From 4e63c4f720728cc9b54e6033da897b5a785836eb Mon Sep 17 00:00:00 2001 From: Olly Betts Date: Fri, 2 May 2014 18:40:54 +1200 Subject: Remove errnoeous note claiming C++ operator~ maps to Lua .. --- Doc/Manual/Lua.html | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Doc/Manual/Lua.html b/Doc/Manual/Lua.html index c67e08834..269cb2801 100644 --- a/Doc/Manual/Lua.html +++ b/Doc/Manual/Lua.html @@ -993,7 +993,7 @@ The current list of operators which can be overloaded (and the alternative funct
  • __unm__ unary minus
  • __call__ operator() (often used in functor classes)
  • __pow__ the exponential fn (no C++ equivalent, Lua uses ^) -
  • __concat__ the concatenation operator (SWIG maps C++'s ~ to Lua's ..) +
  • __concat__ the concatenation operator (Lua's ..)
  • __eq__ operator==
  • __lt__ operator<
  • __le__ operator<= -- cgit v1.2.1 From 7cd9063b52d29bf3a5c6cee8d272b75a1012756b Mon Sep 17 00:00:00 2001 From: Karl Wette Date: Fri, 2 May 2014 16:01:55 +0200 Subject: Remove execute permissions from various non-executable files - source files and Makefiles need never be executable - scripts are run directly by their interpreters in the test suites, so also do not need to be executable --- Examples/guile/matrix/runme.scm | 0 Examples/javascript/class/Makefile | 0 Examples/javascript/class/example.cxx | 0 Examples/javascript/class/example.h | 0 Examples/javascript/class/example.i | 0 Examples/javascript/class/runme.js | 0 Examples/javascript/constant/Makefile | 0 Examples/javascript/constant/example.i | 0 Examples/javascript/constant/runme.js | 0 Examples/javascript/enum/Makefile | 0 Examples/javascript/enum/example.cxx | 0 Examples/javascript/enum/example.h | 0 Examples/javascript/enum/example.i | 0 Examples/javascript/enum/runme.js | 0 Examples/javascript/exception/Makefile | 0 Examples/javascript/functor/Makefile | 0 Examples/javascript/nspace/Makefile | 0 Examples/javascript/operator/Makefile | 0 Examples/javascript/overload/Makefile | 0 Examples/javascript/pointer/Makefile | 0 Examples/javascript/pointer/example.cxx | 0 Examples/javascript/pointer/example.i | 0 Examples/javascript/pointer/runme.js | 0 Examples/javascript/reference/Makefile | 0 Examples/javascript/reference/example.cxx | 0 Examples/javascript/reference/example.h | 0 Examples/javascript/reference/example.i | 0 Examples/javascript/reference/runme.js | 0 Examples/javascript/simple/Makefile | 0 Examples/javascript/simple/runme.js | 0 Examples/javascript/template/Makefile | 0 Examples/javascript/variables/Makefile | 0 Examples/javascript/variables/example.cxx | 0 Examples/javascript/variables/example.h | 0 Examples/javascript/variables/example.i | 0 Examples/javascript/variables/runme.js | 0 Examples/test-suite/javascript/Makefile.in | 0 Examples/test-suite/ocaml/makedebugtop | 0 Examples/test-suite/octave/iadd_runme.m | 0 Examples/test-suite/octave/overload_complicated_runme.m | 0 Examples/test-suite/perl5/char_binary_runme.pl | 0 Examples/test-suite/perl5/class_ignore_runme.pl | 0 Examples/test-suite/perl5/contract_runme.pl | 0 Examples/test-suite/perl5/enum_template_runme.pl | 0 Examples/test-suite/perl5/grouping_runme.pl | 0 Examples/test-suite/perl5/ignore_parameter_runme.pl | 0 Examples/test-suite/perl5/inherit_missing_runme.pl | 0 Examples/test-suite/perl5/li_std_except_runme.pl | 0 Examples/test-suite/perl5/minherit_runme.pl | 0 Examples/test-suite/perl5/naturalvar_runme.pl | 0 Examples/test-suite/perl5/preproc_runme.pl | 0 Examples/test-suite/perl5/primitive_types_runme.pl | 0 Examples/test-suite/perl5/reference_global_vars_runme.pl | 0 Examples/test-suite/perl5/rename_scope_runme.pl | 0 Examples/test-suite/perl5/return_const_value_runme.pl | 0 Examples/test-suite/perl5/run-perl-test.pl | 0 Examples/test-suite/perl5/sizet_runme.pl | 0 Examples/test-suite/perl5/sneaky1_runme.pl | 0 Examples/test-suite/perl5/template_typedef_cplx2_runme.pl | 0 Examples/test-suite/perl5/typedef_class_runme.pl | 0 Examples/test-suite/perl5/typename_runme.pl | 0 Examples/test-suite/perl5/using1_runme.pl | 0 Examples/test-suite/perl5/using2_runme.pl | 0 Examples/test-suite/perl5/wrapmacro_runme.pl | 0 Examples/test-suite/ruby/abstract_access_runme.rb | 0 Examples/test-suite/ruby/access_change_runme.rb | 0 Examples/test-suite/ruby/add_link_runme.rb | 0 Examples/test-suite/ruby/anonymous_bitfield_runme.rb | 0 Examples/test-suite/ruby/apply_signed_char_runme.rb | 0 Examples/test-suite/ruby/apply_strings_runme.rb | 0 Examples/test-suite/ruby/argout_runme.rb | 0 Examples/test-suite/ruby/arrays_runme.rb | 0 Examples/test-suite/ruby/cast_operator_runme.rb | 0 Examples/test-suite/ruby/casts_runme.rb | 0 Examples/test-suite/ruby/check_missing_tests.rb | 0 Examples/test-suite/ruby/class_ignore_runme.rb | 0 Examples/test-suite/ruby/const_const_runme.rb | 0 Examples/test-suite/ruby/constover_runme.rb | 0 Examples/test-suite/ruby/cpp_namespace_runme.rb | 0 Examples/test-suite/ruby/default_constructor_runme.rb | 0 Examples/test-suite/ruby/dynamic_cast_runme.rb | 0 Examples/test-suite/ruby/enum_thorough_runme.rb | 0 Examples/test-suite/ruby/function_typedef_runme.rb | 0 Examples/test-suite/ruby/imports_runme.rb | 0 Examples/test-suite/ruby/integers_runme.rb | 0 Examples/test-suite/ruby/li_cstring_runme.rb | 0 Examples/test-suite/ruby/li_math_runme.rb | 0 Examples/test-suite/ruby/li_std_functors_runme.rb | 0 Examples/test-suite/ruby/li_std_map_runme.rb | 0 Examples/test-suite/ruby/li_std_multimap_runme.rb | 0 Examples/test-suite/ruby/li_std_pair_runme.rb | 0 Examples/test-suite/ruby/li_std_queue_runme.rb | 0 Examples/test-suite/ruby/li_std_set_runme.rb | 0 Examples/test-suite/ruby/li_std_speed2_runme.rb | 0 Examples/test-suite/ruby/li_std_stack_runme.rb | 0 Examples/test-suite/ruby/li_std_stream_runme.rb | 0 Examples/test-suite/ruby/li_std_vector_enum_runme.rb | 0 Examples/test-suite/ruby/li_std_vector_runme.rb | 0 Examples/test-suite/ruby/namespace_typemap_runme.rb | 0 Examples/test-suite/ruby/overload_bool_runme.rb | 0 Examples/test-suite/ruby/overload_copy_runme.rb | 0 Examples/test-suite/ruby/overload_extend_runme.rb | 0 Examples/test-suite/ruby/overload_extendc_runme.rb | 0 Examples/test-suite/ruby/overload_simple_runme.rb | 0 Examples/test-suite/ruby/overload_template_runme.rb | 0 Examples/test-suite/ruby/primitive_ref_runme.rb | 0 Examples/test-suite/ruby/ruby_li_std_speed_runme.rb | 0 Examples/test-suite/ruby/sneaky1_runme.rb | 0 Examples/test-suite/ruby/std_containers_runme.rb | 0 Examples/test-suite/ruby/stl_new_runme.rb | 0 Examples/test-suite/ruby/swig_assert.rb | 0 Examples/test-suite/ruby/swig_gc.rb | 0 Examples/test-suite/ruby/template_inherit_runme.rb | 0 Examples/test-suite/ruby/template_ns4_runme.rb | 0 Examples/test-suite/ruby/template_ns_runme.rb | 0 Examples/test-suite/ruby/template_rename_runme.rb | 0 Examples/test-suite/ruby/typedef_inherit_runme.rb | 0 Examples/test-suite/ruby/typedef_scope_runme.rb | 0 Examples/test-suite/ruby/typemap_namespace_runme.rb | 0 Examples/test-suite/ruby/typename_runme.rb | 0 Lib/javascript/jsc/std_common.i | 0 Lib/javascript/jsc/std_map.i | 0 Lib/javascript/jsc/std_pair.i | 0 Lib/javascript/jsc/std_string.i | 0 Lib/javascript/jsc/std_vector.i | 0 Lib/javascript/jsc/stl.i | 0 Lib/javascript/v8/std_common.i | 0 Lib/javascript/v8/std_map.i | 0 Lib/javascript/v8/std_pair.i | 0 Lib/javascript/v8/std_string.i | 0 Lib/javascript/v8/std_vector.i | 0 Lib/javascript/v8/stl.i | 0 Tools/javascript/v8_shell.cxx | 0 133 files changed, 0 insertions(+), 0 deletions(-) mode change 100755 => 100644 Examples/guile/matrix/runme.scm mode change 100755 => 100644 Examples/javascript/class/Makefile mode change 100755 => 100644 Examples/javascript/class/example.cxx mode change 100755 => 100644 Examples/javascript/class/example.h mode change 100755 => 100644 Examples/javascript/class/example.i mode change 100755 => 100644 Examples/javascript/class/runme.js mode change 100755 => 100644 Examples/javascript/constant/Makefile mode change 100755 => 100644 Examples/javascript/constant/example.i mode change 100755 => 100644 Examples/javascript/constant/runme.js mode change 100755 => 100644 Examples/javascript/enum/Makefile mode change 100755 => 100644 Examples/javascript/enum/example.cxx mode change 100755 => 100644 Examples/javascript/enum/example.h mode change 100755 => 100644 Examples/javascript/enum/example.i mode change 100755 => 100644 Examples/javascript/enum/runme.js mode change 100755 => 100644 Examples/javascript/exception/Makefile mode change 100755 => 100644 Examples/javascript/functor/Makefile mode change 100755 => 100644 Examples/javascript/nspace/Makefile mode change 100755 => 100644 Examples/javascript/operator/Makefile mode change 100755 => 100644 Examples/javascript/overload/Makefile mode change 100755 => 100644 Examples/javascript/pointer/Makefile mode change 100755 => 100644 Examples/javascript/pointer/example.cxx mode change 100755 => 100644 Examples/javascript/pointer/example.i mode change 100755 => 100644 Examples/javascript/pointer/runme.js mode change 100755 => 100644 Examples/javascript/reference/Makefile mode change 100755 => 100644 Examples/javascript/reference/example.cxx mode change 100755 => 100644 Examples/javascript/reference/example.h mode change 100755 => 100644 Examples/javascript/reference/example.i mode change 100755 => 100644 Examples/javascript/reference/runme.js mode change 100755 => 100644 Examples/javascript/simple/Makefile mode change 100755 => 100644 Examples/javascript/simple/runme.js mode change 100755 => 100644 Examples/javascript/template/Makefile mode change 100755 => 100644 Examples/javascript/variables/Makefile mode change 100755 => 100644 Examples/javascript/variables/example.cxx mode change 100755 => 100644 Examples/javascript/variables/example.h mode change 100755 => 100644 Examples/javascript/variables/example.i mode change 100755 => 100644 Examples/javascript/variables/runme.js mode change 100755 => 100644 Examples/test-suite/javascript/Makefile.in mode change 100755 => 100644 Examples/test-suite/ocaml/makedebugtop mode change 100755 => 100644 Examples/test-suite/octave/iadd_runme.m mode change 100755 => 100644 Examples/test-suite/octave/overload_complicated_runme.m mode change 100755 => 100644 Examples/test-suite/perl5/char_binary_runme.pl mode change 100755 => 100644 Examples/test-suite/perl5/class_ignore_runme.pl mode change 100755 => 100644 Examples/test-suite/perl5/contract_runme.pl mode change 100755 => 100644 Examples/test-suite/perl5/enum_template_runme.pl mode change 100755 => 100644 Examples/test-suite/perl5/grouping_runme.pl mode change 100755 => 100644 Examples/test-suite/perl5/ignore_parameter_runme.pl mode change 100755 => 100644 Examples/test-suite/perl5/inherit_missing_runme.pl mode change 100755 => 100644 Examples/test-suite/perl5/li_std_except_runme.pl mode change 100755 => 100644 Examples/test-suite/perl5/minherit_runme.pl mode change 100755 => 100644 Examples/test-suite/perl5/naturalvar_runme.pl mode change 100755 => 100644 Examples/test-suite/perl5/preproc_runme.pl mode change 100755 => 100644 Examples/test-suite/perl5/primitive_types_runme.pl mode change 100755 => 100644 Examples/test-suite/perl5/reference_global_vars_runme.pl mode change 100755 => 100644 Examples/test-suite/perl5/rename_scope_runme.pl mode change 100755 => 100644 Examples/test-suite/perl5/return_const_value_runme.pl mode change 100755 => 100644 Examples/test-suite/perl5/run-perl-test.pl mode change 100755 => 100644 Examples/test-suite/perl5/sizet_runme.pl mode change 100755 => 100644 Examples/test-suite/perl5/sneaky1_runme.pl mode change 100755 => 100644 Examples/test-suite/perl5/template_typedef_cplx2_runme.pl mode change 100755 => 100644 Examples/test-suite/perl5/typedef_class_runme.pl mode change 100755 => 100644 Examples/test-suite/perl5/typename_runme.pl mode change 100755 => 100644 Examples/test-suite/perl5/using1_runme.pl mode change 100755 => 100644 Examples/test-suite/perl5/using2_runme.pl mode change 100755 => 100644 Examples/test-suite/perl5/wrapmacro_runme.pl mode change 100755 => 100644 Examples/test-suite/ruby/abstract_access_runme.rb mode change 100755 => 100644 Examples/test-suite/ruby/access_change_runme.rb mode change 100755 => 100644 Examples/test-suite/ruby/add_link_runme.rb mode change 100755 => 100644 Examples/test-suite/ruby/anonymous_bitfield_runme.rb mode change 100755 => 100644 Examples/test-suite/ruby/apply_signed_char_runme.rb mode change 100755 => 100644 Examples/test-suite/ruby/apply_strings_runme.rb mode change 100755 => 100644 Examples/test-suite/ruby/argout_runme.rb mode change 100755 => 100644 Examples/test-suite/ruby/arrays_runme.rb mode change 100755 => 100644 Examples/test-suite/ruby/cast_operator_runme.rb mode change 100755 => 100644 Examples/test-suite/ruby/casts_runme.rb mode change 100755 => 100644 Examples/test-suite/ruby/check_missing_tests.rb mode change 100755 => 100644 Examples/test-suite/ruby/class_ignore_runme.rb mode change 100755 => 100644 Examples/test-suite/ruby/const_const_runme.rb mode change 100755 => 100644 Examples/test-suite/ruby/constover_runme.rb mode change 100755 => 100644 Examples/test-suite/ruby/cpp_namespace_runme.rb mode change 100755 => 100644 Examples/test-suite/ruby/default_constructor_runme.rb mode change 100755 => 100644 Examples/test-suite/ruby/dynamic_cast_runme.rb mode change 100755 => 100644 Examples/test-suite/ruby/enum_thorough_runme.rb mode change 100755 => 100644 Examples/test-suite/ruby/function_typedef_runme.rb mode change 100755 => 100644 Examples/test-suite/ruby/imports_runme.rb mode change 100755 => 100644 Examples/test-suite/ruby/integers_runme.rb mode change 100755 => 100644 Examples/test-suite/ruby/li_cstring_runme.rb mode change 100755 => 100644 Examples/test-suite/ruby/li_math_runme.rb mode change 100755 => 100644 Examples/test-suite/ruby/li_std_functors_runme.rb mode change 100755 => 100644 Examples/test-suite/ruby/li_std_map_runme.rb mode change 100755 => 100644 Examples/test-suite/ruby/li_std_multimap_runme.rb mode change 100755 => 100644 Examples/test-suite/ruby/li_std_pair_runme.rb mode change 100755 => 100644 Examples/test-suite/ruby/li_std_queue_runme.rb mode change 100755 => 100644 Examples/test-suite/ruby/li_std_set_runme.rb mode change 100755 => 100644 Examples/test-suite/ruby/li_std_speed2_runme.rb mode change 100755 => 100644 Examples/test-suite/ruby/li_std_stack_runme.rb mode change 100755 => 100644 Examples/test-suite/ruby/li_std_stream_runme.rb mode change 100755 => 100644 Examples/test-suite/ruby/li_std_vector_enum_runme.rb mode change 100755 => 100644 Examples/test-suite/ruby/li_std_vector_runme.rb mode change 100755 => 100644 Examples/test-suite/ruby/namespace_typemap_runme.rb mode change 100755 => 100644 Examples/test-suite/ruby/overload_bool_runme.rb mode change 100755 => 100644 Examples/test-suite/ruby/overload_copy_runme.rb mode change 100755 => 100644 Examples/test-suite/ruby/overload_extend_runme.rb mode change 100755 => 100644 Examples/test-suite/ruby/overload_extendc_runme.rb mode change 100755 => 100644 Examples/test-suite/ruby/overload_simple_runme.rb mode change 100755 => 100644 Examples/test-suite/ruby/overload_template_runme.rb mode change 100755 => 100644 Examples/test-suite/ruby/primitive_ref_runme.rb mode change 100755 => 100644 Examples/test-suite/ruby/ruby_li_std_speed_runme.rb mode change 100755 => 100644 Examples/test-suite/ruby/sneaky1_runme.rb mode change 100755 => 100644 Examples/test-suite/ruby/std_containers_runme.rb mode change 100755 => 100644 Examples/test-suite/ruby/stl_new_runme.rb mode change 100755 => 100644 Examples/test-suite/ruby/swig_assert.rb mode change 100755 => 100644 Examples/test-suite/ruby/swig_gc.rb mode change 100755 => 100644 Examples/test-suite/ruby/template_inherit_runme.rb mode change 100755 => 100644 Examples/test-suite/ruby/template_ns4_runme.rb mode change 100755 => 100644 Examples/test-suite/ruby/template_ns_runme.rb mode change 100755 => 100644 Examples/test-suite/ruby/template_rename_runme.rb mode change 100755 => 100644 Examples/test-suite/ruby/typedef_inherit_runme.rb mode change 100755 => 100644 Examples/test-suite/ruby/typedef_scope_runme.rb mode change 100755 => 100644 Examples/test-suite/ruby/typemap_namespace_runme.rb mode change 100755 => 100644 Examples/test-suite/ruby/typename_runme.rb mode change 100755 => 100644 Lib/javascript/jsc/std_common.i mode change 100755 => 100644 Lib/javascript/jsc/std_map.i mode change 100755 => 100644 Lib/javascript/jsc/std_pair.i mode change 100755 => 100644 Lib/javascript/jsc/std_string.i mode change 100755 => 100644 Lib/javascript/jsc/std_vector.i mode change 100755 => 100644 Lib/javascript/jsc/stl.i mode change 100755 => 100644 Lib/javascript/v8/std_common.i mode change 100755 => 100644 Lib/javascript/v8/std_map.i mode change 100755 => 100644 Lib/javascript/v8/std_pair.i mode change 100755 => 100644 Lib/javascript/v8/std_string.i mode change 100755 => 100644 Lib/javascript/v8/std_vector.i mode change 100755 => 100644 Lib/javascript/v8/stl.i mode change 100755 => 100644 Tools/javascript/v8_shell.cxx diff --git a/Examples/guile/matrix/runme.scm b/Examples/guile/matrix/runme.scm old mode 100755 new mode 100644 diff --git a/Examples/javascript/class/Makefile b/Examples/javascript/class/Makefile old mode 100755 new mode 100644 diff --git a/Examples/javascript/class/example.cxx b/Examples/javascript/class/example.cxx old mode 100755 new mode 100644 diff --git a/Examples/javascript/class/example.h b/Examples/javascript/class/example.h old mode 100755 new mode 100644 diff --git a/Examples/javascript/class/example.i b/Examples/javascript/class/example.i old mode 100755 new mode 100644 diff --git a/Examples/javascript/class/runme.js b/Examples/javascript/class/runme.js old mode 100755 new mode 100644 diff --git a/Examples/javascript/constant/Makefile b/Examples/javascript/constant/Makefile old mode 100755 new mode 100644 diff --git a/Examples/javascript/constant/example.i b/Examples/javascript/constant/example.i old mode 100755 new mode 100644 diff --git a/Examples/javascript/constant/runme.js b/Examples/javascript/constant/runme.js old mode 100755 new mode 100644 diff --git a/Examples/javascript/enum/Makefile b/Examples/javascript/enum/Makefile old mode 100755 new mode 100644 diff --git a/Examples/javascript/enum/example.cxx b/Examples/javascript/enum/example.cxx old mode 100755 new mode 100644 diff --git a/Examples/javascript/enum/example.h b/Examples/javascript/enum/example.h old mode 100755 new mode 100644 diff --git a/Examples/javascript/enum/example.i b/Examples/javascript/enum/example.i old mode 100755 new mode 100644 diff --git a/Examples/javascript/enum/runme.js b/Examples/javascript/enum/runme.js old mode 100755 new mode 100644 diff --git a/Examples/javascript/exception/Makefile b/Examples/javascript/exception/Makefile old mode 100755 new mode 100644 diff --git a/Examples/javascript/functor/Makefile b/Examples/javascript/functor/Makefile old mode 100755 new mode 100644 diff --git a/Examples/javascript/nspace/Makefile b/Examples/javascript/nspace/Makefile old mode 100755 new mode 100644 diff --git a/Examples/javascript/operator/Makefile b/Examples/javascript/operator/Makefile old mode 100755 new mode 100644 diff --git a/Examples/javascript/overload/Makefile b/Examples/javascript/overload/Makefile old mode 100755 new mode 100644 diff --git a/Examples/javascript/pointer/Makefile b/Examples/javascript/pointer/Makefile old mode 100755 new mode 100644 diff --git a/Examples/javascript/pointer/example.cxx b/Examples/javascript/pointer/example.cxx old mode 100755 new mode 100644 diff --git a/Examples/javascript/pointer/example.i b/Examples/javascript/pointer/example.i old mode 100755 new mode 100644 diff --git a/Examples/javascript/pointer/runme.js b/Examples/javascript/pointer/runme.js old mode 100755 new mode 100644 diff --git a/Examples/javascript/reference/Makefile b/Examples/javascript/reference/Makefile old mode 100755 new mode 100644 diff --git a/Examples/javascript/reference/example.cxx b/Examples/javascript/reference/example.cxx old mode 100755 new mode 100644 diff --git a/Examples/javascript/reference/example.h b/Examples/javascript/reference/example.h old mode 100755 new mode 100644 diff --git a/Examples/javascript/reference/example.i b/Examples/javascript/reference/example.i old mode 100755 new mode 100644 diff --git a/Examples/javascript/reference/runme.js b/Examples/javascript/reference/runme.js old mode 100755 new mode 100644 diff --git a/Examples/javascript/simple/Makefile b/Examples/javascript/simple/Makefile old mode 100755 new mode 100644 diff --git a/Examples/javascript/simple/runme.js b/Examples/javascript/simple/runme.js old mode 100755 new mode 100644 diff --git a/Examples/javascript/template/Makefile b/Examples/javascript/template/Makefile old mode 100755 new mode 100644 diff --git a/Examples/javascript/variables/Makefile b/Examples/javascript/variables/Makefile old mode 100755 new mode 100644 diff --git a/Examples/javascript/variables/example.cxx b/Examples/javascript/variables/example.cxx old mode 100755 new mode 100644 diff --git a/Examples/javascript/variables/example.h b/Examples/javascript/variables/example.h old mode 100755 new mode 100644 diff --git a/Examples/javascript/variables/example.i b/Examples/javascript/variables/example.i old mode 100755 new mode 100644 diff --git a/Examples/javascript/variables/runme.js b/Examples/javascript/variables/runme.js old mode 100755 new mode 100644 diff --git a/Examples/test-suite/javascript/Makefile.in b/Examples/test-suite/javascript/Makefile.in old mode 100755 new mode 100644 diff --git a/Examples/test-suite/ocaml/makedebugtop b/Examples/test-suite/ocaml/makedebugtop old mode 100755 new mode 100644 diff --git a/Examples/test-suite/octave/iadd_runme.m b/Examples/test-suite/octave/iadd_runme.m old mode 100755 new mode 100644 diff --git a/Examples/test-suite/octave/overload_complicated_runme.m b/Examples/test-suite/octave/overload_complicated_runme.m old mode 100755 new mode 100644 diff --git a/Examples/test-suite/perl5/char_binary_runme.pl b/Examples/test-suite/perl5/char_binary_runme.pl old mode 100755 new mode 100644 diff --git a/Examples/test-suite/perl5/class_ignore_runme.pl b/Examples/test-suite/perl5/class_ignore_runme.pl old mode 100755 new mode 100644 diff --git a/Examples/test-suite/perl5/contract_runme.pl b/Examples/test-suite/perl5/contract_runme.pl old mode 100755 new mode 100644 diff --git a/Examples/test-suite/perl5/enum_template_runme.pl b/Examples/test-suite/perl5/enum_template_runme.pl old mode 100755 new mode 100644 diff --git a/Examples/test-suite/perl5/grouping_runme.pl b/Examples/test-suite/perl5/grouping_runme.pl old mode 100755 new mode 100644 diff --git a/Examples/test-suite/perl5/ignore_parameter_runme.pl b/Examples/test-suite/perl5/ignore_parameter_runme.pl old mode 100755 new mode 100644 diff --git a/Examples/test-suite/perl5/inherit_missing_runme.pl b/Examples/test-suite/perl5/inherit_missing_runme.pl old mode 100755 new mode 100644 diff --git a/Examples/test-suite/perl5/li_std_except_runme.pl b/Examples/test-suite/perl5/li_std_except_runme.pl old mode 100755 new mode 100644 diff --git a/Examples/test-suite/perl5/minherit_runme.pl b/Examples/test-suite/perl5/minherit_runme.pl old mode 100755 new mode 100644 diff --git a/Examples/test-suite/perl5/naturalvar_runme.pl b/Examples/test-suite/perl5/naturalvar_runme.pl old mode 100755 new mode 100644 diff --git a/Examples/test-suite/perl5/preproc_runme.pl b/Examples/test-suite/perl5/preproc_runme.pl old mode 100755 new mode 100644 diff --git a/Examples/test-suite/perl5/primitive_types_runme.pl b/Examples/test-suite/perl5/primitive_types_runme.pl old mode 100755 new mode 100644 diff --git a/Examples/test-suite/perl5/reference_global_vars_runme.pl b/Examples/test-suite/perl5/reference_global_vars_runme.pl old mode 100755 new mode 100644 diff --git a/Examples/test-suite/perl5/rename_scope_runme.pl b/Examples/test-suite/perl5/rename_scope_runme.pl old mode 100755 new mode 100644 diff --git a/Examples/test-suite/perl5/return_const_value_runme.pl b/Examples/test-suite/perl5/return_const_value_runme.pl old mode 100755 new mode 100644 diff --git a/Examples/test-suite/perl5/run-perl-test.pl b/Examples/test-suite/perl5/run-perl-test.pl old mode 100755 new mode 100644 diff --git a/Examples/test-suite/perl5/sizet_runme.pl b/Examples/test-suite/perl5/sizet_runme.pl old mode 100755 new mode 100644 diff --git a/Examples/test-suite/perl5/sneaky1_runme.pl b/Examples/test-suite/perl5/sneaky1_runme.pl old mode 100755 new mode 100644 diff --git a/Examples/test-suite/perl5/template_typedef_cplx2_runme.pl b/Examples/test-suite/perl5/template_typedef_cplx2_runme.pl old mode 100755 new mode 100644 diff --git a/Examples/test-suite/perl5/typedef_class_runme.pl b/Examples/test-suite/perl5/typedef_class_runme.pl old mode 100755 new mode 100644 diff --git a/Examples/test-suite/perl5/typename_runme.pl b/Examples/test-suite/perl5/typename_runme.pl old mode 100755 new mode 100644 diff --git a/Examples/test-suite/perl5/using1_runme.pl b/Examples/test-suite/perl5/using1_runme.pl old mode 100755 new mode 100644 diff --git a/Examples/test-suite/perl5/using2_runme.pl b/Examples/test-suite/perl5/using2_runme.pl old mode 100755 new mode 100644 diff --git a/Examples/test-suite/perl5/wrapmacro_runme.pl b/Examples/test-suite/perl5/wrapmacro_runme.pl old mode 100755 new mode 100644 diff --git a/Examples/test-suite/ruby/abstract_access_runme.rb b/Examples/test-suite/ruby/abstract_access_runme.rb old mode 100755 new mode 100644 diff --git a/Examples/test-suite/ruby/access_change_runme.rb b/Examples/test-suite/ruby/access_change_runme.rb old mode 100755 new mode 100644 diff --git a/Examples/test-suite/ruby/add_link_runme.rb b/Examples/test-suite/ruby/add_link_runme.rb old mode 100755 new mode 100644 diff --git a/Examples/test-suite/ruby/anonymous_bitfield_runme.rb b/Examples/test-suite/ruby/anonymous_bitfield_runme.rb old mode 100755 new mode 100644 diff --git a/Examples/test-suite/ruby/apply_signed_char_runme.rb b/Examples/test-suite/ruby/apply_signed_char_runme.rb old mode 100755 new mode 100644 diff --git a/Examples/test-suite/ruby/apply_strings_runme.rb b/Examples/test-suite/ruby/apply_strings_runme.rb old mode 100755 new mode 100644 diff --git a/Examples/test-suite/ruby/argout_runme.rb b/Examples/test-suite/ruby/argout_runme.rb old mode 100755 new mode 100644 diff --git a/Examples/test-suite/ruby/arrays_runme.rb b/Examples/test-suite/ruby/arrays_runme.rb old mode 100755 new mode 100644 diff --git a/Examples/test-suite/ruby/cast_operator_runme.rb b/Examples/test-suite/ruby/cast_operator_runme.rb old mode 100755 new mode 100644 diff --git a/Examples/test-suite/ruby/casts_runme.rb b/Examples/test-suite/ruby/casts_runme.rb old mode 100755 new mode 100644 diff --git a/Examples/test-suite/ruby/check_missing_tests.rb b/Examples/test-suite/ruby/check_missing_tests.rb old mode 100755 new mode 100644 diff --git a/Examples/test-suite/ruby/class_ignore_runme.rb b/Examples/test-suite/ruby/class_ignore_runme.rb old mode 100755 new mode 100644 diff --git a/Examples/test-suite/ruby/const_const_runme.rb b/Examples/test-suite/ruby/const_const_runme.rb old mode 100755 new mode 100644 diff --git a/Examples/test-suite/ruby/constover_runme.rb b/Examples/test-suite/ruby/constover_runme.rb old mode 100755 new mode 100644 diff --git a/Examples/test-suite/ruby/cpp_namespace_runme.rb b/Examples/test-suite/ruby/cpp_namespace_runme.rb old mode 100755 new mode 100644 diff --git a/Examples/test-suite/ruby/default_constructor_runme.rb b/Examples/test-suite/ruby/default_constructor_runme.rb old mode 100755 new mode 100644 diff --git a/Examples/test-suite/ruby/dynamic_cast_runme.rb b/Examples/test-suite/ruby/dynamic_cast_runme.rb old mode 100755 new mode 100644 diff --git a/Examples/test-suite/ruby/enum_thorough_runme.rb b/Examples/test-suite/ruby/enum_thorough_runme.rb old mode 100755 new mode 100644 diff --git a/Examples/test-suite/ruby/function_typedef_runme.rb b/Examples/test-suite/ruby/function_typedef_runme.rb old mode 100755 new mode 100644 diff --git a/Examples/test-suite/ruby/imports_runme.rb b/Examples/test-suite/ruby/imports_runme.rb old mode 100755 new mode 100644 diff --git a/Examples/test-suite/ruby/integers_runme.rb b/Examples/test-suite/ruby/integers_runme.rb old mode 100755 new mode 100644 diff --git a/Examples/test-suite/ruby/li_cstring_runme.rb b/Examples/test-suite/ruby/li_cstring_runme.rb old mode 100755 new mode 100644 diff --git a/Examples/test-suite/ruby/li_math_runme.rb b/Examples/test-suite/ruby/li_math_runme.rb old mode 100755 new mode 100644 diff --git a/Examples/test-suite/ruby/li_std_functors_runme.rb b/Examples/test-suite/ruby/li_std_functors_runme.rb old mode 100755 new mode 100644 diff --git a/Examples/test-suite/ruby/li_std_map_runme.rb b/Examples/test-suite/ruby/li_std_map_runme.rb old mode 100755 new mode 100644 diff --git a/Examples/test-suite/ruby/li_std_multimap_runme.rb b/Examples/test-suite/ruby/li_std_multimap_runme.rb old mode 100755 new mode 100644 diff --git a/Examples/test-suite/ruby/li_std_pair_runme.rb b/Examples/test-suite/ruby/li_std_pair_runme.rb old mode 100755 new mode 100644 diff --git a/Examples/test-suite/ruby/li_std_queue_runme.rb b/Examples/test-suite/ruby/li_std_queue_runme.rb old mode 100755 new mode 100644 diff --git a/Examples/test-suite/ruby/li_std_set_runme.rb b/Examples/test-suite/ruby/li_std_set_runme.rb old mode 100755 new mode 100644 diff --git a/Examples/test-suite/ruby/li_std_speed2_runme.rb b/Examples/test-suite/ruby/li_std_speed2_runme.rb old mode 100755 new mode 100644 diff --git a/Examples/test-suite/ruby/li_std_stack_runme.rb b/Examples/test-suite/ruby/li_std_stack_runme.rb old mode 100755 new mode 100644 diff --git a/Examples/test-suite/ruby/li_std_stream_runme.rb b/Examples/test-suite/ruby/li_std_stream_runme.rb old mode 100755 new mode 100644 diff --git a/Examples/test-suite/ruby/li_std_vector_enum_runme.rb b/Examples/test-suite/ruby/li_std_vector_enum_runme.rb old mode 100755 new mode 100644 diff --git a/Examples/test-suite/ruby/li_std_vector_runme.rb b/Examples/test-suite/ruby/li_std_vector_runme.rb old mode 100755 new mode 100644 diff --git a/Examples/test-suite/ruby/namespace_typemap_runme.rb b/Examples/test-suite/ruby/namespace_typemap_runme.rb old mode 100755 new mode 100644 diff --git a/Examples/test-suite/ruby/overload_bool_runme.rb b/Examples/test-suite/ruby/overload_bool_runme.rb old mode 100755 new mode 100644 diff --git a/Examples/test-suite/ruby/overload_copy_runme.rb b/Examples/test-suite/ruby/overload_copy_runme.rb old mode 100755 new mode 100644 diff --git a/Examples/test-suite/ruby/overload_extend_runme.rb b/Examples/test-suite/ruby/overload_extend_runme.rb old mode 100755 new mode 100644 diff --git a/Examples/test-suite/ruby/overload_extendc_runme.rb b/Examples/test-suite/ruby/overload_extendc_runme.rb old mode 100755 new mode 100644 diff --git a/Examples/test-suite/ruby/overload_simple_runme.rb b/Examples/test-suite/ruby/overload_simple_runme.rb old mode 100755 new mode 100644 diff --git a/Examples/test-suite/ruby/overload_template_runme.rb b/Examples/test-suite/ruby/overload_template_runme.rb old mode 100755 new mode 100644 diff --git a/Examples/test-suite/ruby/primitive_ref_runme.rb b/Examples/test-suite/ruby/primitive_ref_runme.rb old mode 100755 new mode 100644 diff --git a/Examples/test-suite/ruby/ruby_li_std_speed_runme.rb b/Examples/test-suite/ruby/ruby_li_std_speed_runme.rb old mode 100755 new mode 100644 diff --git a/Examples/test-suite/ruby/sneaky1_runme.rb b/Examples/test-suite/ruby/sneaky1_runme.rb old mode 100755 new mode 100644 diff --git a/Examples/test-suite/ruby/std_containers_runme.rb b/Examples/test-suite/ruby/std_containers_runme.rb old mode 100755 new mode 100644 diff --git a/Examples/test-suite/ruby/stl_new_runme.rb b/Examples/test-suite/ruby/stl_new_runme.rb old mode 100755 new mode 100644 diff --git a/Examples/test-suite/ruby/swig_assert.rb b/Examples/test-suite/ruby/swig_assert.rb old mode 100755 new mode 100644 diff --git a/Examples/test-suite/ruby/swig_gc.rb b/Examples/test-suite/ruby/swig_gc.rb old mode 100755 new mode 100644 diff --git a/Examples/test-suite/ruby/template_inherit_runme.rb b/Examples/test-suite/ruby/template_inherit_runme.rb old mode 100755 new mode 100644 diff --git a/Examples/test-suite/ruby/template_ns4_runme.rb b/Examples/test-suite/ruby/template_ns4_runme.rb old mode 100755 new mode 100644 diff --git a/Examples/test-suite/ruby/template_ns_runme.rb b/Examples/test-suite/ruby/template_ns_runme.rb old mode 100755 new mode 100644 diff --git a/Examples/test-suite/ruby/template_rename_runme.rb b/Examples/test-suite/ruby/template_rename_runme.rb old mode 100755 new mode 100644 diff --git a/Examples/test-suite/ruby/typedef_inherit_runme.rb b/Examples/test-suite/ruby/typedef_inherit_runme.rb old mode 100755 new mode 100644 diff --git a/Examples/test-suite/ruby/typedef_scope_runme.rb b/Examples/test-suite/ruby/typedef_scope_runme.rb old mode 100755 new mode 100644 diff --git a/Examples/test-suite/ruby/typemap_namespace_runme.rb b/Examples/test-suite/ruby/typemap_namespace_runme.rb old mode 100755 new mode 100644 diff --git a/Examples/test-suite/ruby/typename_runme.rb b/Examples/test-suite/ruby/typename_runme.rb old mode 100755 new mode 100644 diff --git a/Lib/javascript/jsc/std_common.i b/Lib/javascript/jsc/std_common.i old mode 100755 new mode 100644 diff --git a/Lib/javascript/jsc/std_map.i b/Lib/javascript/jsc/std_map.i old mode 100755 new mode 100644 diff --git a/Lib/javascript/jsc/std_pair.i b/Lib/javascript/jsc/std_pair.i old mode 100755 new mode 100644 diff --git a/Lib/javascript/jsc/std_string.i b/Lib/javascript/jsc/std_string.i old mode 100755 new mode 100644 diff --git a/Lib/javascript/jsc/std_vector.i b/Lib/javascript/jsc/std_vector.i old mode 100755 new mode 100644 diff --git a/Lib/javascript/jsc/stl.i b/Lib/javascript/jsc/stl.i old mode 100755 new mode 100644 diff --git a/Lib/javascript/v8/std_common.i b/Lib/javascript/v8/std_common.i old mode 100755 new mode 100644 diff --git a/Lib/javascript/v8/std_map.i b/Lib/javascript/v8/std_map.i old mode 100755 new mode 100644 diff --git a/Lib/javascript/v8/std_pair.i b/Lib/javascript/v8/std_pair.i old mode 100755 new mode 100644 diff --git a/Lib/javascript/v8/std_string.i b/Lib/javascript/v8/std_string.i old mode 100755 new mode 100644 diff --git a/Lib/javascript/v8/std_vector.i b/Lib/javascript/v8/std_vector.i old mode 100755 new mode 100644 diff --git a/Lib/javascript/v8/stl.i b/Lib/javascript/v8/stl.i old mode 100755 new mode 100644 diff --git a/Tools/javascript/v8_shell.cxx b/Tools/javascript/v8_shell.cxx old mode 100755 new mode 100644 -- cgit v1.2.1 From d5b765d3888d82d8b6a420b80047278c81c4ef95 Mon Sep 17 00:00:00 2001 From: Karl Wette Date: Fri, 2 May 2014 16:16:11 +0200 Subject: Whitespace cleanup of all Makefiles* - some of the %.clean rules in the test-suite Makefiles were using a single tab as an empty rule, dangerous! I've replaced these with the safer '@exit 0'. --- CCache/Makefile.in | 4 ++-- Doc/Manual/Makefile | 1 - Examples/Makefile.in | 6 +++--- Examples/test-suite/allegrocl/Makefile.in | 9 ++++----- Examples/test-suite/cffi/Makefile.in | 9 ++++----- Examples/test-suite/chicken/Makefile.in | 10 +++++----- Examples/test-suite/clisp/Makefile.in | 9 ++++----- Examples/test-suite/csharp/Makefile.in | 4 ++-- Examples/test-suite/errors/Makefile.in | 7 +++---- Examples/test-suite/go/Makefile.in | 4 ++-- Examples/test-suite/guile/Makefile.in | 10 +++++----- Examples/test-suite/java/Makefile.in | 4 ++-- Examples/test-suite/lua/Makefile.in | 10 +++++----- Examples/test-suite/mzscheme/Makefile.in | 6 +++--- Examples/test-suite/ocaml/Makefile.in | 4 ++-- Examples/test-suite/octave/Makefile.in | 20 +++++++++---------- Examples/test-suite/perl5/Makefile.in | 4 ++-- Examples/test-suite/php/Makefile.in | 4 ++-- Examples/test-suite/pike/Makefile.in | 5 ++--- Examples/test-suite/python/Makefile.in | 23 +++++++++++----------- Examples/test-suite/r/Makefile.in | 12 +++++------- Examples/test-suite/ruby/Makefile.in | 6 +++--- Examples/test-suite/tcl/Makefile.in | 8 ++++---- Examples/test-suite/uffi/Makefile.in | 9 ++++----- Lib/guile/Makefile | 1 - Lib/mzscheme/Makefile | 1 - Lib/perl5/Makefile.in | 32 +++++++++++++------------------ Lib/perl5/Makefile.pl | 4 +--- Lib/python/Makefile.in | 32 ++++++++++++++----------------- Lib/ruby/Makefile.swig | 2 +- Lib/tcl/Makefile.in | 32 ++++++++++++++----------------- Makefile.in | 8 ++++---- Source/Makefile.am | 5 ++--- 33 files changed, 138 insertions(+), 167 deletions(-) diff --git a/CCache/Makefile.in b/CCache/Makefile.in index d8f9042fe..abe78c277 100644 --- a/CCache/Makefile.in +++ b/CCache/Makefile.in @@ -69,9 +69,9 @@ distclean: clean maintainer-clean: distclean /bin/rm -f $(PACKAGE_NAME).1 web/ccache-man.html - + # FIXME: To fix this, test.sh needs to be able to take ccache from the # installed prefix, not from the source dir. -installcheck: +installcheck: @echo "WARNING! This is not really \"installcheck\" yet." $(MAKE) check diff --git a/Doc/Manual/Makefile b/Doc/Manual/Makefile index 42149ba3a..5112afa33 100644 --- a/Doc/Manual/Makefile +++ b/Doc/Manual/Makefile @@ -75,4 +75,3 @@ linkchecker: @echo Note linkchecker versions prior to 6.1 do not work properly wrt anchors @echo ----------------------------------------------------------------------- linkchecker --config=./linkchecker.config index.html - diff --git a/Examples/Makefile.in b/Examples/Makefile.in index 01febf575..326f678c7 100644 --- a/Examples/Makefile.in +++ b/Examples/Makefile.in @@ -88,7 +88,7 @@ endif ################################################################## CPP_DLLIBS = #-L/usr/local/lib/gcc-lib/sparc-sun-solaris2.5.1/2.7.2 \ - -L/usr/local/lib -lg++ -lstdc++ -lgcc + -L/usr/local/lib -lg++ -lstdc++ -lgcc # Solaris workshop 5.0 # CPP_DLLIBS = -L/opt/SUNWspro/lib -lCrun @@ -1621,7 +1621,7 @@ R_SCRIPT=$(RUNME).R r: $(SRCS) $(SWIG) -r $(SWIGOPT) $(INTERFACEPATH) ifneq ($(SRCS),) - $(CC) -g -c $(CFLAGS) $(R_CFLAGS) $(SRCS) $(INCLUDES) + $(CC) -g -c $(CFLAGS) $(R_CFLAGS) $(SRCS) $(INCLUDES) endif +( PKG_CPPFLAGS="$(INCLUDES)" $(COMPILETOOL) $(R) CMD SHLIB -o $(LIBPREFIX)$(TARGET)$(SO) $(ISRCS) $(OBJS) > /dev/null ) @@ -1632,7 +1632,7 @@ endif r_cpp: $(CXXSRCS) $(SWIG) -c++ -r $(SWIGOPT) -o $(RCXXSRCS) $(INTERFACEPATH) ifneq ($(CXXSRCS),) - $(CXX) -g -c $(CXXFLAGS) $(R_CFLAGS) $(CXXSRCS) $(INCLUDES) + $(CXX) -g -c $(CXXFLAGS) $(R_CFLAGS) $(CXXSRCS) $(INCLUDES) endif +( PKG_CPPFLAGS="$(INCLUDES)" $(COMPILETOOL) $(R) CMD SHLIB -o $(LIBPREFIX)$(TARGET)$(SO) $(RCXXSRCS) $(OBJS) > /dev/null ) diff --git a/Examples/test-suite/allegrocl/Makefile.in b/Examples/test-suite/allegrocl/Makefile.in index 5f75bfc08..697c15a45 100644 --- a/Examples/test-suite/allegrocl/Makefile.in +++ b/Examples/test-suite/allegrocl/Makefile.in @@ -12,7 +12,7 @@ top_builddir = @top_builddir@ # these cpp tests generate warnings/errors when compiling # the wrapper .cxx file. -CPP_TEST_BROKEN_CXX = +CPP_TEST_BROKEN_CXX = # the error is wrap:action code generated by swig. \ # error: can't convert [std::string] 'b' to 'bool' \ # might just need a bool overload op for std::string. \ @@ -71,7 +71,7 @@ CPP_TEST_CASES_ACL_UNSUPPORTED = \ extern_throws \ throw_exception \ using_pointers \ - + C_TEST_CASES_ACL_BROKEN = \ # 'cdate.i' module support \ li_cdata \ @@ -96,7 +96,7 @@ include $(srcdir)/../common.mk # none! # Rules for the different types of tests -%.cpptest: +%.cpptest: $(setup) +$(swig_and_compile_cpp) $(run_testcase) @@ -106,7 +106,7 @@ include $(srcdir)/../common.mk +$(swig_and_compile_c) $(run_testcase) -%.multicpptest: +%.multicpptest: $(setup) +$(swig_and_compile_multi_cpp) $(run_testcase) @@ -123,4 +123,3 @@ run_testcase = \ clean: $(MAKE) -f $(top_builddir)/$(EXAMPLES)/Makefile allegrocl_clean - diff --git a/Examples/test-suite/cffi/Makefile.in b/Examples/test-suite/cffi/Makefile.in index aa8b40aec..473d395fd 100644 --- a/Examples/test-suite/cffi/Makefile.in +++ b/Examples/test-suite/cffi/Makefile.in @@ -14,13 +14,13 @@ include $(srcdir)/../common.mk # Overridden variables here # no C++ tests for now CPP_TEST_CASES = -#C_TEST_CASES += +#C_TEST_CASES += # Custom tests - tests with additional commandline options # none! # Rules for the different types of tests -%.cpptest: +%.cpptest: $(setup) +$(swig_and_compile_cpp) $(run_testcase) @@ -30,7 +30,7 @@ CPP_TEST_CASES = +$(swig_and_compile_c) $(run_testcase) -%.multicpptest: +%.multicpptest: $(setup) +$(swig_and_compile_multi_cpp) $(run_testcase) @@ -44,8 +44,7 @@ run_testcase = \ # Clean: (does nothing, we dont generate extra cffi code) %.clean: - + @exit 0 clean: $(MAKE) -f $(top_builddir)/$(EXAMPLES)/Makefile cffi_clean - diff --git a/Examples/test-suite/chicken/Makefile.in b/Examples/test-suite/chicken/Makefile.in index 3c2f3de54..4ee8cb0fa 100644 --- a/Examples/test-suite/chicken/Makefile.in +++ b/Examples/test-suite/chicken/Makefile.in @@ -3,7 +3,7 @@ ####################################################################### LANGUAGE = chicken -VARIANT = +VARIANT = SCRIPTSUFFIX = _runme.ss PROXYSUFFIX = _runme_proxy.ss srcdir = @srcdir@ @@ -17,7 +17,7 @@ SO = @SO@ # Skip the STD cases for now, except for li_std_string.i SKIP_CPP_STD_CASES = Yes -CPP_TEST_CASES += li_std_string +CPP_TEST_CASES += li_std_string EXTRA_TEST_CASES += chicken_ext_test.externaltest @@ -39,7 +39,7 @@ SWIGOPT += -nounit %.multiproxy: SCRIPTSUFFIX = $(PROXYSUFFIX) # Rules for the different types of tests -%.cpptest: +%.cpptest: $(setup) +$(swig_and_compile_cpp) $(run_testcase) @@ -55,7 +55,7 @@ SWIGOPT += -nounit $(MAKE) $*.cproxy; \ fi -%.multicpptest: +%.multicpptest: $(setup) +$(swig_and_compile_multi_cpp) $(run_testcase) @@ -92,7 +92,7 @@ run_testcase = \ # Clean %.clean: - + @exit 0 clean: $(MAKE) -f $(top_builddir)/$(EXAMPLES)/Makefile chicken_clean diff --git a/Examples/test-suite/clisp/Makefile.in b/Examples/test-suite/clisp/Makefile.in index 24655a60f..1fe3c23ac 100644 --- a/Examples/test-suite/clisp/Makefile.in +++ b/Examples/test-suite/clisp/Makefile.in @@ -14,13 +14,13 @@ include $(srcdir)/../common.mk # Overridden variables here # no C++ tests for now CPP_TEST_CASES = -#C_TEST_CASES += +#C_TEST_CASES += # Custom tests - tests with additional commandline options # none! # Rules for the different types of tests -%.cpptest: +%.cpptest: $(setup) +$(swig_and_compile_cpp) $(run_testcase) @@ -30,7 +30,7 @@ CPP_TEST_CASES = +$(swig_and_compile_c) $(run_testcase) -%.multicpptest: +%.multicpptest: $(setup) +$(swig_and_compile_multi_cpp) $(run_testcase) @@ -44,8 +44,7 @@ run_testcase = \ # Clean: (does nothing, we dont generate extra clisp code) %.clean: - + @exit 0 clean: $(MAKE) -f $(top_builddir)/$(EXAMPLES)/Makefile clisp_clean - diff --git a/Examples/test-suite/csharp/Makefile.in b/Examples/test-suite/csharp/Makefile.in index 993699bc8..e54edcc35 100644 --- a/Examples/test-suite/csharp/Makefile.in +++ b/Examples/test-suite/csharp/Makefile.in @@ -40,7 +40,7 @@ csharp_lib_arrays.cpptest: CSHARPFLAGSSPECIAL = -unsafe csharp_swig2_compatibility.cpptest: SWIGOPT += -DSWIG2_CSHARP # Rules for the different types of tests -%.cpptest: +%.cpptest: $(setup) +(cd $* && $(swig_and_compile_cpp)) +$(run_testcase) @@ -50,7 +50,7 @@ csharp_swig2_compatibility.cpptest: SWIGOPT += -DSWIG2_CSHARP +(cd $* && $(swig_and_compile_c)) +$(run_testcase) -%.multicpptest: +%.multicpptest: $(setup) +(cd $* && $(swig_and_compile_multi_cpp)) +$(run_testcase) diff --git a/Examples/test-suite/errors/Makefile.in b/Examples/test-suite/errors/Makefile.in index 601dcd303..e4ba7b751 100644 --- a/Examples/test-suite/errors/Makefile.in +++ b/Examples/test-suite/errors/Makefile.in @@ -29,13 +29,13 @@ CPP_ERROR_TEST_CASES := $(filter cpp_%, $(ALL_ERROR_TEST_CASES)) C_ERROR_TEST_CASES := $(filter-out $(CPP_ERROR_TEST_CASES), $(ALL_ERROR_TEST_CASES)) ERROR_TEST_CASES := $(CPP_ERROR_TEST_CASES:=.cpptest) \ - $(C_ERROR_TEST_CASES:=.ctest) + $(C_ERROR_TEST_CASES:=.ctest) include $(srcdir)/../common.mk # Rules for the different types of tests -%.cpptest: +%.cpptest: echo "$(ACTION)ing errors testcase $*" -$(SWIG) -c++ -python -Wall -Fstandard $(SWIGOPT) $*.i 2>&1 | $(TODOS) > $*.$(ERROR_EXT) $(COMPILETOOL) diff -c $*.stderr $*.$(ERROR_EXT) @@ -46,9 +46,8 @@ include $(srcdir)/../common.mk $(COMPILETOOL) diff -c $*.stderr $*.$(ERROR_EXT) %.clean: - + @exit 0 clean: $(MAKE) -f $(top_builddir)/$(EXAMPLES)/Makefile $(LANGUAGE)_clean @rm -f *.$(ERROR_EXT) *.py - diff --git a/Examples/test-suite/go/Makefile.in b/Examples/test-suite/go/Makefile.in index 535d05a6e..64a84f820 100644 --- a/Examples/test-suite/go/Makefile.in +++ b/Examples/test-suite/go/Makefile.in @@ -29,7 +29,7 @@ include $(srcdir)/../common.mk .SUFFIXES: .cpptest .ctest .multicpptest # Rules for the different types of tests -%.cpptest: +%.cpptest: $(setup) +$(swig_and_compile_cpp) $(run_testcase_cpp) @@ -39,7 +39,7 @@ include $(srcdir)/../common.mk +$(swig_and_compile_c) $(run_testcase) -%.multicpptest: +%.multicpptest: $(setup) +$(swig_and_compile_multi_cpp) $(run_multi_testcase) diff --git a/Examples/test-suite/guile/Makefile.in b/Examples/test-suite/guile/Makefile.in index 0c7b3137c..493dde4f5 100644 --- a/Examples/test-suite/guile/Makefile.in +++ b/Examples/test-suite/guile/Makefile.in @@ -14,9 +14,9 @@ GUILE = @GUILE@ GUILE_RUNTIME= C_TEST_CASES = long_long \ - list_vector \ - multivalue \ - pointer_in_out + list_vector \ + multivalue \ + pointer_in_out include $(srcdir)/../common.mk @@ -28,7 +28,7 @@ INCLUDES += -I$(top_srcdir)/$(EXAMPLES)/$(TEST_SUITE)/guile %.multicpptest: SWIGOPT += $(GUILE_RUNTIME) # Rules for the different types of tests -%.cpptest: +%.cpptest: $(setup) +$(swig_and_compile_cpp) $(run_testcase) @@ -38,7 +38,7 @@ INCLUDES += -I$(top_srcdir)/$(EXAMPLES)/$(TEST_SUITE)/guile +$(swig_and_compile_c) $(run_testcase) -%.multicpptest: +%.multicpptest: $(setup) +$(swig_and_compile_multi_cpp) $(run_testcase) diff --git a/Examples/test-suite/java/Makefile.in b/Examples/test-suite/java/Makefile.in index 059325c13..e4e803d2a 100644 --- a/Examples/test-suite/java/Makefile.in +++ b/Examples/test-suite/java/Makefile.in @@ -55,7 +55,7 @@ director_nspace.%: JAVA_PACKAGE = $*Package director_nspace_director_name_collision.%: JAVA_PACKAGE = $*Package # Rules for the different types of tests -%.cpptest: +%.cpptest: $(setup) +(cd $(JAVA_PACKAGE) && $(swig_and_compile_cpp)) $(run_testcase) @@ -65,7 +65,7 @@ director_nspace_director_name_collision.%: JAVA_PACKAGE = $*Package +(cd $(JAVA_PACKAGE) && $(swig_and_compile_c)) $(run_testcase) -%.multicpptest: +%.multicpptest: $(setup) +(cd $(JAVA_PACKAGE) && $(swig_and_compile_multi_cpp)) $(run_testcase) diff --git a/Examples/test-suite/lua/Makefile.in b/Examples/test-suite/lua/Makefile.in index 66a0d2da9..0950c9d91 100644 --- a/Examples/test-suite/lua/Makefile.in +++ b/Examples/test-suite/lua/Makefile.in @@ -28,7 +28,7 @@ LIBS = -L. lua_no_module_global.%: SWIGOPT += -nomoduleglobal # Rules for the different types of tests -%.cpptest: +%.cpptest: $(setup) +$(swig_and_compile_cpp) $(run_testcase) @@ -38,7 +38,7 @@ lua_no_module_global.%: SWIGOPT += -nomoduleglobal +$(swig_and_compile_c) $(run_testcase) -%.multicpptest: +%.multicpptest: $(setup) +$(swig_and_compile_multi_cpp) $(run_testcase) @@ -52,7 +52,7 @@ run_testcase = \ # Clean: (does nothing, we dont generate extra lua code) %.clean: - + @exit 0 clean: $(MAKE) -f $(top_builddir)/$(EXAMPLES)/Makefile lua_clean @@ -60,5 +60,5 @@ clean: cvsignore: @echo '*wrap* *.so *.dll *.exp *.lib' @echo Makefile - @for i in ${CPP_TEST_CASES} ${C_TEST_CASES}; do echo $$i.lua; done - @for i in ${CPP_TEST_CASES} ${C_TEST_CASES}; do if grep -q $${i}_runme.lua CVS/Entries ; then echo $${i}_runme.lua; fi; done + @for i in ${CPP_TEST_CASES} ${C_TEST_CASES}; do echo $$i.lua; done + @for i in ${CPP_TEST_CASES} ${C_TEST_CASES}; do if grep -q $${i}_runme.lua CVS/Entries ; then echo $${i}_runme.lua; fi; done diff --git a/Examples/test-suite/mzscheme/Makefile.in b/Examples/test-suite/mzscheme/Makefile.in index fcaf33a48..67b8bddf2 100644 --- a/Examples/test-suite/mzscheme/Makefile.in +++ b/Examples/test-suite/mzscheme/Makefile.in @@ -18,7 +18,7 @@ include $(srcdir)/../common.mk # none! # Rules for the different types of tests -%.cpptest: +%.cpptest: $(setup) +$(swig_and_compile_cpp) $(run_testcase) @@ -28,7 +28,7 @@ include $(srcdir)/../common.mk +$(swig_and_compile_c) $(run_testcase) -%.multicpptest: +%.multicpptest: $(setup) +$(swig_and_compile_multi_cpp) $(run_testcase) @@ -42,7 +42,7 @@ run_testcase = \ # Clean %.clean: - + @exit 0 clean: $(MAKE) -f $(top_builddir)/$(EXAMPLES)/Makefile mzscheme_clean diff --git a/Examples/test-suite/ocaml/Makefile.in b/Examples/test-suite/ocaml/Makefile.in index f16c3da95..63edec26a 100644 --- a/Examples/test-suite/ocaml/Makefile.in +++ b/Examples/test-suite/ocaml/Makefile.in @@ -10,7 +10,7 @@ srcdir = @srcdir@ top_srcdir = @top_srcdir@ top_builddir = @top_builddir@ -C_TEST_CASES = +C_TEST_CASES = run_testcase = \ if [ -f $(srcdir)/$(SCRIPTPREFIX)$*$(SCRIPTSUFFIX) -a \ @@ -21,7 +21,7 @@ run_testcase = \ $(COMPILETOOL) $(OCAMLC) -c $(srcdir)/$(SCRIPTPREFIX)$*$(SCRIPTSUFFIX); \ $(COMPILETOOL) $(OCAMLC) swig.cmo -custom -g -cc '$(CXX)' -o runme $(srcdir)/$(*).cmo $(srcdir)/$(*)_runme.cmo $(srcdir)/$(*)_wrap.o && \ $(RUNTOOL) ./runme; \ - fi ; + fi ; check_quant: cat /dev/null > testing diff --git a/Examples/test-suite/octave/Makefile.in b/Examples/test-suite/octave/Makefile.in index dc309e8c6..e48d36a64 100644 --- a/Examples/test-suite/octave/Makefile.in +++ b/Examples/test-suite/octave/Makefile.in @@ -21,7 +21,7 @@ CPP_TEST_BROKEN += \ li_std_set \ li_std_stream -#C_TEST_CASES += +#C_TEST_CASES += # # This test only works with modern C compilers @@ -39,7 +39,7 @@ CSRCS = $(srcdir)/octave_empty.c # none! # Rules for the different types of tests -%.cpptest: +%.cpptest: $(setup) +$(swig_and_compile_cpp) $(run_testcase) @@ -49,7 +49,7 @@ CSRCS = $(srcdir)/octave_empty.c +$(swig_and_compile_c) $(run_testcase) -%.multicpptest: +%.multicpptest: $(setup) +$(swig_and_compile_multi_cpp) $(run_testcase) @@ -72,13 +72,13 @@ clean: cvsignore: @echo '*wrap* *.mc *.so *.dll *.exp *.lib' @echo Makefile - @for i in ${CPP_TEST_CASES} ${C_TEST_CASES}; do echo $$i.m; done - @for i in ${CPP_TEST_CASES} ${C_TEST_CASES}; do if grep -q $${i}_runme.m CVS/Entries ; then echo $${i}_runme.m; fi; done - @echo clientdata_prop_a.m - @echo clientdata_prop_b.m - @echo imports_a.m - @echo imports_b.m - @echo mod_a.m mod_b.m + @for i in ${CPP_TEST_CASES} ${C_TEST_CASES}; do echo $$i.m; done + @for i in ${CPP_TEST_CASES} ${C_TEST_CASES}; do if grep -q $${i}_runme.m CVS/Entries ; then echo $${i}_runme.m; fi; done + @echo clientdata_prop_a.m + @echo clientdata_prop_b.m + @echo imports_a.m + @echo imports_b.m + @echo mod_a.m mod_b.m @echo hugemod.h hugemod_a.i hugemod_b.i hugemod_a.m hugemod_b.m hugemod_runme.m @echo template_typedef_import.m diff --git a/Examples/test-suite/perl5/Makefile.in b/Examples/test-suite/perl5/Makefile.in index 67eaf5c9a..68f32a54a 100644 --- a/Examples/test-suite/perl5/Makefile.in +++ b/Examples/test-suite/perl5/Makefile.in @@ -31,7 +31,7 @@ include $(srcdir)/../common.mk # none! # Rules for the different types of tests -%.cpptest: +%.cpptest: $(setup) +$(swig_and_compile_cpp) $(run_testcase) @@ -41,7 +41,7 @@ include $(srcdir)/../common.mk +$(swig_and_compile_c) $(run_testcase) -%.multicpptest: +%.multicpptest: $(setup) +$(swig_and_compile_multi_cpp) $(run_testcase) diff --git a/Examples/test-suite/php/Makefile.in b/Examples/test-suite/php/Makefile.in index fcdcac2b9..735a3137e 100644 --- a/Examples/test-suite/php/Makefile.in +++ b/Examples/test-suite/php/Makefile.in @@ -29,7 +29,7 @@ missingctests: missingtests: missingcpptests missingctests # Rules for the different types of tests -%.cpptest: +%.cpptest: $(setup) +$(swig_and_compile_cpp) +$(run_testcase) @@ -39,7 +39,7 @@ missingtests: missingcpptests missingctests +$(swig_and_compile_c) +$(run_testcase) -%.multicpptest: +%.multicpptest: $(setup) +$(swig_and_compile_multi_cpp) +$(run_testcase) diff --git a/Examples/test-suite/pike/Makefile.in b/Examples/test-suite/pike/Makefile.in index 389dc74f8..c1ebb747b 100644 --- a/Examples/test-suite/pike/Makefile.in +++ b/Examples/test-suite/pike/Makefile.in @@ -18,7 +18,7 @@ include $(srcdir)/../common.mk # none! # Rules for the different types of tests -%.cpptest: +%.cpptest: $(setup) +$(swig_and_compile_cpp) $(run_testcase) @@ -28,7 +28,7 @@ include $(srcdir)/../common.mk +$(swig_and_compile_c) $(run_testcase) -%.multicpptest: +%.multicpptest: $(setup) +$(swig_and_compile_multi_cpp) $(run_testcase) @@ -46,4 +46,3 @@ run_testcase = \ clean: $(MAKE) -f $(top_builddir)/$(EXAMPLES)/Makefile pike_clean - diff --git a/Examples/test-suite/python/Makefile.in b/Examples/test-suite/python/Makefile.in index e7db32fb7..389aed9ea 100644 --- a/Examples/test-suite/python/Makefile.in +++ b/Examples/test-suite/python/Makefile.in @@ -26,7 +26,7 @@ top_srcdir = @top_srcdir@ top_builddir = @top_builddir@ -PY2TO3 = 2to3 -x import +PY2TO3 = 2to3 -x import CPP_TEST_CASES += \ @@ -109,7 +109,7 @@ VALGRIND_OPT += --suppressions=pythonswig.supp # none! # Rules for the different types of tests -%.cpptest: +%.cpptest: +$(convert_testcase) $(setup) +$(swig_and_compile_cpp) @@ -121,7 +121,7 @@ VALGRIND_OPT += --suppressions=pythonswig.supp +$(swig_and_compile_c) $(run_testcase) -%.multicpptest: +%.multicpptest: +$(convert_testcase) $(setup) +$(swig_and_compile_multi_cpp) @@ -131,7 +131,7 @@ VALGRIND_OPT += --suppressions=pythonswig.supp # Call 2to3 to generate Python 3.x test from the Python 2.x's *_runme.py file %$(PY3SCRIPTSUFFIX): %$(PY2SCRIPTSUFFIX) cp $< $@ - $(PY2TO3) -w $@ >/dev/null 2>&1 + $(PY2TO3) -w $@ >/dev/null 2>&1 # Runs the testcase. A testcase is only run if @@ -172,12 +172,12 @@ clean: cvsignore: @echo '*wrap* *.pyc *.so *.dll *.exp *.lib' @echo Makefile - @for i in ${CPP_TEST_CASES} ${C_TEST_CASES}; do echo $$i.py; done - @for i in ${CPP_TEST_CASES} ${C_TEST_CASES}; do if grep -q $${i}_runme.py CVS/Entries ; then echo $${i}_runme.py; fi; done - @echo clientdata_prop_a.py - @echo clientdata_prop_b.py - @echo imports_a.py - @echo imports_b.py + @for i in ${CPP_TEST_CASES} ${C_TEST_CASES}; do echo $$i.py; done + @for i in ${CPP_TEST_CASES} ${C_TEST_CASES}; do if grep -q $${i}_runme.py CVS/Entries ; then echo $${i}_runme.py; fi; done + @echo clientdata_prop_a.py + @echo clientdata_prop_b.py + @echo imports_a.py + @echo imports_b.py @echo mod_a.py mod_b.py @echo hugemod.h hugemod_a.i hugemod_b.i hugemod_a.py hugemod_b.py hugemod_runme.py @echo template_typedef_import.py @@ -185,9 +185,8 @@ cvsignore: hugemod_runme = hugemod$(SCRIPTPREFIX) hugemod: - perl hugemod.pl $(hugemod_runme) + perl hugemod.pl $(hugemod_runme) $(MAKE) hugemod_a.cpptest $(MAKE) hugemod_b.cpptest sh -c "time $(PYTHON) $(hugemod_runme)" sh -c "time $(PYTHON) $(hugemod_runme)" - diff --git a/Examples/test-suite/r/Makefile.in b/Examples/test-suite/r/Makefile.in index 18e2d4b25..32d9b85da 100644 --- a/Examples/test-suite/r/Makefile.in +++ b/Examples/test-suite/r/Makefile.in @@ -28,7 +28,7 @@ include $(srcdir)/../common.mk # none! # Rules for the different types of tests -%.cpptest: +%.cpptest: $(setup) +$(swig_and_compile_cpp) $(run_testcase) @@ -38,14 +38,14 @@ include $(srcdir)/../common.mk +$(swig_and_compile_c) $(run_testcase) -%.multicpptest: +%.multicpptest: $(setup) +$(swig_and_compile_multi_cpp) $(run_multitestcase) # Runs the testcase. -# -# Run the runme if it exists. If not just load the R wrapper to +# +# Run the runme if it exists. If not just load the R wrapper to # check for syntactic correctness run_testcase = \ if [ -f $(srcdir)/$(SCRIPTPREFIX)$*$(SCRIPTSUFFIX) ]; then \ @@ -58,7 +58,7 @@ run_multitestcase = \ for f in `cat $(top_srcdir)/$(EXAMPLES)/$(TEST_SUITE)/$*.list` ; do \ if [ -f $(srcdir)/$(SCRIPTPREFIX)$${f}$(SCRIPTSUFFIX) ]; then \ env LD_LIBRARY_PATH=.:$$LD_LIBRARY_PATH PATH=.:"$$PATH" \ - $(RUNTOOL) $(RUNR) $(srcdir)/$(SCRIPTPREFIX)$${f}$(SCRIPTSUFFIX); \ + $(RUNTOOL) $(RUNR) $(srcdir)/$(SCRIPTPREFIX)$${f}$(SCRIPTSUFFIX); \ else \ $(RUNTOOL) $(RUNR) $(srcdir)/$(SCRIPTPREFIX)$${f}$(WRAPSUFFIX); \ fi; \ @@ -74,5 +74,3 @@ clean: rm -f $${f}.R $${f}.Rout ; \ done \ fi - - diff --git a/Examples/test-suite/ruby/Makefile.in b/Examples/test-suite/ruby/Makefile.in index ab366ccd4..40985e532 100644 --- a/Examples/test-suite/ruby/Makefile.in +++ b/Examples/test-suite/ruby/Makefile.in @@ -42,7 +42,7 @@ SWIGOPT += -w801 -noautorename -features autodoc=4 ruby_naming.cpptest: SWIGOPT += -autorename # Rules for the different types of tests -%.cpptest: +%.cpptest: $(setup) +$(swig_and_compile_cpp) $(run_testcase) @@ -52,7 +52,7 @@ ruby_naming.cpptest: SWIGOPT += -autorename +$(swig_and_compile_c) $(run_testcase) -%.multicpptest: +%.multicpptest: $(setup) +$(swig_and_compile_multi_cpp) $(run_testcase) @@ -66,7 +66,7 @@ run_testcase = \ # Clean %.clean: - + @exit 0 clean: $(MAKE) -f $(top_builddir)/$(EXAMPLES)/Makefile ruby_clean diff --git a/Examples/test-suite/tcl/Makefile.in b/Examples/test-suite/tcl/Makefile.in index 49d2a7826..6ab293fb9 100644 --- a/Examples/test-suite/tcl/Makefile.in +++ b/Examples/test-suite/tcl/Makefile.in @@ -4,7 +4,7 @@ LANGUAGE = tcl TCLSH = tclsh -SCRIPTSUFFIX = _runme.tcl +SCRIPTSUFFIX = _runme.tcl srcdir = @srcdir@ top_srcdir = @top_srcdir@ top_builddir = @top_builddir@ @@ -27,7 +27,7 @@ include $(srcdir)/../common.mk # none! # Rules for the different types of tests -%.cpptest: +%.cpptest: $(setup) +$(swig_and_compile_cpp) $(run_testcase) @@ -37,7 +37,7 @@ include $(srcdir)/../common.mk +$(swig_and_compile_c) $(run_testcase) -%.multicpptest: +%.multicpptest: $(setup) +$(swig_and_compile_multi_cpp) $(run_testcase) @@ -51,7 +51,7 @@ run_testcase = \ # Clean %.clean: - + @exit 0 clean: $(MAKE) -f $(top_builddir)/$(EXAMPLES)/Makefile tcl_clean diff --git a/Examples/test-suite/uffi/Makefile.in b/Examples/test-suite/uffi/Makefile.in index 8ad153961..5fd000a96 100644 --- a/Examples/test-suite/uffi/Makefile.in +++ b/Examples/test-suite/uffi/Makefile.in @@ -14,13 +14,13 @@ include $(srcdir)/../common.mk # Overridden variables here # no C++ tests for now CPP_TEST_CASES = -#C_TEST_CASES += +#C_TEST_CASES += # Custom tests - tests with additional commandline options # none! # Rules for the different types of tests -%.cpptest: +%.cpptest: $(setup) +$(swig_and_compile_cpp) $(run_testcase) @@ -30,7 +30,7 @@ CPP_TEST_CASES = +$(swig_and_compile_c) $(run_testcase) -%.multicpptest: +%.multicpptest: $(setup) +$(swig_and_compile_multi_cpp) $(run_testcase) @@ -44,8 +44,7 @@ run_testcase = \ # Clean: (does nothing, we dont generate extra uffi code) %.clean: - + @exit 0 clean: $(MAKE) -f $(top_builddir)/$(EXAMPLES)/Makefile uffi_clean - diff --git a/Lib/guile/Makefile b/Lib/guile/Makefile index 17f5feced..fba7fd5d3 100644 --- a/Lib/guile/Makefile +++ b/Lib/guile/Makefile @@ -1,4 +1,3 @@ co: co RCS/*.i* RCS/*.swg* - diff --git a/Lib/mzscheme/Makefile b/Lib/mzscheme/Makefile index 17f5feced..fba7fd5d3 100644 --- a/Lib/mzscheme/Makefile +++ b/Lib/mzscheme/Makefile @@ -1,4 +1,3 @@ co: co RCS/*.i* RCS/*.swg* - diff --git a/Lib/perl5/Makefile.in b/Lib/perl5/Makefile.in index 1fee86ccc..e0b3b74b8 100644 --- a/Lib/perl5/Makefile.in +++ b/Lib/perl5/Makefile.in @@ -1,6 +1,6 @@ # --------------------------------------------------------------- # SWIG Perl5 Makefile -# +# # This file can be used to build various Perl5 extensions with SWIG. # By default this file is set up for dynamic loading, but it can # be easily customized for static extensions by modifying various @@ -17,11 +17,11 @@ # script and should already reflect your machine. #---------------------------------------------------------------- -SRCS = -CXXSRCS = -OBJCSRCS = -OBJS = -INTERFACE = +SRCS = +CXXSRCS = +OBJCSRCS = +OBJS = +INTERFACE = WRAPFILE = $(INTERFACE:.i=_wrap.c) WRAPOBJ = $(INTERFACE:.i=_wrap.o) TARGET = module@SO@ # Use this kind of target for dynamic loading @@ -32,8 +32,8 @@ exec_prefix = @exec_prefix@ CC = @CC@ CXX = @CXX@ -OBJC = @CC@ -Wno-import # -Wno-import needed for gcc -CFLAGS = +OBJC = @CC@ -Wno-import # -Wno-import needed for gcc +CFLAGS = INCLUDES = LIBS = @@ -42,9 +42,9 @@ LIBS = # SWIGOPT = SWIG compiler options # SWIGCC = Compiler used to compile the wrapper file -SWIG = $(exec_prefix)/bin/swig -SWIGOPT = -perl5 -SWIGCC = $(CC) +SWIG = $(exec_prefix)/bin/swig +SWIGOPT = -perl5 +SWIGCC = $(CC) # SWIG Library files. Uncomment this to statically rebuild Perl #SWIGLIBS = -static -lperlmain.i @@ -67,12 +67,12 @@ BUILD = @LDSHARED@ # need to provide additional link libraries (this is not always required). #DLL_LIBS = -L/usr/local/lib/gcc-lib/sparc-sun-solaris2.5.1/2.7.2 \ - -L/usr/local/lib -lg++ -lstdc++ -lgcc + -L/usr/local/lib -lg++ -lstdc++ -lgcc # Perl installation PERL_INCLUDE = -I@PERL5EXT@ -PERL_LIB = -L@PERL5EXT@ -lperl +PERL_LIB = -L@PERL5EXT@ -lperl PERL_FLAGS = -Dbool=char -Dexplicit= # Build libraries (needed for static builds) @@ -118,9 +118,3 @@ $(TARGET): $(WRAPOBJ) $(ALLOBJS) clean: rm -f $(COBJS) $(CXXOBJS) $(OBJCOBJS) $(WRAPOBJ) $(WRAPFILE) $(TARGET) - - - - - - diff --git a/Lib/perl5/Makefile.pl b/Lib/perl5/Makefile.pl index 05240f1e9..cffdc8e79 100644 --- a/Lib/perl5/Makefile.pl +++ b/Lib/perl5/Makefile.pl @@ -7,7 +7,7 @@ # 2. Run perl as 'perl Makefile.pl' # 3. Type 'make' to build your module # 4. Type 'make install' to install your module. -# +# # See "Programming Perl", 2nd. Ed, for more gory details than # you ever wanted to know. @@ -17,5 +17,3 @@ WriteMakefile( 'LIBS' => [''], # Custom libraries (if any) 'OBJECT' => '$module_wrap.o' # Object files ); - - diff --git a/Lib/python/Makefile.in b/Lib/python/Makefile.in index 71effea70..27c384449 100644 --- a/Lib/python/Makefile.in +++ b/Lib/python/Makefile.in @@ -1,6 +1,6 @@ # --------------------------------------------------------------- # SWIG Python Makefile -# +# # This file can be used to build various Python extensions with SWIG. # By default this file is set up for dynamic loading, but it can # be easily customized for static extensions by modifying various @@ -17,11 +17,11 @@ # script and should already reflect your machine. #---------------------------------------------------------------- -SRCS = -CXXSRCS = -OBJCSRCS = -OBJS = -INTERFACE = +SRCS = +CXXSRCS = +OBJCSRCS = +OBJS = +INTERFACE = WRAPFILE = $(INTERFACE:.i=_wrap.c) WRAPOBJ = $(INTERFACE:.i=_wrap.o) TARGET = module@SO@ # Use this kind of target for dynamic loading @@ -32,8 +32,8 @@ exec_prefix = @exec_prefix@ CC = @CC@ CXX = @CXX@ -OBJC = @CC@ -Wno-import # -Wno-import needed for gcc -CFLAGS = +OBJC = @CC@ -Wno-import # -Wno-import needed for gcc +CFLAGS = INCLUDES = LIBS = @@ -42,9 +42,9 @@ LIBS = # SWIGOPT = SWIG compiler options # SWIGCC = Compiler used to compile the wrapper file -SWIG = $(exec_prefix)/bin/swig -SWIGOPT = -python -SWIGCC = $(CC) +SWIG = $(exec_prefix)/bin/swig +SWIGOPT = -python +SWIGCC = $(CC) # SWIG Library files. Uncomment if rebuilding the Python interpreter #SWIGLIBS = -lembed.i @@ -67,11 +67,11 @@ BUILD = @LDSHARED@ # need to provide additional link libraries (this is not always required). #DLL_LIBS = -L/usr/local/lib/gcc-lib/sparc-sun-solaris2.5.1/2.7.2 \ - -L/usr/local/lib -lg++ -lstdc++ -lgcc + -L/usr/local/lib -lg++ -lstdc++ -lgcc # Python installation -PY_INCLUDE = -DHAVE_CONFIG_H @PYINCLUDE@ +PY_INCLUDE = -DHAVE_CONFIG_H @PYINCLUDE@ PY_LIB = @PYLIB@ # Build libraries (needed for static builds) @@ -107,7 +107,7 @@ all: $(TARGET) # Convert the wrapper file into an object file $(WRAPOBJ) : $(WRAPFILE) - $(SWIGCC) -c $(CCSHARED) $(CFLAGS) $(WRAPFILE) $(INCLUDES) $(PY_INCLUDE) + $(SWIGCC) -c $(CCSHARED) $(CFLAGS) $(WRAPFILE) $(INCLUDES) $(PY_INCLUDE) $(WRAPFILE) : $(INTERFACE) $(SWIG) $(SWIGOPT) -o $(WRAPFILE) $(SWIGLIBS) $(INTERFACE) @@ -117,7 +117,3 @@ $(TARGET): $(WRAPOBJ) $(ALLOBJS) clean: rm -f $(COBJS) $(CXXOBJS) $(OBJCOBJS) $(WRAPOBJ) $(WRAPFILE) $(TARGET) - - - - diff --git a/Lib/ruby/Makefile.swig b/Lib/ruby/Makefile.swig index a7f3ae3d2..648b32134 100644 --- a/Lib/ruby/Makefile.swig +++ b/Lib/ruby/Makefile.swig @@ -7,7 +7,7 @@ # 3. Type 'make -f Makefile.swig' to generate wrapper code and Makefile. # 4. Type 'make' to build your extension. # 5. Type 'make install' to install your extension. -# +# MODULE = yourmodule FEATURE = $(MODULE) diff --git a/Lib/tcl/Makefile.in b/Lib/tcl/Makefile.in index 2ab0f7b01..13d7d4653 100644 --- a/Lib/tcl/Makefile.in +++ b/Lib/tcl/Makefile.in @@ -1,10 +1,10 @@ # --------------------------------------------------------------- # SWIG Tcl Makefile -# +# # This file can be used to build various Tcl extensions with SWIG. # By default this file is set up for dynamic loading, but it can # be easily customized for static extensions by modifying various -# portions of the file. +# portions of the file. # # SRCS = C source files # CXXSRCS = C++ source files @@ -19,11 +19,11 @@ # application. #---------------------------------------------------------------- -SRCS = -CXXSRCS = -OBJCSRCS = -OBJS = -INTERFACE = +SRCS = +CXXSRCS = +OBJCSRCS = +OBJS = +INTERFACE = WRAPFILE = $(INTERFACE:.i=_wrap.c) WRAPOBJ = $(INTERFACE:.i=_wrap.o) TARGET = module@SO@ # Use this kind of target for dynamic loading @@ -34,8 +34,8 @@ exec_prefix = @exec_prefix@ CC = @CC@ CXX = @CXX@ -OBJC = @CC@ -Wno-import # -Wno-import needed for gcc -CFLAGS = +OBJC = @CC@ -Wno-import # -Wno-import needed for gcc +CFLAGS = INCLUDES = LIBS = @@ -44,9 +44,9 @@ LIBS = # SWIGOPT = SWIG compiler options # SWIGCC = Compiler used to compile the wrapper file -SWIG = $(exec_prefix)/bin/swig +SWIG = $(exec_prefix)/bin/swig SWIGOPT = -tcl # use -tcl8 for Tcl 8.0 -SWIGCC = $(CC) +SWIGCC = $(CC) # SWIG Library files. Uncomment if rebuilding tclsh #SWIGLIBS = -ltclsh.i @@ -69,7 +69,7 @@ BUILD = @LDSHARED@ # need to provide additional link libraries (this is not always required). #DLL_LIBS = -L/usr/local/lib/gcc-lib/sparc-sun-solaris2.5.1/2.7.2 \ - -L/usr/local/lib -lg++ -lstdc++ -lgcc + -L/usr/local/lib -lg++ -lstdc++ -lgcc # Tcl installation (where is Tcl located) @@ -85,7 +85,7 @@ SYSLIBS = $(LIBM) $(LIBC) @LIBS@ # Build options (uncomment only one of these) BUILD_LIBS = $(LIBS) # Dynamic loading -#BUILD_LIBS = $(TCL_LIB) -ltcl $(LIBS) $(SYSLIBS) # tclsh +#BUILD_LIBS = $(TCL_LIB) -ltcl $(LIBS) $(SYSLIBS) # tclsh # Compilation rules for non-SWIG components @@ -110,7 +110,7 @@ all: $(TARGET) # Convert the wrapper file into an object file $(WRAPOBJ) : $(WRAPFILE) - $(SWIGCC) -c $(CCSHARED) $(CFLAGS) $(WRAPFILE) $(INCLUDES) $(TCL_INCLUDE) + $(SWIGCC) -c $(CCSHARED) $(CFLAGS) $(WRAPFILE) $(INCLUDES) $(TCL_INCLUDE) $(WRAPFILE) : $(INTERFACE) $(SWIG) $(SWIGOPT) -o $(WRAPFILE) $(SWIGLIBS) $(INTERFACE) @@ -120,7 +120,3 @@ $(TARGET): $(WRAPOBJ) $(ALLOBJS) clean: rm -f $(COBJS) $(CXXOBJS) $(OBJCOBJS) $(WRAPOBJ) $(WRAPFILE) $(TARGET) - - - - diff --git a/Makefile.in b/Makefile.in index f4d0be077..2eb1326ea 100644 --- a/Makefile.in +++ b/Makefile.in @@ -249,8 +249,8 @@ check-%-examples : # gcj individual example java.actionexample: @if $(skip-gcj); then \ - echo "skipping Examples/$(LANGUAGE)/java $(ACTION) (gcj test)"; \ - else \ + echo "skipping Examples/$(LANGUAGE)/java $(ACTION) (gcj test)"; \ + else \ echo $(ACTION)ing Examples/$(LANGUAGE)/java; \ (cd Examples/$(LANGUAGE)/java && $(MAKE) $(FLAGS) $(chk-set-env) $(ACTION)) \ fi @@ -481,13 +481,13 @@ lib-languages = gcj typemaps tcl perl5 python guile java mzscheme ruby php ocaml lib-modules = std -install-lib: +install-lib: @echo "Installing the SWIG library" @$(MKINSTDIRS) $(DESTDIR)$(SWIG_LIB) @for file in $(srcdir)/Lib/*.i $(srcdir)/Lib/*.swg ; do \ i=`basename $$file` ; \ echo "Installing $(DESTDIR)$(SWIG_LIB)/$$i"; \ - $(INSTALL_DATA) $$file $(DESTDIR)$(SWIG_LIB)/$$i; \ + $(INSTALL_DATA) $$file $(DESTDIR)$(SWIG_LIB)/$$i; \ done; @for lang in $(lib-languages) $(lib-modules); \ do \ diff --git a/Source/Makefile.am b/Source/Makefile.am index 9e02e37f0..d5331cba1 100644 --- a/Source/Makefile.am +++ b/Source/Makefile.am @@ -90,7 +90,7 @@ eswig_SOURCES = CParse/cscanner.c \ Swig/typeobj.c \ Swig/typemap.c \ Swig/typesys.c \ - Swig/wrapfunc.c + Swig/wrapfunc.c bin_PROGRAMS = eswig eswig_LDADD = @SWIGLIBS@ @@ -99,7 +99,7 @@ eswig_LDADD = @SWIGLIBS@ CXXLINK = $(CXXLD) $(AM_CXXFLAGS) $(CXXFLAGS) $(AM_LDFLAGS) $(LDFLAGS) -o $@ # The executable is copied to the root directory for installation and running the test-suite. -# This occurs on each invocation of make and is a step towards providing support for multiple +# This occurs on each invocation of make and is a step towards providing support for multiple # build directories. all-local: eswig@EXEEXT@ cp -f $(top_builddir)/Source/eswig@EXEEXT@ $(top_builddir)/swig@EXEEXT@ @@ -145,4 +145,3 @@ beautify-file: indent -kr --honour-newlines --line-length160 --indent-level2 --braces-on-func-def-line --leave-optional-blank-lines $(SWIGTYPEDEFS) $(INDENTFILE) -o $(INDENTFILE).tmp; cat $(INDENTFILE).tmp | sed -e 's/const const /const /' > $(INDENTFILE); rm $(INDENTFILE).tmp; - -- cgit v1.2.1 From b6c1889c0891bebcbfd0256d445792a85de8cc91 Mon Sep 17 00:00:00 2001 From: Karl Wette Date: Thu, 24 Apr 2014 21:25:40 +0200 Subject: Fix {python|perl5|ruby|tcl}/java examples - in Lib/gcj/cni.i: remove JvAllocObject(), change JvCreateJavaVM() argument from void* to JvVMInitArgs* - in Examples/{python|perl5|ruby|tcl}/java/Makefile: pass full class name to gcjh, add Example.h as dependency, do not override CXX for compiling C++ sources - in Examples/python/java/example.i: add destructor to class to prevent memory loss complaint --- CHANGES.current | 18 ++++++++++++++++++ Examples/perl5/check.list | 1 + Examples/perl5/java/Makefile | 8 ++++---- Examples/python/java/Makefile | 9 +++++---- Examples/python/java/example.i | 4 ++++ Examples/ruby/java/Makefile | 8 ++++---- Examples/tcl/java/Makefile | 13 +++++-------- Lib/gcj/cni.i | 6 +----- Makefile.in | 2 +- 9 files changed, 43 insertions(+), 26 deletions(-) diff --git a/CHANGES.current b/CHANGES.current index 826b1a2c5..869f37785 100644 --- a/CHANGES.current +++ b/CHANGES.current @@ -8,6 +8,24 @@ Version 3.0.1 (in progress) 2014-05-01: olly [PHP] The generated __isset() method now returns true for read-only properties. +2014-04-24: kwwette + Fix {python|perl5|ruby|tcl}/java examples + + In Lib/gcj/cni.i, for compatibility with newer gcj versions: + + - remove JvAllocObject() which gcj no longer defines, from gcj Changelog: + 2004-04-16 Bryce McKinlay + * gcj/cni.h (JvAllocObject): Remove these obsolete, + undocumented CNI calls. + + - change JvCreateJavaVM() argument from void* to JvVMInitArgs*, from gcj Changelog: + 2005-02-23 Thomas Fitzsimmons + PR libgcj/16923 + ... + (JvCreateJavaVM): Declare vm_args as JvVMInitArgs* rather than void*. + + *** POTENTIAL INCOMPATIBILITY *** + 2014-04-08: wsfulton SF Bug #1366 - Remove duplicate declarations of strtoimax and strtoumax in inttypes.i diff --git a/Examples/perl5/check.list b/Examples/perl5/check.list index 78d45fc0b..dda849311 100644 --- a/Examples/perl5/check.list +++ b/Examples/perl5/check.list @@ -6,6 +6,7 @@ constants2 extend funcptr import +java multimap multiple_inheritance pointer diff --git a/Examples/perl5/java/Makefile b/Examples/perl5/java/Makefile index ff3aab0e7..3a0bb215d 100644 --- a/Examples/perl5/java/Makefile +++ b/Examples/perl5/java/Makefile @@ -8,15 +8,15 @@ LIBS = -lm check: build $(MAKE) -f $(TOP)/Makefile perl5_run -build: Example.class +build: Example.class Example.h $(MAKE) -f $(TOP)/Makefile CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ - TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' CXX="gcj" \ + TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' \ CXXSHARED="gcj -fpic -shared Example.class" PERL5_CCFLAGS='' PERL5_EXP='' LIBS="-lstdc++" perl5_cpp clean: $(MAKE) -f $(TOP)/Makefile perl5_clean rm -f *.class Example.h -Example.class: Example.java +Example.class Example.h: Example.java gcj -fPIC -C -c -g Example.java - gcjh Example + gcjh Example.class diff --git a/Examples/python/java/Makefile b/Examples/python/java/Makefile index 12a9b512a..2ce219969 100644 --- a/Examples/python/java/Makefile +++ b/Examples/python/java/Makefile @@ -6,10 +6,11 @@ INTERFACE = example.i LIBS = -lm check: build + $(MAKE) -f $(TOP)/Makefile python_run -build: Example.class +build: Example.class Example.h $(MAKE) -f $(TOP)/Makefile CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ - TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' CXX="gcj" \ + TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' \ CXXSHARED="gcj -fpic -shared Example.class" DEFS='' LIBS="-lstdc++" python_cpp clean: @@ -17,6 +18,6 @@ clean: rm -f $(TARGET).py rm -f *.class Example.h -Example.class: Example.java +Example.class Example.h: Example.java gcj -fPIC -C -c -g Example.java - gcjh Example + gcjh Example.class diff --git a/Examples/python/java/example.i b/Examples/python/java/example.i index 13d5b5e70..80e08870f 100644 --- a/Examples/python/java/example.i +++ b/Examples/python/java/example.i @@ -7,3 +7,7 @@ %include Example.h + +%extend Example { + ~Example() {} +} diff --git a/Examples/ruby/java/Makefile b/Examples/ruby/java/Makefile index 4d2493493..a71635baa 100644 --- a/Examples/ruby/java/Makefile +++ b/Examples/ruby/java/Makefile @@ -8,15 +8,15 @@ LIBS = -lm check: build $(MAKE) -f $(TOP)/Makefile ruby_run -build: Example.class +build: Example.class Example.h $(MAKE) -f $(TOP)/Makefile CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ - TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' CXX="gcj" \ + TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' \ CXXSHARED="gcj -fpic -shared Example.class" LIBS="-lstdc++" DEFS='' ruby_cpp clean: $(MAKE) -f $(TOP)/Makefile ruby_clean rm -f *.class Example.h -Example.class: Example.java +Example.class Example.h: Example.java gcj -fPIC -C -c -g Example.java - gcjh Example + gcjh Example.class diff --git a/Examples/tcl/java/Makefile b/Examples/tcl/java/Makefile index 3a9212381..a3819ab7c 100644 --- a/Examples/tcl/java/Makefile +++ b/Examples/tcl/java/Makefile @@ -8,18 +8,15 @@ LIBS = -lm check: build $(MAKE) -f $(TOP)/Makefile tcl_run -build: Example.class +build: Example.class Example.h $(MAKE) -f $(TOP)/Makefile CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ - TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' CXX="gcj" \ - TCL_CXXSHARED="gcj -fpic -shared Example.class " LIBS="-lstdc++" DEFS='' tcl_cpp + TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' \ + TCLCXXSHARED="gcj -fpic -shared Example.class " LIBS="-lstdc++" DEFS='' tcl_cpp clean: $(MAKE) -f $(TOP)/Makefile tcl_clean rm -f *.class Example.h -run: - tclsh runme.tcl - -Example.class: Example.java +Example.class Example.h: Example.java gcj -fPIC -C -c -g Example.java - gcjh Example + gcjh Example.class diff --git a/Lib/gcj/cni.i b/Lib/gcj/cni.i index b12148e91..fcc56687a 100644 --- a/Lib/gcj/cni.i +++ b/Lib/gcj/cni.i @@ -4,10 +4,6 @@ %include -extern jobject JvAllocObject (jclass cls); - -extern jobject JvAllocObject (jclass cls, jsize sz); - extern void JvInitClass (jclass cls); extern jstring JvAllocString (jsize sz); @@ -30,7 +26,7 @@ extern void *JvMalloc (jsize size); extern void JvFree (void *ptr); -extern jint JvCreateJavaVM (void* vm_args); +extern jint JvCreateJavaVM (JvVMInitArgs* vm_args); extern java::lang::Thread* JvAttachCurrentThread (jstring name, java::lang::ThreadGroup* group); diff --git a/Makefile.in b/Makefile.in index 2eb1326ea..06e4724c7 100644 --- a/Makefile.in +++ b/Makefile.in @@ -252,7 +252,7 @@ java.actionexample: echo "skipping Examples/$(LANGUAGE)/java $(ACTION) (gcj test)"; \ else \ echo $(ACTION)ing Examples/$(LANGUAGE)/java; \ - (cd Examples/$(LANGUAGE)/java && $(MAKE) $(FLAGS) $(chk-set-env) $(ACTION)) \ + (cd Examples/$(LANGUAGE)/java && $(MAKE) $(FLAGS) $(chk-set-env) $(ACTION) RUNPIPE=$(RUNPIPE)) \ fi # Checks testcases in the test-suite excluding those which are known to be broken -- cgit v1.2.1 From 66555ad2a7f8a0cfad9fff16fcace79346af8033 Mon Sep 17 00:00:00 2001 From: Karl Wette Date: Fri, 25 Apr 2014 00:12:06 +0200 Subject: Fix go configuration and SWIG_GCC_VERSION - in configure.ac: modify sed expression to only look at first line of gccgo --version, extract the last numeric token, and remove periods; this parses e.g. "gccgo (Debian 4.7.2-5) 4.7.2" - in goruntime.swg: fix typo in __GNUC_PATCHLEVEL__ (SF Bug #1298) --- CHANGES.current | 4 ++++ Lib/go/goruntime.swg | 2 +- configure.ac | 8 ++++++-- 3 files changed, 11 insertions(+), 3 deletions(-) diff --git a/CHANGES.current b/CHANGES.current index 869f37785..8b67392b2 100644 --- a/CHANGES.current +++ b/CHANGES.current @@ -8,6 +8,10 @@ Version 3.0.1 (in progress) 2014-05-01: olly [PHP] The generated __isset() method now returns true for read-only properties. +2014-04-24: kwwette + [Go] Fix go ./configure parsing of gccgo --version, and + goruntime.swg typo in __GNUC_PATCHLEVEL__ (SF Bug #1298) + 2014-04-24: kwwette Fix {python|perl5|ruby|tcl}/java examples diff --git a/Lib/go/goruntime.swg b/Lib/go/goruntime.swg index 612f83086..bbc602b0d 100644 --- a/Lib/go/goruntime.swg +++ b/Lib/go/goruntime.swg @@ -116,7 +116,7 @@ extern void _cgo_panic(const char *); file is the same as the version of gccgo. */ #define SWIG_GCC_VERSION \ - (__GNUC__ * 10000 + __GNUC_MINOR__ * 100 + __GNUC__PATH_LEVEL__) + (__GNUC__ * 10000 + __GNUC_MINOR__ * 100 + __GNUC_PATCHLEVEL__) #if SWIG_GCC_VERSION < 40700 #define SwigDoCgocall() diff --git a/configure.ac b/configure.ac index 091749f53..d83e0d31b 100644 --- a/configure.ac +++ b/configure.ac @@ -2266,9 +2266,13 @@ else GOGCC=true GOVERSIONOPTION=--version AC_MSG_CHECKING([whether gccgo version is too old]) - go_version=`$GO $GOVERSIONOPTION | sed -e 's/[^0-9]* \([0-9.]*\) .*$/\1/' -e 's/[.]//g'` - if test "$go_version" -lt 470; then + go_version=[`$GO $GOVERSIONOPTION | sed -n '1p' | sed -e 's/^.* \([0-9.]*\) *$/\1/' -e 's/[.]//g'`] + if test "x$go_version" = x; then + AC_MSG_RESULT([could not determine gccgo version - disabling Go]) + GO= + elif test "$go_version" -lt 470; then AC_MSG_RESULT([yes - minimum version is 4.7.0]) + GO= else AC_MSG_RESULT([no]) if test "$go_version" -lt 480; then -- cgit v1.2.1 From b79646ce4c649c838aa848674cdea5a83fb77694 Mon Sep 17 00:00:00 2001 From: Pingan Yi Date: Sun, 4 May 2014 19:10:44 +0800 Subject: Patch of http://sourceforge.net/p/swig/mailman/message/29816385 --- Lib/java/director.swg | 7 +++++++ Lib/java/java.swg | 2 ++ 2 files changed, 9 insertions(+) diff --git a/Lib/java/director.swg b/Lib/java/director.swg index 819ad903d..7f0fd3933 100644 --- a/Lib/java/director.swg +++ b/Lib/java/director.swg @@ -380,5 +380,12 @@ namespace Swig { return matches; } + class LocalRefGuard { + JNIEnv* jenv_; + jobject jobj_; + public: + LocalRefGuard(JNIEnv* jenv, jobject jobj): jenv_(jenv), jobj_(jobj) {} + ~LocalRefGuard() { if (jobj_) jenv_->DeleteLocalRef(jobj_); } + }; } diff --git a/Lib/java/java.swg b/Lib/java/java.swg index 3d4d83730..3ad0e7aba 100644 --- a/Lib/java/java.swg +++ b/Lib/java/java.swg @@ -405,6 +405,7 @@ SWIGINTERN const char * SWIG_UnpackData(const char *c, void *ptr, size_t sz) { $input = JCALL1(NewStringUTF, jenv, (const char *)$1); if (!$input) return $null; } + Swig::LocalRefGuard refGuard_$input(jenv, $input); } %typemap(freearg, noblock=1) char * { if ($1) JCALL2(ReleaseStringUTFChars, jenv, $input, (const char *)$1); } @@ -731,6 +732,7 @@ SWIGINTERN const char * SWIG_UnpackData(const char *c, void *ptr, size_t sz) { $input = JCALL1(NewStringUTF, jenv, (const char *)$1); if (!$input) return $null; } + Swig::LocalRefGuard refGuard_$input(jenv, $input); } %typemap(argout) char[ANY], char[] "" -- cgit v1.2.1 From 7cac2d35cb53f003ddb14fb0ac93753fea027da3 Mon Sep 17 00:00:00 2001 From: Olly Betts Date: Mon, 5 May 2014 16:04:37 +1200 Subject: Remove random extra assignment in example code --- Examples/lua/class/runme.lua | 1 - 1 file changed, 1 deletion(-) diff --git a/Examples/lua/class/runme.lua b/Examples/lua/class/runme.lua index 2c3ad8ced..5d140defe 100644 --- a/Examples/lua/class/runme.lua +++ b/Examples/lua/class/runme.lua @@ -53,7 +53,6 @@ print("\nGuess I'll clean up now") -- Note: this invokes the virtual destructor c=nil s=nil -s = 3 -- call gc to make sure they are collected collectgarbage() -- cgit v1.2.1 From b115c984a97e5f20e9ad5979f1ad606fff549bc3 Mon Sep 17 00:00:00 2001 From: Olly Betts Date: Mon, 5 May 2014 16:14:31 +1200 Subject: More cleaning up of the class examples --- Examples/chicken/class/example.cxx | 10 +++++----- Examples/csharp/class/example.cxx | 10 +++++----- Examples/d/class/example.cxx | 10 +++++----- Examples/go/class/class.cxx | 10 +++++----- Examples/go/class/index.html | 8 ++++---- Examples/guile/class/example.cxx | 10 +++++----- Examples/javascript/class/example.cxx | 12 ++++++------ Examples/javascript/class/example.h | 18 +++++++++--------- Examples/javascript/class/example.i | 1 - Examples/lua/class/example.cxx | 10 +++++----- Examples/modula3/class/example.cxx | 10 +++++----- Examples/octave/class/example.cxx | 10 +++++----- Examples/r/class/example.cxx | 10 +++++----- 13 files changed, 64 insertions(+), 65 deletions(-) diff --git a/Examples/chicken/class/example.cxx b/Examples/chicken/class/example.cxx index 1e8e203dd..046304519 100644 --- a/Examples/chicken/class/example.cxx +++ b/Examples/chicken/class/example.cxx @@ -1,4 +1,4 @@ -/* File : example.c */ +/* File : example.cxx */ #include "example.h" #define M_PI 3.14159265358979323846 @@ -11,18 +11,18 @@ void Shape::move(double dx, double dy) { int Shape::nshapes = 0; -double Circle::area(void) { +double Circle::area() { return M_PI*radius*radius; } -double Circle::perimeter(void) { +double Circle::perimeter() { return 2*M_PI*radius; } -double Square::area(void) { +double Square::area() { return width*width; } -double Square::perimeter(void) { +double Square::perimeter() { return 4*width; } diff --git a/Examples/csharp/class/example.cxx b/Examples/csharp/class/example.cxx index 1e8e203dd..046304519 100644 --- a/Examples/csharp/class/example.cxx +++ b/Examples/csharp/class/example.cxx @@ -1,4 +1,4 @@ -/* File : example.c */ +/* File : example.cxx */ #include "example.h" #define M_PI 3.14159265358979323846 @@ -11,18 +11,18 @@ void Shape::move(double dx, double dy) { int Shape::nshapes = 0; -double Circle::area(void) { +double Circle::area() { return M_PI*radius*radius; } -double Circle::perimeter(void) { +double Circle::perimeter() { return 2*M_PI*radius; } -double Square::area(void) { +double Square::area() { return width*width; } -double Square::perimeter(void) { +double Square::perimeter() { return 4*width; } diff --git a/Examples/d/class/example.cxx b/Examples/d/class/example.cxx index 1e8e203dd..046304519 100644 --- a/Examples/d/class/example.cxx +++ b/Examples/d/class/example.cxx @@ -1,4 +1,4 @@ -/* File : example.c */ +/* File : example.cxx */ #include "example.h" #define M_PI 3.14159265358979323846 @@ -11,18 +11,18 @@ void Shape::move(double dx, double dy) { int Shape::nshapes = 0; -double Circle::area(void) { +double Circle::area() { return M_PI*radius*radius; } -double Circle::perimeter(void) { +double Circle::perimeter() { return 2*M_PI*radius; } -double Square::area(void) { +double Square::area() { return width*width; } -double Square::perimeter(void) { +double Square::perimeter() { return 4*width; } diff --git a/Examples/go/class/class.cxx b/Examples/go/class/class.cxx index 1e8e203dd..f87c7ec8f 100644 --- a/Examples/go/class/class.cxx +++ b/Examples/go/class/class.cxx @@ -1,4 +1,4 @@ -/* File : example.c */ +/* File : class.cxx */ #include "example.h" #define M_PI 3.14159265358979323846 @@ -11,18 +11,18 @@ void Shape::move(double dx, double dy) { int Shape::nshapes = 0; -double Circle::area(void) { +double Circle::area() { return M_PI*radius*radius; } -double Circle::perimeter(void) { +double Circle::perimeter() { return 2*M_PI*radius; } -double Square::area(void) { +double Square::area() { return width*width; } -double Square::perimeter(void) { +double Square::perimeter() { return 4*width; } diff --git a/Examples/go/class/index.html b/Examples/go/class/index.html index b39119d12..df93b5672 100644 --- a/Examples/go/class/index.html +++ b/Examples/go/class/index.html @@ -33,8 +33,8 @@ public: } virtual ~Shape() { nshapes--; - }; - double x, y; + } + double x, y; void move(double dx, double dy); virtual double area() = 0; virtual double perimeter() = 0; @@ -45,7 +45,7 @@ class Circle : public Shape { private: double radius; public: - Circle(double r) : radius(r) { }; + Circle(double r) : radius(r) { } virtual double area(); virtual double perimeter(); }; @@ -54,7 +54,7 @@ class Square : public Shape { private: double width; public: - Square(double w) : width(w) { }; + Square(double w) : width(w) { } virtual double area(); virtual double perimeter(); }; diff --git a/Examples/guile/class/example.cxx b/Examples/guile/class/example.cxx index 1e8e203dd..046304519 100644 --- a/Examples/guile/class/example.cxx +++ b/Examples/guile/class/example.cxx @@ -1,4 +1,4 @@ -/* File : example.c */ +/* File : example.cxx */ #include "example.h" #define M_PI 3.14159265358979323846 @@ -11,18 +11,18 @@ void Shape::move(double dx, double dy) { int Shape::nshapes = 0; -double Circle::area(void) { +double Circle::area() { return M_PI*radius*radius; } -double Circle::perimeter(void) { +double Circle::perimeter() { return 2*M_PI*radius; } -double Square::area(void) { +double Square::area() { return width*width; } -double Square::perimeter(void) { +double Square::perimeter() { return 4*width; } diff --git a/Examples/javascript/class/example.cxx b/Examples/javascript/class/example.cxx index e23fa6f73..046304519 100644 --- a/Examples/javascript/class/example.cxx +++ b/Examples/javascript/class/example.cxx @@ -1,5 +1,5 @@ -/* File : example.c */ -#include +/* File : example.cxx */ + #include "example.h" #define M_PI 3.14159265358979323846 @@ -11,18 +11,18 @@ void Shape::move(double dx, double dy) { int Shape::nshapes = 0; -double Circle::area(void) { +double Circle::area() { return M_PI*radius*radius; } -double Circle::perimeter(void) { +double Circle::perimeter() { return 2*M_PI*radius; } -double Square::area(void) { +double Square::area() { return width*width; } -double Square::perimeter(void) { +double Square::perimeter() { return 4*width; } diff --git a/Examples/javascript/class/example.h b/Examples/javascript/class/example.h index 64b7684fa..642130cd0 100644 --- a/Examples/javascript/class/example.h +++ b/Examples/javascript/class/example.h @@ -7,11 +7,11 @@ public: } virtual ~Shape() { nshapes--; - }; + } double x, y; void move(double dx, double dy); - virtual double area(void) = 0; - virtual double perimeter(void) = 0; + virtual double area() = 0; + virtual double perimeter() = 0; static int nshapes; }; @@ -19,16 +19,16 @@ class Circle : public Shape { private: double radius; public: - Circle(double r) : radius(r) { }; - virtual double area(void); - virtual double perimeter(void); + Circle(double r) : radius(r) { } + virtual double area(); + virtual double perimeter(); }; class Square : public Shape { private: double width; public: - Square(double w) : width(w) { }; - virtual double area(void); - virtual double perimeter(void); + Square(double w) : width(w) { } + virtual double area(); + virtual double perimeter(); }; diff --git a/Examples/javascript/class/example.i b/Examples/javascript/class/example.i index 75700b305..fbdf7249f 100644 --- a/Examples/javascript/class/example.i +++ b/Examples/javascript/class/example.i @@ -7,4 +7,3 @@ /* Let's just grab the original header file here */ %include "example.h" - diff --git a/Examples/lua/class/example.cxx b/Examples/lua/class/example.cxx index 1e8e203dd..046304519 100644 --- a/Examples/lua/class/example.cxx +++ b/Examples/lua/class/example.cxx @@ -1,4 +1,4 @@ -/* File : example.c */ +/* File : example.cxx */ #include "example.h" #define M_PI 3.14159265358979323846 @@ -11,18 +11,18 @@ void Shape::move(double dx, double dy) { int Shape::nshapes = 0; -double Circle::area(void) { +double Circle::area() { return M_PI*radius*radius; } -double Circle::perimeter(void) { +double Circle::perimeter() { return 2*M_PI*radius; } -double Square::area(void) { +double Square::area() { return width*width; } -double Square::perimeter(void) { +double Square::perimeter() { return 4*width; } diff --git a/Examples/modula3/class/example.cxx b/Examples/modula3/class/example.cxx index 1e8e203dd..046304519 100644 --- a/Examples/modula3/class/example.cxx +++ b/Examples/modula3/class/example.cxx @@ -1,4 +1,4 @@ -/* File : example.c */ +/* File : example.cxx */ #include "example.h" #define M_PI 3.14159265358979323846 @@ -11,18 +11,18 @@ void Shape::move(double dx, double dy) { int Shape::nshapes = 0; -double Circle::area(void) { +double Circle::area() { return M_PI*radius*radius; } -double Circle::perimeter(void) { +double Circle::perimeter() { return 2*M_PI*radius; } -double Square::area(void) { +double Square::area() { return width*width; } -double Square::perimeter(void) { +double Square::perimeter() { return 4*width; } diff --git a/Examples/octave/class/example.cxx b/Examples/octave/class/example.cxx index 1e8e203dd..046304519 100644 --- a/Examples/octave/class/example.cxx +++ b/Examples/octave/class/example.cxx @@ -1,4 +1,4 @@ -/* File : example.c */ +/* File : example.cxx */ #include "example.h" #define M_PI 3.14159265358979323846 @@ -11,18 +11,18 @@ void Shape::move(double dx, double dy) { int Shape::nshapes = 0; -double Circle::area(void) { +double Circle::area() { return M_PI*radius*radius; } -double Circle::perimeter(void) { +double Circle::perimeter() { return 2*M_PI*radius; } -double Square::area(void) { +double Square::area() { return width*width; } -double Square::perimeter(void) { +double Square::perimeter() { return 4*width; } diff --git a/Examples/r/class/example.cxx b/Examples/r/class/example.cxx index 1e8e203dd..046304519 100644 --- a/Examples/r/class/example.cxx +++ b/Examples/r/class/example.cxx @@ -1,4 +1,4 @@ -/* File : example.c */ +/* File : example.cxx */ #include "example.h" #define M_PI 3.14159265358979323846 @@ -11,18 +11,18 @@ void Shape::move(double dx, double dy) { int Shape::nshapes = 0; -double Circle::area(void) { +double Circle::area() { return M_PI*radius*radius; } -double Circle::perimeter(void) { +double Circle::perimeter() { return 2*M_PI*radius; } -double Square::area(void) { +double Square::area() { return width*width; } -double Square::perimeter(void) { +double Square::perimeter() { return 4*width; } -- cgit v1.2.1 From 426dd3312f31245622ec15c07824e406de9a76cf Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Pawe=C5=82=20Tomulik?= Date: Wed, 7 May 2014 17:23:03 +0200 Subject: minor corrections to python documentation --- Doc/Manual/Python.html | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/Doc/Manual/Python.html b/Doc/Manual/Python.html index dcfd7427e..9b86652f4 100644 --- a/Doc/Manual/Python.html +++ b/Doc/Manual/Python.html @@ -5412,7 +5412,7 @@ class M3: pass

    We edit pkg1/mod2.py and want to import module -pkg1/pkg2/pkg3.py in order to derive from class M3. We can +pkg1/pkg2/mod3.py in order to derive from class M3. We can write appropriate Python code in several ways, for example:

    @@ -5570,8 +5570,8 @@ from __future__ import absolute_import

    Imports in __init__.py are handy when you want to populate a package's namespace with names imported from other modules. In SWIG based projects this approach may also be used to split large pieces of code into -smaller modules, compile them in parallel and then re-assemble everything at another -level by importing submodules' contents in __init__.py, for +smaller modules, compile them in parallel and then re-assemble everything at +runtime by importing submodules' contents in __init__.py, for example.

    Unfortunately import directives in __init__.py may cause problems, -- cgit v1.2.1 From 8d01b145f7d368348e702f88df6c091f5d7175a5 Mon Sep 17 00:00:00 2001 From: William S Fulton Date: Fri, 2 May 2014 07:07:15 +0100 Subject: Cosmetic rewording to workaround syntax highlighting bug in vim. --- configure.ac | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/configure.ac b/configure.ac index d83e0d31b..6d70f1da8 100644 --- a/configure.ac +++ b/configure.ac @@ -19,7 +19,7 @@ AH_BOTTOM([ /* Default language */ #define SWIG_LANG "-tcl" -/* Deal with Microsoft's attempt at deprecating C standard runtime functions */ +/* Deal with attempt by Microsoft to deprecate C standard runtime functions */ #if defined(_MSC_VER) # define _CRT_SECURE_NO_DEPRECATE #endif @@ -489,7 +489,7 @@ if test x"${with_tclconfig}" != x ; then if test -f "${with_tclconfig}/tclConfig.sh" ; then TCLCONFIG=`(cd ${with_tclconfig}; pwd)` else - AC_MSG_ERROR([${with_tcl} directory doesn't contain tclConfig.sh]) + AC_MSG_ERROR([${with_tcl} directory does not contain tclConfig.sh]) fi fi # check in a few common install locations -- cgit v1.2.1 From 575c7a113aa8237f130a9c094173b8f335dceff4 Mon Sep 17 00:00:00 2001 From: William S Fulton Date: Fri, 9 May 2014 23:23:39 +0100 Subject: html fixes --- Doc/Manual/Javascript.html | 190 +++++++++++++++++++++++++++++++-------------- Doc/Manual/Lua.html | 90 ++++++++++----------- 2 files changed, 178 insertions(+), 102 deletions(-) diff --git a/Doc/Manual/Javascript.html b/Doc/Manual/Javascript.html index e589d9d09..011e61051 100644 --- a/Doc/Manual/Javascript.html +++ b/Doc/Manual/Javascript.html @@ -6,10 +6,53 @@ -

    SWIG and Javascript

    +

    26 SWIG and Javascript

    + + + + + +

    This chapter describes SWIG's support of Javascript. It does not cover SWIG basics, but only information that is specific to this module.

    -

    Overview

    +

    26.1 Overview

    + +

    Javascript is a prototype-based scripting language that is dynamic, weakly typed and has first-class functions. Its arguably the most popular language for web development. Javascript has gone beyond being a browser-based scripting language and with node.js, it is also used as a backend development language.

    Native Javascript extensions can be used for applications that embed a web-browser view or that embed a Javascript engine (such as node.js). Extending a general purpose web-browser is not possible as this would be a severe security issue.

    @@ -18,9 +61,11 @@ Javascript has gone beyond being a browser-based scripting language and with node-webkit there is a platform which uses Google's Chromium as Web-Browser widget and node.js for javascript extensions.

    -

    Preliminaries

    +

    26.2 Preliminaries

    + + +

    26.2.1 Running SWIG

    -

    Running SWIG

    Suppose that you defined a SWIG module such as the following:

    @@ -51,13 +96,15 @@ bool example_initialize(JSGlobalContextRef context, JSObjectRef *exports)

    and for v8:

    -void example_initialize(v8::Handle exports)
    +void example_initialize(v8::Handle<v8::Object> exports)

    -

    Note: be aware that v8 has a C++ API, and thus, the generated modules must be compiled as C++.

    +Note: be aware that v8 has a C++ API, and thus, the generated modules must be compiled as C++.

    -

    Running Tests and Examples

    +

    26.2.2 Running Tests and Examples

    + +

    The configuration for tests and examples currently supports Linux and Mac only and not MinGW (Windows) yet.

    The default interpreter is node.js as it is available on all platforms and convenient to use.

    Running the examples with JavascriptCore requires libjavascriptcoregtk-1.0 to be installed, e.g., under Ubuntu with

    @@ -98,19 +145,24 @@ $ make check-javascript-test-suite ENGINE=jsc - Windows 7 64bit (VS 2010) - Node.js
    -

    -

    Future work

    +

    26.2.3 Future work

    + +

    The Javascript module is not yet as mature as other modules and some things are still missing. As it makes use of SWIG's Unified Typemap Library (UTL), many typemaps are inherited. We could work on that if requested:

    • More typemaps: compared to other modules there are only a few typemaps implemented. For instance a lot of the std_*.i typemaps are missing, such as std_iostream, for instance.

    • Director support: this would allow to extend a C++ abstract base class in Javascript. A pragmatic intermediate step for the most important usecase would be to support Javascript callbacks as arguments.

    -

    Integration

    +

    26.3 Integration

    + +

    This chapter gives a short introduction how to use a native Javascript extension: as a node.js module, and as an extension for an embedded Webkit.

    -

    Creating node.js Extensions

    +

    26.3.1 Creating node.js Extensions

    + +

    To install node.js you can download an installer from their web-site for OSX and Windows. For Linux you can either build the source yourself and run sudo checkinstall or keep to the (probably stone-age) packaged version. For Ubuntu there is a PPA available.

    @@ -154,7 +206,9 @@ require("./build/Release/example")

    A more detailed explanation is given in the Examples section.

    -

    Troubleshooting

    +

    26.3.1.1 Troubleshooting

    + +
    • 'module' object has no attribute 'script_main'
    @@ -164,10 +218,14 @@ require("./build/Release/example") $ sudo apt-get remove gyp -

    Embedded Webkit

    +

    26.3.2 Embedded Webkit

    + +

    Webkit is pre-installed on OSX and available as a library for GTK.

    -

    OSX

    +

    26.3.2.1 OSX

    + +

    There is general information about programming with WebKit on Apple Developer Documentation. Details about Cocoa programming are not covered here.

    An integration of a native extension 'example' would look like this:

    @@ -201,20 +259,22 @@ extern bool example_initialize(JSGlobalContextRef context); @end
    -

    GTK

    +

    26.3.2.2 GTK

    + +

    There is general information about programming GTK at GTK documentation and in the GTK tutorial, and for Webkit there is a Webkit GTK+ API Reference.

    An integration of a native extension 'example' would look like this:

    -#include 
    -#include 
    +#include <gtk/gtk.h>
    +#include <webkit/webkit.h>
     
     extern bool example_initialize(JSGlobalContextRef context);
     
     int main(int argc, char* argv[])
     {
         // Initialize GTK+
    -    gtk_init(&argc, &argv);
    +    gtk_init(&argc, &argv);
     
         ...
     
    @@ -238,8 +298,9 @@ int main(int argc, char* argv[])
     }
    -

    Creating Applications with node-webkit

    -

    +

    26.3.3 Creating Applications with node-webkit

    + +

    To get started with node-webkit there is a very informative set of wiki pages.

    Similar to node.js, node-webkit is started from command line within a node.js project directory. Native extensions are created in the very same way as for node.js, except that a customized gyp derivate has to be used: nw-gyp. @@ -328,10 +389,14 @@ open new windows, and many more things. }; -

    Examples

    +

    26.4 Examples

    + +

    Some basic examples are shown here in more detail.

    -

    Simple

    +

    26.4.1 Simple

    + +

    The common example simple looks like this:

    @@ -376,11 +441,12 @@ var f = example.Foo;
     example.Foo = 3.1415926;

    First the module example is loaded from the previously built extension. Global methods and variables are available in the scope of the module.

    -

    +

    Note: ECMAScript 5, the currently implemented Javascript standard, does not have modules. node.js and other implementations provide this mechanism defined by the CommonJS group. For browsers this is provided by Browserify, for instance.

    -

    -

    Class

    +

    26.4.2 Class

    + +

    The common example class defines three classes, Shape, Circle, and Square:

    @@ -455,47 +521,47 @@ new Shape();
     $ node -i
    -> var example = require("./build/Release/example");
    +& var example = require("./build/Release/example");
     undefined
    -> var Shape = example.Shape;
    +& var Shape = example.Shape;
     undefined
    -> var Circle = example.Circle;
    +& var Circle = example.Circle;
     undefined
    -> var Square = example.Square;
    +& var Square = example.Square;
     undefined
    -> var c = new Circle(10);
    +& var c = new Circle(10);
     undefined
    -> var s = new Square(10);
    +& var s = new Square(10);
     undefined
    -> Shape.nshapes;
    +& Shape.nshapes;
     2
    -> c.x = 20;
    +& c.x = 20;
     20
    -> c.y = 30;
    +& c.y = 30;
     30
    -> s.x = -10;
    +& s.x = -10;
     -10
    -> s.y = 5;
    +& s.y = 5;
     5
    -> c.area();
    +& c.area();
     314.1592653589793
    -> c.perimeter();
    +& c.perimeter();
     62.83185307179586
    -> s.area();
    +& s.area();
     100
    -> s.perimeter();
    +& s.perimeter();
     40
    -> c.move(40, 40)
    +& c.move(40, 40)
     undefined
    -> c.x
    +& c.x
     60
    -> c.y
    +& c.y
     70
    -> new Shape()
    +& new Shape()
     Error: Class Shape can not be instantiated
     at repl:1:2
     at REPLServer.self.eval (repl.js:110:21)
    -at Interface. (repl.js:239:12)
    +at Interface.<anonymous> (repl.js:239:12)
     at Interface.EventEmitter.emit (events.js:95:17)
     at Interface._onLine (readline.js:202:10)
     at Interface._line (readline.js:531:8)
    @@ -505,13 +571,17 @@ at ReadStream.EventEmitter.emit (events.js:98:17)
     at emitKey (readline.js:1095:12)

    -

    Note: In ECMAScript 5 there is no concept for classes. Instead each function can be used as a constructor function which is executed by the 'new' operator. Furthermore, during construction the key property prototype of the constructor function is used to attach a prototype instance to the created object. A prototype is essentially an object itself that is the first-class delegate of a class used whenever the access to a property of an object fails. The very same prototype instance is shared among all instances of one type. Prototypal inheritance is explained in more detail on in Inheritance and the prototype chain, for instance.

    +Note: In ECMAScript 5 there is no concept for classes. Instead each function can be used as a constructor function which is executed by the 'new' operator. Furthermore, during construction the key property prototype of the constructor function is used to attach a prototype instance to the created object. A prototype is essentially an object itself that is the first-class delegate of a class used whenever the access to a property of an object fails. The very same prototype instance is shared among all instances of one type. Prototypal inheritance is explained in more detail on in Inheritance and the prototype chain, for instance.

    -

    Implementation

    +

    26.5 Implementation

    + +

    The Javascript Module implementation has taken a very different approach compared to other language modules in order to support different Javascript interpreters.

    -

    Source Code

    +

    26.5.1 Source Code

    + +

    The Javascript module is implemented in Source/Modules/javascript.cxx. It dispatches the code generation to a JSEmitter instance, V8Emitter or JSCEmitter. Additionally there are some helpers: Template, for templated code generation, and JSEmitterState, which is used to manage state information during AST traversal. This rough map shall make it easier to find a way through this huge source file:

    @@ -610,7 +680,9 @@ Template::Template(const String *code_) { ... }
     ...
    -

    Code Templates

    +

    26.5.2 Code Templates

    + +

    All generated code is created on the basis of code templates. The templates for JavascriptCore can be found in Lib/javascript/jsc/javascriptcode.swg, for v8 in Lib/javascript/v8/javascriptcode.swg.

    To track the originating code template for generated code you can run

    @@ -647,7 +719,9 @@ t_register.replace("$jsparent", state.clazz(NAME_MANGLED))

    Template creates a copy of that string and Template::replace uses Swig's Replaceall to replace variables in the template. Template::trim can be used to eliminate leading and trailing whitespaces. Template::print is used to write the final template string to a Swig DOH (based on Printv). All methods allow chaining.

    -

    Emitter

    +

    26.5.3 Emitter

    + +

    The Javascript module delegates code generation to a JSEmitter instance. The following extract shows the essential interface:

    @@ -730,7 +804,7 @@ class JSEmitter {
        */
       Template getTemplate(const String *name);
     
    -  State &getState();
    +  State &getState();
     
       ...
     
    @@ -740,12 +814,12 @@ class JSEmitter {
     
     int JAVASCRIPT::top(Node *n) {
    -  emitter->initialize(n);
    +  emitter->initialize(n);
     
       Language::top(n);
     
    -  emitter->dump(n);
    -  emitter->close();
    +  emitter->dump(n);
    +  emitter->close();
     
       return SWIG_OK;
     }
    @@ -755,16 +829,18 @@ int JAVASCRIPT::top(Node *n) {
     int JAVASCRIPT::classHandler(Node *n) {
     
    -  emitter->enterClass(n);
    +  emitter->enterClass(n);
       Language::classHandler(n);
    -  emitter->exitClass(n);
    +  emitter->exitClass(n);
     
       return SWIG_OK;
     }

    In enterClass the emitter stores state information that is necessary when processing class members. In exitClass the wrapper code for the whole class is generated.

    -

    Emitter states

    +

    26.5.4 Emitter states

    + +

    For storing information during the AST traversal the emitter provides a JSEmitterState with different slots to store data representing the scopes global, class, function, and variable.

    diff --git a/Doc/Manual/Lua.html b/Doc/Manual/Lua.html
    index 269cb2801..61f19be68 100644
    --- a/Doc/Manual/Lua.html
    +++ b/Doc/Manual/Lua.html
    @@ -6,7 +6,7 @@
     
     
     
    -

    27 SWIG and Lua

    +

    28 SWIG and Lua

      @@ -82,14 +82,14 @@ Lua is an extension programming language designed to support general procedural eLua stands for Embedded Lua (can be thought of as a flavor of Lua) and offers the full implementation of the Lua programming language to the embedded world, extending it with specific features for efficient and portable software embedded development. eLua runs on smaller devices like microcontrollers and provides the full features of the regular Lua desktop version. More information on eLua can be found here: http://www.eluaproject.net

      -

      27.1 Preliminaries

      +

      28.1 Preliminaries

      The current SWIG implementation is designed to work with Lua 5.0.x, 5.1.x and 5.2.x. It should work with later versions of Lua, but certainly not with Lua 4.0 due to substantial API changes. It is possible to either static link or dynamic link a Lua module into the interpreter (normally Lua static links its libraries, as dynamic linking is not available on all platforms). SWIG also has support for eLua starting from eLua 0.8. Due to substantial changes between SWIG 2.x and SWIG 3.0 and unavailability of testing platform, eLua status was downgraded to 'experimental'.

      -

      27.2 Running SWIG

      +

      28.2 Running SWIG

      @@ -137,7 +137,7 @@ $ swig -lua -eluac example.i The -elua option puts all the C function wrappers and variable get/set wrappers in rotables. It also generates a metatable which will control the access to these variables from eLua. It also offers a significant amount of module size compression. On the other hand, the -eluac option puts all the wrappers in a single rotable. With this option, no matter how huge the module, it will consume no additional microcontroller SRAM (crass compression). There is a catch though: Metatables are not generated with -eluac. To access any value from eLua, one must directly call the wrapper function associated with that value.

      -

      27.2.1 Additional command line options

      +

      28.2.1 Additional command line options

      @@ -178,7 +178,7 @@ swig -lua -help -

      27.2.2 Compiling and Linking and Interpreter

      +

      28.2.2 Compiling and Linking and Interpreter

      @@ -249,7 +249,7 @@ LUALIB_API int ( luaopen_mod )(lua_State *L ); More information on building and configuring eLua can be found here: http://www.eluaproject.net/doc/v0.8/en_building.html

      -

      27.2.3 Compiling a dynamic module

      +

      28.2.3 Compiling a dynamic module

      @@ -317,7 +317,7 @@ Is quite obvious (Go back and consult the Lua documents on how to enable loadlib -

      27.2.4 Using your module

      +

      28.2.4 Using your module

      @@ -335,19 +335,19 @@ $ ./my_lua >

    -

    27.3 A tour of basic C/C++ wrapping

    +

    28.3 A tour of basic C/C++ wrapping

    By default, SWIG tries to build a very natural Lua interface to your C/C++ code. This section briefly covers the essential aspects of this wrapping.

    -

    27.3.1 Modules

    +

    28.3.1 Modules

    The SWIG module directive specifies the name of the Lua module. If you specify `module example', then everything is wrapped into a Lua table 'example' containing all the functions and variables. When choosing a module name, make sure you don't use the same name as a built-in Lua command or standard module name.

    -

    27.3.2 Functions

    +

    28.3.2 Functions

    @@ -388,7 +388,7 @@ It is also possible to rename the module with an assignment. 24

    -

    27.3.3 Global variables

    +

    28.3.3 Global variables

    @@ -476,7 +476,7 @@ If you have used the -eluac option for your eLua module, you will have In general, functions of the form "variable_get()" and "variable_set()" are automatically generated by SWIG for use with -eluac.

    -

    27.3.4 Constants and enums

    +

    28.3.4 Constants and enums

    @@ -511,7 +511,7 @@ If you're using eLua and have used -elua or -eluac to generate Hello World

    -

    27.3.4.1 Constants/enums and classes/structures

    +

    28.3.4.1 Constants/enums and classes/structures

    @@ -567,7 +567,7 @@ If the -no-old-metatable-bindings option is used, then these old-style It is worth mentioning, that example.Test.TEST1 and example.Test_TEST1 are different entities and changing one does not change the other. Given the fact that these are constantes and they are not supposed to be changed, it is up to you to avoid such issues.

    -

    27.3.5 Pointers

    +

    28.3.5 Pointers

    @@ -605,7 +605,7 @@ Lua enforces the integrity of its userdata, so it is virtually impossible to cor nil -

    27.3.6 Structures

    +

    28.3.6 Structures

    @@ -709,7 +709,7 @@ For eLua with the -eluac option, structure manipulation has to be perfo In general, functions of the form "new_struct()", "struct_member_get()", "struct_member_set()" and "free_struct()" are automatically generated by SWIG for each structure defined in C. (Please note: This doesn't apply for modules generated with the -elua option)

    -

    27.3.7 C++ classes

    +

    28.3.7 C++ classes

    @@ -784,7 +784,7 @@ Both style names are generated by default now. However, if the -no-old-metatable-bindings option is used, then the backward compatible names are not generated in addition to ordinary ones.

    -

    27.3.8 C++ inheritance

    +

    28.3.8 C++ inheritance

    @@ -809,7 +809,7 @@ then the function spam() accepts a Foo pointer or a pointer to any clas

    It is safe to use multiple inheritance with SWIG.

    -

    27.3.9 Pointers, references, values, and arrays

    +

    28.3.9 Pointers, references, values, and arrays

    @@ -840,7 +840,7 @@ Foo spam7();

    then all three functions will return a pointer to some Foo object. Since the third function (spam7) returns a value, newly allocated memory is used to hold the result and a pointer is returned (Lua will release this memory when the return value is garbage collected). The other two are pointers which are assumed to be managed by the C code and so will not be garbage collected.

    -

    27.3.10 C++ overloaded functions

    +

    28.3.10 C++ overloaded functions

    @@ -926,7 +926,7 @@ Please refer to the "SWIG and C++" chapter for more information about overloadin

    Dealing with the Lua coercion mechanism, the priority is roughly (integers, floats, strings, userdata). But it is better to rename the functions rather than rely upon the ordering.

    -

    27.3.11 C++ operators

    +

    28.3.11 C++ operators

    @@ -1058,9 +1058,9 @@ operators and pseudo-operators):

  • __setitem__
  • __tostring used internally by Lua for tostring() function. __str__ is mapped to this function -

    No other lua metafunction is inherited. For example, __gc is not inherited and must be redefined in every class. __tostring is subject to a special handling. If absent in class and in class bases, a default one will be provided by SWIG

    +

    No other lua metafunction is inherited. For example, __gc is not inherited and must be redefined in every class. __tostring is subject to a special handling. If absent in class and in class bases, a default one will be provided by SWIG.

    -

    27.3.12 Class extension with %extend

    +

    28.3.12 Class extension with %extend

    @@ -1116,7 +1116,7 @@ true Extend works with both C and C++ code, on classes and structs. It does not modify the underlying object in any way---the extensions only show up in the Lua interface. The only item to take note of is the code has to use the '$self' instead of 'this', and that you cannot access protected/private members of the code (as you are not officially part of the class).

    -

    27.3.13 Using %newobject to release memory

    +

    28.3.13 Using %newobject to release memory

    If you have a function that allocates memory like this,

    @@ -1140,7 +1140,7 @@ char *foo();

    This will release the allocated memory.

    -

    27.3.14 C++ templates

    +

    28.3.14 C++ templates

    @@ -1175,7 +1175,7 @@ In Lua:

    Obviously, there is more to template wrapping than shown in this example. More details can be found in the SWIG and C++ chapter. Some more complicated examples will appear later.

    -

    27.3.15 C++ Smart Pointers

    +

    28.3.15 C++ Smart Pointers

    @@ -1227,7 +1227,7 @@ If you ever need to access the underlying pointer returned by operator->( > f = p:__deref__() -- Returns underlying Foo * -

    27.3.16 C++ Exceptions

    +

    28.3.16 C++ Exceptions

    @@ -1370,7 +1370,7 @@ and the "Exception handling add exception specification to functions or globally (respectively).

    -

    27.3.17 Namespaces

    +

    28.3.17 Namespaces

    @@ -1421,7 +1421,7 @@ Now, from Lua usage is as follows: 19 > -

    27.3.17.1 Compatibility Note

    +

    28.3.17.1 Compatibility Note

    @@ -1437,7 +1437,7 @@ If SWIG is running in a backwards compatible way, i.e. without the -no-old-m -

    27.3.17.2 Names

    +

    28.3.17.2 Names

    If SWIG is launched without -no-old-metatable-bindings option, then it enters backward-compatible mode. While in this mode, it tries @@ -1481,7 +1481,7 @@ surrounding scope without any prefixing. Pretending that Test2 is a struct, not > -

    27.3.17.3 Inheritance

    +

    28.3.17.3 Inheritance

    The internal organization of inheritance has changed. @@ -1522,12 +1522,12 @@ function > -

    27.4 Typemaps

    +

    28.4 Typemaps

    This section explains what typemaps are and how to use them. The default wrapping behaviour of SWIG is enough in most cases. However sometimes SWIG may need a little additional assistance to know which typemap to apply to provide the best wrapping. This section will be explaining how to use typemaps to best effect

    -

    27.4.1 What is a typemap?

    +

    28.4.1 What is a typemap?

    A typemap is nothing more than a code generation rule that is attached to a specific C datatype. For example, to convert integers from Lua to C, you might define a typemap like this:

    @@ -1555,7 +1555,7 @@ Received an integer : 6 720 -

    27.4.2 Using typemaps

    +

    28.4.2 Using typemaps

    There are many ready written typemaps built into SWIG for all common types (int, float, short, long, char*, enum and more), which SWIG uses automatically, with no effort required on your part.

    @@ -1608,7 +1608,7 @@ void swap(int *sx, int *sy);

    Note: C++ references must be handled exactly the same way. However SWIG will automatically wrap a const int& as an input parameter (since that it obviously input).

    -

    27.4.3 Typemaps and arrays

    +

    28.4.3 Typemaps and arrays

    Arrays present a challenge for SWIG, because like pointers SWIG does not know whether these are input or output values, nor @@ -1672,7 +1672,7 @@ and Lua tables to be 1..N, (the indexing follows the norm for the language). In

    Note: SWIG also can support arrays of pointers in a similar manner.

    -

    27.4.4 Typemaps and pointer-pointer functions

    +

    28.4.4 Typemaps and pointer-pointer functions

    Several C++ libraries use a pointer-pointer functions to create its objects. These functions require a pointer to a pointer which is then filled with the pointer to the new object. Microsoft's COM and DirectX as well as many other libraries have this kind of function. An example is given below:

    @@ -1706,7 +1706,7 @@ int Create_Math(iMath** pptr); // its creator (assume it mallocs) ptr=nil -- the iMath* will be GC'ed as normal -

    27.5 Writing typemaps

    +

    28.5 Writing typemaps

    This section describes how you can modify SWIG's default wrapping behavior for various C/C++ datatypes using the %typemap directive. This is an advanced topic that assumes familiarity with the Lua C API as well as the material in the "Typemaps" chapter.

    @@ -1715,7 +1715,7 @@ ptr=nil -- the iMath* will be GC'ed as normal

    Before proceeding, you should read the previous section on using typemaps, and look at the existing typemaps found in luatypemaps.swg and typemaps.i. These are both well documented and fairly easy to read. You should not attempt to write your own typemaps until you have read and can understand both of these files (they may well also give you an idea to base your work on).

    -

    27.5.1 Typemaps you can write

    +

    28.5.1 Typemaps you can write

    There are many different types of typemap that can be written, the full list can be found in the "Typemaps" chapter. However the following are the most commonly used ones.

    @@ -1728,7 +1728,7 @@ ptr=nil -- the iMath* will be GC'ed as normal (the syntax for the typecheck is different from the typemap, see typemaps for details).
  • -

    27.5.2 SWIG's Lua-C API

    +

    28.5.2 SWIG's Lua-C API

    This section explains the SWIG specific Lua-C API. It does not cover the main Lua-C api, as this is well documented and not worth covering.

    @@ -1777,7 +1777,7 @@ This macro, when called within the context of a SWIG wrapped function, will disp
    Similar to SWIG_fail_arg, except that it will display the swig_type_info information instead.
    -

    27.6 Customization of your Bindings

    +

    28.6 Customization of your Bindings

    @@ -1786,7 +1786,7 @@ This section covers adding of some small extra bits to your module to add the la -

    27.6.1 Writing your own custom wrappers

    +

    28.6.1 Writing your own custom wrappers

    @@ -1805,7 +1805,7 @@ int native_function(lua_State*L) // my native code The %native directive in the above example, tells SWIG that there is a function int native_function(lua_State*L); which is to be added into the module under the name 'my_func'. SWIG will not add any wrapper for this function, beyond adding it into the function table. How you write your code is entirely up to you.

    -

    27.6.2 Adding additional Lua code

    +

    28.6.2 Adding additional Lua code

    @@ -1843,7 +1843,7 @@ Good uses for this feature is adding of new code, or writing helper functions to See Examples/lua/arrays for an example of this code.

    -

    27.7 Details on the Lua binding

    +

    28.7 Details on the Lua binding

    @@ -1854,7 +1854,7 @@ See Examples/lua/arrays for an example of this code.

    -

    27.7.1 Binding global data into the module.

    +

    28.7.1 Binding global data into the module.

    @@ -1914,7 +1914,7 @@ end

    That way when you call 'a=example.Foo', the interpreter looks at the table 'example' sees that there is no field 'Foo' and calls __index. This will in turn check in '.get' table and find the existence of 'Foo' and then return the value of the C function call 'Foo_get()'. Similarly for the code 'example.Foo=10', the interpreter will check the table, then call the __newindex which will then check the '.set' table and call the C function 'Foo_set(10)'.

    -

    27.7.2 Userdata and Metatables

    +

    28.7.2 Userdata and Metatables

    @@ -1994,7 +1994,7 @@ Note: Both the opaque structures (like the FILE*) and normal wrapped classes/str

    Note: Operator overloads are basically done in the same way, by adding functions such as '__add' & '__call' to the class' metatable. The current implementation is a bit rough as it will add any member function beginning with '__' into the metatable too, assuming its an operator overload.

    -

    27.7.3 Memory management

    +

    28.7.3 Memory management

    -- cgit v1.2.1 From 4a680e5545af57bd866a8211679b3d953e286545 Mon Sep 17 00:00:00 2001 From: William S Fulton Date: Fri, 9 May 2014 23:26:59 +0100 Subject: html doc chapter numbering update since adding Javascript --- Doc/Manual/Contents.html | 69 ++++++++++++---- Doc/Manual/Extending.html | 100 +++++++++++------------ Doc/Manual/Lisp.html | 22 +++--- Doc/Manual/Modula3.html | 40 +++++----- Doc/Manual/Mzscheme.html | 8 +- Doc/Manual/Ocaml.html | 62 +++++++-------- Doc/Manual/Octave.html | 48 ++++++------ Doc/Manual/Perl5.html | 108 ++++++++++++------------- Doc/Manual/Php.html | 48 ++++++------ Doc/Manual/Pike.html | 24 +++--- Doc/Manual/Python.html | 164 +++++++++++++++++++------------------- Doc/Manual/R.html | 16 ++-- Doc/Manual/Ruby.html | 196 +++++++++++++++++++++++----------------------- Doc/Manual/Tcl.html | 92 +++++++++++----------- 14 files changed, 519 insertions(+), 478 deletions(-) diff --git a/Doc/Manual/Contents.html b/Doc/Manual/Contents.html index 7cf40b95d..37a5aacff 100644 --- a/Doc/Manual/Contents.html +++ b/Doc/Manual/Contents.html @@ -1046,7 +1046,48 @@ -

    26 SWIG and Common Lisp

    +

    26 SWIG and Javascript

    + + + + + +

    27 SWIG and Common Lisp

    @@ -1069,7 +1110,7 @@
    -

    27 SWIG and Lua

    +

    28 SWIG and Lua

    @@ -1137,7 +1178,7 @@
    -

    28 SWIG and Modula-3

    +

    29 SWIG and Modula-3

    @@ -1175,7 +1216,7 @@
    -

    29 SWIG and MzScheme/Racket

    +

    30 SWIG and MzScheme/Racket

    @@ -1187,7 +1228,7 @@
    -

    30 SWIG and Ocaml

    +

    31 SWIG and Ocaml

    @@ -1238,7 +1279,7 @@
    -

    31 SWIG and Octave

    +

    32 SWIG and Octave

    @@ -1274,7 +1315,7 @@
    -

    32 SWIG and Perl5

    +

    33 SWIG and Perl5

    @@ -1350,7 +1391,7 @@
    -

    33 SWIG and PHP

    +

    34 SWIG and PHP

    @@ -1390,7 +1431,7 @@
    -

    34 SWIG and Pike

    +

    35 SWIG and Pike

    @@ -1414,7 +1455,7 @@
    -

    35 SWIG and Python

    +

    36 SWIG and Python

    @@ -1530,7 +1571,7 @@
    -

    36 SWIG and R

    +

    37 SWIG and R

    @@ -1546,7 +1587,7 @@
    -

    37 SWIG and Ruby

    +

    38 SWIG and Ruby

    @@ -1680,7 +1721,7 @@
    -

    38 SWIG and Tcl

    +

    39 SWIG and Tcl

    @@ -1746,7 +1787,7 @@
    -

    39 Extending SWIG to support new languages

    +

    40 Extending SWIG to support new languages

    diff --git a/Doc/Manual/Extending.html b/Doc/Manual/Extending.html index 5c209bbb5..00302d7b5 100644 --- a/Doc/Manual/Extending.html +++ b/Doc/Manual/Extending.html @@ -6,7 +6,7 @@ -

    39 Extending SWIG to support new languages

    +

    40 Extending SWIG to support new languages

      @@ -75,7 +75,7 @@ -

      39.1 Introduction

      +

      40.1 Introduction

      @@ -91,7 +91,7 @@ Also, this chapter is not meant to be a hand-holding tutorial. As a starting po you should probably look at one of SWIG's existing modules.

      -

      39.2 Prerequisites

      +

      40.2 Prerequisites

      @@ -121,7 +121,7 @@ obvious, but almost all SWIG directives as well as the low-level generation of wrapper code are driven by C++ datatypes.

      -

      39.3 The Big Picture

      +

      40.3 The Big Picture

      @@ -158,7 +158,7 @@ role in making the system work. For example, both typemaps and declaration anno based on pattern matching and interact heavily with the underlying type system.

      -

      39.4 Execution Model

      +

      40.4 Execution Model

      @@ -203,7 +203,7 @@ latter stage of compilation. The next few sections briefly describe some of these stages.

      -

      39.4.1 Preprocessing

      +

      40.4.1 Preprocessing

      @@ -284,7 +284,7 @@ been expanded as well as everything else that goes into the low-level construction of the wrapper code.

      -

      39.4.2 Parsing

      +

      40.4.2 Parsing

      @@ -385,7 +385,7 @@ returning a foo and taking types a and b as arguments).

      -

      39.4.3 Parse Trees

      +

      40.4.3 Parse Trees

      @@ -640,7 +640,7 @@ $ swig -c++ -python -debug-module 4 example.i

    -

    39.4.4 Attribute namespaces

    +

    40.4.4 Attribute namespaces

    @@ -659,7 +659,7 @@ that matches the name of the target language. For example, python:foo perl:foo.

    -

    39.4.5 Symbol Tables

    +

    40.4.5 Symbol Tables

    @@ -750,7 +750,7 @@ example.i:5. Previous declaration is foo_i(int )

    -

    39.4.6 The %feature directive

    +

    40.4.6 The %feature directive

    @@ -806,7 +806,7 @@ For example, the exception code above is simply stored without any modifications.

    -

    39.4.7 Code Generation

    +

    40.4.7 Code Generation

    @@ -928,7 +928,7 @@ public : The role of these functions is described shortly.

    -

    39.4.8 SWIG and XML

    +

    40.4.8 SWIG and XML

    @@ -941,7 +941,7 @@ internal data structures, it may be useful to keep XML in the back of your mind as a model.

    -

    39.5 Primitive Data Structures

    +

    40.5 Primitive Data Structures

    @@ -987,7 +987,7 @@ typedef Hash Typetab; -

    39.5.1 Strings

    +

    40.5.1 Strings

    @@ -1128,7 +1128,7 @@ Returns the number of replacements made (if any). -

    39.5.2 Hashes

    +

    40.5.2 Hashes

    @@ -1205,7 +1205,7 @@ Returns the list of hash table keys. -

    39.5.3 Lists

    +

    40.5.3 Lists

    @@ -1294,7 +1294,7 @@ If t is not a standard object, it is assumed to be a char * and is used to create a String object. -

    39.5.4 Common operations

    +

    40.5.4 Common operations

    The following operations are applicable to all datatypes. @@ -1349,7 +1349,7 @@ objects and report errors. Gets the line number associated with x. -

    39.5.5 Iterating over Lists and Hashes

    +

    40.5.5 Iterating over Lists and Hashes

    To iterate over the elements of a list or a hash table, the following functions are used: @@ -1394,7 +1394,7 @@ for (j = First(j); j.item; j= Next(j)) { -

    39.5.6 I/O

    +

    40.5.6 I/O

    Special I/O functions are used for all internal I/O. These operations @@ -1528,7 +1528,7 @@ Printf(f, "%s\n", s); Similarly, the preprocessor and parser all operate on string-files.

    -

    39.6 Navigating and manipulating parse trees

    +

    40.6 Navigating and manipulating parse trees

    Parse trees are built as collections of hash tables. Each node is a hash table in which @@ -1662,7 +1662,7 @@ Deletes a node from the parse tree. Deletion reconnects siblings and properly u the parent so that sibling nodes are unaffected. -

    39.7 Working with attributes

    +

    40.7 Working with attributes

    @@ -1779,7 +1779,7 @@ the attribute is optional. Swig_restore() must always be called after function. -

    39.8 Type system

    +

    40.8 Type system

    @@ -1788,7 +1788,7 @@ pointers, references, and pointers to members. A detailed discussion of type theory is impossible here. However, let's cover the highlights.

    -

    39.8.1 String encoding of types

    +

    40.8.1 String encoding of types

    @@ -1889,7 +1889,7 @@ make the final type, the two parts are just joined together using string concatenation.

    -

    39.8.2 Type construction

    +

    40.8.2 Type construction

    @@ -2058,7 +2058,7 @@ Returns the prefix of a type. For example, if ty is ty is unmodified. -

    39.8.3 Type tests

    +

    40.8.3 Type tests

    @@ -2145,7 +2145,7 @@ Checks if ty is a varargs type. Checks if ty is a templatized type. -

    39.8.4 Typedef and inheritance

    +

    40.8.4 Typedef and inheritance

    @@ -2247,7 +2247,7 @@ Fully reduces ty according to typedef rules. Resulting datatype will consist only of primitive typenames. -

    39.8.5 Lvalues

    +

    40.8.5 Lvalues

    @@ -2284,7 +2284,7 @@ Literal y; // type = 'Literal', ltype='p.char' -

    39.8.6 Output functions

    +

    40.8.6 Output functions

    @@ -2346,7 +2346,7 @@ SWIG, but is most commonly associated with type-descriptor objects that appear in wrappers (e.g., SWIGTYPE_p_double). -

    39.9 Parameters

    +

    40.9 Parameters

    @@ -2445,7 +2445,7 @@ included. Used to emit prototypes. Returns the number of required (non-optional) arguments in p. -

    39.10 Writing a Language Module

    +

    40.10 Writing a Language Module

    @@ -2460,7 +2460,7 @@ describes the creation of a minimal Python module. You should be able to extra this to other languages.

    -

    39.10.1 Execution model

    +

    40.10.1 Execution model

    @@ -2470,7 +2470,7 @@ the parsing of command line options, all aspects of code generation are controll different methods of the Language that must be defined by your module.

    -

    39.10.2 Starting out

    +

    40.10.2 Starting out

    @@ -2578,7 +2578,7 @@ that activates your module. For example, swig -python foo.i. The messages from your new module should appear.

    -

    39.10.3 Command line options

    +

    40.10.3 Command line options

    @@ -2637,7 +2637,7 @@ to mark the option as valid. If you forget to do this, SWIG will terminate wit unrecognized command line option error.

    -

    39.10.4 Configuration and preprocessing

    +

    40.10.4 Configuration and preprocessing

    @@ -2686,7 +2686,7 @@ an implementation file python.cxx and a configuration file python.swg.

    -

    39.10.5 Entry point to code generation

    +

    40.10.5 Entry point to code generation

    @@ -2744,7 +2744,7 @@ int Python::top(Node *n) { -

    39.10.6 Module I/O and wrapper skeleton

    +

    40.10.6 Module I/O and wrapper skeleton

    @@ -2892,7 +2892,7 @@ functionWrapper : void Shape_y_set(Shape *self,double y) -

    39.10.7 Low-level code generators

    +

    40.10.7 Low-level code generators

    @@ -3046,7 +3046,7 @@ but without the typemaps, there is still work to do.

    -

    39.10.8 Configuration files

    +

    40.10.8 Configuration files

    @@ -3190,7 +3190,7 @@ politely displays the ignoring language message. -

    39.10.9 Runtime support

    +

    40.10.9 Runtime support

    @@ -3199,7 +3199,7 @@ Discuss the kinds of functions typically needed for SWIG runtime support (e.g. the SWIG files that implement those functions.

    -

    39.10.10 Standard library files

    +

    40.10.10 Standard library files

    @@ -3218,7 +3218,7 @@ The following are the minimum that are usually supported: Please copy these and modify for any new language.

    -

    39.10.11 User examples

    +

    40.10.11 User examples

    @@ -3247,7 +3247,7 @@ during this process, see the section on .

    -

    39.10.12 Test driven development and the test-suite

    +

    40.10.12 Test driven development and the test-suite

    @@ -3306,7 +3306,7 @@ It is therefore essential that the runtime tests are written in a manner that di but error/exception out with an error message on stderr on failure.

    -

    39.10.12.1 Running the test-suite

    +

    40.10.12.1 Running the test-suite

    @@ -3498,7 +3498,7 @@ It can be run in the same way as the other language test-suites, replacing [lang The test cases used and the way it works is described in Examples/test-suite/errors/Makefile.in.

    -

    39.10.13 Documentation

    +

    40.10.13 Documentation

    @@ -3530,7 +3530,7 @@ Some topics that you'll want to be sure to address include: if available. -

    39.10.14 Prerequisites for adding a new language module to the SWIG distribution

    +

    40.10.14 Prerequisites for adding a new language module to the SWIG distribution

    @@ -3587,7 +3587,7 @@ should be added should there be an area not already covered by the existing tests.

    -

    39.10.15 Coding style guidelines

    +

    40.10.15 Coding style guidelines

    @@ -3611,7 +3611,7 @@ The generated C/C++ code should also follow this style as close as possible. How should be avoided as unlike the SWIG developers, users will never have consistent tab settings.

    -

    39.11 Debugging Options

    +

    40.11 Debugging Options

    @@ -3638,7 +3638,7 @@ There are various command line options which can aid debugging a SWIG interface The complete list of command line options for SWIG are available by running swig -help.

    -

    39.12 Guide to parse tree nodes

    +

    40.12 Guide to parse tree nodes

    @@ -4046,7 +4046,7 @@ extern "X" { ... } declaration. -

    39.13 Further Development Information

    +

    40.13 Further Development Information

    diff --git a/Doc/Manual/Lisp.html b/Doc/Manual/Lisp.html index 7ea9139ac..0b8d47846 100644 --- a/Doc/Manual/Lisp.html +++ b/Doc/Manual/Lisp.html @@ -6,7 +6,7 @@ -

    26 SWIG and Common Lisp

    +

    27 SWIG and Common Lisp

      @@ -41,7 +41,7 @@ Lisp, Common Foreign Function Interface(CFFI), CLisp and UFFI foreign function interfaces.

      -

      26.1 Allegro Common Lisp

      +

      27.1 Allegro Common Lisp

      @@ -50,7 +50,7 @@ here

      -

      26.2 Common Foreign Function Interface(CFFI)

      +

      27.2 Common Foreign Function Interface(CFFI)

      @@ -77,7 +77,7 @@ swig -cffi -module module-name file-name files and the various things which you can do with them.

      -

      26.2.1 Additional Commandline Options

      +

      27.2.1 Additional Commandline Options

      @@ -118,7 +118,7 @@ swig -cffi -help -

      26.2.2 Generating CFFI bindings

      +

      27.2.2 Generating CFFI bindings

      As we mentioned earlier the ideal way to use SWIG is to use interface @@ -392,7 +392,7 @@ The feature intern_function ensures that all C names are
    -

    26.2.3 Generating CFFI bindings for C++ code

    +

    27.2.3 Generating CFFI bindings for C++ code

    This feature to SWIG (for CFFI) is very new and still far from @@ -568,7 +568,7 @@ If you have any questions, suggestions, patches, etc., related to CFFI module feel free to contact us on the SWIG mailing list, and also please add a "[CFFI]" tag in the subject line. -

    26.2.4 Inserting user code into generated files

    +

    27.2.4 Inserting user code into generated files

    @@ -608,7 +608,7 @@ Note that the block %{ ... %} is effectively a shortcut for

    -

    26.3 CLISP

    +

    27.3 CLISP

    @@ -638,7 +638,7 @@ swig -clisp -module module-name file-name interface file for the CLISP module. The CLISP module tries to produce code which is both human readable and easily modifyable.

    -

    26.3.1 Additional Commandline Options

    +

    27.3.1 Additional Commandline Options

    @@ -671,7 +671,7 @@ and global variables will be created otherwise only definitions for
    -

    26.3.2 Details on CLISP bindings

    +

    27.3.2 Details on CLISP bindings

    @@ -795,7 +795,7 @@ struct bar { -

    26.4 UFFI

    +

    27.4 UFFI

    diff --git a/Doc/Manual/Modula3.html b/Doc/Manual/Modula3.html index 0bf9f2995..ffbf6132d 100644 --- a/Doc/Manual/Modula3.html +++ b/Doc/Manual/Modula3.html @@ -5,7 +5,7 @@ -

    28 SWIG and Modula-3

    +

    29 SWIG and Modula-3

      @@ -54,7 +54,7 @@ especially typemaps.

      -

      28.1 Overview

      +

      29.1 Overview

      @@ -84,7 +84,7 @@ FFTW -

      28.1.1 Motivation

      +

      29.1.1 Motivation

      @@ -131,10 +131,10 @@ functions), but it doesn't allow you to easily integrate a Modula-3 module into a C/C++ project.

      -

      28.2 Conception

      +

      29.2 Conception

      -

      28.2.1 Interfaces to C libraries

      +

      29.2.1 Interfaces to C libraries

      @@ -283,7 +283,7 @@ and the principal type must be renamed (%typemap).

      -

      28.2.2 Interfaces to C++ libraries

      +

      29.2.2 Interfaces to C++ libraries

      @@ -384,10 +384,10 @@ There is no C++ library I wrote a SWIG interface for, so I'm not sure if this is possible or sensible, yet.

      -

      28.3 Preliminaries

      +

      29.3 Preliminaries

      -

      28.3.1 Compilers

      +

      29.3.1 Compilers

      @@ -400,7 +400,7 @@ For testing examples I use Critical Mass cm3.

      -

      28.3.2 Additional Commandline Options

      +

      29.3.2 Additional Commandline Options

      @@ -477,10 +477,10 @@ Instead generate templates for some basic typemaps. -

      28.4 Modula-3 typemaps

      +

      29.4 Modula-3 typemaps

      -

      28.4.1 Inputs and outputs

      +

      29.4.1 Inputs and outputs

      @@ -694,7 +694,7 @@ consist of the following parts: -

      28.4.2 Subranges, Enumerations, Sets

      +

      29.4.2 Subranges, Enumerations, Sets

      @@ -746,7 +746,7 @@ that I'd like to automate.

      -

      28.4.3 Objects

      +

      29.4.3 Objects

      @@ -759,7 +759,7 @@ is not really useful, yet.

      -

      28.4.4 Imports

      +

      29.4.4 Imports

      @@ -792,7 +792,7 @@ IMPORT M3toC;

    -

    28.4.5 Exceptions

    +

    29.4.5 Exceptions

    @@ -816,7 +816,7 @@ you should declare %typemap("m3wrapinconv:throws") blah * %{OSError.E%}.

    -

    28.4.6 Example

    +

    29.4.6 Example

    @@ -863,10 +863,10 @@ where almost everything is generated by a typemap: -

    28.5 More hints to the generator

    +

    29.5 More hints to the generator

    -

    28.5.1 Features

    +

    29.5.1 Features

    @@ -903,7 +903,7 @@ where almost everything is generated by a typemap:
    -

    28.5.2 Pragmas

    +

    29.5.2 Pragmas

    @@ -926,7 +926,7 @@ where almost everything is generated by a typemap:
    -

    28.6 Remarks

    +

    29.6 Remarks

      diff --git a/Doc/Manual/Mzscheme.html b/Doc/Manual/Mzscheme.html index 40173d720..fadda5fc9 100644 --- a/Doc/Manual/Mzscheme.html +++ b/Doc/Manual/Mzscheme.html @@ -8,7 +8,7 @@ -

      29 SWIG and MzScheme/Racket

      +

      30 SWIG and MzScheme/Racket

        @@ -24,7 +24,7 @@

        This section contains information on SWIG's support of Racket, formally known as MzScheme. -

        29.1 Creating native structures

        +

        30.1 Creating native structures

        @@ -65,7 +65,7 @@ Then in scheme, you can use regular struct access procedures like

      -

      29.2 Simple example

      +

      30.2 Simple example

      @@ -166,7 +166,7 @@ Some points of interest:

    • The above requests mzc to create an extension using the CGC garbage-collector. The alternative -- the 3m collector -- has generally better performance, but work is still required for SWIG to emit code which is compatible with it.
    -

    29.3 External documentation

    +

    30.3 External documentation

    diff --git a/Doc/Manual/Ocaml.html b/Doc/Manual/Ocaml.html index ec46d6e50..aa6679f9a 100644 --- a/Doc/Manual/Ocaml.html +++ b/Doc/Manual/Ocaml.html @@ -6,7 +6,7 @@ -

    30 SWIG and Ocaml

    +

    31 SWIG and Ocaml

      @@ -80,7 +80,7 @@ If you're not familiar with the Objective Caml language, you can visit The Ocaml Website.

      -

      30.1 Preliminaries

      +

      31.1 Preliminaries

      @@ -99,7 +99,7 @@ file Examples/Makefile illustrate how to compile and link SWIG modules that will be loaded dynamically. This has only been tested on Linux so far.

      -

      30.1.1 Running SWIG

      +

      31.1.1 Running SWIG

      @@ -122,7 +122,7 @@ you will compile the file example_wrap.c with ocamlc or the resulting .ml and .mli files as well, and do the final link with -custom (not needed for native link).

      -

      30.1.2 Compiling the code

      +

      31.1.2 Compiling the code

      @@ -158,7 +158,7 @@ the user more freedom with respect to custom typing.

    -

    30.1.3 The camlp4 module

    +

    31.1.3 The camlp4 module

    @@ -234,7 +234,7 @@ let b = C_string (getenv "PATH") -

    30.1.4 Using your module

    +

    31.1.4 Using your module

    @@ -248,7 +248,7 @@ When linking any ocaml bytecode with your module, use the -custom option is not needed when you build native code.

    -

    30.1.5 Compilation problems and compiling with C++

    +

    31.1.5 Compilation problems and compiling with C++

    @@ -259,7 +259,7 @@ liberal with pointer types may not compile under the C++ compiler. Most code meant to be compiled as C++ will not have problems.

    -

    30.2 The low-level Ocaml/C interface

    +

    31.2 The low-level Ocaml/C interface

    @@ -360,7 +360,7 @@ is that you must append them to the return list with swig_result = caml_list_a signature for a function that uses value in this way.

    -

    30.2.1 The generated module

    +

    31.2.1 The generated module

    @@ -394,7 +394,7 @@ it describes the output SWIG will generate for class definitions. -

    30.2.2 Enums

    +

    31.2.2 Enums

    @@ -457,7 +457,7 @@ val x : Enum_test.c_obj = C_enum `a -

    30.2.2.1 Enum typing in Ocaml

    +

    31.2.2.1 Enum typing in Ocaml

    @@ -470,10 +470,10 @@ functions imported from different modules. You must convert values to master values using the swig_val function before sharing them with another module.

    -

    30.2.3 Arrays

    +

    31.2.3 Arrays

    -

    30.2.3.1 Simple types of bounded arrays

    +

    31.2.3.1 Simple types of bounded arrays

    @@ -494,7 +494,7 @@ arrays of simple types with known bounds in your code, but this only works for arrays whose bounds are completely specified.

    -

    30.2.3.2 Complex and unbounded arrays

    +

    31.2.3.2 Complex and unbounded arrays

    @@ -507,7 +507,7 @@ SWIG can't predict which of these methods will be used in the array, so you have to specify it for yourself in the form of a typemap.

    -

    30.2.3.3 Using an object

    +

    31.2.3.3 Using an object

    @@ -521,7 +521,7 @@ Consider writing an object when the ending condition of your array is complex, such as using a required sentinel, etc.

    -

    30.2.3.4 Example typemap for a function taking float * and int

    +

    31.2.3.4 Example typemap for a function taking float * and int

    @@ -572,7 +572,7 @@ void printfloats( float *tab, int len ); -

    30.2.4 C++ Classes

    +

    31.2.4 C++ Classes

    @@ -615,7 +615,7 @@ the underlying pointer, so using create_[x]_from_ptr alters the returned value for the same object.

    -

    30.2.4.1 STL vector and string Example

    +

    31.2.4.1 STL vector and string Example

    @@ -695,7 +695,7 @@ baz # -

    30.2.4.2 C++ Class Example

    +

    31.2.4.2 C++ Class Example

    @@ -725,7 +725,7 @@ public: }; -

    30.2.4.3 Compiling the example

    +

    31.2.4.3 Compiling the example

    @@ -743,7 +743,7 @@ bash-2.05a$ ocamlmktop -custom swig.cmo -I `camlp4 -where` \
       -L$QTPATH/lib -cclib -lqt
     
    -

    30.2.4.4 Sample Session

    +

    31.2.4.4 Sample Session

    @@ -770,10 +770,10 @@ Assuming you have a working installation of QT, you will see a window
     containing the string "hi" in a button.  
     

    -

    30.2.5 Director Classes

    +

    31.2.5 Director Classes

    -

    30.2.5.1 Director Introduction

    +

    31.2.5.1 Director Introduction

    @@ -800,7 +800,7 @@ class foo { };

    -

    30.2.5.2 Overriding Methods in Ocaml

    +

    31.2.5.2 Overriding Methods in Ocaml

    @@ -828,7 +828,7 @@ In this example, I'll examine the objective caml code involved in providing an overloaded class. This example is contained in Examples/ocaml/shapes.

    -

    30.2.5.3 Director Usage Example

    +

    31.2.5.3 Director Usage Example

    @@ -887,7 +887,7 @@ in a more effortless style in ocaml, while leaving the "engine" part of the program in C++.

    -

    30.2.5.4 Creating director objects

    +

    31.2.5.4 Creating director objects

    @@ -928,7 +928,7 @@ object from causing a core dump, as long as the object is destroyed properly.

    -

    30.2.5.5 Typemaps for directors, directorin, directorout, directorargout

    +

    31.2.5.5 Typemaps for directors, directorin, directorout, directorargout

    @@ -939,7 +939,7 @@ well as a function return value in the same way you provide function arguments, and to receive arguments the same way you normally receive function returns.

    -

    30.2.5.6 directorin typemap

    +

    31.2.5.6 directorin typemap

    @@ -950,7 +950,7 @@ code receives when you are called. In general, a simple directorin typ can use the same body as a simple out typemap.

    -

    30.2.5.7 directorout typemap

    +

    31.2.5.7 directorout typemap

    @@ -961,7 +961,7 @@ for the same type, except when there are special requirements for object ownership, etc.

    -

    30.2.5.8 directorargout typemap

    +

    31.2.5.8 directorargout typemap

    @@ -978,7 +978,7 @@ In the event that you don't specify all of the necessary values, integral values will read zero, and struct or object returns have undefined results.

    -

    30.2.6 Exceptions

    +

    31.2.6 Exceptions

    diff --git a/Doc/Manual/Octave.html b/Doc/Manual/Octave.html index bc6873c4b..9c3489fb8 100644 --- a/Doc/Manual/Octave.html +++ b/Doc/Manual/Octave.html @@ -8,7 +8,7 @@ -

    31 SWIG and Octave

    +

    32 SWIG and Octave

      @@ -55,7 +55,7 @@ More information can be found at O Also, there are a dozen or so examples in the Examples/octave directory, and hundreds in the test suite (Examples/test-suite and Examples/test-suite/octave).

      -

      31.1 Preliminaries

      +

      32.1 Preliminaries

      @@ -63,7 +63,7 @@ As of SWIG 3.0.0, the Octave module has been tested with Octave versions 3.0.5, Use of Octave versions older than 3.x.x is not recommended, as these versions are no longer tested with SWIG.

      -

      31.2 Running SWIG

      +

      32.2 Running SWIG

      @@ -95,7 +95,7 @@ The -c++ option is also required when wrapping C++ code: This creates a C++ source file "example_wrap.cpp". A C++ file is generated even when wrapping C code as Octave is itself written in C++ and requires wrapper code to be in the same language. The generated C++ source file contains the low-level wrappers that need to be compiled and linked with the rest of your C/C++ application (in this case, the gcd implementation) to create an extension module.

      -

      31.2.1 Command-line options

      +

      32.2.1 Command-line options

      @@ -118,7 +118,7 @@ The special name "." loads C global variables into the module namespace, i.e. al The -opprefix options sets the prefix of the names of global/friend operator functions.

      -

      31.2.2 Compiling a dynamic module

      +

      32.2.2 Compiling a dynamic module

      @@ -145,7 +145,7 @@ $ mkoctfile example_wrap.cpp example.c

      octave:1> swigexample
      -

      31.2.3 Using your module

      +

      32.2.3 Using your module

      @@ -163,10 +163,10 @@ octave:4> swigexample.cvar.Foo=4; octave:5> swigexample.cvar.Foo ans = 4

    -

    31.3 A tour of basic C/C++ wrapping

    +

    32.3 A tour of basic C/C++ wrapping

    -

    31.3.1 Modules

    +

    32.3.1 Modules

    @@ -211,7 +211,7 @@ octave:4> swigexample.gcd(4,6) ans = 2 -

    31.3.2 Functions

    +

    32.3.2 Functions

    @@ -228,7 +228,7 @@ int fact(int n);

    octave:1> swigexample.fact(4)
     24 
    -

    31.3.3 Global variables

    +

    32.3.3 Global variables

    @@ -281,7 +281,7 @@ octave:2> swigexample.PI=3.142; octave:3> swigexample.PI ans = 3.1420 -

    31.3.4 Constants and enums

    +

    32.3.4 Constants and enums

    @@ -303,7 +303,7 @@ swigexample.SCONST="Hello World" swigexample.SUNDAY=0 .... -

    31.3.5 Pointers

    +

    32.3.5 Pointers

    @@ -350,7 +350,7 @@ octave:2> f=swigexample.fopen("not there","r"); error: value on right hand side of assignment is undefined error: evaluating assignment expression near line 2, column 2 -

    31.3.6 Structures and C++ classes

    +

    32.3.6 Structures and C++ classes

    @@ -485,7 +485,7 @@ ans = 1 Depending on the ownership setting of a swig_ref, it may call C++ destructors when its reference count goes to zero. See the section on memory management below for details.

    -

    31.3.7 C++ inheritance

    +

    32.3.7 C++ inheritance

    @@ -494,7 +494,7 @@ This information contains the full class hierarchy. When an indexing operation ( the tree is walked to find a match in the current class as well as any of its bases. The lookup is then cached in the swig_ref.

    -

    31.3.8 C++ overloaded functions

    +

    32.3.8 C++ overloaded functions

    @@ -504,7 +504,7 @@ The dispatch function selects which overload to call (if any) based on the passe typecheck typemaps are used to analyze each argument, as well as assign precedence. See the chapter on typemaps for details.

    -

    31.3.9 C++ operators

    +

    32.3.9 C++ operators

    @@ -608,7 +608,7 @@ On the C++ side, the default mappings are as follows: Octave can also utilise friend (i.e. non-member) operators with a simple %rename: see the example in the Examples/octave/operator directory.

    -

    31.3.10 Class extension with %extend

    +

    32.3.10 Class extension with %extend

    @@ -638,7 +638,7 @@ octave:3> printf("%s\n",a); octave:4> a.__str() 4 -

    31.3.11 C++ templates

    +

    32.3.11 C++ templates

    @@ -715,14 +715,14 @@ ans = -

    31.3.12 C++ Smart Pointers

    +

    32.3.12 C++ Smart Pointers

    C++ smart pointers are fully supported as in other modules.

    -

    31.3.13 Directors (calling Octave from C++ code)

    +

    32.3.13 Directors (calling Octave from C++ code)

    @@ -803,14 +803,14 @@ c-side routine called octave-side routine called -

    31.3.14 Threads

    +

    32.3.14 Threads

    The use of threads in wrapped Director code is not supported; i.e., an Octave-side implementation of a C++ class must be called from the Octave interpreter's thread. Anything fancier (apartment/queue model, whatever) is left to the user. Without anything fancier, this amounts to the limitation that Octave must drive the module... like, for example, an optimization package that calls Octave to evaluate an objective function.

    -

    31.3.15 Memory management

    +

    32.3.15 Memory management

    @@ -844,14 +844,14 @@ The %newobject directive may be used to control this behavior for pointers retur In the case where one wishes for the C++ side to own an object that was created in Octave (especially a Director object), one can use the __disown() method to invert this logic. Then letting the Octave reference count go to zero will not destroy the object, but destroying the object will invalidate the Octave-side object if it still exists (and call destructors of other C++ bases in the case of multiple inheritance/subclass()'ing).

    -

    31.3.16 STL support

    +

    32.3.16 STL support

    Various STL library files are provided for wrapping STL containers.

    -

    31.3.17 Matrix typemaps

    +

    32.3.17 Matrix typemaps

    diff --git a/Doc/Manual/Perl5.html b/Doc/Manual/Perl5.html index 010eb48df..8bc7cbfd3 100644 --- a/Doc/Manual/Perl5.html +++ b/Doc/Manual/Perl5.html @@ -6,7 +6,7 @@ -

    32 SWIG and Perl5

    +

    33 SWIG and Perl5

      @@ -96,7 +96,7 @@ later. We're no longer testing regularly with older versions, but Perl 5.6 seems to mostly work, while older versions don't.

      -

      32.1 Overview

      +

      33.1 Overview

      @@ -117,7 +117,7 @@ described. Advanced customization features, typemaps, and other options are found near the end of the chapter.

      -

      32.2 Preliminaries

      +

      33.2 Preliminaries

      @@ -142,7 +142,7 @@ To build the module, you will need to compile the file example_wrap.c and link it with the rest of your program.

      -

      32.2.1 Getting the right header files

      +

      33.2.1 Getting the right header files

      @@ -174,7 +174,7 @@ $ perl -e 'use Config; print "$Config{archlib}\n";'

    -

    32.2.2 Compiling a dynamic module

    +

    33.2.2 Compiling a dynamic module

    @@ -207,7 +207,7 @@ the target should be named `example.so', `example.sl', or the appropriate dynamic module name on your system.

    -

    32.2.3 Building a dynamic module with MakeMaker

    +

    33.2.3 Building a dynamic module with MakeMaker

    @@ -241,7 +241,7 @@ the preferred approach to compilation. More information about MakeMaker can be found in "Programming Perl, 2nd ed." by Larry Wall, Tom Christiansen, and Randal Schwartz.

    -

    32.2.4 Building a static version of Perl

    +

    33.2.4 Building a static version of Perl

    @@ -310,7 +310,7 @@ added to it. Depending on your machine, you may need to link with additional libraries such as -lsocket, -lnsl, -ldl, etc.

    -

    32.2.5 Using the module

    +

    33.2.5 Using the module

    @@ -463,7 +463,7 @@ system configuration (this requires root access and you will need to read the man pages).

    -

    32.2.6 Compilation problems and compiling with C++

    +

    33.2.6 Compilation problems and compiling with C++

    @@ -606,7 +606,7 @@ have to find the macro that conflicts and add an #undef into the .i file. Pleas any conflicting macros you find to swig-user mailing list.

    -

    32.2.7 Compiling for 64-bit platforms

    +

    33.2.7 Compiling for 64-bit platforms

    @@ -633,7 +633,7 @@ also introduce problems on platforms that support more than one linking standard (e.g., -o32 and -n32 on Irix).

    -

    32.3 Building Perl Extensions under Windows

    +

    33.3 Building Perl Extensions under Windows

    @@ -644,7 +644,7 @@ section assumes you are using SWIG with Microsoft Visual C++ although the procedure may be similar with other compilers.

    -

    32.3.1 Running SWIG from Developer Studio

    +

    33.3.1 Running SWIG from Developer Studio

    @@ -707,7 +707,7 @@ print "$a\n"; -

    32.3.2 Using other compilers

    +

    33.3.2 Using other compilers

    @@ -715,7 +715,7 @@ SWIG is known to work with Cygwin and may work with other compilers on Windows. For general hints and suggestions refer to the Windows chapter.

    -

    32.4 The low-level interface

    +

    33.4 The low-level interface

    @@ -725,7 +725,7 @@ can be used to control your application. However, it is also used to construct more user-friendly proxy classes as described in the next section.

    -

    32.4.1 Functions

    +

    33.4.1 Functions

    @@ -748,7 +748,7 @@ use example; $a = &example::fact(2); -

    32.4.2 Global variables

    +

    33.4.2 Global variables

    @@ -818,7 +818,7 @@ extern char *path; // Declared later in the input -

    32.4.3 Constants

    +

    33.4.3 Constants

    @@ -858,7 +858,7 @@ print example::FOO,"\n"; -

    32.4.4 Pointers

    +

    33.4.4 Pointers

    @@ -967,7 +967,7 @@ as XS and xsubpp. Given the advancement of the SWIG typesystem and the SWIG and XS, this is no longer supported.

    -

    32.4.5 Structures

    +

    33.4.5 Structures

    @@ -1101,7 +1101,7 @@ void Bar_f_set(Bar *b, Foo *val) { -

    32.4.6 C++ classes

    +

    33.4.6 C++ classes

    @@ -1166,7 +1166,7 @@ provides direct access to C++ objects. A higher level interface using Perl prox can be built using these low-level accessors. This is described shortly.

    -

    32.4.7 C++ classes and type-checking

    +

    33.4.7 C++ classes and type-checking

    @@ -1202,7 +1202,7 @@ If necessary, the type-checker also adjusts the value of the pointer (as is nece multiple inheritance is used).

    -

    32.4.8 C++ overloaded functions

    +

    33.4.8 C++ overloaded functions

    @@ -1246,7 +1246,7 @@ example::Spam_foo_d($s,3.14); Please refer to the "SWIG Basics" chapter for more information.

    -

    32.4.9 Operators

    +

    33.4.9 Operators

    @@ -1273,7 +1273,7 @@ The following C++ operators are currently supported by the Perl module:

  • operator or
  • -

    32.4.10 Modules and packages

    +

    33.4.10 Modules and packages

    @@ -1368,7 +1368,7 @@ print Foo::fact(4),"\n"; # Call a function in package FooBar --> -

    32.5 Input and output parameters

    +

    33.5 Input and output parameters

    @@ -1587,7 +1587,7 @@ print "$c\n"; Note: The REFERENCE feature is only currently supported for numeric types (integers and floating point).

    -

    32.6 Exception handling

    +

    33.6 Exception handling

    @@ -1752,7 +1752,7 @@ This is still supported, but it is deprecated. The newer %exception di functionality, but it has additional capabilities that make it more powerful.

    -

    32.7 Remapping datatypes with typemaps

    +

    33.7 Remapping datatypes with typemaps

    @@ -1769,7 +1769,7 @@ Typemaps are only used if you want to change some aspect of the primitive C-Perl interface.

    -

    32.7.1 A simple typemap example

    +

    33.7.1 A simple typemap example

    @@ -1873,7 +1873,7 @@ example::count("e","Hello World"); -

    32.7.2 Perl5 typemaps

    +

    33.7.2 Perl5 typemaps

    @@ -1978,7 +1978,7 @@ Return of C++ member data (all languages). Check value of input parameter. -

    32.7.3 Typemap variables

    +

    33.7.3 Typemap variables

    @@ -2049,7 +2049,7 @@ properly assigned. The Perl name of the wrapper function being created. -

    32.7.4 Useful functions

    +

    33.7.4 Useful functions

    @@ -2118,7 +2118,7 @@ int sv_isa(SV *, char *0; -

    32.8 Typemap Examples

    +

    33.8 Typemap Examples

    @@ -2127,7 +2127,7 @@ might look at the files "perl5.swg" and "typemaps.i" in the SWIG library.

    -

    32.8.1 Converting a Perl5 array to a char **

    +

    33.8.1 Converting a Perl5 array to a char **

    @@ -2219,7 +2219,7 @@ print @$b,"\n"; # Print it out -

    32.8.2 Return values

    +

    33.8.2 Return values

    @@ -2248,7 +2248,7 @@ can be done using the EXTEND() macro as in: } -

    32.8.3 Returning values from arguments

    +

    33.8.3 Returning values from arguments

    @@ -2302,7 +2302,7 @@ print "multout(7,13) = @r\n"; ($x,$y) = multout(7,13); -

    32.8.4 Accessing array structure members

    +

    33.8.4 Accessing array structure members

    @@ -2365,7 +2365,7 @@ the "in" typemap in the previous section would be used to convert an to copy the converted array into a C data structure.

    -

    32.8.5 Turning Perl references into C pointers

    +

    33.8.5 Turning Perl references into C pointers

    @@ -2430,7 +2430,7 @@ print "$c\n"; -

    32.8.6 Pointer handling

    +

    33.8.6 Pointer handling

    @@ -2509,7 +2509,7 @@ For example: -

    32.9 Proxy classes

    +

    33.9 Proxy classes

    @@ -2525,7 +2525,7 @@ to the underlying code. This section describes the implementation details of the proxy interface.

    -

    32.9.1 Preliminaries

    +

    33.9.1 Preliminaries

    @@ -2547,7 +2547,7 @@ SWIG creates a collection of high-level Perl wrappers. In your scripts, you wil high level wrappers. The wrappers, in turn, interact with the low-level procedural module.

    -

    32.9.2 Structure and class wrappers

    +

    33.9.2 Structure and class wrappers

    @@ -2673,7 +2673,7 @@ $v->DESTROY(); -

    32.9.3 Object Ownership

    +

    33.9.3 Object Ownership

    @@ -2760,7 +2760,7 @@ counting, garbage collection, or advanced features one might find in sophisticated languages.

    -

    32.9.4 Nested Objects

    +

    33.9.4 Nested Objects

    @@ -2813,7 +2813,7 @@ $p->{f}->{x} = 0.0; %${$p->{v}} = ( x=>0, y=>0, z=>0); -

    32.9.5 Proxy Functions

    +

    33.9.5 Proxy Functions

    @@ -2847,7 +2847,7 @@ This function replaces the original function, but operates in an identical manner.

    -

    32.9.6 Inheritance

    +

    33.9.6 Inheritance

    @@ -2923,7 +2923,7 @@ particular, inheritance of data members is extremely tricky (and I'm not even sure if it really works).

    -

    32.9.7 Modifying the proxy methods

    +

    33.9.7 Modifying the proxy methods

    @@ -2951,7 +2951,7 @@ public: }; -

    32.10 Adding additional Perl code

    +

    33.10 Adding additional Perl code

    @@ -3002,7 +3002,7 @@ set_transform($im, $a); -

    32.11 Cross language polymorphism

    +

    33.11 Cross language polymorphism

    @@ -3036,7 +3036,7 @@ proxy classes, director classes, and C wrapper functions takes care of all the cross-language method routing transparently.

    -

    32.11.1 Enabling directors

    +

    33.11.1 Enabling directors

    @@ -3126,7 +3126,7 @@ sub one { -

    32.11.2 Director classes

    +

    33.11.2 Director classes

    @@ -3206,7 +3206,7 @@ so there is no need for the extra overhead involved with routing the calls through Perl.

    -

    32.11.3 Ownership and object destruction

    +

    33.11.3 Ownership and object destruction

    @@ -3255,7 +3255,7 @@ sub DESTROY { -

    32.11.4 Exception unrolling

    +

    33.11.4 Exception unrolling

    @@ -3311,7 +3311,7 @@ Swig::DirectorMethodException is thrown, Perl will register the exception as soon as the C wrapper function returns.

    -

    32.11.5 Overhead and code bloat

    +

    33.11.5 Overhead and code bloat

    @@ -3345,7 +3345,7 @@ directive) for only those methods that are likely to be extended in Perl.

    -

    32.11.6 Typemaps

    +

    33.11.6 Typemaps

    diff --git a/Doc/Manual/Php.html b/Doc/Manual/Php.html index 493c861f8..7e5cccf6a 100644 --- a/Doc/Manual/Php.html +++ b/Doc/Manual/Php.html @@ -7,7 +7,7 @@ -

    33 SWIG and PHP

    +

    34 SWIG and PHP

      @@ -79,7 +79,7 @@ your extension into php directly, you will need the complete PHP source tree available.

      -

      33.1 Generating PHP Extensions

      +

      34.1 Generating PHP Extensions

      @@ -126,7 +126,7 @@ and it doesn't play nicely with package system. We don't recommend this approach, or provide explicit support for it.

      -

      33.1.1 Building a loadable extension

      +

      34.1.1 Building a loadable extension

      @@ -141,7 +141,7 @@ least work for Linux though): gcc -shared example_wrap.o -o example.so

    -

    33.1.2 Using PHP Extensions

    +

    34.1.2 Using PHP Extensions

    @@ -172,7 +172,7 @@ attempts to do the dl() call for you: include("example.php"); -

    33.2 Basic PHP interface

    +

    34.2 Basic PHP interface

    @@ -183,7 +183,7 @@ other symbols unless care is taken to %rename them. At present SWIG doesn't have support for the namespace feature added in PHP 5.3.

    -

    33.2.1 Constants

    +

    34.2.1 Constants

    @@ -260,7 +260,7 @@ is treated as true by the if test, when the value of the intended constant would be treated as false!

    -

    33.2.2 Global Variables

    +

    34.2.2 Global Variables

    @@ -309,7 +309,7 @@ undefined. At this time SWIG does not support custom accessor methods.

    -

    33.2.3 Functions

    +

    34.2.3 Functions

    @@ -362,7 +362,7 @@ print $s; # The value of $s was not changed. --> -

    33.2.4 Overloading

    +

    34.2.4 Overloading

    @@ -418,7 +418,7 @@ taking the integer argument.

    --> -

    33.2.5 Pointers and References

    +

    34.2.5 Pointers and References

    @@ -563,7 +563,7 @@ PHP in a number of ways: by using unset on an existing variable, or assigning NULL to a variable.

    -

    33.2.6 Structures and C++ classes

    +

    34.2.6 Structures and C++ classes

    @@ -624,7 +624,7 @@ Would be used in the following way from PHP5: Member variables and methods are accessed using the -> operator.

    -

    33.2.6.1 Using -noproxy

    +

    34.2.6.1 Using -noproxy

    @@ -650,7 +650,7 @@ Complex_im_set($obj,$d); Complex_im_get($obj); -

    33.2.6.2 Constructors and Destructors

    +

    34.2.6.2 Constructors and Destructors

    @@ -691,7 +691,7 @@ the programmer can either reassign the variable or call unset($v)

    -

    33.2.6.3 Static Member Variables

    +

    34.2.6.3 Static Member Variables

    @@ -734,7 +734,7 @@ Ko::threats(10); echo "There have now been " . Ko::threats() . " threats\n"; -

    33.2.6.4 Static Member Functions

    +

    34.2.6.4 Static Member Functions

    @@ -756,7 +756,7 @@ Ko::threats(); -

    33.2.7 PHP Pragmas, Startup and Shutdown code

    +

    34.2.7 PHP Pragmas, Startup and Shutdown code

    @@ -844,7 +844,7 @@ The %rinit and %rshutdown statements are very similar but inse into the request init (PHP_RINIT_FUNCTION) and request shutdown (PHP_RSHUTDOWN_FUNCTION) code respectively.

    -

    33.3 Cross language polymorphism

    +

    34.3 Cross language polymorphism

    @@ -879,7 +879,7 @@ wrapper functions takes care of all the cross-language method routing transparently.

    -

    33.3.1 Enabling directors

    +

    34.3.1 Enabling directors

    @@ -968,7 +968,7 @@ class MyFoo extends Foo { -

    33.3.2 Director classes

    +

    34.3.2 Director classes

    @@ -1048,7 +1048,7 @@ so there is no need for the extra overhead involved with routing the calls through PHP.

    -

    33.3.3 Ownership and object destruction

    +

    34.3.3 Ownership and object destruction

    @@ -1104,7 +1104,7 @@ In this example, we are assuming that FooContainer will take care of deleting all the Foo pointers it contains at some point.

    -

    33.3.4 Exception unrolling

    +

    34.3.4 Exception unrolling

    @@ -1163,7 +1163,7 @@ Swig::DirectorMethodException is thrown, PHP will register the exception as soon as the C wrapper function returns.

    -

    33.3.5 Overhead and code bloat

    +

    34.3.5 Overhead and code bloat

    @@ -1196,7 +1196,7 @@ optimized by selectively enabling director methods (using the %feature directive) for only those methods that are likely to be extended in PHP.

    -

    33.3.6 Typemaps

    +

    34.3.6 Typemaps

    @@ -1210,7 +1210,7 @@ need to be supported.

    -

    33.3.7 Miscellaneous

    +

    34.3.7 Miscellaneous

    Director typemaps for STL classes are mostly in place, and hence you diff --git a/Doc/Manual/Pike.html b/Doc/Manual/Pike.html index 3ede1a992..44c6930f8 100644 --- a/Doc/Manual/Pike.html +++ b/Doc/Manual/Pike.html @@ -6,7 +6,7 @@ -

    34 SWIG and Pike

    +

    35 SWIG and Pike

      @@ -46,10 +46,10 @@ least, make sure you read the "SWIG Basics" chapter.

      -

      34.1 Preliminaries

      +

      35.1 Preliminaries

      -

      34.1.1 Running SWIG

      +

      35.1.1 Running SWIG

      @@ -94,7 +94,7 @@ can use the -o option:

      $ swig -pike -o pseudonym.c example.i
      -

      34.1.2 Getting the right header files

      +

      35.1.2 Getting the right header files

      @@ -114,7 +114,7 @@ You're looking for files with the names global.h, program.h and so on.

      -

      34.1.3 Using your module

      +

      35.1.3 Using your module

      @@ -129,10 +129,10 @@ Pike v7.4 release 10 running Hilfe v3.5 (Incremental Pike Frontend) (1) Result: 24

    -

    34.2 Basic C/C++ Mapping

    +

    35.2 Basic C/C++ Mapping

    -

    34.2.1 Modules

    +

    35.2.1 Modules

    @@ -143,7 +143,7 @@ concerned), SWIG's %module directive doesn't really have any significance.

    -

    34.2.2 Functions

    +

    35.2.2 Functions

    @@ -168,7 +168,7 @@ exactly as you'd expect it to: (1) Result: 24 -

    34.2.3 Global variables

    +

    35.2.3 Global variables

    @@ -197,7 +197,7 @@ will result in two functions, Foo_get() and Foo_set(): (3) Result: 3.141590 -

    34.2.4 Constants and enumerated types

    +

    35.2.4 Constants and enumerated types

    @@ -205,7 +205,7 @@ Enumerated types in C/C++ declarations are wrapped as Pike constants, not as Pike enums.

    -

    34.2.5 Constructors and Destructors

    +

    35.2.5 Constructors and Destructors

    @@ -213,7 +213,7 @@ Constructors are wrapped as create() methods, and destructors are wrapped as destroy() methods, for Pike classes.

    -

    34.2.6 Static Members

    +

    35.2.6 Static Members

    diff --git a/Doc/Manual/Python.html b/Doc/Manual/Python.html index 9b86652f4..bdb1ada30 100644 --- a/Doc/Manual/Python.html +++ b/Doc/Manual/Python.html @@ -6,7 +6,7 @@ -

    35 SWIG and Python

    +

    36 SWIG and Python

      @@ -141,7 +141,7 @@ very least, make sure you read the "SWIG Basics" chapter.

      -

      35.1 Overview

      +

      36.1 Overview

      @@ -168,10 +168,10 @@ described followed by a discussion of low-level implementation details.

      -

      35.2 Preliminaries

      +

      36.2 Preliminaries

      -

      35.2.1 Running SWIG

      +

      36.2.1 Running SWIG

      @@ -269,7 +269,7 @@ The following sections have further practical examples and details on how you might go about compiling and using the generated files.

      -

      35.2.2 Using distutils

      +

      36.2.2 Using distutils

      @@ -361,7 +361,7 @@ This same approach works on all platforms if the appropriate compiler is install can even build extensions to the standard Windows Python using MingGW)

      -

      35.2.3 Hand compiling a dynamic module

      +

      36.2.3 Hand compiling a dynamic module

      @@ -409,7 +409,7 @@ module actually consists of two files; socket.py and

      -

      35.2.4 Static linking

      +

      36.2.4 Static linking

      @@ -488,7 +488,7 @@ If using static linking, you might want to rely on a different approach (perhaps using distutils).

      -

      35.2.5 Using your module

      +

      36.2.5 Using your module

      @@ -645,7 +645,7 @@ system configuration (this requires root access and you will need to read the man pages).

      -

      35.2.6 Compilation of C++ extensions

      +

      36.2.6 Compilation of C++ extensions

      @@ -737,7 +737,7 @@ erratic program behavior. If working with lots of software components, you might want to investigate using a more formal standard such as COM.

      -

      35.2.7 Compiling for 64-bit platforms

      +

      36.2.7 Compiling for 64-bit platforms

      @@ -774,7 +774,7 @@ and -m64 allow you to choose the desired binary format for your python extension.

      -

      35.2.8 Building Python Extensions under Windows

      +

      36.2.8 Building Python Extensions under Windows

      @@ -903,7 +903,7 @@ SWIG Wiki.

      -

      35.3 A tour of basic C/C++ wrapping

      +

      36.3 A tour of basic C/C++ wrapping

      @@ -912,7 +912,7 @@ to your C/C++ code. Functions are wrapped as functions, classes are wrapped as This section briefly covers the essential aspects of this wrapping.

      -

      35.3.1 Modules

      +

      36.3.1 Modules

      @@ -925,7 +925,7 @@ module name, make sure you don't use the same name as a built-in Python command or standard module name.

      -

      35.3.2 Functions

      +

      36.3.2 Functions

      @@ -949,7 +949,7 @@ like you think it does: >>>

    -

    35.3.3 Global variables

    +

    36.3.3 Global variables

    @@ -1087,7 +1087,7 @@ that starts with a leading underscore. SWIG does not create cvar if there are no global variables in a module.

    -

    35.3.4 Constants and enums

    +

    36.3.4 Constants and enums

    @@ -1127,7 +1127,7 @@ other object. Unfortunately, there is no easy way for SWIG to generate code that prevents this. You will just have to be careful.

    -

    35.3.5 Pointers

    +

    36.3.5 Pointers

    @@ -1268,7 +1268,7 @@ C-style cast may return a bogus result whereas as the C++-style cast will return None if the conversion can't be performed.

    -

    35.3.6 Structures

    +

    36.3.6 Structures

    @@ -1457,7 +1457,7 @@ everything works just like you would expect. For example: -

    35.3.7 C++ classes

    +

    36.3.7 C++ classes

    @@ -1546,7 +1546,7 @@ they are accessed through cvar like this: -

    35.3.8 C++ inheritance

    +

    36.3.8 C++ inheritance

    @@ -1601,7 +1601,7 @@ then the function spam() accepts Foo * or a pointer to any cla It is safe to use multiple inheritance with SWIG.

    -

    35.3.9 Pointers, references, values, and arrays

    +

    36.3.9 Pointers, references, values, and arrays

    @@ -1662,7 +1662,7 @@ treated as a returning value, and it will follow the same allocation/deallocation process.

    -

    35.3.10 C++ overloaded functions

    +

    36.3.10 C++ overloaded functions

    @@ -1785,7 +1785,7 @@ first declaration takes precedence. Please refer to the "SWIG and C++" chapter for more information about overloading.

    -

    35.3.11 C++ operators

    +

    36.3.11 C++ operators

    @@ -1874,7 +1874,7 @@ Also, be aware that certain operators don't map cleanly to Python. For instance overloaded assignment operators don't map to Python semantics and will be ignored.

    -

    35.3.12 C++ namespaces

    +

    36.3.12 C++ namespaces

    @@ -1941,7 +1941,7 @@ utilizes thousands of small deeply nested namespaces each with identical symbol names, well, then you get what you deserve.

    -

    35.3.13 C++ templates

    +

    36.3.13 C++ templates

    @@ -1995,7 +1995,7 @@ Some more complicated examples will appear later.

    -

    35.3.14 C++ Smart Pointers

    +

    36.3.14 C++ Smart Pointers

    @@ -2079,7 +2079,7 @@ simply use the __deref__() method. For example: -

    35.3.15 C++ reference counted objects

    +

    36.3.15 C++ reference counted objects

    @@ -2088,7 +2088,7 @@ Python examples of memory management using referencing counting.

    -

    35.4 Further details on the Python class interface

    +

    36.4 Further details on the Python class interface

    @@ -2111,7 +2111,7 @@ the -builtin option are in the Built-in section.

    -

    35.4.1 Proxy classes

    +

    36.4.1 Proxy classes

    @@ -2200,7 +2200,7 @@ you can attach new Python methods to the class and you can even inherit from it by Python built-in types until Python 2.2).

    -

    35.4.2 Built-in Types

    +

    36.4.2 Built-in Types

    @@ -2244,7 +2244,7 @@ please refer to the python documentation:

    http://docs.python.org/extending/newtypes.html

    -

    35.4.2.1 Limitations

    +

    36.4.2.1 Limitations

    Use of the -builtin option implies a couple of limitations: @@ -2412,7 +2412,7 @@ assert(issubclass(B.Derived, A.Base)) -

    35.4.2.2 Operator overloads -- use them!

    +

    36.4.2.2 Operator overloads -- use them!

    The entire justification for the -builtin option is improved @@ -2513,7 +2513,7 @@ structs.

    -

    35.4.3 Memory management

    +

    36.4.3 Memory management

    NOTE: Although this section refers to proxy objects, everything here also applies @@ -2708,7 +2708,7 @@ It is also possible to deal with situations like this using typemaps--an advanced topic discussed later.

    -

    35.4.4 Python 2.2 and classic classes

    +

    36.4.4 Python 2.2 and classic classes

    @@ -2745,7 +2745,7 @@ class itself. In Python-2.1 and earlier, they have to be accessed as a global function or through an instance (see the earlier section).

    -

    35.5 Cross language polymorphism

    +

    36.5 Cross language polymorphism

    @@ -2779,7 +2779,7 @@ proxy classes, director classes, and C wrapper functions takes care of all the cross-language method routing transparently.

    -

    35.5.1 Enabling directors

    +

    36.5.1 Enabling directors

    @@ -2869,7 +2869,7 @@ class MyFoo(mymodule.Foo): -

    35.5.2 Director classes

    +

    36.5.2 Director classes

    @@ -2951,7 +2951,7 @@ so there is no need for the extra overhead involved with routing the calls through Python.

    -

    35.5.3 Ownership and object destruction

    +

    36.5.3 Ownership and object destruction

    @@ -3018,7 +3018,7 @@ deleting all the Foo pointers it contains at some point. Note that no hard references to the Foo objects remain in Python.

    -

    35.5.4 Exception unrolling

    +

    36.5.4 Exception unrolling

    @@ -3077,7 +3077,7 @@ Swig::DirectorMethodException is thrown, Python will register the exception as soon as the C wrapper function returns.

    -

    35.5.5 Overhead and code bloat

    +

    36.5.5 Overhead and code bloat

    @@ -3111,7 +3111,7 @@ directive) for only those methods that are likely to be extended in Python.

    -

    35.5.6 Typemaps

    +

    36.5.6 Typemaps

    @@ -3125,7 +3125,7 @@ need to be supported.

    -

    35.5.7 Miscellaneous

    +

    36.5.7 Miscellaneous

    @@ -3172,7 +3172,7 @@ methods that return const references.

    -

    35.6 Common customization features

    +

    36.6 Common customization features

    @@ -3185,7 +3185,7 @@ This section describes some common SWIG features that are used to improve your the interface to an extension module.

    -

    35.6.1 C/C++ helper functions

    +

    36.6.1 C/C++ helper functions

    @@ -3266,7 +3266,7 @@ hard to implement. It is possible to clean this up using Python code, typemaps, customization features as covered in later sections.

    -

    35.6.2 Adding additional Python code

    +

    36.6.2 Adding additional Python code

    @@ -3494,7 +3494,7 @@ The same applies for overloaded constructors.

    -

    35.6.3 Class extension with %extend

    +

    36.6.3 Class extension with %extend

    @@ -3583,7 +3583,7 @@ Vector(12,14,16) in any way---the extensions only show up in the Python interface.

    -

    35.6.4 Exception handling with %exception

    +

    36.6.4 Exception handling with %exception

    @@ -3709,7 +3709,7 @@ The language-independent exception.i library file can also be used to raise exceptions. See the SWIG Library chapter.

    -

    35.7 Tips and techniques

    +

    36.7 Tips and techniques

    @@ -3719,7 +3719,7 @@ strings, binary data, and arrays. This chapter discusses the common techniques solving these problems.

    -

    35.7.1 Input and output parameters

    +

    36.7.1 Input and output parameters

    @@ -3932,7 +3932,7 @@ void foo(Bar *OUTPUT); may not have the intended effect since typemaps.i does not define an OUTPUT rule for Bar.

    -

    35.7.2 Simple pointers

    +

    36.7.2 Simple pointers

    @@ -4001,7 +4001,7 @@ If you replace %pointer_functions() by %pointer_class(type,name)SWIG Library chapter for further details.

    -

    35.7.3 Unbounded C Arrays

    +

    36.7.3 Unbounded C Arrays

    @@ -4063,7 +4063,7 @@ well suited for applications in which you need to create buffers, package binary data, etc.

    -

    35.7.4 String handling

    +

    36.7.4 String handling

    @@ -4132,7 +4132,7 @@ If you need to return binary data, you might use the also be used to extra binary data from arbitrary pointers.

    -

    35.8 Typemaps

    +

    36.8 Typemaps

    @@ -4149,7 +4149,7 @@ Typemaps are only used if you want to change some aspect of the primitive C-Python interface or if you want to elevate your guru status.

    -

    35.8.1 What is a typemap?

    +

    36.8.1 What is a typemap?

    @@ -4265,7 +4265,7 @@ parameter is omitted): -

    35.8.2 Python typemaps

    +

    36.8.2 Python typemaps

    @@ -4306,7 +4306,7 @@ a look at the SWIG library version 1.3.20 or so.

    -

    35.8.3 Typemap variables

    +

    36.8.3 Typemap variables

    @@ -4377,7 +4377,7 @@ properly assigned. The Python name of the wrapper function being created. -

    35.8.4 Useful Python Functions

    +

    36.8.4 Useful Python Functions

    @@ -4505,7 +4505,7 @@ write me -

    35.9 Typemap Examples

    +

    36.9 Typemap Examples

    @@ -4514,7 +4514,7 @@ might look at the files "python.swg" and "typemaps.i" in the SWIG library.

    -

    35.9.1 Converting Python list to a char **

    +

    36.9.1 Converting Python list to a char **

    @@ -4594,7 +4594,7 @@ memory allocation is used to allocate memory for the array, the the C function.

    -

    35.9.2 Expanding a Python object into multiple arguments

    +

    36.9.2 Expanding a Python object into multiple arguments

    @@ -4673,7 +4673,7 @@ to supply the argument count. This is automatically set by the typemap code. F -

    35.9.3 Using typemaps to return arguments

    +

    36.9.3 Using typemaps to return arguments

    @@ -4761,7 +4761,7 @@ function can now be used as follows: >>> -

    35.9.4 Mapping Python tuples into small arrays

    +

    36.9.4 Mapping Python tuples into small arrays

    @@ -4810,7 +4810,7 @@ array, such an approach would not be recommended for huge arrays, but for small structures, this approach works fine.

    -

    35.9.5 Mapping sequences to C arrays

    +

    36.9.5 Mapping sequences to C arrays

    @@ -4899,7 +4899,7 @@ static int convert_darray(PyObject *input, double *ptr, int size) { -

    35.9.6 Pointer handling

    +

    36.9.6 Pointer handling

    @@ -4996,7 +4996,7 @@ class object (if applicable). -

    35.10 Docstring Features

    +

    36.10 Docstring Features

    @@ -5024,7 +5024,7 @@ of your users much simpler.

    -

    35.10.1 Module docstring

    +

    36.10.1 Module docstring

    @@ -5058,7 +5058,7 @@ layout of controls on a panel, etc. to be loaded from an XML file." -

    35.10.2 %feature("autodoc")

    +

    36.10.2 %feature("autodoc")

    @@ -5086,7 +5086,7 @@ four levels for autodoc controlled by the value given to the feature, %feature("autodoc", "level"). The four values for level are covered in the following sub-sections. -

    35.10.2.1 %feature("autodoc", "0")

    +

    36.10.2.1 %feature("autodoc", "0")

    @@ -5115,7 +5115,7 @@ def function_name(*args, **kwargs): -

    35.10.2.2 %feature("autodoc", "1")

    +

    36.10.2.2 %feature("autodoc", "1")

    @@ -5140,7 +5140,7 @@ def function_name(*args, **kwargs): -

    35.10.2.3 %feature("autodoc", "2")

    +

    36.10.2.3 %feature("autodoc", "2")

    @@ -5200,7 +5200,7 @@ def function_name(*args, **kwargs): -

    35.10.2.4 %feature("autodoc", "3")

    +

    36.10.2.4 %feature("autodoc", "3")

    @@ -5225,7 +5225,7 @@ def function_name(*args, **kwargs): -

    35.10.2.5 %feature("autodoc", "docstring")

    +

    36.10.2.5 %feature("autodoc", "docstring")

    @@ -5244,7 +5244,7 @@ void GetPosition(int* OUTPUT, int* OUTPUT); -

    35.10.3 %feature("docstring")

    +

    36.10.3 %feature("docstring")

    @@ -5276,7 +5276,7 @@ with more than one line. -

    35.11 Python Packages

    +

    36.11 Python Packages

    Python has concepts of modules and packages. Modules are separate units of @@ -5334,7 +5334,7 @@ users may need to use special features such as the package option in th %module directive or import related command line options. These are explained in the following sections.

    -

    35.11.1 Setting the Python package

    +

    36.11.1 Setting the Python package

    @@ -5388,7 +5388,7 @@ pkg1/pkg2/_foo.so # (shared library built from C/C++ code generated by SWI -

    35.11.2 Absolute and relative imports

    +

    36.11.2 Absolute and relative imports

    Suppose, we have the following hierarchy of files:

    @@ -5527,7 +5527,7 @@ uses relative imports. Second case is, when one puts import directives in __init__.py to import symbols from submodules or subpackages and the submodule depends on other submodules (discussed later).

    -

    35.11.3 Enforcing absolute import semantics

    +

    36.11.3 Enforcing absolute import semantics

    As you may know, there is an incompatibility in import semantics (for the @@ -5564,7 +5564,7 @@ from __future__ import absolute_import -

    35.11.4 Importing from __init__.py

    +

    36.11.4 Importing from __init__.py

    Imports in __init__.py are handy when you want to populate a @@ -5675,7 +5675,7 @@ effect (note, that the Python 2 case also needs the -relativeimport workaround).

    -

    35.12 Python 3 Support

    +

    36.12 Python 3 Support

    @@ -5702,7 +5702,7 @@ The following are Python 3.0 new features that are currently supported by SWIG.

    -

    35.12.1 Function annotation

    +

    36.12.1 Function annotation

    @@ -5735,7 +5735,7 @@ For detailed usage of function annotation, see PEP 3107.

    -

    35.12.2 Buffer interface

    +

    36.12.2 Buffer interface

    @@ -5887,7 +5887,7 @@ modify the buffer. -

    35.12.3 Abstract base classes

    +

    36.12.3 Abstract base classes

    diff --git a/Doc/Manual/R.html b/Doc/Manual/R.html index ce9523ced..5de390eab 100644 --- a/Doc/Manual/R.html +++ b/Doc/Manual/R.html @@ -6,7 +6,7 @@ -

    36 SWIG and R

    +

    37 SWIG and R

      @@ -33,7 +33,7 @@ compile and run an R interface to QuantLib running on Mandriva Linux with gcc. The R bindings also work on Microsoft Windows using Visual C++.

      -

      36.1 Bugs

      +

      37.1 Bugs

      @@ -45,7 +45,7 @@ Currently the following features are not implemented or broken:

    • C Array wrappings
    -

    36.2 Using R and SWIG

    +

    37.2 Using R and SWIG

    @@ -119,7 +119,7 @@ Without it, inheritance of wrapped objects may fail. These two files can be loaded in any order

    -

    36.3 Precompiling large R files

    +

    37.3 Precompiling large R files

    In cases where the R file is large, one make save a lot of loading @@ -137,7 +137,7 @@ will save a large amount of loading time. -

    36.4 General policy

    +

    37.4 General policy

    @@ -146,7 +146,7 @@ wrapping over the underlying functions and rely on the R type system to provide R syntax.

    -

    36.5 Language conventions

    +

    37.5 Language conventions

    @@ -155,7 +155,7 @@ and [ are overloaded to allow for R syntax (one based indices and slices)

    -

    36.6 C++ classes

    +

    37.6 C++ classes

    @@ -167,7 +167,7 @@ keep track of the pointer object which removes the necessity for a lot of the proxy class baggage you see in other languages.

    -

    36.7 Enumerations

    +

    37.7 Enumerations

    diff --git a/Doc/Manual/Ruby.html b/Doc/Manual/Ruby.html index 9719239a9..cdebfe07b 100644 --- a/Doc/Manual/Ruby.html +++ b/Doc/Manual/Ruby.html @@ -7,7 +7,7 @@ -

    37 SWIG and Ruby

    +

    38 SWIG and Ruby

      @@ -144,7 +144,7 @@

      This chapter describes SWIG's support of Ruby.

      -

      37.1 Preliminaries

      +

      38.1 Preliminaries

      SWIG 1.3 is known to work with Ruby versions 1.6 and later. @@ -159,7 +159,7 @@ read the "SWIG Basics" chapter. It is also assumed that the reader has a basic understanding of Ruby.

      -

      37.1.1 Running SWIG

      +

      38.1.1 Running SWIG

      To build a Ruby module, run SWIG using the -ruby @@ -183,7 +183,7 @@ if compiling a C++ extension) that contains all of the code needed to build a Ruby extension module. To finish building the module, you need to compile this file and link it with the rest of your program.

      -

      37.1.2 Getting the right header files

      +

      38.1.2 Getting the right header files

      In order to compile the wrapper code, the compiler needs the ruby.h @@ -206,7 +206,7 @@ installed, you can run Ruby to find out. For example:

    -

    37.1.3 Compiling a dynamic module

    +

    38.1.3 Compiling a dynamic module

    Ruby extension modules are typically compiled into shared @@ -279,7 +279,7 @@ manual pages for your compiler and linker to determine the correct set of options. You might also check the SWIG Wiki for additional information.

    -

    37.1.4 Using your module

    +

    38.1.4 Using your module

    Ruby module names must be capitalized, @@ -309,7 +309,7 @@ begins with:

    will result in an extension module using the feature name "example" and Ruby module name "Example".

    -

    37.1.5 Static linking

    +

    38.1.5 Static linking

    An alternative approach to dynamic linking is to rebuild the @@ -324,7 +324,7 @@ finding the Ruby source, adding an entry to the ext/Setup file, adding your directory to the list of extensions in the file, and finally rebuilding Ruby.

    -

    37.1.6 Compilation of C++ extensions

    +

    38.1.6 Compilation of C++ extensions

    On most machines, C++ extension modules should be linked @@ -356,7 +356,7 @@ $libs = append_library($libs, "supc++") create_makefile('example')

    -

    37.2 Building Ruby Extensions under Windows 95/NT

    +

    38.2 Building Ruby Extensions under Windows 95/NT

    Building a SWIG extension to Ruby under Windows 95/NT is @@ -381,7 +381,7 @@ order to build extensions, you may need to download the source distribution to the Ruby package, as you will need the Ruby header files.

    -

    37.2.1 Running SWIG from Developer Studio

    +

    38.2.1 Running SWIG from Developer Studio

    If you are developing your application within Microsoft @@ -445,13 +445,13 @@ Foo = 3.0 -

    37.3 The Ruby-to-C/C++ Mapping

    +

    38.3 The Ruby-to-C/C++ Mapping

    This section describes the basics of how SWIG maps C or C++ declarations in your SWIG interface files to Ruby constructs.

    -

    37.3.1 Modules

    +

    38.3.1 Modules

    The SWIG %module directive specifies @@ -523,7 +523,7 @@ option to wrap everything into the global module, take care that the names of your constants, classes and methods don't conflict with any of Ruby's built-in names.

    -

    37.3.2 Functions

    +

    38.3.2 Functions

    Global functions are wrapped as Ruby module methods. For @@ -557,7 +557,7 @@ irb(main):002:0> Example.fact(4) 24 -

    37.3.3 Variable Linking

    +

    38.3.3 Variable Linking

    C/C++ global variables are wrapped as a pair of singleton @@ -619,7 +619,7 @@ directive. For example:

    effect until it is explicitly disabled using %mutable.

    -

    37.3.4 Constants

    +

    38.3.4 Constants

    C/C++ constants are wrapped as module constants initialized @@ -647,7 +647,7 @@ irb(main):002:0> Example::PI 3.14159 -

    37.3.5 Pointers

    +

    38.3.5 Pointers

    "Opaque" pointers to arbitrary C/C++ types (i.e. types that @@ -671,7 +671,7 @@ returns an instance of an internally generated Ruby class:

    A NULL pointer is always represented by the Ruby nil object.

    -

    37.3.6 Structures

    +

    38.3.6 Structures

    C/C++ structs are wrapped as Ruby classes, with accessor @@ -776,7 +776,7 @@ void Bar_f_set(Bar *b, Foo *val) { } -

    37.3.7 C++ classes

    +

    38.3.7 C++ classes

    Like structs, C++ classes are wrapped by creating a new Ruby @@ -831,7 +831,7 @@ Ale 3 -

    37.3.8 C++ Inheritance

    +

    38.3.8 C++ Inheritance

    The SWIG type-checker is fully aware of C++ inheritance. @@ -984,7 +984,7 @@ inherit from both Base1 and Base2 (i.e. they exhibit "Duck Typing").

    -

    37.3.9 C++ Overloaded Functions

    +

    38.3.9 C++ Overloaded Functions

    C++ overloaded functions, methods, and constructors are @@ -1074,7 +1074,7 @@ arises--in this case, the first declaration takes precedence.

    Please refer to the "SWIG and C++" chapter for more information about overloading.

    -

    37.3.10 C++ Operators

    +

    38.3.10 C++ Operators

    For the most part, overloaded operators are handled @@ -1116,7 +1116,7 @@ c = Example.add_complex(a, b) is discussed in the section on operator overloading.

    -

    37.3.11 C++ namespaces

    +

    38.3.11 C++ namespaces

    SWIG is aware of C++ namespaces, but namespace names do not @@ -1173,7 +1173,7 @@ and create extension modules for each namespace separately. If your program utilizes thousands of small deeply nested namespaces each with identical symbol names, well, then you get what you deserve.

    -

    37.3.12 C++ templates

    +

    38.3.12 C++ templates

    C++ templates don't present a huge problem for SWIG. However, @@ -1215,7 +1215,7 @@ irb(main):004:0> p.second 4 -

    37.3.13 C++ Standard Template Library (STL)

    +

    38.3.13 C++ Standard Template Library (STL)

    On a related note, the standard SWIG library contains a @@ -1308,7 +1308,7 @@ puts v shown in these examples. More details can be found in the SWIG and C++ chapter.

    -

    37.3.14 C++ STL Functors

    +

    38.3.14 C++ STL Functors

    Some containers in the STL allow you to modify their default @@ -1369,7 +1369,7 @@ b -

    37.3.15 C++ STL Iterators

    +

    38.3.15 C++ STL Iterators

    The STL is well known for the use of iterators. There @@ -1452,7 +1452,7 @@ i

    If you'd rather have STL classes without any iterators, you should define -DSWIG_NO_EXPORT_ITERATOR_METHODS when running swig.

    -

    37.3.16 C++ Smart Pointers

    +

    38.3.16 C++ Smart Pointers

    In certain C++ programs, it is common to use classes that @@ -1517,7 +1517,7 @@ method. For example:

    irb(main):004:0> f = p.__deref__() # Returns underlying Foo *
    -

    37.3.17 Cross-Language Polymorphism

    +

    38.3.17 Cross-Language Polymorphism

    SWIG's Ruby module supports cross-language polymorphism @@ -1526,7 +1526,7 @@ module. Rather than duplicate the information presented in the 37.3.17.1 Exception Unrolling +

    38.3.17.1 Exception Unrolling

    Whenever a C++ director class routes one of its virtual @@ -1549,7 +1549,7 @@ method is "wrapped" using the rb_rescue2() function from Ruby's C API. If any Ruby exception is raised, it will be caught here and a C++ exception is raised in its place.

    -

    37.4 Naming

    +

    38.4 Naming

    Ruby has several common naming conventions. Constants are @@ -1587,7 +1587,7 @@ generated by SWIG, it is turned off by default in SWIG 1.3.28. However, it is planned to become the default option in future releases.

    -

    37.4.1 Defining Aliases

    +

    38.4.1 Defining Aliases

    It's a fairly common practice in the Ruby built-ins and @@ -1657,7 +1657,7 @@ matching rules used for other kinds of features apply (see the chapter on "Customization Features") for more details).

    -

    37.4.2 Predicate Methods

    +

    38.4.2 Predicate Methods

    Ruby methods that return a boolean value and end in a @@ -1706,7 +1706,7 @@ using SWIG's "features" mechanism and so the same name matching rules used for other kinds of features apply (see the chapter on "Customization Features") for more details).

    -

    37.4.3 Bang Methods

    +

    38.4.3 Bang Methods

    Ruby methods that modify an object in-place and end in an @@ -1738,7 +1738,7 @@ using SWIG's "features" mechanism and so the same name matching rules used for other kinds of features apply (see the chapter on "Customization Features") for more details).

    -

    37.4.4 Getters and Setters

    +

    38.4.4 Getters and Setters

    Often times a C++ library will expose properties through @@ -1773,7 +1773,7 @@ irb(main):003:0> puts foo.value %rename("value=") Foo::setValue(int value); -

    37.5 Input and output parameters

    +

    38.5 Input and output parameters

    A common problem in some C programs is handling parameters @@ -1912,10 +1912,10 @@ void get_dimensions(Matrix *m, int *rows, int*columns);

    r, c = Example.get_dimensions(m)
    -

    37.6 Exception handling

    +

    38.6 Exception handling

    -

    37.6.1 Using the %exception directive

    +

    38.6.1 Using the %exception directive

    The SWIG %exception directive can be @@ -2024,7 +2024,7 @@ methods and functions named getitem and setitem. limited to C++ exception handling. See the chapter on Customization Features for more examples.

    -

    37.6.2 Handling Ruby Blocks

    +

    38.6.2 Handling Ruby Blocks

    One of the highlights of Ruby and most of its standard library @@ -2091,7 +2091,7 @@ a special in typemap, like:

    For more information on typemaps, see Typemaps.

    -

    37.6.3 Raising exceptions

    +

    38.6.3 Raising exceptions

    There are three ways to raise exceptions from C++ code to @@ -2248,7 +2248,7 @@ function. The first argument passed to rb_raise() is the exception type. You can raise a custom exception type or one of the built-in Ruby exception types.

    -

    37.6.4 Exception classes

    +

    38.6.4 Exception classes

    Starting with SWIG 1.3.28, the Ruby module supports the %exceptionclass @@ -2285,7 +2285,7 @@ end

    For another example look at swig/Examples/ruby/exception_class.

    -

    37.7 Typemaps

    +

    38.7 Typemaps

    This section describes how you can modify SWIG's default @@ -2300,7 +2300,7 @@ a required part of using SWIG---the default wrapping behavior is enough in most cases. Typemaps are only used if you want to change some aspect of the primitive C-Ruby interface.

    -

    37.7.1 What is a typemap?

    +

    38.7.1 What is a typemap?

    A typemap is nothing more than a code generation rule that is @@ -2457,7 +2457,7 @@ to be used as follows (notice how the length parameter is omitted):

    2 -

    37.7.2 Typemap scope

    +

    38.7.2 Typemap scope

    Once defined, a typemap remains in effect for all of the @@ -2503,7 +2503,7 @@ where the class itself is defined. For example:

    }; -

    37.7.3 Copying a typemap

    +

    38.7.3 Copying a typemap

    A typemap is copied by using assignment. For example:

    @@ -2545,7 +2545,7 @@ rules as for %apply (char *buf, int len) { (char *buffer, int size) }; // Multiple arguments -

    37.7.4 Deleting a typemap

    +

    38.7.4 Deleting a typemap

    A typemap can be deleted by simply defining no code. For @@ -2570,7 +2570,7 @@ defined by typemaps, clearing a fundamental type like int will make that type unusable unless you also define a new set of typemaps immediately after the clear operation.

    -

    37.7.5 Placement of typemaps

    +

    38.7.5 Placement of typemaps

    Typemap declarations can be declared in the global scope, @@ -2641,13 +2641,13 @@ In this example, this is done using the class declaration class string .

    -

    37.7.6 Ruby typemaps

    +

    38.7.6 Ruby typemaps

    The following list details all of the typemap methods that can be used by the Ruby module:

    -

    37.7.6.1 "in" typemap

    +

    38.7.6.1 "in" typemap

    Converts Ruby objects to input @@ -2714,7 +2714,7 @@ arguments to be specified. For example:

    At this time, only zero or one arguments may be converted.

    -

    37.7.6.2 "typecheck" typemap

    +

    38.7.6.2 "typecheck" typemap

    The "typecheck" typemap is used to support overloaded @@ -2736,7 +2736,7 @@ program uses overloaded methods, you should also define a collection of "typecheck" typemaps. More details about this follow in a later section on "Typemaps and Overloading."

    -

    37.7.6.3 "out" typemap

    +

    38.7.6.3 "out" typemap

    Converts return value of a C function @@ -2787,7 +2787,7 @@ version of the C datatype matched by the typemap.

    -

    37.7.6.4 "arginit" typemap

    +

    38.7.6.4 "arginit" typemap

    The "arginit" typemap is used to set the initial value of a @@ -2802,7 +2802,7 @@ applications. For example:

    } -

    37.7.6.5 "default" typemap

    +

    38.7.6.5 "default" typemap

    The "default" typemap is used to turn an argument into a @@ -2827,7 +2827,7 @@ arguments that follow must have default values. See the 37.7.6.6 "check" typemap +

    38.7.6.6 "check" typemap

    The "check" typemap is used to supply value checking code @@ -2842,7 +2842,7 @@ arguments have been converted. For example:

    } -

    37.7.6.7 "argout" typemap

    +

    38.7.6.7 "argout" typemap

    The "argout" typemap is used to return values from arguments. @@ -2896,7 +2896,7 @@ some function like SWIG_Ruby_AppendOutput.

    See the typemaps.i library for examples.

    -

    37.7.6.8 "freearg" typemap

    +

    38.7.6.8 "freearg" typemap

    The "freearg" typemap is used to cleanup argument data. It is @@ -2923,7 +2923,7 @@ This code is also placed into a special variable $cleanup that may be used in other typemaps whenever a wrapper function needs to abort prematurely.

    -

    37.7.6.9 "newfree" typemap

    +

    38.7.6.9 "newfree" typemap

    The "newfree" typemap is used in conjunction with the %newobject @@ -2947,7 +2947,7 @@ string *foo();

    See Object ownership and %newobject for further details.

    -

    37.7.6.10 "memberin" typemap

    +

    38.7.6.10 "memberin" typemap

    The "memberin" typemap is used to copy data from an @@ -2965,21 +2965,21 @@ example:

    already provides a default implementation for arrays, strings, and other objects.

    -

    37.7.6.11 "varin" typemap

    +

    38.7.6.11 "varin" typemap

    The "varin" typemap is used to convert objects in the target language to C for the purposes of assigning to a C/C++ global variable. This is implementation specific.

    -

    37.7.6.12 "varout" typemap

    +

    38.7.6.12 "varout" typemap

    The "varout" typemap is used to convert a C/C++ object to an object in the target language when reading a C/C++ global variable. This is implementation specific.

    -

    37.7.6.13 "throws" typemap

    +

    38.7.6.13 "throws" typemap

    The "throws" typemap is only used when SWIG parses a C++ @@ -3020,7 +3020,7 @@ specification yet they do throw exceptions, SWIG cannot know how to deal with them. For a neat way to handle these, see the Exception handling with %exception section.

    -

    37.7.6.14 directorin typemap

    +

    38.7.6.14 directorin typemap

    Converts C++ objects in director @@ -3079,7 +3079,7 @@ referring to the class itself. -

    37.7.6.15 directorout typemap

    +

    38.7.6.15 directorout typemap

    Converts Ruby objects in director @@ -3152,7 +3152,7 @@ exception.

    -

    37.7.6.16 directorargout typemap

    +

    38.7.6.16 directorargout typemap

    Output argument processing in director @@ -3210,19 +3210,19 @@ referring to the instance of the class itself -

    37.7.6.17 ret typemap

    +

    38.7.6.17 ret typemap

    Cleanup of function return values

    -

    37.7.6.18 globalin typemap

    +

    38.7.6.18 globalin typemap

    Setting of C global variables

    -

    37.7.7 Typemap variables

    +

    38.7.7 Typemap variables

    @@ -3272,7 +3272,7 @@ so that their values can be properly assigned.

    The Ruby name of the wrapper function being created.
    -

    37.7.8 Useful Functions

    +

    38.7.8 Useful Functions

    When you write a typemap, you usually have to work directly @@ -3287,7 +3287,7 @@ stick to the swig functions instead of the native Ruby functions. That should help you avoid having to rewrite a lot of typemaps across multiple languages.

    -

    37.7.8.1 C Datatypes to Ruby Objects

    +

    38.7.8.1 C Datatypes to Ruby Objects

    @@ -3329,7 +3329,7 @@ SWIG_From_float(float)
    -

    37.7.8.2 Ruby Objects to C Datatypes

    +

    38.7.8.2 Ruby Objects to C Datatypes

    Here, while the Ruby versions return the value directly, the SWIG @@ -3397,7 +3397,7 @@ versions do not, but return a status value to indicate success (SWIG_OK -

    37.7.8.3 Macros for VALUE

    +

    38.7.8.3 Macros for VALUE

    RSTRING_LEN(str)

    @@ -3420,7 +3420,7 @@ versions do not, but return a status value to indicate success (SWIG_OK
    pointer to array storage
    -

    37.7.8.4 Exceptions

    +

    38.7.8.4 Exceptions

    void rb_raise(VALUE exception, const char *fmt, @@ -3499,7 +3499,7 @@ message to standard error if Ruby was invoked with the -w flag. The given format string fmt and remaining arguments are interpreted as with printf(). -

    37.7.8.5 Iterators

    +

    38.7.8.5 Iterators

    void rb_iter_break()

    @@ -3545,14 +3545,14 @@ VALUE), VALUE value)

    Equivalent to Ruby's throw.
    -

    37.7.9 Typemap Examples

    +

    38.7.9 Typemap Examples

    This section includes a few examples of typemaps. For more examples, you might look at the examples in the Example/ruby directory.

    -

    37.7.10 Converting a Ruby array to a char **

    +

    38.7.10 Converting a Ruby array to a char **

    A common problem in many C programs is the processing of @@ -3617,7 +3617,7 @@ array. Since dynamic memory allocation is used to allocate memory for the array, the "freearg" typemap is used to later release this memory after the execution of the C function.

    -

    37.7.11 Collecting arguments in a hash

    +

    38.7.11 Collecting arguments in a hash

    Ruby's solution to the "keyword arguments" capability of some @@ -3831,7 +3831,7 @@ memory leak. Fortunately, this typemap is a lot easier to write:

    program that uses the extension, can be found in the Examples/ruby/hashargs directory of the SWIG distribution.

    -

    37.7.12 Pointer handling

    +

    38.7.12 Pointer handling

    Occasionally, it might be necessary to convert pointer values @@ -3890,7 +3890,7 @@ For example:

    } -

    37.7.12.1 Ruby Datatype Wrapping

    +

    38.7.12.1 Ruby Datatype Wrapping

    VALUE Data_Wrap_Struct(VALUE class, void @@ -3917,7 +3917,7 @@ as above. type c-type from the data object obj and assigns that pointer to ptr. -

    37.7.13 Example: STL Vector to Ruby Array

    +

    38.7.13 Example: STL Vector to Ruby Array

    Another use for macros and type maps is to create a Ruby array @@ -4009,7 +4009,7 @@ STL with ruby, you are advised to use the standard swig STL library, which does much more than this. Refer to the section called the C++ Standard Template Library. -

    37.8 Docstring Features

    +

    38.8 Docstring Features

    @@ -4043,7 +4043,7 @@ generate ri documentation from a c wrap file, you could do:

    $ rdoc -r file_wrap.c -

    37.8.1 Module docstring

    +

    38.8.1 Module docstring

    @@ -4073,7 +4073,7 @@ layout of controls on a panel, etc. to be loaded from an XML file." %module(docstring=DOCSTRING) xrc -

    37.8.2 %feature("autodoc")

    +

    38.8.2 %feature("autodoc")

    Since SWIG does know everything about the function it wraps, @@ -4094,7 +4094,7 @@ several options for autodoc controlled by the value given to the feature, described below.

    -

    37.8.2.1 %feature("autodoc", "0")

    +

    38.8.2.1 %feature("autodoc", "0")

    @@ -4118,7 +4118,7 @@ Then Ruby code like this will be generated: ... -

    37.8.2.2 %feature("autodoc", "1")

    +

    38.8.2.2 %feature("autodoc", "1")

    @@ -4138,7 +4138,7 @@ this: ... -

    37.8.2.3 %feature("autodoc", "2")

    +

    38.8.2.3 %feature("autodoc", "2")

    @@ -4150,7 +4150,7 @@ parameter types with the "2" option will result in Ruby code like this:

    -

    37.8.2.4 %feature("autodoc", "3")

    +

    38.8.2.4 %feature("autodoc", "3")

    @@ -4171,7 +4171,7 @@ Parameters: bar - Bar -

    37.8.2.5 %feature("autodoc", "docstring")

    +

    38.8.2.5 %feature("autodoc", "docstring")

    @@ -4187,7 +4187,7 @@ generated string. For example: void GetPosition(int* OUTPUT, int* OUTPUT); -

    37.8.3 %feature("docstring")

    +

    38.8.3 %feature("docstring")

    @@ -4198,10 +4198,10 @@ docstring associated with classes, function or methods are output. If an item already has an autodoc string then it is combined with the docstring and they are output together.

    -

    37.9 Advanced Topics

    +

    38.9 Advanced Topics

    -

    37.9.1 Operator overloading

    +

    38.9.1 Operator overloading

    SWIG allows operator overloading with, by using the %extend @@ -4382,7 +4382,7 @@ separate method for handling inequality since Ruby parses the expression a != b as !(a == b).

    -

    37.9.2 Creating Multi-Module Packages

    +

    38.9.2 Creating Multi-Module Packages

    The chapter on Working @@ -4508,7 +4508,7 @@ irb(main):005:0> c.getX() 5.0 -

    37.9.3 Specifying Mixin Modules

    +

    38.9.3 Specifying Mixin Modules

    The Ruby language doesn't support multiple inheritance, but @@ -4575,7 +4575,7 @@ matching rules used for other kinds of features apply (see the chapter on "Customization Features") for more details).

    -

    37.10 Memory Management

    +

    38.10 Memory Management

    One of the most common issues in generating SWIG bindings for @@ -4598,7 +4598,7 @@ to C++ (or vice versa) depending on what function or methods are invoked. Clearly, developing a SWIG wrapper requires a thorough understanding of how the underlying library manages memory.

    -

    37.10.1 Mark and Sweep Garbage Collector

    +

    38.10.1 Mark and Sweep Garbage Collector

    Ruby uses a mark and sweep garbage collector. When the garbage @@ -4630,7 +4630,7 @@ any memory has been allocated in creating the underlying C struct or C++ struct, then a "free" function must be defined that deallocates this memory.

    -

    37.10.2 Object Ownership

    +

    38.10.2 Object Ownership

    As described above, memory management depends on clearly @@ -4775,7 +4775,7 @@ public:

    This code can be seen in swig/examples/ruby/tracking.

    -

    37.10.3 Object Tracking

    +

    38.10.3 Object Tracking

    The remaining parts of this section will use the class library @@ -5000,7 +5000,7 @@ However, if you implement your own free functions (see below) you may also have to call the SWIG_RubyRemoveTracking and RubyUnlinkObjects methods.

    -

    37.10.4 Mark Functions

    +

    38.10.4 Mark Functions

    With a bit more testing, we see that our class library still @@ -5129,7 +5129,7 @@ irb(main):016:0>

    This code can be seen in swig/examples/ruby/mark_function.

    -

    37.10.5 Free Functions

    +

    38.10.5 Free Functions

    By default, SWIG creates a "free" function that is called when @@ -5296,7 +5296,7 @@ been freed, and thus raises a runtime exception.

    This code can be seen in swig/examples/ruby/free_function.

    -

    37.10.6 Embedded Ruby and the C++ Stack

    +

    38.10.6 Embedded Ruby and the C++ Stack

    As has been said, the Ruby GC runs and marks objects before diff --git a/Doc/Manual/Tcl.html b/Doc/Manual/Tcl.html index 45eebbf5e..c12701ac9 100644 --- a/Doc/Manual/Tcl.html +++ b/Doc/Manual/Tcl.html @@ -6,7 +6,7 @@ -

    38 SWIG and Tcl

    +

    39 SWIG and Tcl

      @@ -83,7 +83,7 @@ Tcl 8.0 or a later release. Earlier releases of SWIG supported Tcl 7.x, but this is no longer supported.

      -

      38.1 Preliminaries

      +

      39.1 Preliminaries

      @@ -109,7 +109,7 @@ build a Tcl extension module. To finish building the module, you need to compile this file and link it with the rest of your program.

      -

      38.1.1 Getting the right header files

      +

      39.1.1 Getting the right header files

      @@ -127,7 +127,7 @@ this is the case, you should probably make a symbolic link so that tcl.h -

      38.1.2 Compiling a dynamic module

      +

      39.1.2 Compiling a dynamic module

      @@ -163,7 +163,7 @@ The name of the module is specified using the %module directive or the -module command line option.

      -

      38.1.3 Static linking

      +

      39.1.3 Static linking

      @@ -229,7 +229,7 @@ minimal in most situations (and quite frankly not worth the extra hassle in the opinion of this author).

      -

      38.1.4 Using your module

      +

      39.1.4 Using your module

      @@ -357,7 +357,7 @@ to the default system configuration (this requires root access and you will need the man pages).

      -

      38.1.5 Compilation of C++ extensions

      +

      39.1.5 Compilation of C++ extensions

      @@ -440,7 +440,7 @@ erratic program behavior. If working with lots of software components, you might want to investigate using a more formal standard such as COM.

      -

      38.1.6 Compiling for 64-bit platforms

      +

      39.1.6 Compiling for 64-bit platforms

      @@ -467,7 +467,7 @@ also introduce problems on platforms that support more than one linking standard (e.g., -o32 and -n32 on Irix).

      -

      38.1.7 Setting a package prefix

      +

      39.1.7 Setting a package prefix

      @@ -486,7 +486,7 @@ option will append the prefix to the name when creating a command and call it "Foo_bar".

      -

      38.1.8 Using namespaces

      +

      39.1.8 Using namespaces

      @@ -508,7 +508,7 @@ When the -namespace option is used, objects in the module are always accessed with the namespace name such as Foo::bar.

      -

      38.2 Building Tcl/Tk Extensions under Windows 95/NT

      +

      39.2 Building Tcl/Tk Extensions under Windows 95/NT

      @@ -519,7 +519,7 @@ covers the process of using SWIG with Microsoft Visual C++. although the procedure may be similar with other compilers.

      -

      38.2.1 Running SWIG from Developer Studio

      +

      39.2.1 Running SWIG from Developer Studio

      @@ -577,7 +577,7 @@ MSDOS > tclsh80 %

    -

    38.2.2 Using NMAKE

    +

    39.2.2 Using NMAKE

    @@ -640,7 +640,7 @@ to get you started. With a little practice, you'll be making lots of Tcl extensions.

    -

    38.3 A tour of basic C/C++ wrapping

    +

    39.3 A tour of basic C/C++ wrapping

    @@ -651,7 +651,7 @@ classes. This section briefly covers the essential aspects of this wrapping.

    -

    38.3.1 Modules

    +

    39.3.1 Modules

    @@ -685,7 +685,7 @@ To fix this, supply an extra argument to load like this: -

    38.3.2 Functions

    +

    39.3.2 Functions

    @@ -710,7 +710,7 @@ like you think it does: % -

    38.3.3 Global variables

    +

    39.3.3 Global variables

    @@ -790,7 +790,7 @@ extern char *path; // Read-only (due to %immutable) -

    38.3.4 Constants and enums

    +

    39.3.4 Constants and enums

    @@ -874,7 +874,7 @@ When an identifier name is given, it is used to perform an implicit hash-table l conversion. This allows the global statement to be omitted.

    -

    38.3.5 Pointers

    +

    39.3.5 Pointers

    @@ -970,7 +970,7 @@ C-style cast may return a bogus result whereas as the C++-style cast will return None if the conversion can't be performed.

    -

    38.3.6 Structures

    +

    39.3.6 Structures

    @@ -1252,7 +1252,7 @@ Note: Tcl only destroys the underlying object if it has ownership. See the memory management section that appears shortly.

    -

    38.3.7 C++ classes

    +

    39.3.7 C++ classes

    @@ -1319,7 +1319,7 @@ In Tcl, the static member is accessed as follows: -

    38.3.8 C++ inheritance

    +

    39.3.8 C++ inheritance

    @@ -1368,7 +1368,7 @@ For instance: It is safe to use multiple inheritance with SWIG.

    -

    38.3.9 Pointers, references, values, and arrays

    +

    39.3.9 Pointers, references, values, and arrays

    @@ -1422,7 +1422,7 @@ to hold the result and a pointer is returned (Tcl will release this memory when the return value is garbage collected).

    -

    38.3.10 C++ overloaded functions

    +

    39.3.10 C++ overloaded functions

    @@ -1545,7 +1545,7 @@ first declaration takes precedence. Please refer to the "SWIG and C++" chapter for more information about overloading.

    -

    38.3.11 C++ operators

    +

    39.3.11 C++ operators

    @@ -1647,7 +1647,7 @@ There are ways to make this operator appear as part of the class using the % Keep reading.

    -

    38.3.12 C++ namespaces

    +

    39.3.12 C++ namespaces

    @@ -1711,7 +1711,7 @@ utilizes thousands of small deeply nested namespaces each with identical symbol names, well, then you get what you deserve.

    -

    38.3.13 C++ templates

    +

    39.3.13 C++ templates

    @@ -1763,7 +1763,7 @@ More details can be found in the SWIG and C++ -

    38.3.14 C++ Smart Pointers

    +

    39.3.14 C++ Smart Pointers

    @@ -1847,7 +1847,7 @@ simply use the __deref__() method. For example: -

    38.4 Further details on the Tcl class interface

    +

    39.4 Further details on the Tcl class interface

    @@ -1860,7 +1860,7 @@ of low-level details were omitted. This section provides a brief overview of how the proxy classes work.

    -

    38.4.1 Proxy classes

    +

    39.4.1 Proxy classes

    @@ -1925,7 +1925,7 @@ function. This allows objects to be encapsulated objects that look a lot like as shown in the last section.

    -

    38.4.2 Memory management

    +

    39.4.2 Memory management

    @@ -2113,7 +2113,7 @@ typemaps--an advanced topic discussed later.

    -

    38.5 Input and output parameters

    +

    39.5 Input and output parameters

    @@ -2301,7 +2301,7 @@ set c [lindex $dim 1] -

    38.6 Exception handling

    +

    39.6 Exception handling

    @@ -2435,7 +2435,7 @@ Since SWIG's exception handling is user-definable, you are not limited to C++ ex See the chapter on "Customization Features" for more examples.

    -

    38.7 Typemaps

    +

    39.7 Typemaps

    @@ -2452,7 +2452,7 @@ Typemaps are only used if you want to change some aspect of the primitive C-Tcl interface.

    -

    38.7.1 What is a typemap?

    +

    39.7.1 What is a typemap?

    @@ -2569,7 +2569,7 @@ parameter is omitted): -

    38.7.2 Tcl typemaps

    +

    39.7.2 Tcl typemaps

    @@ -2707,7 +2707,7 @@ Initialize an argument to a value before any conversions occur. Examples of these methods will appear shortly.

    -

    38.7.3 Typemap variables

    +

    39.7.3 Typemap variables

    @@ -2778,7 +2778,7 @@ properly assigned. The Tcl name of the wrapper function being created. -

    38.7.4 Converting a Tcl list to a char **

    +

    39.7.4 Converting a Tcl list to a char **

    @@ -2840,7 +2840,7 @@ argv[2] = Larry 3 -

    38.7.5 Returning values in arguments

    +

    39.7.5 Returning values in arguments

    @@ -2882,7 +2882,7 @@ result, a Tcl function using these typemaps will work like this : % -

    38.7.6 Useful functions

    +

    39.7.6 Useful functions

    @@ -2959,7 +2959,7 @@ int Tcl_IsShared(Tcl_Obj *obj); -

    38.7.7 Standard typemaps

    +

    39.7.7 Standard typemaps

    @@ -3043,7 +3043,7 @@ work) -

    38.7.8 Pointer handling

    +

    39.7.8 Pointer handling

    @@ -3119,7 +3119,7 @@ For example: -

    38.8 Turning a SWIG module into a Tcl Package.

    +

    39.8 Turning a SWIG module into a Tcl Package.

    @@ -3191,7 +3191,7 @@ As a final note, most SWIG examples do not yet use the to use the load command instead.

    -

    38.9 Building new kinds of Tcl interfaces (in Tcl)

    +

    39.9 Building new kinds of Tcl interfaces (in Tcl)

    @@ -3290,7 +3290,7 @@ danger of blowing something up (although it is easily accomplished with an out of bounds array access).

    -

    38.9.1 Proxy classes

    +

    39.9.1 Proxy classes

    @@ -3411,7 +3411,7 @@ short, but clever Tcl script can be combined with SWIG to do many interesting things.

    -

    38.10 Tcl/Tk Stubs

    +

    39.10 Tcl/Tk Stubs

    -- cgit v1.2.1 From a6d71e6c57dedcdf520f1d62026fe35a43fbb549 Mon Sep 17 00:00:00 2001 From: Karl Wette Date: Fri, 2 May 2014 00:04:23 +0200 Subject: configure.ac: fix to Javascript configuration - setting SKIP_JAVASCRIPT assumes that JSCENABLED/JSV8ENABLED are empty when jsc/v8 are not available --- configure.ac | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/configure.ac b/configure.ac index 6d70f1da8..46c7479d0 100644 --- a/configure.ac +++ b/configure.ac @@ -1203,7 +1203,7 @@ else if test -z "$JSCORELIB"; then AC_MSG_RESULT(not found) - JSCENABLED=0 + JSCENABLED= else JSCOREDYNAMICLINKING="$JSCORELIB" JSCENABLED=1 @@ -1270,7 +1270,7 @@ else if test "$JSV8LIB" = "" ; then AC_MSG_RESULT(not found) - JSV8ENABLED=0 + JSV8ENABLED= else AC_MSG_RESULT($JSV8LIBDIR) JSV8ENABLED=1 -- cgit v1.2.1 From 00a02a3d9c84c531087a072979681e00f93e3f2a Mon Sep 17 00:00:00 2001 From: xantares Date: Sat, 10 May 2014 12:09:52 +0200 Subject: Fix duplicate entry --- Examples/test-suite/common.mk | 1 - 1 file changed, 1 deletion(-) diff --git a/Examples/test-suite/common.mk b/Examples/test-suite/common.mk index 2a4591524..c8789cb99 100644 --- a/Examples/test-suite/common.mk +++ b/Examples/test-suite/common.mk @@ -409,7 +409,6 @@ CPP_TEST_CASES += \ template_partial_specialization \ template_partial_specialization_typedef \ template_qualifier \ - template_qualifier \ template_ref_type \ template_rename \ template_retvalue \ -- cgit v1.2.1 From 55bda53145d2898bd4642926b25209c12738e558 Mon Sep 17 00:00:00 2001 From: Vladimir Kalinin Date: Sat, 10 May 2014 22:16:26 +0400 Subject: C nested classes symbol table should be in global space --- Source/CParse/parser.y | 3 +++ 1 file changed, 3 insertions(+) diff --git a/Source/CParse/parser.y b/Source/CParse/parser.y index 7e7e5633f..26af7be2d 100644 --- a/Source/CParse/parser.y +++ b/Source/CParse/parser.y @@ -3515,6 +3515,9 @@ cpp_class_decl : storage_class cpptype idcolon inherit LBRACE { } else { cplus_mode = CPLUS_PUBLIC; } + if (!cparse_cplusplus) { + set_scope_to_global(); + } Swig_symbol_newscope(); Swig_symbol_setscopename($3); Swig_inherit_base_symbols(bases); -- cgit v1.2.1 From 4fe6622f64fe05eb14ff397c903970898b78c87a Mon Sep 17 00:00:00 2001 From: Karl Wette Date: Fri, 2 May 2014 00:41:43 +0200 Subject: configure.ac: print configured languages at end of configuration --- configure.ac | 36 ++++++++++++++++++++++++++++++++++++ 1 file changed, 36 insertions(+) diff --git a/configure.ac b/configure.ac index 46c7479d0..eeabd11b4 100644 --- a/configure.ac +++ b/configure.ac @@ -2678,4 +2678,40 @@ AC_CONFIG_FILES([preinst-swig], [chmod +x preinst-swig]) AC_CONFIG_FILES([CCache/ccache_swig_config.h]) AC_OUTPUT + +langs="" +test -n "$SKIP_ALLEGROCL" || langs="$langs allegrocl" +test -n "$SKIP_CFFI" || langs="$langs cffi" +test -n "$SKIP_CHICKEN" || langs="$langs chicken" +test -n "$SKIP_CLISP" || langs="$langs clisp" +test -n "$SKIP_CSHARP" || langs="$langs csharp" +test -n "$SKIP_D" || langs="$langs d" +test -n "$SKIP_GO" || langs="$langs go" +test -n "$SKIP_GUILE" || langs="$langs guile" +test -n "$SKIP_JAVA" || langs="$langs java" +test -n "$SKIP_JAVASCRIPT" || langs="$langs javascript" +test -n "$SKIP_LUA" || langs="$langs lua" +test -n "$SKIP_MODULA3" || langs="$langs modula3" +test -n "$SKIP_MZSCHEME" || langs="$langs mzscheme" +test -n "$SKIP_OCAML" || langs="$langs ocaml" +test -n "$SKIP_OCTAVE" || langs="$langs octave" +test -n "$SKIP_PERL5" || langs="$langs perl5" +test -n "$SKIP_PHP" || langs="$langs php" +test -n "$SKIP_PIKE" || langs="$langs pike" +test -n "$SKIP_PYTHON" || langs="$langs python" +test -n "$SKIP_R" || langs="$langs r" +test -n "$SKIP_RUBY" || langs="$langs ruby" +test -n "$SKIP_TCL" || langs="$langs tcl" +test -n "$SKIP_UFFI" || langs="$langs uffi" + +echo " +======================================================== + +SWIG is configured for use with the following languages: + +$langs + +======================================================== +" + dnl configure.ac ends here -- cgit v1.2.1 From 6fc07c5dc9a05669174b2c03881619bcb492ec5b Mon Sep 17 00:00:00 2001 From: Karl Wette Date: Fri, 2 May 2014 01:28:15 +0200 Subject: Fix segmentation fault in some Javascript examples - memory allocated with malloc() was then being freed with delete[], which is overridden by Javascript libraries (jsc), leading to segfault - replacing malloc with %new_array seems to work though --- Lib/javascript/jsc/javascriptstrings.swg | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Lib/javascript/jsc/javascriptstrings.swg b/Lib/javascript/jsc/javascriptstrings.swg index 0581c1920..10a0e252a 100644 --- a/Lib/javascript/jsc/javascriptstrings.swg +++ b/Lib/javascript/jsc/javascriptstrings.swg @@ -8,7 +8,7 @@ SWIG_JSC_AsCharPtrAndSize(JSContextRef context, JSValueRef valRef, char** cptr, if(JSValueIsString(context, valRef)) { JSStringRef js_str = JSValueToStringCopy(context, valRef, NULL); size_t len = JSStringGetMaximumUTF8CStringSize(js_str); - char* cstr = (char*) malloc(len * sizeof(char)); + char* cstr = (char*) %new_array(len, char); /* JSStringGetUTF8CString returns the length including 0-terminator */ len = JSStringGetUTF8CString(js_str, cstr, len); -- cgit v1.2.1 From 96153c7c0a9200f39d0dc66ffbea2426cd2a4d95 Mon Sep 17 00:00:00 2001 From: Karl Wette Date: Fri, 25 Apr 2014 17:01:14 +0200 Subject: Regenerate configured Makefile if Makefile.in or config.status have changed --- CCache/Makefile.in | 4 ++++ Examples/Makefile.in | 4 ++++ Examples/test-suite/common.mk | 7 +++++++ Examples/test-suite/errors/Makefile.in | 3 +++ Makefile.in | 5 +++++ Tools/javascript/Makefile.in | 16 ++++++++++++---- 6 files changed, 35 insertions(+), 4 deletions(-) diff --git a/CCache/Makefile.in b/CCache/Makefile.in index abe78c277..3513222ca 100644 --- a/CCache/Makefile.in +++ b/CCache/Makefile.in @@ -27,6 +27,10 @@ HEADERS = ccache.h mdfour.h all: $(PACKAGE_NAME)$(EXEEXT) +# Regenerate Makefile if Makefile.in or config.status have changed. +Makefile: $(srcdir)/Makefile.in ./config.status + $(SHELL) ./config.status + # Note that HTML documentation is actually generated and used from the main SWIG documentation Makefile docs: $(PACKAGE_NAME).1 web/ccache-man.html diff --git a/Examples/Makefile.in b/Examples/Makefile.in index 326f678c7..a0acd0fb8 100644 --- a/Examples/Makefile.in +++ b/Examples/Makefile.in @@ -21,6 +21,10 @@ # 'method' describes what is being built. #--------------------------------------------------------------- +# Regenerate Makefile if Makefile.in or config.status have changed. +Makefile: @srcdir@/Makefile.in ../config.status + cd .. && $(SHELL) ./config.status Examples/Makefile + TARGET = CC = @CC@ CXX = @CXX@ diff --git a/Examples/test-suite/common.mk b/Examples/test-suite/common.mk index c8789cb99..bdd1cd471 100644 --- a/Examples/test-suite/common.mk +++ b/Examples/test-suite/common.mk @@ -71,6 +71,13 @@ LIBPREFIX = lib ACTION = check INTERFACEDIR = $(top_srcdir)/$(EXAMPLES)/$(TEST_SUITE)/ +# Regenerate Makefile if Makefile.in or config.status have changed. +ifeq (,$(TEST_SUITE_SUBDIR)) +TEST_SUITE_SUBDIR = $(LANGUAGE) +endif +Makefile: $(srcdir)/Makefile.in ../../../config.status + cd ../../../ && $(SHELL) ./config.status $(EXAMPLES)/$(TEST_SUITE)/$(TEST_SUITE_SUBDIR)/Makefile + # # Please keep test cases in alphabetical order. # Note that any whitespace after the last entry in each list will break make diff --git a/Examples/test-suite/errors/Makefile.in b/Examples/test-suite/errors/Makefile.in index e4ba7b751..843283e7c 100644 --- a/Examples/test-suite/errors/Makefile.in +++ b/Examples/test-suite/errors/Makefile.in @@ -31,6 +31,9 @@ C_ERROR_TEST_CASES := $(filter-out $(CPP_ERROR_TEST_CASES), $(ALL_ERROR_TEST_CAS ERROR_TEST_CASES := $(CPP_ERROR_TEST_CASES:=.cpptest) \ $(C_ERROR_TEST_CASES:=.ctest) +# For rebuilding Makefile from Makefile.in in common.mk +TEST_SUITE_SUBDIR = errors + include $(srcdir)/../common.mk diff --git a/Makefile.in b/Makefile.in index 06e4724c7..53ac47de5 100644 --- a/Makefile.in +++ b/Makefile.in @@ -243,11 +243,13 @@ check-%-examples : # individual example %.actionexample: + @cd Examples && $(MAKE) Makefile @echo $(ACTION)ing Examples/$(LANGUAGE)/$* @(cd Examples/$(LANGUAGE)/$* && $(MAKE) $(FLAGS) $(chk-set-env) $(ACTION) RUNPIPE=$(RUNPIPE)) # gcj individual example java.actionexample: + @cd Examples && $(MAKE) Makefile @if $(skip-gcj); then \ echo "skipping Examples/$(LANGUAGE)/java $(ACTION) (gcj test)"; \ else \ @@ -283,6 +285,9 @@ check-test-suite: \ check-javascript-test-suite check-%-test-suite: + @if test -d Examples/test-suite/$*; then \ + cd Examples/test-suite/$* && $(MAKE) Makefile; \ + fi @if test -z "$(skip-$*)"; then \ echo $* unknown; \ exit 1; \ diff --git a/Tools/javascript/Makefile.in b/Tools/javascript/Makefile.in index 373c5d952..6fbca2384 100644 --- a/Tools/javascript/Makefile.in +++ b/Tools/javascript/Makefile.in @@ -11,6 +11,8 @@ # interpreter (see 'Tools/javascript'). # # ---------------------------------------------------------------- +all: javascript + CC = @CC@ # HACK: under OSX a g++ compiled interpreter is seg-faulting when loading module libraries # with 'c++' it works... probably some missing flags? @@ -29,15 +31,21 @@ JSCXXSHARED = @JSCXXSHARED@ JSV8ENABLED = @JSV8ENABLED@ JSCENABLED = @JSCENABLED@ +srcdir = @srcdir@ + +# Regenerate Makefile if Makefile.in or config.status have changed. +Makefile: $(srcdir)/Makefile.in ../../config.status + cd ../.. && $(SHELL) ./config.status Tools/javascript/Makefile + # These settings are provided by 'configure' (see '/configure.in') ifeq (1, $(JSV8ENABLED)) - JS_INTERPRETER_SRC_V8 = v8_shell.cxx - JS_INTERPRETER_ENABLE_V8 = -DENABLE_V8 +JS_INTERPRETER_SRC_V8 = v8_shell.cxx +JS_INTERPRETER_ENABLE_V8 = -DENABLE_V8 endif ifeq (1, $(JSCENABLED)) - JS_INTERPRETER_SRC_JSC = jsc_shell.cxx - JS_INTERPRETER_ENABLE_JSC = -DENABLE_JSC +JS_INTERPRETER_SRC_JSC = jsc_shell.cxx +JS_INTERPRETER_ENABLE_JSC = -DENABLE_JSC endif JS_INTERPRETER_DEFINES = $(JS_INTERPRETER_ENABLE_JSC) $(JS_INTERPRETER_ENABLE_V8) -- cgit v1.2.1 From e0b987b32faf68075890f7b6579661245247fd01 Mon Sep 17 00:00:00 2001 From: Karl Wette Date: Sat, 29 Mar 2014 16:31:32 +0100 Subject: CCache/Makefile.in: fix to allow out of source tree check/install --- CCache/Makefile.in | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/CCache/Makefile.in b/CCache/Makefile.in index 3513222ca..ae77ae745 100644 --- a/CCache/Makefile.in +++ b/CCache/Makefile.in @@ -14,7 +14,7 @@ NOSOFTLINKSTEST= CC=@CC@ CFLAGS=@CFLAGS@ -I. SWIG=swig -SWIG_LIB=../../Lib +SWIG_LIB=../$(srcdir)/../Lib EXEEXT=@EXEEXT@ # Use standard autoconf approach to transform executable name using --program-prefix and --program-suffix @@ -38,7 +38,7 @@ $(PACKAGE_NAME)$(EXEEXT): $(OBJS) $(HEADERS) $(CC) $(CFLAGS) $(LDFLAGS) -o $@ $(OBJS) $(LIBS) $(PACKAGE_NAME).1: ccache.yo - -yodl2man -o $(PACKAGE_NAME).1 ccache.yo + -yodl2man -o $(PACKAGE_NAME).1 $(srcdir)/ccache.yo web/ccache-man.html: ccache.yo yodl2html -o web/ccache-man.html ccache.yo @@ -50,7 +50,7 @@ install: $(PACKAGE_NAME)$(EXEEXT) $(PACKAGE_NAME).1 ${INSTALLCMD} -m 755 $(PACKAGE_NAME)$(EXEEXT) $(DESTDIR)${bindir}/`echo $(PACKAGE_NAME) | sed '$(transform)'`$(EXEEXT) @echo "Installing $(DESTDIR)${mandir}/man1/`echo $(PACKAGE_NAME) | sed '$(transform)'`.1" ${INSTALLCMD} -d $(DESTDIR)${mandir}/man1 - ${INSTALLCMD} -m 644 ${srcdir}/$(PACKAGE_NAME).1 $(DESTDIR)${mandir}/man1/`echo $(PACKAGE_NAME) | sed '$(transform)'`.1 + ${INSTALLCMD} -m 644 $(PACKAGE_NAME).1 $(DESTDIR)${mandir}/man1/`echo $(PACKAGE_NAME) | sed '$(transform)'`.1 uninstall: $(PACKAGE_NAME)$(EXEEXT) $(PACKAGE_NAME).1 rm -f $(DESTDIR)${bindir}/`echo $(PACKAGE_NAME) | sed '$(transform)'`$(EXEEXT) @@ -62,7 +62,7 @@ clean: check : test test: test.sh - SWIG_LIB='$(SWIG_LIB)' PATH=../..:$$PATH SWIG='$(SWIG)' CC='$(CC)' NOSOFTLINKSTEST='$(NOSOFTLINKSTEST)' ./test.sh + SWIG_LIB='$(SWIG_LIB)' PATH=../..:$$PATH SWIG='$(SWIG)' CC='$(CC)' NOSOFTLINKSTEST='$(NOSOFTLINKSTEST)' $(srcdir)/test.sh check: test -- cgit v1.2.1 From 72e6b5349e62c44b42de448fab6c9b005811d025 Mon Sep 17 00:00:00 2001 From: Karl Wette Date: Fri, 2 May 2014 17:43:06 +0200 Subject: Add "make maintainer-clean" to Travis CI build --- .travis.yml | 1 + 1 file changed, 1 insertion(+) diff --git a/.travis.yml b/.travis.yml index 890382c40..26cb18910 100644 --- a/.travis.yml +++ b/.travis.yml @@ -77,6 +77,7 @@ script: - if test -n "$SWIGLANG"; then make -s check-$SWIGLANG-version; fi - if test -n "$SWIGLANG"; then make -k $SWIGJOBS check-$SWIGLANG-examples; fi - if test -n "$SWIGLANG"; then make -k $SWIGJOBS check-$SWIGLANG-test-suite; fi + - make maintainer-clean branches: only: - master -- cgit v1.2.1 From f574a34155e4ede49b1b023494e0a1637ab89f8f Mon Sep 17 00:00:00 2001 From: Karl Wette Date: Sun, 11 May 2014 23:21:10 +0200 Subject: Allow examples and test-suite to be built out of source tree - Examples/Makefile.in rules use SRCDIR as the relative source directory - ./config.status replicates Examples/ source directory tree in build directory, and copies each Makefile to build directory, prefixed with a header which sets SRCDIR to source directory - Examples/test-suite/.../Makefile.in set SRCDIR from Autoconf-set srcdir - Examples/test-suite/errors/Makefile.in needs to filter out source directory from SWIG error messages - Lua: embedded interpreters are passed location of run-time test - Python: copy run-time scripts to build directory because of 2to3 conversion; import_packages example copies __init__.py from source directory; test-suite sets SCRIPTDIR to location of run-time tests - Javascript: binding.gyp renamed to binding.gyp.in so that $srcdir can be substituted with SRCDIR; removed './' from require() statements so that NODE_PATH can be used to point Node.js to build directory --- .gitignore | 3 + Examples/Makefile.in | 524 +++++++++++---------- Examples/android/class/Makefile | 6 +- Examples/android/extend/Makefile | 6 +- Examples/android/simple/Makefile | 6 +- Examples/chicken/class/Makefile | 10 +- Examples/chicken/constants/Makefile | 6 +- Examples/chicken/multimap/Makefile | 6 +- Examples/chicken/overload/Makefile | 6 +- Examples/chicken/simple/Makefile | 6 +- Examples/csharp/arrays/Makefile | 8 +- Examples/csharp/callback/Makefile | 8 +- Examples/csharp/class/Makefile | 8 +- Examples/csharp/enum/Makefile | 8 +- Examples/csharp/extend/Makefile | 8 +- Examples/csharp/funcptr/Makefile | 8 +- Examples/csharp/nested/Makefile | 8 +- Examples/csharp/reference/Makefile | 8 +- Examples/csharp/simple/Makefile | 8 +- Examples/csharp/template/Makefile | 8 +- Examples/csharp/variables/Makefile | 8 +- Examples/d/callback/Makefile | 8 +- Examples/d/class/Makefile | 8 +- Examples/d/constants/Makefile | 8 +- Examples/d/enum/Makefile | 8 +- Examples/d/extend/Makefile | 8 +- Examples/d/funcptr/Makefile | 8 +- Examples/d/simple/Makefile | 8 +- Examples/d/variables/Makefile | 8 +- Examples/go/callback/Makefile | 6 +- Examples/go/class/Makefile | 6 +- Examples/go/constants/Makefile | 6 +- Examples/go/enum/Makefile | 6 +- Examples/go/extend/Makefile | 6 +- Examples/go/funcptr/Makefile | 6 +- Examples/go/multimap/Makefile | 6 +- Examples/go/pointer/Makefile | 6 +- Examples/go/reference/Makefile | 6 +- Examples/go/simple/Makefile | 6 +- Examples/go/template/Makefile | 6 +- Examples/go/variables/Makefile | 6 +- Examples/guile/class/Makefile | 8 +- Examples/guile/constants/Makefile | 6 +- Examples/guile/matrix/Makefile | 6 +- Examples/guile/multimap/Makefile | 8 +- Examples/guile/multivalue/Makefile | 8 +- Examples/guile/port/Makefile | 6 +- Examples/guile/simple/Makefile | 6 +- Examples/guile/std_vector/Makefile | 8 +- Examples/java/callback/Makefile | 8 +- Examples/java/class/Makefile | 8 +- Examples/java/constants/Makefile | 8 +- Examples/java/enum/Makefile | 8 +- Examples/java/extend/Makefile | 8 +- Examples/java/funcptr/Makefile | 8 +- Examples/java/multimap/Makefile | 8 +- Examples/java/native/Makefile | 8 +- Examples/java/nested/Makefile | 8 +- Examples/java/pointer/Makefile | 8 +- Examples/java/reference/Makefile | 8 +- Examples/java/simple/Makefile | 8 +- Examples/java/template/Makefile | 8 +- Examples/java/typemap/Makefile | 8 +- Examples/java/variables/Makefile | 8 +- Examples/javascript/class/Makefile | 2 +- Examples/javascript/class/binding.gyp | 8 - Examples/javascript/class/binding.gyp.in | 9 + Examples/javascript/class/example.js | 2 +- Examples/javascript/class/runme.js | 2 +- Examples/javascript/constant/Makefile | 2 +- Examples/javascript/constant/binding.gyp | 8 - Examples/javascript/constant/binding.gyp.in | 9 + Examples/javascript/constant/example.js | 2 +- Examples/javascript/constant/runme.js | 2 +- Examples/javascript/enum/Makefile | 2 +- Examples/javascript/enum/binding.gyp | 8 - Examples/javascript/enum/binding.gyp.in | 9 + Examples/javascript/enum/example.js | 2 +- Examples/javascript/enum/runme.js | 2 +- Examples/javascript/example.mk | 8 +- Examples/javascript/exception/Makefile | 2 +- Examples/javascript/exception/binding.gyp | 29 -- Examples/javascript/exception/binding.gyp.in | 30 ++ Examples/javascript/exception/example.js | 2 +- Examples/javascript/exception/runme.js | 2 +- Examples/javascript/functor/Makefile | 2 +- Examples/javascript/functor/binding.gyp | 8 - Examples/javascript/functor/binding.gyp.in | 9 + Examples/javascript/functor/example.js | 2 +- Examples/javascript/functor/runme.js | 2 +- Examples/javascript/nspace/Makefile | 2 +- Examples/javascript/nspace/binding.gyp | 8 - Examples/javascript/nspace/binding.gyp.in | 9 + Examples/javascript/nspace/example.js | 2 +- Examples/javascript/nspace/runme.js | 2 +- Examples/javascript/operator/Makefile | 2 +- Examples/javascript/operator/binding.gyp | 8 - Examples/javascript/operator/binding.gyp.in | 9 + Examples/javascript/operator/example.js | 2 +- Examples/javascript/operator/runme.js | 2 +- Examples/javascript/overload/Makefile | 2 +- Examples/javascript/overload/binding.gyp | 8 - Examples/javascript/overload/binding.gyp.in | 9 + Examples/javascript/overload/example.js | 2 +- Examples/javascript/overload/runme.js | 2 +- Examples/javascript/pointer/Makefile | 2 +- Examples/javascript/pointer/binding.gyp | 8 - Examples/javascript/pointer/binding.gyp.in | 9 + Examples/javascript/pointer/example.js | 2 +- Examples/javascript/pointer/runme.js | 2 +- Examples/javascript/reference/Makefile | 2 +- Examples/javascript/reference/binding.gyp | 8 - Examples/javascript/reference/binding.gyp.in | 9 + Examples/javascript/reference/example.js | 2 +- Examples/javascript/reference/runme.js | 2 +- Examples/javascript/simple/Makefile | 2 +- Examples/javascript/simple/binding.gyp | 8 - Examples/javascript/simple/binding.gyp.in | 9 + Examples/javascript/simple/example.js | 2 +- Examples/javascript/simple/runme.js | 2 +- Examples/javascript/template/Makefile | 2 +- Examples/javascript/template/binding.gyp | 8 - Examples/javascript/template/binding.gyp.in | 9 + Examples/javascript/template/example.js | 2 +- Examples/javascript/template/runme.js | 2 +- Examples/javascript/variables/Makefile | 2 +- Examples/javascript/variables/binding.gyp | 8 - Examples/javascript/variables/binding.gyp.in | 9 + Examples/javascript/variables/example.js | 2 +- Examples/javascript/variables/runme.js | 2 +- Examples/lua/arrays/Makefile | 8 +- Examples/lua/class/Makefile | 8 +- Examples/lua/constants/Makefile | 8 +- Examples/lua/dual/Makefile | 10 +- Examples/lua/embed/Makefile | 6 +- Examples/lua/embed/embed.c | 9 +- Examples/lua/embed2/Makefile | 6 +- Examples/lua/embed2/embed2.c | 9 +- Examples/lua/embed3/Makefile | 6 +- Examples/lua/embed3/embed3.cpp | 10 +- Examples/lua/exception/Makefile | 8 +- Examples/lua/funcptr3/Makefile | 8 +- Examples/lua/functest/Makefile | 8 +- Examples/lua/functor/Makefile | 8 +- Examples/lua/import/Makefile | 12 +- Examples/lua/nspace/Makefile | 8 +- Examples/lua/owner/Makefile | 8 +- Examples/lua/pointer/Makefile | 8 +- Examples/lua/simple/Makefile | 8 +- Examples/lua/variables/Makefile | 8 +- Examples/modula3/class/Makefile | 6 +- Examples/modula3/enum/Makefile | 6 +- Examples/modula3/exception/Makefile | 8 +- Examples/modula3/reference/Makefile | 6 +- Examples/modula3/simple/Makefile | 6 +- Examples/modula3/typemap/Makefile | 6 +- Examples/mzscheme/multimap/Makefile | 6 +- Examples/mzscheme/simple/Makefile | 6 +- Examples/mzscheme/std_vector/Makefile | 4 +- Examples/ocaml/argout_ref/Makefile | 8 +- Examples/ocaml/contract/Makefile | 10 +- Examples/ocaml/scoped_enum/Makefile | 10 +- Examples/ocaml/shapes/Makefile | 10 +- Examples/ocaml/simple/Makefile | 10 +- Examples/ocaml/std_string/Makefile | 8 +- Examples/ocaml/std_vector/Makefile | 8 +- Examples/ocaml/stl/Makefile | 12 +- Examples/ocaml/string_from_ptr/Makefile | 10 +- Examples/ocaml/strings_test/Makefile | 10 +- Examples/octave/callback/Makefile | 6 +- Examples/octave/class/Makefile | 6 +- Examples/octave/constants/Makefile | 6 +- Examples/octave/contract/Makefile | 6 +- Examples/octave/enum/Makefile | 6 +- Examples/octave/extend/Makefile | 6 +- Examples/octave/funcptr/Makefile | 6 +- Examples/octave/funcptr2/Makefile | 6 +- Examples/octave/functor/Makefile | 6 +- Examples/octave/module_load/Makefile | 8 +- Examples/octave/operator/Makefile | 6 +- Examples/octave/pointer/Makefile | 6 +- Examples/octave/reference/Makefile | 6 +- Examples/octave/simple/Makefile | 6 +- Examples/octave/template/Makefile | 6 +- Examples/octave/variables/Makefile | 6 +- Examples/perl5/callback/Makefile | 8 +- Examples/perl5/class/Makefile | 8 +- Examples/perl5/constants/Makefile | 8 +- Examples/perl5/constants2/Makefile | 8 +- Examples/perl5/extend/Makefile | 8 +- Examples/perl5/funcptr/Makefile | 8 +- Examples/perl5/import/Makefile | 12 +- Examples/perl5/inline/Makefile | 4 +- Examples/perl5/java/Makefile | 10 +- Examples/perl5/multimap/Makefile | 8 +- Examples/perl5/multiple_inheritance/Makefile | 8 +- Examples/perl5/pointer/Makefile | 8 +- Examples/perl5/reference/Makefile | 8 +- Examples/perl5/simple/Makefile | 8 +- Examples/perl5/value/Makefile | 8 +- Examples/perl5/variables/Makefile | 8 +- Examples/perl5/xmlstring/Makefile | 8 +- Examples/php/callback/Makefile | 8 +- Examples/php/class/Makefile | 8 +- Examples/php/constants/Makefile | 8 +- Examples/php/cpointer/Makefile | 8 +- Examples/php/disown/Makefile | 8 +- Examples/php/enum/Makefile | 8 +- Examples/php/extend/Makefile | 8 +- Examples/php/funcptr/Makefile | 8 +- Examples/php/overloading/Makefile | 8 +- Examples/php/pointer/Makefile | 8 +- Examples/php/pragmas/Makefile | 8 +- Examples/php/proxy/Makefile | 8 +- Examples/php/reference/Makefile | 8 +- Examples/php/simple/Makefile | 8 +- Examples/php/sync/Makefile | 8 +- Examples/php/value/Makefile | 8 +- Examples/php/variables/Makefile | 8 +- Examples/pike/class/Makefile | 8 +- Examples/pike/constants/Makefile | 8 +- Examples/pike/enum/Makefile | 8 +- Examples/pike/overload/Makefile | 8 +- Examples/pike/simple/Makefile | 8 +- Examples/pike/template/Makefile | 8 +- Examples/python/callback/Makefile | 8 +- Examples/python/class/Makefile | 8 +- Examples/python/constants/Makefile | 8 +- Examples/python/contract/Makefile | 8 +- Examples/python/docstrings/Makefile | 8 +- Examples/python/enum/Makefile | 8 +- Examples/python/exception/Makefile | 8 +- Examples/python/exceptproxy/Makefile | 8 +- Examples/python/extend/Makefile | 8 +- Examples/python/funcptr/Makefile | 8 +- Examples/python/funcptr2/Makefile | 8 +- Examples/python/functor/Makefile | 8 +- Examples/python/import/Makefile | 12 +- Examples/python/import_packages/Makefile | 11 +- .../python/import_packages/from_init1/Makefile | 4 +- .../python/import_packages/from_init1/py2/Makefile | 2 +- .../import_packages/from_init1/py2/pkg2/Makefile | 12 +- .../python/import_packages/from_init1/py3/Makefile | 2 +- .../import_packages/from_init1/py3/pkg2/Makefile | 12 +- .../python/import_packages/from_init2/Makefile | 4 +- .../python/import_packages/from_init2/py2/Makefile | 2 +- .../import_packages/from_init2/py2/pkg2/Makefile | 6 +- .../from_init2/py2/pkg2/pkg3/Makefile | 6 +- .../python/import_packages/from_init2/py3/Makefile | 2 +- .../import_packages/from_init2/py3/pkg2/Makefile | 6 +- .../from_init2/py3/pkg2/pkg3/Makefile | 6 +- .../python/import_packages/from_init3/Makefile | 4 +- .../python/import_packages/from_init3/py2/Makefile | 2 +- .../import_packages/from_init3/py2/pkg2/Makefile | 6 +- .../from_init3/py2/pkg2/pkg3/Makefile | 2 +- .../from_init3/py2/pkg2/pkg3/pkg4/Makefile | 6 +- .../python/import_packages/from_init3/py3/Makefile | 2 +- .../import_packages/from_init3/py3/pkg2/Makefile | 6 +- .../from_init3/py3/pkg2/pkg3/Makefile | 2 +- .../from_init3/py3/pkg2/pkg3/pkg4/Makefile | 6 +- .../import_packages/relativeimport1/Makefile | 4 +- .../import_packages/relativeimport1/py2/Makefile | 2 +- .../relativeimport1/py2/pkg2/Makefile | 6 +- .../relativeimport1/py2/pkg2/pkg3/Makefile | 6 +- .../import_packages/relativeimport1/py3/Makefile | 2 +- .../relativeimport1/py3/pkg2/Makefile | 6 +- .../relativeimport1/py3/pkg2/pkg3/Makefile | 6 +- .../import_packages/relativeimport2/Makefile | 4 +- .../import_packages/relativeimport2/py2/Makefile | 2 +- .../relativeimport2/py2/pkg2/Makefile | 6 +- .../relativeimport2/py2/pkg2/pkg3/Makefile | 2 +- .../relativeimport2/py2/pkg2/pkg3/pkg4/Makefile | 6 +- .../import_packages/relativeimport2/py3/Makefile | 2 +- .../relativeimport2/py3/pkg2/Makefile | 6 +- .../relativeimport2/py3/pkg2/pkg3/Makefile | 2 +- .../relativeimport2/py3/pkg2/pkg3/pkg4/Makefile | 6 +- .../python/import_packages/same_modnames1/Makefile | 4 +- .../import_packages/same_modnames1/pkg1/Makefile | 6 +- .../import_packages/same_modnames1/pkg2/Makefile | 6 +- .../python/import_packages/same_modnames2/Makefile | 4 +- .../import_packages/same_modnames2/pkg1/Makefile | 6 +- .../same_modnames2/pkg1/pkg2/Makefile | 6 +- Examples/python/import_template/Makefile | 12 +- Examples/python/java/Makefile | 10 +- Examples/python/libffi/Makefile | 8 +- Examples/python/multimap/Makefile | 8 +- Examples/python/operator/Makefile | 8 +- Examples/python/performance/constructor/Makefile | 10 +- Examples/python/performance/func/Makefile | 10 +- Examples/python/performance/hierarchy/Makefile | 10 +- .../python/performance/hierarchy_operator/Makefile | 10 +- Examples/python/performance/operator/Makefile | 10 +- Examples/python/pointer/Makefile | 8 +- Examples/python/reference/Makefile | 8 +- Examples/python/simple/Makefile | 8 +- Examples/python/smartptr/Makefile | 8 +- Examples/python/std_map/Makefile | 8 +- Examples/python/std_vector/Makefile | 8 +- Examples/python/swigrun/Makefile | 8 +- Examples/python/template/Makefile | 8 +- Examples/python/varargs/Makefile | 8 +- Examples/python/variables/Makefile | 8 +- Examples/r/class/Makefile | 6 +- Examples/r/simple/Makefile | 6 +- Examples/ruby/class/Makefile | 8 +- Examples/ruby/constants/Makefile | 8 +- Examples/ruby/enum/Makefile | 8 +- Examples/ruby/exception_class/Makefile | 8 +- Examples/ruby/free_function/Makefile | 8 +- Examples/ruby/funcptr/Makefile | 8 +- Examples/ruby/funcptr2/Makefile | 8 +- Examples/ruby/functor/Makefile | 8 +- Examples/ruby/hashargs/Makefile | 8 +- Examples/ruby/import/Makefile | 12 +- Examples/ruby/import_template/Makefile | 12 +- Examples/ruby/java/Makefile | 10 +- Examples/ruby/mark_function/Makefile | 8 +- Examples/ruby/multimap/Makefile | 8 +- Examples/ruby/operator/Makefile | 8 +- Examples/ruby/overloading/Makefile | 8 +- Examples/ruby/pointer/Makefile | 8 +- Examples/ruby/reference/Makefile | 8 +- Examples/ruby/simple/Makefile | 8 +- Examples/ruby/std_vector/Makefile | 8 +- Examples/ruby/template/Makefile | 8 +- Examples/ruby/value/Makefile | 8 +- Examples/ruby/variables/Makefile | 8 +- Examples/tcl/class/Makefile | 8 +- Examples/tcl/constants/Makefile | 8 +- Examples/tcl/contract/Makefile | 8 +- Examples/tcl/enum/Makefile | 8 +- Examples/tcl/funcptr/Makefile | 8 +- Examples/tcl/import/Makefile | 12 +- Examples/tcl/java/Makefile | 10 +- Examples/tcl/multimap/Makefile | 8 +- Examples/tcl/operator/Makefile | 8 +- Examples/tcl/pointer/Makefile | 8 +- Examples/tcl/reference/Makefile | 8 +- Examples/tcl/simple/Makefile | 8 +- Examples/tcl/std_vector/Makefile | 8 +- Examples/tcl/value/Makefile | 8 +- Examples/tcl/variables/Makefile | 8 +- Examples/test-suite/allegrocl/Makefile.in | 6 + Examples/test-suite/cffi/Makefile.in | 6 + Examples/test-suite/chicken/Makefile.in | 7 + Examples/test-suite/clisp/Makefile.in | 6 + Examples/test-suite/common.mk | 14 +- Examples/test-suite/csharp/Makefile.in | 13 +- Examples/test-suite/d/Makefile.in | 10 +- Examples/test-suite/errors/Makefile.in | 19 +- Examples/test-suite/go/Makefile.in | 20 +- Examples/test-suite/guile/Makefile.in | 12 +- Examples/test-suite/java/Makefile.in | 13 +- Examples/test-suite/javascript/Makefile.in | 27 +- .../test-suite/javascript/abstract_access_runme.js | 2 +- .../javascript/abstract_inherit_runme.js | 2 +- .../javascript/abstract_typedef2_runme.js | 2 +- .../javascript/abstract_typedef_runme.js | 2 +- .../javascript/abstract_virtual_runme.js | 2 +- .../test-suite/javascript/array_member_runme.js | 2 +- .../test-suite/javascript/arrays_global_runme.js | 2 +- Examples/test-suite/javascript/callback_runme.js | 2 +- .../test-suite/javascript/char_binary_runme.js | 2 +- .../test-suite/javascript/char_strings_runme.js | 2 +- .../test-suite/javascript/class_ignore_runme.js | 2 +- .../javascript/class_scope_weird_runme.js | 2 +- .../test-suite/javascript/complextest_runme.js | 2 +- Examples/test-suite/javascript/constover_runme.js | 2 +- .../javascript/constructor_copy_runme.js | 2 +- Examples/test-suite/javascript/cpp_enum_runme.js | 2 +- .../test-suite/javascript/cpp_namespace_runme.js | 2 +- Examples/test-suite/javascript/cpp_static_runme.js | 2 +- .../javascript/director_alternating_runme.js | 2 +- Examples/test-suite/javascript/disown_runme.js | 2 +- .../test-suite/javascript/dynamic_cast_runme.js | 2 +- Examples/test-suite/javascript/empty_runme.js | 2 +- .../test-suite/javascript/enum_template_runme.js | 2 +- Examples/test-suite/javascript/infinity_runme.js | 2 +- .../javascript/namespace_virtual_method_runme.js | 2 +- .../javascript/node_template/binding.gyp.in | 2 +- .../test-suite/javascript/nspace_extend_runme.js | 2 +- Examples/test-suite/javascript/nspace_runme.js | 2 +- .../test-suite/javascript/overload_copy_runme.js | 2 +- .../test-suite/javascript/preproc_include_runme.js | 2 +- Examples/test-suite/javascript/preproc_runme.js | 2 +- Examples/test-suite/javascript/rename1_runme.js | 2 +- Examples/test-suite/javascript/rename2_runme.js | 2 +- Examples/test-suite/javascript/rename3_runme.js | 2 +- Examples/test-suite/javascript/rename4_runme.js | 2 +- .../test-suite/javascript/rename_scope_runme.js | 2 +- .../test-suite/javascript/rename_simple_runme.js | 2 +- .../test-suite/javascript/ret_by_value_runme.js | 2 +- Examples/test-suite/javascript/setup_test.sh | 6 - .../test-suite/javascript/string_simple_runme.js | 2 +- .../test-suite/javascript/struct_value_runme.js | 2 +- .../test-suite/javascript/template_static_runme.js | 2 +- .../test-suite/javascript/typedef_class_runme.js | 2 +- .../test-suite/javascript/typedef_inherit_runme.js | 2 +- .../test-suite/javascript/typedef_scope_runme.js | 2 +- .../test-suite/javascript/typemap_arrays_runme.js | 2 +- .../test-suite/javascript/typemap_delete_runme.js | 2 +- .../javascript/typemap_namespace_runme.js | 2 +- .../javascript/typemap_ns_using_runme.js | 2 +- Examples/test-suite/javascript/using1_runme.js | 2 +- Examples/test-suite/javascript/using2_runme.js | 2 +- Examples/test-suite/javascript/varargs_runme.js | 2 +- Examples/test-suite/lua/Makefile.in | 11 +- Examples/test-suite/mzscheme/Makefile.in | 6 + Examples/test-suite/ocaml/Makefile.in | 6 + Examples/test-suite/octave/Makefile.in | 13 +- Examples/test-suite/perl5/Makefile.in | 13 +- Examples/test-suite/php/Makefile.in | 15 +- Examples/test-suite/pike/Makefile.in | 6 + Examples/test-suite/python/Makefile.in | 43 +- Examples/test-suite/r/Makefile.in | 6 + Examples/test-suite/ruby/Makefile.in | 11 +- Examples/test-suite/tcl/Makefile.in | 11 +- Examples/test-suite/uffi/Makefile.in | 6 + Makefile.in | 4 +- Tools/javascript/Makefile.in | 2 +- configure.ac | 35 ++ 421 files changed, 1800 insertions(+), 1538 deletions(-) delete mode 100644 Examples/javascript/class/binding.gyp create mode 100644 Examples/javascript/class/binding.gyp.in delete mode 100644 Examples/javascript/constant/binding.gyp create mode 100644 Examples/javascript/constant/binding.gyp.in delete mode 100644 Examples/javascript/enum/binding.gyp create mode 100644 Examples/javascript/enum/binding.gyp.in delete mode 100644 Examples/javascript/exception/binding.gyp create mode 100644 Examples/javascript/exception/binding.gyp.in delete mode 100644 Examples/javascript/functor/binding.gyp create mode 100644 Examples/javascript/functor/binding.gyp.in delete mode 100644 Examples/javascript/nspace/binding.gyp create mode 100644 Examples/javascript/nspace/binding.gyp.in delete mode 100644 Examples/javascript/operator/binding.gyp create mode 100644 Examples/javascript/operator/binding.gyp.in delete mode 100644 Examples/javascript/overload/binding.gyp create mode 100644 Examples/javascript/overload/binding.gyp.in delete mode 100644 Examples/javascript/pointer/binding.gyp create mode 100644 Examples/javascript/pointer/binding.gyp.in delete mode 100644 Examples/javascript/reference/binding.gyp create mode 100644 Examples/javascript/reference/binding.gyp.in delete mode 100644 Examples/javascript/simple/binding.gyp create mode 100644 Examples/javascript/simple/binding.gyp.in delete mode 100644 Examples/javascript/template/binding.gyp create mode 100644 Examples/javascript/template/binding.gyp.in delete mode 100644 Examples/javascript/variables/binding.gyp create mode 100644 Examples/javascript/variables/binding.gyp.in delete mode 100644 Examples/test-suite/javascript/setup_test.sh diff --git a/.gitignore b/.gitignore index d4d70b010..ce6a3c4b7 100644 --- a/.gitignore +++ b/.gitignore @@ -136,3 +136,6 @@ Examples/test-suite/uffi/*/ # Scratch directories Examples/scratch + +# Out of source tree build directories +_build*/ diff --git a/Examples/Makefile.in b/Examples/Makefile.in index a0acd0fb8..dcfbd83b9 100644 --- a/Examples/Makefile.in +++ b/Examples/Makefile.in @@ -25,11 +25,28 @@ Makefile: @srcdir@/Makefile.in ../config.status cd .. && $(SHELL) ./config.status Examples/Makefile +# SRCDIR is the relative path to the current source directory +# - For in-source-tree builds, SRCDIR with be either '', +# or '../' for some of the test suites (e.g. C#, Java) +# - For out-of-source-tree builds, SRCDIR will be a relative +# path ending with a '/' + +# SRCDIR_SRCS, etc. are $(SRCS), etc. with $(SRCDIR) prepended +SRCDIR_SRCS = $(addprefix $(SRCDIR),$(SRCS)) +SRCDIR_CSRCS = $(addprefix $(SRCDIR),$(CSRCS)) +SRCDIR_CXXSRCS = $(addprefix $(SRCDIR),$(CXXSRCS)) + +ifeq (,$(SRCDIR)) +SRCDIR_INCLUDE = -I. +else +SRCDIR_INCLUDE = -I. -I$(SRCDIR) +endif + TARGET = CC = @CC@ CXX = @CXX@ -CFLAGS = @PLATCFLAGS@ -CXXFLAGS = @BOOST_CPPFLAGS@ @PLATCXXFLAGS@ +CFLAGS = $(SRCDIR_INCLUDE) @PLATCFLAGS@ +CXXFLAGS = $(SRCDIR_INCLUDE) @BOOST_CPPFLAGS@ @PLATCXXFLAGS@ prefix = @prefix@ exec_prefix= @exec_prefix@ SRCS = @@ -37,7 +54,7 @@ INCLUDES = LIBS = INTERFACE = INTERFACEDIR = -INTERFACEPATH = $(INTERFACEDIR)$(INTERFACE) +INTERFACEPATH = $(SRCDIR)$(INTERFACEDIR)$(INTERFACE) SWIGOPT = SWIG = swig @@ -130,38 +147,38 @@ TCL_DLNK = @TCLDYNAMICLINKING@ TCL_SO = @TCL_SO@ TCLLDSHARED = @TCLLDSHARED@ TCLCXXSHARED = @TCLCXXSHARED@ -TCL_SCRIPT = $(RUNME).tcl +TCL_SCRIPT = $(SRCDIR)$(RUNME).tcl # ----------------------------------------------------------- # Build a new version of the tclsh shell # ----------------------------------------------------------- -tclsh: $(SRCS) - $(SWIG) -tcl8 $(SWIGOPT) $(TCL_SWIGOPTS) -ltclsh.i $(INTERFACEPATH) - $(CC) $(CFLAGS) $(SRCS) $(ISRCS) $(INCLUDES) $(TCL_INCLUDE) \ +tclsh: $(SRCDIR_SRCS) + $(SWIG) -tcl8 $(SWIGOPT) $(TCL_SWIGOPTS) -ltclsh.i -o $(ISRCS) $(INTERFACEPATH) + $(CC) $(CFLAGS) $(SRCDIR_SRCS) $(ISRCS) $(INCLUDES) $(TCL_INCLUDE) \ $(TCL_LIB) $(TCL_OPTS) $(LIBS) $(SYSLIBS) -o $(TARGET) -tclsh_cpp: $(SRCS) - $(SWIG) -tcl8 -c++ $(SWIGOPT) $(TCL_SWIGOPTS) -ltclsh.i $(INTERFACEPATH) - $(CXX) $(CXXFLAGS) $(SRCS) $(CXXSRCS) $(ICXXSRCS) $(INCLUDES) $(TCL_INCLUDE) \ +tclsh_cpp: $(SRCDIR_SRCS) + $(SWIG) -tcl8 -c++ $(SWIGOPT) $(TCL_SWIGOPTS) -ltclsh.i -o $(ICXXSRCS) $(INTERFACEPATH) + $(CXX) $(CXXFLAGS) $(SRCDIR_SRCS) $(SRCDIR_CXXSRCS) $(ICXXSRCS) $(INCLUDES) $(TCL_INCLUDE) \ $(TCL_LIB) $(TCL_OPTS) $(LIBS) $(SYSLIBS) -o $(TARGET) # ----------------------------------------------------------- # Build a Tcl dynamic loadable module (you might need to tweak this) # ----------------------------------------------------------- -tcl: $(SRCS) - $(SWIG) -tcl8 $(SWIGOPT) $(TCL_SWIGOPTS) $(INTERFACEPATH) - $(CC) -c $(CCSHARED) $(CFLAGS) $(SRCS) $(ISRCS) $(INCLUDES) $(TCL_INCLUDE) +tcl: $(SRCDIR_SRCS) + $(SWIG) -tcl8 $(SWIGOPT) $(TCL_SWIGOPTS) -o $(ISRCS) $(INTERFACEPATH) + $(CC) -c $(CCSHARED) $(CFLAGS) $(SRCDIR_SRCS) $(ISRCS) $(INCLUDES) $(TCL_INCLUDE) $(TCLLDSHARED) $(CFLAGS) $(OBJS) $(IOBJS) $(TCL_DLNK) $(LIBS) -o $(LIBPREFIX)$(TARGET)$(TCL_SO) # ----------------------------------------------------------- # Build a Tcl7.5 dynamic loadable module for C++ # ----------------------------------------------------------- -tcl_cpp: $(SRCS) - $(SWIG) -tcl8 -c++ $(SWIGOPT) $(TCL_SWIGOPTS) $(INTERFACEPATH) - $(CXX) -c $(CCSHARED) $(CXXFLAGS) $(SRCS) $(CXXSRCS) $(ICXXSRCS) $(INCLUDES) $(TCL_INCLUDE) +tcl_cpp: $(SRCDIR_SRCS) + $(SWIG) -tcl8 -c++ $(SWIGOPT) $(TCL_SWIGOPTS) -o $(ICXXSRCS) $(INTERFACEPATH) + $(CXX) -c $(CCSHARED) $(CXXFLAGS) $(SRCDIR_SRCS) $(SRCDIR_CXXSRCS) $(ICXXSRCS) $(INCLUDES) $(TCL_INCLUDE) $(TCLCXXSHARED) $(CXXFLAGS) $(OBJS) $(IOBJS) $(TCL_DLNK) $(LIBS) $(CPP_DLLIBS) -o $(LIBPREFIX)$(TARGET)$(TCL_SO) # ----------------------------------------------------------------- @@ -205,44 +222,44 @@ PERL5_CCCDLFLAGS = @PERL5CCCDLFLAGS@ PERL5_LDFLAGS = @PERL5LDFLAGS@ PERL = @PERL@ PERL5_LIB = -L$(PERL5_INCLUDE) -l@PERL5LIB@ @LIBS@ $(SYSLIBS) -PERL5_SCRIPT = $(RUNME).pl +PERL5_SCRIPT = $(SRCDIR)$(RUNME).pl # ---------------------------------------------------------------- # Build a Perl5 dynamically loadable module (C) # ---------------------------------------------------------------- -perl5: $(SRCS) - $(SWIG) -perl5 $(SWIGOPT) $(INTERFACEPATH) - $(CC) -c -Dbool=char $(CCSHARED) $(CFLAGS) $(SRCS) $(ISRCS) $(INCLUDES) $(PERL5_CCFLAGS) $(PERL5_CCCDLFLAGS) -I$(PERL5_INCLUDE) +perl5: $(SRCDIR_SRCS) + $(SWIG) -perl5 $(SWIGOPT) -o $(ISRCS) $(INTERFACEPATH) + $(CC) -c -Dbool=char $(CCSHARED) $(CFLAGS) $(SRCDIR_SRCS) $(ISRCS) $(INCLUDES) $(PERL5_CCFLAGS) $(PERL5_CCCDLFLAGS) -I$(PERL5_INCLUDE) $(LDSHARED) $(CFLAGS) $(PERL5_CCDLFLAGS) $(OBJS) $(IOBJS) $(PERL5_LDFLAGS) $(PERL5_DLNK) $(LIBS) -o $(LIBPREFIX)$(TARGET)$(SO) # ---------------------------------------------------------------- # Build a Perl5 dynamically loadable module (C++) # ---------------------------------------------------------------- -perl5_cpp: $(SRCS) - $(SWIG) -perl5 -c++ $(SWIGOPT) $(INTERFACEPATH) - $(CXX) -c $(CCSHARED) $(CXXFLAGS) $(SRCS) $(CXXSRCS) $(ICXXSRCS) $(INCLUDES) $(PERL5_CCFLAGS) $(PERL5_CCCDLFLAGS) -I$(PERL5_INCLUDE) +perl5_cpp: $(SRCDIR_SRCS) + $(SWIG) -perl5 -c++ $(SWIGOPT) -o $(ICXXSRCS) $(INTERFACEPATH) + $(CXX) -c $(CCSHARED) $(CXXFLAGS) $(SRCDIR_SRCS) $(SRCDIR_CXXSRCS) $(ICXXSRCS) $(INCLUDES) $(PERL5_CCFLAGS) $(PERL5_CCCDLFLAGS) -I$(PERL5_INCLUDE) $(CXXSHARED) $(CXXFLAGS) $(PERL5_CCDLFLAGS) $(OBJS) $(IOBJS) $(PERL5_LDFLAGS) $(PERL5_DLNK) $(LIBS) $(CPP_DLLIBS) -o $(LIBPREFIX)$(TARGET)$(SO) # ---------------------------------------------------------------- # Build a module from existing XS C source code. (ie. from xsubpp). # ---------------------------------------------------------------- -perl5_xs: $(SRCS) - $(CC) -c $(CCSHARED) $(CFLAGS) $(SRCS) $(INCLUDES) -I$(PERL5_INCLUDE) +perl5_xs: $(SRCDIR_SRCS) + $(CC) -c $(CCSHARED) $(CFLAGS) $(SRCDIR_SRCS) $(INCLUDES) -I$(PERL5_INCLUDE) $(LDSHARED) $(CFLAGS) $(OBJS) $(LIBS) -o $(TARGET)$(SO) # ---------------------------------------------------------------- # Build a statically linked Perl5 executable # ---------------------------------------------------------------- -perl5_static: $(SRCS) - $(SWIG) -perl5 -static -lperlmain.i $(SWIGOPT) $(INTERFACEPATH) - $(CC) $(CFLAGS) -Dbool=char $(SRCS) $(ISRCS) $(INCLUDES) -I$(PERL5_INCLUDE) $(PERL5_LIB) $(LIBS) -o $(TARGET) +perl5_static: $(SRCDIR_SRCS) + $(SWIG) -perl5 -static -lperlmain.i $(SWIGOPT) -o $(ISRCS) $(INTERFACEPATH) + $(CC) $(CFLAGS) -Dbool=char $(SRCDIR_SRCS) $(ISRCS) $(INCLUDES) -I$(PERL5_INCLUDE) $(PERL5_LIB) $(LIBS) -o $(TARGET) -perl5_static_cpp: $(SRCS) - $(SWIG) -perl5 -c++ -static -lperlmain.i $(SWIGOPT) $(INTERFACEPATH) - $(CXX) $(CXXFLAGS) $(SRCS) $(CXXSRCS) $(ICXXSRCS) $(INCLUDES) -I$(PERL5_INCLUDE) $(PERL5_LIB) $(LIBS) -o $(TARGET) +perl5_static_cpp: $(SRCDIR_SRCS) + $(SWIG) -perl5 -c++ -static -lperlmain.i $(SWIGOPT) -o $(ICXXSRCS) $(INTERFACEPATH) + $(CXX) $(CXXFLAGS) $(SRCDIR_SRCS) $(SRCDIR_CXXSRCS) $(ICXXSRCS) $(INCLUDES) -I$(PERL5_INCLUDE) $(PERL5_LIB) $(LIBS) -o $(TARGET) # ----------------------------------------------------------------- # Running a Perl5 example @@ -271,15 +288,17 @@ perl5_clean: ##### PYTHON ###### ################################################################## +PYTHON_FLAGS = + # Make sure these locate your Python installation ifeq (,$(PY3)) PYTHON_INCLUDE= $(DEFS) @PYINCLUDE@ PYTHON_LIB = @PYLIB@ - PYTHON = @PYTHON@ + PYTHON = @PYTHON@ $(PYTHON_FLAGS) else PYTHON_INCLUDE= $(DEFS) @PY3INCLUDE@ PYTHON_LIB = @PY3LIB@ - PYTHON = @PYTHON3@ + PYTHON = @PYTHON3@ $(PYTHON_FLAGS) endif # Extra Python specific linking options @@ -303,18 +322,18 @@ endif # Build a C dynamically loadable module # ---------------------------------------------------------------- -python: $(SRCS) - $(SWIGPYTHON) $(SWIGOPT) $(INTERFACEPATH) - $(CC) -c $(CCSHARED) $(CFLAGS) $(ISRCS) $(SRCS) $(INCLUDES) $(PYTHON_INCLUDE) +python: $(SRCDIR_SRCS) + $(SWIGPYTHON) $(SWIGOPT) -o $(ISRCS) $(INTERFACEPATH) + $(CC) -c $(CCSHARED) $(CFLAGS) $(ISRCS) $(SRCDIR_SRCS) $(INCLUDES) $(PYTHON_INCLUDE) $(LDSHARED) $(CFLAGS) $(OBJS) $(IOBJS) $(PYTHON_DLNK) $(LIBS) -o $(LIBPREFIX)_$(TARGET)$(PYTHON_SO) # ----------------------------------------------------------------- # Build a C++ dynamically loadable module # ----------------------------------------------------------------- -python_cpp: $(SRCS) - $(SWIGPYTHON) -c++ $(SWIGOPT) $(INTERFACEPATH) - $(CXX) -c $(CCSHARED) $(CXXFLAGS) $(ICXXSRCS) $(SRCS) $(CXXSRCS) $(INCLUDES) $(PYTHON_INCLUDE) +python_cpp: $(SRCDIR_SRCS) + $(SWIGPYTHON) -c++ $(SWIGOPT) -o $(ICXXSRCS) $(INTERFACEPATH) + $(CXX) -c $(CCSHARED) $(CXXFLAGS) $(ICXXSRCS) $(SRCDIR_SRCS) $(SRCDIR_CXXSRCS) $(INCLUDES) $(PYTHON_INCLUDE) $(CXXSHARED) $(CXXFLAGS) $(OBJS) $(IOBJS) $(PYTHON_DLNK) $(LIBS) $(CPP_DLLIBS) -o $(LIBPREFIX)_$(TARGET)$(PYTHON_SO) # ----------------------------------------------------------------- @@ -328,14 +347,14 @@ python_cpp: $(SRCS) TKINTER = PYTHON_LIBOPTS = $(PYTHON_LINK) @LIBS@ $(TKINTER) $(SYSLIBS) -python_static: $(SRCS) - $(SWIGPYTHON) -lembed.i $(SWIGOPT) $(INTERFACEPATH) - $(CC) $(CFLAGS) @LINKFORSHARED@ $(ISRCS) $(SRCS) $(INCLUDES) \ +python_static: $(SRCDIR_SRCS) + $(SWIGPYTHON) -lembed.i $(SWIGOPT) -o $(ISRCS) $(INTERFACEPATH) + $(CC) $(CFLAGS) @LINKFORSHARED@ $(ISRCS) $(SRCDIR_SRCS) $(INCLUDES) \ $(PYTHON_INCLUDE) $(LIBS) -L$(PYTHON_LIB) $(PYTHON_LIBOPTS) -o $(TARGET) -python_static_cpp: $(SRCS) - $(SWIGPYTHON) -c++ -lembed.i $(SWIGOPT) $(INTERFACEPATH) - $(CXX) $(CXXFLAGS) $(ICXXSRCS) $(SRCS) $(CXXSRCS) $(INCLUDES) \ +python_static_cpp: $(SRCDIR_SRCS) + $(SWIGPYTHON) -c++ -lembed.i $(SWIGOPT) -o $(ICXXSRCS) $(INTERFACEPATH) + $(CXX) $(CXXFLAGS) $(ICXXSRCS) $(SRCDIR_SRCS) $(SRCDIR_CXXSRCS) $(INCLUDES) \ $(PYTHON_INCLUDE) $(LIBS) -L$(PYTHON_LIB) $(PYTHON_LIBOPTS) -o $(TARGET) # ----------------------------------------------------------------- @@ -351,9 +370,15 @@ endif PY2TO3 = 2to3 `2to3 -l | grep -v -E "Available|import$$" | awk '{print "-f "$$0}'` python_run: $(PYSCRIPT) + export PYTHONPATH=".:$$PYTHONPATH"; \ $(RUNTOOL) $(PYTHON) $(PYSCRIPT) $(RUNPIPE) -$(RUNME)3.py: $(RUNME).py +ifneq (,$(SRCDIR)) +$(RUNME).py: $(SRCDIR)$(RUNME).py + cp $< $@ +endif + +$(RUNME)3.py: $(SRCDIR)$(RUNME).py cp $< $@ $(PY2TO3) -w $@ >/dev/null 2>&1 @@ -389,26 +414,26 @@ OCTAVE_CXX = $(DEFS) @OCTAVE_CPPFLAGS@ @OCTAVE_CXXFLAGS@ OCTAVE_DLNK = @OCTAVE_LDFLAGS@ OCTAVE_SO = @OCTAVE_SO@ -OCTAVE_SCRIPT = $(RUNME).m +OCTAVE_SCRIPT = $(SRCDIR)$(RUNME).m # ---------------------------------------------------------------- # Build a C dynamically loadable module # Note: Octave requires C++ compiler when compiling C wrappers # ---------------------------------------------------------------- -octave: $(SRCS) - $(SWIG) -octave $(SWIGOPT) $(INTERFACEPATH) +octave: $(SRCDIR_SRCS) + $(SWIG) -octave $(SWIGOPT) -o $(ICXXSRCS) $(INTERFACEPATH) $(CXX) -g -c $(CCSHARED) $(CXXFLAGS) $(ICXXSRCS) $(INCLUDES) $(OCTAVE_CXX) - $(CC) -g -c $(CCSHARED) $(CFLAGS) $(SRCS) $(CSRCS) $(INCLUDES) + $(CC) -g -c $(CCSHARED) $(CFLAGS) $(SRCDIR_SRCS) $(SRCDIR_CSRCS) $(INCLUDES) $(LDSHARED) $(CFLAGS) $(OBJS) $(IOBJS) $(OCTAVE_DLNK) $(LIBS) -o $(LIBPREFIX)$(TARGET)$(OCTAVE_SO) # ----------------------------------------------------------------- # Build a C++ dynamically loadable module # ----------------------------------------------------------------- -octave_cpp: $(SRCS) - $(SWIG) -c++ -octave $(SWIGOPT) $(INTERFACEPATH) - $(CXX) -g -c $(CCSHARED) $(CXXFLAGS) $(ICXXSRCS) $(SRCS) $(CXXSRCS) $(INCLUDES) $(OCTAVE_CXX) +octave_cpp: $(SRCDIR_SRCS) + $(SWIG) -c++ -octave $(SWIGOPT) -o $(ICXXSRCS) $(INTERFACEPATH) + $(CXX) -g -c $(CCSHARED) $(CXXFLAGS) $(ICXXSRCS) $(SRCDIR_SRCS) $(SRCDIR_CXXSRCS) $(INCLUDES) $(OCTAVE_CXX) $(CXXSHARED) -g $(CXXFLAGS) $(OBJS) $(IOBJS) $(OCTAVE_DLNK) $(LIBS) $(CPP_DLLIBS) -o $(LIBPREFIX)$(TARGET)$(OCTAVE_SO) # ----------------------------------------------------------------- @@ -446,20 +471,20 @@ GUILE_SO = @GUILE_SO@ GUILE_LIBS = @GUILE_LIBS@ GUILE_LIBOPTS = @LIBS@ $(SYSLIBS) GUILE_LIBPREFIX = lib -GUILE_SCRIPT = $(RUNME).scm +GUILE_SCRIPT = $(SRCDIR)$(RUNME).scm #------------------------------------------------------------------ # Build a dynamically loaded module with passive linkage #------------------------------------------------------------------ -guile: $(SRCS) - $(SWIG) -guile -Linkage passive $(SWIGOPT) $(INTERFACEPATH) - $(CC) -c $(CCSHARED) $(CFLAGS) $(INCLUDES) $(GUILE_CFLAGS) $(ISRCS) $(SRCS) +guile: $(SRCDIR_SRCS) + $(SWIG) -guile -Linkage passive $(SWIGOPT) -o $(ISRCS) $(INTERFACEPATH) + $(CC) -c $(CCSHARED) $(CFLAGS) $(INCLUDES) $(GUILE_CFLAGS) $(ISRCS) $(SRCDIR_SRCS) $(LDSHARED) $(CFLAGS) $(OBJS) $(IOBJS) $(GUILE_LIBS) $(LIBS) -o $(GUILE_LIBPREFIX)$(TARGET)$(GUILE_SO) guile_cpp: $(GUILE_LIBPREFIX)$(TARGET)$(GUILE_SO) -$(GUILE_LIBPREFIX)$(TARGET)$(GUILE_SO): $(SRCS) - $(SWIG) -c++ -guile -Linkage passive $(SWIGOPT) $(INTERFACEPATH) - $(CXX) -c $(CCSHARED) $(CXXFLAGS) $(INCLUDES) $(GUILE_CFLAGS) $(ICXXSRCS) $(SRCS) $(CXXSRCS) +$(GUILE_LIBPREFIX)$(TARGET)$(GUILE_SO): $(SRCDIR_SRCS) + $(SWIG) -c++ -guile -Linkage passive $(SWIGOPT) -o $(ICXXSRCS) $(INTERFACEPATH) + $(CXX) -c $(CCSHARED) $(CXXFLAGS) $(INCLUDES) $(GUILE_CFLAGS) $(ICXXSRCS) $(SRCDIR_SRCS) $(SRCDIR_CXXSRCS) $(CXXSHARED) $(CXXFLAGS) $(OBJS) $(IOBJS) $(GUILE_LIBS) $(LIBS) $(CPP_DLLIBS) -o $@ guile_externalhdr: @@ -469,34 +494,34 @@ guile_externalhdr: # Build Guile interpreter augmented with extra functions # ----------------------------------------------------------------- -guile_augmented: - $(SWIG) -guile $(SWIGOPT) $(INTERFACE) - $(CC) $(CXXFLAGS) $(SRCS) $(ISRCS) $(GUILE_CFLAGS) $(GUILE_LIBS) $(LIBS) -o $(TARGET) +guile_augmented: $(SRCDIR_SRCS) + $(SWIG) -guile $(SWIGOPT) -o $(ISRCS) $(INTERFACEPATH) + $(CC) $(CXXFLAGS) $(SRCDIR_SRCS) $(ISRCS) $(GUILE_CFLAGS) $(GUILE_LIBS) $(LIBS) -o $(TARGET) # ----------------------------------------------------------------- # Build statically linked Guile interpreter # ----------------------------------------------------------------- -guile_static: $(SRCS) - $(SWIG) -guile -lguilemain.i -Linkage ltdlmod $(SWIGOPT) $(INTERFACEPATH) - $(CC) $(CFLAGS) $(ISRCS) $(SRCS) $(INCLUDES) \ +guile_static: $(SRCDIR_SRCS) + $(SWIG) -guile -lguilemain.i -Linkage ltdlmod $(SWIGOPT) -o $(ISRCS) $(INTERFACEPATH) + $(CC) $(CFLAGS) $(ISRCS) $(SRCDIR_SRCS) $(INCLUDES) \ -DSWIGINIT="SCM scm_init_$(TARGET)_module(void); scm_init_$(TARGET)_module();" \ $(GUILE_CFLAGS) $(GUILE_LIBS) $(LIBS) $(GUILE_LIBOPTS) -o $(TARGET)-guile -guile_static_cpp: $(SRCS) - $(SWIG) -c++ -guile -lguilemain.i -Linkage ltdlmod $(SWIGOPT) $(INTERFACEPATH) - $(CXX) $(CXXFLAGS) $(ICXXSRCS) $(SRCS) $(CXXSRCS) $(INCLUDES) \ +guile_static_cpp: $(SRCDIR_SRCS) + $(SWIG) -c++ -guile -lguilemain.i -Linkage ltdlmod $(SWIGOPT) -o $(ICXXSRCS) $(INTERFACEPATH) + $(CXX) $(CXXFLAGS) $(ICXXSRCS) $(SRCDIR_SRCS) $(SRCDIR_CXXSRCS) $(INCLUDES) \ -DSWIGINIT="SCM scm_init_$(TARGET)_module(void); scm_init_$(TARGET)_module();" \ $(GUILE_CFLAGS) $(GUILE_LIBS) $(LIBS) $(GUILE_LIBOPTS) -o $(TARGET)-guile -guile_simple: $(SRCS) - $(SWIG) -guile -lguilemain.i -Linkage simple $(SWIGOPT) $(INTERFACEPATH) - $(CC) $(CFLAGS) $(ISRCS) $(SRCS) $(INCLUDES) \ +guile_simple: $(SRCDIR_SRCS) + $(SWIG) -guile -lguilemain.i -Linkage simple $(SWIGOPT) -o $(ISRCS) $(INTERFACEPATH) + $(CC) $(CFLAGS) $(ISRCS) $(SRCDIR_SRCS) $(INCLUDES) \ $(GUILE_CFLAGS) $(GUILE_LIBS) $(LIBS) $(GUILE_LIBOPTS) -o $(TARGET)-guile -guile_simple_cpp: $(SRCS) - $(SWIG) -c++ -guile -lguilemain.i -Linkage simple $(SWIGOPT) $(INTERFACEPATH) - $(CXX) $(CXXFLAGS) $(ICXXSRCS) $(SRCS) $(CXXSRCS) $(INCLUDES) \ +guile_simple_cpp: $(SRCDIR_SRCS) + $(SWIG) -c++ -guile -lguilemain.i -Linkage simple $(SWIGOPT) -o $(ICXXSRCS) $(INTERFACEPATH) + $(CXX) $(CXXFLAGS) $(ICXXSRCS) $(SRCDIR_SRCS) $(SRCDIR_CXXSRCS) $(INCLUDES) \ $(GUILE_CFLAGS) $(GUILE_LIBS) $(LIBS) $(GUILE_LIBOPTS) -o $(TARGET)-guile # ----------------------------------------------------------------- @@ -542,39 +567,39 @@ JAVALDSHARED = @JAVALDSHARED@ JAVACXXSHARED = @JAVACXXSHARED@ JAVACFLAGS = @JAVACFLAGS@ JAVA = @JAVA@ -JAVAC = @JAVAC@ +JAVAC = @JAVAC@ -d . # ---------------------------------------------------------------- # Build a java dynamically loadable module (C) # ---------------------------------------------------------------- -java: $(SRCS) - $(SWIG) -java $(SWIGOPT) $(INTERFACEPATH) - $(CC) -c $(CCSHARED) $(CFLAGS) $(JAVACFLAGS) $(SRCS) $(ISRCS) $(INCLUDES) $(JAVA_INCLUDE) +java: $(SRCDIR_SRCS) + $(SWIG) -java $(SWIGOPT) -o $(ISRCS) $(realpath $(INTERFACEPATH)) + $(CC) -c $(CCSHARED) $(CFLAGS) $(JAVACFLAGS) $(SRCDIR_SRCS) $(ISRCS) $(INCLUDES) $(JAVA_INCLUDE) $(JAVALDSHARED) $(CFLAGS) $(OBJS) $(IOBJS) $(JAVA_DLNK) $(LIBS) -o $(JAVA_LIBPREFIX)$(TARGET)$(JAVASO) # ---------------------------------------------------------------- # Build a java dynamically loadable module (C++) # ---------------------------------------------------------------- -java_cpp: $(SRCS) - $(SWIG) -java -c++ $(SWIGOPT) $(INTERFACEPATH) - $(CXX) -c $(CCSHARED) $(CXXFLAGS) $(JAVACFLAGS) $(SRCS) $(CXXSRCS) $(ICXXSRCS) $(INCLUDES) $(JAVA_INCLUDE) +java_cpp: $(SRCDIR_SRCS) + $(SWIG) -java -c++ $(SWIGOPT) -o $(ICXXSRCS) $(realpath $(INTERFACEPATH)) + $(CXX) -c $(CCSHARED) $(CXXFLAGS) $(JAVACFLAGS) $(SRCDIR_SRCS) $(SRCDIR_CXXSRCS) $(ICXXSRCS) $(INCLUDES) $(JAVA_INCLUDE) $(JAVACXXSHARED) $(CXXFLAGS) $(OBJS) $(IOBJS) $(JAVA_DLNK) $(LIBS) $(CPP_DLLIBS) -o $(JAVA_LIBPREFIX)$(TARGET)$(JAVASO) # ---------------------------------------------------------------- # Compile java files # ---------------------------------------------------------------- -java_compile: $(SRCS) - $(COMPILETOOL) $(JAVAC) $(JAVACFLAGS) $(JAVASRCS) +java_compile: $(SRCDIR_SRCS) + $(COMPILETOOL) $(JAVAC) $(JAVACFLAGS) $(addprefix $(SRCDIR),$(JAVASRCS)) # ----------------------------------------------------------------- # Run java example # ----------------------------------------------------------------- java_run: - env LD_LIBRARY_PATH=. $(RUNTOOL) $(JAVA) $(RUNME) $(RUNPIPE) + env LD_LIBRARY_PATH=$$PWD $(RUNTOOL) $(JAVA) $(RUNME) $(RUNPIPE) # ----------------------------------------------------------------- # Version display @@ -617,37 +642,38 @@ NODEGYP = @NODEGYP@ javascript_wrapper: $(SWIG) -javascript $(SWIGOPT) -o $(INTERFACEDIR)$(TARGET)_wrap.c $(INTERFACEPATH) -javascript_wrapper_cpp: $(SRCS) +javascript_wrapper_cpp: $(SRCDIR_SRCS) $(SWIG) -javascript -c++ $(SWIGOPT) -o $(INTERFACEDIR)$(TARGET)_wrap.cxx $(INTERFACEPATH) -javascript_build: $(SRCS) - $(CC) -c $(CCSHARED) $(CFLAGS) $(ISRCS) $(SRCS) $(INCLUDES) $(JSINCLUDES) +javascript_build: $(SRCDIR_SRCS) + $(CC) -c $(CCSHARED) $(CFLAGS) $(ISRCS) $(SRCDIR_SRCS) $(INCLUDES) $(JSINCLUDES) $(LDSHARED) $(CFLAGS) $(OBJS) $(IOBJS) $(JSDYNAMICLINKING) $(LIBS) -o $(LIBPREFIX)$(TARGET)$(SO) -javascript_build_cpp: $(SRCS) +javascript_build_cpp: $(SRCDIR_SRCS) ifeq (node,$(JSENGINE)) + sed -e 's|$$srcdir|./$(SRCDIR)|g' $(SRCDIR)binding.gyp.in > binding.gyp $(NODEGYP) --loglevel=silent configure build 1>>/dev/null else - $(CXX) -c $(CCSHARED) $(CFLAGS) $(ICXXSRCS) $(SRCS) $(CXXSRCS) $(INCLUDES) $(JSINCLUDES) + $(CXX) -c $(CCSHARED) $(CFLAGS) $(ICXXSRCS) $(SRCDIR_SRCS) $(SRCDIR_CXXSRCS) $(INCLUDES) $(JSINCLUDES) $(CXXSHARED) $(CFLAGS) $(OBJS) $(IOBJS) $(JSDYNAMICLINKING) $(LIBS) $(CPP_DLLIBS) -o $(LIBPREFIX)$(TARGET)$(SO) endif # These targets are used by the test-suite: -javascript: $(SRCS) javascript_custom_interpreter +javascript: $(SRCDIR_SRCS) javascript_custom_interpreter $(SWIG) -javascript $(SWIGOPT) $(INTERFACEPATH) ifeq (jsc, $(ENGINE)) - $(CC) -c $(CCSHARED) $(CFLAGS) $(ISRCS) $(SRCS) $(INCLUDES) $(JSINCLUDES) + $(CC) -c $(CCSHARED) $(CFLAGS) $(ISRCS) $(SRCDIR_SRCS) $(INCLUDES) $(JSINCLUDES) $(LDSHARED) $(CFLAGS) $(OBJS) $(IOBJS) $(JSDYNAMICLINKING) $(LIBS) -o $(LIBPREFIX)$(TARGET)$(SO) else # (v8 | node) # v8 and node must be compiled as c++ - $(CXX) -c $(CCSHARED) $(CFLAGS) $(ISRCS) $(SRCS) $(CXXSRCS) $(INCLUDES) $(JSINCLUDES) + $(CXX) -c $(CCSHARED) $(CFLAGS) $(ISRCS) $(SRCDIR_SRCS) $(SRCDIR_CXXSRCS) $(INCLUDES) $(JSINCLUDES) $(CXXSHARED) $(CFLAGS) $(OBJS) $(IOBJS) $(JSDYNAMICLINKING) $(LIBS) $(CPP_DLLIBS) -o $(LIBPREFIX)$(TARGET)$(SO) endif -javascript_cpp: $(SRCS) javascript_custom_interpreter +javascript_cpp: $(SRCDIR_SRCS) javascript_custom_interpreter $(SWIG) -javascript -c++ $(SWIGOPT) $(INTERFACEPATH) - $(CXX) -c $(CCSHARED) $(CFLAGS) $(ICXXSRCS) $(SRCS) $(CXXSRCS) $(INCLUDES) $(JSINCLUDES) + $(CXX) -c $(CCSHARED) $(CFLAGS) $(ICXXSRCS) $(SRCDIR_SRCS) $(SRCDIR_CXXSRCS) $(INCLUDES) $(JSINCLUDES) $(CXXSHARED) $(CFLAGS) $(OBJS) $(IOBJS) $(JSDYNAMICLINKING) $(LIBS) $(CPP_DLLIBS) -o $(LIBPREFIX)$(TARGET)$(SO) # ----------------------------------------------------------------- @@ -659,10 +685,10 @@ javascript_custom_interpreter: ifeq (node,$(JSENGINE)) javascript_run: - $(RUNTOOL) $(NODEJS) $(RUNME).js $(RUNPIPE) + env NODE_PATH=$$PWD:$(SRCDIR) $(RUNTOOL) $(NODEJS) $(SRCDIR)$(RUNME).js $(RUNPIPE) else javascript_run: javascript_custom_interpreter - $(RUNTOOL) $(ROOT_DIR)/Tools/javascript/javascript -$(JSENGINE) -L $(TARGET) $(RUNME).js $(RUNPIPE) + $(RUNTOOL) $(ROOT_DIR)/Tools/javascript/javascript -$(JSENGINE) -L $(TARGET) $(SRCDIR)$(RUNME).js $(RUNPIPE) endif # ----------------------------------------------------------------- @@ -718,7 +744,7 @@ TARGETID = 1 # Build an Android dynamically loadable module (C) # ---------------------------------------------------------------- -android: $(SRCS) +android: $(SRCDIR_SRCS) $(ANDROID) $(SILENT_OPTION) update project --target $(TARGETID) --name $(PROJECTNAME) --path . $(SWIG) -java $(SWIGOPT) -o $(INTERFACEDIR)$(TARGET)_wrap.c $(INTERFACEPATH) +$(ANDROID_NDK_BUILD) $(SILENT_PIPE) @@ -728,7 +754,7 @@ android: $(SRCS) # Build an Android dynamically loadable module (C++) # ---------------------------------------------------------------- -android_cpp: $(SRCS) +android_cpp: $(SRCDIR_SRCS) $(ANDROID) $(SILENT_OPTION) update project --target $(TARGETID) --name $(PROJECTNAME) --path . $(SWIG) -java -c++ $(SWIGOPT) -o $(INTERFACEDIR)$(TARGET)_wrap.cpp $(INTERFACEPATH) +$(ANDROID_NDK_BUILD) $(SILENT_PIPE) @@ -769,13 +795,13 @@ MODULA3_INCLUDE= @MODULA3INC@ # Build a modula3 dynamically loadable module (C) # ---------------------------------------------------------------- -modula3: $(SRCS) - $(SWIG) -modula3 $(SWIGOPT) $(INTERFACEPATH) -# $(CC) -c $(CCSHARED) $(CFLAGS) $(SRCS) $(ISRCS) $(INCLUDES) \ +modula3: $(SRCDIR_SRCS) + $(SWIG) -modula3 $(SWIGOPT) -o $(ISRCS) $(INTERFACEPATH) +# $(CC) -c $(CCSHARED) $(CFLAGS) $(SRCDIR_SRCS) $(ISRCS) $(INCLUDES) \ # $(OBJS) $(IOBJS) $(LIBS) -modula3_cpp: $(SRCS) - $(SWIG) -modula3 -c++ $(SWIGOPT) $(INTERFACEPATH) +modula3_cpp: $(SRCDIR_SRCS) + $(SWIG) -modula3 -c++ $(SWIGOPT) -o $(ICXXSRCS) $(INTERFACEPATH) # ----------------------------------------------------------------- # Run modula3 example @@ -814,14 +840,14 @@ MZSCHEME_SCRIPT = $(RUNME).scm # Build a C/C++ dynamically loadable module # ---------------------------------------------------------------- -mzscheme: $(SRCS) - $(SWIG) -mzscheme $(SWIGOPT) $(INTERFACEPATH) - $(COMPILETOOL) $(MZC) `echo $(INCLUDES) | sed 's/-I/++ccf -I/g'` --cc $(ISRCS) $(SRCS) +mzscheme: $(SRCDIR_SRCS) + $(SWIG) -mzscheme $(SWIGOPT) -o $(ISRCS) $(INTERFACEPATH) + $(COMPILETOOL) $(MZC) `echo $(INCLUDES) | sed 's/-I/++ccf -I/g'` --cc $(ISRCS) $(SRCDIR_SRCS) $(COMPILETOOL) $(MZC) --ld $(TARGET)$(MZSCHEME_SO) $(OBJS) $(IOBJS) -mzscheme_cpp: $(SRCS) - $(SWIG) -mzscheme -c++ $(SWIGOPT) $(INTERFACEPATH) - $(COMPILETOOL) $(MZC) `echo $(INCLUDES) | sed 's/-I/++ccf -I/g'` --cc $(ICXXSRCS) $(SRCS) $(CXXSRCS) +mzscheme_cpp: $(SRCDIR_SRCS) + $(SWIG) -mzscheme -c++ $(SWIGOPT) -o $(ICXXSRCS) $(INTERFACEPATH) + $(COMPILETOOL) $(MZC) `echo $(INCLUDES) | sed 's/-I/++ccf -I/g'` --cc $(ICXXSRCS) $(SRCDIR_SRCS) $(SRCDIR_CXXSRCS) $(CXXSHARED) $(CXXFLAGS) -o $(LIBPREFIX)$(TARGET)$(MZSCHEME_SO) $(OBJS) $(IOBJS) $(MZDYNOBJ) $(CPP_DLLIBS) # ----------------------------------------------------------------- @@ -829,7 +855,7 @@ mzscheme_cpp: $(SRCS) # ----------------------------------------------------------------- mzscheme_run: - env LD_LIBRARY_PATH=. $(RUNTOOL) $(MZSCHEME) -r $(MZSCHEME_SCRIPT) $(RUNPIPE) + env LD_LIBRARY_PATH=$$PWD $(RUNTOOL) $(MZSCHEME) -r $(MZSCHEME_SCRIPT) $(RUNPIPE) # ----------------------------------------------------------------- # Version display @@ -869,10 +895,10 @@ OCAMLCORE=\ $(OCC) -I $(OCAMLP4WHERE) -pp "camlp4o pa_extend.cmo q_MLast.cmo" \ -c swigp4.ml -ocaml_static: $(SRCS) +ocaml_static: $(SRCDIR_SRCS) $(OCAMLCORE) - $(SWIG) -ocaml $(SWIGOPT) $(INTERFACEPATH) - $(OCC) -g -c -ccopt -g -ccopt "$(INCLUDES)" $(ISRCS) $(SRCS) + $(SWIG) -ocaml $(SWIGOPT) -o $(ISRCS) $(INTERFACEPATH) + $(OCC) -g -c -ccopt -g -ccopt "$(INCLUDES)" $(ISRCS) $(SRCDIR_SRCS) $(OCC) -g -c $(INTERFACE:%.i=%.mli) $(OCC) -g -c $(INTERFACE:%.i=%.ml) test -z "$(PROGFILE)" || test -f "$(PROGFILE)" && \ @@ -883,10 +909,10 @@ ocaml_static: $(SRCS) $(PROGFILE:%.ml=%.cmo) \ $(INTERFACE:%.i=%_wrap.@OBJEXT@) $(OBJS) -cclib "$(LIBS)" -ocaml_dynamic: $(SRCS) +ocaml_dynamic: $(SRCDIR_SRCS) $(OCAMLCORE) - $(SWIG) -ocaml $(SWIGOPT) $(INTERFACEPATH) - $(OCC) -g -c -ccopt -g -ccopt "$(INCLUDES)" $(ISRCS) $(SRCS) + $(SWIG) -ocaml $(SWIGOPT) -o $(ISRCS) $(INTERFACEPATH) + $(OCC) -g -c -ccopt -g -ccopt "$(INCLUDES)" $(ISRCS) $(SRCDIR_SRCS) $(CXXSHARED) $(CXXFLAGS) $(CCSHARED) $(CFLAGS) -o $(INTERFACE:%.i=%@SO@) \ $(INTERFACE:%.i=%_wrap.@OBJEXT@) $(OBJS) $(LIBS) $(OCAMLDLGEN) $(INTERFACE:%.i=%.ml) $(INTERFACE:%.i=%@SO@) > \ @@ -902,10 +928,10 @@ ocaml_dynamic: $(SRCS) -package dl -linkpkg \ $(INTERFACE:%.i=%.cmo) $(PROGFILE:%.ml=%.cmo) -ocaml_static_toplevel: $(SRCS) +ocaml_static_toplevel: $(SRCDIR_SRCS) $(OCAMLCORE) - $(SWIG) -ocaml $(SWIGOPT) $(INTERFACEPATH) - $(OCC) -g -c -ccopt -g -ccopt "$(INCLUDES)" $(ISRCS) $(SRCS) + $(SWIG) -ocaml $(SWIGOPT) -o $(ISRCS) $(INTERFACEPATH) + $(OCC) -g -c -ccopt -g -ccopt "$(INCLUDES)" $(ISRCS) $(SRCDIR_SRCS) $(OCC) -g -c $(INTERFACE:%.i=%.mli) $(OCC) -g -c $(INTERFACE:%.i=%.ml) test -z "$(PROGFILE)" || test -f "$(PROGFILE)" && \ @@ -917,12 +943,12 @@ ocaml_static_toplevel: $(SRCS) $(INTERFACE:%.i=%.cmo) \ $(INTERFACE:%.i=%_wrap.@OBJEXT@) $(OBJS) -cclib "$(LIBS)" -ocaml_static_cpp: $(SRCS) +ocaml_static_cpp: $(SRCDIR_SRCS) $(OCAMLCORE) - $(SWIG) -ocaml -c++ $(SWIGOPT) $(INTERFACEPATH) + $(SWIG) -ocaml -c++ $(SWIGOPT) -o $(ICXXSRCS) $(INTERFACEPATH) cp $(ICXXSRCS) $(ICXXSRCS:%.cxx=%.c) $(OCC) -cc '$(CXX) -Wno-write-strings' -g -c -ccopt -g -ccopt "-xc++ $(INCLUDES)" \ - $(ICXXSRCS:%.cxx=%.c) $(SRCS) $(CXXSRCS) + $(ICXXSRCS:%.cxx=%.c) $(SRCDIR_SRCS) $(SRCDIR_CXXSRCS) $(OCC) -g -c $(INTERFACE:%.i=%.mli) $(OCC) -g -c $(INTERFACE:%.i=%.ml) test -z "$(PROGFILE)" || test -f "$(PROGFILE)" && \ @@ -934,12 +960,12 @@ ocaml_static_cpp: $(SRCS) $(INTERFACE:%.i=%_wrap.@OBJEXT@) $(OBJS) \ -cclib "$(LIBS)" -cc '$(CXX) -Wno-write-strings' -ocaml_static_cpp_toplevel: $(SRCS) +ocaml_static_cpp_toplevel: $(SRCDIR_SRCS) $(OCAMLCORE) - $(SWIG) -ocaml -c++ $(SWIGOPT) $(INTERFACEPATH) + $(SWIG) -ocaml -c++ $(SWIGOPT) -o $(ICXXSRCS) $(INTERFACEPATH) cp $(ICXXSRCS) $(ICXXSRCS:%.cxx=%.c) $(OCC) -cc '$(CXX) -Wno-write-strings' -g -c -ccopt -g -ccopt "-xc++ $(INCLUDES)" \ - $(ICXXSRCS:%.cxx=%.c) $(SRCS) $(CXXSRCS) + $(ICXXSRCS:%.cxx=%.c) $(SRCDIR_SRCS) $(SRCDIR_CXXSRCS) $(OCC) -g -c $(INTERFACE:%.i=%.mli) $(OCC) -g -c $(INTERFACE:%.i=%.ml) test -z "$(PROGFILE)" || test -f "$(PROGFILE)" && \ @@ -952,12 +978,12 @@ ocaml_static_cpp_toplevel: $(SRCS) $(INTERFACE:%.i=%_wrap.@OBJEXT@) $(OBJS) \ -cclib "$(LIBS)" -cc '$(CXX) -Wno-write-strings' -ocaml_dynamic_cpp: $(SRCS) +ocaml_dynamic_cpp: $(SRCDIR_SRCS) $(OCAMLCORE) - $(SWIG) -ocaml -c++ $(SWIGOPT) $(INTERFACEPATH) + $(SWIG) -ocaml -c++ $(SWIGOPT) -o $(ICXXSRCS) $(INTERFACEPATH) cp $(ICXXSRCS) $(ICXXSRCS:%.cxx=%.c) $(OCC) -cc '$(CXX) -Wno-write-strings' -g -c -ccopt -g -ccopt "-xc++ $(INCLUDES)" \ - $(ICXXSRCS:%.cxx=%.c) $(SRCS) $(CXXSRCS) -ccopt -fPIC + $(ICXXSRCS:%.cxx=%.c) $(SRCDIR_SRCS) $(SRCDIR_CXXSRCS) -ccopt -fPIC $(CXXSHARED) $(CXXFLAGS) -o $(INTERFACE:%.i=%@SO@) \ $(INTERFACE:%.i=%_wrap.@OBJEXT@) $(OBJS) \ $(CPP_DLLIBS) $(LIBS) @@ -1010,25 +1036,25 @@ RUBY_DLNK = @RUBYDYNAMICLINKING@ RUBY_LIBOPTS = @RUBYLINK@ @LIBS@ $(SYSLIBS) RUBY_SO = @RUBYSO@ RUBY = @RUBY@ -RUBY_SCRIPT = $(RUNME).rb +RUBY_SCRIPT = $(SRCDIR)$(RUNME).rb # ---------------------------------------------------------------- # Build a C dynamically loadable module # ---------------------------------------------------------------- -ruby: $(SRCS) - $(SWIG) -ruby $(SWIGOPT) $(INTERFACEPATH) - $(CC) -c $(CCSHARED) $(CFLAGS) $(RUBY_CFLAGS) $(ISRCS) $(SRCS) $(INCLUDES) $(RUBY_INCLUDE) +ruby: $(SRCDIR_SRCS) + $(SWIG) -ruby $(SWIGOPT) -o $(ISRCS) $(INTERFACEPATH) + $(CC) -c $(CCSHARED) $(CFLAGS) $(RUBY_CFLAGS) $(ISRCS) $(SRCDIR_SRCS) $(INCLUDES) $(RUBY_INCLUDE) $(LDSHARED) $(CFLAGS) $(OBJS) $(IOBJS) $(RUBY_DLNK) $(LIBS) -o $(LIBPREFIX)$(TARGET)$(RUBY_SO) # ----------------------------------------------------------------- # Build a C++ dynamically loadable module # ----------------------------------------------------------------- -ruby_cpp: $(SRCS) - $(SWIG) -c++ -ruby $(SWIGOPT) $(INTERFACEPATH) - $(CXX) -c $(CCSHARED) $(CXXFLAGS) $(RUBY_CFLAGS) $(ICXXSRCS) $(SRCS) $(CXXSRCS) $(INCLUDES) $(RUBY_INCLUDE) +ruby_cpp: $(SRCDIR_SRCS) + $(SWIG) -c++ -ruby $(SWIGOPT) -o $(ICXXSRCS) $(INTERFACEPATH) + $(CXX) -c $(CCSHARED) $(CXXFLAGS) $(RUBY_CFLAGS) $(ICXXSRCS) $(SRCDIR_SRCS) $(SRCDIR_CXXSRCS) $(INCLUDES) $(RUBY_INCLUDE) $(CXXSHARED) $(CXXFLAGS) $(OBJS) $(IOBJS) $(RUBY_DLNK) $(LIBS) $(CPP_DLLIBS) -o $(LIBPREFIX)$(TARGET)$(RUBY_SO) # ----------------------------------------------------------------- @@ -1038,14 +1064,14 @@ ruby_cpp: $(SRCS) # library file # ----------------------------------------------------------------- -ruby_static: $(SRCS) - $(SWIG) -ruby -lembed.i $(SWIGOPT) $(INTERFACEPATH) - $(CC) $(CFLAGS) $(RUBY_CFLAGS) @LINKFORSHARED@ $(ISRCS) $(SRCS) $(INCLUDES) \ +ruby_static: $(SRCDIR_SRCS) + $(SWIG) -ruby -lembed.i $(SWIGOPT) -o $(ISRCS) $(INTERFACEPATH) + $(CC) $(CFLAGS) $(RUBY_CFLAGS) @LINKFORSHARED@ $(ISRCS) $(SRCDIR_SRCS) $(INCLUDES) \ $(RUBY_INCLUDE) $(LIBS) -L$(RUBY_LIB) $(RUBY_LIBOPTS) -o $(TARGET) -ruby_cpp_static: $(SRCS) - $(SWIG) -c++ -ruby -lembed.i $(SWIGOPT) $(INTERFACEPATH) - $(CXX) $(CXXFLAGS) $(RUBY_CFLAGS) $(ICXXSRCS) $(SRCS) $(CXXSRCS) $(INCLUDES) \ +ruby_cpp_static: $(SRCDIR_SRCS) + $(SWIG) -c++ -ruby -lembed.i $(SWIGOPT) -o $(ICXXSRCS) $(INTERFACEPATH) + $(CXX) $(CXXFLAGS) $(RUBY_CFLAGS) $(ICXXSRCS) $(SRCDIR_SRCS) $(SRCDIR_CXXSRCS) $(INCLUDES) \ $(RUBY_INCLUDE) $(LIBS) -L$(RUBY_LIB) $(RUBY_LIBOPTS) -o $(TARGET) # ----------------------------------------------------------------- @@ -1078,24 +1104,24 @@ ruby_clean: PHP = @PHP@ PHP_INCLUDE = @PHPINC@ PHP_SO = @PHP_SO@ -PHP_SCRIPT = $(RUNME).php +PHP_SCRIPT = $(SRCDIR)$(RUNME).php # ------------------------------------------------------------------- # Build a PHP dynamically loadable module (C) # ------------------------------------------------------------------- -php: $(SRCS) - $(SWIG) -php $(SWIGOPT) $(INTERFACEPATH) - $(CC) -c $(CCSHARED) $(CFLAGS) $(SRCS) $(ISRCS) $(INCLUDES) $(PHP_INCLUDE) +php: $(SRCDIR_SRCS) + $(SWIG) -php $(SWIGOPT) -o $(ISRCS) $(INTERFACEPATH) + $(CC) -c $(CCSHARED) $(CFLAGS) $(SRCDIR_SRCS) $(ISRCS) $(INCLUDES) $(PHP_INCLUDE) $(LDSHARED) $(CFLAGS) $(OBJS) $(IOBJS) $(LIBS) -o $(LIBPREFIX)$(TARGET)$(PHP_SO) # -------------------------------------------------------------------- # Build a PHP dynamically loadable module (C++) # -------------------------------------------------------------------- -php_cpp: $(SRCS) - $(SWIG) -php -cppext cxx -c++ $(SWIGOPT) $(INTERFACEPATH) - $(CXX) -c $(CCSHARED) $(CXXFLAGS) $(SRCS) $(CXXSRCS) $(ICXXSRCS) $(INCLUDES) $(PHP_INCLUDE) +php_cpp: $(SRCDIR_SRCS) + $(SWIG) -php -cppext cxx -c++ $(SWIGOPT) -o $(ICXXSRCS) $(INTERFACEPATH) + $(CXX) -c $(CCSHARED) $(CXXFLAGS) $(SRCDIR_SRCS) $(SRCDIR_CXXSRCS) $(ICXXSRCS) $(INCLUDES) $(PHP_INCLUDE) $(CXXSHARED) $(CXXFLAGS) $(OBJS) $(IOBJS) $(LIBS) $(CPP_DLLIBS) -o $(LIBPREFIX)$(TARGET)$(PHP_SO) # ----------------------------------------------------------------- @@ -1138,18 +1164,18 @@ PIKE_SCRIPT = $(RUNME).pike # Build a C dynamically loadable module # ---------------------------------------------------------------- -pike: $(SRCS) - $(SWIG) -pike $(SWIGOPT) $(INTERFACEPATH) - $(CC) -c $(CCSHARED) $(CFLAGS) $(PIKE_CFLAGS) $(ISRCS) $(SRCS) $(INCLUDES) $(PIKE_INCLUDE) +pike: $(SRCDIR_SRCS) + $(SWIG) -pike $(SWIGOPT) -o $(ISRCS) $(INTERFACEPATH) + $(CC) -c $(CCSHARED) $(CFLAGS) $(PIKE_CFLAGS) $(ISRCS) $(SRCDIR_SRCS) $(INCLUDES) $(PIKE_INCLUDE) $(LDSHARED) $(CFLAGS) $(OBJS) $(IOBJS) $(PIKE_DLNK) $(LIBS) -o $(LIBPREFIX)$(TARGET)$(SO) # ----------------------------------------------------------------- # Build a C++ dynamically loadable module # ----------------------------------------------------------------- -pike_cpp: $(SRCS) - $(SWIG) -c++ -pike $(SWIGOPT) $(INTERFACEPATH) - $(CXX) -c $(CCSHARED) $(CXXFLAGS) $(PIKE_CFLAGS) $(ICXXSRCS) $(SRCS) $(CXXSRCS) $(INCLUDES) $(PIKE_INCLUDE) +pike_cpp: $(SRCDIR_SRCS) + $(SWIG) -c++ -pike $(SWIGOPT) -o $(ICXXSRCS) $(INTERFACEPATH) + $(CXX) -c $(CCSHARED) $(CXXFLAGS) $(PIKE_CFLAGS) $(ICXXSRCS) $(SRCDIR_SRCS) $(SRCDIR_CXXSRCS) $(INCLUDES) $(PIKE_INCLUDE) $(CXXSHARED) $(CXXFLAGS) $(OBJS) $(IOBJS) $(PIKE_DLNK) $(LIBS) $(CPP_DLLIBS) -o $(LIBPREFIX)$(TARGET)$(SO) # ----------------------------------------------------------------- @@ -1159,14 +1185,14 @@ pike_cpp: $(SRCS) # library file # ----------------------------------------------------------------- -pike_static: $(SRCS) - $(SWIG) -pike -lembed.i $(SWIGOPT) $(INTERFACEPATH) - $(CC) $(CFLAGS) $(PIKE_CFLAGS) @LINKFORSHARED@ $(ISRCS) $(SRCS) $(INCLUDES) \ +pike_static: $(SRCDIR_SRCS) + $(SWIG) -pike -lembed.i $(SWIGOPT) -o $(ISRCS) $(INTERFACEPATH) + $(CC) $(CFLAGS) $(PIKE_CFLAGS) @LINKFORSHARED@ $(ISRCS) $(SRCDIR_SRCS) $(INCLUDES) \ $(PIKE_INCLUDE) $(LIBS) -L$(PIKE_LIB) $(PIKE_LIBOPTS) -o $(TARGET) -pike_cpp_static: $(SRCS) - $(SWIG) -c++ -pike -lembed.i $(SWIGOPT) $(INTERFACEPATH) - $(CXX) $(CXXFLAGS) $(PIKE_CFLAGS) $(ICXXSRCS) $(SRCS) $(CXXSRCS) $(INCLUDES) \ +pike_cpp_static: $(SRCDIR_SRCS) + $(SWIG) -c++ -pike -lembed.i $(SWIGOPT) -o $(ICXXSRCS) $(INTERFACEPATH) + $(CXX) $(CXXFLAGS) $(PIKE_CFLAGS) $(ICXXSRCS) $(SRCDIR_SRCS) $(SRCDIR_CXXSRCS) $(INCLUDES) \ $(PIKE_INCLUDE) $(LIBS) -L$(PIKE_LIB) $(PIKE_LIBOPTS) -o $(TARGET) # ----------------------------------------------------------------- @@ -1222,23 +1248,23 @@ CHICKEN_COMPILED_MAIN_OBJECT = $(CHICKEN_COMPILED_MAIN:.c=.@OBJEXT@) # ----------------------------------------------------------------- # This is the old way to build chicken, but it does not work correctly with exceptions -chicken_direct: $(SRCS) +chicken_direct: $(SRCDIR_SRCS) $(SWIG) -chicken $(SWIGOPT) $(INCLUDE) $(INTERFACEPATH) $(CHICKEN) $(CHICKEN_GENERATED_SCHEME) $(CHICKENOPTS) \ -dynamic -feature chicken-compile-shared \ -output-file $(CHICKEN_COMPILED_SCHEME) $(CC) -c $(CCSHARED) $(CFLAGS) $(CHICKEN_CFLAGS) \ - $(INCLUDES) $(CHICKEN_INCLUDE) $(ISRCS) $(SRCS) $(CHICKEN_COMPILED_SCHEME) + $(INCLUDES) $(CHICKEN_INCLUDE) $(ISRCS) $(SRCDIR_SRCS) $(CHICKEN_COMPILED_SCHEME) $(LDSHARED) $(CFLAGS) $(CHICKEN_COMPILED_OBJECT) $(OBJS) $(IOBJS) \ $(LIBS) $(CHICKEN_SHAREDLIBOPTS) -o $(LIBPREFIX)$(TARGET)$(SO) -chicken_direct_cpp: $(CXXSRCS) $(CHICKSRCS) +chicken_direct_cpp: $(SRCDIR_CXXSRCS) $(CHICKSRCS) $(SWIG) -c++ -chicken $(SWIGOPT) $(INCLUDE) $(INTERFACEPATH) $(CHICKEN) $(CHICKEN_GENERATED_SCHEME) $(CHICKENOPTS) \ -dynamic -feature chicken-compile-shared \ -output-file $(CHICKEN_COMPILED_SCHEME) $(CXX) -c $(CCSHARED) $(CXXFLAGS) $(CHICKEN_CFLAGS) \ - $(INCLUDES) $(CHICKEN_INCLUDE) $(ICXXSRCS) $(SRCS) $(CXXSRCS) $(CHICKEN_COMPILED_SCHEME) + $(INCLUDES) $(CHICKEN_INCLUDE) $(ICXXSRCS) $(SRCDIR_SRCS) $(SRCDIR_CXXSRCS) $(CHICKEN_COMPILED_SCHEME) $(CXXSHARED) $(CXXFLAGS) $(CHICKEN_COMPILED_OBJECT) $(OBJS) $(IOBJS) \ $(LIBS) $(CPP_DLLIBS) $(CHICKEN_SHAREDLIBOPTS) -o $(LIBPREFIX)$(TARGET)$(SO) @@ -1247,26 +1273,26 @@ chicken_direct_cpp: $(CXXSRCS) $(CHICKSRCS) # ----------------------------------------------------------------- # The following two targets are also used by the test suite -chicken_static: $(SRCS) $(CHICKSRCS) +chicken_static: $(SRCDIR_SRCS) $(CHICKSRCS) $(SWIG) -chicken $(SWIGOPT) $(INCLUDE) $(INTERFACEPATH) $(CHICKEN) $(CHICKEN_GENERATED_SCHEME) $(CHICKENOPTS) \ -output-file $(CHICKEN_COMPILED_SCHEME) $(CHICKEN) $(CHICKEN_MAIN) $(CHICKENOPTS) \ -output-file $(CHICKEN_MAIN:.scm=_chicken.c) $(CC) -c $(CCSHARED) $(CFLAGS) $(CHICKEN_CFLAGS) \ - $(INCLUDES) $(CHICKEN_INCLUDE) $(ISRCS) $(SRCS) \ + $(INCLUDES) $(CHICKEN_INCLUDE) $(ISRCS) $(SRCDIR_SRCS) \ $(CHICKEN_COMPILED_SCHEME) $(CHICKEN_COMPILED_MAIN) $(CC) $(CHICKEN_COMPILED_OBJECT) $(CHICKEN_COMPILED_MAIN_OBJECT) \ $(OBJS) $(IOBJS) $(LIBS) $(CHICKEN_SHAREDLIBOPTS) -o $(TARGET) -chicken_static_cpp: $(CXXSRCS) $(CHICKSRCS) +chicken_static_cpp: $(SRCDIR_CXXSRCS) $(CHICKSRCS) $(SWIG) -c++ -chicken $(SWIGOPT) $(INCLUDE) $(INTERFACEPATH) $(CHICKEN) $(CHICKEN_GENERATED_SCHEME) $(CHICKENOPTS) \ -output-file $(CHICKEN_COMPILED_SCHEME) $(CHICKEN) $(CHICKEN_MAIN) $(CHICKENOPTS) \ -output-file $(CHICKEN_MAIN:.scm=_chicken.c) $(CXX) -c $(CCSHARED) $(CXXFLAGS) $(CHICKEN_CFLAGS) \ - $(INCLUDES) $(CHICKEN_INCLUDE) $(ICXXSRCS) $(SRCS) $(CXXSRCS) \ + $(INCLUDES) $(CHICKEN_INCLUDE) $(ICXXSRCS) $(SRCDIR_SRCS) $(SRCDIR_CXXSRCS) \ $(CHICKEN_COMPILED_SCHEME) $(CHICKEN_COMPILED_MAIN) $(CXX) $(CHICKEN_COMPILED_OBJECT) $(CHICKEN_COMPILED_MAIN_OBJECT) \ $(OBJS) $(IOBJS) $(LIBS) $(CPP_DLLIBS) $(CHICKEN_SHAREDLIBOPTS) -o $(TARGET) @@ -1277,11 +1303,11 @@ chicken_static_cpp: $(CXXSRCS) $(CHICKSRCS) chicken: $(SWIG) -chicken $(SWIGOPT) $(INCLUDE) $(INTERFACEPATH) - $(COMPILETOOL) $(CHICKEN_CSC) -s `echo $(INCLUDES) | sed 's/-I/-C -I/g'` $(CHICKEN_GENERATED_SCHEME) $(SRCS) $(ISRCS) -o $(TARGET)$(SO) + $(COMPILETOOL) $(CHICKEN_CSC) -s `echo $(INCLUDES) | sed 's/-I/-C -I/g'` $(CHICKEN_GENERATED_SCHEME) $(SRCDIR_SRCS) $(ISRCS) -o $(TARGET)$(SO) chicken_cpp: $(SWIG) -c++ -chicken $(SWIGOPT) $(INCLUDE) $(INTERFACEPATH) - $(COMPILETOOL) $(CHICKEN_CSC) -s `echo $(INCLUDES) | sed 's/-I/-C -I/g'` $(CHICKEN_GENERATED_SCHEME) $(SRCS) $(ICXXSRCS) $(CXXSRCS) -o $(TARGET)$(SO) + $(COMPILETOOL) $(CHICKEN_CSC) -s `echo $(INCLUDES) | sed 's/-I/-C -I/g'` $(CHICKEN_GENERATED_SCHEME) $(SRCDIR_SRCS) $(ICXXSRCS) $(SRCDIR_CXXSRCS) -o $(TARGET)$(SO) chicken_externalhdr: $(SWIG) -chicken -external-runtime $(TARGET) @@ -1291,7 +1317,7 @@ chicken_externalhdr: # ----------------------------------------------------------------- chicken_run: - env LD_LIBRARY_PATH=. $(RUNTOOL) $(CHICKEN_CSI) $(CHICKEN_SCRIPT) $(RUNPIPE) + env LD_LIBRARY_PATH=$$PWD $(RUNTOOL) $(CHICKEN_CSI) $(CHICKEN_SCRIPT) $(RUNPIPE) # ----------------------------------------------------------------- # Version display @@ -1327,33 +1353,39 @@ CSHARP_RUNME = $(CSHARPCILINTERPRETER) $(CSHARPCILINTERPRETER_FLAGS) ./$(RUNME). # Build a CSharp dynamically loadable module (C) # ---------------------------------------------------------------- -csharp: $(SRCS) - $(SWIG) -csharp $(SWIGOPT) $(INTERFACEPATH) - $(CC) -c $(CCSHARED) $(CFLAGS) $(CSHARPCFLAGS) $(SRCS) $(ISRCS) $(INCLUDES) +csharp: $(SRCDIR_SRCS) + $(SWIG) -csharp $(SWIGOPT) -o $(ISRCS) $(INTERFACEPATH) + $(CC) -c $(CCSHARED) $(CFLAGS) $(CSHARPCFLAGS) $(SRCDIR_SRCS) $(ISRCS) $(INCLUDES) $(LDSHARED) $(CFLAGS) $(OBJS) $(IOBJS) $(CSHARP_DLNK) $(LIBS) -o $(CSHARP_LIBPREFIX)$(TARGET)$(CSHARPSO) # ---------------------------------------------------------------- # Build a CSharp dynamically loadable module (C++) # ---------------------------------------------------------------- -csharp_cpp: $(SRCS) - $(SWIG) -csharp -c++ $(SWIGOPT) $(INTERFACEPATH) - $(CXX) -c $(CCSHARED) $(CXXFLAGS) $(CSHARPCFLAGS) $(SRCS) $(CXXSRCS) $(ICXXSRCS) $(INCLUDES) +csharp_cpp: $(SRCDIR_SRCS) + $(SWIG) -csharp -c++ $(SWIGOPT) -o $(ICXXSRCS) $(INTERFACEPATH) + $(CXX) -c $(CCSHARED) $(CXXFLAGS) $(CSHARPCFLAGS) $(SRCDIR_SRCS) $(SRCDIR_CXXSRCS) $(ICXXSRCS) $(INCLUDES) $(CXXSHARED) $(CXXFLAGS) $(OBJS) $(IOBJS) $(CSHARP_DLNK) $(LIBS) $(CPP_DLLIBS) -o $(CSHARP_LIBPREFIX)$(TARGET)$(CSHARPSO) # ---------------------------------------------------------------- # Compile CSharp files # ---------------------------------------------------------------- -csharp_compile: $(SRCS) - $(COMPILETOOL) $(CSHARPCOMPILER) $(CSHARPFLAGS) $(CSHARPSRCS) +ifneq (,$(SRCDIR)) +SRCDIR_CSHARPSRCS = $(wildcard $(addprefix $(SRCDIR),$(CSHARPSRCS))) +else +SRCDIR_CSHARPSRCS = +endif + +csharp_compile: $(SRCDIR_SRCS) + $(COMPILETOOL) $(CSHARPCOMPILER) $(CSHARPFLAGS) $(CSHARPSRCS) $(SRCDIR_CSHARPSRCS) # ----------------------------------------------------------------- # Run CSharp example # ----------------------------------------------------------------- csharp_run: - env LD_LIBRARY_PATH=. $(RUNTOOL) $(CSHARP_RUNME) $(RUNPIPE) + env LD_LIBRARY_PATH=$$PWD $(RUNTOOL) $(CSHARP_RUNME) $(RUNPIPE) # ----------------------------------------------------------------- # Version display @@ -1385,7 +1417,7 @@ LUA_DLNK = @LUADYNAMICLINKING@ LUA_SO = @LUA_SO@ LUA = @LUABIN@ -LUA_SCRIPT = $(RUNME).lua +LUA_SCRIPT = $(SRCDIR)$(RUNME).lua # Extra code for lua static link LUA_INTERP = ../lua.c @@ -1394,32 +1426,32 @@ LUA_INTERP = ../lua.c # Build a C dynamically loadable module # ---------------------------------------------------------------- -lua: $(SRCS) - $(SWIG) -lua $(SWIGOPT) $(INTERFACEPATH) - $(CC) -c $(CCSHARED) $(CFLAGS) $(ISRCS) $(SRCS) $(INCLUDES) $(LUA_INCLUDE) +lua: $(SRCDIR_SRCS) + $(SWIG) -lua $(SWIGOPT) -o $(ISRCS) $(INTERFACEPATH) + $(CC) -c $(CCSHARED) $(CFLAGS) $(ISRCS) $(SRCDIR_SRCS) $(INCLUDES) $(LUA_INCLUDE) $(LDSHARED) $(CFLAGS) $(OBJS) $(IOBJS) $(LIBS) $(LUA_LIB) -o $(LIBPREFIX)$(TARGET)$(LUA_SO) # ----------------------------------------------------------------- # Build a C++ dynamically loadable module # ----------------------------------------------------------------- -lua_cpp: $(SRCS) - $(SWIG) -c++ -lua $(SWIGOPT) $(INTERFACEPATH) - $(CXX) -c $(CCSHARED) $(CXXFLAGS) $(ICXXSRCS) $(SRCS) $(CXXSRCS) $(INCLUDES) $(LUA_INCLUDE) +lua_cpp: $(SRCDIR_SRCS) $(GENCXXSRCS) + $(SWIG) -c++ -lua $(SWIGOPT) -o $(ICXXSRCS) $(INTERFACEPATH) + $(CXX) -c $(CCSHARED) $(CXXFLAGS) $(ICXXSRCS) $(SRCDIR_SRCS) $(SRCDIR_CXXSRCS) $(GENCXXSRCS) $(INCLUDES) $(LUA_INCLUDE) $(CXXSHARED) $(CXXFLAGS) $(OBJS) $(IOBJS) $(LIBS) $(LUA_LIB) $(CPP_DLLIBS) -o $(LIBPREFIX)$(TARGET)$(LUA_SO) # ----------------------------------------------------------------- # Build statically linked Lua interpreter # ----------------------------------------------------------------- -lua_static: $(SRCS) - $(SWIG) -lua -module example $(SWIGOPT) $(INTERFACEPATH) - $(CC) $(CFLAGS) $(ISRCS) $(SRCS) $(LUA_INTERP) $(INCLUDES) \ +lua_static: $(SRCDIR_SRCS) + $(SWIG) -lua -module example $(SWIGOPT) -o $(ISRCS) $(INTERFACEPATH) + $(CC) $(CFLAGS) $(ISRCS) $(SRCDIR_SRCS) $(SRCDIR)$(LUA_INTERP) $(INCLUDES) \ $(LUA_INCLUDE) $(LIBS) $(LUA_LIB) -o $(TARGET) -lua_static_cpp: $(SRCS) - $(SWIG) -c++ -lua -module example $(SWIGOPT) $(INTERFACEPATH) - $(CXX) $(CXXFLAGS) $(ICXXSRCS) $(SRCS) $(CXXSRCS) $(LUA_INTERP) $(INCLUDES) \ +lua_static_cpp: $(SRCDIR_SRCS) $(GENCXXSRCS) + $(SWIG) -c++ -lua -module example $(SWIGOPT) -o $(ICXXSRCS) $(INTERFACEPATH) + $(CXX) $(CXXFLAGS) $(ICXXSRCS) $(SRCDIR_SRCS) $(SRCDIR_CXXSRCS) $(GENCXXSRCS) $(SRCDIR)$(LUA_INTERP) $(INCLUDES) \ $(LUA_INCLUDE) $(LIBS) $(LUA_LIB) -o $(TARGET) # ----------------------------------------------------------------- @@ -1430,7 +1462,7 @@ lua_run: $(RUNTOOL) $(LUA) $(LUA_SCRIPT) $(RUNPIPE) lua_embed_run: - $(RUNTOOL) ./$(TARGET) $(RUNPIPE) + $(RUNTOOL) ./$(TARGET) $(LUA_SCRIPT) $(RUNPIPE) # ----------------------------------------------------------------- # Version display @@ -1455,14 +1487,14 @@ lua_clean: ALLEGROCL = @ALLEGROCLBIN@ ALLEGROCL_SCRIPT=$(RUNME).lisp -allegrocl: $(SRCS) - $(SWIG) -allegrocl -cwrap $(SWIGOPT) $(INTERFACEPATH) - $(CC) -c $(CCSHARED) $(CFLAGS) $(ISRCS) $(INCLUDES) $(SRCS) +allegrocl: $(SRCDIR_SRCS) + $(SWIG) -allegrocl -cwrap $(SWIGOPT) -o $(ISRCS) $(INTERFACEPATH) + $(CC) -c $(CCSHARED) $(CFLAGS) $(ISRCS) $(INCLUDES) $(SRCDIR_SRCS) $(LDSHARED) $(CFLAGS) $(OBJS) $(IOBJS) $(LIBS) -o $(LIBPREFIX)$(TARGET)$(SO) -allegrocl_cpp: $(SRCS) - $(SWIG) -c++ -allegrocl $(SWIGOPT) $(INTERFACEPATH) - $(CXX) -c $(CCSHARED) $(CXXFLAGS) $(ICXXSRCS) $(SRCS) $(CXXSRCS) $(INCLUDES) +allegrocl_cpp: $(SRCDIR_SRCS) + $(SWIG) -c++ -allegrocl $(SWIGOPT) -o $(ICXXSRCS) $(INTERFACEPATH) + $(CXX) -c $(CCSHARED) $(CXXFLAGS) $(ICXXSRCS) $(SRCDIR_SRCS) $(SRCDIR_CXXSRCS) $(INCLUDES) $(CXXSHARED) $(CXXFLAGS) $(OBJS) $(IOBJS) $(LIBS) $(CPP_DLLIBS) -o $(LIBPREFIX)$(TARGET)$(SO) # ----------------------------------------------------------------- @@ -1495,11 +1527,11 @@ allegrocl_clean: CLISP = @CLISPBIN@ CLISP_SCRIPT=$(RUNME).lisp -clisp: $(SRCS) - $(SWIG) -clisp $(SWIGOPT) $(INTERFACEPATH) +clisp: $(SRCDIR_SRCS) + $(SWIG) -clisp $(SWIGOPT) -o $(ISRCS) $(INTERFACEPATH) -clisp_cpp: $(SRCS) - $(SWIG) -c++ -clisp $(SWIGOPT) $(INTERFACEPATH) +clisp_cpp: $(SRCDIR_SRCS) + $(SWIG) -c++ -clisp $(SWIGOPT) -o $(ICXXSRCS) $(INTERFACEPATH) # ----------------------------------------------------------------- # Run CLISP example @@ -1531,14 +1563,14 @@ clisp_clean: CFFI = @CFFIBIN@ CFFI_SCRIPT=$(RUNME).lisp -cffi: $(SRCS) - $(SWIG) -cffi $(SWIGOPT) $(INTERFACEPATH) -# $(CC) -c $(CCSHARED) $(CFLAGS) $(ISRCS) $(INCLUDES) $(SRCS) +cffi: $(SRCDIR_SRCS) + $(SWIG) -cffi $(SWIGOPT) -o $(ISRCS) $(INTERFACEPATH) +# $(CC) -c $(CCSHARED) $(CFLAGS) $(ISRCS) $(INCLUDES) $(SRCDIR_SRCS) # $(LDSHARED) $(CFLAGS) $(OBJS) $(IOBJS) $(LIBS) -o $(LIBPREFIX)$(TARGET)$(SO) -cffi_cpp: $(SRCS) - $(SWIG) -c++ -cffi $(SWIGOPT) $(INTERFACEPATH) - $(CXX) -c $(CCSHARED) $(CXXFLAGS) $(ICXXSRCS) $(SRCS) $(CXXSRCS) $(INCLUDES) +cffi_cpp: $(SRCDIR_SRCS) + $(SWIG) -c++ -cffi $(SWIGOPT) -o $(ICXXSRCS) $(INTERFACEPATH) + $(CXX) -c $(CCSHARED) $(CXXFLAGS) $(ICXXSRCS) $(SRCDIR_SRCS) $(SRCDIR_CXXSRCS) $(INCLUDES) $(CXXSHARED) $(CXXFLAGS) $(OBJS) $(IOBJS) $(LIBS) $(CPP_DLLIBS) -o $(LIBPREFIX)$(TARGET)$(SO) # ----------------------------------------------------------------- @@ -1571,14 +1603,14 @@ cffi_clean: UFFI = @UFFIBIN@ UFFI_SCRIPT=$(RUNME).lisp -uffi: $(SRCS) - $(SWIG) -uffi $(SWIGOPT) $(INTERFACEPATH) -# $(CC) -c $(CCSHARED) $(CFLAGS) $(ISRCS) $(INCLUDES) $(SRCS) +uffi: $(SRCDIR_SRCS) + $(SWIG) -uffi $(SWIGOPT) -o $(ISRCS) $(INTERFACEPATH) +# $(CC) -c $(CCSHARED) $(CFLAGS) $(ISRCS) $(INCLUDES) $(SRCDIR_SRCS) # $(LDSHARED) $(CFLAGS) $(OBJS) $(IOBJS) $(LIBS) -o $(LIBPREFIX)$(TARGET)$(SO) -uffi_cpp: $(SRCS) - $(SWIG) -c++ -uffi $(SWIGOPT) $(INTERFACEPATH) -# $(CXX) -c $(CCSHARED) $(CXXFLAGS) $(ICXXSRCS) $(SRCS) $(CXXSRCS) $(INCLUDES) +uffi_cpp: $(SRCDIR_SRCS) + $(SWIG) -c++ -uffi $(SWIGOPT) -o $(ICXXSRCS) $(INTERFACEPATH) +# $(CXX) -c $(CCSHARED) $(CXXFLAGS) $(ICXXSRCS) $(SRCDIR_SRCS) $(SRCDIR_CXXSRCS) $(INCLUDES) # $(CXXSHARED) $(CXXFLAGS) $(OBJS) $(IOBJS) $(LIBS) $(CPP_DLLIBS) -o $(LIBPREFIX)$(TARGET)$(SO) # ----------------------------------------------------------------- @@ -1622,10 +1654,10 @@ R_SCRIPT=$(RUNME).R # Build a R dynamically loadable module (C) # ---------------------------------------------------------------- -r: $(SRCS) - $(SWIG) -r $(SWIGOPT) $(INTERFACEPATH) -ifneq ($(SRCS),) - $(CC) -g -c $(CFLAGS) $(R_CFLAGS) $(SRCS) $(INCLUDES) +r: $(SRCDIR_SRCS) + $(SWIG) -r $(SWIGOPT) -o $(ISRCS) $(INTERFACEPATH) +ifneq ($(SRCDIR_SRCS),) + $(CC) -g -c $(CFLAGS) $(R_CFLAGS) $(SRCDIR_SRCS) $(INCLUDES) endif +( PKG_CPPFLAGS="$(INCLUDES)" $(COMPILETOOL) $(R) CMD SHLIB -o $(LIBPREFIX)$(TARGET)$(SO) $(ISRCS) $(OBJS) > /dev/null ) @@ -1633,10 +1665,10 @@ endif # Build a R dynamically loadable module (C++) # ---------------------------------------------------------------- -r_cpp: $(CXXSRCS) +r_cpp: $(SRCDIR_CXXSRCS) $(SWIG) -c++ -r $(SWIGOPT) -o $(RCXXSRCS) $(INTERFACEPATH) -ifneq ($(CXXSRCS),) - $(CXX) -g -c $(CXXFLAGS) $(R_CFLAGS) $(CXXSRCS) $(INCLUDES) +ifneq ($(SRCDIR_CXXSRCS),) + $(CXX) -g -c $(CXXFLAGS) $(R_CFLAGS) $(SRCDIR_CXXSRCS) $(INCLUDES) endif +( PKG_CPPFLAGS="$(INCLUDES)" $(COMPILETOOL) $(R) CMD SHLIB -o $(LIBPREFIX)$(TARGET)$(SO) $(RCXXSRCS) $(OBJS) > /dev/null ) @@ -1697,12 +1729,12 @@ GOGCCOBJS = $(GOSRCS:.go=.@OBJEXT@) # Build a Go module (C) # ---------------------------------------------------------------- -go: $(SRCS) - $(SWIG) -go $(GOOPT) $(GOSWIGARG) $(SWIGOPT) $(INTERFACEPATH) +go: $(SRCDIR_SRCS) + $(SWIG) -go $(GOOPT) $(GOSWIGARG) $(SWIGOPT) -o $(ISRCS) $(INTERFACEPATH) if $(GO12) || $(GO13) || $(GOGCC); then \ - $(CC) -g -c $(CFLAGS) $(SRCS) $(ISRCS) $(INCLUDES); \ + $(CC) -g -c $(CFLAGS) $(SRCDIR_SRCS) $(ISRCS) $(INCLUDES); \ else \ - $(CC) -g -c $(CCSHARED) $(CFLAGS) $(SRCS) $(ISRCS) $(INCLUDES); \ + $(CC) -g -c $(CCSHARED) $(CFLAGS) $(SRCDIR_SRCS) $(ISRCS) $(INCLUDES); \ $(LDSHARED) $(CFLAGS) $(OBJS) $(IOBJS) $(LIBS) -o $(LIBPREFIX)$(TARGET)$(SO); \ fi $(COMPILETOOL) $(GO) $(GOCOMPILEARG) -I . $(GOSRCS) @@ -1718,12 +1750,12 @@ go: $(SRCS) $(COMPILETOOL) $(GOPACK) grc $(GOPACKAGE) $(GOGCOBJS) $(GOCSRCS:.c=.$(GOOBJEXT)); \ fi; \ fi - if test -f $(RUNME).go; then \ - $(GO) $(GOCOMPILEARG) $(RUNME).go; \ + if test -f $(SRCDIR)$(RUNME).go; then \ + $(GO) $(GOCOMPILEARG) $(SRCDIR)$(RUNME).go; \ if $(GOGCC) ; then \ $(COMPILETOOL) $(GO) -o $(RUNME) $(RUNME).@OBJEXT@ $(GOGCCOBJS) $(OBJS) $(IOBJS); \ elif $(GO12) || $(GO13); then \ - $(COMPILETOOL) $(GOTOOL) $(GOLD) -linkmode external -extld $(CC) -extldflags "$(CFLAGS)" -o $(RUNME) $(RUNME).$(GOOBJEXT); \ + $(COMPILETOOL) $(GOTOOL) $(GOLD) -linkmode external -extld "$(CC)" -extldflags "$(CFLAGS)" -o $(RUNME) $(RUNME).$(GOOBJEXT); \ else \ $(COMPILETOOL) $(GOTOOL) $(GOLD) -r $${GOROOT:-`go env GOROOT`}/pkg/$${GOOS:-`go env GOOS`}_$${GOARCH:-`go env GOARCH`}:. -o $(RUNME) $(RUNME).$(GOOBJEXT); \ fi; \ @@ -1733,12 +1765,12 @@ go: $(SRCS) # Build a Go module (C++) # ---------------------------------------------------------------- -go_cpp: $(SRCS) - $(SWIG) -go -c++ $(GOOPT) $(GOSWIGARG) $(SWIGOPT) $(INTERFACEPATH) +go_cpp: $(SRCDIR_SRCS) + $(SWIG) -go -c++ $(GOOPT) $(GOSWIGARG) $(SWIGOPT) -o $(ICXXSRCS) $(INTERFACEPATH) if $(GO12) || $(GO13) || $(GOGCC); then \ - $(CXX) -g -c $(CXXFLAGS) $(SRCS) $(CXXSRCS) $(ICXXSRCS) $(INCLUDES); \ + $(CXX) -g -c $(CXXFLAGS) $(SRCDIR_SRCS) $(SRCDIR_CXXSRCS) $(ICXXSRCS) $(INCLUDES); \ else \ - $(CXX) -g -c $(CCSHARED) $(CXXFLAGS) $(SRCS) $(CXXSRCS) $(ICXXSRCS) $(INCLUDES); \ + $(CXX) -g -c $(CCSHARED) $(CXXFLAGS) $(SRCDIR_SRCS) $(SRCDIR_CXXSRCS) $(ICXXSRCS) $(INCLUDES); \ $(CXXSHARED) $(CXXFLAGS) $(OBJS) $(IOBJS) $(LIBS) $(CPP_DLLIBS) -o $(LIBPREFIX)$(TARGET)$(SO); \ fi $(COMPILETOOL) $(GO) $(GOCOMPILEARG) -I . $(GOSRCS) @@ -1754,12 +1786,12 @@ go_cpp: $(SRCS) $(COMPILETOOL) $(GOPACK) grc $(GOPACKAGE) $(GOGCOBJS) $(GOCSRCS:.c=.$(GOOBJEXT)); \ fi; \ fi - if test -f $(RUNME).go; then \ - $(GO) $(GOCOMPILEARG) $(RUNME).go; \ + if test -f $(SRCDIR)$(RUNME).go; then \ + $(GO) $(GOCOMPILEARG) $(SRCDIR)$(RUNME).go; \ if $(GOGCC) ; then \ $(COMPILETOOL) $(GO) -o $(RUNME) $(RUNME).@OBJEXT@ $(GOGCCOBJS) $(OBJS) $(IOBJS) -lstdc++; \ elif $(GO12) || $(GO13); then \ - $(COMPILETOOL) $(GOTOOL) $(GOLD) -linkmode external -extld $(CXX) -extldflags "$(CXXFLAGS)" -o $(RUNME) $(RUNME).$(GOOBJEXT); \ + $(COMPILETOOL) $(GOTOOL) $(GOLD) -linkmode external -extld "$(CXX)" -extldflags "$(CXXFLAGS)" -o $(RUNME) $(RUNME).$(GOOBJEXT); \ else \ $(COMPILETOOL) $(GOTOOL) $(GOLD) -r $${GOROOT:-`go env GOROOT`}/pkg/$${GOOS:-`go env GOOS`}_$${GOARCH:-`go env GOARCH`}:. -o $(RUNME) $(RUNME).$(GOOBJEXT); \ fi; \ @@ -1770,7 +1802,7 @@ go_cpp: $(SRCS) # ----------------------------------------------------------------- go_run: - env LD_LIBRARY_PATH=.:$$LD_LIBRARY_PATH $(RUNTOOL) ./$(RUNME) $(RUNPIPE) + env LD_LIBRARY_PATH=$$PWD $(RUNTOOL) ./$(RUNME) $(RUNPIPE) # ----------------------------------------------------------------- # Version display @@ -1812,18 +1844,18 @@ D_RUNME = ./$(RUNME) # Build a dynamically loadable D wrapper for a C module # ---------------------------------------------------------------- -d: $(SRCS) - $(SWIGD) $(SWIGOPT) $(INTERFACEPATH) - $(CC) -c $(CCSHARED) $(CFLAGS) $(DCFLAGS) $(EXTRA_CFLAGS) $(SRCS) $(ISRCS) $(INCLUDES) +d: $(SRCDIR_SRCS) + $(SWIGD) $(SWIGOPT) -o $(ISRCS) $(INTERFACEPATH) + $(CC) -c $(CCSHARED) $(CFLAGS) $(DCFLAGS) $(EXTRA_CFLAGS) $(SRCDIR_SRCS) $(ISRCS) $(INCLUDES) $(LDSHARED) $(CFLAGS) $(DCFLAGS) $(EXTRA_LDFLAGS) $(OBJS) $(IOBJS) $(LIBS) -o $(DLIBPREFIX)$(TARGET)$(SO) # ---------------------------------------------------------------- # Build a dynamically loadable D wrapper for a C++ module # ---------------------------------------------------------------- -d_cpp: $(SRCS) - $(SWIGD) -c++ $(SWIGOPT) $(INTERFACEPATH) - $(CXX) -c $(CCSHARED) $(CXXFLAGS) $(DCFLAGS) $(EXTRA_CFLAGS) $(SRCS) $(CXXSRCS) $(ICXXSRCS) $(INCLUDES) +d_cpp: $(SRCDIR_SRCS) + $(SWIGD) -c++ $(SWIGOPT) -o $(ICXXSRCS) $(INTERFACEPATH) + $(CXX) -c $(CCSHARED) $(CXXFLAGS) $(DCFLAGS) $(EXTRA_CFLAGS) $(SRCDIR_SRCS) $(SRCDIR_CXXSRCS) $(ICXXSRCS) $(INCLUDES) $(CXXSHARED) $(CXXFLAGS) $(DCFLAGS) $(EXTRA_LDFLAGS) $(OBJS) $(IOBJS) $(LIBS) $(CPP_DLLIBS) -o $(DLIBPREFIX)$(TARGET)$(SO) # ---------------------------------------------------------------- @@ -1832,7 +1864,7 @@ d_cpp: $(SRCS) # Clear the DFLAGS environment variable for the compiler call itself # to work around a discrepancy in argument handling between DMD and LDC. -d_compile: $(SRCS) +d_compile: $(SRCDIR_SRCS) DFLAGS="" $(COMPILETOOL) $(DCOMPILER) $(DFLAGS) $(DSRCS) # ----------------------------------------------------------------- diff --git a/Examples/android/class/Makefile b/Examples/android/class/Makefile index cef405ece..44d33de0a 100644 --- a/Examples/android/class/Makefile +++ b/Examples/android/class/Makefile @@ -13,14 +13,14 @@ TARGETID = 1 check: build build: - $(MAKE) -f $(TOP)/Makefile CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT)' \ TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' INTERFACEDIR='$(INTERFACEDIR)' \ PROJECTNAME='$(PROJECTNAME)' TARGETID='$(TARGETID)' android_cpp install: - $(MAKE) -f $(TOP)/Makefile INSTALLOPTIONS='$(INSTALLOPTIONS)' PROJECTNAME='$(PROJECTNAME)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' INSTALLOPTIONS='$(INSTALLOPTIONS)' PROJECTNAME='$(PROJECTNAME)' \ PACKAGEDIR='$(PACKAGEDIR)' PACKAGENAME='$(PACKAGENAME)' android_install clean: - $(MAKE) -f $(TOP)/Makefile TARGET='$(TARGET)' PROJECTNAME='$(PROJECTNAME)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' TARGET='$(TARGET)' PROJECTNAME='$(PROJECTNAME)' \ PACKAGEDIR='$(PACKAGEDIR)' INTERFACEDIR='$(INTERFACEDIR)' android_clean diff --git a/Examples/android/extend/Makefile b/Examples/android/extend/Makefile index 9b796494a..3d0609a08 100644 --- a/Examples/android/extend/Makefile +++ b/Examples/android/extend/Makefile @@ -13,14 +13,14 @@ TARGETID = 1 check: build build: - $(MAKE) -f $(TOP)/Makefile CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT)' \ TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' INTERFACEDIR='$(INTERFACEDIR)' \ PROJECTNAME='$(PROJECTNAME)' TARGETID='$(TARGETID)' android_cpp install: - $(MAKE) -f $(TOP)/Makefile INSTALLOPTIONS='$(INSTALLOPTIONS)' PROJECTNAME='$(PROJECTNAME)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' INSTALLOPTIONS='$(INSTALLOPTIONS)' PROJECTNAME='$(PROJECTNAME)' \ PACKAGEDIR='$(PACKAGEDIR)' PACKAGENAME='$(PACKAGENAME)' android_install clean: - $(MAKE) -f $(TOP)/Makefile TARGET='$(TARGET)' PROJECTNAME='$(PROJECTNAME)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' TARGET='$(TARGET)' PROJECTNAME='$(PROJECTNAME)' \ PACKAGEDIR='$(PACKAGEDIR)' INTERFACEDIR='$(INTERFACEDIR)' android_clean diff --git a/Examples/android/simple/Makefile b/Examples/android/simple/Makefile index 7e7ff40e1..d71b9880c 100644 --- a/Examples/android/simple/Makefile +++ b/Examples/android/simple/Makefile @@ -13,14 +13,14 @@ TARGETID = 1 check: build build: - $(MAKE) -f $(TOP)/Makefile CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT)' \ TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' INTERFACEDIR='$(INTERFACEDIR)' \ PROJECTNAME='$(PROJECTNAME)' TARGETID='$(TARGETID)' android install: - $(MAKE) -f $(TOP)/Makefile INSTALLOPTIONS='$(INSTALLOPTIONS)' PROJECTNAME='$(PROJECTNAME)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' INSTALLOPTIONS='$(INSTALLOPTIONS)' PROJECTNAME='$(PROJECTNAME)' \ PACKAGEDIR='$(PACKAGEDIR)' PACKAGENAME='$(PACKAGENAME)' android_install clean: - $(MAKE) -f $(TOP)/Makefile TARGET='$(TARGET)' PROJECTNAME='$(PROJECTNAME)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' TARGET='$(TARGET)' PROJECTNAME='$(PROJECTNAME)' \ PACKAGEDIR='$(PACKAGEDIR)' INTERFACEDIR='$(INTERFACEDIR)' android_clean diff --git a/Examples/chicken/class/Makefile b/Examples/chicken/class/Makefile index cd445c867..5fafa5c15 100644 --- a/Examples/chicken/class/Makefile +++ b/Examples/chicken/class/Makefile @@ -15,24 +15,24 @@ VARIANT = #VARIANT = _static check: build - $(MAKE) -f $(TOP)/Makefile CHICKEN_SCRIPT='runme-lowlevel.scm' chicken_run - $(MAKE) -f $(TOP)/Makefile CHICKEN_SCRIPT='runme-tinyclos.scm' chicken_run + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' CHICKEN_SCRIPT='runme-lowlevel.scm' chicken_run + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' CHICKEN_SCRIPT='runme-tinyclos.scm' chicken_run build: $(TARGET) $(TARGET)_proxy $(TARGET): $(INTERFACE) $(SRCS) - $(MAKE) -f $(TOP)/Makefile \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' \ SRCS='$(SRCS)' CXXSRCS='$(CXXSRCS)' CHICKEN_MAIN='$(CHICKEN_MAIN)' \ INCLUDE='$(INCLUDE)' SWIGOPT='$(SWIGOPT)' TARGET='$(TARGET)' \ SWIG='$(SWIG)' INTERFACE='$(INTERFACE)' CHICKENOPTS='$(CHICKENOPTS)' chicken$(VARIANT)_cpp $(TARGET)_proxy: $(INTERFACE) $(SRCS) - $(MAKE) -f $(TOP)/Makefile \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' \ SRCS='$(SRCS)' CXXSRCS='$(CXXSRCS)' CHICKEN_MAIN='$(CHICKEN_MAIN)' \ INCLUDE='$(INCLUDE)' SWIGOPT='$(SWIGOPT) -proxy' TARGET='$(TARGET)_proxy' \ SWIG='$(SWIG)' INTERFACE='$(INTERFACE)' CHICKENOPTS='$(CHICKENOPTS)' chicken$(VARIANT)_cpp clean: - $(MAKE) -f $(TOP)/Makefile chicken_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' chicken_clean rm -f example.scm rm -f $(TARGET) diff --git a/Examples/chicken/constants/Makefile b/Examples/chicken/constants/Makefile index fe396733e..a6100f757 100644 --- a/Examples/chicken/constants/Makefile +++ b/Examples/chicken/constants/Makefile @@ -14,17 +14,17 @@ VARIANT = #VARIANT = _static check: build - $(MAKE) -f $(TOP)/Makefile chicken_run + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' chicken_run build: $(TARGET) $(TARGET): $(INTERFACE) $(SRCS) - $(MAKE) -f $(TOP)/Makefile \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' \ SRCS='$(SRCS)' CXXSRCS='$(CXXSRCS)' CHICKEN_MAIN='$(CHICKEN_MAIN)' \ INCLUDE='$(INCLUDE)' SWIGOPT='$(SWIGOPT)' TARGET='$(TARGET)' \ SWIG='$(SWIG)' INTERFACE='$(INTERFACE)' CHICKENOPTS='$(CHICKENOPTS)' chicken$(VARIANT) clean: - $(MAKE) -f $(TOP)/Makefile chicken_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' chicken_clean rm -f example.scm rm -f $(TARGET) diff --git a/Examples/chicken/multimap/Makefile b/Examples/chicken/multimap/Makefile index d92cfede0..79282be17 100644 --- a/Examples/chicken/multimap/Makefile +++ b/Examples/chicken/multimap/Makefile @@ -14,17 +14,17 @@ VARIANT = #VARIANT = _static check: build - $(MAKE) -f $(TOP)/Makefile chicken_run + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' chicken_run build: $(TARGET) $(TARGET): $(INTERFACE) $(SRCS) - $(MAKE) -f $(TOP)/Makefile \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' \ SRCS='$(SRCS)' CXXSRCS='$(CXXSRCS)' CHICKEN_MAIN='$(CHICKEN_MAIN)' \ INCLUDE='$(INCLUDE)' SWIGOPT='$(SWIGOPT)' TARGET='$(TARGET)' \ SWIG='$(SWIG)' INTERFACE='$(INTERFACE)' CHICKENOPTS='$(CHICKENOPTS)' chicken$(VARIANT) clean: - $(MAKE) -f $(TOP)/Makefile chicken_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' chicken_clean rm -f example.scm rm -f $(TARGET) diff --git a/Examples/chicken/overload/Makefile b/Examples/chicken/overload/Makefile index fb190e882..717abd335 100644 --- a/Examples/chicken/overload/Makefile +++ b/Examples/chicken/overload/Makefile @@ -14,17 +14,17 @@ VARIANT = #VARIANT = _static check: build - $(MAKE) -f $(TOP)/Makefile chicken_run + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' chicken_run build: $(TARGET) $(TARGET): $(INTERFACE) $(SRCS) - $(MAKE) -f $(TOP)/Makefile \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' \ SRCS='$(SRCS)' CXXSRCS='$(CXXSRCS)' CHICKEN_MAIN='$(CHICKEN_MAIN)' \ INCLUDE='$(INCLUDE)' SWIGOPT='$(SWIGOPT)' TARGET='$(TARGET)' \ SWIG='$(SWIG)' INTERFACE='$(INTERFACE)' CHICKENOPTS='$(CHICKENOPTS)' chicken$(VARIANT)_cpp clean: - $(MAKE) -f $(TOP)/Makefile chicken_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' chicken_clean rm -f example.scm rm -f $(TARGET) diff --git a/Examples/chicken/simple/Makefile b/Examples/chicken/simple/Makefile index d0d737484..9d1f34fa0 100644 --- a/Examples/chicken/simple/Makefile +++ b/Examples/chicken/simple/Makefile @@ -14,17 +14,17 @@ VARIANT = #VARIANT = _static check: build - $(MAKE) -f $(TOP)/Makefile chicken_run + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' chicken_run build: $(TARGET) $(TARGET): $(INTERFACE) $(SRCS) - $(MAKE) -f $(TOP)/Makefile \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' \ SRCS='$(SRCS)' CXXSRCS='$(CXXSRCS)' CHICKEN_MAIN='$(CHICKEN_MAIN)' \ INCLUDE='$(INCLUDE)' SWIGOPT='$(SWIGOPT)' TARGET='$(TARGET)' \ SWIG='$(SWIG)' INTERFACE='$(INTERFACE)' CHICKENOPTS='$(CHICKENOPTS)' chicken$(VARIANT) clean: - $(MAKE) -f $(TOP)/Makefile chicken_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' chicken_clean rm -f example.scm example-generic.scm example-clos.scm rm -f $(TARGET) diff --git a/Examples/csharp/arrays/Makefile b/Examples/csharp/arrays/Makefile index 4be092d1c..e5d733d35 100644 --- a/Examples/csharp/arrays/Makefile +++ b/Examples/csharp/arrays/Makefile @@ -8,12 +8,12 @@ CSHARPSRCS = *.cs CSHARPFLAGS= -nologo -debug+ -unsafe -out:runme.exe check: build - $(MAKE) -f $(TOP)/Makefile csharp_run + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' csharp_run build: - $(MAKE) -f $(TOP)/Makefile SRCS='$(SRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SRCS='$(SRCS)' SWIG='$(SWIG)' \ SWIGOPT='$(SWIGOPT)' TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' csharp - $(MAKE) -f $(TOP)/Makefile CSHARPSRCS='$(CSHARPSRCS)' CSHARPFLAGS='$(CSHARPFLAGS)' csharp_compile + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' CSHARPSRCS='$(CSHARPSRCS)' CSHARPFLAGS='$(CSHARPFLAGS)' csharp_compile clean: - $(MAKE) -f $(TOP)/Makefile csharp_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' csharp_clean diff --git a/Examples/csharp/callback/Makefile b/Examples/csharp/callback/Makefile index 6c58abd28..4f4c84b9a 100644 --- a/Examples/csharp/callback/Makefile +++ b/Examples/csharp/callback/Makefile @@ -8,12 +8,12 @@ CSHARPSRCS = *.cs CSHARPFLAGS= -nologo -debug+ -out:runme.exe check: build - $(MAKE) -f $(TOP)/Makefile csharp_run + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' csharp_run build: - $(MAKE) -f $(TOP)/Makefile CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ SWIGOPT='$(SWIGOPT)' TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' csharp_cpp - $(MAKE) -f $(TOP)/Makefile CSHARPSRCS='$(CSHARPSRCS)' CSHARPFLAGS='$(CSHARPFLAGS)' csharp_compile + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' CSHARPSRCS='$(CSHARPSRCS)' CSHARPFLAGS='$(CSHARPFLAGS)' csharp_compile clean: - $(MAKE) -f $(TOP)/Makefile csharp_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' csharp_clean diff --git a/Examples/csharp/class/Makefile b/Examples/csharp/class/Makefile index 6c58abd28..4f4c84b9a 100644 --- a/Examples/csharp/class/Makefile +++ b/Examples/csharp/class/Makefile @@ -8,12 +8,12 @@ CSHARPSRCS = *.cs CSHARPFLAGS= -nologo -debug+ -out:runme.exe check: build - $(MAKE) -f $(TOP)/Makefile csharp_run + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' csharp_run build: - $(MAKE) -f $(TOP)/Makefile CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ SWIGOPT='$(SWIGOPT)' TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' csharp_cpp - $(MAKE) -f $(TOP)/Makefile CSHARPSRCS='$(CSHARPSRCS)' CSHARPFLAGS='$(CSHARPFLAGS)' csharp_compile + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' CSHARPSRCS='$(CSHARPSRCS)' CSHARPFLAGS='$(CSHARPFLAGS)' csharp_compile clean: - $(MAKE) -f $(TOP)/Makefile csharp_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' csharp_clean diff --git a/Examples/csharp/enum/Makefile b/Examples/csharp/enum/Makefile index 6c58abd28..4f4c84b9a 100644 --- a/Examples/csharp/enum/Makefile +++ b/Examples/csharp/enum/Makefile @@ -8,12 +8,12 @@ CSHARPSRCS = *.cs CSHARPFLAGS= -nologo -debug+ -out:runme.exe check: build - $(MAKE) -f $(TOP)/Makefile csharp_run + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' csharp_run build: - $(MAKE) -f $(TOP)/Makefile CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ SWIGOPT='$(SWIGOPT)' TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' csharp_cpp - $(MAKE) -f $(TOP)/Makefile CSHARPSRCS='$(CSHARPSRCS)' CSHARPFLAGS='$(CSHARPFLAGS)' csharp_compile + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' CSHARPSRCS='$(CSHARPSRCS)' CSHARPFLAGS='$(CSHARPFLAGS)' csharp_compile clean: - $(MAKE) -f $(TOP)/Makefile csharp_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' csharp_clean diff --git a/Examples/csharp/extend/Makefile b/Examples/csharp/extend/Makefile index 6c58abd28..4f4c84b9a 100644 --- a/Examples/csharp/extend/Makefile +++ b/Examples/csharp/extend/Makefile @@ -8,12 +8,12 @@ CSHARPSRCS = *.cs CSHARPFLAGS= -nologo -debug+ -out:runme.exe check: build - $(MAKE) -f $(TOP)/Makefile csharp_run + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' csharp_run build: - $(MAKE) -f $(TOP)/Makefile CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ SWIGOPT='$(SWIGOPT)' TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' csharp_cpp - $(MAKE) -f $(TOP)/Makefile CSHARPSRCS='$(CSHARPSRCS)' CSHARPFLAGS='$(CSHARPFLAGS)' csharp_compile + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' CSHARPSRCS='$(CSHARPSRCS)' CSHARPFLAGS='$(CSHARPFLAGS)' csharp_compile clean: - $(MAKE) -f $(TOP)/Makefile csharp_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' csharp_clean diff --git a/Examples/csharp/funcptr/Makefile b/Examples/csharp/funcptr/Makefile index ed15cb28e..99cdfa38a 100644 --- a/Examples/csharp/funcptr/Makefile +++ b/Examples/csharp/funcptr/Makefile @@ -8,12 +8,12 @@ CSHARPSRCS = *.cs CSHARPFLAGS= -nologo -debug+ -out:runme.exe check: build - $(MAKE) -f $(TOP)/Makefile csharp_run + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' csharp_run build: - $(MAKE) -f $(TOP)/Makefile SRCS='$(SRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SRCS='$(SRCS)' SWIG='$(SWIG)' \ SWIGOPT='$(SWIGOPT)' TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' csharp - $(MAKE) -f $(TOP)/Makefile CSHARPSRCS='$(CSHARPSRCS)' CSHARPFLAGS='$(CSHARPFLAGS)' csharp_compile + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' CSHARPSRCS='$(CSHARPSRCS)' CSHARPFLAGS='$(CSHARPFLAGS)' csharp_compile clean: - $(MAKE) -f $(TOP)/Makefile csharp_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' csharp_clean diff --git a/Examples/csharp/nested/Makefile b/Examples/csharp/nested/Makefile index 6c58abd28..4f4c84b9a 100644 --- a/Examples/csharp/nested/Makefile +++ b/Examples/csharp/nested/Makefile @@ -8,12 +8,12 @@ CSHARPSRCS = *.cs CSHARPFLAGS= -nologo -debug+ -out:runme.exe check: build - $(MAKE) -f $(TOP)/Makefile csharp_run + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' csharp_run build: - $(MAKE) -f $(TOP)/Makefile CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ SWIGOPT='$(SWIGOPT)' TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' csharp_cpp - $(MAKE) -f $(TOP)/Makefile CSHARPSRCS='$(CSHARPSRCS)' CSHARPFLAGS='$(CSHARPFLAGS)' csharp_compile + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' CSHARPSRCS='$(CSHARPSRCS)' CSHARPFLAGS='$(CSHARPFLAGS)' csharp_compile clean: - $(MAKE) -f $(TOP)/Makefile csharp_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' csharp_clean diff --git a/Examples/csharp/reference/Makefile b/Examples/csharp/reference/Makefile index 6c58abd28..4f4c84b9a 100644 --- a/Examples/csharp/reference/Makefile +++ b/Examples/csharp/reference/Makefile @@ -8,12 +8,12 @@ CSHARPSRCS = *.cs CSHARPFLAGS= -nologo -debug+ -out:runme.exe check: build - $(MAKE) -f $(TOP)/Makefile csharp_run + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' csharp_run build: - $(MAKE) -f $(TOP)/Makefile CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ SWIGOPT='$(SWIGOPT)' TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' csharp_cpp - $(MAKE) -f $(TOP)/Makefile CSHARPSRCS='$(CSHARPSRCS)' CSHARPFLAGS='$(CSHARPFLAGS)' csharp_compile + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' CSHARPSRCS='$(CSHARPSRCS)' CSHARPFLAGS='$(CSHARPFLAGS)' csharp_compile clean: - $(MAKE) -f $(TOP)/Makefile csharp_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' csharp_clean diff --git a/Examples/csharp/simple/Makefile b/Examples/csharp/simple/Makefile index ed15cb28e..99cdfa38a 100644 --- a/Examples/csharp/simple/Makefile +++ b/Examples/csharp/simple/Makefile @@ -8,12 +8,12 @@ CSHARPSRCS = *.cs CSHARPFLAGS= -nologo -debug+ -out:runme.exe check: build - $(MAKE) -f $(TOP)/Makefile csharp_run + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' csharp_run build: - $(MAKE) -f $(TOP)/Makefile SRCS='$(SRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SRCS='$(SRCS)' SWIG='$(SWIG)' \ SWIGOPT='$(SWIGOPT)' TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' csharp - $(MAKE) -f $(TOP)/Makefile CSHARPSRCS='$(CSHARPSRCS)' CSHARPFLAGS='$(CSHARPFLAGS)' csharp_compile + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' CSHARPSRCS='$(CSHARPSRCS)' CSHARPFLAGS='$(CSHARPFLAGS)' csharp_compile clean: - $(MAKE) -f $(TOP)/Makefile csharp_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' csharp_clean diff --git a/Examples/csharp/template/Makefile b/Examples/csharp/template/Makefile index 23fe2eec9..2d0e07009 100644 --- a/Examples/csharp/template/Makefile +++ b/Examples/csharp/template/Makefile @@ -8,12 +8,12 @@ CSHARPSRCS = *.cs CSHARPFLAGS= -nologo -debug+ -out:runme.exe check: build - $(MAKE) -f $(TOP)/Makefile csharp_run + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' csharp_run build: - $(MAKE) -f $(TOP)/Makefile CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ SWIGOPT='$(SWIGOPT)' TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' csharp_cpp - $(MAKE) -f $(TOP)/Makefile CSHARPSRCS='$(CSHARPSRCS)' CSHARPFLAGS='$(CSHARPFLAGS)' csharp_compile + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' CSHARPSRCS='$(CSHARPSRCS)' CSHARPFLAGS='$(CSHARPFLAGS)' csharp_compile clean: - $(MAKE) -f $(TOP)/Makefile csharp_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' csharp_clean diff --git a/Examples/csharp/variables/Makefile b/Examples/csharp/variables/Makefile index ed15cb28e..99cdfa38a 100644 --- a/Examples/csharp/variables/Makefile +++ b/Examples/csharp/variables/Makefile @@ -8,12 +8,12 @@ CSHARPSRCS = *.cs CSHARPFLAGS= -nologo -debug+ -out:runme.exe check: build - $(MAKE) -f $(TOP)/Makefile csharp_run + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' csharp_run build: - $(MAKE) -f $(TOP)/Makefile SRCS='$(SRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SRCS='$(SRCS)' SWIG='$(SWIG)' \ SWIGOPT='$(SWIGOPT)' TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' csharp - $(MAKE) -f $(TOP)/Makefile CSHARPSRCS='$(CSHARPSRCS)' CSHARPFLAGS='$(CSHARPFLAGS)' csharp_compile + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' CSHARPSRCS='$(CSHARPSRCS)' CSHARPFLAGS='$(CSHARPFLAGS)' csharp_compile clean: - $(MAKE) -f $(TOP)/Makefile csharp_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' csharp_clean diff --git a/Examples/d/callback/Makefile b/Examples/d/callback/Makefile index eda18f13c..72edc17a5 100644 --- a/Examples/d/callback/Makefile +++ b/Examples/d/callback/Makefile @@ -15,13 +15,13 @@ DFLAGS = -ofrunme check: build cd $(WORKING_DIR); \ - $(MAKE) -f $(TOP)/Makefile d_run + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' d_run build: cd $(WORKING_DIR); \ - $(MAKE) -f $(TOP)/Makefile EXTRA_CFLAGS='$(EXTRA_CFLAGS)' EXTRA_LDFLAGS='$(EXTRA_LDFLAGS)' SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT) -outcurrentdir ../example.i' TARGET='$(TARGET)' d_cpp; \ - $(MAKE) -f $(TOP)/Makefile DSRCS='$(DSRCS)' DFLAGS='$(DFLAGS)' d_compile + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' EXTRA_CFLAGS='$(EXTRA_CFLAGS)' EXTRA_LDFLAGS='$(EXTRA_LDFLAGS)' SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT) -outcurrentdir ../example.i' TARGET='$(TARGET)' d_cpp; \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' DSRCS='$(DSRCS)' DFLAGS='$(DFLAGS)' d_compile clean: cd $(WORKING_DIR); \ - $(MAKE) -f $(TOP)/Makefile d_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' d_clean diff --git a/Examples/d/class/Makefile b/Examples/d/class/Makefile index eda18f13c..72edc17a5 100644 --- a/Examples/d/class/Makefile +++ b/Examples/d/class/Makefile @@ -15,13 +15,13 @@ DFLAGS = -ofrunme check: build cd $(WORKING_DIR); \ - $(MAKE) -f $(TOP)/Makefile d_run + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' d_run build: cd $(WORKING_DIR); \ - $(MAKE) -f $(TOP)/Makefile EXTRA_CFLAGS='$(EXTRA_CFLAGS)' EXTRA_LDFLAGS='$(EXTRA_LDFLAGS)' SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT) -outcurrentdir ../example.i' TARGET='$(TARGET)' d_cpp; \ - $(MAKE) -f $(TOP)/Makefile DSRCS='$(DSRCS)' DFLAGS='$(DFLAGS)' d_compile + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' EXTRA_CFLAGS='$(EXTRA_CFLAGS)' EXTRA_LDFLAGS='$(EXTRA_LDFLAGS)' SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT) -outcurrentdir ../example.i' TARGET='$(TARGET)' d_cpp; \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' DSRCS='$(DSRCS)' DFLAGS='$(DFLAGS)' d_compile clean: cd $(WORKING_DIR); \ - $(MAKE) -f $(TOP)/Makefile d_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' d_clean diff --git a/Examples/d/constants/Makefile b/Examples/d/constants/Makefile index d537ce281..609c7f660 100644 --- a/Examples/d/constants/Makefile +++ b/Examples/d/constants/Makefile @@ -15,13 +15,13 @@ DFLAGS = -ofrunme check: build cd $(WORKING_DIR); \ - $(MAKE) -f $(TOP)/Makefile d_run + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' d_run build: cd $(WORKING_DIR); \ - $(MAKE) -f $(TOP)/Makefile EXTRA_CFLAGS='$(EXTRA_CFLAGS)' EXTRA_LDFLAGS='$(EXTRA_LDFLAGS)' SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT) -outcurrentdir ../example.i' TARGET='$(TARGET)' d; \ - $(MAKE) -f $(TOP)/Makefile DSRCS='$(DSRCS)' DFLAGS='$(DFLAGS)' d_compile + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' EXTRA_CFLAGS='$(EXTRA_CFLAGS)' EXTRA_LDFLAGS='$(EXTRA_LDFLAGS)' SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT) -outcurrentdir ../example.i' TARGET='$(TARGET)' d; \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' DSRCS='$(DSRCS)' DFLAGS='$(DFLAGS)' d_compile clean: cd $(WORKING_DIR); \ - $(MAKE) -f $(TOP)/Makefile d_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' d_clean diff --git a/Examples/d/enum/Makefile b/Examples/d/enum/Makefile index eda18f13c..72edc17a5 100644 --- a/Examples/d/enum/Makefile +++ b/Examples/d/enum/Makefile @@ -15,13 +15,13 @@ DFLAGS = -ofrunme check: build cd $(WORKING_DIR); \ - $(MAKE) -f $(TOP)/Makefile d_run + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' d_run build: cd $(WORKING_DIR); \ - $(MAKE) -f $(TOP)/Makefile EXTRA_CFLAGS='$(EXTRA_CFLAGS)' EXTRA_LDFLAGS='$(EXTRA_LDFLAGS)' SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT) -outcurrentdir ../example.i' TARGET='$(TARGET)' d_cpp; \ - $(MAKE) -f $(TOP)/Makefile DSRCS='$(DSRCS)' DFLAGS='$(DFLAGS)' d_compile + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' EXTRA_CFLAGS='$(EXTRA_CFLAGS)' EXTRA_LDFLAGS='$(EXTRA_LDFLAGS)' SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT) -outcurrentdir ../example.i' TARGET='$(TARGET)' d_cpp; \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' DSRCS='$(DSRCS)' DFLAGS='$(DFLAGS)' d_compile clean: cd $(WORKING_DIR); \ - $(MAKE) -f $(TOP)/Makefile d_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' d_clean diff --git a/Examples/d/extend/Makefile b/Examples/d/extend/Makefile index eda18f13c..72edc17a5 100644 --- a/Examples/d/extend/Makefile +++ b/Examples/d/extend/Makefile @@ -15,13 +15,13 @@ DFLAGS = -ofrunme check: build cd $(WORKING_DIR); \ - $(MAKE) -f $(TOP)/Makefile d_run + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' d_run build: cd $(WORKING_DIR); \ - $(MAKE) -f $(TOP)/Makefile EXTRA_CFLAGS='$(EXTRA_CFLAGS)' EXTRA_LDFLAGS='$(EXTRA_LDFLAGS)' SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT) -outcurrentdir ../example.i' TARGET='$(TARGET)' d_cpp; \ - $(MAKE) -f $(TOP)/Makefile DSRCS='$(DSRCS)' DFLAGS='$(DFLAGS)' d_compile + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' EXTRA_CFLAGS='$(EXTRA_CFLAGS)' EXTRA_LDFLAGS='$(EXTRA_LDFLAGS)' SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT) -outcurrentdir ../example.i' TARGET='$(TARGET)' d_cpp; \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' DSRCS='$(DSRCS)' DFLAGS='$(DFLAGS)' d_compile clean: cd $(WORKING_DIR); \ - $(MAKE) -f $(TOP)/Makefile d_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' d_clean diff --git a/Examples/d/funcptr/Makefile b/Examples/d/funcptr/Makefile index 2ba893ca7..6554c3c73 100644 --- a/Examples/d/funcptr/Makefile +++ b/Examples/d/funcptr/Makefile @@ -15,13 +15,13 @@ DFLAGS = -ofrunme check: build cd $(WORKING_DIR); \ - $(MAKE) -f $(TOP)/Makefile d_run + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' d_run build: cd $(WORKING_DIR); \ - $(MAKE) -f $(TOP)/Makefile EXTRA_CFLAGS='$(EXTRA_CFLAGS)' EXTRA_LDFLAGS='$(EXTRA_LDFLAGS)' EXTRA_LDFLAGS='$(EXTRA_LDFLAGS)' SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT) -outcurrentdir ../example.i' TARGET='$(TARGET)' d; \ - $(MAKE) -f $(TOP)/Makefile DSRCS='$(DSRCS)' DFLAGS='$(DFLAGS)' d_compile + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' EXTRA_CFLAGS='$(EXTRA_CFLAGS)' EXTRA_LDFLAGS='$(EXTRA_LDFLAGS)' EXTRA_LDFLAGS='$(EXTRA_LDFLAGS)' SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT) -outcurrentdir ../example.i' TARGET='$(TARGET)' d; \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' DSRCS='$(DSRCS)' DFLAGS='$(DFLAGS)' d_compile clean: cd $(WORKING_DIR); \ - $(MAKE) -f $(TOP)/Makefile d_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' d_clean diff --git a/Examples/d/simple/Makefile b/Examples/d/simple/Makefile index a8808c9c5..f5eed3210 100644 --- a/Examples/d/simple/Makefile +++ b/Examples/d/simple/Makefile @@ -15,13 +15,13 @@ DFLAGS = -ofrunme check: build cd $(WORKING_DIR); \ - $(MAKE) -f $(TOP)/Makefile d_run + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' d_run build: cd $(WORKING_DIR); \ - $(MAKE) -f $(TOP)/Makefile EXTRA_CFLAGS='$(EXTRA_CFLAGS)' EXTRA_LDFLAGS='$(EXTRA_LDFLAGS)' SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT) -outcurrentdir ../example.i' TARGET='$(TARGET)' d; \ - $(MAKE) -f $(TOP)/Makefile DSRCS='$(DSRCS)' DFLAGS='$(DFLAGS)' d_compile + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' EXTRA_CFLAGS='$(EXTRA_CFLAGS)' EXTRA_LDFLAGS='$(EXTRA_LDFLAGS)' SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT) -outcurrentdir ../example.i' TARGET='$(TARGET)' d; \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' DSRCS='$(DSRCS)' DFLAGS='$(DFLAGS)' d_compile clean: cd $(WORKING_DIR); \ - $(MAKE) -f $(TOP)/Makefile d_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' d_clean diff --git a/Examples/d/variables/Makefile b/Examples/d/variables/Makefile index a8808c9c5..f5eed3210 100644 --- a/Examples/d/variables/Makefile +++ b/Examples/d/variables/Makefile @@ -15,13 +15,13 @@ DFLAGS = -ofrunme check: build cd $(WORKING_DIR); \ - $(MAKE) -f $(TOP)/Makefile d_run + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' d_run build: cd $(WORKING_DIR); \ - $(MAKE) -f $(TOP)/Makefile EXTRA_CFLAGS='$(EXTRA_CFLAGS)' EXTRA_LDFLAGS='$(EXTRA_LDFLAGS)' SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT) -outcurrentdir ../example.i' TARGET='$(TARGET)' d; \ - $(MAKE) -f $(TOP)/Makefile DSRCS='$(DSRCS)' DFLAGS='$(DFLAGS)' d_compile + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' EXTRA_CFLAGS='$(EXTRA_CFLAGS)' EXTRA_LDFLAGS='$(EXTRA_LDFLAGS)' SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT) -outcurrentdir ../example.i' TARGET='$(TARGET)' d; \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' DSRCS='$(DSRCS)' DFLAGS='$(DFLAGS)' d_compile clean: cd $(WORKING_DIR); \ - $(MAKE) -f $(TOP)/Makefile d_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' d_clean diff --git a/Examples/go/callback/Makefile b/Examples/go/callback/Makefile index 46a14b417..bf5275f14 100644 --- a/Examples/go/callback/Makefile +++ b/Examples/go/callback/Makefile @@ -6,11 +6,11 @@ INTERFACE = example.i SWIGOPT = check: build - $(MAKE) -f $(TOP)/Makefile CXXSRCS='$(CXXSRCS)' TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' go_run + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' CXXSRCS='$(CXXSRCS)' TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' go_run build: - $(MAKE) -f $(TOP)/Makefile CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ SWIGOPT='$(SWIGOPT)' TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' go_cpp clean: - $(MAKE) -f $(TOP)/Makefile INTERFACE='$(INTERFACE)' go_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' INTERFACE='$(INTERFACE)' go_clean diff --git a/Examples/go/class/Makefile b/Examples/go/class/Makefile index 72605caa5..de067cdd8 100644 --- a/Examples/go/class/Makefile +++ b/Examples/go/class/Makefile @@ -6,11 +6,11 @@ INTERFACE = example.i LIBS = -lm check: build - $(MAKE) -f $(TOP)/Makefile CXXSRCS='$(CXXSRCS)' TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' go_run + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' CXXSRCS='$(CXXSRCS)' TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' go_run build: - $(MAKE) -f $(TOP)/Makefile CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' go_cpp clean: - $(MAKE) -f $(TOP)/Makefile INTERFACE='$(INTERFACE)' go_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' INTERFACE='$(INTERFACE)' go_clean diff --git a/Examples/go/constants/Makefile b/Examples/go/constants/Makefile index 9fa967366..8fb07fd6b 100644 --- a/Examples/go/constants/Makefile +++ b/Examples/go/constants/Makefile @@ -6,11 +6,11 @@ INTERFACE = example.i SWIGOPT = check: build - $(MAKE) -f $(TOP)/Makefile CXXSRCS='$(CXXSRCS)' TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' go_run + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' CXXSRCS='$(CXXSRCS)' TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' go_run build: - $(MAKE) -f $(TOP)/Makefile CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ SWIGOPT='$(SWIGOPT)' TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' go clean: - $(MAKE) -f $(TOP)/Makefile INTERFACE='$(INTERFACE)' go_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' INTERFACE='$(INTERFACE)' go_clean diff --git a/Examples/go/enum/Makefile b/Examples/go/enum/Makefile index 1ceecc15c..2e2f1b2bd 100644 --- a/Examples/go/enum/Makefile +++ b/Examples/go/enum/Makefile @@ -6,11 +6,11 @@ INTERFACE = example.i SWIGOPT = check: build - $(MAKE) -f $(TOP)/Makefile CXXSRCS='$(CXXSRCS)' TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' go_run + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' CXXSRCS='$(CXXSRCS)' TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' go_run build: - $(MAKE) -f $(TOP)/Makefile CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ SWIGOPT='$(SWIGOPT)' TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' go_cpp clean: - $(MAKE) -f $(TOP)/Makefile INTERFACE='$(INTERFACE)' go_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' INTERFACE='$(INTERFACE)' go_clean diff --git a/Examples/go/extend/Makefile b/Examples/go/extend/Makefile index 67da89286..290694210 100644 --- a/Examples/go/extend/Makefile +++ b/Examples/go/extend/Makefile @@ -6,11 +6,11 @@ INTERFACE = example.i SWIGOPT = check: build - $(MAKE) -f $(TOP)/Makefile CXXSRCS='$(CXXSRCS)' TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' go_run + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' CXXSRCS='$(CXXSRCS)' TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' go_run build: - $(MAKE) -f $(TOP)/Makefile CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ SWIGOPT='$(SWIGOPT)' TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' go_cpp clean: - $(MAKE) -f $(TOP)/Makefile INTERFACE='$(INTERFACE)' go_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' INTERFACE='$(INTERFACE)' go_clean diff --git a/Examples/go/funcptr/Makefile b/Examples/go/funcptr/Makefile index 2c32c45fc..82031c9d5 100644 --- a/Examples/go/funcptr/Makefile +++ b/Examples/go/funcptr/Makefile @@ -6,11 +6,11 @@ INTERFACE = example.i SWIGOPT = check: build - $(MAKE) -f $(TOP)/Makefile SRCS='$(SRCS)' TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' go_run + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SRCS='$(SRCS)' TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' go_run build: - $(MAKE) -f $(TOP)/Makefile SRCS='$(SRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SRCS='$(SRCS)' SWIG='$(SWIG)' \ SWIGOPT='$(SWIGOPT)' TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' go clean: - $(MAKE) -f $(TOP)/Makefile INTERFACE='$(INTERFACE)' go_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' INTERFACE='$(INTERFACE)' go_clean diff --git a/Examples/go/multimap/Makefile b/Examples/go/multimap/Makefile index 0c5ec395f..4d739162b 100644 --- a/Examples/go/multimap/Makefile +++ b/Examples/go/multimap/Makefile @@ -6,11 +6,11 @@ INTERFACE = example.i SWIGOPT = check: build - $(MAKE) -f $(TOP)/Makefile SRCS='$(SRCS)' TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' go_run + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SRCS='$(SRCS)' TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' go_run build: - $(MAKE) -f $(TOP)/Makefile SRCS='$(SRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SRCS='$(SRCS)' SWIG='$(SWIG)' \ SWIGOPT='$(SWIGOPT)' TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' go clean: - $(MAKE) -f $(TOP)/Makefile INTERFACE='$(INTERFACE)' go_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' INTERFACE='$(INTERFACE)' go_clean diff --git a/Examples/go/pointer/Makefile b/Examples/go/pointer/Makefile index 12e94f939..9f1f3fda0 100644 --- a/Examples/go/pointer/Makefile +++ b/Examples/go/pointer/Makefile @@ -6,11 +6,11 @@ INTERFACE = example.i SWIGOPT = check: build - $(MAKE) -f $(TOP)/Makefile SRCS='$(SRCS)' TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' go_run + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SRCS='$(SRCS)' TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' go_run build: - $(MAKE) -f $(TOP)/Makefile SRCS='$(SRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SRCS='$(SRCS)' SWIG='$(SWIG)' \ SWIGOPT='$(SWIGOPT)' TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' go clean: - $(MAKE) -f $(TOP)/Makefile INTERFACE='$(INTERFACE)' go_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' INTERFACE='$(INTERFACE)' go_clean diff --git a/Examples/go/reference/Makefile b/Examples/go/reference/Makefile index 41a944239..e136f6fae 100644 --- a/Examples/go/reference/Makefile +++ b/Examples/go/reference/Makefile @@ -6,11 +6,11 @@ INTERFACE = example.i SWIGOPT = check: build - $(MAKE) -f $(TOP)/Makefile CXXSRCS='$(CXXSRCS)' TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' go_run + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' CXXSRCS='$(CXXSRCS)' TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' go_run build: - $(MAKE) -f $(TOP)/Makefile CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ SWIGOPT='$(SWIGOPT)' TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' go_cpp clean: - $(MAKE) -f $(TOP)/Makefile INTERFACE='$(INTERFACE)' go_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' INTERFACE='$(INTERFACE)' go_clean diff --git a/Examples/go/simple/Makefile b/Examples/go/simple/Makefile index 907da8821..5bc16549d 100644 --- a/Examples/go/simple/Makefile +++ b/Examples/go/simple/Makefile @@ -5,11 +5,11 @@ TARGET = example INTERFACE = example.i check: build - $(MAKE) -f $(TOP)/Makefile SRCS='$(SRCS)' TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' go_run + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SRCS='$(SRCS)' TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' go_run build: - $(MAKE) -f $(TOP)/Makefile SRCS='$(SRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SRCS='$(SRCS)' SWIG='$(SWIG)' \ TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' go clean: - $(MAKE) -f $(TOP)/Makefile INTERFACE='$(INTERFACE)' go_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' INTERFACE='$(INTERFACE)' go_clean diff --git a/Examples/go/template/Makefile b/Examples/go/template/Makefile index 51cd97a80..a1d674836 100644 --- a/Examples/go/template/Makefile +++ b/Examples/go/template/Makefile @@ -6,11 +6,11 @@ INTERFACE = example.i SWIGOPT = check: build - $(MAKE) -f $(TOP)/Makefile CXXSRCS='$(CXXSRCS)' TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' go_run + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' CXXSRCS='$(CXXSRCS)' TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' go_run build: - $(MAKE) -f $(TOP)/Makefile CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ SWIGOPT='$(SWIGOPT)' TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' go_cpp clean: - $(MAKE) -f $(TOP)/Makefile INTERFACE='$(INTERFACE)' go_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' INTERFACE='$(INTERFACE)' go_clean diff --git a/Examples/go/variables/Makefile b/Examples/go/variables/Makefile index 1f144929c..d0da605e0 100644 --- a/Examples/go/variables/Makefile +++ b/Examples/go/variables/Makefile @@ -6,11 +6,11 @@ INTERFACE = example.i SWIGOPT = check: build - $(MAKE) -f $(TOP)/Makefile SRCS='$(SRCS)' TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' go_run + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SRCS='$(SRCS)' TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' go_run build: - $(MAKE) -f $(TOP)/Makefile SRCS='$(SRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SRCS='$(SRCS)' SWIG='$(SWIG)' \ SWIGOPT='$(SWIGOPT)' TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' go clean: - $(MAKE) -f $(TOP)/Makefile INTERFACE='$(INTERFACE)' go_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' INTERFACE='$(INTERFACE)' go_clean diff --git a/Examples/guile/class/Makefile b/Examples/guile/class/Makefile index 8de4f292b..48426a8fb 100644 --- a/Examples/guile/class/Makefile +++ b/Examples/guile/class/Makefile @@ -5,15 +5,15 @@ TARGET = example INTERFACE = example.i check: build - $(MAKE) -f $(TOP)/Makefile guile_run + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' guile_run build: - $(MAKE) -f $(TOP)/Makefile CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' guile_cpp static: - $(MAKE) -f $(TOP)/Makefile CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ TARGET='my-guile' INTERFACE='$(INTERFACE)' guile_static_cpp clean: - $(MAKE) -f $(TOP)/Makefile TARGET='$(TARGET)' guile_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' TARGET='$(TARGET)' guile_clean diff --git a/Examples/guile/constants/Makefile b/Examples/guile/constants/Makefile index 2b6965e9e..d3f58ebdc 100644 --- a/Examples/guile/constants/Makefile +++ b/Examples/guile/constants/Makefile @@ -5,11 +5,11 @@ TARGET = my-guile INTERFACE = example.i check: build - $(MAKE) -f $(TOP)/Makefile TARGET='$(TARGET)' guile_augmented_run + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' TARGET='$(TARGET)' guile_augmented_run build: - $(MAKE) -f $(TOP)/Makefile SRCS='$(SRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SRCS='$(SRCS)' SWIG='$(SWIG)' \ TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' guile_augmented clean: - $(MAKE) -f $(TOP)/Makefile TARGET='$(TARGET)' guile_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' TARGET='$(TARGET)' guile_clean diff --git a/Examples/guile/matrix/Makefile b/Examples/guile/matrix/Makefile index a32210e65..53638c867 100644 --- a/Examples/guile/matrix/Makefile +++ b/Examples/guile/matrix/Makefile @@ -5,11 +5,11 @@ TARGET = matrix INTERFACE = example.i check: build - $(MAKE) -f $(TOP)/Makefile TARGET='$(TARGET)' GUILE_RUNOPTIONS='-e do-test' guile_augmented_run + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' TARGET='$(TARGET)' GUILE_RUNOPTIONS='-e do-test' guile_augmented_run build: - $(MAKE) -f $(TOP)/Makefile SRCS='$(SRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SRCS='$(SRCS)' SWIG='$(SWIG)' \ TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' LIBS='-lm' guile_augmented clean: - $(MAKE) -f $(TOP)/Makefile TARGET='$(TARGET)' guile_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' TARGET='$(TARGET)' guile_clean diff --git a/Examples/guile/multimap/Makefile b/Examples/guile/multimap/Makefile index 4ca82a3d3..b8f5e9b5a 100644 --- a/Examples/guile/multimap/Makefile +++ b/Examples/guile/multimap/Makefile @@ -5,15 +5,15 @@ TARGET = example INTERFACE = example.i check: build - $(MAKE) -f $(TOP)/Makefile guile_run + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' guile_run build: - $(MAKE) -f $(TOP)/Makefile SRCS='$(SRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SRCS='$(SRCS)' SWIG='$(SWIG)' \ TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' guile static: - $(MAKE) -f $(TOP)/Makefile SRCS='$(SRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SRCS='$(SRCS)' SWIG='$(SWIG)' \ TARGET='my-guile' INTERFACE='$(INTERFACE)' guile_static clean: - $(MAKE) -f $(TOP)/Makefile TARGET='$(TARGET)' guile_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' TARGET='$(TARGET)' guile_clean diff --git a/Examples/guile/multivalue/Makefile b/Examples/guile/multivalue/Makefile index 4ca82a3d3..b8f5e9b5a 100644 --- a/Examples/guile/multivalue/Makefile +++ b/Examples/guile/multivalue/Makefile @@ -5,15 +5,15 @@ TARGET = example INTERFACE = example.i check: build - $(MAKE) -f $(TOP)/Makefile guile_run + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' guile_run build: - $(MAKE) -f $(TOP)/Makefile SRCS='$(SRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SRCS='$(SRCS)' SWIG='$(SWIG)' \ TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' guile static: - $(MAKE) -f $(TOP)/Makefile SRCS='$(SRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SRCS='$(SRCS)' SWIG='$(SWIG)' \ TARGET='my-guile' INTERFACE='$(INTERFACE)' guile_static clean: - $(MAKE) -f $(TOP)/Makefile TARGET='$(TARGET)' guile_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' TARGET='$(TARGET)' guile_clean diff --git a/Examples/guile/port/Makefile b/Examples/guile/port/Makefile index d6ec0ac24..95a3a479f 100644 --- a/Examples/guile/port/Makefile +++ b/Examples/guile/port/Makefile @@ -5,12 +5,12 @@ TARGET = port INTERFACE = example.i check: build - $(MAKE) -f $(TOP)/Makefile TARGET='$(TARGET)' guile_augmented_run + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' TARGET='$(TARGET)' guile_augmented_run build: - $(MAKE) -f $(TOP)/Makefile SRCS='$(SRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SRCS='$(SRCS)' SWIG='$(SWIG)' \ TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' guile_augmented clean: - $(MAKE) -f $(TOP)/Makefile TARGET='$(TARGET)' guile_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' TARGET='$(TARGET)' guile_clean rm -f test.out diff --git a/Examples/guile/simple/Makefile b/Examples/guile/simple/Makefile index da4eb9015..517e41c64 100644 --- a/Examples/guile/simple/Makefile +++ b/Examples/guile/simple/Makefile @@ -5,11 +5,11 @@ TARGET = my-guile INTERFACE = example.i check: build - $(MAKE) -f $(TOP)/Makefile TARGET='$(TARGET)' guile_augmented_run + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' TARGET='$(TARGET)' guile_augmented_run build: - $(MAKE) -f $(TOP)/Makefile SRCS='$(SRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SRCS='$(SRCS)' SWIG='$(SWIG)' \ TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' guile_augmented clean: - $(MAKE) -f $(TOP)/Makefile TARGET='$(TARGET)' guile_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' TARGET='$(TARGET)' guile_clean diff --git a/Examples/guile/std_vector/Makefile b/Examples/guile/std_vector/Makefile index fd7a8439a..d7f5de217 100644 --- a/Examples/guile/std_vector/Makefile +++ b/Examples/guile/std_vector/Makefile @@ -5,15 +5,15 @@ TARGET = example INTERFACE = example.i check: build - $(MAKE) -f $(TOP)/Makefile guile_run + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' guile_run build: - $(MAKE) -f $(TOP)/Makefile CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' guile_cpp static: - $(MAKE) -f $(TOP)/Makefile CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ TARGET='my-guile' INTERFACE='$(INTERFACE)' guile_static_cpp clean: - $(MAKE) -f $(TOP)/Makefile TARGET='$(TARGET)' guile_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' TARGET='$(TARGET)' guile_clean diff --git a/Examples/java/callback/Makefile b/Examples/java/callback/Makefile index 8f274e7cb..13cfd1708 100644 --- a/Examples/java/callback/Makefile +++ b/Examples/java/callback/Makefile @@ -7,12 +7,12 @@ SWIGOPT = JAVASRCS = *.java check: build - $(MAKE) -f $(TOP)/Makefile java_run + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' java_run build: - $(MAKE) -f $(TOP)/Makefile CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ SWIGOPT='$(SWIGOPT)' TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' java_cpp - $(MAKE) -f $(TOP)/Makefile JAVASRCS='$(JAVASRCS)' JAVAFLAGS='$(JAVAFLAGS)' java_compile + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' JAVASRCS='$(JAVASRCS)' JAVAFLAGS='$(JAVAFLAGS)' java_compile clean: - $(MAKE) -f $(TOP)/Makefile java_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' java_clean diff --git a/Examples/java/class/Makefile b/Examples/java/class/Makefile index 8f274e7cb..13cfd1708 100644 --- a/Examples/java/class/Makefile +++ b/Examples/java/class/Makefile @@ -7,12 +7,12 @@ SWIGOPT = JAVASRCS = *.java check: build - $(MAKE) -f $(TOP)/Makefile java_run + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' java_run build: - $(MAKE) -f $(TOP)/Makefile CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ SWIGOPT='$(SWIGOPT)' TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' java_cpp - $(MAKE) -f $(TOP)/Makefile JAVASRCS='$(JAVASRCS)' JAVAFLAGS='$(JAVAFLAGS)' java_compile + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' JAVASRCS='$(JAVASRCS)' JAVAFLAGS='$(JAVAFLAGS)' java_compile clean: - $(MAKE) -f $(TOP)/Makefile java_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' java_clean diff --git a/Examples/java/constants/Makefile b/Examples/java/constants/Makefile index 4e21fc4cd..637ce0ead 100644 --- a/Examples/java/constants/Makefile +++ b/Examples/java/constants/Makefile @@ -7,12 +7,12 @@ SWIGOPT = JAVASRCS = *.java check: build - $(MAKE) -f $(TOP)/Makefile java_run + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' java_run build: - $(MAKE) -f $(TOP)/Makefile CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ SWIGOPT='$(SWIGOPT)' TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' java_cpp - $(MAKE) -f $(TOP)/Makefile JAVASRCS='$(JAVASRCS)' JAVAFLAGS='$(JAVAFLAGS)' java_compile + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' JAVASRCS='$(JAVASRCS)' JAVAFLAGS='$(JAVAFLAGS)' java_compile clean: - $(MAKE) -f $(TOP)/Makefile java_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' java_clean diff --git a/Examples/java/enum/Makefile b/Examples/java/enum/Makefile index 8f274e7cb..13cfd1708 100644 --- a/Examples/java/enum/Makefile +++ b/Examples/java/enum/Makefile @@ -7,12 +7,12 @@ SWIGOPT = JAVASRCS = *.java check: build - $(MAKE) -f $(TOP)/Makefile java_run + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' java_run build: - $(MAKE) -f $(TOP)/Makefile CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ SWIGOPT='$(SWIGOPT)' TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' java_cpp - $(MAKE) -f $(TOP)/Makefile JAVASRCS='$(JAVASRCS)' JAVAFLAGS='$(JAVAFLAGS)' java_compile + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' JAVASRCS='$(JAVASRCS)' JAVAFLAGS='$(JAVAFLAGS)' java_compile clean: - $(MAKE) -f $(TOP)/Makefile java_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' java_clean diff --git a/Examples/java/extend/Makefile b/Examples/java/extend/Makefile index 8f274e7cb..13cfd1708 100644 --- a/Examples/java/extend/Makefile +++ b/Examples/java/extend/Makefile @@ -7,12 +7,12 @@ SWIGOPT = JAVASRCS = *.java check: build - $(MAKE) -f $(TOP)/Makefile java_run + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' java_run build: - $(MAKE) -f $(TOP)/Makefile CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ SWIGOPT='$(SWIGOPT)' TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' java_cpp - $(MAKE) -f $(TOP)/Makefile JAVASRCS='$(JAVASRCS)' JAVAFLAGS='$(JAVAFLAGS)' java_compile + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' JAVASRCS='$(JAVASRCS)' JAVAFLAGS='$(JAVAFLAGS)' java_compile clean: - $(MAKE) -f $(TOP)/Makefile java_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' java_clean diff --git a/Examples/java/funcptr/Makefile b/Examples/java/funcptr/Makefile index e9e29f3a3..c0b1927ca 100644 --- a/Examples/java/funcptr/Makefile +++ b/Examples/java/funcptr/Makefile @@ -7,12 +7,12 @@ SWIGOPT = JAVASRCS = *.java check: build - $(MAKE) -f $(TOP)/Makefile java_run + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' java_run build: - $(MAKE) -f $(TOP)/Makefile SRCS='$(SRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SRCS='$(SRCS)' SWIG='$(SWIG)' \ SWIGOPT='$(SWIGOPT)' TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' java - $(MAKE) -f $(TOP)/Makefile JAVASRCS='$(JAVASRCS)' JAVAFLAGS='$(JAVAFLAGS)' java_compile + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' JAVASRCS='$(JAVASRCS)' JAVAFLAGS='$(JAVAFLAGS)' java_compile clean: - $(MAKE) -f $(TOP)/Makefile java_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' java_clean diff --git a/Examples/java/multimap/Makefile b/Examples/java/multimap/Makefile index e9e29f3a3..c0b1927ca 100644 --- a/Examples/java/multimap/Makefile +++ b/Examples/java/multimap/Makefile @@ -7,12 +7,12 @@ SWIGOPT = JAVASRCS = *.java check: build - $(MAKE) -f $(TOP)/Makefile java_run + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' java_run build: - $(MAKE) -f $(TOP)/Makefile SRCS='$(SRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SRCS='$(SRCS)' SWIG='$(SWIG)' \ SWIGOPT='$(SWIGOPT)' TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' java - $(MAKE) -f $(TOP)/Makefile JAVASRCS='$(JAVASRCS)' JAVAFLAGS='$(JAVAFLAGS)' java_compile + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' JAVASRCS='$(JAVASRCS)' JAVAFLAGS='$(JAVAFLAGS)' java_compile clean: - $(MAKE) -f $(TOP)/Makefile java_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' java_clean diff --git a/Examples/java/native/Makefile b/Examples/java/native/Makefile index e858cbe77..fa67e48a4 100644 --- a/Examples/java/native/Makefile +++ b/Examples/java/native/Makefile @@ -7,12 +7,12 @@ SWIGOPT = JAVASRCS = *.java check: build - $(MAKE) -f $(TOP)/Makefile java_run + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' java_run build: - $(MAKE) -f $(TOP)/Makefile SRCS='$(SRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SRCS='$(SRCS)' SWIG='$(SWIG)' \ SWIGOPT='$(SWIGOPT)' TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' java - $(MAKE) -f $(TOP)/Makefile JAVASRCS='$(JAVASRCS)' JAVAFLAGS='$(JAVAFLAGS)' java_compile + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' JAVASRCS='$(JAVASRCS)' JAVAFLAGS='$(JAVAFLAGS)' java_compile clean: - $(MAKE) -f $(TOP)/Makefile java_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' java_clean diff --git a/Examples/java/nested/Makefile b/Examples/java/nested/Makefile index 8f274e7cb..13cfd1708 100644 --- a/Examples/java/nested/Makefile +++ b/Examples/java/nested/Makefile @@ -7,12 +7,12 @@ SWIGOPT = JAVASRCS = *.java check: build - $(MAKE) -f $(TOP)/Makefile java_run + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' java_run build: - $(MAKE) -f $(TOP)/Makefile CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ SWIGOPT='$(SWIGOPT)' TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' java_cpp - $(MAKE) -f $(TOP)/Makefile JAVASRCS='$(JAVASRCS)' JAVAFLAGS='$(JAVAFLAGS)' java_compile + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' JAVASRCS='$(JAVASRCS)' JAVAFLAGS='$(JAVAFLAGS)' java_compile clean: - $(MAKE) -f $(TOP)/Makefile java_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' java_clean diff --git a/Examples/java/pointer/Makefile b/Examples/java/pointer/Makefile index e9e29f3a3..c0b1927ca 100644 --- a/Examples/java/pointer/Makefile +++ b/Examples/java/pointer/Makefile @@ -7,12 +7,12 @@ SWIGOPT = JAVASRCS = *.java check: build - $(MAKE) -f $(TOP)/Makefile java_run + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' java_run build: - $(MAKE) -f $(TOP)/Makefile SRCS='$(SRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SRCS='$(SRCS)' SWIG='$(SWIG)' \ SWIGOPT='$(SWIGOPT)' TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' java - $(MAKE) -f $(TOP)/Makefile JAVASRCS='$(JAVASRCS)' JAVAFLAGS='$(JAVAFLAGS)' java_compile + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' JAVASRCS='$(JAVASRCS)' JAVAFLAGS='$(JAVAFLAGS)' java_compile clean: - $(MAKE) -f $(TOP)/Makefile java_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' java_clean diff --git a/Examples/java/reference/Makefile b/Examples/java/reference/Makefile index 8f274e7cb..13cfd1708 100644 --- a/Examples/java/reference/Makefile +++ b/Examples/java/reference/Makefile @@ -7,12 +7,12 @@ SWIGOPT = JAVASRCS = *.java check: build - $(MAKE) -f $(TOP)/Makefile java_run + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' java_run build: - $(MAKE) -f $(TOP)/Makefile CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ SWIGOPT='$(SWIGOPT)' TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' java_cpp - $(MAKE) -f $(TOP)/Makefile JAVASRCS='$(JAVASRCS)' JAVAFLAGS='$(JAVAFLAGS)' java_compile + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' JAVASRCS='$(JAVASRCS)' JAVAFLAGS='$(JAVAFLAGS)' java_compile clean: - $(MAKE) -f $(TOP)/Makefile java_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' java_clean diff --git a/Examples/java/simple/Makefile b/Examples/java/simple/Makefile index e9e29f3a3..c0b1927ca 100644 --- a/Examples/java/simple/Makefile +++ b/Examples/java/simple/Makefile @@ -7,12 +7,12 @@ SWIGOPT = JAVASRCS = *.java check: build - $(MAKE) -f $(TOP)/Makefile java_run + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' java_run build: - $(MAKE) -f $(TOP)/Makefile SRCS='$(SRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SRCS='$(SRCS)' SWIG='$(SWIG)' \ SWIGOPT='$(SWIGOPT)' TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' java - $(MAKE) -f $(TOP)/Makefile JAVASRCS='$(JAVASRCS)' JAVAFLAGS='$(JAVAFLAGS)' java_compile + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' JAVASRCS='$(JAVASRCS)' JAVAFLAGS='$(JAVAFLAGS)' java_compile clean: - $(MAKE) -f $(TOP)/Makefile java_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' java_clean diff --git a/Examples/java/template/Makefile b/Examples/java/template/Makefile index 4e21fc4cd..637ce0ead 100644 --- a/Examples/java/template/Makefile +++ b/Examples/java/template/Makefile @@ -7,12 +7,12 @@ SWIGOPT = JAVASRCS = *.java check: build - $(MAKE) -f $(TOP)/Makefile java_run + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' java_run build: - $(MAKE) -f $(TOP)/Makefile CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ SWIGOPT='$(SWIGOPT)' TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' java_cpp - $(MAKE) -f $(TOP)/Makefile JAVASRCS='$(JAVASRCS)' JAVAFLAGS='$(JAVAFLAGS)' java_compile + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' JAVASRCS='$(JAVASRCS)' JAVAFLAGS='$(JAVAFLAGS)' java_compile clean: - $(MAKE) -f $(TOP)/Makefile java_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' java_clean diff --git a/Examples/java/typemap/Makefile b/Examples/java/typemap/Makefile index e858cbe77..fa67e48a4 100644 --- a/Examples/java/typemap/Makefile +++ b/Examples/java/typemap/Makefile @@ -7,12 +7,12 @@ SWIGOPT = JAVASRCS = *.java check: build - $(MAKE) -f $(TOP)/Makefile java_run + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' java_run build: - $(MAKE) -f $(TOP)/Makefile SRCS='$(SRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SRCS='$(SRCS)' SWIG='$(SWIG)' \ SWIGOPT='$(SWIGOPT)' TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' java - $(MAKE) -f $(TOP)/Makefile JAVASRCS='$(JAVASRCS)' JAVAFLAGS='$(JAVAFLAGS)' java_compile + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' JAVASRCS='$(JAVASRCS)' JAVAFLAGS='$(JAVAFLAGS)' java_compile clean: - $(MAKE) -f $(TOP)/Makefile java_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' java_clean diff --git a/Examples/java/variables/Makefile b/Examples/java/variables/Makefile index e9e29f3a3..c0b1927ca 100644 --- a/Examples/java/variables/Makefile +++ b/Examples/java/variables/Makefile @@ -7,12 +7,12 @@ SWIGOPT = JAVASRCS = *.java check: build - $(MAKE) -f $(TOP)/Makefile java_run + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' java_run build: - $(MAKE) -f $(TOP)/Makefile SRCS='$(SRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SRCS='$(SRCS)' SWIG='$(SWIG)' \ SWIGOPT='$(SWIGOPT)' TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' java - $(MAKE) -f $(TOP)/Makefile JAVASRCS='$(JAVASRCS)' JAVAFLAGS='$(JAVAFLAGS)' java_compile + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' JAVASRCS='$(JAVASRCS)' JAVAFLAGS='$(JAVAFLAGS)' java_compile clean: - $(MAKE) -f $(TOP)/Makefile java_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' java_clean diff --git a/Examples/javascript/class/Makefile b/Examples/javascript/class/Makefile index 31846faae..54a8f7b03 100644 --- a/Examples/javascript/class/Makefile +++ b/Examples/javascript/class/Makefile @@ -1,3 +1,3 @@ SRCS = example.cxx -include ../example.mk +include $(SRCDIR)../example.mk diff --git a/Examples/javascript/class/binding.gyp b/Examples/javascript/class/binding.gyp deleted file mode 100644 index 54eebfaa0..000000000 --- a/Examples/javascript/class/binding.gyp +++ /dev/null @@ -1,8 +0,0 @@ -{ - "targets": [ - { - "target_name": "example", - "sources": [ "example.cxx", "example_wrap.cxx" ] - } - ] -} diff --git a/Examples/javascript/class/binding.gyp.in b/Examples/javascript/class/binding.gyp.in new file mode 100644 index 000000000..c56a650e9 --- /dev/null +++ b/Examples/javascript/class/binding.gyp.in @@ -0,0 +1,9 @@ +{ + "targets": [ + { + "target_name": "example", + "sources": [ "$srcdir/example.cxx", "example_wrap.cxx" ], + "include_dirs": ["$srcdir"] + } + ] +} diff --git a/Examples/javascript/class/example.js b/Examples/javascript/class/example.js index 79cd3913f..2e7f83a06 100644 --- a/Examples/javascript/class/example.js +++ b/Examples/javascript/class/example.js @@ -1 +1 @@ -module.exports = require("./build/Release/example"); +module.exports = require("build/Release/example"); diff --git a/Examples/javascript/class/runme.js b/Examples/javascript/class/runme.js index e1d5d9797..6a77b8d8e 100644 --- a/Examples/javascript/class/runme.js +++ b/Examples/javascript/class/runme.js @@ -1,4 +1,4 @@ -var example = require("./example"); +var example = require("example"); // ----- Object creation ----- diff --git a/Examples/javascript/constant/Makefile b/Examples/javascript/constant/Makefile index ea04c7df8..0402f8d09 100644 --- a/Examples/javascript/constant/Makefile +++ b/Examples/javascript/constant/Makefile @@ -1,3 +1,3 @@ SRCS = -include ../example.mk +include $(SRCDIR)../example.mk diff --git a/Examples/javascript/constant/binding.gyp b/Examples/javascript/constant/binding.gyp deleted file mode 100644 index 69af46b22..000000000 --- a/Examples/javascript/constant/binding.gyp +++ /dev/null @@ -1,8 +0,0 @@ -{ - "targets": [ - { - "target_name": "example", - "sources": [ "example_wrap.cxx" ] - } - ] -} diff --git a/Examples/javascript/constant/binding.gyp.in b/Examples/javascript/constant/binding.gyp.in new file mode 100644 index 000000000..59779aef4 --- /dev/null +++ b/Examples/javascript/constant/binding.gyp.in @@ -0,0 +1,9 @@ +{ + "targets": [ + { + "target_name": "example", + "sources": [ "example_wrap.cxx" ], + "include_dirs": ["$srcdir"] + } + ] +} diff --git a/Examples/javascript/constant/example.js b/Examples/javascript/constant/example.js index 79cd3913f..2e7f83a06 100644 --- a/Examples/javascript/constant/example.js +++ b/Examples/javascript/constant/example.js @@ -1 +1 @@ -module.exports = require("./build/Release/example"); +module.exports = require("build/Release/example"); diff --git a/Examples/javascript/constant/runme.js b/Examples/javascript/constant/runme.js index f4b55881e..f29d1a850 100644 --- a/Examples/javascript/constant/runme.js +++ b/Examples/javascript/constant/runme.js @@ -1,4 +1,4 @@ -var example = require("./example"); +var example = require("example"); console.log("ICONST = " + example.ICONST + " (should be 42)"); console.log("FCONST = " + example.FCONST + " (should be 2.1828)"); diff --git a/Examples/javascript/enum/Makefile b/Examples/javascript/enum/Makefile index 31846faae..54a8f7b03 100644 --- a/Examples/javascript/enum/Makefile +++ b/Examples/javascript/enum/Makefile @@ -1,3 +1,3 @@ SRCS = example.cxx -include ../example.mk +include $(SRCDIR)../example.mk diff --git a/Examples/javascript/enum/binding.gyp b/Examples/javascript/enum/binding.gyp deleted file mode 100644 index 54eebfaa0..000000000 --- a/Examples/javascript/enum/binding.gyp +++ /dev/null @@ -1,8 +0,0 @@ -{ - "targets": [ - { - "target_name": "example", - "sources": [ "example.cxx", "example_wrap.cxx" ] - } - ] -} diff --git a/Examples/javascript/enum/binding.gyp.in b/Examples/javascript/enum/binding.gyp.in new file mode 100644 index 000000000..c56a650e9 --- /dev/null +++ b/Examples/javascript/enum/binding.gyp.in @@ -0,0 +1,9 @@ +{ + "targets": [ + { + "target_name": "example", + "sources": [ "$srcdir/example.cxx", "example_wrap.cxx" ], + "include_dirs": ["$srcdir"] + } + ] +} diff --git a/Examples/javascript/enum/example.js b/Examples/javascript/enum/example.js index 79cd3913f..2e7f83a06 100644 --- a/Examples/javascript/enum/example.js +++ b/Examples/javascript/enum/example.js @@ -1 +1 @@ -module.exports = require("./build/Release/example"); +module.exports = require("build/Release/example"); diff --git a/Examples/javascript/enum/runme.js b/Examples/javascript/enum/runme.js index d4e89e8c8..851d43c4b 100644 --- a/Examples/javascript/enum/runme.js +++ b/Examples/javascript/enum/runme.js @@ -1,4 +1,4 @@ -var example = require("./example"); +var example = require("example"); // ----- Object creation ----- diff --git a/Examples/javascript/example.mk b/Examples/javascript/example.mk index 274eff1a3..5a335bba4 100644 --- a/Examples/javascript/example.mk +++ b/Examples/javascript/example.mk @@ -15,13 +15,13 @@ INTERFACE = example.i SWIGOPT=-$(JSENGINE) check: build - $(MAKE) -f $(EXAMPLES_TOP)/Makefile JSENGINE='$(JSENGINE)' TARGET='$(TARGET)' javascript_run + $(MAKE) -f $(EXAMPLES_TOP)/Makefile SRCDIR='$(SRCDIR)' JSENGINE='$(JSENGINE)' TARGET='$(TARGET)' javascript_run build: - $(MAKE) -f $(EXAMPLES_TOP)/Makefile CXXSRCS='$(SRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(EXAMPLES_TOP)/Makefile SRCDIR='$(SRCDIR)' CXXSRCS='$(SRCS)' SWIG='$(SWIG)' \ SWIGOPT='$(SWIGOPT)' TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' javascript_wrapper_cpp - $(MAKE) -f $(EXAMPLES_TOP)/Makefile CXXSRCS='$(SRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(EXAMPLES_TOP)/Makefile SRCDIR='$(SRCDIR)' CXXSRCS='$(SRCS)' SWIG='$(SWIG)' \ SWIGOPT='$(SWIGOPT)' TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' JSENGINE='$(JSENGINE)' javascript_build_cpp clean: - $(MAKE) -f $(EXAMPLES_TOP)/Makefile javascript_clean + $(MAKE) -f $(EXAMPLES_TOP)/Makefile SRCDIR='$(SRCDIR)' javascript_clean diff --git a/Examples/javascript/exception/Makefile b/Examples/javascript/exception/Makefile index 31846faae..54a8f7b03 100644 --- a/Examples/javascript/exception/Makefile +++ b/Examples/javascript/exception/Makefile @@ -1,3 +1,3 @@ SRCS = example.cxx -include ../example.mk +include $(SRCDIR)../example.mk diff --git a/Examples/javascript/exception/binding.gyp b/Examples/javascript/exception/binding.gyp deleted file mode 100644 index 2be0a17a2..000000000 --- a/Examples/javascript/exception/binding.gyp +++ /dev/null @@ -1,29 +0,0 @@ -{ - "targets": [ - { - "target_name": "example", - "sources": [ "example.cxx", "example_wrap.cxx" ], - 'defines': [ - 'BUILDING_NODE_EXTENSION=1', - ], - 'conditions': [ - ['OS=="mac"', - { - 'xcode_settings': { - 'GCC_ENABLE_CPP_RTTI': 'YES', - 'GCC_ENABLE_CPP_EXCEPTIONS' : 'YES' - } - } - ], - ['OS=="linux" or OS=="freebsd" or OS=="openbsd" or OS=="solaris"', - { - 'cflags': [ "-Wno-unused-variable", "-Wno-unused-but-set-variable", "-Wno-unused-but-set-parameter"], - 'cflags_cc': [ "-Wno-unused-variable", "-Wno-unused-but-set-variable", "-Wno-unused-but-set-parameter"], - 'cflags!': [ '-fno-exceptions' ], - 'cflags_cc!': [ '-fno-exceptions', '-fno-rtti' ] - } - ] - ] - } - ] -} diff --git a/Examples/javascript/exception/binding.gyp.in b/Examples/javascript/exception/binding.gyp.in new file mode 100644 index 000000000..577a5c2e3 --- /dev/null +++ b/Examples/javascript/exception/binding.gyp.in @@ -0,0 +1,30 @@ +{ + "targets": [ + { + "target_name": "example", + "sources": [ "$srcdir/example.cxx", "example_wrap.cxx" ], + "include_dirs": ["$srcdir"], + 'defines': [ + 'BUILDING_NODE_EXTENSION=1', + ], + 'conditions': [ + ['OS=="mac"', + { + 'xcode_settings': { + 'GCC_ENABLE_CPP_RTTI': 'YES', + 'GCC_ENABLE_CPP_EXCEPTIONS' : 'YES' + } + } + ], + ['OS=="linux" or OS=="freebsd" or OS=="openbsd" or OS=="solaris"', + { + 'cflags': [ "-Wno-unused-variable", "-Wno-unused-but-set-variable", "-Wno-unused-but-set-parameter"], + 'cflags_cc': [ "-Wno-unused-variable", "-Wno-unused-but-set-variable", "-Wno-unused-but-set-parameter"], + 'cflags!': [ '-fno-exceptions' ], + 'cflags_cc!': [ '-fno-exceptions', '-fno-rtti' ] + } + ] + ] + } + ] +} diff --git a/Examples/javascript/exception/example.js b/Examples/javascript/exception/example.js index 79cd3913f..2e7f83a06 100644 --- a/Examples/javascript/exception/example.js +++ b/Examples/javascript/exception/example.js @@ -1 +1 @@ -module.exports = require("./build/Release/example"); +module.exports = require("build/Release/example"); diff --git a/Examples/javascript/exception/runme.js b/Examples/javascript/exception/runme.js index 977f51ebc..43ce66d6d 100644 --- a/Examples/javascript/exception/runme.js +++ b/Examples/javascript/exception/runme.js @@ -1,4 +1,4 @@ -var example = require("./example"); +var example = require("example"); console.log("Trying to catch some exceptions."); t = new example.Test(); diff --git a/Examples/javascript/functor/Makefile b/Examples/javascript/functor/Makefile index 31846faae..54a8f7b03 100644 --- a/Examples/javascript/functor/Makefile +++ b/Examples/javascript/functor/Makefile @@ -1,3 +1,3 @@ SRCS = example.cxx -include ../example.mk +include $(SRCDIR)../example.mk diff --git a/Examples/javascript/functor/binding.gyp b/Examples/javascript/functor/binding.gyp deleted file mode 100644 index 54eebfaa0..000000000 --- a/Examples/javascript/functor/binding.gyp +++ /dev/null @@ -1,8 +0,0 @@ -{ - "targets": [ - { - "target_name": "example", - "sources": [ "example.cxx", "example_wrap.cxx" ] - } - ] -} diff --git a/Examples/javascript/functor/binding.gyp.in b/Examples/javascript/functor/binding.gyp.in new file mode 100644 index 000000000..c56a650e9 --- /dev/null +++ b/Examples/javascript/functor/binding.gyp.in @@ -0,0 +1,9 @@ +{ + "targets": [ + { + "target_name": "example", + "sources": [ "$srcdir/example.cxx", "example_wrap.cxx" ], + "include_dirs": ["$srcdir"] + } + ] +} diff --git a/Examples/javascript/functor/example.js b/Examples/javascript/functor/example.js index 79cd3913f..2e7f83a06 100644 --- a/Examples/javascript/functor/example.js +++ b/Examples/javascript/functor/example.js @@ -1 +1 @@ -module.exports = require("./build/Release/example"); +module.exports = require("build/Release/example"); diff --git a/Examples/javascript/functor/runme.js b/Examples/javascript/functor/runme.js index dc12470f4..28dc64320 100644 --- a/Examples/javascript/functor/runme.js +++ b/Examples/javascript/functor/runme.js @@ -1,4 +1,4 @@ -var example = require("./example"); +var example = require("example"); a = new example.intSum(0); b = new example.doubleSum(100.0); diff --git a/Examples/javascript/nspace/Makefile b/Examples/javascript/nspace/Makefile index ea04c7df8..0402f8d09 100644 --- a/Examples/javascript/nspace/Makefile +++ b/Examples/javascript/nspace/Makefile @@ -1,3 +1,3 @@ SRCS = -include ../example.mk +include $(SRCDIR)../example.mk diff --git a/Examples/javascript/nspace/binding.gyp b/Examples/javascript/nspace/binding.gyp deleted file mode 100644 index 69af46b22..000000000 --- a/Examples/javascript/nspace/binding.gyp +++ /dev/null @@ -1,8 +0,0 @@ -{ - "targets": [ - { - "target_name": "example", - "sources": [ "example_wrap.cxx" ] - } - ] -} diff --git a/Examples/javascript/nspace/binding.gyp.in b/Examples/javascript/nspace/binding.gyp.in new file mode 100644 index 000000000..59779aef4 --- /dev/null +++ b/Examples/javascript/nspace/binding.gyp.in @@ -0,0 +1,9 @@ +{ + "targets": [ + { + "target_name": "example", + "sources": [ "example_wrap.cxx" ], + "include_dirs": ["$srcdir"] + } + ] +} diff --git a/Examples/javascript/nspace/example.js b/Examples/javascript/nspace/example.js index 79cd3913f..2e7f83a06 100644 --- a/Examples/javascript/nspace/example.js +++ b/Examples/javascript/nspace/example.js @@ -1 +1 @@ -module.exports = require("./build/Release/example"); +module.exports = require("build/Release/example"); diff --git a/Examples/javascript/nspace/runme.js b/Examples/javascript/nspace/runme.js index d6a49d8d4..fad73477d 100644 --- a/Examples/javascript/nspace/runme.js +++ b/Examples/javascript/nspace/runme.js @@ -3,7 +3,7 @@ // This file illustrates class C++ interface generated // by SWIG. -var example = require("./example"); +var example = require("example"); // Calling a module function ( aka global function ) if (example.module_function() !== 7) { diff --git a/Examples/javascript/operator/Makefile b/Examples/javascript/operator/Makefile index ea04c7df8..0402f8d09 100644 --- a/Examples/javascript/operator/Makefile +++ b/Examples/javascript/operator/Makefile @@ -1,3 +1,3 @@ SRCS = -include ../example.mk +include $(SRCDIR)../example.mk diff --git a/Examples/javascript/operator/binding.gyp b/Examples/javascript/operator/binding.gyp deleted file mode 100644 index 69af46b22..000000000 --- a/Examples/javascript/operator/binding.gyp +++ /dev/null @@ -1,8 +0,0 @@ -{ - "targets": [ - { - "target_name": "example", - "sources": [ "example_wrap.cxx" ] - } - ] -} diff --git a/Examples/javascript/operator/binding.gyp.in b/Examples/javascript/operator/binding.gyp.in new file mode 100644 index 000000000..59779aef4 --- /dev/null +++ b/Examples/javascript/operator/binding.gyp.in @@ -0,0 +1,9 @@ +{ + "targets": [ + { + "target_name": "example", + "sources": [ "example_wrap.cxx" ], + "include_dirs": ["$srcdir"] + } + ] +} diff --git a/Examples/javascript/operator/example.js b/Examples/javascript/operator/example.js index 79cd3913f..2e7f83a06 100644 --- a/Examples/javascript/operator/example.js +++ b/Examples/javascript/operator/example.js @@ -1 +1 @@ -module.exports = require("./build/Release/example"); +module.exports = require("build/Release/example"); diff --git a/Examples/javascript/operator/runme.js b/Examples/javascript/operator/runme.js index a700918d6..f72ca1c28 100644 --- a/Examples/javascript/operator/runme.js +++ b/Examples/javascript/operator/runme.js @@ -1,4 +1,4 @@ -var example = require("./example"); +var example = require("example"); a = new example.Complex(2,3); b = new example.Complex(-5,10); diff --git a/Examples/javascript/overload/Makefile b/Examples/javascript/overload/Makefile index ea04c7df8..0402f8d09 100644 --- a/Examples/javascript/overload/Makefile +++ b/Examples/javascript/overload/Makefile @@ -1,3 +1,3 @@ SRCS = -include ../example.mk +include $(SRCDIR)../example.mk diff --git a/Examples/javascript/overload/binding.gyp b/Examples/javascript/overload/binding.gyp deleted file mode 100644 index 69af46b22..000000000 --- a/Examples/javascript/overload/binding.gyp +++ /dev/null @@ -1,8 +0,0 @@ -{ - "targets": [ - { - "target_name": "example", - "sources": [ "example_wrap.cxx" ] - } - ] -} diff --git a/Examples/javascript/overload/binding.gyp.in b/Examples/javascript/overload/binding.gyp.in new file mode 100644 index 000000000..59779aef4 --- /dev/null +++ b/Examples/javascript/overload/binding.gyp.in @@ -0,0 +1,9 @@ +{ + "targets": [ + { + "target_name": "example", + "sources": [ "example_wrap.cxx" ], + "include_dirs": ["$srcdir"] + } + ] +} diff --git a/Examples/javascript/overload/example.js b/Examples/javascript/overload/example.js index 79cd3913f..2e7f83a06 100644 --- a/Examples/javascript/overload/example.js +++ b/Examples/javascript/overload/example.js @@ -1 +1 @@ -module.exports = require("./build/Release/example"); +module.exports = require("build/Release/example"); diff --git a/Examples/javascript/overload/runme.js b/Examples/javascript/overload/runme.js index 1e6c861a6..1c23e3b6b 100644 --- a/Examples/javascript/overload/runme.js +++ b/Examples/javascript/overload/runme.js @@ -1,4 +1,4 @@ -var example = require("./example"); +var example = require("example"); example.f(); example.f(1); diff --git a/Examples/javascript/pointer/Makefile b/Examples/javascript/pointer/Makefile index 31846faae..54a8f7b03 100644 --- a/Examples/javascript/pointer/Makefile +++ b/Examples/javascript/pointer/Makefile @@ -1,3 +1,3 @@ SRCS = example.cxx -include ../example.mk +include $(SRCDIR)../example.mk diff --git a/Examples/javascript/pointer/binding.gyp b/Examples/javascript/pointer/binding.gyp deleted file mode 100644 index 54eebfaa0..000000000 --- a/Examples/javascript/pointer/binding.gyp +++ /dev/null @@ -1,8 +0,0 @@ -{ - "targets": [ - { - "target_name": "example", - "sources": [ "example.cxx", "example_wrap.cxx" ] - } - ] -} diff --git a/Examples/javascript/pointer/binding.gyp.in b/Examples/javascript/pointer/binding.gyp.in new file mode 100644 index 000000000..c56a650e9 --- /dev/null +++ b/Examples/javascript/pointer/binding.gyp.in @@ -0,0 +1,9 @@ +{ + "targets": [ + { + "target_name": "example", + "sources": [ "$srcdir/example.cxx", "example_wrap.cxx" ], + "include_dirs": ["$srcdir"] + } + ] +} diff --git a/Examples/javascript/pointer/example.js b/Examples/javascript/pointer/example.js index 79cd3913f..2e7f83a06 100644 --- a/Examples/javascript/pointer/example.js +++ b/Examples/javascript/pointer/example.js @@ -1 +1 @@ -module.exports = require("./build/Release/example"); +module.exports = require("build/Release/example"); diff --git a/Examples/javascript/pointer/runme.js b/Examples/javascript/pointer/runme.js index fb8cf0c74..e9fa9a0bc 100644 --- a/Examples/javascript/pointer/runme.js +++ b/Examples/javascript/pointer/runme.js @@ -1,4 +1,4 @@ -var example = require("./example"); +var example = require("example"); // First create some objects using the pointer library. console.log("Testing the pointer library"); diff --git a/Examples/javascript/reference/Makefile b/Examples/javascript/reference/Makefile index 31846faae..54a8f7b03 100644 --- a/Examples/javascript/reference/Makefile +++ b/Examples/javascript/reference/Makefile @@ -1,3 +1,3 @@ SRCS = example.cxx -include ../example.mk +include $(SRCDIR)../example.mk diff --git a/Examples/javascript/reference/binding.gyp b/Examples/javascript/reference/binding.gyp deleted file mode 100644 index 54eebfaa0..000000000 --- a/Examples/javascript/reference/binding.gyp +++ /dev/null @@ -1,8 +0,0 @@ -{ - "targets": [ - { - "target_name": "example", - "sources": [ "example.cxx", "example_wrap.cxx" ] - } - ] -} diff --git a/Examples/javascript/reference/binding.gyp.in b/Examples/javascript/reference/binding.gyp.in new file mode 100644 index 000000000..c56a650e9 --- /dev/null +++ b/Examples/javascript/reference/binding.gyp.in @@ -0,0 +1,9 @@ +{ + "targets": [ + { + "target_name": "example", + "sources": [ "$srcdir/example.cxx", "example_wrap.cxx" ], + "include_dirs": ["$srcdir"] + } + ] +} diff --git a/Examples/javascript/reference/example.js b/Examples/javascript/reference/example.js index 79cd3913f..2e7f83a06 100644 --- a/Examples/javascript/reference/example.js +++ b/Examples/javascript/reference/example.js @@ -1 +1 @@ -module.exports = require("./build/Release/example"); +module.exports = require("build/Release/example"); diff --git a/Examples/javascript/reference/runme.js b/Examples/javascript/reference/runme.js index 88c108314..04f732520 100644 --- a/Examples/javascript/reference/runme.js +++ b/Examples/javascript/reference/runme.js @@ -1,5 +1,5 @@ // This file illustrates the manipulation of C++ references in Javascript. -var example = require("./example"); +var example = require("example"); // ----- Object creation ----- diff --git a/Examples/javascript/simple/Makefile b/Examples/javascript/simple/Makefile index 31846faae..54a8f7b03 100644 --- a/Examples/javascript/simple/Makefile +++ b/Examples/javascript/simple/Makefile @@ -1,3 +1,3 @@ SRCS = example.cxx -include ../example.mk +include $(SRCDIR)../example.mk diff --git a/Examples/javascript/simple/binding.gyp b/Examples/javascript/simple/binding.gyp deleted file mode 100644 index 54eebfaa0..000000000 --- a/Examples/javascript/simple/binding.gyp +++ /dev/null @@ -1,8 +0,0 @@ -{ - "targets": [ - { - "target_name": "example", - "sources": [ "example.cxx", "example_wrap.cxx" ] - } - ] -} diff --git a/Examples/javascript/simple/binding.gyp.in b/Examples/javascript/simple/binding.gyp.in new file mode 100644 index 000000000..c56a650e9 --- /dev/null +++ b/Examples/javascript/simple/binding.gyp.in @@ -0,0 +1,9 @@ +{ + "targets": [ + { + "target_name": "example", + "sources": [ "$srcdir/example.cxx", "example_wrap.cxx" ], + "include_dirs": ["$srcdir"] + } + ] +} diff --git a/Examples/javascript/simple/example.js b/Examples/javascript/simple/example.js index 79cd3913f..2e7f83a06 100644 --- a/Examples/javascript/simple/example.js +++ b/Examples/javascript/simple/example.js @@ -1 +1 @@ -module.exports = require("./build/Release/example"); +module.exports = require("build/Release/example"); diff --git a/Examples/javascript/simple/runme.js b/Examples/javascript/simple/runme.js index be2c18669..4abff0e2a 100644 --- a/Examples/javascript/simple/runme.js +++ b/Examples/javascript/simple/runme.js @@ -1,4 +1,4 @@ -var example = require("./example"); +var example = require("example"); /* Call our gcd() function */ diff --git a/Examples/javascript/template/Makefile b/Examples/javascript/template/Makefile index ea04c7df8..0402f8d09 100644 --- a/Examples/javascript/template/Makefile +++ b/Examples/javascript/template/Makefile @@ -1,3 +1,3 @@ SRCS = -include ../example.mk +include $(SRCDIR)../example.mk diff --git a/Examples/javascript/template/binding.gyp b/Examples/javascript/template/binding.gyp deleted file mode 100644 index 69af46b22..000000000 --- a/Examples/javascript/template/binding.gyp +++ /dev/null @@ -1,8 +0,0 @@ -{ - "targets": [ - { - "target_name": "example", - "sources": [ "example_wrap.cxx" ] - } - ] -} diff --git a/Examples/javascript/template/binding.gyp.in b/Examples/javascript/template/binding.gyp.in new file mode 100644 index 000000000..59779aef4 --- /dev/null +++ b/Examples/javascript/template/binding.gyp.in @@ -0,0 +1,9 @@ +{ + "targets": [ + { + "target_name": "example", + "sources": [ "example_wrap.cxx" ], + "include_dirs": ["$srcdir"] + } + ] +} diff --git a/Examples/javascript/template/example.js b/Examples/javascript/template/example.js index 79cd3913f..2e7f83a06 100644 --- a/Examples/javascript/template/example.js +++ b/Examples/javascript/template/example.js @@ -1 +1 @@ -module.exports = require("./build/Release/example"); +module.exports = require("build/Release/example"); diff --git a/Examples/javascript/template/runme.js b/Examples/javascript/template/runme.js index 55894dfd5..af96ac7f9 100644 --- a/Examples/javascript/template/runme.js +++ b/Examples/javascript/template/runme.js @@ -1,4 +1,4 @@ -var example = require("./example"); +var example = require("example"); //Call some templated functions console.log(example.maxint(3,7)); diff --git a/Examples/javascript/variables/Makefile b/Examples/javascript/variables/Makefile index 31846faae..54a8f7b03 100644 --- a/Examples/javascript/variables/Makefile +++ b/Examples/javascript/variables/Makefile @@ -1,3 +1,3 @@ SRCS = example.cxx -include ../example.mk +include $(SRCDIR)../example.mk diff --git a/Examples/javascript/variables/binding.gyp b/Examples/javascript/variables/binding.gyp deleted file mode 100644 index 54eebfaa0..000000000 --- a/Examples/javascript/variables/binding.gyp +++ /dev/null @@ -1,8 +0,0 @@ -{ - "targets": [ - { - "target_name": "example", - "sources": [ "example.cxx", "example_wrap.cxx" ] - } - ] -} diff --git a/Examples/javascript/variables/binding.gyp.in b/Examples/javascript/variables/binding.gyp.in new file mode 100644 index 000000000..c56a650e9 --- /dev/null +++ b/Examples/javascript/variables/binding.gyp.in @@ -0,0 +1,9 @@ +{ + "targets": [ + { + "target_name": "example", + "sources": [ "$srcdir/example.cxx", "example_wrap.cxx" ], + "include_dirs": ["$srcdir"] + } + ] +} diff --git a/Examples/javascript/variables/example.js b/Examples/javascript/variables/example.js index 79cd3913f..2e7f83a06 100644 --- a/Examples/javascript/variables/example.js +++ b/Examples/javascript/variables/example.js @@ -1 +1 @@ -module.exports = require("./build/Release/example"); +module.exports = require("build/Release/example"); diff --git a/Examples/javascript/variables/runme.js b/Examples/javascript/variables/runme.js index 537e17296..a2b5f791c 100644 --- a/Examples/javascript/variables/runme.js +++ b/Examples/javascript/variables/runme.js @@ -1,4 +1,4 @@ -var example = require("./example"); +var example = require("example"); // Try to set the values of some global variables example.ivar = 42; diff --git a/Examples/lua/arrays/Makefile b/Examples/lua/arrays/Makefile index d398dffea..4191f7ec3 100644 --- a/Examples/lua/arrays/Makefile +++ b/Examples/lua/arrays/Makefile @@ -5,15 +5,15 @@ TARGET = example INTERFACE = example.i check: build - $(MAKE) -f $(TOP)/Makefile lua_run + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' lua_run build: - $(MAKE) -f $(TOP)/Makefile SRCS='$(SRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SRCS='$(SRCS)' SWIG='$(SWIG)' \ TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' lua static: - $(MAKE) -f $(TOP)/Makefile SRCS='$(SRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SRCS='$(SRCS)' SWIG='$(SWIG)' \ TARGET='mylua' INTERFACE='$(INTERFACE)' lua_static clean: - $(MAKE) -f $(TOP)/Makefile lua_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' lua_clean diff --git a/Examples/lua/class/Makefile b/Examples/lua/class/Makefile index c39e8acdf..96308f0df 100644 --- a/Examples/lua/class/Makefile +++ b/Examples/lua/class/Makefile @@ -6,15 +6,15 @@ INTERFACE = example.i LIBS = -lm check: build - $(MAKE) -f $(TOP)/Makefile lua_run + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' lua_run build: - $(MAKE) -f $(TOP)/Makefile CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' lua_cpp static: - $(MAKE) -f $(TOP)/Makefile CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ TARGET='mylua' INTERFACE='$(INTERFACE)' lua_cpp_static clean: - $(MAKE) -f $(TOP)/Makefile lua_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' lua_clean diff --git a/Examples/lua/constants/Makefile b/Examples/lua/constants/Makefile index 7e36e15a1..ae33cb182 100644 --- a/Examples/lua/constants/Makefile +++ b/Examples/lua/constants/Makefile @@ -6,15 +6,15 @@ INTERFACE = example.i LIBS = check: build - $(MAKE) -f $(TOP)/Makefile lua_run + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' lua_run build: - $(MAKE) -f $(TOP)/Makefile CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' lua static: - $(MAKE) -f $(TOP)/Makefile CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ TARGET='mylua' INTERFACE='$(INTERFACE)' lua_static clean: - $(MAKE) -f $(TOP)/Makefile lua_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' lua_clean diff --git a/Examples/lua/dual/Makefile b/Examples/lua/dual/Makefile index 12ee00a68..c86152a97 100644 --- a/Examples/lua/dual/Makefile +++ b/Examples/lua/dual/Makefile @@ -1,21 +1,21 @@ TOP = ../.. SWIG = $(TOP)/../preinst-swig TARGET = dual -CXXSRCS = example2_wrap.cxx +GENCXXSRCS = example2_wrap.cxx INTERFACE = dual.i LUA_INTERP = dual.cpp # This is a little different to normal as we need to static link two modules and a custom interpreter # We need the external runtime, then swig examples2, and build the module as normal check: build - $(MAKE) -f $(TOP)/Makefile TARGET='$(TARGET)' lua_embed_run + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' TARGET='$(TARGET)' lua_embed_run build: $(SWIG) -lua -external-runtime - $(SWIG) -c++ -lua $(SWIGOPT) example2.i - $(MAKE) -f $(TOP)/Makefile $(SWIGLIB) CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ + $(SWIG) -c++ -lua $(SWIGOPT) -o $(GENCXXSRCS) $(SRCDIR)example2.i + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' $(SWIGLIB) GENCXXSRCS='$(GENCXXSRCS)' SWIG='$(SWIG)' \ SWIGOPT='$(SWIGOPT)' TARGET='$(TARGET)' INTERFACE='example.i' LUA_INTERP='$(LUA_INTERP)' lua_static_cpp clean: - $(MAKE) -f $(TOP)/Makefile lua_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' lua_clean rm -f swigluarun.h $(TARGET) diff --git a/Examples/lua/embed/Makefile b/Examples/lua/embed/Makefile index 57979c061..5e3a91893 100644 --- a/Examples/lua/embed/Makefile +++ b/Examples/lua/embed/Makefile @@ -9,12 +9,12 @@ LIBS = -lm # this is a little different to normal as we have our own special interpreter # which we want to static link check: build - $(MAKE) -f $(TOP)/Makefile TARGET='$(TARGET)' lua_embed_run + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' TARGET='$(TARGET)' lua_embed_run build: - $(MAKE) -f $(TOP)/Makefile $(SWIGLIB) SRCS='$(SRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' $(SWIGLIB) SRCS='$(SRCS)' SWIG='$(SWIG)' \ SWIGOPT='$(SWIGOPT)' TARGET='$(TARGET)' LIBS='$(LIBS)' INTERFACE='example.i' LUA_INTERP='$(LUA_INTERP)' lua_static clean: - $(MAKE) -f $(TOP)/Makefile lua_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' lua_clean rm -f $(TARGET) diff --git a/Examples/lua/embed/embed.c b/Examples/lua/embed/embed.c index 507567489..1f10cc8e8 100644 --- a/Examples/lua/embed/embed.c +++ b/Examples/lua/embed/embed.c @@ -13,6 +13,7 @@ We will be using the luaL_dostring()/lua_dostring() function to call into lua #include #include +#include #include #include @@ -62,9 +63,13 @@ int main(int argc,char* argv[]) { luaopen_example(L); printf("[C] all looks ok\n"); printf("\n"); - printf("[C] let's load the file 'runme.lua'\n"); + if (argc != 2 || argv[1] == NULL || strlen(argv[1]) == 0) { + printf("[C] ERROR: no lua file given on command line\n"); + exit(3); + } + printf("[C] let's load the file '%s'\n", argv[1]); printf("[C] any lua code in this file will be executed\n"); - if (luaL_loadfile(L, "runme.lua") || lua_pcall(L, 0, 0, 0)) { + if (luaL_loadfile(L, argv[1]) || lua_pcall(L, 0, 0, 0)) { printf("[C] ERROR: cannot run lua file: %s",lua_tostring(L, -1)); exit(3); } diff --git a/Examples/lua/embed2/Makefile b/Examples/lua/embed2/Makefile index ec22bdcae..d30ba0942 100644 --- a/Examples/lua/embed2/Makefile +++ b/Examples/lua/embed2/Makefile @@ -9,12 +9,12 @@ LIBS = -lm # this is a little different to normal as we have our own special interpreter # which we want to static link check: build - $(MAKE) -f $(TOP)/Makefile TARGET='$(TARGET)' lua_embed_run + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' TARGET='$(TARGET)' lua_embed_run build: - $(MAKE) -f $(TOP)/Makefile $(SWIGLIB) SRCS='$(SRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' $(SWIGLIB) SRCS='$(SRCS)' SWIG='$(SWIG)' \ SWIGOPT='$(SWIGOPT)' TARGET='$(TARGET)' LIBS='$(LIBS)' INTERFACE='example.i' LUA_INTERP='$(LUA_INTERP)' lua_static clean: - $(MAKE) -f $(TOP)/Makefile lua_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' lua_clean rm -f $(TARGET) diff --git a/Examples/lua/embed2/embed2.c b/Examples/lua/embed2/embed2.c index 100a1fb33..7b2ca9b67 100644 --- a/Examples/lua/embed2/embed2.c +++ b/Examples/lua/embed2/embed2.c @@ -24,6 +24,7 @@ We will be using the luaL_dostring()/lua_dostring() function to call into lua #include #include +#include #include #include @@ -189,9 +190,13 @@ int main(int argc,char* argv[]) { luaopen_example(L); printf("[C] all looks ok\n"); printf("\n"); - printf("[C] let's load the file 'runme.lua'\n"); + if (argc != 2 || argv[1] == NULL || strlen(argv[1]) == 0) { + printf("[C] ERROR: no lua file given on command line\n"); + exit(3); + } + printf("[C] let's load the file '%s'\n", argv[1]); printf("[C] any lua code in this file will be executed\n"); - if (luaL_loadfile(L, "runme.lua") || lua_pcall(L, 0, 0, 0)) { + if (luaL_loadfile(L, argv[1]) || lua_pcall(L, 0, 0, 0)) { printf("[C] ERROR: cannot run lua file: %s",lua_tostring(L, -1)); exit(3); } diff --git a/Examples/lua/embed3/Makefile b/Examples/lua/embed3/Makefile index 8cfa97454..fc0026122 100644 --- a/Examples/lua/embed3/Makefile +++ b/Examples/lua/embed3/Makefile @@ -9,13 +9,13 @@ LUA_INTERP = embed3.cpp # which we want to static link # we also need the external runtime, so we can get access to certain internals of SWIG check: build - $(MAKE) -f $(TOP)/Makefile TARGET='$(TARGET)' lua_embed_run + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' TARGET='$(TARGET)' lua_embed_run build: $(SWIG) -c++ -lua $(SWIGOPT) -external-runtime swigluarun.h - $(MAKE) -f $(TOP)/Makefile $(SWIGLIB) SRCS='$(SRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' $(SWIGLIB) SRCS='$(SRCS)' SWIG='$(SWIG)' \ SWIGOPT='$(SWIGOPT)' TARGET='$(TARGET)' INTERFACE='example.i' LUA_INTERP='$(LUA_INTERP)' lua_static_cpp clean: - $(MAKE) -f $(TOP)/Makefile lua_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' lua_clean rm -f swigluarun.h $(TARGET) diff --git a/Examples/lua/embed3/embed3.cpp b/Examples/lua/embed3/embed3.cpp index d559167d1..9be49add3 100644 --- a/Examples/lua/embed3/embed3.cpp +++ b/Examples/lua/embed3/embed3.cpp @@ -113,10 +113,14 @@ int main(int argc, char* argv[]) { push_pointer(L,&engine,"Engine *",0); lua_setglobal(L, "pEngine"); // set as global variable - printf("[C++] now let's load the file 'runme.lua'\n"); + if (argc != 2 || argv[1] == NULL || strlen(argv[1]) == 0) { + printf("[C++] ERROR: no lua file given on command line\n"); + exit(3); + } + printf("[C++] now let's load the file '%s'\n", argv[1]); printf("[C++] any lua code in this file will be executed\n"); - if (luaL_loadfile(L, "runme.lua") || lua_pcall(L, 0, 0, 0)) { - printf("[C++] ERROR: cannot run lua file: %s", lua_tostring(L, -1)); + if (luaL_loadfile(L, argv[1]) || lua_pcall(L, 0, 0, 0)) { + printf("[C++] ERROR: cannot run lua file: %s",lua_tostring(L, -1)); exit(3); } printf("[C++] We are now back in C++, all looks ok\n"); diff --git a/Examples/lua/exception/Makefile b/Examples/lua/exception/Makefile index 3dbebb4e5..ac9c28b69 100644 --- a/Examples/lua/exception/Makefile +++ b/Examples/lua/exception/Makefile @@ -6,15 +6,15 @@ INTERFACE = example.i LIBS = -lm check: build - $(MAKE) -f $(TOP)/Makefile lua_run + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' lua_run build: - $(MAKE) -f $(TOP)/Makefile CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' lua_cpp static: - $(MAKE) -f $(TOP)/Makefile CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ TARGET='mylua' INTERFACE='$(INTERFACE)' lua_cpp_static clean: - $(MAKE) -f $(TOP)/Makefile lua_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' lua_clean diff --git a/Examples/lua/funcptr3/Makefile b/Examples/lua/funcptr3/Makefile index 8b51e73e8..aeeaad469 100644 --- a/Examples/lua/funcptr3/Makefile +++ b/Examples/lua/funcptr3/Makefile @@ -6,15 +6,15 @@ INTERFACE = example.i LIBS = check: build - $(MAKE) -f $(TOP)/Makefile lua_run + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' lua_run build: - $(MAKE) -f $(TOP)/Makefile SRCS='$(SRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SRCS='$(SRCS)' SWIG='$(SWIG)' \ TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' lua static: - $(MAKE) -f $(TOP)/Makefile SRCS='$(SRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SRCS='$(SRCS)' SWIG='$(SWIG)' \ TARGET='mylua' INTERFACE='$(INTERFACE)' lua_static clean: - $(MAKE) -f $(TOP)/Makefile lua_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' lua_clean diff --git a/Examples/lua/functest/Makefile b/Examples/lua/functest/Makefile index 8b51e73e8..aeeaad469 100644 --- a/Examples/lua/functest/Makefile +++ b/Examples/lua/functest/Makefile @@ -6,15 +6,15 @@ INTERFACE = example.i LIBS = check: build - $(MAKE) -f $(TOP)/Makefile lua_run + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' lua_run build: - $(MAKE) -f $(TOP)/Makefile SRCS='$(SRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SRCS='$(SRCS)' SWIG='$(SWIG)' \ TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' lua static: - $(MAKE) -f $(TOP)/Makefile SRCS='$(SRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SRCS='$(SRCS)' SWIG='$(SWIG)' \ TARGET='mylua' INTERFACE='$(INTERFACE)' lua_static clean: - $(MAKE) -f $(TOP)/Makefile lua_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' lua_clean diff --git a/Examples/lua/functor/Makefile b/Examples/lua/functor/Makefile index 4e4edbfa5..e647fb2a8 100644 --- a/Examples/lua/functor/Makefile +++ b/Examples/lua/functor/Makefile @@ -7,15 +7,15 @@ LIBS = -lm SWIGOPT = check: build - $(MAKE) -f $(TOP)/Makefile lua_run + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' lua_run build: - $(MAKE) -f $(TOP)/Makefile CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ SWIGOPT='$(SWIGOPT)' TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' lua_cpp static: - $(MAKE) -f $(TOP)/Makefile CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ TARGET='mylua' INTERFACE='$(INTERFACE)' lua_cpp_static clean: - $(MAKE) -f $(TOP)/Makefile lua_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' lua_clean diff --git a/Examples/lua/import/Makefile b/Examples/lua/import/Makefile index 0a9aebd57..8d64a21c6 100644 --- a/Examples/lua/import/Makefile +++ b/Examples/lua/import/Makefile @@ -4,17 +4,17 @@ SWIGOPT = LIBS = check: build - $(MAKE) -f $(TOP)/Makefile lua_run + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' lua_run build: - $(MAKE) -f $(TOP)/Makefile SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT)' \ LIBS='$(LIBS)' TARGET='base' INTERFACE='base.i' lua_cpp - $(MAKE) -f $(TOP)/Makefile SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT)' \ LIBS='$(LIBS)' TARGET='foo' INTERFACE='foo.i' lua_cpp - $(MAKE) -f $(TOP)/Makefile SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT)' \ LIBS='$(LIBS)' TARGET='bar' INTERFACE='bar.i' lua_cpp - $(MAKE) -f $(TOP)/Makefile SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT)' \ LIBS='$(LIBS)' TARGET='spam' INTERFACE='spam.i' lua_cpp clean: - $(MAKE) -f $(TOP)/Makefile lua_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' lua_clean diff --git a/Examples/lua/nspace/Makefile b/Examples/lua/nspace/Makefile index 57875ec49..17757c2ec 100644 --- a/Examples/lua/nspace/Makefile +++ b/Examples/lua/nspace/Makefile @@ -5,15 +5,15 @@ TARGET = example INTERFACE = example.i check: build - $(MAKE) -f $(TOP)/Makefile lua_run + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' lua_run build: - $(MAKE) -f $(TOP)/Makefile CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' lua_cpp static: - $(MAKE) -f $(TOP)/Makefile CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ TARGET='mylua' INTERFACE='$(INTERFACE)' lua_cpp_static clean: - $(MAKE) -f $(TOP)/Makefile lua_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' lua_clean diff --git a/Examples/lua/owner/Makefile b/Examples/lua/owner/Makefile index c39e8acdf..96308f0df 100644 --- a/Examples/lua/owner/Makefile +++ b/Examples/lua/owner/Makefile @@ -6,15 +6,15 @@ INTERFACE = example.i LIBS = -lm check: build - $(MAKE) -f $(TOP)/Makefile lua_run + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' lua_run build: - $(MAKE) -f $(TOP)/Makefile CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' lua_cpp static: - $(MAKE) -f $(TOP)/Makefile CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ TARGET='mylua' INTERFACE='$(INTERFACE)' lua_cpp_static clean: - $(MAKE) -f $(TOP)/Makefile lua_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' lua_clean diff --git a/Examples/lua/pointer/Makefile b/Examples/lua/pointer/Makefile index 8b51e73e8..aeeaad469 100644 --- a/Examples/lua/pointer/Makefile +++ b/Examples/lua/pointer/Makefile @@ -6,15 +6,15 @@ INTERFACE = example.i LIBS = check: build - $(MAKE) -f $(TOP)/Makefile lua_run + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' lua_run build: - $(MAKE) -f $(TOP)/Makefile SRCS='$(SRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SRCS='$(SRCS)' SWIG='$(SWIG)' \ TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' lua static: - $(MAKE) -f $(TOP)/Makefile SRCS='$(SRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SRCS='$(SRCS)' SWIG='$(SWIG)' \ TARGET='mylua' INTERFACE='$(INTERFACE)' lua_static clean: - $(MAKE) -f $(TOP)/Makefile lua_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' lua_clean diff --git a/Examples/lua/simple/Makefile b/Examples/lua/simple/Makefile index d398dffea..4191f7ec3 100644 --- a/Examples/lua/simple/Makefile +++ b/Examples/lua/simple/Makefile @@ -5,15 +5,15 @@ TARGET = example INTERFACE = example.i check: build - $(MAKE) -f $(TOP)/Makefile lua_run + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' lua_run build: - $(MAKE) -f $(TOP)/Makefile SRCS='$(SRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SRCS='$(SRCS)' SWIG='$(SWIG)' \ TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' lua static: - $(MAKE) -f $(TOP)/Makefile SRCS='$(SRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SRCS='$(SRCS)' SWIG='$(SWIG)' \ TARGET='mylua' INTERFACE='$(INTERFACE)' lua_static clean: - $(MAKE) -f $(TOP)/Makefile lua_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' lua_clean diff --git a/Examples/lua/variables/Makefile b/Examples/lua/variables/Makefile index d398dffea..4191f7ec3 100644 --- a/Examples/lua/variables/Makefile +++ b/Examples/lua/variables/Makefile @@ -5,15 +5,15 @@ TARGET = example INTERFACE = example.i check: build - $(MAKE) -f $(TOP)/Makefile lua_run + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' lua_run build: - $(MAKE) -f $(TOP)/Makefile SRCS='$(SRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SRCS='$(SRCS)' SWIG='$(SWIG)' \ TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' lua static: - $(MAKE) -f $(TOP)/Makefile SRCS='$(SRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SRCS='$(SRCS)' SWIG='$(SWIG)' \ TARGET='mylua' INTERFACE='$(INTERFACE)' lua_static clean: - $(MAKE) -f $(TOP)/Makefile lua_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' lua_clean diff --git a/Examples/modula3/class/Makefile b/Examples/modula3/class/Makefile index af8e099cc..2e2f37526 100644 --- a/Examples/modula3/class/Makefile +++ b/Examples/modula3/class/Makefile @@ -8,10 +8,10 @@ SWIGOPT = -c++ MODULA3SRCS = *.[im]3 check: build - $(MAKE) -f $(TOP)/Makefile modula3_run + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' modula3_run build: - $(MAKE) -f $(TOP)/Makefile SRCS='$(SRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SRCS='$(SRCS)' SWIG='$(SWIG)' \ SWIGOPT='$(SWIGOPT)' TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' modula3 m3ppinplace $(MODULA3SRCS) # compilation of example_wrap.cxx is started by cm3 @@ -21,4 +21,4 @@ build: cm3 clean: - $(MAKE) -f $(TOP)/Makefile modula3_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' modula3_clean diff --git a/Examples/modula3/enum/Makefile b/Examples/modula3/enum/Makefile index a351cb1b9..3915e5405 100644 --- a/Examples/modula3/enum/Makefile +++ b/Examples/modula3/enum/Makefile @@ -8,18 +8,18 @@ SWIGOPT = -c++ MODULA3SRCS = *.[im]3 check: build - $(MAKE) -f $(TOP)/Makefile modula3_run + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' modula3_run build: $(SWIG) -modula3 $(SWIGOPT) -module Example -generateconst $(CONSTNUMERIC) $(TARGET).h $(CXX) -Wall $(CONSTNUMERIC).c -o $(CONSTNUMERIC) $(CONSTNUMERIC) >$(CONSTNUMERIC).i - $(MAKE) -f $(TOP)/Makefile SRCS='$(SRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SRCS='$(SRCS)' SWIG='$(SWIG)' \ SWIGOPT='$(SWIGOPT)' TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' modula3 m3ppinplace $(MODULA3SRCS) mv m3makefile $(MODULA3SRCS) src/ cm3 clean: - $(MAKE) -f $(TOP)/Makefile modula3_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' modula3_clean diff --git a/Examples/modula3/exception/Makefile b/Examples/modula3/exception/Makefile index 8d4525512..1dbf1a156 100644 --- a/Examples/modula3/exception/Makefile +++ b/Examples/modula3/exception/Makefile @@ -8,15 +8,15 @@ MODULA3SRCS = *.[im]3 MODULA3FLAGS= -o runme check: build - $(MAKE) -f $(TOP)/Makefile modula3_run + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' modula3_run build: - $(MAKE) -f $(TOP)/Makefile CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ SWIGOPT='$(SWIGOPT)' TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' modula3_cpp -# $(MAKE) -f $(TOP)/Makefile MODULA3SRCS='$(MODULA3SRCS)' MODULA3FLAGS='$(MODULA3FLAGS)' modula3_compile +# $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' MODULA3SRCS='$(MODULA3SRCS)' MODULA3FLAGS='$(MODULA3FLAGS)' modula3_compile m3ppinplace $(MODULA3SRCS) mv m3makefile $(MODULA3SRCS) src/ cm3 clean: - $(MAKE) -f $(TOP)/Makefile modula3_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' modula3_clean diff --git a/Examples/modula3/reference/Makefile b/Examples/modula3/reference/Makefile index 1a5fdeb30..3b68fe822 100644 --- a/Examples/modula3/reference/Makefile +++ b/Examples/modula3/reference/Makefile @@ -7,14 +7,14 @@ SWIGOPT = -c++ MODULA3SRCS = *.[im]3 check: build - $(MAKE) -f $(TOP)/Makefile modula3_run + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' modula3_run build: - $(MAKE) -f $(TOP)/Makefile SRCS='$(SRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SRCS='$(SRCS)' SWIG='$(SWIG)' \ SWIGOPT='$(SWIGOPT)' TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' modula3 m3ppinplace $(MODULA3SRCS) mv m3makefile $(MODULA3SRCS) src/ cm3 clean: - $(MAKE) -f $(TOP)/Makefile modula3_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' modula3_clean diff --git a/Examples/modula3/simple/Makefile b/Examples/modula3/simple/Makefile index 6287dac20..2796b25f8 100644 --- a/Examples/modula3/simple/Makefile +++ b/Examples/modula3/simple/Makefile @@ -7,14 +7,14 @@ SWIGOPT = MODULA3SRCS = *.[im]3 check: build - $(MAKE) -f $(TOP)/Makefile modula3_run + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' modula3_run build: - $(MAKE) -f $(TOP)/Makefile SRCS='$(SRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SRCS='$(SRCS)' SWIG='$(SWIG)' \ SWIGOPT='$(SWIGOPT)' TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' modula3 m3ppinplace $(MODULA3SRCS) mv m3makefile $(MODULA3SRCS) src/ cm3 clean: - $(MAKE) -f $(TOP)/Makefile modula3_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' modula3_clean diff --git a/Examples/modula3/typemap/Makefile b/Examples/modula3/typemap/Makefile index 6287dac20..2796b25f8 100644 --- a/Examples/modula3/typemap/Makefile +++ b/Examples/modula3/typemap/Makefile @@ -7,14 +7,14 @@ SWIGOPT = MODULA3SRCS = *.[im]3 check: build - $(MAKE) -f $(TOP)/Makefile modula3_run + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' modula3_run build: - $(MAKE) -f $(TOP)/Makefile SRCS='$(SRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SRCS='$(SRCS)' SWIG='$(SWIG)' \ SWIGOPT='$(SWIGOPT)' TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' modula3 m3ppinplace $(MODULA3SRCS) mv m3makefile $(MODULA3SRCS) src/ cm3 clean: - $(MAKE) -f $(TOP)/Makefile modula3_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' modula3_clean diff --git a/Examples/mzscheme/multimap/Makefile b/Examples/mzscheme/multimap/Makefile index f8eeb72c3..ecf83fbeb 100644 --- a/Examples/mzscheme/multimap/Makefile +++ b/Examples/mzscheme/multimap/Makefile @@ -6,10 +6,10 @@ INTERFACE = example.i SWIGOPT = check: build - $(MAKE) -f $(TOP)/Makefile mzscheme_run + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' mzscheme_run build: - $(MAKE) -f $(TOP)/Makefile SRCS='$(SRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SRCS='$(SRCS)' SWIG='$(SWIG)' \ SWIGOPT='$(SWIGOPT)' TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' mzscheme clean: - $(MAKE) -f $(TOP)/Makefile mzscheme_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' mzscheme_clean diff --git a/Examples/mzscheme/simple/Makefile b/Examples/mzscheme/simple/Makefile index f8eeb72c3..ecf83fbeb 100644 --- a/Examples/mzscheme/simple/Makefile +++ b/Examples/mzscheme/simple/Makefile @@ -6,10 +6,10 @@ INTERFACE = example.i SWIGOPT = check: build - $(MAKE) -f $(TOP)/Makefile mzscheme_run + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' mzscheme_run build: - $(MAKE) -f $(TOP)/Makefile SRCS='$(SRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SRCS='$(SRCS)' SWIG='$(SWIG)' \ SWIGOPT='$(SWIGOPT)' TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' mzscheme clean: - $(MAKE) -f $(TOP)/Makefile mzscheme_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' mzscheme_clean diff --git a/Examples/mzscheme/std_vector/Makefile b/Examples/mzscheme/std_vector/Makefile index d2bf0a013..75918a61e 100644 --- a/Examples/mzscheme/std_vector/Makefile +++ b/Examples/mzscheme/std_vector/Makefile @@ -9,7 +9,7 @@ GPP = `which g++` MZC = test -n "/usr/bin/mzc" && /usr/bin/mzc check: build - $(MAKE) -f $(TOP)/Makefile mzscheme_run + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' mzscheme_run build: $(SWIG) -mzscheme -c++ $(SWIGOPT) $(INTERFACE) @@ -17,4 +17,4 @@ build: $(MZC) --linker $(GPP) --ld $(TARGET).so example_wrap.o clean: - $(MAKE) -f $(TOP)/Makefile mzscheme_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' mzscheme_clean diff --git a/Examples/ocaml/argout_ref/Makefile b/Examples/ocaml/argout_ref/Makefile index 4e12e3769..09893af65 100644 --- a/Examples/ocaml/argout_ref/Makefile +++ b/Examples/ocaml/argout_ref/Makefile @@ -8,21 +8,21 @@ PROGFILE = example_prog.ml OBJS = example.o check: build - $(MAKE) -f $(TOP)/Makefile TARGET='$(TARGET)' ocaml_run + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' TARGET='$(TARGET)' ocaml_run build: static static: - $(MAKE) -f $(TOP)/Makefile SRCS='$(SRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SRCS='$(SRCS)' SWIG='$(SWIG)' \ TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' MLFILE='$(MLFILE)' \ PROGFILE='$(PROGFILE)' OBJS='$(OBJS)' \ ocaml_static_cpp dynamic: - $(MAKE) -f $(TOP)/Makefile SRCS='$(SRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SRCS='$(SRCS)' SWIG='$(SWIG)' \ TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' MLFILE='$(MLFILE)' \ PROGFILE='$(PROGFILE)' OBJS='$(OBJS)' \ ocaml_dynamic_cpp clean: - $(MAKE) -f $(TOP)/Makefile MLFILE='$(MLFILE)' ocaml_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' MLFILE='$(MLFILE)' ocaml_clean diff --git a/Examples/ocaml/contract/Makefile b/Examples/ocaml/contract/Makefile index 1db93e38a..df5d6a6f5 100644 --- a/Examples/ocaml/contract/Makefile +++ b/Examples/ocaml/contract/Makefile @@ -8,27 +8,27 @@ PROGFILE = example_prog.ml OBJS = check: build - $(MAKE) -f $(TOP)/Makefile TARGET='$(TARGET)' ocaml_run + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' TARGET='$(TARGET)' ocaml_run build: static dynamic: - $(MAKE) -f $(TOP)/Makefile SRCS='$(SRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SRCS='$(SRCS)' SWIG='$(SWIG)' \ TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' MLFILE='$(MLFILE)' \ PROGFILE='$(PROGFILE)' OBJS='$(OBJS)' \ ocaml_dynamic static: - $(MAKE) -f $(TOP)/Makefile SRCS='$(SRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SRCS='$(SRCS)' SWIG='$(SWIG)' \ TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' MLFILE='$(MLFILE)' \ PROGFILE='$(PROGFILE)' OBJS='$(OBJS)' \ ocaml_static toplevel: - $(MAKE) -f $(TOP)/Makefile SRCS='$(SRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SRCS='$(SRCS)' SWIG='$(SWIG)' \ TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' MLFILE='$(MLFILE)' \ PROGFILE='$(PROGFILE)' OBJS='$(OBJS)' \ ocaml_static_toplevel clean: - $(MAKE) -f $(TOP)/Makefile MLFILE='$(MLFILE)' ocaml_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' MLFILE='$(MLFILE)' ocaml_clean diff --git a/Examples/ocaml/scoped_enum/Makefile b/Examples/ocaml/scoped_enum/Makefile index e5de57ac2..794733971 100644 --- a/Examples/ocaml/scoped_enum/Makefile +++ b/Examples/ocaml/scoped_enum/Makefile @@ -8,27 +8,27 @@ PROGFILE = example_prog.ml OBJS = check: build - $(MAKE) -f $(TOP)/Makefile TARGET='$(TARGET)' ocaml_run + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' TARGET='$(TARGET)' ocaml_run build: static dynamic: - $(MAKE) -f $(TOP)/Makefile SRCS='$(SRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SRCS='$(SRCS)' SWIG='$(SWIG)' \ TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' MLFILE='$(MLFILE)' \ PROGFILE='$(PROGFILE)' OBJS='$(OBJS)' \ ocaml_dynamic_cpp static: - $(MAKE) -f $(TOP)/Makefile SRCS='$(SRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SRCS='$(SRCS)' SWIG='$(SWIG)' \ TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' MLFILE='$(MLFILE)' \ PROGFILE='$(PROGFILE)' OBJS='$(OBJS)' \ ocaml_static_cpp toplevel: - $(MAKE) -f $(TOP)/Makefile SRCS='$(SRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SRCS='$(SRCS)' SWIG='$(SWIG)' \ TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' MLFILE='$(MLFILE)' \ PROGFILE='$(PROGFILE)' OBJS='$(OBJS)' \ ocaml_static_cpp_toplevel clean: - $(MAKE) -f $(TOP)/Makefile MLFILE='$(MLFILE)' ocaml_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' MLFILE='$(MLFILE)' ocaml_clean diff --git a/Examples/ocaml/shapes/Makefile b/Examples/ocaml/shapes/Makefile index c1ab6507c..69102f3b1 100644 --- a/Examples/ocaml/shapes/Makefile +++ b/Examples/ocaml/shapes/Makefile @@ -9,27 +9,27 @@ PROGFILE = example_prog.ml OBJS = example.o check: build - $(MAKE) -f $(TOP)/Makefile TARGET='$(TARGET)' ocaml_run + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' TARGET='$(TARGET)' ocaml_run build: static static_top static: - $(MAKE) -f $(TOP)/Makefile SRCS='$(SRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SRCS='$(SRCS)' SWIG='$(SWIG)' \ SWIGOPT='$(SWIGOPT)' TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' \ MLFILE='$(MLFILE)' PROGFILE='$(PROGFILE)' OBJS='$(OBJS)' \ ocaml_static_cpp static_top: - $(MAKE) -f $(TOP)/Makefile SRCS='$(SRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SRCS='$(SRCS)' SWIG='$(SWIG)' \ SWIGOPT='$(SWIGOPT)' TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' \ MLFILE='$(MLFILE)' PROGFILE='$(PROGFILE)' OBJS='$(OBJS)' \ ocaml_static_cpp_toplevel dynamic: - $(MAKE) -f $(TOP)/Makefile SRCS='$(SRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SRCS='$(SRCS)' SWIG='$(SWIG)' \ SWIGOPT='$(SWIGOPT)' TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' MLFILE='$(MLFILE)' PROGFILE='$(PROGFILE)' OBJS='$(OBJS)' \ ocaml_dynamic_cpp clean: - $(MAKE) -f $(TOP)/Makefile MLFILE='$(MLFILE)' ocaml_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' MLFILE='$(MLFILE)' ocaml_clean diff --git a/Examples/ocaml/simple/Makefile b/Examples/ocaml/simple/Makefile index 64c7256c1..49bf81c1e 100644 --- a/Examples/ocaml/simple/Makefile +++ b/Examples/ocaml/simple/Makefile @@ -8,27 +8,27 @@ PROGFILE = example_prog.ml OBJS = example.o check: build - $(MAKE) -f $(TOP)/Makefile TARGET='$(TARGET)' ocaml_run + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' TARGET='$(TARGET)' ocaml_run build: static dynamic: - $(MAKE) -f $(TOP)/Makefile SRCS='$(SRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SRCS='$(SRCS)' SWIG='$(SWIG)' \ TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' MLFILE='$(MLFILE)' \ PROGFILE='$(PROGFILE)' OBJS='$(OBJS)' \ ocaml_dynamic static: - $(MAKE) -f $(TOP)/Makefile SRCS='$(SRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SRCS='$(SRCS)' SWIG='$(SWIG)' \ TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' MLFILE='$(MLFILE)' \ PROGFILE='$(PROGFILE)' OBJS='$(OBJS)' \ ocaml_static toplevel: - $(MAKE) -f $(TOP)/Makefile SRCS='$(SRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SRCS='$(SRCS)' SWIG='$(SWIG)' \ TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' MLFILE='$(MLFILE)' \ PROGFILE='$(PROGFILE)' OBJS='$(OBJS)' \ ocaml_static_toplevel clean: - $(MAKE) -f $(TOP)/Makefile MLFILE='$(MLFILE)' ocaml_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' MLFILE='$(MLFILE)' ocaml_clean diff --git a/Examples/ocaml/std_string/Makefile b/Examples/ocaml/std_string/Makefile index 89f997090..8f8b2f684 100644 --- a/Examples/ocaml/std_string/Makefile +++ b/Examples/ocaml/std_string/Makefile @@ -6,19 +6,19 @@ INTERFACE = example.i PROGFILE = runme.ml check: build - $(MAKE) -f $(TOP)/Makefile TARGET='$(TARGET)' ocaml_run + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' TARGET='$(TARGET)' ocaml_run build: static static: - $(MAKE) -f $(TOP)/Makefile SRCS='$(SRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SRCS='$(SRCS)' SWIG='$(SWIG)' \ PROGFILE='$(PROGFILE)' TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' \ ocaml_static_cpp dynamic: - $(MAKE) -f $(TOP)/Makefile SRCS='$(SRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SRCS='$(SRCS)' SWIG='$(SWIG)' \ PROGFILE='$(PROGFILE)' TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' \ ocaml_dynamic_cpp clean: - $(MAKE) -f $(TOP)/Makefile TARGET='$(TARGET)' ocaml_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' TARGET='$(TARGET)' ocaml_clean diff --git a/Examples/ocaml/std_vector/Makefile b/Examples/ocaml/std_vector/Makefile index 89f997090..8f8b2f684 100644 --- a/Examples/ocaml/std_vector/Makefile +++ b/Examples/ocaml/std_vector/Makefile @@ -6,19 +6,19 @@ INTERFACE = example.i PROGFILE = runme.ml check: build - $(MAKE) -f $(TOP)/Makefile TARGET='$(TARGET)' ocaml_run + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' TARGET='$(TARGET)' ocaml_run build: static static: - $(MAKE) -f $(TOP)/Makefile SRCS='$(SRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SRCS='$(SRCS)' SWIG='$(SWIG)' \ PROGFILE='$(PROGFILE)' TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' \ ocaml_static_cpp dynamic: - $(MAKE) -f $(TOP)/Makefile SRCS='$(SRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SRCS='$(SRCS)' SWIG='$(SWIG)' \ PROGFILE='$(PROGFILE)' TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' \ ocaml_dynamic_cpp clean: - $(MAKE) -f $(TOP)/Makefile TARGET='$(TARGET)' ocaml_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' TARGET='$(TARGET)' ocaml_clean diff --git a/Examples/ocaml/stl/Makefile b/Examples/ocaml/stl/Makefile index a913611fb..e4cce4883 100644 --- a/Examples/ocaml/stl/Makefile +++ b/Examples/ocaml/stl/Makefile @@ -6,29 +6,29 @@ INTERFACE = example.i PROGFILE = runme.ml check: build - $(MAKE) -f $(TOP)/Makefile TARGET='$(TARGET)' ocaml_run + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' TARGET='$(TARGET)' ocaml_run build: static static: - $(MAKE) -f $(TOP)/Makefile SRCS='$(SRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SRCS='$(SRCS)' SWIG='$(SWIG)' \ PROGFILE='$(PROGFILE)' TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' \ ocaml_static_cpp director: - $(MAKE) -f $(TOP)/Makefile SRCS='$(SRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SRCS='$(SRCS)' SWIG='$(SWIG)' \ PROGFILE='$(PROGFILE)' TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' \ ocaml_static_cpp_director dynamic: - $(MAKE) -f $(TOP)/Makefile SRCS='$(SRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SRCS='$(SRCS)' SWIG='$(SWIG)' \ PROGFILE='$(PROGFILE)' TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' \ ocaml_static_cpp toplevel: - $(MAKE) -f $(TOP)/Makefile SRCS='$(SRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SRCS='$(SRCS)' SWIG='$(SWIG)' \ PROGFILE='$(PROGFILE)' TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' \ ocaml_static_cpp_toplevel clean: - $(MAKE) -f $(TOP)/Makefile TARGET='$(TARGET)' ocaml_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' TARGET='$(TARGET)' ocaml_clean diff --git a/Examples/ocaml/string_from_ptr/Makefile b/Examples/ocaml/string_from_ptr/Makefile index 6d344854a..294bdec83 100644 --- a/Examples/ocaml/string_from_ptr/Makefile +++ b/Examples/ocaml/string_from_ptr/Makefile @@ -9,27 +9,27 @@ PROGFILE = example_prog.ml OBJS = check: build - $(MAKE) -f $(TOP)/Makefile TARGET='$(TARGET)' ocaml_run + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' TARGET='$(TARGET)' ocaml_run build: static static_top static: - $(MAKE) -f $(TOP)/Makefile SRCS='$(SRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SRCS='$(SRCS)' SWIG='$(SWIG)' \ SWIGOPT='$(SWIGOPT)' TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' \ MLFILE='$(MLFILE)' PROGFILE='$(PROGFILE)' OBJS='$(OBJS)' \ ocaml_static_cpp static_top: - $(MAKE) -f $(TOP)/Makefile SRCS='$(SRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SRCS='$(SRCS)' SWIG='$(SWIG)' \ SWIGOPT='$(SWIGOPT)' TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' \ MLFILE='$(MLFILE)' PROGFILE='$(PROGFILE)' OBJS='$(OBJS)' \ ocaml_static_cpp_toplevel dynamic: - $(MAKE) -f $(TOP)/Makefile SRCS='$(SRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SRCS='$(SRCS)' SWIG='$(SWIG)' \ SWIGOPT='$(SWIGOPT)' TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' MLFILE='$(MLFILE)' PROGFILE='$(PROGFILE)' OBJS='$(OBJS)' \ ocaml_dynamic_cpp clean: - $(MAKE) -f $(TOP)/Makefile MLFILE='$(MLFILE)' ocaml_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' MLFILE='$(MLFILE)' ocaml_clean diff --git a/Examples/ocaml/strings_test/Makefile b/Examples/ocaml/strings_test/Makefile index 49cc544ed..b6b866669 100644 --- a/Examples/ocaml/strings_test/Makefile +++ b/Examples/ocaml/strings_test/Makefile @@ -6,24 +6,24 @@ INTERFACE = example.i PROGFILE = runme.ml check: build - $(MAKE) -f $(TOP)/Makefile TARGET='$(TARGET)' ocaml_run + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' TARGET='$(TARGET)' ocaml_run build: static top static: - $(MAKE) -f $(TOP)/Makefile SRCS='$(SRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SRCS='$(SRCS)' SWIG='$(SWIG)' \ PROGFILE='$(PROGFILE)' TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' \ ocaml_static_cpp dynamic: - $(MAKE) -f $(TOP)/Makefile SRCS='$(SRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SRCS='$(SRCS)' SWIG='$(SWIG)' \ PROGFILE='$(PROGFILE)' TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' \ ocaml_static_cpp top: - $(MAKE) -f $(TOP)/Makefile SRCS='$(SRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SRCS='$(SRCS)' SWIG='$(SWIG)' \ PROGFILE='$(PROGFILE)' TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' \ ocaml_static_cpp_toplevel clean: - $(MAKE) -f $(TOP)/Makefile TARGET='$(TARGET)' ocaml_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' TARGET='$(TARGET)' ocaml_clean diff --git a/Examples/octave/callback/Makefile b/Examples/octave/callback/Makefile index d38d7f896..7855d0617 100644 --- a/Examples/octave/callback/Makefile +++ b/Examples/octave/callback/Makefile @@ -7,11 +7,11 @@ LIBS = -lm SWIGOPT = check: build - $(MAKE) -f $(TOP)/Makefile octave_run + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' octave_run build: - $(MAKE) -f $(TOP)/Makefile $(SWIGLIB) CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' $(SWIGLIB) CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ SWIGOPT='$(SWIGOPT)' TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' octave_cpp clean: - $(MAKE) -f $(TOP)/Makefile octave_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' octave_clean diff --git a/Examples/octave/class/Makefile b/Examples/octave/class/Makefile index d38d7f896..7855d0617 100644 --- a/Examples/octave/class/Makefile +++ b/Examples/octave/class/Makefile @@ -7,11 +7,11 @@ LIBS = -lm SWIGOPT = check: build - $(MAKE) -f $(TOP)/Makefile octave_run + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' octave_run build: - $(MAKE) -f $(TOP)/Makefile $(SWIGLIB) CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' $(SWIGLIB) CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ SWIGOPT='$(SWIGOPT)' TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' octave_cpp clean: - $(MAKE) -f $(TOP)/Makefile octave_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' octave_clean diff --git a/Examples/octave/constants/Makefile b/Examples/octave/constants/Makefile index 03501bd81..eb05d1e7e 100644 --- a/Examples/octave/constants/Makefile +++ b/Examples/octave/constants/Makefile @@ -7,11 +7,11 @@ LIBS = -lm SWIGOPT = check: build - $(MAKE) -f $(TOP)/Makefile octave_run + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' octave_run build: - $(MAKE) -f $(TOP)/Makefile $(SWIGLIB) CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' $(SWIGLIB) CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ SWIGOPT='$(SWIGOPT)' TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' octave_cpp clean: - $(MAKE) -f $(TOP)/Makefile octave_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' octave_clean diff --git a/Examples/octave/contract/Makefile b/Examples/octave/contract/Makefile index 73e3962ed..2e0e82124 100644 --- a/Examples/octave/contract/Makefile +++ b/Examples/octave/contract/Makefile @@ -5,11 +5,11 @@ TARGET = swigexample INTERFACE = example.i check: build - $(MAKE) -f $(TOP)/Makefile octave_run + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' octave_run build: - $(MAKE) -f $(TOP)/Makefile SRCS='$(SRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SRCS='$(SRCS)' SWIG='$(SWIG)' \ TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' octave clean: - $(MAKE) -f $(TOP)/Makefile octave_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' octave_clean diff --git a/Examples/octave/enum/Makefile b/Examples/octave/enum/Makefile index d38d7f896..7855d0617 100644 --- a/Examples/octave/enum/Makefile +++ b/Examples/octave/enum/Makefile @@ -7,11 +7,11 @@ LIBS = -lm SWIGOPT = check: build - $(MAKE) -f $(TOP)/Makefile octave_run + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' octave_run build: - $(MAKE) -f $(TOP)/Makefile $(SWIGLIB) CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' $(SWIGLIB) CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ SWIGOPT='$(SWIGOPT)' TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' octave_cpp clean: - $(MAKE) -f $(TOP)/Makefile octave_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' octave_clean diff --git a/Examples/octave/extend/Makefile b/Examples/octave/extend/Makefile index d38d7f896..7855d0617 100644 --- a/Examples/octave/extend/Makefile +++ b/Examples/octave/extend/Makefile @@ -7,11 +7,11 @@ LIBS = -lm SWIGOPT = check: build - $(MAKE) -f $(TOP)/Makefile octave_run + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' octave_run build: - $(MAKE) -f $(TOP)/Makefile $(SWIGLIB) CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' $(SWIGLIB) CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ SWIGOPT='$(SWIGOPT)' TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' octave_cpp clean: - $(MAKE) -f $(TOP)/Makefile octave_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' octave_clean diff --git a/Examples/octave/funcptr/Makefile b/Examples/octave/funcptr/Makefile index 73e3962ed..2e0e82124 100644 --- a/Examples/octave/funcptr/Makefile +++ b/Examples/octave/funcptr/Makefile @@ -5,11 +5,11 @@ TARGET = swigexample INTERFACE = example.i check: build - $(MAKE) -f $(TOP)/Makefile octave_run + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' octave_run build: - $(MAKE) -f $(TOP)/Makefile SRCS='$(SRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SRCS='$(SRCS)' SWIG='$(SWIG)' \ TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' octave clean: - $(MAKE) -f $(TOP)/Makefile octave_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' octave_clean diff --git a/Examples/octave/funcptr2/Makefile b/Examples/octave/funcptr2/Makefile index 73e3962ed..2e0e82124 100644 --- a/Examples/octave/funcptr2/Makefile +++ b/Examples/octave/funcptr2/Makefile @@ -5,11 +5,11 @@ TARGET = swigexample INTERFACE = example.i check: build - $(MAKE) -f $(TOP)/Makefile octave_run + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' octave_run build: - $(MAKE) -f $(TOP)/Makefile SRCS='$(SRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SRCS='$(SRCS)' SWIG='$(SWIG)' \ TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' octave clean: - $(MAKE) -f $(TOP)/Makefile octave_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' octave_clean diff --git a/Examples/octave/functor/Makefile b/Examples/octave/functor/Makefile index 94fb96337..0fbc7586b 100644 --- a/Examples/octave/functor/Makefile +++ b/Examples/octave/functor/Makefile @@ -7,11 +7,11 @@ LIBS = -lm SWIGOPT = check: build - $(MAKE) -f $(TOP)/Makefile octave_run + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' octave_run build: - $(MAKE) -f $(TOP)/Makefile CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ SWIGOPT='$(SWIGOPT)' TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' octave_cpp clean: - $(MAKE) -f $(TOP)/Makefile octave_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' octave_clean diff --git a/Examples/octave/module_load/Makefile b/Examples/octave/module_load/Makefile index e388763bd..7b24a8530 100644 --- a/Examples/octave/module_load/Makefile +++ b/Examples/octave/module_load/Makefile @@ -5,14 +5,14 @@ TARGET = swigexample INTERFACE = example.i check: build - $(MAKE) -f $(TOP)/Makefile octave_run + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' octave_run build: - $(MAKE) -f $(TOP)/Makefile SRCS='$(SRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SRCS='$(SRCS)' SWIG='$(SWIG)' \ TARGET='$(TARGET)' SWIGOPT='-module $$(TARGET)' INTERFACE='$(INTERFACE)' octave - $(MAKE) -f $(TOP)/Makefile SRCS='$(SRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SRCS='$(SRCS)' SWIG='$(SWIG)' \ TARGET='$(TARGET)2' SWIGOPT='-module $$(TARGET) -globals .' INTERFACE='$(INTERFACE)' octave clean: - $(MAKE) -f $(TOP)/Makefile octave_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' octave_clean rm -f $(TARGET).m diff --git a/Examples/octave/operator/Makefile b/Examples/octave/operator/Makefile index 94fb96337..0fbc7586b 100644 --- a/Examples/octave/operator/Makefile +++ b/Examples/octave/operator/Makefile @@ -7,11 +7,11 @@ LIBS = -lm SWIGOPT = check: build - $(MAKE) -f $(TOP)/Makefile octave_run + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' octave_run build: - $(MAKE) -f $(TOP)/Makefile CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ SWIGOPT='$(SWIGOPT)' TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' octave_cpp clean: - $(MAKE) -f $(TOP)/Makefile octave_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' octave_clean diff --git a/Examples/octave/pointer/Makefile b/Examples/octave/pointer/Makefile index 73e3962ed..2e0e82124 100644 --- a/Examples/octave/pointer/Makefile +++ b/Examples/octave/pointer/Makefile @@ -5,11 +5,11 @@ TARGET = swigexample INTERFACE = example.i check: build - $(MAKE) -f $(TOP)/Makefile octave_run + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' octave_run build: - $(MAKE) -f $(TOP)/Makefile SRCS='$(SRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SRCS='$(SRCS)' SWIG='$(SWIG)' \ TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' octave clean: - $(MAKE) -f $(TOP)/Makefile octave_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' octave_clean diff --git a/Examples/octave/reference/Makefile b/Examples/octave/reference/Makefile index d38d7f896..7855d0617 100644 --- a/Examples/octave/reference/Makefile +++ b/Examples/octave/reference/Makefile @@ -7,11 +7,11 @@ LIBS = -lm SWIGOPT = check: build - $(MAKE) -f $(TOP)/Makefile octave_run + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' octave_run build: - $(MAKE) -f $(TOP)/Makefile $(SWIGLIB) CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' $(SWIGLIB) CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ SWIGOPT='$(SWIGOPT)' TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' octave_cpp clean: - $(MAKE) -f $(TOP)/Makefile octave_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' octave_clean diff --git a/Examples/octave/simple/Makefile b/Examples/octave/simple/Makefile index 73e3962ed..2e0e82124 100644 --- a/Examples/octave/simple/Makefile +++ b/Examples/octave/simple/Makefile @@ -5,11 +5,11 @@ TARGET = swigexample INTERFACE = example.i check: build - $(MAKE) -f $(TOP)/Makefile octave_run + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' octave_run build: - $(MAKE) -f $(TOP)/Makefile SRCS='$(SRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SRCS='$(SRCS)' SWIG='$(SWIG)' \ TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' octave clean: - $(MAKE) -f $(TOP)/Makefile octave_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' octave_clean diff --git a/Examples/octave/template/Makefile b/Examples/octave/template/Makefile index 94fb96337..0fbc7586b 100644 --- a/Examples/octave/template/Makefile +++ b/Examples/octave/template/Makefile @@ -7,11 +7,11 @@ LIBS = -lm SWIGOPT = check: build - $(MAKE) -f $(TOP)/Makefile octave_run + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' octave_run build: - $(MAKE) -f $(TOP)/Makefile CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ SWIGOPT='$(SWIGOPT)' TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' octave_cpp clean: - $(MAKE) -f $(TOP)/Makefile octave_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' octave_clean diff --git a/Examples/octave/variables/Makefile b/Examples/octave/variables/Makefile index 73e3962ed..2e0e82124 100644 --- a/Examples/octave/variables/Makefile +++ b/Examples/octave/variables/Makefile @@ -5,11 +5,11 @@ TARGET = swigexample INTERFACE = example.i check: build - $(MAKE) -f $(TOP)/Makefile octave_run + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' octave_run build: - $(MAKE) -f $(TOP)/Makefile SRCS='$(SRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SRCS='$(SRCS)' SWIG='$(SWIG)' \ TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' octave clean: - $(MAKE) -f $(TOP)/Makefile octave_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' octave_clean diff --git a/Examples/perl5/callback/Makefile b/Examples/perl5/callback/Makefile index 544d13642..0d1cc574f 100644 --- a/Examples/perl5/callback/Makefile +++ b/Examples/perl5/callback/Makefile @@ -6,15 +6,15 @@ INTERFACE = example.i LIBS = -lm check: build - $(MAKE) -f $(TOP)/Makefile perl5_run + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' perl5_run build: - $(MAKE) -f $(TOP)/Makefile CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' perl5_cpp static: - $(MAKE) -f $(TOP)/Makefile CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ TARGET='myperl' INTERFACE='$(INTERFACE)' perl5_cpp_static clean: - $(MAKE) -f $(TOP)/Makefile perl5_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' perl5_clean diff --git a/Examples/perl5/class/Makefile b/Examples/perl5/class/Makefile index 544d13642..0d1cc574f 100644 --- a/Examples/perl5/class/Makefile +++ b/Examples/perl5/class/Makefile @@ -6,15 +6,15 @@ INTERFACE = example.i LIBS = -lm check: build - $(MAKE) -f $(TOP)/Makefile perl5_run + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' perl5_run build: - $(MAKE) -f $(TOP)/Makefile CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' perl5_cpp static: - $(MAKE) -f $(TOP)/Makefile CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ TARGET='myperl' INTERFACE='$(INTERFACE)' perl5_cpp_static clean: - $(MAKE) -f $(TOP)/Makefile perl5_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' perl5_clean diff --git a/Examples/perl5/constants/Makefile b/Examples/perl5/constants/Makefile index 899282913..b7b411534 100644 --- a/Examples/perl5/constants/Makefile +++ b/Examples/perl5/constants/Makefile @@ -6,15 +6,15 @@ INTERFACE = example.i SWIGOPT = check: build - $(MAKE) -f $(TOP)/Makefile perl5_run + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' perl5_run build: - $(MAKE) -f $(TOP)/Makefile SRCS='$(SRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SRCS='$(SRCS)' SWIG='$(SWIG)' \ SWIGOPT='$(SWIGOPT)' TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' perl5 static: - $(MAKE) -f $(TOP)/Makefile SRCS='$(SRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SRCS='$(SRCS)' SWIG='$(SWIG)' \ SWIGOPT='$(SWIGOPT)' TARGET='myperl' INTERFACE='$(INTERFACE)' perl5_static clean: - $(MAKE) -f $(TOP)/Makefile perl5_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' perl5_clean diff --git a/Examples/perl5/constants2/Makefile b/Examples/perl5/constants2/Makefile index 2ed10d733..85dd13741 100644 --- a/Examples/perl5/constants2/Makefile +++ b/Examples/perl5/constants2/Makefile @@ -6,15 +6,15 @@ INTERFACE = example.i SWIGOPT = -const check: build - $(MAKE) -f $(TOP)/Makefile perl5_run + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' perl5_run build: - $(MAKE) -f $(TOP)/Makefile SRCS='$(SRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SRCS='$(SRCS)' SWIG='$(SWIG)' \ SWIGOPT='$(SWIGOPT)' TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' perl5 static: - $(MAKE) -f $(TOP)/Makefile SRCS='$(SRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SRCS='$(SRCS)' SWIG='$(SWIG)' \ SWIGOPT='$(SWIGOPT)' TARGET='myperl' INTERFACE='$(INTERFACE)' perl5_static clean: - $(MAKE) -f $(TOP)/Makefile perl5_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' perl5_clean diff --git a/Examples/perl5/extend/Makefile b/Examples/perl5/extend/Makefile index 544d13642..0d1cc574f 100644 --- a/Examples/perl5/extend/Makefile +++ b/Examples/perl5/extend/Makefile @@ -6,15 +6,15 @@ INTERFACE = example.i LIBS = -lm check: build - $(MAKE) -f $(TOP)/Makefile perl5_run + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' perl5_run build: - $(MAKE) -f $(TOP)/Makefile CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' perl5_cpp static: - $(MAKE) -f $(TOP)/Makefile CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ TARGET='myperl' INTERFACE='$(INTERFACE)' perl5_cpp_static clean: - $(MAKE) -f $(TOP)/Makefile perl5_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' perl5_clean diff --git a/Examples/perl5/funcptr/Makefile b/Examples/perl5/funcptr/Makefile index 366b5897c..3e1de1fc1 100644 --- a/Examples/perl5/funcptr/Makefile +++ b/Examples/perl5/funcptr/Makefile @@ -6,15 +6,15 @@ INTERFACE = example.i SWIGOPT = check: build - $(MAKE) -f $(TOP)/Makefile perl5_run + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' perl5_run build: - $(MAKE) -f $(TOP)/Makefile SRCS='$(SRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SRCS='$(SRCS)' SWIG='$(SWIG)' \ SWIGOPT='$(SWIGOPT)' TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' perl5 static: - $(MAKE) -f $(TOP)/Makefile SRCS='$(SRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SRCS='$(SRCS)' SWIG='$(SWIG)' \ SWIGOPT='$(SWIGOPT)' TARGET='myperl' INTERFACE='$(INTERFACE)' perl5_static clean: - $(MAKE) -f $(TOP)/Makefile perl5_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' perl5_clean diff --git a/Examples/perl5/import/Makefile b/Examples/perl5/import/Makefile index baa8277fd..b31ab7952 100644 --- a/Examples/perl5/import/Makefile +++ b/Examples/perl5/import/Makefile @@ -4,17 +4,17 @@ SWIGOPT = LIBS = check: build - $(MAKE) -f $(TOP)/Makefile perl5_run + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' perl5_run build: - $(MAKE) -f $(TOP)/Makefile SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT)' \ LIBS='$(LIBS)' TARGET='baseclass' INTERFACE='base.i' perl5_cpp - $(MAKE) -f $(TOP)/Makefile SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT)' \ LIBS='$(LIBS)' TARGET='foo' INTERFACE='foo.i' perl5_cpp - $(MAKE) -f $(TOP)/Makefile SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT)' \ LIBS='$(LIBS)' TARGET='bar' INTERFACE='bar.i' perl5_cpp - $(MAKE) -f $(TOP)/Makefile SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT)' \ LIBS='$(LIBS)' TARGET='spam' INTERFACE='spam.i' perl5_cpp clean: - $(MAKE) -f $(TOP)/Makefile perl5_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' perl5_clean diff --git a/Examples/perl5/inline/Makefile b/Examples/perl5/inline/Makefile index d544a6532..5c98748c1 100644 --- a/Examples/perl5/inline/Makefile +++ b/Examples/perl5/inline/Makefile @@ -1,6 +1,6 @@ run: - $(MAKE) -f $(TOP)/Makefile perl5_run + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' perl5_run clean: - $(MAKE) -f $(TOP)/Makefile perl5_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' perl5_clean rm -rf _Inline diff --git a/Examples/perl5/java/Makefile b/Examples/perl5/java/Makefile index 3a0bb215d..5eaea3212 100644 --- a/Examples/perl5/java/Makefile +++ b/Examples/perl5/java/Makefile @@ -6,17 +6,17 @@ INTERFACE = example.i LIBS = -lm check: build - $(MAKE) -f $(TOP)/Makefile perl5_run + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' perl5_run build: Example.class Example.h - $(MAKE) -f $(TOP)/Makefile CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' \ CXXSHARED="gcj -fpic -shared Example.class" PERL5_CCFLAGS='' PERL5_EXP='' LIBS="-lstdc++" perl5_cpp clean: - $(MAKE) -f $(TOP)/Makefile perl5_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' perl5_clean rm -f *.class Example.h -Example.class Example.h: Example.java - gcj -fPIC -C -c -g Example.java +Example.class Example.h: $(SRCDIR)Example.java + gcj -d . -fPIC -C -c -g $(SRCDIR)Example.java gcjh Example.class diff --git a/Examples/perl5/multimap/Makefile b/Examples/perl5/multimap/Makefile index 366b5897c..3e1de1fc1 100644 --- a/Examples/perl5/multimap/Makefile +++ b/Examples/perl5/multimap/Makefile @@ -6,15 +6,15 @@ INTERFACE = example.i SWIGOPT = check: build - $(MAKE) -f $(TOP)/Makefile perl5_run + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' perl5_run build: - $(MAKE) -f $(TOP)/Makefile SRCS='$(SRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SRCS='$(SRCS)' SWIG='$(SWIG)' \ SWIGOPT='$(SWIGOPT)' TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' perl5 static: - $(MAKE) -f $(TOP)/Makefile SRCS='$(SRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SRCS='$(SRCS)' SWIG='$(SWIG)' \ SWIGOPT='$(SWIGOPT)' TARGET='myperl' INTERFACE='$(INTERFACE)' perl5_static clean: - $(MAKE) -f $(TOP)/Makefile perl5_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' perl5_clean diff --git a/Examples/perl5/multiple_inheritance/Makefile b/Examples/perl5/multiple_inheritance/Makefile index 62355a82c..1fe5a51bb 100644 --- a/Examples/perl5/multiple_inheritance/Makefile +++ b/Examples/perl5/multiple_inheritance/Makefile @@ -6,15 +6,15 @@ INTERFACE = example.i LIBS = check: build - $(MAKE) -f $(TOP)/Makefile perl5_run + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' perl5_run build: - $(MAKE) -f $(TOP)/Makefile CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' perl5_cpp static: - $(MAKE) -f $(TOP)/Makefile CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ TARGET='myperl' INTERFACE='$(INTERFACE)' perl5_cpp_static clean: - $(MAKE) -f $(TOP)/Makefile perl5_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' perl5_clean diff --git a/Examples/perl5/pointer/Makefile b/Examples/perl5/pointer/Makefile index 366b5897c..3e1de1fc1 100644 --- a/Examples/perl5/pointer/Makefile +++ b/Examples/perl5/pointer/Makefile @@ -6,15 +6,15 @@ INTERFACE = example.i SWIGOPT = check: build - $(MAKE) -f $(TOP)/Makefile perl5_run + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' perl5_run build: - $(MAKE) -f $(TOP)/Makefile SRCS='$(SRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SRCS='$(SRCS)' SWIG='$(SWIG)' \ SWIGOPT='$(SWIGOPT)' TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' perl5 static: - $(MAKE) -f $(TOP)/Makefile SRCS='$(SRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SRCS='$(SRCS)' SWIG='$(SWIG)' \ SWIGOPT='$(SWIGOPT)' TARGET='myperl' INTERFACE='$(INTERFACE)' perl5_static clean: - $(MAKE) -f $(TOP)/Makefile perl5_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' perl5_clean diff --git a/Examples/perl5/reference/Makefile b/Examples/perl5/reference/Makefile index 986fab86a..a22f5a68d 100644 --- a/Examples/perl5/reference/Makefile +++ b/Examples/perl5/reference/Makefile @@ -7,15 +7,15 @@ LIBS = -lm SWIGOPT = -noproxy check: build - $(MAKE) -f $(TOP)/Makefile perl5_run + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' perl5_run build: - $(MAKE) -f $(TOP)/Makefile CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' SWIGOPT='$(SWIGOPT)' perl5_cpp static: - $(MAKE) -f $(TOP)/Makefile CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ TARGET='myperl' INTERFACE='$(INTERFACE)' SWIGOPT='$(SWIGOPT)' perl5_cpp_static clean: - $(MAKE) -f $(TOP)/Makefile perl5_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' perl5_clean diff --git a/Examples/perl5/simple/Makefile b/Examples/perl5/simple/Makefile index 366b5897c..3e1de1fc1 100644 --- a/Examples/perl5/simple/Makefile +++ b/Examples/perl5/simple/Makefile @@ -6,15 +6,15 @@ INTERFACE = example.i SWIGOPT = check: build - $(MAKE) -f $(TOP)/Makefile perl5_run + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' perl5_run build: - $(MAKE) -f $(TOP)/Makefile SRCS='$(SRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SRCS='$(SRCS)' SWIG='$(SWIG)' \ SWIGOPT='$(SWIGOPT)' TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' perl5 static: - $(MAKE) -f $(TOP)/Makefile SRCS='$(SRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SRCS='$(SRCS)' SWIG='$(SWIG)' \ SWIGOPT='$(SWIGOPT)' TARGET='myperl' INTERFACE='$(INTERFACE)' perl5_static clean: - $(MAKE) -f $(TOP)/Makefile perl5_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' perl5_clean diff --git a/Examples/perl5/value/Makefile b/Examples/perl5/value/Makefile index 366b5897c..3e1de1fc1 100644 --- a/Examples/perl5/value/Makefile +++ b/Examples/perl5/value/Makefile @@ -6,15 +6,15 @@ INTERFACE = example.i SWIGOPT = check: build - $(MAKE) -f $(TOP)/Makefile perl5_run + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' perl5_run build: - $(MAKE) -f $(TOP)/Makefile SRCS='$(SRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SRCS='$(SRCS)' SWIG='$(SWIG)' \ SWIGOPT='$(SWIGOPT)' TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' perl5 static: - $(MAKE) -f $(TOP)/Makefile SRCS='$(SRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SRCS='$(SRCS)' SWIG='$(SWIG)' \ SWIGOPT='$(SWIGOPT)' TARGET='myperl' INTERFACE='$(INTERFACE)' perl5_static clean: - $(MAKE) -f $(TOP)/Makefile perl5_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' perl5_clean diff --git a/Examples/perl5/variables/Makefile b/Examples/perl5/variables/Makefile index 366b5897c..3e1de1fc1 100644 --- a/Examples/perl5/variables/Makefile +++ b/Examples/perl5/variables/Makefile @@ -6,15 +6,15 @@ INTERFACE = example.i SWIGOPT = check: build - $(MAKE) -f $(TOP)/Makefile perl5_run + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' perl5_run build: - $(MAKE) -f $(TOP)/Makefile SRCS='$(SRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SRCS='$(SRCS)' SWIG='$(SWIG)' \ SWIGOPT='$(SWIGOPT)' TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' perl5 static: - $(MAKE) -f $(TOP)/Makefile SRCS='$(SRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SRCS='$(SRCS)' SWIG='$(SWIG)' \ SWIGOPT='$(SWIGOPT)' TARGET='myperl' INTERFACE='$(INTERFACE)' perl5_static clean: - $(MAKE) -f $(TOP)/Makefile perl5_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' perl5_clean diff --git a/Examples/perl5/xmlstring/Makefile b/Examples/perl5/xmlstring/Makefile index df9dabd11..4f02d3ee4 100644 --- a/Examples/perl5/xmlstring/Makefile +++ b/Examples/perl5/xmlstring/Makefile @@ -6,15 +6,15 @@ INTERFACE = example.i LIBS = -lxerces-c -lxerces-depdom -lm check: build - $(MAKE) -f $(TOP)/Makefile perl5_run + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' perl5_run build: - $(MAKE) -f $(TOP)/Makefile CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' LIBS=$(LIBS) CXX="g++ -g3" perl5_cpp static: - $(MAKE) -f $(TOP)/Makefile CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ TARGET='myperl' INTERFACE='$(INTERFACE)' perl5_cpp_static clean: - $(MAKE) -f $(TOP)/Makefile perl5_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' perl5_clean diff --git a/Examples/php/callback/Makefile b/Examples/php/callback/Makefile index 6f7e4ad27..3ad3999a5 100644 --- a/Examples/php/callback/Makefile +++ b/Examples/php/callback/Makefile @@ -7,15 +7,15 @@ LIBS = -lm SWIGOPT = check: build - $(MAKE) -f $(TOP)/Makefile php_run + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' php_run build: - $(MAKE) -f $(TOP)/Makefile $(SWIGLIB) CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' $(SWIGLIB) CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ SWIGOPT='$(SWIGOPT)' TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' php_cpp static: - $(MAKE) -f $(TOP)/Makefile $(SWIGLIB) CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' $(SWIGLIB) CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ SWIGOPT='$(SWIGOPT)' TARGET='myphp' INTERFACE='$(INTERFACE)' php_cpp_static clean: - $(MAKE) -f $(TOP)/Makefile php_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' php_clean diff --git a/Examples/php/class/Makefile b/Examples/php/class/Makefile index cefd81f78..8b2b340e9 100644 --- a/Examples/php/class/Makefile +++ b/Examples/php/class/Makefile @@ -7,17 +7,17 @@ LIBS = SWIGOPT = check: build - $(MAKE) -f $(TOP)/Makefile php_run + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' php_run build: - $(MAKE) -f $(TOP)/Makefile CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ SWIGOPT='$(SWIGOPT)' TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' \ php_cpp static: - $(MAKE) -f $(TOP)/Makefile CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ SWIGOPT='$(SWIGOPT)' TARGET='myphp' INTERFACE='$(INTERFACE)' \ php_cpp_static clean: - $(MAKE) -f $(TOP)/Makefile php_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' php_clean diff --git a/Examples/php/constants/Makefile b/Examples/php/constants/Makefile index 3f24a3921..e5b49571e 100644 --- a/Examples/php/constants/Makefile +++ b/Examples/php/constants/Makefile @@ -7,17 +7,17 @@ LIBS = SWIGOPT = check: build - $(MAKE) -f $(TOP)/Makefile php_run + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' php_run build: - $(MAKE) -f $(TOP)/Makefile SRCS='$(SRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SRCS='$(SRCS)' SWIG='$(SWIG)' \ SWIGOPT='$(SWIGOPT)' TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' \ php static: - $(MAKE) -f $(TOP)/Makefile SRCS='$(SRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SRCS='$(SRCS)' SWIG='$(SWIG)' \ SWIGOPT='$(SWIGOPT)' TARGET='myphp' INTERFACE='$(INTERFACE)' \ php_static clean: - $(MAKE) -f $(TOP)/Makefile php_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' php_clean diff --git a/Examples/php/cpointer/Makefile b/Examples/php/cpointer/Makefile index 57785acc7..f2c15c5c1 100644 --- a/Examples/php/cpointer/Makefile +++ b/Examples/php/cpointer/Makefile @@ -7,17 +7,17 @@ LIBS = SWIGOPT = check: build - $(MAKE) -f $(TOP)/Makefile php_run + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' php_run build: - $(MAKE) -f $(TOP)/Makefile SRCS='$(SRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SRCS='$(SRCS)' SWIG='$(SWIG)' \ SWIGOPT='$(SWIGOPT)' TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' \ php static: - $(MAKE) -f $(TOP)/Makefile SRCS='$(SRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SRCS='$(SRCS)' SWIG='$(SWIG)' \ SWIGOPT='$(SWIGOPT)' TARGET='myphp' INTERFACE='$(INTERFACE)' \ php_static clean: - $(MAKE) -f $(TOP)/Makefile php_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' php_clean diff --git a/Examples/php/disown/Makefile b/Examples/php/disown/Makefile index cefd81f78..8b2b340e9 100644 --- a/Examples/php/disown/Makefile +++ b/Examples/php/disown/Makefile @@ -7,17 +7,17 @@ LIBS = SWIGOPT = check: build - $(MAKE) -f $(TOP)/Makefile php_run + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' php_run build: - $(MAKE) -f $(TOP)/Makefile CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ SWIGOPT='$(SWIGOPT)' TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' \ php_cpp static: - $(MAKE) -f $(TOP)/Makefile CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ SWIGOPT='$(SWIGOPT)' TARGET='myphp' INTERFACE='$(INTERFACE)' \ php_cpp_static clean: - $(MAKE) -f $(TOP)/Makefile php_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' php_clean diff --git a/Examples/php/enum/Makefile b/Examples/php/enum/Makefile index 22f979d2f..2028d03c7 100644 --- a/Examples/php/enum/Makefile +++ b/Examples/php/enum/Makefile @@ -7,17 +7,17 @@ LIBS = SWIGOPT = -noproxy check: build - $(MAKE) -f $(TOP)/Makefile php_run + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' php_run build: - $(MAKE) -f $(TOP)/Makefile CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ SWIGOPT='$(SWIGOPT)' TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' \ php_cpp static: - $(MAKE) -f $(TOP)/Makefile CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ SWIGOPT='$(SWIGOPT)' TARGET='myphp' INTERFACE='$(INTERFACE)' \ php_cpp_static clean: - $(MAKE) -f $(TOP)/Makefile php_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' php_clean diff --git a/Examples/php/extend/Makefile b/Examples/php/extend/Makefile index 6f7e4ad27..3ad3999a5 100644 --- a/Examples/php/extend/Makefile +++ b/Examples/php/extend/Makefile @@ -7,15 +7,15 @@ LIBS = -lm SWIGOPT = check: build - $(MAKE) -f $(TOP)/Makefile php_run + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' php_run build: - $(MAKE) -f $(TOP)/Makefile $(SWIGLIB) CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' $(SWIGLIB) CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ SWIGOPT='$(SWIGOPT)' TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' php_cpp static: - $(MAKE) -f $(TOP)/Makefile $(SWIGLIB) CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' $(SWIGLIB) CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ SWIGOPT='$(SWIGOPT)' TARGET='myphp' INTERFACE='$(INTERFACE)' php_cpp_static clean: - $(MAKE) -f $(TOP)/Makefile php_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' php_clean diff --git a/Examples/php/funcptr/Makefile b/Examples/php/funcptr/Makefile index 57785acc7..f2c15c5c1 100644 --- a/Examples/php/funcptr/Makefile +++ b/Examples/php/funcptr/Makefile @@ -7,17 +7,17 @@ LIBS = SWIGOPT = check: build - $(MAKE) -f $(TOP)/Makefile php_run + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' php_run build: - $(MAKE) -f $(TOP)/Makefile SRCS='$(SRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SRCS='$(SRCS)' SWIG='$(SWIG)' \ SWIGOPT='$(SWIGOPT)' TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' \ php static: - $(MAKE) -f $(TOP)/Makefile SRCS='$(SRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SRCS='$(SRCS)' SWIG='$(SWIG)' \ SWIGOPT='$(SWIGOPT)' TARGET='myphp' INTERFACE='$(INTERFACE)' \ php_static clean: - $(MAKE) -f $(TOP)/Makefile php_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' php_clean diff --git a/Examples/php/overloading/Makefile b/Examples/php/overloading/Makefile index cefd81f78..8b2b340e9 100644 --- a/Examples/php/overloading/Makefile +++ b/Examples/php/overloading/Makefile @@ -7,17 +7,17 @@ LIBS = SWIGOPT = check: build - $(MAKE) -f $(TOP)/Makefile php_run + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' php_run build: - $(MAKE) -f $(TOP)/Makefile CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ SWIGOPT='$(SWIGOPT)' TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' \ php_cpp static: - $(MAKE) -f $(TOP)/Makefile CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ SWIGOPT='$(SWIGOPT)' TARGET='myphp' INTERFACE='$(INTERFACE)' \ php_cpp_static clean: - $(MAKE) -f $(TOP)/Makefile php_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' php_clean diff --git a/Examples/php/pointer/Makefile b/Examples/php/pointer/Makefile index 57785acc7..f2c15c5c1 100644 --- a/Examples/php/pointer/Makefile +++ b/Examples/php/pointer/Makefile @@ -7,17 +7,17 @@ LIBS = SWIGOPT = check: build - $(MAKE) -f $(TOP)/Makefile php_run + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' php_run build: - $(MAKE) -f $(TOP)/Makefile SRCS='$(SRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SRCS='$(SRCS)' SWIG='$(SWIG)' \ SWIGOPT='$(SWIGOPT)' TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' \ php static: - $(MAKE) -f $(TOP)/Makefile SRCS='$(SRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SRCS='$(SRCS)' SWIG='$(SWIG)' \ SWIGOPT='$(SWIGOPT)' TARGET='myphp' INTERFACE='$(INTERFACE)' \ php_static clean: - $(MAKE) -f $(TOP)/Makefile php_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' php_clean diff --git a/Examples/php/pragmas/Makefile b/Examples/php/pragmas/Makefile index 3f24a3921..e5b49571e 100644 --- a/Examples/php/pragmas/Makefile +++ b/Examples/php/pragmas/Makefile @@ -7,17 +7,17 @@ LIBS = SWIGOPT = check: build - $(MAKE) -f $(TOP)/Makefile php_run + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' php_run build: - $(MAKE) -f $(TOP)/Makefile SRCS='$(SRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SRCS='$(SRCS)' SWIG='$(SWIG)' \ SWIGOPT='$(SWIGOPT)' TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' \ php static: - $(MAKE) -f $(TOP)/Makefile SRCS='$(SRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SRCS='$(SRCS)' SWIG='$(SWIG)' \ SWIGOPT='$(SWIGOPT)' TARGET='myphp' INTERFACE='$(INTERFACE)' \ php_static clean: - $(MAKE) -f $(TOP)/Makefile php_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' php_clean diff --git a/Examples/php/proxy/Makefile b/Examples/php/proxy/Makefile index cefd81f78..8b2b340e9 100644 --- a/Examples/php/proxy/Makefile +++ b/Examples/php/proxy/Makefile @@ -7,17 +7,17 @@ LIBS = SWIGOPT = check: build - $(MAKE) -f $(TOP)/Makefile php_run + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' php_run build: - $(MAKE) -f $(TOP)/Makefile CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ SWIGOPT='$(SWIGOPT)' TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' \ php_cpp static: - $(MAKE) -f $(TOP)/Makefile CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ SWIGOPT='$(SWIGOPT)' TARGET='myphp' INTERFACE='$(INTERFACE)' \ php_cpp_static clean: - $(MAKE) -f $(TOP)/Makefile php_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' php_clean diff --git a/Examples/php/reference/Makefile b/Examples/php/reference/Makefile index cefd81f78..8b2b340e9 100644 --- a/Examples/php/reference/Makefile +++ b/Examples/php/reference/Makefile @@ -7,17 +7,17 @@ LIBS = SWIGOPT = check: build - $(MAKE) -f $(TOP)/Makefile php_run + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' php_run build: - $(MAKE) -f $(TOP)/Makefile CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ SWIGOPT='$(SWIGOPT)' TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' \ php_cpp static: - $(MAKE) -f $(TOP)/Makefile CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ SWIGOPT='$(SWIGOPT)' TARGET='myphp' INTERFACE='$(INTERFACE)' \ php_cpp_static clean: - $(MAKE) -f $(TOP)/Makefile php_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' php_clean diff --git a/Examples/php/simple/Makefile b/Examples/php/simple/Makefile index 57785acc7..f2c15c5c1 100644 --- a/Examples/php/simple/Makefile +++ b/Examples/php/simple/Makefile @@ -7,17 +7,17 @@ LIBS = SWIGOPT = check: build - $(MAKE) -f $(TOP)/Makefile php_run + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' php_run build: - $(MAKE) -f $(TOP)/Makefile SRCS='$(SRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SRCS='$(SRCS)' SWIG='$(SWIG)' \ SWIGOPT='$(SWIGOPT)' TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' \ php static: - $(MAKE) -f $(TOP)/Makefile SRCS='$(SRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SRCS='$(SRCS)' SWIG='$(SWIG)' \ SWIGOPT='$(SWIGOPT)' TARGET='myphp' INTERFACE='$(INTERFACE)' \ php_static clean: - $(MAKE) -f $(TOP)/Makefile php_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' php_clean diff --git a/Examples/php/sync/Makefile b/Examples/php/sync/Makefile index cefd81f78..8b2b340e9 100644 --- a/Examples/php/sync/Makefile +++ b/Examples/php/sync/Makefile @@ -7,17 +7,17 @@ LIBS = SWIGOPT = check: build - $(MAKE) -f $(TOP)/Makefile php_run + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' php_run build: - $(MAKE) -f $(TOP)/Makefile CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ SWIGOPT='$(SWIGOPT)' TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' \ php_cpp static: - $(MAKE) -f $(TOP)/Makefile CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ SWIGOPT='$(SWIGOPT)' TARGET='myphp' INTERFACE='$(INTERFACE)' \ php_cpp_static clean: - $(MAKE) -f $(TOP)/Makefile php_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' php_clean diff --git a/Examples/php/value/Makefile b/Examples/php/value/Makefile index 449686784..3db7afec5 100644 --- a/Examples/php/value/Makefile +++ b/Examples/php/value/Makefile @@ -7,17 +7,17 @@ LIBS = SWIGOPT = -noproxy check: build - $(MAKE) -f $(TOP)/Makefile php_run + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' php_run build: - $(MAKE) -f $(TOP)/Makefile SRCS='$(SRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SRCS='$(SRCS)' SWIG='$(SWIG)' \ SWIGOPT='$(SWIGOPT)' TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' \ php static: - $(MAKE) -f $(TOP)/Makefile SRCS='$(SRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SRCS='$(SRCS)' SWIG='$(SWIG)' \ SWIGOPT='$(SWIGOPT)' TARGET='myphp' INTERFACE='$(INTERFACE)' \ php_static clean: - $(MAKE) -f $(TOP)/Makefile php_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' php_clean diff --git a/Examples/php/variables/Makefile b/Examples/php/variables/Makefile index 57785acc7..f2c15c5c1 100644 --- a/Examples/php/variables/Makefile +++ b/Examples/php/variables/Makefile @@ -7,17 +7,17 @@ LIBS = SWIGOPT = check: build - $(MAKE) -f $(TOP)/Makefile php_run + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' php_run build: - $(MAKE) -f $(TOP)/Makefile SRCS='$(SRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SRCS='$(SRCS)' SWIG='$(SWIG)' \ SWIGOPT='$(SWIGOPT)' TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' \ php static: - $(MAKE) -f $(TOP)/Makefile SRCS='$(SRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SRCS='$(SRCS)' SWIG='$(SWIG)' \ SWIGOPT='$(SWIGOPT)' TARGET='myphp' INTERFACE='$(INTERFACE)' \ php_static clean: - $(MAKE) -f $(TOP)/Makefile php_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' php_clean diff --git a/Examples/pike/class/Makefile b/Examples/pike/class/Makefile index aadc47151..d8cf4ea7e 100644 --- a/Examples/pike/class/Makefile +++ b/Examples/pike/class/Makefile @@ -6,15 +6,15 @@ INTERFACE = example.i LIBS = -lm check: build - $(MAKE) -f $(TOP)/Makefile pike_run + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' pike_run build: - $(MAKE) -f $(TOP)/Makefile CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' pike_cpp static: - $(MAKE) -f $(TOP)/Makefile CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ TARGET='mypike' INTERFACE='$(INTERFACE)' pike_cpp_static clean: - $(MAKE) -f $(TOP)/Makefile pike_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' pike_clean diff --git a/Examples/pike/constants/Makefile b/Examples/pike/constants/Makefile index c9385ce3b..736d30f03 100644 --- a/Examples/pike/constants/Makefile +++ b/Examples/pike/constants/Makefile @@ -5,15 +5,15 @@ TARGET = example INTERFACE = example.i check: build - $(MAKE) -f $(TOP)/Makefile pike_run + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' pike_run build: - $(MAKE) -f $(TOP)/Makefile SRCS='$(SRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SRCS='$(SRCS)' SWIG='$(SWIG)' \ TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' pike static: - $(MAKE) -f $(TOP)/Makefile SRCS='$(SRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SRCS='$(SRCS)' SWIG='$(SWIG)' \ TARGET='mypike' INTERFACE='$(INTERFACE)' pike_static clean: - $(MAKE) -f $(TOP)/Makefile pike_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' pike_clean diff --git a/Examples/pike/enum/Makefile b/Examples/pike/enum/Makefile index aadc47151..d8cf4ea7e 100644 --- a/Examples/pike/enum/Makefile +++ b/Examples/pike/enum/Makefile @@ -6,15 +6,15 @@ INTERFACE = example.i LIBS = -lm check: build - $(MAKE) -f $(TOP)/Makefile pike_run + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' pike_run build: - $(MAKE) -f $(TOP)/Makefile CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' pike_cpp static: - $(MAKE) -f $(TOP)/Makefile CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ TARGET='mypike' INTERFACE='$(INTERFACE)' pike_cpp_static clean: - $(MAKE) -f $(TOP)/Makefile pike_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' pike_clean diff --git a/Examples/pike/overload/Makefile b/Examples/pike/overload/Makefile index 8d799efe1..f111b1137 100644 --- a/Examples/pike/overload/Makefile +++ b/Examples/pike/overload/Makefile @@ -6,15 +6,15 @@ INTERFACE = example.i LIBS = -lstdc++ -lm check: build - $(MAKE) -f $(TOP)/Makefile pike_run + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' pike_run build: - $(MAKE) -f $(TOP)/Makefile CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' pike_cpp static: - $(MAKE) -f $(TOP)/Makefile CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ TARGET='mypike' INTERFACE='$(INTERFACE)' pike_cpp_static clean: - $(MAKE) -f $(TOP)/Makefile pike_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' pike_clean diff --git a/Examples/pike/simple/Makefile b/Examples/pike/simple/Makefile index f58ed4e65..d7f6b209e 100644 --- a/Examples/pike/simple/Makefile +++ b/Examples/pike/simple/Makefile @@ -5,15 +5,15 @@ TARGET = example INTERFACE = example.i check: build - $(MAKE) -f $(TOP)/Makefile pike_run + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' pike_run build: - $(MAKE) -f $(TOP)/Makefile SRCS='$(SRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SRCS='$(SRCS)' SWIG='$(SWIG)' \ TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' pike static: - $(MAKE) -f $(TOP)/Makefile SRCS='$(SRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SRCS='$(SRCS)' SWIG='$(SWIG)' \ TARGET='mypike' INTERFACE='$(INTERFACE)' pike_static clean: - $(MAKE) -f $(TOP)/Makefile pike_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' pike_clean diff --git a/Examples/pike/template/Makefile b/Examples/pike/template/Makefile index e4fc945f7..da115c1d5 100644 --- a/Examples/pike/template/Makefile +++ b/Examples/pike/template/Makefile @@ -7,15 +7,15 @@ LIBS = -lm SWIGOPT = check: build - $(MAKE) -f $(TOP)/Makefile pike_run + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' pike_run build: - $(MAKE) -f $(TOP)/Makefile CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ SWIGOPT='$(SWIGOPT)' TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' pike_cpp static: - $(MAKE) -f $(TOP)/Makefile CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ SWIGOPT='$(SWIGOPT)' TARGET='mypike' INTERFACE='$(INTERFACE)' pike_cpp_static clean: - $(MAKE) -f $(TOP)/Makefile pike_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' pike_clean diff --git a/Examples/python/callback/Makefile b/Examples/python/callback/Makefile index 684995801..a4c4d2a69 100644 --- a/Examples/python/callback/Makefile +++ b/Examples/python/callback/Makefile @@ -7,15 +7,15 @@ LIBS = -lm SWIGOPT = check: build - $(MAKE) -f $(TOP)/Makefile python_run + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' python_run build: - $(MAKE) -f $(TOP)/Makefile $(SWIGLIB) CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' $(SWIGLIB) CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ SWIGOPT='$(SWIGOPT)' TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' python_cpp static: - $(MAKE) -f $(TOP)/Makefile $(SWIGLIB) CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' $(SWIGLIB) CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ SWIGOPT='$(SWIGOPT)' TARGET='mypython' INTERFACE='$(INTERFACE)' python_cpp_static clean: - $(MAKE) -f $(TOP)/Makefile TARGET='$(TARGET)' python_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' TARGET='$(TARGET)' python_clean diff --git a/Examples/python/class/Makefile b/Examples/python/class/Makefile index e940c1f43..41cded284 100644 --- a/Examples/python/class/Makefile +++ b/Examples/python/class/Makefile @@ -6,15 +6,15 @@ INTERFACE = example.i LIBS = -lm check: build - $(MAKE) -f $(TOP)/Makefile python_run + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' python_run build: - $(MAKE) -f $(TOP)/Makefile CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' python_cpp static: - $(MAKE) -f $(TOP)/Makefile CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ TARGET='mypython' INTERFACE='$(INTERFACE)' python_cpp_static clean: - $(MAKE) -f $(TOP)/Makefile TARGET='$(TARGET)' python_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' TARGET='$(TARGET)' python_clean diff --git a/Examples/python/constants/Makefile b/Examples/python/constants/Makefile index 15ffa24c9..8ec6e9cc9 100644 --- a/Examples/python/constants/Makefile +++ b/Examples/python/constants/Makefile @@ -5,15 +5,15 @@ TARGET = example INTERFACE = example.i check: build - $(MAKE) -f $(TOP)/Makefile python_run + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' python_run build: - $(MAKE) -f $(TOP)/Makefile SRCS='$(SRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SRCS='$(SRCS)' SWIG='$(SWIG)' \ TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' python static: - $(MAKE) -f $(TOP)/Makefile SRCS='$(SRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SRCS='$(SRCS)' SWIG='$(SWIG)' \ TARGET='mypython' INTERFACE='$(INTERFACE)' python_static clean: - $(MAKE) -f $(TOP)/Makefile TARGET='$(TARGET)' python_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' TARGET='$(TARGET)' python_clean diff --git a/Examples/python/contract/Makefile b/Examples/python/contract/Makefile index 999521ccc..fe1d9325e 100644 --- a/Examples/python/contract/Makefile +++ b/Examples/python/contract/Makefile @@ -6,15 +6,15 @@ INTERFACE = example.i SWIGOPT = check: build - $(MAKE) -f $(TOP)/Makefile python_run + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' python_run build: - $(MAKE) -f $(TOP)/Makefile SRCS='$(SRCS)' SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SRCS='$(SRCS)' SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT)' \ TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' python static: - $(MAKE) -f $(TOP)/Makefile SRCS='$(SRCS)' SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SRCS='$(SRCS)' SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT)' \ TARGET='mypython' INTERFACE='$(INTERFACE)' python_static clean: - $(MAKE) -f $(TOP)/Makefile TARGET='$(TARGET)' python_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' TARGET='$(TARGET)' python_clean diff --git a/Examples/python/docstrings/Makefile b/Examples/python/docstrings/Makefile index 51552f3cf..f471930dd 100644 --- a/Examples/python/docstrings/Makefile +++ b/Examples/python/docstrings/Makefile @@ -7,17 +7,17 @@ LIBS = -lm SWIGOPT = -O check: build - $(MAKE) -f $(TOP)/Makefile python_run + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' python_run build: - $(MAKE) -f $(TOP)/Makefile CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ SWIGOPT='$(SWIGOPT)' \ TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' python_cpp static: - $(MAKE) -f $(TOP)/Makefile CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ SWIGOPT='$(SWIGOPT)' \ TARGET='mypython' INTERFACE='$(INTERFACE)' python_cpp_static clean: - $(MAKE) -f $(TOP)/Makefile TARGET='$(TARGET)' python_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' TARGET='$(TARGET)' python_clean diff --git a/Examples/python/enum/Makefile b/Examples/python/enum/Makefile index e940c1f43..41cded284 100644 --- a/Examples/python/enum/Makefile +++ b/Examples/python/enum/Makefile @@ -6,15 +6,15 @@ INTERFACE = example.i LIBS = -lm check: build - $(MAKE) -f $(TOP)/Makefile python_run + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' python_run build: - $(MAKE) -f $(TOP)/Makefile CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' python_cpp static: - $(MAKE) -f $(TOP)/Makefile CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ TARGET='mypython' INTERFACE='$(INTERFACE)' python_cpp_static clean: - $(MAKE) -f $(TOP)/Makefile TARGET='$(TARGET)' python_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' TARGET='$(TARGET)' python_clean diff --git a/Examples/python/exception/Makefile b/Examples/python/exception/Makefile index fb200fbaf..ad3d49fe1 100644 --- a/Examples/python/exception/Makefile +++ b/Examples/python/exception/Makefile @@ -6,15 +6,15 @@ INTERFACE = example.i LIBS = -lm check: build - $(MAKE) -f $(TOP)/Makefile python_run + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' python_run build: - $(MAKE) -f $(TOP)/Makefile CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' python_cpp static: - $(MAKE) -f $(TOP)/Makefile CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ TARGET='mypython' INTERFACE='$(INTERFACE)' python_cpp_static clean: - $(MAKE) -f $(TOP)/Makefile TARGET='$(TARGET)' python_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' TARGET='$(TARGET)' python_clean diff --git a/Examples/python/exceptproxy/Makefile b/Examples/python/exceptproxy/Makefile index 86a643415..f406dfaf4 100644 --- a/Examples/python/exceptproxy/Makefile +++ b/Examples/python/exceptproxy/Makefile @@ -7,15 +7,15 @@ LIBS = -lm SWIGOPT = check: build - $(MAKE) -f $(TOP)/Makefile python_run + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' python_run build: - $(MAKE) -f $(TOP)/Makefile CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ SWIGOPT='$(SWIGOPT)' TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' python_cpp static: - $(MAKE) -f $(TOP)/Makefile CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ SWIGOPT='$(SWIGOPT)' TARGET='mypython' INTERFACE='$(INTERFACE)' python_cpp_static clean: - $(MAKE) -f $(TOP)/Makefile TARGET='$(TARGET)' python_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' TARGET='$(TARGET)' python_clean diff --git a/Examples/python/extend/Makefile b/Examples/python/extend/Makefile index 684995801..a4c4d2a69 100644 --- a/Examples/python/extend/Makefile +++ b/Examples/python/extend/Makefile @@ -7,15 +7,15 @@ LIBS = -lm SWIGOPT = check: build - $(MAKE) -f $(TOP)/Makefile python_run + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' python_run build: - $(MAKE) -f $(TOP)/Makefile $(SWIGLIB) CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' $(SWIGLIB) CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ SWIGOPT='$(SWIGOPT)' TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' python_cpp static: - $(MAKE) -f $(TOP)/Makefile $(SWIGLIB) CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' $(SWIGLIB) CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ SWIGOPT='$(SWIGOPT)' TARGET='mypython' INTERFACE='$(INTERFACE)' python_cpp_static clean: - $(MAKE) -f $(TOP)/Makefile TARGET='$(TARGET)' python_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' TARGET='$(TARGET)' python_clean diff --git a/Examples/python/funcptr/Makefile b/Examples/python/funcptr/Makefile index df3bc86ff..222916fa1 100644 --- a/Examples/python/funcptr/Makefile +++ b/Examples/python/funcptr/Makefile @@ -5,15 +5,15 @@ TARGET = example INTERFACE = example.i check: build - $(MAKE) -f $(TOP)/Makefile python_run + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' python_run build: - $(MAKE) -f $(TOP)/Makefile SRCS='$(SRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SRCS='$(SRCS)' SWIG='$(SWIG)' \ TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' python static: - $(MAKE) -f $(TOP)/Makefile SRCS='$(SRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SRCS='$(SRCS)' SWIG='$(SWIG)' \ TARGET='mypython' INTERFACE='$(INTERFACE)' python_static clean: - $(MAKE) -f $(TOP)/Makefile TARGET='$(TARGET)' python_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' TARGET='$(TARGET)' python_clean diff --git a/Examples/python/funcptr2/Makefile b/Examples/python/funcptr2/Makefile index df3bc86ff..222916fa1 100644 --- a/Examples/python/funcptr2/Makefile +++ b/Examples/python/funcptr2/Makefile @@ -5,15 +5,15 @@ TARGET = example INTERFACE = example.i check: build - $(MAKE) -f $(TOP)/Makefile python_run + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' python_run build: - $(MAKE) -f $(TOP)/Makefile SRCS='$(SRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SRCS='$(SRCS)' SWIG='$(SWIG)' \ TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' python static: - $(MAKE) -f $(TOP)/Makefile SRCS='$(SRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SRCS='$(SRCS)' SWIG='$(SWIG)' \ TARGET='mypython' INTERFACE='$(INTERFACE)' python_static clean: - $(MAKE) -f $(TOP)/Makefile TARGET='$(TARGET)' python_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' TARGET='$(TARGET)' python_clean diff --git a/Examples/python/functor/Makefile b/Examples/python/functor/Makefile index dde0d0910..1234c310e 100644 --- a/Examples/python/functor/Makefile +++ b/Examples/python/functor/Makefile @@ -7,15 +7,15 @@ LIBS = -lm SWIGOPT = check: build - $(MAKE) -f $(TOP)/Makefile python_run + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' python_run build: - $(MAKE) -f $(TOP)/Makefile CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ SWIGOPT='$(SWIGOPT)' TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' python_cpp static: - $(MAKE) -f $(TOP)/Makefile CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ TARGET='mypython' INTERFACE='$(INTERFACE)' python_cpp_static clean: - $(MAKE) -f $(TOP)/Makefile TARGET='$(TARGET)' python_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' TARGET='$(TARGET)' python_clean diff --git a/Examples/python/import/Makefile b/Examples/python/import/Makefile index f63e12271..d83dfeaa8 100644 --- a/Examples/python/import/Makefile +++ b/Examples/python/import/Makefile @@ -4,19 +4,19 @@ SWIGOPT = LIBS = check: build - $(MAKE) -f $(TOP)/Makefile python_run + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' python_run build: - $(MAKE) -f $(TOP)/Makefile SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT)' \ LIBS='$(LIBS)' TARGET='base' INTERFACE='base.i' python_cpp - $(MAKE) -f $(TOP)/Makefile SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT)' \ LIBS='$(LIBS)' TARGET='foo' INTERFACE='foo.i' python_cpp - $(MAKE) -f $(TOP)/Makefile SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT)' \ LIBS='$(LIBS)' TARGET='bar' INTERFACE='bar.i' python_cpp - $(MAKE) -f $(TOP)/Makefile SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT)' \ LIBS='$(LIBS)' TARGET='spam' INTERFACE='spam.i' python_cpp clean: - $(MAKE) -f $(TOP)/Makefile TARGET='$(TARGET)' python_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' TARGET='$(TARGET)' python_clean rm -f foo.py bar.py spam.py base.py diff --git a/Examples/python/import_packages/Makefile b/Examples/python/import_packages/Makefile index fda2380b3..2df2be101 100644 --- a/Examples/python/import_packages/Makefile +++ b/Examples/python/import_packages/Makefile @@ -5,7 +5,7 @@ LIBS = PY3 = import_packages_subdirs = \ - same_modnames1 \ + same_modnames1 \ same_modnames2 \ from_init1 \ from_init2 \ @@ -14,8 +14,13 @@ import_packages_subdirs = \ relativeimport1 check: build + if test "x$(SRCDIR)" != x; then \ + for file in `cd $(SRCDIR) && find . -type f -name __init__.py`; do \ + cp "${SRCDIR}$$file" "$$file" || exit 1; \ + done; \ + fi; \ for s in $(import_packages_subdirs); do \ - (cd $$s && $(MAKE) check); \ + (cd $$s && $(MAKE) check); \ done build: @@ -29,7 +34,7 @@ static: done clean: - $(MAKE) -f $(TOP)/Makefile python_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' python_clean for s in $(import_packages_subdirs); do \ (cd $$s && $(MAKE) clean); \ done diff --git a/Examples/python/import_packages/from_init1/Makefile b/Examples/python/import_packages/from_init1/Makefile index 8e35c6c61..b9d803a0e 100644 --- a/Examples/python/import_packages/from_init1/Makefile +++ b/Examples/python/import_packages/from_init1/Makefile @@ -11,7 +11,7 @@ else endif check: build - $(MAKE) -f $(TOP)/Makefile python_run + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' python_run build: cd $(PKG1DIR) && $(MAKE) SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT) -relativeimport' LIBS='$(LIBS)' build @@ -20,6 +20,6 @@ static: cd $(PKG1DIR) && $(MAKE) SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT) -relativeimport' LIBS='$(LIBS)' static clean: - $(MAKE) -f $(TOP)/Makefile python_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' python_clean cd py2 && $(MAKE) clean cd py3 && $(MAKE) clean diff --git a/Examples/python/import_packages/from_init1/py2/Makefile b/Examples/python/import_packages/from_init1/py2/Makefile index 4c0dfab07..9595397d8 100644 --- a/Examples/python/import_packages/from_init1/py2/Makefile +++ b/Examples/python/import_packages/from_init1/py2/Makefile @@ -10,5 +10,5 @@ static: cd pkg2 && $(MAKE) SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT)' LIBS='$(LIBS)' static clean: - $(MAKE) -f $(TOP)/Makefile python_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' python_clean cd pkg2 && $(MAKE) clean diff --git a/Examples/python/import_packages/from_init1/py2/pkg2/Makefile b/Examples/python/import_packages/from_init1/py2/pkg2/Makefile index 0dd174659..1eb810e05 100644 --- a/Examples/python/import_packages/from_init1/py2/pkg2/Makefile +++ b/Examples/python/import_packages/from_init1/py2/pkg2/Makefile @@ -4,17 +4,17 @@ SWIGOPT = LIBS = build: - $(MAKE) -f $(TOP)/Makefile SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT)' \ LIBS='$(LIBS)' TARGET='foo' INTERFACE='foo.i' python_cpp - $(MAKE) -f $(TOP)/Makefile SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT)' \ LIBS='$(LIBS)' TARGET='bar' INTERFACE='bar.i' python_cpp static: - $(MAKE) -f $(TOP)/Makefile SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT)' \ LIBS='$(LIBS)' TARGET='foo' INTERFACE='foo.i' python_cpp_static - $(MAKE) -f $(TOP)/Makefile SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT)' \ LIBS='$(LIBS)' TARGET='bar' INTERFACE='bar.i' python_cpp_static clean:: - $(MAKE) -f $(TOP)/Makefile TARGET='foo' python_clean - $(MAKE) -f $(TOP)/Makefile TARGET='bar' python_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' TARGET='foo' python_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' TARGET='bar' python_clean diff --git a/Examples/python/import_packages/from_init1/py3/Makefile b/Examples/python/import_packages/from_init1/py3/Makefile index 4c0dfab07..9595397d8 100644 --- a/Examples/python/import_packages/from_init1/py3/Makefile +++ b/Examples/python/import_packages/from_init1/py3/Makefile @@ -10,5 +10,5 @@ static: cd pkg2 && $(MAKE) SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT)' LIBS='$(LIBS)' static clean: - $(MAKE) -f $(TOP)/Makefile python_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' python_clean cd pkg2 && $(MAKE) clean diff --git a/Examples/python/import_packages/from_init1/py3/pkg2/Makefile b/Examples/python/import_packages/from_init1/py3/pkg2/Makefile index 0dd174659..1eb810e05 100644 --- a/Examples/python/import_packages/from_init1/py3/pkg2/Makefile +++ b/Examples/python/import_packages/from_init1/py3/pkg2/Makefile @@ -4,17 +4,17 @@ SWIGOPT = LIBS = build: - $(MAKE) -f $(TOP)/Makefile SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT)' \ LIBS='$(LIBS)' TARGET='foo' INTERFACE='foo.i' python_cpp - $(MAKE) -f $(TOP)/Makefile SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT)' \ LIBS='$(LIBS)' TARGET='bar' INTERFACE='bar.i' python_cpp static: - $(MAKE) -f $(TOP)/Makefile SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT)' \ LIBS='$(LIBS)' TARGET='foo' INTERFACE='foo.i' python_cpp_static - $(MAKE) -f $(TOP)/Makefile SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT)' \ LIBS='$(LIBS)' TARGET='bar' INTERFACE='bar.i' python_cpp_static clean:: - $(MAKE) -f $(TOP)/Makefile TARGET='foo' python_clean - $(MAKE) -f $(TOP)/Makefile TARGET='bar' python_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' TARGET='foo' python_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' TARGET='bar' python_clean diff --git a/Examples/python/import_packages/from_init2/Makefile b/Examples/python/import_packages/from_init2/Makefile index 8e35c6c61..b9d803a0e 100644 --- a/Examples/python/import_packages/from_init2/Makefile +++ b/Examples/python/import_packages/from_init2/Makefile @@ -11,7 +11,7 @@ else endif check: build - $(MAKE) -f $(TOP)/Makefile python_run + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' python_run build: cd $(PKG1DIR) && $(MAKE) SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT) -relativeimport' LIBS='$(LIBS)' build @@ -20,6 +20,6 @@ static: cd $(PKG1DIR) && $(MAKE) SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT) -relativeimport' LIBS='$(LIBS)' static clean: - $(MAKE) -f $(TOP)/Makefile python_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' python_clean cd py2 && $(MAKE) clean cd py3 && $(MAKE) clean diff --git a/Examples/python/import_packages/from_init2/py2/Makefile b/Examples/python/import_packages/from_init2/py2/Makefile index 4c0dfab07..9595397d8 100644 --- a/Examples/python/import_packages/from_init2/py2/Makefile +++ b/Examples/python/import_packages/from_init2/py2/Makefile @@ -10,5 +10,5 @@ static: cd pkg2 && $(MAKE) SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT)' LIBS='$(LIBS)' static clean: - $(MAKE) -f $(TOP)/Makefile python_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' python_clean cd pkg2 && $(MAKE) clean diff --git a/Examples/python/import_packages/from_init2/py2/pkg2/Makefile b/Examples/python/import_packages/from_init2/py2/pkg2/Makefile index 3fe56139d..36e099b78 100644 --- a/Examples/python/import_packages/from_init2/py2/pkg2/Makefile +++ b/Examples/python/import_packages/from_init2/py2/pkg2/Makefile @@ -4,15 +4,15 @@ SWIGOPT = LIBS = build: - $(MAKE) -f $(TOP)/Makefile SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT)' \ LIBS='$(LIBS)' TARGET='bar' INTERFACE='bar.i' python_cpp cd pkg3 && $(MAKE) SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT)' LIBS='$(LIBS)' build static: - $(MAKE) -f $(TOP)/Makefile SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT)' \ LIBS='$(LIBS)' TARGET='bar' INTERFACE='bar.i' python_cpp cd pkg3 && $(MAKE) SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT)' LIBS='$(LIBS)' static clean: - $(MAKE) -f $(TOP)/Makefile TARGET='bar' python_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' TARGET='bar' python_clean cd pkg3 && $(MAKE) clean diff --git a/Examples/python/import_packages/from_init2/py2/pkg2/pkg3/Makefile b/Examples/python/import_packages/from_init2/py2/pkg2/pkg3/Makefile index a417e2745..cb20bd25f 100644 --- a/Examples/python/import_packages/from_init2/py2/pkg2/pkg3/Makefile +++ b/Examples/python/import_packages/from_init2/py2/pkg2/pkg3/Makefile @@ -4,12 +4,12 @@ SWIGOPT = LIBS = build: - $(MAKE) -f $(TOP)/Makefile SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT)' \ LIBS='$(LIBS)' TARGET='foo' INTERFACE='foo.i' python_cpp static: - $(MAKE) -f $(TOP)/Makefile SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT)' \ LIBS='$(LIBS)' TARGET='foo' INTERFACE='foo.i' python_cpp_static clean: - $(MAKE) -f $(TOP)/Makefile TARGET='foo' python_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' TARGET='foo' python_clean diff --git a/Examples/python/import_packages/from_init2/py3/Makefile b/Examples/python/import_packages/from_init2/py3/Makefile index 4c0dfab07..9595397d8 100644 --- a/Examples/python/import_packages/from_init2/py3/Makefile +++ b/Examples/python/import_packages/from_init2/py3/Makefile @@ -10,5 +10,5 @@ static: cd pkg2 && $(MAKE) SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT)' LIBS='$(LIBS)' static clean: - $(MAKE) -f $(TOP)/Makefile python_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' python_clean cd pkg2 && $(MAKE) clean diff --git a/Examples/python/import_packages/from_init2/py3/pkg2/Makefile b/Examples/python/import_packages/from_init2/py3/pkg2/Makefile index 3fe56139d..36e099b78 100644 --- a/Examples/python/import_packages/from_init2/py3/pkg2/Makefile +++ b/Examples/python/import_packages/from_init2/py3/pkg2/Makefile @@ -4,15 +4,15 @@ SWIGOPT = LIBS = build: - $(MAKE) -f $(TOP)/Makefile SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT)' \ LIBS='$(LIBS)' TARGET='bar' INTERFACE='bar.i' python_cpp cd pkg3 && $(MAKE) SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT)' LIBS='$(LIBS)' build static: - $(MAKE) -f $(TOP)/Makefile SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT)' \ LIBS='$(LIBS)' TARGET='bar' INTERFACE='bar.i' python_cpp cd pkg3 && $(MAKE) SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT)' LIBS='$(LIBS)' static clean: - $(MAKE) -f $(TOP)/Makefile TARGET='bar' python_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' TARGET='bar' python_clean cd pkg3 && $(MAKE) clean diff --git a/Examples/python/import_packages/from_init2/py3/pkg2/pkg3/Makefile b/Examples/python/import_packages/from_init2/py3/pkg2/pkg3/Makefile index a417e2745..cb20bd25f 100644 --- a/Examples/python/import_packages/from_init2/py3/pkg2/pkg3/Makefile +++ b/Examples/python/import_packages/from_init2/py3/pkg2/pkg3/Makefile @@ -4,12 +4,12 @@ SWIGOPT = LIBS = build: - $(MAKE) -f $(TOP)/Makefile SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT)' \ LIBS='$(LIBS)' TARGET='foo' INTERFACE='foo.i' python_cpp static: - $(MAKE) -f $(TOP)/Makefile SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT)' \ LIBS='$(LIBS)' TARGET='foo' INTERFACE='foo.i' python_cpp_static clean: - $(MAKE) -f $(TOP)/Makefile TARGET='foo' python_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' TARGET='foo' python_clean diff --git a/Examples/python/import_packages/from_init3/Makefile b/Examples/python/import_packages/from_init3/Makefile index 8e35c6c61..b9d803a0e 100644 --- a/Examples/python/import_packages/from_init3/Makefile +++ b/Examples/python/import_packages/from_init3/Makefile @@ -11,7 +11,7 @@ else endif check: build - $(MAKE) -f $(TOP)/Makefile python_run + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' python_run build: cd $(PKG1DIR) && $(MAKE) SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT) -relativeimport' LIBS='$(LIBS)' build @@ -20,6 +20,6 @@ static: cd $(PKG1DIR) && $(MAKE) SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT) -relativeimport' LIBS='$(LIBS)' static clean: - $(MAKE) -f $(TOP)/Makefile python_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' python_clean cd py2 && $(MAKE) clean cd py3 && $(MAKE) clean diff --git a/Examples/python/import_packages/from_init3/py2/Makefile b/Examples/python/import_packages/from_init3/py2/Makefile index 4c0dfab07..9595397d8 100644 --- a/Examples/python/import_packages/from_init3/py2/Makefile +++ b/Examples/python/import_packages/from_init3/py2/Makefile @@ -10,5 +10,5 @@ static: cd pkg2 && $(MAKE) SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT)' LIBS='$(LIBS)' static clean: - $(MAKE) -f $(TOP)/Makefile python_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' python_clean cd pkg2 && $(MAKE) clean diff --git a/Examples/python/import_packages/from_init3/py2/pkg2/Makefile b/Examples/python/import_packages/from_init3/py2/pkg2/Makefile index 3fe56139d..36e099b78 100644 --- a/Examples/python/import_packages/from_init3/py2/pkg2/Makefile +++ b/Examples/python/import_packages/from_init3/py2/pkg2/Makefile @@ -4,15 +4,15 @@ SWIGOPT = LIBS = build: - $(MAKE) -f $(TOP)/Makefile SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT)' \ LIBS='$(LIBS)' TARGET='bar' INTERFACE='bar.i' python_cpp cd pkg3 && $(MAKE) SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT)' LIBS='$(LIBS)' build static: - $(MAKE) -f $(TOP)/Makefile SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT)' \ LIBS='$(LIBS)' TARGET='bar' INTERFACE='bar.i' python_cpp cd pkg3 && $(MAKE) SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT)' LIBS='$(LIBS)' static clean: - $(MAKE) -f $(TOP)/Makefile TARGET='bar' python_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' TARGET='bar' python_clean cd pkg3 && $(MAKE) clean diff --git a/Examples/python/import_packages/from_init3/py2/pkg2/pkg3/Makefile b/Examples/python/import_packages/from_init3/py2/pkg2/pkg3/Makefile index 470f9d561..d6ae1b2bc 100644 --- a/Examples/python/import_packages/from_init3/py2/pkg2/pkg3/Makefile +++ b/Examples/python/import_packages/from_init3/py2/pkg2/pkg3/Makefile @@ -10,5 +10,5 @@ static: cd pkg4 && $(MAKE) SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT)' LIBS='$(LIBS)' static clean: - $(MAKE) -f $(TOP)/Makefile python_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' python_clean cd pkg4 && $(MAKE) clean diff --git a/Examples/python/import_packages/from_init3/py2/pkg2/pkg3/pkg4/Makefile b/Examples/python/import_packages/from_init3/py2/pkg2/pkg3/pkg4/Makefile index a98d31122..286d90070 100644 --- a/Examples/python/import_packages/from_init3/py2/pkg2/pkg3/pkg4/Makefile +++ b/Examples/python/import_packages/from_init3/py2/pkg2/pkg3/pkg4/Makefile @@ -4,12 +4,12 @@ SWIGOPT = LIBS = build: - $(MAKE) -f $(TOP)/Makefile SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT)' \ LIBS='$(LIBS)' TARGET='foo' INTERFACE='foo.i' python_cpp static: - $(MAKE) -f $(TOP)/Makefile SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT)' \ LIBS='$(LIBS)' TARGET='foo' INTERFACE='foo.i' python_cpp_static clean: - $(MAKE) -f $(TOP)/Makefile TARGET='foo' python_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' TARGET='foo' python_clean diff --git a/Examples/python/import_packages/from_init3/py3/Makefile b/Examples/python/import_packages/from_init3/py3/Makefile index 4c0dfab07..9595397d8 100644 --- a/Examples/python/import_packages/from_init3/py3/Makefile +++ b/Examples/python/import_packages/from_init3/py3/Makefile @@ -10,5 +10,5 @@ static: cd pkg2 && $(MAKE) SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT)' LIBS='$(LIBS)' static clean: - $(MAKE) -f $(TOP)/Makefile python_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' python_clean cd pkg2 && $(MAKE) clean diff --git a/Examples/python/import_packages/from_init3/py3/pkg2/Makefile b/Examples/python/import_packages/from_init3/py3/pkg2/Makefile index 3fe56139d..36e099b78 100644 --- a/Examples/python/import_packages/from_init3/py3/pkg2/Makefile +++ b/Examples/python/import_packages/from_init3/py3/pkg2/Makefile @@ -4,15 +4,15 @@ SWIGOPT = LIBS = build: - $(MAKE) -f $(TOP)/Makefile SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT)' \ LIBS='$(LIBS)' TARGET='bar' INTERFACE='bar.i' python_cpp cd pkg3 && $(MAKE) SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT)' LIBS='$(LIBS)' build static: - $(MAKE) -f $(TOP)/Makefile SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT)' \ LIBS='$(LIBS)' TARGET='bar' INTERFACE='bar.i' python_cpp cd pkg3 && $(MAKE) SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT)' LIBS='$(LIBS)' static clean: - $(MAKE) -f $(TOP)/Makefile TARGET='bar' python_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' TARGET='bar' python_clean cd pkg3 && $(MAKE) clean diff --git a/Examples/python/import_packages/from_init3/py3/pkg2/pkg3/Makefile b/Examples/python/import_packages/from_init3/py3/pkg2/pkg3/Makefile index 470f9d561..d6ae1b2bc 100644 --- a/Examples/python/import_packages/from_init3/py3/pkg2/pkg3/Makefile +++ b/Examples/python/import_packages/from_init3/py3/pkg2/pkg3/Makefile @@ -10,5 +10,5 @@ static: cd pkg4 && $(MAKE) SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT)' LIBS='$(LIBS)' static clean: - $(MAKE) -f $(TOP)/Makefile python_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' python_clean cd pkg4 && $(MAKE) clean diff --git a/Examples/python/import_packages/from_init3/py3/pkg2/pkg3/pkg4/Makefile b/Examples/python/import_packages/from_init3/py3/pkg2/pkg3/pkg4/Makefile index a98d31122..286d90070 100644 --- a/Examples/python/import_packages/from_init3/py3/pkg2/pkg3/pkg4/Makefile +++ b/Examples/python/import_packages/from_init3/py3/pkg2/pkg3/pkg4/Makefile @@ -4,12 +4,12 @@ SWIGOPT = LIBS = build: - $(MAKE) -f $(TOP)/Makefile SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT)' \ LIBS='$(LIBS)' TARGET='foo' INTERFACE='foo.i' python_cpp static: - $(MAKE) -f $(TOP)/Makefile SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT)' \ LIBS='$(LIBS)' TARGET='foo' INTERFACE='foo.i' python_cpp_static clean: - $(MAKE) -f $(TOP)/Makefile TARGET='foo' python_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' TARGET='foo' python_clean diff --git a/Examples/python/import_packages/relativeimport1/Makefile b/Examples/python/import_packages/relativeimport1/Makefile index 8e35c6c61..b9d803a0e 100644 --- a/Examples/python/import_packages/relativeimport1/Makefile +++ b/Examples/python/import_packages/relativeimport1/Makefile @@ -11,7 +11,7 @@ else endif check: build - $(MAKE) -f $(TOP)/Makefile python_run + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' python_run build: cd $(PKG1DIR) && $(MAKE) SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT) -relativeimport' LIBS='$(LIBS)' build @@ -20,6 +20,6 @@ static: cd $(PKG1DIR) && $(MAKE) SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT) -relativeimport' LIBS='$(LIBS)' static clean: - $(MAKE) -f $(TOP)/Makefile python_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' python_clean cd py2 && $(MAKE) clean cd py3 && $(MAKE) clean diff --git a/Examples/python/import_packages/relativeimport1/py2/Makefile b/Examples/python/import_packages/relativeimport1/py2/Makefile index 4c0dfab07..9595397d8 100644 --- a/Examples/python/import_packages/relativeimport1/py2/Makefile +++ b/Examples/python/import_packages/relativeimport1/py2/Makefile @@ -10,5 +10,5 @@ static: cd pkg2 && $(MAKE) SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT)' LIBS='$(LIBS)' static clean: - $(MAKE) -f $(TOP)/Makefile python_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' python_clean cd pkg2 && $(MAKE) clean diff --git a/Examples/python/import_packages/relativeimport1/py2/pkg2/Makefile b/Examples/python/import_packages/relativeimport1/py2/pkg2/Makefile index 3fe56139d..36e099b78 100644 --- a/Examples/python/import_packages/relativeimport1/py2/pkg2/Makefile +++ b/Examples/python/import_packages/relativeimport1/py2/pkg2/Makefile @@ -4,15 +4,15 @@ SWIGOPT = LIBS = build: - $(MAKE) -f $(TOP)/Makefile SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT)' \ LIBS='$(LIBS)' TARGET='bar' INTERFACE='bar.i' python_cpp cd pkg3 && $(MAKE) SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT)' LIBS='$(LIBS)' build static: - $(MAKE) -f $(TOP)/Makefile SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT)' \ LIBS='$(LIBS)' TARGET='bar' INTERFACE='bar.i' python_cpp cd pkg3 && $(MAKE) SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT)' LIBS='$(LIBS)' static clean: - $(MAKE) -f $(TOP)/Makefile TARGET='bar' python_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' TARGET='bar' python_clean cd pkg3 && $(MAKE) clean diff --git a/Examples/python/import_packages/relativeimport1/py2/pkg2/pkg3/Makefile b/Examples/python/import_packages/relativeimport1/py2/pkg2/pkg3/Makefile index a417e2745..cb20bd25f 100644 --- a/Examples/python/import_packages/relativeimport1/py2/pkg2/pkg3/Makefile +++ b/Examples/python/import_packages/relativeimport1/py2/pkg2/pkg3/Makefile @@ -4,12 +4,12 @@ SWIGOPT = LIBS = build: - $(MAKE) -f $(TOP)/Makefile SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT)' \ LIBS='$(LIBS)' TARGET='foo' INTERFACE='foo.i' python_cpp static: - $(MAKE) -f $(TOP)/Makefile SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT)' \ LIBS='$(LIBS)' TARGET='foo' INTERFACE='foo.i' python_cpp_static clean: - $(MAKE) -f $(TOP)/Makefile TARGET='foo' python_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' TARGET='foo' python_clean diff --git a/Examples/python/import_packages/relativeimport1/py3/Makefile b/Examples/python/import_packages/relativeimport1/py3/Makefile index 4c0dfab07..9595397d8 100644 --- a/Examples/python/import_packages/relativeimport1/py3/Makefile +++ b/Examples/python/import_packages/relativeimport1/py3/Makefile @@ -10,5 +10,5 @@ static: cd pkg2 && $(MAKE) SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT)' LIBS='$(LIBS)' static clean: - $(MAKE) -f $(TOP)/Makefile python_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' python_clean cd pkg2 && $(MAKE) clean diff --git a/Examples/python/import_packages/relativeimport1/py3/pkg2/Makefile b/Examples/python/import_packages/relativeimport1/py3/pkg2/Makefile index 3fe56139d..36e099b78 100644 --- a/Examples/python/import_packages/relativeimport1/py3/pkg2/Makefile +++ b/Examples/python/import_packages/relativeimport1/py3/pkg2/Makefile @@ -4,15 +4,15 @@ SWIGOPT = LIBS = build: - $(MAKE) -f $(TOP)/Makefile SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT)' \ LIBS='$(LIBS)' TARGET='bar' INTERFACE='bar.i' python_cpp cd pkg3 && $(MAKE) SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT)' LIBS='$(LIBS)' build static: - $(MAKE) -f $(TOP)/Makefile SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT)' \ LIBS='$(LIBS)' TARGET='bar' INTERFACE='bar.i' python_cpp cd pkg3 && $(MAKE) SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT)' LIBS='$(LIBS)' static clean: - $(MAKE) -f $(TOP)/Makefile TARGET='bar' python_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' TARGET='bar' python_clean cd pkg3 && $(MAKE) clean diff --git a/Examples/python/import_packages/relativeimport1/py3/pkg2/pkg3/Makefile b/Examples/python/import_packages/relativeimport1/py3/pkg2/pkg3/Makefile index a417e2745..cb20bd25f 100644 --- a/Examples/python/import_packages/relativeimport1/py3/pkg2/pkg3/Makefile +++ b/Examples/python/import_packages/relativeimport1/py3/pkg2/pkg3/Makefile @@ -4,12 +4,12 @@ SWIGOPT = LIBS = build: - $(MAKE) -f $(TOP)/Makefile SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT)' \ LIBS='$(LIBS)' TARGET='foo' INTERFACE='foo.i' python_cpp static: - $(MAKE) -f $(TOP)/Makefile SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT)' \ LIBS='$(LIBS)' TARGET='foo' INTERFACE='foo.i' python_cpp_static clean: - $(MAKE) -f $(TOP)/Makefile TARGET='foo' python_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' TARGET='foo' python_clean diff --git a/Examples/python/import_packages/relativeimport2/Makefile b/Examples/python/import_packages/relativeimport2/Makefile index 8e35c6c61..b9d803a0e 100644 --- a/Examples/python/import_packages/relativeimport2/Makefile +++ b/Examples/python/import_packages/relativeimport2/Makefile @@ -11,7 +11,7 @@ else endif check: build - $(MAKE) -f $(TOP)/Makefile python_run + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' python_run build: cd $(PKG1DIR) && $(MAKE) SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT) -relativeimport' LIBS='$(LIBS)' build @@ -20,6 +20,6 @@ static: cd $(PKG1DIR) && $(MAKE) SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT) -relativeimport' LIBS='$(LIBS)' static clean: - $(MAKE) -f $(TOP)/Makefile python_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' python_clean cd py2 && $(MAKE) clean cd py3 && $(MAKE) clean diff --git a/Examples/python/import_packages/relativeimport2/py2/Makefile b/Examples/python/import_packages/relativeimport2/py2/Makefile index 4c0dfab07..9595397d8 100644 --- a/Examples/python/import_packages/relativeimport2/py2/Makefile +++ b/Examples/python/import_packages/relativeimport2/py2/Makefile @@ -10,5 +10,5 @@ static: cd pkg2 && $(MAKE) SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT)' LIBS='$(LIBS)' static clean: - $(MAKE) -f $(TOP)/Makefile python_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' python_clean cd pkg2 && $(MAKE) clean diff --git a/Examples/python/import_packages/relativeimport2/py2/pkg2/Makefile b/Examples/python/import_packages/relativeimport2/py2/pkg2/Makefile index 3fe56139d..36e099b78 100644 --- a/Examples/python/import_packages/relativeimport2/py2/pkg2/Makefile +++ b/Examples/python/import_packages/relativeimport2/py2/pkg2/Makefile @@ -4,15 +4,15 @@ SWIGOPT = LIBS = build: - $(MAKE) -f $(TOP)/Makefile SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT)' \ LIBS='$(LIBS)' TARGET='bar' INTERFACE='bar.i' python_cpp cd pkg3 && $(MAKE) SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT)' LIBS='$(LIBS)' build static: - $(MAKE) -f $(TOP)/Makefile SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT)' \ LIBS='$(LIBS)' TARGET='bar' INTERFACE='bar.i' python_cpp cd pkg3 && $(MAKE) SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT)' LIBS='$(LIBS)' static clean: - $(MAKE) -f $(TOP)/Makefile TARGET='bar' python_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' TARGET='bar' python_clean cd pkg3 && $(MAKE) clean diff --git a/Examples/python/import_packages/relativeimport2/py2/pkg2/pkg3/Makefile b/Examples/python/import_packages/relativeimport2/py2/pkg2/pkg3/Makefile index 470f9d561..d6ae1b2bc 100644 --- a/Examples/python/import_packages/relativeimport2/py2/pkg2/pkg3/Makefile +++ b/Examples/python/import_packages/relativeimport2/py2/pkg2/pkg3/Makefile @@ -10,5 +10,5 @@ static: cd pkg4 && $(MAKE) SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT)' LIBS='$(LIBS)' static clean: - $(MAKE) -f $(TOP)/Makefile python_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' python_clean cd pkg4 && $(MAKE) clean diff --git a/Examples/python/import_packages/relativeimport2/py2/pkg2/pkg3/pkg4/Makefile b/Examples/python/import_packages/relativeimport2/py2/pkg2/pkg3/pkg4/Makefile index a98d31122..286d90070 100644 --- a/Examples/python/import_packages/relativeimport2/py2/pkg2/pkg3/pkg4/Makefile +++ b/Examples/python/import_packages/relativeimport2/py2/pkg2/pkg3/pkg4/Makefile @@ -4,12 +4,12 @@ SWIGOPT = LIBS = build: - $(MAKE) -f $(TOP)/Makefile SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT)' \ LIBS='$(LIBS)' TARGET='foo' INTERFACE='foo.i' python_cpp static: - $(MAKE) -f $(TOP)/Makefile SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT)' \ LIBS='$(LIBS)' TARGET='foo' INTERFACE='foo.i' python_cpp_static clean: - $(MAKE) -f $(TOP)/Makefile TARGET='foo' python_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' TARGET='foo' python_clean diff --git a/Examples/python/import_packages/relativeimport2/py3/Makefile b/Examples/python/import_packages/relativeimport2/py3/Makefile index 4c0dfab07..9595397d8 100644 --- a/Examples/python/import_packages/relativeimport2/py3/Makefile +++ b/Examples/python/import_packages/relativeimport2/py3/Makefile @@ -10,5 +10,5 @@ static: cd pkg2 && $(MAKE) SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT)' LIBS='$(LIBS)' static clean: - $(MAKE) -f $(TOP)/Makefile python_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' python_clean cd pkg2 && $(MAKE) clean diff --git a/Examples/python/import_packages/relativeimport2/py3/pkg2/Makefile b/Examples/python/import_packages/relativeimport2/py3/pkg2/Makefile index 3fe56139d..36e099b78 100644 --- a/Examples/python/import_packages/relativeimport2/py3/pkg2/Makefile +++ b/Examples/python/import_packages/relativeimport2/py3/pkg2/Makefile @@ -4,15 +4,15 @@ SWIGOPT = LIBS = build: - $(MAKE) -f $(TOP)/Makefile SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT)' \ LIBS='$(LIBS)' TARGET='bar' INTERFACE='bar.i' python_cpp cd pkg3 && $(MAKE) SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT)' LIBS='$(LIBS)' build static: - $(MAKE) -f $(TOP)/Makefile SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT)' \ LIBS='$(LIBS)' TARGET='bar' INTERFACE='bar.i' python_cpp cd pkg3 && $(MAKE) SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT)' LIBS='$(LIBS)' static clean: - $(MAKE) -f $(TOP)/Makefile TARGET='bar' python_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' TARGET='bar' python_clean cd pkg3 && $(MAKE) clean diff --git a/Examples/python/import_packages/relativeimport2/py3/pkg2/pkg3/Makefile b/Examples/python/import_packages/relativeimport2/py3/pkg2/pkg3/Makefile index 470f9d561..d6ae1b2bc 100644 --- a/Examples/python/import_packages/relativeimport2/py3/pkg2/pkg3/Makefile +++ b/Examples/python/import_packages/relativeimport2/py3/pkg2/pkg3/Makefile @@ -10,5 +10,5 @@ static: cd pkg4 && $(MAKE) SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT)' LIBS='$(LIBS)' static clean: - $(MAKE) -f $(TOP)/Makefile python_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' python_clean cd pkg4 && $(MAKE) clean diff --git a/Examples/python/import_packages/relativeimport2/py3/pkg2/pkg3/pkg4/Makefile b/Examples/python/import_packages/relativeimport2/py3/pkg2/pkg3/pkg4/Makefile index a98d31122..286d90070 100644 --- a/Examples/python/import_packages/relativeimport2/py3/pkg2/pkg3/pkg4/Makefile +++ b/Examples/python/import_packages/relativeimport2/py3/pkg2/pkg3/pkg4/Makefile @@ -4,12 +4,12 @@ SWIGOPT = LIBS = build: - $(MAKE) -f $(TOP)/Makefile SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT)' \ LIBS='$(LIBS)' TARGET='foo' INTERFACE='foo.i' python_cpp static: - $(MAKE) -f $(TOP)/Makefile SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT)' \ LIBS='$(LIBS)' TARGET='foo' INTERFACE='foo.i' python_cpp_static clean: - $(MAKE) -f $(TOP)/Makefile TARGET='foo' python_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' TARGET='foo' python_clean diff --git a/Examples/python/import_packages/same_modnames1/Makefile b/Examples/python/import_packages/same_modnames1/Makefile index 9dd5971dc..e05c13017 100644 --- a/Examples/python/import_packages/same_modnames1/Makefile +++ b/Examples/python/import_packages/same_modnames1/Makefile @@ -4,7 +4,7 @@ SWIGOPT = LIBS = check: build - $(MAKE) -f $(TOP)/Makefile python_run + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' python_run build: cd pkg1 && $(MAKE) SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT)' LIBS='$(LIBS)' build @@ -15,6 +15,6 @@ static: cd pkg2 && $(MAKE) SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT)' LIBS='$(LIBS)' static clean: - $(MAKE) -f $(TOP)/Makefile python_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' python_clean cd pkg1 && $(MAKE) clean cd pkg2 && $(MAKE) clean diff --git a/Examples/python/import_packages/same_modnames1/pkg1/Makefile b/Examples/python/import_packages/same_modnames1/pkg1/Makefile index 9b51a76ed..df1b30321 100644 --- a/Examples/python/import_packages/same_modnames1/pkg1/Makefile +++ b/Examples/python/import_packages/same_modnames1/pkg1/Makefile @@ -4,12 +4,12 @@ SWIGOPT = LIBS = build: - $(MAKE) -f $(TOP)/Makefile SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT)' \ LIBS='$(LIBS)' TARGET='foo' INTERFACE='foo.i' python_cpp static: - $(MAKE) -f $(TOP)/Makefile SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT)' \ LIBS='$(LIBS)' TARGET='foo' INTERFACE='foo.i' python_cpp_static clean: - $(MAKE) -f $(TOP)/Makefile TARGET='foo' python_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' TARGET='foo' python_clean diff --git a/Examples/python/import_packages/same_modnames1/pkg2/Makefile b/Examples/python/import_packages/same_modnames1/pkg2/Makefile index 9b51a76ed..df1b30321 100644 --- a/Examples/python/import_packages/same_modnames1/pkg2/Makefile +++ b/Examples/python/import_packages/same_modnames1/pkg2/Makefile @@ -4,12 +4,12 @@ SWIGOPT = LIBS = build: - $(MAKE) -f $(TOP)/Makefile SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT)' \ LIBS='$(LIBS)' TARGET='foo' INTERFACE='foo.i' python_cpp static: - $(MAKE) -f $(TOP)/Makefile SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT)' \ LIBS='$(LIBS)' TARGET='foo' INTERFACE='foo.i' python_cpp_static clean: - $(MAKE) -f $(TOP)/Makefile TARGET='foo' python_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' TARGET='foo' python_clean diff --git a/Examples/python/import_packages/same_modnames2/Makefile b/Examples/python/import_packages/same_modnames2/Makefile index cfc327883..770343a80 100644 --- a/Examples/python/import_packages/same_modnames2/Makefile +++ b/Examples/python/import_packages/same_modnames2/Makefile @@ -4,7 +4,7 @@ SWIGOPT = LIBS = check: build - $(MAKE) -f $(TOP)/Makefile python_run + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' python_run build: cd pkg1 && $(MAKE) SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT)' LIBS='$(LIBS)' build @@ -15,6 +15,6 @@ static: cd pkg1/pkg2 && $(MAKE) SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT)' LIBS='$(LIBS)' static clean: - $(MAKE) -f $(TOP)/Makefile python_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' python_clean cd pkg1 && $(MAKE) clean cd pkg1/pkg2 && $(MAKE) clean diff --git a/Examples/python/import_packages/same_modnames2/pkg1/Makefile b/Examples/python/import_packages/same_modnames2/pkg1/Makefile index 9b51a76ed..df1b30321 100644 --- a/Examples/python/import_packages/same_modnames2/pkg1/Makefile +++ b/Examples/python/import_packages/same_modnames2/pkg1/Makefile @@ -4,12 +4,12 @@ SWIGOPT = LIBS = build: - $(MAKE) -f $(TOP)/Makefile SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT)' \ LIBS='$(LIBS)' TARGET='foo' INTERFACE='foo.i' python_cpp static: - $(MAKE) -f $(TOP)/Makefile SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT)' \ LIBS='$(LIBS)' TARGET='foo' INTERFACE='foo.i' python_cpp_static clean: - $(MAKE) -f $(TOP)/Makefile TARGET='foo' python_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' TARGET='foo' python_clean diff --git a/Examples/python/import_packages/same_modnames2/pkg1/pkg2/Makefile b/Examples/python/import_packages/same_modnames2/pkg1/pkg2/Makefile index 053b911f5..11e8573ad 100644 --- a/Examples/python/import_packages/same_modnames2/pkg1/pkg2/Makefile +++ b/Examples/python/import_packages/same_modnames2/pkg1/pkg2/Makefile @@ -4,12 +4,12 @@ SWIGOPT = LIBS = build: - $(MAKE) -f $(TOP)/Makefile SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT)' \ LIBS='$(LIBS)' TARGET='foo' INTERFACE='foo.i' python_cpp static: - $(MAKE) -f $(TOP)/Makefile SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT)' \ LIBS='$(LIBS)' TARGET='foo' INTERFACE='foo.i' python_cpp_static clean: - $(MAKE) -f $(TOP)/Makefile TARGET='foo' python_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' TARGET='foo' python_clean diff --git a/Examples/python/import_template/Makefile b/Examples/python/import_template/Makefile index f63e12271..d83dfeaa8 100644 --- a/Examples/python/import_template/Makefile +++ b/Examples/python/import_template/Makefile @@ -4,19 +4,19 @@ SWIGOPT = LIBS = check: build - $(MAKE) -f $(TOP)/Makefile python_run + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' python_run build: - $(MAKE) -f $(TOP)/Makefile SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT)' \ LIBS='$(LIBS)' TARGET='base' INTERFACE='base.i' python_cpp - $(MAKE) -f $(TOP)/Makefile SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT)' \ LIBS='$(LIBS)' TARGET='foo' INTERFACE='foo.i' python_cpp - $(MAKE) -f $(TOP)/Makefile SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT)' \ LIBS='$(LIBS)' TARGET='bar' INTERFACE='bar.i' python_cpp - $(MAKE) -f $(TOP)/Makefile SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT)' \ LIBS='$(LIBS)' TARGET='spam' INTERFACE='spam.i' python_cpp clean: - $(MAKE) -f $(TOP)/Makefile TARGET='$(TARGET)' python_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' TARGET='$(TARGET)' python_clean rm -f foo.py bar.py spam.py base.py diff --git a/Examples/python/java/Makefile b/Examples/python/java/Makefile index 2ce219969..4befa38ba 100644 --- a/Examples/python/java/Makefile +++ b/Examples/python/java/Makefile @@ -6,18 +6,18 @@ INTERFACE = example.i LIBS = -lm check: build - $(MAKE) -f $(TOP)/Makefile python_run + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' python_run build: Example.class Example.h - $(MAKE) -f $(TOP)/Makefile CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' \ CXXSHARED="gcj -fpic -shared Example.class" DEFS='' LIBS="-lstdc++" python_cpp clean: - $(MAKE) -f $(TOP)/Makefile python_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' python_clean rm -f $(TARGET).py rm -f *.class Example.h -Example.class Example.h: Example.java - gcj -fPIC -C -c -g Example.java +Example.class Example.h: $(SRCDIR)Example.java + gcj -d . -fPIC -C -c -g $(SRCDIR)Example.java gcjh Example.class diff --git a/Examples/python/libffi/Makefile b/Examples/python/libffi/Makefile index ae51b0a60..db5dfe138 100644 --- a/Examples/python/libffi/Makefile +++ b/Examples/python/libffi/Makefile @@ -5,15 +5,15 @@ TARGET = example INTERFACE = example.i check: build - $(MAKE) -f $(TOP)/Makefile python_run + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' python_run build: - $(MAKE) -f $(TOP)/Makefile SRCS='$(SRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SRCS='$(SRCS)' SWIG='$(SWIG)' \ TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' LIBS='-L/usr/local/lib -lffi' python static: - $(MAKE) -f $(TOP)/Makefile SRCS='$(SRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SRCS='$(SRCS)' SWIG='$(SWIG)' \ TARGET='mypython' INTERFACE='$(INTERFACE)' python_static clean: - $(MAKE) -f $(TOP)/Makefile TARGET='$(TARGET)' python_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' TARGET='$(TARGET)' python_clean diff --git a/Examples/python/multimap/Makefile b/Examples/python/multimap/Makefile index df3bc86ff..222916fa1 100644 --- a/Examples/python/multimap/Makefile +++ b/Examples/python/multimap/Makefile @@ -5,15 +5,15 @@ TARGET = example INTERFACE = example.i check: build - $(MAKE) -f $(TOP)/Makefile python_run + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' python_run build: - $(MAKE) -f $(TOP)/Makefile SRCS='$(SRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SRCS='$(SRCS)' SWIG='$(SWIG)' \ TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' python static: - $(MAKE) -f $(TOP)/Makefile SRCS='$(SRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SRCS='$(SRCS)' SWIG='$(SWIG)' \ TARGET='mypython' INTERFACE='$(INTERFACE)' python_static clean: - $(MAKE) -f $(TOP)/Makefile TARGET='$(TARGET)' python_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' TARGET='$(TARGET)' python_clean diff --git a/Examples/python/operator/Makefile b/Examples/python/operator/Makefile index dde0d0910..1234c310e 100644 --- a/Examples/python/operator/Makefile +++ b/Examples/python/operator/Makefile @@ -7,15 +7,15 @@ LIBS = -lm SWIGOPT = check: build - $(MAKE) -f $(TOP)/Makefile python_run + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' python_run build: - $(MAKE) -f $(TOP)/Makefile CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ SWIGOPT='$(SWIGOPT)' TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' python_cpp static: - $(MAKE) -f $(TOP)/Makefile CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ TARGET='mypython' INTERFACE='$(INTERFACE)' python_cpp_static clean: - $(MAKE) -f $(TOP)/Makefile TARGET='$(TARGET)' python_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' TARGET='$(TARGET)' python_clean diff --git a/Examples/python/performance/constructor/Makefile b/Examples/python/performance/constructor/Makefile index 98a50ec29..8e65123cf 100644 --- a/Examples/python/performance/constructor/Makefile +++ b/Examples/python/performance/constructor/Makefile @@ -5,17 +5,17 @@ TARGET = Simple INTERFACE = Simple.i build: - $(MAKE) -f $(TOP)/Makefile CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG) -module Simple_baseline' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG) -module Simple_baseline' \ TARGET='$(TARGET)_baseline' INTERFACE='$(INTERFACE)' python_cpp - $(MAKE) -f $(TOP)/Makefile CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG) -O -module Simple_optimized' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG) -O -module Simple_optimized' \ TARGET='$(TARGET)_optimized' INTERFACE='$(INTERFACE)' python_cpp - $(MAKE) -f $(TOP)/Makefile CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG) -builtin -O -module Simple_builtin' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG) -builtin -O -module Simple_builtin' \ TARGET='$(TARGET)_builtin' INTERFACE='$(INTERFACE)' python_cpp static: - $(MAKE) -f $(TOP)/Makefile CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ TARGET='mypython' INTERFACE='$(INTERFACE)' python_cpp_static clean: - $(MAKE) -f $(TOP)/Makefile TARGET='$(TARGET)' python_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' TARGET='$(TARGET)' python_clean rm -f $(TARGET)_*.py diff --git a/Examples/python/performance/func/Makefile b/Examples/python/performance/func/Makefile index 98a50ec29..8e65123cf 100644 --- a/Examples/python/performance/func/Makefile +++ b/Examples/python/performance/func/Makefile @@ -5,17 +5,17 @@ TARGET = Simple INTERFACE = Simple.i build: - $(MAKE) -f $(TOP)/Makefile CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG) -module Simple_baseline' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG) -module Simple_baseline' \ TARGET='$(TARGET)_baseline' INTERFACE='$(INTERFACE)' python_cpp - $(MAKE) -f $(TOP)/Makefile CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG) -O -module Simple_optimized' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG) -O -module Simple_optimized' \ TARGET='$(TARGET)_optimized' INTERFACE='$(INTERFACE)' python_cpp - $(MAKE) -f $(TOP)/Makefile CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG) -builtin -O -module Simple_builtin' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG) -builtin -O -module Simple_builtin' \ TARGET='$(TARGET)_builtin' INTERFACE='$(INTERFACE)' python_cpp static: - $(MAKE) -f $(TOP)/Makefile CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ TARGET='mypython' INTERFACE='$(INTERFACE)' python_cpp_static clean: - $(MAKE) -f $(TOP)/Makefile TARGET='$(TARGET)' python_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' TARGET='$(TARGET)' python_clean rm -f $(TARGET)_*.py diff --git a/Examples/python/performance/hierarchy/Makefile b/Examples/python/performance/hierarchy/Makefile index 98a50ec29..8e65123cf 100644 --- a/Examples/python/performance/hierarchy/Makefile +++ b/Examples/python/performance/hierarchy/Makefile @@ -5,17 +5,17 @@ TARGET = Simple INTERFACE = Simple.i build: - $(MAKE) -f $(TOP)/Makefile CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG) -module Simple_baseline' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG) -module Simple_baseline' \ TARGET='$(TARGET)_baseline' INTERFACE='$(INTERFACE)' python_cpp - $(MAKE) -f $(TOP)/Makefile CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG) -O -module Simple_optimized' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG) -O -module Simple_optimized' \ TARGET='$(TARGET)_optimized' INTERFACE='$(INTERFACE)' python_cpp - $(MAKE) -f $(TOP)/Makefile CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG) -builtin -O -module Simple_builtin' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG) -builtin -O -module Simple_builtin' \ TARGET='$(TARGET)_builtin' INTERFACE='$(INTERFACE)' python_cpp static: - $(MAKE) -f $(TOP)/Makefile CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ TARGET='mypython' INTERFACE='$(INTERFACE)' python_cpp_static clean: - $(MAKE) -f $(TOP)/Makefile TARGET='$(TARGET)' python_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' TARGET='$(TARGET)' python_clean rm -f $(TARGET)_*.py diff --git a/Examples/python/performance/hierarchy_operator/Makefile b/Examples/python/performance/hierarchy_operator/Makefile index 98a50ec29..8e65123cf 100644 --- a/Examples/python/performance/hierarchy_operator/Makefile +++ b/Examples/python/performance/hierarchy_operator/Makefile @@ -5,17 +5,17 @@ TARGET = Simple INTERFACE = Simple.i build: - $(MAKE) -f $(TOP)/Makefile CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG) -module Simple_baseline' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG) -module Simple_baseline' \ TARGET='$(TARGET)_baseline' INTERFACE='$(INTERFACE)' python_cpp - $(MAKE) -f $(TOP)/Makefile CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG) -O -module Simple_optimized' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG) -O -module Simple_optimized' \ TARGET='$(TARGET)_optimized' INTERFACE='$(INTERFACE)' python_cpp - $(MAKE) -f $(TOP)/Makefile CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG) -builtin -O -module Simple_builtin' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG) -builtin -O -module Simple_builtin' \ TARGET='$(TARGET)_builtin' INTERFACE='$(INTERFACE)' python_cpp static: - $(MAKE) -f $(TOP)/Makefile CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ TARGET='mypython' INTERFACE='$(INTERFACE)' python_cpp_static clean: - $(MAKE) -f $(TOP)/Makefile TARGET='$(TARGET)' python_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' TARGET='$(TARGET)' python_clean rm -f $(TARGET)_*.py diff --git a/Examples/python/performance/operator/Makefile b/Examples/python/performance/operator/Makefile index 98a50ec29..8e65123cf 100644 --- a/Examples/python/performance/operator/Makefile +++ b/Examples/python/performance/operator/Makefile @@ -5,17 +5,17 @@ TARGET = Simple INTERFACE = Simple.i build: - $(MAKE) -f $(TOP)/Makefile CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG) -module Simple_baseline' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG) -module Simple_baseline' \ TARGET='$(TARGET)_baseline' INTERFACE='$(INTERFACE)' python_cpp - $(MAKE) -f $(TOP)/Makefile CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG) -O -module Simple_optimized' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG) -O -module Simple_optimized' \ TARGET='$(TARGET)_optimized' INTERFACE='$(INTERFACE)' python_cpp - $(MAKE) -f $(TOP)/Makefile CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG) -builtin -O -module Simple_builtin' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG) -builtin -O -module Simple_builtin' \ TARGET='$(TARGET)_builtin' INTERFACE='$(INTERFACE)' python_cpp static: - $(MAKE) -f $(TOP)/Makefile CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ TARGET='mypython' INTERFACE='$(INTERFACE)' python_cpp_static clean: - $(MAKE) -f $(TOP)/Makefile TARGET='$(TARGET)' python_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' TARGET='$(TARGET)' python_clean rm -f $(TARGET)_*.py diff --git a/Examples/python/pointer/Makefile b/Examples/python/pointer/Makefile index df3bc86ff..222916fa1 100644 --- a/Examples/python/pointer/Makefile +++ b/Examples/python/pointer/Makefile @@ -5,15 +5,15 @@ TARGET = example INTERFACE = example.i check: build - $(MAKE) -f $(TOP)/Makefile python_run + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' python_run build: - $(MAKE) -f $(TOP)/Makefile SRCS='$(SRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SRCS='$(SRCS)' SWIG='$(SWIG)' \ TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' python static: - $(MAKE) -f $(TOP)/Makefile SRCS='$(SRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SRCS='$(SRCS)' SWIG='$(SWIG)' \ TARGET='mypython' INTERFACE='$(INTERFACE)' python_static clean: - $(MAKE) -f $(TOP)/Makefile TARGET='$(TARGET)' python_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' TARGET='$(TARGET)' python_clean diff --git a/Examples/python/reference/Makefile b/Examples/python/reference/Makefile index e940c1f43..41cded284 100644 --- a/Examples/python/reference/Makefile +++ b/Examples/python/reference/Makefile @@ -6,15 +6,15 @@ INTERFACE = example.i LIBS = -lm check: build - $(MAKE) -f $(TOP)/Makefile python_run + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' python_run build: - $(MAKE) -f $(TOP)/Makefile CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' python_cpp static: - $(MAKE) -f $(TOP)/Makefile CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ TARGET='mypython' INTERFACE='$(INTERFACE)' python_cpp_static clean: - $(MAKE) -f $(TOP)/Makefile TARGET='$(TARGET)' python_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' TARGET='$(TARGET)' python_clean diff --git a/Examples/python/simple/Makefile b/Examples/python/simple/Makefile index df3bc86ff..222916fa1 100644 --- a/Examples/python/simple/Makefile +++ b/Examples/python/simple/Makefile @@ -5,15 +5,15 @@ TARGET = example INTERFACE = example.i check: build - $(MAKE) -f $(TOP)/Makefile python_run + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' python_run build: - $(MAKE) -f $(TOP)/Makefile SRCS='$(SRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SRCS='$(SRCS)' SWIG='$(SWIG)' \ TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' python static: - $(MAKE) -f $(TOP)/Makefile SRCS='$(SRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SRCS='$(SRCS)' SWIG='$(SWIG)' \ TARGET='mypython' INTERFACE='$(INTERFACE)' python_static clean: - $(MAKE) -f $(TOP)/Makefile TARGET='$(TARGET)' python_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' TARGET='$(TARGET)' python_clean diff --git a/Examples/python/smartptr/Makefile b/Examples/python/smartptr/Makefile index aaba9cbbc..19609353d 100644 --- a/Examples/python/smartptr/Makefile +++ b/Examples/python/smartptr/Makefile @@ -7,15 +7,15 @@ LIBS = -lm SWIGOPT = check: build - $(MAKE) -f $(TOP)/Makefile python_run + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' python_run build: - $(MAKE) -f $(TOP)/Makefile CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ SWIGOPT='$(SWIGOPT)' TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' python_cpp static: - $(MAKE) -f $(TOP)/Makefile CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ SWIGOPT='$(SWIGOPT)' TARGET='mypython' INTERFACE='$(INTERFACE)' python_cpp_static clean: - $(MAKE) -f $(TOP)/Makefile TARGET='$(TARGET)' python_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' TARGET='$(TARGET)' python_clean diff --git a/Examples/python/std_map/Makefile b/Examples/python/std_map/Makefile index 86a643415..f406dfaf4 100644 --- a/Examples/python/std_map/Makefile +++ b/Examples/python/std_map/Makefile @@ -7,15 +7,15 @@ LIBS = -lm SWIGOPT = check: build - $(MAKE) -f $(TOP)/Makefile python_run + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' python_run build: - $(MAKE) -f $(TOP)/Makefile CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ SWIGOPT='$(SWIGOPT)' TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' python_cpp static: - $(MAKE) -f $(TOP)/Makefile CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ SWIGOPT='$(SWIGOPT)' TARGET='mypython' INTERFACE='$(INTERFACE)' python_cpp_static clean: - $(MAKE) -f $(TOP)/Makefile TARGET='$(TARGET)' python_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' TARGET='$(TARGET)' python_clean diff --git a/Examples/python/std_vector/Makefile b/Examples/python/std_vector/Makefile index 86a643415..f406dfaf4 100644 --- a/Examples/python/std_vector/Makefile +++ b/Examples/python/std_vector/Makefile @@ -7,15 +7,15 @@ LIBS = -lm SWIGOPT = check: build - $(MAKE) -f $(TOP)/Makefile python_run + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' python_run build: - $(MAKE) -f $(TOP)/Makefile CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ SWIGOPT='$(SWIGOPT)' TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' python_cpp static: - $(MAKE) -f $(TOP)/Makefile CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ SWIGOPT='$(SWIGOPT)' TARGET='mypython' INTERFACE='$(INTERFACE)' python_cpp_static clean: - $(MAKE) -f $(TOP)/Makefile TARGET='$(TARGET)' python_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' TARGET='$(TARGET)' python_clean diff --git a/Examples/python/swigrun/Makefile b/Examples/python/swigrun/Makefile index c58f39caf..94f7d04e0 100644 --- a/Examples/python/swigrun/Makefile +++ b/Examples/python/swigrun/Makefile @@ -7,17 +7,17 @@ LIBS = -lm SWIGOPT = check: build - $(MAKE) -f $(TOP)/Makefile python_run + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' python_run build: $(SWIG) -python -external-runtime - $(MAKE) -f $(TOP)/Makefile $(SWIGLIB) CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' $(SWIGLIB) CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ SWIGOPT='$(SWIGOPT)' TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' python_cpp static: - $(MAKE) -f $(TOP)/Makefile $(SWIGLIB) CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' $(SWIGLIB) CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ SWIGOPT='$(SWIGOPT)' TARGET='mypython' INTERFACE='$(INTERFACE)' python_cpp_static clean: - $(MAKE) -f $(TOP)/Makefile TARGET='$(TARGET)' python_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' TARGET='$(TARGET)' python_clean rm -f swigpyrun.h diff --git a/Examples/python/template/Makefile b/Examples/python/template/Makefile index 86a643415..f406dfaf4 100644 --- a/Examples/python/template/Makefile +++ b/Examples/python/template/Makefile @@ -7,15 +7,15 @@ LIBS = -lm SWIGOPT = check: build - $(MAKE) -f $(TOP)/Makefile python_run + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' python_run build: - $(MAKE) -f $(TOP)/Makefile CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ SWIGOPT='$(SWIGOPT)' TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' python_cpp static: - $(MAKE) -f $(TOP)/Makefile CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ SWIGOPT='$(SWIGOPT)' TARGET='mypython' INTERFACE='$(INTERFACE)' python_cpp_static clean: - $(MAKE) -f $(TOP)/Makefile TARGET='$(TARGET)' python_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' TARGET='$(TARGET)' python_clean diff --git a/Examples/python/varargs/Makefile b/Examples/python/varargs/Makefile index 15ffa24c9..8ec6e9cc9 100644 --- a/Examples/python/varargs/Makefile +++ b/Examples/python/varargs/Makefile @@ -5,15 +5,15 @@ TARGET = example INTERFACE = example.i check: build - $(MAKE) -f $(TOP)/Makefile python_run + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' python_run build: - $(MAKE) -f $(TOP)/Makefile SRCS='$(SRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SRCS='$(SRCS)' SWIG='$(SWIG)' \ TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' python static: - $(MAKE) -f $(TOP)/Makefile SRCS='$(SRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SRCS='$(SRCS)' SWIG='$(SWIG)' \ TARGET='mypython' INTERFACE='$(INTERFACE)' python_static clean: - $(MAKE) -f $(TOP)/Makefile TARGET='$(TARGET)' python_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' TARGET='$(TARGET)' python_clean diff --git a/Examples/python/variables/Makefile b/Examples/python/variables/Makefile index df3bc86ff..222916fa1 100644 --- a/Examples/python/variables/Makefile +++ b/Examples/python/variables/Makefile @@ -5,15 +5,15 @@ TARGET = example INTERFACE = example.i check: build - $(MAKE) -f $(TOP)/Makefile python_run + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' python_run build: - $(MAKE) -f $(TOP)/Makefile SRCS='$(SRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SRCS='$(SRCS)' SWIG='$(SWIG)' \ TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' python static: - $(MAKE) -f $(TOP)/Makefile SRCS='$(SRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SRCS='$(SRCS)' SWIG='$(SWIG)' \ TARGET='mypython' INTERFACE='$(INTERFACE)' python_static clean: - $(MAKE) -f $(TOP)/Makefile TARGET='$(TARGET)' python_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' TARGET='$(TARGET)' python_clean diff --git a/Examples/r/class/Makefile b/Examples/r/class/Makefile index 8a64f49a9..3e5d6a6ca 100644 --- a/Examples/r/class/Makefile +++ b/Examples/r/class/Makefile @@ -5,11 +5,11 @@ TARGET = example INTERFACE = example.i check: build - $(MAKE) -f $(TOP)/Makefile r_run + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' r_run build: - $(MAKE) -f $(TOP)/Makefile CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' r_cpp clean: - $(MAKE) -f $(TOP)/Makefile INTERFACE='$(INTERFACE)' r_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' INTERFACE='$(INTERFACE)' r_clean diff --git a/Examples/r/simple/Makefile b/Examples/r/simple/Makefile index 8a8e0e1c1..5cc41530c 100644 --- a/Examples/r/simple/Makefile +++ b/Examples/r/simple/Makefile @@ -5,11 +5,11 @@ TARGET = example INTERFACE = example.i check: build - $(MAKE) -f $(TOP)/Makefile r_run + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' r_run build: - $(MAKE) -f $(TOP)/Makefile SRCS='$(SRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SRCS='$(SRCS)' SWIG='$(SWIG)' \ TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' r clean: - $(MAKE) -f $(TOP)/Makefile INTERFACE='$(INTERFACE)' r_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' INTERFACE='$(INTERFACE)' r_clean diff --git a/Examples/ruby/class/Makefile b/Examples/ruby/class/Makefile index ef267bc44..516f842d7 100644 --- a/Examples/ruby/class/Makefile +++ b/Examples/ruby/class/Makefile @@ -6,15 +6,15 @@ INTERFACE = example.i LIBS = -lm check: build - $(MAKE) -f $(TOP)/Makefile ruby_run + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' ruby_run build: - $(MAKE) -f $(TOP)/Makefile CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' ruby_cpp static: - $(MAKE) -f $(TOP)/Makefile CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ TARGET='myruby' INTERFACE='$(INTERFACE)' ruby_cpp_static clean: - $(MAKE) -f $(TOP)/Makefile ruby_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' ruby_clean diff --git a/Examples/ruby/constants/Makefile b/Examples/ruby/constants/Makefile index 7af9ec89e..561d5fd84 100644 --- a/Examples/ruby/constants/Makefile +++ b/Examples/ruby/constants/Makefile @@ -5,15 +5,15 @@ TARGET = example INTERFACE = example.i check: build - $(MAKE) -f $(TOP)/Makefile ruby_run + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' ruby_run build: - $(MAKE) -f $(TOP)/Makefile SRCS='$(SRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SRCS='$(SRCS)' SWIG='$(SWIG)' \ TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' ruby static: - $(MAKE) -f $(TOP)/Makefile SRCS='$(SRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SRCS='$(SRCS)' SWIG='$(SWIG)' \ TARGET='myruby' INTERFACE='$(INTERFACE)' ruby_static clean: - $(MAKE) -f $(TOP)/Makefile ruby_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' ruby_clean diff --git a/Examples/ruby/enum/Makefile b/Examples/ruby/enum/Makefile index ef267bc44..516f842d7 100644 --- a/Examples/ruby/enum/Makefile +++ b/Examples/ruby/enum/Makefile @@ -6,15 +6,15 @@ INTERFACE = example.i LIBS = -lm check: build - $(MAKE) -f $(TOP)/Makefile ruby_run + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' ruby_run build: - $(MAKE) -f $(TOP)/Makefile CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' ruby_cpp static: - $(MAKE) -f $(TOP)/Makefile CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ TARGET='myruby' INTERFACE='$(INTERFACE)' ruby_cpp_static clean: - $(MAKE) -f $(TOP)/Makefile ruby_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' ruby_clean diff --git a/Examples/ruby/exception_class/Makefile b/Examples/ruby/exception_class/Makefile index f0ae7e573..6723a2a7c 100644 --- a/Examples/ruby/exception_class/Makefile +++ b/Examples/ruby/exception_class/Makefile @@ -6,15 +6,15 @@ INTERFACE = example.i LIBS = -lm check: build - $(MAKE) -f $(TOP)/Makefile ruby_run + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' ruby_run build: - $(MAKE) -f $(TOP)/Makefile CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' ruby_cpp static: - $(MAKE) -f $(TOP)/Makefile CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ TARGET='myruby' INTERFACE='$(INTERFACE)' ruby_cpp_static clean: - $(MAKE) -f $(TOP)/Makefile ruby_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' ruby_clean diff --git a/Examples/ruby/free_function/Makefile b/Examples/ruby/free_function/Makefile index ef267bc44..516f842d7 100644 --- a/Examples/ruby/free_function/Makefile +++ b/Examples/ruby/free_function/Makefile @@ -6,15 +6,15 @@ INTERFACE = example.i LIBS = -lm check: build - $(MAKE) -f $(TOP)/Makefile ruby_run + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' ruby_run build: - $(MAKE) -f $(TOP)/Makefile CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' ruby_cpp static: - $(MAKE) -f $(TOP)/Makefile CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ TARGET='myruby' INTERFACE='$(INTERFACE)' ruby_cpp_static clean: - $(MAKE) -f $(TOP)/Makefile ruby_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' ruby_clean diff --git a/Examples/ruby/funcptr/Makefile b/Examples/ruby/funcptr/Makefile index ddbc1ae30..15b39cf0d 100644 --- a/Examples/ruby/funcptr/Makefile +++ b/Examples/ruby/funcptr/Makefile @@ -5,15 +5,15 @@ TARGET = example INTERFACE = example.i check: build - $(MAKE) -f $(TOP)/Makefile ruby_run + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' ruby_run build: - $(MAKE) -f $(TOP)/Makefile SRCS='$(SRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SRCS='$(SRCS)' SWIG='$(SWIG)' \ TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' ruby static: - $(MAKE) -f $(TOP)/Makefile SRCS='$(SRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SRCS='$(SRCS)' SWIG='$(SWIG)' \ TARGET='myruby' INTERFACE='$(INTERFACE)' ruby_static clean: - $(MAKE) -f $(TOP)/Makefile ruby_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' ruby_clean diff --git a/Examples/ruby/funcptr2/Makefile b/Examples/ruby/funcptr2/Makefile index ddbc1ae30..15b39cf0d 100644 --- a/Examples/ruby/funcptr2/Makefile +++ b/Examples/ruby/funcptr2/Makefile @@ -5,15 +5,15 @@ TARGET = example INTERFACE = example.i check: build - $(MAKE) -f $(TOP)/Makefile ruby_run + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' ruby_run build: - $(MAKE) -f $(TOP)/Makefile SRCS='$(SRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SRCS='$(SRCS)' SWIG='$(SWIG)' \ TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' ruby static: - $(MAKE) -f $(TOP)/Makefile SRCS='$(SRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SRCS='$(SRCS)' SWIG='$(SWIG)' \ TARGET='myruby' INTERFACE='$(INTERFACE)' ruby_static clean: - $(MAKE) -f $(TOP)/Makefile ruby_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' ruby_clean diff --git a/Examples/ruby/functor/Makefile b/Examples/ruby/functor/Makefile index 662baa110..348bd66e3 100644 --- a/Examples/ruby/functor/Makefile +++ b/Examples/ruby/functor/Makefile @@ -5,15 +5,15 @@ INTERFACE = example.i LIBS = -lm check: build - $(MAKE) -f $(TOP)/Makefile ruby_run + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' ruby_run build: - $(MAKE) -f $(TOP)/Makefile CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' ruby_cpp static: - $(MAKE) -f $(TOP)/Makefile CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ TARGET='myruby' INTERFACE='$(INTERFACE)' ruby_cpp_static clean: - $(MAKE) -f $(TOP)/Makefile ruby_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' ruby_clean diff --git a/Examples/ruby/hashargs/Makefile b/Examples/ruby/hashargs/Makefile index 3933cf279..59a36c0dd 100644 --- a/Examples/ruby/hashargs/Makefile +++ b/Examples/ruby/hashargs/Makefile @@ -7,15 +7,15 @@ LIBS = -lm SWIGOPT = check: build - $(MAKE) -f $(TOP)/Makefile ruby_run + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' ruby_run build: - $(MAKE) -f $(TOP)/Makefile SRCS='$(SRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SRCS='$(SRCS)' SWIG='$(SWIG)' \ SWIGOPT='$(SWIGOPT)' TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' ruby static: - $(MAKE) -f $(TOP)/Makefile SRCS='$(SRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SRCS='$(SRCS)' SWIG='$(SWIG)' \ TARGET='myruby' INTERFACE='$(INTERFACE)' ruby_static clean: - $(MAKE) -f $(TOP)/Makefile ruby_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' ruby_clean diff --git a/Examples/ruby/import/Makefile b/Examples/ruby/import/Makefile index cd7719b5c..b5d06bdd7 100644 --- a/Examples/ruby/import/Makefile +++ b/Examples/ruby/import/Makefile @@ -4,17 +4,17 @@ SWIGOPT = LIBS = check: build - $(MAKE) -f $(TOP)/Makefile ruby_run + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' ruby_run build: - $(MAKE) -f $(TOP)/Makefile SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT)' \ LIBS='$(LIBS)' TARGET='base' INTERFACE='base.i' ruby_cpp - $(MAKE) -f $(TOP)/Makefile SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT)' \ LIBS='$(LIBS)' TARGET='foo' INTERFACE='foo.i' ruby_cpp - $(MAKE) -f $(TOP)/Makefile SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT)' \ LIBS='$(LIBS)' TARGET='bar' INTERFACE='bar.i' ruby_cpp - $(MAKE) -f $(TOP)/Makefile SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT)' \ LIBS='$(LIBS)' TARGET='spam' INTERFACE='spam.i' ruby_cpp clean: - $(MAKE) -f $(TOP)/Makefile ruby_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' ruby_clean diff --git a/Examples/ruby/import_template/Makefile b/Examples/ruby/import_template/Makefile index cd7719b5c..b5d06bdd7 100644 --- a/Examples/ruby/import_template/Makefile +++ b/Examples/ruby/import_template/Makefile @@ -4,17 +4,17 @@ SWIGOPT = LIBS = check: build - $(MAKE) -f $(TOP)/Makefile ruby_run + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' ruby_run build: - $(MAKE) -f $(TOP)/Makefile SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT)' \ LIBS='$(LIBS)' TARGET='base' INTERFACE='base.i' ruby_cpp - $(MAKE) -f $(TOP)/Makefile SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT)' \ LIBS='$(LIBS)' TARGET='foo' INTERFACE='foo.i' ruby_cpp - $(MAKE) -f $(TOP)/Makefile SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT)' \ LIBS='$(LIBS)' TARGET='bar' INTERFACE='bar.i' ruby_cpp - $(MAKE) -f $(TOP)/Makefile SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT)' \ LIBS='$(LIBS)' TARGET='spam' INTERFACE='spam.i' ruby_cpp clean: - $(MAKE) -f $(TOP)/Makefile ruby_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' ruby_clean diff --git a/Examples/ruby/java/Makefile b/Examples/ruby/java/Makefile index a71635baa..7d611abd2 100644 --- a/Examples/ruby/java/Makefile +++ b/Examples/ruby/java/Makefile @@ -6,17 +6,17 @@ INTERFACE = example.i LIBS = -lm check: build - $(MAKE) -f $(TOP)/Makefile ruby_run + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' ruby_run build: Example.class Example.h - $(MAKE) -f $(TOP)/Makefile CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' \ CXXSHARED="gcj -fpic -shared Example.class" LIBS="-lstdc++" DEFS='' ruby_cpp clean: - $(MAKE) -f $(TOP)/Makefile ruby_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' ruby_clean rm -f *.class Example.h -Example.class Example.h: Example.java - gcj -fPIC -C -c -g Example.java +Example.class Example.h: $(SRCDIR)Example.java + gcj -d . -fPIC -C -c -g $(SRCDIR)Example.java gcjh Example.class diff --git a/Examples/ruby/mark_function/Makefile b/Examples/ruby/mark_function/Makefile index ef267bc44..516f842d7 100644 --- a/Examples/ruby/mark_function/Makefile +++ b/Examples/ruby/mark_function/Makefile @@ -6,15 +6,15 @@ INTERFACE = example.i LIBS = -lm check: build - $(MAKE) -f $(TOP)/Makefile ruby_run + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' ruby_run build: - $(MAKE) -f $(TOP)/Makefile CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' ruby_cpp static: - $(MAKE) -f $(TOP)/Makefile CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ TARGET='myruby' INTERFACE='$(INTERFACE)' ruby_cpp_static clean: - $(MAKE) -f $(TOP)/Makefile ruby_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' ruby_clean diff --git a/Examples/ruby/multimap/Makefile b/Examples/ruby/multimap/Makefile index ddbc1ae30..15b39cf0d 100644 --- a/Examples/ruby/multimap/Makefile +++ b/Examples/ruby/multimap/Makefile @@ -5,15 +5,15 @@ TARGET = example INTERFACE = example.i check: build - $(MAKE) -f $(TOP)/Makefile ruby_run + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' ruby_run build: - $(MAKE) -f $(TOP)/Makefile SRCS='$(SRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SRCS='$(SRCS)' SWIG='$(SWIG)' \ TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' ruby static: - $(MAKE) -f $(TOP)/Makefile SRCS='$(SRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SRCS='$(SRCS)' SWIG='$(SWIG)' \ TARGET='myruby' INTERFACE='$(INTERFACE)' ruby_static clean: - $(MAKE) -f $(TOP)/Makefile ruby_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' ruby_clean diff --git a/Examples/ruby/operator/Makefile b/Examples/ruby/operator/Makefile index 5fd4b077b..bdcf52646 100644 --- a/Examples/ruby/operator/Makefile +++ b/Examples/ruby/operator/Makefile @@ -7,15 +7,15 @@ LIBS = -lm SWIGOPT = check: build - $(MAKE) -f $(TOP)/Makefile ruby_run + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' ruby_run build: - $(MAKE) -f $(TOP)/Makefile CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ SWIGOPT='$(SWIGOPT)' TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' ruby_cpp static: - $(MAKE) -f $(TOP)/Makefile CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ TARGET='myruby' INTERFACE='$(INTERFACE)' ruby_cpp_static clean: - $(MAKE) -f $(TOP)/Makefile ruby_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' ruby_clean diff --git a/Examples/ruby/overloading/Makefile b/Examples/ruby/overloading/Makefile index ef267bc44..516f842d7 100644 --- a/Examples/ruby/overloading/Makefile +++ b/Examples/ruby/overloading/Makefile @@ -6,15 +6,15 @@ INTERFACE = example.i LIBS = -lm check: build - $(MAKE) -f $(TOP)/Makefile ruby_run + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' ruby_run build: - $(MAKE) -f $(TOP)/Makefile CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' ruby_cpp static: - $(MAKE) -f $(TOP)/Makefile CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ TARGET='myruby' INTERFACE='$(INTERFACE)' ruby_cpp_static clean: - $(MAKE) -f $(TOP)/Makefile ruby_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' ruby_clean diff --git a/Examples/ruby/pointer/Makefile b/Examples/ruby/pointer/Makefile index ddbc1ae30..15b39cf0d 100644 --- a/Examples/ruby/pointer/Makefile +++ b/Examples/ruby/pointer/Makefile @@ -5,15 +5,15 @@ TARGET = example INTERFACE = example.i check: build - $(MAKE) -f $(TOP)/Makefile ruby_run + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' ruby_run build: - $(MAKE) -f $(TOP)/Makefile SRCS='$(SRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SRCS='$(SRCS)' SWIG='$(SWIG)' \ TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' ruby static: - $(MAKE) -f $(TOP)/Makefile SRCS='$(SRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SRCS='$(SRCS)' SWIG='$(SWIG)' \ TARGET='myruby' INTERFACE='$(INTERFACE)' ruby_static clean: - $(MAKE) -f $(TOP)/Makefile ruby_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' ruby_clean diff --git a/Examples/ruby/reference/Makefile b/Examples/ruby/reference/Makefile index ef267bc44..516f842d7 100644 --- a/Examples/ruby/reference/Makefile +++ b/Examples/ruby/reference/Makefile @@ -6,15 +6,15 @@ INTERFACE = example.i LIBS = -lm check: build - $(MAKE) -f $(TOP)/Makefile ruby_run + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' ruby_run build: - $(MAKE) -f $(TOP)/Makefile CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' ruby_cpp static: - $(MAKE) -f $(TOP)/Makefile CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ TARGET='myruby' INTERFACE='$(INTERFACE)' ruby_cpp_static clean: - $(MAKE) -f $(TOP)/Makefile ruby_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' ruby_clean diff --git a/Examples/ruby/simple/Makefile b/Examples/ruby/simple/Makefile index ddbc1ae30..15b39cf0d 100644 --- a/Examples/ruby/simple/Makefile +++ b/Examples/ruby/simple/Makefile @@ -5,15 +5,15 @@ TARGET = example INTERFACE = example.i check: build - $(MAKE) -f $(TOP)/Makefile ruby_run + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' ruby_run build: - $(MAKE) -f $(TOP)/Makefile SRCS='$(SRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SRCS='$(SRCS)' SWIG='$(SWIG)' \ TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' ruby static: - $(MAKE) -f $(TOP)/Makefile SRCS='$(SRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SRCS='$(SRCS)' SWIG='$(SWIG)' \ TARGET='myruby' INTERFACE='$(INTERFACE)' ruby_static clean: - $(MAKE) -f $(TOP)/Makefile ruby_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' ruby_clean diff --git a/Examples/ruby/std_vector/Makefile b/Examples/ruby/std_vector/Makefile index 208a64495..370bd8fb6 100644 --- a/Examples/ruby/std_vector/Makefile +++ b/Examples/ruby/std_vector/Makefile @@ -7,15 +7,15 @@ LIBS = -lm SWIGOPT = check: build - $(MAKE) -f $(TOP)/Makefile ruby_run + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' ruby_run build: - $(MAKE) -f $(TOP)/Makefile CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ SWIGOPT='$(SWIGOPT)' TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' ruby_cpp static: - $(MAKE) -f $(TOP)/Makefile CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ SWIGOPT='$(SWIGOPT)' TARGET='myruby' INTERFACE='$(INTERFACE)' ruby_cpp_static clean: - $(MAKE) -f $(TOP)/Makefile ruby_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' ruby_clean diff --git a/Examples/ruby/template/Makefile b/Examples/ruby/template/Makefile index 208a64495..370bd8fb6 100644 --- a/Examples/ruby/template/Makefile +++ b/Examples/ruby/template/Makefile @@ -7,15 +7,15 @@ LIBS = -lm SWIGOPT = check: build - $(MAKE) -f $(TOP)/Makefile ruby_run + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' ruby_run build: - $(MAKE) -f $(TOP)/Makefile CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ SWIGOPT='$(SWIGOPT)' TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' ruby_cpp static: - $(MAKE) -f $(TOP)/Makefile CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ SWIGOPT='$(SWIGOPT)' TARGET='myruby' INTERFACE='$(INTERFACE)' ruby_cpp_static clean: - $(MAKE) -f $(TOP)/Makefile ruby_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' ruby_clean diff --git a/Examples/ruby/value/Makefile b/Examples/ruby/value/Makefile index ddbc1ae30..15b39cf0d 100644 --- a/Examples/ruby/value/Makefile +++ b/Examples/ruby/value/Makefile @@ -5,15 +5,15 @@ TARGET = example INTERFACE = example.i check: build - $(MAKE) -f $(TOP)/Makefile ruby_run + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' ruby_run build: - $(MAKE) -f $(TOP)/Makefile SRCS='$(SRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SRCS='$(SRCS)' SWIG='$(SWIG)' \ TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' ruby static: - $(MAKE) -f $(TOP)/Makefile SRCS='$(SRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SRCS='$(SRCS)' SWIG='$(SWIG)' \ TARGET='myruby' INTERFACE='$(INTERFACE)' ruby_static clean: - $(MAKE) -f $(TOP)/Makefile ruby_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' ruby_clean diff --git a/Examples/ruby/variables/Makefile b/Examples/ruby/variables/Makefile index ddbc1ae30..15b39cf0d 100644 --- a/Examples/ruby/variables/Makefile +++ b/Examples/ruby/variables/Makefile @@ -5,15 +5,15 @@ TARGET = example INTERFACE = example.i check: build - $(MAKE) -f $(TOP)/Makefile ruby_run + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' ruby_run build: - $(MAKE) -f $(TOP)/Makefile SRCS='$(SRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SRCS='$(SRCS)' SWIG='$(SWIG)' \ TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' ruby static: - $(MAKE) -f $(TOP)/Makefile SRCS='$(SRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SRCS='$(SRCS)' SWIG='$(SWIG)' \ TARGET='myruby' INTERFACE='$(INTERFACE)' ruby_static clean: - $(MAKE) -f $(TOP)/Makefile ruby_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' ruby_clean diff --git a/Examples/tcl/class/Makefile b/Examples/tcl/class/Makefile index db6149cb3..aacf30e04 100644 --- a/Examples/tcl/class/Makefile +++ b/Examples/tcl/class/Makefile @@ -6,15 +6,15 @@ INTERFACE = example.i LIBS = -lm check: build - $(MAKE) -f $(TOP)/Makefile tcl_run + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' tcl_run build: - $(MAKE) -f $(TOP)/Makefile CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' tcl_cpp static: - $(MAKE) -f $(TOP)/Makefile CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ TARGET='mytclsh' INTERFACE='$(INTERFACE)' tclsh_cpp_static clean: - $(MAKE) -f $(TOP)/Makefile tcl_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' tcl_clean diff --git a/Examples/tcl/constants/Makefile b/Examples/tcl/constants/Makefile index ed4d89f52..17c8afa3f 100644 --- a/Examples/tcl/constants/Makefile +++ b/Examples/tcl/constants/Makefile @@ -6,15 +6,15 @@ DLTARGET = example INTERFACE = example.i check: build - $(MAKE) -f $(TOP)/Makefile tcl_run + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' tcl_run build: - $(MAKE) -f $(TOP)/Makefile SRCS='$(SRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SRCS='$(SRCS)' SWIG='$(SWIG)' \ TARGET='$(DLTARGET)' INTERFACE='$(INTERFACE)' tcl static: - $(MAKE) -f $(TOP)/Makefile SRCS='$(SRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SRCS='$(SRCS)' SWIG='$(SWIG)' \ TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' tclsh clean: - $(MAKE) -f $(TOP)/Makefile tcl_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' tcl_clean diff --git a/Examples/tcl/contract/Makefile b/Examples/tcl/contract/Makefile index ca6134e75..01fdc37b3 100644 --- a/Examples/tcl/contract/Makefile +++ b/Examples/tcl/contract/Makefile @@ -7,15 +7,15 @@ INTERFACE = example.i SWIGOPT = check: build - $(MAKE) -f $(TOP)/Makefile tcl_run + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' tcl_run build: - $(MAKE) -f $(TOP)/Makefile SRCS='$(SRCS)' SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SRCS='$(SRCS)' SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT)' \ TARGET='$(DLTARGET)' INTERFACE='$(INTERFACE)' tcl static: - $(MAKE) -f $(TOP)/Makefile SRCS='$(SRCS)' SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SRCS='$(SRCS)' SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT)' \ TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' tclsh clean: - $(MAKE) -f $(TOP)/Makefile tcl_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' tcl_clean diff --git a/Examples/tcl/enum/Makefile b/Examples/tcl/enum/Makefile index db6149cb3..aacf30e04 100644 --- a/Examples/tcl/enum/Makefile +++ b/Examples/tcl/enum/Makefile @@ -6,15 +6,15 @@ INTERFACE = example.i LIBS = -lm check: build - $(MAKE) -f $(TOP)/Makefile tcl_run + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' tcl_run build: - $(MAKE) -f $(TOP)/Makefile CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' tcl_cpp static: - $(MAKE) -f $(TOP)/Makefile CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ TARGET='mytclsh' INTERFACE='$(INTERFACE)' tclsh_cpp_static clean: - $(MAKE) -f $(TOP)/Makefile tcl_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' tcl_clean diff --git a/Examples/tcl/funcptr/Makefile b/Examples/tcl/funcptr/Makefile index 919077918..7155bf3c3 100644 --- a/Examples/tcl/funcptr/Makefile +++ b/Examples/tcl/funcptr/Makefile @@ -6,15 +6,15 @@ DLTARGET = example INTERFACE = example.i check: build - $(MAKE) -f $(TOP)/Makefile tcl_run + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' tcl_run build: - $(MAKE) -f $(TOP)/Makefile SRCS='$(SRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SRCS='$(SRCS)' SWIG='$(SWIG)' \ TARGET='$(DLTARGET)' INTERFACE='$(INTERFACE)' tcl static: - $(MAKE) -f $(TOP)/Makefile SRCS='$(SRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SRCS='$(SRCS)' SWIG='$(SWIG)' \ TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' tclsh clean: - $(MAKE) -f $(TOP)/Makefile tcl_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' tcl_clean diff --git a/Examples/tcl/import/Makefile b/Examples/tcl/import/Makefile index 81cd7c471..6aa48e7a8 100644 --- a/Examples/tcl/import/Makefile +++ b/Examples/tcl/import/Makefile @@ -4,18 +4,18 @@ SWIGOPT = LIBS = check: build - $(MAKE) -f $(TOP)/Makefile tcl_run + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' tcl_run build: - $(MAKE) -f $(TOP)/Makefile SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT)' \ LIBS='$(LIBS)' TARGET='base' INTERFACE='base.i' tcl_cpp - $(MAKE) -f $(TOP)/Makefile SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT)' \ LIBS='$(LIBS)' TARGET='foo' INTERFACE='foo.i' tcl_cpp - $(MAKE) -f $(TOP)/Makefile SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT)' \ LIBS='$(LIBS)' TARGET='bar' INTERFACE='bar.i' tcl_cpp - $(MAKE) -f $(TOP)/Makefile SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT)' \ LIBS='$(LIBS)' TARGET='spam' INTERFACE='spam.i' tcl_cpp clean: - $(MAKE) -f $(TOP)/Makefile tcl_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' tcl_clean diff --git a/Examples/tcl/java/Makefile b/Examples/tcl/java/Makefile index a3819ab7c..4be3764e2 100644 --- a/Examples/tcl/java/Makefile +++ b/Examples/tcl/java/Makefile @@ -6,17 +6,17 @@ INTERFACE = example.i LIBS = -lm check: build - $(MAKE) -f $(TOP)/Makefile tcl_run + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' tcl_run build: Example.class Example.h - $(MAKE) -f $(TOP)/Makefile CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' \ TCLCXXSHARED="gcj -fpic -shared Example.class " LIBS="-lstdc++" DEFS='' tcl_cpp clean: - $(MAKE) -f $(TOP)/Makefile tcl_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' tcl_clean rm -f *.class Example.h -Example.class Example.h: Example.java - gcj -fPIC -C -c -g Example.java +Example.class Example.h: $(SRCDIR)Example.java + gcj -d . -fPIC -C -c -g $(SRCDIR)Example.java gcjh Example.class diff --git a/Examples/tcl/multimap/Makefile b/Examples/tcl/multimap/Makefile index 919077918..7155bf3c3 100644 --- a/Examples/tcl/multimap/Makefile +++ b/Examples/tcl/multimap/Makefile @@ -6,15 +6,15 @@ DLTARGET = example INTERFACE = example.i check: build - $(MAKE) -f $(TOP)/Makefile tcl_run + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' tcl_run build: - $(MAKE) -f $(TOP)/Makefile SRCS='$(SRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SRCS='$(SRCS)' SWIG='$(SWIG)' \ TARGET='$(DLTARGET)' INTERFACE='$(INTERFACE)' tcl static: - $(MAKE) -f $(TOP)/Makefile SRCS='$(SRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SRCS='$(SRCS)' SWIG='$(SWIG)' \ TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' tclsh clean: - $(MAKE) -f $(TOP)/Makefile tcl_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' tcl_clean diff --git a/Examples/tcl/operator/Makefile b/Examples/tcl/operator/Makefile index 6c91c3d21..1c6e1be98 100644 --- a/Examples/tcl/operator/Makefile +++ b/Examples/tcl/operator/Makefile @@ -6,15 +6,15 @@ INTERFACE = example.i LIBS = -lm check: build - $(MAKE) -f $(TOP)/Makefile tcl_run + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' tcl_run build: - $(MAKE) -f $(TOP)/Makefile CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' tcl_cpp static: - $(MAKE) -f $(TOP)/Makefile CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ TARGET='mytclsh' INTERFACE='$(INTERFACE)' tclsh_cpp_static clean: - $(MAKE) -f $(TOP)/Makefile tcl_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' tcl_clean diff --git a/Examples/tcl/pointer/Makefile b/Examples/tcl/pointer/Makefile index 919077918..7155bf3c3 100644 --- a/Examples/tcl/pointer/Makefile +++ b/Examples/tcl/pointer/Makefile @@ -6,15 +6,15 @@ DLTARGET = example INTERFACE = example.i check: build - $(MAKE) -f $(TOP)/Makefile tcl_run + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' tcl_run build: - $(MAKE) -f $(TOP)/Makefile SRCS='$(SRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SRCS='$(SRCS)' SWIG='$(SWIG)' \ TARGET='$(DLTARGET)' INTERFACE='$(INTERFACE)' tcl static: - $(MAKE) -f $(TOP)/Makefile SRCS='$(SRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SRCS='$(SRCS)' SWIG='$(SWIG)' \ TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' tclsh clean: - $(MAKE) -f $(TOP)/Makefile tcl_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' tcl_clean diff --git a/Examples/tcl/reference/Makefile b/Examples/tcl/reference/Makefile index db6149cb3..aacf30e04 100644 --- a/Examples/tcl/reference/Makefile +++ b/Examples/tcl/reference/Makefile @@ -6,15 +6,15 @@ INTERFACE = example.i LIBS = -lm check: build - $(MAKE) -f $(TOP)/Makefile tcl_run + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' tcl_run build: - $(MAKE) -f $(TOP)/Makefile CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' tcl_cpp static: - $(MAKE) -f $(TOP)/Makefile CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ TARGET='mytclsh' INTERFACE='$(INTERFACE)' tclsh_cpp_static clean: - $(MAKE) -f $(TOP)/Makefile tcl_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' tcl_clean diff --git a/Examples/tcl/simple/Makefile b/Examples/tcl/simple/Makefile index 919077918..7155bf3c3 100644 --- a/Examples/tcl/simple/Makefile +++ b/Examples/tcl/simple/Makefile @@ -6,15 +6,15 @@ DLTARGET = example INTERFACE = example.i check: build - $(MAKE) -f $(TOP)/Makefile tcl_run + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' tcl_run build: - $(MAKE) -f $(TOP)/Makefile SRCS='$(SRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SRCS='$(SRCS)' SWIG='$(SWIG)' \ TARGET='$(DLTARGET)' INTERFACE='$(INTERFACE)' tcl static: - $(MAKE) -f $(TOP)/Makefile SRCS='$(SRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SRCS='$(SRCS)' SWIG='$(SWIG)' \ TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' tclsh clean: - $(MAKE) -f $(TOP)/Makefile tcl_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' tcl_clean diff --git a/Examples/tcl/std_vector/Makefile b/Examples/tcl/std_vector/Makefile index a150fc956..f29f933ba 100644 --- a/Examples/tcl/std_vector/Makefile +++ b/Examples/tcl/std_vector/Makefile @@ -7,15 +7,15 @@ INTERFACE = example.i LIBS = -lm check: build - $(MAKE) -f $(TOP)/Makefile tcl_run + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' tcl_run build: - $(MAKE) -f $(TOP)/Makefile CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ TARGET='$(DLTARGET)' INTERFACE='$(INTERFACE)' tcl_cpp static: - $(MAKE) -f $(TOP)/Makefile CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' tclsh_cpp_static clean: - $(MAKE) -f $(TOP)/Makefile tcl_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' tcl_clean diff --git a/Examples/tcl/value/Makefile b/Examples/tcl/value/Makefile index 919077918..7155bf3c3 100644 --- a/Examples/tcl/value/Makefile +++ b/Examples/tcl/value/Makefile @@ -6,15 +6,15 @@ DLTARGET = example INTERFACE = example.i check: build - $(MAKE) -f $(TOP)/Makefile tcl_run + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' tcl_run build: - $(MAKE) -f $(TOP)/Makefile SRCS='$(SRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SRCS='$(SRCS)' SWIG='$(SWIG)' \ TARGET='$(DLTARGET)' INTERFACE='$(INTERFACE)' tcl static: - $(MAKE) -f $(TOP)/Makefile SRCS='$(SRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SRCS='$(SRCS)' SWIG='$(SWIG)' \ TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' tclsh clean: - $(MAKE) -f $(TOP)/Makefile tcl_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' tcl_clean diff --git a/Examples/tcl/variables/Makefile b/Examples/tcl/variables/Makefile index 919077918..7155bf3c3 100644 --- a/Examples/tcl/variables/Makefile +++ b/Examples/tcl/variables/Makefile @@ -6,15 +6,15 @@ DLTARGET = example INTERFACE = example.i check: build - $(MAKE) -f $(TOP)/Makefile tcl_run + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' tcl_run build: - $(MAKE) -f $(TOP)/Makefile SRCS='$(SRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SRCS='$(SRCS)' SWIG='$(SWIG)' \ TARGET='$(DLTARGET)' INTERFACE='$(INTERFACE)' tcl static: - $(MAKE) -f $(TOP)/Makefile SRCS='$(SRCS)' SWIG='$(SWIG)' \ + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SRCS='$(SRCS)' SWIG='$(SWIG)' \ TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' tclsh clean: - $(MAKE) -f $(TOP)/Makefile tcl_clean + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' tcl_clean diff --git a/Examples/test-suite/allegrocl/Makefile.in b/Examples/test-suite/allegrocl/Makefile.in index 697c15a45..2803b7012 100644 --- a/Examples/test-suite/allegrocl/Makefile.in +++ b/Examples/test-suite/allegrocl/Makefile.in @@ -5,9 +5,15 @@ LANGUAGE = allegrocl ALLEGROCL = @ALLEGROCLBIN@ SCRIPTSUFFIX = _runme.lisp + srcdir = @srcdir@ top_srcdir = @top_srcdir@ top_builddir = @top_builddir@ +ifeq (.,$(srcdir)) +SRCDIR = +else +SRCDIR = $(srcdir)/ +endif # these cpp tests generate warnings/errors when compiling diff --git a/Examples/test-suite/cffi/Makefile.in b/Examples/test-suite/cffi/Makefile.in index 473d395fd..a530e2243 100644 --- a/Examples/test-suite/cffi/Makefile.in +++ b/Examples/test-suite/cffi/Makefile.in @@ -5,9 +5,15 @@ LANGUAGE = cffi CFFI = @CFFIBIN@ SCRIPTSUFFIX = _runme.lisp + srcdir = @srcdir@ top_srcdir = @top_srcdir@ top_builddir = @top_builddir@ +ifeq (.,$(srcdir)) +SRCDIR = +else +SRCDIR = $(srcdir)/ +endif include $(srcdir)/../common.mk diff --git a/Examples/test-suite/chicken/Makefile.in b/Examples/test-suite/chicken/Makefile.in index 4ee8cb0fa..ac02dad83 100644 --- a/Examples/test-suite/chicken/Makefile.in +++ b/Examples/test-suite/chicken/Makefile.in @@ -6,9 +6,16 @@ LANGUAGE = chicken VARIANT = SCRIPTSUFFIX = _runme.ss PROXYSUFFIX = _runme_proxy.ss + srcdir = @srcdir@ top_srcdir = @top_srcdir@ top_builddir = @top_builddir@ +ifeq (.,$(srcdir)) +SRCDIR = +else +SRCDIR = $(srcdir)/ +endif + CHICKEN_CSI = @CHICKEN_CSI@ -quiet -batch -no-init SO = @SO@ diff --git a/Examples/test-suite/clisp/Makefile.in b/Examples/test-suite/clisp/Makefile.in index 1fe3c23ac..9db84c561 100644 --- a/Examples/test-suite/clisp/Makefile.in +++ b/Examples/test-suite/clisp/Makefile.in @@ -5,9 +5,15 @@ LANGUAGE = clisp CLISP = @CLISPBIN@ SCRIPTSUFFIX = _runme.lisp + srcdir = @srcdir@ top_srcdir = @top_srcdir@ top_builddir = @top_builddir@ +ifeq (.,$(srcdir)) +SRCDIR = +else +SRCDIR = $(srcdir)/ +endif include $(srcdir)/../common.mk diff --git a/Examples/test-suite/common.mk b/Examples/test-suite/common.mk index bdd1cd471..37d660989 100644 --- a/Examples/test-suite/common.mk +++ b/Examples/test-suite/common.mk @@ -69,7 +69,7 @@ INCLUDES = -I$(top_srcdir)/$(EXAMPLES)/$(TEST_SUITE) LIBS = -L. LIBPREFIX = lib ACTION = check -INTERFACEDIR = $(top_srcdir)/$(EXAMPLES)/$(TEST_SUITE)/ +INTERFACEDIR = ../ # Regenerate Makefile if Makefile.in or config.status have changed. ifeq (,$(TEST_SUITE_SUBDIR)) @@ -688,14 +688,14 @@ partialcheck: $(MAKE) check CC=true CXX=true LDSHARED=true CXXSHARED=true RUNTOOL=true COMPILETOOL=true swig_and_compile_cpp = \ - $(MAKE) -f $(top_builddir)/$(EXAMPLES)/Makefile CXXSRCS="$(CXXSRCS)" \ + $(MAKE) -f $(top_builddir)/$(EXAMPLES)/Makefile SRCDIR="$(SRCDIR)" CXXSRCS="$(CXXSRCS)" \ SWIG_LIB="$(SWIG_LIB)" SWIG="$(SWIG)" \ INCLUDES="$(INCLUDES)" SWIGOPT="$(SWIGOPT)" NOLINK=true \ TARGET="$(TARGETPREFIX)$*$(TARGETSUFFIX)" INTERFACEDIR="$(INTERFACEDIR)" INTERFACE="$*.i" \ $(LANGUAGE)$(VARIANT)_cpp swig_and_compile_c = \ - $(MAKE) -f $(top_builddir)/$(EXAMPLES)/Makefile CSRCS="$(CSRCS)" \ + $(MAKE) -f $(top_builddir)/$(EXAMPLES)/Makefile SRCDIR="$(SRCDIR)" CSRCS="$(CSRCS)" \ SWIG_LIB="$(SWIG_LIB)" SWIG="$(SWIG)" \ INCLUDES="$(INCLUDES)" SWIGOPT="$(SWIGOPT)" NOLINK=true \ TARGET="$(TARGETPREFIX)$*$(TARGETSUFFIX)" INTERFACEDIR="$(INTERFACEDIR)" INTERFACE="$*.i" \ @@ -703,7 +703,7 @@ swig_and_compile_c = \ swig_and_compile_multi_cpp = \ for f in `cat $(top_srcdir)/$(EXAMPLES)/$(TEST_SUITE)/$*.list` ; do \ - $(MAKE) -f $(top_builddir)/$(EXAMPLES)/Makefile CXXSRCS="$(CXXSRCS)" \ + $(MAKE) -f $(top_builddir)/$(EXAMPLES)/Makefile SRCDIR="$(SRCDIR)" CXXSRCS="$(CXXSRCS)" \ SWIG_LIB="$(SWIG_LIB)" SWIG="$(SWIG)" LIBS='$(LIBS)' \ INCLUDES="$(INCLUDES)" SWIGOPT="$(SWIGOPT)" NOLINK=true \ TARGET="$(TARGETPREFIX)$${f}$(TARGETSUFFIX)" INTERFACEDIR="$(INTERFACEDIR)" INTERFACE="$$f.i" \ @@ -711,11 +711,11 @@ swig_and_compile_multi_cpp = \ done swig_and_compile_external = \ - $(MAKE) -f $(top_builddir)/$(EXAMPLES)/Makefile \ + $(MAKE) -f $(top_builddir)/$(EXAMPLES)/Makefile SRCDIR="$(SRCDIR)" \ SWIG_LIB="$(SWIG_LIB)" SWIG="$(SWIG)" \ TARGET="$*_wrap_hdr.h" \ $(LANGUAGE)$(VARIANT)_externalhdr; \ - $(MAKE) -f $(top_builddir)/$(EXAMPLES)/Makefile CXXSRCS="$(CXXSRCS) $*_external.cxx" \ + $(MAKE) -f $(top_builddir)/$(EXAMPLES)/Makefile SRCDIR="$(SRCDIR)" CXXSRCS="$(CXXSRCS) $*_external.cxx" \ SWIG_LIB="$(SWIG_LIB)" SWIG="$(SWIG)" \ INCLUDES="$(INCLUDES)" SWIGOPT="$(SWIGOPT)" NOLINK=true \ TARGET="$(TARGETPREFIX)$*$(TARGETSUFFIX)" INTERFACEDIR="$(INTERFACEDIR)" INTERFACE="$*.i" \ @@ -724,7 +724,7 @@ swig_and_compile_external = \ swig_and_compile_runtime = \ setup = \ - if [ -f $(srcdir)/$(SCRIPTPREFIX)$*$(SCRIPTSUFFIX) ]; then \ + if [ -f $(SCRIPTDIR)/$(SCRIPTPREFIX)$*$(SCRIPTSUFFIX) ]; then \ echo "$(ACTION)ing $(LANGUAGE) testcase $* (with run test)" ; \ else \ echo "$(ACTION)ing $(LANGUAGE) testcase $*" ; \ diff --git a/Examples/test-suite/csharp/Makefile.in b/Examples/test-suite/csharp/Makefile.in index e54edcc35..a2a0828fd 100644 --- a/Examples/test-suite/csharp/Makefile.in +++ b/Examples/test-suite/csharp/Makefile.in @@ -3,14 +3,21 @@ ####################################################################### LANGUAGE = csharp +SCRIPTDIR = $(srcdir) SCRIPTSUFFIX = _runme.cs CSHARPCILINTERPRETER = @CSHARPCILINTERPRETER@ CSHARPCILINTERPRETER_FLAGS = @CSHARPCILINTERPRETER_FLAGS@ CSHARPPATHSEPARATOR = "@CSHARPPATHSEPARATOR@" CSHARPCYGPATH_W = @CSHARPCYGPATH_W@ + srcdir = @srcdir@ top_srcdir = ../@top_srcdir@ top_builddir = ../@top_builddir@ +ifeq (.,$(srcdir)) +SRCDIR = ../ +else +SRCDIR = ../$(srcdir)/ +endif CPP_TEST_CASES = \ csharp_attributes \ @@ -57,7 +64,7 @@ csharp_swig2_compatibility.cpptest: SWIGOPT += -DSWIG2_CSHARP # Makes a directory for the testcase if it does not exist setup = \ - if [ -f $(srcdir)/$(SCRIPTPREFIX)$*$(SCRIPTSUFFIX) ]; then \ + if [ -f $(SCRIPTDIR)/$(SCRIPTPREFIX)$*$(SCRIPTSUFFIX) ]; then \ echo "$(ACTION)ing $(LANGUAGE) testcase $* (with run test)" ; \ else \ echo "$(ACTION)ing $(LANGUAGE) testcase $*" ; \ @@ -71,10 +78,10 @@ setup = \ # Note C# uses LD_LIBRARY_PATH under Unix, PATH under Cygwin/Windows and SHLIB_PATH on HPUX. # DYLD_FALLBACK_LIBRARY_PATH is cleared for MacOSX. run_testcase = \ - if [ -f $(srcdir)/$(SCRIPTPREFIX)$*$(SCRIPTSUFFIX) ]; then \ + if [ -f $(SCRIPTDIR)/$(SCRIPTPREFIX)$*$(SCRIPTSUFFIX) ]; then \ $(MAKE) -f $*/$(top_builddir)/$(EXAMPLES)/Makefile \ CSHARPFLAGS='-nologo -debug+ $(CSHARPFLAGSSPECIAL) -out:$*_runme.exe' \ - CSHARPSRCS='`$(CSHARPCYGPATH_W) $(srcdir)/$(SCRIPTPREFIX)$*$(SCRIPTSUFFIX)` `find $* -name "*.cs" -exec $(CSHARPCYGPATH_W) "{}" \+`' csharp_compile && \ + CSHARPSRCS='`$(CSHARPCYGPATH_W) $(SCRIPTDIR)/$(SCRIPTPREFIX)$*$(SCRIPTSUFFIX)` `find $* -name "*.cs" -exec $(CSHARPCYGPATH_W) "{}" \+`' csharp_compile && \ env LD_LIBRARY_PATH="$*:$$LD_LIBRARY_PATH" PATH="$*:$$PATH" SHLIB_PATH="$*:$$SHLIB_PATH" DYLD_FALLBACK_LIBRARY_PATH= $(RUNTOOL) $(CSHARPCILINTERPRETER) $(CSHARPCILINTERPRETER_FLAGS) ./$*_runme.exe; \ else \ cd $* && \ diff --git a/Examples/test-suite/d/Makefile.in b/Examples/test-suite/d/Makefile.in index 61c2749dc..0542bbad0 100644 --- a/Examples/test-suite/d/Makefile.in +++ b/Examples/test-suite/d/Makefile.in @@ -3,9 +3,15 @@ ####################################################################### LANGUAGE = d + srcdir = @srcdir@ -top_srcdir = ../@top_srcdir@ -top_builddir = ../@top_builddir@ +top_srcdir = @top_srcdir@ +top_builddir = @top_builddir@ +ifeq (.,$(srcdir)) +SRCDIR = +else +SRCDIR = $(srcdir)/ +endif ifeq (2,$(D_VERSION)) VERSIONSUFFIX = .2 diff --git a/Examples/test-suite/errors/Makefile.in b/Examples/test-suite/errors/Makefile.in index 843283e7c..c74e9c65b 100644 --- a/Examples/test-suite/errors/Makefile.in +++ b/Examples/test-suite/errors/Makefile.in @@ -22,9 +22,18 @@ TODOS = tr -d '\r' srcdir = @srcdir@ top_srcdir = @top_srcdir@ top_builddir = @top_builddir@ +ifeq (.,$(srcdir)) +SRCDIR = +else +SRCDIR = $(srcdir)/ +endif + +# strip source directory from output, so that diffs compare +srcdir_regexp = $(shell echo $(srcdir)/ | sed 's/\./[.]/g') +STRIP_SRCDIR = sed 's|^$(srcdir_regexp)||' # All .i files with prefix 'cpp_' will be treated as C++ input and remaining .i files as C input -ALL_ERROR_TEST_CASES := $(patsubst %.i,%, $(wildcard *.i)) +ALL_ERROR_TEST_CASES := $(patsubst %.i,%, $(notdir $(wildcard $(srcdir)/*.i))) CPP_ERROR_TEST_CASES := $(filter cpp_%, $(ALL_ERROR_TEST_CASES)) C_ERROR_TEST_CASES := $(filter-out $(CPP_ERROR_TEST_CASES), $(ALL_ERROR_TEST_CASES)) @@ -40,13 +49,13 @@ include $(srcdir)/../common.mk # Rules for the different types of tests %.cpptest: echo "$(ACTION)ing errors testcase $*" - -$(SWIG) -c++ -python -Wall -Fstandard $(SWIGOPT) $*.i 2>&1 | $(TODOS) > $*.$(ERROR_EXT) - $(COMPILETOOL) diff -c $*.stderr $*.$(ERROR_EXT) + -$(SWIG) -c++ -python -Wall -Fstandard $(SWIGOPT) $(srcdir)/$*.i 2>&1 | $(TODOS) | $(STRIP_SRCDIR) > $*.$(ERROR_EXT) + $(COMPILETOOL) diff -c $(srcdir)/$*.stderr $*.$(ERROR_EXT) %.ctest: echo "$(ACTION)ing errors testcase $*" - -$(SWIG) -python -Wall -Fstandard $(SWIGOPT) $*.i 2>&1 | $(TODOS) > $*.$(ERROR_EXT) - $(COMPILETOOL) diff -c $*.stderr $*.$(ERROR_EXT) + -$(SWIG) -python -Wall -Fstandard $(SWIGOPT) $(srcdir)/$*.i 2>&1 | $(TODOS) | $(STRIP_SRCDIR) > $*.$(ERROR_EXT) + $(COMPILETOOL) diff -c $(srcdir)/$*.stderr $*.$(ERROR_EXT) %.clean: @exit 0 diff --git a/Examples/test-suite/go/Makefile.in b/Examples/test-suite/go/Makefile.in index 64a84f820..03f6f151e 100644 --- a/Examples/test-suite/go/Makefile.in +++ b/Examples/test-suite/go/Makefile.in @@ -9,6 +9,7 @@ GO1 = @GO1@ GO12 = @GO12@ GO13 = @GO13@ GOC = @GOC@ +SCRIPTDIR = $(srcdir) SCRIPTSUFFIX = _runme.go GOCOMPILEARG = `if $(GOGCC) ; then echo -c -g; elif $(GO1) ; then echo tool $(GOC:c=g) ; fi` @@ -23,6 +24,11 @@ SO = @SO@ srcdir = @srcdir@ top_srcdir = @top_srcdir@ top_builddir = @top_builddir@ +ifeq (.,$(srcdir)) +SRCDIR = +else +SRCDIR = $(srcdir)/ +endif include $(srcdir)/../common.mk @@ -47,7 +53,7 @@ include $(srcdir)/../common.mk multi_import.multicpptest: $(setup) for f in multi_import_b multi_import_a; do \ - $(MAKE) -f $(top_builddir)/$(EXAMPLES)/Makefile CXXSRCS="$(CXXSRCS)" \ + $(MAKE) -f $(top_builddir)/$(EXAMPLES)/Makefile SRCDIR="$(SRCDIR)" CXXSRCS="$(CXXSRCS)" \ SWIG_LIB="$(SWIG_LIB)" SWIG="$(SWIG)" LIBS='$(LIBS)' \ INCLUDES="$(INCLUDES)" SWIGOPT="$(SWIGOPT)" NOLINK=true \ TARGET="$(TARGETPREFIX)$${f}$(TARGETSUFFIX)" INTERFACEDIR="$(INTERFACEDIR)" INTERFACE="$$f.i" \ @@ -57,8 +63,8 @@ multi_import.multicpptest: # Runs the testcase. run_testcase = \ - if test -f $(srcdir)/$(SCRIPTPREFIX)$*$(SCRIPTSUFFIX); then \ - $(COMPILETOOL) $(GO) $(GOCOMPILEARG) -I . $(srcdir)/$(SCRIPTPREFIX)$*$(SCRIPTSUFFIX) && \ + if test -f $(SCRIPTDIR)/$(SCRIPTPREFIX)$*$(SCRIPTSUFFIX); then \ + $(COMPILETOOL) $(GO) $(GOCOMPILEARG) -I . $(SCRIPTDIR)/$(SCRIPTPREFIX)$*$(SCRIPTSUFFIX) && \ if $(GOGCC) ; then \ $(COMPILETOOL) $(GO) -o $*_runme $(SCRIPTPREFIX)$*_runme.@OBJEXT@ $*.@OBJEXT@ $*_wrap.@OBJEXT@; \ elif $(GO12) || $(GO13); then \ @@ -70,8 +76,8 @@ run_testcase = \ fi run_testcase_cpp = \ - if test -f $(srcdir)/$(SCRIPTPREFIX)$*$(SCRIPTSUFFIX); then \ - $(COMPILETOOL) $(GO) $(GOCOMPILEARG) -I . $(srcdir)/$(SCRIPTPREFIX)$*$(SCRIPTSUFFIX) && \ + if test -f $(SCRIPTDIR)/$(SCRIPTPREFIX)$*$(SCRIPTSUFFIX); then \ + $(COMPILETOOL) $(GO) $(GOCOMPILEARG) -I . $(SCRIPTDIR)/$(SCRIPTPREFIX)$*$(SCRIPTSUFFIX) && \ if $(GOGCC) ; then \ $(COMPILETOOL) $(GO) -o $*_runme $(SCRIPTPREFIX)$*_runme.@OBJEXT@ $*.@OBJEXT@ $*_wrap.@OBJEXT@ -lstdc++; \ elif $(GO12) || $(GO13); then \ @@ -83,8 +89,8 @@ run_testcase_cpp = \ fi run_multi_testcase = \ - if test -f $(srcdir)/$(SCRIPTPREFIX)$*$(SCRIPTSUFFIX); then \ - $(COMPILETOOL) $(GO) $(GOCOMPILEARG) -I . $(srcdir)/$(SCRIPTPREFIX)$*$(SCRIPTSUFFIX) && \ + if test -f $(SCRIPTDIR)/$(SCRIPTPREFIX)$*$(SCRIPTSUFFIX); then \ + $(COMPILETOOL) $(GO) $(GOCOMPILEARG) -I . $(SCRIPTDIR)/$(SCRIPTPREFIX)$*$(SCRIPTSUFFIX) && \ if $(GOGCC) ; then \ files=`cat $(top_srcdir)/$(EXAMPLES)/$(TEST_SUITE)/$*.list`; \ $(COMPILETOOL) $(GO) -o $*_runme $(SCRIPTPREFIX)$*_runme.@OBJEXT@ `for f in $$files; do echo $$f.@OBJEXT@ $${f}_wrap.@OBJEXT@; done` -lstdc++; \ diff --git a/Examples/test-suite/guile/Makefile.in b/Examples/test-suite/guile/Makefile.in index 493dde4f5..5ac3de685 100644 --- a/Examples/test-suite/guile/Makefile.in +++ b/Examples/test-suite/guile/Makefile.in @@ -6,10 +6,18 @@ EXTRA_TEST_CASES += guile_ext_test.externaltest LANGUAGE = guile VARIANT = +SCRIPTDIR = $(srcdir) SCRIPTSUFFIX = _runme.scm + srcdir = @srcdir@ top_srcdir = @top_srcdir@ top_builddir = @top_builddir@ +ifeq (.,$(srcdir)) +SRCDIR = +else +SRCDIR = $(srcdir)/ +endif + GUILE = @GUILE@ GUILE_RUNTIME= @@ -51,8 +59,8 @@ INCLUDES += -I$(top_srcdir)/$(EXAMPLES)/$(TEST_SUITE)/guile # Runs the testcase. A testcase is only run if # a file is found which has _runme.scm appended after the testcase name. run_testcase = \ - if [ -f $(srcdir)/$(SCRIPTPREFIX)$*$(SCRIPTSUFFIX) ]; then \ - env GUILE_AUTO_COMPILE=0 LD_LIBRARY_PATH=.:$$LD_LIBRARY_PATH $(RUNTOOL) $(GUILE) -l $(srcdir)/$(SCRIPTPREFIX)$*$(SCRIPTSUFFIX); \ + if [ -f $(SCRIPTDIR)/$(SCRIPTPREFIX)$*$(SCRIPTSUFFIX) ]; then \ + env GUILE_AUTO_COMPILE=0 LD_LIBRARY_PATH=.:$$LD_LIBRARY_PATH $(RUNTOOL) $(GUILE) -l $(SCRIPTDIR)/$(SCRIPTPREFIX)$*$(SCRIPTSUFFIX); \ fi # Clean diff --git a/Examples/test-suite/java/Makefile.in b/Examples/test-suite/java/Makefile.in index e4e803d2a..a61452ed2 100644 --- a/Examples/test-suite/java/Makefile.in +++ b/Examples/test-suite/java/Makefile.in @@ -6,10 +6,17 @@ LANGUAGE = java JAVA = @JAVA@ JAVAC = @JAVAC@ JAVAFLAGS = -Xcheck:jni +SCRIPTDIR = $(srcdir) SCRIPTSUFFIX = _runme.java + srcdir = @srcdir@ top_srcdir = ../@top_srcdir@ top_builddir = ../@top_builddir@ +ifeq (.,$(srcdir)) +SRCDIR = ../ +else +SRCDIR = ../$(srcdir)/ +endif C_TEST_CASES = \ java_lib_arrays \ @@ -72,7 +79,7 @@ director_nspace_director_name_collision.%: JAVA_PACKAGE = $*Package # Makes a directory for the testcase if it does not exist setup = \ - if [ -f $(srcdir)/$(SCRIPTPREFIX)$*$(SCRIPTSUFFIX) ]; then \ + if [ -f $(SCRIPTDIR)/$(SCRIPTPREFIX)$*$(SCRIPTSUFFIX) ]; then \ echo "$(ACTION)ing $(LANGUAGE) testcase $* (with run test)" ; \ else \ echo "$(ACTION)ing $(LANGUAGE) testcase $*" ; \ @@ -86,8 +93,8 @@ setup = \ # Note Java uses LD_LIBRARY_PATH under Unix, PATH under Cygwin/Windows, SHLIB_PATH on HPUX and DYLD_LIBRARY_PATH on Mac OS X. run_testcase = \ cd $(JAVA_PACKAGE) && $(COMPILETOOL) $(JAVAC) -classpath . `find . -name "*.java"` && cd .. && \ - if [ -f $(srcdir)/$(SCRIPTPREFIX)$*$(SCRIPTSUFFIX) ]; then \ - $(COMPILETOOL) $(JAVAC) -classpath . -d . $(srcdir)/$(SCRIPTPREFIX)$*$(SCRIPTSUFFIX) && \ + if [ -f $(SCRIPTDIR)/$(SCRIPTPREFIX)$*$(SCRIPTSUFFIX) ]; then \ + $(COMPILETOOL) $(JAVAC) -classpath . -d . $(SCRIPTDIR)/$(SCRIPTPREFIX)$*$(SCRIPTSUFFIX) && \ env LD_LIBRARY_PATH="$(JAVA_PACKAGE):$$LD_LIBRARY_PATH" PATH="$(JAVA_PACKAGE):$$PATH" SHLIB_PATH="$(JAVA_PACKAGE):$$SHLIB_PATH" DYLD_LIBRARY_PATH="$(JAVA_PACKAGE):$$DYLD_LIBRARY_PATH" $(RUNTOOL) $(JAVA) $(JAVAFLAGS) -classpath . $*_runme; \ fi diff --git a/Examples/test-suite/javascript/Makefile.in b/Examples/test-suite/javascript/Makefile.in index 7368ea9a3..6126bde74 100644 --- a/Examples/test-suite/javascript/Makefile.in +++ b/Examples/test-suite/javascript/Makefile.in @@ -4,10 +4,18 @@ LANGUAGE = javascript NODEGYP = @NODEGYP@ +NODEJS = @NODEJS@ SCRIPTSUFFIX = _runme.js + srcdir = @srcdir@ top_srcdir = @top_srcdir@ top_builddir = @top_builddir@ +ifeq (.,$(srcdir)) +SRCDIR = +else +SRCDIR = $(srcdir)/ +endif + SWIG = $(top_builddir)/preinst_swig ifneq (, $(ENGINE)) @@ -47,20 +55,27 @@ ifeq (node,$(JSENGINE)) constant_pointers.cpptest: GYP_CFLAGS = \"-Wno-ignored-qualifiers\" enum_thorough.cpptest: GYP_CFLAGS = \"-Wno-ignored-qualifiers\" + setup_node = \ + test -d $* || mkdir $*; \ + sed -e 's|$$testcase|$*|g; s|$$cflags|$(GYP_CFLAGS)|g; s|$$srcdir|$(srcdir)|g' \ + $(srcdir)/node_template/binding.gyp.in > $*/binding.gyp; \ + sed -e 's|$$testcase|$*|g;' \ + $(srcdir)/node_template/index.js.in > $*/index.js + # Note: we need to use swig in C parse mode, but make node-gyp believe it is c++ (via file extension) swig_and_compile_c = \ - sh ./setup_test.sh $* $(GYP_CFLAGS); \ - $(SWIG) -javascript $(SWIGOPT) -o $*_wrap.cxx ../$*.i; \ + $(setup_node); \ + $(SWIG) -javascript $(SWIGOPT) -o $*_wrap.cxx $(srcdir)/../$*.i; \ $(NODEGYP) --loglevel=silent --directory $* configure build 1>>/dev/null swig_and_compile_cpp = \ - sh ./setup_test.sh $* $(GYP_CFLAGS); \ - $(SWIG) -c++ -javascript $(SWIGOPT) ../$*.i; \ + $(setup_node); \ + $(SWIG) -c++ -javascript $(SWIGOPT) $(srcdir)/../$*.i; \ $(NODEGYP) --loglevel=silent --directory $* configure build 1>>/dev/null run_testcase = \ if [ -f $(srcdir)/$*$(SCRIPTSUFFIX) ]; then \ - node $(srcdir)/$*$(SCRIPTSUFFIX); \ + env NODE_PATH=$$PWD:$(srcdir) $(NODEJS) $(srcdir)/$*$(SCRIPTSUFFIX); \ fi @@ -83,7 +98,7 @@ else run_testcase = \ if [ -f $(srcdir)/$*$(SCRIPTSUFFIX) ]; then \ - $(top_srcdir)/Tools/javascript/javascript -$(JSENGINE) $(srcdir)/$*$(SCRIPTSUFFIX); \ + $(top_builddir)/Tools/javascript/javascript -$(JSENGINE) $(srcdir)/$*$(SCRIPTSUFFIX); \ fi %.ctest: diff --git a/Examples/test-suite/javascript/abstract_access_runme.js b/Examples/test-suite/javascript/abstract_access_runme.js index 8f87d2105..f61bb4358 100644 --- a/Examples/test-suite/javascript/abstract_access_runme.js +++ b/Examples/test-suite/javascript/abstract_access_runme.js @@ -1,4 +1,4 @@ -var abstract_access = require("./abstract_access"); +var abstract_access = require("abstract_access"); var d = new abstract_access.D() if (d.do_x() != 1) { diff --git a/Examples/test-suite/javascript/abstract_inherit_runme.js b/Examples/test-suite/javascript/abstract_inherit_runme.js index 3af2eae74..f732e8767 100644 --- a/Examples/test-suite/javascript/abstract_inherit_runme.js +++ b/Examples/test-suite/javascript/abstract_inherit_runme.js @@ -1,4 +1,4 @@ -var abstract_inherit = require("./abstract_inherit"); +var abstract_inherit = require("abstract_inherit"); // Shouldn't be able to instantiate any of these classes // since none of them implements the pure virtual function diff --git a/Examples/test-suite/javascript/abstract_typedef2_runme.js b/Examples/test-suite/javascript/abstract_typedef2_runme.js index c177e49c3..d8a533ab1 100644 --- a/Examples/test-suite/javascript/abstract_typedef2_runme.js +++ b/Examples/test-suite/javascript/abstract_typedef2_runme.js @@ -1,4 +1,4 @@ -var abstract_typedef2 = require("./abstract_typedef2"); +var abstract_typedef2 = require("abstract_typedef2"); var a = new abstract_typedef2.A_UF(); diff --git a/Examples/test-suite/javascript/abstract_typedef_runme.js b/Examples/test-suite/javascript/abstract_typedef_runme.js index abcfc581d..286328fa8 100644 --- a/Examples/test-suite/javascript/abstract_typedef_runme.js +++ b/Examples/test-suite/javascript/abstract_typedef_runme.js @@ -1,4 +1,4 @@ -var abstract_typedef = require("./abstract_typedef"); +var abstract_typedef = require("abstract_typedef"); var e = new abstract_typedef.Engine(); var a = new abstract_typedef.A() diff --git a/Examples/test-suite/javascript/abstract_virtual_runme.js b/Examples/test-suite/javascript/abstract_virtual_runme.js index 9e2814e41..9a9ce9988 100644 --- a/Examples/test-suite/javascript/abstract_virtual_runme.js +++ b/Examples/test-suite/javascript/abstract_virtual_runme.js @@ -1,4 +1,4 @@ -var abstract_virtual = require("./abstract_virtual"); +var abstract_virtual = require("abstract_virtual"); d = new abstract_virtual.D() diff --git a/Examples/test-suite/javascript/array_member_runme.js b/Examples/test-suite/javascript/array_member_runme.js index 8c4ef1da5..3d9bb0e5b 100644 --- a/Examples/test-suite/javascript/array_member_runme.js +++ b/Examples/test-suite/javascript/array_member_runme.js @@ -1,4 +1,4 @@ -var array_member = require("./array_member"); +var array_member = require("array_member"); var f = new array_member.Foo(); f.data = array_member.global_data; diff --git a/Examples/test-suite/javascript/arrays_global_runme.js b/Examples/test-suite/javascript/arrays_global_runme.js index fdb365f83..0cbb28efb 100644 --- a/Examples/test-suite/javascript/arrays_global_runme.js +++ b/Examples/test-suite/javascript/arrays_global_runme.js @@ -1,4 +1,4 @@ -var arrays_global = require("./arrays_global"); +var arrays_global = require("arrays_global"); arrays_global.array_i = arrays_global.array_const_i; diff --git a/Examples/test-suite/javascript/callback_runme.js b/Examples/test-suite/javascript/callback_runme.js index 9b1ef01a3..021888641 100644 --- a/Examples/test-suite/javascript/callback_runme.js +++ b/Examples/test-suite/javascript/callback_runme.js @@ -1,4 +1,4 @@ -var callback = require("./callback"); +var callback = require("callback"); if (callback.foo(2) !== 2) { throw new Error("Failed."); diff --git a/Examples/test-suite/javascript/char_binary_runme.js b/Examples/test-suite/javascript/char_binary_runme.js index 42abe6060..b2aac920c 100644 --- a/Examples/test-suite/javascript/char_binary_runme.js +++ b/Examples/test-suite/javascript/char_binary_runme.js @@ -1,4 +1,4 @@ -var char_binary = require("./char_binary"); +var char_binary = require("char_binary"); var t = new char_binary.Test(); if (t.strlen('hile') != 4) { diff --git a/Examples/test-suite/javascript/char_strings_runme.js b/Examples/test-suite/javascript/char_strings_runme.js index cca50d851..fe17cb982 100644 --- a/Examples/test-suite/javascript/char_strings_runme.js +++ b/Examples/test-suite/javascript/char_strings_runme.js @@ -1,4 +1,4 @@ -var char_strings = require("./char_strings"); +var char_strings = require("char_strings"); var assertIsEqual = function(expected, actual) { if (expected !== actual) { diff --git a/Examples/test-suite/javascript/class_ignore_runme.js b/Examples/test-suite/javascript/class_ignore_runme.js index f0a32a1c4..ffbe021c7 100644 --- a/Examples/test-suite/javascript/class_ignore_runme.js +++ b/Examples/test-suite/javascript/class_ignore_runme.js @@ -1,4 +1,4 @@ -var class_ignore = require("./class_ignore"); +var class_ignore = require("class_ignore"); a = new class_ignore.Bar(); diff --git a/Examples/test-suite/javascript/class_scope_weird_runme.js b/Examples/test-suite/javascript/class_scope_weird_runme.js index ac745d023..73c118d61 100644 --- a/Examples/test-suite/javascript/class_scope_weird_runme.js +++ b/Examples/test-suite/javascript/class_scope_weird_runme.js @@ -1,4 +1,4 @@ -var class_scope_weird = require("./class_scope_weird"); +var class_scope_weird = require("class_scope_weird"); f = new class_scope_weird.Foo(); g = new class_scope_weird.Foo(3); diff --git a/Examples/test-suite/javascript/complextest_runme.js b/Examples/test-suite/javascript/complextest_runme.js index 1fcc97648..b87d6bffa 100644 --- a/Examples/test-suite/javascript/complextest_runme.js +++ b/Examples/test-suite/javascript/complextest_runme.js @@ -1,4 +1,4 @@ -var complextest = require("./complextest"); +var complextest = require("complextest"); a = [-1,2]; diff --git a/Examples/test-suite/javascript/constover_runme.js b/Examples/test-suite/javascript/constover_runme.js index 764d8b328..9b192b5ff 100644 --- a/Examples/test-suite/javascript/constover_runme.js +++ b/Examples/test-suite/javascript/constover_runme.js @@ -1,4 +1,4 @@ -var constover = require("./constover"); +var constover = require("constover"); p = constover.test("test"); if (p != "test") { diff --git a/Examples/test-suite/javascript/constructor_copy_runme.js b/Examples/test-suite/javascript/constructor_copy_runme.js index 39dce52ce..179b9fb40 100644 --- a/Examples/test-suite/javascript/constructor_copy_runme.js +++ b/Examples/test-suite/javascript/constructor_copy_runme.js @@ -1,4 +1,4 @@ -var constructor_copy = require("./constructor_copy"); +var constructor_copy = require("constructor_copy"); f1 = new constructor_copy.Foo1(3); f11 = new constructor_copy.Foo1(f1); diff --git a/Examples/test-suite/javascript/cpp_enum_runme.js b/Examples/test-suite/javascript/cpp_enum_runme.js index 35f7c60ac..8a248c372 100644 --- a/Examples/test-suite/javascript/cpp_enum_runme.js +++ b/Examples/test-suite/javascript/cpp_enum_runme.js @@ -1,4 +1,4 @@ -var cpp_enum = require("./cpp_enum"); +var cpp_enum = require("cpp_enum"); var f = new cpp_enum.Foo() diff --git a/Examples/test-suite/javascript/cpp_namespace_runme.js b/Examples/test-suite/javascript/cpp_namespace_runme.js index 3bdfef3e9..a6ab79964 100644 --- a/Examples/test-suite/javascript/cpp_namespace_runme.js +++ b/Examples/test-suite/javascript/cpp_namespace_runme.js @@ -1,4 +1,4 @@ -var cpp_namespace = require("./cpp_namespace"); +var cpp_namespace = require("cpp_namespace"); var n = cpp_namespace.fact(4); if (n != 24){ diff --git a/Examples/test-suite/javascript/cpp_static_runme.js b/Examples/test-suite/javascript/cpp_static_runme.js index 2579aeafe..c7917e12e 100644 --- a/Examples/test-suite/javascript/cpp_static_runme.js +++ b/Examples/test-suite/javascript/cpp_static_runme.js @@ -1,4 +1,4 @@ -var cpp_static = require("./cpp_static"); +var cpp_static = require("cpp_static"); cpp_static.StaticFunctionTest.static_func(); cpp_static.StaticFunctionTest.static_func_2(1); diff --git a/Examples/test-suite/javascript/director_alternating_runme.js b/Examples/test-suite/javascript/director_alternating_runme.js index a0411eace..cff288d35 100644 --- a/Examples/test-suite/javascript/director_alternating_runme.js +++ b/Examples/test-suite/javascript/director_alternating_runme.js @@ -1,4 +1,4 @@ -var director_alternating = require("./director_alternating"); +var director_alternating = require("director_alternating"); id = director_alternating.getBar().id(); if (id != director_alternating.idFromGetBar()) diff --git a/Examples/test-suite/javascript/disown_runme.js b/Examples/test-suite/javascript/disown_runme.js index a4a6fd880..ea742b51e 100644 --- a/Examples/test-suite/javascript/disown_runme.js +++ b/Examples/test-suite/javascript/disown_runme.js @@ -1,4 +1,4 @@ -var disown = require("./disown"); +var disown = require("disown"); var a = new disown.A(); var tmp = a.thisown; diff --git a/Examples/test-suite/javascript/dynamic_cast_runme.js b/Examples/test-suite/javascript/dynamic_cast_runme.js index 0029cb0f8..32eabcf8b 100644 --- a/Examples/test-suite/javascript/dynamic_cast_runme.js +++ b/Examples/test-suite/javascript/dynamic_cast_runme.js @@ -1,4 +1,4 @@ -var dynamic_cast = require("./dynamic_cast"); +var dynamic_cast = require("dynamic_cast"); var f = new dynamic_cast.Foo(); var b = new dynamic_cast.Bar(); diff --git a/Examples/test-suite/javascript/empty_runme.js b/Examples/test-suite/javascript/empty_runme.js index db06b3902..7894379be 100644 --- a/Examples/test-suite/javascript/empty_runme.js +++ b/Examples/test-suite/javascript/empty_runme.js @@ -1 +1 @@ -var empty = require("./empty"); \ No newline at end of file +var empty = require("empty"); \ No newline at end of file diff --git a/Examples/test-suite/javascript/enum_template_runme.js b/Examples/test-suite/javascript/enum_template_runme.js index 20f8c3482..1e71e5f64 100644 --- a/Examples/test-suite/javascript/enum_template_runme.js +++ b/Examples/test-suite/javascript/enum_template_runme.js @@ -1,4 +1,4 @@ -var enum_template = require("./enum_template"); +var enum_template = require("enum_template"); if (enum_template.MakeETest() != 1) throw "RuntimeError"; diff --git a/Examples/test-suite/javascript/infinity_runme.js b/Examples/test-suite/javascript/infinity_runme.js index 7b5182ff6..050c391a7 100644 --- a/Examples/test-suite/javascript/infinity_runme.js +++ b/Examples/test-suite/javascript/infinity_runme.js @@ -1,4 +1,4 @@ -var infinity = require("./infinity"); +var infinity = require("infinity"); var my_infinity = infinity.INFINITY; var ret_val = infinity.use_infinity(my_infinity); diff --git a/Examples/test-suite/javascript/namespace_virtual_method_runme.js b/Examples/test-suite/javascript/namespace_virtual_method_runme.js index 24d3bd487..4f1e05c84 100644 --- a/Examples/test-suite/javascript/namespace_virtual_method_runme.js +++ b/Examples/test-suite/javascript/namespace_virtual_method_runme.js @@ -1,3 +1,3 @@ -var namespace_virtual_method = require("./namespace_virtual_method"); +var namespace_virtual_method = require("namespace_virtual_method"); x = new namespace_virtual_method.Spam(); diff --git a/Examples/test-suite/javascript/node_template/binding.gyp.in b/Examples/test-suite/javascript/node_template/binding.gyp.in index 209774ae0..a82ac2f3e 100644 --- a/Examples/test-suite/javascript/node_template/binding.gyp.in +++ b/Examples/test-suite/javascript/node_template/binding.gyp.in @@ -3,7 +3,7 @@ { "target_name": "$testcase", "sources":[ "../$testcase_wrap.cxx" ], - "include_dirs": ["../.."], + "include_dirs": ["../$srcdir/.."], 'defines': [ 'BUILDING_NODE_EXTENSION=1', ], diff --git a/Examples/test-suite/javascript/nspace_extend_runme.js b/Examples/test-suite/javascript/nspace_extend_runme.js index ab81c19d3..8cabfe945 100644 --- a/Examples/test-suite/javascript/nspace_extend_runme.js +++ b/Examples/test-suite/javascript/nspace_extend_runme.js @@ -1,4 +1,4 @@ -var nspace_extend = require("./nspace_extend"); +var nspace_extend = require("nspace_extend"); // constructors and destructors var color1 = new nspace_extend.Outer.Inner1.Color(); diff --git a/Examples/test-suite/javascript/nspace_runme.js b/Examples/test-suite/javascript/nspace_runme.js index f1afff428..993610dd6 100644 --- a/Examples/test-suite/javascript/nspace_runme.js +++ b/Examples/test-suite/javascript/nspace_runme.js @@ -1,4 +1,4 @@ -var nspace = require("./nspace"); +var nspace = require("nspace"); var color1 = new nspace.Outer.Inner1.Color(); var color = new nspace.Outer.Inner1.Color(color1); diff --git a/Examples/test-suite/javascript/overload_copy_runme.js b/Examples/test-suite/javascript/overload_copy_runme.js index 1039ffda1..e2f610788 100644 --- a/Examples/test-suite/javascript/overload_copy_runme.js +++ b/Examples/test-suite/javascript/overload_copy_runme.js @@ -1,4 +1,4 @@ -var overload_copy = require("./overload_copy"); +var overload_copy = require("overload_copy"); f = new overload_copy.Foo(); g = new overload_copy.Foo(f); diff --git a/Examples/test-suite/javascript/preproc_include_runme.js b/Examples/test-suite/javascript/preproc_include_runme.js index 4b827fbcc..5ec72b842 100644 --- a/Examples/test-suite/javascript/preproc_include_runme.js +++ b/Examples/test-suite/javascript/preproc_include_runme.js @@ -1,4 +1,4 @@ -var preproc_include = require("./preproc_include"); +var preproc_include = require("preproc_include"); if (preproc_include.multiply10(10) != 100) throw "RuntimeError"; diff --git a/Examples/test-suite/javascript/preproc_runme.js b/Examples/test-suite/javascript/preproc_runme.js index 669f9d1f0..167ca5ac1 100644 --- a/Examples/test-suite/javascript/preproc_runme.js +++ b/Examples/test-suite/javascript/preproc_runme.js @@ -1,4 +1,4 @@ -var preproc = require("./preproc"); +var preproc = require("preproc"); if (preproc.endif != 1) throw "RuntimeError"; diff --git a/Examples/test-suite/javascript/rename1_runme.js b/Examples/test-suite/javascript/rename1_runme.js index 8374e6a89..68ecc11b6 100644 --- a/Examples/test-suite/javascript/rename1_runme.js +++ b/Examples/test-suite/javascript/rename1_runme.js @@ -1,4 +1,4 @@ -var rename = require("./rename1"); +var rename = require("rename1"); function part1() { var xyz = new rename.XYZInt(); diff --git a/Examples/test-suite/javascript/rename2_runme.js b/Examples/test-suite/javascript/rename2_runme.js index bc6a95a59..99f478596 100644 --- a/Examples/test-suite/javascript/rename2_runme.js +++ b/Examples/test-suite/javascript/rename2_runme.js @@ -1,4 +1,4 @@ -var rename = require("./rename2"); +var rename = require("rename2"); function part1() { var xyz = new rename.XYZInt(); diff --git a/Examples/test-suite/javascript/rename3_runme.js b/Examples/test-suite/javascript/rename3_runme.js index 9e57e80ea..237029fbb 100644 --- a/Examples/test-suite/javascript/rename3_runme.js +++ b/Examples/test-suite/javascript/rename3_runme.js @@ -1,4 +1,4 @@ -var rename = require("./rename3"); +var rename = require("rename3"); function part1() { var xyz = new rename.XYZInt(); diff --git a/Examples/test-suite/javascript/rename4_runme.js b/Examples/test-suite/javascript/rename4_runme.js index d651fc7a1..fed50dceb 100644 --- a/Examples/test-suite/javascript/rename4_runme.js +++ b/Examples/test-suite/javascript/rename4_runme.js @@ -1,4 +1,4 @@ -var rename = require("./rename4"); +var rename = require("rename4"); function part1() { var xyz = new rename.XYZInt(); diff --git a/Examples/test-suite/javascript/rename_scope_runme.js b/Examples/test-suite/javascript/rename_scope_runme.js index c0226df69..fea4d2ca9 100644 --- a/Examples/test-suite/javascript/rename_scope_runme.js +++ b/Examples/test-suite/javascript/rename_scope_runme.js @@ -1,4 +1,4 @@ -var rename_scope = require("./rename_scope"); +var rename_scope = require("rename_scope"); var a = new rename_scope.Natural_UP(); var b = new rename_scope.Natural_BP(); diff --git a/Examples/test-suite/javascript/rename_simple_runme.js b/Examples/test-suite/javascript/rename_simple_runme.js index 918dd68a5..21350cd3e 100644 --- a/Examples/test-suite/javascript/rename_simple_runme.js +++ b/Examples/test-suite/javascript/rename_simple_runme.js @@ -1,4 +1,4 @@ -var rename_simple = require("./rename_simple"); +var rename_simple = require("rename_simple"); var NewStruct = rename_simple.NewStruct; var s = new NewStruct(); diff --git a/Examples/test-suite/javascript/ret_by_value_runme.js b/Examples/test-suite/javascript/ret_by_value_runme.js index d9a77a20b..9d0840602 100644 --- a/Examples/test-suite/javascript/ret_by_value_runme.js +++ b/Examples/test-suite/javascript/ret_by_value_runme.js @@ -1,4 +1,4 @@ -var ret_by_value = require("./ret_by_value"); +var ret_by_value = require("ret_by_value"); a = ret_by_value.get_test(); if (a.myInt != 100) diff --git a/Examples/test-suite/javascript/setup_test.sh b/Examples/test-suite/javascript/setup_test.sh deleted file mode 100644 index 913a74c4b..000000000 --- a/Examples/test-suite/javascript/setup_test.sh +++ /dev/null @@ -1,6 +0,0 @@ -#!/bin/sh -if [ ! -d $1 ]; then - mkdir $1; -fi -sed -e "s/\$testcase/$1/" -e "s/\$cflags/$2/" < node_template/binding.gyp.in > $1/binding.gyp -sed s/\$testcase/$1/ node_template/index.js.in > $1/index.js diff --git a/Examples/test-suite/javascript/string_simple_runme.js b/Examples/test-suite/javascript/string_simple_runme.js index dbdd4136d..39ae84e9e 100644 --- a/Examples/test-suite/javascript/string_simple_runme.js +++ b/Examples/test-suite/javascript/string_simple_runme.js @@ -1,4 +1,4 @@ -var string_simple = require("./string_simple"); +var string_simple = require("string_simple"); // Test unicode string var str = "olé"; diff --git a/Examples/test-suite/javascript/struct_value_runme.js b/Examples/test-suite/javascript/struct_value_runme.js index d6b26f726..5b171b8fe 100644 --- a/Examples/test-suite/javascript/struct_value_runme.js +++ b/Examples/test-suite/javascript/struct_value_runme.js @@ -1,4 +1,4 @@ -var struct_value = require("./struct_value"); +var struct_value = require("struct_value"); b = new struct_value.Bar(); diff --git a/Examples/test-suite/javascript/template_static_runme.js b/Examples/test-suite/javascript/template_static_runme.js index 477d97249..d6106138a 100644 --- a/Examples/test-suite/javascript/template_static_runme.js +++ b/Examples/test-suite/javascript/template_static_runme.js @@ -1,3 +1,3 @@ -var template_static = require("./template_static"); +var template_static = require("template_static"); template_static.Foo.bar_double(1); diff --git a/Examples/test-suite/javascript/typedef_class_runme.js b/Examples/test-suite/javascript/typedef_class_runme.js index 3e4dc9093..64e0051c3 100644 --- a/Examples/test-suite/javascript/typedef_class_runme.js +++ b/Examples/test-suite/javascript/typedef_class_runme.js @@ -1,4 +1,4 @@ -var typedef_class = require("./typedef_class"); +var typedef_class = require("typedef_class"); a = new typedef_class.RealA(); a.a = 3; diff --git a/Examples/test-suite/javascript/typedef_inherit_runme.js b/Examples/test-suite/javascript/typedef_inherit_runme.js index 4abcc2536..7590e1e6e 100644 --- a/Examples/test-suite/javascript/typedef_inherit_runme.js +++ b/Examples/test-suite/javascript/typedef_inherit_runme.js @@ -1,4 +1,4 @@ -var typedef_inherit = require("./typedef_inherit"); +var typedef_inherit = require("typedef_inherit"); a = new typedef_inherit.Foo(); b = new typedef_inherit.Bar(); diff --git a/Examples/test-suite/javascript/typedef_scope_runme.js b/Examples/test-suite/javascript/typedef_scope_runme.js index 0ac56884c..5c1368ab7 100644 --- a/Examples/test-suite/javascript/typedef_scope_runme.js +++ b/Examples/test-suite/javascript/typedef_scope_runme.js @@ -1,4 +1,4 @@ -var typedef_scope = require("./typedef_scope"); +var typedef_scope = require("typedef_scope"); b = new typedef_scope.Bar(); x = b.test1(42,"hello"); diff --git a/Examples/test-suite/javascript/typemap_arrays_runme.js b/Examples/test-suite/javascript/typemap_arrays_runme.js index cd6827ac9..610ecdd9c 100644 --- a/Examples/test-suite/javascript/typemap_arrays_runme.js +++ b/Examples/test-suite/javascript/typemap_arrays_runme.js @@ -1,4 +1,4 @@ -var typemap_arrays = require("./typemap_arrays"); +var typemap_arrays = require("typemap_arrays"); if (typemap_arrays.sumA(null) != 60) throw "RuntimeError, Sum is wrong"; diff --git a/Examples/test-suite/javascript/typemap_delete_runme.js b/Examples/test-suite/javascript/typemap_delete_runme.js index 4b3174956..1d42ce4da 100644 --- a/Examples/test-suite/javascript/typemap_delete_runme.js +++ b/Examples/test-suite/javascript/typemap_delete_runme.js @@ -1,4 +1,4 @@ -var typemap_delete = require("./typemap_delete"); +var typemap_delete = require("typemap_delete"); r = new typemap_delete.Rect(123); if (r.val != 123) diff --git a/Examples/test-suite/javascript/typemap_namespace_runme.js b/Examples/test-suite/javascript/typemap_namespace_runme.js index 614e0ffeb..2aa358024 100644 --- a/Examples/test-suite/javascript/typemap_namespace_runme.js +++ b/Examples/test-suite/javascript/typemap_namespace_runme.js @@ -1,4 +1,4 @@ -var typemap_namespace = require("./typemap_namespace"); +var typemap_namespace = require("typemap_namespace"); if (typemap_namespace.test1("hello") != "hello") throw "RuntimeError"; diff --git a/Examples/test-suite/javascript/typemap_ns_using_runme.js b/Examples/test-suite/javascript/typemap_ns_using_runme.js index 9115c16ae..7e4019ab2 100644 --- a/Examples/test-suite/javascript/typemap_ns_using_runme.js +++ b/Examples/test-suite/javascript/typemap_ns_using_runme.js @@ -1,4 +1,4 @@ -var typemap_ns_using = require("./typemap_ns_using"); +var typemap_ns_using = require("typemap_ns_using"); if (typemap_ns_using.spam(37) != 37) throw "RuntimeError"; diff --git a/Examples/test-suite/javascript/using1_runme.js b/Examples/test-suite/javascript/using1_runme.js index a2e37fcb6..2415156f0 100644 --- a/Examples/test-suite/javascript/using1_runme.js +++ b/Examples/test-suite/javascript/using1_runme.js @@ -1,4 +1,4 @@ -var using1 = require("./using1"); +var using1 = require("using1"); if (using1.spam(37) != 37) throw "RuntimeError"; diff --git a/Examples/test-suite/javascript/using2_runme.js b/Examples/test-suite/javascript/using2_runme.js index aa5e9b15f..2ef08faca 100644 --- a/Examples/test-suite/javascript/using2_runme.js +++ b/Examples/test-suite/javascript/using2_runme.js @@ -1,4 +1,4 @@ -var using2 = require("./using2"); +var using2 = require("using2"); if (using2.spam(37) != 37) throw "RuntimeError"; diff --git a/Examples/test-suite/javascript/varargs_runme.js b/Examples/test-suite/javascript/varargs_runme.js index 69d761e63..fc6d945c1 100644 --- a/Examples/test-suite/javascript/varargs_runme.js +++ b/Examples/test-suite/javascript/varargs_runme.js @@ -1,4 +1,4 @@ -var varargs = require("./varargs"); +var varargs = require("varargs"); if (varargs.test("Hello") != "Hello") { throw new Error("Failed"); diff --git a/Examples/test-suite/lua/Makefile.in b/Examples/test-suite/lua/Makefile.in index 0950c9d91..b35cc15ad 100644 --- a/Examples/test-suite/lua/Makefile.in +++ b/Examples/test-suite/lua/Makefile.in @@ -4,10 +4,17 @@ LANGUAGE = lua LUA = @LUABIN@ +SCRIPTDIR = $(srcdir) SCRIPTSUFFIX = _runme.lua + srcdir = @srcdir@ top_srcdir = @top_srcdir@ top_builddir = @top_builddir@ +ifeq (.,$(srcdir)) +SRCDIR = +else +SRCDIR = $(srcdir)/ +endif # sorry, currently very few test cases work/have been written @@ -46,8 +53,8 @@ lua_no_module_global.%: SWIGOPT += -nomoduleglobal # Runs the testcase. A testcase is only run if # a file is found which has _runme.lua appended after the testcase name. run_testcase = \ - if [ -f $(srcdir)/$(SCRIPTPREFIX)$*$(SCRIPTSUFFIX) ]; then \ - env LUA_PATH="$(srcdir)/?.lua;" $(RUNTOOL) $(LUA) $(srcdir)/$(SCRIPTPREFIX)$*$(SCRIPTSUFFIX); \ + if [ -f $(SCRIPTDIR)/$(SCRIPTPREFIX)$*$(SCRIPTSUFFIX) ]; then \ + env LUA_PATH="$(srcdir)/?.lua;" $(RUNTOOL) $(LUA) $(SCRIPTDIR)/$(SCRIPTPREFIX)$*$(SCRIPTSUFFIX); \ fi # Clean: (does nothing, we dont generate extra lua code) diff --git a/Examples/test-suite/mzscheme/Makefile.in b/Examples/test-suite/mzscheme/Makefile.in index 67b8bddf2..39fb1acbc 100644 --- a/Examples/test-suite/mzscheme/Makefile.in +++ b/Examples/test-suite/mzscheme/Makefile.in @@ -5,9 +5,15 @@ LANGUAGE = mzscheme MZSCHEME = mzscheme SCRIPTSUFFIX = _runme.scm + srcdir = @srcdir@ top_srcdir = @top_srcdir@ top_builddir = @top_builddir@ +ifeq (.,$(srcdir)) +SRCDIR = +else +SRCDIR = $(srcdir)/ +endif include $(srcdir)/../common.mk diff --git a/Examples/test-suite/ocaml/Makefile.in b/Examples/test-suite/ocaml/Makefile.in index 63edec26a..5081e203e 100644 --- a/Examples/test-suite/ocaml/Makefile.in +++ b/Examples/test-suite/ocaml/Makefile.in @@ -6,9 +6,15 @@ LANGUAGE = ocaml OCAMLC = ocamlc VARIANT = _static SCRIPTSUFFIX = _runme.ml + srcdir = @srcdir@ top_srcdir = @top_srcdir@ top_builddir = @top_builddir@ +ifeq (.,$(srcdir)) +SRCDIR = +else +SRCDIR = $(srcdir)/ +endif C_TEST_CASES = diff --git a/Examples/test-suite/octave/Makefile.in b/Examples/test-suite/octave/Makefile.in index e48d36a64..11cb7c076 100644 --- a/Examples/test-suite/octave/Makefile.in +++ b/Examples/test-suite/octave/Makefile.in @@ -4,10 +4,17 @@ LANGUAGE = octave OCTAVE = @OCTAVE@ +SCRIPTDIR = $(srcdir) SCRIPTSUFFIX = _runme.m + srcdir = @srcdir@ top_srcdir = @top_srcdir@ top_builddir = @top_builddir@ +ifeq (.,$(srcdir)) +SRCDIR = +else +SRCDIR = $(srcdir)/ +endif CPP_TEST_CASES += \ li_std_pair_extra \ @@ -33,7 +40,7 @@ include $(srcdir)/../common.mk # Overridden variables here LIBS = -L. -CSRCS = $(srcdir)/octave_empty.c +CSRCS = octave_empty.c # Custom tests - tests with additional commandline options # none! @@ -57,8 +64,8 @@ CSRCS = $(srcdir)/octave_empty.c # Runs the testcase. A testcase is only run if # a file is found which has _runme.m appended after the testcase name. run_testcase = \ - if [ -f $(srcdir)/$(SCRIPTPREFIX)$*$(SCRIPTSUFFIX) ]; then \ - env LD_LIBRARY_PATH=.:$$LD_LIBRARY_PATH OCTAVE_PATH=$(srcdir):$$OCTAVE_PATH $(RUNTOOL) $(OCTAVE) $(srcdir)/$(SCRIPTPREFIX)$*$(SCRIPTSUFFIX); \ + if [ -f $(SCRIPTDIR)/$(SCRIPTPREFIX)$*$(SCRIPTSUFFIX) ]; then \ + env LD_LIBRARY_PATH=.:$$LD_LIBRARY_PATH OCTAVE_PATH=$(srcdir):$$OCTAVE_PATH $(RUNTOOL) $(OCTAVE) $(SCRIPTDIR)/$(SCRIPTPREFIX)$*$(SCRIPTSUFFIX); \ fi # Clean: remove the generated .m file diff --git a/Examples/test-suite/perl5/Makefile.in b/Examples/test-suite/perl5/Makefile.in index 68f32a54a..6778f714e 100644 --- a/Examples/test-suite/perl5/Makefile.in +++ b/Examples/test-suite/perl5/Makefile.in @@ -4,11 +4,18 @@ LANGUAGE = perl5 PERL = @PERL@ +SCRIPTDIR = $(srcdir) SCRIPTSUFFIX = _runme.pl -TEST_RUNNER = run-perl-test.pl +TEST_RUNNER = $(srcdir)/run-perl-test.pl + srcdir = @srcdir@ top_srcdir = @top_srcdir@ top_builddir = @top_builddir@ +ifeq (.,$(srcdir)) +SRCDIR = +else +SRCDIR = $(srcdir)/ +endif CPP_TEST_CASES += \ primitive_types \ @@ -49,8 +56,8 @@ include $(srcdir)/../common.mk # Runs the testcase. A testcase is only run if # a file is found which has _runme.pl appended after the testcase name. run_testcase = \ - if [ -f $(srcdir)/$(SCRIPTPREFIX)$*$(SCRIPTSUFFIX) ]; then \ - env LD_LIBRARY_PATH=.:$$LD_LIBRARY_PATH $(RUNTOOL) $(PERL) $(TEST_RUNNER) $(srcdir)/$(SCRIPTPREFIX)$*$(SCRIPTSUFFIX); \ + if [ -f $(SCRIPTDIR)/$(SCRIPTPREFIX)$*$(SCRIPTSUFFIX) ]; then \ + env LD_LIBRARY_PATH=.:$$LD_LIBRARY_PATH $(RUNTOOL) $(PERL) $(TEST_RUNNER) $(SCRIPTDIR)/$(SCRIPTPREFIX)$*$(SCRIPTSUFFIX); \ fi # Clean: remove the generated .pm file diff --git a/Examples/test-suite/php/Makefile.in b/Examples/test-suite/php/Makefile.in index 735a3137e..b6e4fff1a 100644 --- a/Examples/test-suite/php/Makefile.in +++ b/Examples/test-suite/php/Makefile.in @@ -3,10 +3,17 @@ ####################################################################### LANGUAGE = php +SCRIPTDIR = $(srcdir) SCRIPTSUFFIX = _runme.php + srcdir = @srcdir@ top_srcdir = @top_srcdir@ top_builddir = @top_builddir@ +ifeq (.,$(srcdir)) +SRCDIR = +else +SRCDIR = $(srcdir)/ +endif CPP_TEST_CASES += \ php_namewarn_rename \ @@ -56,10 +63,10 @@ missingtests: missingcpptests missingctests # Runs the testcase. Tries to run testcase_runme.php, and if that's not # found, runs testcase.php, except for multicpptests. run_testcase = \ - if [ -f $(srcdir)/$(SCRIPTPREFIX)$*$(SCRIPTSUFFIX) ]; then \ - $(MAKE) -f $(top_builddir)/$(EXAMPLES)/Makefile PHP_SCRIPT=$(srcdir)/$(SCRIPTPREFIX)$*$(SCRIPTSUFFIX) RUNTOOL="$(RUNTOOL)" php_run; \ - elif [ -f $(srcdir)/$(SCRIPTPREFIX)$*.php -a ! -f $(top_srcdir)/$(EXAMPLES)/$(TEST_SUITE)/$*.list ]; then \ - $(MAKE) -f $(top_builddir)/$(EXAMPLES)/Makefile PHP_SCRIPT=$(srcdir)/$(SCRIPTPREFIX)$*.php RUNTOOL="$(RUNTOOL)" php_run; \ + if [ -f $(SCRIPTDIR)/$(SCRIPTPREFIX)$*$(SCRIPTSUFFIX) ]; then \ + $(MAKE) -f $(top_builddir)/$(EXAMPLES)/Makefile PHP_SCRIPT=$(SCRIPTDIR)/$(SCRIPTPREFIX)$*$(SCRIPTSUFFIX) RUNTOOL="$(RUNTOOL)" php_run; \ + elif [ -f $(SCRIPTDIR)/$(SCRIPTPREFIX)$*.php -a ! -f $(top_srcdir)/$(EXAMPLES)/$(TEST_SUITE)/$*.list ]; then \ + $(MAKE) -f $(top_builddir)/$(EXAMPLES)/Makefile PHP_SCRIPT=$(SCRIPTDIR)/$(SCRIPTPREFIX)$*.php RUNTOOL="$(RUNTOOL)" php_run; \ fi # Clean: remove the generated .php file diff --git a/Examples/test-suite/pike/Makefile.in b/Examples/test-suite/pike/Makefile.in index c1ebb747b..36a34352a 100644 --- a/Examples/test-suite/pike/Makefile.in +++ b/Examples/test-suite/pike/Makefile.in @@ -5,9 +5,15 @@ LANGUAGE = pike PIKE = pike SCRIPTSUFFIX = _runme.pike + srcdir = @srcdir@ top_srcdir = @top_srcdir@ top_builddir = @top_builddir@ +ifeq (.,$(srcdir)) +SRCDIR = +else +SRCDIR = $(srcdir)/ +endif include $(srcdir)/../common.mk diff --git a/Examples/test-suite/python/Makefile.in b/Examples/test-suite/python/Makefile.in index 389aed9ea..719e7d1a4 100644 --- a/Examples/test-suite/python/Makefile.in +++ b/Examples/test-suite/python/Makefile.in @@ -21,9 +21,16 @@ else SCRIPTSUFFIX = $(PY3SCRIPTSUFFIX) endif +SCRIPTDIR = . + srcdir = @srcdir@ top_srcdir = @top_srcdir@ top_builddir = @top_builddir@ +ifeq (.,$(srcdir)) +SRCDIR = +else +SRCDIR = $(srcdir)/ +endif PY2TO3 = 2to3 -x import @@ -128,39 +135,43 @@ VALGRIND_OPT += --suppressions=pythonswig.supp $(run_testcase) -# Call 2to3 to generate Python 3.x test from the Python 2.x's *_runme.py file -%$(PY3SCRIPTSUFFIX): %$(PY2SCRIPTSUFFIX) - cp $< $@ - $(PY2TO3) -w $@ >/dev/null 2>&1 - - # Runs the testcase. A testcase is only run if # a file is found which has _runme.py (or _runme3.py for Python 3) appended after the testcase name. -run_python = env LD_LIBRARY_PATH=.:$$LD_LIBRARY_PATH PYTHONPATH=.:$(srcdir):$$PYTHONPATH $(RUNTOOL) $(PYTHON) $(srcdir)/$(SCRIPTPREFIX)$*$(SCRIPTSUFFIX) +py_runme = $(SCRIPTPREFIX)$*$(SCRIPTSUFFIX) +py2_runme = $(SCRIPTPREFIX)$*$(PY2SCRIPTSUFFIX) +py3_runme = $(SCRIPTPREFIX)$*$(PY3SCRIPTSUFFIX) -py2_runme = $(srcdir)/$(SCRIPTPREFIX)$*$(PY2SCRIPTSUFFIX) -py3_runme = $(srcdir)/$(SCRIPTPREFIX)$*$(PY3SCRIPTSUFFIX) +run_python = env LD_LIBRARY_PATH=.:$$LD_LIBRARY_PATH PYTHONPATH=.:$(srcdir):$$PYTHONPATH $(RUNTOOL) $(PYTHON) $(py_runme) run_testcase = \ - if [ -f $(srcdir)/$(SCRIPTPREFIX)$*$(SCRIPTSUFFIX) ]; then \ + if [ -f $(SCRIPTDIR)/$(py_runme) ]; then \ $(run_python);\ fi -ifeq (,$(PY3)) +# No copying/conversion needed for in-source-tree Python 2 scripts +ifeq ($(SCRIPTDIR)|$(SCRIPTSUFFIX),$(srcdir)|$(PY2SCRIPTSUFFIX)) convert_testcase = else + convert_testcase = \ - if [ -f $(py2_runme) ]; then \ - $(MAKE) -f $(srcdir)/Makefile $(py3_runme); \ + if [ -f $(srcdir)/$(py2_runme) ]; then \ + $(MAKE) $(SCRIPTDIR)/$(py_runme); \ fi + +$(SCRIPTDIR)/$(SCRIPTPREFIX)%$(SCRIPTSUFFIX): $(srcdir)/$(SCRIPTPREFIX)%$(PY2SCRIPTSUFFIX) + test x$< = x$@ || cp $< $@ || exit 1 + test x$(PY3) = x || $(PY2TO3) -w $@ >/dev/null 2>&1 || exit 1 + endif # Clean: remove the generated .py file +# We only remove the _runme3.py if it is generated by 2to3 from a _runme.py. %.clean: - @rm -f $*.py; - @#We only remove the _runme3.py if it is generated by 2to3 from a _runme.py. - @if [ -f $(py2_runme) ]; then rm -f $(py3_runme) $(py3_runme).bak; fi + @rm -f $*.py + @if [ -f $(srcdir)/$(py2_runme) ]; then \ + rm -f $(SCRIPTDIR)/$(py3_runme) $(SCRIPTDIR)/$(py3_runme).bak; \ + fi clean: $(MAKE) -f $(top_builddir)/$(EXAMPLES)/Makefile python_clean diff --git a/Examples/test-suite/r/Makefile.in b/Examples/test-suite/r/Makefile.in index 32d9b85da..9f0de1c5f 100644 --- a/Examples/test-suite/r/Makefile.in +++ b/Examples/test-suite/r/Makefile.in @@ -6,9 +6,15 @@ LANGUAGE = r SCRIPTSUFFIX = _runme.R WRAPSUFFIX = .R RUNR = R CMD BATCH --no-save --no-restore + srcdir = @srcdir@ top_srcdir = @top_srcdir@ top_builddir = @top_builddir@ +ifeq (.,$(srcdir)) +SRCDIR = +else +SRCDIR = $(srcdir)/ +endif C_TEST_CASES += \ r_copy_struct \ diff --git a/Examples/test-suite/ruby/Makefile.in b/Examples/test-suite/ruby/Makefile.in index 40985e532..d0c65929a 100644 --- a/Examples/test-suite/ruby/Makefile.in +++ b/Examples/test-suite/ruby/Makefile.in @@ -4,10 +4,17 @@ LANGUAGE = ruby RUBY = @RUBY@ +SCRIPTDIR = $(srcdir) SCRIPTSUFFIX = _runme.rb + srcdir = @srcdir@ top_srcdir = @top_srcdir@ top_builddir = @top_builddir@ +ifeq (.,$(srcdir)) +SRCDIR = +else +SRCDIR = $(srcdir)/ +endif CPP_TEST_CASES = \ kwargs_feature \ @@ -60,8 +67,8 @@ ruby_naming.cpptest: SWIGOPT += -autorename # Runs the testcase. A testcase is only run if # a file is found which has _runme.rb appended after the testcase name. run_testcase = \ - if [ -f $(srcdir)/$(SCRIPTPREFIX)$*$(SCRIPTSUFFIX) ]; then \ - env LD_LIBRARY_PATH=.:$$LD_LIBRARY_PATH $(RUNTOOL) $(RUBY) -I$(srcdir):. $(srcdir)/$(SCRIPTPREFIX)$*$(SCRIPTSUFFIX); \ + if [ -f $(SCRIPTDIR)/$(SCRIPTPREFIX)$*$(SCRIPTSUFFIX) ]; then \ + env LD_LIBRARY_PATH=.:$$LD_LIBRARY_PATH $(RUNTOOL) $(RUBY) -I$(srcdir):. $(SCRIPTDIR)/$(SCRIPTPREFIX)$*$(SCRIPTSUFFIX); \ fi # Clean diff --git a/Examples/test-suite/tcl/Makefile.in b/Examples/test-suite/tcl/Makefile.in index 6ab293fb9..f8a196e26 100644 --- a/Examples/test-suite/tcl/Makefile.in +++ b/Examples/test-suite/tcl/Makefile.in @@ -4,10 +4,17 @@ LANGUAGE = tcl TCLSH = tclsh +SCRIPTDIR = $(srcdir) SCRIPTSUFFIX = _runme.tcl + srcdir = @srcdir@ top_srcdir = @top_srcdir@ top_builddir = @top_builddir@ +ifeq (.,$(srcdir)) +SRCDIR = +else +SRCDIR = $(srcdir)/ +endif CPP_TEST_CASES += \ primitive_types \ @@ -45,8 +52,8 @@ include $(srcdir)/../common.mk # Runs the testcase. A testcase is only run if # a file is found which has _runme.tcl appended after the testcase name. run_testcase = \ - if [ -f $(srcdir)/$(SCRIPTPREFIX)$*$(SCRIPTSUFFIX) ]; then \ - env LD_LIBRARY_PATH=.:$$LD_LIBRARY_PATH $(RUNTOOL) $(TCLSH) $(srcdir)/$(SCRIPTPREFIX)$*$(SCRIPTSUFFIX); \ + if [ -f $(SCRIPTDIR)/$(SCRIPTPREFIX)$*$(SCRIPTSUFFIX) ]; then \ + env LD_LIBRARY_PATH=.:$$LD_LIBRARY_PATH $(RUNTOOL) $(TCLSH) $(SCRIPTDIR)/$(SCRIPTPREFIX)$*$(SCRIPTSUFFIX); \ fi # Clean diff --git a/Examples/test-suite/uffi/Makefile.in b/Examples/test-suite/uffi/Makefile.in index 5fd000a96..9f3546da6 100644 --- a/Examples/test-suite/uffi/Makefile.in +++ b/Examples/test-suite/uffi/Makefile.in @@ -5,9 +5,15 @@ LANGUAGE = uffi UFFI = @UFFIBIN@ SCRIPTSUFFIX = _runme.lisp + srcdir = @srcdir@ top_srcdir = @top_srcdir@ top_builddir = @top_builddir@ +ifeq (.,$(srcdir)) +SRCDIR = +else +SRCDIR = $(srcdir)/ +endif include $(srcdir)/../common.mk diff --git a/Makefile.in b/Makefile.in index 53ac47de5..8c6072b41 100644 --- a/Makefile.in +++ b/Makefile.in @@ -100,7 +100,7 @@ skip-errors = test -n "" ACTION = check NOSKIP = -chk-set-swiglib = SWIG_LIB=@ROOT_DIR@/Lib +chk-set-swiglib = SWIG_LIB=@ROOT_DIR@/$(srcdir)/Lib chk-set-swig = SWIG=@ROOT_DIR@/$(TARGET) chk-set-env = $(chk-set-swiglib) $(chk-set-swig) @@ -443,7 +443,7 @@ maintainer-clean: @echo maintainer-cleaning CCache @test -z "$(ENABLE_CCACHE)" || (cd $(CCACHE) && $(MAKE) $(FLAGS) maintainer-clean) @echo maintainer-cleaning docs - @cd $(DOCS) && $(MAKE) $(FLAGS) maintainer-clean + @test -d $(DOCS) || exit 0; cd $(DOCS) && $(MAKE) $(FLAGS) maintainer-clean @echo maintainer-cleaning Lib files @rm -f $(srcdir)/Lib/swigwarn.swg @echo distcleaning diff --git a/Tools/javascript/Makefile.in b/Tools/javascript/Makefile.in index 6fbca2384..d5c4711a0 100644 --- a/Tools/javascript/Makefile.in +++ b/Tools/javascript/Makefile.in @@ -53,7 +53,7 @@ JS_INTERPRETER_SRC = javascript.cxx js_shell.cxx $(JS_INTERPRETER_SRC_JSC) $(JS_ JS_INTERPRETER_OBJS = $(JS_INTERPRETER_SRC:.cxx=.o) -%.o: %.cxx +%.o: $(srcdir)/%.cxx $(JSCXX) $(JS_INTERPRETER_DEFINES) $(CXXFLAGS) $(JSINCLUDES) -o $@ -c $< javascript: $(JS_INTERPRETER_OBJS) diff --git a/configure.ac b/configure.ac index eeabd11b4..949986341 100644 --- a/configure.ac +++ b/configure.ac @@ -2677,6 +2677,41 @@ AC_CONFIG_FILES([ AC_CONFIG_FILES([preinst-swig], [chmod +x preinst-swig]) AC_CONFIG_FILES([CCache/ccache_swig_config.h]) +#-------------------------------------------------------------------- +# Building Examples/ out of source directory +#-------------------------------------------------------------------- + +# If building out of source tree, replicate Examples/ source tree in +# build directory, and copy over Makefiles from source directory. +# Prefix each Makefile with a header which sets SRCDIR to the relative +# source directory, and provides a rule for updating the Makefile from +# its original source. +AC_CONFIG_COMMANDS([Examples],[ + if test "x${srcdir}" != "x." ; then + AC_MSG_NOTICE([generating Examples build tree]) + for mkfile in `cd ${srcdir} && find Examples/ -type f -name Makefile`; do + dir=`dirname ${mkfile}` + d=${dir} + reldir=""; + while test "x$d" != "x." ; do + d=`dirname $d` + reldir="${reldir}../" + done + relsrcdir=${reldir}${srcdir}/ + AS_MKDIR_P([${dir}]) + cat <${mkfile} +# DO NOT EDIT: instead edit ${relsrcdir}${mkfile} +# and run (cd ${reldir} && ./config.status) to regenerate +SRCDIR = ${relsrcdir}${dir}/ + +EOF + cat ${srcdir}/${mkfile} >>${mkfile} + done + fi +]) + +#-------------------------------------------------------------------- + AC_OUTPUT langs="" -- cgit v1.2.1 From 9b0e484b8a786b043a6d8f39bd0b18ff2dd91823 Mon Sep 17 00:00:00 2001 From: William S Fulton Date: Mon, 12 May 2014 07:51:55 +0100 Subject: Tests for C nested classes symbol table not being in global space Tests for 55bda53145d2898bd4642926b25209c12738e558 --- Examples/test-suite/common.mk | 1 + .../test-suite/java/nested_extend_c_runme.java | 38 +++++++++++ Examples/test-suite/nested_extend_c.i | 74 ++++++++++++++++++++++ 3 files changed, 113 insertions(+) create mode 100644 Examples/test-suite/java/nested_extend_c_runme.java create mode 100644 Examples/test-suite/nested_extend_c.i diff --git a/Examples/test-suite/common.mk b/Examples/test-suite/common.mk index 2a4591524..4b10527db 100644 --- a/Examples/test-suite/common.mk +++ b/Examples/test-suite/common.mk @@ -602,6 +602,7 @@ C_TEST_CASES += \ memberin_extend_c \ name \ nested \ + nested_extend_c \ nested_structs \ newobject2 \ overload_extend \ diff --git a/Examples/test-suite/java/nested_extend_c_runme.java b/Examples/test-suite/java/nested_extend_c_runme.java new file mode 100644 index 000000000..9da093a09 --- /dev/null +++ b/Examples/test-suite/java/nested_extend_c_runme.java @@ -0,0 +1,38 @@ +import nested_extend_c.*; + +public class nested_extend_c_runme { + + static { + try { + System.loadLibrary("nested_extend_c"); + } 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[]) throws Throwable + { + { + hiA hi = new hiA(); + if (hi.hi_extend() != 'h') + throw new RuntimeException("test failed"); + } + { + lowA low = new lowA(); + if (low.low_extend() != 99) + throw new RuntimeException("test failed"); + } + + { + hiB hi = new hiB(); + if (hi.hi_extend() != 'h') + throw new RuntimeException("test failed"); + } + { + lowB low = new lowB(); + if (low.low_extend() != 99) + throw new RuntimeException("test failed"); + } + } +} diff --git a/Examples/test-suite/nested_extend_c.i b/Examples/test-suite/nested_extend_c.i new file mode 100644 index 000000000..3641cf78f --- /dev/null +++ b/Examples/test-suite/nested_extend_c.i @@ -0,0 +1,74 @@ +%module nested_extend_c + +%extend hiA { + hiA() { + union hiA *self = (union hiA *)malloc(sizeof(union hiA)); + self->c = 'h'; + return self; + } + char hi_extend() { + return $self->c; + } +} +%extend lowA { + lowA() { + struct lowA *self = (struct lowA *)malloc(sizeof(struct lowA)); + self->name = 0; + self->num = 99; + return self; + } + int low_extend() { + return $self->num; + } +} + +%extend hiB { + hiB() { + union hiB *self = (union hiB *)malloc(sizeof(union hiB)); + self->c = 'h'; + return self; + } + char hi_extend() { + return $self->c; + } +} +%extend lowB { + lowB() { + struct lowB *self = (struct lowB *)malloc(sizeof(struct lowB)); + self->name = 0; + self->num = 99; + return self; + } + int low_extend() { + return $self->num; + } +} + +%inline %{ +typedef struct NestedA { + int a; + union hiA { + char c; + int d; + } hiA_instance; + + struct lowA { + char *name; + int num; + } lowA_instance; +} NestedA; + +typedef struct { + int a; + union hiB { + char c; + int d; + } hiB_instance; + + struct lowB { + char *name; + int num; + } lowB_instance; +} NestedB; +%} + -- cgit v1.2.1 From caaf224b5960202034884a1a00a9c3d2c3881c08 Mon Sep 17 00:00:00 2001 From: William S Fulton Date: Mon, 12 May 2014 19:07:55 +0100 Subject: Turn off %extend nested test for cplusplusout languages --- Examples/test-suite/nested_extend_c.i | 2 ++ 1 file changed, 2 insertions(+) diff --git a/Examples/test-suite/nested_extend_c.i b/Examples/test-suite/nested_extend_c.i index 3641cf78f..83d8c0601 100644 --- a/Examples/test-suite/nested_extend_c.i +++ b/Examples/test-suite/nested_extend_c.i @@ -1,5 +1,6 @@ %module nested_extend_c +#if !defined(SWIGOCTAVE) && !defined(SWIG_JAVASCRIPT_V8) %extend hiA { hiA() { union hiA *self = (union hiA *)malloc(sizeof(union hiA)); @@ -43,6 +44,7 @@ return $self->num; } } +#endif %inline %{ typedef struct NestedA { -- cgit v1.2.1 From 2aa540b9c0dee27e42e7eb6db2cb3e9ea24ca2ba Mon Sep 17 00:00:00 2001 From: Vladimir Kalinin Date: Wed, 14 May 2014 00:51:36 +0400 Subject: %extend for nested unnamed C structs --- Source/CParse/parser.y | 9 ++++----- Source/Modules/main.cxx | 2 ++ Source/Modules/nested.cxx | 10 ++++++---- 3 files changed, 12 insertions(+), 9 deletions(-) diff --git a/Source/CParse/parser.y b/Source/CParse/parser.y index 26af7be2d..a1a62cb62 100644 --- a/Source/CParse/parser.y +++ b/Source/CParse/parser.y @@ -41,7 +41,7 @@ int yyparse(); static Node *top = 0; /* Top of the generated parse tree */ static int unnamed = 0; /* Unnamed datatype counter */ -static Hash *extendhash = 0; /* Hash table of added methods */ +Hash *extendhash = 0; /* Hash table of added methods */ static Hash *classes = 0; /* Hash table of classes */ static Hash *classes_typedefs = 0; /* Hash table of typedef classes: typedef struct X {...} Y; */ static Symtab *prev_symtab = 0; @@ -655,7 +655,7 @@ static void add_symbols_copy(Node *n) { actually needs to take precedence. Therefore, we will selectively nuke symbols from the current symbol table, replacing them with the added methods */ -static void merge_extensions(Node *cls, Node *am) { +void merge_extensions(Node *cls, Node *am) { Node *n; Node *csym; @@ -708,7 +708,7 @@ static void merge_extensions(Node *cls, Node *am) { } } -static void append_previous_extension(Node *cls, Node *am) { +void append_previous_extension(Node *cls, Node *am) { Node *n, *ne; Node *pe = 0; Node *ae = 0; @@ -737,7 +737,7 @@ static void append_previous_extension(Node *cls, Node *am) { /* Check for unused %extend. Special case, don't report unused extensions for templates */ -static void check_extensions() { +void check_extensions() { Iterator ki; if (!extendhash) return; @@ -1579,7 +1579,6 @@ program : interface { Setattr(module_node,"name",ModuleName); } Setattr($1,"module",module_node); - check_extensions(); top = $1; } | PARSETYPE parm SEMI { diff --git a/Source/Modules/main.cxx b/Source/Modules/main.cxx index 833394b9c..d8f20c207 100644 --- a/Source/Modules/main.cxx +++ b/Source/Modules/main.cxx @@ -198,6 +198,7 @@ static String *external_runtime_name = 0; enum { STAGE1=1, STAGE2=2, STAGE3=4, STAGE4=8, STAGEOVERFLOW=16 }; static List *libfiles = 0; static List *all_output_files = 0; +extern "C" void check_extensions(); /* ----------------------------------------------------------------------------- * check_extension() @@ -1172,6 +1173,7 @@ int SWIG_main(int argc, char *argv[], Language *l) { Printf(stdout, "Processing unnamed structs...\n"); Swig_nested_name_unnamed_c_structs(top); } + check_extensions(); if (Verbose) { Printf(stdout, "Processing types...\n"); diff --git a/Source/Modules/nested.cxx b/Source/Modules/nested.cxx index 3b45e9f90..169263c3f 100644 --- a/Source/Modules/nested.cxx +++ b/Source/Modules/nested.cxx @@ -338,7 +338,9 @@ static void insertNodeAfter(Node *n, Node *c) { set_nextSibling(n, c); set_previousSibling(c, n); } - +extern "C" Hash *extendhash; +extern "C" void merge_extensions(Node *cls, Node *am); +extern "C" void append_previous_extension(Node *cls, Node *am); void Swig_nested_name_unnamed_c_structs(Node *n) { if (!classhash) classhash = Getattr(n, "classes"); @@ -377,15 +379,15 @@ void Swig_nested_name_unnamed_c_structs(Node *n) { } Delete(ty); // Check for extensions -/* // TODO: we can save extensions hash like class hash and move check_extensions() after nesting processing + // TODO: we can save extensions hash like class hash and move check_extensions() after nesting processing if (extendhash) { if (Node *am = Getattr(extendhash, name)) { // Merge the extension into the symbol table merge_extensions(c, am); append_previous_extension(c, am); - Delattr(extendhash, clsname); + Delattr(extendhash, name); } - }*/ + } Swig_symbol_setscope(Swig_symbol_global_scope()); add_symbols_c(c); -- cgit v1.2.1 From 5d78f14b1c2a580ad08326de4900f51245560dd7 Mon Sep 17 00:00:00 2001 From: Vladimir Kalinin Date: Wed, 14 May 2014 00:56:39 +0400 Subject: test added for nested unnamed C struct %extend --- Examples/test-suite/nested_extend_c.i | 15 +++++++++++++++ Source/Modules/nested.cxx | 2 -- 2 files changed, 15 insertions(+), 2 deletions(-) diff --git a/Examples/test-suite/nested_extend_c.i b/Examples/test-suite/nested_extend_c.i index 83d8c0601..702c839b2 100644 --- a/Examples/test-suite/nested_extend_c.i +++ b/Examples/test-suite/nested_extend_c.i @@ -44,6 +44,13 @@ return $self->num; } } + +%extend FOO_bar { + void bar_extend() { + $self->d = 1; + } +}; + #endif %inline %{ @@ -72,5 +79,13 @@ typedef struct { int num; } lowB_instance; } NestedB; + +typedef struct { + int a; + union { + char c; + int d; + } bar; +} FOO; %} diff --git a/Source/Modules/nested.cxx b/Source/Modules/nested.cxx index 169263c3f..510270681 100644 --- a/Source/Modules/nested.cxx +++ b/Source/Modules/nested.cxx @@ -378,8 +378,6 @@ void Swig_nested_name_unnamed_c_structs(Node *n) { decl = nextSibling(decl); } Delete(ty); - // Check for extensions - // TODO: we can save extensions hash like class hash and move check_extensions() after nesting processing if (extendhash) { if (Node *am = Getattr(extendhash, name)) { // Merge the extension into the symbol table -- cgit v1.2.1 From 3692e175bc980d1e1a06729465ff932e3bcc8e08 Mon Sep 17 00:00:00 2001 From: Vladimir Kalinin Date: Thu, 15 May 2014 03:13:25 +0400 Subject: global unnamed structures ignored --- Examples/test-suite/nested_extend_c.i | 4 ++++ Source/Modules/nested.cxx | 7 ++++++- Source/Modules/typepass.cxx | 3 +++ 3 files changed, 13 insertions(+), 1 deletion(-) diff --git a/Examples/test-suite/nested_extend_c.i b/Examples/test-suite/nested_extend_c.i index 702c839b2..0e1495f86 100644 --- a/Examples/test-suite/nested_extend_c.i +++ b/Examples/test-suite/nested_extend_c.i @@ -87,5 +87,9 @@ typedef struct { int d; } bar; } FOO; + +struct { + int i; +} THING; %} diff --git a/Source/Modules/nested.cxx b/Source/Modules/nested.cxx index 510270681..ca1c79a31 100644 --- a/Source/Modules/nested.cxx +++ b/Source/Modules/nested.cxx @@ -396,7 +396,12 @@ void Swig_nested_name_unnamed_c_structs(Node *n) { Delete(ins); Delattr(c, "nested:outer"); } else { - // global unnamed struct - ignore it + // global unnamed struct - ignore it and it's instances + SetFlag(c, "feature:ignore"); + while (next && Getattr(next, "nested:unnamedtype") == c) { + SetFlag(next, "feature:ignore"); + next = nextSibling(next); + } c = next; continue; } diff --git a/Source/Modules/typepass.cxx b/Source/Modules/typepass.cxx index 329a601a8..ec6f64587 100644 --- a/Source/Modules/typepass.cxx +++ b/Source/Modules/typepass.cxx @@ -661,6 +661,9 @@ class TypePass:private Dispatcher { * ------------------------------------------------------------ */ virtual int cDeclaration(Node *n) { + if (GetFlag(n, "feature:ignore")) { + return SWIG_OK; + } if (NoExcept) { Delattr(n, "throws"); } -- cgit v1.2.1 From 2b5499a2628edda34f2deccd668001093d4a562d Mon Sep 17 00:00:00 2001 From: William S Fulton Date: Tue, 13 May 2014 23:30:00 +0100 Subject: Slight simplification of test-suite build for new out-of-source changes Provide default SRCDIR and SCRIPTDIR variables in common.mk and override only where needed. --- Examples/Makefile.in | 4 ++-- Examples/test-suite/allegrocl/Makefile.in | 5 ----- Examples/test-suite/cffi/Makefile.in | 5 ----- Examples/test-suite/chicken/Makefile.in | 5 ----- Examples/test-suite/clisp/Makefile.in | 5 ----- Examples/test-suite/common.mk | 2 ++ Examples/test-suite/csharp/Makefile.in | 7 +------ Examples/test-suite/d/Makefile.in | 5 ----- Examples/test-suite/errors/Makefile.in | 5 ----- Examples/test-suite/go/Makefile.in | 6 ------ Examples/test-suite/guile/Makefile.in | 6 ------ Examples/test-suite/java/Makefile.in | 7 +------ Examples/test-suite/javascript/Makefile.in | 5 ----- Examples/test-suite/lua/Makefile.in | 6 ------ Examples/test-suite/mzscheme/Makefile.in | 5 ----- Examples/test-suite/ocaml/Makefile.in | 5 ----- Examples/test-suite/octave/Makefile.in | 6 ------ Examples/test-suite/perl5/Makefile.in | 6 ------ Examples/test-suite/php/Makefile.in | 6 ------ Examples/test-suite/pike/Makefile.in | 5 ----- Examples/test-suite/python/Makefile.in | 15 +++------------ Examples/test-suite/r/Makefile.in | 5 ----- Examples/test-suite/ruby/Makefile.in | 6 ------ Examples/test-suite/tcl/Makefile.in | 6 ------ Examples/test-suite/uffi/Makefile.in | 5 ----- 25 files changed, 9 insertions(+), 134 deletions(-) diff --git a/Examples/Makefile.in b/Examples/Makefile.in index dcfbd83b9..d22a85abc 100644 --- a/Examples/Makefile.in +++ b/Examples/Makefile.in @@ -26,8 +26,8 @@ Makefile: @srcdir@/Makefile.in ../config.status cd .. && $(SHELL) ./config.status Examples/Makefile # SRCDIR is the relative path to the current source directory -# - For in-source-tree builds, SRCDIR with be either '', -# or '../' for some of the test suites (e.g. C#, Java) +# - For in-source-tree builds, SRCDIR with be either '' or './', but +# '../' for the test suites that build in a subdir (e.g. C#, Java) # - For out-of-source-tree builds, SRCDIR will be a relative # path ending with a '/' diff --git a/Examples/test-suite/allegrocl/Makefile.in b/Examples/test-suite/allegrocl/Makefile.in index 2803b7012..7c21e18cd 100644 --- a/Examples/test-suite/allegrocl/Makefile.in +++ b/Examples/test-suite/allegrocl/Makefile.in @@ -9,11 +9,6 @@ SCRIPTSUFFIX = _runme.lisp srcdir = @srcdir@ top_srcdir = @top_srcdir@ top_builddir = @top_builddir@ -ifeq (.,$(srcdir)) -SRCDIR = -else -SRCDIR = $(srcdir)/ -endif # these cpp tests generate warnings/errors when compiling diff --git a/Examples/test-suite/cffi/Makefile.in b/Examples/test-suite/cffi/Makefile.in index a530e2243..164538e2b 100644 --- a/Examples/test-suite/cffi/Makefile.in +++ b/Examples/test-suite/cffi/Makefile.in @@ -9,11 +9,6 @@ SCRIPTSUFFIX = _runme.lisp srcdir = @srcdir@ top_srcdir = @top_srcdir@ top_builddir = @top_builddir@ -ifeq (.,$(srcdir)) -SRCDIR = -else -SRCDIR = $(srcdir)/ -endif include $(srcdir)/../common.mk diff --git a/Examples/test-suite/chicken/Makefile.in b/Examples/test-suite/chicken/Makefile.in index ac02dad83..bdda02b7e 100644 --- a/Examples/test-suite/chicken/Makefile.in +++ b/Examples/test-suite/chicken/Makefile.in @@ -10,11 +10,6 @@ PROXYSUFFIX = _runme_proxy.ss srcdir = @srcdir@ top_srcdir = @top_srcdir@ top_builddir = @top_builddir@ -ifeq (.,$(srcdir)) -SRCDIR = -else -SRCDIR = $(srcdir)/ -endif CHICKEN_CSI = @CHICKEN_CSI@ -quiet -batch -no-init SO = @SO@ diff --git a/Examples/test-suite/clisp/Makefile.in b/Examples/test-suite/clisp/Makefile.in index 9db84c561..525605254 100644 --- a/Examples/test-suite/clisp/Makefile.in +++ b/Examples/test-suite/clisp/Makefile.in @@ -9,11 +9,6 @@ SCRIPTSUFFIX = _runme.lisp srcdir = @srcdir@ top_srcdir = @top_srcdir@ top_builddir = @top_builddir@ -ifeq (.,$(srcdir)) -SRCDIR = -else -SRCDIR = $(srcdir)/ -endif include $(srcdir)/../common.mk diff --git a/Examples/test-suite/common.mk b/Examples/test-suite/common.mk index 37d660989..d93d788c9 100644 --- a/Examples/test-suite/common.mk +++ b/Examples/test-suite/common.mk @@ -70,6 +70,8 @@ LIBS = -L. LIBPREFIX = lib ACTION = check INTERFACEDIR = ../ +SRCDIR = $(srcdir)/ +SCRIPTDIR = $(srcdir) # Regenerate Makefile if Makefile.in or config.status have changed. ifeq (,$(TEST_SUITE_SUBDIR)) diff --git a/Examples/test-suite/csharp/Makefile.in b/Examples/test-suite/csharp/Makefile.in index a2a0828fd..7bec108eb 100644 --- a/Examples/test-suite/csharp/Makefile.in +++ b/Examples/test-suite/csharp/Makefile.in @@ -3,7 +3,6 @@ ####################################################################### LANGUAGE = csharp -SCRIPTDIR = $(srcdir) SCRIPTSUFFIX = _runme.cs CSHARPCILINTERPRETER = @CSHARPCILINTERPRETER@ CSHARPCILINTERPRETER_FLAGS = @CSHARPCILINTERPRETER_FLAGS@ @@ -13,11 +12,6 @@ CSHARPCYGPATH_W = @CSHARPCYGPATH_W@ srcdir = @srcdir@ top_srcdir = ../@top_srcdir@ top_builddir = ../@top_builddir@ -ifeq (.,$(srcdir)) -SRCDIR = ../ -else -SRCDIR = ../$(srcdir)/ -endif CPP_TEST_CASES = \ csharp_attributes \ @@ -37,6 +31,7 @@ CPP_TEST_CASES = \ include $(srcdir)/../common.mk # Overridden variables here +SRCDIR = ../$(srcdir)/ SWIGOPT += -namespace $*Namespace CSHARPFLAGSSPECIAL = diff --git a/Examples/test-suite/d/Makefile.in b/Examples/test-suite/d/Makefile.in index 0542bbad0..42fac00bc 100644 --- a/Examples/test-suite/d/Makefile.in +++ b/Examples/test-suite/d/Makefile.in @@ -7,11 +7,6 @@ LANGUAGE = d srcdir = @srcdir@ top_srcdir = @top_srcdir@ top_builddir = @top_builddir@ -ifeq (.,$(srcdir)) -SRCDIR = -else -SRCDIR = $(srcdir)/ -endif ifeq (2,$(D_VERSION)) VERSIONSUFFIX = .2 diff --git a/Examples/test-suite/errors/Makefile.in b/Examples/test-suite/errors/Makefile.in index c74e9c65b..9ca6f6ecd 100644 --- a/Examples/test-suite/errors/Makefile.in +++ b/Examples/test-suite/errors/Makefile.in @@ -22,11 +22,6 @@ TODOS = tr -d '\r' srcdir = @srcdir@ top_srcdir = @top_srcdir@ top_builddir = @top_builddir@ -ifeq (.,$(srcdir)) -SRCDIR = -else -SRCDIR = $(srcdir)/ -endif # strip source directory from output, so that diffs compare srcdir_regexp = $(shell echo $(srcdir)/ | sed 's/\./[.]/g') diff --git a/Examples/test-suite/go/Makefile.in b/Examples/test-suite/go/Makefile.in index 03f6f151e..204cf8a12 100644 --- a/Examples/test-suite/go/Makefile.in +++ b/Examples/test-suite/go/Makefile.in @@ -9,7 +9,6 @@ GO1 = @GO1@ GO12 = @GO12@ GO13 = @GO13@ GOC = @GOC@ -SCRIPTDIR = $(srcdir) SCRIPTSUFFIX = _runme.go GOCOMPILEARG = `if $(GOGCC) ; then echo -c -g; elif $(GO1) ; then echo tool $(GOC:c=g) ; fi` @@ -24,11 +23,6 @@ SO = @SO@ srcdir = @srcdir@ top_srcdir = @top_srcdir@ top_builddir = @top_builddir@ -ifeq (.,$(srcdir)) -SRCDIR = -else -SRCDIR = $(srcdir)/ -endif include $(srcdir)/../common.mk diff --git a/Examples/test-suite/guile/Makefile.in b/Examples/test-suite/guile/Makefile.in index 5ac3de685..6cbf3b9b1 100644 --- a/Examples/test-suite/guile/Makefile.in +++ b/Examples/test-suite/guile/Makefile.in @@ -6,17 +6,11 @@ EXTRA_TEST_CASES += guile_ext_test.externaltest LANGUAGE = guile VARIANT = -SCRIPTDIR = $(srcdir) SCRIPTSUFFIX = _runme.scm srcdir = @srcdir@ top_srcdir = @top_srcdir@ top_builddir = @top_builddir@ -ifeq (.,$(srcdir)) -SRCDIR = -else -SRCDIR = $(srcdir)/ -endif GUILE = @GUILE@ GUILE_RUNTIME= diff --git a/Examples/test-suite/java/Makefile.in b/Examples/test-suite/java/Makefile.in index a61452ed2..dd6c74a51 100644 --- a/Examples/test-suite/java/Makefile.in +++ b/Examples/test-suite/java/Makefile.in @@ -6,17 +6,11 @@ LANGUAGE = java JAVA = @JAVA@ JAVAC = @JAVAC@ JAVAFLAGS = -Xcheck:jni -SCRIPTDIR = $(srcdir) SCRIPTSUFFIX = _runme.java srcdir = @srcdir@ top_srcdir = ../@top_srcdir@ top_builddir = ../@top_builddir@ -ifeq (.,$(srcdir)) -SRCDIR = ../ -else -SRCDIR = ../$(srcdir)/ -endif C_TEST_CASES = \ java_lib_arrays \ @@ -49,6 +43,7 @@ CPP_TEST_CASES = \ include $(srcdir)/../common.mk # Overridden variables here +SRCDIR = ../$(srcdir)/ JAVA_PACKAGE = $* JAVA_PACKAGEOPT = -package $(JAVA_PACKAGE) SWIGOPT += $(JAVA_PACKAGEOPT) diff --git a/Examples/test-suite/javascript/Makefile.in b/Examples/test-suite/javascript/Makefile.in index 6126bde74..211310e86 100644 --- a/Examples/test-suite/javascript/Makefile.in +++ b/Examples/test-suite/javascript/Makefile.in @@ -10,11 +10,6 @@ SCRIPTSUFFIX = _runme.js srcdir = @srcdir@ top_srcdir = @top_srcdir@ top_builddir = @top_builddir@ -ifeq (.,$(srcdir)) -SRCDIR = -else -SRCDIR = $(srcdir)/ -endif SWIG = $(top_builddir)/preinst_swig diff --git a/Examples/test-suite/lua/Makefile.in b/Examples/test-suite/lua/Makefile.in index b35cc15ad..00f940825 100644 --- a/Examples/test-suite/lua/Makefile.in +++ b/Examples/test-suite/lua/Makefile.in @@ -4,17 +4,11 @@ LANGUAGE = lua LUA = @LUABIN@ -SCRIPTDIR = $(srcdir) SCRIPTSUFFIX = _runme.lua srcdir = @srcdir@ top_srcdir = @top_srcdir@ top_builddir = @top_builddir@ -ifeq (.,$(srcdir)) -SRCDIR = -else -SRCDIR = $(srcdir)/ -endif # sorry, currently very few test cases work/have been written diff --git a/Examples/test-suite/mzscheme/Makefile.in b/Examples/test-suite/mzscheme/Makefile.in index 39fb1acbc..1c2466efc 100644 --- a/Examples/test-suite/mzscheme/Makefile.in +++ b/Examples/test-suite/mzscheme/Makefile.in @@ -9,11 +9,6 @@ SCRIPTSUFFIX = _runme.scm srcdir = @srcdir@ top_srcdir = @top_srcdir@ top_builddir = @top_builddir@ -ifeq (.,$(srcdir)) -SRCDIR = -else -SRCDIR = $(srcdir)/ -endif include $(srcdir)/../common.mk diff --git a/Examples/test-suite/ocaml/Makefile.in b/Examples/test-suite/ocaml/Makefile.in index 5081e203e..c9c4bb603 100644 --- a/Examples/test-suite/ocaml/Makefile.in +++ b/Examples/test-suite/ocaml/Makefile.in @@ -10,11 +10,6 @@ SCRIPTSUFFIX = _runme.ml srcdir = @srcdir@ top_srcdir = @top_srcdir@ top_builddir = @top_builddir@ -ifeq (.,$(srcdir)) -SRCDIR = -else -SRCDIR = $(srcdir)/ -endif C_TEST_CASES = diff --git a/Examples/test-suite/octave/Makefile.in b/Examples/test-suite/octave/Makefile.in index 11cb7c076..4f78371f4 100644 --- a/Examples/test-suite/octave/Makefile.in +++ b/Examples/test-suite/octave/Makefile.in @@ -4,17 +4,11 @@ LANGUAGE = octave OCTAVE = @OCTAVE@ -SCRIPTDIR = $(srcdir) SCRIPTSUFFIX = _runme.m srcdir = @srcdir@ top_srcdir = @top_srcdir@ top_builddir = @top_builddir@ -ifeq (.,$(srcdir)) -SRCDIR = -else -SRCDIR = $(srcdir)/ -endif CPP_TEST_CASES += \ li_std_pair_extra \ diff --git a/Examples/test-suite/perl5/Makefile.in b/Examples/test-suite/perl5/Makefile.in index 6778f714e..9d9d460d8 100644 --- a/Examples/test-suite/perl5/Makefile.in +++ b/Examples/test-suite/perl5/Makefile.in @@ -4,18 +4,12 @@ LANGUAGE = perl5 PERL = @PERL@ -SCRIPTDIR = $(srcdir) SCRIPTSUFFIX = _runme.pl TEST_RUNNER = $(srcdir)/run-perl-test.pl srcdir = @srcdir@ top_srcdir = @top_srcdir@ top_builddir = @top_builddir@ -ifeq (.,$(srcdir)) -SRCDIR = -else -SRCDIR = $(srcdir)/ -endif CPP_TEST_CASES += \ primitive_types \ diff --git a/Examples/test-suite/php/Makefile.in b/Examples/test-suite/php/Makefile.in index b6e4fff1a..5f56760ea 100644 --- a/Examples/test-suite/php/Makefile.in +++ b/Examples/test-suite/php/Makefile.in @@ -3,17 +3,11 @@ ####################################################################### LANGUAGE = php -SCRIPTDIR = $(srcdir) SCRIPTSUFFIX = _runme.php srcdir = @srcdir@ top_srcdir = @top_srcdir@ top_builddir = @top_builddir@ -ifeq (.,$(srcdir)) -SRCDIR = -else -SRCDIR = $(srcdir)/ -endif CPP_TEST_CASES += \ php_namewarn_rename \ diff --git a/Examples/test-suite/pike/Makefile.in b/Examples/test-suite/pike/Makefile.in index 36a34352a..414fa1159 100644 --- a/Examples/test-suite/pike/Makefile.in +++ b/Examples/test-suite/pike/Makefile.in @@ -9,11 +9,6 @@ SCRIPTSUFFIX = _runme.pike srcdir = @srcdir@ top_srcdir = @top_srcdir@ top_builddir = @top_builddir@ -ifeq (.,$(srcdir)) -SRCDIR = -else -SRCDIR = $(srcdir)/ -endif include $(srcdir)/../common.mk diff --git a/Examples/test-suite/python/Makefile.in b/Examples/test-suite/python/Makefile.in index 719e7d1a4..492396d15 100644 --- a/Examples/test-suite/python/Makefile.in +++ b/Examples/test-suite/python/Makefile.in @@ -14,6 +14,7 @@ PYTHON = $(PYBIN) #*_runme.py for Python 2.x, *_runme3.py for Python 3.x PY2SCRIPTSUFFIX = _runme.py PY3SCRIPTSUFFIX = _runme3.py +PY2TO3 = 2to3 -x import ifeq (,$(PY3)) SCRIPTSUFFIX = $(PY2SCRIPTSUFFIX) @@ -21,20 +22,9 @@ else SCRIPTSUFFIX = $(PY3SCRIPTSUFFIX) endif -SCRIPTDIR = . - srcdir = @srcdir@ top_srcdir = @top_srcdir@ top_builddir = @top_builddir@ -ifeq (.,$(srcdir)) -SRCDIR = -else -SRCDIR = $(srcdir)/ -endif - - -PY2TO3 = 2to3 -x import - CPP_TEST_CASES += \ argcargvtest \ @@ -109,7 +99,8 @@ BUILTIN_NOT_BROKEN = $(filter-out $(BUILTIN_BROKEN),$(NOT_BROKEN_TEST_CASES)) builtin-check : $(BUILTIN_NOT_BROKEN) # Overridden variables here -LIBS = -L. +SCRIPTDIR = . +LIBS = -L. VALGRIND_OPT += --suppressions=pythonswig.supp # Custom tests - tests with additional commandline options diff --git a/Examples/test-suite/r/Makefile.in b/Examples/test-suite/r/Makefile.in index 9f0de1c5f..8bf537d8c 100644 --- a/Examples/test-suite/r/Makefile.in +++ b/Examples/test-suite/r/Makefile.in @@ -10,11 +10,6 @@ RUNR = R CMD BATCH --no-save --no-restore srcdir = @srcdir@ top_srcdir = @top_srcdir@ top_builddir = @top_builddir@ -ifeq (.,$(srcdir)) -SRCDIR = -else -SRCDIR = $(srcdir)/ -endif C_TEST_CASES += \ r_copy_struct \ diff --git a/Examples/test-suite/ruby/Makefile.in b/Examples/test-suite/ruby/Makefile.in index d0c65929a..206617ecd 100644 --- a/Examples/test-suite/ruby/Makefile.in +++ b/Examples/test-suite/ruby/Makefile.in @@ -4,17 +4,11 @@ LANGUAGE = ruby RUBY = @RUBY@ -SCRIPTDIR = $(srcdir) SCRIPTSUFFIX = _runme.rb srcdir = @srcdir@ top_srcdir = @top_srcdir@ top_builddir = @top_builddir@ -ifeq (.,$(srcdir)) -SRCDIR = -else -SRCDIR = $(srcdir)/ -endif CPP_TEST_CASES = \ kwargs_feature \ diff --git a/Examples/test-suite/tcl/Makefile.in b/Examples/test-suite/tcl/Makefile.in index f8a196e26..32454b09c 100644 --- a/Examples/test-suite/tcl/Makefile.in +++ b/Examples/test-suite/tcl/Makefile.in @@ -4,17 +4,11 @@ LANGUAGE = tcl TCLSH = tclsh -SCRIPTDIR = $(srcdir) SCRIPTSUFFIX = _runme.tcl srcdir = @srcdir@ top_srcdir = @top_srcdir@ top_builddir = @top_builddir@ -ifeq (.,$(srcdir)) -SRCDIR = -else -SRCDIR = $(srcdir)/ -endif CPP_TEST_CASES += \ primitive_types \ diff --git a/Examples/test-suite/uffi/Makefile.in b/Examples/test-suite/uffi/Makefile.in index 9f3546da6..7184af40f 100644 --- a/Examples/test-suite/uffi/Makefile.in +++ b/Examples/test-suite/uffi/Makefile.in @@ -9,11 +9,6 @@ SCRIPTSUFFIX = _runme.lisp srcdir = @srcdir@ top_srcdir = @top_srcdir@ top_builddir = @top_builddir@ -ifeq (.,$(srcdir)) -SRCDIR = -else -SRCDIR = $(srcdir)/ -endif include $(srcdir)/../common.mk -- cgit v1.2.1 From beccd3258fc1fd9e0c3caef3a21fdaeffcef81d3 Mon Sep 17 00:00:00 2001 From: William S Fulton Date: Tue, 13 May 2014 23:52:55 +0100 Subject: Update all languages to use SCRIPTDIR R also to use SCRIPTPREFIX and SCRIPTSUFFIX --- Examples/test-suite/allegrocl/Makefile.in | 4 ++-- Examples/test-suite/cffi/Makefile.in | 4 ++-- Examples/test-suite/chicken/Makefile.in | 10 +++++----- Examples/test-suite/clisp/Makefile.in | 4 ++-- Examples/test-suite/d/Makefile.in | 8 ++++---- Examples/test-suite/javascript/Makefile.in | 2 +- Examples/test-suite/mzscheme/Makefile.in | 4 ++-- Examples/test-suite/ocaml/Makefile.in | 8 ++++---- Examples/test-suite/pike/Makefile.in | 4 ++-- Examples/test-suite/r/Makefile.in | 12 ++++++------ Examples/test-suite/uffi/Makefile.in | 4 ++-- 11 files changed, 32 insertions(+), 32 deletions(-) diff --git a/Examples/test-suite/allegrocl/Makefile.in b/Examples/test-suite/allegrocl/Makefile.in index 7c21e18cd..8c253a7f2 100644 --- a/Examples/test-suite/allegrocl/Makefile.in +++ b/Examples/test-suite/allegrocl/Makefile.in @@ -115,8 +115,8 @@ include $(srcdir)/../common.mk # Runs the testcase. A testcase is only run if # a file is found which has _runme.lisp appended after the testcase name. run_testcase = \ - if [ -f $(srcdir)/$(SCRIPTPREFIX)$*$(SCRIPTSUFFIX) ]; then \ - env LD_LIBRARY_PATH=.:$$LD_LIBRARY_PATH $(RUNTOOL) $(ALLEGROCLBIN) -batch -s $(srcdir)/$(SCRIPTPREFIX)$*$(SCRIPTSUFFIX); \ + if [ -f $(SCRIPTDIR)/$(SCRIPTPREFIX)$*$(SCRIPTSUFFIX) ]; then \ + env LD_LIBRARY_PATH=.:$$LD_LIBRARY_PATH $(RUNTOOL) $(ALLEGROCLBIN) -batch -s $(SCRIPTDIR)/$(SCRIPTPREFIX)$*$(SCRIPTSUFFIX); \ fi %.clean: diff --git a/Examples/test-suite/cffi/Makefile.in b/Examples/test-suite/cffi/Makefile.in index 164538e2b..6e657ba46 100644 --- a/Examples/test-suite/cffi/Makefile.in +++ b/Examples/test-suite/cffi/Makefile.in @@ -39,8 +39,8 @@ CPP_TEST_CASES = # Runs the testcase. A testcase is only run if # a file is found which has _runme.lisp appended after the testcase name. run_testcase = \ - if [ -f $(srcdir)/$(SCRIPTPREFIX)$*$(SCRIPTSUFFIX) ]; then \ - env LD_LIBRARY_PATH=.:$$LD_LIBRARY_PATH $(RUNTOOL) $(CFFI) -batch -s $(srcdir)/$(SCRIPTPREFIX)$*$(SCRIPTSUFFIX); \ + if [ -f $(SCRIPTDIR)/$(SCRIPTPREFIX)$*$(SCRIPTSUFFIX) ]; then \ + env LD_LIBRARY_PATH=.:$$LD_LIBRARY_PATH $(RUNTOOL) $(CFFI) -batch -s $(SCRIPTDIR)/$(SCRIPTPREFIX)$*$(SCRIPTSUFFIX); \ fi # Clean: (does nothing, we dont generate extra cffi code) diff --git a/Examples/test-suite/chicken/Makefile.in b/Examples/test-suite/chicken/Makefile.in index bdda02b7e..5a2ef3d8a 100644 --- a/Examples/test-suite/chicken/Makefile.in +++ b/Examples/test-suite/chicken/Makefile.in @@ -45,7 +45,7 @@ SWIGOPT += -nounit $(setup) +$(swig_and_compile_cpp) $(run_testcase) - if [ -f $(srcdir)/$(SCRIPTPREFIX)$*$(PROXYSUFFIX) ]; then \ + if [ -f $(SCRIPTDIR)/$(SCRIPTPREFIX)$*$(PROXYSUFFIX) ]; then \ $(MAKE) $*.cppproxy; \ fi @@ -53,7 +53,7 @@ SWIGOPT += -nounit $(setup) +$(swig_and_compile_c) $(run_testcase) - if [ -f $(srcdir)/$(SCRIPTPREFIX)$*$(PROXYSUFFIX) ]; then \ + if [ -f $(SCRIPTDIR)/$(SCRIPTPREFIX)$*$(PROXYSUFFIX) ]; then \ $(MAKE) $*.cproxy; \ fi @@ -61,7 +61,7 @@ SWIGOPT += -nounit $(setup) +$(swig_and_compile_multi_cpp) $(run_testcase) - if [ -f $(srcdir)/$(SCRIPTPREFIX)$*$(PROXYSUFFIX) ]; then \ + if [ -f $(SCRIPTDIR)/$(SCRIPTPREFIX)$*$(PROXYSUFFIX) ]; then \ $(MAKE) $*.multiproxy; \ fi @@ -88,8 +88,8 @@ SWIGOPT += -nounit # Runs the testcase. A testcase is only run if # a file is found which has _runme.scm appended after the testcase name. run_testcase = \ - if [ -f $(srcdir)/$(SCRIPTPREFIX)$*$(SCRIPTSUFFIX) ]; then \ - env LD_LIBRARY_PATH=.:$$LD_LIBRARY_PATH $(RUNTOOL) $(CHICKEN_CSI) $(srcdir)/$(SCRIPTPREFIX)$*$(SCRIPTSUFFIX); \ + if [ -f $(SCRIPTDIR)/$(SCRIPTPREFIX)$*$(SCRIPTSUFFIX) ]; then \ + env LD_LIBRARY_PATH=.:$$LD_LIBRARY_PATH $(RUNTOOL) $(CHICKEN_CSI) $(SCRIPTDIR)/$(SCRIPTPREFIX)$*$(SCRIPTSUFFIX); \ fi # Clean diff --git a/Examples/test-suite/clisp/Makefile.in b/Examples/test-suite/clisp/Makefile.in index 525605254..43f7159ff 100644 --- a/Examples/test-suite/clisp/Makefile.in +++ b/Examples/test-suite/clisp/Makefile.in @@ -39,8 +39,8 @@ CPP_TEST_CASES = # Runs the testcase. A testcase is only run if # a file is found which has _runme.lisp appended after the testcase name. run_testcase = \ - if [ -f $(srcdir)/$(SCRIPTPREFIX)$*$(SCRIPTSUFFIX) ]; then \ - env LD_LIBRARY_PATH=.:$$LD_LIBRARY_PATH $(RUNTOOL) $(CLISP) -batch -s $(srcdir)/$(SCRIPTPREFIX)$*$(SCRIPTSUFFIX); \ + if [ -f $(SCRIPTDIR)/$(SCRIPTPREFIX)$*$(SCRIPTSUFFIX) ]; then \ + env LD_LIBRARY_PATH=.:$$LD_LIBRARY_PATH $(RUNTOOL) $(CLISP) -batch -s $(SCRIPTDIR)/$(SCRIPTPREFIX)$*$(SCRIPTSUFFIX); \ fi # Clean: (does nothing, we dont generate extra clisp code) diff --git a/Examples/test-suite/d/Makefile.in b/Examples/test-suite/d/Makefile.in index 42fac00bc..37a944b09 100644 --- a/Examples/test-suite/d/Makefile.in +++ b/Examples/test-suite/d/Makefile.in @@ -14,7 +14,7 @@ else VERSIONSUFFIX = .1 endif -TESTSUFFIX = _runme$(VERSIONSUFFIX).d +SCRIPTSUFFIX = _runme$(VERSIONSUFFIX).d CPP_TEST_CASES = \ d_nativepointers \ @@ -46,7 +46,7 @@ SWIGOPT+=-splitproxy -package $* # Makes a directory for the testcase if it does not exist setup = \ - if [ -f $(srcdir)/$(TESTPREFIX)$*$(TESTSUFFIX) ]; then \ + if [ -f $(SCRIPTDIR)/$(SCRIPTPREFIX)$*$(SCRIPTSUFFIX) ]; then \ echo "$(ACTION)ing $(LANGUAGE) testcase $* (with run test)" ; \ else \ echo "$(ACTION)ing $(LANGUAGE) testcase $*" ; \ @@ -61,11 +61,11 @@ setup = \ # Compiles D files then runs the testcase. A testcase is only run if # a file is found which has _runme.d appended after the testcase name. run_testcase = \ - if [ -f $(srcdir)/$(TESTPREFIX)$*$(TESTSUFFIX) ]; then \ + if [ -f $(SCRIPTDIR)/$(SCRIPTPREFIX)$*$(SCRIPTSUFFIX) ]; then \ cd $*$(VERSIONSUFFIX) && \ $(MAKE) -f $(top_builddir)/$(EXAMPLES)/Makefile \ DFLAGS='-of$*_runme' \ - DSRCS='../$(srcdir)/$(TESTPREFIX)$*$(TESTSUFFIX) `find $* -name *.d`' d_compile && \ + DSRCS='../$(SCRIPTDIR)/$(SCRIPTPREFIX)$*$(SCRIPTSUFFIX) `find $* -name *.d`' d_compile && \ env LD_LIBRARY_PATH=".:$$LD_LIBRARY_PATH" $(RUNTOOL) ./$*_runme; \ else \ cd $*$(VERSIONSUFFIX) && \ diff --git a/Examples/test-suite/javascript/Makefile.in b/Examples/test-suite/javascript/Makefile.in index 211310e86..87e4c6ecb 100644 --- a/Examples/test-suite/javascript/Makefile.in +++ b/Examples/test-suite/javascript/Makefile.in @@ -22,7 +22,7 @@ endif include $(srcdir)/../common.mk _setup = \ - if [ -f $(srcdir)/$(SCRIPTPREFIX)$*$(SCRIPTSUFFIX) ]; then \ + if [ -f $(SCRIPTDIR)/$(SCRIPTPREFIX)$*$(SCRIPTSUFFIX) ]; then \ echo "$(ACTION)ing $(LANGUAGE) ($(JSENGINE)) testcase $* (with run test)" ; \ else \ echo "$(ACTION)ing $(LANGUAGE) ($(JSENGINE)) testcase $*" ; \ diff --git a/Examples/test-suite/mzscheme/Makefile.in b/Examples/test-suite/mzscheme/Makefile.in index 1c2466efc..034e52131 100644 --- a/Examples/test-suite/mzscheme/Makefile.in +++ b/Examples/test-suite/mzscheme/Makefile.in @@ -37,8 +37,8 @@ include $(srcdir)/../common.mk # Runs the testcase. A testcase is only run if # a file is found which has _runme.scm appended after the testcase name. run_testcase = \ - if [ -f $(srcdir)/$(SCRIPTPREFIX)$*$(SCRIPTSUFFIX) ]; then \ - env LD_LIBRARY_PATH=.:$$LD_LIBRARY_PATH $(RUNTOOL) $(MZSCHEME) -r $(srcdir)/$(SCRIPTPREFIX)$*$(SCRIPTSUFFIX); \ + if [ -f $(SCRIPTDIR)/$(SCRIPTPREFIX)$*$(SCRIPTSUFFIX) ]; then \ + env LD_LIBRARY_PATH=.:$$LD_LIBRARY_PATH $(RUNTOOL) $(MZSCHEME) -r $(SCRIPTDIR)/$(SCRIPTPREFIX)$*$(SCRIPTSUFFIX); \ fi # Clean diff --git a/Examples/test-suite/ocaml/Makefile.in b/Examples/test-suite/ocaml/Makefile.in index c9c4bb603..ee93d534c 100644 --- a/Examples/test-suite/ocaml/Makefile.in +++ b/Examples/test-suite/ocaml/Makefile.in @@ -14,12 +14,12 @@ top_builddir = @top_builddir@ C_TEST_CASES = run_testcase = \ - if [ -f $(srcdir)/$(SCRIPTPREFIX)$*$(SCRIPTSUFFIX) -a \ + if [ -f $(SCRIPTDIR)/$(SCRIPTPREFIX)$*$(SCRIPTSUFFIX) -a \ -f $(top_srcdir)/Examples/test-suite/$*.list ] ; then \ - $(COMPILETOOL) $(OCAMLC) -c $(srcdir)/$(SCRIPTPREFIX)$*$(SCRIPTSUFFIX); \ + $(COMPILETOOL) $(OCAMLC) -c $(SCRIPTDIR)/$(SCRIPTPREFIX)$*$(SCRIPTSUFFIX); \ $(COMPILETOOL) $(OCAMLC) swig.cmo -custom -g -cc '$(CXX)' -o runme `cat $(top_srcdir)/Examples/test-suite/$(*).list | sed -e 's/\(.*\)/\1_wrap.o \1.cmo/g'`&& $(RUNTOOL) ./runme; \ - elif [ -f $(srcdir)/$(SCRIPTPREFIX)$*$(SCRIPTSUFFIX) ]; then \ - $(COMPILETOOL) $(OCAMLC) -c $(srcdir)/$(SCRIPTPREFIX)$*$(SCRIPTSUFFIX); \ + elif [ -f $(SCRIPTDIR)/$(SCRIPTPREFIX)$*$(SCRIPTSUFFIX) ]; then \ + $(COMPILETOOL) $(OCAMLC) -c $(SCRIPTDIR)/$(SCRIPTPREFIX)$*$(SCRIPTSUFFIX); \ $(COMPILETOOL) $(OCAMLC) swig.cmo -custom -g -cc '$(CXX)' -o runme $(srcdir)/$(*).cmo $(srcdir)/$(*)_runme.cmo $(srcdir)/$(*)_wrap.o && \ $(RUNTOOL) ./runme; \ fi ; diff --git a/Examples/test-suite/pike/Makefile.in b/Examples/test-suite/pike/Makefile.in index 414fa1159..579c7e28f 100644 --- a/Examples/test-suite/pike/Makefile.in +++ b/Examples/test-suite/pike/Makefile.in @@ -37,8 +37,8 @@ include $(srcdir)/../common.mk # Runs the testcase. A testcase is only run if # a file is found which has _runme.pike appended after the testcase name. run_testcase = \ - if [ -f $(srcdir)/$(SCRIPTPREFIX)$*$(SCRIPTSUFFIX) ]; then \ - env LD_LIBRARY_PATH=.:$$LD_LIBRARY_PATH $(RUNTOOL) $(PIKE) $(srcdir)/$(SCRIPTPREFIX)$*$(SCRIPTSUFFIX); \ + if [ -f $(SCRIPTDIR)/$(SCRIPTPREFIX)$*$(SCRIPTSUFFIX) ]; then \ + env LD_LIBRARY_PATH=.:$$LD_LIBRARY_PATH $(RUNTOOL) $(PIKE) $(SCRIPTDIR)/$(SCRIPTPREFIX)$*$(SCRIPTSUFFIX); \ fi # Clean: remove the generated .pike file diff --git a/Examples/test-suite/r/Makefile.in b/Examples/test-suite/r/Makefile.in index 8bf537d8c..cab339bf7 100644 --- a/Examples/test-suite/r/Makefile.in +++ b/Examples/test-suite/r/Makefile.in @@ -49,19 +49,19 @@ include $(srcdir)/../common.mk # Run the runme if it exists. If not just load the R wrapper to # check for syntactic correctness run_testcase = \ - if [ -f $(srcdir)/$(SCRIPTPREFIX)$*$(SCRIPTSUFFIX) ]; then \ - env LD_LIBRARY_PATH=.:$$LD_LIBRARY_PATH PATH=.:"$$PATH" $(RUNTOOL) $(RUNR) $(srcdir)/$(SCRIPTPREFIX)$*$(SCRIPTSUFFIX); \ + if [ -f $(SCRIPTDIR)/$(SCRIPTPREFIX)$*$(SCRIPTSUFFIX) ]; then \ + env LD_LIBRARY_PATH=.:$$LD_LIBRARY_PATH PATH=.:"$$PATH" $(RUNTOOL) $(RUNR) $(SCRIPTDIR)/$(SCRIPTPREFIX)$*$(SCRIPTSUFFIX); \ else \ - $(RUNTOOL) $(RUNR) $(srcdir)/$(SCRIPTPREFIX)$*$(WRAPSUFFIX); \ + $(RUNTOOL) $(RUNR) $(SCRIPTDIR)/$(SCRIPTPREFIX)$*$(WRAPSUFFIX); \ fi run_multitestcase = \ for f in `cat $(top_srcdir)/$(EXAMPLES)/$(TEST_SUITE)/$*.list` ; do \ - if [ -f $(srcdir)/$(SCRIPTPREFIX)$${f}$(SCRIPTSUFFIX) ]; then \ + if [ -f $(SCRIPTDIR)/$(SCRIPTPREFIX)$${f}$(SCRIPTSUFFIX) ]; then \ env LD_LIBRARY_PATH=.:$$LD_LIBRARY_PATH PATH=.:"$$PATH" \ - $(RUNTOOL) $(RUNR) $(srcdir)/$(SCRIPTPREFIX)$${f}$(SCRIPTSUFFIX); \ + $(RUNTOOL) $(RUNR) $(SCRIPTDIR)/$(SCRIPTPREFIX)$${f}$(SCRIPTSUFFIX); \ else \ - $(RUNTOOL) $(RUNR) $(srcdir)/$(SCRIPTPREFIX)$${f}$(WRAPSUFFIX); \ + $(RUNTOOL) $(RUNR) $(SCRIPTDIR)/$(SCRIPTPREFIX)$${f}$(WRAPSUFFIX); \ fi; \ done # Clean diff --git a/Examples/test-suite/uffi/Makefile.in b/Examples/test-suite/uffi/Makefile.in index 7184af40f..59aa33c6a 100644 --- a/Examples/test-suite/uffi/Makefile.in +++ b/Examples/test-suite/uffi/Makefile.in @@ -39,8 +39,8 @@ CPP_TEST_CASES = # Runs the testcase. A testcase is only run if # a file is found which has _runme.lisp appended after the testcase name. run_testcase = \ - if [ -f $(srcdir)/$(SCRIPTPREFIX)$*$(SCRIPTSUFFIX) ]; then \ - env LD_LIBRARY_PATH=.:$$LD_LIBRARY_PATH $(RUNTOOL) $(UFFI) -batch -s $(srcdir)/$(SCRIPTPREFIX)$*$(SCRIPTSUFFIX); \ + if [ -f $(SCRIPTDIR)/$(SCRIPTPREFIX)$*$(SCRIPTSUFFIX) ]; then \ + env LD_LIBRARY_PATH=.:$$LD_LIBRARY_PATH $(RUNTOOL) $(UFFI) -batch -s $(SCRIPTDIR)/$(SCRIPTPREFIX)$*$(SCRIPTSUFFIX); \ fi # Clean: (does nothing, we dont generate extra uffi code) -- cgit v1.2.1 From 28c3549e433620e6aa94571471e51433aad4d447 Mon Sep 17 00:00:00 2001 From: William S Fulton Date: Wed, 14 May 2014 00:48:51 +0100 Subject: Partially fix R out of source test-suite Fix when there is NOT a runme.R file --- Examples/test-suite/r/Makefile.in | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/Examples/test-suite/r/Makefile.in b/Examples/test-suite/r/Makefile.in index cab339bf7..8ee73b279 100644 --- a/Examples/test-suite/r/Makefile.in +++ b/Examples/test-suite/r/Makefile.in @@ -52,7 +52,7 @@ run_testcase = \ if [ -f $(SCRIPTDIR)/$(SCRIPTPREFIX)$*$(SCRIPTSUFFIX) ]; then \ env LD_LIBRARY_PATH=.:$$LD_LIBRARY_PATH PATH=.:"$$PATH" $(RUNTOOL) $(RUNR) $(SCRIPTDIR)/$(SCRIPTPREFIX)$*$(SCRIPTSUFFIX); \ else \ - $(RUNTOOL) $(RUNR) $(SCRIPTDIR)/$(SCRIPTPREFIX)$*$(WRAPSUFFIX); \ + $(RUNTOOL) $(RUNR) ./$(SCRIPTPREFIX)$*$(WRAPSUFFIX); \ fi run_multitestcase = \ @@ -61,7 +61,7 @@ run_multitestcase = \ env LD_LIBRARY_PATH=.:$$LD_LIBRARY_PATH PATH=.:"$$PATH" \ $(RUNTOOL) $(RUNR) $(SCRIPTDIR)/$(SCRIPTPREFIX)$${f}$(SCRIPTSUFFIX); \ else \ - $(RUNTOOL) $(RUNR) $(SCRIPTDIR)/$(SCRIPTPREFIX)$${f}$(WRAPSUFFIX); \ + $(RUNTOOL) $(RUNR) ./$(SCRIPTPREFIX)$${f}$(WRAPSUFFIX); \ fi; \ done # Clean -- cgit v1.2.1 From 4e47bbee06405811523f5426e812620ac58e86d4 Mon Sep 17 00:00:00 2001 From: William S Fulton Date: Wed, 14 May 2014 00:50:06 +0100 Subject: gitignore to ignore build directory names --- .gitignore | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.gitignore b/.gitignore index ce6a3c4b7..efb6cf096 100644 --- a/.gitignore +++ b/.gitignore @@ -138,4 +138,4 @@ Examples/test-suite/uffi/*/ Examples/scratch # Out of source tree build directories -_build*/ +*build*/ -- cgit v1.2.1 From d927fa5376d7c1c19568ab653f1097ef082cae00 Mon Sep 17 00:00:00 2001 From: William S Fulton Date: Wed, 14 May 2014 22:23:40 +0100 Subject: Remove unnecessary make invocation when running test-suite --- Makefile.in | 3 --- 1 file changed, 3 deletions(-) diff --git a/Makefile.in b/Makefile.in index 8c6072b41..da9dfdce5 100644 --- a/Makefile.in +++ b/Makefile.in @@ -285,9 +285,6 @@ check-test-suite: \ check-javascript-test-suite check-%-test-suite: - @if test -d Examples/test-suite/$*; then \ - cd Examples/test-suite/$* && $(MAKE) Makefile; \ - fi @if test -z "$(skip-$*)"; then \ echo $* unknown; \ exit 1; \ -- cgit v1.2.1 From 18d72f4562745f725e981443248b8fbea1a55cae Mon Sep 17 00:00:00 2001 From: William S Fulton Date: Thu, 15 May 2014 20:27:01 +0100 Subject: Add in CPPFLAGS and LDFLAGS to examples/test-suite - Split current usage of CXXFLAGS into the conventional CPPFLAGS CXXFLAGS and LDFLAGS - Split current usage of CFLAGS into the conventional CPPFLAGS CFLAGS and LDFLAGS - This restores 'make whatever CXXFLAGS=-g' which stopped working during the recently added suppport for out of source builds. - LDFLAGS is currently empty, but is there for future use --- Examples/Makefile.in | 230 ++++++++++++++++++------------------ Examples/chicken/class/Makefile | 1 - Examples/chicken/constants/Makefile | 1 - Examples/chicken/multimap/Makefile | 1 - Examples/chicken/overload/Makefile | 1 - Examples/chicken/simple/Makefile | 1 - Tools/javascript/Makefile.in | 10 +- 7 files changed, 121 insertions(+), 124 deletions(-) diff --git a/Examples/Makefile.in b/Examples/Makefile.in index d22a85abc..7c2d23647 100644 --- a/Examples/Makefile.in +++ b/Examples/Makefile.in @@ -45,8 +45,10 @@ endif TARGET = CC = @CC@ CXX = @CXX@ -CFLAGS = $(SRCDIR_INCLUDE) @PLATCFLAGS@ -CXXFLAGS = $(SRCDIR_INCLUDE) @BOOST_CPPFLAGS@ @PLATCXXFLAGS@ +CPPFLAGS = $(SRCDIR_INCLUDE) +CFLAGS = @PLATCFLAGS@ +CXXFLAGS = @BOOST_CPPFLAGS@ @PLATCXXFLAGS@ +LDFLAGS = prefix = @prefix@ exec_prefix= @exec_prefix@ SRCS = @@ -155,12 +157,12 @@ TCL_SCRIPT = $(SRCDIR)$(RUNME).tcl tclsh: $(SRCDIR_SRCS) $(SWIG) -tcl8 $(SWIGOPT) $(TCL_SWIGOPTS) -ltclsh.i -o $(ISRCS) $(INTERFACEPATH) - $(CC) $(CFLAGS) $(SRCDIR_SRCS) $(ISRCS) $(INCLUDES) $(TCL_INCLUDE) \ + $(CC) $(CPPFLAGS) $(CFLAGS) $(LDFLAGS) $(SRCDIR_SRCS) $(ISRCS) $(INCLUDES) $(TCL_INCLUDE) \ $(TCL_LIB) $(TCL_OPTS) $(LIBS) $(SYSLIBS) -o $(TARGET) tclsh_cpp: $(SRCDIR_SRCS) $(SWIG) -tcl8 -c++ $(SWIGOPT) $(TCL_SWIGOPTS) -ltclsh.i -o $(ICXXSRCS) $(INTERFACEPATH) - $(CXX) $(CXXFLAGS) $(SRCDIR_SRCS) $(SRCDIR_CXXSRCS) $(ICXXSRCS) $(INCLUDES) $(TCL_INCLUDE) \ + $(CXX) $(CPPFLAGS) $(CXXFLAGS) $(LDFLAGS) $(SRCDIR_SRCS) $(SRCDIR_CXXSRCS) $(ICXXSRCS) $(INCLUDES) $(TCL_INCLUDE) \ $(TCL_LIB) $(TCL_OPTS) $(LIBS) $(SYSLIBS) -o $(TARGET) # ----------------------------------------------------------- @@ -169,8 +171,8 @@ tclsh_cpp: $(SRCDIR_SRCS) tcl: $(SRCDIR_SRCS) $(SWIG) -tcl8 $(SWIGOPT) $(TCL_SWIGOPTS) -o $(ISRCS) $(INTERFACEPATH) - $(CC) -c $(CCSHARED) $(CFLAGS) $(SRCDIR_SRCS) $(ISRCS) $(INCLUDES) $(TCL_INCLUDE) - $(TCLLDSHARED) $(CFLAGS) $(OBJS) $(IOBJS) $(TCL_DLNK) $(LIBS) -o $(LIBPREFIX)$(TARGET)$(TCL_SO) + $(CC) -c $(CCSHARED) $(CPPFLAGS) $(CFLAGS) $(SRCDIR_SRCS) $(ISRCS) $(INCLUDES) $(TCL_INCLUDE) + $(TCLLDSHARED) $(CFLAGS) $(LDFLAGS) $(OBJS) $(IOBJS) $(TCL_DLNK) $(LIBS) -o $(LIBPREFIX)$(TARGET)$(TCL_SO) # ----------------------------------------------------------- # Build a Tcl7.5 dynamic loadable module for C++ @@ -178,8 +180,8 @@ tcl: $(SRCDIR_SRCS) tcl_cpp: $(SRCDIR_SRCS) $(SWIG) -tcl8 -c++ $(SWIGOPT) $(TCL_SWIGOPTS) -o $(ICXXSRCS) $(INTERFACEPATH) - $(CXX) -c $(CCSHARED) $(CXXFLAGS) $(SRCDIR_SRCS) $(SRCDIR_CXXSRCS) $(ICXXSRCS) $(INCLUDES) $(TCL_INCLUDE) - $(TCLCXXSHARED) $(CXXFLAGS) $(OBJS) $(IOBJS) $(TCL_DLNK) $(LIBS) $(CPP_DLLIBS) -o $(LIBPREFIX)$(TARGET)$(TCL_SO) + $(CXX) -c $(CCSHARED) $(CPPFLAGS) $(CXXFLAGS) $(SRCDIR_SRCS) $(SRCDIR_CXXSRCS) $(ICXXSRCS) $(INCLUDES) $(TCL_INCLUDE) + $(TCLCXXSHARED) $(CXXFLAGS) $(LDFLAGS) $(OBJS) $(IOBJS) $(TCL_DLNK) $(LIBS) $(CPP_DLLIBS) -o $(LIBPREFIX)$(TARGET)$(TCL_SO) # ----------------------------------------------------------------- # Run Tcl example @@ -230,8 +232,8 @@ PERL5_SCRIPT = $(SRCDIR)$(RUNME).pl perl5: $(SRCDIR_SRCS) $(SWIG) -perl5 $(SWIGOPT) -o $(ISRCS) $(INTERFACEPATH) - $(CC) -c -Dbool=char $(CCSHARED) $(CFLAGS) $(SRCDIR_SRCS) $(ISRCS) $(INCLUDES) $(PERL5_CCFLAGS) $(PERL5_CCCDLFLAGS) -I$(PERL5_INCLUDE) - $(LDSHARED) $(CFLAGS) $(PERL5_CCDLFLAGS) $(OBJS) $(IOBJS) $(PERL5_LDFLAGS) $(PERL5_DLNK) $(LIBS) -o $(LIBPREFIX)$(TARGET)$(SO) + $(CC) -c -Dbool=char $(CCSHARED) $(CPPFLAGS) $(CFLAGS) $(SRCDIR_SRCS) $(ISRCS) $(INCLUDES) $(PERL5_CCFLAGS) $(PERL5_CCCDLFLAGS) -I$(PERL5_INCLUDE) + $(LDSHARED) $(CFLAGS) $(LDFLAGS) $(PERL5_CCDLFLAGS) $(OBJS) $(IOBJS) $(PERL5_LDFLAGS) $(PERL5_DLNK) $(LIBS) -o $(LIBPREFIX)$(TARGET)$(SO) # ---------------------------------------------------------------- # Build a Perl5 dynamically loadable module (C++) @@ -239,15 +241,15 @@ perl5: $(SRCDIR_SRCS) perl5_cpp: $(SRCDIR_SRCS) $(SWIG) -perl5 -c++ $(SWIGOPT) -o $(ICXXSRCS) $(INTERFACEPATH) - $(CXX) -c $(CCSHARED) $(CXXFLAGS) $(SRCDIR_SRCS) $(SRCDIR_CXXSRCS) $(ICXXSRCS) $(INCLUDES) $(PERL5_CCFLAGS) $(PERL5_CCCDLFLAGS) -I$(PERL5_INCLUDE) - $(CXXSHARED) $(CXXFLAGS) $(PERL5_CCDLFLAGS) $(OBJS) $(IOBJS) $(PERL5_LDFLAGS) $(PERL5_DLNK) $(LIBS) $(CPP_DLLIBS) -o $(LIBPREFIX)$(TARGET)$(SO) + $(CXX) -c $(CCSHARED) $(CPPFLAGS) $(CXXFLAGS) $(SRCDIR_SRCS) $(SRCDIR_CXXSRCS) $(ICXXSRCS) $(INCLUDES) $(PERL5_CCFLAGS) $(PERL5_CCCDLFLAGS) -I$(PERL5_INCLUDE) + $(CXXSHARED) $(CXXFLAGS) $(LDFLAGS) $(PERL5_CCDLFLAGS) $(OBJS) $(IOBJS) $(PERL5_LDFLAGS) $(PERL5_DLNK) $(LIBS) $(CPP_DLLIBS) -o $(LIBPREFIX)$(TARGET)$(SO) # ---------------------------------------------------------------- # Build a module from existing XS C source code. (ie. from xsubpp). # ---------------------------------------------------------------- perl5_xs: $(SRCDIR_SRCS) - $(CC) -c $(CCSHARED) $(CFLAGS) $(SRCDIR_SRCS) $(INCLUDES) -I$(PERL5_INCLUDE) - $(LDSHARED) $(CFLAGS) $(OBJS) $(LIBS) -o $(TARGET)$(SO) + $(CC) -c $(CCSHARED) $(CPPFLAGS) $(CFLAGS) $(SRCDIR_SRCS) $(INCLUDES) -I$(PERL5_INCLUDE) + $(LDSHARED) $(CFLAGS) $(LDFLAGS) $(OBJS) $(LIBS) -o $(TARGET)$(SO) # ---------------------------------------------------------------- # Build a statically linked Perl5 executable @@ -255,11 +257,11 @@ perl5_xs: $(SRCDIR_SRCS) perl5_static: $(SRCDIR_SRCS) $(SWIG) -perl5 -static -lperlmain.i $(SWIGOPT) -o $(ISRCS) $(INTERFACEPATH) - $(CC) $(CFLAGS) -Dbool=char $(SRCDIR_SRCS) $(ISRCS) $(INCLUDES) -I$(PERL5_INCLUDE) $(PERL5_LIB) $(LIBS) -o $(TARGET) + $(CC) $(CPPFLAGS) $(CFLAGS) $(LDFLAGS) -Dbool=char $(SRCDIR_SRCS) $(ISRCS) $(INCLUDES) -I$(PERL5_INCLUDE) $(PERL5_LIB) $(LIBS) -o $(TARGET) perl5_static_cpp: $(SRCDIR_SRCS) $(SWIG) -perl5 -c++ -static -lperlmain.i $(SWIGOPT) -o $(ICXXSRCS) $(INTERFACEPATH) - $(CXX) $(CXXFLAGS) $(SRCDIR_SRCS) $(SRCDIR_CXXSRCS) $(ICXXSRCS) $(INCLUDES) -I$(PERL5_INCLUDE) $(PERL5_LIB) $(LIBS) -o $(TARGET) + $(CXX) $(CPPFLAGS) $(CXXFLAGS) $(LDFLAGS) $(SRCDIR_SRCS) $(SRCDIR_CXXSRCS) $(ICXXSRCS) $(INCLUDES) -I$(PERL5_INCLUDE) $(PERL5_LIB) $(LIBS) -o $(TARGET) # ----------------------------------------------------------------- # Running a Perl5 example @@ -324,8 +326,8 @@ endif python: $(SRCDIR_SRCS) $(SWIGPYTHON) $(SWIGOPT) -o $(ISRCS) $(INTERFACEPATH) - $(CC) -c $(CCSHARED) $(CFLAGS) $(ISRCS) $(SRCDIR_SRCS) $(INCLUDES) $(PYTHON_INCLUDE) - $(LDSHARED) $(CFLAGS) $(OBJS) $(IOBJS) $(PYTHON_DLNK) $(LIBS) -o $(LIBPREFIX)_$(TARGET)$(PYTHON_SO) + $(CC) -c $(CCSHARED) $(CPPFLAGS) $(CFLAGS) $(ISRCS) $(SRCDIR_SRCS) $(INCLUDES) $(PYTHON_INCLUDE) + $(LDSHARED) $(CFLAGS) $(LDFLAGS) $(OBJS) $(IOBJS) $(PYTHON_DLNK) $(LIBS) -o $(LIBPREFIX)_$(TARGET)$(PYTHON_SO) # ----------------------------------------------------------------- # Build a C++ dynamically loadable module @@ -333,8 +335,8 @@ python: $(SRCDIR_SRCS) python_cpp: $(SRCDIR_SRCS) $(SWIGPYTHON) -c++ $(SWIGOPT) -o $(ICXXSRCS) $(INTERFACEPATH) - $(CXX) -c $(CCSHARED) $(CXXFLAGS) $(ICXXSRCS) $(SRCDIR_SRCS) $(SRCDIR_CXXSRCS) $(INCLUDES) $(PYTHON_INCLUDE) - $(CXXSHARED) $(CXXFLAGS) $(OBJS) $(IOBJS) $(PYTHON_DLNK) $(LIBS) $(CPP_DLLIBS) -o $(LIBPREFIX)_$(TARGET)$(PYTHON_SO) + $(CXX) -c $(CCSHARED) $(CPPFLAGS) $(CXXFLAGS) $(ICXXSRCS) $(SRCDIR_SRCS) $(SRCDIR_CXXSRCS) $(INCLUDES) $(PYTHON_INCLUDE) + $(CXXSHARED) $(CXXFLAGS) $(LDFLAGS) $(OBJS) $(IOBJS) $(PYTHON_DLNK) $(LIBS) $(CPP_DLLIBS) -o $(LIBPREFIX)_$(TARGET)$(PYTHON_SO) # ----------------------------------------------------------------- # Build statically linked Python interpreter @@ -349,12 +351,12 @@ PYTHON_LIBOPTS = $(PYTHON_LINK) @LIBS@ $(TKINTER) $(SYSLIBS) python_static: $(SRCDIR_SRCS) $(SWIGPYTHON) -lembed.i $(SWIGOPT) -o $(ISRCS) $(INTERFACEPATH) - $(CC) $(CFLAGS) @LINKFORSHARED@ $(ISRCS) $(SRCDIR_SRCS) $(INCLUDES) \ + $(CC) $(CPPFLAGS) $(CFLAGS) $(LDFLAGS) @LINKFORSHARED@ $(ISRCS) $(SRCDIR_SRCS) $(INCLUDES) \ $(PYTHON_INCLUDE) $(LIBS) -L$(PYTHON_LIB) $(PYTHON_LIBOPTS) -o $(TARGET) python_static_cpp: $(SRCDIR_SRCS) $(SWIGPYTHON) -c++ -lembed.i $(SWIGOPT) -o $(ICXXSRCS) $(INTERFACEPATH) - $(CXX) $(CXXFLAGS) $(ICXXSRCS) $(SRCDIR_SRCS) $(SRCDIR_CXXSRCS) $(INCLUDES) \ + $(CXX) $(CPPFLAGS) $(CXXFLAGS) $(LDFLAGS) $(ICXXSRCS) $(SRCDIR_SRCS) $(SRCDIR_CXXSRCS) $(INCLUDES) \ $(PYTHON_INCLUDE) $(LIBS) -L$(PYTHON_LIB) $(PYTHON_LIBOPTS) -o $(TARGET) # ----------------------------------------------------------------- @@ -423,9 +425,9 @@ OCTAVE_SCRIPT = $(SRCDIR)$(RUNME).m octave: $(SRCDIR_SRCS) $(SWIG) -octave $(SWIGOPT) -o $(ICXXSRCS) $(INTERFACEPATH) - $(CXX) -g -c $(CCSHARED) $(CXXFLAGS) $(ICXXSRCS) $(INCLUDES) $(OCTAVE_CXX) - $(CC) -g -c $(CCSHARED) $(CFLAGS) $(SRCDIR_SRCS) $(SRCDIR_CSRCS) $(INCLUDES) - $(LDSHARED) $(CFLAGS) $(OBJS) $(IOBJS) $(OCTAVE_DLNK) $(LIBS) -o $(LIBPREFIX)$(TARGET)$(OCTAVE_SO) + $(CXX) -g -c $(CCSHARED) $(CPPFLAGS) $(CXXFLAGS) $(ICXXSRCS) $(INCLUDES) $(OCTAVE_CXX) + $(CC) -g -c $(CCSHARED) $(CPPFLAGS) $(CFLAGS) $(SRCDIR_SRCS) $(SRCDIR_CSRCS) $(INCLUDES) + $(LDSHARED) $(CFLAGS) $(LDFLAGS) $(OBJS) $(IOBJS) $(OCTAVE_DLNK) $(LIBS) -o $(LIBPREFIX)$(TARGET)$(OCTAVE_SO) # ----------------------------------------------------------------- # Build a C++ dynamically loadable module @@ -433,8 +435,8 @@ octave: $(SRCDIR_SRCS) octave_cpp: $(SRCDIR_SRCS) $(SWIG) -c++ -octave $(SWIGOPT) -o $(ICXXSRCS) $(INTERFACEPATH) - $(CXX) -g -c $(CCSHARED) $(CXXFLAGS) $(ICXXSRCS) $(SRCDIR_SRCS) $(SRCDIR_CXXSRCS) $(INCLUDES) $(OCTAVE_CXX) - $(CXXSHARED) -g $(CXXFLAGS) $(OBJS) $(IOBJS) $(OCTAVE_DLNK) $(LIBS) $(CPP_DLLIBS) -o $(LIBPREFIX)$(TARGET)$(OCTAVE_SO) + $(CXX) -g -c $(CCSHARED) $(CPPFLAGS) $(CXXFLAGS) $(ICXXSRCS) $(SRCDIR_SRCS) $(SRCDIR_CXXSRCS) $(INCLUDES) $(OCTAVE_CXX) + $(CXXSHARED) -g $(CXXFLAGS) $(LDFLAGS) $(OBJS) $(IOBJS) $(OCTAVE_DLNK) $(LIBS) $(CPP_DLLIBS) -o $(LIBPREFIX)$(TARGET)$(OCTAVE_SO) # ----------------------------------------------------------------- # Running an Octave example @@ -478,14 +480,14 @@ GUILE_SCRIPT = $(SRCDIR)$(RUNME).scm #------------------------------------------------------------------ guile: $(SRCDIR_SRCS) $(SWIG) -guile -Linkage passive $(SWIGOPT) -o $(ISRCS) $(INTERFACEPATH) - $(CC) -c $(CCSHARED) $(CFLAGS) $(INCLUDES) $(GUILE_CFLAGS) $(ISRCS) $(SRCDIR_SRCS) - $(LDSHARED) $(CFLAGS) $(OBJS) $(IOBJS) $(GUILE_LIBS) $(LIBS) -o $(GUILE_LIBPREFIX)$(TARGET)$(GUILE_SO) + $(CC) -c $(CCSHARED) $(CPPFLAGS) $(CFLAGS) $(INCLUDES) $(GUILE_CFLAGS) $(ISRCS) $(SRCDIR_SRCS) + $(LDSHARED) $(CFLAGS) $(LDFLAGS) $(OBJS) $(IOBJS) $(GUILE_LIBS) $(LIBS) -o $(GUILE_LIBPREFIX)$(TARGET)$(GUILE_SO) guile_cpp: $(GUILE_LIBPREFIX)$(TARGET)$(GUILE_SO) $(GUILE_LIBPREFIX)$(TARGET)$(GUILE_SO): $(SRCDIR_SRCS) $(SWIG) -c++ -guile -Linkage passive $(SWIGOPT) -o $(ICXXSRCS) $(INTERFACEPATH) - $(CXX) -c $(CCSHARED) $(CXXFLAGS) $(INCLUDES) $(GUILE_CFLAGS) $(ICXXSRCS) $(SRCDIR_SRCS) $(SRCDIR_CXXSRCS) - $(CXXSHARED) $(CXXFLAGS) $(OBJS) $(IOBJS) $(GUILE_LIBS) $(LIBS) $(CPP_DLLIBS) -o $@ + $(CXX) -c $(CCSHARED) $(CPPFLAGS) $(CXXFLAGS) $(INCLUDES) $(GUILE_CFLAGS) $(ICXXSRCS) $(SRCDIR_SRCS) $(SRCDIR_CXXSRCS) + $(CXXSHARED) $(CXXFLAGS) $(LDFLAGS) $(OBJS) $(IOBJS) $(GUILE_LIBS) $(LIBS) $(CPP_DLLIBS) -o $@ guile_externalhdr: $(SWIG) -guile -external-runtime $(TARGET) @@ -496,7 +498,7 @@ guile_externalhdr: guile_augmented: $(SRCDIR_SRCS) $(SWIG) -guile $(SWIGOPT) -o $(ISRCS) $(INTERFACEPATH) - $(CC) $(CXXFLAGS) $(SRCDIR_SRCS) $(ISRCS) $(GUILE_CFLAGS) $(GUILE_LIBS) $(LIBS) -o $(TARGET) + $(CC) $(CPPFLAGS) $(CXXFLAGS) $(LDFLAGS) $(SRCDIR_SRCS) $(ISRCS) $(GUILE_CFLAGS) $(GUILE_LIBS) $(LIBS) -o $(TARGET) # ----------------------------------------------------------------- # Build statically linked Guile interpreter @@ -504,24 +506,24 @@ guile_augmented: $(SRCDIR_SRCS) guile_static: $(SRCDIR_SRCS) $(SWIG) -guile -lguilemain.i -Linkage ltdlmod $(SWIGOPT) -o $(ISRCS) $(INTERFACEPATH) - $(CC) $(CFLAGS) $(ISRCS) $(SRCDIR_SRCS) $(INCLUDES) \ + $(CC) $(CPPFLAGS) $(CFLAGS) $(LDFLAGS) $(ISRCS) $(SRCDIR_SRCS) $(INCLUDES) \ -DSWIGINIT="SCM scm_init_$(TARGET)_module(void); scm_init_$(TARGET)_module();" \ $(GUILE_CFLAGS) $(GUILE_LIBS) $(LIBS) $(GUILE_LIBOPTS) -o $(TARGET)-guile guile_static_cpp: $(SRCDIR_SRCS) $(SWIG) -c++ -guile -lguilemain.i -Linkage ltdlmod $(SWIGOPT) -o $(ICXXSRCS) $(INTERFACEPATH) - $(CXX) $(CXXFLAGS) $(ICXXSRCS) $(SRCDIR_SRCS) $(SRCDIR_CXXSRCS) $(INCLUDES) \ + $(CXX) $(CPPFLAGS) $(CXXFLAGS) $(LDFLAGS) $(ICXXSRCS) $(SRCDIR_SRCS) $(SRCDIR_CXXSRCS) $(INCLUDES) \ -DSWIGINIT="SCM scm_init_$(TARGET)_module(void); scm_init_$(TARGET)_module();" \ $(GUILE_CFLAGS) $(GUILE_LIBS) $(LIBS) $(GUILE_LIBOPTS) -o $(TARGET)-guile guile_simple: $(SRCDIR_SRCS) $(SWIG) -guile -lguilemain.i -Linkage simple $(SWIGOPT) -o $(ISRCS) $(INTERFACEPATH) - $(CC) $(CFLAGS) $(ISRCS) $(SRCDIR_SRCS) $(INCLUDES) \ + $(CC) $(CPPFLAGS) $(CFLAGS) $(LDFLAGS) $(ISRCS) $(SRCDIR_SRCS) $(INCLUDES) \ $(GUILE_CFLAGS) $(GUILE_LIBS) $(LIBS) $(GUILE_LIBOPTS) -o $(TARGET)-guile guile_simple_cpp: $(SRCDIR_SRCS) $(SWIG) -c++ -guile -lguilemain.i -Linkage simple $(SWIGOPT) -o $(ICXXSRCS) $(INTERFACEPATH) - $(CXX) $(CXXFLAGS) $(ICXXSRCS) $(SRCDIR_SRCS) $(SRCDIR_CXXSRCS) $(INCLUDES) \ + $(CXX) $(CPPFLAGS) $(CXXFLAGS) $(LDFLAGS) $(ICXXSRCS) $(SRCDIR_SRCS) $(SRCDIR_CXXSRCS) $(INCLUDES) \ $(GUILE_CFLAGS) $(GUILE_LIBS) $(LIBS) $(GUILE_LIBOPTS) -o $(TARGET)-guile # ----------------------------------------------------------------- @@ -575,8 +577,8 @@ JAVAC = @JAVAC@ -d . java: $(SRCDIR_SRCS) $(SWIG) -java $(SWIGOPT) -o $(ISRCS) $(realpath $(INTERFACEPATH)) - $(CC) -c $(CCSHARED) $(CFLAGS) $(JAVACFLAGS) $(SRCDIR_SRCS) $(ISRCS) $(INCLUDES) $(JAVA_INCLUDE) - $(JAVALDSHARED) $(CFLAGS) $(OBJS) $(IOBJS) $(JAVA_DLNK) $(LIBS) -o $(JAVA_LIBPREFIX)$(TARGET)$(JAVASO) + $(CC) -c $(CCSHARED) $(CPPFLAGS) $(CFLAGS) $(JAVACFLAGS) $(SRCDIR_SRCS) $(ISRCS) $(INCLUDES) $(JAVA_INCLUDE) + $(JAVALDSHARED) $(CFLAGS) $(LDFLAGS) $(OBJS) $(IOBJS) $(JAVA_DLNK) $(LIBS) -o $(JAVA_LIBPREFIX)$(TARGET)$(JAVASO) # ---------------------------------------------------------------- # Build a java dynamically loadable module (C++) @@ -584,8 +586,8 @@ java: $(SRCDIR_SRCS) java_cpp: $(SRCDIR_SRCS) $(SWIG) -java -c++ $(SWIGOPT) -o $(ICXXSRCS) $(realpath $(INTERFACEPATH)) - $(CXX) -c $(CCSHARED) $(CXXFLAGS) $(JAVACFLAGS) $(SRCDIR_SRCS) $(SRCDIR_CXXSRCS) $(ICXXSRCS) $(INCLUDES) $(JAVA_INCLUDE) - $(JAVACXXSHARED) $(CXXFLAGS) $(OBJS) $(IOBJS) $(JAVA_DLNK) $(LIBS) $(CPP_DLLIBS) -o $(JAVA_LIBPREFIX)$(TARGET)$(JAVASO) + $(CXX) -c $(CCSHARED) $(CPPFLAGS) $(CXXFLAGS) $(JAVACFLAGS) $(SRCDIR_SRCS) $(SRCDIR_CXXSRCS) $(ICXXSRCS) $(INCLUDES) $(JAVA_INCLUDE) + $(JAVACXXSHARED) $(CXXFLAGS) $(LDFLAGS) $(OBJS) $(IOBJS) $(JAVA_DLNK) $(LIBS) $(CPP_DLLIBS) -o $(JAVA_LIBPREFIX)$(TARGET)$(JAVASO) # ---------------------------------------------------------------- # Compile java files @@ -646,16 +648,16 @@ javascript_wrapper_cpp: $(SRCDIR_SRCS) $(SWIG) -javascript -c++ $(SWIGOPT) -o $(INTERFACEDIR)$(TARGET)_wrap.cxx $(INTERFACEPATH) javascript_build: $(SRCDIR_SRCS) - $(CC) -c $(CCSHARED) $(CFLAGS) $(ISRCS) $(SRCDIR_SRCS) $(INCLUDES) $(JSINCLUDES) - $(LDSHARED) $(CFLAGS) $(OBJS) $(IOBJS) $(JSDYNAMICLINKING) $(LIBS) -o $(LIBPREFIX)$(TARGET)$(SO) + $(CC) -c $(CCSHARED) $(CPPFLAGS) $(CFLAGS) $(ISRCS) $(SRCDIR_SRCS) $(INCLUDES) $(JSINCLUDES) + $(LDSHARED) $(CFLAGS) $(LDFLAGS) $(OBJS) $(IOBJS) $(JSDYNAMICLINKING) $(LIBS) -o $(LIBPREFIX)$(TARGET)$(SO) javascript_build_cpp: $(SRCDIR_SRCS) ifeq (node,$(JSENGINE)) sed -e 's|$$srcdir|./$(SRCDIR)|g' $(SRCDIR)binding.gyp.in > binding.gyp $(NODEGYP) --loglevel=silent configure build 1>>/dev/null else - $(CXX) -c $(CCSHARED) $(CFLAGS) $(ICXXSRCS) $(SRCDIR_SRCS) $(SRCDIR_CXXSRCS) $(INCLUDES) $(JSINCLUDES) - $(CXXSHARED) $(CFLAGS) $(OBJS) $(IOBJS) $(JSDYNAMICLINKING) $(LIBS) $(CPP_DLLIBS) -o $(LIBPREFIX)$(TARGET)$(SO) + $(CXX) -c $(CCSHARED) $(CPPFLAGS) $(CFLAGS) $(ICXXSRCS) $(SRCDIR_SRCS) $(SRCDIR_CXXSRCS) $(INCLUDES) $(JSINCLUDES) + $(CXXSHARED) $(CFLAGS) $(LDFLAGS) $(OBJS) $(IOBJS) $(JSDYNAMICLINKING) $(LIBS) $(CPP_DLLIBS) -o $(LIBPREFIX)$(TARGET)$(SO) endif @@ -664,17 +666,17 @@ endif javascript: $(SRCDIR_SRCS) javascript_custom_interpreter $(SWIG) -javascript $(SWIGOPT) $(INTERFACEPATH) ifeq (jsc, $(ENGINE)) - $(CC) -c $(CCSHARED) $(CFLAGS) $(ISRCS) $(SRCDIR_SRCS) $(INCLUDES) $(JSINCLUDES) - $(LDSHARED) $(CFLAGS) $(OBJS) $(IOBJS) $(JSDYNAMICLINKING) $(LIBS) -o $(LIBPREFIX)$(TARGET)$(SO) + $(CC) -c $(CCSHARED) $(CPPFLAGS) $(CFLAGS) $(ISRCS) $(SRCDIR_SRCS) $(INCLUDES) $(JSINCLUDES) + $(LDSHARED) $(CFLAGS) $(LDFLAGS) $(OBJS) $(IOBJS) $(JSDYNAMICLINKING) $(LIBS) -o $(LIBPREFIX)$(TARGET)$(SO) else # (v8 | node) # v8 and node must be compiled as c++ - $(CXX) -c $(CCSHARED) $(CFLAGS) $(ISRCS) $(SRCDIR_SRCS) $(SRCDIR_CXXSRCS) $(INCLUDES) $(JSINCLUDES) - $(CXXSHARED) $(CFLAGS) $(OBJS) $(IOBJS) $(JSDYNAMICLINKING) $(LIBS) $(CPP_DLLIBS) -o $(LIBPREFIX)$(TARGET)$(SO) + $(CXX) -c $(CCSHARED) $(CPPFLAGS) $(CFLAGS) $(ISRCS) $(SRCDIR_SRCS) $(SRCDIR_CXXSRCS) $(INCLUDES) $(JSINCLUDES) + $(CXXSHARED) $(CFLAGS) $(LDFLAGS) $(OBJS) $(IOBJS) $(JSDYNAMICLINKING) $(LIBS) $(CPP_DLLIBS) -o $(LIBPREFIX)$(TARGET)$(SO) endif javascript_cpp: $(SRCDIR_SRCS) javascript_custom_interpreter $(SWIG) -javascript -c++ $(SWIGOPT) $(INTERFACEPATH) - $(CXX) -c $(CCSHARED) $(CFLAGS) $(ICXXSRCS) $(SRCDIR_SRCS) $(SRCDIR_CXXSRCS) $(INCLUDES) $(JSINCLUDES) - $(CXXSHARED) $(CFLAGS) $(OBJS) $(IOBJS) $(JSDYNAMICLINKING) $(LIBS) $(CPP_DLLIBS) -o $(LIBPREFIX)$(TARGET)$(SO) + $(CXX) -c $(CCSHARED) $(CPPFLAGS) $(CFLAGS) $(ICXXSRCS) $(SRCDIR_SRCS) $(SRCDIR_CXXSRCS) $(INCLUDES) $(JSINCLUDES) + $(CXXSHARED) $(CFLAGS) $(LDFLAGS) $(OBJS) $(IOBJS) $(JSDYNAMICLINKING) $(LIBS) $(CPP_DLLIBS) -o $(LIBPREFIX)$(TARGET)$(SO) # ----------------------------------------------------------------- # Running a Javascript example @@ -797,8 +799,6 @@ MODULA3_INCLUDE= @MODULA3INC@ modula3: $(SRCDIR_SRCS) $(SWIG) -modula3 $(SWIGOPT) -o $(ISRCS) $(INTERFACEPATH) -# $(CC) -c $(CCSHARED) $(CFLAGS) $(SRCDIR_SRCS) $(ISRCS) $(INCLUDES) \ -# $(OBJS) $(IOBJS) $(LIBS) modula3_cpp: $(SRCDIR_SRCS) $(SWIG) -modula3 -c++ $(SWIGOPT) -o $(ICXXSRCS) $(INTERFACEPATH) @@ -848,7 +848,7 @@ mzscheme: $(SRCDIR_SRCS) mzscheme_cpp: $(SRCDIR_SRCS) $(SWIG) -mzscheme -c++ $(SWIGOPT) -o $(ICXXSRCS) $(INTERFACEPATH) $(COMPILETOOL) $(MZC) `echo $(INCLUDES) | sed 's/-I/++ccf -I/g'` --cc $(ICXXSRCS) $(SRCDIR_SRCS) $(SRCDIR_CXXSRCS) - $(CXXSHARED) $(CXXFLAGS) -o $(LIBPREFIX)$(TARGET)$(MZSCHEME_SO) $(OBJS) $(IOBJS) $(MZDYNOBJ) $(CPP_DLLIBS) + $(CXXSHARED) $(CPPFLAGS) $(CXXFLAGS) $(LDFLAGS) -o $(LIBPREFIX)$(TARGET)$(MZSCHEME_SO) $(OBJS) $(IOBJS) $(MZDYNOBJ) $(CPP_DLLIBS) # ----------------------------------------------------------------- # Run mzscheme example @@ -913,7 +913,7 @@ ocaml_dynamic: $(SRCDIR_SRCS) $(OCAMLCORE) $(SWIG) -ocaml $(SWIGOPT) -o $(ISRCS) $(INTERFACEPATH) $(OCC) -g -c -ccopt -g -ccopt "$(INCLUDES)" $(ISRCS) $(SRCDIR_SRCS) - $(CXXSHARED) $(CXXFLAGS) $(CCSHARED) $(CFLAGS) -o $(INTERFACE:%.i=%@SO@) \ + $(CXXSHARED) $(CPPFLAGS) $(CXXFLAGS) $(LDFLAGS) $(CCSHARED) -o $(INTERFACE:%.i=%@SO@) \ $(INTERFACE:%.i=%_wrap.@OBJEXT@) $(OBJS) $(LIBS) $(OCAMLDLGEN) $(INTERFACE:%.i=%.ml) $(INTERFACE:%.i=%@SO@) > \ $(INTERFACE:%.i=%_dynamic.ml) @@ -984,7 +984,7 @@ ocaml_dynamic_cpp: $(SRCDIR_SRCS) cp $(ICXXSRCS) $(ICXXSRCS:%.cxx=%.c) $(OCC) -cc '$(CXX) -Wno-write-strings' -g -c -ccopt -g -ccopt "-xc++ $(INCLUDES)" \ $(ICXXSRCS:%.cxx=%.c) $(SRCDIR_SRCS) $(SRCDIR_CXXSRCS) -ccopt -fPIC - $(CXXSHARED) $(CXXFLAGS) -o $(INTERFACE:%.i=%@SO@) \ + $(CXXSHARED) $(CPPFLAGS) $(CXXFLAGS) $(LDFLAGS) -o $(INTERFACE:%.i=%@SO@) \ $(INTERFACE:%.i=%_wrap.@OBJEXT@) $(OBJS) \ $(CPP_DLLIBS) $(LIBS) $(OCAMLDLGEN) $(INTERFACE:%.i=%.ml) $(INTERFACE:%.i=%@SO@) > \ @@ -1045,8 +1045,8 @@ RUBY_SCRIPT = $(SRCDIR)$(RUNME).rb ruby: $(SRCDIR_SRCS) $(SWIG) -ruby $(SWIGOPT) -o $(ISRCS) $(INTERFACEPATH) - $(CC) -c $(CCSHARED) $(CFLAGS) $(RUBY_CFLAGS) $(ISRCS) $(SRCDIR_SRCS) $(INCLUDES) $(RUBY_INCLUDE) - $(LDSHARED) $(CFLAGS) $(OBJS) $(IOBJS) $(RUBY_DLNK) $(LIBS) -o $(LIBPREFIX)$(TARGET)$(RUBY_SO) + $(CC) -c $(CCSHARED) $(CPPFLAGS) $(CFLAGS) $(RUBY_CFLAGS) $(ISRCS) $(SRCDIR_SRCS) $(INCLUDES) $(RUBY_INCLUDE) + $(LDSHARED) $(CFLAGS) $(LDFLAGS) $(OBJS) $(IOBJS) $(RUBY_DLNK) $(LIBS) -o $(LIBPREFIX)$(TARGET)$(RUBY_SO) # ----------------------------------------------------------------- # Build a C++ dynamically loadable module @@ -1054,8 +1054,8 @@ ruby: $(SRCDIR_SRCS) ruby_cpp: $(SRCDIR_SRCS) $(SWIG) -c++ -ruby $(SWIGOPT) -o $(ICXXSRCS) $(INTERFACEPATH) - $(CXX) -c $(CCSHARED) $(CXXFLAGS) $(RUBY_CFLAGS) $(ICXXSRCS) $(SRCDIR_SRCS) $(SRCDIR_CXXSRCS) $(INCLUDES) $(RUBY_INCLUDE) - $(CXXSHARED) $(CXXFLAGS) $(OBJS) $(IOBJS) $(RUBY_DLNK) $(LIBS) $(CPP_DLLIBS) -o $(LIBPREFIX)$(TARGET)$(RUBY_SO) + $(CXX) -c $(CCSHARED) $(CPPFLAGS) $(CXXFLAGS) $(RUBY_CFLAGS) $(ICXXSRCS) $(SRCDIR_SRCS) $(SRCDIR_CXXSRCS) $(INCLUDES) $(RUBY_INCLUDE) + $(CXXSHARED) $(CXXFLAGS) $(LDFLAGS) $(OBJS) $(IOBJS) $(RUBY_DLNK) $(LIBS) $(CPP_DLLIBS) -o $(LIBPREFIX)$(TARGET)$(RUBY_SO) # ----------------------------------------------------------------- # Build statically linked Ruby interpreter @@ -1066,12 +1066,12 @@ ruby_cpp: $(SRCDIR_SRCS) ruby_static: $(SRCDIR_SRCS) $(SWIG) -ruby -lembed.i $(SWIGOPT) -o $(ISRCS) $(INTERFACEPATH) - $(CC) $(CFLAGS) $(RUBY_CFLAGS) @LINKFORSHARED@ $(ISRCS) $(SRCDIR_SRCS) $(INCLUDES) \ + $(CC) $(CPPFLAGS) $(CFLAGS) $(LDFLAGS) $(RUBY_CFLAGS) @LINKFORSHARED@ $(ISRCS) $(SRCDIR_SRCS) $(INCLUDES) \ $(RUBY_INCLUDE) $(LIBS) -L$(RUBY_LIB) $(RUBY_LIBOPTS) -o $(TARGET) ruby_cpp_static: $(SRCDIR_SRCS) $(SWIG) -c++ -ruby -lembed.i $(SWIGOPT) -o $(ICXXSRCS) $(INTERFACEPATH) - $(CXX) $(CXXFLAGS) $(RUBY_CFLAGS) $(ICXXSRCS) $(SRCDIR_SRCS) $(SRCDIR_CXXSRCS) $(INCLUDES) \ + $(CXX) $(CPPFLAGS) $(CXXFLAGS) $(LDFLAGS) $(RUBY_CFLAGS) $(ICXXSRCS) $(SRCDIR_SRCS) $(SRCDIR_CXXSRCS) $(INCLUDES) \ $(RUBY_INCLUDE) $(LIBS) -L$(RUBY_LIB) $(RUBY_LIBOPTS) -o $(TARGET) # ----------------------------------------------------------------- @@ -1112,8 +1112,8 @@ PHP_SCRIPT = $(SRCDIR)$(RUNME).php php: $(SRCDIR_SRCS) $(SWIG) -php $(SWIGOPT) -o $(ISRCS) $(INTERFACEPATH) - $(CC) -c $(CCSHARED) $(CFLAGS) $(SRCDIR_SRCS) $(ISRCS) $(INCLUDES) $(PHP_INCLUDE) - $(LDSHARED) $(CFLAGS) $(OBJS) $(IOBJS) $(LIBS) -o $(LIBPREFIX)$(TARGET)$(PHP_SO) + $(CC) -c $(CCSHARED) $(CPPFLAGS) $(CFLAGS) $(SRCDIR_SRCS) $(ISRCS) $(INCLUDES) $(PHP_INCLUDE) + $(LDSHARED) $(CFLAGS) $(LDFLAGS) $(OBJS) $(IOBJS) $(LIBS) -o $(LIBPREFIX)$(TARGET)$(PHP_SO) # -------------------------------------------------------------------- # Build a PHP dynamically loadable module (C++) @@ -1121,8 +1121,8 @@ php: $(SRCDIR_SRCS) php_cpp: $(SRCDIR_SRCS) $(SWIG) -php -cppext cxx -c++ $(SWIGOPT) -o $(ICXXSRCS) $(INTERFACEPATH) - $(CXX) -c $(CCSHARED) $(CXXFLAGS) $(SRCDIR_SRCS) $(SRCDIR_CXXSRCS) $(ICXXSRCS) $(INCLUDES) $(PHP_INCLUDE) - $(CXXSHARED) $(CXXFLAGS) $(OBJS) $(IOBJS) $(LIBS) $(CPP_DLLIBS) -o $(LIBPREFIX)$(TARGET)$(PHP_SO) + $(CXX) -c $(CCSHARED) $(CPPFLAGS) $(CXXFLAGS) $(SRCDIR_SRCS) $(SRCDIR_CXXSRCS) $(ICXXSRCS) $(INCLUDES) $(PHP_INCLUDE) + $(CXXSHARED) $(CXXFLAGS) $(LDFLAGS) $(OBJS) $(IOBJS) $(LIBS) $(CPP_DLLIBS) -o $(LIBPREFIX)$(TARGET)$(PHP_SO) # ----------------------------------------------------------------- # Running a PHP example @@ -1166,8 +1166,8 @@ PIKE_SCRIPT = $(RUNME).pike pike: $(SRCDIR_SRCS) $(SWIG) -pike $(SWIGOPT) -o $(ISRCS) $(INTERFACEPATH) - $(CC) -c $(CCSHARED) $(CFLAGS) $(PIKE_CFLAGS) $(ISRCS) $(SRCDIR_SRCS) $(INCLUDES) $(PIKE_INCLUDE) - $(LDSHARED) $(CFLAGS) $(OBJS) $(IOBJS) $(PIKE_DLNK) $(LIBS) -o $(LIBPREFIX)$(TARGET)$(SO) + $(CC) -c $(CCSHARED) $(CPPFLAGS) $(CFLAGS) $(PIKE_CFLAGS) $(ISRCS) $(SRCDIR_SRCS) $(INCLUDES) $(PIKE_INCLUDE) + $(LDSHARED) $(CFLAGS) $(LDFLAGS) $(OBJS) $(IOBJS) $(PIKE_DLNK) $(LIBS) -o $(LIBPREFIX)$(TARGET)$(SO) # ----------------------------------------------------------------- # Build a C++ dynamically loadable module @@ -1175,8 +1175,8 @@ pike: $(SRCDIR_SRCS) pike_cpp: $(SRCDIR_SRCS) $(SWIG) -c++ -pike $(SWIGOPT) -o $(ICXXSRCS) $(INTERFACEPATH) - $(CXX) -c $(CCSHARED) $(CXXFLAGS) $(PIKE_CFLAGS) $(ICXXSRCS) $(SRCDIR_SRCS) $(SRCDIR_CXXSRCS) $(INCLUDES) $(PIKE_INCLUDE) - $(CXXSHARED) $(CXXFLAGS) $(OBJS) $(IOBJS) $(PIKE_DLNK) $(LIBS) $(CPP_DLLIBS) -o $(LIBPREFIX)$(TARGET)$(SO) + $(CXX) -c $(CCSHARED) $(CPPFLAGS) $(CXXFLAGS) $(PIKE_CFLAGS) $(ICXXSRCS) $(SRCDIR_SRCS) $(SRCDIR_CXXSRCS) $(INCLUDES) $(PIKE_INCLUDE) + $(CXXSHARED) $(CXXFLAGS) $(LDFLAGS) $(OBJS) $(IOBJS) $(PIKE_DLNK) $(LIBS) $(CPP_DLLIBS) -o $(LIBPREFIX)$(TARGET)$(SO) # ----------------------------------------------------------------- # Build statically linked Pike interpreter @@ -1187,12 +1187,12 @@ pike_cpp: $(SRCDIR_SRCS) pike_static: $(SRCDIR_SRCS) $(SWIG) -pike -lembed.i $(SWIGOPT) -o $(ISRCS) $(INTERFACEPATH) - $(CC) $(CFLAGS) $(PIKE_CFLAGS) @LINKFORSHARED@ $(ISRCS) $(SRCDIR_SRCS) $(INCLUDES) \ + $(CC) $(CPPFLAGS) $(CFLAGS) $(LDFLAGS) $(PIKE_CFLAGS) @LINKFORSHARED@ $(ISRCS) $(SRCDIR_SRCS) $(INCLUDES) \ $(PIKE_INCLUDE) $(LIBS) -L$(PIKE_LIB) $(PIKE_LIBOPTS) -o $(TARGET) pike_cpp_static: $(SRCDIR_SRCS) $(SWIG) -c++ -pike -lembed.i $(SWIGOPT) -o $(ICXXSRCS) $(INTERFACEPATH) - $(CXX) $(CXXFLAGS) $(PIKE_CFLAGS) $(ICXXSRCS) $(SRCDIR_SRCS) $(SRCDIR_CXXSRCS) $(INCLUDES) \ + $(CXX) $(CPPFLAGS) $(CXXFLAGS) $(LDFLAGS) $(PIKE_CFLAGS) $(ICXXSRCS) $(SRCDIR_SRCS) $(SRCDIR_CXXSRCS) $(INCLUDES) \ $(PIKE_INCLUDE) $(LIBS) -L$(PIKE_LIB) $(PIKE_LIBOPTS) -o $(TARGET) # ----------------------------------------------------------------- @@ -1253,9 +1253,9 @@ chicken_direct: $(SRCDIR_SRCS) $(CHICKEN) $(CHICKEN_GENERATED_SCHEME) $(CHICKENOPTS) \ -dynamic -feature chicken-compile-shared \ -output-file $(CHICKEN_COMPILED_SCHEME) - $(CC) -c $(CCSHARED) $(CFLAGS) $(CHICKEN_CFLAGS) \ + $(CC) -c $(CCSHARED) $(CPPFLAGS) $(CFLAGS) $(CHICKEN_CFLAGS) \ $(INCLUDES) $(CHICKEN_INCLUDE) $(ISRCS) $(SRCDIR_SRCS) $(CHICKEN_COMPILED_SCHEME) - $(LDSHARED) $(CFLAGS) $(CHICKEN_COMPILED_OBJECT) $(OBJS) $(IOBJS) \ + $(LDSHARED) $(CFLAGS) $(LDFLAGS) $(CHICKEN_COMPILED_OBJECT) $(OBJS) $(IOBJS) \ $(LIBS) $(CHICKEN_SHAREDLIBOPTS) -o $(LIBPREFIX)$(TARGET)$(SO) chicken_direct_cpp: $(SRCDIR_CXXSRCS) $(CHICKSRCS) @@ -1263,9 +1263,9 @@ chicken_direct_cpp: $(SRCDIR_CXXSRCS) $(CHICKSRCS) $(CHICKEN) $(CHICKEN_GENERATED_SCHEME) $(CHICKENOPTS) \ -dynamic -feature chicken-compile-shared \ -output-file $(CHICKEN_COMPILED_SCHEME) - $(CXX) -c $(CCSHARED) $(CXXFLAGS) $(CHICKEN_CFLAGS) \ + $(CXX) -c $(CCSHARED) $(CPPFLAGS) $(CXXFLAGS) $(CHICKEN_CFLAGS) \ $(INCLUDES) $(CHICKEN_INCLUDE) $(ICXXSRCS) $(SRCDIR_SRCS) $(SRCDIR_CXXSRCS) $(CHICKEN_COMPILED_SCHEME) - $(CXXSHARED) $(CXXFLAGS) $(CHICKEN_COMPILED_OBJECT) $(OBJS) $(IOBJS) \ + $(CXXSHARED) $(CXXFLAGS) $(LDFLAGS) $(CHICKEN_COMPILED_OBJECT) $(OBJS) $(IOBJS) \ $(LIBS) $(CPP_DLLIBS) $(CHICKEN_SHAREDLIBOPTS) -o $(LIBPREFIX)$(TARGET)$(SO) # ----------------------------------------------------------------- @@ -1279,10 +1279,10 @@ chicken_static: $(SRCDIR_SRCS) $(CHICKSRCS) -output-file $(CHICKEN_COMPILED_SCHEME) $(CHICKEN) $(CHICKEN_MAIN) $(CHICKENOPTS) \ -output-file $(CHICKEN_MAIN:.scm=_chicken.c) - $(CC) -c $(CCSHARED) $(CFLAGS) $(CHICKEN_CFLAGS) \ + $(CC) -c $(CCSHARED) $(CPPFLAGS) $(CFLAGS) $(CHICKEN_CFLAGS) \ $(INCLUDES) $(CHICKEN_INCLUDE) $(ISRCS) $(SRCDIR_SRCS) \ $(CHICKEN_COMPILED_SCHEME) $(CHICKEN_COMPILED_MAIN) - $(CC) $(CHICKEN_COMPILED_OBJECT) $(CHICKEN_COMPILED_MAIN_OBJECT) \ + $(CC) $(CFLAGS) $(LDFLAGS) $(CHICKEN_COMPILED_OBJECT) $(CHICKEN_COMPILED_MAIN_OBJECT) \ $(OBJS) $(IOBJS) $(LIBS) $(CHICKEN_SHAREDLIBOPTS) -o $(TARGET) chicken_static_cpp: $(SRCDIR_CXXSRCS) $(CHICKSRCS) @@ -1291,10 +1291,10 @@ chicken_static_cpp: $(SRCDIR_CXXSRCS) $(CHICKSRCS) -output-file $(CHICKEN_COMPILED_SCHEME) $(CHICKEN) $(CHICKEN_MAIN) $(CHICKENOPTS) \ -output-file $(CHICKEN_MAIN:.scm=_chicken.c) - $(CXX) -c $(CCSHARED) $(CXXFLAGS) $(CHICKEN_CFLAGS) \ + $(CXX) -c $(CCSHARED) $(CPPFLAGS) $(CXXFLAGS) $(CHICKEN_CFLAGS) \ $(INCLUDES) $(CHICKEN_INCLUDE) $(ICXXSRCS) $(SRCDIR_SRCS) $(SRCDIR_CXXSRCS) \ $(CHICKEN_COMPILED_SCHEME) $(CHICKEN_COMPILED_MAIN) - $(CXX) $(CHICKEN_COMPILED_OBJECT) $(CHICKEN_COMPILED_MAIN_OBJECT) \ + $(CXX) $(CXXFLAGS) $(LDFLAGS) $(CHICKEN_COMPILED_OBJECT) $(CHICKEN_COMPILED_MAIN_OBJECT) \ $(OBJS) $(IOBJS) $(LIBS) $(CPP_DLLIBS) $(CHICKEN_SHAREDLIBOPTS) -o $(TARGET) # ---------------------------------------------------------------- @@ -1355,8 +1355,8 @@ CSHARP_RUNME = $(CSHARPCILINTERPRETER) $(CSHARPCILINTERPRETER_FLAGS) ./$(RUNME). csharp: $(SRCDIR_SRCS) $(SWIG) -csharp $(SWIGOPT) -o $(ISRCS) $(INTERFACEPATH) - $(CC) -c $(CCSHARED) $(CFLAGS) $(CSHARPCFLAGS) $(SRCDIR_SRCS) $(ISRCS) $(INCLUDES) - $(LDSHARED) $(CFLAGS) $(OBJS) $(IOBJS) $(CSHARP_DLNK) $(LIBS) -o $(CSHARP_LIBPREFIX)$(TARGET)$(CSHARPSO) + $(CC) -c $(CCSHARED) $(CPPFLAGS) $(CFLAGS) $(CSHARPCFLAGS) $(SRCDIR_SRCS) $(ISRCS) $(INCLUDES) + $(LDSHARED) $(CFLAGS) $(LDFLAGS) $(OBJS) $(IOBJS) $(CSHARP_DLNK) $(LIBS) -o $(CSHARP_LIBPREFIX)$(TARGET)$(CSHARPSO) # ---------------------------------------------------------------- # Build a CSharp dynamically loadable module (C++) @@ -1364,8 +1364,8 @@ csharp: $(SRCDIR_SRCS) csharp_cpp: $(SRCDIR_SRCS) $(SWIG) -csharp -c++ $(SWIGOPT) -o $(ICXXSRCS) $(INTERFACEPATH) - $(CXX) -c $(CCSHARED) $(CXXFLAGS) $(CSHARPCFLAGS) $(SRCDIR_SRCS) $(SRCDIR_CXXSRCS) $(ICXXSRCS) $(INCLUDES) - $(CXXSHARED) $(CXXFLAGS) $(OBJS) $(IOBJS) $(CSHARP_DLNK) $(LIBS) $(CPP_DLLIBS) -o $(CSHARP_LIBPREFIX)$(TARGET)$(CSHARPSO) + $(CXX) -c $(CCSHARED) $(CPPFLAGS) $(CXXFLAGS) $(CSHARPCFLAGS) $(SRCDIR_SRCS) $(SRCDIR_CXXSRCS) $(ICXXSRCS) $(INCLUDES) + $(CXXSHARED) $(CXXFLAGS) $(LDFLAGS) $(OBJS) $(IOBJS) $(CSHARP_DLNK) $(LIBS) $(CPP_DLLIBS) -o $(CSHARP_LIBPREFIX)$(TARGET)$(CSHARPSO) # ---------------------------------------------------------------- # Compile CSharp files @@ -1428,8 +1428,8 @@ LUA_INTERP = ../lua.c lua: $(SRCDIR_SRCS) $(SWIG) -lua $(SWIGOPT) -o $(ISRCS) $(INTERFACEPATH) - $(CC) -c $(CCSHARED) $(CFLAGS) $(ISRCS) $(SRCDIR_SRCS) $(INCLUDES) $(LUA_INCLUDE) - $(LDSHARED) $(CFLAGS) $(OBJS) $(IOBJS) $(LIBS) $(LUA_LIB) -o $(LIBPREFIX)$(TARGET)$(LUA_SO) + $(CC) -c $(CCSHARED) $(CPPFLAGS) $(CFLAGS) $(ISRCS) $(SRCDIR_SRCS) $(INCLUDES) $(LUA_INCLUDE) + $(LDSHARED) $(CFLAGS) $(LDFLAGS) $(OBJS) $(IOBJS) $(LIBS) $(LUA_LIB) -o $(LIBPREFIX)$(TARGET)$(LUA_SO) # ----------------------------------------------------------------- # Build a C++ dynamically loadable module @@ -1437,8 +1437,8 @@ lua: $(SRCDIR_SRCS) lua_cpp: $(SRCDIR_SRCS) $(GENCXXSRCS) $(SWIG) -c++ -lua $(SWIGOPT) -o $(ICXXSRCS) $(INTERFACEPATH) - $(CXX) -c $(CCSHARED) $(CXXFLAGS) $(ICXXSRCS) $(SRCDIR_SRCS) $(SRCDIR_CXXSRCS) $(GENCXXSRCS) $(INCLUDES) $(LUA_INCLUDE) - $(CXXSHARED) $(CXXFLAGS) $(OBJS) $(IOBJS) $(LIBS) $(LUA_LIB) $(CPP_DLLIBS) -o $(LIBPREFIX)$(TARGET)$(LUA_SO) + $(CXX) -c $(CCSHARED) $(CPPFLAGS) $(CXXFLAGS) $(ICXXSRCS) $(SRCDIR_SRCS) $(SRCDIR_CXXSRCS) $(GENCXXSRCS) $(INCLUDES) $(LUA_INCLUDE) + $(CXXSHARED) $(CXXFLAGS) $(LDFLAGS) $(OBJS) $(IOBJS) $(LIBS) $(LUA_LIB) $(CPP_DLLIBS) -o $(LIBPREFIX)$(TARGET)$(LUA_SO) # ----------------------------------------------------------------- # Build statically linked Lua interpreter @@ -1446,12 +1446,12 @@ lua_cpp: $(SRCDIR_SRCS) $(GENCXXSRCS) lua_static: $(SRCDIR_SRCS) $(SWIG) -lua -module example $(SWIGOPT) -o $(ISRCS) $(INTERFACEPATH) - $(CC) $(CFLAGS) $(ISRCS) $(SRCDIR_SRCS) $(SRCDIR)$(LUA_INTERP) $(INCLUDES) \ + $(CC) $(CPPFLAGS) $(CFLAGS) $(LDFLAGS) $(ISRCS) $(SRCDIR_SRCS) $(SRCDIR)$(LUA_INTERP) $(INCLUDES) \ $(LUA_INCLUDE) $(LIBS) $(LUA_LIB) -o $(TARGET) lua_static_cpp: $(SRCDIR_SRCS) $(GENCXXSRCS) $(SWIG) -c++ -lua -module example $(SWIGOPT) -o $(ICXXSRCS) $(INTERFACEPATH) - $(CXX) $(CXXFLAGS) $(ICXXSRCS) $(SRCDIR_SRCS) $(SRCDIR_CXXSRCS) $(GENCXXSRCS) $(SRCDIR)$(LUA_INTERP) $(INCLUDES) \ + $(CXX) $(CPPFLAGS) $(CXXFLAGS) $(LDFLAGS) $(ICXXSRCS) $(SRCDIR_SRCS) $(SRCDIR_CXXSRCS) $(GENCXXSRCS) $(SRCDIR)$(LUA_INTERP) $(INCLUDES) \ $(LUA_INCLUDE) $(LIBS) $(LUA_LIB) -o $(TARGET) # ----------------------------------------------------------------- @@ -1489,13 +1489,13 @@ ALLEGROCL_SCRIPT=$(RUNME).lisp allegrocl: $(SRCDIR_SRCS) $(SWIG) -allegrocl -cwrap $(SWIGOPT) -o $(ISRCS) $(INTERFACEPATH) - $(CC) -c $(CCSHARED) $(CFLAGS) $(ISRCS) $(INCLUDES) $(SRCDIR_SRCS) - $(LDSHARED) $(CFLAGS) $(OBJS) $(IOBJS) $(LIBS) -o $(LIBPREFIX)$(TARGET)$(SO) + $(CC) -c $(CCSHARED) $(CPPFLAGS) $(CFLAGS) $(ISRCS) $(INCLUDES) $(SRCDIR_SRCS) + $(LDSHARED) $(CFLAGS) $(LDFLAGS) $(OBJS) $(IOBJS) $(LIBS) -o $(LIBPREFIX)$(TARGET)$(SO) allegrocl_cpp: $(SRCDIR_SRCS) $(SWIG) -c++ -allegrocl $(SWIGOPT) -o $(ICXXSRCS) $(INTERFACEPATH) - $(CXX) -c $(CCSHARED) $(CXXFLAGS) $(ICXXSRCS) $(SRCDIR_SRCS) $(SRCDIR_CXXSRCS) $(INCLUDES) - $(CXXSHARED) $(CXXFLAGS) $(OBJS) $(IOBJS) $(LIBS) $(CPP_DLLIBS) -o $(LIBPREFIX)$(TARGET)$(SO) + $(CXX) -c $(CCSHARED) $(CPPFLAGS) $(CXXFLAGS) $(ICXXSRCS) $(SRCDIR_SRCS) $(SRCDIR_CXXSRCS) $(INCLUDES) + $(CXXSHARED) $(CXXFLAGS) $(LDFLAGS) $(OBJS) $(IOBJS) $(LIBS) $(CPP_DLLIBS) -o $(LIBPREFIX)$(TARGET)$(SO) # ----------------------------------------------------------------- # Run ALLEGRO CL example @@ -1565,13 +1565,13 @@ CFFI_SCRIPT=$(RUNME).lisp cffi: $(SRCDIR_SRCS) $(SWIG) -cffi $(SWIGOPT) -o $(ISRCS) $(INTERFACEPATH) -# $(CC) -c $(CCSHARED) $(CFLAGS) $(ISRCS) $(INCLUDES) $(SRCDIR_SRCS) -# $(LDSHARED) $(CFLAGS) $(OBJS) $(IOBJS) $(LIBS) -o $(LIBPREFIX)$(TARGET)$(SO) +# $(CC) -c $(CCSHARED) $(CPPFLAGS) $(CFLAGS) $(ISRCS) $(INCLUDES) $(SRCDIR_SRCS) +# $(LDSHARED) $(CFLAGS) $(LDFLAGS) $(OBJS) $(IOBJS) $(LIBS) -o $(LIBPREFIX)$(TARGET)$(SO) cffi_cpp: $(SRCDIR_SRCS) $(SWIG) -c++ -cffi $(SWIGOPT) -o $(ICXXSRCS) $(INTERFACEPATH) - $(CXX) -c $(CCSHARED) $(CXXFLAGS) $(ICXXSRCS) $(SRCDIR_SRCS) $(SRCDIR_CXXSRCS) $(INCLUDES) - $(CXXSHARED) $(CXXFLAGS) $(OBJS) $(IOBJS) $(LIBS) $(CPP_DLLIBS) -o $(LIBPREFIX)$(TARGET)$(SO) + $(CXX) -c $(CCSHARED) $(CPPFLAGS) $(CXXFLAGS) $(ICXXSRCS) $(SRCDIR_SRCS) $(SRCDIR_CXXSRCS) $(INCLUDES) + $(CXXSHARED) $(CXXFLAGS) $(LDFLAGS) $(OBJS) $(IOBJS) $(LIBS) $(CPP_DLLIBS) -o $(LIBPREFIX)$(TARGET)$(SO) # ----------------------------------------------------------------- # Run CFFI example @@ -1605,13 +1605,13 @@ UFFI_SCRIPT=$(RUNME).lisp uffi: $(SRCDIR_SRCS) $(SWIG) -uffi $(SWIGOPT) -o $(ISRCS) $(INTERFACEPATH) -# $(CC) -c $(CCSHARED) $(CFLAGS) $(ISRCS) $(INCLUDES) $(SRCDIR_SRCS) -# $(LDSHARED) $(CFLAGS) $(OBJS) $(IOBJS) $(LIBS) -o $(LIBPREFIX)$(TARGET)$(SO) +# $(CC) -c $(CCSHARED) $(CPPFLAGS) $(CFLAGS) $(ISRCS) $(INCLUDES) $(SRCDIR_SRCS) +# $(LDSHARED) $(CFLAGS) $(LDFLAGS) $(OBJS) $(IOBJS) $(LIBS) -o $(LIBPREFIX)$(TARGET)$(SO) uffi_cpp: $(SRCDIR_SRCS) $(SWIG) -c++ -uffi $(SWIGOPT) -o $(ICXXSRCS) $(INTERFACEPATH) -# $(CXX) -c $(CCSHARED) $(CXXFLAGS) $(ICXXSRCS) $(SRCDIR_SRCS) $(SRCDIR_CXXSRCS) $(INCLUDES) -# $(CXXSHARED) $(CXXFLAGS) $(OBJS) $(IOBJS) $(LIBS) $(CPP_DLLIBS) -o $(LIBPREFIX)$(TARGET)$(SO) +# $(CXX) -c $(CCSHARED) $(CPPFLAGS) $(CXXFLAGS) $(ICXXSRCS) $(SRCDIR_SRCS) $(SRCDIR_CXXSRCS) $(INCLUDES) +# $(CXXSHARED) $(CXXFLAGS) $(LDFLAGS) $(OBJS) $(IOBJS) $(LIBS) $(CPP_DLLIBS) -o $(LIBPREFIX)$(TARGET)$(SO) # ----------------------------------------------------------------- # Run UFFI example @@ -1657,7 +1657,7 @@ R_SCRIPT=$(RUNME).R r: $(SRCDIR_SRCS) $(SWIG) -r $(SWIGOPT) -o $(ISRCS) $(INTERFACEPATH) ifneq ($(SRCDIR_SRCS),) - $(CC) -g -c $(CFLAGS) $(R_CFLAGS) $(SRCDIR_SRCS) $(INCLUDES) + $(CC) -g -c $(CPPFLAGS) $(CFLAGS) $(R_CFLAGS) $(SRCDIR_SRCS) $(INCLUDES) endif +( PKG_CPPFLAGS="$(INCLUDES)" $(COMPILETOOL) $(R) CMD SHLIB -o $(LIBPREFIX)$(TARGET)$(SO) $(ISRCS) $(OBJS) > /dev/null ) @@ -1668,7 +1668,7 @@ endif r_cpp: $(SRCDIR_CXXSRCS) $(SWIG) -c++ -r $(SWIGOPT) -o $(RCXXSRCS) $(INTERFACEPATH) ifneq ($(SRCDIR_CXXSRCS),) - $(CXX) -g -c $(CXXFLAGS) $(R_CFLAGS) $(SRCDIR_CXXSRCS) $(INCLUDES) + $(CXX) -g -c $(CPPFLAGS) $(CXXFLAGS) $(R_CFLAGS) $(SRCDIR_CXXSRCS) $(INCLUDES) endif +( PKG_CPPFLAGS="$(INCLUDES)" $(COMPILETOOL) $(R) CMD SHLIB -o $(LIBPREFIX)$(TARGET)$(SO) $(RCXXSRCS) $(OBJS) > /dev/null ) @@ -1732,10 +1732,10 @@ GOGCCOBJS = $(GOSRCS:.go=.@OBJEXT@) go: $(SRCDIR_SRCS) $(SWIG) -go $(GOOPT) $(GOSWIGARG) $(SWIGOPT) -o $(ISRCS) $(INTERFACEPATH) if $(GO12) || $(GO13) || $(GOGCC); then \ - $(CC) -g -c $(CFLAGS) $(SRCDIR_SRCS) $(ISRCS) $(INCLUDES); \ + $(CC) -g -c $(CPPFLAGS) $(CFLAGS) $(SRCDIR_SRCS) $(ISRCS) $(INCLUDES); \ else \ - $(CC) -g -c $(CCSHARED) $(CFLAGS) $(SRCDIR_SRCS) $(ISRCS) $(INCLUDES); \ - $(LDSHARED) $(CFLAGS) $(OBJS) $(IOBJS) $(LIBS) -o $(LIBPREFIX)$(TARGET)$(SO); \ + $(CC) -g -c $(CCSHARED) $(CPPFLAGS) $(CFLAGS) $(SRCDIR_SRCS) $(ISRCS) $(INCLUDES); \ + $(LDSHARED) $(CFLAGS) $(LDFLAGS) $(OBJS) $(IOBJS) $(LIBS) -o $(LIBPREFIX)$(TARGET)$(SO); \ fi $(COMPILETOOL) $(GO) $(GOCOMPILEARG) -I . $(GOSRCS) if ! $(GOGCC) ; then \ @@ -1755,7 +1755,7 @@ go: $(SRCDIR_SRCS) if $(GOGCC) ; then \ $(COMPILETOOL) $(GO) -o $(RUNME) $(RUNME).@OBJEXT@ $(GOGCCOBJS) $(OBJS) $(IOBJS); \ elif $(GO12) || $(GO13); then \ - $(COMPILETOOL) $(GOTOOL) $(GOLD) -linkmode external -extld "$(CC)" -extldflags "$(CFLAGS)" -o $(RUNME) $(RUNME).$(GOOBJEXT); \ + $(COMPILETOOL) $(GOTOOL) $(GOLD) -linkmode external -extld "$(CC)" -extldflags "$(CFLAGS) $(LDFLAGS)" -o $(RUNME) $(RUNME).$(GOOBJEXT); \ else \ $(COMPILETOOL) $(GOTOOL) $(GOLD) -r $${GOROOT:-`go env GOROOT`}/pkg/$${GOOS:-`go env GOOS`}_$${GOARCH:-`go env GOARCH`}:. -o $(RUNME) $(RUNME).$(GOOBJEXT); \ fi; \ @@ -1768,10 +1768,10 @@ go: $(SRCDIR_SRCS) go_cpp: $(SRCDIR_SRCS) $(SWIG) -go -c++ $(GOOPT) $(GOSWIGARG) $(SWIGOPT) -o $(ICXXSRCS) $(INTERFACEPATH) if $(GO12) || $(GO13) || $(GOGCC); then \ - $(CXX) -g -c $(CXXFLAGS) $(SRCDIR_SRCS) $(SRCDIR_CXXSRCS) $(ICXXSRCS) $(INCLUDES); \ + $(CXX) -g -c $(CPPFLAGS) $(CXXFLAGS) $(SRCDIR_SRCS) $(SRCDIR_CXXSRCS) $(ICXXSRCS) $(INCLUDES); \ else \ - $(CXX) -g -c $(CCSHARED) $(CXXFLAGS) $(SRCDIR_SRCS) $(SRCDIR_CXXSRCS) $(ICXXSRCS) $(INCLUDES); \ - $(CXXSHARED) $(CXXFLAGS) $(OBJS) $(IOBJS) $(LIBS) $(CPP_DLLIBS) -o $(LIBPREFIX)$(TARGET)$(SO); \ + $(CXX) -g -c $(CCSHARED) $(CPPFLAGS) $(CXXFLAGS) $(SRCDIR_SRCS) $(SRCDIR_CXXSRCS) $(ICXXSRCS) $(INCLUDES); \ + $(CXXSHARED) $(CXXFLAGS) $(LDFLAGS) $(OBJS) $(IOBJS) $(LIBS) $(CPP_DLLIBS) -o $(LIBPREFIX)$(TARGET)$(SO); \ fi $(COMPILETOOL) $(GO) $(GOCOMPILEARG) -I . $(GOSRCS) if ! $(GOGCC) ; then \ @@ -1791,7 +1791,7 @@ go_cpp: $(SRCDIR_SRCS) if $(GOGCC) ; then \ $(COMPILETOOL) $(GO) -o $(RUNME) $(RUNME).@OBJEXT@ $(GOGCCOBJS) $(OBJS) $(IOBJS) -lstdc++; \ elif $(GO12) || $(GO13); then \ - $(COMPILETOOL) $(GOTOOL) $(GOLD) -linkmode external -extld "$(CXX)" -extldflags "$(CXXFLAGS)" -o $(RUNME) $(RUNME).$(GOOBJEXT); \ + $(COMPILETOOL) $(GOTOOL) $(GOLD) -linkmode external -extld "$(CXX)" -extldflags "$(CXXFLAGS) $(LDFLAGS)" -o $(RUNME) $(RUNME).$(GOOBJEXT); \ else \ $(COMPILETOOL) $(GOTOOL) $(GOLD) -r $${GOROOT:-`go env GOROOT`}/pkg/$${GOOS:-`go env GOOS`}_$${GOARCH:-`go env GOARCH`}:. -o $(RUNME) $(RUNME).$(GOOBJEXT); \ fi; \ @@ -1846,8 +1846,8 @@ D_RUNME = ./$(RUNME) d: $(SRCDIR_SRCS) $(SWIGD) $(SWIGOPT) -o $(ISRCS) $(INTERFACEPATH) - $(CC) -c $(CCSHARED) $(CFLAGS) $(DCFLAGS) $(EXTRA_CFLAGS) $(SRCDIR_SRCS) $(ISRCS) $(INCLUDES) - $(LDSHARED) $(CFLAGS) $(DCFLAGS) $(EXTRA_LDFLAGS) $(OBJS) $(IOBJS) $(LIBS) -o $(DLIBPREFIX)$(TARGET)$(SO) + $(CC) -c $(CCSHARED) $(CPPFLAGS) $(CFLAGS) $(DCFLAGS) $(EXTRA_CFLAGS) $(SRCDIR_SRCS) $(ISRCS) $(INCLUDES) + $(LDSHARED) $(CFLAGS) $(LDFLAGS) $(DCFLAGS) $(EXTRA_LDFLAGS) $(OBJS) $(IOBJS) $(LIBS) -o $(DLIBPREFIX)$(TARGET)$(SO) # ---------------------------------------------------------------- # Build a dynamically loadable D wrapper for a C++ module @@ -1855,8 +1855,8 @@ d: $(SRCDIR_SRCS) d_cpp: $(SRCDIR_SRCS) $(SWIGD) -c++ $(SWIGOPT) -o $(ICXXSRCS) $(INTERFACEPATH) - $(CXX) -c $(CCSHARED) $(CXXFLAGS) $(DCFLAGS) $(EXTRA_CFLAGS) $(SRCDIR_SRCS) $(SRCDIR_CXXSRCS) $(ICXXSRCS) $(INCLUDES) - $(CXXSHARED) $(CXXFLAGS) $(DCFLAGS) $(EXTRA_LDFLAGS) $(OBJS) $(IOBJS) $(LIBS) $(CPP_DLLIBS) -o $(DLIBPREFIX)$(TARGET)$(SO) + $(CXX) -c $(CCSHARED) $(CPPFLAGS) $(CXXFLAGS) $(DCFLAGS) $(EXTRA_CFLAGS) $(SRCDIR_SRCS) $(SRCDIR_CXXSRCS) $(ICXXSRCS) $(INCLUDES) + $(CXXSHARED) $(CXXFLAGS) $(LDFLAGS) $(DCFLAGS) $(EXTRA_LDFLAGS) $(OBJS) $(IOBJS) $(LIBS) $(CPP_DLLIBS) -o $(DLIBPREFIX)$(TARGET)$(SO) # ---------------------------------------------------------------- # Compile D files diff --git a/Examples/chicken/class/Makefile b/Examples/chicken/class/Makefile index 5fafa5c15..a37ea4a85 100644 --- a/Examples/chicken/class/Makefile +++ b/Examples/chicken/class/Makefile @@ -6,7 +6,6 @@ CXXSRCS = example.cxx TARGET = class INCLUDE = SWIGOPT = -CFLAGS = VARIANT = # uncomment the following lines to build a static exe (only pick one of the CHICKEN_MAIN lines) diff --git a/Examples/chicken/constants/Makefile b/Examples/chicken/constants/Makefile index a6100f757..7167e866b 100644 --- a/Examples/chicken/constants/Makefile +++ b/Examples/chicken/constants/Makefile @@ -6,7 +6,6 @@ CXXSRCS = TARGET = constants INCLUDE = SWIGOPT = -CFLAGS = VARIANT = # uncomment the following two lines to build a static exe diff --git a/Examples/chicken/multimap/Makefile b/Examples/chicken/multimap/Makefile index 79282be17..e8192e9cd 100644 --- a/Examples/chicken/multimap/Makefile +++ b/Examples/chicken/multimap/Makefile @@ -6,7 +6,6 @@ CXXSRCS = TARGET = multimap INCLUDE = SWIGOPT = -CFLAGS = VARIANT = # uncomment the following two lines to build a static exe diff --git a/Examples/chicken/overload/Makefile b/Examples/chicken/overload/Makefile index 717abd335..a9647d93e 100644 --- a/Examples/chicken/overload/Makefile +++ b/Examples/chicken/overload/Makefile @@ -6,7 +6,6 @@ CXXSRCS = example.cxx TARGET = overload INCLUDE = SWIGOPT = -proxy -unhideprimitive -CFLAGS = VARIANT = # uncomment the following lines to build a static exe diff --git a/Examples/chicken/simple/Makefile b/Examples/chicken/simple/Makefile index 9d1f34fa0..c07075efa 100644 --- a/Examples/chicken/simple/Makefile +++ b/Examples/chicken/simple/Makefile @@ -6,7 +6,6 @@ CXXSRCS = TARGET = simple INCLUDE = SWIGOPT = -CFLAGS = VARIANT = # uncomment the following two lines to build a static exe diff --git a/Tools/javascript/Makefile.in b/Tools/javascript/Makefile.in index d5c4711a0..960c661b2 100644 --- a/Tools/javascript/Makefile.in +++ b/Tools/javascript/Makefile.in @@ -16,9 +16,11 @@ all: javascript CC = @CC@ # HACK: under OSX a g++ compiled interpreter is seg-faulting when loading module libraries # with 'c++' it works... probably some missing flags? -JSCXX = @JSINTERPRETERCXX@ +JSCXX = @JSINTERPRETERCXX@ +CPPFLAGS = @BOOST_CPPFLAGS@ CFLAGS = @PLATCFLAGS@ -CXXFLAGS = @BOOST_CPPFLAGS@ @PLATCXXFLAGS@ +CXXFLAGS = @PLATCXXFLAGS@ +LDFLAGS = LINKFLAGS = @JSINTERPRETERLINKFLAGS@ ROOT_DIR = @ROOT_DIR@ @@ -54,10 +56,10 @@ JS_INTERPRETER_SRC = javascript.cxx js_shell.cxx $(JS_INTERPRETER_SRC_JSC) $(JS_ JS_INTERPRETER_OBJS = $(JS_INTERPRETER_SRC:.cxx=.o) %.o: $(srcdir)/%.cxx - $(JSCXX) $(JS_INTERPRETER_DEFINES) $(CXXFLAGS) $(JSINCLUDES) -o $@ -c $< + $(JSCXX) $(JS_INTERPRETER_DEFINES) $(CPPFLAGS) $(CXXFLAGS) $(JSINCLUDES) -o $@ -c $< javascript: $(JS_INTERPRETER_OBJS) - $(JSCXX) $^ $(CXXFLAGS) -o javascript $(JSDYNAMICLINKING) $(LINKFLAGS) + $(JSCXX) $^ $(CXXFLAGS) $(LDFLAGS) -o javascript $(JSDYNAMICLINKING) $(LINKFLAGS) clean: rm -f *.o -- cgit v1.2.1 From ce5f49463e98fe2825e87f1b1f76e6602f32f4f0 Mon Sep 17 00:00:00 2001 From: William S Fulton Date: Thu, 15 May 2014 20:50:05 +0100 Subject: Remove duplicate test target in CCache Makefile --- CCache/Makefile.in | 2 -- 1 file changed, 2 deletions(-) diff --git a/CCache/Makefile.in b/CCache/Makefile.in index ae77ae745..6703e2ac0 100644 --- a/CCache/Makefile.in +++ b/CCache/Makefile.in @@ -59,8 +59,6 @@ uninstall: $(PACKAGE_NAME)$(EXEEXT) $(PACKAGE_NAME).1 clean: /bin/rm -f $(OBJS) *~ $(PACKAGE_NAME)$(EXEEXT) -check : test - test: test.sh SWIG_LIB='$(SWIG_LIB)' PATH=../..:$$PATH SWIG='$(SWIG)' CC='$(CC)' NOSOFTLINKSTEST='$(NOSOFTLINKSTEST)' $(srcdir)/test.sh -- cgit v1.2.1 From 8ece62b9457a6b61de544c6885772d3bc8150299 Mon Sep 17 00:00:00 2001 From: William S Fulton Date: Thu, 15 May 2014 22:04:54 +0100 Subject: Neaten up test-suite Makefile regeneration --- Examples/test-suite/common.mk | 5 +---- Examples/test-suite/errors/Makefile.in | 7 ++----- 2 files changed, 3 insertions(+), 9 deletions(-) diff --git a/Examples/test-suite/common.mk b/Examples/test-suite/common.mk index d93d788c9..ef697b131 100644 --- a/Examples/test-suite/common.mk +++ b/Examples/test-suite/common.mk @@ -74,11 +74,8 @@ SRCDIR = $(srcdir)/ SCRIPTDIR = $(srcdir) # Regenerate Makefile if Makefile.in or config.status have changed. -ifeq (,$(TEST_SUITE_SUBDIR)) -TEST_SUITE_SUBDIR = $(LANGUAGE) -endif Makefile: $(srcdir)/Makefile.in ../../../config.status - cd ../../../ && $(SHELL) ./config.status $(EXAMPLES)/$(TEST_SUITE)/$(TEST_SUITE_SUBDIR)/Makefile + cd ../../../ && $(SHELL) ./config.status $(EXAMPLES)/$(TEST_SUITE)/$(LANGUAGE)/Makefile # # Please keep test cases in alphabetical order. diff --git a/Examples/test-suite/errors/Makefile.in b/Examples/test-suite/errors/Makefile.in index 9ca6f6ecd..da67db8bd 100644 --- a/Examples/test-suite/errors/Makefile.in +++ b/Examples/test-suite/errors/Makefile.in @@ -13,7 +13,7 @@ # file (.stderr) in addition to the test case itself. ####################################################################### -LANGUAGE = python +LANGUAGE = errors ERROR_EXT = newerr # Portable dos2unix / todos for stripping CR TODOS = tr -d '\r' @@ -35,9 +35,6 @@ C_ERROR_TEST_CASES := $(filter-out $(CPP_ERROR_TEST_CASES), $(ALL_ERROR_TEST_CAS ERROR_TEST_CASES := $(CPP_ERROR_TEST_CASES:=.cpptest) \ $(C_ERROR_TEST_CASES:=.ctest) -# For rebuilding Makefile from Makefile.in in common.mk -TEST_SUITE_SUBDIR = errors - include $(srcdir)/../common.mk @@ -56,5 +53,5 @@ include $(srcdir)/../common.mk @exit 0 clean: - $(MAKE) -f $(top_builddir)/$(EXAMPLES)/Makefile $(LANGUAGE)_clean + $(MAKE) -f $(top_builddir)/$(EXAMPLES)/Makefile python_clean @rm -f *.$(ERROR_EXT) *.py -- cgit v1.2.1 From 61818533129e7d88124e00c69b81088f060b4b39 Mon Sep 17 00:00:00 2001 From: William S Fulton Date: Wed, 14 May 2014 00:36:38 +0100 Subject: Fix out of source clean-android-examples --- Examples/Makefile.in | 2 +- Examples/android/class/Makefile | 2 +- Examples/android/extend/Makefile | 2 +- Examples/android/simple/Makefile | 2 +- 4 files changed, 4 insertions(+), 4 deletions(-) diff --git a/Examples/Makefile.in b/Examples/Makefile.in index 7c2d23647..c47c075e9 100644 --- a/Examples/Makefile.in +++ b/Examples/Makefile.in @@ -782,7 +782,7 @@ android_version: # ----------------------------------------------------------------- android_clean: - ant -q -logfile /dev/null clean + cd $(SRCDIR) && ant -q -logfile /dev/null clean rm -f $(INTERFACEDIR)$(TARGET)_wrap.* rm -f `find $(PACKAGEDIR) -name \*.java | grep -v $(PROJECTNAME).java` rm -rf obj diff --git a/Examples/android/class/Makefile b/Examples/android/class/Makefile index 44d33de0a..574566623 100644 --- a/Examples/android/class/Makefile +++ b/Examples/android/class/Makefile @@ -3,7 +3,7 @@ SWIG = $(TOP)/../preinst-swig TARGET = example INTERFACE = example.i INTERFACEDIR = jni/ -PACKAGEDIR = src/org/swig +PACKAGEDIR = $(SRCDIR)src/org/swig PACKAGENAME= org.swig.classexample SWIGOPT = -package $(PACKAGENAME) -outdir $(PACKAGEDIR)/classexample PROJECTNAME= SwigClass diff --git a/Examples/android/extend/Makefile b/Examples/android/extend/Makefile index 3d0609a08..fb974d22c 100644 --- a/Examples/android/extend/Makefile +++ b/Examples/android/extend/Makefile @@ -3,7 +3,7 @@ SWIG = $(TOP)/../preinst-swig TARGET = example INTERFACE = example.i INTERFACEDIR = jni/ -PACKAGEDIR = src/org/swig +PACKAGEDIR = $(SRCDIR)src/org/swig PACKAGENAME= org.swig.extendexample SWIGOPT = -package $(PACKAGENAME) -outdir $(PACKAGEDIR)/extendexample PROJECTNAME= SwigExtend diff --git a/Examples/android/simple/Makefile b/Examples/android/simple/Makefile index d71b9880c..2bf41968a 100644 --- a/Examples/android/simple/Makefile +++ b/Examples/android/simple/Makefile @@ -3,7 +3,7 @@ SWIG = $(TOP)/../preinst-swig TARGET = example INTERFACE = example.i INTERFACEDIR = jni/ -PACKAGEDIR = src/org/swig +PACKAGEDIR = $(SRCDIR)src/org/swig PACKAGENAME= org.swig.simple SWIGOPT = -package $(PACKAGENAME) -outdir $(PACKAGEDIR)/simple PROJECTNAME= SwigSimple -- cgit v1.2.1 From 81335c5a91f134c3bbd32ecf7c7fa299f356b4f2 Mon Sep 17 00:00:00 2001 From: William S Fulton Date: Thu, 15 May 2014 23:27:26 +0100 Subject: Configured languages display improvement --- configure.ac | 53 ++++++++++++++++++++++++----------------------------- 1 file changed, 24 insertions(+), 29 deletions(-) diff --git a/configure.ac b/configure.ac index 949986341..e2cbe9fca 100644 --- a/configure.ac +++ b/configure.ac @@ -2715,38 +2715,33 @@ EOF AC_OUTPUT langs="" -test -n "$SKIP_ALLEGROCL" || langs="$langs allegrocl" -test -n "$SKIP_CFFI" || langs="$langs cffi" -test -n "$SKIP_CHICKEN" || langs="$langs chicken" -test -n "$SKIP_CLISP" || langs="$langs clisp" -test -n "$SKIP_CSHARP" || langs="$langs csharp" -test -n "$SKIP_D" || langs="$langs d" -test -n "$SKIP_GO" || langs="$langs go" -test -n "$SKIP_GUILE" || langs="$langs guile" -test -n "$SKIP_JAVA" || langs="$langs java" -test -n "$SKIP_JAVASCRIPT" || langs="$langs javascript" -test -n "$SKIP_LUA" || langs="$langs lua" -test -n "$SKIP_MODULA3" || langs="$langs modula3" -test -n "$SKIP_MZSCHEME" || langs="$langs mzscheme" -test -n "$SKIP_OCAML" || langs="$langs ocaml" -test -n "$SKIP_OCTAVE" || langs="$langs octave" -test -n "$SKIP_PERL5" || langs="$langs perl5" -test -n "$SKIP_PHP" || langs="$langs php" -test -n "$SKIP_PIKE" || langs="$langs pike" -test -n "$SKIP_PYTHON" || langs="$langs python" -test -n "$SKIP_R" || langs="$langs r" -test -n "$SKIP_RUBY" || langs="$langs ruby" -test -n "$SKIP_TCL" || langs="$langs tcl" -test -n "$SKIP_UFFI" || langs="$langs uffi" +test -n "$SKIP_ALLEGROCL" || langs="${langs}allegrocl " +test -n "$SKIP_CFFI" || langs="${langs}cffi " +test -n "$SKIP_CHICKEN" || langs="${langs}chicken " +test -n "$SKIP_CLISP" || langs="${langs}clisp " +test -n "$SKIP_CSHARP" || langs="${langs}csharp " +test -n "$SKIP_D" || langs="${langs}d " +test -n "$SKIP_GO" || langs="${langs}go " +test -n "$SKIP_GUILE" || langs="${langs}guile " +test -n "$SKIP_JAVA" || langs="${langs}java " +test -n "$SKIP_JAVASCRIPT" || langs="${langs}javascript " +test -n "$SKIP_LUA" || langs="${langs}lua " +test -n "$SKIP_MODULA3" || langs="${langs}modula3 " +test -n "$SKIP_MZSCHEME" || langs="${langs}mzscheme " +test -n "$SKIP_OCAML" || langs="${langs}ocaml " +test -n "$SKIP_OCTAVE" || langs="${langs}octave " +test -n "$SKIP_PERL5" || langs="${langs}perl5 " +test -n "$SKIP_PHP" || langs="${langs}php " +test -n "$SKIP_PIKE" || langs="${langs}pike " +test -n "$SKIP_PYTHON" || langs="${langs}python " +test -n "$SKIP_R" || langs="${langs}r " +test -n "$SKIP_RUBY" || langs="${langs}ruby " +test -n "$SKIP_TCL" || langs="${langs}tcl " +test -n "$SKIP_UFFI" || langs="${langs}uffi " echo " -======================================================== - -SWIG is configured for use with the following languages: - +The SWIG test-suite and examples are configured for the following languages: $langs - -======================================================== " dnl configure.ac ends here -- cgit v1.2.1 From 2e0f6a21639f3a658126d49eb0e998a3f7b81a14 Mon Sep 17 00:00:00 2001 From: William S Fulton Date: Thu, 15 May 2014 23:55:36 +0100 Subject: Travis testing - add folding to less interesting commands See https://github.com/travis-ci/travis-ci/issues/2285 for fold syntax info. --- .travis.yml | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/.travis.yml b/.travis.yml index 26cb18910..95e433952 100644 --- a/.travis.yml +++ b/.travis.yml @@ -68,16 +68,22 @@ before_install: - if test "$SWIGLANG" = "python" -a "$VER"; then sudo add-apt-repository -y ppa:fkrull/deadsnakes && sudo apt-get -qq update && sudo apt-get -qq install python${VER}-dev && export CONFIGOPTS="--with-python${PY3}=python${VER}"; fi - if test "$SWIGLANG" = "tcl"; then sudo apt-get -qq install tcl8.4-dev; fi script: + - echo 'Configuring...' && echo -en 'travis_fold:start:script.1\\r' - ./autogen.sh && ./configure $CONFIGOPTS + - echo -en 'travis_fold:end:script.1\\r' - make -s $SWIGJOBS - ./swig -version && ./swig -pcreversion - if test -z "$SWIGLANG"; then make -s $SWIGJOBS check-ccache; fi - if test -z "$SWIGLANG"; then make -s $SWIGJOBS check-errors-test-suite; fi + - echo 'Installing...' && echo -en 'travis_fold:start:script.1\\r' - if test -z "$SWIGLANG"; then sudo make -s install && swig -version && ccache-swig -V; fi + - echo -en 'travis_fold:end:script.2\\r' - if test -n "$SWIGLANG"; then make -s check-$SWIGLANG-version; fi - if test -n "$SWIGLANG"; then make -k $SWIGJOBS check-$SWIGLANG-examples; fi - if test -n "$SWIGLANG"; then make -k $SWIGJOBS check-$SWIGLANG-test-suite; fi + - echo -n 'Cleaning...' && echo -en 'travis_fold:start:script.3\\r' - make maintainer-clean + - echo -en 'travis_fold:end:script.3\\r' branches: only: - master -- cgit v1.2.1 From 3b0a549d72fc47616c62d28abeb9d3aafab0fbc0 Mon Sep 17 00:00:00 2001 From: William S Fulton Date: Fri, 16 May 2014 06:11:39 +0100 Subject: Travis folding correction --- .travis.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.travis.yml b/.travis.yml index 95e433952..5d42d3ac5 100644 --- a/.travis.yml +++ b/.travis.yml @@ -75,7 +75,7 @@ script: - ./swig -version && ./swig -pcreversion - if test -z "$SWIGLANG"; then make -s $SWIGJOBS check-ccache; fi - if test -z "$SWIGLANG"; then make -s $SWIGJOBS check-errors-test-suite; fi - - echo 'Installing...' && echo -en 'travis_fold:start:script.1\\r' + - echo 'Installing...' && echo -en 'travis_fold:start:script.2\\r' - if test -z "$SWIGLANG"; then sudo make -s install && swig -version && ccache-swig -V; fi - echo -en 'travis_fold:end:script.2\\r' - if test -n "$SWIGLANG"; then make -s check-$SWIGLANG-version; fi -- cgit v1.2.1 From 06d2c79c2869b709fd6ea3bb646051319bf79e7a Mon Sep 17 00:00:00 2001 From: William S Fulton Date: Fri, 16 May 2014 06:50:37 +0100 Subject: Another Travis folding correction --- .travis.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.travis.yml b/.travis.yml index 5d42d3ac5..a7a16f5fd 100644 --- a/.travis.yml +++ b/.travis.yml @@ -81,7 +81,7 @@ script: - if test -n "$SWIGLANG"; then make -s check-$SWIGLANG-version; fi - if test -n "$SWIGLANG"; then make -k $SWIGJOBS check-$SWIGLANG-examples; fi - if test -n "$SWIGLANG"; then make -k $SWIGJOBS check-$SWIGLANG-test-suite; fi - - echo -n 'Cleaning...' && echo -en 'travis_fold:start:script.3\\r' + - echo 'Cleaning...' && echo -en 'travis_fold:start:script.3\\r' - make maintainer-clean - echo -en 'travis_fold:end:script.3\\r' branches: -- cgit v1.2.1 From 17abb00f2046bd4b52010bb6e0235cb5e13ffbd8 Mon Sep 17 00:00:00 2001 From: William S Fulton Date: Fri, 16 May 2014 06:55:11 +0100 Subject: Modify Travis builds to build out of source Closes #167 --- .travis.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.travis.yml b/.travis.yml index a7a16f5fd..1e7d9c657 100644 --- a/.travis.yml +++ b/.travis.yml @@ -69,7 +69,7 @@ before_install: - if test "$SWIGLANG" = "tcl"; then sudo apt-get -qq install tcl8.4-dev; fi script: - echo 'Configuring...' && echo -en 'travis_fold:start:script.1\\r' - - ./autogen.sh && ./configure $CONFIGOPTS + - ./autogen.sh && mkdir -p build/build && cd build/build && ../../configure $CONFIGOPTS - echo -en 'travis_fold:end:script.1\\r' - make -s $SWIGJOBS - ./swig -version && ./swig -pcreversion -- cgit v1.2.1 From 8b19918a83d0a83c1b212fb1deedae4b965b6595 Mon Sep 17 00:00:00 2001 From: William S Fulton Date: Fri, 16 May 2014 08:02:11 +0100 Subject: Travis builds - add compiler version display --- .travis.yml | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/.travis.yml b/.travis.yml index 1e7d9c657..da5929e1e 100644 --- a/.travis.yml +++ b/.travis.yml @@ -50,8 +50,8 @@ matrix: # None before_install: - date -u - - lsb_release -a - uname -a + - lsb_release -a - sudo apt-get -qq update - time sudo apt-get -qq install libboost-dev - if test -z "$SWIGLANG"; then sudo apt-get -qq install yodl; fi @@ -67,6 +67,8 @@ before_install: - if test "$SWIGLANG" = "python" -a "$PY3" -a -z "$VER"; then sudo apt-get install -qq python3-dev; fi - if test "$SWIGLANG" = "python" -a "$VER"; then sudo add-apt-repository -y ppa:fkrull/deadsnakes && sudo apt-get -qq update && sudo apt-get -qq install python${VER}-dev && export CONFIGOPTS="--with-python${PY3}=python${VER}"; fi - if test "$SWIGLANG" = "tcl"; then sudo apt-get -qq install tcl8.4-dev; fi + - $CC --version + - $CXX --version script: - echo 'Configuring...' && echo -en 'travis_fold:start:script.1\\r' - ./autogen.sh && mkdir -p build/build && cd build/build && ../../configure $CONFIGOPTS -- cgit v1.2.1 From 50f5b4f7f448e79d7460a14795d752a74b60eaaf Mon Sep 17 00:00:00 2001 From: William S Fulton Date: Fri, 16 May 2014 20:46:35 +0100 Subject: Fix in source android examples clean --- Examples/Makefile.in | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Examples/Makefile.in b/Examples/Makefile.in index c47c075e9..954a41c07 100644 --- a/Examples/Makefile.in +++ b/Examples/Makefile.in @@ -782,7 +782,7 @@ android_version: # ----------------------------------------------------------------- android_clean: - cd $(SRCDIR) && ant -q -logfile /dev/null clean + test -n "$(SRCDIR)" && cd $(SRCDIR) ; ant -q -logfile /dev/null clean rm -f $(INTERFACEDIR)$(TARGET)_wrap.* rm -f `find $(PACKAGEDIR) -name \*.java | grep -v $(PROJECTNAME).java` rm -rf obj -- cgit v1.2.1 From 46e5f722c337320807deeacc0e20c6a598390936 Mon Sep 17 00:00:00 2001 From: William S Fulton Date: Fri, 16 May 2014 21:08:06 +0100 Subject: Travis testing: check configure still runs after make maintainer-clean --- .travis.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.travis.yml b/.travis.yml index da5929e1e..96e4fc9a7 100644 --- a/.travis.yml +++ b/.travis.yml @@ -84,7 +84,7 @@ script: - if test -n "$SWIGLANG"; then make -k $SWIGJOBS check-$SWIGLANG-examples; fi - if test -n "$SWIGLANG"; then make -k $SWIGJOBS check-$SWIGLANG-test-suite; fi - echo 'Cleaning...' && echo -en 'travis_fold:start:script.3\\r' - - make maintainer-clean + - make maintainer-clean && ../../configure $CONFIGOPTS - echo -en 'travis_fold:end:script.3\\r' branches: only: -- cgit v1.2.1 From b8b61be301a40521c2908e0236f04369e71749d3 Mon Sep 17 00:00:00 2001 From: William S Fulton Date: Sat, 17 May 2014 23:32:09 +0100 Subject: Detect Javascript v8 on 64 bit Linux --- configure.ac | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/configure.ac b/configure.ac index e2cbe9fca..2ff5dc8db 100644 --- a/configure.ac +++ b/configure.ac @@ -1259,7 +1259,7 @@ else AC_MSG_CHECKING(for V8 Javascript library) AC_ARG_WITH(jsv8lib,[ --with-v8lib=path Set location of V8 Javascript library directory],[JSV8LIBDIR="$withval"], [JSV8LIB=]) - v8libdirs="$JSV8LIBDIR /usr/lib/ /usr/local/lib/" + v8libdirs="$JSV8LIBDIR /usr/lib*/ /usr/local/lib*/" for d in $v8libdirs ; do if test -r $d/libv8.so; then JSV8LIBDIR=$d -- cgit v1.2.1 From ac89f7f7854907f8b45b42ef1f447234d5eb1c64 Mon Sep 17 00:00:00 2001 From: William S Fulton Date: Sun, 18 May 2014 00:59:47 +0100 Subject: Javascript examples tidy up - Remove empty files - Improve clean --- .gitignore | 11 +++++++---- Examples/Makefile.in | 3 ++- Examples/javascript/functor/Makefile | 2 +- Examples/javascript/functor/binding.gyp.in | 2 +- Examples/javascript/functor/example.cxx | 0 Examples/javascript/pointer/typemaps.i | 0 Examples/test-suite/javascript/Makefile.in | 9 +++------ 7 files changed, 14 insertions(+), 13 deletions(-) delete mode 100644 Examples/javascript/functor/example.cxx delete mode 100644 Examples/javascript/pointer/typemaps.i diff --git a/.gitignore b/.gitignore index efb6cf096..c7961efd7 100644 --- a/.gitignore +++ b/.gitignore @@ -124,16 +124,19 @@ Examples/test-suite/uffi/*/ *_wrap.c *_wrap.cxx +# C# generated files +*_runme.exe.mdb +*_runme.exe + +# Javascript generated files +*.gyp + # Python generated files, based on: # https://github.com/github/gitignore/blob/master/Python.gitignore *.py[cod] */__pycache__/ /__pycache__/ -# C# generated files -*_runme.exe.mdb -*_runme.exe - # Scratch directories Examples/scratch diff --git a/Examples/Makefile.in b/Examples/Makefile.in index 954a41c07..b22fd2e76 100644 --- a/Examples/Makefile.in +++ b/Examples/Makefile.in @@ -730,7 +730,8 @@ javascript_clean: rm -f *_wrap* $(RUNME) rm -f core @EXTRA_CLEAN@ rm -f *.@OBJEXT@ *@JSSO@ *.$(SO) - (cd $(ROOT_DIR)/Tools/javascript && $(MAKE) -s clean) + rm -f binding.gyp + cd $(ROOT_DIR)/Tools/javascript && $(MAKE) -s clean ################################################################## ##### ANDROID ###### diff --git a/Examples/javascript/functor/Makefile b/Examples/javascript/functor/Makefile index 54a8f7b03..0402f8d09 100644 --- a/Examples/javascript/functor/Makefile +++ b/Examples/javascript/functor/Makefile @@ -1,3 +1,3 @@ -SRCS = example.cxx +SRCS = include $(SRCDIR)../example.mk diff --git a/Examples/javascript/functor/binding.gyp.in b/Examples/javascript/functor/binding.gyp.in index c56a650e9..59779aef4 100644 --- a/Examples/javascript/functor/binding.gyp.in +++ b/Examples/javascript/functor/binding.gyp.in @@ -2,7 +2,7 @@ "targets": [ { "target_name": "example", - "sources": [ "$srcdir/example.cxx", "example_wrap.cxx" ], + "sources": [ "example_wrap.cxx" ], "include_dirs": ["$srcdir"] } ] diff --git a/Examples/javascript/functor/example.cxx b/Examples/javascript/functor/example.cxx deleted file mode 100644 index e69de29bb..000000000 diff --git a/Examples/javascript/pointer/typemaps.i b/Examples/javascript/pointer/typemaps.i deleted file mode 100644 index e69de29bb..000000000 diff --git a/Examples/test-suite/javascript/Makefile.in b/Examples/test-suite/javascript/Makefile.in index 87e4c6ecb..fc5255155 100644 --- a/Examples/test-suite/javascript/Makefile.in +++ b/Examples/test-suite/javascript/Makefile.in @@ -116,9 +116,6 @@ endif %.clean: rm -rf $* - -clean: - rm -f *_wrap.cxx - rm -f *_wrap.c - rm -f *.so - rm -f *.o + rm -f $*_wrap.* + rm -f $*.so + rm -f $*.o -- cgit v1.2.1 From 176c697c8b50856de8c2be99e1674c4a82c9f800 Mon Sep 17 00:00:00 2001 From: William S Fulton Date: Sun, 18 May 2014 01:06:56 +0100 Subject: Remove PHP director_basic runtime test until fixed. See #164 --- Examples/test-suite/php/director_basic_runme.php | 2 ++ 1 file changed, 2 insertions(+) diff --git a/Examples/test-suite/php/director_basic_runme.php b/Examples/test-suite/php/director_basic_runme.php index de6b50502..1458725f1 100644 --- a/Examples/test-suite/php/director_basic_runme.php +++ b/Examples/test-suite/php/director_basic_runme.php @@ -3,6 +3,7 @@ require "tests.php"; require "director_basic.php"; +/* Removed until runtime error is fixed, see https://github.com/swig/swig/issues/164 // No new functions check::functions(array(foo_ping,foo_pong,foo_get_self,a_f,a_rg,a1_ff,myclass_method,myclass_vmethod,myclass_pmethod,myclass_cmethod,myclass_get_self,myclass_call_pmethod,myclasst_i_method)); // No new classes @@ -53,6 +54,7 @@ $cc->method($b); check::equal($bc->x, 34, "bc failed"); check::equal($bd->x, 16, "bd failed"); +*/ check::done(); ?> -- cgit v1.2.1 From 46cfdba5ca7c1385840005470ec433bef0ea8768 Mon Sep 17 00:00:00 2001 From: William S Fulton Date: Sun, 18 May 2014 01:36:29 +0100 Subject: Attempt to fix li_boost_intrusive_ptr C# compile error Using boost 1.36 and gcc-4.3.4 --- Examples/test-suite/li_boost_intrusive_ptr.i | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/Examples/test-suite/li_boost_intrusive_ptr.i b/Examples/test-suite/li_boost_intrusive_ptr.i index 4916d0285..01613be0e 100644 --- a/Examples/test-suite/li_boost_intrusive_ptr.i +++ b/Examples/test-suite/li_boost_intrusive_ptr.i @@ -14,13 +14,13 @@ %warnfilter(SWIGWARN_LANG_SMARTPTR_MISSING) KlassDerivedDerived; %{ -template void intrusive_ptr_add_ref(const T* r) { r->addref(); } -template void intrusive_ptr_release(const T* r) { r->release(); } - #include #include #include +template void intrusive_ptr_add_ref(const T* r) { r->addref(); } +template void intrusive_ptr_release(const T* r) { r->release(); } + // Uncomment macro below to turn on intrusive_ptr memory leak checking as described above //#define INTRUSIVE_PTR_WRAPPER -- cgit v1.2.1 From def3c08943ea533102dbb2b4b7a64607516f5d3b Mon Sep 17 00:00:00 2001 From: Olly Betts Date: Sun, 18 May 2014 20:20:30 +1200 Subject: Fix comment typos --- Examples/test-suite/lua/operator_overload_runme.lua | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/Examples/test-suite/lua/operator_overload_runme.lua b/Examples/test-suite/lua/operator_overload_runme.lua index 5ba06ff08..c34c09021 100644 --- a/Examples/test-suite/lua/operator_overload_runme.lua +++ b/Examples/test-suite/lua/operator_overload_runme.lua @@ -1,4 +1,4 @@ --- demo of lua swig capacilities (operator overloading) +-- demo of lua swig capacities (operator overloading) require("import") -- the import fn import("operator_overload") -- import lib @@ -33,7 +33,7 @@ assert(b>=c) assert(b>d) assert(b>=d) --- lua does not support += operators: skiping +-- lua does not support += operators: skipping -- test + f=Op(1) @@ -50,7 +50,7 @@ assert(f/g==Op(1)) --lua 5.0.2 defines that unary - is __unm(self,nil) --lua 5.1.2 defines that unary - is __unm(self,self) ---C++ expectes unary - as operator-() +--C++ expects unary - as operator-() --however the latest version of SWIG strictly checks the number of args --and will complain if too many args are provided --therefore disabling these tests for now @@ -79,7 +79,7 @@ assert(tostring(Op(1))=="Op(1)") assert(tostring(Op(-3))=="Op(-3)") --- check that operator overloads are correctly propogated down inheritance hierarchy +-- check that operator overloads are correctly propagated down inheritance hierarchy a_d=OpDerived() b_d=OpDerived(5) -- cgit v1.2.1 From 95f09b49d2be5804501e5e1eafe3cf8f58ff3510 Mon Sep 17 00:00:00 2001 From: Olly Betts Date: Sun, 18 May 2014 20:38:43 +1200 Subject: Don't use // comments in C code. --- Lib/lua/luarun.swg | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/Lib/lua/luarun.swg b/Lib/lua/luarun.swg index d038f4af1..ad735a541 100644 --- a/Lib/lua/luarun.swg +++ b/Lib/lua/luarun.swg @@ -268,7 +268,7 @@ typedef struct swig_lua_class { swig_lua_method *methods; swig_lua_attribute *attributes; swig_lua_namespace *cls_static; - swig_lua_method *metatable; // 0 for -eluac + swig_lua_method *metatable; /* 0 for -eluac */ struct swig_lua_class **bases; const char **base_names; } swig_lua_class; @@ -1629,7 +1629,7 @@ SWIGINTERN void SWIG_Lua_elua_class_register_instance(lua_State *L, swig_lua_cla lua_pop(L,1); assert(lua_gettop(L) == begin); } -#endif // elua && eluac +#endif /* elua && eluac */ /* ----------------------------------------------------------------------------- * Class/structure conversion fns -- cgit v1.2.1 From aa55154ccfa967297181e886a350a36b03c64e07 Mon Sep 17 00:00:00 2001 From: Eric Wing Date: Sun, 18 May 2014 01:29:45 -0700 Subject: JavaScript: Added missing static modifiers to avoid duplicate symbol problems with multiple SWIG modules. --- Lib/javascript/jsc/javascriptcode.swg | 42 ++++++++++++++++---------------- Lib/javascript/jsc/javascripthelpers.swg | 10 ++++---- Lib/javascript/v8/javascripthelpers.swg | 12 ++++----- 3 files changed, 32 insertions(+), 32 deletions(-) diff --git a/Lib/javascript/jsc/javascriptcode.swg b/Lib/javascript/jsc/javascriptcode.swg index 738b54d70..a5f395944 100644 --- a/Lib/javascript/jsc/javascriptcode.swg +++ b/Lib/javascript/jsc/javascriptcode.swg @@ -8,7 +8,7 @@ * ----------------------------------------------------------------------------- */ %fragment ("js_ctor", "templates") %{ -JSObjectRef $jswrapper(JSContextRef context, JSObjectRef thisObject, size_t argc, const JSValueRef argv[], JSValueRef* exception) +static JSObjectRef $jswrapper(JSContextRef context, JSObjectRef thisObject, size_t argc, const JSValueRef argv[], JSValueRef* exception) { $jslocals if(argc != $jsargcount) SWIG_exception_fail(SWIG_ERROR, "Illegal number of arguments for $jswrapper."); @@ -28,7 +28,7 @@ JSObjectRef $jswrapper(JSContextRef context, JSObjectRef thisObject, size_t argc * ----------------------------------------------------------------------------- */ %fragment ("js_veto_ctor", "templates") %{ -JSObjectRef $jswrapper(JSContextRef context, JSObjectRef ctorObject, +static JSObjectRef $jswrapper(JSContextRef context, JSObjectRef ctorObject, size_t argc, const JSValueRef argv[], JSValueRef* exception) { SWIG_exception(SWIG_ERROR, "Class $jsname can not be instantiated"); @@ -44,7 +44,7 @@ JSObjectRef $jswrapper(JSContextRef context, JSObjectRef ctorObject, * ----------------------------------------------------------------------------- */ %fragment ("js_ctor_dispatcher", "templates") %{ -JSObjectRef $jswrapper(JSContextRef context, JSObjectRef ctorObject, +static JSObjectRef $jswrapper(JSContextRef context, JSObjectRef ctorObject, size_t argc, const JSValueRef argv[], JSValueRef* exception) { JSObjectRef thisObject = NULL; @@ -70,7 +70,7 @@ JSObjectRef $jswrapper(JSContextRef context, JSObjectRef ctorObject, * ----------------------------------------------------------------------------- */ %fragment ("js_overloaded_ctor", "templates") %{ -JSObjectRef $jswrapper(JSContextRef context, JSObjectRef thisObject, size_t argc, const JSValueRef argv[], JSValueRef* exception) +static JSObjectRef $jswrapper(JSContextRef context, JSObjectRef thisObject, size_t argc, const JSValueRef argv[], JSValueRef* exception) { $jslocals $jscode @@ -105,7 +105,7 @@ JSObjectRef $jswrapper(JSContextRef context, JSObjectRef thisObject, size_t argc * ----------------------------------------------------------------------------- */ %fragment ("js_dtor", "templates") %{ -void $jswrapper(JSObjectRef thisObject) +static void $jswrapper(JSObjectRef thisObject) { SwigPrivData* t = (SwigPrivData*) JSObjectGetPrivate(thisObject); if(t && t->swigCMemOwn) free (($jstype)t->swigCObject); @@ -121,7 +121,7 @@ void $jswrapper(JSObjectRef thisObject) * ----------------------------------------------------------------------------- */ %fragment ("js_dtoroverride", "templates") %{ -void $jswrapper(JSObjectRef thisObject) +static void $jswrapper(JSObjectRef thisObject) { SwigPrivData* t = (SwigPrivData*) JSObjectGetPrivate(thisObject); if(t && t->swigCMemOwn) { @@ -140,7 +140,7 @@ void $jswrapper(JSObjectRef thisObject) * ----------------------------------------------------------------------------- */ %fragment ("js_getter", "templates") %{ -JSValueRef $jswrapper(JSContextRef context, JSObjectRef thisObject, JSStringRef propertyName, JSValueRef* exception) +static JSValueRef $jswrapper(JSContextRef context, JSObjectRef thisObject, JSStringRef propertyName, JSValueRef* exception) { $jslocals JSValueRef jsresult; @@ -162,7 +162,7 @@ JSValueRef $jswrapper(JSContextRef context, JSObjectRef thisObject, JSStringRef * ----------------------------------------------------------------------------- */ %fragment ("js_setter", "templates") %{ -bool $jswrapper(JSContextRef context, JSObjectRef thisObject, JSStringRef propertyName, JSValueRef value, JSValueRef* exception) +static bool $jswrapper(JSContextRef context, JSObjectRef thisObject, JSStringRef propertyName, JSValueRef value, JSValueRef* exception) { $jslocals $jscode @@ -183,7 +183,7 @@ bool $jswrapper(JSContextRef context, JSObjectRef thisObject, JSStringRef proper * ----------------------------------------------------------------------------- */ %fragment ("js_function", "templates") %{ -JSValueRef $jswrapper(JSContextRef context, JSObjectRef function, JSObjectRef thisObject, size_t argc, const JSValueRef argv[], JSValueRef* exception) +static JSValueRef $jswrapper(JSContextRef context, JSObjectRef function, JSObjectRef thisObject, size_t argc, const JSValueRef argv[], JSValueRef* exception) { $jslocals JSValueRef jsresult; @@ -208,7 +208,7 @@ JSValueRef $jswrapper(JSContextRef context, JSObjectRef function, JSObjectRef th * ----------------------------------------------------------------------------- */ %fragment ("js_function_dispatcher", "templates") %{ -JSValueRef $jswrapper(JSContextRef context, JSObjectRef function, JSObjectRef thisObject, size_t argc, const JSValueRef argv[], JSValueRef* exception) +static JSValueRef $jswrapper(JSContextRef context, JSObjectRef function, JSObjectRef thisObject, size_t argc, const JSValueRef argv[], JSValueRef* exception) { $jslocals JSValueRef jsresult; @@ -232,7 +232,7 @@ JSValueRef $jswrapper(JSContextRef context, JSObjectRef function, JSObjectRef th * ----------------------------------------------------------------------------- */ %fragment ("js_overloaded_function", "templates") %{ -int $jswrapper(JSContextRef context, JSObjectRef function, JSObjectRef thisObject, size_t argc, const JSValueRef argv[], JSValueRef* exception, JSValueRef* p_result) +static int $jswrapper(JSContextRef context, JSObjectRef function, JSObjectRef thisObject, size_t argc, const JSValueRef argv[], JSValueRef* exception, JSValueRef* p_result) { $jslocals JSValueRef jsresult; @@ -291,11 +291,11 @@ int $jswrapper(JSContextRef context, JSObjectRef function, JSObjectRef thisObjec * ----------------------------------------------------------------------------- */ %fragment ("jsc_class_declaration", "templates") %{ -JSClassDefinition $jsmangledname_classDefinition; +static JSClassDefinition $jsmangledname_classDefinition; -JSClassDefinition $jsmangledname_objectDefinition; +static JSClassDefinition $jsmangledname_objectDefinition; -JSClassRef $jsmangledname_classRef; +static JSClassRef $jsmangledname_classRef; %} /* ----------------------------------------------------------------------------- @@ -308,22 +308,22 @@ JSClassRef $jsmangledname_classRef; * ----------------------------------------------------------------------------- */ %fragment ("jsc_class_tables", "templates") %{ -JSStaticValue $jsmangledname_staticValues[] = { +static JSStaticValue $jsmangledname_staticValues[] = { $jsstaticclassvariables { 0, 0, 0, 0 } }; -JSStaticFunction $jsmangledname_staticFunctions[] = { +static JSStaticFunction $jsmangledname_staticFunctions[] = { $jsstaticclassfunctions { 0, 0, 0 } }; -JSStaticValue $jsmangledname_values[] = { +static JSStaticValue $jsmangledname_values[] = { $jsclassvariables { 0, 0, 0, 0 } }; -JSStaticFunction $jsmangledname_functions[] = { +static JSStaticFunction $jsmangledname_functions[] = { $jsclassfunctions { 0, 0, 0 } }; @@ -382,17 +382,17 @@ JSStaticFunction $jsmangledname_functions[] = { * ----------------------------------------------------------------------------- */ %fragment ("jsc_nspace_declaration", "templates") %{ -JSStaticValue $jsnspace_values[] = { +static JSStaticValue $jsnspace_values[] = { $jsglobalvariables { 0, 0, 0, 0 } }; -JSStaticFunction $jsnspace_functions[] = { +static JSStaticFunction $jsnspace_functions[] = { $jsglobalfunctions { 0, 0, 0 } }; -JSClassDefinition $jsnspace_classDefinition; +static JSClassDefinition $jsnspace_classDefinition; %} /* ----------------------------------------------------------------------------- diff --git a/Lib/javascript/jsc/javascripthelpers.swg b/Lib/javascript/jsc/javascripthelpers.swg index 820075ca6..405280161 100644 --- a/Lib/javascript/jsc/javascripthelpers.swg +++ b/Lib/javascript/jsc/javascripthelpers.swg @@ -1,6 +1,6 @@ %insert(wrapper) %{ -bool JS_registerClass(JSGlobalContextRef context, JSObjectRef parentObject, +SWIGINTERN bool JS_registerClass(JSGlobalContextRef context, JSObjectRef parentObject, const char* className, JSClassDefinition* definition) { @@ -14,7 +14,7 @@ bool JS_registerClass(JSGlobalContextRef context, JSObjectRef parentObject, return true; } -bool JS_registerNamespace(JSGlobalContextRef context, +SWIGINTERN bool JS_registerNamespace(JSGlobalContextRef context, JSObjectRef namespaceObj, JSObjectRef parentNamespace, const char* name) { @@ -28,7 +28,7 @@ bool JS_registerNamespace(JSGlobalContextRef context, } -bool JS_registerFunction(JSGlobalContextRef context, JSObjectRef object, +SWIGINTERN bool JS_registerFunction(JSGlobalContextRef context, JSObjectRef object, const char* functionName, JSObjectCallAsFunctionCallback callback) { JSStringRef js_functionName = JSStringCreateWithUTF8CString(functionName); @@ -39,7 +39,7 @@ bool JS_registerFunction(JSGlobalContextRef context, JSObjectRef object, return true; } -bool JS_veto_set_variable(JSContextRef context, JSObjectRef thisObject, JSStringRef propertyName, JSValueRef value, JSValueRef* exception) +SWIGINTERN bool JS_veto_set_variable(JSContextRef context, JSObjectRef thisObject, JSStringRef propertyName, JSValueRef value, JSValueRef* exception) { char buffer[256]; char msg[512]; @@ -57,7 +57,7 @@ bool JS_veto_set_variable(JSContextRef context, JSObjectRef thisObject, JSString return false; } -JSValueRef JS_CharPtrToJSValue(JSContextRef context, char* cstr) { +SWIGINTERN JSValueRef JS_CharPtrToJSValue(JSContextRef context, char* cstr) { JSValueRef val; JSStringRef jsstring = JSStringCreateWithUTF8CString((char*) cstr); diff --git a/Lib/javascript/v8/javascripthelpers.swg b/Lib/javascript/v8/javascripthelpers.swg index 8da6627e2..f6303cced 100644 --- a/Lib/javascript/v8/javascripthelpers.swg +++ b/Lib/javascript/v8/javascripthelpers.swg @@ -16,7 +16,7 @@ typedef v8::PropertyCallbackInfo SwigV8PropertyCallbackInfoVoid; /** * Creates a class template for a class with specified initialization function. */ -v8::Handle SWIGV8_CreateClassTemplate(const char* symbol) { +SWIGRUNTIME v8::Handle SWIGV8_CreateClassTemplate(const char* symbol) { v8::HandleScope scope; v8::Local class_templ = v8::FunctionTemplate::New(); class_templ->SetClassName(v8::String::NewSymbol(symbol)); @@ -36,7 +36,7 @@ v8::Handle SWIGV8_CreateClassTemplate(const char* symbol) /** * Registers a class method with given name for a given class template. */ -void SWIGV8_AddMemberFunction(v8::Handle class_templ, const char* symbol, +SWIGRUNTIME void SWIGV8_AddMemberFunction(v8::Handle class_templ, const char* symbol, SwigV8FunctionCallback _func) { v8::Handle proto_templ = class_templ->PrototypeTemplate(); proto_templ->Set(v8::String::NewSymbol(symbol), v8::FunctionTemplate::New(_func)); @@ -45,7 +45,7 @@ void SWIGV8_AddMemberFunction(v8::Handle class_templ, cons /** * Registers a class property with given name for a given class template. */ -void SWIGV8_AddMemberVariable(v8::Handle class_templ, const char* symbol, +SWIGRUNTIME void SWIGV8_AddMemberVariable(v8::Handle class_templ, const char* symbol, SwigV8AccessorGetterCallback getter, SwigV8AccessorSetterCallback setter) { v8::Handle proto_templ = class_templ->InstanceTemplate(); proto_templ->SetAccessor(v8::String::NewSymbol(symbol), getter, setter); @@ -54,7 +54,7 @@ void SWIGV8_AddMemberVariable(v8::Handle class_templ, cons /** * Registers a class method with given name for a given object. */ -void SWIGV8_AddStaticFunction(v8::Handle obj, const char* symbol, +SWIGRUNTIME void SWIGV8_AddStaticFunction(v8::Handle obj, const char* symbol, const SwigV8FunctionCallback& _func) { obj->Set(v8::String::NewSymbol(symbol), v8::FunctionTemplate::New(_func)->GetFunction()); } @@ -62,12 +62,12 @@ void SWIGV8_AddStaticFunction(v8::Handle obj, const char* symbol, /** * Registers a class method with given name for a given object. */ -void SWIGV8_AddStaticVariable(v8::Handle obj, const char* symbol, +SWIGRUNTIME void SWIGV8_AddStaticVariable(v8::Handle obj, const char* symbol, SwigV8AccessorGetterCallback getter, SwigV8AccessorSetterCallback setter) { obj->SetAccessor(v8::String::NewSymbol(symbol), getter, setter); } -void JS_veto_set_variable(v8::Local property, v8::Local value, +SWIGRUNTIME void JS_veto_set_variable(v8::Local property, v8::Local value, const SwigV8PropertyCallbackInfoVoid& info) { char buffer[256]; -- cgit v1.2.1 From b4534a481aa370a58d376522ea67072fcc446d8f Mon Sep 17 00:00:00 2001 From: Eric Wing Date: Sun, 18 May 2014 01:32:26 -0700 Subject: JavaScriptCore: Bug fix for finalizer. The finalizer needs to be set on the objectDefinition, not the classDefinition. Otherwise, all the finalize callbacks get NULL back for the PrivateData and can't free the SwigPrivData, causing massive leakage. --- Lib/javascript/jsc/javascriptcode.swg | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Lib/javascript/jsc/javascriptcode.swg b/Lib/javascript/jsc/javascriptcode.swg index a5f395944..da6130a6a 100644 --- a/Lib/javascript/jsc/javascriptcode.swg +++ b/Lib/javascript/jsc/javascriptcode.swg @@ -341,7 +341,7 @@ static JSStaticFunction $jsmangledname_functions[] = { $jsmangledname_classDefinition.staticFunctions = $jsmangledname_staticFunctions; $jsmangledname_classDefinition.staticValues = $jsmangledname_staticValues; $jsmangledname_classDefinition.callAsConstructor = $jsctor; - $jsmangledname_classDefinition.finalize = $jsdtor; + $jsmangledname_objectDefinition.finalize = $jsdtor; $jsmangledname_objectDefinition.staticValues = $jsmangledname_values; $jsmangledname_objectDefinition.staticFunctions = $jsmangledname_functions; $jsclass_inheritance -- cgit v1.2.1 From fcb48336605474e97e73ca2bc89076ee01e0b8fa Mon Sep 17 00:00:00 2001 From: Oliver Buchtala Date: Sun, 18 May 2014 20:33:10 +0200 Subject: JavascriptCore: fix cleanup code. --- Lib/javascript/jsc/javascriptcode.swg | 21 +++++++++++++++------ 1 file changed, 15 insertions(+), 6 deletions(-) diff --git a/Lib/javascript/jsc/javascriptcode.swg b/Lib/javascript/jsc/javascriptcode.swg index da6130a6a..3fe9d49e9 100644 --- a/Lib/javascript/jsc/javascriptcode.swg +++ b/Lib/javascript/jsc/javascriptcode.swg @@ -108,8 +108,13 @@ static JSObjectRef $jswrapper(JSContextRef context, JSObjectRef thisObject, size static void $jswrapper(JSObjectRef thisObject) { SwigPrivData* t = (SwigPrivData*) JSObjectGetPrivate(thisObject); - if(t && t->swigCMemOwn) free (($jstype)t->swigCObject); - if(t) free(t); + if(t) { + if (t->swigCMemOwn) { + free (($jstype)t->swigCObject); + } + JSObjectSetPrivate(thisObject, NULL); + free(t); + } } %} @@ -124,11 +129,15 @@ static void $jswrapper(JSObjectRef thisObject) static void $jswrapper(JSObjectRef thisObject) { SwigPrivData* t = (SwigPrivData*) JSObjectGetPrivate(thisObject); - if(t && t->swigCMemOwn) { - $jstype arg1 = ($jstype)t->swigCObject; - ${destructor_action} + if(t) { + if (t->swigCMemOwn) { + $jstype arg1 = ($jstype)t->swigCObject; + ${destructor_action} + } + /* remove the private data to make sure that it isn't accessed elsewhere */ + JSObjectSetPrivate(thisObject, NULL); + free(t); } - if(t) free(t); } %} -- cgit v1.2.1 From 486e903de1bbf847a0a60aa85ab1e1a44c8ca159 Mon Sep 17 00:00:00 2001 From: Eric Wing Date: Sun, 18 May 2014 01:35:46 -0700 Subject: JavaScriptCore: Bug fix for SWIGJSC_AppendOutput. This function requires a return value. I think it should be arr, but somebody should scrutinize this. --- Lib/javascript/jsc/javascriptrun.swg | 1 + 1 file changed, 1 insertion(+) diff --git a/Lib/javascript/jsc/javascriptrun.swg b/Lib/javascript/jsc/javascriptrun.swg index 3463d2351..95f00659d 100644 --- a/Lib/javascript/jsc/javascriptrun.swg +++ b/Lib/javascript/jsc/javascriptrun.swg @@ -295,4 +295,5 @@ JSValueRef SWIGJSC_AppendOutput(JSContextRef context, JSValueRef value, JSValueR length = SWIGJSC_ArrayLength(context, arr); JSObjectSetPropertyAtIndex(context, arr, length, obj, 0); + return arr; } -- cgit v1.2.1 From fade0bcbdef3a1127d677f6ff72be064bcda5a57 Mon Sep 17 00:00:00 2001 From: Eric Wing Date: Sun, 18 May 2014 01:50:05 -0700 Subject: JavaScriptCore: C89: declare variables at the top for antiquated compilers like Microsoft Visual Studio. --- Lib/javascript/jsc/javascriptrun.swg | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/Lib/javascript/jsc/javascriptrun.swg b/Lib/javascript/jsc/javascriptrun.swg index 95f00659d..fce22a452 100644 --- a/Lib/javascript/jsc/javascriptrun.swg +++ b/Lib/javascript/jsc/javascriptrun.swg @@ -128,11 +128,12 @@ int SWIG_JSC_ConvertInstancePtr(JSContextRef context, JSObjectRef objRef, void** } int SWIG_JSC_ConvertPtr(JSContextRef context, JSValueRef valRef, void** ptr, swig_type_info *info, int flags) { + JSObjectRef objRef; if(!JSValueIsObject(context, valRef)) { return SWIG_TypeError; } - JSObjectRef objRef = JSValueToObject(context, valRef, NULL); + objRef = JSValueToObject(context, valRef, NULL); if(objRef == NULL) { return SWIG_ERROR; } -- cgit v1.2.1 From 8498e4878d130a6ae24843084408339f3bf910ce Mon Sep 17 00:00:00 2001 From: Eric Wing Date: Sun, 18 May 2014 03:03:46 -0700 Subject: JavaScriptCore: More missing static modifiers. --- Lib/javascript/jsc/javascriptrun.swg | 36 ++++++++++++++++++------------------ 1 file changed, 18 insertions(+), 18 deletions(-) diff --git a/Lib/javascript/jsc/javascriptrun.swg b/Lib/javascript/jsc/javascriptrun.swg index fce22a452..813c7deb4 100644 --- a/Lib/javascript/jsc/javascriptrun.swg +++ b/Lib/javascript/jsc/javascriptrun.swg @@ -7,13 +7,13 @@ #define SWIG_exception(code, msg) SWIG_JSC_exception(context, exception, code, msg) #define SWIG_fail goto fail -void SWIG_Javascript_Raise(JSContextRef context, JSValueRef *exception, const char* type) { +SWIGRUNTIME void SWIG_Javascript_Raise(JSContextRef context, JSValueRef *exception, const char* type) { JSStringRef message = JSStringCreateWithUTF8CString(type); *exception = JSValueMakeString(context, message); JSStringRelease(message); } -void SWIG_JSC_exception(JSContextRef context, JSValueRef *exception, int code, const char* msg) { +SWIGRUNTIME void SWIG_JSC_exception(JSContextRef context, JSValueRef *exception, int code, const char* msg) { SWIG_Javascript_Raise(context, exception, msg); } @@ -28,7 +28,7 @@ typedef struct { swig_type_info *info; } SwigPrivData; -JSValueRef _wrap_SwigObject_disown(JSContextRef context, JSObjectRef function, JSObjectRef thisObject, size_t argc, const JSValueRef argv[], JSValueRef* exception) +SWIGRUNTIME JSValueRef _wrap_SwigObject_disown(JSContextRef context, JSObjectRef function, JSObjectRef thisObject, size_t argc, const JSValueRef argv[], JSValueRef* exception) { JSValueRef jsresult; @@ -41,7 +41,7 @@ JSValueRef _wrap_SwigObject_disown(JSContextRef context, JSObjectRef function, J return jsresult; } -JSValueRef _wrap_SwigObject_getCPtr(JSContextRef context, JSObjectRef function, JSObjectRef thisObject, size_t argc, const JSValueRef argv[], JSValueRef* exception) +SWIGRUNTIME JSValueRef _wrap_SwigObject_getCPtr(JSContextRef context, JSObjectRef function, JSObjectRef thisObject, size_t argc, const JSValueRef argv[], JSValueRef* exception) { JSValueRef jsresult; long result; @@ -55,7 +55,7 @@ JSValueRef _wrap_SwigObject_getCPtr(JSContextRef context, JSObjectRef function, return jsresult; } -JSValueRef _wrap_SwigObject_equals(JSContextRef context, JSObjectRef function, JSObjectRef thisObject, size_t argc, const JSValueRef argv[], JSValueRef* exception) +SWIGRUNTIME JSValueRef _wrap_SwigObject_equals(JSContextRef context, JSObjectRef function, JSObjectRef thisObject, size_t argc, const JSValueRef argv[], JSValueRef* exception) { JSValueRef jsresult; bool result; @@ -72,13 +72,13 @@ JSValueRef _wrap_SwigObject_equals(JSContextRef context, JSObjectRef function, J return jsresult; } -JSStaticValue _SwigObject_values[] = { +SWIGRUNTIME JSStaticValue _SwigObject_values[] = { { 0, 0, 0, 0 } }; -JSStaticFunction _SwigObject_functions[] = { +SWIGRUNTIME JSStaticFunction _SwigObject_functions[] = { { "disown",_wrap_SwigObject_disown, kJSPropertyAttributeNone }, @@ -93,12 +93,12 @@ JSStaticFunction _SwigObject_functions[] = { } }; -JSClassDefinition _SwigObject_objectDefinition; +SWIGRUNTIME JSClassDefinition _SwigObject_objectDefinition; -JSClassRef _SwigObject_classRef; +SWIGRUNTIME JSClassRef _SwigObject_classRef; -int SWIG_JSC_ConvertInstancePtr(JSContextRef context, JSObjectRef objRef, void** ptr, swig_type_info *info, int flags) { +SWIGRUNTIME int SWIG_JSC_ConvertInstancePtr(JSContextRef context, JSObjectRef objRef, void** ptr, swig_type_info *info, int flags) { SwigPrivData *cdata = (SwigPrivData *) JSObjectGetPrivate(objRef); if(cdata == NULL) { return SWIG_ERROR; @@ -127,7 +127,7 @@ int SWIG_JSC_ConvertInstancePtr(JSContextRef context, JSObjectRef objRef, void** return SWIG_OK; } -int SWIG_JSC_ConvertPtr(JSContextRef context, JSValueRef valRef, void** ptr, swig_type_info *info, int flags) { +SWIGRUNTIME int SWIG_JSC_ConvertPtr(JSContextRef context, JSValueRef valRef, void** ptr, swig_type_info *info, int flags) { JSObjectRef objRef; if(!JSValueIsObject(context, valRef)) { return SWIG_TypeError; @@ -141,7 +141,7 @@ int SWIG_JSC_ConvertPtr(JSContextRef context, JSValueRef valRef, void** ptr, swi return SWIG_JSC_ConvertInstancePtr(context, objRef, ptr, info, flags); } -JSObjectRef SWIG_JSC_NewPointerObj(JSContextRef context, void *ptr, swig_type_info *info, int flags) { +SWIGRUNTIME JSObjectRef SWIG_JSC_NewPointerObj(JSContextRef context, void *ptr, swig_type_info *info, int flags) { JSClassRef classRef; if(info->clientdata == NULL) { @@ -182,18 +182,18 @@ typedef struct { swig_type_info *type; } SwigPackedData; -JSStaticValue _SwigPackedData_values[] = { +SWIGRUNTIME JSStaticValue _SwigPackedData_values[] = { { 0, 0, 0, 0 } }; -JSStaticFunction _SwigPackedData_functions[] = { +SWIGRUNTIME JSStaticFunction _SwigPackedData_functions[] = { { 0, 0, 0 } }; -JSClassDefinition _SwigPackedData_objectDefinition; -JSClassRef _SwigPackedData_classRef; +SWIGRUNTIME JSClassDefinition _SwigPackedData_objectDefinition; +SWIGRUNTIME JSClassRef _SwigPackedData_classRef; SWIGRUNTIMEINLINE int SwigJSCPacked_Check(JSContextRef context, JSValueRef valRef) { @@ -244,7 +244,7 @@ JSValueRef SWIG_JSC_NewPackedObj(JSContextRef context, void *data, size_t size, } /* SwigPackedData wrappers */ - +SWIGRUNTIME void _wrap_SwigPackedData_delete(JSObjectRef obj) { SwigPackedData* cdata = (SwigPackedData*) JSObjectGetPrivate(obj); @@ -263,7 +263,7 @@ void _wrap_SwigPackedData_delete(JSObjectRef obj) * Support for IN/OUTPUT typemaps (see Lib/typemaps/inoutlist.swg) * * ---------------------------------------------------------------------------*/ - +SWIGRUNTIME unsigned int SWIGJSC_ArrayLength(JSContextRef context, JSObjectRef arr) { static JSStringRef LENGTH = 0; JSValueRef exception = NULL; -- cgit v1.2.1 From 05ed0325dc4bd9ddc126d3dacc6b38686f7382cf Mon Sep 17 00:00:00 2001 From: Eric Wing Date: Sun, 18 May 2014 03:43:47 -0700 Subject: JavaScriptCore: ConvertPtr should allow JavaScript null to be a valid value. It is common in C to accept NULL to functions for pointer parameters. extern void DoSomething(struct Foo* foo); ... DoSomething(NULL); Thus, JavaScript null should be allowed: module.DoSomething(null); But the current ConvertPtr definition accepts only objects. This modifies it to allow null. --- Lib/javascript/jsc/javascriptrun.swg | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/Lib/javascript/jsc/javascriptrun.swg b/Lib/javascript/jsc/javascriptrun.swg index 813c7deb4..9655b0eb6 100644 --- a/Lib/javascript/jsc/javascriptrun.swg +++ b/Lib/javascript/jsc/javascriptrun.swg @@ -129,6 +129,13 @@ SWIGRUNTIME int SWIG_JSC_ConvertInstancePtr(JSContextRef context, JSObjectRef ob SWIGRUNTIME int SWIG_JSC_ConvertPtr(JSContextRef context, JSValueRef valRef, void** ptr, swig_type_info *info, int flags) { JSObjectRef objRef; + + /* special case: JavaScript null => C NULL pointer */ + if(JSValueIsNull(context, valRef)) { + *ptr=0; + return SWIG_OK; + } + if(!JSValueIsObject(context, valRef)) { return SWIG_TypeError; } -- cgit v1.2.1 From 7824322b146f67590c1a460f88379bce3a7d4d58 Mon Sep 17 00:00:00 2001 From: Oliver Buchtala Date: Sun, 18 May 2014 22:40:22 +0200 Subject: Javascript: fix warnings in li_std_string test. Old typemaps for std::string were in place instead of delegating to UTL. --- Lib/javascript/jsc/std_string.i | 70 +----------------------------------- Lib/javascript/v8/std_string.i | 80 +---------------------------------------- 2 files changed, 2 insertions(+), 148 deletions(-) diff --git a/Lib/javascript/jsc/std_string.i b/Lib/javascript/jsc/std_string.i index fb1bd62b5..dc1378ae6 100644 --- a/Lib/javascript/jsc/std_string.i +++ b/Lib/javascript/jsc/std_string.i @@ -1,69 +1 @@ -/* ----------------------------------------------------------------------------- - * std_string.i - * - * Typemaps for const std::string&. - * To use non-const std::string references use the following %apply: - * %apply const std::string & {std::string &}; - * - * ----------------------------------------------------------------------------- */ - -%{ -#include - -std::string SWIGJSC_valueToString(JSContextRef context, JSValueRef value) { - JSStringRef jsstring = JSValueToStringCopy(context, value, /* JSValueRef *exception */ 0); - unsigned int length = JSStringGetLength(jsstring); - char *cstr = new char[length + 1]; - JSStringGetUTF8CString(jsstring, cstr, length + 1); - - // create a copy - std::string result(cstr); - - JSStringRelease(jsstring); - delete[] cstr; - - return result; -} - -JSValueRef SWIGJSC_stringToValue(JSContextRef context, const std::string& s) -{ - JSValueRef result; - JSStringRef jsstring = JSStringCreateWithUTF8CString(s.c_str()); - result = JSValueMakeString(context, jsstring); - JSStringRelease(jsstring); - return result; -} -%} - -namespace std { - %naturalvar string; - - class string; - - - %typemap(in) string - %{ - $1 = SWIGJSC_valueToString(context, $input); - %} - - %typemap(in) const string & - %{ - $1 = new std::string(SWIGJSC_valueToString(context, $input)); - %} - - %typemap(freearg) const string & - %{ - delete $1; - %} - - %typemap(out) string - %{ - $result = SWIGJSC_stringToValue(context, $1); - %} - - %typemap(out) const string & - %{ - $result = SWIGJSC_stringToValue(context, *$1); - %} - -} +%include diff --git a/Lib/javascript/v8/std_string.i b/Lib/javascript/v8/std_string.i index 5ad1ead27..dc1378ae6 100644 --- a/Lib/javascript/v8/std_string.i +++ b/Lib/javascript/v8/std_string.i @@ -1,79 +1 @@ -/* ----------------------------------------------------------------------------- - * std_string.i - * - * Typemaps for std::string and const std::string&. - * - * To use non-const std::string references use the following %apply: - * %apply const std::string & {std::string &}; - * - * ----------------------------------------------------------------------------- */ - -%{ -#include -%} - -%fragment("SWIGV8_valueToString", "header", fragment="SWIG_AsCharPtrAndSize") { -std::string* SWIGV8_valueToStringPtr(v8::Handle val) { - - if (!val->IsString()) return 0; - - int alloc; - size_t size; - char* chars; - int res = SWIG_AsCharPtrAndSize(val, &chars, &size, &alloc); - - if(res != SWIG_OK) { - v8::ThrowException(v8::Exception::TypeError(v8::String::New("Could not convert to string."))); - return 0; - } - - // copies the data (again) - std::string *str = new std::string(chars); - - if (alloc) delete[] chars; - - return str; -} -} - -%fragment("SWIGV8_stringToValue", "header", fragment="SWIG_FromCharPtrAndSize") { -v8::Handle SWIGV8_stringToValue(const std::string &str) { - return SWIG_FromCharPtrAndSize(str.c_str(), str.length()); -} -} - -namespace std { - %naturalvar string; - - class string; - - %typemap(in, fragment="SWIGV8_valueToString") string (std::string* tmp) - %{ - tmp = SWIGV8_valueToStringPtr($input); - $1 = *tmp; - if (tmp == 0) { v8::ThrowException(v8::Exception::TypeError(v8::String::New("Null pointer."))); goto fail; } - if (tmp) delete tmp; - %} - - %typemap(in, fragment="SWIGV8_valueToString") const string & - %{ - $1 = SWIGV8_valueToStringPtr($input); - if ($1 == 0) { v8::ThrowException(v8::Exception::TypeError(v8::String::New("Null pointer."))); goto fail; } - %} - - %typemap(freearg) const string & - %{ - if ($1) delete $1; - %} - - %typemap(out, fragment="SWIGV8_stringToValue") string - %{ - $result = SWIGV8_stringToValue($1); - %} - - %typemap(out, fragment="SWIGV8_stringToValue") const string & - %{ - $result = SWIGV8_stringToValue(*$1); - %} - -} +%include -- cgit v1.2.1 From d2ab75f9071ae15d98dbf091f6461ef397d66ef5 Mon Sep 17 00:00:00 2001 From: Vladimir Kalinin Date: Mon, 19 May 2014 02:05:23 +0400 Subject: obscure case workaround in std::set wrapper, where ignored type still need to be processed --- Source/Modules/typepass.cxx | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/Source/Modules/typepass.cxx b/Source/Modules/typepass.cxx index ec6f64587..3e323f910 100644 --- a/Source/Modules/typepass.cxx +++ b/Source/Modules/typepass.cxx @@ -661,15 +661,15 @@ class TypePass:private Dispatcher { * ------------------------------------------------------------ */ virtual int cDeclaration(Node *n) { - if (GetFlag(n, "feature:ignore")) { - return SWIG_OK; - } if (NoExcept) { Delattr(n, "throws"); } /* Normalize types. */ SwigType *ty = Getattr(n, "type"); + if (!ty) { + return SWIG_OK; + } normalize_type(ty); SwigType *decl = Getattr(n, "decl"); if (decl) { -- cgit v1.2.1 From 0c42158723ad29ddd199fc1eeb959bf777f7062f Mon Sep 17 00:00:00 2001 From: Oliver Buchtala Date: Mon, 19 May 2014 00:20:19 +0200 Subject: Javascript: preparations for using Language::getNSpace(). --- Source/Modules/javascript.cxx | 24 ++++++++++++++++++++++-- 1 file changed, 22 insertions(+), 2 deletions(-) diff --git a/Source/Modules/javascript.cxx b/Source/Modules/javascript.cxx index 20af76f9f..e535bc179 100644 --- a/Source/Modules/javascript.cxx +++ b/Source/Modules/javascript.cxx @@ -318,6 +318,10 @@ public: **/ virtual int fragmentDirective(Node *n); +public: + + virtual String *getNSpace() const; + private: JSEmitter *emitter; @@ -467,6 +471,10 @@ int JAVASCRIPT::fragmentDirective(Node *n) { return SWIG_OK; } +String *JAVASCRIPT::getNSpace() const { + return Language::getNSpace(); +} + /* --------------------------------------------------------------------- * top() * @@ -1346,14 +1354,26 @@ int JSEmitter::switchNamespace(Node *n) { return SWIG_OK; } - String *nspace = Getattr(n, "sym:nspace"); - // if nspace is deactivated, everything goes into the global scope if (!GetFlag(n, "feature:nspace")) { current_namespace = Getattr(namespaces, "::"); return SWIG_OK; } +// EXPERIMENTAL: we want to use Language::getNSpace() here +// However, it is not working yet. +// For namespace functions Language::getNSpace() does not give a valid result +#if 0 + JAVASCRIPT *lang = static_cast(Language::instance()); + String *_nspace = lang->getNSpace(); + if (!Equal(nspace, _nspace)) { + Printf(stdout, "##### Custom vs Language::getNSpace(): %s | %s\n", nspace, _nspace); + Swig_print_node(n); + } +#endif + + String *nspace = Getattr(n, "sym:nspace"); + if (nspace == NULL) { // It seems that only classes have 'sym:nspace' set. // We try to get the namespace from the qualified name (i.e., everything before the last '::') -- cgit v1.2.1 From 11963788e0d008e1c6e997577086cd8dd584c03f Mon Sep 17 00:00:00 2001 From: Oliver Buchtala Date: Mon, 19 May 2014 00:21:21 +0200 Subject: Javascript: support null pointers. We allow to set pointer types using JS null. --- Examples/test-suite/javascript/null_pointer_runme.js | 9 +++++++++ Lib/javascript/jsc/javascriptrun.swg | 18 +++++++++++++----- Lib/javascript/v8/javascriptrun.swg | 12 ++++++++++-- 3 files changed, 32 insertions(+), 7 deletions(-) create mode 100644 Examples/test-suite/javascript/null_pointer_runme.js diff --git a/Examples/test-suite/javascript/null_pointer_runme.js b/Examples/test-suite/javascript/null_pointer_runme.js new file mode 100644 index 000000000..7c0d61244 --- /dev/null +++ b/Examples/test-suite/javascript/null_pointer_runme.js @@ -0,0 +1,9 @@ +var null_pointer = require("null_pointer"); + +if (!null_pointer.func(null)) { + throw new Error("Javascript 'null' should be converted into NULL."); +} + +if (null_pointer.getnull() != null) { + throw new Error("NULL should be converted into Javascript 'null'."); +} diff --git a/Lib/javascript/jsc/javascriptrun.swg b/Lib/javascript/jsc/javascriptrun.swg index 9655b0eb6..1ff10a183 100644 --- a/Lib/javascript/jsc/javascriptrun.swg +++ b/Lib/javascript/jsc/javascriptrun.swg @@ -99,7 +99,9 @@ SWIGRUNTIME JSClassRef _SwigObject_classRef; SWIGRUNTIME int SWIG_JSC_ConvertInstancePtr(JSContextRef context, JSObjectRef objRef, void** ptr, swig_type_info *info, int flags) { - SwigPrivData *cdata = (SwigPrivData *) JSObjectGetPrivate(objRef); + SwigPrivData *cdata; + + cdata = (SwigPrivData *) JSObjectGetPrivate(objRef); if(cdata == NULL) { return SWIG_ERROR; } @@ -135,7 +137,7 @@ SWIGRUNTIME int SWIG_JSC_ConvertPtr(JSContextRef context, JSValueRef valRef, voi *ptr=0; return SWIG_OK; } - + if(!JSValueIsObject(context, valRef)) { return SWIG_TypeError; } @@ -149,17 +151,23 @@ SWIGRUNTIME int SWIG_JSC_ConvertPtr(JSContextRef context, JSValueRef valRef, voi } SWIGRUNTIME JSObjectRef SWIG_JSC_NewPointerObj(JSContextRef context, void *ptr, swig_type_info *info, int flags) { - JSClassRef classRef; + JSObjectRef result; + SwigPrivData *cdata; + + if (ptr == NULL) { + return JSValueToObject(context, JSValueMakeNull(context), 0); + } + if(info->clientdata == NULL) { classRef = _SwigObject_classRef; } else { classRef = (JSClassRef) info->clientdata; } - JSObjectRef result = JSObjectMake(context, classRef, NULL); + result = JSObjectMake(context, classRef, NULL); - SwigPrivData* cdata = (SwigPrivData*) malloc(sizeof(SwigPrivData)); + cdata = (SwigPrivData*) malloc(sizeof(SwigPrivData)); cdata->swigCObject = ptr; cdata->swigCMemOwn = (flags & SWIG_POINTER_OWN) ? 1 : 0; cdata->info = info; diff --git a/Lib/javascript/v8/javascriptrun.swg b/Lib/javascript/v8/javascriptrun.swg index 2e0a46717..f200f1520 100644 --- a/Lib/javascript/v8/javascriptrun.swg +++ b/Lib/javascript/v8/javascriptrun.swg @@ -220,7 +220,11 @@ void SWIGV8_SetPrivateData(v8::Handle obj, void* ptr, swig_type_info int SWIG_V8_ConvertPtr(v8::Handle valRef, void** ptr, swig_type_info *info, int flags) { v8::HandleScope scope; - + /* special case: JavaScript null => C NULL pointer */ + if(valRef->IsNull()) { + *ptr=0; + return SWIG_OK; + } if(!valRef->IsObject()) { return SWIG_TypeError; } @@ -228,10 +232,14 @@ int SWIG_V8_ConvertPtr(v8::Handle valRef, void** ptr, swig_type_info return SWIG_V8_ConvertInstancePtr(objRef, ptr, info, flags); } -v8::Handle SWIG_V8_NewPointerObj(void *ptr, swig_type_info *info, int flags) { +v8::Handle SWIG_V8_NewPointerObj(void *ptr, swig_type_info *info, int flags) { v8::HandleScope scope; v8::Handle class_templ; + if (ptr == NULL) { + return scope.Close(v8::Null()); + } + #if (SWIG_V8_VERSION < 0x031900) if(info->clientdata != 0) { class_templ = ((SWIGV8_ClientData*) info->clientdata)->class_templ; -- cgit v1.2.1 From 243671700fd8ac0e18880962c19bf10cf4d91e1b Mon Sep 17 00:00:00 2001 From: William S Fulton Date: Sun, 18 May 2014 23:09:58 +0100 Subject: Fix li_boost_intrusive_ptr for various versions of boost Modify testcase to fix compile errors on various versions of boost. Tested using various combinations from boost-1.33/gcc-3.4.2 to boost-1.53/gcc-4.7.3. Originally noticed as broken on boost-1.36/gcc-4.3.4 on SLE 11. Add in some diagnostics when reference count is wrong... which does still happen occasionally. --- .../java/li_boost_intrusive_ptr_runme.java | 20 +++++++++++--------- Examples/test-suite/li_boost_intrusive_ptr.i | 15 ++++++++++++--- 2 files changed, 23 insertions(+), 12 deletions(-) diff --git a/Examples/test-suite/java/li_boost_intrusive_ptr_runme.java b/Examples/test-suite/java/li_boost_intrusive_ptr_runme.java index 530008a87..750ec5067 100644 --- a/Examples/test-suite/java/li_boost_intrusive_ptr_runme.java +++ b/Examples/test-suite/java/li_boost_intrusive_ptr_runme.java @@ -33,7 +33,7 @@ public class li_boost_intrusive_ptr_runme { // Change loop count to run for a long time to monitor memory final int loopCount = 5000; //5000; for (int i=0; i #include #include -template void intrusive_ptr_add_ref(const T* r) { r->addref(); } -template void intrusive_ptr_release(const T* r) { r->release(); } - // Uncomment macro below to turn on intrusive_ptr memory leak checking as described above //#define INTRUSIVE_PTR_WRAPPER @@ -132,6 +135,8 @@ struct Klass { void release(void) const { if (--count == 0) delete this; } int use_count(void) const { return count; } static long getTotal_count() { return total_count; } + friend void intrusive_ptr_add_ref(const Klass* r) { r->addref(); } + friend void intrusive_ptr_release(const Klass* r) { r->release(); } private: static void increment() { ++total_count; if (debug_shared) cout << " ++xxxxx Klass::increment tot: " << total_count << endl;} @@ -177,6 +182,8 @@ struct IgnoredRefCountingBase { void addref(void) const { ++count; } void release(void) const { if (--count == 0) delete this; } int use_count(void) const { return count; } + inline friend void intrusive_ptr_add_ref(const IgnoredRefCountingBase* r) { r->addref(); } + inline friend void intrusive_ptr_release(const IgnoredRefCountingBase* r) { r->release(); } static long getTotal_count() { return total_count; } private: @@ -414,6 +421,8 @@ template struct Base { void addref(void) const { count++; } void release(void) const { if (--count == 0) delete this; } int use_count(void) const { return count; } + inline friend void intrusive_ptr_add_ref(const Base* r) { r->addref(); } + inline friend void intrusive_ptr_release(const Base* r) { r->release(); } }; %} -- cgit v1.2.1 From a64549034c5579a148c37c7f3e070c8704dca459 Mon Sep 17 00:00:00 2001 From: Oliver Buchtala Date: Mon, 19 May 2014 00:58:32 +0200 Subject: Javascript: generalise test-case 'typemap_variables' so that it can be used for Javascript V8. The original version contains output typemaps that produced incompatible code. Introduce a pre-processor macro that is set to a valid value for v8. --- Examples/test-suite/javascript/Makefile.in | 8 -------- Examples/test-suite/typemap_variables.i | 27 +++++++++++++++++++-------- 2 files changed, 19 insertions(+), 16 deletions(-) diff --git a/Examples/test-suite/javascript/Makefile.in b/Examples/test-suite/javascript/Makefile.in index fc5255155..be4350d1e 100644 --- a/Examples/test-suite/javascript/Makefile.in +++ b/Examples/test-suite/javascript/Makefile.in @@ -28,14 +28,6 @@ _setup = \ echo "$(ACTION)ing $(LANGUAGE) ($(JSENGINE)) testcase $*" ; \ fi; -ifneq (jsc,$(ENGINE)) - - # This test can not be run with v8 as it uses v8 API incompatible output typemaps - typemap_variables.cpptest: - echo "skipping $(LANGUAGE) ($(JSENGINE)) testcase typemap_variables" ; - -endif - ifeq (node,$(JSENGINE)) SWIGOPT += -v8 -DBUILDING_NODE_EXTENSION=1 diff --git a/Examples/test-suite/typemap_variables.i b/Examples/test-suite/typemap_variables.i index 142e35060..047007a1c 100644 --- a/Examples/test-suite/typemap_variables.i +++ b/Examples/test-suite/typemap_variables.i @@ -13,33 +13,44 @@ %} #endif +// For Javascript V8 we can not use '0' for out typemaps +#if defined(SWIG_JAVASCRIPT_V8) +%header %{ +#define OUT_NULL_VALUE v8::Null() +%} +#else +%header %{ +#define OUT_NULL_VALUE 0 +%} +#endif + // Scripting languages use varin/varout for variables (except non-static member variables where in/out are used ???) %typemap(varin) int "this_will_not_compile_varin " %typemap(varout) int "this_will_not_compile_varout" %typemap(varin) int globul "/*int globul varin */ TYPEMAP_VARIABLES_FAIL" -%typemap(varout) int globul "/*int globul varout*/ $result=0;" +%typemap(varout) int globul "/*int globul varout*/ $result=OUT_NULL_VALUE;" %typemap(varin) int Space::nspace "/*int nspace varin */ TYPEMAP_VARIABLES_FAIL" -%typemap(varout) int Space::nspace "/*int nspace varout*/ $result=0;" +%typemap(varout) int Space::nspace "/*int nspace varout*/ $result=OUT_NULL_VALUE;" //%typemap(varin) int member "/*int member varin */" -//%typemap(varout) int member "/*int member varout*/ $result=0;" +//%typemap(varout) int member "/*int member varout*/ $result=OUT_NULL_VALUE;" %typemap(varin) int Space::Struct::smember "/*int smember varin */ TYPEMAP_VARIABLES_FAIL" -%typemap(varout) int Space::Struct::smember "/*int smember varout*/ $result=0;" +%typemap(varout) int Space::Struct::smember "/*int smember varout*/ $result=OUT_NULL_VALUE;" // Statically typed languages use in/out for variables %typemap(in) int "this_will_not_compile_in " %typemap(out) int "this_will_not_compile_out" %typemap(in) int globul "/*int globul in */ $1=0;" -%typemap(out) int globul "/*int globul out*/ $result=0;" +%typemap(out) int globul "/*int globul out*/ $result=OUT_NULL_VALUE;" %typemap(in) int Space::nspace "/*int nspace in */ $1=0;" -%typemap(out) int Space::nspace "/*int nspace out*/ $result=0;" +%typemap(out) int Space::nspace "/*int nspace out*/ $result=OUT_NULL_VALUE;" %typemap(in) int member "/*int member in */ $1=0;" #ifdef SWIGTCL %typemap(out) int member "/*int member out*/" #else -%typemap(out) int member "/*int member out*/ $result=0;" +%typemap(out) int member "/*int member out*/ $result=OUT_NULL_VALUE;" #endif %typemap(in) int Space::Struct::smember "/*int smember in */ $1=0;" -%typemap(out) int Space::Struct::smember "/*int smember out*/ $result=0;" +%typemap(out) int Space::Struct::smember "/*int smember out*/ $result=OUT_NULL_VALUE;" %typemap(javain) int "this_will_not_compile_javain " %typemap(javaout) int "this_will_not_compile_javaout" -- cgit v1.2.1 From 7cc617a19d2c7834ee877af920a824cd29a92a89 Mon Sep 17 00:00:00 2001 From: Oliver Buchtala Date: Mon, 19 May 2014 11:46:21 +0200 Subject: Revert "Javascript: support null pointers." This reverts commit 11963788e0d008e1c6e997577086cd8dd584c03f. --- Examples/test-suite/javascript/null_pointer_runme.js | 9 --------- Lib/javascript/jsc/javascriptrun.swg | 18 +++++------------- Lib/javascript/v8/javascriptrun.swg | 12 ++---------- 3 files changed, 7 insertions(+), 32 deletions(-) delete mode 100644 Examples/test-suite/javascript/null_pointer_runme.js diff --git a/Examples/test-suite/javascript/null_pointer_runme.js b/Examples/test-suite/javascript/null_pointer_runme.js deleted file mode 100644 index 7c0d61244..000000000 --- a/Examples/test-suite/javascript/null_pointer_runme.js +++ /dev/null @@ -1,9 +0,0 @@ -var null_pointer = require("null_pointer"); - -if (!null_pointer.func(null)) { - throw new Error("Javascript 'null' should be converted into NULL."); -} - -if (null_pointer.getnull() != null) { - throw new Error("NULL should be converted into Javascript 'null'."); -} diff --git a/Lib/javascript/jsc/javascriptrun.swg b/Lib/javascript/jsc/javascriptrun.swg index 1ff10a183..9655b0eb6 100644 --- a/Lib/javascript/jsc/javascriptrun.swg +++ b/Lib/javascript/jsc/javascriptrun.swg @@ -99,9 +99,7 @@ SWIGRUNTIME JSClassRef _SwigObject_classRef; SWIGRUNTIME int SWIG_JSC_ConvertInstancePtr(JSContextRef context, JSObjectRef objRef, void** ptr, swig_type_info *info, int flags) { - SwigPrivData *cdata; - - cdata = (SwigPrivData *) JSObjectGetPrivate(objRef); + SwigPrivData *cdata = (SwigPrivData *) JSObjectGetPrivate(objRef); if(cdata == NULL) { return SWIG_ERROR; } @@ -137,7 +135,7 @@ SWIGRUNTIME int SWIG_JSC_ConvertPtr(JSContextRef context, JSValueRef valRef, voi *ptr=0; return SWIG_OK; } - + if(!JSValueIsObject(context, valRef)) { return SWIG_TypeError; } @@ -151,23 +149,17 @@ SWIGRUNTIME int SWIG_JSC_ConvertPtr(JSContextRef context, JSValueRef valRef, voi } SWIGRUNTIME JSObjectRef SWIG_JSC_NewPointerObj(JSContextRef context, void *ptr, swig_type_info *info, int flags) { - JSClassRef classRef; - JSObjectRef result; - SwigPrivData *cdata; - - if (ptr == NULL) { - return JSValueToObject(context, JSValueMakeNull(context), 0); - } + JSClassRef classRef; if(info->clientdata == NULL) { classRef = _SwigObject_classRef; } else { classRef = (JSClassRef) info->clientdata; } - result = JSObjectMake(context, classRef, NULL); + JSObjectRef result = JSObjectMake(context, classRef, NULL); - cdata = (SwigPrivData*) malloc(sizeof(SwigPrivData)); + SwigPrivData* cdata = (SwigPrivData*) malloc(sizeof(SwigPrivData)); cdata->swigCObject = ptr; cdata->swigCMemOwn = (flags & SWIG_POINTER_OWN) ? 1 : 0; cdata->info = info; diff --git a/Lib/javascript/v8/javascriptrun.swg b/Lib/javascript/v8/javascriptrun.swg index f200f1520..2e0a46717 100644 --- a/Lib/javascript/v8/javascriptrun.swg +++ b/Lib/javascript/v8/javascriptrun.swg @@ -220,11 +220,7 @@ void SWIGV8_SetPrivateData(v8::Handle obj, void* ptr, swig_type_info int SWIG_V8_ConvertPtr(v8::Handle valRef, void** ptr, swig_type_info *info, int flags) { v8::HandleScope scope; - /* special case: JavaScript null => C NULL pointer */ - if(valRef->IsNull()) { - *ptr=0; - return SWIG_OK; - } + if(!valRef->IsObject()) { return SWIG_TypeError; } @@ -232,14 +228,10 @@ int SWIG_V8_ConvertPtr(v8::Handle valRef, void** ptr, swig_type_info return SWIG_V8_ConvertInstancePtr(objRef, ptr, info, flags); } -v8::Handle SWIG_V8_NewPointerObj(void *ptr, swig_type_info *info, int flags) { +v8::Handle SWIG_V8_NewPointerObj(void *ptr, swig_type_info *info, int flags) { v8::HandleScope scope; v8::Handle class_templ; - if (ptr == NULL) { - return scope.Close(v8::Null()); - } - #if (SWIG_V8_VERSION < 0x031900) if(info->clientdata != 0) { class_templ = ((SWIGV8_ClientData*) info->clientdata)->class_templ; -- cgit v1.2.1 From d9bb3a84150990cc9e1980398f3dc7afd2dead79 Mon Sep 17 00:00:00 2001 From: Oliver Buchtala Date: Mon, 19 May 2014 11:46:29 +0200 Subject: Revert "JavaScriptCore: ConvertPtr should allow JavaScript null to be a valid value." This reverts commit 05ed0325dc4bd9ddc126d3dacc6b38686f7382cf. --- Lib/javascript/jsc/javascriptrun.swg | 7 ------- 1 file changed, 7 deletions(-) diff --git a/Lib/javascript/jsc/javascriptrun.swg b/Lib/javascript/jsc/javascriptrun.swg index 9655b0eb6..813c7deb4 100644 --- a/Lib/javascript/jsc/javascriptrun.swg +++ b/Lib/javascript/jsc/javascriptrun.swg @@ -129,13 +129,6 @@ SWIGRUNTIME int SWIG_JSC_ConvertInstancePtr(JSContextRef context, JSObjectRef ob SWIGRUNTIME int SWIG_JSC_ConvertPtr(JSContextRef context, JSValueRef valRef, void** ptr, swig_type_info *info, int flags) { JSObjectRef objRef; - - /* special case: JavaScript null => C NULL pointer */ - if(JSValueIsNull(context, valRef)) { - *ptr=0; - return SWIG_OK; - } - if(!JSValueIsObject(context, valRef)) { return SWIG_TypeError; } -- cgit v1.2.1 From 2471e4ad9f1b6b9f851cf359fd6fd6b9aa34e9b8 Mon Sep 17 00:00:00 2001 From: Oliver Buchtala Date: Mon, 19 May 2014 12:11:15 +0200 Subject: Javascript: Use RUNTOOL for running tests. --- Examples/test-suite/javascript/Makefile.in | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Examples/test-suite/javascript/Makefile.in b/Examples/test-suite/javascript/Makefile.in index be4350d1e..a54fcd7e7 100644 --- a/Examples/test-suite/javascript/Makefile.in +++ b/Examples/test-suite/javascript/Makefile.in @@ -85,7 +85,7 @@ else run_testcase = \ if [ -f $(srcdir)/$*$(SCRIPTSUFFIX) ]; then \ - $(top_builddir)/Tools/javascript/javascript -$(JSENGINE) $(srcdir)/$*$(SCRIPTSUFFIX); \ + $(RUNTOOL) $(top_builddir)/Tools/javascript/javascript -$(JSENGINE) $(srcdir)/$*$(SCRIPTSUFFIX); \ fi %.ctest: -- cgit v1.2.1 From d5ea32d7607c1991ae74293472d73740c90e5db8 Mon Sep 17 00:00:00 2001 From: Eric Wing Date: Sun, 18 May 2014 03:43:47 -0700 Subject: JavaScriptCore: ConvertPtr should allow JavaScript null to be a valid value. It is common in C to accept NULL to functions for pointer parameters. extern void DoSomething(struct Foo* foo); ... DoSomething(NULL); Thus, JavaScript null should be allowed: module.DoSomething(null); But the current ConvertPtr definition accepts only objects. This modifies it to allow null. --- Lib/javascript/jsc/javascriptrun.swg | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/Lib/javascript/jsc/javascriptrun.swg b/Lib/javascript/jsc/javascriptrun.swg index 813c7deb4..9655b0eb6 100644 --- a/Lib/javascript/jsc/javascriptrun.swg +++ b/Lib/javascript/jsc/javascriptrun.swg @@ -129,6 +129,13 @@ SWIGRUNTIME int SWIG_JSC_ConvertInstancePtr(JSContextRef context, JSObjectRef ob SWIGRUNTIME int SWIG_JSC_ConvertPtr(JSContextRef context, JSValueRef valRef, void** ptr, swig_type_info *info, int flags) { JSObjectRef objRef; + + /* special case: JavaScript null => C NULL pointer */ + if(JSValueIsNull(context, valRef)) { + *ptr=0; + return SWIG_OK; + } + if(!JSValueIsObject(context, valRef)) { return SWIG_TypeError; } -- cgit v1.2.1 From 3f0f58889131baacb23583a7deb35d9394bfc141 Mon Sep 17 00:00:00 2001 From: Oliver Buchtala Date: Mon, 19 May 2014 00:21:21 +0200 Subject: Javascript: support null pointers. We allow to set pointer types using JS null. --- Examples/test-suite/javascript/null_pointer_runme.js | 9 +++++++++ Lib/javascript/jsc/javascriptrun.swg | 18 +++++++++++++----- Lib/javascript/v8/javascriptrun.swg | 12 ++++++++++-- 3 files changed, 32 insertions(+), 7 deletions(-) create mode 100644 Examples/test-suite/javascript/null_pointer_runme.js diff --git a/Examples/test-suite/javascript/null_pointer_runme.js b/Examples/test-suite/javascript/null_pointer_runme.js new file mode 100644 index 000000000..7c0d61244 --- /dev/null +++ b/Examples/test-suite/javascript/null_pointer_runme.js @@ -0,0 +1,9 @@ +var null_pointer = require("null_pointer"); + +if (!null_pointer.func(null)) { + throw new Error("Javascript 'null' should be converted into NULL."); +} + +if (null_pointer.getnull() != null) { + throw new Error("NULL should be converted into Javascript 'null'."); +} diff --git a/Lib/javascript/jsc/javascriptrun.swg b/Lib/javascript/jsc/javascriptrun.swg index 9655b0eb6..1ff10a183 100644 --- a/Lib/javascript/jsc/javascriptrun.swg +++ b/Lib/javascript/jsc/javascriptrun.swg @@ -99,7 +99,9 @@ SWIGRUNTIME JSClassRef _SwigObject_classRef; SWIGRUNTIME int SWIG_JSC_ConvertInstancePtr(JSContextRef context, JSObjectRef objRef, void** ptr, swig_type_info *info, int flags) { - SwigPrivData *cdata = (SwigPrivData *) JSObjectGetPrivate(objRef); + SwigPrivData *cdata; + + cdata = (SwigPrivData *) JSObjectGetPrivate(objRef); if(cdata == NULL) { return SWIG_ERROR; } @@ -135,7 +137,7 @@ SWIGRUNTIME int SWIG_JSC_ConvertPtr(JSContextRef context, JSValueRef valRef, voi *ptr=0; return SWIG_OK; } - + if(!JSValueIsObject(context, valRef)) { return SWIG_TypeError; } @@ -149,17 +151,23 @@ SWIGRUNTIME int SWIG_JSC_ConvertPtr(JSContextRef context, JSValueRef valRef, voi } SWIGRUNTIME JSObjectRef SWIG_JSC_NewPointerObj(JSContextRef context, void *ptr, swig_type_info *info, int flags) { - JSClassRef classRef; + JSObjectRef result; + SwigPrivData *cdata; + + if (ptr == NULL) { + return JSValueToObject(context, JSValueMakeNull(context), 0); + } + if(info->clientdata == NULL) { classRef = _SwigObject_classRef; } else { classRef = (JSClassRef) info->clientdata; } - JSObjectRef result = JSObjectMake(context, classRef, NULL); + result = JSObjectMake(context, classRef, NULL); - SwigPrivData* cdata = (SwigPrivData*) malloc(sizeof(SwigPrivData)); + cdata = (SwigPrivData*) malloc(sizeof(SwigPrivData)); cdata->swigCObject = ptr; cdata->swigCMemOwn = (flags & SWIG_POINTER_OWN) ? 1 : 0; cdata->info = info; diff --git a/Lib/javascript/v8/javascriptrun.swg b/Lib/javascript/v8/javascriptrun.swg index 2e0a46717..f200f1520 100644 --- a/Lib/javascript/v8/javascriptrun.swg +++ b/Lib/javascript/v8/javascriptrun.swg @@ -220,7 +220,11 @@ void SWIGV8_SetPrivateData(v8::Handle obj, void* ptr, swig_type_info int SWIG_V8_ConvertPtr(v8::Handle valRef, void** ptr, swig_type_info *info, int flags) { v8::HandleScope scope; - + /* special case: JavaScript null => C NULL pointer */ + if(valRef->IsNull()) { + *ptr=0; + return SWIG_OK; + } if(!valRef->IsObject()) { return SWIG_TypeError; } @@ -228,10 +232,14 @@ int SWIG_V8_ConvertPtr(v8::Handle valRef, void** ptr, swig_type_info return SWIG_V8_ConvertInstancePtr(objRef, ptr, info, flags); } -v8::Handle SWIG_V8_NewPointerObj(void *ptr, swig_type_info *info, int flags) { +v8::Handle SWIG_V8_NewPointerObj(void *ptr, swig_type_info *info, int flags) { v8::HandleScope scope; v8::Handle class_templ; + if (ptr == NULL) { + return scope.Close(v8::Null()); + } + #if (SWIG_V8_VERSION < 0x031900) if(info->clientdata != 0) { class_templ = ((SWIGV8_ClientData*) info->clientdata)->class_templ; -- cgit v1.2.1 From 61b7da1671f5d88127eae0cde4561cd7883c825b Mon Sep 17 00:00:00 2001 From: Oliver Buchtala Date: Mon, 19 May 2014 15:59:14 +0200 Subject: JavascriptCore: Bugfix for null-pointer support. This solution must be considered as a preliminary workaround. --- Lib/javascript/jsc/javascriptrun.swg | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/Lib/javascript/jsc/javascriptrun.swg b/Lib/javascript/jsc/javascriptrun.swg index 1ff10a183..ae1567e87 100644 --- a/Lib/javascript/jsc/javascriptrun.swg +++ b/Lib/javascript/jsc/javascriptrun.swg @@ -156,7 +156,11 @@ SWIGRUNTIME JSObjectRef SWIG_JSC_NewPointerObj(JSContextRef context, void *ptr, SwigPrivData *cdata; if (ptr == NULL) { - return JSValueToObject(context, JSValueMakeNull(context), 0); + // HACK: it is not possible to use JSValueToObject (causing seg-fault) + // This static cast turned out to be a workaround + // In future, we should change the interface of this method + // to return JSValueRef instead of JSObjectRef. + return (JSObjectRef) JSValueMakeNull(context); } if(info->clientdata == NULL) { -- cgit v1.2.1 From 71e72c45ed89457e2a17f412219d37aad67040be Mon Sep 17 00:00:00 2001 From: William S Fulton Date: Wed, 21 May 2014 19:16:15 +0100 Subject: Create separate extetnd.c file for handling extensions / %extend This is just a simple code refactor, moving and function renaming to remove the %extend code out of the parser into its own file now that it isn't just used in the parser. --- Source/CParse/cparse.h | 2 +- Source/CParse/parser.y | 177 +++++++++------------------------------------- Source/CParse/util.c | 14 ++++ Source/Makefile.am | 1 + Source/Modules/main.cxx | 3 +- Source/Modules/nested.cxx | 16 ++--- Source/Swig/extend.c | 141 ++++++++++++++++++++++++++++++++++++ Source/Swig/swig.h | 7 ++ 8 files changed, 204 insertions(+), 157 deletions(-) create mode 100644 Source/Swig/extend.c diff --git a/Source/CParse/cparse.h b/Source/CParse/cparse.h index 6d7342a45..5a0d52d23 100644 --- a/Source/CParse/cparse.h +++ b/Source/CParse/cparse.h @@ -59,7 +59,7 @@ extern "C" { extern void cparse_normalize_void(Node *); extern Parm *Swig_cparse_parm(String *s); extern ParmList *Swig_cparse_parms(String *s, Node *file_line_node); - + extern Node *new_node(const_String_or_char_ptr tag); /* templ.c */ extern int Swig_cparse_template_expand(Node *n, String *rname, ParmList *tparms, Symtab *tscope); diff --git a/Source/CParse/parser.y b/Source/CParse/parser.y index a1a62cb62..4ce8f0e6d 100644 --- a/Source/CParse/parser.y +++ b/Source/CParse/parser.y @@ -41,7 +41,6 @@ int yyparse(); static Node *top = 0; /* Top of the generated parse tree */ static int unnamed = 0; /* Unnamed datatype counter */ -Hash *extendhash = 0; /* Hash table of added methods */ static Hash *classes = 0; /* Hash table of classes */ static Hash *classes_typedefs = 0; /* Hash table of typedef classes: typedef struct X {...} Y; */ static Symtab *prev_symtab = 0; @@ -71,14 +70,6 @@ static void yyerror (const char *e) { (void)e; } -static Node *new_node(const_String_or_char_ptr tag) { - Node *n = NewHash(); - set_nodeType(n,tag); - Setfile(n,cparse_file); - Setline(n,cparse_line); - return n; -} - /* Copies a node. Does not copy tree links or symbol table data (except for sym:name) */ @@ -650,106 +641,6 @@ static void add_symbols_copy(Node *n) { } } -/* Extension merge. This function is used to handle the %extend directive - when it appears before a class definition. To handle this, the %extend - actually needs to take precedence. Therefore, we will selectively nuke symbols - from the current symbol table, replacing them with the added methods */ - -void merge_extensions(Node *cls, Node *am) { - Node *n; - Node *csym; - - n = firstChild(am); - while (n) { - String *symname; - if (Strcmp(nodeType(n),"constructor") == 0) { - symname = Getattr(n,"sym:name"); - if (symname) { - if (Strcmp(symname,Getattr(n,"name")) == 0) { - /* If the name and the sym:name of a constructor are the same, - then it hasn't been renamed. However---the name of the class - itself might have been renamed so we need to do a consistency - check here */ - if (Getattr(cls,"sym:name")) { - Setattr(n,"sym:name", Getattr(cls,"sym:name")); - } - } - } - } - - symname = Getattr(n,"sym:name"); - DohIncref(symname); - if ((symname) && (!Getattr(n,"error"))) { - /* Remove node from its symbol table */ - Swig_symbol_remove(n); - csym = Swig_symbol_add(symname,n); - if (csym != n) { - /* Conflict with previous definition. Nuke previous definition */ - String *e = NewStringEmpty(); - String *en = NewStringEmpty(); - String *ec = NewStringEmpty(); - Printf(ec,"Identifier '%s' redefined by %%extend (ignored),",symname); - Printf(en,"%%extend definition of '%s'.",symname); - SWIG_WARN_NODE_BEGIN(n); - Swig_warning(WARN_PARSE_REDEFINED,Getfile(csym),Getline(csym),"%s\n",ec); - Swig_warning(WARN_PARSE_REDEFINED,Getfile(n),Getline(n),"%s\n",en); - SWIG_WARN_NODE_END(n); - Printf(e,"%s:%d:%s\n%s:%d:%s\n",Getfile(csym),Getline(csym),ec, - Getfile(n),Getline(n),en); - Setattr(csym,"error",e); - Delete(e); - Delete(en); - Delete(ec); - Swig_symbol_remove(csym); /* Remove class definition */ - Swig_symbol_add(symname,n); /* Insert extend definition */ - } - } - n = nextSibling(n); - } -} - -void append_previous_extension(Node *cls, Node *am) { - Node *n, *ne; - Node *pe = 0; - Node *ae = 0; - - if (!am) return; - - n = firstChild(am); - while (n) { - ne = nextSibling(n); - set_nextSibling(n,0); - /* typemaps and fragments need to be prepended */ - if (((Cmp(nodeType(n),"typemap") == 0) || (Cmp(nodeType(n),"fragment") == 0))) { - if (!pe) pe = new_node("extend"); - appendChild(pe, n); - } else { - if (!ae) ae = new_node("extend"); - appendChild(ae, n); - } - n = ne; - } - if (pe) prependChild(cls,pe); - if (ae) appendChild(cls,ae); -} - - -/* Check for unused %extend. Special case, don't report unused - extensions for templates */ - -void check_extensions() { - Iterator ki; - - if (!extendhash) return; - for (ki = First(extendhash); ki.key; ki = Next(ki)) { - if (!Strchr(ki.key,'<')) { - SWIG_WARN_NODE_BEGIN(ki.item); - Swig_warning(WARN_PARSE_EXTEND_UNDEF,Getfile(ki.item), Getline(ki.item), "%%extend defined for an undeclared class %s.\n", SwigType_namestr(ki.key)); - SWIG_WARN_NODE_END(ki.item); - } - } -} - /* Check a set of declarations to see if any are pure-abstract */ static List *pure_abstracts(Node *n) { @@ -1682,14 +1573,13 @@ extend_directive : EXTEND options idcolon LBRACE { cplus_mode = CPLUS_PUBLIC; if (!classes) classes = NewHash(); if (!classes_typedefs) classes_typedefs = NewHash(); - if (!extendhash) extendhash = NewHash(); clsname = make_class_name($3); cls = Getattr(classes,clsname); if (!cls) { cls = Getattr(classes_typedefs, clsname); if (!cls) { /* No previous definition. Create a new scope */ - Node *am = Getattr(extendhash,clsname); + Node *am = Getattr(Swig_extend_hash(),clsname); if (!am) { Swig_symbol_newscope(); Swig_symbol_setscopename($3); @@ -1735,13 +1625,13 @@ extend_directive : EXTEND options idcolon LBRACE { appendChild(current_class,$$); } else { /* We store the extensions in the extensions hash */ - Node *am = Getattr(extendhash,clsname); + Node *am = Getattr(Swig_extend_hash(),clsname); if (am) { /* Append the members to the previous extend methods */ appendChild(am,$6); } else { appendChild($$,$6); - Setattr(extendhash,clsname,$$); + Setattr(Swig_extend_hash(),clsname,$$); } } current_class = 0; @@ -2824,8 +2714,7 @@ template_directive: SWIGTEMPLATE LPAREN idstringopt RPAREN idcolonnt LESSTHAN va /* !!! This may be broken. We may have to add the %extend methods at the beginning of the class */ - - if (extendhash) { + { String *stmp = 0; String *clsname; Node *am; @@ -2834,32 +2723,32 @@ template_directive: SWIGTEMPLATE LPAREN idstringopt RPAREN idcolonnt LESSTHAN va } else { clsname = Getattr(templnode,"name"); } - am = Getattr(extendhash,clsname); + am = Getattr(Swig_extend_hash(),clsname); if (am) { Symtab *st = Swig_symbol_current(); Swig_symbol_setscope(Getattr(templnode,"symtab")); /* Printf(stdout,"%s: %s %p %p\n", Getattr(templnode,"name"), clsname, Swig_symbol_current(), Getattr(templnode,"symtab")); */ - merge_extensions(templnode,am); + Swig_extend_merge(templnode,am); Swig_symbol_setscope(st); - append_previous_extension(templnode,am); - Delattr(extendhash,clsname); + Swig_extend_append_previous(templnode,am); + Delattr(Swig_extend_hash(),clsname); } if (stmp) Delete(stmp); } + /* Add to classes hash */ - if (!classes) classes = NewHash(); + if (!classes) + classes = NewHash(); - { - if (Namespaceprefix) { - String *temp = NewStringf("%s::%s", Namespaceprefix, Getattr(templnode,"name")); - Setattr(classes,temp,templnode); - Delete(temp); - } else { - String *qs = Swig_symbol_qualifiedscopename(templnode); - Setattr(classes, qs,templnode); - Delete(qs); - } - } + if (Namespaceprefix) { + String *temp = NewStringf("%s::%s", Namespaceprefix, Getattr(templnode,"name")); + Setattr(classes,temp,templnode); + Delete(temp); + } else { + String *qs = Swig_symbol_qualifiedscopename(templnode); + Setattr(classes, qs,templnode); + Delete(qs); + } } } @@ -3571,13 +3460,12 @@ cpp_class_decl : storage_class cpptype idcolon inherit LBRACE { Setattr($$,"abstracts", pure_abstracts($7)); /* This bit of code merges in a previously defined %extend directive (if any) */ - - if (extendhash) { + { String *clsname = Swig_symbol_qualifiedscopename(0); - am = Getattr(extendhash, clsname); + am = Getattr(Swig_extend_hash(), clsname); if (am) { - merge_extensions($$, am); - Delattr(extendhash, clsname); + Swig_extend_merge($$, am); + Delattr(Swig_extend_hash(), clsname); } Delete(clsname); } @@ -3588,7 +3476,7 @@ cpp_class_decl : storage_class cpptype idcolon inherit LBRACE { appendChild($$, $7); if (am) - append_previous_extension($$, am); + Swig_extend_append_previous($$, am); p = $9; if (p && !nscope_inner) { @@ -3787,15 +3675,16 @@ cpp_class_decl : storage_class cpptype idcolon inherit LBRACE { n = nextSibling(n); } n = $8; - /* Check for previous extensions */ - if (extendhash) { + + /* Check for previous extensions */ + { String *clsname = Swig_symbol_qualifiedscopename(0); - Node *am = Getattr(extendhash,clsname); + Node *am = Getattr(Swig_extend_hash(),clsname); if (am) { - /* Merge the extension into the symbol table */ - merge_extensions($$,am); - append_previous_extension($$,am); - Delattr(extendhash,clsname); + /* Merge the extension into the symbol table */ + Swig_extend_merge($$,am); + Swig_extend_append_previous($$,am); + Delattr(Swig_extend_hash(),clsname); } Delete(clsname); } diff --git a/Source/CParse/util.c b/Source/CParse/util.c index 7572dff10..320671d9a 100644 --- a/Source/CParse/util.c +++ b/Source/CParse/util.c @@ -88,3 +88,17 @@ void cparse_normalize_void(Node *n) { } } } + +/* ----------------------------------------------------------------------------- + * new_node() + * + * Create an empty parse node, setting file and line number information + * ----------------------------------------------------------------------------- */ + +Node *new_node(const_String_or_char_ptr tag) { + Node *n = NewHash(); + set_nodeType(n,tag); + Setfile(n,cparse_file); + Setline(n,cparse_line); + return n; +} diff --git a/Source/Makefile.am b/Source/Makefile.am index d5331cba1..da65b2326 100644 --- a/Source/Makefile.am +++ b/Source/Makefile.am @@ -77,6 +77,7 @@ eswig_SOURCES = CParse/cscanner.c \ Swig/cwrap.c \ Swig/deprecate.c \ Swig/error.c \ + Swig/extend.c \ Swig/fragment.c \ Swig/getopt.c \ Swig/include.c \ diff --git a/Source/Modules/main.cxx b/Source/Modules/main.cxx index d8f20c207..47d0d374b 100644 --- a/Source/Modules/main.cxx +++ b/Source/Modules/main.cxx @@ -198,7 +198,6 @@ static String *external_runtime_name = 0; enum { STAGE1=1, STAGE2=2, STAGE3=4, STAGE4=8, STAGEOVERFLOW=16 }; static List *libfiles = 0; static List *all_output_files = 0; -extern "C" void check_extensions(); /* ----------------------------------------------------------------------------- * check_extension() @@ -1173,7 +1172,7 @@ int SWIG_main(int argc, char *argv[], Language *l) { Printf(stdout, "Processing unnamed structs...\n"); Swig_nested_name_unnamed_c_structs(top); } - check_extensions(); + Swig_extend_unused_check(); if (Verbose) { Printf(stdout, "Processing types...\n"); diff --git a/Source/Modules/nested.cxx b/Source/Modules/nested.cxx index ca1c79a31..9ec52ead1 100644 --- a/Source/Modules/nested.cxx +++ b/Source/Modules/nested.cxx @@ -338,9 +338,7 @@ static void insertNodeAfter(Node *n, Node *c) { set_nextSibling(n, c); set_previousSibling(c, n); } -extern "C" Hash *extendhash; -extern "C" void merge_extensions(Node *cls, Node *am); -extern "C" void append_previous_extension(Node *cls, Node *am); + void Swig_nested_name_unnamed_c_structs(Node *n) { if (!classhash) classhash = Getattr(n, "classes"); @@ -378,13 +376,11 @@ void Swig_nested_name_unnamed_c_structs(Node *n) { decl = nextSibling(decl); } Delete(ty); - if (extendhash) { - if (Node *am = Getattr(extendhash, name)) { - // Merge the extension into the symbol table - merge_extensions(c, am); - append_previous_extension(c, am); - Delattr(extendhash, name); - } + if (Node *am = Getattr(Swig_extend_hash(), name)) { + // Merge the extension into the symbol table + Swig_extend_merge(c, am); + Swig_extend_append_previous(c, am); + Delattr(Swig_extend_hash(), name); } Swig_symbol_setscope(Swig_symbol_global_scope()); add_symbols_c(c); diff --git a/Source/Swig/extend.c b/Source/Swig/extend.c new file mode 100644 index 000000000..30097b434 --- /dev/null +++ b/Source/Swig/extend.c @@ -0,0 +1,141 @@ +/* ----------------------------------------------------------------------------- + * This file is part of SWIG, which is licensed as a whole under version 3 + * (or any later version) of the GNU General Public License. Some additional + * terms also apply to certain portions of SWIG. The full details of the SWIG + * license and copyrights can be found in the LICENSE and COPYRIGHT files + * included with the SWIG source code as distributed by the SWIG developers + * and at http://www.swig.org/legal.html. + * + * extend.c + * + * Extensions support (%extend) + * ----------------------------------------------------------------------------- */ + +#include "swig.h" +#include "cparse.h" + +static Hash *extendhash = 0; /* Hash table of added methods */ + +/* ----------------------------------------------------------------------------- + * Swig_extend_hash() + * + * Access the extend hash + * ----------------------------------------------------------------------------- */ +Hash *Swig_extend_hash(void) { + if (!extendhash) + extendhash = NewHash(); + return extendhash; +} + +/* ----------------------------------------------------------------------------- + * Swig_extend_merge() + * + * Extension merge. This function is used to handle the %extend directive + * when it appears before a class definition. To handle this, the %extend + * actually needs to take precedence. Therefore, we will selectively nuke symbols + * from the current symbol table, replacing them with the added methods. + * ----------------------------------------------------------------------------- */ + +void Swig_extend_merge(Node *cls, Node *am) { + Node *n; + Node *csym; + + n = firstChild(am); + while (n) { + String *symname; + if (Strcmp(nodeType(n),"constructor") == 0) { + symname = Getattr(n,"sym:name"); + if (symname) { + if (Strcmp(symname,Getattr(n,"name")) == 0) { + /* If the name and the sym:name of a constructor are the same, + then it hasn't been renamed. However---the name of the class + itself might have been renamed so we need to do a consistency + check here */ + if (Getattr(cls,"sym:name")) { + Setattr(n,"sym:name", Getattr(cls,"sym:name")); + } + } + } + } + + symname = Getattr(n,"sym:name"); + DohIncref(symname); + if ((symname) && (!Getattr(n,"error"))) { + /* Remove node from its symbol table */ + Swig_symbol_remove(n); + csym = Swig_symbol_add(symname,n); + if (csym != n) { + /* Conflict with previous definition. Nuke previous definition */ + String *e = NewStringEmpty(); + String *en = NewStringEmpty(); + String *ec = NewStringEmpty(); + Printf(ec,"Identifier '%s' redefined by %%extend (ignored),",symname); + Printf(en,"%%extend definition of '%s'.",symname); + SWIG_WARN_NODE_BEGIN(n); + Swig_warning(WARN_PARSE_REDEFINED,Getfile(csym),Getline(csym),"%s\n",ec); + Swig_warning(WARN_PARSE_REDEFINED,Getfile(n),Getline(n),"%s\n",en); + SWIG_WARN_NODE_END(n); + Printf(e,"%s:%d:%s\n%s:%d:%s\n",Getfile(csym),Getline(csym),ec, + Getfile(n),Getline(n),en); + Setattr(csym,"error",e); + Delete(e); + Delete(en); + Delete(ec); + Swig_symbol_remove(csym); /* Remove class definition */ + Swig_symbol_add(symname,n); /* Insert extend definition */ + } + } + n = nextSibling(n); + } +} + +/* ----------------------------------------------------------------------------- + * Swig_extend_append_previous() + * ----------------------------------------------------------------------------- */ + +void Swig_extend_append_previous(Node *cls, Node *am) { + Node *n, *ne; + Node *pe = 0; + Node *ae = 0; + + if (!am) return; + + n = firstChild(am); + while (n) { + ne = nextSibling(n); + set_nextSibling(n,0); + /* typemaps and fragments need to be prepended */ + if (((Cmp(nodeType(n),"typemap") == 0) || (Cmp(nodeType(n),"fragment") == 0))) { + if (!pe) pe = new_node("extend"); + appendChild(pe, n); + } else { + if (!ae) ae = new_node("extend"); + appendChild(ae, n); + } + n = ne; + } + if (pe) prependChild(cls,pe); + if (ae) appendChild(cls,ae); +} + + +/* ----------------------------------------------------------------------------- + * Swig_extend_unused_check() + * + * Check for unused %extend. Special case, don't report unused + * extensions for templates + * ----------------------------------------------------------------------------- */ + +void Swig_extend_unused_check(void) { + Iterator ki; + + if (!extendhash) return; + for (ki = First(extendhash); ki.key; ki = Next(ki)) { + if (!Strchr(ki.key,'<')) { + SWIG_WARN_NODE_BEGIN(ki.item); + Swig_warning(WARN_PARSE_EXTEND_UNDEF,Getfile(ki.item), Getline(ki.item), "%%extend defined for an undeclared class %s.\n", SwigType_namestr(ki.key)); + SWIG_WARN_NODE_END(ki.item); + } + } +} + diff --git a/Source/Swig/swig.h b/Source/Swig/swig.h index 5334a29f0..5ee7f8d95 100644 --- a/Source/Swig/swig.h +++ b/Source/Swig/swig.h @@ -420,6 +420,13 @@ extern int ParmList_is_compactdefargs(ParmList *p); extern void Swig_fragment_emit(String *name); extern void Swig_fragment_clear(String *section); +/* --- Extension support --- */ + + extern Hash *Swig_extend_hash(void); + extern void Swig_extend_merge(Node *cls, Node *am); + extern void Swig_extend_append_previous(Node *cls, Node *am); + extern void Swig_extend_unused_check(void); + /* hacks defined in C++ ! */ extern int Swig_director_mode(void); extern int Swig_director_protected_mode(void); -- cgit v1.2.1 From d9cac664620d282aa423d3f0ef55ab9a677156a4 Mon Sep 17 00:00:00 2001 From: William S Fulton Date: Wed, 21 May 2014 20:04:48 +0100 Subject: Add missing entries into changes files. --- CHANGES.current | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/CHANGES.current b/CHANGES.current index 8b67392b2..e73a91c3f 100644 --- a/CHANGES.current +++ b/CHANGES.current @@ -5,6 +5,18 @@ See the RELEASENOTES file for a summary of changes in each release. Version 3.0.1 (in progress) =========================== +2014-05-18: vkalinin + Bug #175 - Restore %extend to work for unnamed nested structures by using a C + symbol comprising the outer structure name and unnamed variable instance name. + +2014-05-15: kwwette + Add #166 - 'make check' now works out of source. This required te examples to build + out of source. The main languages have been tested - C#, Go, Guile, Java, Javascript, + Lua, Octave, Perl, PHP, Python, Ruby and Tcl. + +2014-05-01: Oliver Buchtala + Javascript support added, see Javascript chapter in the documentation. + 2014-05-01: olly [PHP] The generated __isset() method now returns true for read-only properties. -- cgit v1.2.1 From 9846f3f1eac0835e9d1870f41ea0c03f3006a687 Mon Sep 17 00:00:00 2001 From: Harvey Falcic Date: Wed, 16 Apr 2014 11:13:21 -0400 Subject: Python 3 byte string output: use errors="surrogateescape" ... if available on the version of Python that's in use. This allows obtaining the original byte string (and potentially trying a fallback encoding) if the bytes can't be decoded as UTF-8. Previously, a UnicodeDecodeError would be raised with no way to treat the data as bytes or try another codec. --- Lib/python/pystrings.swg | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/Lib/python/pystrings.swg b/Lib/python/pystrings.swg index f6a4eba8a..2b14547ad 100644 --- a/Lib/python/pystrings.swg +++ b/Lib/python/pystrings.swg @@ -89,7 +89,11 @@ SWIG_FromCharPtrAndSize(const char* carray, size_t size) SWIG_InternalNewPointerObj(%const_cast(carray,char *), pchar_descriptor, 0) : SWIG_Py_Void(); } else { %#if PY_VERSION_HEX >= 0x03000000 +%#if PY_VERSION_HEX >= 0x03010000 + return PyUnicode_DecodeUTF8(carray, %numeric_cast(size,int), "surrogateescape"); +%#else return PyUnicode_FromStringAndSize(carray, %numeric_cast(size,int)); +%#endif %#else return PyString_FromStringAndSize(carray, %numeric_cast(size,int)); %#endif -- cgit v1.2.1 From 791f070e66ee4cf96f0df0a4d00e1fe688f6bb80 Mon Sep 17 00:00:00 2001 From: Harvey Falcic Date: Thu, 22 May 2014 22:53:07 -0400 Subject: Add "unicode_strings" test case for new Python 3 behavior --- Examples/test-suite/common.mk | 1 + Examples/test-suite/python/unicode_strings_runme.py | 4 ++++ Examples/test-suite/unicode_strings.i | 15 +++++++++++++++ 3 files changed, 20 insertions(+) create mode 100644 Examples/test-suite/python/unicode_strings_runme.py create mode 100644 Examples/test-suite/unicode_strings.i diff --git a/Examples/test-suite/common.mk b/Examples/test-suite/common.mk index bfb960fe5..bc1ca5cb8 100644 --- a/Examples/test-suite/common.mk +++ b/Examples/test-suite/common.mk @@ -473,6 +473,7 @@ CPP_TEST_CASES += \ typemap_various \ typename \ types_directive \ + unicode_strings \ union_scope \ using1 \ using2 \ diff --git a/Examples/test-suite/python/unicode_strings_runme.py b/Examples/test-suite/python/unicode_strings_runme.py new file mode 100644 index 000000000..2d26599aa --- /dev/null +++ b/Examples/test-suite/python/unicode_strings_runme.py @@ -0,0 +1,4 @@ +import unicode_strings + +unicode_strings.test_c_str() +unicode_strings.test_std_string() diff --git a/Examples/test-suite/unicode_strings.i b/Examples/test-suite/unicode_strings.i new file mode 100644 index 000000000..f4a8b8b50 --- /dev/null +++ b/Examples/test-suite/unicode_strings.i @@ -0,0 +1,15 @@ +%module unicode_strings + +%include + +%inline %{ + +const char* test_c_str(void) { + return "h\xe9llo"; +} + +std::string test_std_string(void) { + return std::string("h\xe9llo"); +} + +%} -- cgit v1.2.1 From 5fc851a1e0928d5c179c2b9336e76d5e19324d25 Mon Sep 17 00:00:00 2001 From: Harvey Falcic Date: Fri, 23 May 2014 15:24:35 -0400 Subject: Add Python 3 'surrogateescape' documentation --- Doc/Manual/Python.html | 87 ++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 87 insertions(+) diff --git a/Doc/Manual/Python.html b/Doc/Manual/Python.html index bdb1ada30..45725065d 100644 --- a/Doc/Manual/Python.html +++ b/Doc/Manual/Python.html @@ -116,6 +116,7 @@

  • Function annotation
  • Buffer interface
  • Abstract base classes +
  • Byte string output conversion @@ -5928,6 +5929,92 @@ For details of abstract base class, please see PEP 3119.

    +

    35.12.4 Byte string output conversion

    + + +

    +By default, any byte string (char* or std::string) returned +from C or C++ code is decoded to text as UTF-8. This decoding uses the +surrogateescape error handler under Python 3.1 or higher -- this +error handler decodes invalid byte sequences to high surrogate characters +in the range U+DC80 to U+DCFF. + +As an example, consider the following SWIG interface, which exposes a byte +string that cannot be completely decoded as UTF-8: +

    + +
    +%module example
    +
    +%include <std_string.i>
    +
    +%inline %{
    +
    +const char* non_utf8_c_str(void) {
    +        return "h\xe9llo w\xc3\xb6rld";
    +}
    +
    +%}
    +
    + +

    +When this method is called from Python 3, the return value is the following +text string: +

    + +
    +>>> s = test.non_utf8_c_str()
    +>>> s
    +'h\udce9llo wörld'
    +
    + +

    +Since the C string contains bytes that cannot be decoded as UTF-8, those raw +bytes are represented as high surrogate characters that can be used to obtain +the original byte sequence: +

    + +
    +>>> b = s.encode('utf-8', errors='surrogateescape')
    +>>> b
    +b'h\xe9llo w\xc3\xb6rld'
    +
    + +

    +One can then attempt a different encoding, if desired (or simply leave the +byte string as a raw sequence of bytes for use in binary protocols): +

    + +
    +>>> b.decode('latin-1')
    +'héllo wörld'
    +
    + +

    +Note, however, that text strings containing surrogate characters are rejected +with the default strict codec error handler. For example: +

    + +
    +>>> with open('test', 'w') as f:
    +...     print(s, file=f)
    +...
    +Traceback (most recent call last):
    +  File "<stdin>", line 2, in <module>
    +UnicodeEncodeError: 'utf-8' codec can't encode character '\udce9' in position 1: surrogates not allowed
    +
    + +

    +This requires the user to check most strings returned by SWIG bindings, but +the alternative is for a non-UTF8 byte string to be completely inaccessible +in Python 3 code. +

    + +

    +For more details about the surrogateescape error handler, please see +PEP 383. +

    + -- cgit v1.2.1 From 8d3902a6666799a01ff23ee501c478b1371d19a1 Mon Sep 17 00:00:00 2001 From: Olly Betts Date: Sat, 24 May 2014 11:10:57 +1200 Subject: Work towards C90 compatibility for Lua --- Lib/lua/luarun.swg | 49 ++++++++++++++++++++++++++++--------------------- 1 file changed, 28 insertions(+), 21 deletions(-) diff --git a/Lib/lua/luarun.swg b/Lib/lua/luarun.swg index ad735a541..dd668587f 100644 --- a/Lib/lua/luarun.swg +++ b/Lib/lua/luarun.swg @@ -392,8 +392,9 @@ static int swig_lua_elua_emulate_unique_key; /* This function emulates eLua rotables behaviour. It loads a rotable definition into the usual lua table. */ SWIGINTERN void SWIG_Lua_elua_emulate_register(lua_State *L, const swig_elua_entry *table) { + int i, table_parsed, parsed_tables_array, target_table; assert(lua_istable(L,-1)); - int target_table = lua_gettop(L); + target_table = lua_gettop(L); /* Get the registry where we put all parsed tables to avoid loops */ lua_rawgetp(L, LUA_REGISTRYINDEX, &swig_lua_elua_emulate_unique_key); if(lua_isnil(L,-1)) { @@ -402,11 +403,10 @@ SWIGINTERN void SWIG_Lua_elua_emulate_register(lua_State *L, const swig_elua_ent lua_pushvalue(L,-1); lua_rawsetp(L,LUA_REGISTRYINDEX,(void*)(&swig_lua_elua_emulate_unique_key)); } - int parsed_tables_array = lua_gettop(L); + parsed_tables_array = lua_gettop(L); lua_pushvalue(L,target_table); lua_rawsetp(L, parsed_tables_array, table); - int i; - int table_parsed = 0; + table_parsed = 0; const int SWIGUNUSED pairs_start = lua_gettop(L); for(i = 0;table[i].key.type != LUA_TNIL || table[i].value.type != LUA_TNIL;i++) { @@ -606,7 +606,7 @@ SWIGINTERN void SWIG_Lua_class_register(lua_State *L,swig_lua_class *clss); /* helper function - register namespace methods and attributes into namespace */ SWIGINTERN int SWIG_Lua_add_namespace_details(lua_State *L, swig_lua_namespace *ns) { - int i = 0; + int i; /* There must be namespace table (not metatable) at the top of the stack */ assert(lua_istable(L,-1)); SWIG_Lua_InstallConstants(L, ns->ns_constants); @@ -753,11 +753,13 @@ SWIGINTERN int SWIG_Lua_iterate_bases(lua_State *L, swig_type_info * SWIGUNUSED /* first_arg - position of the object in stack. Everything that is above are arguments * and is passed to every evocation of the func */ int last_arg = lua_gettop(L);/* position of last argument */ - lua_getmetatable(L,first_arg); - int original_metatable = last_arg + 1; + int original_metatable; size_t bases_count; + int result; + lua_getmetatable(L,first_arg); + original_metatable = last_arg + 1; SWIG_LUA_INIT_BASE_SEARCH(bases_count); - int result = SWIG_ERROR; + result = SWIG_ERROR; if(ret) *ret = 0; if(bases_count>0) @@ -766,10 +768,11 @@ SWIGINTERN int SWIG_Lua_iterate_bases(lua_State *L, swig_type_info * SWIGUNUSED int j; int subcall_first_arg = lua_gettop(L) + 1;/* Here a copy of first_arg and arguments begin */ int valid = 1; + int subcall_last_arg; + swig_type_info *base_swig_type = 0; for(j=first_arg;j<=last_arg;j++) lua_pushvalue(L,j); - int subcall_last_arg = lua_gettop(L); - swig_type_info *base_swig_type = 0; + subcall_last_arg = lua_gettop(L); /* Trick: temporarily replacing original metatable with metatable for base class and call getter */ for(i=0;ifqname); /* get the name */ @@ -1499,7 +1507,6 @@ SWIGINTERN void SWIG_Lua_class_register_instance(lua_State *L,swig_lua_class *c } lua_pop(L,2); /* tidy stack */ /* Recursively initialize all bases */ - int i = 0; for(i=0;clss->bases[i];i++) { SWIG_Lua_class_register_instance(L,clss->bases[i]); @@ -1604,6 +1611,7 @@ SWIGINTERN void SWIG_Lua_class_register(lua_State *L,swig_lua_class *clss) SWIGINTERN void SWIG_Lua_elua_class_register_instance(lua_State *L, swig_lua_class *clss) { const int SWIGUNUSED begin = lua_gettop(L); + int i; /* if name already there (class is already registered) then do nothing */ SWIG_Lua_get_class_registry(L); /* get the registry */ lua_pushstring(L,clss->fqname); /* get the name */ @@ -1615,7 +1623,6 @@ SWIGINTERN void SWIG_Lua_elua_class_register_instance(lua_State *L, swig_lua_cla } lua_pop(L,2); /* tidy stack */ /* Recursively initialize all bases */ - int i = 0; for(i=0;clss->bases[i];i++) { SWIG_Lua_elua_class_register_instance(L,clss->bases[i]); -- cgit v1.2.1 From 1a0b8abec735ec0db088a1c4c2da1b71cad7ff0e Mon Sep 17 00:00:00 2001 From: Olly Betts Date: Sat, 24 May 2014 11:11:51 +1200 Subject: Fix comment typo --- Lib/lua/luarun.swg | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/Lib/lua/luarun.swg b/Lib/lua/luarun.swg index dd668587f..7cfcff212 100644 --- a/Lib/lua/luarun.swg +++ b/Lib/lua/luarun.swg @@ -1838,8 +1838,8 @@ SWIG_Lua_InstallConstants(lua_State *L, swig_lua_const_info constants[]) { #endif /* Executes a C string in Lua which is a really simple way of calling lua from C Unfortunately lua keeps changing its APIs, so we need a conditional compile -In lua 5.0.X its lua_dostring() -In lua 5.1.X its luaL_dostring() +In lua 5.0.X it's lua_dostring() +In lua 5.1.X it's luaL_dostring() */ SWIGINTERN int SWIG_Lua_dostring(lua_State *L, const char *str) { -- cgit v1.2.1 From 879296f71bcfd56a7659355942c784176ae06e6c Mon Sep 17 00:00:00 2001 From: William S Fulton Date: Sat, 24 May 2014 00:12:27 +0100 Subject: Correct CFLAGS CXXFLAGS for Javascript and guile examples --- Examples/Makefile.in | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/Examples/Makefile.in b/Examples/Makefile.in index b22fd2e76..3a91cddd3 100644 --- a/Examples/Makefile.in +++ b/Examples/Makefile.in @@ -498,7 +498,7 @@ guile_externalhdr: guile_augmented: $(SRCDIR_SRCS) $(SWIG) -guile $(SWIGOPT) -o $(ISRCS) $(INTERFACEPATH) - $(CC) $(CPPFLAGS) $(CXXFLAGS) $(LDFLAGS) $(SRCDIR_SRCS) $(ISRCS) $(GUILE_CFLAGS) $(GUILE_LIBS) $(LIBS) -o $(TARGET) + $(CC) $(CPPFLAGS) $(CFLAGS) $(LDFLAGS) $(SRCDIR_SRCS) $(ISRCS) $(GUILE_CFLAGS) $(GUILE_LIBS) $(LIBS) -o $(TARGET) # ----------------------------------------------------------------- # Build statically linked Guile interpreter @@ -656,8 +656,8 @@ ifeq (node,$(JSENGINE)) sed -e 's|$$srcdir|./$(SRCDIR)|g' $(SRCDIR)binding.gyp.in > binding.gyp $(NODEGYP) --loglevel=silent configure build 1>>/dev/null else - $(CXX) -c $(CCSHARED) $(CPPFLAGS) $(CFLAGS) $(ICXXSRCS) $(SRCDIR_SRCS) $(SRCDIR_CXXSRCS) $(INCLUDES) $(JSINCLUDES) - $(CXXSHARED) $(CFLAGS) $(LDFLAGS) $(OBJS) $(IOBJS) $(JSDYNAMICLINKING) $(LIBS) $(CPP_DLLIBS) -o $(LIBPREFIX)$(TARGET)$(SO) + $(CXX) -c $(CCSHARED) $(CPPFLAGS) $(CXXFLAGS) $(ICXXSRCS) $(SRCDIR_SRCS) $(SRCDIR_CXXSRCS) $(INCLUDES) $(JSINCLUDES) + $(CXXSHARED) $(CXXFLAGS) $(LDFLAGS) $(OBJS) $(IOBJS) $(JSDYNAMICLINKING) $(LIBS) $(CPP_DLLIBS) -o $(LIBPREFIX)$(TARGET)$(SO) endif @@ -669,14 +669,14 @@ ifeq (jsc, $(ENGINE)) $(CC) -c $(CCSHARED) $(CPPFLAGS) $(CFLAGS) $(ISRCS) $(SRCDIR_SRCS) $(INCLUDES) $(JSINCLUDES) $(LDSHARED) $(CFLAGS) $(LDFLAGS) $(OBJS) $(IOBJS) $(JSDYNAMICLINKING) $(LIBS) -o $(LIBPREFIX)$(TARGET)$(SO) else # (v8 | node) # v8 and node must be compiled as c++ - $(CXX) -c $(CCSHARED) $(CPPFLAGS) $(CFLAGS) $(ISRCS) $(SRCDIR_SRCS) $(SRCDIR_CXXSRCS) $(INCLUDES) $(JSINCLUDES) - $(CXXSHARED) $(CFLAGS) $(LDFLAGS) $(OBJS) $(IOBJS) $(JSDYNAMICLINKING) $(LIBS) $(CPP_DLLIBS) -o $(LIBPREFIX)$(TARGET)$(SO) + $(CXX) -c $(CCSHARED) $(CPPFLAGS) $(CXXFLAGS) $(ISRCS) $(SRCDIR_SRCS) $(SRCDIR_CXXSRCS) $(INCLUDES) $(JSINCLUDES) + $(CXXSHARED) $(CXXFLAGS) $(LDFLAGS) $(OBJS) $(IOBJS) $(JSDYNAMICLINKING) $(LIBS) $(CPP_DLLIBS) -o $(LIBPREFIX)$(TARGET)$(SO) endif javascript_cpp: $(SRCDIR_SRCS) javascript_custom_interpreter $(SWIG) -javascript -c++ $(SWIGOPT) $(INTERFACEPATH) - $(CXX) -c $(CCSHARED) $(CPPFLAGS) $(CFLAGS) $(ICXXSRCS) $(SRCDIR_SRCS) $(SRCDIR_CXXSRCS) $(INCLUDES) $(JSINCLUDES) - $(CXXSHARED) $(CFLAGS) $(LDFLAGS) $(OBJS) $(IOBJS) $(JSDYNAMICLINKING) $(LIBS) $(CPP_DLLIBS) -o $(LIBPREFIX)$(TARGET)$(SO) + $(CXX) -c $(CCSHARED) $(CPPFLAGS) $(CXXFLAGS) $(ICXXSRCS) $(SRCDIR_SRCS) $(SRCDIR_CXXSRCS) $(INCLUDES) $(JSINCLUDES) + $(CXXSHARED) $(CXXFLAGS) $(LDFLAGS) $(OBJS) $(IOBJS) $(JSDYNAMICLINKING) $(LIBS) $(CPP_DLLIBS) -o $(LIBPREFIX)$(TARGET)$(SO) # ----------------------------------------------------------------- # Running a Javascript example -- cgit v1.2.1 From f39ed94419e4a30b8b2ba1d49c138fd245010262 Mon Sep 17 00:00:00 2001 From: William S Fulton Date: Sat, 24 May 2014 00:14:01 +0100 Subject: Fix compiler warnings in examples when using -std=c++98 -std=gnu89 -pedantic -Wreturn-type --- Examples/csharp/extend/example.h | 2 +- Examples/csharp/reference/example.cxx | 2 +- Examples/csharp/variables/example.c | 4 ++-- Examples/d/extend/example.h | 2 +- Examples/d/variables/example.c | 4 ++-- Examples/go/extend/example.h | 2 +- Examples/go/reference/reference.cxx | 2 +- Examples/java/extend/example.h | 2 +- Examples/java/reference/example.cxx | 2 +- Examples/java/variables/example.c | 4 ++-- Examples/javascript/reference/example.cxx | 2 +- Examples/javascript/variables/example.cxx | 4 ++-- Examples/lua/arrays/example.c | 2 +- Examples/lua/dual/dual.cpp | 6 +++--- Examples/lua/embed2/embed2.c | 10 +++++----- Examples/lua/functest/example.i | 13 ++++++------- Examples/lua/owner/example.cxx | 11 +++++++---- Examples/lua/variables/example.c | 4 ++-- Examples/modula3/reference/example.cxx | 2 +- Examples/octave/extend/example.h | 2 +- Examples/octave/reference/example.cxx | 2 +- Examples/octave/variables/example.c | 4 ++-- Examples/perl5/extend/example.h | 2 +- Examples/perl5/reference/example.cxx | 2 +- Examples/perl5/value/example.i | 2 +- Examples/perl5/variables/example.c | 4 ++-- Examples/php/extend/example.h | 2 +- Examples/php/reference/example.cxx | 10 +++++----- Examples/php/reference/example.i | 2 +- Examples/php/sync/example.cxx | 2 +- Examples/php/value/example.i | 2 +- Examples/php/variables/example.c | 4 ++-- Examples/python/extend/example.h | 2 +- Examples/python/reference/example.cxx | 2 +- Examples/python/swigrun/example.cxx | 2 +- Examples/python/swigrun/example.h | 2 +- Examples/python/variables/example.c | 4 ++-- Examples/ruby/reference/example.cxx | 2 +- Examples/ruby/value/example.i | 2 +- Examples/ruby/variables/example.c | 4 ++-- Examples/tcl/reference/example.cxx | 2 +- Examples/tcl/value/example.i | 2 +- Examples/tcl/variables/example.c | 4 ++-- 43 files changed, 75 insertions(+), 73 deletions(-) diff --git a/Examples/csharp/extend/example.h b/Examples/csharp/extend/example.h index b27ab9711..ca1aed28f 100644 --- a/Examples/csharp/extend/example.h +++ b/Examples/csharp/extend/example.h @@ -14,7 +14,7 @@ public: virtual std::string getTitle() { return getPosition() + " " + getName(); } virtual std::string getName() { return name; } virtual std::string getPosition() const { return "Employee"; } - virtual ~Employee() { printf("~Employee() @ %p\n", this); } + virtual ~Employee() { printf("~Employee() @ %p\n", (void *)this); } }; diff --git a/Examples/csharp/reference/example.cxx b/Examples/csharp/reference/example.cxx index 8a513bf49..9dbaed2ee 100644 --- a/Examples/csharp/reference/example.cxx +++ b/Examples/csharp/reference/example.cxx @@ -19,7 +19,7 @@ Vector operator+(const Vector &a, const Vector &b) { char *Vector::print() { static char temp[512]; - sprintf(temp,"Vector %p (%g,%g,%g)", this, x,y,z); + sprintf(temp,"Vector %p (%g,%g,%g)", (void *)this, x,y,z); return temp; } diff --git a/Examples/csharp/variables/example.c b/Examples/csharp/variables/example.c index 05e17c8c5..85685fe72 100644 --- a/Examples/csharp/variables/example.c +++ b/Examples/csharp/variables/example.c @@ -52,9 +52,9 @@ void print_vars() { printf("cvar = %c\n", cvar); printf("strvar = %s\n", strvar ? strvar : "(null)"); printf("cstrvar = %s\n", cstrvar); - printf("iptrvar = %p\n", iptrvar); + printf("iptrvar = %p\n", (void *)iptrvar); printf("name = %s\n", name); - printf("ptptr = %p (%d, %d)\n", ptptr, ptptr ? ptptr->x : 0, ptptr ? ptptr->y : 0); + printf("ptptr = %p (%d, %d)\n", (void *)ptptr, ptptr ? ptptr->x : 0, ptptr ? ptptr->y : 0); printf("pt = (%d, %d)\n", pt.x, pt.y); printf("status = %d\n", status); } diff --git a/Examples/d/extend/example.h b/Examples/d/extend/example.h index 7ad93fbc1..7a8c04c33 100644 --- a/Examples/d/extend/example.h +++ b/Examples/d/extend/example.h @@ -14,7 +14,7 @@ public: virtual std::string getTitle() { return getPosition() + " " + getName(); } virtual std::string getName() { return name; } virtual std::string getPosition() const { return "Employee"; } - virtual ~Employee() { printf("~Employee() @ %p\n", this); } + virtual ~Employee() { printf("~Employee() @ %p\n", (void *)this); } }; diff --git a/Examples/d/variables/example.c b/Examples/d/variables/example.c index 3b4e9f346..f5356c755 100644 --- a/Examples/d/variables/example.c +++ b/Examples/d/variables/example.c @@ -52,9 +52,9 @@ void print_vars() { printf("cvar = %c\n", cvar); printf("strvar = %s\n", strvar ? strvar : "(null)"); printf("cstrvar = %s\n", cstrvar); - printf("iptrvar = %p\n", iptrvar); + printf("iptrvar = %p\n", (void *)iptrvar); printf("name = %s\n", name); - printf("ptptr = %p (%d, %d)\n", ptptr, ptptr ? ptptr->x : 0, ptptr ? ptptr->y : 0); + printf("ptptr = %p (%d, %d)\n", (void *)ptptr, ptptr ? ptptr->x : 0, ptptr ? ptptr->y : 0); printf("pt = (%d, %d)\n", pt.x, pt.y); printf("status = %d\n", status); } diff --git a/Examples/go/extend/example.h b/Examples/go/extend/example.h index b27ab9711..ca1aed28f 100644 --- a/Examples/go/extend/example.h +++ b/Examples/go/extend/example.h @@ -14,7 +14,7 @@ public: virtual std::string getTitle() { return getPosition() + " " + getName(); } virtual std::string getName() { return name; } virtual std::string getPosition() const { return "Employee"; } - virtual ~Employee() { printf("~Employee() @ %p\n", this); } + virtual ~Employee() { printf("~Employee() @ %p\n", (void *)this); } }; diff --git a/Examples/go/reference/reference.cxx b/Examples/go/reference/reference.cxx index 8a513bf49..9dbaed2ee 100644 --- a/Examples/go/reference/reference.cxx +++ b/Examples/go/reference/reference.cxx @@ -19,7 +19,7 @@ Vector operator+(const Vector &a, const Vector &b) { char *Vector::print() { static char temp[512]; - sprintf(temp,"Vector %p (%g,%g,%g)", this, x,y,z); + sprintf(temp,"Vector %p (%g,%g,%g)", (void *)this, x,y,z); return temp; } diff --git a/Examples/java/extend/example.h b/Examples/java/extend/example.h index b27ab9711..ca1aed28f 100644 --- a/Examples/java/extend/example.h +++ b/Examples/java/extend/example.h @@ -14,7 +14,7 @@ public: virtual std::string getTitle() { return getPosition() + " " + getName(); } virtual std::string getName() { return name; } virtual std::string getPosition() const { return "Employee"; } - virtual ~Employee() { printf("~Employee() @ %p\n", this); } + virtual ~Employee() { printf("~Employee() @ %p\n", (void *)this); } }; diff --git a/Examples/java/reference/example.cxx b/Examples/java/reference/example.cxx index 8a513bf49..9dbaed2ee 100644 --- a/Examples/java/reference/example.cxx +++ b/Examples/java/reference/example.cxx @@ -19,7 +19,7 @@ Vector operator+(const Vector &a, const Vector &b) { char *Vector::print() { static char temp[512]; - sprintf(temp,"Vector %p (%g,%g,%g)", this, x,y,z); + sprintf(temp,"Vector %p (%g,%g,%g)", (void *)this, x,y,z); return temp; } diff --git a/Examples/java/variables/example.c b/Examples/java/variables/example.c index 05e17c8c5..85685fe72 100644 --- a/Examples/java/variables/example.c +++ b/Examples/java/variables/example.c @@ -52,9 +52,9 @@ void print_vars() { printf("cvar = %c\n", cvar); printf("strvar = %s\n", strvar ? strvar : "(null)"); printf("cstrvar = %s\n", cstrvar); - printf("iptrvar = %p\n", iptrvar); + printf("iptrvar = %p\n", (void *)iptrvar); printf("name = %s\n", name); - printf("ptptr = %p (%d, %d)\n", ptptr, ptptr ? ptptr->x : 0, ptptr ? ptptr->y : 0); + printf("ptptr = %p (%d, %d)\n", (void *)ptptr, ptptr ? ptptr->x : 0, ptptr ? ptptr->y : 0); printf("pt = (%d, %d)\n", pt.x, pt.y); printf("status = %d\n", status); } diff --git a/Examples/javascript/reference/example.cxx b/Examples/javascript/reference/example.cxx index 8a513bf49..9dbaed2ee 100644 --- a/Examples/javascript/reference/example.cxx +++ b/Examples/javascript/reference/example.cxx @@ -19,7 +19,7 @@ Vector operator+(const Vector &a, const Vector &b) { char *Vector::print() { static char temp[512]; - sprintf(temp,"Vector %p (%g,%g,%g)", this, x,y,z); + sprintf(temp,"Vector %p (%g,%g,%g)", (void *)this, x,y,z); return temp; } diff --git a/Examples/javascript/variables/example.cxx b/Examples/javascript/variables/example.cxx index f10390a9e..15314b383 100644 --- a/Examples/javascript/variables/example.cxx +++ b/Examples/javascript/variables/example.cxx @@ -57,9 +57,9 @@ void print_vars() { printf("cvar = %c\n", cvar); printf("strvar = %s\n", strvar ? strvar : "(null)"); printf("cstrvar = %s\n", cstrvar); - printf("iptrvar = %p\n", iptrvar); + printf("iptrvar = %p\n", (void *)iptrvar); printf("name = %s\n", name); - printf("ptptr = %p (%d, %d)\n", ptptr, ptptr ? ptptr->x : 0, ptptr ? ptptr->y : 0); + printf("ptptr = %p (%d, %d)\n", (void *)ptptr, ptptr ? ptptr->x : 0, ptptr ? ptptr->y : 0); printf("pt = (%d, %d)\n", pt.x, pt.y); printf("status = %d\n", status); } diff --git a/Examples/lua/arrays/example.c b/Examples/lua/arrays/example.c index ed23738c8..da1bd755a 100644 --- a/Examples/lua/arrays/example.c +++ b/Examples/lua/arrays/example.c @@ -13,7 +13,7 @@ void sort_int(int* arr, int len) qsort(arr, len, sizeof(int), compare_int); } -// ditto doubles +/* ditto doubles */ int compare_double(const void * a, const void * b) { return (int)( *(double*)a - *(double*)b ); diff --git a/Examples/lua/dual/dual.cpp b/Examples/lua/dual/dual.cpp index b54e44de1..2108a7275 100644 --- a/Examples/lua/dual/dual.cpp +++ b/Examples/lua/dual/dual.cpp @@ -45,14 +45,14 @@ void testModule(lua_State *L) swig_type_info *pTypeInfo=0,*pTypeInfo2=0; swig_module_info *pModule=0; pModule=SWIG_GetModule(L); - DEBUG2(" SWIG_GetModule() returns %p\n",pModule) + DEBUG2(" SWIG_GetModule() returns %p\n", (void *)pModule) if(pModule==0) return; pTypeInfo = SWIG_TypeQuery(L,"Foo *"); DEBUG2(" Type (Foo*) is %s\n",pTypeInfo==0?"unknown":"known"); - DEBUG3(" Module %p typeinfo(Foo*) %p\n",pModule,pTypeInfo); + DEBUG3(" Module %p typeinfo(Foo*) %p\n", (void *)pModule, (void *)pTypeInfo); pTypeInfo2 = SWIG_TypeQuery(L,"Bar *"); DEBUG2(" Type (Bar*) is %s\n",pTypeInfo2==0?"unknown":"known"); - DEBUG3(" Module %p typeinfo(Bar*) %p\n",pModule,pTypeInfo2); + DEBUG3(" Module %p typeinfo(Bar*) %p\n", (void *)pModule, (void *)pTypeInfo2); } int main(int argc,char* argv[]) diff --git a/Examples/lua/embed2/embed2.c b/Examples/lua/embed2/embed2.c index 7b2ca9b67..0ce9f8f7f 100644 --- a/Examples/lua/embed2/embed2.c +++ b/Examples/lua/embed2/embed2.c @@ -53,7 +53,7 @@ int call_add(lua_State *L,int a,int b,int* res) { lua_getglobal(L, "add"); /* function to be called */ if (!lua_isfunction(L,-1)) { printf("[C] error: cannot find function 'add'\n"); - lua_settop(L,top); // reset + lua_settop(L,top); return 0; } lua_pushnumber(L,a); @@ -61,18 +61,18 @@ int call_add(lua_State *L,int a,int b,int* res) { if (lua_pcall(L, 2, 1, 0) != 0) /* call function with 2 arguments and 1 result */ { printf("[C] error running function `add': %s\n",lua_tostring(L, -1)); - lua_settop(L,top); // reset + lua_settop(L,top); return 0; } - // check results + /* check results */ if (!lua_isnumber(L,-1)) { printf("[C] error: returned value is not a number\n"); - lua_settop(L,top); // reset + lua_settop(L,top); return 0; } *res=(int)lua_tonumber(L,-1); lua_settop(L,top); /* reset stack */ - return 1; // ok + return 1; } /* This is a variargs call function for calling from C into Lua. diff --git a/Examples/lua/functest/example.i b/Examples/lua/functest/example.i index 631e0602d..9bb64cbf5 100644 --- a/Examples/lua/functest/example.i +++ b/Examples/lua/functest/example.i @@ -1,13 +1,12 @@ /* File : example.i */ %module example -%include "typemaps.i" // you must have this for the typemaps for ptrs -// basic function testing -// +%include "typemaps.i" + %inline %{ -extern int add1(int x, int y); // return x+y -- basic function test -extern void add2(int x, int *INPUT, int *OUTPUT); // *z = x+*y -- argin and argout test -extern int add3(int x, int y, int *OUTPUT); // return x+y, *z=x-y -- returning 2 values -extern void add4(int x, int *INOUT); // *y += x -- INOUT dual purpose variable +extern int add1(int x, int y); /* return x+y -- basic function test */ +extern void add2(int x, int *INPUT, int *OUTPUT); /* *z = x+*y -- argin and argout test */ +extern int add3(int x, int y, int *OUTPUT); /* return x+y, *z=x-y -- returning 2 values */ +extern void add4(int x, int *INOUT); /* *y += x -- INOUT dual purpose variable */ %} diff --git a/Examples/lua/owner/example.cxx b/Examples/lua/owner/example.cxx index bce484aea..c2c073d79 100644 --- a/Examples/lua/owner/example.cxx +++ b/Examples/lua/owner/example.cxx @@ -39,12 +39,15 @@ Square* createSquare(double w) return new Square(w); } -ShapeOwner::ShapeOwner() {printf(" ShapeOwner(%p)\n",this);} +ShapeOwner::ShapeOwner() { + printf(" ShapeOwner(%p)\n", (void *)this); +} + ShapeOwner::~ShapeOwner() { - printf(" ~ShapeOwner(%p)\n",this); - for(unsigned i=0;ix : 0, ptptr ? ptptr->y : 0); + printf("ptptr = %p (%d, %d)\n", (void *)ptptr, ptptr ? ptptr->x : 0, ptptr ? ptptr->y : 0); printf("pt = (%d, %d)\n", pt.x, pt.y); printf("status = %d\n", status); } diff --git a/Examples/modula3/reference/example.cxx b/Examples/modula3/reference/example.cxx index 649b0169c..9dbaed2ee 100644 --- a/Examples/modula3/reference/example.cxx +++ b/Examples/modula3/reference/example.cxx @@ -19,7 +19,7 @@ Vector operator+(const Vector &a, const Vector &b) { char *Vector::print() { static char temp[512]; - sprintf(temp,"Vector %x (%g,%g,%g)", (int)this, x,y,z); + sprintf(temp,"Vector %p (%g,%g,%g)", (void *)this, x,y,z); return temp; } diff --git a/Examples/octave/extend/example.h b/Examples/octave/extend/example.h index 9e15cf8e4..77a26ec95 100644 --- a/Examples/octave/extend/example.h +++ b/Examples/octave/extend/example.h @@ -14,7 +14,7 @@ public: virtual std::string getTitle() { return getPosition() + " " + getName(); } virtual std::string getName() { return name; } virtual std::string getPosition() const { return "Employee"; } - virtual ~Employee() { printf("~Employee() @ %p\n", this); } + virtual ~Employee() { printf("~Employee() @ %p\n", (void *)this); } }; diff --git a/Examples/octave/reference/example.cxx b/Examples/octave/reference/example.cxx index 9b72ca6a2..632a03a5b 100644 --- a/Examples/octave/reference/example.cxx +++ b/Examples/octave/reference/example.cxx @@ -19,7 +19,7 @@ Vector operator+(const Vector &a, const Vector &b) { char *Vector::print() { static char temp[512]; - sprintf(temp,"Vector %p (%g,%g,%g)", this, x,y,z); + sprintf(temp,"Vector %p (%g,%g,%g)", (void *)this, x,y,z); return temp; } diff --git a/Examples/octave/variables/example.c b/Examples/octave/variables/example.c index e2b72e0ea..a9102a9d5 100644 --- a/Examples/octave/variables/example.c +++ b/Examples/octave/variables/example.c @@ -52,9 +52,9 @@ void print_vars() { printf("cvar = %c\n", cvar); printf("strvar = %s\n", strvar ? strvar : "(null)"); printf("cstrvar = %s\n", cstrvar); - printf("iptrvar = %p\n", iptrvar); + printf("iptrvar = %p\n", (void *)iptrvar); printf("name = %s\n", name); - printf("ptptr = %p (%d, %d)\n", ptptr, ptptr ? ptptr->x : 0, ptptr ? ptptr->y : 0); + printf("ptptr = %p (%d, %d)\n", (void *)ptptr, ptptr ? ptptr->x : 0, ptptr ? ptptr->y : 0); printf("pt = (%d, %d)\n", pt.x, pt.y); printf("status = %d\n", status); } diff --git a/Examples/perl5/extend/example.h b/Examples/perl5/extend/example.h index b27ab9711..ca1aed28f 100644 --- a/Examples/perl5/extend/example.h +++ b/Examples/perl5/extend/example.h @@ -14,7 +14,7 @@ public: virtual std::string getTitle() { return getPosition() + " " + getName(); } virtual std::string getName() { return name; } virtual std::string getPosition() const { return "Employee"; } - virtual ~Employee() { printf("~Employee() @ %p\n", this); } + virtual ~Employee() { printf("~Employee() @ %p\n", (void *)this); } }; diff --git a/Examples/perl5/reference/example.cxx b/Examples/perl5/reference/example.cxx index 8a513bf49..9dbaed2ee 100644 --- a/Examples/perl5/reference/example.cxx +++ b/Examples/perl5/reference/example.cxx @@ -19,7 +19,7 @@ Vector operator+(const Vector &a, const Vector &b) { char *Vector::print() { static char temp[512]; - sprintf(temp,"Vector %p (%g,%g,%g)", this, x,y,z); + sprintf(temp,"Vector %p (%g,%g,%g)", (void *)this, x,y,z); return temp; } diff --git a/Examples/perl5/value/example.i b/Examples/perl5/value/example.i index 98fd60ed5..39663c6b8 100644 --- a/Examples/perl5/value/example.i +++ b/Examples/perl5/value/example.i @@ -26,7 +26,7 @@ Vector *new_Vector(double x, double y, double z) { } void vector_print(Vector *v) { - printf("Vector %p = (%g, %g, %g)\n", v, v->x, v->y, v->z); + printf("Vector %p = (%g, %g, %g)\n", (void *)v, v->x, v->y, v->z); } %} diff --git a/Examples/perl5/variables/example.c b/Examples/perl5/variables/example.c index 05e17c8c5..85685fe72 100644 --- a/Examples/perl5/variables/example.c +++ b/Examples/perl5/variables/example.c @@ -52,9 +52,9 @@ void print_vars() { printf("cvar = %c\n", cvar); printf("strvar = %s\n", strvar ? strvar : "(null)"); printf("cstrvar = %s\n", cstrvar); - printf("iptrvar = %p\n", iptrvar); + printf("iptrvar = %p\n", (void *)iptrvar); printf("name = %s\n", name); - printf("ptptr = %p (%d, %d)\n", ptptr, ptptr ? ptptr->x : 0, ptptr ? ptptr->y : 0); + printf("ptptr = %p (%d, %d)\n", (void *)ptptr, ptptr ? ptptr->x : 0, ptptr ? ptptr->y : 0); printf("pt = (%d, %d)\n", pt.x, pt.y); printf("status = %d\n", status); } diff --git a/Examples/php/extend/example.h b/Examples/php/extend/example.h index b27ab9711..ca1aed28f 100644 --- a/Examples/php/extend/example.h +++ b/Examples/php/extend/example.h @@ -14,7 +14,7 @@ public: virtual std::string getTitle() { return getPosition() + " " + getName(); } virtual std::string getName() { return name; } virtual std::string getPosition() const { return "Employee"; } - virtual ~Employee() { printf("~Employee() @ %p\n", this); } + virtual ~Employee() { printf("~Employee() @ %p\n", (void *)this); } }; diff --git a/Examples/php/reference/example.cxx b/Examples/php/reference/example.cxx index 13e47eade..7ead7fbf6 100644 --- a/Examples/php/reference/example.cxx +++ b/Examples/php/reference/example.cxx @@ -19,23 +19,23 @@ Vector operator+(const Vector &a, const Vector &b) { char *Vector::as_string() { static char temp[512]; - sprintf(temp,"Vector %p (%g,%g,%g)", this, x,y,z); + sprintf(temp,"Vector %p (%g,%g,%g)", (void *)this, x,y,z); return temp; } VectorArray::VectorArray(int size) { items = new Vector[size]; maxsize = size; - printf("VectorArray new: self=%p\n",this); + printf("VectorArray new: self=%p\n", (void *)this); } VectorArray::~VectorArray() { - printf("VectorArray delete: self=%p\n",this); + printf("VectorArray delete: self=%p\n", (void *)this); delete [] items; } Vector &VectorArray::operator[](int index) { - printf("VectorArray: read[%d] self=%p\n",index,this); + printf("VectorArray: read[%d] self=%p\n", index, (void *)this); if ((index < 0) || (index >= maxsize)) { printf("Panic! Array index out of bounds.\n"); exit(1); @@ -44,6 +44,6 @@ Vector &VectorArray::operator[](int index) { } int VectorArray::size() { - printf("VectorArray: size %d self=%p\n",maxsize,this); + printf("VectorArray: size %d self=%p\n", maxsize, (void *)this); return maxsize; } diff --git a/Examples/php/reference/example.i b/Examples/php/reference/example.i index d6122866b..a372439b1 100644 --- a/Examples/php/reference/example.i +++ b/Examples/php/reference/example.i @@ -37,7 +37,7 @@ public: /* This wrapper provides an alternative to the [] operator */ %extend { Vector &get(int index) { - printf("VectorArray extended get: %p %d\n",$self,index); + printf("VectorArray extended get: %p %d\n", (void *)$self, index); return (*$self)[index]; } void set(int index, Vector &a) { diff --git a/Examples/php/sync/example.cxx b/Examples/php/sync/example.cxx index 31ed2021b..0942279b2 100644 --- a/Examples/php/sync/example.cxx +++ b/Examples/php/sync/example.cxx @@ -10,4 +10,4 @@ void Sync::printer(void) { printf("The value of global x is %d\n", x); printf("The value of class s is %s\n", s); printf("The value of class x is %d\n", x); -}; +} diff --git a/Examples/php/value/example.i b/Examples/php/value/example.i index 386fa3b84..20a453468 100644 --- a/Examples/php/value/example.i +++ b/Examples/php/value/example.i @@ -11,7 +11,7 @@ %inline %{ void vector_print(Vector *v) { - printf("Vector %p = (%g, %g, %g)\n", v, v->x, v->y, v->z); + printf("Vector %p = (%g, %g, %g)\n", (void *)v, v->x, v->y, v->z); } %} diff --git a/Examples/php/variables/example.c b/Examples/php/variables/example.c index b21dee32d..d4c6d026d 100644 --- a/Examples/php/variables/example.c +++ b/Examples/php/variables/example.c @@ -52,9 +52,9 @@ void print_vars() { printf("cvar = %c\n", cvar); printf("strvar = %s\n", strvar ? strvar : "(null)"); printf("cstrvar = %s\n", cstrvar); - printf("iptrvar = %p\n", iptrvar); + printf("iptrvar = %p\n", (void *)iptrvar); printf("name = %c%c%c%c%c\n", name[0],name[1],name[2],name[3],name[4]); - printf("ptptr = %p %s\n", ptptr, Point_print( ptptr ) ); + printf("ptptr = %p %s\n", (void *)ptptr, Point_print( ptptr ) ); printf("pt = (%d, %d)\n", pt.x, pt.y); printf("status = %d\n", status); } diff --git a/Examples/python/extend/example.h b/Examples/python/extend/example.h index b27ab9711..ca1aed28f 100644 --- a/Examples/python/extend/example.h +++ b/Examples/python/extend/example.h @@ -14,7 +14,7 @@ public: virtual std::string getTitle() { return getPosition() + " " + getName(); } virtual std::string getName() { return name; } virtual std::string getPosition() const { return "Employee"; } - virtual ~Employee() { printf("~Employee() @ %p\n", this); } + virtual ~Employee() { printf("~Employee() @ %p\n", (void *)this); } }; diff --git a/Examples/python/reference/example.cxx b/Examples/python/reference/example.cxx index 8a513bf49..9dbaed2ee 100644 --- a/Examples/python/reference/example.cxx +++ b/Examples/python/reference/example.cxx @@ -19,7 +19,7 @@ Vector operator+(const Vector &a, const Vector &b) { char *Vector::print() { static char temp[512]; - sprintf(temp,"Vector %p (%g,%g,%g)", this, x,y,z); + sprintf(temp,"Vector %p (%g,%g,%g)", (void *)this, x,y,z); return temp; } diff --git a/Examples/python/swigrun/example.cxx b/Examples/python/swigrun/example.cxx index 25906a559..2d2471301 100644 --- a/Examples/python/swigrun/example.cxx +++ b/Examples/python/swigrun/example.cxx @@ -9,7 +9,7 @@ Manager* convert_to_Manager(PyObject *py_obj) { Manager* c_ptr; swig_type_info *ty = SWIG_TypeQuery("Manager *"); - printf("manager ty %p \n", ty); + printf("manager ty %p \n", (void *)ty); if (SWIG_ConvertPtr(py_obj, (void **) &c_ptr, ty, 0) == -1) { c_ptr = 0; } else { diff --git a/Examples/python/swigrun/example.h b/Examples/python/swigrun/example.h index 69e6fe4de..e89f7baaa 100644 --- a/Examples/python/swigrun/example.h +++ b/Examples/python/swigrun/example.h @@ -14,7 +14,7 @@ public: virtual std::string getTitle() { return getPosition() + " " + getName(); } virtual std::string getName() { return name; } virtual std::string getPosition() const { return "Employee"; } - virtual ~Employee() { printf("~Employee() @ %p\n", this); } + virtual ~Employee() { printf("~Employee() @ %p\n", (void *)this); } }; diff --git a/Examples/python/variables/example.c b/Examples/python/variables/example.c index 05e17c8c5..85685fe72 100644 --- a/Examples/python/variables/example.c +++ b/Examples/python/variables/example.c @@ -52,9 +52,9 @@ void print_vars() { printf("cvar = %c\n", cvar); printf("strvar = %s\n", strvar ? strvar : "(null)"); printf("cstrvar = %s\n", cstrvar); - printf("iptrvar = %p\n", iptrvar); + printf("iptrvar = %p\n", (void *)iptrvar); printf("name = %s\n", name); - printf("ptptr = %p (%d, %d)\n", ptptr, ptptr ? ptptr->x : 0, ptptr ? ptptr->y : 0); + printf("ptptr = %p (%d, %d)\n", (void *)ptptr, ptptr ? ptptr->x : 0, ptptr ? ptptr->y : 0); printf("pt = (%d, %d)\n", pt.x, pt.y); printf("status = %d\n", status); } diff --git a/Examples/ruby/reference/example.cxx b/Examples/ruby/reference/example.cxx index 8a513bf49..9dbaed2ee 100644 --- a/Examples/ruby/reference/example.cxx +++ b/Examples/ruby/reference/example.cxx @@ -19,7 +19,7 @@ Vector operator+(const Vector &a, const Vector &b) { char *Vector::print() { static char temp[512]; - sprintf(temp,"Vector %p (%g,%g,%g)", this, x,y,z); + sprintf(temp,"Vector %p (%g,%g,%g)", (void *)this, x,y,z); return temp; } diff --git a/Examples/ruby/value/example.i b/Examples/ruby/value/example.i index 98fd60ed5..39663c6b8 100644 --- a/Examples/ruby/value/example.i +++ b/Examples/ruby/value/example.i @@ -26,7 +26,7 @@ Vector *new_Vector(double x, double y, double z) { } void vector_print(Vector *v) { - printf("Vector %p = (%g, %g, %g)\n", v, v->x, v->y, v->z); + printf("Vector %p = (%g, %g, %g)\n", (void *)v, v->x, v->y, v->z); } %} diff --git a/Examples/ruby/variables/example.c b/Examples/ruby/variables/example.c index 05e17c8c5..85685fe72 100644 --- a/Examples/ruby/variables/example.c +++ b/Examples/ruby/variables/example.c @@ -52,9 +52,9 @@ void print_vars() { printf("cvar = %c\n", cvar); printf("strvar = %s\n", strvar ? strvar : "(null)"); printf("cstrvar = %s\n", cstrvar); - printf("iptrvar = %p\n", iptrvar); + printf("iptrvar = %p\n", (void *)iptrvar); printf("name = %s\n", name); - printf("ptptr = %p (%d, %d)\n", ptptr, ptptr ? ptptr->x : 0, ptptr ? ptptr->y : 0); + printf("ptptr = %p (%d, %d)\n", (void *)ptptr, ptptr ? ptptr->x : 0, ptptr ? ptptr->y : 0); printf("pt = (%d, %d)\n", pt.x, pt.y); printf("status = %d\n", status); } diff --git a/Examples/tcl/reference/example.cxx b/Examples/tcl/reference/example.cxx index 8a513bf49..9dbaed2ee 100644 --- a/Examples/tcl/reference/example.cxx +++ b/Examples/tcl/reference/example.cxx @@ -19,7 +19,7 @@ Vector operator+(const Vector &a, const Vector &b) { char *Vector::print() { static char temp[512]; - sprintf(temp,"Vector %p (%g,%g,%g)", this, x,y,z); + sprintf(temp,"Vector %p (%g,%g,%g)", (void *)this, x,y,z); return temp; } diff --git a/Examples/tcl/value/example.i b/Examples/tcl/value/example.i index 98fd60ed5..39663c6b8 100644 --- a/Examples/tcl/value/example.i +++ b/Examples/tcl/value/example.i @@ -26,7 +26,7 @@ Vector *new_Vector(double x, double y, double z) { } void vector_print(Vector *v) { - printf("Vector %p = (%g, %g, %g)\n", v, v->x, v->y, v->z); + printf("Vector %p = (%g, %g, %g)\n", (void *)v, v->x, v->y, v->z); } %} diff --git a/Examples/tcl/variables/example.c b/Examples/tcl/variables/example.c index 05e17c8c5..85685fe72 100644 --- a/Examples/tcl/variables/example.c +++ b/Examples/tcl/variables/example.c @@ -52,9 +52,9 @@ void print_vars() { printf("cvar = %c\n", cvar); printf("strvar = %s\n", strvar ? strvar : "(null)"); printf("cstrvar = %s\n", cstrvar); - printf("iptrvar = %p\n", iptrvar); + printf("iptrvar = %p\n", (void *)iptrvar); printf("name = %s\n", name); - printf("ptptr = %p (%d, %d)\n", ptptr, ptptr ? ptptr->x : 0, ptptr ? ptptr->y : 0); + printf("ptptr = %p (%d, %d)\n", (void *)ptptr, ptptr ? ptptr->x : 0, ptptr ? ptptr->y : 0); printf("pt = (%d, %d)\n", pt.x, pt.y); printf("status = %d\n", status); } -- cgit v1.2.1 From 3191473523de629d75181b134c75a83f7fd7297b Mon Sep 17 00:00:00 2001 From: William S Fulton Date: Sat, 24 May 2014 00:14:18 +0100 Subject: Fix compiler warnings in generated code when using -std=c++98 -std=gnu89 -pedantic -Wreturn-type --- Lib/guile/guile_scm_run.swg | 3 +- Lib/javascript/v8/javascriptinit.swg | 2 +- Lib/lua/lua_fnptr.i | 1 - Lib/lua/luarun.swg | 122 +++++++++++++++++++++-------------- Lib/lua/luaruntime.swg | 2 +- Lib/lua/typemaps.i | 2 +- Lib/php/const.i | 4 +- Lib/php/utils.i | 2 +- Lib/ruby/file.i | 2 +- 9 files changed, 80 insertions(+), 60 deletions(-) diff --git a/Lib/guile/guile_scm_run.swg b/Lib/guile/guile_scm_run.swg index 322d660c5..94cf4d101 100644 --- a/Lib/guile/guile_scm_run.swg +++ b/Lib/guile/guile_scm_run.swg @@ -27,8 +27,7 @@ scm_module_variable (SCM module, SCM sym) #endif #if SCM_MAJOR_VERSION >= 2 -// scm_c_define_gsubr takes a different parameter type -// depending on the guile version +/* scm_c_define_gsubr takes a different parameter type depending on the guile version */ typedef scm_t_subr swig_guile_proc; #else diff --git a/Lib/javascript/v8/javascriptinit.swg b/Lib/javascript/v8/javascriptinit.swg index de1fe91f4..b428d4af9 100644 --- a/Lib/javascript/v8/javascriptinit.swg +++ b/Lib/javascript/v8/javascriptinit.swg @@ -113,6 +113,6 @@ void SWIGV8_INIT (v8::Handle exports, v8::Handle /*modul } #if defined(BUILDING_NODE_EXTENSION) -NODE_MODULE($jsname, $jsname_initialize); +NODE_MODULE($jsname, $jsname_initialize) #endif %} diff --git a/Lib/lua/lua_fnptr.i b/Lib/lua/lua_fnptr.i index 4e2c8dc6a..481cfafa6 100644 --- a/Lib/lua/lua_fnptr.i +++ b/Lib/lua/lua_fnptr.i @@ -103,7 +103,6 @@ void swiglua_ref_clear(SWIGLUA_REF* pref){ } void swiglua_ref_set(SWIGLUA_REF* pref,lua_State* L,int idx){ -// swiglua_ref_clear(pref); /* just in case */ pref->L=L; lua_pushvalue(L,idx); /* copy obj to top */ pref->ref=luaL_ref(L,LUA_REGISTRYINDEX); /* remove obj from top & put into registry */ diff --git a/Lib/lua/luarun.swg b/Lib/lua/luarun.swg index 7cfcff212..1dd3b9f09 100644 --- a/Lib/lua/luarun.swg +++ b/Lib/lua/luarun.swg @@ -630,10 +630,12 @@ SWIGINTERN int SWIG_Lua_add_namespace_details(lua_State *L, swig_lua_namespace * /* Register all classes in the namespace */ SWIGINTERN void SWIG_Lua_add_namespace_classes(lua_State *L, swig_lua_namespace *ns) { + swig_lua_class **classes; + /* There must be a module/namespace table at the top of the stack */ assert(lua_istable(L,-1)); - swig_lua_class **classes = ns->ns_classes; + classes = ns->ns_classes; if( classes != 0 ) { while(*classes != 0) { @@ -650,6 +652,7 @@ SWIGINTERN void SWIG_Lua_add_namespace_classes(lua_State *L, swig_lua_namespace */ SWIGINTERN void SWIG_Lua_namespace_register(lua_State *L, swig_lua_namespace *ns, int reg) { + swig_lua_namespace **sub_namespace; /* 1 argument - table on the top of the stack */ const int SWIGUNUSED begin = lua_gettop(L); assert(lua_istable(L,-1)); /* just in case. This is supposed to be module table or parent namespace table */ @@ -681,7 +684,7 @@ SWIGINTERN void SWIG_Lua_namespace_register(lua_State *L, swig_lua_namespace *ns /* Register classes */ SWIG_Lua_add_namespace_classes(L,ns); - swig_lua_namespace **sub_namespace = ns->ns_namespaces; + sub_namespace = ns->ns_namespaces; if( sub_namespace != 0) { while(*sub_namespace != 0) { SWIG_Lua_namespace_register(L, *sub_namespace, 1); @@ -753,22 +756,21 @@ SWIGINTERN int SWIG_Lua_iterate_bases(lua_State *L, swig_type_info * SWIGUNUSED /* first_arg - position of the object in stack. Everything that is above are arguments * and is passed to every evocation of the func */ int last_arg = lua_gettop(L);/* position of last argument */ - int original_metatable; + int original_metatable = last_arg + 1; size_t bases_count; - int result; + int result = SWIG_ERROR; lua_getmetatable(L,first_arg); - original_metatable = last_arg + 1; SWIG_LUA_INIT_BASE_SEARCH(bases_count); - result = SWIG_ERROR; if(ret) *ret = 0; if(bases_count>0) { + int to_remove; size_t i; int j; + int subcall_last_arg; int subcall_first_arg = lua_gettop(L) + 1;/* Here a copy of first_arg and arguments begin */ int valid = 1; - int subcall_last_arg; swig_type_info *base_swig_type = 0; for(j=first_arg;j<=last_arg;j++) lua_pushvalue(L,j); @@ -792,7 +794,7 @@ SWIGINTERN int SWIG_Lua_iterate_bases(lua_State *L, swig_type_info * SWIGUNUSED lua_pushvalue(L,original_metatable); lua_setmetatable(L,first_arg); /* Clear - remove everything between last_arg and subcall_last_arg including */ - const int to_remove = subcall_last_arg - last_arg; + to_remove = subcall_last_arg - last_arg; for(j=0;jtype; + int result; + swig_lua_userdata *usr; + swig_type_info *type; int ret = 0; - int result = SWIG_Lua_class_do_get(L,type,1,&ret); + assert(lua_isuserdata(L,1)); + usr=(swig_lua_userdata*)lua_touserdata(L,1); /* get data */ + type = usr->type; + result = SWIG_Lua_class_do_get(L,type,1,&ret); if(result == SWIG_OK) return ret; @@ -902,6 +905,7 @@ SWIGINTERN int SWIG_Lua_class_do_set(lua_State *L, swig_type_info *type, int fi (3) any for the new value */ + int bases_search_result; int substack_start = lua_gettop(L) - 3; lua_checkstack(L,5); assert(lua_isuserdata(L,substack_start+1)); /* just in case */ @@ -944,14 +948,12 @@ SWIGINTERN int SWIG_Lua_class_do_set(lua_State *L, swig_type_info *type, int fi lua_pop(L,1); /* remove value */ lua_pop(L,1); /* remove metatable */ - { - /* Search among bases */ - int bases_search_result = SWIG_Lua_iterate_bases(L,type,first_arg,SWIG_Lua_class_do_set,ret); - if(ret) - assert(*ret == 0); - assert(lua_gettop(L) == substack_start + 3); - return bases_search_result; - } + /* Search among bases */ + bases_search_result = SWIG_Lua_iterate_bases(L,type,first_arg,SWIG_Lua_class_do_set,ret); + if(ret) + assert(*ret == 0); + assert(lua_gettop(L) == substack_start + 3); + return bases_search_result; } /* This is the actual method exported to Lua. It calls SWIG_Lua_class_do_set and correctly @@ -964,11 +966,14 @@ SWIGINTERN int SWIG_Lua_class_set(lua_State *L) (2) string name of the attribute (3) any for the new value */ - assert(lua_isuserdata(L,1)); - swig_lua_userdata *usr=(swig_lua_userdata*)lua_touserdata(L,1); /* get data */ - swig_type_info *type = usr->type; int ret = 0; - int result = SWIG_Lua_class_do_set(L,type,1,&ret); + int result; + swig_lua_userdata *usr; + swig_type_info *type; + assert(lua_isuserdata(L,1)); + usr=(swig_lua_userdata*)lua_touserdata(L,1); /* get data */ + type = usr->type; + result = SWIG_Lua_class_do_set(L,type,1,&ret); if(result != SWIG_OK) { SWIG_Lua_pushferrstring(L,"Assignment not possible. No setter/member with this name. For custom assignments implement __setitem method."); lua_error(L); @@ -1004,13 +1009,15 @@ SWIGINTERN int SWIG_Lua_class_tostring(lua_State *L) { /* there should be 1 param passed in (1) userdata (not the metatable) */ + const char *className; + void* userData; assert(lua_isuserdata(L,1)); /* just in case */ - void* userData = lua_touserdata(L,1); /* get the userdata address for later */ + userData = lua_touserdata(L,1); /* get the userdata address for later */ lua_getmetatable(L,1); /* get the meta table */ assert(lua_istable(L,-1)); /* just in case */ lua_getfield(L, -1, ".type"); - const char *className = lua_tostring(L, -1); + className = lua_tostring(L, -1); lua_pushfstring(L, "<%s userdata: %p>", className, userData); return 1; @@ -1238,10 +1245,10 @@ SWIGINTERN void SWIG_Lua_add_class_user_metamethods(lua_State *L, swig_lua_class SWIGINTERN void SWIG_Lua_add_class_instance_details(lua_State *L, swig_lua_class *clss) { int i; + size_t bases_count = 0; /* Add bases to .bases table */ SWIG_Lua_get_table(L,".bases"); assert(lua_istable(L,-1)); /* just in case */ - size_t bases_count = 0; for(i=0;clss->bases[i];i++) { SWIG_Lua_get_class_metatable(L,clss->bases[i]->fqname); @@ -1296,7 +1303,7 @@ SWIGRUNTIME int SWIG_Lua_resolve_metamethod(lua_State *L); /*forward declaration /* The real function that resolves a metamethod. * Function searches given class and all it's bases(recursively) for first instance of something that is - * not equal to SWIG_Lua_resolve_metatmethod. (Almost always this 'something' is actuall metamethod implementation + * not equal to SWIG_Lua_resolve_metatmethod. (Almost always this 'something' is actual metamethod implementation * and it is a SWIG-generated C function.). It returns value on the top of the L and there is no garbage below the * answer. * Returns 1 if found, 0 otherwise. @@ -1310,6 +1317,9 @@ SWIGINTERN int SWIG_Lua_do_resolve_metamethod(lua_State *L, const swig_lua_class int skip_check) { /* This function is called recursively */ + int result = 0; + int i = 0; + if (!skip_check) { SWIG_Lua_get_class_metatable(L, clss->fqname); lua_pushvalue(L, metamethod_name_idx); @@ -1326,8 +1336,6 @@ SWIGINTERN int SWIG_Lua_do_resolve_metamethod(lua_State *L, const swig_lua_class } /* Forwarding calls to bases */ - int result = 0; - int i = 0; for(i=0;clss->bases[i];i++) { result = SWIG_Lua_do_resolve_metamethod(L, clss->bases[i], metamethod_name_idx, 0); @@ -1342,21 +1350,26 @@ SWIGINTERN int SWIG_Lua_do_resolve_metamethod(lua_State *L, const swig_lua_class * and calls it */ SWIGRUNTIME int SWIG_Lua_resolve_metamethod(lua_State *L) { + int numargs; + int metamethod_name_idx; + const swig_lua_class* clss; + int result; + lua_checkstack(L,5); - const int numargs = lua_gettop(L); /* number of arguments to pass to actuall metamethod */ + numargs = lua_gettop(L); /* number of arguments to pass to actual metamethod */ /* Get upvalues from closure */ lua_pushvalue(L, lua_upvalueindex(1)); /*Get function name*/ - const int metamethod_name_idx = lua_gettop(L); + metamethod_name_idx = lua_gettop(L); lua_pushvalue(L, lua_upvalueindex(2)); - const swig_lua_class* clss = (const swig_lua_class*)(lua_touserdata(L,-1)); + clss = (const swig_lua_class*)(lua_touserdata(L,-1)); lua_pop(L,1); /* remove lightuserdata with clss from stack */ - /* Actuall work */ - const int result = SWIG_Lua_do_resolve_metamethod(L, clss, metamethod_name_idx, 1); + /* Actual work */ + result = SWIG_Lua_do_resolve_metamethod(L, clss, metamethod_name_idx, 1); if (!result) { - SWIG_Lua_pushferrstring(L,"The metamethod proxy is set, but it failed to find actuall metamethod. Memory corruption is most likely explanation."); + SWIG_Lua_pushferrstring(L,"The metamethod proxy is set, but it failed to find actual metamethod. Memory corruption is most likely explanation."); lua_error(L); return 0; } @@ -1374,10 +1387,14 @@ SWIGRUNTIME int SWIG_Lua_resolve_metamethod(lua_State *L) */ SWIGINTERN int SWIG_Lua_add_class_user_metamethod(lua_State *L, swig_lua_class *clss, const int metatable_index) { + int key_index; + int success = 0; + int i = 0; + /* metamethod name - on the top of the stack */ assert(lua_isstring(L,-1)); - const int key_index = lua_gettop(L); + key_index = lua_gettop(L); /* Check whether method is already defined in metatable */ lua_pushvalue(L,key_index); /* copy of the key */ @@ -1389,8 +1406,6 @@ SWIGINTERN int SWIG_Lua_add_class_user_metamethod(lua_State *L, swig_lua_class * lua_pop(L,1); /* Iterating over immediate bases */ - int success = 0; - int i = 0; for(i=0;clss->bases[i];i++) { const swig_lua_class *base = clss->bases[i]; @@ -1420,11 +1435,15 @@ SWIGINTERN int SWIG_Lua_add_class_user_metamethod(lua_State *L, swig_lua_class * SWIGINTERN void SWIG_Lua_add_class_user_metamethods(lua_State *L, swig_lua_class *clss) { + int metatable_index; + int metamethods_info_index; + int tostring_undefined; + SWIG_Lua_get_class_metatable(L, clss->fqname); - const int metatable_index = lua_gettop(L); + metatable_index = lua_gettop(L); SWIG_Lua_get_inheritable_metamethods(L); assert(lua_istable(L,-1)); - const int metamethods_info_index = lua_gettop(L); + metamethods_info_index = lua_gettop(L); lua_pushnil(L); /* first key */ while(lua_next(L, metamethods_info_index) != 0 ) { /* key at index -2, value at index -1 */ @@ -1442,7 +1461,7 @@ SWIGINTERN void SWIG_Lua_add_class_user_metamethods(lua_State *L, swig_lua_class lua_pushstring(L, "__tostring"); lua_pushvalue(L,-1); lua_rawget(L,metatable_index); - const int tostring_undefined = lua_isnil(L,-1); + tostring_undefined = lua_isnil(L,-1); lua_pop(L,1); if( tostring_undefined ) { lua_pushcfunction(L, SWIG_Lua_class_tostring); @@ -1494,6 +1513,7 @@ SWIGINTERN void SWIG_Lua_class_register_static(lua_State *L, swig_lua_class *cls */ SWIGINTERN void SWIG_Lua_class_register_instance(lua_State *L,swig_lua_class *clss) { + int new_metatable_index; const int SWIGUNUSED begin = lua_gettop(L); int i; /* if name already there (class is already registered) then do nothing */ @@ -1520,11 +1540,12 @@ SWIGINTERN void SWIG_Lua_class_register_instance(lua_State *L,swig_lua_class *c * It would get us all special methods: __getitem, __add etc. * This would set .fn, .type, and other .xxx incorrectly, but we will overwrite it right away */ - const int new_metatable_index = lua_absindex(L,-1); + new_metatable_index = lua_absindex(L,-1); for(i=0;clss->bases[i];i++) { + int base_metatable; SWIG_Lua_get_class_metatable(L,clss->bases[i]->fqname); - const int base_metatable = lua_absindex(L,-1); + base_metatable = lua_absindex(L,-1); SWIG_Lua_merge_tables_by_index(L,new_metatable_index, base_metatable); lua_pop(L,1); } @@ -1573,6 +1594,7 @@ SWIGINTERN void SWIG_Lua_class_register_instance(lua_State *L,swig_lua_class *c SWIGINTERN void SWIG_Lua_class_register(lua_State *L,swig_lua_class *clss) { + int SWIGUNUSED begin; assert(lua_istable(L,-1)); /* This is a table (module or namespace) where classes will be added */ SWIG_Lua_class_register_instance(L,clss); SWIG_Lua_class_register_static(L,clss); @@ -1587,7 +1609,7 @@ SWIGINTERN void SWIG_Lua_class_register(lua_State *L,swig_lua_class *clss) * | ".set" --> .... * |=============================== ".instance" */ - const int SWIGUNUSED begin = lua_gettop(L); + begin = lua_gettop(L); lua_pushstring(L,clss->cls_static->name); lua_rawget(L,-2); /* get class static table */ assert(lua_istable(L,-1)); diff --git a/Lib/lua/luaruntime.swg b/Lib/lua/luaruntime.swg index 26dab93f6..89908044b 100644 --- a/Lib/lua/luaruntime.swg +++ b/Lib/lua/luaruntime.swg @@ -29,6 +29,7 @@ SWIGEXPORT int SWIG_init(lua_State* L) /* default Lua action */ { #if (SWIG_LUA_TARGET != SWIG_LUA_FLAVOR_ELUAC) /* valid for both Lua and eLua */ int i; + int globalRegister = 0; /* start with global table */ lua_pushglobaltable (L); /* SWIG's internal initialisation */ @@ -49,7 +50,6 @@ SWIGEXPORT int SWIG_init(lua_State* L) /* default Lua action */ SWIG_Lua_init_base_class(L,(swig_lua_class*)(swig_types[i]->clientdata)); } } - int globalRegister = 0; #ifdef SWIG_LUA_MODULE_GLOBAL globalRegister = 1; #endif diff --git a/Lib/lua/typemaps.i b/Lib/lua/typemaps.i index 7a095a1e0..c662cd31e 100644 --- a/Lib/lua/typemaps.i +++ b/Lib/lua/typemaps.i @@ -296,7 +296,7 @@ This is one giant macro to define the typemaps & the helpers for array handling */ %define SWIG_TYPEMAP_NUM_ARR(NAME,TYPE) -%{SWIG_DECLARE_TYPEMAP_ARR_FN(NAME,TYPE);%} +%{SWIG_DECLARE_TYPEMAP_ARR_FN(NAME,TYPE)%} // fixed size array's %typemap(in) TYPE INPUT[ANY] diff --git a/Lib/php/const.i b/Lib/php/const.i index 82c48022b..329b0cf07 100644 --- a/Lib/php/const.i +++ b/Lib/php/const.i @@ -34,12 +34,12 @@ SWIGTYPE &&, SWIGTYPE [] { zval *z_var; + zend_constant c; + size_t len = sizeof("$symname") - 1; MAKE_STD_ZVAL(z_var); SWIG_SetPointerZval(z_var, (void*)$value, $1_descriptor, 0); - zend_constant c; c.value = *z_var; zval_copy_ctor(&c.value); - size_t len = sizeof("$symname") - 1; c.name = zend_strndup("$symname", len); c.name_len = len+1; c.flags = CONST_CS | CONST_PERSISTENT; diff --git a/Lib/php/utils.i b/Lib/php/utils.i index 4e53e25a7..408a3b366 100644 --- a/Lib/php/utils.i +++ b/Lib/php/utils.i @@ -92,6 +92,7 @@ %fragment("t_output_helper","header") %{ static void t_output_helper(zval **target, zval *o TSRMLS_DC) { + zval *tmp; if ( (*target)->type == IS_ARRAY ) { /* it's already an array, just append */ add_next_index_zval( *target, o ); @@ -102,7 +103,6 @@ t_output_helper(zval **target, zval *o TSRMLS_DC) { FREE_ZVAL(o); return; } - zval *tmp; ALLOC_INIT_ZVAL(tmp); *tmp = **target; zval_copy_ctor(tmp); diff --git a/Lib/ruby/file.i b/Lib/ruby/file.i index d64937ed1..f9aaa2754 100644 --- a/Lib/ruby/file.i +++ b/Lib/ruby/file.i @@ -4,7 +4,7 @@ extern "C" { #endif -// Ruby 1.9 changed the file name of this header +/* Ruby 1.9 changed the file name of this header */ #ifdef HAVE_RUBY_IO_H #include "ruby/io.h" #else -- cgit v1.2.1 From c2368a40b244e3454a0300e5c671ebe6e98048ab Mon Sep 17 00:00:00 2001 From: William S Fulton Date: Sat, 24 May 2014 09:30:37 +0100 Subject: Javascript warnings for c++98 - remove vla --- Lib/javascript/jsc/javascriptstrings.swg | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Lib/javascript/jsc/javascriptstrings.swg b/Lib/javascript/jsc/javascriptstrings.swg index 10a0e252a..b3f46ae41 100644 --- a/Lib/javascript/jsc/javascriptstrings.swg +++ b/Lib/javascript/jsc/javascriptstrings.swg @@ -53,7 +53,7 @@ SWIG_JSC_FromCharPtrAndSize(JSContextRef context, const char* carray, size_t siz } else { JSStringRef jsstring; if(size < 2) { - char c[size+1]; + char c[2]; int i; for(i=0;i Date: Sat, 24 May 2014 10:12:06 +0100 Subject: Refactor Lua class base search to make ISO c/c++ compliant --- Lib/lua/luarun.swg | 85 +++++++++++++++++++++++++++--------------------------- 1 file changed, 43 insertions(+), 42 deletions(-) diff --git a/Lib/lua/luarun.swg b/Lib/lua/luarun.swg index 1dd3b9f09..6f2068e7a 100644 --- a/Lib/lua/luarun.swg +++ b/Lib/lua/luarun.swg @@ -708,46 +708,6 @@ SWIGINTERN void SWIG_Lua_namespace_register(lua_State *L, swig_lua_namespace *ns SWIGINTERN void SWIG_Lua_get_class_metatable(lua_State *L,const char *cname); -/* Macros for iteration among class bases */ -#if (SWIG_LUA_TARGET == SWIG_LUA_FLAVOR_LUA) -#define SWIG_LUA_INIT_BASE_SEARCH(bases_count)\ - (void)swig_type;\ - SWIG_Lua_get_table(L,".bases");\ - assert(lua_istable(L,-1));\ - bases_count = lua_rawlen(L,-1);\ - const int bases_table = lua_gettop(L); -#define SWIG_LUA_GET_BASE_METATABLE(i,base_swig_type, valid)\ - lua_rawgeti(L,bases_table,i+1);\ - base_swig_type = 0;\ - if(lua_isnil(L,-1)) {\ - valid = 0;\ - lua_pop(L,1);\ - } else\ - valid = 1; - -#else /* In elua .bases table doesn't exist. Use table from swig_lua_class */ - -#define SWIG_LUA_INIT_BASE_SEARCH(bases_count)\ - assert(swig_type!=0);\ - swig_module_info *module=SWIG_GetModule(L);\ - swig_lua_class **bases= ((swig_lua_class*)(swig_type->clientdata))->bases;\ - const char **base_names= ((swig_lua_class*)(swig_type->clientdata))->base_names;\ - bases_count = 0;\ - for(;base_names[bases_count];bases_count++);/* get length of bases */ - -#define SWIG_LUA_GET_BASE_METATABLE(i,base_swig_type, valid)\ - swig_lua_class *base_class = bases[i];\ - if(!base_class)\ - valid = 0;\ - else {\ - valid = 1;\ - SWIG_Lua_get_class_metatable(L,base_class->fqname);\ - base_swig_type = SWIG_TypeQueryModule(module,module,base_names[i]);\ - assert(base_swig_type != 0);\ - } - -#endif - typedef int (*swig_lua_base_iterator_func)(lua_State*,swig_type_info*, int, int *ret); SWIGINTERN int SWIG_Lua_iterate_bases(lua_State *L, swig_type_info * SWIGUNUSED swig_type, @@ -759,8 +719,28 @@ SWIGINTERN int SWIG_Lua_iterate_bases(lua_State *L, swig_type_info * SWIGUNUSED int original_metatable = last_arg + 1; size_t bases_count; int result = SWIG_ERROR; + int bases_table; + (void)swig_type; lua_getmetatable(L,first_arg); - SWIG_LUA_INIT_BASE_SEARCH(bases_count); + + /* initialise base search */ +#if (SWIG_LUA_TARGET == SWIG_LUA_FLAVOR_LUA) + SWIG_Lua_get_table(L,".bases"); + assert(lua_istable(L,-1)); + bases_count = lua_rawlen(L,-1); + bases_table = lua_gettop(L); +#else + /* In elua .bases table doesn't exist. Use table from swig_lua_class */ + (void)bases_table; + assert(swig_type!=0); + swig_module_info *module=SWIG_GetModule(L); + swig_lua_class **bases= ((swig_lua_class*)(swig_type->clientdata))->bases; + const char **base_names= ((swig_lua_class*)(swig_type->clientdata))->base_names; + bases_count = 0; + for(;base_names[bases_count]; + bases_count++);/* get length of bases */ +#endif + if(ret) *ret = 0; if(bases_count>0) @@ -778,7 +758,28 @@ SWIGINTERN int SWIG_Lua_iterate_bases(lua_State *L, swig_type_info * SWIGUNUSED /* Trick: temporarily replacing original metatable with metatable for base class and call getter */ for(i=0;ifqname); + base_swig_type = SWIG_TypeQueryModule(module,module,base_names[i]); + assert(base_swig_type != 0); + } +#endif + if(!valid) continue; assert(lua_isuserdata(L, subcall_first_arg)); -- cgit v1.2.1 From ab86f8a8f51a877615f173c37cd9da34f8bd5905 Mon Sep 17 00:00:00 2001 From: William S Fulton Date: Sat, 24 May 2014 10:29:34 +0100 Subject: Warning fixes in test-suite --- Examples/test-suite/smart_pointer_templatemethods.i | 2 +- Examples/test-suite/struct_initialization.i | 2 +- Examples/test-suite/typemap_array_qualifiers.i | 14 +++++++------- 3 files changed, 9 insertions(+), 9 deletions(-) diff --git a/Examples/test-suite/smart_pointer_templatemethods.i b/Examples/test-suite/smart_pointer_templatemethods.i index f79bbcc9d..bd8808aff 100644 --- a/Examples/test-suite/smart_pointer_templatemethods.i +++ b/Examples/test-suite/smart_pointer_templatemethods.i @@ -45,7 +45,7 @@ public: %template(QueryInterfaceObjct) Objct::QueryInterface; #endif -}; // namespace +} // namespace %} diff --git a/Examples/test-suite/struct_initialization.i b/Examples/test-suite/struct_initialization.i index c378ba31d..da1604f1b 100644 --- a/Examples/test-suite/struct_initialization.i +++ b/Examples/test-suite/struct_initialization.i @@ -3,7 +3,7 @@ %inline %{ -// Named types +/* Named types */ struct StructA { int x; } instanceA1; diff --git a/Examples/test-suite/typemap_array_qualifiers.i b/Examples/test-suite/typemap_array_qualifiers.i index 14df649d3..cbc6c95ff 100644 --- a/Examples/test-suite/typemap_array_qualifiers.i +++ b/Examples/test-suite/typemap_array_qualifiers.i @@ -43,8 +43,8 @@ $1 = 0; /* Correct typemap for $symname: $type */ } %inline %{ - void func1a(myarray x) {}; - void func1b(volatile myarray x) {}; + void func1a(myarray x) {} + void func1b(volatile myarray x) {} %} CLEAR_SWIGTYPE_TYPEMAPS; @@ -57,9 +57,9 @@ $1 = 0; /* Correct typemap for $symname: $type */ } %inline %{ - void func2a(const myarray x) {}; - void func2b(const myconstarray x) {}; - void func2c(const volatile myconstarray x) {}; + void func2a(const myarray x) {} + void func2b(const myconstarray x) {} + void func2c(const volatile myconstarray x) {} %} CLEAR_SWIGTYPE_TYPEMAPS; @@ -72,7 +72,7 @@ $1 = 0; /* Correct typemap for $symname: $type */ } %inline %{ - void func3a(const mycrazyarray x, const mycrazyarray y[7]) {}; + void func3a(const mycrazyarray x, const mycrazyarray y[7]) {} %} CLEAR_SWIGTYPE_TYPEMAPS; @@ -81,5 +81,5 @@ $1 = 0; /* Correct typemap for $symname: $type */ } %inline %{ - void func4a(mycrazyfunc *const x, const mycrazyfuncptr y) {}; + void func4a(mycrazyfunc *const x, const mycrazyfuncptr y) {} %} -- cgit v1.2.1 From 5990872cf741fa31523e2b72ee66fdc8d27da442 Mon Sep 17 00:00:00 2001 From: William S Fulton Date: Sat, 24 May 2014 00:12:00 +0100 Subject: Travis testing - examples use stricter CFLAGS and CXXFLAGS --- .travis.yml | 31 ++++++++++++++++++++++++++++++- 1 file changed, 30 insertions(+), 1 deletion(-) diff --git a/.travis.yml b/.travis.yml index 96e4fc9a7..5859c946f 100644 --- a/.travis.yml +++ b/.travis.yml @@ -67,6 +67,35 @@ before_install: - if test "$SWIGLANG" = "python" -a "$PY3" -a -z "$VER"; then sudo apt-get install -qq python3-dev; fi - if test "$SWIGLANG" = "python" -a "$VER"; then sudo add-apt-repository -y ppa:fkrull/deadsnakes && sudo apt-get -qq update && sudo apt-get -qq install python${VER}-dev && export CONFIGOPTS="--with-python${PY3}=python${VER}"; fi - if test "$SWIGLANG" = "tcl"; then sudo apt-get -qq install tcl8.4-dev; fi + # Stricter compile flags for examples. Various headers and SWIG generated code prevents full use of -pedantic. + - declare -A CFLAGS_EXAMPLES && CFLAGS_EXAMPLES=( + ["csharp"]="-Werror -std=gnu89 -fdiagnostics-show-option -Wno-long-long -Wreturn-type" + ["go"]="-Werror -std=gnu89 -fdiagnostics-show-option -Wno-long-long -Wreturn-type" + ["guile"]="-Werror -std=gnu89 -fdiagnostics-show-option -Wno-long-long -Wreturn-type" + ["java"]="-Werror -std=gnu89 -fdiagnostics-show-option -pedantic -Wno-long-long -Wreturn-type" + ["javascript"]="-Werror -std=gnu89 -fdiagnostics-show-option -pedantic -Wno-long-long -Wreturn-type" + ["lua"]="-Werror -std=gnu89 -fdiagnostics-show-option -pedantic -Wno-long-long -Wreturn-type" + ["octave"]="-Werror -std=gnu89 -fdiagnostics-show-option -pedantic -Wno-long-long -Wreturn-type" + ["perl5"]="-Werror -std=gnu89 -fdiagnostics-show-option -Wno-long-long -Wreturn-type" + ["php"]="-Werror -std=gnu89 -fdiagnostics-show-option -Wno-long-long -Wreturn-type" + ["python"]="-Werror -std=gnu89 -fdiagnostics-show-option -Wno-long-long -Wreturn-type" + ["ruby"]="-Werror -std=gnu89 -fdiagnostics-show-option -Wno-long-long -Wreturn-type" + ["tcl"]="-Werror -std=gnu89 -fdiagnostics-show-option -Wno-long-long -Wreturn-type" + ) + - declare -A CXXFLAGS_EXAMPLES && CXXFLAGS_EXAMPLES=( + ["csharp"]="-Werror -std=c++98 -fdiagnostics-show-option -pedantic -Wno-long-long -Wreturn-type" + ["go"]="-Werror -std=c++98 -fdiagnostics-show-option -pedantic -Wno-long-long -Wreturn-type" + ["guile"]="-Werror -std=c++98 -fdiagnostics-show-option -Wno-long-long -Wreturn-type" + ["java"]="-Werror -std=c++98 -fdiagnostics-show-option -pedantic -Wno-long-long -Wreturn-type" + ["javascript"]="-Werror -std=c++98 -fdiagnostics-show-option -pedantic -Wno-long-long -Wreturn-type" + ["lua"]="-Werror -std=c++98 -fdiagnostics-show-option -pedantic -Wno-long-long -Wreturn-type" + ["octave"]="-Werror -std=c++98 -fdiagnostics-show-option -Wno-long-long -Wreturn-type" + ["perl5"]="-Werror -std=c++98 -fdiagnostics-show-option -Wno-long-long -Wreturn-type" + ["php"]="-Werror -std=c++98 -fdiagnostics-show-option -pedantic -Wno-long-long -Wreturn-type" + ["python"]="-Werror -std=c++98 -fdiagnostics-show-option -pedantic -Wno-long-long -Wreturn-type" + ["ruby"]="-Werror -std=c++98 -fdiagnostics-show-option -pedantic -Wno-long-long -Wreturn-type" + ["tcl"]="-Werror -std=c++98 -fdiagnostics-show-option -Wno-long-long -Wreturn-type" + ) - $CC --version - $CXX --version script: @@ -81,7 +110,7 @@ script: - if test -z "$SWIGLANG"; then sudo make -s install && swig -version && ccache-swig -V; fi - echo -en 'travis_fold:end:script.2\\r' - if test -n "$SWIGLANG"; then make -s check-$SWIGLANG-version; fi - - if test -n "$SWIGLANG"; then make -k $SWIGJOBS check-$SWIGLANG-examples; fi + - if test -n "$SWIGLANG"; then make -k $SWIGJOBS check-$SWIGLANG-examples CFLAGS="${CFLAGS_EXAMPLES[$SWIGLANG]}" CXXFLAGS="${CXXFLAGS_EXAMPLES[$SWIGLANG]}"; fi - if test -n "$SWIGLANG"; then make -k $SWIGJOBS check-$SWIGLANG-test-suite; fi - echo 'Cleaning...' && echo -en 'travis_fold:start:script.3\\r' - make maintainer-clean && ../../configure $CONFIGOPTS -- cgit v1.2.1 From 20ddfb7fcded992bd0e98b9ef8797104fe0900fd Mon Sep 17 00:00:00 2001 From: Harvey Falcic Date: Sat, 24 May 2014 13:22:41 -0400 Subject: Python 3 'surrogateescape' docs: fix div class for Python code --- Doc/Manual/Python.html | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/Doc/Manual/Python.html b/Doc/Manual/Python.html index 45725065d..6dc0ff9ba 100644 --- a/Doc/Manual/Python.html +++ b/Doc/Manual/Python.html @@ -5962,8 +5962,8 @@ When this method is called from Python 3, the return value is the following text string:

    -
    ->>> s = test.non_utf8_c_str()
    +
    +>>> s = example.non_utf8_c_str()
     >>> s
     'h\udce9llo wörld'
     
    @@ -5974,7 +5974,7 @@ bytes are represented as high surrogate characters that can be used to obtain the original byte sequence:

    -
    +
     >>> b = s.encode('utf-8', errors='surrogateescape')
     >>> b
     b'h\xe9llo w\xc3\xb6rld'
    @@ -5985,7 +5985,7 @@ One can then attempt a different encoding, if desired (or simply leave the
     byte string as a raw sequence of bytes for use in binary protocols):
     

    -
    +
     >>> b.decode('latin-1')
     'héllo wörld'
     
    @@ -5995,7 +5995,7 @@ Note, however, that text strings containing surrogate characters are rejected with the default strict codec error handler. For example:

    -
    +
     >>> with open('test', 'w') as f:
     ...     print(s, file=f)
     ...
    -- 
    cgit v1.2.1
    
    
    From bdc63e5a9faf8b2cc0a8b311ab0eea9edd026d02 Mon Sep 17 00:00:00 2001
    From: Karl Wette 
    Date: Sat, 24 May 2014 20:07:52 +0200
    Subject: Remove example Makefiles when running distclean-examples in
     out-of-src build
    
    ---
     Makefile.in | 5 +++++
     1 file changed, 5 insertions(+)
    
    diff --git a/Makefile.in b/Makefile.in
    index da9dfdce5..a040d41a1 100644
    --- a/Makefile.in
    +++ b/Makefile.in
    @@ -420,6 +420,11 @@ distclean-examples:
     	@echo distcleaning Examples
     	@$(MAKE) $(FLAGS) clean-examples
     	@cd Examples && $(MAKE) $(FLAGS) distclean
    +	@if test "x$(srcdir)" != "x."; then \
    +		for mkfile in `cd $(srcdir) && find Examples/ -type f -name Makefile`; do \
    +			rm -f "$$mkfile"; \
    +		done; \
    +	fi
     
     distclean-ccache:
     	@test -z "$(ENABLE_CCACHE)" || (cd $(CCACHE) && $(MAKE) $(FLAGS) distclean)
    -- 
    cgit v1.2.1
    
    
    From 3e978fce9ff9d655a7e9469a59c5d6ccc73fb7cb Mon Sep 17 00:00:00 2001
    From: Karl Wette 
    Date: Sat, 24 May 2014 20:25:56 +0200
    Subject: Record files left over after maintainer-clean in Travis build
    
    ---
     .travis.yml | 2 +-
     1 file changed, 1 insertion(+), 1 deletion(-)
    
    diff --git a/.travis.yml b/.travis.yml
    index 5859c946f..89bed90a1 100644
    --- a/.travis.yml
    +++ b/.travis.yml
    @@ -113,7 +113,7 @@ script:
       - if test -n "$SWIGLANG"; then make -k $SWIGJOBS check-$SWIGLANG-examples CFLAGS="${CFLAGS_EXAMPLES[$SWIGLANG]}" CXXFLAGS="${CXXFLAGS_EXAMPLES[$SWIGLANG]}"; fi
       - if test -n "$SWIGLANG"; then make -k $SWIGJOBS check-$SWIGLANG-test-suite; fi
       - echo 'Cleaning...' && echo -en 'travis_fold:start:script.3\\r'
    -  - make maintainer-clean && ../../configure $CONFIGOPTS
    +  - make maintainer-clean && find . -type f | sed 's/^/File left after maintainer-clean - /' && ../../configure $CONFIGOPTS
       - echo -en 'travis_fold:end:script.3\\r'
     branches:
       only:
    -- 
    cgit v1.2.1
    
    
    From 5c5dfc106f00b4125f1ae7a173463afc8cdeccad Mon Sep 17 00:00:00 2001
    From: Harvey Falcic 
    Date: Sat, 24 May 2014 15:39:53 -0400
    Subject: Python unicode_strings test case: restrict to Python > 3.0
    
    Also adjust the test method names and content to match the docs.
    ---
     Examples/test-suite/python/unicode_strings_runme.py | 7 +++++--
     Examples/test-suite/unicode_strings.i               | 8 ++++----
     2 files changed, 9 insertions(+), 6 deletions(-)
    
    diff --git a/Examples/test-suite/python/unicode_strings_runme.py b/Examples/test-suite/python/unicode_strings_runme.py
    index 2d26599aa..162f40972 100644
    --- a/Examples/test-suite/python/unicode_strings_runme.py
    +++ b/Examples/test-suite/python/unicode_strings_runme.py
    @@ -1,4 +1,7 @@
    +import sys
    +
     import unicode_strings
     
    -unicode_strings.test_c_str()
    -unicode_strings.test_std_string()
    +if sys.version_info > (3, 0):
    +    unicode_strings.non_utf8_c_str()
    +    unicode_strings.non_utf8_std_string()
    diff --git a/Examples/test-suite/unicode_strings.i b/Examples/test-suite/unicode_strings.i
    index f4a8b8b50..56063c8a4 100644
    --- a/Examples/test-suite/unicode_strings.i
    +++ b/Examples/test-suite/unicode_strings.i
    @@ -4,12 +4,12 @@
     
     %inline %{
     
    -const char* test_c_str(void) {
    -        return "h\xe9llo";
    +const char* non_utf8_c_str(void) {
    +        return "h\xe9llo w\xc3\xb6rld";
     }
     
    -std::string test_std_string(void) {
    -        return std::string("h\xe9llo");
    +std::string non_utf8_std_string(void) {
    +        return std::string("h\xe9llo w\xc3\xb6rld");
     }
     
     %}
    -- 
    cgit v1.2.1
    
    
    From 2533d0210fb2f3b2e9f441c38bd03b99f4a57a44 Mon Sep 17 00:00:00 2001
    From: Harvey Falcic 
    Date: Sat, 24 May 2014 16:50:33 -0400
    Subject: unicode_strings test: check return values
    
    ---
     Examples/test-suite/python/unicode_strings_runme.py | 9 +++++++--
     1 file changed, 7 insertions(+), 2 deletions(-)
    
    diff --git a/Examples/test-suite/python/unicode_strings_runme.py b/Examples/test-suite/python/unicode_strings_runme.py
    index 162f40972..0e2e1af06 100644
    --- a/Examples/test-suite/python/unicode_strings_runme.py
    +++ b/Examples/test-suite/python/unicode_strings_runme.py
    @@ -2,6 +2,11 @@ import sys
     
     import unicode_strings
     
    +# The 'u' string prefix isn't valid in Python 3.0 - 3.2 and is redundant
    +# in 3.3+. Since this file is run through 2to3 before testing, though,
    +# mark this as a unicode string in 2.x so it'll become a str in 3.x.
    +test_string = u'h\udce9llo w\u00f6rld'
    +
     if sys.version_info > (3, 0):
    -    unicode_strings.non_utf8_c_str()
    -    unicode_strings.non_utf8_std_string()
    +    assert unicode_strings.non_utf8_c_str() == test_string
    +    assert unicode_strings.non_utf8_std_string() == test_string
    -- 
    cgit v1.2.1
    
    
    From ab527b0e4bf592e55b038a6de0fb8fe4540eea92 Mon Sep 17 00:00:00 2001
    From: Harvey Falcic 
    Date: Sat, 24 May 2014 17:54:53 -0400
    Subject: unicode_strings_runme.py: fix version check
    
    Python 3.0.1 shouldn't pass.
    ---
     Examples/test-suite/python/unicode_strings_runme.py | 2 +-
     1 file changed, 1 insertion(+), 1 deletion(-)
    
    diff --git a/Examples/test-suite/python/unicode_strings_runme.py b/Examples/test-suite/python/unicode_strings_runme.py
    index 0e2e1af06..2110c5ce7 100644
    --- a/Examples/test-suite/python/unicode_strings_runme.py
    +++ b/Examples/test-suite/python/unicode_strings_runme.py
    @@ -7,6 +7,6 @@ import unicode_strings
     # mark this as a unicode string in 2.x so it'll become a str in 3.x.
     test_string = u'h\udce9llo w\u00f6rld'
     
    -if sys.version_info > (3, 0):
    +if sys.version_info[0:2] >= (3, 1):
         assert unicode_strings.non_utf8_c_str() == test_string
         assert unicode_strings.non_utf8_std_string() == test_string
    -- 
    cgit v1.2.1
    
    
    From 91e93838fc6dbc181181f6ffacb024b6a87cfe63 Mon Sep 17 00:00:00 2001
    From: Harvey Falcic 
    Date: Sat, 24 May 2014 18:00:04 -0400
    Subject: unicode_strings test: manually check values instead of using assert
    
    ---
     Examples/test-suite/python/unicode_strings_runme.py | 6 ++++--
     1 file changed, 4 insertions(+), 2 deletions(-)
    
    diff --git a/Examples/test-suite/python/unicode_strings_runme.py b/Examples/test-suite/python/unicode_strings_runme.py
    index 2110c5ce7..e1fc7adec 100644
    --- a/Examples/test-suite/python/unicode_strings_runme.py
    +++ b/Examples/test-suite/python/unicode_strings_runme.py
    @@ -8,5 +8,7 @@ import unicode_strings
     test_string = u'h\udce9llo w\u00f6rld'
     
     if sys.version_info[0:2] >= (3, 1):
    -    assert unicode_strings.non_utf8_c_str() == test_string
    -    assert unicode_strings.non_utf8_std_string() == test_string
    +    if unicode_strings.non_utf8_c_str() != test_string:
    +        raise ValueError('Test comparison mismatch')
    +    if unicode_strings.non_utf8_std_string() != test_string:
    +        raise ValueError('Test comparison mismatch')
    -- 
    cgit v1.2.1
    
    
    From 575ac1c170cbfb9de6ced5f9e7075b928d4a4227 Mon Sep 17 00:00:00 2001
    From: William S Fulton 
    Date: Sun, 25 May 2014 00:01:24 +0100
    Subject: Add 3.0.1 release notes summary
    
    ---
     RELEASENOTES | 8 ++++++++
     1 file changed, 8 insertions(+)
    
    diff --git a/RELEASENOTES b/RELEASENOTES
    index 949f58e38..542ff4b10 100644
    --- a/RELEASENOTES
    +++ b/RELEASENOTES
    @@ -4,6 +4,14 @@ and CHANGES files.
     
     Release Notes
     =============
    +SWIG-3.0.1 summary:
    +- Javascript module added. This supports JavascriptCore (Safari/Webkit),
    +  v8 (Chromium) and node.js currently.
    +- A few notable regressions introduced in 3.0.0 have been fixed - in 
    +  Lua, nested classes and parsing of operator <<.
    +- The usual round of bug fixes and minor improvements for:
    +  C#, GCJ, Go, Java, Lua, PHP and Python.
    +
     SWIG-3.0.0 summary:
     - This is a major new release focusing primarily on C++ improvements.
     - C++11 support added. Please see documentation for details of supported
    -- 
    cgit v1.2.1
    
    
    From 4ab2eb96cd34503f2ceaa3ee88c22801cb546dda Mon Sep 17 00:00:00 2001
    From: William S Fulton 
    Date: Sun, 25 May 2014 00:29:32 +0100
    Subject: R examples building out-of-source
    
    They still don't run though
    ---
     Examples/Makefile.in | 6 +++---
     1 file changed, 3 insertions(+), 3 deletions(-)
    
    diff --git a/Examples/Makefile.in b/Examples/Makefile.in
    index 3a91cddd3..caf848596 100644
    --- a/Examples/Makefile.in
    +++ b/Examples/Makefile.in
    @@ -14,7 +14,7 @@
     #
     # 2.   To use this makefile, set required variables, eg SRCS, INTERFACE,
     #      INTERFACEDIR, INCLUDES, LIBS, TARGET, and do a
    -#           $(MAKE) -f Makefile.template.in SRCS='$(SRCS)' \
    +#           $(MAKE) -f Makefile.template.in SRCDIR='$(SRCDIR)' SRCS='$(SRCS)' \
     #           INCLUDES='$(INCLUDES) LIBS='$(LIBS)' INTERFACE='$(INTERFACE)' \
     #           INTERFACEDIR='$(INTERFACEDIR)' TARGET='$(TARGET)' method
     #
    @@ -1660,7 +1660,7 @@ r: $(SRCDIR_SRCS)
     ifneq ($(SRCDIR_SRCS),)
     	$(CC) -g -c $(CPPFLAGS) $(CFLAGS) $(R_CFLAGS) $(SRCDIR_SRCS) $(INCLUDES)
     endif
    -	+( PKG_CPPFLAGS="$(INCLUDES)" $(COMPILETOOL) $(R) CMD SHLIB -o $(LIBPREFIX)$(TARGET)$(SO) $(ISRCS) $(OBJS) > /dev/null )
    +	+( PKG_CPPFLAGS="$(CPPFLAGS) $(INCLUDES)" $(COMPILETOOL) $(R) CMD SHLIB -o $(LIBPREFIX)$(TARGET)$(SO) $(ISRCS) $(OBJS) > /dev/null )
     
     # ----------------------------------------------------------------
     # Build a R dynamically loadable module (C++)
    @@ -1671,7 +1671,7 @@ r_cpp: $(SRCDIR_CXXSRCS)
     ifneq ($(SRCDIR_CXXSRCS),)
     	$(CXX) -g -c $(CPPFLAGS) $(CXXFLAGS) $(R_CFLAGS) $(SRCDIR_CXXSRCS) $(INCLUDES)
     endif
    -	+( PKG_CPPFLAGS="$(INCLUDES)" $(COMPILETOOL) $(R) CMD SHLIB -o $(LIBPREFIX)$(TARGET)$(SO) $(RCXXSRCS) $(OBJS) > /dev/null )
    +	+( PKG_CPPFLAGS="$(CPPFLAGS) $(INCLUDES)" $(COMPILETOOL) $(R) CMD SHLIB -o $(LIBPREFIX)$(TARGET)$(SO) $(RCXXSRCS) $(OBJS) > /dev/null )
     
     # -----------------------------------------------------------------
     # Run R example
    -- 
    cgit v1.2.1
    
    
    From 597c671e8630f959b48d716ffbc0be57990dc585 Mon Sep 17 00:00:00 2001
    From: William S Fulton 
    Date: Sun, 25 May 2014 12:00:42 +0100
    Subject: More diagnostics for csharp_exceptions testcase for diagnosing
     erratic failures
    
    ---
     Examples/test-suite/csharp/csharp_exceptions_runme.cs | 6 ++++--
     1 file changed, 4 insertions(+), 2 deletions(-)
    
    diff --git a/Examples/test-suite/csharp/csharp_exceptions_runme.cs b/Examples/test-suite/csharp/csharp_exceptions_runme.cs
    index 43585b106..51805ce87 100644
    --- a/Examples/test-suite/csharp/csharp_exceptions_runme.cs
    +++ b/Examples/test-suite/csharp/csharp_exceptions_runme.cs
    @@ -323,7 +323,9 @@ public class TestThread {
              } catch (ArgumentOutOfRangeException e) {
                String expectedMessage = "caught:" + i + "\n" + "Parameter name: input";
                if (e.Message.Replace(runme.CRLF,"\n") != expectedMessage)
    -             throw new Exception("Exception message incorrect. Expected:\n[" + expectedMessage + "]\n" + "Received:\n[" + e.Message + "]");
    +             throw new Exception("Exception message incorrect. Expected:\n[" + 
    +                 expectedMessage + "]\n" + "Received:\n[" + 
    +                 e.Message + "]");
                if (e.ParamName != "input")
                  throw new Exception("Exception ParamName incorrect. Expected:\n[input]\n" + "Received:\n[" + e.ParamName + "]");
                if (e.InnerException != null)
    @@ -333,7 +335,7 @@ public class TestThread {
                throw new Exception("throwsException.dub = " + throwsClass.dub + " expected: 1234.5678");
            }
          } catch (Exception e) {
    -       Console.Error.WriteLine("Test failed (thread " + threadId + "): " + e.Message);
    +       Console.Error.WriteLine("Test failed (thread " + threadId + "): " + e.Message + "\n  TestThread Inner stack trace: " + e.StackTrace);
            Failed = true;
          }
        }
    -- 
    cgit v1.2.1
    
    
    From 01f8253b192224d8996e5bffd3c8121fa32ad0ea Mon Sep 17 00:00:00 2001
    From: Oliver Buchtala 
    Date: Mon, 26 May 2014 21:38:00 +0200
    Subject: Javascript: added a section about known issues.
    
    ---
     Doc/Manual/Javascript.html | 32 +++++++++++---------------------
     1 file changed, 11 insertions(+), 21 deletions(-)
    
    diff --git a/Doc/Manual/Javascript.html b/Doc/Manual/Javascript.html
    index 011e61051..e6f422bd8 100644
    --- a/Doc/Manual/Javascript.html
    +++ b/Doc/Manual/Javascript.html
    @@ -128,33 +128,23 @@ $ make check-javascript-examples ENGINE=jsc
     $ make check-javascript-test-suite ENGINE=jsc
    -

    Tests should run without any problems, i.e., have been tried out, on the following platforms/interpreters:

    -
    -
    -- Ubuntu Precise 12.04 64bit
    -    - JavascriptCore (Webkit 1.8.3)
    -    - Node.js (0.10.26)
    -    - v8 (3.7.12)
    -- Ubuntu Saucy 13.10 64bit
    -    - JavascriptCore (Webkit 1.10.2)
    -    - Node.js
    -    - v8 (3.14.5)
    -- Mac OSX Mountain Lion 10.8
    -    - JavascriptCore (built-in)
    -    - Node.js
    -- Windows 7 64bit (VS 2010)
    -    - Node.js
    -
    -

    26.2.3 Future work

    +

    26.2.1 Known Issues

    +

    At the moment, the Javascript generators pass all tests syntactically, i.e., the generated source code compiles. However, there are still remaining runtime issues.

    -

    The Javascript module is not yet as mature as other modules and some things are still missing. As it makes use of SWIG's Unified Typemap Library (UTL), many typemaps are inherited. We could work on that if requested:

      -
    • More typemaps: compared to other modules there are only a few typemaps implemented. For instance a lot of the std_*.i typemaps are missing, such as std_iostream, for instance.

    • -
    • Director support: this would allow to extend a C++ abstract base class in Javascript. A pragmatic intermediate step for the most important usecase would be to support Javascript callbacks as arguments.

    • +
    • Default optional arguments do not work for all targeted interpreters

    • +
    • Mutliple output arguments do not work for JSC

    • +
    • Memory leaks have been observed for all generators

    • +
    • C89 incompatibily: the JSC generator might still generate C89 violating code

    • +
    • long long is not supported q

    • +
    • Javascript callbacks are not supported

    • +
    • instanceOf does not work under JSC

    +

    The primary development environment has been Linux (Ubuntu 12.04). Windows and OSX have been tested sporadically. Therefore, the generators might have more issues on those platforms. Please report back any problem you observe to help us improving this module quickly.

    +

    26.3 Integration

    -- cgit v1.2.1 From 6f69555225d818530e60cc50a7cd57f8bafd46f1 Mon Sep 17 00:00:00 2001 From: Eric Wing Date: Mon, 19 May 2014 17:15:49 -0700 Subject: JavaScriptCore: Fixed exception object so sourceURL (file name), line (number), and message can be recovered. The current implementation only returns an error string. But this is insufficient for debugging (what file and line number did it fail at?). As documented here: http://parmanoir.com/Taming_JavascriptCore_within_and_without_WebView converting the JSValueRef of string to an JSObjectRef (via JSValueToObject) will trigger JSCore into filling the "sourceURL" and "line" properties into the object so they can be inspected by the caller. Additionally, JavaScriptCore has a "message" property which contains the message string. JSCore doesn't seem to be filling this in for us automatically, unlike "sourceURL" and "line". So this patch also fills that property in too. Thanks to Brian Barnes for the detailed information about "sourceURL", "line", and "message". Below is an example (derived from Brian Barnes's information) on how you typically use/extract these exception details. void script_exception_to_string(JSContextRef js_context,JSValueRef exception_value_ref,char* return_error_string, int return_error_string_max_length) { JSObjectRef exception_object; JSValueRef value_ref; JSStringRef jsstring_property_name = NULL; JSValueRef temporary_exception = NULL; JSStringRef js_return_string = NULL; size_t bytes_needed; char* c_result_string = NULL; exception_object = JSValueToObject(js_context, exception_value_ref, NULL); // source and line numbers strcpy(return_error_string,"["); jsstring_property_name = JSStringCreateWithUTF8CString("sourceURL"); value_ref = JSObjectGetProperty(js_context, exception_object, jsstring_property_name, &temporary_exception); JSStringRelease(jsstring_property_name); js_return_string = JSValueToStringCopy(js_context, value_ref, NULL); bytes_needed = JSStringGetMaximumUTF8CStringSize(js_return_string); c_result_string = (char*)calloc(bytes_needed, sizeof(char)); JSStringGetUTF8CString(js_return_string, c_result_string, bytes_needed); SDL_Log("c_result_string: %s\n", c_result_string); JSStringRelease(js_return_string); strncat(return_error_string, c_result_string, return_error_string_max_length-1); free(c_result_string); strncat(return_error_string, ":", return_error_string_max_length-1); jsstring_property_name = JSStringCreateWithUTF8CString("line"); value_ref = JSObjectGetProperty(js_context, exception_object, jsstring_property_name, &temporary_exception); JSStringRelease(jsstring_property_name); js_return_string = JSValueToStringCopy(js_context, value_ref, NULL); bytes_needed = JSStringGetMaximumUTF8CStringSize(js_return_string); c_result_string = (char*)calloc(bytes_needed, sizeof(char)); JSStringGetUTF8CString(js_return_string, c_result_string, bytes_needed); SDL_Log("c_result_string: %s\n", c_result_string); JSStringRelease(js_return_string); strncat(return_error_string, c_result_string, return_error_string_max_length-1); //SDL_Log("c_result_string: %s\n", c_result_string); free(c_result_string); strncat(return_error_string, "]", return_error_string_max_length-1); /* get message */ jsstring_property_name = JSStringCreateWithUTF8CString("message"); value_ref = JSObjectGetProperty(js_context, exception_object, jsstring_property_name, &temporary_exception); JSStringRelease(jsstring_property_name); if(NULL == value_ref) { strncat(return_error_string, "Unknown Error", return_error_string_max_length-1); } else { js_return_string = JSValueToStringCopy(js_context, value_ref, NULL); bytes_needed = JSStringGetMaximumUTF8CStringSize(js_return_string); c_result_string = (char*)calloc(bytes_needed, sizeof(char)); JSStringGetUTF8CString(js_return_string, c_result_string, bytes_needed); SDL_Log("c_result_string: %s\n", c_result_string); JSStringRelease(js_return_string); strncat(return_error_string, c_result_string, return_error_string_max_length-1); //SDL_Log("c_result_string: %s\n", c_result_string); free(c_result_string); } } To use: if(js_exception) { char return_error_string[256]; script_exception_to_string(js_context, js_exception, return_error_string, 256); SDL_Log("Compile error is %s", return_error_string); } --- Lib/javascript/jsc/javascriptrun.swg | 25 +++++++++++++++++++++++-- 1 file changed, 23 insertions(+), 2 deletions(-) diff --git a/Lib/javascript/jsc/javascriptrun.swg b/Lib/javascript/jsc/javascriptrun.swg index ae1567e87..1fde8855b 100644 --- a/Lib/javascript/jsc/javascriptrun.swg +++ b/Lib/javascript/jsc/javascriptrun.swg @@ -9,8 +9,29 @@ SWIGRUNTIME void SWIG_Javascript_Raise(JSContextRef context, JSValueRef *exception, const char* type) { JSStringRef message = JSStringCreateWithUTF8CString(type); - *exception = JSValueMakeString(context, message); - JSStringRelease(message); + JSStringRef message_property_key; + JSObjectRef exception_object; + JSValueRef exception_value; + JSValueRef message_value; + exception_value = JSValueMakeString(context, message); + /* Converting the result to an object will let JavascriptCore add "sourceURL" (file) and "line" (number) to the exception, + instead of just returning a raw string. This is extremely important for debugging your errors. + */ + exception_object = JSValueToObject(context, exception_value, NULL); + + /* Additionally, JSCore uses "message" which contains the error description. + But it seems that unlike "sourceURL" and "line", converting to an object is not automatically doing this. + So we can add it ourselves. + */ + message_property_key = JSStringCreateWithUTF8CString("message"); + message_value = JSValueMakeString(context, message); + JSObjectSetProperty(context, exception_object, message_property_key, message_value, kJSClassAttributeNone, NULL); + + /* Return the exception_object */ + *exception = exception_object; + + JSStringRelease(message_property_key); + JSStringRelease(message); } SWIGRUNTIME void SWIG_JSC_exception(JSContextRef context, JSValueRef *exception, int code, const char* msg) { -- cgit v1.2.1 From f1c331f2c5b5df607edb581cf7711b7f40d2fb09 Mon Sep 17 00:00:00 2001 From: Eric Wing Date: Mon, 19 May 2014 17:42:00 -0700 Subject: JavaScriptCore: Returning NULL for wrapper functions that expect JSValueRef may crash program. According to this: http://parmanoir.com/Taming_JavascriptCore_within_and_without_WebView Returning NULL instead of an actual JSValueRef for a return value of a function could lead to crashes. I think I have seen related weirdness in the past when I failed to return a proper type to JSCore which resulted in very hard to understand behavior. So this patch changes those return NULLs to return JSValueMakeUndefined(). I thought about JSObjectMakeError, but I don't fully understand the intent of the Error object and can't find any relevant real world examples of it being used. However, everybody seems to be using JSValueMakeUndefined(). This patch should be low impact since this is only triggered on an error condition. --- Lib/javascript/jsc/javascriptcode.swg | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/Lib/javascript/jsc/javascriptcode.swg b/Lib/javascript/jsc/javascriptcode.swg index 3fe9d49e9..f8c5a200f 100644 --- a/Lib/javascript/jsc/javascriptcode.swg +++ b/Lib/javascript/jsc/javascriptcode.swg @@ -17,7 +17,7 @@ static JSObjectRef $jswrapper(JSContextRef context, JSObjectRef thisObject, size return SWIG_JSC_NewPointerObj(context, result, SWIGTYPE_$jsmangledtype, SWIG_POINTER_OWN); goto fail; fail: - return NULL; + return JSValueMakeUndefined(context); } %} @@ -78,7 +78,7 @@ static JSObjectRef $jswrapper(JSContextRef context, JSObjectRef thisObject, size goto fail; fail: - return NULL; + return JSValueMakeUndefined(context); } %} @@ -159,7 +159,7 @@ static JSValueRef $jswrapper(JSContextRef context, JSObjectRef thisObject, JSStr goto fail; fail: - return NULL; + return JSValueMakeUndefined(context); } %} @@ -204,7 +204,7 @@ static JSValueRef $jswrapper(JSContextRef context, JSObjectRef function, JSObjec goto fail; fail: - return NULL; + return JSValueMakeUndefined(context); } %} @@ -229,7 +229,7 @@ static JSValueRef $jswrapper(JSContextRef context, JSObjectRef function, JSObjec goto fail; fail: - return NULL; + return JSValueMakeUndefined(context); } %} -- cgit v1.2.1 From e7b20624cc32d1220d5ad53370bfc1d92c8657c4 Mon Sep 17 00:00:00 2001 From: Eric Wing Date: Mon, 19 May 2014 19:00:43 -0700 Subject: JavaScriptCore: Reverted 2 of the JSValueMakeUndefined replacements because those functions are tied to JSObjectRef instead of JSValueRef. The C compiler will allow this, but C++ will reject the conversion. It is unclear what the correct handling is for JavaScriptCore. (Nobody bothers to document this in JSCore.) Unlike our other problem where we incorrectly assume JSObjectRef when the functions want JSValueRef, this time Apple is demanding the JSObjectRef. Like our other problem, I assume it is unsafe to try to convert Undefined into a JSObjectRef. So reverting to NULL seems like the safer bet for this specific case. Perhaps the other alternative is to return an exception object or an error object. But I would like to see JSCore document this before trying. --- Lib/javascript/jsc/javascriptcode.swg | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/Lib/javascript/jsc/javascriptcode.swg b/Lib/javascript/jsc/javascriptcode.swg index f8c5a200f..c18902fce 100644 --- a/Lib/javascript/jsc/javascriptcode.swg +++ b/Lib/javascript/jsc/javascriptcode.swg @@ -17,7 +17,7 @@ static JSObjectRef $jswrapper(JSContextRef context, JSObjectRef thisObject, size return SWIG_JSC_NewPointerObj(context, result, SWIGTYPE_$jsmangledtype, SWIG_POINTER_OWN); goto fail; fail: - return JSValueMakeUndefined(context); + return NULL; } %} @@ -78,7 +78,7 @@ static JSObjectRef $jswrapper(JSContextRef context, JSObjectRef thisObject, size goto fail; fail: - return JSValueMakeUndefined(context); + return NULL; } %} -- cgit v1.2.1 From 1766e67a1af127f42c908090e8d46b49de30ce19 Mon Sep 17 00:00:00 2001 From: Eric Wing Date: Wed, 21 May 2014 03:43:52 -0700 Subject: JavaScriptCore: Improved code that uses JSObjectMakeError instead of JSValueToObject to create the exception object. JSObjectMakeError automatically populates the "message" field, and possibly other fields I don't know about. This seems to be the most robust way to create an exception object. Thanks to Brian Barnes again for the tip on JSObjectMakeError. --- Lib/javascript/jsc/javascriptrun.swg | 40 +++++++++++++++--------------------- 1 file changed, 17 insertions(+), 23 deletions(-) diff --git a/Lib/javascript/jsc/javascriptrun.swg b/Lib/javascript/jsc/javascriptrun.swg index 1fde8855b..676a45833 100644 --- a/Lib/javascript/jsc/javascriptrun.swg +++ b/Lib/javascript/jsc/javascriptrun.swg @@ -8,30 +8,24 @@ #define SWIG_fail goto fail SWIGRUNTIME void SWIG_Javascript_Raise(JSContextRef context, JSValueRef *exception, const char* type) { - JSStringRef message = JSStringCreateWithUTF8CString(type); - JSStringRef message_property_key; - JSObjectRef exception_object; - JSValueRef exception_value; - JSValueRef message_value; - exception_value = JSValueMakeString(context, message); - /* Converting the result to an object will let JavascriptCore add "sourceURL" (file) and "line" (number) to the exception, - instead of just returning a raw string. This is extremely important for debugging your errors. - */ - exception_object = JSValueToObject(context, exception_value, NULL); - - /* Additionally, JSCore uses "message" which contains the error description. - But it seems that unlike "sourceURL" and "line", converting to an object is not automatically doing this. - So we can add it ourselves. + JSStringRef message = JSStringCreateWithUTF8CString(type); + JSValueRef error_arguments[1]; + JSObjectRef exception_object; + JSValueRef exception_value; + exception_value = JSValueMakeString(context, message); + /* Converting the result to an object will let JavascriptCore add + "sourceURL" (file) and "line" (number) and "message" to the exception, + instead of just returning a raw string. This is extremely important for debugging your errors. + Using JSObjectMakeError is better than JSValueToObject because the latter only populates + "sourceURL" and "line", but not "message" or any others I don't know about. */ - message_property_key = JSStringCreateWithUTF8CString("message"); - message_value = JSValueMakeString(context, message); - JSObjectSetProperty(context, exception_object, message_property_key, message_value, kJSClassAttributeNone, NULL); - - /* Return the exception_object */ - *exception = exception_object; - - JSStringRelease(message_property_key); - JSStringRelease(message); + error_arguments[0] = exception_value; + exception_object = JSObjectMakeError(context, 1, error_arguments, NULL); + + /* Return the exception_object */ + *exception = exception_object; + + JSStringRelease(message); } SWIGRUNTIME void SWIG_JSC_exception(JSContextRef context, JSValueRef *exception, int code, const char* msg) { -- cgit v1.2.1 From 1df7ca77a061b961e054689bc8b61e60ed9ad93d Mon Sep 17 00:00:00 2001 From: Oliver Buchtala Date: Tue, 27 May 2014 10:40:16 +0200 Subject: JavascriptCore: added documentation about how to extract details from JSC errors. This code is necessary for embedding applications to present details about JS exceptions. --- Doc/Manual/Javascript.html | 83 ++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 83 insertions(+) diff --git a/Doc/Manual/Javascript.html b/Doc/Manual/Javascript.html index e6f422bd8..246669a22 100644 --- a/Doc/Manual/Javascript.html +++ b/Doc/Manual/Javascript.html @@ -41,6 +41,7 @@
  • Code Templates
  • Emitter
  • Emitter states +
  • Handling Exceptions in JavascriptCore
  • @@ -870,5 +871,87 @@ state.clazz(RESET); state.clazz(NAME, Getattr(n, "sym:name"));

    State information can be retrieved using state.clazz(NAME) or with Getattr on state.clazz() which actually returns a Hash instance.

    + + +

    26.5.5. Handling Exceptions in JavascriptCore

    + + +

    Applications with an embedded JavascriptCore should be able to present detailed exception messages that occur in the Javascript engine. Below is an example derived from code provided by Brian Barnes on how these exception details can be extracted.

    +
    +
    +void script_exception_to_string(JSContextRef js_context,JSValueRef exception_value_ref,char* return_error_string, int return_error_string_max_length)
    +{
    +  JSObjectRef exception_object;
    +  JSValueRef value_ref;
    +  JSStringRef jsstring_property_name = NULL;
    +  JSValueRef temporary_exception = NULL;
    +  JSStringRef js_return_string = NULL;
    +  size_t bytes_needed;
    +  char* c_result_string = NULL;
    +  exception_object = JSValueToObject(js_context, exception_value_ref, NULL);
    +
    +  /* source url */
    +  strcpy(return_error_string,"[");
    +  jsstring_property_name = JSStringCreateWithUTF8CString("sourceURL");
    +  value_ref = JSObjectGetProperty(js_context, exception_object, jsstring_property_name, &temporary_exception);
    +  JSStringRelease(jsstring_property_name);
    +  js_return_string = JSValueToStringCopy(js_context, value_ref, NULL);
    +  bytes_needed = JSStringGetMaximumUTF8CStringSize(js_return_string);
    +  c_result_string = (char*)calloc(bytes_needed, sizeof(char));
    +  JSStringGetUTF8CString(js_return_string, c_result_string, bytes_needed);
    +  JSStringRelease(js_return_string);
    +  strncat(return_error_string, c_result_string, return_error_string_max_length-1);
    +  free(c_result_string);
    +
    +  strncat(return_error_string, ":", return_error_string_max_length-1);
    +
    +  /* line number */
    +
    +  jsstring_property_name = JSStringCreateWithUTF8CString("line");
    +  value_ref = JSObjectGetProperty(js_context, exception_object, jsstring_property_name, &temporary_exception);
    +  JSStringRelease(jsstring_property_name);
    +  js_return_string = JSValueToStringCopy(js_context, value_ref, NULL);
    +  bytes_needed = JSStringGetMaximumUTF8CStringSize(js_return_string);
    +  c_result_string = (char*)calloc(bytes_needed, sizeof(char));
    +  JSStringGetUTF8CString(js_return_string, c_result_string, bytes_needed);
    +  JSStringRelease(js_return_string);
    +  strncat(return_error_string, c_result_string, return_error_string_max_length-1);
    +  free(c_result_string);
    +
    +  strncat(return_error_string, "]", return_error_string_max_length-1);
    +
    +  /* error message */
    +
    +  jsstring_property_name = JSStringCreateWithUTF8CString("message");
    +  value_ref = JSObjectGetProperty(js_context, exception_object, jsstring_property_name, &temporary_exception);
    +  JSStringRelease(jsstring_property_name);
    +  if(NULL == value_ref)
    +  {
    +    strncat(return_error_string, "Unknown Error", return_error_string_max_length-1);
    +  }
    +  else
    +  {
    +    js_return_string = JSValueToStringCopy(js_context, value_ref, NULL);
    +    bytes_needed = JSStringGetMaximumUTF8CStringSize(js_return_string);
    +    c_result_string = (char*)calloc(bytes_needed, sizeof(char));
    +    JSStringGetUTF8CString(js_return_string, c_result_string, bytes_needed);
    +    JSStringRelease(js_return_string);
    +    strncat(return_error_string, c_result_string, return_error_string_max_length-1);
    +    free(c_result_string);
    +  }
    +}
    +
    + +

    It would be used in the following way:

    +
    +
    +if(js_exception)
    +{
    +  char return_error_string[256];
    +  script_exception_to_string(js_context, js_exception, return_error_string, 256);
    +  printf("Compile error is %s", return_error_string);
    +}
    +
    + -- cgit v1.2.1 From 5d307b2cbfc9e2caa06805df425161617868bea8 Mon Sep 17 00:00:00 2001 From: Oliver Buchtala Date: Tue, 27 May 2014 10:41:39 +0200 Subject: JavascriptCore: updated documentation about how to register an initialized module. --- Doc/Manual/Javascript.html | 24 +++++++++++++++++++++--- 1 file changed, 21 insertions(+), 3 deletions(-) diff --git a/Doc/Manual/Javascript.html b/Doc/Manual/Javascript.html index 246669a22..97197b670 100644 --- a/Doc/Manual/Javascript.html +++ b/Doc/Manual/Javascript.html @@ -223,13 +223,21 @@ $ sudo apt-get remove gyp
     #import "appDelegate.h"
     
    -extern bool example_initialize(JSGlobalContextRef context);
    +extern bool example_initialize(JSGlobalContextRef context, JSObjectRef* exports);
     
     
     @implementation ExampleAppDelegate
     
     @synthesize webView;
     
    +- (void)addGlobalObject:(JSContextRef) context:(NSString *)objectName:(JSObjectRef) theObject {
    +  JSObjectRef global = JSContextGetGlobalObject(context);
    +  JSStringRef objectJSName = JSStringCreateWithCFString( (CFStringRef) objectName )
    +  if ( objectJSName != NULL ) {
    +    JSObjectSetProperty(context, global, objectJSName, theObject, kJSPropertyAttributeReadOnly, NULL);
    +    JSStringRelease( objectJSName );
    +  }
    +}
     
     - (void)applicationDidFinishLaunching:(NSNotification *)aNotification {
     
    @@ -240,7 +248,11 @@ extern bool example_initialize(JSGlobalContextRef context);
       WebFrame *webframe = [webView mainFrame];
       JSGlobalContextRef context = [webframe globalContext];
     
    -  example_initialize(context);
    +  JSObjectRef example;
    +  example_initialize(context, &example);
    +  [self addGlobalObject:context:@"example":example]
    +
    +  JSObjectSetProperty(context, global, JSStringRef propertyName, example, JSPropertyAttributes attributes, NULL);
     
       [ [webView mainFrame] loadRequest:
         [NSURLRequest requestWithURL: [NSURL URLWithString:url] ]
    @@ -273,7 +285,13 @@ int main(int argc, char* argv[])
         WebKitWebView *webView = WEBKIT_WEB_VIEW(webkit_web_view_new());
         WebFrame *webframe = webkit_web_view_get_main_frame(webView);
         JSGlobalContextRef context = webkit_web_frame_get_global_context(webFrame);
    -    example_initialize(context);
    +    JSObjectRef global = JSContextGetGlobalObject(context);
    +
    +    JSObjectRef exampleModule;
    +    example_initialize(context, &exampleModule);
    +    JSStringRef jsName = JSStringCreateWithUTF8CString("example");
    +    JSObjectSetProperty(context, global, jsName, exampleModule, kJSPropertyAttributeReadOnly, NULL);
    +    JSStringRelease(jsName);
     
         ...
     
    -- 
    cgit v1.2.1
    
    
    From a22f97eb3337bdd0b58d6ec764aeb23395c31d70 Mon Sep 17 00:00:00 2001
    From: Oliver Buchtala 
    Date: Tue, 27 May 2014 10:44:13 +0200
    Subject: Javascript: updated documentation about known issues.
    
    [skip ci]
    ---
     Doc/Manual/Javascript.html | 6 +++---
     1 file changed, 3 insertions(+), 3 deletions(-)
    
    diff --git a/Doc/Manual/Javascript.html b/Doc/Manual/Javascript.html
    index 97197b670..a4cc02d02 100644
    --- a/Doc/Manual/Javascript.html
    +++ b/Doc/Manual/Javascript.html
    @@ -15,7 +15,7 @@
     
     
  • Integration
      @@ -137,9 +137,9 @@ $ make check-javascript-test-suite ENGINE=jsc
    • Default optional arguments do not work for all targeted interpreters

    • Mutliple output arguments do not work for JSC

    • -
    • Memory leaks have been observed for all generators

    • C89 incompatibily: the JSC generator might still generate C89 violating code

    • -
    • long long is not supported q

    • +
    • long long is not supported

    • +
    • %native is not supported

    • Javascript callbacks are not supported

    • instanceOf does not work under JSC

    -- cgit v1.2.1 From c342bc1b281d9da9a73d88bfe3fca617cc5dab2d Mon Sep 17 00:00:00 2001 From: Oliver Buchtala Date: Tue, 27 May 2014 21:37:18 +0200 Subject: Javascript: added a link to the v8 web-site to the documentation. --- Doc/Manual/Javascript.html | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Doc/Manual/Javascript.html b/Doc/Manual/Javascript.html index a4cc02d02..bfe91aa09 100644 --- a/Doc/Manual/Javascript.html +++ b/Doc/Manual/Javascript.html @@ -57,7 +57,7 @@

    Javascript is a prototype-based scripting language that is dynamic, weakly typed and has first-class functions. Its arguably the most popular language for web development. Javascript has gone beyond being a browser-based scripting language and with node.js, it is also used as a backend development language.

    Native Javascript extensions can be used for applications that embed a web-browser view or that embed a Javascript engine (such as node.js). Extending a general purpose web-browser is not possible as this would be a severe security issue.

    -

    SWIG Javascript currently supports JavascriptCore, the Javascript engine used by Safari/Webkit, and v8, which is used by Chromium and node.js.

    +

    SWIG Javascript currently supports JavascriptCore, the Javascript engine used by Safari/Webkit, and v8, which is used by Chromium and node.js.

    WebKit is a modern browser implementation available as open-source which can be embedded into an application. With node-webkit there is a platform which uses Google's Chromium as Web-Browser widget and node.js for javascript extensions.

    -- cgit v1.2.1 From b531956467f7e0e064cd9928c044be64fa0a3a0a Mon Sep 17 00:00:00 2001 From: William S Fulton Date: Tue, 27 May 2014 21:55:17 +0100 Subject: Warning fixes compiling with Visual Studio --- Source/Modules/javascript.cxx | 26 +++++++++++++------------- 1 file changed, 13 insertions(+), 13 deletions(-) diff --git a/Source/Modules/javascript.cxx b/Source/Modules/javascript.cxx index e535bc179..8b7a74037 100644 --- a/Source/Modules/javascript.cxx +++ b/Source/Modules/javascript.cxx @@ -724,19 +724,19 @@ int JSEmitter::emitWrapperFunction(Node *n) { // detected via the 'view' attribute. || (Equal(kind, "variable") && Equal(Getattr(n, "view"), "globalfunctionHandler")) ) { - bool is_member = GetFlag(n, "ismember") | GetFlag(n, "feature:extend"); - bool is_static = GetFlag(state.function(), IS_STATIC); + bool is_member = GetFlag(n, "ismember") != 0 || GetFlag(n, "feature:extend") != 0; + bool is_static = GetFlag(state.function(), IS_STATIC) != 0; ret = emitFunction(n, is_member, is_static); } else if (Cmp(kind, "variable") == 0) { - bool is_static = GetFlag(state.variable(), IS_STATIC); + bool is_static = GetFlag(state.variable(), IS_STATIC) != 0; // HACK: smartpointeraccessed static variables are not treated as statics if (GetFlag(n, "allocate:smartpointeraccess")) { is_static = false; } - bool is_member = GetFlag(n, "ismember"); - bool is_setter = GetFlag(n, "memberset") || GetFlag(n, "varset"); - bool is_getter = GetFlag(n, "memberget") || GetFlag(n, "varget"); + bool is_member = GetFlag(n, "ismember") != 0; + bool is_setter = GetFlag(n, "memberset") != 0 || GetFlag(n, "varset") != 0; + bool is_getter = GetFlag(n, "memberget") != 0 || GetFlag(n, "varget") != 0; if (is_setter) { ret = emitSetter(n, is_member, is_static); } else if (is_getter) { @@ -840,7 +840,7 @@ int JSEmitter::emitCtor(Node *n) { Wrapper *wrapper = NewWrapper(); - bool is_overloaded = GetFlag(n, "sym:overloaded"); + bool is_overloaded = GetFlag(n, "sym:overloaded") != 0; Template t_ctor(getTemplate("js_ctor")); @@ -1160,7 +1160,7 @@ int JSEmitter::emitFunction(Node *n, bool is_member, bool is_static) { Wrapper *wrapper = NewWrapper(); Template t_function(getTemplate("js_function")); - bool is_overloaded = GetFlag(n, "sym:overloaded"); + bool is_overloaded = GetFlag(n, "sym:overloaded") != 0; // prepare the function wrapper name String *iname = Getattr(n, "sym:name"); @@ -1288,7 +1288,7 @@ void JSEmitter::marshalOutput(Node *n, ParmList *params, Wrapper *wrapper, Strin cresult = defaultResultName; tm = Swig_typemap_lookup_out("out", n, cresult, wrapper, actioncode); - bool should_own = GetFlag(n, "feature:new"); + bool should_own = GetFlag(n, "feature:new") != 0; if (tm) { Replaceall(tm, "$objecttype", Swig_scopename_last(SwigType_str(SwigType_strip_qualifiers(type), 0))); @@ -1628,8 +1628,8 @@ int JSCEmitter::enterFunction(Node *n) { int JSCEmitter::exitFunction(Node *n) { Template t_function = getTemplate("jsc_function_declaration"); - bool is_member = GetFlag(n, "ismember") | GetFlag(n, "feature:extend"); - bool is_overloaded = GetFlag(n, "sym:overloaded"); + bool is_member = GetFlag(n, "ismember") != 0 || GetFlag(n, "feature:extend") != 0; + bool is_overloaded = GetFlag(n, "sym:overloaded") != 0; // handle overloaded functions if (is_overloaded) { @@ -2077,10 +2077,10 @@ int V8Emitter::exitVariable(Node *n) { } int V8Emitter::exitFunction(Node *n) { - bool is_member = GetFlag(n, "ismember") | GetFlag(n, "feature:extend"); + bool is_member = GetFlag(n, "ismember") != 0 || GetFlag(n, "feature:extend") != 0; // create a dispatcher for overloaded functions - bool is_overloaded = GetFlag(n, "sym:overloaded"); + bool is_overloaded = GetFlag(n, "sym:overloaded") != 0; if (is_overloaded) { if (!Getattr(n, "sym:nextSibling")) { //state.function(WRAPPER_NAME, Swig_name_wrapper(Getattr(n, "name"))); -- cgit v1.2.1 From f03bff152c44203ece2084aac03f14ac55a33b5c Mon Sep 17 00:00:00 2001 From: William S Fulton Date: Tue, 27 May 2014 07:22:46 +0100 Subject: Python 3 byte string output: use errors="surrogateescape" change note --- CHANGES.current | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/CHANGES.current b/CHANGES.current index e73a91c3f..399a05415 100644 --- a/CHANGES.current +++ b/CHANGES.current @@ -5,6 +5,15 @@ See the RELEASENOTES file for a summary of changes in each release. Version 3.0.1 (in progress) =========================== +2014-05-25: hfalcic + [Python] Python 3 byte string output: use errors="surrogateescape" + if available on the version of Python that's in use. This allows + obtaining the original byte string (and potentially trying a fallback + encoding) if the bytes can't be decoded as UTF-8. + + Previously, a UnicodeDecodeError would be raised with no way to treat + the data as bytes or try another codec. + 2014-05-18: vkalinin Bug #175 - Restore %extend to work for unnamed nested structures by using a C symbol comprising the outer structure name and unnamed variable instance name. -- cgit v1.2.1 From eeb113360633fdd69c4d81a3a508853f3cafe9e3 Mon Sep 17 00:00:00 2001 From: William S Fulton Date: Tue, 27 May 2014 07:27:33 +0100 Subject: Javascript html links and typo fixes --- Doc/Manual/Contents.html | 4 +++- Doc/Manual/Javascript.html | 9 +++++---- Doc/Manual/Python.html | 2 +- Doc/Manual/Sections.html | 2 +- 4 files changed, 10 insertions(+), 7 deletions(-) diff --git a/Doc/Manual/Contents.html b/Doc/Manual/Contents.html index 37a5aacff..4dd454352 100644 --- a/Doc/Manual/Contents.html +++ b/Doc/Manual/Contents.html @@ -1056,7 +1056,7 @@
  • Integration
  • @@ -1566,6 +1567,7 @@
  • Function annotation
  • Buffer interface
  • Abstract base classes +
  • Byte string output conversion
  • diff --git a/Doc/Manual/Javascript.html b/Doc/Manual/Javascript.html index bfe91aa09..fc2c45126 100644 --- a/Doc/Manual/Javascript.html +++ b/Doc/Manual/Javascript.html @@ -6,7 +6,7 @@ -

    26 SWIG and Javascript

    +

    26 SWIG and Javascript

      @@ -130,13 +130,14 @@ $ make check-javascript-examples ENGINE=jsc
    $ make check-javascript-test-suite ENGINE=jsc
    -

    26.2.1 Known Issues

    +

    26.2.3 Known Issues

    +

    At the moment, the Javascript generators pass all tests syntactically, i.e., the generated source code compiles. However, there are still remaining runtime issues.

    • Default optional arguments do not work for all targeted interpreters

    • -
    • Mutliple output arguments do not work for JSC

    • +
    • Multiple output arguments do not work for JSC

    • C89 incompatibily: the JSC generator might still generate C89 violating code

    • long long is not supported

    • %native is not supported

    • @@ -891,7 +892,7 @@ state.clazz(NAME, Getattr(n, "sym:name"));

      State information can be retrieved using state.clazz(NAME) or with Getattr on state.clazz() which actually returns a Hash instance.

      -

      26.5.5. Handling Exceptions in JavascriptCore

      +

      26.5.5 Handling Exceptions in JavascriptCore

      Applications with an embedded JavascriptCore should be able to present detailed exception messages that occur in the Javascript engine. Below is an example derived from code provided by Brian Barnes on how these exception details can be extracted.

      diff --git a/Doc/Manual/Python.html b/Doc/Manual/Python.html index 6dc0ff9ba..8b4f42a43 100644 --- a/Doc/Manual/Python.html +++ b/Doc/Manual/Python.html @@ -5929,7 +5929,7 @@ For details of abstract base class, please see PEP 3119.

      -

      35.12.4 Byte string output conversion

      +

      36.12.4 Byte string output conversion

      diff --git a/Doc/Manual/Sections.html b/Doc/Manual/Sections.html index 99d1dfe0d..b616371df 100644 --- a/Doc/Manual/Sections.html +++ b/Doc/Manual/Sections.html @@ -42,7 +42,7 @@ Last update : SWIG-3.0.1 (in progress)

    • Go support
    • Guile support
    • Java support
    • -
    • Javascript support
    • +
    • Javascript support
    • Common Lisp support
    • Lua support
    • Modula3 support
    • -- cgit v1.2.1 From 85413bc84dd1207baf7f1aca08ce0a3771115430 Mon Sep 17 00:00:00 2001 From: William S Fulton Date: Tue, 27 May 2014 18:37:05 +0100 Subject: Add 3.0.1 release date --- ANNOUNCE | 2 +- CHANGES.current | 2 +- Doc/Manual/Sections.html | 2 +- README | 2 +- 4 files changed, 4 insertions(+), 4 deletions(-) diff --git a/ANNOUNCE b/ANNOUNCE index 6229edc4a..7c521e77b 100644 --- a/ANNOUNCE +++ b/ANNOUNCE @@ -1,4 +1,4 @@ -*** ANNOUNCE: SWIG 3.0.1 (in progress) *** +*** ANNOUNCE: SWIG 3.0.1 (27 May 2014) *** http://www.swig.org diff --git a/CHANGES.current b/CHANGES.current index 399a05415..4b95adfa8 100644 --- a/CHANGES.current +++ b/CHANGES.current @@ -2,7 +2,7 @@ Below are the changes for the current release. See the CHANGES file for changes in older releases. See the RELEASENOTES file for a summary of changes in each release. -Version 3.0.1 (in progress) +Version 3.0.1 (27 May 2014) =========================== 2014-05-25: hfalcic diff --git a/Doc/Manual/Sections.html b/Doc/Manual/Sections.html index b616371df..0a61f074e 100644 --- a/Doc/Manual/Sections.html +++ b/Doc/Manual/Sections.html @@ -6,7 +6,7 @@

      SWIG-3.0 Documentation

      -Last update : SWIG-3.0.1 (in progress) +Last update : SWIG-3.0.1 (27 May 2014)

      Sections

      diff --git a/README b/README index 46497c148..e30441be7 100644 --- a/README +++ b/README @@ -1,6 +1,6 @@ SWIG (Simplified Wrapper and Interface Generator) -Version: 3.0.1 (in progress) +Version: 3.0.1 (27 May 2014) Tagline: SWIG is a compiler that integrates C and C++ with languages including Perl, Python, Tcl, Ruby, PHP, Java, C#, D, Go, Lua, -- cgit v1.2.1 From 18c9eca1827e009c66e5651145aff17745b76140 Mon Sep 17 00:00:00 2001 From: William S Fulton Date: Tue, 27 May 2014 19:58:36 +0100 Subject: Add Javascript to announcements --- ANNOUNCE | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/ANNOUNCE b/ANNOUNCE index 7c521e77b..2ec56266b 100644 --- a/ANNOUNCE +++ b/ANNOUNCE @@ -10,11 +10,11 @@ What is SWIG? SWIG is a software development tool that reads C/C++ header files and generates the wrapper code needed to make C and C++ code accessible from other programming languages including Perl, Python, Tcl, Ruby, -PHP, C#, Go, Java, Lua, Scheme (Guile, MzScheme, CHICKEN), D, Ocaml, -Pike, Modula-3, Octave, R, Common Lisp (CLISP, Allegro CL, CFFI, UFFI). -SWIG can also export its parse tree in the form of XML and Lisp -s-expressions. Major applications of SWIG include generation of -scripting language extension modules, rapid prototyping, testing, +PHP, C#, Go, Java, Javascript, Lua, Scheme (Guile, MzScheme, CHICKEN), +D, Ocaml, Pike, Modula-3, Octave, R, Common Lisp (CLISP, Allegro CL, +CFFI, UFFI). SWIG can also export its parse tree in the form of XML +and Lisp s-expressions. Major applications of SWIG include generation +of scripting language extension modules, rapid prototyping, testing, and user interface development for large C/C++ systems. Availability -- cgit v1.2.1 From 686d98672d97962e6ebeaf0e445ba069a8b999cd Mon Sep 17 00:00:00 2001 From: Oliver Buchtala Date: Wed, 28 May 2014 04:27:23 +0200 Subject: Javascript: fixed a missing link in documentation. --- Doc/Manual/Javascript.html | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Doc/Manual/Javascript.html b/Doc/Manual/Javascript.html index bfe91aa09..ef29ac63e 100644 --- a/Doc/Manual/Javascript.html +++ b/Doc/Manual/Javascript.html @@ -332,7 +332,7 @@ A simple example would have the following structure:

      The configuration file essentially conforms to node.js syntax. -It has some extras to configure node-webkit. See the Manifest specification for more details. +It has some extras to configure node-webkit. See the Manifest specification for more details.

      -- cgit v1.2.1 From 703862dc3a1ed01ad705e8884ef8963f8030cacb Mon Sep 17 00:00:00 2001 From: Olly Betts Date: Wed, 28 May 2014 23:04:06 +1200 Subject: Fix unused variable warning in Lua bindings --- Lib/lua/luarun.swg | 17 +++++++++-------- 1 file changed, 9 insertions(+), 8 deletions(-) diff --git a/Lib/lua/luarun.swg b/Lib/lua/luarun.swg index 6f2068e7a..0728a0528 100644 --- a/Lib/lua/luarun.swg +++ b/Lib/lua/luarun.swg @@ -1514,7 +1514,6 @@ SWIGINTERN void SWIG_Lua_class_register_static(lua_State *L, swig_lua_class *cls */ SWIGINTERN void SWIG_Lua_class_register_instance(lua_State *L,swig_lua_class *clss) { - int new_metatable_index; const int SWIGUNUSED begin = lua_gettop(L); int i; /* if name already there (class is already registered) then do nothing */ @@ -1541,14 +1540,16 @@ SWIGINTERN void SWIG_Lua_class_register_instance(lua_State *L,swig_lua_class *c * It would get us all special methods: __getitem, __add etc. * This would set .fn, .type, and other .xxx incorrectly, but we will overwrite it right away */ - new_metatable_index = lua_absindex(L,-1); - for(i=0;clss->bases[i];i++) { - int base_metatable; - SWIG_Lua_get_class_metatable(L,clss->bases[i]->fqname); - base_metatable = lua_absindex(L,-1); - SWIG_Lua_merge_tables_by_index(L,new_metatable_index, base_metatable); - lua_pop(L,1); + int new_metatable_index = lua_absindex(L,-1); + for(i=0;clss->bases[i];i++) + { + int base_metatable; + SWIG_Lua_get_class_metatable(L,clss->bases[i]->fqname); + base_metatable = lua_absindex(L,-1); + SWIG_Lua_merge_tables_by_index(L,new_metatable_index, base_metatable); + lua_pop(L,1); + } } /* And now we will overwrite all incorrectly set data */ #endif -- cgit v1.2.1 From 68347cb723afde8b7bbbbb4d0d8be0f5abae359d Mon Sep 17 00:00:00 2001 From: William S Fulton Date: Wed, 28 May 2014 18:51:46 +0100 Subject: Bump version to 3.0.2 --- ANNOUNCE | 8 ++--- CHANGES | 84 ++++++++++++++++++++++++++++++++++++++++++++++++ CHANGES.current | 82 +--------------------------------------------- Doc/Manual/Sections.html | 2 +- README | 2 +- configure.ac | 2 +- 6 files changed, 92 insertions(+), 88 deletions(-) diff --git a/ANNOUNCE b/ANNOUNCE index 2ec56266b..fc1160007 100644 --- a/ANNOUNCE +++ b/ANNOUNCE @@ -1,8 +1,8 @@ -*** ANNOUNCE: SWIG 3.0.1 (27 May 2014) *** +*** ANNOUNCE: SWIG 3.0.2 (in progress) *** http://www.swig.org -We're pleased to announce SWIG-3.0.1, the latest SWIG release. +We're pleased to announce SWIG-3.0.2, the latest SWIG release. What is SWIG? ============= @@ -21,11 +21,11 @@ Availability ============ The release is available for download on Sourceforge at - http://prdownloads.sourceforge.net/swig/swig-3.0.1.tar.gz + http://prdownloads.sourceforge.net/swig/swig-3.0.2.tar.gz A Windows version is also available at - http://prdownloads.sourceforge.net/swig/swigwin-3.0.1.zip + http://prdownloads.sourceforge.net/swig/swigwin-3.0.2.zip Please report problems with this release to the swig-devel mailing list, details at http://www.swig.org/mail.html. diff --git a/CHANGES b/CHANGES index 821d76b2c..1cfedc31e 100644 --- a/CHANGES +++ b/CHANGES @@ -3,6 +3,90 @@ SWIG (Simplified Wrapper and Interface Generator) See the CHANGES.current file for changes in the current version. See the RELEASENOTES file for a summary of changes in each release. +Version 3.0.1 (27 May 2014) +=========================== + +2014-05-25: hfalcic + [Python] Python 3 byte string output: use errors="surrogateescape" + if available on the version of Python that's in use. This allows + obtaining the original byte string (and potentially trying a fallback + encoding) if the bytes can't be decoded as UTF-8. + + Previously, a UnicodeDecodeError would be raised with no way to treat + the data as bytes or try another codec. + +2014-05-18: vkalinin + Bug #175 - Restore %extend to work for unnamed nested structures by using a C + symbol comprising the outer structure name and unnamed variable instance name. + +2014-05-15: kwwette + Add #166 - 'make check' now works out of source. This required te examples to build + out of source. The main languages have been tested - C#, Go, Guile, Java, Javascript, + Lua, Octave, Perl, PHP, Python, Ruby and Tcl. + +2014-05-01: Oliver Buchtala + Javascript support added, see Javascript chapter in the documentation. + +2014-05-01: olly + [PHP] The generated __isset() method now returns true for read-only properties. + +2014-04-24: kwwette + [Go] Fix go ./configure parsing of gccgo --version, and + goruntime.swg typo in __GNUC_PATCHLEVEL__ (SF Bug #1298) + +2014-04-24: kwwette + Fix {python|perl5|ruby|tcl}/java examples + + In Lib/gcj/cni.i, for compatibility with newer gcj versions: + + - remove JvAllocObject() which gcj no longer defines, from gcj Changelog: + 2004-04-16 Bryce McKinlay + * gcj/cni.h (JvAllocObject): Remove these obsolete, + undocumented CNI calls. + + - change JvCreateJavaVM() argument from void* to JvVMInitArgs*, from gcj Changelog: + 2005-02-23 Thomas Fitzsimmons + PR libgcj/16923 + ... + (JvCreateJavaVM): Declare vm_args as JvVMInitArgs* rather than void*. + + *** POTENTIAL INCOMPATIBILITY *** + +2014-04-08: wsfulton + SF Bug #1366 - Remove duplicate declarations of strtoimax and strtoumax in inttypes.i + +2014-04-08: wsfulton + [Java C#] Enums which have been ignored via %ignore and are subsequently + used are handled slightly differently. Type wrapper classes are now generated + which are effectively a wrapper of an empty enum. Previously in Java uncompilable + code was generated and in C# an int was used. + +2014-04-04: wsfulton + Fix regression in 3.0.0 where legal code following an operator<< definition might + give a syntax error. SF Bug #1365. + +2014-04-03: olly + [PHP] Fix wrapping director constructors with default parameters + with a ZTS-enabled build of PHP. + +2014-04-02: olly + [PHP] Pass the ZTS context we already have to avoid needing to + call TSRMLS_FETCH, which is relatively expensive. + +2014-04-02: olly + [PHP] Pass ZTS context through to t_output_helper() so it works + with a ZTS-enabled build of PHP. Reported by Pierre Labastie in + github PR#155. + +2014-03-28: wsfulton + [Java C# D Go] Fixes for C enums used in an API and the definition of the enum + has not been parsed. For D, this fixes a segfault in SWIG. The other languages + now produce code that compiles, although the definition of the enum is needed + in order to use the enum properly from the target language. + +2014-03-23: v-for-vandal + [Lua] Fix for usage of snprintf in Lua runtime which Visual Studio does not have. + Version 3.0.0 (16 Mar 2014) =========================== diff --git a/CHANGES.current b/CHANGES.current index 4b95adfa8..8d715e730 100644 --- a/CHANGES.current +++ b/CHANGES.current @@ -2,86 +2,6 @@ Below are the changes for the current release. See the CHANGES file for changes in older releases. See the RELEASENOTES file for a summary of changes in each release. -Version 3.0.1 (27 May 2014) +Version 3.0.2 (in progress) =========================== -2014-05-25: hfalcic - [Python] Python 3 byte string output: use errors="surrogateescape" - if available on the version of Python that's in use. This allows - obtaining the original byte string (and potentially trying a fallback - encoding) if the bytes can't be decoded as UTF-8. - - Previously, a UnicodeDecodeError would be raised with no way to treat - the data as bytes or try another codec. - -2014-05-18: vkalinin - Bug #175 - Restore %extend to work for unnamed nested structures by using a C - symbol comprising the outer structure name and unnamed variable instance name. - -2014-05-15: kwwette - Add #166 - 'make check' now works out of source. This required te examples to build - out of source. The main languages have been tested - C#, Go, Guile, Java, Javascript, - Lua, Octave, Perl, PHP, Python, Ruby and Tcl. - -2014-05-01: Oliver Buchtala - Javascript support added, see Javascript chapter in the documentation. - -2014-05-01: olly - [PHP] The generated __isset() method now returns true for read-only properties. - -2014-04-24: kwwette - [Go] Fix go ./configure parsing of gccgo --version, and - goruntime.swg typo in __GNUC_PATCHLEVEL__ (SF Bug #1298) - -2014-04-24: kwwette - Fix {python|perl5|ruby|tcl}/java examples - - In Lib/gcj/cni.i, for compatibility with newer gcj versions: - - - remove JvAllocObject() which gcj no longer defines, from gcj Changelog: - 2004-04-16 Bryce McKinlay - * gcj/cni.h (JvAllocObject): Remove these obsolete, - undocumented CNI calls. - - - change JvCreateJavaVM() argument from void* to JvVMInitArgs*, from gcj Changelog: - 2005-02-23 Thomas Fitzsimmons - PR libgcj/16923 - ... - (JvCreateJavaVM): Declare vm_args as JvVMInitArgs* rather than void*. - - *** POTENTIAL INCOMPATIBILITY *** - -2014-04-08: wsfulton - SF Bug #1366 - Remove duplicate declarations of strtoimax and strtoumax in inttypes.i - -2014-04-08: wsfulton - [Java C#] Enums which have been ignored via %ignore and are subsequently - used are handled slightly differently. Type wrapper classes are now generated - which are effectively a wrapper of an empty enum. Previously in Java uncompilable - code was generated and in C# an int was used. - -2014-04-04: wsfulton - Fix regression in 3.0.0 where legal code following an operator<< definition might - give a syntax error. SF Bug #1365. - -2014-04-03: olly - [PHP] Fix wrapping director constructors with default parameters - with a ZTS-enabled build of PHP. - -2014-04-02: olly - [PHP] Pass the ZTS context we already have to avoid needing to - call TSRMLS_FETCH, which is relatively expensive. - -2014-04-02: olly - [PHP] Pass ZTS context through to t_output_helper() so it works - with a ZTS-enabled build of PHP. Reported by Pierre Labastie in - github PR#155. - -2014-03-28: wsfulton - [Java C# D Go] Fixes for C enums used in an API and the definition of the enum - has not been parsed. For D, this fixes a segfault in SWIG. The other languages - now produce code that compiles, although the definition of the enum is needed - in order to use the enum properly from the target language. - -2014-03-23: v-for-vandal - [Lua] Fix for usage of snprintf in Lua runtime which Visual Studio does not have. diff --git a/Doc/Manual/Sections.html b/Doc/Manual/Sections.html index 0a61f074e..33d76c239 100644 --- a/Doc/Manual/Sections.html +++ b/Doc/Manual/Sections.html @@ -6,7 +6,7 @@

      SWIG-3.0 Documentation

      -Last update : SWIG-3.0.1 (27 May 2014) +Last update : SWIG-3.0.2 (in progress)

      Sections

      diff --git a/README b/README index e30441be7..e4010bd80 100644 --- a/README +++ b/README @@ -1,6 +1,6 @@ SWIG (Simplified Wrapper and Interface Generator) -Version: 3.0.1 (27 May 2014) +Version: 3.0.2 (27 May 2014) Tagline: SWIG is a compiler that integrates C and C++ with languages including Perl, Python, Tcl, Ruby, PHP, Java, C#, D, Go, Lua, diff --git a/configure.ac b/configure.ac index 2ff5dc8db..8af45b69f 100644 --- a/configure.ac +++ b/configure.ac @@ -2,7 +2,7 @@ dnl Process this file with autoconf to produce a configure script. dnl The macros which aren't shipped with the autotools are stored in the dnl Tools/config directory in .m4 files. -AC_INIT([swig],[3.0.1],[http://www.swig.org]) +AC_INIT([swig],[3.0.2],[http://www.swig.org]) dnl NB: When this requirement is increased to 2.60 or later, AC_PROG_SED dnl definition below can be removed -- cgit v1.2.1 From 2b4c49d017f526f6622cd54547ab9fab31941176 Mon Sep 17 00:00:00 2001 From: Artem Serebriyskiy Date: Fri, 16 May 2014 13:00:14 +0400 Subject: Add default __eq implementation * Renamed SWIG_Lua_equal to SWIG_Lua_class_equal * If class has no __eq implemented, then default __eq is provided. Default __eq compares actual pointers stored inside Lua userdata --- Examples/test-suite/lua/cpp_basic_runme.lua | 11 +++++++ Lib/lua/luarun.swg | 46 ++++++++++++++++++----------- Lib/lua/luaruntime.swg | 2 +- 3 files changed, 41 insertions(+), 18 deletions(-) diff --git a/Examples/test-suite/lua/cpp_basic_runme.lua b/Examples/test-suite/lua/cpp_basic_runme.lua index c7e0325c5..5a0e1c699 100644 --- a/Examples/test-suite/lua/cpp_basic_runme.lua +++ b/Examples/test-suite/lua/cpp_basic_runme.lua @@ -86,3 +86,14 @@ f4_name = tostring(f4) assert( f2_name == "Foo" ) assert( f3_name == "Foo" ) assert( f4_name == "FooSubSub" ) + +-- Test __eq implementation supplied by default + +-- eq_f1 and eq_f2 must be different userdata with same Foo* pointer. If eq_f1 and eq_f2 are the same userdata (e.g.) +-- > eq_f1 = smth +-- > eq_f2 = eq_f1 +-- then default Lua equality comparison kicks in and considers them equal. Access to global_fptr is actually a +-- function call (internally) and it returns new userdata each time. +eq_f1 = cb.Bar.global_fptr +eq_f2 = cb.Bar.global_fptr +assert( eq_f1 == eq_f2 ) diff --git a/Lib/lua/luarun.swg b/Lib/lua/luarun.swg index 0728a0528..756c38d01 100644 --- a/Lib/lua/luarun.swg +++ b/Lib/lua/luarun.swg @@ -1037,6 +1037,23 @@ SWIGINTERN int SWIG_Lua_class_disown(lua_State *L) return 0; } +/* lua callable function to compare userdata's value +the issue is that two userdata may point to the same thing +but to lua, they are different objects */ +SWIGRUNTIME int SWIG_Lua_class_equal(lua_State *L) +{ + int result; + swig_lua_userdata *usr1,*usr2; + if (!lua_isuserdata(L,1) || !lua_isuserdata(L,2)) /* just in case */ + return 0; /* nil reply */ + usr1=(swig_lua_userdata*)lua_touserdata(L,1); /* get data */ + usr2=(swig_lua_userdata*)lua_touserdata(L,2); /* get data */ + /*result=(usr1->ptr==usr2->ptr && usr1->type==usr2->type); only works if type is the same*/ + result=(usr1->ptr==usr2->ptr); + lua_pushboolean(L,result); + return 1; +} + /* populate table at the top of the stack with metamethods that ought to be inherited */ SWIGINTERN void SWIG_Lua_populate_inheritable_metamethods(lua_State *L) { @@ -1471,6 +1488,18 @@ SWIGINTERN void SWIG_Lua_add_class_user_metamethods(lua_State *L, swig_lua_class lua_pop(L,1); /* remove copy of the key */ } + /* Special handling for __eq method */ + lua_pushstring(L, "__eq"); + lua_pushvalue(L,-1); + lua_rawget(L,metatable_index); + const int eq_undefined = lua_isnil(L,-1); + lua_pop(L,1); + if( eq_undefined ) { + lua_pushcfunction(L, SWIG_Lua_class_equal); + lua_rawset(L, metatable_index); + } else { + lua_pop(L,1); /* remove copy of the key */ + } /* Warning: __index and __newindex are SWIG-defined. For user-defined operator[] * a __getitem/__setitem method should be defined */ @@ -1788,23 +1817,6 @@ SWIGRUNTIME int SWIG_Lua_type(lua_State *L) return 1; } -/* lua callable function to compare userdata's value -the issue is that two userdata may point to the same thing -but to lua, they are different objects */ -SWIGRUNTIME int SWIG_Lua_equal(lua_State *L) -{ - int result; - swig_lua_userdata *usr1,*usr2; - if (!lua_isuserdata(L,1) || !lua_isuserdata(L,2)) /* just in case */ - return 0; /* nil reply */ - usr1=(swig_lua_userdata*)lua_touserdata(L,1); /* get data */ - usr2=(swig_lua_userdata*)lua_touserdata(L,2); /* get data */ - /*result=(usr1->ptr==usr2->ptr && usr1->type==usr2->type); only works if type is the same*/ - result=(usr1->ptr==usr2->ptr); - lua_pushboolean(L,result); - return 1; -} - /* ----------------------------------------------------------------------------- * global variable support code: class/struct typemap functions * ----------------------------------------------------------------------------- */ diff --git a/Lib/lua/luaruntime.swg b/Lib/lua/luaruntime.swg index 89908044b..8df46e8cb 100644 --- a/Lib/lua/luaruntime.swg +++ b/Lib/lua/luaruntime.swg @@ -40,7 +40,7 @@ SWIGEXPORT int SWIG_init(lua_State* L) /* default Lua action */ #if ((SWIG_LUA_TARGET != SWIG_LUA_FLAVOR_ELUA) && (SWIG_LUA_TARGET != SWIG_LUA_FLAVOR_ELUAC)) || defined(SWIG_LUA_ELUA_EMULATE) /* add a global fn */ SWIG_Lua_add_function(L,"swig_type",SWIG_Lua_type); - SWIG_Lua_add_function(L,"swig_equals",SWIG_Lua_equal); + SWIG_Lua_add_function(L,"swig_equals",SWIG_Lua_class_equal); #endif #if (SWIG_LUA_TARGET != SWIG_LUA_FLAVOR_ELUAC) -- cgit v1.2.1 From 4457d96e54b7dea20b4c7b43e5182fa564d5c0c9 Mon Sep 17 00:00:00 2001 From: Artem Serebriyskiy Date: Fri, 23 May 2014 15:13:41 +0400 Subject: Moving variable declaration to the beginning of the block --- Lib/lua/luarun.swg | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/Lib/lua/luarun.swg b/Lib/lua/luarun.swg index 756c38d01..8803c66f6 100644 --- a/Lib/lua/luarun.swg +++ b/Lib/lua/luarun.swg @@ -1456,6 +1456,7 @@ SWIGINTERN void SWIG_Lua_add_class_user_metamethods(lua_State *L, swig_lua_class int metatable_index; int metamethods_info_index; int tostring_undefined; + int eq_undefined = 0; SWIG_Lua_get_class_metatable(L, clss->fqname); metatable_index = lua_gettop(L); @@ -1492,7 +1493,7 @@ SWIGINTERN void SWIG_Lua_add_class_user_metamethods(lua_State *L, swig_lua_class lua_pushstring(L, "__eq"); lua_pushvalue(L,-1); lua_rawget(L,metatable_index); - const int eq_undefined = lua_isnil(L,-1); + eq_undefined = lua_isnil(L,-1); lua_pop(L,1); if( eq_undefined ) { lua_pushcfunction(L, SWIG_Lua_class_equal); -- cgit v1.2.1 From 46d7645c9ae1ecafd5447cb1f287c5f8d1dc5b4f Mon Sep 17 00:00:00 2001 From: Artem Serebriyskiy Date: Mon, 26 May 2014 23:27:29 +0400 Subject: More tests for equality operator overloading --- Examples/test-suite/common.mk | 1 + Examples/test-suite/equality.i | 67 ++++++++++++++++++++++++++++++ Examples/test-suite/lua/equality_runme.lua | 47 +++++++++++++++++++++ 3 files changed, 115 insertions(+) create mode 100644 Examples/test-suite/equality.i create mode 100644 Examples/test-suite/lua/equality_runme.lua diff --git a/Examples/test-suite/common.mk b/Examples/test-suite/common.mk index bc1ca5cb8..485453b5a 100644 --- a/Examples/test-suite/common.mk +++ b/Examples/test-suite/common.mk @@ -210,6 +210,7 @@ CPP_TEST_CASES += \ enum_template \ enum_thorough \ enum_var \ + equality \ evil_diamond \ evil_diamond_ns \ evil_diamond_prop \ diff --git a/Examples/test-suite/equality.i b/Examples/test-suite/equality.i new file mode 100644 index 000000000..a1b70c299 --- /dev/null +++ b/Examples/test-suite/equality.i @@ -0,0 +1,67 @@ +/* File : equality.i */ +/* + Specific test for operator== overload. Partially overlaps with + operator_overload.i +*/ + +%module equality + +%inline %{ + +/* Point has no equality operator */ +typedef struct Point +{ + double x; + double y; +} Point; + +static const Point s_zeroPoint = { 0.0, 0.0 }; +/* stack version */ +Point MakePoint(double x, double y) + { Point new_point = {x, y}; return new_point; } + +const Point* GetZeroPointPtr() { return &s_zeroPoint; } +Point GetZeroPointCopy() { return s_zeroPoint; } + +/* EqualOpDefined has correct equality operator */ +class EqualOpDefined { +public: + EqualOpDefined(): + x(5) {} + EqualOpDefined(int val): + x(val) {} + + int x; +}; + +/* EqualOpWrong has logically incorrect equality operator */ +class EqualOpWrong { +public: + inline static const EqualOpWrong* GetStaticObject(); +}; + +static const EqualOpWrong s_wrongEqOp; + +const EqualOpWrong* EqualOpWrong::GetStaticObject() + { return &s_wrongEqOp; } + + +inline bool operator==( const EqualOpDefined& first, const EqualOpDefined& second ) + { return first.x == second.x; } + +inline bool operator==( const EqualOpWrong& first, const EqualOpWrong& second ) + { return false; } + +%} + +/* + in order to wrapper this correctly + we need to extend the class + to make the friends & non members part of the class +*/ +%extend EqualOpDefined { + bool operator==(const EqualOpDefined& b){return (*$self) == b;} +} +%extend EqualOpWrong { + bool operator==(const EqualOpWrong& b){return (*$self) == b;} +} diff --git a/Examples/test-suite/lua/equality_runme.lua b/Examples/test-suite/lua/equality_runme.lua new file mode 100644 index 000000000..cadbede0a --- /dev/null +++ b/Examples/test-suite/lua/equality_runme.lua @@ -0,0 +1,47 @@ +require("import") -- the import fn +import("equality") -- import code +eq=equality -- renaming import + +-- catch "undefined" global variables +local env = _ENV -- Lua 5.2 +if not env then env = getfenv () end -- Lua 5.1 +setmetatable(env, {__index=function (t,i) error("undefined global variable `"..i.."'",2) end}) + +-- === No equality operator === + +-- logically same data without equality operator are not equal +p1 = eq.MakePoint(10,9); +p2 = eq.MakePoint(10,9); + +assert( p1 ~= p2 ); + +-- different wrappers for same Point* are equal +p3 = eq.GetZeroPointPtr() +p4 = eq.GetZeroPointPtr() + +assert( p3 == p4 ) + + +-- === Logically correct equality operator === + +ed1 = eq.EqualOpDefined(10) +ed2 = eq.EqualOpDefined(10) +ed3 = eq.EqualOpDefined(15) + +assert( ed1 == ed2 ) +assert( ed1 ~= ed3 ) + + +-- === Logically incorrect equality operator === + +ew1 = eq.EqualOpWrong() +ew2 = eq.EqualOpWrong() + +assert( ew1 ~= ew2 ); + +ew3 = eq.EqualOpWrong.GetStaticObject() +ew4 = eq.EqualOpWrong.GetStaticObject() + +-- Even though these are pointers to same object, operator== overload should +-- state that they are not equal +assert( ew3 ~= ew4 ) -- cgit v1.2.1 From 665c4f581be7aef1e37c40dee3fde00b2d1cdcfd Mon Sep 17 00:00:00 2001 From: Vladimir Kalinin Date: Wed, 28 May 2014 22:15:50 +0400 Subject: %extend symbols for nested structs get into a wrong C symbol table --- Examples/test-suite/nested_extend_c.i | 7 +++++++ Source/Modules/nested.cxx | 14 ++++++++------ 2 files changed, 15 insertions(+), 6 deletions(-) diff --git a/Examples/test-suite/nested_extend_c.i b/Examples/test-suite/nested_extend_c.i index 0e1495f86..fb3c053c4 100644 --- a/Examples/test-suite/nested_extend_c.i +++ b/Examples/test-suite/nested_extend_c.i @@ -10,6 +10,7 @@ char hi_extend() { return $self->c; } + static const long swig_size = sizeof(hiA); } %extend lowA { lowA() { @@ -21,6 +22,7 @@ int low_extend() { return $self->num; } + static const long swig_size = sizeof(lowA); } %extend hiB { @@ -32,6 +34,7 @@ char hi_extend() { return $self->c; } + static const long swig_size = sizeof(hiB); } %extend lowB { lowB() { @@ -43,6 +46,7 @@ int low_extend() { return $self->num; } + static const long swig_size = sizeof(lowB); } %extend FOO_bar { @@ -50,6 +54,9 @@ $self->d = 1; } }; +%extend NestedA { + static const long swig_size = sizeof(NestedA); +} #endif diff --git a/Source/Modules/nested.cxx b/Source/Modules/nested.cxx index 9ec52ead1..c4ab6a8ea 100644 --- a/Source/Modules/nested.cxx +++ b/Source/Modules/nested.cxx @@ -362,7 +362,15 @@ void Swig_nested_name_unnamed_c_structs(Node *n) { Delete(bases); } Setattr(classhash, name, c); + + // Merge the extension into the symbol table + if (Node *am = Getattr(Swig_extend_hash(), name)) { + Swig_extend_merge(c, am); + Swig_extend_append_previous(c, am); + Delattr(Swig_extend_hash(), name); + } Swig_symbol_popscope(); + // process declarations following this type (assign correct new type) SwigType *ty = Copy(name); Node *decl = nextSibling(c); @@ -376,12 +384,6 @@ void Swig_nested_name_unnamed_c_structs(Node *n) { decl = nextSibling(decl); } Delete(ty); - if (Node *am = Getattr(Swig_extend_hash(), name)) { - // Merge the extension into the symbol table - Swig_extend_merge(c, am); - Swig_extend_append_previous(c, am); - Delattr(Swig_extend_hash(), name); - } Swig_symbol_setscope(Swig_symbol_global_scope()); add_symbols_c(c); -- cgit v1.2.1 From 78719759d5572b6c80c6a7061e71f78bee49a5ea Mon Sep 17 00:00:00 2001 From: William S Fulton Date: Wed, 28 May 2014 23:44:55 +0100 Subject: Test-suite makefile fixes for Windows Remove $(realpath ) which is no good for Windows executables running under Cygwin's make --- Examples/Makefile.in | 6 +++--- Examples/test-suite/java/preproc_line_file_runme.java | 16 ++++++++++++---- 2 files changed, 15 insertions(+), 7 deletions(-) diff --git a/Examples/Makefile.in b/Examples/Makefile.in index caf848596..1f3b07205 100644 --- a/Examples/Makefile.in +++ b/Examples/Makefile.in @@ -576,7 +576,7 @@ JAVAC = @JAVAC@ -d . # ---------------------------------------------------------------- java: $(SRCDIR_SRCS) - $(SWIG) -java $(SWIGOPT) -o $(ISRCS) $(realpath $(INTERFACEPATH)) + $(SWIG) -java $(SWIGOPT) -o $(ISRCS) $(INTERFACEPATH) $(CC) -c $(CCSHARED) $(CPPFLAGS) $(CFLAGS) $(JAVACFLAGS) $(SRCDIR_SRCS) $(ISRCS) $(INCLUDES) $(JAVA_INCLUDE) $(JAVALDSHARED) $(CFLAGS) $(LDFLAGS) $(OBJS) $(IOBJS) $(JAVA_DLNK) $(LIBS) -o $(JAVA_LIBPREFIX)$(TARGET)$(JAVASO) @@ -585,7 +585,7 @@ java: $(SRCDIR_SRCS) # ---------------------------------------------------------------- java_cpp: $(SRCDIR_SRCS) - $(SWIG) -java -c++ $(SWIGOPT) -o $(ICXXSRCS) $(realpath $(INTERFACEPATH)) + $(SWIG) -java -c++ $(SWIGOPT) -o $(ICXXSRCS) $(INTERFACEPATH) $(CXX) -c $(CCSHARED) $(CPPFLAGS) $(CXXFLAGS) $(JAVACFLAGS) $(SRCDIR_SRCS) $(SRCDIR_CXXSRCS) $(ICXXSRCS) $(INCLUDES) $(JAVA_INCLUDE) $(JAVACXXSHARED) $(CXXFLAGS) $(LDFLAGS) $(OBJS) $(IOBJS) $(JAVA_DLNK) $(LIBS) $(CPP_DLLIBS) -o $(JAVA_LIBPREFIX)$(TARGET)$(JAVASO) @@ -1373,7 +1373,7 @@ csharp_cpp: $(SRCDIR_SRCS) # ---------------------------------------------------------------- ifneq (,$(SRCDIR)) -SRCDIR_CSHARPSRCS = $(wildcard $(addprefix $(SRCDIR),$(CSHARPSRCS))) +SRCDIR_CSHARPSRCS = $(addprefix $(SRCDIR),$(CSHARPSRCS)) else SRCDIR_CSHARPSRCS = endif diff --git a/Examples/test-suite/java/preproc_line_file_runme.java b/Examples/test-suite/java/preproc_line_file_runme.java index 123753fd9..7726b613b 100644 --- a/Examples/test-suite/java/preproc_line_file_runme.java +++ b/Examples/test-suite/java/preproc_line_file_runme.java @@ -13,13 +13,21 @@ public class preproc_line_file_runme { private static void test_file(String file, String suffix) throws Throwable { - String FILENAME_WINDOWS = "Examples\\test-suite\\preproc_line_file.i"; - String FILENAME_UNIX = "Examples/test-suite/preproc_line_file.i"; +// For swig-3.0.1 and earlier +// String FILENAME_WINDOWS = "Examples\\test-suite\\preproc_line_file.i"; +// String FILENAME_UNIX = "Examples/test-suite/preproc_line_file.i"; + + String FILENAME_WINDOWS2 = "Examples\\test-suite\\java\\..\\preproc_line_file.i"; + String FILENAME_UNIX2 = "Examples/test-suite/java/../preproc_line_file.i"; + + String FILENAME_WINDOWS3 = "..\\.\\..\\preproc_line_file.i"; + String FILENAME_UNIX3 = ".././../preproc_line_file.i"; // We don't test for exact equality here because the file names are relative to the build directory, which can be different from the source directory, // under Unix. But they do need to end with the same path components. - if (!file.endsWith(FILENAME_UNIX + suffix) && !file.endsWith(FILENAME_WINDOWS + suffix)) - throw new RuntimeException("file \"" + file + "\" doesn't end with " + FILENAME_UNIX + suffix); + if (!file.endsWith(FILENAME_UNIX2 + suffix) && !file.endsWith(FILENAME_WINDOWS2 + suffix) && + !file.endsWith(FILENAME_UNIX3 + suffix) && !file.endsWith(FILENAME_WINDOWS3 + suffix)) + throw new RuntimeException("file \"" + file + "\" doesn't end with " + FILENAME_UNIX2 + suffix + " or " + FILENAME_UNIX3 + suffix); } public static void main(String argv[]) throws Throwable -- cgit v1.2.1 From cc1ff55be458fba978cfb7f31f6966630f6b380e Mon Sep 17 00:00:00 2001 From: Karl Wette Date: Wed, 28 May 2014 20:46:44 +0200 Subject: CCache: always generate docs in source directory --- .gitignore | 1 + CCache/Makefile.in | 18 +++++++++--------- 2 files changed, 10 insertions(+), 9 deletions(-) diff --git a/.gitignore b/.gitignore index c7961efd7..e6c73c463 100644 --- a/.gitignore +++ b/.gitignore @@ -85,6 +85,7 @@ swig.spec .dirstamp CCache/ccache-swig CCache/ccache-swig.1 +CCache/web/ccache-man.html Lib/swigwarn.swg Source/CParse/parser.c Source/CParse/parser.h diff --git a/CCache/Makefile.in b/CCache/Makefile.in index 6703e2ac0..6cded08d4 100644 --- a/CCache/Makefile.in +++ b/CCache/Makefile.in @@ -32,27 +32,27 @@ Makefile: $(srcdir)/Makefile.in ./config.status $(SHELL) ./config.status # Note that HTML documentation is actually generated and used from the main SWIG documentation Makefile -docs: $(PACKAGE_NAME).1 web/ccache-man.html +docs: $(srcdir)/$(PACKAGE_NAME).1 $(srcdir)/web/ccache-man.html $(PACKAGE_NAME)$(EXEEXT): $(OBJS) $(HEADERS) $(CC) $(CFLAGS) $(LDFLAGS) -o $@ $(OBJS) $(LIBS) -$(PACKAGE_NAME).1: ccache.yo - -yodl2man -o $(PACKAGE_NAME).1 $(srcdir)/ccache.yo +$(srcdir)/$(PACKAGE_NAME).1: $(srcdir)/ccache.yo + -yodl2man -o $(srcdir)/$(PACKAGE_NAME).1 $(srcdir)/ccache.yo -web/ccache-man.html: ccache.yo - yodl2html -o web/ccache-man.html ccache.yo +$(srcdir)/web/ccache-man.html: $(srcdir)/ccache.yo + yodl2html -o $(srcdir)/web/ccache-man.html $(srcdir)/ccache.yo -install: $(PACKAGE_NAME)$(EXEEXT) $(PACKAGE_NAME).1 +install: $(PACKAGE_NAME)$(EXEEXT) $(srcdir)/$(PACKAGE_NAME).1 @echo "Installing $(PACKAGE_NAME)" @echo "Installing $(DESTDIR)${bindir}/`echo $(PACKAGE_NAME) | sed '$(transform)'`$(EXEEXT)" ${INSTALLCMD} -d $(DESTDIR)${bindir} ${INSTALLCMD} -m 755 $(PACKAGE_NAME)$(EXEEXT) $(DESTDIR)${bindir}/`echo $(PACKAGE_NAME) | sed '$(transform)'`$(EXEEXT) @echo "Installing $(DESTDIR)${mandir}/man1/`echo $(PACKAGE_NAME) | sed '$(transform)'`.1" ${INSTALLCMD} -d $(DESTDIR)${mandir}/man1 - ${INSTALLCMD} -m 644 $(PACKAGE_NAME).1 $(DESTDIR)${mandir}/man1/`echo $(PACKAGE_NAME) | sed '$(transform)'`.1 + ${INSTALLCMD} -m 644 $(srcdir)/$(PACKAGE_NAME).1 $(DESTDIR)${mandir}/man1/`echo $(PACKAGE_NAME) | sed '$(transform)'`.1 -uninstall: $(PACKAGE_NAME)$(EXEEXT) $(PACKAGE_NAME).1 +uninstall: $(PACKAGE_NAME)$(EXEEXT) $(srcdir)/$(PACKAGE_NAME).1 rm -f $(DESTDIR)${bindir}/`echo $(PACKAGE_NAME) | sed '$(transform)'`$(EXEEXT) rm -f $(DESTDIR)${mandir}/man1/`echo $(PACKAGE_NAME) | sed '$(transform)'`.1 @@ -69,7 +69,7 @@ distclean: clean /bin/rm -rf autom4te.cache maintainer-clean: distclean - /bin/rm -f $(PACKAGE_NAME).1 web/ccache-man.html + /bin/rm -f $(srcdir)/$(PACKAGE_NAME).1 $(srcdir)/web/ccache-man.html # FIXME: To fix this, test.sh needs to be able to take ccache from the -- cgit v1.2.1 From 46ce4d3ba9a1ae50706e828ab17c8bc6c2e50fe0 Mon Sep 17 00:00:00 2001 From: Karl Wette Date: Wed, 28 May 2014 21:19:06 +0200 Subject: Distclean Tools/javascript --- Makefile.in | 6 +++++- Tools/javascript/Makefile.in | 3 +++ 2 files changed, 8 insertions(+), 1 deletion(-) diff --git a/Makefile.in b/Makefile.in index a040d41a1..2b9cf3b32 100644 --- a/Makefile.in +++ b/Makefile.in @@ -403,7 +403,7 @@ clean-ccache: DISTCLEAN-DEAD = config.status config.log config.cache swig.spec Makefile mkmf.log libtool preinst-swig -distclean-helper: distclean-test-suite distclean-examples distclean-dead +distclean-helper: distclean-test-suite distclean-examples distclean-tools distclean-dead distclean: distclean-source distclean-ccache distclean-helper @@ -429,6 +429,10 @@ distclean-examples: distclean-ccache: @test -z "$(ENABLE_CCACHE)" || (cd $(CCACHE) && $(MAKE) $(FLAGS) distclean) +distclean-tools: + @echo distcleaning Tools + @cd Tools/javascript && $(MAKE) $(FLAGS) distclean + distclean-dead: rm -f $(DISTCLEAN-DEAD) rm -rf autom4te.cache diff --git a/Tools/javascript/Makefile.in b/Tools/javascript/Makefile.in index 960c661b2..f65be2826 100644 --- a/Tools/javascript/Makefile.in +++ b/Tools/javascript/Makefile.in @@ -64,3 +64,6 @@ javascript: $(JS_INTERPRETER_OBJS) clean: rm -f *.o rm -f javascript + +distclean: clean + rm -f Makefile -- cgit v1.2.1 From 32212d5cc08d312f15e5f6d102610752b86e3f3c Mon Sep 17 00:00:00 2001 From: Karl Wette Date: Wed, 28 May 2014 22:40:36 +0200 Subject: Fully clean Go test-suite --- Examples/test-suite/go/Makefile.in | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/Examples/test-suite/go/Makefile.in b/Examples/test-suite/go/Makefile.in index 204cf8a12..5d8343be1 100644 --- a/Examples/test-suite/go/Makefile.in +++ b/Examples/test-suite/go/Makefile.in @@ -100,11 +100,12 @@ run_multi_testcase = \ @rm -f $*.go $*_gc.c $*_wrap.* $*_runme clean: - $(MAKE) -f $(top_builddir)/$(EXAMPLES)/Makefile go_clean + $(MAKE) -f $(top_builddir)/$(EXAMPLES)/Makefile SRCDIR="$(SRCDIR)" go_clean rm -f mod_a.go mod_b.go imports_a.go imports_b.go rm -f clientdata_prop_a.go clientdata_prop_b.go rm -f multi_import_a.go multi_import_b.go rm -f packageoption_a.go packageoption_b.go packageoption_c.go + rm -f import_stl_a.go import_stl_b.go cvsignore: @echo '*_gc.c *_wrap.* *.so *.dll *.exp *.lib' -- cgit v1.2.1 From 74e17fdbf662d04f21b484616174ca7abdf1d30f Mon Sep 17 00:00:00 2001 From: Karl Wette Date: Wed, 28 May 2014 23:39:10 +0200 Subject: Fix Javascript examples so that "make clean" works properly with node - Need to copy example.cxx to build directory so that build products end up in the right place; use a gyp command expansion to do so --- .gitignore | 1 + Examples/Makefile.in | 2 +- Examples/javascript/class/binding.gyp.in | 2 +- Examples/javascript/enum/binding.gyp.in | 2 +- Examples/javascript/exception/binding.gyp.in | 2 +- Examples/javascript/pointer/binding.gyp.in | 2 +- Examples/javascript/reference/binding.gyp.in | 2 +- Examples/javascript/simple/binding.gyp.in | 2 +- Examples/javascript/variables/binding.gyp.in | 2 +- 9 files changed, 9 insertions(+), 8 deletions(-) diff --git a/.gitignore b/.gitignore index e6c73c463..bce0812b7 100644 --- a/.gitignore +++ b/.gitignore @@ -124,6 +124,7 @@ Examples/test-suite/tcl/*/ Examples/test-suite/uffi/*/ *_wrap.c *_wrap.cxx +*-gypcopy.cxx # C# generated files *_runme.exe.mdb diff --git a/Examples/Makefile.in b/Examples/Makefile.in index 1f3b07205..123a634d7 100644 --- a/Examples/Makefile.in +++ b/Examples/Makefile.in @@ -730,7 +730,7 @@ javascript_clean: rm -f *_wrap* $(RUNME) rm -f core @EXTRA_CLEAN@ rm -f *.@OBJEXT@ *@JSSO@ *.$(SO) - rm -f binding.gyp + rm -f binding.gyp example-gypcopy.cxx cd $(ROOT_DIR)/Tools/javascript && $(MAKE) -s clean ################################################################## diff --git a/Examples/javascript/class/binding.gyp.in b/Examples/javascript/class/binding.gyp.in index c56a650e9..cb2b45e8f 100644 --- a/Examples/javascript/class/binding.gyp.in +++ b/Examples/javascript/class/binding.gyp.in @@ -2,7 +2,7 @@ "targets": [ { "target_name": "example", - "sources": [ "$srcdir/example.cxx", "example_wrap.cxx" ], + "sources": [ " Date: Wed, 28 May 2014 23:55:08 +0200 Subject: Fully clean Javascript test-suite with jsc and v8 --- Examples/test-suite/javascript/Makefile.in | 16 ++++++++++++---- 1 file changed, 12 insertions(+), 4 deletions(-) diff --git a/Examples/test-suite/javascript/Makefile.in b/Examples/test-suite/javascript/Makefile.in index a54fcd7e7..b6e946de2 100644 --- a/Examples/test-suite/javascript/Makefile.in +++ b/Examples/test-suite/javascript/Makefile.in @@ -107,7 +107,15 @@ endif %.clean: - rm -rf $* - rm -f $*_wrap.* - rm -f $*.so - rm -f $*.o + @rm -rf $* + @rm -f $*_wrap.* $*.so $*.o + +clean: + for ext in _wrap.cxx _wrap.o .so; do \ + rm -f clientdata_prop_a$${ext} clientdata_prop_b$${ext}; \ + rm -f imports_a$${ext} imports_b$${ext}; \ + rm -f import_stl_a$${ext} import_stl_b$${ext}; \ + rm -f mod_a$${ext} mod_b$${ext}; \ + rm -f multi_import_a$${ext} multi_import_b$${ext}; \ + rm -f packageoption_a$${ext} packageoption_b$${ext} packageoption_c$${ext}; \ + done -- cgit v1.2.1 From 7f48b2774b32d40c898d2a78d2fe4085aeb4dce9 Mon Sep 17 00:00:00 2001 From: Karl Wette Date: Wed, 28 May 2014 23:55:19 +0200 Subject: Fully clean PHP test-suite --- Examples/test-suite/php/Makefile.in | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) diff --git a/Examples/test-suite/php/Makefile.in b/Examples/test-suite/php/Makefile.in index 5f56760ea..00ccac325 100644 --- a/Examples/test-suite/php/Makefile.in +++ b/Examples/test-suite/php/Makefile.in @@ -65,7 +65,13 @@ run_testcase = \ # Clean: remove the generated .php file %.clean: - @rm -f $*.php; + @rm -f $*.php php_$*.h clean: - $(MAKE) -f $(top_builddir)/$(EXAMPLES)/Makefile php_clean + $(MAKE) -f $(top_builddir)/$(EXAMPLES)/Makefile SRCDIR="$(SRCDIR)" php_clean + rm -f clientdata_prop_a.php clientdata_prop_b.php php_clientdata_prop_a.h php_clientdata_prop_b.h + rm -f import_stl_a.php import_stl_b.php php_import_stl_a.h php_import_stl_b.h + rm -f imports_a.php imports_b.php php_imports_a.h php_imports_b.h + rm -f mod_a.php mod_b.php php_mod_a.h php_mod_b.h + rm -f multi_import_a.php multi_import_b.php php_multi_import_a.h php_multi_import_b.h + rm -f packageoption_a.php packageoption_b.php packageoption_c.php php_packageoption_a.h php_packageoption_b.h php_packageoption_c.h -- cgit v1.2.1 From cc0738bbda7d962b3d72479ac866bca4ab8867e9 Mon Sep 17 00:00:00 2001 From: Karl Wette Date: Wed, 28 May 2014 23:59:46 +0200 Subject: Fully clean Python examples and test-suite --- Examples/Makefile.in | 3 ++- Examples/python/import_packages/Makefile | 5 +++++ Examples/test-suite/python/Makefile.in | 7 +++---- 3 files changed, 10 insertions(+), 5 deletions(-) diff --git a/Examples/Makefile.in b/Examples/Makefile.in index 123a634d7..b1b460c56 100644 --- a/Examples/Makefile.in +++ b/Examples/Makefile.in @@ -401,7 +401,8 @@ python_clean: rm -f core @EXTRA_CLEAN@ rm -f *.@OBJEXT@ *@SO@ *@PYTHON_SO@ rm -f $(TARGET).py - if [ -f $(RUNME).py ]; then rm -f $(RUNME)3.py $(RUNME)3.py.bak; fi + if test -f $(SRCDIR)$(RUNME).py; then rm -f $(RUNME)3.py $(RUNME)3.py.bak; fi + if test "x$(SRCDIR)" != x; then rm -f $(RUNME).py; fi ################################################################## diff --git a/Examples/python/import_packages/Makefile b/Examples/python/import_packages/Makefile index 2df2be101..d5054fd22 100644 --- a/Examples/python/import_packages/Makefile +++ b/Examples/python/import_packages/Makefile @@ -35,6 +35,11 @@ static: clean: $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' python_clean + if test "x$(SRCDIR)" != x; then \ + for file in `cd $(SRCDIR) && find . -type f -name __init__.py`; do \ + rm -f "$$file" || exit 1; \ + done; \ + fi; \ for s in $(import_packages_subdirs); do \ (cd $$s && $(MAKE) clean); \ done diff --git a/Examples/test-suite/python/Makefile.in b/Examples/test-suite/python/Makefile.in index 492396d15..87443cb57 100644 --- a/Examples/test-suite/python/Makefile.in +++ b/Examples/test-suite/python/Makefile.in @@ -160,12 +160,11 @@ endif # We only remove the _runme3.py if it is generated by 2to3 from a _runme.py. %.clean: @rm -f $*.py - @if [ -f $(srcdir)/$(py2_runme) ]; then \ - rm -f $(SCRIPTDIR)/$(py3_runme) $(SCRIPTDIR)/$(py3_runme).bak; \ - fi + @if test -f $(srcdir)/$(py2_runme); then rm -f $(SCRIPTDIR)/$(py3_runme) $(SCRIPTDIR)/$(py3_runme).bak; fi + @if test "x$(SRCDIR)" != x; then rm -f $(SCRIPTDIR)/$(py2_runme); fi clean: - $(MAKE) -f $(top_builddir)/$(EXAMPLES)/Makefile python_clean + $(MAKE) -f $(top_builddir)/$(EXAMPLES)/Makefile SRCDIR="$(SRCDIR)" python_clean rm -f hugemod.h hugemod_a.i hugemod_b.i hugemod_a.py hugemod_b.py hugemod_runme.py rm -f clientdata_prop_a.py clientdata_prop_b.py import_stl_a.py import_stl_b.py rm -f imports_a.py imports_b.py mod_a.py mod_b.py multi_import_a.py -- cgit v1.2.1 From 3fe1eb705617c621f8f99d2f657cfe72a1049cce Mon Sep 17 00:00:00 2001 From: Karl Wette Date: Thu, 29 May 2014 01:13:42 +0200 Subject: Set SRCDIR when calling test-suite clean targets, in case it's needed --- Examples/test-suite/allegrocl/Makefile.in | 2 +- Examples/test-suite/cffi/Makefile.in | 2 +- Examples/test-suite/chicken/Makefile.in | 2 +- Examples/test-suite/clisp/Makefile.in | 2 +- Examples/test-suite/errors/Makefile.in | 2 +- Examples/test-suite/guile/Makefile.in | 2 +- Examples/test-suite/lua/Makefile.in | 2 +- Examples/test-suite/mzscheme/Makefile.in | 2 +- Examples/test-suite/ocaml/Makefile.in | 2 +- Examples/test-suite/octave/Makefile.in | 2 +- Examples/test-suite/perl5/Makefile.in | 2 +- Examples/test-suite/pike/Makefile.in | 2 +- Examples/test-suite/r/Makefile.in | 2 +- Examples/test-suite/ruby/Makefile.in | 2 +- Examples/test-suite/tcl/Makefile.in | 2 +- Examples/test-suite/uffi/Makefile.in | 2 +- 16 files changed, 16 insertions(+), 16 deletions(-) diff --git a/Examples/test-suite/allegrocl/Makefile.in b/Examples/test-suite/allegrocl/Makefile.in index 8c253a7f2..02ef8e302 100644 --- a/Examples/test-suite/allegrocl/Makefile.in +++ b/Examples/test-suite/allegrocl/Makefile.in @@ -123,4 +123,4 @@ run_testcase = \ @rm -f $*.cl clean: - $(MAKE) -f $(top_builddir)/$(EXAMPLES)/Makefile allegrocl_clean + $(MAKE) -f $(top_builddir)/$(EXAMPLES)/Makefile SRCDIR="$(SRCDIR)" allegrocl_clean diff --git a/Examples/test-suite/cffi/Makefile.in b/Examples/test-suite/cffi/Makefile.in index 6e657ba46..ee7e3f61e 100644 --- a/Examples/test-suite/cffi/Makefile.in +++ b/Examples/test-suite/cffi/Makefile.in @@ -48,4 +48,4 @@ run_testcase = \ @exit 0 clean: - $(MAKE) -f $(top_builddir)/$(EXAMPLES)/Makefile cffi_clean + $(MAKE) -f $(top_builddir)/$(EXAMPLES)/Makefile SRCDIR="$(SRCDIR)" cffi_clean diff --git a/Examples/test-suite/chicken/Makefile.in b/Examples/test-suite/chicken/Makefile.in index 5a2ef3d8a..31ab311bb 100644 --- a/Examples/test-suite/chicken/Makefile.in +++ b/Examples/test-suite/chicken/Makefile.in @@ -97,5 +97,5 @@ run_testcase = \ @exit 0 clean: - $(MAKE) -f $(top_builddir)/$(EXAMPLES)/Makefile chicken_clean + $(MAKE) -f $(top_builddir)/$(EXAMPLES)/Makefile SRCDIR="$(SRCDIR)" chicken_clean rm -f *.scm diff --git a/Examples/test-suite/clisp/Makefile.in b/Examples/test-suite/clisp/Makefile.in index 43f7159ff..6837ed60b 100644 --- a/Examples/test-suite/clisp/Makefile.in +++ b/Examples/test-suite/clisp/Makefile.in @@ -48,4 +48,4 @@ run_testcase = \ @exit 0 clean: - $(MAKE) -f $(top_builddir)/$(EXAMPLES)/Makefile clisp_clean + $(MAKE) -f $(top_builddir)/$(EXAMPLES)/Makefile SRCDIR="$(SRCDIR)" clisp_clean diff --git a/Examples/test-suite/errors/Makefile.in b/Examples/test-suite/errors/Makefile.in index da67db8bd..3b165f9cd 100644 --- a/Examples/test-suite/errors/Makefile.in +++ b/Examples/test-suite/errors/Makefile.in @@ -53,5 +53,5 @@ include $(srcdir)/../common.mk @exit 0 clean: - $(MAKE) -f $(top_builddir)/$(EXAMPLES)/Makefile python_clean + $(MAKE) -f $(top_builddir)/$(EXAMPLES)/Makefile SRCDIR="$(SRCDIR)" python_clean @rm -f *.$(ERROR_EXT) *.py diff --git a/Examples/test-suite/guile/Makefile.in b/Examples/test-suite/guile/Makefile.in index 6cbf3b9b1..9050d76f5 100644 --- a/Examples/test-suite/guile/Makefile.in +++ b/Examples/test-suite/guile/Makefile.in @@ -62,4 +62,4 @@ run_testcase = \ @rm -f $*-guile clean: - $(MAKE) -f $(top_builddir)/$(EXAMPLES)/Makefile guile_clean + $(MAKE) -f $(top_builddir)/$(EXAMPLES)/Makefile SRCDIR="$(SRCDIR)" guile_clean diff --git a/Examples/test-suite/lua/Makefile.in b/Examples/test-suite/lua/Makefile.in index 00f940825..c562f09df 100644 --- a/Examples/test-suite/lua/Makefile.in +++ b/Examples/test-suite/lua/Makefile.in @@ -56,7 +56,7 @@ run_testcase = \ @exit 0 clean: - $(MAKE) -f $(top_builddir)/$(EXAMPLES)/Makefile lua_clean + $(MAKE) -f $(top_builddir)/$(EXAMPLES)/Makefile SRCDIR="$(SRCDIR)" lua_clean cvsignore: @echo '*wrap* *.so *.dll *.exp *.lib' diff --git a/Examples/test-suite/mzscheme/Makefile.in b/Examples/test-suite/mzscheme/Makefile.in index 034e52131..da92f76fd 100644 --- a/Examples/test-suite/mzscheme/Makefile.in +++ b/Examples/test-suite/mzscheme/Makefile.in @@ -46,4 +46,4 @@ run_testcase = \ @exit 0 clean: - $(MAKE) -f $(top_builddir)/$(EXAMPLES)/Makefile mzscheme_clean + $(MAKE) -f $(top_builddir)/$(EXAMPLES)/Makefile SRCDIR="$(SRCDIR)" mzscheme_clean diff --git a/Examples/test-suite/ocaml/Makefile.in b/Examples/test-suite/ocaml/Makefile.in index ee93d534c..9a4e008b9 100644 --- a/Examples/test-suite/ocaml/Makefile.in +++ b/Examples/test-suite/ocaml/Makefile.in @@ -81,4 +81,4 @@ include $(srcdir)/../common.mk @rm -f $*.ml $*.mli; clean: - $(MAKE) -f $(top_builddir)/$(EXAMPLES)/Makefile ocaml_clean + $(MAKE) -f $(top_builddir)/$(EXAMPLES)/Makefile SRCDIR="$(SRCDIR)" ocaml_clean diff --git a/Examples/test-suite/octave/Makefile.in b/Examples/test-suite/octave/Makefile.in index 4f78371f4..fbffd240c 100644 --- a/Examples/test-suite/octave/Makefile.in +++ b/Examples/test-suite/octave/Makefile.in @@ -68,7 +68,7 @@ run_testcase = \ @rm -f $*.m; clean: - $(MAKE) -f $(top_builddir)/$(EXAMPLES)/Makefile octave_clean + $(MAKE) -f $(top_builddir)/$(EXAMPLES)/Makefile SRCDIR="$(SRCDIR)" octave_clean cvsignore: @echo '*wrap* *.mc *.so *.dll *.exp *.lib' diff --git a/Examples/test-suite/perl5/Makefile.in b/Examples/test-suite/perl5/Makefile.in index 9d9d460d8..a4628ddcb 100644 --- a/Examples/test-suite/perl5/Makefile.in +++ b/Examples/test-suite/perl5/Makefile.in @@ -59,4 +59,4 @@ run_testcase = \ @rm -f $*.pm; clean: - $(MAKE) -f $(top_builddir)/$(EXAMPLES)/Makefile perl5_clean + $(MAKE) -f $(top_builddir)/$(EXAMPLES)/Makefile SRCDIR="$(SRCDIR)" perl5_clean diff --git a/Examples/test-suite/pike/Makefile.in b/Examples/test-suite/pike/Makefile.in index 579c7e28f..92054dd9d 100644 --- a/Examples/test-suite/pike/Makefile.in +++ b/Examples/test-suite/pike/Makefile.in @@ -46,4 +46,4 @@ run_testcase = \ @rm -f $*.pike; clean: - $(MAKE) -f $(top_builddir)/$(EXAMPLES)/Makefile pike_clean + $(MAKE) -f $(top_builddir)/$(EXAMPLES)/Makefile SRCDIR="$(SRCDIR)" pike_clean diff --git a/Examples/test-suite/r/Makefile.in b/Examples/test-suite/r/Makefile.in index 8ee73b279..d0489531f 100644 --- a/Examples/test-suite/r/Makefile.in +++ b/Examples/test-suite/r/Makefile.in @@ -66,7 +66,7 @@ run_multitestcase = \ done # Clean clean: - $(MAKE) -f $(top_builddir)/$(EXAMPLES)/Makefile r_clean + $(MAKE) -f $(top_builddir)/$(EXAMPLES)/Makefile SRCDIR="$(SRCDIR)" r_clean %.clean: @rm -f $*.R $*_wrap.so $*_wrap.cpp $*_wrap.c $*_wrap.o $*_runme.Rout $*.Rout diff --git a/Examples/test-suite/ruby/Makefile.in b/Examples/test-suite/ruby/Makefile.in index 206617ecd..1a6875360 100644 --- a/Examples/test-suite/ruby/Makefile.in +++ b/Examples/test-suite/ruby/Makefile.in @@ -70,4 +70,4 @@ run_testcase = \ @exit 0 clean: - $(MAKE) -f $(top_builddir)/$(EXAMPLES)/Makefile ruby_clean + $(MAKE) -f $(top_builddir)/$(EXAMPLES)/Makefile SRCDIR="$(SRCDIR)" ruby_clean diff --git a/Examples/test-suite/tcl/Makefile.in b/Examples/test-suite/tcl/Makefile.in index 32454b09c..82c59dee4 100644 --- a/Examples/test-suite/tcl/Makefile.in +++ b/Examples/test-suite/tcl/Makefile.in @@ -55,4 +55,4 @@ run_testcase = \ @exit 0 clean: - $(MAKE) -f $(top_builddir)/$(EXAMPLES)/Makefile tcl_clean + $(MAKE) -f $(top_builddir)/$(EXAMPLES)/Makefile SRCDIR="$(SRCDIR)" tcl_clean diff --git a/Examples/test-suite/uffi/Makefile.in b/Examples/test-suite/uffi/Makefile.in index 59aa33c6a..275778c87 100644 --- a/Examples/test-suite/uffi/Makefile.in +++ b/Examples/test-suite/uffi/Makefile.in @@ -48,4 +48,4 @@ run_testcase = \ @exit 0 clean: - $(MAKE) -f $(top_builddir)/$(EXAMPLES)/Makefile uffi_clean + $(MAKE) -f $(top_builddir)/$(EXAMPLES)/Makefile SRCDIR="$(SRCDIR)" uffi_clean -- cgit v1.2.1 From b51bc39cf7ad2eb9c037f735a2839283c19d1f03 Mon Sep 17 00:00:00 2001 From: Karl Wette Date: Wed, 28 May 2014 21:18:41 +0200 Subject: Add check-maintainer-clean target: fails if files are missed by maintainer-clean --- .travis.yml | 2 +- Makefile.in | 8 ++++++++ 2 files changed, 9 insertions(+), 1 deletion(-) diff --git a/.travis.yml b/.travis.yml index 89bed90a1..08731ca62 100644 --- a/.travis.yml +++ b/.travis.yml @@ -113,7 +113,7 @@ script: - if test -n "$SWIGLANG"; then make -k $SWIGJOBS check-$SWIGLANG-examples CFLAGS="${CFLAGS_EXAMPLES[$SWIGLANG]}" CXXFLAGS="${CXXFLAGS_EXAMPLES[$SWIGLANG]}"; fi - if test -n "$SWIGLANG"; then make -k $SWIGJOBS check-$SWIGLANG-test-suite; fi - echo 'Cleaning...' && echo -en 'travis_fold:start:script.3\\r' - - make maintainer-clean && find . -type f | sed 's/^/File left after maintainer-clean - /' && ../../configure $CONFIGOPTS + - make check-maintainer-clean && ../../configure $CONFIGOPTS - echo -en 'travis_fold:end:script.3\\r' branches: only: diff --git a/Makefile.in b/Makefile.in index 2b9cf3b32..05c506559 100644 --- a/Makefile.in +++ b/Makefile.in @@ -455,6 +455,14 @@ maintainer-clean: @echo distcleaning @$(MAKE) $(FLAGS) distclean-helper +check-maintainer-clean: maintainer-clean + @if test "x$(srcdir)" != "x."; then \ + for file in `find . -type f`; do \ + echo "file missed by maintainer-clean: $$file"; \ + done; \ + fi; \ + test "x$$file" = x && echo "all files cleaned by maintainer-clean" + ##################################################################### # Update the Lib/swigwarn.swg file # Note: Generated into the source tree rather than build tree -- cgit v1.2.1 From 664c6cc81e88b300e21206623ae0053eec43e627 Mon Sep 17 00:00:00 2001 From: William S Fulton Date: Thu, 29 May 2014 07:50:21 +0100 Subject: Fix infinity testcase on windows --- Examples/test-suite/infinity.i | 27 ++++++++++++++++++------ Examples/test-suite/javascript/infinity_runme.js | 1 + 2 files changed, 21 insertions(+), 7 deletions(-) diff --git a/Examples/test-suite/infinity.i b/Examples/test-suite/infinity.i index 726150f02..4aa987c11 100644 --- a/Examples/test-suite/infinity.i +++ b/Examples/test-suite/infinity.i @@ -10,15 +10,16 @@ #include /* C99 math.h defines INFINITY. If not available, this is the fallback. */ -#ifndef INFINITY - #ifdef _MSC_VER +#if !defined(INFINITY) + #if defined(_MSC_VER) union MSVC_EVIL_FLOAT_HACK { unsigned __int8 Bytes[4]; float Value; }; - static union MSVC_EVIL_FLOAT_HACK INFINITY_HACK = {{0x00, 0x00, 0x80, 0x7F}}; + const union MSVC_EVIL_FLOAT_HACK INFINITY_HACK = {{0x00, 0x00, 0x80, 0x7F}}; #define INFINITY (INFINITY_HACK.Value) + #define INFINITY_NO_CONST #endif #ifdef __GNUC__ @@ -33,15 +34,27 @@ #define INFINITY (1e1000) #endif #endif -%} -%inline %{ -/* This will allow us to bind the real INFINITY value through SWIG via MYINFINITY. Use %rename to fix the name. */ +#ifdef INFINITY_NO_CONST +/* To void: error C2099: initializer is not a constant */ +double MYINFINITY = 0.0; +void initialise_MYINFINITY(void) { + MYINFINITY = INFINITY; +} +#else const double MYINFINITY = INFINITY; +void initialise_MYINFINITY(void) { +} +#endif -/* Use of float is intentional because the original bug was in the float conversion due to overflow checking. */ float use_infinity(float inf_val) { return inf_val; } %} + +/* This will allow us to bind the real INFINITY value through SWIG via MYINFINITY. Use %rename to fix the name. */ +const double MYINFINITY = INFINITY; +/* Use of float is intentional because the original bug was in the float conversion due to overflow checking. */ +float use_infinity(float inf_val); + diff --git a/Examples/test-suite/javascript/infinity_runme.js b/Examples/test-suite/javascript/infinity_runme.js index 050c391a7..8ebe496a6 100644 --- a/Examples/test-suite/javascript/infinity_runme.js +++ b/Examples/test-suite/javascript/infinity_runme.js @@ -1,4 +1,5 @@ var infinity = require("infinity"); +infinity.initialise_MYINFINITY(); var my_infinity = infinity.INFINITY; var ret_val = infinity.use_infinity(my_infinity); -- cgit v1.2.1 From 42938dc520d0c13c5d7e463298a2bd77f5ea9c82 Mon Sep 17 00:00:00 2001 From: William S Fulton Date: Thu, 29 May 2014 08:42:38 +0100 Subject: Correct infinity testcase --- Examples/test-suite/infinity.i | 1 + 1 file changed, 1 insertion(+) diff --git a/Examples/test-suite/infinity.i b/Examples/test-suite/infinity.i index 4aa987c11..e95bdf9cf 100644 --- a/Examples/test-suite/infinity.i +++ b/Examples/test-suite/infinity.i @@ -55,6 +55,7 @@ float use_infinity(float inf_val) /* This will allow us to bind the real INFINITY value through SWIG via MYINFINITY. Use %rename to fix the name. */ const double MYINFINITY = INFINITY; +void initialise_MYINFINITY(void); /* Use of float is intentional because the original bug was in the float conversion due to overflow checking. */ float use_infinity(float inf_val); -- cgit v1.2.1 From b71eb53baeb26f5052ed6da5064af6b10d0e6844 Mon Sep 17 00:00:00 2001 From: William S Fulton Date: Thu, 29 May 2014 08:44:19 +0100 Subject: Fix errors test-suite on windows --- Examples/test-suite/errors/Makefile.in | 21 ++++++++++----------- 1 file changed, 10 insertions(+), 11 deletions(-) diff --git a/Examples/test-suite/errors/Makefile.in b/Examples/test-suite/errors/Makefile.in index 3b165f9cd..4c61001e7 100644 --- a/Examples/test-suite/errors/Makefile.in +++ b/Examples/test-suite/errors/Makefile.in @@ -15,18 +15,11 @@ LANGUAGE = errors ERROR_EXT = newerr -# Portable dos2unix / todos for stripping CR -TODOS = tr -d '\r' -#TODOS = sed -e 's/\r$$//' # On OSX behaves as if written 's/r$$//' srcdir = @srcdir@ top_srcdir = @top_srcdir@ top_builddir = @top_builddir@ -# strip source directory from output, so that diffs compare -srcdir_regexp = $(shell echo $(srcdir)/ | sed 's/\./[.]/g') -STRIP_SRCDIR = sed 's|^$(srcdir_regexp)||' - # All .i files with prefix 'cpp_' will be treated as C++ input and remaining .i files as C input ALL_ERROR_TEST_CASES := $(patsubst %.i,%, $(notdir $(wildcard $(srcdir)/*.i))) CPP_ERROR_TEST_CASES := $(filter cpp_%, $(ALL_ERROR_TEST_CASES)) @@ -37,17 +30,23 @@ ERROR_TEST_CASES := $(CPP_ERROR_TEST_CASES:=.cpptest) \ include $(srcdir)/../common.mk +# Portable dos2unix / todos for stripping CR +TODOS = tr -d '\r' +#TODOS = sed -e 's/\r$$//' # On OSX behaves as if written 's/r$$//' + +# strip source directory from output, so that diffs compare +STRIP_SRCDIR = sed -e 's|\\|/|g' -e 's|^$(SRCDIR)||' # Rules for the different types of tests %.cpptest: echo "$(ACTION)ing errors testcase $*" - -$(SWIG) -c++ -python -Wall -Fstandard $(SWIGOPT) $(srcdir)/$*.i 2>&1 | $(TODOS) | $(STRIP_SRCDIR) > $*.$(ERROR_EXT) - $(COMPILETOOL) diff -c $(srcdir)/$*.stderr $*.$(ERROR_EXT) + -$(SWIG) -c++ -python -Wall -Fstandard $(SWIGOPT) $(SRCDIR)$*.i 2>&1 | $(TODOS) | $(STRIP_SRCDIR) > $*.$(ERROR_EXT) + $(COMPILETOOL) diff -c $(SRCDIR)$*.stderr $*.$(ERROR_EXT) %.ctest: echo "$(ACTION)ing errors testcase $*" - -$(SWIG) -python -Wall -Fstandard $(SWIGOPT) $(srcdir)/$*.i 2>&1 | $(TODOS) | $(STRIP_SRCDIR) > $*.$(ERROR_EXT) - $(COMPILETOOL) diff -c $(srcdir)/$*.stderr $*.$(ERROR_EXT) + -$(SWIG) -python -Wall -Fstandard $(SWIGOPT) $(SRCDIR)$*.i 2>&1 | $(TODOS) | $(STRIP_SRCDIR) > $*.$(ERROR_EXT) + $(COMPILETOOL) diff -c $(SRCDIR)$*.stderr $*.$(ERROR_EXT) %.clean: @exit 0 -- cgit v1.2.1 From eb61c85e5f4c5a79dd8e01a36bddae9271612da2 Mon Sep 17 00:00:00 2001 From: Karl Wette Date: Thu, 29 May 2014 14:26:02 +0200 Subject: check-maintainer-clean: print skipping message for in-source-tree builds --- Makefile.in | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) diff --git a/Makefile.in b/Makefile.in index 05c506559..bb0845f37 100644 --- a/Makefile.in +++ b/Makefile.in @@ -456,11 +456,13 @@ maintainer-clean: @$(MAKE) $(FLAGS) distclean-helper check-maintainer-clean: maintainer-clean - @if test "x$(srcdir)" != "x."; then \ - for file in `find . -type f`; do \ - echo "file missed by maintainer-clean: $$file"; \ - done; \ + @if test "x$(srcdir)" = "x."; then \ + echo "skipping maintainer-clean check (in-source-tree build)"; \ + exit 0; \ fi; \ + for file in `find . -type f`; do \ + echo "file missed by maintainer-clean: $$file"; \ + done; \ test "x$$file" = x && echo "all files cleaned by maintainer-clean" ##################################################################### -- cgit v1.2.1 From b8026cc02f6b7639afd83cbd4e0419963d8c9428 Mon Sep 17 00:00:00 2001 From: Karl Wette Date: Thu, 29 May 2014 14:35:23 +0200 Subject: Fix cleaning of Python runme.py scripts for in-source-tree builds --- Examples/Makefile.in | 2 +- Examples/test-suite/python/Makefile.in | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/Examples/Makefile.in b/Examples/Makefile.in index b1b460c56..521df3a70 100644 --- a/Examples/Makefile.in +++ b/Examples/Makefile.in @@ -402,7 +402,7 @@ python_clean: rm -f *.@OBJEXT@ *@SO@ *@PYTHON_SO@ rm -f $(TARGET).py if test -f $(SRCDIR)$(RUNME).py; then rm -f $(RUNME)3.py $(RUNME)3.py.bak; fi - if test "x$(SRCDIR)" != x; then rm -f $(RUNME).py; fi + case "x$(SRCDIR)" in x|x./);; *) rm -f $(RUNME).py;; esac ################################################################## diff --git a/Examples/test-suite/python/Makefile.in b/Examples/test-suite/python/Makefile.in index 87443cb57..9673d7da1 100644 --- a/Examples/test-suite/python/Makefile.in +++ b/Examples/test-suite/python/Makefile.in @@ -161,7 +161,7 @@ endif %.clean: @rm -f $*.py @if test -f $(srcdir)/$(py2_runme); then rm -f $(SCRIPTDIR)/$(py3_runme) $(SCRIPTDIR)/$(py3_runme).bak; fi - @if test "x$(SRCDIR)" != x; then rm -f $(SCRIPTDIR)/$(py2_runme); fi + @if test "x$(SCRIPTDIR)" != "x$(srcdir)"; then rm -f $(SCRIPTDIR)/$(py2_runme); fi clean: $(MAKE) -f $(top_builddir)/$(EXAMPLES)/Makefile SRCDIR="$(SRCDIR)" python_clean -- cgit v1.2.1 From 79c91607369510a02788fb9e992f9de48118b835 Mon Sep 17 00:00:00 2001 From: William S Fulton Date: Thu, 29 May 2014 16:54:08 +0100 Subject: Search for 64bit webkit during configure For some Linux distributions (SUSE) --- configure.ac | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/configure.ac b/configure.ac index 8af45b69f..77b804ddd 100644 --- a/configure.ac +++ b/configure.ac @@ -1191,7 +1191,7 @@ else if test -z "$JSCORELIB"; then case $host in *-*-linux*) - dirs="/usr/lib/ /usr/local/lib/" + dirs="/usr/lib64/ /usr/local/lib64/ /usr/lib/ /usr/local/lib/" for i in $dirs ; do if test -r $i/libjavascriptcoregtk-1.0.so; then AC_MSG_RESULT($i) @@ -1259,7 +1259,7 @@ else AC_MSG_CHECKING(for V8 Javascript library) AC_ARG_WITH(jsv8lib,[ --with-v8lib=path Set location of V8 Javascript library directory],[JSV8LIBDIR="$withval"], [JSV8LIB=]) - v8libdirs="$JSV8LIBDIR /usr/lib*/ /usr/local/lib*/" + v8libdirs="$JSV8LIBDIR /usr/lib64/ /usr/local/lib64/ /usr/lib/ /usr/local/lib/" for d in $v8libdirs ; do if test -r $d/libv8.so; then JSV8LIBDIR=$d -- cgit v1.2.1 From 36a6a0cbe0654693f667fffc349dcb28d1549839 Mon Sep 17 00:00:00 2001 From: William S Fulton Date: Thu, 29 May 2014 19:54:13 +0100 Subject: Update AX_BOOST_BASE autoconf macro to serial 23 --- Tools/config/ax_boost_base.m4 | 21 ++++++++++++++++++--- 1 file changed, 18 insertions(+), 3 deletions(-) diff --git a/Tools/config/ax_boost_base.m4 b/Tools/config/ax_boost_base.m4 index 54a2a1bee..550b64138 100644 --- a/Tools/config/ax_boost_base.m4 +++ b/Tools/config/ax_boost_base.m4 @@ -33,7 +33,7 @@ # and this notice are preserved. This file is offered as-is, without any # warranty. -#serial 20 +#serial 23 AC_DEFUN([AX_BOOST_BASE], [ @@ -91,9 +91,23 @@ if test "x$want_boost" = "xyes"; then dnl are found, e.g. when only header-only libraries are installed! libsubdirs="lib" ax_arch=`uname -m` - if test $ax_arch = x86_64 -o $ax_arch = ppc64 -o $ax_arch = s390x -o $ax_arch = sparc64; then + case $ax_arch in + x86_64|ppc64|s390x|sparc64|aarch64) libsubdirs="lib64 lib lib64" - fi + ;; + esac + + dnl allow for real multi-arch paths e.g. /usr/lib/x86_64-linux-gnu. Give + dnl them priority over the other paths since, if libs are found there, they + dnl are almost assuredly the ones desired. + AC_REQUIRE([AC_CANONICAL_HOST]) + libsubdirs="lib/${host_cpu}-${host_os} $libsubdirs" + + case ${host_cpu} in + i?86) + libsubdirs="lib/i386-${host_os} $libsubdirs" + ;; + esac dnl first we check the system location for boost libraries dnl this location ist chosen if boost libraries are installed with the --layout=system option @@ -256,3 +270,4 @@ if test "x$want_boost" = "xyes"; then fi ]) + -- cgit v1.2.1 From cdd894d2af8eb2454006bf1a866b9bc59b70d3b5 Mon Sep 17 00:00:00 2001 From: Karl Wette Date: Tue, 27 May 2014 01:15:10 +0200 Subject: .gitignore: add Source/TAGS --- .gitignore | 1 + 1 file changed, 1 insertion(+) diff --git a/.gitignore b/.gitignore index bce0812b7..b67e1d219 100644 --- a/.gitignore +++ b/.gitignore @@ -90,6 +90,7 @@ Lib/swigwarn.swg Source/CParse/parser.c Source/CParse/parser.h Source/eswig +Source/TAGS swig Tools/javascript/javascript -- cgit v1.2.1 From 603a73142ad9e97bc0435261f8f3067ad6653bbb Mon Sep 17 00:00:00 2001 From: Karl Wette Date: Mon, 26 May 2014 20:39:04 +0200 Subject: Octave: ignore generated files --- .gitignore | 3 +++ 1 file changed, 3 insertions(+) diff --git a/.gitignore b/.gitignore index b67e1d219..28b44271f 100644 --- a/.gitignore +++ b/.gitignore @@ -134,6 +134,9 @@ Examples/test-suite/uffi/*/ # Javascript generated files *.gyp +# Octave generated files +swigexample*.oct + # Python generated files, based on: # https://github.com/github/gitignore/blob/master/Python.gitignore *.py[cod] -- cgit v1.2.1 From 5c5510842b5c443db0294ca924f13bd1f7ec7fa0 Mon Sep 17 00:00:00 2001 From: Karl Wette Date: Mon, 26 May 2014 21:35:02 +0200 Subject: Octave: remove Python code from std_carray.i --- Lib/octave/std_carray.i | 56 ------------------------------------------------- 1 file changed, 56 deletions(-) diff --git a/Lib/octave/std_carray.i b/Lib/octave/std_carray.i index 9e2338a61..e69de29bb 100644 --- a/Lib/octave/std_carray.i +++ b/Lib/octave/std_carray.i @@ -1,56 +0,0 @@ -%include - -/* -%fragment("StdCarrayTraits","header",fragment="StdSequenceTraits") -{ -namespace swig { - template - struct traits_asptr > { - static int asptr(PyObject *obj, std::carray **array) { - return traits_asptr_stdseq >::asptr(obj, array); - } - }; -} -} - -%warnfilter(SWIGWARN_IGNORE_OPERATOR_INDEX) std::carray::operator[]; - -%extend std::carray { - %fragment(SWIG_Traits_frag(std::carray<_Type, _Size >), "header", - fragment="SwigPyIterator_T", - fragment=SWIG_Traits_frag(_Type), - fragment="StdCarrayTraits") { - namespace swig { - template <> struct traits > { - typedef pointer_category category; - static const char* type_name() { - return "std::carray<" #_Type "," #_Size " >"; - } - }; - } - } - - %typemaps_asptr(SWIG_TYPECHECK_VECTOR, swig::asptr, - SWIG_Traits_frag(std::carray<_Type, _Size >), - std::carray<_Type, _Size >); - - %typemap(out,noblock=1) iterator, const_iterator { - $result = SWIG_NewPointerObj(swig::make_output_iterator((const $type &)$1), - swig::SwigPyIterator::descriptor(),SWIG_POINTER_OWN); - } - - inline size_t __len__() const { return self->size(); } - - inline const _Type& __getitem__(size_t i) const { return (*self)[i]; } - - inline void __setitem__(size_t i, const _Type& v) { (*self)[i] = v; } - - - swig::SwigPyIterator* __iter__(PyObject **PYTHON_SELF) { - return swig::make_output_iterator(self->begin(), self->begin(), self->end(), *PYTHON_SELF); - } -} - -%include -*/ - -- cgit v1.2.1 From ebe13380158ad5f552405463287d3cb4cdecc8bd Mon Sep 17 00:00:00 2001 From: Karl Wette Date: Wed, 21 May 2014 22:31:36 +0200 Subject: Octave: whitespace/indentation cleanup of octave.cxx --- Source/Modules/octave.cxx | 682 +++++++++++++++++++++++----------------------- 1 file changed, 341 insertions(+), 341 deletions(-) diff --git a/Source/Modules/octave.cxx b/Source/Modules/octave.cxx index 103b59194..1c8b639bb 100644 --- a/Source/Modules/octave.cxx +++ b/Source/Modules/octave.cxx @@ -1,5 +1,5 @@ /* ----------------------------------------------------------------------------- - * This file is part of SWIG, which is licensed as a whole under version 3 + * This file is part of SWIG, which is licensed as a whole under version 3 * (or any later version) of the GNU General Public License. Some additional * terms also apply to certain portions of SWIG. The full details of the SWIG * license and copyrights can be found in the LICENSE and COPYRIGHT files @@ -75,51 +75,51 @@ public: constructor_name(0), docs(0) { - /* Add code to manage protected constructors and directors */ - director_prot_ctor_code = NewString(""); - Printv(director_prot_ctor_code, - "if ( $comparison ) { /* subclassed */\n", - " $director_new \n", - "} else {\n", " error(\"accessing abstract class or protected constructor\"); \n", " SWIG_fail;\n", "}\n", NIL); - - enable_cplus_runtime_mode(); - allow_overloading(); - director_multiple_inheritance = 1; - director_language = 1; - docs = NewHash(); - } + /* Add code to manage protected constructors and directors */ + director_prot_ctor_code = NewString(""); + Printv(director_prot_ctor_code, + "if ( $comparison ) { /* subclassed */\n", + " $director_new \n", + "} else {\n", " error(\"accessing abstract class or protected constructor\"); \n", " SWIG_fail;\n", "}\n", NIL); + + enable_cplus_runtime_mode(); + allow_overloading(); + director_multiple_inheritance = 1; + director_language = 1; + docs = NewHash(); + } virtual void main(int argc, char *argv[]) { for (int i = 1; i < argc; i++) { if (argv[i]) { - if (strcmp(argv[i], "-help") == 0) { - fputs(usage, stdout); - } else if (strcmp(argv[i], "-global") == 0 || + if (strcmp(argv[i], "-help") == 0) { + fputs(usage, stdout); + } else if (strcmp(argv[i], "-global") == 0 || strcmp(argv[i], "-noglobal") == 0) { - Printv(stderr, + Printv(stderr, "*** -global/-noglobal are no longer supported\n" "*** global load behaviour is now determined at module load\n" "*** see the Perl section in the manual for details.\n", NIL); - SWIG_exit(EXIT_FAILURE); - } else if (strcmp(argv[i], "-globals") == 0) { - if (argv[i + 1]) { - global_name = NewString(argv[i + 1]); - Swig_mark_arg(i); - Swig_mark_arg(i + 1); - i++; - } else { - Swig_arg_error(); - } - } else if (strcmp(argv[i], "-opprefix") == 0) { - if (argv[i + 1]) { - op_prefix = NewString(argv[i + 1]); - Swig_mark_arg(i); - Swig_mark_arg(i + 1); - i++; - } else { - Swig_arg_error(); - } - } + SWIG_exit(EXIT_FAILURE); + } else if (strcmp(argv[i], "-globals") == 0) { + if (argv[i + 1]) { + global_name = NewString(argv[i + 1]); + Swig_mark_arg(i); + Swig_mark_arg(i + 1); + i++; + } else { + Swig_arg_error(); + } + } else if (strcmp(argv[i], "-opprefix") == 0) { + if (argv[i + 1]) { + op_prefix = NewString(argv[i + 1]); + Swig_mark_arg(i); + Swig_mark_arg(i + 1); + i++; + } else { + Swig_arg_error(); + } + } } } @@ -143,21 +143,21 @@ public: { Node *mod = Getattr(n, "module"); if (mod) { - Node *options = Getattr(mod, "options"); - if (options) { - int dirprot = 0; - if (Getattr(options, "dirprot")) { - dirprot = 1; - } - if (Getattr(options, "nodirprot")) { - dirprot = 0; - } - if (Getattr(options, "directors")) { - allow_directors(); - if (dirprot) - allow_dirprot(); - } - } + Node *options = Getattr(mod, "options"); + if (options) { + int dirprot = 0; + if (Getattr(options, "dirprot")) { + dirprot = 1; + } + if (Getattr(options, "nodirprot")) { + dirprot = 0; + } + if (Getattr(options, "directors")) { + allow_directors(); + if (dirprot) + allow_dirprot(); + } + } } } @@ -202,8 +202,8 @@ public: Printf(f_runtime, "#define SWIG_DIRECTORS\n"); Swig_banner(f_directors_h); if (dirprot_mode()) { - // Printf(f_directors_h, "#include \n"); - // Printf(f_directors_h, "#include \n\n"); + // Printf(f_directors_h, "#include \n"); + // Printf(f_directors_h, "#include \n\n"); } } @@ -263,19 +263,19 @@ public: String *r = NewString(""); for (int j=0;s[j];++j) { if (s[j] == '\n') { - Append(r, "\\n\\\n"); + Append(r, "\\n\\\n"); } else if (s[j] == '\r') { - Append(r, "\\r"); + Append(r, "\\r"); } else if (s[j] == '\t') { - Append(r, "\\t"); + Append(r, "\\t"); } else if (s[j] == '\\') { - Append(r, "\\\\"); + Append(r, "\\\\"); } else if (s[j] == '\'') { - Append(r, "\\\'"); + Append(r, "\\\'"); } else if (s[j] == '\"') { - Append(r, "\\\""); + Append(r, "\\\""); } else - Putc(s[j], r); + Putc(s[j], r); } return r; } @@ -293,11 +293,11 @@ public: String *escaped_doc_str = texinfo_escape(doc_str); if (Len(doc_str)>0) { - Printf(f_doc,"static const char* %s_texinfo = ",wrap_name); - Printf(f_doc,"\"-*- texinfo -*-\\n\\\n%s", escaped_doc_str); - if (Len(decl_info)) - Printf(f_doc,"\\n\\\n@end deftypefn"); - Printf(f_doc,"\";\n"); + Printf(f_doc,"static const char* %s_texinfo = ",wrap_name); + Printf(f_doc,"\"-*- texinfo -*-\\n\\\n%s", escaped_doc_str); + if (Len(decl_info)) + Printf(f_doc,"\\n\\\n@end deftypefn"); + Printf(f_doc,"\";\n"); } Delete(escaped_doc_str); @@ -313,7 +313,7 @@ public: String *decl_info = Getattr(n, "decl_info"); String *cdecl_info = Getattr(n, "cdecl_info"); String *args_info = Getattr(n, "args_info"); - return !Len(synopsis) && !Len(decl_info) && + return !Len(synopsis) && !Len(decl_info) && !Len(cdecl_info) && !Len(args_info); } String *texinfo_name(Node* n, const char* defval = "0") { @@ -360,11 +360,11 @@ public: SwigType *type = Getattr(n, "type"); if (type && Strcmp(type, "void")) { - Node *nn = classLookup(Getattr(n, "type")); - String *type_str = nn ? Copy(Getattr(nn, "sym:name")) : SwigType_str(type, 0); - Append(decl_info, "@var{retval} = "); - Printf(args_str, "%s@var{retval} is of type %s. ", args_str, type_str); - Delete(type_str); + Node *nn = classLookup(Getattr(n, "type")); + String *type_str = nn ? Copy(Getattr(nn, "sym:name")) : SwigType_str(type, 0); + Append(decl_info, "@var{retval} = "); + Printf(args_str, "%s@var{retval} is of type %s. ", args_str, type_str); + Delete(type_str); } Append(decl_info, name); @@ -380,8 +380,8 @@ public: // strip off {} if necessary char *t = Char(str); if (*t == '{') { - Delitem(str, 0); - Delitem(str, DOH_END); + Delitem(str, 0); + Delitem(str, DOH_END); } // emit into synopsis section @@ -408,7 +408,7 @@ public: * addMissingParameterNames() * For functions that have not had nameless parameters set in the Language class. * - * Inputs: + * Inputs: * plist - entire parameter list * arg_offset - argument number for first parameter * Side effects: @@ -420,8 +420,8 @@ public: int i = arg_offset; while (p) { if (!Getattr(p, "lname")) { - String *pname = Swig_cparm_name(p, i); - Delete(pname); + String *pname = Swig_cparm_name(p, i); + Delete(pname); } i++; p = nextSibling(p); @@ -444,12 +444,12 @@ public: String *tm = Getattr(p, "tmap:in"); if (tm) { - pnext = Getattr(p, "tmap:in:next"); - if (checkAttribute(p, "tmap:in:numinputs", "0")) { - continue; - } + pnext = Getattr(p, "tmap:in:next"); + if (checkAttribute(p, "tmap:in:numinputs", "0")) { + continue; + } } else { - pnext = nextSibling(p); + pnext = nextSibling(p); } String *name = 0; @@ -457,9 +457,9 @@ public: String *value = 0; String *pdoc = Getattr(p, "tmap:doc"); if (pdoc) { - name = Getattr(p, "tmap:doc:name"); - type = Getattr(p, "tmap:doc:type"); - value = Getattr(p, "tmap:doc:value"); + name = Getattr(p, "tmap:doc:name"); + type = Getattr(p, "tmap:doc:type"); + value = Getattr(p, "tmap:doc:value"); } // Note: the generated name should be consistent with that in kwnames[] @@ -471,28 +471,28 @@ public: value = value ? value : Getattr(p, "value"); if (SwigType_isvarargs(type)) - break; + break; String *tex_name = NewString(""); if (name) - Printf(tex_name, "@var{%s}", name); + Printf(tex_name, "@var{%s}", name); else - Printf(tex_name, "@var{?}"); + Printf(tex_name, "@var{?}"); if (Len(decl_str)) - Append(decl_str, ", "); + Append(decl_str, ", "); Append(decl_str, tex_name); if (value) { - String *new_value = convertValue(value, Getattr(p, "type")); - if (new_value) { - value = new_value; - } else { - Node *lookup = Swig_symbol_clookup(value, 0); - if (lookup) - value = Getattr(lookup, "sym:name"); - } - Printf(decl_str, " = %s", value); + String *new_value = convertValue(value, Getattr(p, "type")); + if (new_value) { + value = new_value; + } else { + Node *lookup = Swig_symbol_clookup(value, 0); + if (lookup) + value = Getattr(lookup, "sym:name"); + } + Printf(decl_str, " = %s", value); } Node *nn = classLookup(Getattr(p, "type")); @@ -517,18 +517,18 @@ public: if (v && Len(v) > 0) { char fc = (Char(v))[0]; if (('0' <= fc && fc <= '9') || '\'' == fc || '"' == fc) { - /* number or string (or maybe NULL pointer) */ - if (SwigType_ispointer(t) && Strcmp(v, "0") == 0) - return NewString("None"); - else - return v; + /* number or string (or maybe NULL pointer) */ + if (SwigType_ispointer(t) && Strcmp(v, "0") == 0) + return NewString("None"); + else + return v; } if (Strcmp(v, "NULL") == 0 || Strcmp(v, "nullptr") == 0) - return SwigType_ispointer(t) ? NewString("nil") : NewString("0"); + return SwigType_ispointer(t) ? NewString("nil") : NewString("0"); if (Strcmp(v, "true") == 0 || Strcmp(v, "TRUE") == 0) - return NewString("true"); + return NewString("true"); if (Strcmp(v, "false") == 0 || Strcmp(v, "FALSE") == 0) - return NewString("false"); + return NewString("false"); } return 0; } @@ -572,89 +572,89 @@ public: int varargs = emit_isvarargs(l); char source[64]; - Printf(f->code, "if (!SWIG_check_num_args(\"%s\",args.length(),%i,%i,%i)) " - "{\n SWIG_fail;\n }\n", iname, num_arguments, num_required, varargs); + Printf(f->code, "if (!SWIG_check_num_args(\"%s\",args.length(),%i,%i,%i)) " + "{\n SWIG_fail;\n }\n", iname, num_arguments, num_required, varargs); if (constructor && num_arguments == 1 && num_required == 1) { if (Cmp(storage, "explicit") == 0) { - Node *parent = Swig_methodclass(n); - if (GetFlag(parent, "feature:implicitconv")) { - String *desc = NewStringf("SWIGTYPE%s", SwigType_manglestr(Getattr(n, "type"))); - Printf(f->code, "if (SWIG_CheckImplicit(%s)) SWIG_fail;\n", desc); - Delete(desc); - } + Node *parent = Swig_methodclass(n); + if (GetFlag(parent, "feature:implicitconv")) { + String *desc = NewStringf("SWIGTYPE%s", SwigType_manglestr(Getattr(n, "type"))); + Printf(f->code, "if (SWIG_CheckImplicit(%s)) SWIG_fail;\n", desc); + Delete(desc); + } } } for (j = 0, p = l; j < num_arguments; ++j) { while (checkAttribute(p, "tmap:in:numinputs", "0")) { - p = Getattr(p, "tmap:in:next"); + p = Getattr(p, "tmap:in:next"); } SwigType *pt = Getattr(p, "type"); String *tm = Getattr(p, "tmap:in"); if (tm) { - if (!tm || checkAttribute(p, "tmap:in:numinputs", "0")) { - p = nextSibling(p); - continue; - } - - sprintf(source, "args(%d)", j); - Setattr(p, "emit:input", source); - - Replaceall(tm, "$source", Getattr(p, "emit:input")); - Replaceall(tm, "$input", Getattr(p, "emit:input")); - Replaceall(tm, "$target", Getattr(p, "lname")); - - if (Getattr(p, "wrap:disown") || (Getattr(p, "tmap:in:disown"))) { - Replaceall(tm, "$disown", "SWIG_POINTER_DISOWN"); - } else { - Replaceall(tm, "$disown", "0"); - } - - if (Getattr(p, "tmap:in:implicitconv")) { - const char *convflag = "0"; - if (!Getattr(p, "hidden")) { - SwigType *ptype = Getattr(p, "type"); - convflag = get_implicitconv_flag(classLookup(ptype)); - } - Replaceall(tm, "$implicitconv", convflag); - Setattr(p, "implicitconv", convflag); - } - - String *getargs = NewString(""); - if (j >= num_required) - Printf(getargs, "if (%dcode, getargs, "\n", NIL); - Delete(getargs); - - p = Getattr(p, "tmap:in:next"); - continue; + if (!tm || checkAttribute(p, "tmap:in:numinputs", "0")) { + p = nextSibling(p); + continue; + } + + sprintf(source, "args(%d)", j); + Setattr(p, "emit:input", source); + + Replaceall(tm, "$source", Getattr(p, "emit:input")); + Replaceall(tm, "$input", Getattr(p, "emit:input")); + Replaceall(tm, "$target", Getattr(p, "lname")); + + if (Getattr(p, "wrap:disown") || (Getattr(p, "tmap:in:disown"))) { + Replaceall(tm, "$disown", "SWIG_POINTER_DISOWN"); + } else { + Replaceall(tm, "$disown", "0"); + } + + if (Getattr(p, "tmap:in:implicitconv")) { + const char *convflag = "0"; + if (!Getattr(p, "hidden")) { + SwigType *ptype = Getattr(p, "type"); + convflag = get_implicitconv_flag(classLookup(ptype)); + } + Replaceall(tm, "$implicitconv", convflag); + Setattr(p, "implicitconv", convflag); + } + + String *getargs = NewString(""); + if (j >= num_required) + Printf(getargs, "if (%dcode, getargs, "\n", NIL); + Delete(getargs); + + p = Getattr(p, "tmap:in:next"); + continue; } else { - Swig_warning(WARN_TYPEMAP_IN_UNDEF, input_file, line_number, "Unable to use type %s as a function argument.\n", SwigType_str(pt, 0)); - break; + Swig_warning(WARN_TYPEMAP_IN_UNDEF, input_file, line_number, "Unable to use type %s as a function argument.\n", SwigType_str(pt, 0)); + break; } } // Check for trailing varargs if (varargs) { if (p && (tm = Getattr(p, "tmap:in"))) { - Replaceall(tm, "$input", "varargs"); - Printv(f->code, tm, "\n", NIL); + Replaceall(tm, "$input", "varargs"); + Printv(f->code, tm, "\n", NIL); } } // Insert constraint checking code for (p = l; p;) { if ((tm = Getattr(p, "tmap:check"))) { - Replaceall(tm, "$target", Getattr(p, "lname")); - Printv(f->code, tm, "\n", NIL); - p = Getattr(p, "tmap:check:next"); + Replaceall(tm, "$target", Getattr(p, "lname")); + Printv(f->code, tm, "\n", NIL); + p = Getattr(p, "tmap:check:next"); } else { - p = nextSibling(p); + p = nextSibling(p); } } @@ -662,23 +662,23 @@ public: String *cleanup = NewString(""); for (p = l; p;) { if ((tm = Getattr(p, "tmap:freearg"))) { - if (Getattr(p, "tmap:freearg:implicitconv")) { - const char *convflag = "0"; - if (!Getattr(p, "hidden")) { - SwigType *ptype = Getattr(p, "type"); - convflag = get_implicitconv_flag(classLookup(ptype)); - } - if (strcmp(convflag, "0") == 0) { - tm = 0; - } - } - if (tm && (Len(tm) != 0)) { - Replaceall(tm, "$source", Getattr(p, "lname")); - Printv(cleanup, tm, "\n", NIL); - } - p = Getattr(p, "tmap:freearg:next"); + if (Getattr(p, "tmap:freearg:implicitconv")) { + const char *convflag = "0"; + if (!Getattr(p, "hidden")) { + SwigType *ptype = Getattr(p, "type"); + convflag = get_implicitconv_flag(classLookup(ptype)); + } + if (strcmp(convflag, "0") == 0) { + tm = 0; + } + } + if (tm && (Len(tm) != 0)) { + Replaceall(tm, "$source", Getattr(p, "lname")); + Printv(cleanup, tm, "\n", NIL); + } + p = Getattr(p, "tmap:freearg:next"); } else { - p = nextSibling(p); + p = nextSibling(p); } } @@ -686,15 +686,15 @@ public: String *outarg = NewString(""); for (p = l; p;) { if ((tm = Getattr(p, "tmap:argout"))) { - Replaceall(tm, "$source", Getattr(p, "lname")); - Replaceall(tm, "$target", "_outp"); - Replaceall(tm, "$result", "_outp"); - Replaceall(tm, "$arg", Getattr(p, "emit:input")); - Replaceall(tm, "$input", Getattr(p, "emit:input")); - Printv(outarg, tm, "\n", NIL); - p = Getattr(p, "tmap:argout:next"); + Replaceall(tm, "$source", Getattr(p, "lname")); + Replaceall(tm, "$target", "_outp"); + Replaceall(tm, "$result", "_outp"); + Replaceall(tm, "$arg", Getattr(p, "emit:input")); + Replaceall(tm, "$input", Getattr(p, "emit:input")); + Printv(outarg, tm, "\n", NIL); + p = Getattr(p, "tmap:argout:next"); } else { - p = nextSibling(p); + p = nextSibling(p); } } @@ -720,9 +720,9 @@ public: Replaceall(tm, "$result", "_outv"); if (GetFlag(n, "feature:new")) - Replaceall(tm, "$owner", "1"); + Replaceall(tm, "$owner", "1"); else - Replaceall(tm, "$owner", "0"); + Replaceall(tm, "$owner", "0"); Printf(f->code, "%s\n", tm); Printf(f->code, "if (_outv.is_defined()) _outp = " "SWIG_Octave_AppendOutput(_outp, _outv);\n"); @@ -737,8 +737,8 @@ public: if (GetFlag(n, "feature:new")) { if ((tm = Swig_typemap_lookup("newfree", n, Swig_cresult_name(), 0))) { - Replaceall(tm, "$source", Swig_cresult_name()); - Printf(f->code, "%s\n", tm); + Replaceall(tm, "$source", Swig_cresult_name()); + Printf(f->code, "%s\n", tm); } } @@ -830,16 +830,16 @@ public: if (is_assignable(n)) { Setattr(n, "wrap:name", setname); if ((tm = Swig_typemap_lookup("varin", n, name, 0))) { - Replaceall(tm, "$source", "args(0)"); - Replaceall(tm, "$target", name); - Replaceall(tm, "$input", "args(0)"); - if (Getattr(n, "tmap:varin:implicitconv")) { - Replaceall(tm, "$implicitconv", get_implicitconv_flag(n)); - } - emit_action_code(n, setf->code, tm); - Delete(tm); + Replaceall(tm, "$source", "args(0)"); + Replaceall(tm, "$target", name); + Replaceall(tm, "$input", "args(0)"); + if (Getattr(n, "tmap:varin:implicitconv")) { + Replaceall(tm, "$implicitconv", get_implicitconv_flag(n)); + } + emit_action_code(n, setf->code, tm); + Delete(tm); } else { - Swig_warning(WARN_TYPEMAP_VARIN_UNDEF, input_file, line_number, "Unable to set variable of type %s.\n", SwigType_str(t, 0)); + Swig_warning(WARN_TYPEMAP_VARIN_UNDEF, input_file, line_number, "Unable to set variable of type %s.\n", SwigType_str(t, 0)); } Append(setf->code, "fail:\n"); Printf(setf->code, "return octave_value_list();\n"); @@ -995,18 +995,18 @@ public: int index = 0; b = First(baselist); while (b.item) { - String *bname = Getattr(b.item, "name"); - if ((!bname) || GetFlag(b.item, "feature:ignore") || (!Getattr(b.item, "module"))) { - b = Next(b); - continue; - } - - String *bname_mangled = SwigType_manglestr(SwigType_add_pointer(Copy(bname))); - Printf(base_class_names, "\"%s\",", bname_mangled); - Printf(base_class, "0,"); - b = Next(b); - index++; - Delete(bname_mangled); + String *bname = Getattr(b.item, "name"); + if ((!bname) || GetFlag(b.item, "feature:ignore") || (!Getattr(b.item, "module"))) { + b = Next(b); + continue; + } + + String *bname_mangled = SwigType_manglestr(SwigType_add_pointer(Copy(bname))); + Printf(base_class_names, "\"%s\",", bname_mangled); + Printf(base_class, "0,"); + b = Next(b); + index++; + Delete(bname_mangled); } } @@ -1063,8 +1063,8 @@ public: bool overloaded = !!Getattr(n, "sym:overloaded"); if (overloaded) Delslice(rname, Len(rname) - Len(Getattr(n, "sym:overname")), DOH_END); - Printf(s_members_tab, "{\"%s\",%s,0,0,0,%s},\n", - realname, rname, tname); + Printf(s_members_tab, "{\"%s\",%s,0,0,0,%s},\n", + realname, rname, tname); Delete(rname); Delete(tname); } @@ -1112,7 +1112,7 @@ public: Delete(name); Setattr(self, "lname", "self_obj"); if (parms) - set_nextSibling(self, parms); + set_nextSibling(self, parms); Setattr(n, "parms", self); Setattr(n, "wrap:self", "1"); Setattr(n, "hidden", "1"); @@ -1144,12 +1144,12 @@ public: bool overloaded = !!Getattr(n, "sym:overloaded"); if (overloaded) Delslice(rname, Len(rname) - Len(Getattr(n, "sym:overname")), DOH_END); - Printf(s_members_tab, "{\"%s\",%s,0,0,1,%s},\n", - realname, rname, tname); + Printf(s_members_tab, "{\"%s\",%s,0,0,1,%s},\n", + realname, rname, tname); Delete(rname); Delete(tname); } - + return SWIG_OK; } @@ -1217,24 +1217,24 @@ public: if (!Getattr(n, "defaultargs")) { // constructor { - Wrapper *w = NewWrapper(); - String *call; - String *basetype = Getattr(parent, "classtype"); - String *target = Swig_method_decl(0, decl, classname, parms, 0, 0); - call = Swig_csuperclass_call(0, basetype, superparms); - Printf(w->def, "%s::%s: %s," "\nSwig::Director(static_cast<%s*>(this)) { \n", classname, target, call, basetype); - Append(w->def, "}\n"); - Delete(target); - Wrapper_print(w, f_directors); - Delete(call); - DelWrapper(w); + Wrapper *w = NewWrapper(); + String *call; + String *basetype = Getattr(parent, "classtype"); + String *target = Swig_method_decl(0, decl, classname, parms, 0, 0); + call = Swig_csuperclass_call(0, basetype, superparms); + Printf(w->def, "%s::%s: %s," "\nSwig::Director(static_cast<%s*>(this)) { \n", classname, target, call, basetype); + Append(w->def, "}\n"); + Delete(target); + Wrapper_print(w, f_directors); + Delete(call); + DelWrapper(w); } // constructor header { - String *target = Swig_method_decl(0, decl, classname, parms, 0, 1); - Printf(f_directors_h, " %s;\n", target); - Delete(target); + String *target = Swig_method_decl(0, decl, classname, parms, 0, 1); + Printf(f_directors_h, " %s;\n", target); + Delete(target); } } @@ -1250,7 +1250,7 @@ public: { Wrapper *w = NewWrapper(); Printf(w->def, "SwigDirector_%s::SwigDirector_%s(void* self) :" - "\nSwig::Director((octave_swig_type*)self,static_cast<%s*>(this)) { \n", classname, classname, classname); + "\nSwig::Director((octave_swig_type*)self,static_cast<%s*>(this)) { \n", classname, classname, classname); Append(w->def, "}\n"); Wrapper_print(w, f_directors); DelWrapper(w); @@ -1283,7 +1283,7 @@ public: if (Cmp(storage, "virtual") == 0) { if (Cmp(value, "0") == 0) { - pure_virtual = true; + pure_virtual = true; } } @@ -1317,18 +1317,18 @@ public: Append(declaration, " throw("); if (throw_parm_list) - Swig_typemap_attach_parms("throws", throw_parm_list, 0); + Swig_typemap_attach_parms("throws", throw_parm_list, 0); for (p = throw_parm_list; p; p = nextSibling(p)) { - if (Getattr(p, "tmap:throws")) { - if (gencomma++) { - Append(w->def, ", "); - Append(declaration, ", "); - } - String *str = SwigType_str(Getattr(p, "type"), 0); - Append(w->def, str); - Append(declaration, str); - Delete(str); - } + if (Getattr(p, "tmap:throws")) { + if (gencomma++) { + Append(w->def, ", "); + Append(declaration, ", "); + } + String *str = SwigType_str(Getattr(p, "type"), 0); + Append(w->def, str); + Append(declaration, str); + Delete(str); + } } Append(w->def, ")"); @@ -1338,27 +1338,27 @@ public: Append(w->def, " {"); Append(declaration, ";\n"); - // declare method return value + // declare method return value // if the return value is a reference or const reference, a specialized typemap must // handle it, including declaration of c_result ($result). if (!is_void) { if (!(ignored_method && !pure_virtual)) { - String *cres = SwigType_lstr(returntype, "c_result"); - Printf(w->code, "%s;\n", cres); - Delete(cres); + String *cres = SwigType_lstr(returntype, "c_result"); + Printf(w->code, "%s;\n", cres); + Delete(cres); } } if (ignored_method) { if (!pure_virtual) { - if (!is_void) - Printf(w->code, "return "); - String *super_call = Swig_method_call(super, l); - Printf(w->code, "%s;\n", super_call); - Delete(super_call); + if (!is_void) + Printf(w->code, "return "); + String *super_call = Swig_method_call(super, l); + Printf(w->code, "%s;\n", super_call); + Delete(super_call); } else { - Printf(w->code, "Swig::DirectorPureVirtualException::raise(\"Attempted to invoke pure virtual method %s::%s\");\n", SwigType_namestr(c_classname), - SwigType_namestr(name)); + Printf(w->code, "Swig::DirectorPureVirtualException::raise(\"Attempted to invoke pure virtual method %s::%s\");\n", SwigType_namestr(c_classname), + SwigType_namestr(name)); } } else { // attach typemaps to arguments (C/C++ -> Python) @@ -1374,50 +1374,50 @@ public: int outputs = 0; if (!is_void) - outputs++; + outputs++; // build argument list and type conversion string p = l; while (p) { - if (checkAttribute(p, "tmap:in:numinputs", "0")) { - p = Getattr(p, "tmap:in:next"); - continue; - } - - if (Getattr(p, "tmap:directorargout") != 0) - outputs++; - - String *pname = Getattr(p, "name"); - String *ptype = Getattr(p, "type"); - Wrapper_add_local(w, "tmpv", "octave_value tmpv"); - - if ((tm = Getattr(p, "tmap:directorin")) != 0) { - String *parse = Getattr(p, "tmap:directorin:parse"); - if (!parse) { - Setattr(p, "emit:directorinput", "tmpv"); - Replaceall(tm, "$input", "tmpv"); - Replaceall(tm, "$owner", "0"); - Printv(wrap_args, tm, "\n", NIL); - Printf(wrap_args, "args.append(tmpv);\n"); - Putc('O', parse_args); - } else { - Append(parse_args, parse); - Setattr(p, "emit:directorinput", pname); - Replaceall(tm, "$input", pname); - Replaceall(tm, "$owner", "0"); - if (Len(tm) == 0) - Append(tm, pname); - } - p = Getattr(p, "tmap:directorin:next"); - continue; - } else if (Cmp(ptype, "void")) { - Swig_warning(WARN_TYPEMAP_DIRECTORIN_UNDEF, input_file, line_number, - "Unable to use type %s as a function argument in director method %s::%s (skipping method).\n", SwigType_str(ptype, 0), - SwigType_namestr(c_classname), SwigType_namestr(name)); - status = SWIG_NOWRAP; - break; - } - p = nextSibling(p); + if (checkAttribute(p, "tmap:in:numinputs", "0")) { + p = Getattr(p, "tmap:in:next"); + continue; + } + + if (Getattr(p, "tmap:directorargout") != 0) + outputs++; + + String *pname = Getattr(p, "name"); + String *ptype = Getattr(p, "type"); + Wrapper_add_local(w, "tmpv", "octave_value tmpv"); + + if ((tm = Getattr(p, "tmap:directorin")) != 0) { + String *parse = Getattr(p, "tmap:directorin:parse"); + if (!parse) { + Setattr(p, "emit:directorinput", "tmpv"); + Replaceall(tm, "$input", "tmpv"); + Replaceall(tm, "$owner", "0"); + Printv(wrap_args, tm, "\n", NIL); + Printf(wrap_args, "args.append(tmpv);\n"); + Putc('O', parse_args); + } else { + Append(parse_args, parse); + Setattr(p, "emit:directorinput", pname); + Replaceall(tm, "$input", pname); + Replaceall(tm, "$owner", "0"); + if (Len(tm) == 0) + Append(tm, pname); + } + p = Getattr(p, "tmap:directorin:next"); + continue; + } else if (Cmp(ptype, "void")) { + Swig_warning(WARN_TYPEMAP_DIRECTORIN_UNDEF, input_file, line_number, + "Unable to use type %s as a function argument in director method %s::%s (skipping method).\n", SwigType_str(ptype, 0), + SwigType_namestr(c_classname), SwigType_namestr(name)); + status = SWIG_NOWRAP; + break; + } + p = nextSibling(p); } String *method_name = Getattr(n, "sym:name"); @@ -1438,45 +1438,45 @@ public: // marshal return value if (!is_void) { - Printf(w->code, "if (out.length()<%d) {\n", outputs); - Printf(w->code, "Swig::DirectorTypeMismatchException::raise(\"Octave " - "method %s.%s failed to return the required number " "of arguments.\");\n", classname, method_name); - Printf(w->code, "}\n"); - - tm = Swig_typemap_lookup("directorout", n, Swig_cresult_name(), w); - if (tm != 0) { - char temp[24]; - sprintf(temp, "out(%d)", idx); - Replaceall(tm, "$input", temp); - // Replaceall(tm, "$argnum", temp); - Replaceall(tm, "$disown", Getattr(n, "wrap:disown") ? "SWIG_POINTER_DISOWN" : "0"); - if (Getattr(n, "tmap:directorout:implicitconv")) { - Replaceall(tm, "$implicitconv", get_implicitconv_flag(n)); - } - Replaceall(tm, "$result", "c_result"); - Printv(w->code, tm, "\n", NIL); - Delete(tm); - } else { - Swig_warning(WARN_TYPEMAP_DIRECTOROUT_UNDEF, input_file, line_number, - "Unable to use return type %s in director method %s::%s (skipping method).\n", - SwigType_str(returntype, 0), SwigType_namestr(c_classname), SwigType_namestr(name)); - status = SWIG_ERROR; - } + Printf(w->code, "if (out.length()<%d) {\n", outputs); + Printf(w->code, "Swig::DirectorTypeMismatchException::raise(\"Octave " + "method %s.%s failed to return the required number " "of arguments.\");\n", classname, method_name); + Printf(w->code, "}\n"); + + tm = Swig_typemap_lookup("directorout", n, Swig_cresult_name(), w); + if (tm != 0) { + char temp[24]; + sprintf(temp, "out(%d)", idx); + Replaceall(tm, "$input", temp); + // Replaceall(tm, "$argnum", temp); + Replaceall(tm, "$disown", Getattr(n, "wrap:disown") ? "SWIG_POINTER_DISOWN" : "0"); + if (Getattr(n, "tmap:directorout:implicitconv")) { + Replaceall(tm, "$implicitconv", get_implicitconv_flag(n)); + } + Replaceall(tm, "$result", "c_result"); + Printv(w->code, tm, "\n", NIL); + Delete(tm); + } else { + Swig_warning(WARN_TYPEMAP_DIRECTOROUT_UNDEF, input_file, line_number, + "Unable to use return type %s in director method %s::%s (skipping method).\n", + SwigType_str(returntype, 0), SwigType_namestr(c_classname), SwigType_namestr(name)); + status = SWIG_ERROR; + } } idx++; // marshal outputs for (p = l; p;) { - if ((tm = Getattr(p, "tmap:directorargout")) != 0) { - char temp[24]; - sprintf(temp, "out(%d)", idx); - Replaceall(tm, "$result", temp); - Replaceall(tm, "$input", Getattr(p, "emit:directorinput")); - Printv(w->code, tm, "\n", NIL); - p = Getattr(p, "tmap:directorargout:next"); - } else { - p = nextSibling(p); - } + if ((tm = Getattr(p, "tmap:directorargout")) != 0) { + char temp[24]; + sprintf(temp, "out(%d)", idx); + Replaceall(tm, "$result", temp); + Replaceall(tm, "$input", Getattr(p, "emit:directorinput")); + Printv(w->code, tm, "\n", NIL); + p = Getattr(p, "tmap:directorargout:next"); + } else { + p = nextSibling(p); + } } Delete(parse_args); @@ -1486,13 +1486,13 @@ public: if (!is_void) { if (!(ignored_method && !pure_virtual)) { - String *rettype = SwigType_str(returntype, 0); - if (!SwigType_isreference(returntype)) { - Printf(w->code, "return (%s) c_result;\n", rettype); - } else { - Printf(w->code, "return (%s) *c_result;\n", rettype); - } - Delete(rettype); + String *rettype = SwigType_str(returntype, 0); + if (!SwigType_isreference(returntype)) { + Printf(w->code, "return (%s) c_result;\n", rettype); + } else { + Printf(w->code, "return (%s) *c_result;\n", rettype); + } + Delete(rettype); } } @@ -1506,7 +1506,7 @@ public: Replaceall(inline_extra_method, name, extra_method_name); Replaceall(inline_extra_method, ";\n", " {\n "); if (!is_void) - Printf(inline_extra_method, "return "); + Printf(inline_extra_method, "return "); String *methodcall = Swig_method_call(super, l); Printv(inline_extra_method, methodcall, ";\n }\n", NIL); Delete(methodcall); @@ -1515,10 +1515,10 @@ public: // emit the director method if (status == SWIG_OK) { if (!Getattr(n, "defaultargs")) { - Replaceall(w->code, "$symname", symname); - Wrapper_print(w, f_directors); - Printv(f_directors_h, declaration, NIL); - Printv(f_directors_h, inline_extra_method, NIL); + Replaceall(w->code, "$symname", symname); + Wrapper_print(w, f_directors); + Printv(f_directors_h, declaration, NIL); + Printv(f_directors_h, inline_extra_method, NIL); } } // clean up -- cgit v1.2.1 From b2d492c15a0240d8954d3702a87f90eb34fd49fb Mon Sep 17 00:00:00 2001 From: Karl Wette Date: Mon, 26 May 2014 20:38:36 +0200 Subject: Octave: use common example.mk for examples, patterned after javascript --- Examples/octave/callback/Makefile | 18 ++---------------- Examples/octave/class/Makefile | 18 ++---------------- Examples/octave/constants/Makefile | 18 ++---------------- Examples/octave/contract/Makefile | 16 ++-------------- Examples/octave/enum/Makefile | 18 ++---------------- Examples/octave/example.mk | 32 ++++++++++++++++++++++++++++++++ Examples/octave/extend/Makefile | 18 ++---------------- Examples/octave/funcptr/Makefile | 16 ++-------------- Examples/octave/funcptr2/Makefile | 16 ++-------------- Examples/octave/functor/Makefile | 18 ++---------------- Examples/octave/module_load/Makefile | 23 ++++++----------------- Examples/octave/operator/Makefile | 18 ++---------------- Examples/octave/pointer/Makefile | 16 ++-------------- Examples/octave/reference/Makefile | 18 ++---------------- Examples/octave/simple/Makefile | 16 ++-------------- Examples/octave/template/Makefile | 18 ++---------------- Examples/octave/variables/Makefile | 16 ++-------------- 17 files changed, 68 insertions(+), 245 deletions(-) create mode 100644 Examples/octave/example.mk diff --git a/Examples/octave/callback/Makefile b/Examples/octave/callback/Makefile index 7855d0617..3b746de2f 100644 --- a/Examples/octave/callback/Makefile +++ b/Examples/octave/callback/Makefile @@ -1,17 +1,3 @@ -TOP = ../.. -SWIG = $(TOP)/../preinst-swig -CXXSRCS = example.cxx -TARGET = swigexample -INTERFACE = example.i -LIBS = -lm -SWIGOPT = +CXXSRCS = example.cxx -check: build - $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' octave_run - -build: - $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' $(SWIGLIB) CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ - SWIGOPT='$(SWIGOPT)' TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' octave_cpp - -clean: - $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' octave_clean +include $(SRCDIR)../example.mk diff --git a/Examples/octave/class/Makefile b/Examples/octave/class/Makefile index 7855d0617..3b746de2f 100644 --- a/Examples/octave/class/Makefile +++ b/Examples/octave/class/Makefile @@ -1,17 +1,3 @@ -TOP = ../.. -SWIG = $(TOP)/../preinst-swig -CXXSRCS = example.cxx -TARGET = swigexample -INTERFACE = example.i -LIBS = -lm -SWIGOPT = +CXXSRCS = example.cxx -check: build - $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' octave_run - -build: - $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' $(SWIGLIB) CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ - SWIGOPT='$(SWIGOPT)' TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' octave_cpp - -clean: - $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' octave_clean +include $(SRCDIR)../example.mk diff --git a/Examples/octave/constants/Makefile b/Examples/octave/constants/Makefile index eb05d1e7e..acf4d0575 100644 --- a/Examples/octave/constants/Makefile +++ b/Examples/octave/constants/Makefile @@ -1,17 +1,3 @@ -TOP = ../.. -SWIG = $(TOP)/../preinst-swig -CXXSRCS = -TARGET = swigexample -INTERFACE = example.i -LIBS = -lm -SWIGOPT = +CXXSRCS = -check: build - $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' octave_run - -build: - $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' $(SWIGLIB) CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ - SWIGOPT='$(SWIGOPT)' TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' octave_cpp - -clean: - $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' octave_clean +include $(SRCDIR)../example.mk diff --git a/Examples/octave/contract/Makefile b/Examples/octave/contract/Makefile index 2e0e82124..413b64bbd 100644 --- a/Examples/octave/contract/Makefile +++ b/Examples/octave/contract/Makefile @@ -1,15 +1,3 @@ -TOP = ../.. -SWIG = $(TOP)/../preinst-swig -SRCS = example.c -TARGET = swigexample -INTERFACE = example.i +SRCS = example.c -check: build - $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' octave_run - -build: - $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SRCS='$(SRCS)' SWIG='$(SWIG)' \ - TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' octave - -clean: - $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' octave_clean +include $(SRCDIR)../example.mk diff --git a/Examples/octave/enum/Makefile b/Examples/octave/enum/Makefile index 7855d0617..3b746de2f 100644 --- a/Examples/octave/enum/Makefile +++ b/Examples/octave/enum/Makefile @@ -1,17 +1,3 @@ -TOP = ../.. -SWIG = $(TOP)/../preinst-swig -CXXSRCS = example.cxx -TARGET = swigexample -INTERFACE = example.i -LIBS = -lm -SWIGOPT = +CXXSRCS = example.cxx -check: build - $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' octave_run - -build: - $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' $(SWIGLIB) CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ - SWIGOPT='$(SWIGOPT)' TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' octave_cpp - -clean: - $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' octave_clean +include $(SRCDIR)../example.mk diff --git a/Examples/octave/example.mk b/Examples/octave/example.mk new file mode 100644 index 000000000..e0b1e4efb --- /dev/null +++ b/Examples/octave/example.mk @@ -0,0 +1,32 @@ +# Note: as a convention an example must be in a child directory of this. +# These paths are relative to such an example directory + +TOP = ../.. +SWIG = $(TOP)/../preinst-swig +TARGET = swigexample +INTERFACE = example.i + +check: build + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' octave_run + +build: +ifneq (,$(SRCS)) + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SRCS='$(SRCS)' SWIG='$(SWIG)' \ + SWIGOPT='$(SWIGOPT)' TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' octave +else + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ + SWIGOPT='$(SWIGOPT)' TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' octave_cpp +endif +ifneq (,$(TARGET2)$(SWIGOPT2)) +ifneq (,$(SRCS)) + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SRCS='$(SRCS)' SWIG='$(SWIG)' \ + SWIGOPT='$(SWIGOPT2)' TARGET='$(TARGET2)' INTERFACE='$(INTERFACE)' octave +else + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ + SWIGOPT='$(SWIGOPT2)' TARGET='$(TARGET2)' INTERFACE='$(INTERFACE)' octave_cpp +endif +endif + + +clean: + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' octave_clean diff --git a/Examples/octave/extend/Makefile b/Examples/octave/extend/Makefile index 7855d0617..3b746de2f 100644 --- a/Examples/octave/extend/Makefile +++ b/Examples/octave/extend/Makefile @@ -1,17 +1,3 @@ -TOP = ../.. -SWIG = $(TOP)/../preinst-swig -CXXSRCS = example.cxx -TARGET = swigexample -INTERFACE = example.i -LIBS = -lm -SWIGOPT = +CXXSRCS = example.cxx -check: build - $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' octave_run - -build: - $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' $(SWIGLIB) CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ - SWIGOPT='$(SWIGOPT)' TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' octave_cpp - -clean: - $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' octave_clean +include $(SRCDIR)../example.mk diff --git a/Examples/octave/funcptr/Makefile b/Examples/octave/funcptr/Makefile index 2e0e82124..413b64bbd 100644 --- a/Examples/octave/funcptr/Makefile +++ b/Examples/octave/funcptr/Makefile @@ -1,15 +1,3 @@ -TOP = ../.. -SWIG = $(TOP)/../preinst-swig -SRCS = example.c -TARGET = swigexample -INTERFACE = example.i +SRCS = example.c -check: build - $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' octave_run - -build: - $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SRCS='$(SRCS)' SWIG='$(SWIG)' \ - TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' octave - -clean: - $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' octave_clean +include $(SRCDIR)../example.mk diff --git a/Examples/octave/funcptr2/Makefile b/Examples/octave/funcptr2/Makefile index 2e0e82124..413b64bbd 100644 --- a/Examples/octave/funcptr2/Makefile +++ b/Examples/octave/funcptr2/Makefile @@ -1,15 +1,3 @@ -TOP = ../.. -SWIG = $(TOP)/../preinst-swig -SRCS = example.c -TARGET = swigexample -INTERFACE = example.i +SRCS = example.c -check: build - $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' octave_run - -build: - $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SRCS='$(SRCS)' SWIG='$(SWIG)' \ - TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' octave - -clean: - $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' octave_clean +include $(SRCDIR)../example.mk diff --git a/Examples/octave/functor/Makefile b/Examples/octave/functor/Makefile index 0fbc7586b..acf4d0575 100644 --- a/Examples/octave/functor/Makefile +++ b/Examples/octave/functor/Makefile @@ -1,17 +1,3 @@ -TOP = ../.. -SWIG = $(TOP)/../preinst-swig -CXXSRCS = -TARGET = swigexample -INTERFACE = example.i -LIBS = -lm -SWIGOPT = +CXXSRCS = -check: build - $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' octave_run - -build: - $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ - SWIGOPT='$(SWIGOPT)' TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' octave_cpp - -clean: - $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' octave_clean +include $(SRCDIR)../example.mk diff --git a/Examples/octave/module_load/Makefile b/Examples/octave/module_load/Makefile index 7b24a8530..d2cd66e70 100644 --- a/Examples/octave/module_load/Makefile +++ b/Examples/octave/module_load/Makefile @@ -1,18 +1,7 @@ -TOP = ../.. -SWIG = $(TOP)/../preinst-swig -SRCS = example.c -TARGET = swigexample -INTERFACE = example.i +SRCS = example.c +TARGET = swigexample +SWIGOPT = -module swigexample +TARGET2 = swigexample2 +SWIGOPT2 = -module swigexample2 -globals . -check: build - $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' octave_run - -build: - $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SRCS='$(SRCS)' SWIG='$(SWIG)' \ - TARGET='$(TARGET)' SWIGOPT='-module $$(TARGET)' INTERFACE='$(INTERFACE)' octave - $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SRCS='$(SRCS)' SWIG='$(SWIG)' \ - TARGET='$(TARGET)2' SWIGOPT='-module $$(TARGET) -globals .' INTERFACE='$(INTERFACE)' octave - -clean: - $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' octave_clean - rm -f $(TARGET).m +include $(SRCDIR)../example.mk diff --git a/Examples/octave/operator/Makefile b/Examples/octave/operator/Makefile index 0fbc7586b..acf4d0575 100644 --- a/Examples/octave/operator/Makefile +++ b/Examples/octave/operator/Makefile @@ -1,17 +1,3 @@ -TOP = ../.. -SWIG = $(TOP)/../preinst-swig -CXXSRCS = -TARGET = swigexample -INTERFACE = example.i -LIBS = -lm -SWIGOPT = +CXXSRCS = -check: build - $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' octave_run - -build: - $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ - SWIGOPT='$(SWIGOPT)' TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' octave_cpp - -clean: - $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' octave_clean +include $(SRCDIR)../example.mk diff --git a/Examples/octave/pointer/Makefile b/Examples/octave/pointer/Makefile index 2e0e82124..413b64bbd 100644 --- a/Examples/octave/pointer/Makefile +++ b/Examples/octave/pointer/Makefile @@ -1,15 +1,3 @@ -TOP = ../.. -SWIG = $(TOP)/../preinst-swig -SRCS = example.c -TARGET = swigexample -INTERFACE = example.i +SRCS = example.c -check: build - $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' octave_run - -build: - $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SRCS='$(SRCS)' SWIG='$(SWIG)' \ - TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' octave - -clean: - $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' octave_clean +include $(SRCDIR)../example.mk diff --git a/Examples/octave/reference/Makefile b/Examples/octave/reference/Makefile index 7855d0617..3b746de2f 100644 --- a/Examples/octave/reference/Makefile +++ b/Examples/octave/reference/Makefile @@ -1,17 +1,3 @@ -TOP = ../.. -SWIG = $(TOP)/../preinst-swig -CXXSRCS = example.cxx -TARGET = swigexample -INTERFACE = example.i -LIBS = -lm -SWIGOPT = +CXXSRCS = example.cxx -check: build - $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' octave_run - -build: - $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' $(SWIGLIB) CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ - SWIGOPT='$(SWIGOPT)' TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' octave_cpp - -clean: - $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' octave_clean +include $(SRCDIR)../example.mk diff --git a/Examples/octave/simple/Makefile b/Examples/octave/simple/Makefile index 2e0e82124..413b64bbd 100644 --- a/Examples/octave/simple/Makefile +++ b/Examples/octave/simple/Makefile @@ -1,15 +1,3 @@ -TOP = ../.. -SWIG = $(TOP)/../preinst-swig -SRCS = example.c -TARGET = swigexample -INTERFACE = example.i +SRCS = example.c -check: build - $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' octave_run - -build: - $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SRCS='$(SRCS)' SWIG='$(SWIG)' \ - TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' octave - -clean: - $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' octave_clean +include $(SRCDIR)../example.mk diff --git a/Examples/octave/template/Makefile b/Examples/octave/template/Makefile index 0fbc7586b..acf4d0575 100644 --- a/Examples/octave/template/Makefile +++ b/Examples/octave/template/Makefile @@ -1,17 +1,3 @@ -TOP = ../.. -SWIG = $(TOP)/../preinst-swig -CXXSRCS = -TARGET = swigexample -INTERFACE = example.i -LIBS = -lm -SWIGOPT = +CXXSRCS = -check: build - $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' octave_run - -build: - $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ - SWIGOPT='$(SWIGOPT)' TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' octave_cpp - -clean: - $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' octave_clean +include $(SRCDIR)../example.mk diff --git a/Examples/octave/variables/Makefile b/Examples/octave/variables/Makefile index 2e0e82124..413b64bbd 100644 --- a/Examples/octave/variables/Makefile +++ b/Examples/octave/variables/Makefile @@ -1,15 +1,3 @@ -TOP = ../.. -SWIG = $(TOP)/../preinst-swig -SRCS = example.c -TARGET = swigexample -INTERFACE = example.i +SRCS = example.c -check: build - $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' octave_run - -build: - $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SRCS='$(SRCS)' SWIG='$(SWIG)' \ - TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' octave - -clean: - $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' octave_clean +include $(SRCDIR)../example.mk -- cgit v1.2.1 From ecf28da5a9c66904e57995cbd6cae35321ccece4 Mon Sep 17 00:00:00 2001 From: Karl Wette Date: Thu, 29 May 2014 23:42:22 +0200 Subject: Octave: remove deprecated -global/-noglobal command-line arguments --- CHANGES.current | 4 ++++ Source/Modules/octave.cxx | 7 ------- 2 files changed, 4 insertions(+), 7 deletions(-) diff --git a/CHANGES.current b/CHANGES.current index 8d715e730..8e106f4b1 100644 --- a/CHANGES.current +++ b/CHANGES.current @@ -5,3 +5,7 @@ See the RELEASENOTES file for a summary of changes in each release. Version 3.0.2 (in progress) =========================== +2014-04-24: kwwette + [Octave] Remove deprecated -global/-noglobal command-line arguments + + *** POTENTIAL INCOMPATIBILITY *** diff --git a/Source/Modules/octave.cxx b/Source/Modules/octave.cxx index 1c8b639bb..12903166c 100644 --- a/Source/Modules/octave.cxx +++ b/Source/Modules/octave.cxx @@ -94,13 +94,6 @@ public: if (argv[i]) { if (strcmp(argv[i], "-help") == 0) { fputs(usage, stdout); - } else if (strcmp(argv[i], "-global") == 0 || - strcmp(argv[i], "-noglobal") == 0) { - Printv(stderr, - "*** -global/-noglobal are no longer supported\n" - "*** global load behaviour is now determined at module load\n" - "*** see the Perl section in the manual for details.\n", NIL); - SWIG_exit(EXIT_FAILURE); } else if (strcmp(argv[i], "-globals") == 0) { if (argv[i + 1]) { global_name = NewString(argv[i + 1]); -- cgit v1.2.1 From 84e1b553c4544d1c9a847c993931c412748c8b51 Mon Sep 17 00:00:00 2001 From: Vladimir Kalinin Date: Sat, 31 May 2014 07:59:39 +0400 Subject: test fixed --- Examples/test-suite/nested_extend_c.i | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/Examples/test-suite/nested_extend_c.i b/Examples/test-suite/nested_extend_c.i index fb3c053c4..64727b9ea 100644 --- a/Examples/test-suite/nested_extend_c.i +++ b/Examples/test-suite/nested_extend_c.i @@ -10,7 +10,7 @@ char hi_extend() { return $self->c; } - static const long swig_size = sizeof(hiA); + static const long swig_size = sizeof(union hiA); } %extend lowA { lowA() { @@ -22,7 +22,7 @@ int low_extend() { return $self->num; } - static const long swig_size = sizeof(lowA); + static const long swig_size = sizeof(struct lowA); } %extend hiB { @@ -34,7 +34,7 @@ char hi_extend() { return $self->c; } - static const long swig_size = sizeof(hiB); + static const long swig_size = sizeof(union hiB); } %extend lowB { lowB() { @@ -46,7 +46,7 @@ int low_extend() { return $self->num; } - static const long swig_size = sizeof(lowB); + static const long swig_size = sizeof(struct lowB); } %extend FOO_bar { @@ -55,7 +55,7 @@ } }; %extend NestedA { - static const long swig_size = sizeof(NestedA); + static const long swig_size = sizeof(struct NestedA); } #endif -- cgit v1.2.1 From 22be94d2070376237a2099788786b0cf7f8ab521 Mon Sep 17 00:00:00 2001 From: William S Fulton Date: Sat, 31 May 2014 19:58:42 +0100 Subject: Fix std::vector compile problems on OSX for Javascript --- Lib/javascript/jsc/std_vector.i | 2 +- Lib/javascript/v8/std_vector.i | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/Lib/javascript/jsc/std_vector.i b/Lib/javascript/jsc/std_vector.i index 3f29b19c7..971b426a1 100644 --- a/Lib/javascript/jsc/std_vector.i +++ b/Lib/javascript/jsc/std_vector.i @@ -61,7 +61,7 @@ namespace std { %rename(add) push_back; void push_back(const value_type& x); %extend { - const_reference get(int i) throw (std::out_of_range) { + bool get(int i) throw (std::out_of_range) { int size = int(self->size()); if (i>=0 && isize()); if (i>=0 && i Date: Sun, 1 Jun 2014 15:29:47 +0200 Subject: Fix bug in DohNewStringWithSize(): guarantee string is nul-terminated --- Source/DOH/string.c | 1 + 1 file changed, 1 insertion(+) diff --git a/Source/DOH/string.c b/Source/DOH/string.c index 50676c7c3..3e02e05d1 100644 --- a/Source/DOH/string.c +++ b/Source/DOH/string.c @@ -1114,6 +1114,7 @@ DOHString *DohNewStringWithSize(const DOHString_or_char *so, int len) { str->maxsize = max; if (s) { strncpy(str->str, s, len); + str->str[l] = 0; str->len = l; str->sp = l; } else { -- cgit v1.2.1 From 5f3ee109c8dd49fe7c6021c595a4afd648a129e6 Mon Sep 17 00:00:00 2001 From: William S Fulton Date: Mon, 2 Jun 2014 07:09:35 +0100 Subject: Add runtime test for %extend and nested union --- Examples/test-suite/java/nested_extend_c_runme.java | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/Examples/test-suite/java/nested_extend_c_runme.java b/Examples/test-suite/java/nested_extend_c_runme.java index 9da093a09..5d9d861da 100644 --- a/Examples/test-suite/java/nested_extend_c_runme.java +++ b/Examples/test-suite/java/nested_extend_c_runme.java @@ -34,5 +34,12 @@ public class nested_extend_c_runme { if (low.low_extend() != 99) throw new RuntimeException("test failed"); } + { + FOO_bar foobar = new FOO_bar(); + foobar.setD(1234); + if (foobar.getD() != 1234) + throw new RuntimeException("test failed"); + foobar.bar_extend(); + } } } -- cgit v1.2.1 From 6d5444e58709a9d17a6f3a8bc47b80ce8ef28704 Mon Sep 17 00:00:00 2001 From: William S Fulton Date: Mon, 2 Jun 2014 07:23:14 +0100 Subject: CHANGES update --- CHANGES.current | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/CHANGES.current b/CHANGES.current index 8e106f4b1..73c028efd 100644 --- a/CHANGES.current +++ b/CHANGES.current @@ -5,7 +5,10 @@ See the RELEASENOTES file for a summary of changes in each release. Version 3.0.2 (in progress) =========================== -2014-04-24: kwwette +2014-06-02: vkalinin + Fix #183 - %extend and unnamed nested structs + +2014-05-24: kwwette [Octave] Remove deprecated -global/-noglobal command-line arguments *** POTENTIAL INCOMPATIBILITY *** -- cgit v1.2.1 From acd0ebc6605d42cfb931fe46a0aaab06e29fb847 Mon Sep 17 00:00:00 2001 From: William S Fulton Date: Mon, 2 Jun 2014 07:36:00 +0100 Subject: changes file updates --- CHANGES.current | 10 ++++++++++ README | 2 +- 2 files changed, 11 insertions(+), 1 deletion(-) diff --git a/CHANGES.current b/CHANGES.current index 73c028efd..74730a89f 100644 --- a/CHANGES.current +++ b/CHANGES.current @@ -5,9 +5,19 @@ See the RELEASENOTES file for a summary of changes in each release. Version 3.0.2 (in progress) =========================== +2014-06-02: v-for-vandal + [Lua] Pull request #176: + If class has no __eq implemented, then default __eq is generated. + Default __eq compares actual pointers stored inside Lua userdata. + + 2014-06-02: vkalinin Fix #183 - %extend and unnamed nested structs +2014-05-28: kwwette + Fix install failure when using an 'out of source' build using the shipped + tarball - regression introduced in swig-3.0.1. + 2014-05-24: kwwette [Octave] Remove deprecated -global/-noglobal command-line arguments diff --git a/README b/README index e4010bd80..6cc847553 100644 --- a/README +++ b/README @@ -1,6 +1,6 @@ SWIG (Simplified Wrapper and Interface Generator) -Version: 3.0.2 (27 May 2014) +Version: 3.0.2 (in progress) Tagline: SWIG is a compiler that integrates C and C++ with languages including Perl, Python, Tcl, Ruby, PHP, Java, C#, D, Go, Lua, -- cgit v1.2.1 From 37c09b01040d55eb9936a214c031e032c7bf80eb Mon Sep 17 00:00:00 2001 From: William S Fulton Date: Wed, 4 Jun 2014 08:48:04 +0100 Subject: Add 3.0.2 release date --- ANNOUNCE | 2 +- CHANGES.current | 3 +-- Doc/Manual/Sections.html | 2 +- README | 2 +- RELEASENOTES | 3 +++ 5 files changed, 7 insertions(+), 5 deletions(-) diff --git a/ANNOUNCE b/ANNOUNCE index fc1160007..58de2fe10 100644 --- a/ANNOUNCE +++ b/ANNOUNCE @@ -1,4 +1,4 @@ -*** ANNOUNCE: SWIG 3.0.2 (in progress) *** +*** ANNOUNCE: SWIG 3.0.2 (4 Jun 2014) *** http://www.swig.org diff --git a/CHANGES.current b/CHANGES.current index 74730a89f..bb8bbdc41 100644 --- a/CHANGES.current +++ b/CHANGES.current @@ -2,7 +2,7 @@ Below are the changes for the current release. See the CHANGES file for changes in older releases. See the RELEASENOTES file for a summary of changes in each release. -Version 3.0.2 (in progress) +Version 3.0.2 (4 Jun 2014) =========================== 2014-06-02: v-for-vandal @@ -10,7 +10,6 @@ Version 3.0.2 (in progress) If class has no __eq implemented, then default __eq is generated. Default __eq compares actual pointers stored inside Lua userdata. - 2014-06-02: vkalinin Fix #183 - %extend and unnamed nested structs diff --git a/Doc/Manual/Sections.html b/Doc/Manual/Sections.html index 33d76c239..bcae8139d 100644 --- a/Doc/Manual/Sections.html +++ b/Doc/Manual/Sections.html @@ -6,7 +6,7 @@

      SWIG-3.0 Documentation

      -Last update : SWIG-3.0.2 (in progress) +Last update : SWIG-3.0.2 (4 Jun 2014)

      Sections

      diff --git a/README b/README index 6cc847553..746bad7e1 100644 --- a/README +++ b/README @@ -1,6 +1,6 @@ SWIG (Simplified Wrapper and Interface Generator) -Version: 3.0.2 (in progress) +Version: 3.0.2 (4 Jun 2014) Tagline: SWIG is a compiler that integrates C and C++ with languages including Perl, Python, Tcl, Ruby, PHP, Java, C#, D, Go, Lua, diff --git a/RELEASENOTES b/RELEASENOTES index 542ff4b10..38fbe60e7 100644 --- a/RELEASENOTES +++ b/RELEASENOTES @@ -4,6 +4,9 @@ and CHANGES files. Release Notes ============= +SWIG-3.0.2 summary: +- Bug fix during install and a couple of other minor changes. + SWIG-3.0.1 summary: - Javascript module added. This supports JavascriptCore (Safari/Webkit), v8 (Chromium) and node.js currently. -- cgit v1.2.1 From 1949e2cc63abc3d8a361f37d2083774badd04bff Mon Sep 17 00:00:00 2001 From: William S Fulton Date: Wed, 4 Jun 2014 12:21:09 +0100 Subject: Fix equality testcase --- Examples/test-suite/equality.i | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/Examples/test-suite/equality.i b/Examples/test-suite/equality.i index a1b70c299..cdabc4892 100644 --- a/Examples/test-suite/equality.i +++ b/Examples/test-suite/equality.i @@ -6,6 +6,8 @@ %module equality +%warnfilter(SWIGWARN_LANG_IDENTIFIER) operator==; + %inline %{ /* Point has no equality operator */ @@ -40,7 +42,7 @@ public: inline static const EqualOpWrong* GetStaticObject(); }; -static const EqualOpWrong s_wrongEqOp; +static EqualOpWrong s_wrongEqOp; const EqualOpWrong* EqualOpWrong::GetStaticObject() { return &s_wrongEqOp; } -- cgit v1.2.1 From ef4cb2f57465025203961a484fd8f7a0a8c9faa7 Mon Sep 17 00:00:00 2001 From: William S Fulton Date: Wed, 4 Jun 2014 13:00:18 +0100 Subject: Fix example clean target in makefile for operating systems that don't use .so as shared library extension --- Examples/Makefile.in | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) diff --git a/Examples/Makefile.in b/Examples/Makefile.in index 521df3a70..50b7ead03 100644 --- a/Examples/Makefile.in +++ b/Examples/Makefile.in @@ -204,7 +204,7 @@ tcl_version: tcl_clean: rm -f *_wrap* *~ .~* mytclsh@EXEEXT@ rm -f core @EXTRA_CLEAN@ - rm -f *.@OBJEXT@ *@SO@ + rm -f *.@OBJEXT@ *$(TCL_SO) ################################################################## ##### PERL 5 ###### @@ -399,7 +399,7 @@ python_clean: rm -rf __pycache__ rm -f *_wrap* *~ .~* mypython@EXEEXT@ *.pyc rm -f core @EXTRA_CLEAN@ - rm -f *.@OBJEXT@ *@SO@ *@PYTHON_SO@ + rm -f *.@OBJEXT@ *@SO@ *$(PYTHON_SO) rm -f $(TARGET).py if test -f $(SRCDIR)$(RUNME).py; then rm -f $(RUNME)3.py $(RUNME)3.py.bak; fi case "x$(SRCDIR)" in x|x./);; *) rm -f $(RUNME).py;; esac @@ -461,7 +461,7 @@ octave_clean: rm -rf __pycache__ rm -f *_wrap* *~ .~* myoctave@EXEEXT@ *.pyc rm -f core @EXTRA_CLEAN@ - rm -f *.@OBJEXT@ *@SO@ *@OCTAVE_SO@ + rm -f *.@OBJEXT@ *@SO@ *$(OCTAVE_SO) ################################################################## ##### GUILE ###### @@ -551,7 +551,7 @@ guile_version: guile_clean: rm -f *_wrap* *~ .~* my-guile@EXEEXT@ $(TARGET)@EXEEXT@ rm -f core @EXTRA_CLEAN@ - rm -f *.@OBJEXT@ *@GUILE_SO@ + rm -f *.@OBJEXT@ *$(GUILE_SO) ################################################################## ##### JAVA ###### @@ -874,7 +874,7 @@ mzscheme_version: mzscheme_clean: rm -f *_wrap* *~ .~* rm -f core @EXTRA_CLEAN@ - rm -f *.@OBJEXT@ *@SO@ + rm -f *.@OBJEXT@ *$(MZSCHEME_SO) ################################################################## ##### Ocaml ##### @@ -1097,7 +1097,7 @@ ruby_version: ruby_clean: rm -f *_wrap* *~ .~* myruby@EXEEXT@ *.pm rm -f core @EXTRA_CLEAN@ - rm -f *.@OBJEXT@ *@SO@ + rm -f *.@OBJEXT@ *$(RUBY_SO) ################################################################## ##### PHP ###### @@ -1147,7 +1147,7 @@ php_version: php_clean: rm -f *_wrap* *~ .~* example.php php_example.h rm -f core @EXTRA_CLEAN@ - rm -f *.@OBJEXT@ *@SO@ + rm -f *.@OBJEXT@ *$(PHP_SO) ################################################################## ##### Pike ###### @@ -1480,7 +1480,7 @@ lua_version: lua_clean: rm -f *_wrap* *~ .~* mylua@EXEEXT@ rm -f core @EXTRA_CLEAN@ - rm -f *.@OBJEXT@ *@SO@ + rm -f *.@OBJEXT@ *$(LUA_SO) ################################################################## ##### ALLEGRO CL ###### -- cgit v1.2.1 From 8339a2d441772e8d4d7dd6d4e00d2eccf9cb8cbe Mon Sep 17 00:00:00 2001 From: Jason Turner Date: Wed, 4 Jun 2014 14:11:18 -0600 Subject: Fix shared data problem on MacOS 10.9 with xcode 5.1 Move to construct on first use idiom for singleton definition, which prevents problems with singletons between ruby swig modules in an environment with multiple modules on MacOS 10.9 with xcode 5.1. Before this fix, data was being shared between modules which caused a crash on shutdown of the ruby interpreter if more than one module was loaded at a time. --- Lib/ruby/rubyclasses.swg | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) diff --git a/Lib/ruby/rubyclasses.swg b/Lib/ruby/rubyclasses.swg index 5537136af..f7b51bdcc 100644 --- a/Lib/ruby/rubyclasses.swg +++ b/Lib/ruby/rubyclasses.swg @@ -37,9 +37,6 @@ %fragment("GC_VALUE_definition","header") { namespace swig { class SwigGCReferences { - // Hash of all GC_VALUE's currently in use - static SwigGCReferences s_references; - VALUE _hash; SwigGCReferences() : _hash(Qnil) { @@ -50,13 +47,18 @@ namespace swig { } static void EndProcHandler(VALUE) { // Ruby interpreter ending - _hash can no longer be accessed. + SwigGCReferences &s_references = instance(); s_references._hash = Qnil; } public: static SwigGCReferences& instance() { + // Hash of all GC_VALUE's currently in use + static SwigGCReferences s_references; + return s_references; } static void initialize() { + SwigGCReferences &s_references = instance(); if (s_references._hash == Qnil) { rb_set_end_proc(&EndProcHandler, Qnil); s_references._hash = rb_hash_new(); @@ -81,13 +83,13 @@ namespace swig { if (BUILTIN_TYPE(obj) == T_NONE) return; if (_hash != Qnil) { - VALUE val = rb_hash_aref(s_references._hash, obj); + VALUE val = rb_hash_aref(_hash, obj); unsigned n = FIXNUM_P(val) ? NUM2UINT(val) : 1; --n; if (n) - rb_hash_aset(s_references._hash, obj, INT2NUM(n)); + rb_hash_aset(_hash, obj, INT2NUM(n)); else - rb_hash_delete(s_references._hash, obj); + rb_hash_delete(_hash, obj); } } }; @@ -302,8 +304,6 @@ namespace swig { ID GC_VALUE::lshift_id = rb_intern("<<"); ID GC_VALUE::rshift_id = rb_intern(">>"); - SwigGCReferences SwigGCReferences::s_references; - typedef GC_VALUE LANGUAGE_OBJ; } // namespace swig -- cgit v1.2.1 From e0c432f70d38bdcc5828ed1c97e03a4475d42823 Mon Sep 17 00:00:00 2001 From: Julien Schueller Date: Thu, 5 Jun 2014 16:51:23 +0200 Subject: Use 4 spaces in emitFunctionShadowHelper for python --- Source/Modules/python.cxx | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/Source/Modules/python.cxx b/Source/Modules/python.cxx index 06c1c4868..95dcbe09e 100644 --- a/Source/Modules/python.cxx +++ b/Source/Modules/python.cxx @@ -2029,15 +2029,15 @@ public: /* Make a wrapper function to insert the code into */ Printv(f_dest, "\ndef ", name, "(", parms, ")", returnTypeAnnotation(n), ":\n", NIL); if (have_docstring(n)) - Printv(f_dest, " ", docstring(n, AUTODOC_FUNC, tab4), "\n", NIL); + Printv(f_dest, tab4, docstring(n, AUTODOC_FUNC, tab4), "\n", NIL); if (have_pythonprepend(n)) - Printv(f_dest, pythoncode(pythonprepend(n), " "), "\n", NIL); + Printv(f_dest, pythoncode(pythonprepend(n), tab4), "\n", NIL); if (have_pythonappend(n)) { - Printv(f_dest, " val = ", funcCall(name, callParms), "\n", NIL); - Printv(f_dest, pythoncode(pythonappend(n), " "), "\n", NIL); - Printv(f_dest, " return val\n", NIL); + Printv(f_dest, tab4 "val = ", funcCall(name, callParms), "\n", NIL); + Printv(f_dest, pythoncode(pythonappend(n), tab4), "\n", NIL); + Printv(f_dest, tab4 "return val\n", NIL); } else { - Printv(f_dest, " return ", funcCall(name, callParms), "\n", NIL); + Printv(f_dest, tab4 "return ", funcCall(name, callParms), "\n", NIL); } if (Getattr(n, "feature:python:callback") || !have_addtofunc(n)) { -- cgit v1.2.1 From 0d589349a19aded355e2e1489e63c5b6ee126da5 Mon Sep 17 00:00:00 2001 From: Julien Schueller Date: Fri, 6 Jun 2014 11:03:46 +0200 Subject: Fixed pep8 issues E701, E203, E231, E261 --- Lib/python/pyiterators.swg | 3 ++- Source/Modules/python.cxx | 67 +++++++++++++++++++++++----------------------- 2 files changed, 35 insertions(+), 35 deletions(-) diff --git a/Lib/python/pyiterators.swg b/Lib/python/pyiterators.swg index f93594c4c..110c431fe 100644 --- a/Lib/python/pyiterators.swg +++ b/Lib/python/pyiterators.swg @@ -344,7 +344,8 @@ namespace swig %feature("python:slot", "tp_iternext", functype="iternextfunc") SwigPyIterator::__next__; #else %extend SwigPyIterator { - %pythoncode {def __iter__(self): return self} + %pythoncode {def __iter__(self): + return self} } #endif diff --git a/Source/Modules/python.cxx b/Source/Modules/python.cxx index 95dcbe09e..bd3cc0779 100644 --- a/Source/Modules/python.cxx +++ b/Source/Modules/python.cxx @@ -807,7 +807,7 @@ public: Printv(f_shadow, "\nfrom sys import version_info\n", NULL); if (!builtin && fastproxy) { - Printv(f_shadow, "if version_info >= (3,0,0):\n", NULL); + Printv(f_shadow, "if version_info >= (3, 0, 0):\n", NULL); Printf(f_shadow, tab4 "new_instancemethod = lambda func, inst, cls: %s.SWIG_PyInstanceMethod_New(func)\n", module); Printv(f_shadow, "else:\n", NULL); Printv(f_shadow, tab4, "from new import instancemethod as new_instancemethod\n", NULL); @@ -822,7 +822,7 @@ public: * isn't available in python 2.4 or earlier, so we have to write some * code conditional on the python version. */ - Printv(f_shadow, "if version_info >= (2,6,0):\n", NULL); + Printv(f_shadow, "if version_info >= (2, 6, 0):\n", NULL); Printv(f_shadow, tab4, "def swig_import_helper():\n", NULL); Printv(f_shadow, tab8, "from os.path import dirname\n", NULL); Printv(f_shadow, tab8, "import imp\n", NULL); @@ -852,20 +852,20 @@ public: Printf(f_shadow, "from %s import *\n", module); } if (modern || !classic) { - Printv(f_shadow, "try:\n", tab4, "_swig_property = property\n", "except NameError:\n", tab4, "pass # Python < 2.2 doesn't have 'property'.\n", NULL); + Printv(f_shadow, "try:\n", tab4, "_swig_property = property\n", "except NameError:\n", tab4, "pass # Python < 2.2 doesn't have 'property'.\n", NULL); } /* if (!modern) */ /* always needed, a class can be forced to be no-modern, such as an exception */ { // Python-2.2 object hack Printv(f_shadow, - "def _swig_setattr_nondynamic(self,class_type,name,value,static=1):\n", - tab4, "if (name == \"thisown\"): return self.this.own(value)\n", + "def _swig_setattr_nondynamic(self, class_type, name, value, static=1):\n", + tab4, "if (name == \"thisown\"):\n", tab4, tab4, "return self.this.own(value)\n", tab4, "if (name == \"this\"):\n", tab4, tab4, "if type(value).__name__ == 'SwigPyObject':\n", tab4, tab8, "self.__dict__[name] = value\n", #ifdef USE_THISOWN tab4, tab8, "if hasattr(value,\"thisown\"): self.__dict__[\"thisown\"] = value.thisown\n", tab4, tab8, "del value.thisown\n", #endif - tab4, tab8, "return\n", tab4, "method = class_type.__swig_setmethods__.get(name,None)\n", tab4, "if method: return method(self,value)\n", + tab4, tab8, "return\n", tab4, "method = class_type.__swig_setmethods__.get(name, None)\n", tab4, "if method:\n", tab4, tab4, "return method(self, value)\n", #ifdef USE_THISOWN tab4, "if (not static) or (name == \"thisown\"):\n", #else @@ -874,18 +874,18 @@ public: tab4, tab4, "self.__dict__[name] = value\n", tab4, "else:\n", tab4, tab4, "raise AttributeError(\"You cannot add attributes to %s\" % self)\n\n", - "def _swig_setattr(self,class_type,name,value):\n", tab4, "return _swig_setattr_nondynamic(self,class_type,name,value,0)\n\n", NIL); + "def _swig_setattr(self, class_type, name, value):\n", tab4, "return _swig_setattr_nondynamic(self, class_type, name, value, 0)\n\n", NIL); Printv(f_shadow, - "def _swig_getattr(self,class_type,name):\n", - tab4, "if (name == \"thisown\"): return self.this.own()\n", - tab4, "method = class_type.__swig_getmethods__.get(name,None)\n", - tab4, "if method: return method(self)\n", tab4, "raise AttributeError(name)\n\n", NIL); + "def _swig_getattr(self, class_type, name):\n", + tab4, "if (name == \"thisown\"):\n", tab4, tab4, "return self.this.own()\n", + tab4, "method = class_type.__swig_getmethods__.get(name, None)\n", + tab4, "if method:\n", tab4, tab4, "return method(self)\n", tab4, "raise AttributeError(name)\n\n", NIL); Printv(f_shadow, "def _swig_repr(self):\n", - tab4, "try: strthis = \"proxy of \" + self.this.__repr__()\n", - tab4, "except: strthis = \"\"\n", tab4, "return \"<%s.%s; %s >\" % (self.__class__.__module__, self.__class__.__name__, strthis,)\n\n", NIL); + tab4, "try:\n", tab4, tab4, "strthis = \"proxy of \" + self.this.__repr__()\n", + tab4, "except:\n", tab4, tab4, "strthis = \"\"\n", tab4, "return \"<%s.%s; %s >\" % (self.__class__.__module__, self.__class__.__name__, strthis,)\n\n", NIL); if (!classic) { /* Usage of types.ObjectType is deprecated. @@ -895,19 +895,19 @@ public: // "import types\n", "try:\n", // " _object = types.ObjectType\n", - " _object = object\n", " _newclass = 1\n", "except AttributeError:\n", " class _object : pass\n", " _newclass = 0\n", + tab4, "_object = object\n", tab4, "_newclass = 1\n", "except AttributeError:\n", tab4, "class _object:\n", tab4, tab4, "pass\n", tab4, "_newclass = 0\n", // "del types\n", "\n\n", NIL); } } if (modern) { - Printv(f_shadow, "def _swig_setattr_nondynamic_method(set):\n", tab4, "def set_attr(self,name,value):\n", + Printv(f_shadow, "def _swig_setattr_nondynamic_method(set):\n", tab4, "def set_attr(self, name, value):\n", #ifdef USE_THISOWN - tab4, tab4, "if hasattr(self,name) or (name in (\"this\", \"thisown\")):\n", + tab4, tab4, "if hasattr(self, name) or (name in (\"this\", \"thisown\")):\n", #else - tab4, tab4, "if (name == \"thisown\"): return self.this.own(value)\n", tab4, tab4, "if hasattr(self,name) or (name == \"this\"):\n", + tab4, tab4, "if (name == \"thisown\"): return self.this.own(value)\n", tab4, tab4, "if hasattr(self, name) or (name == \"this\"):\n", #endif - tab4, tab4, tab4, "set(self,name,value)\n", + tab4, tab4, tab4, "set(self, name, value)\n", tab4, tab4, "else:\n", tab4, tab4, tab4, "raise AttributeError(\"You cannot add attributes to %s\" % self)\n", tab4, "return set_attr\n\n\n", NIL); } @@ -2154,7 +2154,7 @@ public: Append(f->code, "--argc;\n"); } - Replaceall(dispatch, "$args", "self,args"); + Replaceall(dispatch, "$args", "self, args"); Printv(f->code, dispatch, "\n", NIL); @@ -3957,7 +3957,7 @@ public: if (!modern) { Printv(f_shadow, tab4, "__swig_setmethods__ = {}\n", NIL); if (Len(base_class)) { - Printf(f_shadow, "%sfor _s in [%s]: __swig_setmethods__.update(getattr(_s,'__swig_setmethods__',{}))\n", tab4, base_class); + Printv(f_shadow, tab4, "for _s in [", base_class, "]:\n", tab8, "__swig_setmethods__.update(getattr(_s, '__swig_setmethods__', {}))\n", NIL); } if (!GetFlag(n, "feature:python:nondynamic")) { @@ -3968,7 +3968,7 @@ public: Printv(f_shadow, tab4, "__swig_getmethods__ = {}\n", NIL); if (Len(base_class)) { - Printf(f_shadow, "%sfor _s in [%s]: __swig_getmethods__.update(getattr(_s,'__swig_getmethods__',{}))\n", tab4, base_class); + Printv(f_shadow, tab4, "for _s in [", base_class, "]:\n", tab8, "__swig_getmethods__.update(getattr(_s, '__swig_getmethods__', {}))\n", NIL); } Printv(f_shadow, tab4, "__getattr__ = lambda self, name: _swig_getattr(self, ", class_name, ", name)\n", NIL); @@ -4056,7 +4056,7 @@ public: Delete(realct); if (!have_constructor) { if (!builtin) - Printv(f_shadow_file, tab4, "def __init__(self, *args, **kwargs): raise AttributeError(\"", "No constructor defined", + Printv(f_shadow_file, tab4, "def __init__(self, *args, **kwargs):\n", tab8, "raise AttributeError(\"", "No constructor defined", (Getattr(n, "abstracts") ? " - class is abstract" : ""), "\")\n", NIL); } else if (fastinit && !builtin) { @@ -4094,12 +4094,12 @@ public: Printv(f_shadow_file, "\nclass ", class_name, "Ptr(", class_name, "):\n", tab4, "def __init__(self, this):\n", NIL); if (!modern) { Printv(f_shadow_file, - tab8, "try: self.this.append(this)\n", - tab8, "except: self.this = this\n", tab8, "self.this.own(0)\n", tab8, "self.__class__ = ", class_name, "\n\n", NIL); + tab8, "try:\n", tab8, tab4, "self.this.append(this)\n", + tab8, "except:\n", tab8, tab4, "self.this = this\n", tab8, "self.this.own(0)\n", tab8, "self.__class__ = ", class_name, "\n\n", NIL); } else { Printv(f_shadow_file, - tab8, "try: self.this.append(this)\n", - tab8, "except: self.this = this\n", tab8, "self.this.own(0)\n", tab8, "self.__class__ = ", class_name, "\n\n", NIL); + tab8, "try:\n", tab8, tab4, "self.this.append(this)\n", + tab8, "except:\n", tab8, tab4, "self.this = this\n", tab8, "self.this.own(0)\n", tab8, "self.__class__ = ", class_name, "\n\n", NIL); } } @@ -4223,12 +4223,11 @@ public: String *callParms = make_pyParmList(n, true, true, allow_kwargs); if (!have_addtofunc(n)) { if (!fastproxy || olddefs) { - Printv(f_shadow, tab4, "def ", symname, "(", parms, ")", returnTypeAnnotation(n), ":", NIL); - Printv(f_shadow, " return ", funcCall(fullname, callParms), "\n", NIL); + Printv(f_shadow, tab4, "def ", symname, "(", parms, ")", returnTypeAnnotation(n), ":\n", NIL); + Printv(f_shadow, tab8, "return ", funcCall(fullname, callParms), "\n", NIL); } } else { - Printv(f_shadow, tab4, "def ", symname, "(", parms, ")", returnTypeAnnotation(n), ":", NIL); - Printv(f_shadow, "\n", NIL); + Printv(f_shadow, tab4, "def ", symname, "(", parms, ")", returnTypeAnnotation(n), ":\n", NIL); if (have_docstring(n)) Printv(f_shadow, tab8, docstring(n, AUTODOC_METHOD, tab8), "\n", NIL); if (have_pythonprepend(n)) { @@ -4427,7 +4426,7 @@ public: Printv(pass_self, tab8, tab4, "_self = None\n", tab8, "else:\n", tab8, tab4, "_self = self\n", NIL); } - Printv(f_shadow, tab4, "def __init__(", parms, ")", returnTypeAnnotation(n), ": \n", NIL); + Printv(f_shadow, tab4, "def __init__(", parms, ")", returnTypeAnnotation(n), ":\n", NIL); if (have_docstring(n)) Printv(f_shadow, tab8, docstring(n, AUTODOC_CTOR, tab8), "\n", NIL); if (have_pythonprepend(n)) @@ -4438,7 +4437,7 @@ public: } else { Printv(f_shadow, tab8, "this = ", funcCall(Swig_name_construct(NSPACE_TODO, symname), callParms), "\n", - tab8, "try: self.this.append(this)\n", tab8, "except: self.this = this\n", NIL); + tab8, "try:\n", tab8, tab4, "self.this.append(this)\n", tab8, "except:\n", tab8, tab4, "self.this = this\n", NIL); } if (have_pythonappend(n)) Printv(f_shadow, pythoncode(pythonappend(n), tab8), "\n\n", NIL); @@ -4524,7 +4523,7 @@ public: Printv(f_shadow, tab4, "__swig_destroy__ = ", module, ".", Swig_name_destroy(NSPACE_TODO, symname), "\n", NIL); if (!have_pythonprepend(n) && !have_pythonappend(n)) { if (proxydel) { - Printv(f_shadow, tab4, "__del__ = lambda self : None;\n", NIL); + Printv(f_shadow, tab4, "__del__ = lambda self: None\n", NIL); } return SWIG_OK; } @@ -4535,7 +4534,7 @@ public: Printv(f_shadow, pythoncode(pythonprepend(n), tab8), "\n", NIL); #ifdef USE_THISOWN Printv(f_shadow, tab8, "try:\n", NIL); - Printv(f_shadow, tab8, tab4, "if self.thisown: ", module, ".", Swig_name_destroy(NSPACE_TODO, symname), "(self)\n", NIL); + Printv(f_shadow, tab8, tab4, "if self.thisown:", module, ".", Swig_name_destroy(NSPACE_TODO, symname), "(self)\n", NIL); Printv(f_shadow, tab8, "except: pass\n", NIL); #else #endif -- cgit v1.2.1 From 01a99464550b8d5747c6cef4aae9b694c9b202fa Mon Sep 17 00:00:00 2001 From: Julien Schueller Date: Fri, 6 Jun 2014 11:28:00 +0200 Subject: Fixed some pep8 issues E302 --- Source/Modules/python.cxx | 24 ++++++++++++------------ 1 file changed, 12 insertions(+), 12 deletions(-) diff --git a/Source/Modules/python.cxx b/Source/Modules/python.cxx index bd3cc0779..0ee9570dc 100644 --- a/Source/Modules/python.cxx +++ b/Source/Modules/python.cxx @@ -852,14 +852,14 @@ public: Printf(f_shadow, "from %s import *\n", module); } if (modern || !classic) { - Printv(f_shadow, "try:\n", tab4, "_swig_property = property\n", "except NameError:\n", tab4, "pass # Python < 2.2 doesn't have 'property'.\n", NULL); + Printv(f_shadow, "try:\n", tab4, "_swig_property = property\n", "except NameError:\n", tab4, "pass # Python < 2.2 doesn't have 'property'.\n\n", NULL); } /* if (!modern) */ /* always needed, a class can be forced to be no-modern, such as an exception */ { // Python-2.2 object hack Printv(f_shadow, - "def _swig_setattr_nondynamic(self, class_type, name, value, static=1):\n", + "\n", "def _swig_setattr_nondynamic(self, class_type, name, value, static=1):\n", tab4, "if (name == \"thisown\"):\n", tab4, tab4, "return self.this.own(value)\n", tab4, "if (name == \"this\"):\n", tab4, tab4, "if type(value).__name__ == 'SwigPyObject':\n", tab4, tab8, "self.__dict__[name] = value\n", #ifdef USE_THISOWN @@ -874,16 +874,16 @@ public: tab4, tab4, "self.__dict__[name] = value\n", tab4, "else:\n", tab4, tab4, "raise AttributeError(\"You cannot add attributes to %s\" % self)\n\n", - "def _swig_setattr(self, class_type, name, value):\n", tab4, "return _swig_setattr_nondynamic(self, class_type, name, value, 0)\n\n", NIL); + "\n", "def _swig_setattr(self, class_type, name, value):\n", tab4, "return _swig_setattr_nondynamic(self, class_type, name, value, 0)\n\n", NIL); Printv(f_shadow, - "def _swig_getattr(self, class_type, name):\n", + "\n", "def _swig_getattr(self, class_type, name):\n", tab4, "if (name == \"thisown\"):\n", tab4, tab4, "return self.this.own()\n", tab4, "method = class_type.__swig_getmethods__.get(name, None)\n", tab4, "if method:\n", tab4, tab4, "return method(self)\n", tab4, "raise AttributeError(name)\n\n", NIL); Printv(f_shadow, - "def _swig_repr(self):\n", + "\n", "def _swig_repr(self):\n", tab4, "try:\n", tab4, tab4, "strthis = \"proxy of \" + self.this.__repr__()\n", tab4, "except:\n", tab4, tab4, "strthis = \"\"\n", tab4, "return \"<%s.%s; %s >\" % (self.__class__.__module__, self.__class__.__name__, strthis,)\n\n", NIL); @@ -901,7 +901,7 @@ public: } } if (modern) { - Printv(f_shadow, "def _swig_setattr_nondynamic_method(set):\n", tab4, "def set_attr(self, name, value):\n", + Printv(f_shadow, "\n", "def _swig_setattr_nondynamic_method(set):\n", tab4, "def set_attr(self, name, value):\n", #ifdef USE_THISOWN tab4, tab4, "if hasattr(self, name) or (name in (\"this\", \"thisown\")):\n", #else @@ -4056,7 +4056,7 @@ public: Delete(realct); if (!have_constructor) { if (!builtin) - Printv(f_shadow_file, tab4, "def __init__(self, *args, **kwargs):\n", tab8, "raise AttributeError(\"", "No constructor defined", + Printv(f_shadow_file, "\n", tab4, "def __init__(self, *args, **kwargs):\n", tab8, "raise AttributeError(\"", "No constructor defined", (Getattr(n, "abstracts") ? " - class is abstract" : ""), "\")\n", NIL); } else if (fastinit && !builtin) { @@ -4108,7 +4108,7 @@ public: List *shadow_list = Getattr(n, "shadow_methods"); for (int i = 0; i < Len(shadow_list); ++i) { String *symname = Getitem(shadow_list, i); - Printf(f_shadow_file, "%s.%s = new_instancemethod(%s.%s,None,%s)\n", class_name, symname, module, Swig_name_member(NSPACE_TODO, class_name, symname), + Printf(f_shadow_file, "%s.%s = new_instancemethod(%s.%s, None, %s)\n", class_name, symname, module, Swig_name_member(NSPACE_TODO, class_name, symname), class_name); } } @@ -4223,11 +4223,11 @@ public: String *callParms = make_pyParmList(n, true, true, allow_kwargs); if (!have_addtofunc(n)) { if (!fastproxy || olddefs) { - Printv(f_shadow, tab4, "def ", symname, "(", parms, ")", returnTypeAnnotation(n), ":\n", NIL); + Printv(f_shadow, "\n", tab4, "def ", symname, "(", parms, ")", returnTypeAnnotation(n), ":\n", NIL); Printv(f_shadow, tab8, "return ", funcCall(fullname, callParms), "\n", NIL); } } else { - Printv(f_shadow, tab4, "def ", symname, "(", parms, ")", returnTypeAnnotation(n), ":\n", NIL); + Printv(f_shadow, "\n", tab4, "def ", symname, "(", parms, ")", returnTypeAnnotation(n), ":\n", NIL); if (have_docstring(n)) Printv(f_shadow, tab8, docstring(n, AUTODOC_METHOD, tab8), "\n", NIL); if (have_pythonprepend(n)) { @@ -4313,7 +4313,7 @@ public: int kw = (check_kwargs(n) && !Getattr(n, "sym:overloaded")) ? 1 : 0; String *parms = make_pyParmList(n, false, false, kw); String *callParms = make_pyParmList(n, false, true, kw); - Printv(f_shadow, tab4, "def ", symname, "(", parms, ")", returnTypeAnnotation(n), ":\n", NIL); + Printv(f_shadow, "\n", tab4, "def ", symname, "(", parms, ")", returnTypeAnnotation(n), ":\n", NIL); if (have_docstring(n)) Printv(f_shadow, tab8, docstring(n, AUTODOC_STATICFUNC, tab8), "\n", NIL); if (have_pythonprepend(n)) @@ -4426,7 +4426,7 @@ public: Printv(pass_self, tab8, tab4, "_self = None\n", tab8, "else:\n", tab8, tab4, "_self = self\n", NIL); } - Printv(f_shadow, tab4, "def __init__(", parms, ")", returnTypeAnnotation(n), ":\n", NIL); + Printv(f_shadow, "\n", tab4, "def __init__(", parms, ")", returnTypeAnnotation(n), ":\n", NIL); if (have_docstring(n)) Printv(f_shadow, tab8, docstring(n, AUTODOC_CTOR, tab8), "\n", NIL); if (have_pythonprepend(n)) -- cgit v1.2.1 From 36cac801660523b9f355f53f91cc0c658060155b Mon Sep 17 00:00:00 2001 From: Julien Schueller Date: Fri, 6 Jun 2014 14:27:17 +0200 Subject: Fixed some pep8 issues E701 --- Source/Modules/python.cxx | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/Source/Modules/python.cxx b/Source/Modules/python.cxx index 0ee9570dc..ab6cfd397 100644 --- a/Source/Modules/python.cxx +++ b/Source/Modules/python.cxx @@ -4325,7 +4325,7 @@ public: } else { Printv(f_shadow, tab8, "return ", funcCall(Swig_name_member(NSPACE_TODO, class_name, symname), callParms), "\n\n", NIL); } - Printv(f_shadow, tab4, modern ? "" : "if _newclass:", symname, " = staticmethod(", symname, ")\n", NIL); + Printv(f_shadow, tab4, modern ? "" : "if _newclass:\n", tab8, symname, " = staticmethod(", symname, ")\n", NIL); if (!modern) { Printv(f_shadow, tab4, "__swig_getmethods__[\"", symname, "\"] = lambda x: ", symname, "\n", NIL); @@ -4337,7 +4337,7 @@ public: NIL); } if (!classic) { - Printv(f_shadow, tab4, modern ? "" : "if _newclass:", symname, " = staticmethod(", module, ".", Swig_name_member(NSPACE_TODO, class_name, symname), + Printv(f_shadow, tab4, modern ? "" : "if _newclass:\n", tab8, symname, " = staticmethod(", module, ".", Swig_name_member(NSPACE_TODO, class_name, symname), ")\n", NIL); } } @@ -4573,9 +4573,9 @@ public: } if (!classic) { if (!assignable) { - Printv(f_shadow, tab4, modern ? "" : "if _newclass:", symname, " = _swig_property(", module, ".", getname, ")\n", NIL); + Printv(f_shadow, tab4, modern ? "" : "if _newclass:\n", tab8, symname, " = _swig_property(", module, ".", getname, ")\n", NIL); } else { - Printv(f_shadow, tab4, modern ? "" : "if _newclass:", symname, " = _swig_property(", module, ".", getname, ", ", module, ".", setname, ")\n", NIL); + Printv(f_shadow, tab4, modern ? "" : "if _newclass:\n", tab8, symname, " = _swig_property(", module, ".", getname, ", ", module, ".", setname, ")\n", NIL); } } Delete(mname); @@ -4646,9 +4646,9 @@ public: } if (!classic && !builtin) { if (!assignable) { - Printv(f_shadow, tab4, modern ? "" : "if _newclass:", symname, " = _swig_property(", module, ".", getname, ")\n", NIL); + Printv(f_shadow, tab4, modern ? "" : "if _newclass:\n", tab8, symname, " = _swig_property(", module, ".", getname, ")\n", NIL); } else { - Printv(f_shadow, tab4, modern ? "" : "if _newclass:", symname, " = _swig_property(", module, ".", getname, ", ", module, ".", setname, ")\n", NIL); + Printv(f_shadow, tab4, modern ? "" : "if _newclass:\n", tab8, symname, " = _swig_property(", module, ".", getname, ", ", module, ".", setname, ")\n", NIL); } } String *getter = Getattr(n, "pybuiltin:getter"); -- cgit v1.2.1 From 93e06c0e5867be8dec05e9ab58c2c9fcb2320b7c Mon Sep 17 00:00:00 2001 From: Julien Schueller Date: Fri, 6 Jun 2014 14:44:46 +0200 Subject: Fixed another E231 --- Source/Modules/python.cxx | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/Source/Modules/python.cxx b/Source/Modules/python.cxx index ab6cfd397..0d38a19ed 100644 --- a/Source/Modules/python.cxx +++ b/Source/Modules/python.cxx @@ -3901,7 +3901,7 @@ public: Printv(base_class, bname, NIL); b = Next(b); if (b.item) { - Putc(',', base_class); + Printv(base_class, ", ", NIL); } } } @@ -3922,7 +3922,7 @@ public: String *abcs = Getattr(n, "feature:python:abc"); if (py3 && abcs) { if (Len(base_class)) { - Putc(',', base_class); + Printv(base_class, ", ", NIL); } Printv(base_class, abcs, NIL); } -- cgit v1.2.1 From f4fffbf668781f5308d1e944dc25238c93082b1c Mon Sep 17 00:00:00 2001 From: Julien Schueller Date: Fri, 6 Jun 2014 15:13:23 +0200 Subject: Fixed another E701 --- Lib/python/pycontainer.swg | 3 ++- Lib/python/std_map.i | 12 ++++++++---- Lib/python/std_unordered_map.i | 12 ++++++++---- 3 files changed, 18 insertions(+), 9 deletions(-) diff --git a/Lib/python/pycontainer.swg b/Lib/python/pycontainer.swg index dcada87c7..425cc45fc 100644 --- a/Lib/python/pycontainer.swg +++ b/Lib/python/pycontainer.swg @@ -710,7 +710,8 @@ namespace swig #if defined(SWIGPYTHON_BUILTIN) %feature("python:slot", "tp_iter", functype="getiterfunc") iterator; #else - %pythoncode {def __iter__(self): return self.iterator()} + %pythoncode {def __iter__(self): + return self.iterator()} #endif } diff --git a/Lib/python/std_map.i b/Lib/python/std_map.i index 66ed68da5..58902bca4 100644 --- a/Lib/python/std_map.i +++ b/Lib/python/std_map.i @@ -176,10 +176,14 @@ #else %extend { - %pythoncode {def __iter__(self): return self.key_iterator()} - %pythoncode {def iterkeys(self): return self.key_iterator()} - %pythoncode {def itervalues(self): return self.value_iterator()} - %pythoncode {def iteritems(self): return self.iterator()} + %pythoncode {def __iter__(self): + return self.key_iterator()} + %pythoncode {def iterkeys(self): + return self.key_iterator()} + %pythoncode {def itervalues(self): + return self.value_iterator()} + %pythoncode {def iteritems(self): + return self.iterator()} } #endif diff --git a/Lib/python/std_unordered_map.i b/Lib/python/std_unordered_map.i index b456035e2..737468234 100644 --- a/Lib/python/std_unordered_map.i +++ b/Lib/python/std_unordered_map.i @@ -231,10 +231,14 @@ return swig::make_output_value_iterator(self->begin(), self->begin(), self->end(), *PYTHON_SELF); } - %pythoncode {def __iter__(self): return self.key_iterator()} - %pythoncode {def iterkeys(self): return self.key_iterator()} - %pythoncode {def itervalues(self): return self.value_iterator()} - %pythoncode {def iteritems(self): return self.iterator()} + %pythoncode {def __iter__(self): + return self.key_iterator()} + %pythoncode {def iterkeys(self): + return self.key_iterator()} + %pythoncode {def itervalues(self): + return self.value_iterator()} + %pythoncode {def iteritems(self): + return self.iterator()} } %enddef -- cgit v1.2.1 From fa36b6228e760e19928a9cccff71114ea46f932b Mon Sep 17 00:00:00 2001 From: Jason Turner Date: Sat, 31 May 2014 14:35:10 -0600 Subject: Fix function naming conflict with class overloads. This fix takes into account the classname while generating overload handlers. Example: If you have two classes: class A { public: void doSomething(int); void doSomething(double); }; class B { public: void doSomething(int); void doSomething(double); }; Before this patch, the overload handlers for A::doSomething and B::doSomething create conflicting names and function redefinition errors are caused. After the patch, the overload handlers are named classname_doSomething and no longer conflict. This is might not the best way to implement this, but it solves a critical problem on large projects, and specifically can affect operator overloads that are being wrapped. --- Source/Modules/javascript.cxx | 15 ++++++++++++--- 1 file changed, 12 insertions(+), 3 deletions(-) diff --git a/Source/Modules/javascript.cxx b/Source/Modules/javascript.cxx index 8b7a74037..0c3f02a75 100644 --- a/Source/Modules/javascript.cxx +++ b/Source/Modules/javascript.cxx @@ -1231,18 +1231,27 @@ int JSEmitter::emitFunctionDispatcher(Node *n, bool /*is_member */ ) { // substract the extension "sym:overname", String *wrap_name = NewString(Getattr(n, "wrap:name")); String *overname = Getattr(n, "sym:overname"); + + Node *methodclass = Swig_methodclass(n); + String *class_name = Getattr(methodclass, "sym:name"); + int l1 = Len(wrap_name); int l2 = Len(overname); Delslice(wrap_name, l1 - l2, l1); - Setattr(n, "wrap:name", wrap_name); - state.function(WRAPPER_NAME, wrap_name); + String *new_string = NewStringf("%s_%s", class_name, wrap_name); + String *final_wrap_name = Swig_name_wrapper(new_string); + + Setattr(n, "wrap:name", final_wrap_name); + state.function(WRAPPER_NAME, final_wrap_name); + + t_function.replace("$jslocals", wrapper->locals) .replace("$jscode", wrapper->code); // call this here, to replace all variables - t_function.replace("$jswrapper", wrap_name) + t_function.replace("$jswrapper", final_wrap_name) .replace("$jsname", state.function(NAME)) .pretty_print(f_wrappers); -- cgit v1.2.1 From 8728a97dc60417e4c5599349d06cd1c408f14a7d Mon Sep 17 00:00:00 2001 From: William S Fulton Date: Fri, 6 Jun 2014 19:56:38 +0100 Subject: Bump version to 3.0.3 --- ANNOUNCE | 8 ++++---- CHANGES | 20 ++++++++++++++++++++ CHANGES.current | 18 +----------------- Doc/Manual/Sections.html | 2 +- README | 2 +- configure.ac | 2 +- 6 files changed, 28 insertions(+), 24 deletions(-) diff --git a/ANNOUNCE b/ANNOUNCE index 58de2fe10..95261b2bd 100644 --- a/ANNOUNCE +++ b/ANNOUNCE @@ -1,8 +1,8 @@ -*** ANNOUNCE: SWIG 3.0.2 (4 Jun 2014) *** +*** ANNOUNCE: SWIG 3.0.3 (in progress) *** http://www.swig.org -We're pleased to announce SWIG-3.0.2, the latest SWIG release. +We're pleased to announce SWIG-3.0.3, the latest SWIG release. What is SWIG? ============= @@ -21,11 +21,11 @@ Availability ============ The release is available for download on Sourceforge at - http://prdownloads.sourceforge.net/swig/swig-3.0.2.tar.gz + http://prdownloads.sourceforge.net/swig/swig-3.0.3.tar.gz A Windows version is also available at - http://prdownloads.sourceforge.net/swig/swigwin-3.0.2.zip + http://prdownloads.sourceforge.net/swig/swigwin-3.0.3.zip Please report problems with this release to the swig-devel mailing list, details at http://www.swig.org/mail.html. diff --git a/CHANGES b/CHANGES index 1cfedc31e..edcdbba3e 100644 --- a/CHANGES +++ b/CHANGES @@ -3,6 +3,26 @@ SWIG (Simplified Wrapper and Interface Generator) See the CHANGES.current file for changes in the current version. See the RELEASENOTES file for a summary of changes in each release. +Version 3.0.2 (4 Jun 2014) +========================== + +2014-06-02: v-for-vandal + [Lua] Pull request #176: + If class has no __eq implemented, then default __eq is generated. + Default __eq compares actual pointers stored inside Lua userdata. + +2014-06-02: vkalinin + Fix #183 - %extend and unnamed nested structs + +2014-05-28: kwwette + Fix install failure when using an 'out of source' build using the shipped + tarball - regression introduced in swig-3.0.1. + +2014-05-24: kwwette + [Octave] Remove deprecated -global/-noglobal command-line arguments + + *** POTENTIAL INCOMPATIBILITY *** + Version 3.0.1 (27 May 2014) =========================== diff --git a/CHANGES.current b/CHANGES.current index bb8bbdc41..dce3757d7 100644 --- a/CHANGES.current +++ b/CHANGES.current @@ -2,22 +2,6 @@ Below are the changes for the current release. See the CHANGES file for changes in older releases. See the RELEASENOTES file for a summary of changes in each release. -Version 3.0.2 (4 Jun 2014) +Version 3.0.3 (in progress) =========================== -2014-06-02: v-for-vandal - [Lua] Pull request #176: - If class has no __eq implemented, then default __eq is generated. - Default __eq compares actual pointers stored inside Lua userdata. - -2014-06-02: vkalinin - Fix #183 - %extend and unnamed nested structs - -2014-05-28: kwwette - Fix install failure when using an 'out of source' build using the shipped - tarball - regression introduced in swig-3.0.1. - -2014-05-24: kwwette - [Octave] Remove deprecated -global/-noglobal command-line arguments - - *** POTENTIAL INCOMPATIBILITY *** diff --git a/Doc/Manual/Sections.html b/Doc/Manual/Sections.html index bcae8139d..0bda3e106 100644 --- a/Doc/Manual/Sections.html +++ b/Doc/Manual/Sections.html @@ -6,7 +6,7 @@

      SWIG-3.0 Documentation

      -Last update : SWIG-3.0.2 (4 Jun 2014) +Last update : SWIG-3.0.3 (in progress)

      Sections

      diff --git a/README b/README index 746bad7e1..7d0130b83 100644 --- a/README +++ b/README @@ -1,6 +1,6 @@ SWIG (Simplified Wrapper and Interface Generator) -Version: 3.0.2 (4 Jun 2014) +Version: 3.0.3 (in progress) Tagline: SWIG is a compiler that integrates C and C++ with languages including Perl, Python, Tcl, Ruby, PHP, Java, C#, D, Go, Lua, diff --git a/configure.ac b/configure.ac index 77b804ddd..993e0e28a 100644 --- a/configure.ac +++ b/configure.ac @@ -2,7 +2,7 @@ dnl Process this file with autoconf to produce a configure script. dnl The macros which aren't shipped with the autotools are stored in the dnl Tools/config directory in .m4 files. -AC_INIT([swig],[3.0.2],[http://www.swig.org]) +AC_INIT([swig],[3.0.3],[http://www.swig.org]) dnl NB: When this requirement is increased to 2.60 or later, AC_PROG_SED dnl definition below can be removed -- cgit v1.2.1 From 6fe71da9fa6ff525808a7076f96b0df2c522bef7 Mon Sep 17 00:00:00 2001 From: Julien Schueller Date: Sat, 7 Jun 2014 13:09:15 +0200 Subject: Fixed remaining pep8 errors --- Lib/python/std_pair.i | 22 ++++++++++++---------- Source/Modules/python.cxx | 22 +++++++++++----------- 2 files changed, 23 insertions(+), 21 deletions(-) diff --git a/Lib/python/std_pair.i b/Lib/python/std_pair.i index 782969574..73d47e198 100644 --- a/Lib/python/std_pair.i +++ b/Lib/python/std_pair.i @@ -176,18 +176,20 @@ SwigPython_std_pair_setitem (PyObject *a, Py_ssize_t b, PyObject *c) %define %swig_pair_methods(pair...) #if !defined(SWIGPYTHON_BUILTIN) %extend { -%pythoncode {def __len__(self): return 2 -def __repr__(self): return str((self.first, self.second)) +%pythoncode {def __len__(self): + return 2 +def __repr__(self): + return str((self.first, self.second)) def __getitem__(self, index): - if not (index % 2): - return self.first - else: - return self.second + if not (index % 2): + return self.first + else: + return self.second def __setitem__(self, index, val): - if not (index % 2): - self.first = val - else: - self.second = val} + if not (index % 2): + self.first = val + else: + self.second = val} } #endif %enddef diff --git a/Source/Modules/python.cxx b/Source/Modules/python.cxx index 0d38a19ed..c327dbc1c 100644 --- a/Source/Modules/python.cxx +++ b/Source/Modules/python.cxx @@ -860,10 +860,10 @@ public: // Python-2.2 object hack Printv(f_shadow, "\n", "def _swig_setattr_nondynamic(self, class_type, name, value, static=1):\n", - tab4, "if (name == \"thisown\"):\n", tab4, tab4, "return self.this.own(value)\n", - tab4, "if (name == \"this\"):\n", tab4, tab4, "if type(value).__name__ == 'SwigPyObject':\n", tab4, tab8, "self.__dict__[name] = value\n", + tab4, "if (name == \"thisown\"):\n", tab8, "return self.this.own(value)\n", + tab4, "if (name == \"this\"):\n", tab8, "if type(value).__name__ == 'SwigPyObject':\n", tab4, tab8, "self.__dict__[name] = value\n", #ifdef USE_THISOWN - tab4, tab8, "if hasattr(value,\"thisown\"): self.__dict__[\"thisown\"] = value.thisown\n", tab4, tab8, "del value.thisown\n", + tab4, tab8, "if hasattr(value,\"thisown\"):\n", tab8, tab8, "self.__dict__[\"thisown\"] = value.thisown\n", tab4, tab8, "del value.thisown\n", #endif tab4, tab8, "return\n", tab4, "method = class_type.__swig_setmethods__.get(name, None)\n", tab4, "if method:\n", tab4, tab4, "return method(self, value)\n", #ifdef USE_THISOWN @@ -878,14 +878,14 @@ public: Printv(f_shadow, "\n", "def _swig_getattr(self, class_type, name):\n", - tab4, "if (name == \"thisown\"):\n", tab4, tab4, "return self.this.own()\n", + tab4, "if (name == \"thisown\"):\n", tab8, "return self.this.own()\n", tab4, "method = class_type.__swig_getmethods__.get(name, None)\n", - tab4, "if method:\n", tab4, tab4, "return method(self)\n", tab4, "raise AttributeError(name)\n\n", NIL); + tab4, "if method:\n", tab8, "return method(self)\n", tab4, "raise AttributeError(name)\n\n", NIL); Printv(f_shadow, "\n", "def _swig_repr(self):\n", - tab4, "try:\n", tab4, tab4, "strthis = \"proxy of \" + self.this.__repr__()\n", - tab4, "except:\n", tab4, tab4, "strthis = \"\"\n", tab4, "return \"<%s.%s; %s >\" % (self.__class__.__module__, self.__class__.__name__, strthis,)\n\n", NIL); + tab4, "try:\n", tab8, "strthis = \"proxy of \" + self.this.__repr__()\n", + tab4, "except:\n", tab8, "strthis = \"\"\n", tab4, "return \"<%s.%s; %s >\" % (self.__class__.__module__, self.__class__.__name__, strthis,)\n\n", NIL); if (!classic) { /* Usage of types.ObjectType is deprecated. @@ -895,7 +895,7 @@ public: // "import types\n", "try:\n", // " _object = types.ObjectType\n", - tab4, "_object = object\n", tab4, "_newclass = 1\n", "except AttributeError:\n", tab4, "class _object:\n", tab4, tab4, "pass\n", tab4, "_newclass = 0\n", + tab4, "_object = object\n", tab4, "_newclass = 1\n", "except AttributeError:\n", tab4, "class _object:\n", tab8, "pass\n", tab4, "_newclass = 0\n", // "del types\n", "\n\n", NIL); } @@ -905,7 +905,7 @@ public: #ifdef USE_THISOWN tab4, tab4, "if hasattr(self, name) or (name in (\"this\", \"thisown\")):\n", #else - tab4, tab4, "if (name == \"thisown\"): return self.this.own(value)\n", tab4, tab4, "if hasattr(self, name) or (name == \"this\"):\n", + tab4, tab4, "if (name == \"thisown\"):\n", tab8, tab4, "return self.this.own(value)\n", tab4, tab4, "if hasattr(self, name) or (name == \"this\"):\n", #endif tab4, tab4, tab4, "set(self, name, value)\n", tab4, tab4, "else:\n", @@ -1637,7 +1637,7 @@ public: } // Write the function annotation if (func_annotation) - Printf(doc, " : '%s'", type_str); + Printf(doc, ": '%s'", type_str); // Write default value if (value && !calling) { @@ -2012,7 +2012,7 @@ public: if (ret) ret = SwigType_str(ret, 0); } - return (ret && py3) ? NewStringf(" -> \"%s\" ", ret) + return (ret && py3) ? NewStringf(" -> \"%s\"", ret) : NewString(""); } -- cgit v1.2.1 From 7a4cef998c963bca49dd2403b024d6d69d87b80f Mon Sep 17 00:00:00 2001 From: Julien Schueller Date: Sat, 7 Jun 2014 13:10:27 +0200 Subject: Enable pep8 check --- .travis.yml | 1 + Examples/test-suite/python/Makefile.in | 9 +++++++++ Examples/test-suite/python_append.i | 22 +++++++++++----------- configure.ac | 2 +- 4 files changed, 22 insertions(+), 12 deletions(-) diff --git a/.travis.yml b/.travis.yml index 08731ca62..0db8730d8 100644 --- a/.travis.yml +++ b/.travis.yml @@ -64,6 +64,7 @@ before_install: - if test "$SWIGLANG" = "lua"; then sudo apt-get -qq install lua5.1 liblua5.1-dev; fi - if test "$SWIGLANG" = "octave"; then sudo apt-get -qq install octave3.2 octave3.2-headers; fi - if test "$SWIGLANG" = "php"; then sudo apt-get install php5-cli php5-dev; fi + - if test "$SWIGLANG" = "python"; then sudo apt-get install -qq pep8; fi - if test "$SWIGLANG" = "python" -a "$PY3" -a -z "$VER"; then sudo apt-get install -qq python3-dev; fi - if test "$SWIGLANG" = "python" -a "$VER"; then sudo add-apt-repository -y ppa:fkrull/deadsnakes && sudo apt-get -qq update && sudo apt-get -qq install python${VER}-dev && export CONFIGOPTS="--with-python${PY3}=python${VER}"; fi - if test "$SWIGLANG" = "tcl"; then sudo apt-get -qq install tcl8.4-dev; fi diff --git a/Examples/test-suite/python/Makefile.in b/Examples/test-suite/python/Makefile.in index 9673d7da1..1c35d2843 100644 --- a/Examples/test-suite/python/Makefile.in +++ b/Examples/test-suite/python/Makefile.in @@ -10,6 +10,7 @@ endif LANGUAGE = python PYTHON = $(PYBIN) +PEP8 = @PEP8@ #*_runme.py for Python 2.x, *_runme3.py for Python 3.x PY2SCRIPTSUFFIX = _runme.py @@ -111,12 +112,14 @@ VALGRIND_OPT += --suppressions=pythonswig.supp +$(convert_testcase) $(setup) +$(swig_and_compile_cpp) + $(check_pep8) $(run_testcase) %.ctest: +$(convert_testcase) $(setup) +$(swig_and_compile_c) + $(check_pep8) $(run_testcase) %.multicpptest: @@ -126,6 +129,7 @@ VALGRIND_OPT += --suppressions=pythonswig.supp $(run_testcase) + # Runs the testcase. A testcase is only run if # a file is found which has _runme.py (or _runme3.py for Python 3) appended after the testcase name. @@ -133,6 +137,11 @@ py_runme = $(SCRIPTPREFIX)$*$(SCRIPTSUFFIX) py2_runme = $(SCRIPTPREFIX)$*$(PY2SCRIPTSUFFIX) py3_runme = $(SCRIPTPREFIX)$*$(PY3SCRIPTSUFFIX) +check_pep8 = \ + if [ -n "$(PEP8)" ]; then \ + $(PEP8) --ignore=E501,E30,W291,W391 `echo $(py2_runme)|sed "s|_runme||g"`;\ + fi + run_python = env LD_LIBRARY_PATH=.:$$LD_LIBRARY_PATH PYTHONPATH=.:$(srcdir):$$PYTHONPATH $(RUNTOOL) $(PYTHON) $(py_runme) run_testcase = \ diff --git a/Examples/test-suite/python_append.i b/Examples/test-suite/python_append.i index e263c392b..0ac54656f 100644 --- a/Examples/test-suite/python_append.i +++ b/Examples/test-suite/python_append.i @@ -5,22 +5,22 @@ Testcase to test %pythonprepend and %pythonappend %pythoncode %pythonbegin %module python_append %pythoncode %{ - mypath = os.path.dirname("/a/b/c/d.txt") - funcpath = None - staticfuncpath = None - def grabpath(): +mypath = os.path.dirname("/a/b/c/d.txt") +funcpath = None +staticfuncpath = None +def grabpath(): return funcpath - def grabstaticpath(): +def grabstaticpath(): return staticfuncpath %} %pythonappend Test::func %{ - funcpath = os.path.dirname(funcpath) +funcpath = os.path.dirname(funcpath) %} %pythonprepend Test::func %{ - global funcpath - funcpath = mypath +global funcpath +funcpath = mypath %} %pythonappend Test::static_func %{ @@ -29,9 +29,9 @@ pass %} %pythonprepend Test::static_func { - global staticfuncpath - staticfuncpath = mypath - pass +global staticfuncpath +staticfuncpath = mypath +pass } %pythonbegin %{ diff --git a/configure.ac b/configure.ac index 77b804ddd..2ec39600e 100644 --- a/configure.ac +++ b/configure.ac @@ -789,7 +789,7 @@ AC_SUBST(PY3INCLUDE) AC_SUBST(PY3LIB) AC_SUBST(PY3LINK) AC_SUBST(PYTHON3DYNAMICLINKING) - +AC_CHECK_PROGS(PEP8, pep8) #---------------------------------------------------------------- # Look for Perl5 -- cgit v1.2.1 From 48fcf61515f9b64e0629f9bab9945ea78c06769f Mon Sep 17 00:00:00 2001 From: Julien Schueller Date: Sat, 7 Jun 2014 14:33:38 +0200 Subject: Ubuntu's pep8 is too old, use 1.5.7 --- .travis.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.travis.yml b/.travis.yml index 0db8730d8..6eee47cb5 100644 --- a/.travis.yml +++ b/.travis.yml @@ -64,7 +64,7 @@ before_install: - if test "$SWIGLANG" = "lua"; then sudo apt-get -qq install lua5.1 liblua5.1-dev; fi - if test "$SWIGLANG" = "octave"; then sudo apt-get -qq install octave3.2 octave3.2-headers; fi - if test "$SWIGLANG" = "php"; then sudo apt-get install php5-cli php5-dev; fi - - if test "$SWIGLANG" = "python"; then sudo apt-get install -qq pep8; fi + - if test "$SWIGLANG" = "python"; then pushd /tmp; git clone https://github.com/jcrocholl/pep8.git; pushd pep8; git checkout tags/1.5.7; python ./setup.py build; sudo python ./setup.py install; popd; popd; fi - if test "$SWIGLANG" = "python" -a "$PY3" -a -z "$VER"; then sudo apt-get install -qq python3-dev; fi - if test "$SWIGLANG" = "python" -a "$VER"; then sudo add-apt-repository -y ppa:fkrull/deadsnakes && sudo apt-get -qq update && sudo apt-get -qq install python${VER}-dev && export CONFIGOPTS="--with-python${PY3}=python${VER}"; fi - if test "$SWIGLANG" = "tcl"; then sudo apt-get -qq install tcl8.4-dev; fi -- cgit v1.2.1 From b58caf6978126d56c8df56d6666c27f7428c13f7 Mon Sep 17 00:00:00 2001 From: Olly Betts Date: Sun, 8 Jun 2014 22:04:55 +1200 Subject: Add more new PHP5.6 keywords --- Lib/php/phpkw.swg | 22 ++++++++++++++++++++++ 1 file changed, 22 insertions(+) diff --git a/Lib/php/phpkw.swg b/Lib/php/phpkw.swg index 14f37d2ff..36e535f52 100644 --- a/Lib/php/phpkw.swg +++ b/Lib/php/phpkw.swg @@ -625,6 +625,28 @@ PHPBN2(MYSQLI_SERVER_PUBLIC_KEY); /* Added in PHP 5.6 */ PHPBN2(LDAP_ESCAPE_DN); PHPBN2(LDAP_ESCAPE_FILTER); +PHPBN2(OPENSSL_DEFAULT_STREAM_CIPHERS); +PHPBN2(STREAM_CRYPTO_METHOD_ANY_CLIENT); +PHPBN2(STREAM_CRYPTO_METHOD_ANY_SERVER); +PHPBN2(STREAM_CRYPTO_METHOD_TLSv1_0_CLIENT); +PHPBN2(STREAM_CRYPTO_METHOD_TLSv1_0_SERVER); +PHPBN2(STREAM_CRYPTO_METHOD_TLSv1_1_CLIENT); +PHPBN2(STREAM_CRYPTO_METHOD_TLSv1_1_SERVER); +PHPBN2(STREAM_CRYPTO_METHOD_TLSv1_2_CLIENT); +PHPBN2(STREAM_CRYPTO_METHOD_TLSv1_2_SERVER); +PHPBN2(PGSQL_CONNECT_ASYNC); +PHPBN2(PGSQL_CONNECTION_AUTH_OK); +PHPBN2(PGSQL_CONNECTION_AWAITING_RESPONSE); +PHPBN2(PGSQL_CONNECTION_MADE); +PHPBN2(PGSQL_CONNECTION_SETENV); +PHPBN2(PGSQL_CONNECTION_SSL_STARTUP); +PHPBN2(PGSQL_CONNECTION_STARTED); +PHPBN2(PGSQL_DML_ESCAPE); +PHPBN2(PGSQL_POLLING_ACTIVE); +PHPBN2(PGSQL_POLLING_FAILED); +PHPBN2(PGSQL_POLLING_OK); +PHPBN2(PGSQL_POLLING_READING); +PHPBN2(PGSQL_POLLING_WRITING); /* Class names reserved by PHP (case insensitive) */ PHPCN(directory); -- cgit v1.2.1 From 8a0a8529e5d2386b4f994c74445c005326b8ce7b Mon Sep 17 00:00:00 2001 From: Julien Schueller Date: Sun, 8 Jun 2014 15:43:02 +0200 Subject: Clone pep8 in source dir. --- .travis.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.travis.yml b/.travis.yml index 6eee47cb5..795a690ef 100644 --- a/.travis.yml +++ b/.travis.yml @@ -64,7 +64,7 @@ before_install: - if test "$SWIGLANG" = "lua"; then sudo apt-get -qq install lua5.1 liblua5.1-dev; fi - if test "$SWIGLANG" = "octave"; then sudo apt-get -qq install octave3.2 octave3.2-headers; fi - if test "$SWIGLANG" = "php"; then sudo apt-get install php5-cli php5-dev; fi - - if test "$SWIGLANG" = "python"; then pushd /tmp; git clone https://github.com/jcrocholl/pep8.git; pushd pep8; git checkout tags/1.5.7; python ./setup.py build; sudo python ./setup.py install; popd; popd; fi + - if test "$SWIGLANG" = "python"; git clone https://github.com/jcrocholl/pep8.git && pushd pep8 && git checkout tags/1.5.7 && python ./setup.py build && sudo python ./setup.py install && popd; fi - if test "$SWIGLANG" = "python" -a "$PY3" -a -z "$VER"; then sudo apt-get install -qq python3-dev; fi - if test "$SWIGLANG" = "python" -a "$VER"; then sudo add-apt-repository -y ppa:fkrull/deadsnakes && sudo apt-get -qq update && sudo apt-get -qq install python${VER}-dev && export CONFIGOPTS="--with-python${PY3}=python${VER}"; fi - if test "$SWIGLANG" = "tcl"; then sudo apt-get -qq install tcl8.4-dev; fi -- cgit v1.2.1 From eb26847255679944f5126ced85c93f8978f474a7 Mon Sep 17 00:00:00 2001 From: Julien Schueller Date: Sun, 8 Jun 2014 15:44:44 +0200 Subject: Typo --- .travis.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.travis.yml b/.travis.yml index 795a690ef..016f704ce 100644 --- a/.travis.yml +++ b/.travis.yml @@ -64,7 +64,7 @@ before_install: - if test "$SWIGLANG" = "lua"; then sudo apt-get -qq install lua5.1 liblua5.1-dev; fi - if test "$SWIGLANG" = "octave"; then sudo apt-get -qq install octave3.2 octave3.2-headers; fi - if test "$SWIGLANG" = "php"; then sudo apt-get install php5-cli php5-dev; fi - - if test "$SWIGLANG" = "python"; git clone https://github.com/jcrocholl/pep8.git && pushd pep8 && git checkout tags/1.5.7 && python ./setup.py build && sudo python ./setup.py install && popd; fi + - if test "$SWIGLANG" = "python"; then git clone https://github.com/jcrocholl/pep8.git && pushd pep8 && git checkout tags/1.5.7 && python ./setup.py build && sudo python ./setup.py install && popd; fi - if test "$SWIGLANG" = "python" -a "$PY3" -a -z "$VER"; then sudo apt-get install -qq python3-dev; fi - if test "$SWIGLANG" = "python" -a "$VER"; then sudo add-apt-repository -y ppa:fkrull/deadsnakes && sudo apt-get -qq update && sudo apt-get -qq install python${VER}-dev && export CONFIGOPTS="--with-python${PY3}=python${VER}"; fi - if test "$SWIGLANG" = "tcl"; then sudo apt-get -qq install tcl8.4-dev; fi -- cgit v1.2.1 From 11b5a6187999c24ea6d887110749d12f3c2aa5eb Mon Sep 17 00:00:00 2001 From: Julien Schueller Date: Tue, 10 Jun 2014 08:59:55 +0200 Subject: Check multi-module examples. Dont use sed. --- Examples/test-suite/python/Makefile.in | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) diff --git a/Examples/test-suite/python/Makefile.in b/Examples/test-suite/python/Makefile.in index 1c35d2843..c00d8844c 100644 --- a/Examples/test-suite/python/Makefile.in +++ b/Examples/test-suite/python/Makefile.in @@ -126,6 +126,7 @@ VALGRIND_OPT += --suppressions=pythonswig.supp +$(convert_testcase) $(setup) +$(swig_and_compile_multi_cpp) + $(check_pep8_multi_cpp) $(run_testcase) @@ -139,7 +140,14 @@ py3_runme = $(SCRIPTPREFIX)$*$(PY3SCRIPTSUFFIX) check_pep8 = \ if [ -n "$(PEP8)" ]; then \ - $(PEP8) --ignore=E501,E30,W291,W391 `echo $(py2_runme)|sed "s|_runme||g"`;\ + $(PEP8) --ignore=E501,E30,W291,W391 $(SCRIPTPREFIX)$*.py;\ + fi + +check_pep8_multi_cpp = \ + if [ -n "$(PEP8)" ]; then \ + for f in `cat $(top_srcdir)/$(EXAMPLES)/$(TEST_SUITE)/$*.list` ; do \ + $(PEP8) --ignore=E501,E30,W291,W391 $$f.py; \ + done \ fi run_python = env LD_LIBRARY_PATH=.:$$LD_LIBRARY_PATH PYTHONPATH=.:$(srcdir):$$PYTHONPATH $(RUNTOOL) $(PYTHON) $(py_runme) -- cgit v1.2.1 From 0a4b50162d6a3ae66c1d652278368ca79dc0a70f Mon Sep 17 00:00:00 2001 From: William S Fulton Date: Tue, 24 Jun 2014 18:56:52 +0100 Subject: Remove author names - they are in the COPYRIGHT file --- Lib/tcl/std_map.i | 2 -- 1 file changed, 2 deletions(-) diff --git a/Lib/tcl/std_map.i b/Lib/tcl/std_map.i index 78f6e3276..ade2b0ad1 100644 --- a/Lib/tcl/std_map.i +++ b/Lib/tcl/std_map.i @@ -1,7 +1,5 @@ // // SWIG typemaps for std::map -// Luigi Ballabio -// Jan. 2003 // // Common implementation -- cgit v1.2.1 From e982dc7e3b0670c87e77b63d4d8c4606a9172b2b Mon Sep 17 00:00:00 2001 From: William S Fulton Date: Tue, 1 Jul 2014 20:07:19 +0100 Subject: Correct documentation of special variable names $parentname is really $parentclassname $parentsymname is really $parentclasssymname --- CHANGES | 6 +++--- Doc/Manual/Customization.html | 4 ++-- Doc/Manual/SWIGPlus.html | 2 +- 3 files changed, 6 insertions(+), 6 deletions(-) diff --git a/CHANGES b/CHANGES index edcdbba3e..37868d8fe 100644 --- a/CHANGES +++ b/CHANGES @@ -1021,13 +1021,13 @@ Version 2.0.9 (16 December 2012) 2012-10-11: wsfulton Most of the special variables available for use in %exception are now also available for expansion in - %extend blocks. These are: $name $symname $overname $decl $fulldecl $parentname $parentsymname, see docs + %extend blocks. These are: $name $symname $overname $decl $fulldecl $parentclassname $parentclasssymname, see docs on "Class extension" in SWIGPlus.html. Patch based on submission from Kris Thielemans. 2012-10-10: wsfulton Additional new special variables in %exception are expanded as follows: - $parentname - The parent class name (if any) for a method. - $parentsymname - The target language parent class name (if any) for a method. + $parentclassname - The parent class name (if any) for a method. + $parentclasssymname - The target language parent class name (if any) for a method. 2012-10-08: iant [Go] Generating Go code now requires using the -intgosize option to diff --git a/Doc/Manual/Customization.html b/Doc/Manual/Customization.html index a0a89c042..880b64c90 100644 --- a/Doc/Manual/Customization.html +++ b/Doc/Manual/Customization.html @@ -485,12 +485,12 @@ variables are replaced with. -$parentname +$parentclassname The parent class name (if any) for a method. -$parentsymname +$parentclasssymname The target language parent class name (if any) for a method. diff --git a/Doc/Manual/SWIGPlus.html b/Doc/Manual/SWIGPlus.html index f9558994b..9589bf16c 100644 --- a/Doc/Manual/SWIGPlus.html +++ b/Doc/Manual/SWIGPlus.html @@ -2847,7 +2847,7 @@ struct Derived : Base {

      The following special variables are expanded if used within a %extend block: -$name, $symname, $overname, $decl, $fulldecl, $parentname and $parentsymname. +$name, $symname, $overname, $decl, $fulldecl, $parentclassname and $parentclasssymname. The Special variables section provides more information each of these special variables.

      -- cgit v1.2.1 From 83749b3937bba0679cc02ccaa082f43abd4ad9e0 Mon Sep 17 00:00:00 2001 From: William S Fulton Date: Tue, 1 Jul 2014 20:27:48 +0100 Subject: Fix expansion of the $parentclassname special variable It incorrectly contains brackets in the expanded name. Fixes SF Bug 1375. --- CHANGES.current | 3 +++ Examples/test-suite/extend_special_variables.i | 13 +++++++++++++ Source/Swig/cwrap.c | 2 +- 3 files changed, 17 insertions(+), 1 deletion(-) diff --git a/CHANGES.current b/CHANGES.current index dce3757d7..d3015a0ba 100644 --- a/CHANGES.current +++ b/CHANGES.current @@ -5,3 +5,6 @@ See the RELEASENOTES file for a summary of changes in each release. Version 3.0.3 (in progress) =========================== +2014-07-01: wsfulton + Fix SF Bug #1375 - Expansion of the $parentclassname special variable incorrectly contains + brackets in the expanded name. diff --git a/Examples/test-suite/extend_special_variables.i b/Examples/test-suite/extend_special_variables.i index dd68e7531..9a453597a 100644 --- a/Examples/test-suite/extend_special_variables.i +++ b/Examples/test-suite/extend_special_variables.i @@ -19,3 +19,16 @@ struct ForExtension { }; %} + +%inline %{ +namespace Space { + template class ExtendTemplate {}; +} +%} + +%extend Space::ExtendTemplate +{ + void extending() { $parentclassname tmp; } +} + +%template(ExtendTemplateInt) Space::ExtendTemplate; diff --git a/Source/Swig/cwrap.c b/Source/Swig/cwrap.c index d15c2e12f..c97640b08 100644 --- a/Source/Swig/cwrap.c +++ b/Source/Swig/cwrap.c @@ -869,7 +869,7 @@ void Swig_replace_special_variables(Node *n, Node *parentnode, String *code) { String *parentclassname = 0; if (parentclass) parentclassname = Getattr(parentclass, "name"); - Replaceall(code, "$parentclassname", parentclassname ? parentclassname : ""); + Replaceall(code, "$parentclassname", parentclassname ? SwigType_str(parentclassname, "") : ""); } } -- cgit v1.2.1 From ecdf692fc86e3ec76ed18c6024a11f28a9b27381 Mon Sep 17 00:00:00 2001 From: Mathieu Monney Date: Wed, 2 Jul 2014 11:27:27 +0200 Subject: Fixed JSClassRef declaration not using the static one The class descriptor is not assigned to the static variable but to a local one, which makes the global variable unused. --- Lib/javascript/jsc/javascriptcode.swg | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Lib/javascript/jsc/javascriptcode.swg b/Lib/javascript/jsc/javascriptcode.swg index c18902fce..672df8677 100644 --- a/Lib/javascript/jsc/javascriptcode.swg +++ b/Lib/javascript/jsc/javascriptcode.swg @@ -354,7 +354,7 @@ static JSStaticFunction $jsmangledname_functions[] = { $jsmangledname_objectDefinition.staticValues = $jsmangledname_values; $jsmangledname_objectDefinition.staticFunctions = $jsmangledname_functions; $jsclass_inheritance - JSClassRef $jsmangledname_classRef = JSClassCreate(&$jsmangledname_objectDefinition); + $jsmangledname_classRef = JSClassCreate(&$jsmangledname_objectDefinition); SWIGTYPE_$jsmangledtype->clientdata = $jsmangledname_classRef; %} -- cgit v1.2.1 From 287e84d84c38950c71706533a6aac0a769a107f9 Mon Sep 17 00:00:00 2001 From: Ian Lance Taylor Date: Mon, 14 Jul 2014 08:33:43 -0700 Subject: [Go] Change struct definition to use void *, not uint8, so that the type is recorded as possibly containing pointers. This ensures that the 1.3 garbage collector does not collect pointers passed to C++ code. --- CHANGES.current | 6 ++++++ Source/Modules/go.cxx | 4 ++-- 2 files changed, 8 insertions(+), 2 deletions(-) diff --git a/CHANGES.current b/CHANGES.current index d3015a0ba..d3d461adc 100644 --- a/CHANGES.current +++ b/CHANGES.current @@ -5,6 +5,12 @@ See the RELEASENOTES file for a summary of changes in each release. Version 3.0.3 (in progress) =========================== +2014-07-14: ianlancetaylor + [Go] Change struct definition to use void *, not uint8, so + that the type is recorded as possibly containing + pointers. This ensures that the 1.3 garbage collector + does not collect pointers passed to C++ code. + 2014-07-01: wsfulton Fix SF Bug #1375 - Expansion of the $parentclassname special variable incorrectly contains brackets in the expanded name. diff --git a/Source/Modules/go.cxx b/Source/Modules/go.cxx index e84109faf..2de066b5d 100644 --- a/Source/Modules/go.cxx +++ b/Source/Modules/go.cxx @@ -1206,7 +1206,7 @@ private: } if (Len(parm_size) == 0) { - Append(parm_size, "1"); + Append(parm_size, "SWIG_PARM_SIZE"); } String *fn_name; @@ -1220,7 +1220,7 @@ private: } // \xc2\xb7 is UTF-8 for U+00B7 which is Unicode 'Middle Dot' - Printv(f->def, "\xc2\xb7", fn_name, "(struct { uint8 x[", parm_size, "];} p)", NULL); + Printv(f->def, "\xc2\xb7", fn_name, "(struct { void *x[(", parm_size, ") / SWIG_PARM_SIZE];} p)", NULL); Delete(fn_name); Delete(parm_size); -- cgit v1.2.1 From 093fe2a556d242cf930e79348dcece3ec8c78e6f Mon Sep 17 00:00:00 2001 From: Yuval Kashtan Date: Fri, 18 Jul 2014 15:45:16 +0300 Subject: Add support for java.nio.Buffer including test-suite test case and documentation --- Doc/Manual/Java.html | 9 ++++++ .../test-suite/java/java_lib_various_runme.java | 19 +++++++++++ Examples/test-suite/java_lib_various.i | 4 +++ Lib/java/various.i | 37 ++++++++++++++++++++++ 4 files changed, 69 insertions(+) diff --git a/Doc/Manual/Java.html b/Doc/Manual/Java.html index fb8e5d694..5e87e835e 100644 --- a/Doc/Manual/Java.html +++ b/Doc/Manual/Java.html @@ -5490,6 +5490,15 @@ These are listed below: Use for mapping NULL terminated arrays of C strings to Java String arrays + +unsigned char * +NIOBUFFER +various.i +input
      output +java.nio.Buffer +Use for mapping directly allocated buffers to c/c++. useful with directors and long lived memory objects + +

      25.9.6 Java typemap attributes

      diff --git a/Examples/test-suite/java/java_lib_various_runme.java b/Examples/test-suite/java/java_lib_various_runme.java index 203a30ec2..6d9e13e31 100644 --- a/Examples/test-suite/java/java_lib_various_runme.java +++ b/Examples/test-suite/java/java_lib_various_runme.java @@ -83,6 +83,25 @@ public class java_lib_various_runme { if (byjove[i] != b[i]) throw new RuntimeException("By jove, it failed: [" + new String(b) + "]"); } + + // NIOBUFFER typemap check + java.nio.ByteBuffer buf = java.nio.ByteBuffer.allocateDirect(10); + java_lib_various.niobuffer_fill_hello(buf); + if ( + (char)buf.get(0) != 'h' || + (char)buf.get(1) != 'e' || + (char)buf.get(2) != 'l' || + (char)buf.get(3) != 'l' || + (char)buf.get(4) != 'o' + ) + throw new RuntimeException( + "nio test failed: " + + (char)buf.get(0) + + (char)buf.get(1) + + (char)buf.get(2) + + (char)buf.get(3) + + (char)buf.get(4) + ); } } diff --git a/Examples/test-suite/java_lib_various.i b/Examples/test-suite/java_lib_various.i index 716ae9139..180d07569 100644 --- a/Examples/test-suite/java_lib_various.i +++ b/Examples/test-suite/java_lib_various.i @@ -8,6 +8,7 @@ %apply char **STRING_ARRAY { char **languages }; %apply char *BYTE { char *chars }; %apply char **STRING_OUT { char **string_ptr }; +%apply unsigned char *NIOBUFFER { unsigned char *buf }; %typemap(freearg) char **languages "" // don't delete memory when setting global variable %{ @@ -47,5 +48,8 @@ void char_ptr_ptr_out(char **string_ptr) { *string_ptr = ret; } +void niobuffer_fill_hello(unsigned char *buf) { + sprintf ((char*)buf,"hello"); +} %} diff --git a/Lib/java/various.i b/Lib/java/various.i index 7ba7a5eb3..47782586a 100644 --- a/Lib/java/various.i +++ b/Lib/java/various.i @@ -154,3 +154,40 @@ /* Prevent default freearg typemap from being used */ %typemap(freearg) char *BYTE "" +/* + * unsigned char *NIOBUFFER typemaps. + * This is for mapping java nio buffers to c char array. it is useful for long standing pointers for callbacks + * and wherever performance is critical (and thus memory copy + marshaling is a burdon) + * Note: The Java buffer have to be allocated with allocateDirect. + * + * Example usage wrapping: + * void foo(unsigned char *buf); + * + * Java usage: + * byte b[] = new byte[20]A; + * java.nio.ByteBuffer b = ByteBuffer.allocateDirect(); + * modulename.foo(b); + */ +%typemap(jni) unsigned char *NIOBUFFER "jobject" +%typemap(jtype) unsigned char *NIOBUFFER "java.nio.ByteBuffer" +%typemap(jstype) unsigned char *NIOBUFFER "java.nio.ByteBuffer" +%typemap(javain, + pre=" assert $javainput.isDirect() : \"Buffer must be allocated direct.\";") unsigned char *NIOBUFFER "$javainput" +%typemap(javaout) unsigned char *NIOBUFFER { + return $jnicall; +} +%typemap(in) unsigned char *NIOBUFFER { + $1 = (unsigned char *) JCALL1(GetDirectBufferAddress, jenv, $input); + if ($1 == NULL) { + SWIG_JavaThrowException(jenv, SWIG_JavaRuntimeException, "Unable to get address of direct buffer. Buffer must be allocated direct."); + } +} +%typemap(memberin) unsigned char *NIOBUFFER { + if ($input) { + $1 = $input; + } else { + $1 = 0; + } +} +%typemap(freearg) unsigned char *NIOBUFFER "" +//define end -- cgit v1.2.1 From 84335398494816d03cf6219209f7c66c035caa28 Mon Sep 17 00:00:00 2001 From: gpetrou Date: Thu, 31 Jul 2014 20:07:29 +0100 Subject: Changed CSharp license header to include auto-generated tag so that StyleCop ignores the files. --- Source/Modules/csharp.cxx | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/Source/Modules/csharp.cxx b/Source/Modules/csharp.cxx index d30bd18c5..2cacbd148 100644 --- a/Source/Modules/csharp.cxx +++ b/Source/Modules/csharp.cxx @@ -627,9 +627,10 @@ public: * ----------------------------------------------------------------------------- */ void emitBanner(File *f) { - Printf(f, "/* ----------------------------------------------------------------------------\n"); - Swig_banner_target_lang(f, " *"); - Printf(f, " * ----------------------------------------------------------------------------- */\n\n"); + Printf(f, "//------------------------------------------------------------------------------\n"); + Printf(f, "// \n\n"); + Swig_banner_target_lang(f, "//"); + Printf(f, "//------------------------------------------------------------------------------\n\n"); } /*----------------------------------------------------------------------- -- cgit v1.2.1 From 17737260736ae2b9096cc4b1076db8986e95fe15 Mon Sep 17 00:00:00 2001 From: William S Fulton Date: Mon, 4 Aug 2014 19:22:02 +0100 Subject: Doc/comment improvements in Java various.i --- Lib/java/various.i | 15 ++++++++------- 1 file changed, 8 insertions(+), 7 deletions(-) diff --git a/Lib/java/various.i b/Lib/java/various.i index 47782586a..bfcf346d3 100644 --- a/Lib/java/various.i +++ b/Lib/java/various.i @@ -92,6 +92,7 @@ * The returned string appears in the 1st element of the passed in Java String array. * * Example usage wrapping: + * %apply char **STRING_OUT { char **string_out }; * void foo(char **string_out); * * Java usage: @@ -156,16 +157,16 @@ /* * unsigned char *NIOBUFFER typemaps. - * This is for mapping java nio buffers to c char array. it is useful for long standing pointers for callbacks - * and wherever performance is critical (and thus memory copy + marshaling is a burdon) - * Note: The Java buffer have to be allocated with allocateDirect. + * This is for mapping Java nio buffers to C char arrays. + * It is useful for performance critical code as it reduces the memory copy an marshaling overhead. + * Note: The Java buffer has to be allocated with allocateDirect. * * Example usage wrapping: + * %apply unsigned char *NIOBUFFER { unsigned char *buf }; * void foo(unsigned char *buf); * * Java usage: - * byte b[] = new byte[20]A; - * java.nio.ByteBuffer b = ByteBuffer.allocateDirect(); + * java.nio.ByteBuffer b = ByteBuffer.allocateDirect(20); * modulename.foo(b); */ %typemap(jni) unsigned char *NIOBUFFER "jobject" @@ -179,7 +180,7 @@ %typemap(in) unsigned char *NIOBUFFER { $1 = (unsigned char *) JCALL1(GetDirectBufferAddress, jenv, $input); if ($1 == NULL) { - SWIG_JavaThrowException(jenv, SWIG_JavaRuntimeException, "Unable to get address of direct buffer. Buffer must be allocated direct."); + SWIG_JavaThrowException(jenv, SWIG_JavaRuntimeException, "Unable to get address of a java.nio.ByteBuffer direct byte buffer. Buffer must be a direct buffer and not a non-direct buffer."); } } %typemap(memberin) unsigned char *NIOBUFFER { @@ -190,4 +191,4 @@ } } %typemap(freearg) unsigned char *NIOBUFFER "" -//define end + -- cgit v1.2.1 From db7514860d6c44b664356e54676d6bb0027b8048 Mon Sep 17 00:00:00 2001 From: William S Fulton Date: Mon, 4 Aug 2014 19:27:30 +0100 Subject: Add changes entry for NIOBUFFER Java typemaps --- CHANGES.current | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/CHANGES.current b/CHANGES.current index d3d461adc..d6b7e8d37 100644 --- a/CHANGES.current +++ b/CHANGES.current @@ -5,6 +5,10 @@ See the RELEASENOTES file for a summary of changes in each release. Version 3.0.3 (in progress) =========================== +2014-08-04: wsfulton + [Java] Merge patch #198 from Yuval Kashtan - Support for java.nio.ByteBuffer mapping to + unsigned char * in various.i in NIOBUFFER typemaps. + 2014-07-14: ianlancetaylor [Go] Change struct definition to use void *, not uint8, so that the type is recorded as possibly containing -- cgit v1.2.1 From 69736cc0cb018aa3934090ef3d7fcbcf4b1aa21b Mon Sep 17 00:00:00 2001 From: William S Fulton Date: Mon, 4 Aug 2014 19:41:38 +0100 Subject: Tweak generated C# .cs files header --- Source/Modules/csharp.cxx | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/Source/Modules/csharp.cxx b/Source/Modules/csharp.cxx index 2cacbd148..df4486d1d 100644 --- a/Source/Modules/csharp.cxx +++ b/Source/Modules/csharp.cxx @@ -628,7 +628,8 @@ public: void emitBanner(File *f) { Printf(f, "//------------------------------------------------------------------------------\n"); - Printf(f, "// \n\n"); + Printf(f, "// \n"); + Printf(f, "//\n"); Swig_banner_target_lang(f, "//"); Printf(f, "//------------------------------------------------------------------------------\n\n"); } -- cgit v1.2.1 From 2b71c99feb387f6b89784155020af050f6a3096e Mon Sep 17 00:00:00 2001 From: William S Fulton Date: Mon, 4 Aug 2014 19:44:47 +0100 Subject: Add C# license header changes for StyleCop to changes file --- CHANGES.current | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/CHANGES.current b/CHANGES.current index d6b7e8d37..97f55bef6 100644 --- a/CHANGES.current +++ b/CHANGES.current @@ -5,6 +5,10 @@ See the RELEASENOTES file for a summary of changes in each release. Version 3.0.3 (in progress) =========================== +2014-08-04: wsfulton + [C#] Merge patch #200 from gpetrou - Changed CSharp license header to include auto-generated + tag so that StyleCop ignores the files. + 2014-08-04: wsfulton [Java] Merge patch #198 from Yuval Kashtan - Support for java.nio.ByteBuffer mapping to unsigned char * in various.i in NIOBUFFER typemaps. -- cgit v1.2.1 From 07e2568a2087f095020f6ffed6fe92d4f6ee8162 Mon Sep 17 00:00:00 2001 From: Vadim Zeitlin Date: Sun, 10 Aug 2014 14:40:35 +0200 Subject: Remove long line wrapping from Python parameter list generation code. This doesn't play well with PEP8 checks which imposes very strict continuation line indentation rules which need to be _visually_ aligned, i.e. the subsequent lines must be indented by the position of the opening bracket in the function declaration line, but the code generating the parameter lists doesn't have this information and so it's impossible to do it while avoiding either E128 or E123 ("continuation line {under,over}-indented for visual indent" respectively) error from pep8. Moreover, the wrapping code didn't work correctly anyhow as it only took into account the length of the parameter list itself and not the total line length, which should include the function name as well. So just disable wrapping entirely, long lines shouldn't be a problem anyhow in auto-generated code. --- Source/Modules/python.cxx | 8 -------- 1 file changed, 8 deletions(-) diff --git a/Source/Modules/python.cxx b/Source/Modules/python.cxx index c327dbc1c..59fc403d8 100644 --- a/Source/Modules/python.cxx +++ b/Source/Modules/python.cxx @@ -1563,9 +1563,7 @@ public: Parm *pnext; - int lines = 0; int start_arg_num = is_wrapping_class() ? 1 : 0; - const int maxwidth = 80; if (calling) func_annotation = false; @@ -1615,12 +1613,6 @@ public: if (Len(doc)) { // add a comma to the previous one if any Append(doc, ", "); - - // Do we need to wrap a long line? - if ((Len(doc) - lines * maxwidth) > maxwidth) { - Printf(doc, "\n%s", tab4); - lines += 1; - } } // Do the param type too? -- cgit v1.2.1 From e2b4a72f3eef07dfa471232604a9beba826f10c5 Mon Sep 17 00:00:00 2001 From: William S Fulton Date: Mon, 11 Aug 2014 19:12:05 +0100 Subject: Tcl documentation correction From Ben Golding on swig-devel list. --- Doc/Manual/Tcl.html | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Doc/Manual/Tcl.html b/Doc/Manual/Tcl.html index c12701ac9..d4bf91970 100644 --- a/Doc/Manual/Tcl.html +++ b/Doc/Manual/Tcl.html @@ -1283,7 +1283,7 @@ you can use it in Tcl like this: % x insert Lager % x get 1 Stout -% puts [l cget -length] +% puts [x cget -length] 3 % -- cgit v1.2.1 From b8d3ff060a3ef0c93417cd1dc1a76684549bc64e Mon Sep 17 00:00:00 2001 From: Ian Bell Date: Mon, 11 Aug 2014 20:46:49 +0200 Subject: Update Php.html Short summary of the fact that dl() function can no longer be used. --- Doc/Manual/Php.html | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/Doc/Manual/Php.html b/Doc/Manual/Php.html index 7e5cccf6a..3e7cf54db 100644 --- a/Doc/Manual/Php.html +++ b/Doc/Manual/Php.html @@ -115,7 +115,11 @@ The usual (and recommended) way is to build the extension as a separate dynamically loaded module (which is supported by all modern operating systems). You can then specify that this be loaded automatically in php.ini or load it explicitly for any script which -needs it. +needs it. As of version 5.3 of PHP, the dl() +function cannot be used and your only option is to +add to the php.ini something like + +extension = /usr/lib64/php/modules/mymodule.so

      -- cgit v1.2.1 From 227dd356090fb91bd2dd2b19534ce2b3daa22e1d Mon Sep 17 00:00:00 2001 From: Olly Betts Date: Tue, 12 Aug 2014 14:33:25 +1200 Subject: Fix incorrect examples of regex %rename --- CHANGES | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/CHANGES b/CHANGES index 37868d8fe..9fef3ae06 100644 --- a/CHANGES +++ b/CHANGES @@ -2088,8 +2088,8 @@ Version 2.0.2 (20 February 2011) Fix handling of multiple regex-using %renames attached to the same declaration. For example, now - %rename("%(regex/^Set(.*)/put\\1/)s") ""; - %rename("%(regex/^Get(.*)/get\\1/)s") ""; + %rename("%(regex:/^Set(.*)/put\\1/)s") ""; + %rename("%(regex:/^Get(.*)/get\\1/)s") ""; works as expected whereas before only the last anonymous rename was taken into account. -- cgit v1.2.1 From c43f84af025b3059e1e76c53c3d4093d2fd7487d Mon Sep 17 00:00:00 2001 From: Olly Betts Date: Tue, 12 Aug 2014 14:45:54 +1200 Subject: Improve PHP docs about extension= and dl() --- Doc/Manual/Php.html | 38 ++++++++++++++++++++++++-------------- 1 file changed, 24 insertions(+), 14 deletions(-) diff --git a/Doc/Manual/Php.html b/Doc/Manual/Php.html index 3e7cf54db..cc03f7498 100644 --- a/Doc/Manual/Php.html +++ b/Doc/Manual/Php.html @@ -113,13 +113,7 @@ more detail in section 27.2.6.

      The usual (and recommended) way is to build the extension as a separate dynamically loaded module (which is supported by all modern operating -systems). You can then specify that this be loaded -automatically in php.ini or load it explicitly for any script which -needs it. As of version 5.3 of PHP, the dl() -function cannot be used and your only option is to -add to the php.ini something like - -extension = /usr/lib64/php/modules/mymodule.so +systems).

      @@ -147,10 +141,9 @@ least work for Linux though):

      34.1.2 Using PHP Extensions

      -

      -To test the extension from a PHP script, you need to load it first. You -can load it for every script by adding this line to the [PHP] section of +To test the extension from a PHP script, you first need to load tell PHP to +load it. To do this, add a line like this to the [PHP] section of php.ini:

      @@ -159,8 +152,14 @@ can load it for every script by adding this line to the [PHP] section o

      -Alternatively, you can load it explicitly only for scripts which need it -by adding this line to the start of each such PHP script:: +If the module is in PHP's default extension directory, you can omit the path. +

      + +

      +For some SAPIs (for example, the CLI SAPI) you can instead use the +dl() function to load +an extension at run time, by adding a like like this to the start of each +PHP script which uses your extension:

      @@ -168,14 +167,25 @@ by adding this line to the start of each such PHP script::
       

      -SWIG also generates a php module, which -attempts to do the dl() call for you: +But note that this doesn't work when running PHP through a webserver in PHP5.3 +and later - you'll need to use extension in php.ini as +described above. +

      + +

      +The PHP module which SWIG generates will also attempt to do the dl() +call for you if the extension isn't already loaded:

       	include("example.php");
       
      +

      +This PHP module also defines the PHP classes for the wrapped API, so you'll +almost certainly want to include it anyway. +

      +

      34.2 Basic PHP interface

      -- cgit v1.2.1 From 2b2260e9960996654815a6d23bf632ffb57a156c Mon Sep 17 00:00:00 2001 From: Timothee Cour Date: Tue, 12 Aug 2014 09:11:10 -0700 Subject: _ --- Lib/d/dhead.swg | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/Lib/d/dhead.swg b/Lib/d/dhead.swg index 7a2f4fddc..9f950c60f 100644 --- a/Lib/d/dhead.swg +++ b/Lib/d/dhead.swg @@ -227,7 +227,8 @@ public: m_sPendingException = e; synchronized { - ++m_sPendingCount; + import core.atomic; + core.atomic.atomicOp!"+="(m_sPendingCount, 1); } } @@ -238,7 +239,8 @@ public: e = m_sPendingException; m_sPendingException = null; synchronized { - --m_sPendingCount; + import core.atomic; + core.atomic.atomicOp!"-="(m_sPendingCount, 1); } } } -- cgit v1.2.1 From 1dd297ad9df262c81ddcd1ebd4787b260e26313d Mon Sep 17 00:00:00 2001 From: Johan Hake Date: Tue, 12 Aug 2014 21:48:26 +0200 Subject: Fix issue with relative import when using single header file import. -- The commit propagates the package option to the newly create module node so it is recognized by SWIG -- Added a relativeimport test for this combination (in lack of py3 I was not able to test it with py3 but it "should just work") --- .../import_packages/relativeimport3/Makefile | 25 ++++++++++++++++++++++ .../python/import_packages/relativeimport3/README | 22 +++++++++++++++++++ .../import_packages/relativeimport3/py2/Makefile | 14 ++++++++++++ .../relativeimport3/py2/__init__.py | 0 .../relativeimport3/py2/pkg2/Makefile | 18 ++++++++++++++++ .../relativeimport3/py2/pkg2/__init__.py | 0 .../relativeimport3/py2/pkg2/bar.hpp | 5 +++++ .../import_packages/relativeimport3/py2/pkg2/bar.i | 6 ++++++ .../relativeimport3/py2/pkg2/pkg3/Makefile | 15 +++++++++++++ .../relativeimport3/py2/pkg2/pkg3/__init__.py | 0 .../relativeimport3/py2/pkg2/pkg3/foo.hpp | 4 ++++ .../relativeimport3/py2/pkg2/pkg3/foo.i | 5 +++++ .../import_packages/relativeimport3/py3/Makefile | 14 ++++++++++++ .../relativeimport3/py3/__init__.py | 0 .../relativeimport3/py3/pkg2/Makefile | 18 ++++++++++++++++ .../relativeimport3/py3/pkg2/__init__.py | 0 .../relativeimport3/py3/pkg2/bar.hpp | 5 +++++ .../import_packages/relativeimport3/py3/pkg2/bar.i | 6 ++++++ .../relativeimport3/py3/pkg2/pkg3/Makefile | 15 +++++++++++++ .../relativeimport3/py3/pkg2/pkg3/__init__.py | 0 .../relativeimport3/py3/pkg2/pkg3/foo.hpp | 4 ++++ .../relativeimport3/py3/pkg2/pkg3/foo.i | 5 +++++ .../import_packages/relativeimport3/runme.py | 9 ++++++++ 23 files changed, 190 insertions(+) create mode 100644 Examples/python/import_packages/relativeimport3/Makefile create mode 100644 Examples/python/import_packages/relativeimport3/README create mode 100644 Examples/python/import_packages/relativeimport3/py2/Makefile create mode 100644 Examples/python/import_packages/relativeimport3/py2/__init__.py create mode 100644 Examples/python/import_packages/relativeimport3/py2/pkg2/Makefile create mode 100644 Examples/python/import_packages/relativeimport3/py2/pkg2/__init__.py create mode 100644 Examples/python/import_packages/relativeimport3/py2/pkg2/bar.hpp create mode 100644 Examples/python/import_packages/relativeimport3/py2/pkg2/bar.i create mode 100644 Examples/python/import_packages/relativeimport3/py2/pkg2/pkg3/Makefile create mode 100644 Examples/python/import_packages/relativeimport3/py2/pkg2/pkg3/__init__.py create mode 100644 Examples/python/import_packages/relativeimport3/py2/pkg2/pkg3/foo.hpp create mode 100644 Examples/python/import_packages/relativeimport3/py2/pkg2/pkg3/foo.i create mode 100644 Examples/python/import_packages/relativeimport3/py3/Makefile create mode 100644 Examples/python/import_packages/relativeimport3/py3/__init__.py create mode 100644 Examples/python/import_packages/relativeimport3/py3/pkg2/Makefile create mode 100644 Examples/python/import_packages/relativeimport3/py3/pkg2/__init__.py create mode 100644 Examples/python/import_packages/relativeimport3/py3/pkg2/bar.hpp create mode 100644 Examples/python/import_packages/relativeimport3/py3/pkg2/bar.i create mode 100644 Examples/python/import_packages/relativeimport3/py3/pkg2/pkg3/Makefile create mode 100644 Examples/python/import_packages/relativeimport3/py3/pkg2/pkg3/__init__.py create mode 100644 Examples/python/import_packages/relativeimport3/py3/pkg2/pkg3/foo.hpp create mode 100644 Examples/python/import_packages/relativeimport3/py3/pkg2/pkg3/foo.i create mode 100644 Examples/python/import_packages/relativeimport3/runme.py diff --git a/Examples/python/import_packages/relativeimport3/Makefile b/Examples/python/import_packages/relativeimport3/Makefile new file mode 100644 index 000000000..b9d803a0e --- /dev/null +++ b/Examples/python/import_packages/relativeimport3/Makefile @@ -0,0 +1,25 @@ +TOP = ../../.. +SWIG = $(realpath $(TOP)/../preinst-swig) +SWIGOPT = +LIBS = +PY3 = + +ifeq (,$(PY3)) + PKG1DIR = "py2" +else + PKG1DIR = "py3" +endif + +check: build + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' python_run + +build: + cd $(PKG1DIR) && $(MAKE) SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT) -relativeimport' LIBS='$(LIBS)' build + +static: + cd $(PKG1DIR) && $(MAKE) SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT) -relativeimport' LIBS='$(LIBS)' static + +clean: + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' python_clean + cd py2 && $(MAKE) clean + cd py3 && $(MAKE) clean diff --git a/Examples/python/import_packages/relativeimport3/README b/Examples/python/import_packages/relativeimport3/README new file mode 100644 index 000000000..a99ef2426 --- /dev/null +++ b/Examples/python/import_packages/relativeimport3/README @@ -0,0 +1,22 @@ +This example tests the %import directive and -relativeimport swig option. + +Use 'python runme.py' to run a test. + +Overview: +--------- + +The example defines 2 different extension modules--each wrapping a separate C++ +class. + + pyX/pkg2/pkg3/foo.i - Pkg3_Foo class + pyX/pkg2/bar.i - Pkg2_Bar class derived from Pkg3_Foo + +The code is processed by swig with -relativeimport flag. The runtime test +imports pyX.pkg2.bar module. + +If everything works well, the module pyX.pkg2.bar shall load properly. + +Unix: +----- +- Run make +- Run the test as described above diff --git a/Examples/python/import_packages/relativeimport3/py2/Makefile b/Examples/python/import_packages/relativeimport3/py2/Makefile new file mode 100644 index 000000000..9595397d8 --- /dev/null +++ b/Examples/python/import_packages/relativeimport3/py2/Makefile @@ -0,0 +1,14 @@ +TOP = ../../../.. +SWIG = $(realpath $(TOP)/../preinst-swig) +SWIGOPT = +LIBS = + +build: + cd pkg2 && $(MAKE) SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT)' LIBS='$(LIBS)' build + +static: + cd pkg2 && $(MAKE) SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT)' LIBS='$(LIBS)' static + +clean: + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' python_clean + cd pkg2 && $(MAKE) clean diff --git a/Examples/python/import_packages/relativeimport3/py2/__init__.py b/Examples/python/import_packages/relativeimport3/py2/__init__.py new file mode 100644 index 000000000..e69de29bb diff --git a/Examples/python/import_packages/relativeimport3/py2/pkg2/Makefile b/Examples/python/import_packages/relativeimport3/py2/pkg2/Makefile new file mode 100644 index 000000000..36e099b78 --- /dev/null +++ b/Examples/python/import_packages/relativeimport3/py2/pkg2/Makefile @@ -0,0 +1,18 @@ +TOP = ../../../../.. +SWIG = $(realpath $(TOP)/../preinst-swig) +SWIGOPT = +LIBS = + +build: + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT)' \ + LIBS='$(LIBS)' TARGET='bar' INTERFACE='bar.i' python_cpp + cd pkg3 && $(MAKE) SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT)' LIBS='$(LIBS)' build + +static: + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT)' \ + LIBS='$(LIBS)' TARGET='bar' INTERFACE='bar.i' python_cpp + cd pkg3 && $(MAKE) SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT)' LIBS='$(LIBS)' static + +clean: + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' TARGET='bar' python_clean + cd pkg3 && $(MAKE) clean diff --git a/Examples/python/import_packages/relativeimport3/py2/pkg2/__init__.py b/Examples/python/import_packages/relativeimport3/py2/pkg2/__init__.py new file mode 100644 index 000000000..e69de29bb diff --git a/Examples/python/import_packages/relativeimport3/py2/pkg2/bar.hpp b/Examples/python/import_packages/relativeimport3/py2/pkg2/bar.hpp new file mode 100644 index 000000000..8f09cd5fa --- /dev/null +++ b/Examples/python/import_packages/relativeimport3/py2/pkg2/bar.hpp @@ -0,0 +1,5 @@ +#ifndef PY2_PKG2_BAR_HPP +#define PY2_PKG2_BAR_HPP +#include "../../py2/pkg2/pkg3/foo.hpp" +struct Pkg2_Bar : Pkg3_Foo {}; +#endif /* PY2_PKG2_BAR_HPP */ diff --git a/Examples/python/import_packages/relativeimport3/py2/pkg2/bar.i b/Examples/python/import_packages/relativeimport3/py2/pkg2/bar.i new file mode 100644 index 000000000..6f4690b25 --- /dev/null +++ b/Examples/python/import_packages/relativeimport3/py2/pkg2/bar.i @@ -0,0 +1,6 @@ +%module(package="py2.pkg2") bar +%{ +#include "../../py2/pkg2/bar.hpp" +%} +%import (module="foo", package="py2.pkg2.pkg3") "../../py2/pkg2/pkg3/foo.hpp" +%include "../../py2/pkg2/bar.hpp" diff --git a/Examples/python/import_packages/relativeimport3/py2/pkg2/pkg3/Makefile b/Examples/python/import_packages/relativeimport3/py2/pkg2/pkg3/Makefile new file mode 100644 index 000000000..cb20bd25f --- /dev/null +++ b/Examples/python/import_packages/relativeimport3/py2/pkg2/pkg3/Makefile @@ -0,0 +1,15 @@ +TOP = ../../../../../.. +SWIG = $(realpath $(TOP)/../preinst-swig) +SWIGOPT = +LIBS = + +build: + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT)' \ + LIBS='$(LIBS)' TARGET='foo' INTERFACE='foo.i' python_cpp + +static: + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT)' \ + LIBS='$(LIBS)' TARGET='foo' INTERFACE='foo.i' python_cpp_static + +clean: + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' TARGET='foo' python_clean diff --git a/Examples/python/import_packages/relativeimport3/py2/pkg2/pkg3/__init__.py b/Examples/python/import_packages/relativeimport3/py2/pkg2/pkg3/__init__.py new file mode 100644 index 000000000..e69de29bb diff --git a/Examples/python/import_packages/relativeimport3/py2/pkg2/pkg3/foo.hpp b/Examples/python/import_packages/relativeimport3/py2/pkg2/pkg3/foo.hpp new file mode 100644 index 000000000..b6c89a431 --- /dev/null +++ b/Examples/python/import_packages/relativeimport3/py2/pkg2/pkg3/foo.hpp @@ -0,0 +1,4 @@ +#ifndef PY2_PKG2_PKG3_FOO_HPP +#define PY2_PKG2_PKG3_FOO_HPP +struct Pkg3_Foo {}; +#endif /* PY2_PKG2_PKG3_FOO_HPP */ diff --git a/Examples/python/import_packages/relativeimport3/py2/pkg2/pkg3/foo.i b/Examples/python/import_packages/relativeimport3/py2/pkg2/pkg3/foo.i new file mode 100644 index 000000000..ba32483d2 --- /dev/null +++ b/Examples/python/import_packages/relativeimport3/py2/pkg2/pkg3/foo.i @@ -0,0 +1,5 @@ +%module(package="py2.pkg2.pkg3") foo +%{ +#include "../../../py2/pkg2/pkg3/foo.hpp" +%} +%include "../../../py2/pkg2/pkg3/foo.hpp" diff --git a/Examples/python/import_packages/relativeimport3/py3/Makefile b/Examples/python/import_packages/relativeimport3/py3/Makefile new file mode 100644 index 000000000..9595397d8 --- /dev/null +++ b/Examples/python/import_packages/relativeimport3/py3/Makefile @@ -0,0 +1,14 @@ +TOP = ../../../.. +SWIG = $(realpath $(TOP)/../preinst-swig) +SWIGOPT = +LIBS = + +build: + cd pkg2 && $(MAKE) SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT)' LIBS='$(LIBS)' build + +static: + cd pkg2 && $(MAKE) SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT)' LIBS='$(LIBS)' static + +clean: + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' python_clean + cd pkg2 && $(MAKE) clean diff --git a/Examples/python/import_packages/relativeimport3/py3/__init__.py b/Examples/python/import_packages/relativeimport3/py3/__init__.py new file mode 100644 index 000000000..e69de29bb diff --git a/Examples/python/import_packages/relativeimport3/py3/pkg2/Makefile b/Examples/python/import_packages/relativeimport3/py3/pkg2/Makefile new file mode 100644 index 000000000..36e099b78 --- /dev/null +++ b/Examples/python/import_packages/relativeimport3/py3/pkg2/Makefile @@ -0,0 +1,18 @@ +TOP = ../../../../.. +SWIG = $(realpath $(TOP)/../preinst-swig) +SWIGOPT = +LIBS = + +build: + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT)' \ + LIBS='$(LIBS)' TARGET='bar' INTERFACE='bar.i' python_cpp + cd pkg3 && $(MAKE) SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT)' LIBS='$(LIBS)' build + +static: + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT)' \ + LIBS='$(LIBS)' TARGET='bar' INTERFACE='bar.i' python_cpp + cd pkg3 && $(MAKE) SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT)' LIBS='$(LIBS)' static + +clean: + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' TARGET='bar' python_clean + cd pkg3 && $(MAKE) clean diff --git a/Examples/python/import_packages/relativeimport3/py3/pkg2/__init__.py b/Examples/python/import_packages/relativeimport3/py3/pkg2/__init__.py new file mode 100644 index 000000000..e69de29bb diff --git a/Examples/python/import_packages/relativeimport3/py3/pkg2/bar.hpp b/Examples/python/import_packages/relativeimport3/py3/pkg2/bar.hpp new file mode 100644 index 000000000..408d910d7 --- /dev/null +++ b/Examples/python/import_packages/relativeimport3/py3/pkg2/bar.hpp @@ -0,0 +1,5 @@ +#ifndef PY3_PKG2_BAR_HPP +#define PY3_PKG2_BAR_HPP +#include "../../py3/pkg2/pkg3/foo.hpp" +struct Pkg2_Bar : Pkg3_Foo {}; +#endif /* PY3_PKG2_BAR_HPP */ diff --git a/Examples/python/import_packages/relativeimport3/py3/pkg2/bar.i b/Examples/python/import_packages/relativeimport3/py3/pkg2/bar.i new file mode 100644 index 000000000..157c62e2c --- /dev/null +++ b/Examples/python/import_packages/relativeimport3/py3/pkg2/bar.i @@ -0,0 +1,6 @@ +%module(package="py3.pkg2") bar +%{ +#include "../../py3/pkg2/bar.hpp" +%} +%import (module="foo", package="py3.pkg2.pkg3") "../../py3/pkg2/pkg3/foo.hpp" +%include "../../py3/pkg2/bar.hpp" diff --git a/Examples/python/import_packages/relativeimport3/py3/pkg2/pkg3/Makefile b/Examples/python/import_packages/relativeimport3/py3/pkg2/pkg3/Makefile new file mode 100644 index 000000000..cb20bd25f --- /dev/null +++ b/Examples/python/import_packages/relativeimport3/py3/pkg2/pkg3/Makefile @@ -0,0 +1,15 @@ +TOP = ../../../../../.. +SWIG = $(realpath $(TOP)/../preinst-swig) +SWIGOPT = +LIBS = + +build: + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT)' \ + LIBS='$(LIBS)' TARGET='foo' INTERFACE='foo.i' python_cpp + +static: + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT)' \ + LIBS='$(LIBS)' TARGET='foo' INTERFACE='foo.i' python_cpp_static + +clean: + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' TARGET='foo' python_clean diff --git a/Examples/python/import_packages/relativeimport3/py3/pkg2/pkg3/__init__.py b/Examples/python/import_packages/relativeimport3/py3/pkg2/pkg3/__init__.py new file mode 100644 index 000000000..e69de29bb diff --git a/Examples/python/import_packages/relativeimport3/py3/pkg2/pkg3/foo.hpp b/Examples/python/import_packages/relativeimport3/py3/pkg2/pkg3/foo.hpp new file mode 100644 index 000000000..531721d36 --- /dev/null +++ b/Examples/python/import_packages/relativeimport3/py3/pkg2/pkg3/foo.hpp @@ -0,0 +1,4 @@ +#ifndef PY3_PKG2_PKG3_FOO_HPP +#define PY3_PKG2_PKG3_FOO_HPP +struct Pkg3_Foo {}; +#endif /* PY3_PKG2_PKG3_FOO_HPP */ diff --git a/Examples/python/import_packages/relativeimport3/py3/pkg2/pkg3/foo.i b/Examples/python/import_packages/relativeimport3/py3/pkg2/pkg3/foo.i new file mode 100644 index 000000000..c6ba529b7 --- /dev/null +++ b/Examples/python/import_packages/relativeimport3/py3/pkg2/pkg3/foo.i @@ -0,0 +1,5 @@ +%module(package="py3.pkg2.pkg3") foo +%{ +#include "../../../py3/pkg2/pkg3/foo.hpp" +%} +%include "../../../py3/pkg2/pkg3/foo.hpp" diff --git a/Examples/python/import_packages/relativeimport3/runme.py b/Examples/python/import_packages/relativeimport3/runme.py new file mode 100644 index 000000000..44ce8d1c4 --- /dev/null +++ b/Examples/python/import_packages/relativeimport3/runme.py @@ -0,0 +1,9 @@ +# Test import of modules content from within __init__.py +print "Testing %module(package=...) with -relativeimport" +import sys +if sys.version_info < (3,0): + import py2.pkg2.bar + print " Finished importing py2.pkg2.bar" +else: + import py3.pkg2.bar + print " Finished importing py3.pkg2.bar" -- cgit v1.2.1 From f6b10f299f1339b646525a08754f5311b0a01e2d Mon Sep 17 00:00:00 2001 From: Kris Thielemans Date: Sun, 10 Aug 2014 22:23:50 +0100 Subject: small suggestions for changes in std_ios.i Hi Would it be possible to add the following 2 typedefs to std_ios.i? typedef basic_ios ios; typedef basic_ios wios; at present, it contains only %template(ios) basic_ios; %template(wios) basic_ios; This means however that things like std::ios::openmode are currently not recognised by SWIG. With the above typedefs, they are. Similar typedefs should probably be added in std_iostream.i for ostream etc. Also, while checking std_ios.i, it seems that the definition of basic_ios has a copy-paste error in the private section (the constructor is still as ios_base). To avoid confusion, I suggest to change that. Below is a diff with the suggested changes. Kris --- Lib/std/std_ios.i | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/Lib/std/std_ios.i b/Lib/std/std_ios.i index 75484f3de..db83c7abf 100644 --- a/Lib/std/std_ios.i +++ b/Lib/std/std_ios.i @@ -242,17 +242,19 @@ namespace std { // 27.4.5.1 basic_ios constructors basic_ios(); private: - ios_base(const ios_base&); + basic_ios(const basic_ios&); - ios_base& - operator=(const ios_base&); + basic_ios& + operator=(const basic_ios&); }; } namespace std { + typedef basic_ios ios; %template(ios) basic_ios; #if defined(SWIG_WCHAR) + typedef basic_ios wios; %template(wios) basic_ios; #endif } -- cgit v1.2.1 From 16549a36e3cac2b08c74abcffdbb58cd1757e989 Mon Sep 17 00:00:00 2001 From: Benoit Sigoure Date: Tue, 12 Aug 2014 23:44:50 -0700 Subject: Initialize C++ arrays created by array_functions' new_foo(). `array_functions(TYPE, NAME)' generates a `new_foo(size)' function that allocates a new array of the given type. When compiling in C, the array is initialized with `calloc()', which shows that the intent was to have the array be zero-initialized. When in C++, however, the array was not getting initialized, so it could contain random garbage after creation, when the type was a POD type. This change makes `new_foo(size)' create a value-initialized array when in C++, as per the C++ standard's 5.3.4.15 that says that adding a pair of parentheses at the end of a new-expression does that. --- Lib/carrays.i | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Lib/carrays.i b/Lib/carrays.i index f125105aa..201c17cac 100644 --- a/Lib/carrays.i +++ b/Lib/carrays.i @@ -22,7 +22,7 @@ %{ static TYPE *new_##NAME(int nelements) { %} #ifdef __cplusplus -%{ return new TYPE[nelements]; %} +%{ return new TYPE[nelements](); %} #else %{ return (TYPE *) calloc(nelements,sizeof(TYPE)); %} #endif -- cgit v1.2.1 From f38f6371a34a153531a7f8d5351de15621ed0387 Mon Sep 17 00:00:00 2001 From: Pingan Yi Date: Wed, 13 Aug 2014 16:14:52 +0800 Subject: fixup! Patch of http://sourceforge.net/p/swig/mailman/message/29816385 --- Lib/java/director.swg | 4 ++++ Lib/java/std_string.i | 6 ++++-- 2 files changed, 8 insertions(+), 2 deletions(-) diff --git a/Lib/java/director.swg b/Lib/java/director.swg index 7f0fd3933..24460676f 100644 --- a/Lib/java/director.swg +++ b/Lib/java/director.swg @@ -383,6 +383,10 @@ namespace Swig { class LocalRefGuard { JNIEnv* jenv_; jobject jobj_; + + // non-copyable + LocalRefGuard(const LocalRefGuard &); + LocalRefGuard &operator=(const LocalRefGuard &); public: LocalRefGuard(JNIEnv* jenv, jobject jobj): jenv_(jenv), jobj_(jobj) {} ~LocalRefGuard() { if (jobj_) jenv_->DeleteLocalRef(jobj_); } diff --git a/Lib/java/std_string.i b/Lib/java/std_string.i index 5ad7d30bc..322d0da12 100644 --- a/Lib/java/std_string.i +++ b/Lib/java/std_string.i @@ -49,7 +49,8 @@ class string; jenv->ReleaseStringUTFChars($input, $1_pstr); %} %typemap(directorin,descriptor="Ljava/lang/String;") string -%{ $input = jenv->NewStringUTF($1.c_str()); %} +%{ $input = jenv->NewStringUTF($1.c_str()); + Swig::LocalRefGuard refGuard_$input(jenv, $input); %} %typemap(out) string %{ $result = jenv->NewStringUTF($1.c_str()); %} @@ -98,7 +99,8 @@ class string; jenv->ReleaseStringUTFChars($input, $1_pstr); %} %typemap(directorin,descriptor="Ljava/lang/String;") const string & -%{ $input = jenv->NewStringUTF($1.c_str()); %} +%{ $input = jenv->NewStringUTF($1.c_str()); + Swig::LocalRefGuard refGuard_$input(jenv, $input); %} %typemap(out) const string & %{ $result = jenv->NewStringUTF($1->c_str()); %} -- cgit v1.2.1 From 54218bfe3f1988824df30af129d7d88429d34cb2 Mon Sep 17 00:00:00 2001 From: William S Fulton Date: Fri, 15 Aug 2014 19:01:13 +0100 Subject: C# exception %exception example fix From Cindy Gan [skip ci] --- Doc/Manual/CSharp.html | 1 + 1 file changed, 1 insertion(+) diff --git a/Doc/Manual/CSharp.html b/Doc/Manual/CSharp.html index 7f53423fc..ba49fa004 100644 --- a/Doc/Manual/CSharp.html +++ b/Doc/Manual/CSharp.html @@ -1075,6 +1075,7 @@ try { $action } catch (std::out_of_range e) { SWIG_CSharpSetPendingException(SWIG_CSharpApplicationException, e.what()); + return $null; } %} -- cgit v1.2.1 From 488aed4224d72d3025b03134bc9ce5de1b932fac Mon Sep 17 00:00:00 2001 From: Robert Stone Date: Fri, 15 Aug 2014 21:47:10 -0700 Subject: apply SF Patch #350 and add testcase --- CHANGES.current | 3 +++ Examples/test-suite/director_nestedmodule.i | 29 +++++++++++++++++++++++++++++ Examples/test-suite/perl5/Makefile.in | 1 + Source/Modules/perl5.cxx | 18 +++++++++--------- 4 files changed, 42 insertions(+), 9 deletions(-) create mode 100644 Examples/test-suite/director_nestedmodule.i diff --git a/CHANGES.current b/CHANGES.current index 97f55bef6..6ce431b60 100644 --- a/CHANGES.current +++ b/CHANGES.current @@ -5,6 +5,9 @@ See the RELEASENOTES file for a summary of changes in each release. Version 3.0.3 (in progress) =========================== +2014-08-15: talby + [Perl] Include guard fix for nested modules from Anthony Heading (SF Patch #350). + 2014-08-04: wsfulton [C#] Merge patch #200 from gpetrou - Changed CSharp license header to include auto-generated tag so that StyleCop ignores the files. diff --git a/Examples/test-suite/director_nestedmodule.i b/Examples/test-suite/director_nestedmodule.i new file mode 100644 index 000000000..4e304340f --- /dev/null +++ b/Examples/test-suite/director_nestedmodule.i @@ -0,0 +1,29 @@ +%module(directors="1") "director::nestedmodule" + +%{ +#include + +class Foo { + public: + virtual ~Foo() {} + virtual std::string ping() { return "Foo::ping()"; } + virtual std::string pong() { return "Foo::pong();" + ping(); } + + static Foo* get_self(Foo *slf) {return slf;} +}; + +%} + +%include + +%feature("director") Foo; + + +class Foo { + public: + virtual ~Foo(); + virtual std::string ping(); + virtual std::string pong(); + + static Foo* get_self(Foo *slf); +}; diff --git a/Examples/test-suite/perl5/Makefile.in b/Examples/test-suite/perl5/Makefile.in index a4628ddcb..ccd12d6e4 100644 --- a/Examples/test-suite/perl5/Makefile.in +++ b/Examples/test-suite/perl5/Makefile.in @@ -17,6 +17,7 @@ CPP_TEST_CASES += \ li_cstring \ li_cdata_carrays \ li_reference \ + director_nestedmodule \ C_TEST_CASES += \ li_cdata \ diff --git a/Source/Modules/perl5.cxx b/Source/Modules/perl5.cxx index ff504d461..c67ba554a 100644 --- a/Source/Modules/perl5.cxx +++ b/Source/Modules/perl5.cxx @@ -342,11 +342,18 @@ public: Node *options = Getattr(mod, "options"); module = Copy(Getattr(n,"name")); + String *underscore_module = Copy(module); + Replaceall(underscore_module,":","_"); + + if (verbose > 0) { + fprintf(stdout, "top: using namespace_module: %s\n", Char(namespace_module)); + } + if (directorsEnabled()) { Swig_banner(f_directors_h); Printf(f_directors_h, "\n"); - Printf(f_directors_h, "#ifndef SWIG_%s_WRAP_H_\n", module); - Printf(f_directors_h, "#define SWIG_%s_WRAP_H_\n\n", module); + Printf(f_directors_h, "#ifndef SWIG_%s_WRAP_H_\n", underscore_module); + Printf(f_directors_h, "#define SWIG_%s_WRAP_H_\n\n", underscore_module); if (dirprot_mode()) { Printf(f_directors_h, "#include \n"); Printf(f_directors_h, "#include \n\n"); @@ -379,13 +386,6 @@ public: fprintf(stdout, "top: No package found\n"); } } - String *underscore_module = Copy(module); - Replaceall(underscore_module,":","_"); - - if (verbose > 0) { - fprintf(stdout, "top: using namespace_module: %s\n", Char(namespace_module)); - } - /* If we're in blessed mode, change the package name to "packagec" */ if (blessed) { -- cgit v1.2.1 From 9f1af8921fe716923b6a8ca63a1116f2256cf849 Mon Sep 17 00:00:00 2001 From: Vadim Zeitlin Date: Sat, 16 Aug 2014 00:21:33 +0200 Subject: Refactor: move makeParameterName() to common Language base class. This method was duplicated more or less identically for 4 languages and will be needed for another one soon, so put it in the base class from which it can be simply reused instead. No changes in the program behaviour whatsoever. --- Source/Modules/csharp.cxx | 37 ------------------------------------- Source/Modules/d.cxx | 34 +--------------------------------- Source/Modules/java.cxx | 38 -------------------------------------- Source/Modules/lang.cxx | 38 ++++++++++++++++++++++++++++++++++++++ Source/Modules/modula3.cxx | 29 ----------------------------- Source/Modules/swigmod.h | 3 +++ 6 files changed, 42 insertions(+), 137 deletions(-) diff --git a/Source/Modules/csharp.cxx b/Source/Modules/csharp.cxx index df4486d1d..d94f96aee 100644 --- a/Source/Modules/csharp.cxx +++ b/Source/Modules/csharp.cxx @@ -3200,43 +3200,6 @@ public: Delete(replacementname); } - /* ----------------------------------------------------------------------------- - * makeParameterName() - * - * Inputs: - * n - Node - * p - parameter node - * arg_num - parameter argument number - * setter - set this flag when wrapping variables - * Return: - * arg - a unique parameter name - * ----------------------------------------------------------------------------- */ - - String *makeParameterName(Node *n, Parm *p, int arg_num, bool setter) { - - String *arg = 0; - String *pn = Getattr(p, "name"); - - // Use C parameter name unless it is a duplicate or an empty parameter name - int count = 0; - ParmList *plist = Getattr(n, "parms"); - while (plist) { - if ((Cmp(pn, Getattr(plist, "name")) == 0)) - count++; - plist = nextSibling(plist); - } - String *wrn = pn ? Swig_name_warning(p, 0, pn, 0) : 0; - arg = (!pn || (count > 1) || wrn) ? NewStringf("arg%d", arg_num) : Copy(pn); - - if (setter && Cmp(arg, "self") != 0) { - // Note that in C# properties, the input variable name is always called 'value' - Delete(arg); - arg = NewString("value"); - } - - return arg; - } - /* ----------------------------------------------------------------------------- * emitTypeWrapperClass() * ----------------------------------------------------------------------------- */ diff --git a/Source/Modules/d.cxx b/Source/Modules/d.cxx index 419828ea1..364a2bbee 100644 --- a/Source/Modules/d.cxx +++ b/Source/Modules/d.cxx @@ -4299,40 +4299,8 @@ private: return proxyname; } - /* --------------------------------------------------------------------------- - * D::makeParameterName() - * - * Inputs: - * n - Node - * p - parameter node - * arg_num - parameter argument number - * setter - set this flag when wrapping variables - * Return: - * arg - a unique parameter name - * --------------------------------------------------------------------------- */ String *makeParameterName(Node *n, Parm *p, int arg_num, bool setter) const { - String *arg = 0; - String *pn = Getattr(p, "name"); - - // Use C parameter name unless it is a duplicate or an empty parameter name - int count = 0; - ParmList *plist = Getattr(n, "parms"); - while (plist) { - if ((Cmp(pn, Getattr(plist, "name")) == 0)) - count++; - plist = nextSibling(plist); - } - String *wrn = pn ? Swig_name_warning(p, 0, pn, 0) : 0; - arg = (!pn || (count > 1) || wrn) ? NewStringf("arg%d", arg_num) : Copy(pn); - - if (setter && Cmp(arg, "self") != 0) { - // In theory, we could use the normal parameter name for setter functions. - // Unfortunately, it is set to "Class::VariableName" for static public - // members by the parser, which is not legal D syntax. Thus, we just force - // it to "value". - Delete(arg); - arg = NewString("value"); - } + String *arg = Language::makeParameterName(n, p, arg_num, setter); if (split_proxy_dmodule && Strncmp(arg, package, Len(arg)) == 0) { // If we are in split proxy mode and the argument is named like the target diff --git a/Source/Modules/java.cxx b/Source/Modules/java.cxx index 9e16bb422..32ca1afac 100644 --- a/Source/Modules/java.cxx +++ b/Source/Modules/java.cxx @@ -3115,44 +3115,6 @@ public: Delete(replacementname); } - /* ----------------------------------------------------------------------------- - * makeParameterName() - * - * Inputs: - * n - Node - * p - parameter node - * arg_num - parameter argument number - * setter - set this flag when wrapping variables - * Return: - * arg - a unique parameter name - * ----------------------------------------------------------------------------- */ - - String *makeParameterName(Node *n, Parm *p, int arg_num, bool setter) { - - String *arg = 0; - String *pn = Getattr(p, "name"); - - // Use C parameter name unless it is a duplicate or an empty parameter name - int count = 0; - ParmList *plist = Getattr(n, "parms"); - while (plist) { - if ((Cmp(pn, Getattr(plist, "name")) == 0)) - count++; - plist = nextSibling(plist); - } - String *wrn = pn ? Swig_name_warning(p, 0, pn, 0) : 0; - arg = (!pn || (count > 1) || wrn) ? NewStringf("arg%d", arg_num) : Copy(pn); - - if (setter && Cmp(arg, "self") != 0) { - // Note that for setters the parameter name is always set but sometimes includes C++ - // scope resolution, so we need to strip off the scope resolution to make a valid name. - Delete(arg); - arg = NewString("value"); //Swig_scopename_last(pn); - } - - return arg; - } - /* ----------------------------------------------------------------------------- * emitTypeWrapperClass() * ----------------------------------------------------------------------------- */ diff --git a/Source/Modules/lang.cxx b/Source/Modules/lang.cxx index 5ea79f0ab..2807784ff 100644 --- a/Source/Modules/lang.cxx +++ b/Source/Modules/lang.cxx @@ -3499,6 +3499,44 @@ int Language::is_smart_pointer() const { return SmartPointer; } +/* ----------------------------------------------------------------------------- + * Language::makeParameterName() + * + * Inputs: + * n - Node + * p - parameter node + * arg_num - parameter argument number + * setter - set this flag when wrapping variables + * Return: + * arg - a unique parameter name + * ----------------------------------------------------------------------------- */ +String *Language::makeParameterName(Node *n, Parm *p, int arg_num, bool setter) const { + + String *arg = 0; + String *pn = Getattr(p, "name"); + + // Use C parameter name unless it is a duplicate or an empty parameter name + int count = 0; + ParmList *plist = Getattr(n, "parms"); + while (plist) { + if ((Cmp(pn, Getattr(plist, "name")) == 0)) + count++; + plist = nextSibling(plist); + } + String *wrn = pn ? Swig_name_warning(p, 0, pn, 0) : 0; + arg = (!pn || (count > 1) || wrn) ? NewStringf("arg%d", arg_num) : Copy(pn); + + if (setter && Cmp(arg, "self") != 0) { + // Some languages (C#) insist on calling the input variable "value" while + // others (D, Java) could, in principle, use something different but this + // would require more work, and so we just use "value" for them too. + Delete(arg); + arg = NewString("value"); + } + + return arg; +} + /* ----------------------------------------------------------------------------- * Language::() * ----------------------------------------------------------------------------- */ diff --git a/Source/Modules/modula3.cxx b/Source/Modules/modula3.cxx index db5d0981b..2d6f26108 100644 --- a/Source/Modules/modula3.cxx +++ b/Source/Modules/modula3.cxx @@ -3621,35 +3621,6 @@ MODULA3(): return substitution_performed; } - /* ----------------------------------------------------------------------------- - * makeParameterName() - * - * Inputs: - * n - Node - * p - parameter node - * arg_num - parameter argument number - * Return: - * arg - a unique parameter name - * ----------------------------------------------------------------------------- */ - - String *makeParameterName(Node *n, Parm *p, int arg_num) { - - // Use C parameter name unless it is a duplicate or an empty parameter name - String *pn = Getattr(p, "name"); - int count = 0; - ParmList *plist = Getattr(n, "parms"); - while (plist) { - if ((Cmp(pn, Getattr(plist, "name")) == 0)) - count++; - plist = nextSibling(plist); - } - String *arg = (!pn || (count > 1)) ? NewStringf("arg%d", - arg_num) : Copy(Getattr(p, - "name")); - - return arg; - } - /* ----------------------------------------------------------------------------- * attachParameterNames() * diff --git a/Source/Modules/swigmod.h b/Source/Modules/swigmod.h index 63b91bae5..c451b8d9f 100644 --- a/Source/Modules/swigmod.h +++ b/Source/Modules/swigmod.h @@ -297,6 +297,9 @@ protected: /* Return true if the current method is part of a smart-pointer */ int is_smart_pointer() const; + /* Return the name to use for the given parameter. */ + virtual String *makeParameterName(Node *n, Parm *p, int arg_num, bool setter = false) const; + /* Some language modules require additional wrappers for virtual methods not declared in sub-classes */ virtual bool extraDirectorProtectedCPPMethodsRequired() const; -- cgit v1.2.1 From 80a72d50c7b18a8bb0762e65d18e3b54a7e5e553 Mon Sep 17 00:00:00 2001 From: Vadim Zeitlin Date: Sat, 16 Aug 2014 13:08:46 +0200 Subject: No real changes, just make PYTHON::check_kwargs() const. This will allow calling it from const methods too. --- Source/Modules/python.cxx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Source/Modules/python.cxx b/Source/Modules/python.cxx index 59fc403d8..72666e185 100644 --- a/Source/Modules/python.cxx +++ b/Source/Modules/python.cxx @@ -2044,7 +2044,7 @@ public: * check if using kwargs is allowed for this Node * ------------------------------------------------------------ */ - int check_kwargs(Node *n) { + int check_kwargs(Node *n) const { return (use_kw || GetFlag(n, "feature:kwargs")) && !GetFlag(n, "memberset") && !GetFlag(n, "memberget"); } -- cgit v1.2.1 From fdc6bbeda387fb49ab7dcdbb0f17e4645db3115c Mon Sep 17 00:00:00 2001 From: Vadim Zeitlin Date: Sat, 9 Aug 2014 16:33:23 +0200 Subject: Don't always use "*args" for all Python wrapper functions. Due to what seems like a bug introduced during Python 3 support merge, all the generated Python functions used the general "*args" signature instead of using the named parameters when possible. This happened due to is_primitive_defaultargs() always returning false for the functions without any default arguments as "value" passed to convertValue() was NULL in this case and convertValue() always returns false for NULL. Fix this by checking for value being non-NULL before calling convertValue(). Doing this exposed several problems with the handling of unnamed, duplicate (happens for parameters called INOUT, for example) or clashing with keywords parameter names, so the code dealing with them had to be fixed too. Basically just use makeParameterName() consistently everywhere. --- Source/Modules/python.cxx | 83 +++++++++++++++++++++++++++++------------------ 1 file changed, 51 insertions(+), 32 deletions(-) diff --git a/Source/Modules/python.cxx b/Source/Modules/python.cxx index 72666e185..21ab81a10 100644 --- a/Source/Modules/python.cxx +++ b/Source/Modules/python.cxx @@ -1523,6 +1523,21 @@ public: return ds; } + virtual String *makeParameterName(Node *n, Parm *p, int arg_num, bool = false) const { + // For the keyword arguments, we want to preserve the names as much as possible, + // so we only minimally rename them in Swig_name_make(), e.g. replacing "keyword" + // with "_keyword" if they have any name at all. + if (check_kwargs(n)) { + String* name = Getattr(p, "name"); + if (name) + return Swig_name_make(p, 0, name, 0, 0); + } + + // For the other cases use the general function which replaces arguments whose + // names clash with keywords with (less useful) "argN". + return Language::makeParameterName(n, p, arg_num); + } + /* ----------------------------------------------------------------------------- * addMissingParameterNames() * For functions that have not had nameless parameters set in the Language class. @@ -1534,13 +1549,14 @@ public: * The "lname" attribute in each parameter in plist will be contain a parameter name * ----------------------------------------------------------------------------- */ - void addMissingParameterNames(ParmList *plist, int arg_offset) { + void addMissingParameterNames(Node* n, ParmList *plist, int arg_offset) { Parm *p = plist; int i = arg_offset; while (p) { if (!Getattr(p, "lname")) { - String *pname = Swig_cparm_name(p, i); - Delete(pname); + String *name = makeParameterName(n, p, i); + Setattr(p, "lname", name); + Delete(name); } i++; p = nextSibling(p); @@ -1563,12 +1579,18 @@ public: Parm *pnext; - int start_arg_num = is_wrapping_class() ? 1 : 0; + // Normally we start counting auto-generated argument names from 1, but we should do it from 2 + // if the first argument is "self", i.e. if we're handling a non-static member function. + int arg_num = 1; + if (is_wrapping_class()) { + if (Cmp(Getattr(n, "storage"), "static") != 0) + arg_num++; + } if (calling) func_annotation = false; - addMissingParameterNames(plist, start_arg_num); // for $1_name substitutions done in Swig_typemap_attach_parms + addMissingParameterNames(n, plist, arg_num); // for $1_name substitutions done in Swig_typemap_attach_parms Swig_typemap_attach_parms("in", plist, 0); Swig_typemap_attach_parms("doc", plist, 0); @@ -1577,7 +1599,7 @@ public: return doc; } - for (p = plist; p; p = pnext) { + for (p = plist; p; p = pnext, arg_num++) { String *tm = Getattr(p, "tmap:in"); if (tm) { @@ -1600,15 +1622,18 @@ public: } // Note: the generated name should be consistent with that in kwnames[] - name = name ? name : Getattr(p, "name"); - name = name ? name : Getattr(p, "lname"); - name = Swig_name_make(p, 0, name, 0, 0); // rename parameter if a keyword + String *made_name = 0; + if (!name) { + name = made_name = makeParameterName(n, p, arg_num); + } type = type ? type : Getattr(p, "type"); value = value ? value : Getattr(p, "value"); - if (SwigType_isvarargs(type)) + if (SwigType_isvarargs(type)) { + Delete(made_name); break; + } if (Len(doc)) { // add a comma to the previous one if any @@ -1644,7 +1669,7 @@ public: Printf(doc, "=%s", value); } Delete(type_str); - Delete(name); + Delete(made_name); } if (pdocs) Setattr(n, "feature:pdocs", pdocs); @@ -1816,16 +1841,19 @@ public: } /* ------------------------------------------------------------ * is_primitive_defaultargs() - * Check if all the default args have primitive type. - * (So we can generate proper parameter list with default - * values..) + * Check if the function parameters default argument values + * have primitive types, so that their default values could be + * used in Python code. + * + * If this method returns false, the parameters will be translated + * to a generic "*args" which allows us to deal with default values + * at C++ code level where they can always be handled. * ------------------------------------------------------------ */ bool is_primitive_defaultargs(Node *n) { ParmList *plist = CopyParmList(Getattr(n, "parms")); Parm *p; Parm *pnext; - Swig_typemap_attach_parms("in", plist, 0); for (p = plist; p; p = pnext) { String *tm = Getattr(p, "tmap:in"); if (tm) { @@ -1836,10 +1864,11 @@ public: } else { pnext = nextSibling(p); } - String *type = Getattr(p, "type"); - String *value = Getattr(p, "value"); - if (!convertValue(value, type)) - return false; + if (String *value = Getattr(p, "value")) { + String *type = Getattr(p, "type"); + if (!convertValue(value, type)) + return false; + } } return true; } @@ -2423,7 +2452,6 @@ public: } SwigType *pt = Getattr(p, "type"); - String *pn = Getattr(p, "name"); String *ln = Getattr(p, "lname"); bool parse_from_tuple = (i > 0 || !add_self); if (SwigType_type(pt) == T_VARARGS) { @@ -2445,18 +2473,9 @@ public: /* Keyword argument handling */ if (allow_kwargs && parse_from_tuple) { - if (Len(pn)) { - String *tmp = 0; - String *name = pn; - if (!Getattr(p, "hidden")) { - name = tmp = Swig_name_make(p, 0, pn, 0, 0); // rename parameter if a keyword - } - Printf(kwargs, "(char *) \"%s\",", name); - if (tmp) - Delete(tmp); - } else { - Printf(kwargs, "(char *)\"arg%d\",", i + 1); - } + String *name = makeParameterName(n, p, i + 1); + Printf(kwargs, "(char *) \"%s\",", name); + Delete(name); } /* Look for an input typemap */ -- cgit v1.2.1 From 15b369028fbfcee559d9f4a8e37e2d71428add29 Mon Sep 17 00:00:00 2001 From: Vadim Zeitlin Date: Sun, 10 Aug 2014 03:56:04 +0200 Subject: Allow using enum elements as default values for Python functions. Enum values are just (integer) constants in Python and so can be used as the function default values just as well as literal numbers, account for this when checking whether function parameters can be represented in Python. Also rename is_primitive_defaultargs() to is_representable_as_pyargs() to describe better what this function does. --- Examples/test-suite/python/default_args_runme.py | 3 ++ Source/Modules/python.cxx | 63 ++++++++++++------------ 2 files changed, 35 insertions(+), 31 deletions(-) diff --git a/Examples/test-suite/python/default_args_runme.py b/Examples/test-suite/python/default_args_runme.py index 091a92376..ad5e03d11 100644 --- a/Examples/test-suite/python/default_args_runme.py +++ b/Examples/test-suite/python/default_args_runme.py @@ -1,5 +1,8 @@ import default_args +ec = default_args.EnumClass() +if not ec.blah(): + raise RuntimeError,"EnumClass::blah() default arguments don't work" if default_args.Statics_staticMethod() != 60: raise RuntimeError diff --git a/Source/Modules/python.cxx b/Source/Modules/python.cxx index 21ab81a10..389daf69c 100644 --- a/Source/Modules/python.cxx +++ b/Source/Modules/python.cxx @@ -1659,14 +1659,8 @@ public: // Write default value if (value && !calling) { String *new_value = convertValue(value, Getattr(p, "type")); - if (new_value) { - value = new_value; - } else { - Node *lookup = Swig_symbol_clookup(value, 0); - if (lookup) - value = Getattr(lookup, "sym:name"); - } - Printf(doc, "=%s", value); + if (new_value) + Printf(doc, "=%s", new_value); } Delete(type_str); Delete(made_name); @@ -1817,39 +1811,46 @@ public: /* ------------------------------------------------------------ * convertValue() - * Check if string v can be a Python value literal, - * (eg. number or string), or translate it to a Python literal. + * Check if string v can be a Python value literal or a + * constant. Return NIL if it isn't. * ------------------------------------------------------------ */ String *convertValue(String *v, SwigType *t) { - if (v && Len(v) > 0) { - char fc = (Char(v))[0]; - if (('0' <= fc && fc <= '9') || '\'' == fc || '"' == fc) { - /* number or string (or maybe NULL pointer) */ - if (SwigType_ispointer(t) && Strcmp(v, "0") == 0) - return NewString("None"); - else - return v; - } - if (Strcmp(v, "true") == 0 || Strcmp(v, "TRUE") == 0) - return NewString("True"); - if (Strcmp(v, "false") == 0 || Strcmp(v, "FALSE") == 0) - return NewString("False"); - if (Strcmp(v, "NULL") == 0 || Strcmp(v, "nullptr") == 0) - return SwigType_ispointer(t) ? NewString("None") : NewString("0"); + char fc = (Char(v))[0]; + if (('0' <= fc && fc <= '9') || '\'' == fc || '"' == fc) { + /* number or string (or maybe NULL pointer) */ + if (SwigType_ispointer(t) && Strcmp(v, "0") == 0) + return NewString("None"); + else + return v; } - return 0; + if (Strcmp(v, "true") == 0 || Strcmp(v, "TRUE") == 0) + return NewString("True"); + if (Strcmp(v, "false") == 0 || Strcmp(v, "FALSE") == 0) + return NewString("False"); + if (Strcmp(v, "NULL") == 0 || Strcmp(v, "nullptr") == 0) + return SwigType_ispointer(t) ? NewString("None") : NewString("0"); + + // This could also be an enum type, default value of which is perfectly + // representable in Python. + Node *lookup = Swig_symbol_clookup(v, 0); + if (lookup) { + if (Cmp(Getattr(lookup, "nodeType"), "enumitem") == 0) + return Getattr(lookup, "sym:name"); + } + + return NIL; } + /* ------------------------------------------------------------ - * is_primitive_defaultargs() + * is_representable_as_pyargs() * Check if the function parameters default argument values - * have primitive types, so that their default values could be - * used in Python code. + * can be represented in Python. * * If this method returns false, the parameters will be translated * to a generic "*args" which allows us to deal with default values * at C++ code level where they can always be handled. * ------------------------------------------------------------ */ - bool is_primitive_defaultargs(Node *n) { + bool is_representable_as_pyargs(Node *n) { ParmList *plist = CopyParmList(Getattr(n, "parms")); Parm *p; Parm *pnext; @@ -1913,7 +1914,7 @@ public: n = nn; /* For overloaded function, just use *args */ - if (is_real_overloaded(n) || GetFlag(n, "feature:compactdefaultargs") || !is_primitive_defaultargs(n)) { + if (is_real_overloaded(n) || GetFlag(n, "feature:compactdefaultargs") || !is_representable_as_pyargs(n)) { String *parms = NewString(""); if (in_class) Printf(parms, "self, "); -- cgit v1.2.1 From 30e5a79ecb43c496ec7bd54569b61244038a665c Mon Sep 17 00:00:00 2001 From: Johan Hake Date: Mon, 25 Aug 2014 10:09:12 +0200 Subject: Fix bug 206 where package information for relative in single file import is not propagated correctly. --- Source/CParse/parser.y | 1 + 1 file changed, 1 insertion(+) diff --git a/Source/CParse/parser.y b/Source/CParse/parser.y index 4ce8f0e6d..ec0927536 100644 --- a/Source/CParse/parser.y +++ b/Source/CParse/parser.y @@ -1880,6 +1880,7 @@ include_directive: includetype options string BEGINFILE { Node *nint = new_node("import"); Node *mnode = new_node("module"); Setattr(mnode,"name", mname); + Setattr(mnode,"options",(yyvsp[-5].node)); appendChild(nint,mnode); Delete(mnode); appendChild(nint,firstChild($$)); -- cgit v1.2.1 From e6882287af4177c2cb40528fd007579b3775c68f Mon Sep 17 00:00:00 2001 From: Ian Lance Taylor Date: Mon, 25 Aug 2014 15:58:10 -0700 Subject: Add generated Go files to .gitignore. --- .gitignore | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/.gitignore b/.gitignore index 28b44271f..0e2d70a23 100644 --- a/.gitignore +++ b/.gitignore @@ -143,6 +143,10 @@ swigexample*.oct */__pycache__/ /__pycache__/ +# Go generated files +*.[5689] +*_gc.c + # Scratch directories Examples/scratch -- cgit v1.2.1 From bbecefc6d0150b16f290933452d32d9fdc0cece8 Mon Sep 17 00:00:00 2001 From: Richard Date: Sun, 10 Aug 2014 18:09:59 -0500 Subject: * Fixed typo --with-jsv8inc and --with-jsv8lib * Fixed locating of libv8 on osx --- configure.ac | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/configure.ac b/configure.ac index abc9b06ef..49057d8d1 100644 --- a/configure.ac +++ b/configure.ac @@ -1224,7 +1224,7 @@ else # check for include files AC_MSG_CHECKING(for V8 Javascript v8.h) - AC_ARG_WITH(jsv8inc, [ --with-v8inc=path Set location of Javascript v8 include directory], [JSV8INCDIR="$withval"]) + AC_ARG_WITH(jsv8inc, [ --with-jsv8inc=path Set location of Javascript v8 include directory], [JSV8INCDIR="$withval"]) # if not include dir is specified we try to find if test -z "$JSV8INCDIR"; then @@ -1257,11 +1257,11 @@ else # check for V8 library AC_MSG_CHECKING(for V8 Javascript library) - AC_ARG_WITH(jsv8lib,[ --with-v8lib=path Set location of V8 Javascript library directory],[JSV8LIBDIR="$withval"], [JSV8LIB=]) + AC_ARG_WITH(jsv8lib,[ --with-jsv8lib=path Set location of V8 Javascript library directory],[JSV8LIBDIR="$withval"], [JSV8LIB=]) v8libdirs="$JSV8LIBDIR /usr/lib64/ /usr/local/lib64/ /usr/lib/ /usr/local/lib/" for d in $v8libdirs ; do - if test -r $d/libv8.so; then + if test -r $d/libv8$JSSO; then JSV8LIBDIR=$d JSV8LIB="-L$d -lv8" break @@ -1280,7 +1280,7 @@ else # linking options case $host in *-*-darwin*) - JSV8DYNAMICLINKING="" # TODO: add osx configuration + JSV8DYNAMICLINKING="$JSV8LIB" ;; *-*-linux*) JSV8DYNAMICLINKING="$JSV8LIB" -- cgit v1.2.1 From 19d2976962a81f3f3fd63df44ac46404a83d69ec Mon Sep 17 00:00:00 2001 From: Richard Date: Mon, 11 Aug 2014 12:27:32 -0500 Subject: Allow to specify V8 version, for example V8_VERSION=0x031511 ENGINE=v8 make check-javascript-examples --- Examples/javascript/example.mk | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/Examples/javascript/example.mk b/Examples/javascript/example.mk index 5a335bba4..cb8a33efd 100644 --- a/Examples/javascript/example.mk +++ b/Examples/javascript/example.mk @@ -7,12 +7,18 @@ else JSENGINE=node endif +ifneq (, $(V8_VERSION)) + JSV8_VERSION=$(V8_VERSION) +else + JSV8_VERSION=0x031110 +endif + EXAMPLES_TOP=../.. SWIG_TOP=../../.. SWIG = $(SWIG_TOP)/preinst-swig TARGET = example INTERFACE = example.i -SWIGOPT=-$(JSENGINE) +SWIGOPT=-$(JSENGINE) -DV8_VERSION=$(JSV8_VERSION) check: build $(MAKE) -f $(EXAMPLES_TOP)/Makefile SRCDIR='$(SRCDIR)' JSENGINE='$(JSENGINE)' TARGET='$(TARGET)' javascript_run -- cgit v1.2.1 From b0afc7a9a590fbe3e3ffe7ac06ea30f74aaa267f Mon Sep 17 00:00:00 2001 From: Richard Date: Mon, 11 Aug 2014 12:28:09 -0500 Subject: Allow to specify V8 version, for example: V8_VERSION=0x031511 ENGINE=v8 make check-javascript-test-suite --- Examples/test-suite/javascript/Makefile.in | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/Examples/test-suite/javascript/Makefile.in b/Examples/test-suite/javascript/Makefile.in index b6e946de2..b0fd82c25 100644 --- a/Examples/test-suite/javascript/Makefile.in +++ b/Examples/test-suite/javascript/Makefile.in @@ -19,8 +19,16 @@ else JSENGINE=node endif +ifneq (, $(V8_VERSION)) + JSV8_VERSION=$(V8_VERSION) +else + JSV8_VERSION=0x031110 +endif + include $(srcdir)/../common.mk +SWIGOPT += -DV8_VERSION=$(JSV8_VERSION) + _setup = \ if [ -f $(SCRIPTDIR)/$(SCRIPTPREFIX)$*$(SCRIPTSUFFIX) ]; then \ echo "$(ACTION)ing $(LANGUAGE) ($(JSENGINE)) testcase $* (with run test)" ; \ -- cgit v1.2.1 From 47cbf621be0ad9550ac5714cb3fb63b035a931f3 Mon Sep 17 00:00:00 2001 From: Richard Date: Tue, 12 Aug 2014 09:33:21 -0500 Subject: Fixes for v8 3.15.11 (0x031511) --- Lib/javascript/v8/javascriptrun.swg | 16 +++++++++++----- 1 file changed, 11 insertions(+), 5 deletions(-) diff --git a/Lib/javascript/v8/javascriptrun.swg b/Lib/javascript/v8/javascriptrun.swg index f200f1520..13c3c9070 100644 --- a/Lib/javascript/v8/javascriptrun.swg +++ b/Lib/javascript/v8/javascriptrun.swg @@ -116,7 +116,7 @@ int SWIG_V8_ConvertInstancePtr(v8::Handle objRef, void** ptr, swig_t if(objRef->InternalFieldCount() < 1) return SWIG_ERROR; -#if (SWIG_V8_VERSION < 0x031900) +#if (SWIG_V8_VERSION < 0x031511) v8::Handle cdataRef = objRef->GetInternalField(0); SWIGV8_Proxy *cdata = static_cast(v8::External::Unwrap(cdataRef)); #else @@ -164,7 +164,7 @@ int SWIG_V8_GetInstancePtr(v8::Handle valRef, void** ptr) { if(objRef->InternalFieldCount() < 1) return SWIG_ERROR; -#if (SWIG_V8_VERSION < 0x031900) +#if (SWIG_V8_VERSION < 0x031511) v8::Handle cdataRef = objRef->GetInternalField(0); SWIGV8_Proxy *cdata = static_cast(v8::External::Unwrap(cdataRef)); #else @@ -186,9 +186,12 @@ void SWIGV8_SetPrivateData(v8::Handle obj, void* ptr, swig_type_info cdata->swigCMemOwn = (flags & SWIG_POINTER_OWN) ? 1 : 0; cdata->info = info; -#if (SWIG_V8_VERSION < 0x031900) +#if (SWIG_V8_VERSION < 0x031511) obj->SetPointerInInternalField(0, cdata); cdata->handle = v8::Persistent::New(obj); +#elif (SWIG_V8_VERSION < 0x031900) + obj->SetAlignedPointerInInternalField(0, cdata); + cdata->handle = v8::Persistent::New(obj); #else obj->SetAlignedPointerInInternalField(0, cdata); cdata->handle.Reset(v8::Isolate::GetCurrent(), obj); @@ -367,7 +370,7 @@ swig_type_info* SwigV8Packed_UnpackData(v8::Handle valRef, void *ptr, v8::Handle objRef = valRef->ToObject(); -#if (SWIG_V8_VERSION < 0x031900) +#if (SWIG_V8_VERSION < 0x031511) v8::Handle cdataRef = objRef->GetInternalField(0); sobj = static_cast(v8::External::Unwrap(cdataRef)); #else @@ -425,9 +428,12 @@ v8::Handle SWIGV8_NewPackedObj(void *data, size_t size, swig_type_inf obj->SetHiddenValue(v8::String::New("__swig__packed_data__"), v8::Boolean::New(true)); -#if (SWIG_V8_VERSION < 0x031900) +#if (SWIG_V8_VERSION < 0x031511) obj->SetPointerInInternalField(0, cdata); cdata->handle = v8::Persistent::New(obj); +#elif (SWIG_V8_VERSION < 0x031900) + obj->SetAlignedPointerInInternalField(0, cdata); + cdata->handle = v8::Persistent::New(obj); #else obj->SetAlignedPointerInInternalField(0, cdata); cdata->handle.Reset(v8::Isolate::GetCurrent(), obj); -- cgit v1.2.1 From 2a662502a50e3ae67f515c03b72173b019d2a878 Mon Sep 17 00:00:00 2001 From: Richard Date: Tue, 12 Aug 2014 10:02:23 -0500 Subject: Fixed buffer overrun --- Examples/javascript/template/runme.js | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/Examples/javascript/template/runme.js b/Examples/javascript/template/runme.js index af96ac7f9..6a29fa77c 100644 --- a/Examples/javascript/template/runme.js +++ b/Examples/javascript/template/runme.js @@ -9,20 +9,20 @@ console.log(example.maxdouble(3.14,2.18)); iv = new example.vecint(100); dv = new example.vecdouble(1000); -for(i=0;i<=100;i++) +for(i=0;i<100;i++) iv.setitem(i,2*i); -for(i=0;i<=1000;i++) +for(i=0;i<1000;i++) dv.setitem(i, 1.0/(i+1)); sum = 0; -for(i=0;i<=100;i++) +for(i=0;i<100;i++) sum = sum + iv.getitem(i); console.log(sum); sum = 0.0; -for(i=0;i<=1000;i++) +for(i=0;i<1000;i++) sum = sum + dv.getitem(i); console.log(sum); -- cgit v1.2.1 From 8829230641f6dd3397bdb5142b77f6282990b294 Mon Sep 17 00:00:00 2001 From: Richard Date: Tue, 12 Aug 2014 11:37:49 -0500 Subject: Fixes for v8 3.17.10 (0x031710) --- Lib/javascript/v8/javascriptcode.swg | 24 ++++++++++--- Lib/javascript/v8/javascriptinit.swg | 4 ++- Lib/javascript/v8/javascriptrun.swg | 66 ++++++++++++++++++++++++------------ 3 files changed, 67 insertions(+), 27 deletions(-) diff --git a/Lib/javascript/v8/javascriptcode.swg b/Lib/javascript/v8/javascriptcode.swg index 67a81146e..793c4ab1a 100644 --- a/Lib/javascript/v8/javascriptcode.swg +++ b/Lib/javascript/v8/javascriptcode.swg @@ -120,8 +120,12 @@ fail: %fragment ("js_dtor", "templates") %{ -#if (SWIG_V8_VERSION < 0x031900) +#if (SWIG_V8_VERSION < 0x031710) void $jswrapper(v8::Persistent< v8::Value > object, void *parameter) +{ + SWIGV8_Proxy *proxy = static_cast(parameter); +#elif (SWIG_V8_VERSION < 0x031900) +void $jswrapper(v8::Isolate *isolate, v8::Persistent< v8::Value > object, void *parameter) { SWIGV8_Proxy *proxy = static_cast(parameter); #else @@ -138,8 +142,10 @@ void $jswrapper(v8::Isolate *isolate, v8::Persistent< v8::Object > * object, SWI delete proxy; object.Clear(); -#if (SWIG_V8_VERSION < 0x031900) +#if (SWIG_V8_VERSION < 0x031710) object.Dispose(); +#elif (SWIG_V8_VERSION < 0x031900) + object.Dispose(isolate); #elif (SWIG_V8_VERSION < 0x032100) object->Dispose(isolate); #else @@ -156,8 +162,12 @@ void $jswrapper(v8::Isolate *isolate, v8::Persistent< v8::Object > * object, SWI * ----------------------------------------------------------------------------- */ %fragment ("js_dtoroverride", "templates") %{ -#if (SWIG_V8_VERSION < 0x031900) +#if (SWIG_V8_VERSION < 0x031710) void $jswrapper(v8::Persistent< v8::Value > object, void *parameter) +{ + SWIGV8_Proxy *proxy = static_cast(parameter); +#elif (SWIG_V8_VERSION < 0x031900) +void $jswrapper(v8::Isolate *isolate, v8::Persistent< v8::Value > object, void *parameter) { SWIGV8_Proxy *proxy = static_cast(parameter); #else @@ -170,8 +180,10 @@ void $jswrapper(v8::Isolate *isolate, v8::Persistent< v8::Object > * object, SWI } delete proxy; -#if (SWIG_V8_VERSION < 0x031900) +#if (SWIG_V8_VERSION < 0x031710) object.Dispose(); +#elif (SWIG_V8_VERSION < 0x031900) + object.Dispose(isolate); #elif (SWIG_V8_VERSION < 0x032100) object->Dispose(isolate); #else @@ -331,8 +343,10 @@ fail: %fragment("jsv8_define_class_template", "templates") %{ v8::Handle $jsmangledname_class = SWIGV8_CreateClassTemplate("$jsmangledname"); -#if (SWIG_V8_VERSION < 0x031900) +#if (SWIG_V8_VERSION < 0x031710) $jsmangledname_clientData.class_templ = v8::Persistent::New($jsmangledname_class); +#elif (SWIG_V8_VERSION < 0x031900) + $jsmangledname_clientData.class_templ = v8::Persistent::New(v8::Isolate::GetCurrent(), $jsmangledname_class); #else $jsmangledname_clientData.class_templ.Reset(v8::Isolate::GetCurrent(), $jsmangledname_class); #endif diff --git a/Lib/javascript/v8/javascriptinit.swg b/Lib/javascript/v8/javascriptinit.swg index b428d4af9..651a39144 100644 --- a/Lib/javascript/v8/javascriptinit.swg +++ b/Lib/javascript/v8/javascriptinit.swg @@ -81,8 +81,10 @@ void SWIGV8_INIT (v8::Handle exports, v8::Handle /*modul %fragment("js_initializer", "templates") %{ // a class template for creating proxies of undefined types -#if (SWIG_V8_VERSION < 0x031900) +#if (SWIG_V8_VERSION < 0x031710) SWIGV8_SWIGTYPE_Proxy_class_templ = v8::Persistent::New(SWIGV8_CreateClassTemplate("SwigProxy")); +#elif (SWIG_V8_VERSION < 0x031900) + SWIGV8_SWIGTYPE_Proxy_class_templ = v8::Persistent::New(v8::Isolate::GetCurrent(), SWIGV8_CreateClassTemplate("SwigProxy")); #else SWIGV8_SWIGTYPE_Proxy_class_templ.Reset(v8::Isolate::GetCurrent(), SWIGV8_CreateClassTemplate("SwigProxy")); #endif diff --git a/Lib/javascript/v8/javascriptrun.swg b/Lib/javascript/v8/javascriptrun.swg index 13c3c9070..a38441fc6 100644 --- a/Lib/javascript/v8/javascriptrun.swg +++ b/Lib/javascript/v8/javascriptrun.swg @@ -80,12 +80,15 @@ public: }; ~SWIGV8_Proxy() { -#if (SWIG_V8_VERSION < 0x031900 || SWIG_V8_VERSION >= 0x032100) +#if (SWIG_V8_VERSION < 0x031710) handle.ClearWeak(); handle.Dispose(); -#else +#elif (SWIG_V8_VERSION < 0x032100) handle.ClearWeak(v8::Isolate::GetCurrent()); handle.Dispose(v8::Isolate::GetCurrent()); +#else + handle.ClearWeak(); + handle.Dispose(); #endif handle.Clear(); @@ -102,8 +105,10 @@ class SWIGV8_ClientData { public: v8::Persistent class_templ; -#if (SWIG_V8_VERSION < 0x031900) +#if (SWIG_V8_VERSION < 0x031710) void (*dtor) (v8::Persistent< v8::Value> object, void *parameter); +#elif (SWIG_V8_VERSION < 0x031900) + void (*dtor) (v8::Isolate *isolate, v8::Persistent< v8::Value> object, void *parameter); #else void (*dtor) (v8::Isolate *isolate, v8::Persistent< v8::Object > *object, SWIGV8_Proxy *proxy); #endif @@ -143,8 +148,10 @@ int SWIG_V8_ConvertInstancePtr(v8::Handle objRef, void** ptr, swig_t return SWIG_OK; } -#if (SWIG_V8_VERSION < 0x031900) +#if (SWIG_V8_VERSION < 0x031710) void SWIGV8_Proxy_DefaultDtor(v8::Persistent< v8::Value > object, void *parameter) +#elif (SWIG_V8_VERSION < 0x031900) +void SWIGV8_Proxy_DefaultDtor(v8::Isolate *, v8::Persistent< v8::Value > object, void *parameter) #else void SWIGV8_Proxy_DefaultDtor(v8::Isolate *, v8::Persistent< v8::Object > *object, SWIGV8_Proxy *proxy) #endif @@ -188,37 +195,41 @@ void SWIGV8_SetPrivateData(v8::Handle obj, void* ptr, swig_type_info #if (SWIG_V8_VERSION < 0x031511) obj->SetPointerInInternalField(0, cdata); - cdata->handle = v8::Persistent::New(obj); -#elif (SWIG_V8_VERSION < 0x031900) +#else obj->SetAlignedPointerInInternalField(0, cdata); +#endif + +#if (SWIG_V8_VERSION < 0x031710) cdata->handle = v8::Persistent::New(obj); +#elif (SWIG_V8_VERSION < 0x031900) + cdata->handle = v8::Persistent::New(v8::Isolate::GetCurrent(), obj); #else - obj->SetAlignedPointerInInternalField(0, cdata); cdata->handle.Reset(v8::Isolate::GetCurrent(), obj); #endif -#if (SWIG_V8_VERSION < 0x031900) +#if (SWIG_V8_VERSION < 0x031710) // clientdata must be set for owned data as we need to register the dtor if(cdata->swigCMemOwn && (SWIGV8_ClientData*)info->clientdata) { cdata->handle.MakeWeak(cdata, ((SWIGV8_ClientData*)info->clientdata)->dtor); } else { cdata->handle.MakeWeak(cdata, SWIGV8_Proxy_DefaultDtor); } - cdata->handle.MarkIndependent(); #else if(cdata->swigCMemOwn && (SWIGV8_ClientData*)info->clientdata) { cdata->handle.MakeWeak(v8::Isolate::GetCurrent(), cdata, ((SWIGV8_ClientData*)info->clientdata)->dtor); } else { cdata->handle.MakeWeak(v8::Isolate::GetCurrent(), cdata, SWIGV8_Proxy_DefaultDtor); } +#endif -#if (SWIG_V8_VERSION < 0x032100) +#if (SWIG_V8_VERSION < 0x031710) + cdata->handle.MarkIndependent(); +#elif (SWIG_V8_VERSION < 0x032100) cdata->handle.MarkIndependent(v8::Isolate::GetCurrent()); #else cdata->handle.MarkIndependent(); #endif -#endif } int SWIG_V8_ConvertPtr(v8::Handle valRef, void** ptr, swig_type_info *info, int flags) { @@ -398,8 +409,12 @@ int SWIGV8_ConvertPacked(v8::Handle valRef, void *ptr, size_t sz, swi return SWIG_OK; } -#if (SWIG_V8_VERSION < 0x031900) +#if (SWIG_V8_VERSION < 0x031710) void _wrap_SwigV8PackedData_delete(v8::Persistent< v8::Value > object, void *parameter) +{ + SwigV8PackedData *cdata = static_cast(parameter); +#elif (SWIG_V8_VERSION < 0x031900) +void _wrap_SwigV8PackedData_delete(v8::Isolate *isolate, v8::Persistent< v8::Value > object, void *parameter) { SwigV8PackedData *cdata = static_cast(parameter); #else @@ -409,9 +424,12 @@ void _wrap_SwigV8PackedData_delete(v8::Isolate *isolate, v8::Persistent< v8::Obj delete cdata; -#if (SWIG_V8_VERSION < 0x031900) +#if (SWIG_V8_VERSION < 0x031710) object.Clear(); object.Dispose(); +#elif (SWIG_V8_VERSION < 0x031900) + object.Clear(); + object.Dispose(isolate); #elif (SWIG_V8_VERSION < 0x032100) object->Dispose(isolate); #else @@ -430,25 +448,31 @@ v8::Handle SWIGV8_NewPackedObj(void *data, size_t size, swig_type_inf #if (SWIG_V8_VERSION < 0x031511) obj->SetPointerInInternalField(0, cdata); - cdata->handle = v8::Persistent::New(obj); -#elif (SWIG_V8_VERSION < 0x031900) +#else obj->SetAlignedPointerInInternalField(0, cdata); +#endif + +#if (SWIG_V8_VERSION < 0x031710) cdata->handle = v8::Persistent::New(obj); +#elif (SWIG_V8_VERSION < 0x031900) + cdata->handle = v8::Persistent::New(v8::Isolate::GetCurrent(), obj); #else - obj->SetAlignedPointerInInternalField(0, cdata); cdata->handle.Reset(v8::Isolate::GetCurrent(), obj); #endif -#if (SWIG_V8_VERSION < 0x031900) + +#if (SWIG_V8_VERSION < 0x031710) cdata->handle.MakeWeak(cdata, _wrap_SwigV8PackedData_delete); - cdata->handle.MarkIndependent(); #else cdata->handle.MakeWeak(v8::Isolate::GetCurrent(), cdata, _wrap_SwigV8PackedData_delete); -# if (SWIG_V8_VERSION < 0x032100) +#endif + +#if (SWIG_V8_VERSION < 0x031710) + cdata->handle.MarkIndependent(); +#elif (SWIG_V8_VERSION < 0x032100) cdata->handle.MarkIndependent(v8::Isolate::GetCurrent()); -# else +#else cdata->handle.MarkIndependent(); -# endif #endif return scope.Close(obj); -- cgit v1.2.1 From 44e57d9cfdafe818882f8564038d0fe0a594923c Mon Sep 17 00:00:00 2001 From: Richard Date: Tue, 12 Aug 2014 12:02:38 -0500 Subject: Allow to compile for specific V8 version --- Tools/javascript/Makefile.in | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/Tools/javascript/Makefile.in b/Tools/javascript/Makefile.in index f65be2826..a08ed4760 100644 --- a/Tools/javascript/Makefile.in +++ b/Tools/javascript/Makefile.in @@ -35,6 +35,13 @@ JSCENABLED = @JSCENABLED@ srcdir = @srcdir@ + +ifneq (, $(V8_VERSION)) + JSV8_VERSION=$(V8_VERSION) +else + JSV8_VERSION=0x031110 +endif + # Regenerate Makefile if Makefile.in or config.status have changed. Makefile: $(srcdir)/Makefile.in ../../config.status cd ../.. && $(SHELL) ./config.status Tools/javascript/Makefile @@ -42,7 +49,7 @@ Makefile: $(srcdir)/Makefile.in ../../config.status # These settings are provided by 'configure' (see '/configure.in') ifeq (1, $(JSV8ENABLED)) JS_INTERPRETER_SRC_V8 = v8_shell.cxx -JS_INTERPRETER_ENABLE_V8 = -DENABLE_V8 +JS_INTERPRETER_ENABLE_V8 = -DENABLE_V8 -DV8_VERSION=$(JSV8_VERSION) endif ifeq (1, $(JSCENABLED)) -- cgit v1.2.1 From 8ee40e408bc51e3ef66112f6ec460a3eb4e35b9b Mon Sep 17 00:00:00 2001 From: Richard Date: Tue, 12 Aug 2014 12:03:07 -0500 Subject: Fixes for v8 3.17.10 (0x031710) --- Tools/javascript/v8_shell.cxx | 28 +++++++++++++++++++++++++++- 1 file changed, 27 insertions(+), 1 deletion(-) diff --git a/Tools/javascript/v8_shell.cxx b/Tools/javascript/v8_shell.cxx index 4c6334f2f..5148d32d8 100644 --- a/Tools/javascript/v8_shell.cxx +++ b/Tools/javascript/v8_shell.cxx @@ -70,7 +70,13 @@ V8Shell::~V8Shell() {} bool V8Shell::RunScript(const std::string& scriptPath) { if (!context.IsEmpty()) { +#if (V8_VERSION < 0x031710) context.Dispose(); +#elif (V8_VERSION < 0x031900) + context.Dispose(v8::Isolate::GetCurrent()); +#else + context.Dispose(); +#endif } std::string source = ReadFile(scriptPath); @@ -85,7 +91,15 @@ bool V8Shell::RunScript(const std::string& scriptPath) { bool success = _ExecuteScript(source, scriptPath); context->Exit(); - context.Dispose(); + +#if (V8_VERSION < 0x031710) + context.Dispose(); +#elif (V8_VERSION < 0x031900) + context.Dispose(v8::Isolate::GetCurrent()); +#else + context.Dispose(); +#endif + v8::V8::Dispose(); return true; @@ -112,7 +126,13 @@ bool V8Shell::_ExecuteScript(const std::string& source, const std::string& scrip bool V8Shell::RunShell() { if (!context.IsEmpty()) { +#if (V8_VERSION < 0x031710) + context.Dispose(); +#elif (V8_VERSION < 0x031900) + context.Dispose(v8::Isolate::GetCurrent()); +#else context.Dispose(); +#endif } context = CreateShellContext(); @@ -139,7 +159,13 @@ bool V8Shell::RunShell() { printf("\n"); context->Exit(); +#if (V8_VERSION < 0x031710) + context.Dispose(); +#elif (V8_VERSION < 0x031900) + context.Dispose(v8::Isolate::GetCurrent()); +#else context.Dispose(); +#endif v8::V8::Dispose(); return true; -- cgit v1.2.1 From 013fb3d22da50fa3594a680c3d649334b9b39661 Mon Sep 17 00:00:00 2001 From: Richard Date: Tue, 12 Aug 2014 16:58:29 -0500 Subject: Fixes for v8 3.19.2 (0x031902) --- Lib/javascript/v8/javascriptcode.swg | 6 +++--- Lib/javascript/v8/javascripthelpers.swg | 2 +- Lib/javascript/v8/javascriptrun.swg | 8 ++++---- 3 files changed, 8 insertions(+), 8 deletions(-) diff --git a/Lib/javascript/v8/javascriptcode.swg b/Lib/javascript/v8/javascriptcode.swg index 793c4ab1a..a3eb94daf 100644 --- a/Lib/javascript/v8/javascriptcode.swg +++ b/Lib/javascript/v8/javascriptcode.swg @@ -98,7 +98,7 @@ fail: %{ if(args.Length() == $jsargcount) { errorHandler.err.Clear(); -#if SWIG_V8_VERSION < 0x031900 +#if SWIG_V8_VERSION < 0x031903 self = $jswrapper(args, errorHandler); if(errorHandler.err.IsEmpty()) { return scope.Close(self); @@ -311,7 +311,7 @@ fail: if(args.Length() == $jsargcount) { errorHandler.err.Clear(); -#if (SWIG_V8_VERSION < 0x031900) +#if (SWIG_V8_VERSION < 0x031903) jsresult = $jswrapper(args, errorHandler); if(errorHandler.err.IsEmpty()) { return scope.Close(jsresult); @@ -366,7 +366,7 @@ fail: %{ if (SWIGTYPE_p$jsbaseclass->clientdata && !(static_cast(SWIGTYPE_p$jsbaseclass->clientdata)->class_templ.IsEmpty())) { -#if (SWIG_V8_VERSION < 0x031900) +#if (SWIG_V8_VERSION < 0x031903) $jsmangledname_class->Inherit(static_cast(SWIGTYPE_p$jsbaseclass->clientdata)->class_templ); #else $jsmangledname_class->Inherit( diff --git a/Lib/javascript/v8/javascripthelpers.swg b/Lib/javascript/v8/javascripthelpers.swg index f6303cced..ac352796e 100644 --- a/Lib/javascript/v8/javascripthelpers.swg +++ b/Lib/javascript/v8/javascripthelpers.swg @@ -1,7 +1,7 @@ %insert(runtime) %{ // Note: since 3.19 there are new CallBack types, since 03.21.9 the old ones have been removed -#if SWIG_V8_VERSION < 0x031900 +#if (SWIG_V8_VERSION < 0x031903) typedef v8::InvocationCallback SwigV8FunctionCallback; typedef v8::AccessorGetter SwigV8AccessorGetterCallback; typedef v8::AccessorSetter SwigV8AccessorSetterCallback; diff --git a/Lib/javascript/v8/javascriptrun.swg b/Lib/javascript/v8/javascriptrun.swg index a38441fc6..dd5c9784e 100644 --- a/Lib/javascript/v8/javascriptrun.swg +++ b/Lib/javascript/v8/javascriptrun.swg @@ -49,7 +49,7 @@ public: // Note: these typedefs and defines are used to deal with v8 API changes since version 3.19.00 -#if (SWIG_V8_VERSION < 0x031900) +#if (SWIG_V8_VERSION < 0x031903) typedef v8::Handle SwigV8ReturnValue; typedef v8::Arguments SwigV8Arguments; typedef v8::AccessorInfo SwigV8PropertyCallbackInfo; @@ -254,7 +254,7 @@ v8::Handle SWIG_V8_NewPointerObj(void *ptr, swig_type_info *info, int return scope.Close(v8::Null()); } -#if (SWIG_V8_VERSION < 0x031900) +#if (SWIG_V8_VERSION < 0x031903) if(info->clientdata != 0) { class_templ = ((SWIGV8_ClientData*) info->clientdata)->class_templ; } else { @@ -287,7 +287,7 @@ v8::Handle SWIG_V8_NewPointerObj(void *ptr, swig_type_info *info, int #define SWIG_GetInstancePtr(obj, ptr) SWIG_V8_GetInstancePtr(obj, ptr) -#if (SWIG_V8_VERSION < 0x031900) +#if (SWIG_V8_VERSION < 0x031903) v8::Handle _SWIGV8_wrap_equals(const v8::Arguments &args) { #else void _SWIGV8_wrap_equals(const v8::FunctionCallbackInfo& args) { @@ -320,7 +320,7 @@ fail: SWIGV8_RETURN(v8::Undefined()); } -#if (SWIG_V8_VERSION < 0x031900) +#if (SWIG_V8_VERSION < 0x031903) v8::Handle _wrap_getCPtr(const v8::Arguments &args) { #else void _wrap_getCPtr(const v8::FunctionCallbackInfo& args) { -- cgit v1.2.1 From 3d63f9113bf6bd805f763a2efbe879e7ce08f992 Mon Sep 17 00:00:00 2001 From: Richard Date: Tue, 12 Aug 2014 22:25:32 -0500 Subject: Fixes for v8 3.19.18 (0x031918) --- Lib/javascript/v8/javascriptrun.swg | 12 ++++- Tools/javascript/v8_shell.cxx | 104 ++++++++++++++++++------------------ 2 files changed, 63 insertions(+), 53 deletions(-) diff --git a/Lib/javascript/v8/javascriptrun.swg b/Lib/javascript/v8/javascriptrun.swg index dd5c9784e..50e4c5b87 100644 --- a/Lib/javascript/v8/javascriptrun.swg +++ b/Lib/javascript/v8/javascriptrun.swg @@ -214,12 +214,18 @@ void SWIGV8_SetPrivateData(v8::Handle obj, void* ptr, swig_type_info } else { cdata->handle.MakeWeak(cdata, SWIGV8_Proxy_DefaultDtor); } -#else +#elif (SWIG_V8_VERSION < 0x031918) if(cdata->swigCMemOwn && (SWIGV8_ClientData*)info->clientdata) { cdata->handle.MakeWeak(v8::Isolate::GetCurrent(), cdata, ((SWIGV8_ClientData*)info->clientdata)->dtor); } else { cdata->handle.MakeWeak(v8::Isolate::GetCurrent(), cdata, SWIGV8_Proxy_DefaultDtor); } +#else + if(cdata->swigCMemOwn && (SWIGV8_ClientData*)info->clientdata) { + cdata->handle.MakeWeak(cdata, ((SWIGV8_ClientData*)info->clientdata)->dtor); + } else { + cdata->handle.MakeWeak(cdata, SWIGV8_Proxy_DefaultDtor); + } #endif #if (SWIG_V8_VERSION < 0x031710) @@ -463,8 +469,10 @@ v8::Handle SWIGV8_NewPackedObj(void *data, size_t size, swig_type_inf #if (SWIG_V8_VERSION < 0x031710) cdata->handle.MakeWeak(cdata, _wrap_SwigV8PackedData_delete); -#else +#elif (SWIG_V8_VERSION < 0x031918) cdata->handle.MakeWeak(v8::Isolate::GetCurrent(), cdata, _wrap_SwigV8PackedData_delete); +#else + cdata->handle.MakeWeak(cdata, _wrap_SwigV8PackedData_delete); #endif #if (SWIG_V8_VERSION < 0x031710) diff --git a/Tools/javascript/v8_shell.cxx b/Tools/javascript/v8_shell.cxx index 5148d32d8..cf3836369 100644 --- a/Tools/javascript/v8_shell.cxx +++ b/Tools/javascript/v8_shell.cxx @@ -35,7 +35,11 @@ private: v8::Handle Import(const std::string& moduleName); +#if (V8_VERSION < 0x031900) v8::Persistent CreateShellContext(); +#else + v8::Local CreateShellContext(); +#endif void ReportException(v8::TryCatch* handler); @@ -49,11 +53,6 @@ private: static const char* ToCString(const v8::String::Utf8Value& value); - virtual bool _ExecuteScript(const std::string& source, const std::string& scriptPath); - -protected: - - v8::Persistent context; }; #ifdef __GNUC__ @@ -68,47 +67,25 @@ V8Shell::V8Shell(){} V8Shell::~V8Shell() {} bool V8Shell::RunScript(const std::string& scriptPath) { + std::string source = ReadFile(scriptPath); - if (!context.IsEmpty()) { -#if (V8_VERSION < 0x031710) - context.Dispose(); -#elif (V8_VERSION < 0x031900) - context.Dispose(v8::Isolate::GetCurrent()); + v8::HandleScope scope; + +#if (V8_VERSION < 0x031900) + v8::Persistent context = CreateShellContext(); #else - context.Dispose(); + v8::Local context = CreateShellContext(); #endif - } - - std::string source = ReadFile(scriptPath); - context = CreateShellContext(); if (context.IsEmpty()) { printf("Could not create context.\n"); return false; } - context->Enter(); - bool success = _ExecuteScript(source, scriptPath); - - context->Exit(); - -#if (V8_VERSION < 0x031710) - context.Dispose(); -#elif (V8_VERSION < 0x031900) - context.Dispose(v8::Isolate::GetCurrent()); -#else - context.Dispose(); -#endif - - v8::V8::Dispose(); - - return true; -} - -bool V8Shell::_ExecuteScript(const std::string& source, const std::string& scriptPath) { - v8::HandleScope scope; + context->Enter(); // Store a pointer to this shell for later use + v8::Handle global = context->Global(); v8::Local __shell__ = v8::External::New((void*) (long) this); global->SetHiddenValue(v8::String::New("__shell__"), __shell__); @@ -116,26 +93,34 @@ bool V8Shell::_ExecuteScript(const std::string& source, const std::string& scrip // Node.js compatibility: make `print` available as `console.log()` ExecuteScript("var console = {}; console.log = print;", ""); - if(!ExecuteScript(source, scriptPath)) { - return false; - } + bool success = ExecuteScript(source, scriptPath); - return true; -} + // Cleanup -bool V8Shell::RunShell() { + context->Exit(); - if (!context.IsEmpty()) { #if (V8_VERSION < 0x031710) context.Dispose(); #elif (V8_VERSION < 0x031900) context.Dispose(v8::Isolate::GetCurrent()); #else - context.Dispose(); +// context.Dispose(); +#endif + +// v8::V8::Dispose(); + + return success; +} + +bool V8Shell::RunShell() { + v8::HandleScope scope; + +#if (V8_VERSION < 0x031900) + v8::Persistent context = CreateShellContext(); +#else + v8::Local context = CreateShellContext(); #endif - } - context = CreateShellContext(); if (context.IsEmpty()) { printf("Could not create context.\n"); return false; @@ -158,15 +143,19 @@ bool V8Shell::RunShell() { } printf("\n"); + // Cleanup + context->Exit(); + #if (V8_VERSION < 0x031710) - context.Dispose(); + context.Dispose(); #elif (V8_VERSION < 0x031900) - context.Dispose(v8::Isolate::GetCurrent()); + context.Dispose(v8::Isolate::GetCurrent()); #else - context.Dispose(); +// context.Dispose(); #endif - v8::V8::Dispose(); + +// v8::V8::Dispose(); return true; } @@ -203,7 +192,11 @@ bool V8Shell::DisposeEngine() { return true; } +#if (V8_VERSION < 0x031900) v8::Persistent V8Shell::CreateShellContext() { +#else +v8::Local V8Shell::CreateShellContext() { +#endif v8::HandleScope scope; // Create a template for the global object. @@ -215,9 +208,18 @@ v8::Persistent V8Shell::CreateShellContext() { global->Set(v8::String::New("require"), v8::FunctionTemplate::New(V8Shell::Require)); global->Set(v8::String::New("version"), v8::FunctionTemplate::New(V8Shell::Version)); - v8::Persistent _context = v8::Context::New(NULL, global); - return _context; +#if (V8_VERSION < 0x031900) + v8::Persistent context = v8::Context::New(NULL, global); + return context; +#else +// v8::Local context_ = v8::Context::New(v8::Isolate::GetCurrent(), NULL, global); +// v8::Persistent context; +// context.Reset(v8::Isolate::GetCurrent(), context_); + v8::Local context = v8::Context::New(v8::Isolate::GetCurrent(), NULL, global); + return scope.Close(context); +#endif + } v8::Handle V8Shell::Import(const std::string& module_path) -- cgit v1.2.1 From e98a6592463b2f0c0f10f5725e381b2d6589d982 Mon Sep 17 00:00:00 2001 From: Richard Date: Tue, 12 Aug 2014 23:05:14 -0500 Subject: Fixes for v8 3.21.17 (0x032117) --- Lib/javascript/v8/javascriptcode.swg | 45 +++++++++++++++++ Lib/javascript/v8/javascriptcomplex.swg | 13 +++++ Lib/javascript/v8/javascripthelpers.swg | 5 ++ Lib/javascript/v8/javascriptinit.swg | 5 ++ Lib/javascript/v8/javascriptrun.swg | 55 ++++++++++++++++++--- Tools/javascript/v8_shell.cxx | 88 +++++++++++++++++++++++++++------ 6 files changed, 188 insertions(+), 23 deletions(-) diff --git a/Lib/javascript/v8/javascriptcode.swg b/Lib/javascript/v8/javascriptcode.swg index a3eb94daf..85e26d5f3 100644 --- a/Lib/javascript/v8/javascriptcode.swg +++ b/Lib/javascript/v8/javascriptcode.swg @@ -9,7 +9,12 @@ %fragment("js_ctor", "templates") %{ SwigV8ReturnValue $jswrapper(const SwigV8Arguments& args) { +#if (SWIG_V8_VERSION < 0x032117) v8::HandleScope scope; +#else + v8::HandleScope scope(v8::Isolate::GetCurrent()); +#endif + v8::Handle self = args.Holder(); $jslocals if(args.Length() != $jsargcount) SWIG_exception_fail(SWIG_ERROR, "Illegal number of arguments for $jswrapper."); @@ -32,7 +37,12 @@ fail: %fragment ("js_veto_ctor", "templates") %{ SwigV8ReturnValue $jswrapper(const SwigV8Arguments& args) { +#if (SWIG_V8_VERSION < 0x032117) v8::HandleScope scope; +#else + v8::HandleScope scope(v8::Isolate::GetCurrent()); +#endif + SWIG_exception(SWIG_ERROR, "Class $jsname can not be instantiated"); SWIGV8_RETURN(v8::Undefined()); } @@ -47,7 +57,12 @@ SwigV8ReturnValue $jswrapper(const SwigV8Arguments& args) { %fragment ("js_ctor_dispatcher", "templates") %{ SwigV8ReturnValue $jswrapper(const SwigV8Arguments& args) { +#if (SWIG_V8_VERSION < 0x032117) v8::HandleScope scope; +#else + v8::HandleScope scope(v8::Isolate::GetCurrent()); +#endif + OverloadErrorHandler errorHandler; v8::Handle self; @@ -72,7 +87,12 @@ fail: * ----------------------------------------------------------------------------- */ %fragment("js_overloaded_ctor", "templates") %{ SwigV8ReturnValue $jswrapper(const SwigV8Arguments& args, V8ErrorHandler& SWIGV8_ErrorHandler) { +#if (SWIG_V8_VERSION < 0x032117) v8::HandleScope scope; +#else + v8::HandleScope scope(v8::Isolate::GetCurrent()); +#endif + v8::Handle self = args.Holder(); $jslocals if(args.Length() != $jsargcount) SWIG_exception_fail(SWIG_ERROR, "Illegal number of arguments for $jswrapper."); @@ -201,7 +221,12 @@ void $jswrapper(v8::Isolate *isolate, v8::Persistent< v8::Object > * object, SWI %fragment("js_getter", "templates") %{ SwigV8ReturnValue $jswrapper(v8::Local property, const SwigV8PropertyCallbackInfo& info) { +#if (SWIG_V8_VERSION < 0x032117) v8::HandleScope scope; +#else + v8::HandleScope scope(v8::Isolate::GetCurrent()); +#endif + v8::Handle jsresult; $jslocals $jscode @@ -223,7 +248,12 @@ fail: %{ void $jswrapper(v8::Local property, v8::Local value, const SwigV8PropertyCallbackInfoVoid& info) { +#if (SWIG_V8_VERSION < 0x032117) v8::HandleScope scope; +#else + v8::HandleScope scope(v8::Isolate::GetCurrent()); +#endif + $jslocals $jscode goto fail; @@ -241,7 +271,12 @@ fail: %fragment("js_function", "templates") %{ SwigV8ReturnValue $jswrapper(const SwigV8Arguments& args) { +#if (SWIG_V8_VERSION < 0x032117) v8::HandleScope scope; +#else + v8::HandleScope scope(v8::Isolate::GetCurrent()); +#endif + v8::Handle jsresult; $jslocals if(args.Length() != $jsargcount) SWIG_exception_fail(SWIG_ERROR, "Illegal number of arguments for $jswrapper."); @@ -265,7 +300,12 @@ fail: %fragment("js_function_dispatcher", "templates") %{ SwigV8ReturnValue $jswrapper(const SwigV8Arguments& args) { +#if (SWIG_V8_VERSION < 0x032117) v8::HandleScope scope; +#else + v8::HandleScope scope(v8::Isolate::GetCurrent()); +#endif + v8::Handle jsresult; OverloadErrorHandler errorHandler; $jscode @@ -288,7 +328,12 @@ fail: %{ SwigV8ReturnValue $jswrapper(const SwigV8Arguments& args, V8ErrorHandler& SWIGV8_ErrorHandler) { +#if (SWIG_V8_VERSION < 0x032117) v8::HandleScope scope; +#else + v8::HandleScope scope(v8::Isolate::GetCurrent()); +#endif + v8::Handle jsresult; $jslocals $jscode diff --git a/Lib/javascript/v8/javascriptcomplex.swg b/Lib/javascript/v8/javascriptcomplex.swg index 70c5baffb..88573c2f2 100644 --- a/Lib/javascript/v8/javascriptcomplex.swg +++ b/Lib/javascript/v8/javascriptcomplex.swg @@ -15,7 +15,12 @@ SWIGINTERNINLINE v8::Handle SWIG_From_dec(Type)(%ifcplusplus(const Type&, Type) c) { +#if (SWIG_V8_VERSION < 0x032117) v8::HandleScope scope; +#else + v8::HandleScope scope(v8::Isolate::GetCurrent()); +#endif + v8::Local vals = v8::Array::New(2); vals->Set(0, SWIG_From(double)(Real(c))); @@ -33,7 +38,11 @@ SWIG_From_dec(Type)(%ifcplusplus(const Type&, Type) c) SWIGINTERN int SWIG_AsVal_dec(Type) (v8::Handle o, Type* val) { +#if (SWIG_V8_VERSION < 0x032117) v8::HandleScope scope; +#else + v8::HandleScope scope(v8::Isolate::GetCurrent()); +#endif if (o->IsArray()) { v8::Handle array = v8::Handle::Cast(o); @@ -75,7 +84,11 @@ SWIG_AsVal_dec(Type) (v8::Handle o, Type* val) SWIGINTERN int SWIG_AsVal_dec(Type) (v8::Handle o, Type* val) { +#if (SWIG_V8_VERSION < 0x032117) v8::HandleScope scope; +#else + v8::HandleScope scope(v8::Isolate::GetCurrent()); +#endif if (o->IsArray()) { v8::Handle array = v8::Handle::Cast(o); diff --git a/Lib/javascript/v8/javascripthelpers.swg b/Lib/javascript/v8/javascripthelpers.swg index ac352796e..630946d07 100644 --- a/Lib/javascript/v8/javascripthelpers.swg +++ b/Lib/javascript/v8/javascripthelpers.swg @@ -17,7 +17,12 @@ typedef v8::PropertyCallbackInfo SwigV8PropertyCallbackInfoVoid; * Creates a class template for a class with specified initialization function. */ SWIGRUNTIME v8::Handle SWIGV8_CreateClassTemplate(const char* symbol) { +#if (SWIG_V8_VERSION < 0x032117) v8::HandleScope scope; +#else + v8::HandleScope scope(v8::Isolate::GetCurrent()); +#endif + v8::Local class_templ = v8::FunctionTemplate::New(); class_templ->SetClassName(v8::String::NewSymbol(symbol)); diff --git a/Lib/javascript/v8/javascriptinit.swg b/Lib/javascript/v8/javascriptinit.swg index 651a39144..97b273dc1 100644 --- a/Lib/javascript/v8/javascriptinit.swg +++ b/Lib/javascript/v8/javascriptinit.swg @@ -61,7 +61,12 @@ void SWIGV8_INIT (v8::Handle exports, v8::Handle /*modul { SWIG_InitializeModule(static_cast(&exports)); +#if (SWIG_V8_VERSION < 0x032117) v8::HandleScope scope; +#else + v8::HandleScope scope(v8::Isolate::GetCurrent()); +#endif + v8::Handle exports_obj = exports; %} diff --git a/Lib/javascript/v8/javascriptrun.swg b/Lib/javascript/v8/javascriptrun.swg index 50e4c5b87..311902378 100644 --- a/Lib/javascript/v8/javascriptrun.swg +++ b/Lib/javascript/v8/javascriptrun.swg @@ -117,7 +117,11 @@ public: v8::Persistent SWIGV8_SWIGTYPE_Proxy_class_templ; int SWIG_V8_ConvertInstancePtr(v8::Handle objRef, void** ptr, swig_type_info *info, int flags) { +#if (SWIG_V8_VERSION < 0x032117) v8::HandleScope scope; +#else + v8::HandleScope scope(v8::Isolate::GetCurrent()); +#endif if(objRef->InternalFieldCount() < 1) return SWIG_ERROR; @@ -239,7 +243,12 @@ void SWIGV8_SetPrivateData(v8::Handle obj, void* ptr, swig_type_info } int SWIG_V8_ConvertPtr(v8::Handle valRef, void** ptr, swig_type_info *info, int flags) { +#if (SWIG_V8_VERSION < 0x032117) v8::HandleScope scope; +#else + v8::HandleScope scope(v8::Isolate::GetCurrent()); +#endif + /* special case: JavaScript null => C NULL pointer */ if(valRef->IsNull()) { *ptr=0; @@ -253,7 +262,12 @@ int SWIG_V8_ConvertPtr(v8::Handle valRef, void** ptr, swig_type_info } v8::Handle SWIG_V8_NewPointerObj(void *ptr, swig_type_info *info, int flags) { +#if (SWIG_V8_VERSION < 0x032117) v8::HandleScope scope; +#else + v8::HandleScope scope(v8::Isolate::GetCurrent()); +#endif + v8::Handle class_templ; if (ptr == NULL) { @@ -293,12 +307,14 @@ v8::Handle SWIG_V8_NewPointerObj(void *ptr, swig_type_info *info, int #define SWIG_GetInstancePtr(obj, ptr) SWIG_V8_GetInstancePtr(obj, ptr) -#if (SWIG_V8_VERSION < 0x031903) -v8::Handle _SWIGV8_wrap_equals(const v8::Arguments &args) { +SwigV8ReturnValue _SWIGV8_wrap_equals(const SwigV8Arguments &args) { + +#if (SWIG_V8_VERSION < 0x032117) + v8::HandleScope scope; #else -void _SWIGV8_wrap_equals(const v8::FunctionCallbackInfo& args) { + v8::HandleScope scope(v8::Isolate::GetCurrent()); #endif - v8::HandleScope scope; + v8::Handle jsresult; void *arg1 = (void *) 0 ; void *arg2 = (void *) 0 ; @@ -326,12 +342,14 @@ fail: SWIGV8_RETURN(v8::Undefined()); } -#if (SWIG_V8_VERSION < 0x031903) -v8::Handle _wrap_getCPtr(const v8::Arguments &args) { +SwigV8ReturnValue _wrap_getCPtr(const SwigV8Arguments &args) { + +#if (SWIG_V8_VERSION < 0x032117) + v8::HandleScope scope; #else -void _wrap_getCPtr(const v8::FunctionCallbackInfo& args) { + v8::HandleScope scope(v8::Isolate::GetCurrent()); #endif - v8::HandleScope scope; + v8::Handle jsresult; void *arg1 = (void *) 0 ; long result; @@ -372,7 +390,13 @@ public: SWIGRUNTIMEINLINE int SwigV8Packed_Check(v8::Handle valRef) { + +#if (SWIG_V8_VERSION < 0x032117) v8::HandleScope scope; +#else + v8::HandleScope scope(v8::Isolate::GetCurrent()); +#endif + v8::Handle objRef = valRef->ToObject(); if(objRef->InternalFieldCount() < 1) return false; v8::Handle flag = objRef->GetHiddenValue(v8::String::New("__swig__packed_data__")); @@ -382,7 +406,13 @@ int SwigV8Packed_Check(v8::Handle valRef) { SWIGRUNTIME swig_type_info* SwigV8Packed_UnpackData(v8::Handle valRef, void *ptr, size_t size) { if (SwigV8Packed_Check(valRef)) { + +#if (SWIG_V8_VERSION < 0x032117) v8::HandleScope scope; +#else + v8::HandleScope scope(v8::Isolate::GetCurrent()); +#endif + SwigV8PackedData *sobj; v8::Handle objRef = valRef->ToObject(); @@ -445,7 +475,11 @@ void _wrap_SwigV8PackedData_delete(v8::Isolate *isolate, v8::Persistent< v8::Obj SWIGRUNTIME v8::Handle SWIGV8_NewPackedObj(void *data, size_t size, swig_type_info *type) { +#if (SWIG_V8_VERSION < 0x032117) v8::HandleScope scope; +#else + v8::HandleScope scope(v8::Isolate::GetCurrent()); +#endif SwigV8PackedData* cdata = new SwigV8PackedData(data, size, type); v8::Handle obj = v8::Object::New(); @@ -497,7 +531,12 @@ v8::Handle SWIGV8_NewPackedObj(void *data, size_t size, swig_type_inf SWIGRUNTIME v8::Handle SWIGV8_AppendOutput(v8::Handle result, v8::Handle obj) { +#if (SWIG_V8_VERSION < 0x032117) v8::HandleScope scope; +#else + v8::HandleScope scope(v8::Isolate::GetCurrent()); +#endif + if (result->IsUndefined()) { result = v8::Array::New(); } diff --git a/Tools/javascript/v8_shell.cxx b/Tools/javascript/v8_shell.cxx index cf3836369..b8d777856 100644 --- a/Tools/javascript/v8_shell.cxx +++ b/Tools/javascript/v8_shell.cxx @@ -11,6 +11,22 @@ typedef int (*V8ExtensionInitializer) (v8::Handle module); +// Note: these typedefs and defines are used to deal with v8 API changes since version 3.19.00 + +#if (V8_VERSION < 0x031903) +typedef v8::Handle SwigV8ReturnValue; +typedef v8::Arguments SwigV8Arguments; +typedef v8::AccessorInfo SwigV8PropertyCallbackInfo; +#define SWIGV8_RETURN(val) return scope.Close(val) +#define SWIGV8_RETURN_INFO(val, info) return scope.Close(val) +#else +typedef void SwigV8ReturnValue; +typedef v8::FunctionCallbackInfo SwigV8Arguments; +typedef v8::PropertyCallbackInfo SwigV8PropertyCallbackInfo; +#define SWIGV8_RETURN(val) args.GetReturnValue().Set(val); return +#define SWIGV8_RETURN_INFO(val, info) info.GetReturnValue().Set(val); return +#endif + class V8Shell: public JSShell { public: @@ -43,13 +59,13 @@ private: void ReportException(v8::TryCatch* handler); - static v8::Handle Print(const v8::Arguments& args); + static SwigV8ReturnValue Print(const SwigV8Arguments& args); - static v8::Handle Require(const v8::Arguments& args); + static SwigV8ReturnValue Require(const SwigV8Arguments& args); - static v8::Handle Quit(const v8::Arguments& args); + static SwigV8ReturnValue Quit(const SwigV8Arguments& args); - static v8::Handle Version(const v8::Arguments& args); + static SwigV8ReturnValue Version(const SwigV8Arguments& args); static const char* ToCString(const v8::String::Utf8Value& value); @@ -69,7 +85,11 @@ V8Shell::~V8Shell() {} bool V8Shell::RunScript(const std::string& scriptPath) { std::string source = ReadFile(scriptPath); +#if (V8_VERSION < 0x032117) v8::HandleScope scope; +#else + v8::HandleScope scope(v8::Isolate::GetCurrent()); +#endif #if (V8_VERSION < 0x031900) v8::Persistent context = CreateShellContext(); @@ -113,7 +133,12 @@ bool V8Shell::RunScript(const std::string& scriptPath) { } bool V8Shell::RunShell() { +#if (V8_VERSION < 0x032117) v8::HandleScope scope; +#else + v8::HandleScope scope(v8::Isolate::GetCurrent()); +#endif + #if (V8_VERSION < 0x031900) v8::Persistent context = CreateShellContext(); @@ -166,7 +191,13 @@ bool V8Shell::InitializeEngine() { } bool V8Shell::ExecuteScript(const std::string& source, const std::string& name) { - v8::HandleScope handle_scope; +#if (V8_VERSION < 0x032117) + v8::HandleScope scope; +#else + v8::HandleScope scope(v8::Isolate::GetCurrent()); +#endif + + v8::TryCatch try_catch; v8::Handle script = v8::Script::Compile(v8::String::New(source.c_str()), v8::String::New(name.c_str())); @@ -197,7 +228,12 @@ v8::Persistent V8Shell::CreateShellContext() { #else v8::Local V8Shell::CreateShellContext() { #endif + +#if (V8_VERSION < 0x032117) v8::HandleScope scope; +#else + v8::HandleScope scope(v8::Isolate::GetCurrent()); +#endif // Create a template for the global object. v8::Handle global = v8::ObjectTemplate::New(); @@ -224,7 +260,12 @@ v8::Local V8Shell::CreateShellContext() { v8::Handle V8Shell::Import(const std::string& module_path) { +#if (V8_VERSION < 0x032117) v8::HandleScope scope; +#else + v8::HandleScope scope(v8::Isolate::GetCurrent()); +#endif + HANDLE library; std::string module_name = LoadModule(module_path, &library); @@ -243,10 +284,16 @@ v8::Handle V8Shell::Import(const std::string& module_path) return scope.Close(module); } -v8::Handle V8Shell::Print(const v8::Arguments& args) { +SwigV8ReturnValue V8Shell::Print(const SwigV8Arguments& args) { bool first = true; for (int i = 0; i < args.Length(); i++) { - v8::HandleScope handle_scope; + +#if (V8_VERSION < 0x032117) + v8::HandleScope scope; +#else + v8::HandleScope scope(v8::Isolate::GetCurrent()); +#endif + if (first) { first = false; } else { @@ -258,11 +305,16 @@ v8::Handle V8Shell::Print(const v8::Arguments& args) { } printf("\n"); fflush(stdout); - return v8::Undefined(); + SWIGV8_RETURN(v8::Undefined()); } -v8::Handle V8Shell::Require(const v8::Arguments& args) { +SwigV8ReturnValue V8Shell::Require(const SwigV8Arguments& args) { +#if (V8_VERSION < 0x032117) v8::HandleScope scope; +#else + v8::HandleScope scope(v8::Isolate::GetCurrent()); +#endif + if (args.Length() != 1) { printf("Illegal arguments for `require`"); @@ -279,23 +331,29 @@ v8::Handle V8Shell::Require(const v8::Arguments& args) { v8::Handle module = _this->Import(moduleName); - return scope.Close(module); + SWIGV8_RETURN(module); } -v8::Handle V8Shell::Quit(const v8::Arguments& args) { +SwigV8ReturnValue V8Shell::Quit(const SwigV8Arguments& args) { int exit_code = args[0]->Int32Value(); fflush(stdout); fflush(stderr); exit(exit_code); - return v8::Undefined(); + SWIGV8_RETURN(v8::Undefined()); } -v8::Handle V8Shell::Version(const v8::Arguments& args) { - return v8::String::New(v8::V8::GetVersion()); +SwigV8ReturnValue V8Shell::Version(const SwigV8Arguments& args) { + SWIGV8_RETURN(v8::String::New(v8::V8::GetVersion())); } void V8Shell::ReportException(v8::TryCatch* try_catch) { - v8::HandleScope handle_scope; +#if (V8_VERSION < 0x032117) + v8::HandleScope scope; +#else + v8::HandleScope scope(v8::Isolate::GetCurrent()); +#endif + + v8::String::Utf8Value exception(try_catch->Exception()); const char* exception_string = V8Shell::ToCString(exception); v8::Handle message = try_catch->Message(); -- cgit v1.2.1 From 98b1fca4d8e71dc25fec68906e193d74765db074 Mon Sep 17 00:00:00 2001 From: Richard Date: Thu, 21 Aug 2014 20:52:08 -0500 Subject: Fixed for v8 3.25.30 (0x032530) --- Tools/javascript/Makefile.in | 2 +- Tools/javascript/v8_shell.cxx | 175 +++++++++++++++++++----------------------- 2 files changed, 81 insertions(+), 96 deletions(-) diff --git a/Tools/javascript/Makefile.in b/Tools/javascript/Makefile.in index a08ed4760..8e8a9b4f4 100644 --- a/Tools/javascript/Makefile.in +++ b/Tools/javascript/Makefile.in @@ -49,7 +49,7 @@ Makefile: $(srcdir)/Makefile.in ../../config.status # These settings are provided by 'configure' (see '/configure.in') ifeq (1, $(JSV8ENABLED)) JS_INTERPRETER_SRC_V8 = v8_shell.cxx -JS_INTERPRETER_ENABLE_V8 = -DENABLE_V8 -DV8_VERSION=$(JSV8_VERSION) +JS_INTERPRETER_ENABLE_V8 = -DENABLE_V8 -DSWIG_V8_VERSION=$(JSV8_VERSION) endif ifeq (1, $(JSCENABLED)) diff --git a/Tools/javascript/v8_shell.cxx b/Tools/javascript/v8_shell.cxx index b8d777856..b035eb2c0 100644 --- a/Tools/javascript/v8_shell.cxx +++ b/Tools/javascript/v8_shell.cxx @@ -13,7 +13,7 @@ typedef int (*V8ExtensionInitializer) (v8::Handle module); // Note: these typedefs and defines are used to deal with v8 API changes since version 3.19.00 -#if (V8_VERSION < 0x031903) +#if (SWIG_V8_VERSION < 0x031903) typedef v8::Handle SwigV8ReturnValue; typedef v8::Arguments SwigV8Arguments; typedef v8::AccessorInfo SwigV8PropertyCallbackInfo; @@ -27,6 +27,44 @@ typedef v8::PropertyCallbackInfo SwigV8PropertyCallbackInfo; #define SWIGV8_RETURN_INFO(val, info) info.GetReturnValue().Set(val); return #endif + +#if (SWIG_V8_VERSION < 0x032117) +#define SWIGV8_HANDLESCOPE() v8::HandleScope scope +#define SWIGV8_HANDLESCOPE_ESC() v8::HandleScope scope +#define SWIGV8_ESCAPE(val) return scope.Close(val) +#elif (SWIG_V8_VERSION < 0x032530) +#define SWIGV8_HANDLESCOPE() v8::HandleScope scope(v8::Isolate::GetCurrent()); +#define SWIGV8_HANDLESCOPE_ESC() v8::HandleScope scope(v8::Isolate::GetCurrent()); +#define SWIGV8_ESCAPE(val) return scope.Close(val) +#else +#define SWIGV8_HANDLESCOPE() v8::HandleScope scope(v8::Isolate::GetCurrent()); +#define SWIGV8_HANDLESCOPE_ESC() v8::EscapableHandleScope scope(v8::Isolate::GetCurrent()); +#define SWIGV8_ESCAPE(val) return scope.Escape(val) +#endif + +#if (SWIG_V8_VERSION < 0x032530) +#define SWIGV8_CURRENT_CONTEXT() v8::Context::GetCurrent() +#define SWIGV8_STRING_NEW(str) v8::String::New(str) +#define SWIGV8_FUNCTEMPLATE_NEW(func) v8::FunctionTemplate::New(func) +#define SWIGV8_OBJECT_NEW() v8::Object::New() +#define SWIGV8_EXTERNAL_NEW(val) v8::External::New(val) +#define SWIGV8_UNDEFINED() v8::Undefined() +#else +#define SWIGV8_CURRENT_CONTEXT() v8::Isolate::GetCurrent()->GetCurrentContext() +#define SWIGV8_STRING_NEW(str) v8::String::NewFromUtf8(v8::Isolate::GetCurrent(), str) +#define SWIGV8_FUNCTEMPLATE_NEW(func) v8::FunctionTemplate::New(v8::Isolate::GetCurrent(), func) +#define SWIGV8_OBJECT_NEW() v8::Object::New(v8::Isolate::GetCurrent()) +#define SWIGV8_EXTERNAL_NEW(val) v8::External::New(v8::Isolate::GetCurrent(), val) +#define SWIGV8_UNDEFINED() v8::Undefined(v8::Isolate::GetCurrent()) +#endif + + +#if (SWIG_V8_VERSION < 0x031900) +typedef v8::Persistent SwigV8Context; +#else +typedef v8::Local SwigV8Context; +#endif + class V8Shell: public JSShell { public: @@ -51,11 +89,7 @@ private: v8::Handle Import(const std::string& moduleName); -#if (V8_VERSION < 0x031900) - v8::Persistent CreateShellContext(); -#else - v8::Local CreateShellContext(); -#endif + SwigV8Context CreateShellContext(); void ReportException(v8::TryCatch* handler); @@ -85,17 +119,9 @@ V8Shell::~V8Shell() {} bool V8Shell::RunScript(const std::string& scriptPath) { std::string source = ReadFile(scriptPath); -#if (V8_VERSION < 0x032117) - v8::HandleScope scope; -#else - v8::HandleScope scope(v8::Isolate::GetCurrent()); -#endif + SWIGV8_HANDLESCOPE(); -#if (V8_VERSION < 0x031900) - v8::Persistent context = CreateShellContext(); -#else - v8::Local context = CreateShellContext(); -#endif + SwigV8Context context = CreateShellContext(); if (context.IsEmpty()) { printf("Could not create context.\n"); @@ -107,8 +133,9 @@ bool V8Shell::RunScript(const std::string& scriptPath) { // Store a pointer to this shell for later use v8::Handle global = context->Global(); - v8::Local __shell__ = v8::External::New((void*) (long) this); - global->SetHiddenValue(v8::String::New("__shell__"), __shell__); + v8::Local __shell__ = SWIGV8_EXTERNAL_NEW((void*) (long) this); + + global->SetHiddenValue(SWIGV8_STRING_NEW("__shell__"), __shell__); // Node.js compatibility: make `print` available as `console.log()` ExecuteScript("var console = {}; console.log = print;", ""); @@ -119,9 +146,9 @@ bool V8Shell::RunScript(const std::string& scriptPath) { context->Exit(); -#if (V8_VERSION < 0x031710) +#if (SWIG_V8_VERSION < 0x031710) context.Dispose(); -#elif (V8_VERSION < 0x031900) +#elif (SWIG_V8_VERSION < 0x031900) context.Dispose(v8::Isolate::GetCurrent()); #else // context.Dispose(); @@ -133,18 +160,9 @@ bool V8Shell::RunScript(const std::string& scriptPath) { } bool V8Shell::RunShell() { -#if (V8_VERSION < 0x032117) - v8::HandleScope scope; -#else - v8::HandleScope scope(v8::Isolate::GetCurrent()); -#endif - + SWIGV8_HANDLESCOPE(); -#if (V8_VERSION < 0x031900) - v8::Persistent context = CreateShellContext(); -#else - v8::Local context = CreateShellContext(); -#endif + SwigV8Context context = CreateShellContext(); if (context.IsEmpty()) { printf("Could not create context.\n"); @@ -172,9 +190,9 @@ bool V8Shell::RunShell() { context->Exit(); -#if (V8_VERSION < 0x031710) +#if (SWIG_V8_VERSION < 0x031710) context.Dispose(); -#elif (V8_VERSION < 0x031900) +#elif (SWIG_V8_VERSION < 0x031900) context.Dispose(v8::Isolate::GetCurrent()); #else // context.Dispose(); @@ -191,15 +209,10 @@ bool V8Shell::InitializeEngine() { } bool V8Shell::ExecuteScript(const std::string& source, const std::string& name) { -#if (V8_VERSION < 0x032117) - v8::HandleScope scope; -#else - v8::HandleScope scope(v8::Isolate::GetCurrent()); -#endif - + SWIGV8_HANDLESCOPE(); v8::TryCatch try_catch; - v8::Handle script = v8::Script::Compile(v8::String::New(source.c_str()), v8::String::New(name.c_str())); + v8::Handle script = v8::Script::Compile(SWIGV8_STRING_NEW(source.c_str()), SWIGV8_STRING_NEW(name.c_str())); // Stop if script is empty if (script.IsEmpty()) { @@ -223,49 +236,30 @@ bool V8Shell::DisposeEngine() { return true; } -#if (V8_VERSION < 0x031900) -v8::Persistent V8Shell::CreateShellContext() { -#else -v8::Local V8Shell::CreateShellContext() { -#endif - -#if (V8_VERSION < 0x032117) - v8::HandleScope scope; -#else - v8::HandleScope scope(v8::Isolate::GetCurrent()); -#endif +SwigV8Context V8Shell::CreateShellContext() { + SWIGV8_HANDLESCOPE_ESC(); // Create a template for the global object. v8::Handle global = v8::ObjectTemplate::New(); // Bind global functions - global->Set(v8::String::New("print"), v8::FunctionTemplate::New(V8Shell::Print)); - global->Set(v8::String::New("quit"), v8::FunctionTemplate::New(V8Shell::Quit)); - global->Set(v8::String::New("require"), v8::FunctionTemplate::New(V8Shell::Require)); - global->Set(v8::String::New("version"), v8::FunctionTemplate::New(V8Shell::Version)); + global->Set(SWIGV8_STRING_NEW("print"), SWIGV8_FUNCTEMPLATE_NEW(V8Shell::Print)); + global->Set(SWIGV8_STRING_NEW("quit"), SWIGV8_FUNCTEMPLATE_NEW(V8Shell::Quit)); + global->Set(SWIGV8_STRING_NEW("require"), SWIGV8_FUNCTEMPLATE_NEW(V8Shell::Require)); + global->Set(SWIGV8_STRING_NEW("version"), SWIGV8_FUNCTEMPLATE_NEW(V8Shell::Version)); - -#if (V8_VERSION < 0x031900) - v8::Persistent context = v8::Context::New(NULL, global); +#if (SWIG_V8_VERSION < 0x031900) + SwigV8Context context = v8::Context::New(NULL, global); return context; #else -// v8::Local context_ = v8::Context::New(v8::Isolate::GetCurrent(), NULL, global); -// v8::Persistent context; -// context.Reset(v8::Isolate::GetCurrent(), context_); - v8::Local context = v8::Context::New(v8::Isolate::GetCurrent(), NULL, global); - return scope.Close(context); + SwigV8Context context = v8::Context::New(v8::Isolate::GetCurrent(), NULL, global); + SWIGV8_ESCAPE(context); #endif - } v8::Handle V8Shell::Import(const std::string& module_path) { -#if (V8_VERSION < 0x032117) - v8::HandleScope scope; -#else - v8::HandleScope scope(v8::Isolate::GetCurrent()); -#endif - + SWIGV8_HANDLESCOPE_ESC(); HANDLE library; std::string module_name = LoadModule(module_path, &library); @@ -276,23 +270,21 @@ v8::Handle V8Shell::Import(const std::string& module_path) if(init_function == 0) { printf("Could not find initializer function."); - return v8::Undefined(); + + return SWIGV8_UNDEFINED(); } - v8::Local module = v8::Object::New(); + v8::Local module = SWIGV8_OBJECT_NEW(); init_function(module); - return scope.Close(module); + + SWIGV8_ESCAPE(module); } SwigV8ReturnValue V8Shell::Print(const SwigV8Arguments& args) { bool first = true; for (int i = 0; i < args.Length(); i++) { -#if (V8_VERSION < 0x032117) - v8::HandleScope scope; -#else - v8::HandleScope scope(v8::Isolate::GetCurrent()); -#endif + SWIGV8_HANDLESCOPE(); if (first) { first = false; @@ -305,16 +297,12 @@ SwigV8ReturnValue V8Shell::Print(const SwigV8Arguments& args) { } printf("\n"); fflush(stdout); - SWIGV8_RETURN(v8::Undefined()); + + SWIGV8_RETURN(SWIGV8_UNDEFINED()); } SwigV8ReturnValue V8Shell::Require(const SwigV8Arguments& args) { -#if (V8_VERSION < 0x032117) - v8::HandleScope scope; -#else - v8::HandleScope scope(v8::Isolate::GetCurrent()); -#endif - + SWIGV8_HANDLESCOPE(); if (args.Length() != 1) { printf("Illegal arguments for `require`"); @@ -324,8 +312,9 @@ SwigV8ReturnValue V8Shell::Require(const SwigV8Arguments& args) { const char* cstr = V8Shell::ToCString(str); std::string moduleName(cstr); - v8::Local global = v8::Context::GetCurrent()->Global(); - v8::Local hidden = global->GetHiddenValue(v8::String::New("__shell__")); + v8::Local global = SWIGV8_CURRENT_CONTEXT()->Global(); + + v8::Local hidden = global->GetHiddenValue(SWIGV8_STRING_NEW("__shell__")); v8::Local __shell__ = v8::Local::Cast(hidden); V8Shell* _this = (V8Shell*) (long) __shell__->Value(); @@ -339,20 +328,16 @@ SwigV8ReturnValue V8Shell::Quit(const SwigV8Arguments& args) { fflush(stdout); fflush(stderr); exit(exit_code); - SWIGV8_RETURN(v8::Undefined()); + + SWIGV8_RETURN(SWIGV8_UNDEFINED()); } SwigV8ReturnValue V8Shell::Version(const SwigV8Arguments& args) { - SWIGV8_RETURN(v8::String::New(v8::V8::GetVersion())); + SWIGV8_RETURN(SWIGV8_STRING_NEW(v8::V8::GetVersion())); } void V8Shell::ReportException(v8::TryCatch* try_catch) { -#if (V8_VERSION < 0x032117) - v8::HandleScope scope; -#else - v8::HandleScope scope(v8::Isolate::GetCurrent()); -#endif - + SWIGV8_HANDLESCOPE(); v8::String::Utf8Value exception(try_catch->Exception()); const char* exception_string = V8Shell::ToCString(exception); -- cgit v1.2.1 From e0c0670540235420626649dadc86d96b676b5f19 Mon Sep 17 00:00:00 2001 From: Richard Date: Thu, 21 Aug 2014 20:52:48 -0500 Subject: Partially fixed for 3.25.30 (0x032530) - unfinished --- Lib/javascript/v8/javascriptcode.swg | 82 +++++------------- Lib/javascript/v8/javascriptcomplex.swg | 22 ++--- Lib/javascript/v8/javascripthelpers.swg | 24 +++--- Lib/javascript/v8/javascriptinit.swg | 16 ++-- Lib/javascript/v8/javascriptprimtypes.swg | 12 +-- Lib/javascript/v8/javascriptrun.swg | 139 ++++++++++++++++-------------- Lib/javascript/v8/javascriptstrings.swg | 6 +- Lib/javascript/v8/javascripttypemaps.swg | 2 +- 8 files changed, 129 insertions(+), 174 deletions(-) diff --git a/Lib/javascript/v8/javascriptcode.swg b/Lib/javascript/v8/javascriptcode.swg index 85e26d5f3..e82720e1c 100644 --- a/Lib/javascript/v8/javascriptcode.swg +++ b/Lib/javascript/v8/javascriptcode.swg @@ -9,11 +9,7 @@ %fragment("js_ctor", "templates") %{ SwigV8ReturnValue $jswrapper(const SwigV8Arguments& args) { -#if (SWIG_V8_VERSION < 0x032117) - v8::HandleScope scope; -#else - v8::HandleScope scope(v8::Isolate::GetCurrent()); -#endif + SWIGV8_HANDLESCOPE(); v8::Handle self = args.Holder(); $jslocals @@ -25,7 +21,7 @@ SwigV8ReturnValue $jswrapper(const SwigV8Arguments& args) { goto fail; fail: - SWIGV8_RETURN(v8::Undefined()); + SWIGV8_RETURN(SWIGV8_UNDEFINED()); } %} @@ -37,14 +33,10 @@ fail: %fragment ("js_veto_ctor", "templates") %{ SwigV8ReturnValue $jswrapper(const SwigV8Arguments& args) { -#if (SWIG_V8_VERSION < 0x032117) - v8::HandleScope scope; -#else - v8::HandleScope scope(v8::Isolate::GetCurrent()); -#endif + SWIGV8_HANDLESCOPE(); SWIG_exception(SWIG_ERROR, "Class $jsname can not be instantiated"); - SWIGV8_RETURN(v8::Undefined()); + SWIGV8_RETURN(SWIGV8_UNDEFINED()); } %} @@ -57,11 +49,7 @@ SwigV8ReturnValue $jswrapper(const SwigV8Arguments& args) { %fragment ("js_ctor_dispatcher", "templates") %{ SwigV8ReturnValue $jswrapper(const SwigV8Arguments& args) { -#if (SWIG_V8_VERSION < 0x032117) - v8::HandleScope scope; -#else - v8::HandleScope scope(v8::Isolate::GetCurrent()); -#endif + SWIGV8_HANDLESCOPE(); OverloadErrorHandler errorHandler; v8::Handle self; @@ -73,7 +61,7 @@ SwigV8ReturnValue $jswrapper(const SwigV8Arguments& args) { SWIG_exception_fail(SWIG_ERROR, "Illegal arguments for construction of $jsmangledname"); fail: - SWIGV8_RETURN(v8::Undefined()); + SWIGV8_RETURN(SWIGV8_UNDEFINED()); } %} @@ -87,11 +75,7 @@ fail: * ----------------------------------------------------------------------------- */ %fragment("js_overloaded_ctor", "templates") %{ SwigV8ReturnValue $jswrapper(const SwigV8Arguments& args, V8ErrorHandler& SWIGV8_ErrorHandler) { -#if (SWIG_V8_VERSION < 0x032117) - v8::HandleScope scope; -#else - v8::HandleScope scope(v8::Isolate::GetCurrent()); -#endif + SWIGV8_HANDLESCOPE(); v8::Handle self = args.Holder(); $jslocals @@ -103,7 +87,7 @@ SwigV8ReturnValue $jswrapper(const SwigV8Arguments& args, V8ErrorHandler& SWIGV8 goto fail; fail: - SWIGV8_RETURN(v8::Undefined()); + SWIGV8_RETURN(SWIGV8_UNDEFINED()); } %} @@ -118,10 +102,10 @@ fail: %{ if(args.Length() == $jsargcount) { errorHandler.err.Clear(); -#if SWIG_V8_VERSION < 0x031903 +#if (SWIG_V8_VERSION < 0x031903) self = $jswrapper(args, errorHandler); if(errorHandler.err.IsEmpty()) { - return scope.Close(self); + SWIGV8_ESCAPE(self); } #else $jswrapper(args, errorHandler); @@ -221,11 +205,7 @@ void $jswrapper(v8::Isolate *isolate, v8::Persistent< v8::Object > * object, SWI %fragment("js_getter", "templates") %{ SwigV8ReturnValue $jswrapper(v8::Local property, const SwigV8PropertyCallbackInfo& info) { -#if (SWIG_V8_VERSION < 0x032117) - v8::HandleScope scope; -#else - v8::HandleScope scope(v8::Isolate::GetCurrent()); -#endif + SWIGV8_HANDLESCOPE(); v8::Handle jsresult; $jslocals @@ -234,7 +214,7 @@ SwigV8ReturnValue $jswrapper(v8::Local property, const SwigV8Propert goto fail; fail: - SWIGV8_RETURN_INFO(v8::Undefined(), info); + SWIGV8_RETURN_INFO(SWIGV8_UNDEFINED(), info); } %} @@ -248,11 +228,7 @@ fail: %{ void $jswrapper(v8::Local property, v8::Local value, const SwigV8PropertyCallbackInfoVoid& info) { -#if (SWIG_V8_VERSION < 0x032117) - v8::HandleScope scope; -#else - v8::HandleScope scope(v8::Isolate::GetCurrent()); -#endif + SWIGV8_HANDLESCOPE(); $jslocals $jscode @@ -271,11 +247,7 @@ fail: %fragment("js_function", "templates") %{ SwigV8ReturnValue $jswrapper(const SwigV8Arguments& args) { -#if (SWIG_V8_VERSION < 0x032117) - v8::HandleScope scope; -#else - v8::HandleScope scope(v8::Isolate::GetCurrent()); -#endif + SWIGV8_HANDLESCOPE(); v8::Handle jsresult; $jslocals @@ -286,7 +258,7 @@ SwigV8ReturnValue $jswrapper(const SwigV8Arguments& args) { goto fail; fail: - SWIGV8_RETURN(v8::Undefined()); + SWIGV8_RETURN(SWIGV8_UNDEFINED()); } %} @@ -300,11 +272,7 @@ fail: %fragment("js_function_dispatcher", "templates") %{ SwigV8ReturnValue $jswrapper(const SwigV8Arguments& args) { -#if (SWIG_V8_VERSION < 0x032117) - v8::HandleScope scope; -#else - v8::HandleScope scope(v8::Isolate::GetCurrent()); -#endif + SWIGV8_HANDLESCOPE(); v8::Handle jsresult; OverloadErrorHandler errorHandler; @@ -314,7 +282,7 @@ SwigV8ReturnValue $jswrapper(const SwigV8Arguments& args) { goto fail; fail: - SWIGV8_RETURN(v8::Undefined()); + SWIGV8_RETURN(SWIGV8_UNDEFINED()); } %} @@ -328,11 +296,7 @@ fail: %{ SwigV8ReturnValue $jswrapper(const SwigV8Arguments& args, V8ErrorHandler& SWIGV8_ErrorHandler) { -#if (SWIG_V8_VERSION < 0x032117) - v8::HandleScope scope; -#else - v8::HandleScope scope(v8::Isolate::GetCurrent()); -#endif + SWIGV8_HANDLESCOPE(); v8::Handle jsresult; $jslocals @@ -341,7 +305,7 @@ SwigV8ReturnValue $jswrapper(const SwigV8Arguments& args, V8ErrorHandler& SWIGV8 goto fail; fail: - SWIGV8_RETURN(v8::Undefined()); + SWIGV8_RETURN(SWIGV8_UNDEFINED()); } %} @@ -359,7 +323,7 @@ fail: #if (SWIG_V8_VERSION < 0x031903) jsresult = $jswrapper(args, errorHandler); if(errorHandler.err.IsEmpty()) { - return scope.Close(jsresult); + SWIGV8_ESCAPE(jsresult); } #else $jswrapper(args, errorHandler); @@ -453,7 +417,7 @@ fail: * ----------------------------------------------------------------------------- */ %fragment("jsv8_register_class", "templates") %{ - $jsparent_obj->Set(v8::String::NewSymbol("$jsname"), $jsmangledname_obj); + $jsparent_obj->Set(SWIGV8_SYMBOL_NEW("$jsname"), $jsmangledname_obj); %} /* ----------------------------------------------------------------------------- @@ -462,7 +426,7 @@ fail: * ----------------------------------------------------------------------------- */ %fragment("jsv8_create_namespace", "templates") %{ - v8::Handle $jsmangledname_obj = v8::Object::New(); + v8::Handle $jsmangledname_obj = SWIGV8_OBJECT_NEW(); %} /* ----------------------------------------------------------------------------- @@ -473,7 +437,7 @@ fail: * ----------------------------------------------------------------------------- */ %fragment("jsv8_register_namespace", "templates") %{ - $jsparent_obj->Set(v8::String::NewSymbol("$jsname"), $jsmangledname_obj); + $jsparent_obj->Set(SWIGV8_SYMBOL_NEW("$jsname"), $jsmangledname_obj); %} /* ----------------------------------------------------------------------------- diff --git a/Lib/javascript/v8/javascriptcomplex.swg b/Lib/javascript/v8/javascriptcomplex.swg index 88573c2f2..683b972bc 100644 --- a/Lib/javascript/v8/javascriptcomplex.swg +++ b/Lib/javascript/v8/javascriptcomplex.swg @@ -15,17 +15,13 @@ SWIGINTERNINLINE v8::Handle SWIG_From_dec(Type)(%ifcplusplus(const Type&, Type) c) { -#if (SWIG_V8_VERSION < 0x032117) - v8::HandleScope scope; -#else - v8::HandleScope scope(v8::Isolate::GetCurrent()); -#endif + SWIGV8_HANDLESCOPE_ESC(); - v8::Local vals = v8::Array::New(2); + v8::Local vals = SWIGV8_ARRAY_NEW(2); vals->Set(0, SWIG_From(double)(Real(c))); vals->Set(1, SWIG_From(double)(Imag(c))); - return scope.Close(vals); + SWIGV8_ESCAPE(vals); } } %enddef @@ -38,11 +34,7 @@ SWIG_From_dec(Type)(%ifcplusplus(const Type&, Type) c) SWIGINTERN int SWIG_AsVal_dec(Type) (v8::Handle o, Type* val) { -#if (SWIG_V8_VERSION < 0x032117) - v8::HandleScope scope; -#else - v8::HandleScope scope(v8::Isolate::GetCurrent()); -#endif + SWIGV8_HANDLESCOPE(); if (o->IsArray()) { v8::Handle array = v8::Handle::Cast(o); @@ -84,11 +76,7 @@ SWIG_AsVal_dec(Type) (v8::Handle o, Type* val) SWIGINTERN int SWIG_AsVal_dec(Type) (v8::Handle o, Type* val) { -#if (SWIG_V8_VERSION < 0x032117) - v8::HandleScope scope; -#else - v8::HandleScope scope(v8::Isolate::GetCurrent()); -#endif + SWIGV8_HANDLESCOPE(); if (o->IsArray()) { v8::Handle array = v8::Handle::Cast(o); diff --git a/Lib/javascript/v8/javascripthelpers.swg b/Lib/javascript/v8/javascripthelpers.swg index 630946d07..969225401 100644 --- a/Lib/javascript/v8/javascripthelpers.swg +++ b/Lib/javascript/v8/javascripthelpers.swg @@ -17,25 +17,21 @@ typedef v8::PropertyCallbackInfo SwigV8PropertyCallbackInfoVoid; * Creates a class template for a class with specified initialization function. */ SWIGRUNTIME v8::Handle SWIGV8_CreateClassTemplate(const char* symbol) { -#if (SWIG_V8_VERSION < 0x032117) - v8::HandleScope scope; -#else - v8::HandleScope scope(v8::Isolate::GetCurrent()); -#endif + SWIGV8_HANDLESCOPE_ESC(); - v8::Local class_templ = v8::FunctionTemplate::New(); - class_templ->SetClassName(v8::String::NewSymbol(symbol)); + v8::Local class_templ = SWIGV8_FUNCTEMPLATE_NEW_VOID(); + class_templ->SetClassName(SWIGV8_SYMBOL_NEW(symbol)); v8::Handle inst_templ = class_templ->InstanceTemplate(); inst_templ->SetInternalFieldCount(1); v8::Handle equals_templ = class_templ->PrototypeTemplate(); - equals_templ->Set(v8::String::NewSymbol("equals"), v8::FunctionTemplate::New(_SWIGV8_wrap_equals)); + equals_templ->Set(SWIGV8_SYMBOL_NEW("equals"), SWIGV8_FUNCTEMPLATE_NEW(_SWIGV8_wrap_equals)); v8::Handle cptr_templ = class_templ->PrototypeTemplate(); - cptr_templ->Set(v8::String::NewSymbol("getCPtr"), v8::FunctionTemplate::New(_wrap_getCPtr)); + cptr_templ->Set(SWIGV8_SYMBOL_NEW("getCPtr"), SWIGV8_FUNCTEMPLATE_NEW(_wrap_getCPtr)); - return scope.Close(class_templ); + SWIGV8_ESCAPE(class_templ); } /** @@ -44,7 +40,7 @@ SWIGRUNTIME v8::Handle SWIGV8_CreateClassTemplate(const ch SWIGRUNTIME void SWIGV8_AddMemberFunction(v8::Handle class_templ, const char* symbol, SwigV8FunctionCallback _func) { v8::Handle proto_templ = class_templ->PrototypeTemplate(); - proto_templ->Set(v8::String::NewSymbol(symbol), v8::FunctionTemplate::New(_func)); + proto_templ->Set(SWIGV8_SYMBOL_NEW(symbol), SWIGV8_FUNCTEMPLATE_NEW(_func)); } /** @@ -53,7 +49,7 @@ SWIGRUNTIME void SWIGV8_AddMemberFunction(v8::Handle class SWIGRUNTIME void SWIGV8_AddMemberVariable(v8::Handle class_templ, const char* symbol, SwigV8AccessorGetterCallback getter, SwigV8AccessorSetterCallback setter) { v8::Handle proto_templ = class_templ->InstanceTemplate(); - proto_templ->SetAccessor(v8::String::NewSymbol(symbol), getter, setter); + proto_templ->SetAccessor(SWIGV8_SYMBOL_NEW(symbol), getter, setter); } /** @@ -61,7 +57,7 @@ SWIGRUNTIME void SWIGV8_AddMemberVariable(v8::Handle class */ SWIGRUNTIME void SWIGV8_AddStaticFunction(v8::Handle obj, const char* symbol, const SwigV8FunctionCallback& _func) { - obj->Set(v8::String::NewSymbol(symbol), v8::FunctionTemplate::New(_func)->GetFunction()); + obj->Set(SWIGV8_SYMBOL_NEW(symbol), SWIGV8_FUNCTEMPLATE_NEW(_func)->GetFunction()); } /** @@ -69,7 +65,7 @@ SWIGRUNTIME void SWIGV8_AddStaticFunction(v8::Handle obj, const char */ SWIGRUNTIME void SWIGV8_AddStaticVariable(v8::Handle obj, const char* symbol, SwigV8AccessorGetterCallback getter, SwigV8AccessorSetterCallback setter) { - obj->SetAccessor(v8::String::NewSymbol(symbol), getter, setter); + obj->SetAccessor(SWIGV8_SYMBOL_NEW(symbol), getter, setter); } SWIGRUNTIME void JS_veto_set_variable(v8::Local property, v8::Local value, diff --git a/Lib/javascript/v8/javascriptinit.swg b/Lib/javascript/v8/javascriptinit.swg index 97b273dc1..03ea5e658 100644 --- a/Lib/javascript/v8/javascriptinit.swg +++ b/Lib/javascript/v8/javascriptinit.swg @@ -4,16 +4,16 @@ SWIGRUNTIME void SWIG_V8_SetModule(void *, swig_module_info *swig_module) { - v8::Local global_obj = v8::Context::GetCurrent()->Global(); - v8::Local mod = v8::External::New(swig_module); + v8::Local global_obj = SWIGV8_CURRENT_CONTEXT()->Global(); + v8::Local mod = SWIGV8_EXTERNAL_NEW(swig_module); assert(!mod.IsEmpty()); - global_obj->SetHiddenValue(v8::String::New("swig_module_info_data"), mod); + global_obj->SetHiddenValue(SWIGV8_STRING_NEW("swig_module_info_data"), mod); } SWIGRUNTIME swig_module_info * SWIG_V8_GetModule(void *) { - v8::Local global_obj = v8::Context::GetCurrent()->Global(); - v8::Local moduleinfo = global_obj->GetHiddenValue(v8::String::New("swig_module_info_data")); + v8::Local global_obj = SWIGV8_CURRENT_CONTEXT()->Global(); + v8::Local moduleinfo = global_obj->GetHiddenValue(SWIGV8_STRING_NEW("swig_module_info_data")); if (moduleinfo.IsEmpty()) { @@ -61,11 +61,7 @@ void SWIGV8_INIT (v8::Handle exports, v8::Handle /*modul { SWIG_InitializeModule(static_cast(&exports)); -#if (SWIG_V8_VERSION < 0x032117) - v8::HandleScope scope; -#else - v8::HandleScope scope(v8::Isolate::GetCurrent()); -#endif + SWIGV8_HANDLESCOPE(); v8::Handle exports_obj = exports; %} diff --git a/Lib/javascript/v8/javascriptprimtypes.swg b/Lib/javascript/v8/javascriptprimtypes.swg index 706a799b7..2bb03a35f 100644 --- a/Lib/javascript/v8/javascriptprimtypes.swg +++ b/Lib/javascript/v8/javascriptprimtypes.swg @@ -33,7 +33,7 @@ int SWIG_AsVal_dec(bool)(v8::Handle obj, bool *val) SWIGINTERNINLINE v8::Handle SWIG_From_dec(int)(int value) { - return v8::Int32::New(value); + return SWIGV8_INT32_NEW(value); } } @@ -56,7 +56,7 @@ int SWIG_AsVal_dec(int)(v8::Handle valRef, int* val) SWIGINTERNINLINE v8::Handle SWIG_From_dec(long)(long value) { - return v8::Number::New(value); + return SWIGV8_NUMBER_NEW(value); } } @@ -82,7 +82,7 @@ SWIGINTERNINLINE v8::Handle SWIG_From_dec(unsigned long)(unsigned long value) { return (value > LONG_MAX) ? - v8::Integer::NewFromUnsigned(value) : v8::Integer::New(%numeric_cast(value,long)); + SWIGV8_INTEGER_NEW_UNS(value) : SWIGV8_INTEGER_NEW(%numeric_cast(value,long)); } } @@ -116,7 +116,7 @@ int SWIG_AsVal_dec(unsigned long)(v8::Handle obj, unsigned long *val) SWIGINTERNINLINE v8::Handle SWIG_From_dec(long long)(long long value) { - return v8::Number::New(value); + return SWIGV8_NUMBER_NEW(value); } } @@ -146,7 +146,7 @@ SWIGINTERNINLINE v8::Handle SWIG_From_dec(unsigned long long)(unsigned long long value) { return (value > LONG_MAX) ? - v8::Integer::NewFromUnsigned(value) : v8::Integer::New(%numeric_cast(value,long)); + SWIGV8_INTEGER_NEW_UNS(value) : SWIGV8_INTEGER_NEW(%numeric_cast(value,long)); } } @@ -179,7 +179,7 @@ int SWIG_AsVal_dec(unsigned long long)(v8::Handle obj, unsigned long SWIGINTERN v8::Handle SWIG_From_dec(double) (double val) { - return v8::Number::New(val); + return SWIGV8_NUMBER_NEW(val); } } diff --git a/Lib/javascript/v8/javascriptrun.swg b/Lib/javascript/v8/javascriptrun.swg index 311902378..bdedb25ac 100644 --- a/Lib/javascript/v8/javascriptrun.swg +++ b/Lib/javascript/v8/javascriptrun.swg @@ -9,7 +9,7 @@ #define SWIGV8_OVERLOAD false void SWIG_V8_Raise(const char* msg) { - v8::ThrowException(v8::Exception::Error(v8::String::New(msg))); + v8::ThrowException(v8::Exception::Error(SWIGV8_STRING_NEW(msg))); } /* @@ -39,7 +39,7 @@ V8ErrorHandler SWIGV8_ErrorHandler; class OverloadErrorHandler: public V8ErrorHandler { public: virtual void error(int code, const char* msg) { - err = v8::Exception::Error(v8::String::New(msg)); + err = v8::Exception::Error(SWIGV8_STRING_NEW(msg)); if(code != SWIG_TypeError) { v8::ThrowException(err); } @@ -63,6 +63,55 @@ typedef v8::PropertyCallbackInfo SwigV8PropertyCallbackInfo; #define SWIGV8_RETURN_INFO(val, info) info.GetReturnValue().Set(val); return #endif +#if (SWIG_V8_VERSION < 0x032117) +#define SWIGV8_HANDLESCOPE() v8::HandleScope scope +#define SWIGV8_HANDLESCOPE_ESC() v8::HandleScope scope +#define SWIGV8_ESCAPE(val) return scope.Close(val) +#elif (SWIG_V8_VERSION < 0x032530) +#define SWIGV8_HANDLESCOPE() v8::HandleScope scope(v8::Isolate::GetCurrent()); +#define SWIGV8_HANDLESCOPE_ESC() v8::HandleScope scope(v8::Isolate::GetCurrent()); +#define SWIGV8_ESCAPE(val) return scope.Close(val) +#else +#define SWIGV8_HANDLESCOPE() v8::HandleScope scope(v8::Isolate::GetCurrent()); +#define SWIGV8_HANDLESCOPE_ESC() v8::EscapableHandleScope scope(v8::Isolate::GetCurrent()); +#define SWIGV8_ESCAPE(val) return scope.Escape(val) +#endif + +#if (SWIG_V8_VERSION < 0x032530) +#define SWIGV8_CURRENT_CONTEXT() v8::Context::GetCurrent() +#define SWIGV8_STRING_NEW(str) v8::String::New(str) +#define SWIGV8_STRING_NEW2(cstr, len) v8::String::New(cstr, kNormalString, len) +#define SWIGV8_FUNCTEMPLATE_NEW(func) v8::FunctionTemplate::New(func) +#define SWIGV8_FUNCTEMPLATE_NEW_VOID() v8::FunctionTemplate::New() +#define SWIGV8_OBJECT_NEW() v8::Object::New() +#define SWIGV8_EXTERNAL_NEW(val) v8::External::New(val) +#define SWIGV8_UNDEFINED() v8::Undefined() +#define SWIGV8_NULL() v8::Null() +#define SWIGV8_BOOLEAN_NEW(bool) v8::Boolean::New(bool) +#define SWIGV8_ARRAY_NEW() v8::Array::New() +#define SWIGV8_NUMBER_NEW(num) v8::Number::New(num) +#define SWIGV8_SYMBOL_NEW(sym) v8::String::NewSymbol(sym) +#define SWIGV8_INTEGER_NEW(num) v8::Integer::New(num) +#define SWIGV8_INTEGER_NEW_UNS(num) v8::Integer::NewFromUnsigned(num) +#define SWIGV8_INT32_NEW(num) v8::Int32::New(num) +#else +#define SWIGV8_CURRENT_CONTEXT() v8::Isolate::GetCurrent()->GetCurrentContext() +#define SWIGV8_STRING_NEW(str) v8::String::NewFromUtf8(v8::Isolate::GetCurrent(), str) +#define SWIGV8_STRING_NEW2(cstr, len) v8::String::NewFromUtf8(v8::Isolate::GetCurrent(), cstr, v8::String::kNormalString, len) +#define SWIGV8_FUNCTEMPLATE_NEW(func) v8::FunctionTemplate::New(v8::Isolate::GetCurrent(), func) +#define SWIGV8_FUNCTEMPLATE_NEW_VOID() v8::FunctionTemplate::New(v8::Isolate::GetCurrent()) +#define SWIGV8_OBJECT_NEW() v8::Object::New(v8::Isolate::GetCurrent()) +#define SWIGV8_EXTERNAL_NEW(val) v8::External::New(v8::Isolate::GetCurrent(), val) +#define SWIGV8_UNDEFINED() v8::Undefined(v8::Isolate::GetCurrent()) +#define SWIGV8_NULL() v8::Null(v8::Isolate::GetCurrent()) +#define SWIGV8_BOOLEAN_NEW(bool) v8::Boolean::New(v8::Isolate::GetCurrent(), bool) +#define SWIGV8_ARRAY_NEW() v8::Array::New(v8::Isolate::GetCurrent()) +#define SWIGV8_NUMBER_NEW(num) v8::Number::New(v8::Isolate::GetCurrent(), num) +#define SWIGV8_SYMBOL_NEW(sym) v8::String::NewFromUtf8(v8::Isolate::GetCurrent(), sym) +#define SWIGV8_INTEGER_NEW(num) v8::Integer::New(v8::Isolate::GetCurrent(), num) +#define SWIGV8_INTEGER_NEW_UNS(num) v8::Integer::NewFromUnsigned(v8::Isolate::GetCurrent(), num) +#define SWIGV8_INT32_NEW(num) v8::Int32::New(v8::Isolate::GetCurrent(), num) +#endif /* --------------------------------------------------------------------------- * Basic Proxy object @@ -117,11 +166,7 @@ public: v8::Persistent SWIGV8_SWIGTYPE_Proxy_class_templ; int SWIG_V8_ConvertInstancePtr(v8::Handle objRef, void** ptr, swig_type_info *info, int flags) { -#if (SWIG_V8_VERSION < 0x032117) - v8::HandleScope scope; -#else - v8::HandleScope scope(v8::Isolate::GetCurrent()); -#endif + SWIGV8_HANDLESCOPE(); if(objRef->InternalFieldCount() < 1) return SWIG_ERROR; @@ -243,11 +288,7 @@ void SWIGV8_SetPrivateData(v8::Handle obj, void* ptr, swig_type_info } int SWIG_V8_ConvertPtr(v8::Handle valRef, void** ptr, swig_type_info *info, int flags) { -#if (SWIG_V8_VERSION < 0x032117) - v8::HandleScope scope; -#else - v8::HandleScope scope(v8::Isolate::GetCurrent()); -#endif + SWIGV8_HANDLESCOPE(); /* special case: JavaScript null => C NULL pointer */ if(valRef->IsNull()) { @@ -262,16 +303,12 @@ int SWIG_V8_ConvertPtr(v8::Handle valRef, void** ptr, swig_type_info } v8::Handle SWIG_V8_NewPointerObj(void *ptr, swig_type_info *info, int flags) { -#if (SWIG_V8_VERSION < 0x032117) - v8::HandleScope scope; -#else - v8::HandleScope scope(v8::Isolate::GetCurrent()); -#endif + SWIGV8_HANDLESCOPE_ESC(); v8::Handle class_templ; if (ptr == NULL) { - return scope.Close(v8::Null()); + SWIGV8_ESCAPE(SWIGV8_NULL); } #if (SWIG_V8_VERSION < 0x031903) @@ -293,7 +330,7 @@ v8::Handle SWIG_V8_NewPointerObj(void *ptr, swig_type_info *info, int v8::Handle result = class_templ->InstanceTemplate()->NewInstance(); SWIGV8_SetPrivateData(result, ptr, info, flags); - return scope.Close(result); + SWIGV8_ESCAPE(result); } #define SWIG_ConvertPtr(obj, ptr, info, flags) SWIG_V8_ConvertPtr(obj, ptr, info, flags) @@ -308,12 +345,7 @@ v8::Handle SWIG_V8_NewPointerObj(void *ptr, swig_type_info *info, int #define SWIG_GetInstancePtr(obj, ptr) SWIG_V8_GetInstancePtr(obj, ptr) SwigV8ReturnValue _SWIGV8_wrap_equals(const SwigV8Arguments &args) { - -#if (SWIG_V8_VERSION < 0x032117) - v8::HandleScope scope; -#else - v8::HandleScope scope(v8::Isolate::GetCurrent()); -#endif + SWIGV8_HANDLESCOPE(); v8::Handle jsresult; void *arg1 = (void *) 0 ; @@ -334,21 +366,16 @@ SwigV8ReturnValue _SWIGV8_wrap_equals(const SwigV8Arguments &args) { } result = (bool)(arg1 == arg2); - jsresult = v8::Boolean::New(result); + jsresult = SWIGV8_BOOLEAN_NEW(result); SWIGV8_RETURN(jsresult); goto fail; fail: - SWIGV8_RETURN(v8::Undefined()); + SWIGV8_RETURN(SWIGV8_UNDEFINED()); } SwigV8ReturnValue _wrap_getCPtr(const SwigV8Arguments &args) { - -#if (SWIG_V8_VERSION < 0x032117) - v8::HandleScope scope; -#else - v8::HandleScope scope(v8::Isolate::GetCurrent()); -#endif + SWIGV8_HANDLESCOPE(); v8::Handle jsresult; void *arg1 = (void *) 0 ; @@ -361,12 +388,12 @@ SwigV8ReturnValue _wrap_getCPtr(const SwigV8Arguments &args) { } result = (long)arg1; - jsresult = v8::Number::New(result); + jsresult = SWIGV8_NUMBER_NEW(result); SWIGV8_RETURN(jsresult); goto fail; fail: - SWIGV8_RETURN(v8::Undefined()); + SWIGV8_RETURN(SWIGV8_UNDEFINED()); } /* --------------------------------------------------------------------------- @@ -390,28 +417,18 @@ public: SWIGRUNTIMEINLINE int SwigV8Packed_Check(v8::Handle valRef) { - -#if (SWIG_V8_VERSION < 0x032117) - v8::HandleScope scope; -#else - v8::HandleScope scope(v8::Isolate::GetCurrent()); -#endif + SWIGV8_HANDLESCOPE(); v8::Handle objRef = valRef->ToObject(); if(objRef->InternalFieldCount() < 1) return false; - v8::Handle flag = objRef->GetHiddenValue(v8::String::New("__swig__packed_data__")); + v8::Handle flag = objRef->GetHiddenValue(SWIGV8_STRING_NEW("__swig__packed_data__")); return (flag->IsBoolean() && flag->BooleanValue()); } SWIGRUNTIME swig_type_info* SwigV8Packed_UnpackData(v8::Handle valRef, void *ptr, size_t size) { if (SwigV8Packed_Check(valRef)) { - -#if (SWIG_V8_VERSION < 0x032117) - v8::HandleScope scope; -#else - v8::HandleScope scope(v8::Isolate::GetCurrent()); -#endif + SWIGV8_HANDLESCOPE(); SwigV8PackedData *sobj; @@ -475,16 +492,12 @@ void _wrap_SwigV8PackedData_delete(v8::Isolate *isolate, v8::Persistent< v8::Obj SWIGRUNTIME v8::Handle SWIGV8_NewPackedObj(void *data, size_t size, swig_type_info *type) { -#if (SWIG_V8_VERSION < 0x032117) - v8::HandleScope scope; -#else - v8::HandleScope scope(v8::Isolate::GetCurrent()); -#endif + SWIGV8_HANDLESCOPE_ESC(); SwigV8PackedData* cdata = new SwigV8PackedData(data, size, type); - v8::Handle obj = v8::Object::New(); + v8::Handle obj = SWIGV8_OBJECT_NEW(); - obj->SetHiddenValue(v8::String::New("__swig__packed_data__"), v8::Boolean::New(true)); + obj->SetHiddenValue(SWIGV8_STRING_NEW("__swig__packed_data__"), SWIGV8_BOOLEAN_NEW(true)); #if (SWIG_V8_VERSION < 0x031511) obj->SetPointerInInternalField(0, cdata); @@ -505,8 +518,10 @@ v8::Handle SWIGV8_NewPackedObj(void *data, size_t size, swig_type_inf cdata->handle.MakeWeak(cdata, _wrap_SwigV8PackedData_delete); #elif (SWIG_V8_VERSION < 0x031918) cdata->handle.MakeWeak(v8::Isolate::GetCurrent(), cdata, _wrap_SwigV8PackedData_delete); -#else +#elif (SWIG_V8_VERSION < 0x032530) cdata->handle.MakeWeak(cdata, _wrap_SwigV8PackedData_delete); +#else + v8::V8::MakeWeak(&cdata->handle, cdata, _wrap_SwigV8PackedData_delete); #endif #if (SWIG_V8_VERSION < 0x031710) @@ -517,7 +532,7 @@ v8::Handle SWIGV8_NewPackedObj(void *data, size_t size, swig_type_inf cdata->handle.MarkIndependent(); #endif - return scope.Close(obj); + SWIGV8_ESCAPE(obj); } #define SWIG_ConvertMember(obj, ptr, sz, ty) SWIGV8_ConvertPacked(obj, ptr, sz, ty) @@ -531,17 +546,13 @@ v8::Handle SWIGV8_NewPackedObj(void *data, size_t size, swig_type_inf SWIGRUNTIME v8::Handle SWIGV8_AppendOutput(v8::Handle result, v8::Handle obj) { -#if (SWIG_V8_VERSION < 0x032117) - v8::HandleScope scope; -#else - v8::HandleScope scope(v8::Isolate::GetCurrent()); -#endif + SWIGV8_HANDLESCOPE_ESC(); if (result->IsUndefined()) { - result = v8::Array::New(); + result = SWIGV8_ARRAY_NEW(); } v8::Handle arr = v8::Handle::Cast(result); arr->Set(arr->Length(), obj); - return scope.Close(arr); + SWIGV8_ESCAPE(arr); } diff --git a/Lib/javascript/v8/javascriptstrings.swg b/Lib/javascript/v8/javascriptstrings.swg index 69b6836a8..65ba20e5a 100644 --- a/Lib/javascript/v8/javascriptstrings.swg +++ b/Lib/javascript/v8/javascriptstrings.swg @@ -47,13 +47,13 @@ SWIG_FromCharPtrAndSize(const char* carray, size_t size) if (carray) { if (size > INT_MAX) { // TODO: handle extra long strings - return v8::Undefined(); + return SWIGV8_UNDEFINED(); } else { - v8::Handle js_str = v8::String::New(carray, size); + v8::Handle js_str = SWIGV8_STRING_NEW2(carray, size); return js_str; } } else { - return v8::Undefined(); + return SWIGV8_UNDEFINED(); } } } diff --git a/Lib/javascript/v8/javascripttypemaps.swg b/Lib/javascript/v8/javascripttypemaps.swg index 90317a1c7..4601698e0 100644 --- a/Lib/javascript/v8/javascripttypemaps.swg +++ b/Lib/javascript/v8/javascripttypemaps.swg @@ -26,7 +26,7 @@ /* Javascript types */ #define SWIG_Object v8::Handle -#define VOID_Object v8::Undefined() +#define VOID_Object SWIGV8_UNDEFINED() /* Overload of the output/constant/exception/dirout handling */ -- cgit v1.2.1 From 3c9e16ef8512b5713be05b5efc5f2ad095254c21 Mon Sep 17 00:00:00 2001 From: Richard Date: Fri, 22 Aug 2014 07:56:58 -0500 Subject: Fixed some bugs from previous commit --- Lib/javascript/v8/javascriptrun.swg | 102 +++++++++++++++++++----------------- 1 file changed, 53 insertions(+), 49 deletions(-) diff --git a/Lib/javascript/v8/javascriptrun.swg b/Lib/javascript/v8/javascriptrun.swg index bdedb25ac..0f6469f29 100644 --- a/Lib/javascript/v8/javascriptrun.swg +++ b/Lib/javascript/v8/javascriptrun.swg @@ -1,54 +1,8 @@ /* --------------------------------------------------------------------------- - * Error handling + * These typedefs and defines are used to deal with v8 API changes * * ---------------------------------------------------------------------------*/ -#define SWIG_Error(code, msg) SWIGV8_ErrorHandler.error(code, msg) -#define SWIG_exception(code, msg) SWIGV8_ErrorHandler.error(code, msg) -#define SWIG_fail goto fail -#define SWIGV8_OVERLOAD false - -void SWIG_V8_Raise(const char* msg) { - v8::ThrowException(v8::Exception::Error(SWIGV8_STRING_NEW(msg))); -} - -/* - Note: There are two contexts for handling errors. - A static V8ErrorHandler is used in not overloaded methods. - For overloaded methods the throwing type checking mechanism is used - during dispatching. As V8 exceptions can not be resetted properly - the trick is to use a dynamic ErrorHandler with same local name as the global - one. - - - See defintion of SWIG_Error above. - - See code templates 'JS_function_dispatcher', 'JS_functionwrapper_overload', - and 'JS_function_dispatch_case' in javascriptcode.swg - -*/ -class V8ErrorHandler { -public: - virtual ~V8ErrorHandler() {} - virtual void error(int code, const char* msg) { - SWIG_V8_Raise(msg); - } -}; -// this is used in usually -V8ErrorHandler SWIGV8_ErrorHandler; - -// instances of this are used in overloaded functions -class OverloadErrorHandler: public V8ErrorHandler { -public: - virtual void error(int code, const char* msg) { - err = v8::Exception::Error(SWIGV8_STRING_NEW(msg)); - if(code != SWIG_TypeError) { - v8::ThrowException(err); - } - } - v8::Handle err; -}; - -// Note: these typedefs and defines are used to deal with v8 API changes since version 3.19.00 - #if (SWIG_V8_VERSION < 0x031903) typedef v8::Handle SwigV8ReturnValue; typedef v8::Arguments SwigV8Arguments; @@ -80,7 +34,7 @@ typedef v8::PropertyCallbackInfo SwigV8PropertyCallbackInfo; #if (SWIG_V8_VERSION < 0x032530) #define SWIGV8_CURRENT_CONTEXT() v8::Context::GetCurrent() #define SWIGV8_STRING_NEW(str) v8::String::New(str) -#define SWIGV8_STRING_NEW2(cstr, len) v8::String::New(cstr, kNormalString, len) +#define SWIGV8_STRING_NEW2(cstr, len) v8::String::NewFromUtf8(v8::Isolate::GetCurrent(), cstr, v8::String::kNormalString, len) #define SWIGV8_FUNCTEMPLATE_NEW(func) v8::FunctionTemplate::New(func) #define SWIGV8_FUNCTEMPLATE_NEW_VOID() v8::FunctionTemplate::New() #define SWIGV8_OBJECT_NEW() v8::Object::New() @@ -113,6 +67,56 @@ typedef v8::PropertyCallbackInfo SwigV8PropertyCallbackInfo; #define SWIGV8_INT32_NEW(num) v8::Int32::New(v8::Isolate::GetCurrent(), num) #endif + +/* --------------------------------------------------------------------------- + * Error handling + * + * ---------------------------------------------------------------------------*/ + +#define SWIG_Error(code, msg) SWIGV8_ErrorHandler.error(code, msg) +#define SWIG_exception(code, msg) SWIGV8_ErrorHandler.error(code, msg) +#define SWIG_fail goto fail +#define SWIGV8_OVERLOAD false + +void SWIG_V8_Raise(const char* msg) { + v8::ThrowException(v8::Exception::Error(SWIGV8_STRING_NEW(msg))); +} + +/* + Note: There are two contexts for handling errors. + A static V8ErrorHandler is used in not overloaded methods. + For overloaded methods the throwing type checking mechanism is used + during dispatching. As V8 exceptions can not be resetted properly + the trick is to use a dynamic ErrorHandler with same local name as the global + one. + + - See defintion of SWIG_Error above. + - See code templates 'JS_function_dispatcher', 'JS_functionwrapper_overload', + and 'JS_function_dispatch_case' in javascriptcode.swg + +*/ +class V8ErrorHandler { +public: + virtual ~V8ErrorHandler() {} + virtual void error(int code, const char* msg) { + SWIG_V8_Raise(msg); + } +}; +// this is used in usually +V8ErrorHandler SWIGV8_ErrorHandler; + +// instances of this are used in overloaded functions +class OverloadErrorHandler: public V8ErrorHandler { +public: + virtual void error(int code, const char* msg) { + err = v8::Exception::Error(SWIGV8_STRING_NEW(msg)); + if(code != SWIG_TypeError) { + v8::ThrowException(err); + } + } + v8::Handle err; +}; + /* --------------------------------------------------------------------------- * Basic Proxy object * @@ -308,7 +312,7 @@ v8::Handle SWIG_V8_NewPointerObj(void *ptr, swig_type_info *info, int v8::Handle class_templ; if (ptr == NULL) { - SWIGV8_ESCAPE(SWIGV8_NULL); + SWIGV8_ESCAPE(SWIGV8_NULL()); } #if (SWIG_V8_VERSION < 0x031903) -- cgit v1.2.1 From c1222ebeec3177979be34f1a844ed82294a66953 Mon Sep 17 00:00:00 2001 From: Richard Date: Fri, 22 Aug 2014 08:33:56 -0500 Subject: Partial fixes for 3.24.40 (0x032440) - incomplete --- Lib/javascript/v8/javascriptrun.swg | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/Lib/javascript/v8/javascriptrun.swg b/Lib/javascript/v8/javascriptrun.swg index 0f6469f29..acff01fe6 100644 --- a/Lib/javascript/v8/javascriptrun.swg +++ b/Lib/javascript/v8/javascriptrun.swg @@ -21,7 +21,7 @@ typedef v8::PropertyCallbackInfo SwigV8PropertyCallbackInfo; #define SWIGV8_HANDLESCOPE() v8::HandleScope scope #define SWIGV8_HANDLESCOPE_ESC() v8::HandleScope scope #define SWIGV8_ESCAPE(val) return scope.Close(val) -#elif (SWIG_V8_VERSION < 0x032530) +#elif (SWIG_V8_VERSION < 0x032440) #define SWIGV8_HANDLESCOPE() v8::HandleScope scope(v8::Isolate::GetCurrent()); #define SWIGV8_HANDLESCOPE_ESC() v8::HandleScope scope(v8::Isolate::GetCurrent()); #define SWIGV8_ESCAPE(val) return scope.Close(val) @@ -31,7 +31,7 @@ typedef v8::PropertyCallbackInfo SwigV8PropertyCallbackInfo; #define SWIGV8_ESCAPE(val) return scope.Escape(val) #endif -#if (SWIG_V8_VERSION < 0x032530) +#if (SWIG_V8_VERSION < 0x032440) #define SWIGV8_CURRENT_CONTEXT() v8::Context::GetCurrent() #define SWIGV8_STRING_NEW(str) v8::String::New(str) #define SWIGV8_STRING_NEW2(cstr, len) v8::String::NewFromUtf8(v8::Isolate::GetCurrent(), cstr, v8::String::kNormalString, len) -- cgit v1.2.1 From 1a0605bf45f02923c998dce1255ddc82979bdbf5 Mon Sep 17 00:00:00 2001 From: Richard Date: Fri, 22 Aug 2014 08:35:36 -0500 Subject: Partial fixes for 3.24.40 (0x032440) - incomplete --- Tools/javascript/v8_shell.cxx | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/Tools/javascript/v8_shell.cxx b/Tools/javascript/v8_shell.cxx index b035eb2c0..00d81a034 100644 --- a/Tools/javascript/v8_shell.cxx +++ b/Tools/javascript/v8_shell.cxx @@ -32,7 +32,7 @@ typedef v8::PropertyCallbackInfo SwigV8PropertyCallbackInfo; #define SWIGV8_HANDLESCOPE() v8::HandleScope scope #define SWIGV8_HANDLESCOPE_ESC() v8::HandleScope scope #define SWIGV8_ESCAPE(val) return scope.Close(val) -#elif (SWIG_V8_VERSION < 0x032530) +#elif (SWIG_V8_VERSION < 0x032440) #define SWIGV8_HANDLESCOPE() v8::HandleScope scope(v8::Isolate::GetCurrent()); #define SWIGV8_HANDLESCOPE_ESC() v8::HandleScope scope(v8::Isolate::GetCurrent()); #define SWIGV8_ESCAPE(val) return scope.Close(val) @@ -42,7 +42,7 @@ typedef v8::PropertyCallbackInfo SwigV8PropertyCallbackInfo; #define SWIGV8_ESCAPE(val) return scope.Escape(val) #endif -#if (SWIG_V8_VERSION < 0x032530) +#if (SWIG_V8_VERSION < 0x032440) #define SWIGV8_CURRENT_CONTEXT() v8::Context::GetCurrent() #define SWIGV8_STRING_NEW(str) v8::String::New(str) #define SWIGV8_FUNCTEMPLATE_NEW(func) v8::FunctionTemplate::New(func) -- cgit v1.2.1 From c23375d39d0d02bf414f5c886f8454b8bf05e767 Mon Sep 17 00:00:00 2001 From: Richard Date: Fri, 22 Aug 2014 18:49:48 -0500 Subject: Show V8 Deprecated warnings --- Examples/javascript/example.mk | 2 +- Tools/javascript/Makefile.in | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/Examples/javascript/example.mk b/Examples/javascript/example.mk index cb8a33efd..9afd5b9bf 100644 --- a/Examples/javascript/example.mk +++ b/Examples/javascript/example.mk @@ -18,7 +18,7 @@ SWIG_TOP=../../.. SWIG = $(SWIG_TOP)/preinst-swig TARGET = example INTERFACE = example.i -SWIGOPT=-$(JSENGINE) -DV8_VERSION=$(JSV8_VERSION) +SWIGOPT=-$(JSENGINE) -DV8_VERSION=$(JSV8_VERSION) -DV8_DEPRECATION_WARNINGS check: build $(MAKE) -f $(EXAMPLES_TOP)/Makefile SRCDIR='$(SRCDIR)' JSENGINE='$(JSENGINE)' TARGET='$(TARGET)' javascript_run diff --git a/Tools/javascript/Makefile.in b/Tools/javascript/Makefile.in index 8e8a9b4f4..37ff8830e 100644 --- a/Tools/javascript/Makefile.in +++ b/Tools/javascript/Makefile.in @@ -49,7 +49,7 @@ Makefile: $(srcdir)/Makefile.in ../../config.status # These settings are provided by 'configure' (see '/configure.in') ifeq (1, $(JSV8ENABLED)) JS_INTERPRETER_SRC_V8 = v8_shell.cxx -JS_INTERPRETER_ENABLE_V8 = -DENABLE_V8 -DSWIG_V8_VERSION=$(JSV8_VERSION) +JS_INTERPRETER_ENABLE_V8 = -DENABLE_V8 -DSWIG_V8_VERSION=$(JSV8_VERSION) -DV8_DEPRECATION_WARNINGS endif ifeq (1, $(JSCENABLED)) -- cgit v1.2.1 From d4920591d4bd01df809fbe1d90a3f70f77b1c707 Mon Sep 17 00:00:00 2001 From: Richard Date: Fri, 22 Aug 2014 18:54:12 -0500 Subject: Fixes for v8 3.24.3 (0x032403) --- Lib/javascript/v8/javascriptcode.swg | 32 +++++++----- Lib/javascript/v8/javascriptrun.swg | 95 ++++++++++++++++++++++++++---------- Tools/javascript/v8_shell.cxx | 10 ++-- 3 files changed, 92 insertions(+), 45 deletions(-) diff --git a/Lib/javascript/v8/javascriptcode.swg b/Lib/javascript/v8/javascriptcode.swg index e82720e1c..b5742cfd5 100644 --- a/Lib/javascript/v8/javascriptcode.swg +++ b/Lib/javascript/v8/javascriptcode.swg @@ -125,16 +125,17 @@ fail: %{ #if (SWIG_V8_VERSION < 0x031710) -void $jswrapper(v8::Persistent< v8::Value > object, void *parameter) -{ +void $jswrapper(v8::Persistent< v8::Value > object, void *parameter) { SWIGV8_Proxy *proxy = static_cast(parameter); #elif (SWIG_V8_VERSION < 0x031900) -void $jswrapper(v8::Isolate *isolate, v8::Persistent< v8::Value > object, void *parameter) -{ +void $jswrapper(v8::Isolate *isolate, v8::Persistent< v8::Value > object, void *parameter) { SWIGV8_Proxy *proxy = static_cast(parameter); +#elif (SWIG_V8_VERSION < 0x032403) +void $jswrapper(v8::Isolate *isolate, v8::Persistent< v8::Object > * object, SWIGV8_Proxy *proxy) { #else -void $jswrapper(v8::Isolate *isolate, v8::Persistent< v8::Object > * object, SWIGV8_Proxy *proxy) -{ +void $jswrapper(const v8::WeakCallbackData &data) { + v8::Local object = data.GetValue(); + SWIGV8_Proxy *proxy = data.GetParameter(); #endif if(proxy->swigCMemOwn && proxy->swigCObject) { @@ -146,6 +147,7 @@ void $jswrapper(v8::Isolate *isolate, v8::Persistent< v8::Object > * object, SWI delete proxy; object.Clear(); + #if (SWIG_V8_VERSION < 0x031710) object.Dispose(); #elif (SWIG_V8_VERSION < 0x031900) @@ -167,17 +169,19 @@ void $jswrapper(v8::Isolate *isolate, v8::Persistent< v8::Object > * object, SWI %fragment ("js_dtoroverride", "templates") %{ #if (SWIG_V8_VERSION < 0x031710) -void $jswrapper(v8::Persistent< v8::Value > object, void *parameter) -{ +void $jswrapper(v8::Persistent< v8::Value > object, void *parameter) { SWIGV8_Proxy *proxy = static_cast(parameter); #elif (SWIG_V8_VERSION < 0x031900) -void $jswrapper(v8::Isolate *isolate, v8::Persistent< v8::Value > object, void *parameter) -{ +void $jswrapper(v8::Isolate *isolate, v8::Persistent< v8::Value > object, void *parameter) { SWIGV8_Proxy *proxy = static_cast(parameter); +#elif (SWIG_V8_VERSION < 0x032403) +void $jswrapper(v8::Isolate *isolate, v8::Persistent< v8::Object > * object, SWIGV8_Proxy *proxy) { #else -void $jswrapper(v8::Isolate *isolate, v8::Persistent< v8::Object > * object, SWIGV8_Proxy *proxy) -{ +void $jswrapper(const v8::WeakCallbackData &data) { + v8::Local object = data.GetValue(); + SWIGV8_Proxy *proxy = data.GetParameter(); #endif + if(proxy->swigCMemOwn && proxy->swigCObject) { $jstype arg1 = ($jstype)proxy->swigCObject; ${destructor_action} @@ -190,8 +194,10 @@ void $jswrapper(v8::Isolate *isolate, v8::Persistent< v8::Object > * object, SWI object.Dispose(isolate); #elif (SWIG_V8_VERSION < 0x032100) object->Dispose(isolate); -#else +#elif (SWIG_V8_VERSION < 0x032403) object->Dispose(); +#else + object.Clear(); #endif } %} diff --git a/Lib/javascript/v8/javascriptrun.swg b/Lib/javascript/v8/javascriptrun.swg index acff01fe6..9c84059b4 100644 --- a/Lib/javascript/v8/javascriptrun.swg +++ b/Lib/javascript/v8/javascriptrun.swg @@ -21,7 +21,7 @@ typedef v8::PropertyCallbackInfo SwigV8PropertyCallbackInfo; #define SWIGV8_HANDLESCOPE() v8::HandleScope scope #define SWIGV8_HANDLESCOPE_ESC() v8::HandleScope scope #define SWIGV8_ESCAPE(val) return scope.Close(val) -#elif (SWIG_V8_VERSION < 0x032440) +#elif (SWIG_V8_VERSION < 0x032319) #define SWIGV8_HANDLESCOPE() v8::HandleScope scope(v8::Isolate::GetCurrent()); #define SWIGV8_HANDLESCOPE_ESC() v8::HandleScope scope(v8::Isolate::GetCurrent()); #define SWIGV8_ESCAPE(val) return scope.Close(val) @@ -31,7 +31,7 @@ typedef v8::PropertyCallbackInfo SwigV8PropertyCallbackInfo; #define SWIGV8_ESCAPE(val) return scope.Escape(val) #endif -#if (SWIG_V8_VERSION < 0x032440) +#if (SWIG_V8_VERSION < 0x032319) #define SWIGV8_CURRENT_CONTEXT() v8::Context::GetCurrent() #define SWIGV8_STRING_NEW(str) v8::String::New(str) #define SWIGV8_STRING_NEW2(cstr, len) v8::String::NewFromUtf8(v8::Isolate::GetCurrent(), cstr, v8::String::kNormalString, len) @@ -79,7 +79,11 @@ typedef v8::PropertyCallbackInfo SwigV8PropertyCallbackInfo; #define SWIGV8_OVERLOAD false void SWIG_V8_Raise(const char* msg) { +#if (SWIG_V8_VERSION < 0x032403) v8::ThrowException(v8::Exception::Error(SWIGV8_STRING_NEW(msg))); +#else + v8::Isolate::GetCurrent()->ThrowException(v8::Exception::Error(SWIGV8_STRING_NEW(msg))); +#endif } /* @@ -111,7 +115,11 @@ public: virtual void error(int code, const char* msg) { err = v8::Exception::Error(SWIGV8_STRING_NEW(msg)); if(code != SWIG_TypeError) { +#if (SWIG_V8_VERSION < 0x032403) v8::ThrowException(err); +#else + v8::Isolate::GetCurrent()->ThrowException(err); +#endif } } v8::Handle err; @@ -129,7 +137,11 @@ public: class SWIGV8_Proxy { public: SWIGV8_Proxy(): swigCMemOwn(false), swigCObject(0), info(0) { +#if (SWIG_V8_VERSION < 0x032403) v8::V8::AdjustAmountOfExternalAllocatedMemory(SWIGV8_AVG_OBJ_SIZE); +#else + v8::Isolate::GetCurrent()->AdjustAmountOfExternalAllocatedMemory(SWIGV8_AVG_OBJ_SIZE); +#endif }; ~SWIGV8_Proxy() { @@ -139,13 +151,24 @@ public: #elif (SWIG_V8_VERSION < 0x032100) handle.ClearWeak(v8::Isolate::GetCurrent()); handle.Dispose(v8::Isolate::GetCurrent()); -#else +#elif (SWIG_V8_VERSION < 0x032403) handle.ClearWeak(); handle.Dispose(); +#else + handle.ClearWeak(); + handle.Reset(); #endif +#if (SWIG_V8_VERSION < 0x032403) handle.Clear(); +#endif + +#if (SWIG_V8_VERSION < 0x032403) v8::V8::AdjustAmountOfExternalAllocatedMemory(-SWIGV8_AVG_OBJ_SIZE); +#else + v8::Isolate::GetCurrent()->AdjustAmountOfExternalAllocatedMemory(-SWIGV8_AVG_OBJ_SIZE); +#endif + } bool swigCMemOwn; @@ -162,8 +185,10 @@ public: void (*dtor) (v8::Persistent< v8::Value> object, void *parameter); #elif (SWIG_V8_VERSION < 0x031900) void (*dtor) (v8::Isolate *isolate, v8::Persistent< v8::Value> object, void *parameter); -#else +#elif (SWIG_V8_VERSION < 0x032403) void (*dtor) (v8::Isolate *isolate, v8::Persistent< v8::Object > *object, SWIGV8_Proxy *proxy); +#else + void (*dtor) (const v8::WeakCallbackData &data); #endif }; @@ -201,16 +226,18 @@ int SWIG_V8_ConvertInstancePtr(v8::Handle objRef, void** ptr, swig_t return SWIG_OK; } + #if (SWIG_V8_VERSION < 0x031710) -void SWIGV8_Proxy_DefaultDtor(v8::Persistent< v8::Value > object, void *parameter) +void SWIGV8_Proxy_DefaultDtor(v8::Persistent< v8::Value > object, void *parameter) { + SWIGV8_Proxy *proxy = static_cast(parameter); #elif (SWIG_V8_VERSION < 0x031900) -void SWIGV8_Proxy_DefaultDtor(v8::Isolate *, v8::Persistent< v8::Value > object, void *parameter) -#else -void SWIGV8_Proxy_DefaultDtor(v8::Isolate *, v8::Persistent< v8::Object > *object, SWIGV8_Proxy *proxy) -#endif -{ -#if (SWIG_V8_VERSION < 0x031900) +void SWIGV8_Proxy_DefaultDtor(v8::Isolate *, v8::Persistent< v8::Value > object, void *parameter) { SWIGV8_Proxy *proxy = static_cast(parameter); +#elif (SWIG_V8_VERSION < 0x032403) +void SWIGV8_Proxy_DefaultDtor(v8::Isolate *, v8::Persistent< v8::Object > *object, SWIGV8_Proxy *proxy) { +#else +void SWIGV8_Proxy_DefaultDtor(const v8::WeakCallbackData &data) { + SWIGV8_Proxy *proxy = data.GetParameter(); #endif delete proxy; @@ -273,12 +300,18 @@ void SWIGV8_SetPrivateData(v8::Handle obj, void* ptr, swig_type_info } else { cdata->handle.MakeWeak(v8::Isolate::GetCurrent(), cdata, SWIGV8_Proxy_DefaultDtor); } -#else +#elif (SWIG_V8_VERSION < 0x032403) if(cdata->swigCMemOwn && (SWIGV8_ClientData*)info->clientdata) { cdata->handle.MakeWeak(cdata, ((SWIGV8_ClientData*)info->clientdata)->dtor); } else { cdata->handle.MakeWeak(cdata, SWIGV8_Proxy_DefaultDtor); } +#else + if(cdata->swigCMemOwn && (SWIGV8_ClientData*)info->clientdata) { + cdata->handle.SetWeak(cdata, ((SWIGV8_ClientData*)info->clientdata)->dtor); + } else { + cdata->handle.SetWeak(cdata, SWIGV8_Proxy_DefaultDtor); + } #endif #if (SWIG_V8_VERSION < 0x031710) @@ -312,7 +345,9 @@ v8::Handle SWIG_V8_NewPointerObj(void *ptr, swig_type_info *info, int v8::Handle class_templ; if (ptr == NULL) { - SWIGV8_ESCAPE(SWIGV8_NULL()); +// SWIGV8_ESCAPE(SWIGV8_NULL()); + v8::Local result = SWIGV8_NULL(); + SWIGV8_ESCAPE(result); } #if (SWIG_V8_VERSION < 0x031903) @@ -331,7 +366,8 @@ v8::Handle SWIG_V8_NewPointerObj(void *ptr, swig_type_info *info, int } #endif - v8::Handle result = class_templ->InstanceTemplate()->NewInstance(); +// v8::Handle result = class_templ->InstanceTemplate()->NewInstance(); + v8::Local result = class_templ->InstanceTemplate()->NewInstance(); SWIGV8_SetPrivateData(result, ptr, info, flags); SWIGV8_ESCAPE(result); @@ -467,16 +503,17 @@ int SWIGV8_ConvertPacked(v8::Handle valRef, void *ptr, size_t sz, swi } #if (SWIG_V8_VERSION < 0x031710) -void _wrap_SwigV8PackedData_delete(v8::Persistent< v8::Value > object, void *parameter) -{ +void _wrap_SwigV8PackedData_delete(v8::Persistent< v8::Value > object, void *parameter) { SwigV8PackedData *cdata = static_cast(parameter); #elif (SWIG_V8_VERSION < 0x031900) -void _wrap_SwigV8PackedData_delete(v8::Isolate *isolate, v8::Persistent< v8::Value > object, void *parameter) -{ +void _wrap_SwigV8PackedData_delete(v8::Isolate *isolate, v8::Persistent< v8::Value > object, void *parameter) { SwigV8PackedData *cdata = static_cast(parameter); +#elif (SWIG_V8_VERSION < 0x032403) +void _wrap_SwigV8PackedData_delete(v8::Isolate *isolate, v8::Persistent< v8::Object > * object, SwigV8PackedData *cdata) { #else -void _wrap_SwigV8PackedData_delete(v8::Isolate *isolate, v8::Persistent< v8::Object > * object, SwigV8PackedData *cdata) -{ +void _wrap_SwigV8PackedData_delete(const v8::WeakCallbackData &data) { + v8::Local object = data.GetValue(); + SwigV8PackedData *cdata = data.GetParameter(); #endif delete cdata; @@ -489,8 +526,10 @@ void _wrap_SwigV8PackedData_delete(v8::Isolate *isolate, v8::Persistent< v8::Obj object.Dispose(isolate); #elif (SWIG_V8_VERSION < 0x032100) object->Dispose(isolate); -#else +#elif (SWIG_V8_VERSION < 0x032403) object->Dispose(); +#else + object.Clear(); #endif } @@ -499,7 +538,8 @@ v8::Handle SWIGV8_NewPackedObj(void *data, size_t size, swig_type_inf SWIGV8_HANDLESCOPE_ESC(); SwigV8PackedData* cdata = new SwigV8PackedData(data, size, type); - v8::Handle obj = SWIGV8_OBJECT_NEW(); +// v8::Handle obj = SWIGV8_OBJECT_NEW(); + v8::Local obj = SWIGV8_OBJECT_NEW(); obj->SetHiddenValue(SWIGV8_STRING_NEW("__swig__packed_data__"), SWIGV8_BOOLEAN_NEW(true)); @@ -522,10 +562,11 @@ v8::Handle SWIGV8_NewPackedObj(void *data, size_t size, swig_type_inf cdata->handle.MakeWeak(cdata, _wrap_SwigV8PackedData_delete); #elif (SWIG_V8_VERSION < 0x031918) cdata->handle.MakeWeak(v8::Isolate::GetCurrent(), cdata, _wrap_SwigV8PackedData_delete); -#elif (SWIG_V8_VERSION < 0x032530) +#elif (SWIG_V8_VERSION < 0x032403) cdata->handle.MakeWeak(cdata, _wrap_SwigV8PackedData_delete); #else - v8::V8::MakeWeak(&cdata->handle, cdata, _wrap_SwigV8PackedData_delete); + cdata->handle.SetWeak(cdata, _wrap_SwigV8PackedData_delete); +// v8::V8::SetWeak(&cdata->handle, cdata, _wrap_SwigV8PackedData_delete); #endif #if (SWIG_V8_VERSION < 0x031710) @@ -549,13 +590,15 @@ v8::Handle SWIGV8_NewPackedObj(void *data, size_t size, swig_type_inf * ---------------------------------------------------------------------------*/ SWIGRUNTIME -v8::Handle SWIGV8_AppendOutput(v8::Handle result, v8::Handle obj) { +//v8::Handle SWIGV8_AppendOutput(v8::Handle result, v8::Handle obj) { +v8::Handle SWIGV8_AppendOutput(v8::Local result, v8::Handle obj) { SWIGV8_HANDLESCOPE_ESC(); if (result->IsUndefined()) { result = SWIGV8_ARRAY_NEW(); } - v8::Handle arr = v8::Handle::Cast(result); + //v8::Handle arr = v8::Handle::Cast(result); + v8::Local arr = v8::Local::Cast(result); arr->Set(arr->Length(), obj); SWIGV8_ESCAPE(arr); diff --git a/Tools/javascript/v8_shell.cxx b/Tools/javascript/v8_shell.cxx index 00d81a034..aac1284bd 100644 --- a/Tools/javascript/v8_shell.cxx +++ b/Tools/javascript/v8_shell.cxx @@ -32,7 +32,7 @@ typedef v8::PropertyCallbackInfo SwigV8PropertyCallbackInfo; #define SWIGV8_HANDLESCOPE() v8::HandleScope scope #define SWIGV8_HANDLESCOPE_ESC() v8::HandleScope scope #define SWIGV8_ESCAPE(val) return scope.Close(val) -#elif (SWIG_V8_VERSION < 0x032440) +#elif (SWIG_V8_VERSION < 0x032318) #define SWIGV8_HANDLESCOPE() v8::HandleScope scope(v8::Isolate::GetCurrent()); #define SWIGV8_HANDLESCOPE_ESC() v8::HandleScope scope(v8::Isolate::GetCurrent()); #define SWIGV8_ESCAPE(val) return scope.Close(val) @@ -42,7 +42,7 @@ typedef v8::PropertyCallbackInfo SwigV8PropertyCallbackInfo; #define SWIGV8_ESCAPE(val) return scope.Escape(val) #endif -#if (SWIG_V8_VERSION < 0x032440) +#if (SWIG_V8_VERSION < 0x032318) #define SWIGV8_CURRENT_CONTEXT() v8::Context::GetCurrent() #define SWIGV8_STRING_NEW(str) v8::String::New(str) #define SWIGV8_FUNCTEMPLATE_NEW(func) v8::FunctionTemplate::New(func) @@ -112,7 +112,7 @@ private: #error "implement dll loading" #endif -V8Shell::V8Shell(){} +V8Shell::V8Shell() {} V8Shell::~V8Shell() {} @@ -237,8 +237,6 @@ bool V8Shell::DisposeEngine() { } SwigV8Context V8Shell::CreateShellContext() { - SWIGV8_HANDLESCOPE_ESC(); - // Create a template for the global object. v8::Handle global = v8::ObjectTemplate::New(); @@ -253,7 +251,7 @@ SwigV8Context V8Shell::CreateShellContext() { return context; #else SwigV8Context context = v8::Context::New(v8::Isolate::GetCurrent(), NULL, global); - SWIGV8_ESCAPE(context); + return context; #endif } -- cgit v1.2.1 From fee57484991204b33f10741dce92fd6ce0283a3c Mon Sep 17 00:00:00 2001 From: Richard Date: Fri, 22 Aug 2014 19:17:23 -0500 Subject: Fixes for 3.23.18 (0x032318) --- Lib/javascript/v8/javascriptcode.swg | 6 ++--- Lib/javascript/v8/javascriptrun.swg | 51 ++++++++++++++---------------------- 2 files changed, 23 insertions(+), 34 deletions(-) diff --git a/Lib/javascript/v8/javascriptcode.swg b/Lib/javascript/v8/javascriptcode.swg index b5742cfd5..61bef4cd0 100644 --- a/Lib/javascript/v8/javascriptcode.swg +++ b/Lib/javascript/v8/javascriptcode.swg @@ -130,7 +130,7 @@ void $jswrapper(v8::Persistent< v8::Value > object, void *parameter) { #elif (SWIG_V8_VERSION < 0x031900) void $jswrapper(v8::Isolate *isolate, v8::Persistent< v8::Value > object, void *parameter) { SWIGV8_Proxy *proxy = static_cast(parameter); -#elif (SWIG_V8_VERSION < 0x032403) +#elif (SWIG_V8_VERSION < SWIG_SETWEAK_VERSION) void $jswrapper(v8::Isolate *isolate, v8::Persistent< v8::Object > * object, SWIGV8_Proxy *proxy) { #else void $jswrapper(const v8::WeakCallbackData &data) { @@ -174,7 +174,7 @@ void $jswrapper(v8::Persistent< v8::Value > object, void *parameter) { #elif (SWIG_V8_VERSION < 0x031900) void $jswrapper(v8::Isolate *isolate, v8::Persistent< v8::Value > object, void *parameter) { SWIGV8_Proxy *proxy = static_cast(parameter); -#elif (SWIG_V8_VERSION < 0x032403) +#elif (SWIG_V8_VERSION < SWIG_SETWEAK_VERSION) void $jswrapper(v8::Isolate *isolate, v8::Persistent< v8::Object > * object, SWIGV8_Proxy *proxy) { #else void $jswrapper(const v8::WeakCallbackData &data) { @@ -194,7 +194,7 @@ void $jswrapper(const v8::WeakCallbackData &data) { object.Dispose(isolate); #elif (SWIG_V8_VERSION < 0x032100) object->Dispose(isolate); -#elif (SWIG_V8_VERSION < 0x032403) +#elif (SWIG_V8_VERSION < SWIG_SETWEAK_VERSION) object->Dispose(); #else object.Clear(); diff --git a/Lib/javascript/v8/javascriptrun.swg b/Lib/javascript/v8/javascriptrun.swg index 9c84059b4..f5a4a418c 100644 --- a/Lib/javascript/v8/javascriptrun.swg +++ b/Lib/javascript/v8/javascriptrun.swg @@ -3,6 +3,8 @@ * * ---------------------------------------------------------------------------*/ +#define SWIG_SETWEAK_VERSION 0x032318 + #if (SWIG_V8_VERSION < 0x031903) typedef v8::Handle SwigV8ReturnValue; typedef v8::Arguments SwigV8Arguments; @@ -21,7 +23,7 @@ typedef v8::PropertyCallbackInfo SwigV8PropertyCallbackInfo; #define SWIGV8_HANDLESCOPE() v8::HandleScope scope #define SWIGV8_HANDLESCOPE_ESC() v8::HandleScope scope #define SWIGV8_ESCAPE(val) return scope.Close(val) -#elif (SWIG_V8_VERSION < 0x032319) +#elif (SWIG_V8_VERSION < 0x032318) #define SWIGV8_HANDLESCOPE() v8::HandleScope scope(v8::Isolate::GetCurrent()); #define SWIGV8_HANDLESCOPE_ESC() v8::HandleScope scope(v8::Isolate::GetCurrent()); #define SWIGV8_ESCAPE(val) return scope.Close(val) @@ -31,7 +33,9 @@ typedef v8::PropertyCallbackInfo SwigV8PropertyCallbackInfo; #define SWIGV8_ESCAPE(val) return scope.Escape(val) #endif -#if (SWIG_V8_VERSION < 0x032319) +#if (SWIG_V8_VERSION < 0x032318) +#define SWIGV8_ADJUST_MEMORY(size) v8::V8::AdjustAmountOfExternalAllocatedMemory(size) +#define SWIGV8_THROW_EXCEPTION(err) v8::ThrowException(err) #define SWIGV8_CURRENT_CONTEXT() v8::Context::GetCurrent() #define SWIGV8_STRING_NEW(str) v8::String::New(str) #define SWIGV8_STRING_NEW2(cstr, len) v8::String::NewFromUtf8(v8::Isolate::GetCurrent(), cstr, v8::String::kNormalString, len) @@ -49,6 +53,8 @@ typedef v8::PropertyCallbackInfo SwigV8PropertyCallbackInfo; #define SWIGV8_INTEGER_NEW_UNS(num) v8::Integer::NewFromUnsigned(num) #define SWIGV8_INT32_NEW(num) v8::Int32::New(num) #else +#define SWIGV8_ADJUST_MEMORY(size) v8::Isolate::GetCurrent()->AdjustAmountOfExternalAllocatedMemory(size) +#define SWIGV8_THROW_EXCEPTION(err) v8::Isolate::GetCurrent()->ThrowException(err) #define SWIGV8_CURRENT_CONTEXT() v8::Isolate::GetCurrent()->GetCurrentContext() #define SWIGV8_STRING_NEW(str) v8::String::NewFromUtf8(v8::Isolate::GetCurrent(), str) #define SWIGV8_STRING_NEW2(cstr, len) v8::String::NewFromUtf8(v8::Isolate::GetCurrent(), cstr, v8::String::kNormalString, len) @@ -79,11 +85,7 @@ typedef v8::PropertyCallbackInfo SwigV8PropertyCallbackInfo; #define SWIGV8_OVERLOAD false void SWIG_V8_Raise(const char* msg) { -#if (SWIG_V8_VERSION < 0x032403) - v8::ThrowException(v8::Exception::Error(SWIGV8_STRING_NEW(msg))); -#else - v8::Isolate::GetCurrent()->ThrowException(v8::Exception::Error(SWIGV8_STRING_NEW(msg))); -#endif + SWIGV8_THROW_EXCEPTION(v8::Exception::Error(SWIGV8_STRING_NEW(msg))); } /* @@ -115,11 +117,7 @@ public: virtual void error(int code, const char* msg) { err = v8::Exception::Error(SWIGV8_STRING_NEW(msg)); if(code != SWIG_TypeError) { -#if (SWIG_V8_VERSION < 0x032403) - v8::ThrowException(err); -#else - v8::Isolate::GetCurrent()->ThrowException(err); -#endif + SWIGV8_THROW_EXCEPTION(err); } } v8::Handle err; @@ -137,11 +135,7 @@ public: class SWIGV8_Proxy { public: SWIGV8_Proxy(): swigCMemOwn(false), swigCObject(0), info(0) { -#if (SWIG_V8_VERSION < 0x032403) - v8::V8::AdjustAmountOfExternalAllocatedMemory(SWIGV8_AVG_OBJ_SIZE); -#else - v8::Isolate::GetCurrent()->AdjustAmountOfExternalAllocatedMemory(SWIGV8_AVG_OBJ_SIZE); -#endif + SWIGV8_ADJUST_MEMORY(SWIGV8_AVG_OBJ_SIZE); }; ~SWIGV8_Proxy() { @@ -151,7 +145,7 @@ public: #elif (SWIG_V8_VERSION < 0x032100) handle.ClearWeak(v8::Isolate::GetCurrent()); handle.Dispose(v8::Isolate::GetCurrent()); -#elif (SWIG_V8_VERSION < 0x032403) +#elif (SWIG_V8_VERSION < SWIG_SETWEAK_VERSION) handle.ClearWeak(); handle.Dispose(); #else @@ -159,16 +153,11 @@ public: handle.Reset(); #endif -#if (SWIG_V8_VERSION < 0x032403) +#if (SWIG_V8_VERSION < SWIG_SETWEAK_VERSION) handle.Clear(); #endif -#if (SWIG_V8_VERSION < 0x032403) - v8::V8::AdjustAmountOfExternalAllocatedMemory(-SWIGV8_AVG_OBJ_SIZE); -#else - v8::Isolate::GetCurrent()->AdjustAmountOfExternalAllocatedMemory(-SWIGV8_AVG_OBJ_SIZE); -#endif - + SWIGV8_ADJUST_MEMORY(-SWIGV8_AVG_OBJ_SIZE); } bool swigCMemOwn; @@ -185,7 +174,7 @@ public: void (*dtor) (v8::Persistent< v8::Value> object, void *parameter); #elif (SWIG_V8_VERSION < 0x031900) void (*dtor) (v8::Isolate *isolate, v8::Persistent< v8::Value> object, void *parameter); -#elif (SWIG_V8_VERSION < 0x032403) +#elif (SWIG_V8_VERSION < SWIG_SETWEAK_VERSION) void (*dtor) (v8::Isolate *isolate, v8::Persistent< v8::Object > *object, SWIGV8_Proxy *proxy); #else void (*dtor) (const v8::WeakCallbackData &data); @@ -233,7 +222,7 @@ void SWIGV8_Proxy_DefaultDtor(v8::Persistent< v8::Value > object, void *paramete #elif (SWIG_V8_VERSION < 0x031900) void SWIGV8_Proxy_DefaultDtor(v8::Isolate *, v8::Persistent< v8::Value > object, void *parameter) { SWIGV8_Proxy *proxy = static_cast(parameter); -#elif (SWIG_V8_VERSION < 0x032403) +#elif (SWIG_V8_VERSION < SWIG_SETWEAK_VERSION) void SWIGV8_Proxy_DefaultDtor(v8::Isolate *, v8::Persistent< v8::Object > *object, SWIGV8_Proxy *proxy) { #else void SWIGV8_Proxy_DefaultDtor(const v8::WeakCallbackData &data) { @@ -300,7 +289,7 @@ void SWIGV8_SetPrivateData(v8::Handle obj, void* ptr, swig_type_info } else { cdata->handle.MakeWeak(v8::Isolate::GetCurrent(), cdata, SWIGV8_Proxy_DefaultDtor); } -#elif (SWIG_V8_VERSION < 0x032403) +#elif (SWIG_V8_VERSION < SWIG_SETWEAK_VERSION) if(cdata->swigCMemOwn && (SWIGV8_ClientData*)info->clientdata) { cdata->handle.MakeWeak(cdata, ((SWIGV8_ClientData*)info->clientdata)->dtor); } else { @@ -508,7 +497,7 @@ void _wrap_SwigV8PackedData_delete(v8::Persistent< v8::Value > object, void *par #elif (SWIG_V8_VERSION < 0x031900) void _wrap_SwigV8PackedData_delete(v8::Isolate *isolate, v8::Persistent< v8::Value > object, void *parameter) { SwigV8PackedData *cdata = static_cast(parameter); -#elif (SWIG_V8_VERSION < 0x032403) +#elif (SWIG_V8_VERSION < SWIG_SETWEAK_VERSION) void _wrap_SwigV8PackedData_delete(v8::Isolate *isolate, v8::Persistent< v8::Object > * object, SwigV8PackedData *cdata) { #else void _wrap_SwigV8PackedData_delete(const v8::WeakCallbackData &data) { @@ -526,7 +515,7 @@ void _wrap_SwigV8PackedData_delete(const v8::WeakCallbackDataDispose(isolate); -#elif (SWIG_V8_VERSION < 0x032403) +#elif (SWIG_V8_VERSION < SWIG_SETWEAK_VERSION) object->Dispose(); #else object.Clear(); @@ -562,7 +551,7 @@ v8::Handle SWIGV8_NewPackedObj(void *data, size_t size, swig_type_inf cdata->handle.MakeWeak(cdata, _wrap_SwigV8PackedData_delete); #elif (SWIG_V8_VERSION < 0x031918) cdata->handle.MakeWeak(v8::Isolate::GetCurrent(), cdata, _wrap_SwigV8PackedData_delete); -#elif (SWIG_V8_VERSION < 0x032403) +#elif (SWIG_V8_VERSION < SWIG_SETWEAK_VERSION) cdata->handle.MakeWeak(cdata, _wrap_SwigV8PackedData_delete); #else cdata->handle.SetWeak(cdata, _wrap_SwigV8PackedData_delete); -- cgit v1.2.1 From dea3144726fa3a854181dd302f1840c44aa8cc8f Mon Sep 17 00:00:00 2001 From: Richard Date: Fri, 22 Aug 2014 19:29:22 -0500 Subject: Fixes for V8 3.22.24 (0x032224) Some errors left (??) --- Lib/javascript/v8/javascriptrun.swg | 26 +++++++++++++++----------- 1 file changed, 15 insertions(+), 11 deletions(-) diff --git a/Lib/javascript/v8/javascriptrun.swg b/Lib/javascript/v8/javascriptrun.swg index f5a4a418c..3a8d099df 100644 --- a/Lib/javascript/v8/javascriptrun.swg +++ b/Lib/javascript/v8/javascriptrun.swg @@ -3,7 +3,7 @@ * * ---------------------------------------------------------------------------*/ -#define SWIG_SETWEAK_VERSION 0x032318 +#define SWIG_SETWEAK_VERSION 0x032224 #if (SWIG_V8_VERSION < 0x031903) typedef v8::Handle SwigV8ReturnValue; @@ -23,7 +23,7 @@ typedef v8::PropertyCallbackInfo SwigV8PropertyCallbackInfo; #define SWIGV8_HANDLESCOPE() v8::HandleScope scope #define SWIGV8_HANDLESCOPE_ESC() v8::HandleScope scope #define SWIGV8_ESCAPE(val) return scope.Close(val) -#elif (SWIG_V8_VERSION < 0x032318) +#elif (SWIG_V8_VERSION < 0x032224) #define SWIGV8_HANDLESCOPE() v8::HandleScope scope(v8::Isolate::GetCurrent()); #define SWIGV8_HANDLESCOPE_ESC() v8::HandleScope scope(v8::Isolate::GetCurrent()); #define SWIGV8_ESCAPE(val) return scope.Close(val) @@ -33,11 +33,21 @@ typedef v8::PropertyCallbackInfo SwigV8PropertyCallbackInfo; #define SWIGV8_ESCAPE(val) return scope.Escape(val) #endif -#if (SWIG_V8_VERSION < 0x032318) +#if (SWIG_V8_VERSION < 0x032224) +#define SWIGV8_STRING_NEW(str) v8::String::New(str) +#define SWIGV8_CURRENT_CONTEXT() v8::Context::GetCurrent() +#define SWIGV8_SYMBOL_NEW(sym) v8::String::NewSymbol(sym) #define SWIGV8_ADJUST_MEMORY(size) v8::V8::AdjustAmountOfExternalAllocatedMemory(size) #define SWIGV8_THROW_EXCEPTION(err) v8::ThrowException(err) -#define SWIGV8_CURRENT_CONTEXT() v8::Context::GetCurrent() -#define SWIGV8_STRING_NEW(str) v8::String::New(str) +#else +#define SWIGV8_THROW_EXCEPTION(err) v8::Isolate::GetCurrent()->ThrowException(err) +#define SWIGV8_ADJUST_MEMORY(size) v8::Isolate::GetCurrent()->AdjustAmountOfExternalAllocatedMemory(size) +#define SWIGV8_STRING_NEW(str) v8::String::NewFromUtf8(v8::Isolate::GetCurrent(), str) +#define SWIGV8_CURRENT_CONTEXT() v8::Isolate::GetCurrent()->GetCurrentContext() +#define SWIGV8_SYMBOL_NEW(sym) v8::String::NewFromUtf8(v8::Isolate::GetCurrent(), sym) +#endif + +#if (SWIG_V8_VERSION < 0x032318) #define SWIGV8_STRING_NEW2(cstr, len) v8::String::NewFromUtf8(v8::Isolate::GetCurrent(), cstr, v8::String::kNormalString, len) #define SWIGV8_FUNCTEMPLATE_NEW(func) v8::FunctionTemplate::New(func) #define SWIGV8_FUNCTEMPLATE_NEW_VOID() v8::FunctionTemplate::New() @@ -48,15 +58,10 @@ typedef v8::PropertyCallbackInfo SwigV8PropertyCallbackInfo; #define SWIGV8_BOOLEAN_NEW(bool) v8::Boolean::New(bool) #define SWIGV8_ARRAY_NEW() v8::Array::New() #define SWIGV8_NUMBER_NEW(num) v8::Number::New(num) -#define SWIGV8_SYMBOL_NEW(sym) v8::String::NewSymbol(sym) #define SWIGV8_INTEGER_NEW(num) v8::Integer::New(num) #define SWIGV8_INTEGER_NEW_UNS(num) v8::Integer::NewFromUnsigned(num) #define SWIGV8_INT32_NEW(num) v8::Int32::New(num) #else -#define SWIGV8_ADJUST_MEMORY(size) v8::Isolate::GetCurrent()->AdjustAmountOfExternalAllocatedMemory(size) -#define SWIGV8_THROW_EXCEPTION(err) v8::Isolate::GetCurrent()->ThrowException(err) -#define SWIGV8_CURRENT_CONTEXT() v8::Isolate::GetCurrent()->GetCurrentContext() -#define SWIGV8_STRING_NEW(str) v8::String::NewFromUtf8(v8::Isolate::GetCurrent(), str) #define SWIGV8_STRING_NEW2(cstr, len) v8::String::NewFromUtf8(v8::Isolate::GetCurrent(), cstr, v8::String::kNormalString, len) #define SWIGV8_FUNCTEMPLATE_NEW(func) v8::FunctionTemplate::New(v8::Isolate::GetCurrent(), func) #define SWIGV8_FUNCTEMPLATE_NEW_VOID() v8::FunctionTemplate::New(v8::Isolate::GetCurrent()) @@ -67,7 +72,6 @@ typedef v8::PropertyCallbackInfo SwigV8PropertyCallbackInfo; #define SWIGV8_BOOLEAN_NEW(bool) v8::Boolean::New(v8::Isolate::GetCurrent(), bool) #define SWIGV8_ARRAY_NEW() v8::Array::New(v8::Isolate::GetCurrent()) #define SWIGV8_NUMBER_NEW(num) v8::Number::New(v8::Isolate::GetCurrent(), num) -#define SWIGV8_SYMBOL_NEW(sym) v8::String::NewFromUtf8(v8::Isolate::GetCurrent(), sym) #define SWIGV8_INTEGER_NEW(num) v8::Integer::New(v8::Isolate::GetCurrent(), num) #define SWIGV8_INTEGER_NEW_UNS(num) v8::Integer::NewFromUnsigned(v8::Isolate::GetCurrent(), num) #define SWIGV8_INT32_NEW(num) v8::Int32::New(v8::Isolate::GetCurrent(), num) -- cgit v1.2.1 From ee88602fdea72dcb7a736f1bd14e70f48d0fb287 Mon Sep 17 00:00:00 2001 From: Richard Date: Fri, 22 Aug 2014 19:52:51 -0500 Subject: Use full name --- Lib/javascript/v8/javascriptrun.swg | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/Lib/javascript/v8/javascriptrun.swg b/Lib/javascript/v8/javascriptrun.swg index 3a8d099df..d4d35646a 100644 --- a/Lib/javascript/v8/javascriptrun.swg +++ b/Lib/javascript/v8/javascriptrun.swg @@ -350,12 +350,12 @@ v8::Handle SWIG_V8_NewPointerObj(void *ptr, swig_type_info *info, int class_templ = SWIGV8_SWIGTYPE_Proxy_class_templ; } #else - v8::Isolate *iso = v8::Isolate::GetCurrent(); + v8::Isolate *isolate = v8::Isolate::GetCurrent(); if(info->clientdata != 0) { - class_templ = v8::Handle::New(iso, ((SWIGV8_ClientData*) info->clientdata)->class_templ); + class_templ = v8::Handle::New(isolate, ((SWIGV8_ClientData*) info->clientdata)->class_templ); } else { - class_templ = v8::Handle::New(iso, SWIGV8_SWIGTYPE_Proxy_class_templ); + class_templ = v8::Handle::New(isolate, SWIGV8_SWIGTYPE_Proxy_class_templ); } #endif -- cgit v1.2.1 From eeb4b5497ebf55df303bc0818023fb13f74e6049 Mon Sep 17 00:00:00 2001 From: Richard Date: Fri, 22 Aug 2014 21:38:13 -0500 Subject: Fixes for v8 3.24.17 (0x032417) --- Lib/javascript/v8/javascriptcode.swg | 2 +- Lib/javascript/v8/javascriptrun.swg | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/Lib/javascript/v8/javascriptcode.swg b/Lib/javascript/v8/javascriptcode.swg index 61bef4cd0..840d45bfb 100644 --- a/Lib/javascript/v8/javascriptcode.swg +++ b/Lib/javascript/v8/javascriptcode.swg @@ -385,7 +385,7 @@ fail: $jsmangledname_class->Inherit(static_cast(SWIGTYPE_p$jsbaseclass->clientdata)->class_templ); #else $jsmangledname_class->Inherit( - v8::Handle::New( + v8::Local::New( v8::Isolate::GetCurrent(), static_cast(SWIGTYPE_p$jsbaseclass->clientdata)->class_templ) ); diff --git a/Lib/javascript/v8/javascriptrun.swg b/Lib/javascript/v8/javascriptrun.swg index d4d35646a..147a120e0 100644 --- a/Lib/javascript/v8/javascriptrun.swg +++ b/Lib/javascript/v8/javascriptrun.swg @@ -353,9 +353,9 @@ v8::Handle SWIG_V8_NewPointerObj(void *ptr, swig_type_info *info, int v8::Isolate *isolate = v8::Isolate::GetCurrent(); if(info->clientdata != 0) { - class_templ = v8::Handle::New(isolate, ((SWIGV8_ClientData*) info->clientdata)->class_templ); + class_templ = v8::Local::New(isolate, ((SWIGV8_ClientData*) info->clientdata)->class_templ); } else { - class_templ = v8::Handle::New(isolate, SWIGV8_SWIGTYPE_Proxy_class_templ); + class_templ = v8::Local::New(isolate, SWIGV8_SWIGTYPE_Proxy_class_templ); } #endif -- cgit v1.2.1 From a6ffb22a2a2e5622370c7c0e5871ce4bc77d0e17 Mon Sep 17 00:00:00 2001 From: Richard Date: Fri, 22 Aug 2014 22:23:44 -0500 Subject: Fixed for v8 3.27.34 --- Tools/javascript/v8_shell.cxx | 3 +++ 1 file changed, 3 insertions(+) diff --git a/Tools/javascript/v8_shell.cxx b/Tools/javascript/v8_shell.cxx index aac1284bd..7830c0bdb 100644 --- a/Tools/javascript/v8_shell.cxx +++ b/Tools/javascript/v8_shell.cxx @@ -119,6 +119,9 @@ V8Shell::~V8Shell() {} bool V8Shell::RunScript(const std::string& scriptPath) { std::string source = ReadFile(scriptPath); + v8::Isolate* isolate = v8::Isolate::New(); + v8::Isolate::Scope isolate_scope(isolate); + SWIGV8_HANDLESCOPE(); SwigV8Context context = CreateShellContext(); -- cgit v1.2.1 From 6fee208010f5b7358283ff365ecbfda13f2ed456 Mon Sep 17 00:00:00 2001 From: Richard Date: Fri, 22 Aug 2014 23:42:31 -0500 Subject: Fixes for v8 3.19.2 (0x031902) --- Lib/javascript/v8/javascriptrun.swg | 16 +++++++++++++--- Tools/javascript/v8_shell.cxx | 7 +++++-- 2 files changed, 18 insertions(+), 5 deletions(-) diff --git a/Lib/javascript/v8/javascriptrun.swg b/Lib/javascript/v8/javascriptrun.swg index 147a120e0..d29726f14 100644 --- a/Lib/javascript/v8/javascriptrun.swg +++ b/Lib/javascript/v8/javascriptrun.swg @@ -338,9 +338,12 @@ v8::Handle SWIG_V8_NewPointerObj(void *ptr, swig_type_info *info, int v8::Handle class_templ; if (ptr == NULL) { -// SWIGV8_ESCAPE(SWIGV8_NULL()); +#if (SWIG_V8_VERSION < 0x031903) + SWIGV8_ESCAPE(SWIGV8_NULL()); +#else v8::Local result = SWIGV8_NULL(); SWIGV8_ESCAPE(result); +#endif } #if (SWIG_V8_VERSION < 0x031903) @@ -583,15 +586,22 @@ v8::Handle SWIGV8_NewPackedObj(void *data, size_t size, swig_type_inf * ---------------------------------------------------------------------------*/ SWIGRUNTIME -//v8::Handle SWIGV8_AppendOutput(v8::Handle result, v8::Handle obj) { + +#if (SWIG_V8_VERSION < 0x031903) +v8::Handle SWIGV8_AppendOutput(v8::Handle result, v8::Handle obj) { +#else v8::Handle SWIGV8_AppendOutput(v8::Local result, v8::Handle obj) { +#endif SWIGV8_HANDLESCOPE_ESC(); if (result->IsUndefined()) { result = SWIGV8_ARRAY_NEW(); } - //v8::Handle arr = v8::Handle::Cast(result); +#if (SWIG_V8_VERSION < 0x031903) + v8::Handle arr = v8::Handle::Cast(result); +#else v8::Local arr = v8::Local::Cast(result); +#endif arr->Set(arr->Length(), obj); SWIGV8_ESCAPE(arr); diff --git a/Tools/javascript/v8_shell.cxx b/Tools/javascript/v8_shell.cxx index 7830c0bdb..0255d7e7f 100644 --- a/Tools/javascript/v8_shell.cxx +++ b/Tools/javascript/v8_shell.cxx @@ -282,11 +282,11 @@ v8::Handle V8Shell::Import(const std::string& module_path) } SwigV8ReturnValue V8Shell::Print(const SwigV8Arguments& args) { + SWIGV8_HANDLESCOPE(); + bool first = true; for (int i = 0; i < args.Length(); i++) { - SWIGV8_HANDLESCOPE(); - if (first) { first = false; } else { @@ -325,6 +325,8 @@ SwigV8ReturnValue V8Shell::Require(const SwigV8Arguments& args) { } SwigV8ReturnValue V8Shell::Quit(const SwigV8Arguments& args) { + SWIGV8_HANDLESCOPE(); + int exit_code = args[0]->Int32Value(); fflush(stdout); fflush(stderr); @@ -334,6 +336,7 @@ SwigV8ReturnValue V8Shell::Quit(const SwigV8Arguments& args) { } SwigV8ReturnValue V8Shell::Version(const SwigV8Arguments& args) { + SWIGV8_HANDLESCOPE(); SWIGV8_RETURN(SWIGV8_STRING_NEW(v8::V8::GetVersion())); } -- cgit v1.2.1 From 408390d146ba84a0153686b8c4b0753de1b4c894 Mon Sep 17 00:00:00 2001 From: Richard Date: Fri, 22 Aug 2014 23:52:09 -0500 Subject: Fixes for v8 3.18.3 (0x031803) --- Lib/javascript/v8/javascriptrun.swg | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/Lib/javascript/v8/javascriptrun.swg b/Lib/javascript/v8/javascriptrun.swg index d29726f14..15e5d2ecd 100644 --- a/Lib/javascript/v8/javascriptrun.swg +++ b/Lib/javascript/v8/javascriptrun.swg @@ -47,8 +47,13 @@ typedef v8::PropertyCallbackInfo SwigV8PropertyCallbackInfo; #define SWIGV8_SYMBOL_NEW(sym) v8::String::NewFromUtf8(v8::Isolate::GetCurrent(), sym) #endif -#if (SWIG_V8_VERSION < 0x032318) +#if (SWIG_V8_VERSION < 0x031803) +#define SWIGV8_STRING_NEW2(cstr, len) v8::String::New(cstr, len) +#else #define SWIGV8_STRING_NEW2(cstr, len) v8::String::NewFromUtf8(v8::Isolate::GetCurrent(), cstr, v8::String::kNormalString, len) +#endif + +#if (SWIG_V8_VERSION < 0x032318) #define SWIGV8_FUNCTEMPLATE_NEW(func) v8::FunctionTemplate::New(func) #define SWIGV8_FUNCTEMPLATE_NEW_VOID() v8::FunctionTemplate::New() #define SWIGV8_OBJECT_NEW() v8::Object::New() @@ -62,7 +67,6 @@ typedef v8::PropertyCallbackInfo SwigV8PropertyCallbackInfo; #define SWIGV8_INTEGER_NEW_UNS(num) v8::Integer::NewFromUnsigned(num) #define SWIGV8_INT32_NEW(num) v8::Int32::New(num) #else -#define SWIGV8_STRING_NEW2(cstr, len) v8::String::NewFromUtf8(v8::Isolate::GetCurrent(), cstr, v8::String::kNormalString, len) #define SWIGV8_FUNCTEMPLATE_NEW(func) v8::FunctionTemplate::New(v8::Isolate::GetCurrent(), func) #define SWIGV8_FUNCTEMPLATE_NEW_VOID() v8::FunctionTemplate::New(v8::Isolate::GetCurrent()) #define SWIGV8_OBJECT_NEW() v8::Object::New(v8::Isolate::GetCurrent()) -- cgit v1.2.1 From b8d7cc21b94f910ae6dd7b404d8876278e639030 Mon Sep 17 00:00:00 2001 From: Richard Date: Sat, 23 Aug 2014 00:12:11 -0500 Subject: Use macros for V8 items --- Examples/test-suite/typemap_variables.i | 2 +- Lib/javascript/v8/javascriptprimtypes.swg | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/Examples/test-suite/typemap_variables.i b/Examples/test-suite/typemap_variables.i index 047007a1c..687cae1da 100644 --- a/Examples/test-suite/typemap_variables.i +++ b/Examples/test-suite/typemap_variables.i @@ -16,7 +16,7 @@ // For Javascript V8 we can not use '0' for out typemaps #if defined(SWIG_JAVASCRIPT_V8) %header %{ -#define OUT_NULL_VALUE v8::Null() +#define OUT_NULL_VALUE SWIGV8_NULL() %} #else %header %{ diff --git a/Lib/javascript/v8/javascriptprimtypes.swg b/Lib/javascript/v8/javascriptprimtypes.swg index 2bb03a35f..fe826b863 100644 --- a/Lib/javascript/v8/javascriptprimtypes.swg +++ b/Lib/javascript/v8/javascriptprimtypes.swg @@ -9,7 +9,7 @@ SWIGINTERNINLINE v8::Handle SWIG_From_dec(bool)(bool value) { - return v8::Boolean::New(value); + return SWIGV8_BOOLEAN_NEW(value); } } -- cgit v1.2.1 From 0a07d8f770a703a859857fa61e88aea900f46b6c Mon Sep 17 00:00:00 2001 From: Richard Date: Sat, 23 Aug 2014 01:53:49 -0500 Subject: Update documentation for V8 --- Doc/Manual/Javascript.html | 11 +++++++++++ 1 file changed, 11 insertions(+) diff --git a/Doc/Manual/Javascript.html b/Doc/Manual/Javascript.html index fc24e29c7..3b861be0f 100644 --- a/Doc/Manual/Javascript.html +++ b/Doc/Manual/Javascript.html @@ -88,6 +88,12 @@ $ swig -javascript -jsc example.i
       $ swig -c++ -javascript -jsc example.i
      +

      The V8 code that SWIG generates should work with most versions from 3.11.10 up to 3.29.14 and later.

      +

      Specify the V8 version when running SWIG (e.g. 3.25.30)

      +
      +
      +$ swig -c++ -javascript -v8 -DV8_VERSION=0x032530 example.i
      +

      This creates a C/C++ source file example_wrap.c or example_wrap.cxx. The generated C source file contains the low-level wrappers that need to be compiled and linked with the rest of your C/C++ application to create an extension module.

      The name of the wrapper file is derived from the name of the input file. For example, if the input file is example.i, the name of the wrapper file is example_wrap.c. To change this, you can use the -o option. The wrapped module will export one function which must be called to register the module with the Javascript interpreter. For example, if your module is named example the corresponding initializer for JavascriptCore would be

      @@ -129,6 +135,11 @@ $ make check-javascript-examples ENGINE=jsc
       $ make check-javascript-test-suite ENGINE=jsc
      +

      You can specify a specific V8 version for running the examples and tests

      +
      +
      +$ make check-javascript-examples V8_VERSION=0x032530 ENGINE=v8
      +

      26.2.3 Known Issues

      -- cgit v1.2.1 From a3946e152028148948584f63fc11e5167d202b35 Mon Sep 17 00:00:00 2001 From: Richard Date: Sat, 23 Aug 2014 01:54:10 -0500 Subject: Remove unneeded parameter --- Examples/javascript/example.mk | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Examples/javascript/example.mk b/Examples/javascript/example.mk index 9afd5b9bf..cb8a33efd 100644 --- a/Examples/javascript/example.mk +++ b/Examples/javascript/example.mk @@ -18,7 +18,7 @@ SWIG_TOP=../../.. SWIG = $(SWIG_TOP)/preinst-swig TARGET = example INTERFACE = example.i -SWIGOPT=-$(JSENGINE) -DV8_VERSION=$(JSV8_VERSION) -DV8_DEPRECATION_WARNINGS +SWIGOPT=-$(JSENGINE) -DV8_VERSION=$(JSV8_VERSION) check: build $(MAKE) -f $(EXAMPLES_TOP)/Makefile SRCDIR='$(SRCDIR)' JSENGINE='$(JSENGINE)' TARGET='$(TARGET)' javascript_run -- cgit v1.2.1 From 728f540038c214d5edc9b2c2a54825b17ed5df4c Mon Sep 17 00:00:00 2001 From: Richard Date: Sat, 23 Aug 2014 02:06:51 -0500 Subject: Added work on Javascript V8 --- CHANGES.current | 3 +++ 1 file changed, 3 insertions(+) diff --git a/CHANGES.current b/CHANGES.current index 6ce431b60..3c2e90d02 100644 --- a/CHANGES.current +++ b/CHANGES.current @@ -5,6 +5,9 @@ See the RELEASENOTES file for a summary of changes in each release. Version 3.0.3 (in progress) =========================== +2014-08-23: richie765 + [Javascript] Added support for a variety of V8 versions + 2014-08-15: talby [Perl] Include guard fix for nested modules from Anthony Heading (SF Patch #350). -- cgit v1.2.1 From 911fd761b04323817663749f071f8b7b3768105f Mon Sep 17 00:00:00 2001 From: Richard Date: Thu, 28 Aug 2014 19:09:39 -0500 Subject: Minor improvements --- Doc/Manual/Javascript.html | 2 +- Lib/javascript/v8/javascriptcode.swg | 34 ++++++------- Lib/javascript/v8/javascriptrun.swg | 97 ++++++++++++++++++------------------ Tools/javascript/v8_shell.cxx | 56 ++++++++++----------- 4 files changed, 95 insertions(+), 94 deletions(-) diff --git a/Doc/Manual/Javascript.html b/Doc/Manual/Javascript.html index 3b861be0f..aaef6ab17 100644 --- a/Doc/Manual/Javascript.html +++ b/Doc/Manual/Javascript.html @@ -457,7 +457,7 @@ var x = 42; var y = 105; var g = example.gcd(x,y); -// Accessing the globak variable +// Accessing the global variable var f = example.Foo; example.Foo = 3.1415926; diff --git a/Lib/javascript/v8/javascriptcode.swg b/Lib/javascript/v8/javascriptcode.swg index 840d45bfb..d99546aff 100644 --- a/Lib/javascript/v8/javascriptcode.swg +++ b/Lib/javascript/v8/javascriptcode.swg @@ -8,7 +8,7 @@ * ----------------------------------------------------------------------------- */ %fragment("js_ctor", "templates") %{ -SwigV8ReturnValue $jswrapper(const SwigV8Arguments& args) { +SwigV8ReturnValue $jswrapper(const SwigV8Arguments &args) { SWIGV8_HANDLESCOPE(); v8::Handle self = args.Holder(); @@ -32,7 +32,7 @@ fail: * ----------------------------------------------------------------------------- */ %fragment ("js_veto_ctor", "templates") %{ -SwigV8ReturnValue $jswrapper(const SwigV8Arguments& args) { +SwigV8ReturnValue $jswrapper(const SwigV8Arguments &args) { SWIGV8_HANDLESCOPE(); SWIG_exception(SWIG_ERROR, "Class $jsname can not be instantiated"); @@ -48,7 +48,7 @@ SwigV8ReturnValue $jswrapper(const SwigV8Arguments& args) { * ----------------------------------------------------------------------------- */ %fragment ("js_ctor_dispatcher", "templates") %{ -SwigV8ReturnValue $jswrapper(const SwigV8Arguments& args) { +SwigV8ReturnValue $jswrapper(const SwigV8Arguments &args) { SWIGV8_HANDLESCOPE(); OverloadErrorHandler errorHandler; @@ -74,7 +74,7 @@ fail: * - $jsmangledtype: mangled type of class * ----------------------------------------------------------------------------- */ %fragment("js_overloaded_ctor", "templates") %{ -SwigV8ReturnValue $jswrapper(const SwigV8Arguments& args, V8ErrorHandler& SWIGV8_ErrorHandler) { +SwigV8ReturnValue $jswrapper(const SwigV8Arguments &args, V8ErrorHandler &SWIGV8_ErrorHandler) { SWIGV8_HANDLESCOPE(); v8::Handle self = args.Holder(); @@ -128,10 +128,10 @@ fail: void $jswrapper(v8::Persistent< v8::Value > object, void *parameter) { SWIGV8_Proxy *proxy = static_cast(parameter); #elif (SWIG_V8_VERSION < 0x031900) -void $jswrapper(v8::Isolate *isolate, v8::Persistent< v8::Value > object, void *parameter) { +void $jswrapper(v8::Isolate *isolate, v8::Persistent object, void *parameter) { SWIGV8_Proxy *proxy = static_cast(parameter); -#elif (SWIG_V8_VERSION < SWIG_SETWEAK_VERSION) -void $jswrapper(v8::Isolate *isolate, v8::Persistent< v8::Object > * object, SWIGV8_Proxy *proxy) { +#elif (SWIG_V8_VERSION < SWIGV8_SETWEAK_VERSION) +void $jswrapper(v8::Isolate *isolate, v8::Persistent *object, SWIGV8_Proxy *proxy) { #else void $jswrapper(const v8::WeakCallbackData &data) { v8::Local object = data.GetValue(); @@ -169,13 +169,13 @@ void $jswrapper(const v8::WeakCallbackData &data) { %fragment ("js_dtoroverride", "templates") %{ #if (SWIG_V8_VERSION < 0x031710) -void $jswrapper(v8::Persistent< v8::Value > object, void *parameter) { +void $jswrapper(v8::Persistent object, void *parameter) { SWIGV8_Proxy *proxy = static_cast(parameter); #elif (SWIG_V8_VERSION < 0x031900) -void $jswrapper(v8::Isolate *isolate, v8::Persistent< v8::Value > object, void *parameter) { +void $jswrapper(v8::Isolate *isolate, v8::Persistent object, void *parameter) { SWIGV8_Proxy *proxy = static_cast(parameter); -#elif (SWIG_V8_VERSION < SWIG_SETWEAK_VERSION) -void $jswrapper(v8::Isolate *isolate, v8::Persistent< v8::Object > * object, SWIGV8_Proxy *proxy) { +#elif (SWIG_V8_VERSION < SWIGV8_SETWEAK_VERSION) +void $jswrapper(v8::Isolate *isolate, v8::Persistent< v8::Object> *object, SWIGV8_Proxy *proxy) { #else void $jswrapper(const v8::WeakCallbackData &data) { v8::Local object = data.GetValue(); @@ -194,7 +194,7 @@ void $jswrapper(const v8::WeakCallbackData &data) { object.Dispose(isolate); #elif (SWIG_V8_VERSION < 0x032100) object->Dispose(isolate); -#elif (SWIG_V8_VERSION < SWIG_SETWEAK_VERSION) +#elif (SWIG_V8_VERSION < SWIGV8_SETWEAK_VERSION) object->Dispose(); #else object.Clear(); @@ -210,7 +210,7 @@ void $jswrapper(const v8::WeakCallbackData &data) { * ----------------------------------------------------------------------------- */ %fragment("js_getter", "templates") %{ -SwigV8ReturnValue $jswrapper(v8::Local property, const SwigV8PropertyCallbackInfo& info) { +SwigV8ReturnValue $jswrapper(v8::Local property, const SwigV8PropertyCallbackInfo &info) { SWIGV8_HANDLESCOPE(); v8::Handle jsresult; @@ -233,7 +233,7 @@ fail: %fragment("js_setter", "templates") %{ void $jswrapper(v8::Local property, v8::Local value, - const SwigV8PropertyCallbackInfoVoid& info) { + const SwigV8PropertyCallbackInfoVoid &info) { SWIGV8_HANDLESCOPE(); $jslocals @@ -252,7 +252,7 @@ fail: * ----------------------------------------------------------------------------- */ %fragment("js_function", "templates") %{ -SwigV8ReturnValue $jswrapper(const SwigV8Arguments& args) { +SwigV8ReturnValue $jswrapper(const SwigV8Arguments &args) { SWIGV8_HANDLESCOPE(); v8::Handle jsresult; @@ -277,7 +277,7 @@ fail: * ----------------------------------------------------------------------------- */ %fragment("js_function_dispatcher", "templates") %{ -SwigV8ReturnValue $jswrapper(const SwigV8Arguments& args) { +SwigV8ReturnValue $jswrapper(const SwigV8Arguments &args) { SWIGV8_HANDLESCOPE(); v8::Handle jsresult; @@ -300,7 +300,7 @@ fail: * ----------------------------------------------------------------------------- */ %fragment ("js_overloaded_function", "templates") %{ -SwigV8ReturnValue $jswrapper(const SwigV8Arguments& args, V8ErrorHandler& SWIGV8_ErrorHandler) +SwigV8ReturnValue $jswrapper(const SwigV8Arguments &args, V8ErrorHandler &SWIGV8_ErrorHandler) { SWIGV8_HANDLESCOPE(); diff --git a/Lib/javascript/v8/javascriptrun.swg b/Lib/javascript/v8/javascriptrun.swg index 15e5d2ecd..d4d636c8c 100644 --- a/Lib/javascript/v8/javascriptrun.swg +++ b/Lib/javascript/v8/javascriptrun.swg @@ -3,7 +3,15 @@ * * ---------------------------------------------------------------------------*/ -#define SWIG_SETWEAK_VERSION 0x032224 +// First v8 version that uses "SetWeak" and not "MakeWeak" + +#define SWIGV8_SETWEAK_VERSION 0x032224 + +#if (SWIG_V8_VERSION < 0x031803) +#define SWIGV8_STRING_NEW2(cstr, len) v8::String::New(cstr, len) +#else +#define SWIGV8_STRING_NEW2(cstr, len) v8::String::NewFromUtf8(v8::Isolate::GetCurrent(), cstr, v8::String::kNormalString, len) +#endif #if (SWIG_V8_VERSION < 0x031903) typedef v8::Handle SwigV8ReturnValue; @@ -34,54 +42,47 @@ typedef v8::PropertyCallbackInfo SwigV8PropertyCallbackInfo; #endif #if (SWIG_V8_VERSION < 0x032224) -#define SWIGV8_STRING_NEW(str) v8::String::New(str) -#define SWIGV8_CURRENT_CONTEXT() v8::Context::GetCurrent() -#define SWIGV8_SYMBOL_NEW(sym) v8::String::NewSymbol(sym) #define SWIGV8_ADJUST_MEMORY(size) v8::V8::AdjustAmountOfExternalAllocatedMemory(size) +#define SWIGV8_CURRENT_CONTEXT() v8::Context::GetCurrent() #define SWIGV8_THROW_EXCEPTION(err) v8::ThrowException(err) +#define SWIGV8_STRING_NEW(str) v8::String::New(str) +#define SWIGV8_SYMBOL_NEW(sym) v8::String::NewSymbol(sym) #else -#define SWIGV8_THROW_EXCEPTION(err) v8::Isolate::GetCurrent()->ThrowException(err) #define SWIGV8_ADJUST_MEMORY(size) v8::Isolate::GetCurrent()->AdjustAmountOfExternalAllocatedMemory(size) -#define SWIGV8_STRING_NEW(str) v8::String::NewFromUtf8(v8::Isolate::GetCurrent(), str) #define SWIGV8_CURRENT_CONTEXT() v8::Isolate::GetCurrent()->GetCurrentContext() +#define SWIGV8_THROW_EXCEPTION(err) v8::Isolate::GetCurrent()->ThrowException(err) +#define SWIGV8_STRING_NEW(str) v8::String::NewFromUtf8(v8::Isolate::GetCurrent(), str) #define SWIGV8_SYMBOL_NEW(sym) v8::String::NewFromUtf8(v8::Isolate::GetCurrent(), sym) #endif -#if (SWIG_V8_VERSION < 0x031803) -#define SWIGV8_STRING_NEW2(cstr, len) v8::String::New(cstr, len) -#else -#define SWIGV8_STRING_NEW2(cstr, len) v8::String::NewFromUtf8(v8::Isolate::GetCurrent(), cstr, v8::String::kNormalString, len) -#endif - #if (SWIG_V8_VERSION < 0x032318) +#define SWIGV8_ARRAY_NEW() v8::Array::New() +#define SWIGV8_BOOLEAN_NEW(bool) v8::Boolean::New(bool) +#define SWIGV8_EXTERNAL_NEW(val) v8::External::New(val) #define SWIGV8_FUNCTEMPLATE_NEW(func) v8::FunctionTemplate::New(func) #define SWIGV8_FUNCTEMPLATE_NEW_VOID() v8::FunctionTemplate::New() +#define SWIGV8_INT32_NEW(num) v8::Int32::New(num) +#define SWIGV8_INTEGER_NEW(num) v8::Integer::New(num) +#define SWIGV8_INTEGER_NEW_UNS(num) v8::Integer::NewFromUnsigned(num) +#define SWIGV8_NUMBER_NEW(num) v8::Number::New(num) #define SWIGV8_OBJECT_NEW() v8::Object::New() -#define SWIGV8_EXTERNAL_NEW(val) v8::External::New(val) #define SWIGV8_UNDEFINED() v8::Undefined() #define SWIGV8_NULL() v8::Null() -#define SWIGV8_BOOLEAN_NEW(bool) v8::Boolean::New(bool) -#define SWIGV8_ARRAY_NEW() v8::Array::New() -#define SWIGV8_NUMBER_NEW(num) v8::Number::New(num) -#define SWIGV8_INTEGER_NEW(num) v8::Integer::New(num) -#define SWIGV8_INTEGER_NEW_UNS(num) v8::Integer::NewFromUnsigned(num) -#define SWIGV8_INT32_NEW(num) v8::Int32::New(num) #else +#define SWIGV8_ARRAY_NEW() v8::Array::New(v8::Isolate::GetCurrent()) +#define SWIGV8_BOOLEAN_NEW(bool) v8::Boolean::New(v8::Isolate::GetCurrent(), bool) +#define SWIGV8_EXTERNAL_NEW(val) v8::External::New(v8::Isolate::GetCurrent(), val) #define SWIGV8_FUNCTEMPLATE_NEW(func) v8::FunctionTemplate::New(v8::Isolate::GetCurrent(), func) #define SWIGV8_FUNCTEMPLATE_NEW_VOID() v8::FunctionTemplate::New(v8::Isolate::GetCurrent()) +#define SWIGV8_INT32_NEW(num) v8::Int32::New(v8::Isolate::GetCurrent(), num) +#define SWIGV8_INTEGER_NEW(num) v8::Integer::New(v8::Isolate::GetCurrent(), num) +#define SWIGV8_INTEGER_NEW_UNS(num) v8::Integer::NewFromUnsigned(v8::Isolate::GetCurrent(), num) +#define SWIGV8_NUMBER_NEW(num) v8::Number::New(v8::Isolate::GetCurrent(), num) #define SWIGV8_OBJECT_NEW() v8::Object::New(v8::Isolate::GetCurrent()) -#define SWIGV8_EXTERNAL_NEW(val) v8::External::New(v8::Isolate::GetCurrent(), val) #define SWIGV8_UNDEFINED() v8::Undefined(v8::Isolate::GetCurrent()) #define SWIGV8_NULL() v8::Null(v8::Isolate::GetCurrent()) -#define SWIGV8_BOOLEAN_NEW(bool) v8::Boolean::New(v8::Isolate::GetCurrent(), bool) -#define SWIGV8_ARRAY_NEW() v8::Array::New(v8::Isolate::GetCurrent()) -#define SWIGV8_NUMBER_NEW(num) v8::Number::New(v8::Isolate::GetCurrent(), num) -#define SWIGV8_INTEGER_NEW(num) v8::Integer::New(v8::Isolate::GetCurrent(), num) -#define SWIGV8_INTEGER_NEW_UNS(num) v8::Integer::NewFromUnsigned(v8::Isolate::GetCurrent(), num) -#define SWIGV8_INT32_NEW(num) v8::Int32::New(v8::Isolate::GetCurrent(), num) #endif - /* --------------------------------------------------------------------------- * Error handling * @@ -92,7 +93,7 @@ typedef v8::PropertyCallbackInfo SwigV8PropertyCallbackInfo; #define SWIG_fail goto fail #define SWIGV8_OVERLOAD false -void SWIG_V8_Raise(const char* msg) { +void SWIG_V8_Raise(const char *msg) { SWIGV8_THROW_EXCEPTION(v8::Exception::Error(SWIGV8_STRING_NEW(msg))); } @@ -112,7 +113,7 @@ void SWIG_V8_Raise(const char* msg) { class V8ErrorHandler { public: virtual ~V8ErrorHandler() {} - virtual void error(int code, const char* msg) { + virtual void error(int code, const char *msg) { SWIG_V8_Raise(msg); } }; @@ -122,7 +123,7 @@ V8ErrorHandler SWIGV8_ErrorHandler; // instances of this are used in overloaded functions class OverloadErrorHandler: public V8ErrorHandler { public: - virtual void error(int code, const char* msg) { + virtual void error(int code, const char *msg) { err = v8::Exception::Error(SWIGV8_STRING_NEW(msg)); if(code != SWIG_TypeError) { SWIGV8_THROW_EXCEPTION(err); @@ -153,7 +154,7 @@ public: #elif (SWIG_V8_VERSION < 0x032100) handle.ClearWeak(v8::Isolate::GetCurrent()); handle.Dispose(v8::Isolate::GetCurrent()); -#elif (SWIG_V8_VERSION < SWIG_SETWEAK_VERSION) +#elif (SWIG_V8_VERSION < SWIGV8_SETWEAK_VERSION) handle.ClearWeak(); handle.Dispose(); #else @@ -161,7 +162,7 @@ public: handle.Reset(); #endif -#if (SWIG_V8_VERSION < SWIG_SETWEAK_VERSION) +#if (SWIG_V8_VERSION < SWIGV8_SETWEAK_VERSION) handle.Clear(); #endif @@ -182,7 +183,7 @@ public: void (*dtor) (v8::Persistent< v8::Value> object, void *parameter); #elif (SWIG_V8_VERSION < 0x031900) void (*dtor) (v8::Isolate *isolate, v8::Persistent< v8::Value> object, void *parameter); -#elif (SWIG_V8_VERSION < SWIG_SETWEAK_VERSION) +#elif (SWIG_V8_VERSION < SWIGV8_SETWEAK_VERSION) void (*dtor) (v8::Isolate *isolate, v8::Persistent< v8::Object > *object, SWIGV8_Proxy *proxy); #else void (*dtor) (const v8::WeakCallbackData &data); @@ -191,7 +192,7 @@ public: v8::Persistent SWIGV8_SWIGTYPE_Proxy_class_templ; -int SWIG_V8_ConvertInstancePtr(v8::Handle objRef, void** ptr, swig_type_info *info, int flags) { +int SWIG_V8_ConvertInstancePtr(v8::Handle objRef, void **ptr, swig_type_info *info, int flags) { SWIGV8_HANDLESCOPE(); if(objRef->InternalFieldCount() < 1) return SWIG_ERROR; @@ -230,7 +231,7 @@ void SWIGV8_Proxy_DefaultDtor(v8::Persistent< v8::Value > object, void *paramete #elif (SWIG_V8_VERSION < 0x031900) void SWIGV8_Proxy_DefaultDtor(v8::Isolate *, v8::Persistent< v8::Value > object, void *parameter) { SWIGV8_Proxy *proxy = static_cast(parameter); -#elif (SWIG_V8_VERSION < SWIG_SETWEAK_VERSION) +#elif (SWIG_V8_VERSION < SWIGV8_SETWEAK_VERSION) void SWIGV8_Proxy_DefaultDtor(v8::Isolate *, v8::Persistent< v8::Object > *object, SWIGV8_Proxy *proxy) { #else void SWIGV8_Proxy_DefaultDtor(const v8::WeakCallbackData &data) { @@ -240,7 +241,7 @@ void SWIGV8_Proxy_DefaultDtor(const v8::WeakCallbackData valRef, void** ptr) { +int SWIG_V8_GetInstancePtr(v8::Handle valRef, void **ptr) { if(!valRef->IsObject()) { return SWIG_TypeError; } @@ -264,8 +265,8 @@ int SWIG_V8_GetInstancePtr(v8::Handle valRef, void** ptr) { return SWIG_OK; } -void SWIGV8_SetPrivateData(v8::Handle obj, void* ptr, swig_type_info *info, int flags) { - SWIGV8_Proxy* cdata = new SWIGV8_Proxy(); +void SWIGV8_SetPrivateData(v8::Handle obj, void *ptr, swig_type_info *info, int flags) { + SWIGV8_Proxy *cdata = new SWIGV8_Proxy(); cdata->swigCObject = ptr; cdata->swigCMemOwn = (flags & SWIG_POINTER_OWN) ? 1 : 0; cdata->info = info; @@ -297,7 +298,7 @@ void SWIGV8_SetPrivateData(v8::Handle obj, void* ptr, swig_type_info } else { cdata->handle.MakeWeak(v8::Isolate::GetCurrent(), cdata, SWIGV8_Proxy_DefaultDtor); } -#elif (SWIG_V8_VERSION < SWIG_SETWEAK_VERSION) +#elif (SWIG_V8_VERSION < SWIGV8_SETWEAK_VERSION) if(cdata->swigCMemOwn && (SWIGV8_ClientData*)info->clientdata) { cdata->handle.MakeWeak(cdata, ((SWIGV8_ClientData*)info->clientdata)->dtor); } else { @@ -321,7 +322,7 @@ void SWIGV8_SetPrivateData(v8::Handle obj, void* ptr, swig_type_info } -int SWIG_V8_ConvertPtr(v8::Handle valRef, void** ptr, swig_type_info *info, int flags) { +int SWIG_V8_ConvertPtr(v8::Handle valRef, void **ptr, swig_type_info *info, int flags) { SWIGV8_HANDLESCOPE(); /* special case: JavaScript null => C NULL pointer */ @@ -448,7 +449,7 @@ public: ~SwigV8PackedData() { }; - void* data; + void *data; size_t size; swig_type_info *type; @@ -466,7 +467,7 @@ int SwigV8Packed_Check(v8::Handle valRef) { } SWIGRUNTIME -swig_type_info* SwigV8Packed_UnpackData(v8::Handle valRef, void *ptr, size_t size) { +swig_type_info *SwigV8Packed_UnpackData(v8::Handle valRef, void *ptr, size_t size) { if (SwigV8Packed_Check(valRef)) { SWIGV8_HANDLESCOPE(); @@ -506,10 +507,10 @@ int SWIGV8_ConvertPacked(v8::Handle valRef, void *ptr, size_t sz, swi void _wrap_SwigV8PackedData_delete(v8::Persistent< v8::Value > object, void *parameter) { SwigV8PackedData *cdata = static_cast(parameter); #elif (SWIG_V8_VERSION < 0x031900) -void _wrap_SwigV8PackedData_delete(v8::Isolate *isolate, v8::Persistent< v8::Value > object, void *parameter) { +void _wrap_SwigV8PackedData_delete(v8::Isolate *isolate, v8::Persistent object, void *parameter) { SwigV8PackedData *cdata = static_cast(parameter); -#elif (SWIG_V8_VERSION < SWIG_SETWEAK_VERSION) -void _wrap_SwigV8PackedData_delete(v8::Isolate *isolate, v8::Persistent< v8::Object > * object, SwigV8PackedData *cdata) { +#elif (SWIG_V8_VERSION < SWIGV8_SETWEAK_VERSION) +void _wrap_SwigV8PackedData_delete(v8::Isolate *isolate, v8::Persistent *object, SwigV8PackedData *cdata) { #else void _wrap_SwigV8PackedData_delete(const v8::WeakCallbackData &data) { v8::Local object = data.GetValue(); @@ -526,7 +527,7 @@ void _wrap_SwigV8PackedData_delete(const v8::WeakCallbackDataDispose(isolate); -#elif (SWIG_V8_VERSION < SWIG_SETWEAK_VERSION) +#elif (SWIG_V8_VERSION < SWIGV8_SETWEAK_VERSION) object->Dispose(); #else object.Clear(); @@ -537,7 +538,7 @@ SWIGRUNTIME v8::Handle SWIGV8_NewPackedObj(void *data, size_t size, swig_type_info *type) { SWIGV8_HANDLESCOPE_ESC(); - SwigV8PackedData* cdata = new SwigV8PackedData(data, size, type); + SwigV8PackedData *cdata = new SwigV8PackedData(data, size, type); // v8::Handle obj = SWIGV8_OBJECT_NEW(); v8::Local obj = SWIGV8_OBJECT_NEW(); @@ -562,7 +563,7 @@ v8::Handle SWIGV8_NewPackedObj(void *data, size_t size, swig_type_inf cdata->handle.MakeWeak(cdata, _wrap_SwigV8PackedData_delete); #elif (SWIG_V8_VERSION < 0x031918) cdata->handle.MakeWeak(v8::Isolate::GetCurrent(), cdata, _wrap_SwigV8PackedData_delete); -#elif (SWIG_V8_VERSION < SWIG_SETWEAK_VERSION) +#elif (SWIG_V8_VERSION < SWIGV8_SETWEAK_VERSION) cdata->handle.MakeWeak(cdata, _wrap_SwigV8PackedData_delete); #else cdata->handle.SetWeak(cdata, _wrap_SwigV8PackedData_delete); diff --git a/Tools/javascript/v8_shell.cxx b/Tools/javascript/v8_shell.cxx index 0255d7e7f..bc90c1f10 100644 --- a/Tools/javascript/v8_shell.cxx +++ b/Tools/javascript/v8_shell.cxx @@ -72,7 +72,7 @@ public: virtual ~V8Shell(); - virtual bool RunScript(const std::string& scriptPath); + virtual bool RunScript(const std::string &scriptPath); virtual bool RunShell(); @@ -81,27 +81,27 @@ protected: virtual bool InitializeEngine(); - virtual bool ExecuteScript(const std::string& source, const std::string& scriptPath); + virtual bool ExecuteScript(const std::string &source, const std::string &scriptPath); virtual bool DisposeEngine(); private: - v8::Handle Import(const std::string& moduleName); + v8::Handle Import(const std::string &moduleName); SwigV8Context CreateShellContext(); - void ReportException(v8::TryCatch* handler); + void ReportException(v8::TryCatch *handler); - static SwigV8ReturnValue Print(const SwigV8Arguments& args); + static SwigV8ReturnValue Print(const SwigV8Arguments &args); - static SwigV8ReturnValue Require(const SwigV8Arguments& args); + static SwigV8ReturnValue Require(const SwigV8Arguments &args); - static SwigV8ReturnValue Quit(const SwigV8Arguments& args); + static SwigV8ReturnValue Quit(const SwigV8Arguments &args); - static SwigV8ReturnValue Version(const SwigV8Arguments& args); + static SwigV8ReturnValue Version(const SwigV8Arguments &args); - static const char* ToCString(const v8::String::Utf8Value& value); + static const char* ToCString(const v8::String::Utf8Value &value); }; @@ -116,10 +116,10 @@ V8Shell::V8Shell() {} V8Shell::~V8Shell() {} -bool V8Shell::RunScript(const std::string& scriptPath) { +bool V8Shell::RunScript(const std::string &scriptPath) { std::string source = ReadFile(scriptPath); - v8::Isolate* isolate = v8::Isolate::New(); + v8::Isolate *isolate = v8::Isolate::New(); v8::Isolate::Scope isolate_scope(isolate); SWIGV8_HANDLESCOPE(); @@ -182,7 +182,7 @@ bool V8Shell::RunShell() { while (true) { char buffer[kBufferSize]; printf("> "); - char* str = fgets(buffer, kBufferSize, stdin); + char *str = fgets(buffer, kBufferSize, stdin); if (str == NULL) break; std::string source(str); ExecuteScript(source, "(shell)"); @@ -211,7 +211,7 @@ bool V8Shell::InitializeEngine() { return true; } -bool V8Shell::ExecuteScript(const std::string& source, const std::string& name) { +bool V8Shell::ExecuteScript(const std::string &source, const std::string &name) { SWIGV8_HANDLESCOPE(); v8::TryCatch try_catch; @@ -258,7 +258,7 @@ SwigV8Context V8Shell::CreateShellContext() { #endif } -v8::Handle V8Shell::Import(const std::string& module_path) +v8::Handle V8Shell::Import(const std::string &module_path) { SWIGV8_HANDLESCOPE_ESC(); @@ -281,7 +281,7 @@ v8::Handle V8Shell::Import(const std::string& module_path) SWIGV8_ESCAPE(module); } -SwigV8ReturnValue V8Shell::Print(const SwigV8Arguments& args) { +SwigV8ReturnValue V8Shell::Print(const SwigV8Arguments &args) { SWIGV8_HANDLESCOPE(); bool first = true; @@ -293,7 +293,7 @@ SwigV8ReturnValue V8Shell::Print(const SwigV8Arguments& args) { printf(" "); } v8::String::Utf8Value str(args[i]); - const char* cstr = V8Shell::ToCString(str); + const char *cstr = V8Shell::ToCString(str); printf("%s", cstr); } printf("\n"); @@ -302,7 +302,7 @@ SwigV8ReturnValue V8Shell::Print(const SwigV8Arguments& args) { SWIGV8_RETURN(SWIGV8_UNDEFINED()); } -SwigV8ReturnValue V8Shell::Require(const SwigV8Arguments& args) { +SwigV8ReturnValue V8Shell::Require(const SwigV8Arguments &args) { SWIGV8_HANDLESCOPE(); if (args.Length() != 1) { @@ -310,21 +310,21 @@ SwigV8ReturnValue V8Shell::Require(const SwigV8Arguments& args) { }; v8::String::Utf8Value str(args[0]); - const char* cstr = V8Shell::ToCString(str); + const char *cstr = V8Shell::ToCString(str); std::string moduleName(cstr); v8::Local global = SWIGV8_CURRENT_CONTEXT()->Global(); v8::Local hidden = global->GetHiddenValue(SWIGV8_STRING_NEW("__shell__")); v8::Local __shell__ = v8::Local::Cast(hidden); - V8Shell* _this = (V8Shell*) (long) __shell__->Value(); + V8Shell *_this = (V8Shell *) (long) __shell__->Value(); v8::Handle module = _this->Import(moduleName); SWIGV8_RETURN(module); } -SwigV8ReturnValue V8Shell::Quit(const SwigV8Arguments& args) { +SwigV8ReturnValue V8Shell::Quit(const SwigV8Arguments &args) { SWIGV8_HANDLESCOPE(); int exit_code = args[0]->Int32Value(); @@ -335,16 +335,16 @@ SwigV8ReturnValue V8Shell::Quit(const SwigV8Arguments& args) { SWIGV8_RETURN(SWIGV8_UNDEFINED()); } -SwigV8ReturnValue V8Shell::Version(const SwigV8Arguments& args) { +SwigV8ReturnValue V8Shell::Version(const SwigV8Arguments &args) { SWIGV8_HANDLESCOPE(); SWIGV8_RETURN(SWIGV8_STRING_NEW(v8::V8::GetVersion())); } -void V8Shell::ReportException(v8::TryCatch* try_catch) { +void V8Shell::ReportException(v8::TryCatch *try_catch) { SWIGV8_HANDLESCOPE(); v8::String::Utf8Value exception(try_catch->Exception()); - const char* exception_string = V8Shell::ToCString(exception); + const char *exception_string = V8Shell::ToCString(exception); v8::Handle message = try_catch->Message(); if (message.IsEmpty()) { // V8 didn't provide any extra information about this error; just @@ -353,12 +353,12 @@ void V8Shell::ReportException(v8::TryCatch* try_catch) { } else { // Print (filename):(line number): (message). v8::String::Utf8Value filename(message->GetScriptResourceName()); - const char* filename_string = V8Shell::ToCString(filename); + const char *filename_string = V8Shell::ToCString(filename); int linenum = message->GetLineNumber(); printf("%s:%i: %s\n", filename_string, linenum, exception_string); // Print line of source code. v8::String::Utf8Value sourceline(message->GetSourceLine()); - const char* sourceline_string = V8Shell::ToCString(sourceline); + const char *sourceline_string = V8Shell::ToCString(sourceline); printf("%s\n", sourceline_string); // Print wavy underline (GetUnderline is deprecated). int start = message->GetStartColumn(); @@ -372,17 +372,17 @@ void V8Shell::ReportException(v8::TryCatch* try_catch) { printf("\n"); v8::String::Utf8Value stack_trace(try_catch->StackTrace()); if (stack_trace.length() > 0) { - const char* stack_trace_string = V8Shell::ToCString(stack_trace); + const char *stack_trace_string = V8Shell::ToCString(stack_trace); printf("%s\n", stack_trace_string); } } } // Extracts a C string from a V8 Utf8Value. -const char* V8Shell::ToCString(const v8::String::Utf8Value& value) { +const char *V8Shell::ToCString(const v8::String::Utf8Value &value) { return *value ? *value : ""; } -JSShell* V8Shell_Create() { +JSShell *V8Shell_Create() { return new V8Shell(); } -- cgit v1.2.1 From cf139a90db852446269b0ce7b7ed5f2bf623eafb Mon Sep 17 00:00:00 2001 From: Alexey Pelykh Date: Fri, 29 Aug 2014 19:39:39 +0300 Subject: C++11 strongly-typed enums fix for Java only --- Source/Modules/java.cxx | 25 +++++++++++++++++++++++-- 1 file changed, 23 insertions(+), 2 deletions(-) diff --git a/Source/Modules/java.cxx b/Source/Modules/java.cxx index 9e16bb422..469dfbf53 100644 --- a/Source/Modules/java.cxx +++ b/Source/Modules/java.cxx @@ -837,8 +837,13 @@ public: String *nondir_args = NewString(""); bool is_destructor = (Cmp(Getattr(n, "nodeType"), "destructor") == 0); + // If enum is strongly-typed, generate fully-qualified symname + Node* parent = parentNode(n); + if (GetFlag(parent, "scopedenum")) + symname = Swig_name_member(0, Swig_scopename_last(Getattr(parent, "name")), symname); + if (!Getattr(n, "sym:overloaded")) { - if (!addSymbol(Getattr(n, "sym:name"), n, imclass_name)) + if (!addSymbol(symname, n, imclass_name)) return SWIG_ERROR; } @@ -1556,6 +1561,11 @@ public: } else if (!const_feature_flag) { // Default enum and constant handling will work with any type of C constant and initialises the Java variable from C through a JNI call. + // If enum is strongly-typed, generate fully-qualified symname + Node* parent = parentNode(n); + if (GetFlag(parent, "scopedenum")) + symname = Swig_name_member(0, Swig_scopename_last(Getattr(parent, "name")), symname); + if (classname_substituted_flag) { if (SwigType_isenum(t)) { // This handles wrapping of inline initialised const enum static member variables (not when wrapping enum items - ignored later on) @@ -2709,7 +2719,14 @@ public: * a Java long is used for all classes in the SWIG intermediary class. * The intermediary class methods are thus mangled when overloaded to give * a unique name. */ - String *overloaded_name = NewStringf("%s", Getattr(n, "sym:name")); + + // If enum is strongly-typed, generate fully-qualified symname + String* symname = Getattr(n, "sym:name"); + Node* parent = parentNode(n); + if (GetFlag(parent, "scopedenum")) + symname = Swig_name_member(0, Swig_scopename_last(Getattr(parent, "name")), symname); + + String *overloaded_name = NewStringf("%s", symname); if (Getattr(n, "sym:overloaded")) { Printv(overloaded_name, Getattr(n, "sym:overname"), NIL); @@ -2961,6 +2978,10 @@ public: } else { // Get the enumvalue from a JNI call if (!getCurrentClass() || !cparse_cplusplus || !proxy_flag) { + // If enum is strongly-typed, generate fully-qualified symname + Node* parent = parentNode(n); + if (GetFlag(parent, "scopedenum")) + symname = Swig_name_member(0, Swig_scopename_last(Getattr(parent, "name")), symname); // Strange hack to change the name Setattr(n, "name", Getattr(n, "value")); /* for wrapping of enums in a namespace when emit_action is used */ constantWrapper(n); -- cgit v1.2.1 From 199d29f11085e943e0f360f1080f7c59a85930fc Mon Sep 17 00:00:00 2001 From: Richard Date: Fri, 29 Aug 2014 12:20:40 -0500 Subject: Added missing tag --- Doc/Manual/Javascript.html | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Doc/Manual/Javascript.html b/Doc/Manual/Javascript.html index aaef6ab17..6aabdc754 100644 --- a/Doc/Manual/Javascript.html +++ b/Doc/Manual/Javascript.html @@ -92,7 +92,7 @@ $ swig -c++ -javascript -jsc example.i

      Specify the V8 version when running SWIG (e.g. 3.25.30)

      -$ swig -c++ -javascript -v8 -DV8_VERSION=0x032530 example.i
      +$ swig -c++ -javascript -v8 -DV8_VERSION=0x032530 example.i

      This creates a C/C++ source file example_wrap.c or example_wrap.cxx. The generated C source file contains the low-level wrappers that need to be compiled and linked with the rest of your C/C++ application to create an extension module.

      The name of the wrapper file is derived from the name of the input file. For example, if the input file is example.i, the name of the wrapper file is example_wrap.c. To change this, you can use the -o option. The wrapped module will export one function which must be called to register the module with the Javascript interpreter. For example, if your module is named example the corresponding initializer for JavascriptCore would be

      -- cgit v1.2.1 From 14c2cf3407605c3c0cae92b80f743358211991f3 Mon Sep 17 00:00:00 2001 From: Olly Betts Date: Fri, 29 Aug 2014 16:28:00 -0300 Subject: PHP: Fix memory leak if a director method is passed Null for self --- Source/Modules/php.cxx | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/Source/Modules/php.cxx b/Source/Modules/php.cxx index b07c82d3b..f7e9994f0 100644 --- a/Source/Modules/php.cxx +++ b/Source/Modules/php.cxx @@ -2622,12 +2622,12 @@ done: Printf(w->code, "zval *args[%d];\n", idx); } Printf(w->code, "zval *%s, funcname;\n", Swig_cresult_name()); - Printf(w->code, "MAKE_STD_ZVAL(%s);\n", Swig_cresult_name()); - const char * funcname = GetChar(n, "sym:name"); - Printf(w->code, "ZVAL_STRINGL(&funcname, (char *)\"%s\", %d, 0);\n", funcname, strlen(funcname)); Append(w->code, "if (!swig_self) {\n"); Append(w->code, " SWIG_PHP_Error(E_ERROR, \"this pointer is NULL\");"); Append(w->code, "}\n\n"); + Printf(w->code, "MAKE_STD_ZVAL(%s);\n", Swig_cresult_name()); + const char * funcname = GetChar(n, "sym:name"); + Printf(w->code, "ZVAL_STRINGL(&funcname, (char *)\"%s\", %d, 0);\n", funcname, strlen(funcname)); /* wrap complex arguments to zvals */ Printv(w->code, wrap_args, NIL); -- cgit v1.2.1 From d1b1925270e8b271983c81c89523259dbacdca67 Mon Sep 17 00:00:00 2001 From: Alexey Pelykh Date: Sat, 30 Aug 2014 09:08:04 +0300 Subject: Additional test cases for C++11 strongly-typed enums --- .../test-suite/cpp11_strongly_typed_enumerations.i | 39 ++++++++++++++++++++++ 1 file changed, 39 insertions(+) diff --git a/Examples/test-suite/cpp11_strongly_typed_enumerations.i b/Examples/test-suite/cpp11_strongly_typed_enumerations.i index ed466369e..451688736 100644 --- a/Examples/test-suite/cpp11_strongly_typed_enumerations.i +++ b/Examples/test-suite/cpp11_strongly_typed_enumerations.i @@ -73,6 +73,45 @@ struct UseEnum11 { Enum11 myenum11; }; +class Class1 +{ +public: + enum class Enum12 + { + Val1 = 300, + Val2 = 400, + Val3, + Val4 + }; + + enum Enum13 + { + Val1 = 300, + Val2 = 400, + Val3, + Val4 + }; + + struct Struct1 + { + enum class Enum14 + { + Val1 = 300, + Val2 = 400, + Val3, + Val4 + }; + + enum Enum15 + { + Val1 = 300, + Val2 = 400, + Val3, + Val4 + }; + }; +}; + /* TODO enum class MyClass {AAA, BBB, CCC}; -- cgit v1.2.1 From fd926cf284767dd83e4755b65d0dce364080d62a Mon Sep 17 00:00:00 2001 From: Alexey Pelykh Date: Sat, 30 Aug 2014 09:15:25 +0300 Subject: Revert "C++11 strongly-typed enums fix for Java only" This reverts commit cf139a90db852446269b0ce7b7ed5f2bf623eafb. --- Source/Modules/java.cxx | 25 ++----------------------- 1 file changed, 2 insertions(+), 23 deletions(-) diff --git a/Source/Modules/java.cxx b/Source/Modules/java.cxx index 469dfbf53..9e16bb422 100644 --- a/Source/Modules/java.cxx +++ b/Source/Modules/java.cxx @@ -837,13 +837,8 @@ public: String *nondir_args = NewString(""); bool is_destructor = (Cmp(Getattr(n, "nodeType"), "destructor") == 0); - // If enum is strongly-typed, generate fully-qualified symname - Node* parent = parentNode(n); - if (GetFlag(parent, "scopedenum")) - symname = Swig_name_member(0, Swig_scopename_last(Getattr(parent, "name")), symname); - if (!Getattr(n, "sym:overloaded")) { - if (!addSymbol(symname, n, imclass_name)) + if (!addSymbol(Getattr(n, "sym:name"), n, imclass_name)) return SWIG_ERROR; } @@ -1561,11 +1556,6 @@ public: } else if (!const_feature_flag) { // Default enum and constant handling will work with any type of C constant and initialises the Java variable from C through a JNI call. - // If enum is strongly-typed, generate fully-qualified symname - Node* parent = parentNode(n); - if (GetFlag(parent, "scopedenum")) - symname = Swig_name_member(0, Swig_scopename_last(Getattr(parent, "name")), symname); - if (classname_substituted_flag) { if (SwigType_isenum(t)) { // This handles wrapping of inline initialised const enum static member variables (not when wrapping enum items - ignored later on) @@ -2719,14 +2709,7 @@ public: * a Java long is used for all classes in the SWIG intermediary class. * The intermediary class methods are thus mangled when overloaded to give * a unique name. */ - - // If enum is strongly-typed, generate fully-qualified symname - String* symname = Getattr(n, "sym:name"); - Node* parent = parentNode(n); - if (GetFlag(parent, "scopedenum")) - symname = Swig_name_member(0, Swig_scopename_last(Getattr(parent, "name")), symname); - - String *overloaded_name = NewStringf("%s", symname); + String *overloaded_name = NewStringf("%s", Getattr(n, "sym:name")); if (Getattr(n, "sym:overloaded")) { Printv(overloaded_name, Getattr(n, "sym:overname"), NIL); @@ -2978,10 +2961,6 @@ public: } else { // Get the enumvalue from a JNI call if (!getCurrentClass() || !cparse_cplusplus || !proxy_flag) { - // If enum is strongly-typed, generate fully-qualified symname - Node* parent = parentNode(n); - if (GetFlag(parent, "scopedenum")) - symname = Swig_name_member(0, Swig_scopename_last(Getattr(parent, "name")), symname); // Strange hack to change the name Setattr(n, "name", Getattr(n, "value")); /* for wrapping of enums in a namespace when emit_action is used */ constantWrapper(n); -- cgit v1.2.1 From d318f03efe1980bbd9d899fc39bc1a7bfb604acb Mon Sep 17 00:00:00 2001 From: Alexey Pelykh Date: Sat, 30 Aug 2014 11:58:52 +0300 Subject: C++11 strongly-typed enums fix for Java only (proper) --- .../test-suite/cpp11_strongly_typed_enumerations.i | 115 +++++++++++++++++++++ Source/Modules/java.cxx | 50 ++++++++- Source/Modules/lang.cxx | 60 +++++++++++ 3 files changed, 223 insertions(+), 2 deletions(-) diff --git a/Examples/test-suite/cpp11_strongly_typed_enumerations.i b/Examples/test-suite/cpp11_strongly_typed_enumerations.i index 451688736..8846d6877 100644 --- a/Examples/test-suite/cpp11_strongly_typed_enumerations.i +++ b/Examples/test-suite/cpp11_strongly_typed_enumerations.i @@ -112,6 +112,121 @@ public: }; }; +class Class2 +{ +public: + enum class Enum12 + { + Val1 = 300, + Val2 = 400, + Val3, + Val4 + }; + + enum Enum13 + { + Val1 = 300, + Val2 = 400, + Val3, + Val4 + }; + + struct Struct1 + { + enum class Enum14 + { + Val1 = 300, + Val2 = 400, + Val3, + Val4 + }; + + enum Enum15 + { + Val1 = 300, + Val2 = 400, + Val3, + Val4 + }; + }; +}; + +/* +enum class Enum12 +{ + Val1 = 300, + Val2 = 400, + Val3, + Val4 +}; + +enum Enum13 +{ + Val1 = 300, + Val2 = 400, + Val3, + Val4 +}; +*/ + +namespace NS1 +{ + enum class Enum12 + { + Val1 = 300, + Val2 = 400, + Val3, + Val4 + }; + + enum Enum13 + { + Val1 = 300, + Val2 = 400, + Val3, + Val4 + }; + + class Class3 + { + public: + enum class Enum12 + { + Val1 = 300, + Val2 = 400, + Val3, + Val4 + }; + + enum Enum13 + { + Val1 = 300, + Val2 = 400, + Val3, + Val4 + }; + + struct Struct1 + { + enum class Enum14 + { + Val1 = 300, + Val2 = 400, + Val3, + Val4 + }; + + enum Enum15 + { + Val1 = 300, + Val2 = 400, + Val3, + Val4 + }; + }; + }; +} + /* TODO enum class MyClass {AAA, BBB, CCC}; diff --git a/Source/Modules/java.cxx b/Source/Modules/java.cxx index 9e16bb422..411f7ad31 100644 --- a/Source/Modules/java.cxx +++ b/Source/Modules/java.cxx @@ -838,7 +838,7 @@ public: bool is_destructor = (Cmp(Getattr(n, "nodeType"), "destructor") == 0); if (!Getattr(n, "sym:overloaded")) { - if (!addSymbol(Getattr(n, "sym:name"), n, imclass_name)) + if (!addSymbol(symname, n, imclass_name)) return SWIG_ERROR; } @@ -1556,6 +1556,22 @@ public: } else if (!const_feature_flag) { // Default enum and constant handling will work with any type of C constant and initialises the Java variable from C through a JNI call. + String* pureSymname = NULL; + if (Equal(Getattr(n, "nodeType"), "enumitem")) { + // If enum is strongly-typed, generate fully-qualified symname + Node* parent = parentNode(n); + String* pureSymname = NULL; + if (GetFlag(parent, "scopedenum") && !GetFlag(n, "symname_has_enumscope")) { + pureSymname = symname; + + String* enumClassName = Swig_scopename_last(Getattr(parent, "name")); + symname = Swig_name_member(0, enumClassName, pureSymname); + Delete(enumClassName); + + /* Printf(stdout, "Renamed strong enum value symname (java:1) '%s' -> '%s'\n", pureSymname, symname); */ + } + } + if (classname_substituted_flag) { if (SwigType_isenum(t)) { // This handles wrapping of inline initialised const enum static member variables (not when wrapping enum items - ignored later on) @@ -1568,6 +1584,13 @@ public: Printf(constants_code, "%s.%s();\n", full_imclass_name ? full_imclass_name : imclass_name, Swig_name_get(getNSpace(), symname)); } + // Delete temporary symname if it was created + if (pureSymname) { + Delete(symname); + symname = pureSymname; + pureSymname = NULL; + } + // Each constant and enum value is wrapped with a separate JNI function call SetFlag(n, "feature:immutable"); enum_constant_flag = true; @@ -2959,6 +2982,19 @@ public: // Use the C syntax to make a true Java constant and hope that it compiles as Java code value = Getattr(n, "enumvalue") ? Copy(Getattr(n, "enumvalue")) : Copy(Getattr(n, "enumvalueex")); } else { + // If enum is strongly-typed, generate fully-qualified symname + Node* parent = parentNode(n); + String* pureSymname = NULL; + if (GetFlag(parent, "scopedenum") && !GetFlag(n, "symname_has_enumscope")) { + pureSymname = symname; + + String* enumClassName = Swig_scopename_last(Getattr(parent, "name")); + symname = Swig_name_member(0, enumClassName, pureSymname); + Delete(enumClassName); + + /* Printf(stdout, "Renamed strong enum value symname (java:2) '%s' -> '%s'\n", pureSymname, symname); */ + } + // Get the enumvalue from a JNI call if (!getCurrentClass() || !cparse_cplusplus || !proxy_flag) { // Strange hack to change the name @@ -2967,7 +3003,17 @@ public: value = NewStringf("%s.%s()", full_imclass_name ? full_imclass_name : imclass_name, Swig_name_get(getNSpace(), symname)); } else { memberconstantHandler(n); - value = NewStringf("%s.%s()", full_imclass_name ? full_imclass_name : imclass_name, Swig_name_get(getNSpace(), Swig_name_member(0, proxy_class_name, symname))); + String* full_proxy_class_sym_name = NewString(full_proxy_class_name); + Replaceall(full_proxy_class_sym_name, ".", "_"); + value = NewStringf("%s.%s()", full_imclass_name ? full_imclass_name : imclass_name, Swig_name_get(getNSpace(), Swig_name_member(0, full_proxy_class_sym_name, symname))); + Delete(full_proxy_class_sym_name); + } + + // Delete temporary symname if it was created + if (pureSymname) { + Delete(symname); + symname = pureSymname; + pureSymname = NULL; } } } diff --git a/Source/Modules/lang.cxx b/Source/Modules/lang.cxx index 5ea79f0ab..04eec8af3 100644 --- a/Source/Modules/lang.cxx +++ b/Source/Modules/lang.cxx @@ -1721,6 +1721,24 @@ int Language::memberconstantHandler(Node *n) { String *value = Getattr(n, "value"); String *mrename = Swig_name_member(0, ClassPrefix, symname); + if (Equal(Getattr(n, "nodeType"), "enumitem")) { + // If enum is strongly-typed, generate fully-qualified symname + Node* parent = parentNode(n); + if (GetFlag(parent, "scopedenum") && !GetFlag(n, "symname_has_enumscope")) + { + SetFlag(n, "symname_has_enumscope"); + Delete(mrename); + + String* enumClassName = Swig_scopename_last(Getattr(parent, "name")); + String* scopedItemName = Swig_name_member(0, enumClassName, symname); + mrename = Swig_name_member(0, ClassPrefix, scopedItemName); + + /* Printf(stdout, "Renamed strong enum value symname (lang:1) '%s' -> '%s'\n", symname, mrename); */ + + Delete(enumClassName); + Delete(scopedItemName); + } + } Setattr(n, "sym:name", mrename); String *new_name = 0; @@ -1728,6 +1746,24 @@ int Language::memberconstantHandler(Node *n) { new_name = Copy(value); else new_name = NewStringf("%s::%s", isNonVirtualProtectedAccess(n) ? DirectorClassName : ClassName, name); + if (Equal(Getattr(n, "nodeType"), "enumitem")) { + // If enum is strongly-typed, generate fully-qualified symname + Node* parent = parentNode(n); + if (GetFlag(parent, "scopedenum") && !GetFlag(n, "name_has_enumscope")) + { + SetFlag(n, "name_has_enumscope"); + Delete(new_name); + + String* enumClassName = Swig_scopename_last(Getattr(parent, "name")); + String* scopedItemName = NewStringf("%s::%s", enumClassName, name); + new_name = NewStringf("%s::%s", isNonVirtualProtectedAccess(n) ? DirectorClassName : ClassName, scopedItemName); + + /* Printf(stdout, "Renamed strong enum value name (lang:1) '%s' -> '%s'\n", name, new_name); */ + + Delete(enumClassName); + Delete(scopedItemName); + } + } Setattr(n, "name", new_name); constantWrapper(n); @@ -2962,6 +2998,22 @@ int Language::variableWrapper(Node *n) { Delattr(n,"varset"); Delattr(n,"varget"); + String* pureSymname = NULL; + if (Equal(Getattr(n, "nodeType"), "enumitem")) { + // If enum is strongly-typed, generate fully-qualified symname + Node* parent = parentNode(n); + if (GetFlag(parent, "scopedenum") && !GetFlag(n, "symname_has_enumscope")) + { + pureSymname = symname; + + String* enumClassName = Swig_scopename_last(Getattr(parent, "name")); + symname = Swig_name_member(0, enumClassName, pureSymname); + Delete(enumClassName); + + /* Printf(stdout, "Renamed strong enum value symname (lang:2) '%s' -> '%s'\n", pureSymname, symname); */ + } + } + /* If no way to set variables. We simply create functions */ int assignable = is_assignable(n); int flags = use_naturalvar_mode(n); @@ -3019,6 +3071,14 @@ int Language::variableWrapper(Node *n) { functionWrapper(n); Delattr(n, "varget"); Swig_restore(n); + + // Delete temporary symname if it was created + if (pureSymname) { + Delete(symname); + symname = pureSymname; + pureSymname = NULL; + } + return SWIG_OK; } -- cgit v1.2.1 From abb888cfdde9a9a3efc9430ae8dc3a8164c42c2f Mon Sep 17 00:00:00 2001 From: Alexey Pelykh Date: Sun, 31 Aug 2014 12:14:29 +0300 Subject: Clean-up test suite and fix issue with nspace, as well as keep the fix for Class::Struct::EnumClass being JNI-referenced as Struct_EnumClass --- .../test-suite/cpp11_strongly_typed_enumerations.i | 76 ---------------------- Source/Modules/java.cxx | 13 +++- 2 files changed, 12 insertions(+), 77 deletions(-) diff --git a/Examples/test-suite/cpp11_strongly_typed_enumerations.i b/Examples/test-suite/cpp11_strongly_typed_enumerations.i index 8846d6877..feb7399a1 100644 --- a/Examples/test-suite/cpp11_strongly_typed_enumerations.i +++ b/Examples/test-suite/cpp11_strongly_typed_enumerations.i @@ -151,82 +151,6 @@ public: }; }; -/* -enum class Enum12 -{ - Val1 = 300, - Val2 = 400, - Val3, - Val4 -}; - -enum Enum13 -{ - Val1 = 300, - Val2 = 400, - Val3, - Val4 -}; -*/ - -namespace NS1 -{ - enum class Enum12 - { - Val1 = 300, - Val2 = 400, - Val3, - Val4 - }; - - enum Enum13 - { - Val1 = 300, - Val2 = 400, - Val3, - Val4 - }; - - class Class3 - { - public: - enum class Enum12 - { - Val1 = 300, - Val2 = 400, - Val3, - Val4 - }; - - enum Enum13 - { - Val1 = 300, - Val2 = 400, - Val3, - Val4 - }; - - struct Struct1 - { - enum class Enum14 - { - Val1 = 300, - Val2 = 400, - Val3, - Val4 - }; - - enum Enum15 - { - Val1 = 300, - Val2 = 400, - Val3, - Val4 - }; - }; - }; -} - /* TODO enum class MyClass {AAA, BBB, CCC}; diff --git a/Source/Modules/java.cxx b/Source/Modules/java.cxx index 411f7ad31..1fbc9dee2 100644 --- a/Source/Modules/java.cxx +++ b/Source/Modules/java.cxx @@ -3003,10 +3003,21 @@ public: value = NewStringf("%s.%s()", full_imclass_name ? full_imclass_name : imclass_name, Swig_name_get(getNSpace(), symname)); } else { memberconstantHandler(n); - String* full_proxy_class_sym_name = NewString(full_proxy_class_name); + String* outerClassesPrefix = NULL; + if (Node *outer = Getattr(getCurrentClass(), "nested:outer")) { + outerClassesPrefix = Copy(Getattr(outer, "sym:name")); + for (outer = Getattr(outer, "nested:outer"); outer != 0; outer = Getattr(outer, "nested:outer")) { + Push(outerClassesPrefix, "."); + Push(outerClassesPrefix, Getattr(outer, "sym:name")); + } + } + String* full_proxy_class_sym_name = outerClassesPrefix ? NewStringf("%s.%s", outerClassesPrefix, proxy_class_name) : NewStringf("%s", proxy_class_name); Replaceall(full_proxy_class_sym_name, ".", "_"); + /* Printf(stdout, "Change proxy class symname '%s' -> '%s'\n", proxy_class_name, full_proxy_class_sym_name); */ value = NewStringf("%s.%s()", full_imclass_name ? full_imclass_name : imclass_name, Swig_name_get(getNSpace(), Swig_name_member(0, full_proxy_class_sym_name, symname))); Delete(full_proxy_class_sym_name); + if (outerClassesPrefix) + Delete(outerClassesPrefix); } // Delete temporary symname if it was created -- cgit v1.2.1 From 7b9027db89c3ce84bf7c349bcded3e7b701236ed Mon Sep 17 00:00:00 2001 From: Alexey Pelykh Date: Sun, 31 Aug 2014 19:26:31 +0300 Subject: Java: fix invalid director 'self' variable type name (wasn't fully qualified) --- Source/Modules/java.cxx | 12 +++++++++++- 1 file changed, 11 insertions(+), 1 deletion(-) diff --git a/Source/Modules/java.cxx b/Source/Modules/java.cxx index 1fbc9dee2..f3fe7c380 100644 --- a/Source/Modules/java.cxx +++ b/Source/Modules/java.cxx @@ -3761,9 +3761,19 @@ public: String *imcall_args = NewString(""); int classmeth_off = curr_class_dmethod - first_class_dmethod; bool ignored_method = GetFlag(n, "feature:ignore") ? true : false; - String *qualified_classname = Copy(classname); String *nspace = getNSpace(); + String *outerClassesPrefix = 0; + if (Node *outer = Getattr(parent, "nested:outer")) { + outerClassesPrefix = Copy(Getattr(outer, "sym:name")); + for (outer = Getattr(outer, "nested:outer"); outer != 0; outer = Getattr(outer, "nested:outer")) { + Push(outerClassesPrefix, "."); + Push(outerClassesPrefix, Getattr(outer, "sym:name")); + } + } + String* qualified_classname = outerClassesPrefix ? NewStringf("%s.%s", outerClassesPrefix, classname) : NewStringf("%s", classname); + /* Printf(stdout, "Director qualified_classname '%s' instead of '%s'\n", qualified_classname, classname); */ + if (nspace && package) Insert(qualified_classname, 0, NewStringf("%s.%s.", package, nspace)); else if(nspace) -- cgit v1.2.1 From 255c929c5636f54c16261bd92b8eea2005d61b11 Mon Sep 17 00:00:00 2001 From: Olly Betts Date: Mon, 1 Sep 2014 00:26:15 -0300 Subject: Issue an error for unknown SWIG preprocessor directives, rather than quietly ignoring them. Reported by jrhelsey in issue#217. --- CHANGES.current | 4 ++++ Source/Preprocessor/cpp.c | 2 ++ 2 files changed, 6 insertions(+) diff --git a/CHANGES.current b/CHANGES.current index 6ce431b60..cf57d393e 100644 --- a/CHANGES.current +++ b/CHANGES.current @@ -5,6 +5,10 @@ See the RELEASENOTES file for a summary of changes in each release. Version 3.0.3 (in progress) =========================== +2014-09-01: olly + Issue an error for unknown SWIG preprocessor directives, rather + than quietly ignoring them. Reported by jrhelsey in issue#217. + 2014-08-15: talby [Perl] Include guard fix for nested modules from Anthony Heading (SF Patch #350). diff --git a/Source/Preprocessor/cpp.c b/Source/Preprocessor/cpp.c index baadf7132..1ca549703 100644 --- a/Source/Preprocessor/cpp.c +++ b/Source/Preprocessor/cpp.c @@ -1768,6 +1768,8 @@ String *Preprocessor_parse(String *s) { } } else if (Equal(id, kpp_level)) { Swig_error(Getfile(s), Getline(id), "cpp debug: level = %d, startlevel = %d\n", level, start_level); + } else { + Swig_error(Getfile(s), Getline(id), "Unknown SWIG preprocessor directive: %s\n", id); } for (i = 0; i < cpp_lines; i++) Putc('\n', ns); -- cgit v1.2.1 From f3a6c55929707624a473e2d31561d8d32bcde5bd Mon Sep 17 00:00:00 2001 From: Olly Betts Date: Tue, 2 Sep 2014 02:34:01 -0300 Subject: [Python] Fix regression in indentation of python code produced with -modern, introduced by changes in #188. Reported by fabiencastan in #218. --- CHANGES.current | 5 +++++ Source/Modules/python.cxx | 22 ++++++++++++---------- 2 files changed, 17 insertions(+), 10 deletions(-) diff --git a/CHANGES.current b/CHANGES.current index cf57d393e..c1b124d83 100644 --- a/CHANGES.current +++ b/CHANGES.current @@ -5,6 +5,11 @@ See the RELEASENOTES file for a summary of changes in each release. Version 3.0.3 (in progress) =========================== +2014-09-02: olly + [Python] Fix regression in indentation of python code produced with + -modern, introduced by changes in #188. Reported by fabiencastan + in #218. + 2014-09-01: olly Issue an error for unknown SWIG preprocessor directives, rather than quietly ignoring them. Reported by jrhelsey in issue#217. diff --git a/Source/Modules/python.cxx b/Source/Modules/python.cxx index c327dbc1c..9b92de4b6 100644 --- a/Source/Modules/python.cxx +++ b/Source/Modules/python.cxx @@ -4572,11 +4572,12 @@ public: Printv(f_shadow, tab4, "__swig_getmethods__[\"", symname, "\"] = ", module, ".", getname, "\n", NIL); } if (!classic) { - if (!assignable) { - Printv(f_shadow, tab4, modern ? "" : "if _newclass:\n", tab8, symname, " = _swig_property(", module, ".", getname, ")\n", NIL); - } else { - Printv(f_shadow, tab4, modern ? "" : "if _newclass:\n", tab8, symname, " = _swig_property(", module, ".", getname, ", ", module, ".", setname, ")\n", NIL); - } + if (!modern) + Printv(f_shadow, tab4, "if _newclass:\n", tab4, NIL); + Printv(f_shadow, tab4, symname, " = _swig_property(", module, ".", getname, NIL); + if (assignable) + Printv(f_shadow, ", ", module, ".", setname, NIL); + Printv(f_shadow, ")\n", NIL); } Delete(mname); Delete(setname); @@ -4645,11 +4646,12 @@ public: Printv(f_shadow, tab4, "__swig_getmethods__[\"", symname, "\"] = ", module, ".", getname, "\n", NIL); } if (!classic && !builtin) { - if (!assignable) { - Printv(f_shadow, tab4, modern ? "" : "if _newclass:\n", tab8, symname, " = _swig_property(", module, ".", getname, ")\n", NIL); - } else { - Printv(f_shadow, tab4, modern ? "" : "if _newclass:\n", tab8, symname, " = _swig_property(", module, ".", getname, ", ", module, ".", setname, ")\n", NIL); - } + if (!modern) + Printv(f_shadow, tab4, "if _newclass:\n", tab4, NIL); + Printv(f_shadow, tab4, symname, " = _swig_property(", module, ".", getname, NIL); + if (assignable) + Printv(f_shadow, ", ", module, ".", setname, NIL); + Printv(f_shadow, ")\n", NIL); } String *getter = Getattr(n, "pybuiltin:getter"); String *setter = Getattr(n, "pybuiltin:setter"); -- cgit v1.2.1 From 926fd75878dd86398af5dca4f21a9d9d6d966909 Mon Sep 17 00:00:00 2001 From: Olly Betts Date: Tue, 2 Sep 2014 23:12:09 -0300 Subject: Additional fixes for #218. --- Source/Modules/python.cxx | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/Source/Modules/python.cxx b/Source/Modules/python.cxx index 9b92de4b6..743db9c68 100644 --- a/Source/Modules/python.cxx +++ b/Source/Modules/python.cxx @@ -4325,7 +4325,9 @@ public: } else { Printv(f_shadow, tab8, "return ", funcCall(Swig_name_member(NSPACE_TODO, class_name, symname), callParms), "\n\n", NIL); } - Printv(f_shadow, tab4, modern ? "" : "if _newclass:\n", tab8, symname, " = staticmethod(", symname, ")\n", NIL); + if (!modern) + Printv(f_shadow, tab4, "if _newclass:\n", tab4, NIL); + Printv(f_shadow, tab4, symname, " = staticmethod(", symname, ")\n", NIL); if (!modern) { Printv(f_shadow, tab4, "__swig_getmethods__[\"", symname, "\"] = lambda x: ", symname, "\n", NIL); @@ -4337,7 +4339,9 @@ public: NIL); } if (!classic) { - Printv(f_shadow, tab4, modern ? "" : "if _newclass:\n", tab8, symname, " = staticmethod(", module, ".", Swig_name_member(NSPACE_TODO, class_name, symname), + if (!modern) + Printv(f_shadow, tab4, "if _newclass:\n", tab4, NIL); + Printv(f_shadow, tab4, symname, " = staticmethod(", module, ".", Swig_name_member(NSPACE_TODO, class_name, symname), ")\n", NIL); } } -- cgit v1.2.1 From d3b3ff2c7803c3c4381d864df9818c625713345a Mon Sep 17 00:00:00 2001 From: Olly Betts Date: Tue, 2 Sep 2014 23:12:35 -0300 Subject: Fix comment typo --- Examples/test-suite/python_nondynamic.i | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Examples/test-suite/python_nondynamic.i b/Examples/test-suite/python_nondynamic.i index 26c69644d..54a3f28ca 100644 --- a/Examples/test-suite/python_nondynamic.i +++ b/Examples/test-suite/python_nondynamic.i @@ -1,7 +1,7 @@ %module python_nondynamic /* - Use the %pythonnondynamic directuve to make the wrapped class a + Use the %pythonnondynamic directive to make the wrapped class a nondynamic one, ie, a python class that doesn't dynamically add new attributes. Hence, for the class -- cgit v1.2.1 From e7db081d5e175024f1d5baa9ac028474958a2542 Mon Sep 17 00:00:00 2001 From: Alexey Pelykh Date: Wed, 3 Sep 2014 09:37:25 +0300 Subject: Java: fix generation of ProxyName when JNI descriptor is requested - for inner classes '$' should be used as separator instead of '/' --- Source/Modules/java.cxx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Source/Modules/java.cxx b/Source/Modules/java.cxx index f3fe7c380..2e00a05d7 100644 --- a/Source/Modules/java.cxx +++ b/Source/Modules/java.cxx @@ -209,7 +209,7 @@ public: String *symname = Copy(Getattr(n, "sym:name")); if (symname && !GetFlag(n, "feature:flatnested")) { for (Node *outer_class = Getattr(n, "nested:outer"); outer_class; outer_class = Getattr(outer_class, "nested:outer")) { - Push(symname, "."); + Push(symname, jnidescriptor ? "$" : "."); Push(symname, Getattr(outer_class, "sym:name")); } } -- cgit v1.2.1 From b9fe7b5f005aae4ad1a6e625e54c1ae46ca3cdba Mon Sep 17 00:00:00 2001 From: Olly Betts Date: Wed, 3 Sep 2014 17:18:11 -0300 Subject: Disable case in pp_constant.i which never actually worked --- Examples/test-suite/errors/pp_constant.i | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/Examples/test-suite/errors/pp_constant.i b/Examples/test-suite/errors/pp_constant.i index 2be108e83..c29f4c86d 100644 --- a/Examples/test-suite/errors/pp_constant.i +++ b/Examples/test-suite/errors/pp_constant.i @@ -29,7 +29,9 @@ comment */ %constant int ddd=; #define E1 1234 -#/*C comment*/define E2 1234 +// This case doesn't actually work, but appeared to before we gave an error +// for unknown preprocessor directives. +// #/*C comment*/define E2 1234 #define E3 1234 %constant int eee=; -- cgit v1.2.1 From 8a69da7d826961a666ad54b5d6815c27e8daf775 Mon Sep 17 00:00:00 2001 From: Alexey Pelykh Date: Thu, 4 Sep 2014 12:05:23 +0300 Subject: Java/Fix: swig_connect_director used not-fully-qualified classname --- Source/Modules/java.cxx | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/Source/Modules/java.cxx b/Source/Modules/java.cxx index 2e00a05d7..7a660e85b 100644 --- a/Source/Modules/java.cxx +++ b/Source/Modules/java.cxx @@ -4548,6 +4548,14 @@ public: Wrapper *w = NewWrapper(); + // Form full classname including outer classes + if (classname && !GetFlag(n, "feature:flatnested")) { + for (Node *outer_class = Getattr(n, "nested:outer"); outer_class; outer_class = Getattr(outer_class, "nested:outer")) { + Push(classname, "$"); + Push(classname, Getattr(outer_class, "sym:name")); + } + } + if (Len(package_path) > 0 && Len(getNSpace()) > 0) internal_classname = NewStringf("%s/%s/%s", package_path, getNSpace(), classname); else if (Len(package_path) > 0) -- cgit v1.2.1 From afbb47dc8f19c7867253356ba7df5bd1c6828889 Mon Sep 17 00:00:00 2001 From: Alexey Pelykh Date: Thu, 4 Sep 2014 12:22:56 +0300 Subject: Java/Fix: swig_connect_director used not-fully-qualified classname (proper) --- Source/Modules/java.cxx | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/Source/Modules/java.cxx b/Source/Modules/java.cxx index 7a660e85b..e67b03290 100644 --- a/Source/Modules/java.cxx +++ b/Source/Modules/java.cxx @@ -4542,7 +4542,7 @@ public: * ------------------------------------------------------------ */ int classDirectorEnd(Node *n) { - String *classname = Getattr(n, "sym:name"); + String *classname = Copy(Getattr(n, "sym:name")); String *director_classname = directorClassName(n); String *internal_classname; @@ -4564,6 +4564,7 @@ public: internal_classname = NewStringf("%s/%s", getNSpace(), classname); else internal_classname = NewStringf("%s", classname); + Delete(classname); // If the namespace is multiple levels, the result of getNSpace() will have inserted // .'s to delimit namespaces, so we need to replace those with /'s -- cgit v1.2.1 From 6eaec9ce7c907b17be233b11bff0aa6ada40cb7c Mon Sep 17 00:00:00 2001 From: Olly Betts Date: Thu, 4 Sep 2014 09:29:20 -0300 Subject: Update expected output for pp_constant error test --- Examples/test-suite/errors/pp_constant.stderr | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/Examples/test-suite/errors/pp_constant.stderr b/Examples/test-suite/errors/pp_constant.stderr index 9c79ec2be..54a87edfe 100644 --- a/Examples/test-suite/errors/pp_constant.stderr +++ b/Examples/test-suite/errors/pp_constant.stderr @@ -2,7 +2,7 @@ pp_constant.i:9: Warning 305: Bad constant value (ignored). pp_constant.i:15: Warning 305: Bad constant value (ignored). pp_constant.i:23: Warning 305: Bad constant value (ignored). pp_constant.i:29: Warning 305: Bad constant value (ignored). -pp_constant.i:35: Warning 305: Bad constant value (ignored). -pp_constant.i:42: Warning 305: Bad constant value (ignored). -pp_constant.i:46: Warning 305: Bad constant value (ignored). -pp_constant.i:49: Warning 305: Bad constant value (ignored). +pp_constant.i:37: Warning 305: Bad constant value (ignored). +pp_constant.i:44: Warning 305: Bad constant value (ignored). +pp_constant.i:48: Warning 305: Bad constant value (ignored). +pp_constant.i:51: Warning 305: Bad constant value (ignored). -- cgit v1.2.1 From 1addbb46a84f8981a56aff191fb3d9a7e027823d Mon Sep 17 00:00:00 2001 From: Ian Lance Taylor Date: Fri, 5 Sep 2014 17:54:19 -0700 Subject: [Go] Add imtype, goin, goout, godirectorin, and godirectorout typemaps, to support writing Go code to convert between types. --- CHANGES.current | 5 + Doc/Manual/Contents.html | 1 + Doc/Manual/Go.html | 119 ++++++ Examples/test-suite/go/Makefile.in | 4 + Examples/test-suite/go/go_director_inout_runme.go | 32 ++ Examples/test-suite/go/go_inout_runme.go | 35 ++ Examples/test-suite/go_director_inout.i | 121 ++++++ Examples/test-suite/go_inout.i | 79 ++++ Source/Modules/go.cxx | 441 +++++++++++++++++----- 9 files changed, 740 insertions(+), 97 deletions(-) create mode 100644 Examples/test-suite/go/go_director_inout_runme.go create mode 100644 Examples/test-suite/go/go_inout_runme.go create mode 100644 Examples/test-suite/go_director_inout.i create mode 100644 Examples/test-suite/go_inout.i diff --git a/CHANGES.current b/CHANGES.current index c1b124d83..09a71f7f9 100644 --- a/CHANGES.current +++ b/CHANGES.current @@ -5,6 +5,11 @@ See the RELEASENOTES file for a summary of changes in each release. Version 3.0.3 (in progress) =========================== +2014-09-05: ianlancetaylor + [Go] Add imtype, goin, goout, godirectorin, and + godirectorout typemaps, to support writing Go code to + convert between types. + 2014-09-02: olly [Python] Fix regression in indentation of python code produced with -modern, introduced by changes in #188. Reported by fabiencastan diff --git a/Doc/Manual/Contents.html b/Doc/Manual/Contents.html index 4dd454352..0eba7c250 100644 --- a/Doc/Manual/Contents.html +++ b/Doc/Manual/Contents.html @@ -861,6 +861,7 @@
    • Default Go primitive type mappings
    • Output arguments
    • Adding additional go code +
    • Go typemaps
    diff --git a/Doc/Manual/Go.html b/Doc/Manual/Go.html index 93b87a4a4..e991fa3bd 100644 --- a/Doc/Manual/Go.html +++ b/Doc/Manual/Go.html @@ -30,6 +30,7 @@
  • Default Go primitive type mappings
  • Output arguments
  • Adding additional go code +
  • Go typemaps @@ -692,5 +693,123 @@ func bar() { +

    23.3.11 Go typemaps

    + + +

    +You can use the %typemap directive to modify SWIG's default +wrapping behavior for specific C/C++ types. You need to be familiar +with the material in the general +"Typemaps" chapter. That chapter +explains how to define a typemap. This section describes some +specific typemaps used for Go. +

    + +

    +In general type conversion code may be written either in C/C++ or in +Go. The choice to make normally depends on where memory should be +allocated. To allocate memory controlled by the Go garbage collector, +write Go code. To allocate memory in the C/C++ heap, write C code. +

    + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
    TypemapDescription
    gotype +The Go type to use for a C++ type. This type will appear in the +generated Go wrapper function. If this is not defined SWIG will use a +default as described above. +
    imtype +An intermediate Go type used by the "goin", "goout", "godirectorin", +and "godirectorout" typemaps. If this typemap is not defined for a +C/C++ type, the gotype typemape will be used. This is useful when +gotype is best converted to C/C++ using Go code. +
    goin +Go code to convert from gotype to imtype when calling a C/C++ +function. SWIG will then internally convert imtype to a C/C++ type +and pass it down. If this is not defined no conversion is done. +
    in +C/C++ code to convert the internally generated C/C++ type, based on +imtype, into the C/C++ type that a function call expects. If this is +not defined the value will simply be cast to the desired type. +
    out +C/C++ code to convert the C/C++ type that a function call returns into +the internally generated C/C++ type, based on imtype, that will be +returned to Go. If this is not defined the value will simply be cast +to the desired type. +
    goout +Go code to convert a value returned from a C/C++ function from imtype +to gotype. If this is not defined no conversion is done. +
    directorin +C/C++ code to convert the C/C++ type used to call a director method +into the internally generated C/C++ type, based on imtype, that will +be passed to Go. If this is not defined the value will simply be cast +to the desired type. +
    godirectorin +Go code to convert a value used to call a director method from imtype +to gotype. If this is not defined no conversion is done. +
    godirectorout +Go code to convert a value returned from a director method from gotype +to imtype. If this is not defined no conversion is done. +
    directorout +C/C++ code to convert a value returned from a director method from the +internally generated C/C++ type, based on imtype, into the type that +the method should return If this is not defined the value will simply +be cast to the desired type. +
    + diff --git a/Examples/test-suite/go/Makefile.in b/Examples/test-suite/go/Makefile.in index 5d8343be1..4480ecf1f 100644 --- a/Examples/test-suite/go/Makefile.in +++ b/Examples/test-suite/go/Makefile.in @@ -24,6 +24,10 @@ srcdir = @srcdir@ top_srcdir = @top_srcdir@ top_builddir = @top_builddir@ +CPP_TEST_CASES = \ + go_inout \ + go_director_inout + include $(srcdir)/../common.mk .SUFFIXES: .cpptest .ctest .multicpptest diff --git a/Examples/test-suite/go/go_director_inout_runme.go b/Examples/test-suite/go/go_director_inout_runme.go new file mode 100644 index 000000000..9b9df318e --- /dev/null +++ b/Examples/test-suite/go/go_director_inout_runme.go @@ -0,0 +1,32 @@ +package main + +import ( + wrap "./go_director_inout" +) + +type GoMyClass struct {} + +func (p *GoMyClass) Adjust(m map[string]interface{}) wrap.GoRetStruct { + s := "" + for k, v := range m { + s += k + "," + v.(string) + ";" + } + return wrap.GoRetStruct{s} +} + +func main() { + a := wrap.NewDirectorMyClass(&GoMyClass{}) + m := map[string]interface{}{ + "first": "second", + } + s := a.Adjust(m) + if s.Str != "first,second;" { + panic(s) + } + + a = wrap.NewDirectorMyClass(nil) + s = a.Adjust(m) + if s.Str != `{"first":"second"}` { + panic(s.Str) + } +} diff --git a/Examples/test-suite/go/go_inout_runme.go b/Examples/test-suite/go/go_inout_runme.go new file mode 100644 index 000000000..d288b31b1 --- /dev/null +++ b/Examples/test-suite/go/go_inout_runme.go @@ -0,0 +1,35 @@ +package main + +import ( + "encoding/json" + "fmt" + "reflect" + + "./go_inout" +) + +type S struct { + A int + B string + C float64 +} + +func (p *S) MarshalJSON() ([]byte, error) { + return json.Marshal(*p) +} + +func main() { + v := &S{12, "hi", 34.5} + m := go_inout.Same(v) + want := map[string]interface{}{ + // The type of A changes from int to float64 because + // JSON has no ints. + "A": float64(12), + "B": "hi", + "C": 34.5, + } + if !reflect.DeepEqual(m, want) { + fmt.Println("got", m, "want", want) + panic(m) + } +} diff --git a/Examples/test-suite/go_director_inout.i b/Examples/test-suite/go_director_inout.i new file mode 100644 index 000000000..af59e313c --- /dev/null +++ b/Examples/test-suite/go_director_inout.i @@ -0,0 +1,121 @@ +// Test the goin and goout typemaps for directors. + +%module(directors="1") go_director_inout + +%{ +#include +%} + +%inline +%{ + +struct MyStruct { + std::string str; +}; + +struct RetStruct { + std::string str; +}; + +%} + +%go_import("encoding/json") + +%insert(go_header) +%{ + +type GoRetStruct struct { + Str string +} + +%} + +%typemap(gotype) RetStruct "GoRetStruct" + +%typemap(imtype) RetStruct "string" + +%typemap(goin) RetStruct +%{ + $result = $input.Str +%} + +%typemap(in) RetStruct +%{ + $result.str.assign($input.p, $input.n); +%} + +%typemap(out) RetStruct +%{ + $result = _swig_makegostring($1.str.data(), $1.str.length()); +%} + +%typemap(goout) RetStruct +%{ + $result = GoRetStruct{Str: $input} +%} + +%typemap(godirectorout) RetStruct +%{ + $result = $input.Str +%} + +%typemap(directorout) RetStruct +%{ + $result.str.assign($input.p, $input.n); +%} + +%typemap(godirectorin) RetStruct +%{ +%} + +%typemap(gotype) MyStruct "map[string]interface{}" + +%typemap(imtype) MyStruct "string" + +%typemap(goin) MyStruct +%{ + if b, err := json.Marshal($input); err != nil { + panic(err) + } else { + $result = string(b) + } +%} + +%typemap(directorin) MyStruct +%{ + $input = _swig_makegostring($1.str.data(), $1.str.length()); +%} + +%typemap(out) MyStruct +%{ + $result = _swig_makegostring($1.str.data(), $1.str.length()); +%} + +%typemap(godirectorin) MyStruct +%{ + if err := json.Unmarshal([]byte($input), &$result); err != nil { + panic(err) + } +%} + +%typemap(in) MyStruct +%{ + $1.str.assign($input.p, $input.n); +%} + +%feature("director") MyClass; + +%inline +%{ + +class MyClass { + public: + virtual ~MyClass() {} + virtual RetStruct Adjust(MyStruct s) { + RetStruct r; + r.str = s.str; + return r; + } +}; + +%} diff --git a/Examples/test-suite/go_inout.i b/Examples/test-suite/go_inout.i new file mode 100644 index 000000000..443ce6f8f --- /dev/null +++ b/Examples/test-suite/go_inout.i @@ -0,0 +1,79 @@ +// Test the goin and goout typemaps. + +%module go_inout + +%{ +#include +%} + +%inline +%{ + +struct MyStruct { + std::string str; +}; + +struct RetStruct { + std::string str; +}; + +%} + +// Write a typemap that calls C++ by converting in and out of JSON. + +%go_import("encoding/json") + +%insert(go_header) +%{ + +type In json.Marshaler + +%} + +%typemap(gotype) MyStruct "In" + +%typemap(imtype) MyStruct "string" + +%typemap(goin) MyStruct +%{ + { + b, err := $input.MarshalJSON() + if err != nil { + panic(err) + } + $result = string(b) + } +%} + +%typemap(in) MyStruct +%{ + $1.str.assign($input.p, $input.n); +%} + +%typemap(gotype) RetStruct "map[string]interface{}" + +%typemap(imtype) RetStruct "string" + +%typemap(out) RetStruct +%{ + $result = _swig_makegostring($1.str.data(), $1.str.length()); +%} + +%typemap(goout) RetStruct +%{ + if err := json.Unmarshal([]byte($1), &$result); err != nil { + panic(err) + } +%} + +%inline +%{ + +RetStruct Same(MyStruct s) +{ + RetStruct r; + r.str = s.str; + return r; +} + +%} diff --git a/Source/Modules/go.cxx b/Source/Modules/go.cxx index 2de066b5d..06b76d998 100644 --- a/Source/Modules/go.cxx +++ b/Source/Modules/go.cxx @@ -867,6 +867,8 @@ private: emit_attach_parmmaps(parms, dummy); Swig_typemap_attach_parms("default", parms, dummy); Swig_typemap_attach_parms("gotype", parms, dummy); + Swig_typemap_attach_parms("goin", parms, dummy); + Swig_typemap_attach_parms("imtype", parms, dummy); int parm_count = emit_num_arguments(parms); int required_count = emit_num_required(parms); @@ -884,26 +886,28 @@ private: receiver = NULL; } + String *goout = Swig_typemap_lookup("goout", n, "swig_r", NULL); + bool add_to_interface = (interfaces && !is_constructor && !is_destructor && !is_static && !overname && checkFunctionVisibility(n, NULL)); bool needs_wrapper = (gccgo_flag || receiver || is_constructor || is_destructor || parm_count > required_count); // See whether any of the function parameters are represented by - // interface values When calling the C++ code, we need to convert + // interface values. When calling the C++ code, we need to convert // back to a uintptr. if (!needs_wrapper) { Parm *p = parms; for (int i = 0; i < parm_count; ++i) { p = getParm(p); String *ty = Getattr(p, "type"); - if (goTypeIsInterface(p, ty)) { + if (goTypeIsInterface(p, ty) || Getattr(p, "tmap:goin") != NULL) { needs_wrapper = true; break; } p = nextParm(p); } } - if (goTypeIsInterface(n, result)) { + if (goTypeIsInterface(n, result) || goout != NULL) { needs_wrapper = true; } @@ -1077,46 +1081,49 @@ private: } } - if (gccgo_flag) { - if (!is_constructor) { - Printv(f_go_wrappers, "\tdefer SwigCgocallDone()\n", NULL); - Printv(f_go_wrappers, "\tSwigCgocall()\n", NULL); + String *call = NewString(""); + + bool need_return_var = SwigType_type(result) != T_VOID && ((gccgo_flag && is_constructor) || goout != NULL); + if (need_return_var) { + Printv(f_go_wrappers, "\tvar swig_r ", NULL); + if (is_constructor) { + String *cl = exportedName(class_name); + Printv(f_go_wrappers, cl, NULL); + Delete(cl); } else { - // For a constructor the wrapper function will return a - // uintptr but we will return an interface. We want to - // convert the uintptr to the interface after calling - // SwigCgocallDone, so that we don't try to allocate memory - // while the Go scheduler can't see us. - Printv(f_go_wrappers, "\tvar done bool\n", NULL); - Printv(f_go_wrappers, "\tdefer func() {\n", NULL); - Printv(f_go_wrappers, "\t\tif !done {\n", NULL); - Printv(f_go_wrappers, "\t\t\tSwigCgocallDone()\n", NULL); - Printv(f_go_wrappers, "\t\t}\n", NULL); - Printv(f_go_wrappers, "\t}()\n", NULL); - Printv(f_go_wrappers, "\tSwigCgocall()\n", NULL); + Printv(f_go_wrappers, goImType(n, result), NULL); + } + Printv(f_go_wrappers, "\n", NULL); + } + + if (gccgo_flag) { + if (goout != NULL || is_constructor) { + Printv(call, "\tfunc() {\n", NULL); } + Printv(call, "\tdefer SwigCgocallDone()\n", NULL); + Printv(call, "\tSwigCgocall()\n", NULL); } - Printv(f_go_wrappers, "\t", NULL); + Printv(call, "\t", NULL); if (SwigType_type(result) != T_VOID) { - if (gccgo_flag && is_constructor) { - Printv(f_go_wrappers, "swig_r := ", NULL); + if (need_return_var) { + Printv(call, "swig_r = ", NULL); } else { - Printv(f_go_wrappers, "return ", NULL); + Printv(call, "return ", NULL); } } - Printv(f_go_wrappers, wrapper_name, "(", NULL); + Printv(call, wrapper_name, "(", NULL); if (parm_count > required_count) { - Printv(f_go_wrappers, "len(_swig_args)", NULL); + Printv(call, "len(_swig_args)", NULL); } if (base && receiver) { if (parm_count > required_count) { - Printv(f_go_wrappers, ", ", NULL); + Printv(call, ", ", NULL); } - Printv(f_go_wrappers, "_swig_base", NULL); + Printv(call, "_swig_base", NULL); } Parm *p = parms; @@ -1124,26 +1131,53 @@ private: p = getParm(p); if (i > 0 || (base && receiver) || parm_count > required_count) { - Printv(f_go_wrappers, ", ", NULL); + Printv(call, ", ", NULL); } - Printv(f_go_wrappers, Getattr(p, "lname"), NULL); - // If this is a destructor, then the C function expects the - // C++ value, and we have the interface. We need to get the - // C++ value. The same is true for a type represented as an - // interface. - if ((i == 0 && is_destructor) || ((i > 0 || !receiver || base || is_constructor) && goTypeIsInterface(p, Getattr(p, "type")))) { - Printv(f_go_wrappers, ".Swigcptr()", NULL); + SwigType *pt = Getattr(p, "type"); + String *ln = Getattr(p, "lname"); + + String *goin = Getattr(p, "tmap:goin"); + if (goin == NULL) { + Printv(call, ln, NULL); + if ((i == 0 && is_destructor) || ((i > 0 || !receiver || base || is_constructor) && goTypeIsInterface(p, pt))) { + Printv(call, ".Swigcptr()", NULL); + } + } else { + String *ivar = NewString(""); + Printf(ivar, "_swig_i_%d", i); + String *itm = goImType(p, pt); + Printv(f_go_wrappers, "\tvar ", ivar, " ", itm, NULL); + goin = Copy(goin); + Replaceall(goin, "$input", ln); + Replaceall(goin, "$result", ivar); + Printv(f_go_wrappers, goin, NULL); + Delete(goin); + Printv(call, ivar, NULL); } p = nextParm(p); } - Printv(f_go_wrappers, ")\n", NULL); + Printv(call, ")\n", NULL); + + if (gccgo_flag && (goout != NULL || is_constructor)) { + Printv(call, "\t}()\n", NULL); + } - if (gccgo_flag && is_constructor) { - Printv(f_go_wrappers, "\tSwigCgocallDone()\n", NULL); - Printv(f_go_wrappers, "\tdone = true\n", NULL); - Printv(f_go_wrappers, "\treturn swig_r\n", NULL); + Printv(f_go_wrappers, call, NULL); + Delete(call); + + if (need_return_var) { + if (goout == NULL) { + Printv(f_go_wrappers, "\treturn swig_r\n", NULL); + } else { + String *tm = goType(n, result); + Printv(f_go_wrappers, "\tvar swig_r_1 ", tm, "\n", NULL); + Replaceall(goout, "$input", "swig_r"); + Replaceall(goout, "$result", "swig_r_1"); + Printv(f_go_wrappers, goout, NULL); + Printv(f_go_wrappers, "\treturn swig_r_1\n", NULL); + } } Printv(f_go_wrappers, "}\n", NULL); @@ -1348,6 +1382,7 @@ private: String *ln = Getattr(p, "lname"); String *input = NewString(""); Printv(input, "swig_a->", ln, NULL); + tm = Copy(tm); Replaceall(tm, "$input", input); Setattr(p, "emit:input", input); if (i < required_count) { @@ -1357,6 +1392,7 @@ private: Printv(f->code, "\t\t", tm, "\n", NULL); Printv(f->code, "\t}\n", NULL); } + Delete(tm); } p = nextParm(p); } @@ -1486,6 +1522,7 @@ private: String *ln = Getattr(p, "lname"); String *pn = NewString("g"); Append(pn, ln); + tm = Copy(tm); Replaceall(tm, "$input", pn); Setattr(p, "emit:input", pn); if (i < required_count) { @@ -1495,6 +1532,7 @@ private: Printv(f->code, " ", tm, "\n", NULL); Printv(f->code, " }\n", NULL); } + Delete(tm); } p = nextParm(p); @@ -1543,17 +1581,19 @@ private: if (!tm) { p = nextSibling(p); } else { + tm = Copy(tm); Replaceall(tm, "$input", Getattr(p, "emit:input")); Printv(f->code, tm, "\n\n", NULL); + Delete(tm); p = Getattr(p, "tmap:check:next"); } } } /* ----------------------------------------------------------------------- - * getGoAction() + * emitGoAction() * - * Get the action of the function. This is used for C/C++ function. + * Emit the action of the function. This is used for the C/C++ function. * ----------------------------------------------------------------------- */ void emitGoAction(Node *n, List *base, ParmList *parms, SwigType *result, Wrapper *f) { @@ -1626,9 +1666,11 @@ private: if (!tm) { p = nextSibling(p); } else { + tm = Copy(tm); Replaceall(tm, "$result", Swig_cresult_name()); Replaceall(tm, "$input", Getattr(p, "emit:input")); Printv(f->code, tm, "\n", NULL); + Delete(tm); p = Getattr(p, "tmap:argout:next"); } } @@ -1650,8 +1692,10 @@ private: if (!tm) { p = nextSibling(p); } else { + tm = Copy(tm); Replaceall(tm, "$input", Getattr(p, "emit:input")); Printv(ret, tm, "\n", NULL); + Delete(tm); p = Getattr(p, "tmap:freearg:next"); } } @@ -2047,7 +2091,7 @@ private: } Append(f_go_wrappers, interfaces); - Printf(f_go_wrappers, "}\n\n", NULL); + Printv(f_go_wrappers, "}\n\n", NULL); Delete(interfaces); interfaces = NULL; @@ -2640,6 +2684,7 @@ private: DelWrapper(dummy); Swig_typemap_attach_parms("gotype", parms, NULL); + Swig_typemap_attach_parms("imtype", parms, NULL); int parm_count = emit_num_arguments(parms); String *func_name = NewString("NewDirector"); @@ -3075,6 +3120,7 @@ private: DelWrapper(dummy); Swig_typemap_attach_parms("gotype", parms, NULL); + Swig_typemap_attach_parms("imtype", parms, NULL); int parm_count = emit_num_arguments(parms); SwigType *result = Getattr(n, "type"); @@ -3122,6 +3168,8 @@ private: Swig_typemap_attach_parms("directorin", parms, w); Swig_typemap_attach_parms("directorargout", parms, w); + Swig_typemap_attach_parms("godirectorin", parms, w); + Swig_typemap_attach_parms("goin", parms, dummy); if (!is_ignored) { // We use an interface to see if this method is defined in Go. @@ -3234,29 +3282,82 @@ private: if (GetFlag(n, "abstract")) { Printv(f_go_wrappers, "\tpanic(\"call to pure virtual method\")\n", NULL); } else { + String *goout = NULL; + if (SwigType_type(result) != T_VOID) { + Printv(f_go_wrappers, "\tvar swig_r ", goImType(n, result), "\n", NULL); + goout = Swig_typemap_lookup("goout", n, "swig_r", NULL); + } + + String *call = NewString(""); + if (gccgo_flag) { - Printv(f_go_wrappers, "\tdefer SwigCgocallDone()\n", NULL); - Printv(f_go_wrappers, "\tSwigCgocall()\n", NULL); + if (goout != NULL) { + Printv(call, "\tfunc() {\n", NULL); + } + Printv(call, "\tdefer SwigCgocallDone()\n", NULL); + Printv(call, "\tSwigCgocall()\n", NULL); } - Printv(f_go_wrappers, "\t", NULL); + Printv(call, "\t", NULL); if (SwigType_type(result) != T_VOID) { - Printv(f_go_wrappers, "return ", NULL); + Printv(call, "swig_r = ", NULL); } - Printv(f_go_wrappers, upcall_gc_name, "(swig_p.", go_type_name, NULL); + Printv(call, upcall_gc_name, "(swig_p.", go_type_name, NULL); p = parms; for (int i = 0; i < parm_count; ++i) { + Printv(call, ", ", NULL); p = getParm(p); SwigType *pt = Getattr(p, "type"); - Printv(f_go_wrappers, ", ", Getattr(p, "lname"), NULL); - if (goTypeIsInterface(p, pt)) { - Printv(f_go_wrappers, ".Swigcptr()", NULL); + + String *ln = Getattr(p, "lname"); + + // This is an ordinary call from Go to C++, so adjust using + // the goin typemap. + String *goin = Getattr(p, "tmap:goin"); + if (goin == NULL) { + Printv(call, ln, NULL); + if (goTypeIsInterface(p, pt)) { + Printv(call, ".Swigcptr()", NULL); + } + } else { + String *ivar = NewString(""); + Printf(ivar, "_swig_i_%d", i); + String *itm = goImType(p, pt); + Printv(f_go_wrappers, "\tvar ", ivar, " ", itm, NULL); + goin = Copy(goin); + Replaceall(goin, "$input", ln); + Replaceall(goin, "$result", ivar); + Printv(f_go_wrappers, goin, NULL); + Delete(goin); + Printv(call, ivar, NULL); + Delete(ivar); } + p = nextParm(p); } - Printv(f_go_wrappers, ")\n", NULL); + Printv(call, ")\n", NULL); + + if (gccgo_flag && goout != NULL) { + Printv(call, "\t}()\n", NULL); + } + + Printv(f_go_wrappers, call, NULL); + Delete(call); + + if (SwigType_type(result) != T_VOID) { + if (goout == NULL) { + Printv(f_go_wrappers, "\treturn swig_r\n", NULL); + } else { + String *tm = goType(n, result); + Printv(f_go_wrappers, "\tvar swig_r_1 ", tm, "\n", NULL); + Replaceall(goout, "$input", "swig_r"); + Replaceall(goout, "$result", "swig_r_1"); + Printv(f_go_wrappers, goout, NULL); + Printv(f_go_wrappers, "\treturn swig_r_1\n", NULL); + } + } } Printv(f_go_wrappers, "}\n\n", NULL); @@ -3389,29 +3490,83 @@ private: Printv(f_go_wrappers, " {\n", NULL); + String *goout = NULL; + if (SwigType_type(result) != T_VOID) { + Printv(f_go_wrappers, "\tvar swig_r ", goImType(n, result), "\n", NULL); + goout = Swig_typemap_lookup("goout", n, "swig_r", NULL); + } + + String *call = NewString(""); + if (gccgo_flag) { - Printv(f_go_wrappers, "\tdefer SwigCgocallDone()\n", NULL); - Printv(f_go_wrappers, "\tSwigCgocall()\n", NULL); + if (goout != NULL) { + Printv(call, "\tfunc() {\n", NULL); + } + Printv(call, "\tdefer SwigCgocallDone()\n", NULL); + Printv(call, "\tSwigCgocall()\n", NULL); } - Printv(f_go_wrappers, "\t", NULL); + Printv(call, "\t", NULL); if (SwigType_type(result) != T_VOID) { - Printv(f_go_wrappers, "return ", NULL); + Printv(call, "swig_r = ", NULL); } - Printv(f_go_wrappers, upcall_gc_name, "(p.(*", director_struct_name, ").", go_type_name, NULL); + Printv(call, upcall_gc_name, "(p.(*", director_struct_name, ").", go_type_name, NULL); p = parms; for (int i = 0; i < parm_count; ++i) { + Printv(call, ", ", NULL); p = getParm(p); SwigType *pt = Getattr(p, "type"); - Printv(f_go_wrappers, ", ", Getattr(p, "lname"), NULL); + + String *ln = Copy(Getattr(p, "lname")); if (goTypeIsInterface(p, pt)) { - Printv(f_go_wrappers, ".Swigcptr()", NULL); + Printv(ln, ".Swigcptr()", NULL); + } + + String *goin = Getattr(p, "tmap:goin"); + if (goin == NULL) { + Printv(call, ln, NULL); + } else { + String *ivar = NewString(""); + Printf(ivar, "_swig_i_%d", i); + String *itm = goImType(p, pt); + Printv(f_go_wrappers, "\tvar ", ivar, " ", itm, NULL); + goin = Copy(goin); + Replaceall(goin, "$input", ln); + Replaceall(goin, "$result", ivar); + Printv(f_go_wrappers, goin, NULL); + Delete(goin); + Printv(call, ivar, NULL); + Delete(ivar); } + + Delete(ln); + p = nextParm(p); } - Printv(f_go_wrappers, ")\n", NULL); + Printv(call, ")\n", NULL); + + if (gccgo_flag && goout != NULL) { + Printv(call, "\t}()\n", NULL); + } + + Printv(f_go_wrappers, call, NULL); + Delete(call); + + if (SwigType_type(result) != T_VOID) { + if (goout == NULL) { + Printv(f_go_wrappers, "\treturn swig_r\n", NULL); + } else { + String *tm = goType(n, result); + Printv(f_go_wrappers, "\tvar swig_r_1 ", tm, "\n", NULL); + Replaceall(goout, "$input", "swig_r"); + Replaceall(goout, "$result", "swig_r_1"); + Printv(f_go_wrappers, goout, NULL); + Printv(f_go_wrappers, "\treturn swig_r_1\n", NULL); + } + } + Printv(f_go_wrappers, "}\n\n", NULL); } @@ -3437,34 +3592,53 @@ private: } Printv(f_go_wrappers, "{\n", NULL); - if (gccgo_flag) { - Printv(f_go_wrappers, "\tSwigCgocallBack()\n", NULL); - Printv(f_go_wrappers, "\tdefer SwigCgocallBackDone()\n", NULL); - } - - Printv(f_go_wrappers, "\t", NULL); - if (is_ignored) { - Printv(f_go_wrappers, "return\n", NULL); + Printv(f_go_wrappers, "\treturn\n", NULL); } else { bool result_is_interface = false; + String *goout = NULL; if (SwigType_type(result) != T_VOID) { - Printv(f_go_wrappers, "return ", NULL); result_is_interface = goTypeIsInterface(NULL, result); + Printv(f_go_wrappers, "\tvar swig_r ", NULL); + if (!result_is_interface) { + Printv(f_go_wrappers, goType(n, result), NULL); + } else { + Printv(f_go_wrappers, result_wrapper, NULL); + } + Printv(f_go_wrappers, "\n", NULL); + goout = Swig_typemap_lookup("godirectorout", n, "swig_r", NULL); + } + + String *call = NewString(""); + + if (gccgo_flag) { + if (goout != NULL) { + Printv(call, "\tfunc() {\n", NULL); + } + Printv(call, "\tSwigCgocallBack()\n", NULL); + Printv(call, "\tdefer SwigCgocallBackDone()\n", NULL); + } + + Printv(call, "\t", NULL); + + if (SwigType_type(result) != T_VOID) { + Printv(call, "swig_r = ", NULL); if (result_is_interface) { - Printv(f_go_wrappers, result_wrapper, "(", NULL); + Printv(call, result_wrapper, "(", NULL); } } - Printv(f_go_wrappers, "p.", go_with_over_name, "(", NULL); + Printv(call, "p.", go_with_over_name, "(", NULL); p = parms; for (int i = 0; i < parm_count; ++i) { p = getParm(p); if (i > 0) { - Printv(f_go_wrappers, ", ", NULL); + Printv(call, ", ", NULL); } SwigType *pt = Getattr(p, "type"); + String *ln = NewString(""); + // If the Go representation is an interface type class, then // we are receiving a uintptr, and must convert to the // interface. @@ -3473,26 +3647,64 @@ private: // Passing is_result as true to goWrapperType gives us the // name of the Go type we need to convert to an interface. String *wt = goWrapperType(p, pt, true); - Printv(f_go_wrappers, wt, "(", NULL); + Printv(ln, wt, "(", NULL); Delete(wt); } - Printv(f_go_wrappers, Getattr(p, "lname"), NULL); + Printv(ln, Getattr(p, "lname"), NULL); if (is_interface) { - Printv(f_go_wrappers, ")", NULL); + Printv(ln, ")", NULL); + } + + String *goin = Getattr(p, "tmap:godirectorin"); + if (goin == NULL) { + Printv(call, ln, NULL); + } else { + String *ivar = NewString(""); + Printf(ivar, "_swig_i_%d", i); + String *itm = goType(p, pt); + Printv(f_go_wrappers, "\tvar ", ivar, " ", itm, NULL); + goin = Copy(goin); + Replaceall(goin, "$input", ln); + Replaceall(goin, "$result", ivar); + Printv(f_go_wrappers, goin, NULL); + Delete(goin); + Printv(call, ivar, NULL); + Delete(ivar); } + Delete(ln); + p = nextParm(p); } - Printv(f_go_wrappers, ")", NULL); + Printv(call, ")", NULL); if (result_is_interface) { - Printv(f_go_wrappers, ".Swigcptr())", NULL); + Printv(call, ".Swigcptr())", NULL); } + Printv(call, "\n", NULL); - Printv(f_go_wrappers, "\n", NULL); + if (gccgo_flag && goout != NULL) { + Printv(call, "\t}()\n", NULL); + } + + Printv(f_go_wrappers, call, NULL); + Delete(call); + + if (SwigType_type(result) != T_VOID) { + if (goout == NULL) { + Printv(f_go_wrappers, "\treturn swig_r\n", NULL); + } else { + String *tm = goImType(n, result); + Printv(f_go_wrappers, "\tvar swig_r_1 ", tm, "\n", NULL); + Replaceall(goout, "$input", "swig_r"); + Replaceall(goout, "$result", "swig_r_1"); + Printv(f_go_wrappers, goout, NULL); + Printv(f_go_wrappers, "\treturn swig_r_1\n", NULL); + } + } } Printv(f_go_wrappers, "}\n\n", NULL); @@ -3610,6 +3822,7 @@ private: Swig_warning(WARN_TYPEMAP_DIRECTORIN_UNDEF, input_file, line_number, "Unable to use type %s as director method argument\n", SwigType_str(Getattr(p, "type"), 0)); } else { + tm = Copy(tm); String *ln = Getattr(p, "lname"); String *input = NewString(""); Printv(input, "swig_a.", ln, NULL); @@ -3618,6 +3831,7 @@ private: Replaceall(tm, "$owner", "0"); Delete(input); Printv(w->code, "\t", tm, "\n", NULL); + Delete(tm); } p = Getattr(p, "tmap:directorin:next"); } @@ -3683,9 +3897,11 @@ private: Swig_warning(WARN_TYPEMAP_DIRECTORIN_UNDEF, input_file, line_number, "Unable to use type %s as director method argument\n", SwigType_str(Getattr(p, "type"), 0)); } else { + tm = Copy(tm); Replaceall(tm, "$input", pn); Replaceall(tm, "$owner", 0); Printv(w->code, " ", tm, "\n", NULL); + Delete(tm); Printv(args, ", ", pn, NULL); } @@ -3722,9 +3938,11 @@ private: for (p = parms; p;) { String *tm; if ((tm = Getattr(p, "tmap:directorargout"))) { + tm = Copy(tm); Replaceall(tm, "$result", "jresult"); Replaceall(tm, "$input", Getattr(p, "emit:directorinput")); Printv(w->code, tm, "\n", NIL); + Delete(tm); p = Getattr(p, "tmap:directorargout:next"); } else { p = nextSibling(p); @@ -4462,7 +4680,19 @@ private: * ---------------------------------------------------------------------- */ String *goType(Node *n, SwigType *type) { - return goTypeWithInfo(n, type, NULL); + return goTypeWithInfo(n, type, false, NULL); + } + + /* ---------------------------------------------------------------------- + * goImType() + * + * Given a SWIG type, return a string for the intermediate Go type + * to pass to C/C++. This is like goType except that it looks for + * an imtype typemap entry first. + * ---------------------------------------------------------------------- */ + + String *goImType(Node *n, SwigType *type) { + return goTypeWithInfo(n, type, true, NULL); } /* ---------------------------------------------------------------------- @@ -4470,6 +4700,8 @@ private: * * Like goType, but return some more information. * + * If use_imtype is true, this look for a imtype typemap entry. + * * If the p_is_interface parameter is not NULL, this sets * *p_is_interface to indicate whether this type is going to be * represented by a Go interface type. These are cases where the Go @@ -4477,24 +4709,39 @@ private: * forth with C/C++. * ---------------------------------------------------------------------- */ - String *goTypeWithInfo(Node *n, SwigType *type, bool *p_is_interface) { + String *goTypeWithInfo(Node *n, SwigType *type, bool use_imtype, bool *p_is_interface) { if (p_is_interface) { *p_is_interface = false; } - String *ret; - if (n && Cmp(type, Getattr(n, "type")) == 0) { - ret = NULL; - if (Strcmp(Getattr(n, "nodeType"), "parm") == 0) { - ret = Getattr(n, "tmap:gotype"); + String *ret = NULL; + if (use_imtype) { + if (n && Cmp(type, Getattr(n, "type")) == 0) { + if (Strcmp(Getattr(n, "nodeType"), "parm") == 0) { + ret = Getattr(n, "tmap:imtype"); + } + if (!ret) { + ret = Swig_typemap_lookup("imtype", n, "", NULL); + } + } else { + Parm *p = NewParm(type, "goImType", n); + ret = Swig_typemap_lookup("imtype", p, "", NULL); + Delete(p); } - if (!ret) { - ret = Swig_typemap_lookup("gotype", n, "", NULL); + } + if (!ret) { + if (n && Cmp(type, Getattr(n, "type")) == 0) { + if (Strcmp(Getattr(n, "nodeType"), "parm") == 0) { + ret = Getattr(n, "tmap:gotype"); + } + if (!ret) { + ret = Swig_typemap_lookup("gotype", n, "", NULL); + } + } else { + Parm *p = NewParm(type, "goType", n); + ret = Swig_typemap_lookup("gotype", p, "", NULL); + Delete(p); } - } else { - Parm *p = NewParm(type, "goType", n); - ret = Swig_typemap_lookup("gotype", p, "", NULL); - Delete(p); } if (ret && Strstr(ret, "$gotypename") != 0) { @@ -4563,7 +4810,7 @@ private: ret = NewString("uintptr"); } else { bool is_interface; - String *base = goTypeWithInfo(n, r, &is_interface); + String *base = goTypeWithInfo(n, r, false, &is_interface); // At the Go level, an unknown or class type is handled as an // interface wrapping a pointer. This means that if a @@ -4627,12 +4874,12 @@ private: if (add_pointer) { SwigType_add_pointer(r); } - ret = goTypeWithInfo(n, r, p_is_interface); + ret = goTypeWithInfo(n, r, false, p_is_interface); Delete(r); } else if (SwigType_isqualifier(t)) { SwigType *r = Copy(t); SwigType_del_qualifier(r); - ret = goTypeWithInfo(n, r, p_is_interface); + ret = goTypeWithInfo(n, r, false, p_is_interface); Delete(r); } else if (SwigType_isvarargs(t)) { ret = NewString("[]interface{}"); @@ -4658,7 +4905,7 @@ private: String *goWrapperType(Node *n, SwigType *type, bool is_result) { bool is_interface; - String *ret = goTypeWithInfo(n, type, &is_interface); + String *ret = goTypeWithInfo(n, type, true, &is_interface); // If this is an interface, we want to pass the real type. if (is_interface) { @@ -4742,7 +4989,7 @@ private: String *gcCTypeForGoValue(Node *n, SwigType *type, String *name) { bool is_interface; - String *gt = goTypeWithInfo(n, type, &is_interface); + String *gt = goTypeWithInfo(n, type, true, &is_interface); bool is_string = Strcmp(gt, "string") == 0; bool is_slice = Strncmp(gt, "[]", 2) == 0; bool is_function = Strcmp(gt, "_swig_fnptr") == 0; @@ -4885,7 +5132,7 @@ private: bool goTypeIsInterface(Node *n, SwigType *type) { bool is_interface; - Delete(goTypeWithInfo(n, type, &is_interface)); + Delete(goTypeWithInfo(n, type, false, &is_interface)); return is_interface; } -- cgit v1.2.1 From be145043df6ba6224f8e5dc9a4149720f3f7f5a1 Mon Sep 17 00:00:00 2001 From: Ian Lance Taylor Date: Sun, 7 Sep 2014 15:44:12 -0700 Subject: Add run test case for argout.i. --- Examples/test-suite/go/argout_runme.go | 41 ++++++++++++++++++++++++++++++++++ 1 file changed, 41 insertions(+) create mode 100644 Examples/test-suite/go/argout_runme.go diff --git a/Examples/test-suite/go/argout_runme.go b/Examples/test-suite/go/argout_runme.go new file mode 100644 index 000000000..5f7017e73 --- /dev/null +++ b/Examples/test-suite/go/argout_runme.go @@ -0,0 +1,41 @@ +package main + +import wrap "./argout" + +func main() { + ip := wrap.New_intp() + wrap.Intp_assign(ip, 42) + if r := wrap.Incp(ip); r != 42 { + panic(r) + } + if r := wrap.Intp_value(ip); r != 43 { + panic(r) + } + + p := wrap.New_intp() + wrap.Intp_assign(p, 2) + if r := wrap.Incp(p); r != 2 { + panic(r) + } + if r := wrap.Intp_value(p); r != 3 { + panic(r) + } + + r := wrap.New_intp() + wrap.Intp_assign(r, 7) + if r := wrap.Incr(r); r != 7 { + panic(r) + } + if r := wrap.Intp_value(r); r != 8 { + panic(r) + } + + tr := wrap.New_intp() + wrap.Intp_assign(tr, 4) + if r := wrap.Inctr(tr); r != 4 { + panic(r) + } + if r := wrap.Intp_value(tr); r != 5 { + panic(r) + } +} -- cgit v1.2.1 From 0dfc1b090f5a76b0279ff2470d55ecf97bb8ee32 Mon Sep 17 00:00:00 2001 From: Richard Date: Tue, 9 Sep 2014 10:08:30 -0300 Subject: Fix duplicate symbol linker errors for Javascript/v8 --- Lib/javascript/v8/javascriptcode.swg | 34 +++++++++++++++++----------------- Lib/javascript/v8/javascriptrun.swg | 36 ++++++++++++++++++------------------ 2 files changed, 35 insertions(+), 35 deletions(-) diff --git a/Lib/javascript/v8/javascriptcode.swg b/Lib/javascript/v8/javascriptcode.swg index d99546aff..5af026d0b 100644 --- a/Lib/javascript/v8/javascriptcode.swg +++ b/Lib/javascript/v8/javascriptcode.swg @@ -8,7 +8,7 @@ * ----------------------------------------------------------------------------- */ %fragment("js_ctor", "templates") %{ -SwigV8ReturnValue $jswrapper(const SwigV8Arguments &args) { +static SwigV8ReturnValue $jswrapper(const SwigV8Arguments &args) { SWIGV8_HANDLESCOPE(); v8::Handle self = args.Holder(); @@ -32,7 +32,7 @@ fail: * ----------------------------------------------------------------------------- */ %fragment ("js_veto_ctor", "templates") %{ -SwigV8ReturnValue $jswrapper(const SwigV8Arguments &args) { +static SwigV8ReturnValue $jswrapper(const SwigV8Arguments &args) { SWIGV8_HANDLESCOPE(); SWIG_exception(SWIG_ERROR, "Class $jsname can not be instantiated"); @@ -48,7 +48,7 @@ SwigV8ReturnValue $jswrapper(const SwigV8Arguments &args) { * ----------------------------------------------------------------------------- */ %fragment ("js_ctor_dispatcher", "templates") %{ -SwigV8ReturnValue $jswrapper(const SwigV8Arguments &args) { +static SwigV8ReturnValue $jswrapper(const SwigV8Arguments &args) { SWIGV8_HANDLESCOPE(); OverloadErrorHandler errorHandler; @@ -74,7 +74,7 @@ fail: * - $jsmangledtype: mangled type of class * ----------------------------------------------------------------------------- */ %fragment("js_overloaded_ctor", "templates") %{ -SwigV8ReturnValue $jswrapper(const SwigV8Arguments &args, V8ErrorHandler &SWIGV8_ErrorHandler) { +static SwigV8ReturnValue $jswrapper(const SwigV8Arguments &args, V8ErrorHandler &SWIGV8_ErrorHandler) { SWIGV8_HANDLESCOPE(); v8::Handle self = args.Holder(); @@ -125,15 +125,15 @@ fail: %{ #if (SWIG_V8_VERSION < 0x031710) -void $jswrapper(v8::Persistent< v8::Value > object, void *parameter) { +static void $jswrapper(v8::Persistent< v8::Value > object, void *parameter) { SWIGV8_Proxy *proxy = static_cast(parameter); #elif (SWIG_V8_VERSION < 0x031900) -void $jswrapper(v8::Isolate *isolate, v8::Persistent object, void *parameter) { +static void $jswrapper(v8::Isolate *isolate, v8::Persistent object, void *parameter) { SWIGV8_Proxy *proxy = static_cast(parameter); #elif (SWIG_V8_VERSION < SWIGV8_SETWEAK_VERSION) -void $jswrapper(v8::Isolate *isolate, v8::Persistent *object, SWIGV8_Proxy *proxy) { +static void $jswrapper(v8::Isolate *isolate, v8::Persistent *object, SWIGV8_Proxy *proxy) { #else -void $jswrapper(const v8::WeakCallbackData &data) { +static void $jswrapper(const v8::WeakCallbackData &data) { v8::Local object = data.GetValue(); SWIGV8_Proxy *proxy = data.GetParameter(); #endif @@ -169,15 +169,15 @@ void $jswrapper(const v8::WeakCallbackData &data) { %fragment ("js_dtoroverride", "templates") %{ #if (SWIG_V8_VERSION < 0x031710) -void $jswrapper(v8::Persistent object, void *parameter) { +static void $jswrapper(v8::Persistent object, void *parameter) { SWIGV8_Proxy *proxy = static_cast(parameter); #elif (SWIG_V8_VERSION < 0x031900) -void $jswrapper(v8::Isolate *isolate, v8::Persistent object, void *parameter) { +static void $jswrapper(v8::Isolate *isolate, v8::Persistent object, void *parameter) { SWIGV8_Proxy *proxy = static_cast(parameter); #elif (SWIG_V8_VERSION < SWIGV8_SETWEAK_VERSION) -void $jswrapper(v8::Isolate *isolate, v8::Persistent< v8::Object> *object, SWIGV8_Proxy *proxy) { +static void $jswrapper(v8::Isolate *isolate, v8::Persistent< v8::Object> *object, SWIGV8_Proxy *proxy) { #else -void $jswrapper(const v8::WeakCallbackData &data) { +static void $jswrapper(const v8::WeakCallbackData &data) { v8::Local object = data.GetValue(); SWIGV8_Proxy *proxy = data.GetParameter(); #endif @@ -210,7 +210,7 @@ void $jswrapper(const v8::WeakCallbackData &data) { * ----------------------------------------------------------------------------- */ %fragment("js_getter", "templates") %{ -SwigV8ReturnValue $jswrapper(v8::Local property, const SwigV8PropertyCallbackInfo &info) { +static SwigV8ReturnValue $jswrapper(v8::Local property, const SwigV8PropertyCallbackInfo &info) { SWIGV8_HANDLESCOPE(); v8::Handle jsresult; @@ -232,7 +232,7 @@ fail: * ----------------------------------------------------------------------------- */ %fragment("js_setter", "templates") %{ -void $jswrapper(v8::Local property, v8::Local value, +static void $jswrapper(v8::Local property, v8::Local value, const SwigV8PropertyCallbackInfoVoid &info) { SWIGV8_HANDLESCOPE(); @@ -252,7 +252,7 @@ fail: * ----------------------------------------------------------------------------- */ %fragment("js_function", "templates") %{ -SwigV8ReturnValue $jswrapper(const SwigV8Arguments &args) { +static SwigV8ReturnValue $jswrapper(const SwigV8Arguments &args) { SWIGV8_HANDLESCOPE(); v8::Handle jsresult; @@ -277,7 +277,7 @@ fail: * ----------------------------------------------------------------------------- */ %fragment("js_function_dispatcher", "templates") %{ -SwigV8ReturnValue $jswrapper(const SwigV8Arguments &args) { +static SwigV8ReturnValue $jswrapper(const SwigV8Arguments &args) { SWIGV8_HANDLESCOPE(); v8::Handle jsresult; @@ -300,7 +300,7 @@ fail: * ----------------------------------------------------------------------------- */ %fragment ("js_overloaded_function", "templates") %{ -SwigV8ReturnValue $jswrapper(const SwigV8Arguments &args, V8ErrorHandler &SWIGV8_ErrorHandler) +static SwigV8ReturnValue $jswrapper(const SwigV8Arguments &args, V8ErrorHandler &SWIGV8_ErrorHandler) { SWIGV8_HANDLESCOPE(); diff --git a/Lib/javascript/v8/javascriptrun.swg b/Lib/javascript/v8/javascriptrun.swg index d4d636c8c..d9a6b591a 100644 --- a/Lib/javascript/v8/javascriptrun.swg +++ b/Lib/javascript/v8/javascriptrun.swg @@ -93,7 +93,7 @@ typedef v8::PropertyCallbackInfo SwigV8PropertyCallbackInfo; #define SWIG_fail goto fail #define SWIGV8_OVERLOAD false -void SWIG_V8_Raise(const char *msg) { +static void SWIG_V8_Raise(const char *msg) { SWIGV8_THROW_EXCEPTION(v8::Exception::Error(SWIGV8_STRING_NEW(msg))); } @@ -118,7 +118,7 @@ public: } }; // this is used in usually -V8ErrorHandler SWIGV8_ErrorHandler; +static V8ErrorHandler SWIGV8_ErrorHandler; // instances of this are used in overloaded functions class OverloadErrorHandler: public V8ErrorHandler { @@ -190,9 +190,9 @@ public: #endif }; -v8::Persistent SWIGV8_SWIGTYPE_Proxy_class_templ; +static v8::Persistent SWIGV8_SWIGTYPE_Proxy_class_templ; -int SWIG_V8_ConvertInstancePtr(v8::Handle objRef, void **ptr, swig_type_info *info, int flags) { +static int SWIG_V8_ConvertInstancePtr(v8::Handle objRef, void **ptr, swig_type_info *info, int flags) { SWIGV8_HANDLESCOPE(); if(objRef->InternalFieldCount() < 1) return SWIG_ERROR; @@ -226,22 +226,22 @@ int SWIG_V8_ConvertInstancePtr(v8::Handle objRef, void **ptr, swig_t #if (SWIG_V8_VERSION < 0x031710) -void SWIGV8_Proxy_DefaultDtor(v8::Persistent< v8::Value > object, void *parameter) { +static void SWIGV8_Proxy_DefaultDtor(v8::Persistent< v8::Value > object, void *parameter) { SWIGV8_Proxy *proxy = static_cast(parameter); #elif (SWIG_V8_VERSION < 0x031900) -void SWIGV8_Proxy_DefaultDtor(v8::Isolate *, v8::Persistent< v8::Value > object, void *parameter) { +static void SWIGV8_Proxy_DefaultDtor(v8::Isolate *, v8::Persistent< v8::Value > object, void *parameter) { SWIGV8_Proxy *proxy = static_cast(parameter); #elif (SWIG_V8_VERSION < SWIGV8_SETWEAK_VERSION) -void SWIGV8_Proxy_DefaultDtor(v8::Isolate *, v8::Persistent< v8::Object > *object, SWIGV8_Proxy *proxy) { +static void SWIGV8_Proxy_DefaultDtor(v8::Isolate *, v8::Persistent< v8::Object > *object, SWIGV8_Proxy *proxy) { #else -void SWIGV8_Proxy_DefaultDtor(const v8::WeakCallbackData &data) { +static void SWIGV8_Proxy_DefaultDtor(const v8::WeakCallbackData &data) { SWIGV8_Proxy *proxy = data.GetParameter(); #endif delete proxy; } -int SWIG_V8_GetInstancePtr(v8::Handle valRef, void **ptr) { +static int SWIG_V8_GetInstancePtr(v8::Handle valRef, void **ptr) { if(!valRef->IsObject()) { return SWIG_TypeError; } @@ -265,7 +265,7 @@ int SWIG_V8_GetInstancePtr(v8::Handle valRef, void **ptr) { return SWIG_OK; } -void SWIGV8_SetPrivateData(v8::Handle obj, void *ptr, swig_type_info *info, int flags) { +static void SWIGV8_SetPrivateData(v8::Handle obj, void *ptr, swig_type_info *info, int flags) { SWIGV8_Proxy *cdata = new SWIGV8_Proxy(); cdata->swigCObject = ptr; cdata->swigCMemOwn = (flags & SWIG_POINTER_OWN) ? 1 : 0; @@ -322,7 +322,7 @@ void SWIGV8_SetPrivateData(v8::Handle obj, void *ptr, swig_type_info } -int SWIG_V8_ConvertPtr(v8::Handle valRef, void **ptr, swig_type_info *info, int flags) { +static int SWIG_V8_ConvertPtr(v8::Handle valRef, void **ptr, swig_type_info *info, int flags) { SWIGV8_HANDLESCOPE(); /* special case: JavaScript null => C NULL pointer */ @@ -337,7 +337,7 @@ int SWIG_V8_ConvertPtr(v8::Handle valRef, void **ptr, swig_type_info return SWIG_V8_ConvertInstancePtr(objRef, ptr, info, flags); } -v8::Handle SWIG_V8_NewPointerObj(void *ptr, swig_type_info *info, int flags) { +static v8::Handle SWIG_V8_NewPointerObj(void *ptr, swig_type_info *info, int flags) { SWIGV8_HANDLESCOPE_ESC(); v8::Handle class_templ; @@ -385,7 +385,7 @@ v8::Handle SWIG_V8_NewPointerObj(void *ptr, swig_type_info *info, int #define SWIG_GetInstancePtr(obj, ptr) SWIG_V8_GetInstancePtr(obj, ptr) -SwigV8ReturnValue _SWIGV8_wrap_equals(const SwigV8Arguments &args) { +static SwigV8ReturnValue _SWIGV8_wrap_equals(const SwigV8Arguments &args) { SWIGV8_HANDLESCOPE(); v8::Handle jsresult; @@ -415,7 +415,7 @@ fail: SWIGV8_RETURN(SWIGV8_UNDEFINED()); } -SwigV8ReturnValue _wrap_getCPtr(const SwigV8Arguments &args) { +static SwigV8ReturnValue _wrap_getCPtr(const SwigV8Arguments &args) { SWIGV8_HANDLESCOPE(); v8::Handle jsresult; @@ -504,15 +504,15 @@ int SWIGV8_ConvertPacked(v8::Handle valRef, void *ptr, size_t sz, swi } #if (SWIG_V8_VERSION < 0x031710) -void _wrap_SwigV8PackedData_delete(v8::Persistent< v8::Value > object, void *parameter) { +static void _wrap_SwigV8PackedData_delete(v8::Persistent< v8::Value > object, void *parameter) { SwigV8PackedData *cdata = static_cast(parameter); #elif (SWIG_V8_VERSION < 0x031900) -void _wrap_SwigV8PackedData_delete(v8::Isolate *isolate, v8::Persistent object, void *parameter) { +static void _wrap_SwigV8PackedData_delete(v8::Isolate *isolate, v8::Persistent object, void *parameter) { SwigV8PackedData *cdata = static_cast(parameter); #elif (SWIG_V8_VERSION < SWIGV8_SETWEAK_VERSION) -void _wrap_SwigV8PackedData_delete(v8::Isolate *isolate, v8::Persistent *object, SwigV8PackedData *cdata) { +static void _wrap_SwigV8PackedData_delete(v8::Isolate *isolate, v8::Persistent *object, SwigV8PackedData *cdata) { #else -void _wrap_SwigV8PackedData_delete(const v8::WeakCallbackData &data) { +static void _wrap_SwigV8PackedData_delete(const v8::WeakCallbackData &data) { v8::Local object = data.GetValue(); SwigV8PackedData *cdata = data.GetParameter(); #endif -- cgit v1.2.1 From 0dd7b61c576018bc73c36350d3c72f3d62f84ee3 Mon Sep 17 00:00:00 2001 From: Olly Betts Date: Tue, 9 Sep 2014 13:39:30 -0300 Subject: Fix segmentation faults with directors in PHP >= 5.4 --- CHANGES.current | 5 +++++ Examples/test-suite/php/director_basic_runme.php | 2 -- Lib/php/phprun.swg | 2 +- 3 files changed, 6 insertions(+), 3 deletions(-) diff --git a/CHANGES.current b/CHANGES.current index 09a71f7f9..e9b9b71ea 100644 --- a/CHANGES.current +++ b/CHANGES.current @@ -5,6 +5,11 @@ See the RELEASENOTES file for a summary of changes in each release. Version 3.0.3 (in progress) =========================== +2014-09-09: olly + [PHP] Fix segmentation faults with directors in PHP >= 5.4, and + reenable runme tests for director_basic testcase. Fix from + pavel-charvat in issue#164. + 2014-09-05: ianlancetaylor [Go] Add imtype, goin, goout, godirectorin, and godirectorout typemaps, to support writing Go code to diff --git a/Examples/test-suite/php/director_basic_runme.php b/Examples/test-suite/php/director_basic_runme.php index 1458725f1..de6b50502 100644 --- a/Examples/test-suite/php/director_basic_runme.php +++ b/Examples/test-suite/php/director_basic_runme.php @@ -3,7 +3,6 @@ require "tests.php"; require "director_basic.php"; -/* Removed until runtime error is fixed, see https://github.com/swig/swig/issues/164 // No new functions check::functions(array(foo_ping,foo_pong,foo_get_self,a_f,a_rg,a1_ff,myclass_method,myclass_vmethod,myclass_pmethod,myclass_cmethod,myclass_get_self,myclass_call_pmethod,myclasst_i_method)); // No new classes @@ -54,7 +53,6 @@ $cc->method($b); check::equal($bc->x, 34, "bc failed"); check::equal($bd->x, 16, "bd failed"); -*/ check::done(); ?> diff --git a/Lib/php/phprun.swg b/Lib/php/phprun.swg index 6d922bcad..00d8bc560 100644 --- a/Lib/php/phprun.swg +++ b/Lib/php/phprun.swg @@ -153,7 +153,7 @@ SWIG_ZTS_SetPointerZval(zval *z, void *ptr, swig_type_info *type, int newobject } Z_SET_REFCOUNT_P(z, 1); Z_SET_ISREF_P(z); - zend_hash_update(HASH_OF(z), (char*)"_cPtr", sizeof("_cPtr"), (void*)&resource, sizeof(zval), NULL); + zend_hash_update(HASH_OF(z), (char*)"_cPtr", sizeof("_cPtr"), (void*)&resource, sizeof(zval*), NULL); } return; } -- cgit v1.2.1 From acaaa0f31f9e843abd724d73212634a5e443a11d Mon Sep 17 00:00:00 2001 From: Ian Lance Taylor Date: Tue, 9 Sep 2014 11:28:04 -0700 Subject: [Go] Add goargout typemap. --- CHANGES.current | 3 + Doc/Manual/Go.html | 21 ++++ Examples/test-suite/go/go_inout_runme.go | 8 ++ Examples/test-suite/go_inout.i | 124 ++++++++++++++++++++++- Lib/go/go.swg | 6 +- Source/Modules/go.cxx | 168 ++++++++++++++++++++++++------- 6 files changed, 286 insertions(+), 44 deletions(-) diff --git a/CHANGES.current b/CHANGES.current index e9b9b71ea..4f2348419 100644 --- a/CHANGES.current +++ b/CHANGES.current @@ -5,6 +5,9 @@ See the RELEASENOTES file for a summary of changes in each release. Version 3.0.3 (in progress) =========================== +2014-09-09: ianlancetaylor + [Go] Add goargout typemap. + 2014-09-09: olly [PHP] Fix segmentation faults with directors in PHP >= 5.4, and reenable runme tests for director_basic testcase. Fix from diff --git a/Doc/Manual/Go.html b/Doc/Manual/Go.html index e991fa3bd..5ce76e8cd 100644 --- a/Doc/Manual/Go.html +++ b/Doc/Manual/Go.html @@ -773,6 +773,27 @@ to gotype. If this is not defined no conversion is done. + +argout + +C/C++ code to adjust an argument value when returning from a function. +This is called after the real C/C++ function has run. This uses the +internally generated C/C++ type, based on imtype. This is only useful +for a pointer type of some sort. If this is not defined nothing will +be done. + + + + +goargout + +Go code to adjust an argument value when returning from a function. +This is called after the real C/C++ function has run. The value will +be in imtype. This is only useful for a pointer type of some sort. +If this is not defined nothing will be done. + + + directorin diff --git a/Examples/test-suite/go/go_inout_runme.go b/Examples/test-suite/go/go_inout_runme.go index d288b31b1..13c429b87 100644 --- a/Examples/test-suite/go/go_inout_runme.go +++ b/Examples/test-suite/go/go_inout_runme.go @@ -32,4 +32,12 @@ func main() { fmt.Println("got", m, "want", want) panic(m) } + + a := []string{"a", "bc", "def"} + go_inout.DoubleArray(&a) + dwant := []string{"a", "bc", "def", "aa", "bcbc", "defdef"} + if !reflect.DeepEqual(a, dwant) { + fmt.Println("got", a, "want", dwant) + panic(a) + } } diff --git a/Examples/test-suite/go_inout.i b/Examples/test-suite/go_inout.i index 443ce6f8f..510ed68e0 100644 --- a/Examples/test-suite/go_inout.i +++ b/Examples/test-suite/go_inout.i @@ -1,9 +1,11 @@ -// Test the goin and goout typemaps. +// Test the goin, goout, and goargout typemaps. %module go_inout %{ #include +#include +#include %} %inline @@ -21,7 +23,7 @@ struct RetStruct { // Write a typemap that calls C++ by converting in and out of JSON. -%go_import("encoding/json") +%go_import("encoding/json", "bytes", "encoding/binary") %insert(go_header) %{ @@ -77,3 +79,121 @@ RetStruct Same(MyStruct s) } %} + +%inline +%{ + +struct MyArray { + std::vector strings; +}; + +static uint64_t getuint64(const char* s) { + uint64_t ret = 0; + for (int i = 0; i < 8; i++, s++) { + ret |= static_cast(*s) << i * 8; + } + return ret; +} + +static void putuint64(std::string *s, size_t off, uint64_t v) { + for (int i = 0; i < 8; i++) { + (*s)[off + i] = (v >> (i * 8)) & 0xff; + } +} + +%} + +%typemap(gotype) MyArray* "*[]string" + +%typemap(imtype) MyArray* "*string" + +// Encode the slice as a single string, with length prefixes. +%typemap(goin) MyArray* +%{ + { + var buf bytes.Buffer + bin := binary.LittleEndian + var b [8]byte + bin.PutUint64(b[:], uint64(len(*$input))) + buf.Write(b[:]) + for _, s := range *$input { + bin.PutUint64(b[:], uint64(len(s))) + buf.Write(b[:]) + buf.WriteString(s) + } + str := buf.String() + $result = &str + } +%} + +// Unpack the string holding the packed slice. +%typemap(in) MyArray* (MyArray t) +%{ + { + _gostring_ *s = $input; + const char *p = static_cast(s->p); + uint64_t len = getuint64(p); + p += 8; + t.strings.resize(len); + for (uint64_t i = 0; i < len; i++) { + uint64_t slen = getuint64(p); + p += 8; + t.strings[i].assign(p, slen); + p += slen; + } + $1 = &t; + } +%} + +// Pack the vector into a string. +%typemap(argout) MyArray* +%{ + { + size_t tot = 8; + std::vector::const_iterator p; + for (p = $1->strings.begin(); p != $1->strings.end(); ++p) { + tot += 8 + p->size(); + } + std::string str; + str.resize(tot); + putuint64(&str, 0, $1->strings.size()); + size_t off = 8; + for (p = $1->strings.begin(); p != $1->strings.end(); ++p) { + putuint64(&str, off, p->size()); + off += 8; + str.replace(off, p->size(), *p); + off += p->size(); + } + *$input = _swig_makegostring(str.data(), str.size()); + } +%} + +// Unpack the string into a []string. +%typemap(goargout) MyArray* +%{ + { + str := *$input + bin := binary.LittleEndian + size := bin.Uint64([]byte(str[:8])) + str = str[8:] + r := make([]string, size) + for i := range r { + len := bin.Uint64([]byte(str[:8])) + str = str[8:] + r[i] = str[:len] + str = str[len:] + } + *$1 = r + } + +%} + +%inline +%{ +void DoubleArray(MyArray* v) { + size_t size = v->strings.size(); + for (size_t i = 0; i < size; i++) { + v->strings.push_back(v->strings[i] + v->strings[i]); + } +} +%} diff --git a/Lib/go/go.swg b/Lib/go/go.swg index 0c03ae576..c680844c4 100644 --- a/Lib/go/go.swg +++ b/Lib/go/go.swg @@ -225,13 +225,13 @@ %{ $1 = *($&1_ltype)&$input; %} %typemap(out) SWIGTYPE * -%{ *($&1_ltype)&$result = $1; %} +%{ *($&1_ltype)&$result = ($1_ltype)$1; %} %typemap(directorin) SWIGTYPE * -%{ $input = ($1_ltype)$1; %} +%{ *($&1_ltype)&$input = ($1_ltype)$1; %} %typemap(directorout) SWIGTYPE * -%{ $result = ($1_ltype)$input; %} +%{ $result = *($&1_ltype)&$input; %} %apply SWIGTYPE * { SWIGTYPE *const } diff --git a/Source/Modules/go.cxx b/Source/Modules/go.cxx index 06b76d998..388014cc0 100644 --- a/Source/Modules/go.cxx +++ b/Source/Modules/go.cxx @@ -868,6 +868,7 @@ private: Swig_typemap_attach_parms("default", parms, dummy); Swig_typemap_attach_parms("gotype", parms, dummy); Swig_typemap_attach_parms("goin", parms, dummy); + Swig_typemap_attach_parms("goargout", parms, dummy); Swig_typemap_attach_parms("imtype", parms, dummy); int parm_count = emit_num_arguments(parms); int required_count = emit_num_required(parms); @@ -892,20 +893,25 @@ private: bool needs_wrapper = (gccgo_flag || receiver || is_constructor || is_destructor || parm_count > required_count); + bool has_goout = false; + if (goout) { + has_goout = true; + } + // See whether any of the function parameters are represented by // interface values. When calling the C++ code, we need to convert // back to a uintptr. - if (!needs_wrapper) { - Parm *p = parms; - for (int i = 0; i < parm_count; ++i) { - p = getParm(p); - String *ty = Getattr(p, "type"); - if (goTypeIsInterface(p, ty) || Getattr(p, "tmap:goin") != NULL) { - needs_wrapper = true; - break; - } - p = nextParm(p); + Parm *p = parms; + for (int i = 0; i < parm_count; ++i) { + p = getParm(p); + String *ty = Getattr(p, "type"); + if (Getattr(p, "tmap:goargout")) { + has_goout = true; + needs_wrapper = true; + } else if (goTypeIsInterface(p, ty) || Getattr(p, "tmap:goin")) { + needs_wrapper = true; } + p = nextParm(p); } if (goTypeIsInterface(n, result) || goout != NULL) { needs_wrapper = true; @@ -982,7 +988,7 @@ private: Printv(f_go_wrappers, "func ", NULL); - Parm *p = parms; + p = parms; int pi = 0; // Add the receiver if this is a method. @@ -1097,7 +1103,7 @@ private: } if (gccgo_flag) { - if (goout != NULL || is_constructor) { + if (has_goout || is_constructor) { Printv(call, "\tfunc() {\n", NULL); } Printv(call, "\tdefer SwigCgocallDone()\n", NULL); @@ -1143,6 +1149,7 @@ private: if ((i == 0 && is_destructor) || ((i > 0 || !receiver || base || is_constructor) && goTypeIsInterface(p, pt))) { Printv(call, ".Swigcptr()", NULL); } + Setattr(p, "emit:goinput", ln); } else { String *ivar = NewString(""); Printf(ivar, "_swig_i_%d", i); @@ -1154,19 +1161,22 @@ private: Printv(f_go_wrappers, goin, NULL); Delete(goin); Printv(call, ivar, NULL); + Setattr(p, "emit:goinput", ivar); } p = nextParm(p); } Printv(call, ")\n", NULL); - if (gccgo_flag && (goout != NULL || is_constructor)) { + if (gccgo_flag && (has_goout || is_constructor)) { Printv(call, "\t}()\n", NULL); } Printv(f_go_wrappers, call, NULL); Delete(call); + goargout(parms, parm_count); + if (need_return_var) { if (goout == NULL) { Printv(f_go_wrappers, "\treturn swig_r\n", NULL); @@ -1676,6 +1686,32 @@ private: } } + /* ----------------------------------------------------------------------- + * goargout() + * + * Handle Go argument output code if any. This is used for the Go + * function. This assumes that each parameter has an "emit:goinput" + * property with the name to use to refer to that parameter. + * ----------------------------------------------------------------------- */ + + void goargout(ParmList *parms, int parm_count) { + Parm *p = parms; + for (int i = 0; i < parm_count; ++i) { + p = getParm(p); + String *tm = Getattr(p, "tmap:goargout"); + if (!tm) { + p = nextSibling(p); + } else { + tm = Copy(tm); + Replaceall(tm, "$result", "swig_r"); + Replaceall(tm, "$input", Getattr(p, "emit:goinput")); + Printv(f_go_wrappers, tm, NULL); + Delete(tm); + p = Getattr(p, "tmap:goargout:next"); + } + } + } + /* ----------------------------------------------------------------------- * freearg() * @@ -3170,6 +3206,7 @@ private: Swig_typemap_attach_parms("directorargout", parms, w); Swig_typemap_attach_parms("godirectorin", parms, w); Swig_typemap_attach_parms("goin", parms, dummy); + Swig_typemap_attach_parms("goargout", parms, dummy); if (!is_ignored) { // We use an interface to see if this method is defined in Go. @@ -3282,16 +3319,29 @@ private: if (GetFlag(n, "abstract")) { Printv(f_go_wrappers, "\tpanic(\"call to pure virtual method\")\n", NULL); } else { + bool has_goout = false; String *goout = NULL; if (SwigType_type(result) != T_VOID) { Printv(f_go_wrappers, "\tvar swig_r ", goImType(n, result), "\n", NULL); goout = Swig_typemap_lookup("goout", n, "swig_r", NULL); + if (goout) { + has_goout = true; + } + } + + p = parms; + for (int i = 0; i < parm_count; ++i) { + p = getParm(p); + if (Getattr(p, "tmap:goargout")) { + has_goout = true; + } + p = nextParm(p); } String *call = NewString(""); if (gccgo_flag) { - if (goout != NULL) { + if (has_goout) { Printv(call, "\tfunc() {\n", NULL); } Printv(call, "\tdefer SwigCgocallDone()\n", NULL); @@ -3320,6 +3370,7 @@ private: if (goTypeIsInterface(p, pt)) { Printv(call, ".Swigcptr()", NULL); } + Setattr(p, "emit:goinput", ln); } else { String *ivar = NewString(""); Printf(ivar, "_swig_i_%d", i); @@ -3331,7 +3382,7 @@ private: Printv(f_go_wrappers, goin, NULL); Delete(goin); Printv(call, ivar, NULL); - Delete(ivar); + Setattr(p, "emit:goinput", ivar); } p = nextParm(p); @@ -3339,13 +3390,15 @@ private: Printv(call, ")\n", NULL); - if (gccgo_flag && goout != NULL) { + if (gccgo_flag && has_goout) { Printv(call, "\t}()\n", NULL); } Printv(f_go_wrappers, call, NULL); Delete(call); + goargout(parms, parm_count); + if (SwigType_type(result) != T_VOID) { if (goout == NULL) { Printv(f_go_wrappers, "\treturn swig_r\n", NULL); @@ -3526,6 +3579,7 @@ private: String *goin = Getattr(p, "tmap:goin"); if (goin == NULL) { Printv(call, ln, NULL); + Setattr(p, "emit:goinput", ln); } else { String *ivar = NewString(""); Printf(ivar, "_swig_i_%d", i); @@ -3537,7 +3591,7 @@ private: Printv(f_go_wrappers, goin, NULL); Delete(goin); Printv(call, ivar, NULL); - Delete(ivar); + Setattr(p, "emit:goinput", ivar); } Delete(ln); @@ -3554,6 +3608,8 @@ private: Printv(f_go_wrappers, call, NULL); Delete(call); + goargout(parms, parm_count); + if (SwigType_type(result) != T_VOID) { if (goout == NULL) { Printv(f_go_wrappers, "\treturn swig_r\n", NULL); @@ -3838,6 +3894,21 @@ private: Printv(w->code, " crosscall2(", callback_wname, ", &swig_a, (int) sizeof swig_a);\n", NULL); + /* Marshal outputs */ + for (p = parms; p;) { + String *tm; + if ((tm = Getattr(p, "tmap:directorargout"))) { + tm = Copy(tm); + Replaceall(tm, "$result", "jresult"); + Replaceall(tm, "$input", Getattr(p, "emit:directorinput")); + Printv(w->code, tm, "\n", NIL); + Delete(tm); + p = Getattr(p, "tmap:directorargout:next"); + } else { + p = nextSibling(p); + } + } + if (SwigType_type(result) != T_VOID) { String *result_str = NewString("c_result"); String *tm = Swig_typemap_lookup("directorout", n, result_str, NULL); @@ -3886,7 +3957,7 @@ private: String *pn = NewString("g"); Append(pn, Getattr(p, "lname")); - Setattr(p, "emit:input", pn); + Setattr(p, "emit:directorinput", pn); String *tm = gccgoCTypeForGoValue(n, Getattr(p, "type"), pn); Wrapper_add_local(w, pn, tm); @@ -3915,6 +3986,21 @@ private: } Printv(w->code, callback_wname, "(go_val", args, ");\n", NULL); + /* Marshal outputs */ + for (p = parms; p;) { + String *tm; + if ((tm = Getattr(p, "tmap:directorargout"))) { + tm = Copy(tm); + Replaceall(tm, "$result", "jresult"); + Replaceall(tm, "$input", Getattr(p, "emit:directorinput")); + Printv(w->code, tm, "\n", NIL); + Delete(tm); + p = Getattr(p, "tmap:directorargout:next"); + } else { + p = nextSibling(p); + } + } + if (SwigType_type(result) != T_VOID) { String *result_str = NewString("c_result"); String *tm = Swig_typemap_lookup("directorout", n, result_str, NULL); @@ -3933,21 +4019,6 @@ private: Delete(result_str); } } - - /* Marshal outputs */ - for (p = parms; p;) { - String *tm; - if ((tm = Getattr(p, "tmap:directorargout"))) { - tm = Copy(tm); - Replaceall(tm, "$result", "jresult"); - Replaceall(tm, "$input", Getattr(p, "emit:directorinput")); - Printv(w->code, tm, "\n", NIL); - Delete(tm); - p = Getattr(p, "tmap:directorargout:next"); - } else { - p = nextSibling(p); - } - } } else { assert(is_pure_virtual); Printv(w->code, " _swig_gopanic(\"call to pure virtual function ", Getattr(parent, "sym:name"), name, "\");\n", NULL); @@ -4990,6 +5061,17 @@ private: String *gcCTypeForGoValue(Node *n, SwigType *type, String *name) { bool is_interface; String *gt = goTypeWithInfo(n, type, true, &is_interface); + + String *tail = NewString(""); + SwigType *t = SwigType_typedef_resolve_all(type); + if (!SwigType_isreference(t)) { + while (Strncmp(gt, "*", 1) == 0) { + Replace(gt, "*", "", DOH_REPLACE_FIRST); + Printv(tail, "*", NULL); + } + } + Delete(t); + bool is_string = Strcmp(gt, "string") == 0; bool is_slice = Strncmp(gt, "[]", 2) == 0; bool is_function = Strcmp(gt, "_swig_fnptr") == 0; @@ -5017,18 +5099,21 @@ private: if (is_string) { // Note that we don't turn a reference to a string into a // pointer to a string. Strings are immutable anyhow. - ret = NewString("_gostring_ "); - Append(ret, name); + ret = NewString(""); + Printv(ret, "_gostring_", tail, " ", name, NULL); + Delete(tail); return ret; } else if (is_slice) { // Slices are always passed as a _goslice_, whether or not references // are involved. - ret = NewString("_goslice_ "); - Append(ret, name); + ret = NewString(""); + Printv(ret, "_goslice_", tail, " ", name, NULL); + Delete(tail); return ret; } else if (is_function || is_member) { - ret = NewString("void *"); - Append(ret, name); + ret = NewString(""); + Printv(ret, "void*", tail, " ", name, NULL); + Delete(tail); return ret; } else if (is_complex64) { ret = NewString("_Complex float "); @@ -5045,6 +5130,7 @@ private: SwigType_add_pointer(t); ret = SwigType_lstr(t, name); Delete(t); + Delete(tail); return ret; } else { SwigType *t = SwigType_typedef_resolve_all(type); @@ -5068,6 +5154,7 @@ private: } Delete(q); Delete(t); + Delete(tail); return ret; } } @@ -5100,14 +5187,17 @@ private: } else if (is_float64) { ret = NewString("double "); } else { + Delete(tail); return SwigType_lstr(type, name); } } + Append(ret, tail); if (SwigType_isreference(type)) { Append(ret, "* "); } Append(ret, name); + Delete(tail); return ret; } -- cgit v1.2.1 From 06b1157470457ef6fe85dab32c0a9c1a73aab520 Mon Sep 17 00:00:00 2001 From: Ian Lance Taylor Date: Wed, 10 Sep 2014 16:17:54 -0700 Subject: Make sure to give all parameters a local before adding all the new typemaps. Also mark C functions compiled by 6c and friends as nosplit. --- Source/Modules/go.cxx | 17 ++++++++++++----- 1 file changed, 12 insertions(+), 5 deletions(-) diff --git a/Source/Modules/go.cxx b/Source/Modules/go.cxx index 388014cc0..ea890285a 100644 --- a/Source/Modules/go.cxx +++ b/Source/Modules/go.cxx @@ -865,12 +865,21 @@ private: int goFunctionWrapper(Node *n, String *name, String *go_name, String *overname, String *wname, List *base, ParmList *parms, SwigType *result, bool is_static, bool *p_needs_wrapper) { Wrapper *dummy = NewWrapper(); emit_attach_parmmaps(parms, dummy); + + Parm *p = parms; + int parm_count = emit_num_arguments(parms); + for (int i = 0; i < parm_count; ++i) { + p = getParm(p); + Swig_cparm_name(p, i); + p = nextParm(p); + } + Swig_typemap_attach_parms("default", parms, dummy); Swig_typemap_attach_parms("gotype", parms, dummy); Swig_typemap_attach_parms("goin", parms, dummy); Swig_typemap_attach_parms("goargout", parms, dummy); Swig_typemap_attach_parms("imtype", parms, dummy); - int parm_count = emit_num_arguments(parms); + int required_count = emit_num_required(parms); String *receiver = class_receiver; @@ -901,7 +910,7 @@ private: // See whether any of the function parameters are represented by // interface values. When calling the C++ code, we need to convert // back to a uintptr. - Parm *p = parms; + p = parms; for (int i = 0; i < parm_count; ++i) { p = getParm(p); String *ty = Getattr(p, "type"); @@ -935,7 +944,6 @@ private: Printv(f_go_wrappers, "int", NULL); } Parm *p = getParm(parms); - Swig_cparm_name(p, 0); int i = 0; if (is_destructor) { if (parm_count > required_count) { @@ -956,8 +964,6 @@ private: } for (; i < parm_count; ++i) { p = getParm(p); - // Give the parameter a name we will use below. - Swig_cparm_name(p, i); if (i > 0 || (base && receiver) || parm_count > required_count) { Printv(f_go_wrappers, ", ", NULL); } @@ -1264,6 +1270,7 @@ private: } // \xc2\xb7 is UTF-8 for U+00B7 which is Unicode 'Middle Dot' + Printv(f->def, "#pragma textflag 7\n", NULL); Printv(f->def, "\xc2\xb7", fn_name, "(struct { void *x[(", parm_size, ") / SWIG_PARM_SIZE];} p)", NULL); Delete(fn_name); -- cgit v1.2.1 From fa94a29df4e332e42e91972888e6d17cbd4519c7 Mon Sep 17 00:00:00 2001 From: Olly Betts Date: Thu, 11 Sep 2014 12:13:12 -0300 Subject: Fix comment typo --- Examples/test-suite/director_abstract.i | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Examples/test-suite/director_abstract.i b/Examples/test-suite/director_abstract.i index cc9dca55a..7dfcc8984 100644 --- a/Examples/test-suite/director_abstract.i +++ b/Examples/test-suite/director_abstract.i @@ -156,7 +156,7 @@ namespace ns class Example3 { protected: - /* the default constructor is always emitter, even when protected, + /* the default constructor is always emitted, even when protected, having another public constructor, and 'dirprot' is not used. This is just for Java compatibility */ Example3() -- cgit v1.2.1 From e12322df865a17cc794b5cd4e9743f105b5a38bd Mon Sep 17 00:00:00 2001 From: Olly Betts Date: Thu, 11 Sep 2014 13:09:08 -0300 Subject: [PHP] Fix throwing a PHP exception through C++ from a subclassed director method - PHP NULL gets returned by the subclassed method in this case, so the directorout typemap needs to allow that (at least if an exception is active). --- CHANGES.current | 6 +++ Examples/test-suite/director_exception.i | 19 +++++++- .../test-suite/php/director_exception_runme.php | 53 +++++++++++++++++++++- Lib/php/php.swg | 8 ++-- 4 files changed, 80 insertions(+), 6 deletions(-) diff --git a/CHANGES.current b/CHANGES.current index 4f2348419..c1d93d57d 100644 --- a/CHANGES.current +++ b/CHANGES.current @@ -5,6 +5,12 @@ See the RELEASENOTES file for a summary of changes in each release. Version 3.0.3 (in progress) =========================== +2014-09-11: olly + [PHP] Fix throwing a PHP exception through C++ from a subclassed + director method - PHP NULL gets returned by the subclassed method + in this case, so the directorout typemap needs to allow that (at + least if an exception is active). + 2014-09-09: ianlancetaylor [Go] Add goargout typemap. diff --git a/Examples/test-suite/director_exception.i b/Examples/test-suite/director_exception.i index 3fd3e563c..8e56e5db6 100644 --- a/Examples/test-suite/director_exception.i +++ b/Examples/test-suite/director_exception.i @@ -106,7 +106,7 @@ Foo *launder(Foo *f) { %} %feature("director") Bar; - +%feature("director") ReturnAllTypes; %inline %{ struct Exception1 @@ -132,4 +132,21 @@ Foo *launder(Foo *f) { virtual std::string pang() throw () { return "Bar::pang()"; } }; + // Class to allow regression testing SWIG/PHP not checking if an exception + // had been thrown in directorout typemaps. + class ReturnAllTypes + { + public: + int call_int() { return return_int(); } + double call_double() { return return_double(); } + const char * call_const_char_star() { return return_const_char_star(); } + std::string call_std_string() { return return_std_string(); } + Bar call_Bar() { return return_Bar(); } + + virtual int return_int() { return 0; } + virtual double return_double() { return 0.0; } + virtual const char * return_const_char_star() { return ""; } + virtual std::string return_std_string() { return std::string(); } + virtual Bar return_Bar() { return Bar(); } + }; %} diff --git a/Examples/test-suite/php/director_exception_runme.php b/Examples/test-suite/php/director_exception_runme.php index 33e6e9b52..cb823214b 100644 --- a/Examples/test-suite/php/director_exception_runme.php +++ b/Examples/test-suite/php/director_exception_runme.php @@ -4,9 +4,9 @@ require "tests.php"; require "director_exception.php"; // No new functions -check::functions(array(foo_ping,foo_pong,launder,bar_ping,bar_pong,bar_pang)); +check::functions(array(foo_ping,foo_pong,launder,bar_ping,bar_pong,bar_pang,returnalltypes_return_int,returnalltypes_return_double,returnalltypes_return_const_char_star,returnalltypes_return_std_string,returnalltypes_return_bar)); // No new classes -check::classes(array(director_exception,Foo,Exception1,Exception2,Base,Bar)); +check::classes(array(director_exception,Foo,Exception1,Exception2,Base,Bar,ReturnAllTypes)); // now new vars check::globals(array()); @@ -74,5 +74,54 @@ try { } catch (Exception1 $e1) { } +// Check that we can throw exceptions from director methods (this didn't used +// to work in all cases, as the exception gets "set" in PHP and the method +// then returns PHP NULL, which the directorout template may fail to convert. + +class Bad extends ReturnAllTypes { + function return_int() { throw new Exception("bad int"); } + function return_double() { throw new Exception("bad double"); } + function return_const_char_star() { throw new Exception("bad const_char_star"); } + function return_std_string() { throw new Exception("bad std_string"); } + function return_Bar() { throw new Exception("bad Bar"); } +} + +$bad = new Bad(); + +try { + $bad->call_int(); + check::fail("Exception wasn't propagated from Bad::return_int()"); +} catch (Exception $e) { + check::equal($e->getMessage(), "bad int", "propagated exception incorrect"); +} + +try { + $bad->call_double(); + check::fail("Exception wasn't propagated from Bad::return_double()"); +} catch (Exception $e) { + check::equal($e->getMessage(), "bad double", "propagated exception incorrect"); +} + +try { + $bad->call_const_char_star(); + check::fail("Exception wasn't propagated from Bad::return_const_char_star()"); +} catch (Exception $e) { + check::equal($e->getMessage(), "bad const_char_star", "propagated exception incorrect"); +} + +try { + $bad->call_std_string(); + check::fail("Exception wasn't propagated from Bad::return_std_string()"); +} catch (Exception $e) { + check::equal($e->getMessage(), "bad std_string", "propagated exception incorrect"); +} + +try { + $bad->call_Bar(); + check::fail("Exception wasn't propagated from Bad::return_Bar()"); +} catch (Exception $e) { + check::equal($e->getMessage(), "bad Bar", "propagated exception incorrect"); +} + check::done(); ?> diff --git a/Lib/php/php.swg b/Lib/php/php.swg index afa047ef6..8b5fb7be3 100644 --- a/Lib/php/php.swg +++ b/Lib/php/php.swg @@ -93,10 +93,12 @@ %typemap(directorout) SWIGTYPE ($&1_ltype tmp) { - if(SWIG_ConvertPtr($input, (void **) &tmp, $&1_descriptor, 0) < 0 || tmp == NULL) { - SWIG_PHP_Error(E_ERROR, "Type error in argument $argnum of $symname. Expected $&1_descriptor"); + /* If exit was via exception, PHP NULL is returned so skip the conversion. */ + if (!EG(exception)) { + if(SWIG_ConvertPtr($input, (void **) &tmp, $&1_descriptor, 0) < 0 || tmp == NULL) + SWIG_PHP_Error(E_ERROR, "Type error in argument $argnum of $symname. Expected $&1_descriptor"); + $result = *tmp; } - $result = *tmp; } %typemap(in) SWIGTYPE *, -- cgit v1.2.1 From 1a99212c2c1f2c1819ae84fe553a27889be46791 Mon Sep 17 00:00:00 2001 From: Olly Betts Date: Fri, 12 Sep 2014 12:48:37 -0300 Subject: [PHP] Add support for specifying any PHP interfaces a wrapped class implements, e.g.: %typemap("phpinterfaces") MyIterator "Iterator"; --- CHANGES.current | 4 ++++ Doc/Manual/Contents.html | 1 + Doc/Manual/Php.html | 18 ++++++++++++++++++ Examples/test-suite/php/Makefile.in | 1 + Examples/test-suite/php/php_iterator_runme.php | 24 ++++++++++++++++++++++++ Examples/test-suite/php_iterator.i | 20 ++++++++++++++++++++ Source/Modules/php.cxx | 11 +++++++++++ 7 files changed, 79 insertions(+) create mode 100644 Examples/test-suite/php/php_iterator_runme.php create mode 100644 Examples/test-suite/php_iterator.i diff --git a/CHANGES.current b/CHANGES.current index c1d93d57d..4c8397e46 100644 --- a/CHANGES.current +++ b/CHANGES.current @@ -5,6 +5,10 @@ See the RELEASENOTES file for a summary of changes in each release. Version 3.0.3 (in progress) =========================== +2014-09-12: olly + [PHP] Add support for specifying any PHP interfaces a wrapped class + implements, e.g.: %typemap("phpinterfaces") MyIterator "Iterator"; + 2014-09-11: olly [PHP] Fix throwing a PHP exception through C++ from a subclassed director method - PHP NULL gets returned by the subclassed method diff --git a/Doc/Manual/Contents.html b/Doc/Manual/Contents.html index 0eba7c250..0d97e2803 100644 --- a/Doc/Manual/Contents.html +++ b/Doc/Manual/Contents.html @@ -1416,6 +1416,7 @@
  • Constructors and Destructors
  • Static Member Variables
  • Static Member Functions +
  • Specifying Implemented Interfaces
  • PHP Pragmas, Startup and Shutdown code diff --git a/Doc/Manual/Php.html b/Doc/Manual/Php.html index cc03f7498..684774d51 100644 --- a/Doc/Manual/Php.html +++ b/Doc/Manual/Php.html @@ -29,6 +29,7 @@
  • Constructors and Destructors
  • Static Member Variables
  • Static Member Functions +
  • Specifying Implemented Interfaces
  • PHP Pragmas, Startup and Shutdown code @@ -770,6 +771,23 @@ Ko::threats(); +

    34.2.6.5 Specifying Implemented Interfaces

    + +

    +PHP supports the concept of abstract interfaces which a class can implement. +Since SWIG 3.0.3, you can tell SWIG that a wrapped class (for example +MyIterator) implements the Iterator interface like +so: +

    + +
    +%typemap("phpinterfaces") MyIterator "Iterator";
    +
    + +

    +If there are multiple interfaces, just list them separated by commas. +

    +

    34.2.7 PHP Pragmas, Startup and Shutdown code

    diff --git a/Examples/test-suite/php/Makefile.in b/Examples/test-suite/php/Makefile.in index 00ccac325..c3f8af5cb 100644 --- a/Examples/test-suite/php/Makefile.in +++ b/Examples/test-suite/php/Makefile.in @@ -10,6 +10,7 @@ top_srcdir = @top_srcdir@ top_builddir = @top_builddir@ CPP_TEST_CASES += \ + php_iterator \ php_namewarn_rename \ include $(srcdir)/../common.mk diff --git a/Examples/test-suite/php/php_iterator_runme.php b/Examples/test-suite/php/php_iterator_runme.php new file mode 100644 index 000000000..d69a5b385 --- /dev/null +++ b/Examples/test-suite/php/php_iterator_runme.php @@ -0,0 +1,24 @@ + $v) { + $s .= "($k=>$v)"; +} +check::equal($s, '(0=>2)(1=>3)(2=>4)', 'Simple iteration failed'); + +check::done(); +?> diff --git a/Examples/test-suite/php_iterator.i b/Examples/test-suite/php_iterator.i new file mode 100644 index 000000000..43ab68b55 --- /dev/null +++ b/Examples/test-suite/php_iterator.i @@ -0,0 +1,20 @@ +/* php_iterator.i - PHP-specific testcase for wrapping to a PHP Iterator */ +%module php_iterator + +%typemap("phpinterfaces") MyIterator "Iterator"; + +%inline %{ + +class MyIterator { + int i, from, to; +public: + MyIterator(int from_, int to_) + : i(from_), from(from_), to(to_) { } + void rewind() { i = from; } + bool valid() const { return i != to; } + int key() const { return i - from; } + int current() const { return i; } + void next() { ++i; } +}; + +%} diff --git a/Source/Modules/php.cxx b/Source/Modules/php.cxx index f7e9994f0..b09dd09aa 100644 --- a/Source/Modules/php.cxx +++ b/Source/Modules/php.cxx @@ -2045,6 +2045,17 @@ done: } else if (GetFlag(n, "feature:exceptionclass")) { Append(s_phpclasses, "extends Exception "); } + { + Node *node = NewHash(); + Setattr(node, "type", Getattr(n, "name")); + Setfile(node, Getfile(n)); + Setline(node, Getline(n)); + String * interfaces = Swig_typemap_lookup("phpinterfaces", node, "", 0); + if (interfaces) { + Printf(s_phpclasses, "implements %s ", interfaces); + } + Delete(node); + } Printf(s_phpclasses, "{\n\tpublic $%s=null;\n", SWIG_PTR); if (!baseclass) { // Only store this in the base class (NB !baseclass means we *are* -- cgit v1.2.1 From 39433f12e40ae238efaeb668482b4387611d22bd Mon Sep 17 00:00:00 2001 From: Ian Lance Taylor Date: Fri, 12 Sep 2014 17:46:21 -0700 Subject: Fix one case where we test goout rather than has_goout. The effect was to incorrect use a return statement before the goout typemap code. --- Source/Modules/go.cxx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Source/Modules/go.cxx b/Source/Modules/go.cxx index ea890285a..c75a46b30 100644 --- a/Source/Modules/go.cxx +++ b/Source/Modules/go.cxx @@ -1095,7 +1095,7 @@ private: String *call = NewString(""); - bool need_return_var = SwigType_type(result) != T_VOID && ((gccgo_flag && is_constructor) || goout != NULL); + bool need_return_var = SwigType_type(result) != T_VOID && ((gccgo_flag && is_constructor) || has_goout); if (need_return_var) { Printv(f_go_wrappers, "\tvar swig_r ", NULL); if (is_constructor) { -- cgit v1.2.1 From 8128b1e12fbd055a4474df4af5c8f90fc655ee7f Mon Sep 17 00:00:00 2001 From: William S Fulton Date: Thu, 28 Aug 2014 07:42:46 +0100 Subject: For Android examples, replace hard coded tool names with those detected at configure time. --- Examples/Makefile.in | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/Examples/Makefile.in b/Examples/Makefile.in index 50b7ead03..b7dc7d101 100644 --- a/Examples/Makefile.in +++ b/Examples/Makefile.in @@ -738,10 +738,10 @@ javascript_clean: ##### ANDROID ###### ################################################################## -ANDROID = android -ANDROID_NDK_BUILD = ndk-build -ANDROID_ADB = adb -ANT = ant +ANDROID = @ANDROID@ +ANDROID_NDK_BUILD = @NDKBUILD@ +ANDROID_ADB = @ADB@ +ANT = @ANT@ TARGETID = 1 # ---------------------------------------------------------------- @@ -784,7 +784,7 @@ android_version: # ----------------------------------------------------------------- android_clean: - test -n "$(SRCDIR)" && cd $(SRCDIR) ; ant -q -logfile /dev/null clean + test -n "$(SRCDIR)" && cd $(SRCDIR) ; $(ANT) -q -logfile /dev/null clean rm -f $(INTERFACEDIR)$(TARGET)_wrap.* rm -f `find $(PACKAGEDIR) -name \*.java | grep -v $(PROJECTNAME).java` rm -rf obj -- cgit v1.2.1 From fea2fc137e2a1db8601e6af922838a71cc47596e Mon Sep 17 00:00:00 2001 From: William S Fulton Date: Tue, 16 Sep 2014 19:19:48 +0100 Subject: Suppress Octave failing the build li_std_vector testcase causing g++ internal compiler error --- .travis.yml | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/.travis.yml b/.travis.yml index 016f704ce..8521e0cc6 100644 --- a/.travis.yml +++ b/.travis.yml @@ -47,7 +47,9 @@ matrix: - compiler: gcc env: SWIGLANG=tcl allow_failures: - # None + # g++-4.6.3 internal compiler error for li_std_vector testcase + - compiler: gcc + env: SWIGLANG=octave SWIGJOBS=-j4 before_install: - date -u - uname -a -- cgit v1.2.1 From 11d07bb45bdec6fcdaff87ffdb43ff4e30639936 Mon Sep 17 00:00:00 2001 From: Richard Pastrick Date: Tue, 16 Sep 2014 13:02:27 -0700 Subject: add bool array type to arrays_csharp.i [issue #228] --- Lib/csharp/arrays_csharp.i | 2 ++ 1 file changed, 2 insertions(+) diff --git a/Lib/csharp/arrays_csharp.i b/Lib/csharp/arrays_csharp.i index 174a2823e..237067a88 100644 --- a/Lib/csharp/arrays_csharp.i +++ b/Lib/csharp/arrays_csharp.i @@ -103,6 +103,7 @@ CSHARP_ARRAYS(long long, long) CSHARP_ARRAYS(unsigned long long, ulong) CSHARP_ARRAYS(float, float) CSHARP_ARRAYS(double, double) +CSHARP_ARRAYS(bool, bool) %define CSHARP_ARRAYS_FIXED( CTYPE, CSTYPE ) @@ -134,4 +135,5 @@ CSHARP_ARRAYS_FIXED(long long, long) CSHARP_ARRAYS_FIXED(unsigned long long, ulong) CSHARP_ARRAYS_FIXED(float, float) CSHARP_ARRAYS_FIXED(double, double) +CSHARP_ARRAYS_FIXED(bool, bool) -- cgit v1.2.1 From 15152596f2b2829ec8188131015854c8cc532b9a Mon Sep 17 00:00:00 2001 From: William S Fulton Date: Wed, 17 Sep 2014 22:19:07 +0100 Subject: Change file for #228 and #229 --- CHANGES.current | 3 +++ 1 file changed, 3 insertions(+) diff --git a/CHANGES.current b/CHANGES.current index 4c8397e46..d5dcb05f6 100644 --- a/CHANGES.current +++ b/CHANGES.current @@ -5,6 +5,9 @@ See the RELEASENOTES file for a summary of changes in each release. Version 3.0.3 (in progress) =========================== +2014-09-17: wsfulton + [C#] Merge patch #229 from contre - Add bool array types to arrays_csharp.i + 2014-09-12: olly [PHP] Add support for specifying any PHP interfaces a wrapped class implements, e.g.: %typemap("phpinterfaces") MyIterator "Iterator"; -- cgit v1.2.1 From 783e816d89ccd17b0820e50c7943e5b4e39bc973 Mon Sep 17 00:00:00 2001 From: William S Fulton Date: Tue, 23 Sep 2014 19:54:13 +0100 Subject: Testcase warning suppression --- Examples/test-suite/director_exception.i | 3 +++ 1 file changed, 3 insertions(+) diff --git a/Examples/test-suite/director_exception.i b/Examples/test-suite/director_exception.i index 8e56e5db6..43aeea22a 100644 --- a/Examples/test-suite/director_exception.i +++ b/Examples/test-suite/director_exception.i @@ -1,5 +1,7 @@ %module(directors="1") director_exception +%warnfilter(SWIGWARN_TYPEMAP_DIRECTOROUT_PTR) return_const_char_star; + %{ #if defined(_MSC_VER) @@ -148,5 +150,6 @@ Foo *launder(Foo *f) { virtual const char * return_const_char_star() { return ""; } virtual std::string return_std_string() { return std::string(); } virtual Bar return_Bar() { return Bar(); } + virtual ~ReturnAllTypes() {} }; %} -- cgit v1.2.1 From de6b433cb178c2e4b7b2f3c7dfc02a90ddedfccf Mon Sep 17 00:00:00 2001 From: Thomas Maslach Date: Tue, 23 Sep 2014 20:22:20 +0100 Subject: Fix Python crash when using -threads iterating containers MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Also fixes li_std_vector_enum testcase when run with -threads. Patch supplied on swig-devel mailing list on 12 Sep with details... ============================================== I just wanted to mention that I found a crash issue in bug.. I am using SWIG 2.0.11 with python and have –threads enabled. I have a C++ std::vector that I instantiate in SWIG with %template. I also have a method in a class that returns this vector. I also include std_vector.i, btw.. When I iterate like so: children = Action.getActionList() for child in children: pass Everything is fine.. When I iterate like this: for child in Action.getActionList() pass Product crashes. The problem is the following. This code gets called first: SWIGINTERN PyObject *_wrap_delete_SwigPyIterator(PyObject *SWIGUNUSEDPARM(self), PyObject *args) { PyObject *resultobj = 0; swig::SwigPyIterator *arg1 = (swig::SwigPyIterator *) 0 ; void *argp1 = 0 ; int res1 = 0 ; PyObject * obj0 = 0 ; if(!PyArg_UnpackTuple(args,(char *)"delete_SwigPyIterator",1,1,&obj0)) SWIG_fail; res1 = SWIG_ConvertPtr(obj0, &argp1,SWIGTYPE_p_swig__SwigPyIterator, SWIG_POINTER_DISOWN | 0 ); if (!SWIG_IsOK(res1)) { SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "delete_SwigPyIterator" "', argument " "1"" of type '" "swig::SwigPyIterator *""'"); } arg1 = reinterpret_cast< swig::SwigPyIterator * >(argp1); { SWIG_PYTHON_THREAD_BEGIN_ALLOW; delete arg1; SWIG_PYTHON_THREAD_END_ALLOW; } resultobj = SWIG_Py_Void(); return resultobj; fail: return NULL; } Note the SWIG_PYTHON_THREAD_BEGIN_ALLOW/END_ALLOW. In between those two statements, we delete arg1. That in turn will eventually end up in this code: namespace swig { class SwigPtr_PyObject { protected: PyObject *_obj; public: … snip! … ~SwigPtr_PyObject() { Py_XDECREF(_obj); } Uh-oh! We call Py_XDECREF when we aren’t supposed to because we are in a SWIG_PYTHON_THREAD_BEGIN_ALLOW/END_ALLOW section! This takes care of the issue: namespace swig { class SwigPtr_PyObject { protected: PyObject *_obj; public: … snip! … ~SwigPtr_PyObject() { SWIG_PYTHON_THREAD_BEGIN_BLOCK; Py_XDECREF(_obj); SWIG_PYTHON_THREAD_END_BLOCK; } There are several other methods in this class that use the Python API, but don’t have the BEGIN/END block defined. I’m not sure if they are required for all of them, but I believe they are.. I have attached a modified pyclasses.swg with what I believe are the correct changes. This code is from 2.0.11, but as far as I can tell, it’s the same as what is in 3.0.2… Apologies for not doing more here (making/running tests, getting it in the code repository, etc..), but I’m under some pressure to get some unrelated things done… --- CHANGES.current | 4 +++ Examples/test-suite/python/python_threads_runme.py | 10 ++++++ Examples/test-suite/python_threads.i | 40 ++++++++++++++++++++++ Lib/python/pyclasses.swg | 8 +++++ 4 files changed, 62 insertions(+) create mode 100644 Examples/test-suite/python/python_threads_runme.py create mode 100644 Examples/test-suite/python_threads.i diff --git a/CHANGES.current b/CHANGES.current index d5dcb05f6..781b21c1c 100644 --- a/CHANGES.current +++ b/CHANGES.current @@ -5,6 +5,10 @@ See the RELEASENOTES file for a summary of changes in each release. Version 3.0.3 (in progress) =========================== +2014-09-23: wsfulton + [Python] Add patch from Thomas Maslach to fix crash in wrappers when using -threads in + the STL iterators (SwigPyIterator destructor). + 2014-09-17: wsfulton [C#] Merge patch #229 from contre - Add bool array types to arrays_csharp.i diff --git a/Examples/test-suite/python/python_threads_runme.py b/Examples/test-suite/python/python_threads_runme.py new file mode 100644 index 000000000..d00e2458f --- /dev/null +++ b/Examples/test-suite/python/python_threads_runme.py @@ -0,0 +1,10 @@ +from python_threads import * + +action = ActionGroup() +count = 1 +for child in action.GetActionList(): + if child.val != count: + raise RuntimeError("Expected: " + str(count) + " got: " + str(child.val)) + count = count + 1 + +# Was seg faulting at the end here diff --git a/Examples/test-suite/python_threads.i b/Examples/test-suite/python_threads.i new file mode 100644 index 000000000..08eddef11 --- /dev/null +++ b/Examples/test-suite/python_threads.i @@ -0,0 +1,40 @@ +%module(threads=1) python_threads + +%include + +%inline %{ +struct Action { + int val; + Action(int val = 0) : val(val) {} +}; +%} + +%template(VectorActionPtr) std::vector; + +%inline %{ +#include +#include +template struct myStlVector : public std::vector { +}; +typedef myStlVector ActionList; + +%} + +%template(ActionList) myStlVector; + +%inline %{ +class ActionGroup +{ +public: + ActionList &GetActionList () const { + static ActionList list; + list.push_back(new Action(1)); + list.push_back(new Action(2)); + list.push_back(new Action(3)); + list.push_back(new Action(4)); + return list; + } +}; +%} + + diff --git a/Lib/python/pyclasses.swg b/Lib/python/pyclasses.swg index b73ebdbb8..9d6299ff1 100644 --- a/Lib/python/pyclasses.swg +++ b/Lib/python/pyclasses.swg @@ -72,27 +72,35 @@ namespace swig { SwigPtr_PyObject(const SwigPtr_PyObject& item) : _obj(item._obj) { + SWIG_PYTHON_THREAD_BEGIN_BLOCK; Py_XINCREF(_obj); + SWIG_PYTHON_THREAD_END_BLOCK; } SwigPtr_PyObject(PyObject *obj, bool initial_ref = true) :_obj(obj) { if (initial_ref) { + SWIG_PYTHON_THREAD_BEGIN_BLOCK; Py_XINCREF(_obj); + SWIG_PYTHON_THREAD_END_BLOCK; } } SwigPtr_PyObject & operator=(const SwigPtr_PyObject& item) { + SWIG_PYTHON_THREAD_BEGIN_BLOCK; Py_XINCREF(item._obj); Py_XDECREF(_obj); _obj = item._obj; + SWIG_PYTHON_THREAD_END_BLOCK; return *this; } ~SwigPtr_PyObject() { + SWIG_PYTHON_THREAD_BEGIN_BLOCK; Py_XDECREF(_obj); + SWIG_PYTHON_THREAD_END_BLOCK; } operator PyObject *() const -- cgit v1.2.1 From 4b64ce71a365d6734ca54673300d44d0d597762c Mon Sep 17 00:00:00 2001 From: Ian Lance Taylor Date: Thu, 25 Sep 2014 12:10:11 -0700 Subject: [Go] Adjust generated code to work with upcoming Go 1.4 release. --- CHANGES.current | 4 + Lib/go/goruntime.swg | 23 ++++- Source/Modules/go.cxx | 270 ++++++++++++++++++++++++++------------------------ 3 files changed, 162 insertions(+), 135 deletions(-) diff --git a/CHANGES.current b/CHANGES.current index 781b21c1c..ab78637f9 100644 --- a/CHANGES.current +++ b/CHANGES.current @@ -5,6 +5,10 @@ See the RELEASENOTES file for a summary of changes in each release. Version 3.0.3 (in progress) =========================== +2014-09-25: ianlancetaylor + [Go] Adjust generated code to work with upcoming Go 1.4 + release. + 2014-09-23: wsfulton [Python] Add patch from Thomas Maslach to fix crash in wrappers when using -threads in the STL iterators (SwigPyIterator destructor). diff --git a/Lib/go/goruntime.swg b/Lib/go/goruntime.swg index bbc602b0d..a61837074 100644 --- a/Lib/go/goruntime.swg +++ b/Lib/go/goruntime.swg @@ -57,12 +57,21 @@ swiggo_size_assert(double, 8) extern "C" { #endif extern void crosscall2(void (*fn)(void *, int), void *, int); +extern char* _cgo_topofstack(void) __attribute__ ((weak)); extern void _cgo_allocate(void *, int); extern void _cgo_panic(void *, int); #ifdef __cplusplus } #endif +static char *_swig_topofstack() { + if (_cgo_topofstack) { + return _cgo_topofstack(); + } else { + return 0; + } +} + static void *_swig_goallocate(size_t len) { struct { size_t len; @@ -89,11 +98,11 @@ static void _swig_gopanic(const char *p) { #include "runtime.h" #include "cgocall.h" -#ifdef _64BIT -#define SWIG_PARM_SIZE 8 -#else -#define SWIG_PARM_SIZE 4 -#endif +#pragma dataflag 16 +static void *cgocall = runtime·cgocall; +#pragma dataflag 16 +void *·_cgo_runtime_cgocall = &cgocall; + %} #else @@ -194,6 +203,10 @@ static _gostring_ _swig_makegostring(const char *p, size_t l) { %go_import("unsafe", _ "runtime/cgo") +%insert(go_header) %{ +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) +%} + #else %go_import("syscall", "unsafe") diff --git a/Source/Modules/go.cxx b/Source/Modules/go.cxx index c75a46b30..c9910ab05 100644 --- a/Source/Modules/go.cxx +++ b/Source/Modules/go.cxx @@ -822,14 +822,13 @@ private: assert(result); - bool needs_wrapper; - int r = goFunctionWrapper(n, name, go_name, overname, wname, base, parms, result, is_static, &needs_wrapper); + int r = goFunctionWrapper(n, name, go_name, overname, wname, base, parms, result, is_static); if (r != SWIG_OK) { return r; } if (!gccgo_flag) { - r = gcFunctionWrapper(n, name, go_name, overname, wname, parms, result, is_static, needs_wrapper); + r = gcFunctionWrapper(wname); if (r != SWIG_OK) { return r; } @@ -862,7 +861,7 @@ private: * base class. * ---------------------------------------------------------------------- */ - int goFunctionWrapper(Node *n, String *name, String *go_name, String *overname, String *wname, List *base, ParmList *parms, SwigType *result, bool is_static, bool *p_needs_wrapper) { + int goFunctionWrapper(Node *n, String *name, String *go_name, String *overname, String *wname, List *base, ParmList *parms, SwigType *result, bool is_static) { Wrapper *dummy = NewWrapper(); emit_attach_parmmaps(parms, dummy); @@ -926,7 +925,9 @@ private: needs_wrapper = true; } - *p_needs_wrapper = needs_wrapper; + if (!gccgo_flag) { + Printv(f_go_wrappers, "var ", wname, " unsafe.Pointer\n\n", NULL); + } // If this is a method, first declare the C function we will call. // If we do not need a wrapper, then we will only be writing a @@ -939,9 +940,10 @@ private: Printv(f_go_wrappers, "//extern ", go_prefix, "_", wname, "\n", NULL); } + bool arg = false; Printv(f_go_wrappers, "func ", wrapper_name, "(", NULL); if (parm_count > required_count) { - Printv(f_go_wrappers, "int", NULL); + Printv(f_go_wrappers, argName(&arg), " int", NULL); } Parm *p = getParm(parms); int i = 0; @@ -949,14 +951,14 @@ private: if (parm_count > required_count) { Printv(f_go_wrappers, ", ", NULL); } - Printv(f_go_wrappers, "uintptr", NULL); + Printv(f_go_wrappers, argName(&arg), " uintptr", NULL); ++i; p = nextParm(p); } else if (receiver && (base || !is_constructor)) { if (parm_count > required_count) { Printv(f_go_wrappers, ", ", NULL); } - Printv(f_go_wrappers, receiver, NULL); + Printv(f_go_wrappers, argName(&arg), " ", receiver, NULL); if (!base) { ++i; p = nextParm(p); @@ -968,21 +970,33 @@ private: Printv(f_go_wrappers, ", ", NULL); } String *tm = goWrapperType(p, Getattr(p, "type"), false); - Printv(f_go_wrappers, tm, NULL); + Printv(f_go_wrappers, argName(&arg), " ", tm, NULL); Delete(tm); p = nextParm(p); } Printv(f_go_wrappers, ")", NULL); if (is_constructor) { - Printv(f_go_wrappers, " ", class_receiver, NULL); + Printv(f_go_wrappers, " (", argName(&arg), " ", class_receiver, ")", NULL); } else { if (SwigType_type(result) != T_VOID) { String *tm = goWrapperType(n, result, true); - Printv(f_go_wrappers, " ", tm, NULL); + Printv(f_go_wrappers, " (", argName(&arg), " ", tm, ")", NULL); Delete(tm); } } + if (!gccgo_flag) { + Printv(f_go_wrappers, " {\n", NULL); + if (arg) { + Printv(f_go_wrappers, "\t_swig_p := uintptr(unsafe.Pointer(&base))\n", NULL); + } else { + Printv(f_go_wrappers, "\tvar _swig_p uintptr\n", NULL); + } + Printv(f_go_wrappers, "\t_cgo_runtime_cgocall(", wname, ", _swig_p)\n", NULL); + Printv(f_go_wrappers, "\treturn\n", NULL); + Printv(f_go_wrappers, "}", NULL); + } + Printv(f_go_wrappers, "\n\n", NULL); } @@ -998,12 +1012,19 @@ private: int pi = 0; // Add the receiver if this is a method. + String *first = NULL; if (receiver) { Printv(f_go_wrappers, "(", NULL); if (base && receiver) { Printv(f_go_wrappers, "_swig_base", NULL); + if (first == NULL) { + first = NewString("_swig_base"); + } } else { Printv(f_go_wrappers, Getattr(p, "lname"), NULL); + if (first == NULL) { + first = Copy(Getattr(p, "lname")); + } p = nextParm(p); ++pi; } @@ -1031,6 +1052,9 @@ private: if (pi == 0 && is_destructor) { String *cl = exportedName(class_name); Printv(parm_print, Getattr(p, "lname"), " ", cl, NULL); + if (first == NULL) { + first = Copy(Getattr(p, "lname")); + } Delete(cl); } else { if (pi > (receiver && !base ? 1 : 0)) { @@ -1038,10 +1062,14 @@ private: } if (pi >= required_count) { Printv(parm_print, "_swig_args ...interface{}", NULL); + if (first == NULL) { + first = NewString("_swig_args"); + } break; } - if (needs_wrapper) { - Printv(parm_print, Getattr(p, "lname"), " ", NULL); + Printv(parm_print, Getattr(p, "lname"), " ", NULL); + if (first == NULL) { + first = Copy(Getattr(p, "lname")); } String *tm = goType(p, Getattr(p, "type")); Printv(parm_print, tm, NULL); @@ -1055,12 +1083,18 @@ private: // Write out the result type. if (is_constructor) { String *cl = exportedName(class_name); - Printv(parm_print, " ", cl, NULL); + Printv(parm_print, " (_swig_ret ", cl, ")", NULL); + if (first == NULL) { + first = NewString("_swig_ret"); + } Delete(cl); } else { if (SwigType_type(result) != T_VOID) { String *tm = goType(n, result); - Printv(parm_print, " ", tm, NULL); + Printv(parm_print, " (_swig_ret ", tm, ")", NULL); + if (first == NULL) { + first = NewString("_swig_ret"); + } Delete(tm); } } @@ -1197,6 +1231,20 @@ private: } Printv(f_go_wrappers, "}\n", NULL); + } else if (!gccgo_flag) { + // We don't need a wrapper. If we're using gccgo, the function + // declaration is all we need--it has a //extern comment to + // GCC-compiled wrapper. If we're not using gccgo, we need to + // call the GCC-compiled wrapper here. + Printv(f_go_wrappers, " {\n", NULL); + if (first == NULL) { + Printv(f_go_wrappers, "\tvar _swig_p uintptr\n", NULL); + } else { + Printv(f_go_wrappers, "\t_swig_p := uintptr(unsafe.Pointer(&", first, "))\n", NULL); + } + Printv(f_go_wrappers, "\t_cgo_runtime_cgocall(", wname, ", _swig_p)\n", NULL); + Printv(f_go_wrappers, "\treturn\n", NULL); + Printv(f_go_wrappers, "}", NULL); } Printv(f_go_wrappers, "\n", NULL); @@ -1207,119 +1255,47 @@ private: return SWIG_OK; } + /* ---------------------------------------------------------------------- + * argName() + * + * A helper for goFunctionWrapper to output the first argument name + * as "base" and all others as "_". + * ---------------------------------------------------------------------- */ + + const char *argName(bool *arg) { + if (*arg) { + return "_"; + } + *arg = true; + return "base"; + } + /* ---------------------------------------------------------------------- * gcFunctionWrapper() * * This is used for 6g/8g, not for gccgo. Write out the function - * wrapper which will be compiled with 6c/8c. + * redirector that will be compiled with 6c/8c. This used to write + * out a real function wrapper, but that has moved into Go code. * ---------------------------------------------------------------------- */ - int gcFunctionWrapper(Node *n, String *name, String *go_name, String *overname, String *wname, ParmList *parms, SwigType *result, bool is_static, bool needs_wrapper) { + int gcFunctionWrapper(String *wname) { Wrapper *f = NewWrapper(); Printv(f->def, "#pragma dynimport ", wname, " ", wname, " \"\"\n", NULL); Printv(f->def, "#pragma cgo_import_static ", wname, "\n", NULL); - Printv(f->def, "extern void (*", wname, ")(void*);\n", NULL); - Printv(f->def, "static void (*x", wname, ")(void*) = ", wname, ";\n", NULL); - Printv(f->def, "\n", NULL); - Printv(f->def, "void\n", NULL); - - Wrapper *dummy = NewWrapper(); - emit_attach_parmmaps(parms, dummy); - Swig_typemap_attach_parms("default", parms, dummy); - Swig_typemap_attach_parms("gosize", parms, dummy); - int parm_count = emit_num_arguments(parms); - int required_count = emit_num_required(parms); - - String *parm_size = NewString(""); - - if (parm_count > required_count) { - Append(parm_size, "SWIG_PARM_SIZE"); - } - - if (class_receiver && !is_static) { - if (Len(parm_size) > 0) { - Append(parm_size, " + "); - } - Append(parm_size, "SWIG_PARM_SIZE"); - } - - Parm *p = parms; - for (int i = 0; i < parm_count; ++i) { - p = getParm(p); - addGcTypeSize(p, Getattr(p, "type"), parm_size); - p = nextParm(p); - } - - if (SwigType_type(result) != T_VOID) { - addGcTypeSize(n, result, parm_size); - } - - if (Len(parm_size) == 0) { - Append(parm_size, "SWIG_PARM_SIZE"); - } - - String *fn_name; - if (!needs_wrapper) { - fn_name = Copy(go_name); - if (overname) { - Append(fn_name, overname); - } - } else { - fn_name = buildGoWrapperName(name, overname); - } - + Printv(f->def, "extern void ", wname, "(void*);\n", NULL); + // Declare this as a uintptr, since it is not a pointer into the + // Go heap. // \xc2\xb7 is UTF-8 for U+00B7 which is Unicode 'Middle Dot' - Printv(f->def, "#pragma textflag 7\n", NULL); - Printv(f->def, "\xc2\xb7", fn_name, "(struct { void *x[(", parm_size, ") / SWIG_PARM_SIZE];} p)", NULL); - - Delete(fn_name); - Delete(parm_size); - - Printv(f->code, "{\n", NULL); - Printv(f->code, "\truntime\xc2\xb7" "cgocall(x", wname, ", &p);\n", NULL); - Printv(f->code, "}\n", NULL); - Printv(f->code, "\n", NULL); + Printv(f->def, "uintptr \xc2\xb7", wname, " = (uintptr)", wname, ";\n", NULL); Wrapper_print(f, f_gc_wrappers); DelWrapper(f); - DelWrapper(dummy); return SWIG_OK; } - /* ---------------------------------------------------------------------- - * getGcTypeSize() - * - * Return the size to use when passing a type from 6g/8g to 6c/8c. - * ---------------------------------------------------------------------- */ - - String *addGcTypeSize(Node *n, SwigType *type, String *orig) { - if (Len(orig) > 0) { - Append(orig, " + "); - } - - String *go = goType(n, type); - if (Cmp(go, "string") == 0) { - // A string has a pointer and a length. - Append(orig, "(2 * SWIG_PARM_SIZE)"); - } else if (Strncmp(go, "[]", 2) == 0) { - // A slice has a pointer, a length, and a capacity. - Append(orig, "(3 * SWIG_PARM_SIZE)"); - } else if (Strcmp(go, "float64") == 0) { - Append(orig, "8"); - } else if (Strcmp(go, "complex64") == 0) { - Append(orig, "8"); - } else if (Strcmp(go, "complex128") == 0) { - Append(orig, "16"); - } else { - Append(orig, "SWIG_PARM_SIZE"); - } - - return orig; - } - /* ---------------------------------------------------------------------- * gccFunctionWrapper() * @@ -1380,6 +1356,12 @@ private: Delete(ln); Printv(f->code, "\t\t", ct, ";\n", NULL); Delete(ct); + + ln = NewString("_swig_go_result"); + ct = gcCTypeForGoValue(n, result, ln); + Wrapper_add_local(f, "_swig_go_result", ct); + Delete(ct); + Delete(ln); } Printv(f->code, "\t} *swig_a = (struct swigargs *) swig_v;\n", NULL); @@ -1517,9 +1499,9 @@ private: Delete(fndef); if (SwigType_type(result) != T_VOID) { - String *ln = NewString("go_result"); + String *ln = NewString("_swig_go_result"); String *ct = gccgoCTypeForGoValue(n, result, ln); - Wrapper_add_local(f, "go_result", ct); + Wrapper_add_local(f, "_swig_go_result", ct); Delete(ct); Delete(ln); } @@ -1568,7 +1550,7 @@ private: cleanupFunction(n, f, parms); if (SwigType_type(result) != T_VOID) { - Printv(f->code, " return go_result;\n", NULL); + Printv(f->code, " return _swig_go_result;\n", NULL); } Printv(f->code, "}\n", NULL); @@ -1614,6 +1596,10 @@ private: * ----------------------------------------------------------------------- */ void emitGoAction(Node *n, List *base, ParmList *parms, SwigType *result, Wrapper *f) { + if (!gccgo_flag && SwigType_type(result) != T_VOID) { + Wrapper_add_local(f, "swig_stktop", "char *swig_stktop"); + Printv(f->code, "\tswig_stktop = _swig_topofstack();\n", NULL); + } String *actioncode; if (!base || isStatic(n)) { Swig_director_emit_dynamic_cast(n, f); @@ -1650,12 +1636,7 @@ private: if (!tm) { Swig_warning(WARN_TYPEMAP_OUT_UNDEF, input_file, line_number, "Unable to use return type %s\n", SwigType_str(result, 0)); } else { - if (!gccgo_flag) { - static const String *swig_a_result = NewStringf("swig_a->%s", Swig_cresult_name()); - Replaceall(tm, "$result", swig_a_result); - } else { - Replaceall(tm, "$result", "go_result"); - } + Replaceall(tm, "$result", "_swig_go_result"); if (GetFlag(n, "feature:new")) { Replaceall(tm, "$owner", "1"); } else { @@ -1665,6 +1646,14 @@ private: Delete(tm); } + if (!gccgo_flag && SwigType_type(result) != T_VOID) { + // If the function called back into the Go code, the stack might + // have been copied. We need to adjust swig_a accordingly here. + // This is what cgo does. + Printv(f->code, "\tswig_a = (struct swigargs*)((char*)swig_a + (_swig_topofstack() - swig_stktop));\n", NULL); + Printv(f->code, "\tswig_a->", Swig_cresult_name(), " = ", "_swig_go_result;\n", NULL); + } + Swig_restore(n); } @@ -2754,7 +2743,9 @@ private: if (!is_ignored) { // Declare the C++ wrapper. - if (gccgo_flag) { + if (!gccgo_flag) { + Printv(f_go_wrappers, "var ", wname, " unsafe.Pointer\n\n", NULL); + } else { Printv(f_go_wrappers, "//extern ", go_prefix, "_", wname, "\n", NULL); } @@ -2762,18 +2753,28 @@ private: if (overname) { Printv(f_go_wrappers, overname, NULL); } - Printv(f_go_wrappers, "(*", director_struct_name, NULL); + Printv(f_go_wrappers, "(_swig_director *", director_struct_name, NULL); p = parms; for (int i = 0; i < parm_count; ++i) { p = getParm(p); String *tm = goType(p, Getattr(p, "type")); - Printv(f_go_wrappers, ", ", tm, NULL); + Printv(f_go_wrappers, ", _ ", tm, NULL); Delete(tm); p = nextParm(p); } - Printv(f_go_wrappers, ") ", go_type_name, "\n\n", NULL); + Printv(f_go_wrappers, ") (_swig_ret ", go_type_name, ")", NULL); + + if (!gccgo_flag) { + Printv(f_go_wrappers, " {\n", NULL); + Printv(f_go_wrappers, "\t_swig_p := uintptr(unsafe.Pointer(&_swig_director))\n", NULL); + Printv(f_go_wrappers, "\t_cgo_runtime_cgocall(", wname, ", _swig_p)\n", NULL); + Printv(f_go_wrappers, "\treturn\n", NULL); + Printv(f_go_wrappers, "}", NULL); + } + + Printv(f_go_wrappers, "\n\n", NULL); Printv(f_go_wrappers, "func ", func_with_over_name, "(v interface{}", NULL); @@ -2842,8 +2843,7 @@ private: Setattr(n, "wrap:action", action); if (!gccgo_flag) { - int r = gcFunctionWrapper(n, fn_name, fn_name, overname, wname, - first_parm, result, is_static, false); + int r = gcFunctionWrapper(wname); if (r != SWIG_OK) { return r; } @@ -3247,17 +3247,19 @@ private: // Declare the upcall function, which calls the method on the // parent class. - if (gccgo_flag) { + if (!gccgo_flag) { + Printv(f_go_wrappers, "var ", upcall_wname, " unsafe.Pointer\n\n", NULL); + } else { Printv(f_go_wrappers, "//extern ", go_prefix, "_", upcall_wname, "\n", NULL); } - Printv(f_go_wrappers, "func ", upcall_gc_name, "(", go_type_name, NULL); + Printv(f_go_wrappers, "func ", upcall_gc_name, "(_swig_ptr ", go_type_name, NULL); p = parms; for (int i = 0; i < parm_count; ++i) { p = getParm(p); String *tm = goWrapperType(p, Getattr(p, "type"), false); - Printv(f_go_wrappers, ", ", tm, NULL); + Printv(f_go_wrappers, ", _ ", tm, NULL); Delete(tm); p = nextParm(p); } @@ -3266,11 +3268,19 @@ private: if (SwigType_type(result) != T_VOID) { String *tm = goWrapperType(n, result, true); - Printv(f_go_wrappers, " ", tm, NULL); + Printv(f_go_wrappers, " (_swig_ret ", tm, ")", NULL); Delete(tm); } - Printv(f_go_wrappers, "\n", NULL); + if (!gccgo_flag) { + Printv(f_go_wrappers, " {\n", NULL); + Printv(f_go_wrappers, "\t_swig_p := uintptr(unsafe.Pointer(&_swig_ptr))\n", NULL); + Printv(f_go_wrappers, "\t_cgo_runtime_cgocall(", upcall_wname, ", _swig_p)\n", NULL); + Printv(f_go_wrappers, "\treturn\n", NULL); + Printv(f_go_wrappers, "}", NULL); + } + + Printv(f_go_wrappers, "\n\n", NULL); } // Define the method on the director class in Go. @@ -3502,7 +3512,7 @@ private: if (!gccgo_flag) { // Write the upcall wrapper function. This is compiled by gc // and calls the C++ function. - int r = gcFunctionWrapper(n, upcall_name, upcall_name, overname, upcall_wname, first_parm, result, is_static, true); + int r = gcFunctionWrapper(upcall_wname); if (r != SWIG_OK) { return r; } -- cgit v1.2.1 From 2f5bf397ae5235129efed25cefbb8dbcb277eaf0 Mon Sep 17 00:00:00 2001 From: William S Fulton Date: Sat, 27 Sep 2014 13:56:11 +0100 Subject: Make more use of LocalRefGuard in Java --- Lib/java/director.swg | 30 +++++++++++++++++------------- 1 file changed, 17 insertions(+), 13 deletions(-) diff --git a/Lib/java/director.swg b/Lib/java/director.swg index 24460676f..031cdf2a9 100644 --- a/Lib/java/director.swg +++ b/Lib/java/director.swg @@ -100,6 +100,22 @@ namespace Swig { bool weak_global_; }; + /* Local JNI reference deleter */ + class LocalRefGuard { + JNIEnv *jenv_; + jobject jobj_; + + // non-copyable + LocalRefGuard(const LocalRefGuard &); + LocalRefGuard &operator=(const LocalRefGuard &); + public: + LocalRefGuard(JNIEnv *jenv, jobject jobj): jenv_(jenv), jobj_(jobj) {} + ~LocalRefGuard() { + if (jobj_) + jenv_->DeleteLocalRef(jobj_); + } + }; + /* director base class */ class Director { /* pointer to Java virtual machine */ @@ -152,6 +168,7 @@ namespace Swig { JNIEnvWrapper jnienv(this) ; JNIEnv *jenv = jnienv.getJNIEnv() ; jobject jobj = swig_self_.get(jenv); + LocalRefGuard ref_deleter(jenv, jobj); #if defined(DEBUG_DIRECTOR_OWNED) std::cout << "Swig::Director::disconnect_director_self(" << jobj << ")" << std::endl; #endif @@ -164,7 +181,6 @@ namespace Swig { jenv->CallVoidMethod(jobj, disconn_meth); } } - jenv->DeleteLocalRef(jobj); } public: @@ -379,17 +395,5 @@ namespace Swig { } return matches; } - - class LocalRefGuard { - JNIEnv* jenv_; - jobject jobj_; - - // non-copyable - LocalRefGuard(const LocalRefGuard &); - LocalRefGuard &operator=(const LocalRefGuard &); - public: - LocalRefGuard(JNIEnv* jenv, jobject jobj): jenv_(jenv), jobj_(jobj) {} - ~LocalRefGuard() { if (jobj_) jenv_->DeleteLocalRef(jobj_); } - }; } -- cgit v1.2.1 From f4964f5fb3f26bbe8526adb2bf2efe7543c98732 Mon Sep 17 00:00:00 2001 From: William S Fulton Date: Sat, 27 Sep 2014 14:32:03 +0100 Subject: Use more conventional naming for generated Java LocalRefGuard variables --- Lib/java/java.swg | 7 ++++--- Lib/java/std_string.i | 4 ++-- 2 files changed, 6 insertions(+), 5 deletions(-) diff --git a/Lib/java/java.swg b/Lib/java/java.swg index 3ad0e7aba..98524e85e 100644 --- a/Lib/java/java.swg +++ b/Lib/java/java.swg @@ -400,12 +400,13 @@ SWIGINTERN const char * SWIG_UnpackData(const char *c, void *ptr, size_t sz) { } %typemap(directorin, descriptor="Ljava/lang/String;", noblock=1) char * { - $input = 0; + $input = 0; if ($1) { $input = JCALL1(NewStringUTF, jenv, (const char *)$1); if (!$input) return $null; } - Swig::LocalRefGuard refGuard_$input(jenv, $input); + Swig::LocalRefGuard $1_refguard(jenv, $input); +// boohoo } %typemap(freearg, noblock=1) char * { if ($1) JCALL2(ReleaseStringUTFChars, jenv, $input, (const char *)$1); } @@ -732,7 +733,7 @@ SWIGINTERN const char * SWIG_UnpackData(const char *c, void *ptr, size_t sz) { $input = JCALL1(NewStringUTF, jenv, (const char *)$1); if (!$input) return $null; } - Swig::LocalRefGuard refGuard_$input(jenv, $input); + Swig::LocalRefGuard $1_refguard(jenv, $input); } %typemap(argout) char[ANY], char[] "" diff --git a/Lib/java/std_string.i b/Lib/java/std_string.i index 322d0da12..830a89611 100644 --- a/Lib/java/std_string.i +++ b/Lib/java/std_string.i @@ -50,7 +50,7 @@ class string; %typemap(directorin,descriptor="Ljava/lang/String;") string %{ $input = jenv->NewStringUTF($1.c_str()); - Swig::LocalRefGuard refGuard_$input(jenv, $input); %} + Swig::LocalRefGuard $1_refguard(jenv, $input); %} %typemap(out) string %{ $result = jenv->NewStringUTF($1.c_str()); %} @@ -100,7 +100,7 @@ class string; %typemap(directorin,descriptor="Ljava/lang/String;") const string & %{ $input = jenv->NewStringUTF($1.c_str()); - Swig::LocalRefGuard refGuard_$input(jenv, $input); %} + Swig::LocalRefGuard $1_refguard(jenv, $input); %} %typemap(out) const string & %{ $result = jenv->NewStringUTF($1->c_str()); %} -- cgit v1.2.1 From d03ff2b262b74235354277a39083fdd02d337bfc Mon Sep 17 00:00:00 2001 From: William S Fulton Date: Sat, 27 Sep 2014 14:48:13 +0100 Subject: Changes note for #168 - JNI leak fix --- CHANGES.current | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/CHANGES.current b/CHANGES.current index ab78637f9..721f44df9 100644 --- a/CHANGES.current +++ b/CHANGES.current @@ -5,6 +5,10 @@ See the RELEASENOTES file for a summary of changes in each release. Version 3.0.3 (in progress) =========================== +2014-09-27: wsfulton + [Java] Patch #168 - Fix leak in Java director string handling after the Java + upcall when called from a native thread. + 2014-09-25: ianlancetaylor [Go] Adjust generated code to work with upcoming Go 1.4 release. -- cgit v1.2.1 From a9ff9ab2b963cecf997529aba9a259fce9db6382 Mon Sep 17 00:00:00 2001 From: William S Fulton Date: Sat, 27 Sep 2014 15:14:14 +0100 Subject: Add changes note for #187 - Ruby data sharing fix --- CHANGES.current | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/CHANGES.current b/CHANGES.current index 721f44df9..d8ce4ea48 100644 --- a/CHANGES.current +++ b/CHANGES.current @@ -5,6 +5,10 @@ See the RELEASENOTES file for a summary of changes in each release. Version 3.0.3 (in progress) =========================== +2014-09-27: wsfulton + [Ruby] Patch #187 - Fix crash on shutdown of the Ruby interpreter if more than one + module was loaded at a time when data is being shared between modules. + 2014-09-27: wsfulton [Java] Patch #168 - Fix leak in Java director string handling after the Java upcall when called from a native thread. -- cgit v1.2.1 From f81042057b9d7b95eb755a5be8bcbf4ff5fc8aaf Mon Sep 17 00:00:00 2001 From: William S Fulton Date: Sat, 27 Sep 2014 16:55:46 +0100 Subject: Add changes note for #208 - array_functions initialisation --- CHANGES.current | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/CHANGES.current b/CHANGES.current index d8ce4ea48..6bc9262c6 100644 --- a/CHANGES.current +++ b/CHANGES.current @@ -5,6 +5,10 @@ See the RELEASENOTES file for a summary of changes in each release. Version 3.0.3 (in progress) =========================== +2014-09-27: wsfulton + Patch #208 - Initialise newly created array when using array_functions in the + carrays.i library (C++ usage). + 2014-09-27: wsfulton [Ruby] Patch #187 - Fix crash on shutdown of the Ruby interpreter if more than one module was loaded at a time when data is being shared between modules. -- cgit v1.2.1 From de4f30bd3c45709143f557a12038c022ca42a683 Mon Sep 17 00:00:00 2001 From: Johan Hake Date: Mon, 29 Sep 2014 17:37:41 +0200 Subject: Small fixes to the relative import fix. -- Now the tests actually runs -- Corrected the syntax for the fix in the yacc file --- Examples/python/import_packages/Makefile | 3 ++- Source/CParse/parser.y | 2 +- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/Examples/python/import_packages/Makefile b/Examples/python/import_packages/Makefile index d5054fd22..dfd46d05c 100644 --- a/Examples/python/import_packages/Makefile +++ b/Examples/python/import_packages/Makefile @@ -11,7 +11,8 @@ import_packages_subdirs = \ from_init2 \ from_init3 \ relativeimport1 \ - relativeimport1 + relativeimport2 \ + relativeimport3 check: build if test "x$(SRCDIR)" != x; then \ diff --git a/Source/CParse/parser.y b/Source/CParse/parser.y index ec0927536..b334ace76 100644 --- a/Source/CParse/parser.y +++ b/Source/CParse/parser.y @@ -1880,7 +1880,7 @@ include_directive: includetype options string BEGINFILE { Node *nint = new_node("import"); Node *mnode = new_node("module"); Setattr(mnode,"name", mname); - Setattr(mnode,"options",(yyvsp[-5].node)); + Setattr(mnode,"options",$2); appendChild(nint,mnode); Delete(mnode); appendChild(nint,firstChild($$)); -- cgit v1.2.1 From 00457b65995e0edb8e783ea13d4d2740e08ecb62 Mon Sep 17 00:00:00 2001 From: Richard Date: Tue, 30 Sep 2014 12:33:49 -0300 Subject: Making generated code more readable --- Lib/javascript/v8/javascriptcode.swg | 10 +++------- Lib/javascript/v8/javascriptinit.swg | 8 +------- Lib/javascript/v8/javascriptrun.swg | 8 ++++++++ 3 files changed, 12 insertions(+), 14 deletions(-) diff --git a/Lib/javascript/v8/javascriptcode.swg b/Lib/javascript/v8/javascriptcode.swg index 5af026d0b..12db9b4ab 100644 --- a/Lib/javascript/v8/javascriptcode.swg +++ b/Lib/javascript/v8/javascriptcode.swg @@ -357,14 +357,9 @@ fail: * ----------------------------------------------------------------------------- */ %fragment("jsv8_define_class_template", "templates") %{ + /* Name: $jsmangledname, Type: $jsmangledtype, Dtor: $jsdtor */ v8::Handle $jsmangledname_class = SWIGV8_CreateClassTemplate("$jsmangledname"); -#if (SWIG_V8_VERSION < 0x031710) - $jsmangledname_clientData.class_templ = v8::Persistent::New($jsmangledname_class); -#elif (SWIG_V8_VERSION < 0x031900) - $jsmangledname_clientData.class_templ = v8::Persistent::New(v8::Isolate::GetCurrent(), $jsmangledname_class); -#else - $jsmangledname_clientData.class_templ.Reset(v8::Isolate::GetCurrent(), $jsmangledname_class); -#endif + SWIGV8_SET_CLASS_TEMPL($jsmangledname_clientData.class_templ, $jsmangledname_class); $jsmangledname_clientData.dtor = $jsdtor; if (SWIGTYPE_$jsmangledtype->clientdata == 0) { SWIGTYPE_$jsmangledtype->clientdata = &$jsmangledname_clientData; @@ -408,6 +403,7 @@ fail: * ----------------------------------------------------------------------------- */ %fragment("jsv8_create_class_instance", "templates") %{ + /* Class: $jsname ($jsmangledname) */ v8::Handle $jsmangledname_class_0 = SWIGV8_CreateClassTemplate("$jsname"); $jsmangledname_class_0->SetCallHandler($jsctor); $jsmangledname_class_0->Inherit($jsmangledname_class); diff --git a/Lib/javascript/v8/javascriptinit.swg b/Lib/javascript/v8/javascriptinit.swg index 03ea5e658..34befa7ce 100644 --- a/Lib/javascript/v8/javascriptinit.swg +++ b/Lib/javascript/v8/javascriptinit.swg @@ -82,13 +82,7 @@ void SWIGV8_INIT (v8::Handle exports, v8::Handle /*modul %fragment("js_initializer", "templates") %{ // a class template for creating proxies of undefined types -#if (SWIG_V8_VERSION < 0x031710) - SWIGV8_SWIGTYPE_Proxy_class_templ = v8::Persistent::New(SWIGV8_CreateClassTemplate("SwigProxy")); -#elif (SWIG_V8_VERSION < 0x031900) - SWIGV8_SWIGTYPE_Proxy_class_templ = v8::Persistent::New(v8::Isolate::GetCurrent(), SWIGV8_CreateClassTemplate("SwigProxy")); -#else - SWIGV8_SWIGTYPE_Proxy_class_templ.Reset(v8::Isolate::GetCurrent(), SWIGV8_CreateClassTemplate("SwigProxy")); -#endif + SWIGV8_SET_CLASS_TEMPL(SWIGV8_SWIGTYPE_Proxy_class_templ, SWIGV8_CreateClassTemplate("SwigProxy")); /* create objects for namespaces */ $jsv8nspaces diff --git a/Lib/javascript/v8/javascriptrun.swg b/Lib/javascript/v8/javascriptrun.swg index d9a6b591a..b37059cca 100644 --- a/Lib/javascript/v8/javascriptrun.swg +++ b/Lib/javascript/v8/javascriptrun.swg @@ -83,6 +83,14 @@ typedef v8::PropertyCallbackInfo SwigV8PropertyCallbackInfo; #define SWIGV8_NULL() v8::Null(v8::Isolate::GetCurrent()) #endif +#if (SWIG_V8_VERSION < 0x031710) +#define SWIGV8_SET_CLASS_TEMPL(class_templ, class) class_templ = v8::Persistent::New(class); +#elif (SWIG_V8_VERSION < 0x031900) +#define SWIGV8_SET_CLASS_TEMPL(class_templ, class) class_templ = v8::Persistent::New(v8::Isolate::GetCurrent(), class); +#else +#define SWIGV8_SET_CLASS_TEMPL(class_templ, class) class_templ.Reset(v8::Isolate::GetCurrent(), class); +#endif + /* --------------------------------------------------------------------------- * Error handling * -- cgit v1.2.1 From 412d9813f9a9d415c8519d0f6b5f6f5681e97890 Mon Sep 17 00:00:00 2001 From: William S Fulton Date: Sat, 27 Sep 2014 15:39:50 +0100 Subject: Typo fix in Android docs [skip ci] --- Doc/Manual/Android.html | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Doc/Manual/Android.html b/Doc/Manual/Android.html index e62139797..2890e2415 100644 --- a/Doc/Manual/Android.html +++ b/Doc/Manual/Android.html @@ -56,7 +56,7 @@ Add the SDK tools and NDK tools to your path and create a directory somewhere fo
     $ export PATH=$HOME/android/android-sdk-linux_x86/tools:$HOME/android/android-sdk-linux_x86/platform-tools:$HOME/android/android-ndk-r6b:$PATH
     $ mkdir AndroidApps 
    -$ cd AnrdoidApps
    +$ cd AndroidApps
     
    -- cgit v1.2.1 From af1093d9560a60a9f9aa409743d8c5bd606ada0b Mon Sep 17 00:00:00 2001 From: William S Fulton Date: Tue, 30 Sep 2014 20:37:14 +0100 Subject: Add changes note for #207 [skip ci] --- CHANGES.current | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/CHANGES.current b/CHANGES.current index ee85b0cf3..2638d9930 100644 --- a/CHANGES.current +++ b/CHANGES.current @@ -5,6 +5,10 @@ See the RELEASENOTES file for a summary of changes in each release. Version 3.0.3 (in progress) =========================== +2014-09-30: wsfulton + [Python] Patch #207 - Fix No module error with -relativeimport when using single + header file import. + 2014-09-27: wsfulton Patch #208 - Initialise newly created array when using array_functions in the carrays.i library (C++ usage). -- cgit v1.2.1 From 0d6cebc7c4c7406b4def554a4a7a242b3091af37 Mon Sep 17 00:00:00 2001 From: Ian Lance Taylor Date: Tue, 30 Sep 2014 12:42:21 -0700 Subject: [Go] In configure script, require Go 1.1 or later. --- CHANGES.current | 3 +++ configure.ac | 40 +++++++++++++++++++++++++--------------- 2 files changed, 28 insertions(+), 15 deletions(-) diff --git a/CHANGES.current b/CHANGES.current index 2638d9930..9b23e88de 100644 --- a/CHANGES.current +++ b/CHANGES.current @@ -5,6 +5,9 @@ See the RELEASENOTES file for a summary of changes in each release. Version 3.0.3 (in progress) =========================== +2014-09-30: ianlancetaylor + [Go] In configure script, require Go 1.1 or later. + 2014-09-30: wsfulton [Python] Patch #207 - Fix No module error with -relativeimport when using single header file import. diff --git a/configure.ac b/configure.ac index 49057d8d1..78c276029 100644 --- a/configure.ac +++ b/configure.ac @@ -2291,14 +2291,21 @@ else GOVERSIONOPTION=version GOC=$(sh -c "$(go env) && echo \$GOCHAR")c go_version=$($GO $GOVERSIONOPTION | sed -e 's/go version //') + AC_MSG_CHECKING([whether go version is too old]) case $go_version in - go1.0*) GOOPT="-intgosize 32" ;; - *) if test "$GOC" = "6c"; then - GOOPT="-intgosize 64" - else - GOOPT="-intgosize 32" - fi - ;; + go1.0*) + AC_MSG_RESULT([yes - minimum version is 1.1]) + GO= + GOOPT="-intgosize 32" + ;; + *) + AC_MSG_RESULT([no]) + if test "$GOC" = "6c"; then + GOOPT="-intgosize 64" + else + GOOPT="-intgosize 32" + fi + ;; esac case $go_version in go1.0* | go1.1*) @@ -2315,14 +2322,17 @@ else GOC=`echo $GO | sed -e 's/g/c/'` GOVERSIONOPTION=-V AC_MSG_CHECKING([whether Go ($GO) version is too old]) - go_version=`$GO $GOVERSIONOPTION 2>/dev/null | sed -e 's/.*version.* \([[0-9]]*\).*/\1/'` - go_min_version=7077 - if test "$go_version" != "" -a "$go_version" -lt $go_min_version; then - AC_MSG_RESULT([yes - minimum version is $go_min_version]) - GO= - else - AC_MSG_RESULT([no]) - fi + AC_MSG_RESULT([yes - minimum version is 1.1]) + GO= + dnl Old code retained for now in case we implement an option for it. + dnl go_version=`$GO $GOVERSIONOPTION 2>/dev/null | sed -e 's/.*version.* \([[0-9]]*\).*/\1/'` + dnl go_min_version=7077 + dnl if test "$go_version" != "" -a "$go_version" -lt $go_min_version; then + dnl AC_MSG_RESULT([yes - minimum version is $go_min_version]) + dnl GO= + dnl else + dnl AC_MSG_RESULT([no]) + dnl fi GOOPT="-intgosize 32" GO12=false GO13=false -- cgit v1.2.1 From 08c8df5fdd4aa8f3b466c16785b15a22a96add27 Mon Sep 17 00:00:00 2001 From: Oliver Buchtala Date: Tue, 30 Sep 2014 22:20:06 +0200 Subject: Announced changes after merging #195 and #216. --- CHANGES.current | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/CHANGES.current b/CHANGES.current index ee85b0cf3..5300f3c15 100644 --- a/CHANGES.current +++ b/CHANGES.current @@ -5,6 +5,12 @@ See the RELEASENOTES file for a summary of changes in each release. Version 3.0.3 (in progress) =========================== +2014-09-30: oliverb + [Javascript] Merge patch #216 by Richie765 - Added support for many versions of v8 javascript. + +2014-09-30: oliverb + [Javascript] Merge patch #195 by zittix - Fixed JSClassRef declaration not using the static one. + 2014-09-27: wsfulton Patch #208 - Initialise newly created array when using array_functions in the carrays.i library (C++ usage). @@ -60,9 +66,6 @@ Version 3.0.3 (in progress) Issue an error for unknown SWIG preprocessor directives, rather than quietly ignoring them. Reported by jrhelsey in issue#217. -2014-08-23: richie765 - [Javascript] Added support for a variety of V8 versions - 2014-08-15: talby [Perl] Include guard fix for nested modules from Anthony Heading (SF Patch #350). -- cgit v1.2.1 From 0fb34cb019359ceb53e4ec49628bb7ba91a2a2c4 Mon Sep 17 00:00:00 2001 From: William S Fulton Date: Wed, 1 Oct 2014 07:57:23 +0100 Subject: Disable test not relevant for Python -builtin --- Examples/test-suite/python/python_append_runme.py | 9 +++++++-- Examples/test-suite/python_append.i | 5 +++++ 2 files changed, 12 insertions(+), 2 deletions(-) diff --git a/Examples/test-suite/python/python_append_runme.py b/Examples/test-suite/python/python_append_runme.py index 41cebad58..54d7a3e00 100644 --- a/Examples/test-suite/python/python_append_runme.py +++ b/Examples/test-suite/python/python_append_runme.py @@ -1,11 +1,16 @@ from python_append import * + +# test not relevant for -builtin +if is_python_builtin(): + exit(0) + t=Test() t.func() t.static_func() if grabpath() != os.path.dirname(mypath): - raise RuntimeError + raise RuntimeError("grabpath failed") if grabstaticpath() != os.path.basename(mypath): - raise RuntimeError + raise RuntimeError("grabstaticpath failed") diff --git a/Examples/test-suite/python_append.i b/Examples/test-suite/python_append.i index 0ac54656f..f37a6c199 100644 --- a/Examples/test-suite/python_append.i +++ b/Examples/test-suite/python_append.i @@ -46,5 +46,10 @@ public: void func() {}; }; +#ifdef SWIGPYTHON_BUILTIN +bool is_python_builtin() { return true; } +#else +bool is_python_builtin() { return false; } +#endif %} -- cgit v1.2.1 From 558af639bd02ac07513098b841a9c16bb4afd764 Mon Sep 17 00:00:00 2001 From: Yann Diorcet Date: Wed, 24 Sep 2014 14:07:44 +0200 Subject: Python: Fix property access with director --- Examples/test-suite/common.mk | 1 + Examples/test-suite/director_property.i | 151 +++++++++++++++++++++ .../test-suite/python/director_property_runme.py | 18 +++ Source/Modules/python.cxx | 11 +- 4 files changed, 178 insertions(+), 3 deletions(-) create mode 100644 Examples/test-suite/director_property.i create mode 100644 Examples/test-suite/python/director_property_runme.py diff --git a/Examples/test-suite/common.mk b/Examples/test-suite/common.mk index 485453b5a..c8a67283c 100644 --- a/Examples/test-suite/common.mk +++ b/Examples/test-suite/common.mk @@ -172,6 +172,7 @@ CPP_TEST_CASES += \ director_abstract \ director_alternating \ director_basic \ + director_property \ director_binary_string \ director_classes \ director_classic \ diff --git a/Examples/test-suite/director_property.i b/Examples/test-suite/director_property.i new file mode 100644 index 000000000..3363c3c4f --- /dev/null +++ b/Examples/test-suite/director_property.i @@ -0,0 +1,151 @@ +%module(directors="1") director_property + +%warnfilter(SWIGWARN_TYPEMAP_THREAD_UNSAFE,SWIGWARN_TYPEMAP_DIRECTOROUT_PTR) MyClass::pmethod; + +%{ + #include + + class Foo { + private: + std::string a; + public: + virtual ~Foo() {} + virtual std::string ping() { return "Foo::ping()"; } + virtual std::string pong() { return "Foo::pong();" + ping(); } + virtual std::string getA() { return this->a; } + virtual void setA(std::string a) { this->a = a; } + + static Foo* get_self(Foo *slf) {return slf;} + + }; + + %} + + %include + + %feature("director") Foo; + + + class Foo { + public: + virtual ~Foo(); + virtual std::string ping(); + virtual std::string pong(); + virtual std::string getA(); + virtual void setA(std::string a); + + static Foo* get_self(Foo *slf); + + }; + + %{ + #include + %} + %feature("director") A; + + // basic renaming + %rename(rg) A::gg; + %feature("nodirector") hi::A1::gg; + + %inline %{ + + struct A{ + A(std::complex i, double d=0.0) {} + A(int i, bool j=false) {} + virtual ~A() {} + + virtual int f(int i=0) {return i;} + virtual int gg(int i=0) {return i;} + }; + + namespace hi { + + struct A1 : public A { + A1(std::complex i, double d=0.0) : A(i, d) {} + A1(int i, bool j=false) : A(i, j) {} + + virtual int ff(int i = 0) {return i;} + }; + } + + + %} + + + %feature("director") MyClass; + + %inline %{ + + typedef void VoidType; + + struct Bar + { + int x; + Bar(int _x = 0) : x(_x) + { + } + }; + + + +class MyClass { +public: + MyClass(int a = 0) + { + } + + virtual void method(VoidType *) + { + } + + virtual ~MyClass() + { + } + + virtual Bar vmethod(Bar b) + { + b.x += 13; + return b; + } + + virtual Bar* pmethod(Bar *b) + { + b->x += 12; + return b; + } + + Bar cmethod(const Bar &b) + { + return vmethod(b); + } + + static MyClass *get_self(MyClass *c) + { + return c; + } + + static Bar * call_pmethod(MyClass *myclass, Bar *b) { + return myclass->pmethod(b); + } +}; + +template +class MyClassT { +public: + MyClassT(int a = 0) + { + } + + virtual void method(VoidType *) + { + } + + virtual ~MyClassT() + { + } + +}; + +%} + +%template(MyClassT_i) MyClassT; diff --git a/Examples/test-suite/python/director_property_runme.py b/Examples/test-suite/python/director_property_runme.py new file mode 100644 index 000000000..303e53b67 --- /dev/null +++ b/Examples/test-suite/python/director_property_runme.py @@ -0,0 +1,18 @@ +import director_property + +class PyFoo(director_property.Foo): + a = property(director_property.Foo.getA, director_property.Foo.setA) + + def ping(self): + return "PyFoo::ping()" + + +foo = PyFoo() + +foo.setA("BLABLA") +if foo.getA() != "BLABLA": + raise RuntimeError + +foo.a = "BIBI" +if foo.a != "BIBI": + raise RuntimeError diff --git a/Source/Modules/python.cxx b/Source/Modules/python.cxx index 743db9c68..2310b3472 100644 --- a/Source/Modules/python.cxx +++ b/Source/Modules/python.cxx @@ -871,16 +871,21 @@ public: #else tab4, "if (not static):\n", #endif - tab4, tab4, "self.__dict__[name] = value\n", + tab4, tab4, "object.__setattr__(self, name, value)\n", tab4, "else:\n", tab4, tab4, "raise AttributeError(\"You cannot add attributes to %s\" % self)\n\n", "\n", "def _swig_setattr(self, class_type, name, value):\n", tab4, "return _swig_setattr_nondynamic(self, class_type, name, value, 0)\n\n", NIL); Printv(f_shadow, - "\n", "def _swig_getattr(self, class_type, name):\n", + "\n", "def _swig_getattr_nondynamic(self, class_type, name, static=1):\n", tab4, "if (name == \"thisown\"):\n", tab8, "return self.this.own()\n", tab4, "method = class_type.__swig_getmethods__.get(name, None)\n", - tab4, "if method:\n", tab8, "return method(self)\n", tab4, "raise AttributeError(name)\n\n", NIL); + tab4, "if method:\n", tab8, "return method(self)\n", + tab4, "if (not static):\n", + tab4, tab4, "return object.__getattr__(self, name)\n", + tab4, "else:\n", + tab4, tab4, "raise AttributeError(name)\n\n", + "def _swig_getattr(self, class_type, name):\n", tab4, "return _swig_getattr_nondynamic(self, class_type, name, 0)\n\n", NIL); Printv(f_shadow, "\n", "def _swig_repr(self):\n", -- cgit v1.2.1 From 34eb4b15d3322c362208f98f775c71a2a59898a2 Mon Sep 17 00:00:00 2001 From: William S Fulton Date: Thu, 2 Oct 2014 19:08:58 +0100 Subject: Add some more Python -builtin tests that don't work --- Examples/test-suite/python/Makefile.in | 3 +++ 1 file changed, 3 insertions(+) diff --git a/Examples/test-suite/python/Makefile.in b/Examples/test-suite/python/Makefile.in index c00d8844c..896014770 100644 --- a/Examples/test-suite/python/Makefile.in +++ b/Examples/test-suite/python/Makefile.in @@ -87,9 +87,12 @@ C_TEST_CASES += \ include $(srcdir)/../common.mk BUILTIN_BROKEN = \ + autodoc.cpptest \ default_constructor.cpptest \ director_exception.cpptest \ exception_order.cpptest \ + import_nomodule.cpptest \ + li_std_except_as_class.cpptest \ li_std_string_extra.cpptest \ li_std_wstring.cpptest \ python_abstractbase.cpptest \ -- cgit v1.2.1 From 0d16b191223d5eb842555857df55035507c74954 Mon Sep 17 00:00:00 2001 From: Karl Wette Date: Thu, 2 Oct 2014 22:45:42 +0200 Subject: Octave: remove '\' line continuation in director_detect_runme.m - Deprecated in Octave 3.8.1 --- Examples/test-suite/octave/director_detect_runme.m | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/Examples/test-suite/octave/director_detect_runme.m b/Examples/test-suite/octave/director_detect_runme.m index f2d8c8dd2..21925712a 100644 --- a/Examples/test-suite/octave/director_detect_runme.m +++ b/Examples/test-suite/octave/director_detect_runme.m @@ -1,7 +1,7 @@ director_detect -global MyBar=@(val=2) \ - subclass(director_detect.Bar(),'val',val,@get_value,@get_class,@just_do_it,@clone); +global MyBar=@(val=2) subclass(director_detect.Bar(),'val',val,@get_value,@get_class,@just_do_it,@clone); + function val=get_value(self) self.val = self.val + 1; val = self.val; -- cgit v1.2.1 From 5c07625d05eabc08a781008928297e35b80cb8ab Mon Sep 17 00:00:00 2001 From: Karl Wette Date: Sat, 31 May 2014 09:21:25 +0200 Subject: Octave: ignore test suite generated files --- .gitignore | 1 + 1 file changed, 1 insertion(+) diff --git a/.gitignore b/.gitignore index 0e2d70a23..a1b9d5e94 100644 --- a/.gitignore +++ b/.gitignore @@ -136,6 +136,7 @@ Examples/test-suite/uffi/*/ # Octave generated files swigexample*.oct +Examples/test-suite/octave/*.oct # Python generated files, based on: # https://github.com/github/gitignore/blob/master/Python.gitignore -- cgit v1.2.1 From a93d5eac4eb375d31d4f7a2cdabf924c1c19bb52 Mon Sep 17 00:00:00 2001 From: Karl Wette Date: Mon, 2 Jun 2014 04:14:35 +0200 Subject: Octave: turn on autodoc in examples, so that feature is tested --- Examples/octave/callback/example.i | 3 +++ Examples/octave/class/example.i | 2 ++ Examples/octave/constants/example.i | 2 ++ Examples/octave/contract/example.i | 2 ++ Examples/octave/enum/example.i | 2 ++ Examples/octave/extend/example.i | 3 +++ Examples/octave/funcptr/example.i | 3 +++ Examples/octave/funcptr2/example.i | 3 +++ Examples/octave/functor/example.i | 1 + Examples/octave/module_load/example.i | 3 +++ Examples/octave/operator/example.i | 4 ++++ Examples/octave/pointer/example.i | 2 ++ Examples/octave/reference/example.i | 2 ++ Examples/octave/simple/example.i | 2 ++ Examples/octave/template/example.i | 2 ++ Examples/octave/variables/example.i | 3 +++ 16 files changed, 39 insertions(+) diff --git a/Examples/octave/callback/example.i b/Examples/octave/callback/example.i index 3192904db..50ef5096d 100644 --- a/Examples/octave/callback/example.i +++ b/Examples/octave/callback/example.i @@ -1,5 +1,8 @@ /* File : example.i */ %module(directors="1") swigexample + +%feature("autodoc", 1); + %{ #include "example.h" %} diff --git a/Examples/octave/class/example.i b/Examples/octave/class/example.i index b109bcb78..52e9fd3bf 100644 --- a/Examples/octave/class/example.i +++ b/Examples/octave/class/example.i @@ -1,6 +1,8 @@ /* File : example.i */ %module swigexample +%feature("autodoc", 1); + %{ #include "example.h" %} diff --git a/Examples/octave/constants/example.i b/Examples/octave/constants/example.i index 405974b44..ab42a6b21 100644 --- a/Examples/octave/constants/example.i +++ b/Examples/octave/constants/example.i @@ -1,6 +1,8 @@ /* File : example.i */ %module swigexample +%feature("autodoc", 1); + /* A few preprocessor macros */ #define ICONST 42 diff --git a/Examples/octave/contract/example.i b/Examples/octave/contract/example.i index 78c459efc..8976607b2 100644 --- a/Examples/octave/contract/example.i +++ b/Examples/octave/contract/example.i @@ -1,6 +1,8 @@ /* File : example.i */ %module swigexample +%feature("autodoc", 1); + %contract gcd(int x, int y) { require: x >= 0; diff --git a/Examples/octave/enum/example.i b/Examples/octave/enum/example.i index cee9af471..084bab06b 100644 --- a/Examples/octave/enum/example.i +++ b/Examples/octave/enum/example.i @@ -1,6 +1,8 @@ /* File : example.i */ %module swigexample +%feature("autodoc", 1); + %{ #include "example.h" %} diff --git a/Examples/octave/extend/example.i b/Examples/octave/extend/example.i index 953c2f314..3b9ac53c4 100644 --- a/Examples/octave/extend/example.i +++ b/Examples/octave/extend/example.i @@ -1,5 +1,8 @@ /* File : example.i */ %module(directors="1") swigexample + +%feature("autodoc", 1); + %{ #include "example.h" %} diff --git a/Examples/octave/funcptr/example.i b/Examples/octave/funcptr/example.i index 163a1991b..c6fcfe781 100644 --- a/Examples/octave/funcptr/example.i +++ b/Examples/octave/funcptr/example.i @@ -1,5 +1,8 @@ /* File : example.i */ %module swigexample + +%feature("autodoc", 1); + %{ #include "example.h" %} diff --git a/Examples/octave/funcptr2/example.i b/Examples/octave/funcptr2/example.i index 33378a1c1..bbe50fb8f 100644 --- a/Examples/octave/funcptr2/example.i +++ b/Examples/octave/funcptr2/example.i @@ -1,5 +1,8 @@ /* File : example.i */ %module swigexample + +%feature("autodoc", 1); + %{ #include "example.h" %} diff --git a/Examples/octave/functor/example.i b/Examples/octave/functor/example.i index ade20c56c..0c21a8ed6 100644 --- a/Examples/octave/functor/example.i +++ b/Examples/octave/functor/example.i @@ -1,6 +1,7 @@ /* File : example.i */ %module swigexample +%feature("autodoc", 1); %inline %{ // From B. Strousjoup, "The C++ Programming Language, Third Edition", p. 514 diff --git a/Examples/octave/module_load/example.i b/Examples/octave/module_load/example.i index fd074d4f2..bd0e39937 100644 --- a/Examples/octave/module_load/example.i +++ b/Examples/octave/module_load/example.i @@ -1,5 +1,8 @@ /* File : example.i */ /* module name given on cmdline */ + +%feature("autodoc", 1); + %{ #include "example.h" %} diff --git a/Examples/octave/operator/example.i b/Examples/octave/operator/example.i index a2d97731d..7fad8e609 100644 --- a/Examples/octave/operator/example.i +++ b/Examples/octave/operator/example.i @@ -1,6 +1,10 @@ /* File : example.i */ %module swigexample + +%feature("autodoc", 1); + #pragma SWIG nowarn=SWIGWARN_IGNORE_OPERATOR_EQ + %{ #include "example.h" %} diff --git a/Examples/octave/pointer/example.i b/Examples/octave/pointer/example.i index 545e3ada4..8b9e0f134 100644 --- a/Examples/octave/pointer/example.i +++ b/Examples/octave/pointer/example.i @@ -1,6 +1,8 @@ /* File : example.i */ %module swigexample +%feature("autodoc", 1); + %{ extern void add(int *, int *, int *); extern void sub(int *, int *, int *); diff --git a/Examples/octave/reference/example.i b/Examples/octave/reference/example.i index da09800c0..0aa733451 100644 --- a/Examples/octave/reference/example.i +++ b/Examples/octave/reference/example.i @@ -4,6 +4,8 @@ %module swigexample +%feature("autodoc", 1); + %{ #include "example.h" %} diff --git a/Examples/octave/simple/example.i b/Examples/octave/simple/example.i index 127bfcd84..a3006f282 100644 --- a/Examples/octave/simple/example.i +++ b/Examples/octave/simple/example.i @@ -1,6 +1,8 @@ /* File : example.i */ %module swigexample +%feature("autodoc", 1); + %inline %{ extern int gcd(int x, int y); extern double Foo; diff --git a/Examples/octave/template/example.i b/Examples/octave/template/example.i index cfff18ded..3c57f3884 100644 --- a/Examples/octave/template/example.i +++ b/Examples/octave/template/example.i @@ -1,6 +1,8 @@ /* File : example.i */ %module swigexample +%feature("autodoc", 1); + %{ #include "example.h" %} diff --git a/Examples/octave/variables/example.i b/Examples/octave/variables/example.i index 3e11495ad..9d8b03ec2 100644 --- a/Examples/octave/variables/example.i +++ b/Examples/octave/variables/example.i @@ -1,5 +1,8 @@ /* File : example.i */ %module swigexample + +%feature("autodoc", 1); + %{ #include "example.h" %} -- cgit v1.2.1 From 5ac475cbcd873307abe802063789f47aa5435dd1 Mon Sep 17 00:00:00 2001 From: Karl Wette Date: Sat, 4 Oct 2014 13:29:46 +0200 Subject: Octave: whitespace/indentation/style cleanup of octave.cxx - Used "astyle -A10 -s2 -N -p -H -U -k1" for style cleanup - Replaced NewString("") with NewStringEmpty() - Used 'w' instead of 'f' for Wrapper() objects --- Source/Modules/octave.cxx | 831 ++++++++++++++++++++++++---------------------- 1 file changed, 438 insertions(+), 393 deletions(-) diff --git a/Source/Modules/octave.cxx b/Source/Modules/octave.cxx index 12903166c..3ec60c31d 100644 --- a/Source/Modules/octave.cxx +++ b/Source/Modules/octave.cxx @@ -14,10 +14,10 @@ #include "swigmod.h" #include "cparse.h" -static String *global_name = 0; -static String *op_prefix = 0; +static String* global_name = 0; +static String* op_prefix = 0; -static const char *usage = "\ +static const char* usage = "\ Octave Options (available with -octave)\n\ -globals - Set used to access C global variables [default: 'cvar']\n\ Use '.' to load C global variables into module namespace\n\ @@ -25,39 +25,39 @@ Octave Options (available with -octave)\n\ \n"; -class OCTAVE:public Language { +class OCTAVE: public Language +{ private: - File *f_begin; - File *f_runtime; - File *f_header; - File *f_doc; - File *f_wrappers; - File *f_init; - File *f_initbeforefunc; - File *f_directors; - File *f_directors_h; - String *s_global_tab; - String *s_members_tab; - String *class_name; + File* f_begin; + File* f_runtime; + File* f_header; + File* f_doc; + File* f_wrappers; + File* f_init; + File* f_initbeforefunc; + File* f_directors; + File* f_directors_h; + String* s_global_tab; + String* s_members_tab; + String* class_name; int have_constructor; int have_destructor; - String *constructor_name; + String* constructor_name; - Hash *docs; + Hash* docs; - void Octave_begin_function(Node *n, File *f, const_String_or_char_ptr cname, const_String_or_char_ptr wname, bool dld) { + void Octave_begin_function(Node* n, File* f, const_String_or_char_ptr cname, const_String_or_char_ptr wname, bool dld) { if (dld) { - String *tname = texinfo_name(n, "std::string()"); + String* tname = texinfo_name(n, "std::string()"); Printf(f, "SWIG_DEFUN( %s, %s, %s ) {", cname, wname, tname); - } - else { + } else { Printf(f, "static octave_value_list %s (const octave_value_list& args, int nargout) {", wname); } } public: - OCTAVE(): + OCTAVE() : f_begin(0), f_runtime(0), f_header(0), @@ -73,10 +73,9 @@ public: have_constructor(0), have_destructor(0), constructor_name(0), - docs(0) - { + docs(0) { /* Add code to manage protected constructors and directors */ - director_prot_ctor_code = NewString(""); + director_prot_ctor_code = NewStringEmpty(); Printv(director_prot_ctor_code, "if ( $comparison ) { /* subclassed */\n", " $director_new \n", @@ -89,7 +88,7 @@ public: docs = NewHash(); } - virtual void main(int argc, char *argv[]) { + virtual void main(int argc, char* argv[]) { for (int i = 1; i < argc; i++) { if (argv[i]) { if (strcmp(argv[i], "-help") == 0) { @@ -116,10 +115,12 @@ public: } } - if (!global_name) + if (!global_name) { global_name = NewString("cvar"); - if (!op_prefix) + } + if (!op_prefix) { op_prefix = NewString("op_"); + } SWIG_library_directory("octave"); Preprocessor_define("SWIGOCTAVE 1", 0); @@ -128,15 +129,16 @@ public: allow_overloading(); // Octave API is C++, so output must be C++ compatibile even when wrapping C code - if (!cparse_cplusplus) + if (!cparse_cplusplus) { Swig_cparse_cplusplusout(1); + } } - virtual int top(Node *n) { + virtual int top(Node* n) { { - Node *mod = Getattr(n, "module"); + Node* mod = Getattr(n, "module"); if (mod) { - Node *options = Getattr(mod, "options"); + Node* options = Getattr(mod, "options"); if (options) { int dirprot = 0; if (Getattr(options, "dirprot")) { @@ -147,29 +149,30 @@ public: } if (Getattr(options, "directors")) { allow_directors(); - if (dirprot) + if (dirprot) { allow_dirprot(); + } } } } } - String *module = Getattr(n, "name"); - String *outfile = Getattr(n, "outfile"); + String* module = Getattr(n, "name"); + String* outfile = Getattr(n, "outfile"); f_begin = NewFile(outfile, "w", SWIG_output_files()); if (!f_begin) { FileErrorDisplay(outfile); SWIG_exit(EXIT_FAILURE); } - f_runtime = NewString(""); - f_header = NewString(""); - f_doc = NewString(""); - f_wrappers = NewString(""); - f_init = NewString(""); - f_initbeforefunc = NewString(""); - f_directors_h = NewString(""); - f_directors = NewString(""); - s_global_tab = NewString(""); + f_runtime = NewStringEmpty(); + f_header = NewStringEmpty(); + f_doc = NewStringEmpty(); + f_wrappers = NewStringEmpty(); + f_init = NewStringEmpty(); + f_initbeforefunc = NewStringEmpty(); + f_directors_h = NewStringEmpty(); + f_directors = NewStringEmpty(); + s_global_tab = NewStringEmpty(); Swig_register_filebyname("begin", f_begin); Swig_register_filebyname("runtime", f_runtime); Swig_register_filebyname("header", f_header); @@ -205,19 +208,23 @@ public: Printf(s_global_tab, "\nstatic const struct swig_octave_member swig_globals[] = {\n"); Printf(f_init, "static bool SWIG_init_user(octave_swig_type* module_ns)\n{\n"); - if (!CPlusPlus) - Printf(f_header,"extern \"C\" {\n"); + if (!CPlusPlus) { + Printf(f_header, "extern \"C\" {\n"); + } Language::top(n); - if (!CPlusPlus) - Printf(f_header,"}\n"); + if (!CPlusPlus) { + Printf(f_header, "}\n"); + } - if (Len(docs)) + if (Len(docs)) { emit_doc_texinfo(); + } - if (directorsEnabled()) + if (directorsEnabled()) { Swig_insert_file("director.swg", f_runtime); + } Printf(f_init, "return true;\n}\n"); Printf(s_global_tab, "{0,0,0,0,0}\n};\n"); @@ -249,12 +256,13 @@ public: return SWIG_OK; } - String *texinfo_escape(String *_s) { - const char* s=(const char*)Data(_s); - while (*s&&(*s=='\t'||*s=='\r'||*s=='\n'||*s==' ')) + String* texinfo_escape(String* _s) { + const char* s = (const char*) Data(_s); + while (*s && (*s == '\t' || *s == '\r' || *s == '\n' || *s == ' ')) { ++s; - String *r = NewString(""); - for (int j=0;s[j];++j) { + } + String* r = NewStringEmpty(); + for (int j = 0; s[j]; ++j) { if (s[j] == '\n') { Append(r, "\\n\\\n"); } else if (s[j] == '\r') { @@ -267,94 +275,98 @@ public: Append(r, "\\\'"); } else if (s[j] == '\"') { Append(r, "\\\""); - } else + } else { Putc(s[j], r); + } } return r; } void emit_doc_texinfo() { for (Iterator it = First(docs); it.key; it = Next(it)) { - String *wrap_name = it.key; + String* wrap_name = it.key; - String *synopsis = Getattr(it.item, "synopsis"); - String *decl_info = Getattr(it.item, "decl_info"); - String *cdecl_info = Getattr(it.item, "cdecl_info"); - String *args_info = Getattr(it.item, "args_info"); + String* synopsis = Getattr(it.item, "synopsis"); + String* decl_info = Getattr(it.item, "decl_info"); + String* cdecl_info = Getattr(it.item, "cdecl_info"); + String* args_info = Getattr(it.item, "args_info"); - String *doc_str = NewString(""); + String* doc_str = NewStringEmpty(); Printv(doc_str, synopsis, decl_info, cdecl_info, args_info, NIL); - String *escaped_doc_str = texinfo_escape(doc_str); - - if (Len(doc_str)>0) { - Printf(f_doc,"static const char* %s_texinfo = ",wrap_name); - Printf(f_doc,"\"-*- texinfo -*-\\n\\\n%s", escaped_doc_str); - if (Len(decl_info)) - Printf(f_doc,"\\n\\\n@end deftypefn"); - Printf(f_doc,"\";\n"); + String* escaped_doc_str = texinfo_escape(doc_str); + + if (Len(doc_str) > 0) { + Printf(f_doc, "static const char* %s_texinfo = ", wrap_name); + Printf(f_doc, "\"-*- texinfo -*-\\n\\\n%s", escaped_doc_str); + if (Len(decl_info)) { + Printf(f_doc, "\\n\\\n@end deftypefn"); + } + Printf(f_doc, "\";\n"); } Delete(escaped_doc_str); Delete(doc_str); Delete(wrap_name); } - Printf(f_doc,"\n"); + Printf(f_doc, "\n"); } bool is_empty_doc_node(Node* n) { - if (!n) + if (!n) { return true; - String *synopsis = Getattr(n, "synopsis"); - String *decl_info = Getattr(n, "decl_info"); - String *cdecl_info = Getattr(n, "cdecl_info"); - String *args_info = Getattr(n, "args_info"); + } + String* synopsis = Getattr(n, "synopsis"); + String* decl_info = Getattr(n, "decl_info"); + String* cdecl_info = Getattr(n, "cdecl_info"); + String* args_info = Getattr(n, "args_info"); return !Len(synopsis) && !Len(decl_info) && - !Len(cdecl_info) && !Len(args_info); + !Len(cdecl_info) && !Len(args_info); } - String *texinfo_name(Node* n, const char* defval = "0") { - String *tname = NewString(""); - String *iname = Getattr(n, "sym:name"); - String *wname = Swig_name_wrapper(iname); + String* texinfo_name(Node* n, const char* defval = "0") { + String* tname = NewStringEmpty(); + String* iname = Getattr(n, "sym:name"); + String* wname = Swig_name_wrapper(iname); Node* d = Getattr(docs, wname); - if (is_empty_doc_node(d)) + if (is_empty_doc_node(d)) { Printf(tname, defval); - else + } else { Printf(tname, "%s_texinfo", wname); + } return tname; } - void process_autodoc(Node *n) { - String *iname = Getattr(n, "sym:name"); - String *name = Getattr(n, "name"); - String *wname = Swig_name_wrapper(iname); - String *str = Getattr(n, "feature:docstring"); + void process_autodoc(Node* n) { + String* iname = Getattr(n, "sym:name"); + String* name = Getattr(n, "name"); + String* wname = Swig_name_wrapper(iname); + String* str = Getattr(n, "feature:docstring"); bool autodoc_enabled = !Cmp(Getattr(n, "feature:autodoc"), "1"); Node* d = Getattr(docs, wname); if (!d) { d = NewHash(); - Setattr(d, "synopsis", NewString("")); - Setattr(d, "decl_info", NewString("")); - Setattr(d, "cdecl_info", NewString("")); - Setattr(d, "args_info", NewString("")); + Setattr(d, "synopsis", NewStringEmpty()); + Setattr(d, "decl_info", NewStringEmpty()); + Setattr(d, "cdecl_info", NewStringEmpty()); + Setattr(d, "args_info", NewStringEmpty()); Setattr(docs, wname, d); } - String *synopsis = Getattr(d, "synopsis"); - String *decl_info = Getattr(d, "decl_info"); + String* synopsis = Getattr(d, "synopsis"); + String* decl_info = Getattr(d, "decl_info"); // String *cdecl_info = Getattr(d, "cdecl_info"); - String *args_info = Getattr(d, "args_info"); + String* args_info = Getattr(d, "args_info"); // * couldn't we just emit the docs here? if (autodoc_enabled) { - String *decl_str = NewString(""); - String *args_str = NewString(""); + String* decl_str = NewStringEmpty(); + String* args_str = NewStringEmpty(); make_autodocParmList(n, decl_str, args_str); Append(decl_info, "@deftypefn {Loadable Function} "); - SwigType *type = Getattr(n, "type"); + SwigType* type = Getattr(n, "type"); if (type && Strcmp(type, "void")) { - Node *nn = classLookup(Getattr(n, "type")); - String *type_str = nn ? Copy(Getattr(nn, "sym:name")) : SwigType_str(type, 0); + Node* nn = classLookup(Getattr(n, "type")); + String* type_str = nn ? Copy(Getattr(nn, "sym:name")) : SwigType_str(type, 0); Append(decl_info, "@var{retval} = "); Printf(args_str, "%s@var{retval} is of type %s. ", args_str, type_str); Delete(type_str); @@ -371,7 +383,7 @@ public: if (str && Len(str) > 0) { // strip off {} if necessary - char *t = Char(str); + char* t = Char(str); if (*t == '{') { Delitem(str, 0); Delitem(str, DOH_END); @@ -382,14 +394,15 @@ public: } } - virtual int importDirective(Node *n) { - String *modname = Getattr(n, "module"); - if (modname) + virtual int importDirective(Node* n) { + String* modname = Getattr(n, "module"); + if (modname) { Printf(f_init, "if (!SWIG_Octave_LoadModule(\"%s\")) return false;\n", modname); + } return Language::importDirective(n); } - const char *get_implicitconv_flag(Node *n) { + const char* get_implicitconv_flag(Node* n) { int conv = 0; if (n && GetFlag(n, "feature:implicitconv")) { conv = 1; @@ -408,12 +421,12 @@ public: * The "lname" attribute in each parameter in plist will be contain a parameter name * ----------------------------------------------------------------------------- */ - void addMissingParameterNames(ParmList *plist, int arg_offset) { - Parm *p = plist; + void addMissingParameterNames(ParmList* plist, int arg_offset) { + Parm* p = plist; int i = arg_offset; while (p) { if (!Getattr(p, "lname")) { - String *pname = Swig_cparm_name(p, i); + String* pname = Swig_cparm_name(p, i); Delete(pname); } i++; @@ -421,21 +434,21 @@ public: } } - void make_autodocParmList(Node *n, String *decl_str, String *args_str) { - String *pdocs = 0; - ParmList *plist = CopyParmList(Getattr(n, "parms")); - Parm *p; - Parm *pnext; + void make_autodocParmList(Node* n, String* decl_str, String* args_str) { + String* pdocs = 0; + ParmList* plist = CopyParmList(Getattr(n, "parms")); + Parm* p; + Parm* pnext; int start_arg_num = is_wrapping_class() ? 1 : 0; - addMissingParameterNames(plist, start_arg_num); // for $1_name substitutions done in Swig_typemap_attach_parms + addMissingParameterNames(plist, start_arg_num); // for $1_name substitutions done in Swig_typemap_attach_parms Swig_typemap_attach_parms("in", plist, 0); Swig_typemap_attach_parms("doc", plist, 0); for (p = plist; p; p = pnext) { - String *tm = Getattr(p, "tmap:in"); + String* tm = Getattr(p, "tmap:in"); if (tm) { pnext = Getattr(p, "tmap:in:next"); if (checkAttribute(p, "tmap:in:numinputs", "0")) { @@ -445,10 +458,10 @@ public: pnext = nextSibling(p); } - String *name = 0; - String *type = 0; - String *value = 0; - String *pdoc = Getattr(p, "tmap:doc"); + String* name = 0; + String* type = 0; + String* value = 0; + String* pdoc = Getattr(p, "tmap:doc"); if (pdoc) { name = Getattr(p, "tmap:doc:name"); type = Getattr(p, "tmap:doc:type"); @@ -458,46 +471,51 @@ public: // Note: the generated name should be consistent with that in kwnames[] name = name ? name : Getattr(p, "name"); name = name ? name : Getattr(p, "lname"); - name = Swig_name_make(p, 0, name, 0, 0); // rename parameter if a keyword + name = Swig_name_make(p, 0, name, 0, 0); // rename parameter if a keyword type = type ? type : Getattr(p, "type"); value = value ? value : Getattr(p, "value"); - if (SwigType_isvarargs(type)) + if (SwigType_isvarargs(type)) { break; + } - String *tex_name = NewString(""); - if (name) + String* tex_name = NewStringEmpty(); + if (name) { Printf(tex_name, "@var{%s}", name); - else + } else { Printf(tex_name, "@var{?}"); + } - if (Len(decl_str)) + if (Len(decl_str)) { Append(decl_str, ", "); + } Append(decl_str, tex_name); if (value) { - String *new_value = convertValue(value, Getattr(p, "type")); + String* new_value = convertValue(value, Getattr(p, "type")); if (new_value) { value = new_value; } else { - Node *lookup = Swig_symbol_clookup(value, 0); - if (lookup) + Node* lookup = Swig_symbol_clookup(value, 0); + if (lookup) { value = Getattr(lookup, "sym:name"); + } } Printf(decl_str, " = %s", value); } - Node *nn = classLookup(Getattr(p, "type")); - String *type_str = nn ? Copy(Getattr(nn, "sym:name")) : SwigType_str(type, 0); + Node* nn = classLookup(Getattr(p, "type")); + String* type_str = nn ? Copy(Getattr(nn, "sym:name")) : SwigType_str(type, 0); Printf(args_str, "%s is of type %s. ", tex_name, type_str); Delete(type_str); Delete(tex_name); Delete(name); } - if (pdocs) + if (pdocs) { Setattr(n, "feature:pdocs", pdocs); + } Delete(plist); } @@ -506,58 +524,65 @@ public: * Check if string v can be an Octave value literal, * (eg. number or string), or translate it to an Octave literal. * ------------------------------------------------------------ */ - String *convertValue(String *v, SwigType *t) { + String* convertValue(String* v, SwigType* t) { if (v && Len(v) > 0) { - char fc = (Char(v))[0]; + char fc = (Char(v)) [0]; if (('0' <= fc && fc <= '9') || '\'' == fc || '"' == fc) { /* number or string (or maybe NULL pointer) */ - if (SwigType_ispointer(t) && Strcmp(v, "0") == 0) + if (SwigType_ispointer(t) && Strcmp(v, "0") == 0) { return NewString("None"); - else + } else { return v; + } } - if (Strcmp(v, "NULL") == 0 || Strcmp(v, "nullptr") == 0) + if (Strcmp(v, "NULL") == 0 || Strcmp(v, "nullptr") == 0) { return SwigType_ispointer(t) ? NewString("nil") : NewString("0"); - if (Strcmp(v, "true") == 0 || Strcmp(v, "TRUE") == 0) + } + if (Strcmp(v, "true") == 0 || Strcmp(v, "TRUE") == 0) { return NewString("true"); - if (Strcmp(v, "false") == 0 || Strcmp(v, "FALSE") == 0) + } + if (Strcmp(v, "false") == 0 || Strcmp(v, "FALSE") == 0) { return NewString("false"); + } } return 0; } - virtual int functionWrapper(Node *n) { - Parm *p; - String *tm; + virtual int functionWrapper(Node* n) { + Parm* p; + String* tm; int j; - String *nodeType = Getattr(n, "nodeType"); + String* nodeType = Getattr(n, "nodeType"); int constructor = (!Cmp(nodeType, "constructor")); int destructor = (!Cmp(nodeType, "destructor")); - String *storage = Getattr(n, "storage"); + String* storage = Getattr(n, "storage"); bool overloaded = !!Getattr(n, "sym:overloaded"); bool last_overload = overloaded && !Getattr(n, "sym:nextSibling"); - String *iname = Getattr(n, "sym:name"); - String *wname = Swig_name_wrapper(iname); - String *overname = Copy(wname); - SwigType *d = Getattr(n, "type"); - ParmList *l = Getattr(n, "parms"); + String* iname = Getattr(n, "sym:name"); + String* wname = Swig_name_wrapper(iname); + String* overname = Copy(wname); + SwigType* d = Getattr(n, "type"); + ParmList* l = Getattr(n, "parms"); - if (!overloaded && !addSymbol(iname, n)) + if (!overloaded && !addSymbol(iname, n)) { return SWIG_ERROR; + } - if (overloaded) + if (overloaded) { Append(overname, Getattr(n, "sym:overname")); + } - if (!overloaded || last_overload) + if (!overloaded || last_overload) { process_autodoc(n); + } - Wrapper *f = NewWrapper(); - Octave_begin_function(n, f->def, iname, overname, !overloaded); + Wrapper* w = NewWrapper(); + Octave_begin_function(n, w->def, iname, overname, !overloaded); - emit_parameter_variables(l, f); - emit_attach_parmmaps(l, f); + emit_parameter_variables(l, w); + emit_attach_parmmaps(l, w); Setattr(n, "wrap:parms", l); int num_arguments = emit_num_arguments(l); @@ -565,15 +590,15 @@ public: int varargs = emit_isvarargs(l); char source[64]; - Printf(f->code, "if (!SWIG_check_num_args(\"%s\",args.length(),%i,%i,%i)) " + Printf(w->code, "if (!SWIG_check_num_args(\"%s\",args.length(),%i,%i,%i)) " "{\n SWIG_fail;\n }\n", iname, num_arguments, num_required, varargs); if (constructor && num_arguments == 1 && num_required == 1) { if (Cmp(storage, "explicit") == 0) { - Node *parent = Swig_methodclass(n); + Node* parent = Swig_methodclass(n); if (GetFlag(parent, "feature:implicitconv")) { - String *desc = NewStringf("SWIGTYPE%s", SwigType_manglestr(Getattr(n, "type"))); - Printf(f->code, "if (SWIG_CheckImplicit(%s)) SWIG_fail;\n", desc); + String* desc = NewStringf("SWIGTYPE%s", SwigType_manglestr(Getattr(n, "type"))); + Printf(w->code, "if (SWIG_CheckImplicit(%s)) SWIG_fail;\n", desc); Delete(desc); } } @@ -584,9 +609,9 @@ public: p = Getattr(p, "tmap:in:next"); } - SwigType *pt = Getattr(p, "type"); + SwigType* pt = Getattr(p, "type"); - String *tm = Getattr(p, "tmap:in"); + String* tm = Getattr(p, "tmap:in"); if (tm) { if (!tm || checkAttribute(p, "tmap:in:numinputs", "0")) { p = nextSibling(p); @@ -607,21 +632,22 @@ public: } if (Getattr(p, "tmap:in:implicitconv")) { - const char *convflag = "0"; + const char* convflag = "0"; if (!Getattr(p, "hidden")) { - SwigType *ptype = Getattr(p, "type"); + SwigType* ptype = Getattr(p, "type"); convflag = get_implicitconv_flag(classLookup(ptype)); } Replaceall(tm, "$implicitconv", convflag); Setattr(p, "implicitconv", convflag); } - String *getargs = NewString(""); - if (j >= num_required) + String* getargs = NewStringEmpty(); + if (j >= num_required) { Printf(getargs, "if (%dcode, getargs, "\n", NIL); + } + Printv(w->code, getargs, "\n", NIL); Delete(getargs); p = Getattr(p, "tmap:in:next"); @@ -636,7 +662,7 @@ public: if (varargs) { if (p && (tm = Getattr(p, "tmap:in"))) { Replaceall(tm, "$input", "varargs"); - Printv(f->code, tm, "\n", NIL); + Printv(w->code, tm, "\n", NIL); } } @@ -644,7 +670,7 @@ public: for (p = l; p;) { if ((tm = Getattr(p, "tmap:check"))) { Replaceall(tm, "$target", Getattr(p, "lname")); - Printv(f->code, tm, "\n", NIL); + Printv(w->code, tm, "\n", NIL); p = Getattr(p, "tmap:check:next"); } else { p = nextSibling(p); @@ -652,13 +678,13 @@ public: } // Insert cleanup code - String *cleanup = NewString(""); + String* cleanup = NewStringEmpty(); for (p = l; p;) { if ((tm = Getattr(p, "tmap:freearg"))) { if (Getattr(p, "tmap:freearg:implicitconv")) { - const char *convflag = "0"; + const char* convflag = "0"; if (!Getattr(p, "hidden")) { - SwigType *ptype = Getattr(p, "type"); + SwigType* ptype = Getattr(p, "type"); convflag = get_implicitconv_flag(classLookup(ptype)); } if (strcmp(convflag, "0") == 0) { @@ -676,7 +702,7 @@ public: } // Insert argument output code - String *outarg = NewString(""); + String* outarg = NewStringEmpty(); for (p = l; p;) { if ((tm = Getattr(p, "tmap:argout"))) { Replaceall(tm, "$source", Getattr(p, "lname")); @@ -693,73 +719,75 @@ public: int director_method = is_member_director(n) && !is_smart_pointer() && !destructor; if (director_method) { - Wrapper_add_local(f, "upcall", "bool upcall = false"); - Append(f->code, "upcall = !!dynamic_cast(arg1);\n"); + Wrapper_add_local(w, "upcall", "bool upcall = false"); + Append(w->code, "upcall = !!dynamic_cast(arg1);\n"); } Setattr(n, "wrap:name", overname); - Swig_director_emit_dynamic_cast(n, f); - String *actioncode = emit_action(n); + Swig_director_emit_dynamic_cast(n, w); + String* actioncode = emit_action(n); - Wrapper_add_local(f, "_out", "octave_value_list _out"); - Wrapper_add_local(f, "_outp", "octave_value_list *_outp=&_out"); - Wrapper_add_local(f, "_outv", "octave_value _outv"); + Wrapper_add_local(w, "_out", "octave_value_list _out"); + Wrapper_add_local(w, "_outp", "octave_value_list *_outp=&_out"); + Wrapper_add_local(w, "_outv", "octave_value _outv"); // Return the function value - if ((tm = Swig_typemap_lookup_out("out", n, Swig_cresult_name(), f, actioncode))) { + if ((tm = Swig_typemap_lookup_out("out", n, Swig_cresult_name(), w, actioncode))) { Replaceall(tm, "$source", Swig_cresult_name()); Replaceall(tm, "$target", "_outv"); Replaceall(tm, "$result", "_outv"); - if (GetFlag(n, "feature:new")) + if (GetFlag(n, "feature:new")) { Replaceall(tm, "$owner", "1"); - else + } else { Replaceall(tm, "$owner", "0"); + } - Printf(f->code, "%s\n", tm); - Printf(f->code, "if (_outv.is_defined()) _outp = " "SWIG_Octave_AppendOutput(_outp, _outv);\n"); + Printf(w->code, "%s\n", tm); + Printf(w->code, "if (_outv.is_defined()) _outp = " "SWIG_Octave_AppendOutput(_outp, _outv);\n"); Delete(tm); } else { Swig_warning(WARN_TYPEMAP_OUT_UNDEF, input_file, line_number, "Unable to use return type %s in function %s.\n", SwigType_str(d, 0), iname); } - emit_return_variable(n, d, f); + emit_return_variable(n, d, w); - Printv(f->code, outarg, NIL); - Printv(f->code, cleanup, NIL); + Printv(w->code, outarg, NIL); + Printv(w->code, cleanup, NIL); if (GetFlag(n, "feature:new")) { if ((tm = Swig_typemap_lookup("newfree", n, Swig_cresult_name(), 0))) { Replaceall(tm, "$source", Swig_cresult_name()); - Printf(f->code, "%s\n", tm); + Printf(w->code, "%s\n", tm); } } if ((tm = Swig_typemap_lookup("ret", n, Swig_cresult_name(), 0))) { Replaceall(tm, "$source", Swig_cresult_name()); Replaceall(tm, "$result", "_outv"); - Printf(f->code, "%s\n", tm); + Printf(w->code, "%s\n", tm); Delete(tm); } - Printf(f->code, "return _out;\n"); - Printf(f->code, "fail:\n"); // we should free locals etc if this happens - Printv(f->code, cleanup, NIL); - Printf(f->code, "return octave_value_list();\n"); - Printf(f->code, "}\n"); + Printf(w->code, "return _out;\n"); + Printf(w->code, "fail:\n"); // we should free locals etc if this happens + Printv(w->code, cleanup, NIL); + Printf(w->code, "return octave_value_list();\n"); + Printf(w->code, "}\n"); /* Substitute the cleanup code */ - Replaceall(f->code, "$cleanup", cleanup); + Replaceall(w->code, "$cleanup", cleanup); - Replaceall(f->code, "$symname", iname); - Wrapper_print(f, f_wrappers); - DelWrapper(f); + Replaceall(w->code, "$symname", iname); + Wrapper_print(w, f_wrappers); + DelWrapper(w); - if (last_overload) + if (last_overload) { dispatchFunction(n); + } if (!overloaded || last_overload) { - String *tname = texinfo_name(n); + String* tname = texinfo_name(n); Printf(s_global_tab, "{\"%s\",%s,0,0,2,%s},\n", iname, wname, tname); Delete(tname); } @@ -772,54 +800,56 @@ public: return SWIG_OK; } - void dispatchFunction(Node *n) { - Wrapper *f = NewWrapper(); + void dispatchFunction(Node* n) { + Wrapper* w = NewWrapper(); - String *iname = Getattr(n, "sym:name"); - String *wname = Swig_name_wrapper(iname); + String* iname = Getattr(n, "sym:name"); + String* wname = Swig_name_wrapper(iname); int maxargs; - String *dispatch = Swig_overload_dispatch(n, "return %s(args, nargout);", &maxargs); - String *tmp = NewString(""); + String* dispatch = Swig_overload_dispatch(n, "return %s(args, nargout);", &maxargs); + String* tmp = NewStringEmpty(); - Octave_begin_function(n, f->def, iname, wname, true); - Wrapper_add_local(f, "argc", "int argc = args.length()"); + Octave_begin_function(n, w->def, iname, wname, true); + Wrapper_add_local(w, "argc", "int argc = args.length()"); Printf(tmp, "octave_value_ref argv[%d]={", maxargs); - for (int j = 0; j < maxargs; ++j) + for (int j = 0; j < maxargs; ++j) { Printf(tmp, "%soctave_value_ref(args,%d)", j ? "," : " ", j); + } Printf(tmp, "}"); - Wrapper_add_local(f, "argv", tmp); - Printv(f->code, dispatch, "\n", NIL); - Printf(f->code, "error(\"No matching function for overload\");\n", iname); - Printf(f->code, "return octave_value_list();\n"); - Printv(f->code, "}\n", NIL); + Wrapper_add_local(w, "argv", tmp); + Printv(w->code, dispatch, "\n", NIL); + Printf(w->code, "error(\"No matching function for overload\");\n", iname); + Printf(w->code, "return octave_value_list();\n"); + Printv(w->code, "}\n", NIL); - Wrapper_print(f, f_wrappers); + Wrapper_print(w, f_wrappers); Delete(tmp); - DelWrapper(f); + DelWrapper(w); Delete(dispatch); Delete(wname); } - virtual int variableWrapper(Node *n) { - String *name = Getattr(n, "name"); - String *iname = Getattr(n, "sym:name"); - SwigType *t = Getattr(n, "type"); + virtual int variableWrapper(Node* n) { + String* name = Getattr(n, "name"); + String* iname = Getattr(n, "sym:name"); + SwigType* t = Getattr(n, "type"); - if (!addSymbol(iname, n)) + if (!addSymbol(iname, n)) { return SWIG_ERROR; + } - String *tm; - Wrapper *getf = NewWrapper(); - Wrapper *setf = NewWrapper(); + String* tm; + Wrapper* getw = NewWrapper(); + Wrapper* setw = NewWrapper(); - String *getname = Swig_name_get(NSPACE_TODO, iname); - String *setname = Swig_name_set(NSPACE_TODO, iname); + String* getname = Swig_name_get(NSPACE_TODO, iname); + String* setname = Swig_name_set(NSPACE_TODO, iname); - String *getwname = Swig_name_wrapper(getname); - String *setwname = Swig_name_wrapper(setname); + String* getwname = Swig_name_wrapper(getname); + String* setwname = Swig_name_wrapper(setname); - Octave_begin_function(n, setf->def, setname, setwname, true); - Printf(setf->def, "if (!SWIG_check_num_args(\"%s_set\",args.length(),1,1,0)) return octave_value_list();", iname); + Octave_begin_function(n, setw->def, setname, setwname, true); + Printf(setw->def, "if (!SWIG_check_num_args(\"%s_set\",args.length(),1,1,0)) return octave_value_list();", iname); if (is_assignable(n)) { Setattr(n, "wrap:name", setname); if ((tm = Swig_typemap_lookup("varin", n, name, 0))) { @@ -829,65 +859,66 @@ public: if (Getattr(n, "tmap:varin:implicitconv")) { Replaceall(tm, "$implicitconv", get_implicitconv_flag(n)); } - emit_action_code(n, setf->code, tm); + emit_action_code(n, setw->code, tm); Delete(tm); } else { Swig_warning(WARN_TYPEMAP_VARIN_UNDEF, input_file, line_number, "Unable to set variable of type %s.\n", SwigType_str(t, 0)); } - Append(setf->code, "fail:\n"); - Printf(setf->code, "return octave_value_list();\n"); + Append(setw->code, "fail:\n"); + Printf(setw->code, "return octave_value_list();\n"); } else { - Printf(setf->code, "return octave_set_immutable(args,nargout);"); + Printf(setw->code, "return octave_set_immutable(args,nargout);"); } - Append(setf->code, "}\n"); - Wrapper_print(setf, f_wrappers); + Append(setw->code, "}\n"); + Wrapper_print(setw, f_wrappers); Setattr(n, "wrap:name", getname); int addfail = 0; - Octave_begin_function(n, getf->def, getname, getwname, true); - Wrapper_add_local(getf, "obj", "octave_value obj"); + Octave_begin_function(n, getw->def, getname, getwname, true); + Wrapper_add_local(getw, "obj", "octave_value obj"); if ((tm = Swig_typemap_lookup("varout", n, name, 0))) { Replaceall(tm, "$source", name); Replaceall(tm, "$target", "obj"); Replaceall(tm, "$result", "obj"); - addfail = emit_action_code(n, getf->code, tm); + addfail = emit_action_code(n, getw->code, tm); Delete(tm); } else { Swig_warning(WARN_TYPEMAP_VAROUT_UNDEF, input_file, line_number, "Unable to read variable of type %s\n", SwigType_str(t, 0)); } - Append(getf->code, " return obj;\n"); + Append(getw->code, " return obj;\n"); if (addfail) { - Append(getf->code, "fail:\n"); - Append(getf->code, " return octave_value_list();\n"); + Append(getw->code, "fail:\n"); + Append(getw->code, " return octave_value_list();\n"); } - Append(getf->code, "}\n"); - Wrapper_print(getf, f_wrappers); + Append(getw->code, "}\n"); + Wrapper_print(getw, f_wrappers); Printf(s_global_tab, "{\"%s\",0,%s,%s,2,0},\n", iname, getwname, setwname); Delete(getwname); Delete(setwname); - DelWrapper(setf); - DelWrapper(getf); + DelWrapper(setw); + DelWrapper(getw); return SWIG_OK; } - virtual int constantWrapper(Node *n) { - String *name = Getattr(n, "name"); - String *iname = Getattr(n, "sym:name"); - SwigType *type = Getattr(n, "type"); - String *rawval = Getattr(n, "rawval"); - String *value = rawval ? rawval : Getattr(n, "value"); - String *cppvalue = Getattr(n, "cppvalue"); - String *tm; + virtual int constantWrapper(Node* n) { + String* name = Getattr(n, "name"); + String* iname = Getattr(n, "sym:name"); + SwigType* type = Getattr(n, "type"); + String* rawval = Getattr(n, "rawval"); + String* value = rawval ? rawval : Getattr(n, "value"); + String* cppvalue = Getattr(n, "cppvalue"); + String* tm; - if (!addSymbol(iname, n)) + if (!addSymbol(iname, n)) { return SWIG_ERROR; + } if (SwigType_type(type) == T_MPOINTER) { - String *wname = Swig_name_wrapper(iname); - String *str = SwigType_str(type, wname); + String* wname = Swig_name_wrapper(iname); + String* str = SwigType_str(type, wname); Printf(f_header, "static %s = %s;\n", str, value); Delete(str); value = wname; @@ -906,36 +937,37 @@ public: return SWIG_OK; } - virtual int nativeWrapper(Node *n) { + virtual int nativeWrapper(Node* n) { return Language::nativeWrapper(n); } - virtual int enumDeclaration(Node *n) { + virtual int enumDeclaration(Node* n) { return Language::enumDeclaration(n); } - virtual int enumvalueDeclaration(Node *n) { + virtual int enumvalueDeclaration(Node* n) { return Language::enumvalueDeclaration(n); } - virtual int classDeclaration(Node *n) { + virtual int classDeclaration(Node* n) { return Language::classDeclaration(n); } - virtual int classHandler(Node *n) { + virtual int classHandler(Node* n) { have_constructor = 0; have_destructor = 0; constructor_name = 0; class_name = Getattr(n, "sym:name"); - if (!addSymbol(class_name, n)) + if (!addSymbol(class_name, n)) { return SWIG_ERROR; + } // This is a bug, due to the fact that swig_type -> octave_class mapping // is 1-to-n. - static Hash *emitted = NewHash(); - String *mangled_classname = Swig_name_mangle(Getattr(n, "name")); + static Hash* emitted = NewHash(); + String* mangled_classname = Swig_name_mangle(Getattr(n, "name")); if (Getattr(emitted, mangled_classname)) { Delete(mangled_classname); return SWIG_NOWRAP; @@ -944,24 +976,24 @@ public: Delete(mangled_classname); assert(!s_members_tab); - s_members_tab = NewString(""); + s_members_tab = NewStringEmpty(); Printv(s_members_tab, "static swig_octave_member swig_", class_name, "_members[] = {\n", NIL); Language::classHandler(n); - SwigType *t = Copy(Getattr(n, "name")); + SwigType* t = Copy(Getattr(n, "name")); SwigType_add_pointer(t); - String *wrap_class = NewStringf("&_wrap_class_%s", class_name); + String* wrap_class = NewStringf("&_wrap_class_%s", class_name); SwigType_remember_clientdata(t, wrap_class); int use_director = Swig_directorclass(n); if (use_director) { - String *nspace = Getattr(n, "sym:nspace"); - String *cname = Swig_name_disown(nspace, class_name); - String *wcname = Swig_name_wrapper(cname); - String *cnameshdw = NewStringf("%s_shadow", cname); - String *wcnameshdw = Swig_name_wrapper(cnameshdw); + String* nspace = Getattr(n, "sym:nspace"); + String* cname = Swig_name_disown(nspace, class_name); + String* wcname = Swig_name_wrapper(cname); + String* cnameshdw = NewStringf("%s_shadow", cname); + String* wcnameshdw = Swig_name_wrapper(cnameshdw); Octave_begin_function(n, f_wrappers, cnameshdw, wcnameshdw, true); Printf(f_wrappers, " if (args.length()!=1) {\n"); Printf(f_wrappers, " error(\"disown takes no arguments\");\n"); @@ -980,21 +1012,21 @@ public: Printf(s_members_tab, "{0,0,0,0}\n};\n"); Printv(f_wrappers, s_members_tab, NIL); - String *base_class_names = NewString(""); - String *base_class = NewString(""); - List *baselist = Getattr(n, "bases"); + String* base_class_names = NewStringEmpty(); + String* base_class = NewStringEmpty(); + List* baselist = Getattr(n, "bases"); if (baselist && Len(baselist)) { Iterator b; int index = 0; b = First(baselist); while (b.item) { - String *bname = Getattr(b.item, "name"); + String* bname = Getattr(b.item, "name"); if ((!bname) || GetFlag(b.item, "feature:ignore") || (!Getattr(b.item, "module"))) { b = Next(b); continue; } - String *bname_mangled = SwigType_manglestr(SwigType_add_pointer(Copy(bname))); + String* bname_mangled = SwigType_manglestr(SwigType_add_pointer(Copy(bname))); Printf(base_class_names, "\"%s\",", bname_mangled); Printf(base_class, "0,"); b = Next(b); @@ -1008,25 +1040,27 @@ public: Printv(f_wrappers, "static swig_octave_class _wrap_class_", class_name, " = {\"", class_name, "\", &SWIGTYPE", SwigType_manglestr(t), ",", NIL); Printv(f_wrappers, Swig_directorclass(n) ? "1," : "0,", NIL); if (have_constructor) { - String *nspace = Getattr(n, "sym:nspace"); - String *cname = Swig_name_construct(nspace, constructor_name); - String *wcname = Swig_name_wrapper(cname); - String *tname = texinfo_name(n); + String* nspace = Getattr(n, "sym:nspace"); + String* cname = Swig_name_construct(nspace, constructor_name); + String* wcname = Swig_name_wrapper(cname); + String* tname = texinfo_name(n); Printf(f_wrappers, "%s,%s,", wcname, tname); Delete(tname); Delete(wcname); Delete(cname); - } else + } else { Printv(f_wrappers, "0,0,", NIL); + } if (have_destructor) { - String *nspace = Getattr(n, "sym:nspace"); - String *cname = Swig_name_destroy(nspace, class_name); - String *wcname = Swig_name_wrapper(cname); + String* nspace = Getattr(n, "sym:nspace"); + String* cname = Swig_name_destroy(nspace, class_name); + String* wcname = Swig_name_wrapper(cname); Printf(f_wrappers, "%s,", wcname); Delete(wcname); Delete(cname); - } else + } else { Printv(f_wrappers, "0", ",", NIL); + } Printf(f_wrappers, "swig_%s_members,swig_%s_base_names,swig_%s_base };\n\n", class_name, class_name, class_name); Delete(base_class); @@ -1039,23 +1073,24 @@ public: return SWIG_OK; } - virtual int memberfunctionHandler(Node *n) { + virtual int memberfunctionHandler(Node* n) { Language::memberfunctionHandler(n); assert(s_members_tab); assert(class_name); - String *name = Getattr(n, "name"); - String *iname = GetChar(n, "sym:name"); - String *realname = iname ? iname : name; - String *wname = Getattr(n, "wrap:name"); + String* name = Getattr(n, "name"); + String* iname = GetChar(n, "sym:name"); + String* realname = iname ? iname : name; + String* wname = Getattr(n, "wrap:name"); assert(wname); if (!Getattr(n, "sym:nextSibling")) { - String *tname = texinfo_name(n); - String *rname = Copy(wname); + String* tname = texinfo_name(n); + String* rname = Copy(wname); bool overloaded = !!Getattr(n, "sym:overloaded"); - if (overloaded) + if (overloaded) { Delslice(rname, Len(rname) - Len(Getattr(n, "sym:overname")), DOH_END); + } Printf(s_members_tab, "{\"%s\",%s,0,0,0,%s},\n", realname, rname, tname); Delete(rname); @@ -1065,18 +1100,18 @@ public: return SWIG_OK; } - virtual int membervariableHandler(Node *n) { + virtual int membervariableHandler(Node* n) { Setattr(n, "feature:autodoc", "0"); Language::membervariableHandler(n); assert(s_members_tab); assert(class_name); - String *symname = Getattr(n, "sym:name"); - String *getname = Swig_name_get(NSPACE_TODO, Swig_name_member(NSPACE_TODO, class_name, symname)); - String *setname = Swig_name_set(NSPACE_TODO, Swig_name_member(NSPACE_TODO, class_name, symname)); - String *getwname = Swig_name_wrapper(getname); - String *setwname = GetFlag(n, "feature:immutable") ? NewString("octave_set_immutable") : Swig_name_wrapper(setname); + String* symname = Getattr(n, "sym:name"); + String* getname = Swig_name_get(NSPACE_TODO, Swig_name_member(NSPACE_TODO, class_name, symname)); + String* setname = Swig_name_set(NSPACE_TODO, Swig_name_member(NSPACE_TODO, class_name, symname)); + String* getwname = Swig_name_wrapper(getname); + String* setwname = GetFlag(n, "feature:immutable") ? NewString("octave_set_immutable") : Swig_name_wrapper(setname); assert(s_members_tab); Printf(s_members_tab, "{\"%s\",0,%s,%s,0,0},\n", symname, getwname, setwname); @@ -1088,24 +1123,26 @@ public: return SWIG_OK; } - virtual int constructorHandler(Node *n) { + virtual int constructorHandler(Node* n) { have_constructor = 1; - if (!constructor_name) + if (!constructor_name) { constructor_name = NewString(Getattr(n, "sym:name")); + } int use_director = Swig_directorclass(n); if (use_director) { - Parm *parms = Getattr(n, "parms"); - Parm *self; - String *name = NewString("self"); - String *type = NewString("void"); + Parm* parms = Getattr(n, "parms"); + Parm* self; + String* name = NewString("self"); + String* type = NewString("void"); SwigType_add_pointer(type); self = NewParm(type, name, n); Delete(type); Delete(name); Setattr(self, "lname", "self_obj"); - if (parms) + if (parms) { set_nextSibling(self, parms); + } Setattr(n, "parms", self); Setattr(n, "wrap:self", "1"); Setattr(n, "hidden", "1"); @@ -1115,28 +1152,29 @@ public: return Language::constructorHandler(n); } - virtual int destructorHandler(Node *n) { + virtual int destructorHandler(Node* n) { have_destructor = 1; return Language::destructorHandler(n); } - virtual int staticmemberfunctionHandler(Node *n) { + virtual int staticmemberfunctionHandler(Node* n) { Language::staticmemberfunctionHandler(n); assert(s_members_tab); assert(class_name); - String *name = Getattr(n, "name"); - String *iname = GetChar(n, "sym:name"); - String *realname = iname ? iname : name; - String *wname = Getattr(n, "wrap:name"); + String* name = Getattr(n, "name"); + String* iname = GetChar(n, "sym:name"); + String* realname = iname ? iname : name; + String* wname = Getattr(n, "wrap:name"); assert(wname); if (!Getattr(n, "sym:nextSibling")) { - String *tname = texinfo_name(n); - String *rname = Copy(wname); + String* tname = texinfo_name(n); + String* rname = Copy(wname); bool overloaded = !!Getattr(n, "sym:overloaded"); - if (overloaded) + if (overloaded) { Delslice(rname, Len(rname) - Len(Getattr(n, "sym:overname")), DOH_END); + } Printf(s_members_tab, "{\"%s\",%s,0,0,1,%s},\n", realname, rname, tname); Delete(rname); @@ -1146,11 +1184,11 @@ public: return SWIG_OK; } - virtual int memberconstantHandler(Node *n) { + virtual int memberconstantHandler(Node* n) { return Language::memberconstantHandler(n); } - virtual int staticmembervariableHandler(Node *n) { + virtual int staticmembervariableHandler(Node* n) { Setattr(n, "feature:autodoc", "0"); Language::staticmembervariableHandler(n); @@ -1158,11 +1196,11 @@ public: if (!GetFlag(n, "wrappedasconstant")) { assert(s_members_tab); assert(class_name); - String *symname = Getattr(n, "sym:name"); - String *getname = Swig_name_get(NSPACE_TODO, Swig_name_member(NSPACE_TODO, class_name, symname)); - String *setname = Swig_name_set(NSPACE_TODO, Swig_name_member(NSPACE_TODO, class_name, symname)); - String *getwname = Swig_name_wrapper(getname); - String *setwname = GetFlag(n, "feature:immutable") ? NewString("octave_set_immutable") : Swig_name_wrapper(setname); + String* symname = Getattr(n, "sym:name"); + String* getname = Swig_name_get(NSPACE_TODO, Swig_name_member(NSPACE_TODO, class_name, symname)); + String* setname = Swig_name_set(NSPACE_TODO, Swig_name_member(NSPACE_TODO, class_name, symname)); + String* getwname = Swig_name_wrapper(getname); + String* setwname = GetFlag(n, "feature:immutable") ? NewString("octave_set_immutable") : Swig_name_wrapper(setname); assert(s_members_tab); Printf(s_members_tab, "{\"%s\",0,%s,%s,1,0},\n", symname, getwname, setwname); @@ -1175,8 +1213,8 @@ public: return SWIG_OK; } - int classDirectorInit(Node *n) { - String *declaration = Swig_director_declaration(n); + int classDirectorInit(Node* n) { + String* declaration = Swig_director_declaration(n); Printf(f_directors_h, "\n"); Printf(f_directors_h, "%s\n", declaration); Printf(f_directors_h, "public:\n"); @@ -1184,24 +1222,24 @@ public: return Language::classDirectorInit(n); } - int classDirectorEnd(Node *n) { + int classDirectorEnd(Node* n) { Printf(f_directors_h, "};\n\n"); return Language::classDirectorEnd(n); } - int classDirectorConstructor(Node *n) { - Node *parent = Getattr(n, "parentNode"); - String *sub = NewString(""); - String *decl = Getattr(n, "decl"); - String *supername = Swig_class_name(parent); - String *classname = NewString(""); + int classDirectorConstructor(Node* n) { + Node* parent = Getattr(n, "parentNode"); + String* sub = NewStringEmpty(); + String* decl = Getattr(n, "decl"); + String* supername = Swig_class_name(parent); + String* classname = NewStringEmpty(); Printf(classname, "SwigDirector_%s", supername); // insert self parameter - Parm *p; - ParmList *superparms = Getattr(n, "parms"); - ParmList *parms = CopyParmList(superparms); - String *type = NewString("void"); + Parm* p; + ParmList* superparms = Getattr(n, "parms"); + ParmList* parms = CopyParmList(superparms); + String* type = NewString("void"); SwigType_add_pointer(type); p = NewParm(type, NewString("self"), n); set_nextSibling(p, parms); @@ -1210,10 +1248,10 @@ public: if (!Getattr(n, "defaultargs")) { // constructor { - Wrapper *w = NewWrapper(); - String *call; - String *basetype = Getattr(parent, "classtype"); - String *target = Swig_method_decl(0, decl, classname, parms, 0, 0); + Wrapper* w = NewWrapper(); + String* call; + String* basetype = Getattr(parent, "classtype"); + String* target = Swig_method_decl(0, decl, classname, parms, 0, 0); call = Swig_csuperclass_call(0, basetype, superparms); Printf(w->def, "%s::%s: %s," "\nSwig::Director(static_cast<%s*>(this)) { \n", classname, target, call, basetype); Append(w->def, "}\n"); @@ -1225,7 +1263,7 @@ public: // constructor header { - String *target = Swig_method_decl(0, decl, classname, parms, 0, 1); + String* target = Swig_method_decl(0, decl, classname, parms, 0, 1); Printf(f_directors_h, " %s;\n", target); Delete(target); } @@ -1238,10 +1276,10 @@ public: return Language::classDirectorConstructor(n); } - int classDirectorDefaultConstructor(Node *n) { - String *classname = Swig_class_name(n); + int classDirectorDefaultConstructor(Node* n) { + String* classname = Swig_class_name(n); { - Wrapper *w = NewWrapper(); + Wrapper* w = NewWrapper(); Printf(w->def, "SwigDirector_%s::SwigDirector_%s(void* self) :" "\nSwig::Director((octave_swig_type*)self,static_cast<%s*>(this)) { \n", classname, classname, classname); Append(w->def, "}\n"); @@ -1253,22 +1291,22 @@ public: return Language::classDirectorDefaultConstructor(n); } - int classDirectorMethod(Node *n, Node *parent, String *super) { + int classDirectorMethod(Node* n, Node* parent, String* super) { int is_void = 0; int is_pointer = 0; - String *decl = Getattr(n, "decl"); - String *returntype = Getattr(n, "type"); - String *name = Getattr(n, "name"); - String *classname = Getattr(parent, "sym:name"); - String *c_classname = Getattr(parent, "name"); - String *symname = Getattr(n, "sym:name"); - String *declaration = NewString(""); - ParmList *l = Getattr(n, "parms"); - Wrapper *w = NewWrapper(); - String *tm; - String *wrap_args = NewString(""); - String *value = Getattr(n, "value"); - String *storage = Getattr(n, "storage"); + String* decl = Getattr(n, "decl"); + String* returntype = Getattr(n, "type"); + String* name = Getattr(n, "name"); + String* classname = Getattr(parent, "sym:name"); + String* c_classname = Getattr(parent, "name"); + String* symname = Getattr(n, "sym:name"); + String* declaration = NewStringEmpty(); + ParmList* l = Getattr(n, "parms"); + Wrapper* w = NewWrapper(); + String* tm; + String* wrap_args = NewStringEmpty(); + String* value = Getattr(n, "value"); + String* storage = Getattr(n, "storage"); bool pure_virtual = false; int status = SWIG_OK; int idx; @@ -1285,10 +1323,10 @@ public: is_void = (!Cmp(returntype, "void") && !is_pointer); // virtual method definition - String *target; - String *pclassname = NewStringf("SwigDirector_%s", classname); - String *qualified_name = NewStringf("%s::%s", pclassname, name); - SwigType *rtype = Getattr(n, "conversion_operator") ? 0 : Getattr(n, "classDirectorMethods:type"); + String* target; + String* pclassname = NewStringf("SwigDirector_%s", classname); + String* qualified_name = NewStringf("%s::%s", pclassname, name); + SwigType* rtype = Getattr(n, "conversion_operator") ? 0 : Getattr(n, "classDirectorMethods:type"); target = Swig_method_decl(rtype, decl, qualified_name, l, 0, 0); Printf(w->def, "%s", target); Delete(qualified_name); @@ -1300,24 +1338,25 @@ public: Delete(target); // Get any exception classes in the throws typemap - ParmList *throw_parm_list = 0; + ParmList* throw_parm_list = 0; if ((throw_parm_list = Getattr(n, "throws")) || Getattr(n, "throw")) { - Parm *p; + Parm* p; int gencomma = 0; Append(w->def, " throw("); Append(declaration, " throw("); - if (throw_parm_list) + if (throw_parm_list) { Swig_typemap_attach_parms("throws", throw_parm_list, 0); + } for (p = throw_parm_list; p; p = nextSibling(p)) { if (Getattr(p, "tmap:throws")) { if (gencomma++) { Append(w->def, ", "); Append(declaration, ", "); } - String *str = SwigType_str(Getattr(p, "type"), 0); + String* str = SwigType_str(Getattr(p, "type"), 0); Append(w->def, str); Append(declaration, str); Delete(str); @@ -1336,7 +1375,7 @@ public: // handle it, including declaration of c_result ($result). if (!is_void) { if (!(ignored_method && !pure_virtual)) { - String *cres = SwigType_lstr(returntype, "c_result"); + String* cres = SwigType_lstr(returntype, "c_result"); Printf(w->code, "%s;\n", cres); Delete(cres); } @@ -1344,9 +1383,10 @@ public: if (ignored_method) { if (!pure_virtual) { - if (!is_void) + if (!is_void) { Printf(w->code, "return "); - String *super_call = Swig_method_call(super, l); + } + String* super_call = Swig_method_call(super, l); Printf(w->code, "%s;\n", super_call); Delete(super_call); } else { @@ -1355,7 +1395,7 @@ public: } } else { // attach typemaps to arguments (C/C++ -> Python) - String *parse_args = NewString(""); + String* parse_args = NewStringEmpty(); Swig_director_parms_fixup(l); @@ -1363,11 +1403,12 @@ public: Swig_typemap_attach_parms("directorin", l, 0); Swig_typemap_attach_parms("directorargout", l, w); - Parm *p; + Parm* p; int outputs = 0; - if (!is_void) + if (!is_void) { outputs++; + } // build argument list and type conversion string p = l; @@ -1377,15 +1418,16 @@ public: continue; } - if (Getattr(p, "tmap:directorargout") != 0) + if (Getattr(p, "tmap:directorargout") != 0) { outputs++; + } - String *pname = Getattr(p, "name"); - String *ptype = Getattr(p, "type"); + String* pname = Getattr(p, "name"); + String* ptype = Getattr(p, "type"); Wrapper_add_local(w, "tmpv", "octave_value tmpv"); if ((tm = Getattr(p, "tmap:directorin")) != 0) { - String *parse = Getattr(p, "tmap:directorin:parse"); + String* parse = Getattr(p, "tmap:directorin:parse"); if (!parse) { Setattr(p, "emit:directorinput", "tmpv"); Replaceall(tm, "$input", "tmpv"); @@ -1398,8 +1440,9 @@ public: Setattr(p, "emit:directorinput", pname); Replaceall(tm, "$input", pname); Replaceall(tm, "$owner", "0"); - if (Len(tm) == 0) + if (Len(tm) == 0) { Append(tm, pname); + } } p = Getattr(p, "tmap:directorin:next"); continue; @@ -1413,7 +1456,7 @@ public: p = nextSibling(p); } - String *method_name = Getattr(n, "sym:name"); + String* method_name = Getattr(n, "sym:name"); Printv(w->code, wrap_args, NIL); @@ -1425,8 +1468,8 @@ public: Printf(w->code, "idx.push_back(args);\n"); Printf(w->code, "out=swig_get_self()->subsref(\".(\",idx,%d);\n", outputs); - String *cleanup = NewString(""); - String *outarg = NewString(""); + String* cleanup = NewStringEmpty(); + String* outarg = NewStringEmpty(); idx = 0; // marshal return value @@ -1479,7 +1522,7 @@ public: if (!is_void) { if (!(ignored_method && !pure_virtual)) { - String *rettype = SwigType_str(returntype, 0); + String* rettype = SwigType_str(returntype, 0); if (!SwigType_isreference(returntype)) { Printf(w->code, "return (%s) c_result;\n", rettype); } else { @@ -1492,15 +1535,16 @@ public: Append(w->code, "}\n"); // We expose protected methods via an extra public inline method which makes a straight call to the wrapped class' method - String *inline_extra_method = NewString(""); + String* inline_extra_method = NewStringEmpty(); if (dirprot_mode() && !is_public(n) && !pure_virtual) { Printv(inline_extra_method, declaration, NIL); - String *extra_method_name = NewStringf("%sSwigPublic", name); + String* extra_method_name = NewStringf("%sSwigPublic", name); Replaceall(inline_extra_method, name, extra_method_name); Replaceall(inline_extra_method, ";\n", " {\n "); - if (!is_void) + if (!is_void) { Printf(inline_extra_method, "return "); - String *methodcall = Swig_method_call(super, l); + } + String* methodcall = Swig_method_call(super, l); Printv(inline_extra_method, methodcall, ";\n }\n", NIL); Delete(methodcall); Delete(extra_method_name); @@ -1521,9 +1565,9 @@ public: return status; } - String *runtimeCode() { - String *s = NewString(""); - String *srun = Swig_include_sys("octrun.swg"); + String* runtimeCode() { + String* s = NewStringEmpty(); + String* srun = Swig_include_sys("octrun.swg"); if (!srun) { Printf(stderr, "*** Unable to open 'octrun.swg'\n"); } else { @@ -1533,11 +1577,12 @@ public: return s; } - String *defaultExternalRuntimeFilename() { + String* defaultExternalRuntimeFilename() { return NewString("swigoctaverun.h"); } }; -extern "C" Language *swig_octave(void) { +extern "C" Language* swig_octave(void) +{ return new OCTAVE(); } -- cgit v1.2.1 From 6c04378e20ee20cbadca7c3d887941e270990faf Mon Sep 17 00:00:00 2001 From: Karl Wette Date: Sat, 4 Oct 2014 13:42:42 +0200 Subject: Octave: simplify Examples/octave/example.mk --- Examples/octave/example.mk | 37 ++++++++++++++++++++++--------------- 1 file changed, 22 insertions(+), 15 deletions(-) diff --git a/Examples/octave/example.mk b/Examples/octave/example.mk index e0b1e4efb..ac36cca91 100644 --- a/Examples/octave/example.mk +++ b/Examples/octave/example.mk @@ -6,27 +6,34 @@ SWIG = $(TOP)/../preinst-swig TARGET = swigexample INTERFACE = example.i -check: build - $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' octave_run +BUILDCMD = \ + $(MAKE) -f $(TOP)/Makefile \ + SRCDIR='$(SRCDIR)' \ + SWIG='$(SWIG)' \ + INTERFACE='$(INTERFACE)' -build: ifneq (,$(SRCS)) - $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SRCS='$(SRCS)' SWIG='$(SWIG)' \ - SWIGOPT='$(SWIGOPT)' TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' octave + BUILDCMD += SRCS='$(SRCS)' + BUILDTARGET = octave else - $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ - SWIGOPT='$(SWIGOPT)' TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' octave_cpp + BUILDCMD += CXXSRCS='$(CXXSRCS)' + BUILDTARGET = octave_cpp endif + +check: build + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' octave_run + +build: + $(BUILDCMD) SWIGOPT='$(SWIGOPT)' TARGET='$(TARGET)' $(BUILDTARGET) + ifneq (,$(TARGET2)$(SWIGOPT2)) -ifneq (,$(SRCS)) - $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SRCS='$(SRCS)' SWIG='$(SWIG)' \ - SWIGOPT='$(SWIGOPT2)' TARGET='$(TARGET2)' INTERFACE='$(INTERFACE)' octave -else - $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ - SWIGOPT='$(SWIGOPT2)' TARGET='$(TARGET2)' INTERFACE='$(INTERFACE)' octave_cpp -endif -endif +check: build2 + +build2: + $(BUILDCMD) SWIGOPT='$(SWIGOPT2)' TARGET='$(TARGET2)' $(BUILDTARGET) + +endif clean: $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' octave_clean -- cgit v1.2.1 From bf12d76d037dddb68c294cd77c3ad1f6b6d2e985 Mon Sep 17 00:00:00 2001 From: Karl Wette Date: Mon, 2 Jun 2014 03:02:47 +0200 Subject: Octave: cleanup/restructure library files - Restructure runtime code into declarations, function and class definitions, and initialisation code - Rename internal functions/types to follow SWIG_Octave... or SwigOct... naming styles - Style/comment/whitespace cleanups --- Lib/octave/attribute.i | 4 + Lib/octave/boost_shared_ptr.i | 183 +++--- Lib/octave/carrays.i | 6 +- Lib/octave/cdata.i | 4 + Lib/octave/cmalloc.i | 4 + Lib/octave/director.swg | 132 ---- Lib/octave/exception.i | 7 +- Lib/octave/factory.i | 4 + Lib/octave/implicit.i | 5 +- Lib/octave/octave.swg | 15 +- Lib/octave/octcomplex.swg | 129 ++-- Lib/octave/octcontainer.swg | 985 ++++++++++++++--------------- Lib/octave/octfragments.swg | 19 + Lib/octave/octiterators.swg | 582 +++++++++-------- Lib/octave/octopers.swg | 17 +- Lib/octave/octprimtypes.swg | 365 ++++++----- Lib/octave/octrun.swg | 1389 ----------------------------------------- Lib/octave/octrunclass.swg | 1203 +++++++++++++++++++++++++++++++++++ Lib/octave/octrundecl.swg | 479 ++++++++++++++ Lib/octave/octrunfunc.swg | 187 ++++++ Lib/octave/octruninit.swg | 422 +++++++++++++ Lib/octave/octruntime.swg | 333 +--------- Lib/octave/octstdcommon.swg | 408 ++++++------ Lib/octave/octtypemaps.swg | 55 +- Lib/octave/octuserdir.swg | 119 ++-- Lib/octave/std_alloc.i | 4 + Lib/octave/std_basic_string.i | 96 +-- Lib/octave/std_carray.i | 3 + Lib/octave/std_char_traits.i | 4 + Lib/octave/std_common.i | 120 ++-- Lib/octave/std_complex.i | 19 +- Lib/octave/std_container.i | 4 + Lib/octave/std_deque.i | 19 +- Lib/octave/std_except.i | 4 + Lib/octave/std_list.i | 20 +- Lib/octave/std_map.i | 149 ++--- Lib/octave/std_pair.i | 214 ++++--- Lib/octave/std_string.i | 4 + Lib/octave/std_vector.i | 13 +- Lib/octave/stl.i | 5 +- Lib/octave/typemaps.i | 4 + Source/Modules/octave.cxx | 50 +- 42 files changed, 4187 insertions(+), 3601 deletions(-) delete mode 100644 Lib/octave/director.swg delete mode 100644 Lib/octave/octrun.swg create mode 100644 Lib/octave/octrunclass.swg create mode 100644 Lib/octave/octrundecl.swg create mode 100644 Lib/octave/octrunfunc.swg create mode 100644 Lib/octave/octruninit.swg diff --git a/Lib/octave/attribute.i b/Lib/octave/attribute.i index 779716cd2..104e4f436 100644 --- a/Lib/octave/attribute.i +++ b/Lib/octave/attribute.i @@ -1 +1,5 @@ +// +// attribute.i - Attribute support +// + %include diff --git a/Lib/octave/boost_shared_ptr.i b/Lib/octave/boost_shared_ptr.i index 93b1a896f..44868ccac 100644 --- a/Lib/octave/boost_shared_ptr.i +++ b/Lib/octave/boost_shared_ptr.i @@ -1,3 +1,7 @@ +// +// boost_shared_ptr.i - Boost shared pointer support +// + %include // Language specific macro implementing all the customisations for handling the smart pointer @@ -10,30 +14,32 @@ // destructor wrapper customisation %feature("unref") TYPE //"if (debug_shared) { cout << \"deleting use_count: \" << (*smartarg1).use_count() << \" [\" << (boost::get_deleter(*smartarg1) ? std::string(\"CANNOT BE DETERMINED SAFELY\") : ( (*smartarg1).get() ? (*smartarg1)->getValue() : std::string(\"NULL PTR\") )) << \"]\" << endl << flush; }\n" - "(void)arg1; delete smartarg1;" + "(void)arg1; delete smartarg1;" -// Typemap customisations... +///// Typemap customisations ///// -// plain value -%typemap(in) CONST TYPE (void *argp, int res = 0) { +// Plain value +%typemap(in) CONST TYPE(void* argp, int res = 0) { int newmem = 0; res = SWIG_ConvertPtrAndOwn($input, &argp, $descriptor(SWIG_SHARED_PTR_QNAMESPACE::shared_ptr< TYPE > *), %convertptr_flags, &newmem); if (!SWIG_IsOK(res)) { - %argument_fail(res, "$type", $symname, $argnum); + %argument_fail(res, "$type", $symname, $argnum); } if (!argp) { %argument_nullref("$type", $symname, $argnum); } else { $1 = *(%reinterpret_cast(argp, SWIG_SHARED_PTR_QNAMESPACE::shared_ptr< CONST TYPE > *)->get()); - if (newmem & SWIG_CAST_NEW_MEMORY) delete %reinterpret_cast(argp, SWIG_SHARED_PTR_QNAMESPACE::shared_ptr< CONST TYPE > *); + if (newmem & SWIG_CAST_NEW_MEMORY) { + delete %reinterpret_cast(argp, SWIG_SHARED_PTR_QNAMESPACE::shared_ptr< CONST TYPE > *); + } } } %typemap(out) CONST TYPE { - %set_output(SWIG_NewPointerObj(new SWIG_SHARED_PTR_QNAMESPACE::shared_ptr< CONST TYPE >(new $1_ltype(($1_ltype &)$1)), $descriptor(SWIG_SHARED_PTR_QNAMESPACE::shared_ptr< TYPE > *), SWIG_POINTER_OWN)); + %set_output(SWIG_NewPointerObj(new SWIG_SHARED_PTR_QNAMESPACE::shared_ptr< CONST TYPE > (new $1_ltype(($1_ltype &) $1)), $descriptor(SWIG_SHARED_PTR_QNAMESPACE::shared_ptr< TYPE > *), SWIG_POINTER_OWN)); } %typemap(varin) CONST TYPE { - void *argp = 0; + void* argp = 0; int newmem = 0; int res = SWIG_ConvertPtrAndOwn($input, &argp, $descriptor(SWIG_SHARED_PTR_QNAMESPACE::shared_ptr< TYPE > *), %convertptr_flags, &newmem); if (!SWIG_IsOK(res)) { @@ -43,20 +49,22 @@ %argument_nullref("$type", $symname, $argnum); } else { $1 = *(%reinterpret_cast(argp, SWIG_SHARED_PTR_QNAMESPACE::shared_ptr< CONST TYPE > *)->get()); - if (newmem & SWIG_CAST_NEW_MEMORY) delete %reinterpret_cast(argp, SWIG_SHARED_PTR_QNAMESPACE::shared_ptr< CONST TYPE > *); + if (newmem & SWIG_CAST_NEW_MEMORY) { + delete %reinterpret_cast(argp, SWIG_SHARED_PTR_QNAMESPACE::shared_ptr< CONST TYPE > *); + } } } %typemap(varout) CONST TYPE { - %set_varoutput(SWIG_NewPointerObj(new SWIG_SHARED_PTR_QNAMESPACE::shared_ptr< CONST TYPE >(new $1_ltype(($1_ltype &)$1)), $descriptor(SWIG_SHARED_PTR_QNAMESPACE::shared_ptr< TYPE > *), SWIG_POINTER_OWN)); + %set_varoutput(SWIG_NewPointerObj(new SWIG_SHARED_PTR_QNAMESPACE::shared_ptr< CONST TYPE > (new $1_ltype(($1_ltype &) $1)), $descriptor(SWIG_SHARED_PTR_QNAMESPACE::shared_ptr< TYPE > *), SWIG_POINTER_OWN)); } -// plain pointer +// Plain pointer // Note: $disown not implemented as it will lead to a memory leak of the shared_ptr instance -%typemap(in) CONST TYPE * (void *argp = 0, int res = 0, SWIG_SHARED_PTR_QNAMESPACE::shared_ptr< CONST TYPE > tempshared, SWIG_SHARED_PTR_QNAMESPACE::shared_ptr< CONST TYPE > *smartarg = 0) { +%typemap(in) CONST TYPE* (void* argp = 0, int res = 0, SWIG_SHARED_PTR_QNAMESPACE::shared_ptr< CONST TYPE > tempshared, SWIG_SHARED_PTR_QNAMESPACE::shared_ptr< CONST TYPE > *smartarg = 0) { int newmem = 0; res = SWIG_ConvertPtrAndOwn($input, &argp, $descriptor(SWIG_SHARED_PTR_QNAMESPACE::shared_ptr< TYPE > *), %convertptr_flags, &newmem); if (!SWIG_IsOK(res)) { - %argument_fail(res, "$type", $symname, $argnum); + %argument_fail(res, "$type", $symname, $argnum); } if (newmem & SWIG_CAST_NEW_MEMORY) { tempshared = *%reinterpret_cast(argp, SWIG_SHARED_PTR_QNAMESPACE::shared_ptr< CONST TYPE > *); @@ -67,13 +75,13 @@ $1 = %const_cast((smartarg ? smartarg->get() : 0), $1_ltype); } } -%typemap(out, fragment="SWIG_null_deleter") CONST TYPE * { - SWIG_SHARED_PTR_QNAMESPACE::shared_ptr< CONST TYPE > *smartresult = $1 ? new SWIG_SHARED_PTR_QNAMESPACE::shared_ptr< CONST TYPE >($1 SWIG_NO_NULL_DELETER_$owner) : 0; +%typemap(out, fragment = "SWIG_null_deleter") CONST TYPE* { + SWIG_SHARED_PTR_QNAMESPACE::shared_ptr< CONST TYPE > *smartresult = $1 ? new SWIG_SHARED_PTR_QNAMESPACE::shared_ptr< CONST TYPE > ($1 SWIG_NO_NULL_DELETER_$owner) : 0; %set_output(SWIG_NewPointerObj(%as_voidptr(smartresult), $descriptor(SWIG_SHARED_PTR_QNAMESPACE::shared_ptr< TYPE > *), $owner | SWIG_POINTER_OWN)); } -%typemap(varin) CONST TYPE * { - void *argp = 0; +%typemap(varin) CONST TYPE* { + void* argp = 0; int newmem = 0; int res = SWIG_ConvertPtrAndOwn($input, &argp, $descriptor(SWIG_SHARED_PTR_QNAMESPACE::shared_ptr< TYPE > *), %convertptr_flags, &newmem); if (!SWIG_IsOK(res)) { @@ -90,19 +98,21 @@ $1 = %const_cast((smartarg ? smartarg->get() : 0), $1_ltype); } } -%typemap(varout, fragment="SWIG_null_deleter") CONST TYPE * { - SWIG_SHARED_PTR_QNAMESPACE::shared_ptr< CONST TYPE > *smartresult = $1 ? new SWIG_SHARED_PTR_QNAMESPACE::shared_ptr< CONST TYPE >($1 SWIG_NO_NULL_DELETER_0) : 0; +%typemap(varout, fragment = "SWIG_null_deleter") CONST TYPE* { + SWIG_SHARED_PTR_QNAMESPACE::shared_ptr< CONST TYPE > *smartresult = $1 ? new SWIG_SHARED_PTR_QNAMESPACE::shared_ptr< CONST TYPE > ($1 SWIG_NO_NULL_DELETER_0) : 0; %set_varoutput(SWIG_NewPointerObj(%as_voidptr(smartresult), $descriptor(SWIG_SHARED_PTR_QNAMESPACE::shared_ptr< TYPE > *), SWIG_POINTER_OWN)); } -// plain reference -%typemap(in) CONST TYPE & (void *argp = 0, int res = 0, SWIG_SHARED_PTR_QNAMESPACE::shared_ptr< CONST TYPE > tempshared) { +// Plain reference +%typemap(in) CONST TYPE& (void* argp = 0, int res = 0, SWIG_SHARED_PTR_QNAMESPACE::shared_ptr< CONST TYPE > tempshared) { int newmem = 0; res = SWIG_ConvertPtrAndOwn($input, &argp, $descriptor(SWIG_SHARED_PTR_QNAMESPACE::shared_ptr< TYPE > *), %convertptr_flags, &newmem); if (!SWIG_IsOK(res)) { - %argument_fail(res, "$type", $symname, $argnum); + %argument_fail(res, "$type", $symname, $argnum); + } + if (!argp) { + %argument_nullref("$type", $symname, $argnum); } - if (!argp) { %argument_nullref("$type", $symname, $argnum); } if (newmem & SWIG_CAST_NEW_MEMORY) { tempshared = *%reinterpret_cast(argp, SWIG_SHARED_PTR_QNAMESPACE::shared_ptr< CONST TYPE > *); delete %reinterpret_cast(argp, SWIG_SHARED_PTR_QNAMESPACE::shared_ptr< CONST TYPE > *); @@ -111,20 +121,22 @@ $1 = %const_cast(%reinterpret_cast(argp, SWIG_SHARED_PTR_QNAMESPACE::shared_ptr< CONST TYPE > *)->get(), $1_ltype); } } -%typemap(out, fragment="SWIG_null_deleter") CONST TYPE & { - SWIG_SHARED_PTR_QNAMESPACE::shared_ptr< CONST TYPE > *smartresult = new SWIG_SHARED_PTR_QNAMESPACE::shared_ptr< CONST TYPE >($1 SWIG_NO_NULL_DELETER_$owner); +%typemap(out, fragment = "SWIG_null_deleter") CONST TYPE& { + SWIG_SHARED_PTR_QNAMESPACE::shared_ptr< CONST TYPE > *smartresult = new SWIG_SHARED_PTR_QNAMESPACE::shared_ptr< CONST TYPE > ($1 SWIG_NO_NULL_DELETER_$owner); %set_output(SWIG_NewPointerObj(%as_voidptr(smartresult), $descriptor(SWIG_SHARED_PTR_QNAMESPACE::shared_ptr< TYPE > *), SWIG_POINTER_OWN)); } -%typemap(varin) CONST TYPE & { - void *argp = 0; +%typemap(varin) CONST TYPE& { + void* argp = 0; int newmem = 0; int res = SWIG_ConvertPtrAndOwn($input, &argp, $descriptor(SWIG_SHARED_PTR_QNAMESPACE::shared_ptr< TYPE > *), %convertptr_flags, &newmem); if (!SWIG_IsOK(res)) { %variable_fail(res, "$type", "$name"); } SWIG_SHARED_PTR_QNAMESPACE::shared_ptr< CONST TYPE > tempshared; - if (!argp) { %argument_nullref("$type", $symname, $argnum); } + if (!argp) { + %argument_nullref("$type", $symname, $argnum); + } if (newmem & SWIG_CAST_NEW_MEMORY) { tempshared = *%reinterpret_cast(argp, SWIG_SHARED_PTR_QNAMESPACE::shared_ptr< CONST TYPE > *); delete %reinterpret_cast(argp, SWIG_SHARED_PTR_QNAMESPACE::shared_ptr< CONST TYPE > *); @@ -133,18 +145,18 @@ $1 = *%const_cast(%reinterpret_cast(argp, SWIG_SHARED_PTR_QNAMESPACE::shared_ptr< CONST TYPE > *)->get(), $1_ltype); } } -%typemap(varout, fragment="SWIG_null_deleter") CONST TYPE & { - SWIG_SHARED_PTR_QNAMESPACE::shared_ptr< CONST TYPE > *smartresult = new SWIG_SHARED_PTR_QNAMESPACE::shared_ptr< CONST TYPE >(&$1 SWIG_NO_NULL_DELETER_0); +%typemap(varout, fragment = "SWIG_null_deleter") CONST TYPE& { + SWIG_SHARED_PTR_QNAMESPACE::shared_ptr< CONST TYPE > *smartresult = new SWIG_SHARED_PTR_QNAMESPACE::shared_ptr< CONST TYPE > (&$1 SWIG_NO_NULL_DELETER_0); %set_varoutput(SWIG_NewPointerObj(%as_voidptr(smartresult), $descriptor(SWIG_SHARED_PTR_QNAMESPACE::shared_ptr< TYPE > *), SWIG_POINTER_OWN)); } -// plain pointer by reference +// Plain pointer by reference // Note: $disown not implemented as it will lead to a memory leak of the shared_ptr instance -%typemap(in) TYPE *CONST& (void *argp = 0, int res = 0, $*1_ltype temp = 0, SWIG_SHARED_PTR_QNAMESPACE::shared_ptr< CONST TYPE > tempshared) { +%typemap(in) TYPE* CONST& (void* argp = 0, int res = 0, $*1_ltype temp = 0, SWIG_SHARED_PTR_QNAMESPACE::shared_ptr< CONST TYPE > tempshared) { int newmem = 0; res = SWIG_ConvertPtrAndOwn($input, &argp, $descriptor(SWIG_SHARED_PTR_QNAMESPACE::shared_ptr< TYPE > *), %convertptr_flags, &newmem); if (!SWIG_IsOK(res)) { - %argument_fail(res, "$type", $symname, $argnum); + %argument_fail(res, "$type", $symname, $argnum); } if (newmem & SWIG_CAST_NEW_MEMORY) { tempshared = *%reinterpret_cast(argp, SWIG_SHARED_PTR_QNAMESPACE::shared_ptr< CONST TYPE > *); @@ -155,57 +167,65 @@ } $1 = &temp; } -%typemap(out, fragment="SWIG_null_deleter") TYPE *CONST& { - SWIG_SHARED_PTR_QNAMESPACE::shared_ptr< CONST TYPE > *smartresult = new SWIG_SHARED_PTR_QNAMESPACE::shared_ptr< CONST TYPE >(*$1 SWIG_NO_NULL_DELETER_$owner); +%typemap(out, fragment = "SWIG_null_deleter") TYPE * CONST& { + SWIG_SHARED_PTR_QNAMESPACE::shared_ptr< CONST TYPE > *smartresult = new SWIG_SHARED_PTR_QNAMESPACE::shared_ptr< CONST TYPE > (*$1 SWIG_NO_NULL_DELETER_$owner); %set_output(SWIG_NewPointerObj(%as_voidptr(smartresult), $descriptor(SWIG_SHARED_PTR_QNAMESPACE::shared_ptr< TYPE > *), SWIG_POINTER_OWN)); } -%typemap(varin) TYPE *CONST& %{ +%typemap(varin) TYPE* CONST& %{ #error "varin typemap not implemented" %} -%typemap(varout) TYPE *CONST& %{ +%typemap(varout) TYPE* CONST& %{ #error "varout typemap not implemented" %} -// shared_ptr by value -%typemap(in) SWIG_SHARED_PTR_QNAMESPACE::shared_ptr< CONST TYPE > (void *argp, int res = 0) { +// Shared_ptr by value +%typemap(in) SWIG_SHARED_PTR_QNAMESPACE::shared_ptr< CONST TYPE > (void* argp, int res = 0) { int newmem = 0; res = SWIG_ConvertPtrAndOwn($input, &argp, $descriptor(SWIG_SHARED_PTR_QNAMESPACE::shared_ptr< TYPE > *), %convertptr_flags, &newmem); if (!SWIG_IsOK(res)) { - %argument_fail(res, "$type", $symname, $argnum); + %argument_fail(res, "$type", $symname, $argnum); + } + if (argp) { + $1 = *(%reinterpret_cast(argp, $<ype)); + } + if (newmem & SWIG_CAST_NEW_MEMORY) { + delete %reinterpret_cast(argp, $<ype); } - if (argp) $1 = *(%reinterpret_cast(argp, $<ype)); - if (newmem & SWIG_CAST_NEW_MEMORY) delete %reinterpret_cast(argp, $<ype); } %typemap(out) SWIG_SHARED_PTR_QNAMESPACE::shared_ptr< CONST TYPE > { - SWIG_SHARED_PTR_QNAMESPACE::shared_ptr< CONST TYPE > *smartresult = $1 ? new SWIG_SHARED_PTR_QNAMESPACE::shared_ptr< CONST TYPE >($1) : 0; + SWIG_SHARED_PTR_QNAMESPACE::shared_ptr< CONST TYPE > *smartresult = $1 ? new SWIG_SHARED_PTR_QNAMESPACE::shared_ptr< CONST TYPE > ($1) : 0; %set_output(SWIG_NewPointerObj(%as_voidptr(smartresult), $descriptor(SWIG_SHARED_PTR_QNAMESPACE::shared_ptr< TYPE > *), SWIG_POINTER_OWN)); } %typemap(varin) SWIG_SHARED_PTR_QNAMESPACE::shared_ptr< CONST TYPE > { int newmem = 0; - void *argp = 0; + void* argp = 0; int res = SWIG_ConvertPtrAndOwn($input, &argp, $descriptor(SWIG_SHARED_PTR_QNAMESPACE::shared_ptr< TYPE > *), %convertptr_flags, &newmem); if (!SWIG_IsOK(res)) { %variable_fail(res, "$type", "$name"); } $1 = argp ? *(%reinterpret_cast(argp, $<ype)) : SWIG_SHARED_PTR_QNAMESPACE::shared_ptr< TYPE >(); - if (newmem & SWIG_CAST_NEW_MEMORY) delete %reinterpret_cast(argp, $<ype); + if (newmem & SWIG_CAST_NEW_MEMORY) { + delete %reinterpret_cast(argp, $<ype); + } } %typemap(varout) SWIG_SHARED_PTR_QNAMESPACE::shared_ptr< CONST TYPE > { - SWIG_SHARED_PTR_QNAMESPACE::shared_ptr< CONST TYPE > *smartresult = $1 ? new SWIG_SHARED_PTR_QNAMESPACE::shared_ptr< CONST TYPE >($1) : 0; + SWIG_SHARED_PTR_QNAMESPACE::shared_ptr< CONST TYPE > *smartresult = $1 ? new SWIG_SHARED_PTR_QNAMESPACE::shared_ptr< CONST TYPE > ($1) : 0; %set_varoutput(SWIG_NewPointerObj(%as_voidptr(smartresult), $descriptor(SWIG_SHARED_PTR_QNAMESPACE::shared_ptr< TYPE > *), SWIG_POINTER_OWN)); } -// shared_ptr by reference -%typemap(in) SWIG_SHARED_PTR_QNAMESPACE::shared_ptr< CONST TYPE > & (void *argp, int res = 0, $*1_ltype tempshared) { +// Shared_ptr by reference +%typemap(in) SWIG_SHARED_PTR_QNAMESPACE::shared_ptr< CONST TYPE > & (void* argp, int res = 0, $*1_ltype tempshared) { int newmem = 0; res = SWIG_ConvertPtrAndOwn($input, &argp, $descriptor(SWIG_SHARED_PTR_QNAMESPACE::shared_ptr< TYPE > *), %convertptr_flags, &newmem); if (!SWIG_IsOK(res)) { - %argument_fail(res, "$type", $symname, $argnum); + %argument_fail(res, "$type", $symname, $argnum); } if (newmem & SWIG_CAST_NEW_MEMORY) { - if (argp) tempshared = *%reinterpret_cast(argp, $ltype); + if (argp) { + tempshared = *%reinterpret_cast(argp, $ltype); + } delete %reinterpret_cast(argp, $ltype); $1 = &tempshared; } else { @@ -213,7 +233,7 @@ } } %typemap(out) SWIG_SHARED_PTR_QNAMESPACE::shared_ptr< CONST TYPE > & { - SWIG_SHARED_PTR_QNAMESPACE::shared_ptr< CONST TYPE > *smartresult = *$1 ? new SWIG_SHARED_PTR_QNAMESPACE::shared_ptr< CONST TYPE >(*$1) : 0; + SWIG_SHARED_PTR_QNAMESPACE::shared_ptr< CONST TYPE > *smartresult = *$1 ? new SWIG_SHARED_PTR_QNAMESPACE::shared_ptr< CONST TYPE > (*$1) : 0; %set_output(SWIG_NewPointerObj(%as_voidptr(smartresult), $descriptor(SWIG_SHARED_PTR_QNAMESPACE::shared_ptr< TYPE > *), SWIG_POINTER_OWN)); } @@ -224,15 +244,17 @@ #error "varout typemap not implemented" %} -// shared_ptr by pointer -%typemap(in) SWIG_SHARED_PTR_QNAMESPACE::shared_ptr< CONST TYPE > * (void *argp, int res = 0, $*1_ltype tempshared) { +// Shared_ptr by pointer +%typemap(in) SWIG_SHARED_PTR_QNAMESPACE::shared_ptr< CONST TYPE > * (void* argp, int res = 0, $*1_ltype tempshared) { int newmem = 0; res = SWIG_ConvertPtrAndOwn($input, &argp, $descriptor(SWIG_SHARED_PTR_QNAMESPACE::shared_ptr< TYPE > *), %convertptr_flags, &newmem); if (!SWIG_IsOK(res)) { - %argument_fail(res, "$type", $symname, $argnum); + %argument_fail(res, "$type", $symname, $argnum); } if (newmem & SWIG_CAST_NEW_MEMORY) { - if (argp) tempshared = *%reinterpret_cast(argp, $ltype); + if (argp) { + tempshared = *%reinterpret_cast(argp, $ltype); + } delete %reinterpret_cast(argp, $ltype); $1 = &tempshared; } else { @@ -240,9 +262,11 @@ } } %typemap(out) SWIG_SHARED_PTR_QNAMESPACE::shared_ptr< CONST TYPE > * { - SWIG_SHARED_PTR_QNAMESPACE::shared_ptr< CONST TYPE > *smartresult = $1 && *$1 ? new SWIG_SHARED_PTR_QNAMESPACE::shared_ptr< CONST TYPE >(*$1) : 0; + SWIG_SHARED_PTR_QNAMESPACE::shared_ptr< CONST TYPE > *smartresult = $1 && *$1 ? new SWIG_SHARED_PTR_QNAMESPACE::shared_ptr< CONST TYPE > (*$1) : 0; %set_output(SWIG_NewPointerObj(%as_voidptr(smartresult), $descriptor(SWIG_SHARED_PTR_QNAMESPACE::shared_ptr< TYPE > *), SWIG_POINTER_OWN)); - if ($owner) delete $1; + if ($owner) { + delete $1; + } } %typemap(varin) SWIG_SHARED_PTR_QNAMESPACE::shared_ptr< CONST TYPE > * %{ @@ -252,20 +276,24 @@ #error "varout typemap not implemented" %} -// shared_ptr by pointer reference -%typemap(in) SWIG_SHARED_PTR_QNAMESPACE::shared_ptr< CONST TYPE > *& (void *argp, int res = 0, SWIG_SHARED_PTR_QNAMESPACE::shared_ptr< CONST TYPE > tempshared, $*1_ltype temp = 0) { +// Shared_ptr by pointer reference +%typemap(in) SWIG_SHARED_PTR_QNAMESPACE::shared_ptr< CONST TYPE > *& (void* argp, int res = 0, SWIG_SHARED_PTR_QNAMESPACE::shared_ptr< CONST TYPE > tempshared, $*1_ltype temp = 0) { int newmem = 0; res = SWIG_ConvertPtrAndOwn($input, &argp, $descriptor(SWIG_SHARED_PTR_QNAMESPACE::shared_ptr< TYPE > *), %convertptr_flags, &newmem); if (!SWIG_IsOK(res)) { - %argument_fail(res, "$type", $symname, $argnum); + %argument_fail(res, "$type", $symname, $argnum); + } + if (argp) { + tempshared = *%reinterpret_cast(argp, $*ltype); + } + if (newmem & SWIG_CAST_NEW_MEMORY) { + delete %reinterpret_cast(argp, $*ltype); } - if (argp) tempshared = *%reinterpret_cast(argp, $*ltype); - if (newmem & SWIG_CAST_NEW_MEMORY) delete %reinterpret_cast(argp, $*ltype); temp = &tempshared; $1 = &temp; } %typemap(out) SWIG_SHARED_PTR_QNAMESPACE::shared_ptr< CONST TYPE > *& { - SWIG_SHARED_PTR_QNAMESPACE::shared_ptr< CONST TYPE > *smartresult = *$1 && **$1 ? new SWIG_SHARED_PTR_QNAMESPACE::shared_ptr< CONST TYPE >(**$1) : 0; + SWIG_SHARED_PTR_QNAMESPACE::shared_ptr< CONST TYPE > *smartresult = *$1 && **$1 ? new SWIG_SHARED_PTR_QNAMESPACE::shared_ptr< CONST TYPE > (**$1) : 0; %set_output(SWIG_NewPointerObj(%as_voidptr(smartresult), $descriptor(SWIG_SHARED_PTR_QNAMESPACE::shared_ptr< TYPE > *), SWIG_POINTER_OWN)); } @@ -277,31 +305,30 @@ %} // Typecheck typemaps -// Note: SWIG_ConvertPtr with void ** parameter set to 0 instead of using SWIG_ConvertPtrAndOwn, so that the casting +// Note: SWIG_ConvertPtr with void ** parameter set to 0 instead of using SWIG_ConvertPtrAndOwn, so that the casting // function is not called thereby avoiding a possible smart pointer copy constructor call when casting up the inheritance chain. -%typemap(typecheck,precedence=SWIG_TYPECHECK_POINTER,noblock=1) - TYPE CONST, - TYPE CONST &, - TYPE CONST *, - TYPE *CONST&, - SWIG_SHARED_PTR_QNAMESPACE::shared_ptr< CONST TYPE >, - SWIG_SHARED_PTR_QNAMESPACE::shared_ptr< CONST TYPE > &, - SWIG_SHARED_PTR_QNAMESPACE::shared_ptr< CONST TYPE > *, - SWIG_SHARED_PTR_QNAMESPACE::shared_ptr< CONST TYPE > *& { +%typemap(typecheck, precedence = SWIG_TYPECHECK_POINTER, noblock = 1) + TYPE CONST, + TYPE CONST&, + TYPE CONST*, + TYPE * CONST&, + SWIG_SHARED_PTR_QNAMESPACE::shared_ptr< CONST TYPE >, + SWIG_SHARED_PTR_QNAMESPACE::shared_ptr< CONST TYPE > &, + SWIG_SHARED_PTR_QNAMESPACE::shared_ptr< CONST TYPE > *, + SWIG_SHARED_PTR_QNAMESPACE::shared_ptr< CONST TYPE > *& +{ int res = SWIG_ConvertPtr($input, 0, $descriptor(SWIG_SHARED_PTR_QNAMESPACE::shared_ptr< TYPE > *), 0); $1 = SWIG_CheckState(res); } - -// various missing typemaps - If ever used (unlikely) ensure compilation error rather than runtime bug -%typemap(in) CONST TYPE[], CONST TYPE[ANY], CONST TYPE (CLASS::*) %{ +// Various missing typemaps - If ever used (unlikely) ensure compilation error rather than runtime bug +%typemap(in) CONST TYPE[], CONST TYPE[ANY], CONST TYPE(CLASS::*) %{ #error "typemaps for $1_type not available" %} -%typemap(out) CONST TYPE[], CONST TYPE[ANY], CONST TYPE (CLASS::*) %{ +%typemap(out) CONST TYPE[], CONST TYPE[ANY], CONST TYPE(CLASS::*) %{ #error "typemaps for $1_type not available" %} %template() SWIG_SHARED_PTR_QNAMESPACE::shared_ptr< CONST TYPE >; %enddef - diff --git a/Lib/octave/carrays.i b/Lib/octave/carrays.i index 014de37ff..6607b7664 100644 --- a/Lib/octave/carrays.i +++ b/Lib/octave/carrays.i @@ -1,5 +1,9 @@ +// +// carrays.i - Manipulate simple pointers as arrays +// + %define %array_class(TYPE,NAME) - %array_class_wrap(TYPE,NAME,__paren__,__paren_asgn__) +%array_class_wrap(TYPE,NAME,__paren__,__paren_asgn__) %enddef %include diff --git a/Lib/octave/cdata.i b/Lib/octave/cdata.i index 367965990..d626b5db0 100644 --- a/Lib/octave/cdata.i +++ b/Lib/octave/cdata.i @@ -1 +1,5 @@ +// +// cdata.i - Manipulate raw C data as strings +// + %include diff --git a/Lib/octave/cmalloc.i b/Lib/octave/cmalloc.i index 248f06b96..e8b5929b7 100644 --- a/Lib/octave/cmalloc.i +++ b/Lib/octave/cmalloc.i @@ -1 +1,5 @@ +// +// cmalloc.i - Object creation using C malloc() +// + %include diff --git a/Lib/octave/director.swg b/Lib/octave/director.swg deleted file mode 100644 index c399a6a89..000000000 --- a/Lib/octave/director.swg +++ /dev/null @@ -1,132 +0,0 @@ -/* ----------------------------------------------------------------------------- - * director.swg - * - * This file contains support for director classes so that D proxy - * methods can be called from C++. - * ----------------------------------------------------------------------------- */ - -# define SWIG_DIRECTOR_CAST(ARG) dynamic_cast(ARG) - -#include - -namespace Swig { - - class Director { - octave_swig_type *self; - bool swig_disowned; - - Director(const Director &x); - Director &operator=(const Director &rhs); - public: - - Director(void *vptr):self(0), swig_disowned(false) { - set_rtdir(vptr, this); - } - - ~Director() { - swig_director_destroyed(self, this); - if (swig_disowned) - self->decref(); - } - - void swig_set_self(octave_swig_type *new_self) { - assert(!swig_disowned); - self = new_self; - } - - octave_swig_type *swig_get_self() const { - return self; - } - - void swig_disown() { - if (swig_disowned) - return; - swig_disowned = true; - self->incref(); - } - }; - - struct DirectorTypeMismatchException { - static void raise(const char *msg) { - // ... todo - throw(DirectorTypeMismatchException()); - } - - static void raise(const octave_value &ov, const char *msg) { - // ... todo - raise(msg); - } - }; - - struct DirectorPureVirtualException { - static void raise(const char *msg) { - // ... todo - throw(DirectorPureVirtualException()); - } - - static void raise(const octave_value &ov, const char *msg) { - // ... todo - raise(msg); - } - }; - - SWIGINTERN rtdir_map *get_rtdir_map() { - static swig_module_info *module = 0; - if (!module) - module = SWIG_GetModule(0); - if (!module) - return 0; - if (!module->clientdata) - module->clientdata = new rtdir_map; - return (rtdir_map *) module->clientdata; - } - - SWIGINTERNINLINE void set_rtdir(void *vptr, Director *d) { - rtdir_map *rm = get_rtdir_map(); - if (rm) - (*rm)[vptr] = d; - } - - SWIGINTERNINLINE void erase_rtdir(void *vptr) { - rtdir_map *rm = get_rtdir_map(); - if (rm) - (*rm).erase(vptr); - } - - SWIGINTERNINLINE Director *get_rtdir(void *vptr) { - rtdir_map *rm = get_rtdir_map(); - if (!rm) - return 0; - rtdir_map::const_iterator pos = rm->find(vptr); - Director *rtdir = (pos != rm->end())? pos->second : 0; - return rtdir; - } - - SWIGRUNTIME void swig_director_destroyed(octave_swig_type *self, Director *d) { - self->director_destroyed(d); - } - - SWIGRUNTIME octave_swig_type *swig_director_get_self(Director *d) { - return d->swig_get_self(); - } - - SWIGRUNTIME void swig_director_set_self(Director *d, octave_swig_type *self) { - d->swig_set_self(self); - } - -} - -SWIGRUNTIME void swig_acquire_ownership(void *vptr) { - // assert(0); - // ... todo -} - -SWIGRUNTIME void swig_acquire_ownership_array(void *vptr) { - // assert(0); - // ... todo -} - -SWIGRUNTIME void swig_acquire_ownership_obj(void *vptr, int own) { - // assert(0); - // ... todo -} diff --git a/Lib/octave/exception.i b/Lib/octave/exception.i index bb0b15c9d..959bba7dd 100644 --- a/Lib/octave/exception.i +++ b/Lib/octave/exception.i @@ -1,6 +1,9 @@ -%include +// +// exception.i - C++ exception support +// +%include %insert("runtime") { - %define_as(SWIG_exception(code, msg), %block(%error(code, msg); SWIG_fail; )) +%define_as(SWIG_exception(code, msg), %block(%error(code, msg); SWIG_fail; )) } diff --git a/Lib/octave/factory.i b/Lib/octave/factory.i index 46a0a8733..029c81004 100644 --- a/Lib/octave/factory.i +++ b/Lib/octave/factory.i @@ -1 +1,5 @@ +// +// factory.i - Factory method wrapping +// + %include diff --git a/Lib/octave/implicit.i b/Lib/octave/implicit.i index 152c2b056..ceb05b7f7 100644 --- a/Lib/octave/implicit.i +++ b/Lib/octave/implicit.i @@ -1,7 +1,10 @@ +// +// implicit.i - %implicit directive +// + %include %include #warning "This file provides the %implicit directive, which is an old and fragile" #warning "way to implement the C++ implicit conversion mechanism." #warning "Try using the more robust '%implicitconv Type;' directive instead." - diff --git a/Lib/octave/octave.swg b/Lib/octave/octave.swg index 872054d88..b25931cfd 100644 --- a/Lib/octave/octave.swg +++ b/Lib/octave/octave.swg @@ -1,8 +1,19 @@ +// +// octave.swg - Octave configuration module +// + +// Include standard SWIG macros and fragments %include %include + +// Include Octave runtime code %include -%include + +// Include Octave typemaps %include + +// Include Octave overloaded operator support %include -%define %docstring %feature("docstring") %enddef +// Include Octave special user directives +%include diff --git a/Lib/octave/octcomplex.swg b/Lib/octave/octcomplex.swg index a3e9ebf77..320dba127 100644 --- a/Lib/octave/octcomplex.swg +++ b/Lib/octave/octcomplex.swg @@ -1,92 +1,83 @@ -/* - Defines the As/From conversors for double/float complex, you need to - provide complex Type, the Name you want to use in the conversors, - the complex Constructor method, and the Real and Imag complex - accesor methods. +// +// octcomplex.swg - Octave complex number support +// - See the std_complex.i and ccomplex.i for concrete examples. -*/ +// Defines the As/From conversors for double/float complex, you need to +// provide complex Type, the Name you want to use in the conversors, +// the complex Constructor method, and the Real and Imag complex accessor +// methods. See the std_complex.i and ccomplex.i for concrete examples. -/* the common from conversor */ +// Common 'from' conversor %define %swig_fromcplx_conv(Type, OctConstructor, Real, Imag) - %fragment(SWIG_From_frag(Type),"header") +%fragment(SWIG_From_frag(Type), "header") { - SWIGINTERNINLINE octave_value - SWIG_From(Type)(const Type& c) - { - return octave_value(OctConstructor(Real(c), Imag(c))); - } + SWIGINTERNINLINE octave_value SWIG_From(Type)(const Type & c) { + return octave_value(OctConstructor(Real(c), Imag(c))); + } } %enddef -// the double case +// Double-precision 'as' conversor %define %swig_cplxdbl_conv(Type, Constructor, Real, Imag) - %fragment(SWIG_AsVal_frag(Type),"header", - fragment=SWIG_AsVal_frag(double)) +%fragment(SWIG_AsVal_frag(Type), "header", fragment = SWIG_AsVal_frag(double)) { - SWIGINTERN int - SWIG_AsVal(Type) (const octave_value& ov, Type* val) - { - if (ov.is_complex_scalar()) { - if (val) { - Complex c(ov.complex_value()); - *val=Constructor(c.real(),c.imag()); - } - return SWIG_OK; - } else { - double d; - int res = SWIG_AddCast(SWIG_AsVal(double)(ov, &d)); - if (SWIG_IsOK(res)) { - if (val) - *val = Constructor(d, 0.0); - return res; - } + SWIGINTERN int SWIG_AsVal(Type)(const octave_value & ov, Type * val) { + if (ov.is_complex_scalar()) { + if (val) { + Complex c(ov.complex_value()); + *val = Constructor(c.real(), c.imag()); + } + return SWIG_OK; + } else { + double d; + int res = SWIG_AddCast(SWIG_AsVal(double)(ov, &d)); + if (SWIG_IsOK(res)) { + if (val) { + *val = Constructor(d, 0.0); + } + return res; } - return SWIG_TypeError; } + return SWIG_TypeError; + } } %swig_fromcplx_conv(Type, Complex, Real, Imag); %enddef -// the float case +// Single-precision 'as' conversor %define %swig_cplxflt_conv(Type, Constructor, Real, Imag) - %fragment(SWIG_AsVal_frag(Type),"header", - fragment=SWIG_AsVal_frag(float)) { - SWIGINTERN int - SWIG_AsVal(Type) (const octave_value& ov, Type* val) - { - if (ov.is_complex_scalar()) { - if (val) { - Complex c(ov.complex_value()); - double re = c.real(); - double im = c.imag(); - if ((-FLT_MAX <= re && re <= FLT_MAX) && (-FLT_MAX <= im && im <= FLT_MAX)) { - if (val) - *val = Constructor(%numeric_cast(re, float), - %numeric_cast(im, float)); - return SWIG_OK; - } else - return SWIG_OverflowError; - } - } else { - float d; - int res = SWIG_AddCast(SWIG_AsVal(float)(ov, &d)); - if (SWIG_IsOK(res)) { - if (val) - *val = Constructor(d, 0.0); - return res; - } +%fragment(SWIG_AsVal_frag(Type), "header", fragment = SWIG_AsVal_frag(float)) +{ + SWIGINTERN int SWIG_AsVal(Type)(const octave_value & ov, Type * val) { + if (ov.is_complex_scalar()) { + if (val) { + Complex c(ov.complex_value()); + double re = c.real(); + double im = c.imag(); + if ((-FLT_MAX <= re && re <= FLT_MAX) && (-FLT_MAX <= im && im <= FLT_MAX)) { + if (val) + *val = Constructor(%numeric_cast(re, float), %numeric_cast(im, float)); + return SWIG_OK; + } else { + return SWIG_OverflowError; + } + } + } else { + float d; + int res = SWIG_AddCast(SWIG_AsVal(float)(ov, &d)); + if (SWIG_IsOK(res)) { + if (val) { + *val = Constructor(d, 0.0); + } + return res; } - return SWIG_TypeError; } + return SWIG_TypeError; + } } %swig_fromcplx_conv(Type, FloatComplex, Real, Imag); %enddef -#define %swig_cplxflt_convn(Type, Constructor, Real, Imag) \ -%swig_cplxflt_conv(Type, Constructor, Real, Imag) - - -#define %swig_cplxdbl_convn(Type, Constructor, Real, Imag) \ -%swig_cplxdbl_conv(Type, Constructor, Real, Imag) +#define %swig_cplxflt_convn(Type, Constructor, Real, Imag) %swig_cplxflt_conv(Type, Constructor, Real, Imag) +#define %swig_cplxdbl_convn(Type, Constructor, Real, Imag) %swig_cplxdbl_conv(Type, Constructor, Real, Imag) diff --git a/Lib/octave/octcontainer.swg b/Lib/octave/octcontainer.swg index 723256ca0..c6e88f7c8 100644 --- a/Lib/octave/octcontainer.swg +++ b/Lib/octave/octcontainer.swg @@ -1,21 +1,20 @@ -/* ----------------------------------------------------------------------------- - * octcontainer.swg - * - * Octave cell <-> C++ container wrapper - * - * This wrapper, and its iterator, allows a general use (and reuse) of - * the mapping between C++ and Octave, thanks to the C++ templates. - * - * Of course, it needs the C++ compiler to support templates, but - * since we will use this wrapper with the STL containers, that should - * be the case. - * ----------------------------------------------------------------------------- */ - -%{ +// +// octcontainer.swg - Octave STL container support +// + +// Octave cell <-> C++ container wrapper +// +// This wrapper, and its iterator, allows a general use (and reuse) of +// the mapping between C++ and Octave, thanks to the C++ templates. +// +// Of course, it needs the C++ compiler to support templates, but +// since we will use this wrapper with the STL containers, that should +// be the case. + +%header %{ #include %} - #if !defined(SWIG_NO_EXPORT_ITERATOR_METHODS) # if !defined(SWIG_EXPORT_ITERATOR_METHODS) # define SWIG_EXPORT_ITERATOR_METHODS SWIG_EXPORT_ITERATOR_METHODS @@ -24,599 +23,585 @@ %include -// The Octave C++ Wrap - %fragment(""); %include -%fragment(SWIG_Traits_frag(octave_value),"header",fragment="StdTraits") { -namespace swig { - template <> struct traits { - typedef value_category category; - static const char* type_name() { return "octave_value"; } - }; - - template <> struct traits_from { - typedef octave_value value_type; - static octave_value from(const value_type& val) { - return val; - } - }; - - template <> - struct traits_check { - static bool check(const octave_value&) { - return true; - } - }; - - template <> struct traits_asval { - typedef octave_value value_type; - static int asval(const octave_value& obj, value_type *val) { - if (val) *val = obj; - return SWIG_OK; - } - }; -} -} - -%fragment("OctSequence_Base","header",fragment="") +%fragment(SWIG_Traits_frag(octave_value), "header", fragment = "StdTraits") { -%#include -namespace std { - template <> - struct less : public binary_function + namespace swig { - bool - operator()(const octave_value& v, const octave_value& w) const - { - octave_value res = do_binary_op(octave_value::op_le,v,w); - return res.is_true(); - } - }; -} -namespace swig { - inline size_t - check_index(ptrdiff_t i, size_t size, bool insert = false) { - if ( i < 0 ) { - if ((size_t) (-i) <= size) - return (size_t) (i + size); - } else if ( (size_t) i < size ) { - return (size_t) i; - } else if (insert && ((size_t) i == size)) { - return size; - } - - throw std::out_of_range("index out of range"); - } - - inline size_t - slice_index(ptrdiff_t i, size_t size) { - if ( i < 0 ) { - if ((size_t) (-i) <= size) { - return (size_t) (i + size); - } else { - throw std::out_of_range("index out of range"); + template <> + struct traits { + typedef value_category category; + static const char* type_name() { + return "octave_value"; } - } else { - return ( (size_t) i < size ) ? ((size_t) i) : size; - } - } + }; - template - inline typename Sequence::iterator - getpos(Sequence* self, Difference i) { - typename Sequence::iterator pos = self->begin(); - std::advance(pos, check_index(i,self->size())); - return pos; - } - - template - inline typename Sequence::const_iterator - cgetpos(const Sequence* self, Difference i) { - typename Sequence::const_iterator pos = self->begin(); - std::advance(pos, check_index(i,self->size())); - return pos; - } + template <> + struct traits_from { + typedef octave_value value_type; + static octave_value from(const value_type& val) { + return val; + } + }; - template - inline Sequence* - getslice(const Sequence* self, Difference i, Difference j) { - typename Sequence::size_type size = self->size(); - typename Sequence::size_type ii = swig::check_index(i, size); - typename Sequence::size_type jj = swig::slice_index(j, size); - - if (jj > ii) { - typename Sequence::const_iterator vb = self->begin(); - typename Sequence::const_iterator ve = self->begin(); - std::advance(vb,ii); - std::advance(ve,jj); - return new Sequence(vb, ve); - } else { - return new Sequence(); - } - } + template <> + struct traits_check { + static bool check(const octave_value&) { + return true; + } + }; + + template <> + struct traits_asval { + typedef octave_value value_type; + static int asval(const octave_value& obj, value_type* val) { + if (val) { + *val = obj; + } + return SWIG_OK; + } + }; - template - inline void - setslice(Sequence* self, Difference i, Difference j, const InputSeq& v) { - typename Sequence::size_type size = self->size(); - typename Sequence::size_type ii = swig::check_index(i, size, true); - typename Sequence::size_type jj = swig::slice_index(j, size); - if (jj < ii) jj = ii; - size_t ssize = jj - ii; - if (ssize <= v.size()) { - typename Sequence::iterator sb = self->begin(); - typename InputSeq::const_iterator vmid = v.begin(); - std::advance(sb,ii); - std::advance(vmid, jj - ii); - self->insert(std::copy(v.begin(), vmid, sb), vmid, v.end()); - } else { - typename Sequence::iterator sb = self->begin(); - typename Sequence::iterator se = self->begin(); - std::advance(sb,ii); - std::advance(se,jj); - self->erase(sb,se); - self->insert(sb, v.begin(), v.end()); - } } - template - inline void - delslice(Sequence* self, Difference i, Difference j) { - typename Sequence::size_type size = self->size(); - typename Sequence::size_type ii = swig::check_index(i, size, true); - typename Sequence::size_type jj = swig::slice_index(j, size); - if (jj > ii) { - typename Sequence::iterator sb = self->begin(); - typename Sequence::iterator se = self->begin(); - std::advance(sb,ii); - std::advance(se,jj); - self->erase(sb,se); - } - } -} } -%fragment("OctSequence_Cont","header", - fragment="StdTraits", - fragment="OctSequence_Base", - fragment="OctSwigIterator_T") -{ -namespace swig +%fragment("OctSequence_Base", "header", fragment = "") { - template - struct OctSequence_Ref // * octave can't support these, because of how assignment works +%#include + + namespace std { - OctSequence_Ref(const octave_value& seq, int index) - : _seq(seq), _index(index) - { - } - - operator T () const - { - // swig::SwigVar_PyObject item = OctSequence_GetItem(_seq, _index); - octave_value item; // * todo - try { - return swig::as(item, true); - } catch (std::exception& e) { - char msg[1024]; - sprintf(msg, "in sequence element %d ", _index); - if (!Octave_Error_Occurred()) { - %type_error(swig::type_name()); - } - SWIG_Octave_AddErrorMsg(msg); - SWIG_Octave_AddErrorMsg(e.what()); - throw; - } - } - OctSequence_Ref& operator=(const T& v) - { - // OctSequence_SetItem(_seq, _index, swig::from(v)); - // * todo - return *this; - } + template <> + struct less : public binary_function { + bool + operator()(const octave_value& v, const octave_value& w) const { + octave_value res = do_binary_op(octave_value::op_le, v, w); + return res.is_true(); + } + }; - private: - octave_value _seq; - int _index; - }; + } - template - struct OctSequence_ArrowProxy + namespace swig { - OctSequence_ArrowProxy(const T& x): m_value(x) {} - const T* operator->() const { return &m_value; } - operator const T*() const { return &m_value; } - T m_value; - }; - - template - struct OctSequence_InputIterator - { - typedef OctSequence_InputIterator self; - - typedef std::random_access_iterator_tag iterator_category; - typedef Reference reference; - typedef T value_type; - typedef T* pointer; - typedef int difference_type; - OctSequence_InputIterator() + inline size_t check_index(ptrdiff_t i, size_t size, bool insert = false) { - } + if (i < 0) { + if ((size_t)(-i) <= size) { + return (size_t)(i + size); + } + } else if ((size_t) i < size) { + return (size_t) i; + } else if (insert && ((size_t) i == size)) { + return size; + } - OctSequence_InputIterator(const octave_value& seq, int index) - : _seq(seq), _index(index) - { + throw std::out_of_range("index out of range"); } - reference operator*() const + inline size_t slice_index(ptrdiff_t i, size_t size) { - return reference(_seq, _index); - } - - OctSequence_ArrowProxy - operator->() const { - return OctSequence_ArrowProxy(operator*()); + if (i < 0) { + if ((size_t)(-i) <= size) { + return (size_t)(i + size); + } else { + throw std::out_of_range("index out of range"); + } + } else { + return ((size_t) i < size) ? ((size_t) i) : size; + } } - bool operator==(const self& ri) const + template + inline typename Sequence::iterator getpos(Sequence* self, Difference i) { - return (_index == ri._index); + typename Sequence::iterator pos = self->begin(); + std::advance(pos, check_index(i, self->size())); + return pos; } - bool operator!=(const self& ri) const + template + inline typename Sequence::const_iterator cgetpos(const Sequence* self, Difference i) { - return !(operator==(ri)); + typename Sequence::const_iterator pos = self->begin(); + std::advance(pos, check_index(i, self->size())); + return pos; } - self& operator ++ () + template + inline Sequence* getslice(const Sequence* self, Difference i, Difference j) { - ++_index; - return *this; + typename Sequence::size_type size = self->size(); + typename Sequence::size_type ii = swig::check_index(i, size); + typename Sequence::size_type jj = swig::slice_index(j, size); + if (jj > ii) { + typename Sequence::const_iterator vb = self->begin(); + typename Sequence::const_iterator ve = self->begin(); + std::advance(vb, ii); + std::advance(ve, jj); + return new Sequence(vb, ve); + } else { + return new Sequence(); + } } - self& operator -- () + template + inline void setslice(Sequence* self, Difference i, Difference j, const InputSeq& v) { - --_index; - return *this; + typename Sequence::size_type size = self->size(); + typename Sequence::size_type ii = swig::check_index(i, size, true); + typename Sequence::size_type jj = swig::slice_index(j, size); + if (jj < ii) { + jj = ii; + } + size_t ssize = jj - ii; + if (ssize <= v.size()) { + typename Sequence::iterator sb = self->begin(); + typename InputSeq::const_iterator vmid = v.begin(); + std::advance(sb, ii); + std::advance(vmid, jj - ii); + self->insert(std::copy(v.begin(), vmid, sb), vmid, v.end()); + } else { + typename Sequence::iterator sb = self->begin(); + typename Sequence::iterator se = self->begin(); + std::advance(sb, ii); + std::advance(se, jj); + self->erase(sb, se); + self->insert(sb, v.begin(), v.end()); + } } - self& operator += (difference_type n) + template + inline void delslice(Sequence* self, Difference i, Difference j) { - _index += n; - return *this; + typename Sequence::size_type size = self->size(); + typename Sequence::size_type ii = swig::check_index(i, size, true); + typename Sequence::size_type jj = swig::slice_index(j, size); + if (jj > ii) { + typename Sequence::iterator sb = self->begin(); + typename Sequence::iterator se = self->begin(); + std::advance(sb, ii); + std::advance(se, jj); + self->erase(sb, se); + } } - self operator +(difference_type n) const - { - return self(_seq, _index + n); - } + } - self& operator -= (difference_type n) - { - _index -= n; - return *this; - } +} - self operator -(difference_type n) const - { - return self(_seq, _index - n); - } +%fragment("OctSequence_Cont", "header", fragment = "StdTraits", fragment = "OctSequence_Base", fragment = "OctIterator_T") +{ - difference_type operator - (const self& ri) const - { - return _index - ri._index; - } + namespace swig + { - bool operator < (const self& ri) const - { - return _index < ri._index; - } + template + struct OctSequence_Ref { // * octave can't support these, because of how assignment works - reference - operator[](difference_type n) const - { - return reference(_seq, _index + n); - } + OctSequence_Ref(const octave_value& seq, int index) + : _seq(seq), _index(index) { + } - private: - octave_value _seq; - difference_type _index; - }; + operator T() const { + octave_value item; // * todo + try { + return swig::as (item, true); + } catch (std::exception& e) { + char msg[1024]; + sprintf(msg, "in sequence element %d ", _index); + if (!SWIG_Octave_ErrorOccurred()) { + %type_error(swig::type_name()); + } + SWIG_Octave_AddErrorMsg(msg); + SWIG_Octave_AddErrorMsg(e.what()); + throw; + } + } - template - struct OctSequence_Cont - { - typedef OctSequence_Ref reference; - typedef const OctSequence_Ref const_reference; - typedef T value_type; - typedef T* pointer; - typedef int difference_type; - typedef int size_type; - typedef const pointer const_pointer; - typedef OctSequence_InputIterator iterator; - typedef OctSequence_InputIterator const_iterator; - - OctSequence_Cont(const octave_value& seq) : _seq(seq) - { - // * assert that we have map type etc. - /* - if (!OctSequence_Check(seq)) { - throw std::invalid_argument("a sequence is expected"); - } - _seq = seq; - Py_INCREF(_seq); - */ - } + OctSequence_Ref& operator= (const T& v) { + // * todo + return *this; + } - ~OctSequence_Cont() - { - } + private: - size_type size() const - { - // return static_cast(OctSequence_Size(_seq)); - return 0; // * todo - } + octave_value _seq; + int _index; - bool empty() const - { - return size() == 0; - } + }; - iterator begin() - { - return iterator(_seq, 0); - } + template + struct OctSequence_ArrowProxy { + OctSequence_ArrowProxy(const T& x) : m_value(x) {} + const T* operator->() const { + return &m_value; + } + operator const T* () const { + return &m_value; + } + T m_value; + }; - const_iterator begin() const - { - return const_iterator(_seq, 0); - } + template + struct OctSequence_InputIterator { - iterator end() - { - return iterator(_seq, size()); - } + typedef OctSequence_InputIterator self; + typedef std::random_access_iterator_tag iterator_category; + typedef Reference reference; + typedef T value_type; + typedef T* pointer; + typedef int difference_type; - const_iterator end() const - { - return const_iterator(_seq, size()); - } + OctSequence_InputIterator() { + } - reference operator[](difference_type n) - { - return reference(_seq, n); - } + OctSequence_InputIterator(const octave_value& seq, int index) + : _seq(seq), _index(index) { + } - const_reference operator[](difference_type n) const - { - return const_reference(_seq, n); - } + reference operator*() const { + return reference(_seq, _index); + } - bool check(bool set_err = true) const - { - int s = size(); - for (int i = 0; i < s; ++i) { - // swig::SwigVar_PyObject item = OctSequence_GetItem(_seq, i); - octave_value item; // * todo - if (!swig::check(item)) { - if (set_err) { - char msg[1024]; - sprintf(msg, "in sequence element %d", i); - SWIG_Error(SWIG_RuntimeError, msg); - } - return false; - } - } - return true; - } + OctSequence_ArrowProxy + operator->() const { + return OctSequence_ArrowProxy (operator*()); + } - private: - octave_value _seq; - }; + bool operator== (const self& ri) const { + return (_index == ri._index); + } + + bool operator!= (const self& ri) const { + return !(operator== (ri)); + } + + self& operator ++ () { + ++_index; + return *this; + } + + self& operator -- () { + --_index; + return *this; + } + + self& operator += (difference_type n) { + _index += n; + return *this; + } + + self operator + (difference_type n) const { + return self(_seq, _index + n); + } + + self& operator -= (difference_type n) { + _index -= n; + return *this; + } + + self operator - (difference_type n) const { + return self(_seq, _index - n); + } + + difference_type operator - (const self& ri) const { + return _index - ri._index; + } + + bool operator < (const self& ri) const { + return _index < ri._index; + } + + reference + operator[](difference_type n) const { + return reference(_seq, _index + n); + } + + private: + octave_value _seq; + difference_type _index; + }; + + template + struct OctSequence_Cont { + typedef OctSequence_Ref reference; + typedef const OctSequence_Ref const_reference; + typedef T value_type; + typedef T* pointer; + typedef int difference_type; + typedef int size_type; + typedef const pointer const_pointer; + typedef OctSequence_InputIterator iterator; + typedef OctSequence_InputIterator const_iterator; + + OctSequence_Cont(const octave_value& seq) : _seq(seq) { + } + + ~OctSequence_Cont() { + } + + size_type size() const { + return 0; // * todo + } + + bool empty() const { + return size() == 0; + } + + iterator begin() { + return iterator(_seq, 0); + } + + const_iterator begin() const { + return const_iterator(_seq, 0); + } + + iterator end() { + return iterator(_seq, size()); + } + + const_iterator end() const { + return const_iterator(_seq, size()); + } + + reference operator[](difference_type n) { + return reference(_seq, n); + } + + const_reference operator[](difference_type n) const { + return const_reference(_seq, n); + } + + bool check(bool set_err = true) const { + int s = size(); + for (int i = 0; i < s; ++i) { + octave_value item; // * todo + if (!swig::check (item)) { + if (set_err) { + char msg[1024]; + sprintf(msg, "in sequence element %d", i); + SWIG_Error(SWIG_RuntimeError, msg); + } + return false; + } + } + return true; + } + + private: + octave_value _seq; + }; + + } -} } %define %swig_sequence_iterator(Sequence...) #if defined(SWIG_EXPORT_ITERATOR_METHODS) - class iterator; - class reverse_iterator; - class const_iterator; - class const_reverse_iterator; - - %typemap(out,noblock=1,fragment="OctSequence_Cont") - iterator, reverse_iterator, const_iterator, const_reverse_iterator { - $result = SWIG_NewPointerObj(swig::make_output_iterator(%static_cast($1,const $type &)), - swig::OctSwigIterator::descriptor(),SWIG_POINTER_OWN); - } - %typemap(out,fragment="OctSequence_Cont") - std::pair, std::pair { - octave_value_list tmpc; - tmpc.append(SWIG_NewPointerObj(swig::make_output_iterator(%static_cast($1,const $type &).first), - swig::OctSwigIterator::descriptor(),SWIG_POINTER_OWN)); - tmpc.append(SWIG_NewPointerObj(swig::make_output_iterator(%static_cast($1,const $type &).second), - swig::OctSwigIterator::descriptor(),SWIG_POINTER_OWN)); - $result = Cell(tmpc); - } - %fragment("SwigPyPairBoolOutputIterator","header",fragment=SWIG_From_frag(bool),fragment="OctSequence_Cont") {} +class iterator; +class reverse_iterator; +class const_iterator; +class const_reverse_iterator; - %typemap(out,fragment="OctPairBoolOutputIterator") - std::pair, std::pair { - octave_value_list tmpc; - tmpc.append(SWIG_NewPointerObj(swig::make_output_iterator(%static_cast($1,const $type &).first), - swig::OctSwigIterator::descriptor(),SWIG_POINTER_OWN)); - tmpc.append(SWIG_From(bool)(%static_cast($1,const $type &).second)); - $result = Cell(tmpc); - } +%typemap(out, noblock = 1, fragment = "OctSequence_Cont") iterator, reverse_iterator, const_iterator, const_reverse_iterator { + $result = SWIG_NewPointerObj(swig::make_output_iterator(%static_cast($1, const $type&)), + swig::OctIterator::descriptor(), SWIG_POINTER_OWN); +} +%typemap(out, fragment = "OctSequence_Cont") std::pair, std::pair { + octave_value_list tmpc; + tmpc.append(SWIG_NewPointerObj(swig::make_output_iterator(%static_cast($1, const $type&).first), swig::OctIterator::descriptor(), SWIG_POINTER_OWN)); + tmpc.append(SWIG_NewPointerObj(swig::make_output_iterator(%static_cast($1, const $type&).second), swig::OctIterator::descriptor(), SWIG_POINTER_OWN)); + $result = Cell(tmpc); +} - %typemap(in,noblock=1,fragment="OctSequence_Cont") - iterator(swig::OctSwigIterator *iter = 0, int res), - reverse_iterator(swig::OctSwigIterator *iter = 0, int res), - const_iterator(swig::OctSwigIterator *iter = 0, int res), - const_reverse_iterator(swig::OctSwigIterator *iter = 0, int res) { - res = SWIG_ConvertPtr($input, %as_voidptrptr(&iter), swig::OctSwigIterator::descriptor(), 0); - if (!SWIG_IsOK(res) || !iter) { - %argument_fail(SWIG_TypeError, "$type", $symname, $argnum); +%fragment("OctPairBoolOutputIterator", "header", fragment = SWIG_From_frag(bool), fragment = "OctSequence_Cont") {} + +%typemap(out, fragment = "OctPairBoolOutputIterator") std::pair, std::pair { + octave_value_list tmpc; + tmpc.append(SWIG_NewPointerObj(swig::make_output_iterator(%static_cast($1, const $type&).first), + swig::OctIterator::descriptor(), SWIG_POINTER_OWN)); + tmpc.append(SWIG_From(bool)(%static_cast($1, const $type&).second)); + $result = Cell(tmpc); +} + +%typemap(in, noblock = 1, fragment = "OctSequence_Cont") + iterator(swig::OctIterator* iter = 0, int res), + reverse_iterator(swig::OctIterator* iter = 0, int res), + const_iterator(swig::OctIterator* iter = 0, int res), + const_reverse_iterator(swig::OctIterator* iter = 0, int res) +{ + res = SWIG_ConvertPtr($input, %as_voidptrptr(&iter), swig::OctIterator::descriptor(), 0); + if (!SWIG_IsOK(res) || !iter) { + %argument_fail(SWIG_TypeError, "$type", $symname, $argnum); + } else { + swig::OctIterator_T < $type > *iter_t = dynamic_cast < swig::OctIterator_T < $type > * >(iter); + if (iter_t) { + $1 = iter_t->get_current(); } else { - swig::OctSwigIterator_T<$type > *iter_t = dynamic_cast *>(iter); - if (iter_t) { - $1 = iter_t->get_current(); - } else { - %argument_fail(SWIG_TypeError, "$type", $symname, $argnum); - } + %argument_fail(SWIG_TypeError, "$type", $symname, $argnum); } } +} - %typecheck(%checkcode(ITERATOR),noblock=1,fragment="OctSequence_Cont") - iterator, reverse_iterator, const_iterator, const_reverse_iterator { - swig::OctSwigIterator *iter = 0; - int res = SWIG_ConvertPtr($input, %as_voidptrptr(&iter), swig::OctSwigIterator::descriptor(), 0); - $1 = (SWIG_IsOK(res) && iter && (dynamic_cast *>(iter) != 0)); - } +%typecheck(%checkcode(ITERATOR), noblock = 1, fragment = "OctSequence_Cont") iterator, reverse_iterator, const_iterator, const_reverse_iterator { + swig::OctIterator* iter = 0; + int res = SWIG_ConvertPtr($input, %as_voidptrptr(&iter), swig::OctIterator::descriptor(), 0); + $1 = (SWIG_IsOK(res) && iter && (dynamic_cast < swig::OctIterator_T < $type > * >(iter) != 0)); +} + +%fragment("OctSequence_Cont"); - %fragment("OctSequence_Cont"); #endif //SWIG_EXPORT_ITERATOR_METHODS %enddef -// The octave container methods +// Octave container methods %define %swig_container_methods(Container...) %enddef %define %swig_sequence_methods_common(Sequence...) - %swig_sequence_iterator(%arg(Sequence)) - %swig_container_methods(%arg(Sequence)) - - %fragment("OctSequence_Base"); - - %extend { - value_type pop() throw (std::out_of_range) { - if (self->size() == 0) - throw std::out_of_range("pop from empty container"); - Sequence::value_type x = self->back(); - self->pop_back(); - return x; - } +%swig_sequence_iterator(%arg(Sequence)) +%swig_container_methods(%arg(Sequence)) - value_type __paren__(difference_type i) throw (std::out_of_range) { - return *(swig::cgetpos(self, i)); - } +%fragment("OctSequence_Base"); - void __paren_asgn__(difference_type i, value_type x) throw (std::out_of_range) { - *(swig::getpos(self,i)) = x; - } +%extend { - void append(value_type x) { - self->push_back(x); + value_type pop() throw(std::out_of_range) { + if (self->size() == 0) { + throw std::out_of_range("pop from empty container"); } + Sequence::value_type x = self->back(); + self->pop_back(); + return x; + } + + value_type __paren__(difference_type i) throw(std::out_of_range) { + return * (swig::cgetpos(self, i)); + } + + void __paren_asgn__(difference_type i, value_type x) throw(std::out_of_range) { + * (swig::getpos(self, i)) = x; + } + + void append(value_type x) { + self->push_back(x); } +} %enddef %define %swig_sequence_methods(Sequence...) - %swig_sequence_methods_common(%arg(Sequence)) +%swig_sequence_methods_common(%arg(Sequence)) %enddef %define %swig_sequence_methods_val(Sequence...) - %swig_sequence_methods_common(%arg(Sequence)) +%swig_sequence_methods_common(%arg(Sequence)) %enddef -// // Common fragments -// -%fragment("StdSequenceTraits","header", - fragment="StdTraits", - fragment="OctSequence_Cont") +%fragment("StdSequenceTraits", "header", fragment = "StdTraits", fragment = "OctSequence_Cont") { -namespace swig { - template - inline void - assign(const OctSeq& octseq, Seq* seq) { + + namespace swig + { + + template + inline void + assign(const OctSeq& octseq, Seq* seq) + { %#ifdef SWIG_STD_NOASSIGN_STL - typedef typename OctSeq::value_type value_type; - typename OctSeq::const_iterator it = octseq.begin(); - for (;it != octseq.end(); ++it) { - seq->insert(seq->end(),(value_type)(*it)); - } + typedef typename OctSeq::value_type value_type; + typename OctSeq::const_iterator it = octseq.begin(); + for (; it != octseq.end(); ++it) { + seq->insert(seq->end(), (value_type)(*it)); + } %#else - seq->assign(octseq.begin(), octseq.end()); + seq->assign(octseq.begin(), octseq.end()); %#endif - } - - template - struct traits_asptr_stdseq { - typedef Seq sequence; - typedef T value_type; - - static int asptr(const octave_value& obj, sequence **seq) { - if (!obj.is_defined() || Swig::swig_value_deref(obj)) { - sequence *p; - if (SWIG_ConvertPtr(obj,(void**)&p, - swig::type_info(),0) == SWIG_OK) { - if (seq) *seq = p; - return SWIG_OLDOBJ; - } - } else if (obj.is_cell()) { - try { - OctSequence_Cont octseq(obj); - if (seq) { - sequence *pseq = new sequence(); - assign(octseq, pseq); - *seq = pseq; - return SWIG_NEWOBJ; - } else { - return octseq.check() ? SWIG_OK : SWIG_ERROR; - } - } catch (std::exception& e) { - if (seq&&!error_state) - error("swig type error: %s",e.what()); - return SWIG_ERROR; - } - } - return SWIG_ERROR; } - }; - template - struct traits_from_stdseq { - typedef Seq sequence; - typedef T value_type; - typedef typename Seq::size_type size_type; - typedef typename sequence::const_iterator const_iterator; + template + struct traits_asptr_stdseq { + + typedef Seq sequence; + typedef T value_type; + + static int asptr(const octave_value& obj, sequence** seq) { + if (!obj.is_defined() || SWIG_Octave_ValueDeref(obj)) { + sequence* p; + if (SWIG_ConvertPtr(obj, (void**) &p, swig::type_info(), 0) == SWIG_OK) { + if (seq) { + *seq = p; + } + return SWIG_OLDOBJ; + } + } else if (obj.is_cell()) { + try { + OctSequence_Cont octseq(obj); + if (seq) { + sequence* pseq = new sequence(); + assign(octseq, pseq); + *seq = pseq; + return SWIG_NEWOBJ; + } else { + return octseq.check() ? SWIG_OK : SWIG_ERROR; + } + } catch (std::exception& e) { + if (seq && !error_state) { + error("swig type error: %s", e.what()); + } + return SWIG_ERROR; + } + } + return SWIG_ERROR; + } + }; + + template + struct traits_from_stdseq { + + typedef Seq sequence; + typedef T value_type; + typedef typename Seq::size_type size_type; + typedef typename sequence::const_iterator const_iterator; - static octave_value from(const sequence& seq) { + static octave_value from(const sequence& seq) { #ifdef SWIG_OCTAVE_EXTRA_NATIVE_CONTAINERS - swig_type_info *desc = swig::type_info(); - if (desc && desc->clientdata) { - return SWIG_NewPointerObj(new sequence(seq), desc, SWIG_POINTER_OWN); - } + swig_type_info* desc = swig::type_info(); + if (desc && desc->clientdata) { + return SWIG_NewPointerObj(new sequence(seq), desc, SWIG_POINTER_OWN); + } #endif - size_type size = seq.size(); - if (size <= (size_type)INT_MAX) { - Cell c(size,1); - int i = 0; - for (const_iterator it = seq.begin(); - it != seq.end(); ++it, ++i) { - c(i) = swig::from(*it); - } - return c; - } else { - error("swig overflow error: sequence size not valid in octave"); - return octave_value(); + size_type size = seq.size(); + if (size <= (size_type) INT_MAX) { + Cell c(size, 1); + int i = 0; + for (const_iterator it = seq.begin(); + it != seq.end(); ++it, ++i) { + c(i) = swig::from (*it); + } + return c; + } else { + error("swig overflow error: sequence size not valid in octave"); + return octave_value(); + } + return octave_value(); } - return octave_value(); - } - }; -} -} + }; + + } + +} diff --git a/Lib/octave/octfragments.swg b/Lib/octave/octfragments.swg index 8b1378917..2c81e546c 100644 --- a/Lib/octave/octfragments.swg +++ b/Lib/octave/octfragments.swg @@ -1 +1,20 @@ +// +// octfragments.swg - Octave user fragments +// +// Create a file with this name, 'octfragments.swg', in your working +// directory and add all the %fragments you want to take precedence +// over the default ones defined by SWIG. +// +// For example, if you add: +// +// %fragment(SWIG_AsVal_frag(int),"header") { +// SWIGINTERNINLINE int SWIG_AsVal(int)(octave_value& obj, int *val) { +// ; +// } +// } +// +// this will replace the code used to retrieve an integer value for all +// the typemaps that need it, including: +// +// int, std::vector, std::list >, etc. diff --git a/Lib/octave/octiterators.swg b/Lib/octave/octiterators.swg index 79a20f833..e4b7f4488 100644 --- a/Lib/octave/octiterators.swg +++ b/Lib/octave/octiterators.swg @@ -1,357 +1,345 @@ -/* ----------------------------------------------------------------------------- - * octiterators.swg - * - * Users can derive form the OctSwigIterator to implemet their - * own iterators. As an example (real one since we use it for STL/STD - * containers), the template OctSwigIterator_T does the - * implementation for generic C++ iterators. - * ----------------------------------------------------------------------------- */ +// +// octiterators.swg - Octave STL iterator support +// + +// Users can derive form the OctIterator to implement their +// own iterators. As an example (real one since we use it for STL/STD +// containers), the template OctIterator_T does the +// implementation for generic C++ iterators. %include -%fragment("OctSwigIterator","header",fragment="") { -namespace swig { - struct stop_iteration { - }; +%fragment("OctIterator", "header", fragment = "") +{ - struct OctSwigIterator { - private: - octave_value _seq; + namespace swig + { - protected: - OctSwigIterator(octave_value seq) : _seq(seq) - { - } - - public: - virtual ~OctSwigIterator() {} + struct OctStopIteration { + }; - virtual octave_value value() const = 0; + struct OctIterator { - virtual OctSwigIterator *incr(size_t n = 1) = 0; + private: - virtual OctSwigIterator *decr(size_t n = 1) - { - throw stop_iteration(); - } + octave_value _seq; - virtual ptrdiff_t distance(const OctSwigIterator &x) const - { - throw std::invalid_argument("operation not supported"); - } + protected: - virtual bool equal (const OctSwigIterator &x) const - { - throw std::invalid_argument("operation not supported"); - } - - virtual OctSwigIterator *copy() const = 0; + OctIterator(octave_value seq) : _seq(seq) { + } - octave_value next() - { - octave_value obj = value(); - incr(); - return obj; - } + public: - octave_value previous() - { - decr(); - return value(); - } + virtual ~OctIterator() {} - OctSwigIterator *advance(ptrdiff_t n) - { - return (n > 0) ? incr(n) : decr(-n); - } - - bool operator == (const OctSwigIterator& x) const - { - return equal(x); - } - - bool operator != (const OctSwigIterator& x) const - { - return ! operator==(x); - } + virtual octave_value value() const = 0; - OctSwigIterator* operator ++ () { - incr(); - return this; - } + virtual OctIterator* incr(size_t n = 1) = 0; - OctSwigIterator* operator -- () { - decr(); - return this; - } - - OctSwigIterator* operator + (ptrdiff_t n) const - { - return copy()->advance(n); - } + virtual OctIterator* decr(size_t n = 1) { + throw OctStopIteration(); + } + + virtual ptrdiff_t distance(const OctIterator& x) const { + throw std::invalid_argument("operation not supported"); + } + + virtual bool equal(const OctIterator& x) const { + throw std::invalid_argument("operation not supported"); + } + + virtual OctIterator* copy() const = 0; + + octave_value next() { + octave_value obj = value(); + incr(); + return obj; + } + + octave_value previous() { + decr(); + return value(); + } + + OctIterator* advance(ptrdiff_t n) { + return (n > 0) ? incr(n) : decr(-n); + } + + bool operator== (const OctIterator& x) const { + return equal(x); + } + + bool operator!= (const OctIterator& x) const { + return ! operator== (x); + } + + OctIterator* operator++ () { + incr(); + return this; + } + + OctIterator* operator-- () { + decr(); + return this; + } + + OctIterator* operator+ (ptrdiff_t n) const { + return copy()->advance(n); + } + + OctIterator* operator- (ptrdiff_t n) const { + return copy()->advance(-n); + } + + ptrdiff_t operator- (const OctIterator& x) const { + return x.distance(*this); + } + + static swig_type_info* descriptor() { + static int init = 0; + static swig_type_info* desc = 0; + if (!init) { + desc = SWIG_TypeQuery("swig::OctIterator *"); + init = 1; + } + return desc; + } + + }; + + } - OctSwigIterator* operator - (ptrdiff_t n) const - { - return copy()->advance(-n); - } - - ptrdiff_t operator - (const OctSwigIterator& x) const - { - return x.distance(*this); - } - - static swig_type_info* descriptor() { - static int init = 0; - static swig_type_info* desc = 0; - if (!init) { - desc = SWIG_TypeQuery("swig::OctSwigIterator *"); - init = 1; - } - return desc; - } - }; -} } -%fragment("OctSwigIterator_T","header",fragment="",fragment="OctSwigIterator",fragment="StdTraits",fragment="StdIteratorTraits") { -namespace swig { - template - class OctSwigIterator_T : public OctSwigIterator +%fragment("OctIterator_T", "header", fragment = "", fragment = "OctIterator", fragment = "StdTraits", fragment = "StdIteratorTraits") +{ + + namespace swig { - public: - typedef OutIterator out_iterator; - typedef typename std::iterator_traits::value_type value_type; - typedef OctSwigIterator_T self_type; - OctSwigIterator_T(out_iterator curr, octave_value seq) - : OctSwigIterator(seq), current(curr) + template + class OctIterator_T : public OctIterator { - } - const out_iterator& get_current() const - { - return current; - } + public: - - bool equal (const OctSwigIterator &iter) const - { - const self_type *iters = dynamic_cast(&iter); - if (iters) { - return (current == iters->get_current()); - } else { - throw std::invalid_argument("bad iterator type"); + typedef OutIterator out_iterator; + typedef typename std::iterator_traits::value_type value_type; + typedef OctIterator_T self_type; + + OctIterator_T(out_iterator curr, octave_value seq) + : OctIterator(seq), current(curr) { } - } - - ptrdiff_t distance(const OctSwigIterator &iter) const - { - const self_type *iters = dynamic_cast(&iter); - if (iters) { - return std::distance(current, iters->get_current()); - } else { - throw std::invalid_argument("bad iterator type"); + + const out_iterator& get_current() const { + return current; } - } - - protected: - out_iterator current; - }; - - template - struct from_oper - { - typedef const ValueType& argument_type; - typedef octave_value result_type; - result_type operator()(argument_type v) const - { - return swig::from(v); - } - }; - template::value_type, - typename FromOper = from_oper > - class OctSwigIteratorOpen_T : public OctSwigIterator_T - { - public: - FromOper from; - typedef OutIterator out_iterator; - typedef ValueType value_type; - typedef OctSwigIterator_T base; - typedef OctSwigIteratorOpen_T self_type; - - OctSwigIteratorOpen_T(out_iterator curr, octave_value seq) - : OctSwigIterator_T(curr, seq) - { - } - - octave_value value() const { - return from(static_cast(*(base::current))); - } - - OctSwigIterator *copy() const - { - return new self_type(*this); - } + bool equal(const OctIterator& iter) const { + const self_type* iters = dynamic_cast(&iter); + if (iters) { + return (current == iters->get_current()); + } else { + throw std::invalid_argument("bad iterator type"); + } + } - OctSwigIterator *incr(size_t n = 1) - { - while (n--) { - ++base::current; + ptrdiff_t distance(const OctIterator& iter) const { + const self_type* iters = dynamic_cast(&iter); + if (iters) { + return std::distance(current, iters->get_current()); + } else { + throw std::invalid_argument("bad iterator type"); + } } - return this; - } - OctSwigIterator *decr(size_t n = 1) - { - while (n--) { - --base::current; + protected: + + out_iterator current; + + }; + + template + struct OctFromOper { + typedef const ValueType& argument_type; + typedef octave_value result_type; + result_type operator()(argument_type v) const { + return swig::from(v); } - return this; - } - }; + }; - template::value_type, - typename FromOper = from_oper > - class OctSwigIteratorClosed_T : public OctSwigIterator_T - { - public: - FromOper from; - typedef OutIterator out_iterator; - typedef ValueType value_type; - typedef OctSwigIterator_T base; - typedef OctSwigIteratorClosed_T self_type; - - OctSwigIteratorClosed_T(out_iterator curr, out_iterator first, out_iterator last, octave_value seq) - : OctSwigIterator_T(curr, seq), begin(first), end(last) + template < typename OutIterator, typename ValueType = typename std::iterator_traits::value_type, typename FromOper = OctFromOper > + class OctIteratorOpen_T : public OctIterator_T { - } - - octave_value value() const { - if (base::current == end) { - throw stop_iteration(); - } else { - return from(static_cast(*(base::current))); + + public: + + FromOper from; + typedef OutIterator out_iterator; + typedef ValueType value_type; + typedef OctIterator_T base; + typedef OctIteratorOpen_T self_type; + + OctIteratorOpen_T(out_iterator curr, octave_value seq) + : OctIterator_T (curr, seq) { } - } - - OctSwigIterator *copy() const - { - return new self_type(*this); - } - OctSwigIterator *incr(size_t n = 1) - { - while (n--) { - if (base::current == end) { - throw stop_iteration(); - } else { - ++base::current; - } + octave_value value() const { + return from(static_cast(* (base::current))); } - return this; - } - OctSwigIterator *decr(size_t n = 1) + OctIterator* copy() const { + return new self_type(*this); + } + + OctIterator* incr(size_t n = 1) { + while (n--) { + ++base::current; + } + return this; + } + + OctIterator* decr(size_t n = 1) { + while (n--) { + --base::current; + } + return this; + } + + }; + + template < typename OutIterator, typename ValueType = typename std::iterator_traits::value_type, typename FromOper = OctFromOper > + class OctIteratorClosed_T : public OctIterator_T { - while (n--) { - if (base::current == begin) { - throw stop_iteration(); - } else { - --base::current; - } + + public: + + FromOper from; + typedef OutIterator out_iterator; + typedef ValueType value_type; + typedef OctIterator_T base; + typedef OctIteratorClosed_T self_type; + + OctIteratorClosed_T(out_iterator curr, out_iterator first, out_iterator last, octave_value seq) + : OctIterator_T (curr, seq), begin(first), end(last) { } - return this; + + octave_value value() const { + if (base::current == end) { + throw OctStopIteration(); + } else { + return from(static_cast(* (base::current))); + } + } + + OctIterator* copy() const { + return new self_type(*this); + } + + OctIterator* incr(size_t n = 1) { + while (n--) { + if (base::current == end) { + throw OctStopIteration(); + } else { + ++base::current; + } + } + return this; + } + + OctIterator* decr(size_t n = 1) { + while (n--) { + if (base::current == begin) { + throw OctStopIteration(); + } else { + --base::current; + } + } + return this; + } + + private: + + out_iterator begin; + out_iterator end; + + }; + + template + inline OctIterator* make_output_iterator(const OutIter& current, const OutIter& begin, const OutIter& end, octave_value seq = octave_value()) + { + return new OctIteratorClosed_T (current, begin, end, seq); } - private: - out_iterator begin; - out_iterator end; - }; + template + inline OctIterator* make_output_iterator(const OutIter& current, octave_value seq = octave_value()) + { + return new OctIteratorOpen_T (current, seq); + } - template - inline OctSwigIterator* - make_output_iterator(const OutIter& current, const OutIter& begin,const OutIter& end, octave_value seq = octave_value()) - { - return new OctSwigIteratorClosed_T(current, begin, end, seq); } - template - inline OctSwigIterator* - make_output_iterator(const OutIter& current, octave_value seq = octave_value()) - { - return new OctSwigIteratorOpen_T(current, seq); - } -} } +%fragment("OctIterator"); -%fragment("OctSwigIterator"); -namespace swig +namespace swig { -// Throw a StopIteration exception - %ignore stop_iteration; - struct stop_iteration {}; - - %typemap(throws) stop_iteration { - error("stop_iteration exception"); + + // Throw a StopIteration exception + %ignore OctStopIteration; + struct OctStopIteration {}; + %typemap(throws) OctStopIteration { + error("OctStopIteration exception"); SWIG_fail; } -// Mark methods that return new objects - %newobject OctSwigIterator::copy; - %newobject OctSwigIterator::operator + (ptrdiff_t n) const; - %newobject OctSwigIterator::operator - (ptrdiff_t n) const; - - %nodirector OctSwigIterator; - - %catches(swig::stop_iteration) OctSwigIterator::value() const; - %catches(swig::stop_iteration) OctSwigIterator::incr(size_t n = 1); - %catches(swig::stop_iteration) OctSwigIterator::decr(size_t n = 1); - %catches(std::invalid_argument) OctSwigIterator::distance(const OctSwigIterator &x) const; - %catches(std::invalid_argument) OctSwigIterator::equal (const OctSwigIterator &x) const; - %catches(swig::stop_iteration) OctSwigIterator::next(); - %catches(swig::stop_iteration) OctSwigIterator::previous(); - %catches(swig::stop_iteration) OctSwigIterator::advance(ptrdiff_t n); - %catches(swig::stop_iteration) OctSwigIterator::operator += (ptrdiff_t n); - %catches(swig::stop_iteration) OctSwigIterator::operator -= (ptrdiff_t n); - %catches(swig::stop_iteration) OctSwigIterator::operator + (ptrdiff_t n) const; - %catches(swig::stop_iteration) OctSwigIterator::operator - (ptrdiff_t n) const; - + // Mark methods that return new objects + %newobject OctIterator::copy; + %newobject OctIterator::operator+ (ptrdiff_t n) const; + %newobject OctIterator::operator- (ptrdiff_t n) const; + + %catches(swig::OctStopIteration) OctIterator::value() const; + %catches(swig::OctStopIteration) OctIterator::incr(size_t n = 1); + %catches(swig::OctStopIteration) OctIterator::decr(size_t n = 1); + %catches(std::invalid_argument) OctIterator::distance(const OctIterator& x) const; + %catches(std::invalid_argument) OctIterator::equal(const OctIterator& x) const; + %catches(swig::OctStopIteration) OctIterator::next(); + %catches(swig::OctStopIteration) OctIterator::previous(); + %catches(swig::OctStopIteration) OctIterator::advance(ptrdiff_t n); + %catches(swig::OctStopIteration) OctIterator::operator+= (ptrdiff_t n); + %catches(swig::OctStopIteration) OctIterator::operator-= (ptrdiff_t n); + %catches(swig::OctStopIteration) OctIterator::operator+ (ptrdiff_t n) const; + %catches(swig::OctStopIteration) OctIterator::operator- (ptrdiff_t n) const; + + %nodirector OctIterator; + struct OctIterator { - struct OctSwigIterator - { protected: - OctSwigIterator(octave_value seq); + + OctIterator(octave_value seq); public: - virtual ~OctSwigIterator(); + virtual ~OctIterator(); virtual octave_value value() const = 0; - - virtual OctSwigIterator *incr(size_t n = 1) = 0; - - virtual OctSwigIterator *decr(size_t n = 1); - - virtual ptrdiff_t distance(const OctSwigIterator &x) const; - - virtual bool equal (const OctSwigIterator &x) const; - - virtual OctSwigIterator *copy() const = 0; - + virtual OctIterator* incr(size_t n = 1) = 0; + virtual OctIterator* decr(size_t n = 1); + virtual ptrdiff_t distance(const OctIterator& x) const; + virtual bool equal(const OctIterator& x) const; + virtual OctIterator* copy() const = 0; octave_value next(); octave_value previous(); - OctSwigIterator *advance(ptrdiff_t n); - - bool operator == (const OctSwigIterator& x) const; - bool operator != (const OctSwigIterator& x) const; - OctSwigIterator* operator ++ (); - OctSwigIterator* operator -- (); - OctSwigIterator* operator + (ptrdiff_t n) const; - OctSwigIterator* operator - (ptrdiff_t n) const; - ptrdiff_t operator - (const OctSwigIterator& x) const; + OctIterator* advance(ptrdiff_t n); + bool operator== (const OctIterator& x) const; + bool operator!= (const OctIterator& x) const; + OctIterator* operator++ (); + OctIterator* operator-- (); + OctIterator* operator+ (ptrdiff_t n) const; + OctIterator* operator- (ptrdiff_t n) const; + ptrdiff_t operator- (const OctIterator& x) const; + }; -} +} diff --git a/Lib/octave/octopers.swg b/Lib/octave/octopers.swg index c38e64d8c..86e7df88a 100644 --- a/Lib/octave/octopers.swg +++ b/Lib/octave/octopers.swg @@ -1,17 +1,17 @@ -/* ------------------------------------------------------------ - * Overloaded operator support - * ------------------------------------------------------------ */ +// +// octopers.swg - Octave overloaded operator support +// #ifdef __cplusplus -// operators supported in Octave, and the methods they are routed to - +// Operators supported in Octave, and the methods they are routed to: +// // __brace__ a{args} // __brace_asgn__ a{args} = rhs // __paren__ a(args) // __paren_asgn__ a(args) = rhs // __str__ generates string rep - +// // __not__ !a // __uplus__ +a // __uminus__ -a @@ -40,8 +40,7 @@ // __el_and__ a & b // __el_or__ a | b -// operators supported in C++, and the methods that route to them - +// Operators supported in C++, and the methods that route to them: %rename(__add__) *::operator+; %rename(__add__) *::operator+(); %rename(__add__) *::operator+() const; @@ -85,4 +84,4 @@ %ignoreoperator(EQ) operator=; %ignoreoperator(ARROWSTAR) operator->*; -#endif /* __cplusplus */ +#endif // __cplusplus diff --git a/Lib/octave/octprimtypes.swg b/Lib/octave/octprimtypes.swg index 6f43f21b0..7105bda48 100644 --- a/Lib/octave/octprimtypes.swg +++ b/Lib/octave/octprimtypes.swg @@ -1,232 +1,259 @@ -/* ------------------------------------------------------------ - * Primitive Types - * ------------------------------------------------------------ */ - +// +// octprimtypes.swg - Octave primitive types +// // boolean -%fragment(SWIG_From_frag(bool),"header") { -SWIGINTERNINLINE octave_value - SWIG_From_dec(bool)(bool value) +%fragment(SWIG_From_frag(bool), "header") { - return octave_value(value); -} + SWIGINTERNINLINE octave_value + SWIG_From_dec(bool)(bool value) { + return octave_value(value); + } } -%fragment(SWIG_AsVal_frag(bool),"header", - fragment=SWIG_AsVal_frag(long)) { -SWIGINTERN int -SWIG_AsVal_dec(bool)(const octave_value& ov, bool *val) +%fragment(SWIG_AsVal_frag(bool), "header", + fragment = SWIG_AsVal_frag(long)) { - if (!ov.is_bool_type()) - return SWIG_ERROR; - if (val) - *val = ov.bool_value(); - return SWIG_OK; -} + SWIGINTERN int + SWIG_AsVal_dec(bool)(const octave_value & ov, bool * val) { + if (!ov.is_bool_type()) { + return SWIG_ERROR; + } + if (val) { + *val = ov.bool_value(); + } + return SWIG_OK; + } } // long -%fragment(SWIG_From_frag(long),"header") { - SWIGINTERNINLINE octave_value SWIG_From_dec(long) (long value) - { - return octave_value(value); - } +%fragment(SWIG_From_frag(long), "header") +{ + SWIGINTERNINLINE octave_value SWIG_From_dec(long)(long value) { + return octave_value(value); + } } -%fragment(SWIG_AsVal_frag(long),"header") { - SWIGINTERN int SWIG_AsVal_dec(long)(const octave_value& ov, long* val) - { - if (!ov.is_scalar_type()) - return SWIG_TypeError; - if (ov.is_complex_scalar()) - return SWIG_TypeError; - if (ov.is_double_type()||ov.is_single_type()) { - double v=ov.double_value(); - if (v!=floor(v)) - return SWIG_TypeError; +%fragment(SWIG_AsVal_frag(long), "header") +{ + SWIGINTERN int SWIG_AsVal_dec(long)(const octave_value & ov, long * val) { + if (!ov.is_scalar_type()) { + return SWIG_TypeError; + } + if (ov.is_complex_scalar()) { + return SWIG_TypeError; + } + if (ov.is_double_type() || ov.is_single_type()) { + double v = ov.double_value(); + if (v != floor(v)) { + return SWIG_TypeError; } - if (val) - *val = ov.long_value(); - return SWIG_OK; } + if (val) { + *val = ov.long_value(); + } + return SWIG_OK; + } } // unsigned long -%fragment(SWIG_From_frag(unsigned long),"header") { - SWIGINTERNINLINE octave_value SWIG_From_dec(unsigned long) (unsigned long value) - { - return octave_value(value); - } +%fragment(SWIG_From_frag(unsigned long), "header") +{ + SWIGINTERNINLINE octave_value SWIG_From_dec(unsigned long)(unsigned long value) { + return octave_value(value); + } } -%fragment(SWIG_AsVal_frag(unsigned long),"header") { - SWIGINTERN int SWIG_AsVal_dec(unsigned long)(const octave_value& ov, unsigned long* val) - { - if (!ov.is_scalar_type()) - return SWIG_TypeError; - if (ov.is_complex_scalar()) - return SWIG_TypeError; - if (ov.is_double_type()||ov.is_single_type()) { - double v=ov.double_value(); - if (v<0) - return SWIG_OverflowError; - if (v!=floor(v)) - return SWIG_TypeError; +%fragment(SWIG_AsVal_frag(unsigned long), "header") +{ + SWIGINTERN int SWIG_AsVal_dec(unsigned long)(const octave_value & ov, unsigned long * val) { + if (!ov.is_scalar_type()) { + return SWIG_TypeError; + } + if (ov.is_complex_scalar()) { + return SWIG_TypeError; + } + if (ov.is_double_type() || ov.is_single_type()) { + double v = ov.double_value(); + if (v < 0) { + return SWIG_OverflowError; } - if (ov.is_int8_type()||ov.is_int16_type()|| - ov.is_int32_type()) { - long v=ov.long_value(); - if (v<0) - return SWIG_OverflowError; + if (v != floor(v)) { + return SWIG_TypeError; } - if (ov.is_int64_type()) { - long long v=ov.int64_scalar_value().value(); - if (v<0) - return SWIG_OverflowError; + } + if (ov.is_int8_type() || ov.is_int16_type() || ov.is_int32_type()) { + long v = ov.long_value(); + if (v < 0) { + return SWIG_OverflowError; } - if (val) - *val = ov.ulong_value(); - return SWIG_OK; } + if (ov.is_int64_type()) { + long long v = ov.int64_scalar_value().value(); + if (v < 0) { + return SWIG_OverflowError; + } + } + if (val) { + *val = ov.ulong_value(); + } + return SWIG_OK; + } } // long long -%fragment(SWIG_From_frag(long long),"header") { - SWIGINTERNINLINE octave_value SWIG_From_dec(long long) (long long value) - { - return octave_int64(value); - } +%fragment(SWIG_From_frag(long long), "header") +{ + SWIGINTERNINLINE octave_value SWIG_From_dec(long long)(long long value) { + return octave_int64(value); + } } -%fragment(SWIG_AsVal_frag(long long),"header") { - SWIGINTERN int SWIG_AsVal_dec(long long)(const octave_value& ov, long long* val) - { - if (!ov.is_scalar_type()) - return SWIG_TypeError; - if (ov.is_complex_scalar()) - return SWIG_TypeError; - if (ov.is_double_type()||ov.is_single_type()) { - double v=ov.double_value(); - if (v!=floor(v)) - return SWIG_TypeError; +%fragment(SWIG_AsVal_frag(long long), "header") +{ + SWIGINTERN int SWIG_AsVal_dec(long long)(const octave_value & ov, long long * val) { + if (!ov.is_scalar_type()) { + return SWIG_TypeError; + } + if (ov.is_complex_scalar()) { + return SWIG_TypeError; + } + if (ov.is_double_type() || ov.is_single_type()) { + double v = ov.double_value(); + if (v != floor(v)) { + return SWIG_TypeError; } - if (val) { - if (ov.is_int64_type()) - *val = ov.int64_scalar_value().value(); - else if (ov.is_uint64_type()) - *val = ov.uint64_scalar_value().value(); - else - *val = ov.long_value(); + } + if (val) { + if (ov.is_int64_type()) { + *val = ov.int64_scalar_value().value(); + } else if (ov.is_uint64_type()) { + *val = ov.uint64_scalar_value().value(); + } else { + *val = ov.long_value(); } - return SWIG_OK; } + return SWIG_OK; + } } -%fragment(SWIG_From_frag(unsigned long long),"header") { - SWIGINTERNINLINE octave_value SWIG_From_dec(unsigned long long) (unsigned long long value) - { - return octave_uint64(value); - } +%fragment(SWIG_From_frag(unsigned long long), "header") +{ + SWIGINTERNINLINE octave_value SWIG_From_dec(unsigned long long)(unsigned long long value) { + return octave_uint64(value); + } } -%fragment(SWIG_AsVal_frag(unsigned long long),"header") { - SWIGINTERN int SWIG_AsVal_dec(unsigned long long)(const octave_value& ov, unsigned long long* val) - { - if (!ov.is_scalar_type()) - return SWIG_TypeError; - if (ov.is_complex_scalar()) - return SWIG_TypeError; - if (ov.is_double_type()||ov.is_single_type()) { - double v=ov.double_value(); - if (v<0) - return SWIG_OverflowError; - if (v!=floor(v)) - return SWIG_TypeError; +%fragment(SWIG_AsVal_frag(unsigned long long), "header") +{ + SWIGINTERN int SWIG_AsVal_dec(unsigned long long)(const octave_value & ov, unsigned long long * val) { + if (!ov.is_scalar_type()) { + return SWIG_TypeError; + } + if (ov.is_complex_scalar()) { + return SWIG_TypeError; + } + if (ov.is_double_type() || ov.is_single_type()) { + double v = ov.double_value(); + if (v < 0) { + return SWIG_OverflowError; } - if (ov.is_int8_type()||ov.is_int16_type()|| - ov.is_int32_type()) { - long v=ov.long_value(); - if (v<0) - return SWIG_OverflowError; + if (v != floor(v)) { + return SWIG_TypeError; } - if (ov.is_int64_type()) { - long long v=ov.int64_scalar_value().value(); - if (v<0) - return SWIG_OverflowError; + } + if (ov.is_int8_type() || ov.is_int16_type() || + ov.is_int32_type()) { + long v = ov.long_value(); + if (v < 0) { + return SWIG_OverflowError; + } + } + if (ov.is_int64_type()) { + long long v = ov.int64_scalar_value().value(); + if (v < 0) { + return SWIG_OverflowError; } - if (val) { - if (ov.is_int64_type()) - *val = ov.int64_scalar_value().value(); - else if (ov.is_uint64_type()) - *val = ov.uint64_scalar_value().value(); - else - *val = ov.long_value(); + } + if (val) { + if (ov.is_int64_type()) { + *val = ov.int64_scalar_value().value(); + } else if (ov.is_uint64_type()) { + *val = ov.uint64_scalar_value().value(); + } else { + *val = ov.long_value(); } - return SWIG_OK; } + return SWIG_OK; + } } // double -%fragment(SWIG_From_frag(double),"header") { - SWIGINTERNINLINE octave_value SWIG_From_dec(double) (double value) - { - return octave_value(value); - } +%fragment(SWIG_From_frag(double), "header") +{ + SWIGINTERNINLINE octave_value SWIG_From_dec(double)(double value) { + return octave_value(value); + } } -%fragment(SWIG_AsVal_frag(double),"header") { - SWIGINTERN int SWIG_AsVal_dec(double)(const octave_value& ov, double* val) - { - if (!ov.is_scalar_type()) - return SWIG_TypeError; - if (ov.is_complex_scalar()) - return SWIG_TypeError; - if (val) - *val = ov.double_value(); - return SWIG_OK; +%fragment(SWIG_AsVal_frag(double), "header") +{ + SWIGINTERN int SWIG_AsVal_dec(double)(const octave_value & ov, double * val) { + if (!ov.is_scalar_type()) { + return SWIG_TypeError; + } + if (ov.is_complex_scalar()) { + return SWIG_TypeError; + } + if (val) { + *val = ov.double_value(); } + return SWIG_OK; + } } // const char* (strings) -%fragment("SWIG_AsCharPtrAndSize","header") { -SWIGINTERN int -SWIG_AsCharPtrAndSize(octave_value ov, char** cptr, size_t* psize, int *alloc) +%fragment("SWIG_AsCharPtrAndSize", "header") { - if (ov.is_cell() && ov.rows() == 1 && ov.columns() == 1) - ov = ov.cell_value()(0); - if (!ov.is_string()) - return SWIG_TypeError; - - std::string str=ov.string_value(); - size_t len=str.size(); - char* cstr=(char*)str.c_str(); - if (alloc) { - *cptr = %new_copy_array(cstr, len + 1, char); - *alloc = SWIG_NEWOBJ; - } else if (cptr) - *cptr = cstr; - if (psize) - *psize = len + 1; - return SWIG_OK; -} + SWIGINTERN int + SWIG_AsCharPtrAndSize(octave_value ov, char** cptr, size_t * psize, int * alloc) { + if (ov.is_cell() && ov.rows() == 1 && ov.columns() == 1) { + ov = ov.cell_value()(0); + } + if (!ov.is_string()) { + return SWIG_TypeError; + } + + std::string str = ov.string_value(); + size_t len = str.size(); + char* cstr = (char*) str.c_str(); + if (alloc) { + *cptr = %new_copy_array(cstr, len + 1, char); + *alloc = SWIG_NEWOBJ; + } else if (cptr) { + *cptr = cstr; + } + if (psize) { + *psize = len + 1; + } + return SWIG_OK; + } } -%fragment("SWIG_FromCharPtrAndSize","header",fragment="SWIG_pchar_descriptor") { -SWIGINTERNINLINE octave_value -SWIG_FromCharPtrAndSize(const char* carray, size_t size) +%fragment("SWIG_FromCharPtrAndSize", "header", fragment = "SWIG_pchar_descriptor") { - return std::string(carray,carray+size); + SWIGINTERNINLINE octave_value + SWIG_FromCharPtrAndSize(const char * carray, size_t size) { + return std::string(carray, carray + size); + } } -} - - diff --git a/Lib/octave/octrun.swg b/Lib/octave/octrun.swg deleted file mode 100644 index dc9b6b6e6..000000000 --- a/Lib/octave/octrun.swg +++ /dev/null @@ -1,1389 +0,0 @@ - -#include - -// Macro for enabling features which require Octave version >= major.minor.patch -#define SWIG_OCTAVE_PREREQ(major, minor, patch) \ - ( (OCTAVE_MAJOR_VERSION<<16) + (OCTAVE_MINOR_VERSION<<8) + OCTAVE_PATCH_VERSION >= ((major)<<16) + ((minor)<<8) + (patch) ) - -// Reconstruct Octave major, minor, and patch versions for releases prior to 3.8.1 -#if !defined(OCTAVE_MAJOR_VERSION) - -# if !defined(OCTAVE_API_VERSION_NUMBER) - -// Hack to distinguish between Octave 3.8.0, which removed OCTAVE_API_VERSION_NUMBER but did not yet -// introduce OCTAVE_MAJOR_VERSION, and Octave <= 3.2, which did not define OCTAVE_API_VERSION_NUMBER -# include -# if defined(octave_ov_h) -# define OCTAVE_MAJOR_VERSION 3 -# define OCTAVE_MINOR_VERSION 8 -# define OCTAVE_PATCH_VERSION 0 -# else - -// Hack to distinguish between Octave 3.2 and earlier versions, before OCTAVE_API_VERSION_NUMBER existed -# define ComplexLU __ignore -# include -# undef ComplexLU -# if defined(octave_Complex_LU_h) - -// We know only that this version is prior to Octave 3.2, i.e. OCTAVE_API_VERSION_NUMBER < 37 -# define OCTAVE_MAJOR_VERSION 3 -# define OCTAVE_MINOR_VERSION 1 -# define OCTAVE_PATCH_VERSION 99 - -# else - -// OCTAVE_API_VERSION_NUMBER == 37 -# define OCTAVE_MAJOR_VERSION 3 -# define OCTAVE_MINOR_VERSION 2 -# define OCTAVE_PATCH_VERSION 0 - -# endif // defined(octave_Complex_LU_h) - -# endif // defined(octave_ov_h) - -// Correlation between Octave API and version numbers extracted from Octave's -// ChangeLogs; version is the *earliest* released Octave with that API number -# elif OCTAVE_API_VERSION_NUMBER >= 48 -# define OCTAVE_MAJOR_VERSION 3 -# define OCTAVE_MINOR_VERSION 6 -# define OCTAVE_PATCH_VERSION 0 - -# elif OCTAVE_API_VERSION_NUMBER >= 45 -# define OCTAVE_MAJOR_VERSION 3 -# define OCTAVE_MINOR_VERSION 4 -# define OCTAVE_PATCH_VERSION 1 - -# elif OCTAVE_API_VERSION_NUMBER >= 42 -# define OCTAVE_MAJOR_VERSION 3 -# define OCTAVE_MINOR_VERSION 3 -# define OCTAVE_PATCH_VERSION 54 - -# elif OCTAVE_API_VERSION_NUMBER >= 41 -# define OCTAVE_MAJOR_VERSION 3 -# define OCTAVE_MINOR_VERSION 3 -# define OCTAVE_PATCH_VERSION 53 - -# elif OCTAVE_API_VERSION_NUMBER >= 40 -# define OCTAVE_MAJOR_VERSION 3 -# define OCTAVE_MINOR_VERSION 3 -# define OCTAVE_PATCH_VERSION 52 - -# elif OCTAVE_API_VERSION_NUMBER >= 39 -# define OCTAVE_MAJOR_VERSION 3 -# define OCTAVE_MINOR_VERSION 3 -# define OCTAVE_PATCH_VERSION 51 - -# else // OCTAVE_API_VERSION_NUMBER == 38 -# define OCTAVE_MAJOR_VERSION 3 -# define OCTAVE_MINOR_VERSION 3 -# define OCTAVE_PATCH_VERSION 50 - -# endif // !defined(OCTAVE_API_VERSION_NUMBER) - -#endif // !defined(OCTAVE_MAJOR_VERSION) - -#if !SWIG_OCTAVE_PREREQ(3,2,0) -#define SWIG_DEFUN(cname, wname, doc) DEFUNX_DLD(#cname, wname, FS ## cname, args, nargout, doc) -#else -#define SWIG_DEFUN(cname, wname, doc) DEFUNX_DLD(#cname, wname, G ## cname, args, nargout, doc) -#endif - -SWIGRUNTIME bool SWIG_check_num_args(const char *func_name, int num_args, int max_args, int min_args, int varargs) { - if (num_args > max_args && !varargs) - error("function %s takes at most %i arguments", func_name, max_args); - else if (num_args < min_args) - error("function %s requires at least %i arguments", func_name, min_args); - else - return true; - return false; -} - -SWIGRUNTIME octave_value_list *SWIG_Octave_AppendOutput(octave_value_list *ovl, const octave_value &ov) { - ovl->append(ov); - return ovl; -} - -SWIGRUNTIME octave_value SWIG_ErrorType(int code) { - switch (code) { - case SWIG_MemoryError: - return "SWIG_MemoryError"; - case SWIG_IOError: - return "SWIG_IOError"; - case SWIG_RuntimeError: - return "SWIG_RuntimeError"; - case SWIG_IndexError: - return "SWIG_IndexError"; - case SWIG_TypeError: - return "SWIG_TypeError"; - case SWIG_DivisionByZero: - return "SWIG_DivisionByZero"; - case SWIG_OverflowError: - return "SWIG_OverflowError"; - case SWIG_SyntaxError: - return "SWIG_SyntaxError"; - case SWIG_ValueError: - return "SWIG_ValueError"; - case SWIG_SystemError: - return "SWIG_SystemError"; - case SWIG_AttributeError: - return "SWIG_AttributeError"; - } - return "SWIG unknown error"; -} - -SWIGRUNTIME octave_value SWIG_Error(int code, const char *msg) { - octave_value type(SWIG_ErrorType(code)); - std::string r = msg; - r += " (" + type.string_value() + ")"; - error(r.c_str()); - return octave_value(r); -} - -#define SWIG_fail goto fail - -#define SWIG_Octave_ConvertPtr(obj, pptr, type, flags) SWIG_Octave_ConvertPtrAndOwn(obj, pptr, type, flags, 0) -#define SWIG_ConvertPtr(obj, pptr, type, flags) SWIG_Octave_ConvertPtr(obj, pptr, type, flags) -#define SWIG_ConvertPtrAndOwn(obj,pptr,type,flags,own) SWIG_Octave_ConvertPtrAndOwn(obj, pptr, type, flags, own) -#define SWIG_ConvertPtr(obj, pptr, type, flags) SWIG_Octave_ConvertPtr(obj, pptr, type, flags) -#define SWIG_NewPointerObj(ptr, type, flags) SWIG_Octave_NewPointerObj(ptr, type, flags) -#define swig_owntype int - -#define SWIG_ConvertPacked(obj, ptr, sz, ty) SWIG_Octave_ConvertPacked(obj, ptr, sz, ty) -#define SWIG_NewPackedObj(ptr, sz, type) SWIG_Octave_NewPackedObj(ptr, sz, type) - -#define SWIG_ConvertFunctionPtr(obj, pptr, type) SWIG_ConvertPtr(obj, pptr, type, 0) -#define SWIG_NewFunctionPtrObj(ptr, type) SWIG_NewPointerObj(ptr, type, 0) - -#define SWIG_ConvertMember(obj, ptr, sz, ty) SWIG_Octave_ConvertPacked(obj, ptr, sz, ty) -#define SWIG_NewMemberObj(ptr, sz, type) SWIG_Octave_NewPackedObj(ptr, sz, type) - -#define SWIG_GetModule(clientdata) SWIG_Octave_GetModule(clientdata) -#define SWIG_SetModule(clientdata, pointer) SWIG_Octave_SetModule(clientdata,pointer); -#define SWIG_MODULE_CLIENTDATA_TYPE void* - -#define Octave_Error_Occurred() 0 -#define SWIG_Octave_AddErrorMsg(msg) {;} - -SWIGRUNTIME swig_module_info *SWIG_Octave_GetModule(void *clientdata); -SWIGRUNTIME void SWIG_Octave_SetModule(void *clientdata, swig_module_info *pointer); - -// For backward compatibility only -#define SWIG_POINTER_EXCEPTION 0 -#define SWIG_arg_fail(arg) 0 - -// Runtime API implementation - -#include -#include -#include - -typedef octave_value_list(*octave_func) (const octave_value_list &, int); -class octave_swig_type; - -namespace Swig { - -#ifdef SWIG_DIRECTORS - - class Director; - - typedef std::map < void *, Director * > rtdir_map; - SWIGINTERN rtdir_map* get_rtdir_map(); - SWIGINTERNINLINE void set_rtdir(void *vptr, Director *d); - SWIGINTERNINLINE void erase_rtdir(void *vptr); - SWIGINTERNINLINE Director *get_rtdir(void *vptr); - - SWIGRUNTIME void swig_director_destroyed(octave_swig_type *self, Director *d); - SWIGRUNTIME octave_swig_type *swig_director_get_self(Director *d); - SWIGRUNTIME void swig_director_set_self(Director *d, octave_swig_type *self); - -#endif - - SWIGRUNTIME octave_base_value *swig_value_ref(octave_swig_type *ost); - SWIGRUNTIME octave_swig_type *swig_value_deref(octave_value ov); - SWIGRUNTIME octave_swig_type *swig_value_deref(const octave_base_value &ov); -} - -#ifdef SWIG_DIRECTORS -SWIGRUNTIME void swig_acquire_ownership(void *vptr); -SWIGRUNTIME void swig_acquire_ownership_array(void *vptr); -SWIGRUNTIME void swig_acquire_ownership_obj(void *vptr, int own); -#endif - - struct swig_octave_member { - const char *name; - octave_func method; - octave_func get_method; - octave_func set_method; - int flags; // 1 static, 2 global - const char *doc; - bool is_static() const { - return flags &1; - } bool is_global() const { - return flags &2; - } - }; - - struct swig_octave_class { - const char *name; - swig_type_info **type; - int director; - octave_func constructor; - const char *constructor_doc; - octave_func destructor; - const swig_octave_member *members; - const char **base_names; - const swig_type_info **base; - }; - - // octave_swig_type plays the role of both the shadow class and the class - // representation within Octave, since there is no support for classes. - // - // These should really be decoupled, with the class support added to Octave - // and the shadow class given by an m-file script. That would dramatically - // reduce the runtime complexity, and be more in line w/ other modules. - - class octave_swig_type:public octave_base_value { - struct cpp_ptr { - void *ptr; - bool destroyed; - cpp_ptr(void *_ptr):ptr(_ptr), destroyed(false) { - }}; - typedef std::pair < const swig_type_info *, cpp_ptr > type_ptr_pair; - - mutable swig_module_info *module; - - const swig_type_info *construct_type; // type of special type object - std::vector < type_ptr_pair > types; // our c++ base classes - int own; // whether we call c++ destructors when we die - - typedef std::pair < const swig_octave_member *, octave_value > member_value_pair; - typedef std::map < std::string, member_value_pair > member_map; - member_map members; - bool always_static; - - const swig_octave_member *find_member(const swig_type_info *type, const std::string &name) { - if (!type->clientdata) - return 0; - swig_octave_class *c = (swig_octave_class *) type->clientdata; - const swig_octave_member *m; - for (m = c->members; m->name; ++m) - if (m->name == name) - return m; - for (int j = 0; c->base_names[j]; ++j) { - if (!c->base[j]) { - if (!module) - module = SWIG_GetModule(0); - assert(module); - c->base[j] = SWIG_MangledTypeQueryModule(module, module, c->base_names[j]); - } - if (!c->base[j]) - return 0; - if ((m = find_member(c->base[j], name))) - return m; - } - return 0; - } - - member_value_pair *find_member(const std::string &name, bool insert_if_not_found) { - member_map::iterator it = members.find(name); - if (it != members.end()) - return &it->second; - const swig_octave_member *m; - for (unsigned int j = 0; j < types.size(); ++j) - if ((m = find_member(types[j].first, name))) - return &members.insert(std::make_pair(name, std::make_pair(m, octave_value()))).first->second; - if (!insert_if_not_found) - return 0; - return &members[name]; - } - - const swig_type_info *find_base(const std::string &name, const swig_type_info *base) { - if (!base) { - for (unsigned int j = 0; j < types.size(); ++j) { - assert(types[j].first->clientdata); - swig_octave_class *cj = (swig_octave_class *) types[j].first->clientdata; - if (cj->name == name) - return types[j].first; - } - return 0; - } - assert(base->clientdata); - swig_octave_class *c = (swig_octave_class *) base->clientdata; - for (int j = 0; c->base_names[j]; ++j) { - if (!c->base[j]) { - if (!module) - module = SWIG_GetModule(0); - assert(module); - c->base[j] = SWIG_MangledTypeQueryModule(module, module, c->base_names[j]); - } - if (!c->base[j]) - return 0; - assert(c->base[j]->clientdata); - swig_octave_class *cj = (swig_octave_class *) c->base[j]->clientdata; - if (cj->name == name) - return c->base[j]; - } - return 0; - } - - void load_members(const swig_octave_class* c,member_map& out) const { - for (const swig_octave_member *m = c->members; m->name; ++m) { - if (out.find(m->name) == out.end()) - out.insert(std::make_pair(m->name, std::make_pair(m, octave_value()))); - } - for (int j = 0; c->base_names[j]; ++j) { - if (!c->base[j]) { - if (!module) - module = SWIG_GetModule(0); - assert(module); - c->base[j] = SWIG_MangledTypeQueryModule(module, module, c->base_names[j]); - } - if (!c->base[j]) - continue; - assert(c->base[j]->clientdata); - const swig_octave_class *cj = - (const swig_octave_class *) c->base[j]->clientdata; - load_members(cj,out); - } - } - - void load_members(member_map& out) const { - out=members; - for (unsigned int j = 0; j < types.size(); ++j) - if (types[j].first->clientdata) - load_members((const swig_octave_class *) types[j].first->clientdata, out); - } - - octave_value_list member_invoke(member_value_pair *m, const octave_value_list &args, int nargout) { - if (m->second.is_defined()) - return m->second.subsref("(", std::list < octave_value_list > (1, args), nargout); - else if (m->first && m->first->method) - return m->first->method(args, nargout); - error("member not defined or not invocable"); - return octave_value_list(); - } - - bool dispatch_unary_op(const std::string &symbol, octave_value &ret) { - member_value_pair *m = find_member(symbol, false); - if (!m || m->first->is_static() || m->first->is_global()) - return false; - octave_value_list args; - args.append(as_value()); - octave_value_list argout(member_invoke(m, args, 1)); - if (argout.length() < 1) - return false; - ret = argout(0); - return true; - } - - bool dispatch_binary_op(const std::string &symbol, const octave_base_value &rhs, octave_value &ret) { - member_value_pair *m = find_member(symbol, false); - if (!m || m->first->is_static() || m->first->is_global()) - return false; - octave_value_list args; - args.append(as_value()); - args.append(make_value_hack(rhs)); - octave_value_list argout(member_invoke(m, args, 1)); - if (argout.length() < 1) - return false; - ret = argout(0); - return true; - } - - bool dispatch_index_op(const std::string &symbol, const octave_value_list &rhs, octave_value_list &ret) { - member_value_pair *m = find_member(symbol, false); - if (!m || m->first->is_static() || m->first->is_global()) - return false; - octave_value_list args; - args.append(as_value()); - args.append(rhs); - octave_value_list argout(member_invoke(m, args, 1)); - if (argout.length() >= 1) - ret = argout(0); - return true; - } - - octave_value_list member_deref(member_value_pair *m, const octave_value_list &args) { - if (m->second.is_defined()) - return m->second; - else if (m->first) { - if (m->first->get_method) - return m->first->get_method(args, 1); - else if (m->first->method) - return octave_value(new octave_builtin(m->first->method)); - } - error("undefined member"); - return octave_value_list(); - } - - static octave_value make_value_hack(const octave_base_value &x) { - ((octave_swig_type &) x).count++; - return octave_value((octave_base_value *) &x); - } - - octave_swig_type(const octave_swig_type &x); - octave_swig_type &operator=(const octave_swig_type &rhs); - public: - - octave_swig_type(void *_ptr = 0, const swig_type_info *_type = 0, int _own = 0, - bool _always_static = false) - : module(0), construct_type(_ptr ? 0 : _type), own(_own), - always_static(_always_static) { - if (_type || _ptr) - types.push_back(std::make_pair(_type, _ptr)); -#ifdef SWIG_DIRECTORS - if (_ptr) { - Swig::Director *d = Swig::get_rtdir(_ptr); - if (d) - Swig::swig_director_set_self(d, this); - } -#endif - } - - ~octave_swig_type() { - if (own) { - ++count; - for (unsigned int j = 0; j < types.size(); ++j) { - if (!types[j].first || !types[j].first->clientdata) - continue; - swig_octave_class *c = (swig_octave_class *) types[j].first->clientdata; - if (c->destructor && !types[j].second.destroyed && types[j].second.ptr) { - c->destructor(as_value(), 0); - } - } - } -#ifdef SWIG_DIRECTORS - for (unsigned int j = 0; j < types.size(); ++j) - Swig::erase_rtdir(types[j].second.ptr); -#endif - } - - dim_vector dims(void) const { - octave_swig_type *nc_this = const_cast < octave_swig_type *>(this); - - // Find the __dims__ method of this object - member_value_pair *m = nc_this->find_member("__dims__", false); - - if (!m) return dim_vector(1,1); - - // Call the __dims__ method of this object - octave_value_list inarg; - inarg.append(nc_this->as_value()); - octave_value_list outarg = nc_this->member_invoke(m, inarg, 1); - - // __dims__ should return (at least) one output argument - if (outarg.length() < 1) return dim_vector(1,1); - - octave_value & out = outarg(0); - - // Return value should be cell or matrix of integers - if (out.is_cell()) { - const Cell & c=out.cell_value(); - int ndim = c.rows(); - if (ndim==1 && c.columns()!=1) ndim = c.columns(); - - dim_vector d; - d.resize(ndim < 2 ? 2 : ndim); - d(0) = d(1) = 1; - - // Fill in dim_vector - for (int k=0;k a = out.int_vector_value(); - if (error_state) return dim_vector(1,1); - dim_vector d; - d.resize(a.numel() < 2 ? 2 : a.numel()); - d(0) = d(1) = 1; - for (int k=0;kclientdata) - return 0; - swig_octave_class *c = (swig_octave_class *) types[0].first->clientdata; - return c->constructor_doc; - } - - std::string swig_type_name() const { - // * need some way to manually name subclasses. - // * eg optional first arg to subclass(), or named_subclass() - std::string ret; - for (unsigned int j = 0; j < types.size(); ++j) { - if (j) - ret += "_"; - if (types[j].first->clientdata) { - swig_octave_class *c = (swig_octave_class *) types[j].first->clientdata; - ret += c->name; - } else - ret += types[j].first->name; - } - return ret; - } - - void merge(octave_swig_type &rhs) { - rhs.own = 0; - for (unsigned int j = 0; j < rhs.types.size(); ++j) { - assert(!rhs.types[j].second.destroyed); -#ifdef SWIG_DIRECTORS - Swig::Director *d = Swig::get_rtdir(rhs.types[j].second.ptr); - if (d) - Swig::swig_director_set_self(d, this); -#endif - } - types.insert(types.end(), rhs.types.begin(), rhs.types.end()); - members.insert(rhs.members.begin(), rhs.members.end()); - rhs.types.clear(); - rhs.members.clear(); - } - - typedef member_map::const_iterator swig_member_const_iterator; - swig_member_const_iterator swig_members_begin() { return members.begin(); } - swig_member_const_iterator swig_members_end() { return members.end(); } - - void *cast(swig_type_info *type, int *_own, int flags) { - if (_own) - *_own = own; - if (flags &SWIG_POINTER_DISOWN) - own = 0; - if (!type && types.size()) - return types[0].second.ptr; - for (unsigned int j = 0; j < types.size(); ++j) - if (type == types[j].first) - return types[j].second.ptr; - for (unsigned int j = 0; j < types.size(); ++j) { - swig_cast_info *tc = SWIG_TypeCheck(types[j].first->name, type); - if (!tc) - continue; - int newmemory = 0; - void *vptr = SWIG_TypeCast(tc, types[j].second.ptr, &newmemory); - assert(!newmemory); // newmemory handling not yet implemented - return vptr; - } - return 0; - } - - bool is_owned() const { - return own; - } - -#ifdef SWIG_DIRECTORS - void director_destroyed(Swig::Director *d) { - bool found = false; - for (unsigned int j = 0; j < types.size(); ++j) { - Swig::Director *dj = Swig::get_rtdir(types[j].second.ptr); - if (dj == d) { - types[j].second.destroyed = true; - found = true; - } - } - assert(found); - } -#endif - - void assign(const std::string &name, const octave_value &ov) { - members[name] = std::make_pair((const swig_octave_member *) 0, ov); - } - - void assign(const std::string &name, const swig_octave_member *m) { - members[name] = std::make_pair(m, octave_value()); - } - - octave_base_value *clone() const { - // pass-by-value is probably not desired, and is harder; - // requires calling copy constructors of contained types etc. - assert(0); - *(int *) 0 = 0; - return 0; - } - - octave_base_value *empty_clone() const { - return new octave_swig_type(); - } - - bool is_defined() const { - return true; - } - - virtual bool is_map() const { - return true; - } - - virtual octave_value subsref(const std::string &ops, const std::list < octave_value_list > &idx) { - octave_value_list ovl = subsref(ops, idx, 1); - return ovl.length()? ovl(0) : octave_value(); - } - - virtual octave_value_list subsref(const std::string &ops, const std::list < octave_value_list > &idx, int nargout) { - assert(ops.size() > 0); - assert(ops.size() == idx.size()); - - std::list < octave_value_list >::const_iterator idx_it = idx.begin(); - int skip = 0; - octave_value_list sub_ovl; - - // constructor invocation - if (ops[skip] == '(' && construct_type) { - assert(construct_type->clientdata); - swig_octave_class *c = (swig_octave_class *) construct_type->clientdata; - if (!c->constructor) { - error("cannot create instance"); - return octave_value_list(); - } - octave_value_list args; - if (c->director) - args.append(Swig::swig_value_ref(new octave_swig_type(this, 0, 0))); - args.append(*idx_it++); - ++skip; - sub_ovl = c->constructor(args, nargout); - } - // member dereference or invocation - else if (ops[skip] == '.') { - std::string subname; - const swig_type_info *base = 0; // eg, a.base.base_cpp_mem - for (;;) { - octave_value_list subname_ovl(*idx_it++); - ++skip; - assert(subname_ovl.length() == 1 && subname_ovl(0).is_string()); - subname = subname_ovl(0).string_value(); - - const swig_type_info *next_base = find_base(subname, base); - if (!next_base || skip >= (int) ops.size() || ops[skip] != '.') - break; - base = next_base; - } - - member_value_pair tmp, *m = &tmp; - if (!base || !(m->first = find_member(base, subname))) - m = find_member(subname, false); - if (!m) { - error("member not found"); - return octave_value_list(); - } - - octave_value_list args; - if (!always_static && - (!m->first || (!m->first->is_static() && !m->first->is_global()))) - args.append(as_value()); - if (skip < (int) ops.size() && ops[skip] == '(' && - ((m->first && m->first->method) || m->second.is_function() || - m->second.is_function_handle())) { - args.append(*idx_it++); - ++skip; - sub_ovl = member_invoke(m, args, nargout); - } else { - sub_ovl = member_deref(m, args); - } - } - // index operator - else { - if (ops[skip] == '(' || ops[skip] == '{') { - const char *op_name = ops[skip] == '(' ? "__paren__" : "__brace__"; - octave_value_list args; - args.append(*idx_it++); - ++skip; - if (!dispatch_index_op(op_name, args, sub_ovl)) { - error("error evaluating index operator"); - return octave_value_list(); - } - } else { - error("unsupported subsref"); - return octave_value_list(); - } - } - - if (skip >= (int) ops.size()) - return sub_ovl; - if (sub_ovl.length() < 1) { - error("bad subs ref"); - return octave_value_list(); - } - return sub_ovl(0).next_subsref(nargout, ops, idx, skip); - } - - octave_value subsasgn(const std::string &ops, const std::list < octave_value_list > &idx, const octave_value &rhs) { - assert(ops.size() > 0); - assert(ops.size() == idx.size()); - - std::list < octave_value_list >::const_iterator idx_it = idx.begin(); - int skip = 0; - - if (ops.size() > 1) { - std::list < octave_value_list >::const_iterator last = idx.end(); - --last; - std::list < octave_value_list > next_idx(idx.begin(), last); - octave_value next_ov = subsref(ops.substr(0, ops.size() - 1), next_idx); - next_ov.subsasgn(ops.substr(ops.size() - 1), std::list < octave_value_list > (1, *last), rhs); - } - - else if (ops[skip] == '(' || ops[skip] == '{') { - const char *op_name = ops[skip] == '(' ? "__paren_asgn__" : "__brace_asgn__"; - member_value_pair *m = find_member(op_name, false); - if (m) { - octave_value_list args; - args.append(as_value()); - args.append(*idx_it); - args.append(rhs); - member_invoke(m, args, 1); - } else - error("%s member not found", op_name); - } - - else if (ops[skip] == '.') { - octave_value_list subname_ovl(*idx_it++); - ++skip; - assert(subname_ovl.length() == 1 &&subname_ovl(0).is_string()); - std::string subname = subname_ovl(0).string_value(); - - member_value_pair *m = find_member(subname, true); - if (!m->first || !m->first->set_method) { - m->first = 0; - m->second = rhs; - } else if (m->first->set_method) { - octave_value_list args; - if (!m->first->is_static() && !m->first->is_global()) - args.append(as_value()); - args.append(rhs); - m->first->set_method(args, 1); - } else - error("member not assignable"); - } else - error("unsupported subsasgn"); - - return as_value(); - } - - virtual bool is_object() const { - return true; - } - - virtual bool is_string() const { - octave_swig_type *nc_this = const_cast < octave_swig_type *>(this); - return !!nc_this->find_member("__str__", false); - } - - virtual std::string string_value(bool force = false) const { - octave_swig_type *nc_this = const_cast < octave_swig_type *>(this); - member_value_pair *m = nc_this->find_member("__str__", false); - if (!m) { - error("__str__ method not defined"); - return std::string(); - } - octave_value_list outarg = nc_this->member_invoke(m, octave_value_list(nc_this->as_value()), 1); - if (outarg.length() < 1 || !outarg(0).is_string()) { - error("__str__ method did not return a string"); - return std::string(); - } - return outarg(0).string_value(); - } - -#if SWIG_OCTAVE_PREREQ(3,3,52) - virtual octave_map map_value() const { - return octave_map(); - } -#else - virtual Octave_map map_value() const { - return Octave_map(); - } -#endif - - virtual string_vector map_keys() const { - member_map tmp; - load_members(tmp); - - string_vector keys(tmp.size()); - int k = 0; - for (member_map::iterator it = tmp.begin(); it != tmp.end(); ++it) - keys(k++) = it->first; - - return keys; - } - - virtual bool save_ascii (std::ostream& os) { - return true; - } - - virtual bool load_ascii (std::istream& is) { - return true; - } - - virtual bool save_binary (std::ostream& os, bool& save_as_floats) { - return true; - } - - virtual bool load_binary (std::istream& is, bool swap, - oct_mach_info::float_format fmt) { - return true; - } - -#if defined (HAVE_HDF5) - virtual bool - save_hdf5 (hid_t loc_id, const char *name, bool save_as_floats) { - return true; - } - - virtual bool - load_hdf5 (hid_t loc_id, const char *name, bool have_h5giterate_bug) { - return true; - } -#endif - - virtual octave_value convert_to_str(bool pad = false, bool force = false, char type = '"') const { - return string_value(); - } - - virtual octave_value convert_to_str_internal(bool pad, bool force, char type) const { - return string_value(); - } - - static bool dispatch_global_op(const std::string &symbol, const octave_value_list &args, octave_value &ret) { - // we assume that SWIG_op_prefix-prefixed functions are installed in global namespace - // (rather than any module namespace). - - octave_function *fcn = is_valid_function(symbol, std::string(), false); - if (!fcn) - return false; - ret = fcn->do_multi_index_op(1, args)(0); - return true; - } - - static octave_value dispatch_unary_op(const octave_base_value &x, const char *op_name) { - octave_swig_type *ost = Swig::swig_value_deref(x); - assert(ost); - - octave_value ret; - if (ost->dispatch_unary_op(std::string("__") + op_name + std::string("__"), ret)) - return ret; - std::string symbol = SWIG_op_prefix + ost->swig_type_name() + "_" + op_name; - octave_value_list args; - args.append(make_value_hack(x)); - if (dispatch_global_op(symbol, args, ret)) - return ret; - - error("could not dispatch unary operator"); - return octave_value(); - } - - static octave_value dispatch_binary_op(const octave_base_value &lhs, const octave_base_value &rhs, const char *op_name) { - octave_swig_type *lhs_ost = Swig::swig_value_deref(lhs); - octave_swig_type *rhs_ost = Swig::swig_value_deref(rhs); - - octave_value ret; - if (lhs_ost && lhs_ost->dispatch_binary_op(std::string("__") + op_name + std::string("__"), rhs, ret)) - return ret; - if (rhs_ost) { - if (strlen(op_name) == 2 && (op_name[1] == 't' || op_name[1] == 'e')) { - if (op_name[0] == 'l' && rhs_ost->dispatch_binary_op(std::string("__g") + op_name[1] + std::string("__"), lhs, ret)) - return ret; - if (op_name[0] == 'g' && rhs_ost->dispatch_binary_op(std::string("__l") + op_name[1] + std::string("__"), lhs, ret)) - return ret; - } - if (rhs_ost->dispatch_binary_op(std::string("__r") + op_name + std::string("__"), lhs, ret)) - return ret; - } - - std::string symbol; - octave_value_list args; - args.append(make_value_hack(lhs)); - args.append(make_value_hack(rhs)); - - symbol = SWIG_op_prefix; - symbol += lhs_ost ? lhs_ost->swig_type_name() : lhs.type_name(); - symbol += "_"; - symbol += op_name; - symbol += "_"; - symbol += rhs_ost ? rhs_ost->swig_type_name() : rhs.type_name(); - if (dispatch_global_op(symbol, args, ret)) - return ret; - - symbol = SWIG_op_prefix; - symbol += lhs_ost ? lhs_ost->swig_type_name() : lhs.type_name(); - symbol += "_"; - symbol += op_name; - symbol += "_"; - symbol += "any"; - if (dispatch_global_op(symbol, args, ret)) - return ret; - - symbol = SWIG_op_prefix; - symbol += "any"; - symbol += "_"; - symbol += op_name; - symbol += "_"; - symbol += rhs_ost ? rhs_ost->swig_type_name() : rhs.type_name(); - if (dispatch_global_op(symbol, args, ret)) - return ret; - - error("could not dispatch binary operator"); - return octave_value(); - } - - void print(std::ostream &os, bool pr_as_read_syntax = false) const { - if (is_string()) { - os << string_value(); - return; - } - - member_map tmp; - load_members(tmp); - - indent(os); - os << "{"; newline(os); - increment_indent_level(); - for (unsigned int j = 0; j < types.size(); ++j) { - indent(os); - if (types[j].first->clientdata) { - const swig_octave_class *c = (const swig_octave_class *) types[j].first->clientdata; - os << c->name << ", ptr = " << types[j].second.ptr; newline(os); - } else { - os << types[j].first->name << ", ptr = " << types[j].second.ptr; newline(os); - } - } - for (member_map::const_iterator it = tmp.begin(); it != tmp.end(); ++it) { - indent(os); - if (it->second.first) { - const char *objtype = it->second.first->method ? "method" : "variable"; - const char *modifier = (it->second.first->flags &1) ? "static " : (it->second.first->flags &2) ? "global " : ""; - os << it->second.first->name << " (" << modifier << objtype << ")"; newline(os); - assert(it->second.first->name == it->first); - } else { - os << it->first; newline(os); - } - } - decrement_indent_level(); - indent(os); - os << "}"; newline(os); - } - }; - - // Octave tries hard to preserve pass-by-value semantics. Eg, assignments - // will call clone() via make_unique() if there is more than one outstanding - // reference to the lhs, and forces the clone's reference count to 1 - // (so you can't just increment your own count and return this). - // - // One way to fix this (without modifying Octave) is to add a level of - // indirection such that clone copies ref-counted pointer and we keep - // pass-by-ref semantics (which are more natural/expected for C++ bindings). - // - // Supporting both pass-by-{ref,value} and toggling via %feature/option - // might be nice. - - class octave_swig_ref:public octave_base_value { - octave_swig_type *ptr; - public: - octave_swig_ref(octave_swig_type *_ptr = 0) - :ptr(_ptr) { } - - ~octave_swig_ref() - { if (ptr) ptr->decref(); } - - octave_swig_type *get_ptr() const - { return ptr; } - - octave_base_value *clone() const - { if (ptr) ptr->incref(); return new octave_swig_ref(ptr); } - - octave_base_value *empty_clone() const - { return new octave_swig_ref(0); } - - dim_vector dims(void) const - { return ptr->dims(); } - - bool is_defined() const - { return ptr->is_defined(); } - - virtual bool is_map() const - { return ptr->is_map(); } - - virtual octave_value subsref(const std::string &ops, const std::list < octave_value_list > &idx) - { return ptr->subsref(ops, idx); } - - virtual octave_value_list subsref(const std::string &ops, const std::list < octave_value_list > &idx, int nargout) - { return ptr->subsref(ops, idx, nargout); } - - octave_value subsasgn(const std::string &ops, const std::list < octave_value_list > &idx, const octave_value &rhs) - { return ptr->subsasgn(ops, idx, rhs); } - - virtual bool is_object() const - { return ptr->is_object(); } - - virtual bool is_string() const - { return ptr->is_string(); } - - virtual std::string string_value(bool force = false) const - { return ptr->string_value(force); } - -#if SWIG_OCTAVE_PREREQ(3,3,52) - virtual octave_map map_value() const - { return ptr->map_value(); } -#else - virtual Octave_map map_value() const - { return ptr->map_value(); } -#endif - - virtual string_vector map_keys() const - { return ptr->map_keys(); } - - virtual bool save_ascii (std::ostream& os) - { return ptr->save_ascii(os); } - - virtual bool load_ascii (std::istream& is) - { return ptr->load_ascii(is); } - - virtual bool save_binary (std::ostream& os, bool& save_as_floats) - { return ptr->save_binary(os, save_as_floats); } - - virtual bool load_binary (std::istream& is, bool swap, - oct_mach_info::float_format fmt) - { return ptr->load_binary(is, swap, fmt); } - -#if defined (HAVE_HDF5) - virtual bool - save_hdf5 (hid_t loc_id, const char *name, bool save_as_floats) - { return ptr->save_hdf5(loc_id, name, save_as_floats); } - - virtual bool - load_hdf5 (hid_t loc_id, const char *name, bool have_h5giterate_bug) - { return ptr->load_hdf5(loc_id, name, have_h5giterate_bug); } -#endif - - virtual octave_value convert_to_str(bool pad = false, bool force = false, char type = '"') const - { return ptr->convert_to_str(pad, force, type); } - - virtual octave_value convert_to_str_internal(bool pad, bool force, char type) const - { return ptr->convert_to_str_internal(pad, force, type); } - - void print(std::ostream &os, bool pr_as_read_syntax = false) const - { return ptr->print(os, pr_as_read_syntax); } - - private: - DECLARE_OCTAVE_ALLOCATOR; - DECLARE_OV_TYPEID_FUNCTIONS_AND_DATA; - }; - DEFINE_OCTAVE_ALLOCATOR(octave_swig_ref); - DEFINE_OV_TYPEID_FUNCTIONS_AND_DATA(octave_swig_ref, "swig_ref", "swig_ref"); - - class octave_swig_packed:public octave_base_value { - swig_type_info *type; - std::vector < char > buf; - public: - - octave_swig_packed(swig_type_info *_type = 0, const void *_buf = 0, size_t _buf_len = 0) - : type(_type), buf((const char*)_buf, (const char*)_buf + _buf_len) { - } - - bool copy(swig_type_info *outtype, void *ptr, size_t sz) const { - if (outtype && outtype != type) - return false; - assert(sz <= buf.size()); - std::copy(buf.begin(), buf.begin()+sz, (char*)ptr); - return true; - } - - octave_base_value *clone() const { - return new octave_swig_packed(*this); - } - - octave_base_value *empty_clone() const { - return new octave_swig_packed(); - } - - bool is_defined() const { - return true; - } - - void print(std::ostream &os, bool pr_as_read_syntax = false) const { - indent(os); - os << "swig packed type: name = " << (type ? type->name : std::string()) << ", len = " << buf.size(); newline(os); - } - - - virtual bool save_ascii (std::ostream& os) { - return true; - } - - virtual bool load_ascii (std::istream& is) { - return true; - } - - virtual bool save_binary (std::ostream& os, bool& save_as_floats) { - return true; - } - - virtual bool load_binary (std::istream& is, bool swap, - oct_mach_info::float_format fmt) { - return true; - } - -#if defined (HAVE_HDF5) - virtual bool - save_hdf5 (hid_t loc_id, const char *name, bool save_as_floats) { - return true; - } - - virtual bool - load_hdf5 (hid_t loc_id, const char *name, bool have_h5giterate_bug) { - return true; - } -#endif - - private: - DECLARE_OCTAVE_ALLOCATOR; - DECLARE_OV_TYPEID_FUNCTIONS_AND_DATA; - }; - DEFINE_OCTAVE_ALLOCATOR(octave_swig_packed); - DEFINE_OV_TYPEID_FUNCTIONS_AND_DATA(octave_swig_packed, "swig_packed", "swig_packed"); - - SWIGRUNTIME octave_value_list octave_set_immutable(const octave_value_list &args, int nargout) { - error("attempt to set immutable member variable"); - return octave_value_list(); - } - - struct octave_value_ref { - const octave_value_list &ovl; - int j; - - octave_value_ref(const octave_value_list &_ovl, int _j) - :ovl(_ovl), j(_j) { } - - operator octave_value() const { - return ovl(j); - } - - octave_value operator*() const { - return ovl(j); - } - }; - - -namespace Swig { - - SWIGRUNTIME octave_base_value *swig_value_ref(octave_swig_type *ost) { - return new octave_swig_ref(ost); - } - - SWIGRUNTIME octave_swig_type *swig_value_deref(octave_value ov) { - if (ov.is_cell() && ov.rows() == 1 && ov.columns() == 1) - ov = ov.cell_value()(0); - return swig_value_deref(*ov.internal_rep()); - } - - SWIGRUNTIME octave_swig_type *swig_value_deref(const octave_base_value &ov) { - if (ov.type_id() != octave_swig_ref::static_type_id()) - return 0; - const octave_swig_ref *osr = static_cast < const octave_swig_ref *>(&ov); - return osr->get_ptr(); - } - -} - - -#define swig_unary_op(name) \ -SWIGRUNTIME octave_value swig_unary_op_##name(const octave_base_value &x) { \ - return octave_swig_type::dispatch_unary_op(x,#name); \ -} -#define swig_binary_op(name) \ -SWIGRUNTIME octave_value swig_binary_op_##name(const octave_base_value&lhs,const octave_base_value &rhs) { \ - return octave_swig_type::dispatch_binary_op(lhs,rhs,#name); \ -} -#define swigreg_unary_op(name) \ -if (!octave_value_typeinfo::lookup_unary_op(octave_value::op_##name,tid)) \ -octave_value_typeinfo::register_unary_op(octave_value::op_##name,tid,swig_unary_op_##name); -#define swigreg_binary_op(name) \ -if (!octave_value_typeinfo::lookup_binary_op(octave_value::op_##name,tid1,tid2)) \ -octave_value_typeinfo::register_binary_op(octave_value::op_##name,tid1,tid2,swig_binary_op_##name); - - swig_unary_op(not); - swig_unary_op(uplus); - swig_unary_op(uminus); - swig_unary_op(transpose); - swig_unary_op(hermitian); - swig_unary_op(incr); - swig_unary_op(decr); - - swig_binary_op(add); - swig_binary_op(sub); - swig_binary_op(mul); - swig_binary_op(div); - swig_binary_op(pow); - swig_binary_op(ldiv); - swig_binary_op(lshift); - swig_binary_op(rshift); - swig_binary_op(lt); - swig_binary_op(le); - swig_binary_op(eq); - swig_binary_op(ge); - swig_binary_op(gt); - swig_binary_op(ne); - swig_binary_op(el_mul); - swig_binary_op(el_div); - swig_binary_op(el_pow); - swig_binary_op(el_ldiv); - swig_binary_op(el_and); - swig_binary_op(el_or); - - SWIGRUNTIME void SWIG_InstallUnaryOps(int tid) { - swigreg_unary_op(not); - swigreg_unary_op(uplus); - swigreg_unary_op(uminus); - swigreg_unary_op(transpose); - swigreg_unary_op(hermitian); - swigreg_unary_op(incr); - swigreg_unary_op(decr); - } - SWIGRUNTIME void SWIG_InstallBinaryOps(int tid1, int tid2) { - swigreg_binary_op(add); - swigreg_binary_op(sub); - swigreg_binary_op(mul); - swigreg_binary_op(div); - swigreg_binary_op(pow); - swigreg_binary_op(ldiv); - swigreg_binary_op(lshift); - swigreg_binary_op(rshift); - swigreg_binary_op(lt); - swigreg_binary_op(le); - swigreg_binary_op(eq); - swigreg_binary_op(ge); - swigreg_binary_op(gt); - swigreg_binary_op(ne); - swigreg_binary_op(el_mul); - swigreg_binary_op(el_div); - swigreg_binary_op(el_pow); - swigreg_binary_op(el_ldiv); - swigreg_binary_op(el_and); - swigreg_binary_op(el_or); - } - SWIGRUNTIME void SWIG_InstallOps(int tid) { - // here we assume that tid are conseq integers increasing from zero, and - // that our tid is the last one. might be better to have explicit string - // list of types we should bind to, and use lookup_type to resolve their tid. - - SWIG_InstallUnaryOps(tid); - SWIG_InstallBinaryOps(tid, tid); - for (int j = 0; j < tid; ++j) { - SWIG_InstallBinaryOps(j, tid); - SWIG_InstallBinaryOps(tid, j); - } - } - -SWIGRUNTIME octave_value SWIG_Octave_NewPointerObj(void *ptr, swig_type_info *type, int flags) { - int own = (flags &SWIG_POINTER_OWN) ? SWIG_POINTER_OWN : 0; - -#ifdef SWIG_DIRECTORS - Swig::Director *d = Swig::get_rtdir(ptr); - if (d && Swig::swig_director_get_self(d)) - return Swig::swig_director_get_self(d)->as_value(); -#endif - return Swig::swig_value_ref(new octave_swig_type(ptr, type, own)); -} - -SWIGRUNTIME int SWIG_Octave_ConvertPtrAndOwn(octave_value ov, void **ptr, swig_type_info *type, int flags, int *own) { - if (ov.is_cell() && ov.rows() == 1 && ov.columns() == 1) - ov = ov.cell_value()(0); - if (!ov.is_defined() || - (ov.is_matrix_type() && ov.rows() == 0 && ov.columns() == 0) ) { - if (ptr) - *ptr = 0; - return SWIG_OK; - } - if (ov.type_id() != octave_swig_ref::static_type_id()) - return SWIG_ERROR; - octave_swig_ref *osr = static_cast < octave_swig_ref *>(ov.internal_rep()); - octave_swig_type *ost = osr->get_ptr(); - void *vptr = ost->cast(type, own, flags); - if (!vptr) - return SWIG_ERROR; - if (ptr) - *ptr = vptr; - return SWIG_OK; -} - -SWIGRUNTIME octave_value SWIG_Octave_NewPackedObj(void *ptr, size_t sz, swig_type_info *type) { - return new octave_swig_packed(type, (char *) ptr, sz); -} - -SWIGRUNTIME int SWIG_Octave_ConvertPacked(const octave_value &ov, void *ptr, size_t sz, swig_type_info *type) { - if (!ov.is_defined()) - return SWIG_ERROR; - if (ov.type_id() != octave_swig_packed::static_type_id()) - return SWIG_ERROR; - octave_swig_packed *ost = static_cast < octave_swig_packed *>(ov.internal_rep()); - return ost->copy(type, (char *) ptr, sz) ? SWIG_OK : SWIG_ERROR; -} - -SWIGRUNTIMEINLINE void SWIG_Octave_SetConstant(octave_swig_type *module_ns, const std::string &name, const octave_value &ov) { - module_ns->assign(name, ov); -} - -SWIGRUNTIMEINLINE octave_value SWIG_Octave_GetGlobalValue(std::string name) { - return get_global_value(name, true); -} - -SWIGRUNTIME void SWIG_Octave_SetGlobalValue(std::string name, const octave_value& value) { - set_global_value(name, value); -} - -SWIGRUNTIME void SWIG_Octave_LinkGlobalValue(std::string name) { -#if !SWIG_OCTAVE_PREREQ(3,2,0) - link_to_global_variable(curr_sym_tab->lookup(name, true)); -#else -#if !SWIG_OCTAVE_PREREQ(3,8,0) - symbol_table::varref(name); -#endif - symbol_table::mark_global(name); -#endif -} - -SWIGRUNTIME swig_module_info *SWIG_Octave_GetModule(void *clientdata) { - octave_value ov = SWIG_Octave_GetGlobalValue("__SWIG_MODULE__" SWIG_TYPE_TABLE_NAME SWIG_RUNTIME_VERSION); - if (!ov.is_defined() || - ov.type_id() != octave_swig_packed::static_type_id()) - return 0; - const octave_swig_packed* osp = - static_cast < const octave_swig_packed *> (ov.internal_rep()); - swig_module_info *pointer = 0; - osp->copy(0, &pointer, sizeof(swig_module_info *)); - return pointer; -} - -SWIGRUNTIME void SWIG_Octave_SetModule(void *clientdata, swig_module_info *pointer) { - octave_value ov = new octave_swig_packed(0, &pointer, sizeof(swig_module_info *)); - SWIG_Octave_SetGlobalValue("__SWIG_MODULE__" SWIG_TYPE_TABLE_NAME SWIG_RUNTIME_VERSION, ov); -} diff --git a/Lib/octave/octrunclass.swg b/Lib/octave/octrunclass.swg new file mode 100644 index 000000000..2310a45b8 --- /dev/null +++ b/Lib/octave/octrunclass.swg @@ -0,0 +1,1203 @@ +// +// octrunclass.swg - Octave runtime classes +// + +////////// Octave class: SwigOctType ////////// + +const SwigOctMember* SwigOctType::find_member(const swig_type_info* type, const std::string& name) +{ + if (!type->clientdata) { + return 0; + } + SwigOctClass* c = (SwigOctClass*) type->clientdata; + const SwigOctMember* m; + for (m = c->members; m->name; ++m) + if (m->name == name) { + return m; + } + for (int j = 0; c->base_names[j]; ++j) { + if (!c->base[j]) { + if (!module) { + module = SWIG_GetModule(0); + } + assert(module); + c->base[j] = SWIG_MangledTypeQueryModule(module, module, c->base_names[j]); + } + if (!c->base[j]) { + return 0; + } + if ((m = find_member(c->base[j], name))) { + return m; + } + } + return 0; +} + +SwigOctType::member_value_pair* SwigOctType::find_member(const std::string& name, bool insert_if_not_found) +{ + member_map::iterator it = members.find(name); + if (it != members.end()) { + return &it->second; + } + const SwigOctMember* m; + for (unsigned int j = 0; j < types.size(); ++j) + if ((m = find_member(types[j].first, name))) { + return &members.insert(std::make_pair(name, std::make_pair(m, octave_value()))).first->second; + } + if (!insert_if_not_found) { + return 0; + } + return &members[name]; +} + +const swig_type_info* SwigOctType::find_base(const std::string& name, const swig_type_info* base) +{ + if (!base) { + for (unsigned int j = 0; j < types.size(); ++j) { + assert(types[j].first->clientdata); + SwigOctClass* cj = (SwigOctClass*) types[j].first->clientdata; + if (cj->name == name) { + return types[j].first; + } + } + return 0; + } + assert(base->clientdata); + SwigOctClass* c = (SwigOctClass*) base->clientdata; + for (int j = 0; c->base_names[j]; ++j) { + if (!c->base[j]) { + if (!module) { + module = SWIG_GetModule(0); + } + assert(module); + c->base[j] = SWIG_MangledTypeQueryModule(module, module, c->base_names[j]); + } + if (!c->base[j]) { + return 0; + } + assert(c->base[j]->clientdata); + SwigOctClass* cj = (SwigOctClass*) c->base[j]->clientdata; + if (cj->name == name) { + return c->base[j]; + } + } + return 0; +} + +void SwigOctType::load_members(const SwigOctClass* c, member_map& out) const +{ + for (const SwigOctMember* m = c->members; m->name; ++m) { + if (out.find(m->name) == out.end()) { + out.insert(std::make_pair(m->name, std::make_pair(m, octave_value()))); + } + } + for (int j = 0; c->base_names[j]; ++j) { + if (!c->base[j]) { + if (!module) { + module = SWIG_GetModule(0); + } + assert(module); + c->base[j] = SWIG_MangledTypeQueryModule(module, module, c->base_names[j]); + } + if (!c->base[j]) { + continue; + } + assert(c->base[j]->clientdata); + const SwigOctClass* cj = + (const SwigOctClass*) c->base[j]->clientdata; + load_members(cj, out); + } +} + +void SwigOctType::load_members(member_map& out) const +{ + out = members; + for (unsigned int j = 0; j < types.size(); ++j) + if (types[j].first->clientdata) { + load_members((const SwigOctClass*) types[j].first->clientdata, out); + } +} + +octave_value_list SwigOctType::member_invoke(member_value_pair* m, const octave_value_list& args, int nargout) +{ + if (m->second.is_defined()) { + return m->second.subsref("(", std::list < octave_value_list > (1, args), nargout); + } else if (m->first && m->first->method) { + return m->first->method(args, nargout); + } + error("member not defined or not invocable"); + return octave_value_list(); +} + +bool SwigOctType::dispatch_unary_op(const std::string& symbol, octave_value& ret) +{ + member_value_pair* m = find_member(symbol, false); + if (!m || m->first->is_static() || m->first->is_global()) { + return false; + } + octave_value_list args; + args.append(as_value()); + octave_value_list argout(member_invoke(m, args, 1)); + if (argout.length() < 1) { + return false; + } + ret = argout(0); + return true; +} + +bool SwigOctType::dispatch_binary_op(const std::string& symbol, const octave_base_value& rhs, octave_value& ret) +{ + member_value_pair* m = find_member(symbol, false); + if (!m || m->first->is_static() || m->first->is_global()) { + return false; + } + octave_value_list args; + args.append(as_value()); + args.append(make_value_hack(rhs)); + octave_value_list argout(member_invoke(m, args, 1)); + if (argout.length() < 1) { + return false; + } + ret = argout(0); + return true; +} + +bool SwigOctType::dispatch_index_op(const std::string& symbol, const octave_value_list& rhs, octave_value_list& ret) +{ + member_value_pair* m = find_member(symbol, false); + if (!m || m->first->is_static() || m->first->is_global()) { + return false; + } + octave_value_list args; + args.append(as_value()); + args.append(rhs); + octave_value_list argout(member_invoke(m, args, 1)); + if (argout.length() >= 1) { + ret = argout(0); + } + return true; +} + +octave_value_list SwigOctType::member_deref(member_value_pair* m, const octave_value_list& args) +{ + if (m->second.is_defined()) { + return m->second; + } else if (m->first) { + if (m->first->get_method) { + return m->first->get_method(args, 1); + } else if (m->first->method) { + return octave_value(new octave_builtin(m->first->method)); + } + } + error("undefined member"); + return octave_value_list(); +} + +octave_value SwigOctType::make_value_hack(const octave_base_value& x) +{ + ((SwigOctType&) x).count++; + return octave_value((octave_base_value*) &x); +} + +SwigOctType::SwigOctType(void* _ptr, const swig_type_info* _type, int _own, bool _always_static) + : module(0), construct_type(_ptr ? 0 : _type), own(_own), always_static(_always_static) +{ + if (_type || _ptr) { + types.push_back(std::make_pair(_type, _ptr)); + } +#ifdef SWIG_DIRECTORS + if (_ptr) { + Swig::Director* d = Swig::get_rtdir(_ptr); + if (d) { + Swig::swig_director_set_self(d, this); + } + } +#endif +} + +SwigOctType::~SwigOctType() +{ + if (own) { + ++count; + for (unsigned int j = 0; j < types.size(); ++j) { + if (!types[j].first || !types[j].first->clientdata) { + continue; + } + SwigOctClass* c = (SwigOctClass*) types[j].first->clientdata; + if (c->destructor && !types[j].second.destroyed && types[j].second.ptr) { + c->destructor(as_value(), 0); + } + } + } +#ifdef SWIG_DIRECTORS + for (unsigned int j = 0; j < types.size(); ++j) { + Swig::erase_rtdir(types[j].second.ptr); + } +#endif +} + +dim_vector SwigOctType::dims(void) const +{ + SwigOctType* nc_this = const_cast < SwigOctType*>(this); + + // Find the __dims__ method of this object + member_value_pair* m = nc_this->find_member("__dims__", false); + + if (!m) { + return dim_vector(1, 1); + } + + // Call the __dims__ method of this object + octave_value_list inarg; + inarg.append(nc_this->as_value()); + octave_value_list outarg = nc_this->member_invoke(m, inarg, 1); + + // __dims__ should return (at least) one output argument + if (outarg.length() < 1) { + return dim_vector(1, 1); + } + + octave_value& out = outarg(0); + + // Return value should be cell or matrix of integers + if (out.is_cell()) { + const Cell& c = out.cell_value(); + int ndim = c.rows(); + if (ndim == 1 && c.columns() != 1) { + ndim = c.columns(); + } + + dim_vector d; + d.resize(ndim < 2 ? 2 : ndim); + d(0) = d(1) = 1; + + // Fill in dim_vector + for (int k = 0; k < ndim; k++) { + const octave_value& obj = c(k); + d.elem(k) = obj.int_value(); + + // __dims__ should return a cell filled with integers + if (error_state) { + return dim_vector(1, 1); + } + } + return d; + } else if (out.is_matrix_type() || out.is_numeric_type()) { + if (out.rows() == 1 || out.columns() == 1) { + Array a = out.int_vector_value(); + if (error_state) { + return dim_vector(1, 1); + } + dim_vector d; + d.resize(a.numel() < 2 ? 2 : a.numel()); + d(0) = d(1) = 1; + for (int k = 0; k < a.numel(); k++) { + d.elem(k) = a(k); + } + return d; + } else { + return dim_vector(1, 1); + } + } else { + return dim_vector(1, 1); + } +} + +octave_value SwigOctType::as_value() +{ + ++count; + return SWIG_Octave_ValueRef(this); +} + +void SwigOctType::incref() +{ + ++count; +} + +void SwigOctType::decref() +{ + if (!--count) { + delete this; + } +} + +long SwigOctType::swig_this() const +{ + if (!types.size()) { + return (long) this; + } + return (long) types[0].second.ptr; +} + +const char* SwigOctType::help_text() const +{ + if (!types.size()) { + return 0; + } + if (!types[0].first->clientdata) { + return 0; + } + SwigOctClass* c = (SwigOctClass*) types[0].first->clientdata; + return c->constructor_doc; +} + +std::string SwigOctType::swig_type_name() const +{ + // * need some way to manually name subclasses. + // * eg optional first arg to subclass(), or named_subclass() + std::string ret; + for (unsigned int j = 0; j < types.size(); ++j) { + if (j) { + ret += "_"; + } + if (types[j].first->clientdata) { + SwigOctClass* c = (SwigOctClass*) types[j].first->clientdata; + ret += c->name; + } else { + ret += types[j].first->name; + } + } + return ret; +} + +void SwigOctType::merge(SwigOctType& rhs) +{ + rhs.own = 0; + for (unsigned int j = 0; j < rhs.types.size(); ++j) { + assert(!rhs.types[j].second.destroyed); +#ifdef SWIG_DIRECTORS + Swig::Director* d = Swig::get_rtdir(rhs.types[j].second.ptr); + if (d) { + Swig::swig_director_set_self(d, this); + } +#endif + } + types.insert(types.end(), rhs.types.begin(), rhs.types.end()); + members.insert(rhs.members.begin(), rhs.members.end()); + rhs.types.clear(); + rhs.members.clear(); +} + +SwigOctType::swig_member_const_iterator SwigOctType::swig_members_begin() +{ + return members.begin(); +} + +SwigOctType::swig_member_const_iterator SwigOctType::swig_members_end() +{ + return members.end(); +} + +void* SwigOctType::cast(swig_type_info* type, int* _own, int flags) +{ + if (_own) { + *_own = own; + } + if (flags & SWIG_POINTER_DISOWN) { + own = 0; + } + if (!type && types.size()) { + return types[0].second.ptr; + } + for (unsigned int j = 0; j < types.size(); ++j) + if (type == types[j].first) { + return types[j].second.ptr; + } + for (unsigned int j = 0; j < types.size(); ++j) { + swig_cast_info* tc = SWIG_TypeCheck(types[j].first->name, type); + if (!tc) { + continue; + } + int newmemory = 0; + void* vptr = SWIG_TypeCast(tc, types[j].second.ptr, &newmemory); + assert(!newmemory); // newmemory handling not yet implemented + return vptr; + } + return 0; +} + +bool SwigOctType::is_owned() const +{ + return own; +} + +#ifdef SWIG_DIRECTORS +void SwigOctType::director_destroyed(Swig::Director* d) +{ + bool found = false; + for (unsigned int j = 0; j < types.size(); ++j) { + Swig::Director* dj = Swig::get_rtdir(types[j].second.ptr); + if (dj == d) { + types[j].second.destroyed = true; + found = true; + } + } + assert(found); +} +#endif + +void SwigOctType::assign(const std::string& name, const octave_value& ov) +{ + members[name] = std::make_pair((const SwigOctMember*) 0, ov); +} + +void SwigOctType::assign(const std::string& name, const SwigOctMember* m) +{ + members[name] = std::make_pair(m, octave_value()); +} + +octave_base_value* SwigOctType::clone() const +{ + // pass-by-value is probably not desired, and is harder; + // requires calling copy constructors of contained types etc. + assert(0); + * (int*) 0 = 0; + return 0; +} + +octave_base_value* SwigOctType::empty_clone() const +{ + return new SwigOctType(); +} + +bool SwigOctType::is_defined() const +{ + return true; +} + +bool SwigOctType::is_map() const +{ + return true; +} + +octave_value SwigOctType::subsref(const std::string& ops, const std::list < octave_value_list > &idx) +{ + octave_value_list ovl = subsref(ops, idx, 1); + return ovl.length() ? ovl(0) : octave_value(); +} + +octave_value_list SwigOctType::subsref(const std::string& ops, const std::list < octave_value_list > &idx, int nargout) +{ + assert(ops.size() > 0); + assert(ops.size() == idx.size()); + + std::list < octave_value_list >::const_iterator idx_it = idx.begin(); + int skip = 0; + octave_value_list sub_ovl; + + // constructor invocation + if (ops[skip] == '(' && construct_type) { + assert(construct_type->clientdata); + SwigOctClass* c = (SwigOctClass*) construct_type->clientdata; + if (!c->constructor) { + error("cannot create instance"); + return octave_value_list(); + } + octave_value_list args; + if (c->director) { + args.append(SWIG_Octave_ValueRef(new SwigOctType(this, 0, 0))); + } + args.append(*idx_it++); + ++skip; + sub_ovl = c->constructor(args, nargout); + } + // member dereference or invocation + else if (ops[skip] == '.') { + std::string subname; + const swig_type_info* base = 0; // eg, a.base.base_cpp_mem + for (;;) { + octave_value_list subname_ovl(*idx_it++); + ++skip; + assert(subname_ovl.length() == 1 && subname_ovl(0).is_string()); + subname = subname_ovl(0).string_value(); + + const swig_type_info* next_base = find_base(subname, base); + if (!next_base || skip >= (int) ops.size() || ops[skip] != '.') { + break; + } + base = next_base; + } + + member_value_pair tmp, *m = &tmp; + if (!base || !(m->first = find_member(base, subname))) { + m = find_member(subname, false); + } + if (!m) { + error("member not found"); + return octave_value_list(); + } + + octave_value_list args; + if (!always_static && + (!m->first || (!m->first->is_static() && !m->first->is_global()))) { + args.append(as_value()); + } + if (skip < (int) ops.size() && ops[skip] == '(' && + ((m->first && m->first->method) || m->second.is_function() || + m->second.is_function_handle())) { + args.append(*idx_it++); + ++skip; + sub_ovl = member_invoke(m, args, nargout); + } else { + sub_ovl = member_deref(m, args); + } + } + // index operator + else { + if (ops[skip] == '(' || ops[skip] == '{') { + const char* op_name = ops[skip] == '(' ? "__paren__" : "__brace__"; + octave_value_list args; + args.append(*idx_it++); + ++skip; + if (!dispatch_index_op(op_name, args, sub_ovl)) { + error("error evaluating index operator"); + return octave_value_list(); + } + } else { + error("unsupported subsref"); + return octave_value_list(); + } + } + + if (skip >= (int) ops.size()) { + return sub_ovl; + } + if (sub_ovl.length() < 1) { + error("bad subs ref"); + return octave_value_list(); + } + return sub_ovl(0).next_subsref(nargout, ops, idx, skip); +} + +octave_value SwigOctType::subsasgn(const std::string& ops, const std::list < octave_value_list > &idx, const octave_value& rhs) +{ + assert(ops.size() > 0); + assert(ops.size() == idx.size()); + + std::list < octave_value_list >::const_iterator idx_it = idx.begin(); + int skip = 0; + + if (ops.size() > 1) { + std::list < octave_value_list >::const_iterator last = idx.end(); + --last; + std::list < octave_value_list > next_idx(idx.begin(), last); + octave_value next_ov = subsref(ops.substr(0, ops.size() - 1), next_idx); + next_ov.subsasgn(ops.substr(ops.size() - 1), std::list < octave_value_list > (1, *last), rhs); + } + + else if (ops[skip] == '(' || ops[skip] == '{') { + const char* op_name = ops[skip] == '(' ? "__paren_asgn__" : "__brace_asgn__"; + member_value_pair* m = find_member(op_name, false); + if (m) { + octave_value_list args; + args.append(as_value()); + args.append(*idx_it); + args.append(rhs); + member_invoke(m, args, 1); + } else { + error("%s member not found", op_name); + } + } + + else if (ops[skip] == '.') { + octave_value_list subname_ovl(*idx_it++); + ++skip; + assert(subname_ovl.length() == 1 && subname_ovl(0).is_string()); + std::string subname = subname_ovl(0).string_value(); + + member_value_pair* m = find_member(subname, true); + if (!m->first || !m->first->set_method) { + m->first = 0; + m->second = rhs; + } else if (m->first->set_method) { + octave_value_list args; + if (!m->first->is_static() && !m->first->is_global()) { + args.append(as_value()); + } + args.append(rhs); + m->first->set_method(args, 1); + } else { + error("member not assignable"); + } + } else { + error("unsupported subsasgn"); + } + + return as_value(); +} + +bool SwigOctType::is_object() const +{ + return true; +} + +bool SwigOctType::is_string() const +{ + SwigOctType* nc_this = const_cast < SwigOctType*>(this); + return !!nc_this->find_member("__str__", false); +} + +std::string SwigOctType::string_value(bool force) const +{ + SwigOctType* nc_this = const_cast < SwigOctType*>(this); + member_value_pair* m = nc_this->find_member("__str__", false); + if (!m) { + error("__str__ method not defined"); + return std::string(); + } + octave_value_list outarg = nc_this->member_invoke(m, octave_value_list(nc_this->as_value()), 1); + if (outarg.length() < 1 || !outarg(0).is_string()) { + error("__str__ method did not return a string"); + return std::string(); + } + return outarg(0).string_value(); +} + +octave_map SwigOctType::map_value() const +{ + return octave_map(); +} + +string_vector SwigOctType::map_keys() const +{ + member_map tmp; + load_members(tmp); + + string_vector keys(tmp.size()); + int k = 0; + for (member_map::iterator it = tmp.begin(); it != tmp.end(); ++it) { + keys(k++) = it->first; + } + + return keys; +} + +bool SwigOctType::save_ascii(std::ostream& os) +{ + return true; +} + +bool SwigOctType::load_ascii(std::istream& is) +{ + return true; +} + +bool SwigOctType::save_binary(std::ostream& os, bool& save_as_floats) +{ + return true; +} + +bool SwigOctType::load_binary(std::istream& is, bool swap, oct_mach_info::float_format fmt) +{ + return true; +} + +#ifdef HAVE_HDF5 +bool SwigOctType::save_hdf5(hid_t loc_id, const char* name, bool save_as_floats) +{ + return true; +} + +bool SwigOctType::load_hdf5(hid_t loc_id, const char* name, bool have_h5giterate_bug) +{ + return true; +} +#endif + +octave_value SwigOctType::convert_to_str(bool pad, bool force, char type) const +{ + return string_value(); +} + +octave_value SwigOctType::convert_to_str_internal(bool pad, bool force, char type) const +{ + return string_value(); +} + +bool SwigOctType::dispatch_global_op(const std::string& symbol, const octave_value_list& args, octave_value& ret) +{ + // we assume that SWIG_op_prefix-prefixed functions are installed in global namespace + // (rather than any module namespace). + + octave_function* fcn = is_valid_function(symbol, std::string(), false); + if (!fcn) { + return false; + } + ret = fcn->do_multi_index_op(1, args)(0); + return true; +} + +octave_value SwigOctType::dispatch_unary_op(const octave_base_value& x, const char* op_name) +{ + SwigOctType* ost = SWIG_Octave_ValueDeref(x); + assert(ost); + + octave_value ret; + if (ost->dispatch_unary_op(std::string("__") + op_name + std::string("__"), ret)) { + return ret; + } + std::string symbol = SWIG_op_prefix + ost->swig_type_name() + "_" + op_name; + octave_value_list args; + args.append(make_value_hack(x)); + if (dispatch_global_op(symbol, args, ret)) { + return ret; + } + + error("could not dispatch unary operator"); + return octave_value(); +} + +octave_value SwigOctType::dispatch_binary_op(const octave_base_value& lhs, const octave_base_value& rhs, const char* op_name) +{ + SwigOctType* lhs_ost = SWIG_Octave_ValueDeref(lhs); + SwigOctType* rhs_ost = SWIG_Octave_ValueDeref(rhs); + + octave_value ret; + if (lhs_ost && lhs_ost->dispatch_binary_op(std::string("__") + op_name + std::string("__"), rhs, ret)) { + return ret; + } + if (rhs_ost) { + if (strlen(op_name) == 2 && (op_name[1] == 't' || op_name[1] == 'e')) { + if (op_name[0] == 'l' && rhs_ost->dispatch_binary_op(std::string("__g") + op_name[1] + std::string("__"), lhs, ret)) { + return ret; + } + if (op_name[0] == 'g' && rhs_ost->dispatch_binary_op(std::string("__l") + op_name[1] + std::string("__"), lhs, ret)) { + return ret; + } + } + if (rhs_ost->dispatch_binary_op(std::string("__r") + op_name + std::string("__"), lhs, ret)) { + return ret; + } + } + + std::string symbol; + octave_value_list args; + args.append(make_value_hack(lhs)); + args.append(make_value_hack(rhs)); + + symbol = SWIG_op_prefix; + symbol += lhs_ost ? lhs_ost->swig_type_name() : lhs.type_name(); + symbol += "_"; + symbol += op_name; + symbol += "_"; + symbol += rhs_ost ? rhs_ost->swig_type_name() : rhs.type_name(); + if (dispatch_global_op(symbol, args, ret)) { + return ret; + } + + symbol = SWIG_op_prefix; + symbol += lhs_ost ? lhs_ost->swig_type_name() : lhs.type_name(); + symbol += "_"; + symbol += op_name; + symbol += "_"; + symbol += "any"; + if (dispatch_global_op(symbol, args, ret)) { + return ret; + } + + symbol = SWIG_op_prefix; + symbol += "any"; + symbol += "_"; + symbol += op_name; + symbol += "_"; + symbol += rhs_ost ? rhs_ost->swig_type_name() : rhs.type_name(); + if (dispatch_global_op(symbol, args, ret)) { + return ret; + } + + error("could not dispatch binary operator"); + return octave_value(); +} + +void SwigOctType::print(std::ostream& os, bool pr_as_read_syntax) const +{ + if (is_string()) { + os << string_value(); + return; + } + + member_map tmp; + load_members(tmp); + + indent(os); + os << "{"; + newline(os); + increment_indent_level(); + for (unsigned int j = 0; j < types.size(); ++j) { + indent(os); + if (types[j].first->clientdata) { + const SwigOctClass* c = (const SwigOctClass*) types[j].first->clientdata; + os << c->name << ", ptr = " << types[j].second.ptr; + newline(os); + } else { + os << types[j].first->name << ", ptr = " << types[j].second.ptr; + newline(os); + } + } + for (member_map::const_iterator it = tmp.begin(); it != tmp.end(); ++it) { + indent(os); + if (it->second.first) { + const char* objtype = it->second.first->method ? "method" : "variable"; + const char* modifier = (it->second.first->flags & 1) ? "static " : (it->second.first->flags & 2) ? "global " : ""; + os << it->second.first->name << " (" << modifier << objtype << ")"; + newline(os); + assert(it->second.first->name == it->first); + } else { + os << it->first; + newline(os); + } + } + decrement_indent_level(); + indent(os); + os << "}"; + newline(os); +} + +////////// Octave class: SwigOctRef ////////// + +DEFINE_OCTAVE_ALLOCATOR(SwigOctRef); +DEFINE_OV_TYPEID_FUNCTIONS_AND_DATA(SwigOctRef, "swig_ref", "swig_ref"); + +SwigOctRef::SwigOctRef(SwigOctType* _ptr) + : ptr(_ptr) +{ } + +SwigOctRef::~SwigOctRef() +{ + if (ptr) { + ptr->decref(); + } +} + +SwigOctType* SwigOctRef::get_ptr() const +{ + return ptr; +} + +octave_base_value* SwigOctRef::clone() const +{ + if (ptr) { + ptr->incref(); + } + return new SwigOctRef(ptr); +} + +octave_base_value* SwigOctRef::empty_clone() const +{ + return new SwigOctRef(0); +} + +dim_vector SwigOctRef::dims(void) const +{ + return ptr->dims(); +} + +bool SwigOctRef::is_defined() const +{ + return ptr->is_defined(); +} + +bool SwigOctRef::is_map() const +{ + return ptr->is_map(); +} + +octave_value SwigOctRef::subsref(const std::string& ops, const std::list < octave_value_list > &idx) +{ + return ptr->subsref(ops, idx); +} + +octave_value_list SwigOctRef::subsref(const std::string& ops, const std::list < octave_value_list > &idx, int nargout) +{ + return ptr->subsref(ops, idx, nargout); +} + +octave_value SwigOctRef::subsasgn(const std::string& ops, const std::list < octave_value_list > &idx, const octave_value& rhs) +{ + return ptr->subsasgn(ops, idx, rhs); +} + +bool SwigOctRef::is_object() const +{ + return ptr->is_object(); +} + +bool SwigOctRef::is_string() const +{ + return ptr->is_string(); +} + +std::string SwigOctRef::string_value(bool force) const +{ + return ptr->string_value(force); +} + +octave_map SwigOctRef::map_value() const +{ + return ptr->map_value(); +} + +string_vector SwigOctRef::map_keys() const +{ + return ptr->map_keys(); +} + +bool SwigOctRef::save_ascii(std::ostream& os) +{ + return ptr->save_ascii(os); +} + +bool SwigOctRef::load_ascii(std::istream& is) +{ + return ptr->load_ascii(is); +} + +bool SwigOctRef::save_binary(std::ostream& os, bool& save_as_floats) +{ + return ptr->save_binary(os, save_as_floats); +} + +bool SwigOctRef::load_binary(std::istream& is, bool swap, oct_mach_info::float_format fmt) +{ + return ptr->load_binary(is, swap, fmt); +} + +#ifdef HAVE_HDF5 +bool SwigOctRef::save_hdf5(hid_t loc_id, const char* name, bool save_as_floats) +{ + return ptr->save_hdf5(loc_id, name, save_as_floats); +} + +bool SwigOctRef::load_hdf5(hid_t loc_id, const char* name, bool have_h5giterate_bug) +{ + return ptr->load_hdf5(loc_id, name, have_h5giterate_bug); +} +#endif + +octave_value SwigOctRef::convert_to_str(bool pad, bool force, char type) const +{ + return ptr->convert_to_str(pad, force, type); +} + +octave_value SwigOctRef::convert_to_str_internal(bool pad, bool force, char type) const +{ + return ptr->convert_to_str_internal(pad, force, type); +} + +void SwigOctRef::print(std::ostream& os, bool pr_as_read_syntax) const +{ + return ptr->print(os, pr_as_read_syntax); +} + +////////// Octave class: SwigOctPacked ////////// + +DEFINE_OCTAVE_ALLOCATOR(SwigOctPacked); +DEFINE_OV_TYPEID_FUNCTIONS_AND_DATA(SwigOctPacked, "swig_packed", "swig_packed"); + +SwigOctPacked::SwigOctPacked(swig_type_info* _type, const void* _buf, size_t _buf_len) + : type(_type), buf((const char*) _buf, (const char*) _buf + _buf_len) +{ } + +bool SwigOctPacked::copy(swig_type_info* outtype, void* ptr, size_t sz) const +{ + if (outtype && outtype != type) { + return false; + } + assert(sz <= buf.size()); + std::copy(buf.begin(), buf.begin() + sz, (char*) ptr); + return true; +} + +octave_base_value* SwigOctPacked::clone() const +{ + return new SwigOctPacked(*this); +} + +octave_base_value* SwigOctPacked::empty_clone() const +{ + return new SwigOctPacked(); +} + +bool SwigOctPacked::is_defined() const +{ + return true; +} + +void SwigOctPacked::print(std::ostream& os, bool pr_as_read_syntax) const +{ + indent(os); + os << "swig packed type: name = " << (type ? type->name : std::string()) << ", len = " << buf.size(); + newline(os); +} + +bool SwigOctPacked::save_ascii(std::ostream& os) +{ + return true; +} + +bool SwigOctPacked::load_ascii(std::istream& is) +{ + return true; +} + +bool SwigOctPacked::save_binary(std::ostream& os, bool& save_as_floats) +{ + return true; +} + +bool SwigOctPacked::load_binary(std::istream& is, bool swap, oct_mach_info::float_format fmt) +{ + return true; +} + +#ifdef HAVE_HDF5 +bool SwigOctPacked::save_hdf5(hid_t loc_id, const char* name, bool save_as_floats) +{ + return true; +} + +bool SwigOctPacked::load_hdf5(hid_t loc_id, const char* name, bool have_h5giterate_bug) +{ + return true; +} +#endif + +////////// Octave class: Swig::Director and related classes ////////// + +#ifdef SWIG_DIRECTORS + +#include + +Swig::Director::Director(void* vptr) : self(0), swig_disowned(false) +{ + set_rtdir(vptr, this); +} + +Swig::Director::~Director() +{ + swig_director_destroyed(self, this); + if (swig_disowned) { + self->decref(); + } +} + +void Swig::Director::swig_set_self(SwigOctType* new_self) +{ + assert(!swig_disowned); + self = new_self; +} + +SwigOctType* Swig::Director::swig_get_self() const +{ + return self; +} + +void Swig::Director::swig_disown() +{ + if (swig_disowned) { + return; + } + swig_disowned = true; + self->incref(); +} + +void Swig::DirectorTypeMismatchException::raise(const char* msg) +{ + // ... todo + throw(DirectorTypeMismatchException()); +} + +void Swig::DirectorTypeMismatchException::raise(const octave_value& ov, const char* msg) +{ + // ... todo + raise(msg); +} + +void Swig::DirectorPureVirtualException::raise(const char* msg) +{ + // ... todo + throw(DirectorPureVirtualException()); +} + +void Swig::DirectorPureVirtualException::raise(const octave_value& ov, const char* msg) +{ + // ... todo + raise(msg); +} + +SWIGOCTRT Swig::rtdir_map* Swig::get_rtdir_map() +{ + static swig_module_info* module = 0; + if (!module) { + module = SWIG_GetModule(0); + } + if (!module) { + return 0; + } + if (!module->clientdata) { + module->clientdata = new rtdir_map; + } + return (rtdir_map*) module->clientdata; +} + +SWIGOCTRTINLINE void Swig::set_rtdir(void* vptr, Director* d) +{ + rtdir_map* rm = get_rtdir_map(); + if (rm) { + (*rm) [vptr] = d; + } +} + +SWIGOCTRTINLINE void Swig::erase_rtdir(void* vptr) +{ + rtdir_map* rm = get_rtdir_map(); + if (rm) { + (*rm).erase(vptr); + } +} + +SWIGOCTRTINLINE Swig::Director* Swig::get_rtdir(void* vptr) +{ + rtdir_map* rm = get_rtdir_map(); + if (!rm) { + return 0; + } + rtdir_map::const_iterator pos = rm->find(vptr); + Director* rtdir = (pos != rm->end()) ? pos->second : 0; + return rtdir; +} + +SWIGOCTRT void Swig::swig_director_destroyed(SwigOctType* self, Director* d) +{ + self->director_destroyed(d); +} + +SWIGOCTRT SwigOctType* Swig::swig_director_get_self(Director* d) +{ + return d->swig_get_self(); +} + +SWIGOCTRT void Swig::swig_director_set_self(Director* d, SwigOctType* self) +{ + d->swig_set_self(self); +} + +SWIGOCTRT void swig_acquire_ownership(void* vptr) +{ + // assert(0); + // ... todo +} + +SWIGOCTRT void swig_acquire_ownership_array(void* vptr) +{ + // assert(0); + // ... todo +} + +SWIGOCTRT void swig_acquire_ownership_obj(void* vptr, int own) +{ + // assert(0); + // ... todo +} + +#endif // SWIG_DIRECTORS diff --git a/Lib/octave/octrundecl.swg b/Lib/octave/octrundecl.swg new file mode 100644 index 000000000..f71895abb --- /dev/null +++ b/Lib/octave/octrundecl.swg @@ -0,0 +1,479 @@ +// +// octrundecl.swg - Declarations of Octave runtime code +// + +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include + +////////// Determine Octave version ////////// + +// Macro for enabling features which require Octave version >= major.minor.patch +#define SWIG_OCTAVE_PREREQ(major, minor, patch) \ + ( (OCTAVE_MAJOR_VERSION<<16) + (OCTAVE_MINOR_VERSION<<8) + OCTAVE_PATCH_VERSION >= ((major)<<16) + ((minor)<<8) + (patch) ) + +// Reconstruct Octave major, minor, and patch versions for releases prior to 3.8.1 +#if !defined(OCTAVE_MAJOR_VERSION) + +# if !defined(OCTAVE_API_VERSION_NUMBER) + +// Hack to distinguish between Octave 3.8.0, which removed OCTAVE_API_VERSION_NUMBER but did not yet +// introduce OCTAVE_MAJOR_VERSION, and Octave <= 3.2, which did not define OCTAVE_API_VERSION_NUMBER +# include +# if defined(octave_ov_h) +# define OCTAVE_MAJOR_VERSION 3 +# define OCTAVE_MINOR_VERSION 8 +# define OCTAVE_PATCH_VERSION 0 +# else + +// Hack to distinguish between Octave 3.2 and earlier versions, before OCTAVE_API_VERSION_NUMBER existed +# define ComplexLU __ignore +# include +# undef ComplexLU +# if defined(octave_Complex_LU_h) + +// We know only that this version is prior to Octave 3.2, i.e. OCTAVE_API_VERSION_NUMBER < 37 +# define OCTAVE_MAJOR_VERSION 3 +# define OCTAVE_MINOR_VERSION 1 +# define OCTAVE_PATCH_VERSION 99 + +# else + +// OCTAVE_API_VERSION_NUMBER == 37 +# define OCTAVE_MAJOR_VERSION 3 +# define OCTAVE_MINOR_VERSION 2 +# define OCTAVE_PATCH_VERSION 0 + +# endif // defined(octave_Complex_LU_h) + +# endif // defined(octave_ov_h) + +// Correlation between Octave API and version numbers extracted from Octave's +// ChangeLogs; version is the *earliest* released Octave with that API number +# elif OCTAVE_API_VERSION_NUMBER >= 48 +# define OCTAVE_MAJOR_VERSION 3 +# define OCTAVE_MINOR_VERSION 6 +# define OCTAVE_PATCH_VERSION 0 + +# elif OCTAVE_API_VERSION_NUMBER >= 45 +# define OCTAVE_MAJOR_VERSION 3 +# define OCTAVE_MINOR_VERSION 4 +# define OCTAVE_PATCH_VERSION 1 + +# elif OCTAVE_API_VERSION_NUMBER >= 42 +# define OCTAVE_MAJOR_VERSION 3 +# define OCTAVE_MINOR_VERSION 3 +# define OCTAVE_PATCH_VERSION 54 + +# elif OCTAVE_API_VERSION_NUMBER >= 41 +# define OCTAVE_MAJOR_VERSION 3 +# define OCTAVE_MINOR_VERSION 3 +# define OCTAVE_PATCH_VERSION 53 + +# elif OCTAVE_API_VERSION_NUMBER >= 40 +# define OCTAVE_MAJOR_VERSION 3 +# define OCTAVE_MINOR_VERSION 3 +# define OCTAVE_PATCH_VERSION 52 + +# elif OCTAVE_API_VERSION_NUMBER >= 39 +# define OCTAVE_MAJOR_VERSION 3 +# define OCTAVE_MINOR_VERSION 3 +# define OCTAVE_PATCH_VERSION 51 + +# else // OCTAVE_API_VERSION_NUMBER == 38 +# define OCTAVE_MAJOR_VERSION 3 +# define OCTAVE_MINOR_VERSION 3 +# define OCTAVE_PATCH_VERSION 50 + +# endif // !defined(OCTAVE_API_VERSION_NUMBER) + +#endif // !defined(OCTAVE_MAJOR_VERSION) + +// Octave_map was renamed to octave_map in v3.3.52 +#if !SWIG_OCTAVE_PREREQ(3,3,52) +#define octave_map Octave_map +#endif + +////////// Declare/define SWIG interface function loadable by Octave ////////// + +#if !SWIG_OCTAVE_PREREQ(3,2,0) +#define SWIG_DEFUN(cname, wname, doc) DEFUNX_DLD(#cname, wname, FS ## cname, args, nargout, doc) +#else +#define SWIG_DEFUN(cname, wname, doc) DEFUNX_DLD(#cname, wname, G ## cname, args, nargout, doc) +#endif + +////////// Define visibility of Octave runtime functions ////////// + +#define SWIGOCTRT SWIGRUNTIME +#define SWIGOCTRTINLINE SWIGOCTRT SWIGINLINE + +////////// Octave implementations of SWIG runtime functions ////////// + +#define SWIG_fail goto fail +#define swig_owntype int +#define SWIG_MODULE_CLIENTDATA_TYPE void* + +#define SWIG_ConvertFunctionPtr(obj, pptr, type) SWIG_ConvertPtr(obj, pptr, type, 0) +#define SWIG_ConvertMember(obj, ptr, sz, ty) SWIG_Octave_ConvertPacked(obj, ptr, sz, ty) +#define SWIG_ConvertPacked(obj, ptr, sz, ty) SWIG_Octave_ConvertPacked(obj, ptr, sz, ty) +#define SWIG_ConvertPtr(obj, pptr, type, flags) SWIG_Octave_ConvertPtr(obj, pptr, type, flags) +#define SWIG_ConvertPtr(obj, pptr, type, flags) SWIG_Octave_ConvertPtr(obj, pptr, type, flags) +#define SWIG_ConvertPtrAndOwn(obj,pptr,type,flags,own) SWIG_Octave_ConvertPtrAndOwn(obj, pptr, type, flags, own) +#define SWIG_GetModule(clientdata) SWIG_Octave_GetModule(clientdata) +#define SWIG_NewFunctionPtrObj(ptr, type) SWIG_NewPointerObj(ptr, type, 0) +#define SWIG_NewMemberObj(ptr, sz, type) SWIG_Octave_NewPackedObj(ptr, sz, type) +#define SWIG_NewPackedObj(ptr, sz, type) SWIG_Octave_NewPackedObj(ptr, sz, type) +#define SWIG_NewPointerObj(ptr, type, flags) SWIG_Octave_NewPointerObj(ptr, type, flags) +#define SWIG_Octave_AddErrorMsg(msg) {;} +#define SWIG_Octave_ConvertPtr(obj, pptr, type, flags) SWIG_Octave_ConvertPtrAndOwn(obj, pptr, type, flags, 0) +#define SWIG_Octave_ErrorOccurred() 0 +#define SWIG_SetModule(clientdata, pointer) SWIG_Octave_SetModule(clientdata,pointer); + +#define SWIG_DIRECTOR_CAST(ARG) dynamic_cast(ARG) + +// For backward compatibility only +#define SWIG_POINTER_EXCEPTION 0 +#define SWIG_arg_fail(arg) 0 + +////////// Forward declarations of Octave runtime classes and types ////////// + +class SwigOctPacked; +class SwigOctRef; +class SwigOctType; +struct SwigOctClass; +struct SwigOctMember; +struct SwigOctValueRef; +typedef octave_value_list(*SwigOctFuncPtr)(const octave_value_list&, int); + +#ifdef SWIG_DIRECTORS +namespace Swig +{ + class Director; + typedef std::map < void* , Director* > rtdir_map; +} +#endif + +////////// Declarations of Octave runtime functions ////////// + +SWIGOCTRT octave_value SWIG_Error(int code, const char* msg); +SWIGOCTRT octave_value SWIG_ErrorType(int code); +SWIGOCTRT octave_value_list* SWIG_Octave_AppendOutput(octave_value_list* ovl, const octave_value& ov); +SWIGOCTRT bool SWIG_Octave_CheckNumArgs(const char* func_name, int num_args, int max_args, int min_args, int varargs); +SWIGOCTRT int SWIG_Octave_ConvertPacked(const octave_value& ov, void* ptr, size_t sz, swig_type_info* type); +SWIGOCTRT int SWIG_Octave_ConvertPtrAndOwn(octave_value ov, void** ptr, swig_type_info* type, int flags, int* own); +SWIGOCTRTINLINE octave_value SWIG_Octave_GetGlobalValue(std::string name); +SWIGOCTRT swig_module_info* SWIG_Octave_GetModule(void* clientdata); +SWIGOCTRT swig_module_info* SWIG_Octave_GetModule(void* clientdata); +SWIGOCTRT void SWIG_Octave_LinkGlobalValue(std::string name); +SWIGOCTRT octave_value SWIG_Octave_NewPackedObj(void* ptr, size_t sz, swig_type_info* type); +SWIGOCTRT octave_value SWIG_Octave_NewPointerObj(void* ptr, swig_type_info* type, int flags); +SWIGOCTRTINLINE void SWIG_Octave_SetConstant(SwigOctType* module_ns, const std::string& name, const octave_value& ov); +SWIGOCTRT void SWIG_Octave_SetGlobalValue(std::string name, const octave_value& value); +SWIGOCTRT octave_value_list SWIG_Octave_SetImmutable(const octave_value_list& args, int nargout); +SWIGOCTRT void SWIG_Octave_SetModule(void* clientdata, swig_module_info* pointer); +SWIGOCTRT void SWIG_Octave_SetModule(void* clientdata, swig_module_info* pointer); +SWIGOCTRT SwigOctType* SWIG_Octave_ValueDeref(const octave_base_value& ov); +SWIGOCTRT SwigOctType* SWIG_Octave_ValueDeref(octave_value ov); +SWIGOCTRT octave_base_value* SWIG_Octave_ValueRef(SwigOctType* ost); + +#ifdef SWIG_DIRECTORS +namespace Swig +{ + SWIGOCTRTINLINE void erase_rtdir(void* vptr); + SWIGOCTRTINLINE Director* get_rtdir(void* vptr); + SWIGOCTRT rtdir_map* get_rtdir_map(); + SWIGOCTRTINLINE void set_rtdir(void* vptr, Director* d); + SWIGOCTRT void swig_director_destroyed(SwigOctType* self, Director* d); + SWIGOCTRT SwigOctType* swig_director_get_self(Director* d); + SWIGOCTRT void swig_director_set_self(Director* d, SwigOctType* self); +} +SWIGOCTRT void swig_acquire_ownership(void* vptr); +SWIGOCTRT void swig_acquire_ownership_array(void* vptr); +SWIGOCTRT void swig_acquire_ownership_obj(void* vptr, int own); +#endif + +////////// Declare Octave class: SwigOctMember ////////// + +struct SwigOctMember { + const char* name; + SwigOctFuncPtr method; + SwigOctFuncPtr get_method; + SwigOctFuncPtr set_method; + int flags; // 1=static, 2=global + const char* doc; + bool is_static() const { + return flags & 1; + } + bool is_global() const { + return flags & 2; + } +}; + +////////// Declare Octave class: SwigOctClass ////////// + +struct SwigOctClass { + const char* name; + swig_type_info** type; + int director; + SwigOctFuncPtr constructor; + const char* constructor_doc; + SwigOctFuncPtr destructor; + const SwigOctMember* members; + const char** base_names; + const swig_type_info** base; +}; + +////////// Declare Octave class: SwigOctValueRef ////////// + +struct SwigOctValueRef { + const octave_value_list& ovl; + int j; + SwigOctValueRef(const octave_value_list& _ovl, int _j) + : ovl(_ovl), j(_j) { + } + operator octave_value() const { + return ovl(j); + } + octave_value operator*() const { + return ovl(j); + } +}; + +////////// Declare Octave class: SwigOctType ////////// + +// SwigOctType plays the role of both the shadow class and the class +// representation within Octave, since there is no support for classes. +// +// These should really be decoupled, with the class support added to Octave +// and the shadow class given by an m-file script. That would dramatically +// reduce the runtime complexity, and be more in line w/ other modules. + +class SwigOctType: public octave_base_value +{ + + struct cpp_ptr { + void* ptr; + bool destroyed; + cpp_ptr(void* _ptr) : ptr(_ptr), destroyed(false) { + } + }; + + typedef std::pair < const swig_type_info* , cpp_ptr > type_ptr_pair; + typedef std::pair < const SwigOctMember* , octave_value > member_value_pair; + typedef std::map < std::string, member_value_pair > member_map; + + mutable swig_module_info* module; + const swig_type_info* construct_type; // type of special type object + std::vector < type_ptr_pair > types; // our c++ base classes + int own; // whether we call c++ destructors when we die + member_map members; + bool always_static; + + SwigOctType(const SwigOctType& x); + SwigOctType& operator= (const SwigOctType& rhs); + + bool dispatch_binary_op(const std::string& symbol, const octave_base_value& rhs, octave_value& ret); + bool dispatch_index_op(const std::string& symbol, const octave_value_list& rhs, octave_value_list& ret); + bool dispatch_unary_op(const std::string& symbol, octave_value& ret); + const swig_type_info* find_base(const std::string& name, const swig_type_info* base); + member_value_pair* find_member(const std::string& name, bool insert_if_not_found); + const SwigOctMember* find_member(const swig_type_info* type, const std::string& name); + void load_members(const SwigOctClass* c, member_map& out) const; + void load_members(member_map& out) const; + static octave_value make_value_hack(const octave_base_value& x); + octave_value_list member_deref(member_value_pair* m, const octave_value_list& args); + octave_value_list member_invoke(member_value_pair* m, const octave_value_list& args, int nargout); + +public: + + typedef member_map::const_iterator swig_member_const_iterator; + + SwigOctType(void* _ptr = 0, const swig_type_info* _type = 0, int _own = 0, bool _always_static = false); + ~SwigOctType(); + + octave_value as_value(); + void assign(const std::string& name, const octave_value& ov); + void assign(const std::string& name, const SwigOctMember* m); + void* cast(swig_type_info* type, int* _own, int flags); + octave_base_value* clone() const; + virtual octave_value convert_to_str(bool pad = false, bool force = false, char type = '"') const; + virtual octave_value convert_to_str_internal(bool pad, bool force, char type) const; + void decref(); + dim_vector dims(void) const; + static octave_value dispatch_binary_op(const octave_base_value& lhs, const octave_base_value& rhs, const char* op_name); + static bool dispatch_global_op(const std::string& symbol, const octave_value_list& args, octave_value& ret); + static octave_value dispatch_unary_op(const octave_base_value& x, const char* op_name); + octave_base_value* empty_clone() const; + const char* help_text() const; + void incref(); + bool is_defined() const; + virtual bool is_map() const; + virtual bool is_object() const; + bool is_owned() const; + virtual bool is_string() const; + virtual bool load_ascii(std::istream& is); + virtual bool load_binary(std::istream& is, bool swap, oct_mach_info::float_format fmt); + virtual string_vector map_keys() const; + virtual octave_map map_value() const; + void merge(SwigOctType& rhs); + void print(std::ostream& os, bool pr_as_read_syntax = false) const; + virtual bool save_ascii(std::ostream& os); + virtual bool save_binary(std::ostream& os, bool& save_as_floats); + virtual std::string string_value(bool force = false) const; + octave_value subsasgn(const std::string& ops, const std::list < octave_value_list > &idx, const octave_value& rhs); + virtual octave_value subsref(const std::string& ops, const std::list < octave_value_list > &idx); + virtual octave_value_list subsref(const std::string& ops, const std::list < octave_value_list > &idx, int nargout); + swig_member_const_iterator swig_members_begin(); + swig_member_const_iterator swig_members_end(); + long swig_this() const; + std::string swig_type_name() const; + +#ifdef HAVE_HDF5 + virtual bool load_hdf5(hid_t loc_id, const char* name, bool have_h5giterate_bug); + virtual bool save_hdf5(hid_t loc_id, const char* name, bool save_as_floats); +#endif + +#ifdef SWIG_DIRECTORS + void director_destroyed(Swig::Director* d); +#endif + +}; + +////////// Declare Octave class: SwigOctType ////////// + +// Octave tries hard to preserve pass-by-value semantics. Eg, assignments +// will call clone() via make_unique() if there is more than one outstanding +// reference to the lhs, and forces the clone's reference count to 1 +// (so you can't just increment your own count and return this). +// +// One way to fix this (without modifying Octave) is to add a level of +// indirection such that clone copies ref-counted pointer and we keep +// pass-by-ref semantics (which are more natural/expected for C++ bindings). +// +// Supporting both pass-by-{ref,value} and toggling via %feature/option +// might be nice. + +class SwigOctRef: public octave_base_value +{ + + DECLARE_OCTAVE_ALLOCATOR; + DECLARE_OV_TYPEID_FUNCTIONS_AND_DATA; + + SwigOctType* ptr; + +public: + + SwigOctRef(SwigOctType* _ptr = 0); + ~SwigOctRef(); + + octave_base_value* clone() const; + virtual octave_value convert_to_str(bool pad = false, bool force = false, char type = '"') const; + virtual octave_value convert_to_str_internal(bool pad, bool force, char type) const; + dim_vector dims(void) const; + octave_base_value* empty_clone() const; + SwigOctType* get_ptr() const; + bool is_defined() const; + virtual bool is_map() const; + virtual bool is_object() const; + virtual bool is_string() const; + virtual bool load_ascii(std::istream& is); + virtual bool load_binary(std::istream& is, bool swap, oct_mach_info::float_format fmt); + virtual string_vector map_keys() const; + virtual octave_map map_value() const; + void print(std::ostream& os, bool pr_as_read_syntax = false) const; + virtual bool save_ascii(std::ostream& os); + virtual bool save_binary(std::ostream& os, bool& save_as_floats); + virtual std::string string_value(bool force = false) const; + octave_value subsasgn(const std::string& ops, const std::list < octave_value_list > &idx, const octave_value& rhs); + virtual octave_value subsref(const std::string& ops, const std::list < octave_value_list > &idx); + virtual octave_value_list subsref(const std::string& ops, const std::list < octave_value_list > &idx, int nargout); + +#ifdef HAVE_HDF5 + virtual bool load_hdf5(hid_t loc_id, const char* name, bool have_h5giterate_bug); + virtual bool save_hdf5(hid_t loc_id, const char* name, bool save_as_floats); +#endif + +}; + +////////// Declare Octave class: SwigOctPacked ////////// + +class SwigOctPacked: public octave_base_value +{ + + DECLARE_OCTAVE_ALLOCATOR; + DECLARE_OV_TYPEID_FUNCTIONS_AND_DATA; + + swig_type_info* type; + std::vector < char > buf; + +public: + + SwigOctPacked(swig_type_info* _type = 0, const void* _buf = 0, size_t _buf_len = 0); + + octave_base_value* clone() const; + bool copy(swig_type_info* outtype, void* ptr, size_t sz) const; + octave_base_value* empty_clone() const; + bool is_defined() const; + virtual bool load_ascii(std::istream& is); + virtual bool load_binary(std::istream& is, bool swap, oct_mach_info::float_format fmt); + void print(std::ostream& os, bool pr_as_read_syntax = false) const; + virtual bool save_ascii(std::ostream& os); + virtual bool save_binary(std::ostream& os, bool& save_as_floats); + +#ifdef HAVE_HDF5 + virtual bool load_hdf5(hid_t loc_id, const char* name, bool have_h5giterate_bug); + virtual bool save_hdf5(hid_t loc_id, const char* name, bool save_as_floats); +#endif + +}; + +////////// Declare Octave class: Swig::Director and related classes ////////// + +#ifdef SWIG_DIRECTORS +namespace Swig +{ + + class Director + { + + SwigOctType* self; + bool swig_disowned; + + Director(const Director& x); + Director& operator= (const Director& rhs); + + public: + + Director(void* vptr); + ~Director(); + + void swig_disown(); + SwigOctType* swig_get_self() const; + void swig_set_self(SwigOctType* new_self); + + }; + + struct DirectorTypeMismatchException { + static void raise(const char* msg); + static void raise(const octave_value& ov, const char* msg); + }; + + struct DirectorPureVirtualException { + static void raise(const char* msg); + static void raise(const octave_value& ov, const char* msg); + }; + +} +#endif diff --git a/Lib/octave/octrunfunc.swg b/Lib/octave/octrunfunc.swg new file mode 100644 index 000000000..6773373b8 --- /dev/null +++ b/Lib/octave/octrunfunc.swg @@ -0,0 +1,187 @@ +// +// octrunfunc.swg - Octave runtime functions +// + +SWIGOCTRT bool SWIG_Octave_CheckNumArgs(const char* func_name, int num_args, int max_args, int min_args, int varargs) +{ + if (num_args > max_args && !varargs) { + error("function %s takes at most %i arguments", func_name, max_args); + } else if (num_args < min_args) { + error("function %s requires at least %i arguments", func_name, min_args); + } else { + return true; + } + return false; +} + +SWIGOCTRT octave_value_list* SWIG_Octave_AppendOutput(octave_value_list* ovl, const octave_value& ov) +{ + ovl->append(ov); + return ovl; +} + +SWIGOCTRT octave_value SWIG_ErrorType(int code) +{ + switch (code) { + case SWIG_MemoryError: + return "SWIG_MemoryError"; + case SWIG_IOError: + return "SWIG_IOError"; + case SWIG_RuntimeError: + return "SWIG_RuntimeError"; + case SWIG_IndexError: + return "SWIG_IndexError"; + case SWIG_TypeError: + return "SWIG_TypeError"; + case SWIG_DivisionByZero: + return "SWIG_DivisionByZero"; + case SWIG_OverflowError: + return "SWIG_OverflowError"; + case SWIG_SyntaxError: + return "SWIG_SyntaxError"; + case SWIG_ValueError: + return "SWIG_ValueError"; + case SWIG_SystemError: + return "SWIG_SystemError"; + case SWIG_AttributeError: + return "SWIG_AttributeError"; + } + return "SWIG unknown error"; +} + +SWIGOCTRT octave_value SWIG_Error(int code, const char* msg) +{ + octave_value type(SWIG_ErrorType(code)); + std::string r = msg; + r += " (" + type.string_value() + ")"; + error(r.c_str()); + return octave_value(r); +} + +SWIGOCTRT octave_value SWIG_Octave_NewPointerObj(void* ptr, swig_type_info* type, int flags) +{ + int own = (flags & SWIG_POINTER_OWN) ? SWIG_POINTER_OWN : 0; +#ifdef SWIG_DIRECTORS + Swig::Director* d = Swig::get_rtdir(ptr); + if (d && Swig::swig_director_get_self(d)) { + return Swig::swig_director_get_self(d)->as_value(); + } +#endif + return SWIG_Octave_ValueRef(new SwigOctType(ptr, type, own)); +} + +SWIGOCTRT int SWIG_Octave_ConvertPtrAndOwn(octave_value ov, void** ptr, swig_type_info* type, int flags, int* own) +{ + if (ov.is_cell() && ov.rows() == 1 && ov.columns() == 1) { + ov = ov.cell_value()(0); + } + if (!ov.is_defined() || (ov.is_matrix_type() && ov.rows() == 0 && ov.columns() == 0)) { + if (ptr) { + *ptr = 0; + } + return SWIG_OK; + } + if (ov.type_id() != SwigOctRef::static_type_id()) { + return SWIG_ERROR; + } + SwigOctRef* osr = static_cast < SwigOctRef*>(ov.internal_rep()); + SwigOctType* ost = osr->get_ptr(); + void* vptr = ost->cast(type, own, flags); + if (!vptr) { + return SWIG_ERROR; + } + if (ptr) { + *ptr = vptr; + } + return SWIG_OK; +} + +SWIGOCTRT octave_value SWIG_Octave_NewPackedObj(void* ptr, size_t sz, swig_type_info* type) +{ + return new SwigOctPacked(type, (char*) ptr, sz); +} + +SWIGOCTRT int SWIG_Octave_ConvertPacked(const octave_value& ov, void* ptr, size_t sz, swig_type_info* type) +{ + if (!ov.is_defined()) { + return SWIG_ERROR; + } + if (ov.type_id() != SwigOctPacked::static_type_id()) { + return SWIG_ERROR; + } + SwigOctPacked* ost = static_cast < SwigOctPacked*>(ov.internal_rep()); + return ost->copy(type, (char*) ptr, sz) ? SWIG_OK : SWIG_ERROR; +} + +SWIGOCTRTINLINE void SWIG_Octave_SetConstant(SwigOctType* module_ns, const std::string& name, const octave_value& ov) +{ + module_ns->assign(name, ov); +} + +SWIGOCTRTINLINE octave_value SWIG_Octave_GetGlobalValue(std::string name) +{ + return get_global_value(name, true); +} + +SWIGOCTRT void SWIG_Octave_SetGlobalValue(std::string name, const octave_value& value) +{ + set_global_value(name, value); +} + +SWIGOCTRT void SWIG_Octave_LinkGlobalValue(std::string name) +{ +#if !SWIG_OCTAVE_PREREQ(3,2,0) + link_to_global_variable(curr_sym_tab->lookup(name, true)); +#else +#if !SWIG_OCTAVE_PREREQ(3,8,0) + symbol_table::varref(name); +#endif + symbol_table::mark_global(name); +#endif +} + +SWIGOCTRT swig_module_info* SWIG_Octave_GetModule(void* clientdata) +{ + octave_value ov = SWIG_Octave_GetGlobalValue("__SWIG_MODULE__" SWIG_TYPE_TABLE_NAME SWIG_RUNTIME_VERSION); + if (!ov.is_defined() || ov.type_id() != SwigOctPacked::static_type_id()) { + return 0; + } + const SwigOctPacked* osp = static_cast < const SwigOctPacked*>(ov.internal_rep()); + swig_module_info* pointer = 0; + osp->copy(0, &pointer, sizeof(swig_module_info*)); + return pointer; +} + +SWIGOCTRT void SWIG_Octave_SetModule(void* clientdata, swig_module_info* pointer) +{ + octave_value ov = new SwigOctPacked(0, &pointer, sizeof(swig_module_info*)); + SWIG_Octave_SetGlobalValue("__SWIG_MODULE__" SWIG_TYPE_TABLE_NAME SWIG_RUNTIME_VERSION, ov); +} + +SWIGOCTRT octave_base_value* SWIG_Octave_ValueRef(SwigOctType* ost) +{ + return new SwigOctRef(ost); +} + +SWIGOCTRT SwigOctType* SWIG_Octave_ValueDeref(octave_value ov) +{ + if (ov.is_cell() && ov.rows() == 1 && ov.columns() == 1) { + ov = ov.cell_value()(0); + } + return SWIG_Octave_ValueDeref(*ov.internal_rep()); +} + +SWIGOCTRT SwigOctType* SWIG_Octave_ValueDeref(const octave_base_value& ov) +{ + if (ov.type_id() != SwigOctRef::static_type_id()) { + return 0; + } + const SwigOctRef* osr = static_cast < const SwigOctRef*>(&ov); + return osr->get_ptr(); +} + +SWIGOCTRT octave_value_list SWIG_Octave_SetImmutable(const octave_value_list& args, int nargout) +{ + error("attempt to set immutable member variable"); + return octave_value_list(); +} diff --git a/Lib/octave/octruninit.swg b/Lib/octave/octruninit.swg new file mode 100644 index 000000000..86d033af2 --- /dev/null +++ b/Lib/octave/octruninit.swg @@ -0,0 +1,422 @@ +// +// octruninit.swg - Octave runtime initialisation code +// + +// Forward declaration of module initialisation function +SWIGINTERN bool SWIG_Octave_InitUser(SwigOctType* module_ns); + +////////// Define, register, and install unary and binary operator dispatch functions ////////// + +#define SWIG_Octave_UnaryOp(name) \ + SWIGINTERN octave_value SWIG_Octave_UnaryOp_##name(const octave_base_value &x) { \ + return SwigOctType::dispatch_unary_op(x,#name); \ + } +#define SWIG_Octave_BinaryOp(name) \ + SWIGINTERN octave_value SWIG_Octave_BinaryOp_##name(const octave_base_value&lhs,const octave_base_value &rhs) { \ + return SwigOctType::dispatch_binary_op(lhs,rhs,#name); \ + } + +SWIG_Octave_UnaryOp(not); +SWIG_Octave_UnaryOp(uplus); +SWIG_Octave_UnaryOp(uminus); +SWIG_Octave_UnaryOp(transpose); +SWIG_Octave_UnaryOp(hermitian); +SWIG_Octave_UnaryOp(incr); +SWIG_Octave_UnaryOp(decr); + +SWIG_Octave_BinaryOp(add); +SWIG_Octave_BinaryOp(sub); +SWIG_Octave_BinaryOp(mul); +SWIG_Octave_BinaryOp(div); +SWIG_Octave_BinaryOp(pow); +SWIG_Octave_BinaryOp(ldiv); +SWIG_Octave_BinaryOp(lshift); +SWIG_Octave_BinaryOp(rshift); +SWIG_Octave_BinaryOp(lt); +SWIG_Octave_BinaryOp(le); +SWIG_Octave_BinaryOp(eq); +SWIG_Octave_BinaryOp(ge); +SWIG_Octave_BinaryOp(gt); +SWIG_Octave_BinaryOp(ne); +SWIG_Octave_BinaryOp(el_mul); +SWIG_Octave_BinaryOp(el_div); +SWIG_Octave_BinaryOp(el_pow); +SWIG_Octave_BinaryOp(el_ldiv); +SWIG_Octave_BinaryOp(el_and); +SWIG_Octave_BinaryOp(el_or); + +#define SWIG_Octave_RegisterUnaryOp(name) \ + if (!octave_value_typeinfo::lookup_unary_op(octave_value::op_##name,tid)) \ + octave_value_typeinfo::register_unary_op(octave_value::op_##name,tid,SWIG_Octave_UnaryOp_##name); +#define SWIG_Octave_RegisterBinaryOp(name) \ + if (!octave_value_typeinfo::lookup_binary_op(octave_value::op_##name,tid1,tid2)) \ + octave_value_typeinfo::register_binary_op(octave_value::op_##name,tid1,tid2,SWIG_Octave_BinaryOp_##name); + +SWIGINTERN void SWIG_Octave_InstallUnaryOps(int tid) +{ + SWIG_Octave_RegisterUnaryOp(not); + SWIG_Octave_RegisterUnaryOp(uplus); + SWIG_Octave_RegisterUnaryOp(uminus); + SWIG_Octave_RegisterUnaryOp(transpose); + SWIG_Octave_RegisterUnaryOp(hermitian); + SWIG_Octave_RegisterUnaryOp(incr); + SWIG_Octave_RegisterUnaryOp(decr); +} + +SWIGINTERN void SWIG_Octave_InstallBinaryOps(int tid1, int tid2) +{ + SWIG_Octave_RegisterBinaryOp(add); + SWIG_Octave_RegisterBinaryOp(sub); + SWIG_Octave_RegisterBinaryOp(mul); + SWIG_Octave_RegisterBinaryOp(div); + SWIG_Octave_RegisterBinaryOp(pow); + SWIG_Octave_RegisterBinaryOp(ldiv); + SWIG_Octave_RegisterBinaryOp(lshift); + SWIG_Octave_RegisterBinaryOp(rshift); + SWIG_Octave_RegisterBinaryOp(lt); + SWIG_Octave_RegisterBinaryOp(le); + SWIG_Octave_RegisterBinaryOp(eq); + SWIG_Octave_RegisterBinaryOp(ge); + SWIG_Octave_RegisterBinaryOp(gt); + SWIG_Octave_RegisterBinaryOp(ne); + SWIG_Octave_RegisterBinaryOp(el_mul); + SWIG_Octave_RegisterBinaryOp(el_div); + SWIG_Octave_RegisterBinaryOp(el_pow); + SWIG_Octave_RegisterBinaryOp(el_ldiv); + SWIG_Octave_RegisterBinaryOp(el_and); + SWIG_Octave_RegisterBinaryOp(el_or); +} + +SWIGINTERN void SWIG_Octave_InstallOps(int tid) +{ + // here we assume that tid are conseq integers increasing from zero, and + // that our tid is the last one. might be better to have explicit string + // list of types we should bind to, and use lookup_type to resolve their tid. + SWIG_Octave_InstallUnaryOps(tid); + SWIG_Octave_InstallBinaryOps(tid, tid); + for (int j = 0; j < tid; ++j) { + SWIG_Octave_InstallBinaryOps(j, tid); + SWIG_Octave_InstallBinaryOps(tid, j); + } +} + +////////// Internal functions for loading/installing modules ////////// + +SWIGINTERN bool SWIG_Octave_LoadModule(std::string name) +{ + bool retn; + { +#if !SWIG_OCTAVE_PREREQ(3,3,50) + unwind_protect::begin_frame("SWIG_Octave_LoadModule"); + unwind_protect_int(error_state); + unwind_protect_int(warning_state); + unwind_protect_bool(discard_error_messages); + unwind_protect_bool(discard_warning_messages); +#else + unwind_protect frame; + frame.protect_var(error_state); + frame.protect_var(warning_state); + frame.protect_var(discard_error_messages); + frame.protect_var(discard_warning_messages); +#endif + error_state = 0; + warning_state = 0; + discard_error_messages = true; + discard_warning_messages = true; + feval(name, octave_value_list(), 0); + retn = (error_state == 0); +#if !SWIG_OCTAVE_PREREQ(3,3,50) + unwind_protect::run_frame("SWIG_Octave_LoadModule"); +#endif + } + if (!retn) { + error(SWIG_name_d ": could not load module `%s'", name.c_str()); + } + return retn; +} + +SWIGINTERN bool SWIG_Octave_InstallFunction(octave_function* octloadfcn, std::string name) +{ + bool retn; + { +#if !SWIG_OCTAVE_PREREQ(3,3,50) + unwind_protect::begin_frame("SWIG_Octave_InstallFunction"); + unwind_protect_int(error_state); + unwind_protect_int(warning_state); + unwind_protect_bool(discard_error_messages); + unwind_protect_bool(discard_warning_messages); +#else + unwind_protect frame; + frame.protect_var(error_state); + frame.protect_var(warning_state); + frame.protect_var(discard_error_messages); + frame.protect_var(discard_warning_messages); +#endif + error_state = 0; + warning_state = 0; + discard_error_messages = true; + discard_warning_messages = true; + octave_value_list args; + args.append(name); + args.append(octloadfcn->fcn_file_name()); + error_state = 0; + feval("autoload", args, 0); + retn = (error_state == 0); +#if !SWIG_OCTAVE_PREREQ(3,3,50) + unwind_protect::run_frame("SWIG_Octave_InstallFunction"); +#endif + } + if (!retn) { + error(SWIG_name_d ": could not load function `%s'", name.c_str()); + } + return retn; +} + +////////// Public module function: swig_type() ////////// + +static const char* const swig_type_usage = "-*- texinfo -*- \n\ +@deftypefn {Loadable Function} {} swig_type(@var{swigref})\n\ +Return the underlying C/C++ type name of a SWIG-wrapped object.\n\ +@end deftypefn"; + +DEFUN_DLD(swig_type, args, nargout, swig_type_usage) +{ + if (args.length() != 1) { + error("swig_type: must be called with only a single object"); + return octave_value_list(); + } + SwigOctType* ost = SWIG_Octave_ValueDeref(args(0)); + if (!ost) { + error("swig_type: object is not a swig_ref"); + return octave_value_list(); + } + return octave_value(ost->swig_type_name()); +} + +////////// Public module function: swig_typequery() ////////// + +static const char* const swig_typequery_usage = "-*- texinfo -*- \n\ +@deftypefn {Loadable Function} {} swig_typequery(@var{string})\n\ +Return @var{string} if it is a recognised SWIG-wrapped C/C++ type name;\n\ +otherwise return `'.\n\ +@end deftypefn"; + +DEFUN_DLD(swig_typequery, args, nargout, swig_typequery_usage) +{ + if (args.length() != 1 || !args(0).is_string()) { + error("swig_typequery: must be called with single string argument"); + return octave_value_list(); + } + swig_module_info* module = SWIG_GetModule(0); + swig_type_info* type = SWIG_TypeQueryModule(module, module, args(0).string_value().c_str()); + if (!type) { + return octave_value(""); + } + return octave_value(type->name); +} + +////////// Public module function: swig_this() ////////// + +static const char* const swig_this_usage = "-*- texinfo -*- \n\ +@deftypefn {Loadable Function} {} swig_this(@var{swigref})\n\ +Return the underlying C/C++ pointer of a SWIG-wrapped object.\n\ +@end deftypefn"; + +DEFUN_DLD(swig_this, args, nargout, swig_this_usage) +{ + if (args.length() != 1) { + error("swig_this: must be called with only a single object"); + return octave_value_list(); + } + if (args(0).is_matrix_type() && args(0).rows() == 0 && args(0).columns() == 0) { + return octave_value(octave_uint64(0)); + } + SwigOctType* ost = SWIG_Octave_ValueDeref(args(0)); + if (!ost) { + error("swig_this: object is not a swig_ref"); + return octave_value_list(); + } + return octave_value(octave_uint64((unsigned long long) ost->swig_this())); +} + +////////// Public module function: subclass() ////////// + +static const char* const subclass_usage = "-*- texinfo -*- \n\ +@deftypefn {Loadable Function} {} subclass()\n\ +@deftypefnx{Loadable Function} {} subclass(@var{swigclass}, @var{name}, @var{fcn}, @dots{})\n\ +Subclass a C++ class from within Octave, and provide implementations of its virtual methods.\n\ +\n\ +See the SWIG manual for usage examples.\n\ +@end deftypefn"; + +DEFUN_DLD(subclass, args, nargout, subclass_usage) +{ + SwigOctType* top = new SwigOctType; + for (int j = 0; j < args.length(); ++j) { + if (args(j).type_id() == SwigOctRef::static_type_id()) { + SwigOctRef* osr = static_cast < SwigOctRef*>(args(j).internal_rep()); + SwigOctType* ost = osr->get_ptr(); + if (!ost->is_owned()) { + error("subclass: cannot subclass object not constructed on octave side"); + return octave_value_list(); + } + top->merge(*ost); + } else if (args(j).is_function_handle()) { + top->assign(args(j).fcn_handle_value()->fcn_name(), args(j)); + } else if (args(j).is_string()) { + if (j + 1 >= args.length()) { + error("subclass: member assignments must be of string,value form"); + return octave_value_list(); + } + top->assign(args(j).string_value(), args(j + 1)); + ++j; + } else { + error("subclass: invalid arguments to subclass()"); + return octave_value_list(); + } + } + return octave_value(SWIG_Octave_ValueRef(top)); +} + +////////// Public function which loads the Octave module ////////// + +static const char* const SWIG_name_usage = "-*- texinfo -*- \n\ +@deftypefn {Loadable Module} {} " SWIG_name_d "\n\ +Loads the SWIG-generated module `" SWIG_name_d "'.\n\ +@end deftypefn"; + +DEFUN_DLD(SWIG_name, args, nargout, SWIG_name_usage) +{ + + static SwigOctType* module_ns = 0; + + // workaround to prevent octave seg-faulting on exit: set Octave exit function + // octave_exit to _Exit, which exits immediately without trying to cleanup memory. + // definitely affects version 3.2.*, not sure about 3.3.*, seems to be fixed in + // version 3.4.* and above. can be turned off with macro definition. +#ifndef SWIG_OCTAVE_NO_SEGFAULT_HACK +#if SWIG_OCTAVE_PREREQ(3,2,0) && !SWIG_OCTAVE_PREREQ(3,4,1) + octave_exit = ::_Exit; +#endif +#endif + + // check for no input and output args + if (args.length() != 0 || nargout != 0) { + print_usage(); + return octave_value_list(); + } + + // create module on first function call + if (!module_ns) { + + // workaround bug in octave where installing global variable of custom type and then + // exiting without explicitly clearing the variable causes octave to segfault. +#if SWIG_OCTAVE_PREREQ(3,2,0) + octave_value_list eval_args; + eval_args.append("base"); + eval_args.append("function __swig_atexit__; " + " if mislocked() " + " clear -all; " + " else " + " mlock(); " + " endif; " + "endfunction; " + "__swig_atexit__; " + "atexit(\"__swig_atexit__\", false); " + "atexit(\"__swig_atexit__\")"); + feval("evalin", eval_args, 0); +#endif + + SwigOctRef::register_type(); + SwigOctPacked::register_type(); + SWIG_InitializeModule(0); + SWIG_PropagateClientData(); + + octave_function* me = octave_call_stack::current(); + + if (!SWIG_Octave_InstallFunction(me, "swig_type")) { + return octave_value_list(); + } + if (!SWIG_Octave_InstallFunction(me, "swig_typequery")) { + return octave_value_list(); + } + if (!SWIG_Octave_InstallFunction(me, "swig_this")) { + return octave_value_list(); + } + if (!SWIG_Octave_InstallFunction(me, "subclass")) { + return octave_value_list(); + } + + SwigOctType* cvar_ns = 0; + if (std::string(SWIG_global_name) != ".") { + cvar_ns = new SwigOctType; + for (int j = 0; swig_globals[j].name; ++j) + if (swig_globals[j].get_method) { + cvar_ns->assign(swig_globals[j].name, &swig_globals[j]); + } + } + + module_ns = new SwigOctType(0, 0, 0, true); + if (std::string(SWIG_global_name) != ".") { + module_ns->assign(SWIG_global_name, SWIG_Octave_ValueRef(cvar_ns)); + } else { + for (int j = 0; swig_globals[j].name; ++j) + if (swig_globals[j].get_method) { + module_ns->assign(swig_globals[j].name, &swig_globals[j]); + } + } + for (int j = 0; swig_globals[j].name; ++j) + if (swig_globals[j].method) { + module_ns->assign(swig_globals[j].name, &swig_globals[j]); + } + + // * need better solution here; swig_type -> octave_class mapping is + // * really n-to-1, in some cases such as template partial spec, etc. + // * see failing tests. + for (int j = 0; swig_types[j]; ++j) + if (swig_types[j]->clientdata) { + SwigOctClass* c = (SwigOctClass*) swig_types[j]->clientdata; + module_ns->assign(c->name, + SWIG_Octave_ValueRef + (new SwigOctType(0, swig_types[j]))); + } + + if (!SWIG_Octave_InitUser(module_ns)) { + delete module_ns; + module_ns = 0; + return octave_value_list(); + } + + SWIG_Octave_InstallOps(SwigOctRef::static_type_id()); + + SwigOctType::swig_member_const_iterator mb; + for (mb = module_ns->swig_members_begin(); mb != module_ns->swig_members_end(); ++mb) { + if (mb->second.first && mb->second.first->method) { + if (!SWIG_Octave_InstallFunction(me, mb->first)) { + return octave_value_list(); + } + } + } + +#if !SWIG_OCTAVE_PREREQ(3,2,0) + mlock(me->name()); +#else + mlock(); +#endif + + } + + SwigOctType::swig_member_const_iterator mb; + for (mb = module_ns->swig_members_begin(); mb != module_ns->swig_members_end(); ++mb) { + if (mb->second.second.is_defined()) { + SWIG_Octave_SetGlobalValue(mb->first, mb->second.second); + SWIG_Octave_LinkGlobalValue(mb->first); + } + } + + SWIG_Octave_SetGlobalValue(SWIG_name_d, module_ns->as_value()); + SWIG_Octave_LinkGlobalValue(SWIG_name_d); + + return octave_value_list(); + +} diff --git a/Lib/octave/octruntime.swg b/Lib/octave/octruntime.swg index fbf2007f6..cdcb66c30 100644 --- a/Lib/octave/octruntime.swg +++ b/Lib/octave/octruntime.swg @@ -1,323 +1,20 @@ -%insert(runtime) %{ -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -%} +// +// octruntime.swg - Octave runtime code +// -%insert(runtime) "swigrun.swg"; -%insert(runtime) "swigerrors.swg"; -%insert(runtime) "octrun.swg"; +// Insert standard SWIG runtime code +%insert("runtime") "swigrun.swg"; +%insert("runtime") "swigerrors.swg"; +%insert("initbeforefunc") "swiginit.swg" -%insert(initbeforefunc) "swiginit.swg" +// Declarations of Octave runtime code +%insert("runtime") "octrundecl.swg"; -%insert(initbeforefunc) %{ +// Octave runtime functions +%insert("runtime") "octrunfunc.swg" -static bool SWIG_init_user(octave_swig_type* module_ns); +// Octave runtime classes +%insert("runtime") "octrunclass.swg" -SWIGINTERN bool SWIG_Octave_LoadModule(std::string name) { - bool retn; - { -#if !SWIG_OCTAVE_PREREQ(3,3,50) - unwind_protect::begin_frame("SWIG_Octave_LoadModule"); - unwind_protect_int(error_state); - unwind_protect_int(warning_state); - unwind_protect_bool(discard_error_messages); - unwind_protect_bool(discard_warning_messages); -#else - unwind_protect frame; - frame.protect_var(error_state); - frame.protect_var(warning_state); - frame.protect_var(discard_error_messages); - frame.protect_var(discard_warning_messages); -#endif - error_state = 0; - warning_state = 0; - discard_error_messages = true; - discard_warning_messages = true; - feval(name, octave_value_list(), 0); - retn = (error_state == 0); -#if !SWIG_OCTAVE_PREREQ(3,3,50) - unwind_protect::run_frame("SWIG_Octave_LoadModule"); -#endif - } - if (!retn) { - error(SWIG_name_d ": could not load module `%s'", name.c_str()); - } - return retn; -} - -SWIGINTERN bool SWIG_Octave_InstallFunction(octave_function *octloadfcn, std::string name) { - bool retn; - { -#if !SWIG_OCTAVE_PREREQ(3,3,50) - unwind_protect::begin_frame("SWIG_Octave_InstallFunction"); - unwind_protect_int(error_state); - unwind_protect_int(warning_state); - unwind_protect_bool(discard_error_messages); - unwind_protect_bool(discard_warning_messages); -#else - unwind_protect frame; - frame.protect_var(error_state); - frame.protect_var(warning_state); - frame.protect_var(discard_error_messages); - frame.protect_var(discard_warning_messages); -#endif - error_state = 0; - warning_state = 0; - discard_error_messages = true; - discard_warning_messages = true; - octave_value_list args; - args.append(name); - args.append(octloadfcn->fcn_file_name()); - error_state = 0; - feval("autoload", args, 0); - retn = (error_state == 0); -#if !SWIG_OCTAVE_PREREQ(3,3,50) - unwind_protect::run_frame("SWIG_Octave_InstallFunction"); -#endif - } - if (!retn) { - error(SWIG_name_d ": could not load function `%s'", name.c_str()); - } - return retn; -} - -static const char *const subclass_usage = "-*- texinfo -*- \n\ -@deftypefn {Loadable Function} {} subclass()\n\ -@deftypefnx{Loadable Function} {} subclass(@var{swigclass}, @var{name}, @var{fcn}, @dots{})\n\ -Subclass a C++ class from within Octave, and provide implementations of its virtual methods.\n\ -\n\ -See the SWIG manual for usage examples.\n\ -@end deftypefn"; - -DEFUN_DLD( subclass, args, nargout, subclass_usage ) { - octave_swig_type *top = new octave_swig_type; - for (int j = 0; j < args.length(); ++j) { - if (args(j).type_id() == octave_swig_ref::static_type_id()) { - octave_swig_ref *osr = static_cast < octave_swig_ref *>(args(j).internal_rep()); - octave_swig_type *ost = osr->get_ptr(); - if (!ost->is_owned()) { - error("subclass: cannot subclass object not constructed on octave side"); - return octave_value_list(); - } - top->merge(*ost); - } else if (args(j).is_function_handle()) { - top->assign(args(j).fcn_handle_value()->fcn_name(), args(j)); - } else if (args(j).is_string()) { - if (j + 1 >= args.length()) { - error("subclass: member assignments must be of string,value form"); - return octave_value_list(); - } - top->assign(args(j).string_value(), args(j + 1)); - ++j; - } else { - error("subclass: invalid arguments to subclass()"); - return octave_value_list(); - } - } - return octave_value(Swig::swig_value_ref(top)); -} - -static const char *const swig_type_usage = "-*- texinfo -*- \n\ -@deftypefn {Loadable Function} {} swig_type(@var{swigref})\n\ -Return the underlying C/C++ type name of a SWIG-wrapped object.\n\ -@end deftypefn"; - -DEFUN_DLD( swig_type, args, nargout, swig_type_usage ) { - if (args.length() != 1) { - error("swig_type: must be called with only a single object"); - return octave_value_list(); - } - octave_swig_type *ost = Swig::swig_value_deref(args(0)); - if (!ost) { - error("swig_type: object is not a swig_ref"); - return octave_value_list(); - } - return octave_value(ost->swig_type_name()); -} - -static const char *const swig_typequery_usage = "-*- texinfo -*- \n\ -@deftypefn {Loadable Function} {} swig_typequery(@var{string})\n\ -Return @var{string} if it is a recognised SWIG-wrapped C/C++ type name;\n\ -otherwise return `'.\n\ -@end deftypefn"; - -DEFUN_DLD( swig_typequery, args, nargout, swig_typequery_usage ) { - if (args.length() != 1 || !args(0).is_string()) { - error("swig_typequery: must be called with single string argument"); - return octave_value_list(); - } - swig_module_info *module = SWIG_GetModule(0); - swig_type_info *type = SWIG_TypeQueryModule(module, module, args(0).string_value().c_str()); - if (!type) - return octave_value(""); - return octave_value(type->name); -} - -static const char *const swig_this_usage = "-*- texinfo -*- \n\ -@deftypefn {Loadable Function} {} swig_this(@var{swigref})\n\ -Return the underlying C/C++ pointer of a SWIG-wrapped object.\n\ -@end deftypefn"; - -DEFUN_DLD( swig_this, args, nargout, swig_this_usage ) { - if (args.length() != 1) { - error("swig_this: must be called with only a single object"); - return octave_value_list(); - } - if (args(0).is_matrix_type() && args(0).rows() == 0 && args(0).columns() == 0) - return octave_value(octave_uint64(0)); - octave_swig_type *ost = Swig::swig_value_deref(args(0)); - if (!ost) { - error("swig_this: object is not a swig_ref"); - return octave_value_list(); - } - return octave_value(octave_uint64((unsigned long long) ost->swig_this())); -} - -static const char *const SWIG_name_usage = "-*- texinfo -*- \n\ -@deftypefn {Loadable Module} {} " SWIG_name_d "\n\ -Loads the SWIG-generated module `" SWIG_name_d "'.\n\ -@end deftypefn"; - -DEFUN_DLD( SWIG_name, args, nargout, SWIG_name_usage ) { - - static octave_swig_type* module_ns = 0; - - // workaround to prevent octave seg-faulting on exit: set Octave exit function - // octave_exit to _Exit, which exits immediately without trying to cleanup memory. - // definitely affects version 3.2.*, not sure about 3.3.*, seems to be fixed in - // version 3.4.* and above. can be turned off with macro definition. -#ifndef SWIG_OCTAVE_NO_SEGFAULT_HACK -#if SWIG_OCTAVE_PREREQ(3,2,0) && !SWIG_OCTAVE_PREREQ(3,4,1) - octave_exit = ::_Exit; -#endif -#endif - - // check for no input and output args - if (args.length() != 0 || nargout != 0) { - print_usage(); - return octave_value_list(); - } - - // create module on first function call - if (!module_ns) { - - // workaround bug in octave where installing global variable of custom type and then - // exiting without explicitly clearing the variable causes octave to segfault. -#if SWIG_OCTAVE_PREREQ(3,2,0) - octave_value_list eval_args; - eval_args.append("base"); - eval_args.append("function __swig_atexit__; " - " if mislocked() " - " clear -all; " - " else " - " mlock(); " - " endif; " - "endfunction; " - "__swig_atexit__; " - "atexit(\"__swig_atexit__\", false); " - "atexit(\"__swig_atexit__\")"); - feval("evalin", eval_args, 0); -#endif - - octave_swig_ref::register_type(); - octave_swig_packed::register_type(); - SWIG_InitializeModule(0); - SWIG_PropagateClientData(); - - octave_function *me = octave_call_stack::current(); - - if (!SWIG_Octave_InstallFunction(me, "swig_type")) { - return octave_value_list(); - } - if (!SWIG_Octave_InstallFunction(me, "swig_typequery")) { - return octave_value_list(); - } - if (!SWIG_Octave_InstallFunction(me, "swig_this")) { - return octave_value_list(); - } - if (!SWIG_Octave_InstallFunction(me, "subclass")) { - return octave_value_list(); - } - - octave_swig_type* cvar_ns=0; - if (std::string(SWIG_global_name) != ".") { - cvar_ns=new octave_swig_type; - for (int j=0;swig_globals[j].name;++j) - if (swig_globals[j].get_method) - cvar_ns->assign(swig_globals[j].name,&swig_globals[j]); - } - - module_ns=new octave_swig_type(0, 0, 0, true); - if (std::string(SWIG_global_name) != ".") { - module_ns->assign(SWIG_global_name,Swig::swig_value_ref(cvar_ns)); - } - else { - for (int j=0;swig_globals[j].name;++j) - if (swig_globals[j].get_method) - module_ns->assign(swig_globals[j].name,&swig_globals[j]); - } - for (int j=0;swig_globals[j].name;++j) - if (swig_globals[j].method) - module_ns->assign(swig_globals[j].name,&swig_globals[j]); - - // * need better solution here; swig_type -> octave_class mapping is - // * really n-to-1, in some cases such as template partial spec, etc. - // * see failing tests. - for (int j=0;swig_types[j];++j) - if (swig_types[j]->clientdata) { - swig_octave_class* c=(swig_octave_class*)swig_types[j]->clientdata; - module_ns->assign(c->name, - Swig::swig_value_ref - (new octave_swig_type(0,swig_types[j]))); - } - - if (!SWIG_init_user(module_ns)) { - delete module_ns; - module_ns=0; - return octave_value_list(); - } - - SWIG_InstallOps(octave_swig_ref::static_type_id()); - - octave_swig_type::swig_member_const_iterator mb; - for (mb = module_ns->swig_members_begin(); mb != module_ns->swig_members_end(); ++mb) { - if (mb->second.first && mb->second.first->method) { - if (!SWIG_Octave_InstallFunction(me, mb->first)) { - return octave_value_list(); - } - } - } - -#if !SWIG_OCTAVE_PREREQ(3,2,0) - mlock(me->name()); -#else - mlock(); -#endif - - } - - octave_swig_type::swig_member_const_iterator mb; - for (mb = module_ns->swig_members_begin(); mb != module_ns->swig_members_end(); ++mb) { - if (mb->second.second.is_defined()) { - SWIG_Octave_SetGlobalValue(mb->first, mb->second.second); - SWIG_Octave_LinkGlobalValue(mb->first); - } - } - - SWIG_Octave_SetGlobalValue(SWIG_name_d, module_ns->as_value()); - SWIG_Octave_LinkGlobalValue(SWIG_name_d); - - return octave_value_list(); - -} - -%} +// Octave runtime initialisation code +%insert("initbeforefunc") "octruninit.swg" diff --git a/Lib/octave/octstdcommon.swg b/Lib/octave/octstdcommon.swg index 96923f40a..56379ed73 100644 --- a/Lib/octave/octstdcommon.swg +++ b/Lib/octave/octstdcommon.swg @@ -1,226 +1,258 @@ -%fragment("StdTraits","header",fragment="StdTraitsCommon") +// +// octstdcommon.swg - Octave common STL code +// + +%fragment("StdTraits", "header", fragment = "StdTraitsCommon") { -namespace swig { -// Traits that provides the from method - template struct traits_from_ptr { - static octave_value from(Type *val, int owner = 0) { - return SWIG_NewPointerObj(val, type_info(), owner); - } - }; - template struct traits_from { - static octave_value from(const Type& val) { - return traits_from_ptr::from(new Type(val), 1); - } - }; + namespace swig + { - template struct traits_from { - static octave_value from(Type* val) { - return traits_from_ptr::from(val, 0); - } - }; + // Traits that provides the from method + template struct traits_from_ptr { + static octave_value from(Type* val, int owner = 0) { + return SWIG_NewPointerObj(val, type_info(), owner); + } + }; - template struct traits_from { - static octave_value from(const Type* val) { - return traits_from_ptr::from(const_cast(val), 0); - } - }; + template struct traits_from { + static octave_value from(const Type& val) { + return traits_from_ptr::from(new Type(val), 1); + } + }; + template struct traits_from { + static octave_value from(Type* val) { + return traits_from_ptr::from(val, 0); + } + }; - template - inline octave_value from(const Type& val) { - return traits_from::from(val); - } + template struct traits_from { + static octave_value from(const Type* val) { + return traits_from_ptr::from(const_cast(val), 0); + } + }; - template - inline octave_value from_ptr(Type* val, int owner) { - return traits_from_ptr::from(val, owner); - } + + template + inline octave_value from(const Type& val) + { + return traits_from::from(val); + } + + template + inline octave_value from_ptr(Type* val, int owner) + { + return traits_from_ptr::from(val, owner); + } // Traits that provides the asval/as/check method - template - struct traits_asptr { - static int asptr(const octave_value& obj, Type **val) { - Type *p; - int res = SWIG_ConvertPtr(obj, (void**)&p, type_info(), 0); - if (SWIG_IsOK(res)) { - if (val) *val = p; + template + struct traits_asptr { + static int asptr(const octave_value& obj, Type** val) { + Type* p; + int res = SWIG_ConvertPtr(obj, (void**) &p, type_info(), 0); + if (SWIG_IsOK(res)) { + if (val) { + *val = p; + } + } + return res; } - return res; + }; + + template + inline int asptr(const octave_value& obj, Type** vptr) + { + return traits_asptr::asptr(obj, vptr); } - }; - template - inline int asptr(const octave_value& obj, Type **vptr) { - return traits_asptr::asptr(obj, vptr); - } + template + struct traits_asval { + static int asval(const octave_value& obj, Type* val) { + if (val) { + Type* p = 0; + int res = traits_asptr::asptr(obj, &p); + if (!SWIG_IsOK(res)) { + return res; + } + if (p) { + typedef typename noconst_traits::noconst_type noconst_type; + * (const_cast(val)) = *p; + if (SWIG_IsNewObj(res)) { + %delete(p); + res = SWIG_DelNewMask(res); + } + return res; + } else { + return SWIG_ERROR; + } + } else { + return traits_asptr::asptr(obj, (Type**)(0)); + } + } + }; - template - struct traits_asval { - static int asval(const octave_value& obj, Type *val) { - if (val) { - Type *p = 0; - int res = traits_asptr::asptr(obj, &p); - if (!SWIG_IsOK(res)) return res; - if (p) { - typedef typename noconst_traits::noconst_type noconst_type; - *(const_cast(val)) = *p; - if (SWIG_IsNewObj(res)){ - %delete(p); - res = SWIG_DelNewMask(res); - } - return res; - } else { - return SWIG_ERROR; - } - } else { - return traits_asptr::asptr(obj, (Type **)(0)); + template struct traits_asval { + static int asval(const octave_value& obj, Type** val) { + if (val) { + typedef typename noconst_traits::noconst_type noconst_type; + noconst_type* p = 0; + int res = traits_asptr::asptr(obj, &p); + if (SWIG_IsOK(res)) { + * (const_cast(val)) = p; + } + return res; + } else { + return traits_asptr::asptr(obj, (Type**)(0)); + } } + }; + + template + inline int asval(const octave_value& obj, Type* val) + { + return traits_asval::asval(obj, val); } - }; - - template struct traits_asval { - static int asval(const octave_value& obj, Type **val) { - if (val) { - typedef typename noconst_traits::noconst_type noconst_type; - noconst_type *p = 0; - int res = traits_asptr::asptr(obj, &p); - if (SWIG_IsOK(res)) { - *(const_cast(val)) = p; - } - return res; - } else { - return traits_asptr::asptr(obj, (Type **)(0)); + + template + struct traits_as { + static Type as(const octave_value& obj, bool throw_error) { + Type v; + int res = asval(obj, &v); + if (!obj.is_defined() || !SWIG_IsOK(res)) { + if (!SWIG_Octave_ErrorOccurred()) { + %type_error(swig::type_name()); + } + if (throw_error) { + throw std::invalid_argument("bad type"); + } + } + return v; } - } - }; - - template - inline int asval(const octave_value& obj, Type *val) { - return traits_asval::asval(obj, val); - } + }; - template - struct traits_as { - static Type as(const octave_value& obj, bool throw_error) { - Type v; - int res = asval(obj, &v); - if (!obj.is_defined() || !SWIG_IsOK(res)) { - if (!Octave_Error_Occurred()) { - %type_error(swig::type_name()); - } - if (throw_error) throw std::invalid_argument("bad type"); + template + struct traits_as { + static Type as(const octave_value& obj, bool throw_error) { + Type* v = 0; + int res = traits_asptr::asptr(obj, &v); + if (SWIG_IsOK(res) && v) { + if (SWIG_IsNewObj(res)) { + Type r(*v); + %delete(v); + return r; + } else { + return *v; + } + } else { + // Uninitialized return value, no Type() constructor required. + static Type* v_def = (Type*) malloc(sizeof(Type)); + if (!SWIG_Octave_ErrorOccurred()) { + %type_error(swig::type_name()); + } + if (throw_error) { + throw std::invalid_argument("bad type"); + } + memset(v_def, 0, sizeof(Type)); + return *v_def; + } } - return v; - } - }; - - template - struct traits_as { - static Type as(const octave_value& obj, bool throw_error) { - Type *v = 0; - int res = traits_asptr::asptr(obj, &v); - if (SWIG_IsOK(res) && v) { - if (SWIG_IsNewObj(res)) { - Type r(*v); - %delete(v); - return r; - } else { - return *v; - } - } else { - // Uninitialized return value, no Type() constructor required. - static Type *v_def = (Type*) malloc(sizeof(Type)); - if (!Octave_Error_Occurred()) { - %type_error(swig::type_name()); - } - if (throw_error) throw std::invalid_argument("bad type"); - memset(v_def,0,sizeof(Type)); - return *v_def; + }; + + template + struct traits_as { + static Type* as(const octave_value& obj, bool throw_error) { + Type* v = 0; + int res = traits_asptr::asptr(obj, &v); + if (SWIG_IsOK(res)) { + return v; + } else { + if (!SWIG_Octave_ErrorOccurred()) { + %type_error(swig::type_name()); + } + if (throw_error) { + throw std::invalid_argument("bad type"); + } + return 0; + } } + }; + + template + inline Type as(const octave_value& obj, bool te = false) + { + return traits_as::category>::as(obj, te); } - }; - - template - struct traits_as { - static Type* as(const octave_value& obj, bool throw_error) { - Type *v = 0; - int res = traits_asptr::asptr(obj, &v); - if (SWIG_IsOK(res)) { - return v; - } else { - if (!Octave_Error_Occurred()) { - %type_error(swig::type_name()); - } - if (throw_error) throw std::invalid_argument("bad type"); - return 0; + + template + struct traits_check { + static bool check(const octave_value& obj) { + int res = asval(obj, (Type*)(0)); + return SWIG_IsOK(res) ? true : false; } - } - }; - - template - inline Type as(const octave_value& obj, bool te = false) { - return traits_as::category>::as(obj, te); - } + }; - template - struct traits_check { - static bool check(const octave_value& obj) { - int res = asval(obj, (Type *)(0)); - return SWIG_IsOK(res) ? true : false; - } - }; + template + struct traits_check { + static bool check(const octave_value& obj) { + int res = asptr(obj, (Type**)(0)); + return SWIG_IsOK(res) ? true : false; + } + }; - template - struct traits_check { - static bool check(const octave_value& obj) { - int res = asptr(obj, (Type **)(0)); - return SWIG_IsOK(res) ? true : false; + template + inline bool check(const octave_value& obj) + { + return traits_check::category>::check(obj); } - }; - template - inline bool check(const octave_value& obj) { - return traits_check::category>::check(obj); } + } -} -%define %specialize_std_container(Type,Check,As,From) -%{ -namespace swig { - template <> struct traits_asval { - typedef Type value_type; - static int asval(const octave_value& obj, value_type *val) { - if (Check(obj)) { - if (val) *val = As(obj); - return SWIG_OK; +%define %specialize_std_container(Type, Check, As, From) +%header %{ + + namespace swig { + + template <> + struct traits_asval { + typedef Type value_type; + static int asval(const octave_value& obj, value_type* val) { + if (Check(obj)) { + if (val) { + *val = As(obj); + } + return SWIG_OK; + } + return SWIG_ERROR; } - return SWIG_ERROR; - } - }; - template <> struct traits_from { - typedef Type value_type; - static octave_value from(const value_type& val) { - return From(val); - } - }; + }; + + template <> + struct traits_from { + typedef Type value_type; + static octave_value from(const value_type& val) { + return From(val); + } + }; + + template <> + struct traits_check { + static int check(const octave_value& obj) { + int res = Check(obj); + return obj && res ? res : 0; + } + }; + + } - template <> - struct traits_check { - static int check(const octave_value& obj) { - int res = Check(obj); - return obj && res ? res : 0; - } - }; -} %} %enddef - #define specialize_std_vector(Type,Check,As,From) %specialize_std_container(%arg(Type),Check,As,From) #define specialize_std_list(Type,Check,As,From) %specialize_std_container(%arg(Type),Check,As,From) #define specialize_std_deque(Type,Check,As,From) %specialize_std_container(%arg(Type),Check,As,From) #define specialize_std_set(Type,Check,As,From) %specialize_std_container(%arg(Type),Check,As,From) #define specialize_std_multiset(Type,Check,As,From) %specialize_std_container(%arg(Type),Check,As,From) - diff --git a/Lib/octave/octtypemaps.swg b/Lib/octave/octtypemaps.swg index 4acf8e076..b241ad400 100644 --- a/Lib/octave/octtypemaps.swg +++ b/Lib/octave/octtypemaps.swg @@ -1,46 +1,45 @@ +// +// octtypemaps.swg - Octave typemaps +// // Include fundamental fragment definitions %include -// Look for user fragments file. +// Look for user fragments file %include // Octave fragments for primitive types %include -// Octave fragments for char* strings -//%include - - #ifndef SWIG_DIRECTOR_TYPEMAPS #define SWIG_DIRECTOR_TYPEMAPS #endif // Octave types -#define SWIG_Object octave_value -#define VOID_Object octave_value() +#define SWIG_Object octave_value +#define VOID_Object octave_value() -/* // Octave allows implicit conversion -#define %implicitconv_flag $implicitconv -*/ +//#define %implicitconv_flag $implicitconv -// append output -#define SWIG_AppendOutput(result, obj) SWIG_Octave_AppendOutput(result, obj) +// Append output +#define SWIG_AppendOutput(result, obj) SWIG_Octave_AppendOutput(result, obj) -// set constant -#define SWIG_SetConstant(name, obj) SWIG_Octave_SetConstant(module_ns,name,obj) +// Set constant +#define SWIG_SetConstant(name, obj) SWIG_Octave_SetConstant(module_ns,name,obj) -// raise -#define SWIG_Octave_Raise(OBJ, TYPE, DESC) error("C++ side threw an exception of type " TYPE) -#define SWIG_Raise(obj, type, desc) SWIG_Octave_Raise(obj, type, desc) +// Raise errors +#define SWIG_Octave_Raise(OBJ, TYPE, DESC) error("C++ side threw an exception of type " TYPE) +#define SWIG_Raise(obj, type, desc) SWIG_Octave_Raise(obj, type, desc) // Include the unified typemap library %include +// Typechecks for Octave types %typecheck(SWIG_TYPECHECK_SWIGOBJECT) SWIG_Object "$1 = (*$input).is_defined();"; %typecheck(SWIG_TYPECHECK_SWIGOBJECT) octave_value_list "$1 = true;"; +// Typemaps for Octave types %typemap(in) (octave_value_list varargs,...) { for (int j=$argnum-1;jappend($1); } @@ -70,23 +67,3 @@ %typemap(out,noblock=1) Cell { $result=$1; } - -/* -// Smart Pointers -%typemap(out,noblock=1) const SWIGTYPE & SMARTPOINTER { - $result = SWIG_NewPointerObj(%new_copy(*$1, $*ltype), $descriptor, SWIG_POINTER_OWN | %newpointer_flags); -} - -%typemap(ret) const SWIGTYPE & SMARTPOINTER, SWIGTYPE SMARTPOINTER { - octave_swig_type* lobj=Swig::swig_value_deref($result); - if (lobj) { - std::list idx; - idx.push_back(octave_value("__deref__")); - idx.push_back(octave_value_list()); - octave_value_list ovl(lobj->subsref(".(",idx)); - octave_swig_type* robj=ovl.length()>=1?Swig::swig_value_deref(ovl(0)):0; - if (robj && !error_state) - lobj->append(robj); - } -} -*/ diff --git a/Lib/octave/octuserdir.swg b/Lib/octave/octuserdir.swg index ebb11b3a5..164e08a36 100644 --- a/Lib/octave/octuserdir.swg +++ b/Lib/octave/octuserdir.swg @@ -1,70 +1,65 @@ -/* ------------------------------------------------------------------------- - * Special user directives - * ------------------------------------------------------------------------- */ +// +// octuserdir.swg - Octave special user directives +// -/* ------------------------------------------------------------------------- */ -/* - Implicit Conversion using the C++ constructor mechanism -*/ +// Document string directive +#define %docstring %feature("docstring") -#define %implicitconv %feature("implicitconv") +// Implicit conversion using the C++ constructor mechanism +#define %implicitconv %feature("implicitconv") #define %noimplicitconv %feature("implicitconv", "0") #define %clearimplicitconv %feature("implicitconv", "") - -/* ------------------------------------------------------------------------- */ -/* - %extend_smart_pointer extend the smart pointer support. - - For example, if you have a smart pointer as: - - template class RCPtr { - public: - ... - RCPtr(Type *p); - Type * operator->() const; - ... - }; - - you use the %extend_smart_pointer directive as: - - %extend_smart_pointer(RCPtr); - %template(RCPtr_A) RCPtr; - - then, if you have something like: - - RCPtr make_ptr(); - int foo(A *); - - you can do the following: - - a = make_ptr(); - b = foo(a); - - ie, swig will accept a RCPtr object where a 'A *' is - expected. - - Also, when using vectors - - %extend_smart_pointer(RCPtr); - %template(RCPtr_A) RCPtr; - %template(vector_A) std::vector >; - - you can type - - a = A(); - v = vector_A(2) - v[0] = a - - ie, an 'A *' object is accepted, via implicit conversion, - where a RCPtr object is expected. Additionally - - x = v[0] - - returns (and sets 'x' as) a copy of v[0], making reference - counting possible and consistent. -*/ - +// %extend_smart_pointer: extend the smart pointer support. +// +// For example, if you have a smart pointer as: +// +// template class RCPtr { +// public: +// ... +// RCPtr(Type *p); +// Type * operator->() const; +// ... +// }; +// +// you use the %extend_smart_pointer directive as: +// +// %extend_smart_pointer(RCPtr); +// %template(RCPtr_A) RCPtr; +// +// then, if you have something like: +// +// RCPtr make_ptr(); +// int foo(A *); +// +// you can do the following: +// +// a = make_ptr(); +// b = foo(a); +// +// ie, swig will accept a RCPtr object where a 'A *' is +// expected. +// +// Also, when using vectors +// +// %extend_smart_pointer(RCPtr); +// %template(RCPtr_A) RCPtr; +// %template(vector_A) std::vector >; +// +// you can type +// +// a = A(); +// v = vector_A(2) +// v[0] = a +// +// ie, an 'A *' object is accepted, via implicit conversion, +// where a RCPtr object is expected. Additionally +// +// x = v[0] +// +// returns (and sets 'x' as) a copy of v[0], making reference +// counting possible and consistent. +// %define %extend_smart_pointer(Type...) %implicitconv Type; %apply const SWIGTYPE& SMARTPOINTER { const Type& }; diff --git a/Lib/octave/std_alloc.i b/Lib/octave/std_alloc.i index 35dc051be..1013e6829 100644 --- a/Lib/octave/std_alloc.i +++ b/Lib/octave/std_alloc.i @@ -1 +1,5 @@ +// +// std_alloc.i - STL allocator support +// + %include diff --git a/Lib/octave/std_basic_string.i b/Lib/octave/std_basic_string.i index 19712e8d0..113e10826 100644 --- a/Lib/octave/std_basic_string.i +++ b/Lib/octave/std_basic_string.i @@ -1,4 +1,8 @@ -#if !defined(SWIG_STD_STRING) +// +// std_basic_string.i - STL string support +// + +#if !defined(SWIG_STD_STRING) #define SWIG_STD_BASIC_STRING #define SWIG_STD_MODERN_STL @@ -6,28 +10,25 @@ #define %swig_basic_string(Type...) %swig_sequence_methods_val(Type) - -%fragment(SWIG_AsPtr_frag(std::basic_string),"header", - fragment="SWIG_AsCharPtrAndSize") { -SWIGINTERN int -SWIG_AsPtr(std::basic_string)(octave_value obj, std::string **val) +%fragment(SWIG_AsPtr_frag(std::basic_string), "header", fragment = "SWIG_AsCharPtrAndSize") { - if (obj.is_string()) { - if (val) - *val = new std::string(obj.string_value()); - return SWIG_NEWOBJ; + SWIGINTERN int SWIG_AsPtr(std::basic_string)(octave_value obj, std::string** val) { + if (obj.is_string()) { + if (val) { + *val = new std::string(obj.string_value()); + } + return SWIG_NEWOBJ; + } + if (val) { + error("a string is expected"); + } + return 0; } - if (val) - error("a string is expected"); - return 0; -} } -%fragment(SWIG_From_frag(std::basic_string),"header", - fragment="SWIG_FromCharPtrAndSize") { -SWIGINTERNINLINE octave_value - SWIG_From(std::basic_string)(const std::string& s) - { +%fragment(SWIG_From_frag(std::basic_string), "header", fragment = "SWIG_FromCharPtrAndSize") +{ + SWIGINTERNINLINE octave_value SWIG_From(std::basic_string)(const std::string & s) { return SWIG_FromCharPtrAndSize(s.data(), s.size()); } } @@ -35,51 +36,54 @@ SWIGINTERNINLINE octave_value %ignore std::basic_string::operator +=; %include + %typemaps_asptrfromn(%checkcode(STRING), std::basic_string); #endif - #if !defined(SWIG_STD_WSTRING) -%fragment(SWIG_AsPtr_frag(std::basic_string),"header", - fragment="SWIG_AsWCharPtrAndSize") { -SWIGINTERN int - SWIG_AsPtr(std::basic_string)(PyObject* obj, std::wstring **val) - { - static swig_type_info* string_info = - SWIG_TypeQuery("std::basic_string *"); - std::wstring *vptr; - if (SWIG_ConvertPtr(obj, (void**)&vptr, string_info, 0) == SWIG_OK) { - if (val) *val = vptr; +%fragment(SWIG_AsPtr_frag(std::basic_string), "header", fragment = "SWIG_AsWCharPtrAndSize") +{ + SWIGINTERN int SWIG_AsPtr(std::basic_string)(PyObject * obj, std::wstring** val) { + static swig_type_info* string_info = SWIG_TypeQuery("std::basic_string *"); + std::wstring* vptr; + if (SWIG_ConvertPtr(obj, (void**) &vptr, string_info, 0) == SWIG_OK) { + if (val) { + *val = vptr; + } return SWIG_OLDOBJ; } else { PyErr_Clear(); - wchar_t *buf = 0 ; size_t size = 0; int alloc = 0; + wchar_t* buf = 0 ; + size_t size = 0; + int alloc = 0; if (SWIG_AsWCharPtrAndSize(obj, &buf, &size, &alloc) == SWIG_OK) { - if (buf) { - if (val) *val = new std::wstring(buf, size - 1); - if (alloc == SWIG_NEWOBJ) %delete_array(buf); - return SWIG_NEWOBJ; - } + if (buf) { + if (val) { + *val = new std::wstring(buf, size - 1); + } + if (alloc == SWIG_NEWOBJ) { + %delete_array(buf); + } + return SWIG_NEWOBJ; + } } else { - PyErr_Clear(); - } + PyErr_Clear(); + } if (val) { - SWIG_PYTHON_THREAD_BEGIN_BLOCK; - PyErr_SetString(PyExc_TypeError,"a wstring is expected"); - SWIG_PYTHON_THREAD_END_BLOCK; + SWIG_PYTHON_THREAD_BEGIN_BLOCK; + PyErr_SetString(PyExc_TypeError, "a wstring is expected"); + SWIG_PYTHON_THREAD_END_BLOCK; } return 0; } } } -%fragment(SWIG_From_frag(std::basic_string),"header", - fragment="SWIG_FromWCharPtrAndSize") { -SWIGINTERNINLINE PyObject* - SWIG_From(std::basic_string)(const std::wstring& s) - { +%fragment(SWIG_From_frag(std::basic_string), "header", fragment = "SWIG_FromWCharPtrAndSize") +{ + SWIGINTERNINLINE PyObject* SWIG_From(std::basic_string)(const std::wstring & s) { return SWIG_FromWCharPtrAndSize(s.data(), s.size()); } } diff --git a/Lib/octave/std_carray.i b/Lib/octave/std_carray.i index e69de29bb..dcf317e80 100644 --- a/Lib/octave/std_carray.i +++ b/Lib/octave/std_carray.i @@ -0,0 +1,3 @@ +// +// std_carray.i +// diff --git a/Lib/octave/std_char_traits.i b/Lib/octave/std_char_traits.i index bf4e6c47d..d05f7b42c 100644 --- a/Lib/octave/std_char_traits.i +++ b/Lib/octave/std_char_traits.i @@ -1 +1,5 @@ +// +// std_char_traits.i - STL character traits +// + %include diff --git a/Lib/octave/std_common.i b/Lib/octave/std_common.i index 9aebf7f45..ebefc5942 100644 --- a/Lib/octave/std_common.i +++ b/Lib/octave/std_common.i @@ -1,72 +1,82 @@ +// +// std_common.i - Common STL support code +// + %include %include - // Generate the traits for a 'primitive' type, such as 'double', // for which the SWIG_AsVal and SWIG_From methods are already defined. - %define %traits_ptypen(Type...) - %fragment(SWIG_Traits_frag(Type),"header", - fragment=SWIG_AsVal_frag(Type), - fragment=SWIG_From_frag(Type), - fragment="StdTraits") { -namespace swig { - template <> struct traits { - typedef value_category category; - static const char* type_name() { return #Type; } - }; - template <> struct traits_asval { - typedef Type value_type; - static int asval(octave_value obj, value_type *val) { - return SWIG_AsVal(Type)(obj, val); - } - }; - template <> struct traits_from { - typedef Type value_type; - static octave_value from(const value_type& val) { - return SWIG_From(Type)(val); - } - }; -} +%fragment(SWIG_Traits_frag(Type), "header", fragment = SWIG_AsVal_frag(Type), fragment = SWIG_From_frag(Type), fragment = "StdTraits") +{ + + namespace swig + { + + template <> struct traits { + typedef value_category category; + static const char* type_name() { + return #Type; } + }; + + template <> struct traits_asval { + typedef Type value_type; + static int asval(octave_value obj, value_type* val) { + return SWIG_AsVal(Type)(obj, val); + } + }; + + template <> struct traits_from { + typedef Type value_type; + static octave_value from(const value_type& val) { + return SWIG_From(Type)(val); + } + }; + + } + } %enddef -/* Traits for enums. This is bit of a sneaky trick needed because a generic template specialization of enums - is not possible (unless using template meta-programming which SWIG doesn't support because of the explicit - instantiations required using %template). The STL containers define the 'front' method and the typemap - below is used whenever the front method is wrapped returning an enum. This typemap simply picks up the - standard enum typemap, but additionally drags in a fragment containing the traits_asval and traits_from - required in the generated code for enums. */ +// Traits for enums. This is bit of a sneaky trick needed because a generic template specialization of enums +// is not possible (unless using template meta-programming which SWIG doesn't support because of the explicit +// instantiations required using %template). The STL containers define the 'front' method and the typemap +// below is used whenever the front method is wrapped returning an enum. This typemap simply picks up the +// standard enum typemap, but additionally drags in a fragment containing the traits_asval and traits_from +// required in the generated code for enums. %define %traits_enum(Type...) - %fragment("SWIG_Traits_enum_"{Type},"header", - fragment=SWIG_AsVal_frag(int), - fragment=SWIG_From_frag(int), - fragment="StdTraits") { -namespace swig { - template <> struct traits_asval { - typedef Type value_type; - static int asval(octave_value obj, value_type *val) { - return SWIG_AsVal(int)(obj, (int *)val); - } - }; - template <> struct traits_from { - typedef Type value_type; - static octave_value from(const value_type& val) { - return SWIG_From(int)((int)val); - } - }; -} +%fragment("SWIG_Traits_enum_" {Type}, "header", fragment = SWIG_AsVal_frag(int), fragment = SWIG_From_frag(int), fragment = "StdTraits") { + + namespace swig + { + + template <> struct traits_asval { + typedef Type value_type; + static int asval(octave_value obj, value_type* val) { + return SWIG_AsVal(int)(obj, (int*) val); + } + }; + + template <> struct traits_from { + typedef Type value_type; + static octave_value from(const value_type& val) { + return SWIG_From(int)((int) val); + } + }; + + } + } -%typemap(out, fragment="SWIG_Traits_enum_"{Type}) const enum SWIGTYPE& front %{$typemap(out, const enum SWIGTYPE&)%} -%enddef +%typemap(out, fragment = "SWIG_Traits_enum_" {Type}) const enum SWIGTYPE& front %{ + $typemap(out, const enum SWIGTYPE&) +%} + +%enddef %include -// -// Generates the traits for all the known primitive -// C++ types (int, double, ...) -// +// Generates the traits for all the known primitive C++ types (int, double, ...) %apply_cpptypes(%traits_ptypen); - diff --git a/Lib/octave/std_complex.i b/Lib/octave/std_complex.i index 771728b9d..0b4627078 100644 --- a/Lib/octave/std_complex.i +++ b/Lib/octave/std_complex.i @@ -1,22 +1,17 @@ -/* - * STD C++ complex typemaps - */ +// +// std_complex.i - STL complex typemaps +// %include -%{ -#include +%header %{ +#include %} -/* defining the complex as/from converters */ - +// Define the complex as/from converters %swig_cplxdbl_convn(std::complex, std::complex, std::real, std::imag) %swig_cplxflt_convn(std::complex, std::complex, std::real, std::imag) -/* defining the typemaps */ - +// Define the typemaps %typemaps_primitive(%checkcode(CPLXDBL), std::complex); %typemaps_primitive(%checkcode(CPLXFLT), std::complex); - - - diff --git a/Lib/octave/std_container.i b/Lib/octave/std_container.i index cab76452b..80abeb768 100644 --- a/Lib/octave/std_container.i +++ b/Lib/octave/std_container.i @@ -1,2 +1,6 @@ +// +// std_container.i - STL container support +// + %include %include diff --git a/Lib/octave/std_deque.i b/Lib/octave/std_deque.i index 6866a610f..d5eb67db8 100644 --- a/Lib/octave/std_deque.i +++ b/Lib/octave/std_deque.i @@ -1,22 +1,29 @@ -// Deques +// +// std_deque.i - STL deque support +// -%fragment("StdDequeTraits","header",fragment="StdSequenceTraits") +%fragment("StdDequeTraits", "header", fragment = "StdSequenceTraits") %{ - namespace swig { + + namespace swig + { + template struct traits_asptr > { - static int asptr(octave_value obj, std::deque **vec) { - return traits_asptr_stdseq >::asptr(obj, vec); + static int asptr(octave_value obj, std::deque **vec) { + return traits_asptr_stdseq >::asptr(obj, vec); } }; template struct traits_from > { static octave_value from(const std::deque & vec) { - return traits_from_stdseq >::from(vec); + return traits_from_stdseq >::from(vec); } }; + } + %} #define %swig_deque_methods(Type...) %swig_sequence_methods(Type) diff --git a/Lib/octave/std_except.i b/Lib/octave/std_except.i index af98428f6..1f2987004 100644 --- a/Lib/octave/std_except.i +++ b/Lib/octave/std_except.i @@ -1 +1,5 @@ +// +// std_except.i - STL exception support +// + %include diff --git a/Lib/octave/std_list.i b/Lib/octave/std_list.i index 1421efaee..580d7d312 100644 --- a/Lib/octave/std_list.i +++ b/Lib/octave/std_list.i @@ -1,26 +1,32 @@ -// Lists +// +// std_list.i - STL list support +// -%fragment("StdListTraits","header",fragment="StdSequenceTraits") +%fragment("StdListTraits", "header", fragment = "StdSequenceTraits") %{ - namespace swig { + + namespace swig + { + template struct traits_asptr > { static int asptr(const octave_value& obj, std::list **lis) { - return traits_asptr_stdseq >::asptr(obj, lis); + return traits_asptr_stdseq >::asptr(obj, lis); } }; template struct traits_from > { - static octave_value *from(const std::list & vec) { - return traits_from_stdseq >::from(vec); + static octave_value* from(const std::list & vec) { + return traits_from_stdseq >::from(vec); } }; + } + %} #define %swig_list_methods(Type...) %swig_sequence_methods(Type) #define %swig_list_methods_val(Type...) %swig_sequence_methods_val(Type); %include - diff --git a/Lib/octave/std_map.i b/Lib/octave/std_map.i index 7b85a548e..259bdaec3 100644 --- a/Lib/octave/std_map.i +++ b/Lib/octave/std_map.i @@ -1,156 +1,125 @@ -// Maps +// +// std_map.i - STL map support +// %include -%fragment("StdMapCommonTraits","header",fragment="StdSequenceTraits") +%fragment("StdMapCommonTraits", "header", fragment = "StdSequenceTraits") { - namespace swig { + + namespace swig + { + template - struct from_key_oper - { + struct from_key_oper { typedef const ValueType& argument_type; typedef octave_value result_type; - result_type operator()(argument_type v) const - { - return swig::from(v.first); + result_type operator()(argument_type v) const { + return swig::from(v.first); } }; template - struct from_value_oper - { + struct from_value_oper { typedef const ValueType& argument_type; typedef octave_value result_type; - result_type operator()(argument_type v) const - { - return swig::from(v.second); + result_type operator()(argument_type v) const { + return swig::from(v.second); } }; template - struct OctMapIterator_T : OctSwigIteratorClosed_T - { + struct OctMapIterator_T : OctIteratorClosed_T { OctMapIterator_T(OutIterator curr, OutIterator first, OutIterator last, octave_value seq) - : OctSwigIteratorClosed_T(curr, first, last, seq) - { + : OctIteratorClosed_T (curr, first, last, seq) { } }; - template > - struct OctMapKeyIterator_T : OctMapIterator_T - { + template < class OutIterator, class FromOper = from_key_oper > + struct OctMapKeyIterator_T : OctMapIterator_T { OctMapKeyIterator_T(OutIterator curr, OutIterator first, OutIterator last, octave_value seq) - : OctMapIterator_T(curr, first, last, seq) - { + : OctMapIterator_T (curr, first, last, seq) { } }; template - inline OctSwigIterator* - make_output_key_iterator(const OutIter& current, const OutIter& begin, const OutIter& end, octave_value seq = octave_value()) + inline OctIterator* make_output_key_iterator(const OutIter& current, const OutIter& begin, const OutIter& end, octave_value seq = octave_value()) { - return new OctMapKeyIterator_T(current, begin, end, seq); + return new OctMapKeyIterator_T (current, begin, end, seq); } - template > - struct OctMapValueIterator_T : OctMapIterator_T - { + template < class OutIterator, class FromOper = from_value_oper > + struct OctMapValueIterator_T : OctMapIterator_T { OctMapValueIterator_T(OutIterator curr, OutIterator first, OutIterator last, octave_value seq) - : OctMapIterator_T(curr, first, last, seq) - { + : OctMapIterator_T (curr, first, last, seq) { } }; - + template - inline OctSwigIterator* + inline OctIterator* make_output_value_iterator(const OutIter& current, const OutIter& begin, const OutIter& end, octave_value seq = 0) { - return new OctMapValueIterator_T(current, begin, end, seq); + return new OctMapValueIterator_T (current, begin, end, seq); } + } + } -%fragment("StdMapTraits","header",fragment="StdMapCommonTraits") +%fragment("StdMapTraits", "header", fragment = "StdMapCommonTraits") { - namespace swig { + + namespace swig + { + template inline void - assign(const OctSeq& octseq, std::map *map) { - typedef typename std::map::value_type value_type; + assign(const OctSeq& octseq, std::map *map) + { + typedef typename std::map::value_type value_type; typename OctSeq::const_iterator it = octseq.begin(); - for (;it != octseq.end(); ++it) { - map->insert(value_type(it->first, it->second)); + for (; it != octseq.end(); ++it) { + map->insert(value_type(it->first, it->second)); } } template - struct traits_asptr > { - typedef std::map map_type; - static int asptr(octave_value obj, map_type **val) { - /* - int res = SWIG_ERROR; - if (PyDict_Check(obj)) { - SwigVar_PyObject items = PyObject_CallMethod(obj,(char *)"items",NULL); - res = traits_asptr_stdseq, std::pair >::asptr(items, val); - } else { - map_type *p; - res = SWIG_ConvertPtr(obj,(void**)&p,swig::type_info(),0); - if (SWIG_IsOK(res) && val) *val = p; - } - return res; - */ - return SWIG_ERROR; - } + struct traits_asptr > { + + typedef std::map map_type; + static int asptr(octave_value obj, map_type** val) { + // * todo + return SWIG_ERROR; + } + }; - + template - struct traits_from > { - typedef std::map map_type; + struct traits_from > { + typedef std::map map_type; typedef typename map_type::const_iterator const_iterator; typedef typename map_type::size_type size_type; - + static octave_value from(const map_type& map) { - /* - swig_type_info *desc = swig::type_info(); - if (desc && desc->clientdata) { - return SWIG_NewPointerObj(new map_type(map), desc, SWIG_POINTER_OWN); - } else { - size_type size = map.size(); - int pysize = (size <= (size_type) INT_MAX) ? (int) size : -1; - if (pysize < 0) { - SWIG_PYTHON_THREAD_BEGIN_BLOCK; - PyErr_SetString(PyExc_OverflowError, - "map size not valid in python"); - SWIG_PYTHON_THREAD_END_BLOCK; - return NULL; - } - PyObject *obj = PyDict_New(); - for (const_iterator i= map.begin(); i!= map.end(); ++i) { - swig::SwigVar_PyObject key = swig::from(i->first); - swig::SwigVar_PyObject val = swig::from(i->second); - PyDict_SetItem(obj, key, val); - } - return obj; - } - */ - return octave_value(); + // * todo + return octave_value(); } + }; + } + } %define %swig_map_common(Map...) - %swig_sequence_iterator(Map); - %swig_container_methods(Map); +%swig_sequence_iterator(Map); +%swig_container_methods(Map); %enddef %define %swig_map_methods(Map...) - %swig_map_common(Map) +%swig_map_common(Map) %enddef - %include diff --git a/Lib/octave/std_pair.i b/Lib/octave/std_pair.i index ab028d144..ac2384714 100644 --- a/Lib/octave/std_pair.i +++ b/Lib/octave/std_pair.i @@ -1,129 +1,145 @@ -// Pairs +// +// std_pair.i - STL pair support +// %include //#define SWIG_STD_PAIR_ASVAL -%fragment("StdPairTraits","header",fragment="StdTraits") { - namespace swig { +%fragment("StdPairTraits", "header", fragment = "StdTraits") +{ + namespace swig + { + #ifdef SWIG_STD_PAIR_ASVAL + template - struct traits_asval > { - typedef std::pair value_type; - - static int get_pair(const octave_value& first, octave_value second, - std::pair *val) - { - if (val) { - T *pfirst = &(val->first); - int res1 = swig::asval(first, pfirst); - if (!SWIG_IsOK(res1)) - return res1; - U *psecond = &(val->second); - int res2 = swig::asval(second, psecond); - if (!SWIG_IsOK(res2)) - return res2; - return res1 > res2 ? res1 : res2; - } else { - T *pfirst = 0; - int res1 = swig::asval(first, pfirst); - if (!SWIG_IsOK(res1)) - return res1; - U *psecond = 0; - int res2 = swig::asval((PyObject*)second, psecond); - if (!SWIG_IsOK(res2)) - return res2; - return res1 > res2 ? res1 : res2; - } + struct traits_asval > { + + typedef std::pair value_type; + + static int get_pair(const octave_value& first, octave_value second, std::pair *val) { + if (val) { + T* pfirst = & (val->first); + int res1 = swig::asval(first, pfirst); + if (!SWIG_IsOK(res1)) { + return res1; + } + U* psecond = & (val->second); + int res2 = swig::asval(second, psecond); + if (!SWIG_IsOK(res2)) { + return res2; + } + return res1 > res2 ? res1 : res2; + } else { + T* pfirst = 0; + int res1 = swig::asval(first, pfirst); + if (!SWIG_IsOK(res1)) { + return res1; + } + U* psecond = 0; + int res2 = swig::asval((PyObject*) second, psecond); + if (!SWIG_IsOK(res2)) { + return res2; + } + return res1 > res2 ? res1 : res2; + } } - static int asval(const octave_value& obj, std::pair *val) { - if (obj.is_cell()) { - Cell c=obj.cell_value(); - if (c.numel()<2) { - error("pair from Cell array requires at least two elements"); - return SWIG_ERROR; - } - return get_pair(c(0),c(1),val); - } else { - value_type *p; - int res = SWIG_ConvertPtr(obj,(void**)&p,swig::type_info(),0); - if (SWIG_IsOK(res) && val) - *val = *p; - return res; - } - return SWIG_ERROR; + static int asval(const octave_value& obj, std::pair *val) { + if (obj.is_cell()) { + Cell c = obj.cell_value(); + if (c.numel() < 2) { + error("pair from Cell array requires at least two elements"); + return SWIG_ERROR; + } + return get_pair(c(0), c(1), val); + } else { + value_type* p; + int res = SWIG_ConvertPtr(obj, (void**) &p, swig::type_info(), 0); + if (SWIG_IsOK(res) && val) { + *val = *p; + } + return res; + } + return SWIG_ERROR; } }; #else + template - struct traits_asptr > { - typedef std::pair value_type; - - static int get_pair(const octave_value& first, octave_value second, - std::pair **val) - { - if (val) { - value_type *vp = %new_instance(std::pair); - T *pfirst = &(vp->first); - int res1 = swig::asval(first, pfirst); - if (!SWIG_IsOK(res1)) - return res1; - U *psecond = &(vp->second); - int res2 = swig::asval(second, psecond); - if (!SWIG_IsOK(res2)) - return res2; - *val = vp; - return SWIG_AddNewMask(res1 > res2 ? res1 : res2); - } else { - T *pfirst = 0; - int res1 = swig::asval(first, pfirst); - if (!SWIG_IsOK(res1)) - return res1; - U *psecond = 0; - int res2 = swig::asval(second, psecond); - if (!SWIG_IsOK(res2)) - return res2; - return res1 > res2 ? res1 : res2; - } - return SWIG_ERROR; + struct traits_asptr > { + typedef std::pair value_type; + + static int get_pair(const octave_value& first, octave_value second, std::pair **val) { + if (val) { + value_type* vp = %new_instance(std::pair); + T* pfirst = & (vp->first); + int res1 = swig::asval(first, pfirst); + if (!SWIG_IsOK(res1)) { + return res1; + } + U* psecond = & (vp->second); + int res2 = swig::asval(second, psecond); + if (!SWIG_IsOK(res2)) { + return res2; + } + *val = vp; + return SWIG_AddNewMask(res1 > res2 ? res1 : res2); + } else { + T* pfirst = 0; + int res1 = swig::asval(first, pfirst); + if (!SWIG_IsOK(res1)) { + return res1; + } + U* psecond = 0; + int res2 = swig::asval(second, psecond); + if (!SWIG_IsOK(res2)) { + return res2; + } + return res1 > res2 ? res1 : res2; + } + return SWIG_ERROR; } - static int asptr(const octave_value& obj, std::pair **val) { - if (obj.is_cell()) { - Cell c=obj.cell_value(); - if (c.numel()<2) { - error("pair from Cell array requires at least two elements"); - return SWIG_ERROR; - } - return get_pair(c(0),c(1),val); - } else { - value_type *p; - int res = SWIG_ConvertPtr(obj,(void**)&p,swig::type_info(),0); - if (SWIG_IsOK(res) && val) - *val = p; - return res; - } - return SWIG_ERROR; + static int asptr(const octave_value& obj, std::pair **val) { + if (obj.is_cell()) { + Cell c = obj.cell_value(); + if (c.numel() < 2) { + error("pair from Cell array requires at least two elements"); + return SWIG_ERROR; + } + return get_pair(c(0), c(1), val); + } else { + value_type* p; + int res = SWIG_ConvertPtr(obj, (void**) &p, swig::type_info(), 0); + if (SWIG_IsOK(res) && val) { + *val = p; + } + return res; + } + return SWIG_ERROR; } }; #endif + template - struct traits_from > { - static octave_value from(const std::pair& val) { - Cell c(1,2); - c(0)=swig::from(val.first); - c(1)=swig::from(val.second); - return c; + struct traits_from > { + static octave_value from(const std::pair& val) { + Cell c(1, 2); + c(0) = swig::from(val.first); + c(1) = swig::from(val.second); + return c; } }; + } + } %define %swig_pair_methods(pair...) %enddef %include - diff --git a/Lib/octave/std_string.i b/Lib/octave/std_string.i index dc1378ae6..e9ad572e0 100644 --- a/Lib/octave/std_string.i +++ b/Lib/octave/std_string.i @@ -1 +1,5 @@ +// +// std_string.i - STL string support +// + %include diff --git a/Lib/octave/std_vector.i b/Lib/octave/std_vector.i index 2862b5e77..386aea2a4 100644 --- a/Lib/octave/std_vector.i +++ b/Lib/octave/std_vector.i @@ -1,19 +1,21 @@ -// Vectors +// +// std_vector.i - STL vector support +// -%fragment("StdVectorTraits","header",fragment="StdSequenceTraits") +%fragment("StdVectorTraits", "header", fragment = "StdSequenceTraits") %{ namespace swig { template struct traits_asptr > { static int asptr(const octave_value& obj, std::vector **vec) { - return traits_asptr_stdseq >::asptr(obj, vec); + return traits_asptr_stdseq >::asptr(obj, vec); } }; - + template struct traits_from > { static octave_value from(const std::vector& vec) { - return traits_from_stdseq >::from(vec); + return traits_from_stdseq >::from(vec); } }; } @@ -23,4 +25,3 @@ #define %swig_vector_methods_val(Type...) %swig_sequence_methods_val(Type); %include - diff --git a/Lib/octave/stl.i b/Lib/octave/stl.i index b29f7d84d..83714cb8f 100644 --- a/Lib/octave/stl.i +++ b/Lib/octave/stl.i @@ -1,4 +1,7 @@ -/* initial STL definition. extended as needed in each language */ +// +// stl.i - STL support +// + %include %include %include diff --git a/Lib/octave/typemaps.i b/Lib/octave/typemaps.i index 1f9b9c432..c093399ed 100644 --- a/Lib/octave/typemaps.i +++ b/Lib/octave/typemaps.i @@ -1 +1,5 @@ +// +// typemaps.i - Standard typemaps +// + %include diff --git a/Source/Modules/octave.cxx b/Source/Modules/octave.cxx index 3ec60c31d..ec54e8b99 100644 --- a/Source/Modules/octave.cxx +++ b/Source/Modules/octave.cxx @@ -205,8 +205,8 @@ public: Printf(f_runtime, "\n"); - Printf(s_global_tab, "\nstatic const struct swig_octave_member swig_globals[] = {\n"); - Printf(f_init, "static bool SWIG_init_user(octave_swig_type* module_ns)\n{\n"); + Printf(s_global_tab, "\nstatic const struct SwigOctMember swig_globals[] = {\n"); + Printf(f_init, "SWIGINTERN bool SWIG_Octave_InitUser(SwigOctType* module_ns)\n{\n"); if (!CPlusPlus) { Printf(f_header, "extern \"C\" {\n"); @@ -222,10 +222,6 @@ public: emit_doc_texinfo(); } - if (directorsEnabled()) { - Swig_insert_file("director.swg", f_runtime); - } - Printf(f_init, "return true;\n}\n"); Printf(s_global_tab, "{0,0,0,0,0}\n};\n"); @@ -590,7 +586,7 @@ public: int varargs = emit_isvarargs(l); char source[64]; - Printf(w->code, "if (!SWIG_check_num_args(\"%s\",args.length(),%i,%i,%i)) " + Printf(w->code, "if (!SWIG_Octave_CheckNumArgs(\"%s\",args.length(),%i,%i,%i)) " "{\n SWIG_fail;\n }\n", iname, num_arguments, num_required, varargs); if (constructor && num_arguments == 1 && num_required == 1) { @@ -811,9 +807,9 @@ public: Octave_begin_function(n, w->def, iname, wname, true); Wrapper_add_local(w, "argc", "int argc = args.length()"); - Printf(tmp, "octave_value_ref argv[%d]={", maxargs); + Printf(tmp, "SwigOctValueRef argv[%d] = {", maxargs); for (int j = 0; j < maxargs; ++j) { - Printf(tmp, "%soctave_value_ref(args,%d)", j ? "," : " ", j); + Printf(tmp, "%sSwigOctValueRef(args,%d)", j ? "," : " ", j); } Printf(tmp, "}"); Wrapper_add_local(w, "argv", tmp); @@ -849,7 +845,7 @@ public: String* setwname = Swig_name_wrapper(setname); Octave_begin_function(n, setw->def, setname, setwname, true); - Printf(setw->def, "if (!SWIG_check_num_args(\"%s_set\",args.length(),1,1,0)) return octave_value_list();", iname); + Printf(setw->def, "if (!SWIG_Octave_CheckNumArgs(\"%s_set\",args.length(),1,1,0)) return octave_value_list();", iname); if (is_assignable(n)) { Setattr(n, "wrap:name", setname); if ((tm = Swig_typemap_lookup("varin", n, name, 0))) { @@ -867,7 +863,7 @@ public: Append(setw->code, "fail:\n"); Printf(setw->code, "return octave_value_list();\n"); } else { - Printf(setw->code, "return octave_set_immutable(args,nargout);"); + Printf(setw->code, "return SWIG_Octave_SetImmutable(args,nargout);"); } Append(setw->code, "}\n"); Wrapper_print(setw, f_wrappers); @@ -977,7 +973,7 @@ public: assert(!s_members_tab); s_members_tab = NewStringEmpty(); - Printv(s_members_tab, "static swig_octave_member swig_", class_name, "_members[] = {\n", NIL); + Printv(s_members_tab, "static SwigOctMember swig_", class_name, "_members[] = {\n", NIL); Language::classHandler(n); @@ -1037,7 +1033,7 @@ public: Printv(f_wrappers, "static const char *swig_", class_name, "_base_names[] = {", base_class_names, "0};\n", NIL); Printv(f_wrappers, "static const swig_type_info *swig_", class_name, "_base[] = {", base_class, "0};\n", NIL); - Printv(f_wrappers, "static swig_octave_class _wrap_class_", class_name, " = {\"", class_name, "\", &SWIGTYPE", SwigType_manglestr(t), ",", NIL); + Printv(f_wrappers, "static SwigOctClass _wrap_class_", class_name, " = {\"", class_name, "\", &SWIGTYPE", SwigType_manglestr(t), ",", NIL); Printv(f_wrappers, Swig_directorclass(n) ? "1," : "0,", NIL); if (have_constructor) { String* nspace = Getattr(n, "sym:nspace"); @@ -1111,7 +1107,7 @@ public: String* getname = Swig_name_get(NSPACE_TODO, Swig_name_member(NSPACE_TODO, class_name, symname)); String* setname = Swig_name_set(NSPACE_TODO, Swig_name_member(NSPACE_TODO, class_name, symname)); String* getwname = Swig_name_wrapper(getname); - String* setwname = GetFlag(n, "feature:immutable") ? NewString("octave_set_immutable") : Swig_name_wrapper(setname); + String* setwname = GetFlag(n, "feature:immutable") ? NewString("SWIG_Octave_SetImmutable") : Swig_name_wrapper(setname); assert(s_members_tab); Printf(s_members_tab, "{\"%s\",0,%s,%s,0,0},\n", symname, getwname, setwname); @@ -1200,7 +1196,7 @@ public: String* getname = Swig_name_get(NSPACE_TODO, Swig_name_member(NSPACE_TODO, class_name, symname)); String* setname = Swig_name_set(NSPACE_TODO, Swig_name_member(NSPACE_TODO, class_name, symname)); String* getwname = Swig_name_wrapper(getname); - String* setwname = GetFlag(n, "feature:immutable") ? NewString("octave_set_immutable") : Swig_name_wrapper(setname); + String* setwname = GetFlag(n, "feature:immutable") ? NewString("SWIG_Octave_SetImmutable") : Swig_name_wrapper(setname); assert(s_members_tab); Printf(s_members_tab, "{\"%s\",0,%s,%s,1,0},\n", symname, getwname, setwname); @@ -1281,12 +1277,12 @@ public: { Wrapper* w = NewWrapper(); Printf(w->def, "SwigDirector_%s::SwigDirector_%s(void* self) :" - "\nSwig::Director((octave_swig_type*)self,static_cast<%s*>(this)) { \n", classname, classname, classname); + "\nSwig::Director((SwigOctType*)self,static_cast<%s*>(this)) { \n", classname, classname, classname); Append(w->def, "}\n"); Wrapper_print(w, f_directors); DelWrapper(w); } - Printf(f_directors_h, " SwigDirector_%s(octave_swig_type* self);\n", classname); + Printf(f_directors_h, " SwigDirector_%s(SwigOctType* self);\n", classname); Delete(classname); return Language::classDirectorDefaultConstructor(n); } @@ -1567,12 +1563,20 @@ public: String* runtimeCode() { String* s = NewStringEmpty(); - String* srun = Swig_include_sys("octrun.swg"); - if (!srun) { - Printf(stderr, "*** Unable to open 'octrun.swg'\n"); - } else { - Append(s, srun); - Delete(srun); + const char* runtimeFiles[] = { + "octrundecl.swg", + "octrunfunc.swg", + "octrunclass.swg", + "octruninit.swg" + }; + for (size_t i = 0; i < sizeof(runtimeFiles)/sizeof(runtimeFiles[0]); ++i) { + String* srun = Swig_include_sys(runtimeFiles[i]); + if (!srun) { + Printf(stderr, "*** Unable to open '%s'\n", runtimeFiles[i]); + } else { + Append(s, srun); + Delete(srun); + } } return s; } -- cgit v1.2.1 From 56fefcc7e0adb2a4a25a30280047c1d7c097454f Mon Sep 17 00:00:00 2001 From: Karl Wette Date: Sat, 4 Oct 2014 18:16:17 +0200 Subject: Octave: whitespace/style cleanup of Doc/Manual/Octave.html --- Doc/Manual/Octave.html | 453 ++++++++++++++++++++++++++++++++----------------- 1 file changed, 300 insertions(+), 153 deletions(-) diff --git a/Doc/Manual/Octave.html b/Doc/Manual/Octave.html index 9c3489fb8..e48083afd 100644 --- a/Doc/Manual/Octave.html +++ b/Doc/Manual/Octave.html @@ -5,7 +5,6 @@ -

    32 SWIG and Octave

    @@ -43,29 +42,29 @@ - -

    - Octave is a high-level language intended for numerical programming that is mostly compatible with MATLAB. -More information can be found at Octave web site. +Octave is a high-level language intended for numerical programming that is +mostly compatible with MATLAB. More information can be found +at Octave web site.

    - This chapter is intended to give an introduction to using the module. You should also read the SWIG documentation that is not specific to Octave. -Also, there are a dozen or so examples in the Examples/octave directory, and hundreds in the test suite (Examples/test-suite and Examples/test-suite/octave). +This chapter is intended to give an introduction to using the module. You +should also read the SWIG documentation that is not specific to Octave. Also, +there are a dozen or so examples in the Examples/octave directory, and hundreds +in the test suite (Examples/test-suite and Examples/test-suite/octave).

    32.1 Preliminaries

    -

    -As of SWIG 3.0.0, the Octave module has been tested with Octave versions 3.0.5, 3.2.4, 3.4.3, 3.6.4, and 3.8.0. -Use of Octave versions older than 3.x.x is not recommended, as these versions are no longer tested with SWIG. +As of SWIG 3.0.0, the Octave module has been tested with Octave versions 3.0.5, +3.2.4, 3.4.3, 3.6.4, and 3.8.0. Use of Octave versions older than 3.x.x is not +recommended, as these versions are no longer tested with SWIG.

    32.2 Running SWIG

    -

    Let's start with a very simple SWIG interface file, example.i:

    @@ -76,54 +75,67 @@ Let's start with a very simple SWIG interface file, example.i: #include "example.h" %} int gcd(int x, int y); -extern double Foo; +extern double Foo; +

    -To build an Octave module when wrapping C code, run SWIG using the -octave option: +To build an Octave module when wrapping C code, run swig using +the -octave option:

    -
    $ swig -octave -o example_wrap.cpp example.i 
    +
    +$ swig -octave -o example_wrap.cpp example.i
    +

    The -c++ option is also required when wrapping C++ code:

    - -
    $ swig -octave -c++ -o example_wrap.cpp example.i 
    +
    +$ swig -octave -c++ -o example_wrap.cpp example.i
    +

    -This creates a C++ source file "example_wrap.cpp". A C++ file is generated even when wrapping C code as Octave is itself written in C++ and requires wrapper code to be in the same language. The generated C++ source file contains the low-level wrappers that need to be compiled and linked with the rest of your C/C++ application (in this case, the gcd implementation) to create an extension module. +This creates a C++ source file example_wrap.cpp. A C++ file is +generated even when wrapping C code as Octave is itself written in C++ and +requires wrapper code to be in the same language. The generated C++ source file +contains the low-level wrappers that need to be compiled and linked with the +rest of your C/C++ application (in this case, the gcd implementation) to create +an extension module.

    32.2.1 Command-line options

    -

    -The swig command line has a number of options you can use, like to redirect its output. Use swig -help to learn about these. -Options specific to the Octave module are: +The swig command line has a number of options you can use, like to +redirect its output. Use swig -help to learn about these. Options +specific to the Octave module are:

    $ swig -octave -help
     ...
     Octave Options (available with -octave)
    -     -globals name - Set name used to access C global variables [default: 'cvar']
    -                     Use '.' to load C global variables into module namespace
    -     -opprefix str - Prefix str for global operator functions [default: 'op_']
    +     -globals <name> - Set <name> used to access C global variables [default: 'cvar']
    +		       Use '.' to load C global variables into module namespace
    +     -opprefix <str> - Prefix <str> for global operator functions [default: 'op_']
     

    -The -globals option sets the name of the variable which is the namespace for C global variables exported by the module. -The special name "." loads C global variables into the module namespace, i.e. alongside C functions and structs exported by the module. -The -opprefix options sets the prefix of the names of global/friend operator functions. +The -globals option sets the name of the variable which is the +namespace for C global variables exported by the module. The special +name . loads C global variables into the module namespace, +i.e. alongside C functions and structs exported by the module. +The -opprefix options sets the prefix of the names of +global/friend operator functions.

    32.2.2 Compiling a dynamic module

    -

    -Octave modules are DLLs/shared objects having the ".oct" suffix. -Building an oct file is usually done with the mkoctfile command (either within Octave itself, or from the shell). For example, +Octave modules are DLLs/shared objects having the .oct suffix. +Building an .oct file is usually done with the mkoctfile +command (either within Octave itself, or from the shell). For example,

    @@ -132,28 +144,30 @@ $ mkoctfile example_wrap.cpp example.c
     

    - where "example.c" is the file containing the gcd() implementation. +where example.c is the file containing the gcd() implementation.

    - mkoctfile can also be used to extract the build parameters required to invoke the compiler and linker yourself. See the Octave manual and mkoctfile man page. +mkoctfile can also be used to extract the build parameters required to +invoke the compiler and linker yourself. See the Octave manual +and mkoctfile man page.

    - mkoctfile will produce "swigexample.oct", which contains the compiled extension module. Loading it into Octave is then a matter of invoking +mkoctfile will produce swigexample.oct, which contains the +compiled extension module. Loading it into Octave is then a matter of invoking

    -
    octave:1> swigexample
    +
    octave:1> swigexample
    +

    32.2.3 Using your module

    -

    -Assuming all goes well, you will be able to do this: -
    +Assuming all goes well, you will be able to do this:

    -
    $ octave -q
    +
    $ octave -q
     octave:1> swigexample
     octave:2> swigexample.gcd(4,6)
     ans =  2
    @@ -161,20 +175,27 @@ octave:3> swigexample.cvar.Foo
     ans =  3
     octave:4> swigexample.cvar.Foo=4;
     octave:5> swigexample.cvar.Foo
    -ans =  4 
    +ans = 4 +

    32.3 A tour of basic C/C++ wrapping

    -

    32.3.1 Modules

    -

    -The SWIG module directive specifies the name of the Octave module. If you specify "module swigexample", then in Octave everything in the module will be accessible under "swigexample", as in the above example. When choosing a module name, make sure you don't use the same name as a built-in Octave command or standard module name. +The SWIG module directive specifies the name of the Octave module. If +you specify module swigexample, then in Octave everything in the module +will be accessible under swigexample, as in the above example. When +choosing a module name, make sure you don't use the same name as a built-in +Octave command or standard module name.

    -When Octave is asked to invoke swigexample, it will try to find the ".m" or ".oct" file that defines the function "swigexample". You therefore need to make sure that "swigexample.oct" is in Octave's search path, which can be specified with the environment variable "OCTAVE_PATH". +When Octave is asked to invoke swigexample, it will try to find +the .m or .oct file that defines the +function swigexample. You therefore need to make sure +that swigexample.oct is in Octave's search path, which can be specified +with the environment variable OCTAVE_PATH.

    @@ -193,8 +214,9 @@ ans = 4

    -Modules can also be loaded from within functions, even before being loaded in the base context. -If the module is also used in the base context, however, it must first be loaded again: +Modules can also be loaded from within functions, even before being loaded in +the base context. If the module is also used in the base context, however, it +must first be loaded again:

    @@ -213,112 +235,135 @@ ans =  2
     
     

    32.3.2 Functions

    -

    -Global functions are wrapped as new Octave built-in functions. For example, +Global functions are wrapped as new Octave built-in functions. For example,

    -
    %module swigexample
    -int fact(int n); 
    +
    +%module swigexample
    +int fact(int n);
    +

    - creates a built-in function swigexample.fact(n) that works exactly like you think it does: +creates a built-in function swigexample.fact(n) that works exactly like +you think it does:

    -
    octave:1> swigexample.fact(4)
    -24 
    +
    octave:1> swigexample.fact(4)
    +24
    +

    32.3.3 Global variables

    -

    - Global variables are a little special in Octave. Given a global variable: +Global variables are a little special in Octave. Given a global variable:

    -
    %module swigexample
    +
    +%module swigexample
     extern double Foo;
     

    - To expose variables, SWIG actually generates two functions, to get and set the value. In this case, Foo_set and Foo_set would be generated. SWIG then automatically calls these functions when you get and set the variable-- in the former case creating a local copy in the interpreter of the C variables, and in the latter case copying an interpreter variables onto the C variable. +To expose variables, SWIG actually generates two functions, to get and set the +value. In this case, Foo_set and Foo_set would be +generated. SWIG then automatically calls these functions when you get and set +the variable -- in the former case creating a local copy in the interpreter of +the C variables, and in the latter case copying an interpreter variables onto +the C variable.

    -
    octave:1> swigexample;
    +
    octave:1> swigexample;
     octave:2> c=swigexample.cvar.Foo
     c =  3
     octave:3> swigexample.cvar.Foo=4;
     octave:4> c
     c =  3
     octave:5> swigexample.cvar.Foo
    -ans =  4
    +ans = 4 +

    -If a variable is marked with the %immutable directive then any attempts to set this variable will cause an Octave error. Given a global variable: +If a variable is marked with the %immutable directive then any attempts +to set this variable will cause an Octave error. Given a global variable:

    -
    %module swigexample
    +
    +%module swigexample
     %immutable;
     extern double Foo;
     %mutable;
     

    - SWIG will allow the reading of Foo but when a set attempt is made, an error function will be called. +SWIG will allow the reading of Foo but when a set attempt is made, an +error function will be called.

    -
    octave:1> swigexample
    +
    octave:1> swigexample
     octave:2> swigexample.Foo=4
     error: attempt to set immutable member variable
     error: assignment failed, or no method for `swig_type = scalar'
    -error: evaluating assignment expression near line 2, column 12 
    +error: evaluating assignment expression near line 2, column 12 +

    - It is possible to add new functions or variables to the module. This also allows the user to rename/remove existing functions and constants (but not linked variables, mutable or immutable). Therefore users are recommended to be careful when doing so. +It is possible to add new functions or variables to the module. This also allows +the user to rename/remove existing functions and constants (but not linked +variables, mutable or immutable). Therefore users are recommended to be careful +when doing so.

    -
    octave:1> swigexample;
    +
    octave:1> swigexample;
     octave:2> swigexample.PI=3.142;
     octave:3> swigexample.PI
    -ans =  3.1420 
    +ans = 3.1420 +

    32.3.4 Constants and enums

    -

    - Because Octave doesn't really have the concept of constants, C/C++ constants are not really constant in Octave. They are actually just a copy of the value into the Octave interpreter. Therefore they can be changed just as any other value. For example given some constants: +Because Octave doesn't really have the concept of constants, C/C++ constants are +not really constant in Octave. They are actually just a copy of the value into +the Octave interpreter. Therefore they can be changed just as any other +value. For example given some constants:

    -
    %module swigexample
    +
    +%module swigexample
     %constant int ICONST=42;
     #define    SCONST      "Hello World"
     enum Days{SUNDAY,MONDAY,TUESDAY,WEDNESDAY,THURSDAY,FRIDAY,SATURDAY};
     

    - This is 'effectively' converted into the following Octave code: +This is effectively converted into the following Octave code:

    -
    swigexample.ICONST=42
    +
    swigexample.ICONST=42
     swigexample.SCONST="Hello World"
     swigexample.SUNDAY=0
    -.... 
    +.... +

    32.3.5 Pointers

    -

    - C/C++ pointers are fully supported by SWIG. Furthermore, SWIG has no problem working with incomplete type information. Given a wrapping of the <file.h> interface: - C/C++ pointers are fully supported by SWIG. Furthermore, SWIG has no problem working with incomplete type information. Given a wrapping of the <file.h> interface: +C/C++ pointers are fully supported by SWIG. Furthermore, SWIG has no problem +working with incomplete type information. Given a wrapping of +the file.h interface:

    -
    %module swigexample
    +
    +%module swigexample
     FILE *fopen(const char *filename, const char *mode);
     int fputs(const char *, FILE *);
     int fclose(FILE *);
     

    -When wrapped, you will be able to use the functions in a natural way from Octave. For example: +When wrapped, you will be able to use the functions in a natural way from +Octave. For example:

    @@ -329,7 +374,7 @@ octave:4> swigexample.fclose(f);
     

    - Simply printing the value of a wrapped C++ type will print its typename. E.g., +Simply printing the value of a wrapped C++ type will print its typename, e.g.:

    octave:1> swigexample;
    @@ -339,55 +384,67 @@ f =
     
     {
       _p_FILE, ptr = 0x9b0cd00
    -} 
    +} +

    - As the user of the pointer, you are responsible for freeing it, or closing any resources associated with it (just as you would in a C program). This does not apply so strictly to classes and structs (see below). +As the user of the pointer, you are responsible for freeing it, or closing any +resources associated with it (just as you would in a C program). This does not +apply so strictly to classes and structs (see below).

    -
    octave:1> swigexample;
    +
    octave:1> swigexample;
     octave:2> f=swigexample.fopen("not there","r");
     error: value on right hand side of assignment is undefined
    -error: evaluating assignment expression near line 2, column 2 
    +error: evaluating assignment expression near line 2, column 2 +

    32.3.6 Structures and C++ classes

    -

    - SWIG wraps C structures and C++ classes by using a special Octave type called a swig_ref. A swig_ref contains a reference to one or more instances of C/C++ objects, or just the type information for an object. -For each wrapped structure and class, a swig_ref will be exposed that has the name of the type. When invoked as a function, it creates a new object of its type and returns a swig_ref that points to that instance. This provides a very natural interface. For example, +SWIG wraps C structures and C++ classes by using a special Octave type called +a swig_ref. A swig_ref contains a reference to one or more +instances of C/C++ objects, or just the type information for an object. For +each wrapped structure and class, a swig_ref will be exposed that has +the name of the type. When invoked as a function, it creates a new object of its +type and returns a swig_ref that points to that instance. This provides +a very natural interface. For example,

    -
    struct Point{
    +
    +struct Point{
       int x,y;
     };
     

    - is used as follows: +is used as follows:

    -
    -
    octave:1> swigexample;
    +
    octave:1> swigexample;
     octave:2> p=swigexample.Point();
     octave:3> p.x=3;
     octave:4> p.y=5;
     octave:5> p.x, p.y
     ans =  3
    -ans =  5 
    +ans =  5
     
    +

    In C++, invoking the type object in this way calls the object's constructor. -swig_ref objects can also be acquired by having a wrapped function return a pointer, reference, or value of a non-primitive type. +swig_ref objects can also be acquired by having a wrapped function +return a pointer, reference, or value of a non-primitive type.

    -

    -The swig_ref type handles indexing operations such that usage maps closely to what you would have in C/C++. -Structure members are accessed as in the above example, by calling set and get methods for C++ variables. -Methods also work as expected. For example, code wrapped in the following way +

    +The swig_ref type handles indexing operations such that usage maps +closely to what you would have in C/C++. Structure members are accessed as in +the above example, by calling set and get methods for C++ variables. Methods +also work as expected. For example, code wrapped in the following way

    -
    class Point{
    +
    +class Point{
     public:
       int x,y;
       Point(int _x,int _y) : x(_x),y(_y) {}
    @@ -399,34 +456,41 @@ public:
       }
     };
     
    +

    can be used from Octave like this

    -
    -
    octave:1> swigexample;
    +
    +
    octave:1> swigexample;
     octave:2> p1=swigexample.Point(3,5);
     octave:3> p2=swigexample.Point(1,2);
     octave:4> p1.distance(p2)
     ans =  3.6056
     
    +

    -By using the swig_this() and swig_type() functions, one can discover the pointers to and types of the underlying C/C++ object. +By using the swig_this() and swig_type() functions, one can +discover the pointers to and types of the underlying C/C++ object.

    -
    -
    +
     octave:5> swig_this(p1)
     ans = 162504808
     octave:6> swig_type(p1)
     ans = Point
     
    +

    -Note that swig_ref is a reference-counted pointer to a C/C++ object/type, and as such has pass-by-reference semantics. For example if one has a allocated a single object but has two swig_ref's pointing to it, modifying the object through either of them will change the single allocated object. -This differs from the usual pass-by-value (copy-on-write) semantics that Octave maintains for built-in types. For example, in the following snippet, modifying b does not modify a, +Note that swig_ref is a reference-counted pointer to a C/C++ +object/type, and as such has pass-by-reference semantics. For example if one has +a allocated a single object but has two swig_ref's pointing to it, +modifying the object through either of them will change the single allocated +object. This differs from the usual pass-by-value (copy-on-write) semantics +that Octave maintains for built-in types. For example, in the following snippet, +modifying b does not modify a,

    -
    -
    +
     octave:7> a=struct('x',4)
     a =
     {
    @@ -452,12 +516,12 @@ a =
       x =  4
     }
     
    +

    However, when dealing with wrapped objects, one gets the behavior

    -
    -
    +
     octave:2> a=Point(3,5)
     a =
     
    @@ -482,41 +546,58 @@ ans =  1
     

    -Depending on the ownership setting of a swig_ref, it may call C++ destructors when its reference count goes to zero. See the section on memory management below for details. +Depending on the ownership setting of a swig_ref, it may call C++ +destructors when its reference count goes to zero. See the section on memory +management below for details.

    32.3.7 C++ inheritance

    -

    -Single and multiple inheritance are fully supported. The swig_ref type carries type information along with any C++ object pointer it holds. -This information contains the full class hierarchy. When an indexing operation (such as a method invocation) occurs, -the tree is walked to find a match in the current class as well as any of its bases. The lookup is then cached in the swig_ref. +Single and multiple inheritance are fully supported. The swig_ref type +carries type information along with any C++ object pointer it holds. This +information contains the full class hierarchy. When an indexing operation (such +as a method invocation) occurs, the tree is walked to find a match in the +current class as well as any of its bases. The lookup is then cached in +the swig_ref.

    32.3.8 C++ overloaded functions

    -

    -Overloaded functions are supported, and handled as in other modules. That is, -each overload is wrapped separately (under internal names), and a dispatch function is also emitted under the external/visible name. -The dispatch function selects which overload to call (if any) based on the passed arguments. -typecheck typemaps are used to analyze each argument, as well as assign precedence. See the chapter on typemaps for details. +Overloaded functions are supported, and handled as in other modules. That is, +each overload is wrapped separately (under internal names), and a dispatch +function is also emitted under the external/visible name. The dispatch function +selects which overload to call (if any) based on the passed arguments. +typecheck typemaps are used to analyze each argument, as well as assign +precedence. See the chapter on typemaps for details.

    32.3.9 C++ operators

    -

    C++ operator overloading is supported, in a way similar to other modules. -The swig_ref type supports all unary and binary operators between itself and all other types that exist in the system at module load time. When an operator is used (where one of the operands is a swig_ref), the runtime routes the call to either a member function of the given object, or to a global function whose named is derived from the types of the operands (either both or just the lhs or rhs). +The swig_ref type supports all unary and binary operators between +itself and all other types that exist in the system at module load time. When an +operator is used (where one of the operands is a swig_ref), the runtime +routes the call to either a member function of the given object, or to a global +function whose named is derived from the types of the operands (either both or +just the lhs or rhs).

    +

    -For example, if a and b are SWIG variables in Octave, a+b becomes a.__add(b). The wrapper is then free to implement __add to do whatever it wants. A wrapper may define the __add function manually, %rename some other function to it, or %rename a C++ operator to it. +For example, if a and b are SWIG variables in +Octave, a+b becomes a.__add(b). The wrapper is then free to +implement __add to do whatever it wants. A wrapper may define the __add +function manually, %rename some other function to it, +or %rename a C++ operator to it.

    +

    -By default the C++ operators are renamed to their corresponding Octave operators. So without doing any work, the following interface +By default the C++ operators are renamed to their corresponding Octave +operators. So without doing any work, the following interface

    +
     %inline {
     struct A {
    @@ -528,16 +609,20 @@ struct A {
     };
     }
     
    +

    is usable from Octave like this:

    +
     a=A(2), b=A(3), c=a+b
     assert(c.value==5);
     
    +

    Octave operators are mapped in the following way:

    +
     __brace      a{args}
     __brace_asgn a{args} = rhs
    @@ -572,9 +657,11 @@ __el_ldiv    a .\ b
     __el_and     a & b
     __el_or      a | b
     
    +

    On the C++ side, the default mappings are as follows:

    +
     %rename(__add)       *::operator+;
     %rename(__add)       *::operator+();
    @@ -605,18 +692,21 @@ On the C++ side, the default mappings are as follows:
     

    -Octave can also utilise friend (i.e. non-member) operators with a simple %rename: see the example in the Examples/octave/operator directory. +Octave can also utilise friend (i.e. non-member) operators with a simple +%rename: see the example in the Examples/octave/operator directory.

    32.3.10 Class extension with %extend

    -

    -The %extend directive works the same as in other modules. -

    -

    -You can use it to define special behavior, like for example defining Octave operators not mapped to C++ operators, or defining certain Octave mechanisms such as how an object prints. For example, the octave_value::{is_string,string_value,print} functions are routed to a special method __str that can be defined inside an %extend. +The %extend directive works the same as in other modules. You can use +it to define special behavior, like for example defining Octave operators not +mapped to C++ operators, or defining certain Octave mechanisms such as how an +object prints. For example, +the octave_value::{is_string,string_value,print} functions are routed +to a special method __str that can be defined inside an extend>.

    +
     %extend A {
     string __str() {
    @@ -626,9 +716,11 @@ string __str() {
     }
     }
     
    +

    Then in Octave one gets,

    +
     octave:1> a=A(4);
     octave:2> a
    @@ -638,15 +730,18 @@ octave:3> printf("%s\n",a);
     octave:4> a.__str()
     4
     
    -

    32.3.11 C++ templates

    +

    32.3.11 C++ templates

    -C++ class and function templates are fully supported as in other modules, in that the %template directive may used to create explicit instantiations of templated types. -For example, function templates can be instantiated as follows: +C++ class and function templates are fully supported as in other modules, in +that the template> directive may used to create explicit instantiations of +templated types. For example, function templates can be instantiated as +follows:

    -
    %module swigexample
    +
    +%module swigexample
     %inline {
      template<class __scalar>
        __scalar mul(__scalar a,__scalar b) {
    @@ -657,6 +752,7 @@ For example, function templates can be instantiated as follows:
     %template(mul) mul<std::complex<double> >
     %template(mul) mul<double>
     
    +

    and then used from Octave

    @@ -674,7 +770,8 @@ ans = 22 + 46i Similarly, class templates can be instantiated as in the following example,

    -
    %module swigexample
    +
    +%module swigexample
     %include <std_complex.i>
     %include <std_string.i>
     %inline {
    @@ -714,26 +811,30 @@ ans =
     (7,4)
     
    -

    32.3.12 C++ Smart Pointers

    -

    C++ smart pointers are fully supported as in other modules.

    32.3.13 Directors (calling Octave from C++ code)

    -

    -There is full support for SWIG Directors, which permits Octave code to subclass C++ classes, and implement their virtual methods. +There is full support for SWIG directors, which permits Octave code to subclass +C++ classes, and implement their virtual methods.

    +

    -Octave has no direct support for object oriented programming, however the swig_ref type provides some of this support. You can manufacture a swig_ref using the subclass function (provided by the SWIG/Octave runtime). +Octave has no direct support for object oriented programming, however +the swig_ref type provides some of this support. You can manufacture +a swig_ref using the subclass function (provided by the +SWIG/Octave runtime).

    +

    For example,

    +
     octave:1> a=subclass();
     octave:2> a.my_var = 4;
    @@ -741,9 +842,12 @@ octave:3> a.my_method = @(self) printf("my_var = ",self.my_var);
     octave:4> a.my_method();
     my_var = 4
     
    +

    -subclass() can also be used to subclass one or more C++ types. Suppose you have an interface defined by +subclass() can also be used to subclass one or more C++ types. Suppose +you have an interface defined by

    +
     %inline {
     class A {
    @@ -757,9 +861,11 @@ void call_your_method(A& a) {
     }
     }
     
    +

    Then from Octave you can say:

    +
     octave:1> B=@() subclass(A(),@my_method);
     octave:2> function my_method(self)
    @@ -768,30 +874,46 @@ octave:4> end
     octave:5> call_your_method(B());
     octave-side routine called
     
    +

    or more concisely,

    +
     octave:1> B=@() subclass(A(),'my_method',@(self) printf("octave-side routine called\n"));
     octave:2> call_your_method(B());
     octave-side routine called
     
    +

    -Note that you have to enable directors via the %feature directive (see other modules for this). +Note that you have to enable directors via the %feature directive (see +other modules for this).

    +

    -subclass() will accept any number of C++ bases or other subclass()'ed objects, (string,octave_value) pairs, and function_handles. In the first case, these are taken as base classes; in the second case, as named members (either variables or functions, depending on whether the given value is a function handle); in the third case, as member functions whose name is taken from the given function handle. E.g., +subclass() will accept any number of C++ bases or +other subclass()'ed objects, (string,octave_value) pairs, +and function_handles. In the first case, these are taken as base +classes; in the second case, as named members (either variables or functions, +depending on whether the given value is a function handle); in the third case, +as member functions whose name is taken from the given function handle, e.g.:

    +
     octave:1> B=@(some_var=2) subclass(A(),'some_var',some_var,@some_func,'another_func',
     @(self) do_stuff())
     
    +

    -You can also assign non-C++ member variables and functions after construct time. There is no support for non-C++ static members. +You can also assign non-C++ member variables and functions after construction +time. There is no support for non-C++ static members.

    +

    -There is limited support for explicitly referencing C++ bases. So, in the example above, we could have +There is limited support for explicitly referencing C++ bases. So, in the +example above, we could have

    +
     octave:1> B=@() subclass(A(),@my_method);
     octave:2> function my_method(self)
    @@ -805,19 +927,29 @@ octave-side routine called
     
     

    32.3.14 Threads

    -

    -The use of threads in wrapped Director code is not supported; i.e., an Octave-side implementation of a C++ class must be called from the Octave interpreter's thread. Anything fancier (apartment/queue model, whatever) is left to the user. Without anything fancier, this amounts to the limitation that Octave must drive the module... like, for example, an optimization package that calls Octave to evaluate an objective function. +The use of threads in wrapped director code is not supported; i.e., an +Octave-side implementation of a C++ class must be called from the Octave +interpreter's thread. Anything fancier (apartment/queue model, whatever) is left +to the user. Without anything fancier, this amounts to the limitation that +Octave must drive the module... like, for example, an optimization package that +calls Octave to evaluate an objective function.

    32.3.15 Memory management

    -

    -As noted above, swig_ref represents a reference counted pointer to a C/C++-side object. It also contains a flag indicating whether Octave or the C/C++ code owns the object. If Octave owns it, any destructors will be called when the reference count reaches zero. If the C/C++ side owns the object, then destructors will not be called when the reference count goes to zero. +As noted above, swig_ref represents a reference counted pointer to a +C/C++-side object. It also contains a flag indicating whether Octave or the +C/C++ code owns the object. If Octave owns it, any destructors will be called +when the reference count reaches zero. If the C/C++ side owns the object, then +destructors will not be called when the reference count goes to zero.

    +

    For example, +

    +
     %inline {
     class A {
    @@ -827,9 +959,11 @@ public:
     };
     }
     
    +

    -Would produce this behavior in Octave: +would produce this behavior in Octave:

    +
     octave:1> a=A();
     A constructing
    @@ -838,36 +972,49 @@ octave:3> clear a;
     octave:4> b=4;
     A destructing
     
    +

    -The %newobject directive may be used to control this behavior for pointers returned from functions. +The %newobject directive may be used to control this behavior for +pointers returned from functions. +

    +

    -In the case where one wishes for the C++ side to own an object that was created in Octave (especially a Director object), one can use the __disown() method to invert this logic. Then letting the Octave reference count go to zero will not destroy the object, but destroying the object will invalidate the Octave-side object if it still exists (and call destructors of other C++ bases in the case of multiple inheritance/subclass()'ing). +In the case where one wishes for the C++ side to own an object that was created +in Octave (especially a Director object), one can use the __disown() method to +invert this logic. Then letting the Octave reference count go to zero will not +destroy the object, but destroying the object will invalidate the Octave-side +object if it still exists (and call destructors of other C++ bases in the case +of multiple inheritance/subclass()'ing).

    32.3.16 STL support

    -

    Various STL library files are provided for wrapping STL containers.

    32.3.17 Matrix typemaps

    -

    -Octave provides a rich set of classes for dealing with matrices. Currently there are no built-in typemaps to deal with those. However, these are relatively straight forward for users to add themselves (see the docs on typemaps). Without much work (a single typemap decl-- say, 5 lines of code in the interface file), it would be possible to have a function +Octave provides a rich set of classes for dealing with matrices. Currently there +are no built-in typemaps to deal with those. However, these are relatively +straight forward for users to add themselves (see the docs on typemaps). Without +much work (a single typemap decl -- say, 5 lines of code in the interface file), +it would be possible to have a function

    +
     double my_det(const double* mat,int m,int n);
     
    +

    that is accessed from Octave as,

    +
     octave:1> my_det(rand(4));
     ans = -0.18388
     
    -
    - + -- cgit v1.2.1 From 952eee8f5904f85411d28dd375cc7df67f74b95a Mon Sep 17 00:00:00 2001 From: Karl Wette Date: Sat, 4 Oct 2014 18:27:34 +0200 Subject: Octave: drop support for Octave versions older than 3.2.0 - Latest non-supported version is 3.0.5, released 2009-04-09 - Earliest supported version is 3.2.0, released 2009-06-05 --- CHANGES.current | 7 +++++++ Doc/Manual/Octave.html | 5 ++--- Examples/octave/module_load/runme.m | 6 ------ Lib/octave/octrundecl.swg | 11 ++++++----- Lib/octave/octrunfunc.swg | 4 ---- Lib/octave/octruninit.swg | 8 +------- 6 files changed, 16 insertions(+), 25 deletions(-) diff --git a/CHANGES.current b/CHANGES.current index b305c7627..3b81a63bd 100644 --- a/CHANGES.current +++ b/CHANGES.current @@ -5,6 +5,13 @@ See the RELEASENOTES file for a summary of changes in each release. Version 3.0.3 (in progress) =========================== +2014-10-04: kwwette + [Octave] Drop support for Octave versions older than 3.2.0 + - Latest non-supported version is 3.0.5, released 2009-04-09 + - Earliest supported version is 3.2.0, released 2009-06-05 + + *** POTENTIAL INCOMPATIBILITY *** + 2014-09-30: oliverb [Javascript] Merge patch #216 by Richie765 - Added support for many versions of v8 javascript. diff --git a/Doc/Manual/Octave.html b/Doc/Manual/Octave.html index e48083afd..3ba477b37 100644 --- a/Doc/Manual/Octave.html +++ b/Doc/Manual/Octave.html @@ -58,9 +58,8 @@ in the test suite (Examples/test-suite and Examples/test-suite/octave).

    32.1 Preliminaries

    -As of SWIG 3.0.0, the Octave module has been tested with Octave versions 3.0.5, -3.2.4, 3.4.3, 3.6.4, and 3.8.0. Use of Octave versions older than 3.x.x is not -recommended, as these versions are no longer tested with SWIG. +SWIG version 3.0.3 supports only Octave version 3.2.0 or later. It has +been tested with Octave versions 3.2.4, 3.4.3, 3.6.4, and 3.8.1.

    32.2 Running SWIG

    diff --git a/Examples/octave/module_load/runme.m b/Examples/octave/module_load/runme.m index bc311b5e6..758df9c93 100644 --- a/Examples/octave/module_load/runme.m +++ b/Examples/octave/module_load/runme.m @@ -61,12 +61,6 @@ testme testme clear all -# octave 3.0.5 randomly crashes on the remaining tests, so skip them -api_version = sscanf(octave_config_info("api_version"), "api-v%i"); -if api_version < 37 - exit -endif - # load module with no cvar clear all; swigexample2; diff --git a/Lib/octave/octrundecl.swg b/Lib/octave/octrundecl.swg index f71895abb..6452aec97 100644 --- a/Lib/octave/octrundecl.swg +++ b/Lib/octave/octrundecl.swg @@ -101,6 +101,11 @@ #endif // !defined(OCTAVE_MAJOR_VERSION) +// Set minimum supported Octave version +#if !SWIG_OCTAVE_PREREQ(3,2,0) +#error This version of SWIG supports only Octave version 3.2.0 or later +#endif + // Octave_map was renamed to octave_map in v3.3.52 #if !SWIG_OCTAVE_PREREQ(3,3,52) #define octave_map Octave_map @@ -108,11 +113,7 @@ ////////// Declare/define SWIG interface function loadable by Octave ////////// -#if !SWIG_OCTAVE_PREREQ(3,2,0) -#define SWIG_DEFUN(cname, wname, doc) DEFUNX_DLD(#cname, wname, FS ## cname, args, nargout, doc) -#else -#define SWIG_DEFUN(cname, wname, doc) DEFUNX_DLD(#cname, wname, G ## cname, args, nargout, doc) -#endif +#define SWIG_DEFUN(cname, wname, doc) DEFUNX_DLD(#cname, wname, G ## cname, args, nargout, doc) ////////// Define visibility of Octave runtime functions ////////// diff --git a/Lib/octave/octrunfunc.swg b/Lib/octave/octrunfunc.swg index 6773373b8..34dae2ee2 100644 --- a/Lib/octave/octrunfunc.swg +++ b/Lib/octave/octrunfunc.swg @@ -130,14 +130,10 @@ SWIGOCTRT void SWIG_Octave_SetGlobalValue(std::string name, const octave_value& SWIGOCTRT void SWIG_Octave_LinkGlobalValue(std::string name) { -#if !SWIG_OCTAVE_PREREQ(3,2,0) - link_to_global_variable(curr_sym_tab->lookup(name, true)); -#else #if !SWIG_OCTAVE_PREREQ(3,8,0) symbol_table::varref(name); #endif symbol_table::mark_global(name); -#endif } SWIGOCTRT swig_module_info* SWIG_Octave_GetModule(void* clientdata) diff --git a/Lib/octave/octruninit.swg b/Lib/octave/octruninit.swg index 86d033af2..7d83a5633 100644 --- a/Lib/octave/octruninit.swg +++ b/Lib/octave/octruninit.swg @@ -295,7 +295,7 @@ DEFUN_DLD(SWIG_name, args, nargout, SWIG_name_usage) // definitely affects version 3.2.*, not sure about 3.3.*, seems to be fixed in // version 3.4.* and above. can be turned off with macro definition. #ifndef SWIG_OCTAVE_NO_SEGFAULT_HACK -#if SWIG_OCTAVE_PREREQ(3,2,0) && !SWIG_OCTAVE_PREREQ(3,4,1) +#if !SWIG_OCTAVE_PREREQ(3,4,1) octave_exit = ::_Exit; #endif #endif @@ -311,7 +311,6 @@ DEFUN_DLD(SWIG_name, args, nargout, SWIG_name_usage) // workaround bug in octave where installing global variable of custom type and then // exiting without explicitly clearing the variable causes octave to segfault. -#if SWIG_OCTAVE_PREREQ(3,2,0) octave_value_list eval_args; eval_args.append("base"); eval_args.append("function __swig_atexit__; " @@ -325,7 +324,6 @@ DEFUN_DLD(SWIG_name, args, nargout, SWIG_name_usage) "atexit(\"__swig_atexit__\", false); " "atexit(\"__swig_atexit__\")"); feval("evalin", eval_args, 0); -#endif SwigOctRef::register_type(); SwigOctPacked::register_type(); @@ -398,11 +396,7 @@ DEFUN_DLD(SWIG_name, args, nargout, SWIG_name_usage) } } -#if !SWIG_OCTAVE_PREREQ(3,2,0) - mlock(me->name()); -#else mlock(); -#endif } -- cgit v1.2.1 From 8e37bcf1a88ba4df783b39c77e6132a51a4536a5 Mon Sep 17 00:00:00 2001 From: Karl Wette Date: Sun, 5 Oct 2014 14:31:24 +0200 Subject: Octave: disable optimization of tests for faster compiles/less memory usage - Filter out all but -g... and -W... flags from OCTAVE_CXXFLAGS - Use AX_CHECK_COMPILE_FLAG() to check if -O0 is supported, if so add to end of OCTAVE_CXXFLAGS to ensure optimization is disabled - Also run mkoctfile under "env -" to protect it from environment - Also use more standard-compliant sed expressions --- Tools/config/ax_check_compile_flag.m4 | 74 +++++++++++++++++++++++++++++++++++ configure.ac | 27 +++++++++---- 2 files changed, 94 insertions(+), 7 deletions(-) create mode 100644 Tools/config/ax_check_compile_flag.m4 diff --git a/Tools/config/ax_check_compile_flag.m4 b/Tools/config/ax_check_compile_flag.m4 new file mode 100644 index 000000000..51df0c09a --- /dev/null +++ b/Tools/config/ax_check_compile_flag.m4 @@ -0,0 +1,74 @@ +# =========================================================================== +# http://www.gnu.org/software/autoconf-archive/ax_check_compile_flag.html +# =========================================================================== +# +# SYNOPSIS +# +# AX_CHECK_COMPILE_FLAG(FLAG, [ACTION-SUCCESS], [ACTION-FAILURE], [EXTRA-FLAGS], [INPUT]) +# +# DESCRIPTION +# +# Check whether the given FLAG works with the current language's compiler +# or gives an error. (Warnings, however, are ignored) +# +# ACTION-SUCCESS/ACTION-FAILURE are shell commands to execute on +# success/failure. +# +# If EXTRA-FLAGS is defined, it is added to the current language's default +# flags (e.g. CFLAGS) when the check is done. The check is thus made with +# the flags: "CFLAGS EXTRA-FLAGS FLAG". This can for example be used to +# force the compiler to issue an error when a bad flag is given. +# +# INPUT gives an alternative input source to AC_COMPILE_IFELSE. +# +# NOTE: Implementation based on AX_CFLAGS_GCC_OPTION. Please keep this +# macro in sync with AX_CHECK_{PREPROC,LINK}_FLAG. +# +# LICENSE +# +# Copyright (c) 2008 Guido U. Draheim +# Copyright (c) 2011 Maarten Bosmans +# +# This program is free software: you can redistribute it and/or modify it +# under the terms of the GNU General Public License as published by the +# Free Software Foundation, either version 3 of the License, or (at your +# option) any later version. +# +# This program is distributed in the hope that it will be useful, but +# WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General +# Public License for more details. +# +# You should have received a copy of the GNU General Public License along +# with this program. If not, see . +# +# As a special exception, the respective Autoconf Macro's copyright owner +# gives unlimited permission to copy, distribute and modify the configure +# scripts that are the output of Autoconf when processing the Macro. You +# need not follow the terms of the GNU General Public License when using +# or distributing such scripts, even though portions of the text of the +# Macro appear in them. The GNU General Public License (GPL) does govern +# all other use of the material that constitutes the Autoconf Macro. +# +# This special exception to the GPL applies to versions of the Autoconf +# Macro released by the Autoconf Archive. When you make and distribute a +# modified version of the Autoconf Macro, you may extend this special +# exception to the GPL to apply to your modified version as well. + +#serial 3 + +AC_DEFUN([AX_CHECK_COMPILE_FLAG], +[AC_PREREQ(2.59)dnl for _AC_LANG_PREFIX +AS_VAR_PUSHDEF([CACHEVAR],[ax_cv_check_[]_AC_LANG_ABBREV[]flags_$4_$1])dnl +AC_CACHE_CHECK([whether _AC_LANG compiler accepts $1], CACHEVAR, [ + ax_check_save_flags=$[]_AC_LANG_PREFIX[]FLAGS + _AC_LANG_PREFIX[]FLAGS="$[]_AC_LANG_PREFIX[]FLAGS $4 $1" + AC_COMPILE_IFELSE([m4_default([$5],[AC_LANG_PROGRAM()])], + [AS_VAR_SET(CACHEVAR,[yes])], + [AS_VAR_SET(CACHEVAR,[no])]) + _AC_LANG_PREFIX[]FLAGS=$ax_check_save_flags]) +AS_IF([test x"AS_VAR_GET(CACHEVAR)" = xyes], + [m4_default([$2], :)], + [m4_default([$3], :)]) +AS_VAR_POPDEF([CACHEVAR])dnl +])dnl AX_CHECK_COMPILE_FLAGS diff --git a/configure.ac b/configure.ac index 78c276029..017fc5a0c 100644 --- a/configure.ac +++ b/configure.ac @@ -937,25 +937,38 @@ fi if test -n "$OCTAVE"; then AC_MSG_CHECKING([for Octave preprocessor flags]) OCTAVE_CPPFLAGS= - for n in CPPFLAGS INCFLAGS; do - OCTAVE_CPPFLAGS="${OCTAVE_CPPFLAGS} "`unset CPPFLAGS; ${mkoctfile} -p $n` + for var in CPPFLAGS INCFLAGS ALL_CXXFLAGS; do + for flag in `env - ${mkoctfile} -p ${var}`; do + case ${flag} in + -D*|-I*) OCTAVE_CPPFLAGS="${OCTAVE_CPPFLAGS} ${flag}";; + *) ;; + esac + done done AC_MSG_RESULT([$OCTAVE_CPPFLAGS]) AC_MSG_CHECKING([for Octave compiler flags]) OCTAVE_CXXFLAGS= - for n in ALL_CXXFLAGS; do - OCTAVE_CXXFLAGS="${OCTAVE_CXXFLAGS} "`unset CXXFLAGS; ${mkoctfile} -p $n` + for var in ALL_CXXFLAGS; do + for flag in `env - ${mkoctfile} -p ${var}`; do + case ${flag} in + -g*|-W*) OCTAVE_CXXFLAGS="${OCTAVE_CXXFLAGS} ${flag}";; + *) ;; + esac + done done AC_MSG_RESULT([$OCTAVE_CXXFLAGS]) + AC_LANG_PUSH([C++]) + AX_CHECK_COMPILE_FLAG([-O0],[OCTAVE_CXXFLAGS="${OCTAVE_CXXFLAGS} -O0"],[],[-Werror]) + AC_LANG_POP([C++]) AC_MSG_CHECKING([for Octave linker flags]) OCTAVE_LDFLAGS= - for n in RDYNAMIC_FLAG LFLAGS RLD_FLAG OCTAVE_LIBS LIBS; do - OCTAVE_LDFLAGS="${OCTAVE_LDFLAGS} "`${mkoctfile} -p $n` + for var in RDYNAMIC_FLAG LFLAGS RLD_FLAG OCTAVE_LIBS LIBS; do + OCTAVE_LDFLAGS="${OCTAVE_LDFLAGS} "`env - ${mkoctfile} -p ${var}` done AC_MSG_RESULT([$OCTAVE_LDFLAGS]) for octave_opt in --silent --norc --no-history --no-window-system; do AC_MSG_CHECKING([if Octave option '${octave_opt}' is supported]) - octave_out=`${OCTAVE} ${octave_opt} /dev/null 2>&1 | sed -n '1{/unrecognized/p}'` + octave_out=`${OCTAVE} ${octave_opt} /dev/null 2>&1 | sed -n '1p' | sed -n '/unrecognized/p'` AS_IF([test "x${octave_out}" = x],[ AC_MSG_RESULT([yes]) OCTAVE="${OCTAVE} ${octave_opt}" -- cgit v1.2.1 From 90c32a11c24b9a47820f7ab88448cc0261219cf9 Mon Sep 17 00:00:00 2001 From: Karl Wette Date: Sun, 5 Oct 2014 14:34:46 +0200 Subject: .travis.yml: reduce Octave make jobs to 3 - Allow for more memory per job to prevent gcc failures - Disabling optimization should give enough speedup to compensate --- .travis.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.travis.yml b/.travis.yml index 8521e0cc6..fca1941a9 100644 --- a/.travis.yml +++ b/.travis.yml @@ -23,7 +23,7 @@ matrix: - compiler: gcc env: SWIGLANG=lua - compiler: gcc - env: SWIGLANG=octave SWIGJOBS=-j4 + env: SWIGLANG=octave SWIGJOBS=-j3 - compiler: gcc env: SWIGLANG=perl5 - compiler: gcc -- cgit v1.2.1 From 492b1b0339441ecc7e0eed0166d2e9981c9d3c2a Mon Sep 17 00:00:00 2001 From: Karl Wette Date: Sun, 5 Oct 2014 14:35:12 +0200 Subject: Revert "Suppress Octave failing the build" - This reverts commit fea2fc137e2a1db8601e6af922838a71cc47596e. - Failures were probably due to gcc running out of memory - Disabling optimization of Octave tests should both increase compile times and reduce memory usage, and reducing number of make jobs to 3 should also allow for more memory per job --- .travis.yml | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/.travis.yml b/.travis.yml index fca1941a9..4266e7183 100644 --- a/.travis.yml +++ b/.travis.yml @@ -47,9 +47,7 @@ matrix: - compiler: gcc env: SWIGLANG=tcl allow_failures: - # g++-4.6.3 internal compiler error for li_std_vector testcase - - compiler: gcc - env: SWIGLANG=octave SWIGJOBS=-j4 + # None before_install: - date -u - uname -a -- cgit v1.2.1 From 8c7e578279b17d6133992383e9da04abb2690b90 Mon Sep 17 00:00:00 2001 From: Karl Wette Date: Sun, 5 Oct 2014 20:53:27 +0200 Subject: Octave: remove unused function SwigOctType::help_text() --- Lib/octave/octrunclass.swg | 12 ------------ Lib/octave/octrundecl.swg | 1 - 2 files changed, 13 deletions(-) diff --git a/Lib/octave/octrunclass.swg b/Lib/octave/octrunclass.swg index 2310a45b8..3070e79d1 100644 --- a/Lib/octave/octrunclass.swg +++ b/Lib/octave/octrunclass.swg @@ -329,18 +329,6 @@ long SwigOctType::swig_this() const return (long) types[0].second.ptr; } -const char* SwigOctType::help_text() const -{ - if (!types.size()) { - return 0; - } - if (!types[0].first->clientdata) { - return 0; - } - SwigOctClass* c = (SwigOctClass*) types[0].first->clientdata; - return c->constructor_doc; -} - std::string SwigOctType::swig_type_name() const { // * need some way to manually name subclasses. diff --git a/Lib/octave/octrundecl.swg b/Lib/octave/octrundecl.swg index 6452aec97..c451f6951 100644 --- a/Lib/octave/octrundecl.swg +++ b/Lib/octave/octrundecl.swg @@ -317,7 +317,6 @@ public: static bool dispatch_global_op(const std::string& symbol, const octave_value_list& args, octave_value& ret); static octave_value dispatch_unary_op(const octave_base_value& x, const char* op_name); octave_base_value* empty_clone() const; - const char* help_text() const; void incref(); bool is_defined() const; virtual bool is_map() const; -- cgit v1.2.1 From afa9affcd97ea05d4bac538407b47a06df6f09a1 Mon Sep 17 00:00:00 2001 From: Karl Wette Date: Sun, 5 Oct 2014 20:54:20 +0200 Subject: Octave: remove unused field SwigOctClass::constructor_doc --- Lib/octave/octrundecl.swg | 1 - Source/Modules/octave.cxx | 6 ++---- 2 files changed, 2 insertions(+), 5 deletions(-) diff --git a/Lib/octave/octrundecl.swg b/Lib/octave/octrundecl.swg index c451f6951..a1b2de778 100644 --- a/Lib/octave/octrundecl.swg +++ b/Lib/octave/octrundecl.swg @@ -229,7 +229,6 @@ struct SwigOctClass { swig_type_info** type; int director; SwigOctFuncPtr constructor; - const char* constructor_doc; SwigOctFuncPtr destructor; const SwigOctMember* members; const char** base_names; diff --git a/Source/Modules/octave.cxx b/Source/Modules/octave.cxx index ec54e8b99..b9c7a2a12 100644 --- a/Source/Modules/octave.cxx +++ b/Source/Modules/octave.cxx @@ -1039,13 +1039,11 @@ public: String* nspace = Getattr(n, "sym:nspace"); String* cname = Swig_name_construct(nspace, constructor_name); String* wcname = Swig_name_wrapper(cname); - String* tname = texinfo_name(n); - Printf(f_wrappers, "%s,%s,", wcname, tname); - Delete(tname); + Printf(f_wrappers, "%s,", wcname); Delete(wcname); Delete(cname); } else { - Printv(f_wrappers, "0,0,", NIL); + Printv(f_wrappers, "0,", NIL); } if (have_destructor) { String* nspace = Getattr(n, "sym:nspace"); -- cgit v1.2.1 From 60da096a079ffc547d2ee6a7825624682e0c68ac Mon Sep 17 00:00:00 2001 From: Anthony Li Date: Mon, 6 Oct 2014 19:26:07 +0800 Subject: GoLang:fix overload functions with polymorphic issue --- Examples/test-suite/common.mk | 1 + Examples/test-suite/common.mk~ | 746 +++ Examples/test-suite/go/abstract_access.go | 311 ++ Examples/test-suite/go/abstract_access_runme | Bin 0 -> 588366 bytes Examples/test-suite/go/abstract_inherit.go | 285 ++ Examples/test-suite/go/abstract_inherit_ok.go | 136 + Examples/test-suite/go/abstract_signature.go | 147 + Examples/test-suite/go/abstract_typedef.go | 174 + Examples/test-suite/go/abstract_typedef2.go | 184 + Examples/test-suite/go/abstract_typedef2_runme | Bin 0 -> 548637 bytes Examples/test-suite/go/abstract_typedef_runme | Bin 0 -> 541892 bytes Examples/test-suite/go/abstract_virtual.go | 348 ++ Examples/test-suite/go/abstract_virtual_runme | Bin 0 -> 600891 bytes Examples/test-suite/go/access_change.go | 438 ++ Examples/test-suite/go/add_link.go | 88 + Examples/test-suite/go/aggregate.go | 40 + Examples/test-suite/go/allowexcept.go | 241 + Examples/test-suite/go/allprotected.go | 681 +++ Examples/test-suite/go/allprotected_not.go | 88 + Examples/test-suite/go/allprotected_not_wrap.h | 16 + Examples/test-suite/go/allprotected_wrap.h | 51 + Examples/test-suite/go/anonymous_bitfield.go | 205 + Examples/test-suite/go/apply_signed_char.go | 358 ++ Examples/test-suite/go/apply_signed_char_wrap.h | 37 + Examples/test-suite/go/apply_strings.go | 587 +++ Examples/test-suite/go/apply_strings_wrap.h | 49 + Examples/test-suite/go/argout.go | 122 + Examples/test-suite/go/argout_runme | Bin 0 -> 509880 bytes Examples/test-suite/go/array_member.go | 586 +++ Examples/test-suite/go/array_member_runme | Bin 0 -> 550490 bytes Examples/test-suite/go/array_typedef_memberin.go | 328 ++ Examples/test-suite/go/arrayref.go | 61 + Examples/test-suite/go/arrays.go | 750 +++ Examples/test-suite/go/arrays_dimensionless.go | 292 ++ Examples/test-suite/go/arrays_global.go | 729 +++ Examples/test-suite/go/arrays_global_runme | Bin 0 -> 567485 bytes Examples/test-suite/go/arrays_global_twodim.go | 621 +++ Examples/test-suite/go/arrays_scope.go | 190 + Examples/test-suite/go/autodoc.go | 933 ++++ Examples/test-suite/go/bloody_hell.go | 102 + Examples/test-suite/go/bom_utf8.go | 101 + Examples/test-suite/go/bools.go | 370 ++ Examples/test-suite/go/c_delete.go | 120 + Examples/test-suite/go/c_delete_function.go | 36 + Examples/test-suite/go/cast_operator.go | 88 + Examples/test-suite/go/casts.go | 148 + Examples/test-suite/go/catches.go | 111 + Examples/test-suite/go/char_binary.go | 164 + Examples/test-suite/go/char_binary_runme | Bin 0 -> 522506 bytes Examples/test-suite/go/char_constant.go | 69 + Examples/test-suite/go/char_strings.go | 302 ++ Examples/test-suite/go/class_forward.go | 122 + Examples/test-suite/go/class_ignore.go | 262 + Examples/test-suite/go/class_ignore_runme | Bin 0 -> 527776 bytes Examples/test-suite/go/class_scope_weird.go | 218 + Examples/test-suite/go/class_scope_weird_runme | Bin 0 -> 524253 bytes Examples/test-suite/go/clientdata_prop_a.go | 124 + Examples/test-suite/go/clientdata_prop_b.go | 389 ++ Examples/test-suite/go/compactdefaultargs.go | 226 + Examples/test-suite/go/compactdefaultargs_runme | Bin 0 -> 551975 bytes Examples/test-suite/go/const_const.go | 49 + Examples/test-suite/go/const_const_2.go | 126 + Examples/test-suite/go/constant_expr.go | 71 + Examples/test-suite/go/constant_pointers.go | 1327 +++++ Examples/test-suite/go/constover.go | 141 + Examples/test-suite/go/constover_runme | Bin 0 -> 1879569 bytes Examples/test-suite/go/constructor_copy.go | 1012 ++++ Examples/test-suite/go/constructor_copy_runme | Bin 0 -> 598598 bytes Examples/test-suite/go/constructor_exception.go | 151 + Examples/test-suite/go/constructor_explicit.go | 110 + Examples/test-suite/go/constructor_ignore.go | 205 + Examples/test-suite/go/constructor_rename.go | 75 + Examples/test-suite/go/constructor_value.go | 113 + Examples/test-suite/go/contract.go | 625 +++ Examples/test-suite/go/contract_runme | Bin 0 -> 684277 bytes Examples/test-suite/go/conversion.go | 126 + Examples/test-suite/go/conversion_namespace.go | 126 + Examples/test-suite/go/conversion_ns_template.go | 194 + Examples/test-suite/go/cplusplus_throw.go | 128 + Examples/test-suite/go/cpp_basic.go | 804 +++ Examples/test-suite/go/cpp_enum.go | 354 ++ Examples/test-suite/go/cpp_enum_runme | Bin 0 -> 545574 bytes Examples/test-suite/go/cpp_namespace.go | 418 ++ Examples/test-suite/go/cpp_namespace_runme | Bin 0 -> 616236 bytes Examples/test-suite/go/cpp_nodefault.go | 213 + Examples/test-suite/go/cpp_static.go | 168 + Examples/test-suite/go/cpp_static_runme | Bin 0 -> 510223 bytes Examples/test-suite/go/cpp_typedef.go | 352 ++ .../go/curiously_recurring_template_pattern.go | 278 + Examples/test-suite/go/default_arg_values.go | 154 + Examples/test-suite/go/default_args.go | 1719 +++++++ Examples/test-suite/go/default_args_runme | Bin 0 -> 669530 bytes Examples/test-suite/go/default_constructor.go | 902 ++++ Examples/test-suite/go/default_constructor_runme | Bin 0 -> 669024 bytes Examples/test-suite/go/defvalue_constructor.go | 136 + Examples/test-suite/go/derived_byvalue.go | 316 ++ Examples/test-suite/go/derived_nested.go | 232 + Examples/test-suite/go/destructor_reprotected.go | 154 + Examples/test-suite/go/director_abstract.go | 1331 +++++ Examples/test-suite/go/director_abstract_wrap.h | 99 + Examples/test-suite/go/director_alternating.go | 328 ++ Examples/test-suite/go/director_alternating_runme | Bin 0 -> 557938 bytes Examples/test-suite/go/director_alternating_wrap.h | 29 + Examples/test-suite/go/director_basic.go | 1420 ++++++ Examples/test-suite/go/director_basic_runme | Bin 0 -> 836295 bytes Examples/test-suite/go/director_basic_wrap.h | 83 + Examples/test-suite/go/director_binary_string.go | 267 + .../test-suite/go/director_binary_string_wrap.h | 29 + Examples/test-suite/go/director_classes.go | 1871 +++++++ Examples/test-suite/go/director_classes_wrap.h | 132 + Examples/test-suite/go/director_classic.go | 1102 ++++ Examples/test-suite/go/director_classic_runme | Bin 0 -> 2257665 bytes Examples/test-suite/go/director_classic_wrap.h | 94 + Examples/test-suite/go/director_constructor.go | 290 ++ Examples/test-suite/go/director_constructor_wrap.h | 34 + Examples/test-suite/go/director_default.go | 875 ++++ Examples/test-suite/go/director_default_runme | Bin 0 -> 750890 bytes Examples/test-suite/go/director_default_wrap.h | 62 + Examples/test-suite/go/director_detect.go | 581 +++ Examples/test-suite/go/director_detect_runme | Bin 0 -> 661368 bytes Examples/test-suite/go/director_detect_wrap.h | 54 + Examples/test-suite/go/director_enum.go | 1436 ++++++ Examples/test-suite/go/director_enum_runme | Bin 0 -> 848743 bytes Examples/test-suite/go/director_enum_wrap.h | 114 + Examples/test-suite/go/director_exception.go | 1066 ++++ Examples/test-suite/go/director_exception_runme | Bin 0 -> 822448 bytes Examples/test-suite/go/director_exception_wrap.h | 87 + Examples/test-suite/go/director_extend.go | 101 + Examples/test-suite/go/director_extend_runme | Bin 0 -> 517522 bytes Examples/test-suite/go/director_extend_wrap.h | 16 + Examples/test-suite/go/director_finalizer.go | 206 + Examples/test-suite/go/director_finalizer_runme | Bin 0 -> 547717 bytes Examples/test-suite/go/director_finalizer_wrap.h | 29 + Examples/test-suite/go/director_frob.go | 1493 ++++++ Examples/test-suite/go/director_frob_runme | Bin 0 -> 911559 bytes Examples/test-suite/go/director_frob_wrap.h | 120 + Examples/test-suite/go/director_ignore.go | 810 +++ Examples/test-suite/go/director_ignore_wrap.h | 101 + Examples/test-suite/go/director_keywords.go | 175 + Examples/test-suite/go/director_keywords_wrap.h | 29 + Examples/test-suite/go/director_namespace_clash.go | 313 ++ .../test-suite/go/director_namespace_clash_wrap.h | 42 + Examples/test-suite/go/director_nested.go | 662 +++ Examples/test-suite/go/director_nested_runme | Bin 0 -> 728500 bytes Examples/test-suite/go/director_nested_wrap.h | 65 + Examples/test-suite/go/director_nspace.go | 450 ++ .../go/director_nspace_director_name_collision.go | 180 + .../director_nspace_director_name_collision_wrap.h | 29 + Examples/test-suite/go/director_nspace_wrap.h | 45 + Examples/test-suite/go/director_overload.go | 862 ++++ Examples/test-suite/go/director_overload2.go | 727 +++ Examples/test-suite/go/director_overload2_wrap.h | 79 + Examples/test-suite/go/director_overload_wrap.h | 78 + Examples/test-suite/go/director_primitives.go | 1368 +++++ Examples/test-suite/go/director_primitives_wrap.h | 114 + Examples/test-suite/go/director_protected.go | 1081 ++++ .../test-suite/go/director_protected_overloaded.go | 386 ++ .../go/director_protected_overloaded_wrap.h | 42 + Examples/test-suite/go/director_protected_runme | Bin 0 -> 793371 bytes Examples/test-suite/go/director_protected_wrap.h | 97 + Examples/test-suite/go/director_redefined.go | 312 ++ Examples/test-suite/go/director_redefined_wrap.h | 33 + Examples/test-suite/go/director_smartptr.go | 29 + Examples/test-suite/go/director_smartptr_wrap.h | 16 + Examples/test-suite/go/director_string.go | 609 +++ Examples/test-suite/go/director_string_runme | Bin 0 -> 761946 bytes Examples/test-suite/go/director_string_wrap.h | 49 + Examples/test-suite/go/director_thread.go | 239 + Examples/test-suite/go/director_thread_wrap.h | 29 + Examples/test-suite/go/director_unroll.go | 290 ++ Examples/test-suite/go/director_unroll_runme | Bin 0 -> 589423 bytes Examples/test-suite/go/director_unroll_wrap.h | 33 + Examples/test-suite/go/director_using.go | 969 ++++ Examples/test-suite/go/director_using_wrap.h | 90 + Examples/test-suite/go/director_wombat.go | 528 ++ Examples/test-suite/go/director_wombat_wrap.h | 62 + Examples/test-suite/go/disown.go | 139 + Examples/test-suite/go/disown_runme | Bin 0 -> 533821 bytes Examples/test-suite/go/dynamic_cast.go | 178 + Examples/test-suite/go/dynamic_cast_runme | Bin 0 -> 540102 bytes Examples/test-suite/go/empty.go | 29 + Examples/test-suite/go/empty_runme | Bin 0 -> 492692 bytes Examples/test-suite/go/enum_forward.go | 90 + Examples/test-suite/go/enum_ignore.go | 129 + Examples/test-suite/go/enum_macro.go | 226 + Examples/test-suite/go/enum_missing.go | 196 + Examples/test-suite/go/enum_plus.go | 83 + Examples/test-suite/go/enum_rename.go | 71 + Examples/test-suite/go/enum_scope_template.go | 120 + Examples/test-suite/go/enum_template.go | 119 + Examples/test-suite/go/enum_template_runme | Bin 0 -> 508847 bytes Examples/test-suite/go/enum_thorough.go | 4294 ++++++++++++++++ Examples/test-suite/go/enum_var.go | 73 + Examples/test-suite/go/enums.go | 507 ++ Examples/test-suite/go/enums_runme | Bin 0 -> 557870 bytes Examples/test-suite/go/equality.go | 336 ++ Examples/test-suite/go/evil_diamond.go | 250 + Examples/test-suite/go/evil_diamond_ns.go | 250 + Examples/test-suite/go/evil_diamond_prop.go | 484 ++ Examples/test-suite/go/exception_order.go | 441 ++ Examples/test-suite/go/exception_order_runme | Bin 0 -> 794098 bytes Examples/test-suite/go/expressions.go | 124 + Examples/test-suite/go/extend.go | 308 ++ .../test-suite/go/extend_constructor_destructor.go | 504 ++ Examples/test-suite/go/extend_default.go | 1696 ++++++ Examples/test-suite/go/extend_placement.go | 815 +++ Examples/test-suite/go/extend_placement_runme | Bin 0 -> 719478 bytes Examples/test-suite/go/extend_special_variables.go | 162 + Examples/test-suite/go/extend_template.go | 101 + Examples/test-suite/go/extend_template_ns.go | 118 + Examples/test-suite/go/extend_template_ns_runme | Bin 0 -> 520955 bytes Examples/test-suite/go/extend_template_runme | Bin 0 -> 514820 bytes Examples/test-suite/go/extend_typedef_class.go | 653 +++ Examples/test-suite/go/extern_c.go | 49 + Examples/test-suite/go/extern_c_runme | Bin 0 -> 497595 bytes Examples/test-suite/go/extern_declaration.go | 50 + Examples/test-suite/go/extern_namespace.go | 61 + Examples/test-suite/go/extern_throws.go | 36 + Examples/test-suite/go/features.go | 834 +++ Examples/test-suite/go/fragments.go | 43 + Examples/test-suite/go/friends.go | 451 ++ Examples/test-suite/go/friends_runme | Bin 0 -> 584905 bytes Examples/test-suite/go/funcptr.go | 338 ++ Examples/test-suite/go/funcptr_cpp.go | 116 + Examples/test-suite/go/function_typedef.go | 50 + Examples/test-suite/go/fvirtual.go | 171 + Examples/test-suite/go/fvirtual_runme | Bin 0 -> 546754 bytes Examples/test-suite/go/global_functions.go | 63 + Examples/test-suite/go/global_namespace.go | 1039 ++++ Examples/test-suite/go/global_ns_arg.go | 43 + Examples/test-suite/go/global_ns_arg_runme | Bin 0 -> 498924 bytes Examples/test-suite/go/global_scope_types.go | 194 + Examples/test-suite/go/global_vars.go | 378 ++ Examples/test-suite/go/go_director_inout.go | 360 ++ Examples/test-suite/go/go_director_inout_runme | Bin 0 -> 2471045 bytes Examples/test-suite/go/go_director_inout_wrap.h | 29 + Examples/test-suite/go/go_inout.go | 355 ++ Examples/test-suite/go/go_inout_runme | Bin 0 -> 2567812 bytes Examples/test-suite/go/grouping.go | 92 + Examples/test-suite/go/grouping_runme | Bin 0 -> 508721 bytes Examples/test-suite/go/ignore_parameter.go | 307 ++ .../test-suite/go/ignore_template_constructor.go | 275 + Examples/test-suite/go/immutable_values.go | 81 + Examples/test-suite/go/import_nomodule.go | 128 + Examples/test-suite/go/import_nomodule_runme | Bin 0 -> 523381 bytes Examples/test-suite/go/import_stl_a.go | 202 + Examples/test-suite/go/import_stl_b.go | 42 + Examples/test-suite/go/imports_a.go | 155 + Examples/test-suite/go/imports_b.go | 264 + Examples/test-suite/go/imports_runme | Bin 0 -> 576059 bytes Examples/test-suite/go/inctest.go | 307 ++ Examples/test-suite/go/inctest_runme | Bin 0 -> 538591 bytes Examples/test-suite/go/infinity.go | 63 + Examples/test-suite/go/inherit.go | 155 + Examples/test-suite/go/inherit_missing.go | 192 + Examples/test-suite/go/inherit_missing_runme | Bin 0 -> 548217 bytes Examples/test-suite/go/inherit_same_name.go | 204 + Examples/test-suite/go/inherit_target_language.go | 714 +++ Examples/test-suite/go/inherit_void_arg.go | 136 + Examples/test-suite/go/inline_initializer.go | 75 + Examples/test-suite/go/insert_directive.go | 29 + Examples/test-suite/go/integers.go | 169 + Examples/test-suite/go/keyword_rename.go | 185 + Examples/test-suite/go/keyword_rename_runme | Bin 0 -> 506488 bytes Examples/test-suite/go/kind.go | 392 ++ Examples/test-suite/go/langobj.go | 36 + Examples/test-suite/go/lextype.go | 70 + Examples/test-suite/go/li_attribute.go | 576 +++ Examples/test-suite/go/li_attribute_runme | Bin 0 -> 676775 bytes Examples/test-suite/go/li_attribute_template.go | 411 ++ Examples/test-suite/go/li_boost_shared_ptr.go | 1856 +++++++ .../test-suite/go/li_boost_shared_ptr_attribute.go | 29 + Examples/test-suite/go/li_boost_shared_ptr_bits.go | 417 ++ .../test-suite/go/li_boost_shared_ptr_template.go | 343 ++ Examples/test-suite/go/li_carrays.go | 529 ++ Examples/test-suite/go/li_carrays_runme | Bin 0 -> 538624 bytes Examples/test-suite/go/li_cdata.go | 104 + Examples/test-suite/go/li_cdata_runme | Bin 0 -> 508616 bytes Examples/test-suite/go/li_cmalloc.go | 272 + Examples/test-suite/go/li_cmalloc_runme | Bin 0 -> 524326 bytes Examples/test-suite/go/li_constraints.go | 109 + Examples/test-suite/go/li_cpointer.go | 178 + Examples/test-suite/go/li_cpointer_runme | Bin 0 -> 508241 bytes Examples/test-suite/go/li_math.go | 175 + Examples/test-suite/go/li_std_auto_ptr.go | 29 + Examples/test-suite/go/li_std_combinations.go | 1374 +++++ Examples/test-suite/go/li_std_deque.go | 1174 +++++ Examples/test-suite/go/li_std_except.go | 346 ++ Examples/test-suite/go/li_std_except_as_class.go | 49 + Examples/test-suite/go/li_std_map.go | 2700 ++++++++++ Examples/test-suite/go/li_std_map_runme | Bin 0 -> 1525723 bytes Examples/test-suite/go/li_std_pair.go | 249 + Examples/test-suite/go/li_std_pair_using.go | 305 ++ Examples/test-suite/go/li_std_string.go | 487 ++ Examples/test-suite/go/li_std_vector.go | 3412 +++++++++++++ Examples/test-suite/go/li_std_vector_enum.go | 304 ++ Examples/test-suite/go/li_std_vector_member_var.go | 459 ++ Examples/test-suite/go/li_stdint.go | 943 ++++ Examples/test-suite/go/li_swigtype_inout.go | 218 + Examples/test-suite/go/li_typemaps.go | 931 ++++ Examples/test-suite/go/li_typemaps_apply.go | 575 +++ Examples/test-suite/go/li_windows.go | 624 +++ Examples/test-suite/go/long_long.go | 195 + Examples/test-suite/go/long_long_apply.go | 241 + Examples/test-suite/go/member_funcptr_galore.go | 432 ++ Examples/test-suite/go/member_pointer.go | 737 +++ Examples/test-suite/go/member_pointer_runme | Bin 0 -> 1981129 bytes Examples/test-suite/go/member_template.go | 165 + Examples/test-suite/go/memberin_extend.go | 101 + Examples/test-suite/go/memberin_extend_c.go | 101 + Examples/test-suite/go/memberin_extend_c_runme | Bin 0 -> 516040 bytes Examples/test-suite/go/minherit.go | 612 +++ Examples/test-suite/go/minherit2.go | 201 + Examples/test-suite/go/minherit_runme | Bin 0 -> 2037550 bytes Examples/test-suite/go/mixed_types.go | 839 +++ Examples/test-suite/go/mod_a.go | 182 + Examples/test-suite/go/mod_b.go | 211 + Examples/test-suite/go/mod_runme | Bin 0 -> 564071 bytes Examples/test-suite/go/multi_import_a.go | 111 + Examples/test-suite/go/multi_import_b.go | 161 + Examples/test-suite/go/multi_import_runme | Bin 0 -> 540010 bytes Examples/test-suite/go/multiple_inheritance.go | 718 +++ Examples/test-suite/go/name.go | 69 + Examples/test-suite/go/name_cxx.go | 146 + Examples/test-suite/go/name_warnings.go | 169 + Examples/test-suite/go/namespace_class.go | 1280 +++++ Examples/test-suite/go/namespace_class_runme | Bin 0 -> 604515 bytes Examples/test-suite/go/namespace_enum.go | 117 + Examples/test-suite/go/namespace_extend.go | 88 + .../test-suite/go/namespace_forward_declaration.go | 211 + Examples/test-suite/go/namespace_nested.go | 339 ++ Examples/test-suite/go/namespace_spaces.go | 140 + Examples/test-suite/go/namespace_template.go | 269 + Examples/test-suite/go/namespace_typedef_class.go | 165 + Examples/test-suite/go/namespace_typemap.go | 204 + Examples/test-suite/go/namespace_typemap_runme | Bin 0 -> 558723 bytes Examples/test-suite/go/namespace_union.go | 101 + Examples/test-suite/go/namespace_virtual_method.go | 144 + .../test-suite/go/namespace_virtual_method_runme | Bin 0 -> 533161 bytes Examples/test-suite/go/naturalvar.go | 234 + Examples/test-suite/go/naturalvar_more.go | 506 ++ Examples/test-suite/go/naturalvar_onoff.go | 383 ++ Examples/test-suite/go/naturalvar_runme | Bin 0 -> 566774 bytes Examples/test-suite/go/nested.go | 910 ++++ Examples/test-suite/go/nested_class.go | 850 +++ Examples/test-suite/go/nested_comment.go | 113 + Examples/test-suite/go/nested_directors.go | 299 ++ Examples/test-suite/go/nested_directors_wrap.h | 41 + Examples/test-suite/go/nested_extend_c.go | 875 ++++ Examples/test-suite/go/nested_scope.go | 203 + Examples/test-suite/go/nested_structs.go | 470 ++ Examples/test-suite/go/nested_workaround.go | 201 + Examples/test-suite/go/nested_workaround_runme | Bin 0 -> 549486 bytes Examples/test-suite/go/newobject1.go | 95 + Examples/test-suite/go/newobject2.go | 132 + Examples/test-suite/go/nspace.go | 29 + Examples/test-suite/go/nspace_extend.go | 29 + Examples/test-suite/go/null_pointer.go | 99 + Examples/test-suite/go/operator_overload.go | 1152 +++++ Examples/test-suite/go/operator_overload_break.go | 287 ++ Examples/test-suite/go/operator_pointer_ref.go | 111 + Examples/test-suite/go/operbool.go | 88 + Examples/test-suite/go/ordering.go | 101 + Examples/test-suite/go/overload_bool.go | 143 + Examples/test-suite/go/overload_copy.go | 98 + Examples/test-suite/go/overload_copy_runme | Bin 0 -> 515303 bytes Examples/test-suite/go/overload_extend.go | 248 + Examples/test-suite/go/overload_extend_runme | Bin 0 -> 546049 bytes Examples/test-suite/go/overload_extendc.go | 226 + Examples/test-suite/go/overload_extendc_runme | Bin 0 -> 556881 bytes Examples/test-suite/go/overload_method.go | 125 + Examples/test-suite/go/overload_numeric.go | 340 ++ Examples/test-suite/go/overload_polymorphic.go | 156 + Examples/test-suite/go/overload_polymorphic_runme | Bin 0 -> 535619 bytes .../test-suite/go/overload_polymorphic_runme.go | 11 + .../test-suite/go/overload_polymorphic_runme.go~ | 11 + Examples/test-suite/go/overload_rename.go | 133 + Examples/test-suite/go/overload_rename_runme | Bin 0 -> 528035 bytes Examples/test-suite/go/overload_return_type.go | 215 + Examples/test-suite/go/overload_simple.go | 1060 ++++ Examples/test-suite/go/overload_simple_runme | Bin 0 -> 693717 bytes Examples/test-suite/go/overload_subtype.go | 161 + Examples/test-suite/go/overload_subtype_runme | Bin 0 -> 531236 bytes Examples/test-suite/go/overload_template.go | 1185 +++++ Examples/test-suite/go/overload_template_fast.go | 1185 +++++ .../test-suite/go/overload_template_fast_runme | Bin 0 -> 704179 bytes Examples/test-suite/go/overload_template_runme | Bin 0 -> 700912 bytes Examples/test-suite/go/packageoption_a.go | 152 + Examples/test-suite/go/packageoption_b.go | 88 + Examples/test-suite/go/packageoption_c.go | 111 + Examples/test-suite/go/pointer_reference.go | 219 + Examples/test-suite/go/preproc.go | 403 ++ Examples/test-suite/go/preproc_constants.go | 246 + Examples/test-suite/go/preproc_constants_c.go | 246 + Examples/test-suite/go/preproc_defined.go | 144 + Examples/test-suite/go/preproc_include.go | 84 + Examples/test-suite/go/preproc_line_file.go | 316 ++ Examples/test-suite/go/preproc_runme | Bin 0 -> 543428 bytes Examples/test-suite/go/primitive_ref.go | 233 + Examples/test-suite/go/primitive_ref_runme | Bin 0 -> 539354 bytes Examples/test-suite/go/private_assign.go | 190 + Examples/test-suite/go/protected_rename.go | 88 + Examples/test-suite/go/pure_virtual.go | 537 ++ Examples/test-suite/go/redefined.go | 134 + Examples/test-suite/go/redefined_not.go | 29 + Examples/test-suite/go/refcount.go | 797 +++ Examples/test-suite/go/refcount_runme | Bin 0 -> 719525 bytes Examples/test-suite/go/reference_global_vars.go | 756 +++ Examples/test-suite/go/reference_global_vars_runme | Bin 0 -> 667836 bytes Examples/test-suite/go/register_par.go | 57 + Examples/test-suite/go/rename1.go | 1023 ++++ Examples/test-suite/go/rename2.go | 1023 ++++ Examples/test-suite/go/rename3.go | 1023 ++++ Examples/test-suite/go/rename4.go | 1023 ++++ Examples/test-suite/go/rename_pcre_encoder.go | 274 + Examples/test-suite/go/rename_pcre_enum.go | 96 + Examples/test-suite/go/rename_predicates.go | 424 ++ Examples/test-suite/go/rename_scope.go | 300 ++ Examples/test-suite/go/rename_scope_runme | Bin 0 -> 558236 bytes Examples/test-suite/go/rename_simple.go | 190 + Examples/test-suite/go/rename_simple_runme | Bin 0 -> 1888165 bytes Examples/test-suite/go/rename_strip_encoder.go | 126 + Examples/test-suite/go/rename_strip_encoder_runme | Bin 0 -> 522623 bytes Examples/test-suite/go/restrict_cplusplus.go | 101 + Examples/test-suite/go/ret_by_value.go | 139 + Examples/test-suite/go/ret_by_value_runme | Bin 0 -> 523079 bytes Examples/test-suite/go/return_const_value.go | 257 + Examples/test-suite/go/return_const_value_runme | Bin 0 -> 551501 bytes Examples/test-suite/go/return_value_scope.go | 164 + Examples/test-suite/go/rname.go | 292 ++ Examples/test-suite/go/samename.go | 88 + Examples/test-suite/go/simple_array.go | 201 + Examples/test-suite/go/sizeof_pointer.go | 153 + Examples/test-suite/go/sizet.go | 57 + Examples/test-suite/go/smart_pointer_const.go | 204 + Examples/test-suite/go/smart_pointer_const2.go | 204 + .../test-suite/go/smart_pointer_const_overload.go | 805 +++ Examples/test-suite/go/smart_pointer_extend.go | 1107 ++++ Examples/test-suite/go/smart_pointer_extend_runme | Bin 0 -> 737603 bytes Examples/test-suite/go/smart_pointer_inherit.go | 1007 ++++ Examples/test-suite/go/smart_pointer_member.go | 483 ++ Examples/test-suite/go/smart_pointer_member_runme | Bin 0 -> 1934344 bytes Examples/test-suite/go/smart_pointer_multi.go | 384 ++ Examples/test-suite/go/smart_pointer_multi_runme | Bin 0 -> 601734 bytes .../test-suite/go/smart_pointer_multi_typedef.go | 384 ++ .../go/smart_pointer_multi_typedef_runme | Bin 0 -> 605838 bytes Examples/test-suite/go/smart_pointer_namespace.go | 267 + Examples/test-suite/go/smart_pointer_namespace2.go | 267 + Examples/test-suite/go/smart_pointer_not.go | 267 + Examples/test-suite/go/smart_pointer_overload.go | 296 ++ .../test-suite/go/smart_pointer_overload_runme | Bin 0 -> 578126 bytes Examples/test-suite/go/smart_pointer_protected.go | 265 + Examples/test-suite/go/smart_pointer_rename.go | 191 + Examples/test-suite/go/smart_pointer_rename_runme | Bin 0 -> 545731 bytes Examples/test-suite/go/smart_pointer_simple.go | 204 + Examples/test-suite/go/smart_pointer_simple_runme | Bin 0 -> 546795 bytes Examples/test-suite/go/smart_pointer_static.go | 196 + .../go/smart_pointer_template_const_overload.go | 373 ++ .../go/smart_pointer_template_defaults_overload.go | 748 +++ .../test-suite/go/smart_pointer_templatemethods.go | 431 ++ .../go/smart_pointer_templatevariables.go | 277 + .../go/smart_pointer_templatevariables_runme | Bin 0 -> 557475 bytes Examples/test-suite/go/smart_pointer_typedef.go | 204 + Examples/test-suite/go/smart_pointer_typedef_runme | Bin 0 -> 546956 bytes Examples/test-suite/go/sneaky1.go | 57 + Examples/test-suite/go/sneaky1_runme | Bin 0 -> 502229 bytes Examples/test-suite/go/special_variable_macros.go | 414 ++ .../test-suite/go/special_variable_macros_runme | Bin 0 -> 591344 bytes Examples/test-suite/go/special_variables.go | 621 +++ Examples/test-suite/go/special_variables_wrap.h | 29 + Examples/test-suite/go/static_array_member.go | 75 + Examples/test-suite/go/static_const_member.go | 107 + Examples/test-suite/go/static_const_member_2.go | 283 + Examples/test-suite/go/static_const_member_2_runme | Bin 0 -> 558214 bytes Examples/test-suite/go/string_simple.go | 36 + Examples/test-suite/go/struct_initialization.go | 709 +++ .../test-suite/go/struct_initialization_cpp.go | 709 +++ Examples/test-suite/go/struct_initialization_runme | Bin 0 -> 586981 bytes Examples/test-suite/go/struct_rename.go | 101 + Examples/test-suite/go/struct_rename_runme | Bin 0 -> 513788 bytes Examples/test-suite/go/struct_value.go | 191 + Examples/test-suite/go/struct_value_runme | Bin 0 -> 537159 bytes Examples/test-suite/go/symbol_clash.go | 29 + Examples/test-suite/go/template_arg_replace.go | 88 + Examples/test-suite/go/template_arg_scope.go | 96 + Examples/test-suite/go/template_arg_typename.go | 122 + Examples/test-suite/go/template_array_numeric.go | 110 + Examples/test-suite/go/template_base_template.go | 160 + Examples/test-suite/go/template_basic.go | 289 ++ Examples/test-suite/go/template_classes.go | 152 + Examples/test-suite/go/template_const_ref.go | 177 + Examples/test-suite/go/template_construct.go | 75 + Examples/test-suite/go/template_default.go | 793 +++ Examples/test-suite/go/template_default2.go | 279 + Examples/test-suite/go/template_default_arg.go | 2105 ++++++++ Examples/test-suite/go/template_default_arg_runme | Bin 0 -> 894243 bytes .../go/template_default_arg_virtual_destructor.go | 151 + .../test-suite/go/template_default_class_parms.go | 525 ++ .../go/template_default_class_parms_typedef.go | 983 ++++ Examples/test-suite/go/template_default_inherit.go | 168 + Examples/test-suite/go/template_default_qualify.go | 241 + Examples/test-suite/go/template_default_vw.go | 159 + Examples/test-suite/go/template_enum.go | 263 + Examples/test-suite/go/template_enum_ns_inherit.go | 271 + Examples/test-suite/go/template_enum_typedef.go | 197 + Examples/test-suite/go/template_explicit.go | 289 ++ Examples/test-suite/go/template_extend1.go | 139 + Examples/test-suite/go/template_extend1_runme | Bin 0 -> 524960 bytes Examples/test-suite/go/template_extend2.go | 139 + Examples/test-suite/go/template_extend2_runme | Bin 0 -> 524960 bytes Examples/test-suite/go/template_extend_overload.go | 400 ++ .../test-suite/go/template_extend_overload_2.go | 385 ++ Examples/test-suite/go/template_forward.go | 378 ++ Examples/test-suite/go/template_inherit.go | 484 ++ .../test-suite/go/template_inherit_abstract.go | 358 ++ Examples/test-suite/go/template_inherit_runme | Bin 0 -> 641216 bytes Examples/test-suite/go/template_int_const.go | 410 ++ Examples/test-suite/go/template_methods.go | 322 ++ .../go/template_namespace_forward_declaration.go | 211 + Examples/test-suite/go/template_nested.go | 919 ++++ Examples/test-suite/go/template_nested_typemaps.go | 182 + Examples/test-suite/go/template_ns.go | 263 + Examples/test-suite/go/template_ns2.go | 69 + Examples/test-suite/go/template_ns3.go | 88 + Examples/test-suite/go/template_ns4.go | 267 + Examples/test-suite/go/template_ns4_runme | Bin 0 -> 531923 bytes Examples/test-suite/go/template_ns_enum.go | 66 + Examples/test-suite/go/template_ns_enum2.go | 113 + Examples/test-suite/go/template_ns_inherit.go | 122 + Examples/test-suite/go/template_ns_runme | Bin 0 -> 564885 bytes Examples/test-suite/go/template_ns_scope.go | 152 + Examples/test-suite/go/template_opaque.go | 259 + Examples/test-suite/go/template_opaque_runme | Bin 0 -> 637791 bytes Examples/test-suite/go/template_partial_arg.go | 203 + .../go/template_partial_specialization.go | 1962 +++++++ .../go/template_partial_specialization_typedef.go | 1809 +++++++ Examples/test-suite/go/template_qualifier.go | 88 + Examples/test-suite/go/template_ref_type.go | 203 + Examples/test-suite/go/template_ref_type_runme | Bin 0 -> 529248 bytes Examples/test-suite/go/template_rename.go | 267 + Examples/test-suite/go/template_rename_runme | Bin 0 -> 543297 bytes Examples/test-suite/go/template_retvalue.go | 202 + Examples/test-suite/go/template_specialization.go | 152 + .../go/template_specialization_defarg.go | 368 ++ .../test-suite/go/template_specialization_enum.go | 218 + Examples/test-suite/go/template_static.go | 196 + Examples/test-suite/go/template_static_runme | Bin 0 -> 502583 bytes Examples/test-suite/go/template_tbase_template.go | 198 + .../test-suite/go/template_tbase_template_runme | Bin 0 -> 515637 bytes .../test-suite/go/template_template_parameters.go | 297 ++ Examples/test-suite/go/template_type_namespace.go | 214 + .../test-suite/go/template_type_namespace_runme | Bin 0 -> 639894 bytes Examples/test-suite/go/template_typedef.go | 444 ++ .../go/template_typedef_class_template.go | 294 ++ Examples/test-suite/go/template_typedef_cplx.go | 456 ++ Examples/test-suite/go/template_typedef_cplx2.go | 664 +++ Examples/test-suite/go/template_typedef_cplx3.go | 896 ++++ .../test-suite/go/template_typedef_cplx3_runme | Bin 0 -> 739574 bytes Examples/test-suite/go/template_typedef_cplx4.go | 896 ++++ .../test-suite/go/template_typedef_cplx4_runme | Bin 0 -> 739574 bytes Examples/test-suite/go/template_typedef_cplx5.go | 109 + Examples/test-suite/go/template_typedef_fnc.go | 214 + Examples/test-suite/go/template_typedef_funcptr.go | 175 + Examples/test-suite/go/template_typedef_import.go | 270 + Examples/test-suite/go/template_typedef_inherit.go | 246 + Examples/test-suite/go/template_typedef_ns.go | 101 + Examples/test-suite/go/template_typedef_ptr.go | 113 + Examples/test-suite/go/template_typedef_rec.go | 189 + Examples/test-suite/go/template_typedef_typedef.go | 259 + Examples/test-suite/go/template_typemaps.go | 237 + .../test-suite/go/template_typemaps_typedef.go | 520 ++ .../test-suite/go/template_typemaps_typedef2.go | 520 ++ Examples/test-suite/go/template_using.go | 89 + ...late_using_directive_and_declaration_forward.go | 653 +++ Examples/test-suite/go/template_virtual.go | 150 + Examples/test-suite/go/template_whitespace.go | 97 + Examples/test-suite/go/threads.go | 101 + Examples/test-suite/go/threads_exception.go | 230 + Examples/test-suite/go/threads_exception_runme | Bin 0 -> 782278 bytes Examples/test-suite/go/throw_exception.go | 285 ++ Examples/test-suite/go/typedef_array_member.go | 173 + Examples/test-suite/go/typedef_class.go | 297 ++ Examples/test-suite/go/typedef_class_runme | Bin 0 -> 534500 bytes Examples/test-suite/go/typedef_funcptr.go | 52 + Examples/test-suite/go/typedef_inherit.go | 283 + Examples/test-suite/go/typedef_inherit_runme | Bin 0 -> 574627 bytes Examples/test-suite/go/typedef_mptr.go | 29 + Examples/test-suite/go/typedef_reference.go | 96 + Examples/test-suite/go/typedef_scope.go | 177 + Examples/test-suite/go/typedef_scope_runme | Bin 0 -> 519858 bytes Examples/test-suite/go/typedef_sizet.go | 36 + Examples/test-suite/go/typedef_struct.go | 438 ++ Examples/test-suite/go/typedef_typedef.go | 164 + Examples/test-suite/go/typemap_array_qualifiers.go | 185 + Examples/test-suite/go/typemap_arrays.go | 36 + Examples/test-suite/go/typemap_delete.go | 101 + Examples/test-suite/go/typemap_directorout.go | 304 ++ Examples/test-suite/go/typemap_directorout_wrap.h | 37 + Examples/test-suite/go/typemap_global_scope.go | 1023 ++++ Examples/test-suite/go/typemap_manyargs.go | 49 + Examples/test-suite/go/typemap_namespace.go | 43 + Examples/test-suite/go/typemap_namespace_runme | Bin 0 -> 499834 bytes Examples/test-suite/go/typemap_ns_using.go | 82 + Examples/test-suite/go/typemap_ns_using_runme | Bin 0 -> 498488 bytes Examples/test-suite/go/typemap_numinputs.go | 36 + Examples/test-suite/go/typemap_out_optimal.go | 148 + Examples/test-suite/go/typemap_out_optimal_runme | Bin 0 -> 526166 bytes Examples/test-suite/go/typemap_qualifier_strip.go | 148 + Examples/test-suite/go/typemap_subst.go | 101 + Examples/test-suite/go/typemap_template.go | 290 ++ .../test-suite/go/typemap_template_parm_typedef.go | 97 + Examples/test-suite/go/typemap_variables.go | 158 + Examples/test-suite/go/typemap_various.go | 363 ++ Examples/test-suite/go/typename.go | 170 + Examples/test-suite/go/typename_runme | Bin 0 -> 530446 bytes Examples/test-suite/go/types_directive.go | 358 ++ Examples/test-suite/go/unicode_strings.go | 43 + Examples/test-suite/go/union_parameter.go | 397 ++ Examples/test-suite/go/union_scope.go | 75 + Examples/test-suite/go/unions.go | 448 ++ Examples/test-suite/go/unions_runme | Bin 0 -> 592772 bytes Examples/test-suite/go/using1.go | 82 + Examples/test-suite/go/using1_runme | Bin 0 -> 498320 bytes Examples/test-suite/go/using2.go | 82 + Examples/test-suite/go/using2_runme | Bin 0 -> 498344 bytes Examples/test-suite/go/using_composition.go | 523 ++ Examples/test-suite/go/using_composition_runme | Bin 0 -> 643361 bytes .../go/using_directive_and_declaration.go | 499 ++ .../go/using_directive_and_declaration_forward.go | 613 +++ Examples/test-suite/go/using_extend.go | 412 ++ Examples/test-suite/go/using_extend_runme | Bin 0 -> 611645 bytes Examples/test-suite/go/using_inherit.go | 637 +++ Examples/test-suite/go/using_inherit_runme | Bin 0 -> 676090 bytes Examples/test-suite/go/using_namespace.go | 334 ++ Examples/test-suite/go/using_namespace_loop.go | 29 + Examples/test-suite/go/using_pointers.go | 226 + Examples/test-suite/go/using_private.go | 315 ++ Examples/test-suite/go/using_private_runme | Bin 0 -> 549711 bytes Examples/test-suite/go/using_protected.go | 221 + Examples/test-suite/go/using_protected_runme | Bin 0 -> 539085 bytes Examples/test-suite/go/valuewrapper.go | 149 + Examples/test-suite/go/valuewrapper_base.go | 151 + Examples/test-suite/go/valuewrapper_const.go | 165 + Examples/test-suite/go/valuewrapper_opaque.go | 481 ++ Examples/test-suite/go/varargs.go | 244 + Examples/test-suite/go/varargs_overload.go | 165 + Examples/test-suite/go/varargs_overload_runme | Bin 0 -> 534491 bytes Examples/test-suite/go/varargs_runme | Bin 0 -> 546950 bytes Examples/test-suite/go/virtual_destructor.go | 110 + Examples/test-suite/go/virtual_poly.go | 1317 +++++ Examples/test-suite/go/virtual_poly_runme | Bin 0 -> 640275 bytes Examples/test-suite/go/virtual_poly_wrap.h | 16 + .../test-suite/go/virtual_vs_nonvirtual_base.go | 337 ++ Examples/test-suite/go/voidtest.go | 155 + Examples/test-suite/go/voidtest_runme | Bin 0 -> 523754 bytes Examples/test-suite/go/wallkw.go | 64 + Examples/test-suite/go/wrapmacro.go | 68 + Examples/test-suite/go/wrapmacro_runme | Bin 0 -> 509094 bytes Examples/test-suite/overload_polymorphic.i | 25 + Examples/test-suite/overload_polymorphic.i~ | 25 + Examples/test-suite/overload_rename.i~ | 30 + Source/Modules/go.cxx | 2 +- Source/Modules/go.cxx~ | 5385 ++++++++++++++++++++ 663 files changed, 180498 insertions(+), 1 deletion(-) create mode 100644 Examples/test-suite/common.mk~ create mode 100644 Examples/test-suite/go/abstract_access.go create mode 100755 Examples/test-suite/go/abstract_access_runme create mode 100644 Examples/test-suite/go/abstract_inherit.go create mode 100644 Examples/test-suite/go/abstract_inherit_ok.go create mode 100644 Examples/test-suite/go/abstract_signature.go create mode 100644 Examples/test-suite/go/abstract_typedef.go create mode 100644 Examples/test-suite/go/abstract_typedef2.go create mode 100755 Examples/test-suite/go/abstract_typedef2_runme create mode 100755 Examples/test-suite/go/abstract_typedef_runme create mode 100644 Examples/test-suite/go/abstract_virtual.go create mode 100755 Examples/test-suite/go/abstract_virtual_runme create mode 100644 Examples/test-suite/go/access_change.go create mode 100644 Examples/test-suite/go/add_link.go create mode 100644 Examples/test-suite/go/aggregate.go create mode 100644 Examples/test-suite/go/allowexcept.go create mode 100644 Examples/test-suite/go/allprotected.go create mode 100644 Examples/test-suite/go/allprotected_not.go create mode 100644 Examples/test-suite/go/allprotected_not_wrap.h create mode 100644 Examples/test-suite/go/allprotected_wrap.h create mode 100644 Examples/test-suite/go/anonymous_bitfield.go create mode 100644 Examples/test-suite/go/apply_signed_char.go create mode 100644 Examples/test-suite/go/apply_signed_char_wrap.h create mode 100644 Examples/test-suite/go/apply_strings.go create mode 100644 Examples/test-suite/go/apply_strings_wrap.h create mode 100644 Examples/test-suite/go/argout.go create mode 100755 Examples/test-suite/go/argout_runme create mode 100644 Examples/test-suite/go/array_member.go create mode 100755 Examples/test-suite/go/array_member_runme create mode 100644 Examples/test-suite/go/array_typedef_memberin.go create mode 100644 Examples/test-suite/go/arrayref.go create mode 100644 Examples/test-suite/go/arrays.go create mode 100644 Examples/test-suite/go/arrays_dimensionless.go create mode 100644 Examples/test-suite/go/arrays_global.go create mode 100755 Examples/test-suite/go/arrays_global_runme create mode 100644 Examples/test-suite/go/arrays_global_twodim.go create mode 100644 Examples/test-suite/go/arrays_scope.go create mode 100644 Examples/test-suite/go/autodoc.go create mode 100644 Examples/test-suite/go/bloody_hell.go create mode 100644 Examples/test-suite/go/bom_utf8.go create mode 100644 Examples/test-suite/go/bools.go create mode 100644 Examples/test-suite/go/c_delete.go create mode 100644 Examples/test-suite/go/c_delete_function.go create mode 100644 Examples/test-suite/go/cast_operator.go create mode 100644 Examples/test-suite/go/casts.go create mode 100644 Examples/test-suite/go/catches.go create mode 100644 Examples/test-suite/go/char_binary.go create mode 100755 Examples/test-suite/go/char_binary_runme create mode 100644 Examples/test-suite/go/char_constant.go create mode 100644 Examples/test-suite/go/char_strings.go create mode 100644 Examples/test-suite/go/class_forward.go create mode 100644 Examples/test-suite/go/class_ignore.go create mode 100755 Examples/test-suite/go/class_ignore_runme create mode 100644 Examples/test-suite/go/class_scope_weird.go create mode 100755 Examples/test-suite/go/class_scope_weird_runme create mode 100644 Examples/test-suite/go/clientdata_prop_a.go create mode 100644 Examples/test-suite/go/clientdata_prop_b.go create mode 100644 Examples/test-suite/go/compactdefaultargs.go create mode 100755 Examples/test-suite/go/compactdefaultargs_runme create mode 100644 Examples/test-suite/go/const_const.go create mode 100644 Examples/test-suite/go/const_const_2.go create mode 100644 Examples/test-suite/go/constant_expr.go create mode 100644 Examples/test-suite/go/constant_pointers.go create mode 100644 Examples/test-suite/go/constover.go create mode 100755 Examples/test-suite/go/constover_runme create mode 100644 Examples/test-suite/go/constructor_copy.go create mode 100755 Examples/test-suite/go/constructor_copy_runme create mode 100644 Examples/test-suite/go/constructor_exception.go create mode 100644 Examples/test-suite/go/constructor_explicit.go create mode 100644 Examples/test-suite/go/constructor_ignore.go create mode 100644 Examples/test-suite/go/constructor_rename.go create mode 100644 Examples/test-suite/go/constructor_value.go create mode 100644 Examples/test-suite/go/contract.go create mode 100755 Examples/test-suite/go/contract_runme create mode 100644 Examples/test-suite/go/conversion.go create mode 100644 Examples/test-suite/go/conversion_namespace.go create mode 100644 Examples/test-suite/go/conversion_ns_template.go create mode 100644 Examples/test-suite/go/cplusplus_throw.go create mode 100644 Examples/test-suite/go/cpp_basic.go create mode 100644 Examples/test-suite/go/cpp_enum.go create mode 100755 Examples/test-suite/go/cpp_enum_runme create mode 100644 Examples/test-suite/go/cpp_namespace.go create mode 100755 Examples/test-suite/go/cpp_namespace_runme create mode 100644 Examples/test-suite/go/cpp_nodefault.go create mode 100644 Examples/test-suite/go/cpp_static.go create mode 100755 Examples/test-suite/go/cpp_static_runme create mode 100644 Examples/test-suite/go/cpp_typedef.go create mode 100644 Examples/test-suite/go/curiously_recurring_template_pattern.go create mode 100644 Examples/test-suite/go/default_arg_values.go create mode 100644 Examples/test-suite/go/default_args.go create mode 100755 Examples/test-suite/go/default_args_runme create mode 100644 Examples/test-suite/go/default_constructor.go create mode 100755 Examples/test-suite/go/default_constructor_runme create mode 100644 Examples/test-suite/go/defvalue_constructor.go create mode 100644 Examples/test-suite/go/derived_byvalue.go create mode 100644 Examples/test-suite/go/derived_nested.go create mode 100644 Examples/test-suite/go/destructor_reprotected.go create mode 100644 Examples/test-suite/go/director_abstract.go create mode 100644 Examples/test-suite/go/director_abstract_wrap.h create mode 100644 Examples/test-suite/go/director_alternating.go create mode 100755 Examples/test-suite/go/director_alternating_runme create mode 100644 Examples/test-suite/go/director_alternating_wrap.h create mode 100644 Examples/test-suite/go/director_basic.go create mode 100755 Examples/test-suite/go/director_basic_runme create mode 100644 Examples/test-suite/go/director_basic_wrap.h create mode 100644 Examples/test-suite/go/director_binary_string.go create mode 100644 Examples/test-suite/go/director_binary_string_wrap.h create mode 100644 Examples/test-suite/go/director_classes.go create mode 100644 Examples/test-suite/go/director_classes_wrap.h create mode 100644 Examples/test-suite/go/director_classic.go create mode 100755 Examples/test-suite/go/director_classic_runme create mode 100644 Examples/test-suite/go/director_classic_wrap.h create mode 100644 Examples/test-suite/go/director_constructor.go create mode 100644 Examples/test-suite/go/director_constructor_wrap.h create mode 100644 Examples/test-suite/go/director_default.go create mode 100755 Examples/test-suite/go/director_default_runme create mode 100644 Examples/test-suite/go/director_default_wrap.h create mode 100644 Examples/test-suite/go/director_detect.go create mode 100755 Examples/test-suite/go/director_detect_runme create mode 100644 Examples/test-suite/go/director_detect_wrap.h create mode 100644 Examples/test-suite/go/director_enum.go create mode 100755 Examples/test-suite/go/director_enum_runme create mode 100644 Examples/test-suite/go/director_enum_wrap.h create mode 100644 Examples/test-suite/go/director_exception.go create mode 100755 Examples/test-suite/go/director_exception_runme create mode 100644 Examples/test-suite/go/director_exception_wrap.h create mode 100644 Examples/test-suite/go/director_extend.go create mode 100755 Examples/test-suite/go/director_extend_runme create mode 100644 Examples/test-suite/go/director_extend_wrap.h create mode 100644 Examples/test-suite/go/director_finalizer.go create mode 100755 Examples/test-suite/go/director_finalizer_runme create mode 100644 Examples/test-suite/go/director_finalizer_wrap.h create mode 100644 Examples/test-suite/go/director_frob.go create mode 100755 Examples/test-suite/go/director_frob_runme create mode 100644 Examples/test-suite/go/director_frob_wrap.h create mode 100644 Examples/test-suite/go/director_ignore.go create mode 100644 Examples/test-suite/go/director_ignore_wrap.h create mode 100644 Examples/test-suite/go/director_keywords.go create mode 100644 Examples/test-suite/go/director_keywords_wrap.h create mode 100644 Examples/test-suite/go/director_namespace_clash.go create mode 100644 Examples/test-suite/go/director_namespace_clash_wrap.h create mode 100644 Examples/test-suite/go/director_nested.go create mode 100755 Examples/test-suite/go/director_nested_runme create mode 100644 Examples/test-suite/go/director_nested_wrap.h create mode 100644 Examples/test-suite/go/director_nspace.go create mode 100644 Examples/test-suite/go/director_nspace_director_name_collision.go create mode 100644 Examples/test-suite/go/director_nspace_director_name_collision_wrap.h create mode 100644 Examples/test-suite/go/director_nspace_wrap.h create mode 100644 Examples/test-suite/go/director_overload.go create mode 100644 Examples/test-suite/go/director_overload2.go create mode 100644 Examples/test-suite/go/director_overload2_wrap.h create mode 100644 Examples/test-suite/go/director_overload_wrap.h create mode 100644 Examples/test-suite/go/director_primitives.go create mode 100644 Examples/test-suite/go/director_primitives_wrap.h create mode 100644 Examples/test-suite/go/director_protected.go create mode 100644 Examples/test-suite/go/director_protected_overloaded.go create mode 100644 Examples/test-suite/go/director_protected_overloaded_wrap.h create mode 100755 Examples/test-suite/go/director_protected_runme create mode 100644 Examples/test-suite/go/director_protected_wrap.h create mode 100644 Examples/test-suite/go/director_redefined.go create mode 100644 Examples/test-suite/go/director_redefined_wrap.h create mode 100644 Examples/test-suite/go/director_smartptr.go create mode 100644 Examples/test-suite/go/director_smartptr_wrap.h create mode 100644 Examples/test-suite/go/director_string.go create mode 100755 Examples/test-suite/go/director_string_runme create mode 100644 Examples/test-suite/go/director_string_wrap.h create mode 100644 Examples/test-suite/go/director_thread.go create mode 100644 Examples/test-suite/go/director_thread_wrap.h create mode 100644 Examples/test-suite/go/director_unroll.go create mode 100755 Examples/test-suite/go/director_unroll_runme create mode 100644 Examples/test-suite/go/director_unroll_wrap.h create mode 100644 Examples/test-suite/go/director_using.go create mode 100644 Examples/test-suite/go/director_using_wrap.h create mode 100644 Examples/test-suite/go/director_wombat.go create mode 100644 Examples/test-suite/go/director_wombat_wrap.h create mode 100644 Examples/test-suite/go/disown.go create mode 100755 Examples/test-suite/go/disown_runme create mode 100644 Examples/test-suite/go/dynamic_cast.go create mode 100755 Examples/test-suite/go/dynamic_cast_runme create mode 100644 Examples/test-suite/go/empty.go create mode 100755 Examples/test-suite/go/empty_runme create mode 100644 Examples/test-suite/go/enum_forward.go create mode 100644 Examples/test-suite/go/enum_ignore.go create mode 100644 Examples/test-suite/go/enum_macro.go create mode 100644 Examples/test-suite/go/enum_missing.go create mode 100644 Examples/test-suite/go/enum_plus.go create mode 100644 Examples/test-suite/go/enum_rename.go create mode 100644 Examples/test-suite/go/enum_scope_template.go create mode 100644 Examples/test-suite/go/enum_template.go create mode 100755 Examples/test-suite/go/enum_template_runme create mode 100644 Examples/test-suite/go/enum_thorough.go create mode 100644 Examples/test-suite/go/enum_var.go create mode 100644 Examples/test-suite/go/enums.go create mode 100755 Examples/test-suite/go/enums_runme create mode 100644 Examples/test-suite/go/equality.go create mode 100644 Examples/test-suite/go/evil_diamond.go create mode 100644 Examples/test-suite/go/evil_diamond_ns.go create mode 100644 Examples/test-suite/go/evil_diamond_prop.go create mode 100644 Examples/test-suite/go/exception_order.go create mode 100755 Examples/test-suite/go/exception_order_runme create mode 100644 Examples/test-suite/go/expressions.go create mode 100644 Examples/test-suite/go/extend.go create mode 100644 Examples/test-suite/go/extend_constructor_destructor.go create mode 100644 Examples/test-suite/go/extend_default.go create mode 100644 Examples/test-suite/go/extend_placement.go create mode 100755 Examples/test-suite/go/extend_placement_runme create mode 100644 Examples/test-suite/go/extend_special_variables.go create mode 100644 Examples/test-suite/go/extend_template.go create mode 100644 Examples/test-suite/go/extend_template_ns.go create mode 100755 Examples/test-suite/go/extend_template_ns_runme create mode 100755 Examples/test-suite/go/extend_template_runme create mode 100644 Examples/test-suite/go/extend_typedef_class.go create mode 100644 Examples/test-suite/go/extern_c.go create mode 100755 Examples/test-suite/go/extern_c_runme create mode 100644 Examples/test-suite/go/extern_declaration.go create mode 100644 Examples/test-suite/go/extern_namespace.go create mode 100644 Examples/test-suite/go/extern_throws.go create mode 100644 Examples/test-suite/go/features.go create mode 100644 Examples/test-suite/go/fragments.go create mode 100644 Examples/test-suite/go/friends.go create mode 100755 Examples/test-suite/go/friends_runme create mode 100644 Examples/test-suite/go/funcptr.go create mode 100644 Examples/test-suite/go/funcptr_cpp.go create mode 100644 Examples/test-suite/go/function_typedef.go create mode 100644 Examples/test-suite/go/fvirtual.go create mode 100755 Examples/test-suite/go/fvirtual_runme create mode 100644 Examples/test-suite/go/global_functions.go create mode 100644 Examples/test-suite/go/global_namespace.go create mode 100644 Examples/test-suite/go/global_ns_arg.go create mode 100755 Examples/test-suite/go/global_ns_arg_runme create mode 100644 Examples/test-suite/go/global_scope_types.go create mode 100644 Examples/test-suite/go/global_vars.go create mode 100644 Examples/test-suite/go/go_director_inout.go create mode 100755 Examples/test-suite/go/go_director_inout_runme create mode 100644 Examples/test-suite/go/go_director_inout_wrap.h create mode 100644 Examples/test-suite/go/go_inout.go create mode 100755 Examples/test-suite/go/go_inout_runme create mode 100644 Examples/test-suite/go/grouping.go create mode 100755 Examples/test-suite/go/grouping_runme create mode 100644 Examples/test-suite/go/ignore_parameter.go create mode 100644 Examples/test-suite/go/ignore_template_constructor.go create mode 100644 Examples/test-suite/go/immutable_values.go create mode 100644 Examples/test-suite/go/import_nomodule.go create mode 100755 Examples/test-suite/go/import_nomodule_runme create mode 100644 Examples/test-suite/go/import_stl_a.go create mode 100644 Examples/test-suite/go/import_stl_b.go create mode 100644 Examples/test-suite/go/imports_a.go create mode 100644 Examples/test-suite/go/imports_b.go create mode 100755 Examples/test-suite/go/imports_runme create mode 100644 Examples/test-suite/go/inctest.go create mode 100755 Examples/test-suite/go/inctest_runme create mode 100644 Examples/test-suite/go/infinity.go create mode 100644 Examples/test-suite/go/inherit.go create mode 100644 Examples/test-suite/go/inherit_missing.go create mode 100755 Examples/test-suite/go/inherit_missing_runme create mode 100644 Examples/test-suite/go/inherit_same_name.go create mode 100644 Examples/test-suite/go/inherit_target_language.go create mode 100644 Examples/test-suite/go/inherit_void_arg.go create mode 100644 Examples/test-suite/go/inline_initializer.go create mode 100644 Examples/test-suite/go/insert_directive.go create mode 100644 Examples/test-suite/go/integers.go create mode 100644 Examples/test-suite/go/keyword_rename.go create mode 100755 Examples/test-suite/go/keyword_rename_runme create mode 100644 Examples/test-suite/go/kind.go create mode 100644 Examples/test-suite/go/langobj.go create mode 100644 Examples/test-suite/go/lextype.go create mode 100644 Examples/test-suite/go/li_attribute.go create mode 100755 Examples/test-suite/go/li_attribute_runme create mode 100644 Examples/test-suite/go/li_attribute_template.go create mode 100644 Examples/test-suite/go/li_boost_shared_ptr.go create mode 100644 Examples/test-suite/go/li_boost_shared_ptr_attribute.go create mode 100644 Examples/test-suite/go/li_boost_shared_ptr_bits.go create mode 100644 Examples/test-suite/go/li_boost_shared_ptr_template.go create mode 100644 Examples/test-suite/go/li_carrays.go create mode 100755 Examples/test-suite/go/li_carrays_runme create mode 100644 Examples/test-suite/go/li_cdata.go create mode 100755 Examples/test-suite/go/li_cdata_runme create mode 100644 Examples/test-suite/go/li_cmalloc.go create mode 100755 Examples/test-suite/go/li_cmalloc_runme create mode 100644 Examples/test-suite/go/li_constraints.go create mode 100644 Examples/test-suite/go/li_cpointer.go create mode 100755 Examples/test-suite/go/li_cpointer_runme create mode 100644 Examples/test-suite/go/li_math.go create mode 100644 Examples/test-suite/go/li_std_auto_ptr.go create mode 100644 Examples/test-suite/go/li_std_combinations.go create mode 100644 Examples/test-suite/go/li_std_deque.go create mode 100644 Examples/test-suite/go/li_std_except.go create mode 100644 Examples/test-suite/go/li_std_except_as_class.go create mode 100644 Examples/test-suite/go/li_std_map.go create mode 100755 Examples/test-suite/go/li_std_map_runme create mode 100644 Examples/test-suite/go/li_std_pair.go create mode 100644 Examples/test-suite/go/li_std_pair_using.go create mode 100644 Examples/test-suite/go/li_std_string.go create mode 100644 Examples/test-suite/go/li_std_vector.go create mode 100644 Examples/test-suite/go/li_std_vector_enum.go create mode 100644 Examples/test-suite/go/li_std_vector_member_var.go create mode 100644 Examples/test-suite/go/li_stdint.go create mode 100644 Examples/test-suite/go/li_swigtype_inout.go create mode 100644 Examples/test-suite/go/li_typemaps.go create mode 100644 Examples/test-suite/go/li_typemaps_apply.go create mode 100644 Examples/test-suite/go/li_windows.go create mode 100644 Examples/test-suite/go/long_long.go create mode 100644 Examples/test-suite/go/long_long_apply.go create mode 100644 Examples/test-suite/go/member_funcptr_galore.go create mode 100644 Examples/test-suite/go/member_pointer.go create mode 100755 Examples/test-suite/go/member_pointer_runme create mode 100644 Examples/test-suite/go/member_template.go create mode 100644 Examples/test-suite/go/memberin_extend.go create mode 100644 Examples/test-suite/go/memberin_extend_c.go create mode 100755 Examples/test-suite/go/memberin_extend_c_runme create mode 100644 Examples/test-suite/go/minherit.go create mode 100644 Examples/test-suite/go/minherit2.go create mode 100755 Examples/test-suite/go/minherit_runme create mode 100644 Examples/test-suite/go/mixed_types.go create mode 100644 Examples/test-suite/go/mod_a.go create mode 100644 Examples/test-suite/go/mod_b.go create mode 100755 Examples/test-suite/go/mod_runme create mode 100644 Examples/test-suite/go/multi_import_a.go create mode 100644 Examples/test-suite/go/multi_import_b.go create mode 100755 Examples/test-suite/go/multi_import_runme create mode 100644 Examples/test-suite/go/multiple_inheritance.go create mode 100644 Examples/test-suite/go/name.go create mode 100644 Examples/test-suite/go/name_cxx.go create mode 100644 Examples/test-suite/go/name_warnings.go create mode 100644 Examples/test-suite/go/namespace_class.go create mode 100755 Examples/test-suite/go/namespace_class_runme create mode 100644 Examples/test-suite/go/namespace_enum.go create mode 100644 Examples/test-suite/go/namespace_extend.go create mode 100644 Examples/test-suite/go/namespace_forward_declaration.go create mode 100644 Examples/test-suite/go/namespace_nested.go create mode 100644 Examples/test-suite/go/namespace_spaces.go create mode 100644 Examples/test-suite/go/namespace_template.go create mode 100644 Examples/test-suite/go/namespace_typedef_class.go create mode 100644 Examples/test-suite/go/namespace_typemap.go create mode 100755 Examples/test-suite/go/namespace_typemap_runme create mode 100644 Examples/test-suite/go/namespace_union.go create mode 100644 Examples/test-suite/go/namespace_virtual_method.go create mode 100755 Examples/test-suite/go/namespace_virtual_method_runme create mode 100644 Examples/test-suite/go/naturalvar.go create mode 100644 Examples/test-suite/go/naturalvar_more.go create mode 100644 Examples/test-suite/go/naturalvar_onoff.go create mode 100755 Examples/test-suite/go/naturalvar_runme create mode 100644 Examples/test-suite/go/nested.go create mode 100644 Examples/test-suite/go/nested_class.go create mode 100644 Examples/test-suite/go/nested_comment.go create mode 100644 Examples/test-suite/go/nested_directors.go create mode 100644 Examples/test-suite/go/nested_directors_wrap.h create mode 100644 Examples/test-suite/go/nested_extend_c.go create mode 100644 Examples/test-suite/go/nested_scope.go create mode 100644 Examples/test-suite/go/nested_structs.go create mode 100644 Examples/test-suite/go/nested_workaround.go create mode 100755 Examples/test-suite/go/nested_workaround_runme create mode 100644 Examples/test-suite/go/newobject1.go create mode 100644 Examples/test-suite/go/newobject2.go create mode 100644 Examples/test-suite/go/nspace.go create mode 100644 Examples/test-suite/go/nspace_extend.go create mode 100644 Examples/test-suite/go/null_pointer.go create mode 100644 Examples/test-suite/go/operator_overload.go create mode 100644 Examples/test-suite/go/operator_overload_break.go create mode 100644 Examples/test-suite/go/operator_pointer_ref.go create mode 100644 Examples/test-suite/go/operbool.go create mode 100644 Examples/test-suite/go/ordering.go create mode 100644 Examples/test-suite/go/overload_bool.go create mode 100644 Examples/test-suite/go/overload_copy.go create mode 100755 Examples/test-suite/go/overload_copy_runme create mode 100644 Examples/test-suite/go/overload_extend.go create mode 100755 Examples/test-suite/go/overload_extend_runme create mode 100644 Examples/test-suite/go/overload_extendc.go create mode 100755 Examples/test-suite/go/overload_extendc_runme create mode 100644 Examples/test-suite/go/overload_method.go create mode 100644 Examples/test-suite/go/overload_numeric.go create mode 100644 Examples/test-suite/go/overload_polymorphic.go create mode 100755 Examples/test-suite/go/overload_polymorphic_runme create mode 100644 Examples/test-suite/go/overload_polymorphic_runme.go create mode 100644 Examples/test-suite/go/overload_polymorphic_runme.go~ create mode 100644 Examples/test-suite/go/overload_rename.go create mode 100755 Examples/test-suite/go/overload_rename_runme create mode 100644 Examples/test-suite/go/overload_return_type.go create mode 100644 Examples/test-suite/go/overload_simple.go create mode 100755 Examples/test-suite/go/overload_simple_runme create mode 100644 Examples/test-suite/go/overload_subtype.go create mode 100755 Examples/test-suite/go/overload_subtype_runme create mode 100644 Examples/test-suite/go/overload_template.go create mode 100644 Examples/test-suite/go/overload_template_fast.go create mode 100755 Examples/test-suite/go/overload_template_fast_runme create mode 100755 Examples/test-suite/go/overload_template_runme create mode 100644 Examples/test-suite/go/packageoption_a.go create mode 100644 Examples/test-suite/go/packageoption_b.go create mode 100644 Examples/test-suite/go/packageoption_c.go create mode 100644 Examples/test-suite/go/pointer_reference.go create mode 100644 Examples/test-suite/go/preproc.go create mode 100644 Examples/test-suite/go/preproc_constants.go create mode 100644 Examples/test-suite/go/preproc_constants_c.go create mode 100644 Examples/test-suite/go/preproc_defined.go create mode 100644 Examples/test-suite/go/preproc_include.go create mode 100644 Examples/test-suite/go/preproc_line_file.go create mode 100755 Examples/test-suite/go/preproc_runme create mode 100644 Examples/test-suite/go/primitive_ref.go create mode 100755 Examples/test-suite/go/primitive_ref_runme create mode 100644 Examples/test-suite/go/private_assign.go create mode 100644 Examples/test-suite/go/protected_rename.go create mode 100644 Examples/test-suite/go/pure_virtual.go create mode 100644 Examples/test-suite/go/redefined.go create mode 100644 Examples/test-suite/go/redefined_not.go create mode 100644 Examples/test-suite/go/refcount.go create mode 100755 Examples/test-suite/go/refcount_runme create mode 100644 Examples/test-suite/go/reference_global_vars.go create mode 100755 Examples/test-suite/go/reference_global_vars_runme create mode 100644 Examples/test-suite/go/register_par.go create mode 100644 Examples/test-suite/go/rename1.go create mode 100644 Examples/test-suite/go/rename2.go create mode 100644 Examples/test-suite/go/rename3.go create mode 100644 Examples/test-suite/go/rename4.go create mode 100644 Examples/test-suite/go/rename_pcre_encoder.go create mode 100644 Examples/test-suite/go/rename_pcre_enum.go create mode 100644 Examples/test-suite/go/rename_predicates.go create mode 100644 Examples/test-suite/go/rename_scope.go create mode 100755 Examples/test-suite/go/rename_scope_runme create mode 100644 Examples/test-suite/go/rename_simple.go create mode 100755 Examples/test-suite/go/rename_simple_runme create mode 100644 Examples/test-suite/go/rename_strip_encoder.go create mode 100755 Examples/test-suite/go/rename_strip_encoder_runme create mode 100644 Examples/test-suite/go/restrict_cplusplus.go create mode 100644 Examples/test-suite/go/ret_by_value.go create mode 100755 Examples/test-suite/go/ret_by_value_runme create mode 100644 Examples/test-suite/go/return_const_value.go create mode 100755 Examples/test-suite/go/return_const_value_runme create mode 100644 Examples/test-suite/go/return_value_scope.go create mode 100644 Examples/test-suite/go/rname.go create mode 100644 Examples/test-suite/go/samename.go create mode 100644 Examples/test-suite/go/simple_array.go create mode 100644 Examples/test-suite/go/sizeof_pointer.go create mode 100644 Examples/test-suite/go/sizet.go create mode 100644 Examples/test-suite/go/smart_pointer_const.go create mode 100644 Examples/test-suite/go/smart_pointer_const2.go create mode 100644 Examples/test-suite/go/smart_pointer_const_overload.go create mode 100644 Examples/test-suite/go/smart_pointer_extend.go create mode 100755 Examples/test-suite/go/smart_pointer_extend_runme create mode 100644 Examples/test-suite/go/smart_pointer_inherit.go create mode 100644 Examples/test-suite/go/smart_pointer_member.go create mode 100755 Examples/test-suite/go/smart_pointer_member_runme create mode 100644 Examples/test-suite/go/smart_pointer_multi.go create mode 100755 Examples/test-suite/go/smart_pointer_multi_runme create mode 100644 Examples/test-suite/go/smart_pointer_multi_typedef.go create mode 100755 Examples/test-suite/go/smart_pointer_multi_typedef_runme create mode 100644 Examples/test-suite/go/smart_pointer_namespace.go create mode 100644 Examples/test-suite/go/smart_pointer_namespace2.go create mode 100644 Examples/test-suite/go/smart_pointer_not.go create mode 100644 Examples/test-suite/go/smart_pointer_overload.go create mode 100755 Examples/test-suite/go/smart_pointer_overload_runme create mode 100644 Examples/test-suite/go/smart_pointer_protected.go create mode 100644 Examples/test-suite/go/smart_pointer_rename.go create mode 100755 Examples/test-suite/go/smart_pointer_rename_runme create mode 100644 Examples/test-suite/go/smart_pointer_simple.go create mode 100755 Examples/test-suite/go/smart_pointer_simple_runme create mode 100644 Examples/test-suite/go/smart_pointer_static.go create mode 100644 Examples/test-suite/go/smart_pointer_template_const_overload.go create mode 100644 Examples/test-suite/go/smart_pointer_template_defaults_overload.go create mode 100644 Examples/test-suite/go/smart_pointer_templatemethods.go create mode 100644 Examples/test-suite/go/smart_pointer_templatevariables.go create mode 100755 Examples/test-suite/go/smart_pointer_templatevariables_runme create mode 100644 Examples/test-suite/go/smart_pointer_typedef.go create mode 100755 Examples/test-suite/go/smart_pointer_typedef_runme create mode 100644 Examples/test-suite/go/sneaky1.go create mode 100755 Examples/test-suite/go/sneaky1_runme create mode 100644 Examples/test-suite/go/special_variable_macros.go create mode 100755 Examples/test-suite/go/special_variable_macros_runme create mode 100644 Examples/test-suite/go/special_variables.go create mode 100644 Examples/test-suite/go/special_variables_wrap.h create mode 100644 Examples/test-suite/go/static_array_member.go create mode 100644 Examples/test-suite/go/static_const_member.go create mode 100644 Examples/test-suite/go/static_const_member_2.go create mode 100755 Examples/test-suite/go/static_const_member_2_runme create mode 100644 Examples/test-suite/go/string_simple.go create mode 100644 Examples/test-suite/go/struct_initialization.go create mode 100644 Examples/test-suite/go/struct_initialization_cpp.go create mode 100755 Examples/test-suite/go/struct_initialization_runme create mode 100644 Examples/test-suite/go/struct_rename.go create mode 100755 Examples/test-suite/go/struct_rename_runme create mode 100644 Examples/test-suite/go/struct_value.go create mode 100755 Examples/test-suite/go/struct_value_runme create mode 100644 Examples/test-suite/go/symbol_clash.go create mode 100644 Examples/test-suite/go/template_arg_replace.go create mode 100644 Examples/test-suite/go/template_arg_scope.go create mode 100644 Examples/test-suite/go/template_arg_typename.go create mode 100644 Examples/test-suite/go/template_array_numeric.go create mode 100644 Examples/test-suite/go/template_base_template.go create mode 100644 Examples/test-suite/go/template_basic.go create mode 100644 Examples/test-suite/go/template_classes.go create mode 100644 Examples/test-suite/go/template_const_ref.go create mode 100644 Examples/test-suite/go/template_construct.go create mode 100644 Examples/test-suite/go/template_default.go create mode 100644 Examples/test-suite/go/template_default2.go create mode 100644 Examples/test-suite/go/template_default_arg.go create mode 100755 Examples/test-suite/go/template_default_arg_runme create mode 100644 Examples/test-suite/go/template_default_arg_virtual_destructor.go create mode 100644 Examples/test-suite/go/template_default_class_parms.go create mode 100644 Examples/test-suite/go/template_default_class_parms_typedef.go create mode 100644 Examples/test-suite/go/template_default_inherit.go create mode 100644 Examples/test-suite/go/template_default_qualify.go create mode 100644 Examples/test-suite/go/template_default_vw.go create mode 100644 Examples/test-suite/go/template_enum.go create mode 100644 Examples/test-suite/go/template_enum_ns_inherit.go create mode 100644 Examples/test-suite/go/template_enum_typedef.go create mode 100644 Examples/test-suite/go/template_explicit.go create mode 100644 Examples/test-suite/go/template_extend1.go create mode 100755 Examples/test-suite/go/template_extend1_runme create mode 100644 Examples/test-suite/go/template_extend2.go create mode 100755 Examples/test-suite/go/template_extend2_runme create mode 100644 Examples/test-suite/go/template_extend_overload.go create mode 100644 Examples/test-suite/go/template_extend_overload_2.go create mode 100644 Examples/test-suite/go/template_forward.go create mode 100644 Examples/test-suite/go/template_inherit.go create mode 100644 Examples/test-suite/go/template_inherit_abstract.go create mode 100755 Examples/test-suite/go/template_inherit_runme create mode 100644 Examples/test-suite/go/template_int_const.go create mode 100644 Examples/test-suite/go/template_methods.go create mode 100644 Examples/test-suite/go/template_namespace_forward_declaration.go create mode 100644 Examples/test-suite/go/template_nested.go create mode 100644 Examples/test-suite/go/template_nested_typemaps.go create mode 100644 Examples/test-suite/go/template_ns.go create mode 100644 Examples/test-suite/go/template_ns2.go create mode 100644 Examples/test-suite/go/template_ns3.go create mode 100644 Examples/test-suite/go/template_ns4.go create mode 100755 Examples/test-suite/go/template_ns4_runme create mode 100644 Examples/test-suite/go/template_ns_enum.go create mode 100644 Examples/test-suite/go/template_ns_enum2.go create mode 100644 Examples/test-suite/go/template_ns_inherit.go create mode 100755 Examples/test-suite/go/template_ns_runme create mode 100644 Examples/test-suite/go/template_ns_scope.go create mode 100644 Examples/test-suite/go/template_opaque.go create mode 100755 Examples/test-suite/go/template_opaque_runme create mode 100644 Examples/test-suite/go/template_partial_arg.go create mode 100644 Examples/test-suite/go/template_partial_specialization.go create mode 100644 Examples/test-suite/go/template_partial_specialization_typedef.go create mode 100644 Examples/test-suite/go/template_qualifier.go create mode 100644 Examples/test-suite/go/template_ref_type.go create mode 100755 Examples/test-suite/go/template_ref_type_runme create mode 100644 Examples/test-suite/go/template_rename.go create mode 100755 Examples/test-suite/go/template_rename_runme create mode 100644 Examples/test-suite/go/template_retvalue.go create mode 100644 Examples/test-suite/go/template_specialization.go create mode 100644 Examples/test-suite/go/template_specialization_defarg.go create mode 100644 Examples/test-suite/go/template_specialization_enum.go create mode 100644 Examples/test-suite/go/template_static.go create mode 100755 Examples/test-suite/go/template_static_runme create mode 100644 Examples/test-suite/go/template_tbase_template.go create mode 100755 Examples/test-suite/go/template_tbase_template_runme create mode 100644 Examples/test-suite/go/template_template_parameters.go create mode 100644 Examples/test-suite/go/template_type_namespace.go create mode 100755 Examples/test-suite/go/template_type_namespace_runme create mode 100644 Examples/test-suite/go/template_typedef.go create mode 100644 Examples/test-suite/go/template_typedef_class_template.go create mode 100644 Examples/test-suite/go/template_typedef_cplx.go create mode 100644 Examples/test-suite/go/template_typedef_cplx2.go create mode 100644 Examples/test-suite/go/template_typedef_cplx3.go create mode 100755 Examples/test-suite/go/template_typedef_cplx3_runme create mode 100644 Examples/test-suite/go/template_typedef_cplx4.go create mode 100755 Examples/test-suite/go/template_typedef_cplx4_runme create mode 100644 Examples/test-suite/go/template_typedef_cplx5.go create mode 100644 Examples/test-suite/go/template_typedef_fnc.go create mode 100644 Examples/test-suite/go/template_typedef_funcptr.go create mode 100644 Examples/test-suite/go/template_typedef_import.go create mode 100644 Examples/test-suite/go/template_typedef_inherit.go create mode 100644 Examples/test-suite/go/template_typedef_ns.go create mode 100644 Examples/test-suite/go/template_typedef_ptr.go create mode 100644 Examples/test-suite/go/template_typedef_rec.go create mode 100644 Examples/test-suite/go/template_typedef_typedef.go create mode 100644 Examples/test-suite/go/template_typemaps.go create mode 100644 Examples/test-suite/go/template_typemaps_typedef.go create mode 100644 Examples/test-suite/go/template_typemaps_typedef2.go create mode 100644 Examples/test-suite/go/template_using.go create mode 100644 Examples/test-suite/go/template_using_directive_and_declaration_forward.go create mode 100644 Examples/test-suite/go/template_virtual.go create mode 100644 Examples/test-suite/go/template_whitespace.go create mode 100644 Examples/test-suite/go/threads.go create mode 100644 Examples/test-suite/go/threads_exception.go create mode 100755 Examples/test-suite/go/threads_exception_runme create mode 100644 Examples/test-suite/go/throw_exception.go create mode 100644 Examples/test-suite/go/typedef_array_member.go create mode 100644 Examples/test-suite/go/typedef_class.go create mode 100755 Examples/test-suite/go/typedef_class_runme create mode 100644 Examples/test-suite/go/typedef_funcptr.go create mode 100644 Examples/test-suite/go/typedef_inherit.go create mode 100755 Examples/test-suite/go/typedef_inherit_runme create mode 100644 Examples/test-suite/go/typedef_mptr.go create mode 100644 Examples/test-suite/go/typedef_reference.go create mode 100644 Examples/test-suite/go/typedef_scope.go create mode 100755 Examples/test-suite/go/typedef_scope_runme create mode 100644 Examples/test-suite/go/typedef_sizet.go create mode 100644 Examples/test-suite/go/typedef_struct.go create mode 100644 Examples/test-suite/go/typedef_typedef.go create mode 100644 Examples/test-suite/go/typemap_array_qualifiers.go create mode 100644 Examples/test-suite/go/typemap_arrays.go create mode 100644 Examples/test-suite/go/typemap_delete.go create mode 100644 Examples/test-suite/go/typemap_directorout.go create mode 100644 Examples/test-suite/go/typemap_directorout_wrap.h create mode 100644 Examples/test-suite/go/typemap_global_scope.go create mode 100644 Examples/test-suite/go/typemap_manyargs.go create mode 100644 Examples/test-suite/go/typemap_namespace.go create mode 100755 Examples/test-suite/go/typemap_namespace_runme create mode 100644 Examples/test-suite/go/typemap_ns_using.go create mode 100755 Examples/test-suite/go/typemap_ns_using_runme create mode 100644 Examples/test-suite/go/typemap_numinputs.go create mode 100644 Examples/test-suite/go/typemap_out_optimal.go create mode 100755 Examples/test-suite/go/typemap_out_optimal_runme create mode 100644 Examples/test-suite/go/typemap_qualifier_strip.go create mode 100644 Examples/test-suite/go/typemap_subst.go create mode 100644 Examples/test-suite/go/typemap_template.go create mode 100644 Examples/test-suite/go/typemap_template_parm_typedef.go create mode 100644 Examples/test-suite/go/typemap_variables.go create mode 100644 Examples/test-suite/go/typemap_various.go create mode 100644 Examples/test-suite/go/typename.go create mode 100755 Examples/test-suite/go/typename_runme create mode 100644 Examples/test-suite/go/types_directive.go create mode 100644 Examples/test-suite/go/unicode_strings.go create mode 100644 Examples/test-suite/go/union_parameter.go create mode 100644 Examples/test-suite/go/union_scope.go create mode 100644 Examples/test-suite/go/unions.go create mode 100755 Examples/test-suite/go/unions_runme create mode 100644 Examples/test-suite/go/using1.go create mode 100755 Examples/test-suite/go/using1_runme create mode 100644 Examples/test-suite/go/using2.go create mode 100755 Examples/test-suite/go/using2_runme create mode 100644 Examples/test-suite/go/using_composition.go create mode 100755 Examples/test-suite/go/using_composition_runme create mode 100644 Examples/test-suite/go/using_directive_and_declaration.go create mode 100644 Examples/test-suite/go/using_directive_and_declaration_forward.go create mode 100644 Examples/test-suite/go/using_extend.go create mode 100755 Examples/test-suite/go/using_extend_runme create mode 100644 Examples/test-suite/go/using_inherit.go create mode 100755 Examples/test-suite/go/using_inherit_runme create mode 100644 Examples/test-suite/go/using_namespace.go create mode 100644 Examples/test-suite/go/using_namespace_loop.go create mode 100644 Examples/test-suite/go/using_pointers.go create mode 100644 Examples/test-suite/go/using_private.go create mode 100755 Examples/test-suite/go/using_private_runme create mode 100644 Examples/test-suite/go/using_protected.go create mode 100755 Examples/test-suite/go/using_protected_runme create mode 100644 Examples/test-suite/go/valuewrapper.go create mode 100644 Examples/test-suite/go/valuewrapper_base.go create mode 100644 Examples/test-suite/go/valuewrapper_const.go create mode 100644 Examples/test-suite/go/valuewrapper_opaque.go create mode 100644 Examples/test-suite/go/varargs.go create mode 100644 Examples/test-suite/go/varargs_overload.go create mode 100755 Examples/test-suite/go/varargs_overload_runme create mode 100755 Examples/test-suite/go/varargs_runme create mode 100644 Examples/test-suite/go/virtual_destructor.go create mode 100644 Examples/test-suite/go/virtual_poly.go create mode 100755 Examples/test-suite/go/virtual_poly_runme create mode 100644 Examples/test-suite/go/virtual_poly_wrap.h create mode 100644 Examples/test-suite/go/virtual_vs_nonvirtual_base.go create mode 100644 Examples/test-suite/go/voidtest.go create mode 100755 Examples/test-suite/go/voidtest_runme create mode 100644 Examples/test-suite/go/wallkw.go create mode 100644 Examples/test-suite/go/wrapmacro.go create mode 100755 Examples/test-suite/go/wrapmacro_runme create mode 100644 Examples/test-suite/overload_polymorphic.i create mode 100644 Examples/test-suite/overload_polymorphic.i~ create mode 100644 Examples/test-suite/overload_rename.i~ create mode 100644 Source/Modules/go.cxx~ diff --git a/Examples/test-suite/common.mk b/Examples/test-suite/common.mk index 485453b5a..232ba7eb2 100644 --- a/Examples/test-suite/common.mk +++ b/Examples/test-suite/common.mk @@ -308,6 +308,7 @@ CPP_TEST_CASES += \ overload_extend \ overload_method \ overload_numeric \ + overload_polymorphic \ overload_rename \ overload_return_type \ overload_simple \ diff --git a/Examples/test-suite/common.mk~ b/Examples/test-suite/common.mk~ new file mode 100644 index 000000000..485453b5a --- /dev/null +++ b/Examples/test-suite/common.mk~ @@ -0,0 +1,746 @@ +####################################################################### +# SWIG test suite makefile. +# The test suite comprises many different test cases, which have +# typically produced bugs in the past. The aim is to have the test +# cases compiling for every language modules. Some testcase have +# a runtime test which is written in each of the module's language. +# +# This makefile runs SWIG on the testcases, compiles the c/c++ code +# then builds the object code for use by the language. +# To complete a test in a language follow these guidelines: +# 1) Add testcases to CPP_TEST_CASES (c++) or C_TEST_CASES (c) or +# MULTI_CPP_TEST_CASES (multi-module c++ tests) +# 2) If not already done, create a makefile which: +# a) Defines LANGUAGE matching a language rule in Examples/Makefile, +# for example LANGUAGE = java +# b) Define rules for %.ctest, %.cpptest, %.multicpptest and %.clean. +# c) Define srcdir, top_srcdir and top_builddir (these are the +# equivalent to configure's variables of the same name). +# 3) One off special commandline options for a testcase can be added. +# See custom tests below. +# +# The 'check' target runs the testcases including SWIG invocation, +# C/C++ compilation, target language compilation (if any) and runtime +# test (if there is an associated 'runme' test). +# The 'partialcheck' target only invokes SWIG. +# The 'all' target is the same as the 'check' target but also includes +# known broken testcases. +# The 'clean' target cleans up. +# +# Note that the RUNTOOL, COMPILETOOL and SWIGTOOL variables can be used +# for invoking tools for the runtime tests and target language +# compiler (eg javac), and on SWIG respectively. For example, valgrind +# can be used for memory checking of the runtime tests using: +# make RUNTOOL="valgrind --leak-check=full" +# and valgrind can be used when invoking SWIG using: +# make SWIGTOOL="valgrind --tool=memcheck --trace-children=yes" +# Note: trace-children needed because of preinst-swig shell wrapper +# to the swig executable. +# +# An individual test run can be debugged easily: +# make director_string.cpptest RUNTOOL="gdb --args" +# +# The variables below can be overridden after including this makefile +####################################################################### + +####################################################################### +# Variables +####################################################################### + +ifneq (,$(USE_VALGRIND)) +VALGRIND_OPT = --leak-check=full +RUNTOOL = valgrind $(VALGRIND_OPT) +else +RUNTOOL = +endif +COMPILETOOL= +SWIGTOOL = + +SWIG = $(SWIGTOOL) $(top_builddir)/preinst-swig +SWIG_LIB = $(top_srcdir)/Lib +TEST_SUITE = test-suite +EXAMPLES = Examples +CXXSRCS = +CSRCS = +TARGETPREFIX = +TARGETSUFFIX = +SWIGOPT = -outcurrentdir -I$(top_srcdir)/$(EXAMPLES)/$(TEST_SUITE) +INCLUDES = -I$(top_srcdir)/$(EXAMPLES)/$(TEST_SUITE) +LIBS = -L. +LIBPREFIX = lib +ACTION = check +INTERFACEDIR = ../ +SRCDIR = $(srcdir)/ +SCRIPTDIR = $(srcdir) + +# Regenerate Makefile if Makefile.in or config.status have changed. +Makefile: $(srcdir)/Makefile.in ../../../config.status + cd ../../../ && $(SHELL) ./config.status $(EXAMPLES)/$(TEST_SUITE)/$(LANGUAGE)/Makefile + +# +# Please keep test cases in alphabetical order. +# Note that any whitespace after the last entry in each list will break make +# + +# Broken C++ test cases. (Can be run individually using: make testcase.cpptest) +CPP_TEST_BROKEN += \ + constants \ + cpp_broken \ + exception_partial_info \ + extend_variable \ + li_std_vector_ptr \ + li_boost_shared_ptr_template \ + nested_private \ + overload_complicated \ + rename_camel \ + template_default_pointer \ + template_private_assignment \ + template_expr \ + $(CPP11_TEST_BROKEN) + + +# Broken C test cases. (Can be run individually using: make testcase.ctest) +C_TEST_BROKEN += \ + tag_no_clash_with_variable + +# C++ test cases. (Can be run individually using: make testcase.cpptest) +CPP_TEST_CASES += \ + abstract_access \ + abstract_inherit \ + abstract_inherit_ok \ + abstract_signature \ + abstract_typedef \ + abstract_typedef2 \ + abstract_virtual \ + access_change \ + add_link \ + aggregate \ + allowexcept \ + allprotected \ + allprotected_not \ + anonymous_bitfield \ + apply_signed_char \ + apply_strings \ + argout \ + array_member \ + array_typedef_memberin \ + arrayref \ + arrays_dimensionless \ + arrays_global \ + arrays_global_twodim \ + arrays_scope \ + autodoc \ + bloody_hell \ + bools \ + catches \ + cast_operator \ + casts \ + char_binary \ + char_strings \ + class_forward \ + class_ignore \ + class_scope_weird \ + compactdefaultargs \ + const_const_2 \ + constant_pointers \ + constover \ + constructor_copy \ + constructor_exception \ + constructor_explicit \ + constructor_ignore \ + constructor_rename \ + constructor_value \ + contract \ + conversion \ + conversion_namespace \ + conversion_ns_template \ + cplusplus_throw \ + cpp_basic \ + cpp_enum \ + cpp_namespace \ + cpp_nodefault \ + cpp_static \ + cpp_typedef \ + curiously_recurring_template_pattern \ + default_args \ + default_arg_values \ + default_constructor \ + defvalue_constructor \ + derived_byvalue \ + derived_nested \ + destructor_reprotected \ + director_abstract \ + director_alternating \ + director_basic \ + director_binary_string \ + director_classes \ + director_classic \ + director_constructor \ + director_default \ + director_detect \ + director_enum \ + director_exception \ + director_extend \ + director_finalizer \ + director_frob \ + director_ignore \ + director_keywords \ + director_namespace_clash \ + director_nspace \ + director_nspace_director_name_collision \ + director_nested \ + director_overload \ + director_overload2 \ + director_primitives \ + director_protected \ + director_protected_overloaded \ + director_redefined \ + director_smartptr \ + director_thread \ + director_unroll \ + director_using \ + director_wombat \ + disown \ + dynamic_cast \ + empty \ + enum_ignore \ + enum_plus \ + enum_rename \ + enum_scope_template \ + enum_template \ + enum_thorough \ + enum_var \ + equality \ + evil_diamond \ + evil_diamond_ns \ + evil_diamond_prop \ + exception_order \ + extend \ + extend_constructor_destructor \ + extend_default \ + extend_placement \ + extend_special_variables \ + extend_template \ + extend_template_ns \ + extend_typedef_class \ + extern_c \ + extern_namespace \ + extern_throws \ + expressions \ + features \ + fragments \ + friends \ + funcptr_cpp \ + fvirtual \ + global_namespace \ + global_ns_arg \ + global_scope_types \ + global_vars \ + grouping \ + ignore_parameter \ + import_nomodule \ + inherit \ + inherit_missing \ + inherit_same_name \ + inherit_target_language \ + inherit_void_arg \ + inline_initializer \ + insert_directive \ + keyword_rename \ + kind \ + langobj \ + li_attribute \ + li_attribute_template \ + li_boost_shared_ptr \ + li_boost_shared_ptr_bits \ + li_boost_shared_ptr_template \ + li_boost_shared_ptr_attribute \ + li_carrays \ + li_cdata \ + li_cpointer \ + li_std_auto_ptr \ + li_stdint \ + li_swigtype_inout \ + li_typemaps \ + li_typemaps_apply \ + li_windows \ + long_long_apply \ + memberin_extend \ + member_funcptr_galore \ + member_pointer \ + member_template \ + minherit \ + minherit2 \ + mixed_types \ + multiple_inheritance \ + name_cxx \ + name_warnings \ + namespace_class \ + namespace_enum \ + namespace_extend \ + namespace_forward_declaration \ + namespace_nested \ + namespace_spaces \ + namespace_template \ + namespace_typedef_class \ + namespace_typemap \ + namespace_union \ + namespace_virtual_method \ + nspace \ + nspace_extend \ + naturalvar \ + naturalvar_more \ + naturalvar_onoff \ + nested_class \ + nested_directors \ + nested_comment \ + nested_scope \ + nested_workaround \ + newobject1 \ + null_pointer \ + operator_overload \ + operator_overload_break \ + operator_pointer_ref \ + operbool \ + ordering \ + overload_bool \ + overload_copy \ + overload_extend \ + overload_method \ + overload_numeric \ + overload_rename \ + overload_return_type \ + overload_simple \ + overload_subtype \ + overload_template \ + overload_template_fast \ + pointer_reference \ + preproc_constants \ + primitive_ref \ + private_assign \ + protected_rename \ + pure_virtual \ + redefined \ + redefined_not \ + refcount \ + reference_global_vars \ + register_par \ + rename1 \ + rename2 \ + rename3 \ + rename4 \ + rename_scope \ + rename_simple \ + rename_strip_encoder \ + rename_pcre_encoder \ + rename_pcre_enum \ + rename_predicates \ + restrict_cplusplus \ + return_const_value \ + return_value_scope \ + rname \ + samename \ + sizet \ + smart_pointer_const \ + smart_pointer_const2 \ + smart_pointer_const_overload \ + smart_pointer_extend \ + smart_pointer_member \ + smart_pointer_multi \ + smart_pointer_multi_typedef \ + smart_pointer_namespace \ + smart_pointer_namespace2 \ + smart_pointer_not \ + smart_pointer_overload \ + smart_pointer_protected \ + smart_pointer_rename \ + smart_pointer_simple \ + smart_pointer_static \ + smart_pointer_template_const_overload \ + smart_pointer_template_defaults_overload \ + smart_pointer_templatemethods \ + smart_pointer_templatevariables \ + smart_pointer_typedef \ + special_variables \ + special_variable_macros \ + static_array_member \ + static_const_member \ + static_const_member_2 \ + struct_initialization_cpp \ + struct_value \ + symbol_clash \ + template_arg_replace \ + template_arg_scope \ + template_arg_typename \ + template_array_numeric \ + template_basic \ + template_base_template \ + template_classes \ + template_const_ref \ + template_construct \ + template_default \ + template_default2 \ + template_default_arg \ + template_default_arg_virtual_destructor \ + template_default_class_parms \ + template_default_class_parms_typedef \ + template_default_inherit \ + template_default_qualify \ + template_default_vw \ + template_enum \ + template_enum_ns_inherit \ + template_enum_typedef \ + template_explicit \ + template_extend1 \ + template_extend2 \ + template_extend_overload \ + template_extend_overload_2 \ + template_forward \ + template_inherit \ + template_inherit_abstract \ + template_int_const \ + template_methods \ + template_namespace_forward_declaration \ + template_using_directive_and_declaration_forward \ + template_nested \ + template_nested_typemaps \ + template_ns \ + template_ns2 \ + template_ns3 \ + template_ns4 \ + template_ns_enum \ + template_ns_enum2 \ + template_ns_inherit \ + template_ns_scope \ + template_partial_arg \ + template_partial_specialization \ + template_partial_specialization_typedef \ + template_qualifier \ + template_ref_type \ + template_rename \ + template_retvalue \ + template_specialization \ + template_specialization_defarg \ + template_specialization_enum \ + template_static \ + template_tbase_template \ + template_template_parameters \ + template_typedef \ + template_typedef_class_template \ + template_typedef_cplx \ + template_typedef_cplx2 \ + template_typedef_cplx3 \ + template_typedef_cplx4 \ + template_typedef_cplx5 \ + template_typedef_funcptr \ + template_typedef_inherit \ + template_typedef_ns \ + template_typedef_ptr \ + template_typedef_rec \ + template_typedef_typedef \ + template_typemaps \ + template_typemaps_typedef \ + template_typemaps_typedef2 \ + template_using \ + template_virtual \ + template_whitespace \ + threads \ + threads_exception \ + throw_exception \ + typedef_array_member \ + typedef_class \ + typedef_funcptr \ + typedef_inherit \ + typedef_mptr \ + typedef_reference \ + typedef_scope \ + typedef_sizet \ + typedef_struct \ + typedef_typedef \ + typemap_arrays \ + typemap_array_qualifiers \ + typemap_delete \ + typemap_directorout \ + typemap_global_scope \ + typemap_manyargs \ + typemap_namespace \ + typemap_ns_using \ + typemap_numinputs \ + typemap_template \ + typemap_template_parm_typedef \ + typemap_out_optimal \ + typemap_qualifier_strip \ + typemap_variables \ + typemap_various \ + typename \ + types_directive \ + unicode_strings \ + union_scope \ + using1 \ + using2 \ + using_composition \ + using_directive_and_declaration \ + using_directive_and_declaration_forward \ + using_extend \ + using_inherit \ + using_namespace \ + using_namespace_loop \ + using_pointers \ + using_private \ + using_protected \ + valuewrapper \ + valuewrapper_base \ + valuewrapper_const \ + valuewrapper_opaque \ + varargs \ + varargs_overload \ + virtual_destructor \ + virtual_poly \ + virtual_vs_nonvirtual_base \ + voidtest \ + wallkw \ + wrapmacro + +# C++11 test cases. +CPP11_TEST_CASES = \ + cpp11_alignment \ + cpp11_alternate_function_syntax \ + cpp11_constexpr \ + cpp11_decltype \ + cpp11_default_delete \ + cpp11_delegating_constructors \ + cpp11_explicit_conversion_operators \ + cpp11_final_override \ + cpp11_function_objects \ + cpp11_inheriting_constructors \ + cpp11_initializer_list \ + cpp11_initializer_list_extend \ + cpp11_lambda_functions \ + cpp11_noexcept \ + cpp11_null_pointer_constant \ + cpp11_raw_string_literals \ + cpp11_result_of \ + cpp11_rvalue_reference \ + cpp11_rvalue_reference2 \ + cpp11_rvalue_reference3 \ + cpp11_sizeof_object \ + cpp11_static_assert \ + cpp11_thread_local \ + cpp11_template_double_brackets \ + cpp11_template_explicit \ + cpp11_template_typedefs \ + cpp11_type_traits \ + cpp11_uniform_initialization \ + cpp11_unrestricted_unions \ + cpp11_userdefined_literals \ + +# Broken C++11 test cases. +CPP11_TEST_BROKEN = \ +# cpp11_hash_tables \ # not fully implemented yet +# cpp11_strongly_typed_enumerations \ # SWIG not quite getting this right yet in all langs +# cpp11_variadic_templates \ # Broken for some languages (such as Java) +# cpp11_reference_wrapper \ # No typemaps + + +# +# Put all the heavy STD/STL cases here, where they can be skipped if needed +# +CPP_STD_TEST_CASES += \ + director_string \ + ignore_template_constructor \ + li_std_combinations \ + li_std_deque \ + li_std_except \ + li_std_except_as_class \ + li_std_map \ + li_std_pair \ + li_std_pair_using \ + li_std_string \ + li_std_vector \ + li_std_vector_enum \ + li_std_vector_member_var\ + naturalvar \ + smart_pointer_inherit \ + template_typedef_fnc \ + template_type_namespace \ + template_opaque +# li_std_list + + +ifndef SKIP_CPP_STD_CASES +CPP_TEST_CASES += ${CPP_STD_TEST_CASES} +endif + +ifneq (,$(HAVE_CXX11_COMPILER)) +CPP_TEST_CASES += $(CPP11_TEST_CASES) +endif + +# C test cases. (Can be run individually using: make testcase.ctest) +C_TEST_CASES += \ + arrays \ + bom_utf8 \ + c_delete \ + c_delete_function \ + char_constant \ + const_const \ + constant_expr \ + empty \ + enums \ + enum_forward \ + enum_macro \ + enum_missing \ + extern_declaration \ + funcptr \ + function_typedef \ + global_functions \ + immutable_values \ + inctest \ + infinity \ + integers \ + keyword_rename \ + lextype \ + li_carrays \ + li_cdata \ + li_cmalloc \ + li_constraints \ + li_cpointer \ + li_math \ + long_long \ + memberin_extend_c \ + name \ + nested \ + nested_extend_c \ + nested_structs \ + newobject2 \ + overload_extend \ + overload_extendc \ + preproc \ + preproc_constants_c \ + preproc_defined \ + preproc_include \ + preproc_line_file \ + ret_by_value \ + simple_array \ + sizeof_pointer \ + sneaky1 \ + string_simple \ + struct_rename \ + struct_initialization \ + typedef_struct \ + typemap_subst \ + union_parameter \ + unions + + +# Multi-module C++ test cases . (Can be run individually using make testcase.multicpptest) +MULTI_CPP_TEST_CASES += \ + clientdata_prop \ + imports \ + import_stl \ + packageoption \ + mod \ + template_typedef_import \ + multi_import + +# Custom tests - tests with additional commandline options +wallkw.cpptest: SWIGOPT += -Wallkw +preproc_include.ctest: SWIGOPT += -includeall + + +NOT_BROKEN_TEST_CASES = $(CPP_TEST_CASES:=.cpptest) \ + $(C_TEST_CASES:=.ctest) \ + $(MULTI_CPP_TEST_CASES:=.multicpptest) \ + $(EXTRA_TEST_CASES) + +BROKEN_TEST_CASES = $(CPP_TEST_BROKEN:=.cpptest) \ + $(C_TEST_BROKEN:=.ctest) + +ALL_CLEAN = $(CPP_TEST_CASES:=.clean) \ + $(C_TEST_CASES:=.clean) \ + $(MULTI_CPP_TEST_CASES:=.clean) \ + $(CPP_TEST_BROKEN:=.clean) \ + $(C_TEST_BROKEN:=.clean) + +####################################################################### +# Error test suite has its own set of test cases +####################################################################### +ifneq (,$(ERROR_TEST_CASES)) +check: $(ERROR_TEST_CASES) +else + +####################################################################### +# The following applies for all module languages +####################################################################### +all: $(NOT_BROKEN_TEST_CASES) $(BROKEN_TEST_CASES) + +broken: $(BROKEN_TEST_CASES) + +check: $(NOT_BROKEN_TEST_CASES) + +check-c: $(C_TEST_CASES:=.ctest) + +check-cpp: $(CPP_TEST_CASES:=.cpptest) + +check-cpp11: $(CPP11_TEST_CASES:=.cpptest) + +endif + +# partialcheck target runs SWIG only, ie no compilation or running of tests (for a subset of languages) +partialcheck: + $(MAKE) check CC=true CXX=true LDSHARED=true CXXSHARED=true RUNTOOL=true COMPILETOOL=true + +swig_and_compile_cpp = \ + $(MAKE) -f $(top_builddir)/$(EXAMPLES)/Makefile SRCDIR="$(SRCDIR)" CXXSRCS="$(CXXSRCS)" \ + SWIG_LIB="$(SWIG_LIB)" SWIG="$(SWIG)" \ + INCLUDES="$(INCLUDES)" SWIGOPT="$(SWIGOPT)" NOLINK=true \ + TARGET="$(TARGETPREFIX)$*$(TARGETSUFFIX)" INTERFACEDIR="$(INTERFACEDIR)" INTERFACE="$*.i" \ + $(LANGUAGE)$(VARIANT)_cpp + +swig_and_compile_c = \ + $(MAKE) -f $(top_builddir)/$(EXAMPLES)/Makefile SRCDIR="$(SRCDIR)" CSRCS="$(CSRCS)" \ + SWIG_LIB="$(SWIG_LIB)" SWIG="$(SWIG)" \ + INCLUDES="$(INCLUDES)" SWIGOPT="$(SWIGOPT)" NOLINK=true \ + TARGET="$(TARGETPREFIX)$*$(TARGETSUFFIX)" INTERFACEDIR="$(INTERFACEDIR)" INTERFACE="$*.i" \ + $(LANGUAGE)$(VARIANT) + +swig_and_compile_multi_cpp = \ + for f in `cat $(top_srcdir)/$(EXAMPLES)/$(TEST_SUITE)/$*.list` ; do \ + $(MAKE) -f $(top_builddir)/$(EXAMPLES)/Makefile SRCDIR="$(SRCDIR)" CXXSRCS="$(CXXSRCS)" \ + SWIG_LIB="$(SWIG_LIB)" SWIG="$(SWIG)" LIBS='$(LIBS)' \ + INCLUDES="$(INCLUDES)" SWIGOPT="$(SWIGOPT)" NOLINK=true \ + TARGET="$(TARGETPREFIX)$${f}$(TARGETSUFFIX)" INTERFACEDIR="$(INTERFACEDIR)" INTERFACE="$$f.i" \ + $(LANGUAGE)$(VARIANT)_cpp; \ + done + +swig_and_compile_external = \ + $(MAKE) -f $(top_builddir)/$(EXAMPLES)/Makefile SRCDIR="$(SRCDIR)" \ + SWIG_LIB="$(SWIG_LIB)" SWIG="$(SWIG)" \ + TARGET="$*_wrap_hdr.h" \ + $(LANGUAGE)$(VARIANT)_externalhdr; \ + $(MAKE) -f $(top_builddir)/$(EXAMPLES)/Makefile SRCDIR="$(SRCDIR)" CXXSRCS="$(CXXSRCS) $*_external.cxx" \ + SWIG_LIB="$(SWIG_LIB)" SWIG="$(SWIG)" \ + INCLUDES="$(INCLUDES)" SWIGOPT="$(SWIGOPT)" NOLINK=true \ + TARGET="$(TARGETPREFIX)$*$(TARGETSUFFIX)" INTERFACEDIR="$(INTERFACEDIR)" INTERFACE="$*.i" \ + $(LANGUAGE)$(VARIANT)_cpp + +swig_and_compile_runtime = \ + +setup = \ + if [ -f $(SCRIPTDIR)/$(SCRIPTPREFIX)$*$(SCRIPTSUFFIX) ]; then \ + echo "$(ACTION)ing $(LANGUAGE) testcase $* (with run test)" ; \ + else \ + echo "$(ACTION)ing $(LANGUAGE) testcase $*" ; \ + fi; + + + +####################################################################### +# Clean +####################################################################### +clean: $(ALL_CLEAN) + +distclean: clean + @rm -f Makefile + +.PHONY: all check partialcheck broken clean distclean + diff --git a/Examples/test-suite/go/abstract_access.go b/Examples/test-suite/go/abstract_access.go new file mode 100644 index 000000000..c2bc76f18 --- /dev/null +++ b/Examples/test-suite/go/abstract_access.go @@ -0,0 +1,311 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../abstract_access.i + +package abstract_access + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrA uintptr + +func (p SwigcptrA) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrA) SwigIsA() { +} + +var _wrap_delete_A unsafe.Pointer + +func _swig_wrap_delete_A(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_A, _swig_p) + return +} + +func DeleteA(arg1 A) { + _swig_wrap_delete_A(arg1.Swigcptr()) +} + +var _wrap_A_z unsafe.Pointer + +func _swig_wrap_A_z(base SwigcptrA) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_A_z, _swig_p) + return +} + +func (arg1 SwigcptrA) Z() (_swig_ret int) { + return _swig_wrap_A_z(arg1) +} + +var _wrap_A_do_x unsafe.Pointer + +func _swig_wrap_A_do_x(base SwigcptrA) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_A_do_x, _swig_p) + return +} + +func (arg1 SwigcptrA) Do_x() (_swig_ret int) { + return _swig_wrap_A_do_x(arg1) +} + +type A interface { + Swigcptr() uintptr + SwigIsA() + Z() (_swig_ret int) + Do_x() (_swig_ret int) +} + +type SwigcptrB uintptr + +func (p SwigcptrB) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrB) SwigIsB() { +} + +var _wrap_delete_B unsafe.Pointer + +func _swig_wrap_delete_B(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_B, _swig_p) + return +} + +func DeleteB(arg1 B) { + _swig_wrap_delete_B(arg1.Swigcptr()) +} + +var _wrap_B_z unsafe.Pointer + +func _swig_wrap_B_z(base SwigcptrB) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_B_z, _swig_p) + return +} + +func (_swig_base SwigcptrB) Z() (_swig_ret int) { + return _swig_wrap_B_z(_swig_base) +} + +var _wrap_B_do_x unsafe.Pointer + +func _swig_wrap_B_do_x(base SwigcptrB) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_B_do_x, _swig_p) + return +} + +func (_swig_base SwigcptrB) Do_x() (_swig_ret int) { + return _swig_wrap_B_do_x(_swig_base) +} + +func (p SwigcptrB) SwigIsA() { +} + +func (p SwigcptrB) SwigGetA() A { + return SwigcptrA(p.Swigcptr()) +} + +type B interface { + Swigcptr() uintptr + SwigIsB() + Z() (_swig_ret int) + Do_x() (_swig_ret int) + SwigIsA() + SwigGetA() A +} + +type SwigcptrC uintptr + +func (p SwigcptrC) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrC) SwigIsC() { +} + +var _wrap_delete_C unsafe.Pointer + +func _swig_wrap_delete_C(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_C, _swig_p) + return +} + +func DeleteC(arg1 C) { + _swig_wrap_delete_C(arg1.Swigcptr()) +} + +var _wrap_C_z unsafe.Pointer + +func _swig_wrap_C_z(base SwigcptrC) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_C_z, _swig_p) + return +} + +func (_swig_base SwigcptrC) Z() (_swig_ret int) { + return _swig_wrap_C_z(_swig_base) +} + +var _wrap_C_do_x unsafe.Pointer + +func _swig_wrap_C_do_x(base SwigcptrC) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_C_do_x, _swig_p) + return +} + +func (_swig_base SwigcptrC) Do_x() (_swig_ret int) { + return _swig_wrap_C_do_x(_swig_base) +} + +func (p SwigcptrC) SwigIsB() { +} + +func (p SwigcptrC) SwigGetB() B { + return SwigcptrB(p.Swigcptr()) +} + +func (p SwigcptrC) SwigIsA() { +} + +func (p SwigcptrC) SwigGetA() A { + return SwigcptrA(p.Swigcptr()) +} + +type C interface { + Swigcptr() uintptr + SwigIsC() + Z() (_swig_ret int) + Do_x() (_swig_ret int) + SwigIsB() + SwigGetB() B + SwigIsA() + SwigGetA() A +} + +type SwigcptrD uintptr + +func (p SwigcptrD) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrD) SwigIsD() { +} + +var _wrap_new_D unsafe.Pointer + +func _swig_wrap_new_D() (base SwigcptrD) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_D, _swig_p) + return +} + +func NewD() (_swig_ret D) { + return _swig_wrap_new_D() +} + +var _wrap_delete_D unsafe.Pointer + +func _swig_wrap_delete_D(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_D, _swig_p) + return +} + +func DeleteD(arg1 D) { + _swig_wrap_delete_D(arg1.Swigcptr()) +} + +var _wrap_D_z unsafe.Pointer + +func _swig_wrap_D_z(base SwigcptrD) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_D_z, _swig_p) + return +} + +func (_swig_base SwigcptrD) Z() (_swig_ret int) { + return _swig_wrap_D_z(_swig_base) +} + +var _wrap_D_do_x unsafe.Pointer + +func _swig_wrap_D_do_x(base SwigcptrD) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_D_do_x, _swig_p) + return +} + +func (_swig_base SwigcptrD) Do_x() (_swig_ret int) { + return _swig_wrap_D_do_x(_swig_base) +} + +func (p SwigcptrD) SwigIsC() { +} + +func (p SwigcptrD) SwigGetC() C { + return SwigcptrC(p.Swigcptr()) +} + +func (p SwigcptrD) SwigIsB() { +} + +func (p SwigcptrD) SwigGetB() B { + return SwigcptrB(p.Swigcptr()) +} + +func (p SwigcptrD) SwigIsA() { +} + +func (p SwigcptrD) SwigGetA() A { + return SwigcptrA(p.Swigcptr()) +} + +type D interface { + Swigcptr() uintptr + SwigIsD() + Z() (_swig_ret int) + Do_x() (_swig_ret int) + SwigIsC() + SwigGetC() C + SwigIsB() + SwigGetB() B + SwigIsA() + SwigGetA() A +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/abstract_access_runme b/Examples/test-suite/go/abstract_access_runme new file mode 100755 index 000000000..50e545dac Binary files /dev/null and b/Examples/test-suite/go/abstract_access_runme differ diff --git a/Examples/test-suite/go/abstract_inherit.go b/Examples/test-suite/go/abstract_inherit.go new file mode 100644 index 000000000..a33f3826f --- /dev/null +++ b/Examples/test-suite/go/abstract_inherit.go @@ -0,0 +1,285 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../abstract_inherit.i + +package abstract_inherit + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrFoo uintptr + +func (p SwigcptrFoo) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrFoo) SwigIsFoo() { +} + +var _wrap_delete_Foo unsafe.Pointer + +func _swig_wrap_delete_Foo(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Foo, _swig_p) + return +} + +func DeleteFoo(arg1 Foo) { + _swig_wrap_delete_Foo(arg1.Swigcptr()) +} + +var _wrap_Foo_blah unsafe.Pointer + +func _swig_wrap_Foo_blah(base SwigcptrFoo) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_blah, _swig_p) + return +} + +func (arg1 SwigcptrFoo) Blah() (_swig_ret int) { + return _swig_wrap_Foo_blah(arg1) +} + +type Foo interface { + Swigcptr() uintptr + SwigIsFoo() + Blah() (_swig_ret int) +} + +type SwigcptrBar uintptr + +func (p SwigcptrBar) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrBar) SwigIsBar() { +} + +var _wrap_delete_Bar unsafe.Pointer + +func _swig_wrap_delete_Bar(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Bar, _swig_p) + return +} + +func DeleteBar(arg1 Bar) { + _swig_wrap_delete_Bar(arg1.Swigcptr()) +} + +var _wrap_Bar_blah unsafe.Pointer + +func _swig_wrap_Bar_blah(base SwigcptrBar) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Bar_blah, _swig_p) + return +} + +func (_swig_base SwigcptrBar) Blah() (_swig_ret int) { + return _swig_wrap_Bar_blah(_swig_base) +} + +func (p SwigcptrBar) SwigIsFoo() { +} + +func (p SwigcptrBar) SwigGetFoo() Foo { + return SwigcptrFoo(p.Swigcptr()) +} + +type Bar interface { + Swigcptr() uintptr + SwigIsBar() + Blah() (_swig_ret int) + SwigIsFoo() + SwigGetFoo() Foo +} + +type SwigcptrSpam uintptr + +func (p SwigcptrSpam) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrSpam) SwigIsSpam() { +} + +var _wrap_delete_Spam unsafe.Pointer + +func _swig_wrap_delete_Spam(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Spam, _swig_p) + return +} + +func DeleteSpam(arg1 Spam) { + _swig_wrap_delete_Spam(arg1.Swigcptr()) +} + +var _wrap_Spam_blah unsafe.Pointer + +func _swig_wrap_Spam_blah(base SwigcptrSpam) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Spam_blah, _swig_p) + return +} + +func (_swig_base SwigcptrSpam) Blah() (_swig_ret int) { + return _swig_wrap_Spam_blah(_swig_base) +} + +func (p SwigcptrSpam) SwigIsFoo() { +} + +func (p SwigcptrSpam) SwigGetFoo() Foo { + return SwigcptrFoo(p.Swigcptr()) +} + +type Spam interface { + Swigcptr() uintptr + SwigIsSpam() + Blah() (_swig_ret int) + SwigIsFoo() + SwigGetFoo() Foo +} + +type SwigcptrNRFilter_i uintptr + +func (p SwigcptrNRFilter_i) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrNRFilter_i) SwigIsNRFilter_i() { +} + +var _wrap_delete_NRFilter_i unsafe.Pointer + +func _swig_wrap_delete_NRFilter_i(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_NRFilter_i, _swig_p) + return +} + +func DeleteNRFilter_i(arg1 NRFilter_i) { + _swig_wrap_delete_NRFilter_i(arg1.Swigcptr()) +} + +type NRFilter_i interface { + Swigcptr() uintptr + SwigIsNRFilter_i() +} + +type SwigcptrNRRCFilter_i uintptr + +func (p SwigcptrNRRCFilter_i) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrNRRCFilter_i) SwigIsNRRCFilter_i() { +} + +var _wrap_delete_NRRCFilter_i unsafe.Pointer + +func _swig_wrap_delete_NRRCFilter_i(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_NRRCFilter_i, _swig_p) + return +} + +func DeleteNRRCFilter_i(arg1 NRRCFilter_i) { + _swig_wrap_delete_NRRCFilter_i(arg1.Swigcptr()) +} + +func (p SwigcptrNRRCFilter_i) SwigIsNRFilter_i() { +} + +func (p SwigcptrNRRCFilter_i) SwigGetNRFilter_i() NRFilter_i { + return SwigcptrNRFilter_i(p.Swigcptr()) +} + +type NRRCFilter_i interface { + Swigcptr() uintptr + SwigIsNRRCFilter_i() + SwigIsNRFilter_i() + SwigGetNRFilter_i() NRFilter_i +} + +type SwigcptrNRRCFilterpro_i uintptr + +func (p SwigcptrNRRCFilterpro_i) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrNRRCFilterpro_i) SwigIsNRRCFilterpro_i() { +} + +var _wrap_delete_NRRCFilterpro_i unsafe.Pointer + +func _swig_wrap_delete_NRRCFilterpro_i(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_NRRCFilterpro_i, _swig_p) + return +} + +func DeleteNRRCFilterpro_i(arg1 NRRCFilterpro_i) { + _swig_wrap_delete_NRRCFilterpro_i(arg1.Swigcptr()) +} + +type NRRCFilterpro_i interface { + Swigcptr() uintptr + SwigIsNRRCFilterpro_i() +} + +type SwigcptrNRRCFilterpri_i uintptr + +func (p SwigcptrNRRCFilterpri_i) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrNRRCFilterpri_i) SwigIsNRRCFilterpri_i() { +} + +var _wrap_delete_NRRCFilterpri_i unsafe.Pointer + +func _swig_wrap_delete_NRRCFilterpri_i(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_NRRCFilterpri_i, _swig_p) + return +} + +func DeleteNRRCFilterpri_i(arg1 NRRCFilterpri_i) { + _swig_wrap_delete_NRRCFilterpri_i(arg1.Swigcptr()) +} + +type NRRCFilterpri_i interface { + Swigcptr() uintptr + SwigIsNRRCFilterpri_i() +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/abstract_inherit_ok.go b/Examples/test-suite/go/abstract_inherit_ok.go new file mode 100644 index 000000000..ba6812af7 --- /dev/null +++ b/Examples/test-suite/go/abstract_inherit_ok.go @@ -0,0 +1,136 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../abstract_inherit_ok.i + +package abstract_inherit_ok + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrFoo uintptr + +func (p SwigcptrFoo) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrFoo) SwigIsFoo() { +} + +var _wrap_delete_Foo unsafe.Pointer + +func _swig_wrap_delete_Foo(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Foo, _swig_p) + return +} + +func DeleteFoo(arg1 Foo) { + _swig_wrap_delete_Foo(arg1.Swigcptr()) +} + +var _wrap_Foo_blah unsafe.Pointer + +func _swig_wrap_Foo_blah(base SwigcptrFoo) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_blah, _swig_p) + return +} + +func (arg1 SwigcptrFoo) Blah() (_swig_ret int) { + return _swig_wrap_Foo_blah(arg1) +} + +type Foo interface { + Swigcptr() uintptr + SwigIsFoo() + Blah() (_swig_ret int) +} + +type SwigcptrSpam uintptr + +func (p SwigcptrSpam) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrSpam) SwigIsSpam() { +} + +var _wrap_new_Spam unsafe.Pointer + +func _swig_wrap_new_Spam() (base SwigcptrSpam) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Spam, _swig_p) + return +} + +func NewSpam() (_swig_ret Spam) { + return _swig_wrap_new_Spam() +} + +var _wrap_delete_Spam unsafe.Pointer + +func _swig_wrap_delete_Spam(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Spam, _swig_p) + return +} + +func DeleteSpam(arg1 Spam) { + _swig_wrap_delete_Spam(arg1.Swigcptr()) +} + +var _wrap_Spam_blah unsafe.Pointer + +func _swig_wrap_Spam_blah(base SwigcptrSpam) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Spam_blah, _swig_p) + return +} + +func (_swig_base SwigcptrSpam) Blah() (_swig_ret int) { + return _swig_wrap_Spam_blah(_swig_base) +} + +func (p SwigcptrSpam) SwigIsFoo() { +} + +func (p SwigcptrSpam) SwigGetFoo() Foo { + return SwigcptrFoo(p.Swigcptr()) +} + +type Spam interface { + Swigcptr() uintptr + SwigIsSpam() + Blah() (_swig_ret int) + SwigIsFoo() + SwigGetFoo() Foo +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/abstract_signature.go b/Examples/test-suite/go/abstract_signature.go new file mode 100644 index 000000000..d2917d233 --- /dev/null +++ b/Examples/test-suite/go/abstract_signature.go @@ -0,0 +1,147 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../abstract_signature.i + +package abstract_signature + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrAbstract_foo uintptr + +func (p SwigcptrAbstract_foo) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrAbstract_foo) SwigIsAbstract_foo() { +} + +var _wrap_delete_abstract_foo unsafe.Pointer + +func _swig_wrap_delete_abstract_foo(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_abstract_foo, _swig_p) + return +} + +func DeleteAbstract_foo(arg1 Abstract_foo) { + _swig_wrap_delete_abstract_foo(arg1.Swigcptr()) +} + +var _wrap_abstract_foo_meth unsafe.Pointer + +func _swig_wrap_abstract_foo_meth(base SwigcptrAbstract_foo, _ int) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_abstract_foo_meth, _swig_p) + return +} + +func (arg1 SwigcptrAbstract_foo) Meth(arg2 int) (_swig_ret int) { + return _swig_wrap_abstract_foo_meth(arg1, arg2) +} + +type Abstract_foo interface { + Swigcptr() uintptr + SwigIsAbstract_foo() + Meth(arg2 int) (_swig_ret int) +} + +type SwigcptrAbstract_bar uintptr + +func (p SwigcptrAbstract_bar) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrAbstract_bar) SwigIsAbstract_bar() { +} + +var _wrap_delete_abstract_bar unsafe.Pointer + +func _swig_wrap_delete_abstract_bar(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_abstract_bar, _swig_p) + return +} + +func DeleteAbstract_bar(arg1 Abstract_bar) { + _swig_wrap_delete_abstract_bar(arg1.Swigcptr()) +} + +var _wrap_abstract_bar_meth__SWIG_0 unsafe.Pointer + +func _swig_wrap_abstract_bar_meth__SWIG_0(base SwigcptrAbstract_bar, _ int) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_abstract_bar_meth__SWIG_0, _swig_p) + return +} + +func (arg1 SwigcptrAbstract_bar) Meth__SWIG_0(arg2 int) (_swig_ret int) { + return _swig_wrap_abstract_bar_meth__SWIG_0(arg1, arg2) +} + +var _wrap_abstract_bar_meth__SWIG_1 unsafe.Pointer + +func _swig_wrap_abstract_bar_meth__SWIG_1(base SwigcptrAbstract_bar, _ int, _ int) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_abstract_bar_meth__SWIG_1, _swig_p) + return +} + +func (arg1 SwigcptrAbstract_bar) Meth__SWIG_1(arg2 int, arg3 int) (_swig_ret int) { + return _swig_wrap_abstract_bar_meth__SWIG_1(arg1, arg2, arg3) +} + +func (p SwigcptrAbstract_bar) Meth(a ...interface{}) int { + argc := len(a) + if argc == 1 { + return p.Meth__SWIG_0(a[0].(int)) + } + if argc == 2 { + return p.Meth__SWIG_1(a[0].(int), a[1].(int)) + } + panic("No match for overloaded function call") +} + +func (p SwigcptrAbstract_bar) SwigIsAbstract_foo() { +} + +func (p SwigcptrAbstract_bar) SwigGetAbstract_foo() Abstract_foo { + return SwigcptrAbstract_foo(p.Swigcptr()) +} + +type Abstract_bar interface { + Swigcptr() uintptr + SwigIsAbstract_bar() + Meth(a ...interface{}) int + SwigIsAbstract_foo() + SwigGetAbstract_foo() Abstract_foo +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/abstract_typedef.go b/Examples/test-suite/go/abstract_typedef.go new file mode 100644 index 000000000..c1d86f209 --- /dev/null +++ b/Examples/test-suite/go/abstract_typedef.go @@ -0,0 +1,174 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../abstract_typedef.i + +package abstract_typedef + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrEngine uintptr + +func (p SwigcptrEngine) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrEngine) SwigIsEngine() { +} + +var _wrap_new_Engine unsafe.Pointer + +func _swig_wrap_new_Engine() (base SwigcptrEngine) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Engine, _swig_p) + return +} + +func NewEngine() (_swig_ret Engine) { + return _swig_wrap_new_Engine() +} + +var _wrap_delete_Engine unsafe.Pointer + +func _swig_wrap_delete_Engine(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Engine, _swig_p) + return +} + +func DeleteEngine(arg1 Engine) { + _swig_wrap_delete_Engine(arg1.Swigcptr()) +} + +type Engine interface { + Swigcptr() uintptr + SwigIsEngine() +} + +type SwigcptrAbstractBaseClass uintptr + +func (p SwigcptrAbstractBaseClass) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrAbstractBaseClass) SwigIsAbstractBaseClass() { +} + +var _wrap_delete_AbstractBaseClass unsafe.Pointer + +func _swig_wrap_delete_AbstractBaseClass(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_AbstractBaseClass, _swig_p) + return +} + +func DeleteAbstractBaseClass(arg1 AbstractBaseClass) { + _swig_wrap_delete_AbstractBaseClass(arg1.Swigcptr()) +} + +var _wrap_AbstractBaseClass_write unsafe.Pointer + +func _swig_wrap_AbstractBaseClass_write(base SwigcptrAbstractBaseClass, _ uintptr) (_ bool) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_AbstractBaseClass_write, _swig_p) + return +} + +func (arg1 SwigcptrAbstractBaseClass) Write(arg2 Engine) (_swig_ret bool) { + return _swig_wrap_AbstractBaseClass_write(arg1, arg2.Swigcptr()) +} + +type AbstractBaseClass interface { + Swigcptr() uintptr + SwigIsAbstractBaseClass() + Write(arg2 Engine) (_swig_ret bool) +} + +type SwigcptrA uintptr + +func (p SwigcptrA) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrA) SwigIsA() { +} + +var _wrap_new_A unsafe.Pointer + +func _swig_wrap_new_A() (base SwigcptrA) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_A, _swig_p) + return +} + +func NewA() (_swig_ret A) { + return _swig_wrap_new_A() +} + +var _wrap_delete_A unsafe.Pointer + +func _swig_wrap_delete_A(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_A, _swig_p) + return +} + +func DeleteA(arg1 A) { + _swig_wrap_delete_A(arg1.Swigcptr()) +} + +var _wrap_A_write unsafe.Pointer + +func _swig_wrap_A_write(base SwigcptrA, _ uintptr) (_ bool) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_A_write, _swig_p) + return +} + +func (_swig_base SwigcptrA) Write(arg1 Engine) (_swig_ret bool) { + return _swig_wrap_A_write(_swig_base, arg1.Swigcptr()) +} + +func (p SwigcptrA) SwigIsAbstractBaseClass() { +} + +func (p SwigcptrA) SwigGetAbstractBaseClass() AbstractBaseClass { + return SwigcptrAbstractBaseClass(p.Swigcptr()) +} + +type A interface { + Swigcptr() uintptr + SwigIsA() + Write(arg1 Engine) (_swig_ret bool) + SwigIsAbstractBaseClass() + SwigGetAbstractBaseClass() AbstractBaseClass +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/abstract_typedef2.go b/Examples/test-suite/go/abstract_typedef2.go new file mode 100644 index 000000000..24cc29b62 --- /dev/null +++ b/Examples/test-suite/go/abstract_typedef2.go @@ -0,0 +1,184 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../abstract_typedef2.i + +package abstract_typedef2 + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type FieldDim int +var _wrap_UnaryField unsafe.Pointer + +func _swig_getUnaryField() (_swig_ret FieldDim) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_UnaryField, _swig_p) + return +} +var UnaryField FieldDim = _swig_getUnaryField() +var _wrap_BinaryField unsafe.Pointer + +func _swig_getBinaryField() (_swig_ret FieldDim) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_BinaryField, _swig_p) + return +} +var BinaryField FieldDim = _swig_getBinaryField() +type SwigcptrBase_UF uintptr + +func (p SwigcptrBase_UF) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrBase_UF) SwigIsBase_UF() { +} + +var _wrap_delete_Base_UF unsafe.Pointer + +func _swig_wrap_delete_Base_UF(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Base_UF, _swig_p) + return +} + +func DeleteBase_UF(arg1 Base_UF) { + _swig_wrap_delete_Base_UF(arg1.Swigcptr()) +} + +var _wrap_Base_UF_set unsafe.Pointer + +func _swig_wrap_Base_UF_set(base SwigcptrBase_UF, _ uint) (_ SwigcptrFacet_Sl_UnaryField_Sg_) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Base_UF_set, _swig_p) + return +} + +func (arg1 SwigcptrBase_UF) Set(arg2 uint) (_swig_ret Facet_Sl_UnaryField_Sg_) { + return _swig_wrap_Base_UF_set(arg1, arg2) +} + +type Base_UF interface { + Swigcptr() uintptr + SwigIsBase_UF() + Set(arg2 uint) (_swig_ret Facet_Sl_UnaryField_Sg_) +} + +type SwigcptrA_UF uintptr + +func (p SwigcptrA_UF) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrA_UF) SwigIsA_UF() { +} + +var _wrap_new_A_UF__SWIG_0 unsafe.Pointer + +func _swig_wrap_new_A_UF__SWIG_0(base int) (_ SwigcptrA_UF) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_A_UF__SWIG_0, _swig_p) + return +} + +func NewA_UF__SWIG_0(arg1 int) (_swig_ret A_UF) { + return _swig_wrap_new_A_UF__SWIG_0(arg1) +} + +var _wrap_new_A_UF__SWIG_1 unsafe.Pointer + +func _swig_wrap_new_A_UF__SWIG_1() (base SwigcptrA_UF) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_A_UF__SWIG_1, _swig_p) + return +} + +func NewA_UF__SWIG_1() (_swig_ret A_UF) { + return _swig_wrap_new_A_UF__SWIG_1() +} + +func NewA_UF(a ...interface{}) A_UF { + argc := len(a) + if argc == 0 { + return NewA_UF__SWIG_1() + } + if argc == 1 { + return NewA_UF__SWIG_0(a[0].(int)) + } + panic("No match for overloaded function call") +} + +var _wrap_A_UF_set unsafe.Pointer + +func _swig_wrap_A_UF_set(base SwigcptrA_UF, _ uint) (_ SwigcptrFacet_Sl_UnaryField_Sg_) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_A_UF_set, _swig_p) + return +} + +func (arg1 SwigcptrA_UF) Set(arg2 uint) (_swig_ret Facet_Sl_UnaryField_Sg_) { + return _swig_wrap_A_UF_set(arg1, arg2) +} + +var _wrap_delete_A_UF unsafe.Pointer + +func _swig_wrap_delete_A_UF(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_A_UF, _swig_p) + return +} + +func DeleteA_UF(arg1 A_UF) { + _swig_wrap_delete_A_UF(arg1.Swigcptr()) +} + +func (p SwigcptrA_UF) SwigIsBase_UF() { +} + +func (p SwigcptrA_UF) SwigGetBase_UF() Base_UF { + return SwigcptrBase_UF(p.Swigcptr()) +} + +type A_UF interface { + Swigcptr() uintptr + SwigIsA_UF() + Set(arg2 uint) (_swig_ret Facet_Sl_UnaryField_Sg_) + SwigIsBase_UF() + SwigGetBase_UF() Base_UF +} + + +type SwigcptrFacet_Sl_UnaryField_Sg_ uintptr +type Facet_Sl_UnaryField_Sg_ interface { + Swigcptr() uintptr; +} +func (p SwigcptrFacet_Sl_UnaryField_Sg_) Swigcptr() uintptr { + return uintptr(p) +} + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/abstract_typedef2_runme b/Examples/test-suite/go/abstract_typedef2_runme new file mode 100755 index 000000000..94e754462 Binary files /dev/null and b/Examples/test-suite/go/abstract_typedef2_runme differ diff --git a/Examples/test-suite/go/abstract_typedef_runme b/Examples/test-suite/go/abstract_typedef_runme new file mode 100755 index 000000000..ebdd3be45 Binary files /dev/null and b/Examples/test-suite/go/abstract_typedef_runme differ diff --git a/Examples/test-suite/go/abstract_virtual.go b/Examples/test-suite/go/abstract_virtual.go new file mode 100644 index 000000000..b958ab1ea --- /dev/null +++ b/Examples/test-suite/go/abstract_virtual.go @@ -0,0 +1,348 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../abstract_virtual.i + +package abstract_virtual + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrA uintptr + +func (p SwigcptrA) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrA) SwigIsA() { +} + +var _wrap_delete_A unsafe.Pointer + +func _swig_wrap_delete_A(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_A, _swig_p) + return +} + +func DeleteA(arg1 A) { + _swig_wrap_delete_A(arg1.Swigcptr()) +} + +var _wrap_A_foo unsafe.Pointer + +func _swig_wrap_A_foo(base SwigcptrA) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_A_foo, _swig_p) + return +} + +func (arg1 SwigcptrA) Foo() (_swig_ret int) { + return _swig_wrap_A_foo(arg1) +} + +type A interface { + Swigcptr() uintptr + SwigIsA() + Foo() (_swig_ret int) +} + +type SwigcptrB uintptr + +func (p SwigcptrB) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrB) SwigIsB() { +} + +var _wrap_B_foo unsafe.Pointer + +func _swig_wrap_B_foo(base SwigcptrB) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_B_foo, _swig_p) + return +} + +func (arg1 SwigcptrB) Foo() (_swig_ret int) { + return _swig_wrap_B_foo(arg1) +} + +var _wrap_new_B unsafe.Pointer + +func _swig_wrap_new_B() (base SwigcptrB) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_B, _swig_p) + return +} + +func NewB() (_swig_ret B) { + return _swig_wrap_new_B() +} + +var _wrap_delete_B unsafe.Pointer + +func _swig_wrap_delete_B(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_B, _swig_p) + return +} + +func DeleteB(arg1 B) { + _swig_wrap_delete_B(arg1.Swigcptr()) +} + +func (p SwigcptrB) SwigIsA() { +} + +func (p SwigcptrB) SwigGetA() A { + return SwigcptrA(p.Swigcptr()) +} + +type B interface { + Swigcptr() uintptr + SwigIsB() + Foo() (_swig_ret int) + SwigIsA() + SwigGetA() A +} + +type SwigcptrC uintptr + +func (p SwigcptrC) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrC) SwigIsC() { +} + +var _wrap_delete_C unsafe.Pointer + +func _swig_wrap_delete_C(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_C, _swig_p) + return +} + +func DeleteC(arg1 C) { + _swig_wrap_delete_C(arg1.Swigcptr()) +} + +var _wrap_C_foo unsafe.Pointer + +func _swig_wrap_C_foo(base SwigcptrC) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_C_foo, _swig_p) + return +} + +func (_swig_base SwigcptrC) Foo() (_swig_ret int) { + return _swig_wrap_C_foo(_swig_base) +} + +func (p SwigcptrC) SwigIsA() { +} + +func (p SwigcptrC) SwigGetA() A { + return SwigcptrA(p.Swigcptr()) +} + +type C interface { + Swigcptr() uintptr + SwigIsC() + Foo() (_swig_ret int) + SwigIsA() + SwigGetA() A +} + +type SwigcptrD uintptr + +func (p SwigcptrD) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrD) SwigIsD() { +} + +var _wrap_new_D unsafe.Pointer + +func _swig_wrap_new_D() (base SwigcptrD) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_D, _swig_p) + return +} + +func NewD() (_swig_ret D) { + return _swig_wrap_new_D() +} + +var _wrap_delete_D unsafe.Pointer + +func _swig_wrap_delete_D(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_D, _swig_p) + return +} + +func DeleteD(arg1 D) { + _swig_wrap_delete_D(arg1.Swigcptr()) +} + +var _wrap_D_foo unsafe.Pointer + +func _swig_wrap_D_foo(base SwigcptrD) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_D_foo, _swig_p) + return +} + +func (_swig_base SwigcptrD) Foo() (_swig_ret int) { + return _swig_wrap_D_foo(_swig_base) +} + +func (p SwigcptrD) SwigIsB() { +} + +func (p SwigcptrD) SwigGetB() B { + return SwigcptrB(p.Swigcptr()) +} + +func (p SwigcptrD) SwigIsA() { +} + +func (p SwigcptrD) SwigGetA() A { + return SwigcptrA(p.Swigcptr()) +} + +var _wrap_D_SwigGetC unsafe.Pointer + +func _swig_wrap_D_SwigGetC(base SwigcptrD) (_ SwigcptrC) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_D_SwigGetC, _swig_p) + return +} + +func (arg1 SwigcptrD) SwigGetC() (_swig_ret C) { + return _swig_wrap_D_SwigGetC(arg1) +} + +type D interface { + Swigcptr() uintptr + SwigIsD() + Foo() (_swig_ret int) + SwigIsB() + SwigGetB() B + SwigIsA() + SwigGetA() A + SwigGetC() (_swig_ret C) +} + +type SwigcptrE uintptr + +func (p SwigcptrE) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrE) SwigIsE() { +} + +var _wrap_new_E unsafe.Pointer + +func _swig_wrap_new_E() (base SwigcptrE) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_E, _swig_p) + return +} + +func NewE() (_swig_ret E) { + return _swig_wrap_new_E() +} + +var _wrap_delete_E unsafe.Pointer + +func _swig_wrap_delete_E(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_E, _swig_p) + return +} + +func DeleteE(arg1 E) { + _swig_wrap_delete_E(arg1.Swigcptr()) +} + +var _wrap_E_foo unsafe.Pointer + +func _swig_wrap_E_foo(base SwigcptrE) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_E_foo, _swig_p) + return +} + +func (_swig_base SwigcptrE) Foo() (_swig_ret int) { + return _swig_wrap_E_foo(_swig_base) +} + +func (p SwigcptrE) SwigIsC() { +} + +func (p SwigcptrE) SwigGetC() C { + return SwigcptrC(p.Swigcptr()) +} + +func (p SwigcptrE) SwigIsA() { +} + +func (p SwigcptrE) SwigGetA() A { + return SwigcptrA(p.Swigcptr()) +} + +var _wrap_E_SwigGetB unsafe.Pointer + +func _swig_wrap_E_SwigGetB(base SwigcptrE) (_ SwigcptrB) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_E_SwigGetB, _swig_p) + return +} + +func (arg1 SwigcptrE) SwigGetB() (_swig_ret B) { + return _swig_wrap_E_SwigGetB(arg1) +} + +type E interface { + Swigcptr() uintptr + SwigIsE() + Foo() (_swig_ret int) + SwigIsC() + SwigGetC() C + SwigIsA() + SwigGetA() A + SwigGetB() (_swig_ret B) +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/abstract_virtual_runme b/Examples/test-suite/go/abstract_virtual_runme new file mode 100755 index 000000000..1fbda7f02 Binary files /dev/null and b/Examples/test-suite/go/abstract_virtual_runme differ diff --git a/Examples/test-suite/go/access_change.go b/Examples/test-suite/go/access_change.go new file mode 100644 index 000000000..e0429b74a --- /dev/null +++ b/Examples/test-suite/go/access_change.go @@ -0,0 +1,438 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../access_change.i + +package access_change + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrBaseInt uintptr + +func (p SwigcptrBaseInt) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrBaseInt) SwigIsBaseInt() { +} + +var _wrap_delete_BaseInt unsafe.Pointer + +func _swig_wrap_delete_BaseInt(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_BaseInt, _swig_p) + return +} + +func DeleteBaseInt(arg1 BaseInt) { + _swig_wrap_delete_BaseInt(arg1.Swigcptr()) +} + +var _wrap_BaseInt_PublicProtectedPublic1 unsafe.Pointer + +func _swig_wrap_BaseInt_PublicProtectedPublic1(base SwigcptrBaseInt) (_ *int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_BaseInt_PublicProtectedPublic1, _swig_p) + return +} + +func (arg1 SwigcptrBaseInt) PublicProtectedPublic1() (_swig_ret *int) { + return _swig_wrap_BaseInt_PublicProtectedPublic1(arg1) +} + +var _wrap_BaseInt_PublicProtectedPublic2 unsafe.Pointer + +func _swig_wrap_BaseInt_PublicProtectedPublic2(base SwigcptrBaseInt) (_ *int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_BaseInt_PublicProtectedPublic2, _swig_p) + return +} + +func (arg1 SwigcptrBaseInt) PublicProtectedPublic2() (_swig_ret *int) { + return _swig_wrap_BaseInt_PublicProtectedPublic2(arg1) +} + +var _wrap_BaseInt_PublicProtectedPublic3 unsafe.Pointer + +func _swig_wrap_BaseInt_PublicProtectedPublic3(base SwigcptrBaseInt) (_ *int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_BaseInt_PublicProtectedPublic3, _swig_p) + return +} + +func (arg1 SwigcptrBaseInt) PublicProtectedPublic3() (_swig_ret *int) { + return _swig_wrap_BaseInt_PublicProtectedPublic3(arg1) +} + +var _wrap_BaseInt_PublicProtectedPublic4 unsafe.Pointer + +func _swig_wrap_BaseInt_PublicProtectedPublic4(base SwigcptrBaseInt) (_ *int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_BaseInt_PublicProtectedPublic4, _swig_p) + return +} + +func (arg1 SwigcptrBaseInt) PublicProtectedPublic4() (_swig_ret *int) { + return _swig_wrap_BaseInt_PublicProtectedPublic4(arg1) +} + +var _wrap_new_BaseInt unsafe.Pointer + +func _swig_wrap_new_BaseInt() (base SwigcptrBaseInt) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_BaseInt, _swig_p) + return +} + +func NewBaseInt() (_swig_ret BaseInt) { + return _swig_wrap_new_BaseInt() +} + +type BaseInt interface { + Swigcptr() uintptr + SwigIsBaseInt() + PublicProtectedPublic1() (_swig_ret *int) + PublicProtectedPublic2() (_swig_ret *int) + PublicProtectedPublic3() (_swig_ret *int) + PublicProtectedPublic4() (_swig_ret *int) +} + +type SwigcptrDerivedInt uintptr + +func (p SwigcptrDerivedInt) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrDerivedInt) SwigIsDerivedInt() { +} + +var _wrap_DerivedInt_WasProtected1 unsafe.Pointer + +func _swig_wrap_DerivedInt_WasProtected1(base SwigcptrDerivedInt) (_ *int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_DerivedInt_WasProtected1, _swig_p) + return +} + +func (arg1 SwigcptrDerivedInt) WasProtected1() (_swig_ret *int) { + return _swig_wrap_DerivedInt_WasProtected1(arg1) +} + +var _wrap_DerivedInt_WasProtected2 unsafe.Pointer + +func _swig_wrap_DerivedInt_WasProtected2(base SwigcptrDerivedInt) (_ *int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_DerivedInt_WasProtected2, _swig_p) + return +} + +func (arg1 SwigcptrDerivedInt) WasProtected2() (_swig_ret *int) { + return _swig_wrap_DerivedInt_WasProtected2(arg1) +} + +var _wrap_DerivedInt_WasProtected3 unsafe.Pointer + +func _swig_wrap_DerivedInt_WasProtected3(base SwigcptrDerivedInt) (_ *int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_DerivedInt_WasProtected3, _swig_p) + return +} + +func (arg1 SwigcptrDerivedInt) WasProtected3() (_swig_ret *int) { + return _swig_wrap_DerivedInt_WasProtected3(arg1) +} + +var _wrap_DerivedInt_WasProtected4 unsafe.Pointer + +func _swig_wrap_DerivedInt_WasProtected4(base SwigcptrDerivedInt) (_ *int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_DerivedInt_WasProtected4, _swig_p) + return +} + +func (arg1 SwigcptrDerivedInt) WasProtected4() (_swig_ret *int) { + return _swig_wrap_DerivedInt_WasProtected4(arg1) +} + +var _wrap_new_DerivedInt unsafe.Pointer + +func _swig_wrap_new_DerivedInt() (base SwigcptrDerivedInt) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_DerivedInt, _swig_p) + return +} + +func NewDerivedInt() (_swig_ret DerivedInt) { + return _swig_wrap_new_DerivedInt() +} + +var _wrap_delete_DerivedInt unsafe.Pointer + +func _swig_wrap_delete_DerivedInt(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_DerivedInt, _swig_p) + return +} + +func DeleteDerivedInt(arg1 DerivedInt) { + _swig_wrap_delete_DerivedInt(arg1.Swigcptr()) +} + +var _wrap_DerivedInt_PublicProtectedPublic1 unsafe.Pointer + +func _swig_wrap_DerivedInt_PublicProtectedPublic1(base SwigcptrDerivedInt) (_ *int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_DerivedInt_PublicProtectedPublic1, _swig_p) + return +} + +func (_swig_base SwigcptrDerivedInt) PublicProtectedPublic1() (_swig_ret *int) { + return _swig_wrap_DerivedInt_PublicProtectedPublic1(_swig_base) +} + +var _wrap_DerivedInt_PublicProtectedPublic2 unsafe.Pointer + +func _swig_wrap_DerivedInt_PublicProtectedPublic2(base SwigcptrDerivedInt) (_ *int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_DerivedInt_PublicProtectedPublic2, _swig_p) + return +} + +func (_swig_base SwigcptrDerivedInt) PublicProtectedPublic2() (_swig_ret *int) { + return _swig_wrap_DerivedInt_PublicProtectedPublic2(_swig_base) +} + +var _wrap_DerivedInt_PublicProtectedPublic3 unsafe.Pointer + +func _swig_wrap_DerivedInt_PublicProtectedPublic3(base SwigcptrDerivedInt) (_ *int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_DerivedInt_PublicProtectedPublic3, _swig_p) + return +} + +func (_swig_base SwigcptrDerivedInt) PublicProtectedPublic3() (_swig_ret *int) { + return _swig_wrap_DerivedInt_PublicProtectedPublic3(_swig_base) +} + +var _wrap_DerivedInt_PublicProtectedPublic4 unsafe.Pointer + +func _swig_wrap_DerivedInt_PublicProtectedPublic4(base SwigcptrDerivedInt) (_ *int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_DerivedInt_PublicProtectedPublic4, _swig_p) + return +} + +func (_swig_base SwigcptrDerivedInt) PublicProtectedPublic4() (_swig_ret *int) { + return _swig_wrap_DerivedInt_PublicProtectedPublic4(_swig_base) +} + +func (p SwigcptrDerivedInt) SwigIsBaseInt() { +} + +func (p SwigcptrDerivedInt) SwigGetBaseInt() BaseInt { + return SwigcptrBaseInt(p.Swigcptr()) +} + +type DerivedInt interface { + Swigcptr() uintptr + SwigIsDerivedInt() + WasProtected1() (_swig_ret *int) + WasProtected2() (_swig_ret *int) + WasProtected3() (_swig_ret *int) + WasProtected4() (_swig_ret *int) + PublicProtectedPublic1() (_swig_ret *int) + PublicProtectedPublic2() (_swig_ret *int) + PublicProtectedPublic3() (_swig_ret *int) + PublicProtectedPublic4() (_swig_ret *int) + SwigIsBaseInt() + SwigGetBaseInt() BaseInt +} + +type SwigcptrBottomInt uintptr + +func (p SwigcptrBottomInt) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrBottomInt) SwigIsBottomInt() { +} + +var _wrap_BottomInt_WasProtected1 unsafe.Pointer + +func _swig_wrap_BottomInt_WasProtected1(base SwigcptrBottomInt) (_ *int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_BottomInt_WasProtected1, _swig_p) + return +} + +func (arg1 SwigcptrBottomInt) WasProtected1() (_swig_ret *int) { + return _swig_wrap_BottomInt_WasProtected1(arg1) +} + +var _wrap_BottomInt_WasProtected2 unsafe.Pointer + +func _swig_wrap_BottomInt_WasProtected2(base SwigcptrBottomInt) (_ *int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_BottomInt_WasProtected2, _swig_p) + return +} + +func (arg1 SwigcptrBottomInt) WasProtected2() (_swig_ret *int) { + return _swig_wrap_BottomInt_WasProtected2(arg1) +} + +var _wrap_BottomInt_WasProtected3 unsafe.Pointer + +func _swig_wrap_BottomInt_WasProtected3(base SwigcptrBottomInt) (_ *int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_BottomInt_WasProtected3, _swig_p) + return +} + +func (arg1 SwigcptrBottomInt) WasProtected3() (_swig_ret *int) { + return _swig_wrap_BottomInt_WasProtected3(arg1) +} + +var _wrap_BottomInt_WasProtected4 unsafe.Pointer + +func _swig_wrap_BottomInt_WasProtected4(base SwigcptrBottomInt) (_ *int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_BottomInt_WasProtected4, _swig_p) + return +} + +func (arg1 SwigcptrBottomInt) WasProtected4() (_swig_ret *int) { + return _swig_wrap_BottomInt_WasProtected4(arg1) +} + +var _wrap_BottomInt_PublicProtectedPublic1 unsafe.Pointer + +func _swig_wrap_BottomInt_PublicProtectedPublic1(base SwigcptrBottomInt) (_ *int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_BottomInt_PublicProtectedPublic1, _swig_p) + return +} + +func (arg1 SwigcptrBottomInt) PublicProtectedPublic1() (_swig_ret *int) { + return _swig_wrap_BottomInt_PublicProtectedPublic1(arg1) +} + +var _wrap_BottomInt_PublicProtectedPublic2 unsafe.Pointer + +func _swig_wrap_BottomInt_PublicProtectedPublic2(base SwigcptrBottomInt) (_ *int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_BottomInt_PublicProtectedPublic2, _swig_p) + return +} + +func (arg1 SwigcptrBottomInt) PublicProtectedPublic2() (_swig_ret *int) { + return _swig_wrap_BottomInt_PublicProtectedPublic2(arg1) +} + +var _wrap_BottomInt_PublicProtectedPublic3 unsafe.Pointer + +func _swig_wrap_BottomInt_PublicProtectedPublic3(base SwigcptrBottomInt) (_ *int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_BottomInt_PublicProtectedPublic3, _swig_p) + return +} + +func (arg1 SwigcptrBottomInt) PublicProtectedPublic3() (_swig_ret *int) { + return _swig_wrap_BottomInt_PublicProtectedPublic3(arg1) +} + +var _wrap_BottomInt_PublicProtectedPublic4 unsafe.Pointer + +func _swig_wrap_BottomInt_PublicProtectedPublic4(base SwigcptrBottomInt) (_ *int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_BottomInt_PublicProtectedPublic4, _swig_p) + return +} + +func (arg1 SwigcptrBottomInt) PublicProtectedPublic4() (_swig_ret *int) { + return _swig_wrap_BottomInt_PublicProtectedPublic4(arg1) +} + +var _wrap_new_BottomInt unsafe.Pointer + +func _swig_wrap_new_BottomInt() (base SwigcptrBottomInt) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_BottomInt, _swig_p) + return +} + +func NewBottomInt() (_swig_ret BottomInt) { + return _swig_wrap_new_BottomInt() +} + +var _wrap_delete_BottomInt unsafe.Pointer + +func _swig_wrap_delete_BottomInt(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_BottomInt, _swig_p) + return +} + +func DeleteBottomInt(arg1 BottomInt) { + _swig_wrap_delete_BottomInt(arg1.Swigcptr()) +} + +func (p SwigcptrBottomInt) SwigIsDerivedInt() { +} + +func (p SwigcptrBottomInt) SwigGetDerivedInt() DerivedInt { + return SwigcptrDerivedInt(p.Swigcptr()) +} + +func (p SwigcptrBottomInt) SwigIsBaseInt() { +} + +func (p SwigcptrBottomInt) SwigGetBaseInt() BaseInt { + return SwigcptrBaseInt(p.Swigcptr()) +} + +type BottomInt interface { + Swigcptr() uintptr + SwigIsBottomInt() + WasProtected1() (_swig_ret *int) + WasProtected2() (_swig_ret *int) + WasProtected3() (_swig_ret *int) + WasProtected4() (_swig_ret *int) + PublicProtectedPublic1() (_swig_ret *int) + PublicProtectedPublic2() (_swig_ret *int) + PublicProtectedPublic3() (_swig_ret *int) + PublicProtectedPublic4() (_swig_ret *int) + SwigIsDerivedInt() + SwigGetDerivedInt() DerivedInt + SwigIsBaseInt() + SwigGetBaseInt() BaseInt +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/add_link.go b/Examples/test-suite/go/add_link.go new file mode 100644 index 000000000..987a30cbd --- /dev/null +++ b/Examples/test-suite/go/add_link.go @@ -0,0 +1,88 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../add_link.i + +package add_link + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrFoo uintptr + +func (p SwigcptrFoo) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrFoo) SwigIsFoo() { +} + +var _wrap_new_Foo unsafe.Pointer + +func _swig_wrap_new_Foo() (base SwigcptrFoo) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Foo, _swig_p) + return +} + +func NewFoo() (_swig_ret Foo) { + return _swig_wrap_new_Foo() +} + +var _wrap_Foo_blah unsafe.Pointer + +func _swig_wrap_Foo_blah(base SwigcptrFoo) (_ SwigcptrFoo) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_blah, _swig_p) + return +} + +func (arg1 SwigcptrFoo) Blah() (_swig_ret Foo) { + return _swig_wrap_Foo_blah(arg1) +} + +var _wrap_delete_Foo unsafe.Pointer + +func _swig_wrap_delete_Foo(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Foo, _swig_p) + return +} + +func DeleteFoo(arg1 Foo) { + _swig_wrap_delete_Foo(arg1.Swigcptr()) +} + +type Foo interface { + Swigcptr() uintptr + SwigIsFoo() + Blah() (_swig_ret Foo) +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/aggregate.go b/Examples/test-suite/go/aggregate.go new file mode 100644 index 000000000..a4bd498f8 --- /dev/null +++ b/Examples/test-suite/go/aggregate.go @@ -0,0 +1,40 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../aggregate.i + +package aggregate + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +const UP int = 1 +const DOWN int = 2 +const LEFT int = 3 +const RIGHT int = 4 +var _wrap_move unsafe.Pointer + +func Move(arg1 int) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_move, _swig_p) + return +} + diff --git a/Examples/test-suite/go/allowexcept.go b/Examples/test-suite/go/allowexcept.go new file mode 100644 index 000000000..13cadbaa9 --- /dev/null +++ b/Examples/test-suite/go/allowexcept.go @@ -0,0 +1,241 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../allowexcept.i + +package allowexcept + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrUVW uintptr + +func (p SwigcptrUVW) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrUVW) SwigIsUVW() { +} + +type UVW interface { + Swigcptr() uintptr + SwigIsUVW() +} + +var _wrap_uvw_global_variable_set unsafe.Pointer + +func _swig_wrap_uvw_global_variable_set(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_uvw_global_variable_set, _swig_p) + return +} + +func SetUvw_global_variable(arg1 UVW) { + _swig_wrap_uvw_global_variable_set(arg1.Swigcptr()) +} + +var _wrap_uvw_global_variable_get unsafe.Pointer + +func _swig_wrap_uvw_global_variable_get() (base SwigcptrUVW) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_uvw_global_variable_get, _swig_p) + return +} + +func GetUvw_global_variable() (_swig_ret UVW) { + return _swig_wrap_uvw_global_variable_get() +} + +type SwigcptrBar uintptr + +func (p SwigcptrBar) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrBar) SwigIsBar() { +} + +var _wrap_Bar_member_variable_set unsafe.Pointer + +func _swig_wrap_Bar_member_variable_set(base SwigcptrBar, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Bar_member_variable_set, _swig_p) + return +} + +func (arg1 SwigcptrBar) SetMember_variable(arg2 UVW) { + _swig_wrap_Bar_member_variable_set(arg1, arg2.Swigcptr()) +} + +var _wrap_Bar_member_variable_get unsafe.Pointer + +func _swig_wrap_Bar_member_variable_get(base SwigcptrBar) (_ SwigcptrUVW) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Bar_member_variable_get, _swig_p) + return +} + +func (arg1 SwigcptrBar) GetMember_variable() (_swig_ret UVW) { + return _swig_wrap_Bar_member_variable_get(arg1) +} + +var _wrap_Bar_static_member_variable_set unsafe.Pointer + +func _swig_wrap_Bar_static_member_variable_set(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Bar_static_member_variable_set, _swig_p) + return +} + +func SetBarStatic_member_variable(arg1 UVW) { + _swig_wrap_Bar_static_member_variable_set(arg1.Swigcptr()) +} + +var _wrap_Bar_static_member_variable_get unsafe.Pointer + +func _swig_wrap_Bar_static_member_variable_get() (base SwigcptrUVW) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Bar_static_member_variable_get, _swig_p) + return +} + +func GetBarStatic_member_variable() (_swig_ret UVW) { + return _swig_wrap_Bar_static_member_variable_get() +} + +type Bar interface { + Swigcptr() uintptr + SwigIsBar() + SetMember_variable(arg2 UVW) + GetMember_variable() (_swig_ret UVW) +} + +type SwigcptrXYZ uintptr + +func (p SwigcptrXYZ) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrXYZ) SwigIsXYZ() { +} + +type XYZ interface { + Swigcptr() uintptr + SwigIsXYZ() +} + +var _wrap_global_variable_set unsafe.Pointer + +func _swig_wrap_global_variable_set(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_global_variable_set, _swig_p) + return +} + +func SetGlobal_variable(arg1 XYZ) { + _swig_wrap_global_variable_set(arg1.Swigcptr()) +} + +var _wrap_global_variable_get unsafe.Pointer + +func _swig_wrap_global_variable_get() (base SwigcptrXYZ) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_global_variable_get, _swig_p) + return +} + +func GetGlobal_variable() (_swig_ret XYZ) { + return _swig_wrap_global_variable_get() +} + +type SwigcptrFoo uintptr + +func (p SwigcptrFoo) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrFoo) SwigIsFoo() { +} + +var _wrap_Foo_member_variable_set unsafe.Pointer + +func _swig_wrap_Foo_member_variable_set(base SwigcptrFoo, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_member_variable_set, _swig_p) + return +} + +func (arg1 SwigcptrFoo) SetMember_variable(arg2 XYZ) { + _swig_wrap_Foo_member_variable_set(arg1, arg2.Swigcptr()) +} + +var _wrap_Foo_member_variable_get unsafe.Pointer + +func _swig_wrap_Foo_member_variable_get(base SwigcptrFoo) (_ SwigcptrXYZ) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_member_variable_get, _swig_p) + return +} + +func (arg1 SwigcptrFoo) GetMember_variable() (_swig_ret XYZ) { + return _swig_wrap_Foo_member_variable_get(arg1) +} + +var _wrap_Foo_static_member_variable_set unsafe.Pointer + +func _swig_wrap_Foo_static_member_variable_set(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_static_member_variable_set, _swig_p) + return +} + +func SetFooStatic_member_variable(arg1 XYZ) { + _swig_wrap_Foo_static_member_variable_set(arg1.Swigcptr()) +} + +var _wrap_Foo_static_member_variable_get unsafe.Pointer + +func _swig_wrap_Foo_static_member_variable_get() (base SwigcptrXYZ) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_static_member_variable_get, _swig_p) + return +} + +func GetFooStatic_member_variable() (_swig_ret XYZ) { + return _swig_wrap_Foo_static_member_variable_get() +} + +type Foo interface { + Swigcptr() uintptr + SwigIsFoo() + SetMember_variable(arg2 XYZ) + GetMember_variable() (_swig_ret XYZ) +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/allprotected.go b/Examples/test-suite/go/allprotected.go new file mode 100644 index 000000000..223d32f4f --- /dev/null +++ b/Examples/test-suite/go/allprotected.go @@ -0,0 +1,681 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../allprotected.i + +package allprotected + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrKlass uintptr + +func (p SwigcptrKlass) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrKlass) SwigIsKlass() { +} + +var _wrap_new_Klass unsafe.Pointer + +func _swig_wrap_new_Klass(base string) (_ SwigcptrKlass) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Klass, _swig_p) + return +} + +func NewKlass(arg1 string) (_swig_ret Klass) { + return _swig_wrap_new_Klass(arg1) +} + +var _wrap_Klass_getName unsafe.Pointer + +func _swig_wrap_Klass_getName(base SwigcptrKlass) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Klass_getName, _swig_p) + return +} + +func (arg1 SwigcptrKlass) GetName() (_swig_ret string) { + return _swig_wrap_Klass_getName(arg1) +} + +var _wrap_delete_Klass unsafe.Pointer + +func _swig_wrap_delete_Klass(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Klass, _swig_p) + return +} + +func DeleteKlass(arg1 Klass) { + _swig_wrap_delete_Klass(arg1.Swigcptr()) +} + +type Klass interface { + Swigcptr() uintptr + SwigIsKlass() + GetName() (_swig_ret string) +} + +type _swig_DirectorPublicBase struct { + SwigcptrPublicBase + v interface{} +} + +func (p *_swig_DirectorPublicBase) Swigcptr() uintptr { + return p.SwigcptrPublicBase.Swigcptr() +} + +func (p *_swig_DirectorPublicBase) SwigIsPublicBase() { +} + +func (p *_swig_DirectorPublicBase) DirectorInterface() interface{} { + return p.v +} + +var _wrap__swig_NewDirectorPublicBasePublicBase unsafe.Pointer + +func _swig_NewDirectorPublicBasePublicBase(_swig_director *_swig_DirectorPublicBase, _ string) (_swig_ret SwigcptrPublicBase) { + _swig_p := uintptr(unsafe.Pointer(&_swig_director)) + _cgo_runtime_cgocall(_wrap__swig_NewDirectorPublicBasePublicBase, _swig_p) + return +} + +func NewDirectorPublicBase(v interface{}, arg1 string) PublicBase { + p := &_swig_DirectorPublicBase{0, v} + p.SwigcptrPublicBase = _swig_NewDirectorPublicBasePublicBase(p, arg1) + return p +} + +var _wrap_DeleteDirectorPublicBase unsafe.Pointer + +func _swig_wrap_DeleteDirectorPublicBase(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_DeleteDirectorPublicBase, _swig_p) + return +} + +func DeleteDirectorPublicBase(arg1 PublicBase) { + _swig_wrap_DeleteDirectorPublicBase(arg1.Swigcptr()) +} + +func Swiggo_DeleteDirector_PublicBase(p *_swig_DirectorPublicBase) { + p.SwigcptrPublicBase = 0 +} + +type _swig_DirectorInterfacePublicBaseVirtualMethod interface { + VirtualMethod() string +} + +var _wrap__swig_DirectorPublicBase_upcall_VirtualMethod unsafe.Pointer + +func _swig_wrap__swig_DirectorPublicBase_upcall_VirtualMethod(_swig_ptr SwigcptrPublicBase) (_swig_ret string) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) + _cgo_runtime_cgocall(_wrap__swig_DirectorPublicBase_upcall_VirtualMethod, _swig_p) + return +} + +func (swig_p *_swig_DirectorPublicBase) VirtualMethod() string { + if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfacePublicBaseVirtualMethod); swig_ok { + return swig_g.VirtualMethod() + } + var swig_r string + swig_r = _swig_wrap__swig_DirectorPublicBase_upcall_VirtualMethod(swig_p.SwigcptrPublicBase) + return swig_r +} + +func DirectorPublicBaseVirtualMethod(p PublicBase) string { + var swig_r string + swig_r = _swig_wrap__swig_DirectorPublicBase_upcall_VirtualMethod(p.(*_swig_DirectorPublicBase).SwigcptrPublicBase) + return swig_r +} + +func Swig_DirectorPublicBase_callback_virtualMethod(p *_swig_DirectorPublicBase) (swig_result string) { + var swig_r string + swig_r = p.VirtualMethod() + return swig_r +} + +type SwigcptrPublicBase uintptr + +func (p SwigcptrPublicBase) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrPublicBase) SwigIsPublicBase() { +} + +func (p SwigcptrPublicBase) DirectorInterface() interface{} { + return nil +} + +type PublicBaseAnEnum int +var _wrap_EnumVal1_PublicBase unsafe.Pointer + +func _swig_getPublicBase_EnumVal1_PublicBase() (_swig_ret PublicBaseAnEnum) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_EnumVal1_PublicBase, _swig_p) + return +} +var PublicBaseEnumVal1 PublicBaseAnEnum = _swig_getPublicBase_EnumVal1_PublicBase() +var _wrap_EnumVal2_PublicBase unsafe.Pointer + +func _swig_getPublicBase_EnumVal2_PublicBase() (_swig_ret PublicBaseAnEnum) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_EnumVal2_PublicBase, _swig_p) + return +} +var PublicBaseEnumVal2 PublicBaseAnEnum = _swig_getPublicBase_EnumVal2_PublicBase() +var _wrap_new_PublicBase unsafe.Pointer + +func _swig_wrap_new_PublicBase(base string) (_ SwigcptrPublicBase) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_PublicBase, _swig_p) + return +} + +func NewPublicBase(arg1 string) (_swig_ret PublicBase) { + return _swig_wrap_new_PublicBase(arg1) +} + +var _wrap_delete_PublicBase unsafe.Pointer + +func _swig_wrap_delete_PublicBase(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_PublicBase, _swig_p) + return +} + +func DeletePublicBase(arg1 PublicBase) { + _swig_wrap_delete_PublicBase(arg1.Swigcptr()) +} + +var _wrap_PublicBase_virtualMethod unsafe.Pointer + +func _swig_wrap_PublicBase_virtualMethod(base SwigcptrPublicBase) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_PublicBase_virtualMethod, _swig_p) + return +} + +func (arg1 SwigcptrPublicBase) VirtualMethod() (_swig_ret string) { + return _swig_wrap_PublicBase_virtualMethod(arg1) +} + +var _wrap_PublicBase_instanceMethod unsafe.Pointer + +func _swig_wrap_PublicBase_instanceMethod(base SwigcptrPublicBase, _ uintptr) (_ SwigcptrKlass) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_PublicBase_instanceMethod, _swig_p) + return +} + +func (arg1 SwigcptrPublicBase) InstanceMethod(arg2 Klass) (_swig_ret Klass) { + return _swig_wrap_PublicBase_instanceMethod(arg1, arg2.Swigcptr()) +} + +var _wrap_PublicBase_instanceOverloaded__SWIG_0 unsafe.Pointer + +func _swig_wrap_PublicBase_instanceOverloaded__SWIG_0(base SwigcptrPublicBase, _ uintptr) (_ SwigcptrKlass) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_PublicBase_instanceOverloaded__SWIG_0, _swig_p) + return +} + +func (arg1 SwigcptrPublicBase) InstanceOverloaded__SWIG_0(arg2 Klass) (_swig_ret Klass) { + return _swig_wrap_PublicBase_instanceOverloaded__SWIG_0(arg1, arg2.Swigcptr()) +} + +var _wrap_PublicBase_instanceOverloaded__SWIG_1 unsafe.Pointer + +func _swig_wrap_PublicBase_instanceOverloaded__SWIG_1(base SwigcptrPublicBase, _ uintptr, _ string) (_ SwigcptrKlass) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_PublicBase_instanceOverloaded__SWIG_1, _swig_p) + return +} + +func (arg1 SwigcptrPublicBase) InstanceOverloaded__SWIG_1(arg2 Klass, arg3 string) (_swig_ret Klass) { + return _swig_wrap_PublicBase_instanceOverloaded__SWIG_1(arg1, arg2.Swigcptr(), arg3) +} + +func (p SwigcptrPublicBase) InstanceOverloaded(a ...interface{}) Klass { + argc := len(a) + if argc == 1 { + return p.InstanceOverloaded__SWIG_0(a[0].(Klass)) + } + if argc == 2 { + return p.InstanceOverloaded__SWIG_1(a[0].(Klass), a[1].(string)) + } + panic("No match for overloaded function call") +} + +var _wrap_PublicBase_staticMethod unsafe.Pointer + +func _swig_wrap_PublicBase_staticMethod(base uintptr) (_ SwigcptrKlass) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_PublicBase_staticMethod, _swig_p) + return +} + +func PublicBaseStaticMethod(arg1 Klass) (_swig_ret Klass) { + return _swig_wrap_PublicBase_staticMethod(arg1.Swigcptr()) +} + +var _wrap_PublicBase_staticOverloaded__SWIG_0 unsafe.Pointer + +func _swig_wrap_PublicBase_staticOverloaded__SWIG_0(base uintptr) (_ SwigcptrKlass) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_PublicBase_staticOverloaded__SWIG_0, _swig_p) + return +} + +func PublicBaseStaticOverloaded__SWIG_0(arg1 Klass) (_swig_ret Klass) { + return _swig_wrap_PublicBase_staticOverloaded__SWIG_0(arg1.Swigcptr()) +} + +var _wrap_PublicBase_staticOverloaded__SWIG_1 unsafe.Pointer + +func _swig_wrap_PublicBase_staticOverloaded__SWIG_1(base uintptr, _ string) (_ SwigcptrKlass) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_PublicBase_staticOverloaded__SWIG_1, _swig_p) + return +} + +func PublicBaseStaticOverloaded__SWIG_1(arg1 Klass, arg2 string) (_swig_ret Klass) { + return _swig_wrap_PublicBase_staticOverloaded__SWIG_1(arg1.Swigcptr(), arg2) +} + +func PublicBaseStaticOverloaded(a ...interface{}) Klass { + argc := len(a) + if argc == 1 { + return PublicBaseStaticOverloaded__SWIG_0(a[0].(Klass)) + } + if argc == 2 { + return PublicBaseStaticOverloaded__SWIG_1(a[0].(Klass), a[1].(string)) + } + panic("No match for overloaded function call") +} + +var _wrap_PublicBase_instanceMemberVariable_set unsafe.Pointer + +func _swig_wrap_PublicBase_instanceMemberVariable_set(base SwigcptrPublicBase, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_PublicBase_instanceMemberVariable_set, _swig_p) + return +} + +func (arg1 SwigcptrPublicBase) SetInstanceMemberVariable(arg2 int) { + _swig_wrap_PublicBase_instanceMemberVariable_set(arg1, arg2) +} + +var _wrap_PublicBase_instanceMemberVariable_get unsafe.Pointer + +func _swig_wrap_PublicBase_instanceMemberVariable_get(base SwigcptrPublicBase) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_PublicBase_instanceMemberVariable_get, _swig_p) + return +} + +func (arg1 SwigcptrPublicBase) GetInstanceMemberVariable() (_swig_ret int) { + return _swig_wrap_PublicBase_instanceMemberVariable_get(arg1) +} + +var _wrap_PublicBase_staticMemberVariable_set unsafe.Pointer + +func _swig_wrap_PublicBase_staticMemberVariable_set(base int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_PublicBase_staticMemberVariable_set, _swig_p) + return +} + +func SetPublicBaseStaticMemberVariable(arg1 int) { + _swig_wrap_PublicBase_staticMemberVariable_set(arg1) +} + +var _wrap_PublicBase_staticMemberVariable_get unsafe.Pointer + +func GetPublicBaseStaticMemberVariable() (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_PublicBase_staticMemberVariable_get, _swig_p) + return +} +var _wrap_PublicBase_staticConstMemberVariable_PublicBase unsafe.Pointer + +func _swig_getPublicBase_PublicBase_staticConstMemberVariable_PublicBase() (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_PublicBase_staticConstMemberVariable_PublicBase, _swig_p) + return +} +var PublicBaseStaticConstMemberVariable int = _swig_getPublicBase_PublicBase_staticConstMemberVariable_PublicBase() +var _wrap_PublicBase_anEnum_set unsafe.Pointer + +func _swig_wrap_PublicBase_anEnum_set(base SwigcptrPublicBase, _ PublicBaseAnEnum) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_PublicBase_anEnum_set, _swig_p) + return +} + +func (arg1 SwigcptrPublicBase) SetAnEnum(arg2 PublicBaseAnEnum) { + _swig_wrap_PublicBase_anEnum_set(arg1, arg2) +} + +var _wrap_PublicBase_anEnum_get unsafe.Pointer + +func _swig_wrap_PublicBase_anEnum_get(base SwigcptrPublicBase) (_ PublicBaseAnEnum) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_PublicBase_anEnum_get, _swig_p) + return +} + +func (arg1 SwigcptrPublicBase) GetAnEnum() (_swig_ret PublicBaseAnEnum) { + return _swig_wrap_PublicBase_anEnum_get(arg1) +} + +var _wrap_PublicBase_stringMember_set unsafe.Pointer + +func _swig_wrap_PublicBase_stringMember_set(base SwigcptrPublicBase, _ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_PublicBase_stringMember_set, _swig_p) + return +} + +func (arg1 SwigcptrPublicBase) SetStringMember(arg2 string) { + _swig_wrap_PublicBase_stringMember_set(arg1, arg2) +} + +var _wrap_PublicBase_stringMember_get unsafe.Pointer + +func _swig_wrap_PublicBase_stringMember_get(base SwigcptrPublicBase) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_PublicBase_stringMember_get, _swig_p) + return +} + +func (arg1 SwigcptrPublicBase) GetStringMember() (_swig_ret string) { + return _swig_wrap_PublicBase_stringMember_get(arg1) +} + +type PublicBase interface { + Swigcptr() uintptr + SwigIsPublicBase() + DirectorInterface() interface{} + VirtualMethod() (_swig_ret string) + InstanceMethod(arg2 Klass) (_swig_ret Klass) + InstanceOverloaded(a ...interface{}) Klass + SetInstanceMemberVariable(arg2 int) + GetInstanceMemberVariable() (_swig_ret int) + SetAnEnum(arg2 PublicBaseAnEnum) + GetAnEnum() (_swig_ret PublicBaseAnEnum) + SetStringMember(arg2 string) + GetStringMember() (_swig_ret string) +} + +type _swig_DirectorProtectedBase struct { + SwigcptrProtectedBase + v interface{} +} + +func (p *_swig_DirectorProtectedBase) Swigcptr() uintptr { + return p.SwigcptrProtectedBase.Swigcptr() +} + +func (p *_swig_DirectorProtectedBase) SwigIsProtectedBase() { +} + +func (p *_swig_DirectorProtectedBase) DirectorInterface() interface{} { + return p.v +} + +var _wrap__swig_NewDirectorProtectedBaseProtectedBase unsafe.Pointer + +func _swig_NewDirectorProtectedBaseProtectedBase(_swig_director *_swig_DirectorProtectedBase, _ string) (_swig_ret SwigcptrProtectedBase) { + _swig_p := uintptr(unsafe.Pointer(&_swig_director)) + _cgo_runtime_cgocall(_wrap__swig_NewDirectorProtectedBaseProtectedBase, _swig_p) + return +} + +func NewDirectorProtectedBase(v interface{}, arg1 string) ProtectedBase { + p := &_swig_DirectorProtectedBase{0, v} + p.SwigcptrProtectedBase = _swig_NewDirectorProtectedBaseProtectedBase(p, arg1) + return p +} + +type _swig_DirectorInterfaceProtectedBaseVirtualMethod interface { + VirtualMethod() string +} + +var _wrap__swig_DirectorProtectedBase_upcall_VirtualMethod unsafe.Pointer + +func _swig_wrap__swig_DirectorProtectedBase_upcall_VirtualMethod(_swig_ptr SwigcptrProtectedBase) (_swig_ret string) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) + _cgo_runtime_cgocall(_wrap__swig_DirectorProtectedBase_upcall_VirtualMethod, _swig_p) + return +} + +func (swig_p *_swig_DirectorProtectedBase) VirtualMethod() string { + if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceProtectedBaseVirtualMethod); swig_ok { + return swig_g.VirtualMethod() + } + var swig_r string + swig_r = _swig_wrap__swig_DirectorProtectedBase_upcall_VirtualMethod(swig_p.SwigcptrProtectedBase) + return swig_r +} + +func DirectorProtectedBaseVirtualMethod(p ProtectedBase) string { + var swig_r string + swig_r = _swig_wrap__swig_DirectorProtectedBase_upcall_VirtualMethod(p.(*_swig_DirectorProtectedBase).SwigcptrProtectedBase) + return swig_r +} + +func Swig_DirectorProtectedBase_callback_virtualMethod(p *_swig_DirectorProtectedBase) (swig_result string) { + var swig_r string + swig_r = p.VirtualMethod() + return swig_r +} + +type SwigcptrProtectedBase uintptr + +func (p SwigcptrProtectedBase) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrProtectedBase) SwigIsProtectedBase() { +} + +func (p SwigcptrProtectedBase) DirectorInterface() interface{} { + return nil +} + +type ProtectedBaseAnEnum int +var _wrap_EnumVal1_ProtectedBase unsafe.Pointer + +func _swig_getProtectedBase_EnumVal1_ProtectedBase() (_swig_ret ProtectedBaseAnEnum) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_EnumVal1_ProtectedBase, _swig_p) + return +} +var ProtectedBaseEnumVal1 ProtectedBaseAnEnum = _swig_getProtectedBase_EnumVal1_ProtectedBase() +var _wrap_EnumVal2_ProtectedBase unsafe.Pointer + +func _swig_getProtectedBase_EnumVal2_ProtectedBase() (_swig_ret ProtectedBaseAnEnum) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_EnumVal2_ProtectedBase, _swig_p) + return +} +var ProtectedBaseEnumVal2 ProtectedBaseAnEnum = _swig_getProtectedBase_EnumVal2_ProtectedBase() +var _wrap_ProtectedBase_getName unsafe.Pointer + +func _swig_wrap_ProtectedBase_getName(base SwigcptrProtectedBase) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_ProtectedBase_getName, _swig_p) + return +} + +func (arg1 SwigcptrProtectedBase) GetName() (_swig_ret string) { + return _swig_wrap_ProtectedBase_getName(arg1) +} + +var _wrap_new_ProtectedBase unsafe.Pointer + +func _swig_wrap_new_ProtectedBase(base string) (_ SwigcptrProtectedBase) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_ProtectedBase, _swig_p) + return +} + +func NewProtectedBase(arg1 string) (_swig_ret ProtectedBase) { + return _swig_wrap_new_ProtectedBase(arg1) +} + +var _wrap_ProtectedBase_instanceMemberVariable_set unsafe.Pointer + +func _swig_wrap_ProtectedBase_instanceMemberVariable_set(base SwigcptrProtectedBase, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_ProtectedBase_instanceMemberVariable_set, _swig_p) + return +} + +func (arg1 SwigcptrProtectedBase) SetInstanceMemberVariable(arg2 int) { + _swig_wrap_ProtectedBase_instanceMemberVariable_set(arg1, arg2) +} + +var _wrap_ProtectedBase_instanceMemberVariable_get unsafe.Pointer + +func _swig_wrap_ProtectedBase_instanceMemberVariable_get(base SwigcptrProtectedBase) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_ProtectedBase_instanceMemberVariable_get, _swig_p) + return +} + +func (arg1 SwigcptrProtectedBase) GetInstanceMemberVariable() (_swig_ret int) { + return _swig_wrap_ProtectedBase_instanceMemberVariable_get(arg1) +} + +var _wrap_ProtectedBase_staticMemberVariable_set unsafe.Pointer + +func _swig_wrap_ProtectedBase_staticMemberVariable_set(base int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_ProtectedBase_staticMemberVariable_set, _swig_p) + return +} + +func SetProtectedBaseStaticMemberVariable(arg1 int) { + _swig_wrap_ProtectedBase_staticMemberVariable_set(arg1) +} + +var _wrap_ProtectedBase_staticMemberVariable_get unsafe.Pointer + +func GetProtectedBaseStaticMemberVariable() (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_ProtectedBase_staticMemberVariable_get, _swig_p) + return +} +var _wrap_ProtectedBase_staticConstMemberVariable_ProtectedBase unsafe.Pointer + +func _swig_getProtectedBase_ProtectedBase_staticConstMemberVariable_ProtectedBase() (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_ProtectedBase_staticConstMemberVariable_ProtectedBase, _swig_p) + return +} +var ProtectedBaseStaticConstMemberVariable int = _swig_getProtectedBase_ProtectedBase_staticConstMemberVariable_ProtectedBase() +var _wrap_ProtectedBase_anEnum_set unsafe.Pointer + +func _swig_wrap_ProtectedBase_anEnum_set(base SwigcptrProtectedBase, _ ProtectedBaseAnEnum) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_ProtectedBase_anEnum_set, _swig_p) + return +} + +func (arg1 SwigcptrProtectedBase) SetAnEnum(arg2 ProtectedBaseAnEnum) { + _swig_wrap_ProtectedBase_anEnum_set(arg1, arg2) +} + +var _wrap_ProtectedBase_anEnum_get unsafe.Pointer + +func _swig_wrap_ProtectedBase_anEnum_get(base SwigcptrProtectedBase) (_ ProtectedBaseAnEnum) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_ProtectedBase_anEnum_get, _swig_p) + return +} + +func (arg1 SwigcptrProtectedBase) GetAnEnum() (_swig_ret ProtectedBaseAnEnum) { + return _swig_wrap_ProtectedBase_anEnum_get(arg1) +} + +var _wrap_ProtectedBase_stringMember_set unsafe.Pointer + +func _swig_wrap_ProtectedBase_stringMember_set(base SwigcptrProtectedBase, _ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_ProtectedBase_stringMember_set, _swig_p) + return +} + +func (arg1 SwigcptrProtectedBase) SetStringMember(arg2 string) { + _swig_wrap_ProtectedBase_stringMember_set(arg1, arg2) +} + +var _wrap_ProtectedBase_stringMember_get unsafe.Pointer + +func _swig_wrap_ProtectedBase_stringMember_get(base SwigcptrProtectedBase) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_ProtectedBase_stringMember_get, _swig_p) + return +} + +func (arg1 SwigcptrProtectedBase) GetStringMember() (_swig_ret string) { + return _swig_wrap_ProtectedBase_stringMember_get(arg1) +} + +type ProtectedBaseProtectedEnum int +type ProtectedBase interface { + Swigcptr() uintptr + SwigIsProtectedBase() + DirectorInterface() interface{} + GetName() (_swig_ret string) +} + + +type SwigcptrSwigDirector_ProtectedBase uintptr +type SwigDirector_ProtectedBase interface { + Swigcptr() uintptr; +} +func (p SwigcptrSwigDirector_ProtectedBase) Swigcptr() uintptr { + return uintptr(p) +} + +type SwigcptrSwigDirector_PublicBase uintptr +type SwigDirector_PublicBase interface { + Swigcptr() uintptr; +} +func (p SwigcptrSwigDirector_PublicBase) Swigcptr() uintptr { + return uintptr(p) +} + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/allprotected_not.go b/Examples/test-suite/go/allprotected_not.go new file mode 100644 index 000000000..f393222ba --- /dev/null +++ b/Examples/test-suite/go/allprotected_not.go @@ -0,0 +1,88 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../allprotected_not.i + +package allprotected_not + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrAllProtectedNot uintptr + +func (p SwigcptrAllProtectedNot) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrAllProtectedNot) SwigIsAllProtectedNot() { +} + +var _wrap_delete_AllProtectedNot unsafe.Pointer + +func _swig_wrap_delete_AllProtectedNot(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_AllProtectedNot, _swig_p) + return +} + +func DeleteAllProtectedNot(arg1 AllProtectedNot) { + _swig_wrap_delete_AllProtectedNot(arg1.Swigcptr()) +} + +var _wrap_AllProtectedNot_PublicMethod unsafe.Pointer + +func _swig_wrap_AllProtectedNot_PublicMethod(base SwigcptrAllProtectedNot) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_AllProtectedNot_PublicMethod, _swig_p) + return +} + +func (arg1 SwigcptrAllProtectedNot) PublicMethod() { + _swig_wrap_AllProtectedNot_PublicMethod(arg1) +} + +var _wrap_new_AllProtectedNot unsafe.Pointer + +func _swig_wrap_new_AllProtectedNot() (base SwigcptrAllProtectedNot) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_AllProtectedNot, _swig_p) + return +} + +func NewAllProtectedNot() (_swig_ret AllProtectedNot) { + return _swig_wrap_new_AllProtectedNot() +} + +type AllProtectedNot interface { + Swigcptr() uintptr + SwigIsAllProtectedNot() + PublicMethod() +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/allprotected_not_wrap.h b/Examples/test-suite/go/allprotected_not_wrap.h new file mode 100644 index 000000000..940424b89 --- /dev/null +++ b/Examples/test-suite/go/allprotected_not_wrap.h @@ -0,0 +1,16 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../allprotected_not.i + +#ifndef SWIG_allprotected_not_WRAP_H_ +#define SWIG_allprotected_not_WRAP_H_ + +#endif diff --git a/Examples/test-suite/go/allprotected_wrap.h b/Examples/test-suite/go/allprotected_wrap.h new file mode 100644 index 000000000..6a7fd8caf --- /dev/null +++ b/Examples/test-suite/go/allprotected_wrap.h @@ -0,0 +1,51 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../allprotected.i + +#ifndef SWIG_allprotected_WRAP_H_ +#define SWIG_allprotected_WRAP_H_ + +class SwigDirector_PublicBase : public PublicBase +{ + public: + SwigDirector_PublicBase(void *swig_p, char const *s); + virtual ~SwigDirector_PublicBase(); + std::string _swig_upcall_virtualMethod() const { + return PublicBase::virtualMethod(); + } + virtual std::string virtualMethod() const; + private: + void *go_val; +}; + +class SwigDirector_ProtectedBase : public ProtectedBase +{ + public: + SwigDirector_ProtectedBase(void *swig_p, char const *s); + std::string _swig_upcall_virtualMethod() const { + return ProtectedBase::virtualMethod(); + } + virtual std::string virtualMethod() const; + using ProtectedBase::instanceMethod; + using ProtectedBase::instanceOverloaded; + using ProtectedBase::staticMethod; + using ProtectedBase::staticOverloaded; + using ProtectedBase::instanceMemberVariable; + using ProtectedBase::staticMemberVariable; + using ProtectedBase::staticConstMemberVariable; + using ProtectedBase::anEnum; + using ProtectedBase::stringMember; + using ProtectedBase::IntegerType; + private: + void *go_val; +}; + +#endif diff --git a/Examples/test-suite/go/anonymous_bitfield.go b/Examples/test-suite/go/anonymous_bitfield.go new file mode 100644 index 000000000..6dd8c7fd3 --- /dev/null +++ b/Examples/test-suite/go/anonymous_bitfield.go @@ -0,0 +1,205 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../anonymous_bitfield.i + +package anonymous_bitfield + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrFoo uintptr + +func (p SwigcptrFoo) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrFoo) SwigIsFoo() { +} + +var _wrap_Foo_x_set unsafe.Pointer + +func _swig_wrap_Foo_x_set(base SwigcptrFoo, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_x_set, _swig_p) + return +} + +func (arg1 SwigcptrFoo) SetX(arg2 int) { + _swig_wrap_Foo_x_set(arg1, arg2) +} + +var _wrap_Foo_x_get unsafe.Pointer + +func _swig_wrap_Foo_x_get(base SwigcptrFoo) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_x_get, _swig_p) + return +} + +func (arg1 SwigcptrFoo) GetX() (_swig_ret int) { + return _swig_wrap_Foo_x_get(arg1) +} + +var _wrap_Foo_y_set unsafe.Pointer + +func _swig_wrap_Foo_y_set(base SwigcptrFoo, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_y_set, _swig_p) + return +} + +func (arg1 SwigcptrFoo) SetY(arg2 int) { + _swig_wrap_Foo_y_set(arg1, arg2) +} + +var _wrap_Foo_y_get unsafe.Pointer + +func _swig_wrap_Foo_y_get(base SwigcptrFoo) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_y_get, _swig_p) + return +} + +func (arg1 SwigcptrFoo) GetY() (_swig_ret int) { + return _swig_wrap_Foo_y_get(arg1) +} + +var _wrap_Foo_f_set unsafe.Pointer + +func _swig_wrap_Foo_f_set(base SwigcptrFoo, _ uint) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_f_set, _swig_p) + return +} + +func (arg1 SwigcptrFoo) SetF(arg2 uint) { + _swig_wrap_Foo_f_set(arg1, arg2) +} + +var _wrap_Foo_f_get unsafe.Pointer + +func _swig_wrap_Foo_f_get(base SwigcptrFoo) (_ uint) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_f_get, _swig_p) + return +} + +func (arg1 SwigcptrFoo) GetF() (_swig_ret uint) { + return _swig_wrap_Foo_f_get(arg1) +} + +var _wrap_Foo_z_set unsafe.Pointer + +func _swig_wrap_Foo_z_set(base SwigcptrFoo, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_z_set, _swig_p) + return +} + +func (arg1 SwigcptrFoo) SetZ(arg2 int) { + _swig_wrap_Foo_z_set(arg1, arg2) +} + +var _wrap_Foo_z_get unsafe.Pointer + +func _swig_wrap_Foo_z_get(base SwigcptrFoo) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_z_get, _swig_p) + return +} + +func (arg1 SwigcptrFoo) GetZ() (_swig_ret int) { + return _swig_wrap_Foo_z_get(arg1) +} + +var _wrap_Foo_seq_set unsafe.Pointer + +func _swig_wrap_Foo_seq_set(base SwigcptrFoo, _ uint) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_seq_set, _swig_p) + return +} + +func (arg1 SwigcptrFoo) SetSeq(arg2 uint) { + _swig_wrap_Foo_seq_set(arg1, arg2) +} + +var _wrap_Foo_seq_get unsafe.Pointer + +func _swig_wrap_Foo_seq_get(base SwigcptrFoo) (_ uint) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_seq_get, _swig_p) + return +} + +func (arg1 SwigcptrFoo) GetSeq() (_swig_ret uint) { + return _swig_wrap_Foo_seq_get(arg1) +} + +var _wrap_new_Foo unsafe.Pointer + +func _swig_wrap_new_Foo() (base SwigcptrFoo) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Foo, _swig_p) + return +} + +func NewFoo() (_swig_ret Foo) { + return _swig_wrap_new_Foo() +} + +var _wrap_delete_Foo unsafe.Pointer + +func _swig_wrap_delete_Foo(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Foo, _swig_p) + return +} + +func DeleteFoo(arg1 Foo) { + _swig_wrap_delete_Foo(arg1.Swigcptr()) +} + +type Foo interface { + Swigcptr() uintptr + SwigIsFoo() + SetX(arg2 int) + GetX() (_swig_ret int) + SetY(arg2 int) + GetY() (_swig_ret int) + SetF(arg2 uint) + GetF() (_swig_ret uint) + SetZ(arg2 int) + GetZ() (_swig_ret int) + SetSeq(arg2 uint) + GetSeq() (_swig_ret uint) +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/apply_signed_char.go b/Examples/test-suite/go/apply_signed_char.go new file mode 100644 index 000000000..9d95e07fe --- /dev/null +++ b/Examples/test-suite/go/apply_signed_char.go @@ -0,0 +1,358 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../apply_signed_char.i + +package apply_signed_char + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +var _wrap_CharValFunction unsafe.Pointer + +func CharValFunction(arg1 int8) (_swig_ret int8) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_CharValFunction, _swig_p) + return +} +var _wrap_CCharValFunction unsafe.Pointer + +func CCharValFunction(arg1 int8) (_swig_ret int8) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_CCharValFunction, _swig_p) + return +} +var _wrap_CCharRefFunction unsafe.Pointer + +func CCharRefFunction(arg1 int8) (_swig_ret int8) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_CCharRefFunction, _swig_p) + return +} +var _wrap_globalchar_set unsafe.Pointer + +func _swig_wrap_globalchar_set(base int8) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_globalchar_set, _swig_p) + return +} + +func SetGlobalchar(arg1 int8) { + _swig_wrap_globalchar_set(arg1) +} + +var _wrap_globalchar_get unsafe.Pointer + +func GetGlobalchar() (_swig_ret int8) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_globalchar_get, _swig_p) + return +} +var _wrap_globalconstchar_get unsafe.Pointer + +func GetGlobalconstchar() (_swig_ret int8) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_globalconstchar_get, _swig_p) + return +} +type _swig_DirectorDirectorTest struct { + SwigcptrDirectorTest + v interface{} +} + +func (p *_swig_DirectorDirectorTest) Swigcptr() uintptr { + return p.SwigcptrDirectorTest.Swigcptr() +} + +func (p *_swig_DirectorDirectorTest) SwigIsDirectorTest() { +} + +func (p *_swig_DirectorDirectorTest) DirectorInterface() interface{} { + return p.v +} + +var _wrap__swig_NewDirectorDirectorTestDirectorTest unsafe.Pointer + +func _swig_NewDirectorDirectorTestDirectorTest(_swig_director *_swig_DirectorDirectorTest) (_swig_ret SwigcptrDirectorTest) { + _swig_p := uintptr(unsafe.Pointer(&_swig_director)) + _cgo_runtime_cgocall(_wrap__swig_NewDirectorDirectorTestDirectorTest, _swig_p) + return +} + +func NewDirectorDirectorTest(v interface{}) DirectorTest { + p := &_swig_DirectorDirectorTest{0, v} + p.SwigcptrDirectorTest = _swig_NewDirectorDirectorTestDirectorTest(p) + return p +} + +type _swig_DirectorInterfaceDirectorTestCharValFunction interface { + CharValFunction(int8) int8 +} + +var _wrap__swig_DirectorDirectorTest_upcall_CharValFunction unsafe.Pointer + +func _swig_wrap__swig_DirectorDirectorTest_upcall_CharValFunction(_swig_ptr SwigcptrDirectorTest, _ int8) (_swig_ret int8) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) + _cgo_runtime_cgocall(_wrap__swig_DirectorDirectorTest_upcall_CharValFunction, _swig_p) + return +} + +func (swig_p *_swig_DirectorDirectorTest) CharValFunction(number int8) int8 { + if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceDirectorTestCharValFunction); swig_ok { + return swig_g.CharValFunction(number) + } + var swig_r int8 + swig_r = _swig_wrap__swig_DirectorDirectorTest_upcall_CharValFunction(swig_p.SwigcptrDirectorTest, number) + return swig_r +} + +func DirectorDirectorTestCharValFunction(p DirectorTest, arg2 int8) int8 { + var swig_r int8 + swig_r = _swig_wrap__swig_DirectorDirectorTest_upcall_CharValFunction(p.(*_swig_DirectorDirectorTest).SwigcptrDirectorTest, arg2) + return swig_r +} + +func Swig_DirectorDirectorTest_callback_CharValFunction(p *_swig_DirectorDirectorTest, arg2 int8) (swig_result int8) { + var swig_r int8 + swig_r = p.CharValFunction(arg2) + return swig_r +} + +type _swig_DirectorInterfaceDirectorTestCCharValFunction interface { + CCharValFunction(int8) int8 +} + +var _wrap__swig_DirectorDirectorTest_upcall_CCharValFunction unsafe.Pointer + +func _swig_wrap__swig_DirectorDirectorTest_upcall_CCharValFunction(_swig_ptr SwigcptrDirectorTest, _ int8) (_swig_ret int8) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) + _cgo_runtime_cgocall(_wrap__swig_DirectorDirectorTest_upcall_CCharValFunction, _swig_p) + return +} + +func (swig_p *_swig_DirectorDirectorTest) CCharValFunction(number int8) int8 { + if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceDirectorTestCCharValFunction); swig_ok { + return swig_g.CCharValFunction(number) + } + var swig_r int8 + swig_r = _swig_wrap__swig_DirectorDirectorTest_upcall_CCharValFunction(swig_p.SwigcptrDirectorTest, number) + return swig_r +} + +func DirectorDirectorTestCCharValFunction(p DirectorTest, arg2 int8) int8 { + var swig_r int8 + swig_r = _swig_wrap__swig_DirectorDirectorTest_upcall_CCharValFunction(p.(*_swig_DirectorDirectorTest).SwigcptrDirectorTest, arg2) + return swig_r +} + +func Swig_DirectorDirectorTest_callback_CCharValFunction(p *_swig_DirectorDirectorTest, arg2 int8) (swig_result int8) { + var swig_r int8 + swig_r = p.CCharValFunction(arg2) + return swig_r +} + +type _swig_DirectorInterfaceDirectorTestCCharRefFunction interface { + CCharRefFunction(int8) int8 +} + +var _wrap__swig_DirectorDirectorTest_upcall_CCharRefFunction unsafe.Pointer + +func _swig_wrap__swig_DirectorDirectorTest_upcall_CCharRefFunction(_swig_ptr SwigcptrDirectorTest, _ int8) (_swig_ret int8) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) + _cgo_runtime_cgocall(_wrap__swig_DirectorDirectorTest_upcall_CCharRefFunction, _swig_p) + return +} + +func (swig_p *_swig_DirectorDirectorTest) CCharRefFunction(number int8) int8 { + if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceDirectorTestCCharRefFunction); swig_ok { + return swig_g.CCharRefFunction(number) + } + var swig_r int8 + swig_r = _swig_wrap__swig_DirectorDirectorTest_upcall_CCharRefFunction(swig_p.SwigcptrDirectorTest, number) + return swig_r +} + +func DirectorDirectorTestCCharRefFunction(p DirectorTest, arg2 int8) int8 { + var swig_r int8 + swig_r = _swig_wrap__swig_DirectorDirectorTest_upcall_CCharRefFunction(p.(*_swig_DirectorDirectorTest).SwigcptrDirectorTest, arg2) + return swig_r +} + +func Swig_DirectorDirectorTest_callback_CCharRefFunction(p *_swig_DirectorDirectorTest, arg2 int8) (swig_result int8) { + var swig_r int8 + swig_r = p.CCharRefFunction(arg2) + return swig_r +} + +var _wrap_DeleteDirectorDirectorTest unsafe.Pointer + +func _swig_wrap_DeleteDirectorDirectorTest(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_DeleteDirectorDirectorTest, _swig_p) + return +} + +func DeleteDirectorDirectorTest(arg1 DirectorTest) { + _swig_wrap_DeleteDirectorDirectorTest(arg1.Swigcptr()) +} + +func Swiggo_DeleteDirector_DirectorTest(p *_swig_DirectorDirectorTest) { + p.SwigcptrDirectorTest = 0 +} + +type SwigcptrDirectorTest uintptr + +func (p SwigcptrDirectorTest) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrDirectorTest) SwigIsDirectorTest() { +} + +func (p SwigcptrDirectorTest) DirectorInterface() interface{} { + return nil +} + +var _wrap_new_DirectorTest unsafe.Pointer + +func _swig_wrap_new_DirectorTest() (base SwigcptrDirectorTest) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_DirectorTest, _swig_p) + return +} + +func NewDirectorTest() (_swig_ret DirectorTest) { + return _swig_wrap_new_DirectorTest() +} + +var _wrap_DirectorTest_CharValFunction unsafe.Pointer + +func _swig_wrap_DirectorTest_CharValFunction(base SwigcptrDirectorTest, _ int8) (_ int8) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_DirectorTest_CharValFunction, _swig_p) + return +} + +func (arg1 SwigcptrDirectorTest) CharValFunction(arg2 int8) (_swig_ret int8) { + return _swig_wrap_DirectorTest_CharValFunction(arg1, arg2) +} + +var _wrap_DirectorTest_CCharValFunction unsafe.Pointer + +func _swig_wrap_DirectorTest_CCharValFunction(base SwigcptrDirectorTest, _ int8) (_ int8) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_DirectorTest_CCharValFunction, _swig_p) + return +} + +func (arg1 SwigcptrDirectorTest) CCharValFunction(arg2 int8) (_swig_ret int8) { + return _swig_wrap_DirectorTest_CCharValFunction(arg1, arg2) +} + +var _wrap_DirectorTest_CCharRefFunction unsafe.Pointer + +func _swig_wrap_DirectorTest_CCharRefFunction(base SwigcptrDirectorTest, _ int8) (_ int8) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_DirectorTest_CCharRefFunction, _swig_p) + return +} + +func (arg1 SwigcptrDirectorTest) CCharRefFunction(arg2 int8) (_swig_ret int8) { + return _swig_wrap_DirectorTest_CCharRefFunction(arg1, arg2) +} + +var _wrap_DirectorTest_memberchar_set unsafe.Pointer + +func _swig_wrap_DirectorTest_memberchar_set(base SwigcptrDirectorTest, _ int8) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_DirectorTest_memberchar_set, _swig_p) + return +} + +func (arg1 SwigcptrDirectorTest) SetMemberchar(arg2 int8) { + _swig_wrap_DirectorTest_memberchar_set(arg1, arg2) +} + +var _wrap_DirectorTest_memberchar_get unsafe.Pointer + +func _swig_wrap_DirectorTest_memberchar_get(base SwigcptrDirectorTest) (_ int8) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_DirectorTest_memberchar_get, _swig_p) + return +} + +func (arg1 SwigcptrDirectorTest) GetMemberchar() (_swig_ret int8) { + return _swig_wrap_DirectorTest_memberchar_get(arg1) +} + +var _wrap_DirectorTest_memberconstchar_get unsafe.Pointer + +func _swig_wrap_DirectorTest_memberconstchar_get(base SwigcptrDirectorTest) (_ int8) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_DirectorTest_memberconstchar_get, _swig_p) + return +} + +func (arg1 SwigcptrDirectorTest) GetMemberconstchar() (_swig_ret int8) { + return _swig_wrap_DirectorTest_memberconstchar_get(arg1) +} + +var _wrap_delete_DirectorTest unsafe.Pointer + +func _swig_wrap_delete_DirectorTest(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_DirectorTest, _swig_p) + return +} + +func DeleteDirectorTest(arg1 DirectorTest) { + _swig_wrap_delete_DirectorTest(arg1.Swigcptr()) +} + +type DirectorTest interface { + Swigcptr() uintptr + SwigIsDirectorTest() + DirectorInterface() interface{} + CharValFunction(arg2 int8) (_swig_ret int8) + CCharValFunction(arg2 int8) (_swig_ret int8) + CCharRefFunction(arg2 int8) (_swig_ret int8) + SetMemberchar(arg2 int8) + GetMemberchar() (_swig_ret int8) + GetMemberconstchar() (_swig_ret int8) +} + + +type SwigcptrSwigDirector_DirectorTest uintptr +type SwigDirector_DirectorTest interface { + Swigcptr() uintptr; +} +func (p SwigcptrSwigDirector_DirectorTest) Swigcptr() uintptr { + return uintptr(p) +} + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/apply_signed_char_wrap.h b/Examples/test-suite/go/apply_signed_char_wrap.h new file mode 100644 index 000000000..65a2e09e7 --- /dev/null +++ b/Examples/test-suite/go/apply_signed_char_wrap.h @@ -0,0 +1,37 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../apply_signed_char.i + +#ifndef SWIG_apply_signed_char_WRAP_H_ +#define SWIG_apply_signed_char_WRAP_H_ + +class SwigDirector_DirectorTest : public DirectorTest +{ + public: + SwigDirector_DirectorTest(void *swig_p); + char _swig_upcall_CharValFunction(char number) { + return DirectorTest::CharValFunction(number); + } + virtual char CharValFunction(char number); + char const _swig_upcall_CCharValFunction(char const number) { + return DirectorTest::CCharValFunction(number); + } + virtual char const CCharValFunction(char const number); + char const &_swig_upcall_CCharRefFunction(char const &number) { + return DirectorTest::CCharRefFunction(number); + } + virtual char const &CCharRefFunction(char const &number); + virtual ~SwigDirector_DirectorTest(); + private: + void *go_val; +}; + +#endif diff --git a/Examples/test-suite/go/apply_strings.go b/Examples/test-suite/go/apply_strings.go new file mode 100644 index 000000000..009e191b9 --- /dev/null +++ b/Examples/test-suite/go/apply_strings.go @@ -0,0 +1,587 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../apply_strings.i + +package apply_strings + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +var _wrap_UCharFunction unsafe.Pointer + +func UCharFunction(arg1 string) (_swig_ret string) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_UCharFunction, _swig_p) + return +} +var _wrap_SCharFunction unsafe.Pointer + +func SCharFunction(arg1 string) (_swig_ret string) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_SCharFunction, _swig_p) + return +} +var _wrap_CUCharFunction unsafe.Pointer + +func CUCharFunction(arg1 string) (_swig_ret string) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_CUCharFunction, _swig_p) + return +} +var _wrap_CSCharFunction unsafe.Pointer + +func CSCharFunction(arg1 string) (_swig_ret string) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_CSCharFunction, _swig_p) + return +} +var _wrap_CharFunction unsafe.Pointer + +func CharFunction(arg1 *byte) (_swig_ret *byte) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_CharFunction, _swig_p) + return +} +var _wrap_CCharFunction unsafe.Pointer + +func CCharFunction(arg1 *byte) (_swig_ret *byte) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_CCharFunction, _swig_p) + return +} +type SwigcptrTNumber uintptr + +func (p SwigcptrTNumber) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrTNumber) SwigIsTNumber() { +} + +var _wrap_TNumber_DigitsMemberA_set unsafe.Pointer + +func _swig_wrap_TNumber_DigitsMemberA_set(base SwigcptrTNumber, _ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_TNumber_DigitsMemberA_set, _swig_p) + return +} + +func (arg1 SwigcptrTNumber) SetDigitsMemberA(arg2 string) { + _swig_wrap_TNumber_DigitsMemberA_set(arg1, arg2) +} + +var _wrap_TNumber_DigitsMemberA_get unsafe.Pointer + +func _swig_wrap_TNumber_DigitsMemberA_get(base SwigcptrTNumber) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_TNumber_DigitsMemberA_get, _swig_p) + return +} + +func (arg1 SwigcptrTNumber) GetDigitsMemberA() (_swig_ret string) { + return _swig_wrap_TNumber_DigitsMemberA_get(arg1) +} + +var _wrap_TNumber_DigitsMemberB_set unsafe.Pointer + +func _swig_wrap_TNumber_DigitsMemberB_set(base SwigcptrTNumber, _ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_TNumber_DigitsMemberB_set, _swig_p) + return +} + +func (arg1 SwigcptrTNumber) SetDigitsMemberB(arg2 string) { + _swig_wrap_TNumber_DigitsMemberB_set(arg1, arg2) +} + +var _wrap_TNumber_DigitsMemberB_get unsafe.Pointer + +func _swig_wrap_TNumber_DigitsMemberB_get(base SwigcptrTNumber) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_TNumber_DigitsMemberB_get, _swig_p) + return +} + +func (arg1 SwigcptrTNumber) GetDigitsMemberB() (_swig_ret string) { + return _swig_wrap_TNumber_DigitsMemberB_get(arg1) +} + +var _wrap_new_TNumber unsafe.Pointer + +func _swig_wrap_new_TNumber() (base SwigcptrTNumber) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_TNumber, _swig_p) + return +} + +func NewTNumber() (_swig_ret TNumber) { + return _swig_wrap_new_TNumber() +} + +var _wrap_delete_TNumber unsafe.Pointer + +func _swig_wrap_delete_TNumber(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_TNumber, _swig_p) + return +} + +func DeleteTNumber(arg1 TNumber) { + _swig_wrap_delete_TNumber(arg1.Swigcptr()) +} + +type TNumber interface { + Swigcptr() uintptr + SwigIsTNumber() + SetDigitsMemberA(arg2 string) + GetDigitsMemberA() (_swig_ret string) + SetDigitsMemberB(arg2 string) + GetDigitsMemberB() (_swig_ret string) +} + +var _wrap_DigitsGlobalA_set unsafe.Pointer + +func _swig_wrap_DigitsGlobalA_set(base string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_DigitsGlobalA_set, _swig_p) + return +} + +func SetDigitsGlobalA(arg1 string) { + _swig_wrap_DigitsGlobalA_set(arg1) +} + +var _wrap_DigitsGlobalA_get unsafe.Pointer + +func GetDigitsGlobalA() (_swig_ret string) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_DigitsGlobalA_get, _swig_p) + return +} +var _wrap_DigitsGlobalB_get unsafe.Pointer + +func GetDigitsGlobalB() (_swig_ret string) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_DigitsGlobalB_get, _swig_p) + return +} +var _wrap_DigitsGlobalC_set unsafe.Pointer + +func _swig_wrap_DigitsGlobalC_set(base string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_DigitsGlobalC_set, _swig_p) + return +} + +func SetDigitsGlobalC(arg1 string) { + _swig_wrap_DigitsGlobalC_set(arg1) +} + +var _wrap_DigitsGlobalC_get unsafe.Pointer + +func GetDigitsGlobalC() (_swig_ret string) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_DigitsGlobalC_get, _swig_p) + return +} +type _swig_DirectorDirectorTest struct { + SwigcptrDirectorTest + v interface{} +} + +func (p *_swig_DirectorDirectorTest) Swigcptr() uintptr { + return p.SwigcptrDirectorTest.Swigcptr() +} + +func (p *_swig_DirectorDirectorTest) SwigIsDirectorTest() { +} + +func (p *_swig_DirectorDirectorTest) DirectorInterface() interface{} { + return p.v +} + +var _wrap__swig_NewDirectorDirectorTestDirectorTest unsafe.Pointer + +func _swig_NewDirectorDirectorTestDirectorTest(_swig_director *_swig_DirectorDirectorTest) (_swig_ret SwigcptrDirectorTest) { + _swig_p := uintptr(unsafe.Pointer(&_swig_director)) + _cgo_runtime_cgocall(_wrap__swig_NewDirectorDirectorTestDirectorTest, _swig_p) + return +} + +func NewDirectorDirectorTest(v interface{}) DirectorTest { + p := &_swig_DirectorDirectorTest{0, v} + p.SwigcptrDirectorTest = _swig_NewDirectorDirectorTestDirectorTest(p) + return p +} + +type _swig_DirectorInterfaceDirectorTestUCharFunction interface { + UCharFunction(string) string +} + +var _wrap__swig_DirectorDirectorTest_upcall_UCharFunction unsafe.Pointer + +func _swig_wrap__swig_DirectorDirectorTest_upcall_UCharFunction(_swig_ptr SwigcptrDirectorTest, _ string) (_swig_ret string) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) + _cgo_runtime_cgocall(_wrap__swig_DirectorDirectorTest_upcall_UCharFunction, _swig_p) + return +} + +func (swig_p *_swig_DirectorDirectorTest) UCharFunction(str string) string { + if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceDirectorTestUCharFunction); swig_ok { + return swig_g.UCharFunction(str) + } + var swig_r string + swig_r = _swig_wrap__swig_DirectorDirectorTest_upcall_UCharFunction(swig_p.SwigcptrDirectorTest, str) + return swig_r +} + +func DirectorDirectorTestUCharFunction(p DirectorTest, arg2 string) string { + var swig_r string + swig_r = _swig_wrap__swig_DirectorDirectorTest_upcall_UCharFunction(p.(*_swig_DirectorDirectorTest).SwigcptrDirectorTest, arg2) + return swig_r +} + +func Swig_DirectorDirectorTest_callback_UCharFunction(p *_swig_DirectorDirectorTest, arg2 string) (swig_result string) { + var swig_r string + swig_r = p.UCharFunction(arg2) + return swig_r +} + +type _swig_DirectorInterfaceDirectorTestSCharFunction interface { + SCharFunction(string) string +} + +var _wrap__swig_DirectorDirectorTest_upcall_SCharFunction unsafe.Pointer + +func _swig_wrap__swig_DirectorDirectorTest_upcall_SCharFunction(_swig_ptr SwigcptrDirectorTest, _ string) (_swig_ret string) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) + _cgo_runtime_cgocall(_wrap__swig_DirectorDirectorTest_upcall_SCharFunction, _swig_p) + return +} + +func (swig_p *_swig_DirectorDirectorTest) SCharFunction(str string) string { + if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceDirectorTestSCharFunction); swig_ok { + return swig_g.SCharFunction(str) + } + var swig_r string + swig_r = _swig_wrap__swig_DirectorDirectorTest_upcall_SCharFunction(swig_p.SwigcptrDirectorTest, str) + return swig_r +} + +func DirectorDirectorTestSCharFunction(p DirectorTest, arg2 string) string { + var swig_r string + swig_r = _swig_wrap__swig_DirectorDirectorTest_upcall_SCharFunction(p.(*_swig_DirectorDirectorTest).SwigcptrDirectorTest, arg2) + return swig_r +} + +func Swig_DirectorDirectorTest_callback_SCharFunction(p *_swig_DirectorDirectorTest, arg2 string) (swig_result string) { + var swig_r string + swig_r = p.SCharFunction(arg2) + return swig_r +} + +type _swig_DirectorInterfaceDirectorTestCUCharFunction interface { + CUCharFunction(string) string +} + +var _wrap__swig_DirectorDirectorTest_upcall_CUCharFunction unsafe.Pointer + +func _swig_wrap__swig_DirectorDirectorTest_upcall_CUCharFunction(_swig_ptr SwigcptrDirectorTest, _ string) (_swig_ret string) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) + _cgo_runtime_cgocall(_wrap__swig_DirectorDirectorTest_upcall_CUCharFunction, _swig_p) + return +} + +func (swig_p *_swig_DirectorDirectorTest) CUCharFunction(str string) string { + if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceDirectorTestCUCharFunction); swig_ok { + return swig_g.CUCharFunction(str) + } + var swig_r string + swig_r = _swig_wrap__swig_DirectorDirectorTest_upcall_CUCharFunction(swig_p.SwigcptrDirectorTest, str) + return swig_r +} + +func DirectorDirectorTestCUCharFunction(p DirectorTest, arg2 string) string { + var swig_r string + swig_r = _swig_wrap__swig_DirectorDirectorTest_upcall_CUCharFunction(p.(*_swig_DirectorDirectorTest).SwigcptrDirectorTest, arg2) + return swig_r +} + +func Swig_DirectorDirectorTest_callback_CUCharFunction(p *_swig_DirectorDirectorTest, arg2 string) (swig_result string) { + var swig_r string + swig_r = p.CUCharFunction(arg2) + return swig_r +} + +type _swig_DirectorInterfaceDirectorTestCSCharFunction interface { + CSCharFunction(string) string +} + +var _wrap__swig_DirectorDirectorTest_upcall_CSCharFunction unsafe.Pointer + +func _swig_wrap__swig_DirectorDirectorTest_upcall_CSCharFunction(_swig_ptr SwigcptrDirectorTest, _ string) (_swig_ret string) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) + _cgo_runtime_cgocall(_wrap__swig_DirectorDirectorTest_upcall_CSCharFunction, _swig_p) + return +} + +func (swig_p *_swig_DirectorDirectorTest) CSCharFunction(str string) string { + if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceDirectorTestCSCharFunction); swig_ok { + return swig_g.CSCharFunction(str) + } + var swig_r string + swig_r = _swig_wrap__swig_DirectorDirectorTest_upcall_CSCharFunction(swig_p.SwigcptrDirectorTest, str) + return swig_r +} + +func DirectorDirectorTestCSCharFunction(p DirectorTest, arg2 string) string { + var swig_r string + swig_r = _swig_wrap__swig_DirectorDirectorTest_upcall_CSCharFunction(p.(*_swig_DirectorDirectorTest).SwigcptrDirectorTest, arg2) + return swig_r +} + +func Swig_DirectorDirectorTest_callback_CSCharFunction(p *_swig_DirectorDirectorTest, arg2 string) (swig_result string) { + var swig_r string + swig_r = p.CSCharFunction(arg2) + return swig_r +} + +type _swig_DirectorInterfaceDirectorTestCharFunction interface { + CharFunction(*byte) *byte +} + +var _wrap__swig_DirectorDirectorTest_upcall_CharFunction unsafe.Pointer + +func _swig_wrap__swig_DirectorDirectorTest_upcall_CharFunction(_swig_ptr SwigcptrDirectorTest, _ *byte) (_swig_ret *byte) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) + _cgo_runtime_cgocall(_wrap__swig_DirectorDirectorTest_upcall_CharFunction, _swig_p) + return +} + +func (swig_p *_swig_DirectorDirectorTest) CharFunction(buffer *byte) *byte { + if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceDirectorTestCharFunction); swig_ok { + return swig_g.CharFunction(buffer) + } + var swig_r *byte + swig_r = _swig_wrap__swig_DirectorDirectorTest_upcall_CharFunction(swig_p.SwigcptrDirectorTest, buffer) + return swig_r +} + +func DirectorDirectorTestCharFunction(p DirectorTest, arg2 *byte) *byte { + var swig_r *byte + swig_r = _swig_wrap__swig_DirectorDirectorTest_upcall_CharFunction(p.(*_swig_DirectorDirectorTest).SwigcptrDirectorTest, arg2) + return swig_r +} + +func Swig_DirectorDirectorTest_callback_CharFunction(p *_swig_DirectorDirectorTest, arg2 *byte) (swig_result *byte) { + var swig_r *byte + swig_r = p.CharFunction(arg2) + return swig_r +} + +type _swig_DirectorInterfaceDirectorTestCCharFunction interface { + CCharFunction(*byte) *byte +} + +var _wrap__swig_DirectorDirectorTest_upcall_CCharFunction unsafe.Pointer + +func _swig_wrap__swig_DirectorDirectorTest_upcall_CCharFunction(_swig_ptr SwigcptrDirectorTest, _ *byte) (_swig_ret *byte) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) + _cgo_runtime_cgocall(_wrap__swig_DirectorDirectorTest_upcall_CCharFunction, _swig_p) + return +} + +func (swig_p *_swig_DirectorDirectorTest) CCharFunction(buffer *byte) *byte { + if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceDirectorTestCCharFunction); swig_ok { + return swig_g.CCharFunction(buffer) + } + var swig_r *byte + swig_r = _swig_wrap__swig_DirectorDirectorTest_upcall_CCharFunction(swig_p.SwigcptrDirectorTest, buffer) + return swig_r +} + +func DirectorDirectorTestCCharFunction(p DirectorTest, arg2 *byte) *byte { + var swig_r *byte + swig_r = _swig_wrap__swig_DirectorDirectorTest_upcall_CCharFunction(p.(*_swig_DirectorDirectorTest).SwigcptrDirectorTest, arg2) + return swig_r +} + +func Swig_DirectorDirectorTest_callback_CCharFunction(p *_swig_DirectorDirectorTest, arg2 *byte) (swig_result *byte) { + var swig_r *byte + swig_r = p.CCharFunction(arg2) + return swig_r +} + +var _wrap_DeleteDirectorDirectorTest unsafe.Pointer + +func _swig_wrap_DeleteDirectorDirectorTest(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_DeleteDirectorDirectorTest, _swig_p) + return +} + +func DeleteDirectorDirectorTest(arg1 DirectorTest) { + _swig_wrap_DeleteDirectorDirectorTest(arg1.Swigcptr()) +} + +func Swiggo_DeleteDirector_DirectorTest(p *_swig_DirectorDirectorTest) { + p.SwigcptrDirectorTest = 0 +} + +type SwigcptrDirectorTest uintptr + +func (p SwigcptrDirectorTest) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrDirectorTest) SwigIsDirectorTest() { +} + +func (p SwigcptrDirectorTest) DirectorInterface() interface{} { + return nil +} + +var _wrap_DirectorTest_UCharFunction unsafe.Pointer + +func _swig_wrap_DirectorTest_UCharFunction(base SwigcptrDirectorTest, _ string) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_DirectorTest_UCharFunction, _swig_p) + return +} + +func (arg1 SwigcptrDirectorTest) UCharFunction(arg2 string) (_swig_ret string) { + return _swig_wrap_DirectorTest_UCharFunction(arg1, arg2) +} + +var _wrap_DirectorTest_SCharFunction unsafe.Pointer + +func _swig_wrap_DirectorTest_SCharFunction(base SwigcptrDirectorTest, _ string) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_DirectorTest_SCharFunction, _swig_p) + return +} + +func (arg1 SwigcptrDirectorTest) SCharFunction(arg2 string) (_swig_ret string) { + return _swig_wrap_DirectorTest_SCharFunction(arg1, arg2) +} + +var _wrap_DirectorTest_CUCharFunction unsafe.Pointer + +func _swig_wrap_DirectorTest_CUCharFunction(base SwigcptrDirectorTest, _ string) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_DirectorTest_CUCharFunction, _swig_p) + return +} + +func (arg1 SwigcptrDirectorTest) CUCharFunction(arg2 string) (_swig_ret string) { + return _swig_wrap_DirectorTest_CUCharFunction(arg1, arg2) +} + +var _wrap_DirectorTest_CSCharFunction unsafe.Pointer + +func _swig_wrap_DirectorTest_CSCharFunction(base SwigcptrDirectorTest, _ string) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_DirectorTest_CSCharFunction, _swig_p) + return +} + +func (arg1 SwigcptrDirectorTest) CSCharFunction(arg2 string) (_swig_ret string) { + return _swig_wrap_DirectorTest_CSCharFunction(arg1, arg2) +} + +var _wrap_DirectorTest_CharFunction unsafe.Pointer + +func _swig_wrap_DirectorTest_CharFunction(base SwigcptrDirectorTest, _ *byte) (_ *byte) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_DirectorTest_CharFunction, _swig_p) + return +} + +func (arg1 SwigcptrDirectorTest) CharFunction(arg2 *byte) (_swig_ret *byte) { + return _swig_wrap_DirectorTest_CharFunction(arg1, arg2) +} + +var _wrap_DirectorTest_CCharFunction unsafe.Pointer + +func _swig_wrap_DirectorTest_CCharFunction(base SwigcptrDirectorTest, _ *byte) (_ *byte) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_DirectorTest_CCharFunction, _swig_p) + return +} + +func (arg1 SwigcptrDirectorTest) CCharFunction(arg2 *byte) (_swig_ret *byte) { + return _swig_wrap_DirectorTest_CCharFunction(arg1, arg2) +} + +var _wrap_delete_DirectorTest unsafe.Pointer + +func _swig_wrap_delete_DirectorTest(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_DirectorTest, _swig_p) + return +} + +func DeleteDirectorTest(arg1 DirectorTest) { + _swig_wrap_delete_DirectorTest(arg1.Swigcptr()) +} + +var _wrap_new_DirectorTest unsafe.Pointer + +func _swig_wrap_new_DirectorTest() (base SwigcptrDirectorTest) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_DirectorTest, _swig_p) + return +} + +func NewDirectorTest() (_swig_ret DirectorTest) { + return _swig_wrap_new_DirectorTest() +} + +type DirectorTest interface { + Swigcptr() uintptr + SwigIsDirectorTest() + DirectorInterface() interface{} + UCharFunction(arg2 string) (_swig_ret string) + SCharFunction(arg2 string) (_swig_ret string) + CUCharFunction(arg2 string) (_swig_ret string) + CSCharFunction(arg2 string) (_swig_ret string) + CharFunction(arg2 *byte) (_swig_ret *byte) + CCharFunction(arg2 *byte) (_swig_ret *byte) +} + + +type SwigcptrSwigDirector_DirectorTest uintptr +type SwigDirector_DirectorTest interface { + Swigcptr() uintptr; +} +func (p SwigcptrSwigDirector_DirectorTest) Swigcptr() uintptr { + return uintptr(p) +} + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/apply_strings_wrap.h b/Examples/test-suite/go/apply_strings_wrap.h new file mode 100644 index 000000000..5dfaea869 --- /dev/null +++ b/Examples/test-suite/go/apply_strings_wrap.h @@ -0,0 +1,49 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../apply_strings.i + +#ifndef SWIG_apply_strings_WRAP_H_ +#define SWIG_apply_strings_WRAP_H_ + +class SwigDirector_DirectorTest : public DirectorTest +{ + public: + SwigDirector_DirectorTest(void *swig_p); + UCharPtr _swig_upcall_UCharFunction(UCharPtr str) { + return DirectorTest::UCharFunction(str); + } + virtual UCharPtr UCharFunction(UCharPtr str); + SCharPtr _swig_upcall_SCharFunction(SCharPtr str) { + return DirectorTest::SCharFunction(str); + } + virtual SCharPtr SCharFunction(SCharPtr str); + CUCharPtr _swig_upcall_CUCharFunction(CUCharPtr str) { + return DirectorTest::CUCharFunction(str); + } + virtual CUCharPtr CUCharFunction(CUCharPtr str); + CSCharPtr _swig_upcall_CSCharFunction(CSCharPtr str) { + return DirectorTest::CSCharFunction(str); + } + virtual CSCharPtr CSCharFunction(CSCharPtr str); + CharPtr _swig_upcall_CharFunction(CharPtr buffer) { + return DirectorTest::CharFunction(buffer); + } + virtual CharPtr CharFunction(CharPtr buffer); + CCharPtr _swig_upcall_CCharFunction(CCharPtr buffer) { + return DirectorTest::CCharFunction(buffer); + } + virtual CCharPtr CCharFunction(CCharPtr buffer); + virtual ~SwigDirector_DirectorTest(); + private: + void *go_val; +}; + +#endif diff --git a/Examples/test-suite/go/argout.go b/Examples/test-suite/go/argout.go new file mode 100644 index 000000000..122cf57c4 --- /dev/null +++ b/Examples/test-suite/go/argout.go @@ -0,0 +1,122 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../argout.i + +package argout + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +var _wrap_new_intp unsafe.Pointer + +func New_intp() (_swig_ret *int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_new_intp, _swig_p) + return +} +var _wrap_copy_intp unsafe.Pointer + +func Copy_intp(arg1 int) (_swig_ret *int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_copy_intp, _swig_p) + return +} +var _wrap_delete_intp unsafe.Pointer + +func _swig_wrap_delete_intp(base *int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_intp, _swig_p) + return +} + +func Delete_intp(arg1 *int) { + _swig_wrap_delete_intp(arg1) +} + +var _wrap_intp_assign unsafe.Pointer + +func _swig_wrap_intp_assign(base *int, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_intp_assign, _swig_p) + return +} + +func Intp_assign(arg1 *int, arg2 int) { + _swig_wrap_intp_assign(arg1, arg2) +} + +var _wrap_intp_value unsafe.Pointer + +func Intp_value(arg1 *int) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_intp_value, _swig_p) + return +} +var _wrap_incp unsafe.Pointer + +func Incp(arg1 *int) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_incp, _swig_p) + return +} +var _wrap_incr unsafe.Pointer + +func Incr(arg1 *int) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_incr, _swig_p) + return +} +var _wrap_inctr unsafe.Pointer + +func Inctr(arg1 *int) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_inctr, _swig_p) + return +} +var _wrap_voidhandle unsafe.Pointer + +func _swig_wrap_voidhandle(base *uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_voidhandle, _swig_p) + return +} + +func Voidhandle(arg1 *uintptr) { + _swig_wrap_voidhandle(arg1) +} + +var _wrap_handle unsafe.Pointer + +func Handle(arg1 uintptr) (_swig_ret string) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_handle, _swig_p) + return +} + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/argout_runme b/Examples/test-suite/go/argout_runme new file mode 100755 index 000000000..fa4ac2d74 Binary files /dev/null and b/Examples/test-suite/go/argout_runme differ diff --git a/Examples/test-suite/go/array_member.go b/Examples/test-suite/go/array_member.go new file mode 100644 index 000000000..3d284e341 --- /dev/null +++ b/Examples/test-suite/go/array_member.go @@ -0,0 +1,586 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../array_member.i + +package array_member + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrFoo uintptr + +func (p SwigcptrFoo) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrFoo) SwigIsFoo() { +} + +var _wrap_Foo_text_set unsafe.Pointer + +func _swig_wrap_Foo_text_set(base SwigcptrFoo, _ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_text_set, _swig_p) + return +} + +func (arg1 SwigcptrFoo) SetText(arg2 string) { + _swig_wrap_Foo_text_set(arg1, arg2) +} + +var _wrap_Foo_text_get unsafe.Pointer + +func _swig_wrap_Foo_text_get(base SwigcptrFoo) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_text_get, _swig_p) + return +} + +func (arg1 SwigcptrFoo) GetText() (_swig_ret string) { + return _swig_wrap_Foo_text_get(arg1) +} + +var _wrap_Foo_data_set unsafe.Pointer + +func _swig_wrap_Foo_data_set(base SwigcptrFoo, _ *int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_data_set, _swig_p) + return +} + +func (arg1 SwigcptrFoo) SetData(arg2 *int) { + _swig_wrap_Foo_data_set(arg1, arg2) +} + +var _wrap_Foo_data_get unsafe.Pointer + +func _swig_wrap_Foo_data_get(base SwigcptrFoo) (_ *int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_data_get, _swig_p) + return +} + +func (arg1 SwigcptrFoo) GetData() (_swig_ret *int) { + return _swig_wrap_Foo_data_get(arg1) +} + +var _wrap_new_Foo unsafe.Pointer + +func _swig_wrap_new_Foo() (base SwigcptrFoo) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Foo, _swig_p) + return +} + +func NewFoo() (_swig_ret Foo) { + return _swig_wrap_new_Foo() +} + +var _wrap_delete_Foo unsafe.Pointer + +func _swig_wrap_delete_Foo(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Foo, _swig_p) + return +} + +func DeleteFoo(arg1 Foo) { + _swig_wrap_delete_Foo(arg1.Swigcptr()) +} + +type Foo interface { + Swigcptr() uintptr + SwigIsFoo() + SetText(arg2 string) + GetText() (_swig_ret string) + SetData(arg2 *int) + GetData() (_swig_ret *int) +} + +var _wrap_global_data_set unsafe.Pointer + +func _swig_wrap_global_data_set(base *int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_global_data_set, _swig_p) + return +} + +func SetGlobal_data(arg1 *int) { + _swig_wrap_global_data_set(arg1) +} + +var _wrap_global_data_get unsafe.Pointer + +func GetGlobal_data() (_swig_ret *int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_global_data_get, _swig_p) + return +} +var _wrap_set_value unsafe.Pointer + +func _swig_wrap_set_value(base *int, _ int, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_set_value, _swig_p) + return +} + +func Set_value(arg1 *int, arg2 int, arg3 int) { + _swig_wrap_set_value(arg1, arg2, arg3) +} + +var _wrap_get_value unsafe.Pointer + +func Get_value(arg1 *int, arg2 int) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_get_value, _swig_p) + return +} +type SwigcptrMaterial uintptr + +func (p SwigcptrMaterial) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrMaterial) SwigIsMaterial() { +} + +var _wrap_new_Material unsafe.Pointer + +func _swig_wrap_new_Material() (base SwigcptrMaterial) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Material, _swig_p) + return +} + +func NewMaterial() (_swig_ret Material) { + return _swig_wrap_new_Material() +} + +var _wrap_delete_Material unsafe.Pointer + +func _swig_wrap_delete_Material(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Material, _swig_p) + return +} + +func DeleteMaterial(arg1 Material) { + _swig_wrap_delete_Material(arg1.Swigcptr()) +} + +type Material interface { + Swigcptr() uintptr + SwigIsMaterial() +} + +type SwigcptrRayPacketData uintptr + +func (p SwigcptrRayPacketData) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrRayPacketData) SwigIsRayPacketData() { +} + +var _wrap_Size_RayPacketData unsafe.Pointer + +func _swig_getRayPacketData_Size_RayPacketData() (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_Size_RayPacketData, _swig_p) + return +} +var RayPacketDataSize int = _swig_getRayPacketData_Size_RayPacketData() +var _wrap_RayPacketData_chitMat_set unsafe.Pointer + +func _swig_wrap_RayPacketData_chitMat_set(base SwigcptrRayPacketData, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_RayPacketData_chitMat_set, _swig_p) + return +} + +func (arg1 SwigcptrRayPacketData) SetChitMat(arg2 Material) { + _swig_wrap_RayPacketData_chitMat_set(arg1, arg2.Swigcptr()) +} + +var _wrap_RayPacketData_chitMat_get unsafe.Pointer + +func _swig_wrap_RayPacketData_chitMat_get(base SwigcptrRayPacketData) (_ SwigcptrMaterial) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_RayPacketData_chitMat_get, _swig_p) + return +} + +func (arg1 SwigcptrRayPacketData) GetChitMat() (_swig_ret Material) { + return _swig_wrap_RayPacketData_chitMat_get(arg1) +} + +var _wrap_RayPacketData_hitMat_val_set unsafe.Pointer + +func _swig_wrap_RayPacketData_hitMat_val_set(base SwigcptrRayPacketData, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_RayPacketData_hitMat_val_set, _swig_p) + return +} + +func (arg1 SwigcptrRayPacketData) SetHitMat_val(arg2 Material) { + _swig_wrap_RayPacketData_hitMat_val_set(arg1, arg2.Swigcptr()) +} + +var _wrap_RayPacketData_hitMat_val_get unsafe.Pointer + +func _swig_wrap_RayPacketData_hitMat_val_get(base SwigcptrRayPacketData) (_ SwigcptrMaterial) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_RayPacketData_hitMat_val_get, _swig_p) + return +} + +func (arg1 SwigcptrRayPacketData) GetHitMat_val() (_swig_ret Material) { + return _swig_wrap_RayPacketData_hitMat_val_get(arg1) +} + +var _wrap_RayPacketData_hitMat_set unsafe.Pointer + +func _swig_wrap_RayPacketData_hitMat_set(base SwigcptrRayPacketData, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_RayPacketData_hitMat_set, _swig_p) + return +} + +func (arg1 SwigcptrRayPacketData) SetHitMat(arg2 Material) { + _swig_wrap_RayPacketData_hitMat_set(arg1, arg2.Swigcptr()) +} + +var _wrap_RayPacketData_hitMat_get unsafe.Pointer + +func _swig_wrap_RayPacketData_hitMat_get(base SwigcptrRayPacketData) (_ SwigcptrMaterial) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_RayPacketData_hitMat_get, _swig_p) + return +} + +func (arg1 SwigcptrRayPacketData) GetHitMat() (_swig_ret Material) { + return _swig_wrap_RayPacketData_hitMat_get(arg1) +} + +var _wrap_RayPacketData_chitMat2_set unsafe.Pointer + +func _swig_wrap_RayPacketData_chitMat2_set(base SwigcptrRayPacketData, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_RayPacketData_chitMat2_set, _swig_p) + return +} + +func (arg1 SwigcptrRayPacketData) SetChitMat2(arg2 Material) { + _swig_wrap_RayPacketData_chitMat2_set(arg1, arg2.Swigcptr()) +} + +var _wrap_RayPacketData_chitMat2_get unsafe.Pointer + +func _swig_wrap_RayPacketData_chitMat2_get(base SwigcptrRayPacketData) (_ SwigcptrMaterial) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_RayPacketData_chitMat2_get, _swig_p) + return +} + +func (arg1 SwigcptrRayPacketData) GetChitMat2() (_swig_ret Material) { + return _swig_wrap_RayPacketData_chitMat2_get(arg1) +} + +var _wrap_RayPacketData_hitMat_val2_set unsafe.Pointer + +func _swig_wrap_RayPacketData_hitMat_val2_set(base SwigcptrRayPacketData, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_RayPacketData_hitMat_val2_set, _swig_p) + return +} + +func (arg1 SwigcptrRayPacketData) SetHitMat_val2(arg2 Material) { + _swig_wrap_RayPacketData_hitMat_val2_set(arg1, arg2.Swigcptr()) +} + +var _wrap_RayPacketData_hitMat_val2_get unsafe.Pointer + +func _swig_wrap_RayPacketData_hitMat_val2_get(base SwigcptrRayPacketData) (_ SwigcptrMaterial) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_RayPacketData_hitMat_val2_get, _swig_p) + return +} + +func (arg1 SwigcptrRayPacketData) GetHitMat_val2() (_swig_ret Material) { + return _swig_wrap_RayPacketData_hitMat_val2_get(arg1) +} + +var _wrap_RayPacketData_hitMat2_set unsafe.Pointer + +func _swig_wrap_RayPacketData_hitMat2_set(base SwigcptrRayPacketData, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_RayPacketData_hitMat2_set, _swig_p) + return +} + +func (arg1 SwigcptrRayPacketData) SetHitMat2(arg2 Material) { + _swig_wrap_RayPacketData_hitMat2_set(arg1, arg2.Swigcptr()) +} + +var _wrap_RayPacketData_hitMat2_get unsafe.Pointer + +func _swig_wrap_RayPacketData_hitMat2_get(base SwigcptrRayPacketData) (_ SwigcptrMaterial) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_RayPacketData_hitMat2_get, _swig_p) + return +} + +func (arg1 SwigcptrRayPacketData) GetHitMat2() (_swig_ret Material) { + return _swig_wrap_RayPacketData_hitMat2_get(arg1) +} + +var _wrap_new_RayPacketData unsafe.Pointer + +func _swig_wrap_new_RayPacketData() (base SwigcptrRayPacketData) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_RayPacketData, _swig_p) + return +} + +func NewRayPacketData() (_swig_ret RayPacketData) { + return _swig_wrap_new_RayPacketData() +} + +var _wrap_delete_RayPacketData unsafe.Pointer + +func _swig_wrap_delete_RayPacketData(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_RayPacketData, _swig_p) + return +} + +func DeleteRayPacketData(arg1 RayPacketData) { + _swig_wrap_delete_RayPacketData(arg1.Swigcptr()) +} + +type RayPacketData interface { + Swigcptr() uintptr + SwigIsRayPacketData() + SetChitMat(arg2 Material) + GetChitMat() (_swig_ret Material) + SetHitMat_val(arg2 Material) + GetHitMat_val() (_swig_ret Material) + SetHitMat(arg2 Material) + GetHitMat() (_swig_ret Material) + SetChitMat2(arg2 Material) + GetChitMat2() (_swig_ret Material) + SetHitMat_val2(arg2 Material) + GetHitMat_val2() (_swig_ret Material) + SetHitMat2(arg2 Material) + GetHitMat2() (_swig_ret Material) +} + +const BUFF_LEN int = 12 +type SwigcptrMyBuff uintptr + +func (p SwigcptrMyBuff) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrMyBuff) SwigIsMyBuff() { +} + +var _wrap_MyBuff_i_set unsafe.Pointer + +func _swig_wrap_MyBuff_i_set(base SwigcptrMyBuff, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_MyBuff_i_set, _swig_p) + return +} + +func (arg1 SwigcptrMyBuff) SetI(arg2 int) { + _swig_wrap_MyBuff_i_set(arg1, arg2) +} + +var _wrap_MyBuff_i_get unsafe.Pointer + +func _swig_wrap_MyBuff_i_get(base SwigcptrMyBuff) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_MyBuff_i_get, _swig_p) + return +} + +func (arg1 SwigcptrMyBuff) GetI() (_swig_ret int) { + return _swig_wrap_MyBuff_i_get(arg1) +} + +var _wrap_MyBuff_x_set unsafe.Pointer + +func _swig_wrap_MyBuff_x_set(base SwigcptrMyBuff, _ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_MyBuff_x_set, _swig_p) + return +} + +func (arg1 SwigcptrMyBuff) SetX(arg2 string) { + _swig_wrap_MyBuff_x_set(arg1, arg2) +} + +var _wrap_MyBuff_x_get unsafe.Pointer + +func _swig_wrap_MyBuff_x_get(base SwigcptrMyBuff) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_MyBuff_x_get, _swig_p) + return +} + +func (arg1 SwigcptrMyBuff) GetX() (_swig_ret string) { + return _swig_wrap_MyBuff_x_get(arg1) +} + +var _wrap_new_MyBuff unsafe.Pointer + +func _swig_wrap_new_MyBuff() (base SwigcptrMyBuff) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_MyBuff, _swig_p) + return +} + +func NewMyBuff() (_swig_ret MyBuff) { + return _swig_wrap_new_MyBuff() +} + +var _wrap_delete_MyBuff unsafe.Pointer + +func _swig_wrap_delete_MyBuff(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_MyBuff, _swig_p) + return +} + +func DeleteMyBuff(arg1 MyBuff) { + _swig_wrap_delete_MyBuff(arg1.Swigcptr()) +} + +type MyBuff interface { + Swigcptr() uintptr + SwigIsMyBuff() + SetI(arg2 int) + GetI() (_swig_ret int) + SetX(arg2 string) + GetX() (_swig_ret string) +} + +type SwigcptrMySBuff uintptr + +func (p SwigcptrMySBuff) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrMySBuff) SwigIsMySBuff() { +} + +var _wrap_MySBuff_i_set unsafe.Pointer + +func _swig_wrap_MySBuff_i_set(base SwigcptrMySBuff, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_MySBuff_i_set, _swig_p) + return +} + +func (arg1 SwigcptrMySBuff) SetI(arg2 int) { + _swig_wrap_MySBuff_i_set(arg1, arg2) +} + +var _wrap_MySBuff_i_get unsafe.Pointer + +func _swig_wrap_MySBuff_i_get(base SwigcptrMySBuff) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_MySBuff_i_get, _swig_p) + return +} + +func (arg1 SwigcptrMySBuff) GetI() (_swig_ret int) { + return _swig_wrap_MySBuff_i_get(arg1) +} + +var _wrap_MySBuff_x_set unsafe.Pointer + +func _swig_wrap_MySBuff_x_set(base SwigcptrMySBuff, _ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_MySBuff_x_set, _swig_p) + return +} + +func (arg1 SwigcptrMySBuff) SetX(arg2 string) { + _swig_wrap_MySBuff_x_set(arg1, arg2) +} + +var _wrap_MySBuff_x_get unsafe.Pointer + +func _swig_wrap_MySBuff_x_get(base SwigcptrMySBuff) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_MySBuff_x_get, _swig_p) + return +} + +func (arg1 SwigcptrMySBuff) GetX() (_swig_ret string) { + return _swig_wrap_MySBuff_x_get(arg1) +} + +var _wrap_new_MySBuff unsafe.Pointer + +func _swig_wrap_new_MySBuff() (base SwigcptrMySBuff) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_MySBuff, _swig_p) + return +} + +func NewMySBuff() (_swig_ret MySBuff) { + return _swig_wrap_new_MySBuff() +} + +var _wrap_delete_MySBuff unsafe.Pointer + +func _swig_wrap_delete_MySBuff(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_MySBuff, _swig_p) + return +} + +func DeleteMySBuff(arg1 MySBuff) { + _swig_wrap_delete_MySBuff(arg1.Swigcptr()) +} + +type MySBuff interface { + Swigcptr() uintptr + SwigIsMySBuff() + SetI(arg2 int) + GetI() (_swig_ret int) + SetX(arg2 string) + GetX() (_swig_ret string) +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/array_member_runme b/Examples/test-suite/go/array_member_runme new file mode 100755 index 000000000..f97cc4f55 Binary files /dev/null and b/Examples/test-suite/go/array_member_runme differ diff --git a/Examples/test-suite/go/array_typedef_memberin.go b/Examples/test-suite/go/array_typedef_memberin.go new file mode 100644 index 000000000..bc1c3bf7a --- /dev/null +++ b/Examples/test-suite/go/array_typedef_memberin.go @@ -0,0 +1,328 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../array_typedef_memberin.i + +package array_typedef_memberin + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrExampleDetail uintptr + +func (p SwigcptrExampleDetail) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrExampleDetail) SwigIsExampleDetail() { +} + +var _wrap_ExampleDetail_node_list_set unsafe.Pointer + +func _swig_wrap_ExampleDetail_node_list_set(base SwigcptrExampleDetail, _ *int16) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_ExampleDetail_node_list_set, _swig_p) + return +} + +func (arg1 SwigcptrExampleDetail) SetNode_list(arg2 *int16) { + _swig_wrap_ExampleDetail_node_list_set(arg1, arg2) +} + +var _wrap_ExampleDetail_node_list_get unsafe.Pointer + +func _swig_wrap_ExampleDetail_node_list_get(base SwigcptrExampleDetail) (_ *int16) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_ExampleDetail_node_list_get, _swig_p) + return +} + +func (arg1 SwigcptrExampleDetail) GetNode_list() (_swig_ret *int16) { + return _swig_wrap_ExampleDetail_node_list_get(arg1) +} + +var _wrap_ExampleDetail_node_list2_get unsafe.Pointer + +func _swig_wrap_ExampleDetail_node_list2_get(base SwigcptrExampleDetail) (_ *int16) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_ExampleDetail_node_list2_get, _swig_p) + return +} + +func (arg1 SwigcptrExampleDetail) GetNode_list2() (_swig_ret *int16) { + return _swig_wrap_ExampleDetail_node_list2_get(arg1) +} + +var _wrap_ExampleDetail_node_list3_get unsafe.Pointer + +func _swig_wrap_ExampleDetail_node_list3_get(base SwigcptrExampleDetail) (_ *int16) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_ExampleDetail_node_list3_get, _swig_p) + return +} + +func (arg1 SwigcptrExampleDetail) GetNode_list3() (_swig_ret *int16) { + return _swig_wrap_ExampleDetail_node_list3_get(arg1) +} + +var _wrap_ExampleDetail_fn1 unsafe.Pointer + +func _swig_wrap_ExampleDetail_fn1(base SwigcptrExampleDetail, _ *int16) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_ExampleDetail_fn1, _swig_p) + return +} + +func (arg1 SwigcptrExampleDetail) Fn1(arg2 *int16) { + _swig_wrap_ExampleDetail_fn1(arg1, arg2) +} + +var _wrap_ExampleDetail_fn2 unsafe.Pointer + +func _swig_wrap_ExampleDetail_fn2(base SwigcptrExampleDetail, _ *int16) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_ExampleDetail_fn2, _swig_p) + return +} + +func (arg1 SwigcptrExampleDetail) Fn2(arg2 *int16) { + _swig_wrap_ExampleDetail_fn2(arg1, arg2) +} + +var _wrap_ExampleDetail_fn3 unsafe.Pointer + +func _swig_wrap_ExampleDetail_fn3(base SwigcptrExampleDetail, _ *int16) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_ExampleDetail_fn3, _swig_p) + return +} + +func (arg1 SwigcptrExampleDetail) Fn3(arg2 *int16) { + _swig_wrap_ExampleDetail_fn3(arg1, arg2) +} + +var _wrap_ExampleDetail_fn4 unsafe.Pointer + +func _swig_wrap_ExampleDetail_fn4(base SwigcptrExampleDetail, _ **int16) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_ExampleDetail_fn4, _swig_p) + return +} + +func (arg1 SwigcptrExampleDetail) Fn4(arg2 **int16) { + _swig_wrap_ExampleDetail_fn4(arg1, arg2) +} + +var _wrap_ExampleDetail_fn5 unsafe.Pointer + +func _swig_wrap_ExampleDetail_fn5(base SwigcptrExampleDetail, _ **int16) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_ExampleDetail_fn5, _swig_p) + return +} + +func (arg1 SwigcptrExampleDetail) Fn5(arg2 **int16) { + _swig_wrap_ExampleDetail_fn5(arg1, arg2) +} + +var _wrap_ExampleDetail_fn6 unsafe.Pointer + +func _swig_wrap_ExampleDetail_fn6(base SwigcptrExampleDetail, _ **int16) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_ExampleDetail_fn6, _swig_p) + return +} + +func (arg1 SwigcptrExampleDetail) Fn6(arg2 **int16) { + _swig_wrap_ExampleDetail_fn6(arg1, arg2) +} + +var _wrap_ExampleDetail_fn7 unsafe.Pointer + +func _swig_wrap_ExampleDetail_fn7(base SwigcptrExampleDetail, _ ***int16) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_ExampleDetail_fn7, _swig_p) + return +} + +func (arg1 SwigcptrExampleDetail) Fn7(arg2 ***int16) { + _swig_wrap_ExampleDetail_fn7(arg1, arg2) +} + +var _wrap_ExampleDetail_fn8 unsafe.Pointer + +func _swig_wrap_ExampleDetail_fn8(base SwigcptrExampleDetail, _ ***int16) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_ExampleDetail_fn8, _swig_p) + return +} + +func (arg1 SwigcptrExampleDetail) Fn8(arg2 ***int16) { + _swig_wrap_ExampleDetail_fn8(arg1, arg2) +} + +var _wrap_ExampleDetail_fn9 unsafe.Pointer + +func _swig_wrap_ExampleDetail_fn9(base SwigcptrExampleDetail, _ ***int16) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_ExampleDetail_fn9, _swig_p) + return +} + +func (arg1 SwigcptrExampleDetail) Fn9(arg2 ***int16) { + _swig_wrap_ExampleDetail_fn9(arg1, arg2) +} + +var _wrap_new_ExampleDetail unsafe.Pointer + +func _swig_wrap_new_ExampleDetail() (base SwigcptrExampleDetail) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_ExampleDetail, _swig_p) + return +} + +func NewExampleDetail() (_swig_ret ExampleDetail) { + return _swig_wrap_new_ExampleDetail() +} + +var _wrap_delete_ExampleDetail unsafe.Pointer + +func _swig_wrap_delete_ExampleDetail(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_ExampleDetail, _swig_p) + return +} + +func DeleteExampleDetail(arg1 ExampleDetail) { + _swig_wrap_delete_ExampleDetail(arg1.Swigcptr()) +} + +type ExampleDetail interface { + Swigcptr() uintptr + SwigIsExampleDetail() + SetNode_list(arg2 *int16) + GetNode_list() (_swig_ret *int16) + GetNode_list2() (_swig_ret *int16) + GetNode_list3() (_swig_ret *int16) + Fn1(arg2 *int16) + Fn2(arg2 *int16) + Fn3(arg2 *int16) + Fn4(arg2 **int16) + Fn5(arg2 **int16) + Fn6(arg2 **int16) + Fn7(arg2 ***int16) + Fn8(arg2 ***int16) + Fn9(arg2 ***int16) +} + +var _wrap_test_1 unsafe.Pointer + +func _swig_wrap_test_1(base **int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_test_1, _swig_p) + return +} + +func Test_1(arg1 **int) { + _swig_wrap_test_1(arg1) +} + +var _wrap_test_2 unsafe.Pointer + +func _swig_wrap_test_2(base **int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_test_2, _swig_p) + return +} + +func Test_2(arg1 **int) { + _swig_wrap_test_2(arg1) +} + +var _wrap_test_3 unsafe.Pointer + +func _swig_wrap_test_3(base **int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_test_3, _swig_p) + return +} + +func Test_3(arg1 **int) { + _swig_wrap_test_3(arg1) +} + +var _wrap_test_4 unsafe.Pointer + +func _swig_wrap_test_4(base **int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_test_4, _swig_p) + return +} + +func Test_4(arg1 **int) { + _swig_wrap_test_4(arg1) +} + +var _wrap_test_5 unsafe.Pointer + +func _swig_wrap_test_5(base **int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_test_5, _swig_p) + return +} + +func Test_5(arg1 **int) { + _swig_wrap_test_5(arg1) +} + +var _wrap_test_3r unsafe.Pointer + +func _swig_wrap_test_3r(base ***int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_test_3r, _swig_p) + return +} + +func Test_3r(arg1 ***int) { + _swig_wrap_test_3r(arg1) +} + +var _wrap_test_4r unsafe.Pointer + +func _swig_wrap_test_4r(base ***int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_test_4r, _swig_p) + return +} + +func Test_4r(arg1 ***int) { + _swig_wrap_test_4r(arg1) +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/arrayref.go b/Examples/test-suite/go/arrayref.go new file mode 100644 index 000000000..1027233bf --- /dev/null +++ b/Examples/test-suite/go/arrayref.go @@ -0,0 +1,61 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../arrayref.i + +package arrayref + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +var _wrap_foo unsafe.Pointer + +func _swig_wrap_foo(base **int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_foo, _swig_p) + return +} + +func Foo(arg1 **int) { + _swig_wrap_foo(arg1) +} + +var _wrap_bar unsafe.Pointer + +func _swig_wrap_bar(base **int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_bar, _swig_p) + return +} + +func Bar(arg1 **int) { + _swig_wrap_bar(arg1) +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/arrays.go b/Examples/test-suite/go/arrays.go new file mode 100644 index 000000000..5e3bcb55e --- /dev/null +++ b/Examples/test-suite/go/arrays.go @@ -0,0 +1,750 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../arrays.i + +package arrays + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +const ARRAY_LEN int = 2 +type Finger int +var _wrap_One unsafe.Pointer + +func _swig_getOne() (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_One, _swig_p) + return +} +var One int = _swig_getOne() +var _wrap_Two unsafe.Pointer + +func _swig_getTwo() (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_Two, _swig_p) + return +} +var Two int = _swig_getTwo() +var _wrap_Three unsafe.Pointer + +func _swig_getThree() (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_Three, _swig_p) + return +} +var Three int = _swig_getThree() +var _wrap_Four unsafe.Pointer + +func _swig_getFour() (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_Four, _swig_p) + return +} +var Four int = _swig_getFour() +var _wrap_Five unsafe.Pointer + +func _swig_getFive() (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_Five, _swig_p) + return +} +var Five int = _swig_getFive() +type SwigcptrSimpleStruct uintptr + +func (p SwigcptrSimpleStruct) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrSimpleStruct) SwigIsSimpleStruct() { +} + +var _wrap_SimpleStruct_double_field_set unsafe.Pointer + +func _swig_wrap_SimpleStruct_double_field_set(base SwigcptrSimpleStruct, _ float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_SimpleStruct_double_field_set, _swig_p) + return +} + +func (arg1 SwigcptrSimpleStruct) SetDouble_field(arg2 float64) { + _swig_wrap_SimpleStruct_double_field_set(arg1, arg2) +} + +var _wrap_SimpleStruct_double_field_get unsafe.Pointer + +func _swig_wrap_SimpleStruct_double_field_get(base SwigcptrSimpleStruct) (_ float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_SimpleStruct_double_field_get, _swig_p) + return +} + +func (arg1 SwigcptrSimpleStruct) GetDouble_field() (_swig_ret float64) { + return _swig_wrap_SimpleStruct_double_field_get(arg1) +} + +var _wrap_new_SimpleStruct unsafe.Pointer + +func _swig_wrap_new_SimpleStruct() (base SwigcptrSimpleStruct) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_SimpleStruct, _swig_p) + return +} + +func NewSimpleStruct() (_swig_ret SimpleStruct) { + return _swig_wrap_new_SimpleStruct() +} + +var _wrap_delete_SimpleStruct unsafe.Pointer + +func _swig_wrap_delete_SimpleStruct(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_SimpleStruct, _swig_p) + return +} + +func DeleteSimpleStruct(arg1 SimpleStruct) { + _swig_wrap_delete_SimpleStruct(arg1.Swigcptr()) +} + +type SimpleStruct interface { + Swigcptr() uintptr + SwigIsSimpleStruct() + SetDouble_field(arg2 float64) + GetDouble_field() (_swig_ret float64) +} + +type SwigcptrArrayStruct uintptr + +func (p SwigcptrArrayStruct) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrArrayStruct) SwigIsArrayStruct() { +} + +var _wrap_ArrayStruct_array_c_set unsafe.Pointer + +func _swig_wrap_ArrayStruct_array_c_set(base SwigcptrArrayStruct, _ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_ArrayStruct_array_c_set, _swig_p) + return +} + +func (arg1 SwigcptrArrayStruct) SetArray_c(arg2 string) { + _swig_wrap_ArrayStruct_array_c_set(arg1, arg2) +} + +var _wrap_ArrayStruct_array_c_get unsafe.Pointer + +func _swig_wrap_ArrayStruct_array_c_get(base SwigcptrArrayStruct) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_ArrayStruct_array_c_get, _swig_p) + return +} + +func (arg1 SwigcptrArrayStruct) GetArray_c() (_swig_ret string) { + return _swig_wrap_ArrayStruct_array_c_get(arg1) +} + +var _wrap_ArrayStruct_array_sc_set unsafe.Pointer + +func _swig_wrap_ArrayStruct_array_sc_set(base SwigcptrArrayStruct, _ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_ArrayStruct_array_sc_set, _swig_p) + return +} + +func (arg1 SwigcptrArrayStruct) SetArray_sc(arg2 string) { + _swig_wrap_ArrayStruct_array_sc_set(arg1, arg2) +} + +var _wrap_ArrayStruct_array_sc_get unsafe.Pointer + +func _swig_wrap_ArrayStruct_array_sc_get(base SwigcptrArrayStruct) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_ArrayStruct_array_sc_get, _swig_p) + return +} + +func (arg1 SwigcptrArrayStruct) GetArray_sc() (_swig_ret string) { + return _swig_wrap_ArrayStruct_array_sc_get(arg1) +} + +var _wrap_ArrayStruct_array_uc_set unsafe.Pointer + +func _swig_wrap_ArrayStruct_array_uc_set(base SwigcptrArrayStruct, _ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_ArrayStruct_array_uc_set, _swig_p) + return +} + +func (arg1 SwigcptrArrayStruct) SetArray_uc(arg2 string) { + _swig_wrap_ArrayStruct_array_uc_set(arg1, arg2) +} + +var _wrap_ArrayStruct_array_uc_get unsafe.Pointer + +func _swig_wrap_ArrayStruct_array_uc_get(base SwigcptrArrayStruct) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_ArrayStruct_array_uc_get, _swig_p) + return +} + +func (arg1 SwigcptrArrayStruct) GetArray_uc() (_swig_ret string) { + return _swig_wrap_ArrayStruct_array_uc_get(arg1) +} + +var _wrap_ArrayStruct_array_s_set unsafe.Pointer + +func _swig_wrap_ArrayStruct_array_s_set(base SwigcptrArrayStruct, _ *int16) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_ArrayStruct_array_s_set, _swig_p) + return +} + +func (arg1 SwigcptrArrayStruct) SetArray_s(arg2 *int16) { + _swig_wrap_ArrayStruct_array_s_set(arg1, arg2) +} + +var _wrap_ArrayStruct_array_s_get unsafe.Pointer + +func _swig_wrap_ArrayStruct_array_s_get(base SwigcptrArrayStruct) (_ *int16) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_ArrayStruct_array_s_get, _swig_p) + return +} + +func (arg1 SwigcptrArrayStruct) GetArray_s() (_swig_ret *int16) { + return _swig_wrap_ArrayStruct_array_s_get(arg1) +} + +var _wrap_ArrayStruct_array_us_set unsafe.Pointer + +func _swig_wrap_ArrayStruct_array_us_set(base SwigcptrArrayStruct, _ *uint16) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_ArrayStruct_array_us_set, _swig_p) + return +} + +func (arg1 SwigcptrArrayStruct) SetArray_us(arg2 *uint16) { + _swig_wrap_ArrayStruct_array_us_set(arg1, arg2) +} + +var _wrap_ArrayStruct_array_us_get unsafe.Pointer + +func _swig_wrap_ArrayStruct_array_us_get(base SwigcptrArrayStruct) (_ *uint16) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_ArrayStruct_array_us_get, _swig_p) + return +} + +func (arg1 SwigcptrArrayStruct) GetArray_us() (_swig_ret *uint16) { + return _swig_wrap_ArrayStruct_array_us_get(arg1) +} + +var _wrap_ArrayStruct_array_i_set unsafe.Pointer + +func _swig_wrap_ArrayStruct_array_i_set(base SwigcptrArrayStruct, _ *int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_ArrayStruct_array_i_set, _swig_p) + return +} + +func (arg1 SwigcptrArrayStruct) SetArray_i(arg2 *int) { + _swig_wrap_ArrayStruct_array_i_set(arg1, arg2) +} + +var _wrap_ArrayStruct_array_i_get unsafe.Pointer + +func _swig_wrap_ArrayStruct_array_i_get(base SwigcptrArrayStruct) (_ *int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_ArrayStruct_array_i_get, _swig_p) + return +} + +func (arg1 SwigcptrArrayStruct) GetArray_i() (_swig_ret *int) { + return _swig_wrap_ArrayStruct_array_i_get(arg1) +} + +var _wrap_ArrayStruct_array_ui_set unsafe.Pointer + +func _swig_wrap_ArrayStruct_array_ui_set(base SwigcptrArrayStruct, _ *uint) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_ArrayStruct_array_ui_set, _swig_p) + return +} + +func (arg1 SwigcptrArrayStruct) SetArray_ui(arg2 *uint) { + _swig_wrap_ArrayStruct_array_ui_set(arg1, arg2) +} + +var _wrap_ArrayStruct_array_ui_get unsafe.Pointer + +func _swig_wrap_ArrayStruct_array_ui_get(base SwigcptrArrayStruct) (_ *uint) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_ArrayStruct_array_ui_get, _swig_p) + return +} + +func (arg1 SwigcptrArrayStruct) GetArray_ui() (_swig_ret *uint) { + return _swig_wrap_ArrayStruct_array_ui_get(arg1) +} + +var _wrap_ArrayStruct_array_l_set unsafe.Pointer + +func _swig_wrap_ArrayStruct_array_l_set(base SwigcptrArrayStruct, _ *int64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_ArrayStruct_array_l_set, _swig_p) + return +} + +func (arg1 SwigcptrArrayStruct) SetArray_l(arg2 *int64) { + _swig_wrap_ArrayStruct_array_l_set(arg1, arg2) +} + +var _wrap_ArrayStruct_array_l_get unsafe.Pointer + +func _swig_wrap_ArrayStruct_array_l_get(base SwigcptrArrayStruct) (_ *int64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_ArrayStruct_array_l_get, _swig_p) + return +} + +func (arg1 SwigcptrArrayStruct) GetArray_l() (_swig_ret *int64) { + return _swig_wrap_ArrayStruct_array_l_get(arg1) +} + +var _wrap_ArrayStruct_array_ul_set unsafe.Pointer + +func _swig_wrap_ArrayStruct_array_ul_set(base SwigcptrArrayStruct, _ *uint64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_ArrayStruct_array_ul_set, _swig_p) + return +} + +func (arg1 SwigcptrArrayStruct) SetArray_ul(arg2 *uint64) { + _swig_wrap_ArrayStruct_array_ul_set(arg1, arg2) +} + +var _wrap_ArrayStruct_array_ul_get unsafe.Pointer + +func _swig_wrap_ArrayStruct_array_ul_get(base SwigcptrArrayStruct) (_ *uint64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_ArrayStruct_array_ul_get, _swig_p) + return +} + +func (arg1 SwigcptrArrayStruct) GetArray_ul() (_swig_ret *uint64) { + return _swig_wrap_ArrayStruct_array_ul_get(arg1) +} + +var _wrap_ArrayStruct_array_ll_set unsafe.Pointer + +func _swig_wrap_ArrayStruct_array_ll_set(base SwigcptrArrayStruct, _ *int64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_ArrayStruct_array_ll_set, _swig_p) + return +} + +func (arg1 SwigcptrArrayStruct) SetArray_ll(arg2 *int64) { + _swig_wrap_ArrayStruct_array_ll_set(arg1, arg2) +} + +var _wrap_ArrayStruct_array_ll_get unsafe.Pointer + +func _swig_wrap_ArrayStruct_array_ll_get(base SwigcptrArrayStruct) (_ *int64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_ArrayStruct_array_ll_get, _swig_p) + return +} + +func (arg1 SwigcptrArrayStruct) GetArray_ll() (_swig_ret *int64) { + return _swig_wrap_ArrayStruct_array_ll_get(arg1) +} + +var _wrap_ArrayStruct_array_f_set unsafe.Pointer + +func _swig_wrap_ArrayStruct_array_f_set(base SwigcptrArrayStruct, _ *float32) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_ArrayStruct_array_f_set, _swig_p) + return +} + +func (arg1 SwigcptrArrayStruct) SetArray_f(arg2 *float32) { + _swig_wrap_ArrayStruct_array_f_set(arg1, arg2) +} + +var _wrap_ArrayStruct_array_f_get unsafe.Pointer + +func _swig_wrap_ArrayStruct_array_f_get(base SwigcptrArrayStruct) (_ *float32) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_ArrayStruct_array_f_get, _swig_p) + return +} + +func (arg1 SwigcptrArrayStruct) GetArray_f() (_swig_ret *float32) { + return _swig_wrap_ArrayStruct_array_f_get(arg1) +} + +var _wrap_ArrayStruct_array_d_set unsafe.Pointer + +func _swig_wrap_ArrayStruct_array_d_set(base SwigcptrArrayStruct, _ *float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_ArrayStruct_array_d_set, _swig_p) + return +} + +func (arg1 SwigcptrArrayStruct) SetArray_d(arg2 *float64) { + _swig_wrap_ArrayStruct_array_d_set(arg1, arg2) +} + +var _wrap_ArrayStruct_array_d_get unsafe.Pointer + +func _swig_wrap_ArrayStruct_array_d_get(base SwigcptrArrayStruct) (_ *float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_ArrayStruct_array_d_get, _swig_p) + return +} + +func (arg1 SwigcptrArrayStruct) GetArray_d() (_swig_ret *float64) { + return _swig_wrap_ArrayStruct_array_d_get(arg1) +} + +var _wrap_ArrayStruct_array_struct_set unsafe.Pointer + +func _swig_wrap_ArrayStruct_array_struct_set(base SwigcptrArrayStruct, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_ArrayStruct_array_struct_set, _swig_p) + return +} + +func (arg1 SwigcptrArrayStruct) SetArray_struct(arg2 SimpleStruct) { + _swig_wrap_ArrayStruct_array_struct_set(arg1, arg2.Swigcptr()) +} + +var _wrap_ArrayStruct_array_struct_get unsafe.Pointer + +func _swig_wrap_ArrayStruct_array_struct_get(base SwigcptrArrayStruct) (_ SwigcptrSimpleStruct) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_ArrayStruct_array_struct_get, _swig_p) + return +} + +func (arg1 SwigcptrArrayStruct) GetArray_struct() (_swig_ret SimpleStruct) { + return _swig_wrap_ArrayStruct_array_struct_get(arg1) +} + +var _wrap_ArrayStruct_array_structpointers_set unsafe.Pointer + +func _swig_wrap_ArrayStruct_array_structpointers_set(base SwigcptrArrayStruct, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_ArrayStruct_array_structpointers_set, _swig_p) + return +} + +func (arg1 SwigcptrArrayStruct) SetArray_structpointers(arg2 SimpleStruct) { + _swig_wrap_ArrayStruct_array_structpointers_set(arg1, arg2.Swigcptr()) +} + +var _wrap_ArrayStruct_array_structpointers_get unsafe.Pointer + +func _swig_wrap_ArrayStruct_array_structpointers_get(base SwigcptrArrayStruct) (_ SwigcptrSimpleStruct) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_ArrayStruct_array_structpointers_get, _swig_p) + return +} + +func (arg1 SwigcptrArrayStruct) GetArray_structpointers() (_swig_ret SimpleStruct) { + return _swig_wrap_ArrayStruct_array_structpointers_get(arg1) +} + +var _wrap_ArrayStruct_array_ipointers_set unsafe.Pointer + +func _swig_wrap_ArrayStruct_array_ipointers_set(base SwigcptrArrayStruct, _ **int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_ArrayStruct_array_ipointers_set, _swig_p) + return +} + +func (arg1 SwigcptrArrayStruct) SetArray_ipointers(arg2 **int) { + _swig_wrap_ArrayStruct_array_ipointers_set(arg1, arg2) +} + +var _wrap_ArrayStruct_array_ipointers_get unsafe.Pointer + +func _swig_wrap_ArrayStruct_array_ipointers_get(base SwigcptrArrayStruct) (_ **int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_ArrayStruct_array_ipointers_get, _swig_p) + return +} + +func (arg1 SwigcptrArrayStruct) GetArray_ipointers() (_swig_ret **int) { + return _swig_wrap_ArrayStruct_array_ipointers_get(arg1) +} + +var _wrap_ArrayStruct_array_enum_set unsafe.Pointer + +func _swig_wrap_ArrayStruct_array_enum_set(base SwigcptrArrayStruct, _ *Finger) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_ArrayStruct_array_enum_set, _swig_p) + return +} + +func (arg1 SwigcptrArrayStruct) SetArray_enum(arg2 *Finger) { + _swig_wrap_ArrayStruct_array_enum_set(arg1, arg2) +} + +var _wrap_ArrayStruct_array_enum_get unsafe.Pointer + +func _swig_wrap_ArrayStruct_array_enum_get(base SwigcptrArrayStruct) (_ *Finger) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_ArrayStruct_array_enum_get, _swig_p) + return +} + +func (arg1 SwigcptrArrayStruct) GetArray_enum() (_swig_ret *Finger) { + return _swig_wrap_ArrayStruct_array_enum_get(arg1) +} + +var _wrap_ArrayStruct_array_enumpointers_set unsafe.Pointer + +func _swig_wrap_ArrayStruct_array_enumpointers_set(base SwigcptrArrayStruct, _ **Finger) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_ArrayStruct_array_enumpointers_set, _swig_p) + return +} + +func (arg1 SwigcptrArrayStruct) SetArray_enumpointers(arg2 **Finger) { + _swig_wrap_ArrayStruct_array_enumpointers_set(arg1, arg2) +} + +var _wrap_ArrayStruct_array_enumpointers_get unsafe.Pointer + +func _swig_wrap_ArrayStruct_array_enumpointers_get(base SwigcptrArrayStruct) (_ **Finger) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_ArrayStruct_array_enumpointers_get, _swig_p) + return +} + +func (arg1 SwigcptrArrayStruct) GetArray_enumpointers() (_swig_ret **Finger) { + return _swig_wrap_ArrayStruct_array_enumpointers_get(arg1) +} + +var _wrap_ArrayStruct_array_const_i_get unsafe.Pointer + +func _swig_wrap_ArrayStruct_array_const_i_get(base SwigcptrArrayStruct) (_ *int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_ArrayStruct_array_const_i_get, _swig_p) + return +} + +func (arg1 SwigcptrArrayStruct) GetArray_const_i() (_swig_ret *int) { + return _swig_wrap_ArrayStruct_array_const_i_get(arg1) +} + +var _wrap_new_ArrayStruct unsafe.Pointer + +func _swig_wrap_new_ArrayStruct() (base SwigcptrArrayStruct) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_ArrayStruct, _swig_p) + return +} + +func NewArrayStruct() (_swig_ret ArrayStruct) { + return _swig_wrap_new_ArrayStruct() +} + +var _wrap_delete_ArrayStruct unsafe.Pointer + +func _swig_wrap_delete_ArrayStruct(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_ArrayStruct, _swig_p) + return +} + +func DeleteArrayStruct(arg1 ArrayStruct) { + _swig_wrap_delete_ArrayStruct(arg1.Swigcptr()) +} + +type ArrayStruct interface { + Swigcptr() uintptr + SwigIsArrayStruct() + SetArray_c(arg2 string) + GetArray_c() (_swig_ret string) + SetArray_sc(arg2 string) + GetArray_sc() (_swig_ret string) + SetArray_uc(arg2 string) + GetArray_uc() (_swig_ret string) + SetArray_s(arg2 *int16) + GetArray_s() (_swig_ret *int16) + SetArray_us(arg2 *uint16) + GetArray_us() (_swig_ret *uint16) + SetArray_i(arg2 *int) + GetArray_i() (_swig_ret *int) + SetArray_ui(arg2 *uint) + GetArray_ui() (_swig_ret *uint) + SetArray_l(arg2 *int64) + GetArray_l() (_swig_ret *int64) + SetArray_ul(arg2 *uint64) + GetArray_ul() (_swig_ret *uint64) + SetArray_ll(arg2 *int64) + GetArray_ll() (_swig_ret *int64) + SetArray_f(arg2 *float32) + GetArray_f() (_swig_ret *float32) + SetArray_d(arg2 *float64) + GetArray_d() (_swig_ret *float64) + SetArray_struct(arg2 SimpleStruct) + GetArray_struct() (_swig_ret SimpleStruct) + SetArray_structpointers(arg2 SimpleStruct) + GetArray_structpointers() (_swig_ret SimpleStruct) + SetArray_ipointers(arg2 **int) + GetArray_ipointers() (_swig_ret **int) + SetArray_enum(arg2 *Finger) + GetArray_enum() (_swig_ret *Finger) + SetArray_enumpointers(arg2 **Finger) + GetArray_enumpointers() (_swig_ret **Finger) + GetArray_const_i() (_swig_ret *int) +} + +var _wrap_fn_taking_arrays unsafe.Pointer + +func _swig_wrap_fn_taking_arrays(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_fn_taking_arrays, _swig_p) + return +} + +func Fn_taking_arrays(arg1 SimpleStruct) { + _swig_wrap_fn_taking_arrays(arg1.Swigcptr()) +} + +var _wrap_newintpointer unsafe.Pointer + +func Newintpointer() (_swig_ret *int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_newintpointer, _swig_p) + return +} +var _wrap_setintfrompointer unsafe.Pointer + +func _swig_wrap_setintfrompointer(base *int, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_setintfrompointer, _swig_p) + return +} + +func Setintfrompointer(arg1 *int, arg2 int) { + _swig_wrap_setintfrompointer(arg1, arg2) +} + +var _wrap_getintfrompointer unsafe.Pointer + +func Getintfrompointer(arg1 *int) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_getintfrompointer, _swig_p) + return +} +var _wrap_array_pointer_func unsafe.Pointer + +func _swig_wrap_array_pointer_func(base **int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_array_pointer_func, _swig_p) + return +} + +func Array_pointer_func(arg1 **int) { + _swig_wrap_array_pointer_func(arg1) +} + +type SwigcptrCartPoseData_t uintptr + +func (p SwigcptrCartPoseData_t) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrCartPoseData_t) SwigIsCartPoseData_t() { +} + +var _wrap_CartPoseData_t_p_set unsafe.Pointer + +func _swig_wrap_CartPoseData_t_p_set(base SwigcptrCartPoseData_t, _ *float32) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_CartPoseData_t_p_set, _swig_p) + return +} + +func (arg1 SwigcptrCartPoseData_t) SetP(arg2 *float32) { + _swig_wrap_CartPoseData_t_p_set(arg1, arg2) +} + +var _wrap_CartPoseData_t_p_get unsafe.Pointer + +func _swig_wrap_CartPoseData_t_p_get(base SwigcptrCartPoseData_t) (_ *float32) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_CartPoseData_t_p_get, _swig_p) + return +} + +func (arg1 SwigcptrCartPoseData_t) GetP() (_swig_ret *float32) { + return _swig_wrap_CartPoseData_t_p_get(arg1) +} + +var _wrap_new_CartPoseData_t unsafe.Pointer + +func _swig_wrap_new_CartPoseData_t() (base SwigcptrCartPoseData_t) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_CartPoseData_t, _swig_p) + return +} + +func NewCartPoseData_t() (_swig_ret CartPoseData_t) { + return _swig_wrap_new_CartPoseData_t() +} + +var _wrap_delete_CartPoseData_t unsafe.Pointer + +func _swig_wrap_delete_CartPoseData_t(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_CartPoseData_t, _swig_p) + return +} + +func DeleteCartPoseData_t(arg1 CartPoseData_t) { + _swig_wrap_delete_CartPoseData_t(arg1.Swigcptr()) +} + +type CartPoseData_t interface { + Swigcptr() uintptr + SwigIsCartPoseData_t() + SetP(arg2 *float32) + GetP() (_swig_ret *float32) +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/arrays_dimensionless.go b/Examples/test-suite/go/arrays_dimensionless.go new file mode 100644 index 000000000..afaebec48 --- /dev/null +++ b/Examples/test-suite/go/arrays_dimensionless.go @@ -0,0 +1,292 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../arrays_dimensionless.i + +package arrays_dimensionless + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +var _wrap_globalints_get unsafe.Pointer + +func GetGlobalints() (_swig_ret *int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_globalints_get, _swig_p) + return +} +var _wrap_constglobalints_get unsafe.Pointer + +func GetConstglobalints() (_swig_ret *int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_constglobalints_get, _swig_p) + return +} +type SwigcptrBar uintptr + +func (p SwigcptrBar) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrBar) SwigIsBar() { +} + +var _wrap_Bar_ints_get unsafe.Pointer + +func GetBarInts() (_swig_ret *int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_Bar_ints_get, _swig_p) + return +} +var _wrap_new_Bar unsafe.Pointer + +func _swig_wrap_new_Bar() (base SwigcptrBar) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Bar, _swig_p) + return +} + +func NewBar() (_swig_ret Bar) { + return _swig_wrap_new_Bar() +} + +var _wrap_delete_Bar unsafe.Pointer + +func _swig_wrap_delete_Bar(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Bar, _swig_p) + return +} + +func DeleteBar(arg1 Bar) { + _swig_wrap_delete_Bar(arg1.Swigcptr()) +} + +type Bar interface { + Swigcptr() uintptr + SwigIsBar() +} + +var _wrap_arr_bool unsafe.Pointer + +func Arr_bool(arg1 *bool, arg2 int) (_swig_ret float64) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_arr_bool, _swig_p) + return +} +var _wrap_arr_char unsafe.Pointer + +func Arr_char(arg1 string, arg2 int) (_swig_ret float64) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_arr_char, _swig_p) + return +} +var _wrap_arr_schar unsafe.Pointer + +func Arr_schar(arg1 string, arg2 int) (_swig_ret float64) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_arr_schar, _swig_p) + return +} +var _wrap_arr_uchar unsafe.Pointer + +func Arr_uchar(arg1 string, arg2 int) (_swig_ret float64) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_arr_uchar, _swig_p) + return +} +var _wrap_arr_short unsafe.Pointer + +func Arr_short(arg1 *int16, arg2 int) (_swig_ret float64) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_arr_short, _swig_p) + return +} +var _wrap_arr_ushort unsafe.Pointer + +func Arr_ushort(arg1 *uint16, arg2 int) (_swig_ret float64) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_arr_ushort, _swig_p) + return +} +var _wrap_arr_int unsafe.Pointer + +func Arr_int(arg1 *int, arg2 int) (_swig_ret float64) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_arr_int, _swig_p) + return +} +var _wrap_arr_uint unsafe.Pointer + +func Arr_uint(arg1 *uint, arg2 int) (_swig_ret float64) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_arr_uint, _swig_p) + return +} +var _wrap_arr_long unsafe.Pointer + +func Arr_long(arg1 *int64, arg2 int) (_swig_ret float64) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_arr_long, _swig_p) + return +} +var _wrap_arr_ulong unsafe.Pointer + +func Arr_ulong(arg1 *uint64, arg2 int) (_swig_ret float64) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_arr_ulong, _swig_p) + return +} +var _wrap_arr_ll unsafe.Pointer + +func Arr_ll(arg1 *int64, arg2 int) (_swig_ret float64) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_arr_ll, _swig_p) + return +} +var _wrap_arr_ull unsafe.Pointer + +func Arr_ull(arg1 *uint64, arg2 int) (_swig_ret float64) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_arr_ull, _swig_p) + return +} +var _wrap_arr_float unsafe.Pointer + +func Arr_float(arg1 *float32, arg2 int) (_swig_ret float64) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_arr_float, _swig_p) + return +} +var _wrap_arr_double unsafe.Pointer + +func Arr_double(arg1 *float64, arg2 int) (_swig_ret float64) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_arr_double, _swig_p) + return +} +var _wrap_ptr_bool unsafe.Pointer + +func Ptr_bool(arg1 *bool, arg2 int) (_swig_ret float64) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_ptr_bool, _swig_p) + return +} +var _wrap_ptr_char unsafe.Pointer + +func Ptr_char(arg1 *byte, arg2 int) (_swig_ret float64) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_ptr_char, _swig_p) + return +} +var _wrap_ptr_schar unsafe.Pointer + +func Ptr_schar(arg1 *int8, arg2 int) (_swig_ret float64) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_ptr_schar, _swig_p) + return +} +var _wrap_ptr_uchar unsafe.Pointer + +func Ptr_uchar(arg1 *byte, arg2 int) (_swig_ret float64) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_ptr_uchar, _swig_p) + return +} +var _wrap_ptr_short unsafe.Pointer + +func Ptr_short(arg1 *int16, arg2 int) (_swig_ret float64) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_ptr_short, _swig_p) + return +} +var _wrap_ptr_ushort unsafe.Pointer + +func Ptr_ushort(arg1 *uint16, arg2 int) (_swig_ret float64) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_ptr_ushort, _swig_p) + return +} +var _wrap_ptr_int unsafe.Pointer + +func Ptr_int(arg1 *int, arg2 int) (_swig_ret float64) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_ptr_int, _swig_p) + return +} +var _wrap_ptr_uint unsafe.Pointer + +func Ptr_uint(arg1 *uint, arg2 int) (_swig_ret float64) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_ptr_uint, _swig_p) + return +} +var _wrap_ptr_long unsafe.Pointer + +func Ptr_long(arg1 *int64, arg2 int) (_swig_ret float64) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_ptr_long, _swig_p) + return +} +var _wrap_ptr_ulong unsafe.Pointer + +func Ptr_ulong(arg1 *uint64, arg2 int) (_swig_ret float64) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_ptr_ulong, _swig_p) + return +} +var _wrap_ptr_ll unsafe.Pointer + +func Ptr_ll(arg1 *int64, arg2 int) (_swig_ret float64) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_ptr_ll, _swig_p) + return +} +var _wrap_ptr_ull unsafe.Pointer + +func Ptr_ull(arg1 *uint64, arg2 int) (_swig_ret float64) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_ptr_ull, _swig_p) + return +} +var _wrap_ptr_float unsafe.Pointer + +func Ptr_float(arg1 *float32, arg2 int) (_swig_ret float64) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_ptr_float, _swig_p) + return +} +var _wrap_ptr_double unsafe.Pointer + +func Ptr_double(arg1 *float64, arg2 int) (_swig_ret float64) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_ptr_double, _swig_p) + return +} + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/arrays_global.go b/Examples/test-suite/go/arrays_global.go new file mode 100644 index 000000000..08b583b8f --- /dev/null +++ b/Examples/test-suite/go/arrays_global.go @@ -0,0 +1,729 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../arrays_global.i + +package arrays_global + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +const ARRAY_LEN int = 2 +type Finger int +var _wrap_One unsafe.Pointer + +func _swig_getOne() (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_One, _swig_p) + return +} +var One int = _swig_getOne() +var _wrap_Two unsafe.Pointer + +func _swig_getTwo() (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_Two, _swig_p) + return +} +var Two int = _swig_getTwo() +var _wrap_Three unsafe.Pointer + +func _swig_getThree() (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_Three, _swig_p) + return +} +var Three int = _swig_getThree() +var _wrap_Four unsafe.Pointer + +func _swig_getFour() (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_Four, _swig_p) + return +} +var Four int = _swig_getFour() +var _wrap_Five unsafe.Pointer + +func _swig_getFive() (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_Five, _swig_p) + return +} +var Five int = _swig_getFive() +type SwigcptrSimpleStruct uintptr + +func (p SwigcptrSimpleStruct) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrSimpleStruct) SwigIsSimpleStruct() { +} + +var _wrap_SimpleStruct_double_field_set unsafe.Pointer + +func _swig_wrap_SimpleStruct_double_field_set(base SwigcptrSimpleStruct, _ float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_SimpleStruct_double_field_set, _swig_p) + return +} + +func (arg1 SwigcptrSimpleStruct) SetDouble_field(arg2 float64) { + _swig_wrap_SimpleStruct_double_field_set(arg1, arg2) +} + +var _wrap_SimpleStruct_double_field_get unsafe.Pointer + +func _swig_wrap_SimpleStruct_double_field_get(base SwigcptrSimpleStruct) (_ float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_SimpleStruct_double_field_get, _swig_p) + return +} + +func (arg1 SwigcptrSimpleStruct) GetDouble_field() (_swig_ret float64) { + return _swig_wrap_SimpleStruct_double_field_get(arg1) +} + +var _wrap_new_SimpleStruct unsafe.Pointer + +func _swig_wrap_new_SimpleStruct() (base SwigcptrSimpleStruct) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_SimpleStruct, _swig_p) + return +} + +func NewSimpleStruct() (_swig_ret SimpleStruct) { + return _swig_wrap_new_SimpleStruct() +} + +var _wrap_delete_SimpleStruct unsafe.Pointer + +func _swig_wrap_delete_SimpleStruct(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_SimpleStruct, _swig_p) + return +} + +func DeleteSimpleStruct(arg1 SimpleStruct) { + _swig_wrap_delete_SimpleStruct(arg1.Swigcptr()) +} + +type SimpleStruct interface { + Swigcptr() uintptr + SwigIsSimpleStruct() + SetDouble_field(arg2 float64) + GetDouble_field() (_swig_ret float64) +} + +var _wrap_array_c_set unsafe.Pointer + +func _swig_wrap_array_c_set(base string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_array_c_set, _swig_p) + return +} + +func SetArray_c(arg1 string) { + _swig_wrap_array_c_set(arg1) +} + +var _wrap_array_c_get unsafe.Pointer + +func GetArray_c() (_swig_ret string) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_array_c_get, _swig_p) + return +} +var _wrap_array_sc_set unsafe.Pointer + +func _swig_wrap_array_sc_set(base string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_array_sc_set, _swig_p) + return +} + +func SetArray_sc(arg1 string) { + _swig_wrap_array_sc_set(arg1) +} + +var _wrap_array_sc_get unsafe.Pointer + +func GetArray_sc() (_swig_ret string) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_array_sc_get, _swig_p) + return +} +var _wrap_array_uc_set unsafe.Pointer + +func _swig_wrap_array_uc_set(base string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_array_uc_set, _swig_p) + return +} + +func SetArray_uc(arg1 string) { + _swig_wrap_array_uc_set(arg1) +} + +var _wrap_array_uc_get unsafe.Pointer + +func GetArray_uc() (_swig_ret string) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_array_uc_get, _swig_p) + return +} +var _wrap_array_s_set unsafe.Pointer + +func _swig_wrap_array_s_set(base *int16) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_array_s_set, _swig_p) + return +} + +func SetArray_s(arg1 *int16) { + _swig_wrap_array_s_set(arg1) +} + +var _wrap_array_s_get unsafe.Pointer + +func GetArray_s() (_swig_ret *int16) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_array_s_get, _swig_p) + return +} +var _wrap_array_us_set unsafe.Pointer + +func _swig_wrap_array_us_set(base *uint16) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_array_us_set, _swig_p) + return +} + +func SetArray_us(arg1 *uint16) { + _swig_wrap_array_us_set(arg1) +} + +var _wrap_array_us_get unsafe.Pointer + +func GetArray_us() (_swig_ret *uint16) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_array_us_get, _swig_p) + return +} +var _wrap_array_i_set unsafe.Pointer + +func _swig_wrap_array_i_set(base *int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_array_i_set, _swig_p) + return +} + +func SetArray_i(arg1 *int) { + _swig_wrap_array_i_set(arg1) +} + +var _wrap_array_i_get unsafe.Pointer + +func GetArray_i() (_swig_ret *int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_array_i_get, _swig_p) + return +} +var _wrap_array_ui_set unsafe.Pointer + +func _swig_wrap_array_ui_set(base *uint) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_array_ui_set, _swig_p) + return +} + +func SetArray_ui(arg1 *uint) { + _swig_wrap_array_ui_set(arg1) +} + +var _wrap_array_ui_get unsafe.Pointer + +func GetArray_ui() (_swig_ret *uint) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_array_ui_get, _swig_p) + return +} +var _wrap_array_l_set unsafe.Pointer + +func _swig_wrap_array_l_set(base *int64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_array_l_set, _swig_p) + return +} + +func SetArray_l(arg1 *int64) { + _swig_wrap_array_l_set(arg1) +} + +var _wrap_array_l_get unsafe.Pointer + +func GetArray_l() (_swig_ret *int64) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_array_l_get, _swig_p) + return +} +var _wrap_array_ul_set unsafe.Pointer + +func _swig_wrap_array_ul_set(base *uint64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_array_ul_set, _swig_p) + return +} + +func SetArray_ul(arg1 *uint64) { + _swig_wrap_array_ul_set(arg1) +} + +var _wrap_array_ul_get unsafe.Pointer + +func GetArray_ul() (_swig_ret *uint64) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_array_ul_get, _swig_p) + return +} +var _wrap_array_ll_set unsafe.Pointer + +func _swig_wrap_array_ll_set(base *int64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_array_ll_set, _swig_p) + return +} + +func SetArray_ll(arg1 *int64) { + _swig_wrap_array_ll_set(arg1) +} + +var _wrap_array_ll_get unsafe.Pointer + +func GetArray_ll() (_swig_ret *int64) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_array_ll_get, _swig_p) + return +} +var _wrap_array_f_set unsafe.Pointer + +func _swig_wrap_array_f_set(base *float32) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_array_f_set, _swig_p) + return +} + +func SetArray_f(arg1 *float32) { + _swig_wrap_array_f_set(arg1) +} + +var _wrap_array_f_get unsafe.Pointer + +func GetArray_f() (_swig_ret *float32) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_array_f_get, _swig_p) + return +} +var _wrap_array_d_set unsafe.Pointer + +func _swig_wrap_array_d_set(base *float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_array_d_set, _swig_p) + return +} + +func SetArray_d(arg1 *float64) { + _swig_wrap_array_d_set(arg1) +} + +var _wrap_array_d_get unsafe.Pointer + +func GetArray_d() (_swig_ret *float64) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_array_d_get, _swig_p) + return +} +var _wrap_array_struct_set unsafe.Pointer + +func _swig_wrap_array_struct_set(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_array_struct_set, _swig_p) + return +} + +func SetArray_struct(arg1 SimpleStruct) { + _swig_wrap_array_struct_set(arg1.Swigcptr()) +} + +var _wrap_array_struct_get unsafe.Pointer + +func _swig_wrap_array_struct_get() (base SwigcptrSimpleStruct) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_array_struct_get, _swig_p) + return +} + +func GetArray_struct() (_swig_ret SimpleStruct) { + return _swig_wrap_array_struct_get() +} + +var _wrap_array_structpointers_set unsafe.Pointer + +func _swig_wrap_array_structpointers_set(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_array_structpointers_set, _swig_p) + return +} + +func SetArray_structpointers(arg1 SimpleStruct) { + _swig_wrap_array_structpointers_set(arg1.Swigcptr()) +} + +var _wrap_array_structpointers_get unsafe.Pointer + +func _swig_wrap_array_structpointers_get() (base SwigcptrSimpleStruct) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_array_structpointers_get, _swig_p) + return +} + +func GetArray_structpointers() (_swig_ret SimpleStruct) { + return _swig_wrap_array_structpointers_get() +} + +var _wrap_array_ipointers_set unsafe.Pointer + +func _swig_wrap_array_ipointers_set(base **int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_array_ipointers_set, _swig_p) + return +} + +func SetArray_ipointers(arg1 **int) { + _swig_wrap_array_ipointers_set(arg1) +} + +var _wrap_array_ipointers_get unsafe.Pointer + +func GetArray_ipointers() (_swig_ret **int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_array_ipointers_get, _swig_p) + return +} +var _wrap_array_enum_set unsafe.Pointer + +func _swig_wrap_array_enum_set(base *Finger) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_array_enum_set, _swig_p) + return +} + +func SetArray_enum(arg1 *Finger) { + _swig_wrap_array_enum_set(arg1) +} + +var _wrap_array_enum_get unsafe.Pointer + +func GetArray_enum() (_swig_ret *Finger) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_array_enum_get, _swig_p) + return +} +var _wrap_array_enumpointers_set unsafe.Pointer + +func _swig_wrap_array_enumpointers_set(base **Finger) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_array_enumpointers_set, _swig_p) + return +} + +func SetArray_enumpointers(arg1 **Finger) { + _swig_wrap_array_enumpointers_set(arg1) +} + +var _wrap_array_enumpointers_get unsafe.Pointer + +func GetArray_enumpointers() (_swig_ret **Finger) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_array_enumpointers_get, _swig_p) + return +} +var _wrap_array_const_i_get unsafe.Pointer + +func GetArray_const_i() (_swig_ret *int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_array_const_i_get, _swig_p) + return +} +var _wrap_BeginString_FIX44a_get unsafe.Pointer + +func GetBeginString_FIX44a() (_swig_ret string) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_BeginString_FIX44a_get, _swig_p) + return +} +var _wrap_BeginString_FIX44b_set unsafe.Pointer + +func _swig_wrap_BeginString_FIX44b_set(base string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_BeginString_FIX44b_set, _swig_p) + return +} + +func SetBeginString_FIX44b(arg1 string) { + _swig_wrap_BeginString_FIX44b_set(arg1) +} + +var _wrap_BeginString_FIX44b_get unsafe.Pointer + +func GetBeginString_FIX44b() (_swig_ret string) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_BeginString_FIX44b_get, _swig_p) + return +} +var _wrap_BeginString_FIX44c_get unsafe.Pointer + +func GetBeginString_FIX44c() (_swig_ret string) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_BeginString_FIX44c_get, _swig_p) + return +} +var _wrap_BeginString_FIX44d_set unsafe.Pointer + +func _swig_wrap_BeginString_FIX44d_set(base string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_BeginString_FIX44d_set, _swig_p) + return +} + +func SetBeginString_FIX44d(arg1 string) { + _swig_wrap_BeginString_FIX44d_set(arg1) +} + +var _wrap_BeginString_FIX44d_get unsafe.Pointer + +func GetBeginString_FIX44d() (_swig_ret string) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_BeginString_FIX44d_get, _swig_p) + return +} +var _wrap_BeginString_FIX44e_set unsafe.Pointer + +func _swig_wrap_BeginString_FIX44e_set(base string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_BeginString_FIX44e_set, _swig_p) + return +} + +func SetBeginString_FIX44e(arg1 string) { + _swig_wrap_BeginString_FIX44e_set(arg1) +} + +var _wrap_BeginString_FIX44e_get unsafe.Pointer + +func GetBeginString_FIX44e() (_swig_ret string) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_BeginString_FIX44e_get, _swig_p) + return +} +var _wrap_BeginString_FIX44f_get unsafe.Pointer + +func GetBeginString_FIX44f() (_swig_ret string) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_BeginString_FIX44f_get, _swig_p) + return +} +var _wrap_test_a__SWIG_0 unsafe.Pointer + +func Test_a__SWIG_0(arg1 string, arg2 string, arg3 string, arg4 string) (_swig_ret string) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_test_a__SWIG_0, _swig_p) + return +} +var _wrap_test_b__SWIG_0 unsafe.Pointer + +func Test_b__SWIG_0(arg1 string, arg2 string) (_swig_ret string) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_test_b__SWIG_0, _swig_p) + return +} +var _wrap_test_a__SWIG_1 unsafe.Pointer + +func Test_a__SWIG_1(arg1 int) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_test_a__SWIG_1, _swig_p) + return +} +func Test_a(a ...interface{}) interface{} { + argc := len(a) + if argc == 1 { + return Test_a__SWIG_1(a[0].(int)) + } + if argc == 4 { + return Test_a__SWIG_0(a[0].(string), a[1].(string), a[2].(string), a[3].(string)) + } + panic("No match for overloaded function call") +} + +var _wrap_test_b__SWIG_1 unsafe.Pointer + +func Test_b__SWIG_1(arg1 int) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_test_b__SWIG_1, _swig_p) + return +} +func Test_b(a ...interface{}) interface{} { + argc := len(a) + if argc == 1 { + return Test_b__SWIG_1(a[0].(int)) + } + if argc == 2 { + return Test_b__SWIG_0(a[0].(string), a[1].(string)) + } + panic("No match for overloaded function call") +} + +type SwigcptrMaterial uintptr + +func (p SwigcptrMaterial) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrMaterial) SwigIsMaterial() { +} + +var _wrap_new_Material unsafe.Pointer + +func _swig_wrap_new_Material() (base SwigcptrMaterial) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Material, _swig_p) + return +} + +func NewMaterial() (_swig_ret Material) { + return _swig_wrap_new_Material() +} + +var _wrap_delete_Material unsafe.Pointer + +func _swig_wrap_delete_Material(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Material, _swig_p) + return +} + +func DeleteMaterial(arg1 Material) { + _swig_wrap_delete_Material(arg1.Swigcptr()) +} + +type Material interface { + Swigcptr() uintptr + SwigIsMaterial() +} + +var _wrap_Size unsafe.Pointer + +func _swig_getSize() (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_Size, _swig_p) + return +} +var Size int = _swig_getSize() +var _wrap_chitMat_set unsafe.Pointer + +func _swig_wrap_chitMat_set(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_chitMat_set, _swig_p) + return +} + +func SetChitMat(arg1 Material) { + _swig_wrap_chitMat_set(arg1.Swigcptr()) +} + +var _wrap_chitMat_get unsafe.Pointer + +func _swig_wrap_chitMat_get() (base SwigcptrMaterial) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_chitMat_get, _swig_p) + return +} + +func GetChitMat() (_swig_ret Material) { + return _swig_wrap_chitMat_get() +} + +var _wrap_hitMat_val_set unsafe.Pointer + +func _swig_wrap_hitMat_val_set(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_hitMat_val_set, _swig_p) + return +} + +func SetHitMat_val(arg1 Material) { + _swig_wrap_hitMat_val_set(arg1.Swigcptr()) +} + +var _wrap_hitMat_val_get unsafe.Pointer + +func _swig_wrap_hitMat_val_get() (base SwigcptrMaterial) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_hitMat_val_get, _swig_p) + return +} + +func GetHitMat_val() (_swig_ret Material) { + return _swig_wrap_hitMat_val_get() +} + +var _wrap_hitMat_set unsafe.Pointer + +func _swig_wrap_hitMat_set(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_hitMat_set, _swig_p) + return +} + +func SetHitMat(arg1 Material) { + _swig_wrap_hitMat_set(arg1.Swigcptr()) +} + +var _wrap_hitMat_get unsafe.Pointer + +func _swig_wrap_hitMat_get() (base SwigcptrMaterial) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_hitMat_get, _swig_p) + return +} + +func GetHitMat() (_swig_ret Material) { + return _swig_wrap_hitMat_get() +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/arrays_global_runme b/Examples/test-suite/go/arrays_global_runme new file mode 100755 index 000000000..d9d05d80a Binary files /dev/null and b/Examples/test-suite/go/arrays_global_runme differ diff --git a/Examples/test-suite/go/arrays_global_twodim.go b/Examples/test-suite/go/arrays_global_twodim.go new file mode 100644 index 000000000..858d2d43e --- /dev/null +++ b/Examples/test-suite/go/arrays_global_twodim.go @@ -0,0 +1,621 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../arrays_global_twodim.i + +package arrays_global_twodim + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +const ARRAY_LEN_X int = 2 +const ARRAY_LEN_Y int = 4 +type Finger int +var _wrap_One unsafe.Pointer + +func _swig_getOne() (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_One, _swig_p) + return +} +var One int = _swig_getOne() +var _wrap_Two unsafe.Pointer + +func _swig_getTwo() (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_Two, _swig_p) + return +} +var Two int = _swig_getTwo() +var _wrap_Three unsafe.Pointer + +func _swig_getThree() (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_Three, _swig_p) + return +} +var Three int = _swig_getThree() +var _wrap_Four unsafe.Pointer + +func _swig_getFour() (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_Four, _swig_p) + return +} +var Four int = _swig_getFour() +var _wrap_Five unsafe.Pointer + +func _swig_getFive() (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_Five, _swig_p) + return +} +var Five int = _swig_getFive() +type SwigcptrSimpleStruct uintptr + +func (p SwigcptrSimpleStruct) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrSimpleStruct) SwigIsSimpleStruct() { +} + +var _wrap_SimpleStruct_double_field_set unsafe.Pointer + +func _swig_wrap_SimpleStruct_double_field_set(base SwigcptrSimpleStruct, _ float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_SimpleStruct_double_field_set, _swig_p) + return +} + +func (arg1 SwigcptrSimpleStruct) SetDouble_field(arg2 float64) { + _swig_wrap_SimpleStruct_double_field_set(arg1, arg2) +} + +var _wrap_SimpleStruct_double_field_get unsafe.Pointer + +func _swig_wrap_SimpleStruct_double_field_get(base SwigcptrSimpleStruct) (_ float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_SimpleStruct_double_field_get, _swig_p) + return +} + +func (arg1 SwigcptrSimpleStruct) GetDouble_field() (_swig_ret float64) { + return _swig_wrap_SimpleStruct_double_field_get(arg1) +} + +var _wrap_new_SimpleStruct unsafe.Pointer + +func _swig_wrap_new_SimpleStruct() (base SwigcptrSimpleStruct) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_SimpleStruct, _swig_p) + return +} + +func NewSimpleStruct() (_swig_ret SimpleStruct) { + return _swig_wrap_new_SimpleStruct() +} + +var _wrap_delete_SimpleStruct unsafe.Pointer + +func _swig_wrap_delete_SimpleStruct(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_SimpleStruct, _swig_p) + return +} + +func DeleteSimpleStruct(arg1 SimpleStruct) { + _swig_wrap_delete_SimpleStruct(arg1.Swigcptr()) +} + +type SimpleStruct interface { + Swigcptr() uintptr + SwigIsSimpleStruct() + SetDouble_field(arg2 float64) + GetDouble_field() (_swig_ret float64) +} + +var _wrap_array_c_set unsafe.Pointer + +func _swig_wrap_array_c_set(base *string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_array_c_set, _swig_p) + return +} + +func SetArray_c(arg1 *string) { + _swig_wrap_array_c_set(arg1) +} + +var _wrap_array_c_get unsafe.Pointer + +func GetArray_c() (_swig_ret *string) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_array_c_get, _swig_p) + return +} +var _wrap_array_sc_set unsafe.Pointer + +func _swig_wrap_array_sc_set(base *string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_array_sc_set, _swig_p) + return +} + +func SetArray_sc(arg1 *string) { + _swig_wrap_array_sc_set(arg1) +} + +var _wrap_array_sc_get unsafe.Pointer + +func GetArray_sc() (_swig_ret *string) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_array_sc_get, _swig_p) + return +} +var _wrap_array_uc_set unsafe.Pointer + +func _swig_wrap_array_uc_set(base *string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_array_uc_set, _swig_p) + return +} + +func SetArray_uc(arg1 *string) { + _swig_wrap_array_uc_set(arg1) +} + +var _wrap_array_uc_get unsafe.Pointer + +func GetArray_uc() (_swig_ret *string) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_array_uc_get, _swig_p) + return +} +var _wrap_array_s_set unsafe.Pointer + +func _swig_wrap_array_s_set(base **int16) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_array_s_set, _swig_p) + return +} + +func SetArray_s(arg1 **int16) { + _swig_wrap_array_s_set(arg1) +} + +var _wrap_array_s_get unsafe.Pointer + +func GetArray_s() (_swig_ret **int16) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_array_s_get, _swig_p) + return +} +var _wrap_array_us_set unsafe.Pointer + +func _swig_wrap_array_us_set(base **uint16) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_array_us_set, _swig_p) + return +} + +func SetArray_us(arg1 **uint16) { + _swig_wrap_array_us_set(arg1) +} + +var _wrap_array_us_get unsafe.Pointer + +func GetArray_us() (_swig_ret **uint16) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_array_us_get, _swig_p) + return +} +var _wrap_array_i_set unsafe.Pointer + +func _swig_wrap_array_i_set(base **int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_array_i_set, _swig_p) + return +} + +func SetArray_i(arg1 **int) { + _swig_wrap_array_i_set(arg1) +} + +var _wrap_array_i_get unsafe.Pointer + +func GetArray_i() (_swig_ret **int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_array_i_get, _swig_p) + return +} +var _wrap_array_ui_set unsafe.Pointer + +func _swig_wrap_array_ui_set(base **uint) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_array_ui_set, _swig_p) + return +} + +func SetArray_ui(arg1 **uint) { + _swig_wrap_array_ui_set(arg1) +} + +var _wrap_array_ui_get unsafe.Pointer + +func GetArray_ui() (_swig_ret **uint) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_array_ui_get, _swig_p) + return +} +var _wrap_array_l_set unsafe.Pointer + +func _swig_wrap_array_l_set(base **int64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_array_l_set, _swig_p) + return +} + +func SetArray_l(arg1 **int64) { + _swig_wrap_array_l_set(arg1) +} + +var _wrap_array_l_get unsafe.Pointer + +func GetArray_l() (_swig_ret **int64) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_array_l_get, _swig_p) + return +} +var _wrap_array_ul_set unsafe.Pointer + +func _swig_wrap_array_ul_set(base **uint64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_array_ul_set, _swig_p) + return +} + +func SetArray_ul(arg1 **uint64) { + _swig_wrap_array_ul_set(arg1) +} + +var _wrap_array_ul_get unsafe.Pointer + +func GetArray_ul() (_swig_ret **uint64) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_array_ul_get, _swig_p) + return +} +var _wrap_array_ll_set unsafe.Pointer + +func _swig_wrap_array_ll_set(base **int64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_array_ll_set, _swig_p) + return +} + +func SetArray_ll(arg1 **int64) { + _swig_wrap_array_ll_set(arg1) +} + +var _wrap_array_ll_get unsafe.Pointer + +func GetArray_ll() (_swig_ret **int64) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_array_ll_get, _swig_p) + return +} +var _wrap_array_f_set unsafe.Pointer + +func _swig_wrap_array_f_set(base **float32) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_array_f_set, _swig_p) + return +} + +func SetArray_f(arg1 **float32) { + _swig_wrap_array_f_set(arg1) +} + +var _wrap_array_f_get unsafe.Pointer + +func GetArray_f() (_swig_ret **float32) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_array_f_get, _swig_p) + return +} +var _wrap_array_d_set unsafe.Pointer + +func _swig_wrap_array_d_set(base **float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_array_d_set, _swig_p) + return +} + +func SetArray_d(arg1 **float64) { + _swig_wrap_array_d_set(arg1) +} + +var _wrap_array_d_get unsafe.Pointer + +func GetArray_d() (_swig_ret **float64) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_array_d_get, _swig_p) + return +} +var _wrap_array_struct_set unsafe.Pointer + +func _swig_wrap_array_struct_set(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_array_struct_set, _swig_p) + return +} + +func SetArray_struct(arg1 SimpleStruct) { + _swig_wrap_array_struct_set(arg1.Swigcptr()) +} + +var _wrap_array_struct_get unsafe.Pointer + +func _swig_wrap_array_struct_get() (base SwigcptrSimpleStruct) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_array_struct_get, _swig_p) + return +} + +func GetArray_struct() (_swig_ret SimpleStruct) { + return _swig_wrap_array_struct_get() +} + +var _wrap_array_structpointers_set unsafe.Pointer + +func _swig_wrap_array_structpointers_set(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_array_structpointers_set, _swig_p) + return +} + +func SetArray_structpointers(arg1 SimpleStruct) { + _swig_wrap_array_structpointers_set(arg1.Swigcptr()) +} + +var _wrap_array_structpointers_get unsafe.Pointer + +func _swig_wrap_array_structpointers_get() (base SwigcptrSimpleStruct) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_array_structpointers_get, _swig_p) + return +} + +func GetArray_structpointers() (_swig_ret SimpleStruct) { + return _swig_wrap_array_structpointers_get() +} + +var _wrap_array_ipointers_set unsafe.Pointer + +func _swig_wrap_array_ipointers_set(base ***int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_array_ipointers_set, _swig_p) + return +} + +func SetArray_ipointers(arg1 ***int) { + _swig_wrap_array_ipointers_set(arg1) +} + +var _wrap_array_ipointers_get unsafe.Pointer + +func GetArray_ipointers() (_swig_ret ***int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_array_ipointers_get, _swig_p) + return +} +var _wrap_array_enum_set unsafe.Pointer + +func _swig_wrap_array_enum_set(base **Finger) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_array_enum_set, _swig_p) + return +} + +func SetArray_enum(arg1 **Finger) { + _swig_wrap_array_enum_set(arg1) +} + +var _wrap_array_enum_get unsafe.Pointer + +func GetArray_enum() (_swig_ret **Finger) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_array_enum_get, _swig_p) + return +} +var _wrap_array_enumpointers_set unsafe.Pointer + +func _swig_wrap_array_enumpointers_set(base ***Finger) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_array_enumpointers_set, _swig_p) + return +} + +func SetArray_enumpointers(arg1 ***Finger) { + _swig_wrap_array_enumpointers_set(arg1) +} + +var _wrap_array_enumpointers_get unsafe.Pointer + +func GetArray_enumpointers() (_swig_ret ***Finger) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_array_enumpointers_get, _swig_p) + return +} +var _wrap_array_const_i_get unsafe.Pointer + +func GetArray_const_i() (_swig_ret **int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_array_const_i_get, _swig_p) + return +} +var _wrap_fn_taking_arrays unsafe.Pointer + +func _swig_wrap_fn_taking_arrays(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_fn_taking_arrays, _swig_p) + return +} + +func Fn_taking_arrays(arg1 SimpleStruct) { + _swig_wrap_fn_taking_arrays(arg1.Swigcptr()) +} + +var _wrap_get_2d_array unsafe.Pointer + +func Get_2d_array(arg1 **int, arg2 int, arg3 int) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_get_2d_array, _swig_p) + return +} +type SwigcptrMaterial uintptr + +func (p SwigcptrMaterial) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrMaterial) SwigIsMaterial() { +} + +var _wrap_new_Material unsafe.Pointer + +func _swig_wrap_new_Material() (base SwigcptrMaterial) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Material, _swig_p) + return +} + +func NewMaterial() (_swig_ret Material) { + return _swig_wrap_new_Material() +} + +var _wrap_delete_Material unsafe.Pointer + +func _swig_wrap_delete_Material(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Material, _swig_p) + return +} + +func DeleteMaterial(arg1 Material) { + _swig_wrap_delete_Material(arg1.Swigcptr()) +} + +type Material interface { + Swigcptr() uintptr + SwigIsMaterial() +} + +var _wrap_Size unsafe.Pointer + +func _swig_getSize() (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_Size, _swig_p) + return +} +var Size int = _swig_getSize() +var _wrap_chitMat_set unsafe.Pointer + +func _swig_wrap_chitMat_set(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_chitMat_set, _swig_p) + return +} + +func SetChitMat(arg1 Material) { + _swig_wrap_chitMat_set(arg1.Swigcptr()) +} + +var _wrap_chitMat_get unsafe.Pointer + +func _swig_wrap_chitMat_get() (base SwigcptrMaterial) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_chitMat_get, _swig_p) + return +} + +func GetChitMat() (_swig_ret Material) { + return _swig_wrap_chitMat_get() +} + +var _wrap_hitMat_val_set unsafe.Pointer + +func _swig_wrap_hitMat_val_set(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_hitMat_val_set, _swig_p) + return +} + +func SetHitMat_val(arg1 Material) { + _swig_wrap_hitMat_val_set(arg1.Swigcptr()) +} + +var _wrap_hitMat_val_get unsafe.Pointer + +func _swig_wrap_hitMat_val_get() (base SwigcptrMaterial) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_hitMat_val_get, _swig_p) + return +} + +func GetHitMat_val() (_swig_ret Material) { + return _swig_wrap_hitMat_val_get() +} + +var _wrap_hitMat_set unsafe.Pointer + +func _swig_wrap_hitMat_set(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_hitMat_set, _swig_p) + return +} + +func SetHitMat(arg1 Material) { + _swig_wrap_hitMat_set(arg1.Swigcptr()) +} + +var _wrap_hitMat_get unsafe.Pointer + +func _swig_wrap_hitMat_get() (base SwigcptrMaterial) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_hitMat_get, _swig_p) + return +} + +func GetHitMat() (_swig_ret Material) { + return _swig_wrap_hitMat_get() +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/arrays_scope.go b/Examples/test-suite/go/arrays_scope.go new file mode 100644 index 000000000..8c049f286 --- /dev/null +++ b/Examples/test-suite/go/arrays_scope.go @@ -0,0 +1,190 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../arrays_scope.i + +package arrays_scope + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +var _wrap_ASIZE unsafe.Pointer + +func _swig_getASIZE() (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_ASIZE, _swig_p) + return +} +var ASIZE int = _swig_getASIZE() +var _wrap_BBSIZE unsafe.Pointer + +func _swig_getBBSIZE() (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_BBSIZE, _swig_p) + return +} +var BBSIZE int = _swig_getBBSIZE() +type SwigcptrBar uintptr + +func (p SwigcptrBar) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrBar) SwigIsBar() { +} + +var _wrap_CCSIZE_Bar unsafe.Pointer + +func _swig_getBar_CCSIZE_Bar() (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_CCSIZE_Bar, _swig_p) + return +} +var BarCCSIZE int = _swig_getBar_CCSIZE_Bar() +var _wrap_Bar_adata_set unsafe.Pointer + +func _swig_wrap_Bar_adata_set(base SwigcptrBar, _ *int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Bar_adata_set, _swig_p) + return +} + +func (arg1 SwigcptrBar) SetAdata(arg2 *int) { + _swig_wrap_Bar_adata_set(arg1, arg2) +} + +var _wrap_Bar_adata_get unsafe.Pointer + +func _swig_wrap_Bar_adata_get(base SwigcptrBar) (_ *int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Bar_adata_get, _swig_p) + return +} + +func (arg1 SwigcptrBar) GetAdata() (_swig_ret *int) { + return _swig_wrap_Bar_adata_get(arg1) +} + +var _wrap_Bar_bdata_set unsafe.Pointer + +func _swig_wrap_Bar_bdata_set(base SwigcptrBar, _ *int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Bar_bdata_set, _swig_p) + return +} + +func (arg1 SwigcptrBar) SetBdata(arg2 *int) { + _swig_wrap_Bar_bdata_set(arg1, arg2) +} + +var _wrap_Bar_bdata_get unsafe.Pointer + +func _swig_wrap_Bar_bdata_get(base SwigcptrBar) (_ *int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Bar_bdata_get, _swig_p) + return +} + +func (arg1 SwigcptrBar) GetBdata() (_swig_ret *int) { + return _swig_wrap_Bar_bdata_get(arg1) +} + +var _wrap_Bar_cdata_set unsafe.Pointer + +func _swig_wrap_Bar_cdata_set(base SwigcptrBar, _ *int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Bar_cdata_set, _swig_p) + return +} + +func (arg1 SwigcptrBar) SetCdata(arg2 *int) { + _swig_wrap_Bar_cdata_set(arg1, arg2) +} + +var _wrap_Bar_cdata_get unsafe.Pointer + +func _swig_wrap_Bar_cdata_get(base SwigcptrBar) (_ *int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Bar_cdata_get, _swig_p) + return +} + +func (arg1 SwigcptrBar) GetCdata() (_swig_ret *int) { + return _swig_wrap_Bar_cdata_get(arg1) +} + +var _wrap_Bar_blah unsafe.Pointer + +func _swig_wrap_Bar_blah(base SwigcptrBar, _ *int, _ *int, _ *int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Bar_blah, _swig_p) + return +} + +func (arg1 SwigcptrBar) Blah(arg2 *int, arg3 *int, arg4 *int) { + _swig_wrap_Bar_blah(arg1, arg2, arg3, arg4) +} + +var _wrap_new_Bar unsafe.Pointer + +func _swig_wrap_new_Bar() (base SwigcptrBar) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Bar, _swig_p) + return +} + +func NewBar() (_swig_ret Bar) { + return _swig_wrap_new_Bar() +} + +var _wrap_delete_Bar unsafe.Pointer + +func _swig_wrap_delete_Bar(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Bar, _swig_p) + return +} + +func DeleteBar(arg1 Bar) { + _swig_wrap_delete_Bar(arg1.Swigcptr()) +} + +type Bar interface { + Swigcptr() uintptr + SwigIsBar() + SetAdata(arg2 *int) + GetAdata() (_swig_ret *int) + SetBdata(arg2 *int) + GetBdata() (_swig_ret *int) + SetCdata(arg2 *int) + GetCdata() (_swig_ret *int) + Blah(arg2 *int, arg3 *int, arg4 *int) +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/autodoc.go b/Examples/test-suite/go/autodoc.go new file mode 100644 index 000000000..783dc59b1 --- /dev/null +++ b/Examples/test-suite/go/autodoc.go @@ -0,0 +1,933 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../autodoc.i + +package autodoc + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type Hola int +var _wrap_hi unsafe.Pointer + +func _swig_gethi() (_swig_ret Hola) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_hi, _swig_p) + return +} +var Hi Hola = _swig_gethi() +var _wrap_hello unsafe.Pointer + +func _swig_gethello() (_swig_ret Hola) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_hello, _swig_p) + return +} +var Hello Hola = _swig_gethello() +type SwigcptrA uintptr + +func (p SwigcptrA) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrA) SwigIsA() { +} + +var _wrap_new_A unsafe.Pointer + +func _swig_wrap_new_A(base int, _ int16, _ Hola) (_ SwigcptrA) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_A, _swig_p) + return +} + +func NewA(arg1 int, arg2 int16, arg3 Hola) (_swig_ret A) { + return _swig_wrap_new_A(arg1, arg2, arg3) +} + +var _wrap_A_funk unsafe.Pointer + +func _swig_wrap_A_funk(base SwigcptrA, _ int) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_A_funk, _swig_p) + return +} + +func (arg1 SwigcptrA) Funk(arg2 int) (_swig_ret int) { + return _swig_wrap_A_funk(arg1, arg2) +} + +var _wrap_A_func0 unsafe.Pointer + +func _swig_wrap_A_func0(base SwigcptrA, _ int16, _ int) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_A_func0, _swig_p) + return +} + +func (arg1 SwigcptrA) Func0(arg2 int16, arg3 int) (_swig_ret int) { + return _swig_wrap_A_func0(arg1, arg2, arg3) +} + +var _wrap_A_func1 unsafe.Pointer + +func _swig_wrap_A_func1(base SwigcptrA, _ int16, _ int) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_A_func1, _swig_p) + return +} + +func (arg1 SwigcptrA) Func1(arg2 int16, arg3 int) (_swig_ret int) { + return _swig_wrap_A_func1(arg1, arg2, arg3) +} + +var _wrap_A_func2 unsafe.Pointer + +func _swig_wrap_A_func2(base SwigcptrA, _ int16, _ int) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_A_func2, _swig_p) + return +} + +func (arg1 SwigcptrA) Func2(arg2 int16, arg3 int) (_swig_ret int) { + return _swig_wrap_A_func2(arg1, arg2, arg3) +} + +var _wrap_A_func3 unsafe.Pointer + +func _swig_wrap_A_func3(base SwigcptrA, _ int16, _ int) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_A_func3, _swig_p) + return +} + +func (arg1 SwigcptrA) Func3(arg2 int16, arg3 int) (_swig_ret int) { + return _swig_wrap_A_func3(arg1, arg2, arg3) +} + +var _wrap_A_func0default__SWIG_0 unsafe.Pointer + +func _swig_wrap_A_func0default__SWIG_0(base SwigcptrA, _ uintptr, _ int16, _ int, _ float64) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_A_func0default__SWIG_0, _swig_p) + return +} + +func (arg1 SwigcptrA) Func0default__SWIG_0(arg2 A, arg3 int16, arg4 int, arg5 float64) (_swig_ret int) { + return _swig_wrap_A_func0default__SWIG_0(arg1, arg2.Swigcptr(), arg3, arg4, arg5) +} + +var _wrap_A_func0default__SWIG_1 unsafe.Pointer + +func _swig_wrap_A_func0default__SWIG_1(base SwigcptrA, _ uintptr, _ int16, _ int) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_A_func0default__SWIG_1, _swig_p) + return +} + +func (arg1 SwigcptrA) Func0default__SWIG_1(arg2 A, arg3 int16, arg4 int) (_swig_ret int) { + return _swig_wrap_A_func0default__SWIG_1(arg1, arg2.Swigcptr(), arg3, arg4) +} + +func (p SwigcptrA) Func0default(a ...interface{}) int { + argc := len(a) + if argc == 3 { + return p.Func0default__SWIG_1(a[0].(A), a[1].(int16), a[2].(int)) + } + if argc == 4 { + return p.Func0default__SWIG_0(a[0].(A), a[1].(int16), a[2].(int), a[3].(float64)) + } + panic("No match for overloaded function call") +} + +var _wrap_A_func1default__SWIG_0 unsafe.Pointer + +func _swig_wrap_A_func1default__SWIG_0(base SwigcptrA, _ uintptr, _ int16, _ int, _ float64) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_A_func1default__SWIG_0, _swig_p) + return +} + +func (arg1 SwigcptrA) Func1default__SWIG_0(arg2 A, arg3 int16, arg4 int, arg5 float64) (_swig_ret int) { + return _swig_wrap_A_func1default__SWIG_0(arg1, arg2.Swigcptr(), arg3, arg4, arg5) +} + +var _wrap_A_func1default__SWIG_1 unsafe.Pointer + +func _swig_wrap_A_func1default__SWIG_1(base SwigcptrA, _ uintptr, _ int16, _ int) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_A_func1default__SWIG_1, _swig_p) + return +} + +func (arg1 SwigcptrA) Func1default__SWIG_1(arg2 A, arg3 int16, arg4 int) (_swig_ret int) { + return _swig_wrap_A_func1default__SWIG_1(arg1, arg2.Swigcptr(), arg3, arg4) +} + +func (p SwigcptrA) Func1default(a ...interface{}) int { + argc := len(a) + if argc == 3 { + return p.Func1default__SWIG_1(a[0].(A), a[1].(int16), a[2].(int)) + } + if argc == 4 { + return p.Func1default__SWIG_0(a[0].(A), a[1].(int16), a[2].(int), a[3].(float64)) + } + panic("No match for overloaded function call") +} + +var _wrap_A_func2default__SWIG_0 unsafe.Pointer + +func _swig_wrap_A_func2default__SWIG_0(base SwigcptrA, _ uintptr, _ int16, _ int, _ float64) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_A_func2default__SWIG_0, _swig_p) + return +} + +func (arg1 SwigcptrA) Func2default__SWIG_0(arg2 A, arg3 int16, arg4 int, arg5 float64) (_swig_ret int) { + return _swig_wrap_A_func2default__SWIG_0(arg1, arg2.Swigcptr(), arg3, arg4, arg5) +} + +var _wrap_A_func2default__SWIG_1 unsafe.Pointer + +func _swig_wrap_A_func2default__SWIG_1(base SwigcptrA, _ uintptr, _ int16, _ int) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_A_func2default__SWIG_1, _swig_p) + return +} + +func (arg1 SwigcptrA) Func2default__SWIG_1(arg2 A, arg3 int16, arg4 int) (_swig_ret int) { + return _swig_wrap_A_func2default__SWIG_1(arg1, arg2.Swigcptr(), arg3, arg4) +} + +func (p SwigcptrA) Func2default(a ...interface{}) int { + argc := len(a) + if argc == 3 { + return p.Func2default__SWIG_1(a[0].(A), a[1].(int16), a[2].(int)) + } + if argc == 4 { + return p.Func2default__SWIG_0(a[0].(A), a[1].(int16), a[2].(int), a[3].(float64)) + } + panic("No match for overloaded function call") +} + +var _wrap_A_func3default__SWIG_0 unsafe.Pointer + +func _swig_wrap_A_func3default__SWIG_0(base SwigcptrA, _ uintptr, _ int16, _ int, _ float64) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_A_func3default__SWIG_0, _swig_p) + return +} + +func (arg1 SwigcptrA) Func3default__SWIG_0(arg2 A, arg3 int16, arg4 int, arg5 float64) (_swig_ret int) { + return _swig_wrap_A_func3default__SWIG_0(arg1, arg2.Swigcptr(), arg3, arg4, arg5) +} + +var _wrap_A_func3default__SWIG_1 unsafe.Pointer + +func _swig_wrap_A_func3default__SWIG_1(base SwigcptrA, _ uintptr, _ int16, _ int) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_A_func3default__SWIG_1, _swig_p) + return +} + +func (arg1 SwigcptrA) Func3default__SWIG_1(arg2 A, arg3 int16, arg4 int) (_swig_ret int) { + return _swig_wrap_A_func3default__SWIG_1(arg1, arg2.Swigcptr(), arg3, arg4) +} + +func (p SwigcptrA) Func3default(a ...interface{}) int { + argc := len(a) + if argc == 3 { + return p.Func3default__SWIG_1(a[0].(A), a[1].(int16), a[2].(int)) + } + if argc == 4 { + return p.Func3default__SWIG_0(a[0].(A), a[1].(int16), a[2].(int), a[3].(float64)) + } + panic("No match for overloaded function call") +} + +var _wrap_A_func0static__SWIG_0 unsafe.Pointer + +func _swig_wrap_A_func0static__SWIG_0(base uintptr, _ int16, _ int, _ float64) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_A_func0static__SWIG_0, _swig_p) + return +} + +func AFunc0static__SWIG_0(arg1 A, arg2 int16, arg3 int, arg4 float64) (_swig_ret int) { + return _swig_wrap_A_func0static__SWIG_0(arg1.Swigcptr(), arg2, arg3, arg4) +} + +var _wrap_A_func0static__SWIG_1 unsafe.Pointer + +func _swig_wrap_A_func0static__SWIG_1(base uintptr, _ int16, _ int) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_A_func0static__SWIG_1, _swig_p) + return +} + +func AFunc0static__SWIG_1(arg1 A, arg2 int16, arg3 int) (_swig_ret int) { + return _swig_wrap_A_func0static__SWIG_1(arg1.Swigcptr(), arg2, arg3) +} + +func AFunc0static(a ...interface{}) int { + argc := len(a) + if argc == 3 { + return AFunc0static__SWIG_1(a[0].(A), a[1].(int16), a[2].(int)) + } + if argc == 4 { + return AFunc0static__SWIG_0(a[0].(A), a[1].(int16), a[2].(int), a[3].(float64)) + } + panic("No match for overloaded function call") +} + +var _wrap_A_func1static__SWIG_0 unsafe.Pointer + +func _swig_wrap_A_func1static__SWIG_0(base uintptr, _ int16, _ int, _ float64) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_A_func1static__SWIG_0, _swig_p) + return +} + +func AFunc1static__SWIG_0(arg1 A, arg2 int16, arg3 int, arg4 float64) (_swig_ret int) { + return _swig_wrap_A_func1static__SWIG_0(arg1.Swigcptr(), arg2, arg3, arg4) +} + +var _wrap_A_func1static__SWIG_1 unsafe.Pointer + +func _swig_wrap_A_func1static__SWIG_1(base uintptr, _ int16, _ int) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_A_func1static__SWIG_1, _swig_p) + return +} + +func AFunc1static__SWIG_1(arg1 A, arg2 int16, arg3 int) (_swig_ret int) { + return _swig_wrap_A_func1static__SWIG_1(arg1.Swigcptr(), arg2, arg3) +} + +func AFunc1static(a ...interface{}) int { + argc := len(a) + if argc == 3 { + return AFunc1static__SWIG_1(a[0].(A), a[1].(int16), a[2].(int)) + } + if argc == 4 { + return AFunc1static__SWIG_0(a[0].(A), a[1].(int16), a[2].(int), a[3].(float64)) + } + panic("No match for overloaded function call") +} + +var _wrap_A_func2static__SWIG_0 unsafe.Pointer + +func _swig_wrap_A_func2static__SWIG_0(base uintptr, _ int16, _ int, _ float64) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_A_func2static__SWIG_0, _swig_p) + return +} + +func AFunc2static__SWIG_0(arg1 A, arg2 int16, arg3 int, arg4 float64) (_swig_ret int) { + return _swig_wrap_A_func2static__SWIG_0(arg1.Swigcptr(), arg2, arg3, arg4) +} + +var _wrap_A_func2static__SWIG_1 unsafe.Pointer + +func _swig_wrap_A_func2static__SWIG_1(base uintptr, _ int16, _ int) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_A_func2static__SWIG_1, _swig_p) + return +} + +func AFunc2static__SWIG_1(arg1 A, arg2 int16, arg3 int) (_swig_ret int) { + return _swig_wrap_A_func2static__SWIG_1(arg1.Swigcptr(), arg2, arg3) +} + +func AFunc2static(a ...interface{}) int { + argc := len(a) + if argc == 3 { + return AFunc2static__SWIG_1(a[0].(A), a[1].(int16), a[2].(int)) + } + if argc == 4 { + return AFunc2static__SWIG_0(a[0].(A), a[1].(int16), a[2].(int), a[3].(float64)) + } + panic("No match for overloaded function call") +} + +var _wrap_A_func3static__SWIG_0 unsafe.Pointer + +func _swig_wrap_A_func3static__SWIG_0(base uintptr, _ int16, _ int, _ float64) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_A_func3static__SWIG_0, _swig_p) + return +} + +func AFunc3static__SWIG_0(arg1 A, arg2 int16, arg3 int, arg4 float64) (_swig_ret int) { + return _swig_wrap_A_func3static__SWIG_0(arg1.Swigcptr(), arg2, arg3, arg4) +} + +var _wrap_A_func3static__SWIG_1 unsafe.Pointer + +func _swig_wrap_A_func3static__SWIG_1(base uintptr, _ int16, _ int) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_A_func3static__SWIG_1, _swig_p) + return +} + +func AFunc3static__SWIG_1(arg1 A, arg2 int16, arg3 int) (_swig_ret int) { + return _swig_wrap_A_func3static__SWIG_1(arg1.Swigcptr(), arg2, arg3) +} + +func AFunc3static(a ...interface{}) int { + argc := len(a) + if argc == 3 { + return AFunc3static__SWIG_1(a[0].(A), a[1].(int16), a[2].(int)) + } + if argc == 4 { + return AFunc3static__SWIG_0(a[0].(A), a[1].(int16), a[2].(int), a[3].(float64)) + } + panic("No match for overloaded function call") +} + +var _wrap_A_variable_a_set unsafe.Pointer + +func _swig_wrap_A_variable_a_set(base SwigcptrA, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_A_variable_a_set, _swig_p) + return +} + +func (arg1 SwigcptrA) SetVariable_a(arg2 int) { + _swig_wrap_A_variable_a_set(arg1, arg2) +} + +var _wrap_A_variable_a_get unsafe.Pointer + +func _swig_wrap_A_variable_a_get(base SwigcptrA) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_A_variable_a_get, _swig_p) + return +} + +func (arg1 SwigcptrA) GetVariable_a() (_swig_ret int) { + return _swig_wrap_A_variable_a_get(arg1) +} + +var _wrap_A_variable_b_set unsafe.Pointer + +func _swig_wrap_A_variable_b_set(base SwigcptrA, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_A_variable_b_set, _swig_p) + return +} + +func (arg1 SwigcptrA) SetVariable_b(arg2 int) { + _swig_wrap_A_variable_b_set(arg1, arg2) +} + +var _wrap_A_variable_b_get unsafe.Pointer + +func _swig_wrap_A_variable_b_get(base SwigcptrA) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_A_variable_b_get, _swig_p) + return +} + +func (arg1 SwigcptrA) GetVariable_b() (_swig_ret int) { + return _swig_wrap_A_variable_b_get(arg1) +} + +var _wrap_A_variable_c_set unsafe.Pointer + +func _swig_wrap_A_variable_c_set(base SwigcptrA, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_A_variable_c_set, _swig_p) + return +} + +func (arg1 SwigcptrA) SetVariable_c(arg2 int) { + _swig_wrap_A_variable_c_set(arg1, arg2) +} + +var _wrap_A_variable_c_get unsafe.Pointer + +func _swig_wrap_A_variable_c_get(base SwigcptrA) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_A_variable_c_get, _swig_p) + return +} + +func (arg1 SwigcptrA) GetVariable_c() (_swig_ret int) { + return _swig_wrap_A_variable_c_get(arg1) +} + +var _wrap_A_variable_d_set unsafe.Pointer + +func _swig_wrap_A_variable_d_set(base SwigcptrA, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_A_variable_d_set, _swig_p) + return +} + +func (arg1 SwigcptrA) SetVariable_d(arg2 int) { + _swig_wrap_A_variable_d_set(arg1, arg2) +} + +var _wrap_A_variable_d_get unsafe.Pointer + +func _swig_wrap_A_variable_d_get(base SwigcptrA) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_A_variable_d_get, _swig_p) + return +} + +func (arg1 SwigcptrA) GetVariable_d() (_swig_ret int) { + return _swig_wrap_A_variable_d_get(arg1) +} + +var _wrap_delete_A unsafe.Pointer + +func _swig_wrap_delete_A(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_A, _swig_p) + return +} + +func DeleteA(arg1 A) { + _swig_wrap_delete_A(arg1.Swigcptr()) +} + +type A interface { + Swigcptr() uintptr + SwigIsA() + Funk(arg2 int) (_swig_ret int) + Func0(arg2 int16, arg3 int) (_swig_ret int) + Func1(arg2 int16, arg3 int) (_swig_ret int) + Func2(arg2 int16, arg3 int) (_swig_ret int) + Func3(arg2 int16, arg3 int) (_swig_ret int) + Func0default(a ...interface{}) int + Func1default(a ...interface{}) int + Func2default(a ...interface{}) int + Func3default(a ...interface{}) int + SetVariable_a(arg2 int) + GetVariable_a() (_swig_ret int) + SetVariable_b(arg2 int) + GetVariable_b() (_swig_ret int) + SetVariable_c(arg2 int) + GetVariable_c() (_swig_ret int) + SetVariable_d(arg2 int) + GetVariable_d() (_swig_ret int) +} + +type SwigcptrB uintptr + +func (p SwigcptrB) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrB) SwigIsB() { +} + +var _wrap_new_B unsafe.Pointer + +func _swig_wrap_new_B(base int, _ int, _ Hola) (_ SwigcptrB) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_B, _swig_p) + return +} + +func NewB(arg1 int, arg2 int, arg3 Hola) (_swig_ret B) { + return _swig_wrap_new_B(arg1, arg2, arg3) +} + +var _wrap_B_funk unsafe.Pointer + +func _swig_wrap_B_funk(base SwigcptrB, _ int, _ int) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_B_funk, _swig_p) + return +} + +func (arg1 SwigcptrB) Funk(arg2 int, arg3 int) (_swig_ret int) { + return _swig_wrap_B_funk(arg1, arg2, arg3) +} + +var _wrap_delete_B unsafe.Pointer + +func _swig_wrap_delete_B(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_B, _swig_p) + return +} + +func DeleteB(arg1 B) { + _swig_wrap_delete_B(arg1.Swigcptr()) +} + +type B interface { + Swigcptr() uintptr + SwigIsB() + Funk(arg2 int, arg3 int) (_swig_ret int) +} + +type SwigcptrC uintptr + +func (p SwigcptrC) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrC) SwigIsC() { +} + +var _wrap_new_C unsafe.Pointer + +func _swig_wrap_new_C(base int, _ int, _ Hola) (_ SwigcptrC) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_C, _swig_p) + return +} + +func NewC(arg1 int, arg2 int, arg3 Hola) (_swig_ret C) { + return _swig_wrap_new_C(arg1, arg2, arg3) +} + +var _wrap_delete_C unsafe.Pointer + +func _swig_wrap_delete_C(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_C, _swig_p) + return +} + +func DeleteC(arg1 C) { + _swig_wrap_delete_C(arg1.Swigcptr()) +} + +type C interface { + Swigcptr() uintptr + SwigIsC() +} + +type SwigcptrD uintptr + +func (p SwigcptrD) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrD) SwigIsD() { +} + +var _wrap_new_D unsafe.Pointer + +func _swig_wrap_new_D(base int, _ int, _ Hola) (_ SwigcptrD) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_D, _swig_p) + return +} + +func NewD(arg1 int, arg2 int, arg3 Hola) (_swig_ret D) { + return _swig_wrap_new_D(arg1, arg2, arg3) +} + +var _wrap_delete_D unsafe.Pointer + +func _swig_wrap_delete_D(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_D, _swig_p) + return +} + +func DeleteD(arg1 D) { + _swig_wrap_delete_D(arg1.Swigcptr()) +} + +type D interface { + Swigcptr() uintptr + SwigIsD() +} + +type SwigcptrE uintptr + +func (p SwigcptrE) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrE) SwigIsE() { +} + +var _wrap_new_E unsafe.Pointer + +func _swig_wrap_new_E(base int, _ int, _ Hola) (_ SwigcptrE) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_E, _swig_p) + return +} + +func NewE(arg1 int, arg2 int, arg3 Hola) (_swig_ret E) { + return _swig_wrap_new_E(arg1, arg2, arg3) +} + +var _wrap_delete_E unsafe.Pointer + +func _swig_wrap_delete_E(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_E, _swig_p) + return +} + +func DeleteE(arg1 E) { + _swig_wrap_delete_E(arg1.Swigcptr()) +} + +type E interface { + Swigcptr() uintptr + SwigIsE() +} + +type SwigcptrF uintptr + +func (p SwigcptrF) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrF) SwigIsF() { +} + +var _wrap_new_F unsafe.Pointer + +func _swig_wrap_new_F(base int, _ int, _ Hola) (_ SwigcptrF) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_F, _swig_p) + return +} + +func NewF(arg1 int, arg2 int, arg3 Hola) (_swig_ret F) { + return _swig_wrap_new_F(arg1, arg2, arg3) +} + +var _wrap_delete_F unsafe.Pointer + +func _swig_wrap_delete_F(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_F, _swig_p) + return +} + +func DeleteF(arg1 F) { + _swig_wrap_delete_F(arg1.Swigcptr()) +} + +type F interface { + Swigcptr() uintptr + SwigIsF() +} + +var _wrap_funk unsafe.Pointer + +func _swig_wrap_funk(base uintptr, _ int16, _ int, _ int) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_funk, _swig_p) + return +} + +func Funk(arg1 A, arg2 int16, arg3 int, arg4 int) (_swig_ret int) { + return _swig_wrap_funk(arg1.Swigcptr(), arg2, arg3, arg4) +} + +var _wrap_funkdefaults__SWIG_0 unsafe.Pointer + +func _swig_wrap_funkdefaults__SWIG_0(base uintptr, _ int16, _ int, _ int, _ float64) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_funkdefaults__SWIG_0, _swig_p) + return +} + +func Funkdefaults__SWIG_0(arg1 A, arg2 int16, arg3 int, arg4 int, arg5 float64) (_swig_ret int) { + return _swig_wrap_funkdefaults__SWIG_0(arg1.Swigcptr(), arg2, arg3, arg4, arg5) +} + +var _wrap_funkdefaults__SWIG_1 unsafe.Pointer + +func _swig_wrap_funkdefaults__SWIG_1(base uintptr, _ int16, _ int, _ int) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_funkdefaults__SWIG_1, _swig_p) + return +} + +func Funkdefaults__SWIG_1(arg1 A, arg2 int16, arg3 int, arg4 int) (_swig_ret int) { + return _swig_wrap_funkdefaults__SWIG_1(arg1.Swigcptr(), arg2, arg3, arg4) +} + +func Funkdefaults(a ...interface{}) int { + argc := len(a) + if argc == 4 { + return Funkdefaults__SWIG_1(a[0].(A), a[1].(int16), a[2].(int), a[3].(int)) + } + if argc == 5 { + return Funkdefaults__SWIG_0(a[0].(A), a[1].(int16), a[2].(int), a[3].(int), a[4].(float64)) + } + panic("No match for overloaded function call") +} + +var _wrap_func_input unsafe.Pointer + +func Func_input(arg1 int) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_func_input, _swig_p) + return +} +var _wrap_func_output unsafe.Pointer + +func Func_output(arg1 []int) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_func_output, _swig_p) + return +} +var _wrap_func_inout unsafe.Pointer + +func Func_inout(arg1 []int) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_func_inout, _swig_p) + return +} +var _wrap_FUNC_CB_CALLBACK unsafe.Pointer + +func _swig_getFUNC_CB_CALLBACK() (_swig_ret _swig_fnptr) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_FUNC_CB_CALLBACK, _swig_p) + return +} +var FUNC_CB_CALLBACK _swig_fnptr = _swig_getFUNC_CB_CALLBACK() +var _wrap_func_cb unsafe.Pointer + +func Func_cb(arg1 int, arg2 int) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_func_cb, _swig_p) + return +} +type SwigcptrS uintptr + +func (p SwigcptrS) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrS) SwigIsS() { +} + +var _wrap_S_a_set unsafe.Pointer + +func _swig_wrap_S_a_set(base SwigcptrS, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_S_a_set, _swig_p) + return +} + +func (arg1 SwigcptrS) SetA(arg2 int) { + _swig_wrap_S_a_set(arg1, arg2) +} + +var _wrap_S_a_get unsafe.Pointer + +func _swig_wrap_S_a_get(base SwigcptrS) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_S_a_get, _swig_p) + return +} + +func (arg1 SwigcptrS) GetA() (_swig_ret int) { + return _swig_wrap_S_a_get(arg1) +} + +var _wrap_S_b_set unsafe.Pointer + +func _swig_wrap_S_b_set(base SwigcptrS, _ byte) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_S_b_set, _swig_p) + return +} + +func (arg1 SwigcptrS) SetB(arg2 byte) { + _swig_wrap_S_b_set(arg1, arg2) +} + +var _wrap_S_b_get unsafe.Pointer + +func _swig_wrap_S_b_get(base SwigcptrS) (_ byte) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_S_b_get, _swig_p) + return +} + +func (arg1 SwigcptrS) GetB() (_swig_ret byte) { + return _swig_wrap_S_b_get(arg1) +} + +var _wrap_new_S unsafe.Pointer + +func _swig_wrap_new_S() (base SwigcptrS) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_S, _swig_p) + return +} + +func NewS() (_swig_ret S) { + return _swig_wrap_new_S() +} + +var _wrap_delete_S unsafe.Pointer + +func _swig_wrap_delete_S(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_S, _swig_p) + return +} + +func DeleteS(arg1 S) { + _swig_wrap_delete_S(arg1.Swigcptr()) +} + +type S interface { + Swigcptr() uintptr + SwigIsS() + SetA(arg2 int) + GetA() (_swig_ret int) + SetB(arg2 byte) + GetB() (_swig_ret byte) +} + +var _wrap_banana unsafe.Pointer + +func _swig_wrap_banana(base uintptr, _ uintptr, _ int, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_banana, _swig_p) + return +} + +func Banana(arg1 S, arg2 S, arg3 int, arg4 int) { + _swig_wrap_banana(arg1.Swigcptr(), arg2.Swigcptr(), arg3, arg4) +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/bloody_hell.go b/Examples/test-suite/go/bloody_hell.go new file mode 100644 index 000000000..563fbe094 --- /dev/null +++ b/Examples/test-suite/go/bloody_hell.go @@ -0,0 +1,102 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../bloody_hell.i + +package bloody_hell + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +const KMaxIOCTLSpaceParmsSize int = 128 +type SwigcptrSM_CHANNEL_IX_DUMP_PARMS uintptr + +func (p SwigcptrSM_CHANNEL_IX_DUMP_PARMS) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrSM_CHANNEL_IX_DUMP_PARMS) SwigIsSM_CHANNEL_IX_DUMP_PARMS() { +} + +var _wrap_SM_CHANNEL_IX_DUMP_PARMS_data_set unsafe.Pointer + +func _swig_wrap_SM_CHANNEL_IX_DUMP_PARMS_data_set(base SwigcptrSM_CHANNEL_IX_DUMP_PARMS, _ *uint) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_SM_CHANNEL_IX_DUMP_PARMS_data_set, _swig_p) + return +} + +func (arg1 SwigcptrSM_CHANNEL_IX_DUMP_PARMS) SetData(arg2 *uint) { + _swig_wrap_SM_CHANNEL_IX_DUMP_PARMS_data_set(arg1, arg2) +} + +var _wrap_SM_CHANNEL_IX_DUMP_PARMS_data_get unsafe.Pointer + +func _swig_wrap_SM_CHANNEL_IX_DUMP_PARMS_data_get(base SwigcptrSM_CHANNEL_IX_DUMP_PARMS) (_ *uint) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_SM_CHANNEL_IX_DUMP_PARMS_data_get, _swig_p) + return +} + +func (arg1 SwigcptrSM_CHANNEL_IX_DUMP_PARMS) GetData() (_swig_ret *uint) { + return _swig_wrap_SM_CHANNEL_IX_DUMP_PARMS_data_get(arg1) +} + +var _wrap_new_SM_CHANNEL_IX_DUMP_PARMS unsafe.Pointer + +func _swig_wrap_new_SM_CHANNEL_IX_DUMP_PARMS() (base SwigcptrSM_CHANNEL_IX_DUMP_PARMS) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_SM_CHANNEL_IX_DUMP_PARMS, _swig_p) + return +} + +func NewSM_CHANNEL_IX_DUMP_PARMS() (_swig_ret SM_CHANNEL_IX_DUMP_PARMS) { + return _swig_wrap_new_SM_CHANNEL_IX_DUMP_PARMS() +} + +var _wrap_delete_SM_CHANNEL_IX_DUMP_PARMS unsafe.Pointer + +func _swig_wrap_delete_SM_CHANNEL_IX_DUMP_PARMS(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_SM_CHANNEL_IX_DUMP_PARMS, _swig_p) + return +} + +func DeleteSM_CHANNEL_IX_DUMP_PARMS(arg1 SM_CHANNEL_IX_DUMP_PARMS) { + _swig_wrap_delete_SM_CHANNEL_IX_DUMP_PARMS(arg1.Swigcptr()) +} + +type SM_CHANNEL_IX_DUMP_PARMS interface { + Swigcptr() uintptr + SwigIsSM_CHANNEL_IX_DUMP_PARMS() + SetData(arg2 *uint) + GetData() (_swig_ret *uint) +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/bom_utf8.go b/Examples/test-suite/go/bom_utf8.go new file mode 100644 index 000000000..9922ea112 --- /dev/null +++ b/Examples/test-suite/go/bom_utf8.go @@ -0,0 +1,101 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../bom_utf8.i + +package bom_utf8 + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrNotALotHere uintptr + +func (p SwigcptrNotALotHere) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrNotALotHere) SwigIsNotALotHere() { +} + +var _wrap_NotALotHere_n_set unsafe.Pointer + +func _swig_wrap_NotALotHere_n_set(base SwigcptrNotALotHere, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_NotALotHere_n_set, _swig_p) + return +} + +func (arg1 SwigcptrNotALotHere) SetN(arg2 int) { + _swig_wrap_NotALotHere_n_set(arg1, arg2) +} + +var _wrap_NotALotHere_n_get unsafe.Pointer + +func _swig_wrap_NotALotHere_n_get(base SwigcptrNotALotHere) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_NotALotHere_n_get, _swig_p) + return +} + +func (arg1 SwigcptrNotALotHere) GetN() (_swig_ret int) { + return _swig_wrap_NotALotHere_n_get(arg1) +} + +var _wrap_new_NotALotHere unsafe.Pointer + +func _swig_wrap_new_NotALotHere() (base SwigcptrNotALotHere) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_NotALotHere, _swig_p) + return +} + +func NewNotALotHere() (_swig_ret NotALotHere) { + return _swig_wrap_new_NotALotHere() +} + +var _wrap_delete_NotALotHere unsafe.Pointer + +func _swig_wrap_delete_NotALotHere(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_NotALotHere, _swig_p) + return +} + +func DeleteNotALotHere(arg1 NotALotHere) { + _swig_wrap_delete_NotALotHere(arg1.Swigcptr()) +} + +type NotALotHere interface { + Swigcptr() uintptr + SwigIsNotALotHere() + SetN(arg2 int) + GetN() (_swig_ret int) +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/bools.go b/Examples/test-suite/go/bools.go new file mode 100644 index 000000000..b5a5caef3 --- /dev/null +++ b/Examples/test-suite/go/bools.go @@ -0,0 +1,370 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../bools.i + +package bools + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +const Constbool bool = false +var _wrap_bool1_set unsafe.Pointer + +func _swig_wrap_bool1_set(base bool) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_bool1_set, _swig_p) + return +} + +func SetBool1(arg1 bool) { + _swig_wrap_bool1_set(arg1) +} + +var _wrap_bool1_get unsafe.Pointer + +func GetBool1() (_swig_ret bool) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_bool1_get, _swig_p) + return +} +var _wrap_bool2_set unsafe.Pointer + +func _swig_wrap_bool2_set(base bool) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_bool2_set, _swig_p) + return +} + +func SetBool2(arg1 bool) { + _swig_wrap_bool2_set(arg1) +} + +var _wrap_bool2_get unsafe.Pointer + +func GetBool2() (_swig_ret bool) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_bool2_get, _swig_p) + return +} +var _wrap_pbool_set unsafe.Pointer + +func _swig_wrap_pbool_set(base *bool) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_pbool_set, _swig_p) + return +} + +func SetPbool(arg1 *bool) { + _swig_wrap_pbool_set(arg1) +} + +var _wrap_pbool_get unsafe.Pointer + +func GetPbool() (_swig_ret *bool) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_pbool_get, _swig_p) + return +} +var _wrap_rbool_set unsafe.Pointer + +func _swig_wrap_rbool_set(base *bool) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_rbool_set, _swig_p) + return +} + +func SetRbool(arg1 *bool) { + _swig_wrap_rbool_set(arg1) +} + +var _wrap_rbool_get unsafe.Pointer + +func GetRbool() (_swig_ret *bool) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_rbool_get, _swig_p) + return +} +var _wrap_const_pbool_set unsafe.Pointer + +func _swig_wrap_const_pbool_set(base *bool) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_const_pbool_set, _swig_p) + return +} + +func SetConst_pbool(arg1 *bool) { + _swig_wrap_const_pbool_set(arg1) +} + +var _wrap_const_pbool_get unsafe.Pointer + +func GetConst_pbool() (_swig_ret *bool) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_const_pbool_get, _swig_p) + return +} +var _wrap_const_rbool_get unsafe.Pointer + +func GetConst_rbool() (_swig_ret bool) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_const_rbool_get, _swig_p) + return +} +var _wrap_eax unsafe.Pointer + +func Eax() (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_eax, _swig_p) + return +} +var _wrap_bo unsafe.Pointer + +func Bo(arg1 bool) (_swig_ret bool) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_bo, _swig_p) + return +} +var _wrap_rbo unsafe.Pointer + +func Rbo(arg1 *bool) (_swig_ret *bool) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_rbo, _swig_p) + return +} +var _wrap_pbo unsafe.Pointer + +func Pbo(arg1 *bool) (_swig_ret *bool) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_pbo, _swig_p) + return +} +var _wrap_const_rbo unsafe.Pointer + +func Const_rbo(arg1 bool) (_swig_ret bool) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_const_rbo, _swig_p) + return +} +var _wrap_const_pbo unsafe.Pointer + +func Const_pbo(arg1 *bool) (_swig_ret *bool) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_const_pbo, _swig_p) + return +} +var _wrap_value unsafe.Pointer + +func Value(arg1 *bool) (_swig_ret bool) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_value, _swig_p) + return +} +type SwigcptrBoolStructure uintptr + +func (p SwigcptrBoolStructure) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrBoolStructure) SwigIsBoolStructure() { +} + +var _wrap_BoolStructure_m_bool1_set unsafe.Pointer + +func _swig_wrap_BoolStructure_m_bool1_set(base SwigcptrBoolStructure, _ bool) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_BoolStructure_m_bool1_set, _swig_p) + return +} + +func (arg1 SwigcptrBoolStructure) SetM_bool1(arg2 bool) { + _swig_wrap_BoolStructure_m_bool1_set(arg1, arg2) +} + +var _wrap_BoolStructure_m_bool1_get unsafe.Pointer + +func _swig_wrap_BoolStructure_m_bool1_get(base SwigcptrBoolStructure) (_ bool) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_BoolStructure_m_bool1_get, _swig_p) + return +} + +func (arg1 SwigcptrBoolStructure) GetM_bool1() (_swig_ret bool) { + return _swig_wrap_BoolStructure_m_bool1_get(arg1) +} + +var _wrap_BoolStructure_m_bool2_set unsafe.Pointer + +func _swig_wrap_BoolStructure_m_bool2_set(base SwigcptrBoolStructure, _ bool) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_BoolStructure_m_bool2_set, _swig_p) + return +} + +func (arg1 SwigcptrBoolStructure) SetM_bool2(arg2 bool) { + _swig_wrap_BoolStructure_m_bool2_set(arg1, arg2) +} + +var _wrap_BoolStructure_m_bool2_get unsafe.Pointer + +func _swig_wrap_BoolStructure_m_bool2_get(base SwigcptrBoolStructure) (_ bool) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_BoolStructure_m_bool2_get, _swig_p) + return +} + +func (arg1 SwigcptrBoolStructure) GetM_bool2() (_swig_ret bool) { + return _swig_wrap_BoolStructure_m_bool2_get(arg1) +} + +var _wrap_BoolStructure_m_pbool_set unsafe.Pointer + +func _swig_wrap_BoolStructure_m_pbool_set(base SwigcptrBoolStructure, _ *bool) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_BoolStructure_m_pbool_set, _swig_p) + return +} + +func (arg1 SwigcptrBoolStructure) SetM_pbool(arg2 *bool) { + _swig_wrap_BoolStructure_m_pbool_set(arg1, arg2) +} + +var _wrap_BoolStructure_m_pbool_get unsafe.Pointer + +func _swig_wrap_BoolStructure_m_pbool_get(base SwigcptrBoolStructure) (_ *bool) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_BoolStructure_m_pbool_get, _swig_p) + return +} + +func (arg1 SwigcptrBoolStructure) GetM_pbool() (_swig_ret *bool) { + return _swig_wrap_BoolStructure_m_pbool_get(arg1) +} + +var _wrap_BoolStructure_m_rbool_set unsafe.Pointer + +func _swig_wrap_BoolStructure_m_rbool_set(base SwigcptrBoolStructure, _ *bool) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_BoolStructure_m_rbool_set, _swig_p) + return +} + +func (arg1 SwigcptrBoolStructure) SetM_rbool(arg2 *bool) { + _swig_wrap_BoolStructure_m_rbool_set(arg1, arg2) +} + +var _wrap_BoolStructure_m_rbool_get unsafe.Pointer + +func _swig_wrap_BoolStructure_m_rbool_get(base SwigcptrBoolStructure) (_ *bool) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_BoolStructure_m_rbool_get, _swig_p) + return +} + +func (arg1 SwigcptrBoolStructure) GetM_rbool() (_swig_ret *bool) { + return _swig_wrap_BoolStructure_m_rbool_get(arg1) +} + +var _wrap_BoolStructure_m_const_pbool_set unsafe.Pointer + +func _swig_wrap_BoolStructure_m_const_pbool_set(base SwigcptrBoolStructure, _ *bool) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_BoolStructure_m_const_pbool_set, _swig_p) + return +} + +func (arg1 SwigcptrBoolStructure) SetM_const_pbool(arg2 *bool) { + _swig_wrap_BoolStructure_m_const_pbool_set(arg1, arg2) +} + +var _wrap_BoolStructure_m_const_pbool_get unsafe.Pointer + +func _swig_wrap_BoolStructure_m_const_pbool_get(base SwigcptrBoolStructure) (_ *bool) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_BoolStructure_m_const_pbool_get, _swig_p) + return +} + +func (arg1 SwigcptrBoolStructure) GetM_const_pbool() (_swig_ret *bool) { + return _swig_wrap_BoolStructure_m_const_pbool_get(arg1) +} + +var _wrap_BoolStructure_m_const_rbool_get unsafe.Pointer + +func _swig_wrap_BoolStructure_m_const_rbool_get(base SwigcptrBoolStructure) (_ bool) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_BoolStructure_m_const_rbool_get, _swig_p) + return +} + +func (arg1 SwigcptrBoolStructure) GetM_const_rbool() (_swig_ret bool) { + return _swig_wrap_BoolStructure_m_const_rbool_get(arg1) +} + +var _wrap_new_BoolStructure unsafe.Pointer + +func _swig_wrap_new_BoolStructure() (base SwigcptrBoolStructure) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_BoolStructure, _swig_p) + return +} + +func NewBoolStructure() (_swig_ret BoolStructure) { + return _swig_wrap_new_BoolStructure() +} + +var _wrap_delete_BoolStructure unsafe.Pointer + +func _swig_wrap_delete_BoolStructure(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_BoolStructure, _swig_p) + return +} + +func DeleteBoolStructure(arg1 BoolStructure) { + _swig_wrap_delete_BoolStructure(arg1.Swigcptr()) +} + +type BoolStructure interface { + Swigcptr() uintptr + SwigIsBoolStructure() + SetM_bool1(arg2 bool) + GetM_bool1() (_swig_ret bool) + SetM_bool2(arg2 bool) + GetM_bool2() (_swig_ret bool) + SetM_pbool(arg2 *bool) + GetM_pbool() (_swig_ret *bool) + SetM_rbool(arg2 *bool) + GetM_rbool() (_swig_ret *bool) + SetM_const_pbool(arg2 *bool) + GetM_const_pbool() (_swig_ret *bool) + GetM_const_rbool() (_swig_ret bool) +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/c_delete.go b/Examples/test-suite/go/c_delete.go new file mode 100644 index 000000000..5e98d64a5 --- /dev/null +++ b/Examples/test-suite/go/c_delete.go @@ -0,0 +1,120 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../c_delete.i + +package c_delete + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrDelete uintptr + +func (p SwigcptrDelete) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrDelete) SwigIsDelete() { +} + +var _wrap_delete_delete_set unsafe.Pointer + +func _swig_wrap_delete_delete_set(base SwigcptrDelete, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_delete_set, _swig_p) + return +} + +func (arg1 SwigcptrDelete) SetDelete(arg2 int) { + _swig_wrap_delete_delete_set(arg1, arg2) +} + +var _wrap_delete_delete_get unsafe.Pointer + +func _swig_wrap_delete_delete_get(base SwigcptrDelete) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_delete_get, _swig_p) + return +} + +func (arg1 SwigcptrDelete) GetDelete() (_swig_ret int) { + return _swig_wrap_delete_delete_get(arg1) +} + +var _wrap_new_DeleteGlobalVariable unsafe.Pointer + +func _swig_wrap_new_DeleteGlobalVariable() (base SwigcptrDelete) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_DeleteGlobalVariable, _swig_p) + return +} + +func NewDeleteGlobalVariable() (_swig_ret Delete) { + return _swig_wrap_new_DeleteGlobalVariable() +} + +var _wrap_delete_delete unsafe.Pointer + +func _swig_wrap_delete_delete(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_delete, _swig_p) + return +} + +func DeleteDelete(arg1 Delete) { + _swig_wrap_delete_delete(arg1.Swigcptr()) +} + +type Delete interface { + Swigcptr() uintptr + SwigIsDelete() + SetDelete(arg2 int) + GetDelete() (_swig_ret int) +} + +var _wrap_DeleteGlobalVariable_set unsafe.Pointer + +func _swig_wrap_DeleteGlobalVariable_set(base int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_DeleteGlobalVariable_set, _swig_p) + return +} + +func SetDeleteGlobalVariable(arg1 int) { + _swig_wrap_DeleteGlobalVariable_set(arg1) +} + +var _wrap_DeleteGlobalVariable_get unsafe.Pointer + +func GetDeleteGlobalVariable() (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_DeleteGlobalVariable_get, _swig_p) + return +} + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/c_delete_function.go b/Examples/test-suite/go/c_delete_function.go new file mode 100644 index 000000000..644a6f740 --- /dev/null +++ b/Examples/test-suite/go/c_delete_function.go @@ -0,0 +1,36 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../c_delete_function.i + +package c_delete_function + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +var _wrap_delete unsafe.Pointer + +func Delete(arg1 float64) (_swig_ret float64) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_delete, _swig_p) + return +} + diff --git a/Examples/test-suite/go/cast_operator.go b/Examples/test-suite/go/cast_operator.go new file mode 100644 index 000000000..af3cae475 --- /dev/null +++ b/Examples/test-suite/go/cast_operator.go @@ -0,0 +1,88 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../cast_operator.i + +package cast_operator + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrA uintptr + +func (p SwigcptrA) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrA) SwigIsA() { +} + +var _wrap_A_tochar unsafe.Pointer + +func _swig_wrap_A_tochar(base SwigcptrA) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_A_tochar, _swig_p) + return +} + +func (arg1 SwigcptrA) Tochar() (_swig_ret string) { + return _swig_wrap_A_tochar(arg1) +} + +var _wrap_new_A unsafe.Pointer + +func _swig_wrap_new_A() (base SwigcptrA) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_A, _swig_p) + return +} + +func NewA() (_swig_ret A) { + return _swig_wrap_new_A() +} + +var _wrap_delete_A unsafe.Pointer + +func _swig_wrap_delete_A(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_A, _swig_p) + return +} + +func DeleteA(arg1 A) { + _swig_wrap_delete_A(arg1.Swigcptr()) +} + +type A interface { + Swigcptr() uintptr + SwigIsA() + Tochar() (_swig_ret string) +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/casts.go b/Examples/test-suite/go/casts.go new file mode 100644 index 000000000..deecb8ce7 --- /dev/null +++ b/Examples/test-suite/go/casts.go @@ -0,0 +1,148 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../casts.i + +package casts + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrA uintptr + +func (p SwigcptrA) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrA) SwigIsA() { +} + +var _wrap_new_A unsafe.Pointer + +func _swig_wrap_new_A() (base SwigcptrA) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_A, _swig_p) + return +} + +func NewA() (_swig_ret A) { + return _swig_wrap_new_A() +} + +var _wrap_A_hello unsafe.Pointer + +func _swig_wrap_A_hello(base SwigcptrA) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_A_hello, _swig_p) + return +} + +func (arg1 SwigcptrA) Hello() { + _swig_wrap_A_hello(arg1) +} + +var _wrap_delete_A unsafe.Pointer + +func _swig_wrap_delete_A(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_A, _swig_p) + return +} + +func DeleteA(arg1 A) { + _swig_wrap_delete_A(arg1.Swigcptr()) +} + +type A interface { + Swigcptr() uintptr + SwigIsA() + Hello() +} + +type SwigcptrB uintptr + +func (p SwigcptrB) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrB) SwigIsB() { +} + +var _wrap_new_B unsafe.Pointer + +func _swig_wrap_new_B() (base SwigcptrB) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_B, _swig_p) + return +} + +func NewB() (_swig_ret B) { + return _swig_wrap_new_B() +} + +var _wrap_delete_B unsafe.Pointer + +func _swig_wrap_delete_B(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_B, _swig_p) + return +} + +func DeleteB(arg1 B) { + _swig_wrap_delete_B(arg1.Swigcptr()) +} + +var _wrap_B_hello unsafe.Pointer + +func _swig_wrap_B_hello(base SwigcptrB) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_B_hello, _swig_p) + return +} + +func (_swig_base SwigcptrB) Hello() { + _swig_wrap_B_hello(_swig_base) +} + +func (p SwigcptrB) SwigIsA() { +} + +func (p SwigcptrB) SwigGetA() A { + return SwigcptrA(p.Swigcptr()) +} + +type B interface { + Swigcptr() uintptr + SwigIsB() + Hello() + SwigIsA() + SwigGetA() A +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/catches.go b/Examples/test-suite/go/catches.go new file mode 100644 index 000000000..259ee5063 --- /dev/null +++ b/Examples/test-suite/go/catches.go @@ -0,0 +1,111 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../catches.i + +package catches + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrThreeException uintptr + +func (p SwigcptrThreeException) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrThreeException) SwigIsThreeException() { +} + +var _wrap_new_ThreeException unsafe.Pointer + +func _swig_wrap_new_ThreeException() (base SwigcptrThreeException) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_ThreeException, _swig_p) + return +} + +func NewThreeException() (_swig_ret ThreeException) { + return _swig_wrap_new_ThreeException() +} + +var _wrap_delete_ThreeException unsafe.Pointer + +func _swig_wrap_delete_ThreeException(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_ThreeException, _swig_p) + return +} + +func DeleteThreeException(arg1 ThreeException) { + _swig_wrap_delete_ThreeException(arg1.Swigcptr()) +} + +type ThreeException interface { + Swigcptr() uintptr + SwigIsThreeException() +} + +var _wrap_test_catches unsafe.Pointer + +func _swig_wrap_test_catches(base int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_test_catches, _swig_p) + return +} + +func Test_catches(arg1 int) { + _swig_wrap_test_catches(arg1) +} + +var _wrap_test_exception_specification unsafe.Pointer + +func _swig_wrap_test_exception_specification(base int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_test_exception_specification, _swig_p) + return +} + +func Test_exception_specification(arg1 int) { + _swig_wrap_test_exception_specification(arg1) +} + +var _wrap_test_catches_all unsafe.Pointer + +func _swig_wrap_test_catches_all(base int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_test_catches_all, _swig_p) + return +} + +func Test_catches_all(arg1 int) { + _swig_wrap_test_catches_all(arg1) +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/char_binary.go b/Examples/test-suite/go/char_binary.go new file mode 100644 index 000000000..cd7b82e5e --- /dev/null +++ b/Examples/test-suite/go/char_binary.go @@ -0,0 +1,164 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../char_binary.i + +package char_binary + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrTest uintptr + +func (p SwigcptrTest) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrTest) SwigIsTest() { +} + +var _wrap_Test_strlen unsafe.Pointer + +func _swig_wrap_Test_strlen(base SwigcptrTest, _ string) (_ int64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Test_strlen, _swig_p) + return +} + +func (arg1 SwigcptrTest) Strlen(arg2 string) (_swig_ret int64) { + return _swig_wrap_Test_strlen(arg1, arg2) +} + +var _wrap_new_Test unsafe.Pointer + +func _swig_wrap_new_Test() (base SwigcptrTest) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Test, _swig_p) + return +} + +func NewTest() (_swig_ret Test) { + return _swig_wrap_new_Test() +} + +var _wrap_delete_Test unsafe.Pointer + +func _swig_wrap_delete_Test(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Test, _swig_p) + return +} + +func DeleteTest(arg1 Test) { + _swig_wrap_delete_Test(arg1.Swigcptr()) +} + +type Test interface { + Swigcptr() uintptr + SwigIsTest() + Strlen(arg2 string) (_swig_ret int64) +} + +var _wrap_var_namet_set unsafe.Pointer + +func _swig_wrap_var_namet_set(base string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_var_namet_set, _swig_p) + return +} + +func SetVar_namet(arg1 string) { + _swig_wrap_var_namet_set(arg1) +} + +var _wrap_var_namet_get unsafe.Pointer + +func GetVar_namet() (_swig_ret string) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_var_namet_get, _swig_p) + return +} +var _wrap_var_pchar_set unsafe.Pointer + +func _swig_wrap_var_pchar_set(base string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_var_pchar_set, _swig_p) + return +} + +func SetVar_pchar(arg1 string) { + _swig_wrap_var_pchar_set(arg1) +} + +var _wrap_var_pchar_get unsafe.Pointer + +func GetVar_pchar() (_swig_ret string) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_var_pchar_get, _swig_p) + return +} +var _wrap_new_pchar unsafe.Pointer + +func New_pchar(arg1 int) (_swig_ret *byte) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_new_pchar, _swig_p) + return +} +var _wrap_delete_pchar unsafe.Pointer + +func _swig_wrap_delete_pchar(base *byte) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_pchar, _swig_p) + return +} + +func Delete_pchar(arg1 *byte) { + _swig_wrap_delete_pchar(arg1) +} + +var _wrap_pchar_getitem unsafe.Pointer + +func Pchar_getitem(arg1 *byte, arg2 int) (_swig_ret byte) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_pchar_getitem, _swig_p) + return +} +var _wrap_pchar_setitem unsafe.Pointer + +func _swig_wrap_pchar_setitem(base *byte, _ int, _ byte) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_pchar_setitem, _swig_p) + return +} + +func Pchar_setitem(arg1 *byte, arg2 int, arg3 byte) { + _swig_wrap_pchar_setitem(arg1, arg2, arg3) +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/char_binary_runme b/Examples/test-suite/go/char_binary_runme new file mode 100755 index 000000000..b07ebe5de Binary files /dev/null and b/Examples/test-suite/go/char_binary_runme differ diff --git a/Examples/test-suite/go/char_constant.go b/Examples/test-suite/go/char_constant.go new file mode 100644 index 000000000..0b25d5230 --- /dev/null +++ b/Examples/test-suite/go/char_constant.go @@ -0,0 +1,69 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../char_constant.i + +package char_constant + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +const CHAR_CONSTANT byte = 'x' +const STRING_CONSTANT string = "xyzzy" +var _wrap_ESC_CONST unsafe.Pointer + +func _swig_getESC_CONST() (_swig_ret byte) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_ESC_CONST, _swig_p) + return +} +var ESC_CONST byte = _swig_getESC_CONST() +var _wrap_NULL_CONST unsafe.Pointer + +func _swig_getNULL_CONST() (_swig_ret byte) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_NULL_CONST, _swig_p) + return +} +var NULL_CONST byte = _swig_getNULL_CONST() +var _wrap_SPECIALCHAR unsafe.Pointer + +func _swig_getSPECIALCHAR() (_swig_ret byte) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_SPECIALCHAR, _swig_p) + return +} +var SPECIALCHAR byte = _swig_getSPECIALCHAR() +var _wrap_ia_get unsafe.Pointer + +func GetIa() (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_ia_get, _swig_p) + return +} +var _wrap_ib_get unsafe.Pointer + +func GetIb() (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_ib_get, _swig_p) + return +} + diff --git a/Examples/test-suite/go/char_strings.go b/Examples/test-suite/go/char_strings.go new file mode 100644 index 000000000..42a26c8b2 --- /dev/null +++ b/Examples/test-suite/go/char_strings.go @@ -0,0 +1,302 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../char_strings.i + +package char_strings + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +var _wrap_GetCharHeapString unsafe.Pointer + +func GetCharHeapString() (_swig_ret string) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_GetCharHeapString, _swig_p) + return +} +var _wrap_GetConstCharProgramCodeString unsafe.Pointer + +func GetConstCharProgramCodeString() (_swig_ret string) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_GetConstCharProgramCodeString, _swig_p) + return +} +var _wrap_DeleteCharHeapString unsafe.Pointer + +func _swig_wrap_DeleteCharHeapString() { + var _swig_p uintptr + _cgo_runtime_cgocall(_wrap_DeleteCharHeapString, _swig_p) + return +} + +func DeleteCharHeapString() { + _swig_wrap_DeleteCharHeapString() +} + +var _wrap_GetCharStaticString unsafe.Pointer + +func GetCharStaticString() (_swig_ret string) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_GetCharStaticString, _swig_p) + return +} +var _wrap_GetCharStaticStringFixed unsafe.Pointer + +func GetCharStaticStringFixed() (_swig_ret string) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_GetCharStaticStringFixed, _swig_p) + return +} +var _wrap_GetConstCharStaticStringFixed unsafe.Pointer + +func GetConstCharStaticStringFixed() (_swig_ret string) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_GetConstCharStaticStringFixed, _swig_p) + return +} +var _wrap_SetCharHeapString unsafe.Pointer + +func SetCharHeapString(arg1 string, arg2 uint) (_swig_ret bool) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_SetCharHeapString, _swig_p) + return +} +var _wrap_SetCharStaticString unsafe.Pointer + +func SetCharStaticString(arg1 string, arg2 uint) (_swig_ret bool) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_SetCharStaticString, _swig_p) + return +} +var _wrap_SetCharArrayStaticString unsafe.Pointer + +func SetCharArrayStaticString(arg1 string, arg2 uint) (_swig_ret bool) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_SetCharArrayStaticString, _swig_p) + return +} +var _wrap_SetConstCharHeapString unsafe.Pointer + +func SetConstCharHeapString(arg1 string, arg2 uint) (_swig_ret bool) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_SetConstCharHeapString, _swig_p) + return +} +var _wrap_SetConstCharStaticString unsafe.Pointer + +func SetConstCharStaticString(arg1 string, arg2 uint) (_swig_ret bool) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_SetConstCharStaticString, _swig_p) + return +} +var _wrap_SetConstCharArrayStaticString unsafe.Pointer + +func SetConstCharArrayStaticString(arg1 string, arg2 uint) (_swig_ret bool) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_SetConstCharArrayStaticString, _swig_p) + return +} +var _wrap_SetCharConstStaticString unsafe.Pointer + +func SetCharConstStaticString(arg1 string, arg2 uint) (_swig_ret bool) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_SetCharConstStaticString, _swig_p) + return +} +var _wrap_SetConstCharConstStaticString unsafe.Pointer + +func SetConstCharConstStaticString(arg1 string, arg2 uint) (_swig_ret bool) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_SetConstCharConstStaticString, _swig_p) + return +} +var _wrap_CharPingPong unsafe.Pointer + +func CharPingPong(arg1 string) (_swig_ret string) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_CharPingPong, _swig_p) + return +} +var _wrap_CharArrayPingPong unsafe.Pointer + +func CharArrayPingPong(arg1 string) (_swig_ret string) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_CharArrayPingPong, _swig_p) + return +} +var _wrap_CharArrayDimsPingPong unsafe.Pointer + +func CharArrayDimsPingPong(arg1 string) (_swig_ret string) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_CharArrayDimsPingPong, _swig_p) + return +} +var _wrap_global_char_set unsafe.Pointer + +func _swig_wrap_global_char_set(base string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_global_char_set, _swig_p) + return +} + +func SetGlobal_char(arg1 string) { + _swig_wrap_global_char_set(arg1) +} + +var _wrap_global_char_get unsafe.Pointer + +func GetGlobal_char() (_swig_ret string) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_global_char_get, _swig_p) + return +} +var _wrap_global_char_array1_set unsafe.Pointer + +func _swig_wrap_global_char_array1_set(base string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_global_char_array1_set, _swig_p) + return +} + +func SetGlobal_char_array1(arg1 string) { + _swig_wrap_global_char_array1_set(arg1) +} + +var _wrap_global_char_array1_get unsafe.Pointer + +func GetGlobal_char_array1() (_swig_ret string) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_global_char_array1_get, _swig_p) + return +} +var _wrap_global_char_array2_set unsafe.Pointer + +func _swig_wrap_global_char_array2_set(base string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_global_char_array2_set, _swig_p) + return +} + +func SetGlobal_char_array2(arg1 string) { + _swig_wrap_global_char_array2_set(arg1) +} + +var _wrap_global_char_array2_get unsafe.Pointer + +func GetGlobal_char_array2() (_swig_ret string) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_global_char_array2_get, _swig_p) + return +} +var _wrap_global_const_char_get unsafe.Pointer + +func GetGlobal_const_char() (_swig_ret string) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_global_const_char_get, _swig_p) + return +} +var _wrap_global_const_char_array1_get unsafe.Pointer + +func GetGlobal_const_char_array1() (_swig_ret string) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_global_const_char_array1_get, _swig_p) + return +} +var _wrap_global_const_char_array2_get unsafe.Pointer + +func GetGlobal_const_char_array2() (_swig_ret string) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_global_const_char_array2_get, _swig_p) + return +} +var _wrap_GetNewCharString unsafe.Pointer + +func GetNewCharString() (_swig_ret string) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_GetNewCharString, _swig_p) + return +} +var _wrap_GetNextFormat unsafe.Pointer + +func _swig_wrap_GetNextFormat(base uintptr, _ string, _ uintptr) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_GetNextFormat, _swig_p) + return +} + +func GetNextFormat(arg1 Formatpos, arg2 string, arg3 OBFormat) (_swig_ret int) { + return _swig_wrap_GetNextFormat(arg1.Swigcptr(), arg2, arg3.Swigcptr()) +} + +var _wrap_GetCharPointerRef unsafe.Pointer + +func GetCharPointerRef() (_swig_ret string) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_GetCharPointerRef, _swig_p) + return +} +var _wrap_SetCharPointerRef unsafe.Pointer + +func SetCharPointerRef(arg1 string, arg2 uint) (_swig_ret bool) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_SetCharPointerRef, _swig_p) + return +} +var _wrap_GetConstCharPointerRef unsafe.Pointer + +func GetConstCharPointerRef() (_swig_ret string) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_GetConstCharPointerRef, _swig_p) + return +} +var _wrap_SetConstCharPointerRef unsafe.Pointer + +func SetConstCharPointerRef(arg1 string, arg2 uint) (_swig_ret bool) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_SetConstCharPointerRef, _swig_p) + return +} + +type SwigcptrOBFormat uintptr +type OBFormat interface { + Swigcptr() uintptr; +} +func (p SwigcptrOBFormat) Swigcptr() uintptr { + return uintptr(p) +} + +type SwigcptrFormatpos uintptr +type Formatpos interface { + Swigcptr() uintptr; +} +func (p SwigcptrFormatpos) Swigcptr() uintptr { + return uintptr(p) +} + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/class_forward.go b/Examples/test-suite/go/class_forward.go new file mode 100644 index 000000000..d4dd444be --- /dev/null +++ b/Examples/test-suite/go/class_forward.go @@ -0,0 +1,122 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../class_forward.i + +package class_forward + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrA uintptr + +func (p SwigcptrA) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrA) SwigIsA() { +} + +var _wrap_new_A unsafe.Pointer + +func _swig_wrap_new_A() (base SwigcptrA) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_A, _swig_p) + return +} + +func NewA() (_swig_ret A) { + return _swig_wrap_new_A() +} + +var _wrap_delete_A unsafe.Pointer + +func _swig_wrap_delete_A(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_A, _swig_p) + return +} + +func DeleteA(arg1 A) { + _swig_wrap_delete_A(arg1.Swigcptr()) +} + +type A interface { + Swigcptr() uintptr + SwigIsA() +} + +type SwigcptrC uintptr + +func (p SwigcptrC) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrC) SwigIsC() { +} + +var _wrap_new_C unsafe.Pointer + +func _swig_wrap_new_C() (base SwigcptrC) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_C, _swig_p) + return +} + +func NewC() (_swig_ret C) { + return _swig_wrap_new_C() +} + +var _wrap_delete_C unsafe.Pointer + +func _swig_wrap_delete_C(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_C, _swig_p) + return +} + +func DeleteC(arg1 C) { + _swig_wrap_delete_C(arg1.Swigcptr()) +} + +func (p SwigcptrC) SwigIsA() { +} + +func (p SwigcptrC) SwigGetA() A { + return SwigcptrA(p.Swigcptr()) +} + +type C interface { + Swigcptr() uintptr + SwigIsC() + SwigIsA() + SwigGetA() A +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/class_ignore.go b/Examples/test-suite/go/class_ignore.go new file mode 100644 index 000000000..49e7d04e5 --- /dev/null +++ b/Examples/test-suite/go/class_ignore.go @@ -0,0 +1,262 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../class_ignore.i + +package class_ignore + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrBar uintptr + +func (p SwigcptrBar) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrBar) SwigIsBar() { +} + +var _wrap_Bar_blah unsafe.Pointer + +func _swig_wrap_Bar_blah(base SwigcptrBar) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Bar_blah, _swig_p) + return +} + +func (arg1 SwigcptrBar) Blah() (_swig_ret string) { + return _swig_wrap_Bar_blah(arg1) +} + +var _wrap_new_Bar unsafe.Pointer + +func _swig_wrap_new_Bar() (base SwigcptrBar) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Bar, _swig_p) + return +} + +func NewBar() (_swig_ret Bar) { + return _swig_wrap_new_Bar() +} + +var _wrap_delete_Bar unsafe.Pointer + +func _swig_wrap_delete_Bar(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Bar, _swig_p) + return +} + +func DeleteBar(arg1 Bar) { + _swig_wrap_delete_Bar(arg1.Swigcptr()) +} + +type Bar interface { + Swigcptr() uintptr + SwigIsBar() + Blah() (_swig_ret string) +} + +type SwigcptrBoo uintptr + +func (p SwigcptrBoo) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrBoo) SwigIsBoo() { +} + +var _wrap_delete_Boo unsafe.Pointer + +func _swig_wrap_delete_Boo(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Boo, _swig_p) + return +} + +func DeleteBoo(arg1 Boo) { + _swig_wrap_delete_Boo(arg1.Swigcptr()) +} + +var _wrap_Boo_away unsafe.Pointer + +func _swig_wrap_Boo_away(base SwigcptrBoo) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Boo_away, _swig_p) + return +} + +func (arg1 SwigcptrBoo) Away() { + _swig_wrap_Boo_away(arg1) +} + +var _wrap_new_Boo unsafe.Pointer + +func _swig_wrap_new_Boo() (base SwigcptrBoo) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Boo, _swig_p) + return +} + +func NewBoo() (_swig_ret Boo) { + return _swig_wrap_new_Boo() +} + +type Boo interface { + Swigcptr() uintptr + SwigIsBoo() + Away() +} + +type SwigcptrFar uintptr + +func (p SwigcptrFar) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrFar) SwigIsFar() { +} + +var _wrap_new_Far unsafe.Pointer + +func _swig_wrap_new_Far() (base SwigcptrFar) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Far, _swig_p) + return +} + +func NewFar() (_swig_ret Far) { + return _swig_wrap_new_Far() +} + +var _wrap_delete_Far unsafe.Pointer + +func _swig_wrap_delete_Far(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Far, _swig_p) + return +} + +func DeleteFar(arg1 Far) { + _swig_wrap_delete_Far(arg1.Swigcptr()) +} + +func (p SwigcptrFar) SwigIsBoo() { +} + +func (p SwigcptrFar) SwigGetBoo() Boo { + return SwigcptrBoo(p.Swigcptr()) +} + +type Far interface { + Swigcptr() uintptr + SwigIsFar() + SwigIsBoo() + SwigGetBoo() Boo +} + +type SwigcptrHoo uintptr + +func (p SwigcptrHoo) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrHoo) SwigIsHoo() { +} + +var _wrap_new_Hoo unsafe.Pointer + +func _swig_wrap_new_Hoo() (base SwigcptrHoo) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Hoo, _swig_p) + return +} + +func NewHoo() (_swig_ret Hoo) { + return _swig_wrap_new_Hoo() +} + +var _wrap_delete_Hoo unsafe.Pointer + +func _swig_wrap_delete_Hoo(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Hoo, _swig_p) + return +} + +func DeleteHoo(arg1 Hoo) { + _swig_wrap_delete_Hoo(arg1.Swigcptr()) +} + +func (p SwigcptrHoo) SwigIsFar() { +} + +func (p SwigcptrHoo) SwigGetFar() Far { + return SwigcptrFar(p.Swigcptr()) +} + +func (p SwigcptrHoo) SwigIsBoo() { +} + +func (p SwigcptrHoo) SwigGetBoo() Boo { + return SwigcptrBoo(p.Swigcptr()) +} + +type Hoo interface { + Swigcptr() uintptr + SwigIsHoo() + SwigIsFar() + SwigGetFar() Far + SwigIsBoo() + SwigGetBoo() Boo +} + +var _wrap_do_blah unsafe.Pointer + +func _swig_wrap_do_blah(base uintptr) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_do_blah, _swig_p) + return +} + +func Do_blah(arg1 Foo) (_swig_ret string) { + return _swig_wrap_do_blah(arg1.Swigcptr()) +} + + +type SwigcptrFoo uintptr +type Foo interface { + Swigcptr() uintptr; +} +func (p SwigcptrFoo) Swigcptr() uintptr { + return uintptr(p) +} + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/class_ignore_runme b/Examples/test-suite/go/class_ignore_runme new file mode 100755 index 000000000..7fce83f6f Binary files /dev/null and b/Examples/test-suite/go/class_ignore_runme differ diff --git a/Examples/test-suite/go/class_scope_weird.go b/Examples/test-suite/go/class_scope_weird.go new file mode 100644 index 000000000..93f4295ca --- /dev/null +++ b/Examples/test-suite/go/class_scope_weird.go @@ -0,0 +1,218 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../class_scope_weird.i + +package class_scope_weird + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrFoo uintptr + +func (p SwigcptrFoo) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrFoo) SwigIsFoo() { +} + +var _wrap_new_Foo__SWIG_0 unsafe.Pointer + +func _swig_wrap_new_Foo__SWIG_0() (base SwigcptrFoo) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Foo__SWIG_0, _swig_p) + return +} + +func NewFoo__SWIG_0() (_swig_ret Foo) { + return _swig_wrap_new_Foo__SWIG_0() +} + +var _wrap_new_Foo__SWIG_1 unsafe.Pointer + +func _swig_wrap_new_Foo__SWIG_1(base int) (_ SwigcptrFoo) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Foo__SWIG_1, _swig_p) + return +} + +func NewFoo__SWIG_1(arg1 int) (_swig_ret Foo) { + return _swig_wrap_new_Foo__SWIG_1(arg1) +} + +func NewFoo(a ...interface{}) Foo { + argc := len(a) + if argc == 0 { + return NewFoo__SWIG_0() + } + if argc == 1 { + return NewFoo__SWIG_1(a[0].(int)) + } + panic("No match for overloaded function call") +} + +var _wrap_Foo_bar unsafe.Pointer + +func _swig_wrap_Foo_bar(base SwigcptrFoo, _ int) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_bar, _swig_p) + return +} + +func (arg1 SwigcptrFoo) Bar(arg2 int) (_swig_ret int) { + return _swig_wrap_Foo_bar(arg1, arg2) +} + +var _wrap_delete_Foo unsafe.Pointer + +func _swig_wrap_delete_Foo(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Foo, _swig_p) + return +} + +func DeleteFoo(arg1 Foo) { + _swig_wrap_delete_Foo(arg1.Swigcptr()) +} + +type Foo interface { + Swigcptr() uintptr + SwigIsFoo() + Bar(arg2 int) (_swig_ret int) +} + +type SwigcptrQuat uintptr + +func (p SwigcptrQuat) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrQuat) SwigIsQuat() { +} + +var _wrap_new_Quat__SWIG_0 unsafe.Pointer + +func _swig_wrap_new_Quat__SWIG_0() (base SwigcptrQuat) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Quat__SWIG_0, _swig_p) + return +} + +func NewQuat__SWIG_0() (_swig_ret Quat) { + return _swig_wrap_new_Quat__SWIG_0() +} + +var _wrap_new_Quat__SWIG_1 unsafe.Pointer + +func _swig_wrap_new_Quat__SWIG_1(base float32, _ float32, _ float32, _ float32) (_ SwigcptrQuat) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Quat__SWIG_1, _swig_p) + return +} + +func NewQuat__SWIG_1(arg1 float32, arg2 float32, arg3 float32, arg4 float32) (_swig_ret Quat) { + return _swig_wrap_new_Quat__SWIG_1(arg1, arg2, arg3, arg4) +} + +var _wrap_new_Quat__SWIG_2 unsafe.Pointer + +func _swig_wrap_new_Quat__SWIG_2(base uintptr, _ float32) (_ SwigcptrQuat) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Quat__SWIG_2, _swig_p) + return +} + +func NewQuat__SWIG_2(arg1 Tacka3, arg2 float32) (_swig_ret Quat) { + return _swig_wrap_new_Quat__SWIG_2(arg1.Swigcptr(), arg2) +} + +var _wrap_new_Quat__SWIG_3 unsafe.Pointer + +func _swig_wrap_new_Quat__SWIG_3(base uintptr) (_ SwigcptrQuat) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Quat__SWIG_3, _swig_p) + return +} + +func NewQuat__SWIG_3(arg1 Matrix4) (_swig_ret Quat) { + return _swig_wrap_new_Quat__SWIG_3(arg1.Swigcptr()) +} + +func NewQuat(a ...interface{}) Quat { + argc := len(a) + if argc == 0 { + return NewQuat__SWIG_0() + } + if argc == 1 { + return NewQuat__SWIG_3(a[0].(Matrix4)) + } + if argc == 2 { + return NewQuat__SWIG_2(a[0].(Tacka3), a[1].(float32)) + } + if argc == 4 { + return NewQuat__SWIG_1(a[0].(float32), a[1].(float32), a[2].(float32), a[3].(float32)) + } + panic("No match for overloaded function call") +} + +var _wrap_delete_Quat unsafe.Pointer + +func _swig_wrap_delete_Quat(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Quat, _swig_p) + return +} + +func DeleteQuat(arg1 Quat) { + _swig_wrap_delete_Quat(arg1.Swigcptr()) +} + +type Quat interface { + Swigcptr() uintptr + SwigIsQuat() +} + + +type SwigcptrTacka3 uintptr +type Tacka3 interface { + Swigcptr() uintptr; +} +func (p SwigcptrTacka3) Swigcptr() uintptr { + return uintptr(p) +} + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + +type SwigcptrMatrix4 uintptr +type Matrix4 interface { + Swigcptr() uintptr; +} +func (p SwigcptrMatrix4) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/class_scope_weird_runme b/Examples/test-suite/go/class_scope_weird_runme new file mode 100755 index 000000000..d41c53752 Binary files /dev/null and b/Examples/test-suite/go/class_scope_weird_runme differ diff --git a/Examples/test-suite/go/clientdata_prop_a.go b/Examples/test-suite/go/clientdata_prop_a.go new file mode 100644 index 000000000..fe029f74f --- /dev/null +++ b/Examples/test-suite/go/clientdata_prop_a.go @@ -0,0 +1,124 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../clientdata_prop_a.i + +package clientdata_prop_a + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrA uintptr + +func (p SwigcptrA) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrA) SwigIsA() { +} + +var _wrap_A_fA unsafe.Pointer + +func _swig_wrap_A_fA(base SwigcptrA) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_A_fA, _swig_p) + return +} + +func (arg1 SwigcptrA) FA() { + _swig_wrap_A_fA(arg1) +} + +var _wrap_new_A unsafe.Pointer + +func _swig_wrap_new_A() (base SwigcptrA) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_A, _swig_p) + return +} + +func NewA() (_swig_ret A) { + return _swig_wrap_new_A() +} + +var _wrap_delete_A unsafe.Pointer + +func _swig_wrap_delete_A(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_A, _swig_p) + return +} + +func DeleteA(arg1 A) { + _swig_wrap_delete_A(arg1.Swigcptr()) +} + +type A interface { + Swigcptr() uintptr + SwigIsA() + FA() +} + +var _wrap_test_A unsafe.Pointer + +func _swig_wrap_test_A(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_test_A, _swig_p) + return +} + +func Test_A(arg1 A) { + _swig_wrap_test_A(arg1.Swigcptr()) +} + +var _wrap_test_tA unsafe.Pointer + +func _swig_wrap_test_tA(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_test_tA, _swig_p) + return +} + +func Test_tA(arg1 A) { + _swig_wrap_test_tA(arg1.Swigcptr()) +} + +var _wrap_new_tA unsafe.Pointer + +func _swig_wrap_new_tA() (base SwigcptrA) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_tA, _swig_p) + return +} + +func New_tA() (_swig_ret A) { + return _swig_wrap_new_tA() +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/clientdata_prop_b.go b/Examples/test-suite/go/clientdata_prop_b.go new file mode 100644 index 000000000..1d8aa4c73 --- /dev/null +++ b/Examples/test-suite/go/clientdata_prop_b.go @@ -0,0 +1,389 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../clientdata_prop_b.i + +package clientdata_prop_b + +import "unsafe" +import _ "runtime/cgo" +import "clientdata_prop_a" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrB uintptr + +func (p SwigcptrB) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrB) SwigIsB() { +} + +var _wrap_B_fB unsafe.Pointer + +func _swig_wrap_B_fB(base SwigcptrB) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_B_fB, _swig_p) + return +} + +func (arg1 SwigcptrB) FB() { + _swig_wrap_B_fB(arg1) +} + +var _wrap_new_B unsafe.Pointer + +func _swig_wrap_new_B() (base SwigcptrB) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_B, _swig_p) + return +} + +func NewB() (_swig_ret B) { + return _swig_wrap_new_B() +} + +var _wrap_delete_B unsafe.Pointer + +func _swig_wrap_delete_B(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_B, _swig_p) + return +} + +func DeleteB(arg1 B) { + _swig_wrap_delete_B(arg1.Swigcptr()) +} + +var _wrap_B_fA unsafe.Pointer + +func _swig_wrap_B_fA(base SwigcptrB) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_B_fA, _swig_p) + return +} + +func (_swig_base SwigcptrB) FA() { + _swig_wrap_B_fA(_swig_base) +} + +func (p SwigcptrB) SwigIsA() { +} + +func (p SwigcptrB) SwigGetA() clientdata_prop_a.A { + return clientdata_prop_a.SwigcptrA(p.Swigcptr()) +} + +type B interface { + Swigcptr() uintptr + SwigIsB() + FB() + FA() + SwigIsA() + SwigGetA() clientdata_prop_a.A +} + +type SwigcptrC uintptr + +func (p SwigcptrC) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrC) SwigIsC() { +} + +var _wrap_C_fC unsafe.Pointer + +func _swig_wrap_C_fC(base SwigcptrC) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_C_fC, _swig_p) + return +} + +func (arg1 SwigcptrC) FC() { + _swig_wrap_C_fC(arg1) +} + +var _wrap_new_C unsafe.Pointer + +func _swig_wrap_new_C() (base SwigcptrC) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_C, _swig_p) + return +} + +func NewC() (_swig_ret C) { + return _swig_wrap_new_C() +} + +var _wrap_delete_C unsafe.Pointer + +func _swig_wrap_delete_C(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_C, _swig_p) + return +} + +func DeleteC(arg1 C) { + _swig_wrap_delete_C(arg1.Swigcptr()) +} + +var _wrap_C_fA unsafe.Pointer + +func _swig_wrap_C_fA(base SwigcptrC) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_C_fA, _swig_p) + return +} + +func (_swig_base SwigcptrC) FA() { + _swig_wrap_C_fA(_swig_base) +} + +func (p SwigcptrC) SwigIsA() { +} + +func (p SwigcptrC) SwigGetA() clientdata_prop_a.A { + return clientdata_prop_a.SwigcptrA(p.Swigcptr()) +} + +type C interface { + Swigcptr() uintptr + SwigIsC() + FC() + FA() + SwigIsA() + SwigGetA() clientdata_prop_a.A +} + +type SwigcptrD uintptr + +func (p SwigcptrD) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrD) SwigIsD() { +} + +var _wrap_D_fD unsafe.Pointer + +func _swig_wrap_D_fD(base SwigcptrD) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_D_fD, _swig_p) + return +} + +func (arg1 SwigcptrD) FD() { + _swig_wrap_D_fD(arg1) +} + +var _wrap_new_D unsafe.Pointer + +func _swig_wrap_new_D() (base SwigcptrD) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_D, _swig_p) + return +} + +func NewD() (_swig_ret D) { + return _swig_wrap_new_D() +} + +var _wrap_delete_D unsafe.Pointer + +func _swig_wrap_delete_D(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_D, _swig_p) + return +} + +func DeleteD(arg1 D) { + _swig_wrap_delete_D(arg1.Swigcptr()) +} + +var _wrap_D_fA unsafe.Pointer + +func _swig_wrap_D_fA(base SwigcptrD) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_D_fA, _swig_p) + return +} + +func (_swig_base SwigcptrD) FA() { + _swig_wrap_D_fA(_swig_base) +} + +func (p SwigcptrD) SwigIsA() { +} + +func (p SwigcptrD) SwigGetA() clientdata_prop_a.A { + return clientdata_prop_a.SwigcptrA(p.Swigcptr()) +} + +type D interface { + Swigcptr() uintptr + SwigIsD() + FD() + FA() + SwigIsA() + SwigGetA() clientdata_prop_a.A +} + +var _wrap_test_t2A unsafe.Pointer + +func _swig_wrap_test_t2A(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_test_t2A, _swig_p) + return +} + +func Test_t2A(arg1 clientdata_prop_a.A) { + _swig_wrap_test_t2A(arg1.Swigcptr()) +} + +var _wrap_test_t3A unsafe.Pointer + +func _swig_wrap_test_t3A(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_test_t3A, _swig_p) + return +} + +func Test_t3A(arg1 clientdata_prop_a.A) { + _swig_wrap_test_t3A(arg1.Swigcptr()) +} + +var _wrap_test_B unsafe.Pointer + +func _swig_wrap_test_B(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_test_B, _swig_p) + return +} + +func Test_B(arg1 B) { + _swig_wrap_test_B(arg1.Swigcptr()) +} + +var _wrap_test_C unsafe.Pointer + +func _swig_wrap_test_C(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_test_C, _swig_p) + return +} + +func Test_C(arg1 C) { + _swig_wrap_test_C(arg1.Swigcptr()) +} + +var _wrap_test_D unsafe.Pointer + +func _swig_wrap_test_D(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_test_D, _swig_p) + return +} + +func Test_D(arg1 D) { + _swig_wrap_test_D(arg1.Swigcptr()) +} + +var _wrap_test_tD unsafe.Pointer + +func _swig_wrap_test_tD(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_test_tD, _swig_p) + return +} + +func Test_tD(arg1 D) { + _swig_wrap_test_tD(arg1.Swigcptr()) +} + +var _wrap_test_t2D unsafe.Pointer + +func _swig_wrap_test_t2D(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_test_t2D, _swig_p) + return +} + +func Test_t2D(arg1 D) { + _swig_wrap_test_t2D(arg1.Swigcptr()) +} + +var _wrap_new_t2A unsafe.Pointer + +func _swig_wrap_new_t2A() (base clientdata_prop_a.SwigcptrA) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_t2A, _swig_p) + return +} + +func New_t2A() (_swig_ret clientdata_prop_a.A) { + return _swig_wrap_new_t2A() +} + +var _wrap_new_t3A unsafe.Pointer + +func _swig_wrap_new_t3A() (base clientdata_prop_a.SwigcptrA) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_t3A, _swig_p) + return +} + +func New_t3A() (_swig_ret clientdata_prop_a.A) { + return _swig_wrap_new_t3A() +} + +var _wrap_new_tD unsafe.Pointer + +func _swig_wrap_new_tD() (base SwigcptrD) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_tD, _swig_p) + return +} + +func New_tD() (_swig_ret D) { + return _swig_wrap_new_tD() +} + +var _wrap_new_t2D unsafe.Pointer + +func _swig_wrap_new_t2D() (base SwigcptrD) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_t2D, _swig_p) + return +} + +func New_t2D() (_swig_ret D) { + return _swig_wrap_new_t2D() +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/compactdefaultargs.go b/Examples/test-suite/go/compactdefaultargs.go new file mode 100644 index 000000000..097295db9 --- /dev/null +++ b/Examples/test-suite/go/compactdefaultargs.go @@ -0,0 +1,226 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../compactdefaultargs.i + +package compactdefaultargs + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrDefaults1 uintptr + +func (p SwigcptrDefaults1) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrDefaults1) SwigIsDefaults1() { +} + +var _wrap_Defaults1_PUBLIC_DEFAULT_get unsafe.Pointer + +func GetDefaults1PUBLIC_DEFAULT() (_swig_ret float64) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_Defaults1_PUBLIC_DEFAULT_get, _swig_p) + return +} +var _wrap_new_Defaults1__SWIG_0 unsafe.Pointer + +func _swig_wrap_new_Defaults1__SWIG_0(base int) (_ SwigcptrDefaults1) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Defaults1__SWIG_0, _swig_p) + return +} + +func NewDefaults1__SWIG_0(arg1 int) (_swig_ret Defaults1) { + return _swig_wrap_new_Defaults1__SWIG_0(arg1) +} + +var _wrap_new_Defaults1__SWIG_1 unsafe.Pointer + +func _swig_wrap_new_Defaults1__SWIG_1() (base SwigcptrDefaults1) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Defaults1__SWIG_1, _swig_p) + return +} + +func NewDefaults1__SWIG_1() (_swig_ret Defaults1) { + return _swig_wrap_new_Defaults1__SWIG_1() +} + +func NewDefaults1(a ...interface{}) Defaults1 { + argc := len(a) + if argc == 0 { + return NewDefaults1__SWIG_1() + } + if argc == 1 { + return NewDefaults1__SWIG_0(a[0].(int)) + } + panic("No match for overloaded function call") +} + +var _wrap_Defaults1_ret__SWIG_0 unsafe.Pointer + +func _swig_wrap_Defaults1_ret__SWIG_0(base SwigcptrDefaults1, _ float64) (_ float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Defaults1_ret__SWIG_0, _swig_p) + return +} + +func (arg1 SwigcptrDefaults1) Ret__SWIG_0(arg2 float64) (_swig_ret float64) { + return _swig_wrap_Defaults1_ret__SWIG_0(arg1, arg2) +} + +var _wrap_Defaults1_ret__SWIG_1 unsafe.Pointer + +func _swig_wrap_Defaults1_ret__SWIG_1(base SwigcptrDefaults1) (_ float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Defaults1_ret__SWIG_1, _swig_p) + return +} + +func (arg1 SwigcptrDefaults1) Ret__SWIG_1() (_swig_ret float64) { + return _swig_wrap_Defaults1_ret__SWIG_1(arg1) +} + +func (p SwigcptrDefaults1) Ret(a ...interface{}) float64 { + argc := len(a) + if argc == 0 { + return p.Ret__SWIG_1() + } + if argc == 1 { + return p.Ret__SWIG_0(a[0].(float64)) + } + panic("No match for overloaded function call") +} + +var _wrap_delete_Defaults1 unsafe.Pointer + +func _swig_wrap_delete_Defaults1(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Defaults1, _swig_p) + return +} + +func DeleteDefaults1(arg1 Defaults1) { + _swig_wrap_delete_Defaults1(arg1.Swigcptr()) +} + +type Defaults1 interface { + Swigcptr() uintptr + SwigIsDefaults1() + Ret(a ...interface{}) float64 +} + +type SwigcptrDefaults2 uintptr + +func (p SwigcptrDefaults2) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrDefaults2) SwigIsDefaults2() { +} + +var _wrap_Defaults2_PUBLIC_DEFAULT_get unsafe.Pointer + +func GetDefaults2PUBLIC_DEFAULT() (_swig_ret float64) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_Defaults2_PUBLIC_DEFAULT_get, _swig_p) + return +} +var _wrap_new_Defaults2__SWIG_0 unsafe.Pointer + +func _swig_wrap_new_Defaults2__SWIG_0(base int) (_ SwigcptrDefaults2) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Defaults2__SWIG_0, _swig_p) + return +} + +func NewDefaults2__SWIG_0(arg1 int) (_swig_ret Defaults2) { + return _swig_wrap_new_Defaults2__SWIG_0(arg1) +} + +var _wrap_new_Defaults2__SWIG_1 unsafe.Pointer + +func _swig_wrap_new_Defaults2__SWIG_1() (base SwigcptrDefaults2) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Defaults2__SWIG_1, _swig_p) + return +} + +func NewDefaults2__SWIG_1() (_swig_ret Defaults2) { + return _swig_wrap_new_Defaults2__SWIG_1() +} + +func NewDefaults2(a ...interface{}) Defaults2 { + argc := len(a) + if argc == 0 { + return NewDefaults2__SWIG_1() + } + if argc == 1 { + return NewDefaults2__SWIG_0(a[0].(int)) + } + panic("No match for overloaded function call") +} + +var _wrap_Defaults2_ret unsafe.Pointer + +func _swig_wrap_Defaults2_ret(base int, _ SwigcptrDefaults2, _ float64) (_ float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Defaults2_ret, _swig_p) + return +} + +func (arg1 SwigcptrDefaults2) Ret(_swig_args ...interface{}) (_swig_ret float64) { + var arg2 float64 + if len(_swig_args) > 0 { + arg2 = _swig_args[0].(float64) + } + return _swig_wrap_Defaults2_ret(len(_swig_args), arg1, arg2) +} + +var _wrap_delete_Defaults2 unsafe.Pointer + +func _swig_wrap_delete_Defaults2(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Defaults2, _swig_p) + return +} + +func DeleteDefaults2(arg1 Defaults2) { + _swig_wrap_delete_Defaults2(arg1.Swigcptr()) +} + +type Defaults2 interface { + Swigcptr() uintptr + SwigIsDefaults2() + Ret(_swig_args ...interface{}) (_swig_ret float64) +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/compactdefaultargs_runme b/Examples/test-suite/go/compactdefaultargs_runme new file mode 100755 index 000000000..2f4b8c591 Binary files /dev/null and b/Examples/test-suite/go/compactdefaultargs_runme differ diff --git a/Examples/test-suite/go/const_const.go b/Examples/test-suite/go/const_const.go new file mode 100644 index 000000000..2aa8ce702 --- /dev/null +++ b/Examples/test-suite/go/const_const.go @@ -0,0 +1,49 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../const_const.i + +package const_const + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +var _wrap_foo unsafe.Pointer + +func _swig_wrap_foo(base *int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_foo, _swig_p) + return +} + +func Foo(arg1 *int) { + _swig_wrap_foo(arg1) +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/const_const_2.go b/Examples/test-suite/go/const_const_2.go new file mode 100644 index 000000000..4e87068e7 --- /dev/null +++ b/Examples/test-suite/go/const_const_2.go @@ -0,0 +1,126 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../const_const_2.i + +package const_const_2 + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrSpam uintptr + +func (p SwigcptrSpam) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrSpam) SwigIsSpam() { +} + +var _wrap_new_Spam unsafe.Pointer + +func _swig_wrap_new_Spam() (base SwigcptrSpam) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Spam, _swig_p) + return +} + +func NewSpam() (_swig_ret Spam) { + return _swig_wrap_new_Spam() +} + +var _wrap_delete_Spam unsafe.Pointer + +func _swig_wrap_delete_Spam(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Spam, _swig_p) + return +} + +func DeleteSpam(arg1 Spam) { + _swig_wrap_delete_Spam(arg1.Swigcptr()) +} + +type Spam interface { + Swigcptr() uintptr + SwigIsSpam() +} + +type SwigcptrEggs uintptr + +func (p SwigcptrEggs) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrEggs) SwigIsEggs() { +} + +var _wrap_new_Eggs unsafe.Pointer + +func _swig_wrap_new_Eggs() (base SwigcptrEggs) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Eggs, _swig_p) + return +} + +func NewEggs() (_swig_ret Eggs) { + return _swig_wrap_new_Eggs() +} + +var _wrap_Eggs_spam unsafe.Pointer + +func _swig_wrap_Eggs_spam(base SwigcptrEggs) (_ SwigcptrSpam) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Eggs_spam, _swig_p) + return +} + +func (arg1 SwigcptrEggs) Spam() (_swig_ret Spam) { + return _swig_wrap_Eggs_spam(arg1) +} + +var _wrap_delete_Eggs unsafe.Pointer + +func _swig_wrap_delete_Eggs(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Eggs, _swig_p) + return +} + +func DeleteEggs(arg1 Eggs) { + _swig_wrap_delete_Eggs(arg1.Swigcptr()) +} + +type Eggs interface { + Swigcptr() uintptr + SwigIsEggs() + Spam() (_swig_ret Spam) +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/constant_expr.go b/Examples/test-suite/go/constant_expr.go new file mode 100644 index 000000000..2a2cf24b8 --- /dev/null +++ b/Examples/test-suite/go/constant_expr.go @@ -0,0 +1,71 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../constant_expr.i + +package constant_expr + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +var _wrap_X_get unsafe.Pointer + +func GetX() (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_X_get, _swig_p) + return +} +var _wrap_FOO unsafe.Pointer + +func _swig_getFOO() (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_FOO, _swig_p) + return +} +var FOO int = _swig_getFOO() +var _wrap_d_array_set unsafe.Pointer + +func _swig_wrap_d_array_set(base *float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_d_array_set, _swig_p) + return +} + +func SetD_array(arg1 *float64) { + _swig_wrap_d_array_set(arg1) +} + +var _wrap_d_array_get unsafe.Pointer + +func GetD_array() (_swig_ret *float64) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_d_array_get, _swig_p) + return +} + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/constant_pointers.go b/Examples/test-suite/go/constant_pointers.go new file mode 100644 index 000000000..c92c3b1ff --- /dev/null +++ b/Examples/test-suite/go/constant_pointers.go @@ -0,0 +1,1327 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../constant_pointers.i + +package constant_pointers + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +var _wrap_GlobalInt_set unsafe.Pointer + +func _swig_wrap_GlobalInt_set(base int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_GlobalInt_set, _swig_p) + return +} + +func SetGlobalInt(arg1 int) { + _swig_wrap_GlobalInt_set(arg1) +} + +var _wrap_GlobalInt_get unsafe.Pointer + +func GetGlobalInt() (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_GlobalInt_get, _swig_p) + return +} +var _wrap_ConstInt_get unsafe.Pointer + +func GetConstInt() (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_ConstInt_get, _swig_p) + return +} +var _wrap_GlobalIntPtr_set unsafe.Pointer + +func _swig_wrap_GlobalIntPtr_set(base *int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_GlobalIntPtr_set, _swig_p) + return +} + +func SetGlobalIntPtr(arg1 *int) { + _swig_wrap_GlobalIntPtr_set(arg1) +} + +var _wrap_GlobalIntPtr_get unsafe.Pointer + +func GetGlobalIntPtr() (_swig_ret *int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_GlobalIntPtr_get, _swig_p) + return +} +var _wrap_GlobalConstIntPtr_get unsafe.Pointer + +func GetGlobalConstIntPtr() (_swig_ret *int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_GlobalConstIntPtr_get, _swig_p) + return +} +const ARRAY_SIZE int = 2 +type SwigcptrParametersTest uintptr + +func (p SwigcptrParametersTest) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrParametersTest) SwigIsParametersTest() { +} + +var _wrap_ParametersTest_param1 unsafe.Pointer + +func _swig_wrap_ParametersTest_param1(base SwigcptrParametersTest, _ *int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_ParametersTest_param1, _swig_p) + return +} + +func (arg1 SwigcptrParametersTest) Param1(arg2 *int) { + _swig_wrap_ParametersTest_param1(arg1, arg2) +} + +var _wrap_ParametersTest_param2 unsafe.Pointer + +func _swig_wrap_ParametersTest_param2(base SwigcptrParametersTest, _ *int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_ParametersTest_param2, _swig_p) + return +} + +func (arg1 SwigcptrParametersTest) Param2(arg2 *int) { + _swig_wrap_ParametersTest_param2(arg1, arg2) +} + +var _wrap_ParametersTest_param3 unsafe.Pointer + +func _swig_wrap_ParametersTest_param3(base SwigcptrParametersTest, _ *int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_ParametersTest_param3, _swig_p) + return +} + +func (arg1 SwigcptrParametersTest) Param3(arg2 *int) { + _swig_wrap_ParametersTest_param3(arg1, arg2) +} + +var _wrap_ParametersTest_param4 unsafe.Pointer + +func _swig_wrap_ParametersTest_param4(base SwigcptrParametersTest, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_ParametersTest_param4, _swig_p) + return +} + +func (arg1 SwigcptrParametersTest) Param4(arg2 int) { + _swig_wrap_ParametersTest_param4(arg1, arg2) +} + +var _wrap_ParametersTest_param5 unsafe.Pointer + +func _swig_wrap_ParametersTest_param5(base SwigcptrParametersTest, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_ParametersTest_param5, _swig_p) + return +} + +func (arg1 SwigcptrParametersTest) Param5(arg2 int) { + _swig_wrap_ParametersTest_param5(arg1, arg2) +} + +var _wrap_ParametersTest_param6 unsafe.Pointer + +func _swig_wrap_ParametersTest_param6(base SwigcptrParametersTest, _ *int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_ParametersTest_param6, _swig_p) + return +} + +func (arg1 SwigcptrParametersTest) Param6(arg2 *int) { + _swig_wrap_ParametersTest_param6(arg1, arg2) +} + +var _wrap_ParametersTest_param7 unsafe.Pointer + +func _swig_wrap_ParametersTest_param7(base SwigcptrParametersTest, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_ParametersTest_param7, _swig_p) + return +} + +func (arg1 SwigcptrParametersTest) Param7(arg2 int) { + _swig_wrap_ParametersTest_param7(arg1, arg2) +} + +var _wrap_ParametersTest_param8 unsafe.Pointer + +func _swig_wrap_ParametersTest_param8(base SwigcptrParametersTest, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_ParametersTest_param8, _swig_p) + return +} + +func (arg1 SwigcptrParametersTest) Param8(arg2 int) { + _swig_wrap_ParametersTest_param8(arg1, arg2) +} + +var _wrap_ParametersTest_param9 unsafe.Pointer + +func _swig_wrap_ParametersTest_param9(base SwigcptrParametersTest, _ **int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_ParametersTest_param9, _swig_p) + return +} + +func (arg1 SwigcptrParametersTest) Param9(arg2 **int) { + _swig_wrap_ParametersTest_param9(arg1, arg2) +} + +var _wrap_ParametersTest_param10 unsafe.Pointer + +func _swig_wrap_ParametersTest_param10(base SwigcptrParametersTest, _ *int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_ParametersTest_param10, _swig_p) + return +} + +func (arg1 SwigcptrParametersTest) Param10(arg2 *int) { + _swig_wrap_ParametersTest_param10(arg1, arg2) +} + +var _wrap_ParametersTest_param11 unsafe.Pointer + +func _swig_wrap_ParametersTest_param11(base SwigcptrParametersTest, _ *int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_ParametersTest_param11, _swig_p) + return +} + +func (arg1 SwigcptrParametersTest) Param11(arg2 *int) { + _swig_wrap_ParametersTest_param11(arg1, arg2) +} + +var _wrap_ParametersTest_param_array1 unsafe.Pointer + +func _swig_wrap_ParametersTest_param_array1(base SwigcptrParametersTest, _ **int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_ParametersTest_param_array1, _swig_p) + return +} + +func (arg1 SwigcptrParametersTest) Param_array1(arg2 **int) { + _swig_wrap_ParametersTest_param_array1(arg1, arg2) +} + +var _wrap_ParametersTest_param_array2 unsafe.Pointer + +func _swig_wrap_ParametersTest_param_array2(base SwigcptrParametersTest, _ **int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_ParametersTest_param_array2, _swig_p) + return +} + +func (arg1 SwigcptrParametersTest) Param_array2(arg2 **int) { + _swig_wrap_ParametersTest_param_array2(arg1, arg2) +} + +var _wrap_ParametersTest_param_array3 unsafe.Pointer + +func _swig_wrap_ParametersTest_param_array3(base SwigcptrParametersTest, _ **int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_ParametersTest_param_array3, _swig_p) + return +} + +func (arg1 SwigcptrParametersTest) Param_array3(arg2 **int) { + _swig_wrap_ParametersTest_param_array3(arg1, arg2) +} + +var _wrap_ParametersTest_param_array4 unsafe.Pointer + +func _swig_wrap_ParametersTest_param_array4(base SwigcptrParametersTest, _ *int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_ParametersTest_param_array4, _swig_p) + return +} + +func (arg1 SwigcptrParametersTest) Param_array4(arg2 *int) { + _swig_wrap_ParametersTest_param_array4(arg1, arg2) +} + +var _wrap_ParametersTest_param_array5 unsafe.Pointer + +func _swig_wrap_ParametersTest_param_array5(base SwigcptrParametersTest, _ *int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_ParametersTest_param_array5, _swig_p) + return +} + +func (arg1 SwigcptrParametersTest) Param_array5(arg2 *int) { + _swig_wrap_ParametersTest_param_array5(arg1, arg2) +} + +var _wrap_ParametersTest_param_array6 unsafe.Pointer + +func _swig_wrap_ParametersTest_param_array6(base SwigcptrParametersTest, _ **int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_ParametersTest_param_array6, _swig_p) + return +} + +func (arg1 SwigcptrParametersTest) Param_array6(arg2 **int) { + _swig_wrap_ParametersTest_param_array6(arg1, arg2) +} + +var _wrap_new_ParametersTest unsafe.Pointer + +func _swig_wrap_new_ParametersTest() (base SwigcptrParametersTest) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_ParametersTest, _swig_p) + return +} + +func NewParametersTest() (_swig_ret ParametersTest) { + return _swig_wrap_new_ParametersTest() +} + +var _wrap_delete_ParametersTest unsafe.Pointer + +func _swig_wrap_delete_ParametersTest(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_ParametersTest, _swig_p) + return +} + +func DeleteParametersTest(arg1 ParametersTest) { + _swig_wrap_delete_ParametersTest(arg1.Swigcptr()) +} + +type ParametersTest interface { + Swigcptr() uintptr + SwigIsParametersTest() + Param1(arg2 *int) + Param2(arg2 *int) + Param3(arg2 *int) + Param4(arg2 int) + Param5(arg2 int) + Param6(arg2 *int) + Param7(arg2 int) + Param8(arg2 int) + Param9(arg2 **int) + Param10(arg2 *int) + Param11(arg2 *int) + Param_array1(arg2 **int) + Param_array2(arg2 **int) + Param_array3(arg2 **int) + Param_array4(arg2 *int) + Param_array5(arg2 *int) + Param_array6(arg2 **int) +} + +type SwigcptrMemberVariablesTest uintptr + +func (p SwigcptrMemberVariablesTest) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrMemberVariablesTest) SwigIsMemberVariablesTest() { +} + +var _wrap_MemberVariablesTest_member1_set unsafe.Pointer + +func _swig_wrap_MemberVariablesTest_member1_set(base SwigcptrMemberVariablesTest, _ *int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_MemberVariablesTest_member1_set, _swig_p) + return +} + +func (arg1 SwigcptrMemberVariablesTest) SetMember1(arg2 *int) { + _swig_wrap_MemberVariablesTest_member1_set(arg1, arg2) +} + +var _wrap_MemberVariablesTest_member1_get unsafe.Pointer + +func _swig_wrap_MemberVariablesTest_member1_get(base SwigcptrMemberVariablesTest) (_ *int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_MemberVariablesTest_member1_get, _swig_p) + return +} + +func (arg1 SwigcptrMemberVariablesTest) GetMember1() (_swig_ret *int) { + return _swig_wrap_MemberVariablesTest_member1_get(arg1) +} + +var _wrap_MemberVariablesTest_member2_set unsafe.Pointer + +func _swig_wrap_MemberVariablesTest_member2_set(base SwigcptrMemberVariablesTest, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_MemberVariablesTest_member2_set, _swig_p) + return +} + +func (arg1 SwigcptrMemberVariablesTest) SetMember2(arg2 ParametersTest) { + _swig_wrap_MemberVariablesTest_member2_set(arg1, arg2.Swigcptr()) +} + +var _wrap_MemberVariablesTest_member2_get unsafe.Pointer + +func _swig_wrap_MemberVariablesTest_member2_get(base SwigcptrMemberVariablesTest) (_ SwigcptrParametersTest) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_MemberVariablesTest_member2_get, _swig_p) + return +} + +func (arg1 SwigcptrMemberVariablesTest) GetMember2() (_swig_ret ParametersTest) { + return _swig_wrap_MemberVariablesTest_member2_get(arg1) +} + +var _wrap_MemberVariablesTest_member3_get unsafe.Pointer + +func _swig_wrap_MemberVariablesTest_member3_get(base SwigcptrMemberVariablesTest) (_ *int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_MemberVariablesTest_member3_get, _swig_p) + return +} + +func (arg1 SwigcptrMemberVariablesTest) GetMember3() (_swig_ret *int) { + return _swig_wrap_MemberVariablesTest_member3_get(arg1) +} + +var _wrap_MemberVariablesTest_member4_get unsafe.Pointer + +func _swig_wrap_MemberVariablesTest_member4_get(base SwigcptrMemberVariablesTest) (_ SwigcptrParametersTest) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_MemberVariablesTest_member4_get, _swig_p) + return +} + +func (arg1 SwigcptrMemberVariablesTest) GetMember4() (_swig_ret ParametersTest) { + return _swig_wrap_MemberVariablesTest_member4_get(arg1) +} + +var _wrap_MemberVariablesTest_array_member1_set unsafe.Pointer + +func _swig_wrap_MemberVariablesTest_array_member1_set(base SwigcptrMemberVariablesTest, _ **int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_MemberVariablesTest_array_member1_set, _swig_p) + return +} + +func (arg1 SwigcptrMemberVariablesTest) SetArray_member1(arg2 **int) { + _swig_wrap_MemberVariablesTest_array_member1_set(arg1, arg2) +} + +var _wrap_MemberVariablesTest_array_member1_get unsafe.Pointer + +func _swig_wrap_MemberVariablesTest_array_member1_get(base SwigcptrMemberVariablesTest) (_ **int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_MemberVariablesTest_array_member1_get, _swig_p) + return +} + +func (arg1 SwigcptrMemberVariablesTest) GetArray_member1() (_swig_ret **int) { + return _swig_wrap_MemberVariablesTest_array_member1_get(arg1) +} + +var _wrap_MemberVariablesTest_array_member2_set unsafe.Pointer + +func _swig_wrap_MemberVariablesTest_array_member2_set(base SwigcptrMemberVariablesTest, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_MemberVariablesTest_array_member2_set, _swig_p) + return +} + +func (arg1 SwigcptrMemberVariablesTest) SetArray_member2(arg2 ParametersTest) { + _swig_wrap_MemberVariablesTest_array_member2_set(arg1, arg2.Swigcptr()) +} + +var _wrap_MemberVariablesTest_array_member2_get unsafe.Pointer + +func _swig_wrap_MemberVariablesTest_array_member2_get(base SwigcptrMemberVariablesTest) (_ SwigcptrParametersTest) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_MemberVariablesTest_array_member2_get, _swig_p) + return +} + +func (arg1 SwigcptrMemberVariablesTest) GetArray_member2() (_swig_ret ParametersTest) { + return _swig_wrap_MemberVariablesTest_array_member2_get(arg1) +} + +var _wrap_new_MemberVariablesTest unsafe.Pointer + +func _swig_wrap_new_MemberVariablesTest() (base SwigcptrMemberVariablesTest) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_MemberVariablesTest, _swig_p) + return +} + +func NewMemberVariablesTest() (_swig_ret MemberVariablesTest) { + return _swig_wrap_new_MemberVariablesTest() +} + +var _wrap_delete_MemberVariablesTest unsafe.Pointer + +func _swig_wrap_delete_MemberVariablesTest(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_MemberVariablesTest, _swig_p) + return +} + +func DeleteMemberVariablesTest(arg1 MemberVariablesTest) { + _swig_wrap_delete_MemberVariablesTest(arg1.Swigcptr()) +} + +type MemberVariablesTest interface { + Swigcptr() uintptr + SwigIsMemberVariablesTest() + SetMember1(arg2 *int) + GetMember1() (_swig_ret *int) + SetMember2(arg2 ParametersTest) + GetMember2() (_swig_ret ParametersTest) + GetMember3() (_swig_ret *int) + GetMember4() (_swig_ret ParametersTest) + SetArray_member1(arg2 **int) + GetArray_member1() (_swig_ret **int) + SetArray_member2(arg2 ParametersTest) + GetArray_member2() (_swig_ret ParametersTest) +} + +var _wrap_foofunction unsafe.Pointer + +func _swig_wrap_foofunction(base *int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_foofunction, _swig_p) + return +} + +func Foofunction(arg1 *int) { + _swig_wrap_foofunction(arg1) +} + +var _wrap_int1_set unsafe.Pointer + +func _swig_wrap_int1_set(base int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_int1_set, _swig_p) + return +} + +func SetInt1(arg1 int) { + _swig_wrap_int1_set(arg1) +} + +var _wrap_int1_get unsafe.Pointer + +func GetInt1() (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_int1_get, _swig_p) + return +} +var _wrap_int2_set unsafe.Pointer + +func _swig_wrap_int2_set(base int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_int2_set, _swig_p) + return +} + +func SetInt2(arg1 int) { + _swig_wrap_int2_set(arg1) +} + +var _wrap_int2_get unsafe.Pointer + +func GetInt2() (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_int2_get, _swig_p) + return +} +var _wrap_int3_set unsafe.Pointer + +func _swig_wrap_int3_set(base *int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_int3_set, _swig_p) + return +} + +func SetInt3(arg1 *int) { + _swig_wrap_int3_set(arg1) +} + +var _wrap_int3_get unsafe.Pointer + +func GetInt3() (_swig_ret *int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_int3_get, _swig_p) + return +} +var _wrap_int4_get unsafe.Pointer + +func GetInt4() (_swig_ret *int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_int4_get, _swig_p) + return +} +var _wrap_global_const_int_ptr_array_get unsafe.Pointer + +func GetGlobal_const_int_ptr_array() (_swig_ret **int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_global_const_int_ptr_array_get, _swig_p) + return +} +var _wrap_array_member4_get unsafe.Pointer + +func GetArray_member4() (_swig_ret uintptr) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_array_member4_get, _swig_p) + return +} +type SwigcptrReturnValuesTest uintptr + +func (p SwigcptrReturnValuesTest) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrReturnValuesTest) SwigIsReturnValuesTest() { +} + +var _wrap_ReturnValuesTest_td1_set unsafe.Pointer + +func _swig_wrap_ReturnValuesTest_td1_set(base SwigcptrReturnValuesTest, _ *int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_ReturnValuesTest_td1_set, _swig_p) + return +} + +func (arg1 SwigcptrReturnValuesTest) SetTd1(arg2 *int) { + _swig_wrap_ReturnValuesTest_td1_set(arg1, arg2) +} + +var _wrap_ReturnValuesTest_td1_get unsafe.Pointer + +func _swig_wrap_ReturnValuesTest_td1_get(base SwigcptrReturnValuesTest) (_ *int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_ReturnValuesTest_td1_get, _swig_p) + return +} + +func (arg1 SwigcptrReturnValuesTest) GetTd1() (_swig_ret *int) { + return _swig_wrap_ReturnValuesTest_td1_get(arg1) +} + +var _wrap_ReturnValuesTest_td2_set unsafe.Pointer + +func _swig_wrap_ReturnValuesTest_td2_set(base SwigcptrReturnValuesTest, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_ReturnValuesTest_td2_set, _swig_p) + return +} + +func (arg1 SwigcptrReturnValuesTest) SetTd2(arg2 int) { + _swig_wrap_ReturnValuesTest_td2_set(arg1, arg2) +} + +var _wrap_ReturnValuesTest_td2_get unsafe.Pointer + +func _swig_wrap_ReturnValuesTest_td2_get(base SwigcptrReturnValuesTest) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_ReturnValuesTest_td2_get, _swig_p) + return +} + +func (arg1 SwigcptrReturnValuesTest) GetTd2() (_swig_ret int) { + return _swig_wrap_ReturnValuesTest_td2_get(arg1) +} + +var _wrap_ReturnValuesTest_int1_set unsafe.Pointer + +func _swig_wrap_ReturnValuesTest_int1_set(base SwigcptrReturnValuesTest, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_ReturnValuesTest_int1_set, _swig_p) + return +} + +func (arg1 SwigcptrReturnValuesTest) SetInt1(arg2 int) { + _swig_wrap_ReturnValuesTest_int1_set(arg1, arg2) +} + +var _wrap_ReturnValuesTest_int1_get unsafe.Pointer + +func _swig_wrap_ReturnValuesTest_int1_get(base SwigcptrReturnValuesTest) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_ReturnValuesTest_int1_get, _swig_p) + return +} + +func (arg1 SwigcptrReturnValuesTest) GetInt1() (_swig_ret int) { + return _swig_wrap_ReturnValuesTest_int1_get(arg1) +} + +var _wrap_ReturnValuesTest_int2_set unsafe.Pointer + +func _swig_wrap_ReturnValuesTest_int2_set(base SwigcptrReturnValuesTest, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_ReturnValuesTest_int2_set, _swig_p) + return +} + +func (arg1 SwigcptrReturnValuesTest) SetInt2(arg2 int) { + _swig_wrap_ReturnValuesTest_int2_set(arg1, arg2) +} + +var _wrap_ReturnValuesTest_int2_get unsafe.Pointer + +func _swig_wrap_ReturnValuesTest_int2_get(base SwigcptrReturnValuesTest) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_ReturnValuesTest_int2_get, _swig_p) + return +} + +func (arg1 SwigcptrReturnValuesTest) GetInt2() (_swig_ret int) { + return _swig_wrap_ReturnValuesTest_int2_get(arg1) +} + +var _wrap_ReturnValuesTest_int3_get unsafe.Pointer + +func _swig_wrap_ReturnValuesTest_int3_get(base SwigcptrReturnValuesTest) (_ *int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_ReturnValuesTest_int3_get, _swig_p) + return +} + +func (arg1 SwigcptrReturnValuesTest) GetInt3() (_swig_ret *int) { + return _swig_wrap_ReturnValuesTest_int3_get(arg1) +} + +var _wrap_ReturnValuesTest_int4_set unsafe.Pointer + +func _swig_wrap_ReturnValuesTest_int4_set(base SwigcptrReturnValuesTest, _ *int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_ReturnValuesTest_int4_set, _swig_p) + return +} + +func (arg1 SwigcptrReturnValuesTest) SetInt4(arg2 *int) { + _swig_wrap_ReturnValuesTest_int4_set(arg1, arg2) +} + +var _wrap_ReturnValuesTest_int4_get unsafe.Pointer + +func _swig_wrap_ReturnValuesTest_int4_get(base SwigcptrReturnValuesTest) (_ *int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_ReturnValuesTest_int4_get, _swig_p) + return +} + +func (arg1 SwigcptrReturnValuesTest) GetInt4() (_swig_ret *int) { + return _swig_wrap_ReturnValuesTest_int4_get(arg1) +} + +var _wrap_ReturnValuesTest_array1_set unsafe.Pointer + +func _swig_wrap_ReturnValuesTest_array1_set(base SwigcptrReturnValuesTest, _ *int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_ReturnValuesTest_array1_set, _swig_p) + return +} + +func (arg1 SwigcptrReturnValuesTest) SetArray1(arg2 *int) { + _swig_wrap_ReturnValuesTest_array1_set(arg1, arg2) +} + +var _wrap_ReturnValuesTest_array1_get unsafe.Pointer + +func _swig_wrap_ReturnValuesTest_array1_get(base SwigcptrReturnValuesTest) (_ *int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_ReturnValuesTest_array1_get, _swig_p) + return +} + +func (arg1 SwigcptrReturnValuesTest) GetArray1() (_swig_ret *int) { + return _swig_wrap_ReturnValuesTest_array1_get(arg1) +} + +var _wrap_ReturnValuesTest_ret1 unsafe.Pointer + +func _swig_wrap_ReturnValuesTest_ret1(base SwigcptrReturnValuesTest) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_ReturnValuesTest_ret1, _swig_p) + return +} + +func (arg1 SwigcptrReturnValuesTest) Ret1() (_swig_ret int) { + return _swig_wrap_ReturnValuesTest_ret1(arg1) +} + +var _wrap_ReturnValuesTest_ret2 unsafe.Pointer + +func _swig_wrap_ReturnValuesTest_ret2(base SwigcptrReturnValuesTest) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_ReturnValuesTest_ret2, _swig_p) + return +} + +func (arg1 SwigcptrReturnValuesTest) Ret2() (_swig_ret int) { + return _swig_wrap_ReturnValuesTest_ret2(arg1) +} + +var _wrap_ReturnValuesTest_ret3 unsafe.Pointer + +func _swig_wrap_ReturnValuesTest_ret3(base SwigcptrReturnValuesTest) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_ReturnValuesTest_ret3, _swig_p) + return +} + +func (arg1 SwigcptrReturnValuesTest) Ret3() (_swig_ret int) { + return _swig_wrap_ReturnValuesTest_ret3(arg1) +} + +var _wrap_ReturnValuesTest_ret4 unsafe.Pointer + +func _swig_wrap_ReturnValuesTest_ret4(base SwigcptrReturnValuesTest) (_ *int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_ReturnValuesTest_ret4, _swig_p) + return +} + +func (arg1 SwigcptrReturnValuesTest) Ret4() (_swig_ret *int) { + return _swig_wrap_ReturnValuesTest_ret4(arg1) +} + +var _wrap_ReturnValuesTest_ret5 unsafe.Pointer + +func _swig_wrap_ReturnValuesTest_ret5(base SwigcptrReturnValuesTest) (_ *int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_ReturnValuesTest_ret5, _swig_p) + return +} + +func (arg1 SwigcptrReturnValuesTest) Ret5() (_swig_ret *int) { + return _swig_wrap_ReturnValuesTest_ret5(arg1) +} + +var _wrap_ReturnValuesTest_ret6 unsafe.Pointer + +func _swig_wrap_ReturnValuesTest_ret6(base SwigcptrReturnValuesTest, _ **int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_ReturnValuesTest_ret6, _swig_p) + return +} + +func (arg1 SwigcptrReturnValuesTest) Ret6(arg2 **int) { + _swig_wrap_ReturnValuesTest_ret6(arg1, arg2) +} + +var _wrap_ReturnValuesTest_ret7 unsafe.Pointer + +func _swig_wrap_ReturnValuesTest_ret7(base SwigcptrReturnValuesTest) (_ **int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_ReturnValuesTest_ret7, _swig_p) + return +} + +func (arg1 SwigcptrReturnValuesTest) Ret7() (_swig_ret **int) { + return _swig_wrap_ReturnValuesTest_ret7(arg1) +} + +var _wrap_ReturnValuesTest_ret8 unsafe.Pointer + +func _swig_wrap_ReturnValuesTest_ret8(base SwigcptrReturnValuesTest, _ *int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_ReturnValuesTest_ret8, _swig_p) + return +} + +func (arg1 SwigcptrReturnValuesTest) Ret8(arg2 *int) { + _swig_wrap_ReturnValuesTest_ret8(arg1, arg2) +} + +var _wrap_ReturnValuesTest_ret9 unsafe.Pointer + +func _swig_wrap_ReturnValuesTest_ret9(base SwigcptrReturnValuesTest) (_ *int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_ReturnValuesTest_ret9, _swig_p) + return +} + +func (arg1 SwigcptrReturnValuesTest) Ret9() (_swig_ret *int) { + return _swig_wrap_ReturnValuesTest_ret9(arg1) +} + +var _wrap_new_ReturnValuesTest unsafe.Pointer + +func _swig_wrap_new_ReturnValuesTest() (base SwigcptrReturnValuesTest) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_ReturnValuesTest, _swig_p) + return +} + +func NewReturnValuesTest() (_swig_ret ReturnValuesTest) { + return _swig_wrap_new_ReturnValuesTest() +} + +var _wrap_delete_ReturnValuesTest unsafe.Pointer + +func _swig_wrap_delete_ReturnValuesTest(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_ReturnValuesTest, _swig_p) + return +} + +func DeleteReturnValuesTest(arg1 ReturnValuesTest) { + _swig_wrap_delete_ReturnValuesTest(arg1.Swigcptr()) +} + +type ReturnValuesTest interface { + Swigcptr() uintptr + SwigIsReturnValuesTest() + SetTd1(arg2 *int) + GetTd1() (_swig_ret *int) + SetTd2(arg2 int) + GetTd2() (_swig_ret int) + SetInt1(arg2 int) + GetInt1() (_swig_ret int) + SetInt2(arg2 int) + GetInt2() (_swig_ret int) + GetInt3() (_swig_ret *int) + SetInt4(arg2 *int) + GetInt4() (_swig_ret *int) + SetArray1(arg2 *int) + GetArray1() (_swig_ret *int) + Ret1() (_swig_ret int) + Ret2() (_swig_ret int) + Ret3() (_swig_ret int) + Ret4() (_swig_ret *int) + Ret5() (_swig_ret *int) + Ret6(arg2 **int) + Ret7() (_swig_ret **int) + Ret8(arg2 *int) + Ret9() (_swig_ret *int) +} + +var _wrap_globalRet1 unsafe.Pointer + +func GlobalRet1() (_swig_ret *int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_globalRet1, _swig_p) + return +} +var _wrap_globalRet2 unsafe.Pointer + +func GlobalRet2() (_swig_ret *int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_globalRet2, _swig_p) + return +} +var _wrap_opaque unsafe.Pointer + +func _swig_wrap_opaque(base uintptr) (_ SwigcptrA) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_opaque, _swig_p) + return +} + +func Opaque(arg1 A) (_swig_ret A) { + return _swig_wrap_opaque(arg1.Swigcptr()) +} + +type SwigcptrB uintptr + +func (p SwigcptrB) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrB) SwigIsB() { +} + +var _wrap_new_B unsafe.Pointer + +func _swig_wrap_new_B() (base SwigcptrB) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_B, _swig_p) + return +} + +func NewB() (_swig_ret B) { + return _swig_wrap_new_B() +} + +var _wrap_B_ca_get unsafe.Pointer + +func _swig_wrap_B_ca_get(base SwigcptrB) (_ SwigcptrA) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_B_ca_get, _swig_p) + return +} + +func (arg1 SwigcptrB) GetCa() (_swig_ret A) { + return _swig_wrap_B_ca_get(arg1) +} + +var _wrap_B_a_set unsafe.Pointer + +func _swig_wrap_B_a_set(base SwigcptrB, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_B_a_set, _swig_p) + return +} + +func (arg1 SwigcptrB) SetA(arg2 A) { + _swig_wrap_B_a_set(arg1, arg2.Swigcptr()) +} + +var _wrap_B_a_get unsafe.Pointer + +func _swig_wrap_B_a_get(base SwigcptrB) (_ SwigcptrA) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_B_a_get, _swig_p) + return +} + +func (arg1 SwigcptrB) GetA() (_swig_ret A) { + return _swig_wrap_B_a_get(arg1) +} + +var _wrap_B_ap_set unsafe.Pointer + +func _swig_wrap_B_ap_set(base SwigcptrB, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_B_ap_set, _swig_p) + return +} + +func (arg1 SwigcptrB) SetAp(arg2 A) { + _swig_wrap_B_ap_set(arg1, arg2.Swigcptr()) +} + +var _wrap_B_ap_get unsafe.Pointer + +func _swig_wrap_B_ap_get(base SwigcptrB) (_ SwigcptrA) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_B_ap_get, _swig_p) + return +} + +func (arg1 SwigcptrB) GetAp() (_swig_ret A) { + return _swig_wrap_B_ap_get(arg1) +} + +var _wrap_B_cap_set unsafe.Pointer + +func _swig_wrap_B_cap_set(base SwigcptrB, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_B_cap_set, _swig_p) + return +} + +func (arg1 SwigcptrB) SetCap(arg2 A) { + _swig_wrap_B_cap_set(arg1, arg2.Swigcptr()) +} + +var _wrap_B_cap_get unsafe.Pointer + +func _swig_wrap_B_cap_get(base SwigcptrB) (_ SwigcptrA) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_B_cap_get, _swig_p) + return +} + +func (arg1 SwigcptrB) GetCap() (_swig_ret A) { + return _swig_wrap_B_cap_get(arg1) +} + +var _wrap_B_acptr_set unsafe.Pointer + +func _swig_wrap_B_acptr_set(base SwigcptrB, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_B_acptr_set, _swig_p) + return +} + +func (arg1 SwigcptrB) SetAcptr(arg2 A) { + _swig_wrap_B_acptr_set(arg1, arg2.Swigcptr()) +} + +var _wrap_B_acptr_get unsafe.Pointer + +func _swig_wrap_B_acptr_get(base SwigcptrB) (_ SwigcptrA) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_B_acptr_get, _swig_p) + return +} + +func (arg1 SwigcptrB) GetAcptr() (_swig_ret A) { + return _swig_wrap_B_acptr_get(arg1) +} + +var _wrap_delete_B unsafe.Pointer + +func _swig_wrap_delete_B(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_B, _swig_p) + return +} + +func DeleteB(arg1 B) { + _swig_wrap_delete_B(arg1.Swigcptr()) +} + +type B interface { + Swigcptr() uintptr + SwigIsB() + GetCa() (_swig_ret A) + SetA(arg2 A) + GetA() (_swig_ret A) + SetAp(arg2 A) + GetAp() (_swig_ret A) + SetCap(arg2 A) + GetCap() (_swig_ret A) + SetAcptr(arg2 A) + GetAcptr() (_swig_ret A) +} + +var _wrap_bar unsafe.Pointer + +func _swig_wrap_bar(base uintptr) (_ SwigcptrB) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_bar, _swig_p) + return +} + +func Bar(arg1 B) (_swig_ret B) { + return _swig_wrap_bar(arg1.Swigcptr()) +} + +var _wrap_cbar unsafe.Pointer + +func _swig_wrap_cbar(base uintptr) (_ SwigcptrB) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_cbar, _swig_p) + return +} + +func Cbar(arg1 B) (_swig_ret B) { + return _swig_wrap_cbar(arg1.Swigcptr()) +} + +var _wrap_wxEVENT_COMMAND_BUTTON_CLICKEDr_set unsafe.Pointer + +func _swig_wrap_wxEVENT_COMMAND_BUTTON_CLICKEDr_set(base *int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_wxEVENT_COMMAND_BUTTON_CLICKEDr_set, _swig_p) + return +} + +func SetWxEVENT_COMMAND_BUTTON_CLICKEDr(arg1 *int) { + _swig_wrap_wxEVENT_COMMAND_BUTTON_CLICKEDr_set(arg1) +} + +var _wrap_wxEVENT_COMMAND_BUTTON_CLICKEDr_get unsafe.Pointer + +func GetWxEVENT_COMMAND_BUTTON_CLICKEDr() (_swig_ret *int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_wxEVENT_COMMAND_BUTTON_CLICKEDr_get, _swig_p) + return +} +var _wrap_wxEVENT_COMMAND_BUTTON_CLICKEDp_set unsafe.Pointer + +func _swig_wrap_wxEVENT_COMMAND_BUTTON_CLICKEDp_set(base *int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_wxEVENT_COMMAND_BUTTON_CLICKEDp_set, _swig_p) + return +} + +func SetWxEVENT_COMMAND_BUTTON_CLICKEDp(arg1 *int) { + _swig_wrap_wxEVENT_COMMAND_BUTTON_CLICKEDp_set(arg1) +} + +var _wrap_wxEVENT_COMMAND_BUTTON_CLICKEDp_get unsafe.Pointer + +func GetWxEVENT_COMMAND_BUTTON_CLICKEDp() (_swig_ret *int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_wxEVENT_COMMAND_BUTTON_CLICKEDp_get, _swig_p) + return +} +var _wrap_languages1_set unsafe.Pointer + +func _swig_wrap_languages1_set(base *string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_languages1_set, _swig_p) + return +} + +func SetLanguages1(arg1 *string) { + _swig_wrap_languages1_set(arg1) +} + +var _wrap_languages1_get unsafe.Pointer + +func GetLanguages1() (_swig_ret *string) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_languages1_get, _swig_p) + return +} +var _wrap_languages2_set unsafe.Pointer + +func _swig_wrap_languages2_set(base *string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_languages2_set, _swig_p) + return +} + +func SetLanguages2(arg1 *string) { + _swig_wrap_languages2_set(arg1) +} + +var _wrap_languages2_get unsafe.Pointer + +func GetLanguages2() (_swig_ret *string) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_languages2_get, _swig_p) + return +} +type SwigcptrFoo uintptr + +func (p SwigcptrFoo) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrFoo) SwigIsFoo() { +} + +var _wrap_Foo_icap_set unsafe.Pointer + +func _swig_wrap_Foo_icap_set(base SwigcptrFoo, _ *int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_icap_set, _swig_p) + return +} + +func (arg1 SwigcptrFoo) SetIcap(arg2 *int) { + _swig_wrap_Foo_icap_set(arg1, arg2) +} + +var _wrap_Foo_icap_get unsafe.Pointer + +func _swig_wrap_Foo_icap_get(base SwigcptrFoo) (_ *int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_icap_get, _swig_p) + return +} + +func (arg1 SwigcptrFoo) GetIcap() (_swig_ret *int) { + return _swig_wrap_Foo_icap_get(arg1) +} + +var _wrap_new_Foo unsafe.Pointer + +func _swig_wrap_new_Foo() (base SwigcptrFoo) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Foo, _swig_p) + return +} + +func NewFoo() (_swig_ret Foo) { + return _swig_wrap_new_Foo() +} + +var _wrap_delete_Foo unsafe.Pointer + +func _swig_wrap_delete_Foo(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Foo, _swig_p) + return +} + +func DeleteFoo(arg1 Foo) { + _swig_wrap_delete_Foo(arg1.Swigcptr()) +} + +type Foo interface { + Swigcptr() uintptr + SwigIsFoo() + SetIcap(arg2 *int) + GetIcap() (_swig_ret *int) +} + +var _wrap_icap_set unsafe.Pointer + +func _swig_wrap_icap_set(base *int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_icap_set, _swig_p) + return +} + +func SetIcap(arg1 *int) { + _swig_wrap_icap_set(arg1) +} + +var _wrap_icap_get unsafe.Pointer + +func GetIcap() (_swig_ret *int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_icap_get, _swig_p) + return +} +var _wrap_cap_set unsafe.Pointer + +func _swig_wrap_cap_set(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_cap_set, _swig_p) + return +} + +func SetCap(arg1 Foo) { + _swig_wrap_cap_set(arg1.Swigcptr()) +} + +var _wrap_cap_get unsafe.Pointer + +func _swig_wrap_cap_get() (base SwigcptrFoo) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_cap_get, _swig_p) + return +} + +func GetCap() (_swig_ret Foo) { + return _swig_wrap_cap_get() +} + + +type SwigcptrA uintptr +type A interface { + Swigcptr() uintptr; +} +func (p SwigcptrA) Swigcptr() uintptr { + return uintptr(p) +} + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/constover.go b/Examples/test-suite/go/constover.go new file mode 100644 index 000000000..7f46c8619 --- /dev/null +++ b/Examples/test-suite/go/constover.go @@ -0,0 +1,141 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../constover.i + +package constover + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +var _wrap_test unsafe.Pointer + +func Test(arg1 string) (_swig_ret string) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_test, _swig_p) + return +} +var _wrap_test_pconst unsafe.Pointer + +func Test_pconst(arg1 string) (_swig_ret string) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_test_pconst, _swig_p) + return +} +type SwigcptrFoo uintptr + +func (p SwigcptrFoo) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrFoo) SwigIsFoo() { +} + +var _wrap_new_Foo unsafe.Pointer + +func _swig_wrap_new_Foo() (base SwigcptrFoo) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Foo, _swig_p) + return +} + +func NewFoo() (_swig_ret Foo) { + return _swig_wrap_new_Foo() +} + +var _wrap_Foo_test unsafe.Pointer + +func _swig_wrap_Foo_test(base SwigcptrFoo, _ string) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_test, _swig_p) + return +} + +func (arg1 SwigcptrFoo) Test(arg2 string) (_swig_ret string) { + return _swig_wrap_Foo_test(arg1, arg2) +} + +var _wrap_Foo_test_pconst unsafe.Pointer + +func _swig_wrap_Foo_test_pconst(base SwigcptrFoo, _ string) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_test_pconst, _swig_p) + return +} + +func (arg1 SwigcptrFoo) Test_pconst(arg2 string) (_swig_ret string) { + return _swig_wrap_Foo_test_pconst(arg1, arg2) +} + +var _wrap_Foo_test_constm unsafe.Pointer + +func _swig_wrap_Foo_test_constm(base SwigcptrFoo, _ string) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_test_constm, _swig_p) + return +} + +func (arg1 SwigcptrFoo) Test_constm(arg2 string) (_swig_ret string) { + return _swig_wrap_Foo_test_constm(arg1, arg2) +} + +var _wrap_Foo_test_pconstm unsafe.Pointer + +func _swig_wrap_Foo_test_pconstm(base SwigcptrFoo, _ string) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_test_pconstm, _swig_p) + return +} + +func (arg1 SwigcptrFoo) Test_pconstm(arg2 string) (_swig_ret string) { + return _swig_wrap_Foo_test_pconstm(arg1, arg2) +} + +var _wrap_delete_Foo unsafe.Pointer + +func _swig_wrap_delete_Foo(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Foo, _swig_p) + return +} + +func DeleteFoo(arg1 Foo) { + _swig_wrap_delete_Foo(arg1.Swigcptr()) +} + +type Foo interface { + Swigcptr() uintptr + SwigIsFoo() + Test(arg2 string) (_swig_ret string) + Test_pconst(arg2 string) (_swig_ret string) + Test_constm(arg2 string) (_swig_ret string) + Test_pconstm(arg2 string) (_swig_ret string) +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/constover_runme b/Examples/test-suite/go/constover_runme new file mode 100755 index 000000000..5e39bbb3b Binary files /dev/null and b/Examples/test-suite/go/constover_runme differ diff --git a/Examples/test-suite/go/constructor_copy.go b/Examples/test-suite/go/constructor_copy.go new file mode 100644 index 000000000..8ee7fc93d --- /dev/null +++ b/Examples/test-suite/go/constructor_copy.go @@ -0,0 +1,1012 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../constructor_copy.i + +package constructor_copy + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrFoo1 uintptr + +func (p SwigcptrFoo1) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrFoo1) SwigIsFoo1() { +} + +var _wrap_Foo1_x_set unsafe.Pointer + +func _swig_wrap_Foo1_x_set(base SwigcptrFoo1, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo1_x_set, _swig_p) + return +} + +func (arg1 SwigcptrFoo1) SetX(arg2 int) { + _swig_wrap_Foo1_x_set(arg1, arg2) +} + +var _wrap_Foo1_x_get unsafe.Pointer + +func _swig_wrap_Foo1_x_get(base SwigcptrFoo1) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo1_x_get, _swig_p) + return +} + +func (arg1 SwigcptrFoo1) GetX() (_swig_ret int) { + return _swig_wrap_Foo1_x_get(arg1) +} + +var _wrap_new_Foo1__SWIG_0 unsafe.Pointer + +func _swig_wrap_new_Foo1__SWIG_0(base int) (_ SwigcptrFoo1) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Foo1__SWIG_0, _swig_p) + return +} + +func NewFoo1__SWIG_0(arg1 int) (_swig_ret Foo1) { + return _swig_wrap_new_Foo1__SWIG_0(arg1) +} + +var _wrap_new_Foo1__SWIG_1 unsafe.Pointer + +func _swig_wrap_new_Foo1__SWIG_1() (base SwigcptrFoo1) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Foo1__SWIG_1, _swig_p) + return +} + +func NewFoo1__SWIG_1() (_swig_ret Foo1) { + return _swig_wrap_new_Foo1__SWIG_1() +} + +var _wrap_new_Foo1__SWIG_2 unsafe.Pointer + +func _swig_wrap_new_Foo1__SWIG_2(base uintptr) (_ SwigcptrFoo1) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Foo1__SWIG_2, _swig_p) + return +} + +func NewFoo1__SWIG_2(arg1 Foo1) (_swig_ret Foo1) { + return _swig_wrap_new_Foo1__SWIG_2(arg1.Swigcptr()) +} + +func NewFoo1(a ...interface{}) Foo1 { + argc := len(a) + if argc == 0 { + return NewFoo1__SWIG_1() + } + if argc == 1 { + if _, ok := a[0].(Foo1); !ok { + goto check_2 + } + return NewFoo1__SWIG_2(a[0].(Foo1)) + } +check_2: + if argc == 1 { + return NewFoo1__SWIG_0(a[0].(int)) + } + panic("No match for overloaded function call") +} + +var _wrap_delete_Foo1 unsafe.Pointer + +func _swig_wrap_delete_Foo1(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Foo1, _swig_p) + return +} + +func DeleteFoo1(arg1 Foo1) { + _swig_wrap_delete_Foo1(arg1.Swigcptr()) +} + +type Foo1 interface { + Swigcptr() uintptr + SwigIsFoo1() + SetX(arg2 int) + GetX() (_swig_ret int) +} + +type SwigcptrFoo2 uintptr + +func (p SwigcptrFoo2) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrFoo2) SwigIsFoo2() { +} + +var _wrap_new_Foo2__SWIG_0 unsafe.Pointer + +func _swig_wrap_new_Foo2__SWIG_0() (base SwigcptrFoo2) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Foo2__SWIG_0, _swig_p) + return +} + +func NewFoo2__SWIG_0() (_swig_ret Foo2) { + return _swig_wrap_new_Foo2__SWIG_0() +} + +var _wrap_new_Foo2__SWIG_1 unsafe.Pointer + +func _swig_wrap_new_Foo2__SWIG_1(base uintptr) (_ SwigcptrFoo2) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Foo2__SWIG_1, _swig_p) + return +} + +func NewFoo2__SWIG_1(arg1 Foo2) (_swig_ret Foo2) { + return _swig_wrap_new_Foo2__SWIG_1(arg1.Swigcptr()) +} + +func NewFoo2(a ...interface{}) Foo2 { + argc := len(a) + if argc == 0 { + return NewFoo2__SWIG_0() + } + if argc == 1 { + return NewFoo2__SWIG_1(a[0].(Foo2)) + } + panic("No match for overloaded function call") +} + +var _wrap_delete_Foo2 unsafe.Pointer + +func _swig_wrap_delete_Foo2(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Foo2, _swig_p) + return +} + +func DeleteFoo2(arg1 Foo2) { + _swig_wrap_delete_Foo2(arg1.Swigcptr()) +} + +type Foo2 interface { + Swigcptr() uintptr + SwigIsFoo2() +} + +type SwigcptrFoo3 uintptr + +func (p SwigcptrFoo3) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrFoo3) SwigIsFoo3() { +} + +var _wrap_new_Foo3__SWIG_0 unsafe.Pointer + +func _swig_wrap_new_Foo3__SWIG_0() (base SwigcptrFoo3) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Foo3__SWIG_0, _swig_p) + return +} + +func NewFoo3__SWIG_0() (_swig_ret Foo3) { + return _swig_wrap_new_Foo3__SWIG_0() +} + +var _wrap_new_Foo3__SWIG_1 unsafe.Pointer + +func _swig_wrap_new_Foo3__SWIG_1(base uintptr) (_ SwigcptrFoo3) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Foo3__SWIG_1, _swig_p) + return +} + +func NewFoo3__SWIG_1(arg1 Foo3) (_swig_ret Foo3) { + return _swig_wrap_new_Foo3__SWIG_1(arg1.Swigcptr()) +} + +func NewFoo3(a ...interface{}) Foo3 { + argc := len(a) + if argc == 0 { + return NewFoo3__SWIG_0() + } + if argc == 1 { + return NewFoo3__SWIG_1(a[0].(Foo3)) + } + panic("No match for overloaded function call") +} + +var _wrap_delete_Foo3 unsafe.Pointer + +func _swig_wrap_delete_Foo3(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Foo3, _swig_p) + return +} + +func DeleteFoo3(arg1 Foo3) { + _swig_wrap_delete_Foo3(arg1.Swigcptr()) +} + +type Foo3 interface { + Swigcptr() uintptr + SwigIsFoo3() +} + +type SwigcptrFoo4 uintptr + +func (p SwigcptrFoo4) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrFoo4) SwigIsFoo4() { +} + +var _wrap_new_Foo4 unsafe.Pointer + +func _swig_wrap_new_Foo4() (base SwigcptrFoo4) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Foo4, _swig_p) + return +} + +func NewFoo4() (_swig_ret Foo4) { + return _swig_wrap_new_Foo4() +} + +var _wrap_delete_Foo4 unsafe.Pointer + +func _swig_wrap_delete_Foo4(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Foo4, _swig_p) + return +} + +func DeleteFoo4(arg1 Foo4) { + _swig_wrap_delete_Foo4(arg1.Swigcptr()) +} + +type Foo4 interface { + Swigcptr() uintptr + SwigIsFoo4() +} + +type SwigcptrFoo4a uintptr + +func (p SwigcptrFoo4a) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrFoo4a) SwigIsFoo4a() { +} + +var _wrap_new_Foo4a unsafe.Pointer + +func _swig_wrap_new_Foo4a() (base SwigcptrFoo4a) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Foo4a, _swig_p) + return +} + +func NewFoo4a() (_swig_ret Foo4a) { + return _swig_wrap_new_Foo4a() +} + +var _wrap_delete_Foo4a unsafe.Pointer + +func _swig_wrap_delete_Foo4a(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Foo4a, _swig_p) + return +} + +func DeleteFoo4a(arg1 Foo4a) { + _swig_wrap_delete_Foo4a(arg1.Swigcptr()) +} + +type Foo4a interface { + Swigcptr() uintptr + SwigIsFoo4a() +} + +type SwigcptrFoo5 uintptr + +func (p SwigcptrFoo5) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrFoo5) SwigIsFoo5() { +} + +var _wrap_new_Foo5__SWIG_0 unsafe.Pointer + +func _swig_wrap_new_Foo5__SWIG_0() (base SwigcptrFoo5) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Foo5__SWIG_0, _swig_p) + return +} + +func NewFoo5__SWIG_0() (_swig_ret Foo5) { + return _swig_wrap_new_Foo5__SWIG_0() +} + +var _wrap_new_Foo5__SWIG_1 unsafe.Pointer + +func _swig_wrap_new_Foo5__SWIG_1(base uintptr) (_ SwigcptrFoo5) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Foo5__SWIG_1, _swig_p) + return +} + +func NewFoo5__SWIG_1(arg1 Foo5) (_swig_ret Foo5) { + return _swig_wrap_new_Foo5__SWIG_1(arg1.Swigcptr()) +} + +func NewFoo5(a ...interface{}) Foo5 { + argc := len(a) + if argc == 0 { + return NewFoo5__SWIG_0() + } + if argc == 1 { + return NewFoo5__SWIG_1(a[0].(Foo5)) + } + panic("No match for overloaded function call") +} + +var _wrap_delete_Foo5 unsafe.Pointer + +func _swig_wrap_delete_Foo5(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Foo5, _swig_p) + return +} + +func DeleteFoo5(arg1 Foo5) { + _swig_wrap_delete_Foo5(arg1.Swigcptr()) +} + +func (p SwigcptrFoo5) SwigIsFoo4() { +} + +func (p SwigcptrFoo5) SwigGetFoo4() Foo4 { + return SwigcptrFoo4(p.Swigcptr()) +} + +type Foo5 interface { + Swigcptr() uintptr + SwigIsFoo5() + SwigIsFoo4() + SwigGetFoo4() Foo4 +} + +type SwigcptrFoo6 uintptr + +func (p SwigcptrFoo6) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrFoo6) SwigIsFoo6() { +} + +var _wrap_new_Foo6 unsafe.Pointer + +func _swig_wrap_new_Foo6(base uintptr) (_ SwigcptrFoo6) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Foo6, _swig_p) + return +} + +func NewFoo6(arg1 Foo6) (_swig_ret Foo6) { + return _swig_wrap_new_Foo6(arg1.Swigcptr()) +} + +var _wrap_delete_Foo6 unsafe.Pointer + +func _swig_wrap_delete_Foo6(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Foo6, _swig_p) + return +} + +func DeleteFoo6(arg1 Foo6) { + _swig_wrap_delete_Foo6(arg1.Swigcptr()) +} + +func (p SwigcptrFoo6) SwigIsFoo4() { +} + +func (p SwigcptrFoo6) SwigGetFoo4() Foo4 { + return SwigcptrFoo4(p.Swigcptr()) +} + +type Foo6 interface { + Swigcptr() uintptr + SwigIsFoo6() + SwigIsFoo4() + SwigGetFoo4() Foo4 +} + +type SwigcptrFoo7 uintptr + +func (p SwigcptrFoo7) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrFoo7) SwigIsFoo7() { +} + +var _wrap_new_Foo7__SWIG_0 unsafe.Pointer + +func _swig_wrap_new_Foo7__SWIG_0() (base SwigcptrFoo7) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Foo7__SWIG_0, _swig_p) + return +} + +func NewFoo7__SWIG_0() (_swig_ret Foo7) { + return _swig_wrap_new_Foo7__SWIG_0() +} + +var _wrap_new_Foo7__SWIG_1 unsafe.Pointer + +func _swig_wrap_new_Foo7__SWIG_1(base uintptr) (_ SwigcptrFoo7) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Foo7__SWIG_1, _swig_p) + return +} + +func NewFoo7__SWIG_1(arg1 Foo7) (_swig_ret Foo7) { + return _swig_wrap_new_Foo7__SWIG_1(arg1.Swigcptr()) +} + +func NewFoo7(a ...interface{}) Foo7 { + argc := len(a) + if argc == 0 { + return NewFoo7__SWIG_0() + } + if argc == 1 { + return NewFoo7__SWIG_1(a[0].(Foo7)) + } + panic("No match for overloaded function call") +} + +var _wrap_delete_Foo7 unsafe.Pointer + +func _swig_wrap_delete_Foo7(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Foo7, _swig_p) + return +} + +func DeleteFoo7(arg1 Foo7) { + _swig_wrap_delete_Foo7(arg1.Swigcptr()) +} + +func (p SwigcptrFoo7) SwigIsFoo5() { +} + +func (p SwigcptrFoo7) SwigGetFoo5() Foo5 { + return SwigcptrFoo5(p.Swigcptr()) +} + +func (p SwigcptrFoo7) SwigIsFoo4() { +} + +func (p SwigcptrFoo7) SwigGetFoo4() Foo4 { + return SwigcptrFoo4(p.Swigcptr()) +} + +type Foo7 interface { + Swigcptr() uintptr + SwigIsFoo7() + SwigIsFoo5() + SwigGetFoo5() Foo5 + SwigIsFoo4() + SwigGetFoo4() Foo4 +} + +type SwigcptrFoo8 uintptr + +func (p SwigcptrFoo8) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrFoo8) SwigIsFoo8() { +} + +var _wrap_new_Foo8 unsafe.Pointer + +func _swig_wrap_new_Foo8() (base SwigcptrFoo8) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Foo8, _swig_p) + return +} + +func NewFoo8() (_swig_ret Foo8) { + return _swig_wrap_new_Foo8() +} + +var _wrap_delete_Foo8 unsafe.Pointer + +func _swig_wrap_delete_Foo8(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Foo8, _swig_p) + return +} + +func DeleteFoo8(arg1 Foo8) { + _swig_wrap_delete_Foo8(arg1.Swigcptr()) +} + +type Foo8 interface { + Swigcptr() uintptr + SwigIsFoo8() +} + +type SwigcptrBari uintptr + +func (p SwigcptrBari) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrBari) SwigIsBari() { +} + +var _wrap_Bari_x_set unsafe.Pointer + +func _swig_wrap_Bari_x_set(base SwigcptrBari, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Bari_x_set, _swig_p) + return +} + +func (arg1 SwigcptrBari) SetX(arg2 int) { + _swig_wrap_Bari_x_set(arg1, arg2) +} + +var _wrap_Bari_x_get unsafe.Pointer + +func _swig_wrap_Bari_x_get(base SwigcptrBari) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Bari_x_get, _swig_p) + return +} + +func (arg1 SwigcptrBari) GetX() (_swig_ret int) { + return _swig_wrap_Bari_x_get(arg1) +} + +var _wrap_new_Bari__SWIG_0 unsafe.Pointer + +func _swig_wrap_new_Bari__SWIG_0(base int) (_ SwigcptrBari) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Bari__SWIG_0, _swig_p) + return +} + +func NewBari__SWIG_0(arg1 int) (_swig_ret Bari) { + return _swig_wrap_new_Bari__SWIG_0(arg1) +} + +var _wrap_new_Bari__SWIG_1 unsafe.Pointer + +func _swig_wrap_new_Bari__SWIG_1() (base SwigcptrBari) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Bari__SWIG_1, _swig_p) + return +} + +func NewBari__SWIG_1() (_swig_ret Bari) { + return _swig_wrap_new_Bari__SWIG_1() +} + +var _wrap_new_Bari__SWIG_2 unsafe.Pointer + +func _swig_wrap_new_Bari__SWIG_2(base uintptr) (_ SwigcptrBari) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Bari__SWIG_2, _swig_p) + return +} + +func NewBari__SWIG_2(arg1 Bari) (_swig_ret Bari) { + return _swig_wrap_new_Bari__SWIG_2(arg1.Swigcptr()) +} + +func NewBari(a ...interface{}) Bari { + argc := len(a) + if argc == 0 { + return NewBari__SWIG_1() + } + if argc == 1 { + if _, ok := a[0].(Bari); !ok { + goto check_2 + } + return NewBari__SWIG_2(a[0].(Bari)) + } +check_2: + if argc == 1 { + return NewBari__SWIG_0(a[0].(int)) + } + panic("No match for overloaded function call") +} + +var _wrap_delete_Bari unsafe.Pointer + +func _swig_wrap_delete_Bari(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Bari, _swig_p) + return +} + +func DeleteBari(arg1 Bari) { + _swig_wrap_delete_Bari(arg1.Swigcptr()) +} + +type Bari interface { + Swigcptr() uintptr + SwigIsBari() + SetX(arg2 int) + GetX() (_swig_ret int) +} + +type SwigcptrBard uintptr + +func (p SwigcptrBard) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrBard) SwigIsBard() { +} + +var _wrap_Bard_x_set unsafe.Pointer + +func _swig_wrap_Bard_x_set(base SwigcptrBard, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Bard_x_set, _swig_p) + return +} + +func (arg1 SwigcptrBard) SetX(arg2 int) { + _swig_wrap_Bard_x_set(arg1, arg2) +} + +var _wrap_Bard_x_get unsafe.Pointer + +func _swig_wrap_Bard_x_get(base SwigcptrBard) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Bard_x_get, _swig_p) + return +} + +func (arg1 SwigcptrBard) GetX() (_swig_ret int) { + return _swig_wrap_Bard_x_get(arg1) +} + +var _wrap_new_Bard__SWIG_0 unsafe.Pointer + +func _swig_wrap_new_Bard__SWIG_0(base int) (_ SwigcptrBard) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Bard__SWIG_0, _swig_p) + return +} + +func NewBard__SWIG_0(arg1 int) (_swig_ret Bard) { + return _swig_wrap_new_Bard__SWIG_0(arg1) +} + +var _wrap_new_Bard__SWIG_1 unsafe.Pointer + +func _swig_wrap_new_Bard__SWIG_1() (base SwigcptrBard) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Bard__SWIG_1, _swig_p) + return +} + +func NewBard__SWIG_1() (_swig_ret Bard) { + return _swig_wrap_new_Bard__SWIG_1() +} + +func NewBard(a ...interface{}) Bard { + argc := len(a) + if argc == 0 { + return NewBard__SWIG_1() + } + if argc == 1 { + return NewBard__SWIG_0(a[0].(int)) + } + panic("No match for overloaded function call") +} + +var _wrap_delete_Bard unsafe.Pointer + +func _swig_wrap_delete_Bard(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Bard, _swig_p) + return +} + +func DeleteBard(arg1 Bard) { + _swig_wrap_delete_Bard(arg1.Swigcptr()) +} + +type Bard interface { + Swigcptr() uintptr + SwigIsBard() + SetX(arg2 int) + GetX() (_swig_ret int) +} + +type SwigcptrABC_Libor_ModelUtils uintptr + +func (p SwigcptrABC_Libor_ModelUtils) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrABC_Libor_ModelUtils) SwigIsABC_Libor_ModelUtils() { +} + +var _wrap_new_ABC_Libor_ModelUtils__SWIG_0 unsafe.Pointer + +func _swig_wrap_new_ABC_Libor_ModelUtils__SWIG_0() (base SwigcptrABC_Libor_ModelUtils) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_ABC_Libor_ModelUtils__SWIG_0, _swig_p) + return +} + +func NewABC_Libor_ModelUtils__SWIG_0() (_swig_ret ABC_Libor_ModelUtils) { + return _swig_wrap_new_ABC_Libor_ModelUtils__SWIG_0() +} + +var _wrap_new_ABC_Libor_ModelUtils__SWIG_1 unsafe.Pointer + +func _swig_wrap_new_ABC_Libor_ModelUtils__SWIG_1(base uintptr) (_ SwigcptrABC_Libor_ModelUtils) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_ABC_Libor_ModelUtils__SWIG_1, _swig_p) + return +} + +func NewABC_Libor_ModelUtils__SWIG_1(arg1 ABC_Libor_ModelUtils) (_swig_ret ABC_Libor_ModelUtils) { + return _swig_wrap_new_ABC_Libor_ModelUtils__SWIG_1(arg1.Swigcptr()) +} + +func NewABC_Libor_ModelUtils(a ...interface{}) ABC_Libor_ModelUtils { + argc := len(a) + if argc == 0 { + return NewABC_Libor_ModelUtils__SWIG_0() + } + if argc == 1 { + return NewABC_Libor_ModelUtils__SWIG_1(a[0].(ABC_Libor_ModelUtils)) + } + panic("No match for overloaded function call") +} + +var _wrap_delete_ABC_Libor_ModelUtils unsafe.Pointer + +func _swig_wrap_delete_ABC_Libor_ModelUtils(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_ABC_Libor_ModelUtils, _swig_p) + return +} + +func DeleteABC_Libor_ModelUtils(arg1 ABC_Libor_ModelUtils) { + _swig_wrap_delete_ABC_Libor_ModelUtils(arg1.Swigcptr()) +} + +type ABC_Libor_ModelUtils interface { + Swigcptr() uintptr + SwigIsABC_Libor_ModelUtils() +} + +type SwigcptrModelUtils_i uintptr + +func (p SwigcptrModelUtils_i) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrModelUtils_i) SwigIsModelUtils_i() { +} + +var _wrap_new_ModelUtils_i__SWIG_0 unsafe.Pointer + +func _swig_wrap_new_ModelUtils_i__SWIG_0() (base SwigcptrModelUtils_i) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_ModelUtils_i__SWIG_0, _swig_p) + return +} + +func NewModelUtils_i__SWIG_0() (_swig_ret ModelUtils_i) { + return _swig_wrap_new_ModelUtils_i__SWIG_0() +} + +var _wrap_new_ModelUtils_i__SWIG_1 unsafe.Pointer + +func _swig_wrap_new_ModelUtils_i__SWIG_1(base uintptr) (_ SwigcptrModelUtils_i) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_ModelUtils_i__SWIG_1, _swig_p) + return +} + +func NewModelUtils_i__SWIG_1(arg1 ModelUtils_i) (_swig_ret ModelUtils_i) { + return _swig_wrap_new_ModelUtils_i__SWIG_1(arg1.Swigcptr()) +} + +func NewModelUtils_i(a ...interface{}) ModelUtils_i { + argc := len(a) + if argc == 0 { + return NewModelUtils_i__SWIG_0() + } + if argc == 1 { + return NewModelUtils_i__SWIG_1(a[0].(ModelUtils_i)) + } + panic("No match for overloaded function call") +} + +var _wrap_delete_ModelUtils_i unsafe.Pointer + +func _swig_wrap_delete_ModelUtils_i(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_ModelUtils_i, _swig_p) + return +} + +func DeleteModelUtils_i(arg1 ModelUtils_i) { + _swig_wrap_delete_ModelUtils_i(arg1.Swigcptr()) +} + +type ModelUtils_i interface { + Swigcptr() uintptr + SwigIsModelUtils_i() +} + +type SwigcptrSpace1Space2_TotalReturnSwap uintptr + +func (p SwigcptrSpace1Space2_TotalReturnSwap) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrSpace1Space2_TotalReturnSwap) SwigIsSpace1Space2_TotalReturnSwap() { +} + +var _wrap_new_Space1Space2_TotalReturnSwap__SWIG_0 unsafe.Pointer + +func _swig_wrap_new_Space1Space2_TotalReturnSwap__SWIG_0() (base SwigcptrSpace1Space2_TotalReturnSwap) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Space1Space2_TotalReturnSwap__SWIG_0, _swig_p) + return +} + +func NewSpace1Space2_TotalReturnSwap__SWIG_0() (_swig_ret Space1Space2_TotalReturnSwap) { + return _swig_wrap_new_Space1Space2_TotalReturnSwap__SWIG_0() +} + +var _wrap_new_Space1Space2_TotalReturnSwap__SWIG_1 unsafe.Pointer + +func _swig_wrap_new_Space1Space2_TotalReturnSwap__SWIG_1(base uintptr) (_ SwigcptrSpace1Space2_TotalReturnSwap) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Space1Space2_TotalReturnSwap__SWIG_1, _swig_p) + return +} + +func NewSpace1Space2_TotalReturnSwap__SWIG_1(arg1 Space1Space2_TotalReturnSwap) (_swig_ret Space1Space2_TotalReturnSwap) { + return _swig_wrap_new_Space1Space2_TotalReturnSwap__SWIG_1(arg1.Swigcptr()) +} + +func NewSpace1Space2_TotalReturnSwap(a ...interface{}) Space1Space2_TotalReturnSwap { + argc := len(a) + if argc == 0 { + return NewSpace1Space2_TotalReturnSwap__SWIG_0() + } + if argc == 1 { + return NewSpace1Space2_TotalReturnSwap__SWIG_1(a[0].(Space1Space2_TotalReturnSwap)) + } + panic("No match for overloaded function call") +} + +var _wrap_delete_Space1Space2_TotalReturnSwap unsafe.Pointer + +func _swig_wrap_delete_Space1Space2_TotalReturnSwap(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Space1Space2_TotalReturnSwap, _swig_p) + return +} + +func DeleteSpace1Space2_TotalReturnSwap(arg1 Space1Space2_TotalReturnSwap) { + _swig_wrap_delete_Space1Space2_TotalReturnSwap(arg1.Swigcptr()) +} + +type Space1Space2_TotalReturnSwap interface { + Swigcptr() uintptr + SwigIsSpace1Space2_TotalReturnSwap() +} + +type SwigcptrTotal_i uintptr + +func (p SwigcptrTotal_i) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrTotal_i) SwigIsTotal_i() { +} + +var _wrap_new_Total_i__SWIG_0 unsafe.Pointer + +func _swig_wrap_new_Total_i__SWIG_0() (base SwigcptrTotal_i) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Total_i__SWIG_0, _swig_p) + return +} + +func NewTotal_i__SWIG_0() (_swig_ret Total_i) { + return _swig_wrap_new_Total_i__SWIG_0() +} + +var _wrap_new_Total_i__SWIG_1 unsafe.Pointer + +func _swig_wrap_new_Total_i__SWIG_1(base uintptr) (_ SwigcptrTotal_i) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Total_i__SWIG_1, _swig_p) + return +} + +func NewTotal_i__SWIG_1(arg1 Total_i) (_swig_ret Total_i) { + return _swig_wrap_new_Total_i__SWIG_1(arg1.Swigcptr()) +} + +func NewTotal_i(a ...interface{}) Total_i { + argc := len(a) + if argc == 0 { + return NewTotal_i__SWIG_0() + } + if argc == 1 { + return NewTotal_i__SWIG_1(a[0].(Total_i)) + } + panic("No match for overloaded function call") +} + +var _wrap_delete_Total_i unsafe.Pointer + +func _swig_wrap_delete_Total_i(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Total_i, _swig_p) + return +} + +func DeleteTotal_i(arg1 Total_i) { + _swig_wrap_delete_Total_i(arg1.Swigcptr()) +} + +type Total_i interface { + Swigcptr() uintptr + SwigIsTotal_i() +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/constructor_copy_runme b/Examples/test-suite/go/constructor_copy_runme new file mode 100755 index 000000000..5cf9a96e4 Binary files /dev/null and b/Examples/test-suite/go/constructor_copy_runme differ diff --git a/Examples/test-suite/go/constructor_exception.go b/Examples/test-suite/go/constructor_exception.go new file mode 100644 index 000000000..1153a9b12 --- /dev/null +++ b/Examples/test-suite/go/constructor_exception.go @@ -0,0 +1,151 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../constructor_exception.i + +package constructor_exception + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrError uintptr + +func (p SwigcptrError) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrError) SwigIsError() { +} + +var _wrap_new_Error unsafe.Pointer + +func _swig_wrap_new_Error() (base SwigcptrError) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Error, _swig_p) + return +} + +func NewError() (_swig_ret Error) { + return _swig_wrap_new_Error() +} + +var _wrap_delete_Error unsafe.Pointer + +func _swig_wrap_delete_Error(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Error, _swig_p) + return +} + +func DeleteError(arg1 Error) { + _swig_wrap_delete_Error(arg1.Swigcptr()) +} + +type Error interface { + Swigcptr() uintptr + SwigIsError() +} + +type SwigcptrSomeClass uintptr + +func (p SwigcptrSomeClass) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrSomeClass) SwigIsSomeClass() { +} + +var _wrap_new_SomeClass unsafe.Pointer + +func _swig_wrap_new_SomeClass(base int) (_ SwigcptrSomeClass) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_SomeClass, _swig_p) + return +} + +func NewSomeClass(arg1 int) (_swig_ret SomeClass) { + return _swig_wrap_new_SomeClass(arg1) +} + +var _wrap_delete_SomeClass unsafe.Pointer + +func _swig_wrap_delete_SomeClass(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_SomeClass, _swig_p) + return +} + +func DeleteSomeClass(arg1 SomeClass) { + _swig_wrap_delete_SomeClass(arg1.Swigcptr()) +} + +type SomeClass interface { + Swigcptr() uintptr + SwigIsSomeClass() +} + +type SwigcptrTest uintptr + +func (p SwigcptrTest) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrTest) SwigIsTest() { +} + +var _wrap_new_Test unsafe.Pointer + +func _swig_wrap_new_Test(base int) (_ SwigcptrTest) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Test, _swig_p) + return +} + +func NewTest(arg1 int) (_swig_ret Test) { + return _swig_wrap_new_Test(arg1) +} + +var _wrap_delete_Test unsafe.Pointer + +func _swig_wrap_delete_Test(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Test, _swig_p) + return +} + +func DeleteTest(arg1 Test) { + _swig_wrap_delete_Test(arg1.Swigcptr()) +} + +type Test interface { + Swigcptr() uintptr + SwigIsTest() +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/constructor_explicit.go b/Examples/test-suite/go/constructor_explicit.go new file mode 100644 index 000000000..eeb797530 --- /dev/null +++ b/Examples/test-suite/go/constructor_explicit.go @@ -0,0 +1,110 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../constructor_explicit.i + +package constructor_explicit + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrFoo uintptr + +func (p SwigcptrFoo) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrFoo) SwigIsFoo() { +} + +var _wrap_new_Foo__SWIG_0 unsafe.Pointer + +func _swig_wrap_new_Foo__SWIG_0() (base SwigcptrFoo) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Foo__SWIG_0, _swig_p) + return +} + +func NewFoo__SWIG_0() (_swig_ret Foo) { + return _swig_wrap_new_Foo__SWIG_0() +} + +var _wrap_new_Foo__SWIG_1 unsafe.Pointer + +func _swig_wrap_new_Foo__SWIG_1(base int) (_ SwigcptrFoo) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Foo__SWIG_1, _swig_p) + return +} + +func NewFoo__SWIG_1(arg1 int) (_swig_ret Foo) { + return _swig_wrap_new_Foo__SWIG_1(arg1) +} + +func NewFoo(a ...interface{}) Foo { + argc := len(a) + if argc == 0 { + return NewFoo__SWIG_0() + } + if argc == 1 { + return NewFoo__SWIG_1(a[0].(int)) + } + panic("No match for overloaded function call") +} + +var _wrap_delete_Foo unsafe.Pointer + +func _swig_wrap_delete_Foo(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Foo, _swig_p) + return +} + +func DeleteFoo(arg1 Foo) { + _swig_wrap_delete_Foo(arg1.Swigcptr()) +} + +type Foo interface { + Swigcptr() uintptr + SwigIsFoo() +} + +var _wrap_test unsafe.Pointer + +func _swig_wrap_test(base uintptr) (_ SwigcptrFoo) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_test, _swig_p) + return +} + +func Test(arg1 Foo) (_swig_ret Foo) { + return _swig_wrap_test(arg1.Swigcptr()) +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/constructor_ignore.go b/Examples/test-suite/go/constructor_ignore.go new file mode 100644 index 000000000..2e0a3ba19 --- /dev/null +++ b/Examples/test-suite/go/constructor_ignore.go @@ -0,0 +1,205 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../constructor_ignore.i + +package constructor_ignore + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrDelta1 uintptr + +func (p SwigcptrDelta1) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrDelta1) SwigIsDelta1() { +} + +var _wrap_delete_Delta1 unsafe.Pointer + +func _swig_wrap_delete_Delta1(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Delta1, _swig_p) + return +} + +func DeleteDelta1(arg1 Delta1) { + _swig_wrap_delete_Delta1(arg1.Swigcptr()) +} + +type Delta1 interface { + Swigcptr() uintptr + SwigIsDelta1() +} + +type SwigcptrDelta2 uintptr + +func (p SwigcptrDelta2) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrDelta2) SwigIsDelta2() { +} + +var _wrap_delete_Delta2 unsafe.Pointer + +func _swig_wrap_delete_Delta2(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Delta2, _swig_p) + return +} + +func DeleteDelta2(arg1 Delta2) { + _swig_wrap_delete_Delta2(arg1.Swigcptr()) +} + +type Delta2 interface { + Swigcptr() uintptr + SwigIsDelta2() +} + +type SwigcptrDelta3 uintptr + +func (p SwigcptrDelta3) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrDelta3) SwigIsDelta3() { +} + +var _wrap_delete_Delta3 unsafe.Pointer + +func _swig_wrap_delete_Delta3(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Delta3, _swig_p) + return +} + +func DeleteDelta3(arg1 Delta3) { + _swig_wrap_delete_Delta3(arg1.Swigcptr()) +} + +type Delta3 interface { + Swigcptr() uintptr + SwigIsDelta3() +} + +type SwigcptrDelta4 uintptr + +func (p SwigcptrDelta4) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrDelta4) SwigIsDelta4() { +} + +var _wrap_delete_Delta4 unsafe.Pointer + +func _swig_wrap_delete_Delta4(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Delta4, _swig_p) + return +} + +func DeleteDelta4(arg1 Delta4) { + _swig_wrap_delete_Delta4(arg1.Swigcptr()) +} + +type Delta4 interface { + Swigcptr() uintptr + SwigIsDelta4() +} + +type SwigcptrDelta5 uintptr + +func (p SwigcptrDelta5) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrDelta5) SwigIsDelta5() { +} + +var _wrap_delete_Delta5 unsafe.Pointer + +func _swig_wrap_delete_Delta5(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Delta5, _swig_p) + return +} + +func DeleteDelta5(arg1 Delta5) { + _swig_wrap_delete_Delta5(arg1.Swigcptr()) +} + +type Delta5 interface { + Swigcptr() uintptr + SwigIsDelta5() +} + +type SwigcptrDelta6 uintptr + +func (p SwigcptrDelta6) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrDelta6) SwigIsDelta6() { +} + +var _wrap_new_Delta6 unsafe.Pointer + +func _swig_wrap_new_Delta6() (base SwigcptrDelta6) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Delta6, _swig_p) + return +} + +func NewDelta6() (_swig_ret Delta6) { + return _swig_wrap_new_Delta6() +} + +var _wrap_delete_Delta6 unsafe.Pointer + +func _swig_wrap_delete_Delta6(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Delta6, _swig_p) + return +} + +func DeleteDelta6(arg1 Delta6) { + _swig_wrap_delete_Delta6(arg1.Swigcptr()) +} + +type Delta6 interface { + Swigcptr() uintptr + SwigIsDelta6() +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/constructor_rename.go b/Examples/test-suite/go/constructor_rename.go new file mode 100644 index 000000000..986e9c825 --- /dev/null +++ b/Examples/test-suite/go/constructor_rename.go @@ -0,0 +1,75 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../constructor_rename.i + +package constructor_rename + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrFoo uintptr + +func (p SwigcptrFoo) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrFoo) SwigIsFoo() { +} + +var _wrap_new_RenamedConstructor unsafe.Pointer + +func _swig_wrap_new_RenamedConstructor() (base SwigcptrFoo) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_RenamedConstructor, _swig_p) + return +} + +func NewRenamedConstructor() (_swig_ret Foo) { + return _swig_wrap_new_RenamedConstructor() +} + +var _wrap_delete_Foo unsafe.Pointer + +func _swig_wrap_delete_Foo(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Foo, _swig_p) + return +} + +func DeleteFoo(arg1 Foo) { + _swig_wrap_delete_Foo(arg1.Swigcptr()) +} + +type Foo interface { + Swigcptr() uintptr + SwigIsFoo() +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/constructor_value.go b/Examples/test-suite/go/constructor_value.go new file mode 100644 index 000000000..98d7802ce --- /dev/null +++ b/Examples/test-suite/go/constructor_value.go @@ -0,0 +1,113 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../constructor_value.i + +package constructor_value + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrFoo uintptr + +func (p SwigcptrFoo) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrFoo) SwigIsFoo() { +} + +var _wrap_new_Foo unsafe.Pointer + +func _swig_wrap_new_Foo(base int) (_ SwigcptrFoo) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Foo, _swig_p) + return +} + +func NewFoo(arg1 int) (_swig_ret Foo) { + return _swig_wrap_new_Foo(arg1) +} + +var _wrap_delete_Foo unsafe.Pointer + +func _swig_wrap_delete_Foo(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Foo, _swig_p) + return +} + +func DeleteFoo(arg1 Foo) { + _swig_wrap_delete_Foo(arg1.Swigcptr()) +} + +type Foo interface { + Swigcptr() uintptr + SwigIsFoo() +} + +type SwigcptrBar uintptr + +func (p SwigcptrBar) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrBar) SwigIsBar() { +} + +var _wrap_new_Bar unsafe.Pointer + +func _swig_wrap_new_Bar(base uintptr) (_ SwigcptrBar) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Bar, _swig_p) + return +} + +func NewBar(arg1 Foo) (_swig_ret Bar) { + return _swig_wrap_new_Bar(arg1.Swigcptr()) +} + +var _wrap_delete_Bar unsafe.Pointer + +func _swig_wrap_delete_Bar(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Bar, _swig_p) + return +} + +func DeleteBar(arg1 Bar) { + _swig_wrap_delete_Bar(arg1.Swigcptr()) +} + +type Bar interface { + Swigcptr() uintptr + SwigIsBar() +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/contract.go b/Examples/test-suite/go/contract.go new file mode 100644 index 000000000..5c4626ea1 --- /dev/null +++ b/Examples/test-suite/go/contract.go @@ -0,0 +1,625 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../contract.i + +package contract + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +var _wrap_test_preassert unsafe.Pointer + +func Test_preassert(arg1 int, arg2 int) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_test_preassert, _swig_p) + return +} +var _wrap_test_postassert unsafe.Pointer + +func Test_postassert(arg1 int) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_test_postassert, _swig_p) + return +} +var _wrap_test_prepost unsafe.Pointer + +func Test_prepost(arg1 int, arg2 int) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_test_prepost, _swig_p) + return +} +type SwigcptrFoo uintptr + +func (p SwigcptrFoo) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrFoo) SwigIsFoo() { +} + +var _wrap_delete_Foo unsafe.Pointer + +func _swig_wrap_delete_Foo(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Foo, _swig_p) + return +} + +func DeleteFoo(arg1 Foo) { + _swig_wrap_delete_Foo(arg1.Swigcptr()) +} + +var _wrap_Foo_test_preassert unsafe.Pointer + +func _swig_wrap_Foo_test_preassert(base SwigcptrFoo, _ int, _ int) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_test_preassert, _swig_p) + return +} + +func (arg1 SwigcptrFoo) Test_preassert(arg2 int, arg3 int) (_swig_ret int) { + return _swig_wrap_Foo_test_preassert(arg1, arg2, arg3) +} + +var _wrap_Foo_test_postassert unsafe.Pointer + +func _swig_wrap_Foo_test_postassert(base SwigcptrFoo, _ int) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_test_postassert, _swig_p) + return +} + +func (arg1 SwigcptrFoo) Test_postassert(arg2 int) (_swig_ret int) { + return _swig_wrap_Foo_test_postassert(arg1, arg2) +} + +var _wrap_Foo_test_prepost unsafe.Pointer + +func _swig_wrap_Foo_test_prepost(base SwigcptrFoo, _ int, _ int) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_test_prepost, _swig_p) + return +} + +func (arg1 SwigcptrFoo) Test_prepost(arg2 int, arg3 int) (_swig_ret int) { + return _swig_wrap_Foo_test_prepost(arg1, arg2, arg3) +} + +var _wrap_Foo_stest_prepost unsafe.Pointer + +func FooStest_prepost(arg1 int, arg2 int) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_Foo_stest_prepost, _swig_p) + return +} +var _wrap_new_Foo unsafe.Pointer + +func _swig_wrap_new_Foo() (base SwigcptrFoo) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Foo, _swig_p) + return +} + +func NewFoo() (_swig_ret Foo) { + return _swig_wrap_new_Foo() +} + +type Foo interface { + Swigcptr() uintptr + SwigIsFoo() + Test_preassert(arg2 int, arg3 int) (_swig_ret int) + Test_postassert(arg2 int) (_swig_ret int) + Test_prepost(arg2 int, arg3 int) (_swig_ret int) +} + +type SwigcptrBar uintptr + +func (p SwigcptrBar) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrBar) SwigIsBar() { +} + +var _wrap_Bar_test_prepost unsafe.Pointer + +func _swig_wrap_Bar_test_prepost(base SwigcptrBar, _ int, _ int) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Bar_test_prepost, _swig_p) + return +} + +func (arg1 SwigcptrBar) Test_prepost(arg2 int, arg3 int) (_swig_ret int) { + return _swig_wrap_Bar_test_prepost(arg1, arg2, arg3) +} + +var _wrap_new_Bar unsafe.Pointer + +func _swig_wrap_new_Bar() (base SwigcptrBar) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Bar, _swig_p) + return +} + +func NewBar() (_swig_ret Bar) { + return _swig_wrap_new_Bar() +} + +var _wrap_delete_Bar unsafe.Pointer + +func _swig_wrap_delete_Bar(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Bar, _swig_p) + return +} + +func DeleteBar(arg1 Bar) { + _swig_wrap_delete_Bar(arg1.Swigcptr()) +} + +var _wrap_Bar_test_preassert unsafe.Pointer + +func _swig_wrap_Bar_test_preassert(base SwigcptrBar, _ int, _ int) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Bar_test_preassert, _swig_p) + return +} + +func (_swig_base SwigcptrBar) Test_preassert(arg1 int, arg2 int) (_swig_ret int) { + return _swig_wrap_Bar_test_preassert(_swig_base, arg1, arg2) +} + +var _wrap_Bar_test_postassert unsafe.Pointer + +func _swig_wrap_Bar_test_postassert(base SwigcptrBar, _ int) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Bar_test_postassert, _swig_p) + return +} + +func (_swig_base SwigcptrBar) Test_postassert(arg1 int) (_swig_ret int) { + return _swig_wrap_Bar_test_postassert(_swig_base, arg1) +} + +var _wrap_Bar_stest_prepost unsafe.Pointer + +func BarStest_prepost(arg1 int, arg2 int) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_Bar_stest_prepost, _swig_p) + return +} +func (p SwigcptrBar) SwigIsFoo() { +} + +func (p SwigcptrBar) SwigGetFoo() Foo { + return SwigcptrFoo(p.Swigcptr()) +} + +type Bar interface { + Swigcptr() uintptr + SwigIsBar() + Test_prepost(arg2 int, arg3 int) (_swig_ret int) + Test_preassert(arg1 int, arg2 int) (_swig_ret int) + Test_postassert(arg1 int) (_swig_ret int) + SwigIsFoo() + SwigGetFoo() Foo +} + +type SwigcptrA uintptr + +func (p SwigcptrA) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrA) SwigIsA() { +} + +var _wrap_delete_A unsafe.Pointer + +func _swig_wrap_delete_A(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_A, _swig_p) + return +} + +func DeleteA(arg1 A) { + _swig_wrap_delete_A(arg1.Swigcptr()) +} + +var _wrap_A_foo unsafe.Pointer + +func _swig_wrap_A_foo(base SwigcptrA, _ int, _ int, _ int, _ int, _ int) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_A_foo, _swig_p) + return +} + +func (arg1 SwigcptrA) Foo(arg2 int, arg3 int, arg4 int, arg5 int, arg6 int) (_swig_ret int) { + return _swig_wrap_A_foo(arg1, arg2, arg3, arg4, arg5, arg6) +} + +var _wrap_new_A unsafe.Pointer + +func _swig_wrap_new_A() (base SwigcptrA) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_A, _swig_p) + return +} + +func NewA() (_swig_ret A) { + return _swig_wrap_new_A() +} + +type A interface { + Swigcptr() uintptr + SwigIsA() + Foo(arg2 int, arg3 int, arg4 int, arg5 int, arg6 int) (_swig_ret int) +} + +type SwigcptrB uintptr + +func (p SwigcptrB) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrB) SwigIsB() { +} + +var _wrap_delete_B unsafe.Pointer + +func _swig_wrap_delete_B(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_B, _swig_p) + return +} + +func DeleteB(arg1 B) { + _swig_wrap_delete_B(arg1.Swigcptr()) +} + +var _wrap_B_bar unsafe.Pointer + +func _swig_wrap_B_bar(base SwigcptrB, _ int, _ int, _ int, _ int, _ int) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_B_bar, _swig_p) + return +} + +func (arg1 SwigcptrB) Bar(arg2 int, arg3 int, arg4 int, arg5 int, arg6 int) (_swig_ret int) { + return _swig_wrap_B_bar(arg1, arg2, arg3, arg4, arg5, arg6) +} + +var _wrap_new_B unsafe.Pointer + +func _swig_wrap_new_B() (base SwigcptrB) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_B, _swig_p) + return +} + +func NewB() (_swig_ret B) { + return _swig_wrap_new_B() +} + +type B interface { + Swigcptr() uintptr + SwigIsB() + Bar(arg2 int, arg3 int, arg4 int, arg5 int, arg6 int) (_swig_ret int) +} + +type SwigcptrC uintptr + +func (p SwigcptrC) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrC) SwigIsC() { +} + +var _wrap_C_foo unsafe.Pointer + +func _swig_wrap_C_foo(base SwigcptrC, _ int, _ int, _ int, _ int, _ int) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_C_foo, _swig_p) + return +} + +func (arg1 SwigcptrC) Foo(arg2 int, arg3 int, arg4 int, arg5 int, arg6 int) (_swig_ret int) { + return _swig_wrap_C_foo(arg1, arg2, arg3, arg4, arg5, arg6) +} + +var _wrap_C_bar unsafe.Pointer + +func _swig_wrap_C_bar(base SwigcptrC, _ int, _ int, _ int, _ int, _ int) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_C_bar, _swig_p) + return +} + +func (arg1 SwigcptrC) Bar(arg2 int, arg3 int, arg4 int, arg5 int, arg6 int) (_swig_ret int) { + return _swig_wrap_C_bar(arg1, arg2, arg3, arg4, arg5, arg6) +} + +var _wrap_new_C unsafe.Pointer + +func _swig_wrap_new_C() (base SwigcptrC) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_C, _swig_p) + return +} + +func NewC() (_swig_ret C) { + return _swig_wrap_new_C() +} + +var _wrap_delete_C unsafe.Pointer + +func _swig_wrap_delete_C(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_C, _swig_p) + return +} + +func DeleteC(arg1 C) { + _swig_wrap_delete_C(arg1.Swigcptr()) +} + +func (p SwigcptrC) SwigIsA() { +} + +func (p SwigcptrC) SwigGetA() A { + return SwigcptrA(p.Swigcptr()) +} + +var _wrap_C_SwigGetB unsafe.Pointer + +func _swig_wrap_C_SwigGetB(base SwigcptrC) (_ SwigcptrB) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_C_SwigGetB, _swig_p) + return +} + +func (arg1 SwigcptrC) SwigGetB() (_swig_ret B) { + return _swig_wrap_C_SwigGetB(arg1) +} + +type C interface { + Swigcptr() uintptr + SwigIsC() + Foo(arg2 int, arg3 int, arg4 int, arg5 int, arg6 int) (_swig_ret int) + Bar(arg2 int, arg3 int, arg4 int, arg5 int, arg6 int) (_swig_ret int) + SwigIsA() + SwigGetA() A + SwigGetB() (_swig_ret B) +} + +type SwigcptrD uintptr + +func (p SwigcptrD) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrD) SwigIsD() { +} + +var _wrap_D_foo unsafe.Pointer + +func _swig_wrap_D_foo(base SwigcptrD, _ int, _ int, _ int, _ int, _ int) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_D_foo, _swig_p) + return +} + +func (arg1 SwigcptrD) Foo(arg2 int, arg3 int, arg4 int, arg5 int, arg6 int) (_swig_ret int) { + return _swig_wrap_D_foo(arg1, arg2, arg3, arg4, arg5, arg6) +} + +var _wrap_D_bar unsafe.Pointer + +func _swig_wrap_D_bar(base SwigcptrD, _ int, _ int, _ int, _ int, _ int) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_D_bar, _swig_p) + return +} + +func (arg1 SwigcptrD) Bar(arg2 int, arg3 int, arg4 int, arg5 int, arg6 int) (_swig_ret int) { + return _swig_wrap_D_bar(arg1, arg2, arg3, arg4, arg5, arg6) +} + +var _wrap_new_D unsafe.Pointer + +func _swig_wrap_new_D() (base SwigcptrD) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_D, _swig_p) + return +} + +func NewD() (_swig_ret D) { + return _swig_wrap_new_D() +} + +var _wrap_delete_D unsafe.Pointer + +func _swig_wrap_delete_D(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_D, _swig_p) + return +} + +func DeleteD(arg1 D) { + _swig_wrap_delete_D(arg1.Swigcptr()) +} + +func (p SwigcptrD) SwigIsC() { +} + +func (p SwigcptrD) SwigGetC() C { + return SwigcptrC(p.Swigcptr()) +} + +func (p SwigcptrD) SwigIsA() { +} + +func (p SwigcptrD) SwigGetA() A { + return SwigcptrA(p.Swigcptr()) +} + +func (p SwigcptrD) SwigGetB() B { + return p.SwigGetC().SwigGetB() +} + +type D interface { + Swigcptr() uintptr + SwigIsD() + Foo(arg2 int, arg3 int, arg4 int, arg5 int, arg6 int) (_swig_ret int) + Bar(arg2 int, arg3 int, arg4 int, arg5 int, arg6 int) (_swig_ret int) + SwigIsC() + SwigGetC() C + SwigIsA() + SwigGetA() A + SwigGetB() B +} + +type SwigcptrE uintptr + +func (p SwigcptrE) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrE) SwigIsE() { +} + +var _wrap_E_m_i_set unsafe.Pointer + +func _swig_wrap_E_m_i_set(base SwigcptrE, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_E_m_i_set, _swig_p) + return +} + +func (arg1 SwigcptrE) SetM_i(arg2 int) { + _swig_wrap_E_m_i_set(arg1, arg2) +} + +var _wrap_E_m_i_get unsafe.Pointer + +func _swig_wrap_E_m_i_get(base SwigcptrE) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_E_m_i_get, _swig_p) + return +} + +func (arg1 SwigcptrE) GetM_i() (_swig_ret int) { + return _swig_wrap_E_m_i_get(arg1) +} + +var _wrap_E_manipulate_i unsafe.Pointer + +func _swig_wrap_E_manipulate_i(base SwigcptrE, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_E_manipulate_i, _swig_p) + return +} + +func (arg1 SwigcptrE) Manipulate_i(arg2 int) { + _swig_wrap_E_manipulate_i(arg1, arg2) +} + +var _wrap_new_E unsafe.Pointer + +func _swig_wrap_new_E() (base SwigcptrE) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_E, _swig_p) + return +} + +func NewE() (_swig_ret E) { + return _swig_wrap_new_E() +} + +var _wrap_delete_E unsafe.Pointer + +func _swig_wrap_delete_E(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_E, _swig_p) + return +} + +func DeleteE(arg1 E) { + _swig_wrap_delete_E(arg1.Swigcptr()) +} + +type E interface { + Swigcptr() uintptr + SwigIsE() + SetM_i(arg2 int) + GetM_i() (_swig_ret int) + Manipulate_i(arg2 int) +} + +type SwigcptrMyClass uintptr + +func (p SwigcptrMyClass) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrMyClass) SwigIsMyClass() { +} + +var _wrap_new_myClass unsafe.Pointer + +func _swig_wrap_new_myClass(base int) (_ SwigcptrMyClass) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_myClass, _swig_p) + return +} + +func NewMyClass(arg1 int) (_swig_ret MyClass) { + return _swig_wrap_new_myClass(arg1) +} + +var _wrap_delete_myClass unsafe.Pointer + +func _swig_wrap_delete_myClass(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_myClass, _swig_p) + return +} + +func DeleteMyClass(arg1 MyClass) { + _swig_wrap_delete_myClass(arg1.Swigcptr()) +} + +type MyClass interface { + Swigcptr() uintptr + SwigIsMyClass() +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/contract_runme b/Examples/test-suite/go/contract_runme new file mode 100755 index 000000000..2da080166 Binary files /dev/null and b/Examples/test-suite/go/contract_runme differ diff --git a/Examples/test-suite/go/conversion.go b/Examples/test-suite/go/conversion.go new file mode 100644 index 000000000..3f7460afe --- /dev/null +++ b/Examples/test-suite/go/conversion.go @@ -0,0 +1,126 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../conversion.i + +package conversion + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrFoo uintptr + +func (p SwigcptrFoo) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrFoo) SwigIsFoo() { +} + +var _wrap_new_Foo unsafe.Pointer + +func _swig_wrap_new_Foo() (base SwigcptrFoo) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Foo, _swig_p) + return +} + +func NewFoo() (_swig_ret Foo) { + return _swig_wrap_new_Foo() +} + +var _wrap_delete_Foo unsafe.Pointer + +func _swig_wrap_delete_Foo(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Foo, _swig_p) + return +} + +func DeleteFoo(arg1 Foo) { + _swig_wrap_delete_Foo(arg1.Swigcptr()) +} + +type Foo interface { + Swigcptr() uintptr + SwigIsFoo() +} + +type SwigcptrBar uintptr + +func (p SwigcptrBar) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrBar) SwigIsBar() { +} + +var _wrap_Bar_toFoo unsafe.Pointer + +func _swig_wrap_Bar_toFoo(base SwigcptrBar) (_ SwigcptrFoo) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Bar_toFoo, _swig_p) + return +} + +func (arg1 SwigcptrBar) ToFoo() (_swig_ret Foo) { + return _swig_wrap_Bar_toFoo(arg1) +} + +var _wrap_new_Bar unsafe.Pointer + +func _swig_wrap_new_Bar() (base SwigcptrBar) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Bar, _swig_p) + return +} + +func NewBar() (_swig_ret Bar) { + return _swig_wrap_new_Bar() +} + +var _wrap_delete_Bar unsafe.Pointer + +func _swig_wrap_delete_Bar(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Bar, _swig_p) + return +} + +func DeleteBar(arg1 Bar) { + _swig_wrap_delete_Bar(arg1.Swigcptr()) +} + +type Bar interface { + Swigcptr() uintptr + SwigIsBar() + ToFoo() (_swig_ret Foo) +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/conversion_namespace.go b/Examples/test-suite/go/conversion_namespace.go new file mode 100644 index 000000000..d9bf1f10f --- /dev/null +++ b/Examples/test-suite/go/conversion_namespace.go @@ -0,0 +1,126 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../conversion_namespace.i + +package conversion_namespace + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrFoo uintptr + +func (p SwigcptrFoo) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrFoo) SwigIsFoo() { +} + +var _wrap_new_Foo unsafe.Pointer + +func _swig_wrap_new_Foo() (base SwigcptrFoo) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Foo, _swig_p) + return +} + +func NewFoo() (_swig_ret Foo) { + return _swig_wrap_new_Foo() +} + +var _wrap_delete_Foo unsafe.Pointer + +func _swig_wrap_delete_Foo(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Foo, _swig_p) + return +} + +func DeleteFoo(arg1 Foo) { + _swig_wrap_delete_Foo(arg1.Swigcptr()) +} + +type Foo interface { + Swigcptr() uintptr + SwigIsFoo() +} + +type SwigcptrBar uintptr + +func (p SwigcptrBar) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrBar) SwigIsBar() { +} + +var _wrap_Bar_toFoo unsafe.Pointer + +func _swig_wrap_Bar_toFoo(base SwigcptrBar) (_ SwigcptrFoo) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Bar_toFoo, _swig_p) + return +} + +func (arg1 SwigcptrBar) ToFoo() (_swig_ret Foo) { + return _swig_wrap_Bar_toFoo(arg1) +} + +var _wrap_new_Bar unsafe.Pointer + +func _swig_wrap_new_Bar() (base SwigcptrBar) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Bar, _swig_p) + return +} + +func NewBar() (_swig_ret Bar) { + return _swig_wrap_new_Bar() +} + +var _wrap_delete_Bar unsafe.Pointer + +func _swig_wrap_delete_Bar(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Bar, _swig_p) + return +} + +func DeleteBar(arg1 Bar) { + _swig_wrap_delete_Bar(arg1.Swigcptr()) +} + +type Bar interface { + Swigcptr() uintptr + SwigIsBar() + ToFoo() (_swig_ret Foo) +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/conversion_ns_template.go b/Examples/test-suite/go/conversion_ns_template.go new file mode 100644 index 000000000..0c0f61959 --- /dev/null +++ b/Examples/test-suite/go/conversion_ns_template.go @@ -0,0 +1,194 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../conversion_ns_template.i + +package conversion_ns_template + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type OssTest int +var _wrap_One unsafe.Pointer + +func _swig_getOne() (_swig_ret OssTest) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_One, _swig_p) + return +} +var One OssTest = _swig_getOne() +var _wrap_Two unsafe.Pointer + +func _swig_getTwo() (_swig_ret OssTest) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_Two, _swig_p) + return +} +var Two OssTest = _swig_getTwo() +type SwigcptrHi uintptr + +func (p SwigcptrHi) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrHi) SwigIsHi() { +} + +var _wrap_new_create unsafe.Pointer + +func _swig_wrap_new_create(base int) (_ SwigcptrHi) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_create, _swig_p) + return +} + +func NewCreate(arg1 int) (_swig_ret Hi) { + return _swig_wrap_new_create(arg1) +} + +var _wrap_delete_Hi unsafe.Pointer + +func _swig_wrap_delete_Hi(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Hi, _swig_p) + return +} + +func DeleteHi(arg1 Hi) { + _swig_wrap_delete_Hi(arg1.Swigcptr()) +} + +type Hi interface { + Swigcptr() uintptr + SwigIsHi() +} + +type SwigcptrFoo_One uintptr + +func (p SwigcptrFoo_One) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrFoo_One) SwigIsFoo_One() { +} + +var _wrap_new_Foo_One unsafe.Pointer + +func _swig_wrap_new_Foo_One() (base SwigcptrFoo_One) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Foo_One, _swig_p) + return +} + +func NewFoo_One() (_swig_ret Foo_One) { + return _swig_wrap_new_Foo_One() +} + +var _wrap_delete_Foo_One unsafe.Pointer + +func _swig_wrap_delete_Foo_One(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Foo_One, _swig_p) + return +} + +func DeleteFoo_One(arg1 Foo_One) { + _swig_wrap_delete_Foo_One(arg1.Swigcptr()) +} + +type Foo_One interface { + Swigcptr() uintptr + SwigIsFoo_One() +} + +type SwigcptrBar_One uintptr + +func (p SwigcptrBar_One) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrBar_One) SwigIsBar_One() { +} + +var _wrap_new_Bar_create unsafe.Pointer + +func _swig_wrap_new_Bar_create(base int) (_ SwigcptrBar_One) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Bar_create, _swig_p) + return +} + +func NewBar_create(arg1 int) (_swig_ret Bar_One) { + return _swig_wrap_new_Bar_create(arg1) +} + +var _wrap_Bar_One_hello1 unsafe.Pointer + +func _swig_wrap_Bar_One_hello1(base SwigcptrBar_One) (_ *int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Bar_One_hello1, _swig_p) + return +} + +func (arg1 SwigcptrBar_One) Hello1() (_swig_ret *int) { + return _swig_wrap_Bar_One_hello1(arg1) +} + +var _wrap_Bar_One_hello2 unsafe.Pointer + +func _swig_wrap_Bar_One_hello2(base SwigcptrBar_One) (_ SwigcptrFoo_One) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Bar_One_hello2, _swig_p) + return +} + +func (arg1 SwigcptrBar_One) Hello2() (_swig_ret Foo_One) { + return _swig_wrap_Bar_One_hello2(arg1) +} + +var _wrap_delete_Bar_One unsafe.Pointer + +func _swig_wrap_delete_Bar_One(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Bar_One, _swig_p) + return +} + +func DeleteBar_One(arg1 Bar_One) { + _swig_wrap_delete_Bar_One(arg1.Swigcptr()) +} + +type Bar_One interface { + Swigcptr() uintptr + SwigIsBar_One() + Hello1() (_swig_ret *int) + Hello2() (_swig_ret Foo_One) +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/cplusplus_throw.go b/Examples/test-suite/go/cplusplus_throw.go new file mode 100644 index 000000000..1f1860797 --- /dev/null +++ b/Examples/test-suite/go/cplusplus_throw.go @@ -0,0 +1,128 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../cplusplus_throw.i + +package cplusplus_throw + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrFoo uintptr + +func (p SwigcptrFoo) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrFoo) SwigIsFoo() { +} + +var _wrap_delete_Foo unsafe.Pointer + +func _swig_wrap_delete_Foo(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Foo, _swig_p) + return +} + +func DeleteFoo(arg1 Foo) { + _swig_wrap_delete_Foo(arg1.Swigcptr()) +} + +type Foo interface { + Swigcptr() uintptr + SwigIsFoo() +} + +type SwigcptrBar uintptr + +func (p SwigcptrBar) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrBar) SwigIsBar() { +} + +var _wrap_Bar_baz unsafe.Pointer + +func _swig_wrap_Bar_baz(base SwigcptrBar) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Bar_baz, _swig_p) + return +} + +func (arg1 SwigcptrBar) Baz() { + _swig_wrap_Bar_baz(arg1) +} + +var _wrap_Bar_foo unsafe.Pointer + +func _swig_wrap_Bar_foo(base SwigcptrBar) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Bar_foo, _swig_p) + return +} + +func (arg1 SwigcptrBar) Foo() { + _swig_wrap_Bar_foo(arg1) +} + +var _wrap_Bar_bazfoo unsafe.Pointer + +func _swig_wrap_Bar_bazfoo(base SwigcptrBar) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Bar_bazfoo, _swig_p) + return +} + +func (arg1 SwigcptrBar) Bazfoo() { + _swig_wrap_Bar_bazfoo(arg1) +} + +var _wrap_delete_Bar unsafe.Pointer + +func _swig_wrap_delete_Bar(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Bar, _swig_p) + return +} + +func DeleteBar(arg1 Bar) { + _swig_wrap_delete_Bar(arg1.Swigcptr()) +} + +type Bar interface { + Swigcptr() uintptr + SwigIsBar() + Baz() + Foo() + Bazfoo() +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/cpp_basic.go b/Examples/test-suite/go/cpp_basic.go new file mode 100644 index 000000000..516923a92 --- /dev/null +++ b/Examples/test-suite/go/cpp_basic.go @@ -0,0 +1,804 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../cpp_basic.i + +package cpp_basic + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrFoo uintptr + +func (p SwigcptrFoo) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrFoo) SwigIsFoo() { +} + +var _wrap_new_Foo unsafe.Pointer + +func _swig_wrap_new_Foo(base int) (_ SwigcptrFoo) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Foo, _swig_p) + return +} + +func NewFoo(arg1 int) (_swig_ret Foo) { + return _swig_wrap_new_Foo(arg1) +} + +var _wrap_Foo_num_set unsafe.Pointer + +func _swig_wrap_Foo_num_set(base SwigcptrFoo, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_num_set, _swig_p) + return +} + +func (arg1 SwigcptrFoo) SetNum(arg2 int) { + _swig_wrap_Foo_num_set(arg1, arg2) +} + +var _wrap_Foo_num_get unsafe.Pointer + +func _swig_wrap_Foo_num_get(base SwigcptrFoo) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_num_get, _swig_p) + return +} + +func (arg1 SwigcptrFoo) GetNum() (_swig_ret int) { + return _swig_wrap_Foo_num_get(arg1) +} + +var _wrap_Foo_func1 unsafe.Pointer + +func _swig_wrap_Foo_func1(base SwigcptrFoo, _ int) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_func1, _swig_p) + return +} + +func (arg1 SwigcptrFoo) Func1(arg2 int) (_swig_ret int) { + return _swig_wrap_Foo_func1(arg1, arg2) +} + +var _wrap_Foo_func2 unsafe.Pointer + +func _swig_wrap_Foo_func2(base SwigcptrFoo, _ int) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_func2, _swig_p) + return +} + +func (arg1 SwigcptrFoo) Func2(arg2 int) (_swig_ret int) { + return _swig_wrap_Foo_func2(arg1, arg2) +} + +var _wrap_Foo_func_ptr_set unsafe.Pointer + +func _swig_wrap_Foo_func_ptr_set(base SwigcptrFoo, _ _swig_memberptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_func_ptr_set, _swig_p) + return +} + +func (arg1 SwigcptrFoo) SetFunc_ptr(arg2 _swig_memberptr) { + _swig_wrap_Foo_func_ptr_set(arg1, arg2) +} + +var _wrap_Foo_func_ptr_get unsafe.Pointer + +func _swig_wrap_Foo_func_ptr_get(base SwigcptrFoo) (_ _swig_memberptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_func_ptr_get, _swig_p) + return +} + +func (arg1 SwigcptrFoo) GetFunc_ptr() (_swig_ret _swig_memberptr) { + return _swig_wrap_Foo_func_ptr_get(arg1) +} + +var _wrap_Foo___str__ unsafe.Pointer + +func _swig_wrap_Foo___str__(base SwigcptrFoo) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo___str__, _swig_p) + return +} + +func (arg1 SwigcptrFoo) X__str__() (_swig_ret string) { + return _swig_wrap_Foo___str__(arg1) +} + +var _wrap_delete_Foo unsafe.Pointer + +func _swig_wrap_delete_Foo(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Foo, _swig_p) + return +} + +func DeleteFoo(arg1 Foo) { + _swig_wrap_delete_Foo(arg1.Swigcptr()) +} + +type Foo interface { + Swigcptr() uintptr + SwigIsFoo() + SetNum(arg2 int) + GetNum() (_swig_ret int) + Func1(arg2 int) (_swig_ret int) + Func2(arg2 int) (_swig_ret int) + SetFunc_ptr(arg2 _swig_memberptr) + GetFunc_ptr() (_swig_ret _swig_memberptr) + X__str__() (_swig_ret string) +} + +type SwigcptrFooSub uintptr + +func (p SwigcptrFooSub) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrFooSub) SwigIsFooSub() { +} + +var _wrap_new_FooSub unsafe.Pointer + +func _swig_wrap_new_FooSub() (base SwigcptrFooSub) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_FooSub, _swig_p) + return +} + +func NewFooSub() (_swig_ret FooSub) { + return _swig_wrap_new_FooSub() +} + +var _wrap_delete_FooSub unsafe.Pointer + +func _swig_wrap_delete_FooSub(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_FooSub, _swig_p) + return +} + +func DeleteFooSub(arg1 FooSub) { + _swig_wrap_delete_FooSub(arg1.Swigcptr()) +} + +var _wrap_SetFooSub_Num unsafe.Pointer + +func _swig_wrap_SetFooSub_Num(base SwigcptrFooSub, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_SetFooSub_Num, _swig_p) + return +} + +func (_swig_base SwigcptrFooSub) SetNum(arg1 int) { + _swig_wrap_SetFooSub_Num(_swig_base, arg1) +} + +var _wrap_GetFooSub_Num unsafe.Pointer + +func _swig_wrap_GetFooSub_Num(base SwigcptrFooSub) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_GetFooSub_Num, _swig_p) + return +} + +func (_swig_base SwigcptrFooSub) GetNum() (_swig_ret int) { + return _swig_wrap_GetFooSub_Num(_swig_base) +} + +var _wrap_FooSub_func1 unsafe.Pointer + +func _swig_wrap_FooSub_func1(base SwigcptrFooSub, _ int) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_FooSub_func1, _swig_p) + return +} + +func (_swig_base SwigcptrFooSub) Func1(arg1 int) (_swig_ret int) { + return _swig_wrap_FooSub_func1(_swig_base, arg1) +} + +var _wrap_FooSub_func2 unsafe.Pointer + +func _swig_wrap_FooSub_func2(base SwigcptrFooSub, _ int) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_FooSub_func2, _swig_p) + return +} + +func (_swig_base SwigcptrFooSub) Func2(arg1 int) (_swig_ret int) { + return _swig_wrap_FooSub_func2(_swig_base, arg1) +} + +var _wrap_SetFooSub_Func_ptr unsafe.Pointer + +func _swig_wrap_SetFooSub_Func_ptr(base SwigcptrFooSub, _ _swig_memberptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_SetFooSub_Func_ptr, _swig_p) + return +} + +func (_swig_base SwigcptrFooSub) SetFunc_ptr(arg1 _swig_memberptr) { + _swig_wrap_SetFooSub_Func_ptr(_swig_base, arg1) +} + +var _wrap_GetFooSub_Func_ptr unsafe.Pointer + +func _swig_wrap_GetFooSub_Func_ptr(base SwigcptrFooSub) (_ _swig_memberptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_GetFooSub_Func_ptr, _swig_p) + return +} + +func (_swig_base SwigcptrFooSub) GetFunc_ptr() (_swig_ret _swig_memberptr) { + return _swig_wrap_GetFooSub_Func_ptr(_swig_base) +} + +var _wrap_FooSub___str__ unsafe.Pointer + +func _swig_wrap_FooSub___str__(base SwigcptrFooSub) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_FooSub___str__, _swig_p) + return +} + +func (_swig_base SwigcptrFooSub) X__str__() (_swig_ret string) { + return _swig_wrap_FooSub___str__(_swig_base) +} + +func (p SwigcptrFooSub) SwigIsFoo() { +} + +func (p SwigcptrFooSub) SwigGetFoo() Foo { + return SwigcptrFoo(p.Swigcptr()) +} + +type FooSub interface { + Swigcptr() uintptr + SwigIsFooSub() + SetNum(arg1 int) + GetNum() (_swig_ret int) + Func1(arg1 int) (_swig_ret int) + Func2(arg1 int) (_swig_ret int) + SetFunc_ptr(arg1 _swig_memberptr) + GetFunc_ptr() (_swig_ret _swig_memberptr) + X__str__() (_swig_ret string) + SwigIsFoo() + SwigGetFoo() Foo +} + +type SwigcptrFooSubSub uintptr + +func (p SwigcptrFooSubSub) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrFooSubSub) SwigIsFooSubSub() { +} + +var _wrap_new_FooSubSub unsafe.Pointer + +func _swig_wrap_new_FooSubSub() (base SwigcptrFooSubSub) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_FooSubSub, _swig_p) + return +} + +func NewFooSubSub() (_swig_ret FooSubSub) { + return _swig_wrap_new_FooSubSub() +} + +var _wrap_FooSubSub___str__ unsafe.Pointer + +func _swig_wrap_FooSubSub___str__(base SwigcptrFooSubSub) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_FooSubSub___str__, _swig_p) + return +} + +func (arg1 SwigcptrFooSubSub) X__str__() (_swig_ret string) { + return _swig_wrap_FooSubSub___str__(arg1) +} + +var _wrap_delete_FooSubSub unsafe.Pointer + +func _swig_wrap_delete_FooSubSub(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_FooSubSub, _swig_p) + return +} + +func DeleteFooSubSub(arg1 FooSubSub) { + _swig_wrap_delete_FooSubSub(arg1.Swigcptr()) +} + +var _wrap_SetFooSubSub_Num unsafe.Pointer + +func _swig_wrap_SetFooSubSub_Num(base SwigcptrFooSubSub, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_SetFooSubSub_Num, _swig_p) + return +} + +func (_swig_base SwigcptrFooSubSub) SetNum(arg1 int) { + _swig_wrap_SetFooSubSub_Num(_swig_base, arg1) +} + +var _wrap_GetFooSubSub_Num unsafe.Pointer + +func _swig_wrap_GetFooSubSub_Num(base SwigcptrFooSubSub) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_GetFooSubSub_Num, _swig_p) + return +} + +func (_swig_base SwigcptrFooSubSub) GetNum() (_swig_ret int) { + return _swig_wrap_GetFooSubSub_Num(_swig_base) +} + +var _wrap_FooSubSub_func1 unsafe.Pointer + +func _swig_wrap_FooSubSub_func1(base SwigcptrFooSubSub, _ int) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_FooSubSub_func1, _swig_p) + return +} + +func (_swig_base SwigcptrFooSubSub) Func1(arg1 int) (_swig_ret int) { + return _swig_wrap_FooSubSub_func1(_swig_base, arg1) +} + +var _wrap_FooSubSub_func2 unsafe.Pointer + +func _swig_wrap_FooSubSub_func2(base SwigcptrFooSubSub, _ int) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_FooSubSub_func2, _swig_p) + return +} + +func (_swig_base SwigcptrFooSubSub) Func2(arg1 int) (_swig_ret int) { + return _swig_wrap_FooSubSub_func2(_swig_base, arg1) +} + +var _wrap_SetFooSubSub_Func_ptr unsafe.Pointer + +func _swig_wrap_SetFooSubSub_Func_ptr(base SwigcptrFooSubSub, _ _swig_memberptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_SetFooSubSub_Func_ptr, _swig_p) + return +} + +func (_swig_base SwigcptrFooSubSub) SetFunc_ptr(arg1 _swig_memberptr) { + _swig_wrap_SetFooSubSub_Func_ptr(_swig_base, arg1) +} + +var _wrap_GetFooSubSub_Func_ptr unsafe.Pointer + +func _swig_wrap_GetFooSubSub_Func_ptr(base SwigcptrFooSubSub) (_ _swig_memberptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_GetFooSubSub_Func_ptr, _swig_p) + return +} + +func (_swig_base SwigcptrFooSubSub) GetFunc_ptr() (_swig_ret _swig_memberptr) { + return _swig_wrap_GetFooSubSub_Func_ptr(_swig_base) +} + +func (p SwigcptrFooSubSub) SwigIsFooSub() { +} + +func (p SwigcptrFooSubSub) SwigGetFooSub() FooSub { + return SwigcptrFooSub(p.Swigcptr()) +} + +func (p SwigcptrFooSubSub) SwigIsFoo() { +} + +func (p SwigcptrFooSubSub) SwigGetFoo() Foo { + return SwigcptrFoo(p.Swigcptr()) +} + +type FooSubSub interface { + Swigcptr() uintptr + SwigIsFooSubSub() + X__str__() (_swig_ret string) + SetNum(arg1 int) + GetNum() (_swig_ret int) + Func1(arg1 int) (_swig_ret int) + Func2(arg1 int) (_swig_ret int) + SetFunc_ptr(arg1 _swig_memberptr) + GetFunc_ptr() (_swig_ret _swig_memberptr) + SwigIsFooSub() + SwigGetFooSub() FooSub + SwigIsFoo() + SwigGetFoo() Foo +} + +type SwigcptrBar uintptr + +func (p SwigcptrBar) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrBar) SwigIsBar() { +} + +var _wrap_new_Bar unsafe.Pointer + +func _swig_wrap_new_Bar() (base SwigcptrBar) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Bar, _swig_p) + return +} + +func NewBar() (_swig_ret Bar) { + return _swig_wrap_new_Bar() +} + +var _wrap_Bar_fptr_set unsafe.Pointer + +func _swig_wrap_Bar_fptr_set(base SwigcptrBar, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Bar_fptr_set, _swig_p) + return +} + +func (arg1 SwigcptrBar) SetFptr(arg2 Foo) { + _swig_wrap_Bar_fptr_set(arg1, arg2.Swigcptr()) +} + +var _wrap_Bar_fptr_get unsafe.Pointer + +func _swig_wrap_Bar_fptr_get(base SwigcptrBar) (_ SwigcptrFoo) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Bar_fptr_get, _swig_p) + return +} + +func (arg1 SwigcptrBar) GetFptr() (_swig_ret Foo) { + return _swig_wrap_Bar_fptr_get(arg1) +} + +var _wrap_Bar_fref_set unsafe.Pointer + +func _swig_wrap_Bar_fref_set(base SwigcptrBar, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Bar_fref_set, _swig_p) + return +} + +func (arg1 SwigcptrBar) SetFref(arg2 Foo) { + _swig_wrap_Bar_fref_set(arg1, arg2.Swigcptr()) +} + +var _wrap_Bar_fref_get unsafe.Pointer + +func _swig_wrap_Bar_fref_get(base SwigcptrBar) (_ SwigcptrFoo) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Bar_fref_get, _swig_p) + return +} + +func (arg1 SwigcptrBar) GetFref() (_swig_ret Foo) { + return _swig_wrap_Bar_fref_get(arg1) +} + +var _wrap_Bar_fval_set unsafe.Pointer + +func _swig_wrap_Bar_fval_set(base SwigcptrBar, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Bar_fval_set, _swig_p) + return +} + +func (arg1 SwigcptrBar) SetFval(arg2 Foo) { + _swig_wrap_Bar_fval_set(arg1, arg2.Swigcptr()) +} + +var _wrap_Bar_fval_get unsafe.Pointer + +func _swig_wrap_Bar_fval_get(base SwigcptrBar) (_ SwigcptrFoo) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Bar_fval_get, _swig_p) + return +} + +func (arg1 SwigcptrBar) GetFval() (_swig_ret Foo) { + return _swig_wrap_Bar_fval_get(arg1) +} + +var _wrap_Bar_cint_get unsafe.Pointer + +func _swig_wrap_Bar_cint_get(base SwigcptrBar) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Bar_cint_get, _swig_p) + return +} + +func (arg1 SwigcptrBar) GetCint() (_swig_ret int) { + return _swig_wrap_Bar_cint_get(arg1) +} + +var _wrap_Bar_global_cint_Bar unsafe.Pointer + +func _swig_getBar_Bar_global_cint_Bar() (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_Bar_global_cint_Bar, _swig_p) + return +} +var BarGlobal_cint int = _swig_getBar_Bar_global_cint_Bar() +var _wrap_Bar_global_fptr_set unsafe.Pointer + +func _swig_wrap_Bar_global_fptr_set(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Bar_global_fptr_set, _swig_p) + return +} + +func SetBarGlobal_fptr(arg1 Foo) { + _swig_wrap_Bar_global_fptr_set(arg1.Swigcptr()) +} + +var _wrap_Bar_global_fptr_get unsafe.Pointer + +func _swig_wrap_Bar_global_fptr_get() (base SwigcptrFoo) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Bar_global_fptr_get, _swig_p) + return +} + +func GetBarGlobal_fptr() (_swig_ret Foo) { + return _swig_wrap_Bar_global_fptr_get() +} + +var _wrap_Bar_global_fref_set unsafe.Pointer + +func _swig_wrap_Bar_global_fref_set(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Bar_global_fref_set, _swig_p) + return +} + +func SetBarGlobal_fref(arg1 Foo) { + _swig_wrap_Bar_global_fref_set(arg1.Swigcptr()) +} + +var _wrap_Bar_global_fref_get unsafe.Pointer + +func _swig_wrap_Bar_global_fref_get() (base SwigcptrFoo) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Bar_global_fref_get, _swig_p) + return +} + +func GetBarGlobal_fref() (_swig_ret Foo) { + return _swig_wrap_Bar_global_fref_get() +} + +var _wrap_Bar_global_fval_set unsafe.Pointer + +func _swig_wrap_Bar_global_fval_set(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Bar_global_fval_set, _swig_p) + return +} + +func SetBarGlobal_fval(arg1 Foo) { + _swig_wrap_Bar_global_fval_set(arg1.Swigcptr()) +} + +var _wrap_Bar_global_fval_get unsafe.Pointer + +func _swig_wrap_Bar_global_fval_get() (base SwigcptrFoo) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Bar_global_fval_get, _swig_p) + return +} + +func GetBarGlobal_fval() (_swig_ret Foo) { + return _swig_wrap_Bar_global_fval_get() +} + +var _wrap_Bar_test unsafe.Pointer + +func _swig_wrap_Bar_test(base SwigcptrBar, _ int, _ uintptr) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Bar_test, _swig_p) + return +} + +func (arg1 SwigcptrBar) Test(arg2 int, arg3 Foo) (_swig_ret int) { + return _swig_wrap_Bar_test(arg1, arg2, arg3.Swigcptr()) +} + +var _wrap_Bar_testFoo unsafe.Pointer + +func _swig_wrap_Bar_testFoo(base SwigcptrBar, _ int, _ uintptr) (_ SwigcptrFoo) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Bar_testFoo, _swig_p) + return +} + +func (arg1 SwigcptrBar) TestFoo(arg2 int, arg3 Foo) (_swig_ret Foo) { + return _swig_wrap_Bar_testFoo(arg1, arg2, arg3.Swigcptr()) +} + +var _wrap_delete_Bar unsafe.Pointer + +func _swig_wrap_delete_Bar(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Bar, _swig_p) + return +} + +func DeleteBar(arg1 Bar) { + _swig_wrap_delete_Bar(arg1.Swigcptr()) +} + +type Bar interface { + Swigcptr() uintptr + SwigIsBar() + SetFptr(arg2 Foo) + GetFptr() (_swig_ret Foo) + SetFref(arg2 Foo) + GetFref() (_swig_ret Foo) + SetFval(arg2 Foo) + GetFval() (_swig_ret Foo) + GetCint() (_swig_ret int) + Test(arg2 int, arg3 Foo) (_swig_ret int) + TestFoo(arg2 int, arg3 Foo) (_swig_ret Foo) +} + +var _wrap_get_func1_ptr unsafe.Pointer + +func Get_func1_ptr() (_swig_ret _swig_memberptr) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_get_func1_ptr, _swig_p) + return +} +var _wrap_get_func2_ptr unsafe.Pointer + +func Get_func2_ptr() (_swig_ret _swig_memberptr) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_get_func2_ptr, _swig_p) + return +} +var _wrap_test_func_ptr unsafe.Pointer + +func _swig_wrap_test_func_ptr(base uintptr, _ int) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_test_func_ptr, _swig_p) + return +} + +func Test_func_ptr(arg1 Foo, arg2 int) (_swig_ret int) { + return _swig_wrap_test_func_ptr(arg1.Swigcptr(), arg2) +} + +type SwigcptrFl_Window uintptr + +func (p SwigcptrFl_Window) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrFl_Window) SwigIsFl_Window() { +} + +var _wrap_new_Fl_Window unsafe.Pointer + +func _swig_wrap_new_Fl_Window() (base SwigcptrFl_Window) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Fl_Window, _swig_p) + return +} + +func NewFl_Window() (_swig_ret Fl_Window) { + return _swig_wrap_new_Fl_Window() +} + +var _wrap_delete_Fl_Window unsafe.Pointer + +func _swig_wrap_delete_Fl_Window(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Fl_Window, _swig_p) + return +} + +func DeleteFl_Window(arg1 Fl_Window) { + _swig_wrap_delete_Fl_Window(arg1.Swigcptr()) +} + +var _wrap_Fl_Window_show__SWIG_0 unsafe.Pointer + +func _swig_wrap_Fl_Window_show__SWIG_0(base SwigcptrFl_Window, _ uintptr, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Fl_Window_show__SWIG_0, _swig_p) + return +} + +func (arg1 SwigcptrFl_Window) Show__SWIG_0(arg2 uintptr, arg3 uintptr) { + _swig_wrap_Fl_Window_show__SWIG_0(arg1, arg2, arg3) +} + +var _wrap_Fl_Window_show__SWIG_1 unsafe.Pointer + +func _swig_wrap_Fl_Window_show__SWIG_1(base SwigcptrFl_Window, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Fl_Window_show__SWIG_1, _swig_p) + return +} + +func (arg1 SwigcptrFl_Window) Show__SWIG_1(arg2 uintptr) { + _swig_wrap_Fl_Window_show__SWIG_1(arg1, arg2) +} + +var _wrap_Fl_Window_show__SWIG_2 unsafe.Pointer + +func _swig_wrap_Fl_Window_show__SWIG_2(base SwigcptrFl_Window) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Fl_Window_show__SWIG_2, _swig_p) + return +} + +func (arg1 SwigcptrFl_Window) Show__SWIG_2() { + _swig_wrap_Fl_Window_show__SWIG_2(arg1) +} + +func (p SwigcptrFl_Window) Show(a ...interface{}) { + argc := len(a) + if argc == 0 { + p.Show__SWIG_2() + return + } + if argc == 1 { + p.Show__SWIG_1(a[0].(uintptr)) + return + } + if argc == 2 { + p.Show__SWIG_0(a[0].(uintptr), a[1].(uintptr)) + return + } + panic("No match for overloaded function call") +} + +type Fl_Window interface { + Swigcptr() uintptr + SwigIsFl_Window() + Show(a ...interface{}) +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/cpp_enum.go b/Examples/test-suite/go/cpp_enum.go new file mode 100644 index 000000000..4b9bec1a3 --- /dev/null +++ b/Examples/test-suite/go/cpp_enum.go @@ -0,0 +1,354 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../cpp_enum.i + +package cpp_enum + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SOME_ENUM int +var _wrap_ENUM_ONE unsafe.Pointer + +func _swig_getENUM_ONE() (_swig_ret SOME_ENUM) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_ENUM_ONE, _swig_p) + return +} +var ENUM_ONE SOME_ENUM = _swig_getENUM_ONE() +var _wrap_ENUM_TWO unsafe.Pointer + +func _swig_getENUM_TWO() (_swig_ret SOME_ENUM) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_ENUM_TWO, _swig_p) + return +} +var ENUM_TWO SOME_ENUM = _swig_getENUM_TWO() +type SwigcptrStructWithEnums uintptr + +func (p SwigcptrStructWithEnums) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrStructWithEnums) SwigIsStructWithEnums() { +} + +var _wrap_new_StructWithEnums unsafe.Pointer + +func _swig_wrap_new_StructWithEnums() (base SwigcptrStructWithEnums) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_StructWithEnums, _swig_p) + return +} + +func NewStructWithEnums() (_swig_ret StructWithEnums) { + return _swig_wrap_new_StructWithEnums() +} + +var _wrap_StructWithEnums_some_enum_set unsafe.Pointer + +func _swig_wrap_StructWithEnums_some_enum_set(base SwigcptrStructWithEnums, _ SOME_ENUM) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_StructWithEnums_some_enum_set, _swig_p) + return +} + +func (arg1 SwigcptrStructWithEnums) SetSome_enum(arg2 SOME_ENUM) { + _swig_wrap_StructWithEnums_some_enum_set(arg1, arg2) +} + +var _wrap_StructWithEnums_some_enum_get unsafe.Pointer + +func _swig_wrap_StructWithEnums_some_enum_get(base SwigcptrStructWithEnums) (_ SOME_ENUM) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_StructWithEnums_some_enum_get, _swig_p) + return +} + +func (arg1 SwigcptrStructWithEnums) GetSome_enum() (_swig_ret SOME_ENUM) { + return _swig_wrap_StructWithEnums_some_enum_get(arg1) +} + +var _wrap_StructWithEnums_enum_test1 unsafe.Pointer + +func _swig_wrap_StructWithEnums_enum_test1(base SwigcptrStructWithEnums, _ SOME_ENUM, _ *SOME_ENUM, _ *SOME_ENUM) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_StructWithEnums_enum_test1, _swig_p) + return +} + +func (arg1 SwigcptrStructWithEnums) Enum_test1(arg2 SOME_ENUM, arg3 *SOME_ENUM, arg4 *SOME_ENUM) { + _swig_wrap_StructWithEnums_enum_test1(arg1, arg2, arg3, arg4) +} + +var _wrap_StructWithEnums_enum_test2 unsafe.Pointer + +func _swig_wrap_StructWithEnums_enum_test2(base SwigcptrStructWithEnums, _ SOME_ENUM, _ *SOME_ENUM, _ *SOME_ENUM) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_StructWithEnums_enum_test2, _swig_p) + return +} + +func (arg1 SwigcptrStructWithEnums) Enum_test2(arg2 SOME_ENUM, arg3 *SOME_ENUM, arg4 *SOME_ENUM) { + _swig_wrap_StructWithEnums_enum_test2(arg1, arg2, arg3, arg4) +} + +var _wrap_StructWithEnums_enum_test3 unsafe.Pointer + +func _swig_wrap_StructWithEnums_enum_test3(base SwigcptrStructWithEnums) (_ SOME_ENUM) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_StructWithEnums_enum_test3, _swig_p) + return +} + +func (arg1 SwigcptrStructWithEnums) Enum_test3() (_swig_ret SOME_ENUM) { + return _swig_wrap_StructWithEnums_enum_test3(arg1) +} + +var _wrap_StructWithEnums_enum_test4 unsafe.Pointer + +func _swig_wrap_StructWithEnums_enum_test4(base SwigcptrStructWithEnums) (_ SOME_ENUM) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_StructWithEnums_enum_test4, _swig_p) + return +} + +func (arg1 SwigcptrStructWithEnums) Enum_test4() (_swig_ret SOME_ENUM) { + return _swig_wrap_StructWithEnums_enum_test4(arg1) +} + +var _wrap_StructWithEnums_enum_test5 unsafe.Pointer + +func _swig_wrap_StructWithEnums_enum_test5(base SwigcptrStructWithEnums) (_ *SOME_ENUM) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_StructWithEnums_enum_test5, _swig_p) + return +} + +func (arg1 SwigcptrStructWithEnums) Enum_test5() (_swig_ret *SOME_ENUM) { + return _swig_wrap_StructWithEnums_enum_test5(arg1) +} + +var _wrap_StructWithEnums_enum_test6 unsafe.Pointer + +func _swig_wrap_StructWithEnums_enum_test6(base SwigcptrStructWithEnums) (_ *SOME_ENUM) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_StructWithEnums_enum_test6, _swig_p) + return +} + +func (arg1 SwigcptrStructWithEnums) Enum_test6() (_swig_ret *SOME_ENUM) { + return _swig_wrap_StructWithEnums_enum_test6(arg1) +} + +var _wrap_StructWithEnums_enum_test7 unsafe.Pointer + +func _swig_wrap_StructWithEnums_enum_test7(base SwigcptrStructWithEnums) (_ *SOME_ENUM) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_StructWithEnums_enum_test7, _swig_p) + return +} + +func (arg1 SwigcptrStructWithEnums) Enum_test7() (_swig_ret *SOME_ENUM) { + return _swig_wrap_StructWithEnums_enum_test7(arg1) +} + +var _wrap_StructWithEnums_enum_test8 unsafe.Pointer + +func _swig_wrap_StructWithEnums_enum_test8(base SwigcptrStructWithEnums) (_ *SOME_ENUM) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_StructWithEnums_enum_test8, _swig_p) + return +} + +func (arg1 SwigcptrStructWithEnums) Enum_test8() (_swig_ret *SOME_ENUM) { + return _swig_wrap_StructWithEnums_enum_test8(arg1) +} + +var _wrap_delete_StructWithEnums unsafe.Pointer + +func _swig_wrap_delete_StructWithEnums(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_StructWithEnums, _swig_p) + return +} + +func DeleteStructWithEnums(arg1 StructWithEnums) { + _swig_wrap_delete_StructWithEnums(arg1.Swigcptr()) +} + +type StructWithEnums interface { + Swigcptr() uintptr + SwigIsStructWithEnums() + SetSome_enum(arg2 SOME_ENUM) + GetSome_enum() (_swig_ret SOME_ENUM) + Enum_test1(arg2 SOME_ENUM, arg3 *SOME_ENUM, arg4 *SOME_ENUM) + Enum_test2(arg2 SOME_ENUM, arg3 *SOME_ENUM, arg4 *SOME_ENUM) + Enum_test3() (_swig_ret SOME_ENUM) + Enum_test4() (_swig_ret SOME_ENUM) + Enum_test5() (_swig_ret *SOME_ENUM) + Enum_test6() (_swig_ret *SOME_ENUM) + Enum_test7() (_swig_ret *SOME_ENUM) + Enum_test8() (_swig_ret *SOME_ENUM) +} + +type SwigcptrFoo uintptr + +func (p SwigcptrFoo) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrFoo) SwigIsFoo() { +} + +var _wrap_Hi_Foo unsafe.Pointer + +func _swig_getFoo_Hi_Foo() (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_Hi_Foo, _swig_p) + return +} +var FooHi int = _swig_getFoo_Hi_Foo() +var _wrap_Hello_Foo unsafe.Pointer + +func _swig_getFoo_Hello_Foo() (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_Hello_Foo, _swig_p) + return +} +var FooHello int = _swig_getFoo_Hello_Foo() +var _wrap_Foo_hola_set unsafe.Pointer + +func _swig_wrap_Foo_hola_set(base SwigcptrFoo, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_hola_set, _swig_p) + return +} + +func (arg1 SwigcptrFoo) SetHola(arg2 int) { + _swig_wrap_Foo_hola_set(arg1, arg2) +} + +var _wrap_Foo_hola_get unsafe.Pointer + +func _swig_wrap_Foo_hola_get(base SwigcptrFoo) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_hola_get, _swig_p) + return +} + +func (arg1 SwigcptrFoo) GetHola() (_swig_ret int) { + return _swig_wrap_Foo_hola_get(arg1) +} + +var _wrap_new_Foo unsafe.Pointer + +func _swig_wrap_new_Foo() (base SwigcptrFoo) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Foo, _swig_p) + return +} + +func NewFoo() (_swig_ret Foo) { + return _swig_wrap_new_Foo() +} + +var _wrap_delete_Foo unsafe.Pointer + +func _swig_wrap_delete_Foo(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Foo, _swig_p) + return +} + +func DeleteFoo(arg1 Foo) { + _swig_wrap_delete_Foo(arg1.Swigcptr()) +} + +type Foo interface { + Swigcptr() uintptr + SwigIsFoo() + SetHola(arg2 int) + GetHola() (_swig_ret int) +} + +var _wrap_Hi unsafe.Pointer + +func _swig_getHi() (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_Hi, _swig_p) + return +} +var Hi int = _swig_getHi() +var _wrap_Hello unsafe.Pointer + +func _swig_getHello() (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_Hello, _swig_p) + return +} +var Hello int = _swig_getHello() +var _wrap_hi_set unsafe.Pointer + +func _swig_wrap_hi_set(base int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_hi_set, _swig_p) + return +} + +func SetHi(arg1 int) { + _swig_wrap_hi_set(arg1) +} + +var _wrap_hi_get unsafe.Pointer + +func GetHi() (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_hi_get, _swig_p) + return +} +type Play_state int +var _wrap_PLAY unsafe.Pointer + +func _swig_getPLAY() (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_PLAY, _swig_p) + return +} +var PLAY int = _swig_getPLAY() +var _wrap_STOP unsafe.Pointer + +func _swig_getSTOP() (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_STOP, _swig_p) + return +} +var STOP int = _swig_getSTOP() + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/cpp_enum_runme b/Examples/test-suite/go/cpp_enum_runme new file mode 100755 index 000000000..164b08eba Binary files /dev/null and b/Examples/test-suite/go/cpp_enum_runme differ diff --git a/Examples/test-suite/go/cpp_namespace.go b/Examples/test-suite/go/cpp_namespace.go new file mode 100644 index 000000000..fdab5cbbf --- /dev/null +++ b/Examples/test-suite/go/cpp_namespace.go @@ -0,0 +1,418 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../cpp_namespace.i + +package cpp_namespace + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +var _wrap_fact unsafe.Pointer + +func Fact(arg1 int) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_fact, _swig_p) + return +} +var _wrap_Foo_set unsafe.Pointer + +func _swig_wrap_Foo_set(base int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_set, _swig_p) + return +} + +func SetFoo(arg1 int) { + _swig_wrap_Foo_set(arg1) +} + +var _wrap_Foo_get unsafe.Pointer + +func GetFoo() (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_Foo_get, _swig_p) + return +} +type SwigcptrTest uintptr + +func (p SwigcptrTest) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrTest) SwigIsTest() { +} + +var _wrap_new_Test unsafe.Pointer + +func _swig_wrap_new_Test() (base SwigcptrTest) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Test, _swig_p) + return +} + +func NewTest() (_swig_ret Test) { + return _swig_wrap_new_Test() +} + +var _wrap_delete_Test unsafe.Pointer + +func _swig_wrap_delete_Test(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Test, _swig_p) + return +} + +func DeleteTest(arg1 Test) { + _swig_wrap_delete_Test(arg1.Swigcptr()) +} + +var _wrap_Test_method unsafe.Pointer + +func _swig_wrap_Test_method(base SwigcptrTest) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Test_method, _swig_p) + return +} + +func (arg1 SwigcptrTest) Method() (_swig_ret string) { + return _swig_wrap_Test_method(arg1) +} + +type Test interface { + Swigcptr() uintptr + SwigIsTest() + Method() (_swig_ret string) +} + +var _wrap_weird unsafe.Pointer + +func _swig_wrap_weird(base string, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_weird, _swig_p) + return +} + +func Weird(arg1 string, arg2 int) { + _swig_wrap_weird(arg1, arg2) +} + +var _wrap_do_method unsafe.Pointer + +func _swig_wrap_do_method(base uintptr) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_do_method, _swig_p) + return +} + +func Do_method(arg1 Test) (_swig_ret string) { + return _swig_wrap_do_method(arg1.Swigcptr()) +} + +var _wrap_do_method2 unsafe.Pointer + +func _swig_wrap_do_method2(base uintptr) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_do_method2, _swig_p) + return +} + +func Do_method2(arg1 Test) (_swig_ret string) { + return _swig_wrap_do_method2(arg1.Swigcptr()) +} + +type SwigcptrTest2 uintptr + +func (p SwigcptrTest2) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrTest2) SwigIsTest2() { +} + +var _wrap_delete_Test2 unsafe.Pointer + +func _swig_wrap_delete_Test2(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Test2, _swig_p) + return +} + +func DeleteTest2(arg1 Test2) { + _swig_wrap_delete_Test2(arg1.Swigcptr()) +} + +var _wrap_Test2_method unsafe.Pointer + +func _swig_wrap_Test2_method(base SwigcptrTest2) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Test2_method, _swig_p) + return +} + +func (arg1 SwigcptrTest2) Method() (_swig_ret string) { + return _swig_wrap_Test2_method(arg1) +} + +var _wrap_new_Test2 unsafe.Pointer + +func _swig_wrap_new_Test2() (base SwigcptrTest2) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Test2, _swig_p) + return +} + +func NewTest2() (_swig_ret Test2) { + return _swig_wrap_new_Test2() +} + +type Test2 interface { + Swigcptr() uintptr + SwigIsTest2() + Method() (_swig_ret string) +} + +type SwigcptrTest3 uintptr + +func (p SwigcptrTest3) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrTest3) SwigIsTest3() { +} + +var _wrap_Test3_method unsafe.Pointer + +func _swig_wrap_Test3_method(base SwigcptrTest3) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Test3_method, _swig_p) + return +} + +func (arg1 SwigcptrTest3) Method() (_swig_ret string) { + return _swig_wrap_Test3_method(arg1) +} + +var _wrap_new_Test3 unsafe.Pointer + +func _swig_wrap_new_Test3() (base SwigcptrTest3) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Test3, _swig_p) + return +} + +func NewTest3() (_swig_ret Test3) { + return _swig_wrap_new_Test3() +} + +var _wrap_delete_Test3 unsafe.Pointer + +func _swig_wrap_delete_Test3(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Test3, _swig_p) + return +} + +func DeleteTest3(arg1 Test3) { + _swig_wrap_delete_Test3(arg1.Swigcptr()) +} + +func (p SwigcptrTest3) SwigIsTest2() { +} + +func (p SwigcptrTest3) SwigGetTest2() Test2 { + return SwigcptrTest2(p.Swigcptr()) +} + +type Test3 interface { + Swigcptr() uintptr + SwigIsTest3() + Method() (_swig_ret string) + SwigIsTest2() + SwigGetTest2() Test2 +} + +type SwigcptrTest4 uintptr + +func (p SwigcptrTest4) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrTest4) SwigIsTest4() { +} + +var _wrap_Test4_method unsafe.Pointer + +func _swig_wrap_Test4_method(base SwigcptrTest4) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Test4_method, _swig_p) + return +} + +func (arg1 SwigcptrTest4) Method() (_swig_ret string) { + return _swig_wrap_Test4_method(arg1) +} + +var _wrap_new_Test4 unsafe.Pointer + +func _swig_wrap_new_Test4() (base SwigcptrTest4) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Test4, _swig_p) + return +} + +func NewTest4() (_swig_ret Test4) { + return _swig_wrap_new_Test4() +} + +var _wrap_delete_Test4 unsafe.Pointer + +func _swig_wrap_delete_Test4(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Test4, _swig_p) + return +} + +func DeleteTest4(arg1 Test4) { + _swig_wrap_delete_Test4(arg1.Swigcptr()) +} + +func (p SwigcptrTest4) SwigIsTest3() { +} + +func (p SwigcptrTest4) SwigGetTest3() Test3 { + return SwigcptrTest3(p.Swigcptr()) +} + +func (p SwigcptrTest4) SwigIsTest2() { +} + +func (p SwigcptrTest4) SwigGetTest2() Test2 { + return SwigcptrTest2(p.Swigcptr()) +} + +type Test4 interface { + Swigcptr() uintptr + SwigIsTest4() + Method() (_swig_ret string) + SwigIsTest3() + SwigGetTest3() Test3 + SwigIsTest2() + SwigGetTest2() Test2 +} + +var _wrap_foo3 unsafe.Pointer + +func Foo3(arg1 int) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_foo3, _swig_p) + return +} +type SwigcptrTest5 uintptr + +func (p SwigcptrTest5) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrTest5) SwigIsTest5() { +} + +var _wrap_Test5_method unsafe.Pointer + +func _swig_wrap_Test5_method(base SwigcptrTest5) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Test5_method, _swig_p) + return +} + +func (arg1 SwigcptrTest5) Method() (_swig_ret string) { + return _swig_wrap_Test5_method(arg1) +} + +var _wrap_new_Test5 unsafe.Pointer + +func _swig_wrap_new_Test5() (base SwigcptrTest5) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Test5, _swig_p) + return +} + +func NewTest5() (_swig_ret Test5) { + return _swig_wrap_new_Test5() +} + +var _wrap_delete_Test5 unsafe.Pointer + +func _swig_wrap_delete_Test5(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Test5, _swig_p) + return +} + +func DeleteTest5(arg1 Test5) { + _swig_wrap_delete_Test5(arg1.Swigcptr()) +} + +func (p SwigcptrTest5) SwigIsTest3() { +} + +func (p SwigcptrTest5) SwigGetTest3() Test3 { + return SwigcptrTest3(p.Swigcptr()) +} + +func (p SwigcptrTest5) SwigIsTest2() { +} + +func (p SwigcptrTest5) SwigGetTest2() Test2 { + return SwigcptrTest2(p.Swigcptr()) +} + +type Test5 interface { + Swigcptr() uintptr + SwigIsTest5() + Method() (_swig_ret string) + SwigIsTest3() + SwigGetTest3() Test3 + SwigIsTest2() + SwigGetTest2() Test2 +} + +var _wrap_do_method3 unsafe.Pointer + +func _swig_wrap_do_method3(base uintptr, _ int) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_do_method3, _swig_p) + return +} + +func Do_method3(arg1 Test2, arg2 int) (_swig_ret string) { + return _swig_wrap_do_method3(arg1.Swigcptr(), arg2) +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/cpp_namespace_runme b/Examples/test-suite/go/cpp_namespace_runme new file mode 100755 index 000000000..e5937721e Binary files /dev/null and b/Examples/test-suite/go/cpp_namespace_runme differ diff --git a/Examples/test-suite/go/cpp_nodefault.go b/Examples/test-suite/go/cpp_nodefault.go new file mode 100644 index 000000000..512492b01 --- /dev/null +++ b/Examples/test-suite/go/cpp_nodefault.go @@ -0,0 +1,213 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../cpp_nodefault.i + +package cpp_nodefault + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrFoo uintptr + +func (p SwigcptrFoo) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrFoo) SwigIsFoo() { +} + +var _wrap_Foo_a_set unsafe.Pointer + +func _swig_wrap_Foo_a_set(base SwigcptrFoo, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_a_set, _swig_p) + return +} + +func (arg1 SwigcptrFoo) SetA(arg2 int) { + _swig_wrap_Foo_a_set(arg1, arg2) +} + +var _wrap_Foo_a_get unsafe.Pointer + +func _swig_wrap_Foo_a_get(base SwigcptrFoo) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_a_get, _swig_p) + return +} + +func (arg1 SwigcptrFoo) GetA() (_swig_ret int) { + return _swig_wrap_Foo_a_get(arg1) +} + +var _wrap_new_Foo unsafe.Pointer + +func _swig_wrap_new_Foo(base int, _ int) (_ SwigcptrFoo) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Foo, _swig_p) + return +} + +func NewFoo(arg1 int, arg2 int) (_swig_ret Foo) { + return _swig_wrap_new_Foo(arg1, arg2) +} + +var _wrap_delete_Foo unsafe.Pointer + +func _swig_wrap_delete_Foo(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Foo, _swig_p) + return +} + +func DeleteFoo(arg1 Foo) { + _swig_wrap_delete_Foo(arg1.Swigcptr()) +} + +type Foo interface { + Swigcptr() uintptr + SwigIsFoo() + SetA(arg2 int) + GetA() (_swig_ret int) +} + +var _wrap_create unsafe.Pointer + +func _swig_wrap_create(base int, _ int) (_ SwigcptrFoo) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_create, _swig_p) + return +} + +func Create(arg1 int, arg2 int) (_swig_ret Foo) { + return _swig_wrap_create(arg1, arg2) +} + +var _wrap_consume unsafe.Pointer + +func _swig_wrap_consume(base uintptr, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_consume, _swig_p) + return +} + +func Consume(arg1 Foo, arg2 Foo) { + _swig_wrap_consume(arg1.Swigcptr(), arg2.Swigcptr()) +} + +type SwigcptrBar uintptr + +func (p SwigcptrBar) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrBar) SwigIsBar() { +} + +var _wrap_Bar_consume unsafe.Pointer + +func _swig_wrap_Bar_consume(base SwigcptrBar, _ uintptr, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Bar_consume, _swig_p) + return +} + +func (arg1 SwigcptrBar) Consume(arg2 Foo, arg3 Foo) { + _swig_wrap_Bar_consume(arg1, arg2.Swigcptr(), arg3.Swigcptr()) +} + +var _wrap_Bar_create unsafe.Pointer + +func _swig_wrap_Bar_create(base SwigcptrBar, _ int, _ int) (_ SwigcptrFoo) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Bar_create, _swig_p) + return +} + +func (arg1 SwigcptrBar) Create(arg2 int, arg3 int) (_swig_ret Foo) { + return _swig_wrap_Bar_create(arg1, arg2, arg3) +} + +var _wrap_new_Bar unsafe.Pointer + +func _swig_wrap_new_Bar() (base SwigcptrBar) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Bar, _swig_p) + return +} + +func NewBar() (_swig_ret Bar) { + return _swig_wrap_new_Bar() +} + +var _wrap_delete_Bar unsafe.Pointer + +func _swig_wrap_delete_Bar(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Bar, _swig_p) + return +} + +func DeleteBar(arg1 Bar) { + _swig_wrap_delete_Bar(arg1.Swigcptr()) +} + +type Bar interface { + Swigcptr() uintptr + SwigIsBar() + Consume(arg2 Foo, arg3 Foo) + Create(arg2 int, arg3 int) (_swig_ret Foo) +} + +var _wrap_gvar_set unsafe.Pointer + +func _swig_wrap_gvar_set(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_gvar_set, _swig_p) + return +} + +func SetGvar(arg1 Foo) { + _swig_wrap_gvar_set(arg1.Swigcptr()) +} + +var _wrap_gvar_get unsafe.Pointer + +func _swig_wrap_gvar_get() (base SwigcptrFoo) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_gvar_get, _swig_p) + return +} + +func GetGvar() (_swig_ret Foo) { + return _swig_wrap_gvar_get() +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/cpp_static.go b/Examples/test-suite/go/cpp_static.go new file mode 100644 index 000000000..77b9aec1a --- /dev/null +++ b/Examples/test-suite/go/cpp_static.go @@ -0,0 +1,168 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../cpp_static.i + +package cpp_static + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrStaticMemberTest uintptr + +func (p SwigcptrStaticMemberTest) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrStaticMemberTest) SwigIsStaticMemberTest() { +} + +var _wrap_StaticMemberTest_static_int_set unsafe.Pointer + +func _swig_wrap_StaticMemberTest_static_int_set(base int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_StaticMemberTest_static_int_set, _swig_p) + return +} + +func SetStaticMemberTestStatic_int(arg1 int) { + _swig_wrap_StaticMemberTest_static_int_set(arg1) +} + +var _wrap_StaticMemberTest_static_int_get unsafe.Pointer + +func GetStaticMemberTestStatic_int() (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_StaticMemberTest_static_int_get, _swig_p) + return +} +var _wrap_new_StaticMemberTest unsafe.Pointer + +func _swig_wrap_new_StaticMemberTest() (base SwigcptrStaticMemberTest) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_StaticMemberTest, _swig_p) + return +} + +func NewStaticMemberTest() (_swig_ret StaticMemberTest) { + return _swig_wrap_new_StaticMemberTest() +} + +var _wrap_delete_StaticMemberTest unsafe.Pointer + +func _swig_wrap_delete_StaticMemberTest(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_StaticMemberTest, _swig_p) + return +} + +func DeleteStaticMemberTest(arg1 StaticMemberTest) { + _swig_wrap_delete_StaticMemberTest(arg1.Swigcptr()) +} + +type StaticMemberTest interface { + Swigcptr() uintptr + SwigIsStaticMemberTest() +} + +type SwigcptrStaticFunctionTest uintptr + +func (p SwigcptrStaticFunctionTest) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrStaticFunctionTest) SwigIsStaticFunctionTest() { +} + +var _wrap_StaticFunctionTest_static_func unsafe.Pointer + +func _swig_wrap_StaticFunctionTest_static_func() { + var _swig_p uintptr + _cgo_runtime_cgocall(_wrap_StaticFunctionTest_static_func, _swig_p) + return +} + +func StaticFunctionTestStatic_func() { + _swig_wrap_StaticFunctionTest_static_func() +} + +var _wrap_StaticFunctionTest_static_func_2 unsafe.Pointer + +func _swig_wrap_StaticFunctionTest_static_func_2(base int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_StaticFunctionTest_static_func_2, _swig_p) + return +} + +func StaticFunctionTestStatic_func_2(arg1 int) { + _swig_wrap_StaticFunctionTest_static_func_2(arg1) +} + +var _wrap_StaticFunctionTest_static_func_3 unsafe.Pointer + +func _swig_wrap_StaticFunctionTest_static_func_3(base int, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_StaticFunctionTest_static_func_3, _swig_p) + return +} + +func StaticFunctionTestStatic_func_3(arg1 int, arg2 int) { + _swig_wrap_StaticFunctionTest_static_func_3(arg1, arg2) +} + +var _wrap_new_StaticFunctionTest unsafe.Pointer + +func _swig_wrap_new_StaticFunctionTest() (base SwigcptrStaticFunctionTest) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_StaticFunctionTest, _swig_p) + return +} + +func NewStaticFunctionTest() (_swig_ret StaticFunctionTest) { + return _swig_wrap_new_StaticFunctionTest() +} + +var _wrap_delete_StaticFunctionTest unsafe.Pointer + +func _swig_wrap_delete_StaticFunctionTest(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_StaticFunctionTest, _swig_p) + return +} + +func DeleteStaticFunctionTest(arg1 StaticFunctionTest) { + _swig_wrap_delete_StaticFunctionTest(arg1.Swigcptr()) +} + +type StaticFunctionTest interface { + Swigcptr() uintptr + SwigIsStaticFunctionTest() +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/cpp_static_runme b/Examples/test-suite/go/cpp_static_runme new file mode 100755 index 000000000..47143aee9 Binary files /dev/null and b/Examples/test-suite/go/cpp_static_runme differ diff --git a/Examples/test-suite/go/cpp_typedef.go b/Examples/test-suite/go/cpp_typedef.go new file mode 100644 index 000000000..eaa2bf1c5 --- /dev/null +++ b/Examples/test-suite/go/cpp_typedef.go @@ -0,0 +1,352 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../cpp_typedef.i + +package cpp_typedef + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrFoo uintptr + +func (p SwigcptrFoo) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrFoo) SwigIsFoo() { +} + +var _wrap_Foo_bar unsafe.Pointer + +func _swig_wrap_Foo_bar(base SwigcptrFoo) (_ SwigcptrBar) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_bar, _swig_p) + return +} + +func (arg1 SwigcptrFoo) Bar() (_swig_ret Bar) { + return _swig_wrap_Foo_bar(arg1) +} + +var _wrap_Foo_sbar unsafe.Pointer + +func _swig_wrap_Foo_sbar() (base SwigcptrBar) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_sbar, _swig_p) + return +} + +func FooSbar() (_swig_ret Bar) { + return _swig_wrap_Foo_sbar() +} + +var _wrap_new_Foo unsafe.Pointer + +func _swig_wrap_new_Foo() (base SwigcptrFoo) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Foo, _swig_p) + return +} + +func NewFoo() (_swig_ret Foo) { + return _swig_wrap_new_Foo() +} + +var _wrap_delete_Foo unsafe.Pointer + +func _swig_wrap_delete_Foo(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Foo, _swig_p) + return +} + +func DeleteFoo(arg1 Foo) { + _swig_wrap_delete_Foo(arg1.Swigcptr()) +} + +type Foo interface { + Swigcptr() uintptr + SwigIsFoo() + Bar() (_swig_ret Bar) +} + +type SwigcptrUnnamedStruct uintptr + +func (p SwigcptrUnnamedStruct) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrUnnamedStruct) SwigIsUnnamedStruct() { +} + +var _wrap_UnnamedStruct_something_set unsafe.Pointer + +func _swig_wrap_UnnamedStruct_something_set(base SwigcptrUnnamedStruct, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_UnnamedStruct_something_set, _swig_p) + return +} + +func (arg1 SwigcptrUnnamedStruct) SetSomething(arg2 int) { + _swig_wrap_UnnamedStruct_something_set(arg1, arg2) +} + +var _wrap_UnnamedStruct_something_get unsafe.Pointer + +func _swig_wrap_UnnamedStruct_something_get(base SwigcptrUnnamedStruct) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_UnnamedStruct_something_get, _swig_p) + return +} + +func (arg1 SwigcptrUnnamedStruct) GetSomething() (_swig_ret int) { + return _swig_wrap_UnnamedStruct_something_get(arg1) +} + +var _wrap_UnnamedStruct_m unsafe.Pointer + +func _swig_wrap_UnnamedStruct_m(base SwigcptrUnnamedStruct) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_UnnamedStruct_m, _swig_p) + return +} + +func (arg1 SwigcptrUnnamedStruct) M() { + _swig_wrap_UnnamedStruct_m(arg1) +} + +var _wrap_new_UnnamedStruct unsafe.Pointer + +func _swig_wrap_new_UnnamedStruct() (base SwigcptrUnnamedStruct) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_UnnamedStruct, _swig_p) + return +} + +func NewUnnamedStruct() (_swig_ret UnnamedStruct) { + return _swig_wrap_new_UnnamedStruct() +} + +var _wrap_delete_UnnamedStruct unsafe.Pointer + +func _swig_wrap_delete_UnnamedStruct(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_UnnamedStruct, _swig_p) + return +} + +func DeleteUnnamedStruct(arg1 UnnamedStruct) { + _swig_wrap_delete_UnnamedStruct(arg1.Swigcptr()) +} + +type UnnamedStruct interface { + Swigcptr() uintptr + SwigIsUnnamedStruct() + SetSomething(arg2 int) + GetSomething() (_swig_ret int) + M() +} + +type SwigcptrTypedefNamedStruct uintptr + +func (p SwigcptrTypedefNamedStruct) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrTypedefNamedStruct) SwigIsTypedefNamedStruct() { +} + +var _wrap_TypedefNamedStruct_something_set unsafe.Pointer + +func _swig_wrap_TypedefNamedStruct_something_set(base SwigcptrTypedefNamedStruct, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_TypedefNamedStruct_something_set, _swig_p) + return +} + +func (arg1 SwigcptrTypedefNamedStruct) SetSomething(arg2 int) { + _swig_wrap_TypedefNamedStruct_something_set(arg1, arg2) +} + +var _wrap_TypedefNamedStruct_something_get unsafe.Pointer + +func _swig_wrap_TypedefNamedStruct_something_get(base SwigcptrTypedefNamedStruct) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_TypedefNamedStruct_something_get, _swig_p) + return +} + +func (arg1 SwigcptrTypedefNamedStruct) GetSomething() (_swig_ret int) { + return _swig_wrap_TypedefNamedStruct_something_get(arg1) +} + +var _wrap_TypedefNamedStruct_m unsafe.Pointer + +func _swig_wrap_TypedefNamedStruct_m(base SwigcptrTypedefNamedStruct) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_TypedefNamedStruct_m, _swig_p) + return +} + +func (arg1 SwigcptrTypedefNamedStruct) M() { + _swig_wrap_TypedefNamedStruct_m(arg1) +} + +var _wrap_new_TypedefNamedStruct unsafe.Pointer + +func _swig_wrap_new_TypedefNamedStruct() (base SwigcptrTypedefNamedStruct) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_TypedefNamedStruct, _swig_p) + return +} + +func NewTypedefNamedStruct() (_swig_ret TypedefNamedStruct) { + return _swig_wrap_new_TypedefNamedStruct() +} + +var _wrap_delete_TypedefNamedStruct unsafe.Pointer + +func _swig_wrap_delete_TypedefNamedStruct(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_TypedefNamedStruct, _swig_p) + return +} + +func DeleteTypedefNamedStruct(arg1 TypedefNamedStruct) { + _swig_wrap_delete_TypedefNamedStruct(arg1.Swigcptr()) +} + +type TypedefNamedStruct interface { + Swigcptr() uintptr + SwigIsTypedefNamedStruct() + SetSomething(arg2 int) + GetSomething() (_swig_ret int) + M() +} + +type SwigcptrTest uintptr + +func (p SwigcptrTest) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrTest) SwigIsTest() { +} + +var _wrap_Test_test1 unsafe.Pointer + +func _swig_wrap_Test_test1(base SwigcptrTest, _ uintptr) (_ SwigcptrUnnamedStruct) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Test_test1, _swig_p) + return +} + +func (arg1 SwigcptrTest) Test1(arg2 UnnamedStruct) (_swig_ret UnnamedStruct) { + return _swig_wrap_Test_test1(arg1, arg2.Swigcptr()) +} + +var _wrap_Test_test2 unsafe.Pointer + +func _swig_wrap_Test_test2(base SwigcptrTest, _ uintptr) (_ SwigcptrTypedefNamedStruct) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Test_test2, _swig_p) + return +} + +func (arg1 SwigcptrTest) Test2(arg2 TypedefNamedStruct) (_swig_ret TypedefNamedStruct) { + return _swig_wrap_Test_test2(arg1, arg2.Swigcptr()) +} + +var _wrap_Test_test3 unsafe.Pointer + +func _swig_wrap_Test_test3(base SwigcptrTest, _ uintptr) (_ SwigcptrTypedefNamedStruct) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Test_test3, _swig_p) + return +} + +func (arg1 SwigcptrTest) Test3(arg2 TypedefNamedStruct) (_swig_ret TypedefNamedStruct) { + return _swig_wrap_Test_test3(arg1, arg2.Swigcptr()) +} + +var _wrap_Test_test4 unsafe.Pointer + +func _swig_wrap_Test_test4(base SwigcptrTest, _ uintptr) (_ SwigcptrTypedefNamedStruct) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Test_test4, _swig_p) + return +} + +func (arg1 SwigcptrTest) Test4(arg2 TypedefNamedStruct) (_swig_ret TypedefNamedStruct) { + return _swig_wrap_Test_test4(arg1, arg2.Swigcptr()) +} + +var _wrap_new_Test unsafe.Pointer + +func _swig_wrap_new_Test() (base SwigcptrTest) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Test, _swig_p) + return +} + +func NewTest() (_swig_ret Test) { + return _swig_wrap_new_Test() +} + +var _wrap_delete_Test unsafe.Pointer + +func _swig_wrap_delete_Test(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Test, _swig_p) + return +} + +func DeleteTest(arg1 Test) { + _swig_wrap_delete_Test(arg1.Swigcptr()) +} + +type Test interface { + Swigcptr() uintptr + SwigIsTest() + Test1(arg2 UnnamedStruct) (_swig_ret UnnamedStruct) + Test2(arg2 TypedefNamedStruct) (_swig_ret TypedefNamedStruct) + Test3(arg2 TypedefNamedStruct) (_swig_ret TypedefNamedStruct) + Test4(arg2 TypedefNamedStruct) (_swig_ret TypedefNamedStruct) +} + + +type SwigcptrBar uintptr +type Bar interface { + Swigcptr() uintptr; +} +func (p SwigcptrBar) Swigcptr() uintptr { + return uintptr(p) +} + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/curiously_recurring_template_pattern.go b/Examples/test-suite/go/curiously_recurring_template_pattern.go new file mode 100644 index 000000000..b2e4e8066 --- /dev/null +++ b/Examples/test-suite/go/curiously_recurring_template_pattern.go @@ -0,0 +1,278 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../curiously_recurring_template_pattern.i + +package curiously_recurring_template_pattern + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrBasederived uintptr + +func (p SwigcptrBasederived) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrBasederived) SwigIsBasederived() { +} + +var _wrap_new_basederived unsafe.Pointer + +func _swig_wrap_new_basederived() (base SwigcptrBasederived) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_basederived, _swig_p) + return +} + +func NewBasederived() (_swig_ret Basederived) { + return _swig_wrap_new_basederived() +} + +var _wrap_basederived_getBase1Param unsafe.Pointer + +func _swig_wrap_basederived_getBase1Param(base SwigcptrBasederived) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_basederived_getBase1Param, _swig_p) + return +} + +func (arg1 SwigcptrBasederived) GetBase1Param() (_swig_ret int) { + return _swig_wrap_basederived_getBase1Param(arg1) +} + +var _wrap_basederived_setBase1Param unsafe.Pointer + +func _swig_wrap_basederived_setBase1Param(base SwigcptrBasederived, _ int) (_ SwigcptrDerived) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_basederived_setBase1Param, _swig_p) + return +} + +func (arg1 SwigcptrBasederived) SetBase1Param(arg2 int) (_swig_ret Derived) { + return _swig_wrap_basederived_setBase1Param(arg1, arg2) +} + +var _wrap_basederived_getBase2Param unsafe.Pointer + +func _swig_wrap_basederived_getBase2Param(base SwigcptrBasederived) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_basederived_getBase2Param, _swig_p) + return +} + +func (arg1 SwigcptrBasederived) GetBase2Param() (_swig_ret int) { + return _swig_wrap_basederived_getBase2Param(arg1) +} + +var _wrap_basederived_setBase2Param unsafe.Pointer + +func _swig_wrap_basederived_setBase2Param(base SwigcptrBasederived, _ int) (_ SwigcptrDerived) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_basederived_setBase2Param, _swig_p) + return +} + +func (arg1 SwigcptrBasederived) SetBase2Param(arg2 int) (_swig_ret Derived) { + return _swig_wrap_basederived_setBase2Param(arg1, arg2) +} + +var _wrap_delete_basederived unsafe.Pointer + +func _swig_wrap_delete_basederived(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_basederived, _swig_p) + return +} + +func DeleteBasederived(arg1 Basederived) { + _swig_wrap_delete_basederived(arg1.Swigcptr()) +} + +type Basederived interface { + Swigcptr() uintptr + SwigIsBasederived() + GetBase1Param() (_swig_ret int) + SetBase1Param(arg2 int) (_swig_ret Derived) + GetBase2Param() (_swig_ret int) + SetBase2Param(arg2 int) (_swig_ret Derived) +} + +type SwigcptrDerived uintptr + +func (p SwigcptrDerived) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrDerived) SwigIsDerived() { +} + +var _wrap_new_Derived unsafe.Pointer + +func _swig_wrap_new_Derived() (base SwigcptrDerived) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Derived, _swig_p) + return +} + +func NewDerived() (_swig_ret Derived) { + return _swig_wrap_new_Derived() +} + +var _wrap_Derived_getDerived1Param unsafe.Pointer + +func _swig_wrap_Derived_getDerived1Param(base SwigcptrDerived) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Derived_getDerived1Param, _swig_p) + return +} + +func (arg1 SwigcptrDerived) GetDerived1Param() (_swig_ret int) { + return _swig_wrap_Derived_getDerived1Param(arg1) +} + +var _wrap_Derived_setDerived1Param unsafe.Pointer + +func _swig_wrap_Derived_setDerived1Param(base SwigcptrDerived, _ int) (_ SwigcptrDerived) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Derived_setDerived1Param, _swig_p) + return +} + +func (arg1 SwigcptrDerived) SetDerived1Param(arg2 int) (_swig_ret Derived) { + return _swig_wrap_Derived_setDerived1Param(arg1, arg2) +} + +var _wrap_Derived_getDerived2Param unsafe.Pointer + +func _swig_wrap_Derived_getDerived2Param(base SwigcptrDerived) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Derived_getDerived2Param, _swig_p) + return +} + +func (arg1 SwigcptrDerived) GetDerived2Param() (_swig_ret int) { + return _swig_wrap_Derived_getDerived2Param(arg1) +} + +var _wrap_Derived_setDerived2Param unsafe.Pointer + +func _swig_wrap_Derived_setDerived2Param(base SwigcptrDerived, _ int) (_ SwigcptrDerived) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Derived_setDerived2Param, _swig_p) + return +} + +func (arg1 SwigcptrDerived) SetDerived2Param(arg2 int) (_swig_ret Derived) { + return _swig_wrap_Derived_setDerived2Param(arg1, arg2) +} + +var _wrap_delete_Derived unsafe.Pointer + +func _swig_wrap_delete_Derived(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Derived, _swig_p) + return +} + +func DeleteDerived(arg1 Derived) { + _swig_wrap_delete_Derived(arg1.Swigcptr()) +} + +var _wrap_Derived_getBase1Param unsafe.Pointer + +func _swig_wrap_Derived_getBase1Param(base SwigcptrDerived) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Derived_getBase1Param, _swig_p) + return +} + +func (_swig_base SwigcptrDerived) GetBase1Param() (_swig_ret int) { + return _swig_wrap_Derived_getBase1Param(_swig_base) +} + +var _wrap_Derived_setBase1Param unsafe.Pointer + +func _swig_wrap_Derived_setBase1Param(base SwigcptrDerived, _ int) (_ SwigcptrDerived) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Derived_setBase1Param, _swig_p) + return +} + +func (_swig_base SwigcptrDerived) SetBase1Param(arg1 int) (_swig_ret Derived) { + return _swig_wrap_Derived_setBase1Param(_swig_base, arg1) +} + +var _wrap_Derived_getBase2Param unsafe.Pointer + +func _swig_wrap_Derived_getBase2Param(base SwigcptrDerived) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Derived_getBase2Param, _swig_p) + return +} + +func (_swig_base SwigcptrDerived) GetBase2Param() (_swig_ret int) { + return _swig_wrap_Derived_getBase2Param(_swig_base) +} + +var _wrap_Derived_setBase2Param unsafe.Pointer + +func _swig_wrap_Derived_setBase2Param(base SwigcptrDerived, _ int) (_ SwigcptrDerived) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Derived_setBase2Param, _swig_p) + return +} + +func (_swig_base SwigcptrDerived) SetBase2Param(arg1 int) (_swig_ret Derived) { + return _swig_wrap_Derived_setBase2Param(_swig_base, arg1) +} + +func (p SwigcptrDerived) SwigIsBasederived() { +} + +func (p SwigcptrDerived) SwigGetBasederived() Basederived { + return SwigcptrBasederived(p.Swigcptr()) +} + +type Derived interface { + Swigcptr() uintptr + SwigIsDerived() + GetDerived1Param() (_swig_ret int) + SetDerived1Param(arg2 int) (_swig_ret Derived) + GetDerived2Param() (_swig_ret int) + SetDerived2Param(arg2 int) (_swig_ret Derived) + GetBase1Param() (_swig_ret int) + SetBase1Param(arg1 int) (_swig_ret Derived) + GetBase2Param() (_swig_ret int) + SetBase2Param(arg1 int) (_swig_ret Derived) + SwigIsBasederived() + SwigGetBasederived() Basederived +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/default_arg_values.go b/Examples/test-suite/go/default_arg_values.go new file mode 100644 index 000000000..a87e1f055 --- /dev/null +++ b/Examples/test-suite/go/default_arg_values.go @@ -0,0 +1,154 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../default_arg_values.i + +package default_arg_values + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrDisplay uintptr + +func (p SwigcptrDisplay) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrDisplay) SwigIsDisplay() { +} + +var _wrap_Display_draw1__SWIG_0 unsafe.Pointer + +func _swig_wrap_Display_draw1__SWIG_0(base SwigcptrDisplay, _ float32) (_ float32) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Display_draw1__SWIG_0, _swig_p) + return +} + +func (arg1 SwigcptrDisplay) Draw1__SWIG_0(arg2 float32) (_swig_ret float32) { + return _swig_wrap_Display_draw1__SWIG_0(arg1, arg2) +} + +var _wrap_Display_draw1__SWIG_1 unsafe.Pointer + +func _swig_wrap_Display_draw1__SWIG_1(base SwigcptrDisplay) (_ float32) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Display_draw1__SWIG_1, _swig_p) + return +} + +func (arg1 SwigcptrDisplay) Draw1__SWIG_1() (_swig_ret float32) { + return _swig_wrap_Display_draw1__SWIG_1(arg1) +} + +func (p SwigcptrDisplay) Draw1(a ...interface{}) float32 { + argc := len(a) + if argc == 0 { + return p.Draw1__SWIG_1() + } + if argc == 1 { + return p.Draw1__SWIG_0(a[0].(float32)) + } + panic("No match for overloaded function call") +} + +var _wrap_Display_draw2__SWIG_0 unsafe.Pointer + +func _swig_wrap_Display_draw2__SWIG_0(base SwigcptrDisplay, _ *float32) (_ float32) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Display_draw2__SWIG_0, _swig_p) + return +} + +func (arg1 SwigcptrDisplay) Draw2__SWIG_0(arg2 *float32) (_swig_ret float32) { + return _swig_wrap_Display_draw2__SWIG_0(arg1, arg2) +} + +var _wrap_Display_draw2__SWIG_1 unsafe.Pointer + +func _swig_wrap_Display_draw2__SWIG_1(base SwigcptrDisplay) (_ float32) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Display_draw2__SWIG_1, _swig_p) + return +} + +func (arg1 SwigcptrDisplay) Draw2__SWIG_1() (_swig_ret float32) { + return _swig_wrap_Display_draw2__SWIG_1(arg1) +} + +func (p SwigcptrDisplay) Draw2(a ...interface{}) float32 { + argc := len(a) + if argc == 0 { + return p.Draw2__SWIG_1() + } + if argc == 1 { + return p.Draw2__SWIG_0(a[0].(*float32)) + } + panic("No match for overloaded function call") +} + +var _wrap_new_Display unsafe.Pointer + +func _swig_wrap_new_Display() (base SwigcptrDisplay) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Display, _swig_p) + return +} + +func NewDisplay() (_swig_ret Display) { + return _swig_wrap_new_Display() +} + +var _wrap_delete_Display unsafe.Pointer + +func _swig_wrap_delete_Display(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Display, _swig_p) + return +} + +func DeleteDisplay(arg1 Display) { + _swig_wrap_delete_Display(arg1.Swigcptr()) +} + +type Display interface { + Swigcptr() uintptr + SwigIsDisplay() + Draw1(a ...interface{}) float32 + Draw2(a ...interface{}) float32 +} + +var _wrap_createPtr unsafe.Pointer + +func CreatePtr(arg1 float32) (_swig_ret *float32) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_createPtr, _swig_p) + return +} + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/default_args.go b/Examples/test-suite/go/default_args.go new file mode 100644 index 000000000..8933b5b42 --- /dev/null +++ b/Examples/test-suite/go/default_args.go @@ -0,0 +1,1719 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../default_args.i + +package default_args + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +var _wrap_anonymous__SWIG_0 unsafe.Pointer + +func Anonymous__SWIG_0(arg1 int) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_anonymous__SWIG_0, _swig_p) + return +} +var _wrap_anonymous__SWIG_1 unsafe.Pointer + +func Anonymous__SWIG_1() (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_anonymous__SWIG_1, _swig_p) + return +} +func Anonymous(a ...interface{}) int { + argc := len(a) + if argc == 0 { + return Anonymous__SWIG_1() + } + if argc == 1 { + return Anonymous__SWIG_0(a[0].(int)) + } + panic("No match for overloaded function call") +} + +var _wrap_booltest__SWIG_0 unsafe.Pointer + +func Booltest__SWIG_0(arg1 bool) (_swig_ret bool) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_booltest__SWIG_0, _swig_p) + return +} +var _wrap_booltest__SWIG_1 unsafe.Pointer + +func Booltest__SWIG_1() (_swig_ret bool) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_booltest__SWIG_1, _swig_p) + return +} +func Booltest(a ...interface{}) bool { + argc := len(a) + if argc == 0 { + return Booltest__SWIG_1() + } + if argc == 1 { + return Booltest__SWIG_0(a[0].(bool)) + } + panic("No match for overloaded function call") +} + +type Flavor int +var _wrap_BITTER unsafe.Pointer + +func _swig_getBITTER() (_swig_ret Flavor) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_BITTER, _swig_p) + return +} +var BITTER Flavor = _swig_getBITTER() +var _wrap_SWEET unsafe.Pointer + +func _swig_getSWEET() (_swig_ret Flavor) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_SWEET, _swig_p) + return +} +var SWEET Flavor = _swig_getSWEET() +type SwigcptrEnumClass uintptr + +func (p SwigcptrEnumClass) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrEnumClass) SwigIsEnumClass() { +} + +type EnumClassSpeed int +var _wrap_FAST_EnumClass unsafe.Pointer + +func _swig_getEnumClass_FAST_EnumClass() (_swig_ret EnumClassSpeed) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_FAST_EnumClass, _swig_p) + return +} +var EnumClassFAST EnumClassSpeed = _swig_getEnumClass_FAST_EnumClass() +var _wrap_SLOW_EnumClass unsafe.Pointer + +func _swig_getEnumClass_SLOW_EnumClass() (_swig_ret EnumClassSpeed) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_SLOW_EnumClass, _swig_p) + return +} +var EnumClassSLOW EnumClassSpeed = _swig_getEnumClass_SLOW_EnumClass() +var _wrap_EnumClass_blah__SWIG_0 unsafe.Pointer + +func _swig_wrap_EnumClass_blah__SWIG_0(base SwigcptrEnumClass, _ EnumClassSpeed, _ Flavor) (_ bool) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_EnumClass_blah__SWIG_0, _swig_p) + return +} + +func (arg1 SwigcptrEnumClass) Blah__SWIG_0(arg2 EnumClassSpeed, arg3 Flavor) (_swig_ret bool) { + return _swig_wrap_EnumClass_blah__SWIG_0(arg1, arg2, arg3) +} + +var _wrap_EnumClass_blah__SWIG_1 unsafe.Pointer + +func _swig_wrap_EnumClass_blah__SWIG_1(base SwigcptrEnumClass, _ EnumClassSpeed) (_ bool) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_EnumClass_blah__SWIG_1, _swig_p) + return +} + +func (arg1 SwigcptrEnumClass) Blah__SWIG_1(arg2 EnumClassSpeed) (_swig_ret bool) { + return _swig_wrap_EnumClass_blah__SWIG_1(arg1, arg2) +} + +var _wrap_EnumClass_blah__SWIG_2 unsafe.Pointer + +func _swig_wrap_EnumClass_blah__SWIG_2(base SwigcptrEnumClass) (_ bool) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_EnumClass_blah__SWIG_2, _swig_p) + return +} + +func (arg1 SwigcptrEnumClass) Blah__SWIG_2() (_swig_ret bool) { + return _swig_wrap_EnumClass_blah__SWIG_2(arg1) +} + +func (p SwigcptrEnumClass) Blah(a ...interface{}) bool { + argc := len(a) + if argc == 0 { + return p.Blah__SWIG_2() + } + if argc == 1 { + return p.Blah__SWIG_1(a[0].(EnumClassSpeed)) + } + if argc == 2 { + return p.Blah__SWIG_0(a[0].(EnumClassSpeed), a[1].(Flavor)) + } + panic("No match for overloaded function call") +} + +var _wrap_new_EnumClass unsafe.Pointer + +func _swig_wrap_new_EnumClass() (base SwigcptrEnumClass) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_EnumClass, _swig_p) + return +} + +func NewEnumClass() (_swig_ret EnumClass) { + return _swig_wrap_new_EnumClass() +} + +var _wrap_delete_EnumClass unsafe.Pointer + +func _swig_wrap_delete_EnumClass(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_EnumClass, _swig_p) + return +} + +func DeleteEnumClass(arg1 EnumClass) { + _swig_wrap_delete_EnumClass(arg1.Swigcptr()) +} + +type EnumClass interface { + Swigcptr() uintptr + SwigIsEnumClass() + Blah(a ...interface{}) bool +} + +var _wrap_casts1__SWIG_0 unsafe.Pointer + +func Casts1__SWIG_0(arg1 string) (_swig_ret string) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_casts1__SWIG_0, _swig_p) + return +} +var _wrap_casts1__SWIG_1 unsafe.Pointer + +func Casts1__SWIG_1() (_swig_ret string) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_casts1__SWIG_1, _swig_p) + return +} +func Casts1(a ...interface{}) string { + argc := len(a) + if argc == 0 { + return Casts1__SWIG_1() + } + if argc == 1 { + return Casts1__SWIG_0(a[0].(string)) + } + panic("No match for overloaded function call") +} + +var _wrap_casts2__SWIG_0 unsafe.Pointer + +func Casts2__SWIG_0(arg1 string) (_swig_ret string) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_casts2__SWIG_0, _swig_p) + return +} +var _wrap_casts2__SWIG_1 unsafe.Pointer + +func Casts2__SWIG_1() (_swig_ret string) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_casts2__SWIG_1, _swig_p) + return +} +func Casts2(a ...interface{}) string { + argc := len(a) + if argc == 0 { + return Casts2__SWIG_1() + } + if argc == 1 { + return Casts2__SWIG_0(a[0].(string)) + } + panic("No match for overloaded function call") +} + +var _wrap_chartest1__SWIG_0 unsafe.Pointer + +func Chartest1__SWIG_0(arg1 byte) (_swig_ret byte) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_chartest1__SWIG_0, _swig_p) + return +} +var _wrap_chartest1__SWIG_1 unsafe.Pointer + +func Chartest1__SWIG_1() (_swig_ret byte) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_chartest1__SWIG_1, _swig_p) + return +} +func Chartest1(a ...interface{}) byte { + argc := len(a) + if argc == 0 { + return Chartest1__SWIG_1() + } + if argc == 1 { + return Chartest1__SWIG_0(a[0].(byte)) + } + panic("No match for overloaded function call") +} + +var _wrap_chartest2__SWIG_0 unsafe.Pointer + +func Chartest2__SWIG_0(arg1 byte) (_swig_ret byte) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_chartest2__SWIG_0, _swig_p) + return +} +var _wrap_chartest2__SWIG_1 unsafe.Pointer + +func Chartest2__SWIG_1() (_swig_ret byte) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_chartest2__SWIG_1, _swig_p) + return +} +func Chartest2(a ...interface{}) byte { + argc := len(a) + if argc == 0 { + return Chartest2__SWIG_1() + } + if argc == 1 { + return Chartest2__SWIG_0(a[0].(byte)) + } + panic("No match for overloaded function call") +} + +type ATypeAType int +var _wrap_NoType unsafe.Pointer + +func _swig_getNoType() (_swig_ret ATypeAType) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_NoType, _swig_p) + return +} +var NoType ATypeAType = _swig_getNoType() +var _wrap_dummy__SWIG_0 unsafe.Pointer + +func _swig_wrap_dummy__SWIG_0(base ATypeAType) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_dummy__SWIG_0, _swig_p) + return +} + +func Dummy__SWIG_0(arg1 ATypeAType) { + _swig_wrap_dummy__SWIG_0(arg1) +} + +var _wrap_dummy__SWIG_1 unsafe.Pointer + +func _swig_wrap_dummy__SWIG_1() { + var _swig_p uintptr + _cgo_runtime_cgocall(_wrap_dummy__SWIG_1, _swig_p) + return +} + +func Dummy__SWIG_1() { + _swig_wrap_dummy__SWIG_1() +} + +func Dummy(a ...interface{}) { + argc := len(a) + if argc == 0 { + Dummy__SWIG_1() + return + } + if argc == 1 { + Dummy__SWIG_0(a[0].(ATypeAType)) + return + } + panic("No match for overloaded function call") +} + +var _wrap_CONST_NUM_set unsafe.Pointer + +func _swig_wrap_CONST_NUM_set(base int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_CONST_NUM_set, _swig_p) + return +} + +func SetCONST_NUM(arg1 int) { + _swig_wrap_CONST_NUM_set(arg1) +} + +var _wrap_CONST_NUM_get unsafe.Pointer + +func GetCONST_NUM() (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_CONST_NUM_get, _swig_p) + return +} +var _wrap_afunction__SWIG_0 unsafe.Pointer + +func Afunction__SWIG_0(arg1 int) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_afunction__SWIG_0, _swig_p) + return +} +var _wrap_afunction__SWIG_1 unsafe.Pointer + +func Afunction__SWIG_1() (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_afunction__SWIG_1, _swig_p) + return +} +func Afunction(a ...interface{}) int { + argc := len(a) + if argc == 0 { + return Afunction__SWIG_1() + } + if argc == 1 { + return Afunction__SWIG_0(a[0].(int)) + } + panic("No match for overloaded function call") +} + +var _wrap_reftest1__SWIG_0 unsafe.Pointer + +func Reftest1__SWIG_0(arg1 int) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_reftest1__SWIG_0, _swig_p) + return +} +var _wrap_reftest1__SWIG_1 unsafe.Pointer + +func Reftest1__SWIG_1() (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_reftest1__SWIG_1, _swig_p) + return +} +func Reftest1(a ...interface{}) int { + argc := len(a) + if argc == 0 { + return Reftest1__SWIG_1() + } + if argc == 1 { + return Reftest1__SWIG_0(a[0].(int)) + } + panic("No match for overloaded function call") +} + +var _wrap_reftest2__SWIG_0 unsafe.Pointer + +func Reftest2__SWIG_0(arg1 string) (_swig_ret string) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_reftest2__SWIG_0, _swig_p) + return +} +var _wrap_reftest2__SWIG_1 unsafe.Pointer + +func Reftest2__SWIG_1() (_swig_ret string) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_reftest2__SWIG_1, _swig_p) + return +} +func Reftest2(a ...interface{}) string { + argc := len(a) + if argc == 0 { + return Reftest2__SWIG_1() + } + if argc == 1 { + return Reftest2__SWIG_0(a[0].(string)) + } + panic("No match for overloaded function call") +} + +type SwigcptrTree uintptr + +func (p SwigcptrTree) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrTree) SwigIsTree() { +} + +type TreeTypes int +var _wrap_Oak_Tree unsafe.Pointer + +func _swig_getTree_Oak_Tree() (_swig_ret TreeTypes) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_Oak_Tree, _swig_p) + return +} +var TreeOak TreeTypes = _swig_getTree_Oak_Tree() +var _wrap_Fir_Tree unsafe.Pointer + +func _swig_getTree_Fir_Tree() (_swig_ret TreeTypes) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_Fir_Tree, _swig_p) + return +} +var TreeFir TreeTypes = _swig_getTree_Fir_Tree() +var _wrap_Cedar_Tree unsafe.Pointer + +func _swig_getTree_Cedar_Tree() (_swig_ret TreeTypes) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_Cedar_Tree, _swig_p) + return +} +var TreeCedar TreeTypes = _swig_getTree_Cedar_Tree() +var _wrap_Tree_chops unsafe.Pointer + +func _swig_wrap_Tree_chops(base SwigcptrTree, _ TreeTypes) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Tree_chops, _swig_p) + return +} + +func (arg1 SwigcptrTree) Chops(arg2 TreeTypes) { + _swig_wrap_Tree_chops(arg1, arg2) +} + +var _wrap_Tree_test__SWIG_0 unsafe.Pointer + +func _swig_wrap_Tree_test__SWIG_0(base SwigcptrTree, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Tree_test__SWIG_0, _swig_p) + return +} + +func (arg1 SwigcptrTree) Test__SWIG_0(arg2 int) { + _swig_wrap_Tree_test__SWIG_0(arg1, arg2) +} + +var _wrap_Tree_test__SWIG_1 unsafe.Pointer + +func _swig_wrap_Tree_test__SWIG_1(base SwigcptrTree) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Tree_test__SWIG_1, _swig_p) + return +} + +func (arg1 SwigcptrTree) Test__SWIG_1() { + _swig_wrap_Tree_test__SWIG_1(arg1) +} + +func (p SwigcptrTree) Test(a ...interface{}) { + argc := len(a) + if argc == 0 { + p.Test__SWIG_1() + return + } + if argc == 1 { + p.Test__SWIG_0(a[0].(int)) + return + } + panic("No match for overloaded function call") +} + +var _wrap_new_Tree unsafe.Pointer + +func _swig_wrap_new_Tree() (base SwigcptrTree) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Tree, _swig_p) + return +} + +func NewTree() (_swig_ret Tree) { + return _swig_wrap_new_Tree() +} + +var _wrap_delete_Tree unsafe.Pointer + +func _swig_wrap_delete_Tree(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Tree, _swig_p) + return +} + +func DeleteTree(arg1 Tree) { + _swig_wrap_delete_Tree(arg1.Swigcptr()) +} + +type Tree interface { + Swigcptr() uintptr + SwigIsTree() + Chops(arg2 TreeTypes) + Test(a ...interface{}) +} + +var _wrap_chops unsafe.Pointer + +func Chops(arg1 TreeTypes) (_swig_ret TreeTypes) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_chops, _swig_p) + return +} +type SwigcptrFoo uintptr + +func (p SwigcptrFoo) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrFoo) SwigIsFoo() { +} + +var _wrap_Foo_bar2_set unsafe.Pointer + +func _swig_wrap_Foo_bar2_set(base int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_bar2_set, _swig_p) + return +} + +func SetFooBar2(arg1 int) { + _swig_wrap_Foo_bar2_set(arg1) +} + +var _wrap_Foo_bar2_get unsafe.Pointer + +func GetFooBar2() (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_Foo_bar2_get, _swig_p) + return +} +var _wrap_Foo_spam_set unsafe.Pointer + +func _swig_wrap_Foo_spam_set(base int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_spam_set, _swig_p) + return +} + +func SetFooSpam(arg1 int) { + _swig_wrap_Foo_spam_set(arg1) +} + +var _wrap_Foo_spam_get unsafe.Pointer + +func GetFooSpam() (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_Foo_spam_get, _swig_p) + return +} +var _wrap_new_Foo unsafe.Pointer + +func _swig_wrap_new_Foo() (base SwigcptrFoo) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Foo, _swig_p) + return +} + +func NewFoo() (_swig_ret Foo) { + return _swig_wrap_new_Foo() +} + +var _wrap_Foo_method1__SWIG_0 unsafe.Pointer + +func _swig_wrap_Foo_method1__SWIG_0(base SwigcptrFoo, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_method1__SWIG_0, _swig_p) + return +} + +func (arg1 SwigcptrFoo) Method1__SWIG_0(arg2 int) { + _swig_wrap_Foo_method1__SWIG_0(arg1, arg2) +} + +var _wrap_Foo_method1__SWIG_1 unsafe.Pointer + +func _swig_wrap_Foo_method1__SWIG_1(base SwigcptrFoo) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_method1__SWIG_1, _swig_p) + return +} + +func (arg1 SwigcptrFoo) Method1__SWIG_1() { + _swig_wrap_Foo_method1__SWIG_1(arg1) +} + +func (p SwigcptrFoo) Method1(a ...interface{}) { + argc := len(a) + if argc == 0 { + p.Method1__SWIG_1() + return + } + if argc == 1 { + p.Method1__SWIG_0(a[0].(int)) + return + } + panic("No match for overloaded function call") +} + +var _wrap_Foo_method2__SWIG_0 unsafe.Pointer + +func _swig_wrap_Foo_method2__SWIG_0(base SwigcptrFoo, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_method2__SWIG_0, _swig_p) + return +} + +func (arg1 SwigcptrFoo) Method2__SWIG_0(arg2 int) { + _swig_wrap_Foo_method2__SWIG_0(arg1, arg2) +} + +var _wrap_Foo_method2__SWIG_1 unsafe.Pointer + +func _swig_wrap_Foo_method2__SWIG_1(base SwigcptrFoo) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_method2__SWIG_1, _swig_p) + return +} + +func (arg1 SwigcptrFoo) Method2__SWIG_1() { + _swig_wrap_Foo_method2__SWIG_1(arg1) +} + +func (p SwigcptrFoo) Method2(a ...interface{}) { + argc := len(a) + if argc == 0 { + p.Method2__SWIG_1() + return + } + if argc == 1 { + p.Method2__SWIG_0(a[0].(int)) + return + } + panic("No match for overloaded function call") +} + +var _wrap_Foo_newname__SWIG_0 unsafe.Pointer + +func _swig_wrap_Foo_newname__SWIG_0(base SwigcptrFoo, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_newname__SWIG_0, _swig_p) + return +} + +func (arg1 SwigcptrFoo) Newname__SWIG_0(arg2 int) { + _swig_wrap_Foo_newname__SWIG_0(arg1, arg2) +} + +var _wrap_Foo_newname__SWIG_1 unsafe.Pointer + +func _swig_wrap_Foo_newname__SWIG_1(base SwigcptrFoo) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_newname__SWIG_1, _swig_p) + return +} + +func (arg1 SwigcptrFoo) Newname__SWIG_1() { + _swig_wrap_Foo_newname__SWIG_1(arg1) +} + +func (p SwigcptrFoo) Newname(a ...interface{}) { + argc := len(a) + if argc == 0 { + p.Newname__SWIG_1() + return + } + if argc == 1 { + p.Newname__SWIG_0(a[0].(int)) + return + } + panic("No match for overloaded function call") +} + +var _wrap_Foo_renamed3arg unsafe.Pointer + +func _swig_wrap_Foo_renamed3arg(base SwigcptrFoo, _ int, _ float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_renamed3arg, _swig_p) + return +} + +func (arg1 SwigcptrFoo) Renamed3arg(arg2 int, arg3 float64) { + _swig_wrap_Foo_renamed3arg(arg1, arg2, arg3) +} + +var _wrap_Foo_renamed2arg unsafe.Pointer + +func _swig_wrap_Foo_renamed2arg(base SwigcptrFoo, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_renamed2arg, _swig_p) + return +} + +func (arg1 SwigcptrFoo) Renamed2arg(arg2 int) { + _swig_wrap_Foo_renamed2arg(arg1, arg2) +} + +var _wrap_Foo_renamed1arg unsafe.Pointer + +func _swig_wrap_Foo_renamed1arg(base SwigcptrFoo) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_renamed1arg, _swig_p) + return +} + +func (arg1 SwigcptrFoo) Renamed1arg() { + _swig_wrap_Foo_renamed1arg(arg1) +} + +var _wrap_delete_Foo unsafe.Pointer + +func _swig_wrap_delete_Foo(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Foo, _swig_p) + return +} + +func DeleteFoo(arg1 Foo) { + _swig_wrap_delete_Foo(arg1.Swigcptr()) +} + +type Foo interface { + Swigcptr() uintptr + SwigIsFoo() + Method1(a ...interface{}) + Method2(a ...interface{}) + Newname(a ...interface{}) + Renamed3arg(arg2 int, arg3 float64) + Renamed2arg(arg2 int) + Renamed1arg() +} + +type MyType int +var _wrap_Val1 unsafe.Pointer + +func _swig_getVal1() (_swig_ret MyType) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_Val1, _swig_p) + return +} +var Val1 MyType = _swig_getVal1() +var _wrap_Val2 unsafe.Pointer + +func _swig_getVal2() (_swig_ret MyType) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_Val2, _swig_p) + return +} +var Val2 MyType = _swig_getVal2() +type SwigcptrMyClass1 uintptr + +func (p SwigcptrMyClass1) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrMyClass1) SwigIsMyClass1() { +} + +var _wrap_new_MyClass1 unsafe.Pointer + +func _swig_wrap_new_MyClass1(base MyType) (_ SwigcptrMyClass1) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_MyClass1, _swig_p) + return +} + +func NewMyClass1(arg1 MyType) (_swig_ret MyClass1) { + return _swig_wrap_new_MyClass1(arg1) +} + +var _wrap_delete_MyClass1 unsafe.Pointer + +func _swig_wrap_delete_MyClass1(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_MyClass1, _swig_p) + return +} + +func DeleteMyClass1(arg1 MyClass1) { + _swig_wrap_delete_MyClass1(arg1.Swigcptr()) +} + +type MyClass1 interface { + Swigcptr() uintptr + SwigIsMyClass1() +} + +type SwigcptrMyClass2 uintptr + +func (p SwigcptrMyClass2) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrMyClass2) SwigIsMyClass2() { +} + +var _wrap_MyClass2_set unsafe.Pointer + +func _swig_wrap_MyClass2_set(base int, _ SwigcptrMyClass2, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_MyClass2_set, _swig_p) + return +} + +func (arg1 SwigcptrMyClass2) Set(_swig_args ...interface{}) { + var arg2 MyClass1 + if len(_swig_args) > 0 { + arg2 = _swig_args[0].(MyClass1) + } + _swig_wrap_MyClass2_set(len(_swig_args), arg1, arg2.Swigcptr()) +} + +var _wrap_MyClass2_set2__SWIG_0 unsafe.Pointer + +func _swig_wrap_MyClass2_set2__SWIG_0(base SwigcptrMyClass2, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_MyClass2_set2__SWIG_0, _swig_p) + return +} + +func (arg1 SwigcptrMyClass2) Set2__SWIG_0(arg2 MyClass1) { + _swig_wrap_MyClass2_set2__SWIG_0(arg1, arg2.Swigcptr()) +} + +var _wrap_MyClass2_set2__SWIG_1 unsafe.Pointer + +func _swig_wrap_MyClass2_set2__SWIG_1(base SwigcptrMyClass2) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_MyClass2_set2__SWIG_1, _swig_p) + return +} + +func (arg1 SwigcptrMyClass2) Set2__SWIG_1() { + _swig_wrap_MyClass2_set2__SWIG_1(arg1) +} + +func (p SwigcptrMyClass2) Set2(a ...interface{}) { + argc := len(a) + if argc == 0 { + p.Set2__SWIG_1() + return + } + if argc == 1 { + p.Set2__SWIG_0(a[0].(MyClass1)) + return + } + panic("No match for overloaded function call") +} + +var _wrap_new_MyClass2 unsafe.Pointer + +func _swig_wrap_new_MyClass2() (base SwigcptrMyClass2) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_MyClass2, _swig_p) + return +} + +func NewMyClass2() (_swig_ret MyClass2) { + return _swig_wrap_new_MyClass2() +} + +var _wrap_delete_MyClass2 unsafe.Pointer + +func _swig_wrap_delete_MyClass2(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_MyClass2, _swig_p) + return +} + +func DeleteMyClass2(arg1 MyClass2) { + _swig_wrap_delete_MyClass2(arg1.Swigcptr()) +} + +type MyClass2 interface { + Swigcptr() uintptr + SwigIsMyClass2() + Set(_swig_args ...interface{}) + Set2(a ...interface{}) +} + +var _wrap_exceptionspec__SWIG_0 unsafe.Pointer + +func _swig_wrap_exceptionspec__SWIG_0(base int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_exceptionspec__SWIG_0, _swig_p) + return +} + +func Exceptionspec__SWIG_0(arg1 int) { + _swig_wrap_exceptionspec__SWIG_0(arg1) +} + +var _wrap_exceptionspec__SWIG_1 unsafe.Pointer + +func _swig_wrap_exceptionspec__SWIG_1() { + var _swig_p uintptr + _cgo_runtime_cgocall(_wrap_exceptionspec__SWIG_1, _swig_p) + return +} + +func Exceptionspec__SWIG_1() { + _swig_wrap_exceptionspec__SWIG_1() +} + +func Exceptionspec(a ...interface{}) { + argc := len(a) + if argc == 0 { + Exceptionspec__SWIG_1() + return + } + if argc == 1 { + Exceptionspec__SWIG_0(a[0].(int)) + return + } + panic("No match for overloaded function call") +} + +type SwigcptrExcept uintptr + +func (p SwigcptrExcept) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrExcept) SwigIsExcept() { +} + +var _wrap_new_Except__SWIG_0 unsafe.Pointer + +func _swig_wrap_new_Except__SWIG_0(base bool, _ int) (_ SwigcptrExcept) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Except__SWIG_0, _swig_p) + return +} + +func NewExcept__SWIG_0(arg1 bool, arg2 int) (_swig_ret Except) { + return _swig_wrap_new_Except__SWIG_0(arg1, arg2) +} + +var _wrap_new_Except__SWIG_1 unsafe.Pointer + +func _swig_wrap_new_Except__SWIG_1(base bool) (_ SwigcptrExcept) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Except__SWIG_1, _swig_p) + return +} + +func NewExcept__SWIG_1(arg1 bool) (_swig_ret Except) { + return _swig_wrap_new_Except__SWIG_1(arg1) +} + +func NewExcept(a ...interface{}) Except { + argc := len(a) + if argc == 1 { + return NewExcept__SWIG_1(a[0].(bool)) + } + if argc == 2 { + return NewExcept__SWIG_0(a[0].(bool), a[1].(int)) + } + panic("No match for overloaded function call") +} + +var _wrap_Except_exspec__SWIG_0 unsafe.Pointer + +func _swig_wrap_Except_exspec__SWIG_0(base SwigcptrExcept, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Except_exspec__SWIG_0, _swig_p) + return +} + +func (arg1 SwigcptrExcept) Exspec__SWIG_0(arg2 int) { + _swig_wrap_Except_exspec__SWIG_0(arg1, arg2) +} + +var _wrap_Except_exspec__SWIG_1 unsafe.Pointer + +func _swig_wrap_Except_exspec__SWIG_1(base SwigcptrExcept) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Except_exspec__SWIG_1, _swig_p) + return +} + +func (arg1 SwigcptrExcept) Exspec__SWIG_1() { + _swig_wrap_Except_exspec__SWIG_1(arg1) +} + +func (p SwigcptrExcept) Exspec(a ...interface{}) { + argc := len(a) + if argc == 0 { + p.Exspec__SWIG_1() + return + } + if argc == 1 { + p.Exspec__SWIG_0(a[0].(int)) + return + } + panic("No match for overloaded function call") +} + +var _wrap_delete_Except unsafe.Pointer + +func _swig_wrap_delete_Except(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Except, _swig_p) + return +} + +func DeleteExcept(arg1 Except) { + _swig_wrap_delete_Except(arg1.Swigcptr()) +} + +type Except interface { + Swigcptr() uintptr + SwigIsExcept() + Exspec(a ...interface{}) +} + +type SwigcptrStatics uintptr + +func (p SwigcptrStatics) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrStatics) SwigIsStatics() { +} + +var _wrap_Statics_staticmethod__SWIG_0 unsafe.Pointer + +func StaticsStaticmethod__SWIG_0(arg1 int, arg2 int, arg3 int) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_Statics_staticmethod__SWIG_0, _swig_p) + return +} +var _wrap_Statics_staticmethod__SWIG_1 unsafe.Pointer + +func StaticsStaticmethod__SWIG_1(arg1 int, arg2 int) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_Statics_staticmethod__SWIG_1, _swig_p) + return +} +var _wrap_Statics_staticmethod__SWIG_2 unsafe.Pointer + +func StaticsStaticmethod__SWIG_2(arg1 int) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_Statics_staticmethod__SWIG_2, _swig_p) + return +} +var _wrap_Statics_staticmethod__SWIG_3 unsafe.Pointer + +func StaticsStaticmethod__SWIG_3() (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_Statics_staticmethod__SWIG_3, _swig_p) + return +} +func StaticsStaticmethod(a ...interface{}) int { + argc := len(a) + if argc == 0 { + return StaticsStaticmethod__SWIG_3() + } + if argc == 1 { + return StaticsStaticmethod__SWIG_2(a[0].(int)) + } + if argc == 2 { + return StaticsStaticmethod__SWIG_1(a[0].(int), a[1].(int)) + } + if argc == 3 { + return StaticsStaticmethod__SWIG_0(a[0].(int), a[1].(int), a[2].(int)) + } + panic("No match for overloaded function call") +} + +var _wrap_new_Statics unsafe.Pointer + +func _swig_wrap_new_Statics() (base SwigcptrStatics) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Statics, _swig_p) + return +} + +func NewStatics() (_swig_ret Statics) { + return _swig_wrap_new_Statics() +} + +var _wrap_delete_Statics unsafe.Pointer + +func _swig_wrap_delete_Statics(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Statics, _swig_p) + return +} + +func DeleteStatics(arg1 Statics) { + _swig_wrap_delete_Statics(arg1.Swigcptr()) +} + +type Statics interface { + Swigcptr() uintptr + SwigIsStatics() +} + +type SwigcptrTricky uintptr + +func (p SwigcptrTricky) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrTricky) SwigIsTricky() { +} + +var _wrap_Tricky_privatedefault__SWIG_0 unsafe.Pointer + +func _swig_wrap_Tricky_privatedefault__SWIG_0(base SwigcptrTricky, _ int) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Tricky_privatedefault__SWIG_0, _swig_p) + return +} + +func (arg1 SwigcptrTricky) Privatedefault__SWIG_0(arg2 int) (_swig_ret int) { + return _swig_wrap_Tricky_privatedefault__SWIG_0(arg1, arg2) +} + +var _wrap_Tricky_privatedefault__SWIG_1 unsafe.Pointer + +func _swig_wrap_Tricky_privatedefault__SWIG_1(base SwigcptrTricky) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Tricky_privatedefault__SWIG_1, _swig_p) + return +} + +func (arg1 SwigcptrTricky) Privatedefault__SWIG_1() (_swig_ret int) { + return _swig_wrap_Tricky_privatedefault__SWIG_1(arg1) +} + +func (p SwigcptrTricky) Privatedefault(a ...interface{}) int { + argc := len(a) + if argc == 0 { + return p.Privatedefault__SWIG_1() + } + if argc == 1 { + return p.Privatedefault__SWIG_0(a[0].(int)) + } + panic("No match for overloaded function call") +} + +var _wrap_Tricky_protectedint__SWIG_0 unsafe.Pointer + +func _swig_wrap_Tricky_protectedint__SWIG_0(base SwigcptrTricky, _ int) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Tricky_protectedint__SWIG_0, _swig_p) + return +} + +func (arg1 SwigcptrTricky) Protectedint__SWIG_0(arg2 int) (_swig_ret int) { + return _swig_wrap_Tricky_protectedint__SWIG_0(arg1, arg2) +} + +var _wrap_Tricky_protectedint__SWIG_1 unsafe.Pointer + +func _swig_wrap_Tricky_protectedint__SWIG_1(base SwigcptrTricky) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Tricky_protectedint__SWIG_1, _swig_p) + return +} + +func (arg1 SwigcptrTricky) Protectedint__SWIG_1() (_swig_ret int) { + return _swig_wrap_Tricky_protectedint__SWIG_1(arg1) +} + +func (p SwigcptrTricky) Protectedint(a ...interface{}) int { + argc := len(a) + if argc == 0 { + return p.Protectedint__SWIG_1() + } + if argc == 1 { + return p.Protectedint__SWIG_0(a[0].(int)) + } + panic("No match for overloaded function call") +} + +var _wrap_Tricky_protecteddouble__SWIG_0 unsafe.Pointer + +func _swig_wrap_Tricky_protecteddouble__SWIG_0(base SwigcptrTricky, _ float64) (_ float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Tricky_protecteddouble__SWIG_0, _swig_p) + return +} + +func (arg1 SwigcptrTricky) Protecteddouble__SWIG_0(arg2 float64) (_swig_ret float64) { + return _swig_wrap_Tricky_protecteddouble__SWIG_0(arg1, arg2) +} + +var _wrap_Tricky_protecteddouble__SWIG_1 unsafe.Pointer + +func _swig_wrap_Tricky_protecteddouble__SWIG_1(base SwigcptrTricky) (_ float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Tricky_protecteddouble__SWIG_1, _swig_p) + return +} + +func (arg1 SwigcptrTricky) Protecteddouble__SWIG_1() (_swig_ret float64) { + return _swig_wrap_Tricky_protecteddouble__SWIG_1(arg1) +} + +func (p SwigcptrTricky) Protecteddouble(a ...interface{}) float64 { + argc := len(a) + if argc == 0 { + return p.Protecteddouble__SWIG_1() + } + if argc == 1 { + return p.Protecteddouble__SWIG_0(a[0].(float64)) + } + panic("No match for overloaded function call") +} + +var _wrap_Tricky_functiondefault__SWIG_0 unsafe.Pointer + +func _swig_wrap_Tricky_functiondefault__SWIG_0(base SwigcptrTricky, _ int) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Tricky_functiondefault__SWIG_0, _swig_p) + return +} + +func (arg1 SwigcptrTricky) Functiondefault__SWIG_0(arg2 int) (_swig_ret int) { + return _swig_wrap_Tricky_functiondefault__SWIG_0(arg1, arg2) +} + +var _wrap_Tricky_functiondefault__SWIG_1 unsafe.Pointer + +func _swig_wrap_Tricky_functiondefault__SWIG_1(base SwigcptrTricky) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Tricky_functiondefault__SWIG_1, _swig_p) + return +} + +func (arg1 SwigcptrTricky) Functiondefault__SWIG_1() (_swig_ret int) { + return _swig_wrap_Tricky_functiondefault__SWIG_1(arg1) +} + +func (p SwigcptrTricky) Functiondefault(a ...interface{}) int { + argc := len(a) + if argc == 0 { + return p.Functiondefault__SWIG_1() + } + if argc == 1 { + return p.Functiondefault__SWIG_0(a[0].(int)) + } + panic("No match for overloaded function call") +} + +var _wrap_Tricky_contrived__SWIG_0 unsafe.Pointer + +func _swig_wrap_Tricky_contrived__SWIG_0(base SwigcptrTricky, _ string) (_ byte) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Tricky_contrived__SWIG_0, _swig_p) + return +} + +func (arg1 SwigcptrTricky) Contrived__SWIG_0(arg2 string) (_swig_ret byte) { + return _swig_wrap_Tricky_contrived__SWIG_0(arg1, arg2) +} + +var _wrap_Tricky_contrived__SWIG_1 unsafe.Pointer + +func _swig_wrap_Tricky_contrived__SWIG_1(base SwigcptrTricky) (_ byte) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Tricky_contrived__SWIG_1, _swig_p) + return +} + +func (arg1 SwigcptrTricky) Contrived__SWIG_1() (_swig_ret byte) { + return _swig_wrap_Tricky_contrived__SWIG_1(arg1) +} + +func (p SwigcptrTricky) Contrived(a ...interface{}) byte { + argc := len(a) + if argc == 0 { + return p.Contrived__SWIG_1() + } + if argc == 1 { + return p.Contrived__SWIG_0(a[0].(string)) + } + panic("No match for overloaded function call") +} + +var _wrap_new_Tricky unsafe.Pointer + +func _swig_wrap_new_Tricky() (base SwigcptrTricky) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Tricky, _swig_p) + return +} + +func NewTricky() (_swig_ret Tricky) { + return _swig_wrap_new_Tricky() +} + +var _wrap_delete_Tricky unsafe.Pointer + +func _swig_wrap_delete_Tricky(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Tricky, _swig_p) + return +} + +func DeleteTricky(arg1 Tricky) { + _swig_wrap_delete_Tricky(arg1.Swigcptr()) +} + +type Tricky interface { + Swigcptr() uintptr + SwigIsTricky() + Privatedefault(a ...interface{}) int + Protectedint(a ...interface{}) int + Protecteddouble(a ...interface{}) float64 + Functiondefault(a ...interface{}) int + Contrived(a ...interface{}) byte +} + +type SwigcptrKlass uintptr + +func (p SwigcptrKlass) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrKlass) SwigIsKlass() { +} + +var _wrap_Klass_val_set unsafe.Pointer + +func _swig_wrap_Klass_val_set(base SwigcptrKlass, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Klass_val_set, _swig_p) + return +} + +func (arg1 SwigcptrKlass) SetVal(arg2 int) { + _swig_wrap_Klass_val_set(arg1, arg2) +} + +var _wrap_Klass_val_get unsafe.Pointer + +func _swig_wrap_Klass_val_get(base SwigcptrKlass) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Klass_val_get, _swig_p) + return +} + +func (arg1 SwigcptrKlass) GetVal() (_swig_ret int) { + return _swig_wrap_Klass_val_get(arg1) +} + +var _wrap_new_Klass__SWIG_0 unsafe.Pointer + +func _swig_wrap_new_Klass__SWIG_0(base int) (_ SwigcptrKlass) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Klass__SWIG_0, _swig_p) + return +} + +func NewKlass__SWIG_0(arg1 int) (_swig_ret Klass) { + return _swig_wrap_new_Klass__SWIG_0(arg1) +} + +var _wrap_new_Klass__SWIG_1 unsafe.Pointer + +func _swig_wrap_new_Klass__SWIG_1() (base SwigcptrKlass) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Klass__SWIG_1, _swig_p) + return +} + +func NewKlass__SWIG_1() (_swig_ret Klass) { + return _swig_wrap_new_Klass__SWIG_1() +} + +func NewKlass(a ...interface{}) Klass { + argc := len(a) + if argc == 0 { + return NewKlass__SWIG_1() + } + if argc == 1 { + return NewKlass__SWIG_0(a[0].(int)) + } + panic("No match for overloaded function call") +} + +var _wrap_delete_Klass unsafe.Pointer + +func _swig_wrap_delete_Klass(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Klass, _swig_p) + return +} + +func DeleteKlass(arg1 Klass) { + _swig_wrap_delete_Klass(arg1.Swigcptr()) +} + +type Klass interface { + Swigcptr() uintptr + SwigIsKlass() + SetVal(arg2 int) + GetVal() (_swig_ret int) +} + +var _wrap_constructorcall__SWIG_0 unsafe.Pointer + +func _swig_wrap_constructorcall__SWIG_0(base uintptr) (_ SwigcptrKlass) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_constructorcall__SWIG_0, _swig_p) + return +} + +func Constructorcall__SWIG_0(arg1 Klass) (_swig_ret Klass) { + return _swig_wrap_constructorcall__SWIG_0(arg1.Swigcptr()) +} + +var _wrap_constructorcall__SWIG_1 unsafe.Pointer + +func _swig_wrap_constructorcall__SWIG_1() (base SwigcptrKlass) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_constructorcall__SWIG_1, _swig_p) + return +} + +func Constructorcall__SWIG_1() (_swig_ret Klass) { + return _swig_wrap_constructorcall__SWIG_1() +} + +func Constructorcall(a ...interface{}) Klass { + argc := len(a) + if argc == 0 { + return Constructorcall__SWIG_1() + } + if argc == 1 { + return Constructorcall__SWIG_0(a[0].(Klass)) + } + panic("No match for overloaded function call") +} + +type SwigcptrConstMethods uintptr + +func (p SwigcptrConstMethods) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrConstMethods) SwigIsConstMethods() { +} + +var _wrap_ConstMethods_coo__SWIG_0 unsafe.Pointer + +func _swig_wrap_ConstMethods_coo__SWIG_0(base SwigcptrConstMethods, _ float64) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_ConstMethods_coo__SWIG_0, _swig_p) + return +} + +func (arg1 SwigcptrConstMethods) Coo__SWIG_0(arg2 float64) (_swig_ret int) { + return _swig_wrap_ConstMethods_coo__SWIG_0(arg1, arg2) +} + +var _wrap_ConstMethods_coo__SWIG_1 unsafe.Pointer + +func _swig_wrap_ConstMethods_coo__SWIG_1(base SwigcptrConstMethods) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_ConstMethods_coo__SWIG_1, _swig_p) + return +} + +func (arg1 SwigcptrConstMethods) Coo__SWIG_1() (_swig_ret int) { + return _swig_wrap_ConstMethods_coo__SWIG_1(arg1) +} + +func (p SwigcptrConstMethods) Coo(a ...interface{}) int { + argc := len(a) + if argc == 0 { + return p.Coo__SWIG_1() + } + if argc == 1 { + return p.Coo__SWIG_0(a[0].(float64)) + } + panic("No match for overloaded function call") +} + +var _wrap_new_ConstMethods unsafe.Pointer + +func _swig_wrap_new_ConstMethods() (base SwigcptrConstMethods) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_ConstMethods, _swig_p) + return +} + +func NewConstMethods() (_swig_ret ConstMethods) { + return _swig_wrap_new_ConstMethods() +} + +var _wrap_delete_ConstMethods unsafe.Pointer + +func _swig_wrap_delete_ConstMethods(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_ConstMethods, _swig_p) + return +} + +func DeleteConstMethods(arg1 ConstMethods) { + _swig_wrap_delete_ConstMethods(arg1.Swigcptr()) +} + +type ConstMethods interface { + Swigcptr() uintptr + SwigIsConstMethods() + Coo(a ...interface{}) int +} + +var _wrap_cfunc1 unsafe.Pointer + +func _swig_wrap_cfunc1(base int, _ float64, _ float64) (_ float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_cfunc1, _swig_p) + return +} + +func Cfunc1(arg1 float64, _swig_args ...interface{}) (_swig_ret float64) { + var arg2 float64 + if len(_swig_args) > 0 { + arg2 = _swig_args[0].(float64) + } + return _swig_wrap_cfunc1(len(_swig_args), arg1, arg2) +} + +var _wrap_cfunc2 unsafe.Pointer + +func _swig_wrap_cfunc2(base int, _ float64, _ float64) (_ float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_cfunc2, _swig_p) + return +} + +func Cfunc2(arg1 float64, _swig_args ...interface{}) (_swig_ret float64) { + var arg2 float64 + if len(_swig_args) > 0 { + arg2 = _swig_args[0].(float64) + } + return _swig_wrap_cfunc2(len(_swig_args), arg1, arg2) +} + +var _wrap_cfunc3 unsafe.Pointer + +func _swig_wrap_cfunc3(base int, _ float64, _ float64) (_ float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_cfunc3, _swig_p) + return +} + +func Cfunc3(arg1 float64, _swig_args ...interface{}) (_swig_ret float64) { + var arg2 float64 + if len(_swig_args) > 0 { + arg2 = _swig_args[0].(float64) + } + return _swig_wrap_cfunc3(len(_swig_args), arg1, arg2) +} + +type SwigcptrPointf uintptr + +func (p SwigcptrPointf) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrPointf) SwigIsPointf() { +} + +var _wrap_Pointf_x_set unsafe.Pointer + +func _swig_wrap_Pointf_x_set(base SwigcptrPointf, _ float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Pointf_x_set, _swig_p) + return +} + +func (arg1 SwigcptrPointf) SetX(arg2 float64) { + _swig_wrap_Pointf_x_set(arg1, arg2) +} + +var _wrap_Pointf_x_get unsafe.Pointer + +func _swig_wrap_Pointf_x_get(base SwigcptrPointf) (_ float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Pointf_x_get, _swig_p) + return +} + +func (arg1 SwigcptrPointf) GetX() (_swig_ret float64) { + return _swig_wrap_Pointf_x_get(arg1) +} + +var _wrap_Pointf_y_set unsafe.Pointer + +func _swig_wrap_Pointf_y_set(base SwigcptrPointf, _ float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Pointf_y_set, _swig_p) + return +} + +func (arg1 SwigcptrPointf) SetY(arg2 float64) { + _swig_wrap_Pointf_y_set(arg1, arg2) +} + +var _wrap_Pointf_y_get unsafe.Pointer + +func _swig_wrap_Pointf_y_get(base SwigcptrPointf) (_ float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Pointf_y_get, _swig_p) + return +} + +func (arg1 SwigcptrPointf) GetY() (_swig_ret float64) { + return _swig_wrap_Pointf_y_get(arg1) +} + +var _wrap_new_Pointf unsafe.Pointer + +func _swig_wrap_new_Pointf() (base SwigcptrPointf) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Pointf, _swig_p) + return +} + +func NewPointf() (_swig_ret Pointf) { + return _swig_wrap_new_Pointf() +} + +var _wrap_delete_Pointf unsafe.Pointer + +func _swig_wrap_delete_Pointf(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Pointf, _swig_p) + return +} + +func DeletePointf(arg1 Pointf) { + _swig_wrap_delete_Pointf(arg1.Swigcptr()) +} + +type Pointf interface { + Swigcptr() uintptr + SwigIsPointf() + SetX(arg2 float64) + GetX() (_swig_ret float64) + SetY(arg2 float64) + GetY() (_swig_ret float64) +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/default_args_runme b/Examples/test-suite/go/default_args_runme new file mode 100755 index 000000000..347e01e70 Binary files /dev/null and b/Examples/test-suite/go/default_args_runme differ diff --git a/Examples/test-suite/go/default_constructor.go b/Examples/test-suite/go/default_constructor.go new file mode 100644 index 000000000..8d4b6fe40 --- /dev/null +++ b/Examples/test-suite/go/default_constructor.go @@ -0,0 +1,902 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../default_constructor.i + +package default_constructor + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrA uintptr + +func (p SwigcptrA) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrA) SwigIsA() { +} + +var _wrap_new_A unsafe.Pointer + +func _swig_wrap_new_A() (base SwigcptrA) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_A, _swig_p) + return +} + +func NewA() (_swig_ret A) { + return _swig_wrap_new_A() +} + +var _wrap_delete_A unsafe.Pointer + +func _swig_wrap_delete_A(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_A, _swig_p) + return +} + +func DeleteA(arg1 A) { + _swig_wrap_delete_A(arg1.Swigcptr()) +} + +type A interface { + Swigcptr() uintptr + SwigIsA() +} + +type SwigcptrAA uintptr + +func (p SwigcptrAA) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrAA) SwigIsAA() { +} + +var _wrap_new_AA unsafe.Pointer + +func _swig_wrap_new_AA() (base SwigcptrAA) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_AA, _swig_p) + return +} + +func NewAA() (_swig_ret AA) { + return _swig_wrap_new_AA() +} + +var _wrap_delete_AA unsafe.Pointer + +func _swig_wrap_delete_AA(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_AA, _swig_p) + return +} + +func DeleteAA(arg1 AA) { + _swig_wrap_delete_AA(arg1.Swigcptr()) +} + +func (p SwigcptrAA) SwigIsA() { +} + +func (p SwigcptrAA) SwigGetA() A { + return SwigcptrA(p.Swigcptr()) +} + +type AA interface { + Swigcptr() uintptr + SwigIsAA() + SwigIsA() + SwigGetA() A +} + +type SwigcptrB uintptr + +func (p SwigcptrB) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrB) SwigIsB() { +} + +var _wrap_new_B unsafe.Pointer + +func _swig_wrap_new_B(base int, _ int) (_ SwigcptrB) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_B, _swig_p) + return +} + +func NewB(arg1 int, arg2 int) (_swig_ret B) { + return _swig_wrap_new_B(arg1, arg2) +} + +var _wrap_delete_B unsafe.Pointer + +func _swig_wrap_delete_B(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_B, _swig_p) + return +} + +func DeleteB(arg1 B) { + _swig_wrap_delete_B(arg1.Swigcptr()) +} + +type B interface { + Swigcptr() uintptr + SwigIsB() +} + +type SwigcptrBB uintptr + +func (p SwigcptrBB) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrBB) SwigIsBB() { +} + +var _wrap_delete_BB unsafe.Pointer + +func _swig_wrap_delete_BB(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_BB, _swig_p) + return +} + +func DeleteBB(arg1 BB) { + _swig_wrap_delete_BB(arg1.Swigcptr()) +} + +func (p SwigcptrBB) SwigIsB() { +} + +func (p SwigcptrBB) SwigGetB() B { + return SwigcptrB(p.Swigcptr()) +} + +type BB interface { + Swigcptr() uintptr + SwigIsBB() + SwigIsB() + SwigGetB() B +} + +type SwigcptrC uintptr + +func (p SwigcptrC) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrC) SwigIsC() { +} + +var _wrap_delete_C unsafe.Pointer + +func _swig_wrap_delete_C(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_C, _swig_p) + return +} + +func DeleteC(arg1 C) { + _swig_wrap_delete_C(arg1.Swigcptr()) +} + +type C interface { + Swigcptr() uintptr + SwigIsC() +} + +type SwigcptrCC uintptr + +func (p SwigcptrCC) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrCC) SwigIsCC() { +} + +var _wrap_new_CC unsafe.Pointer + +func _swig_wrap_new_CC() (base SwigcptrCC) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_CC, _swig_p) + return +} + +func NewCC() (_swig_ret CC) { + return _swig_wrap_new_CC() +} + +var _wrap_delete_CC unsafe.Pointer + +func _swig_wrap_delete_CC(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_CC, _swig_p) + return +} + +func DeleteCC(arg1 CC) { + _swig_wrap_delete_CC(arg1.Swigcptr()) +} + +func (p SwigcptrCC) SwigIsC() { +} + +func (p SwigcptrCC) SwigGetC() C { + return SwigcptrC(p.Swigcptr()) +} + +type CC interface { + Swigcptr() uintptr + SwigIsCC() + SwigIsC() + SwigGetC() C +} + +type SwigcptrD uintptr + +func (p SwigcptrD) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrD) SwigIsD() { +} + +var _wrap_D_foo unsafe.Pointer + +func _swig_wrap_D_foo(base SwigcptrD) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_D_foo, _swig_p) + return +} + +func (arg1 SwigcptrD) Foo() { + _swig_wrap_D_foo(arg1) +} + +var _wrap_delete_D unsafe.Pointer + +func _swig_wrap_delete_D(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_D, _swig_p) + return +} + +func DeleteD(arg1 D) { + _swig_wrap_delete_D(arg1.Swigcptr()) +} + +type D interface { + Swigcptr() uintptr + SwigIsD() + Foo() +} + +type SwigcptrDD uintptr + +func (p SwigcptrDD) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrDD) SwigIsDD() { +} + +var _wrap_delete_DD unsafe.Pointer + +func _swig_wrap_delete_DD(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_DD, _swig_p) + return +} + +func DeleteDD(arg1 DD) { + _swig_wrap_delete_DD(arg1.Swigcptr()) +} + +var _wrap_DD_foo unsafe.Pointer + +func _swig_wrap_DD_foo(base SwigcptrDD) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_DD_foo, _swig_p) + return +} + +func (_swig_base SwigcptrDD) Foo() { + _swig_wrap_DD_foo(_swig_base) +} + +func (p SwigcptrDD) SwigIsD() { +} + +func (p SwigcptrDD) SwigGetD() D { + return SwigcptrD(p.Swigcptr()) +} + +type DD interface { + Swigcptr() uintptr + SwigIsDD() + Foo() + SwigIsD() + SwigGetD() D +} + +type SwigcptrAD uintptr + +func (p SwigcptrAD) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrAD) SwigIsAD() { +} + +var _wrap_delete_AD unsafe.Pointer + +func _swig_wrap_delete_AD(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_AD, _swig_p) + return +} + +func DeleteAD(arg1 AD) { + _swig_wrap_delete_AD(arg1.Swigcptr()) +} + +var _wrap_AD_foo unsafe.Pointer + +func _swig_wrap_AD_foo(base SwigcptrAD) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_AD_foo, _swig_p) + return +} + +func (_swig_base SwigcptrAD) Foo() { + _swig_wrap_AD_foo(_swig_base) +} + +func (p SwigcptrAD) SwigIsA() { +} + +func (p SwigcptrAD) SwigGetA() A { + return SwigcptrA(p.Swigcptr()) +} + +var _wrap_AD_SwigGetD unsafe.Pointer + +func _swig_wrap_AD_SwigGetD(base SwigcptrAD) (_ SwigcptrD) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_AD_SwigGetD, _swig_p) + return +} + +func (arg1 SwigcptrAD) SwigGetD() (_swig_ret D) { + return _swig_wrap_AD_SwigGetD(arg1) +} + +type AD interface { + Swigcptr() uintptr + SwigIsAD() + Foo() + SwigIsA() + SwigGetA() A + SwigGetD() (_swig_ret D) +} + +type SwigcptrE uintptr + +func (p SwigcptrE) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrE) SwigIsE() { +} + +var _wrap_new_E__SWIG_0 unsafe.Pointer + +func _swig_wrap_new_E__SWIG_0(base int, _ int) (_ SwigcptrE) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_E__SWIG_0, _swig_p) + return +} + +func NewE__SWIG_0(arg1 int, arg2 int) (_swig_ret E) { + return _swig_wrap_new_E__SWIG_0(arg1, arg2) +} + +var _wrap_new_E__SWIG_1 unsafe.Pointer + +func _swig_wrap_new_E__SWIG_1(base int) (_ SwigcptrE) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_E__SWIG_1, _swig_p) + return +} + +func NewE__SWIG_1(arg1 int) (_swig_ret E) { + return _swig_wrap_new_E__SWIG_1(arg1) +} + +var _wrap_new_E__SWIG_2 unsafe.Pointer + +func _swig_wrap_new_E__SWIG_2() (base SwigcptrE) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_E__SWIG_2, _swig_p) + return +} + +func NewE__SWIG_2() (_swig_ret E) { + return _swig_wrap_new_E__SWIG_2() +} + +func NewE(a ...interface{}) E { + argc := len(a) + if argc == 0 { + return NewE__SWIG_2() + } + if argc == 1 { + return NewE__SWIG_1(a[0].(int)) + } + if argc == 2 { + return NewE__SWIG_0(a[0].(int), a[1].(int)) + } + panic("No match for overloaded function call") +} + +var _wrap_delete_E unsafe.Pointer + +func _swig_wrap_delete_E(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_E, _swig_p) + return +} + +func DeleteE(arg1 E) { + _swig_wrap_delete_E(arg1.Swigcptr()) +} + +type E interface { + Swigcptr() uintptr + SwigIsE() +} + +type SwigcptrEE uintptr + +func (p SwigcptrEE) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrEE) SwigIsEE() { +} + +var _wrap_new_EE unsafe.Pointer + +func _swig_wrap_new_EE() (base SwigcptrEE) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_EE, _swig_p) + return +} + +func NewEE() (_swig_ret EE) { + return _swig_wrap_new_EE() +} + +var _wrap_delete_EE unsafe.Pointer + +func _swig_wrap_delete_EE(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_EE, _swig_p) + return +} + +func DeleteEE(arg1 EE) { + _swig_wrap_delete_EE(arg1.Swigcptr()) +} + +func (p SwigcptrEE) SwigIsE() { +} + +func (p SwigcptrEE) SwigGetE() E { + return SwigcptrE(p.Swigcptr()) +} + +type EE interface { + Swigcptr() uintptr + SwigIsEE() + SwigIsE() + SwigGetE() E +} + +type SwigcptrEB uintptr + +func (p SwigcptrEB) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrEB) SwigIsEB() { +} + +var _wrap_delete_EB unsafe.Pointer + +func _swig_wrap_delete_EB(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_EB, _swig_p) + return +} + +func DeleteEB(arg1 EB) { + _swig_wrap_delete_EB(arg1.Swigcptr()) +} + +func (p SwigcptrEB) SwigIsE() { +} + +func (p SwigcptrEB) SwigGetE() E { + return SwigcptrE(p.Swigcptr()) +} + +var _wrap_EB_SwigGetB unsafe.Pointer + +func _swig_wrap_EB_SwigGetB(base SwigcptrEB) (_ SwigcptrB) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_EB_SwigGetB, _swig_p) + return +} + +func (arg1 SwigcptrEB) SwigGetB() (_swig_ret B) { + return _swig_wrap_EB_SwigGetB(arg1) +} + +type EB interface { + Swigcptr() uintptr + SwigIsEB() + SwigIsE() + SwigGetE() E + SwigGetB() (_swig_ret B) +} + +type SwigcptrF uintptr + +func (p SwigcptrF) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrF) SwigIsF() { +} + +var _wrap_F_foo unsafe.Pointer + +func _swig_wrap_F_foo(base SwigcptrF, _ int, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_F_foo, _swig_p) + return +} + +func (arg1 SwigcptrF) Foo(arg2 int, arg3 int) { + _swig_wrap_F_foo(arg1, arg2, arg3) +} + +var _wrap_bar unsafe.Pointer + +func _swig_wrap_bar(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_bar, _swig_p) + return +} + +func Bar(arg1 F) { + _swig_wrap_bar(arg1.Swigcptr()) +} + +var _wrap_F_destroy unsafe.Pointer + +func _swig_wrap_F_destroy(base SwigcptrF) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_F_destroy, _swig_p) + return +} + +func (arg1 SwigcptrF) Destroy() { + _swig_wrap_F_destroy(arg1) +} + +var _wrap_new_F unsafe.Pointer + +func _swig_wrap_new_F() (base SwigcptrF) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_F, _swig_p) + return +} + +func NewF() (_swig_ret F) { + return _swig_wrap_new_F() +} + +type F interface { + Swigcptr() uintptr + SwigIsF() + Foo(arg2 int, arg3 int) + Destroy() +} + +type SwigcptrFFF uintptr + +func (p SwigcptrFFF) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrFFF) SwigIsFFF() { +} + +var _wrap_new_FFF unsafe.Pointer + +func _swig_wrap_new_FFF() (base SwigcptrFFF) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_FFF, _swig_p) + return +} + +func NewFFF() (_swig_ret FFF) { + return _swig_wrap_new_FFF() +} + +var _wrap_FFF_foo unsafe.Pointer + +func _swig_wrap_FFF_foo(base SwigcptrFFF, _ int, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_FFF_foo, _swig_p) + return +} + +func (_swig_base SwigcptrFFF) Foo(arg1 int, arg2 int) { + _swig_wrap_FFF_foo(_swig_base, arg1, arg2) +} + +var _wrap_FFF_destroy unsafe.Pointer + +func _swig_wrap_FFF_destroy(base SwigcptrFFF) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_FFF_destroy, _swig_p) + return +} + +func (_swig_base SwigcptrFFF) Destroy() { + _swig_wrap_FFF_destroy(_swig_base) +} + +func (p SwigcptrFFF) SwigIsF() { +} + +func (p SwigcptrFFF) SwigGetF() F { + return SwigcptrF(p.Swigcptr()) +} + +type FFF interface { + Swigcptr() uintptr + SwigIsFFF() + Foo(arg1 int, arg2 int) + Destroy() + SwigIsF() + SwigGetF() F +} + +type SwigcptrG uintptr + +func (p SwigcptrG) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrG) SwigIsG() { +} + +var _wrap_G_destroy unsafe.Pointer + +func _swig_wrap_G_destroy(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_G_destroy, _swig_p) + return +} + +func GDestroy(arg1 G) { + _swig_wrap_G_destroy(arg1.Swigcptr()) +} + +var _wrap_new_G unsafe.Pointer + +func _swig_wrap_new_G() (base SwigcptrG) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_G, _swig_p) + return +} + +func NewG() (_swig_ret G) { + return _swig_wrap_new_G() +} + +type G interface { + Swigcptr() uintptr + SwigIsG() +} + +type SwigcptrGG uintptr + +func (p SwigcptrGG) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrGG) SwigIsGG() { +} + +var _wrap_new_GG unsafe.Pointer + +func _swig_wrap_new_GG() (base SwigcptrGG) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_GG, _swig_p) + return +} + +func NewGG() (_swig_ret GG) { + return _swig_wrap_new_GG() +} + +var _wrap_delete_GG unsafe.Pointer + +func _swig_wrap_delete_GG(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_GG, _swig_p) + return +} + +func DeleteGG(arg1 GG) { + _swig_wrap_delete_GG(arg1.Swigcptr()) +} + +var _wrap_GG_destroy unsafe.Pointer + +func _swig_wrap_GG_destroy(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_GG_destroy, _swig_p) + return +} + +func GGDestroy(arg1 G) { + _swig_wrap_GG_destroy(arg1.Swigcptr()) +} + +func (p SwigcptrGG) SwigIsG() { +} + +func (p SwigcptrGG) SwigGetG() G { + return SwigcptrG(p.Swigcptr()) +} + +type GG interface { + Swigcptr() uintptr + SwigIsGG() + SwigIsG() + SwigGetG() G +} + +type SwigcptrHH uintptr + +func (p SwigcptrHH) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrHH) SwigIsHH() { +} + +var _wrap_new_HH unsafe.Pointer + +func _swig_wrap_new_HH(base int, _ int) (_ SwigcptrHH) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_HH, _swig_p) + return +} + +func NewHH(arg1 int, arg2 int) (_swig_ret HH) { + return _swig_wrap_new_HH(arg1, arg2) +} + +var _wrap_delete_HH unsafe.Pointer + +func _swig_wrap_delete_HH(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_HH, _swig_p) + return +} + +func DeleteHH(arg1 HH) { + _swig_wrap_delete_HH(arg1.Swigcptr()) +} + +type HH interface { + Swigcptr() uintptr + SwigIsHH() +} + +type SwigcptrVoid uintptr + +func (p SwigcptrVoid) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrVoid) SwigIsOSRSpatialReferenceShadow() { +} + +var _wrap_new_OSRSpatialReferenceShadow__SWIG_0 unsafe.Pointer + +func _swig_wrap_new_OSRSpatialReferenceShadow__SWIG_0(base string) (_ SwigcptrVoid) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_OSRSpatialReferenceShadow__SWIG_0, _swig_p) + return +} + +func NewOSRSpatialReferenceShadow__SWIG_0(arg1 string) (_swig_ret OSRSpatialReferenceShadow) { + return _swig_wrap_new_OSRSpatialReferenceShadow__SWIG_0(arg1) +} + +var _wrap_new_OSRSpatialReferenceShadow__SWIG_1 unsafe.Pointer + +func _swig_wrap_new_OSRSpatialReferenceShadow__SWIG_1() (base SwigcptrVoid) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_OSRSpatialReferenceShadow__SWIG_1, _swig_p) + return +} + +func NewOSRSpatialReferenceShadow__SWIG_1() (_swig_ret OSRSpatialReferenceShadow) { + return _swig_wrap_new_OSRSpatialReferenceShadow__SWIG_1() +} + +func NewOSRSpatialReferenceShadow(a ...interface{}) { + argc := len(a) + if argc == 0 { + NewOSRSpatialReferenceShadow__SWIG_1() + return + } + if argc == 1 { + NewOSRSpatialReferenceShadow__SWIG_0(a[0].(string)) + return + } + panic("No match for overloaded function call") +} + +var _wrap_delete_OSRSpatialReferenceShadow unsafe.Pointer + +func _swig_wrap_delete_OSRSpatialReferenceShadow(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_OSRSpatialReferenceShadow, _swig_p) + return +} + +func DeleteOSRSpatialReferenceShadow(arg1 OSRSpatialReferenceShadow) { + _swig_wrap_delete_OSRSpatialReferenceShadow(arg1.Swigcptr()) +} + +type OSRSpatialReferenceShadow interface { + Swigcptr() uintptr + SwigIsOSRSpatialReferenceShadow() +} + + diff --git a/Examples/test-suite/go/default_constructor_runme b/Examples/test-suite/go/default_constructor_runme new file mode 100755 index 000000000..46e4adfc2 Binary files /dev/null and b/Examples/test-suite/go/default_constructor_runme differ diff --git a/Examples/test-suite/go/defvalue_constructor.go b/Examples/test-suite/go/defvalue_constructor.go new file mode 100644 index 000000000..04758e210 --- /dev/null +++ b/Examples/test-suite/go/defvalue_constructor.go @@ -0,0 +1,136 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../defvalue_constructor.i + +package defvalue_constructor + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrBar uintptr + +func (p SwigcptrBar) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrBar) SwigIsBar() { +} + +var _wrap_new_Bar unsafe.Pointer + +func _swig_wrap_new_Bar() (base SwigcptrBar) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Bar, _swig_p) + return +} + +func NewBar() (_swig_ret Bar) { + return _swig_wrap_new_Bar() +} + +var _wrap_delete_Bar unsafe.Pointer + +func _swig_wrap_delete_Bar(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Bar, _swig_p) + return +} + +func DeleteBar(arg1 Bar) { + _swig_wrap_delete_Bar(arg1.Swigcptr()) +} + +type Bar interface { + Swigcptr() uintptr + SwigIsBar() +} + +type SwigcptrBaz uintptr + +func (p SwigcptrBaz) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrBaz) SwigIsBaz() { +} + +var _wrap_new_Baz__SWIG_0 unsafe.Pointer + +func _swig_wrap_new_Baz__SWIG_0(base uintptr) (_ SwigcptrBaz) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Baz__SWIG_0, _swig_p) + return +} + +func NewBaz__SWIG_0(arg1 Bar) (_swig_ret Baz) { + return _swig_wrap_new_Baz__SWIG_0(arg1.Swigcptr()) +} + +var _wrap_new_Baz__SWIG_1 unsafe.Pointer + +func _swig_wrap_new_Baz__SWIG_1() (base SwigcptrBaz) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Baz__SWIG_1, _swig_p) + return +} + +func NewBaz__SWIG_1() (_swig_ret Baz) { + return _swig_wrap_new_Baz__SWIG_1() +} + +func NewBaz(a ...interface{}) Baz { + argc := len(a) + if argc == 0 { + return NewBaz__SWIG_1() + } + if argc == 1 { + return NewBaz__SWIG_0(a[0].(Bar)) + } + panic("No match for overloaded function call") +} + +var _wrap_delete_Baz unsafe.Pointer + +func _swig_wrap_delete_Baz(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Baz, _swig_p) + return +} + +func DeleteBaz(arg1 Baz) { + _swig_wrap_delete_Baz(arg1.Swigcptr()) +} + +type Baz interface { + Swigcptr() uintptr + SwigIsBaz() +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/derived_byvalue.go b/Examples/test-suite/go/derived_byvalue.go new file mode 100644 index 000000000..483215912 --- /dev/null +++ b/Examples/test-suite/go/derived_byvalue.go @@ -0,0 +1,316 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../derived_byvalue.i + +package derived_byvalue + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrFoo uintptr + +func (p SwigcptrFoo) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrFoo) SwigIsFoo() { +} + +var _wrap_Foo_x_set unsafe.Pointer + +func _swig_wrap_Foo_x_set(base SwigcptrFoo, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_x_set, _swig_p) + return +} + +func (arg1 SwigcptrFoo) SetX(arg2 int) { + _swig_wrap_Foo_x_set(arg1, arg2) +} + +var _wrap_Foo_x_get unsafe.Pointer + +func _swig_wrap_Foo_x_get(base SwigcptrFoo) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_x_get, _swig_p) + return +} + +func (arg1 SwigcptrFoo) GetX() (_swig_ret int) { + return _swig_wrap_Foo_x_get(arg1) +} + +var _wrap_Foo_rmethod unsafe.Pointer + +func _swig_wrap_Foo_rmethod(base SwigcptrFoo, _ uintptr) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_rmethod, _swig_p) + return +} + +func (arg1 SwigcptrFoo) Rmethod(arg2 Foo) (_swig_ret int) { + return _swig_wrap_Foo_rmethod(arg1, arg2.Swigcptr()) +} + +var _wrap_Foo_method unsafe.Pointer + +func _swig_wrap_Foo_method(base SwigcptrFoo, _ uintptr) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_method, _swig_p) + return +} + +func (arg1 SwigcptrFoo) Method(arg2 Foo) (_swig_ret int) { + return _swig_wrap_Foo_method(arg1, arg2.Swigcptr()) +} + +var _wrap_new_Foo unsafe.Pointer + +func _swig_wrap_new_Foo() (base SwigcptrFoo) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Foo, _swig_p) + return +} + +func NewFoo() (_swig_ret Foo) { + return _swig_wrap_new_Foo() +} + +var _wrap_delete_Foo unsafe.Pointer + +func _swig_wrap_delete_Foo(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Foo, _swig_p) + return +} + +func DeleteFoo(arg1 Foo) { + _swig_wrap_delete_Foo(arg1.Swigcptr()) +} + +type Foo interface { + Swigcptr() uintptr + SwigIsFoo() + SetX(arg2 int) + GetX() (_swig_ret int) + Rmethod(arg2 Foo) (_swig_ret int) + Method(arg2 Foo) (_swig_ret int) +} + +type SwigcptrBar uintptr + +func (p SwigcptrBar) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrBar) SwigIsBar() { +} + +var _wrap_Bar_a_set unsafe.Pointer + +func _swig_wrap_Bar_a_set(base SwigcptrBar, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Bar_a_set, _swig_p) + return +} + +func (arg1 SwigcptrBar) SetA(arg2 Foo) { + _swig_wrap_Bar_a_set(arg1, arg2.Swigcptr()) +} + +var _wrap_Bar_a_get unsafe.Pointer + +func _swig_wrap_Bar_a_get(base SwigcptrBar) (_ SwigcptrFoo) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Bar_a_get, _swig_p) + return +} + +func (arg1 SwigcptrBar) GetA() (_swig_ret Foo) { + return _swig_wrap_Bar_a_get(arg1) +} + +var _wrap_Bar_b_set unsafe.Pointer + +func _swig_wrap_Bar_b_set(base SwigcptrBar, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Bar_b_set, _swig_p) + return +} + +func (arg1 SwigcptrBar) SetB(arg2 Foo) { + _swig_wrap_Bar_b_set(arg1, arg2.Swigcptr()) +} + +var _wrap_Bar_b_get unsafe.Pointer + +func _swig_wrap_Bar_b_get(base SwigcptrBar) (_ SwigcptrFoo) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Bar_b_get, _swig_p) + return +} + +func (arg1 SwigcptrBar) GetB() (_swig_ret Foo) { + return _swig_wrap_Bar_b_get(arg1) +} + +var _wrap_new_Bar unsafe.Pointer + +func _swig_wrap_new_Bar() (base SwigcptrBar) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Bar, _swig_p) + return +} + +func NewBar() (_swig_ret Bar) { + return _swig_wrap_new_Bar() +} + +var _wrap_delete_Bar unsafe.Pointer + +func _swig_wrap_delete_Bar(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Bar, _swig_p) + return +} + +func DeleteBar(arg1 Bar) { + _swig_wrap_delete_Bar(arg1.Swigcptr()) +} + +type Bar interface { + Swigcptr() uintptr + SwigIsBar() + SetA(arg2 Foo) + GetA() (_swig_ret Foo) + SetB(arg2 Foo) + GetB() (_swig_ret Foo) +} + +type SwigcptrDerFoo uintptr + +func (p SwigcptrDerFoo) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrDerFoo) SwigIsDerFoo() { +} + +var _wrap_new_DerFoo unsafe.Pointer + +func _swig_wrap_new_DerFoo() (base SwigcptrDerFoo) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_DerFoo, _swig_p) + return +} + +func NewDerFoo() (_swig_ret DerFoo) { + return _swig_wrap_new_DerFoo() +} + +var _wrap_delete_DerFoo unsafe.Pointer + +func _swig_wrap_delete_DerFoo(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_DerFoo, _swig_p) + return +} + +func DeleteDerFoo(arg1 DerFoo) { + _swig_wrap_delete_DerFoo(arg1.Swigcptr()) +} + +var _wrap_SetDerFoo_X unsafe.Pointer + +func _swig_wrap_SetDerFoo_X(base SwigcptrDerFoo, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_SetDerFoo_X, _swig_p) + return +} + +func (_swig_base SwigcptrDerFoo) SetX(arg1 int) { + _swig_wrap_SetDerFoo_X(_swig_base, arg1) +} + +var _wrap_GetDerFoo_X unsafe.Pointer + +func _swig_wrap_GetDerFoo_X(base SwigcptrDerFoo) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_GetDerFoo_X, _swig_p) + return +} + +func (_swig_base SwigcptrDerFoo) GetX() (_swig_ret int) { + return _swig_wrap_GetDerFoo_X(_swig_base) +} + +var _wrap_DerFoo_rmethod unsafe.Pointer + +func _swig_wrap_DerFoo_rmethod(base SwigcptrDerFoo, _ uintptr) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_DerFoo_rmethod, _swig_p) + return +} + +func (_swig_base SwigcptrDerFoo) Rmethod(arg1 Foo) (_swig_ret int) { + return _swig_wrap_DerFoo_rmethod(_swig_base, arg1.Swigcptr()) +} + +var _wrap_DerFoo_method unsafe.Pointer + +func _swig_wrap_DerFoo_method(base SwigcptrDerFoo, _ uintptr) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_DerFoo_method, _swig_p) + return +} + +func (_swig_base SwigcptrDerFoo) Method(arg1 Foo) (_swig_ret int) { + return _swig_wrap_DerFoo_method(_swig_base, arg1.Swigcptr()) +} + +func (p SwigcptrDerFoo) SwigIsFoo() { +} + +func (p SwigcptrDerFoo) SwigGetFoo() Foo { + return SwigcptrFoo(p.Swigcptr()) +} + +type DerFoo interface { + Swigcptr() uintptr + SwigIsDerFoo() + SetX(arg1 int) + GetX() (_swig_ret int) + Rmethod(arg1 Foo) (_swig_ret int) + Method(arg1 Foo) (_swig_ret int) + SwigIsFoo() + SwigGetFoo() Foo +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/derived_nested.go b/Examples/test-suite/go/derived_nested.go new file mode 100644 index 000000000..f31f58160 --- /dev/null +++ b/Examples/test-suite/go/derived_nested.go @@ -0,0 +1,232 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../derived_nested.i + +package derived_nested + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrA uintptr + +func (p SwigcptrA) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrA) SwigIsA() { +} + +var _wrap_A_x_set unsafe.Pointer + +func _swig_wrap_A_x_set(base SwigcptrA, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_A_x_set, _swig_p) + return +} + +func (arg1 SwigcptrA) SetX(arg2 int) { + _swig_wrap_A_x_set(arg1, arg2) +} + +var _wrap_A_x_get unsafe.Pointer + +func _swig_wrap_A_x_get(base SwigcptrA) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_A_x_get, _swig_p) + return +} + +func (arg1 SwigcptrA) GetX() (_swig_ret int) { + return _swig_wrap_A_x_get(arg1) +} + +var _wrap_new_A unsafe.Pointer + +func _swig_wrap_new_A() (base SwigcptrA) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_A, _swig_p) + return +} + +func NewA() (_swig_ret A) { + return _swig_wrap_new_A() +} + +var _wrap_delete_A unsafe.Pointer + +func _swig_wrap_delete_A(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_A, _swig_p) + return +} + +func DeleteA(arg1 A) { + _swig_wrap_delete_A(arg1.Swigcptr()) +} + +type A interface { + Swigcptr() uintptr + SwigIsA() + SetX(arg2 int) + GetX() (_swig_ret int) +} + +type SwigcptrB uintptr + +func (p SwigcptrB) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrB) SwigIsB() { +} + +var _wrap_new_B unsafe.Pointer + +func _swig_wrap_new_B() (base SwigcptrB) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_B, _swig_p) + return +} + +func NewB() (_swig_ret B) { + return _swig_wrap_new_B() +} + +var _wrap_delete_B unsafe.Pointer + +func _swig_wrap_delete_B(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_B, _swig_p) + return +} + +func DeleteB(arg1 B) { + _swig_wrap_delete_B(arg1.Swigcptr()) +} + +type B interface { + Swigcptr() uintptr + SwigIsB() +} + +type SwigcptrBB uintptr + +func (p SwigcptrBB) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrBB) SwigIsBB() { +} + +var _wrap_BB_ff_instance_set unsafe.Pointer + +func _swig_wrap_BB_ff_instance_set(base SwigcptrBB, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_BB_ff_instance_set, _swig_p) + return +} + +func (arg1 SwigcptrBB) SetFf_instance(arg2 BB_FF) { + _swig_wrap_BB_ff_instance_set(arg1, arg2.Swigcptr()) +} + +var _wrap_BB_ff_instance_get unsafe.Pointer + +func _swig_wrap_BB_ff_instance_get(base SwigcptrBB) (_ SwigcptrBB_FF) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_BB_ff_instance_get, _swig_p) + return +} + +func (arg1 SwigcptrBB) GetFf_instance() (_swig_ret BB_FF) { + return _swig_wrap_BB_ff_instance_get(arg1) +} + +var _wrap_BB_useEE unsafe.Pointer + +func _swig_wrap_BB_useEE(base SwigcptrBB, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_BB_useEE, _swig_p) + return +} + +func (arg1 SwigcptrBB) UseEE(arg2 BB_EE) { + _swig_wrap_BB_useEE(arg1, arg2.Swigcptr()) +} + +var _wrap_new_BB unsafe.Pointer + +func _swig_wrap_new_BB() (base SwigcptrBB) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_BB, _swig_p) + return +} + +func NewBB() (_swig_ret BB) { + return _swig_wrap_new_BB() +} + +var _wrap_delete_BB unsafe.Pointer + +func _swig_wrap_delete_BB(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_BB, _swig_p) + return +} + +func DeleteBB(arg1 BB) { + _swig_wrap_delete_BB(arg1.Swigcptr()) +} + +type BB interface { + Swigcptr() uintptr + SwigIsBB() + SetFf_instance(arg2 BB_FF) + GetFf_instance() (_swig_ret BB_FF) + UseEE(arg2 BB_EE) +} + + +type SwigcptrBB_FF uintptr +type BB_FF interface { + Swigcptr() uintptr; +} +func (p SwigcptrBB_FF) Swigcptr() uintptr { + return uintptr(p) +} + +type SwigcptrBB_EE uintptr +type BB_EE interface { + Swigcptr() uintptr; +} +func (p SwigcptrBB_EE) Swigcptr() uintptr { + return uintptr(p) +} + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/destructor_reprotected.go b/Examples/test-suite/go/destructor_reprotected.go new file mode 100644 index 000000000..9c2a54c2e --- /dev/null +++ b/Examples/test-suite/go/destructor_reprotected.go @@ -0,0 +1,154 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../destructor_reprotected.i + +package destructor_reprotected + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrA uintptr + +func (p SwigcptrA) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrA) SwigIsA() { +} + +var _wrap_new_A unsafe.Pointer + +func _swig_wrap_new_A() (base SwigcptrA) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_A, _swig_p) + return +} + +func NewA() (_swig_ret A) { + return _swig_wrap_new_A() +} + +var _wrap_delete_A unsafe.Pointer + +func _swig_wrap_delete_A(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_A, _swig_p) + return +} + +func DeleteA(arg1 A) { + _swig_wrap_delete_A(arg1.Swigcptr()) +} + +type A interface { + Swigcptr() uintptr + SwigIsA() +} + +type SwigcptrB uintptr + +func (p SwigcptrB) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrB) SwigIsB() { +} + +func (p SwigcptrB) SwigIsA() { +} + +func (p SwigcptrB) SwigGetA() A { + return SwigcptrA(p.Swigcptr()) +} + +type B interface { + Swigcptr() uintptr + SwigIsB() + SwigIsA() + SwigGetA() A +} + +type SwigcptrC uintptr + +func (p SwigcptrC) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrC) SwigIsC() { +} + +var _wrap_new_C unsafe.Pointer + +func _swig_wrap_new_C() (base SwigcptrC) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_C, _swig_p) + return +} + +func NewC() (_swig_ret C) { + return _swig_wrap_new_C() +} + +var _wrap_delete_C unsafe.Pointer + +func _swig_wrap_delete_C(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_C, _swig_p) + return +} + +func DeleteC(arg1 C) { + _swig_wrap_delete_C(arg1.Swigcptr()) +} + +func (p SwigcptrC) SwigIsB() { +} + +func (p SwigcptrC) SwigGetB() B { + return SwigcptrB(p.Swigcptr()) +} + +func (p SwigcptrC) SwigIsA() { +} + +func (p SwigcptrC) SwigGetA() A { + return SwigcptrA(p.Swigcptr()) +} + +type C interface { + Swigcptr() uintptr + SwigIsC() + SwigIsB() + SwigGetB() B + SwigIsA() + SwigGetA() A +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/director_abstract.go b/Examples/test-suite/go/director_abstract.go new file mode 100644 index 000000000..616ca3f58 --- /dev/null +++ b/Examples/test-suite/go/director_abstract.go @@ -0,0 +1,1331 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../director_abstract.i + +package director_abstract + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type _swig_DirectorFoo struct { + SwigcptrFoo + v interface{} +} + +func (p *_swig_DirectorFoo) Swigcptr() uintptr { + return p.SwigcptrFoo.Swigcptr() +} + +func (p *_swig_DirectorFoo) SwigIsFoo() { +} + +func (p *_swig_DirectorFoo) DirectorInterface() interface{} { + return p.v +} + +var _wrap__swig_NewDirectorFooFoo unsafe.Pointer + +func _swig_NewDirectorFooFoo(_swig_director *_swig_DirectorFoo) (_swig_ret SwigcptrFoo) { + _swig_p := uintptr(unsafe.Pointer(&_swig_director)) + _cgo_runtime_cgocall(_wrap__swig_NewDirectorFooFoo, _swig_p) + return +} + +func NewDirectorFoo(v interface{}) Foo { + p := &_swig_DirectorFoo{0, v} + p.SwigcptrFoo = _swig_NewDirectorFooFoo(p) + return p +} + +var _wrap_DeleteDirectorFoo unsafe.Pointer + +func _swig_wrap_DeleteDirectorFoo(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_DeleteDirectorFoo, _swig_p) + return +} + +func DeleteDirectorFoo(arg1 Foo) { + _swig_wrap_DeleteDirectorFoo(arg1.Swigcptr()) +} + +func Swiggo_DeleteDirector_Foo(p *_swig_DirectorFoo) { + p.SwigcptrFoo = 0 +} + +type _swig_DirectorInterfaceFooPing interface { + Ping() string +} + +func (swig_p *_swig_DirectorFoo) Ping() string { + if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceFooPing); swig_ok { + return swig_g.Ping() + } + panic("call to pure virtual method") +} + +func Swig_DirectorFoo_callback_ping(p *_swig_DirectorFoo) (swig_result string) { + var swig_r string + swig_r = p.Ping() + return swig_r +} + +type _swig_DirectorInterfaceFooPong interface { + Pong() string +} + +var _wrap__swig_DirectorFoo_upcall_Pong unsafe.Pointer + +func _swig_wrap__swig_DirectorFoo_upcall_Pong(_swig_ptr SwigcptrFoo) (_swig_ret string) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) + _cgo_runtime_cgocall(_wrap__swig_DirectorFoo_upcall_Pong, _swig_p) + return +} + +func (swig_p *_swig_DirectorFoo) Pong() string { + if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceFooPong); swig_ok { + return swig_g.Pong() + } + var swig_r string + swig_r = _swig_wrap__swig_DirectorFoo_upcall_Pong(swig_p.SwigcptrFoo) + return swig_r +} + +func DirectorFooPong(p Foo) string { + var swig_r string + swig_r = _swig_wrap__swig_DirectorFoo_upcall_Pong(p.(*_swig_DirectorFoo).SwigcptrFoo) + return swig_r +} + +func Swig_DirectorFoo_callback_pong(p *_swig_DirectorFoo) (swig_result string) { + var swig_r string + swig_r = p.Pong() + return swig_r +} + +type SwigcptrFoo uintptr + +func (p SwigcptrFoo) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrFoo) SwigIsFoo() { +} + +func (p SwigcptrFoo) DirectorInterface() interface{} { + return nil +} + +var _wrap_delete_Foo unsafe.Pointer + +func _swig_wrap_delete_Foo(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Foo, _swig_p) + return +} + +func DeleteFoo(arg1 Foo) { + _swig_wrap_delete_Foo(arg1.Swigcptr()) +} + +var _wrap_Foo_ping unsafe.Pointer + +func _swig_wrap_Foo_ping(base SwigcptrFoo) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_ping, _swig_p) + return +} + +func (arg1 SwigcptrFoo) Ping() (_swig_ret string) { + return _swig_wrap_Foo_ping(arg1) +} + +var _wrap_Foo_pong unsafe.Pointer + +func _swig_wrap_Foo_pong(base SwigcptrFoo) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_pong, _swig_p) + return +} + +func (arg1 SwigcptrFoo) Pong() (_swig_ret string) { + return _swig_wrap_Foo_pong(arg1) +} + +var _wrap_new_Foo unsafe.Pointer + +func _swig_wrap_new_Foo() (base SwigcptrFoo) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Foo, _swig_p) + return +} + +func NewFoo() (_swig_ret Foo) { + return _swig_wrap_new_Foo() +} + +type Foo interface { + Swigcptr() uintptr + SwigIsFoo() + DirectorInterface() interface{} + Ping() (_swig_ret string) + Pong() (_swig_ret string) +} + +type _swig_DirectorExample0 struct { + SwigcptrExample0 + v interface{} +} + +func (p *_swig_DirectorExample0) Swigcptr() uintptr { + return p.SwigcptrExample0.Swigcptr() +} + +func (p *_swig_DirectorExample0) SwigIsExample0() { +} + +func (p *_swig_DirectorExample0) DirectorInterface() interface{} { + return p.v +} + +var _wrap__swig_NewDirectorExample0Example0__SWIG_0 unsafe.Pointer + +func _swig_NewDirectorExample0Example0__SWIG_0(_swig_director *_swig_DirectorExample0, _ int, _ int) (_swig_ret SwigcptrExample0) { + _swig_p := uintptr(unsafe.Pointer(&_swig_director)) + _cgo_runtime_cgocall(_wrap__swig_NewDirectorExample0Example0__SWIG_0, _swig_p) + return +} + +func NewDirectorExample0__SWIG_0(v interface{}, arg1 int, arg2 int) Example0 { + p := &_swig_DirectorExample0{0, v} + p.SwigcptrExample0 = _swig_NewDirectorExample0Example0__SWIG_0(p, arg1, arg2) + return p +} + +var _wrap__swig_NewDirectorExample0Example0__SWIG_1 unsafe.Pointer + +func _swig_NewDirectorExample0Example0__SWIG_1(_swig_director *_swig_DirectorExample0) (_swig_ret SwigcptrExample0) { + _swig_p := uintptr(unsafe.Pointer(&_swig_director)) + _cgo_runtime_cgocall(_wrap__swig_NewDirectorExample0Example0__SWIG_1, _swig_p) + return +} + +func NewDirectorExample0__SWIG_1(v interface{}) Example0 { + p := &_swig_DirectorExample0{0, v} + p.SwigcptrExample0 = _swig_NewDirectorExample0Example0__SWIG_1(p) + return p +} + +func NewDirectorExample0(abi interface{}, a ...interface{}) Example0 { + argc := len(a) + if argc == 0 { + return NewDirectorExample0__SWIG_1(abi) + } + if argc == 2 { + return NewDirectorExample0__SWIG_0(abi, a[0].(int), a[1].(int)) + } + panic("No match for overloaded function call") +} + +var _wrap_DeleteDirectorExample0 unsafe.Pointer + +func _swig_wrap_DeleteDirectorExample0(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_DeleteDirectorExample0, _swig_p) + return +} + +func DeleteDirectorExample0(arg1 Example0) { + _swig_wrap_DeleteDirectorExample0(arg1.Swigcptr()) +} + +func Swiggo_DeleteDirector_Example0(p *_swig_DirectorExample0) { + p.SwigcptrExample0 = 0 +} + +type _swig_DirectorInterfaceExample0Color interface { + Color(byte, byte, byte) int +} + +var _wrap__swig_DirectorExample0_upcall_Color unsafe.Pointer + +func _swig_wrap__swig_DirectorExample0_upcall_Color(_swig_ptr SwigcptrExample0, _ byte, _ byte, _ byte) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) + _cgo_runtime_cgocall(_wrap__swig_DirectorExample0_upcall_Color, _swig_p) + return +} + +func (swig_p *_swig_DirectorExample0) Color(r byte, g byte, b byte) int { + if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceExample0Color); swig_ok { + return swig_g.Color(r, g, b) + } + var swig_r int + swig_r = _swig_wrap__swig_DirectorExample0_upcall_Color(swig_p.SwigcptrExample0, r, g, b) + return swig_r +} + +func DirectorExample0Color(p Example0, arg2 byte, arg3 byte, arg4 byte) int { + var swig_r int + swig_r = _swig_wrap__swig_DirectorExample0_upcall_Color(p.(*_swig_DirectorExample0).SwigcptrExample0, arg2, arg3, arg4) + return swig_r +} + +func Swig_DirectorExample0_callback_Color(p *_swig_DirectorExample0, arg2 byte, arg3 byte, arg4 byte) (swig_result int) { + var swig_r int + swig_r = p.Color(arg2, arg3, arg4) + return swig_r +} + +type SwigcptrExample0 uintptr + +func (p SwigcptrExample0) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrExample0) SwigIsExample0() { +} + +func (p SwigcptrExample0) DirectorInterface() interface{} { + return nil +} + +var _wrap_new_Example0__SWIG_0 unsafe.Pointer + +func _swig_wrap_new_Example0__SWIG_0(base int, _ int) (_ SwigcptrExample0) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Example0__SWIG_0, _swig_p) + return +} + +func NewExample0__SWIG_0(arg1 int, arg2 int) (_swig_ret Example0) { + return _swig_wrap_new_Example0__SWIG_0(arg1, arg2) +} + +var _wrap_new_Example0__SWIG_1 unsafe.Pointer + +func _swig_wrap_new_Example0__SWIG_1() (base SwigcptrExample0) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Example0__SWIG_1, _swig_p) + return +} + +func NewExample0__SWIG_1() (_swig_ret Example0) { + return _swig_wrap_new_Example0__SWIG_1() +} + +func NewExample0(a ...interface{}) Example0 { + argc := len(a) + if argc == 0 { + return NewExample0__SWIG_1() + } + if argc == 2 { + return NewExample0__SWIG_0(a[0].(int), a[1].(int)) + } + panic("No match for overloaded function call") +} + +var _wrap_delete_Example0 unsafe.Pointer + +func _swig_wrap_delete_Example0(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Example0, _swig_p) + return +} + +func DeleteExample0(arg1 Example0) { + _swig_wrap_delete_Example0(arg1.Swigcptr()) +} + +var _wrap_Example0_GetXSize unsafe.Pointer + +func _swig_wrap_Example0_GetXSize(base SwigcptrExample0) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Example0_GetXSize, _swig_p) + return +} + +func (arg1 SwigcptrExample0) GetXSize() (_swig_ret int) { + return _swig_wrap_Example0_GetXSize(arg1) +} + +var _wrap_Example0_Color unsafe.Pointer + +func _swig_wrap_Example0_Color(base SwigcptrExample0, _ byte, _ byte, _ byte) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Example0_Color, _swig_p) + return +} + +func (arg1 SwigcptrExample0) Color(arg2 byte, arg3 byte, arg4 byte) (_swig_ret int) { + return _swig_wrap_Example0_Color(arg1, arg2, arg3, arg4) +} + +var _wrap_Example0_get_color unsafe.Pointer + +func _swig_wrap_Example0_get_color(base uintptr, _ byte, _ byte, _ byte) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Example0_get_color, _swig_p) + return +} + +func Example0Get_color(arg1 Example0, arg2 byte, arg3 byte, arg4 byte) (_swig_ret int) { + return _swig_wrap_Example0_get_color(arg1.Swigcptr(), arg2, arg3, arg4) +} + +type Example0 interface { + Swigcptr() uintptr + SwigIsExample0() + DirectorInterface() interface{} + GetXSize() (_swig_ret int) + Color(arg2 byte, arg3 byte, arg4 byte) (_swig_ret int) +} + +type _swig_DirectorExample1 struct { + SwigcptrExample1 + v interface{} +} + +func (p *_swig_DirectorExample1) Swigcptr() uintptr { + return p.SwigcptrExample1.Swigcptr() +} + +func (p *_swig_DirectorExample1) SwigIsExample1() { +} + +func (p *_swig_DirectorExample1) DirectorInterface() interface{} { + return p.v +} + +var _wrap__swig_NewDirectorExample1Example1__SWIG_0 unsafe.Pointer + +func _swig_NewDirectorExample1Example1__SWIG_0(_swig_director *_swig_DirectorExample1, _ int, _ int) (_swig_ret SwigcptrExample1) { + _swig_p := uintptr(unsafe.Pointer(&_swig_director)) + _cgo_runtime_cgocall(_wrap__swig_NewDirectorExample1Example1__SWIG_0, _swig_p) + return +} + +func NewDirectorExample1__SWIG_0(v interface{}, arg1 int, arg2 int) Example1 { + p := &_swig_DirectorExample1{0, v} + p.SwigcptrExample1 = _swig_NewDirectorExample1Example1__SWIG_0(p, arg1, arg2) + return p +} + +var _wrap__swig_NewDirectorExample1Example1__SWIG_1 unsafe.Pointer + +func _swig_NewDirectorExample1Example1__SWIG_1(_swig_director *_swig_DirectorExample1) (_swig_ret SwigcptrExample1) { + _swig_p := uintptr(unsafe.Pointer(&_swig_director)) + _cgo_runtime_cgocall(_wrap__swig_NewDirectorExample1Example1__SWIG_1, _swig_p) + return +} + +func NewDirectorExample1__SWIG_1(v interface{}) Example1 { + p := &_swig_DirectorExample1{0, v} + p.SwigcptrExample1 = _swig_NewDirectorExample1Example1__SWIG_1(p) + return p +} + +func NewDirectorExample1(abi interface{}, a ...interface{}) Example1 { + argc := len(a) + if argc == 0 { + return NewDirectorExample1__SWIG_1(abi) + } + if argc == 2 { + return NewDirectorExample1__SWIG_0(abi, a[0].(int), a[1].(int)) + } + panic("No match for overloaded function call") +} + +var _wrap_DeleteDirectorExample1 unsafe.Pointer + +func _swig_wrap_DeleteDirectorExample1(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_DeleteDirectorExample1, _swig_p) + return +} + +func DeleteDirectorExample1(arg1 Example1) { + _swig_wrap_DeleteDirectorExample1(arg1.Swigcptr()) +} + +func Swiggo_DeleteDirector_Example1(p *_swig_DirectorExample1) { + p.SwigcptrExample1 = 0 +} + +type _swig_DirectorInterfaceExample1Color interface { + Color(byte, byte, byte) int +} + +func (swig_p *_swig_DirectorExample1) Color(r byte, g byte, b byte) int { + if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceExample1Color); swig_ok { + return swig_g.Color(r, g, b) + } + panic("call to pure virtual method") +} + +func Swig_DirectorExample1_callback_Color(p *_swig_DirectorExample1, r byte, g byte, b byte) (swig_result int) { + var swig_r int + swig_r = p.Color(r, g, b) + return swig_r +} + +type SwigcptrExample1 uintptr + +func (p SwigcptrExample1) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrExample1) SwigIsExample1() { +} + +func (p SwigcptrExample1) DirectorInterface() interface{} { + return nil +} + +var _wrap_new_Example1__SWIG_0 unsafe.Pointer + +func _swig_wrap_new_Example1__SWIG_0(base int, _ int) (_ SwigcptrExample1) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Example1__SWIG_0, _swig_p) + return +} + +func NewExample1__SWIG_0(arg1 int, arg2 int) (_swig_ret Example1) { + return _swig_wrap_new_Example1__SWIG_0(arg1, arg2) +} + +var _wrap_new_Example1__SWIG_1 unsafe.Pointer + +func _swig_wrap_new_Example1__SWIG_1() (base SwigcptrExample1) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Example1__SWIG_1, _swig_p) + return +} + +func NewExample1__SWIG_1() (_swig_ret Example1) { + return _swig_wrap_new_Example1__SWIG_1() +} + +func NewExample1(a ...interface{}) Example1 { + argc := len(a) + if argc == 0 { + return NewExample1__SWIG_1() + } + if argc == 2 { + return NewExample1__SWIG_0(a[0].(int), a[1].(int)) + } + panic("No match for overloaded function call") +} + +var _wrap_delete_Example1 unsafe.Pointer + +func _swig_wrap_delete_Example1(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Example1, _swig_p) + return +} + +func DeleteExample1(arg1 Example1) { + _swig_wrap_delete_Example1(arg1.Swigcptr()) +} + +var _wrap_Example1_GetXSize unsafe.Pointer + +func _swig_wrap_Example1_GetXSize(base SwigcptrExample1) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Example1_GetXSize, _swig_p) + return +} + +func (arg1 SwigcptrExample1) GetXSize() (_swig_ret int) { + return _swig_wrap_Example1_GetXSize(arg1) +} + +var _wrap_Example1_Color unsafe.Pointer + +func _swig_wrap_Example1_Color(base SwigcptrExample1, _ byte, _ byte, _ byte) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Example1_Color, _swig_p) + return +} + +func (arg1 SwigcptrExample1) Color(arg2 byte, arg3 byte, arg4 byte) (_swig_ret int) { + return _swig_wrap_Example1_Color(arg1, arg2, arg3, arg4) +} + +var _wrap_Example1_get_color unsafe.Pointer + +func _swig_wrap_Example1_get_color(base uintptr, _ byte, _ byte, _ byte) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Example1_get_color, _swig_p) + return +} + +func Example1Get_color(arg1 Example1, arg2 byte, arg3 byte, arg4 byte) (_swig_ret int) { + return _swig_wrap_Example1_get_color(arg1.Swigcptr(), arg2, arg3, arg4) +} + +type Example1 interface { + Swigcptr() uintptr + SwigIsExample1() + DirectorInterface() interface{} + GetXSize() (_swig_ret int) + Color(arg2 byte, arg3 byte, arg4 byte) (_swig_ret int) +} + +type _swig_DirectorExample2 struct { + SwigcptrExample2 + v interface{} +} + +func (p *_swig_DirectorExample2) Swigcptr() uintptr { + return p.SwigcptrExample2.Swigcptr() +} + +func (p *_swig_DirectorExample2) SwigIsExample2() { +} + +func (p *_swig_DirectorExample2) DirectorInterface() interface{} { + return p.v +} + +var _wrap__swig_NewDirectorExample2Example2__SWIG_0 unsafe.Pointer + +func _swig_NewDirectorExample2Example2__SWIG_0(_swig_director *_swig_DirectorExample2, _ int) (_swig_ret SwigcptrExample2) { + _swig_p := uintptr(unsafe.Pointer(&_swig_director)) + _cgo_runtime_cgocall(_wrap__swig_NewDirectorExample2Example2__SWIG_0, _swig_p) + return +} + +func NewDirectorExample2__SWIG_0(v interface{}, arg1 int) Example2 { + p := &_swig_DirectorExample2{0, v} + p.SwigcptrExample2 = _swig_NewDirectorExample2Example2__SWIG_0(p, arg1) + return p +} + +var _wrap__swig_NewDirectorExample2Example2__SWIG_1 unsafe.Pointer + +func _swig_NewDirectorExample2Example2__SWIG_1(_swig_director *_swig_DirectorExample2, _ int, _ int) (_swig_ret SwigcptrExample2) { + _swig_p := uintptr(unsafe.Pointer(&_swig_director)) + _cgo_runtime_cgocall(_wrap__swig_NewDirectorExample2Example2__SWIG_1, _swig_p) + return +} + +func NewDirectorExample2__SWIG_1(v interface{}, arg1 int, arg2 int) Example2 { + p := &_swig_DirectorExample2{0, v} + p.SwigcptrExample2 = _swig_NewDirectorExample2Example2__SWIG_1(p, arg1, arg2) + return p +} + +func NewDirectorExample2(abi interface{}, a ...interface{}) Example2 { + argc := len(a) + if argc == 1 { + return NewDirectorExample2__SWIG_0(abi, a[0].(int)) + } + if argc == 2 { + return NewDirectorExample2__SWIG_1(abi, a[0].(int), a[1].(int)) + } + panic("No match for overloaded function call") +} + +var _wrap_DeleteDirectorExample2 unsafe.Pointer + +func _swig_wrap_DeleteDirectorExample2(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_DeleteDirectorExample2, _swig_p) + return +} + +func DeleteDirectorExample2(arg1 Example2) { + _swig_wrap_DeleteDirectorExample2(arg1.Swigcptr()) +} + +func Swiggo_DeleteDirector_Example2(p *_swig_DirectorExample2) { + p.SwigcptrExample2 = 0 +} + +type _swig_DirectorInterfaceExample2Color interface { + Color(byte, byte, byte) int +} + +func (swig_p *_swig_DirectorExample2) Color(r byte, g byte, b byte) int { + if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceExample2Color); swig_ok { + return swig_g.Color(r, g, b) + } + panic("call to pure virtual method") +} + +func Swig_DirectorExample2_callback_Color(p *_swig_DirectorExample2, r byte, g byte, b byte) (swig_result int) { + var swig_r int + swig_r = p.Color(r, g, b) + return swig_r +} + +type SwigcptrExample2 uintptr + +func (p SwigcptrExample2) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrExample2) SwigIsExample2() { +} + +func (p SwigcptrExample2) DirectorInterface() interface{} { + return nil +} + +var _wrap_new_Example2__SWIG_0 unsafe.Pointer + +func _swig_wrap_new_Example2__SWIG_0(base int) (_ SwigcptrExample2) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Example2__SWIG_0, _swig_p) + return +} + +func NewExample2__SWIG_0(arg1 int) (_swig_ret Example2) { + return _swig_wrap_new_Example2__SWIG_0(arg1) +} + +var _wrap_new_Example2__SWIG_1 unsafe.Pointer + +func _swig_wrap_new_Example2__SWIG_1(base int, _ int) (_ SwigcptrExample2) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Example2__SWIG_1, _swig_p) + return +} + +func NewExample2__SWIG_1(arg1 int, arg2 int) (_swig_ret Example2) { + return _swig_wrap_new_Example2__SWIG_1(arg1, arg2) +} + +func NewExample2(a ...interface{}) Example2 { + argc := len(a) + if argc == 1 { + return NewExample2__SWIG_0(a[0].(int)) + } + if argc == 2 { + return NewExample2__SWIG_1(a[0].(int), a[1].(int)) + } + panic("No match for overloaded function call") +} + +var _wrap_delete_Example2 unsafe.Pointer + +func _swig_wrap_delete_Example2(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Example2, _swig_p) + return +} + +func DeleteExample2(arg1 Example2) { + _swig_wrap_delete_Example2(arg1.Swigcptr()) +} + +var _wrap_Example2_GetXSize unsafe.Pointer + +func _swig_wrap_Example2_GetXSize(base SwigcptrExample2) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Example2_GetXSize, _swig_p) + return +} + +func (arg1 SwigcptrExample2) GetXSize() (_swig_ret int) { + return _swig_wrap_Example2_GetXSize(arg1) +} + +var _wrap_Example2_Color unsafe.Pointer + +func _swig_wrap_Example2_Color(base SwigcptrExample2, _ byte, _ byte, _ byte) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Example2_Color, _swig_p) + return +} + +func (arg1 SwigcptrExample2) Color(arg2 byte, arg3 byte, arg4 byte) (_swig_ret int) { + return _swig_wrap_Example2_Color(arg1, arg2, arg3, arg4) +} + +var _wrap_Example2_get_color unsafe.Pointer + +func _swig_wrap_Example2_get_color(base uintptr, _ byte, _ byte, _ byte) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Example2_get_color, _swig_p) + return +} + +func Example2Get_color(arg1 Example2, arg2 byte, arg3 byte, arg4 byte) (_swig_ret int) { + return _swig_wrap_Example2_get_color(arg1.Swigcptr(), arg2, arg3, arg4) +} + +type Example2 interface { + Swigcptr() uintptr + SwigIsExample2() + DirectorInterface() interface{} + GetXSize() (_swig_ret int) + Color(arg2 byte, arg3 byte, arg4 byte) (_swig_ret int) +} + +type _swig_DirectorExample4 struct { + SwigcptrExample4 + v interface{} +} + +func (p *_swig_DirectorExample4) Swigcptr() uintptr { + return p.SwigcptrExample4.Swigcptr() +} + +func (p *_swig_DirectorExample4) SwigIsExample4() { +} + +func (p *_swig_DirectorExample4) DirectorInterface() interface{} { + return p.v +} + +var _wrap__swig_NewDirectorExample4Example4__SWIG_0 unsafe.Pointer + +func _swig_NewDirectorExample4Example4__SWIG_0(_swig_director *_swig_DirectorExample4) (_swig_ret SwigcptrExample4) { + _swig_p := uintptr(unsafe.Pointer(&_swig_director)) + _cgo_runtime_cgocall(_wrap__swig_NewDirectorExample4Example4__SWIG_0, _swig_p) + return +} + +func NewDirectorExample4__SWIG_0(v interface{}) Example4 { + p := &_swig_DirectorExample4{0, v} + p.SwigcptrExample4 = _swig_NewDirectorExample4Example4__SWIG_0(p) + return p +} + +var _wrap__swig_NewDirectorExample4Example4__SWIG_1 unsafe.Pointer + +func _swig_NewDirectorExample4Example4__SWIG_1(_swig_director *_swig_DirectorExample4, _ int, _ int) (_swig_ret SwigcptrExample4) { + _swig_p := uintptr(unsafe.Pointer(&_swig_director)) + _cgo_runtime_cgocall(_wrap__swig_NewDirectorExample4Example4__SWIG_1, _swig_p) + return +} + +func NewDirectorExample4__SWIG_1(v interface{}, arg1 int, arg2 int) Example4 { + p := &_swig_DirectorExample4{0, v} + p.SwigcptrExample4 = _swig_NewDirectorExample4Example4__SWIG_1(p, arg1, arg2) + return p +} + +func NewDirectorExample4(abi interface{}, a ...interface{}) Example4 { + argc := len(a) + if argc == 0 { + return NewDirectorExample4__SWIG_0(abi) + } + if argc == 2 { + return NewDirectorExample4__SWIG_1(abi, a[0].(int), a[1].(int)) + } + panic("No match for overloaded function call") +} + +var _wrap_DeleteDirectorExample4 unsafe.Pointer + +func _swig_wrap_DeleteDirectorExample4(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_DeleteDirectorExample4, _swig_p) + return +} + +func DeleteDirectorExample4(arg1 Example4) { + _swig_wrap_DeleteDirectorExample4(arg1.Swigcptr()) +} + +func Swiggo_DeleteDirector_Example4(p *_swig_DirectorExample4) { + p.SwigcptrExample4 = 0 +} + +type _swig_DirectorInterfaceExample4Color interface { + Color(byte, byte, byte) int +} + +func (swig_p *_swig_DirectorExample4) Color(r byte, g byte, b byte) int { + if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceExample4Color); swig_ok { + return swig_g.Color(r, g, b) + } + panic("call to pure virtual method") +} + +func Swig_DirectorExample4_callback_Color(p *_swig_DirectorExample4, r byte, g byte, b byte) (swig_result int) { + var swig_r int + swig_r = p.Color(r, g, b) + return swig_r +} + +type SwigcptrExample4 uintptr + +func (p SwigcptrExample4) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrExample4) SwigIsExample4() { +} + +func (p SwigcptrExample4) DirectorInterface() interface{} { + return nil +} + +var _wrap_new_Example4__SWIG_0 unsafe.Pointer + +func _swig_wrap_new_Example4__SWIG_0() (base SwigcptrExample4) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Example4__SWIG_0, _swig_p) + return +} + +func NewExample4__SWIG_0() (_swig_ret Example4) { + return _swig_wrap_new_Example4__SWIG_0() +} + +var _wrap_new_Example4__SWIG_1 unsafe.Pointer + +func _swig_wrap_new_Example4__SWIG_1(base int, _ int) (_ SwigcptrExample4) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Example4__SWIG_1, _swig_p) + return +} + +func NewExample4__SWIG_1(arg1 int, arg2 int) (_swig_ret Example4) { + return _swig_wrap_new_Example4__SWIG_1(arg1, arg2) +} + +func NewExample4(a ...interface{}) Example4 { + argc := len(a) + if argc == 0 { + return NewExample4__SWIG_0() + } + if argc == 2 { + return NewExample4__SWIG_1(a[0].(int), a[1].(int)) + } + panic("No match for overloaded function call") +} + +var _wrap_delete_Example4 unsafe.Pointer + +func _swig_wrap_delete_Example4(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Example4, _swig_p) + return +} + +func DeleteExample4(arg1 Example4) { + _swig_wrap_delete_Example4(arg1.Swigcptr()) +} + +var _wrap_Example4_GetXSize unsafe.Pointer + +func _swig_wrap_Example4_GetXSize(base SwigcptrExample4) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Example4_GetXSize, _swig_p) + return +} + +func (arg1 SwigcptrExample4) GetXSize() (_swig_ret int) { + return _swig_wrap_Example4_GetXSize(arg1) +} + +var _wrap_Example4_Color unsafe.Pointer + +func _swig_wrap_Example4_Color(base SwigcptrExample4, _ byte, _ byte, _ byte) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Example4_Color, _swig_p) + return +} + +func (arg1 SwigcptrExample4) Color(arg2 byte, arg3 byte, arg4 byte) (_swig_ret int) { + return _swig_wrap_Example4_Color(arg1, arg2, arg3, arg4) +} + +var _wrap_Example4_get_color unsafe.Pointer + +func _swig_wrap_Example4_get_color(base uintptr, _ byte, _ byte, _ byte) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Example4_get_color, _swig_p) + return +} + +func Example4Get_color(arg1 Example4, arg2 byte, arg3 byte, arg4 byte) (_swig_ret int) { + return _swig_wrap_Example4_get_color(arg1.Swigcptr(), arg2, arg3, arg4) +} + +type Example4 interface { + Swigcptr() uintptr + SwigIsExample4() + DirectorInterface() interface{} + GetXSize() (_swig_ret int) + Color(arg2 byte, arg3 byte, arg4 byte) (_swig_ret int) +} + +type _swig_DirectorExample3_i struct { + SwigcptrExample3_i + v interface{} +} + +func (p *_swig_DirectorExample3_i) Swigcptr() uintptr { + return p.SwigcptrExample3_i.Swigcptr() +} + +func (p *_swig_DirectorExample3_i) SwigIsExample3_i() { +} + +func (p *_swig_DirectorExample3_i) DirectorInterface() interface{} { + return p.v +} + +var _wrap__swig_NewDirectorExample3_iExample3_i__SWIG_0 unsafe.Pointer + +func _swig_NewDirectorExample3_iExample3_i__SWIG_0(_swig_director *_swig_DirectorExample3_i) (_swig_ret SwigcptrExample3_i) { + _swig_p := uintptr(unsafe.Pointer(&_swig_director)) + _cgo_runtime_cgocall(_wrap__swig_NewDirectorExample3_iExample3_i__SWIG_0, _swig_p) + return +} + +func NewDirectorExample3_i__SWIG_0(v interface{}) Example3_i { + p := &_swig_DirectorExample3_i{0, v} + p.SwigcptrExample3_i = _swig_NewDirectorExample3_iExample3_i__SWIG_0(p) + return p +} + +var _wrap__swig_NewDirectorExample3_iExample3_i__SWIG_1 unsafe.Pointer + +func _swig_NewDirectorExample3_iExample3_i__SWIG_1(_swig_director *_swig_DirectorExample3_i, _ int) (_swig_ret SwigcptrExample3_i) { + _swig_p := uintptr(unsafe.Pointer(&_swig_director)) + _cgo_runtime_cgocall(_wrap__swig_NewDirectorExample3_iExample3_i__SWIG_1, _swig_p) + return +} + +func NewDirectorExample3_i__SWIG_1(v interface{}, arg1 int) Example3_i { + p := &_swig_DirectorExample3_i{0, v} + p.SwigcptrExample3_i = _swig_NewDirectorExample3_iExample3_i__SWIG_1(p, arg1) + return p +} + +var _wrap__swig_NewDirectorExample3_iExample3_i__SWIG_2 unsafe.Pointer + +func _swig_NewDirectorExample3_iExample3_i__SWIG_2(_swig_director *_swig_DirectorExample3_i, _ int, _ int) (_swig_ret SwigcptrExample3_i) { + _swig_p := uintptr(unsafe.Pointer(&_swig_director)) + _cgo_runtime_cgocall(_wrap__swig_NewDirectorExample3_iExample3_i__SWIG_2, _swig_p) + return +} + +func NewDirectorExample3_i__SWIG_2(v interface{}, arg1 int, arg2 int) Example3_i { + p := &_swig_DirectorExample3_i{0, v} + p.SwigcptrExample3_i = _swig_NewDirectorExample3_iExample3_i__SWIG_2(p, arg1, arg2) + return p +} + +func NewDirectorExample3_i(abi interface{}, a ...interface{}) Example3_i { + argc := len(a) + if argc == 0 { + return NewDirectorExample3_i__SWIG_0(abi) + } + if argc == 1 { + return NewDirectorExample3_i__SWIG_1(abi, a[0].(int)) + } + if argc == 2 { + return NewDirectorExample3_i__SWIG_2(abi, a[0].(int), a[1].(int)) + } + panic("No match for overloaded function call") +} + +var _wrap_DeleteDirectorExample3_i unsafe.Pointer + +func _swig_wrap_DeleteDirectorExample3_i(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_DeleteDirectorExample3_i, _swig_p) + return +} + +func DeleteDirectorExample3_i(arg1 Example3_i) { + _swig_wrap_DeleteDirectorExample3_i(arg1.Swigcptr()) +} + +func Swiggo_DeleteDirector_Example3_i(p *_swig_DirectorExample3_i) { + p.SwigcptrExample3_i = 0 +} + +type _swig_DirectorInterfaceExample3_iColor interface { + Color(byte, byte, byte) int +} + +func (swig_p *_swig_DirectorExample3_i) Color(r byte, g byte, b byte) int { + if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceExample3_iColor); swig_ok { + return swig_g.Color(r, g, b) + } + panic("call to pure virtual method") +} + +func Swig_DirectorExample3_i_callback_Color(p *_swig_DirectorExample3_i, r byte, g byte, b byte) (swig_result int) { + var swig_r int + swig_r = p.Color(r, g, b) + return swig_r +} + +type SwigcptrExample3_i uintptr + +func (p SwigcptrExample3_i) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrExample3_i) SwigIsExample3_i() { +} + +func (p SwigcptrExample3_i) DirectorInterface() interface{} { + return nil +} + +var _wrap_new_Example3_i__SWIG_0 unsafe.Pointer + +func _swig_wrap_new_Example3_i__SWIG_0() (base SwigcptrExample3_i) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Example3_i__SWIG_0, _swig_p) + return +} + +func NewExample3_i__SWIG_0() (_swig_ret Example3_i) { + return _swig_wrap_new_Example3_i__SWIG_0() +} + +var _wrap_new_Example3_i__SWIG_1 unsafe.Pointer + +func _swig_wrap_new_Example3_i__SWIG_1(base int) (_ SwigcptrExample3_i) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Example3_i__SWIG_1, _swig_p) + return +} + +func NewExample3_i__SWIG_1(arg1 int) (_swig_ret Example3_i) { + return _swig_wrap_new_Example3_i__SWIG_1(arg1) +} + +var _wrap_new_Example3_i__SWIG_2 unsafe.Pointer + +func _swig_wrap_new_Example3_i__SWIG_2(base int, _ int) (_ SwigcptrExample3_i) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Example3_i__SWIG_2, _swig_p) + return +} + +func NewExample3_i__SWIG_2(arg1 int, arg2 int) (_swig_ret Example3_i) { + return _swig_wrap_new_Example3_i__SWIG_2(arg1, arg2) +} + +func NewExample3_i(a ...interface{}) Example3_i { + argc := len(a) + if argc == 0 { + return NewExample3_i__SWIG_0() + } + if argc == 1 { + return NewExample3_i__SWIG_1(a[0].(int)) + } + if argc == 2 { + return NewExample3_i__SWIG_2(a[0].(int), a[1].(int)) + } + panic("No match for overloaded function call") +} + +var _wrap_delete_Example3_i unsafe.Pointer + +func _swig_wrap_delete_Example3_i(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Example3_i, _swig_p) + return +} + +func DeleteExample3_i(arg1 Example3_i) { + _swig_wrap_delete_Example3_i(arg1.Swigcptr()) +} + +var _wrap_Example3_i_Color unsafe.Pointer + +func _swig_wrap_Example3_i_Color(base SwigcptrExample3_i, _ byte, _ byte, _ byte) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Example3_i_Color, _swig_p) + return +} + +func (arg1 SwigcptrExample3_i) Color(arg2 byte, arg3 byte, arg4 byte) (_swig_ret int) { + return _swig_wrap_Example3_i_Color(arg1, arg2, arg3, arg4) +} + +var _wrap_Example3_i_get_color unsafe.Pointer + +func _swig_wrap_Example3_i_get_color(base uintptr, _ byte, _ byte, _ byte) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Example3_i_get_color, _swig_p) + return +} + +func Example3_iGet_color(arg1 Example3_i, arg2 byte, arg3 byte, arg4 byte) (_swig_ret int) { + return _swig_wrap_Example3_i_get_color(arg1.Swigcptr(), arg2, arg3, arg4) +} + +type Example3_i interface { + Swigcptr() uintptr + SwigIsExample3_i() + DirectorInterface() interface{} + Color(arg2 byte, arg3 byte, arg4 byte) (_swig_ret int) +} + +type _swig_DirectorA struct { + SwigcptrA + v interface{} +} + +func (p *_swig_DirectorA) Swigcptr() uintptr { + return p.SwigcptrA.Swigcptr() +} + +func (p *_swig_DirectorA) SwigIsA() { +} + +func (p *_swig_DirectorA) DirectorInterface() interface{} { + return p.v +} + +var _wrap__swig_NewDirectorAA unsafe.Pointer + +func _swig_NewDirectorAA(_swig_director *_swig_DirectorA, _ A) (_swig_ret SwigcptrA) { + _swig_p := uintptr(unsafe.Pointer(&_swig_director)) + _cgo_runtime_cgocall(_wrap__swig_NewDirectorAA, _swig_p) + return +} + +func NewDirectorA(v interface{}, arg1 A) A { + p := &_swig_DirectorA{0, v} + p.SwigcptrA = _swig_NewDirectorAA(p, arg1) + return p +} + +var _wrap_DeleteDirectorA unsafe.Pointer + +func _swig_wrap_DeleteDirectorA(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_DeleteDirectorA, _swig_p) + return +} + +func DeleteDirectorA(arg1 A) { + _swig_wrap_DeleteDirectorA(arg1.Swigcptr()) +} + +func Swiggo_DeleteDirector_A(p *_swig_DirectorA) { + p.SwigcptrA = 0 +} + +type _swig_DirectorInterfaceAF interface { + F() int +} + +func (swig_p *_swig_DirectorA) F() int { + if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceAF); swig_ok { + return swig_g.F() + } + panic("call to pure virtual method") +} + +func Swig_DirectorA_callback_f(p *_swig_DirectorA) (swig_result int) { + var swig_r int + swig_r = p.F() + return swig_r +} + +type SwigcptrA uintptr + +func (p SwigcptrA) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrA) SwigIsA() { +} + +func (p SwigcptrA) DirectorInterface() interface{} { + return nil +} + +var _wrap_delete_A unsafe.Pointer + +func _swig_wrap_delete_A(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_A, _swig_p) + return +} + +func DeleteA(arg1 A) { + _swig_wrap_delete_A(arg1.Swigcptr()) +} + +var _wrap_g unsafe.Pointer + +func _swig_wrap_g(base uintptr) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_g, _swig_p) + return +} + +func G(arg1 A) (_swig_ret int) { + return _swig_wrap_g(arg1.Swigcptr()) +} + +var _wrap_new_A unsafe.Pointer + +func _swig_wrap_new_A(base uintptr) (_ SwigcptrA) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_A, _swig_p) + return +} + +func NewA(arg1 A) (_swig_ret A) { + return _swig_wrap_new_A(arg1.Swigcptr()) +} + +type A interface { + Swigcptr() uintptr + SwigIsA() + DirectorInterface() interface{} +} + + +type SwigcptrSwigDirector_Example0 uintptr +type SwigDirector_Example0 interface { + Swigcptr() uintptr; +} +func (p SwigcptrSwigDirector_Example0) Swigcptr() uintptr { + return uintptr(p) +} + +type SwigcptrSwigDirector_Foo uintptr +type SwigDirector_Foo interface { + Swigcptr() uintptr; +} +func (p SwigcptrSwigDirector_Foo) Swigcptr() uintptr { + return uintptr(p) +} + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/director_abstract_wrap.h b/Examples/test-suite/go/director_abstract_wrap.h new file mode 100644 index 000000000..a2b4e51ee --- /dev/null +++ b/Examples/test-suite/go/director_abstract_wrap.h @@ -0,0 +1,99 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../director_abstract.i + +#ifndef SWIG_director_abstract_WRAP_H_ +#define SWIG_director_abstract_WRAP_H_ + +class SwigDirector_Foo : public Foo +{ + public: + SwigDirector_Foo(void *swig_p); + virtual ~SwigDirector_Foo(); + virtual std::string ping(); + std::string _swig_upcall_pong() { + return Foo::pong(); + } + virtual std::string pong(); + private: + void *go_val; +}; + +class SwigDirector_Example0 : public Example0 +{ + public: + SwigDirector_Example0(void *swig_p, int x, int y); + SwigDirector_Example0(void *swig_p); + virtual ~SwigDirector_Example0(); + int _swig_upcall_Color(unsigned char r, unsigned char g, unsigned char b) { + return Example0::Color(r,g,b); + } + virtual int Color(unsigned char r, unsigned char g, unsigned char b); + private: + void *go_val; +}; + +class SwigDirector_Example1 : public Example1 +{ + public: + SwigDirector_Example1(void *swig_p, int x, int y); + SwigDirector_Example1(void *swig_p); + virtual ~SwigDirector_Example1(); + virtual int Color(unsigned char r, unsigned char g, unsigned char b); + private: + void *go_val; +}; + +class SwigDirector_Example2 : public Example2 +{ + public: + SwigDirector_Example2(void *swig_p, int x); + SwigDirector_Example2(void *swig_p, int x, int y); + virtual ~SwigDirector_Example2(); + virtual int Color(unsigned char r, unsigned char g, unsigned char b); + private: + void *go_val; +}; + +class SwigDirector_Example4 : public Example4 +{ + public: + SwigDirector_Example4(void *swig_p); + SwigDirector_Example4(void *swig_p, int x, int y); + virtual ~SwigDirector_Example4(); + virtual int Color(unsigned char r, unsigned char g, unsigned char b); + private: + void *go_val; +}; + +class SwigDirector_Example3_i : public ns::Example3< int > +{ + public: + SwigDirector_Example3_i(void *swig_p); + SwigDirector_Example3_i(void *swig_p, int x); + SwigDirector_Example3_i(void *swig_p, int x, int y); + virtual ~SwigDirector_Example3_i(); + virtual int Color(unsigned char r, unsigned char g, unsigned char b); + private: + void *go_val; +}; + +class SwigDirector_A : public A +{ + public: + SwigDirector_A(void *swig_p, A const &arg0); + virtual ~SwigDirector_A(); + virtual int f(); + private: + void *go_val; +}; + +#endif diff --git a/Examples/test-suite/go/director_alternating.go b/Examples/test-suite/go/director_alternating.go new file mode 100644 index 000000000..4f83b3c91 --- /dev/null +++ b/Examples/test-suite/go/director_alternating.go @@ -0,0 +1,328 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../director_alternating.i + +package director_alternating + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type _swig_DirectorFoo struct { + SwigcptrFoo + v interface{} +} + +func (p *_swig_DirectorFoo) Swigcptr() uintptr { + return p.SwigcptrFoo.Swigcptr() +} + +func (p *_swig_DirectorFoo) SwigIsFoo() { +} + +func (p *_swig_DirectorFoo) DirectorInterface() interface{} { + return p.v +} + +var _wrap__swig_NewDirectorFooFoo unsafe.Pointer + +func _swig_NewDirectorFooFoo(_swig_director *_swig_DirectorFoo) (_swig_ret SwigcptrFoo) { + _swig_p := uintptr(unsafe.Pointer(&_swig_director)) + _cgo_runtime_cgocall(_wrap__swig_NewDirectorFooFoo, _swig_p) + return +} + +func NewDirectorFoo(v interface{}) Foo { + p := &_swig_DirectorFoo{0, v} + p.SwigcptrFoo = _swig_NewDirectorFooFoo(p) + return p +} + +var _wrap_DeleteDirectorFoo unsafe.Pointer + +func _swig_wrap_DeleteDirectorFoo(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_DeleteDirectorFoo, _swig_p) + return +} + +func DeleteDirectorFoo(arg1 Foo) { + _swig_wrap_DeleteDirectorFoo(arg1.Swigcptr()) +} + +func Swiggo_DeleteDirector_Foo(p *_swig_DirectorFoo) { + p.SwigcptrFoo = 0 +} + +type _swig_DirectorInterfaceFooId interface { + Id() int +} + +var _wrap__swig_DirectorFoo_upcall_Id unsafe.Pointer + +func _swig_wrap__swig_DirectorFoo_upcall_Id(_swig_ptr SwigcptrFoo) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) + _cgo_runtime_cgocall(_wrap__swig_DirectorFoo_upcall_Id, _swig_p) + return +} + +func (swig_p *_swig_DirectorFoo) Id() int { + if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceFooId); swig_ok { + return swig_g.Id() + } + var swig_r int + swig_r = _swig_wrap__swig_DirectorFoo_upcall_Id(swig_p.SwigcptrFoo) + return swig_r +} + +func DirectorFooId(p Foo) int { + var swig_r int + swig_r = _swig_wrap__swig_DirectorFoo_upcall_Id(p.(*_swig_DirectorFoo).SwigcptrFoo) + return swig_r +} + +func Swig_DirectorFoo_callback_id(p *_swig_DirectorFoo) (swig_result int) { + var swig_r int + swig_r = p.Id() + return swig_r +} + +type SwigcptrFoo uintptr + +func (p SwigcptrFoo) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrFoo) SwigIsFoo() { +} + +func (p SwigcptrFoo) DirectorInterface() interface{} { + return nil +} + +var _wrap_delete_Foo unsafe.Pointer + +func _swig_wrap_delete_Foo(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Foo, _swig_p) + return +} + +func DeleteFoo(arg1 Foo) { + _swig_wrap_delete_Foo(arg1.Swigcptr()) +} + +var _wrap_Foo_id unsafe.Pointer + +func _swig_wrap_Foo_id(base SwigcptrFoo) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_id, _swig_p) + return +} + +func (arg1 SwigcptrFoo) Id() (_swig_ret int) { + return _swig_wrap_Foo_id(arg1) +} + +var _wrap_new_Foo unsafe.Pointer + +func _swig_wrap_new_Foo() (base SwigcptrFoo) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Foo, _swig_p) + return +} + +func NewFoo() (_swig_ret Foo) { + return _swig_wrap_new_Foo() +} + +type Foo interface { + Swigcptr() uintptr + SwigIsFoo() + DirectorInterface() interface{} + Id() (_swig_ret int) +} + +type SwigcptrBar uintptr + +func (p SwigcptrBar) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrBar) SwigIsBar() { +} + +var _wrap_new_Bar unsafe.Pointer + +func _swig_wrap_new_Bar() (base SwigcptrBar) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Bar, _swig_p) + return +} + +func NewBar() (_swig_ret Bar) { + return _swig_wrap_new_Bar() +} + +var _wrap_delete_Bar unsafe.Pointer + +func _swig_wrap_delete_Bar(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Bar, _swig_p) + return +} + +func DeleteBar(arg1 Bar) { + _swig_wrap_delete_Bar(arg1.Swigcptr()) +} + +var _wrap_Bar_id unsafe.Pointer + +func _swig_wrap_Bar_id(base SwigcptrBar) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Bar_id, _swig_p) + return +} + +func (_swig_base SwigcptrBar) Id() (_swig_ret int) { + return _swig_wrap_Bar_id(_swig_base) +} + +func (p SwigcptrBar) SwigIsFoo() { +} + +func (p SwigcptrBar) SwigGetFoo() Foo { + return SwigcptrFoo(p.Swigcptr()) +} + +type Bar interface { + Swigcptr() uintptr + SwigIsBar() + Id() (_swig_ret int) + SwigIsFoo() + SwigGetFoo() Foo +} + +type SwigcptrBaz uintptr + +func (p SwigcptrBaz) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrBaz) SwigIsBaz() { +} + +var _wrap_Baz_id unsafe.Pointer + +func _swig_wrap_Baz_id(base SwigcptrBaz) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Baz_id, _swig_p) + return +} + +func (arg1 SwigcptrBaz) Id() (_swig_ret int) { + return _swig_wrap_Baz_id(arg1) +} + +var _wrap_new_Baz unsafe.Pointer + +func _swig_wrap_new_Baz() (base SwigcptrBaz) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Baz, _swig_p) + return +} + +func NewBaz() (_swig_ret Baz) { + return _swig_wrap_new_Baz() +} + +var _wrap_delete_Baz unsafe.Pointer + +func _swig_wrap_delete_Baz(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Baz, _swig_p) + return +} + +func DeleteBaz(arg1 Baz) { + _swig_wrap_delete_Baz(arg1.Swigcptr()) +} + +func (p SwigcptrBaz) SwigIsBar() { +} + +func (p SwigcptrBaz) SwigGetBar() Bar { + return SwigcptrBar(p.Swigcptr()) +} + +func (p SwigcptrBaz) SwigIsFoo() { +} + +func (p SwigcptrBaz) SwigGetFoo() Foo { + return SwigcptrFoo(p.Swigcptr()) +} + +type Baz interface { + Swigcptr() uintptr + SwigIsBaz() + Id() (_swig_ret int) + SwigIsBar() + SwigGetBar() Bar + SwigIsFoo() + SwigGetFoo() Foo +} + +var _wrap_getBar unsafe.Pointer + +func _swig_wrap_getBar() (base SwigcptrBar) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_getBar, _swig_p) + return +} + +func GetBar() (_swig_ret Bar) { + return _swig_wrap_getBar() +} + +var _wrap_idFromGetBar unsafe.Pointer + +func IdFromGetBar() (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_idFromGetBar, _swig_p) + return +} + +type SwigcptrSwigDirector_Foo uintptr +type SwigDirector_Foo interface { + Swigcptr() uintptr; +} +func (p SwigcptrSwigDirector_Foo) Swigcptr() uintptr { + return uintptr(p) +} + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/director_alternating_runme b/Examples/test-suite/go/director_alternating_runme new file mode 100755 index 000000000..44454efb3 Binary files /dev/null and b/Examples/test-suite/go/director_alternating_runme differ diff --git a/Examples/test-suite/go/director_alternating_wrap.h b/Examples/test-suite/go/director_alternating_wrap.h new file mode 100644 index 000000000..651935066 --- /dev/null +++ b/Examples/test-suite/go/director_alternating_wrap.h @@ -0,0 +1,29 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../director_alternating.i + +#ifndef SWIG_director_alternating_WRAP_H_ +#define SWIG_director_alternating_WRAP_H_ + +class SwigDirector_Foo : public Foo +{ + public: + SwigDirector_Foo(void *swig_p); + virtual ~SwigDirector_Foo(); + int _swig_upcall_id() { + return Foo::id(); + } + virtual int id(); + private: + void *go_val; +}; + +#endif diff --git a/Examples/test-suite/go/director_basic.go b/Examples/test-suite/go/director_basic.go new file mode 100644 index 000000000..f16bcd816 --- /dev/null +++ b/Examples/test-suite/go/director_basic.go @@ -0,0 +1,1420 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../director_basic.i + +package director_basic + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type _swig_DirectorFoo struct { + SwigcptrFoo + v interface{} +} + +func (p *_swig_DirectorFoo) Swigcptr() uintptr { + return p.SwigcptrFoo.Swigcptr() +} + +func (p *_swig_DirectorFoo) SwigIsFoo() { +} + +func (p *_swig_DirectorFoo) DirectorInterface() interface{} { + return p.v +} + +var _wrap__swig_NewDirectorFooFoo unsafe.Pointer + +func _swig_NewDirectorFooFoo(_swig_director *_swig_DirectorFoo) (_swig_ret SwigcptrFoo) { + _swig_p := uintptr(unsafe.Pointer(&_swig_director)) + _cgo_runtime_cgocall(_wrap__swig_NewDirectorFooFoo, _swig_p) + return +} + +func NewDirectorFoo(v interface{}) Foo { + p := &_swig_DirectorFoo{0, v} + p.SwigcptrFoo = _swig_NewDirectorFooFoo(p) + return p +} + +var _wrap_DeleteDirectorFoo unsafe.Pointer + +func _swig_wrap_DeleteDirectorFoo(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_DeleteDirectorFoo, _swig_p) + return +} + +func DeleteDirectorFoo(arg1 Foo) { + _swig_wrap_DeleteDirectorFoo(arg1.Swigcptr()) +} + +func Swiggo_DeleteDirector_Foo(p *_swig_DirectorFoo) { + p.SwigcptrFoo = 0 +} + +type _swig_DirectorInterfaceFooPing interface { + Ping() string +} + +var _wrap__swig_DirectorFoo_upcall_Ping unsafe.Pointer + +func _swig_wrap__swig_DirectorFoo_upcall_Ping(_swig_ptr SwigcptrFoo) (_swig_ret string) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) + _cgo_runtime_cgocall(_wrap__swig_DirectorFoo_upcall_Ping, _swig_p) + return +} + +func (swig_p *_swig_DirectorFoo) Ping() string { + if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceFooPing); swig_ok { + return swig_g.Ping() + } + var swig_r string + swig_r = _swig_wrap__swig_DirectorFoo_upcall_Ping(swig_p.SwigcptrFoo) + return swig_r +} + +func DirectorFooPing(p Foo) string { + var swig_r string + swig_r = _swig_wrap__swig_DirectorFoo_upcall_Ping(p.(*_swig_DirectorFoo).SwigcptrFoo) + return swig_r +} + +func Swig_DirectorFoo_callback_ping(p *_swig_DirectorFoo) (swig_result string) { + var swig_r string + swig_r = p.Ping() + return swig_r +} + +type _swig_DirectorInterfaceFooPong interface { + Pong() string +} + +var _wrap__swig_DirectorFoo_upcall_Pong unsafe.Pointer + +func _swig_wrap__swig_DirectorFoo_upcall_Pong(_swig_ptr SwigcptrFoo) (_swig_ret string) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) + _cgo_runtime_cgocall(_wrap__swig_DirectorFoo_upcall_Pong, _swig_p) + return +} + +func (swig_p *_swig_DirectorFoo) Pong() string { + if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceFooPong); swig_ok { + return swig_g.Pong() + } + var swig_r string + swig_r = _swig_wrap__swig_DirectorFoo_upcall_Pong(swig_p.SwigcptrFoo) + return swig_r +} + +func DirectorFooPong(p Foo) string { + var swig_r string + swig_r = _swig_wrap__swig_DirectorFoo_upcall_Pong(p.(*_swig_DirectorFoo).SwigcptrFoo) + return swig_r +} + +func Swig_DirectorFoo_callback_pong(p *_swig_DirectorFoo) (swig_result string) { + var swig_r string + swig_r = p.Pong() + return swig_r +} + +type SwigcptrFoo uintptr + +func (p SwigcptrFoo) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrFoo) SwigIsFoo() { +} + +func (p SwigcptrFoo) DirectorInterface() interface{} { + return nil +} + +var _wrap_delete_Foo unsafe.Pointer + +func _swig_wrap_delete_Foo(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Foo, _swig_p) + return +} + +func DeleteFoo(arg1 Foo) { + _swig_wrap_delete_Foo(arg1.Swigcptr()) +} + +var _wrap_Foo_ping unsafe.Pointer + +func _swig_wrap_Foo_ping(base SwigcptrFoo) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_ping, _swig_p) + return +} + +func (arg1 SwigcptrFoo) Ping() (_swig_ret string) { + return _swig_wrap_Foo_ping(arg1) +} + +var _wrap_Foo_pong unsafe.Pointer + +func _swig_wrap_Foo_pong(base SwigcptrFoo) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_pong, _swig_p) + return +} + +func (arg1 SwigcptrFoo) Pong() (_swig_ret string) { + return _swig_wrap_Foo_pong(arg1) +} + +var _wrap_Foo_get_self unsafe.Pointer + +func _swig_wrap_Foo_get_self(base uintptr) (_ SwigcptrFoo) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_get_self, _swig_p) + return +} + +func FooGet_self(arg1 Foo) (_swig_ret Foo) { + return _swig_wrap_Foo_get_self(arg1.Swigcptr()) +} + +var _wrap_new_Foo unsafe.Pointer + +func _swig_wrap_new_Foo() (base SwigcptrFoo) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Foo, _swig_p) + return +} + +func NewFoo() (_swig_ret Foo) { + return _swig_wrap_new_Foo() +} + +type Foo interface { + Swigcptr() uintptr + SwigIsFoo() + DirectorInterface() interface{} + Ping() (_swig_ret string) + Pong() (_swig_ret string) +} + +type _swig_DirectorA struct { + SwigcptrA + v interface{} +} + +func (p *_swig_DirectorA) Swigcptr() uintptr { + return p.SwigcptrA.Swigcptr() +} + +func (p *_swig_DirectorA) SwigIsA() { +} + +func (p *_swig_DirectorA) DirectorInterface() interface{} { + return p.v +} + +var _wrap__swig_NewDirectorAA__SWIG_0 unsafe.Pointer + +func _swig_NewDirectorAA__SWIG_0(_swig_director *_swig_DirectorA, _ Std_complex_Sl_int_Sg_, _ float64) (_swig_ret SwigcptrA) { + _swig_p := uintptr(unsafe.Pointer(&_swig_director)) + _cgo_runtime_cgocall(_wrap__swig_NewDirectorAA__SWIG_0, _swig_p) + return +} + +func NewDirectorA__SWIG_0(v interface{}, arg1 Std_complex_Sl_int_Sg_, arg2 float64) A { + p := &_swig_DirectorA{0, v} + p.SwigcptrA = _swig_NewDirectorAA__SWIG_0(p, arg1, arg2) + return p +} + +var _wrap__swig_NewDirectorAA__SWIG_1 unsafe.Pointer + +func _swig_NewDirectorAA__SWIG_1(_swig_director *_swig_DirectorA, _ Std_complex_Sl_int_Sg_) (_swig_ret SwigcptrA) { + _swig_p := uintptr(unsafe.Pointer(&_swig_director)) + _cgo_runtime_cgocall(_wrap__swig_NewDirectorAA__SWIG_1, _swig_p) + return +} + +func NewDirectorA__SWIG_1(v interface{}, arg1 Std_complex_Sl_int_Sg_) A { + p := &_swig_DirectorA{0, v} + p.SwigcptrA = _swig_NewDirectorAA__SWIG_1(p, arg1) + return p +} + +var _wrap__swig_NewDirectorAA__SWIG_2 unsafe.Pointer + +func _swig_NewDirectorAA__SWIG_2(_swig_director *_swig_DirectorA, _ int, _ bool) (_swig_ret SwigcptrA) { + _swig_p := uintptr(unsafe.Pointer(&_swig_director)) + _cgo_runtime_cgocall(_wrap__swig_NewDirectorAA__SWIG_2, _swig_p) + return +} + +func NewDirectorA__SWIG_2(v interface{}, arg1 int, arg2 bool) A { + p := &_swig_DirectorA{0, v} + p.SwigcptrA = _swig_NewDirectorAA__SWIG_2(p, arg1, arg2) + return p +} + +var _wrap__swig_NewDirectorAA__SWIG_3 unsafe.Pointer + +func _swig_NewDirectorAA__SWIG_3(_swig_director *_swig_DirectorA, _ int) (_swig_ret SwigcptrA) { + _swig_p := uintptr(unsafe.Pointer(&_swig_director)) + _cgo_runtime_cgocall(_wrap__swig_NewDirectorAA__SWIG_3, _swig_p) + return +} + +func NewDirectorA__SWIG_3(v interface{}, arg1 int) A { + p := &_swig_DirectorA{0, v} + p.SwigcptrA = _swig_NewDirectorAA__SWIG_3(p, arg1) + return p +} + +func NewDirectorA(abi interface{}, a ...interface{}) A { + argc := len(a) + if argc == 1 { + if _, ok := a[0].(Std_complex_Sl_int_Sg_); !ok { + goto check_1 + } + return NewDirectorA__SWIG_1(abi, a[0].(Std_complex_Sl_int_Sg_)) + } +check_1: + if argc == 1 { + return NewDirectorA__SWIG_3(abi, a[0].(int)) + } + if argc == 2 { + if _, ok := a[0].(Std_complex_Sl_int_Sg_); !ok { + goto check_3 + } + if _, ok := a[1].(float64); !ok { + goto check_3 + } + return NewDirectorA__SWIG_0(abi, a[0].(Std_complex_Sl_int_Sg_), a[1].(float64)) + } +check_3: + if argc == 2 { + return NewDirectorA__SWIG_2(abi, a[0].(int), a[1].(bool)) + } + panic("No match for overloaded function call") +} + +var _wrap_DeleteDirectorA unsafe.Pointer + +func _swig_wrap_DeleteDirectorA(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_DeleteDirectorA, _swig_p) + return +} + +func DeleteDirectorA(arg1 A) { + _swig_wrap_DeleteDirectorA(arg1.Swigcptr()) +} + +func Swiggo_DeleteDirector_A(p *_swig_DirectorA) { + p.SwigcptrA = 0 +} + +type _swig_DirectorInterfaceAF__SWIG_0 interface { + F__SWIG_0(int) int +} + +var _wrap__swig_DirectorA_upcall_F__SWIG_0 unsafe.Pointer + +func _swig_wrap__swig_DirectorA_upcall_F__SWIG_0(_swig_ptr SwigcptrA, _ int) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) + _cgo_runtime_cgocall(_wrap__swig_DirectorA_upcall_F__SWIG_0, _swig_p) + return +} + +func (swig_p *_swig_DirectorA) F__SWIG_0(i int) int { + if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceAF__SWIG_0); swig_ok { + return swig_g.F__SWIG_0(i) + } + var swig_r int + swig_r = _swig_wrap__swig_DirectorA_upcall_F__SWIG_0(swig_p.SwigcptrA, i) + return swig_r +} + +func DirectorAF__SWIG_0(p A, arg2 int) int { + var swig_r int + swig_r = _swig_wrap__swig_DirectorA_upcall_F__SWIG_0(p.(*_swig_DirectorA).SwigcptrA, arg2) + return swig_r +} + +func Swig_DirectorA_callback_f__SWIG_0(p *_swig_DirectorA, arg2 int) (swig_result int) { + var swig_r int + swig_r = p.F__SWIG_0(arg2) + return swig_r +} + +type _swig_DirectorInterfaceAF__SWIG_1 interface { + F__SWIG_1() int +} + +var _wrap__swig_DirectorA_upcall_F__SWIG_1 unsafe.Pointer + +func _swig_wrap__swig_DirectorA_upcall_F__SWIG_1(_swig_ptr SwigcptrA) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) + _cgo_runtime_cgocall(_wrap__swig_DirectorA_upcall_F__SWIG_1, _swig_p) + return +} + +func (swig_p *_swig_DirectorA) F__SWIG_1() int { + if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceAF__SWIG_1); swig_ok { + return swig_g.F__SWIG_1() + } + var swig_r int + swig_r = _swig_wrap__swig_DirectorA_upcall_F__SWIG_1(swig_p.SwigcptrA) + return swig_r +} + +func DirectorAF__SWIG_1(p A) int { + var swig_r int + swig_r = _swig_wrap__swig_DirectorA_upcall_F__SWIG_1(p.(*_swig_DirectorA).SwigcptrA) + return swig_r +} + +func Swig_DirectorA_callback_f__SWIG_1(p *_swig_DirectorA) (swig_result int) { + var swig_r int + swig_r = p.F__SWIG_1() + return swig_r +} + +func (p _swig_DirectorA) F(a ...interface{}) int { + argc := len(a) + if argc == 0 { + return p.F__SWIG_1() + } + if argc == 1 { + return p.F__SWIG_0(a[0].(int)) + } + panic("No match for overloaded function call") +} + +func DirectorAF(p *_swig_DirectorA, a ...interface{}) int { + argc := len(a) + if argc == 0 { + return DirectorAF__SWIG_1(p) + } + if argc == 1 { + return DirectorAF__SWIG_0(p, a[0].(int)) + } + panic("No match for overloaded function call") +} + +type _swig_DirectorInterfaceARg__SWIG_0 interface { + Rg__SWIG_0(int) int +} + +var _wrap__swig_DirectorA_upcall_Rg__SWIG_0 unsafe.Pointer + +func _swig_wrap__swig_DirectorA_upcall_Rg__SWIG_0(_swig_ptr SwigcptrA, _ int) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) + _cgo_runtime_cgocall(_wrap__swig_DirectorA_upcall_Rg__SWIG_0, _swig_p) + return +} + +func (swig_p *_swig_DirectorA) Rg__SWIG_0(i int) int { + if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceARg__SWIG_0); swig_ok { + return swig_g.Rg__SWIG_0(i) + } + var swig_r int + swig_r = _swig_wrap__swig_DirectorA_upcall_Rg__SWIG_0(swig_p.SwigcptrA, i) + return swig_r +} + +func DirectorARg__SWIG_0(p A, arg2 int) int { + var swig_r int + swig_r = _swig_wrap__swig_DirectorA_upcall_Rg__SWIG_0(p.(*_swig_DirectorA).SwigcptrA, arg2) + return swig_r +} + +func Swig_DirectorA_callback_rg__SWIG_0(p *_swig_DirectorA, arg2 int) (swig_result int) { + var swig_r int + swig_r = p.Rg__SWIG_0(arg2) + return swig_r +} + +type _swig_DirectorInterfaceARg__SWIG_1 interface { + Rg__SWIG_1() int +} + +var _wrap__swig_DirectorA_upcall_Rg__SWIG_1 unsafe.Pointer + +func _swig_wrap__swig_DirectorA_upcall_Rg__SWIG_1(_swig_ptr SwigcptrA) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) + _cgo_runtime_cgocall(_wrap__swig_DirectorA_upcall_Rg__SWIG_1, _swig_p) + return +} + +func (swig_p *_swig_DirectorA) Rg__SWIG_1() int { + if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceARg__SWIG_1); swig_ok { + return swig_g.Rg__SWIG_1() + } + var swig_r int + swig_r = _swig_wrap__swig_DirectorA_upcall_Rg__SWIG_1(swig_p.SwigcptrA) + return swig_r +} + +func DirectorARg__SWIG_1(p A) int { + var swig_r int + swig_r = _swig_wrap__swig_DirectorA_upcall_Rg__SWIG_1(p.(*_swig_DirectorA).SwigcptrA) + return swig_r +} + +func Swig_DirectorA_callback_rg__SWIG_1(p *_swig_DirectorA) (swig_result int) { + var swig_r int + swig_r = p.Rg__SWIG_1() + return swig_r +} + +func (p _swig_DirectorA) Rg(a ...interface{}) int { + argc := len(a) + if argc == 0 { + return p.Rg__SWIG_1() + } + if argc == 1 { + return p.Rg__SWIG_0(a[0].(int)) + } + panic("No match for overloaded function call") +} + +func DirectorARg(p *_swig_DirectorA, a ...interface{}) int { + argc := len(a) + if argc == 0 { + return DirectorARg__SWIG_1(p) + } + if argc == 1 { + return DirectorARg__SWIG_0(p, a[0].(int)) + } + panic("No match for overloaded function call") +} + +type SwigcptrA uintptr + +func (p SwigcptrA) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrA) SwigIsA() { +} + +func (p SwigcptrA) DirectorInterface() interface{} { + return nil +} + +var _wrap_new_A__SWIG_0 unsafe.Pointer + +func _swig_wrap_new_A__SWIG_0(base uintptr, _ float64) (_ SwigcptrA) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_A__SWIG_0, _swig_p) + return +} + +func NewA__SWIG_0(arg1 Std_complex_Sl_int_Sg_, arg2 float64) (_swig_ret A) { + return _swig_wrap_new_A__SWIG_0(arg1.Swigcptr(), arg2) +} + +var _wrap_new_A__SWIG_1 unsafe.Pointer + +func _swig_wrap_new_A__SWIG_1(base uintptr) (_ SwigcptrA) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_A__SWIG_1, _swig_p) + return +} + +func NewA__SWIG_1(arg1 Std_complex_Sl_int_Sg_) (_swig_ret A) { + return _swig_wrap_new_A__SWIG_1(arg1.Swigcptr()) +} + +var _wrap_new_A__SWIG_2 unsafe.Pointer + +func _swig_wrap_new_A__SWIG_2(base int, _ bool) (_ SwigcptrA) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_A__SWIG_2, _swig_p) + return +} + +func NewA__SWIG_2(arg1 int, arg2 bool) (_swig_ret A) { + return _swig_wrap_new_A__SWIG_2(arg1, arg2) +} + +var _wrap_new_A__SWIG_3 unsafe.Pointer + +func _swig_wrap_new_A__SWIG_3(base int) (_ SwigcptrA) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_A__SWIG_3, _swig_p) + return +} + +func NewA__SWIG_3(arg1 int) (_swig_ret A) { + return _swig_wrap_new_A__SWIG_3(arg1) +} + +func NewA(a ...interface{}) A { + argc := len(a) + if argc == 1 { + if _, ok := a[0].(Std_complex_Sl_int_Sg_); !ok { + goto check_1 + } + return NewA__SWIG_1(a[0].(Std_complex_Sl_int_Sg_)) + } +check_1: + if argc == 1 { + return NewA__SWIG_3(a[0].(int)) + } + if argc == 2 { + if _, ok := a[0].(Std_complex_Sl_int_Sg_); !ok { + goto check_3 + } + if _, ok := a[1].(float64); !ok { + goto check_3 + } + return NewA__SWIG_0(a[0].(Std_complex_Sl_int_Sg_), a[1].(float64)) + } +check_3: + if argc == 2 { + return NewA__SWIG_2(a[0].(int), a[1].(bool)) + } + panic("No match for overloaded function call") +} + +var _wrap_delete_A unsafe.Pointer + +func _swig_wrap_delete_A(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_A, _swig_p) + return +} + +func DeleteA(arg1 A) { + _swig_wrap_delete_A(arg1.Swigcptr()) +} + +var _wrap_A_f__SWIG_0 unsafe.Pointer + +func _swig_wrap_A_f__SWIG_0(base SwigcptrA, _ int) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_A_f__SWIG_0, _swig_p) + return +} + +func (arg1 SwigcptrA) F__SWIG_0(arg2 int) (_swig_ret int) { + return _swig_wrap_A_f__SWIG_0(arg1, arg2) +} + +var _wrap_A_f__SWIG_1 unsafe.Pointer + +func _swig_wrap_A_f__SWIG_1(base SwigcptrA) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_A_f__SWIG_1, _swig_p) + return +} + +func (arg1 SwigcptrA) F__SWIG_1() (_swig_ret int) { + return _swig_wrap_A_f__SWIG_1(arg1) +} + +func (p SwigcptrA) F(a ...interface{}) int { + argc := len(a) + if argc == 0 { + return p.F__SWIG_1() + } + if argc == 1 { + return p.F__SWIG_0(a[0].(int)) + } + panic("No match for overloaded function call") +} + +var _wrap_A_rg__SWIG_0 unsafe.Pointer + +func _swig_wrap_A_rg__SWIG_0(base SwigcptrA, _ int) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_A_rg__SWIG_0, _swig_p) + return +} + +func (arg1 SwigcptrA) Rg__SWIG_0(arg2 int) (_swig_ret int) { + return _swig_wrap_A_rg__SWIG_0(arg1, arg2) +} + +var _wrap_A_rg__SWIG_1 unsafe.Pointer + +func _swig_wrap_A_rg__SWIG_1(base SwigcptrA) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_A_rg__SWIG_1, _swig_p) + return +} + +func (arg1 SwigcptrA) Rg__SWIG_1() (_swig_ret int) { + return _swig_wrap_A_rg__SWIG_1(arg1) +} + +func (p SwigcptrA) Rg(a ...interface{}) int { + argc := len(a) + if argc == 0 { + return p.Rg__SWIG_1() + } + if argc == 1 { + return p.Rg__SWIG_0(a[0].(int)) + } + panic("No match for overloaded function call") +} + +type A interface { + Swigcptr() uintptr + SwigIsA() + DirectorInterface() interface{} + F(a ...interface{}) int + Rg(a ...interface{}) int +} + +type SwigcptrA1 uintptr + +func (p SwigcptrA1) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrA1) SwigIsA1() { +} + +var _wrap_new_A1__SWIG_0 unsafe.Pointer + +func _swig_wrap_new_A1__SWIG_0(base uintptr, _ float64) (_ SwigcptrA1) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_A1__SWIG_0, _swig_p) + return +} + +func NewA1__SWIG_0(arg1 Std_complex_Sl_int_Sg_, arg2 float64) (_swig_ret A1) { + return _swig_wrap_new_A1__SWIG_0(arg1.Swigcptr(), arg2) +} + +var _wrap_new_A1__SWIG_1 unsafe.Pointer + +func _swig_wrap_new_A1__SWIG_1(base uintptr) (_ SwigcptrA1) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_A1__SWIG_1, _swig_p) + return +} + +func NewA1__SWIG_1(arg1 Std_complex_Sl_int_Sg_) (_swig_ret A1) { + return _swig_wrap_new_A1__SWIG_1(arg1.Swigcptr()) +} + +var _wrap_new_A1__SWIG_2 unsafe.Pointer + +func _swig_wrap_new_A1__SWIG_2(base int, _ bool) (_ SwigcptrA1) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_A1__SWIG_2, _swig_p) + return +} + +func NewA1__SWIG_2(arg1 int, arg2 bool) (_swig_ret A1) { + return _swig_wrap_new_A1__SWIG_2(arg1, arg2) +} + +var _wrap_new_A1__SWIG_3 unsafe.Pointer + +func _swig_wrap_new_A1__SWIG_3(base int) (_ SwigcptrA1) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_A1__SWIG_3, _swig_p) + return +} + +func NewA1__SWIG_3(arg1 int) (_swig_ret A1) { + return _swig_wrap_new_A1__SWIG_3(arg1) +} + +func NewA1(a ...interface{}) A1 { + argc := len(a) + if argc == 1 { + if _, ok := a[0].(Std_complex_Sl_int_Sg_); !ok { + goto check_1 + } + return NewA1__SWIG_1(a[0].(Std_complex_Sl_int_Sg_)) + } +check_1: + if argc == 1 { + return NewA1__SWIG_3(a[0].(int)) + } + if argc == 2 { + if _, ok := a[0].(Std_complex_Sl_int_Sg_); !ok { + goto check_3 + } + if _, ok := a[1].(float64); !ok { + goto check_3 + } + return NewA1__SWIG_0(a[0].(Std_complex_Sl_int_Sg_), a[1].(float64)) + } +check_3: + if argc == 2 { + return NewA1__SWIG_2(a[0].(int), a[1].(bool)) + } + panic("No match for overloaded function call") +} + +var _wrap_A1_ff__SWIG_0 unsafe.Pointer + +func _swig_wrap_A1_ff__SWIG_0(base SwigcptrA1, _ int) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_A1_ff__SWIG_0, _swig_p) + return +} + +func (arg1 SwigcptrA1) Ff__SWIG_0(arg2 int) (_swig_ret int) { + return _swig_wrap_A1_ff__SWIG_0(arg1, arg2) +} + +var _wrap_A1_ff__SWIG_1 unsafe.Pointer + +func _swig_wrap_A1_ff__SWIG_1(base SwigcptrA1) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_A1_ff__SWIG_1, _swig_p) + return +} + +func (arg1 SwigcptrA1) Ff__SWIG_1() (_swig_ret int) { + return _swig_wrap_A1_ff__SWIG_1(arg1) +} + +func (p SwigcptrA1) Ff(a ...interface{}) int { + argc := len(a) + if argc == 0 { + return p.Ff__SWIG_1() + } + if argc == 1 { + return p.Ff__SWIG_0(a[0].(int)) + } + panic("No match for overloaded function call") +} + +var _wrap_delete_A1 unsafe.Pointer + +func _swig_wrap_delete_A1(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_A1, _swig_p) + return +} + +func DeleteA1(arg1 A1) { + _swig_wrap_delete_A1(arg1.Swigcptr()) +} + +var _wrap_A1_f__SWIG_0 unsafe.Pointer + +func _swig_wrap_A1_f__SWIG_0(base SwigcptrA1, _ int) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_A1_f__SWIG_0, _swig_p) + return +} + +func (_swig_base SwigcptrA1) F__SWIG_0(arg1 int) (_swig_ret int) { + return _swig_wrap_A1_f__SWIG_0(_swig_base, arg1) +} + +var _wrap_A1_f__SWIG_1 unsafe.Pointer + +func _swig_wrap_A1_f__SWIG_1(base SwigcptrA1) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_A1_f__SWIG_1, _swig_p) + return +} + +func (_swig_base SwigcptrA1) F__SWIG_1() (_swig_ret int) { + return _swig_wrap_A1_f__SWIG_1(_swig_base) +} + +func (p SwigcptrA1) F(a ...interface{}) int { + argc := len(a) + if argc == 0 { + return p.F__SWIG_1() + } + if argc == 1 { + return p.F__SWIG_0(a[0].(int)) + } + panic("No match for overloaded function call") +} + +var _wrap_A1_rg__SWIG_0 unsafe.Pointer + +func _swig_wrap_A1_rg__SWIG_0(base SwigcptrA1, _ int) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_A1_rg__SWIG_0, _swig_p) + return +} + +func (_swig_base SwigcptrA1) Rg__SWIG_0(arg1 int) (_swig_ret int) { + return _swig_wrap_A1_rg__SWIG_0(_swig_base, arg1) +} + +var _wrap_A1_rg__SWIG_1 unsafe.Pointer + +func _swig_wrap_A1_rg__SWIG_1(base SwigcptrA1) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_A1_rg__SWIG_1, _swig_p) + return +} + +func (_swig_base SwigcptrA1) Rg__SWIG_1() (_swig_ret int) { + return _swig_wrap_A1_rg__SWIG_1(_swig_base) +} + +func (p SwigcptrA1) Rg(a ...interface{}) int { + argc := len(a) + if argc == 0 { + return p.Rg__SWIG_1() + } + if argc == 1 { + return p.Rg__SWIG_0(a[0].(int)) + } + panic("No match for overloaded function call") +} + +func (p SwigcptrA1) SwigIsA() { +} + +func (p SwigcptrA1) SwigGetA() A { + return SwigcptrA(p.Swigcptr()) +} + +type A1 interface { + Swigcptr() uintptr + SwigIsA1() + Ff(a ...interface{}) int + F(a ...interface{}) int + Rg(a ...interface{}) int + SwigIsA() + SwigGetA() A +} + +type SwigcptrBar uintptr + +func (p SwigcptrBar) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrBar) SwigIsBar() { +} + +var _wrap_Bar_x_set unsafe.Pointer + +func _swig_wrap_Bar_x_set(base SwigcptrBar, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Bar_x_set, _swig_p) + return +} + +func (arg1 SwigcptrBar) SetX(arg2 int) { + _swig_wrap_Bar_x_set(arg1, arg2) +} + +var _wrap_Bar_x_get unsafe.Pointer + +func _swig_wrap_Bar_x_get(base SwigcptrBar) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Bar_x_get, _swig_p) + return +} + +func (arg1 SwigcptrBar) GetX() (_swig_ret int) { + return _swig_wrap_Bar_x_get(arg1) +} + +var _wrap_new_Bar__SWIG_0 unsafe.Pointer + +func _swig_wrap_new_Bar__SWIG_0(base int) (_ SwigcptrBar) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Bar__SWIG_0, _swig_p) + return +} + +func NewBar__SWIG_0(arg1 int) (_swig_ret Bar) { + return _swig_wrap_new_Bar__SWIG_0(arg1) +} + +var _wrap_new_Bar__SWIG_1 unsafe.Pointer + +func _swig_wrap_new_Bar__SWIG_1() (base SwigcptrBar) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Bar__SWIG_1, _swig_p) + return +} + +func NewBar__SWIG_1() (_swig_ret Bar) { + return _swig_wrap_new_Bar__SWIG_1() +} + +func NewBar(a ...interface{}) Bar { + argc := len(a) + if argc == 0 { + return NewBar__SWIG_1() + } + if argc == 1 { + return NewBar__SWIG_0(a[0].(int)) + } + panic("No match for overloaded function call") +} + +var _wrap_delete_Bar unsafe.Pointer + +func _swig_wrap_delete_Bar(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Bar, _swig_p) + return +} + +func DeleteBar(arg1 Bar) { + _swig_wrap_delete_Bar(arg1.Swigcptr()) +} + +type Bar interface { + Swigcptr() uintptr + SwigIsBar() + SetX(arg2 int) + GetX() (_swig_ret int) +} + +type _swig_DirectorMyClass struct { + SwigcptrMyClass + v interface{} +} + +func (p *_swig_DirectorMyClass) Swigcptr() uintptr { + return p.SwigcptrMyClass.Swigcptr() +} + +func (p *_swig_DirectorMyClass) SwigIsMyClass() { +} + +func (p *_swig_DirectorMyClass) DirectorInterface() interface{} { + return p.v +} + +var _wrap__swig_NewDirectorMyClassMyClass__SWIG_0 unsafe.Pointer + +func _swig_NewDirectorMyClassMyClass__SWIG_0(_swig_director *_swig_DirectorMyClass, _ int) (_swig_ret SwigcptrMyClass) { + _swig_p := uintptr(unsafe.Pointer(&_swig_director)) + _cgo_runtime_cgocall(_wrap__swig_NewDirectorMyClassMyClass__SWIG_0, _swig_p) + return +} + +func NewDirectorMyClass__SWIG_0(v interface{}, arg1 int) MyClass { + p := &_swig_DirectorMyClass{0, v} + p.SwigcptrMyClass = _swig_NewDirectorMyClassMyClass__SWIG_0(p, arg1) + return p +} + +var _wrap__swig_NewDirectorMyClassMyClass__SWIG_1 unsafe.Pointer + +func _swig_NewDirectorMyClassMyClass__SWIG_1(_swig_director *_swig_DirectorMyClass) (_swig_ret SwigcptrMyClass) { + _swig_p := uintptr(unsafe.Pointer(&_swig_director)) + _cgo_runtime_cgocall(_wrap__swig_NewDirectorMyClassMyClass__SWIG_1, _swig_p) + return +} + +func NewDirectorMyClass__SWIG_1(v interface{}) MyClass { + p := &_swig_DirectorMyClass{0, v} + p.SwigcptrMyClass = _swig_NewDirectorMyClassMyClass__SWIG_1(p) + return p +} + +func NewDirectorMyClass(abi interface{}, a ...interface{}) MyClass { + argc := len(a) + if argc == 0 { + return NewDirectorMyClass__SWIG_1(abi) + } + if argc == 1 { + return NewDirectorMyClass__SWIG_0(abi, a[0].(int)) + } + panic("No match for overloaded function call") +} + +type _swig_DirectorInterfaceMyClassMethod interface { + Method(uintptr) +} + +var _wrap__swig_DirectorMyClass_upcall_Method unsafe.Pointer + +func _swig_wrap__swig_DirectorMyClass_upcall_Method(_swig_ptr SwigcptrMyClass, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) + _cgo_runtime_cgocall(_wrap__swig_DirectorMyClass_upcall_Method, _swig_p) + return +} + +func (swig_p *_swig_DirectorMyClass) Method(arg0 uintptr) { + if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceMyClassMethod); swig_ok { + swig_g.Method(arg0) + return + } + _swig_wrap__swig_DirectorMyClass_upcall_Method(swig_p.SwigcptrMyClass, arg0) +} + +func DirectorMyClassMethod(p MyClass, arg2 uintptr) { + _swig_wrap__swig_DirectorMyClass_upcall_Method(p.(*_swig_DirectorMyClass).SwigcptrMyClass, arg2) +} + +func Swig_DirectorMyClass_callback_method(p *_swig_DirectorMyClass, arg2 uintptr) { + p.Method(arg2) +} + +var _wrap_DeleteDirectorMyClass unsafe.Pointer + +func _swig_wrap_DeleteDirectorMyClass(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_DeleteDirectorMyClass, _swig_p) + return +} + +func DeleteDirectorMyClass(arg1 MyClass) { + _swig_wrap_DeleteDirectorMyClass(arg1.Swigcptr()) +} + +func Swiggo_DeleteDirector_MyClass(p *_swig_DirectorMyClass) { + p.SwigcptrMyClass = 0 +} + +type _swig_DirectorInterfaceMyClassVmethod interface { + Vmethod(Bar) Bar +} + +var _wrap__swig_DirectorMyClass_upcall_Vmethod unsafe.Pointer + +func _swig_wrap__swig_DirectorMyClass_upcall_Vmethod(_swig_ptr SwigcptrMyClass, _ uintptr) (_swig_ret SwigcptrBar) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) + _cgo_runtime_cgocall(_wrap__swig_DirectorMyClass_upcall_Vmethod, _swig_p) + return +} + +func (swig_p *_swig_DirectorMyClass) Vmethod(b Bar) Bar { + if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceMyClassVmethod); swig_ok { + return swig_g.Vmethod(b) + } + var swig_r Bar + swig_r = _swig_wrap__swig_DirectorMyClass_upcall_Vmethod(swig_p.SwigcptrMyClass, b.Swigcptr()) + return swig_r +} + +func DirectorMyClassVmethod(p MyClass, arg2 Bar) Bar { + var swig_r Bar + swig_r = _swig_wrap__swig_DirectorMyClass_upcall_Vmethod(p.(*_swig_DirectorMyClass).SwigcptrMyClass, arg2.Swigcptr()) + return swig_r +} + +func Swig_DirectorMyClass_callback_vmethod(p *_swig_DirectorMyClass, arg2 uintptr) (swig_result SwigcptrBar) { + var swig_r SwigcptrBar + swig_r = SwigcptrBar(p.Vmethod(SwigcptrBar(arg2)).Swigcptr()) + return swig_r +} + +type _swig_DirectorInterfaceMyClassPmethod interface { + Pmethod(Bar) Bar +} + +var _wrap__swig_DirectorMyClass_upcall_Pmethod unsafe.Pointer + +func _swig_wrap__swig_DirectorMyClass_upcall_Pmethod(_swig_ptr SwigcptrMyClass, _ uintptr) (_swig_ret SwigcptrBar) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) + _cgo_runtime_cgocall(_wrap__swig_DirectorMyClass_upcall_Pmethod, _swig_p) + return +} + +func (swig_p *_swig_DirectorMyClass) Pmethod(b Bar) Bar { + if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceMyClassPmethod); swig_ok { + return swig_g.Pmethod(b) + } + var swig_r Bar + swig_r = _swig_wrap__swig_DirectorMyClass_upcall_Pmethod(swig_p.SwigcptrMyClass, b.Swigcptr()) + return swig_r +} + +func DirectorMyClassPmethod(p MyClass, arg2 Bar) Bar { + var swig_r Bar + swig_r = _swig_wrap__swig_DirectorMyClass_upcall_Pmethod(p.(*_swig_DirectorMyClass).SwigcptrMyClass, arg2.Swigcptr()) + return swig_r +} + +func Swig_DirectorMyClass_callback_pmethod(p *_swig_DirectorMyClass, arg2 uintptr) (swig_result SwigcptrBar) { + var swig_r SwigcptrBar + swig_r = SwigcptrBar(p.Pmethod(SwigcptrBar(arg2)).Swigcptr()) + return swig_r +} + +type SwigcptrMyClass uintptr + +func (p SwigcptrMyClass) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrMyClass) SwigIsMyClass() { +} + +func (p SwigcptrMyClass) DirectorInterface() interface{} { + return nil +} + +var _wrap_new_MyClass__SWIG_0 unsafe.Pointer + +func _swig_wrap_new_MyClass__SWIG_0(base int) (_ SwigcptrMyClass) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_MyClass__SWIG_0, _swig_p) + return +} + +func NewMyClass__SWIG_0(arg1 int) (_swig_ret MyClass) { + return _swig_wrap_new_MyClass__SWIG_0(arg1) +} + +var _wrap_new_MyClass__SWIG_1 unsafe.Pointer + +func _swig_wrap_new_MyClass__SWIG_1() (base SwigcptrMyClass) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_MyClass__SWIG_1, _swig_p) + return +} + +func NewMyClass__SWIG_1() (_swig_ret MyClass) { + return _swig_wrap_new_MyClass__SWIG_1() +} + +func NewMyClass(a ...interface{}) MyClass { + argc := len(a) + if argc == 0 { + return NewMyClass__SWIG_1() + } + if argc == 1 { + return NewMyClass__SWIG_0(a[0].(int)) + } + panic("No match for overloaded function call") +} + +var _wrap_MyClass_method unsafe.Pointer + +func _swig_wrap_MyClass_method(base SwigcptrMyClass, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_MyClass_method, _swig_p) + return +} + +func (arg1 SwigcptrMyClass) Method(arg2 uintptr) { + _swig_wrap_MyClass_method(arg1, arg2) +} + +var _wrap_delete_MyClass unsafe.Pointer + +func _swig_wrap_delete_MyClass(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_MyClass, _swig_p) + return +} + +func DeleteMyClass(arg1 MyClass) { + _swig_wrap_delete_MyClass(arg1.Swigcptr()) +} + +var _wrap_MyClass_vmethod unsafe.Pointer + +func _swig_wrap_MyClass_vmethod(base SwigcptrMyClass, _ uintptr) (_ SwigcptrBar) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_MyClass_vmethod, _swig_p) + return +} + +func (arg1 SwigcptrMyClass) Vmethod(arg2 Bar) (_swig_ret Bar) { + return _swig_wrap_MyClass_vmethod(arg1, arg2.Swigcptr()) +} + +var _wrap_MyClass_pmethod unsafe.Pointer + +func _swig_wrap_MyClass_pmethod(base SwigcptrMyClass, _ uintptr) (_ SwigcptrBar) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_MyClass_pmethod, _swig_p) + return +} + +func (arg1 SwigcptrMyClass) Pmethod(arg2 Bar) (_swig_ret Bar) { + return _swig_wrap_MyClass_pmethod(arg1, arg2.Swigcptr()) +} + +var _wrap_MyClass_cmethod unsafe.Pointer + +func _swig_wrap_MyClass_cmethod(base SwigcptrMyClass, _ uintptr) (_ SwigcptrBar) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_MyClass_cmethod, _swig_p) + return +} + +func (arg1 SwigcptrMyClass) Cmethod(arg2 Bar) (_swig_ret Bar) { + return _swig_wrap_MyClass_cmethod(arg1, arg2.Swigcptr()) +} + +var _wrap_MyClass_get_self unsafe.Pointer + +func _swig_wrap_MyClass_get_self(base uintptr) (_ SwigcptrMyClass) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_MyClass_get_self, _swig_p) + return +} + +func MyClassGet_self(arg1 MyClass) (_swig_ret MyClass) { + return _swig_wrap_MyClass_get_self(arg1.Swigcptr()) +} + +var _wrap_MyClass_call_pmethod unsafe.Pointer + +func _swig_wrap_MyClass_call_pmethod(base uintptr, _ uintptr) (_ SwigcptrBar) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_MyClass_call_pmethod, _swig_p) + return +} + +func MyClassCall_pmethod(arg1 MyClass, arg2 Bar) (_swig_ret Bar) { + return _swig_wrap_MyClass_call_pmethod(arg1.Swigcptr(), arg2.Swigcptr()) +} + +type MyClass interface { + Swigcptr() uintptr + SwigIsMyClass() + DirectorInterface() interface{} + Method(arg2 uintptr) + Vmethod(arg2 Bar) (_swig_ret Bar) + Pmethod(arg2 Bar) (_swig_ret Bar) + Cmethod(arg2 Bar) (_swig_ret Bar) +} + +type SwigcptrMyClassT_i uintptr + +func (p SwigcptrMyClassT_i) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrMyClassT_i) SwigIsMyClassT_i() { +} + +var _wrap_new_MyClassT_i__SWIG_0 unsafe.Pointer + +func _swig_wrap_new_MyClassT_i__SWIG_0(base int) (_ SwigcptrMyClassT_i) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_MyClassT_i__SWIG_0, _swig_p) + return +} + +func NewMyClassT_i__SWIG_0(arg1 int) (_swig_ret MyClassT_i) { + return _swig_wrap_new_MyClassT_i__SWIG_0(arg1) +} + +var _wrap_new_MyClassT_i__SWIG_1 unsafe.Pointer + +func _swig_wrap_new_MyClassT_i__SWIG_1() (base SwigcptrMyClassT_i) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_MyClassT_i__SWIG_1, _swig_p) + return +} + +func NewMyClassT_i__SWIG_1() (_swig_ret MyClassT_i) { + return _swig_wrap_new_MyClassT_i__SWIG_1() +} + +func NewMyClassT_i(a ...interface{}) MyClassT_i { + argc := len(a) + if argc == 0 { + return NewMyClassT_i__SWIG_1() + } + if argc == 1 { + return NewMyClassT_i__SWIG_0(a[0].(int)) + } + panic("No match for overloaded function call") +} + +var _wrap_MyClassT_i_method unsafe.Pointer + +func _swig_wrap_MyClassT_i_method(base SwigcptrMyClassT_i, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_MyClassT_i_method, _swig_p) + return +} + +func (arg1 SwigcptrMyClassT_i) Method(arg2 uintptr) { + _swig_wrap_MyClassT_i_method(arg1, arg2) +} + +var _wrap_delete_MyClassT_i unsafe.Pointer + +func _swig_wrap_delete_MyClassT_i(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_MyClassT_i, _swig_p) + return +} + +func DeleteMyClassT_i(arg1 MyClassT_i) { + _swig_wrap_delete_MyClassT_i(arg1.Swigcptr()) +} + +type MyClassT_i interface { + Swigcptr() uintptr + SwigIsMyClassT_i() + Method(arg2 uintptr) +} + + +type SwigcptrSwigDirector_A uintptr +type SwigDirector_A interface { + Swigcptr() uintptr; +} +func (p SwigcptrSwigDirector_A) Swigcptr() uintptr { + return uintptr(p) +} + +type SwigcptrSwigDirector_Foo uintptr +type SwigDirector_Foo interface { + Swigcptr() uintptr; +} +func (p SwigcptrSwigDirector_Foo) Swigcptr() uintptr { + return uintptr(p) +} + +type SwigcptrStd_complex_Sl_int_Sg_ uintptr +type Std_complex_Sl_int_Sg_ interface { + Swigcptr() uintptr; +} +func (p SwigcptrStd_complex_Sl_int_Sg_) Swigcptr() uintptr { + return uintptr(p) +} + +type SwigcptrSwigDirector_MyClass uintptr +type SwigDirector_MyClass interface { + Swigcptr() uintptr; +} +func (p SwigcptrSwigDirector_MyClass) Swigcptr() uintptr { + return uintptr(p) +} + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/director_basic_runme b/Examples/test-suite/go/director_basic_runme new file mode 100755 index 000000000..3cdbb7478 Binary files /dev/null and b/Examples/test-suite/go/director_basic_runme differ diff --git a/Examples/test-suite/go/director_basic_wrap.h b/Examples/test-suite/go/director_basic_wrap.h new file mode 100644 index 000000000..6647a7ed7 --- /dev/null +++ b/Examples/test-suite/go/director_basic_wrap.h @@ -0,0 +1,83 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../director_basic.i + +#ifndef SWIG_director_basic_WRAP_H_ +#define SWIG_director_basic_WRAP_H_ + +class SwigDirector_Foo : public Foo +{ + public: + SwigDirector_Foo(void *swig_p); + virtual ~SwigDirector_Foo(); + std::string _swig_upcall_ping() { + return Foo::ping(); + } + virtual std::string ping(); + std::string _swig_upcall_pong() { + return Foo::pong(); + } + virtual std::string pong(); + private: + void *go_val; +}; + +class SwigDirector_A : public A +{ + public: + SwigDirector_A(void *swig_p, std::complex< int > i, double d); + SwigDirector_A(void *swig_p, std::complex< int > i); + SwigDirector_A(void *swig_p, int i, bool j); + SwigDirector_A(void *swig_p, int i); + virtual ~SwigDirector_A(); + int _swig_upcall_f__SWIG_0(int i) { + return A::f(i); + } + virtual int f(int i); + int _swig_upcall_f__SWIG_1() { + return A::f(); + } + virtual int f(); + int _swig_upcall_rg__SWIG_0(int i) { + return A::gg(i); + } + virtual int gg(int i); + int _swig_upcall_rg__SWIG_1() { + return A::gg(); + } + virtual int gg(); + private: + void *go_val; +}; + +class SwigDirector_MyClass : public MyClass +{ + public: + SwigDirector_MyClass(void *swig_p, int a); + SwigDirector_MyClass(void *swig_p); + void _swig_upcall_method(VoidType *arg0) { + MyClass::method(arg0); + } + virtual void method(VoidType *arg0); + virtual ~SwigDirector_MyClass(); + Bar _swig_upcall_vmethod(Bar b) { + return MyClass::vmethod(b); + } + virtual Bar vmethod(Bar b); + Bar *_swig_upcall_pmethod(Bar *b) { + return MyClass::pmethod(b); + } + virtual Bar *pmethod(Bar *b); + private: + void *go_val; +}; + +#endif diff --git a/Examples/test-suite/go/director_binary_string.go b/Examples/test-suite/go/director_binary_string.go new file mode 100644 index 000000000..131f66147 --- /dev/null +++ b/Examples/test-suite/go/director_binary_string.go @@ -0,0 +1,267 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../director_binary_string.i + +package director_binary_string + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +const BUFFER_SIZE_AA int = 8 +const BUFFER_SIZE_BB int = 5 +type _swig_DirectorCallback struct { + SwigcptrCallback + v interface{} +} + +func (p *_swig_DirectorCallback) Swigcptr() uintptr { + return p.SwigcptrCallback.Swigcptr() +} + +func (p *_swig_DirectorCallback) SwigIsCallback() { +} + +func (p *_swig_DirectorCallback) DirectorInterface() interface{} { + return p.v +} + +var _wrap__swig_NewDirectorCallbackCallback unsafe.Pointer + +func _swig_NewDirectorCallbackCallback(_swig_director *_swig_DirectorCallback) (_swig_ret SwigcptrCallback) { + _swig_p := uintptr(unsafe.Pointer(&_swig_director)) + _cgo_runtime_cgocall(_wrap__swig_NewDirectorCallbackCallback, _swig_p) + return +} + +func NewDirectorCallback(v interface{}) Callback { + p := &_swig_DirectorCallback{0, v} + p.SwigcptrCallback = _swig_NewDirectorCallbackCallback(p) + return p +} + +var _wrap_DeleteDirectorCallback unsafe.Pointer + +func _swig_wrap_DeleteDirectorCallback(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_DeleteDirectorCallback, _swig_p) + return +} + +func DeleteDirectorCallback(arg1 Callback) { + _swig_wrap_DeleteDirectorCallback(arg1.Swigcptr()) +} + +func Swiggo_DeleteDirector_Callback(p *_swig_DirectorCallback) { + p.SwigcptrCallback = 0 +} + +type _swig_DirectorInterfaceCallbackRun interface { + Run(string, string) +} + +var _wrap__swig_DirectorCallback_upcall_Run unsafe.Pointer + +func _swig_wrap__swig_DirectorCallback_upcall_Run(_swig_ptr SwigcptrCallback, _ string, _ string) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) + _cgo_runtime_cgocall(_wrap__swig_DirectorCallback_upcall_Run, _swig_p) + return +} + +func (swig_p *_swig_DirectorCallback) Run(dataBufferAA string, dataBufferBB string) { + if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceCallbackRun); swig_ok { + swig_g.Run(dataBufferAA, dataBufferBB) + return + } + _swig_wrap__swig_DirectorCallback_upcall_Run(swig_p.SwigcptrCallback, dataBufferAA, dataBufferBB) +} + +func DirectorCallbackRun(p Callback, arg2 string, arg4 string) { + _swig_wrap__swig_DirectorCallback_upcall_Run(p.(*_swig_DirectorCallback).SwigcptrCallback, arg2, arg4) +} + +func Swig_DirectorCallback_callback_run(p *_swig_DirectorCallback, arg2 string, arg4 string) { + p.Run(arg2, arg4) +} + +type SwigcptrCallback uintptr + +func (p SwigcptrCallback) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrCallback) SwigIsCallback() { +} + +func (p SwigcptrCallback) DirectorInterface() interface{} { + return nil +} + +var _wrap_delete_Callback unsafe.Pointer + +func _swig_wrap_delete_Callback(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Callback, _swig_p) + return +} + +func DeleteCallback(arg1 Callback) { + _swig_wrap_delete_Callback(arg1.Swigcptr()) +} + +var _wrap_Callback_run unsafe.Pointer + +func _swig_wrap_Callback_run(base SwigcptrCallback, _ string, _ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Callback_run, _swig_p) + return +} + +func (arg1 SwigcptrCallback) Run(arg2 string, arg3 string) { + _swig_wrap_Callback_run(arg1, arg2, arg3) +} + +var _wrap_new_Callback unsafe.Pointer + +func _swig_wrap_new_Callback() (base SwigcptrCallback) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Callback, _swig_p) + return +} + +func NewCallback() (_swig_ret Callback) { + return _swig_wrap_new_Callback() +} + +type Callback interface { + Swigcptr() uintptr + SwigIsCallback() + DirectorInterface() interface{} + Run(arg2 string, arg3 string) +} + +type SwigcptrCaller uintptr + +func (p SwigcptrCaller) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrCaller) SwigIsCaller() { +} + +var _wrap_new_Caller unsafe.Pointer + +func _swig_wrap_new_Caller() (base SwigcptrCaller) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Caller, _swig_p) + return +} + +func NewCaller() (_swig_ret Caller) { + return _swig_wrap_new_Caller() +} + +var _wrap_delete_Caller unsafe.Pointer + +func _swig_wrap_delete_Caller(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Caller, _swig_p) + return +} + +func DeleteCaller(arg1 Caller) { + _swig_wrap_delete_Caller(arg1.Swigcptr()) +} + +var _wrap_Caller_delCallback unsafe.Pointer + +func _swig_wrap_Caller_delCallback(base SwigcptrCaller) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Caller_delCallback, _swig_p) + return +} + +func (arg1 SwigcptrCaller) DelCallback() { + _swig_wrap_Caller_delCallback(arg1) +} + +var _wrap_Caller_setCallback unsafe.Pointer + +func _swig_wrap_Caller_setCallback(base SwigcptrCaller, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Caller_setCallback, _swig_p) + return +} + +func (arg1 SwigcptrCaller) SetCallback(arg2 Callback) { + _swig_wrap_Caller_setCallback(arg1, arg2.Swigcptr()) +} + +var _wrap_Caller_call unsafe.Pointer + +func _swig_wrap_Caller_call(base SwigcptrCaller) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Caller_call, _swig_p) + return +} + +func (arg1 SwigcptrCaller) Call() (_swig_ret int) { + return _swig_wrap_Caller_call(arg1) +} + +var _wrap_Caller_call_null unsafe.Pointer + +func _swig_wrap_Caller_call_null(base SwigcptrCaller) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Caller_call_null, _swig_p) + return +} + +func (arg1 SwigcptrCaller) Call_null() { + _swig_wrap_Caller_call_null(arg1) +} + +type Caller interface { + Swigcptr() uintptr + SwigIsCaller() + DelCallback() + SetCallback(arg2 Callback) + Call() (_swig_ret int) + Call_null() +} + + +type SwigcptrSwigDirector_Callback uintptr +type SwigDirector_Callback interface { + Swigcptr() uintptr; +} +func (p SwigcptrSwigDirector_Callback) Swigcptr() uintptr { + return uintptr(p) +} + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/director_binary_string_wrap.h b/Examples/test-suite/go/director_binary_string_wrap.h new file mode 100644 index 000000000..0607ede41 --- /dev/null +++ b/Examples/test-suite/go/director_binary_string_wrap.h @@ -0,0 +1,29 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../director_binary_string.i + +#ifndef SWIG_director_binary_string_WRAP_H_ +#define SWIG_director_binary_string_WRAP_H_ + +class SwigDirector_Callback : public Callback +{ + public: + SwigDirector_Callback(void *swig_p); + virtual ~SwigDirector_Callback(); + void _swig_upcall_run(char *dataBufferAA, int sizeAA, char *dataBufferBB, int sizeBB) { + Callback::run(dataBufferAA,sizeAA,dataBufferBB,sizeBB); + } + virtual void run(char *dataBufferAA, int sizeAA, char *dataBufferBB, int sizeBB); + private: + void *go_val; +}; + +#endif diff --git a/Examples/test-suite/go/director_classes.go b/Examples/test-suite/go/director_classes.go new file mode 100644 index 000000000..8991fdc73 --- /dev/null +++ b/Examples/test-suite/go/director_classes.go @@ -0,0 +1,1871 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../director_classes.i + +package director_classes + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +var _wrap_PrintDebug_set unsafe.Pointer + +func _swig_wrap_PrintDebug_set(base bool) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_PrintDebug_set, _swig_p) + return +} + +func SetPrintDebug(arg1 bool) { + _swig_wrap_PrintDebug_set(arg1) +} + +var _wrap_PrintDebug_get unsafe.Pointer + +func GetPrintDebug() (_swig_ret bool) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_PrintDebug_get, _swig_p) + return +} +type SwigcptrDoubleHolder uintptr + +func (p SwigcptrDoubleHolder) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrDoubleHolder) SwigIsDoubleHolder() { +} + +var _wrap_new_DoubleHolder__SWIG_0 unsafe.Pointer + +func _swig_wrap_new_DoubleHolder__SWIG_0(base float64) (_ SwigcptrDoubleHolder) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_DoubleHolder__SWIG_0, _swig_p) + return +} + +func NewDoubleHolder__SWIG_0(arg1 float64) (_swig_ret DoubleHolder) { + return _swig_wrap_new_DoubleHolder__SWIG_0(arg1) +} + +var _wrap_new_DoubleHolder__SWIG_1 unsafe.Pointer + +func _swig_wrap_new_DoubleHolder__SWIG_1() (base SwigcptrDoubleHolder) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_DoubleHolder__SWIG_1, _swig_p) + return +} + +func NewDoubleHolder__SWIG_1() (_swig_ret DoubleHolder) { + return _swig_wrap_new_DoubleHolder__SWIG_1() +} + +func NewDoubleHolder(a ...interface{}) DoubleHolder { + argc := len(a) + if argc == 0 { + return NewDoubleHolder__SWIG_1() + } + if argc == 1 { + return NewDoubleHolder__SWIG_0(a[0].(float64)) + } + panic("No match for overloaded function call") +} + +var _wrap_DoubleHolder_val_set unsafe.Pointer + +func _swig_wrap_DoubleHolder_val_set(base SwigcptrDoubleHolder, _ float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_DoubleHolder_val_set, _swig_p) + return +} + +func (arg1 SwigcptrDoubleHolder) SetVal(arg2 float64) { + _swig_wrap_DoubleHolder_val_set(arg1, arg2) +} + +var _wrap_DoubleHolder_val_get unsafe.Pointer + +func _swig_wrap_DoubleHolder_val_get(base SwigcptrDoubleHolder) (_ float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_DoubleHolder_val_get, _swig_p) + return +} + +func (arg1 SwigcptrDoubleHolder) GetVal() (_swig_ret float64) { + return _swig_wrap_DoubleHolder_val_get(arg1) +} + +var _wrap_delete_DoubleHolder unsafe.Pointer + +func _swig_wrap_delete_DoubleHolder(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_DoubleHolder, _swig_p) + return +} + +func DeleteDoubleHolder(arg1 DoubleHolder) { + _swig_wrap_delete_DoubleHolder(arg1.Swigcptr()) +} + +type DoubleHolder interface { + Swigcptr() uintptr + SwigIsDoubleHolder() + SetVal(arg2 float64) + GetVal() (_swig_ret float64) +} + +type _swig_DirectorBase struct { + SwigcptrBase + v interface{} +} + +func (p *_swig_DirectorBase) Swigcptr() uintptr { + return p.SwigcptrBase.Swigcptr() +} + +func (p *_swig_DirectorBase) SwigIsBase() { +} + +func (p *_swig_DirectorBase) DirectorInterface() interface{} { + return p.v +} + +var _wrap__swig_NewDirectorBaseBase unsafe.Pointer + +func _swig_NewDirectorBaseBase(_swig_director *_swig_DirectorBase, _ float64) (_swig_ret SwigcptrBase) { + _swig_p := uintptr(unsafe.Pointer(&_swig_director)) + _cgo_runtime_cgocall(_wrap__swig_NewDirectorBaseBase, _swig_p) + return +} + +func NewDirectorBase(v interface{}, arg1 float64) Base { + p := &_swig_DirectorBase{0, v} + p.SwigcptrBase = _swig_NewDirectorBaseBase(p, arg1) + return p +} + +var _wrap_DeleteDirectorBase unsafe.Pointer + +func _swig_wrap_DeleteDirectorBase(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_DeleteDirectorBase, _swig_p) + return +} + +func DeleteDirectorBase(arg1 Base) { + _swig_wrap_DeleteDirectorBase(arg1.Swigcptr()) +} + +func Swiggo_DeleteDirector_Base(p *_swig_DirectorBase) { + p.SwigcptrBase = 0 +} + +type _swig_DirectorInterfaceBaseVal interface { + Val(DoubleHolder) DoubleHolder +} + +var _wrap__swig_DirectorBase_upcall_Val unsafe.Pointer + +func _swig_wrap__swig_DirectorBase_upcall_Val(_swig_ptr SwigcptrBase, _ uintptr) (_swig_ret SwigcptrDoubleHolder) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) + _cgo_runtime_cgocall(_wrap__swig_DirectorBase_upcall_Val, _swig_p) + return +} + +func (swig_p *_swig_DirectorBase) Val(x DoubleHolder) DoubleHolder { + if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceBaseVal); swig_ok { + return swig_g.Val(x) + } + var swig_r DoubleHolder + swig_r = _swig_wrap__swig_DirectorBase_upcall_Val(swig_p.SwigcptrBase, x.Swigcptr()) + return swig_r +} + +func DirectorBaseVal(p Base, arg2 DoubleHolder) DoubleHolder { + var swig_r DoubleHolder + swig_r = _swig_wrap__swig_DirectorBase_upcall_Val(p.(*_swig_DirectorBase).SwigcptrBase, arg2.Swigcptr()) + return swig_r +} + +func Swig_DirectorBase_callback_Val(p *_swig_DirectorBase, arg2 uintptr) (swig_result SwigcptrDoubleHolder) { + var swig_r SwigcptrDoubleHolder + swig_r = SwigcptrDoubleHolder(p.Val(SwigcptrDoubleHolder(arg2)).Swigcptr()) + return swig_r +} + +type _swig_DirectorInterfaceBaseRef interface { + Ref(DoubleHolder) DoubleHolder +} + +var _wrap__swig_DirectorBase_upcall_Ref unsafe.Pointer + +func _swig_wrap__swig_DirectorBase_upcall_Ref(_swig_ptr SwigcptrBase, _ uintptr) (_swig_ret SwigcptrDoubleHolder) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) + _cgo_runtime_cgocall(_wrap__swig_DirectorBase_upcall_Ref, _swig_p) + return +} + +func (swig_p *_swig_DirectorBase) Ref(x DoubleHolder) DoubleHolder { + if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceBaseRef); swig_ok { + return swig_g.Ref(x) + } + var swig_r DoubleHolder + swig_r = _swig_wrap__swig_DirectorBase_upcall_Ref(swig_p.SwigcptrBase, x.Swigcptr()) + return swig_r +} + +func DirectorBaseRef(p Base, arg2 DoubleHolder) DoubleHolder { + var swig_r DoubleHolder + swig_r = _swig_wrap__swig_DirectorBase_upcall_Ref(p.(*_swig_DirectorBase).SwigcptrBase, arg2.Swigcptr()) + return swig_r +} + +func Swig_DirectorBase_callback_Ref(p *_swig_DirectorBase, arg2 uintptr) (swig_result SwigcptrDoubleHolder) { + var swig_r SwigcptrDoubleHolder + swig_r = SwigcptrDoubleHolder(p.Ref(SwigcptrDoubleHolder(arg2)).Swigcptr()) + return swig_r +} + +type _swig_DirectorInterfaceBasePtr interface { + Ptr(DoubleHolder) DoubleHolder +} + +var _wrap__swig_DirectorBase_upcall_Ptr unsafe.Pointer + +func _swig_wrap__swig_DirectorBase_upcall_Ptr(_swig_ptr SwigcptrBase, _ uintptr) (_swig_ret SwigcptrDoubleHolder) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) + _cgo_runtime_cgocall(_wrap__swig_DirectorBase_upcall_Ptr, _swig_p) + return +} + +func (swig_p *_swig_DirectorBase) Ptr(x DoubleHolder) DoubleHolder { + if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceBasePtr); swig_ok { + return swig_g.Ptr(x) + } + var swig_r DoubleHolder + swig_r = _swig_wrap__swig_DirectorBase_upcall_Ptr(swig_p.SwigcptrBase, x.Swigcptr()) + return swig_r +} + +func DirectorBasePtr(p Base, arg2 DoubleHolder) DoubleHolder { + var swig_r DoubleHolder + swig_r = _swig_wrap__swig_DirectorBase_upcall_Ptr(p.(*_swig_DirectorBase).SwigcptrBase, arg2.Swigcptr()) + return swig_r +} + +func Swig_DirectorBase_callback_Ptr(p *_swig_DirectorBase, arg2 uintptr) (swig_result SwigcptrDoubleHolder) { + var swig_r SwigcptrDoubleHolder + swig_r = SwigcptrDoubleHolder(p.Ptr(SwigcptrDoubleHolder(arg2)).Swigcptr()) + return swig_r +} + +type _swig_DirectorInterfaceBaseFullyOverloaded__SWIG_0 interface { + FullyOverloaded__SWIG_0(int) string +} + +var _wrap__swig_DirectorBase_upcall_FullyOverloaded__SWIG_0 unsafe.Pointer + +func _swig_wrap__swig_DirectorBase_upcall_FullyOverloaded__SWIG_0(_swig_ptr SwigcptrBase, _ int) (_swig_ret string) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) + _cgo_runtime_cgocall(_wrap__swig_DirectorBase_upcall_FullyOverloaded__SWIG_0, _swig_p) + return +} + +func (swig_p *_swig_DirectorBase) FullyOverloaded__SWIG_0(x int) string { + if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceBaseFullyOverloaded__SWIG_0); swig_ok { + return swig_g.FullyOverloaded__SWIG_0(x) + } + var swig_r string + swig_r = _swig_wrap__swig_DirectorBase_upcall_FullyOverloaded__SWIG_0(swig_p.SwigcptrBase, x) + return swig_r +} + +func DirectorBaseFullyOverloaded__SWIG_0(p Base, arg2 int) string { + var swig_r string + swig_r = _swig_wrap__swig_DirectorBase_upcall_FullyOverloaded__SWIG_0(p.(*_swig_DirectorBase).SwigcptrBase, arg2) + return swig_r +} + +func Swig_DirectorBase_callback_FullyOverloaded__SWIG_0(p *_swig_DirectorBase, arg2 int) (swig_result string) { + var swig_r string + swig_r = p.FullyOverloaded__SWIG_0(arg2) + return swig_r +} + +type _swig_DirectorInterfaceBaseFullyOverloaded__SWIG_1 interface { + FullyOverloaded__SWIG_1(bool) string +} + +var _wrap__swig_DirectorBase_upcall_FullyOverloaded__SWIG_1 unsafe.Pointer + +func _swig_wrap__swig_DirectorBase_upcall_FullyOverloaded__SWIG_1(_swig_ptr SwigcptrBase, _ bool) (_swig_ret string) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) + _cgo_runtime_cgocall(_wrap__swig_DirectorBase_upcall_FullyOverloaded__SWIG_1, _swig_p) + return +} + +func (swig_p *_swig_DirectorBase) FullyOverloaded__SWIG_1(x bool) string { + if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceBaseFullyOverloaded__SWIG_1); swig_ok { + return swig_g.FullyOverloaded__SWIG_1(x) + } + var swig_r string + swig_r = _swig_wrap__swig_DirectorBase_upcall_FullyOverloaded__SWIG_1(swig_p.SwigcptrBase, x) + return swig_r +} + +func DirectorBaseFullyOverloaded__SWIG_1(p Base, arg2 bool) string { + var swig_r string + swig_r = _swig_wrap__swig_DirectorBase_upcall_FullyOverloaded__SWIG_1(p.(*_swig_DirectorBase).SwigcptrBase, arg2) + return swig_r +} + +func Swig_DirectorBase_callback_FullyOverloaded__SWIG_1(p *_swig_DirectorBase, arg2 bool) (swig_result string) { + var swig_r string + swig_r = p.FullyOverloaded__SWIG_1(arg2) + return swig_r +} + +func (p _swig_DirectorBase) FullyOverloaded(a ...interface{}) string { + argc := len(a) + if argc == 1 { + if _, ok := a[0].(bool); !ok { + goto check_1 + } + return p.FullyOverloaded__SWIG_1(a[0].(bool)) + } +check_1: + if argc == 1 { + return p.FullyOverloaded__SWIG_0(a[0].(int)) + } + panic("No match for overloaded function call") +} + +func DirectorBaseFullyOverloaded(p *_swig_DirectorBase, a ...interface{}) string { + argc := len(a) + if argc == 1 { + if _, ok := a[0].(bool); !ok { + goto check_1 + } + return DirectorBaseFullyOverloaded__SWIG_1(p, a[0].(bool)) + } +check_1: + if argc == 1 { + return DirectorBaseFullyOverloaded__SWIG_0(p, a[0].(int)) + } + panic("No match for overloaded function call") +} + +type _swig_DirectorInterfaceBaseSemiOverloaded__SWIG_0 interface { + SemiOverloaded__SWIG_0(int) string +} + +var _wrap__swig_DirectorBase_upcall_SemiOverloaded__SWIG_0 unsafe.Pointer + +func _swig_wrap__swig_DirectorBase_upcall_SemiOverloaded__SWIG_0(_swig_ptr SwigcptrBase, _ int) (_swig_ret string) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) + _cgo_runtime_cgocall(_wrap__swig_DirectorBase_upcall_SemiOverloaded__SWIG_0, _swig_p) + return +} + +func (swig_p *_swig_DirectorBase) SemiOverloaded__SWIG_0(x int) string { + if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceBaseSemiOverloaded__SWIG_0); swig_ok { + return swig_g.SemiOverloaded__SWIG_0(x) + } + var swig_r string + swig_r = _swig_wrap__swig_DirectorBase_upcall_SemiOverloaded__SWIG_0(swig_p.SwigcptrBase, x) + return swig_r +} + +func DirectorBaseSemiOverloaded__SWIG_0(p Base, arg2 int) string { + var swig_r string + swig_r = _swig_wrap__swig_DirectorBase_upcall_SemiOverloaded__SWIG_0(p.(*_swig_DirectorBase).SwigcptrBase, arg2) + return swig_r +} + +func Swig_DirectorBase_callback_SemiOverloaded__SWIG_0(p *_swig_DirectorBase, arg2 int) (swig_result string) { + var swig_r string + swig_r = p.SemiOverloaded__SWIG_0(arg2) + return swig_r +} + +type _swig_DirectorInterfaceBaseSemiOverloaded__SWIG_1 interface { + SemiOverloaded__SWIG_1(bool) string +} + +var _wrap__swig_DirectorBase_upcall_SemiOverloaded__SWIG_1 unsafe.Pointer + +func _swig_wrap__swig_DirectorBase_upcall_SemiOverloaded__SWIG_1(_swig_ptr SwigcptrBase, _ bool) (_swig_ret string) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) + _cgo_runtime_cgocall(_wrap__swig_DirectorBase_upcall_SemiOverloaded__SWIG_1, _swig_p) + return +} + +func (swig_p *_swig_DirectorBase) SemiOverloaded__SWIG_1(x bool) string { + if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceBaseSemiOverloaded__SWIG_1); swig_ok { + return swig_g.SemiOverloaded__SWIG_1(x) + } + var swig_r string + swig_r = _swig_wrap__swig_DirectorBase_upcall_SemiOverloaded__SWIG_1(swig_p.SwigcptrBase, x) + return swig_r +} + +func DirectorBaseSemiOverloaded__SWIG_1(p Base, arg2 bool) string { + var swig_r string + swig_r = _swig_wrap__swig_DirectorBase_upcall_SemiOverloaded__SWIG_1(p.(*_swig_DirectorBase).SwigcptrBase, arg2) + return swig_r +} + +func Swig_DirectorBase_callback_SemiOverloaded__SWIG_1(p *_swig_DirectorBase, arg2 bool) (swig_result string) { + var swig_r string + swig_r = p.SemiOverloaded__SWIG_1(arg2) + return swig_r +} + +func (p _swig_DirectorBase) SemiOverloaded(a ...interface{}) string { + argc := len(a) + if argc == 1 { + if _, ok := a[0].(bool); !ok { + goto check_1 + } + return p.SemiOverloaded__SWIG_1(a[0].(bool)) + } +check_1: + if argc == 1 { + return p.SemiOverloaded__SWIG_0(a[0].(int)) + } + panic("No match for overloaded function call") +} + +func DirectorBaseSemiOverloaded(p *_swig_DirectorBase, a ...interface{}) string { + argc := len(a) + if argc == 1 { + if _, ok := a[0].(bool); !ok { + goto check_1 + } + return DirectorBaseSemiOverloaded__SWIG_1(p, a[0].(bool)) + } +check_1: + if argc == 1 { + return DirectorBaseSemiOverloaded__SWIG_0(p, a[0].(int)) + } + panic("No match for overloaded function call") +} + +type _swig_DirectorInterfaceBaseDefaultParms__SWIG_0 interface { + DefaultParms__SWIG_0(int, float64) string +} + +var _wrap__swig_DirectorBase_upcall_DefaultParms__SWIG_0 unsafe.Pointer + +func _swig_wrap__swig_DirectorBase_upcall_DefaultParms__SWIG_0(_swig_ptr SwigcptrBase, _ int, _ float64) (_swig_ret string) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) + _cgo_runtime_cgocall(_wrap__swig_DirectorBase_upcall_DefaultParms__SWIG_0, _swig_p) + return +} + +func (swig_p *_swig_DirectorBase) DefaultParms__SWIG_0(x int, y float64) string { + if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceBaseDefaultParms__SWIG_0); swig_ok { + return swig_g.DefaultParms__SWIG_0(x, y) + } + var swig_r string + swig_r = _swig_wrap__swig_DirectorBase_upcall_DefaultParms__SWIG_0(swig_p.SwigcptrBase, x, y) + return swig_r +} + +func DirectorBaseDefaultParms__SWIG_0(p Base, arg2 int, arg3 float64) string { + var swig_r string + swig_r = _swig_wrap__swig_DirectorBase_upcall_DefaultParms__SWIG_0(p.(*_swig_DirectorBase).SwigcptrBase, arg2, arg3) + return swig_r +} + +func Swig_DirectorBase_callback_DefaultParms__SWIG_0(p *_swig_DirectorBase, arg2 int, arg3 float64) (swig_result string) { + var swig_r string + swig_r = p.DefaultParms__SWIG_0(arg2, arg3) + return swig_r +} + +type _swig_DirectorInterfaceBaseDefaultParms__SWIG_1 interface { + DefaultParms__SWIG_1(int) string +} + +var _wrap__swig_DirectorBase_upcall_DefaultParms__SWIG_1 unsafe.Pointer + +func _swig_wrap__swig_DirectorBase_upcall_DefaultParms__SWIG_1(_swig_ptr SwigcptrBase, _ int) (_swig_ret string) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) + _cgo_runtime_cgocall(_wrap__swig_DirectorBase_upcall_DefaultParms__SWIG_1, _swig_p) + return +} + +func (swig_p *_swig_DirectorBase) DefaultParms__SWIG_1(x int) string { + if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceBaseDefaultParms__SWIG_1); swig_ok { + return swig_g.DefaultParms__SWIG_1(x) + } + var swig_r string + swig_r = _swig_wrap__swig_DirectorBase_upcall_DefaultParms__SWIG_1(swig_p.SwigcptrBase, x) + return swig_r +} + +func DirectorBaseDefaultParms__SWIG_1(p Base, arg2 int) string { + var swig_r string + swig_r = _swig_wrap__swig_DirectorBase_upcall_DefaultParms__SWIG_1(p.(*_swig_DirectorBase).SwigcptrBase, arg2) + return swig_r +} + +func Swig_DirectorBase_callback_DefaultParms__SWIG_1(p *_swig_DirectorBase, arg2 int) (swig_result string) { + var swig_r string + swig_r = p.DefaultParms__SWIG_1(arg2) + return swig_r +} + +func (p _swig_DirectorBase) DefaultParms(a ...interface{}) string { + argc := len(a) + if argc == 1 { + return p.DefaultParms__SWIG_1(a[0].(int)) + } + if argc == 2 { + return p.DefaultParms__SWIG_0(a[0].(int), a[1].(float64)) + } + panic("No match for overloaded function call") +} + +func DirectorBaseDefaultParms(p *_swig_DirectorBase, a ...interface{}) string { + argc := len(a) + if argc == 1 { + return DirectorBaseDefaultParms__SWIG_1(p, a[0].(int)) + } + if argc == 2 { + return DirectorBaseDefaultParms__SWIG_0(p, a[0].(int), a[1].(float64)) + } + panic("No match for overloaded function call") +} + +type SwigcptrBase uintptr + +func (p SwigcptrBase) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrBase) SwigIsBase() { +} + +func (p SwigcptrBase) DirectorInterface() interface{} { + return nil +} + +var _wrap_new_Base unsafe.Pointer + +func _swig_wrap_new_Base(base float64) (_ SwigcptrBase) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Base, _swig_p) + return +} + +func NewBase(arg1 float64) (_swig_ret Base) { + return _swig_wrap_new_Base(arg1) +} + +var _wrap_delete_Base unsafe.Pointer + +func _swig_wrap_delete_Base(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Base, _swig_p) + return +} + +func DeleteBase(arg1 Base) { + _swig_wrap_delete_Base(arg1.Swigcptr()) +} + +var _wrap_Base_Val unsafe.Pointer + +func _swig_wrap_Base_Val(base SwigcptrBase, _ uintptr) (_ SwigcptrDoubleHolder) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Base_Val, _swig_p) + return +} + +func (arg1 SwigcptrBase) Val(arg2 DoubleHolder) (_swig_ret DoubleHolder) { + return _swig_wrap_Base_Val(arg1, arg2.Swigcptr()) +} + +var _wrap_Base_Ref unsafe.Pointer + +func _swig_wrap_Base_Ref(base SwigcptrBase, _ uintptr) (_ SwigcptrDoubleHolder) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Base_Ref, _swig_p) + return +} + +func (arg1 SwigcptrBase) Ref(arg2 DoubleHolder) (_swig_ret DoubleHolder) { + return _swig_wrap_Base_Ref(arg1, arg2.Swigcptr()) +} + +var _wrap_Base_Ptr unsafe.Pointer + +func _swig_wrap_Base_Ptr(base SwigcptrBase, _ uintptr) (_ SwigcptrDoubleHolder) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Base_Ptr, _swig_p) + return +} + +func (arg1 SwigcptrBase) Ptr(arg2 DoubleHolder) (_swig_ret DoubleHolder) { + return _swig_wrap_Base_Ptr(arg1, arg2.Swigcptr()) +} + +var _wrap_Base_FullyOverloaded__SWIG_0 unsafe.Pointer + +func _swig_wrap_Base_FullyOverloaded__SWIG_0(base SwigcptrBase, _ int) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Base_FullyOverloaded__SWIG_0, _swig_p) + return +} + +func (arg1 SwigcptrBase) FullyOverloaded__SWIG_0(arg2 int) (_swig_ret string) { + return _swig_wrap_Base_FullyOverloaded__SWIG_0(arg1, arg2) +} + +var _wrap_Base_FullyOverloaded__SWIG_1 unsafe.Pointer + +func _swig_wrap_Base_FullyOverloaded__SWIG_1(base SwigcptrBase, _ bool) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Base_FullyOverloaded__SWIG_1, _swig_p) + return +} + +func (arg1 SwigcptrBase) FullyOverloaded__SWIG_1(arg2 bool) (_swig_ret string) { + return _swig_wrap_Base_FullyOverloaded__SWIG_1(arg1, arg2) +} + +func (p SwigcptrBase) FullyOverloaded(a ...interface{}) string { + argc := len(a) + if argc == 1 { + if _, ok := a[0].(bool); !ok { + goto check_1 + } + return p.FullyOverloaded__SWIG_1(a[0].(bool)) + } +check_1: + if argc == 1 { + return p.FullyOverloaded__SWIG_0(a[0].(int)) + } + panic("No match for overloaded function call") +} + +var _wrap_Base_SemiOverloaded__SWIG_0 unsafe.Pointer + +func _swig_wrap_Base_SemiOverloaded__SWIG_0(base SwigcptrBase, _ int) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Base_SemiOverloaded__SWIG_0, _swig_p) + return +} + +func (arg1 SwigcptrBase) SemiOverloaded__SWIG_0(arg2 int) (_swig_ret string) { + return _swig_wrap_Base_SemiOverloaded__SWIG_0(arg1, arg2) +} + +var _wrap_Base_SemiOverloaded__SWIG_1 unsafe.Pointer + +func _swig_wrap_Base_SemiOverloaded__SWIG_1(base SwigcptrBase, _ bool) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Base_SemiOverloaded__SWIG_1, _swig_p) + return +} + +func (arg1 SwigcptrBase) SemiOverloaded__SWIG_1(arg2 bool) (_swig_ret string) { + return _swig_wrap_Base_SemiOverloaded__SWIG_1(arg1, arg2) +} + +func (p SwigcptrBase) SemiOverloaded(a ...interface{}) string { + argc := len(a) + if argc == 1 { + if _, ok := a[0].(bool); !ok { + goto check_1 + } + return p.SemiOverloaded__SWIG_1(a[0].(bool)) + } +check_1: + if argc == 1 { + return p.SemiOverloaded__SWIG_0(a[0].(int)) + } + panic("No match for overloaded function call") +} + +var _wrap_Base_DefaultParms__SWIG_0 unsafe.Pointer + +func _swig_wrap_Base_DefaultParms__SWIG_0(base SwigcptrBase, _ int, _ float64) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Base_DefaultParms__SWIG_0, _swig_p) + return +} + +func (arg1 SwigcptrBase) DefaultParms__SWIG_0(arg2 int, arg3 float64) (_swig_ret string) { + return _swig_wrap_Base_DefaultParms__SWIG_0(arg1, arg2, arg3) +} + +var _wrap_Base_DefaultParms__SWIG_1 unsafe.Pointer + +func _swig_wrap_Base_DefaultParms__SWIG_1(base SwigcptrBase, _ int) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Base_DefaultParms__SWIG_1, _swig_p) + return +} + +func (arg1 SwigcptrBase) DefaultParms__SWIG_1(arg2 int) (_swig_ret string) { + return _swig_wrap_Base_DefaultParms__SWIG_1(arg1, arg2) +} + +func (p SwigcptrBase) DefaultParms(a ...interface{}) string { + argc := len(a) + if argc == 1 { + return p.DefaultParms__SWIG_1(a[0].(int)) + } + if argc == 2 { + return p.DefaultParms__SWIG_0(a[0].(int), a[1].(float64)) + } + panic("No match for overloaded function call") +} + +type Base interface { + Swigcptr() uintptr + SwigIsBase() + DirectorInterface() interface{} + Val(arg2 DoubleHolder) (_swig_ret DoubleHolder) + Ref(arg2 DoubleHolder) (_swig_ret DoubleHolder) + Ptr(arg2 DoubleHolder) (_swig_ret DoubleHolder) + FullyOverloaded(a ...interface{}) string + SemiOverloaded(a ...interface{}) string + DefaultParms(a ...interface{}) string +} + +type _swig_DirectorDerived struct { + SwigcptrDerived + v interface{} +} + +func (p *_swig_DirectorDerived) Swigcptr() uintptr { + return p.SwigcptrDerived.Swigcptr() +} + +func (p *_swig_DirectorDerived) SwigIsDerived() { +} + +func (p *_swig_DirectorDerived) DirectorInterface() interface{} { + return p.v +} + +var _wrap__swig_NewDirectorDerivedDerived unsafe.Pointer + +func _swig_NewDirectorDerivedDerived(_swig_director *_swig_DirectorDerived, _ float64) (_swig_ret SwigcptrDerived) { + _swig_p := uintptr(unsafe.Pointer(&_swig_director)) + _cgo_runtime_cgocall(_wrap__swig_NewDirectorDerivedDerived, _swig_p) + return +} + +func NewDirectorDerived(v interface{}, arg1 float64) Derived { + p := &_swig_DirectorDerived{0, v} + p.SwigcptrDerived = _swig_NewDirectorDerivedDerived(p, arg1) + return p +} + +var _wrap_DeleteDirectorDerived unsafe.Pointer + +func _swig_wrap_DeleteDirectorDerived(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_DeleteDirectorDerived, _swig_p) + return +} + +func DeleteDirectorDerived(arg1 Derived) { + _swig_wrap_DeleteDirectorDerived(arg1.Swigcptr()) +} + +func Swiggo_DeleteDirector_Derived(p *_swig_DirectorDerived) { + p.SwigcptrDerived = 0 +} + +type _swig_DirectorInterfaceDerivedVal interface { + Val(DoubleHolder) DoubleHolder +} + +var _wrap__swig_DirectorDerived_upcall_Val unsafe.Pointer + +func _swig_wrap__swig_DirectorDerived_upcall_Val(_swig_ptr SwigcptrDerived, _ uintptr) (_swig_ret SwigcptrDoubleHolder) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) + _cgo_runtime_cgocall(_wrap__swig_DirectorDerived_upcall_Val, _swig_p) + return +} + +func (swig_p *_swig_DirectorDerived) Val(x DoubleHolder) DoubleHolder { + if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceDerivedVal); swig_ok { + return swig_g.Val(x) + } + var swig_r DoubleHolder + swig_r = _swig_wrap__swig_DirectorDerived_upcall_Val(swig_p.SwigcptrDerived, x.Swigcptr()) + return swig_r +} + +func DirectorDerivedVal(p Derived, arg2 DoubleHolder) DoubleHolder { + var swig_r DoubleHolder + swig_r = _swig_wrap__swig_DirectorDerived_upcall_Val(p.(*_swig_DirectorDerived).SwigcptrDerived, arg2.Swigcptr()) + return swig_r +} + +func Swig_DirectorDerived_callback_Val(p *_swig_DirectorDerived, arg2 uintptr) (swig_result SwigcptrDoubleHolder) { + var swig_r SwigcptrDoubleHolder + swig_r = SwigcptrDoubleHolder(p.Val(SwigcptrDoubleHolder(arg2)).Swigcptr()) + return swig_r +} + +type _swig_DirectorInterfaceDerivedRef interface { + Ref(DoubleHolder) DoubleHolder +} + +var _wrap__swig_DirectorDerived_upcall_Ref unsafe.Pointer + +func _swig_wrap__swig_DirectorDerived_upcall_Ref(_swig_ptr SwigcptrDerived, _ uintptr) (_swig_ret SwigcptrDoubleHolder) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) + _cgo_runtime_cgocall(_wrap__swig_DirectorDerived_upcall_Ref, _swig_p) + return +} + +func (swig_p *_swig_DirectorDerived) Ref(x DoubleHolder) DoubleHolder { + if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceDerivedRef); swig_ok { + return swig_g.Ref(x) + } + var swig_r DoubleHolder + swig_r = _swig_wrap__swig_DirectorDerived_upcall_Ref(swig_p.SwigcptrDerived, x.Swigcptr()) + return swig_r +} + +func DirectorDerivedRef(p Derived, arg2 DoubleHolder) DoubleHolder { + var swig_r DoubleHolder + swig_r = _swig_wrap__swig_DirectorDerived_upcall_Ref(p.(*_swig_DirectorDerived).SwigcptrDerived, arg2.Swigcptr()) + return swig_r +} + +func Swig_DirectorDerived_callback_Ref(p *_swig_DirectorDerived, arg2 uintptr) (swig_result SwigcptrDoubleHolder) { + var swig_r SwigcptrDoubleHolder + swig_r = SwigcptrDoubleHolder(p.Ref(SwigcptrDoubleHolder(arg2)).Swigcptr()) + return swig_r +} + +type _swig_DirectorInterfaceDerivedPtr interface { + Ptr(DoubleHolder) DoubleHolder +} + +var _wrap__swig_DirectorDerived_upcall_Ptr unsafe.Pointer + +func _swig_wrap__swig_DirectorDerived_upcall_Ptr(_swig_ptr SwigcptrDerived, _ uintptr) (_swig_ret SwigcptrDoubleHolder) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) + _cgo_runtime_cgocall(_wrap__swig_DirectorDerived_upcall_Ptr, _swig_p) + return +} + +func (swig_p *_swig_DirectorDerived) Ptr(x DoubleHolder) DoubleHolder { + if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceDerivedPtr); swig_ok { + return swig_g.Ptr(x) + } + var swig_r DoubleHolder + swig_r = _swig_wrap__swig_DirectorDerived_upcall_Ptr(swig_p.SwigcptrDerived, x.Swigcptr()) + return swig_r +} + +func DirectorDerivedPtr(p Derived, arg2 DoubleHolder) DoubleHolder { + var swig_r DoubleHolder + swig_r = _swig_wrap__swig_DirectorDerived_upcall_Ptr(p.(*_swig_DirectorDerived).SwigcptrDerived, arg2.Swigcptr()) + return swig_r +} + +func Swig_DirectorDerived_callback_Ptr(p *_swig_DirectorDerived, arg2 uintptr) (swig_result SwigcptrDoubleHolder) { + var swig_r SwigcptrDoubleHolder + swig_r = SwigcptrDoubleHolder(p.Ptr(SwigcptrDoubleHolder(arg2)).Swigcptr()) + return swig_r +} + +type _swig_DirectorInterfaceDerivedFullyOverloaded__SWIG_0 interface { + FullyOverloaded__SWIG_0(int) string +} + +var _wrap__swig_DirectorDerived_upcall_FullyOverloaded__SWIG_0 unsafe.Pointer + +func _swig_wrap__swig_DirectorDerived_upcall_FullyOverloaded__SWIG_0(_swig_ptr SwigcptrDerived, _ int) (_swig_ret string) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) + _cgo_runtime_cgocall(_wrap__swig_DirectorDerived_upcall_FullyOverloaded__SWIG_0, _swig_p) + return +} + +func (swig_p *_swig_DirectorDerived) FullyOverloaded__SWIG_0(x int) string { + if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceDerivedFullyOverloaded__SWIG_0); swig_ok { + return swig_g.FullyOverloaded__SWIG_0(x) + } + var swig_r string + swig_r = _swig_wrap__swig_DirectorDerived_upcall_FullyOverloaded__SWIG_0(swig_p.SwigcptrDerived, x) + return swig_r +} + +func DirectorDerivedFullyOverloaded__SWIG_0(p Derived, arg2 int) string { + var swig_r string + swig_r = _swig_wrap__swig_DirectorDerived_upcall_FullyOverloaded__SWIG_0(p.(*_swig_DirectorDerived).SwigcptrDerived, arg2) + return swig_r +} + +func Swig_DirectorDerived_callback_FullyOverloaded__SWIG_0(p *_swig_DirectorDerived, arg2 int) (swig_result string) { + var swig_r string + swig_r = p.FullyOverloaded__SWIG_0(arg2) + return swig_r +} + +type _swig_DirectorInterfaceDerivedFullyOverloaded__SWIG_1 interface { + FullyOverloaded__SWIG_1(bool) string +} + +var _wrap__swig_DirectorDerived_upcall_FullyOverloaded__SWIG_1 unsafe.Pointer + +func _swig_wrap__swig_DirectorDerived_upcall_FullyOverloaded__SWIG_1(_swig_ptr SwigcptrDerived, _ bool) (_swig_ret string) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) + _cgo_runtime_cgocall(_wrap__swig_DirectorDerived_upcall_FullyOverloaded__SWIG_1, _swig_p) + return +} + +func (swig_p *_swig_DirectorDerived) FullyOverloaded__SWIG_1(x bool) string { + if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceDerivedFullyOverloaded__SWIG_1); swig_ok { + return swig_g.FullyOverloaded__SWIG_1(x) + } + var swig_r string + swig_r = _swig_wrap__swig_DirectorDerived_upcall_FullyOverloaded__SWIG_1(swig_p.SwigcptrDerived, x) + return swig_r +} + +func DirectorDerivedFullyOverloaded__SWIG_1(p Derived, arg2 bool) string { + var swig_r string + swig_r = _swig_wrap__swig_DirectorDerived_upcall_FullyOverloaded__SWIG_1(p.(*_swig_DirectorDerived).SwigcptrDerived, arg2) + return swig_r +} + +func Swig_DirectorDerived_callback_FullyOverloaded__SWIG_1(p *_swig_DirectorDerived, arg2 bool) (swig_result string) { + var swig_r string + swig_r = p.FullyOverloaded__SWIG_1(arg2) + return swig_r +} + +func (p _swig_DirectorDerived) FullyOverloaded(a ...interface{}) string { + argc := len(a) + if argc == 1 { + if _, ok := a[0].(bool); !ok { + goto check_1 + } + return p.FullyOverloaded__SWIG_1(a[0].(bool)) + } +check_1: + if argc == 1 { + return p.FullyOverloaded__SWIG_0(a[0].(int)) + } + panic("No match for overloaded function call") +} + +func DirectorDerivedFullyOverloaded(p *_swig_DirectorDerived, a ...interface{}) string { + argc := len(a) + if argc == 1 { + if _, ok := a[0].(bool); !ok { + goto check_1 + } + return DirectorDerivedFullyOverloaded__SWIG_1(p, a[0].(bool)) + } +check_1: + if argc == 1 { + return DirectorDerivedFullyOverloaded__SWIG_0(p, a[0].(int)) + } + panic("No match for overloaded function call") +} + +type _swig_DirectorInterfaceDerivedSemiOverloaded interface { + SemiOverloaded(int) string +} + +var _wrap__swig_DirectorDerived_upcall_SemiOverloaded unsafe.Pointer + +func _swig_wrap__swig_DirectorDerived_upcall_SemiOverloaded(_swig_ptr SwigcptrDerived, _ int) (_swig_ret string) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) + _cgo_runtime_cgocall(_wrap__swig_DirectorDerived_upcall_SemiOverloaded, _swig_p) + return +} + +func (swig_p *_swig_DirectorDerived) SemiOverloaded(x int) string { + if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceDerivedSemiOverloaded); swig_ok { + return swig_g.SemiOverloaded(x) + } + var swig_r string + swig_r = _swig_wrap__swig_DirectorDerived_upcall_SemiOverloaded(swig_p.SwigcptrDerived, x) + return swig_r +} + +func DirectorDerivedSemiOverloaded(p Derived, arg2 int) string { + var swig_r string + swig_r = _swig_wrap__swig_DirectorDerived_upcall_SemiOverloaded(p.(*_swig_DirectorDerived).SwigcptrDerived, arg2) + return swig_r +} + +func Swig_DirectorDerived_callback_SemiOverloaded(p *_swig_DirectorDerived, arg2 int) (swig_result string) { + var swig_r string + swig_r = p.SemiOverloaded(arg2) + return swig_r +} + +type _swig_DirectorInterfaceDerivedSemiOverloaded__SWIG_1 interface { + SemiOverloaded__SWIG_1(bool) string +} + +var _wrap__swig_DirectorDerived_upcall_SemiOverloaded__SWIG_1 unsafe.Pointer + +func _swig_wrap__swig_DirectorDerived_upcall_SemiOverloaded__SWIG_1(_swig_ptr SwigcptrDerived, _ bool) (_swig_ret string) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) + _cgo_runtime_cgocall(_wrap__swig_DirectorDerived_upcall_SemiOverloaded__SWIG_1, _swig_p) + return +} + +func (swig_p *_swig_DirectorDerived) SemiOverloaded__SWIG_1(x bool) string { + if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceDerivedSemiOverloaded__SWIG_1); swig_ok { + return swig_g.SemiOverloaded__SWIG_1(x) + } + var swig_r string + swig_r = _swig_wrap__swig_DirectorDerived_upcall_SemiOverloaded__SWIG_1(swig_p.SwigcptrDerived, x) + return swig_r +} + +func DirectorDerivedSemiOverloaded__SWIG_1(p Derived, arg2 bool) string { + var swig_r string + swig_r = _swig_wrap__swig_DirectorDerived_upcall_SemiOverloaded__SWIG_1(p.(*_swig_DirectorDerived).SwigcptrDerived, arg2) + return swig_r +} + +func Swig_DirectorDerived_callback_SemiOverloaded__SWIG_1(p *_swig_DirectorDerived, arg2 bool) (swig_result string) { + var swig_r string + swig_r = p.SemiOverloaded__SWIG_1(arg2) + return swig_r +} + +type _swig_DirectorInterfaceDerivedDefaultParms__SWIG_0 interface { + DefaultParms__SWIG_0(int, float64) string +} + +var _wrap__swig_DirectorDerived_upcall_DefaultParms__SWIG_0 unsafe.Pointer + +func _swig_wrap__swig_DirectorDerived_upcall_DefaultParms__SWIG_0(_swig_ptr SwigcptrDerived, _ int, _ float64) (_swig_ret string) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) + _cgo_runtime_cgocall(_wrap__swig_DirectorDerived_upcall_DefaultParms__SWIG_0, _swig_p) + return +} + +func (swig_p *_swig_DirectorDerived) DefaultParms__SWIG_0(x int, y float64) string { + if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceDerivedDefaultParms__SWIG_0); swig_ok { + return swig_g.DefaultParms__SWIG_0(x, y) + } + var swig_r string + swig_r = _swig_wrap__swig_DirectorDerived_upcall_DefaultParms__SWIG_0(swig_p.SwigcptrDerived, x, y) + return swig_r +} + +func DirectorDerivedDefaultParms__SWIG_0(p Derived, arg2 int, arg3 float64) string { + var swig_r string + swig_r = _swig_wrap__swig_DirectorDerived_upcall_DefaultParms__SWIG_0(p.(*_swig_DirectorDerived).SwigcptrDerived, arg2, arg3) + return swig_r +} + +func Swig_DirectorDerived_callback_DefaultParms__SWIG_0(p *_swig_DirectorDerived, arg2 int, arg3 float64) (swig_result string) { + var swig_r string + swig_r = p.DefaultParms__SWIG_0(arg2, arg3) + return swig_r +} + +type _swig_DirectorInterfaceDerivedDefaultParms__SWIG_1 interface { + DefaultParms__SWIG_1(int) string +} + +var _wrap__swig_DirectorDerived_upcall_DefaultParms__SWIG_1 unsafe.Pointer + +func _swig_wrap__swig_DirectorDerived_upcall_DefaultParms__SWIG_1(_swig_ptr SwigcptrDerived, _ int) (_swig_ret string) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) + _cgo_runtime_cgocall(_wrap__swig_DirectorDerived_upcall_DefaultParms__SWIG_1, _swig_p) + return +} + +func (swig_p *_swig_DirectorDerived) DefaultParms__SWIG_1(x int) string { + if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceDerivedDefaultParms__SWIG_1); swig_ok { + return swig_g.DefaultParms__SWIG_1(x) + } + var swig_r string + swig_r = _swig_wrap__swig_DirectorDerived_upcall_DefaultParms__SWIG_1(swig_p.SwigcptrDerived, x) + return swig_r +} + +func DirectorDerivedDefaultParms__SWIG_1(p Derived, arg2 int) string { + var swig_r string + swig_r = _swig_wrap__swig_DirectorDerived_upcall_DefaultParms__SWIG_1(p.(*_swig_DirectorDerived).SwigcptrDerived, arg2) + return swig_r +} + +func Swig_DirectorDerived_callback_DefaultParms__SWIG_1(p *_swig_DirectorDerived, arg2 int) (swig_result string) { + var swig_r string + swig_r = p.DefaultParms__SWIG_1(arg2) + return swig_r +} + +func (p _swig_DirectorDerived) DefaultParms(a ...interface{}) string { + argc := len(a) + if argc == 1 { + return p.DefaultParms__SWIG_1(a[0].(int)) + } + if argc == 2 { + return p.DefaultParms__SWIG_0(a[0].(int), a[1].(float64)) + } + panic("No match for overloaded function call") +} + +func DirectorDerivedDefaultParms(p *_swig_DirectorDerived, a ...interface{}) string { + argc := len(a) + if argc == 1 { + return DirectorDerivedDefaultParms__SWIG_1(p, a[0].(int)) + } + if argc == 2 { + return DirectorDerivedDefaultParms__SWIG_0(p, a[0].(int), a[1].(float64)) + } + panic("No match for overloaded function call") +} + +type SwigcptrDerived uintptr + +func (p SwigcptrDerived) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrDerived) SwigIsDerived() { +} + +func (p SwigcptrDerived) DirectorInterface() interface{} { + return nil +} + +var _wrap_new_Derived unsafe.Pointer + +func _swig_wrap_new_Derived(base float64) (_ SwigcptrDerived) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Derived, _swig_p) + return +} + +func NewDerived(arg1 float64) (_swig_ret Derived) { + return _swig_wrap_new_Derived(arg1) +} + +var _wrap_delete_Derived unsafe.Pointer + +func _swig_wrap_delete_Derived(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Derived, _swig_p) + return +} + +func DeleteDerived(arg1 Derived) { + _swig_wrap_delete_Derived(arg1.Swigcptr()) +} + +var _wrap_Derived_Val unsafe.Pointer + +func _swig_wrap_Derived_Val(base SwigcptrDerived, _ uintptr) (_ SwigcptrDoubleHolder) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Derived_Val, _swig_p) + return +} + +func (arg1 SwigcptrDerived) Val(arg2 DoubleHolder) (_swig_ret DoubleHolder) { + return _swig_wrap_Derived_Val(arg1, arg2.Swigcptr()) +} + +var _wrap_Derived_Ref unsafe.Pointer + +func _swig_wrap_Derived_Ref(base SwigcptrDerived, _ uintptr) (_ SwigcptrDoubleHolder) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Derived_Ref, _swig_p) + return +} + +func (arg1 SwigcptrDerived) Ref(arg2 DoubleHolder) (_swig_ret DoubleHolder) { + return _swig_wrap_Derived_Ref(arg1, arg2.Swigcptr()) +} + +var _wrap_Derived_Ptr unsafe.Pointer + +func _swig_wrap_Derived_Ptr(base SwigcptrDerived, _ uintptr) (_ SwigcptrDoubleHolder) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Derived_Ptr, _swig_p) + return +} + +func (arg1 SwigcptrDerived) Ptr(arg2 DoubleHolder) (_swig_ret DoubleHolder) { + return _swig_wrap_Derived_Ptr(arg1, arg2.Swigcptr()) +} + +var _wrap_Derived_FullyOverloaded__SWIG_0 unsafe.Pointer + +func _swig_wrap_Derived_FullyOverloaded__SWIG_0(base SwigcptrDerived, _ int) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Derived_FullyOverloaded__SWIG_0, _swig_p) + return +} + +func (arg1 SwigcptrDerived) FullyOverloaded__SWIG_0(arg2 int) (_swig_ret string) { + return _swig_wrap_Derived_FullyOverloaded__SWIG_0(arg1, arg2) +} + +var _wrap_Derived_FullyOverloaded__SWIG_1 unsafe.Pointer + +func _swig_wrap_Derived_FullyOverloaded__SWIG_1(base SwigcptrDerived, _ bool) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Derived_FullyOverloaded__SWIG_1, _swig_p) + return +} + +func (arg1 SwigcptrDerived) FullyOverloaded__SWIG_1(arg2 bool) (_swig_ret string) { + return _swig_wrap_Derived_FullyOverloaded__SWIG_1(arg1, arg2) +} + +func (p SwigcptrDerived) FullyOverloaded(a ...interface{}) string { + argc := len(a) + if argc == 1 { + if _, ok := a[0].(bool); !ok { + goto check_1 + } + return p.FullyOverloaded__SWIG_1(a[0].(bool)) + } +check_1: + if argc == 1 { + return p.FullyOverloaded__SWIG_0(a[0].(int)) + } + panic("No match for overloaded function call") +} + +var _wrap_Derived_SemiOverloaded unsafe.Pointer + +func _swig_wrap_Derived_SemiOverloaded(base SwigcptrDerived, _ int) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Derived_SemiOverloaded, _swig_p) + return +} + +func (arg1 SwigcptrDerived) SemiOverloaded(arg2 int) (_swig_ret string) { + return _swig_wrap_Derived_SemiOverloaded(arg1, arg2) +} + +var _wrap_Derived_DefaultParms__SWIG_0 unsafe.Pointer + +func _swig_wrap_Derived_DefaultParms__SWIG_0(base SwigcptrDerived, _ int, _ float64) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Derived_DefaultParms__SWIG_0, _swig_p) + return +} + +func (arg1 SwigcptrDerived) DefaultParms__SWIG_0(arg2 int, arg3 float64) (_swig_ret string) { + return _swig_wrap_Derived_DefaultParms__SWIG_0(arg1, arg2, arg3) +} + +var _wrap_Derived_DefaultParms__SWIG_1 unsafe.Pointer + +func _swig_wrap_Derived_DefaultParms__SWIG_1(base SwigcptrDerived, _ int) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Derived_DefaultParms__SWIG_1, _swig_p) + return +} + +func (arg1 SwigcptrDerived) DefaultParms__SWIG_1(arg2 int) (_swig_ret string) { + return _swig_wrap_Derived_DefaultParms__SWIG_1(arg1, arg2) +} + +func (p SwigcptrDerived) DefaultParms(a ...interface{}) string { + argc := len(a) + if argc == 1 { + return p.DefaultParms__SWIG_1(a[0].(int)) + } + if argc == 2 { + return p.DefaultParms__SWIG_0(a[0].(int), a[1].(float64)) + } + panic("No match for overloaded function call") +} + +func (p SwigcptrDerived) SwigIsBase() { +} + +func (p SwigcptrDerived) SwigGetBase() Base { + return SwigcptrBase(p.Swigcptr()) +} + +type Derived interface { + Swigcptr() uintptr + SwigIsDerived() + DirectorInterface() interface{} + Val(arg2 DoubleHolder) (_swig_ret DoubleHolder) + Ref(arg2 DoubleHolder) (_swig_ret DoubleHolder) + Ptr(arg2 DoubleHolder) (_swig_ret DoubleHolder) + FullyOverloaded(a ...interface{}) string + SemiOverloaded(arg2 int) (_swig_ret string) + DefaultParms(a ...interface{}) string + SwigIsBase() + SwigGetBase() Base +} + +type SwigcptrCaller uintptr + +func (p SwigcptrCaller) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrCaller) SwigIsCaller() { +} + +var _wrap_new_Caller unsafe.Pointer + +func _swig_wrap_new_Caller() (base SwigcptrCaller) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Caller, _swig_p) + return +} + +func NewCaller() (_swig_ret Caller) { + return _swig_wrap_new_Caller() +} + +var _wrap_delete_Caller unsafe.Pointer + +func _swig_wrap_delete_Caller(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Caller, _swig_p) + return +} + +func DeleteCaller(arg1 Caller) { + _swig_wrap_delete_Caller(arg1.Swigcptr()) +} + +var _wrap_Caller_set unsafe.Pointer + +func _swig_wrap_Caller_set(base SwigcptrCaller, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Caller_set, _swig_p) + return +} + +func (arg1 SwigcptrCaller) Set(arg2 Base) { + _swig_wrap_Caller_set(arg1, arg2.Swigcptr()) +} + +var _wrap_Caller_reset unsafe.Pointer + +func _swig_wrap_Caller_reset(base SwigcptrCaller) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Caller_reset, _swig_p) + return +} + +func (arg1 SwigcptrCaller) Reset() { + _swig_wrap_Caller_reset(arg1) +} + +var _wrap_Caller_ValCall unsafe.Pointer + +func _swig_wrap_Caller_ValCall(base SwigcptrCaller, _ uintptr) (_ SwigcptrDoubleHolder) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Caller_ValCall, _swig_p) + return +} + +func (arg1 SwigcptrCaller) ValCall(arg2 DoubleHolder) (_swig_ret DoubleHolder) { + return _swig_wrap_Caller_ValCall(arg1, arg2.Swigcptr()) +} + +var _wrap_Caller_RefCall unsafe.Pointer + +func _swig_wrap_Caller_RefCall(base SwigcptrCaller, _ uintptr) (_ SwigcptrDoubleHolder) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Caller_RefCall, _swig_p) + return +} + +func (arg1 SwigcptrCaller) RefCall(arg2 DoubleHolder) (_swig_ret DoubleHolder) { + return _swig_wrap_Caller_RefCall(arg1, arg2.Swigcptr()) +} + +var _wrap_Caller_PtrCall unsafe.Pointer + +func _swig_wrap_Caller_PtrCall(base SwigcptrCaller, _ uintptr) (_ SwigcptrDoubleHolder) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Caller_PtrCall, _swig_p) + return +} + +func (arg1 SwigcptrCaller) PtrCall(arg2 DoubleHolder) (_swig_ret DoubleHolder) { + return _swig_wrap_Caller_PtrCall(arg1, arg2.Swigcptr()) +} + +var _wrap_Caller_FullyOverloadedCall__SWIG_0 unsafe.Pointer + +func _swig_wrap_Caller_FullyOverloadedCall__SWIG_0(base SwigcptrCaller, _ int) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Caller_FullyOverloadedCall__SWIG_0, _swig_p) + return +} + +func (arg1 SwigcptrCaller) FullyOverloadedCall__SWIG_0(arg2 int) (_swig_ret string) { + return _swig_wrap_Caller_FullyOverloadedCall__SWIG_0(arg1, arg2) +} + +var _wrap_Caller_FullyOverloadedCall__SWIG_1 unsafe.Pointer + +func _swig_wrap_Caller_FullyOverloadedCall__SWIG_1(base SwigcptrCaller, _ bool) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Caller_FullyOverloadedCall__SWIG_1, _swig_p) + return +} + +func (arg1 SwigcptrCaller) FullyOverloadedCall__SWIG_1(arg2 bool) (_swig_ret string) { + return _swig_wrap_Caller_FullyOverloadedCall__SWIG_1(arg1, arg2) +} + +func (p SwigcptrCaller) FullyOverloadedCall(a ...interface{}) string { + argc := len(a) + if argc == 1 { + if _, ok := a[0].(bool); !ok { + goto check_1 + } + return p.FullyOverloadedCall__SWIG_1(a[0].(bool)) + } +check_1: + if argc == 1 { + return p.FullyOverloadedCall__SWIG_0(a[0].(int)) + } + panic("No match for overloaded function call") +} + +var _wrap_Caller_SemiOverloadedCall__SWIG_0 unsafe.Pointer + +func _swig_wrap_Caller_SemiOverloadedCall__SWIG_0(base SwigcptrCaller, _ int) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Caller_SemiOverloadedCall__SWIG_0, _swig_p) + return +} + +func (arg1 SwigcptrCaller) SemiOverloadedCall__SWIG_0(arg2 int) (_swig_ret string) { + return _swig_wrap_Caller_SemiOverloadedCall__SWIG_0(arg1, arg2) +} + +var _wrap_Caller_SemiOverloadedCall__SWIG_1 unsafe.Pointer + +func _swig_wrap_Caller_SemiOverloadedCall__SWIG_1(base SwigcptrCaller, _ bool) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Caller_SemiOverloadedCall__SWIG_1, _swig_p) + return +} + +func (arg1 SwigcptrCaller) SemiOverloadedCall__SWIG_1(arg2 bool) (_swig_ret string) { + return _swig_wrap_Caller_SemiOverloadedCall__SWIG_1(arg1, arg2) +} + +func (p SwigcptrCaller) SemiOverloadedCall(a ...interface{}) string { + argc := len(a) + if argc == 1 { + if _, ok := a[0].(bool); !ok { + goto check_1 + } + return p.SemiOverloadedCall__SWIG_1(a[0].(bool)) + } +check_1: + if argc == 1 { + return p.SemiOverloadedCall__SWIG_0(a[0].(int)) + } + panic("No match for overloaded function call") +} + +var _wrap_Caller_DefaultParmsCall__SWIG_0 unsafe.Pointer + +func _swig_wrap_Caller_DefaultParmsCall__SWIG_0(base SwigcptrCaller, _ int) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Caller_DefaultParmsCall__SWIG_0, _swig_p) + return +} + +func (arg1 SwigcptrCaller) DefaultParmsCall__SWIG_0(arg2 int) (_swig_ret string) { + return _swig_wrap_Caller_DefaultParmsCall__SWIG_0(arg1, arg2) +} + +var _wrap_Caller_DefaultParmsCall__SWIG_1 unsafe.Pointer + +func _swig_wrap_Caller_DefaultParmsCall__SWIG_1(base SwigcptrCaller, _ int, _ float64) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Caller_DefaultParmsCall__SWIG_1, _swig_p) + return +} + +func (arg1 SwigcptrCaller) DefaultParmsCall__SWIG_1(arg2 int, arg3 float64) (_swig_ret string) { + return _swig_wrap_Caller_DefaultParmsCall__SWIG_1(arg1, arg2, arg3) +} + +func (p SwigcptrCaller) DefaultParmsCall(a ...interface{}) string { + argc := len(a) + if argc == 1 { + return p.DefaultParmsCall__SWIG_0(a[0].(int)) + } + if argc == 2 { + return p.DefaultParmsCall__SWIG_1(a[0].(int), a[1].(float64)) + } + panic("No match for overloaded function call") +} + +type Caller interface { + Swigcptr() uintptr + SwigIsCaller() + Set(arg2 Base) + Reset() + ValCall(arg2 DoubleHolder) (_swig_ret DoubleHolder) + RefCall(arg2 DoubleHolder) (_swig_ret DoubleHolder) + PtrCall(arg2 DoubleHolder) (_swig_ret DoubleHolder) + FullyOverloadedCall(a ...interface{}) string + SemiOverloadedCall(a ...interface{}) string + DefaultParmsCall(a ...interface{}) string +} + +type _swig_DirectorBaseClass struct { + SwigcptrBaseClass + v interface{} +} + +func (p *_swig_DirectorBaseClass) Swigcptr() uintptr { + return p.SwigcptrBaseClass.Swigcptr() +} + +func (p *_swig_DirectorBaseClass) SwigIsBaseClass() { +} + +func (p *_swig_DirectorBaseClass) DirectorInterface() interface{} { + return p.v +} + +var _wrap__swig_NewDirectorBaseClassBaseClass unsafe.Pointer + +func _swig_NewDirectorBaseClassBaseClass(_swig_director *_swig_DirectorBaseClass) (_swig_ret SwigcptrBaseClass) { + _swig_p := uintptr(unsafe.Pointer(&_swig_director)) + _cgo_runtime_cgocall(_wrap__swig_NewDirectorBaseClassBaseClass, _swig_p) + return +} + +func NewDirectorBaseClass(v interface{}) BaseClass { + p := &_swig_DirectorBaseClass{0, v} + p.SwigcptrBaseClass = _swig_NewDirectorBaseClassBaseClass(p) + return p +} + +var _wrap_DeleteDirectorBaseClass unsafe.Pointer + +func _swig_wrap_DeleteDirectorBaseClass(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_DeleteDirectorBaseClass, _swig_p) + return +} + +func DeleteDirectorBaseClass(arg1 BaseClass) { + _swig_wrap_DeleteDirectorBaseClass(arg1.Swigcptr()) +} + +func Swiggo_DeleteDirector_BaseClass(p *_swig_DirectorBaseClass) { + p.SwigcptrBaseClass = 0 +} + +type _swig_DirectorInterfaceBaseClassDofoo interface { + Dofoo(*int, *int, *int) int +} + +var _wrap__swig_DirectorBaseClass_upcall_Dofoo unsafe.Pointer + +func _swig_wrap__swig_DirectorBaseClass_upcall_Dofoo(_swig_ptr SwigcptrBaseClass, _ *int, _ *int, _ *int) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) + _cgo_runtime_cgocall(_wrap__swig_DirectorBaseClass_upcall_Dofoo, _swig_p) + return +} + +func (swig_p *_swig_DirectorBaseClass) Dofoo(one *int, two *int, three *int) int { + if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceBaseClassDofoo); swig_ok { + return swig_g.Dofoo(one, two, three) + } + var swig_r int + swig_r = _swig_wrap__swig_DirectorBaseClass_upcall_Dofoo(swig_p.SwigcptrBaseClass, one, two, three) + return swig_r +} + +func DirectorBaseClassDofoo(p BaseClass, arg2 *int, arg3 *int, arg4 *int) int { + var swig_r int + swig_r = _swig_wrap__swig_DirectorBaseClass_upcall_Dofoo(p.(*_swig_DirectorBaseClass).SwigcptrBaseClass, arg2, arg3, arg4) + return swig_r +} + +func Swig_DirectorBaseClass_callback_dofoo(p *_swig_DirectorBaseClass, arg2 *int, arg3 *int, arg4 *int) (swig_result int) { + var swig_r int + swig_r = p.Dofoo(arg2, arg3, arg4) + return swig_r +} + +type SwigcptrBaseClass uintptr + +func (p SwigcptrBaseClass) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrBaseClass) SwigIsBaseClass() { +} + +func (p SwigcptrBaseClass) DirectorInterface() interface{} { + return nil +} + +var _wrap_delete_BaseClass unsafe.Pointer + +func _swig_wrap_delete_BaseClass(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_BaseClass, _swig_p) + return +} + +func DeleteBaseClass(arg1 BaseClass) { + _swig_wrap_delete_BaseClass(arg1.Swigcptr()) +} + +var _wrap_BaseClass_dofoo unsafe.Pointer + +func _swig_wrap_BaseClass_dofoo(base SwigcptrBaseClass, _ *int, _ *int, _ *int) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_BaseClass_dofoo, _swig_p) + return +} + +func (arg1 SwigcptrBaseClass) Dofoo(arg2 *int, arg3 *int, arg4 *int) (_swig_ret int) { + return _swig_wrap_BaseClass_dofoo(arg1, arg2, arg3, arg4) +} + +var _wrap_new_BaseClass unsafe.Pointer + +func _swig_wrap_new_BaseClass() (base SwigcptrBaseClass) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_BaseClass, _swig_p) + return +} + +func NewBaseClass() (_swig_ret BaseClass) { + return _swig_wrap_new_BaseClass() +} + +type BaseClass interface { + Swigcptr() uintptr + SwigIsBaseClass() + DirectorInterface() interface{} + Dofoo(arg2 *int, arg3 *int, arg4 *int) (_swig_ret int) +} + +type _swig_DirectorDerivedClass struct { + SwigcptrDerivedClass + v interface{} +} + +func (p *_swig_DirectorDerivedClass) Swigcptr() uintptr { + return p.SwigcptrDerivedClass.Swigcptr() +} + +func (p *_swig_DirectorDerivedClass) SwigIsDerivedClass() { +} + +func (p *_swig_DirectorDerivedClass) DirectorInterface() interface{} { + return p.v +} + +var _wrap__swig_NewDirectorDerivedClassDerivedClass unsafe.Pointer + +func _swig_NewDirectorDerivedClassDerivedClass(_swig_director *_swig_DirectorDerivedClass) (_swig_ret SwigcptrDerivedClass) { + _swig_p := uintptr(unsafe.Pointer(&_swig_director)) + _cgo_runtime_cgocall(_wrap__swig_NewDirectorDerivedClassDerivedClass, _swig_p) + return +} + +func NewDirectorDerivedClass(v interface{}) DerivedClass { + p := &_swig_DirectorDerivedClass{0, v} + p.SwigcptrDerivedClass = _swig_NewDirectorDerivedClassDerivedClass(p) + return p +} + +var _wrap_DeleteDirectorDerivedClass unsafe.Pointer + +func _swig_wrap_DeleteDirectorDerivedClass(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_DeleteDirectorDerivedClass, _swig_p) + return +} + +func DeleteDirectorDerivedClass(arg1 DerivedClass) { + _swig_wrap_DeleteDirectorDerivedClass(arg1.Swigcptr()) +} + +func Swiggo_DeleteDirector_DerivedClass(p *_swig_DirectorDerivedClass) { + p.SwigcptrDerivedClass = 0 +} + +type _swig_DirectorInterfaceDerivedClassDofoo interface { + Dofoo(*int, *int, *int) int +} + +var _wrap__swig_DirectorDerivedClass_upcall_Dofoo unsafe.Pointer + +func _swig_wrap__swig_DirectorDerivedClass_upcall_Dofoo(_swig_ptr SwigcptrDerivedClass, _ *int, _ *int, _ *int) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) + _cgo_runtime_cgocall(_wrap__swig_DirectorDerivedClass_upcall_Dofoo, _swig_p) + return +} + +func (swig_p *_swig_DirectorDerivedClass) Dofoo(one *int, two *int, three *int) int { + if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceDerivedClassDofoo); swig_ok { + return swig_g.Dofoo(one, two, three) + } + var swig_r int + swig_r = _swig_wrap__swig_DirectorDerivedClass_upcall_Dofoo(swig_p.SwigcptrDerivedClass, one, two, three) + return swig_r +} + +func DirectorDerivedClassDofoo(p DerivedClass, arg2 *int, arg3 *int, arg4 *int) int { + var swig_r int + swig_r = _swig_wrap__swig_DirectorDerivedClass_upcall_Dofoo(p.(*_swig_DirectorDerivedClass).SwigcptrDerivedClass, arg2, arg3, arg4) + return swig_r +} + +func Swig_DirectorDerivedClass_callback_dofoo(p *_swig_DirectorDerivedClass, arg2 *int, arg3 *int, arg4 *int) (swig_result int) { + var swig_r int + swig_r = p.Dofoo(arg2, arg3, arg4) + return swig_r +} + +type SwigcptrDerivedClass uintptr + +func (p SwigcptrDerivedClass) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrDerivedClass) SwigIsDerivedClass() { +} + +func (p SwigcptrDerivedClass) DirectorInterface() interface{} { + return nil +} + +var _wrap_new_DerivedClass unsafe.Pointer + +func _swig_wrap_new_DerivedClass() (base SwigcptrDerivedClass) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_DerivedClass, _swig_p) + return +} + +func NewDerivedClass() (_swig_ret DerivedClass) { + return _swig_wrap_new_DerivedClass() +} + +var _wrap_delete_DerivedClass unsafe.Pointer + +func _swig_wrap_delete_DerivedClass(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_DerivedClass, _swig_p) + return +} + +func DeleteDerivedClass(arg1 DerivedClass) { + _swig_wrap_delete_DerivedClass(arg1.Swigcptr()) +} + +var _wrap_DerivedClass_dofoo unsafe.Pointer + +func _swig_wrap_DerivedClass_dofoo(base SwigcptrDerivedClass, _ *int, _ *int, _ *int) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_DerivedClass_dofoo, _swig_p) + return +} + +func (_swig_base SwigcptrDerivedClass) Dofoo(arg1 *int, arg2 *int, arg3 *int) (_swig_ret int) { + return _swig_wrap_DerivedClass_dofoo(_swig_base, arg1, arg2, arg3) +} + +func (p SwigcptrDerivedClass) SwigIsBaseClass() { +} + +func (p SwigcptrDerivedClass) SwigGetBaseClass() BaseClass { + return SwigcptrBaseClass(p.Swigcptr()) +} + +type DerivedClass interface { + Swigcptr() uintptr + SwigIsDerivedClass() + DirectorInterface() interface{} + Dofoo(arg1 *int, arg2 *int, arg3 *int) (_swig_ret int) + SwigIsBaseClass() + SwigGetBaseClass() BaseClass +} + + +type SwigcptrSwigDirector_BaseClass uintptr +type SwigDirector_BaseClass interface { + Swigcptr() uintptr; +} +func (p SwigcptrSwigDirector_BaseClass) Swigcptr() uintptr { + return uintptr(p) +} + +type SwigcptrSwigDirector_Derived uintptr +type SwigDirector_Derived interface { + Swigcptr() uintptr; +} +func (p SwigcptrSwigDirector_Derived) Swigcptr() uintptr { + return uintptr(p) +} + +type SwigcptrSwigDirector_Base uintptr +type SwigDirector_Base interface { + Swigcptr() uintptr; +} +func (p SwigcptrSwigDirector_Base) Swigcptr() uintptr { + return uintptr(p) +} + +type SwigcptrSwigDirector_DerivedClass uintptr +type SwigDirector_DerivedClass interface { + Swigcptr() uintptr; +} +func (p SwigcptrSwigDirector_DerivedClass) Swigcptr() uintptr { + return uintptr(p) +} + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/director_classes_wrap.h b/Examples/test-suite/go/director_classes_wrap.h new file mode 100644 index 000000000..a18d87f70 --- /dev/null +++ b/Examples/test-suite/go/director_classes_wrap.h @@ -0,0 +1,132 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../director_classes.i + +#ifndef SWIG_director_classes_WRAP_H_ +#define SWIG_director_classes_WRAP_H_ + +class SwigDirector_Base : public Base +{ + public: + SwigDirector_Base(void *swig_p, double dd); + virtual ~SwigDirector_Base(); + DoubleHolder _swig_upcall_Val(DoubleHolder x) { + return Base::Val(x); + } + virtual DoubleHolder Val(DoubleHolder x); + DoubleHolder &_swig_upcall_Ref(DoubleHolder &x) { + return Base::Ref(x); + } + virtual DoubleHolder &Ref(DoubleHolder &x); + DoubleHolder *_swig_upcall_Ptr(DoubleHolder *x) { + return Base::Ptr(x); + } + virtual DoubleHolder *Ptr(DoubleHolder *x); + std::string _swig_upcall_FullyOverloaded__SWIG_0(int x) { + return Base::FullyOverloaded(x); + } + virtual std::string FullyOverloaded(int x); + std::string _swig_upcall_FullyOverloaded__SWIG_1(bool x) { + return Base::FullyOverloaded(x); + } + virtual std::string FullyOverloaded(bool x); + std::string _swig_upcall_SemiOverloaded__SWIG_0(int x) { + return Base::SemiOverloaded(x); + } + virtual std::string SemiOverloaded(int x); + std::string _swig_upcall_SemiOverloaded__SWIG_1(bool x) { + return Base::SemiOverloaded(x); + } + virtual std::string SemiOverloaded(bool x); + std::string _swig_upcall_DefaultParms__SWIG_0(int x, double y) { + return Base::DefaultParms(x,y); + } + virtual std::string DefaultParms(int x, double y); + std::string _swig_upcall_DefaultParms__SWIG_1(int x) { + return Base::DefaultParms(x); + } + virtual std::string DefaultParms(int x); + private: + void *go_val; +}; + +class SwigDirector_Derived : public Derived +{ + public: + SwigDirector_Derived(void *swig_p, double dd); + virtual ~SwigDirector_Derived(); + DoubleHolder _swig_upcall_Val(DoubleHolder x) { + return Derived::Val(x); + } + virtual DoubleHolder Val(DoubleHolder x); + DoubleHolder &_swig_upcall_Ref(DoubleHolder &x) { + return Derived::Ref(x); + } + virtual DoubleHolder &Ref(DoubleHolder &x); + DoubleHolder *_swig_upcall_Ptr(DoubleHolder *x) { + return Derived::Ptr(x); + } + virtual DoubleHolder *Ptr(DoubleHolder *x); + std::string _swig_upcall_FullyOverloaded__SWIG_0(int x) { + return Derived::FullyOverloaded(x); + } + virtual std::string FullyOverloaded(int x); + std::string _swig_upcall_FullyOverloaded__SWIG_1(bool x) { + return Derived::FullyOverloaded(x); + } + virtual std::string FullyOverloaded(bool x); + std::string _swig_upcall_SemiOverloaded(int x) { + return Derived::SemiOverloaded(x); + } + virtual std::string SemiOverloaded(int x); + std::string _swig_upcall_SemiOverloaded__SWIG_1(bool x) { + return Base::SemiOverloaded(x); + } + virtual std::string SemiOverloaded(bool x); + std::string _swig_upcall_DefaultParms__SWIG_0(int x, double y) { + return Derived::DefaultParms(x,y); + } + virtual std::string DefaultParms(int x, double y); + std::string _swig_upcall_DefaultParms__SWIG_1(int x) { + return Derived::DefaultParms(x); + } + virtual std::string DefaultParms(int x); + private: + void *go_val; +}; + +class SwigDirector_BaseClass : public BaseClass +{ + public: + SwigDirector_BaseClass(void *swig_p); + virtual ~SwigDirector_BaseClass(); + int _swig_upcall_dofoo(int &one, int &two, int &three) { + return BaseClass::dofoo(one,two,three); + } + virtual int dofoo(int &one, int &two, int &three); + private: + void *go_val; +}; + +class SwigDirector_DerivedClass : public DerivedClass +{ + public: + SwigDirector_DerivedClass(void *swig_p); + virtual ~SwigDirector_DerivedClass(); + int _swig_upcall_dofoo(int &one, int &two, int &three) { + return BaseClass::dofoo(one,two,three); + } + virtual int dofoo(int &one, int &two, int &three); + private: + void *go_val; +}; + +#endif diff --git a/Examples/test-suite/go/director_classic.go b/Examples/test-suite/go/director_classic.go new file mode 100644 index 000000000..5a3534a56 --- /dev/null +++ b/Examples/test-suite/go/director_classic.go @@ -0,0 +1,1102 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../director_classic.i + +package director_classic + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type _swig_DirectorBeing struct { + SwigcptrBeing + v interface{} +} + +func (p *_swig_DirectorBeing) Swigcptr() uintptr { + return p.SwigcptrBeing.Swigcptr() +} + +func (p *_swig_DirectorBeing) SwigIsBeing() { +} + +func (p *_swig_DirectorBeing) DirectorInterface() interface{} { + return p.v +} + +var _wrap__swig_NewDirectorBeingBeing unsafe.Pointer + +func _swig_NewDirectorBeingBeing(_swig_director *_swig_DirectorBeing) (_swig_ret SwigcptrBeing) { + _swig_p := uintptr(unsafe.Pointer(&_swig_director)) + _cgo_runtime_cgocall(_wrap__swig_NewDirectorBeingBeing, _swig_p) + return +} + +func NewDirectorBeing(v interface{}) Being { + p := &_swig_DirectorBeing{0, v} + p.SwigcptrBeing = _swig_NewDirectorBeingBeing(p) + return p +} + +type _swig_DirectorInterfaceBeingId interface { + Id() string +} + +var _wrap__swig_DirectorBeing_upcall_Id unsafe.Pointer + +func _swig_wrap__swig_DirectorBeing_upcall_Id(_swig_ptr SwigcptrBeing) (_swig_ret string) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) + _cgo_runtime_cgocall(_wrap__swig_DirectorBeing_upcall_Id, _swig_p) + return +} + +func (swig_p *_swig_DirectorBeing) Id() string { + if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceBeingId); swig_ok { + return swig_g.Id() + } + var swig_r string + swig_r = _swig_wrap__swig_DirectorBeing_upcall_Id(swig_p.SwigcptrBeing) + return swig_r +} + +func DirectorBeingId(p Being) string { + var swig_r string + swig_r = _swig_wrap__swig_DirectorBeing_upcall_Id(p.(*_swig_DirectorBeing).SwigcptrBeing) + return swig_r +} + +func Swig_DirectorBeing_callback_id(p *_swig_DirectorBeing) (swig_result string) { + var swig_r string + swig_r = p.Id() + return swig_r +} + +var _wrap_DeleteDirectorBeing unsafe.Pointer + +func _swig_wrap_DeleteDirectorBeing(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_DeleteDirectorBeing, _swig_p) + return +} + +func DeleteDirectorBeing(arg1 Being) { + _swig_wrap_DeleteDirectorBeing(arg1.Swigcptr()) +} + +func Swiggo_DeleteDirector_Being(p *_swig_DirectorBeing) { + p.SwigcptrBeing = 0 +} + +type SwigcptrBeing uintptr + +func (p SwigcptrBeing) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrBeing) SwigIsBeing() { +} + +func (p SwigcptrBeing) DirectorInterface() interface{} { + return nil +} + +var _wrap_Being_id unsafe.Pointer + +func _swig_wrap_Being_id(base SwigcptrBeing) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Being_id, _swig_p) + return +} + +func (arg1 SwigcptrBeing) Id() (_swig_ret string) { + return _swig_wrap_Being_id(arg1) +} + +var _wrap_delete_Being unsafe.Pointer + +func _swig_wrap_delete_Being(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Being, _swig_p) + return +} + +func DeleteBeing(arg1 Being) { + _swig_wrap_delete_Being(arg1.Swigcptr()) +} + +var _wrap_new_Being unsafe.Pointer + +func _swig_wrap_new_Being() (base SwigcptrBeing) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Being, _swig_p) + return +} + +func NewBeing() (_swig_ret Being) { + return _swig_wrap_new_Being() +} + +type Being interface { + Swigcptr() uintptr + SwigIsBeing() + DirectorInterface() interface{} + Id() (_swig_ret string) +} + +type _swig_DirectorPerson struct { + SwigcptrPerson + v interface{} +} + +func (p *_swig_DirectorPerson) Swigcptr() uintptr { + return p.SwigcptrPerson.Swigcptr() +} + +func (p *_swig_DirectorPerson) SwigIsPerson() { +} + +func (p *_swig_DirectorPerson) DirectorInterface() interface{} { + return p.v +} + +var _wrap__swig_NewDirectorPersonPerson unsafe.Pointer + +func _swig_NewDirectorPersonPerson(_swig_director *_swig_DirectorPerson) (_swig_ret SwigcptrPerson) { + _swig_p := uintptr(unsafe.Pointer(&_swig_director)) + _cgo_runtime_cgocall(_wrap__swig_NewDirectorPersonPerson, _swig_p) + return +} + +func NewDirectorPerson(v interface{}) Person { + p := &_swig_DirectorPerson{0, v} + p.SwigcptrPerson = _swig_NewDirectorPersonPerson(p) + return p +} + +type _swig_DirectorInterfacePersonId interface { + Id() string +} + +var _wrap__swig_DirectorPerson_upcall_Id unsafe.Pointer + +func _swig_wrap__swig_DirectorPerson_upcall_Id(_swig_ptr SwigcptrPerson) (_swig_ret string) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) + _cgo_runtime_cgocall(_wrap__swig_DirectorPerson_upcall_Id, _swig_p) + return +} + +func (swig_p *_swig_DirectorPerson) Id() string { + if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfacePersonId); swig_ok { + return swig_g.Id() + } + var swig_r string + swig_r = _swig_wrap__swig_DirectorPerson_upcall_Id(swig_p.SwigcptrPerson) + return swig_r +} + +func DirectorPersonId(p Person) string { + var swig_r string + swig_r = _swig_wrap__swig_DirectorPerson_upcall_Id(p.(*_swig_DirectorPerson).SwigcptrPerson) + return swig_r +} + +func Swig_DirectorPerson_callback_id(p *_swig_DirectorPerson) (swig_result string) { + var swig_r string + swig_r = p.Id() + return swig_r +} + +var _wrap_DeleteDirectorPerson unsafe.Pointer + +func _swig_wrap_DeleteDirectorPerson(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_DeleteDirectorPerson, _swig_p) + return +} + +func DeleteDirectorPerson(arg1 Person) { + _swig_wrap_DeleteDirectorPerson(arg1.Swigcptr()) +} + +func Swiggo_DeleteDirector_Person(p *_swig_DirectorPerson) { + p.SwigcptrPerson = 0 +} + +type SwigcptrPerson uintptr + +func (p SwigcptrPerson) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrPerson) SwigIsPerson() { +} + +func (p SwigcptrPerson) DirectorInterface() interface{} { + return nil +} + +var _wrap_Person_id unsafe.Pointer + +func _swig_wrap_Person_id(base SwigcptrPerson) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Person_id, _swig_p) + return +} + +func (arg1 SwigcptrPerson) Id() (_swig_ret string) { + return _swig_wrap_Person_id(arg1) +} + +var _wrap_new_Person unsafe.Pointer + +func _swig_wrap_new_Person() (base SwigcptrPerson) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Person, _swig_p) + return +} + +func NewPerson() (_swig_ret Person) { + return _swig_wrap_new_Person() +} + +var _wrap_delete_Person unsafe.Pointer + +func _swig_wrap_delete_Person(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Person, _swig_p) + return +} + +func DeletePerson(arg1 Person) { + _swig_wrap_delete_Person(arg1.Swigcptr()) +} + +func (p SwigcptrPerson) SwigIsBeing() { +} + +func (p SwigcptrPerson) SwigGetBeing() Being { + return SwigcptrBeing(p.Swigcptr()) +} + +type Person interface { + Swigcptr() uintptr + SwigIsPerson() + DirectorInterface() interface{} + Id() (_swig_ret string) + SwigIsBeing() + SwigGetBeing() Being +} + +type _swig_DirectorChild struct { + SwigcptrChild + v interface{} +} + +func (p *_swig_DirectorChild) Swigcptr() uintptr { + return p.SwigcptrChild.Swigcptr() +} + +func (p *_swig_DirectorChild) SwigIsChild() { +} + +func (p *_swig_DirectorChild) DirectorInterface() interface{} { + return p.v +} + +var _wrap__swig_NewDirectorChildChild unsafe.Pointer + +func _swig_NewDirectorChildChild(_swig_director *_swig_DirectorChild) (_swig_ret SwigcptrChild) { + _swig_p := uintptr(unsafe.Pointer(&_swig_director)) + _cgo_runtime_cgocall(_wrap__swig_NewDirectorChildChild, _swig_p) + return +} + +func NewDirectorChild(v interface{}) Child { + p := &_swig_DirectorChild{0, v} + p.SwigcptrChild = _swig_NewDirectorChildChild(p) + return p +} + +type _swig_DirectorInterfaceChildId interface { + Id() string +} + +var _wrap__swig_DirectorChild_upcall_Id unsafe.Pointer + +func _swig_wrap__swig_DirectorChild_upcall_Id(_swig_ptr SwigcptrChild) (_swig_ret string) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) + _cgo_runtime_cgocall(_wrap__swig_DirectorChild_upcall_Id, _swig_p) + return +} + +func (swig_p *_swig_DirectorChild) Id() string { + if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceChildId); swig_ok { + return swig_g.Id() + } + var swig_r string + swig_r = _swig_wrap__swig_DirectorChild_upcall_Id(swig_p.SwigcptrChild) + return swig_r +} + +func DirectorChildId(p Child) string { + var swig_r string + swig_r = _swig_wrap__swig_DirectorChild_upcall_Id(p.(*_swig_DirectorChild).SwigcptrChild) + return swig_r +} + +func Swig_DirectorChild_callback_id(p *_swig_DirectorChild) (swig_result string) { + var swig_r string + swig_r = p.Id() + return swig_r +} + +var _wrap_DeleteDirectorChild unsafe.Pointer + +func _swig_wrap_DeleteDirectorChild(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_DeleteDirectorChild, _swig_p) + return +} + +func DeleteDirectorChild(arg1 Child) { + _swig_wrap_DeleteDirectorChild(arg1.Swigcptr()) +} + +func Swiggo_DeleteDirector_Child(p *_swig_DirectorChild) { + p.SwigcptrChild = 0 +} + +type SwigcptrChild uintptr + +func (p SwigcptrChild) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrChild) SwigIsChild() { +} + +func (p SwigcptrChild) DirectorInterface() interface{} { + return nil +} + +var _wrap_Child_id unsafe.Pointer + +func _swig_wrap_Child_id(base SwigcptrChild) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Child_id, _swig_p) + return +} + +func (arg1 SwigcptrChild) Id() (_swig_ret string) { + return _swig_wrap_Child_id(arg1) +} + +var _wrap_new_Child unsafe.Pointer + +func _swig_wrap_new_Child() (base SwigcptrChild) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Child, _swig_p) + return +} + +func NewChild() (_swig_ret Child) { + return _swig_wrap_new_Child() +} + +var _wrap_delete_Child unsafe.Pointer + +func _swig_wrap_delete_Child(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Child, _swig_p) + return +} + +func DeleteChild(arg1 Child) { + _swig_wrap_delete_Child(arg1.Swigcptr()) +} + +func (p SwigcptrChild) SwigIsPerson() { +} + +func (p SwigcptrChild) SwigGetPerson() Person { + return SwigcptrPerson(p.Swigcptr()) +} + +func (p SwigcptrChild) SwigIsBeing() { +} + +func (p SwigcptrChild) SwigGetBeing() Being { + return SwigcptrBeing(p.Swigcptr()) +} + +type Child interface { + Swigcptr() uintptr + SwigIsChild() + DirectorInterface() interface{} + Id() (_swig_ret string) + SwigIsPerson() + SwigGetPerson() Person + SwigIsBeing() + SwigGetBeing() Being +} + +type _swig_DirectorGrandChild struct { + SwigcptrGrandChild + v interface{} +} + +func (p *_swig_DirectorGrandChild) Swigcptr() uintptr { + return p.SwigcptrGrandChild.Swigcptr() +} + +func (p *_swig_DirectorGrandChild) SwigIsGrandChild() { +} + +func (p *_swig_DirectorGrandChild) DirectorInterface() interface{} { + return p.v +} + +var _wrap__swig_NewDirectorGrandChildGrandChild unsafe.Pointer + +func _swig_NewDirectorGrandChildGrandChild(_swig_director *_swig_DirectorGrandChild) (_swig_ret SwigcptrGrandChild) { + _swig_p := uintptr(unsafe.Pointer(&_swig_director)) + _cgo_runtime_cgocall(_wrap__swig_NewDirectorGrandChildGrandChild, _swig_p) + return +} + +func NewDirectorGrandChild(v interface{}) GrandChild { + p := &_swig_DirectorGrandChild{0, v} + p.SwigcptrGrandChild = _swig_NewDirectorGrandChildGrandChild(p) + return p +} + +type _swig_DirectorInterfaceGrandChildId interface { + Id() string +} + +var _wrap__swig_DirectorGrandChild_upcall_Id unsafe.Pointer + +func _swig_wrap__swig_DirectorGrandChild_upcall_Id(_swig_ptr SwigcptrGrandChild) (_swig_ret string) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) + _cgo_runtime_cgocall(_wrap__swig_DirectorGrandChild_upcall_Id, _swig_p) + return +} + +func (swig_p *_swig_DirectorGrandChild) Id() string { + if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceGrandChildId); swig_ok { + return swig_g.Id() + } + var swig_r string + swig_r = _swig_wrap__swig_DirectorGrandChild_upcall_Id(swig_p.SwigcptrGrandChild) + return swig_r +} + +func DirectorGrandChildId(p GrandChild) string { + var swig_r string + swig_r = _swig_wrap__swig_DirectorGrandChild_upcall_Id(p.(*_swig_DirectorGrandChild).SwigcptrGrandChild) + return swig_r +} + +func Swig_DirectorGrandChild_callback_id(p *_swig_DirectorGrandChild) (swig_result string) { + var swig_r string + swig_r = p.Id() + return swig_r +} + +var _wrap_DeleteDirectorGrandChild unsafe.Pointer + +func _swig_wrap_DeleteDirectorGrandChild(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_DeleteDirectorGrandChild, _swig_p) + return +} + +func DeleteDirectorGrandChild(arg1 GrandChild) { + _swig_wrap_DeleteDirectorGrandChild(arg1.Swigcptr()) +} + +func Swiggo_DeleteDirector_GrandChild(p *_swig_DirectorGrandChild) { + p.SwigcptrGrandChild = 0 +} + +type SwigcptrGrandChild uintptr + +func (p SwigcptrGrandChild) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrGrandChild) SwigIsGrandChild() { +} + +func (p SwigcptrGrandChild) DirectorInterface() interface{} { + return nil +} + +var _wrap_GrandChild_id unsafe.Pointer + +func _swig_wrap_GrandChild_id(base SwigcptrGrandChild) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_GrandChild_id, _swig_p) + return +} + +func (arg1 SwigcptrGrandChild) Id() (_swig_ret string) { + return _swig_wrap_GrandChild_id(arg1) +} + +var _wrap_new_GrandChild unsafe.Pointer + +func _swig_wrap_new_GrandChild() (base SwigcptrGrandChild) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_GrandChild, _swig_p) + return +} + +func NewGrandChild() (_swig_ret GrandChild) { + return _swig_wrap_new_GrandChild() +} + +var _wrap_delete_GrandChild unsafe.Pointer + +func _swig_wrap_delete_GrandChild(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_GrandChild, _swig_p) + return +} + +func DeleteGrandChild(arg1 GrandChild) { + _swig_wrap_delete_GrandChild(arg1.Swigcptr()) +} + +func (p SwigcptrGrandChild) SwigIsChild() { +} + +func (p SwigcptrGrandChild) SwigGetChild() Child { + return SwigcptrChild(p.Swigcptr()) +} + +func (p SwigcptrGrandChild) SwigIsPerson() { +} + +func (p SwigcptrGrandChild) SwigGetPerson() Person { + return SwigcptrPerson(p.Swigcptr()) +} + +func (p SwigcptrGrandChild) SwigIsBeing() { +} + +func (p SwigcptrGrandChild) SwigGetBeing() Being { + return SwigcptrBeing(p.Swigcptr()) +} + +type GrandChild interface { + Swigcptr() uintptr + SwigIsGrandChild() + DirectorInterface() interface{} + Id() (_swig_ret string) + SwigIsChild() + SwigGetChild() Child + SwigIsPerson() + SwigGetPerson() Person + SwigIsBeing() + SwigGetBeing() Being +} + +type _swig_DirectorOrphanPerson struct { + SwigcptrOrphanPerson + v interface{} +} + +func (p *_swig_DirectorOrphanPerson) Swigcptr() uintptr { + return p.SwigcptrOrphanPerson.Swigcptr() +} + +func (p *_swig_DirectorOrphanPerson) SwigIsOrphanPerson() { +} + +func (p *_swig_DirectorOrphanPerson) DirectorInterface() interface{} { + return p.v +} + +var _wrap__swig_NewDirectorOrphanPersonOrphanPerson unsafe.Pointer + +func _swig_NewDirectorOrphanPersonOrphanPerson(_swig_director *_swig_DirectorOrphanPerson) (_swig_ret SwigcptrOrphanPerson) { + _swig_p := uintptr(unsafe.Pointer(&_swig_director)) + _cgo_runtime_cgocall(_wrap__swig_NewDirectorOrphanPersonOrphanPerson, _swig_p) + return +} + +func NewDirectorOrphanPerson(v interface{}) OrphanPerson { + p := &_swig_DirectorOrphanPerson{0, v} + p.SwigcptrOrphanPerson = _swig_NewDirectorOrphanPersonOrphanPerson(p) + return p +} + +type _swig_DirectorInterfaceOrphanPersonId interface { + Id() string +} + +var _wrap__swig_DirectorOrphanPerson_upcall_Id unsafe.Pointer + +func _swig_wrap__swig_DirectorOrphanPerson_upcall_Id(_swig_ptr SwigcptrOrphanPerson) (_swig_ret string) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) + _cgo_runtime_cgocall(_wrap__swig_DirectorOrphanPerson_upcall_Id, _swig_p) + return +} + +func (swig_p *_swig_DirectorOrphanPerson) Id() string { + if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceOrphanPersonId); swig_ok { + return swig_g.Id() + } + var swig_r string + swig_r = _swig_wrap__swig_DirectorOrphanPerson_upcall_Id(swig_p.SwigcptrOrphanPerson) + return swig_r +} + +func DirectorOrphanPersonId(p OrphanPerson) string { + var swig_r string + swig_r = _swig_wrap__swig_DirectorOrphanPerson_upcall_Id(p.(*_swig_DirectorOrphanPerson).SwigcptrOrphanPerson) + return swig_r +} + +func Swig_DirectorOrphanPerson_callback_id(p *_swig_DirectorOrphanPerson) (swig_result string) { + var swig_r string + swig_r = p.Id() + return swig_r +} + +var _wrap_DeleteDirectorOrphanPerson unsafe.Pointer + +func _swig_wrap_DeleteDirectorOrphanPerson(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_DeleteDirectorOrphanPerson, _swig_p) + return +} + +func DeleteDirectorOrphanPerson(arg1 OrphanPerson) { + _swig_wrap_DeleteDirectorOrphanPerson(arg1.Swigcptr()) +} + +func Swiggo_DeleteDirector_OrphanPerson(p *_swig_DirectorOrphanPerson) { + p.SwigcptrOrphanPerson = 0 +} + +type SwigcptrOrphanPerson uintptr + +func (p SwigcptrOrphanPerson) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrOrphanPerson) SwigIsOrphanPerson() { +} + +func (p SwigcptrOrphanPerson) DirectorInterface() interface{} { + return nil +} + +var _wrap_new_OrphanPerson unsafe.Pointer + +func _swig_wrap_new_OrphanPerson() (base SwigcptrOrphanPerson) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_OrphanPerson, _swig_p) + return +} + +func NewOrphanPerson() (_swig_ret OrphanPerson) { + return _swig_wrap_new_OrphanPerson() +} + +var _wrap_delete_OrphanPerson unsafe.Pointer + +func _swig_wrap_delete_OrphanPerson(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_OrphanPerson, _swig_p) + return +} + +func DeleteOrphanPerson(arg1 OrphanPerson) { + _swig_wrap_delete_OrphanPerson(arg1.Swigcptr()) +} + +var _wrap_OrphanPerson_id unsafe.Pointer + +func _swig_wrap_OrphanPerson_id(base SwigcptrOrphanPerson) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_OrphanPerson_id, _swig_p) + return +} + +func (_swig_base SwigcptrOrphanPerson) Id() (_swig_ret string) { + return _swig_wrap_OrphanPerson_id(_swig_base) +} + +func (p SwigcptrOrphanPerson) SwigIsPerson() { +} + +func (p SwigcptrOrphanPerson) SwigGetPerson() Person { + return SwigcptrPerson(p.Swigcptr()) +} + +func (p SwigcptrOrphanPerson) SwigIsBeing() { +} + +func (p SwigcptrOrphanPerson) SwigGetBeing() Being { + return SwigcptrBeing(p.Swigcptr()) +} + +type OrphanPerson interface { + Swigcptr() uintptr + SwigIsOrphanPerson() + DirectorInterface() interface{} + Id() (_swig_ret string) + SwigIsPerson() + SwigGetPerson() Person + SwigIsBeing() + SwigGetBeing() Being +} + +type _swig_DirectorOrphanChild struct { + SwigcptrOrphanChild + v interface{} +} + +func (p *_swig_DirectorOrphanChild) Swigcptr() uintptr { + return p.SwigcptrOrphanChild.Swigcptr() +} + +func (p *_swig_DirectorOrphanChild) SwigIsOrphanChild() { +} + +func (p *_swig_DirectorOrphanChild) DirectorInterface() interface{} { + return p.v +} + +var _wrap__swig_NewDirectorOrphanChildOrphanChild unsafe.Pointer + +func _swig_NewDirectorOrphanChildOrphanChild(_swig_director *_swig_DirectorOrphanChild) (_swig_ret SwigcptrOrphanChild) { + _swig_p := uintptr(unsafe.Pointer(&_swig_director)) + _cgo_runtime_cgocall(_wrap__swig_NewDirectorOrphanChildOrphanChild, _swig_p) + return +} + +func NewDirectorOrphanChild(v interface{}) OrphanChild { + p := &_swig_DirectorOrphanChild{0, v} + p.SwigcptrOrphanChild = _swig_NewDirectorOrphanChildOrphanChild(p) + return p +} + +type _swig_DirectorInterfaceOrphanChildId interface { + Id() string +} + +var _wrap__swig_DirectorOrphanChild_upcall_Id unsafe.Pointer + +func _swig_wrap__swig_DirectorOrphanChild_upcall_Id(_swig_ptr SwigcptrOrphanChild) (_swig_ret string) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) + _cgo_runtime_cgocall(_wrap__swig_DirectorOrphanChild_upcall_Id, _swig_p) + return +} + +func (swig_p *_swig_DirectorOrphanChild) Id() string { + if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceOrphanChildId); swig_ok { + return swig_g.Id() + } + var swig_r string + swig_r = _swig_wrap__swig_DirectorOrphanChild_upcall_Id(swig_p.SwigcptrOrphanChild) + return swig_r +} + +func DirectorOrphanChildId(p OrphanChild) string { + var swig_r string + swig_r = _swig_wrap__swig_DirectorOrphanChild_upcall_Id(p.(*_swig_DirectorOrphanChild).SwigcptrOrphanChild) + return swig_r +} + +func Swig_DirectorOrphanChild_callback_id(p *_swig_DirectorOrphanChild) (swig_result string) { + var swig_r string + swig_r = p.Id() + return swig_r +} + +var _wrap_DeleteDirectorOrphanChild unsafe.Pointer + +func _swig_wrap_DeleteDirectorOrphanChild(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_DeleteDirectorOrphanChild, _swig_p) + return +} + +func DeleteDirectorOrphanChild(arg1 OrphanChild) { + _swig_wrap_DeleteDirectorOrphanChild(arg1.Swigcptr()) +} + +func Swiggo_DeleteDirector_OrphanChild(p *_swig_DirectorOrphanChild) { + p.SwigcptrOrphanChild = 0 +} + +type SwigcptrOrphanChild uintptr + +func (p SwigcptrOrphanChild) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrOrphanChild) SwigIsOrphanChild() { +} + +func (p SwigcptrOrphanChild) DirectorInterface() interface{} { + return nil +} + +var _wrap_new_OrphanChild unsafe.Pointer + +func _swig_wrap_new_OrphanChild() (base SwigcptrOrphanChild) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_OrphanChild, _swig_p) + return +} + +func NewOrphanChild() (_swig_ret OrphanChild) { + return _swig_wrap_new_OrphanChild() +} + +var _wrap_delete_OrphanChild unsafe.Pointer + +func _swig_wrap_delete_OrphanChild(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_OrphanChild, _swig_p) + return +} + +func DeleteOrphanChild(arg1 OrphanChild) { + _swig_wrap_delete_OrphanChild(arg1.Swigcptr()) +} + +var _wrap_OrphanChild_id unsafe.Pointer + +func _swig_wrap_OrphanChild_id(base SwigcptrOrphanChild) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_OrphanChild_id, _swig_p) + return +} + +func (_swig_base SwigcptrOrphanChild) Id() (_swig_ret string) { + return _swig_wrap_OrphanChild_id(_swig_base) +} + +func (p SwigcptrOrphanChild) SwigIsChild() { +} + +func (p SwigcptrOrphanChild) SwigGetChild() Child { + return SwigcptrChild(p.Swigcptr()) +} + +func (p SwigcptrOrphanChild) SwigIsPerson() { +} + +func (p SwigcptrOrphanChild) SwigGetPerson() Person { + return SwigcptrPerson(p.Swigcptr()) +} + +func (p SwigcptrOrphanChild) SwigIsBeing() { +} + +func (p SwigcptrOrphanChild) SwigGetBeing() Being { + return SwigcptrBeing(p.Swigcptr()) +} + +type OrphanChild interface { + Swigcptr() uintptr + SwigIsOrphanChild() + DirectorInterface() interface{} + Id() (_swig_ret string) + SwigIsChild() + SwigGetChild() Child + SwigIsPerson() + SwigGetPerson() Person + SwigIsBeing() + SwigGetBeing() Being +} + +type SwigcptrCaller uintptr + +func (p SwigcptrCaller) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrCaller) SwigIsCaller() { +} + +func (p SwigcptrCaller) DirectorInterface() interface{} { + return nil +} + +var _wrap_new_Caller unsafe.Pointer + +func _swig_wrap_new_Caller() (base SwigcptrCaller) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Caller, _swig_p) + return +} + +func NewCaller() (_swig_ret Caller) { + return _swig_wrap_new_Caller() +} + +var _wrap_delete_Caller unsafe.Pointer + +func _swig_wrap_delete_Caller(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Caller, _swig_p) + return +} + +func DeleteCaller(arg1 Caller) { + _swig_wrap_delete_Caller(arg1.Swigcptr()) +} + +var _wrap_Caller_delCallback unsafe.Pointer + +func _swig_wrap_Caller_delCallback(base SwigcptrCaller) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Caller_delCallback, _swig_p) + return +} + +func (arg1 SwigcptrCaller) DelCallback() { + _swig_wrap_Caller_delCallback(arg1) +} + +var _wrap_Caller_setCallback unsafe.Pointer + +func _swig_wrap_Caller_setCallback(base SwigcptrCaller, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Caller_setCallback, _swig_p) + return +} + +func (arg1 SwigcptrCaller) SetCallback(arg2 Person) { + _swig_wrap_Caller_setCallback(arg1, arg2.Swigcptr()) +} + +var _wrap_Caller_resetCallback unsafe.Pointer + +func _swig_wrap_Caller_resetCallback(base SwigcptrCaller) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Caller_resetCallback, _swig_p) + return +} + +func (arg1 SwigcptrCaller) ResetCallback() { + _swig_wrap_Caller_resetCallback(arg1) +} + +var _wrap_Caller_call unsafe.Pointer + +func _swig_wrap_Caller_call(base SwigcptrCaller) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Caller_call, _swig_p) + return +} + +func (arg1 SwigcptrCaller) Call() (_swig_ret string) { + return _swig_wrap_Caller_call(arg1) +} + +var _wrap_Caller_baseClass unsafe.Pointer + +func _swig_wrap_Caller_baseClass(base SwigcptrCaller) (_ SwigcptrPerson) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Caller_baseClass, _swig_p) + return +} + +func (arg1 SwigcptrCaller) BaseClass() (_swig_ret Person) { + return _swig_wrap_Caller_baseClass(arg1) +} + +type Caller interface { + Swigcptr() uintptr + SwigIsCaller() + DirectorInterface() interface{} + DelCallback() + SetCallback(arg2 Person) + ResetCallback() + Call() (_swig_ret string) + BaseClass() (_swig_ret Person) +} + + +type SwigcptrSwigDirector_Being uintptr +type SwigDirector_Being interface { + Swigcptr() uintptr; +} +func (p SwigcptrSwigDirector_Being) Swigcptr() uintptr { + return uintptr(p) +} + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + +type SwigcptrSwigDirector_GrandChild uintptr +type SwigDirector_GrandChild interface { + Swigcptr() uintptr; +} +func (p SwigcptrSwigDirector_GrandChild) Swigcptr() uintptr { + return uintptr(p) +} + +type SwigcptrSwigDirector_Person uintptr +type SwigDirector_Person interface { + Swigcptr() uintptr; +} +func (p SwigcptrSwigDirector_Person) Swigcptr() uintptr { + return uintptr(p) +} + +type SwigcptrSwigDirector_OrphanChild uintptr +type SwigDirector_OrphanChild interface { + Swigcptr() uintptr; +} +func (p SwigcptrSwigDirector_OrphanChild) Swigcptr() uintptr { + return uintptr(p) +} + +type SwigcptrSwigDirector_Child uintptr +type SwigDirector_Child interface { + Swigcptr() uintptr; +} +func (p SwigcptrSwigDirector_Child) Swigcptr() uintptr { + return uintptr(p) +} + +type SwigcptrSwigDirector_OrphanPerson uintptr +type SwigDirector_OrphanPerson interface { + Swigcptr() uintptr; +} +func (p SwigcptrSwigDirector_OrphanPerson) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/director_classic_runme b/Examples/test-suite/go/director_classic_runme new file mode 100755 index 000000000..1f6f65c94 Binary files /dev/null and b/Examples/test-suite/go/director_classic_runme differ diff --git a/Examples/test-suite/go/director_classic_wrap.h b/Examples/test-suite/go/director_classic_wrap.h new file mode 100644 index 000000000..b316c893f --- /dev/null +++ b/Examples/test-suite/go/director_classic_wrap.h @@ -0,0 +1,94 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../director_classic.i + +#ifndef SWIG_director_classic_WRAP_H_ +#define SWIG_director_classic_WRAP_H_ + +class SwigDirector_Being : public Being +{ + public: + SwigDirector_Being(void *swig_p); + std::string _swig_upcall_id() { + return Being::id(); + } + virtual std::string id(); + virtual ~SwigDirector_Being(); + private: + void *go_val; +}; + +class SwigDirector_Person : public Person +{ + public: + SwigDirector_Person(void *swig_p); + std::string _swig_upcall_id() { + return Person::id(); + } + virtual std::string id(); + virtual ~SwigDirector_Person(); + private: + void *go_val; +}; + +class SwigDirector_Child : public Child +{ + public: + SwigDirector_Child(void *swig_p); + std::string _swig_upcall_id() { + return Child::id(); + } + virtual std::string id(); + virtual ~SwigDirector_Child(); + private: + void *go_val; +}; + +class SwigDirector_GrandChild : public GrandChild +{ + public: + SwigDirector_GrandChild(void *swig_p); + std::string _swig_upcall_id() { + return GrandChild::id(); + } + virtual std::string id(); + virtual ~SwigDirector_GrandChild(); + private: + void *go_val; +}; + +class SwigDirector_OrphanPerson : public OrphanPerson +{ + public: + SwigDirector_OrphanPerson(void *swig_p); + std::string _swig_upcall_id() { + return Person::id(); + } + virtual std::string id(); + virtual ~SwigDirector_OrphanPerson(); + private: + void *go_val; +}; + +class SwigDirector_OrphanChild : public OrphanChild +{ + public: + SwigDirector_OrphanChild(void *swig_p); + std::string _swig_upcall_id() { + return Child::id(); + } + virtual std::string id(); + virtual ~SwigDirector_OrphanChild(); + private: + void *go_val; +}; + +#endif diff --git a/Examples/test-suite/go/director_constructor.go b/Examples/test-suite/go/director_constructor.go new file mode 100644 index 000000000..2c6edcb45 --- /dev/null +++ b/Examples/test-suite/go/director_constructor.go @@ -0,0 +1,290 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../director_constructor.i + +package director_constructor + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type _swig_DirectorFoo struct { + SwigcptrFoo + v interface{} +} + +func (p *_swig_DirectorFoo) Swigcptr() uintptr { + return p.SwigcptrFoo.Swigcptr() +} + +func (p *_swig_DirectorFoo) SwigIsFoo() { +} + +func (p *_swig_DirectorFoo) DirectorInterface() interface{} { + return p.v +} + +var _wrap__swig_NewDirectorFooFoo unsafe.Pointer + +func _swig_NewDirectorFooFoo(_swig_director *_swig_DirectorFoo, _ int) (_swig_ret SwigcptrFoo) { + _swig_p := uintptr(unsafe.Pointer(&_swig_director)) + _cgo_runtime_cgocall(_wrap__swig_NewDirectorFooFoo, _swig_p) + return +} + +func NewDirectorFoo(v interface{}, arg1 int) Foo { + p := &_swig_DirectorFoo{0, v} + p.SwigcptrFoo = _swig_NewDirectorFooFoo(p, arg1) + return p +} + +var _wrap_DeleteDirectorFoo unsafe.Pointer + +func _swig_wrap_DeleteDirectorFoo(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_DeleteDirectorFoo, _swig_p) + return +} + +func DeleteDirectorFoo(arg1 Foo) { + _swig_wrap_DeleteDirectorFoo(arg1.Swigcptr()) +} + +func Swiggo_DeleteDirector_Foo(p *_swig_DirectorFoo) { + p.SwigcptrFoo = 0 +} + +type _swig_DirectorInterfaceFooGetit interface { + Getit() int +} + +var _wrap__swig_DirectorFoo_upcall_Getit unsafe.Pointer + +func _swig_wrap__swig_DirectorFoo_upcall_Getit(_swig_ptr SwigcptrFoo) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) + _cgo_runtime_cgocall(_wrap__swig_DirectorFoo_upcall_Getit, _swig_p) + return +} + +func (swig_p *_swig_DirectorFoo) Getit() int { + if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceFooGetit); swig_ok { + return swig_g.Getit() + } + var swig_r int + swig_r = _swig_wrap__swig_DirectorFoo_upcall_Getit(swig_p.SwigcptrFoo) + return swig_r +} + +func DirectorFooGetit(p Foo) int { + var swig_r int + swig_r = _swig_wrap__swig_DirectorFoo_upcall_Getit(p.(*_swig_DirectorFoo).SwigcptrFoo) + return swig_r +} + +func Swig_DirectorFoo_callback_getit(p *_swig_DirectorFoo) (swig_result int) { + var swig_r int + swig_r = p.Getit() + return swig_r +} + +type _swig_DirectorInterfaceFooDoubleit interface { + Doubleit() +} + +var _wrap__swig_DirectorFoo_upcall_Doubleit unsafe.Pointer + +func _swig_wrap__swig_DirectorFoo_upcall_Doubleit(_swig_ptr SwigcptrFoo) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) + _cgo_runtime_cgocall(_wrap__swig_DirectorFoo_upcall_Doubleit, _swig_p) + return +} + +func (swig_p *_swig_DirectorFoo) Doubleit() { + if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceFooDoubleit); swig_ok { + swig_g.Doubleit() + return + } + _swig_wrap__swig_DirectorFoo_upcall_Doubleit(swig_p.SwigcptrFoo) +} + +func DirectorFooDoubleit(p Foo) { + _swig_wrap__swig_DirectorFoo_upcall_Doubleit(p.(*_swig_DirectorFoo).SwigcptrFoo) +} + +func Swig_DirectorFoo_callback_doubleit(p *_swig_DirectorFoo) { + p.Doubleit() +} + +type _swig_DirectorInterfaceFooTest interface { + Test() int +} + +func (swig_p *_swig_DirectorFoo) Test() int { + if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceFooTest); swig_ok { + return swig_g.Test() + } + panic("call to pure virtual method") +} + +func Swig_DirectorFoo_callback_test(p *_swig_DirectorFoo) (swig_result int) { + var swig_r int + swig_r = p.Test() + return swig_r +} + +type SwigcptrFoo uintptr + +func (p SwigcptrFoo) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrFoo) SwigIsFoo() { +} + +func (p SwigcptrFoo) DirectorInterface() interface{} { + return nil +} + +var _wrap_Foo_a_set unsafe.Pointer + +func _swig_wrap_Foo_a_set(base SwigcptrFoo, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_a_set, _swig_p) + return +} + +func (arg1 SwigcptrFoo) SetA(arg2 int) { + _swig_wrap_Foo_a_set(arg1, arg2) +} + +var _wrap_Foo_a_get unsafe.Pointer + +func _swig_wrap_Foo_a_get(base SwigcptrFoo) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_a_get, _swig_p) + return +} + +func (arg1 SwigcptrFoo) GetA() (_swig_ret int) { + return _swig_wrap_Foo_a_get(arg1) +} + +var _wrap_new_Foo unsafe.Pointer + +func _swig_wrap_new_Foo(base int) (_ SwigcptrFoo) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Foo, _swig_p) + return +} + +func NewFoo(arg1 int) (_swig_ret Foo) { + return _swig_wrap_new_Foo(arg1) +} + +var _wrap_delete_Foo unsafe.Pointer + +func _swig_wrap_delete_Foo(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Foo, _swig_p) + return +} + +func DeleteFoo(arg1 Foo) { + _swig_wrap_delete_Foo(arg1.Swigcptr()) +} + +var _wrap_Foo_do_test unsafe.Pointer + +func _swig_wrap_Foo_do_test(base SwigcptrFoo) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_do_test, _swig_p) + return +} + +func (arg1 SwigcptrFoo) Do_test() (_swig_ret int) { + return _swig_wrap_Foo_do_test(arg1) +} + +var _wrap_Foo_getit unsafe.Pointer + +func _swig_wrap_Foo_getit(base SwigcptrFoo) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_getit, _swig_p) + return +} + +func (arg1 SwigcptrFoo) Getit() (_swig_ret int) { + return _swig_wrap_Foo_getit(arg1) +} + +var _wrap_Foo_doubleit unsafe.Pointer + +func _swig_wrap_Foo_doubleit(base SwigcptrFoo) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_doubleit, _swig_p) + return +} + +func (arg1 SwigcptrFoo) Doubleit() { + _swig_wrap_Foo_doubleit(arg1) +} + +var _wrap_Foo_test unsafe.Pointer + +func _swig_wrap_Foo_test(base SwigcptrFoo) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_test, _swig_p) + return +} + +func (arg1 SwigcptrFoo) Test() (_swig_ret int) { + return _swig_wrap_Foo_test(arg1) +} + +type Foo interface { + Swigcptr() uintptr + SwigIsFoo() + DirectorInterface() interface{} + SetA(arg2 int) + GetA() (_swig_ret int) + Do_test() (_swig_ret int) + Getit() (_swig_ret int) + Doubleit() + Test() (_swig_ret int) +} + + +type SwigcptrSwigDirector_Foo uintptr +type SwigDirector_Foo interface { + Swigcptr() uintptr; +} +func (p SwigcptrSwigDirector_Foo) Swigcptr() uintptr { + return uintptr(p) +} + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/director_constructor_wrap.h b/Examples/test-suite/go/director_constructor_wrap.h new file mode 100644 index 000000000..814f687f0 --- /dev/null +++ b/Examples/test-suite/go/director_constructor_wrap.h @@ -0,0 +1,34 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../director_constructor.i + +#ifndef SWIG_director_constructor_WRAP_H_ +#define SWIG_director_constructor_WRAP_H_ + +class SwigDirector_Foo : public Foo +{ + public: + SwigDirector_Foo(void *swig_p, int i); + virtual ~SwigDirector_Foo(); + int _swig_upcall_getit() { + return Foo::getit(); + } + virtual int getit(); + void _swig_upcall_doubleit() { + Foo::doubleit(); + } + virtual void doubleit(); + virtual int test(); + private: + void *go_val; +}; + +#endif diff --git a/Examples/test-suite/go/director_default.go b/Examples/test-suite/go/director_default.go new file mode 100644 index 000000000..c87fdd35d --- /dev/null +++ b/Examples/test-suite/go/director_default.go @@ -0,0 +1,875 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../director_default.i + +package director_default + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type _swig_DirectorFoo struct { + SwigcptrFoo + v interface{} +} + +func (p *_swig_DirectorFoo) Swigcptr() uintptr { + return p.SwigcptrFoo.Swigcptr() +} + +func (p *_swig_DirectorFoo) SwigIsFoo() { +} + +func (p *_swig_DirectorFoo) DirectorInterface() interface{} { + return p.v +} + +var _wrap__swig_NewDirectorFooFoo__SWIG_0 unsafe.Pointer + +func _swig_NewDirectorFooFoo__SWIG_0(_swig_director *_swig_DirectorFoo, _ int) (_swig_ret SwigcptrFoo) { + _swig_p := uintptr(unsafe.Pointer(&_swig_director)) + _cgo_runtime_cgocall(_wrap__swig_NewDirectorFooFoo__SWIG_0, _swig_p) + return +} + +func NewDirectorFoo__SWIG_0(v interface{}, arg1 int) Foo { + p := &_swig_DirectorFoo{0, v} + p.SwigcptrFoo = _swig_NewDirectorFooFoo__SWIG_0(p, arg1) + return p +} + +var _wrap__swig_NewDirectorFooFoo__SWIG_1 unsafe.Pointer + +func _swig_NewDirectorFooFoo__SWIG_1(_swig_director *_swig_DirectorFoo) (_swig_ret SwigcptrFoo) { + _swig_p := uintptr(unsafe.Pointer(&_swig_director)) + _cgo_runtime_cgocall(_wrap__swig_NewDirectorFooFoo__SWIG_1, _swig_p) + return +} + +func NewDirectorFoo__SWIG_1(v interface{}) Foo { + p := &_swig_DirectorFoo{0, v} + p.SwigcptrFoo = _swig_NewDirectorFooFoo__SWIG_1(p) + return p +} + +func NewDirectorFoo(abi interface{}, a ...interface{}) Foo { + argc := len(a) + if argc == 0 { + return NewDirectorFoo__SWIG_1(abi) + } + if argc == 1 { + return NewDirectorFoo__SWIG_0(abi, a[0].(int)) + } + panic("No match for overloaded function call") +} + +var _wrap_DeleteDirectorFoo unsafe.Pointer + +func _swig_wrap_DeleteDirectorFoo(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_DeleteDirectorFoo, _swig_p) + return +} + +func DeleteDirectorFoo(arg1 Foo) { + _swig_wrap_DeleteDirectorFoo(arg1.Swigcptr()) +} + +func Swiggo_DeleteDirector_Foo(p *_swig_DirectorFoo) { + p.SwigcptrFoo = 0 +} + +type _swig_DirectorInterfaceFooMsg__SWIG_0 interface { + Msg__SWIG_0(string) string +} + +var _wrap__swig_DirectorFoo_upcall_Msg__SWIG_0 unsafe.Pointer + +func _swig_wrap__swig_DirectorFoo_upcall_Msg__SWIG_0(_swig_ptr SwigcptrFoo, _ string) (_swig_ret string) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) + _cgo_runtime_cgocall(_wrap__swig_DirectorFoo_upcall_Msg__SWIG_0, _swig_p) + return +} + +func (swig_p *_swig_DirectorFoo) Msg__SWIG_0(msg string) string { + if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceFooMsg__SWIG_0); swig_ok { + return swig_g.Msg__SWIG_0(msg) + } + var swig_r string + swig_r = _swig_wrap__swig_DirectorFoo_upcall_Msg__SWIG_0(swig_p.SwigcptrFoo, msg) + return swig_r +} + +func DirectorFooMsg__SWIG_0(p Foo, arg2 string) string { + var swig_r string + swig_r = _swig_wrap__swig_DirectorFoo_upcall_Msg__SWIG_0(p.(*_swig_DirectorFoo).SwigcptrFoo, arg2) + return swig_r +} + +func Swig_DirectorFoo_callback_Msg__SWIG_0(p *_swig_DirectorFoo, arg2 string) (swig_result string) { + var swig_r string + swig_r = p.Msg__SWIG_0(arg2) + return swig_r +} + +type _swig_DirectorInterfaceFooMsg__SWIG_1 interface { + Msg__SWIG_1() string +} + +var _wrap__swig_DirectorFoo_upcall_Msg__SWIG_1 unsafe.Pointer + +func _swig_wrap__swig_DirectorFoo_upcall_Msg__SWIG_1(_swig_ptr SwigcptrFoo) (_swig_ret string) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) + _cgo_runtime_cgocall(_wrap__swig_DirectorFoo_upcall_Msg__SWIG_1, _swig_p) + return +} + +func (swig_p *_swig_DirectorFoo) Msg__SWIG_1() string { + if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceFooMsg__SWIG_1); swig_ok { + return swig_g.Msg__SWIG_1() + } + var swig_r string + swig_r = _swig_wrap__swig_DirectorFoo_upcall_Msg__SWIG_1(swig_p.SwigcptrFoo) + return swig_r +} + +func DirectorFooMsg__SWIG_1(p Foo) string { + var swig_r string + swig_r = _swig_wrap__swig_DirectorFoo_upcall_Msg__SWIG_1(p.(*_swig_DirectorFoo).SwigcptrFoo) + return swig_r +} + +func Swig_DirectorFoo_callback_Msg__SWIG_1(p *_swig_DirectorFoo) (swig_result string) { + var swig_r string + swig_r = p.Msg__SWIG_1() + return swig_r +} + +func (p _swig_DirectorFoo) Msg(a ...interface{}) string { + argc := len(a) + if argc == 0 { + return p.Msg__SWIG_1() + } + if argc == 1 { + return p.Msg__SWIG_0(a[0].(string)) + } + panic("No match for overloaded function call") +} + +func DirectorFooMsg(p *_swig_DirectorFoo, a ...interface{}) string { + argc := len(a) + if argc == 0 { + return DirectorFooMsg__SWIG_1(p) + } + if argc == 1 { + return DirectorFooMsg__SWIG_0(p, a[0].(string)) + } + panic("No match for overloaded function call") +} + +type SwigcptrFoo uintptr + +func (p SwigcptrFoo) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrFoo) SwigIsFoo() { +} + +func (p SwigcptrFoo) DirectorInterface() interface{} { + return nil +} + +var _wrap_new_Foo__SWIG_0 unsafe.Pointer + +func _swig_wrap_new_Foo__SWIG_0(base int) (_ SwigcptrFoo) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Foo__SWIG_0, _swig_p) + return +} + +func NewFoo__SWIG_0(arg1 int) (_swig_ret Foo) { + return _swig_wrap_new_Foo__SWIG_0(arg1) +} + +var _wrap_new_Foo__SWIG_1 unsafe.Pointer + +func _swig_wrap_new_Foo__SWIG_1() (base SwigcptrFoo) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Foo__SWIG_1, _swig_p) + return +} + +func NewFoo__SWIG_1() (_swig_ret Foo) { + return _swig_wrap_new_Foo__SWIG_1() +} + +func NewFoo(a ...interface{}) Foo { + argc := len(a) + if argc == 0 { + return NewFoo__SWIG_1() + } + if argc == 1 { + return NewFoo__SWIG_0(a[0].(int)) + } + panic("No match for overloaded function call") +} + +var _wrap_delete_Foo unsafe.Pointer + +func _swig_wrap_delete_Foo(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Foo, _swig_p) + return +} + +func DeleteFoo(arg1 Foo) { + _swig_wrap_delete_Foo(arg1.Swigcptr()) +} + +var _wrap_Foo_Msg__SWIG_0 unsafe.Pointer + +func _swig_wrap_Foo_Msg__SWIG_0(base SwigcptrFoo, _ string) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_Msg__SWIG_0, _swig_p) + return +} + +func (arg1 SwigcptrFoo) Msg__SWIG_0(arg2 string) (_swig_ret string) { + return _swig_wrap_Foo_Msg__SWIG_0(arg1, arg2) +} + +var _wrap_Foo_Msg__SWIG_1 unsafe.Pointer + +func _swig_wrap_Foo_Msg__SWIG_1(base SwigcptrFoo) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_Msg__SWIG_1, _swig_p) + return +} + +func (arg1 SwigcptrFoo) Msg__SWIG_1() (_swig_ret string) { + return _swig_wrap_Foo_Msg__SWIG_1(arg1) +} + +func (p SwigcptrFoo) Msg(a ...interface{}) string { + argc := len(a) + if argc == 0 { + return p.Msg__SWIG_1() + } + if argc == 1 { + return p.Msg__SWIG_0(a[0].(string)) + } + panic("No match for overloaded function call") +} + +var _wrap_Foo_GetMsg__SWIG_0 unsafe.Pointer + +func _swig_wrap_Foo_GetMsg__SWIG_0(base SwigcptrFoo) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_GetMsg__SWIG_0, _swig_p) + return +} + +func (arg1 SwigcptrFoo) GetMsg__SWIG_0() (_swig_ret string) { + return _swig_wrap_Foo_GetMsg__SWIG_0(arg1) +} + +var _wrap_Foo_GetMsg__SWIG_1 unsafe.Pointer + +func _swig_wrap_Foo_GetMsg__SWIG_1(base SwigcptrFoo, _ string) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_GetMsg__SWIG_1, _swig_p) + return +} + +func (arg1 SwigcptrFoo) GetMsg__SWIG_1(arg2 string) (_swig_ret string) { + return _swig_wrap_Foo_GetMsg__SWIG_1(arg1, arg2) +} + +func (p SwigcptrFoo) GetMsg(a ...interface{}) string { + argc := len(a) + if argc == 0 { + return p.GetMsg__SWIG_0() + } + if argc == 1 { + return p.GetMsg__SWIG_1(a[0].(string)) + } + panic("No match for overloaded function call") +} + +type Foo interface { + Swigcptr() uintptr + SwigIsFoo() + DirectorInterface() interface{} + Msg(a ...interface{}) string + GetMsg(a ...interface{}) string +} + +type SwigcptrBar uintptr + +func (p SwigcptrBar) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrBar) SwigIsBar() { +} + +var _wrap_new_Bar__SWIG_0 unsafe.Pointer + +func _swig_wrap_new_Bar__SWIG_0() (base SwigcptrBar) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Bar__SWIG_0, _swig_p) + return +} + +func NewBar__SWIG_0() (_swig_ret Bar) { + return _swig_wrap_new_Bar__SWIG_0() +} + +var _wrap_new_Bar__SWIG_1 unsafe.Pointer + +func _swig_wrap_new_Bar__SWIG_1(base int) (_ SwigcptrBar) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Bar__SWIG_1, _swig_p) + return +} + +func NewBar__SWIG_1(arg1 int) (_swig_ret Bar) { + return _swig_wrap_new_Bar__SWIG_1(arg1) +} + +func NewBar(a ...interface{}) Bar { + argc := len(a) + if argc == 0 { + return NewBar__SWIG_0() + } + if argc == 1 { + return NewBar__SWIG_1(a[0].(int)) + } + panic("No match for overloaded function call") +} + +var _wrap_delete_Bar unsafe.Pointer + +func _swig_wrap_delete_Bar(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Bar, _swig_p) + return +} + +func DeleteBar(arg1 Bar) { + _swig_wrap_delete_Bar(arg1.Swigcptr()) +} + +var _wrap_Bar_Msg__SWIG_0 unsafe.Pointer + +func _swig_wrap_Bar_Msg__SWIG_0(base SwigcptrBar, _ string) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Bar_Msg__SWIG_0, _swig_p) + return +} + +func (arg1 SwigcptrBar) Msg__SWIG_0(arg2 string) (_swig_ret string) { + return _swig_wrap_Bar_Msg__SWIG_0(arg1, arg2) +} + +var _wrap_Bar_Msg__SWIG_1 unsafe.Pointer + +func _swig_wrap_Bar_Msg__SWIG_1(base SwigcptrBar) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Bar_Msg__SWIG_1, _swig_p) + return +} + +func (arg1 SwigcptrBar) Msg__SWIG_1() (_swig_ret string) { + return _swig_wrap_Bar_Msg__SWIG_1(arg1) +} + +func (p SwigcptrBar) Msg(a ...interface{}) string { + argc := len(a) + if argc == 0 { + return p.Msg__SWIG_1() + } + if argc == 1 { + return p.Msg__SWIG_0(a[0].(string)) + } + panic("No match for overloaded function call") +} + +var _wrap_Bar_GetMsg__SWIG_0 unsafe.Pointer + +func _swig_wrap_Bar_GetMsg__SWIG_0(base SwigcptrBar) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Bar_GetMsg__SWIG_0, _swig_p) + return +} + +func (arg1 SwigcptrBar) GetMsg__SWIG_0() (_swig_ret string) { + return _swig_wrap_Bar_GetMsg__SWIG_0(arg1) +} + +var _wrap_Bar_GetMsg__SWIG_1 unsafe.Pointer + +func _swig_wrap_Bar_GetMsg__SWIG_1(base SwigcptrBar, _ string) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Bar_GetMsg__SWIG_1, _swig_p) + return +} + +func (arg1 SwigcptrBar) GetMsg__SWIG_1(arg2 string) (_swig_ret string) { + return _swig_wrap_Bar_GetMsg__SWIG_1(arg1, arg2) +} + +func (p SwigcptrBar) GetMsg(a ...interface{}) string { + argc := len(a) + if argc == 0 { + return p.GetMsg__SWIG_0() + } + if argc == 1 { + return p.GetMsg__SWIG_1(a[0].(string)) + } + panic("No match for overloaded function call") +} + +type Bar interface { + Swigcptr() uintptr + SwigIsBar() + Msg(a ...interface{}) string + GetMsg(a ...interface{}) string +} + +type _swig_DirectorDefaultsBase struct { + SwigcptrDefaultsBase + v interface{} +} + +func (p *_swig_DirectorDefaultsBase) Swigcptr() uintptr { + return p.SwigcptrDefaultsBase.Swigcptr() +} + +func (p *_swig_DirectorDefaultsBase) SwigIsDefaultsBase() { +} + +func (p *_swig_DirectorDefaultsBase) DirectorInterface() interface{} { + return p.v +} + +var _wrap__swig_NewDirectorDefaultsBaseDefaultsBase unsafe.Pointer + +func _swig_NewDirectorDefaultsBaseDefaultsBase(_swig_director *_swig_DirectorDefaultsBase) (_swig_ret SwigcptrDefaultsBase) { + _swig_p := uintptr(unsafe.Pointer(&_swig_director)) + _cgo_runtime_cgocall(_wrap__swig_NewDirectorDefaultsBaseDefaultsBase, _swig_p) + return +} + +func NewDirectorDefaultsBase(v interface{}) DefaultsBase { + p := &_swig_DirectorDefaultsBase{0, v} + p.SwigcptrDefaultsBase = _swig_NewDirectorDefaultsBaseDefaultsBase(p) + return p +} + +type _swig_DirectorInterfaceDefaultsBaseDefaultargs__SWIG_0 interface { + Defaultargs__SWIG_0(float64, *int) *int +} + +func (swig_p *_swig_DirectorDefaultsBase) Defaultargs__SWIG_0(d float64, a *int) *int { + if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceDefaultsBaseDefaultargs__SWIG_0); swig_ok { + return swig_g.Defaultargs__SWIG_0(d, a) + } + panic("call to pure virtual method") +} + +func Swig_DirectorDefaultsBase_callback_defaultargs__SWIG_0(p *_swig_DirectorDefaultsBase, d float64, a *int) (swig_result *int) { + var swig_r *int + swig_r = p.Defaultargs__SWIG_0(d, a) + return swig_r +} + +type _swig_DirectorInterfaceDefaultsBaseDefaultargs__SWIG_1 interface { + Defaultargs__SWIG_1(float64) *int +} + +func (swig_p *_swig_DirectorDefaultsBase) Defaultargs__SWIG_1(d float64) *int { + if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceDefaultsBaseDefaultargs__SWIG_1); swig_ok { + return swig_g.Defaultargs__SWIG_1(d) + } + panic("call to pure virtual method") +} + +func Swig_DirectorDefaultsBase_callback_defaultargs__SWIG_1(p *_swig_DirectorDefaultsBase, d float64) (swig_result *int) { + var swig_r *int + swig_r = p.Defaultargs__SWIG_1(d) + return swig_r +} + +func (p _swig_DirectorDefaultsBase) Defaultargs(a ...interface{}) *int { + argc := len(a) + if argc == 1 { + return p.Defaultargs__SWIG_1(a[0].(float64)) + } + if argc == 2 { + return p.Defaultargs__SWIG_0(a[0].(float64), a[1].(*int)) + } + panic("No match for overloaded function call") +} + +var _wrap_DeleteDirectorDefaultsBase unsafe.Pointer + +func _swig_wrap_DeleteDirectorDefaultsBase(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_DeleteDirectorDefaultsBase, _swig_p) + return +} + +func DeleteDirectorDefaultsBase(arg1 DefaultsBase) { + _swig_wrap_DeleteDirectorDefaultsBase(arg1.Swigcptr()) +} + +func Swiggo_DeleteDirector_DefaultsBase(p *_swig_DirectorDefaultsBase) { + p.SwigcptrDefaultsBase = 0 +} + +type SwigcptrDefaultsBase uintptr + +func (p SwigcptrDefaultsBase) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrDefaultsBase) SwigIsDefaultsBase() { +} + +func (p SwigcptrDefaultsBase) DirectorInterface() interface{} { + return nil +} + +var _wrap_DefaultsBase_defaultargs__SWIG_0 unsafe.Pointer + +func _swig_wrap_DefaultsBase_defaultargs__SWIG_0(base SwigcptrDefaultsBase, _ float64, _ *int) (_ *int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_DefaultsBase_defaultargs__SWIG_0, _swig_p) + return +} + +func (arg1 SwigcptrDefaultsBase) Defaultargs__SWIG_0(arg2 float64, arg3 *int) (_swig_ret *int) { + return _swig_wrap_DefaultsBase_defaultargs__SWIG_0(arg1, arg2, arg3) +} + +var _wrap_DefaultsBase_defaultargs__SWIG_1 unsafe.Pointer + +func _swig_wrap_DefaultsBase_defaultargs__SWIG_1(base SwigcptrDefaultsBase, _ float64) (_ *int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_DefaultsBase_defaultargs__SWIG_1, _swig_p) + return +} + +func (arg1 SwigcptrDefaultsBase) Defaultargs__SWIG_1(arg2 float64) (_swig_ret *int) { + return _swig_wrap_DefaultsBase_defaultargs__SWIG_1(arg1, arg2) +} + +func (p SwigcptrDefaultsBase) Defaultargs(a ...interface{}) *int { + argc := len(a) + if argc == 1 { + return p.Defaultargs__SWIG_1(a[0].(float64)) + } + if argc == 2 { + return p.Defaultargs__SWIG_0(a[0].(float64), a[1].(*int)) + } + panic("No match for overloaded function call") +} + +var _wrap_delete_DefaultsBase unsafe.Pointer + +func _swig_wrap_delete_DefaultsBase(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_DefaultsBase, _swig_p) + return +} + +func DeleteDefaultsBase(arg1 DefaultsBase) { + _swig_wrap_delete_DefaultsBase(arg1.Swigcptr()) +} + +var _wrap_new_DefaultsBase unsafe.Pointer + +func _swig_wrap_new_DefaultsBase() (base SwigcptrDefaultsBase) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_DefaultsBase, _swig_p) + return +} + +func NewDefaultsBase() (_swig_ret DefaultsBase) { + return _swig_wrap_new_DefaultsBase() +} + +type DefaultsBase interface { + Swigcptr() uintptr + SwigIsDefaultsBase() + DirectorInterface() interface{} + Defaultargs(a ...interface{}) *int +} + +type _swig_DirectorDefaultsDerived struct { + SwigcptrDefaultsDerived + v interface{} +} + +func (p *_swig_DirectorDefaultsDerived) Swigcptr() uintptr { + return p.SwigcptrDefaultsDerived.Swigcptr() +} + +func (p *_swig_DirectorDefaultsDerived) SwigIsDefaultsDerived() { +} + +func (p *_swig_DirectorDefaultsDerived) DirectorInterface() interface{} { + return p.v +} + +var _wrap__swig_NewDirectorDefaultsDerivedDefaultsDerived unsafe.Pointer + +func _swig_NewDirectorDefaultsDerivedDefaultsDerived(_swig_director *_swig_DirectorDefaultsDerived) (_swig_ret SwigcptrDefaultsDerived) { + _swig_p := uintptr(unsafe.Pointer(&_swig_director)) + _cgo_runtime_cgocall(_wrap__swig_NewDirectorDefaultsDerivedDefaultsDerived, _swig_p) + return +} + +func NewDirectorDefaultsDerived(v interface{}) DefaultsDerived { + p := &_swig_DirectorDefaultsDerived{0, v} + p.SwigcptrDefaultsDerived = _swig_NewDirectorDefaultsDerivedDefaultsDerived(p) + return p +} + +type _swig_DirectorInterfaceDefaultsDerivedDefaultargs__SWIG_0 interface { + Defaultargs__SWIG_0(float64, *int) *int +} + +var _wrap__swig_DirectorDefaultsDerived_upcall_Defaultargs__SWIG_0 unsafe.Pointer + +func _swig_wrap__swig_DirectorDefaultsDerived_upcall_Defaultargs__SWIG_0(_swig_ptr SwigcptrDefaultsDerived, _ float64, _ *int) (_swig_ret *int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) + _cgo_runtime_cgocall(_wrap__swig_DirectorDefaultsDerived_upcall_Defaultargs__SWIG_0, _swig_p) + return +} + +func (swig_p *_swig_DirectorDefaultsDerived) Defaultargs__SWIG_0(d float64, a *int) *int { + if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceDefaultsDerivedDefaultargs__SWIG_0); swig_ok { + return swig_g.Defaultargs__SWIG_0(d, a) + } + var swig_r *int + swig_r = _swig_wrap__swig_DirectorDefaultsDerived_upcall_Defaultargs__SWIG_0(swig_p.SwigcptrDefaultsDerived, d, a) + return swig_r +} + +func DirectorDefaultsDerivedDefaultargs__SWIG_0(p DefaultsDerived, arg2 float64, arg3 *int) *int { + var swig_r *int + swig_r = _swig_wrap__swig_DirectorDefaultsDerived_upcall_Defaultargs__SWIG_0(p.(*_swig_DirectorDefaultsDerived).SwigcptrDefaultsDerived, arg2, arg3) + return swig_r +} + +func Swig_DirectorDefaultsDerived_callback_defaultargs__SWIG_0(p *_swig_DirectorDefaultsDerived, arg2 float64, arg3 *int) (swig_result *int) { + var swig_r *int + swig_r = p.Defaultargs__SWIG_0(arg2, arg3) + return swig_r +} + +type _swig_DirectorInterfaceDefaultsDerivedDefaultargs__SWIG_1 interface { + Defaultargs__SWIG_1(float64) *int +} + +var _wrap__swig_DirectorDefaultsDerived_upcall_Defaultargs__SWIG_1 unsafe.Pointer + +func _swig_wrap__swig_DirectorDefaultsDerived_upcall_Defaultargs__SWIG_1(_swig_ptr SwigcptrDefaultsDerived, _ float64) (_swig_ret *int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) + _cgo_runtime_cgocall(_wrap__swig_DirectorDefaultsDerived_upcall_Defaultargs__SWIG_1, _swig_p) + return +} + +func (swig_p *_swig_DirectorDefaultsDerived) Defaultargs__SWIG_1(d float64) *int { + if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceDefaultsDerivedDefaultargs__SWIG_1); swig_ok { + return swig_g.Defaultargs__SWIG_1(d) + } + var swig_r *int + swig_r = _swig_wrap__swig_DirectorDefaultsDerived_upcall_Defaultargs__SWIG_1(swig_p.SwigcptrDefaultsDerived, d) + return swig_r +} + +func DirectorDefaultsDerivedDefaultargs__SWIG_1(p DefaultsDerived, arg2 float64) *int { + var swig_r *int + swig_r = _swig_wrap__swig_DirectorDefaultsDerived_upcall_Defaultargs__SWIG_1(p.(*_swig_DirectorDefaultsDerived).SwigcptrDefaultsDerived, arg2) + return swig_r +} + +func Swig_DirectorDefaultsDerived_callback_defaultargs__SWIG_1(p *_swig_DirectorDefaultsDerived, arg2 float64) (swig_result *int) { + var swig_r *int + swig_r = p.Defaultargs__SWIG_1(arg2) + return swig_r +} + +func (p _swig_DirectorDefaultsDerived) Defaultargs(a ...interface{}) *int { + argc := len(a) + if argc == 1 { + return p.Defaultargs__SWIG_1(a[0].(float64)) + } + if argc == 2 { + return p.Defaultargs__SWIG_0(a[0].(float64), a[1].(*int)) + } + panic("No match for overloaded function call") +} + +func DirectorDefaultsDerivedDefaultargs(p *_swig_DirectorDefaultsDerived, a ...interface{}) *int { + argc := len(a) + if argc == 1 { + return DirectorDefaultsDerivedDefaultargs__SWIG_1(p, a[0].(float64)) + } + if argc == 2 { + return DirectorDefaultsDerivedDefaultargs__SWIG_0(p, a[0].(float64), a[1].(*int)) + } + panic("No match for overloaded function call") +} + +var _wrap_DeleteDirectorDefaultsDerived unsafe.Pointer + +func _swig_wrap_DeleteDirectorDefaultsDerived(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_DeleteDirectorDefaultsDerived, _swig_p) + return +} + +func DeleteDirectorDefaultsDerived(arg1 DefaultsDerived) { + _swig_wrap_DeleteDirectorDefaultsDerived(arg1.Swigcptr()) +} + +func Swiggo_DeleteDirector_DefaultsDerived(p *_swig_DirectorDefaultsDerived) { + p.SwigcptrDefaultsDerived = 0 +} + +type SwigcptrDefaultsDerived uintptr + +func (p SwigcptrDefaultsDerived) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrDefaultsDerived) SwigIsDefaultsDerived() { +} + +func (p SwigcptrDefaultsDerived) DirectorInterface() interface{} { + return nil +} + +var _wrap_DefaultsDerived_defaultargs__SWIG_0 unsafe.Pointer + +func _swig_wrap_DefaultsDerived_defaultargs__SWIG_0(base SwigcptrDefaultsDerived, _ float64, _ *int) (_ *int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_DefaultsDerived_defaultargs__SWIG_0, _swig_p) + return +} + +func (arg1 SwigcptrDefaultsDerived) Defaultargs__SWIG_0(arg2 float64, arg3 *int) (_swig_ret *int) { + return _swig_wrap_DefaultsDerived_defaultargs__SWIG_0(arg1, arg2, arg3) +} + +var _wrap_DefaultsDerived_defaultargs__SWIG_1 unsafe.Pointer + +func _swig_wrap_DefaultsDerived_defaultargs__SWIG_1(base SwigcptrDefaultsDerived, _ float64) (_ *int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_DefaultsDerived_defaultargs__SWIG_1, _swig_p) + return +} + +func (arg1 SwigcptrDefaultsDerived) Defaultargs__SWIG_1(arg2 float64) (_swig_ret *int) { + return _swig_wrap_DefaultsDerived_defaultargs__SWIG_1(arg1, arg2) +} + +func (p SwigcptrDefaultsDerived) Defaultargs(a ...interface{}) *int { + argc := len(a) + if argc == 1 { + return p.Defaultargs__SWIG_1(a[0].(float64)) + } + if argc == 2 { + return p.Defaultargs__SWIG_0(a[0].(float64), a[1].(*int)) + } + panic("No match for overloaded function call") +} + +var _wrap_new_DefaultsDerived unsafe.Pointer + +func _swig_wrap_new_DefaultsDerived() (base SwigcptrDefaultsDerived) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_DefaultsDerived, _swig_p) + return +} + +func NewDefaultsDerived() (_swig_ret DefaultsDerived) { + return _swig_wrap_new_DefaultsDerived() +} + +var _wrap_delete_DefaultsDerived unsafe.Pointer + +func _swig_wrap_delete_DefaultsDerived(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_DefaultsDerived, _swig_p) + return +} + +func DeleteDefaultsDerived(arg1 DefaultsDerived) { + _swig_wrap_delete_DefaultsDerived(arg1.Swigcptr()) +} + +func (p SwigcptrDefaultsDerived) SwigIsDefaultsBase() { +} + +func (p SwigcptrDefaultsDerived) SwigGetDefaultsBase() DefaultsBase { + return SwigcptrDefaultsBase(p.Swigcptr()) +} + +type DefaultsDerived interface { + Swigcptr() uintptr + SwigIsDefaultsDerived() + DirectorInterface() interface{} + Defaultargs(a ...interface{}) *int + SwigIsDefaultsBase() + SwigGetDefaultsBase() DefaultsBase +} + + +type SwigcptrSwigDirector_Foo uintptr +type SwigDirector_Foo interface { + Swigcptr() uintptr; +} +func (p SwigcptrSwigDirector_Foo) Swigcptr() uintptr { + return uintptr(p) +} + +type SwigcptrSwigDirector_DefaultsDerived uintptr +type SwigDirector_DefaultsDerived interface { + Swigcptr() uintptr; +} +func (p SwigcptrSwigDirector_DefaultsDerived) Swigcptr() uintptr { + return uintptr(p) +} + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/director_default_runme b/Examples/test-suite/go/director_default_runme new file mode 100755 index 000000000..3e4a374b8 Binary files /dev/null and b/Examples/test-suite/go/director_default_runme differ diff --git a/Examples/test-suite/go/director_default_wrap.h b/Examples/test-suite/go/director_default_wrap.h new file mode 100644 index 000000000..7426b727d --- /dev/null +++ b/Examples/test-suite/go/director_default_wrap.h @@ -0,0 +1,62 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../director_default.i + +#ifndef SWIG_director_default_WRAP_H_ +#define SWIG_director_default_WRAP_H_ + +class SwigDirector_Foo : public Foo +{ + public: + SwigDirector_Foo(void *swig_p, int i); + SwigDirector_Foo(void *swig_p); + virtual ~SwigDirector_Foo(); + std::string _swig_upcall_Msg__SWIG_0(std::string msg) { + return Foo::Msg(msg); + } + virtual std::string Msg(std::string msg); + std::string _swig_upcall_Msg__SWIG_1() { + return Foo::Msg(); + } + virtual std::string Msg(); + private: + void *go_val; +}; + +class SwigDirector_DefaultsBase : public DefaultsBase +{ + public: + SwigDirector_DefaultsBase(void *swig_p); + virtual IntegerPtr defaultargs(double d, int *a); + virtual IntegerPtr defaultargs(double d); + virtual ~SwigDirector_DefaultsBase(); + private: + void *go_val; +}; + +class SwigDirector_DefaultsDerived : public DefaultsDerived +{ + public: + SwigDirector_DefaultsDerived(void *swig_p); + int *_swig_upcall_defaultargs__SWIG_0(Double d, IntegerPtr a) { + return DefaultsDerived::defaultargs(d,a); + } + virtual int *defaultargs(Double d, IntegerPtr a); + int *_swig_upcall_defaultargs__SWIG_1(Double d) { + return DefaultsDerived::defaultargs(d); + } + virtual int *defaultargs(Double d); + virtual ~SwigDirector_DefaultsDerived(); + private: + void *go_val; +}; + +#endif diff --git a/Examples/test-suite/go/director_detect.go b/Examples/test-suite/go/director_detect.go new file mode 100644 index 000000000..5148e4584 --- /dev/null +++ b/Examples/test-suite/go/director_detect.go @@ -0,0 +1,581 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../director_detect.i + +package director_detect + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrA uintptr + +func (p SwigcptrA) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrA) SwigIsA() { +} + +var _wrap_new_A unsafe.Pointer + +func _swig_wrap_new_A() (base SwigcptrA) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_A, _swig_p) + return +} + +func NewA() (_swig_ret A) { + return _swig_wrap_new_A() +} + +var _wrap_delete_A unsafe.Pointer + +func _swig_wrap_delete_A(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_A, _swig_p) + return +} + +func DeleteA(arg1 A) { + _swig_wrap_delete_A(arg1.Swigcptr()) +} + +type A interface { + Swigcptr() uintptr + SwigIsA() +} + +type _swig_DirectorFoo struct { + SwigcptrFoo + v interface{} +} + +func (p *_swig_DirectorFoo) Swigcptr() uintptr { + return p.SwigcptrFoo.Swigcptr() +} + +func (p *_swig_DirectorFoo) SwigIsFoo() { +} + +func (p *_swig_DirectorFoo) DirectorInterface() interface{} { + return p.v +} + +var _wrap__swig_NewDirectorFooFoo unsafe.Pointer + +func _swig_NewDirectorFooFoo(_swig_director *_swig_DirectorFoo) (_swig_ret SwigcptrFoo) { + _swig_p := uintptr(unsafe.Pointer(&_swig_director)) + _cgo_runtime_cgocall(_wrap__swig_NewDirectorFooFoo, _swig_p) + return +} + +func NewDirectorFoo(v interface{}) Foo { + p := &_swig_DirectorFoo{0, v} + p.SwigcptrFoo = _swig_NewDirectorFooFoo(p) + return p +} + +var _wrap_DeleteDirectorFoo unsafe.Pointer + +func _swig_wrap_DeleteDirectorFoo(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_DeleteDirectorFoo, _swig_p) + return +} + +func DeleteDirectorFoo(arg1 Foo) { + _swig_wrap_DeleteDirectorFoo(arg1.Swigcptr()) +} + +func Swiggo_DeleteDirector_Foo(p *_swig_DirectorFoo) { + p.SwigcptrFoo = 0 +} + +type _swig_DirectorInterfaceFooCloner interface { + Cloner() Foo +} + +func (swig_p *_swig_DirectorFoo) Cloner() Foo { + if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceFooCloner); swig_ok { + return swig_g.Cloner() + } + panic("call to pure virtual method") +} + +func Swig_DirectorFoo_callback_cloner(p *_swig_DirectorFoo) (swig_result SwigcptrFoo) { + var swig_r SwigcptrFoo + swig_r = SwigcptrFoo(p.Cloner().Swigcptr()) + return swig_r +} + +type _swig_DirectorInterfaceFooGet_value interface { + Get_value() int +} + +func (swig_p *_swig_DirectorFoo) Get_value() int { + if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceFooGet_value); swig_ok { + return swig_g.Get_value() + } + panic("call to pure virtual method") +} + +func Swig_DirectorFoo_callback_get_value(p *_swig_DirectorFoo) (swig_result int) { + var swig_r int + swig_r = p.Get_value() + return swig_r +} + +type _swig_DirectorInterfaceFooGet_class interface { + Get_class() A +} + +func (swig_p *_swig_DirectorFoo) Get_class() A { + if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceFooGet_class); swig_ok { + return swig_g.Get_class() + } + panic("call to pure virtual method") +} + +func Swig_DirectorFoo_callback_get_class(p *_swig_DirectorFoo) (swig_result SwigcptrA) { + var swig_r SwigcptrA + swig_r = SwigcptrA(p.Get_class().Swigcptr()) + return swig_r +} + +type _swig_DirectorInterfaceFooJust_do_it interface { + Just_do_it() +} + +func (swig_p *_swig_DirectorFoo) Just_do_it() { + if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceFooJust_do_it); swig_ok { + swig_g.Just_do_it() + return + } + panic("call to pure virtual method") +} + +func Swig_DirectorFoo_callback_just_do_it(p *_swig_DirectorFoo) { + p.Just_do_it() +} + +type SwigcptrFoo uintptr + +func (p SwigcptrFoo) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrFoo) SwigIsFoo() { +} + +func (p SwigcptrFoo) DirectorInterface() interface{} { + return nil +} + +var _wrap_delete_Foo unsafe.Pointer + +func _swig_wrap_delete_Foo(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Foo, _swig_p) + return +} + +func DeleteFoo(arg1 Foo) { + _swig_wrap_delete_Foo(arg1.Swigcptr()) +} + +var _wrap_Foo_cloner unsafe.Pointer + +func _swig_wrap_Foo_cloner(base SwigcptrFoo) (_ SwigcptrFoo) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_cloner, _swig_p) + return +} + +func (arg1 SwigcptrFoo) Cloner() (_swig_ret Foo) { + return _swig_wrap_Foo_cloner(arg1) +} + +var _wrap_Foo_get_value unsafe.Pointer + +func _swig_wrap_Foo_get_value(base SwigcptrFoo) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_get_value, _swig_p) + return +} + +func (arg1 SwigcptrFoo) Get_value() (_swig_ret int) { + return _swig_wrap_Foo_get_value(arg1) +} + +var _wrap_Foo_get_class unsafe.Pointer + +func _swig_wrap_Foo_get_class(base SwigcptrFoo) (_ SwigcptrA) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_get_class, _swig_p) + return +} + +func (arg1 SwigcptrFoo) Get_class() (_swig_ret A) { + return _swig_wrap_Foo_get_class(arg1) +} + +var _wrap_Foo_just_do_it unsafe.Pointer + +func _swig_wrap_Foo_just_do_it(base SwigcptrFoo) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_just_do_it, _swig_p) + return +} + +func (arg1 SwigcptrFoo) Just_do_it() { + _swig_wrap_Foo_just_do_it(arg1) +} + +var _wrap_new_Foo unsafe.Pointer + +func _swig_wrap_new_Foo() (base SwigcptrFoo) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Foo, _swig_p) + return +} + +func NewFoo() (_swig_ret Foo) { + return _swig_wrap_new_Foo() +} + +type Foo interface { + Swigcptr() uintptr + SwigIsFoo() + DirectorInterface() interface{} + Cloner() (_swig_ret Foo) + Get_value() (_swig_ret int) + Get_class() (_swig_ret A) + Just_do_it() +} + +type _swig_DirectorBar struct { + SwigcptrBar + v interface{} +} + +func (p *_swig_DirectorBar) Swigcptr() uintptr { + return p.SwigcptrBar.Swigcptr() +} + +func (p *_swig_DirectorBar) SwigIsBar() { +} + +func (p *_swig_DirectorBar) DirectorInterface() interface{} { + return p.v +} + +var _wrap__swig_NewDirectorBarBar unsafe.Pointer + +func _swig_NewDirectorBarBar(_swig_director *_swig_DirectorBar) (_swig_ret SwigcptrBar) { + _swig_p := uintptr(unsafe.Pointer(&_swig_director)) + _cgo_runtime_cgocall(_wrap__swig_NewDirectorBarBar, _swig_p) + return +} + +func NewDirectorBar(v interface{}) Bar { + p := &_swig_DirectorBar{0, v} + p.SwigcptrBar = _swig_NewDirectorBarBar(p) + return p +} + +var _wrap_DeleteDirectorBar unsafe.Pointer + +func _swig_wrap_DeleteDirectorBar(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_DeleteDirectorBar, _swig_p) + return +} + +func DeleteDirectorBar(arg1 Bar) { + _swig_wrap_DeleteDirectorBar(arg1.Swigcptr()) +} + +func Swiggo_DeleteDirector_Bar(p *_swig_DirectorBar) { + p.SwigcptrBar = 0 +} + +type _swig_DirectorInterfaceBarCloner interface { + Cloner() Bar +} + +var _wrap__swig_DirectorBar_upcall_Cloner unsafe.Pointer + +func _swig_wrap__swig_DirectorBar_upcall_Cloner(_swig_ptr SwigcptrBar) (_swig_ret SwigcptrBar) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) + _cgo_runtime_cgocall(_wrap__swig_DirectorBar_upcall_Cloner, _swig_p) + return +} + +func (swig_p *_swig_DirectorBar) Cloner() Bar { + if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceBarCloner); swig_ok { + return swig_g.Cloner() + } + var swig_r Bar + swig_r = _swig_wrap__swig_DirectorBar_upcall_Cloner(swig_p.SwigcptrBar) + return swig_r +} + +func DirectorBarCloner(p Bar) Bar { + var swig_r Bar + swig_r = _swig_wrap__swig_DirectorBar_upcall_Cloner(p.(*_swig_DirectorBar).SwigcptrBar) + return swig_r +} + +func Swig_DirectorBar_callback_cloner(p *_swig_DirectorBar) (swig_result SwigcptrBar) { + var swig_r SwigcptrBar + swig_r = SwigcptrBar(p.Cloner().Swigcptr()) + return swig_r +} + +type _swig_DirectorInterfaceBarGet_value interface { + Get_value() int +} + +var _wrap__swig_DirectorBar_upcall_Get_value unsafe.Pointer + +func _swig_wrap__swig_DirectorBar_upcall_Get_value(_swig_ptr SwigcptrBar) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) + _cgo_runtime_cgocall(_wrap__swig_DirectorBar_upcall_Get_value, _swig_p) + return +} + +func (swig_p *_swig_DirectorBar) Get_value() int { + if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceBarGet_value); swig_ok { + return swig_g.Get_value() + } + var swig_r int + swig_r = _swig_wrap__swig_DirectorBar_upcall_Get_value(swig_p.SwigcptrBar) + return swig_r +} + +func DirectorBarGet_value(p Bar) int { + var swig_r int + swig_r = _swig_wrap__swig_DirectorBar_upcall_Get_value(p.(*_swig_DirectorBar).SwigcptrBar) + return swig_r +} + +func Swig_DirectorBar_callback_get_value(p *_swig_DirectorBar) (swig_result int) { + var swig_r int + swig_r = p.Get_value() + return swig_r +} + +type _swig_DirectorInterfaceBarGet_class interface { + Get_class() A +} + +var _wrap__swig_DirectorBar_upcall_Get_class unsafe.Pointer + +func _swig_wrap__swig_DirectorBar_upcall_Get_class(_swig_ptr SwigcptrBar) (_swig_ret SwigcptrA) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) + _cgo_runtime_cgocall(_wrap__swig_DirectorBar_upcall_Get_class, _swig_p) + return +} + +func (swig_p *_swig_DirectorBar) Get_class() A { + if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceBarGet_class); swig_ok { + return swig_g.Get_class() + } + var swig_r A + swig_r = _swig_wrap__swig_DirectorBar_upcall_Get_class(swig_p.SwigcptrBar) + return swig_r +} + +func DirectorBarGet_class(p Bar) A { + var swig_r A + swig_r = _swig_wrap__swig_DirectorBar_upcall_Get_class(p.(*_swig_DirectorBar).SwigcptrBar) + return swig_r +} + +func Swig_DirectorBar_callback_get_class(p *_swig_DirectorBar) (swig_result SwigcptrA) { + var swig_r SwigcptrA + swig_r = SwigcptrA(p.Get_class().Swigcptr()) + return swig_r +} + +type _swig_DirectorInterfaceBarJust_do_it interface { + Just_do_it() +} + +var _wrap__swig_DirectorBar_upcall_Just_do_it unsafe.Pointer + +func _swig_wrap__swig_DirectorBar_upcall_Just_do_it(_swig_ptr SwigcptrBar) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) + _cgo_runtime_cgocall(_wrap__swig_DirectorBar_upcall_Just_do_it, _swig_p) + return +} + +func (swig_p *_swig_DirectorBar) Just_do_it() { + if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceBarJust_do_it); swig_ok { + swig_g.Just_do_it() + return + } + _swig_wrap__swig_DirectorBar_upcall_Just_do_it(swig_p.SwigcptrBar) +} + +func DirectorBarJust_do_it(p Bar) { + _swig_wrap__swig_DirectorBar_upcall_Just_do_it(p.(*_swig_DirectorBar).SwigcptrBar) +} + +func Swig_DirectorBar_callback_just_do_it(p *_swig_DirectorBar) { + p.Just_do_it() +} + +type SwigcptrBar uintptr + +func (p SwigcptrBar) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrBar) SwigIsBar() { +} + +func (p SwigcptrBar) DirectorInterface() interface{} { + return nil +} + +var _wrap_Bar_baseclass unsafe.Pointer + +func _swig_wrap_Bar_baseclass(base SwigcptrBar) (_ SwigcptrFoo) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Bar_baseclass, _swig_p) + return +} + +func (arg1 SwigcptrBar) Baseclass() (_swig_ret Foo) { + return _swig_wrap_Bar_baseclass(arg1) +} + +var _wrap_Bar_cloner unsafe.Pointer + +func _swig_wrap_Bar_cloner(base SwigcptrBar) (_ SwigcptrBar) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Bar_cloner, _swig_p) + return +} + +func (arg1 SwigcptrBar) Cloner() (_swig_ret Bar) { + return _swig_wrap_Bar_cloner(arg1) +} + +var _wrap_Bar_get_value unsafe.Pointer + +func _swig_wrap_Bar_get_value(base SwigcptrBar) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Bar_get_value, _swig_p) + return +} + +func (arg1 SwigcptrBar) Get_value() (_swig_ret int) { + return _swig_wrap_Bar_get_value(arg1) +} + +var _wrap_Bar_get_class unsafe.Pointer + +func _swig_wrap_Bar_get_class(base SwigcptrBar) (_ SwigcptrA) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Bar_get_class, _swig_p) + return +} + +func (arg1 SwigcptrBar) Get_class() (_swig_ret A) { + return _swig_wrap_Bar_get_class(arg1) +} + +var _wrap_Bar_just_do_it unsafe.Pointer + +func _swig_wrap_Bar_just_do_it(base SwigcptrBar) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Bar_just_do_it, _swig_p) + return +} + +func (arg1 SwigcptrBar) Just_do_it() { + _swig_wrap_Bar_just_do_it(arg1) +} + +var _wrap_new_Bar unsafe.Pointer + +func _swig_wrap_new_Bar() (base SwigcptrBar) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Bar, _swig_p) + return +} + +func NewBar() (_swig_ret Bar) { + return _swig_wrap_new_Bar() +} + +var _wrap_delete_Bar unsafe.Pointer + +func _swig_wrap_delete_Bar(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Bar, _swig_p) + return +} + +func DeleteBar(arg1 Bar) { + _swig_wrap_delete_Bar(arg1.Swigcptr()) +} + +func (p SwigcptrBar) SwigIsFoo() { +} + +func (p SwigcptrBar) SwigGetFoo() Foo { + return SwigcptrFoo(p.Swigcptr()) +} + +type Bar interface { + Swigcptr() uintptr + SwigIsBar() + DirectorInterface() interface{} + Baseclass() (_swig_ret Foo) + Cloner() (_swig_ret Bar) + Get_value() (_swig_ret int) + Get_class() (_swig_ret A) + Just_do_it() + SwigIsFoo() + SwigGetFoo() Foo +} + + +type SwigcptrSwigDirector_Bar uintptr +type SwigDirector_Bar interface { + Swigcptr() uintptr; +} +func (p SwigcptrSwigDirector_Bar) Swigcptr() uintptr { + return uintptr(p) +} + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/director_detect_runme b/Examples/test-suite/go/director_detect_runme new file mode 100755 index 000000000..06736d0ce Binary files /dev/null and b/Examples/test-suite/go/director_detect_runme differ diff --git a/Examples/test-suite/go/director_detect_wrap.h b/Examples/test-suite/go/director_detect_wrap.h new file mode 100644 index 000000000..27d4ef17f --- /dev/null +++ b/Examples/test-suite/go/director_detect_wrap.h @@ -0,0 +1,54 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../director_detect.i + +#ifndef SWIG_director_detect_WRAP_H_ +#define SWIG_director_detect_WRAP_H_ + +class SwigDirector_Foo : public Foo +{ + public: + SwigDirector_Foo(void *swig_p); + virtual ~SwigDirector_Foo(); + virtual Foo *cloner(); + virtual int get_value(); + virtual A *get_class(); + virtual void just_do_it(); + private: + void *go_val; +}; + +class SwigDirector_Bar : public Bar +{ + public: + SwigDirector_Bar(void *swig_p); + virtual ~SwigDirector_Bar(); + Bar *_swig_upcall_cloner() { + return Bar::cloner(); + } + virtual Bar *cloner(); + foo::Int _swig_upcall_get_value() { + return Bar::get_value(); + } + virtual foo::Int get_value(); + B *_swig_upcall_get_class() { + return Bar::get_class(); + } + virtual B *get_class(); + void _swig_upcall_just_do_it() { + Bar::just_do_it(); + } + virtual void just_do_it(); + private: + void *go_val; +}; + +#endif diff --git a/Examples/test-suite/go/director_enum.go b/Examples/test-suite/go/director_enum.go new file mode 100644 index 000000000..39e25764c --- /dev/null +++ b/Examples/test-suite/go/director_enum.go @@ -0,0 +1,1436 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../director_enum.i + +package director_enum + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type EnumDirectorHello int +var _wrap_hi unsafe.Pointer + +func _swig_gethi() (_swig_ret EnumDirectorHello) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_hi, _swig_p) + return +} +var Hi EnumDirectorHello = _swig_gethi() +var _wrap_hello unsafe.Pointer + +func _swig_gethello() (_swig_ret EnumDirectorHello) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_hello, _swig_p) + return +} +var Hello EnumDirectorHello = _swig_gethello() +var _wrap_yo unsafe.Pointer + +func _swig_getyo() (_swig_ret EnumDirectorHello) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_yo, _swig_p) + return +} +var Yo EnumDirectorHello = _swig_getyo() +var _wrap_awright unsafe.Pointer + +func _swig_getawright() (_swig_ret EnumDirectorHello) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_awright, _swig_p) + return +} +var Awright EnumDirectorHello = _swig_getawright() +type _swig_DirectorFoo struct { + SwigcptrFoo + v interface{} +} + +func (p *_swig_DirectorFoo) Swigcptr() uintptr { + return p.SwigcptrFoo.Swigcptr() +} + +func (p *_swig_DirectorFoo) SwigIsFoo() { +} + +func (p *_swig_DirectorFoo) DirectorInterface() interface{} { + return p.v +} + +var _wrap__swig_NewDirectorFooFoo unsafe.Pointer + +func _swig_NewDirectorFooFoo(_swig_director *_swig_DirectorFoo) (_swig_ret SwigcptrFoo) { + _swig_p := uintptr(unsafe.Pointer(&_swig_director)) + _cgo_runtime_cgocall(_wrap__swig_NewDirectorFooFoo, _swig_p) + return +} + +func NewDirectorFoo(v interface{}) Foo { + p := &_swig_DirectorFoo{0, v} + p.SwigcptrFoo = _swig_NewDirectorFooFoo(p) + return p +} + +var _wrap_DeleteDirectorFoo unsafe.Pointer + +func _swig_wrap_DeleteDirectorFoo(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_DeleteDirectorFoo, _swig_p) + return +} + +func DeleteDirectorFoo(arg1 Foo) { + _swig_wrap_DeleteDirectorFoo(arg1.Swigcptr()) +} + +func Swiggo_DeleteDirector_Foo(p *_swig_DirectorFoo) { + p.SwigcptrFoo = 0 +} + +type _swig_DirectorInterfaceFooSay_hi__SWIG_0 interface { + Say_hi__SWIG_0(EnumDirectorHello) EnumDirectorHello +} + +var _wrap__swig_DirectorFoo_upcall_Say_hi__SWIG_0 unsafe.Pointer + +func _swig_wrap__swig_DirectorFoo_upcall_Say_hi__SWIG_0(_swig_ptr SwigcptrFoo, _ EnumDirectorHello) (_swig_ret EnumDirectorHello) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) + _cgo_runtime_cgocall(_wrap__swig_DirectorFoo_upcall_Say_hi__SWIG_0, _swig_p) + return +} + +func (swig_p *_swig_DirectorFoo) Say_hi__SWIG_0(h EnumDirectorHello) EnumDirectorHello { + if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceFooSay_hi__SWIG_0); swig_ok { + return swig_g.Say_hi__SWIG_0(h) + } + var swig_r EnumDirectorHello + swig_r = _swig_wrap__swig_DirectorFoo_upcall_Say_hi__SWIG_0(swig_p.SwigcptrFoo, h) + return swig_r +} + +func DirectorFooSay_hi__SWIG_0(p Foo, arg2 EnumDirectorHello) EnumDirectorHello { + var swig_r EnumDirectorHello + swig_r = _swig_wrap__swig_DirectorFoo_upcall_Say_hi__SWIG_0(p.(*_swig_DirectorFoo).SwigcptrFoo, arg2) + return swig_r +} + +func Swig_DirectorFoo_callback_say_hi__SWIG_0(p *_swig_DirectorFoo, arg2 EnumDirectorHello) (swig_result EnumDirectorHello) { + var swig_r EnumDirectorHello + swig_r = p.Say_hi__SWIG_0(arg2) + return swig_r +} + +type _swig_DirectorInterfaceFooSay_hello interface { + Say_hello(EnumDirectorHello) EnumDirectorHello +} + +var _wrap__swig_DirectorFoo_upcall_Say_hello unsafe.Pointer + +func _swig_wrap__swig_DirectorFoo_upcall_Say_hello(_swig_ptr SwigcptrFoo, _ EnumDirectorHello) (_swig_ret EnumDirectorHello) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) + _cgo_runtime_cgocall(_wrap__swig_DirectorFoo_upcall_Say_hello, _swig_p) + return +} + +func (swig_p *_swig_DirectorFoo) Say_hello(arg0 EnumDirectorHello) EnumDirectorHello { + if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceFooSay_hello); swig_ok { + return swig_g.Say_hello(arg0) + } + var swig_r EnumDirectorHello + swig_r = _swig_wrap__swig_DirectorFoo_upcall_Say_hello(swig_p.SwigcptrFoo, arg0) + return swig_r +} + +func DirectorFooSay_hello(p Foo, arg2 EnumDirectorHello) EnumDirectorHello { + var swig_r EnumDirectorHello + swig_r = _swig_wrap__swig_DirectorFoo_upcall_Say_hello(p.(*_swig_DirectorFoo).SwigcptrFoo, arg2) + return swig_r +} + +func Swig_DirectorFoo_callback_say_hello(p *_swig_DirectorFoo, arg2 EnumDirectorHello) (swig_result EnumDirectorHello) { + var swig_r EnumDirectorHello + swig_r = p.Say_hello(arg2) + return swig_r +} + +type _swig_DirectorInterfaceFooSay_hi__SWIG_1 interface { + Say_hi__SWIG_1(A) EnumDirectorHello +} + +var _wrap__swig_DirectorFoo_upcall_Say_hi__SWIG_1 unsafe.Pointer + +func _swig_wrap__swig_DirectorFoo_upcall_Say_hi__SWIG_1(_swig_ptr SwigcptrFoo, _ uintptr) (_swig_ret EnumDirectorHello) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) + _cgo_runtime_cgocall(_wrap__swig_DirectorFoo_upcall_Say_hi__SWIG_1, _swig_p) + return +} + +func (swig_p *_swig_DirectorFoo) Say_hi__SWIG_1(a A) EnumDirectorHello { + if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceFooSay_hi__SWIG_1); swig_ok { + return swig_g.Say_hi__SWIG_1(a) + } + var swig_r EnumDirectorHello + swig_r = _swig_wrap__swig_DirectorFoo_upcall_Say_hi__SWIG_1(swig_p.SwigcptrFoo, a.Swigcptr()) + return swig_r +} + +func DirectorFooSay_hi__SWIG_1(p Foo, arg2 A) EnumDirectorHello { + var swig_r EnumDirectorHello + swig_r = _swig_wrap__swig_DirectorFoo_upcall_Say_hi__SWIG_1(p.(*_swig_DirectorFoo).SwigcptrFoo, arg2.Swigcptr()) + return swig_r +} + +func Swig_DirectorFoo_callback_say_hi__SWIG_1(p *_swig_DirectorFoo, arg2 uintptr) (swig_result EnumDirectorHello) { + var swig_r EnumDirectorHello + swig_r = p.Say_hi__SWIG_1(SwigcptrA(arg2)) + return swig_r +} + +func (p _swig_DirectorFoo) Say_hi(a ...interface{}) EnumDirectorHello { + argc := len(a) + if argc == 1 { + if _, ok := a[0].(EnumDirectorHello); !ok { + goto check_1 + } + return p.Say_hi__SWIG_0(a[0].(EnumDirectorHello)) + } +check_1: + if argc == 1 { + return p.Say_hi__SWIG_1(a[0].(A)) + } + panic("No match for overloaded function call") +} + +func DirectorFooSay_hi(p *_swig_DirectorFoo, a ...interface{}) EnumDirectorHello { + argc := len(a) + if argc == 1 { + if _, ok := a[0].(EnumDirectorHello); !ok { + goto check_1 + } + return DirectorFooSay_hi__SWIG_0(p, a[0].(EnumDirectorHello)) + } +check_1: + if argc == 1 { + return DirectorFooSay_hi__SWIG_1(p, a[0].(A)) + } + panic("No match for overloaded function call") +} + +type _swig_DirectorInterfaceFooSay_bye interface { + Say_bye(EnumDirectorFooBye) EnumDirectorFooBye +} + +var _wrap__swig_DirectorFoo_upcall_Say_bye unsafe.Pointer + +func _swig_wrap__swig_DirectorFoo_upcall_Say_bye(_swig_ptr SwigcptrFoo, _ EnumDirectorFooBye) (_swig_ret EnumDirectorFooBye) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) + _cgo_runtime_cgocall(_wrap__swig_DirectorFoo_upcall_Say_bye, _swig_p) + return +} + +func (swig_p *_swig_DirectorFoo) Say_bye(b EnumDirectorFooBye) EnumDirectorFooBye { + if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceFooSay_bye); swig_ok { + return swig_g.Say_bye(b) + } + var swig_r EnumDirectorFooBye + swig_r = _swig_wrap__swig_DirectorFoo_upcall_Say_bye(swig_p.SwigcptrFoo, b) + return swig_r +} + +func DirectorFooSay_bye(p Foo, arg2 EnumDirectorFooBye) EnumDirectorFooBye { + var swig_r EnumDirectorFooBye + swig_r = _swig_wrap__swig_DirectorFoo_upcall_Say_bye(p.(*_swig_DirectorFoo).SwigcptrFoo, arg2) + return swig_r +} + +func Swig_DirectorFoo_callback_say_bye(p *_swig_DirectorFoo, arg2 EnumDirectorFooBye) (swig_result EnumDirectorFooBye) { + var swig_r EnumDirectorFooBye + swig_r = p.Say_bye(arg2) + return swig_r +} + +type _swig_DirectorInterfaceFooSay_hi_ref interface { + Say_hi_ref(*EnumDirectorHello) *EnumDirectorHello +} + +var _wrap__swig_DirectorFoo_upcall_Say_hi_ref unsafe.Pointer + +func _swig_wrap__swig_DirectorFoo_upcall_Say_hi_ref(_swig_ptr SwigcptrFoo, _ *EnumDirectorHello) (_swig_ret *EnumDirectorHello) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) + _cgo_runtime_cgocall(_wrap__swig_DirectorFoo_upcall_Say_hi_ref, _swig_p) + return +} + +func (swig_p *_swig_DirectorFoo) Say_hi_ref(h *EnumDirectorHello) *EnumDirectorHello { + if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceFooSay_hi_ref); swig_ok { + return swig_g.Say_hi_ref(h) + } + var swig_r *EnumDirectorHello + swig_r = _swig_wrap__swig_DirectorFoo_upcall_Say_hi_ref(swig_p.SwigcptrFoo, h) + return swig_r +} + +func DirectorFooSay_hi_ref(p Foo, arg2 *EnumDirectorHello) *EnumDirectorHello { + var swig_r *EnumDirectorHello + swig_r = _swig_wrap__swig_DirectorFoo_upcall_Say_hi_ref(p.(*_swig_DirectorFoo).SwigcptrFoo, arg2) + return swig_r +} + +func Swig_DirectorFoo_callback_say_hi_ref(p *_swig_DirectorFoo, arg2 *EnumDirectorHello) (swig_result *EnumDirectorHello) { + var swig_r *EnumDirectorHello + swig_r = p.Say_hi_ref(arg2) + return swig_r +} + +type SwigcptrFoo uintptr + +func (p SwigcptrFoo) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrFoo) SwigIsFoo() { +} + +func (p SwigcptrFoo) DirectorInterface() interface{} { + return nil +} + +type EnumDirectorFooBye int +var _wrap_ciao_Foo unsafe.Pointer + +func _swig_getFoo_ciao_Foo() (_swig_ret EnumDirectorFooBye) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_ciao_Foo, _swig_p) + return +} +var FooCiao EnumDirectorFooBye = _swig_getFoo_ciao_Foo() +var _wrap_aufwiedersehen_Foo unsafe.Pointer + +func _swig_getFoo_aufwiedersehen_Foo() (_swig_ret EnumDirectorFooBye) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_aufwiedersehen_Foo, _swig_p) + return +} +var FooAufwiedersehen EnumDirectorFooBye = _swig_getFoo_aufwiedersehen_Foo() +var _wrap_adios_Foo unsafe.Pointer + +func _swig_getFoo_adios_Foo() (_swig_ret EnumDirectorFooBye) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_adios_Foo, _swig_p) + return +} +var FooAdios EnumDirectorFooBye = _swig_getFoo_adios_Foo() +var _wrap_delete_Foo unsafe.Pointer + +func _swig_wrap_delete_Foo(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Foo, _swig_p) + return +} + +func DeleteFoo(arg1 Foo) { + _swig_wrap_delete_Foo(arg1.Swigcptr()) +} + +var _wrap_Foo_say_hi__SWIG_0 unsafe.Pointer + +func _swig_wrap_Foo_say_hi__SWIG_0(base SwigcptrFoo, _ EnumDirectorHello) (_ EnumDirectorHello) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_say_hi__SWIG_0, _swig_p) + return +} + +func (arg1 SwigcptrFoo) Say_hi__SWIG_0(arg2 EnumDirectorHello) (_swig_ret EnumDirectorHello) { + return _swig_wrap_Foo_say_hi__SWIG_0(arg1, arg2) +} + +var _wrap_Foo_say_hello unsafe.Pointer + +func _swig_wrap_Foo_say_hello(base SwigcptrFoo, _ EnumDirectorHello) (_ EnumDirectorHello) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_say_hello, _swig_p) + return +} + +func (arg1 SwigcptrFoo) Say_hello(arg2 EnumDirectorHello) (_swig_ret EnumDirectorHello) { + return _swig_wrap_Foo_say_hello(arg1, arg2) +} + +var _wrap_Foo_say_hi__SWIG_1 unsafe.Pointer + +func _swig_wrap_Foo_say_hi__SWIG_1(base SwigcptrFoo, _ uintptr) (_ EnumDirectorHello) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_say_hi__SWIG_1, _swig_p) + return +} + +func (arg1 SwigcptrFoo) Say_hi__SWIG_1(arg2 A) (_swig_ret EnumDirectorHello) { + return _swig_wrap_Foo_say_hi__SWIG_1(arg1, arg2.Swigcptr()) +} + +func (p SwigcptrFoo) Say_hi(a ...interface{}) EnumDirectorHello { + argc := len(a) + if argc == 1 { + if _, ok := a[0].(EnumDirectorHello); !ok { + goto check_1 + } + return p.Say_hi__SWIG_0(a[0].(EnumDirectorHello)) + } +check_1: + if argc == 1 { + return p.Say_hi__SWIG_1(a[0].(A)) + } + panic("No match for overloaded function call") +} + +var _wrap_Foo_say_bye unsafe.Pointer + +func _swig_wrap_Foo_say_bye(base SwigcptrFoo, _ EnumDirectorFooBye) (_ EnumDirectorFooBye) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_say_bye, _swig_p) + return +} + +func (arg1 SwigcptrFoo) Say_bye(arg2 EnumDirectorFooBye) (_swig_ret EnumDirectorFooBye) { + return _swig_wrap_Foo_say_bye(arg1, arg2) +} + +var _wrap_Foo_say_hi_ref unsafe.Pointer + +func _swig_wrap_Foo_say_hi_ref(base SwigcptrFoo, _ *EnumDirectorHello) (_ *EnumDirectorHello) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_say_hi_ref, _swig_p) + return +} + +func (arg1 SwigcptrFoo) Say_hi_ref(arg2 *EnumDirectorHello) (_swig_ret *EnumDirectorHello) { + return _swig_wrap_Foo_say_hi_ref(arg1, arg2) +} + +var _wrap_Foo_ping unsafe.Pointer + +func _swig_wrap_Foo_ping(base SwigcptrFoo, _ EnumDirectorHello) (_ EnumDirectorHello) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_ping, _swig_p) + return +} + +func (arg1 SwigcptrFoo) Ping(arg2 EnumDirectorHello) (_swig_ret EnumDirectorHello) { + return _swig_wrap_Foo_ping(arg1, arg2) +} + +var _wrap_Foo_ping_ref unsafe.Pointer + +func _swig_wrap_Foo_ping_ref(base SwigcptrFoo, _ *EnumDirectorHello) (_ *EnumDirectorHello) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_ping_ref, _swig_p) + return +} + +func (arg1 SwigcptrFoo) Ping_ref(arg2 *EnumDirectorHello) (_swig_ret *EnumDirectorHello) { + return _swig_wrap_Foo_ping_ref(arg1, arg2) +} + +var _wrap_Foo_ping_member_enum unsafe.Pointer + +func _swig_wrap_Foo_ping_member_enum(base SwigcptrFoo, _ EnumDirectorFooBye) (_ EnumDirectorFooBye) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_ping_member_enum, _swig_p) + return +} + +func (arg1 SwigcptrFoo) Ping_member_enum(arg2 EnumDirectorFooBye) (_swig_ret EnumDirectorFooBye) { + return _swig_wrap_Foo_ping_member_enum(arg1, arg2) +} + +var _wrap_new_Foo unsafe.Pointer + +func _swig_wrap_new_Foo() (base SwigcptrFoo) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Foo, _swig_p) + return +} + +func NewFoo() (_swig_ret Foo) { + return _swig_wrap_new_Foo() +} + +type Foo interface { + Swigcptr() uintptr + SwigIsFoo() + DirectorInterface() interface{} + Say_hello(arg2 EnumDirectorHello) (_swig_ret EnumDirectorHello) + Say_hi(a ...interface{}) EnumDirectorHello + Say_bye(arg2 EnumDirectorFooBye) (_swig_ret EnumDirectorFooBye) + Say_hi_ref(arg2 *EnumDirectorHello) (_swig_ret *EnumDirectorHello) + Ping(arg2 EnumDirectorHello) (_swig_ret EnumDirectorHello) + Ping_ref(arg2 *EnumDirectorHello) (_swig_ret *EnumDirectorHello) + Ping_member_enum(arg2 EnumDirectorFooBye) (_swig_ret EnumDirectorFooBye) +} + +type EnumDirectorFType int +var _wrap_SA unsafe.Pointer + +func _swig_getSA() (_swig_ret EnumDirectorFType) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_SA, _swig_p) + return +} +var SA EnumDirectorFType = _swig_getSA() +var _wrap_NA_ unsafe.Pointer + +func _swig_getNA_() (_swig_ret EnumDirectorFType) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_NA_, _swig_p) + return +} +var NA_ EnumDirectorFType = _swig_getNA_() +var _wrap_EA unsafe.Pointer + +func _swig_getEA() (_swig_ret EnumDirectorFType) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_EA, _swig_p) + return +} +var EA EnumDirectorFType = _swig_getEA() +type _swig_DirectorA struct { + SwigcptrA + v interface{} +} + +func (p *_swig_DirectorA) Swigcptr() uintptr { + return p.SwigcptrA.Swigcptr() +} + +func (p *_swig_DirectorA) SwigIsA() { +} + +func (p *_swig_DirectorA) DirectorInterface() interface{} { + return p.v +} + +var _wrap__swig_NewDirectorAA unsafe.Pointer + +func _swig_NewDirectorAA(_swig_director *_swig_DirectorA, _ float64, _ float64, _ EnumDirectorFType) (_swig_ret SwigcptrA) { + _swig_p := uintptr(unsafe.Pointer(&_swig_director)) + _cgo_runtime_cgocall(_wrap__swig_NewDirectorAA, _swig_p) + return +} + +func NewDirectorA(v interface{}, arg1 float64, arg2 float64, arg3 EnumDirectorFType) A { + p := &_swig_DirectorA{0, v} + p.SwigcptrA = _swig_NewDirectorAA(p, arg1, arg2, arg3) + return p +} + +var _wrap_DeleteDirectorA unsafe.Pointer + +func _swig_wrap_DeleteDirectorA(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_DeleteDirectorA, _swig_p) + return +} + +func DeleteDirectorA(arg1 A) { + _swig_wrap_DeleteDirectorA(arg1.Swigcptr()) +} + +func Swiggo_DeleteDirector_A(p *_swig_DirectorA) { + p.SwigcptrA = 0 +} + +type _swig_DirectorInterfaceAF__SWIG_0 interface { + F__SWIG_0(int) int +} + +var _wrap__swig_DirectorA_upcall_F__SWIG_0 unsafe.Pointer + +func _swig_wrap__swig_DirectorA_upcall_F__SWIG_0(_swig_ptr SwigcptrA, _ int) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) + _cgo_runtime_cgocall(_wrap__swig_DirectorA_upcall_F__SWIG_0, _swig_p) + return +} + +func (swig_p *_swig_DirectorA) F__SWIG_0(i int) int { + if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceAF__SWIG_0); swig_ok { + return swig_g.F__SWIG_0(i) + } + var swig_r int + swig_r = _swig_wrap__swig_DirectorA_upcall_F__SWIG_0(swig_p.SwigcptrA, i) + return swig_r +} + +func DirectorAF__SWIG_0(p A, arg2 int) int { + var swig_r int + swig_r = _swig_wrap__swig_DirectorA_upcall_F__SWIG_0(p.(*_swig_DirectorA).SwigcptrA, arg2) + return swig_r +} + +func Swig_DirectorA_callback_f__SWIG_0(p *_swig_DirectorA, arg2 int) (swig_result int) { + var swig_r int + swig_r = p.F__SWIG_0(arg2) + return swig_r +} + +type _swig_DirectorInterfaceAF__SWIG_1 interface { + F__SWIG_1() int +} + +var _wrap__swig_DirectorA_upcall_F__SWIG_1 unsafe.Pointer + +func _swig_wrap__swig_DirectorA_upcall_F__SWIG_1(_swig_ptr SwigcptrA) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) + _cgo_runtime_cgocall(_wrap__swig_DirectorA_upcall_F__SWIG_1, _swig_p) + return +} + +func (swig_p *_swig_DirectorA) F__SWIG_1() int { + if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceAF__SWIG_1); swig_ok { + return swig_g.F__SWIG_1() + } + var swig_r int + swig_r = _swig_wrap__swig_DirectorA_upcall_F__SWIG_1(swig_p.SwigcptrA) + return swig_r +} + +func DirectorAF__SWIG_1(p A) int { + var swig_r int + swig_r = _swig_wrap__swig_DirectorA_upcall_F__SWIG_1(p.(*_swig_DirectorA).SwigcptrA) + return swig_r +} + +func Swig_DirectorA_callback_f__SWIG_1(p *_swig_DirectorA) (swig_result int) { + var swig_r int + swig_r = p.F__SWIG_1() + return swig_r +} + +func (p _swig_DirectorA) F(a ...interface{}) int { + argc := len(a) + if argc == 0 { + return p.F__SWIG_1() + } + if argc == 1 { + return p.F__SWIG_0(a[0].(int)) + } + panic("No match for overloaded function call") +} + +func DirectorAF(p *_swig_DirectorA, a ...interface{}) int { + argc := len(a) + if argc == 0 { + return DirectorAF__SWIG_1(p) + } + if argc == 1 { + return DirectorAF__SWIG_0(p, a[0].(int)) + } + panic("No match for overloaded function call") +} + +type SwigcptrA uintptr + +func (p SwigcptrA) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrA) SwigIsA() { +} + +func (p SwigcptrA) DirectorInterface() interface{} { + return nil +} + +var _wrap_new_A unsafe.Pointer + +func _swig_wrap_new_A(base float64, _ float64, _ EnumDirectorFType) (_ SwigcptrA) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_A, _swig_p) + return +} + +func NewA(arg1 float64, arg2 float64, arg3 EnumDirectorFType) (_swig_ret A) { + return _swig_wrap_new_A(arg1, arg2, arg3) +} + +var _wrap_delete_A unsafe.Pointer + +func _swig_wrap_delete_A(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_A, _swig_p) + return +} + +func DeleteA(arg1 A) { + _swig_wrap_delete_A(arg1.Swigcptr()) +} + +var _wrap_A_f__SWIG_0 unsafe.Pointer + +func _swig_wrap_A_f__SWIG_0(base SwigcptrA, _ int) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_A_f__SWIG_0, _swig_p) + return +} + +func (arg1 SwigcptrA) F__SWIG_0(arg2 int) (_swig_ret int) { + return _swig_wrap_A_f__SWIG_0(arg1, arg2) +} + +var _wrap_A_f__SWIG_1 unsafe.Pointer + +func _swig_wrap_A_f__SWIG_1(base SwigcptrA) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_A_f__SWIG_1, _swig_p) + return +} + +func (arg1 SwigcptrA) F__SWIG_1() (_swig_ret int) { + return _swig_wrap_A_f__SWIG_1(arg1) +} + +func (p SwigcptrA) F(a ...interface{}) int { + argc := len(a) + if argc == 0 { + return p.F__SWIG_1() + } + if argc == 1 { + return p.F__SWIG_0(a[0].(int)) + } + panic("No match for overloaded function call") +} + +type A interface { + Swigcptr() uintptr + SwigIsA() + DirectorInterface() interface{} + F(a ...interface{}) int +} + +type _swig_DirectorB struct { + SwigcptrB + v interface{} +} + +func (p *_swig_DirectorB) Swigcptr() uintptr { + return p.SwigcptrB.Swigcptr() +} + +func (p *_swig_DirectorB) SwigIsB() { +} + +func (p *_swig_DirectorB) DirectorInterface() interface{} { + return p.v +} + +var _wrap__swig_NewDirectorBB unsafe.Pointer + +func _swig_NewDirectorBB(_swig_director *_swig_DirectorB, _ float64, _ float64, _ EnumDirectorFType) (_swig_ret SwigcptrB) { + _swig_p := uintptr(unsafe.Pointer(&_swig_director)) + _cgo_runtime_cgocall(_wrap__swig_NewDirectorBB, _swig_p) + return +} + +func NewDirectorB(v interface{}, arg1 float64, arg2 float64, arg3 EnumDirectorFType) B { + p := &_swig_DirectorB{0, v} + p.SwigcptrB = _swig_NewDirectorBB(p, arg1, arg2, arg3) + return p +} + +var _wrap_DeleteDirectorB unsafe.Pointer + +func _swig_wrap_DeleteDirectorB(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_DeleteDirectorB, _swig_p) + return +} + +func DeleteDirectorB(arg1 B) { + _swig_wrap_DeleteDirectorB(arg1.Swigcptr()) +} + +func Swiggo_DeleteDirector_B(p *_swig_DirectorB) { + p.SwigcptrB = 0 +} + +type _swig_DirectorInterfaceBF__SWIG_0 interface { + F__SWIG_0(int) int +} + +var _wrap__swig_DirectorB_upcall_F__SWIG_0 unsafe.Pointer + +func _swig_wrap__swig_DirectorB_upcall_F__SWIG_0(_swig_ptr SwigcptrB, _ int) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) + _cgo_runtime_cgocall(_wrap__swig_DirectorB_upcall_F__SWIG_0, _swig_p) + return +} + +func (swig_p *_swig_DirectorB) F__SWIG_0(i int) int { + if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceBF__SWIG_0); swig_ok { + return swig_g.F__SWIG_0(i) + } + var swig_r int + swig_r = _swig_wrap__swig_DirectorB_upcall_F__SWIG_0(swig_p.SwigcptrB, i) + return swig_r +} + +func DirectorBF__SWIG_0(p B, arg2 int) int { + var swig_r int + swig_r = _swig_wrap__swig_DirectorB_upcall_F__SWIG_0(p.(*_swig_DirectorB).SwigcptrB, arg2) + return swig_r +} + +func Swig_DirectorB_callback_f__SWIG_0(p *_swig_DirectorB, arg2 int) (swig_result int) { + var swig_r int + swig_r = p.F__SWIG_0(arg2) + return swig_r +} + +type _swig_DirectorInterfaceBF__SWIG_1 interface { + F__SWIG_1() int +} + +var _wrap__swig_DirectorB_upcall_F__SWIG_1 unsafe.Pointer + +func _swig_wrap__swig_DirectorB_upcall_F__SWIG_1(_swig_ptr SwigcptrB) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) + _cgo_runtime_cgocall(_wrap__swig_DirectorB_upcall_F__SWIG_1, _swig_p) + return +} + +func (swig_p *_swig_DirectorB) F__SWIG_1() int { + if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceBF__SWIG_1); swig_ok { + return swig_g.F__SWIG_1() + } + var swig_r int + swig_r = _swig_wrap__swig_DirectorB_upcall_F__SWIG_1(swig_p.SwigcptrB) + return swig_r +} + +func DirectorBF__SWIG_1(p B) int { + var swig_r int + swig_r = _swig_wrap__swig_DirectorB_upcall_F__SWIG_1(p.(*_swig_DirectorB).SwigcptrB) + return swig_r +} + +func Swig_DirectorB_callback_f__SWIG_1(p *_swig_DirectorB) (swig_result int) { + var swig_r int + swig_r = p.F__SWIG_1() + return swig_r +} + +type SwigcptrB uintptr + +func (p SwigcptrB) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrB) SwigIsB() { +} + +func (p SwigcptrB) DirectorInterface() interface{} { + return nil +} + +var _wrap_new_B unsafe.Pointer + +func _swig_wrap_new_B(base float64, _ float64, _ EnumDirectorFType) (_ SwigcptrB) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_B, _swig_p) + return +} + +func NewB(arg1 float64, arg2 float64, arg3 EnumDirectorFType) (_swig_ret B) { + return _swig_wrap_new_B(arg1, arg2, arg3) +} + +var _wrap_delete_B unsafe.Pointer + +func _swig_wrap_delete_B(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_B, _swig_p) + return +} + +func DeleteB(arg1 B) { + _swig_wrap_delete_B(arg1.Swigcptr()) +} + +var _wrap_B_f__SWIG_0 unsafe.Pointer + +func _swig_wrap_B_f__SWIG_0(base SwigcptrB, _ int) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_B_f__SWIG_0, _swig_p) + return +} + +func (_swig_base SwigcptrB) F__SWIG_0(arg1 int) (_swig_ret int) { + return _swig_wrap_B_f__SWIG_0(_swig_base, arg1) +} + +var _wrap_B_f__SWIG_1 unsafe.Pointer + +func _swig_wrap_B_f__SWIG_1(base SwigcptrB) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_B_f__SWIG_1, _swig_p) + return +} + +func (_swig_base SwigcptrB) F__SWIG_1() (_swig_ret int) { + return _swig_wrap_B_f__SWIG_1(_swig_base) +} + +func (p SwigcptrB) F(a ...interface{}) int { + argc := len(a) + if argc == 0 { + return p.F__SWIG_1() + } + if argc == 1 { + return p.F__SWIG_0(a[0].(int)) + } + panic("No match for overloaded function call") +} + +func (p SwigcptrB) SwigIsA() { +} + +func (p SwigcptrB) SwigGetA() A { + return SwigcptrA(p.Swigcptr()) +} + +type B interface { + Swigcptr() uintptr + SwigIsB() + DirectorInterface() interface{} + F(a ...interface{}) int + SwigIsA() + SwigGetA() A +} + +type _swig_DirectorA2 struct { + SwigcptrA2 + v interface{} +} + +func (p *_swig_DirectorA2) Swigcptr() uintptr { + return p.SwigcptrA2.Swigcptr() +} + +func (p *_swig_DirectorA2) SwigIsA2() { +} + +func (p *_swig_DirectorA2) DirectorInterface() interface{} { + return p.v +} + +var _wrap__swig_NewDirectorA2A2__SWIG_0 unsafe.Pointer + +func _swig_NewDirectorA2A2__SWIG_0(_swig_director *_swig_DirectorA2, _ EnumDirectorFType) (_swig_ret SwigcptrA2) { + _swig_p := uintptr(unsafe.Pointer(&_swig_director)) + _cgo_runtime_cgocall(_wrap__swig_NewDirectorA2A2__SWIG_0, _swig_p) + return +} + +func NewDirectorA2__SWIG_0(v interface{}, arg1 EnumDirectorFType) A2 { + p := &_swig_DirectorA2{0, v} + p.SwigcptrA2 = _swig_NewDirectorA2A2__SWIG_0(p, arg1) + return p +} + +var _wrap__swig_NewDirectorA2A2__SWIG_1 unsafe.Pointer + +func _swig_NewDirectorA2A2__SWIG_1(_swig_director *_swig_DirectorA2) (_swig_ret SwigcptrA2) { + _swig_p := uintptr(unsafe.Pointer(&_swig_director)) + _cgo_runtime_cgocall(_wrap__swig_NewDirectorA2A2__SWIG_1, _swig_p) + return +} + +func NewDirectorA2__SWIG_1(v interface{}) A2 { + p := &_swig_DirectorA2{0, v} + p.SwigcptrA2 = _swig_NewDirectorA2A2__SWIG_1(p) + return p +} + +func NewDirectorA2(abi interface{}, a ...interface{}) A2 { + argc := len(a) + if argc == 0 { + return NewDirectorA2__SWIG_1(abi) + } + if argc == 1 { + return NewDirectorA2__SWIG_0(abi, a[0].(EnumDirectorFType)) + } + panic("No match for overloaded function call") +} + +var _wrap_DeleteDirectorA2 unsafe.Pointer + +func _swig_wrap_DeleteDirectorA2(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_DeleteDirectorA2, _swig_p) + return +} + +func DeleteDirectorA2(arg1 A2) { + _swig_wrap_DeleteDirectorA2(arg1.Swigcptr()) +} + +func Swiggo_DeleteDirector_A2(p *_swig_DirectorA2) { + p.SwigcptrA2 = 0 +} + +type _swig_DirectorInterfaceA2F__SWIG_0 interface { + F__SWIG_0(int) int +} + +var _wrap__swig_DirectorA2_upcall_F__SWIG_0 unsafe.Pointer + +func _swig_wrap__swig_DirectorA2_upcall_F__SWIG_0(_swig_ptr SwigcptrA2, _ int) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) + _cgo_runtime_cgocall(_wrap__swig_DirectorA2_upcall_F__SWIG_0, _swig_p) + return +} + +func (swig_p *_swig_DirectorA2) F__SWIG_0(i int) int { + if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceA2F__SWIG_0); swig_ok { + return swig_g.F__SWIG_0(i) + } + var swig_r int + swig_r = _swig_wrap__swig_DirectorA2_upcall_F__SWIG_0(swig_p.SwigcptrA2, i) + return swig_r +} + +func DirectorA2F__SWIG_0(p A2, arg2 int) int { + var swig_r int + swig_r = _swig_wrap__swig_DirectorA2_upcall_F__SWIG_0(p.(*_swig_DirectorA2).SwigcptrA2, arg2) + return swig_r +} + +func Swig_DirectorA2_callback_f__SWIG_0(p *_swig_DirectorA2, arg2 int) (swig_result int) { + var swig_r int + swig_r = p.F__SWIG_0(arg2) + return swig_r +} + +type _swig_DirectorInterfaceA2F__SWIG_1 interface { + F__SWIG_1() int +} + +var _wrap__swig_DirectorA2_upcall_F__SWIG_1 unsafe.Pointer + +func _swig_wrap__swig_DirectorA2_upcall_F__SWIG_1(_swig_ptr SwigcptrA2) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) + _cgo_runtime_cgocall(_wrap__swig_DirectorA2_upcall_F__SWIG_1, _swig_p) + return +} + +func (swig_p *_swig_DirectorA2) F__SWIG_1() int { + if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceA2F__SWIG_1); swig_ok { + return swig_g.F__SWIG_1() + } + var swig_r int + swig_r = _swig_wrap__swig_DirectorA2_upcall_F__SWIG_1(swig_p.SwigcptrA2) + return swig_r +} + +func DirectorA2F__SWIG_1(p A2) int { + var swig_r int + swig_r = _swig_wrap__swig_DirectorA2_upcall_F__SWIG_1(p.(*_swig_DirectorA2).SwigcptrA2) + return swig_r +} + +func Swig_DirectorA2_callback_f__SWIG_1(p *_swig_DirectorA2) (swig_result int) { + var swig_r int + swig_r = p.F__SWIG_1() + return swig_r +} + +func (p _swig_DirectorA2) F(a ...interface{}) int { + argc := len(a) + if argc == 0 { + return p.F__SWIG_1() + } + if argc == 1 { + return p.F__SWIG_0(a[0].(int)) + } + panic("No match for overloaded function call") +} + +func DirectorA2F(p *_swig_DirectorA2, a ...interface{}) int { + argc := len(a) + if argc == 0 { + return DirectorA2F__SWIG_1(p) + } + if argc == 1 { + return DirectorA2F__SWIG_0(p, a[0].(int)) + } + panic("No match for overloaded function call") +} + +type SwigcptrA2 uintptr + +func (p SwigcptrA2) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrA2) SwigIsA2() { +} + +func (p SwigcptrA2) DirectorInterface() interface{} { + return nil +} + +var _wrap_new_A2__SWIG_0 unsafe.Pointer + +func _swig_wrap_new_A2__SWIG_0(base EnumDirectorFType) (_ SwigcptrA2) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_A2__SWIG_0, _swig_p) + return +} + +func NewA2__SWIG_0(arg1 EnumDirectorFType) (_swig_ret A2) { + return _swig_wrap_new_A2__SWIG_0(arg1) +} + +var _wrap_new_A2__SWIG_1 unsafe.Pointer + +func _swig_wrap_new_A2__SWIG_1() (base SwigcptrA2) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_A2__SWIG_1, _swig_p) + return +} + +func NewA2__SWIG_1() (_swig_ret A2) { + return _swig_wrap_new_A2__SWIG_1() +} + +func NewA2(a ...interface{}) A2 { + argc := len(a) + if argc == 0 { + return NewA2__SWIG_1() + } + if argc == 1 { + return NewA2__SWIG_0(a[0].(EnumDirectorFType)) + } + panic("No match for overloaded function call") +} + +var _wrap_delete_A2 unsafe.Pointer + +func _swig_wrap_delete_A2(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_A2, _swig_p) + return +} + +func DeleteA2(arg1 A2) { + _swig_wrap_delete_A2(arg1.Swigcptr()) +} + +var _wrap_A2_f__SWIG_0 unsafe.Pointer + +func _swig_wrap_A2_f__SWIG_0(base SwigcptrA2, _ int) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_A2_f__SWIG_0, _swig_p) + return +} + +func (arg1 SwigcptrA2) F__SWIG_0(arg2 int) (_swig_ret int) { + return _swig_wrap_A2_f__SWIG_0(arg1, arg2) +} + +var _wrap_A2_f__SWIG_1 unsafe.Pointer + +func _swig_wrap_A2_f__SWIG_1(base SwigcptrA2) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_A2_f__SWIG_1, _swig_p) + return +} + +func (arg1 SwigcptrA2) F__SWIG_1() (_swig_ret int) { + return _swig_wrap_A2_f__SWIG_1(arg1) +} + +func (p SwigcptrA2) F(a ...interface{}) int { + argc := len(a) + if argc == 0 { + return p.F__SWIG_1() + } + if argc == 1 { + return p.F__SWIG_0(a[0].(int)) + } + panic("No match for overloaded function call") +} + +type A2 interface { + Swigcptr() uintptr + SwigIsA2() + DirectorInterface() interface{} + F(a ...interface{}) int +} + +type _swig_DirectorB2 struct { + SwigcptrB2 + v interface{} +} + +func (p *_swig_DirectorB2) Swigcptr() uintptr { + return p.SwigcptrB2.Swigcptr() +} + +func (p *_swig_DirectorB2) SwigIsB2() { +} + +func (p *_swig_DirectorB2) DirectorInterface() interface{} { + return p.v +} + +var _wrap__swig_NewDirectorB2B2 unsafe.Pointer + +func _swig_NewDirectorB2B2(_swig_director *_swig_DirectorB2, _ EnumDirectorFType) (_swig_ret SwigcptrB2) { + _swig_p := uintptr(unsafe.Pointer(&_swig_director)) + _cgo_runtime_cgocall(_wrap__swig_NewDirectorB2B2, _swig_p) + return +} + +func NewDirectorB2(v interface{}, arg1 EnumDirectorFType) B2 { + p := &_swig_DirectorB2{0, v} + p.SwigcptrB2 = _swig_NewDirectorB2B2(p, arg1) + return p +} + +var _wrap_DeleteDirectorB2 unsafe.Pointer + +func _swig_wrap_DeleteDirectorB2(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_DeleteDirectorB2, _swig_p) + return +} + +func DeleteDirectorB2(arg1 B2) { + _swig_wrap_DeleteDirectorB2(arg1.Swigcptr()) +} + +func Swiggo_DeleteDirector_B2(p *_swig_DirectorB2) { + p.SwigcptrB2 = 0 +} + +type _swig_DirectorInterfaceB2F__SWIG_0 interface { + F__SWIG_0(int) int +} + +var _wrap__swig_DirectorB2_upcall_F__SWIG_0 unsafe.Pointer + +func _swig_wrap__swig_DirectorB2_upcall_F__SWIG_0(_swig_ptr SwigcptrB2, _ int) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) + _cgo_runtime_cgocall(_wrap__swig_DirectorB2_upcall_F__SWIG_0, _swig_p) + return +} + +func (swig_p *_swig_DirectorB2) F__SWIG_0(i int) int { + if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceB2F__SWIG_0); swig_ok { + return swig_g.F__SWIG_0(i) + } + var swig_r int + swig_r = _swig_wrap__swig_DirectorB2_upcall_F__SWIG_0(swig_p.SwigcptrB2, i) + return swig_r +} + +func DirectorB2F__SWIG_0(p B2, arg2 int) int { + var swig_r int + swig_r = _swig_wrap__swig_DirectorB2_upcall_F__SWIG_0(p.(*_swig_DirectorB2).SwigcptrB2, arg2) + return swig_r +} + +func Swig_DirectorB2_callback_f__SWIG_0(p *_swig_DirectorB2, arg2 int) (swig_result int) { + var swig_r int + swig_r = p.F__SWIG_0(arg2) + return swig_r +} + +type _swig_DirectorInterfaceB2F__SWIG_1 interface { + F__SWIG_1() int +} + +var _wrap__swig_DirectorB2_upcall_F__SWIG_1 unsafe.Pointer + +func _swig_wrap__swig_DirectorB2_upcall_F__SWIG_1(_swig_ptr SwigcptrB2) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) + _cgo_runtime_cgocall(_wrap__swig_DirectorB2_upcall_F__SWIG_1, _swig_p) + return +} + +func (swig_p *_swig_DirectorB2) F__SWIG_1() int { + if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceB2F__SWIG_1); swig_ok { + return swig_g.F__SWIG_1() + } + var swig_r int + swig_r = _swig_wrap__swig_DirectorB2_upcall_F__SWIG_1(swig_p.SwigcptrB2) + return swig_r +} + +func DirectorB2F__SWIG_1(p B2) int { + var swig_r int + swig_r = _swig_wrap__swig_DirectorB2_upcall_F__SWIG_1(p.(*_swig_DirectorB2).SwigcptrB2) + return swig_r +} + +func Swig_DirectorB2_callback_f__SWIG_1(p *_swig_DirectorB2) (swig_result int) { + var swig_r int + swig_r = p.F__SWIG_1() + return swig_r +} + +type SwigcptrB2 uintptr + +func (p SwigcptrB2) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrB2) SwigIsB2() { +} + +func (p SwigcptrB2) DirectorInterface() interface{} { + return nil +} + +var _wrap_new_B2 unsafe.Pointer + +func _swig_wrap_new_B2(base EnumDirectorFType) (_ SwigcptrB2) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_B2, _swig_p) + return +} + +func NewB2(arg1 EnumDirectorFType) (_swig_ret B2) { + return _swig_wrap_new_B2(arg1) +} + +var _wrap_delete_B2 unsafe.Pointer + +func _swig_wrap_delete_B2(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_B2, _swig_p) + return +} + +func DeleteB2(arg1 B2) { + _swig_wrap_delete_B2(arg1.Swigcptr()) +} + +var _wrap_B2_f__SWIG_0 unsafe.Pointer + +func _swig_wrap_B2_f__SWIG_0(base SwigcptrB2, _ int) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_B2_f__SWIG_0, _swig_p) + return +} + +func (_swig_base SwigcptrB2) F__SWIG_0(arg1 int) (_swig_ret int) { + return _swig_wrap_B2_f__SWIG_0(_swig_base, arg1) +} + +var _wrap_B2_f__SWIG_1 unsafe.Pointer + +func _swig_wrap_B2_f__SWIG_1(base SwigcptrB2) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_B2_f__SWIG_1, _swig_p) + return +} + +func (_swig_base SwigcptrB2) F__SWIG_1() (_swig_ret int) { + return _swig_wrap_B2_f__SWIG_1(_swig_base) +} + +func (p SwigcptrB2) F(a ...interface{}) int { + argc := len(a) + if argc == 0 { + return p.F__SWIG_1() + } + if argc == 1 { + return p.F__SWIG_0(a[0].(int)) + } + panic("No match for overloaded function call") +} + +func (p SwigcptrB2) SwigIsA2() { +} + +func (p SwigcptrB2) SwigGetA2() A2 { + return SwigcptrA2(p.Swigcptr()) +} + +type B2 interface { + Swigcptr() uintptr + SwigIsB2() + DirectorInterface() interface{} + F(a ...interface{}) int + SwigIsA2() + SwigGetA2() A2 +} + + +type SwigcptrSwigDirector_A uintptr +type SwigDirector_A interface { + Swigcptr() uintptr; +} +func (p SwigcptrSwigDirector_A) Swigcptr() uintptr { + return uintptr(p) +} + +type SwigcptrSwigDirector_B uintptr +type SwigDirector_B interface { + Swigcptr() uintptr; +} +func (p SwigcptrSwigDirector_B) Swigcptr() uintptr { + return uintptr(p) +} + +type SwigcptrSwigDirector_Foo uintptr +type SwigDirector_Foo interface { + Swigcptr() uintptr; +} +func (p SwigcptrSwigDirector_Foo) Swigcptr() uintptr { + return uintptr(p) +} + +type SwigcptrSwigDirector_B2 uintptr +type SwigDirector_B2 interface { + Swigcptr() uintptr; +} +func (p SwigcptrSwigDirector_B2) Swigcptr() uintptr { + return uintptr(p) +} + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + +type SwigcptrSwigDirector_A2 uintptr +type SwigDirector_A2 interface { + Swigcptr() uintptr; +} +func (p SwigcptrSwigDirector_A2) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/director_enum_runme b/Examples/test-suite/go/director_enum_runme new file mode 100755 index 000000000..ad202226f Binary files /dev/null and b/Examples/test-suite/go/director_enum_runme differ diff --git a/Examples/test-suite/go/director_enum_wrap.h b/Examples/test-suite/go/director_enum_wrap.h new file mode 100644 index 000000000..8173ee1a7 --- /dev/null +++ b/Examples/test-suite/go/director_enum_wrap.h @@ -0,0 +1,114 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../director_enum.i + +#ifndef SWIG_director_enum_WRAP_H_ +#define SWIG_director_enum_WRAP_H_ + +class SwigDirector_Foo : public EnumDirector::Foo +{ + public: + SwigDirector_Foo(void *swig_p); + virtual ~SwigDirector_Foo(); + EnumDirector::Hello _swig_upcall_say_hi__SWIG_0(EnumDirector::Hello h) { + return EnumDirector::Foo::say_hi(h); + } + virtual EnumDirector::Hello say_hi(EnumDirector::Hello h); + EnumDirector::Hello _swig_upcall_say_hello(EnumDirector::Hello arg0) { + return EnumDirector::Foo::say_hello(arg0); + } + virtual EnumDirector::Hello say_hello(EnumDirector::Hello arg0); + EnumDirector::Hello _swig_upcall_say_hi__SWIG_1(EnumDirector::A *a) { + return EnumDirector::Foo::say_hi(a); + } + virtual EnumDirector::Hello say_hi(EnumDirector::A *a); + EnumDirector::Foo::Bye _swig_upcall_say_bye(EnumDirector::Foo::Bye b) { + return EnumDirector::Foo::say_bye(b); + } + virtual EnumDirector::Foo::Bye say_bye(EnumDirector::Foo::Bye b); + EnumDirector::Hello const &_swig_upcall_say_hi_ref(EnumDirector::Hello const &h) { + return EnumDirector::Foo::say_hi_ref(h); + } + virtual EnumDirector::Hello const &say_hi_ref(EnumDirector::Hello const &h); + private: + void *go_val; +}; + +class SwigDirector_A : public EnumDirector::A +{ + public: + SwigDirector_A(void *swig_p, double const a, double const b, EnumDirector::FType const c); + virtual ~SwigDirector_A(); + int _swig_upcall_f__SWIG_0(int i) { + return EnumDirector::A::f(i); + } + virtual int f(int i); + int _swig_upcall_f__SWIG_1() { + return EnumDirector::A::f(); + } + virtual int f(); + private: + void *go_val; +}; + +class SwigDirector_B : public EnumDirector::B +{ + public: + SwigDirector_B(void *swig_p, double const a, double const b, EnumDirector::FType const c); + virtual ~SwigDirector_B(); + int _swig_upcall_f__SWIG_0(int i) { + return EnumDirector::A::f(i); + } + virtual int f(int i); + int _swig_upcall_f__SWIG_1() { + return EnumDirector::A::f(); + } + virtual int f(); + private: + void *go_val; +}; + +class SwigDirector_A2 : public EnumDirector::A2 +{ + public: + SwigDirector_A2(void *swig_p, EnumDirector::FType const c); + SwigDirector_A2(void *swig_p); + virtual ~SwigDirector_A2(); + int _swig_upcall_f__SWIG_0(int i) { + return EnumDirector::A2::f(i); + } + virtual int f(int i); + int _swig_upcall_f__SWIG_1() { + return EnumDirector::A2::f(); + } + virtual int f(); + private: + void *go_val; +}; + +class SwigDirector_B2 : public EnumDirector::B2 +{ + public: + SwigDirector_B2(void *swig_p, EnumDirector::FType const c); + virtual ~SwigDirector_B2(); + int _swig_upcall_f__SWIG_0(int i) { + return EnumDirector::A2::f(i); + } + virtual int f(int i); + int _swig_upcall_f__SWIG_1() { + return EnumDirector::A2::f(); + } + virtual int f(); + private: + void *go_val; +}; + +#endif diff --git a/Examples/test-suite/go/director_exception.go b/Examples/test-suite/go/director_exception.go new file mode 100644 index 000000000..50f6c8885 --- /dev/null +++ b/Examples/test-suite/go/director_exception.go @@ -0,0 +1,1066 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../director_exception.i + +package director_exception + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type _swig_DirectorFoo struct { + SwigcptrFoo + v interface{} +} + +func (p *_swig_DirectorFoo) Swigcptr() uintptr { + return p.SwigcptrFoo.Swigcptr() +} + +func (p *_swig_DirectorFoo) SwigIsFoo() { +} + +func (p *_swig_DirectorFoo) DirectorInterface() interface{} { + return p.v +} + +var _wrap__swig_NewDirectorFooFoo unsafe.Pointer + +func _swig_NewDirectorFooFoo(_swig_director *_swig_DirectorFoo) (_swig_ret SwigcptrFoo) { + _swig_p := uintptr(unsafe.Pointer(&_swig_director)) + _cgo_runtime_cgocall(_wrap__swig_NewDirectorFooFoo, _swig_p) + return +} + +func NewDirectorFoo(v interface{}) Foo { + p := &_swig_DirectorFoo{0, v} + p.SwigcptrFoo = _swig_NewDirectorFooFoo(p) + return p +} + +var _wrap_DeleteDirectorFoo unsafe.Pointer + +func _swig_wrap_DeleteDirectorFoo(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_DeleteDirectorFoo, _swig_p) + return +} + +func DeleteDirectorFoo(arg1 Foo) { + _swig_wrap_DeleteDirectorFoo(arg1.Swigcptr()) +} + +func Swiggo_DeleteDirector_Foo(p *_swig_DirectorFoo) { + p.SwigcptrFoo = 0 +} + +type _swig_DirectorInterfaceFooPing interface { + Ping() string +} + +var _wrap__swig_DirectorFoo_upcall_Ping unsafe.Pointer + +func _swig_wrap__swig_DirectorFoo_upcall_Ping(_swig_ptr SwigcptrFoo) (_swig_ret string) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) + _cgo_runtime_cgocall(_wrap__swig_DirectorFoo_upcall_Ping, _swig_p) + return +} + +func (swig_p *_swig_DirectorFoo) Ping() string { + if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceFooPing); swig_ok { + return swig_g.Ping() + } + var swig_r string + swig_r = _swig_wrap__swig_DirectorFoo_upcall_Ping(swig_p.SwigcptrFoo) + return swig_r +} + +func DirectorFooPing(p Foo) string { + var swig_r string + swig_r = _swig_wrap__swig_DirectorFoo_upcall_Ping(p.(*_swig_DirectorFoo).SwigcptrFoo) + return swig_r +} + +func Swig_DirectorFoo_callback_ping(p *_swig_DirectorFoo) (swig_result string) { + var swig_r string + swig_r = p.Ping() + return swig_r +} + +type _swig_DirectorInterfaceFooPong__SWIG_0 interface { + Pong__SWIG_0(int) string +} + +var _wrap__swig_DirectorFoo_upcall_Pong__SWIG_0 unsafe.Pointer + +func _swig_wrap__swig_DirectorFoo_upcall_Pong__SWIG_0(_swig_ptr SwigcptrFoo, _ int) (_swig_ret string) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) + _cgo_runtime_cgocall(_wrap__swig_DirectorFoo_upcall_Pong__SWIG_0, _swig_p) + return +} + +func (swig_p *_swig_DirectorFoo) Pong__SWIG_0(val int) string { + if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceFooPong__SWIG_0); swig_ok { + return swig_g.Pong__SWIG_0(val) + } + var swig_r string + swig_r = _swig_wrap__swig_DirectorFoo_upcall_Pong__SWIG_0(swig_p.SwigcptrFoo, val) + return swig_r +} + +func DirectorFooPong__SWIG_0(p Foo, arg2 int) string { + var swig_r string + swig_r = _swig_wrap__swig_DirectorFoo_upcall_Pong__SWIG_0(p.(*_swig_DirectorFoo).SwigcptrFoo, arg2) + return swig_r +} + +func Swig_DirectorFoo_callback_pong__SWIG_0(p *_swig_DirectorFoo, arg2 int) (swig_result string) { + var swig_r string + swig_r = p.Pong__SWIG_0(arg2) + return swig_r +} + +type _swig_DirectorInterfaceFooPong__SWIG_1 interface { + Pong__SWIG_1() string +} + +var _wrap__swig_DirectorFoo_upcall_Pong__SWIG_1 unsafe.Pointer + +func _swig_wrap__swig_DirectorFoo_upcall_Pong__SWIG_1(_swig_ptr SwigcptrFoo) (_swig_ret string) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) + _cgo_runtime_cgocall(_wrap__swig_DirectorFoo_upcall_Pong__SWIG_1, _swig_p) + return +} + +func (swig_p *_swig_DirectorFoo) Pong__SWIG_1() string { + if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceFooPong__SWIG_1); swig_ok { + return swig_g.Pong__SWIG_1() + } + var swig_r string + swig_r = _swig_wrap__swig_DirectorFoo_upcall_Pong__SWIG_1(swig_p.SwigcptrFoo) + return swig_r +} + +func DirectorFooPong__SWIG_1(p Foo) string { + var swig_r string + swig_r = _swig_wrap__swig_DirectorFoo_upcall_Pong__SWIG_1(p.(*_swig_DirectorFoo).SwigcptrFoo) + return swig_r +} + +func Swig_DirectorFoo_callback_pong__SWIG_1(p *_swig_DirectorFoo) (swig_result string) { + var swig_r string + swig_r = p.Pong__SWIG_1() + return swig_r +} + +func (p _swig_DirectorFoo) Pong(a ...interface{}) string { + argc := len(a) + if argc == 0 { + return p.Pong__SWIG_1() + } + if argc == 1 { + return p.Pong__SWIG_0(a[0].(int)) + } + panic("No match for overloaded function call") +} + +func DirectorFooPong(p *_swig_DirectorFoo, a ...interface{}) string { + argc := len(a) + if argc == 0 { + return DirectorFooPong__SWIG_1(p) + } + if argc == 1 { + return DirectorFooPong__SWIG_0(p, a[0].(int)) + } + panic("No match for overloaded function call") +} + +type SwigcptrFoo uintptr + +func (p SwigcptrFoo) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrFoo) SwigIsFoo() { +} + +func (p SwigcptrFoo) DirectorInterface() interface{} { + return nil +} + +var _wrap_delete_Foo unsafe.Pointer + +func _swig_wrap_delete_Foo(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Foo, _swig_p) + return +} + +func DeleteFoo(arg1 Foo) { + _swig_wrap_delete_Foo(arg1.Swigcptr()) +} + +var _wrap_Foo_ping unsafe.Pointer + +func _swig_wrap_Foo_ping(base SwigcptrFoo) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_ping, _swig_p) + return +} + +func (arg1 SwigcptrFoo) Ping() (_swig_ret string) { + return _swig_wrap_Foo_ping(arg1) +} + +var _wrap_Foo_pong__SWIG_0 unsafe.Pointer + +func _swig_wrap_Foo_pong__SWIG_0(base SwigcptrFoo, _ int) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_pong__SWIG_0, _swig_p) + return +} + +func (arg1 SwigcptrFoo) Pong__SWIG_0(arg2 int) (_swig_ret string) { + return _swig_wrap_Foo_pong__SWIG_0(arg1, arg2) +} + +var _wrap_Foo_pong__SWIG_1 unsafe.Pointer + +func _swig_wrap_Foo_pong__SWIG_1(base SwigcptrFoo) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_pong__SWIG_1, _swig_p) + return +} + +func (arg1 SwigcptrFoo) Pong__SWIG_1() (_swig_ret string) { + return _swig_wrap_Foo_pong__SWIG_1(arg1) +} + +func (p SwigcptrFoo) Pong(a ...interface{}) string { + argc := len(a) + if argc == 0 { + return p.Pong__SWIG_1() + } + if argc == 1 { + return p.Pong__SWIG_0(a[0].(int)) + } + panic("No match for overloaded function call") +} + +var _wrap_new_Foo unsafe.Pointer + +func _swig_wrap_new_Foo() (base SwigcptrFoo) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Foo, _swig_p) + return +} + +func NewFoo() (_swig_ret Foo) { + return _swig_wrap_new_Foo() +} + +type Foo interface { + Swigcptr() uintptr + SwigIsFoo() + DirectorInterface() interface{} + Ping() (_swig_ret string) + Pong(a ...interface{}) string +} + +var _wrap_launder unsafe.Pointer + +func _swig_wrap_launder(base uintptr) (_ SwigcptrFoo) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_launder, _swig_p) + return +} + +func Launder(arg1 Foo) (_swig_ret Foo) { + return _swig_wrap_launder(arg1.Swigcptr()) +} + +type SwigcptrException1 uintptr + +func (p SwigcptrException1) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrException1) SwigIsException1() { +} + +var _wrap_new_Exception1 unsafe.Pointer + +func _swig_wrap_new_Exception1() (base SwigcptrException1) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Exception1, _swig_p) + return +} + +func NewException1() (_swig_ret Exception1) { + return _swig_wrap_new_Exception1() +} + +var _wrap_delete_Exception1 unsafe.Pointer + +func _swig_wrap_delete_Exception1(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Exception1, _swig_p) + return +} + +func DeleteException1(arg1 Exception1) { + _swig_wrap_delete_Exception1(arg1.Swigcptr()) +} + +type Exception1 interface { + Swigcptr() uintptr + SwigIsException1() +} + +type SwigcptrException2 uintptr + +func (p SwigcptrException2) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrException2) SwigIsException2() { +} + +var _wrap_new_Exception2 unsafe.Pointer + +func _swig_wrap_new_Exception2() (base SwigcptrException2) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Exception2, _swig_p) + return +} + +func NewException2() (_swig_ret Exception2) { + return _swig_wrap_new_Exception2() +} + +var _wrap_delete_Exception2 unsafe.Pointer + +func _swig_wrap_delete_Exception2(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Exception2, _swig_p) + return +} + +func DeleteException2(arg1 Exception2) { + _swig_wrap_delete_Exception2(arg1.Swigcptr()) +} + +type Exception2 interface { + Swigcptr() uintptr + SwigIsException2() +} + +type SwigcptrBase uintptr + +func (p SwigcptrBase) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrBase) SwigIsBase() { +} + +var _wrap_delete_Base unsafe.Pointer + +func _swig_wrap_delete_Base(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Base, _swig_p) + return +} + +func DeleteBase(arg1 Base) { + _swig_wrap_delete_Base(arg1.Swigcptr()) +} + +var _wrap_new_Base unsafe.Pointer + +func _swig_wrap_new_Base() (base SwigcptrBase) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Base, _swig_p) + return +} + +func NewBase() (_swig_ret Base) { + return _swig_wrap_new_Base() +} + +type Base interface { + Swigcptr() uintptr + SwigIsBase() +} + +type _swig_DirectorBar struct { + SwigcptrBar + v interface{} +} + +func (p *_swig_DirectorBar) Swigcptr() uintptr { + return p.SwigcptrBar.Swigcptr() +} + +func (p *_swig_DirectorBar) SwigIsBar() { +} + +func (p *_swig_DirectorBar) DirectorInterface() interface{} { + return p.v +} + +var _wrap__swig_NewDirectorBarBar unsafe.Pointer + +func _swig_NewDirectorBarBar(_swig_director *_swig_DirectorBar) (_swig_ret SwigcptrBar) { + _swig_p := uintptr(unsafe.Pointer(&_swig_director)) + _cgo_runtime_cgocall(_wrap__swig_NewDirectorBarBar, _swig_p) + return +} + +func NewDirectorBar(v interface{}) Bar { + p := &_swig_DirectorBar{0, v} + p.SwigcptrBar = _swig_NewDirectorBarBar(p) + return p +} + +var _wrap_DeleteDirectorBar unsafe.Pointer + +func _swig_wrap_DeleteDirectorBar(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_DeleteDirectorBar, _swig_p) + return +} + +func DeleteDirectorBar(arg1 Bar) { + _swig_wrap_DeleteDirectorBar(arg1.Swigcptr()) +} + +func Swiggo_DeleteDirector_Bar(p *_swig_DirectorBar) { + p.SwigcptrBar = 0 +} + +type _swig_DirectorInterfaceBarPing interface { + Ping() string +} + +var _wrap__swig_DirectorBar_upcall_Ping unsafe.Pointer + +func _swig_wrap__swig_DirectorBar_upcall_Ping(_swig_ptr SwigcptrBar) (_swig_ret string) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) + _cgo_runtime_cgocall(_wrap__swig_DirectorBar_upcall_Ping, _swig_p) + return +} + +func (swig_p *_swig_DirectorBar) Ping() string { + if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceBarPing); swig_ok { + return swig_g.Ping() + } + var swig_r string + swig_r = _swig_wrap__swig_DirectorBar_upcall_Ping(swig_p.SwigcptrBar) + return swig_r +} + +func DirectorBarPing(p Bar) string { + var swig_r string + swig_r = _swig_wrap__swig_DirectorBar_upcall_Ping(p.(*_swig_DirectorBar).SwigcptrBar) + return swig_r +} + +func Swig_DirectorBar_callback_ping(p *_swig_DirectorBar) (swig_result string) { + var swig_r string + swig_r = p.Ping() + return swig_r +} + +type _swig_DirectorInterfaceBarPong interface { + Pong() string +} + +var _wrap__swig_DirectorBar_upcall_Pong unsafe.Pointer + +func _swig_wrap__swig_DirectorBar_upcall_Pong(_swig_ptr SwigcptrBar) (_swig_ret string) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) + _cgo_runtime_cgocall(_wrap__swig_DirectorBar_upcall_Pong, _swig_p) + return +} + +func (swig_p *_swig_DirectorBar) Pong() string { + if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceBarPong); swig_ok { + return swig_g.Pong() + } + var swig_r string + swig_r = _swig_wrap__swig_DirectorBar_upcall_Pong(swig_p.SwigcptrBar) + return swig_r +} + +func DirectorBarPong(p Bar) string { + var swig_r string + swig_r = _swig_wrap__swig_DirectorBar_upcall_Pong(p.(*_swig_DirectorBar).SwigcptrBar) + return swig_r +} + +func Swig_DirectorBar_callback_pong(p *_swig_DirectorBar) (swig_result string) { + var swig_r string + swig_r = p.Pong() + return swig_r +} + +type _swig_DirectorInterfaceBarPang interface { + Pang() string +} + +var _wrap__swig_DirectorBar_upcall_Pang unsafe.Pointer + +func _swig_wrap__swig_DirectorBar_upcall_Pang(_swig_ptr SwigcptrBar) (_swig_ret string) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) + _cgo_runtime_cgocall(_wrap__swig_DirectorBar_upcall_Pang, _swig_p) + return +} + +func (swig_p *_swig_DirectorBar) Pang() string { + if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceBarPang); swig_ok { + return swig_g.Pang() + } + var swig_r string + swig_r = _swig_wrap__swig_DirectorBar_upcall_Pang(swig_p.SwigcptrBar) + return swig_r +} + +func DirectorBarPang(p Bar) string { + var swig_r string + swig_r = _swig_wrap__swig_DirectorBar_upcall_Pang(p.(*_swig_DirectorBar).SwigcptrBar) + return swig_r +} + +func Swig_DirectorBar_callback_pang(p *_swig_DirectorBar) (swig_result string) { + var swig_r string + swig_r = p.Pang() + return swig_r +} + +type SwigcptrBar uintptr + +func (p SwigcptrBar) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrBar) SwigIsBar() { +} + +func (p SwigcptrBar) DirectorInterface() interface{} { + return nil +} + +var _wrap_Bar_ping unsafe.Pointer + +func _swig_wrap_Bar_ping(base SwigcptrBar) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Bar_ping, _swig_p) + return +} + +func (arg1 SwigcptrBar) Ping() (_swig_ret string) { + return _swig_wrap_Bar_ping(arg1) +} + +var _wrap_Bar_pong unsafe.Pointer + +func _swig_wrap_Bar_pong(base SwigcptrBar) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Bar_pong, _swig_p) + return +} + +func (arg1 SwigcptrBar) Pong() (_swig_ret string) { + return _swig_wrap_Bar_pong(arg1) +} + +var _wrap_Bar_pang unsafe.Pointer + +func _swig_wrap_Bar_pang(base SwigcptrBar) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Bar_pang, _swig_p) + return +} + +func (arg1 SwigcptrBar) Pang() (_swig_ret string) { + return _swig_wrap_Bar_pang(arg1) +} + +var _wrap_new_Bar unsafe.Pointer + +func _swig_wrap_new_Bar() (base SwigcptrBar) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Bar, _swig_p) + return +} + +func NewBar() (_swig_ret Bar) { + return _swig_wrap_new_Bar() +} + +var _wrap_delete_Bar unsafe.Pointer + +func _swig_wrap_delete_Bar(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Bar, _swig_p) + return +} + +func DeleteBar(arg1 Bar) { + _swig_wrap_delete_Bar(arg1.Swigcptr()) +} + +func (p SwigcptrBar) SwigIsBase() { +} + +func (p SwigcptrBar) SwigGetBase() Base { + return SwigcptrBase(p.Swigcptr()) +} + +type Bar interface { + Swigcptr() uintptr + SwigIsBar() + DirectorInterface() interface{} + Ping() (_swig_ret string) + Pong() (_swig_ret string) + Pang() (_swig_ret string) + SwigIsBase() + SwigGetBase() Base +} + +type _swig_DirectorReturnAllTypes struct { + SwigcptrReturnAllTypes + v interface{} +} + +func (p *_swig_DirectorReturnAllTypes) Swigcptr() uintptr { + return p.SwigcptrReturnAllTypes.Swigcptr() +} + +func (p *_swig_DirectorReturnAllTypes) SwigIsReturnAllTypes() { +} + +func (p *_swig_DirectorReturnAllTypes) DirectorInterface() interface{} { + return p.v +} + +var _wrap__swig_NewDirectorReturnAllTypesReturnAllTypes unsafe.Pointer + +func _swig_NewDirectorReturnAllTypesReturnAllTypes(_swig_director *_swig_DirectorReturnAllTypes) (_swig_ret SwigcptrReturnAllTypes) { + _swig_p := uintptr(unsafe.Pointer(&_swig_director)) + _cgo_runtime_cgocall(_wrap__swig_NewDirectorReturnAllTypesReturnAllTypes, _swig_p) + return +} + +func NewDirectorReturnAllTypes(v interface{}) ReturnAllTypes { + p := &_swig_DirectorReturnAllTypes{0, v} + p.SwigcptrReturnAllTypes = _swig_NewDirectorReturnAllTypesReturnAllTypes(p) + return p +} + +type _swig_DirectorInterfaceReturnAllTypesReturn_int interface { + Return_int() int +} + +var _wrap__swig_DirectorReturnAllTypes_upcall_Return_int unsafe.Pointer + +func _swig_wrap__swig_DirectorReturnAllTypes_upcall_Return_int(_swig_ptr SwigcptrReturnAllTypes) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) + _cgo_runtime_cgocall(_wrap__swig_DirectorReturnAllTypes_upcall_Return_int, _swig_p) + return +} + +func (swig_p *_swig_DirectorReturnAllTypes) Return_int() int { + if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceReturnAllTypesReturn_int); swig_ok { + return swig_g.Return_int() + } + var swig_r int + swig_r = _swig_wrap__swig_DirectorReturnAllTypes_upcall_Return_int(swig_p.SwigcptrReturnAllTypes) + return swig_r +} + +func DirectorReturnAllTypesReturn_int(p ReturnAllTypes) int { + var swig_r int + swig_r = _swig_wrap__swig_DirectorReturnAllTypes_upcall_Return_int(p.(*_swig_DirectorReturnAllTypes).SwigcptrReturnAllTypes) + return swig_r +} + +func Swig_DirectorReturnAllTypes_callback_return_int(p *_swig_DirectorReturnAllTypes) (swig_result int) { + var swig_r int + swig_r = p.Return_int() + return swig_r +} + +type _swig_DirectorInterfaceReturnAllTypesReturn_double interface { + Return_double() float64 +} + +var _wrap__swig_DirectorReturnAllTypes_upcall_Return_double unsafe.Pointer + +func _swig_wrap__swig_DirectorReturnAllTypes_upcall_Return_double(_swig_ptr SwigcptrReturnAllTypes) (_swig_ret float64) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) + _cgo_runtime_cgocall(_wrap__swig_DirectorReturnAllTypes_upcall_Return_double, _swig_p) + return +} + +func (swig_p *_swig_DirectorReturnAllTypes) Return_double() float64 { + if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceReturnAllTypesReturn_double); swig_ok { + return swig_g.Return_double() + } + var swig_r float64 + swig_r = _swig_wrap__swig_DirectorReturnAllTypes_upcall_Return_double(swig_p.SwigcptrReturnAllTypes) + return swig_r +} + +func DirectorReturnAllTypesReturn_double(p ReturnAllTypes) float64 { + var swig_r float64 + swig_r = _swig_wrap__swig_DirectorReturnAllTypes_upcall_Return_double(p.(*_swig_DirectorReturnAllTypes).SwigcptrReturnAllTypes) + return swig_r +} + +func Swig_DirectorReturnAllTypes_callback_return_double(p *_swig_DirectorReturnAllTypes) (swig_result float64) { + var swig_r float64 + swig_r = p.Return_double() + return swig_r +} + +type _swig_DirectorInterfaceReturnAllTypesReturn_const_char_star interface { + Return_const_char_star() string +} + +var _wrap__swig_DirectorReturnAllTypes_upcall_Return_const_char_star unsafe.Pointer + +func _swig_wrap__swig_DirectorReturnAllTypes_upcall_Return_const_char_star(_swig_ptr SwigcptrReturnAllTypes) (_swig_ret string) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) + _cgo_runtime_cgocall(_wrap__swig_DirectorReturnAllTypes_upcall_Return_const_char_star, _swig_p) + return +} + +func (swig_p *_swig_DirectorReturnAllTypes) Return_const_char_star() string { + if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceReturnAllTypesReturn_const_char_star); swig_ok { + return swig_g.Return_const_char_star() + } + var swig_r string + swig_r = _swig_wrap__swig_DirectorReturnAllTypes_upcall_Return_const_char_star(swig_p.SwigcptrReturnAllTypes) + return swig_r +} + +func DirectorReturnAllTypesReturn_const_char_star(p ReturnAllTypes) string { + var swig_r string + swig_r = _swig_wrap__swig_DirectorReturnAllTypes_upcall_Return_const_char_star(p.(*_swig_DirectorReturnAllTypes).SwigcptrReturnAllTypes) + return swig_r +} + +func Swig_DirectorReturnAllTypes_callback_return_const_char_star(p *_swig_DirectorReturnAllTypes) (swig_result string) { + var swig_r string + swig_r = p.Return_const_char_star() + return swig_r +} + +type _swig_DirectorInterfaceReturnAllTypesReturn_std_string interface { + Return_std_string() string +} + +var _wrap__swig_DirectorReturnAllTypes_upcall_Return_std_string unsafe.Pointer + +func _swig_wrap__swig_DirectorReturnAllTypes_upcall_Return_std_string(_swig_ptr SwigcptrReturnAllTypes) (_swig_ret string) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) + _cgo_runtime_cgocall(_wrap__swig_DirectorReturnAllTypes_upcall_Return_std_string, _swig_p) + return +} + +func (swig_p *_swig_DirectorReturnAllTypes) Return_std_string() string { + if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceReturnAllTypesReturn_std_string); swig_ok { + return swig_g.Return_std_string() + } + var swig_r string + swig_r = _swig_wrap__swig_DirectorReturnAllTypes_upcall_Return_std_string(swig_p.SwigcptrReturnAllTypes) + return swig_r +} + +func DirectorReturnAllTypesReturn_std_string(p ReturnAllTypes) string { + var swig_r string + swig_r = _swig_wrap__swig_DirectorReturnAllTypes_upcall_Return_std_string(p.(*_swig_DirectorReturnAllTypes).SwigcptrReturnAllTypes) + return swig_r +} + +func Swig_DirectorReturnAllTypes_callback_return_std_string(p *_swig_DirectorReturnAllTypes) (swig_result string) { + var swig_r string + swig_r = p.Return_std_string() + return swig_r +} + +type _swig_DirectorInterfaceReturnAllTypesReturn_Bar interface { + Return_Bar() Bar +} + +var _wrap__swig_DirectorReturnAllTypes_upcall_Return_Bar unsafe.Pointer + +func _swig_wrap__swig_DirectorReturnAllTypes_upcall_Return_Bar(_swig_ptr SwigcptrReturnAllTypes) (_swig_ret SwigcptrBar) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) + _cgo_runtime_cgocall(_wrap__swig_DirectorReturnAllTypes_upcall_Return_Bar, _swig_p) + return +} + +func (swig_p *_swig_DirectorReturnAllTypes) Return_Bar() Bar { + if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceReturnAllTypesReturn_Bar); swig_ok { + return swig_g.Return_Bar() + } + var swig_r Bar + swig_r = _swig_wrap__swig_DirectorReturnAllTypes_upcall_Return_Bar(swig_p.SwigcptrReturnAllTypes) + return swig_r +} + +func DirectorReturnAllTypesReturn_Bar(p ReturnAllTypes) Bar { + var swig_r Bar + swig_r = _swig_wrap__swig_DirectorReturnAllTypes_upcall_Return_Bar(p.(*_swig_DirectorReturnAllTypes).SwigcptrReturnAllTypes) + return swig_r +} + +func Swig_DirectorReturnAllTypes_callback_return_Bar(p *_swig_DirectorReturnAllTypes) (swig_result SwigcptrBar) { + var swig_r SwigcptrBar + swig_r = SwigcptrBar(p.Return_Bar().Swigcptr()) + return swig_r +} + +var _wrap_DeleteDirectorReturnAllTypes unsafe.Pointer + +func _swig_wrap_DeleteDirectorReturnAllTypes(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_DeleteDirectorReturnAllTypes, _swig_p) + return +} + +func DeleteDirectorReturnAllTypes(arg1 ReturnAllTypes) { + _swig_wrap_DeleteDirectorReturnAllTypes(arg1.Swigcptr()) +} + +func Swiggo_DeleteDirector_ReturnAllTypes(p *_swig_DirectorReturnAllTypes) { + p.SwigcptrReturnAllTypes = 0 +} + +type SwigcptrReturnAllTypes uintptr + +func (p SwigcptrReturnAllTypes) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrReturnAllTypes) SwigIsReturnAllTypes() { +} + +func (p SwigcptrReturnAllTypes) DirectorInterface() interface{} { + return nil +} + +var _wrap_ReturnAllTypes_call_int unsafe.Pointer + +func _swig_wrap_ReturnAllTypes_call_int(base SwigcptrReturnAllTypes) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_ReturnAllTypes_call_int, _swig_p) + return +} + +func (arg1 SwigcptrReturnAllTypes) Call_int() (_swig_ret int) { + return _swig_wrap_ReturnAllTypes_call_int(arg1) +} + +var _wrap_ReturnAllTypes_call_double unsafe.Pointer + +func _swig_wrap_ReturnAllTypes_call_double(base SwigcptrReturnAllTypes) (_ float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_ReturnAllTypes_call_double, _swig_p) + return +} + +func (arg1 SwigcptrReturnAllTypes) Call_double() (_swig_ret float64) { + return _swig_wrap_ReturnAllTypes_call_double(arg1) +} + +var _wrap_ReturnAllTypes_call_const_char_star unsafe.Pointer + +func _swig_wrap_ReturnAllTypes_call_const_char_star(base SwigcptrReturnAllTypes) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_ReturnAllTypes_call_const_char_star, _swig_p) + return +} + +func (arg1 SwigcptrReturnAllTypes) Call_const_char_star() (_swig_ret string) { + return _swig_wrap_ReturnAllTypes_call_const_char_star(arg1) +} + +var _wrap_ReturnAllTypes_call_std_string unsafe.Pointer + +func _swig_wrap_ReturnAllTypes_call_std_string(base SwigcptrReturnAllTypes) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_ReturnAllTypes_call_std_string, _swig_p) + return +} + +func (arg1 SwigcptrReturnAllTypes) Call_std_string() (_swig_ret string) { + return _swig_wrap_ReturnAllTypes_call_std_string(arg1) +} + +var _wrap_ReturnAllTypes_call_Bar unsafe.Pointer + +func _swig_wrap_ReturnAllTypes_call_Bar(base SwigcptrReturnAllTypes) (_ SwigcptrBar) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_ReturnAllTypes_call_Bar, _swig_p) + return +} + +func (arg1 SwigcptrReturnAllTypes) Call_Bar() (_swig_ret Bar) { + return _swig_wrap_ReturnAllTypes_call_Bar(arg1) +} + +var _wrap_ReturnAllTypes_return_int unsafe.Pointer + +func _swig_wrap_ReturnAllTypes_return_int(base SwigcptrReturnAllTypes) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_ReturnAllTypes_return_int, _swig_p) + return +} + +func (arg1 SwigcptrReturnAllTypes) Return_int() (_swig_ret int) { + return _swig_wrap_ReturnAllTypes_return_int(arg1) +} + +var _wrap_ReturnAllTypes_return_double unsafe.Pointer + +func _swig_wrap_ReturnAllTypes_return_double(base SwigcptrReturnAllTypes) (_ float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_ReturnAllTypes_return_double, _swig_p) + return +} + +func (arg1 SwigcptrReturnAllTypes) Return_double() (_swig_ret float64) { + return _swig_wrap_ReturnAllTypes_return_double(arg1) +} + +var _wrap_ReturnAllTypes_return_const_char_star unsafe.Pointer + +func _swig_wrap_ReturnAllTypes_return_const_char_star(base SwigcptrReturnAllTypes) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_ReturnAllTypes_return_const_char_star, _swig_p) + return +} + +func (arg1 SwigcptrReturnAllTypes) Return_const_char_star() (_swig_ret string) { + return _swig_wrap_ReturnAllTypes_return_const_char_star(arg1) +} + +var _wrap_ReturnAllTypes_return_std_string unsafe.Pointer + +func _swig_wrap_ReturnAllTypes_return_std_string(base SwigcptrReturnAllTypes) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_ReturnAllTypes_return_std_string, _swig_p) + return +} + +func (arg1 SwigcptrReturnAllTypes) Return_std_string() (_swig_ret string) { + return _swig_wrap_ReturnAllTypes_return_std_string(arg1) +} + +var _wrap_ReturnAllTypes_return_Bar unsafe.Pointer + +func _swig_wrap_ReturnAllTypes_return_Bar(base SwigcptrReturnAllTypes) (_ SwigcptrBar) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_ReturnAllTypes_return_Bar, _swig_p) + return +} + +func (arg1 SwigcptrReturnAllTypes) Return_Bar() (_swig_ret Bar) { + return _swig_wrap_ReturnAllTypes_return_Bar(arg1) +} + +var _wrap_delete_ReturnAllTypes unsafe.Pointer + +func _swig_wrap_delete_ReturnAllTypes(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_ReturnAllTypes, _swig_p) + return +} + +func DeleteReturnAllTypes(arg1 ReturnAllTypes) { + _swig_wrap_delete_ReturnAllTypes(arg1.Swigcptr()) +} + +var _wrap_new_ReturnAllTypes unsafe.Pointer + +func _swig_wrap_new_ReturnAllTypes() (base SwigcptrReturnAllTypes) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_ReturnAllTypes, _swig_p) + return +} + +func NewReturnAllTypes() (_swig_ret ReturnAllTypes) { + return _swig_wrap_new_ReturnAllTypes() +} + +type ReturnAllTypes interface { + Swigcptr() uintptr + SwigIsReturnAllTypes() + DirectorInterface() interface{} + Call_int() (_swig_ret int) + Call_double() (_swig_ret float64) + Call_const_char_star() (_swig_ret string) + Call_std_string() (_swig_ret string) + Call_Bar() (_swig_ret Bar) + Return_int() (_swig_ret int) + Return_double() (_swig_ret float64) + Return_const_char_star() (_swig_ret string) + Return_std_string() (_swig_ret string) + Return_Bar() (_swig_ret Bar) +} + + +type SwigcptrSwigDirector_ReturnAllTypes uintptr +type SwigDirector_ReturnAllTypes interface { + Swigcptr() uintptr; +} +func (p SwigcptrSwigDirector_ReturnAllTypes) Swigcptr() uintptr { + return uintptr(p) +} + +type SwigcptrSwigDirector_Foo uintptr +type SwigDirector_Foo interface { + Swigcptr() uintptr; +} +func (p SwigcptrSwigDirector_Foo) Swigcptr() uintptr { + return uintptr(p) +} + +type SwigcptrSwigDirector_Bar uintptr +type SwigDirector_Bar interface { + Swigcptr() uintptr; +} +func (p SwigcptrSwigDirector_Bar) Swigcptr() uintptr { + return uintptr(p) +} + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/director_exception_runme b/Examples/test-suite/go/director_exception_runme new file mode 100755 index 000000000..77b5f04d5 Binary files /dev/null and b/Examples/test-suite/go/director_exception_runme differ diff --git a/Examples/test-suite/go/director_exception_wrap.h b/Examples/test-suite/go/director_exception_wrap.h new file mode 100644 index 000000000..53d2ff6a0 --- /dev/null +++ b/Examples/test-suite/go/director_exception_wrap.h @@ -0,0 +1,87 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../director_exception.i + +#ifndef SWIG_director_exception_WRAP_H_ +#define SWIG_director_exception_WRAP_H_ + +class SwigDirector_Foo : public Foo +{ + public: + SwigDirector_Foo(void *swig_p); + virtual ~SwigDirector_Foo(); + std::string _swig_upcall_ping() { + return Foo::ping(); + } + virtual std::string ping(); + std::string _swig_upcall_pong__SWIG_0(int val) { + return Foo::pong(val); + } + virtual std::string pong(int val); + std::string _swig_upcall_pong__SWIG_1() { + return Foo::pong(); + } + virtual std::string pong(); + private: + void *go_val; +}; + +class SwigDirector_Bar : public Bar +{ + public: + SwigDirector_Bar(void *swig_p); + virtual ~SwigDirector_Bar() throw(); + std::string _swig_upcall_ping() { + return Bar::ping(); + } + virtual std::string ping() throw(Exception1, Exception2 &); + std::string _swig_upcall_pong() { + return Bar::pong(); + } + virtual std::string pong() throw(Unknown1, int, Unknown2 &); + std::string _swig_upcall_pang() { + return Bar::pang(); + } + virtual std::string pang() throw(); + private: + void *go_val; +}; + +class SwigDirector_ReturnAllTypes : public ReturnAllTypes +{ + public: + SwigDirector_ReturnAllTypes(void *swig_p); + int _swig_upcall_return_int() { + return ReturnAllTypes::return_int(); + } + virtual int return_int(); + double _swig_upcall_return_double() { + return ReturnAllTypes::return_double(); + } + virtual double return_double(); + char const *_swig_upcall_return_const_char_star() { + return ReturnAllTypes::return_const_char_star(); + } + virtual char const *return_const_char_star(); + std::string _swig_upcall_return_std_string() { + return ReturnAllTypes::return_std_string(); + } + virtual std::string return_std_string(); + Bar _swig_upcall_return_Bar() { + return ReturnAllTypes::return_Bar(); + } + virtual Bar return_Bar(); + virtual ~SwigDirector_ReturnAllTypes(); + private: + void *go_val; +}; + +#endif diff --git a/Examples/test-suite/go/director_extend.go b/Examples/test-suite/go/director_extend.go new file mode 100644 index 000000000..a49852131 --- /dev/null +++ b/Examples/test-suite/go/director_extend.go @@ -0,0 +1,101 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../director_extend.i + +package director_extend + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrSpObject uintptr + +func (p SwigcptrSpObject) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrSpObject) SwigIsSpObject() { +} + +var _wrap_new_SpObject unsafe.Pointer + +func _swig_wrap_new_SpObject() (base SwigcptrSpObject) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_SpObject, _swig_p) + return +} + +func NewSpObject() (_swig_ret SpObject) { + return _swig_wrap_new_SpObject() +} + +var _wrap_delete_SpObject unsafe.Pointer + +func _swig_wrap_delete_SpObject(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_SpObject, _swig_p) + return +} + +func DeleteSpObject(arg1 SpObject) { + _swig_wrap_delete_SpObject(arg1.Swigcptr()) +} + +var _wrap_SpObject_getFooBar unsafe.Pointer + +func _swig_wrap_SpObject_getFooBar(base SwigcptrSpObject) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_SpObject_getFooBar, _swig_p) + return +} + +func (arg1 SwigcptrSpObject) GetFooBar() (_swig_ret int) { + return _swig_wrap_SpObject_getFooBar(arg1) +} + +var _wrap_SpObject_dummy unsafe.Pointer + +func _swig_wrap_SpObject_dummy(base SwigcptrSpObject) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_SpObject_dummy, _swig_p) + return +} + +func (arg1 SwigcptrSpObject) Dummy() (_swig_ret int) { + return _swig_wrap_SpObject_dummy(arg1) +} + +type SpObject interface { + Swigcptr() uintptr + SwigIsSpObject() + GetFooBar() (_swig_ret int) + Dummy() (_swig_ret int) +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/director_extend_runme b/Examples/test-suite/go/director_extend_runme new file mode 100755 index 000000000..d947b2b50 Binary files /dev/null and b/Examples/test-suite/go/director_extend_runme differ diff --git a/Examples/test-suite/go/director_extend_wrap.h b/Examples/test-suite/go/director_extend_wrap.h new file mode 100644 index 000000000..8fc4e4d1b --- /dev/null +++ b/Examples/test-suite/go/director_extend_wrap.h @@ -0,0 +1,16 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../director_extend.i + +#ifndef SWIG_director_extend_WRAP_H_ +#define SWIG_director_extend_WRAP_H_ + +#endif diff --git a/Examples/test-suite/go/director_finalizer.go b/Examples/test-suite/go/director_finalizer.go new file mode 100644 index 000000000..293dfeecf --- /dev/null +++ b/Examples/test-suite/go/director_finalizer.go @@ -0,0 +1,206 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../director_finalizer.i + +package director_finalizer + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type _swig_DirectorFoo struct { + SwigcptrFoo + v interface{} +} + +func (p *_swig_DirectorFoo) Swigcptr() uintptr { + return p.SwigcptrFoo.Swigcptr() +} + +func (p *_swig_DirectorFoo) SwigIsFoo() { +} + +func (p *_swig_DirectorFoo) DirectorInterface() interface{} { + return p.v +} + +var _wrap__swig_NewDirectorFooFoo unsafe.Pointer + +func _swig_NewDirectorFooFoo(_swig_director *_swig_DirectorFoo) (_swig_ret SwigcptrFoo) { + _swig_p := uintptr(unsafe.Pointer(&_swig_director)) + _cgo_runtime_cgocall(_wrap__swig_NewDirectorFooFoo, _swig_p) + return +} + +func NewDirectorFoo(v interface{}) Foo { + p := &_swig_DirectorFoo{0, v} + p.SwigcptrFoo = _swig_NewDirectorFooFoo(p) + return p +} + +var _wrap_DeleteDirectorFoo unsafe.Pointer + +func _swig_wrap_DeleteDirectorFoo(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_DeleteDirectorFoo, _swig_p) + return +} + +func DeleteDirectorFoo(arg1 Foo) { + _swig_wrap_DeleteDirectorFoo(arg1.Swigcptr()) +} + +func Swiggo_DeleteDirector_Foo(p *_swig_DirectorFoo) { + p.SwigcptrFoo = 0 +} + +type _swig_DirectorInterfaceFooOrStatus interface { + OrStatus(int) +} + +var _wrap__swig_DirectorFoo_upcall_OrStatus unsafe.Pointer + +func _swig_wrap__swig_DirectorFoo_upcall_OrStatus(_swig_ptr SwigcptrFoo, _ int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) + _cgo_runtime_cgocall(_wrap__swig_DirectorFoo_upcall_OrStatus, _swig_p) + return +} + +func (swig_p *_swig_DirectorFoo) OrStatus(x int) { + if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceFooOrStatus); swig_ok { + swig_g.OrStatus(x) + return + } + _swig_wrap__swig_DirectorFoo_upcall_OrStatus(swig_p.SwigcptrFoo, x) +} + +func DirectorFooOrStatus(p Foo, arg2 int) { + _swig_wrap__swig_DirectorFoo_upcall_OrStatus(p.(*_swig_DirectorFoo).SwigcptrFoo, arg2) +} + +func Swig_DirectorFoo_callback_orStatus(p *_swig_DirectorFoo, arg2 int) { + p.OrStatus(arg2) +} + +type SwigcptrFoo uintptr + +func (p SwigcptrFoo) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrFoo) SwigIsFoo() { +} + +func (p SwigcptrFoo) DirectorInterface() interface{} { + return nil +} + +var _wrap_delete_Foo unsafe.Pointer + +func _swig_wrap_delete_Foo(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Foo, _swig_p) + return +} + +func DeleteFoo(arg1 Foo) { + _swig_wrap_delete_Foo(arg1.Swigcptr()) +} + +var _wrap_Foo_orStatus unsafe.Pointer + +func _swig_wrap_Foo_orStatus(base SwigcptrFoo, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_orStatus, _swig_p) + return +} + +func (arg1 SwigcptrFoo) OrStatus(arg2 int) { + _swig_wrap_Foo_orStatus(arg1, arg2) +} + +var _wrap_new_Foo unsafe.Pointer + +func _swig_wrap_new_Foo() (base SwigcptrFoo) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Foo, _swig_p) + return +} + +func NewFoo() (_swig_ret Foo) { + return _swig_wrap_new_Foo() +} + +type Foo interface { + Swigcptr() uintptr + SwigIsFoo() + DirectorInterface() interface{} + OrStatus(arg2 int) +} + +var _wrap_getStatus unsafe.Pointer + +func GetStatus() (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_getStatus, _swig_p) + return +} +var _wrap_launder unsafe.Pointer + +func _swig_wrap_launder(base uintptr) (_ SwigcptrFoo) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_launder, _swig_p) + return +} + +func Launder(arg1 Foo) (_swig_ret Foo) { + return _swig_wrap_launder(arg1.Swigcptr()) +} + +var _wrap_resetStatus unsafe.Pointer + +func _swig_wrap_resetStatus() { + var _swig_p uintptr + _cgo_runtime_cgocall(_wrap_resetStatus, _swig_p) + return +} + +func ResetStatus() { + _swig_wrap_resetStatus() +} + + +type SwigcptrSwigDirector_Foo uintptr +type SwigDirector_Foo interface { + Swigcptr() uintptr; +} +func (p SwigcptrSwigDirector_Foo) Swigcptr() uintptr { + return uintptr(p) +} + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/director_finalizer_runme b/Examples/test-suite/go/director_finalizer_runme new file mode 100755 index 000000000..6e2484102 Binary files /dev/null and b/Examples/test-suite/go/director_finalizer_runme differ diff --git a/Examples/test-suite/go/director_finalizer_wrap.h b/Examples/test-suite/go/director_finalizer_wrap.h new file mode 100644 index 000000000..07f5451d5 --- /dev/null +++ b/Examples/test-suite/go/director_finalizer_wrap.h @@ -0,0 +1,29 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../director_finalizer.i + +#ifndef SWIG_director_finalizer_WRAP_H_ +#define SWIG_director_finalizer_WRAP_H_ + +class SwigDirector_Foo : public Foo +{ + public: + SwigDirector_Foo(void *swig_p); + virtual ~SwigDirector_Foo(); + void _swig_upcall_orStatus(int x) { + Foo::orStatus(x); + } + virtual void orStatus(int x); + private: + void *go_val; +}; + +#endif diff --git a/Examples/test-suite/go/director_frob.go b/Examples/test-suite/go/director_frob.go new file mode 100644 index 000000000..1ca9f17ee --- /dev/null +++ b/Examples/test-suite/go/director_frob.go @@ -0,0 +1,1493 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../director_frob.i + +package director_frob + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type _swig_DirectorAlpha struct { + SwigcptrAlpha + v interface{} +} + +func (p *_swig_DirectorAlpha) Swigcptr() uintptr { + return p.SwigcptrAlpha.Swigcptr() +} + +func (p *_swig_DirectorAlpha) SwigIsAlpha() { +} + +func (p *_swig_DirectorAlpha) DirectorInterface() interface{} { + return p.v +} + +var _wrap__swig_NewDirectorAlphaAlpha unsafe.Pointer + +func _swig_NewDirectorAlphaAlpha(_swig_director *_swig_DirectorAlpha) (_swig_ret SwigcptrAlpha) { + _swig_p := uintptr(unsafe.Pointer(&_swig_director)) + _cgo_runtime_cgocall(_wrap__swig_NewDirectorAlphaAlpha, _swig_p) + return +} + +func NewDirectorAlpha(v interface{}) Alpha { + p := &_swig_DirectorAlpha{0, v} + p.SwigcptrAlpha = _swig_NewDirectorAlphaAlpha(p) + return p +} + +var _wrap_DeleteDirectorAlpha unsafe.Pointer + +func _swig_wrap_DeleteDirectorAlpha(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_DeleteDirectorAlpha, _swig_p) + return +} + +func DeleteDirectorAlpha(arg1 Alpha) { + _swig_wrap_DeleteDirectorAlpha(arg1.Swigcptr()) +} + +func Swiggo_DeleteDirector_Alpha(p *_swig_DirectorAlpha) { + p.SwigcptrAlpha = 0 +} + +type _swig_DirectorInterfaceAlphaAbs_method interface { + Abs_method() string +} + +func (swig_p *_swig_DirectorAlpha) Abs_method() string { + if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceAlphaAbs_method); swig_ok { + return swig_g.Abs_method() + } + panic("call to pure virtual method") +} + +func Swig_DirectorAlpha_callback_abs_method(p *_swig_DirectorAlpha) (swig_result string) { + var swig_r string + swig_r = p.Abs_method() + return swig_r +} + +type SwigcptrAlpha uintptr + +func (p SwigcptrAlpha) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrAlpha) SwigIsAlpha() { +} + +func (p SwigcptrAlpha) DirectorInterface() interface{} { + return nil +} + +var _wrap_delete_Alpha unsafe.Pointer + +func _swig_wrap_delete_Alpha(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Alpha, _swig_p) + return +} + +func DeleteAlpha(arg1 Alpha) { + _swig_wrap_delete_Alpha(arg1.Swigcptr()) +} + +var _wrap_Alpha_abs_method unsafe.Pointer + +func _swig_wrap_Alpha_abs_method(base SwigcptrAlpha) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Alpha_abs_method, _swig_p) + return +} + +func (arg1 SwigcptrAlpha) Abs_method() (_swig_ret string) { + return _swig_wrap_Alpha_abs_method(arg1) +} + +var _wrap_new_Alpha unsafe.Pointer + +func _swig_wrap_new_Alpha() (base SwigcptrAlpha) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Alpha, _swig_p) + return +} + +func NewAlpha() (_swig_ret Alpha) { + return _swig_wrap_new_Alpha() +} + +type Alpha interface { + Swigcptr() uintptr + SwigIsAlpha() + DirectorInterface() interface{} + Abs_method() (_swig_ret string) +} + +type _swig_DirectorBravo struct { + SwigcptrBravo + v interface{} +} + +func (p *_swig_DirectorBravo) Swigcptr() uintptr { + return p.SwigcptrBravo.Swigcptr() +} + +func (p *_swig_DirectorBravo) SwigIsBravo() { +} + +func (p *_swig_DirectorBravo) DirectorInterface() interface{} { + return p.v +} + +var _wrap__swig_NewDirectorBravoBravo unsafe.Pointer + +func _swig_NewDirectorBravoBravo(_swig_director *_swig_DirectorBravo) (_swig_ret SwigcptrBravo) { + _swig_p := uintptr(unsafe.Pointer(&_swig_director)) + _cgo_runtime_cgocall(_wrap__swig_NewDirectorBravoBravo, _swig_p) + return +} + +func NewDirectorBravo(v interface{}) Bravo { + p := &_swig_DirectorBravo{0, v} + p.SwigcptrBravo = _swig_NewDirectorBravoBravo(p) + return p +} + +var _wrap_DeleteDirectorBravo unsafe.Pointer + +func _swig_wrap_DeleteDirectorBravo(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_DeleteDirectorBravo, _swig_p) + return +} + +func DeleteDirectorBravo(arg1 Bravo) { + _swig_wrap_DeleteDirectorBravo(arg1.Swigcptr()) +} + +func Swiggo_DeleteDirector_Bravo(p *_swig_DirectorBravo) { + p.SwigcptrBravo = 0 +} + +type SwigcptrBravo uintptr + +func (p SwigcptrBravo) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrBravo) SwigIsBravo() { +} + +func (p SwigcptrBravo) DirectorInterface() interface{} { + return nil +} + +var _wrap_Bravo_abs_method unsafe.Pointer + +func _swig_wrap_Bravo_abs_method(base SwigcptrBravo) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Bravo_abs_method, _swig_p) + return +} + +func (arg1 SwigcptrBravo) Abs_method() (_swig_ret string) { + return _swig_wrap_Bravo_abs_method(arg1) +} + +var _wrap_new_Bravo unsafe.Pointer + +func _swig_wrap_new_Bravo() (base SwigcptrBravo) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Bravo, _swig_p) + return +} + +func NewBravo() (_swig_ret Bravo) { + return _swig_wrap_new_Bravo() +} + +var _wrap_delete_Bravo unsafe.Pointer + +func _swig_wrap_delete_Bravo(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Bravo, _swig_p) + return +} + +func DeleteBravo(arg1 Bravo) { + _swig_wrap_delete_Bravo(arg1.Swigcptr()) +} + +func (p SwigcptrBravo) SwigIsAlpha() { +} + +func (p SwigcptrBravo) SwigGetAlpha() Alpha { + return SwigcptrAlpha(p.Swigcptr()) +} + +type Bravo interface { + Swigcptr() uintptr + SwigIsBravo() + DirectorInterface() interface{} + Abs_method() (_swig_ret string) + SwigIsAlpha() + SwigGetAlpha() Alpha +} + +type _swig_DirectorCharlie struct { + SwigcptrCharlie + v interface{} +} + +func (p *_swig_DirectorCharlie) Swigcptr() uintptr { + return p.SwigcptrCharlie.Swigcptr() +} + +func (p *_swig_DirectorCharlie) SwigIsCharlie() { +} + +func (p *_swig_DirectorCharlie) DirectorInterface() interface{} { + return p.v +} + +var _wrap__swig_NewDirectorCharlieCharlie unsafe.Pointer + +func _swig_NewDirectorCharlieCharlie(_swig_director *_swig_DirectorCharlie) (_swig_ret SwigcptrCharlie) { + _swig_p := uintptr(unsafe.Pointer(&_swig_director)) + _cgo_runtime_cgocall(_wrap__swig_NewDirectorCharlieCharlie, _swig_p) + return +} + +func NewDirectorCharlie(v interface{}) Charlie { + p := &_swig_DirectorCharlie{0, v} + p.SwigcptrCharlie = _swig_NewDirectorCharlieCharlie(p) + return p +} + +var _wrap_DeleteDirectorCharlie unsafe.Pointer + +func _swig_wrap_DeleteDirectorCharlie(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_DeleteDirectorCharlie, _swig_p) + return +} + +func DeleteDirectorCharlie(arg1 Charlie) { + _swig_wrap_DeleteDirectorCharlie(arg1.Swigcptr()) +} + +func Swiggo_DeleteDirector_Charlie(p *_swig_DirectorCharlie) { + p.SwigcptrCharlie = 0 +} + +type _swig_DirectorInterfaceCharlieAbs_method interface { + Abs_method() string +} + +var _wrap__swig_DirectorCharlie_upcall_Abs_method unsafe.Pointer + +func _swig_wrap__swig_DirectorCharlie_upcall_Abs_method(_swig_ptr SwigcptrCharlie) (_swig_ret string) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) + _cgo_runtime_cgocall(_wrap__swig_DirectorCharlie_upcall_Abs_method, _swig_p) + return +} + +func (swig_p *_swig_DirectorCharlie) Abs_method() string { + if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceCharlieAbs_method); swig_ok { + return swig_g.Abs_method() + } + var swig_r string + swig_r = _swig_wrap__swig_DirectorCharlie_upcall_Abs_method(swig_p.SwigcptrCharlie) + return swig_r +} + +func DirectorCharlieAbs_method(p Charlie) string { + var swig_r string + swig_r = _swig_wrap__swig_DirectorCharlie_upcall_Abs_method(p.(*_swig_DirectorCharlie).SwigcptrCharlie) + return swig_r +} + +func Swig_DirectorCharlie_callback_abs_method(p *_swig_DirectorCharlie) (swig_result string) { + var swig_r string + swig_r = p.Abs_method() + return swig_r +} + +type SwigcptrCharlie uintptr + +func (p SwigcptrCharlie) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrCharlie) SwigIsCharlie() { +} + +func (p SwigcptrCharlie) DirectorInterface() interface{} { + return nil +} + +var _wrap_Charlie_abs_method unsafe.Pointer + +func _swig_wrap_Charlie_abs_method(base SwigcptrCharlie) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Charlie_abs_method, _swig_p) + return +} + +func (arg1 SwigcptrCharlie) Abs_method() (_swig_ret string) { + return _swig_wrap_Charlie_abs_method(arg1) +} + +var _wrap_new_Charlie unsafe.Pointer + +func _swig_wrap_new_Charlie() (base SwigcptrCharlie) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Charlie, _swig_p) + return +} + +func NewCharlie() (_swig_ret Charlie) { + return _swig_wrap_new_Charlie() +} + +var _wrap_delete_Charlie unsafe.Pointer + +func _swig_wrap_delete_Charlie(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Charlie, _swig_p) + return +} + +func DeleteCharlie(arg1 Charlie) { + _swig_wrap_delete_Charlie(arg1.Swigcptr()) +} + +func (p SwigcptrCharlie) SwigIsBravo() { +} + +func (p SwigcptrCharlie) SwigGetBravo() Bravo { + return SwigcptrBravo(p.Swigcptr()) +} + +func (p SwigcptrCharlie) SwigIsAlpha() { +} + +func (p SwigcptrCharlie) SwigGetAlpha() Alpha { + return SwigcptrAlpha(p.Swigcptr()) +} + +type Charlie interface { + Swigcptr() uintptr + SwigIsCharlie() + DirectorInterface() interface{} + Abs_method() (_swig_ret string) + SwigIsBravo() + SwigGetBravo() Bravo + SwigIsAlpha() + SwigGetAlpha() Alpha +} + +type _swig_DirectorDelta struct { + SwigcptrDelta + v interface{} +} + +func (p *_swig_DirectorDelta) Swigcptr() uintptr { + return p.SwigcptrDelta.Swigcptr() +} + +func (p *_swig_DirectorDelta) SwigIsDelta() { +} + +func (p *_swig_DirectorDelta) DirectorInterface() interface{} { + return p.v +} + +var _wrap__swig_NewDirectorDeltaDelta unsafe.Pointer + +func _swig_NewDirectorDeltaDelta(_swig_director *_swig_DirectorDelta) (_swig_ret SwigcptrDelta) { + _swig_p := uintptr(unsafe.Pointer(&_swig_director)) + _cgo_runtime_cgocall(_wrap__swig_NewDirectorDeltaDelta, _swig_p) + return +} + +func NewDirectorDelta(v interface{}) Delta { + p := &_swig_DirectorDelta{0, v} + p.SwigcptrDelta = _swig_NewDirectorDeltaDelta(p) + return p +} + +var _wrap_DeleteDirectorDelta unsafe.Pointer + +func _swig_wrap_DeleteDirectorDelta(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_DeleteDirectorDelta, _swig_p) + return +} + +func DeleteDirectorDelta(arg1 Delta) { + _swig_wrap_DeleteDirectorDelta(arg1.Swigcptr()) +} + +func Swiggo_DeleteDirector_Delta(p *_swig_DirectorDelta) { + p.SwigcptrDelta = 0 +} + +type _swig_DirectorInterfaceDeltaAbs_method interface { + Abs_method() string +} + +var _wrap__swig_DirectorDelta_upcall_Abs_method unsafe.Pointer + +func _swig_wrap__swig_DirectorDelta_upcall_Abs_method(_swig_ptr SwigcptrDelta) (_swig_ret string) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) + _cgo_runtime_cgocall(_wrap__swig_DirectorDelta_upcall_Abs_method, _swig_p) + return +} + +func (swig_p *_swig_DirectorDelta) Abs_method() string { + if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceDeltaAbs_method); swig_ok { + return swig_g.Abs_method() + } + var swig_r string + swig_r = _swig_wrap__swig_DirectorDelta_upcall_Abs_method(swig_p.SwigcptrDelta) + return swig_r +} + +func DirectorDeltaAbs_method(p Delta) string { + var swig_r string + swig_r = _swig_wrap__swig_DirectorDelta_upcall_Abs_method(p.(*_swig_DirectorDelta).SwigcptrDelta) + return swig_r +} + +func Swig_DirectorDelta_callback_abs_method(p *_swig_DirectorDelta) (swig_result string) { + var swig_r string + swig_r = p.Abs_method() + return swig_r +} + +type SwigcptrDelta uintptr + +func (p SwigcptrDelta) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrDelta) SwigIsDelta() { +} + +func (p SwigcptrDelta) DirectorInterface() interface{} { + return nil +} + +var _wrap_new_Delta unsafe.Pointer + +func _swig_wrap_new_Delta() (base SwigcptrDelta) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Delta, _swig_p) + return +} + +func NewDelta() (_swig_ret Delta) { + return _swig_wrap_new_Delta() +} + +var _wrap_delete_Delta unsafe.Pointer + +func _swig_wrap_delete_Delta(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Delta, _swig_p) + return +} + +func DeleteDelta(arg1 Delta) { + _swig_wrap_delete_Delta(arg1.Swigcptr()) +} + +var _wrap_Delta_abs_method unsafe.Pointer + +func _swig_wrap_Delta_abs_method(base SwigcptrDelta) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Delta_abs_method, _swig_p) + return +} + +func (_swig_base SwigcptrDelta) Abs_method() (_swig_ret string) { + return _swig_wrap_Delta_abs_method(_swig_base) +} + +func (p SwigcptrDelta) SwigIsCharlie() { +} + +func (p SwigcptrDelta) SwigGetCharlie() Charlie { + return SwigcptrCharlie(p.Swigcptr()) +} + +func (p SwigcptrDelta) SwigIsBravo() { +} + +func (p SwigcptrDelta) SwigGetBravo() Bravo { + return SwigcptrBravo(p.Swigcptr()) +} + +func (p SwigcptrDelta) SwigIsAlpha() { +} + +func (p SwigcptrDelta) SwigGetAlpha() Alpha { + return SwigcptrAlpha(p.Swigcptr()) +} + +type Delta interface { + Swigcptr() uintptr + SwigIsDelta() + DirectorInterface() interface{} + Abs_method() (_swig_ret string) + SwigIsCharlie() + SwigGetCharlie() Charlie + SwigIsBravo() + SwigGetBravo() Bravo + SwigIsAlpha() + SwigGetAlpha() Alpha +} + +type _swig_DirectorOps struct { + SwigcptrOps + v interface{} +} + +func (p *_swig_DirectorOps) Swigcptr() uintptr { + return p.SwigcptrOps.Swigcptr() +} + +func (p *_swig_DirectorOps) SwigIsOps() { +} + +func (p *_swig_DirectorOps) DirectorInterface() interface{} { + return p.v +} + +var _wrap__swig_NewDirectorOpsOps unsafe.Pointer + +func _swig_NewDirectorOpsOps(_swig_director *_swig_DirectorOps) (_swig_ret SwigcptrOps) { + _swig_p := uintptr(unsafe.Pointer(&_swig_director)) + _cgo_runtime_cgocall(_wrap__swig_NewDirectorOpsOps, _swig_p) + return +} + +func NewDirectorOps(v interface{}) Ops { + p := &_swig_DirectorOps{0, v} + p.SwigcptrOps = _swig_NewDirectorOpsOps(p) + return p +} + +var _wrap_DeleteDirectorOps unsafe.Pointer + +func _swig_wrap_DeleteDirectorOps(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_DeleteDirectorOps, _swig_p) + return +} + +func DeleteDirectorOps(arg1 Ops) { + _swig_wrap_DeleteDirectorOps(arg1.Swigcptr()) +} + +func Swiggo_DeleteDirector_Ops(p *_swig_DirectorOps) { + p.SwigcptrOps = 0 +} + +type _swig_DirectorInterfaceOpsOpInt interface { + OpInt() int +} + +var _wrap__swig_DirectorOps_upcall_OpInt unsafe.Pointer + +func _swig_wrap__swig_DirectorOps_upcall_OpInt(_swig_ptr SwigcptrOps) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) + _cgo_runtime_cgocall(_wrap__swig_DirectorOps_upcall_OpInt, _swig_p) + return +} + +func (swig_p *_swig_DirectorOps) OpInt() int { + if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceOpsOpInt); swig_ok { + return swig_g.OpInt() + } + var swig_r int + swig_r = _swig_wrap__swig_DirectorOps_upcall_OpInt(swig_p.SwigcptrOps) + return swig_r +} + +func DirectorOpsOpInt(p Ops) int { + var swig_r int + swig_r = _swig_wrap__swig_DirectorOps_upcall_OpInt(p.(*_swig_DirectorOps).SwigcptrOps) + return swig_r +} + +func Swig_DirectorOps_callback_OpInt(p *_swig_DirectorOps) (swig_result int) { + var swig_r int + swig_r = p.OpInt() + return swig_r +} + +type _swig_DirectorInterfaceOpsOpIntStarStarConst interface { + OpIntStarStarConst() **int +} + +var _wrap__swig_DirectorOps_upcall_OpIntStarStarConst unsafe.Pointer + +func _swig_wrap__swig_DirectorOps_upcall_OpIntStarStarConst(_swig_ptr SwigcptrOps) (_swig_ret **int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) + _cgo_runtime_cgocall(_wrap__swig_DirectorOps_upcall_OpIntStarStarConst, _swig_p) + return +} + +func (swig_p *_swig_DirectorOps) OpIntStarStarConst() **int { + if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceOpsOpIntStarStarConst); swig_ok { + return swig_g.OpIntStarStarConst() + } + var swig_r **int + swig_r = _swig_wrap__swig_DirectorOps_upcall_OpIntStarStarConst(swig_p.SwigcptrOps) + return swig_r +} + +func DirectorOpsOpIntStarStarConst(p Ops) **int { + var swig_r **int + swig_r = _swig_wrap__swig_DirectorOps_upcall_OpIntStarStarConst(p.(*_swig_DirectorOps).SwigcptrOps) + return swig_r +} + +func Swig_DirectorOps_callback_OpIntStarStarConst(p *_swig_DirectorOps) (swig_result **int) { + var swig_r **int + swig_r = p.OpIntStarStarConst() + return swig_r +} + +type _swig_DirectorInterfaceOpsOpIntAmp interface { + OpIntAmp() *int +} + +var _wrap__swig_DirectorOps_upcall_OpIntAmp unsafe.Pointer + +func _swig_wrap__swig_DirectorOps_upcall_OpIntAmp(_swig_ptr SwigcptrOps) (_swig_ret *int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) + _cgo_runtime_cgocall(_wrap__swig_DirectorOps_upcall_OpIntAmp, _swig_p) + return +} + +func (swig_p *_swig_DirectorOps) OpIntAmp() *int { + if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceOpsOpIntAmp); swig_ok { + return swig_g.OpIntAmp() + } + var swig_r *int + swig_r = _swig_wrap__swig_DirectorOps_upcall_OpIntAmp(swig_p.SwigcptrOps) + return swig_r +} + +func DirectorOpsOpIntAmp(p Ops) *int { + var swig_r *int + swig_r = _swig_wrap__swig_DirectorOps_upcall_OpIntAmp(p.(*_swig_DirectorOps).SwigcptrOps) + return swig_r +} + +func Swig_DirectorOps_callback_OpIntAmp(p *_swig_DirectorOps) (swig_result *int) { + var swig_r *int + swig_r = p.OpIntAmp() + return swig_r +} + +type _swig_DirectorInterfaceOpsOpIntStar interface { + OpIntStar() uintptr +} + +var _wrap__swig_DirectorOps_upcall_OpIntStar unsafe.Pointer + +func _swig_wrap__swig_DirectorOps_upcall_OpIntStar(_swig_ptr SwigcptrOps) (_swig_ret uintptr) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) + _cgo_runtime_cgocall(_wrap__swig_DirectorOps_upcall_OpIntStar, _swig_p) + return +} + +func (swig_p *_swig_DirectorOps) OpIntStar() uintptr { + if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceOpsOpIntStar); swig_ok { + return swig_g.OpIntStar() + } + var swig_r uintptr + swig_r = _swig_wrap__swig_DirectorOps_upcall_OpIntStar(swig_p.SwigcptrOps) + return swig_r +} + +func DirectorOpsOpIntStar(p Ops) uintptr { + var swig_r uintptr + swig_r = _swig_wrap__swig_DirectorOps_upcall_OpIntStar(p.(*_swig_DirectorOps).SwigcptrOps) + return swig_r +} + +func Swig_DirectorOps_callback_OpIntStar(p *_swig_DirectorOps) (swig_result uintptr) { + var swig_r uintptr + swig_r = p.OpIntStar() + return swig_r +} + +type _swig_DirectorInterfaceOpsOpConstIntIntStar interface { + OpConstIntIntStar() *int +} + +var _wrap__swig_DirectorOps_upcall_OpConstIntIntStar unsafe.Pointer + +func _swig_wrap__swig_DirectorOps_upcall_OpConstIntIntStar(_swig_ptr SwigcptrOps) (_swig_ret *int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) + _cgo_runtime_cgocall(_wrap__swig_DirectorOps_upcall_OpConstIntIntStar, _swig_p) + return +} + +func (swig_p *_swig_DirectorOps) OpConstIntIntStar() *int { + if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceOpsOpConstIntIntStar); swig_ok { + return swig_g.OpConstIntIntStar() + } + var swig_r *int + swig_r = _swig_wrap__swig_DirectorOps_upcall_OpConstIntIntStar(swig_p.SwigcptrOps) + return swig_r +} + +func DirectorOpsOpConstIntIntStar(p Ops) *int { + var swig_r *int + swig_r = _swig_wrap__swig_DirectorOps_upcall_OpConstIntIntStar(p.(*_swig_DirectorOps).SwigcptrOps) + return swig_r +} + +func Swig_DirectorOps_callback_OpConstIntIntStar(p *_swig_DirectorOps) (swig_result *int) { + var swig_r *int + swig_r = p.OpConstIntIntStar() + return swig_r +} + +type SwigcptrOps uintptr + +func (p SwigcptrOps) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrOps) SwigIsOps() { +} + +func (p SwigcptrOps) DirectorInterface() interface{} { + return nil +} + +var _wrap_new_Ops unsafe.Pointer + +func _swig_wrap_new_Ops() (base SwigcptrOps) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Ops, _swig_p) + return +} + +func NewOps() (_swig_ret Ops) { + return _swig_wrap_new_Ops() +} + +var _wrap_delete_Ops unsafe.Pointer + +func _swig_wrap_delete_Ops(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Ops, _swig_p) + return +} + +func DeleteOps(arg1 Ops) { + _swig_wrap_delete_Ops(arg1.Swigcptr()) +} + +var _wrap_Ops_OpInt unsafe.Pointer + +func _swig_wrap_Ops_OpInt(base SwigcptrOps) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Ops_OpInt, _swig_p) + return +} + +func (arg1 SwigcptrOps) OpInt() (_swig_ret int) { + return _swig_wrap_Ops_OpInt(arg1) +} + +var _wrap_Ops_OpIntStarStarConst unsafe.Pointer + +func _swig_wrap_Ops_OpIntStarStarConst(base SwigcptrOps) (_ **int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Ops_OpIntStarStarConst, _swig_p) + return +} + +func (arg1 SwigcptrOps) OpIntStarStarConst() (_swig_ret **int) { + return _swig_wrap_Ops_OpIntStarStarConst(arg1) +} + +var _wrap_Ops_OpIntAmp unsafe.Pointer + +func _swig_wrap_Ops_OpIntAmp(base SwigcptrOps) (_ *int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Ops_OpIntAmp, _swig_p) + return +} + +func (arg1 SwigcptrOps) OpIntAmp() (_swig_ret *int) { + return _swig_wrap_Ops_OpIntAmp(arg1) +} + +var _wrap_Ops_OpIntStar unsafe.Pointer + +func _swig_wrap_Ops_OpIntStar(base SwigcptrOps) (_ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Ops_OpIntStar, _swig_p) + return +} + +func (arg1 SwigcptrOps) OpIntStar() (_swig_ret uintptr) { + return _swig_wrap_Ops_OpIntStar(arg1) +} + +var _wrap_Ops_OpConstIntIntStar unsafe.Pointer + +func _swig_wrap_Ops_OpConstIntIntStar(base SwigcptrOps) (_ *int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Ops_OpConstIntIntStar, _swig_p) + return +} + +func (arg1 SwigcptrOps) OpConstIntIntStar() (_swig_ret *int) { + return _swig_wrap_Ops_OpConstIntIntStar(arg1) +} + +type Ops interface { + Swigcptr() uintptr + SwigIsOps() + DirectorInterface() interface{} + OpInt() (_swig_ret int) + OpIntStarStarConst() (_swig_ret **int) + OpIntAmp() (_swig_ret *int) + OpIntStar() (_swig_ret uintptr) + OpConstIntIntStar() (_swig_ret *int) +} + +type _swig_DirectorPrims struct { + SwigcptrPrims + v interface{} +} + +func (p *_swig_DirectorPrims) Swigcptr() uintptr { + return p.SwigcptrPrims.Swigcptr() +} + +func (p *_swig_DirectorPrims) SwigIsPrims() { +} + +func (p *_swig_DirectorPrims) DirectorInterface() interface{} { + return p.v +} + +var _wrap__swig_NewDirectorPrimsPrims unsafe.Pointer + +func _swig_NewDirectorPrimsPrims(_swig_director *_swig_DirectorPrims) (_swig_ret SwigcptrPrims) { + _swig_p := uintptr(unsafe.Pointer(&_swig_director)) + _cgo_runtime_cgocall(_wrap__swig_NewDirectorPrimsPrims, _swig_p) + return +} + +func NewDirectorPrims(v interface{}) Prims { + p := &_swig_DirectorPrims{0, v} + p.SwigcptrPrims = _swig_NewDirectorPrimsPrims(p) + return p +} + +var _wrap_DeleteDirectorPrims unsafe.Pointer + +func _swig_wrap_DeleteDirectorPrims(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_DeleteDirectorPrims, _swig_p) + return +} + +func DeleteDirectorPrims(arg1 Prims) { + _swig_wrap_DeleteDirectorPrims(arg1.Swigcptr()) +} + +func Swiggo_DeleteDirector_Prims(p *_swig_DirectorPrims) { + p.SwigcptrPrims = 0 +} + +type _swig_DirectorInterfacePrimsUll interface { + Ull(uint64, uint64) uint64 +} + +var _wrap__swig_DirectorPrims_upcall_Ull unsafe.Pointer + +func _swig_wrap__swig_DirectorPrims_upcall_Ull(_swig_ptr SwigcptrPrims, _ uint64, _ uint64) (_swig_ret uint64) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) + _cgo_runtime_cgocall(_wrap__swig_DirectorPrims_upcall_Ull, _swig_p) + return +} + +func (swig_p *_swig_DirectorPrims) Ull(i uint64, j uint64) uint64 { + if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfacePrimsUll); swig_ok { + return swig_g.Ull(i, j) + } + var swig_r uint64 + swig_r = _swig_wrap__swig_DirectorPrims_upcall_Ull(swig_p.SwigcptrPrims, i, j) + return swig_r +} + +func DirectorPrimsUll(p Prims, arg2 uint64, arg3 uint64) uint64 { + var swig_r uint64 + swig_r = _swig_wrap__swig_DirectorPrims_upcall_Ull(p.(*_swig_DirectorPrims).SwigcptrPrims, arg2, arg3) + return swig_r +} + +func Swig_DirectorPrims_callback_ull(p *_swig_DirectorPrims, arg2 uint64, arg3 uint64) (swig_result uint64) { + var swig_r uint64 + swig_r = p.Ull(arg2, arg3) + return swig_r +} + +type SwigcptrPrims uintptr + +func (p SwigcptrPrims) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrPrims) SwigIsPrims() { +} + +func (p SwigcptrPrims) DirectorInterface() interface{} { + return nil +} + +var _wrap_delete_Prims unsafe.Pointer + +func _swig_wrap_delete_Prims(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Prims, _swig_p) + return +} + +func DeletePrims(arg1 Prims) { + _swig_wrap_delete_Prims(arg1.Swigcptr()) +} + +var _wrap_Prims_ull unsafe.Pointer + +func _swig_wrap_Prims_ull(base SwigcptrPrims, _ uint64, _ uint64) (_ uint64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Prims_ull, _swig_p) + return +} + +func (arg1 SwigcptrPrims) Ull(arg2 uint64, arg3 uint64) (_swig_ret uint64) { + return _swig_wrap_Prims_ull(arg1, arg2, arg3) +} + +var _wrap_Prims_callull unsafe.Pointer + +func _swig_wrap_Prims_callull(base SwigcptrPrims, _ int, _ int) (_ uint64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Prims_callull, _swig_p) + return +} + +func (arg1 SwigcptrPrims) Callull(arg2 int, arg3 int) (_swig_ret uint64) { + return _swig_wrap_Prims_callull(arg1, arg2, arg3) +} + +var _wrap_new_Prims unsafe.Pointer + +func _swig_wrap_new_Prims() (base SwigcptrPrims) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Prims, _swig_p) + return +} + +func NewPrims() (_swig_ret Prims) { + return _swig_wrap_new_Prims() +} + +type Prims interface { + Swigcptr() uintptr + SwigIsPrims() + DirectorInterface() interface{} + Ull(arg2 uint64, arg3 uint64) (_swig_ret uint64) + Callull(arg2 int, arg3 int) (_swig_ret uint64) +} + +type SwigcptrCorePoint3d uintptr + +func (p SwigcptrCorePoint3d) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrCorePoint3d) SwigIsCorePoint3d() { +} + +func (p SwigcptrCorePoint3d) DirectorInterface() interface{} { + return nil +} + +var _wrap_new_corePoint3d unsafe.Pointer + +func _swig_wrap_new_corePoint3d() (base SwigcptrCorePoint3d) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_corePoint3d, _swig_p) + return +} + +func NewCorePoint3d() (_swig_ret CorePoint3d) { + return _swig_wrap_new_corePoint3d() +} + +var _wrap_delete_corePoint3d unsafe.Pointer + +func _swig_wrap_delete_corePoint3d(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_corePoint3d, _swig_p) + return +} + +func DeleteCorePoint3d(arg1 CorePoint3d) { + _swig_wrap_delete_corePoint3d(arg1.Swigcptr()) +} + +type CorePoint3d interface { + Swigcptr() uintptr + SwigIsCorePoint3d() + DirectorInterface() interface{} +} + +type SwigcptrCoreCallbacks_On3dEngineRedrawnData uintptr + +func (p SwigcptrCoreCallbacks_On3dEngineRedrawnData) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrCoreCallbacks_On3dEngineRedrawnData) SwigIsCoreCallbacks_On3dEngineRedrawnData() { +} + +func (p SwigcptrCoreCallbacks_On3dEngineRedrawnData) DirectorInterface() interface{} { + return nil +} + +var _wrap_coreCallbacks_On3dEngineRedrawnData__eye_set unsafe.Pointer + +func _swig_wrap_coreCallbacks_On3dEngineRedrawnData__eye_set(base SwigcptrCoreCallbacks_On3dEngineRedrawnData, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_coreCallbacks_On3dEngineRedrawnData__eye_set, _swig_p) + return +} + +func (arg1 SwigcptrCoreCallbacks_On3dEngineRedrawnData) SetX_eye(arg2 CorePoint3d) { + _swig_wrap_coreCallbacks_On3dEngineRedrawnData__eye_set(arg1, arg2.Swigcptr()) +} + +var _wrap_coreCallbacks_On3dEngineRedrawnData__eye_get unsafe.Pointer + +func _swig_wrap_coreCallbacks_On3dEngineRedrawnData__eye_get(base SwigcptrCoreCallbacks_On3dEngineRedrawnData) (_ SwigcptrCorePoint3d) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_coreCallbacks_On3dEngineRedrawnData__eye_get, _swig_p) + return +} + +func (arg1 SwigcptrCoreCallbacks_On3dEngineRedrawnData) GetX_eye() (_swig_ret CorePoint3d) { + return _swig_wrap_coreCallbacks_On3dEngineRedrawnData__eye_get(arg1) +} + +var _wrap_coreCallbacks_On3dEngineRedrawnData__at_set unsafe.Pointer + +func _swig_wrap_coreCallbacks_On3dEngineRedrawnData__at_set(base SwigcptrCoreCallbacks_On3dEngineRedrawnData, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_coreCallbacks_On3dEngineRedrawnData__at_set, _swig_p) + return +} + +func (arg1 SwigcptrCoreCallbacks_On3dEngineRedrawnData) SetX_at(arg2 CorePoint3d) { + _swig_wrap_coreCallbacks_On3dEngineRedrawnData__at_set(arg1, arg2.Swigcptr()) +} + +var _wrap_coreCallbacks_On3dEngineRedrawnData__at_get unsafe.Pointer + +func _swig_wrap_coreCallbacks_On3dEngineRedrawnData__at_get(base SwigcptrCoreCallbacks_On3dEngineRedrawnData) (_ SwigcptrCorePoint3d) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_coreCallbacks_On3dEngineRedrawnData__at_get, _swig_p) + return +} + +func (arg1 SwigcptrCoreCallbacks_On3dEngineRedrawnData) GetX_at() (_swig_ret CorePoint3d) { + return _swig_wrap_coreCallbacks_On3dEngineRedrawnData__at_get(arg1) +} + +var _wrap_new_coreCallbacks_On3dEngineRedrawnData unsafe.Pointer + +func _swig_wrap_new_coreCallbacks_On3dEngineRedrawnData() (base SwigcptrCoreCallbacks_On3dEngineRedrawnData) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_coreCallbacks_On3dEngineRedrawnData, _swig_p) + return +} + +func NewCoreCallbacks_On3dEngineRedrawnData() (_swig_ret CoreCallbacks_On3dEngineRedrawnData) { + return _swig_wrap_new_coreCallbacks_On3dEngineRedrawnData() +} + +var _wrap_delete_coreCallbacks_On3dEngineRedrawnData unsafe.Pointer + +func _swig_wrap_delete_coreCallbacks_On3dEngineRedrawnData(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_coreCallbacks_On3dEngineRedrawnData, _swig_p) + return +} + +func DeleteCoreCallbacks_On3dEngineRedrawnData(arg1 CoreCallbacks_On3dEngineRedrawnData) { + _swig_wrap_delete_coreCallbacks_On3dEngineRedrawnData(arg1.Swigcptr()) +} + +type CoreCallbacks_On3dEngineRedrawnData interface { + Swigcptr() uintptr + SwigIsCoreCallbacks_On3dEngineRedrawnData() + DirectorInterface() interface{} + SetX_eye(arg2 CorePoint3d) + GetX_eye() (_swig_ret CorePoint3d) + SetX_at(arg2 CorePoint3d) + GetX_at() (_swig_ret CorePoint3d) +} + +type SwigcptrCoreCallbacksOn3dEngineRedrawnData uintptr + +func (p SwigcptrCoreCallbacksOn3dEngineRedrawnData) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrCoreCallbacksOn3dEngineRedrawnData) SwigIsCoreCallbacksOn3dEngineRedrawnData() { +} + +func (p SwigcptrCoreCallbacksOn3dEngineRedrawnData) DirectorInterface() interface{} { + return nil +} + +var _wrap_coreCallbacksOn3dEngineRedrawnData__eye_set unsafe.Pointer + +func _swig_wrap_coreCallbacksOn3dEngineRedrawnData__eye_set(base SwigcptrCoreCallbacksOn3dEngineRedrawnData, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_coreCallbacksOn3dEngineRedrawnData__eye_set, _swig_p) + return +} + +func (arg1 SwigcptrCoreCallbacksOn3dEngineRedrawnData) SetX_eye(arg2 CorePoint3d) { + _swig_wrap_coreCallbacksOn3dEngineRedrawnData__eye_set(arg1, arg2.Swigcptr()) +} + +var _wrap_coreCallbacksOn3dEngineRedrawnData__eye_get unsafe.Pointer + +func _swig_wrap_coreCallbacksOn3dEngineRedrawnData__eye_get(base SwigcptrCoreCallbacksOn3dEngineRedrawnData) (_ SwigcptrCorePoint3d) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_coreCallbacksOn3dEngineRedrawnData__eye_get, _swig_p) + return +} + +func (arg1 SwigcptrCoreCallbacksOn3dEngineRedrawnData) GetX_eye() (_swig_ret CorePoint3d) { + return _swig_wrap_coreCallbacksOn3dEngineRedrawnData__eye_get(arg1) +} + +var _wrap_coreCallbacksOn3dEngineRedrawnData__at_set unsafe.Pointer + +func _swig_wrap_coreCallbacksOn3dEngineRedrawnData__at_set(base SwigcptrCoreCallbacksOn3dEngineRedrawnData, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_coreCallbacksOn3dEngineRedrawnData__at_set, _swig_p) + return +} + +func (arg1 SwigcptrCoreCallbacksOn3dEngineRedrawnData) SetX_at(arg2 CorePoint3d) { + _swig_wrap_coreCallbacksOn3dEngineRedrawnData__at_set(arg1, arg2.Swigcptr()) +} + +var _wrap_coreCallbacksOn3dEngineRedrawnData__at_get unsafe.Pointer + +func _swig_wrap_coreCallbacksOn3dEngineRedrawnData__at_get(base SwigcptrCoreCallbacksOn3dEngineRedrawnData) (_ SwigcptrCorePoint3d) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_coreCallbacksOn3dEngineRedrawnData__at_get, _swig_p) + return +} + +func (arg1 SwigcptrCoreCallbacksOn3dEngineRedrawnData) GetX_at() (_swig_ret CorePoint3d) { + return _swig_wrap_coreCallbacksOn3dEngineRedrawnData__at_get(arg1) +} + +var _wrap_new_coreCallbacksOn3dEngineRedrawnData unsafe.Pointer + +func _swig_wrap_new_coreCallbacksOn3dEngineRedrawnData() (base SwigcptrCoreCallbacksOn3dEngineRedrawnData) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_coreCallbacksOn3dEngineRedrawnData, _swig_p) + return +} + +func NewCoreCallbacksOn3dEngineRedrawnData() (_swig_ret CoreCallbacksOn3dEngineRedrawnData) { + return _swig_wrap_new_coreCallbacksOn3dEngineRedrawnData() +} + +var _wrap_delete_coreCallbacksOn3dEngineRedrawnData unsafe.Pointer + +func _swig_wrap_delete_coreCallbacksOn3dEngineRedrawnData(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_coreCallbacksOn3dEngineRedrawnData, _swig_p) + return +} + +func DeleteCoreCallbacksOn3dEngineRedrawnData(arg1 CoreCallbacksOn3dEngineRedrawnData) { + _swig_wrap_delete_coreCallbacksOn3dEngineRedrawnData(arg1.Swigcptr()) +} + +type CoreCallbacksOn3dEngineRedrawnData interface { + Swigcptr() uintptr + SwigIsCoreCallbacksOn3dEngineRedrawnData() + DirectorInterface() interface{} + SetX_eye(arg2 CorePoint3d) + GetX_eye() (_swig_ret CorePoint3d) + SetX_at(arg2 CorePoint3d) + GetX_at() (_swig_ret CorePoint3d) +} + +type _swig_DirectorCoreCallbacks struct { + SwigcptrCoreCallbacks + v interface{} +} + +func (p *_swig_DirectorCoreCallbacks) Swigcptr() uintptr { + return p.SwigcptrCoreCallbacks.Swigcptr() +} + +func (p *_swig_DirectorCoreCallbacks) SwigIsCoreCallbacks() { +} + +func (p *_swig_DirectorCoreCallbacks) DirectorInterface() interface{} { + return p.v +} + +var _wrap__swig_NewDirectorCoreCallbacksCoreCallbacks unsafe.Pointer + +func _swig_NewDirectorCoreCallbacksCoreCallbacks(_swig_director *_swig_DirectorCoreCallbacks) (_swig_ret SwigcptrCoreCallbacks) { + _swig_p := uintptr(unsafe.Pointer(&_swig_director)) + _cgo_runtime_cgocall(_wrap__swig_NewDirectorCoreCallbacksCoreCallbacks, _swig_p) + return +} + +func NewDirectorCoreCallbacks(v interface{}) CoreCallbacks { + p := &_swig_DirectorCoreCallbacks{0, v} + p.SwigcptrCoreCallbacks = _swig_NewDirectorCoreCallbacksCoreCallbacks(p) + return p +} + +var _wrap_DeleteDirectorCoreCallbacks unsafe.Pointer + +func _swig_wrap_DeleteDirectorCoreCallbacks(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_DeleteDirectorCoreCallbacks, _swig_p) + return +} + +func DeleteDirectorCoreCallbacks(arg1 CoreCallbacks) { + _swig_wrap_DeleteDirectorCoreCallbacks(arg1.Swigcptr()) +} + +func Swiggo_DeleteDirector_coreCallbacks(p *_swig_DirectorCoreCallbacks) { + p.SwigcptrCoreCallbacks = 0 +} + +type _swig_DirectorInterfaceCoreCallbacksOn3dEngineRedrawn interface { + On3dEngineRedrawn(CoreCallbacks_On3dEngineRedrawnData) +} + +var _wrap__swig_DirectorCoreCallbacks_upcall_On3dEngineRedrawn unsafe.Pointer + +func _swig_wrap__swig_DirectorCoreCallbacks_upcall_On3dEngineRedrawn(_swig_ptr SwigcptrCoreCallbacks, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) + _cgo_runtime_cgocall(_wrap__swig_DirectorCoreCallbacks_upcall_On3dEngineRedrawn, _swig_p) + return +} + +func (swig_p *_swig_DirectorCoreCallbacks) On3dEngineRedrawn(data CoreCallbacks_On3dEngineRedrawnData) { + if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceCoreCallbacksOn3dEngineRedrawn); swig_ok { + swig_g.On3dEngineRedrawn(data) + return + } + _swig_wrap__swig_DirectorCoreCallbacks_upcall_On3dEngineRedrawn(swig_p.SwigcptrCoreCallbacks, data.Swigcptr()) +} + +func DirectorCoreCallbacksOn3dEngineRedrawn(p CoreCallbacks, arg2 CoreCallbacks_On3dEngineRedrawnData) { + _swig_wrap__swig_DirectorCoreCallbacks_upcall_On3dEngineRedrawn(p.(*_swig_DirectorCoreCallbacks).SwigcptrCoreCallbacks, arg2.Swigcptr()) +} + +func Swig_DirectorCoreCallbacks_callback_On3dEngineRedrawn(p *_swig_DirectorCoreCallbacks, arg2 uintptr) { + p.On3dEngineRedrawn(SwigcptrCoreCallbacks_On3dEngineRedrawnData(arg2)) +} + +type _swig_DirectorInterfaceCoreCallbacksOn3dEngineRedrawn2 interface { + On3dEngineRedrawn2(CoreCallbacksOn3dEngineRedrawnData) +} + +var _wrap__swig_DirectorCoreCallbacks_upcall_On3dEngineRedrawn2 unsafe.Pointer + +func _swig_wrap__swig_DirectorCoreCallbacks_upcall_On3dEngineRedrawn2(_swig_ptr SwigcptrCoreCallbacks, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) + _cgo_runtime_cgocall(_wrap__swig_DirectorCoreCallbacks_upcall_On3dEngineRedrawn2, _swig_p) + return +} + +func (swig_p *_swig_DirectorCoreCallbacks) On3dEngineRedrawn2(data CoreCallbacksOn3dEngineRedrawnData) { + if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceCoreCallbacksOn3dEngineRedrawn2); swig_ok { + swig_g.On3dEngineRedrawn2(data) + return + } + _swig_wrap__swig_DirectorCoreCallbacks_upcall_On3dEngineRedrawn2(swig_p.SwigcptrCoreCallbacks, data.Swigcptr()) +} + +func DirectorCoreCallbacksOn3dEngineRedrawn2(p CoreCallbacks, arg2 CoreCallbacksOn3dEngineRedrawnData) { + _swig_wrap__swig_DirectorCoreCallbacks_upcall_On3dEngineRedrawn2(p.(*_swig_DirectorCoreCallbacks).SwigcptrCoreCallbacks, arg2.Swigcptr()) +} + +func Swig_DirectorCoreCallbacks_callback_On3dEngineRedrawn2(p *_swig_DirectorCoreCallbacks, arg2 uintptr) { + p.On3dEngineRedrawn2(SwigcptrCoreCallbacksOn3dEngineRedrawnData(arg2)) +} + +type SwigcptrCoreCallbacks uintptr + +func (p SwigcptrCoreCallbacks) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrCoreCallbacks) SwigIsCoreCallbacks() { +} + +func (p SwigcptrCoreCallbacks) DirectorInterface() interface{} { + return nil +} + +var _wrap_new_coreCallbacks unsafe.Pointer + +func _swig_wrap_new_coreCallbacks() (base SwigcptrCoreCallbacks) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_coreCallbacks, _swig_p) + return +} + +func NewCoreCallbacks() (_swig_ret CoreCallbacks) { + return _swig_wrap_new_coreCallbacks() +} + +var _wrap_delete_coreCallbacks unsafe.Pointer + +func _swig_wrap_delete_coreCallbacks(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_coreCallbacks, _swig_p) + return +} + +func DeleteCoreCallbacks(arg1 CoreCallbacks) { + _swig_wrap_delete_coreCallbacks(arg1.Swigcptr()) +} + +var _wrap_coreCallbacks_On3dEngineRedrawn unsafe.Pointer + +func _swig_wrap_coreCallbacks_On3dEngineRedrawn(base SwigcptrCoreCallbacks, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_coreCallbacks_On3dEngineRedrawn, _swig_p) + return +} + +func (arg1 SwigcptrCoreCallbacks) On3dEngineRedrawn(arg2 CoreCallbacks_On3dEngineRedrawnData) { + _swig_wrap_coreCallbacks_On3dEngineRedrawn(arg1, arg2.Swigcptr()) +} + +var _wrap_coreCallbacks_On3dEngineRedrawn2 unsafe.Pointer + +func _swig_wrap_coreCallbacks_On3dEngineRedrawn2(base SwigcptrCoreCallbacks, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_coreCallbacks_On3dEngineRedrawn2, _swig_p) + return +} + +func (arg1 SwigcptrCoreCallbacks) On3dEngineRedrawn2(arg2 CoreCallbacksOn3dEngineRedrawnData) { + _swig_wrap_coreCallbacks_On3dEngineRedrawn2(arg1, arg2.Swigcptr()) +} + +type CoreCallbacks interface { + Swigcptr() uintptr + SwigIsCoreCallbacks() + DirectorInterface() interface{} + On3dEngineRedrawn(arg2 CoreCallbacks_On3dEngineRedrawnData) + On3dEngineRedrawn2(arg2 CoreCallbacksOn3dEngineRedrawnData) +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + +type SwigcptrSwigDirector_coreCallbacks uintptr +type SwigDirector_coreCallbacks interface { + Swigcptr() uintptr; +} +func (p SwigcptrSwigDirector_coreCallbacks) Swigcptr() uintptr { + return uintptr(p) +} + +type SwigcptrSwigDirector_Ops uintptr +type SwigDirector_Ops interface { + Swigcptr() uintptr; +} +func (p SwigcptrSwigDirector_Ops) Swigcptr() uintptr { + return uintptr(p) +} + +type SwigcptrSwigDirector_Charlie uintptr +type SwigDirector_Charlie interface { + Swigcptr() uintptr; +} +func (p SwigcptrSwigDirector_Charlie) Swigcptr() uintptr { + return uintptr(p) +} + +type SwigcptrSwigDirector_Delta uintptr +type SwigDirector_Delta interface { + Swigcptr() uintptr; +} +func (p SwigcptrSwigDirector_Delta) Swigcptr() uintptr { + return uintptr(p) +} + +type SwigcptrSwigDirector_Prims uintptr +type SwigDirector_Prims interface { + Swigcptr() uintptr; +} +func (p SwigcptrSwigDirector_Prims) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/director_frob_runme b/Examples/test-suite/go/director_frob_runme new file mode 100755 index 000000000..131e34611 Binary files /dev/null and b/Examples/test-suite/go/director_frob_runme differ diff --git a/Examples/test-suite/go/director_frob_wrap.h b/Examples/test-suite/go/director_frob_wrap.h new file mode 100644 index 000000000..fe4800b67 --- /dev/null +++ b/Examples/test-suite/go/director_frob_wrap.h @@ -0,0 +1,120 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../director_frob.i + +#ifndef SWIG_director_frob_WRAP_H_ +#define SWIG_director_frob_WRAP_H_ + +class SwigDirector_Alpha : public Alpha +{ + public: + SwigDirector_Alpha(void *swig_p); + virtual ~SwigDirector_Alpha(); + virtual char const *abs_method(); + private: + void *go_val; +}; + +class SwigDirector_Bravo : public Bravo +{ + public: + SwigDirector_Bravo(void *swig_p); + virtual ~SwigDirector_Bravo(); + private: + void *go_val; +}; + +class SwigDirector_Charlie : public Charlie +{ + public: + SwigDirector_Charlie(void *swig_p); + virtual ~SwigDirector_Charlie(); + char const *_swig_upcall_abs_method() { + return Charlie::abs_method(); + } + virtual char const *abs_method(); + private: + void *go_val; +}; + +class SwigDirector_Delta : public Delta +{ + public: + SwigDirector_Delta(void *swig_p); + virtual ~SwigDirector_Delta(); + char const *_swig_upcall_abs_method() { + return Charlie::abs_method(); + } + virtual char const *abs_method(); + private: + void *go_val; +}; + +class SwigDirector_Ops : public Ops +{ + public: + SwigDirector_Ops(void *swig_p); + virtual ~SwigDirector_Ops(); + int _swig_upcall_OpInt() { + return Ops::operator int(); + } + virtual operator int(); + int **_swig_upcall_OpIntStarStarConst() const { + return Ops::operator int**(); + } + virtual operator int**() const; + int &_swig_upcall_OpIntAmp() { + return Ops::operator int&(); + } + virtual operator int&(); + void *_swig_upcall_OpIntStar() { + return Ops::operator void*(); + } + virtual operator void*(); + int const *_swig_upcall_OpConstIntIntStar() { + return Ops::operator const int*(); + } + virtual operator const int*(); + private: + void *go_val; +}; + +class SwigDirector_Prims : public Prims +{ + public: + SwigDirector_Prims(void *swig_p); + virtual ~SwigDirector_Prims(); + unsigned long long _swig_upcall_ull(unsigned long long i, unsigned long long j) { + return Prims::ull(i,j); + } + virtual unsigned long long ull(unsigned long long i, unsigned long long j); + private: + void *go_val; +}; + +class SwigDirector_coreCallbacks : public coreCallbacks +{ + public: + SwigDirector_coreCallbacks(void *swig_p); + virtual ~SwigDirector_coreCallbacks(); + void _swig_upcall_On3dEngineRedrawn(coreCallbacks_On3dEngineRedrawnData const &data) { + coreCallbacks::On3dEngineRedrawn(data); + } + virtual void On3dEngineRedrawn(coreCallbacks_On3dEngineRedrawnData const &data); + void _swig_upcall_On3dEngineRedrawn2(coreCallbacksOn3dEngineRedrawnData const &data) { + coreCallbacks::On3dEngineRedrawn2(data); + } + virtual void On3dEngineRedrawn2(coreCallbacksOn3dEngineRedrawnData const &data); + private: + void *go_val; +}; + +#endif diff --git a/Examples/test-suite/go/director_ignore.go b/Examples/test-suite/go/director_ignore.go new file mode 100644 index 000000000..e100eca26 --- /dev/null +++ b/Examples/test-suite/go/director_ignore.go @@ -0,0 +1,810 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../director_ignore.i + +package director_ignore + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type _swig_DirectorDIgnores struct { + SwigcptrDIgnores + v interface{} +} + +func (p *_swig_DirectorDIgnores) Swigcptr() uintptr { + return p.SwigcptrDIgnores.Swigcptr() +} + +func (p *_swig_DirectorDIgnores) SwigIsDIgnores() { +} + +func (p *_swig_DirectorDIgnores) DirectorInterface() interface{} { + return p.v +} + +var _wrap__swig_NewDirectorDIgnoresDIgnores unsafe.Pointer + +func _swig_NewDirectorDIgnoresDIgnores(_swig_director *_swig_DirectorDIgnores) (_swig_ret SwigcptrDIgnores) { + _swig_p := uintptr(unsafe.Pointer(&_swig_director)) + _cgo_runtime_cgocall(_wrap__swig_NewDirectorDIgnoresDIgnores, _swig_p) + return +} + +func NewDirectorDIgnores(v interface{}) DIgnores { + p := &_swig_DirectorDIgnores{0, v} + p.SwigcptrDIgnores = _swig_NewDirectorDIgnoresDIgnores(p) + return p +} + +var _wrap_DeleteDirectorDIgnores unsafe.Pointer + +func _swig_wrap_DeleteDirectorDIgnores(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_DeleteDirectorDIgnores, _swig_p) + return +} + +func DeleteDirectorDIgnores(arg1 DIgnores) { + _swig_wrap_DeleteDirectorDIgnores(arg1.Swigcptr()) +} + +func Swiggo_DeleteDirector_DIgnores(p *_swig_DirectorDIgnores) { + p.SwigcptrDIgnores = 0 +} + +type _swig_DirectorInterfaceDIgnoresOverloadedMethod interface { + OverloadedMethod(bool) +} + +var _wrap__swig_DirectorDIgnores_upcall_OverloadedMethod unsafe.Pointer + +func _swig_wrap__swig_DirectorDIgnores_upcall_OverloadedMethod(_swig_ptr SwigcptrDIgnores, _ bool) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) + _cgo_runtime_cgocall(_wrap__swig_DirectorDIgnores_upcall_OverloadedMethod, _swig_p) + return +} + +func (swig_p *_swig_DirectorDIgnores) OverloadedMethod(b bool) { + if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceDIgnoresOverloadedMethod); swig_ok { + swig_g.OverloadedMethod(b) + return + } + _swig_wrap__swig_DirectorDIgnores_upcall_OverloadedMethod(swig_p.SwigcptrDIgnores, b) +} + +func DirectorDIgnoresOverloadedMethod(p DIgnores, arg2 bool) { + _swig_wrap__swig_DirectorDIgnores_upcall_OverloadedMethod(p.(*_swig_DirectorDIgnores).SwigcptrDIgnores, arg2) +} + +func Swig_DirectorDIgnores_callback_OverloadedMethod(p *_swig_DirectorDIgnores, arg2 bool) { + p.OverloadedMethod(arg2) +} + +type _swig_DirectorInterfaceDIgnoresTriple interface { + Triple(int) int +} + +var _wrap__swig_DirectorDIgnores_upcall_Triple unsafe.Pointer + +func _swig_wrap__swig_DirectorDIgnores_upcall_Triple(_swig_ptr SwigcptrDIgnores, _ int) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) + _cgo_runtime_cgocall(_wrap__swig_DirectorDIgnores_upcall_Triple, _swig_p) + return +} + +func (swig_p *_swig_DirectorDIgnores) Triple(n int) int { + if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceDIgnoresTriple); swig_ok { + return swig_g.Triple(n) + } + var swig_r int + swig_r = _swig_wrap__swig_DirectorDIgnores_upcall_Triple(swig_p.SwigcptrDIgnores, n) + return swig_r +} + +func DirectorDIgnoresTriple(p DIgnores, arg2 int) int { + var swig_r int + swig_r = _swig_wrap__swig_DirectorDIgnores_upcall_Triple(p.(*_swig_DirectorDIgnores).SwigcptrDIgnores, arg2) + return swig_r +} + +func Swig_DirectorDIgnores_callback_Triple(p *_swig_DirectorDIgnores, arg2 int) (swig_result int) { + var swig_r int + swig_r = p.Triple(arg2) + return swig_r +} + +type _swig_DirectorInterfaceDIgnoresTempMethod interface { + TempMethod() +} + +func (swig_p *_swig_DirectorDIgnores) TempMethod() { + if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceDIgnoresTempMethod); swig_ok { + swig_g.TempMethod() + return + } + panic("call to pure virtual method") +} + +func Swig_DirectorDIgnores_callback_TempMethod(p *_swig_DirectorDIgnores) { + p.TempMethod() +} + +type _swig_DirectorInterfaceDIgnoresOverloadedProtectedMethod interface { + OverloadedProtectedMethod() +} + +var _wrap__swig_DirectorDIgnores_upcall_OverloadedProtectedMethod unsafe.Pointer + +func _swig_wrap__swig_DirectorDIgnores_upcall_OverloadedProtectedMethod(_swig_ptr SwigcptrDIgnores) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) + _cgo_runtime_cgocall(_wrap__swig_DirectorDIgnores_upcall_OverloadedProtectedMethod, _swig_p) + return +} + +func (swig_p *_swig_DirectorDIgnores) OverloadedProtectedMethod() { + if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceDIgnoresOverloadedProtectedMethod); swig_ok { + swig_g.OverloadedProtectedMethod() + return + } + _swig_wrap__swig_DirectorDIgnores_upcall_OverloadedProtectedMethod(swig_p.SwigcptrDIgnores) +} + +func DirectorDIgnoresOverloadedProtectedMethod(p DIgnores) { + _swig_wrap__swig_DirectorDIgnores_upcall_OverloadedProtectedMethod(p.(*_swig_DirectorDIgnores).SwigcptrDIgnores) +} + +func Swig_DirectorDIgnores_callback_OverloadedProtectedMethod(p *_swig_DirectorDIgnores) { + p.OverloadedProtectedMethod() +} + +type SwigcptrDIgnores uintptr + +func (p SwigcptrDIgnores) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrDIgnores) SwigIsDIgnores() { +} + +func (p SwigcptrDIgnores) DirectorInterface() interface{} { + return nil +} + +var _wrap_delete_DIgnores unsafe.Pointer + +func _swig_wrap_delete_DIgnores(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_DIgnores, _swig_p) + return +} + +func DeleteDIgnores(arg1 DIgnores) { + _swig_wrap_delete_DIgnores(arg1.Swigcptr()) +} + +var _wrap_DIgnores_OverloadedMethod unsafe.Pointer + +func _swig_wrap_DIgnores_OverloadedMethod(base SwigcptrDIgnores, _ bool) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_DIgnores_OverloadedMethod, _swig_p) + return +} + +func (arg1 SwigcptrDIgnores) OverloadedMethod(arg2 bool) { + _swig_wrap_DIgnores_OverloadedMethod(arg1, arg2) +} + +var _wrap_DIgnores_Triple unsafe.Pointer + +func _swig_wrap_DIgnores_Triple(base SwigcptrDIgnores, _ int) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_DIgnores_Triple, _swig_p) + return +} + +func (arg1 SwigcptrDIgnores) Triple(arg2 int) (_swig_ret int) { + return _swig_wrap_DIgnores_Triple(arg1, arg2) +} + +var _wrap_DIgnores_TempMethod unsafe.Pointer + +func _swig_wrap_DIgnores_TempMethod(base SwigcptrDIgnores) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_DIgnores_TempMethod, _swig_p) + return +} + +func (arg1 SwigcptrDIgnores) TempMethod() { + _swig_wrap_DIgnores_TempMethod(arg1) +} + +var _wrap_new_DIgnores unsafe.Pointer + +func _swig_wrap_new_DIgnores() (base SwigcptrDIgnores) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_DIgnores, _swig_p) + return +} + +func NewDIgnores() (_swig_ret DIgnores) { + return _swig_wrap_new_DIgnores() +} + +type DIgnores interface { + Swigcptr() uintptr + SwigIsDIgnores() + DirectorInterface() interface{} + OverloadedMethod(arg2 bool) + Triple(arg2 int) (_swig_ret int) + TempMethod() +} + +type _swig_DirectorDAbstractIgnores struct { + SwigcptrDAbstractIgnores + v interface{} +} + +func (p *_swig_DirectorDAbstractIgnores) Swigcptr() uintptr { + return p.SwigcptrDAbstractIgnores.Swigcptr() +} + +func (p *_swig_DirectorDAbstractIgnores) SwigIsDAbstractIgnores() { +} + +func (p *_swig_DirectorDAbstractIgnores) DirectorInterface() interface{} { + return p.v +} + +var _wrap__swig_NewDirectorDAbstractIgnoresDAbstractIgnores unsafe.Pointer + +func _swig_NewDirectorDAbstractIgnoresDAbstractIgnores(_swig_director *_swig_DirectorDAbstractIgnores) (_swig_ret SwigcptrDAbstractIgnores) { + _swig_p := uintptr(unsafe.Pointer(&_swig_director)) + _cgo_runtime_cgocall(_wrap__swig_NewDirectorDAbstractIgnoresDAbstractIgnores, _swig_p) + return +} + +func NewDirectorDAbstractIgnores(v interface{}) DAbstractIgnores { + p := &_swig_DirectorDAbstractIgnores{0, v} + p.SwigcptrDAbstractIgnores = _swig_NewDirectorDAbstractIgnoresDAbstractIgnores(p) + return p +} + +var _wrap_DeleteDirectorDAbstractIgnores unsafe.Pointer + +func _swig_wrap_DeleteDirectorDAbstractIgnores(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_DeleteDirectorDAbstractIgnores, _swig_p) + return +} + +func DeleteDirectorDAbstractIgnores(arg1 DAbstractIgnores) { + _swig_wrap_DeleteDirectorDAbstractIgnores(arg1.Swigcptr()) +} + +func Swiggo_DeleteDirector_DAbstractIgnores(p *_swig_DirectorDAbstractIgnores) { + p.SwigcptrDAbstractIgnores = 0 +} + +type _swig_DirectorInterfaceDAbstractIgnoresOverloadedMethod interface { + OverloadedMethod(bool) float64 +} + +func (swig_p *_swig_DirectorDAbstractIgnores) OverloadedMethod(b bool) float64 { + if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceDAbstractIgnoresOverloadedMethod); swig_ok { + return swig_g.OverloadedMethod(b) + } + panic("call to pure virtual method") +} + +func Swig_DirectorDAbstractIgnores_callback_OverloadedMethod(p *_swig_DirectorDAbstractIgnores, b bool) (swig_result float64) { + var swig_r float64 + swig_r = p.OverloadedMethod(b) + return swig_r +} + +type _swig_DirectorInterfaceDAbstractIgnoresQuadruple interface { + Quadruple(int) int +} + +var _wrap__swig_DirectorDAbstractIgnores_upcall_Quadruple unsafe.Pointer + +func _swig_wrap__swig_DirectorDAbstractIgnores_upcall_Quadruple(_swig_ptr SwigcptrDAbstractIgnores, _ int) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) + _cgo_runtime_cgocall(_wrap__swig_DirectorDAbstractIgnores_upcall_Quadruple, _swig_p) + return +} + +func (swig_p *_swig_DirectorDAbstractIgnores) Quadruple(n int) int { + if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceDAbstractIgnoresQuadruple); swig_ok { + return swig_g.Quadruple(n) + } + var swig_r int + swig_r = _swig_wrap__swig_DirectorDAbstractIgnores_upcall_Quadruple(swig_p.SwigcptrDAbstractIgnores, n) + return swig_r +} + +func DirectorDAbstractIgnoresQuadruple(p DAbstractIgnores, arg2 int) int { + var swig_r int + swig_r = _swig_wrap__swig_DirectorDAbstractIgnores_upcall_Quadruple(p.(*_swig_DirectorDAbstractIgnores).SwigcptrDAbstractIgnores, arg2) + return swig_r +} + +func Swig_DirectorDAbstractIgnores_callback_Quadruple(p *_swig_DirectorDAbstractIgnores, arg2 int) (swig_result int) { + var swig_r int + swig_r = p.Quadruple(arg2) + return swig_r +} + +type _swig_DirectorInterfaceDAbstractIgnoresOverloadedProtectedMethod interface { + OverloadedProtectedMethod() float64 +} + +func (swig_p *_swig_DirectorDAbstractIgnores) OverloadedProtectedMethod() float64 { + if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceDAbstractIgnoresOverloadedProtectedMethod); swig_ok { + return swig_g.OverloadedProtectedMethod() + } + panic("call to pure virtual method") +} + +func Swig_DirectorDAbstractIgnores_callback_OverloadedProtectedMethod(p *_swig_DirectorDAbstractIgnores) (swig_result float64) { + var swig_r float64 + swig_r = p.OverloadedProtectedMethod() + return swig_r +} + +type SwigcptrDAbstractIgnores uintptr + +func (p SwigcptrDAbstractIgnores) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrDAbstractIgnores) SwigIsDAbstractIgnores() { +} + +func (p SwigcptrDAbstractIgnores) DirectorInterface() interface{} { + return nil +} + +var _wrap_delete_DAbstractIgnores unsafe.Pointer + +func _swig_wrap_delete_DAbstractIgnores(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_DAbstractIgnores, _swig_p) + return +} + +func DeleteDAbstractIgnores(arg1 DAbstractIgnores) { + _swig_wrap_delete_DAbstractIgnores(arg1.Swigcptr()) +} + +var _wrap_DAbstractIgnores_OverloadedMethod unsafe.Pointer + +func _swig_wrap_DAbstractIgnores_OverloadedMethod(base SwigcptrDAbstractIgnores, _ bool) (_ float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_DAbstractIgnores_OverloadedMethod, _swig_p) + return +} + +func (arg1 SwigcptrDAbstractIgnores) OverloadedMethod(arg2 bool) (_swig_ret float64) { + return _swig_wrap_DAbstractIgnores_OverloadedMethod(arg1, arg2) +} + +var _wrap_DAbstractIgnores_Quadruple unsafe.Pointer + +func _swig_wrap_DAbstractIgnores_Quadruple(base SwigcptrDAbstractIgnores, _ int) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_DAbstractIgnores_Quadruple, _swig_p) + return +} + +func (arg1 SwigcptrDAbstractIgnores) Quadruple(arg2 int) (_swig_ret int) { + return _swig_wrap_DAbstractIgnores_Quadruple(arg1, arg2) +} + +var _wrap_new_DAbstractIgnores unsafe.Pointer + +func _swig_wrap_new_DAbstractIgnores() (base SwigcptrDAbstractIgnores) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_DAbstractIgnores, _swig_p) + return +} + +func NewDAbstractIgnores() (_swig_ret DAbstractIgnores) { + return _swig_wrap_new_DAbstractIgnores() +} + +type DAbstractIgnores interface { + Swigcptr() uintptr + SwigIsDAbstractIgnores() + DirectorInterface() interface{} + OverloadedMethod(arg2 bool) (_swig_ret float64) + Quadruple(arg2 int) (_swig_ret int) +} + +type _swig_DirectorDTemplateAbstractIgnoresInt struct { + SwigcptrDTemplateAbstractIgnoresInt + v interface{} +} + +func (p *_swig_DirectorDTemplateAbstractIgnoresInt) Swigcptr() uintptr { + return p.SwigcptrDTemplateAbstractIgnoresInt.Swigcptr() +} + +func (p *_swig_DirectorDTemplateAbstractIgnoresInt) SwigIsDTemplateAbstractIgnoresInt() { +} + +func (p *_swig_DirectorDTemplateAbstractIgnoresInt) DirectorInterface() interface{} { + return p.v +} + +var _wrap__swig_NewDirectorDTemplateAbstractIgnoresIntDTemplateAbstractIgnoresInt unsafe.Pointer + +func _swig_NewDirectorDTemplateAbstractIgnoresIntDTemplateAbstractIgnoresInt(_swig_director *_swig_DirectorDTemplateAbstractIgnoresInt) (_swig_ret SwigcptrDTemplateAbstractIgnoresInt) { + _swig_p := uintptr(unsafe.Pointer(&_swig_director)) + _cgo_runtime_cgocall(_wrap__swig_NewDirectorDTemplateAbstractIgnoresIntDTemplateAbstractIgnoresInt, _swig_p) + return +} + +func NewDirectorDTemplateAbstractIgnoresInt(v interface{}) DTemplateAbstractIgnoresInt { + p := &_swig_DirectorDTemplateAbstractIgnoresInt{0, v} + p.SwigcptrDTemplateAbstractIgnoresInt = _swig_NewDirectorDTemplateAbstractIgnoresIntDTemplateAbstractIgnoresInt(p) + return p +} + +var _wrap_DeleteDirectorDTemplateAbstractIgnoresInt unsafe.Pointer + +func _swig_wrap_DeleteDirectorDTemplateAbstractIgnoresInt(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_DeleteDirectorDTemplateAbstractIgnoresInt, _swig_p) + return +} + +func DeleteDirectorDTemplateAbstractIgnoresInt(arg1 DTemplateAbstractIgnoresInt) { + _swig_wrap_DeleteDirectorDTemplateAbstractIgnoresInt(arg1.Swigcptr()) +} + +func Swiggo_DeleteDirector_DTemplateAbstractIgnoresInt(p *_swig_DirectorDTemplateAbstractIgnoresInt) { + p.SwigcptrDTemplateAbstractIgnoresInt = 0 +} + +type _swig_DirectorInterfaceDTemplateAbstractIgnoresIntOverloadedMethod interface { + OverloadedMethod(bool) float64 +} + +func (swig_p *_swig_DirectorDTemplateAbstractIgnoresInt) OverloadedMethod(b bool) float64 { + if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceDTemplateAbstractIgnoresIntOverloadedMethod); swig_ok { + return swig_g.OverloadedMethod(b) + } + panic("call to pure virtual method") +} + +func Swig_DirectorDTemplateAbstractIgnoresInt_callback_OverloadedMethod(p *_swig_DirectorDTemplateAbstractIgnoresInt, b bool) (swig_result float64) { + var swig_r float64 + swig_r = p.OverloadedMethod(b) + return swig_r +} + +type _swig_DirectorInterfaceDTemplateAbstractIgnoresIntQuadruple interface { + Quadruple(int) int +} + +var _wrap__swig_DirectorDTemplateAbstractIgnoresInt_upcall_Quadruple unsafe.Pointer + +func _swig_wrap__swig_DirectorDTemplateAbstractIgnoresInt_upcall_Quadruple(_swig_ptr SwigcptrDTemplateAbstractIgnoresInt, _ int) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) + _cgo_runtime_cgocall(_wrap__swig_DirectorDTemplateAbstractIgnoresInt_upcall_Quadruple, _swig_p) + return +} + +func (swig_p *_swig_DirectorDTemplateAbstractIgnoresInt) Quadruple(n int) int { + if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceDTemplateAbstractIgnoresIntQuadruple); swig_ok { + return swig_g.Quadruple(n) + } + var swig_r int + swig_r = _swig_wrap__swig_DirectorDTemplateAbstractIgnoresInt_upcall_Quadruple(swig_p.SwigcptrDTemplateAbstractIgnoresInt, n) + return swig_r +} + +func DirectorDTemplateAbstractIgnoresIntQuadruple(p DTemplateAbstractIgnoresInt, arg2 int) int { + var swig_r int + swig_r = _swig_wrap__swig_DirectorDTemplateAbstractIgnoresInt_upcall_Quadruple(p.(*_swig_DirectorDTemplateAbstractIgnoresInt).SwigcptrDTemplateAbstractIgnoresInt, arg2) + return swig_r +} + +func Swig_DirectorDTemplateAbstractIgnoresInt_callback_Quadruple(p *_swig_DirectorDTemplateAbstractIgnoresInt, arg2 int) (swig_result int) { + var swig_r int + swig_r = p.Quadruple(arg2) + return swig_r +} + +type _swig_DirectorInterfaceDTemplateAbstractIgnoresIntOverloadedProtectedMethod interface { + OverloadedProtectedMethod() float64 +} + +func (swig_p *_swig_DirectorDTemplateAbstractIgnoresInt) OverloadedProtectedMethod() float64 { + if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceDTemplateAbstractIgnoresIntOverloadedProtectedMethod); swig_ok { + return swig_g.OverloadedProtectedMethod() + } + panic("call to pure virtual method") +} + +func Swig_DirectorDTemplateAbstractIgnoresInt_callback_OverloadedProtectedMethod(p *_swig_DirectorDTemplateAbstractIgnoresInt) (swig_result float64) { + var swig_r float64 + swig_r = p.OverloadedProtectedMethod() + return swig_r +} + +type SwigcptrDTemplateAbstractIgnoresInt uintptr + +func (p SwigcptrDTemplateAbstractIgnoresInt) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrDTemplateAbstractIgnoresInt) SwigIsDTemplateAbstractIgnoresInt() { +} + +func (p SwigcptrDTemplateAbstractIgnoresInt) DirectorInterface() interface{} { + return nil +} + +var _wrap_delete_DTemplateAbstractIgnoresInt unsafe.Pointer + +func _swig_wrap_delete_DTemplateAbstractIgnoresInt(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_DTemplateAbstractIgnoresInt, _swig_p) + return +} + +func DeleteDTemplateAbstractIgnoresInt(arg1 DTemplateAbstractIgnoresInt) { + _swig_wrap_delete_DTemplateAbstractIgnoresInt(arg1.Swigcptr()) +} + +var _wrap_DTemplateAbstractIgnoresInt_OverloadedMethod unsafe.Pointer + +func _swig_wrap_DTemplateAbstractIgnoresInt_OverloadedMethod(base SwigcptrDTemplateAbstractIgnoresInt, _ bool) (_ float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_DTemplateAbstractIgnoresInt_OverloadedMethod, _swig_p) + return +} + +func (arg1 SwigcptrDTemplateAbstractIgnoresInt) OverloadedMethod(arg2 bool) (_swig_ret float64) { + return _swig_wrap_DTemplateAbstractIgnoresInt_OverloadedMethod(arg1, arg2) +} + +var _wrap_DTemplateAbstractIgnoresInt_Quadruple unsafe.Pointer + +func _swig_wrap_DTemplateAbstractIgnoresInt_Quadruple(base SwigcptrDTemplateAbstractIgnoresInt, _ int) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_DTemplateAbstractIgnoresInt_Quadruple, _swig_p) + return +} + +func (arg1 SwigcptrDTemplateAbstractIgnoresInt) Quadruple(arg2 int) (_swig_ret int) { + return _swig_wrap_DTemplateAbstractIgnoresInt_Quadruple(arg1, arg2) +} + +var _wrap_new_DTemplateAbstractIgnoresInt unsafe.Pointer + +func _swig_wrap_new_DTemplateAbstractIgnoresInt() (base SwigcptrDTemplateAbstractIgnoresInt) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_DTemplateAbstractIgnoresInt, _swig_p) + return +} + +func NewDTemplateAbstractIgnoresInt() (_swig_ret DTemplateAbstractIgnoresInt) { + return _swig_wrap_new_DTemplateAbstractIgnoresInt() +} + +type DTemplateAbstractIgnoresInt interface { + Swigcptr() uintptr + SwigIsDTemplateAbstractIgnoresInt() + DirectorInterface() interface{} + OverloadedMethod(arg2 bool) (_swig_ret float64) + Quadruple(arg2 int) (_swig_ret int) +} + +type _swig_DirectorDIgnoreConstructor struct { + SwigcptrDIgnoreConstructor + v interface{} +} + +func (p *_swig_DirectorDIgnoreConstructor) Swigcptr() uintptr { + return p.SwigcptrDIgnoreConstructor.Swigcptr() +} + +func (p *_swig_DirectorDIgnoreConstructor) SwigIsDIgnoreConstructor() { +} + +func (p *_swig_DirectorDIgnoreConstructor) DirectorInterface() interface{} { + return p.v +} + +var _wrap__swig_NewDirectorDIgnoreConstructorDIgnoreConstructor unsafe.Pointer + +func _swig_NewDirectorDIgnoreConstructorDIgnoreConstructor(_swig_director *_swig_DirectorDIgnoreConstructor, _ string, _ int) (_swig_ret SwigcptrDIgnoreConstructor) { + _swig_p := uintptr(unsafe.Pointer(&_swig_director)) + _cgo_runtime_cgocall(_wrap__swig_NewDirectorDIgnoreConstructorDIgnoreConstructor, _swig_p) + return +} + +func NewDirectorDIgnoreConstructor(v interface{}, arg1 string, arg2 int) DIgnoreConstructor { + p := &_swig_DirectorDIgnoreConstructor{0, v} + p.SwigcptrDIgnoreConstructor = _swig_NewDirectorDIgnoreConstructorDIgnoreConstructor(p, arg1, arg2) + return p +} + +var _wrap_DeleteDirectorDIgnoreConstructor unsafe.Pointer + +func _swig_wrap_DeleteDirectorDIgnoreConstructor(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_DeleteDirectorDIgnoreConstructor, _swig_p) + return +} + +func DeleteDirectorDIgnoreConstructor(arg1 DIgnoreConstructor) { + _swig_wrap_DeleteDirectorDIgnoreConstructor(arg1.Swigcptr()) +} + +func Swiggo_DeleteDirector_DIgnoreConstructor(p *_swig_DirectorDIgnoreConstructor) { + p.SwigcptrDIgnoreConstructor = 0 +} + +type SwigcptrDIgnoreConstructor uintptr + +func (p SwigcptrDIgnoreConstructor) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrDIgnoreConstructor) SwigIsDIgnoreConstructor() { +} + +func (p SwigcptrDIgnoreConstructor) DirectorInterface() interface{} { + return nil +} + +var _wrap_delete_DIgnoreConstructor unsafe.Pointer + +func _swig_wrap_delete_DIgnoreConstructor(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_DIgnoreConstructor, _swig_p) + return +} + +func DeleteDIgnoreConstructor(arg1 DIgnoreConstructor) { + _swig_wrap_delete_DIgnoreConstructor(arg1.Swigcptr()) +} + +var _wrap_new_DIgnoreConstructor unsafe.Pointer + +func _swig_wrap_new_DIgnoreConstructor(base string, _ int) (_ SwigcptrDIgnoreConstructor) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_DIgnoreConstructor, _swig_p) + return +} + +func NewDIgnoreConstructor(arg1 string, arg2 int) (_swig_ret DIgnoreConstructor) { + return _swig_wrap_new_DIgnoreConstructor(arg1, arg2) +} + +type DIgnoreConstructor interface { + Swigcptr() uintptr + SwigIsDIgnoreConstructor() + DirectorInterface() interface{} +} + +type _swig_DirectorDIgnoreOnlyConstructor struct { + SwigcptrDIgnoreOnlyConstructor + v interface{} +} + +func (p *_swig_DirectorDIgnoreOnlyConstructor) Swigcptr() uintptr { + return p.SwigcptrDIgnoreOnlyConstructor.Swigcptr() +} + +func (p *_swig_DirectorDIgnoreOnlyConstructor) SwigIsDIgnoreOnlyConstructor() { +} + +func (p *_swig_DirectorDIgnoreOnlyConstructor) DirectorInterface() interface{} { + return p.v +} + +var _wrap_DeleteDirectorDIgnoreOnlyConstructor unsafe.Pointer + +func _swig_wrap_DeleteDirectorDIgnoreOnlyConstructor(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_DeleteDirectorDIgnoreOnlyConstructor, _swig_p) + return +} + +func DeleteDirectorDIgnoreOnlyConstructor(arg1 DIgnoreOnlyConstructor) { + _swig_wrap_DeleteDirectorDIgnoreOnlyConstructor(arg1.Swigcptr()) +} + +func Swiggo_DeleteDirector_DIgnoreOnlyConstructor(p *_swig_DirectorDIgnoreOnlyConstructor) { + p.SwigcptrDIgnoreOnlyConstructor = 0 +} + +type SwigcptrDIgnoreOnlyConstructor uintptr + +func (p SwigcptrDIgnoreOnlyConstructor) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrDIgnoreOnlyConstructor) SwigIsDIgnoreOnlyConstructor() { +} + +func (p SwigcptrDIgnoreOnlyConstructor) DirectorInterface() interface{} { + return nil +} + +var _wrap_delete_DIgnoreOnlyConstructor unsafe.Pointer + +func _swig_wrap_delete_DIgnoreOnlyConstructor(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_DIgnoreOnlyConstructor, _swig_p) + return +} + +func DeleteDIgnoreOnlyConstructor(arg1 DIgnoreOnlyConstructor) { + _swig_wrap_delete_DIgnoreOnlyConstructor(arg1.Swigcptr()) +} + +type DIgnoreOnlyConstructor interface { + Swigcptr() uintptr + SwigIsDIgnoreOnlyConstructor() + DirectorInterface() interface{} +} + + +type SwigcptrSwigDirector_DIgnores uintptr +type SwigDirector_DIgnores interface { + Swigcptr() uintptr; +} +func (p SwigcptrSwigDirector_DIgnores) Swigcptr() uintptr { + return uintptr(p) +} + +type SwigcptrSwigDirector_DAbstractIgnores uintptr +type SwigDirector_DAbstractIgnores interface { + Swigcptr() uintptr; +} +func (p SwigcptrSwigDirector_DAbstractIgnores) Swigcptr() uintptr { + return uintptr(p) +} + +type SwigcptrSwigDirector_DTemplateAbstractIgnoresInt uintptr +type SwigDirector_DTemplateAbstractIgnoresInt interface { + Swigcptr() uintptr; +} +func (p SwigcptrSwigDirector_DTemplateAbstractIgnoresInt) Swigcptr() uintptr { + return uintptr(p) +} + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/director_ignore_wrap.h b/Examples/test-suite/go/director_ignore_wrap.h new file mode 100644 index 000000000..e5bbbd802 --- /dev/null +++ b/Examples/test-suite/go/director_ignore_wrap.h @@ -0,0 +1,101 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../director_ignore.i + +#ifndef SWIG_director_ignore_WRAP_H_ +#define SWIG_director_ignore_WRAP_H_ + +class SwigDirector_DIgnores : public DIgnores +{ + public: + SwigDirector_DIgnores(void *swig_p); + virtual ~SwigDirector_DIgnores(); + void _swig_upcall_OverloadedMethod(bool b) { + DIgnores::OverloadedMethod(b); + } + virtual void OverloadedMethod(bool b); + int _swig_upcall_Triple(int n) { + return DIgnores::Triple(n); + } + virtual int Triple(int n); + virtual double PublicPureVirtualMethod1(); + virtual void PublicPureVirtualMethod2(); + virtual void TempMethod(); + void _swig_upcall_OverloadedProtectedMethod() { + DIgnores::OverloadedProtectedMethod(); + } + virtual void OverloadedProtectedMethod(); + virtual double ProtectedPureVirtualMethod1(); + virtual void ProtectedPureVirtualMethod2(); + private: + void *go_val; +}; + +class SwigDirector_DAbstractIgnores : public DAbstractIgnores +{ + public: + SwigDirector_DAbstractIgnores(void *swig_p); + virtual ~SwigDirector_DAbstractIgnores(); + virtual double OverloadedMethod(int n, int xoffset, int yoffset); + virtual double OverloadedMethod(int n, int xoffset); + virtual double OverloadedMethod(int n); + virtual double OverloadedMethod(bool b); + int _swig_upcall_Quadruple(int n) { + return DAbstractIgnores::Quadruple(n); + } + virtual int Quadruple(int n); + virtual double OverloadedProtectedMethod(int n, int xoffset, int yoffset); + virtual double OverloadedProtectedMethod(int n, int xoffset); + virtual double OverloadedProtectedMethod(int n); + virtual double OverloadedProtectedMethod(); + private: + void *go_val; +}; + +class SwigDirector_DTemplateAbstractIgnoresInt : public DTemplateAbstractIgnores< int > +{ + public: + SwigDirector_DTemplateAbstractIgnoresInt(void *swig_p); + virtual ~SwigDirector_DTemplateAbstractIgnoresInt(); + virtual double OverloadedMethod(int n, int xoffset, int yoffset); + virtual double OverloadedMethod(int n, int xoffset); + virtual double OverloadedMethod(int n); + virtual double OverloadedMethod(bool b); + int _swig_upcall_Quadruple(int n) { + return DTemplateAbstractIgnores< int >::Quadruple(n); + } + virtual int Quadruple(int n); + virtual double OverloadedProtectedMethod(int n, int xoffset, int yoffset); + virtual double OverloadedProtectedMethod(int n, int xoffset); + virtual double OverloadedProtectedMethod(int n); + virtual double OverloadedProtectedMethod(); + private: + void *go_val; +}; + +class SwigDirector_DIgnoreConstructor : public DIgnoreConstructor +{ + public: + SwigDirector_DIgnoreConstructor(void *swig_p, std::string s, int i); + virtual ~SwigDirector_DIgnoreConstructor(); + private: + void *go_val; +}; + +class SwigDirector_DIgnoreOnlyConstructor : public DIgnoreOnlyConstructor +{ + public: + virtual ~SwigDirector_DIgnoreOnlyConstructor(); + private: + void *go_val; +}; + +#endif diff --git a/Examples/test-suite/go/director_keywords.go b/Examples/test-suite/go/director_keywords.go new file mode 100644 index 000000000..0b77ce786 --- /dev/null +++ b/Examples/test-suite/go/director_keywords.go @@ -0,0 +1,175 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../director_keywords.i + +package director_keywords + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type _swig_DirectorFoo struct { + SwigcptrFoo + v interface{} +} + +func (p *_swig_DirectorFoo) Swigcptr() uintptr { + return p.SwigcptrFoo.Swigcptr() +} + +func (p *_swig_DirectorFoo) SwigIsFoo() { +} + +func (p *_swig_DirectorFoo) DirectorInterface() interface{} { + return p.v +} + +var _wrap__swig_NewDirectorFooFoo unsafe.Pointer + +func _swig_NewDirectorFooFoo(_swig_director *_swig_DirectorFoo) (_swig_ret SwigcptrFoo) { + _swig_p := uintptr(unsafe.Pointer(&_swig_director)) + _cgo_runtime_cgocall(_wrap__swig_NewDirectorFooFoo, _swig_p) + return +} + +func NewDirectorFoo(v interface{}) Foo { + p := &_swig_DirectorFoo{0, v} + p.SwigcptrFoo = _swig_NewDirectorFooFoo(p) + return p +} + +var _wrap_DeleteDirectorFoo unsafe.Pointer + +func _swig_wrap_DeleteDirectorFoo(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_DeleteDirectorFoo, _swig_p) + return +} + +func DeleteDirectorFoo(arg1 Foo) { + _swig_wrap_DeleteDirectorFoo(arg1.Swigcptr()) +} + +func Swiggo_DeleteDirector_Foo(p *_swig_DirectorFoo) { + p.SwigcptrFoo = 0 +} + +type _swig_DirectorInterfaceFooBar interface { + Bar(int) +} + +var _wrap__swig_DirectorFoo_upcall_Bar unsafe.Pointer + +func _swig_wrap__swig_DirectorFoo_upcall_Bar(_swig_ptr SwigcptrFoo, _ int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) + _cgo_runtime_cgocall(_wrap__swig_DirectorFoo_upcall_Bar, _swig_p) + return +} + +func (swig_p *_swig_DirectorFoo) Bar(abstract int) { + if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceFooBar); swig_ok { + swig_g.Bar(abstract) + return + } + _swig_wrap__swig_DirectorFoo_upcall_Bar(swig_p.SwigcptrFoo, abstract) +} + +func DirectorFooBar(p Foo, arg2 int) { + _swig_wrap__swig_DirectorFoo_upcall_Bar(p.(*_swig_DirectorFoo).SwigcptrFoo, arg2) +} + +func Swig_DirectorFoo_callback_bar(p *_swig_DirectorFoo, arg2 int) { + p.Bar(arg2) +} + +type SwigcptrFoo uintptr + +func (p SwigcptrFoo) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrFoo) SwigIsFoo() { +} + +func (p SwigcptrFoo) DirectorInterface() interface{} { + return nil +} + +var _wrap_delete_Foo unsafe.Pointer + +func _swig_wrap_delete_Foo(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Foo, _swig_p) + return +} + +func DeleteFoo(arg1 Foo) { + _swig_wrap_delete_Foo(arg1.Swigcptr()) +} + +var _wrap_Foo_bar unsafe.Pointer + +func _swig_wrap_Foo_bar(base SwigcptrFoo, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_bar, _swig_p) + return +} + +func (arg1 SwigcptrFoo) Bar(arg2 int) { + _swig_wrap_Foo_bar(arg1, arg2) +} + +var _wrap_new_Foo unsafe.Pointer + +func _swig_wrap_new_Foo() (base SwigcptrFoo) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Foo, _swig_p) + return +} + +func NewFoo() (_swig_ret Foo) { + return _swig_wrap_new_Foo() +} + +type Foo interface { + Swigcptr() uintptr + SwigIsFoo() + DirectorInterface() interface{} + Bar(arg2 int) +} + + +type SwigcptrSwigDirector_Foo uintptr +type SwigDirector_Foo interface { + Swigcptr() uintptr; +} +func (p SwigcptrSwigDirector_Foo) Swigcptr() uintptr { + return uintptr(p) +} + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/director_keywords_wrap.h b/Examples/test-suite/go/director_keywords_wrap.h new file mode 100644 index 000000000..46b9d2a53 --- /dev/null +++ b/Examples/test-suite/go/director_keywords_wrap.h @@ -0,0 +1,29 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../director_keywords.i + +#ifndef SWIG_director_keywords_WRAP_H_ +#define SWIG_director_keywords_WRAP_H_ + +class SwigDirector_Foo : public Foo +{ + public: + SwigDirector_Foo(void *swig_p); + virtual ~SwigDirector_Foo(); + void _swig_upcall_bar(int abstract) { + Foo::bar(abstract); + } + virtual void bar(int abstract); + private: + void *go_val; +}; + +#endif diff --git a/Examples/test-suite/go/director_namespace_clash.go b/Examples/test-suite/go/director_namespace_clash.go new file mode 100644 index 000000000..30bc89d01 --- /dev/null +++ b/Examples/test-suite/go/director_namespace_clash.go @@ -0,0 +1,313 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../director_namespace_clash.i + +package director_namespace_clash + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type _swig_DirectorGreatOne struct { + SwigcptrGreatOne + v interface{} +} + +func (p *_swig_DirectorGreatOne) Swigcptr() uintptr { + return p.SwigcptrGreatOne.Swigcptr() +} + +func (p *_swig_DirectorGreatOne) SwigIsGreatOne() { +} + +func (p *_swig_DirectorGreatOne) DirectorInterface() interface{} { + return p.v +} + +var _wrap__swig_NewDirectorGreatOneGreatOne unsafe.Pointer + +func _swig_NewDirectorGreatOneGreatOne(_swig_director *_swig_DirectorGreatOne) (_swig_ret SwigcptrGreatOne) { + _swig_p := uintptr(unsafe.Pointer(&_swig_director)) + _cgo_runtime_cgocall(_wrap__swig_NewDirectorGreatOneGreatOne, _swig_p) + return +} + +func NewDirectorGreatOne(v interface{}) GreatOne { + p := &_swig_DirectorGreatOne{0, v} + p.SwigcptrGreatOne = _swig_NewDirectorGreatOneGreatOne(p) + return p +} + +type _swig_DirectorInterfaceGreatOneSuperb interface { + Superb(int) +} + +var _wrap__swig_DirectorGreatOne_upcall_Superb unsafe.Pointer + +func _swig_wrap__swig_DirectorGreatOne_upcall_Superb(_swig_ptr SwigcptrGreatOne, _ int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) + _cgo_runtime_cgocall(_wrap__swig_DirectorGreatOne_upcall_Superb, _swig_p) + return +} + +func (swig_p *_swig_DirectorGreatOne) Superb(a int) { + if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceGreatOneSuperb); swig_ok { + swig_g.Superb(a) + return + } + _swig_wrap__swig_DirectorGreatOne_upcall_Superb(swig_p.SwigcptrGreatOne, a) +} + +func DirectorGreatOneSuperb(p GreatOne, arg2 int) { + _swig_wrap__swig_DirectorGreatOne_upcall_Superb(p.(*_swig_DirectorGreatOne).SwigcptrGreatOne, arg2) +} + +func Swig_DirectorGreatOne_callback_superb(p *_swig_DirectorGreatOne, arg2 int) { + p.Superb(arg2) +} + +var _wrap_DeleteDirectorGreatOne unsafe.Pointer + +func _swig_wrap_DeleteDirectorGreatOne(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_DeleteDirectorGreatOne, _swig_p) + return +} + +func DeleteDirectorGreatOne(arg1 GreatOne) { + _swig_wrap_DeleteDirectorGreatOne(arg1.Swigcptr()) +} + +func Swiggo_DeleteDirector_GreatOne(p *_swig_DirectorGreatOne) { + p.SwigcptrGreatOne = 0 +} + +type SwigcptrGreatOne uintptr + +func (p SwigcptrGreatOne) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrGreatOne) SwigIsGreatOne() { +} + +func (p SwigcptrGreatOne) DirectorInterface() interface{} { + return nil +} + +var _wrap_GreatOne_superb unsafe.Pointer + +func _swig_wrap_GreatOne_superb(base SwigcptrGreatOne, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_GreatOne_superb, _swig_p) + return +} + +func (arg1 SwigcptrGreatOne) Superb(arg2 int) { + _swig_wrap_GreatOne_superb(arg1, arg2) +} + +var _wrap_delete_GreatOne unsafe.Pointer + +func _swig_wrap_delete_GreatOne(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_GreatOne, _swig_p) + return +} + +func DeleteGreatOne(arg1 GreatOne) { + _swig_wrap_delete_GreatOne(arg1.Swigcptr()) +} + +var _wrap_new_GreatOne unsafe.Pointer + +func _swig_wrap_new_GreatOne() (base SwigcptrGreatOne) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_GreatOne, _swig_p) + return +} + +func NewGreatOne() (_swig_ret GreatOne) { + return _swig_wrap_new_GreatOne() +} + +type GreatOne interface { + Swigcptr() uintptr + SwigIsGreatOne() + DirectorInterface() interface{} + Superb(arg2 int) +} + +type _swig_DirectorGreat struct { + SwigcptrGreat + v interface{} +} + +func (p *_swig_DirectorGreat) Swigcptr() uintptr { + return p.SwigcptrGreat.Swigcptr() +} + +func (p *_swig_DirectorGreat) SwigIsGreat() { +} + +func (p *_swig_DirectorGreat) DirectorInterface() interface{} { + return p.v +} + +var _wrap__swig_NewDirectorGreatGreat unsafe.Pointer + +func _swig_NewDirectorGreatGreat(_swig_director *_swig_DirectorGreat) (_swig_ret SwigcptrGreat) { + _swig_p := uintptr(unsafe.Pointer(&_swig_director)) + _cgo_runtime_cgocall(_wrap__swig_NewDirectorGreatGreat, _swig_p) + return +} + +func NewDirectorGreat(v interface{}) Great { + p := &_swig_DirectorGreat{0, v} + p.SwigcptrGreat = _swig_NewDirectorGreatGreat(p) + return p +} + +type _swig_DirectorInterfaceGreatExcellent interface { + Excellent() +} + +var _wrap__swig_DirectorGreat_upcall_Excellent unsafe.Pointer + +func _swig_wrap__swig_DirectorGreat_upcall_Excellent(_swig_ptr SwigcptrGreat) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) + _cgo_runtime_cgocall(_wrap__swig_DirectorGreat_upcall_Excellent, _swig_p) + return +} + +func (swig_p *_swig_DirectorGreat) Excellent() { + if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceGreatExcellent); swig_ok { + swig_g.Excellent() + return + } + _swig_wrap__swig_DirectorGreat_upcall_Excellent(swig_p.SwigcptrGreat) +} + +func DirectorGreatExcellent(p Great) { + _swig_wrap__swig_DirectorGreat_upcall_Excellent(p.(*_swig_DirectorGreat).SwigcptrGreat) +} + +func Swig_DirectorGreat_callback_excellent(p *_swig_DirectorGreat) { + p.Excellent() +} + +var _wrap_DeleteDirectorGreat unsafe.Pointer + +func _swig_wrap_DeleteDirectorGreat(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_DeleteDirectorGreat, _swig_p) + return +} + +func DeleteDirectorGreat(arg1 Great) { + _swig_wrap_DeleteDirectorGreat(arg1.Swigcptr()) +} + +func Swiggo_DeleteDirector_Great(p *_swig_DirectorGreat) { + p.SwigcptrGreat = 0 +} + +type SwigcptrGreat uintptr + +func (p SwigcptrGreat) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrGreat) SwigIsGreat() { +} + +func (p SwigcptrGreat) DirectorInterface() interface{} { + return nil +} + +var _wrap_Great_excellent unsafe.Pointer + +func _swig_wrap_Great_excellent(base SwigcptrGreat) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Great_excellent, _swig_p) + return +} + +func (arg1 SwigcptrGreat) Excellent() { + _swig_wrap_Great_excellent(arg1) +} + +var _wrap_delete_Great unsafe.Pointer + +func _swig_wrap_delete_Great(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Great, _swig_p) + return +} + +func DeleteGreat(arg1 Great) { + _swig_wrap_delete_Great(arg1.Swigcptr()) +} + +var _wrap_new_Great unsafe.Pointer + +func _swig_wrap_new_Great() (base SwigcptrGreat) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Great, _swig_p) + return +} + +func NewGreat() (_swig_ret Great) { + return _swig_wrap_new_Great() +} + +type Great interface { + Swigcptr() uintptr + SwigIsGreat() + DirectorInterface() interface{} + Excellent() +} + + +type SwigcptrSwigDirector_GreatOne uintptr +type SwigDirector_GreatOne interface { + Swigcptr() uintptr; +} +func (p SwigcptrSwigDirector_GreatOne) Swigcptr() uintptr { + return uintptr(p) +} + +type SwigcptrSwigDirector_Great uintptr +type SwigDirector_Great interface { + Swigcptr() uintptr; +} +func (p SwigcptrSwigDirector_Great) Swigcptr() uintptr { + return uintptr(p) +} + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/director_namespace_clash_wrap.h b/Examples/test-suite/go/director_namespace_clash_wrap.h new file mode 100644 index 000000000..e3de6ff74 --- /dev/null +++ b/Examples/test-suite/go/director_namespace_clash_wrap.h @@ -0,0 +1,42 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../director_namespace_clash.i + +#ifndef SWIG_director_namespace_clash_WRAP_H_ +#define SWIG_director_namespace_clash_WRAP_H_ + +class SwigDirector_GreatOne : public One::Great +{ + public: + SwigDirector_GreatOne(void *swig_p); + void _swig_upcall_superb(int a) { + One::Great::superb(a); + } + virtual void superb(int a); + virtual ~SwigDirector_GreatOne(); + private: + void *go_val; +}; + +class SwigDirector_Great : public Two::Great +{ + public: + SwigDirector_Great(void *swig_p); + void _swig_upcall_excellent() { + Two::Great::excellent(); + } + virtual void excellent(); + virtual ~SwigDirector_Great(); + private: + void *go_val; +}; + +#endif diff --git a/Examples/test-suite/go/director_nested.go b/Examples/test-suite/go/director_nested.go new file mode 100644 index 000000000..3021aa542 --- /dev/null +++ b/Examples/test-suite/go/director_nested.go @@ -0,0 +1,662 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../director_nested.i + +package director_nested + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type _swig_DirectorFoo_int struct { + SwigcptrFoo_int + v interface{} +} + +func (p *_swig_DirectorFoo_int) Swigcptr() uintptr { + return p.SwigcptrFoo_int.Swigcptr() +} + +func (p *_swig_DirectorFoo_int) SwigIsFoo_int() { +} + +func (p *_swig_DirectorFoo_int) DirectorInterface() interface{} { + return p.v +} + +var _wrap__swig_NewDirectorFoo_intFoo_int unsafe.Pointer + +func _swig_NewDirectorFoo_intFoo_int(_swig_director *_swig_DirectorFoo_int) (_swig_ret SwigcptrFoo_int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_director)) + _cgo_runtime_cgocall(_wrap__swig_NewDirectorFoo_intFoo_int, _swig_p) + return +} + +func NewDirectorFoo_int(v interface{}) Foo_int { + p := &_swig_DirectorFoo_int{0, v} + p.SwigcptrFoo_int = _swig_NewDirectorFoo_intFoo_int(p) + return p +} + +var _wrap_DeleteDirectorFoo_int unsafe.Pointer + +func _swig_wrap_DeleteDirectorFoo_int(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_DeleteDirectorFoo_int, _swig_p) + return +} + +func DeleteDirectorFoo_int(arg1 Foo_int) { + _swig_wrap_DeleteDirectorFoo_int(arg1.Swigcptr()) +} + +func Swiggo_DeleteDirector_Foo_int(p *_swig_DirectorFoo_int) { + p.SwigcptrFoo_int = 0 +} + +type _swig_DirectorInterfaceFoo_intDo_advance interface { + Do_advance() string +} + +func (swig_p *_swig_DirectorFoo_int) Do_advance() string { + if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceFoo_intDo_advance); swig_ok { + return swig_g.Do_advance() + } + panic("call to pure virtual method") +} + +func Swig_DirectorFoo_int_callback_do_advance(p *_swig_DirectorFoo_int) (swig_result string) { + var swig_r string + swig_r = p.Do_advance() + return swig_r +} + +type SwigcptrFoo_int uintptr + +func (p SwigcptrFoo_int) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrFoo_int) SwigIsFoo_int() { +} + +func (p SwigcptrFoo_int) DirectorInterface() interface{} { + return nil +} + +var _wrap_delete_Foo_int unsafe.Pointer + +func _swig_wrap_delete_Foo_int(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Foo_int, _swig_p) + return +} + +func DeleteFoo_int(arg1 Foo_int) { + _swig_wrap_delete_Foo_int(arg1.Swigcptr()) +} + +var _wrap_Foo_int_advance unsafe.Pointer + +func _swig_wrap_Foo_int_advance(base SwigcptrFoo_int) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_int_advance, _swig_p) + return +} + +func (arg1 SwigcptrFoo_int) Advance() (_swig_ret string) { + return _swig_wrap_Foo_int_advance(arg1) +} + +var _wrap_new_Foo_int unsafe.Pointer + +func _swig_wrap_new_Foo_int() (base SwigcptrFoo_int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Foo_int, _swig_p) + return +} + +func NewFoo_int() (_swig_ret Foo_int) { + return _swig_wrap_new_Foo_int() +} + +type Foo_int interface { + Swigcptr() uintptr + SwigIsFoo_int() + DirectorInterface() interface{} + Advance() (_swig_ret string) +} + +type _swig_DirectorBar struct { + SwigcptrBar + v interface{} +} + +func (p *_swig_DirectorBar) Swigcptr() uintptr { + return p.SwigcptrBar.Swigcptr() +} + +func (p *_swig_DirectorBar) SwigIsBar() { +} + +func (p *_swig_DirectorBar) DirectorInterface() interface{} { + return p.v +} + +var _wrap__swig_NewDirectorBarBar unsafe.Pointer + +func _swig_NewDirectorBarBar(_swig_director *_swig_DirectorBar) (_swig_ret SwigcptrBar) { + _swig_p := uintptr(unsafe.Pointer(&_swig_director)) + _cgo_runtime_cgocall(_wrap__swig_NewDirectorBarBar, _swig_p) + return +} + +func NewDirectorBar(v interface{}) Bar { + p := &_swig_DirectorBar{0, v} + p.SwigcptrBar = _swig_NewDirectorBarBar(p) + return p +} + +var _wrap_DeleteDirectorBar unsafe.Pointer + +func _swig_wrap_DeleteDirectorBar(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_DeleteDirectorBar, _swig_p) + return +} + +func DeleteDirectorBar(arg1 Bar) { + _swig_wrap_DeleteDirectorBar(arg1.Swigcptr()) +} + +func Swiggo_DeleteDirector_Bar(p *_swig_DirectorBar) { + p.SwigcptrBar = 0 +} + +type _swig_DirectorInterfaceBarDo_advance interface { + Do_advance() string +} + +var _wrap__swig_DirectorBar_upcall_Do_advance unsafe.Pointer + +func _swig_wrap__swig_DirectorBar_upcall_Do_advance(_swig_ptr SwigcptrBar) (_swig_ret string) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) + _cgo_runtime_cgocall(_wrap__swig_DirectorBar_upcall_Do_advance, _swig_p) + return +} + +func (swig_p *_swig_DirectorBar) Do_advance() string { + if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceBarDo_advance); swig_ok { + return swig_g.Do_advance() + } + var swig_r string + swig_r = _swig_wrap__swig_DirectorBar_upcall_Do_advance(swig_p.SwigcptrBar) + return swig_r +} + +func DirectorBarDo_advance(p Bar) string { + var swig_r string + swig_r = _swig_wrap__swig_DirectorBar_upcall_Do_advance(p.(*_swig_DirectorBar).SwigcptrBar) + return swig_r +} + +func Swig_DirectorBar_callback_do_advance(p *_swig_DirectorBar) (swig_result string) { + var swig_r string + swig_r = p.Do_advance() + return swig_r +} + +type _swig_DirectorInterfaceBarDo_step interface { + Do_step() string +} + +var _wrap__swig_DirectorBar_upcall_Do_step unsafe.Pointer + +func _swig_wrap__swig_DirectorBar_upcall_Do_step(_swig_ptr SwigcptrBar) (_swig_ret string) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) + _cgo_runtime_cgocall(_wrap__swig_DirectorBar_upcall_Do_step, _swig_p) + return +} + +func (swig_p *_swig_DirectorBar) Do_step() string { + if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceBarDo_step); swig_ok { + return swig_g.Do_step() + } + var swig_r string + swig_r = _swig_wrap__swig_DirectorBar_upcall_Do_step(swig_p.SwigcptrBar) + return swig_r +} + +func DirectorBarDo_step(p Bar) string { + var swig_r string + swig_r = _swig_wrap__swig_DirectorBar_upcall_Do_step(p.(*_swig_DirectorBar).SwigcptrBar) + return swig_r +} + +func Swig_DirectorBar_callback_do_step(p *_swig_DirectorBar) (swig_result string) { + var swig_r string + swig_r = p.Do_step() + return swig_r +} + +type SwigcptrBar uintptr + +func (p SwigcptrBar) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrBar) SwigIsBar() { +} + +func (p SwigcptrBar) DirectorInterface() interface{} { + return nil +} + +var _wrap_Bar_step unsafe.Pointer + +func _swig_wrap_Bar_step(base SwigcptrBar) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Bar_step, _swig_p) + return +} + +func (arg1 SwigcptrBar) Step() (_swig_ret string) { + return _swig_wrap_Bar_step(arg1) +} + +var _wrap_new_Bar unsafe.Pointer + +func _swig_wrap_new_Bar() (base SwigcptrBar) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Bar, _swig_p) + return +} + +func NewBar() (_swig_ret Bar) { + return _swig_wrap_new_Bar() +} + +var _wrap_delete_Bar unsafe.Pointer + +func _swig_wrap_delete_Bar(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Bar, _swig_p) + return +} + +func DeleteBar(arg1 Bar) { + _swig_wrap_delete_Bar(arg1.Swigcptr()) +} + +var _wrap_Bar_advance unsafe.Pointer + +func _swig_wrap_Bar_advance(base SwigcptrBar) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Bar_advance, _swig_p) + return +} + +func (_swig_base SwigcptrBar) Advance() (_swig_ret string) { + return _swig_wrap_Bar_advance(_swig_base) +} + +func (p SwigcptrBar) SwigIsFoo_int() { +} + +func (p SwigcptrBar) SwigGetFoo_int() Foo_int { + return SwigcptrFoo_int(p.Swigcptr()) +} + +type Bar interface { + Swigcptr() uintptr + SwigIsBar() + DirectorInterface() interface{} + Step() (_swig_ret string) + Advance() (_swig_ret string) + SwigIsFoo_int() + SwigGetFoo_int() Foo_int +} + +type _swig_DirectorFooBar_int struct { + SwigcptrFooBar_int + v interface{} +} + +func (p *_swig_DirectorFooBar_int) Swigcptr() uintptr { + return p.SwigcptrFooBar_int.Swigcptr() +} + +func (p *_swig_DirectorFooBar_int) SwigIsFooBar_int() { +} + +func (p *_swig_DirectorFooBar_int) DirectorInterface() interface{} { + return p.v +} + +var _wrap__swig_NewDirectorFooBar_intFooBar_int unsafe.Pointer + +func _swig_NewDirectorFooBar_intFooBar_int(_swig_director *_swig_DirectorFooBar_int) (_swig_ret SwigcptrFooBar_int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_director)) + _cgo_runtime_cgocall(_wrap__swig_NewDirectorFooBar_intFooBar_int, _swig_p) + return +} + +func NewDirectorFooBar_int(v interface{}) FooBar_int { + p := &_swig_DirectorFooBar_int{0, v} + p.SwigcptrFooBar_int = _swig_NewDirectorFooBar_intFooBar_int(p) + return p +} + +var _wrap_DeleteDirectorFooBar_int unsafe.Pointer + +func _swig_wrap_DeleteDirectorFooBar_int(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_DeleteDirectorFooBar_int, _swig_p) + return +} + +func DeleteDirectorFooBar_int(arg1 FooBar_int) { + _swig_wrap_DeleteDirectorFooBar_int(arg1.Swigcptr()) +} + +func Swiggo_DeleteDirector_FooBar_int(p *_swig_DirectorFooBar_int) { + p.SwigcptrFooBar_int = 0 +} + +type _swig_DirectorInterfaceFooBar_intDo_advance interface { + Do_advance() string +} + +var _wrap__swig_DirectorFooBar_int_upcall_Do_advance unsafe.Pointer + +func _swig_wrap__swig_DirectorFooBar_int_upcall_Do_advance(_swig_ptr SwigcptrFooBar_int) (_swig_ret string) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) + _cgo_runtime_cgocall(_wrap__swig_DirectorFooBar_int_upcall_Do_advance, _swig_p) + return +} + +func (swig_p *_swig_DirectorFooBar_int) Do_advance() string { + if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceFooBar_intDo_advance); swig_ok { + return swig_g.Do_advance() + } + var swig_r string + swig_r = _swig_wrap__swig_DirectorFooBar_int_upcall_Do_advance(swig_p.SwigcptrFooBar_int) + return swig_r +} + +func DirectorFooBar_intDo_advance(p FooBar_int) string { + var swig_r string + swig_r = _swig_wrap__swig_DirectorFooBar_int_upcall_Do_advance(p.(*_swig_DirectorFooBar_int).SwigcptrFooBar_int) + return swig_r +} + +func Swig_DirectorFooBar_int_callback_do_advance(p *_swig_DirectorFooBar_int) (swig_result string) { + var swig_r string + swig_r = p.Do_advance() + return swig_r +} + +type _swig_DirectorInterfaceFooBar_intDo_step interface { + Do_step() string +} + +var _wrap__swig_DirectorFooBar_int_upcall_Do_step unsafe.Pointer + +func _swig_wrap__swig_DirectorFooBar_int_upcall_Do_step(_swig_ptr SwigcptrFooBar_int) (_swig_ret string) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) + _cgo_runtime_cgocall(_wrap__swig_DirectorFooBar_int_upcall_Do_step, _swig_p) + return +} + +func (swig_p *_swig_DirectorFooBar_int) Do_step() string { + if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceFooBar_intDo_step); swig_ok { + return swig_g.Do_step() + } + var swig_r string + swig_r = _swig_wrap__swig_DirectorFooBar_int_upcall_Do_step(swig_p.SwigcptrFooBar_int) + return swig_r +} + +func DirectorFooBar_intDo_step(p FooBar_int) string { + var swig_r string + swig_r = _swig_wrap__swig_DirectorFooBar_int_upcall_Do_step(p.(*_swig_DirectorFooBar_int).SwigcptrFooBar_int) + return swig_r +} + +func Swig_DirectorFooBar_int_callback_do_step(p *_swig_DirectorFooBar_int) (swig_result string) { + var swig_r string + swig_r = p.Do_step() + return swig_r +} + +type _swig_DirectorInterfaceFooBar_intGet_value interface { + Get_value() int +} + +func (swig_p *_swig_DirectorFooBar_int) Get_value() int { + if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceFooBar_intGet_value); swig_ok { + return swig_g.Get_value() + } + panic("call to pure virtual method") +} + +func Swig_DirectorFooBar_int_callback_get_value(p *_swig_DirectorFooBar_int) (swig_result int) { + var swig_r int + swig_r = p.Get_value() + return swig_r +} + +type _swig_DirectorInterfaceFooBar_intGet_name interface { + Get_name() string +} + +var _wrap__swig_DirectorFooBar_int_upcall_Get_name unsafe.Pointer + +func _swig_wrap__swig_DirectorFooBar_int_upcall_Get_name(_swig_ptr SwigcptrFooBar_int) (_swig_ret string) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) + _cgo_runtime_cgocall(_wrap__swig_DirectorFooBar_int_upcall_Get_name, _swig_p) + return +} + +func (swig_p *_swig_DirectorFooBar_int) Get_name() string { + if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceFooBar_intGet_name); swig_ok { + return swig_g.Get_name() + } + var swig_r string + swig_r = _swig_wrap__swig_DirectorFooBar_int_upcall_Get_name(swig_p.SwigcptrFooBar_int) + return swig_r +} + +func DirectorFooBar_intGet_name(p FooBar_int) string { + var swig_r string + swig_r = _swig_wrap__swig_DirectorFooBar_int_upcall_Get_name(p.(*_swig_DirectorFooBar_int).SwigcptrFooBar_int) + return swig_r +} + +func Swig_DirectorFooBar_int_callback_get_name(p *_swig_DirectorFooBar_int) (swig_result string) { + var swig_r string + swig_r = p.Get_name() + return swig_r +} + +type SwigcptrFooBar_int uintptr + +func (p SwigcptrFooBar_int) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrFooBar_int) SwigIsFooBar_int() { +} + +func (p SwigcptrFooBar_int) DirectorInterface() interface{} { + return nil +} + +var _wrap_FooBar_int_get_value unsafe.Pointer + +func _swig_wrap_FooBar_int_get_value(base SwigcptrFooBar_int) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_FooBar_int_get_value, _swig_p) + return +} + +func (arg1 SwigcptrFooBar_int) Get_value() (_swig_ret int) { + return _swig_wrap_FooBar_int_get_value(arg1) +} + +var _wrap_FooBar_int_get_name unsafe.Pointer + +func _swig_wrap_FooBar_int_get_name(base SwigcptrFooBar_int) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_FooBar_int_get_name, _swig_p) + return +} + +func (arg1 SwigcptrFooBar_int) Get_name() (_swig_ret string) { + return _swig_wrap_FooBar_int_get_name(arg1) +} + +var _wrap_FooBar_int_name unsafe.Pointer + +func _swig_wrap_FooBar_int_name(base SwigcptrFooBar_int) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_FooBar_int_name, _swig_p) + return +} + +func (arg1 SwigcptrFooBar_int) Name() (_swig_ret string) { + return _swig_wrap_FooBar_int_name(arg1) +} + +var _wrap_FooBar_int_get_self unsafe.Pointer + +func _swig_wrap_FooBar_int_get_self(base uintptr) (_ SwigcptrFooBar_int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_FooBar_int_get_self, _swig_p) + return +} + +func FooBar_intGet_self(arg1 FooBar_int) (_swig_ret FooBar_int) { + return _swig_wrap_FooBar_int_get_self(arg1.Swigcptr()) +} + +var _wrap_new_FooBar_int unsafe.Pointer + +func _swig_wrap_new_FooBar_int() (base SwigcptrFooBar_int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_FooBar_int, _swig_p) + return +} + +func NewFooBar_int() (_swig_ret FooBar_int) { + return _swig_wrap_new_FooBar_int() +} + +var _wrap_delete_FooBar_int unsafe.Pointer + +func _swig_wrap_delete_FooBar_int(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_FooBar_int, _swig_p) + return +} + +func DeleteFooBar_int(arg1 FooBar_int) { + _swig_wrap_delete_FooBar_int(arg1.Swigcptr()) +} + +var _wrap_FooBar_int_step unsafe.Pointer + +func _swig_wrap_FooBar_int_step(base SwigcptrFooBar_int) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_FooBar_int_step, _swig_p) + return +} + +func (_swig_base SwigcptrFooBar_int) Step() (_swig_ret string) { + return _swig_wrap_FooBar_int_step(_swig_base) +} + +var _wrap_FooBar_int_advance unsafe.Pointer + +func _swig_wrap_FooBar_int_advance(base SwigcptrFooBar_int) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_FooBar_int_advance, _swig_p) + return +} + +func (_swig_base SwigcptrFooBar_int) Advance() (_swig_ret string) { + return _swig_wrap_FooBar_int_advance(_swig_base) +} + +func (p SwigcptrFooBar_int) SwigIsBar() { +} + +func (p SwigcptrFooBar_int) SwigGetBar() Bar { + return SwigcptrBar(p.Swigcptr()) +} + +func (p SwigcptrFooBar_int) SwigIsFoo_int() { +} + +func (p SwigcptrFooBar_int) SwigGetFoo_int() Foo_int { + return SwigcptrFoo_int(p.Swigcptr()) +} + +type FooBar_int interface { + Swigcptr() uintptr + SwigIsFooBar_int() + DirectorInterface() interface{} + Get_value() (_swig_ret int) + Get_name() (_swig_ret string) + Name() (_swig_ret string) + Step() (_swig_ret string) + Advance() (_swig_ret string) + SwigIsBar() + SwigGetBar() Bar + SwigIsFoo_int() + SwigGetFoo_int() Foo_int +} + + +type SwigcptrSwigDirector_FooBar_int uintptr +type SwigDirector_FooBar_int interface { + Swigcptr() uintptr; +} +func (p SwigcptrSwigDirector_FooBar_int) Swigcptr() uintptr { + return uintptr(p) +} + +type SwigcptrSwigDirector_Bar uintptr +type SwigDirector_Bar interface { + Swigcptr() uintptr; +} +func (p SwigcptrSwigDirector_Bar) Swigcptr() uintptr { + return uintptr(p) +} + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/director_nested_runme b/Examples/test-suite/go/director_nested_runme new file mode 100755 index 000000000..1aabef3a3 Binary files /dev/null and b/Examples/test-suite/go/director_nested_runme differ diff --git a/Examples/test-suite/go/director_nested_wrap.h b/Examples/test-suite/go/director_nested_wrap.h new file mode 100644 index 000000000..25e81d3a2 --- /dev/null +++ b/Examples/test-suite/go/director_nested_wrap.h @@ -0,0 +1,65 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../director_nested.i + +#ifndef SWIG_director_nested_WRAP_H_ +#define SWIG_director_nested_WRAP_H_ + +class SwigDirector_Foo_int : public Foo< int > +{ + public: + SwigDirector_Foo_int(void *swig_p); + virtual ~SwigDirector_Foo_int(); + virtual std::string do_advance(); + private: + void *go_val; +}; + +class SwigDirector_Bar : public Bar +{ + public: + SwigDirector_Bar(void *swig_p); + virtual ~SwigDirector_Bar(); + std::string _swig_upcall_do_advance() { + return Bar::do_advance(); + } + virtual std::string do_advance(); + std::string _swig_upcall_do_step() const { + return Bar::do_step(); + } + virtual std::string do_step() const; + private: + void *go_val; +}; + +class SwigDirector_FooBar_int : public FooBar< int > +{ + public: + SwigDirector_FooBar_int(void *swig_p); + virtual ~SwigDirector_FooBar_int(); + std::string _swig_upcall_do_advance() { + return Bar::do_advance(); + } + virtual std::string do_advance(); + std::string _swig_upcall_do_step() const { + return Bar::do_step(); + } + virtual std::string do_step() const; + virtual int get_value() const; + char const *_swig_upcall_get_name() { + return FooBar< int >::get_name(); + } + virtual char const *get_name(); + private: + void *go_val; +}; + +#endif diff --git a/Examples/test-suite/go/director_nspace.go b/Examples/test-suite/go/director_nspace.go new file mode 100644 index 000000000..cdb5b2d6e --- /dev/null +++ b/Examples/test-suite/go/director_nspace.go @@ -0,0 +1,450 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../director_nspace.i + +package director_nspace + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrFooBar uintptr + +func (p SwigcptrFooBar) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrFooBar) SwigIsFooBar() { +} + +var _wrap_new_FooBar__SWIG_0 unsafe.Pointer + +func _swig_wrap_new_FooBar__SWIG_0() (base SwigcptrFooBar) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_FooBar__SWIG_0, _swig_p) + return +} + +func NewFooBar__SWIG_0() (_swig_ret FooBar) { + return _swig_wrap_new_FooBar__SWIG_0() +} + +var _wrap_new_FooBar__SWIG_1 unsafe.Pointer + +func _swig_wrap_new_FooBar__SWIG_1(base uintptr) (_ SwigcptrFooBar) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_FooBar__SWIG_1, _swig_p) + return +} + +func NewFooBar__SWIG_1(arg1 FooBar) (_swig_ret FooBar) { + return _swig_wrap_new_FooBar__SWIG_1(arg1.Swigcptr()) +} + +func NewFooBar(a ...interface{}) FooBar { + argc := len(a) + if argc == 0 { + return NewFooBar__SWIG_0() + } + if argc == 1 { + return NewFooBar__SWIG_1(a[0].(FooBar)) + } + panic("No match for overloaded function call") +} + +var _wrap_delete_FooBar unsafe.Pointer + +func _swig_wrap_delete_FooBar(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_FooBar, _swig_p) + return +} + +func DeleteFooBar(arg1 FooBar) { + _swig_wrap_delete_FooBar(arg1.Swigcptr()) +} + +var _wrap_FooBar_FooBarDo unsafe.Pointer + +func _swig_wrap_FooBar_FooBarDo(base SwigcptrFooBar) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_FooBar_FooBarDo, _swig_p) + return +} + +func (arg1 SwigcptrFooBar) FooBarDo() (_swig_ret string) { + return _swig_wrap_FooBar_FooBarDo(arg1) +} + +type FooBar interface { + Swigcptr() uintptr + SwigIsFooBar() + FooBarDo() (_swig_ret string) +} + +type _swig_DirectorFoo struct { + SwigcptrFoo + v interface{} +} + +func (p *_swig_DirectorFoo) Swigcptr() uintptr { + return p.SwigcptrFoo.Swigcptr() +} + +func (p *_swig_DirectorFoo) SwigIsFoo() { +} + +func (p *_swig_DirectorFoo) DirectorInterface() interface{} { + return p.v +} + +var _wrap__swig_NewDirectorFooFoo unsafe.Pointer + +func _swig_NewDirectorFooFoo(_swig_director *_swig_DirectorFoo) (_swig_ret SwigcptrFoo) { + _swig_p := uintptr(unsafe.Pointer(&_swig_director)) + _cgo_runtime_cgocall(_wrap__swig_NewDirectorFooFoo, _swig_p) + return +} + +func NewDirectorFoo(v interface{}) Foo { + p := &_swig_DirectorFoo{0, v} + p.SwigcptrFoo = _swig_NewDirectorFooFoo(p) + return p +} + +var _wrap_DeleteDirectorFoo unsafe.Pointer + +func _swig_wrap_DeleteDirectorFoo(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_DeleteDirectorFoo, _swig_p) + return +} + +func DeleteDirectorFoo(arg1 Foo) { + _swig_wrap_DeleteDirectorFoo(arg1.Swigcptr()) +} + +func Swiggo_DeleteDirector_Foo(p *_swig_DirectorFoo) { + p.SwigcptrFoo = 0 +} + +type _swig_DirectorInterfaceFooPing interface { + Ping() string +} + +var _wrap__swig_DirectorFoo_upcall_Ping unsafe.Pointer + +func _swig_wrap__swig_DirectorFoo_upcall_Ping(_swig_ptr SwigcptrFoo) (_swig_ret string) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) + _cgo_runtime_cgocall(_wrap__swig_DirectorFoo_upcall_Ping, _swig_p) + return +} + +func (swig_p *_swig_DirectorFoo) Ping() string { + if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceFooPing); swig_ok { + return swig_g.Ping() + } + var swig_r string + swig_r = _swig_wrap__swig_DirectorFoo_upcall_Ping(swig_p.SwigcptrFoo) + return swig_r +} + +func DirectorFooPing(p Foo) string { + var swig_r string + swig_r = _swig_wrap__swig_DirectorFoo_upcall_Ping(p.(*_swig_DirectorFoo).SwigcptrFoo) + return swig_r +} + +func Swig_DirectorFoo_callback_ping(p *_swig_DirectorFoo) (swig_result string) { + var swig_r string + swig_r = p.Ping() + return swig_r +} + +type _swig_DirectorInterfaceFooPong interface { + Pong() string +} + +var _wrap__swig_DirectorFoo_upcall_Pong unsafe.Pointer + +func _swig_wrap__swig_DirectorFoo_upcall_Pong(_swig_ptr SwigcptrFoo) (_swig_ret string) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) + _cgo_runtime_cgocall(_wrap__swig_DirectorFoo_upcall_Pong, _swig_p) + return +} + +func (swig_p *_swig_DirectorFoo) Pong() string { + if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceFooPong); swig_ok { + return swig_g.Pong() + } + var swig_r string + swig_r = _swig_wrap__swig_DirectorFoo_upcall_Pong(swig_p.SwigcptrFoo) + return swig_r +} + +func DirectorFooPong(p Foo) string { + var swig_r string + swig_r = _swig_wrap__swig_DirectorFoo_upcall_Pong(p.(*_swig_DirectorFoo).SwigcptrFoo) + return swig_r +} + +func Swig_DirectorFoo_callback_pong(p *_swig_DirectorFoo) (swig_result string) { + var swig_r string + swig_r = p.Pong() + return swig_r +} + +type _swig_DirectorInterfaceFooFooBar interface { + FooBar(FooBar) string +} + +var _wrap__swig_DirectorFoo_upcall_FooBar unsafe.Pointer + +func _swig_wrap__swig_DirectorFoo_upcall_FooBar(_swig_ptr SwigcptrFoo, _ uintptr) (_swig_ret string) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) + _cgo_runtime_cgocall(_wrap__swig_DirectorFoo_upcall_FooBar, _swig_p) + return +} + +func (swig_p *_swig_DirectorFoo) FooBar(fb FooBar) string { + if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceFooFooBar); swig_ok { + return swig_g.FooBar(fb) + } + var swig_r string + swig_r = _swig_wrap__swig_DirectorFoo_upcall_FooBar(swig_p.SwigcptrFoo, fb.Swigcptr()) + return swig_r +} + +func DirectorFooFooBar(p Foo, arg2 FooBar) string { + var swig_r string + swig_r = _swig_wrap__swig_DirectorFoo_upcall_FooBar(p.(*_swig_DirectorFoo).SwigcptrFoo, arg2.Swigcptr()) + return swig_r +} + +func Swig_DirectorFoo_callback_fooBar(p *_swig_DirectorFoo, arg2 uintptr) (swig_result string) { + var swig_r string + swig_r = p.FooBar(SwigcptrFooBar(arg2)) + return swig_r +} + +type _swig_DirectorInterfaceFooMakeFoo interface { + MakeFoo() Foo +} + +var _wrap__swig_DirectorFoo_upcall_MakeFoo unsafe.Pointer + +func _swig_wrap__swig_DirectorFoo_upcall_MakeFoo(_swig_ptr SwigcptrFoo) (_swig_ret SwigcptrFoo) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) + _cgo_runtime_cgocall(_wrap__swig_DirectorFoo_upcall_MakeFoo, _swig_p) + return +} + +func (swig_p *_swig_DirectorFoo) MakeFoo() Foo { + if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceFooMakeFoo); swig_ok { + return swig_g.MakeFoo() + } + var swig_r Foo + swig_r = _swig_wrap__swig_DirectorFoo_upcall_MakeFoo(swig_p.SwigcptrFoo) + return swig_r +} + +func DirectorFooMakeFoo(p Foo) Foo { + var swig_r Foo + swig_r = _swig_wrap__swig_DirectorFoo_upcall_MakeFoo(p.(*_swig_DirectorFoo).SwigcptrFoo) + return swig_r +} + +func Swig_DirectorFoo_callback_makeFoo(p *_swig_DirectorFoo) (swig_result SwigcptrFoo) { + var swig_r SwigcptrFoo + swig_r = SwigcptrFoo(p.MakeFoo().Swigcptr()) + return swig_r +} + +type _swig_DirectorInterfaceFooMakeFooBar interface { + MakeFooBar() FooBar +} + +var _wrap__swig_DirectorFoo_upcall_MakeFooBar unsafe.Pointer + +func _swig_wrap__swig_DirectorFoo_upcall_MakeFooBar(_swig_ptr SwigcptrFoo) (_swig_ret SwigcptrFooBar) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) + _cgo_runtime_cgocall(_wrap__swig_DirectorFoo_upcall_MakeFooBar, _swig_p) + return +} + +func (swig_p *_swig_DirectorFoo) MakeFooBar() FooBar { + if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceFooMakeFooBar); swig_ok { + return swig_g.MakeFooBar() + } + var swig_r FooBar + swig_r = _swig_wrap__swig_DirectorFoo_upcall_MakeFooBar(swig_p.SwigcptrFoo) + return swig_r +} + +func DirectorFooMakeFooBar(p Foo) FooBar { + var swig_r FooBar + swig_r = _swig_wrap__swig_DirectorFoo_upcall_MakeFooBar(p.(*_swig_DirectorFoo).SwigcptrFoo) + return swig_r +} + +func Swig_DirectorFoo_callback_makeFooBar(p *_swig_DirectorFoo) (swig_result SwigcptrFooBar) { + var swig_r SwigcptrFooBar + swig_r = SwigcptrFooBar(p.MakeFooBar().Swigcptr()) + return swig_r +} + +type SwigcptrFoo uintptr + +func (p SwigcptrFoo) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrFoo) SwigIsFoo() { +} + +func (p SwigcptrFoo) DirectorInterface() interface{} { + return nil +} + +var _wrap_delete_Foo unsafe.Pointer + +func _swig_wrap_delete_Foo(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Foo, _swig_p) + return +} + +func DeleteFoo(arg1 Foo) { + _swig_wrap_delete_Foo(arg1.Swigcptr()) +} + +var _wrap_Foo_ping unsafe.Pointer + +func _swig_wrap_Foo_ping(base SwigcptrFoo) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_ping, _swig_p) + return +} + +func (arg1 SwigcptrFoo) Ping() (_swig_ret string) { + return _swig_wrap_Foo_ping(arg1) +} + +var _wrap_Foo_pong unsafe.Pointer + +func _swig_wrap_Foo_pong(base SwigcptrFoo) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_pong, _swig_p) + return +} + +func (arg1 SwigcptrFoo) Pong() (_swig_ret string) { + return _swig_wrap_Foo_pong(arg1) +} + +var _wrap_Foo_fooBar unsafe.Pointer + +func _swig_wrap_Foo_fooBar(base SwigcptrFoo, _ uintptr) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_fooBar, _swig_p) + return +} + +func (arg1 SwigcptrFoo) FooBar(arg2 FooBar) (_swig_ret string) { + return _swig_wrap_Foo_fooBar(arg1, arg2.Swigcptr()) +} + +var _wrap_Foo_makeFoo unsafe.Pointer + +func _swig_wrap_Foo_makeFoo(base SwigcptrFoo) (_ SwigcptrFoo) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_makeFoo, _swig_p) + return +} + +func (arg1 SwigcptrFoo) MakeFoo() (_swig_ret Foo) { + return _swig_wrap_Foo_makeFoo(arg1) +} + +var _wrap_Foo_makeFooBar unsafe.Pointer + +func _swig_wrap_Foo_makeFooBar(base SwigcptrFoo) (_ SwigcptrFooBar) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_makeFooBar, _swig_p) + return +} + +func (arg1 SwigcptrFoo) MakeFooBar() (_swig_ret FooBar) { + return _swig_wrap_Foo_makeFooBar(arg1) +} + +var _wrap_Foo_get_self unsafe.Pointer + +func _swig_wrap_Foo_get_self(base uintptr) (_ SwigcptrFoo) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_get_self, _swig_p) + return +} + +func FooGet_self(arg1 Foo) (_swig_ret Foo) { + return _swig_wrap_Foo_get_self(arg1.Swigcptr()) +} + +var _wrap_new_Foo unsafe.Pointer + +func _swig_wrap_new_Foo() (base SwigcptrFoo) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Foo, _swig_p) + return +} + +func NewFoo() (_swig_ret Foo) { + return _swig_wrap_new_Foo() +} + +type Foo interface { + Swigcptr() uintptr + SwigIsFoo() + DirectorInterface() interface{} + Ping() (_swig_ret string) + Pong() (_swig_ret string) + FooBar(arg2 FooBar) (_swig_ret string) + MakeFoo() (_swig_ret Foo) + MakeFooBar() (_swig_ret FooBar) +} + + +type SwigcptrSwigDirector_Foo uintptr +type SwigDirector_Foo interface { + Swigcptr() uintptr; +} +func (p SwigcptrSwigDirector_Foo) Swigcptr() uintptr { + return uintptr(p) +} + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/director_nspace_director_name_collision.go b/Examples/test-suite/go/director_nspace_director_name_collision.go new file mode 100644 index 000000000..4c69b1be0 --- /dev/null +++ b/Examples/test-suite/go/director_nspace_director_name_collision.go @@ -0,0 +1,180 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../director_nspace_director_name_collision.i + +package director_nspace_director_name_collision + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type _swig_DirectorFoo struct { + SwigcptrFoo + v interface{} +} + +func (p *_swig_DirectorFoo) Swigcptr() uintptr { + return p.SwigcptrFoo.Swigcptr() +} + +func (p *_swig_DirectorFoo) SwigIsFoo() { +} + +func (p *_swig_DirectorFoo) DirectorInterface() interface{} { + return p.v +} + +var _wrap__swig_NewDirectorFooFoo unsafe.Pointer + +func _swig_NewDirectorFooFoo(_swig_director *_swig_DirectorFoo) (_swig_ret SwigcptrFoo) { + _swig_p := uintptr(unsafe.Pointer(&_swig_director)) + _cgo_runtime_cgocall(_wrap__swig_NewDirectorFooFoo, _swig_p) + return +} + +func NewDirectorFoo(v interface{}) Foo { + p := &_swig_DirectorFoo{0, v} + p.SwigcptrFoo = _swig_NewDirectorFooFoo(p) + return p +} + +var _wrap_DeleteDirectorFoo unsafe.Pointer + +func _swig_wrap_DeleteDirectorFoo(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_DeleteDirectorFoo, _swig_p) + return +} + +func DeleteDirectorFoo(arg1 Foo) { + _swig_wrap_DeleteDirectorFoo(arg1.Swigcptr()) +} + +func Swiggo_DeleteDirector_Foo(p *_swig_DirectorFoo) { + p.SwigcptrFoo = 0 +} + +type _swig_DirectorInterfaceFooPing interface { + Ping() string +} + +var _wrap__swig_DirectorFoo_upcall_Ping unsafe.Pointer + +func _swig_wrap__swig_DirectorFoo_upcall_Ping(_swig_ptr SwigcptrFoo) (_swig_ret string) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) + _cgo_runtime_cgocall(_wrap__swig_DirectorFoo_upcall_Ping, _swig_p) + return +} + +func (swig_p *_swig_DirectorFoo) Ping() string { + if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceFooPing); swig_ok { + return swig_g.Ping() + } + var swig_r string + swig_r = _swig_wrap__swig_DirectorFoo_upcall_Ping(swig_p.SwigcptrFoo) + return swig_r +} + +func DirectorFooPing(p Foo) string { + var swig_r string + swig_r = _swig_wrap__swig_DirectorFoo_upcall_Ping(p.(*_swig_DirectorFoo).SwigcptrFoo) + return swig_r +} + +func Swig_DirectorFoo_callback_ping(p *_swig_DirectorFoo) (swig_result string) { + var swig_r string + swig_r = p.Ping() + return swig_r +} + +type SwigcptrFoo uintptr + +func (p SwigcptrFoo) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrFoo) SwigIsFoo() { +} + +func (p SwigcptrFoo) DirectorInterface() interface{} { + return nil +} + +var _wrap_delete_Foo unsafe.Pointer + +func _swig_wrap_delete_Foo(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Foo, _swig_p) + return +} + +func DeleteFoo(arg1 Foo) { + _swig_wrap_delete_Foo(arg1.Swigcptr()) +} + +var _wrap_Foo_ping unsafe.Pointer + +func _swig_wrap_Foo_ping(base SwigcptrFoo) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_ping, _swig_p) + return +} + +func (arg1 SwigcptrFoo) Ping() (_swig_ret string) { + return _swig_wrap_Foo_ping(arg1) +} + +var _wrap_new_Foo unsafe.Pointer + +func _swig_wrap_new_Foo() (base SwigcptrFoo) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Foo, _swig_p) + return +} + +func NewFoo() (_swig_ret Foo) { + return _swig_wrap_new_Foo() +} + +type Foo interface { + Swigcptr() uintptr + SwigIsFoo() + DirectorInterface() interface{} + Ping() (_swig_ret string) +} + + +type SwigcptrSwigDirector_Foo uintptr +type SwigDirector_Foo interface { + Swigcptr() uintptr; +} +func (p SwigcptrSwigDirector_Foo) Swigcptr() uintptr { + return uintptr(p) +} + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/director_nspace_director_name_collision_wrap.h b/Examples/test-suite/go/director_nspace_director_name_collision_wrap.h new file mode 100644 index 000000000..f202865c6 --- /dev/null +++ b/Examples/test-suite/go/director_nspace_director_name_collision_wrap.h @@ -0,0 +1,29 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../director_nspace_director_name_collision.i + +#ifndef SWIG_director_nspace_director_name_collision_WRAP_H_ +#define SWIG_director_nspace_director_name_collision_WRAP_H_ + +class SwigDirector_Foo : public TopLevel::A::Foo +{ + public: + SwigDirector_Foo(void *swig_p); + virtual ~SwigDirector_Foo(); + std::string _swig_upcall_ping() { + return TopLevel::A::Foo::ping(); + } + virtual std::string ping(); + private: + void *go_val; +}; + +#endif diff --git a/Examples/test-suite/go/director_nspace_wrap.h b/Examples/test-suite/go/director_nspace_wrap.h new file mode 100644 index 000000000..552fffa1f --- /dev/null +++ b/Examples/test-suite/go/director_nspace_wrap.h @@ -0,0 +1,45 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../director_nspace.i + +#ifndef SWIG_director_nspace_WRAP_H_ +#define SWIG_director_nspace_WRAP_H_ + +class SwigDirector_Foo : public TopLevel::Bar::Foo +{ + public: + SwigDirector_Foo(void *swig_p); + virtual ~SwigDirector_Foo(); + std::string _swig_upcall_ping() { + return TopLevel::Bar::Foo::ping(); + } + virtual std::string ping(); + std::string _swig_upcall_pong() { + return TopLevel::Bar::Foo::pong(); + } + virtual std::string pong(); + std::string _swig_upcall_fooBar(TopLevel::Bar::FooBar *fb) { + return TopLevel::Bar::Foo::fooBar(fb); + } + virtual std::string fooBar(TopLevel::Bar::FooBar *fb); + TopLevel::Bar::Foo _swig_upcall_makeFoo() { + return TopLevel::Bar::Foo::makeFoo(); + } + virtual TopLevel::Bar::Foo makeFoo(); + TopLevel::Bar::FooBar _swig_upcall_makeFooBar() { + return TopLevel::Bar::Foo::makeFooBar(); + } + virtual TopLevel::Bar::FooBar makeFooBar(); + private: + void *go_val; +}; + +#endif diff --git a/Examples/test-suite/go/director_overload.go b/Examples/test-suite/go/director_overload.go new file mode 100644 index 000000000..f99a600d4 --- /dev/null +++ b/Examples/test-suite/go/director_overload.go @@ -0,0 +1,862 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../director_overload.i + +package director_overload + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type _swig_DirectorOverloadedClass struct { + SwigcptrOverloadedClass + v interface{} +} + +func (p *_swig_DirectorOverloadedClass) Swigcptr() uintptr { + return p.SwigcptrOverloadedClass.Swigcptr() +} + +func (p *_swig_DirectorOverloadedClass) SwigIsOverloadedClass() { +} + +func (p *_swig_DirectorOverloadedClass) DirectorInterface() interface{} { + return p.v +} + +var _wrap__swig_NewDirectorOverloadedClassOverloadedClass unsafe.Pointer + +func _swig_NewDirectorOverloadedClassOverloadedClass(_swig_director *_swig_DirectorOverloadedClass) (_swig_ret SwigcptrOverloadedClass) { + _swig_p := uintptr(unsafe.Pointer(&_swig_director)) + _cgo_runtime_cgocall(_wrap__swig_NewDirectorOverloadedClassOverloadedClass, _swig_p) + return +} + +func NewDirectorOverloadedClass(v interface{}) OverloadedClass { + p := &_swig_DirectorOverloadedClass{0, v} + p.SwigcptrOverloadedClass = _swig_NewDirectorOverloadedClassOverloadedClass(p) + return p +} + +var _wrap_DeleteDirectorOverloadedClass unsafe.Pointer + +func _swig_wrap_DeleteDirectorOverloadedClass(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_DeleteDirectorOverloadedClass, _swig_p) + return +} + +func DeleteDirectorOverloadedClass(arg1 OverloadedClass) { + _swig_wrap_DeleteDirectorOverloadedClass(arg1.Swigcptr()) +} + +func Swiggo_DeleteDirector_OverloadedClass(p *_swig_DirectorOverloadedClass) { + p.SwigcptrOverloadedClass = 0 +} + +type _swig_DirectorInterfaceOverloadedClassMethod1 interface { + Method1() +} + +var _wrap__swig_DirectorOverloadedClass_upcall_Method1 unsafe.Pointer + +func _swig_wrap__swig_DirectorOverloadedClass_upcall_Method1(_swig_ptr SwigcptrOverloadedClass) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) + _cgo_runtime_cgocall(_wrap__swig_DirectorOverloadedClass_upcall_Method1, _swig_p) + return +} + +func (swig_p *_swig_DirectorOverloadedClass) Method1() { + if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceOverloadedClassMethod1); swig_ok { + swig_g.Method1() + return + } + _swig_wrap__swig_DirectorOverloadedClass_upcall_Method1(swig_p.SwigcptrOverloadedClass) +} + +func DirectorOverloadedClassMethod1(p OverloadedClass) { + _swig_wrap__swig_DirectorOverloadedClass_upcall_Method1(p.(*_swig_DirectorOverloadedClass).SwigcptrOverloadedClass) +} + +func Swig_DirectorOverloadedClass_callback_method1(p *_swig_DirectorOverloadedClass) { + p.Method1() +} + +type _swig_DirectorInterfaceOverloadedClassMethod2__SWIG_0 interface { + Method2__SWIG_0() +} + +var _wrap__swig_DirectorOverloadedClass_upcall_Method2__SWIG_0 unsafe.Pointer + +func _swig_wrap__swig_DirectorOverloadedClass_upcall_Method2__SWIG_0(_swig_ptr SwigcptrOverloadedClass) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) + _cgo_runtime_cgocall(_wrap__swig_DirectorOverloadedClass_upcall_Method2__SWIG_0, _swig_p) + return +} + +func (swig_p *_swig_DirectorOverloadedClass) Method2__SWIG_0() { + if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceOverloadedClassMethod2__SWIG_0); swig_ok { + swig_g.Method2__SWIG_0() + return + } + _swig_wrap__swig_DirectorOverloadedClass_upcall_Method2__SWIG_0(swig_p.SwigcptrOverloadedClass) +} + +func DirectorOverloadedClassMethod2__SWIG_0(p OverloadedClass) { + _swig_wrap__swig_DirectorOverloadedClass_upcall_Method2__SWIG_0(p.(*_swig_DirectorOverloadedClass).SwigcptrOverloadedClass) +} + +func Swig_DirectorOverloadedClass_callback_method2__SWIG_0(p *_swig_DirectorOverloadedClass) { + p.Method2__SWIG_0() +} + +type _swig_DirectorInterfaceOverloadedClassMethod3 interface { + Method3() +} + +var _wrap__swig_DirectorOverloadedClass_upcall_Method3 unsafe.Pointer + +func _swig_wrap__swig_DirectorOverloadedClass_upcall_Method3(_swig_ptr SwigcptrOverloadedClass) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) + _cgo_runtime_cgocall(_wrap__swig_DirectorOverloadedClass_upcall_Method3, _swig_p) + return +} + +func (swig_p *_swig_DirectorOverloadedClass) Method3() { + if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceOverloadedClassMethod3); swig_ok { + swig_g.Method3() + return + } + _swig_wrap__swig_DirectorOverloadedClass_upcall_Method3(swig_p.SwigcptrOverloadedClass) +} + +func DirectorOverloadedClassMethod3(p OverloadedClass) { + _swig_wrap__swig_DirectorOverloadedClass_upcall_Method3(p.(*_swig_DirectorOverloadedClass).SwigcptrOverloadedClass) +} + +func Swig_DirectorOverloadedClass_callback_method3(p *_swig_DirectorOverloadedClass) { + p.Method3() +} + +type _swig_DirectorInterfaceOverloadedClassMethod2__SWIG_1 interface { + Method2__SWIG_1(bool) +} + +var _wrap__swig_DirectorOverloadedClass_upcall_Method2__SWIG_1 unsafe.Pointer + +func _swig_wrap__swig_DirectorOverloadedClass_upcall_Method2__SWIG_1(_swig_ptr SwigcptrOverloadedClass, _ bool) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) + _cgo_runtime_cgocall(_wrap__swig_DirectorOverloadedClass_upcall_Method2__SWIG_1, _swig_p) + return +} + +func (swig_p *_swig_DirectorOverloadedClass) Method2__SWIG_1(b bool) { + if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceOverloadedClassMethod2__SWIG_1); swig_ok { + swig_g.Method2__SWIG_1(b) + return + } + _swig_wrap__swig_DirectorOverloadedClass_upcall_Method2__SWIG_1(swig_p.SwigcptrOverloadedClass, b) +} + +func DirectorOverloadedClassMethod2__SWIG_1(p OverloadedClass, arg2 bool) { + _swig_wrap__swig_DirectorOverloadedClass_upcall_Method2__SWIG_1(p.(*_swig_DirectorOverloadedClass).SwigcptrOverloadedClass, arg2) +} + +func Swig_DirectorOverloadedClass_callback_method2__SWIG_1(p *_swig_DirectorOverloadedClass, arg2 bool) { + p.Method2__SWIG_1(arg2) +} + +func (p _swig_DirectorOverloadedClass) Method2(a ...interface{}) { + argc := len(a) + if argc == 0 { + p.Method2__SWIG_0() + return + } + if argc == 1 { + p.Method2__SWIG_1(a[0].(bool)) + return + } + panic("No match for overloaded function call") +} + +func DirectorOverloadedClassMethod2(p *_swig_DirectorOverloadedClass, a ...interface{}) { + argc := len(a) + if argc == 0 { + DirectorOverloadedClassMethod2__SWIG_0(p) + return + } + if argc == 1 { + DirectorOverloadedClassMethod2__SWIG_1(p, a[0].(bool)) + return + } + panic("No match for overloaded function call") +} + +type SwigcptrOverloadedClass uintptr + +func (p SwigcptrOverloadedClass) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrOverloadedClass) SwigIsOverloadedClass() { +} + +func (p SwigcptrOverloadedClass) DirectorInterface() interface{} { + return nil +} + +var _wrap_delete_OverloadedClass unsafe.Pointer + +func _swig_wrap_delete_OverloadedClass(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_OverloadedClass, _swig_p) + return +} + +func DeleteOverloadedClass(arg1 OverloadedClass) { + _swig_wrap_delete_OverloadedClass(arg1.Swigcptr()) +} + +var _wrap_OverloadedClass_method1 unsafe.Pointer + +func _swig_wrap_OverloadedClass_method1(base SwigcptrOverloadedClass) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_OverloadedClass_method1, _swig_p) + return +} + +func (arg1 SwigcptrOverloadedClass) Method1() { + _swig_wrap_OverloadedClass_method1(arg1) +} + +var _wrap_OverloadedClass_method2__SWIG_0 unsafe.Pointer + +func _swig_wrap_OverloadedClass_method2__SWIG_0(base SwigcptrOverloadedClass) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_OverloadedClass_method2__SWIG_0, _swig_p) + return +} + +func (arg1 SwigcptrOverloadedClass) Method2__SWIG_0() { + _swig_wrap_OverloadedClass_method2__SWIG_0(arg1) +} + +var _wrap_OverloadedClass_method3 unsafe.Pointer + +func _swig_wrap_OverloadedClass_method3(base SwigcptrOverloadedClass) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_OverloadedClass_method3, _swig_p) + return +} + +func (arg1 SwigcptrOverloadedClass) Method3() { + _swig_wrap_OverloadedClass_method3(arg1) +} + +var _wrap_OverloadedClass_method2__SWIG_1 unsafe.Pointer + +func _swig_wrap_OverloadedClass_method2__SWIG_1(base SwigcptrOverloadedClass, _ bool) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_OverloadedClass_method2__SWIG_1, _swig_p) + return +} + +func (arg1 SwigcptrOverloadedClass) Method2__SWIG_1(arg2 bool) { + _swig_wrap_OverloadedClass_method2__SWIG_1(arg1, arg2) +} + +func (p SwigcptrOverloadedClass) Method2(a ...interface{}) { + argc := len(a) + if argc == 0 { + p.Method2__SWIG_0() + return + } + if argc == 1 { + p.Method2__SWIG_1(a[0].(bool)) + return + } + panic("No match for overloaded function call") +} + +var _wrap_new_OverloadedClass unsafe.Pointer + +func _swig_wrap_new_OverloadedClass() (base SwigcptrOverloadedClass) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_OverloadedClass, _swig_p) + return +} + +func NewOverloadedClass() (_swig_ret OverloadedClass) { + return _swig_wrap_new_OverloadedClass() +} + +type OverloadedClass interface { + Swigcptr() uintptr + SwigIsOverloadedClass() + DirectorInterface() interface{} + Method1() + Method3() + Method2(a ...interface{}) +} + +type _swig_DirectorOverloadedPointers struct { + SwigcptrOverloadedPointers + v interface{} +} + +func (p *_swig_DirectorOverloadedPointers) Swigcptr() uintptr { + return p.SwigcptrOverloadedPointers.Swigcptr() +} + +func (p *_swig_DirectorOverloadedPointers) SwigIsOverloadedPointers() { +} + +func (p *_swig_DirectorOverloadedPointers) DirectorInterface() interface{} { + return p.v +} + +var _wrap__swig_NewDirectorOverloadedPointersOverloadedPointers unsafe.Pointer + +func _swig_NewDirectorOverloadedPointersOverloadedPointers(_swig_director *_swig_DirectorOverloadedPointers) (_swig_ret SwigcptrOverloadedPointers) { + _swig_p := uintptr(unsafe.Pointer(&_swig_director)) + _cgo_runtime_cgocall(_wrap__swig_NewDirectorOverloadedPointersOverloadedPointers, _swig_p) + return +} + +func NewDirectorOverloadedPointers(v interface{}) OverloadedPointers { + p := &_swig_DirectorOverloadedPointers{0, v} + p.SwigcptrOverloadedPointers = _swig_NewDirectorOverloadedPointersOverloadedPointers(p) + return p +} + +var _wrap_DeleteDirectorOverloadedPointers unsafe.Pointer + +func _swig_wrap_DeleteDirectorOverloadedPointers(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_DeleteDirectorOverloadedPointers, _swig_p) + return +} + +func DeleteDirectorOverloadedPointers(arg1 OverloadedPointers) { + _swig_wrap_DeleteDirectorOverloadedPointers(arg1.Swigcptr()) +} + +func Swiggo_DeleteDirector_OverloadedPointers(p *_swig_DirectorOverloadedPointers) { + p.SwigcptrOverloadedPointers = 0 +} + +type _swig_DirectorInterfaceOverloadedPointersMethod__SWIG_0 interface { + Method__SWIG_0(*int) +} + +var _wrap__swig_DirectorOverloadedPointers_upcall_Method__SWIG_0 unsafe.Pointer + +func _swig_wrap__swig_DirectorOverloadedPointers_upcall_Method__SWIG_0(_swig_ptr SwigcptrOverloadedPointers, _ *int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) + _cgo_runtime_cgocall(_wrap__swig_DirectorOverloadedPointers_upcall_Method__SWIG_0, _swig_p) + return +} + +func (swig_p *_swig_DirectorOverloadedPointers) Method__SWIG_0(p *int) { + if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceOverloadedPointersMethod__SWIG_0); swig_ok { + swig_g.Method__SWIG_0(p) + return + } + _swig_wrap__swig_DirectorOverloadedPointers_upcall_Method__SWIG_0(swig_p.SwigcptrOverloadedPointers, p) +} + +func DirectorOverloadedPointersMethod__SWIG_0(p OverloadedPointers, arg2 *int) { + _swig_wrap__swig_DirectorOverloadedPointers_upcall_Method__SWIG_0(p.(*_swig_DirectorOverloadedPointers).SwigcptrOverloadedPointers, arg2) +} + +func Swig_DirectorOverloadedPointers_callback_method__SWIG_0(p *_swig_DirectorOverloadedPointers, arg2 *int) { + p.Method__SWIG_0(arg2) +} + +type _swig_DirectorInterfaceOverloadedPointersMethod__SWIG_1 interface { + Method__SWIG_1(*float64) +} + +var _wrap__swig_DirectorOverloadedPointers_upcall_Method__SWIG_1 unsafe.Pointer + +func _swig_wrap__swig_DirectorOverloadedPointers_upcall_Method__SWIG_1(_swig_ptr SwigcptrOverloadedPointers, _ *float64) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) + _cgo_runtime_cgocall(_wrap__swig_DirectorOverloadedPointers_upcall_Method__SWIG_1, _swig_p) + return +} + +func (swig_p *_swig_DirectorOverloadedPointers) Method__SWIG_1(p *float64) { + if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceOverloadedPointersMethod__SWIG_1); swig_ok { + swig_g.Method__SWIG_1(p) + return + } + _swig_wrap__swig_DirectorOverloadedPointers_upcall_Method__SWIG_1(swig_p.SwigcptrOverloadedPointers, p) +} + +func DirectorOverloadedPointersMethod__SWIG_1(p OverloadedPointers, arg2 *float64) { + _swig_wrap__swig_DirectorOverloadedPointers_upcall_Method__SWIG_1(p.(*_swig_DirectorOverloadedPointers).SwigcptrOverloadedPointers, arg2) +} + +func Swig_DirectorOverloadedPointers_callback_method__SWIG_1(p *_swig_DirectorOverloadedPointers, arg2 *float64) { + p.Method__SWIG_1(arg2) +} + +type _swig_DirectorInterfaceOverloadedPointersMethod__SWIG_2 interface { + Method__SWIG_2(*bool) +} + +var _wrap__swig_DirectorOverloadedPointers_upcall_Method__SWIG_2 unsafe.Pointer + +func _swig_wrap__swig_DirectorOverloadedPointers_upcall_Method__SWIG_2(_swig_ptr SwigcptrOverloadedPointers, _ *bool) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) + _cgo_runtime_cgocall(_wrap__swig_DirectorOverloadedPointers_upcall_Method__SWIG_2, _swig_p) + return +} + +func (swig_p *_swig_DirectorOverloadedPointers) Method__SWIG_2(r *bool) { + if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceOverloadedPointersMethod__SWIG_2); swig_ok { + swig_g.Method__SWIG_2(r) + return + } + _swig_wrap__swig_DirectorOverloadedPointers_upcall_Method__SWIG_2(swig_p.SwigcptrOverloadedPointers, r) +} + +func DirectorOverloadedPointersMethod__SWIG_2(p OverloadedPointers, arg2 *bool) { + _swig_wrap__swig_DirectorOverloadedPointers_upcall_Method__SWIG_2(p.(*_swig_DirectorOverloadedPointers).SwigcptrOverloadedPointers, arg2) +} + +func Swig_DirectorOverloadedPointers_callback_method__SWIG_2(p *_swig_DirectorOverloadedPointers, arg2 *bool) { + p.Method__SWIG_2(arg2) +} + +type _swig_DirectorInterfaceOverloadedPointersMethod__SWIG_3 interface { + Method__SWIG_3(*int16) +} + +var _wrap__swig_DirectorOverloadedPointers_upcall_Method__SWIG_3 unsafe.Pointer + +func _swig_wrap__swig_DirectorOverloadedPointers_upcall_Method__SWIG_3(_swig_ptr SwigcptrOverloadedPointers, _ *int16) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) + _cgo_runtime_cgocall(_wrap__swig_DirectorOverloadedPointers_upcall_Method__SWIG_3, _swig_p) + return +} + +func (swig_p *_swig_DirectorOverloadedPointers) Method__SWIG_3(r *int16) { + if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceOverloadedPointersMethod__SWIG_3); swig_ok { + swig_g.Method__SWIG_3(r) + return + } + _swig_wrap__swig_DirectorOverloadedPointers_upcall_Method__SWIG_3(swig_p.SwigcptrOverloadedPointers, r) +} + +func DirectorOverloadedPointersMethod__SWIG_3(p OverloadedPointers, arg2 *int16) { + _swig_wrap__swig_DirectorOverloadedPointers_upcall_Method__SWIG_3(p.(*_swig_DirectorOverloadedPointers).SwigcptrOverloadedPointers, arg2) +} + +func Swig_DirectorOverloadedPointers_callback_method__SWIG_3(p *_swig_DirectorOverloadedPointers, arg2 *int16) { + p.Method__SWIG_3(arg2) +} + +type _swig_DirectorInterfaceOverloadedPointersMethod__SWIG_4 interface { + Method__SWIG_4(OverloadedClass) +} + +var _wrap__swig_DirectorOverloadedPointers_upcall_Method__SWIG_4 unsafe.Pointer + +func _swig_wrap__swig_DirectorOverloadedPointers_upcall_Method__SWIG_4(_swig_ptr SwigcptrOverloadedPointers, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) + _cgo_runtime_cgocall(_wrap__swig_DirectorOverloadedPointers_upcall_Method__SWIG_4, _swig_p) + return +} + +func (swig_p *_swig_DirectorOverloadedPointers) Method__SWIG_4(p OverloadedClass) { + if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceOverloadedPointersMethod__SWIG_4); swig_ok { + swig_g.Method__SWIG_4(p) + return + } + _swig_wrap__swig_DirectorOverloadedPointers_upcall_Method__SWIG_4(swig_p.SwigcptrOverloadedPointers, p.Swigcptr()) +} + +func DirectorOverloadedPointersMethod__SWIG_4(p OverloadedPointers, arg2 OverloadedClass) { + _swig_wrap__swig_DirectorOverloadedPointers_upcall_Method__SWIG_4(p.(*_swig_DirectorOverloadedPointers).SwigcptrOverloadedPointers, arg2.Swigcptr()) +} + +func Swig_DirectorOverloadedPointers_callback_method__SWIG_4(p *_swig_DirectorOverloadedPointers, arg2 uintptr) { + p.Method__SWIG_4(SwigcptrOverloadedClass(arg2)) +} + +type _swig_DirectorInterfaceOverloadedPointersMethod__SWIG_5 interface { + Method__SWIG_5(OverloadedPointers) +} + +var _wrap__swig_DirectorOverloadedPointers_upcall_Method__SWIG_5 unsafe.Pointer + +func _swig_wrap__swig_DirectorOverloadedPointers_upcall_Method__SWIG_5(_swig_ptr SwigcptrOverloadedPointers, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) + _cgo_runtime_cgocall(_wrap__swig_DirectorOverloadedPointers_upcall_Method__SWIG_5, _swig_p) + return +} + +func (swig_p *_swig_DirectorOverloadedPointers) Method__SWIG_5(p OverloadedPointers) { + if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceOverloadedPointersMethod__SWIG_5); swig_ok { + swig_g.Method__SWIG_5(p) + return + } + _swig_wrap__swig_DirectorOverloadedPointers_upcall_Method__SWIG_5(swig_p.SwigcptrOverloadedPointers, p.Swigcptr()) +} + +func DirectorOverloadedPointersMethod__SWIG_5(p OverloadedPointers, arg2 OverloadedPointers) { + _swig_wrap__swig_DirectorOverloadedPointers_upcall_Method__SWIG_5(p.(*_swig_DirectorOverloadedPointers).SwigcptrOverloadedPointers, arg2.Swigcptr()) +} + +func Swig_DirectorOverloadedPointers_callback_method__SWIG_5(p *_swig_DirectorOverloadedPointers, arg2 uintptr) { + p.Method__SWIG_5(SwigcptrOverloadedPointers(arg2)) +} + +func (p _swig_DirectorOverloadedPointers) Method(a ...interface{}) { + argc := len(a) + if argc == 1 { + if _, ok := a[0].(*int); !ok { + goto check_1 + } + p.Method__SWIG_0(a[0].(*int)) + return + } +check_1: + if argc == 1 { + if _, ok := a[0].(*float64); !ok { + goto check_2 + } + p.Method__SWIG_1(a[0].(*float64)) + return + } +check_2: + if argc == 1 { + if _, ok := a[0].(*bool); !ok { + goto check_3 + } + p.Method__SWIG_2(a[0].(*bool)) + return + } +check_3: + if argc == 1 { + if _, ok := a[0].(*int16); !ok { + goto check_4 + } + p.Method__SWIG_3(a[0].(*int16)) + return + } +check_4: + if argc == 1 { + if _, ok := a[0].(OverloadedClass); !ok { + goto check_5 + } + p.Method__SWIG_4(a[0].(OverloadedClass)) + return + } +check_5: + if argc == 1 { + p.Method__SWIG_5(a[0].(OverloadedPointers)) + return + } + panic("No match for overloaded function call") +} + +func DirectorOverloadedPointersMethod(p *_swig_DirectorOverloadedPointers, a ...interface{}) { + argc := len(a) + if argc == 1 { + if _, ok := a[0].(*int); !ok { + goto check_1 + } + DirectorOverloadedPointersMethod__SWIG_0(p, a[0].(*int)) + return + } +check_1: + if argc == 1 { + if _, ok := a[0].(*float64); !ok { + goto check_2 + } + DirectorOverloadedPointersMethod__SWIG_1(p, a[0].(*float64)) + return + } +check_2: + if argc == 1 { + if _, ok := a[0].(*bool); !ok { + goto check_3 + } + DirectorOverloadedPointersMethod__SWIG_2(p, a[0].(*bool)) + return + } +check_3: + if argc == 1 { + if _, ok := a[0].(*int16); !ok { + goto check_4 + } + DirectorOverloadedPointersMethod__SWIG_3(p, a[0].(*int16)) + return + } +check_4: + if argc == 1 { + if _, ok := a[0].(OverloadedClass); !ok { + goto check_5 + } + DirectorOverloadedPointersMethod__SWIG_4(p, a[0].(OverloadedClass)) + return + } +check_5: + if argc == 1 { + DirectorOverloadedPointersMethod__SWIG_5(p, a[0].(OverloadedPointers)) + return + } + panic("No match for overloaded function call") +} + +type _swig_DirectorInterfaceOverloadedPointersNotover interface { + Notover(*int) +} + +var _wrap__swig_DirectorOverloadedPointers_upcall_Notover unsafe.Pointer + +func _swig_wrap__swig_DirectorOverloadedPointers_upcall_Notover(_swig_ptr SwigcptrOverloadedPointers, _ *int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) + _cgo_runtime_cgocall(_wrap__swig_DirectorOverloadedPointers_upcall_Notover, _swig_p) + return +} + +func (swig_p *_swig_DirectorOverloadedPointers) Notover(p *int) { + if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceOverloadedPointersNotover); swig_ok { + swig_g.Notover(p) + return + } + _swig_wrap__swig_DirectorOverloadedPointers_upcall_Notover(swig_p.SwigcptrOverloadedPointers, p) +} + +func DirectorOverloadedPointersNotover(p OverloadedPointers, arg2 *int) { + _swig_wrap__swig_DirectorOverloadedPointers_upcall_Notover(p.(*_swig_DirectorOverloadedPointers).SwigcptrOverloadedPointers, arg2) +} + +func Swig_DirectorOverloadedPointers_callback_notover(p *_swig_DirectorOverloadedPointers, arg2 *int) { + p.Notover(arg2) +} + +type SwigcptrOverloadedPointers uintptr + +func (p SwigcptrOverloadedPointers) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrOverloadedPointers) SwigIsOverloadedPointers() { +} + +func (p SwigcptrOverloadedPointers) DirectorInterface() interface{} { + return nil +} + +var _wrap_delete_OverloadedPointers unsafe.Pointer + +func _swig_wrap_delete_OverloadedPointers(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_OverloadedPointers, _swig_p) + return +} + +func DeleteOverloadedPointers(arg1 OverloadedPointers) { + _swig_wrap_delete_OverloadedPointers(arg1.Swigcptr()) +} + +var _wrap_OverloadedPointers_method__SWIG_0 unsafe.Pointer + +func _swig_wrap_OverloadedPointers_method__SWIG_0(base SwigcptrOverloadedPointers, _ *int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_OverloadedPointers_method__SWIG_0, _swig_p) + return +} + +func (arg1 SwigcptrOverloadedPointers) Method__SWIG_0(arg2 *int) { + _swig_wrap_OverloadedPointers_method__SWIG_0(arg1, arg2) +} + +var _wrap_OverloadedPointers_method__SWIG_1 unsafe.Pointer + +func _swig_wrap_OverloadedPointers_method__SWIG_1(base SwigcptrOverloadedPointers, _ *float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_OverloadedPointers_method__SWIG_1, _swig_p) + return +} + +func (arg1 SwigcptrOverloadedPointers) Method__SWIG_1(arg2 *float64) { + _swig_wrap_OverloadedPointers_method__SWIG_1(arg1, arg2) +} + +var _wrap_OverloadedPointers_method__SWIG_2 unsafe.Pointer + +func _swig_wrap_OverloadedPointers_method__SWIG_2(base SwigcptrOverloadedPointers, _ *bool) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_OverloadedPointers_method__SWIG_2, _swig_p) + return +} + +func (arg1 SwigcptrOverloadedPointers) Method__SWIG_2(arg2 *bool) { + _swig_wrap_OverloadedPointers_method__SWIG_2(arg1, arg2) +} + +var _wrap_OverloadedPointers_method__SWIG_3 unsafe.Pointer + +func _swig_wrap_OverloadedPointers_method__SWIG_3(base SwigcptrOverloadedPointers, _ *int16) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_OverloadedPointers_method__SWIG_3, _swig_p) + return +} + +func (arg1 SwigcptrOverloadedPointers) Method__SWIG_3(arg2 *int16) { + _swig_wrap_OverloadedPointers_method__SWIG_3(arg1, arg2) +} + +var _wrap_OverloadedPointers_method__SWIG_4 unsafe.Pointer + +func _swig_wrap_OverloadedPointers_method__SWIG_4(base SwigcptrOverloadedPointers, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_OverloadedPointers_method__SWIG_4, _swig_p) + return +} + +func (arg1 SwigcptrOverloadedPointers) Method__SWIG_4(arg2 OverloadedClass) { + _swig_wrap_OverloadedPointers_method__SWIG_4(arg1, arg2.Swigcptr()) +} + +var _wrap_OverloadedPointers_method__SWIG_5 unsafe.Pointer + +func _swig_wrap_OverloadedPointers_method__SWIG_5(base SwigcptrOverloadedPointers, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_OverloadedPointers_method__SWIG_5, _swig_p) + return +} + +func (arg1 SwigcptrOverloadedPointers) Method__SWIG_5(arg2 OverloadedPointers) { + _swig_wrap_OverloadedPointers_method__SWIG_5(arg1, arg2.Swigcptr()) +} + +func (p SwigcptrOverloadedPointers) Method(a ...interface{}) { + argc := len(a) + if argc == 1 { + if _, ok := a[0].(*int); !ok { + goto check_1 + } + p.Method__SWIG_0(a[0].(*int)) + return + } +check_1: + if argc == 1 { + if _, ok := a[0].(*float64); !ok { + goto check_2 + } + p.Method__SWIG_1(a[0].(*float64)) + return + } +check_2: + if argc == 1 { + if _, ok := a[0].(*bool); !ok { + goto check_3 + } + p.Method__SWIG_2(a[0].(*bool)) + return + } +check_3: + if argc == 1 { + if _, ok := a[0].(*int16); !ok { + goto check_4 + } + p.Method__SWIG_3(a[0].(*int16)) + return + } +check_4: + if argc == 1 { + if _, ok := a[0].(OverloadedClass); !ok { + goto check_5 + } + p.Method__SWIG_4(a[0].(OverloadedClass)) + return + } +check_5: + if argc == 1 { + p.Method__SWIG_5(a[0].(OverloadedPointers)) + return + } + panic("No match for overloaded function call") +} + +var _wrap_OverloadedPointers_notover unsafe.Pointer + +func _swig_wrap_OverloadedPointers_notover(base SwigcptrOverloadedPointers, _ *int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_OverloadedPointers_notover, _swig_p) + return +} + +func (arg1 SwigcptrOverloadedPointers) Notover(arg2 *int) { + _swig_wrap_OverloadedPointers_notover(arg1, arg2) +} + +var _wrap_new_OverloadedPointers unsafe.Pointer + +func _swig_wrap_new_OverloadedPointers() (base SwigcptrOverloadedPointers) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_OverloadedPointers, _swig_p) + return +} + +func NewOverloadedPointers() (_swig_ret OverloadedPointers) { + return _swig_wrap_new_OverloadedPointers() +} + +type OverloadedPointers interface { + Swigcptr() uintptr + SwigIsOverloadedPointers() + DirectorInterface() interface{} + Method(a ...interface{}) + Notover(arg2 *int) +} + + +type SwigcptrSwigDirector_OverloadedPointers uintptr +type SwigDirector_OverloadedPointers interface { + Swigcptr() uintptr; +} +func (p SwigcptrSwigDirector_OverloadedPointers) Swigcptr() uintptr { + return uintptr(p) +} + +type SwigcptrSwigDirector_OverloadedClass uintptr +type SwigDirector_OverloadedClass interface { + Swigcptr() uintptr; +} +func (p SwigcptrSwigDirector_OverloadedClass) Swigcptr() uintptr { + return uintptr(p) +} + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/director_overload2.go b/Examples/test-suite/go/director_overload2.go new file mode 100644 index 000000000..183c02a7b --- /dev/null +++ b/Examples/test-suite/go/director_overload2.go @@ -0,0 +1,727 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../director_overload2.i + +package director_overload2 + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type _swig_DirectorOverloadBase struct { + SwigcptrOverloadBase + v interface{} +} + +func (p *_swig_DirectorOverloadBase) Swigcptr() uintptr { + return p.SwigcptrOverloadBase.Swigcptr() +} + +func (p *_swig_DirectorOverloadBase) SwigIsOverloadBase() { +} + +func (p *_swig_DirectorOverloadBase) DirectorInterface() interface{} { + return p.v +} + +var _wrap__swig_NewDirectorOverloadBaseOverloadBase unsafe.Pointer + +func _swig_NewDirectorOverloadBaseOverloadBase(_swig_director *_swig_DirectorOverloadBase) (_swig_ret SwigcptrOverloadBase) { + _swig_p := uintptr(unsafe.Pointer(&_swig_director)) + _cgo_runtime_cgocall(_wrap__swig_NewDirectorOverloadBaseOverloadBase, _swig_p) + return +} + +func NewDirectorOverloadBase(v interface{}) OverloadBase { + p := &_swig_DirectorOverloadBase{0, v} + p.SwigcptrOverloadBase = _swig_NewDirectorOverloadBaseOverloadBase(p) + return p +} + +var _wrap_DeleteDirectorOverloadBase unsafe.Pointer + +func _swig_wrap_DeleteDirectorOverloadBase(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_DeleteDirectorOverloadBase, _swig_p) + return +} + +func DeleteDirectorOverloadBase(arg1 OverloadBase) { + _swig_wrap_DeleteDirectorOverloadBase(arg1.Swigcptr()) +} + +func Swiggo_DeleteDirector_OverloadBase(p *_swig_DirectorOverloadBase) { + p.SwigcptrOverloadBase = 0 +} + +type _swig_DirectorInterfaceOverloadBaseMmm interface { + Mmm() +} + +var _wrap__swig_DirectorOverloadBase_upcall_Mmm unsafe.Pointer + +func _swig_wrap__swig_DirectorOverloadBase_upcall_Mmm(_swig_ptr SwigcptrOverloadBase) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) + _cgo_runtime_cgocall(_wrap__swig_DirectorOverloadBase_upcall_Mmm, _swig_p) + return +} + +func (swig_p *_swig_DirectorOverloadBase) Mmm() { + if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceOverloadBaseMmm); swig_ok { + swig_g.Mmm() + return + } + _swig_wrap__swig_DirectorOverloadBase_upcall_Mmm(swig_p.SwigcptrOverloadBase) +} + +func DirectorOverloadBaseMmm(p OverloadBase) { + _swig_wrap__swig_DirectorOverloadBase_upcall_Mmm(p.(*_swig_DirectorOverloadBase).SwigcptrOverloadBase) +} + +func Swig_DirectorOverloadBase_callback_mmm(p *_swig_DirectorOverloadBase) { + p.Mmm() +} + +type _swig_DirectorInterfaceOverloadBaseNnn__SWIG_0 interface { + Nnn__SWIG_0(int) +} + +var _wrap__swig_DirectorOverloadBase_upcall_Nnn__SWIG_0 unsafe.Pointer + +func _swig_wrap__swig_DirectorOverloadBase_upcall_Nnn__SWIG_0(_swig_ptr SwigcptrOverloadBase, _ int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) + _cgo_runtime_cgocall(_wrap__swig_DirectorOverloadBase_upcall_Nnn__SWIG_0, _swig_p) + return +} + +func (swig_p *_swig_DirectorOverloadBase) Nnn__SWIG_0(vvv int) { + if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceOverloadBaseNnn__SWIG_0); swig_ok { + swig_g.Nnn__SWIG_0(vvv) + return + } + _swig_wrap__swig_DirectorOverloadBase_upcall_Nnn__SWIG_0(swig_p.SwigcptrOverloadBase, vvv) +} + +func DirectorOverloadBaseNnn__SWIG_0(p OverloadBase, arg2 int) { + _swig_wrap__swig_DirectorOverloadBase_upcall_Nnn__SWIG_0(p.(*_swig_DirectorOverloadBase).SwigcptrOverloadBase, arg2) +} + +func Swig_DirectorOverloadBase_callback_nnn__SWIG_0(p *_swig_DirectorOverloadBase, arg2 int) { + p.Nnn__SWIG_0(arg2) +} + +type _swig_DirectorInterfaceOverloadBaseNnn__SWIG_1 interface { + Nnn__SWIG_1() +} + +var _wrap__swig_DirectorOverloadBase_upcall_Nnn__SWIG_1 unsafe.Pointer + +func _swig_wrap__swig_DirectorOverloadBase_upcall_Nnn__SWIG_1(_swig_ptr SwigcptrOverloadBase) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) + _cgo_runtime_cgocall(_wrap__swig_DirectorOverloadBase_upcall_Nnn__SWIG_1, _swig_p) + return +} + +func (swig_p *_swig_DirectorOverloadBase) Nnn__SWIG_1() { + if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceOverloadBaseNnn__SWIG_1); swig_ok { + swig_g.Nnn__SWIG_1() + return + } + _swig_wrap__swig_DirectorOverloadBase_upcall_Nnn__SWIG_1(swig_p.SwigcptrOverloadBase) +} + +func DirectorOverloadBaseNnn__SWIG_1(p OverloadBase) { + _swig_wrap__swig_DirectorOverloadBase_upcall_Nnn__SWIG_1(p.(*_swig_DirectorOverloadBase).SwigcptrOverloadBase) +} + +func Swig_DirectorOverloadBase_callback_nnn__SWIG_1(p *_swig_DirectorOverloadBase) { + p.Nnn__SWIG_1() +} + +func (p _swig_DirectorOverloadBase) Nnn(a ...interface{}) { + argc := len(a) + if argc == 0 { + p.Nnn__SWIG_1() + return + } + if argc == 1 { + p.Nnn__SWIG_0(a[0].(int)) + return + } + panic("No match for overloaded function call") +} + +func DirectorOverloadBaseNnn(p *_swig_DirectorOverloadBase, a ...interface{}) { + argc := len(a) + if argc == 0 { + DirectorOverloadBaseNnn__SWIG_1(p) + return + } + if argc == 1 { + DirectorOverloadBaseNnn__SWIG_0(p, a[0].(int)) + return + } + panic("No match for overloaded function call") +} + +type SwigcptrOverloadBase uintptr + +func (p SwigcptrOverloadBase) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrOverloadBase) SwigIsOverloadBase() { +} + +func (p SwigcptrOverloadBase) DirectorInterface() interface{} { + return nil +} + +var _wrap_delete_OverloadBase unsafe.Pointer + +func _swig_wrap_delete_OverloadBase(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_OverloadBase, _swig_p) + return +} + +func DeleteOverloadBase(arg1 OverloadBase) { + _swig_wrap_delete_OverloadBase(arg1.Swigcptr()) +} + +var _wrap_OverloadBase_mmm unsafe.Pointer + +func _swig_wrap_OverloadBase_mmm(base SwigcptrOverloadBase) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_OverloadBase_mmm, _swig_p) + return +} + +func (arg1 SwigcptrOverloadBase) Mmm() { + _swig_wrap_OverloadBase_mmm(arg1) +} + +var _wrap_OverloadBase_nnn__SWIG_0 unsafe.Pointer + +func _swig_wrap_OverloadBase_nnn__SWIG_0(base SwigcptrOverloadBase, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_OverloadBase_nnn__SWIG_0, _swig_p) + return +} + +func (arg1 SwigcptrOverloadBase) Nnn__SWIG_0(arg2 int) { + _swig_wrap_OverloadBase_nnn__SWIG_0(arg1, arg2) +} + +var _wrap_OverloadBase_nnn__SWIG_1 unsafe.Pointer + +func _swig_wrap_OverloadBase_nnn__SWIG_1(base SwigcptrOverloadBase) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_OverloadBase_nnn__SWIG_1, _swig_p) + return +} + +func (arg1 SwigcptrOverloadBase) Nnn__SWIG_1() { + _swig_wrap_OverloadBase_nnn__SWIG_1(arg1) +} + +func (p SwigcptrOverloadBase) Nnn(a ...interface{}) { + argc := len(a) + if argc == 0 { + p.Nnn__SWIG_1() + return + } + if argc == 1 { + p.Nnn__SWIG_0(a[0].(int)) + return + } + panic("No match for overloaded function call") +} + +var _wrap_new_OverloadBase unsafe.Pointer + +func _swig_wrap_new_OverloadBase() (base SwigcptrOverloadBase) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_OverloadBase, _swig_p) + return +} + +func NewOverloadBase() (_swig_ret OverloadBase) { + return _swig_wrap_new_OverloadBase() +} + +type OverloadBase interface { + Swigcptr() uintptr + SwigIsOverloadBase() + DirectorInterface() interface{} + Mmm() + Nnn(a ...interface{}) +} + +type _swig_DirectorOverloadDerived1 struct { + SwigcptrOverloadDerived1 + v interface{} +} + +func (p *_swig_DirectorOverloadDerived1) Swigcptr() uintptr { + return p.SwigcptrOverloadDerived1.Swigcptr() +} + +func (p *_swig_DirectorOverloadDerived1) SwigIsOverloadDerived1() { +} + +func (p *_swig_DirectorOverloadDerived1) DirectorInterface() interface{} { + return p.v +} + +var _wrap__swig_NewDirectorOverloadDerived1OverloadDerived1 unsafe.Pointer + +func _swig_NewDirectorOverloadDerived1OverloadDerived1(_swig_director *_swig_DirectorOverloadDerived1) (_swig_ret SwigcptrOverloadDerived1) { + _swig_p := uintptr(unsafe.Pointer(&_swig_director)) + _cgo_runtime_cgocall(_wrap__swig_NewDirectorOverloadDerived1OverloadDerived1, _swig_p) + return +} + +func NewDirectorOverloadDerived1(v interface{}) OverloadDerived1 { + p := &_swig_DirectorOverloadDerived1{0, v} + p.SwigcptrOverloadDerived1 = _swig_NewDirectorOverloadDerived1OverloadDerived1(p) + return p +} + +var _wrap_DeleteDirectorOverloadDerived1 unsafe.Pointer + +func _swig_wrap_DeleteDirectorOverloadDerived1(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_DeleteDirectorOverloadDerived1, _swig_p) + return +} + +func DeleteDirectorOverloadDerived1(arg1 OverloadDerived1) { + _swig_wrap_DeleteDirectorOverloadDerived1(arg1.Swigcptr()) +} + +func Swiggo_DeleteDirector_OverloadDerived1(p *_swig_DirectorOverloadDerived1) { + p.SwigcptrOverloadDerived1 = 0 +} + +type _swig_DirectorInterfaceOverloadDerived1Mmm interface { + Mmm() +} + +var _wrap__swig_DirectorOverloadDerived1_upcall_Mmm unsafe.Pointer + +func _swig_wrap__swig_DirectorOverloadDerived1_upcall_Mmm(_swig_ptr SwigcptrOverloadDerived1) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) + _cgo_runtime_cgocall(_wrap__swig_DirectorOverloadDerived1_upcall_Mmm, _swig_p) + return +} + +func (swig_p *_swig_DirectorOverloadDerived1) Mmm() { + if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceOverloadDerived1Mmm); swig_ok { + swig_g.Mmm() + return + } + _swig_wrap__swig_DirectorOverloadDerived1_upcall_Mmm(swig_p.SwigcptrOverloadDerived1) +} + +func DirectorOverloadDerived1Mmm(p OverloadDerived1) { + _swig_wrap__swig_DirectorOverloadDerived1_upcall_Mmm(p.(*_swig_DirectorOverloadDerived1).SwigcptrOverloadDerived1) +} + +func Swig_DirectorOverloadDerived1_callback_mmm(p *_swig_DirectorOverloadDerived1) { + p.Mmm() +} + +type _swig_DirectorInterfaceOverloadDerived1Nnn interface { + Nnn(int) +} + +var _wrap__swig_DirectorOverloadDerived1_upcall_Nnn unsafe.Pointer + +func _swig_wrap__swig_DirectorOverloadDerived1_upcall_Nnn(_swig_ptr SwigcptrOverloadDerived1, _ int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) + _cgo_runtime_cgocall(_wrap__swig_DirectorOverloadDerived1_upcall_Nnn, _swig_p) + return +} + +func (swig_p *_swig_DirectorOverloadDerived1) Nnn(vvv int) { + if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceOverloadDerived1Nnn); swig_ok { + swig_g.Nnn(vvv) + return + } + _swig_wrap__swig_DirectorOverloadDerived1_upcall_Nnn(swig_p.SwigcptrOverloadDerived1, vvv) +} + +func DirectorOverloadDerived1Nnn(p OverloadDerived1, arg2 int) { + _swig_wrap__swig_DirectorOverloadDerived1_upcall_Nnn(p.(*_swig_DirectorOverloadDerived1).SwigcptrOverloadDerived1, arg2) +} + +func Swig_DirectorOverloadDerived1_callback_nnn(p *_swig_DirectorOverloadDerived1, arg2 int) { + p.Nnn(arg2) +} + +type _swig_DirectorInterfaceOverloadDerived1Nnn__SWIG_1 interface { + Nnn__SWIG_1() +} + +var _wrap__swig_DirectorOverloadDerived1_upcall_Nnn__SWIG_1 unsafe.Pointer + +func _swig_wrap__swig_DirectorOverloadDerived1_upcall_Nnn__SWIG_1(_swig_ptr SwigcptrOverloadDerived1) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) + _cgo_runtime_cgocall(_wrap__swig_DirectorOverloadDerived1_upcall_Nnn__SWIG_1, _swig_p) + return +} + +func (swig_p *_swig_DirectorOverloadDerived1) Nnn__SWIG_1() { + if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceOverloadDerived1Nnn__SWIG_1); swig_ok { + swig_g.Nnn__SWIG_1() + return + } + _swig_wrap__swig_DirectorOverloadDerived1_upcall_Nnn__SWIG_1(swig_p.SwigcptrOverloadDerived1) +} + +func DirectorOverloadDerived1Nnn__SWIG_1(p OverloadDerived1) { + _swig_wrap__swig_DirectorOverloadDerived1_upcall_Nnn__SWIG_1(p.(*_swig_DirectorOverloadDerived1).SwigcptrOverloadDerived1) +} + +func Swig_DirectorOverloadDerived1_callback_nnn__SWIG_1(p *_swig_DirectorOverloadDerived1) { + p.Nnn__SWIG_1() +} + +type SwigcptrOverloadDerived1 uintptr + +func (p SwigcptrOverloadDerived1) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrOverloadDerived1) SwigIsOverloadDerived1() { +} + +func (p SwigcptrOverloadDerived1) DirectorInterface() interface{} { + return nil +} + +var _wrap_OverloadDerived1_nnn unsafe.Pointer + +func _swig_wrap_OverloadDerived1_nnn(base SwigcptrOverloadDerived1, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_OverloadDerived1_nnn, _swig_p) + return +} + +func (arg1 SwigcptrOverloadDerived1) Nnn(arg2 int) { + _swig_wrap_OverloadDerived1_nnn(arg1, arg2) +} + +var _wrap_new_OverloadDerived1 unsafe.Pointer + +func _swig_wrap_new_OverloadDerived1() (base SwigcptrOverloadDerived1) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_OverloadDerived1, _swig_p) + return +} + +func NewOverloadDerived1() (_swig_ret OverloadDerived1) { + return _swig_wrap_new_OverloadDerived1() +} + +var _wrap_delete_OverloadDerived1 unsafe.Pointer + +func _swig_wrap_delete_OverloadDerived1(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_OverloadDerived1, _swig_p) + return +} + +func DeleteOverloadDerived1(arg1 OverloadDerived1) { + _swig_wrap_delete_OverloadDerived1(arg1.Swigcptr()) +} + +var _wrap_OverloadDerived1_mmm unsafe.Pointer + +func _swig_wrap_OverloadDerived1_mmm(base SwigcptrOverloadDerived1) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_OverloadDerived1_mmm, _swig_p) + return +} + +func (_swig_base SwigcptrOverloadDerived1) Mmm() { + _swig_wrap_OverloadDerived1_mmm(_swig_base) +} + +func (p SwigcptrOverloadDerived1) SwigIsOverloadBase() { +} + +func (p SwigcptrOverloadDerived1) SwigGetOverloadBase() OverloadBase { + return SwigcptrOverloadBase(p.Swigcptr()) +} + +type OverloadDerived1 interface { + Swigcptr() uintptr + SwigIsOverloadDerived1() + DirectorInterface() interface{} + Nnn(arg2 int) + Mmm() + SwigIsOverloadBase() + SwigGetOverloadBase() OverloadBase +} + +type _swig_DirectorOverloadDerived2 struct { + SwigcptrOverloadDerived2 + v interface{} +} + +func (p *_swig_DirectorOverloadDerived2) Swigcptr() uintptr { + return p.SwigcptrOverloadDerived2.Swigcptr() +} + +func (p *_swig_DirectorOverloadDerived2) SwigIsOverloadDerived2() { +} + +func (p *_swig_DirectorOverloadDerived2) DirectorInterface() interface{} { + return p.v +} + +var _wrap__swig_NewDirectorOverloadDerived2OverloadDerived2 unsafe.Pointer + +func _swig_NewDirectorOverloadDerived2OverloadDerived2(_swig_director *_swig_DirectorOverloadDerived2) (_swig_ret SwigcptrOverloadDerived2) { + _swig_p := uintptr(unsafe.Pointer(&_swig_director)) + _cgo_runtime_cgocall(_wrap__swig_NewDirectorOverloadDerived2OverloadDerived2, _swig_p) + return +} + +func NewDirectorOverloadDerived2(v interface{}) OverloadDerived2 { + p := &_swig_DirectorOverloadDerived2{0, v} + p.SwigcptrOverloadDerived2 = _swig_NewDirectorOverloadDerived2OverloadDerived2(p) + return p +} + +var _wrap_DeleteDirectorOverloadDerived2 unsafe.Pointer + +func _swig_wrap_DeleteDirectorOverloadDerived2(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_DeleteDirectorOverloadDerived2, _swig_p) + return +} + +func DeleteDirectorOverloadDerived2(arg1 OverloadDerived2) { + _swig_wrap_DeleteDirectorOverloadDerived2(arg1.Swigcptr()) +} + +func Swiggo_DeleteDirector_OverloadDerived2(p *_swig_DirectorOverloadDerived2) { + p.SwigcptrOverloadDerived2 = 0 +} + +type _swig_DirectorInterfaceOverloadDerived2Mmm interface { + Mmm() +} + +var _wrap__swig_DirectorOverloadDerived2_upcall_Mmm unsafe.Pointer + +func _swig_wrap__swig_DirectorOverloadDerived2_upcall_Mmm(_swig_ptr SwigcptrOverloadDerived2) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) + _cgo_runtime_cgocall(_wrap__swig_DirectorOverloadDerived2_upcall_Mmm, _swig_p) + return +} + +func (swig_p *_swig_DirectorOverloadDerived2) Mmm() { + if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceOverloadDerived2Mmm); swig_ok { + swig_g.Mmm() + return + } + _swig_wrap__swig_DirectorOverloadDerived2_upcall_Mmm(swig_p.SwigcptrOverloadDerived2) +} + +func DirectorOverloadDerived2Mmm(p OverloadDerived2) { + _swig_wrap__swig_DirectorOverloadDerived2_upcall_Mmm(p.(*_swig_DirectorOverloadDerived2).SwigcptrOverloadDerived2) +} + +func Swig_DirectorOverloadDerived2_callback_mmm(p *_swig_DirectorOverloadDerived2) { + p.Mmm() +} + +type _swig_DirectorInterfaceOverloadDerived2Nnn__SWIG_0 interface { + Nnn__SWIG_0(int) +} + +var _wrap__swig_DirectorOverloadDerived2_upcall_Nnn__SWIG_0 unsafe.Pointer + +func _swig_wrap__swig_DirectorOverloadDerived2_upcall_Nnn__SWIG_0(_swig_ptr SwigcptrOverloadDerived2, _ int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) + _cgo_runtime_cgocall(_wrap__swig_DirectorOverloadDerived2_upcall_Nnn__SWIG_0, _swig_p) + return +} + +func (swig_p *_swig_DirectorOverloadDerived2) Nnn__SWIG_0(vvv int) { + if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceOverloadDerived2Nnn__SWIG_0); swig_ok { + swig_g.Nnn__SWIG_0(vvv) + return + } + _swig_wrap__swig_DirectorOverloadDerived2_upcall_Nnn__SWIG_0(swig_p.SwigcptrOverloadDerived2, vvv) +} + +func DirectorOverloadDerived2Nnn__SWIG_0(p OverloadDerived2, arg2 int) { + _swig_wrap__swig_DirectorOverloadDerived2_upcall_Nnn__SWIG_0(p.(*_swig_DirectorOverloadDerived2).SwigcptrOverloadDerived2, arg2) +} + +func Swig_DirectorOverloadDerived2_callback_nnn__SWIG_0(p *_swig_DirectorOverloadDerived2, arg2 int) { + p.Nnn__SWIG_0(arg2) +} + +type _swig_DirectorInterfaceOverloadDerived2Nnn interface { + Nnn() +} + +var _wrap__swig_DirectorOverloadDerived2_upcall_Nnn unsafe.Pointer + +func _swig_wrap__swig_DirectorOverloadDerived2_upcall_Nnn(_swig_ptr SwigcptrOverloadDerived2) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) + _cgo_runtime_cgocall(_wrap__swig_DirectorOverloadDerived2_upcall_Nnn, _swig_p) + return +} + +func (swig_p *_swig_DirectorOverloadDerived2) Nnn() { + if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceOverloadDerived2Nnn); swig_ok { + swig_g.Nnn() + return + } + _swig_wrap__swig_DirectorOverloadDerived2_upcall_Nnn(swig_p.SwigcptrOverloadDerived2) +} + +func DirectorOverloadDerived2Nnn(p OverloadDerived2) { + _swig_wrap__swig_DirectorOverloadDerived2_upcall_Nnn(p.(*_swig_DirectorOverloadDerived2).SwigcptrOverloadDerived2) +} + +func Swig_DirectorOverloadDerived2_callback_nnn(p *_swig_DirectorOverloadDerived2) { + p.Nnn() +} + +type SwigcptrOverloadDerived2 uintptr + +func (p SwigcptrOverloadDerived2) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrOverloadDerived2) SwigIsOverloadDerived2() { +} + +func (p SwigcptrOverloadDerived2) DirectorInterface() interface{} { + return nil +} + +var _wrap_OverloadDerived2_nnn unsafe.Pointer + +func _swig_wrap_OverloadDerived2_nnn(base SwigcptrOverloadDerived2) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_OverloadDerived2_nnn, _swig_p) + return +} + +func (arg1 SwigcptrOverloadDerived2) Nnn() { + _swig_wrap_OverloadDerived2_nnn(arg1) +} + +var _wrap_new_OverloadDerived2 unsafe.Pointer + +func _swig_wrap_new_OverloadDerived2() (base SwigcptrOverloadDerived2) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_OverloadDerived2, _swig_p) + return +} + +func NewOverloadDerived2() (_swig_ret OverloadDerived2) { + return _swig_wrap_new_OverloadDerived2() +} + +var _wrap_delete_OverloadDerived2 unsafe.Pointer + +func _swig_wrap_delete_OverloadDerived2(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_OverloadDerived2, _swig_p) + return +} + +func DeleteOverloadDerived2(arg1 OverloadDerived2) { + _swig_wrap_delete_OverloadDerived2(arg1.Swigcptr()) +} + +var _wrap_OverloadDerived2_mmm unsafe.Pointer + +func _swig_wrap_OverloadDerived2_mmm(base SwigcptrOverloadDerived2) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_OverloadDerived2_mmm, _swig_p) + return +} + +func (_swig_base SwigcptrOverloadDerived2) Mmm() { + _swig_wrap_OverloadDerived2_mmm(_swig_base) +} + +func (p SwigcptrOverloadDerived2) SwigIsOverloadBase() { +} + +func (p SwigcptrOverloadDerived2) SwigGetOverloadBase() OverloadBase { + return SwigcptrOverloadBase(p.Swigcptr()) +} + +type OverloadDerived2 interface { + Swigcptr() uintptr + SwigIsOverloadDerived2() + DirectorInterface() interface{} + Nnn() + Mmm() + SwigIsOverloadBase() + SwigGetOverloadBase() OverloadBase +} + + +type SwigcptrSwigDirector_OverloadDerived1 uintptr +type SwigDirector_OverloadDerived1 interface { + Swigcptr() uintptr; +} +func (p SwigcptrSwigDirector_OverloadDerived1) Swigcptr() uintptr { + return uintptr(p) +} + +type SwigcptrSwigDirector_OverloadDerived2 uintptr +type SwigDirector_OverloadDerived2 interface { + Swigcptr() uintptr; +} +func (p SwigcptrSwigDirector_OverloadDerived2) Swigcptr() uintptr { + return uintptr(p) +} + +type SwigcptrSwigDirector_OverloadBase uintptr +type SwigDirector_OverloadBase interface { + Swigcptr() uintptr; +} +func (p SwigcptrSwigDirector_OverloadBase) Swigcptr() uintptr { + return uintptr(p) +} + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/director_overload2_wrap.h b/Examples/test-suite/go/director_overload2_wrap.h new file mode 100644 index 000000000..d1b97521e --- /dev/null +++ b/Examples/test-suite/go/director_overload2_wrap.h @@ -0,0 +1,79 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../director_overload2.i + +#ifndef SWIG_director_overload2_WRAP_H_ +#define SWIG_director_overload2_WRAP_H_ + +class SwigDirector_OverloadBase : public OverloadBase +{ + public: + SwigDirector_OverloadBase(void *swig_p); + virtual ~SwigDirector_OverloadBase(); + void _swig_upcall_mmm() { + OverloadBase::mmm(); + } + virtual void mmm(); + void _swig_upcall_nnn__SWIG_0(int vvv) { + OverloadBase::nnn(vvv); + } + virtual void nnn(int vvv); + void _swig_upcall_nnn__SWIG_1() { + OverloadBase::nnn(); + } + virtual void nnn(); + private: + void *go_val; +}; + +class SwigDirector_OverloadDerived1 : public OverloadDerived1 +{ + public: + SwigDirector_OverloadDerived1(void *swig_p); + virtual ~SwigDirector_OverloadDerived1(); + void _swig_upcall_mmm() { + OverloadBase::mmm(); + } + virtual void mmm(); + void _swig_upcall_nnn(int vvv) { + OverloadDerived1::nnn(vvv); + } + virtual void nnn(int vvv); + void _swig_upcall_nnn__SWIG_1() { + OverloadBase::nnn(); + } + virtual void nnn(); + private: + void *go_val; +}; + +class SwigDirector_OverloadDerived2 : public OverloadDerived2 +{ + public: + SwigDirector_OverloadDerived2(void *swig_p); + virtual ~SwigDirector_OverloadDerived2(); + void _swig_upcall_mmm() { + OverloadBase::mmm(); + } + virtual void mmm(); + void _swig_upcall_nnn__SWIG_0(int vvv) { + OverloadBase::nnn(vvv); + } + virtual void nnn(int vvv); + void _swig_upcall_nnn() { + OverloadDerived2::nnn(); + } + virtual void nnn(); + private: + void *go_val; +}; + +#endif diff --git a/Examples/test-suite/go/director_overload_wrap.h b/Examples/test-suite/go/director_overload_wrap.h new file mode 100644 index 000000000..19c96dd53 --- /dev/null +++ b/Examples/test-suite/go/director_overload_wrap.h @@ -0,0 +1,78 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../director_overload.i + +#ifndef SWIG_director_overload_WRAP_H_ +#define SWIG_director_overload_WRAP_H_ + +class SwigDirector_OverloadedClass : public OverloadedClass +{ + public: + SwigDirector_OverloadedClass(void *swig_p); + virtual ~SwigDirector_OverloadedClass(); + void _swig_upcall_method1() const { + OverloadedClass::method1(); + } + virtual void method1() const; + void _swig_upcall_method2__SWIG_0() const { + OverloadedClass::method2(); + } + virtual void method2() const; + void _swig_upcall_method3() const { + OverloadedClass::method3(); + } + virtual void method3() const; + void _swig_upcall_method2__SWIG_1(bool b) const { + OverloadedClass::method2(b); + } + virtual void method2(bool b) const; + private: + void *go_val; +}; + +class SwigDirector_OverloadedPointers : public OverloadedPointers +{ + public: + SwigDirector_OverloadedPointers(void *swig_p); + virtual ~SwigDirector_OverloadedPointers(); + void _swig_upcall_method__SWIG_0(int *p) const { + OverloadedPointers::method(p); + } + virtual void method(int *p) const; + void _swig_upcall_method__SWIG_1(double *p) const { + OverloadedPointers::method(p); + } + virtual void method(double *p) const; + void _swig_upcall_method__SWIG_2(bool &r) const { + OverloadedPointers::method(r); + } + virtual void method(bool &r) const; + void _swig_upcall_method__SWIG_3(short &r) const { + OverloadedPointers::method(r); + } + virtual void method(short &r) const; + void _swig_upcall_method__SWIG_4(OverloadedClass *p) const { + OverloadedPointers::method(p); + } + virtual void method(OverloadedClass *p) const; + void _swig_upcall_method__SWIG_5(OverloadedPointers *p) const { + OverloadedPointers::method(p); + } + virtual void method(OverloadedPointers *p) const; + void _swig_upcall_notover(int *p) const { + OverloadedPointers::notover(p); + } + virtual void notover(int *p) const; + private: + void *go_val; +}; + +#endif diff --git a/Examples/test-suite/go/director_primitives.go b/Examples/test-suite/go/director_primitives.go new file mode 100644 index 000000000..a9a566452 --- /dev/null +++ b/Examples/test-suite/go/director_primitives.go @@ -0,0 +1,1368 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../director_primitives.i + +package director_primitives + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +var _wrap_PrintDebug_set unsafe.Pointer + +func _swig_wrap_PrintDebug_set(base bool) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_PrintDebug_set, _swig_p) + return +} + +func SetPrintDebug(arg1 bool) { + _swig_wrap_PrintDebug_set(arg1) +} + +var _wrap_PrintDebug_get unsafe.Pointer + +func GetPrintDebug() (_swig_ret bool) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_PrintDebug_get, _swig_p) + return +} +type HShadowMode int +var _wrap_HShadowNone unsafe.Pointer + +func _swig_getHShadowNone() (_swig_ret HShadowMode) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_HShadowNone, _swig_p) + return +} +var HShadowNone HShadowMode = _swig_getHShadowNone() +var _wrap_HShadowSoft unsafe.Pointer + +func _swig_getHShadowSoft() (_swig_ret HShadowMode) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_HShadowSoft, _swig_p) + return +} +var HShadowSoft HShadowMode = _swig_getHShadowSoft() +var _wrap_HShadowHard unsafe.Pointer + +func _swig_getHShadowHard() (_swig_ret HShadowMode) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_HShadowHard, _swig_p) + return +} +var HShadowHard HShadowMode = _swig_getHShadowHard() +type _swig_DirectorBase struct { + SwigcptrBase + v interface{} +} + +func (p *_swig_DirectorBase) Swigcptr() uintptr { + return p.SwigcptrBase.Swigcptr() +} + +func (p *_swig_DirectorBase) SwigIsBase() { +} + +func (p *_swig_DirectorBase) DirectorInterface() interface{} { + return p.v +} + +var _wrap__swig_NewDirectorBaseBase unsafe.Pointer + +func _swig_NewDirectorBaseBase(_swig_director *_swig_DirectorBase, _ float64) (_swig_ret SwigcptrBase) { + _swig_p := uintptr(unsafe.Pointer(&_swig_director)) + _cgo_runtime_cgocall(_wrap__swig_NewDirectorBaseBase, _swig_p) + return +} + +func NewDirectorBase(v interface{}, arg1 float64) Base { + p := &_swig_DirectorBase{0, v} + p.SwigcptrBase = _swig_NewDirectorBaseBase(p, arg1) + return p +} + +var _wrap_DeleteDirectorBase unsafe.Pointer + +func _swig_wrap_DeleteDirectorBase(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_DeleteDirectorBase, _swig_p) + return +} + +func DeleteDirectorBase(arg1 Base) { + _swig_wrap_DeleteDirectorBase(arg1.Swigcptr()) +} + +func Swiggo_DeleteDirector_Base(p *_swig_DirectorBase) { + p.SwigcptrBase = 0 +} + +type _swig_DirectorInterfaceBaseNoParmsMethod interface { + NoParmsMethod() +} + +var _wrap__swig_DirectorBase_upcall_NoParmsMethod unsafe.Pointer + +func _swig_wrap__swig_DirectorBase_upcall_NoParmsMethod(_swig_ptr SwigcptrBase) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) + _cgo_runtime_cgocall(_wrap__swig_DirectorBase_upcall_NoParmsMethod, _swig_p) + return +} + +func (swig_p *_swig_DirectorBase) NoParmsMethod() { + if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceBaseNoParmsMethod); swig_ok { + swig_g.NoParmsMethod() + return + } + _swig_wrap__swig_DirectorBase_upcall_NoParmsMethod(swig_p.SwigcptrBase) +} + +func DirectorBaseNoParmsMethod(p Base) { + _swig_wrap__swig_DirectorBase_upcall_NoParmsMethod(p.(*_swig_DirectorBase).SwigcptrBase) +} + +func Swig_DirectorBase_callback_NoParmsMethod(p *_swig_DirectorBase) { + p.NoParmsMethod() +} + +type _swig_DirectorInterfaceBaseBoolMethod interface { + BoolMethod(bool) bool +} + +var _wrap__swig_DirectorBase_upcall_BoolMethod unsafe.Pointer + +func _swig_wrap__swig_DirectorBase_upcall_BoolMethod(_swig_ptr SwigcptrBase, _ bool) (_swig_ret bool) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) + _cgo_runtime_cgocall(_wrap__swig_DirectorBase_upcall_BoolMethod, _swig_p) + return +} + +func (swig_p *_swig_DirectorBase) BoolMethod(x bool) bool { + if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceBaseBoolMethod); swig_ok { + return swig_g.BoolMethod(x) + } + var swig_r bool + swig_r = _swig_wrap__swig_DirectorBase_upcall_BoolMethod(swig_p.SwigcptrBase, x) + return swig_r +} + +func DirectorBaseBoolMethod(p Base, arg2 bool) bool { + var swig_r bool + swig_r = _swig_wrap__swig_DirectorBase_upcall_BoolMethod(p.(*_swig_DirectorBase).SwigcptrBase, arg2) + return swig_r +} + +func Swig_DirectorBase_callback_BoolMethod(p *_swig_DirectorBase, arg2 bool) (swig_result bool) { + var swig_r bool + swig_r = p.BoolMethod(arg2) + return swig_r +} + +type _swig_DirectorInterfaceBaseIntMethod interface { + IntMethod(int) int +} + +var _wrap__swig_DirectorBase_upcall_IntMethod unsafe.Pointer + +func _swig_wrap__swig_DirectorBase_upcall_IntMethod(_swig_ptr SwigcptrBase, _ int) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) + _cgo_runtime_cgocall(_wrap__swig_DirectorBase_upcall_IntMethod, _swig_p) + return +} + +func (swig_p *_swig_DirectorBase) IntMethod(x int) int { + if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceBaseIntMethod); swig_ok { + return swig_g.IntMethod(x) + } + var swig_r int + swig_r = _swig_wrap__swig_DirectorBase_upcall_IntMethod(swig_p.SwigcptrBase, x) + return swig_r +} + +func DirectorBaseIntMethod(p Base, arg2 int) int { + var swig_r int + swig_r = _swig_wrap__swig_DirectorBase_upcall_IntMethod(p.(*_swig_DirectorBase).SwigcptrBase, arg2) + return swig_r +} + +func Swig_DirectorBase_callback_IntMethod(p *_swig_DirectorBase, arg2 int) (swig_result int) { + var swig_r int + swig_r = p.IntMethod(arg2) + return swig_r +} + +type _swig_DirectorInterfaceBaseUIntMethod interface { + UIntMethod(uint) uint +} + +var _wrap__swig_DirectorBase_upcall_UIntMethod unsafe.Pointer + +func _swig_wrap__swig_DirectorBase_upcall_UIntMethod(_swig_ptr SwigcptrBase, _ uint) (_swig_ret uint) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) + _cgo_runtime_cgocall(_wrap__swig_DirectorBase_upcall_UIntMethod, _swig_p) + return +} + +func (swig_p *_swig_DirectorBase) UIntMethod(x uint) uint { + if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceBaseUIntMethod); swig_ok { + return swig_g.UIntMethod(x) + } + var swig_r uint + swig_r = _swig_wrap__swig_DirectorBase_upcall_UIntMethod(swig_p.SwigcptrBase, x) + return swig_r +} + +func DirectorBaseUIntMethod(p Base, arg2 uint) uint { + var swig_r uint + swig_r = _swig_wrap__swig_DirectorBase_upcall_UIntMethod(p.(*_swig_DirectorBase).SwigcptrBase, arg2) + return swig_r +} + +func Swig_DirectorBase_callback_UIntMethod(p *_swig_DirectorBase, arg2 uint) (swig_result uint) { + var swig_r uint + swig_r = p.UIntMethod(arg2) + return swig_r +} + +type _swig_DirectorInterfaceBaseFloatMethod interface { + FloatMethod(float32) float32 +} + +var _wrap__swig_DirectorBase_upcall_FloatMethod unsafe.Pointer + +func _swig_wrap__swig_DirectorBase_upcall_FloatMethod(_swig_ptr SwigcptrBase, _ float32) (_swig_ret float32) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) + _cgo_runtime_cgocall(_wrap__swig_DirectorBase_upcall_FloatMethod, _swig_p) + return +} + +func (swig_p *_swig_DirectorBase) FloatMethod(x float32) float32 { + if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceBaseFloatMethod); swig_ok { + return swig_g.FloatMethod(x) + } + var swig_r float32 + swig_r = _swig_wrap__swig_DirectorBase_upcall_FloatMethod(swig_p.SwigcptrBase, x) + return swig_r +} + +func DirectorBaseFloatMethod(p Base, arg2 float32) float32 { + var swig_r float32 + swig_r = _swig_wrap__swig_DirectorBase_upcall_FloatMethod(p.(*_swig_DirectorBase).SwigcptrBase, arg2) + return swig_r +} + +func Swig_DirectorBase_callback_FloatMethod(p *_swig_DirectorBase, arg2 float32) (swig_result float32) { + var swig_r float32 + swig_r = p.FloatMethod(arg2) + return swig_r +} + +type _swig_DirectorInterfaceBaseCharPtrMethod interface { + CharPtrMethod(string) string +} + +var _wrap__swig_DirectorBase_upcall_CharPtrMethod unsafe.Pointer + +func _swig_wrap__swig_DirectorBase_upcall_CharPtrMethod(_swig_ptr SwigcptrBase, _ string) (_swig_ret string) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) + _cgo_runtime_cgocall(_wrap__swig_DirectorBase_upcall_CharPtrMethod, _swig_p) + return +} + +func (swig_p *_swig_DirectorBase) CharPtrMethod(x string) string { + if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceBaseCharPtrMethod); swig_ok { + return swig_g.CharPtrMethod(x) + } + var swig_r string + swig_r = _swig_wrap__swig_DirectorBase_upcall_CharPtrMethod(swig_p.SwigcptrBase, x) + return swig_r +} + +func DirectorBaseCharPtrMethod(p Base, arg2 string) string { + var swig_r string + swig_r = _swig_wrap__swig_DirectorBase_upcall_CharPtrMethod(p.(*_swig_DirectorBase).SwigcptrBase, arg2) + return swig_r +} + +func Swig_DirectorBase_callback_CharPtrMethod(p *_swig_DirectorBase, arg2 string) (swig_result string) { + var swig_r string + swig_r = p.CharPtrMethod(arg2) + return swig_r +} + +type _swig_DirectorInterfaceBaseConstCharPtrMethod interface { + ConstCharPtrMethod(string) string +} + +var _wrap__swig_DirectorBase_upcall_ConstCharPtrMethod unsafe.Pointer + +func _swig_wrap__swig_DirectorBase_upcall_ConstCharPtrMethod(_swig_ptr SwigcptrBase, _ string) (_swig_ret string) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) + _cgo_runtime_cgocall(_wrap__swig_DirectorBase_upcall_ConstCharPtrMethod, _swig_p) + return +} + +func (swig_p *_swig_DirectorBase) ConstCharPtrMethod(x string) string { + if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceBaseConstCharPtrMethod); swig_ok { + return swig_g.ConstCharPtrMethod(x) + } + var swig_r string + swig_r = _swig_wrap__swig_DirectorBase_upcall_ConstCharPtrMethod(swig_p.SwigcptrBase, x) + return swig_r +} + +func DirectorBaseConstCharPtrMethod(p Base, arg2 string) string { + var swig_r string + swig_r = _swig_wrap__swig_DirectorBase_upcall_ConstCharPtrMethod(p.(*_swig_DirectorBase).SwigcptrBase, arg2) + return swig_r +} + +func Swig_DirectorBase_callback_ConstCharPtrMethod(p *_swig_DirectorBase, arg2 string) (swig_result string) { + var swig_r string + swig_r = p.ConstCharPtrMethod(arg2) + return swig_r +} + +type _swig_DirectorInterfaceBaseEnumMethod interface { + EnumMethod(HShadowMode) HShadowMode +} + +var _wrap__swig_DirectorBase_upcall_EnumMethod unsafe.Pointer + +func _swig_wrap__swig_DirectorBase_upcall_EnumMethod(_swig_ptr SwigcptrBase, _ HShadowMode) (_swig_ret HShadowMode) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) + _cgo_runtime_cgocall(_wrap__swig_DirectorBase_upcall_EnumMethod, _swig_p) + return +} + +func (swig_p *_swig_DirectorBase) EnumMethod(x HShadowMode) HShadowMode { + if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceBaseEnumMethod); swig_ok { + return swig_g.EnumMethod(x) + } + var swig_r HShadowMode + swig_r = _swig_wrap__swig_DirectorBase_upcall_EnumMethod(swig_p.SwigcptrBase, x) + return swig_r +} + +func DirectorBaseEnumMethod(p Base, arg2 HShadowMode) HShadowMode { + var swig_r HShadowMode + swig_r = _swig_wrap__swig_DirectorBase_upcall_EnumMethod(p.(*_swig_DirectorBase).SwigcptrBase, arg2) + return swig_r +} + +func Swig_DirectorBase_callback_EnumMethod(p *_swig_DirectorBase, arg2 HShadowMode) (swig_result HShadowMode) { + var swig_r HShadowMode + swig_r = p.EnumMethod(arg2) + return swig_r +} + +type _swig_DirectorInterfaceBaseManyParmsMethod interface { + ManyParmsMethod(bool, int, uint, float32, string, string, HShadowMode) +} + +var _wrap__swig_DirectorBase_upcall_ManyParmsMethod unsafe.Pointer + +func _swig_wrap__swig_DirectorBase_upcall_ManyParmsMethod(_swig_ptr SwigcptrBase, _ bool, _ int, _ uint, _ float32, _ string, _ string, _ HShadowMode) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) + _cgo_runtime_cgocall(_wrap__swig_DirectorBase_upcall_ManyParmsMethod, _swig_p) + return +} + +func (swig_p *_swig_DirectorBase) ManyParmsMethod(b bool, i int, u uint, f float32, c string, cc string, h HShadowMode) { + if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceBaseManyParmsMethod); swig_ok { + swig_g.ManyParmsMethod(b, i, u, f, c, cc, h) + return + } + _swig_wrap__swig_DirectorBase_upcall_ManyParmsMethod(swig_p.SwigcptrBase, b, i, u, f, c, cc, h) +} + +func DirectorBaseManyParmsMethod(p Base, arg2 bool, arg3 int, arg4 uint, arg5 float32, arg6 string, arg7 string, arg8 HShadowMode) { + _swig_wrap__swig_DirectorBase_upcall_ManyParmsMethod(p.(*_swig_DirectorBase).SwigcptrBase, arg2, arg3, arg4, arg5, arg6, arg7, arg8) +} + +func Swig_DirectorBase_callback_ManyParmsMethod(p *_swig_DirectorBase, arg2 bool, arg3 int, arg4 uint, arg5 float32, arg6 string, arg7 string, arg8 HShadowMode) { + p.ManyParmsMethod(arg2, arg3, arg4, arg5, arg6, arg7, arg8) +} + +type _swig_DirectorInterfaceBaseNotOverriddenMethod interface { + NotOverriddenMethod() +} + +var _wrap__swig_DirectorBase_upcall_NotOverriddenMethod unsafe.Pointer + +func _swig_wrap__swig_DirectorBase_upcall_NotOverriddenMethod(_swig_ptr SwigcptrBase) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) + _cgo_runtime_cgocall(_wrap__swig_DirectorBase_upcall_NotOverriddenMethod, _swig_p) + return +} + +func (swig_p *_swig_DirectorBase) NotOverriddenMethod() { + if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceBaseNotOverriddenMethod); swig_ok { + swig_g.NotOverriddenMethod() + return + } + _swig_wrap__swig_DirectorBase_upcall_NotOverriddenMethod(swig_p.SwigcptrBase) +} + +func DirectorBaseNotOverriddenMethod(p Base) { + _swig_wrap__swig_DirectorBase_upcall_NotOverriddenMethod(p.(*_swig_DirectorBase).SwigcptrBase) +} + +func Swig_DirectorBase_callback_NotOverriddenMethod(p *_swig_DirectorBase) { + p.NotOverriddenMethod() +} + +type SwigcptrBase uintptr + +func (p SwigcptrBase) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrBase) SwigIsBase() { +} + +func (p SwigcptrBase) DirectorInterface() interface{} { + return nil +} + +var _wrap_new_Base unsafe.Pointer + +func _swig_wrap_new_Base(base float64) (_ SwigcptrBase) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Base, _swig_p) + return +} + +func NewBase(arg1 float64) (_swig_ret Base) { + return _swig_wrap_new_Base(arg1) +} + +var _wrap_delete_Base unsafe.Pointer + +func _swig_wrap_delete_Base(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Base, _swig_p) + return +} + +func DeleteBase(arg1 Base) { + _swig_wrap_delete_Base(arg1.Swigcptr()) +} + +var _wrap_Base_NoParmsMethod unsafe.Pointer + +func _swig_wrap_Base_NoParmsMethod(base SwigcptrBase) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Base_NoParmsMethod, _swig_p) + return +} + +func (arg1 SwigcptrBase) NoParmsMethod() { + _swig_wrap_Base_NoParmsMethod(arg1) +} + +var _wrap_Base_BoolMethod unsafe.Pointer + +func _swig_wrap_Base_BoolMethod(base SwigcptrBase, _ bool) (_ bool) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Base_BoolMethod, _swig_p) + return +} + +func (arg1 SwigcptrBase) BoolMethod(arg2 bool) (_swig_ret bool) { + return _swig_wrap_Base_BoolMethod(arg1, arg2) +} + +var _wrap_Base_IntMethod unsafe.Pointer + +func _swig_wrap_Base_IntMethod(base SwigcptrBase, _ int) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Base_IntMethod, _swig_p) + return +} + +func (arg1 SwigcptrBase) IntMethod(arg2 int) (_swig_ret int) { + return _swig_wrap_Base_IntMethod(arg1, arg2) +} + +var _wrap_Base_UIntMethod unsafe.Pointer + +func _swig_wrap_Base_UIntMethod(base SwigcptrBase, _ uint) (_ uint) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Base_UIntMethod, _swig_p) + return +} + +func (arg1 SwigcptrBase) UIntMethod(arg2 uint) (_swig_ret uint) { + return _swig_wrap_Base_UIntMethod(arg1, arg2) +} + +var _wrap_Base_FloatMethod unsafe.Pointer + +func _swig_wrap_Base_FloatMethod(base SwigcptrBase, _ float32) (_ float32) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Base_FloatMethod, _swig_p) + return +} + +func (arg1 SwigcptrBase) FloatMethod(arg2 float32) (_swig_ret float32) { + return _swig_wrap_Base_FloatMethod(arg1, arg2) +} + +var _wrap_Base_CharPtrMethod unsafe.Pointer + +func _swig_wrap_Base_CharPtrMethod(base SwigcptrBase, _ string) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Base_CharPtrMethod, _swig_p) + return +} + +func (arg1 SwigcptrBase) CharPtrMethod(arg2 string) (_swig_ret string) { + return _swig_wrap_Base_CharPtrMethod(arg1, arg2) +} + +var _wrap_Base_ConstCharPtrMethod unsafe.Pointer + +func _swig_wrap_Base_ConstCharPtrMethod(base SwigcptrBase, _ string) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Base_ConstCharPtrMethod, _swig_p) + return +} + +func (arg1 SwigcptrBase) ConstCharPtrMethod(arg2 string) (_swig_ret string) { + return _swig_wrap_Base_ConstCharPtrMethod(arg1, arg2) +} + +var _wrap_Base_EnumMethod unsafe.Pointer + +func _swig_wrap_Base_EnumMethod(base SwigcptrBase, _ HShadowMode) (_ HShadowMode) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Base_EnumMethod, _swig_p) + return +} + +func (arg1 SwigcptrBase) EnumMethod(arg2 HShadowMode) (_swig_ret HShadowMode) { + return _swig_wrap_Base_EnumMethod(arg1, arg2) +} + +var _wrap_Base_ManyParmsMethod unsafe.Pointer + +func _swig_wrap_Base_ManyParmsMethod(base SwigcptrBase, _ bool, _ int, _ uint, _ float32, _ string, _ string, _ HShadowMode) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Base_ManyParmsMethod, _swig_p) + return +} + +func (arg1 SwigcptrBase) ManyParmsMethod(arg2 bool, arg3 int, arg4 uint, arg5 float32, arg6 string, arg7 string, arg8 HShadowMode) { + _swig_wrap_Base_ManyParmsMethod(arg1, arg2, arg3, arg4, arg5, arg6, arg7, arg8) +} + +var _wrap_Base_NotOverriddenMethod unsafe.Pointer + +func _swig_wrap_Base_NotOverriddenMethod(base SwigcptrBase) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Base_NotOverriddenMethod, _swig_p) + return +} + +func (arg1 SwigcptrBase) NotOverriddenMethod() { + _swig_wrap_Base_NotOverriddenMethod(arg1) +} + +type Base interface { + Swigcptr() uintptr + SwigIsBase() + DirectorInterface() interface{} + NoParmsMethod() + BoolMethod(arg2 bool) (_swig_ret bool) + IntMethod(arg2 int) (_swig_ret int) + UIntMethod(arg2 uint) (_swig_ret uint) + FloatMethod(arg2 float32) (_swig_ret float32) + CharPtrMethod(arg2 string) (_swig_ret string) + ConstCharPtrMethod(arg2 string) (_swig_ret string) + EnumMethod(arg2 HShadowMode) (_swig_ret HShadowMode) + ManyParmsMethod(arg2 bool, arg3 int, arg4 uint, arg5 float32, arg6 string, arg7 string, arg8 HShadowMode) + NotOverriddenMethod() +} + +type _swig_DirectorDerived struct { + SwigcptrDerived + v interface{} +} + +func (p *_swig_DirectorDerived) Swigcptr() uintptr { + return p.SwigcptrDerived.Swigcptr() +} + +func (p *_swig_DirectorDerived) SwigIsDerived() { +} + +func (p *_swig_DirectorDerived) DirectorInterface() interface{} { + return p.v +} + +var _wrap__swig_NewDirectorDerivedDerived unsafe.Pointer + +func _swig_NewDirectorDerivedDerived(_swig_director *_swig_DirectorDerived, _ float64) (_swig_ret SwigcptrDerived) { + _swig_p := uintptr(unsafe.Pointer(&_swig_director)) + _cgo_runtime_cgocall(_wrap__swig_NewDirectorDerivedDerived, _swig_p) + return +} + +func NewDirectorDerived(v interface{}, arg1 float64) Derived { + p := &_swig_DirectorDerived{0, v} + p.SwigcptrDerived = _swig_NewDirectorDerivedDerived(p, arg1) + return p +} + +var _wrap_DeleteDirectorDerived unsafe.Pointer + +func _swig_wrap_DeleteDirectorDerived(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_DeleteDirectorDerived, _swig_p) + return +} + +func DeleteDirectorDerived(arg1 Derived) { + _swig_wrap_DeleteDirectorDerived(arg1.Swigcptr()) +} + +func Swiggo_DeleteDirector_Derived(p *_swig_DirectorDerived) { + p.SwigcptrDerived = 0 +} + +type _swig_DirectorInterfaceDerivedNoParmsMethod interface { + NoParmsMethod() +} + +var _wrap__swig_DirectorDerived_upcall_NoParmsMethod unsafe.Pointer + +func _swig_wrap__swig_DirectorDerived_upcall_NoParmsMethod(_swig_ptr SwigcptrDerived) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) + _cgo_runtime_cgocall(_wrap__swig_DirectorDerived_upcall_NoParmsMethod, _swig_p) + return +} + +func (swig_p *_swig_DirectorDerived) NoParmsMethod() { + if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceDerivedNoParmsMethod); swig_ok { + swig_g.NoParmsMethod() + return + } + _swig_wrap__swig_DirectorDerived_upcall_NoParmsMethod(swig_p.SwigcptrDerived) +} + +func DirectorDerivedNoParmsMethod(p Derived) { + _swig_wrap__swig_DirectorDerived_upcall_NoParmsMethod(p.(*_swig_DirectorDerived).SwigcptrDerived) +} + +func Swig_DirectorDerived_callback_NoParmsMethod(p *_swig_DirectorDerived) { + p.NoParmsMethod() +} + +type _swig_DirectorInterfaceDerivedBoolMethod interface { + BoolMethod(bool) bool +} + +var _wrap__swig_DirectorDerived_upcall_BoolMethod unsafe.Pointer + +func _swig_wrap__swig_DirectorDerived_upcall_BoolMethod(_swig_ptr SwigcptrDerived, _ bool) (_swig_ret bool) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) + _cgo_runtime_cgocall(_wrap__swig_DirectorDerived_upcall_BoolMethod, _swig_p) + return +} + +func (swig_p *_swig_DirectorDerived) BoolMethod(x bool) bool { + if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceDerivedBoolMethod); swig_ok { + return swig_g.BoolMethod(x) + } + var swig_r bool + swig_r = _swig_wrap__swig_DirectorDerived_upcall_BoolMethod(swig_p.SwigcptrDerived, x) + return swig_r +} + +func DirectorDerivedBoolMethod(p Derived, arg2 bool) bool { + var swig_r bool + swig_r = _swig_wrap__swig_DirectorDerived_upcall_BoolMethod(p.(*_swig_DirectorDerived).SwigcptrDerived, arg2) + return swig_r +} + +func Swig_DirectorDerived_callback_BoolMethod(p *_swig_DirectorDerived, arg2 bool) (swig_result bool) { + var swig_r bool + swig_r = p.BoolMethod(arg2) + return swig_r +} + +type _swig_DirectorInterfaceDerivedIntMethod interface { + IntMethod(int) int +} + +var _wrap__swig_DirectorDerived_upcall_IntMethod unsafe.Pointer + +func _swig_wrap__swig_DirectorDerived_upcall_IntMethod(_swig_ptr SwigcptrDerived, _ int) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) + _cgo_runtime_cgocall(_wrap__swig_DirectorDerived_upcall_IntMethod, _swig_p) + return +} + +func (swig_p *_swig_DirectorDerived) IntMethod(x int) int { + if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceDerivedIntMethod); swig_ok { + return swig_g.IntMethod(x) + } + var swig_r int + swig_r = _swig_wrap__swig_DirectorDerived_upcall_IntMethod(swig_p.SwigcptrDerived, x) + return swig_r +} + +func DirectorDerivedIntMethod(p Derived, arg2 int) int { + var swig_r int + swig_r = _swig_wrap__swig_DirectorDerived_upcall_IntMethod(p.(*_swig_DirectorDerived).SwigcptrDerived, arg2) + return swig_r +} + +func Swig_DirectorDerived_callback_IntMethod(p *_swig_DirectorDerived, arg2 int) (swig_result int) { + var swig_r int + swig_r = p.IntMethod(arg2) + return swig_r +} + +type _swig_DirectorInterfaceDerivedUIntMethod interface { + UIntMethod(uint) uint +} + +var _wrap__swig_DirectorDerived_upcall_UIntMethod unsafe.Pointer + +func _swig_wrap__swig_DirectorDerived_upcall_UIntMethod(_swig_ptr SwigcptrDerived, _ uint) (_swig_ret uint) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) + _cgo_runtime_cgocall(_wrap__swig_DirectorDerived_upcall_UIntMethod, _swig_p) + return +} + +func (swig_p *_swig_DirectorDerived) UIntMethod(x uint) uint { + if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceDerivedUIntMethod); swig_ok { + return swig_g.UIntMethod(x) + } + var swig_r uint + swig_r = _swig_wrap__swig_DirectorDerived_upcall_UIntMethod(swig_p.SwigcptrDerived, x) + return swig_r +} + +func DirectorDerivedUIntMethod(p Derived, arg2 uint) uint { + var swig_r uint + swig_r = _swig_wrap__swig_DirectorDerived_upcall_UIntMethod(p.(*_swig_DirectorDerived).SwigcptrDerived, arg2) + return swig_r +} + +func Swig_DirectorDerived_callback_UIntMethod(p *_swig_DirectorDerived, arg2 uint) (swig_result uint) { + var swig_r uint + swig_r = p.UIntMethod(arg2) + return swig_r +} + +type _swig_DirectorInterfaceDerivedFloatMethod interface { + FloatMethod(float32) float32 +} + +var _wrap__swig_DirectorDerived_upcall_FloatMethod unsafe.Pointer + +func _swig_wrap__swig_DirectorDerived_upcall_FloatMethod(_swig_ptr SwigcptrDerived, _ float32) (_swig_ret float32) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) + _cgo_runtime_cgocall(_wrap__swig_DirectorDerived_upcall_FloatMethod, _swig_p) + return +} + +func (swig_p *_swig_DirectorDerived) FloatMethod(x float32) float32 { + if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceDerivedFloatMethod); swig_ok { + return swig_g.FloatMethod(x) + } + var swig_r float32 + swig_r = _swig_wrap__swig_DirectorDerived_upcall_FloatMethod(swig_p.SwigcptrDerived, x) + return swig_r +} + +func DirectorDerivedFloatMethod(p Derived, arg2 float32) float32 { + var swig_r float32 + swig_r = _swig_wrap__swig_DirectorDerived_upcall_FloatMethod(p.(*_swig_DirectorDerived).SwigcptrDerived, arg2) + return swig_r +} + +func Swig_DirectorDerived_callback_FloatMethod(p *_swig_DirectorDerived, arg2 float32) (swig_result float32) { + var swig_r float32 + swig_r = p.FloatMethod(arg2) + return swig_r +} + +type _swig_DirectorInterfaceDerivedCharPtrMethod interface { + CharPtrMethod(string) string +} + +var _wrap__swig_DirectorDerived_upcall_CharPtrMethod unsafe.Pointer + +func _swig_wrap__swig_DirectorDerived_upcall_CharPtrMethod(_swig_ptr SwigcptrDerived, _ string) (_swig_ret string) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) + _cgo_runtime_cgocall(_wrap__swig_DirectorDerived_upcall_CharPtrMethod, _swig_p) + return +} + +func (swig_p *_swig_DirectorDerived) CharPtrMethod(x string) string { + if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceDerivedCharPtrMethod); swig_ok { + return swig_g.CharPtrMethod(x) + } + var swig_r string + swig_r = _swig_wrap__swig_DirectorDerived_upcall_CharPtrMethod(swig_p.SwigcptrDerived, x) + return swig_r +} + +func DirectorDerivedCharPtrMethod(p Derived, arg2 string) string { + var swig_r string + swig_r = _swig_wrap__swig_DirectorDerived_upcall_CharPtrMethod(p.(*_swig_DirectorDerived).SwigcptrDerived, arg2) + return swig_r +} + +func Swig_DirectorDerived_callback_CharPtrMethod(p *_swig_DirectorDerived, arg2 string) (swig_result string) { + var swig_r string + swig_r = p.CharPtrMethod(arg2) + return swig_r +} + +type _swig_DirectorInterfaceDerivedConstCharPtrMethod interface { + ConstCharPtrMethod(string) string +} + +var _wrap__swig_DirectorDerived_upcall_ConstCharPtrMethod unsafe.Pointer + +func _swig_wrap__swig_DirectorDerived_upcall_ConstCharPtrMethod(_swig_ptr SwigcptrDerived, _ string) (_swig_ret string) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) + _cgo_runtime_cgocall(_wrap__swig_DirectorDerived_upcall_ConstCharPtrMethod, _swig_p) + return +} + +func (swig_p *_swig_DirectorDerived) ConstCharPtrMethod(x string) string { + if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceDerivedConstCharPtrMethod); swig_ok { + return swig_g.ConstCharPtrMethod(x) + } + var swig_r string + swig_r = _swig_wrap__swig_DirectorDerived_upcall_ConstCharPtrMethod(swig_p.SwigcptrDerived, x) + return swig_r +} + +func DirectorDerivedConstCharPtrMethod(p Derived, arg2 string) string { + var swig_r string + swig_r = _swig_wrap__swig_DirectorDerived_upcall_ConstCharPtrMethod(p.(*_swig_DirectorDerived).SwigcptrDerived, arg2) + return swig_r +} + +func Swig_DirectorDerived_callback_ConstCharPtrMethod(p *_swig_DirectorDerived, arg2 string) (swig_result string) { + var swig_r string + swig_r = p.ConstCharPtrMethod(arg2) + return swig_r +} + +type _swig_DirectorInterfaceDerivedEnumMethod interface { + EnumMethod(HShadowMode) HShadowMode +} + +var _wrap__swig_DirectorDerived_upcall_EnumMethod unsafe.Pointer + +func _swig_wrap__swig_DirectorDerived_upcall_EnumMethod(_swig_ptr SwigcptrDerived, _ HShadowMode) (_swig_ret HShadowMode) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) + _cgo_runtime_cgocall(_wrap__swig_DirectorDerived_upcall_EnumMethod, _swig_p) + return +} + +func (swig_p *_swig_DirectorDerived) EnumMethod(x HShadowMode) HShadowMode { + if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceDerivedEnumMethod); swig_ok { + return swig_g.EnumMethod(x) + } + var swig_r HShadowMode + swig_r = _swig_wrap__swig_DirectorDerived_upcall_EnumMethod(swig_p.SwigcptrDerived, x) + return swig_r +} + +func DirectorDerivedEnumMethod(p Derived, arg2 HShadowMode) HShadowMode { + var swig_r HShadowMode + swig_r = _swig_wrap__swig_DirectorDerived_upcall_EnumMethod(p.(*_swig_DirectorDerived).SwigcptrDerived, arg2) + return swig_r +} + +func Swig_DirectorDerived_callback_EnumMethod(p *_swig_DirectorDerived, arg2 HShadowMode) (swig_result HShadowMode) { + var swig_r HShadowMode + swig_r = p.EnumMethod(arg2) + return swig_r +} + +type _swig_DirectorInterfaceDerivedManyParmsMethod interface { + ManyParmsMethod(bool, int, uint, float32, string, string, HShadowMode) +} + +var _wrap__swig_DirectorDerived_upcall_ManyParmsMethod unsafe.Pointer + +func _swig_wrap__swig_DirectorDerived_upcall_ManyParmsMethod(_swig_ptr SwigcptrDerived, _ bool, _ int, _ uint, _ float32, _ string, _ string, _ HShadowMode) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) + _cgo_runtime_cgocall(_wrap__swig_DirectorDerived_upcall_ManyParmsMethod, _swig_p) + return +} + +func (swig_p *_swig_DirectorDerived) ManyParmsMethod(b bool, i int, u uint, f float32, c string, cc string, h HShadowMode) { + if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceDerivedManyParmsMethod); swig_ok { + swig_g.ManyParmsMethod(b, i, u, f, c, cc, h) + return + } + _swig_wrap__swig_DirectorDerived_upcall_ManyParmsMethod(swig_p.SwigcptrDerived, b, i, u, f, c, cc, h) +} + +func DirectorDerivedManyParmsMethod(p Derived, arg2 bool, arg3 int, arg4 uint, arg5 float32, arg6 string, arg7 string, arg8 HShadowMode) { + _swig_wrap__swig_DirectorDerived_upcall_ManyParmsMethod(p.(*_swig_DirectorDerived).SwigcptrDerived, arg2, arg3, arg4, arg5, arg6, arg7, arg8) +} + +func Swig_DirectorDerived_callback_ManyParmsMethod(p *_swig_DirectorDerived, arg2 bool, arg3 int, arg4 uint, arg5 float32, arg6 string, arg7 string, arg8 HShadowMode) { + p.ManyParmsMethod(arg2, arg3, arg4, arg5, arg6, arg7, arg8) +} + +type _swig_DirectorInterfaceDerivedNotOverriddenMethod interface { + NotOverriddenMethod() +} + +var _wrap__swig_DirectorDerived_upcall_NotOverriddenMethod unsafe.Pointer + +func _swig_wrap__swig_DirectorDerived_upcall_NotOverriddenMethod(_swig_ptr SwigcptrDerived) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) + _cgo_runtime_cgocall(_wrap__swig_DirectorDerived_upcall_NotOverriddenMethod, _swig_p) + return +} + +func (swig_p *_swig_DirectorDerived) NotOverriddenMethod() { + if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceDerivedNotOverriddenMethod); swig_ok { + swig_g.NotOverriddenMethod() + return + } + _swig_wrap__swig_DirectorDerived_upcall_NotOverriddenMethod(swig_p.SwigcptrDerived) +} + +func DirectorDerivedNotOverriddenMethod(p Derived) { + _swig_wrap__swig_DirectorDerived_upcall_NotOverriddenMethod(p.(*_swig_DirectorDerived).SwigcptrDerived) +} + +func Swig_DirectorDerived_callback_NotOverriddenMethod(p *_swig_DirectorDerived) { + p.NotOverriddenMethod() +} + +type SwigcptrDerived uintptr + +func (p SwigcptrDerived) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrDerived) SwigIsDerived() { +} + +func (p SwigcptrDerived) DirectorInterface() interface{} { + return nil +} + +var _wrap_new_Derived unsafe.Pointer + +func _swig_wrap_new_Derived(base float64) (_ SwigcptrDerived) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Derived, _swig_p) + return +} + +func NewDerived(arg1 float64) (_swig_ret Derived) { + return _swig_wrap_new_Derived(arg1) +} + +var _wrap_delete_Derived unsafe.Pointer + +func _swig_wrap_delete_Derived(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Derived, _swig_p) + return +} + +func DeleteDerived(arg1 Derived) { + _swig_wrap_delete_Derived(arg1.Swigcptr()) +} + +var _wrap_Derived_NoParmsMethod unsafe.Pointer + +func _swig_wrap_Derived_NoParmsMethod(base SwigcptrDerived) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Derived_NoParmsMethod, _swig_p) + return +} + +func (arg1 SwigcptrDerived) NoParmsMethod() { + _swig_wrap_Derived_NoParmsMethod(arg1) +} + +var _wrap_Derived_BoolMethod unsafe.Pointer + +func _swig_wrap_Derived_BoolMethod(base SwigcptrDerived, _ bool) (_ bool) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Derived_BoolMethod, _swig_p) + return +} + +func (arg1 SwigcptrDerived) BoolMethod(arg2 bool) (_swig_ret bool) { + return _swig_wrap_Derived_BoolMethod(arg1, arg2) +} + +var _wrap_Derived_IntMethod unsafe.Pointer + +func _swig_wrap_Derived_IntMethod(base SwigcptrDerived, _ int) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Derived_IntMethod, _swig_p) + return +} + +func (arg1 SwigcptrDerived) IntMethod(arg2 int) (_swig_ret int) { + return _swig_wrap_Derived_IntMethod(arg1, arg2) +} + +var _wrap_Derived_UIntMethod unsafe.Pointer + +func _swig_wrap_Derived_UIntMethod(base SwigcptrDerived, _ uint) (_ uint) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Derived_UIntMethod, _swig_p) + return +} + +func (arg1 SwigcptrDerived) UIntMethod(arg2 uint) (_swig_ret uint) { + return _swig_wrap_Derived_UIntMethod(arg1, arg2) +} + +var _wrap_Derived_FloatMethod unsafe.Pointer + +func _swig_wrap_Derived_FloatMethod(base SwigcptrDerived, _ float32) (_ float32) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Derived_FloatMethod, _swig_p) + return +} + +func (arg1 SwigcptrDerived) FloatMethod(arg2 float32) (_swig_ret float32) { + return _swig_wrap_Derived_FloatMethod(arg1, arg2) +} + +var _wrap_Derived_CharPtrMethod unsafe.Pointer + +func _swig_wrap_Derived_CharPtrMethod(base SwigcptrDerived, _ string) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Derived_CharPtrMethod, _swig_p) + return +} + +func (arg1 SwigcptrDerived) CharPtrMethod(arg2 string) (_swig_ret string) { + return _swig_wrap_Derived_CharPtrMethod(arg1, arg2) +} + +var _wrap_Derived_ConstCharPtrMethod unsafe.Pointer + +func _swig_wrap_Derived_ConstCharPtrMethod(base SwigcptrDerived, _ string) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Derived_ConstCharPtrMethod, _swig_p) + return +} + +func (arg1 SwigcptrDerived) ConstCharPtrMethod(arg2 string) (_swig_ret string) { + return _swig_wrap_Derived_ConstCharPtrMethod(arg1, arg2) +} + +var _wrap_Derived_EnumMethod unsafe.Pointer + +func _swig_wrap_Derived_EnumMethod(base SwigcptrDerived, _ HShadowMode) (_ HShadowMode) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Derived_EnumMethod, _swig_p) + return +} + +func (arg1 SwigcptrDerived) EnumMethod(arg2 HShadowMode) (_swig_ret HShadowMode) { + return _swig_wrap_Derived_EnumMethod(arg1, arg2) +} + +var _wrap_Derived_ManyParmsMethod unsafe.Pointer + +func _swig_wrap_Derived_ManyParmsMethod(base SwigcptrDerived, _ bool, _ int, _ uint, _ float32, _ string, _ string, _ HShadowMode) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Derived_ManyParmsMethod, _swig_p) + return +} + +func (arg1 SwigcptrDerived) ManyParmsMethod(arg2 bool, arg3 int, arg4 uint, arg5 float32, arg6 string, arg7 string, arg8 HShadowMode) { + _swig_wrap_Derived_ManyParmsMethod(arg1, arg2, arg3, arg4, arg5, arg6, arg7, arg8) +} + +var _wrap_Derived_NotOverriddenMethod unsafe.Pointer + +func _swig_wrap_Derived_NotOverriddenMethod(base SwigcptrDerived) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Derived_NotOverriddenMethod, _swig_p) + return +} + +func (_swig_base SwigcptrDerived) NotOverriddenMethod() { + _swig_wrap_Derived_NotOverriddenMethod(_swig_base) +} + +func (p SwigcptrDerived) SwigIsBase() { +} + +func (p SwigcptrDerived) SwigGetBase() Base { + return SwigcptrBase(p.Swigcptr()) +} + +type Derived interface { + Swigcptr() uintptr + SwigIsDerived() + DirectorInterface() interface{} + NoParmsMethod() + BoolMethod(arg2 bool) (_swig_ret bool) + IntMethod(arg2 int) (_swig_ret int) + UIntMethod(arg2 uint) (_swig_ret uint) + FloatMethod(arg2 float32) (_swig_ret float32) + CharPtrMethod(arg2 string) (_swig_ret string) + ConstCharPtrMethod(arg2 string) (_swig_ret string) + EnumMethod(arg2 HShadowMode) (_swig_ret HShadowMode) + ManyParmsMethod(arg2 bool, arg3 int, arg4 uint, arg5 float32, arg6 string, arg7 string, arg8 HShadowMode) + NotOverriddenMethod() + SwigIsBase() + SwigGetBase() Base +} + +type SwigcptrCaller uintptr + +func (p SwigcptrCaller) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrCaller) SwigIsCaller() { +} + +var _wrap_new_Caller unsafe.Pointer + +func _swig_wrap_new_Caller() (base SwigcptrCaller) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Caller, _swig_p) + return +} + +func NewCaller() (_swig_ret Caller) { + return _swig_wrap_new_Caller() +} + +var _wrap_delete_Caller unsafe.Pointer + +func _swig_wrap_delete_Caller(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Caller, _swig_p) + return +} + +func DeleteCaller(arg1 Caller) { + _swig_wrap_delete_Caller(arg1.Swigcptr()) +} + +var _wrap_Caller_set unsafe.Pointer + +func _swig_wrap_Caller_set(base SwigcptrCaller, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Caller_set, _swig_p) + return +} + +func (arg1 SwigcptrCaller) Set(arg2 Base) { + _swig_wrap_Caller_set(arg1, arg2.Swigcptr()) +} + +var _wrap_Caller_reset unsafe.Pointer + +func _swig_wrap_Caller_reset(base SwigcptrCaller) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Caller_reset, _swig_p) + return +} + +func (arg1 SwigcptrCaller) Reset() { + _swig_wrap_Caller_reset(arg1) +} + +var _wrap_Caller_NoParmsMethodCall unsafe.Pointer + +func _swig_wrap_Caller_NoParmsMethodCall(base SwigcptrCaller) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Caller_NoParmsMethodCall, _swig_p) + return +} + +func (arg1 SwigcptrCaller) NoParmsMethodCall() { + _swig_wrap_Caller_NoParmsMethodCall(arg1) +} + +var _wrap_Caller_BoolMethodCall unsafe.Pointer + +func _swig_wrap_Caller_BoolMethodCall(base SwigcptrCaller, _ bool) (_ bool) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Caller_BoolMethodCall, _swig_p) + return +} + +func (arg1 SwigcptrCaller) BoolMethodCall(arg2 bool) (_swig_ret bool) { + return _swig_wrap_Caller_BoolMethodCall(arg1, arg2) +} + +var _wrap_Caller_IntMethodCall unsafe.Pointer + +func _swig_wrap_Caller_IntMethodCall(base SwigcptrCaller, _ int) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Caller_IntMethodCall, _swig_p) + return +} + +func (arg1 SwigcptrCaller) IntMethodCall(arg2 int) (_swig_ret int) { + return _swig_wrap_Caller_IntMethodCall(arg1, arg2) +} + +var _wrap_Caller_UIntMethodCall unsafe.Pointer + +func _swig_wrap_Caller_UIntMethodCall(base SwigcptrCaller, _ uint) (_ uint) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Caller_UIntMethodCall, _swig_p) + return +} + +func (arg1 SwigcptrCaller) UIntMethodCall(arg2 uint) (_swig_ret uint) { + return _swig_wrap_Caller_UIntMethodCall(arg1, arg2) +} + +var _wrap_Caller_FloatMethodCall unsafe.Pointer + +func _swig_wrap_Caller_FloatMethodCall(base SwigcptrCaller, _ float32) (_ float32) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Caller_FloatMethodCall, _swig_p) + return +} + +func (arg1 SwigcptrCaller) FloatMethodCall(arg2 float32) (_swig_ret float32) { + return _swig_wrap_Caller_FloatMethodCall(arg1, arg2) +} + +var _wrap_Caller_CharPtrMethodCall unsafe.Pointer + +func _swig_wrap_Caller_CharPtrMethodCall(base SwigcptrCaller, _ string) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Caller_CharPtrMethodCall, _swig_p) + return +} + +func (arg1 SwigcptrCaller) CharPtrMethodCall(arg2 string) (_swig_ret string) { + return _swig_wrap_Caller_CharPtrMethodCall(arg1, arg2) +} + +var _wrap_Caller_ConstCharPtrMethodCall unsafe.Pointer + +func _swig_wrap_Caller_ConstCharPtrMethodCall(base SwigcptrCaller, _ string) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Caller_ConstCharPtrMethodCall, _swig_p) + return +} + +func (arg1 SwigcptrCaller) ConstCharPtrMethodCall(arg2 string) (_swig_ret string) { + return _swig_wrap_Caller_ConstCharPtrMethodCall(arg1, arg2) +} + +var _wrap_Caller_EnumMethodCall unsafe.Pointer + +func _swig_wrap_Caller_EnumMethodCall(base SwigcptrCaller, _ HShadowMode) (_ HShadowMode) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Caller_EnumMethodCall, _swig_p) + return +} + +func (arg1 SwigcptrCaller) EnumMethodCall(arg2 HShadowMode) (_swig_ret HShadowMode) { + return _swig_wrap_Caller_EnumMethodCall(arg1, arg2) +} + +var _wrap_Caller_ManyParmsMethodCall unsafe.Pointer + +func _swig_wrap_Caller_ManyParmsMethodCall(base SwigcptrCaller, _ bool, _ int, _ uint, _ float32, _ string, _ string, _ HShadowMode) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Caller_ManyParmsMethodCall, _swig_p) + return +} + +func (arg1 SwigcptrCaller) ManyParmsMethodCall(arg2 bool, arg3 int, arg4 uint, arg5 float32, arg6 string, arg7 string, arg8 HShadowMode) { + _swig_wrap_Caller_ManyParmsMethodCall(arg1, arg2, arg3, arg4, arg5, arg6, arg7, arg8) +} + +var _wrap_Caller_NotOverriddenMethodCall unsafe.Pointer + +func _swig_wrap_Caller_NotOverriddenMethodCall(base SwigcptrCaller) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Caller_NotOverriddenMethodCall, _swig_p) + return +} + +func (arg1 SwigcptrCaller) NotOverriddenMethodCall() { + _swig_wrap_Caller_NotOverriddenMethodCall(arg1) +} + +type Caller interface { + Swigcptr() uintptr + SwigIsCaller() + Set(arg2 Base) + Reset() + NoParmsMethodCall() + BoolMethodCall(arg2 bool) (_swig_ret bool) + IntMethodCall(arg2 int) (_swig_ret int) + UIntMethodCall(arg2 uint) (_swig_ret uint) + FloatMethodCall(arg2 float32) (_swig_ret float32) + CharPtrMethodCall(arg2 string) (_swig_ret string) + ConstCharPtrMethodCall(arg2 string) (_swig_ret string) + EnumMethodCall(arg2 HShadowMode) (_swig_ret HShadowMode) + ManyParmsMethodCall(arg2 bool, arg3 int, arg4 uint, arg5 float32, arg6 string, arg7 string, arg8 HShadowMode) + NotOverriddenMethodCall() +} + + +type SwigcptrSwigDirector_Derived uintptr +type SwigDirector_Derived interface { + Swigcptr() uintptr; +} +func (p SwigcptrSwigDirector_Derived) Swigcptr() uintptr { + return uintptr(p) +} + +type SwigcptrSwigDirector_Base uintptr +type SwigDirector_Base interface { + Swigcptr() uintptr; +} +func (p SwigcptrSwigDirector_Base) Swigcptr() uintptr { + return uintptr(p) +} + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/director_primitives_wrap.h b/Examples/test-suite/go/director_primitives_wrap.h new file mode 100644 index 000000000..62048dbd9 --- /dev/null +++ b/Examples/test-suite/go/director_primitives_wrap.h @@ -0,0 +1,114 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../director_primitives.i + +#ifndef SWIG_director_primitives_WRAP_H_ +#define SWIG_director_primitives_WRAP_H_ + +class SwigDirector_Base : public Base +{ + public: + SwigDirector_Base(void *swig_p, double dd); + virtual ~SwigDirector_Base(); + void _swig_upcall_NoParmsMethod() { + Base::NoParmsMethod(); + } + virtual void NoParmsMethod(); + bool _swig_upcall_BoolMethod(bool x) { + return Base::BoolMethod(x); + } + virtual bool BoolMethod(bool x); + int _swig_upcall_IntMethod(int x) { + return Base::IntMethod(x); + } + virtual int IntMethod(int x); + unsigned int _swig_upcall_UIntMethod(unsigned int x) { + return Base::UIntMethod(x); + } + virtual unsigned int UIntMethod(unsigned int x); + float _swig_upcall_FloatMethod(float x) { + return Base::FloatMethod(x); + } + virtual float FloatMethod(float x); + char *_swig_upcall_CharPtrMethod(char *x) { + return Base::CharPtrMethod(x); + } + virtual char *CharPtrMethod(char *x); + char const *_swig_upcall_ConstCharPtrMethod(char const *x) { + return Base::ConstCharPtrMethod(x); + } + virtual char const *ConstCharPtrMethod(char const *x); + HShadowMode _swig_upcall_EnumMethod(HShadowMode x) { + return Base::EnumMethod(x); + } + virtual HShadowMode EnumMethod(HShadowMode x); + void _swig_upcall_ManyParmsMethod(bool b, int i, unsigned int u, float f, char *c, char const *cc, HShadowMode h) { + Base::ManyParmsMethod(b,i,u,f,c,cc,h); + } + virtual void ManyParmsMethod(bool b, int i, unsigned int u, float f, char *c, char const *cc, HShadowMode h); + void _swig_upcall_NotOverriddenMethod() { + Base::NotOverriddenMethod(); + } + virtual void NotOverriddenMethod(); + private: + void *go_val; +}; + +class SwigDirector_Derived : public Derived +{ + public: + SwigDirector_Derived(void *swig_p, double dd); + virtual ~SwigDirector_Derived(); + void _swig_upcall_NoParmsMethod() { + Derived::NoParmsMethod(); + } + virtual void NoParmsMethod(); + bool _swig_upcall_BoolMethod(bool x) { + return Derived::BoolMethod(x); + } + virtual bool BoolMethod(bool x); + int _swig_upcall_IntMethod(int x) { + return Derived::IntMethod(x); + } + virtual int IntMethod(int x); + unsigned int _swig_upcall_UIntMethod(unsigned int x) { + return Derived::UIntMethod(x); + } + virtual unsigned int UIntMethod(unsigned int x); + float _swig_upcall_FloatMethod(float x) { + return Derived::FloatMethod(x); + } + virtual float FloatMethod(float x); + char *_swig_upcall_CharPtrMethod(char *x) { + return Derived::CharPtrMethod(x); + } + virtual char *CharPtrMethod(char *x); + char const *_swig_upcall_ConstCharPtrMethod(char const *x) { + return Derived::ConstCharPtrMethod(x); + } + virtual char const *ConstCharPtrMethod(char const *x); + HShadowMode _swig_upcall_EnumMethod(HShadowMode x) { + return Derived::EnumMethod(x); + } + virtual HShadowMode EnumMethod(HShadowMode x); + void _swig_upcall_ManyParmsMethod(bool b, int i, unsigned int u, float f, char *c, char const *cc, HShadowMode h) { + Derived::ManyParmsMethod(b,i,u,f,c,cc,h); + } + virtual void ManyParmsMethod(bool b, int i, unsigned int u, float f, char *c, char const *cc, HShadowMode h); + void _swig_upcall_NotOverriddenMethod() { + Base::NotOverriddenMethod(); + } + virtual void NotOverriddenMethod(); + private: + void *go_val; +}; + +#endif diff --git a/Examples/test-suite/go/director_protected.go b/Examples/test-suite/go/director_protected.go new file mode 100644 index 000000000..7c22873e6 --- /dev/null +++ b/Examples/test-suite/go/director_protected.go @@ -0,0 +1,1081 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../director_protected.i + +package director_protected + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type _swig_DirectorFoo struct { + SwigcptrFoo + v interface{} +} + +func (p *_swig_DirectorFoo) Swigcptr() uintptr { + return p.SwigcptrFoo.Swigcptr() +} + +func (p *_swig_DirectorFoo) SwigIsFoo() { +} + +func (p *_swig_DirectorFoo) DirectorInterface() interface{} { + return p.v +} + +var _wrap__swig_NewDirectorFooFoo unsafe.Pointer + +func _swig_NewDirectorFooFoo(_swig_director *_swig_DirectorFoo) (_swig_ret SwigcptrFoo) { + _swig_p := uintptr(unsafe.Pointer(&_swig_director)) + _cgo_runtime_cgocall(_wrap__swig_NewDirectorFooFoo, _swig_p) + return +} + +func NewDirectorFoo(v interface{}) Foo { + p := &_swig_DirectorFoo{0, v} + p.SwigcptrFoo = _swig_NewDirectorFooFoo(p) + return p +} + +var _wrap_DeleteDirectorFoo unsafe.Pointer + +func _swig_wrap_DeleteDirectorFoo(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_DeleteDirectorFoo, _swig_p) + return +} + +func DeleteDirectorFoo(arg1 Foo) { + _swig_wrap_DeleteDirectorFoo(arg1.Swigcptr()) +} + +func Swiggo_DeleteDirector_Foo(p *_swig_DirectorFoo) { + p.SwigcptrFoo = 0 +} + +type _swig_DirectorInterfaceFooPong interface { + Pong() string +} + +var _wrap__swig_DirectorFoo_upcall_Pong unsafe.Pointer + +func _swig_wrap__swig_DirectorFoo_upcall_Pong(_swig_ptr SwigcptrFoo) (_swig_ret string) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) + _cgo_runtime_cgocall(_wrap__swig_DirectorFoo_upcall_Pong, _swig_p) + return +} + +func (swig_p *_swig_DirectorFoo) Pong() string { + if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceFooPong); swig_ok { + return swig_g.Pong() + } + var swig_r string + swig_r = _swig_wrap__swig_DirectorFoo_upcall_Pong(swig_p.SwigcptrFoo) + return swig_r +} + +func DirectorFooPong(p Foo) string { + var swig_r string + swig_r = _swig_wrap__swig_DirectorFoo_upcall_Pong(p.(*_swig_DirectorFoo).SwigcptrFoo) + return swig_r +} + +func Swig_DirectorFoo_callback_pong(p *_swig_DirectorFoo) (swig_result string) { + var swig_r string + swig_r = p.Pong() + return swig_r +} + +type _swig_DirectorInterfaceFooPing interface { + Ping() string +} + +func (swig_p *_swig_DirectorFoo) Ping() string { + if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceFooPing); swig_ok { + return swig_g.Ping() + } + panic("call to pure virtual method") +} + +func Swig_DirectorFoo_callback_ping(p *_swig_DirectorFoo) (swig_result string) { + var swig_r string + swig_r = p.Ping() + return swig_r +} + +type _swig_DirectorInterfaceFooPang interface { + Pang() string +} + +var _wrap__swig_DirectorFoo_upcall_Pang unsafe.Pointer + +func _swig_wrap__swig_DirectorFoo_upcall_Pang(_swig_ptr SwigcptrFoo) (_swig_ret string) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) + _cgo_runtime_cgocall(_wrap__swig_DirectorFoo_upcall_Pang, _swig_p) + return +} + +func (swig_p *_swig_DirectorFoo) Pang() string { + if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceFooPang); swig_ok { + return swig_g.Pang() + } + var swig_r string + swig_r = _swig_wrap__swig_DirectorFoo_upcall_Pang(swig_p.SwigcptrFoo) + return swig_r +} + +func DirectorFooPang(p Foo) string { + var swig_r string + swig_r = _swig_wrap__swig_DirectorFoo_upcall_Pang(p.(*_swig_DirectorFoo).SwigcptrFoo) + return swig_r +} + +func Swig_DirectorFoo_callback_pang(p *_swig_DirectorFoo) (swig_result string) { + var swig_r string + swig_r = p.Pang() + return swig_r +} + +type _swig_DirectorInterfaceFooUsed interface { + Used() string +} + +var _wrap__swig_DirectorFoo_upcall_Used unsafe.Pointer + +func _swig_wrap__swig_DirectorFoo_upcall_Used(_swig_ptr SwigcptrFoo) (_swig_ret string) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) + _cgo_runtime_cgocall(_wrap__swig_DirectorFoo_upcall_Used, _swig_p) + return +} + +func (swig_p *_swig_DirectorFoo) Used() string { + if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceFooUsed); swig_ok { + return swig_g.Used() + } + var swig_r string + swig_r = _swig_wrap__swig_DirectorFoo_upcall_Used(swig_p.SwigcptrFoo) + return swig_r +} + +func DirectorFooUsed(p Foo) string { + var swig_r string + swig_r = _swig_wrap__swig_DirectorFoo_upcall_Used(p.(*_swig_DirectorFoo).SwigcptrFoo) + return swig_r +} + +func Swig_DirectorFoo_callback_used(p *_swig_DirectorFoo) (swig_result string) { + var swig_r string + swig_r = p.Used() + return swig_r +} + +type _swig_DirectorInterfaceFooCheer interface { + Cheer() string +} + +var _wrap__swig_DirectorFoo_upcall_Cheer unsafe.Pointer + +func _swig_wrap__swig_DirectorFoo_upcall_Cheer(_swig_ptr SwigcptrFoo) (_swig_ret string) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) + _cgo_runtime_cgocall(_wrap__swig_DirectorFoo_upcall_Cheer, _swig_p) + return +} + +func (swig_p *_swig_DirectorFoo) Cheer() string { + if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceFooCheer); swig_ok { + return swig_g.Cheer() + } + var swig_r string + swig_r = _swig_wrap__swig_DirectorFoo_upcall_Cheer(swig_p.SwigcptrFoo) + return swig_r +} + +func DirectorFooCheer(p Foo) string { + var swig_r string + swig_r = _swig_wrap__swig_DirectorFoo_upcall_Cheer(p.(*_swig_DirectorFoo).SwigcptrFoo) + return swig_r +} + +func Swig_DirectorFoo_callback_cheer(p *_swig_DirectorFoo) (swig_result string) { + var swig_r string + swig_r = p.Cheer() + return swig_r +} + +type SwigcptrFoo uintptr + +func (p SwigcptrFoo) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrFoo) SwigIsFoo() { +} + +func (p SwigcptrFoo) DirectorInterface() interface{} { + return nil +} + +var _wrap_delete_Foo unsafe.Pointer + +func _swig_wrap_delete_Foo(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Foo, _swig_p) + return +} + +func DeleteFoo(arg1 Foo) { + _swig_wrap_delete_Foo(arg1.Swigcptr()) +} + +var _wrap_Foo_pong unsafe.Pointer + +func _swig_wrap_Foo_pong(base SwigcptrFoo) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_pong, _swig_p) + return +} + +func (arg1 SwigcptrFoo) Pong() (_swig_ret string) { + return _swig_wrap_Foo_pong(arg1) +} + +var _wrap_Foo_s unsafe.Pointer + +func _swig_wrap_Foo_s(base SwigcptrFoo) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_s, _swig_p) + return +} + +func (arg1 SwigcptrFoo) S() (_swig_ret int) { + return _swig_wrap_Foo_s(arg1) +} + +var _wrap_Foo_q unsafe.Pointer + +func _swig_wrap_Foo_q(base SwigcptrFoo) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_q, _swig_p) + return +} + +func (arg1 SwigcptrFoo) Q() (_swig_ret int) { + return _swig_wrap_Foo_q(arg1) +} + +var _wrap_new_Foo unsafe.Pointer + +func _swig_wrap_new_Foo() (base SwigcptrFoo) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Foo, _swig_p) + return +} + +func NewFoo() (_swig_ret Foo) { + return _swig_wrap_new_Foo() +} + +type Foo interface { + Swigcptr() uintptr + SwigIsFoo() + DirectorInterface() interface{} + Pong() (_swig_ret string) + S() (_swig_ret int) + Q() (_swig_ret int) +} + +type _swig_DirectorBar struct { + SwigcptrBar + v interface{} +} + +func (p *_swig_DirectorBar) Swigcptr() uintptr { + return p.SwigcptrBar.Swigcptr() +} + +func (p *_swig_DirectorBar) SwigIsBar() { +} + +func (p *_swig_DirectorBar) DirectorInterface() interface{} { + return p.v +} + +var _wrap__swig_NewDirectorBarBar unsafe.Pointer + +func _swig_NewDirectorBarBar(_swig_director *_swig_DirectorBar) (_swig_ret SwigcptrBar) { + _swig_p := uintptr(unsafe.Pointer(&_swig_director)) + _cgo_runtime_cgocall(_wrap__swig_NewDirectorBarBar, _swig_p) + return +} + +func NewDirectorBar(v interface{}) Bar { + p := &_swig_DirectorBar{0, v} + p.SwigcptrBar = _swig_NewDirectorBarBar(p) + return p +} + +var _wrap_DeleteDirectorBar unsafe.Pointer + +func _swig_wrap_DeleteDirectorBar(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_DeleteDirectorBar, _swig_p) + return +} + +func DeleteDirectorBar(arg1 Bar) { + _swig_wrap_DeleteDirectorBar(arg1.Swigcptr()) +} + +func Swiggo_DeleteDirector_Bar(p *_swig_DirectorBar) { + p.SwigcptrBar = 0 +} + +type _swig_DirectorInterfaceBarPong interface { + Pong() string +} + +var _wrap__swig_DirectorBar_upcall_Pong unsafe.Pointer + +func _swig_wrap__swig_DirectorBar_upcall_Pong(_swig_ptr SwigcptrBar) (_swig_ret string) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) + _cgo_runtime_cgocall(_wrap__swig_DirectorBar_upcall_Pong, _swig_p) + return +} + +func (swig_p *_swig_DirectorBar) Pong() string { + if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceBarPong); swig_ok { + return swig_g.Pong() + } + var swig_r string + swig_r = _swig_wrap__swig_DirectorBar_upcall_Pong(swig_p.SwigcptrBar) + return swig_r +} + +func DirectorBarPong(p Bar) string { + var swig_r string + swig_r = _swig_wrap__swig_DirectorBar_upcall_Pong(p.(*_swig_DirectorBar).SwigcptrBar) + return swig_r +} + +func Swig_DirectorBar_callback_pong(p *_swig_DirectorBar) (swig_result string) { + var swig_r string + swig_r = p.Pong() + return swig_r +} + +type _swig_DirectorInterfaceBarPing interface { + Ping() string +} + +var _wrap__swig_DirectorBar_upcall_Ping unsafe.Pointer + +func _swig_wrap__swig_DirectorBar_upcall_Ping(_swig_ptr SwigcptrBar) (_swig_ret string) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) + _cgo_runtime_cgocall(_wrap__swig_DirectorBar_upcall_Ping, _swig_p) + return +} + +func (swig_p *_swig_DirectorBar) Ping() string { + if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceBarPing); swig_ok { + return swig_g.Ping() + } + var swig_r string + swig_r = _swig_wrap__swig_DirectorBar_upcall_Ping(swig_p.SwigcptrBar) + return swig_r +} + +func DirectorBarPing(p Bar) string { + var swig_r string + swig_r = _swig_wrap__swig_DirectorBar_upcall_Ping(p.(*_swig_DirectorBar).SwigcptrBar) + return swig_r +} + +func Swig_DirectorBar_callback_ping(p *_swig_DirectorBar) (swig_result string) { + var swig_r string + swig_r = p.Ping() + return swig_r +} + +type _swig_DirectorInterfaceBarPang interface { + Pang() string +} + +var _wrap__swig_DirectorBar_upcall_Pang unsafe.Pointer + +func _swig_wrap__swig_DirectorBar_upcall_Pang(_swig_ptr SwigcptrBar) (_swig_ret string) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) + _cgo_runtime_cgocall(_wrap__swig_DirectorBar_upcall_Pang, _swig_p) + return +} + +func (swig_p *_swig_DirectorBar) Pang() string { + if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceBarPang); swig_ok { + return swig_g.Pang() + } + var swig_r string + swig_r = _swig_wrap__swig_DirectorBar_upcall_Pang(swig_p.SwigcptrBar) + return swig_r +} + +func DirectorBarPang(p Bar) string { + var swig_r string + swig_r = _swig_wrap__swig_DirectorBar_upcall_Pang(p.(*_swig_DirectorBar).SwigcptrBar) + return swig_r +} + +func Swig_DirectorBar_callback_pang(p *_swig_DirectorBar) (swig_result string) { + var swig_r string + swig_r = p.Pang() + return swig_r +} + +type _swig_DirectorInterfaceBarUsed interface { + Used() string +} + +var _wrap__swig_DirectorBar_upcall_Used unsafe.Pointer + +func _swig_wrap__swig_DirectorBar_upcall_Used(_swig_ptr SwigcptrBar) (_swig_ret string) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) + _cgo_runtime_cgocall(_wrap__swig_DirectorBar_upcall_Used, _swig_p) + return +} + +func (swig_p *_swig_DirectorBar) Used() string { + if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceBarUsed); swig_ok { + return swig_g.Used() + } + var swig_r string + swig_r = _swig_wrap__swig_DirectorBar_upcall_Used(swig_p.SwigcptrBar) + return swig_r +} + +func DirectorBarUsed(p Bar) string { + var swig_r string + swig_r = _swig_wrap__swig_DirectorBar_upcall_Used(p.(*_swig_DirectorBar).SwigcptrBar) + return swig_r +} + +func Swig_DirectorBar_callback_used(p *_swig_DirectorBar) (swig_result string) { + var swig_r string + swig_r = p.Used() + return swig_r +} + +type _swig_DirectorInterfaceBarCheer interface { + Cheer() string +} + +var _wrap__swig_DirectorBar_upcall_Cheer unsafe.Pointer + +func _swig_wrap__swig_DirectorBar_upcall_Cheer(_swig_ptr SwigcptrBar) (_swig_ret string) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) + _cgo_runtime_cgocall(_wrap__swig_DirectorBar_upcall_Cheer, _swig_p) + return +} + +func (swig_p *_swig_DirectorBar) Cheer() string { + if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceBarCheer); swig_ok { + return swig_g.Cheer() + } + var swig_r string + swig_r = _swig_wrap__swig_DirectorBar_upcall_Cheer(swig_p.SwigcptrBar) + return swig_r +} + +func DirectorBarCheer(p Bar) string { + var swig_r string + swig_r = _swig_wrap__swig_DirectorBar_upcall_Cheer(p.(*_swig_DirectorBar).SwigcptrBar) + return swig_r +} + +func Swig_DirectorBar_callback_cheer(p *_swig_DirectorBar) (swig_result string) { + var swig_r string + swig_r = p.Cheer() + return swig_r +} + +type SwigcptrBar uintptr + +func (p SwigcptrBar) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrBar) SwigIsBar() { +} + +func (p SwigcptrBar) DirectorInterface() interface{} { + return nil +} + +var _wrap_Bar_create unsafe.Pointer + +func _swig_wrap_Bar_create(base SwigcptrBar) (_ SwigcptrFoo) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Bar_create, _swig_p) + return +} + +func (arg1 SwigcptrBar) Create() (_swig_ret Foo) { + return _swig_wrap_Bar_create(arg1) +} + +var _wrap_Bar_callping unsafe.Pointer + +func _swig_wrap_Bar_callping(base SwigcptrBar) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Bar_callping, _swig_p) + return +} + +func (arg1 SwigcptrBar) Callping() (_swig_ret string) { + return _swig_wrap_Bar_callping(arg1) +} + +var _wrap_Bar_callcheer unsafe.Pointer + +func _swig_wrap_Bar_callcheer(base SwigcptrBar) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Bar_callcheer, _swig_p) + return +} + +func (arg1 SwigcptrBar) Callcheer() (_swig_ret string) { + return _swig_wrap_Bar_callcheer(arg1) +} + +var _wrap_Bar_pong unsafe.Pointer + +func _swig_wrap_Bar_pong(base SwigcptrBar) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Bar_pong, _swig_p) + return +} + +func (arg1 SwigcptrBar) Pong() (_swig_ret string) { + return _swig_wrap_Bar_pong(arg1) +} + +var _wrap_Bar_a_set unsafe.Pointer + +func _swig_wrap_Bar_a_set(base SwigcptrBar, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Bar_a_set, _swig_p) + return +} + +func (arg1 SwigcptrBar) SetA(arg2 int) { + _swig_wrap_Bar_a_set(arg1, arg2) +} + +var _wrap_Bar_a_get unsafe.Pointer + +func _swig_wrap_Bar_a_get(base SwigcptrBar) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Bar_a_get, _swig_p) + return +} + +func (arg1 SwigcptrBar) GetA() (_swig_ret int) { + return _swig_wrap_Bar_a_get(arg1) +} + +var _wrap_Bar_used unsafe.Pointer + +func _swig_wrap_Bar_used(base SwigcptrBar) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Bar_used, _swig_p) + return +} + +func (arg1 SwigcptrBar) Used() (_swig_ret string) { + return _swig_wrap_Bar_used(arg1) +} + +type BarHello int +var _wrap_new_Bar unsafe.Pointer + +func _swig_wrap_new_Bar() (base SwigcptrBar) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Bar, _swig_p) + return +} + +func NewBar() (_swig_ret Bar) { + return _swig_wrap_new_Bar() +} + +var _wrap_delete_Bar unsafe.Pointer + +func _swig_wrap_delete_Bar(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Bar, _swig_p) + return +} + +func DeleteBar(arg1 Bar) { + _swig_wrap_delete_Bar(arg1.Swigcptr()) +} + +var _wrap_Bar_s unsafe.Pointer + +func _swig_wrap_Bar_s(base SwigcptrBar) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Bar_s, _swig_p) + return +} + +func (_swig_base SwigcptrBar) S() (_swig_ret int) { + return _swig_wrap_Bar_s(_swig_base) +} + +var _wrap_Bar_q unsafe.Pointer + +func _swig_wrap_Bar_q(base SwigcptrBar) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Bar_q, _swig_p) + return +} + +func (_swig_base SwigcptrBar) Q() (_swig_ret int) { + return _swig_wrap_Bar_q(_swig_base) +} + +func (p SwigcptrBar) SwigIsFoo() { +} + +func (p SwigcptrBar) SwigGetFoo() Foo { + return SwigcptrFoo(p.Swigcptr()) +} + +type Bar interface { + Swigcptr() uintptr + SwigIsBar() + DirectorInterface() interface{} + Create() (_swig_ret Foo) + Callping() (_swig_ret string) + Callcheer() (_swig_ret string) + Pong() (_swig_ret string) + SetA(arg2 int) + GetA() (_swig_ret int) + Used() (_swig_ret string) + S() (_swig_ret int) + Q() (_swig_ret int) + SwigIsFoo() + SwigGetFoo() Foo +} + +type SwigcptrPrivateFoo uintptr + +func (p SwigcptrPrivateFoo) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrPrivateFoo) SwigIsPrivateFoo() { +} + +var _wrap_delete_PrivateFoo unsafe.Pointer + +func _swig_wrap_delete_PrivateFoo(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_PrivateFoo, _swig_p) + return +} + +func DeletePrivateFoo(arg1 PrivateFoo) { + _swig_wrap_delete_PrivateFoo(arg1.Swigcptr()) +} + +type PrivateFoo interface { + Swigcptr() uintptr + SwigIsPrivateFoo() +} + +type _swig_DirectorA struct { + SwigcptrA + v interface{} +} + +func (p *_swig_DirectorA) Swigcptr() uintptr { + return p.SwigcptrA.Swigcptr() +} + +func (p *_swig_DirectorA) SwigIsA() { +} + +func (p *_swig_DirectorA) DirectorInterface() interface{} { + return p.v +} + +var _wrap__swig_NewDirectorAA unsafe.Pointer + +func _swig_NewDirectorAA(_swig_director *_swig_DirectorA) (_swig_ret SwigcptrA) { + _swig_p := uintptr(unsafe.Pointer(&_swig_director)) + _cgo_runtime_cgocall(_wrap__swig_NewDirectorAA, _swig_p) + return +} + +func NewDirectorA(v interface{}) A { + p := &_swig_DirectorA{0, v} + p.SwigcptrA = _swig_NewDirectorAA(p) + return p +} + +var _wrap_DeleteDirectorA unsafe.Pointer + +func _swig_wrap_DeleteDirectorA(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_DeleteDirectorA, _swig_p) + return +} + +func DeleteDirectorA(arg1 A) { + _swig_wrap_DeleteDirectorA(arg1.Swigcptr()) +} + +func Swiggo_DeleteDirector_A(p *_swig_DirectorA) { + p.SwigcptrA = 0 +} + +type _swig_DirectorInterfaceADraw interface { + Draw() +} + +var _wrap__swig_DirectorA_upcall_Draw unsafe.Pointer + +func _swig_wrap__swig_DirectorA_upcall_Draw(_swig_ptr SwigcptrA) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) + _cgo_runtime_cgocall(_wrap__swig_DirectorA_upcall_Draw, _swig_p) + return +} + +func (swig_p *_swig_DirectorA) Draw() { + if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceADraw); swig_ok { + swig_g.Draw() + return + } + _swig_wrap__swig_DirectorA_upcall_Draw(swig_p.SwigcptrA) +} + +func DirectorADraw(p A) { + _swig_wrap__swig_DirectorA_upcall_Draw(p.(*_swig_DirectorA).SwigcptrA) +} + +func Swig_DirectorA_callback_draw(p *_swig_DirectorA) { + p.Draw() +} + +type SwigcptrA uintptr + +func (p SwigcptrA) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrA) SwigIsA() { +} + +func (p SwigcptrA) DirectorInterface() interface{} { + return nil +} + +var _wrap_new_A unsafe.Pointer + +func _swig_wrap_new_A() (base SwigcptrA) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_A, _swig_p) + return +} + +func NewA() (_swig_ret A) { + return _swig_wrap_new_A() +} + +var _wrap_delete_A unsafe.Pointer + +func _swig_wrap_delete_A(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_A, _swig_p) + return +} + +func DeleteA(arg1 A) { + _swig_wrap_delete_A(arg1.Swigcptr()) +} + +type A interface { + Swigcptr() uintptr + SwigIsA() + DirectorInterface() interface{} +} + +type _swig_DirectorB struct { + SwigcptrB + v interface{} +} + +func (p *_swig_DirectorB) Swigcptr() uintptr { + return p.SwigcptrB.Swigcptr() +} + +func (p *_swig_DirectorB) SwigIsB() { +} + +func (p *_swig_DirectorB) DirectorInterface() interface{} { + return p.v +} + +var _wrap__swig_NewDirectorBB unsafe.Pointer + +func _swig_NewDirectorBB(_swig_director *_swig_DirectorB) (_swig_ret SwigcptrB) { + _swig_p := uintptr(unsafe.Pointer(&_swig_director)) + _cgo_runtime_cgocall(_wrap__swig_NewDirectorBB, _swig_p) + return +} + +func NewDirectorB(v interface{}) B { + p := &_swig_DirectorB{0, v} + p.SwigcptrB = _swig_NewDirectorBB(p) + return p +} + +var _wrap_DeleteDirectorB unsafe.Pointer + +func _swig_wrap_DeleteDirectorB(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_DeleteDirectorB, _swig_p) + return +} + +func DeleteDirectorB(arg1 B) { + _swig_wrap_DeleteDirectorB(arg1.Swigcptr()) +} + +func Swiggo_DeleteDirector_B(p *_swig_DirectorB) { + p.SwigcptrB = 0 +} + +type _swig_DirectorInterfaceBDraw interface { + Draw() +} + +var _wrap__swig_DirectorB_upcall_Draw unsafe.Pointer + +func _swig_wrap__swig_DirectorB_upcall_Draw(_swig_ptr SwigcptrB) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) + _cgo_runtime_cgocall(_wrap__swig_DirectorB_upcall_Draw, _swig_p) + return +} + +func (swig_p *_swig_DirectorB) Draw() { + if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceBDraw); swig_ok { + swig_g.Draw() + return + } + _swig_wrap__swig_DirectorB_upcall_Draw(swig_p.SwigcptrB) +} + +func DirectorBDraw(p B) { + _swig_wrap__swig_DirectorB_upcall_Draw(p.(*_swig_DirectorB).SwigcptrB) +} + +func Swig_DirectorB_callback_draw(p *_swig_DirectorB) { + p.Draw() +} + +type SwigcptrB uintptr + +func (p SwigcptrB) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrB) SwigIsB() { +} + +func (p SwigcptrB) DirectorInterface() interface{} { + return nil +} + +var _wrap_new_B unsafe.Pointer + +func _swig_wrap_new_B() (base SwigcptrB) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_B, _swig_p) + return +} + +func NewB() (_swig_ret B) { + return _swig_wrap_new_B() +} + +var _wrap_delete_B unsafe.Pointer + +func _swig_wrap_delete_B(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_B, _swig_p) + return +} + +func DeleteB(arg1 B) { + _swig_wrap_delete_B(arg1.Swigcptr()) +} + +func (p SwigcptrB) SwigIsA() { +} + +func (p SwigcptrB) SwigGetA() A { + return SwigcptrA(p.Swigcptr()) +} + +type B interface { + Swigcptr() uintptr + SwigIsB() + DirectorInterface() interface{} + SwigIsA() + SwigGetA() A +} + +type SwigcptrAA uintptr + +func (p SwigcptrAA) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrAA) SwigIsAA() { +} + +var _wrap_new_AA unsafe.Pointer + +func _swig_wrap_new_AA() (base SwigcptrAA) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_AA, _swig_p) + return +} + +func NewAA() (_swig_ret AA) { + return _swig_wrap_new_AA() +} + +var _wrap_delete_AA unsafe.Pointer + +func _swig_wrap_delete_AA(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_AA, _swig_p) + return +} + +func DeleteAA(arg1 AA) { + _swig_wrap_delete_AA(arg1.Swigcptr()) +} + +type AA interface { + Swigcptr() uintptr + SwigIsAA() +} + +type SwigcptrBB uintptr + +func (p SwigcptrBB) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrBB) SwigIsBB() { +} + +var _wrap_new_BB unsafe.Pointer + +func _swig_wrap_new_BB() (base SwigcptrBB) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_BB, _swig_p) + return +} + +func NewBB() (_swig_ret BB) { + return _swig_wrap_new_BB() +} + +var _wrap_delete_BB unsafe.Pointer + +func _swig_wrap_delete_BB(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_BB, _swig_p) + return +} + +func DeleteBB(arg1 BB) { + _swig_wrap_delete_BB(arg1.Swigcptr()) +} + +func (p SwigcptrBB) SwigIsAA() { +} + +func (p SwigcptrBB) SwigGetAA() AA { + return SwigcptrAA(p.Swigcptr()) +} + +type BB interface { + Swigcptr() uintptr + SwigIsBB() + SwigIsAA() + SwigGetAA() AA +} + + +type SwigcptrSwigDirector_A uintptr +type SwigDirector_A interface { + Swigcptr() uintptr; +} +func (p SwigcptrSwigDirector_A) Swigcptr() uintptr { + return uintptr(p) +} + +type SwigcptrSwigDirector_B uintptr +type SwigDirector_B interface { + Swigcptr() uintptr; +} +func (p SwigcptrSwigDirector_B) Swigcptr() uintptr { + return uintptr(p) +} + +type SwigcptrSwigDirector_Foo uintptr +type SwigDirector_Foo interface { + Swigcptr() uintptr; +} +func (p SwigcptrSwigDirector_Foo) Swigcptr() uintptr { + return uintptr(p) +} + +type SwigcptrSwigDirector_Bar uintptr +type SwigDirector_Bar interface { + Swigcptr() uintptr; +} +func (p SwigcptrSwigDirector_Bar) Swigcptr() uintptr { + return uintptr(p) +} + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/director_protected_overloaded.go b/Examples/test-suite/go/director_protected_overloaded.go new file mode 100644 index 000000000..90ca6e74e --- /dev/null +++ b/Examples/test-suite/go/director_protected_overloaded.go @@ -0,0 +1,386 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../director_protected_overloaded.i + +package director_protected_overloaded + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type _swig_DirectorIDataObserver struct { + SwigcptrIDataObserver + v interface{} +} + +func (p *_swig_DirectorIDataObserver) Swigcptr() uintptr { + return p.SwigcptrIDataObserver.Swigcptr() +} + +func (p *_swig_DirectorIDataObserver) SwigIsIDataObserver() { +} + +func (p *_swig_DirectorIDataObserver) DirectorInterface() interface{} { + return p.v +} + +var _wrap__swig_NewDirectorIDataObserverIDataObserver unsafe.Pointer + +func _swig_NewDirectorIDataObserverIDataObserver(_swig_director *_swig_DirectorIDataObserver) (_swig_ret SwigcptrIDataObserver) { + _swig_p := uintptr(unsafe.Pointer(&_swig_director)) + _cgo_runtime_cgocall(_wrap__swig_NewDirectorIDataObserverIDataObserver, _swig_p) + return +} + +func NewDirectorIDataObserver(v interface{}) IDataObserver { + p := &_swig_DirectorIDataObserver{0, v} + p.SwigcptrIDataObserver = _swig_NewDirectorIDataObserverIDataObserver(p) + return p +} + +var _wrap_DeleteDirectorIDataObserver unsafe.Pointer + +func _swig_wrap_DeleteDirectorIDataObserver(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_DeleteDirectorIDataObserver, _swig_p) + return +} + +func DeleteDirectorIDataObserver(arg1 IDataObserver) { + _swig_wrap_DeleteDirectorIDataObserver(arg1.Swigcptr()) +} + +func Swiggo_DeleteDirector_IDataObserver(p *_swig_DirectorIDataObserver) { + p.SwigcptrIDataObserver = 0 +} + +type _swig_DirectorInterfaceIDataObserverNotoverloaded interface { + Notoverloaded() +} + +func (swig_p *_swig_DirectorIDataObserver) Notoverloaded() { + if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceIDataObserverNotoverloaded); swig_ok { + swig_g.Notoverloaded() + return + } + panic("call to pure virtual method") +} + +func Swig_DirectorIDataObserver_callback_notoverloaded(p *_swig_DirectorIDataObserver) { + p.Notoverloaded() +} + +type _swig_DirectorInterfaceIDataObserverIsoverloaded__SWIG_0 interface { + Isoverloaded__SWIG_0() +} + +func (swig_p *_swig_DirectorIDataObserver) Isoverloaded__SWIG_0() { + if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceIDataObserverIsoverloaded__SWIG_0); swig_ok { + swig_g.Isoverloaded__SWIG_0() + return + } + panic("call to pure virtual method") +} + +func Swig_DirectorIDataObserver_callback_isoverloaded__SWIG_0(p *_swig_DirectorIDataObserver) { + p.Isoverloaded__SWIG_0() +} + +type _swig_DirectorInterfaceIDataObserverIsoverloaded__SWIG_1 interface { + Isoverloaded__SWIG_1(int) +} + +func (swig_p *_swig_DirectorIDataObserver) Isoverloaded__SWIG_1(i int) { + if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceIDataObserverIsoverloaded__SWIG_1); swig_ok { + swig_g.Isoverloaded__SWIG_1(i) + return + } + panic("call to pure virtual method") +} + +func Swig_DirectorIDataObserver_callback_isoverloaded__SWIG_1(p *_swig_DirectorIDataObserver, i int) { + p.Isoverloaded__SWIG_1(i) +} + +type _swig_DirectorInterfaceIDataObserverIsoverloaded__SWIG_2 interface { + Isoverloaded__SWIG_2(int, float64) +} + +func (swig_p *_swig_DirectorIDataObserver) Isoverloaded__SWIG_2(i int, d float64) { + if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceIDataObserverIsoverloaded__SWIG_2); swig_ok { + swig_g.Isoverloaded__SWIG_2(i, d) + return + } + panic("call to pure virtual method") +} + +func Swig_DirectorIDataObserver_callback_isoverloaded__SWIG_2(p *_swig_DirectorIDataObserver, i int, d float64) { + p.Isoverloaded__SWIG_2(i, d) +} + +func (p _swig_DirectorIDataObserver) Isoverloaded(a ...interface{}) { + argc := len(a) + if argc == 0 { + p.Isoverloaded__SWIG_0() + return + } + if argc == 1 { + p.Isoverloaded__SWIG_1(a[0].(int)) + return + } + if argc == 2 { + p.Isoverloaded__SWIG_2(a[0].(int), a[1].(float64)) + return + } + panic("No match for overloaded function call") +} + +type SwigcptrIDataObserver uintptr + +func (p SwigcptrIDataObserver) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrIDataObserver) SwigIsIDataObserver() { +} + +func (p SwigcptrIDataObserver) DirectorInterface() interface{} { + return nil +} + +var _wrap_delete_IDataObserver unsafe.Pointer + +func _swig_wrap_delete_IDataObserver(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_IDataObserver, _swig_p) + return +} + +func DeleteIDataObserver(arg1 IDataObserver) { + _swig_wrap_delete_IDataObserver(arg1.Swigcptr()) +} + +var _wrap_new_IDataObserver unsafe.Pointer + +func _swig_wrap_new_IDataObserver() (base SwigcptrIDataObserver) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_IDataObserver, _swig_p) + return +} + +func NewIDataObserver() (_swig_ret IDataObserver) { + return _swig_wrap_new_IDataObserver() +} + +type IDataObserver interface { + Swigcptr() uintptr + SwigIsIDataObserver() + DirectorInterface() interface{} +} + +type _swig_DirectorDerivedDataObserver struct { + SwigcptrDerivedDataObserver + v interface{} +} + +func (p *_swig_DirectorDerivedDataObserver) Swigcptr() uintptr { + return p.SwigcptrDerivedDataObserver.Swigcptr() +} + +func (p *_swig_DirectorDerivedDataObserver) SwigIsDerivedDataObserver() { +} + +func (p *_swig_DirectorDerivedDataObserver) DirectorInterface() interface{} { + return p.v +} + +var _wrap__swig_NewDirectorDerivedDataObserverDerivedDataObserver unsafe.Pointer + +func _swig_NewDirectorDerivedDataObserverDerivedDataObserver(_swig_director *_swig_DirectorDerivedDataObserver) (_swig_ret SwigcptrDerivedDataObserver) { + _swig_p := uintptr(unsafe.Pointer(&_swig_director)) + _cgo_runtime_cgocall(_wrap__swig_NewDirectorDerivedDataObserverDerivedDataObserver, _swig_p) + return +} + +func NewDirectorDerivedDataObserver(v interface{}) DerivedDataObserver { + p := &_swig_DirectorDerivedDataObserver{0, v} + p.SwigcptrDerivedDataObserver = _swig_NewDirectorDerivedDataObserverDerivedDataObserver(p) + return p +} + +var _wrap_DeleteDirectorDerivedDataObserver unsafe.Pointer + +func _swig_wrap_DeleteDirectorDerivedDataObserver(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_DeleteDirectorDerivedDataObserver, _swig_p) + return +} + +func DeleteDirectorDerivedDataObserver(arg1 DerivedDataObserver) { + _swig_wrap_DeleteDirectorDerivedDataObserver(arg1.Swigcptr()) +} + +func Swiggo_DeleteDirector_DerivedDataObserver(p *_swig_DirectorDerivedDataObserver) { + p.SwigcptrDerivedDataObserver = 0 +} + +type _swig_DirectorInterfaceDerivedDataObserverNotoverloaded interface { + Notoverloaded() +} + +func (swig_p *_swig_DirectorDerivedDataObserver) Notoverloaded() { + if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceDerivedDataObserverNotoverloaded); swig_ok { + swig_g.Notoverloaded() + return + } + panic("call to pure virtual method") +} + +func Swig_DirectorDerivedDataObserver_callback_notoverloaded(p *_swig_DirectorDerivedDataObserver) { + p.Notoverloaded() +} + +type _swig_DirectorInterfaceDerivedDataObserverIsoverloaded__SWIG_0 interface { + Isoverloaded__SWIG_0() +} + +func (swig_p *_swig_DirectorDerivedDataObserver) Isoverloaded__SWIG_0() { + if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceDerivedDataObserverIsoverloaded__SWIG_0); swig_ok { + swig_g.Isoverloaded__SWIG_0() + return + } + panic("call to pure virtual method") +} + +func Swig_DirectorDerivedDataObserver_callback_isoverloaded__SWIG_0(p *_swig_DirectorDerivedDataObserver) { + p.Isoverloaded__SWIG_0() +} + +type _swig_DirectorInterfaceDerivedDataObserverIsoverloaded__SWIG_1 interface { + Isoverloaded__SWIG_1(int) +} + +func (swig_p *_swig_DirectorDerivedDataObserver) Isoverloaded__SWIG_1(i int) { + if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceDerivedDataObserverIsoverloaded__SWIG_1); swig_ok { + swig_g.Isoverloaded__SWIG_1(i) + return + } + panic("call to pure virtual method") +} + +func Swig_DirectorDerivedDataObserver_callback_isoverloaded__SWIG_1(p *_swig_DirectorDerivedDataObserver, i int) { + p.Isoverloaded__SWIG_1(i) +} + +type _swig_DirectorInterfaceDerivedDataObserverIsoverloaded__SWIG_2 interface { + Isoverloaded__SWIG_2(int, float64) +} + +func (swig_p *_swig_DirectorDerivedDataObserver) Isoverloaded__SWIG_2(i int, d float64) { + if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceDerivedDataObserverIsoverloaded__SWIG_2); swig_ok { + swig_g.Isoverloaded__SWIG_2(i, d) + return + } + panic("call to pure virtual method") +} + +func Swig_DirectorDerivedDataObserver_callback_isoverloaded__SWIG_2(p *_swig_DirectorDerivedDataObserver, i int, d float64) { + p.Isoverloaded__SWIG_2(i, d) +} + +func (p _swig_DirectorDerivedDataObserver) Isoverloaded(a ...interface{}) { + argc := len(a) + if argc == 0 { + p.Isoverloaded__SWIG_0() + return + } + if argc == 1 { + p.Isoverloaded__SWIG_1(a[0].(int)) + return + } + if argc == 2 { + p.Isoverloaded__SWIG_2(a[0].(int), a[1].(float64)) + return + } + panic("No match for overloaded function call") +} + +type SwigcptrDerivedDataObserver uintptr + +func (p SwigcptrDerivedDataObserver) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrDerivedDataObserver) SwigIsDerivedDataObserver() { +} + +func (p SwigcptrDerivedDataObserver) DirectorInterface() interface{} { + return nil +} + +var _wrap_new_DerivedDataObserver unsafe.Pointer + +func _swig_wrap_new_DerivedDataObserver() (base SwigcptrDerivedDataObserver) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_DerivedDataObserver, _swig_p) + return +} + +func NewDerivedDataObserver() (_swig_ret DerivedDataObserver) { + return _swig_wrap_new_DerivedDataObserver() +} + +var _wrap_delete_DerivedDataObserver unsafe.Pointer + +func _swig_wrap_delete_DerivedDataObserver(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_DerivedDataObserver, _swig_p) + return +} + +func DeleteDerivedDataObserver(arg1 DerivedDataObserver) { + _swig_wrap_delete_DerivedDataObserver(arg1.Swigcptr()) +} + +func (p SwigcptrDerivedDataObserver) SwigIsIDataObserver() { +} + +func (p SwigcptrDerivedDataObserver) SwigGetIDataObserver() IDataObserver { + return SwigcptrIDataObserver(p.Swigcptr()) +} + +type DerivedDataObserver interface { + Swigcptr() uintptr + SwigIsDerivedDataObserver() + DirectorInterface() interface{} + SwigIsIDataObserver() + SwigGetIDataObserver() IDataObserver +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/director_protected_overloaded_wrap.h b/Examples/test-suite/go/director_protected_overloaded_wrap.h new file mode 100644 index 000000000..03d05cadd --- /dev/null +++ b/Examples/test-suite/go/director_protected_overloaded_wrap.h @@ -0,0 +1,42 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../director_protected_overloaded.i + +#ifndef SWIG_director_protected_overloaded_WRAP_H_ +#define SWIG_director_protected_overloaded_WRAP_H_ + +class SwigDirector_IDataObserver : public IDataObserver +{ + public: + SwigDirector_IDataObserver(void *swig_p); + virtual ~SwigDirector_IDataObserver(); + virtual void notoverloaded(); + virtual void isoverloaded(); + virtual void isoverloaded(int i); + virtual void isoverloaded(int i, double d); + private: + void *go_val; +}; + +class SwigDirector_DerivedDataObserver : public DerivedDataObserver +{ + public: + SwigDirector_DerivedDataObserver(void *swig_p); + virtual ~SwigDirector_DerivedDataObserver(); + virtual void notoverloaded(); + virtual void isoverloaded(); + virtual void isoverloaded(int i); + virtual void isoverloaded(int i, double d); + private: + void *go_val; +}; + +#endif diff --git a/Examples/test-suite/go/director_protected_runme b/Examples/test-suite/go/director_protected_runme new file mode 100755 index 000000000..3cd60841c Binary files /dev/null and b/Examples/test-suite/go/director_protected_runme differ diff --git a/Examples/test-suite/go/director_protected_wrap.h b/Examples/test-suite/go/director_protected_wrap.h new file mode 100644 index 000000000..ce845aa39 --- /dev/null +++ b/Examples/test-suite/go/director_protected_wrap.h @@ -0,0 +1,97 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../director_protected.i + +#ifndef SWIG_director_protected_WRAP_H_ +#define SWIG_director_protected_WRAP_H_ + +class SwigDirector_Foo : public Foo +{ + public: + SwigDirector_Foo(void *swig_p); + virtual ~SwigDirector_Foo(); + std::string _swig_upcall_pong() { + return Foo::pong(); + } + virtual std::string pong(); + virtual std::string ping(); + std::string _swig_upcall_pang() { + return Foo::pang(); + } + virtual std::string pang(); + std::string _swig_upcall_used() { + return Foo::used(); + } + virtual std::string used(); + std::string _swig_upcall_cheer() { + return Foo::cheer(); + } + virtual std::string cheer(); + private: + void *go_val; +}; + +class SwigDirector_Bar : public Bar +{ + public: + SwigDirector_Bar(void *swig_p); + virtual ~SwigDirector_Bar(); + std::string _swig_upcall_pong() { + return Bar::pong(); + } + virtual std::string pong(); + std::string _swig_upcall_ping() { + return Bar::ping(); + } + virtual std::string ping(); + std::string _swig_upcall_pang() { + return Foo::pang(); + } + virtual std::string pang(); + std::string _swig_upcall_used() { + return Bar::used(); + } + virtual std::string used(); + std::string _swig_upcall_cheer() { + return Bar::cheer(); + } + virtual std::string cheer(); + private: + void *go_val; +}; + +class SwigDirector_A : public A +{ + public: + SwigDirector_A(void *swig_p); + virtual ~SwigDirector_A(); + void _swig_upcall_draw() { + A::draw(); + } + virtual void draw(); + private: + void *go_val; +}; + +class SwigDirector_B : public B +{ + public: + SwigDirector_B(void *swig_p); + virtual ~SwigDirector_B(); + void _swig_upcall_draw() { + B::draw(); + } + virtual void draw(); + private: + void *go_val; +}; + +#endif diff --git a/Examples/test-suite/go/director_redefined.go b/Examples/test-suite/go/director_redefined.go new file mode 100644 index 000000000..c3130ec03 --- /dev/null +++ b/Examples/test-suite/go/director_redefined.go @@ -0,0 +1,312 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../director_redefined.i + +package director_redefined + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrA uintptr + +func (p SwigcptrA) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrA) SwigIsA() { +} + +var _wrap_delete_A unsafe.Pointer + +func _swig_wrap_delete_A(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_A, _swig_p) + return +} + +func DeleteA(arg1 A) { + _swig_wrap_delete_A(arg1.Swigcptr()) +} + +var _wrap_A_get_val unsafe.Pointer + +func _swig_wrap_A_get_val(base SwigcptrA, _ int) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_A_get_val, _swig_p) + return +} + +func (arg1 SwigcptrA) Get_val(arg2 int) (_swig_ret int) { + return _swig_wrap_A_get_val(arg1, arg2) +} + +var _wrap_A_get_rval unsafe.Pointer + +func _swig_wrap_A_get_rval(base SwigcptrA, _ int) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_A_get_rval, _swig_p) + return +} + +func (arg1 SwigcptrA) Get_rval(arg2 int) (_swig_ret int) { + return _swig_wrap_A_get_rval(arg1, arg2) +} + +var _wrap_new_A unsafe.Pointer + +func _swig_wrap_new_A() (base SwigcptrA) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_A, _swig_p) + return +} + +func NewA() (_swig_ret A) { + return _swig_wrap_new_A() +} + +type A interface { + Swigcptr() uintptr + SwigIsA() + Get_val(arg2 int) (_swig_ret int) + Get_rval(arg2 int) (_swig_ret int) +} + +type _swig_DirectorB struct { + SwigcptrB + v interface{} +} + +func (p *_swig_DirectorB) Swigcptr() uintptr { + return p.SwigcptrB.Swigcptr() +} + +func (p *_swig_DirectorB) SwigIsB() { +} + +func (p *_swig_DirectorB) DirectorInterface() interface{} { + return p.v +} + +var _wrap__swig_NewDirectorBB unsafe.Pointer + +func _swig_NewDirectorBB(_swig_director *_swig_DirectorB) (_swig_ret SwigcptrB) { + _swig_p := uintptr(unsafe.Pointer(&_swig_director)) + _cgo_runtime_cgocall(_wrap__swig_NewDirectorBB, _swig_p) + return +} + +func NewDirectorB(v interface{}) B { + p := &_swig_DirectorB{0, v} + p.SwigcptrB = _swig_NewDirectorBB(p) + return p +} + +var _wrap_DeleteDirectorB unsafe.Pointer + +func _swig_wrap_DeleteDirectorB(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_DeleteDirectorB, _swig_p) + return +} + +func DeleteDirectorB(arg1 B) { + _swig_wrap_DeleteDirectorB(arg1.Swigcptr()) +} + +func Swiggo_DeleteDirector_B(p *_swig_DirectorB) { + p.SwigcptrB = 0 +} + +type _swig_DirectorInterfaceBGet_val interface { + Get_val(int) int +} + +var _wrap__swig_DirectorB_upcall_Get_val unsafe.Pointer + +func _swig_wrap__swig_DirectorB_upcall_Get_val(_swig_ptr SwigcptrB, _ int) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) + _cgo_runtime_cgocall(_wrap__swig_DirectorB_upcall_Get_val, _swig_p) + return +} + +func (swig_p *_swig_DirectorB) Get_val(a int) int { + if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceBGet_val); swig_ok { + return swig_g.Get_val(a) + } + var swig_r int + swig_r = _swig_wrap__swig_DirectorB_upcall_Get_val(swig_p.SwigcptrB, a) + return swig_r +} + +func DirectorBGet_val(p B, arg2 int) int { + var swig_r int + swig_r = _swig_wrap__swig_DirectorB_upcall_Get_val(p.(*_swig_DirectorB).SwigcptrB, arg2) + return swig_r +} + +func Swig_DirectorB_callback_get_val(p *_swig_DirectorB, arg2 int) (swig_result int) { + var swig_r int + swig_r = p.Get_val(arg2) + return swig_r +} + +type _swig_DirectorInterfaceBGet_rval interface { + Get_rval(int) int +} + +var _wrap__swig_DirectorB_upcall_Get_rval unsafe.Pointer + +func _swig_wrap__swig_DirectorB_upcall_Get_rval(_swig_ptr SwigcptrB, _ int) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) + _cgo_runtime_cgocall(_wrap__swig_DirectorB_upcall_Get_rval, _swig_p) + return +} + +func (swig_p *_swig_DirectorB) Get_rval(a int) int { + if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceBGet_rval); swig_ok { + return swig_g.Get_rval(a) + } + var swig_r int + swig_r = _swig_wrap__swig_DirectorB_upcall_Get_rval(swig_p.SwigcptrB, a) + return swig_r +} + +func DirectorBGet_rval(p B, arg2 int) int { + var swig_r int + swig_r = _swig_wrap__swig_DirectorB_upcall_Get_rval(p.(*_swig_DirectorB).SwigcptrB, arg2) + return swig_r +} + +func Swig_DirectorB_callback_get_rval(p *_swig_DirectorB, arg2 int) (swig_result int) { + var swig_r int + swig_r = p.Get_rval(arg2) + return swig_r +} + +type SwigcptrB uintptr + +func (p SwigcptrB) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrB) SwigIsB() { +} + +func (p SwigcptrB) DirectorInterface() interface{} { + return nil +} + +var _wrap_B_get_val unsafe.Pointer + +func _swig_wrap_B_get_val(base SwigcptrB, _ int) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_B_get_val, _swig_p) + return +} + +func (arg1 SwigcptrB) Get_val(arg2 int) (_swig_ret int) { + return _swig_wrap_B_get_val(arg1, arg2) +} + +var _wrap_B_get_rval unsafe.Pointer + +func _swig_wrap_B_get_rval(base SwigcptrB, _ int) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_B_get_rval, _swig_p) + return +} + +func (arg1 SwigcptrB) Get_rval(arg2 int) (_swig_ret int) { + return _swig_wrap_B_get_rval(arg1, arg2) +} + +var _wrap_B_get_rrval unsafe.Pointer + +func _swig_wrap_B_get_rrval(base SwigcptrB, _ int) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_B_get_rrval, _swig_p) + return +} + +func (arg1 SwigcptrB) Get_rrval(arg2 int) (_swig_ret int) { + return _swig_wrap_B_get_rrval(arg1, arg2) +} + +var _wrap_new_B unsafe.Pointer + +func _swig_wrap_new_B() (base SwigcptrB) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_B, _swig_p) + return +} + +func NewB() (_swig_ret B) { + return _swig_wrap_new_B() +} + +var _wrap_delete_B unsafe.Pointer + +func _swig_wrap_delete_B(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_B, _swig_p) + return +} + +func DeleteB(arg1 B) { + _swig_wrap_delete_B(arg1.Swigcptr()) +} + +func (p SwigcptrB) SwigIsA() { +} + +func (p SwigcptrB) SwigGetA() A { + return SwigcptrA(p.Swigcptr()) +} + +type B interface { + Swigcptr() uintptr + SwigIsB() + DirectorInterface() interface{} + Get_val(arg2 int) (_swig_ret int) + Get_rval(arg2 int) (_swig_ret int) + Get_rrval(arg2 int) (_swig_ret int) + SwigIsA() + SwigGetA() A +} + + +type SwigcptrSwigDirector_B uintptr +type SwigDirector_B interface { + Swigcptr() uintptr; +} +func (p SwigcptrSwigDirector_B) Swigcptr() uintptr { + return uintptr(p) +} + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/director_redefined_wrap.h b/Examples/test-suite/go/director_redefined_wrap.h new file mode 100644 index 000000000..4f09ba805 --- /dev/null +++ b/Examples/test-suite/go/director_redefined_wrap.h @@ -0,0 +1,33 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../director_redefined.i + +#ifndef SWIG_director_redefined_WRAP_H_ +#define SWIG_director_redefined_WRAP_H_ + +class SwigDirector_B : public B +{ + public: + SwigDirector_B(void *swig_p); + virtual ~SwigDirector_B(); + int _swig_upcall_get_val(int a) { + return B::get_val(a); + } + virtual int get_val(int a); + int _swig_upcall_get_rval(int const &a) { + return B::get_rval(a); + } + virtual int get_rval(int const &a); + private: + void *go_val; +}; + +#endif diff --git a/Examples/test-suite/go/director_smartptr.go b/Examples/test-suite/go/director_smartptr.go new file mode 100644 index 000000000..6f5a7a0c5 --- /dev/null +++ b/Examples/test-suite/go/director_smartptr.go @@ -0,0 +1,29 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../director_smartptr.i + +package director_smartptr + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + + diff --git a/Examples/test-suite/go/director_smartptr_wrap.h b/Examples/test-suite/go/director_smartptr_wrap.h new file mode 100644 index 000000000..95dd9470d --- /dev/null +++ b/Examples/test-suite/go/director_smartptr_wrap.h @@ -0,0 +1,16 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../director_smartptr.i + +#ifndef SWIG_director_smartptr_WRAP_H_ +#define SWIG_director_smartptr_WRAP_H_ + +#endif diff --git a/Examples/test-suite/go/director_string.go b/Examples/test-suite/go/director_string.go new file mode 100644 index 000000000..c0d6f178b --- /dev/null +++ b/Examples/test-suite/go/director_string.go @@ -0,0 +1,609 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../director_string.i + +package director_string + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type _swig_DirectorA struct { + SwigcptrA + v interface{} +} + +func (p *_swig_DirectorA) Swigcptr() uintptr { + return p.SwigcptrA.Swigcptr() +} + +func (p *_swig_DirectorA) SwigIsA() { +} + +func (p *_swig_DirectorA) DirectorInterface() interface{} { + return p.v +} + +var _wrap__swig_NewDirectorAA unsafe.Pointer + +func _swig_NewDirectorAA(_swig_director *_swig_DirectorA, _ string) (_swig_ret SwigcptrA) { + _swig_p := uintptr(unsafe.Pointer(&_swig_director)) + _cgo_runtime_cgocall(_wrap__swig_NewDirectorAA, _swig_p) + return +} + +func NewDirectorA(v interface{}, arg1 string) A { + p := &_swig_DirectorA{0, v} + p.SwigcptrA = _swig_NewDirectorAA(p, arg1) + return p +} + +var _wrap_DeleteDirectorA unsafe.Pointer + +func _swig_wrap_DeleteDirectorA(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_DeleteDirectorA, _swig_p) + return +} + +func DeleteDirectorA(arg1 A) { + _swig_wrap_DeleteDirectorA(arg1.Swigcptr()) +} + +func Swiggo_DeleteDirector_A(p *_swig_DirectorA) { + p.SwigcptrA = 0 +} + +type _swig_DirectorInterfaceAGet_first interface { + Get_first() string +} + +var _wrap__swig_DirectorA_upcall_Get_first unsafe.Pointer + +func _swig_wrap__swig_DirectorA_upcall_Get_first(_swig_ptr SwigcptrA) (_swig_ret string) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) + _cgo_runtime_cgocall(_wrap__swig_DirectorA_upcall_Get_first, _swig_p) + return +} + +func (swig_p *_swig_DirectorA) Get_first() string { + if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceAGet_first); swig_ok { + return swig_g.Get_first() + } + var swig_r string + swig_r = _swig_wrap__swig_DirectorA_upcall_Get_first(swig_p.SwigcptrA) + return swig_r +} + +func DirectorAGet_first(p A) string { + var swig_r string + swig_r = _swig_wrap__swig_DirectorA_upcall_Get_first(p.(*_swig_DirectorA).SwigcptrA) + return swig_r +} + +func Swig_DirectorA_callback_get_first(p *_swig_DirectorA) (swig_result string) { + var swig_r string + swig_r = p.Get_first() + return swig_r +} + +type _swig_DirectorInterfaceAGet interface { + Get(int) string +} + +var _wrap__swig_DirectorA_upcall_Get unsafe.Pointer + +func _swig_wrap__swig_DirectorA_upcall_Get(_swig_ptr SwigcptrA, _ int) (_swig_ret string) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) + _cgo_runtime_cgocall(_wrap__swig_DirectorA_upcall_Get, _swig_p) + return +} + +func (swig_p *_swig_DirectorA) Get(n int) string { + if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceAGet); swig_ok { + return swig_g.Get(n) + } + var swig_r string + swig_r = _swig_wrap__swig_DirectorA_upcall_Get(swig_p.SwigcptrA, n) + return swig_r +} + +func DirectorAGet(p A, arg2 int) string { + var swig_r string + swig_r = _swig_wrap__swig_DirectorA_upcall_Get(p.(*_swig_DirectorA).SwigcptrA, arg2) + return swig_r +} + +func Swig_DirectorA_callback_get(p *_swig_DirectorA, arg2 int) (swig_result string) { + var swig_r string + swig_r = p.Get(arg2) + return swig_r +} + +type _swig_DirectorInterfaceACall_get_first interface { + Call_get_first() string +} + +var _wrap__swig_DirectorA_upcall_Call_get_first unsafe.Pointer + +func _swig_wrap__swig_DirectorA_upcall_Call_get_first(_swig_ptr SwigcptrA) (_swig_ret string) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) + _cgo_runtime_cgocall(_wrap__swig_DirectorA_upcall_Call_get_first, _swig_p) + return +} + +func (swig_p *_swig_DirectorA) Call_get_first() string { + if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceACall_get_first); swig_ok { + return swig_g.Call_get_first() + } + var swig_r string + swig_r = _swig_wrap__swig_DirectorA_upcall_Call_get_first(swig_p.SwigcptrA) + return swig_r +} + +func DirectorACall_get_first(p A) string { + var swig_r string + swig_r = _swig_wrap__swig_DirectorA_upcall_Call_get_first(p.(*_swig_DirectorA).SwigcptrA) + return swig_r +} + +func Swig_DirectorA_callback_call_get_first(p *_swig_DirectorA) (swig_result string) { + var swig_r string + swig_r = p.Call_get_first() + return swig_r +} + +type _swig_DirectorInterfaceACall_get interface { + Call_get(int) string +} + +var _wrap__swig_DirectorA_upcall_Call_get unsafe.Pointer + +func _swig_wrap__swig_DirectorA_upcall_Call_get(_swig_ptr SwigcptrA, _ int) (_swig_ret string) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) + _cgo_runtime_cgocall(_wrap__swig_DirectorA_upcall_Call_get, _swig_p) + return +} + +func (swig_p *_swig_DirectorA) Call_get(n int) string { + if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceACall_get); swig_ok { + return swig_g.Call_get(n) + } + var swig_r string + swig_r = _swig_wrap__swig_DirectorA_upcall_Call_get(swig_p.SwigcptrA, n) + return swig_r +} + +func DirectorACall_get(p A, arg2 int) string { + var swig_r string + swig_r = _swig_wrap__swig_DirectorA_upcall_Call_get(p.(*_swig_DirectorA).SwigcptrA, arg2) + return swig_r +} + +func Swig_DirectorA_callback_call_get(p *_swig_DirectorA, arg2 int) (swig_result string) { + var swig_r string + swig_r = p.Call_get(arg2) + return swig_r +} + +type _swig_DirectorInterfaceAString_length interface { + String_length(string) int +} + +var _wrap__swig_DirectorA_upcall_String_length unsafe.Pointer + +func _swig_wrap__swig_DirectorA_upcall_String_length(_swig_ptr SwigcptrA, _ string) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) + _cgo_runtime_cgocall(_wrap__swig_DirectorA_upcall_String_length, _swig_p) + return +} + +func (swig_p *_swig_DirectorA) String_length(s string) int { + if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceAString_length); swig_ok { + return swig_g.String_length(s) + } + var swig_r int + swig_r = _swig_wrap__swig_DirectorA_upcall_String_length(swig_p.SwigcptrA, s) + return swig_r +} + +func DirectorAString_length(p A, arg2 string) int { + var swig_r int + swig_r = _swig_wrap__swig_DirectorA_upcall_String_length(p.(*_swig_DirectorA).SwigcptrA, arg2) + return swig_r +} + +func Swig_DirectorA_callback_string_length(p *_swig_DirectorA, arg2 string) (swig_result int) { + var swig_r int + swig_r = p.String_length(arg2) + return swig_r +} + +type _swig_DirectorInterfaceAProcess_text interface { + Process_text(string) +} + +var _wrap__swig_DirectorA_upcall_Process_text unsafe.Pointer + +func _swig_wrap__swig_DirectorA_upcall_Process_text(_swig_ptr SwigcptrA, _ string) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) + _cgo_runtime_cgocall(_wrap__swig_DirectorA_upcall_Process_text, _swig_p) + return +} + +func (swig_p *_swig_DirectorA) Process_text(text string) { + if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceAProcess_text); swig_ok { + swig_g.Process_text(text) + return + } + _swig_wrap__swig_DirectorA_upcall_Process_text(swig_p.SwigcptrA, text) +} + +func DirectorAProcess_text(p A, arg2 string) { + _swig_wrap__swig_DirectorA_upcall_Process_text(p.(*_swig_DirectorA).SwigcptrA, arg2) +} + +func Swig_DirectorA_callback_process_text(p *_swig_DirectorA, arg2 string) { + p.Process_text(arg2) +} + +type SwigcptrA uintptr + +func (p SwigcptrA) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrA) SwigIsA() { +} + +func (p SwigcptrA) DirectorInterface() interface{} { + return nil +} + +var _wrap_new_A unsafe.Pointer + +func _swig_wrap_new_A(base string) (_ SwigcptrA) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_A, _swig_p) + return +} + +func NewA(arg1 string) (_swig_ret A) { + return _swig_wrap_new_A(arg1) +} + +var _wrap_delete_A unsafe.Pointer + +func _swig_wrap_delete_A(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_A, _swig_p) + return +} + +func DeleteA(arg1 A) { + _swig_wrap_delete_A(arg1.Swigcptr()) +} + +var _wrap_A_get_first unsafe.Pointer + +func _swig_wrap_A_get_first(base SwigcptrA) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_A_get_first, _swig_p) + return +} + +func (arg1 SwigcptrA) Get_first() (_swig_ret string) { + return _swig_wrap_A_get_first(arg1) +} + +var _wrap_A_get unsafe.Pointer + +func _swig_wrap_A_get(base SwigcptrA, _ int) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_A_get, _swig_p) + return +} + +func (arg1 SwigcptrA) Get(arg2 int) (_swig_ret string) { + return _swig_wrap_A_get(arg1, arg2) +} + +var _wrap_A_call_get_first unsafe.Pointer + +func _swig_wrap_A_call_get_first(base SwigcptrA) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_A_call_get_first, _swig_p) + return +} + +func (arg1 SwigcptrA) Call_get_first() (_swig_ret string) { + return _swig_wrap_A_call_get_first(arg1) +} + +var _wrap_A_call_get unsafe.Pointer + +func _swig_wrap_A_call_get(base SwigcptrA, _ int) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_A_call_get, _swig_p) + return +} + +func (arg1 SwigcptrA) Call_get(arg2 int) (_swig_ret string) { + return _swig_wrap_A_call_get(arg1, arg2) +} + +var _wrap_A_string_length unsafe.Pointer + +func _swig_wrap_A_string_length(base SwigcptrA, _ string) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_A_string_length, _swig_p) + return +} + +func (arg1 SwigcptrA) String_length(arg2 string) (_swig_ret int) { + return _swig_wrap_A_string_length(arg1, arg2) +} + +var _wrap_A_m_strings_set unsafe.Pointer + +func _swig_wrap_A_m_strings_set(base SwigcptrA, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_A_m_strings_set, _swig_p) + return +} + +func (arg1 SwigcptrA) SetM_strings(arg2 StringVector) { + _swig_wrap_A_m_strings_set(arg1, arg2.Swigcptr()) +} + +var _wrap_A_m_strings_get unsafe.Pointer + +func _swig_wrap_A_m_strings_get(base SwigcptrA) (_ SwigcptrStringVector) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_A_m_strings_get, _swig_p) + return +} + +func (arg1 SwigcptrA) GetM_strings() (_swig_ret StringVector) { + return _swig_wrap_A_m_strings_get(arg1) +} + +var _wrap_A_process_text unsafe.Pointer + +func _swig_wrap_A_process_text(base SwigcptrA, _ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_A_process_text, _swig_p) + return +} + +func (arg1 SwigcptrA) Process_text(arg2 string) { + _swig_wrap_A_process_text(arg1, arg2) +} + +var _wrap_A_call_process_func unsafe.Pointer + +func _swig_wrap_A_call_process_func(base SwigcptrA) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_A_call_process_func, _swig_p) + return +} + +func (arg1 SwigcptrA) Call_process_func() { + _swig_wrap_A_call_process_func(arg1) +} + +type A interface { + Swigcptr() uintptr + SwigIsA() + DirectorInterface() interface{} + Get_first() (_swig_ret string) + Get(arg2 int) (_swig_ret string) + Call_get_first() (_swig_ret string) + Call_get(arg2 int) (_swig_ret string) + String_length(arg2 string) (_swig_ret int) + SetM_strings(arg2 StringVector) + GetM_strings() (_swig_ret StringVector) + Process_text(arg2 string) + Call_process_func() +} + +type SwigcptrStringVector uintptr + +func (p SwigcptrStringVector) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrStringVector) SwigIsStringVector() { +} + +var _wrap_new_StringVector__SWIG_0 unsafe.Pointer + +func _swig_wrap_new_StringVector__SWIG_0() (base SwigcptrStringVector) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_StringVector__SWIG_0, _swig_p) + return +} + +func NewStringVector__SWIG_0() (_swig_ret StringVector) { + return _swig_wrap_new_StringVector__SWIG_0() +} + +var _wrap_new_StringVector__SWIG_1 unsafe.Pointer + +func _swig_wrap_new_StringVector__SWIG_1(base int64) (_ SwigcptrStringVector) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_StringVector__SWIG_1, _swig_p) + return +} + +func NewStringVector__SWIG_1(arg1 int64) (_swig_ret StringVector) { + return _swig_wrap_new_StringVector__SWIG_1(arg1) +} + +func NewStringVector(a ...interface{}) StringVector { + argc := len(a) + if argc == 0 { + return NewStringVector__SWIG_0() + } + if argc == 1 { + return NewStringVector__SWIG_1(a[0].(int64)) + } + panic("No match for overloaded function call") +} + +var _wrap_StringVector_size unsafe.Pointer + +func _swig_wrap_StringVector_size(base SwigcptrStringVector) (_ int64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_StringVector_size, _swig_p) + return +} + +func (arg1 SwigcptrStringVector) Size() (_swig_ret int64) { + return _swig_wrap_StringVector_size(arg1) +} + +var _wrap_StringVector_capacity unsafe.Pointer + +func _swig_wrap_StringVector_capacity(base SwigcptrStringVector) (_ int64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_StringVector_capacity, _swig_p) + return +} + +func (arg1 SwigcptrStringVector) Capacity() (_swig_ret int64) { + return _swig_wrap_StringVector_capacity(arg1) +} + +var _wrap_StringVector_reserve unsafe.Pointer + +func _swig_wrap_StringVector_reserve(base SwigcptrStringVector, _ int64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_StringVector_reserve, _swig_p) + return +} + +func (arg1 SwigcptrStringVector) Reserve(arg2 int64) { + _swig_wrap_StringVector_reserve(arg1, arg2) +} + +var _wrap_StringVector_isEmpty unsafe.Pointer + +func _swig_wrap_StringVector_isEmpty(base SwigcptrStringVector) (_ bool) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_StringVector_isEmpty, _swig_p) + return +} + +func (arg1 SwigcptrStringVector) IsEmpty() (_swig_ret bool) { + return _swig_wrap_StringVector_isEmpty(arg1) +} + +var _wrap_StringVector_clear unsafe.Pointer + +func _swig_wrap_StringVector_clear(base SwigcptrStringVector) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_StringVector_clear, _swig_p) + return +} + +func (arg1 SwigcptrStringVector) Clear() { + _swig_wrap_StringVector_clear(arg1) +} + +var _wrap_StringVector_add unsafe.Pointer + +func _swig_wrap_StringVector_add(base SwigcptrStringVector, _ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_StringVector_add, _swig_p) + return +} + +func (arg1 SwigcptrStringVector) Add(arg2 string) { + _swig_wrap_StringVector_add(arg1, arg2) +} + +var _wrap_StringVector_get unsafe.Pointer + +func _swig_wrap_StringVector_get(base SwigcptrStringVector, _ int) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_StringVector_get, _swig_p) + return +} + +func (arg1 SwigcptrStringVector) Get(arg2 int) (_swig_ret string) { + return _swig_wrap_StringVector_get(arg1, arg2) +} + +var _wrap_StringVector_set unsafe.Pointer + +func _swig_wrap_StringVector_set(base SwigcptrStringVector, _ int, _ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_StringVector_set, _swig_p) + return +} + +func (arg1 SwigcptrStringVector) Set(arg2 int, arg3 string) { + _swig_wrap_StringVector_set(arg1, arg2, arg3) +} + +var _wrap_delete_StringVector unsafe.Pointer + +func _swig_wrap_delete_StringVector(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_StringVector, _swig_p) + return +} + +func DeleteStringVector(arg1 StringVector) { + _swig_wrap_delete_StringVector(arg1.Swigcptr()) +} + +type StringVector interface { + Swigcptr() uintptr + SwigIsStringVector() + Size() (_swig_ret int64) + Capacity() (_swig_ret int64) + Reserve(arg2 int64) + IsEmpty() (_swig_ret bool) + Clear() + Add(arg2 string) + Get(arg2 int) (_swig_ret string) + Set(arg2 int, arg3 string) +} + + +type SwigcptrSwigDirector_A uintptr +type SwigDirector_A interface { + Swigcptr() uintptr; +} +func (p SwigcptrSwigDirector_A) Swigcptr() uintptr { + return uintptr(p) +} + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/director_string_runme b/Examples/test-suite/go/director_string_runme new file mode 100755 index 000000000..ece4678ea Binary files /dev/null and b/Examples/test-suite/go/director_string_runme differ diff --git a/Examples/test-suite/go/director_string_wrap.h b/Examples/test-suite/go/director_string_wrap.h new file mode 100644 index 000000000..73a6e6e5f --- /dev/null +++ b/Examples/test-suite/go/director_string_wrap.h @@ -0,0 +1,49 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../director_string.i + +#ifndef SWIG_director_string_WRAP_H_ +#define SWIG_director_string_WRAP_H_ + +class SwigDirector_A : public A +{ + public: + SwigDirector_A(void *swig_p, std::string const &first); + virtual ~SwigDirector_A(); + std::string const &_swig_upcall_get_first() const { + return A::get_first(); + } + virtual std::string const &get_first() const; + std::string const &_swig_upcall_get(int n) const { + return A::get(n); + } + virtual std::string const &get(int n) const; + std::string const &_swig_upcall_call_get_first() const { + return A::call_get_first(); + } + virtual std::string const &call_get_first() const; + std::string const &_swig_upcall_call_get(int n) const { + return A::call_get(n); + } + virtual std::string const &call_get(int n) const; + int _swig_upcall_string_length(std::string const &s) const { + return A::string_length(s); + } + virtual int string_length(std::string const &s) const; + void _swig_upcall_process_text(char const *text) { + A::process_text(text); + } + virtual void process_text(char const *text); + private: + void *go_val; +}; + +#endif diff --git a/Examples/test-suite/go/director_thread.go b/Examples/test-suite/go/director_thread.go new file mode 100644 index 000000000..13efccf57 --- /dev/null +++ b/Examples/test-suite/go/director_thread.go @@ -0,0 +1,239 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../director_thread.i + +package director_thread + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +var _wrap_MilliSecondSleep unsafe.Pointer + +func _swig_wrap_MilliSecondSleep(base int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_MilliSecondSleep, _swig_p) + return +} + +func MilliSecondSleep(arg1 int) { + _swig_wrap_MilliSecondSleep(arg1) +} + +type _swig_DirectorFoo struct { + SwigcptrFoo + v interface{} +} + +func (p *_swig_DirectorFoo) Swigcptr() uintptr { + return p.SwigcptrFoo.Swigcptr() +} + +func (p *_swig_DirectorFoo) SwigIsFoo() { +} + +func (p *_swig_DirectorFoo) DirectorInterface() interface{} { + return p.v +} + +var _wrap__swig_NewDirectorFooFoo unsafe.Pointer + +func _swig_NewDirectorFooFoo(_swig_director *_swig_DirectorFoo) (_swig_ret SwigcptrFoo) { + _swig_p := uintptr(unsafe.Pointer(&_swig_director)) + _cgo_runtime_cgocall(_wrap__swig_NewDirectorFooFoo, _swig_p) + return +} + +func NewDirectorFoo(v interface{}) Foo { + p := &_swig_DirectorFoo{0, v} + p.SwigcptrFoo = _swig_NewDirectorFooFoo(p) + return p +} + +var _wrap_DeleteDirectorFoo unsafe.Pointer + +func _swig_wrap_DeleteDirectorFoo(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_DeleteDirectorFoo, _swig_p) + return +} + +func DeleteDirectorFoo(arg1 Foo) { + _swig_wrap_DeleteDirectorFoo(arg1.Swigcptr()) +} + +func Swiggo_DeleteDirector_Foo(p *_swig_DirectorFoo) { + p.SwigcptrFoo = 0 +} + +type _swig_DirectorInterfaceFooDo_foo interface { + Do_foo() +} + +var _wrap__swig_DirectorFoo_upcall_Do_foo unsafe.Pointer + +func _swig_wrap__swig_DirectorFoo_upcall_Do_foo(_swig_ptr SwigcptrFoo) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) + _cgo_runtime_cgocall(_wrap__swig_DirectorFoo_upcall_Do_foo, _swig_p) + return +} + +func (swig_p *_swig_DirectorFoo) Do_foo() { + if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceFooDo_foo); swig_ok { + swig_g.Do_foo() + return + } + _swig_wrap__swig_DirectorFoo_upcall_Do_foo(swig_p.SwigcptrFoo) +} + +func DirectorFooDo_foo(p Foo) { + _swig_wrap__swig_DirectorFoo_upcall_Do_foo(p.(*_swig_DirectorFoo).SwigcptrFoo) +} + +func Swig_DirectorFoo_callback_do_foo(p *_swig_DirectorFoo) { + p.Do_foo() +} + +type SwigcptrFoo uintptr + +func (p SwigcptrFoo) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrFoo) SwigIsFoo() { +} + +func (p SwigcptrFoo) DirectorInterface() interface{} { + return nil +} + +var _wrap_Foo_val_set unsafe.Pointer + +func _swig_wrap_Foo_val_set(base SwigcptrFoo, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_val_set, _swig_p) + return +} + +func (arg1 SwigcptrFoo) SetVal(arg2 int) { + _swig_wrap_Foo_val_set(arg1, arg2) +} + +var _wrap_Foo_val_get unsafe.Pointer + +func _swig_wrap_Foo_val_get(base SwigcptrFoo) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_val_get, _swig_p) + return +} + +func (arg1 SwigcptrFoo) GetVal() (_swig_ret int) { + return _swig_wrap_Foo_val_get(arg1) +} + +var _wrap_new_Foo unsafe.Pointer + +func _swig_wrap_new_Foo() (base SwigcptrFoo) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Foo, _swig_p) + return +} + +func NewFoo() (_swig_ret Foo) { + return _swig_wrap_new_Foo() +} + +var _wrap_delete_Foo unsafe.Pointer + +func _swig_wrap_delete_Foo(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Foo, _swig_p) + return +} + +func DeleteFoo(arg1 Foo) { + _swig_wrap_delete_Foo(arg1.Swigcptr()) +} + +var _wrap_Foo_stop unsafe.Pointer + +func _swig_wrap_Foo_stop(base SwigcptrFoo) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_stop, _swig_p) + return +} + +func (arg1 SwigcptrFoo) Stop() { + _swig_wrap_Foo_stop(arg1) +} + +var _wrap_Foo_run unsafe.Pointer + +func _swig_wrap_Foo_run(base SwigcptrFoo) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_run, _swig_p) + return +} + +func (arg1 SwigcptrFoo) Run() { + _swig_wrap_Foo_run(arg1) +} + +var _wrap_Foo_do_foo unsafe.Pointer + +func _swig_wrap_Foo_do_foo(base SwigcptrFoo) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_do_foo, _swig_p) + return +} + +func (arg1 SwigcptrFoo) Do_foo() { + _swig_wrap_Foo_do_foo(arg1) +} + +type Foo interface { + Swigcptr() uintptr + SwigIsFoo() + DirectorInterface() interface{} + SetVal(arg2 int) + GetVal() (_swig_ret int) + Stop() + Run() + Do_foo() +} + + +type SwigcptrSwigDirector_Foo uintptr +type SwigDirector_Foo interface { + Swigcptr() uintptr; +} +func (p SwigcptrSwigDirector_Foo) Swigcptr() uintptr { + return uintptr(p) +} + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/director_thread_wrap.h b/Examples/test-suite/go/director_thread_wrap.h new file mode 100644 index 000000000..14e4d51a7 --- /dev/null +++ b/Examples/test-suite/go/director_thread_wrap.h @@ -0,0 +1,29 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../director_thread.i + +#ifndef SWIG_director_thread_WRAP_H_ +#define SWIG_director_thread_WRAP_H_ + +class SwigDirector_Foo : public Foo +{ + public: + SwigDirector_Foo(void *swig_p); + virtual ~SwigDirector_Foo(); + void _swig_upcall_do_foo() { + Foo::do_foo(); + } + virtual void do_foo(); + private: + void *go_val; +}; + +#endif diff --git a/Examples/test-suite/go/director_unroll.go b/Examples/test-suite/go/director_unroll.go new file mode 100644 index 000000000..bd07ce74f --- /dev/null +++ b/Examples/test-suite/go/director_unroll.go @@ -0,0 +1,290 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../director_unroll.i + +package director_unroll + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type _swig_DirectorFoo struct { + SwigcptrFoo + v interface{} +} + +func (p *_swig_DirectorFoo) Swigcptr() uintptr { + return p.SwigcptrFoo.Swigcptr() +} + +func (p *_swig_DirectorFoo) SwigIsFoo() { +} + +func (p *_swig_DirectorFoo) DirectorInterface() interface{} { + return p.v +} + +var _wrap__swig_NewDirectorFooFoo unsafe.Pointer + +func _swig_NewDirectorFooFoo(_swig_director *_swig_DirectorFoo) (_swig_ret SwigcptrFoo) { + _swig_p := uintptr(unsafe.Pointer(&_swig_director)) + _cgo_runtime_cgocall(_wrap__swig_NewDirectorFooFoo, _swig_p) + return +} + +func NewDirectorFoo(v interface{}) Foo { + p := &_swig_DirectorFoo{0, v} + p.SwigcptrFoo = _swig_NewDirectorFooFoo(p) + return p +} + +var _wrap_DeleteDirectorFoo unsafe.Pointer + +func _swig_wrap_DeleteDirectorFoo(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_DeleteDirectorFoo, _swig_p) + return +} + +func DeleteDirectorFoo(arg1 Foo) { + _swig_wrap_DeleteDirectorFoo(arg1.Swigcptr()) +} + +func Swiggo_DeleteDirector_Foo(p *_swig_DirectorFoo) { + p.SwigcptrFoo = 0 +} + +type _swig_DirectorInterfaceFooPing interface { + Ping() string +} + +var _wrap__swig_DirectorFoo_upcall_Ping unsafe.Pointer + +func _swig_wrap__swig_DirectorFoo_upcall_Ping(_swig_ptr SwigcptrFoo) (_swig_ret string) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) + _cgo_runtime_cgocall(_wrap__swig_DirectorFoo_upcall_Ping, _swig_p) + return +} + +func (swig_p *_swig_DirectorFoo) Ping() string { + if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceFooPing); swig_ok { + return swig_g.Ping() + } + var swig_r string + swig_r = _swig_wrap__swig_DirectorFoo_upcall_Ping(swig_p.SwigcptrFoo) + return swig_r +} + +func DirectorFooPing(p Foo) string { + var swig_r string + swig_r = _swig_wrap__swig_DirectorFoo_upcall_Ping(p.(*_swig_DirectorFoo).SwigcptrFoo) + return swig_r +} + +func Swig_DirectorFoo_callback_ping(p *_swig_DirectorFoo) (swig_result string) { + var swig_r string + swig_r = p.Ping() + return swig_r +} + +type _swig_DirectorInterfaceFooPong interface { + Pong() string +} + +var _wrap__swig_DirectorFoo_upcall_Pong unsafe.Pointer + +func _swig_wrap__swig_DirectorFoo_upcall_Pong(_swig_ptr SwigcptrFoo) (_swig_ret string) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) + _cgo_runtime_cgocall(_wrap__swig_DirectorFoo_upcall_Pong, _swig_p) + return +} + +func (swig_p *_swig_DirectorFoo) Pong() string { + if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceFooPong); swig_ok { + return swig_g.Pong() + } + var swig_r string + swig_r = _swig_wrap__swig_DirectorFoo_upcall_Pong(swig_p.SwigcptrFoo) + return swig_r +} + +func DirectorFooPong(p Foo) string { + var swig_r string + swig_r = _swig_wrap__swig_DirectorFoo_upcall_Pong(p.(*_swig_DirectorFoo).SwigcptrFoo) + return swig_r +} + +func Swig_DirectorFoo_callback_pong(p *_swig_DirectorFoo) (swig_result string) { + var swig_r string + swig_r = p.Pong() + return swig_r +} + +type SwigcptrFoo uintptr + +func (p SwigcptrFoo) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrFoo) SwigIsFoo() { +} + +func (p SwigcptrFoo) DirectorInterface() interface{} { + return nil +} + +var _wrap_delete_Foo unsafe.Pointer + +func _swig_wrap_delete_Foo(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Foo, _swig_p) + return +} + +func DeleteFoo(arg1 Foo) { + _swig_wrap_delete_Foo(arg1.Swigcptr()) +} + +var _wrap_Foo_ping unsafe.Pointer + +func _swig_wrap_Foo_ping(base SwigcptrFoo) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_ping, _swig_p) + return +} + +func (arg1 SwigcptrFoo) Ping() (_swig_ret string) { + return _swig_wrap_Foo_ping(arg1) +} + +var _wrap_Foo_pong unsafe.Pointer + +func _swig_wrap_Foo_pong(base SwigcptrFoo) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_pong, _swig_p) + return +} + +func (arg1 SwigcptrFoo) Pong() (_swig_ret string) { + return _swig_wrap_Foo_pong(arg1) +} + +var _wrap_new_Foo unsafe.Pointer + +func _swig_wrap_new_Foo() (base SwigcptrFoo) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Foo, _swig_p) + return +} + +func NewFoo() (_swig_ret Foo) { + return _swig_wrap_new_Foo() +} + +type Foo interface { + Swigcptr() uintptr + SwigIsFoo() + DirectorInterface() interface{} + Ping() (_swig_ret string) + Pong() (_swig_ret string) +} + +type SwigcptrBar uintptr + +func (p SwigcptrBar) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrBar) SwigIsBar() { +} + +var _wrap_Bar_set unsafe.Pointer + +func _swig_wrap_Bar_set(base SwigcptrBar, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Bar_set, _swig_p) + return +} + +func (arg1 SwigcptrBar) Set(arg2 Foo) { + _swig_wrap_Bar_set(arg1, arg2.Swigcptr()) +} + +var _wrap_Bar_get unsafe.Pointer + +func _swig_wrap_Bar_get(base SwigcptrBar) (_ SwigcptrFoo) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Bar_get, _swig_p) + return +} + +func (arg1 SwigcptrBar) Get() (_swig_ret Foo) { + return _swig_wrap_Bar_get(arg1) +} + +var _wrap_new_Bar unsafe.Pointer + +func _swig_wrap_new_Bar() (base SwigcptrBar) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Bar, _swig_p) + return +} + +func NewBar() (_swig_ret Bar) { + return _swig_wrap_new_Bar() +} + +var _wrap_delete_Bar unsafe.Pointer + +func _swig_wrap_delete_Bar(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Bar, _swig_p) + return +} + +func DeleteBar(arg1 Bar) { + _swig_wrap_delete_Bar(arg1.Swigcptr()) +} + +type Bar interface { + Swigcptr() uintptr + SwigIsBar() + Set(arg2 Foo) + Get() (_swig_ret Foo) +} + + +type SwigcptrSwigDirector_Foo uintptr +type SwigDirector_Foo interface { + Swigcptr() uintptr; +} +func (p SwigcptrSwigDirector_Foo) Swigcptr() uintptr { + return uintptr(p) +} + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/director_unroll_runme b/Examples/test-suite/go/director_unroll_runme new file mode 100755 index 000000000..e58b74644 Binary files /dev/null and b/Examples/test-suite/go/director_unroll_runme differ diff --git a/Examples/test-suite/go/director_unroll_wrap.h b/Examples/test-suite/go/director_unroll_wrap.h new file mode 100644 index 000000000..55273110b --- /dev/null +++ b/Examples/test-suite/go/director_unroll_wrap.h @@ -0,0 +1,33 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../director_unroll.i + +#ifndef SWIG_director_unroll_WRAP_H_ +#define SWIG_director_unroll_WRAP_H_ + +class SwigDirector_Foo : public Foo +{ + public: + SwigDirector_Foo(void *swig_p); + virtual ~SwigDirector_Foo(); + std::string _swig_upcall_ping() { + return Foo::ping(); + } + virtual std::string ping(); + std::string _swig_upcall_pong() { + return Foo::pong(); + } + virtual std::string pong(); + private: + void *go_val; +}; + +#endif diff --git a/Examples/test-suite/go/director_using.go b/Examples/test-suite/go/director_using.go new file mode 100644 index 000000000..4c4dec077 --- /dev/null +++ b/Examples/test-suite/go/director_using.go @@ -0,0 +1,969 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../director_using.i + +package director_using + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type _swig_DirectorFoo_int struct { + SwigcptrFoo_int + v interface{} +} + +func (p *_swig_DirectorFoo_int) Swigcptr() uintptr { + return p.SwigcptrFoo_int.Swigcptr() +} + +func (p *_swig_DirectorFoo_int) SwigIsFoo_int() { +} + +func (p *_swig_DirectorFoo_int) DirectorInterface() interface{} { + return p.v +} + +var _wrap__swig_NewDirectorFoo_intFoo_int unsafe.Pointer + +func _swig_NewDirectorFoo_intFoo_int(_swig_director *_swig_DirectorFoo_int) (_swig_ret SwigcptrFoo_int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_director)) + _cgo_runtime_cgocall(_wrap__swig_NewDirectorFoo_intFoo_int, _swig_p) + return +} + +func NewDirectorFoo_int(v interface{}) Foo_int { + p := &_swig_DirectorFoo_int{0, v} + p.SwigcptrFoo_int = _swig_NewDirectorFoo_intFoo_int(p) + return p +} + +var _wrap_DeleteDirectorFoo_int unsafe.Pointer + +func _swig_wrap_DeleteDirectorFoo_int(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_DeleteDirectorFoo_int, _swig_p) + return +} + +func DeleteDirectorFoo_int(arg1 Foo_int) { + _swig_wrap_DeleteDirectorFoo_int(arg1.Swigcptr()) +} + +func Swiggo_DeleteDirector_Foo_int(p *_swig_DirectorFoo_int) { + p.SwigcptrFoo_int = 0 +} + +type _swig_DirectorInterfaceFoo_intDo_advance interface { + Do_advance() string +} + +func (swig_p *_swig_DirectorFoo_int) Do_advance() string { + if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceFoo_intDo_advance); swig_ok { + return swig_g.Do_advance() + } + panic("call to pure virtual method") +} + +func Swig_DirectorFoo_int_callback_do_advance(p *_swig_DirectorFoo_int) (swig_result string) { + var swig_r string + swig_r = p.Do_advance() + return swig_r +} + +type _swig_DirectorInterfaceFoo_intDo_step interface { + Do_step() string +} + +func (swig_p *_swig_DirectorFoo_int) Do_step() string { + if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceFoo_intDo_step); swig_ok { + return swig_g.Do_step() + } + panic("call to pure virtual method") +} + +func Swig_DirectorFoo_int_callback_do_step(p *_swig_DirectorFoo_int) (swig_result string) { + var swig_r string + swig_r = p.Do_step() + return swig_r +} + +type SwigcptrFoo_int uintptr + +func (p SwigcptrFoo_int) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrFoo_int) SwigIsFoo_int() { +} + +func (p SwigcptrFoo_int) DirectorInterface() interface{} { + return nil +} + +var _wrap_delete_Foo_int unsafe.Pointer + +func _swig_wrap_delete_Foo_int(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Foo_int, _swig_p) + return +} + +func DeleteFoo_int(arg1 Foo_int) { + _swig_wrap_delete_Foo_int(arg1.Swigcptr()) +} + +var _wrap_Foo_int_advance unsafe.Pointer + +func _swig_wrap_Foo_int_advance(base SwigcptrFoo_int) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_int_advance, _swig_p) + return +} + +func (arg1 SwigcptrFoo_int) Advance() (_swig_ret string) { + return _swig_wrap_Foo_int_advance(arg1) +} + +var _wrap_new_Foo_int unsafe.Pointer + +func _swig_wrap_new_Foo_int() (base SwigcptrFoo_int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Foo_int, _swig_p) + return +} + +func NewFoo_int() (_swig_ret Foo_int) { + return _swig_wrap_new_Foo_int() +} + +type Foo_int interface { + Swigcptr() uintptr + SwigIsFoo_int() + DirectorInterface() interface{} + Advance() (_swig_ret string) +} + +type _swig_DirectorBar struct { + SwigcptrBar + v interface{} +} + +func (p *_swig_DirectorBar) Swigcptr() uintptr { + return p.SwigcptrBar.Swigcptr() +} + +func (p *_swig_DirectorBar) SwigIsBar() { +} + +func (p *_swig_DirectorBar) DirectorInterface() interface{} { + return p.v +} + +var _wrap__swig_NewDirectorBarBar unsafe.Pointer + +func _swig_NewDirectorBarBar(_swig_director *_swig_DirectorBar) (_swig_ret SwigcptrBar) { + _swig_p := uintptr(unsafe.Pointer(&_swig_director)) + _cgo_runtime_cgocall(_wrap__swig_NewDirectorBarBar, _swig_p) + return +} + +func NewDirectorBar(v interface{}) Bar { + p := &_swig_DirectorBar{0, v} + p.SwigcptrBar = _swig_NewDirectorBarBar(p) + return p +} + +var _wrap_DeleteDirectorBar unsafe.Pointer + +func _swig_wrap_DeleteDirectorBar(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_DeleteDirectorBar, _swig_p) + return +} + +func DeleteDirectorBar(arg1 Bar) { + _swig_wrap_DeleteDirectorBar(arg1.Swigcptr()) +} + +func Swiggo_DeleteDirector_Bar(p *_swig_DirectorBar) { + p.SwigcptrBar = 0 +} + +type _swig_DirectorInterfaceBarDo_advance interface { + Do_advance() string +} + +var _wrap__swig_DirectorBar_upcall_Do_advance unsafe.Pointer + +func _swig_wrap__swig_DirectorBar_upcall_Do_advance(_swig_ptr SwigcptrBar) (_swig_ret string) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) + _cgo_runtime_cgocall(_wrap__swig_DirectorBar_upcall_Do_advance, _swig_p) + return +} + +func (swig_p *_swig_DirectorBar) Do_advance() string { + if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceBarDo_advance); swig_ok { + return swig_g.Do_advance() + } + var swig_r string + swig_r = _swig_wrap__swig_DirectorBar_upcall_Do_advance(swig_p.SwigcptrBar) + return swig_r +} + +func DirectorBarDo_advance(p Bar) string { + var swig_r string + swig_r = _swig_wrap__swig_DirectorBar_upcall_Do_advance(p.(*_swig_DirectorBar).SwigcptrBar) + return swig_r +} + +func Swig_DirectorBar_callback_do_advance(p *_swig_DirectorBar) (swig_result string) { + var swig_r string + swig_r = p.Do_advance() + return swig_r +} + +type _swig_DirectorInterfaceBarDo_step interface { + Do_step() string +} + +func (swig_p *_swig_DirectorBar) Do_step() string { + if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceBarDo_step); swig_ok { + return swig_g.Do_step() + } + panic("call to pure virtual method") +} + +func Swig_DirectorBar_callback_do_step(p *_swig_DirectorBar) (swig_result string) { + var swig_r string + swig_r = p.Do_step() + return swig_r +} + +type SwigcptrBar uintptr + +func (p SwigcptrBar) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrBar) SwigIsBar() { +} + +func (p SwigcptrBar) DirectorInterface() interface{} { + return nil +} + +var _wrap_Bar_step unsafe.Pointer + +func _swig_wrap_Bar_step(base SwigcptrBar) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Bar_step, _swig_p) + return +} + +func (arg1 SwigcptrBar) Step() (_swig_ret string) { + return _swig_wrap_Bar_step(arg1) +} + +var _wrap_Bar_do_step unsafe.Pointer + +func _swig_wrap_Bar_do_step(base SwigcptrBar) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Bar_do_step, _swig_p) + return +} + +func (arg1 SwigcptrBar) Do_step() (_swig_ret string) { + return _swig_wrap_Bar_do_step(arg1) +} + +var _wrap_new_Bar unsafe.Pointer + +func _swig_wrap_new_Bar() (base SwigcptrBar) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Bar, _swig_p) + return +} + +func NewBar() (_swig_ret Bar) { + return _swig_wrap_new_Bar() +} + +var _wrap_delete_Bar unsafe.Pointer + +func _swig_wrap_delete_Bar(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Bar, _swig_p) + return +} + +func DeleteBar(arg1 Bar) { + _swig_wrap_delete_Bar(arg1.Swigcptr()) +} + +var _wrap_Bar_advance unsafe.Pointer + +func _swig_wrap_Bar_advance(base SwigcptrBar) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Bar_advance, _swig_p) + return +} + +func (_swig_base SwigcptrBar) Advance() (_swig_ret string) { + return _swig_wrap_Bar_advance(_swig_base) +} + +func (p SwigcptrBar) SwigIsFoo_int() { +} + +func (p SwigcptrBar) SwigGetFoo_int() Foo_int { + return SwigcptrFoo_int(p.Swigcptr()) +} + +type Bar interface { + Swigcptr() uintptr + SwigIsBar() + DirectorInterface() interface{} + Step() (_swig_ret string) + Do_step() (_swig_ret string) + Advance() (_swig_ret string) + SwigIsFoo_int() + SwigGetFoo_int() Foo_int +} + +type _swig_DirectorFooBar_int struct { + SwigcptrFooBar_int + v interface{} +} + +func (p *_swig_DirectorFooBar_int) Swigcptr() uintptr { + return p.SwigcptrFooBar_int.Swigcptr() +} + +func (p *_swig_DirectorFooBar_int) SwigIsFooBar_int() { +} + +func (p *_swig_DirectorFooBar_int) DirectorInterface() interface{} { + return p.v +} + +var _wrap__swig_NewDirectorFooBar_intFooBar_int unsafe.Pointer + +func _swig_NewDirectorFooBar_intFooBar_int(_swig_director *_swig_DirectorFooBar_int) (_swig_ret SwigcptrFooBar_int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_director)) + _cgo_runtime_cgocall(_wrap__swig_NewDirectorFooBar_intFooBar_int, _swig_p) + return +} + +func NewDirectorFooBar_int(v interface{}) FooBar_int { + p := &_swig_DirectorFooBar_int{0, v} + p.SwigcptrFooBar_int = _swig_NewDirectorFooBar_intFooBar_int(p) + return p +} + +var _wrap_DeleteDirectorFooBar_int unsafe.Pointer + +func _swig_wrap_DeleteDirectorFooBar_int(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_DeleteDirectorFooBar_int, _swig_p) + return +} + +func DeleteDirectorFooBar_int(arg1 FooBar_int) { + _swig_wrap_DeleteDirectorFooBar_int(arg1.Swigcptr()) +} + +func Swiggo_DeleteDirector_FooBar_int(p *_swig_DirectorFooBar_int) { + p.SwigcptrFooBar_int = 0 +} + +type _swig_DirectorInterfaceFooBar_intDo_advance interface { + Do_advance() string +} + +var _wrap__swig_DirectorFooBar_int_upcall_Do_advance unsafe.Pointer + +func _swig_wrap__swig_DirectorFooBar_int_upcall_Do_advance(_swig_ptr SwigcptrFooBar_int) (_swig_ret string) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) + _cgo_runtime_cgocall(_wrap__swig_DirectorFooBar_int_upcall_Do_advance, _swig_p) + return +} + +func (swig_p *_swig_DirectorFooBar_int) Do_advance() string { + if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceFooBar_intDo_advance); swig_ok { + return swig_g.Do_advance() + } + var swig_r string + swig_r = _swig_wrap__swig_DirectorFooBar_int_upcall_Do_advance(swig_p.SwigcptrFooBar_int) + return swig_r +} + +func DirectorFooBar_intDo_advance(p FooBar_int) string { + var swig_r string + swig_r = _swig_wrap__swig_DirectorFooBar_int_upcall_Do_advance(p.(*_swig_DirectorFooBar_int).SwigcptrFooBar_int) + return swig_r +} + +func Swig_DirectorFooBar_int_callback_do_advance(p *_swig_DirectorFooBar_int) (swig_result string) { + var swig_r string + swig_r = p.Do_advance() + return swig_r +} + +type _swig_DirectorInterfaceFooBar_intDo_step interface { + Do_step() string +} + +func (swig_p *_swig_DirectorFooBar_int) Do_step() string { + if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceFooBar_intDo_step); swig_ok { + return swig_g.Do_step() + } + panic("call to pure virtual method") +} + +func Swig_DirectorFooBar_int_callback_do_step(p *_swig_DirectorFooBar_int) (swig_result string) { + var swig_r string + swig_r = p.Do_step() + return swig_r +} + +type _swig_DirectorInterfaceFooBar_intGet_value interface { + Get_value() int +} + +func (swig_p *_swig_DirectorFooBar_int) Get_value() int { + if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceFooBar_intGet_value); swig_ok { + return swig_g.Get_value() + } + panic("call to pure virtual method") +} + +func Swig_DirectorFooBar_int_callback_get_value(p *_swig_DirectorFooBar_int) (swig_result int) { + var swig_r int + swig_r = p.Get_value() + return swig_r +} + +type SwigcptrFooBar_int uintptr + +func (p SwigcptrFooBar_int) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrFooBar_int) SwigIsFooBar_int() { +} + +func (p SwigcptrFooBar_int) DirectorInterface() interface{} { + return nil +} + +var _wrap_FooBar_int_get_value unsafe.Pointer + +func _swig_wrap_FooBar_int_get_value(base SwigcptrFooBar_int) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_FooBar_int_get_value, _swig_p) + return +} + +func (arg1 SwigcptrFooBar_int) Get_value() (_swig_ret int) { + return _swig_wrap_FooBar_int_get_value(arg1) +} + +var _wrap_FooBar_int_do_advance unsafe.Pointer + +func _swig_wrap_FooBar_int_do_advance(base SwigcptrFooBar_int) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_FooBar_int_do_advance, _swig_p) + return +} + +func (arg1 SwigcptrFooBar_int) Do_advance() (_swig_ret string) { + return _swig_wrap_FooBar_int_do_advance(arg1) +} + +var _wrap_new_FooBar_int unsafe.Pointer + +func _swig_wrap_new_FooBar_int() (base SwigcptrFooBar_int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_FooBar_int, _swig_p) + return +} + +func NewFooBar_int() (_swig_ret FooBar_int) { + return _swig_wrap_new_FooBar_int() +} + +var _wrap_delete_FooBar_int unsafe.Pointer + +func _swig_wrap_delete_FooBar_int(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_FooBar_int, _swig_p) + return +} + +func DeleteFooBar_int(arg1 FooBar_int) { + _swig_wrap_delete_FooBar_int(arg1.Swigcptr()) +} + +var _wrap_FooBar_int_step unsafe.Pointer + +func _swig_wrap_FooBar_int_step(base SwigcptrFooBar_int) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_FooBar_int_step, _swig_p) + return +} + +func (_swig_base SwigcptrFooBar_int) Step() (_swig_ret string) { + return _swig_wrap_FooBar_int_step(_swig_base) +} + +var _wrap_FooBar_int_advance unsafe.Pointer + +func _swig_wrap_FooBar_int_advance(base SwigcptrFooBar_int) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_FooBar_int_advance, _swig_p) + return +} + +func (_swig_base SwigcptrFooBar_int) Advance() (_swig_ret string) { + return _swig_wrap_FooBar_int_advance(_swig_base) +} + +func (p SwigcptrFooBar_int) SwigIsBar() { +} + +func (p SwigcptrFooBar_int) SwigGetBar() Bar { + return SwigcptrBar(p.Swigcptr()) +} + +func (p SwigcptrFooBar_int) SwigIsFoo_int() { +} + +func (p SwigcptrFooBar_int) SwigGetFoo_int() Foo_int { + return SwigcptrFoo_int(p.Swigcptr()) +} + +type FooBar_int interface { + Swigcptr() uintptr + SwigIsFooBar_int() + DirectorInterface() interface{} + Get_value() (_swig_ret int) + Do_advance() (_swig_ret string) + Step() (_swig_ret string) + Advance() (_swig_ret string) + SwigIsBar() + SwigGetBar() Bar + SwigIsFoo_int() + SwigGetFoo_int() Foo_int +} + +type _swig_DirectorSomeBase struct { + SwigcptrSomeBase + v interface{} +} + +func (p *_swig_DirectorSomeBase) Swigcptr() uintptr { + return p.SwigcptrSomeBase.Swigcptr() +} + +func (p *_swig_DirectorSomeBase) SwigIsSomeBase() { +} + +func (p *_swig_DirectorSomeBase) DirectorInterface() interface{} { + return p.v +} + +var _wrap__swig_NewDirectorSomeBaseSomeBase unsafe.Pointer + +func _swig_NewDirectorSomeBaseSomeBase(_swig_director *_swig_DirectorSomeBase) (_swig_ret SwigcptrSomeBase) { + _swig_p := uintptr(unsafe.Pointer(&_swig_director)) + _cgo_runtime_cgocall(_wrap__swig_NewDirectorSomeBaseSomeBase, _swig_p) + return +} + +func NewDirectorSomeBase(v interface{}) SomeBase { + p := &_swig_DirectorSomeBase{0, v} + p.SwigcptrSomeBase = _swig_NewDirectorSomeBaseSomeBase(p) + return p +} + +var _wrap_DeleteDirectorSomeBase unsafe.Pointer + +func _swig_wrap_DeleteDirectorSomeBase(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_DeleteDirectorSomeBase, _swig_p) + return +} + +func DeleteDirectorSomeBase(arg1 SomeBase) { + _swig_wrap_DeleteDirectorSomeBase(arg1.Swigcptr()) +} + +func Swiggo_DeleteDirector_SomeBase(p *_swig_DirectorSomeBase) { + p.SwigcptrSomeBase = 0 +} + +type _swig_DirectorInterfaceSomeBaseMethod1 interface { + Method1() +} + +var _wrap__swig_DirectorSomeBase_upcall_Method1 unsafe.Pointer + +func _swig_wrap__swig_DirectorSomeBase_upcall_Method1(_swig_ptr SwigcptrSomeBase) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) + _cgo_runtime_cgocall(_wrap__swig_DirectorSomeBase_upcall_Method1, _swig_p) + return +} + +func (swig_p *_swig_DirectorSomeBase) Method1() { + if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceSomeBaseMethod1); swig_ok { + swig_g.Method1() + return + } + _swig_wrap__swig_DirectorSomeBase_upcall_Method1(swig_p.SwigcptrSomeBase) +} + +func DirectorSomeBaseMethod1(p SomeBase) { + _swig_wrap__swig_DirectorSomeBase_upcall_Method1(p.(*_swig_DirectorSomeBase).SwigcptrSomeBase) +} + +func Swig_DirectorSomeBase_callback_method1(p *_swig_DirectorSomeBase) { + p.Method1() +} + +type _swig_DirectorInterfaceSomeBaseMethod2 interface { + Method2() +} + +var _wrap__swig_DirectorSomeBase_upcall_Method2 unsafe.Pointer + +func _swig_wrap__swig_DirectorSomeBase_upcall_Method2(_swig_ptr SwigcptrSomeBase) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) + _cgo_runtime_cgocall(_wrap__swig_DirectorSomeBase_upcall_Method2, _swig_p) + return +} + +func (swig_p *_swig_DirectorSomeBase) Method2() { + if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceSomeBaseMethod2); swig_ok { + swig_g.Method2() + return + } + _swig_wrap__swig_DirectorSomeBase_upcall_Method2(swig_p.SwigcptrSomeBase) +} + +func DirectorSomeBaseMethod2(p SomeBase) { + _swig_wrap__swig_DirectorSomeBase_upcall_Method2(p.(*_swig_DirectorSomeBase).SwigcptrSomeBase) +} + +func Swig_DirectorSomeBase_callback_method2(p *_swig_DirectorSomeBase) { + p.Method2() +} + +type SwigcptrSomeBase uintptr + +func (p SwigcptrSomeBase) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrSomeBase) SwigIsSomeBase() { +} + +func (p SwigcptrSomeBase) DirectorInterface() interface{} { + return nil +} + +var _wrap_delete_SomeBase unsafe.Pointer + +func _swig_wrap_delete_SomeBase(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_SomeBase, _swig_p) + return +} + +func DeleteSomeBase(arg1 SomeBase) { + _swig_wrap_delete_SomeBase(arg1.Swigcptr()) +} + +var _wrap_SomeBase_method1 unsafe.Pointer + +func _swig_wrap_SomeBase_method1(base SwigcptrSomeBase) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_SomeBase_method1, _swig_p) + return +} + +func (arg1 SwigcptrSomeBase) Method1() { + _swig_wrap_SomeBase_method1(arg1) +} + +var _wrap_SomeBase_method2 unsafe.Pointer + +func _swig_wrap_SomeBase_method2(base SwigcptrSomeBase) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_SomeBase_method2, _swig_p) + return +} + +func (arg1 SwigcptrSomeBase) Method2() { + _swig_wrap_SomeBase_method2(arg1) +} + +var _wrap_new_SomeBase unsafe.Pointer + +func _swig_wrap_new_SomeBase() (base SwigcptrSomeBase) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_SomeBase, _swig_p) + return +} + +func NewSomeBase() (_swig_ret SomeBase) { + return _swig_wrap_new_SomeBase() +} + +type SomeBase interface { + Swigcptr() uintptr + SwigIsSomeBase() + DirectorInterface() interface{} + Method1() + Method2() +} + +type _swig_DirectorPrivateDerived struct { + SwigcptrPrivateDerived + v interface{} +} + +func (p *_swig_DirectorPrivateDerived) Swigcptr() uintptr { + return p.SwigcptrPrivateDerived.Swigcptr() +} + +func (p *_swig_DirectorPrivateDerived) SwigIsPrivateDerived() { +} + +func (p *_swig_DirectorPrivateDerived) DirectorInterface() interface{} { + return p.v +} + +var _wrap__swig_NewDirectorPrivateDerivedPrivateDerived unsafe.Pointer + +func _swig_NewDirectorPrivateDerivedPrivateDerived(_swig_director *_swig_DirectorPrivateDerived) (_swig_ret SwigcptrPrivateDerived) { + _swig_p := uintptr(unsafe.Pointer(&_swig_director)) + _cgo_runtime_cgocall(_wrap__swig_NewDirectorPrivateDerivedPrivateDerived, _swig_p) + return +} + +func NewDirectorPrivateDerived(v interface{}) PrivateDerived { + p := &_swig_DirectorPrivateDerived{0, v} + p.SwigcptrPrivateDerived = _swig_NewDirectorPrivateDerivedPrivateDerived(p) + return p +} + +var _wrap_DeleteDirectorPrivateDerived unsafe.Pointer + +func _swig_wrap_DeleteDirectorPrivateDerived(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_DeleteDirectorPrivateDerived, _swig_p) + return +} + +func DeleteDirectorPrivateDerived(arg1 PrivateDerived) { + _swig_wrap_DeleteDirectorPrivateDerived(arg1.Swigcptr()) +} + +func Swiggo_DeleteDirector_PrivateDerived(p *_swig_DirectorPrivateDerived) { + p.SwigcptrPrivateDerived = 0 +} + +type _swig_DirectorInterfacePrivateDerivedMethod1 interface { + Method1() +} + +var _wrap__swig_DirectorPrivateDerived_upcall_Method1 unsafe.Pointer + +func _swig_wrap__swig_DirectorPrivateDerived_upcall_Method1(_swig_ptr SwigcptrPrivateDerived) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) + _cgo_runtime_cgocall(_wrap__swig_DirectorPrivateDerived_upcall_Method1, _swig_p) + return +} + +func (swig_p *_swig_DirectorPrivateDerived) Method1() { + if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfacePrivateDerivedMethod1); swig_ok { + swig_g.Method1() + return + } + _swig_wrap__swig_DirectorPrivateDerived_upcall_Method1(swig_p.SwigcptrPrivateDerived) +} + +func DirectorPrivateDerivedMethod1(p PrivateDerived) { + _swig_wrap__swig_DirectorPrivateDerived_upcall_Method1(p.(*_swig_DirectorPrivateDerived).SwigcptrPrivateDerived) +} + +func Swig_DirectorPrivateDerived_callback_method1(p *_swig_DirectorPrivateDerived) { + p.Method1() +} + +type _swig_DirectorInterfacePrivateDerivedMethod2 interface { + Method2() +} + +var _wrap__swig_DirectorPrivateDerived_upcall_Method2 unsafe.Pointer + +func _swig_wrap__swig_DirectorPrivateDerived_upcall_Method2(_swig_ptr SwigcptrPrivateDerived) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) + _cgo_runtime_cgocall(_wrap__swig_DirectorPrivateDerived_upcall_Method2, _swig_p) + return +} + +func (swig_p *_swig_DirectorPrivateDerived) Method2() { + if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfacePrivateDerivedMethod2); swig_ok { + swig_g.Method2() + return + } + _swig_wrap__swig_DirectorPrivateDerived_upcall_Method2(swig_p.SwigcptrPrivateDerived) +} + +func DirectorPrivateDerivedMethod2(p PrivateDerived) { + _swig_wrap__swig_DirectorPrivateDerived_upcall_Method2(p.(*_swig_DirectorPrivateDerived).SwigcptrPrivateDerived) +} + +func Swig_DirectorPrivateDerived_callback_method2(p *_swig_DirectorPrivateDerived) { + p.Method2() +} + +type SwigcptrPrivateDerived uintptr + +func (p SwigcptrPrivateDerived) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrPrivateDerived) SwigIsPrivateDerived() { +} + +func (p SwigcptrPrivateDerived) DirectorInterface() interface{} { + return nil +} + +var _wrap_new_PrivateDerived unsafe.Pointer + +func _swig_wrap_new_PrivateDerived() (base SwigcptrPrivateDerived) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_PrivateDerived, _swig_p) + return +} + +func NewPrivateDerived() (_swig_ret PrivateDerived) { + return _swig_wrap_new_PrivateDerived() +} + +var _wrap_delete_PrivateDerived unsafe.Pointer + +func _swig_wrap_delete_PrivateDerived(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_PrivateDerived, _swig_p) + return +} + +func DeletePrivateDerived(arg1 PrivateDerived) { + _swig_wrap_delete_PrivateDerived(arg1.Swigcptr()) +} + +var _wrap_PrivateDerived_method1 unsafe.Pointer + +func _swig_wrap_PrivateDerived_method1(base SwigcptrPrivateDerived) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_PrivateDerived_method1, _swig_p) + return +} + +func (_swig_base SwigcptrPrivateDerived) Method1() { + _swig_wrap_PrivateDerived_method1(_swig_base) +} + +var _wrap_PrivateDerived_method2 unsafe.Pointer + +func _swig_wrap_PrivateDerived_method2(base SwigcptrPrivateDerived) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_PrivateDerived_method2, _swig_p) + return +} + +func (_swig_base SwigcptrPrivateDerived) Method2() { + _swig_wrap_PrivateDerived_method2(_swig_base) +} + +func (p SwigcptrPrivateDerived) SwigIsSomeBase() { +} + +func (p SwigcptrPrivateDerived) SwigGetSomeBase() SomeBase { + return SwigcptrSomeBase(p.Swigcptr()) +} + +type PrivateDerived interface { + Swigcptr() uintptr + SwigIsPrivateDerived() + DirectorInterface() interface{} + Method1() + Method2() + SwigIsSomeBase() + SwigGetSomeBase() SomeBase +} + + +type SwigcptrSwigDirector_PrivateDerived uintptr +type SwigDirector_PrivateDerived interface { + Swigcptr() uintptr; +} +func (p SwigcptrSwigDirector_PrivateDerived) Swigcptr() uintptr { + return uintptr(p) +} + +type SwigcptrSwigDirector_FooBar_int uintptr +type SwigDirector_FooBar_int interface { + Swigcptr() uintptr; +} +func (p SwigcptrSwigDirector_FooBar_int) Swigcptr() uintptr { + return uintptr(p) +} + +type SwigcptrSwigDirector_Bar uintptr +type SwigDirector_Bar interface { + Swigcptr() uintptr; +} +func (p SwigcptrSwigDirector_Bar) Swigcptr() uintptr { + return uintptr(p) +} + +type SwigcptrSwigDirector_SomeBase uintptr +type SwigDirector_SomeBase interface { + Swigcptr() uintptr; +} +func (p SwigcptrSwigDirector_SomeBase) Swigcptr() uintptr { + return uintptr(p) +} + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/director_using_wrap.h b/Examples/test-suite/go/director_using_wrap.h new file mode 100644 index 000000000..42c9c2ba4 --- /dev/null +++ b/Examples/test-suite/go/director_using_wrap.h @@ -0,0 +1,90 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../director_using.i + +#ifndef SWIG_director_using_WRAP_H_ +#define SWIG_director_using_WRAP_H_ + +class SwigDirector_Foo_int : public Foo< int > +{ + public: + SwigDirector_Foo_int(void *swig_p); + virtual ~SwigDirector_Foo_int(); + virtual std::string do_advance(); + virtual std::string do_step() const; + private: + void *go_val; +}; + +class SwigDirector_Bar : public Bar +{ + public: + SwigDirector_Bar(void *swig_p); + virtual ~SwigDirector_Bar(); + std::string _swig_upcall_do_advance() { + return Bar::do_advance(); + } + virtual std::string do_advance(); + virtual std::string do_step() const; + private: + void *go_val; +}; + +class SwigDirector_FooBar_int : public FooBar< int > +{ + public: + SwigDirector_FooBar_int(void *swig_p); + virtual ~SwigDirector_FooBar_int(); + std::string _swig_upcall_do_advance() { + return FooBar< int >::do_advance(); + } + virtual std::string do_advance(); + virtual std::string do_step() const; + virtual int get_value() const; + private: + void *go_val; +}; + +class SwigDirector_SomeBase : public SomeBase +{ + public: + SwigDirector_SomeBase(void *swig_p); + virtual ~SwigDirector_SomeBase(); + void _swig_upcall_method1() { + SomeBase::method1(); + } + virtual void method1(); + void _swig_upcall_method2() { + SomeBase::method2(); + } + virtual void method2(); + private: + void *go_val; +}; + +class SwigDirector_PrivateDerived : public PrivateDerived +{ + public: + SwigDirector_PrivateDerived(void *swig_p); + virtual ~SwigDirector_PrivateDerived(); + void _swig_upcall_method1() { + SomeBase::method1(); + } + virtual void method1(); + void _swig_upcall_method2() { + SomeBase::method2(); + } + virtual void method2(); + private: + void *go_val; +}; + +#endif diff --git a/Examples/test-suite/go/director_wombat.go b/Examples/test-suite/go/director_wombat.go new file mode 100644 index 000000000..879c11211 --- /dev/null +++ b/Examples/test-suite/go/director_wombat.go @@ -0,0 +1,528 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../director_wombat.i + +package director_wombat + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type _swig_DirectorBar struct { + SwigcptrBar + v interface{} +} + +func (p *_swig_DirectorBar) Swigcptr() uintptr { + return p.SwigcptrBar.Swigcptr() +} + +func (p *_swig_DirectorBar) SwigIsBar() { +} + +func (p *_swig_DirectorBar) DirectorInterface() interface{} { + return p.v +} + +var _wrap__swig_NewDirectorBarBar unsafe.Pointer + +func _swig_NewDirectorBarBar(_swig_director *_swig_DirectorBar) (_swig_ret SwigcptrBar) { + _swig_p := uintptr(unsafe.Pointer(&_swig_director)) + _cgo_runtime_cgocall(_wrap__swig_NewDirectorBarBar, _swig_p) + return +} + +func NewDirectorBar(v interface{}) Bar { + p := &_swig_DirectorBar{0, v} + p.SwigcptrBar = _swig_NewDirectorBarBar(p) + return p +} + +var _wrap_DeleteDirectorBar unsafe.Pointer + +func _swig_wrap_DeleteDirectorBar(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_DeleteDirectorBar, _swig_p) + return +} + +func DeleteDirectorBar(arg1 Bar) { + _swig_wrap_DeleteDirectorBar(arg1.Swigcptr()) +} + +func Swiggo_DeleteDirector_Bar(p *_swig_DirectorBar) { + p.SwigcptrBar = 0 +} + +type _swig_DirectorInterfaceBarMeth interface { + Meth() Foo_integers +} + +var _wrap__swig_DirectorBar_upcall_Meth unsafe.Pointer + +func _swig_wrap__swig_DirectorBar_upcall_Meth(_swig_ptr SwigcptrBar) (_swig_ret SwigcptrFoo_integers) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) + _cgo_runtime_cgocall(_wrap__swig_DirectorBar_upcall_Meth, _swig_p) + return +} + +func (swig_p *_swig_DirectorBar) Meth() Foo_integers { + if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceBarMeth); swig_ok { + return swig_g.Meth() + } + var swig_r Foo_integers + swig_r = _swig_wrap__swig_DirectorBar_upcall_Meth(swig_p.SwigcptrBar) + return swig_r +} + +func DirectorBarMeth(p Bar) Foo_integers { + var swig_r Foo_integers + swig_r = _swig_wrap__swig_DirectorBar_upcall_Meth(p.(*_swig_DirectorBar).SwigcptrBar) + return swig_r +} + +func Swig_DirectorBar_callback_meth(p *_swig_DirectorBar) (swig_result SwigcptrFoo_integers) { + var swig_r SwigcptrFoo_integers + swig_r = SwigcptrFoo_integers(p.Meth().Swigcptr()) + return swig_r +} + +type _swig_DirectorInterfaceBarFoo_meth_ref interface { + Foo_meth_ref(Foo_integers, int) +} + +var _wrap__swig_DirectorBar_upcall_Foo_meth_ref unsafe.Pointer + +func _swig_wrap__swig_DirectorBar_upcall_Foo_meth_ref(_swig_ptr SwigcptrBar, _ uintptr, _ int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) + _cgo_runtime_cgocall(_wrap__swig_DirectorBar_upcall_Foo_meth_ref, _swig_p) + return +} + +func (swig_p *_swig_DirectorBar) Foo_meth_ref(arg0 Foo_integers, arg1 int) { + if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceBarFoo_meth_ref); swig_ok { + swig_g.Foo_meth_ref(arg0, arg1) + return + } + _swig_wrap__swig_DirectorBar_upcall_Foo_meth_ref(swig_p.SwigcptrBar, arg0.Swigcptr(), arg1) +} + +func DirectorBarFoo_meth_ref(p Bar, arg2 Foo_integers, arg3 int) { + _swig_wrap__swig_DirectorBar_upcall_Foo_meth_ref(p.(*_swig_DirectorBar).SwigcptrBar, arg2.Swigcptr(), arg3) +} + +func Swig_DirectorBar_callback_foo_meth_ref(p *_swig_DirectorBar, arg2 uintptr, arg3 int) { + p.Foo_meth_ref(SwigcptrFoo_integers(arg2), arg3) +} + +type _swig_DirectorInterfaceBarFoo_meth_ptr interface { + Foo_meth_ptr(Foo_integers, int) +} + +var _wrap__swig_DirectorBar_upcall_Foo_meth_ptr unsafe.Pointer + +func _swig_wrap__swig_DirectorBar_upcall_Foo_meth_ptr(_swig_ptr SwigcptrBar, _ uintptr, _ int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) + _cgo_runtime_cgocall(_wrap__swig_DirectorBar_upcall_Foo_meth_ptr, _swig_p) + return +} + +func (swig_p *_swig_DirectorBar) Foo_meth_ptr(arg0 Foo_integers, arg1 int) { + if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceBarFoo_meth_ptr); swig_ok { + swig_g.Foo_meth_ptr(arg0, arg1) + return + } + _swig_wrap__swig_DirectorBar_upcall_Foo_meth_ptr(swig_p.SwigcptrBar, arg0.Swigcptr(), arg1) +} + +func DirectorBarFoo_meth_ptr(p Bar, arg2 Foo_integers, arg3 int) { + _swig_wrap__swig_DirectorBar_upcall_Foo_meth_ptr(p.(*_swig_DirectorBar).SwigcptrBar, arg2.Swigcptr(), arg3) +} + +func Swig_DirectorBar_callback_foo_meth_ptr(p *_swig_DirectorBar, arg2 uintptr, arg3 int) { + p.Foo_meth_ptr(SwigcptrFoo_integers(arg2), arg3) +} + +type _swig_DirectorInterfaceBarFoo_meth_val interface { + Foo_meth_val(Foo_integers, int) +} + +var _wrap__swig_DirectorBar_upcall_Foo_meth_val unsafe.Pointer + +func _swig_wrap__swig_DirectorBar_upcall_Foo_meth_val(_swig_ptr SwigcptrBar, _ uintptr, _ int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) + _cgo_runtime_cgocall(_wrap__swig_DirectorBar_upcall_Foo_meth_val, _swig_p) + return +} + +func (swig_p *_swig_DirectorBar) Foo_meth_val(arg0 Foo_integers, arg1 int) { + if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceBarFoo_meth_val); swig_ok { + swig_g.Foo_meth_val(arg0, arg1) + return + } + _swig_wrap__swig_DirectorBar_upcall_Foo_meth_val(swig_p.SwigcptrBar, arg0.Swigcptr(), arg1) +} + +func DirectorBarFoo_meth_val(p Bar, arg2 Foo_integers, arg3 int) { + _swig_wrap__swig_DirectorBar_upcall_Foo_meth_val(p.(*_swig_DirectorBar).SwigcptrBar, arg2.Swigcptr(), arg3) +} + +func Swig_DirectorBar_callback_foo_meth_val(p *_swig_DirectorBar, arg2 uintptr, arg3 int) { + p.Foo_meth_val(SwigcptrFoo_integers(arg2), arg3) +} + +type _swig_DirectorInterfaceBarFoo_meth_cref interface { + Foo_meth_cref(Foo_integers, int) +} + +var _wrap__swig_DirectorBar_upcall_Foo_meth_cref unsafe.Pointer + +func _swig_wrap__swig_DirectorBar_upcall_Foo_meth_cref(_swig_ptr SwigcptrBar, _ uintptr, _ int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) + _cgo_runtime_cgocall(_wrap__swig_DirectorBar_upcall_Foo_meth_cref, _swig_p) + return +} + +func (swig_p *_swig_DirectorBar) Foo_meth_cref(arg0 Foo_integers, arg1 int) { + if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceBarFoo_meth_cref); swig_ok { + swig_g.Foo_meth_cref(arg0, arg1) + return + } + _swig_wrap__swig_DirectorBar_upcall_Foo_meth_cref(swig_p.SwigcptrBar, arg0.Swigcptr(), arg1) +} + +func DirectorBarFoo_meth_cref(p Bar, arg2 Foo_integers, arg3 int) { + _swig_wrap__swig_DirectorBar_upcall_Foo_meth_cref(p.(*_swig_DirectorBar).SwigcptrBar, arg2.Swigcptr(), arg3) +} + +func Swig_DirectorBar_callback_foo_meth_cref(p *_swig_DirectorBar, arg2 uintptr, arg3 int) { + p.Foo_meth_cref(SwigcptrFoo_integers(arg2), arg3) +} + +type _swig_DirectorInterfaceBarFoo_meth_cptr interface { + Foo_meth_cptr(Foo_integers, int) +} + +var _wrap__swig_DirectorBar_upcall_Foo_meth_cptr unsafe.Pointer + +func _swig_wrap__swig_DirectorBar_upcall_Foo_meth_cptr(_swig_ptr SwigcptrBar, _ uintptr, _ int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) + _cgo_runtime_cgocall(_wrap__swig_DirectorBar_upcall_Foo_meth_cptr, _swig_p) + return +} + +func (swig_p *_swig_DirectorBar) Foo_meth_cptr(arg0 Foo_integers, arg1 int) { + if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceBarFoo_meth_cptr); swig_ok { + swig_g.Foo_meth_cptr(arg0, arg1) + return + } + _swig_wrap__swig_DirectorBar_upcall_Foo_meth_cptr(swig_p.SwigcptrBar, arg0.Swigcptr(), arg1) +} + +func DirectorBarFoo_meth_cptr(p Bar, arg2 Foo_integers, arg3 int) { + _swig_wrap__swig_DirectorBar_upcall_Foo_meth_cptr(p.(*_swig_DirectorBar).SwigcptrBar, arg2.Swigcptr(), arg3) +} + +func Swig_DirectorBar_callback_foo_meth_cptr(p *_swig_DirectorBar, arg2 uintptr, arg3 int) { + p.Foo_meth_cptr(SwigcptrFoo_integers(arg2), arg3) +} + +type SwigcptrBar uintptr + +func (p SwigcptrBar) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrBar) SwigIsBar() { +} + +func (p SwigcptrBar) DirectorInterface() interface{} { + return nil +} + +var _wrap_delete_Bar unsafe.Pointer + +func _swig_wrap_delete_Bar(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Bar, _swig_p) + return +} + +func DeleteBar(arg1 Bar) { + _swig_wrap_delete_Bar(arg1.Swigcptr()) +} + +var _wrap_Bar_meth unsafe.Pointer + +func _swig_wrap_Bar_meth(base SwigcptrBar) (_ SwigcptrFoo_integers) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Bar_meth, _swig_p) + return +} + +func (arg1 SwigcptrBar) Meth() (_swig_ret Foo_integers) { + return _swig_wrap_Bar_meth(arg1) +} + +var _wrap_Bar_foo_meth_ref unsafe.Pointer + +func _swig_wrap_Bar_foo_meth_ref(base SwigcptrBar, _ uintptr, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Bar_foo_meth_ref, _swig_p) + return +} + +func (arg1 SwigcptrBar) Foo_meth_ref(arg2 Foo_integers, arg3 int) { + _swig_wrap_Bar_foo_meth_ref(arg1, arg2.Swigcptr(), arg3) +} + +var _wrap_Bar_foo_meth_ptr unsafe.Pointer + +func _swig_wrap_Bar_foo_meth_ptr(base SwigcptrBar, _ uintptr, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Bar_foo_meth_ptr, _swig_p) + return +} + +func (arg1 SwigcptrBar) Foo_meth_ptr(arg2 Foo_integers, arg3 int) { + _swig_wrap_Bar_foo_meth_ptr(arg1, arg2.Swigcptr(), arg3) +} + +var _wrap_Bar_foo_meth_val unsafe.Pointer + +func _swig_wrap_Bar_foo_meth_val(base SwigcptrBar, _ uintptr, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Bar_foo_meth_val, _swig_p) + return +} + +func (arg1 SwigcptrBar) Foo_meth_val(arg2 Foo_integers, arg3 int) { + _swig_wrap_Bar_foo_meth_val(arg1, arg2.Swigcptr(), arg3) +} + +var _wrap_Bar_foo_meth_cref unsafe.Pointer + +func _swig_wrap_Bar_foo_meth_cref(base SwigcptrBar, _ uintptr, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Bar_foo_meth_cref, _swig_p) + return +} + +func (arg1 SwigcptrBar) Foo_meth_cref(arg2 Foo_integers, arg3 int) { + _swig_wrap_Bar_foo_meth_cref(arg1, arg2.Swigcptr(), arg3) +} + +var _wrap_Bar_foo_meth_cptr unsafe.Pointer + +func _swig_wrap_Bar_foo_meth_cptr(base SwigcptrBar, _ uintptr, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Bar_foo_meth_cptr, _swig_p) + return +} + +func (arg1 SwigcptrBar) Foo_meth_cptr(arg2 Foo_integers, arg3 int) { + _swig_wrap_Bar_foo_meth_cptr(arg1, arg2.Swigcptr(), arg3) +} + +var _wrap_new_Bar unsafe.Pointer + +func _swig_wrap_new_Bar() (base SwigcptrBar) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Bar, _swig_p) + return +} + +func NewBar() (_swig_ret Bar) { + return _swig_wrap_new_Bar() +} + +type Bar interface { + Swigcptr() uintptr + SwigIsBar() + DirectorInterface() interface{} + Meth() (_swig_ret Foo_integers) + Foo_meth_ref(arg2 Foo_integers, arg3 int) + Foo_meth_ptr(arg2 Foo_integers, arg3 int) + Foo_meth_val(arg2 Foo_integers, arg3 int) + Foo_meth_cref(arg2 Foo_integers, arg3 int) + Foo_meth_cptr(arg2 Foo_integers, arg3 int) +} + +type _swig_DirectorFoo_integers struct { + SwigcptrFoo_integers + v interface{} +} + +func (p *_swig_DirectorFoo_integers) Swigcptr() uintptr { + return p.SwigcptrFoo_integers.Swigcptr() +} + +func (p *_swig_DirectorFoo_integers) SwigIsFoo_integers() { +} + +func (p *_swig_DirectorFoo_integers) DirectorInterface() interface{} { + return p.v +} + +var _wrap__swig_NewDirectorFoo_integersFoo_integers unsafe.Pointer + +func _swig_NewDirectorFoo_integersFoo_integers(_swig_director *_swig_DirectorFoo_integers) (_swig_ret SwigcptrFoo_integers) { + _swig_p := uintptr(unsafe.Pointer(&_swig_director)) + _cgo_runtime_cgocall(_wrap__swig_NewDirectorFoo_integersFoo_integers, _swig_p) + return +} + +func NewDirectorFoo_integers(v interface{}) Foo_integers { + p := &_swig_DirectorFoo_integers{0, v} + p.SwigcptrFoo_integers = _swig_NewDirectorFoo_integersFoo_integers(p) + return p +} + +var _wrap_DeleteDirectorFoo_integers unsafe.Pointer + +func _swig_wrap_DeleteDirectorFoo_integers(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_DeleteDirectorFoo_integers, _swig_p) + return +} + +func DeleteDirectorFoo_integers(arg1 Foo_integers) { + _swig_wrap_DeleteDirectorFoo_integers(arg1.Swigcptr()) +} + +func Swiggo_DeleteDirector_Foo_integers(p *_swig_DirectorFoo_integers) { + p.SwigcptrFoo_integers = 0 +} + +type _swig_DirectorInterfaceFoo_integersMeth interface { + Meth(int) int +} + +var _wrap__swig_DirectorFoo_integers_upcall_Meth unsafe.Pointer + +func _swig_wrap__swig_DirectorFoo_integers_upcall_Meth(_swig_ptr SwigcptrFoo_integers, _ int) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) + _cgo_runtime_cgocall(_wrap__swig_DirectorFoo_integers_upcall_Meth, _swig_p) + return +} + +func (swig_p *_swig_DirectorFoo_integers) Meth(param int) int { + if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceFoo_integersMeth); swig_ok { + return swig_g.Meth(param) + } + var swig_r int + swig_r = _swig_wrap__swig_DirectorFoo_integers_upcall_Meth(swig_p.SwigcptrFoo_integers, param) + return swig_r +} + +func DirectorFoo_integersMeth(p Foo_integers, arg2 int) int { + var swig_r int + swig_r = _swig_wrap__swig_DirectorFoo_integers_upcall_Meth(p.(*_swig_DirectorFoo_integers).SwigcptrFoo_integers, arg2) + return swig_r +} + +func Swig_DirectorFoo_integers_callback_meth(p *_swig_DirectorFoo_integers, arg2 int) (swig_result int) { + var swig_r int + swig_r = p.Meth(arg2) + return swig_r +} + +type SwigcptrFoo_integers uintptr + +func (p SwigcptrFoo_integers) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrFoo_integers) SwigIsFoo_integers() { +} + +func (p SwigcptrFoo_integers) DirectorInterface() interface{} { + return nil +} + +var _wrap_new_Foo_integers unsafe.Pointer + +func _swig_wrap_new_Foo_integers() (base SwigcptrFoo_integers) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Foo_integers, _swig_p) + return +} + +func NewFoo_integers() (_swig_ret Foo_integers) { + return _swig_wrap_new_Foo_integers() +} + +var _wrap_delete_Foo_integers unsafe.Pointer + +func _swig_wrap_delete_Foo_integers(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Foo_integers, _swig_p) + return +} + +func DeleteFoo_integers(arg1 Foo_integers) { + _swig_wrap_delete_Foo_integers(arg1.Swigcptr()) +} + +var _wrap_Foo_integers_meth unsafe.Pointer + +func _swig_wrap_Foo_integers_meth(base SwigcptrFoo_integers, _ int) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_integers_meth, _swig_p) + return +} + +func (arg1 SwigcptrFoo_integers) Meth(arg2 int) (_swig_ret int) { + return _swig_wrap_Foo_integers_meth(arg1, arg2) +} + +type Foo_integers interface { + Swigcptr() uintptr + SwigIsFoo_integers() + DirectorInterface() interface{} + Meth(arg2 int) (_swig_ret int) +} + + +type SwigcptrSwigDirector_Bar uintptr +type SwigDirector_Bar interface { + Swigcptr() uintptr; +} +func (p SwigcptrSwigDirector_Bar) Swigcptr() uintptr { + return uintptr(p) +} + +type SwigcptrSwigDirector_Foo_integers uintptr +type SwigDirector_Foo_integers interface { + Swigcptr() uintptr; +} +func (p SwigcptrSwigDirector_Foo_integers) Swigcptr() uintptr { + return uintptr(p) +} + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/director_wombat_wrap.h b/Examples/test-suite/go/director_wombat_wrap.h new file mode 100644 index 000000000..e65021439 --- /dev/null +++ b/Examples/test-suite/go/director_wombat_wrap.h @@ -0,0 +1,62 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../director_wombat.i + +#ifndef SWIG_director_wombat_WRAP_H_ +#define SWIG_director_wombat_WRAP_H_ + +class SwigDirector_Bar : public Bar +{ + public: + SwigDirector_Bar(void *swig_p); + virtual ~SwigDirector_Bar(); + Foo_int *_swig_upcall_meth() { + return Bar::meth(); + } + virtual Foo_int *meth(); + void _swig_upcall_foo_meth_ref(Foo_int &arg0, int arg1) { + Bar::foo_meth_ref(arg0,arg1); + } + virtual void foo_meth_ref(Foo_int &arg0, int arg1); + void _swig_upcall_foo_meth_ptr(Foo_int *arg0, int arg1) { + Bar::foo_meth_ptr(arg0,arg1); + } + virtual void foo_meth_ptr(Foo_int *arg0, int arg1); + void _swig_upcall_foo_meth_val(Foo_int arg0, int arg1) { + Bar::foo_meth_val(arg0,arg1); + } + virtual void foo_meth_val(Foo_int arg0, int arg1); + void _swig_upcall_foo_meth_cref(Foo_int const &arg0, int arg1) { + Bar::foo_meth_cref(arg0,arg1); + } + virtual void foo_meth_cref(Foo_int const &arg0, int arg1); + void _swig_upcall_foo_meth_cptr(Foo_int const *arg0, int arg1) { + Bar::foo_meth_cptr(arg0,arg1); + } + virtual void foo_meth_cptr(Foo_int const *arg0, int arg1); + private: + void *go_val; +}; + +class SwigDirector_Foo_integers : public Foo< int > +{ + public: + SwigDirector_Foo_integers(void *swig_p); + virtual ~SwigDirector_Foo_integers(); + int _swig_upcall_meth(int param) { + return Foo< int >::meth(param); + } + virtual int meth(int param); + private: + void *go_val; +}; + +#endif diff --git a/Examples/test-suite/go/disown.go b/Examples/test-suite/go/disown.go new file mode 100644 index 000000000..ad89189ff --- /dev/null +++ b/Examples/test-suite/go/disown.go @@ -0,0 +1,139 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../disown.i + +package disown + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrA uintptr + +func (p SwigcptrA) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrA) SwigIsA() { +} + +var _wrap_delete_A unsafe.Pointer + +func _swig_wrap_delete_A(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_A, _swig_p) + return +} + +func DeleteA(arg1 A) { + _swig_wrap_delete_A(arg1.Swigcptr()) +} + +var _wrap_new_A unsafe.Pointer + +func _swig_wrap_new_A() (base SwigcptrA) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_A, _swig_p) + return +} + +func NewA() (_swig_ret A) { + return _swig_wrap_new_A() +} + +type A interface { + Swigcptr() uintptr + SwigIsA() +} + +type SwigcptrB uintptr + +func (p SwigcptrB) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrB) SwigIsB() { +} + +var _wrap_new_B unsafe.Pointer + +func _swig_wrap_new_B() (base SwigcptrB) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_B, _swig_p) + return +} + +func NewB() (_swig_ret B) { + return _swig_wrap_new_B() +} + +var _wrap_delete_B unsafe.Pointer + +func _swig_wrap_delete_B(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_B, _swig_p) + return +} + +func DeleteB(arg1 B) { + _swig_wrap_delete_B(arg1.Swigcptr()) +} + +var _wrap_B_acquire unsafe.Pointer + +func _swig_wrap_B_acquire(base SwigcptrB, _ uintptr) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_B_acquire, _swig_p) + return +} + +func (arg1 SwigcptrB) Acquire(arg2 A) (_swig_ret int) { + return _swig_wrap_B_acquire(arg1, arg2.Swigcptr()) +} + +var _wrap_B_remove unsafe.Pointer + +func _swig_wrap_B_remove(base SwigcptrB, _ uintptr) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_B_remove, _swig_p) + return +} + +func (arg1 SwigcptrB) Remove(arg2 A) (_swig_ret int) { + return _swig_wrap_B_remove(arg1, arg2.Swigcptr()) +} + +type B interface { + Swigcptr() uintptr + SwigIsB() + Acquire(arg2 A) (_swig_ret int) + Remove(arg2 A) (_swig_ret int) +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/disown_runme b/Examples/test-suite/go/disown_runme new file mode 100755 index 000000000..162b3d682 Binary files /dev/null and b/Examples/test-suite/go/disown_runme differ diff --git a/Examples/test-suite/go/dynamic_cast.go b/Examples/test-suite/go/dynamic_cast.go new file mode 100644 index 000000000..94e9b9b66 --- /dev/null +++ b/Examples/test-suite/go/dynamic_cast.go @@ -0,0 +1,178 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../dynamic_cast.i + +package dynamic_cast + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + + +func FooToBar(f Foo) Bar { + return SwigcptrBar(f.Swigcptr()) +} + +type SwigcptrFoo uintptr + +func (p SwigcptrFoo) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrFoo) SwigIsFoo() { +} + +var _wrap_delete_Foo unsafe.Pointer + +func _swig_wrap_delete_Foo(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Foo, _swig_p) + return +} + +func DeleteFoo(arg1 Foo) { + _swig_wrap_delete_Foo(arg1.Swigcptr()) +} + +var _wrap_Foo_blah unsafe.Pointer + +func _swig_wrap_Foo_blah(base SwigcptrFoo) (_ SwigcptrFoo) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_blah, _swig_p) + return +} + +func (arg1 SwigcptrFoo) Blah() (_swig_ret Foo) { + return _swig_wrap_Foo_blah(arg1) +} + +var _wrap_new_Foo unsafe.Pointer + +func _swig_wrap_new_Foo() (base SwigcptrFoo) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Foo, _swig_p) + return +} + +func NewFoo() (_swig_ret Foo) { + return _swig_wrap_new_Foo() +} + +type Foo interface { + Swigcptr() uintptr + SwigIsFoo() + Blah() (_swig_ret Foo) +} + +type SwigcptrBar uintptr + +func (p SwigcptrBar) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrBar) SwigIsBar() { +} + +var _wrap_Bar_blah unsafe.Pointer + +func _swig_wrap_Bar_blah(base SwigcptrBar) (_ SwigcptrFoo) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Bar_blah, _swig_p) + return +} + +func (arg1 SwigcptrBar) Blah() (_swig_ret Foo) { + return _swig_wrap_Bar_blah(arg1) +} + +var _wrap_Bar_test unsafe.Pointer + +func _swig_wrap_Bar_test(base SwigcptrBar) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Bar_test, _swig_p) + return +} + +func (arg1 SwigcptrBar) Test() (_swig_ret string) { + return _swig_wrap_Bar_test(arg1) +} + +var _wrap_new_Bar unsafe.Pointer + +func _swig_wrap_new_Bar() (base SwigcptrBar) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Bar, _swig_p) + return +} + +func NewBar() (_swig_ret Bar) { + return _swig_wrap_new_Bar() +} + +var _wrap_delete_Bar unsafe.Pointer + +func _swig_wrap_delete_Bar(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Bar, _swig_p) + return +} + +func DeleteBar(arg1 Bar) { + _swig_wrap_delete_Bar(arg1.Swigcptr()) +} + +func (p SwigcptrBar) SwigIsFoo() { +} + +func (p SwigcptrBar) SwigGetFoo() Foo { + return SwigcptrFoo(p.Swigcptr()) +} + +type Bar interface { + Swigcptr() uintptr + SwigIsBar() + Blah() (_swig_ret Foo) + Test() (_swig_ret string) + SwigIsFoo() + SwigGetFoo() Foo +} + +var _wrap_do_test unsafe.Pointer + +func _swig_wrap_do_test(base uintptr) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_do_test, _swig_p) + return +} + +func Do_test(arg1 Bar) (_swig_ret string) { + return _swig_wrap_do_test(arg1.Swigcptr()) +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/dynamic_cast_runme b/Examples/test-suite/go/dynamic_cast_runme new file mode 100755 index 000000000..333efd253 Binary files /dev/null and b/Examples/test-suite/go/dynamic_cast_runme differ diff --git a/Examples/test-suite/go/empty.go b/Examples/test-suite/go/empty.go new file mode 100644 index 000000000..3484c59fc --- /dev/null +++ b/Examples/test-suite/go/empty.go @@ -0,0 +1,29 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../empty.i + +package empty + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + + diff --git a/Examples/test-suite/go/empty_runme b/Examples/test-suite/go/empty_runme new file mode 100755 index 000000000..4f1a9f803 Binary files /dev/null and b/Examples/test-suite/go/empty_runme differ diff --git a/Examples/test-suite/go/enum_forward.go b/Examples/test-suite/go/enum_forward.go new file mode 100644 index 000000000..3e2cb2850 --- /dev/null +++ b/Examples/test-suite/go/enum_forward.go @@ -0,0 +1,90 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../enum_forward.i + +package enum_forward + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type Enum_SS_ForwardEnum1 int +var _wrap_get_enum1 unsafe.Pointer + +func Get_enum1() (_swig_ret Enum_SS_ForwardEnum1) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_get_enum1, _swig_p) + return +} +var _wrap_test_function1 unsafe.Pointer + +func Test_function1(arg1 Enum_SS_ForwardEnum1) (_swig_ret Enum_SS_ForwardEnum1) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_test_function1, _swig_p) + return +} +var _wrap_get_enum2 unsafe.Pointer + +func Get_enum2() (_swig_ret Enum_SS_ForwardEnum2) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_get_enum2, _swig_p) + return +} +var _wrap_test_function2 unsafe.Pointer + +func Test_function2(arg1 Enum_SS_ForwardEnum2) (_swig_ret Enum_SS_ForwardEnum2) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_test_function2, _swig_p) + return +} +type Enum_SS_ForwardEnum2 int +type Enum_SS_ForwardEnum3 int +var _wrap_EEE unsafe.Pointer + +func _swig_getEEE() (_swig_ret Enum_SS_ForwardEnum3) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_EEE, _swig_p) + return +} +var EEE Enum_SS_ForwardEnum3 = _swig_getEEE() +var _wrap_FFF unsafe.Pointer + +func _swig_getFFF() (_swig_ret Enum_SS_ForwardEnum3) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_FFF, _swig_p) + return +} +var FFF Enum_SS_ForwardEnum3 = _swig_getFFF() +var _wrap_get_enum3 unsafe.Pointer + +func Get_enum3() (_swig_ret Enum_SS_ForwardEnum3) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_get_enum3, _swig_p) + return +} +var _wrap_test_function3 unsafe.Pointer + +func Test_function3(arg1 Enum_SS_ForwardEnum3) (_swig_ret Enum_SS_ForwardEnum3) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_test_function3, _swig_p) + return +} + diff --git a/Examples/test-suite/go/enum_ignore.go b/Examples/test-suite/go/enum_ignore.go new file mode 100644 index 000000000..5d0c7af4f --- /dev/null +++ b/Examples/test-suite/go/enum_ignore.go @@ -0,0 +1,129 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../enum_ignore.i + +package enum_ignore + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrDraw uintptr + +func (p SwigcptrDraw) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrDraw) SwigIsDraw() { +} + +var _wrap_Draw_DrawBW unsafe.Pointer + +func _swig_wrap_Draw_DrawBW(base SwigcptrDraw) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Draw_DrawBW, _swig_p) + return +} + +func (arg1 SwigcptrDraw) DrawBW() { + _swig_wrap_Draw_DrawBW(arg1) +} + +var _wrap_Draw_DrawC unsafe.Pointer + +func _swig_wrap_Draw_DrawC(base SwigcptrDraw, _ N_C) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Draw_DrawC, _swig_p) + return +} + +func (arg1 SwigcptrDraw) DrawC(arg2 N_C) { + _swig_wrap_Draw_DrawC(arg1, arg2) +} + +var _wrap_Draw_DrawC_Ptr unsafe.Pointer + +func _swig_wrap_Draw_DrawC_Ptr(base SwigcptrDraw, _ *N_C) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Draw_DrawC_Ptr, _swig_p) + return +} + +func (arg1 SwigcptrDraw) DrawC_Ptr(arg2 *N_C) { + _swig_wrap_Draw_DrawC_Ptr(arg1, arg2) +} + +var _wrap_Draw_DrawC_ConstRef unsafe.Pointer + +func _swig_wrap_Draw_DrawC_ConstRef(base SwigcptrDraw, _ *N_C) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Draw_DrawC_ConstRef, _swig_p) + return +} + +func (arg1 SwigcptrDraw) DrawC_ConstRef(arg2 *N_C) { + _swig_wrap_Draw_DrawC_ConstRef(arg1, arg2) +} + +var _wrap_new_Draw unsafe.Pointer + +func _swig_wrap_new_Draw() (base SwigcptrDraw) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Draw, _swig_p) + return +} + +func NewDraw() (_swig_ret Draw) { + return _swig_wrap_new_Draw() +} + +var _wrap_delete_Draw unsafe.Pointer + +func _swig_wrap_delete_Draw(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Draw, _swig_p) + return +} + +func DeleteDraw(arg1 Draw) { + _swig_wrap_delete_Draw(arg1.Swigcptr()) +} + +type Draw interface { + Swigcptr() uintptr + SwigIsDraw() + DrawBW() + DrawC(arg2 N_C) + DrawC_Ptr(arg2 *N_C) + DrawC_ConstRef(arg2 *N_C) +} + + +type N_C int + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/enum_macro.go b/Examples/test-suite/go/enum_macro.go new file mode 100644 index 000000000..bddf43693 --- /dev/null +++ b/Examples/test-suite/go/enum_macro.go @@ -0,0 +1,226 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../enum_macro.i + +package enum_macro + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type Enum_SS_Greeks1 int +var _wrap_alpha1 unsafe.Pointer + +func _swig_getalpha1() (_swig_ret Enum_SS_Greeks1) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_alpha1, _swig_p) + return +} +var Alpha1 Enum_SS_Greeks1 = _swig_getalpha1() +var _wrap_beta1 unsafe.Pointer + +func _swig_getbeta1() (_swig_ret Enum_SS_Greeks1) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_beta1, _swig_p) + return +} +var Beta1 Enum_SS_Greeks1 = _swig_getbeta1() +var _wrap_theta1 unsafe.Pointer + +func _swig_gettheta1() (_swig_ret Enum_SS_Greeks1) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_theta1, _swig_p) + return +} +var Theta1 Enum_SS_Greeks1 = _swig_gettheta1() +type Enum_SS_Greeks2 int +var _wrap_alpha2 unsafe.Pointer + +func _swig_getalpha2() (_swig_ret Enum_SS_Greeks2) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_alpha2, _swig_p) + return +} +var Alpha2 Enum_SS_Greeks2 = _swig_getalpha2() +var _wrap_beta2 unsafe.Pointer + +func _swig_getbeta2() (_swig_ret Enum_SS_Greeks2) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_beta2, _swig_p) + return +} +var Beta2 Enum_SS_Greeks2 = _swig_getbeta2() +var _wrap_theta2 unsafe.Pointer + +func _swig_gettheta2() (_swig_ret Enum_SS_Greeks2) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_theta2, _swig_p) + return +} +var Theta2 Enum_SS_Greeks2 = _swig_gettheta2() +type Enum_SS_Greeks3 int +var _wrap_alpha3 unsafe.Pointer + +func _swig_getalpha3() (_swig_ret Enum_SS_Greeks3) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_alpha3, _swig_p) + return +} +var Alpha3 Enum_SS_Greeks3 = _swig_getalpha3() +var _wrap_beta3 unsafe.Pointer + +func _swig_getbeta3() (_swig_ret Enum_SS_Greeks3) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_beta3, _swig_p) + return +} +var Beta3 Enum_SS_Greeks3 = _swig_getbeta3() +var _wrap_theta3 unsafe.Pointer + +func _swig_gettheta3() (_swig_ret Enum_SS_Greeks3) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_theta3, _swig_p) + return +} +var Theta3 Enum_SS_Greeks3 = _swig_gettheta3() +type Enum_SS_Greeks4 int +var _wrap_alpha4 unsafe.Pointer + +func _swig_getalpha4() (_swig_ret Enum_SS_Greeks4) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_alpha4, _swig_p) + return +} +var Alpha4 Enum_SS_Greeks4 = _swig_getalpha4() +var _wrap_beta4 unsafe.Pointer + +func _swig_getbeta4() (_swig_ret Enum_SS_Greeks4) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_beta4, _swig_p) + return +} +var Beta4 Enum_SS_Greeks4 = _swig_getbeta4() +var _wrap_theta4 unsafe.Pointer + +func _swig_gettheta4() (_swig_ret Enum_SS_Greeks4) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_theta4, _swig_p) + return +} +var Theta4 Enum_SS_Greeks4 = _swig_gettheta4() +type Enum_SS_Greeks5 int +var _wrap_alpha5 unsafe.Pointer + +func _swig_getalpha5() (_swig_ret Enum_SS_Greeks5) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_alpha5, _swig_p) + return +} +var Alpha5 Enum_SS_Greeks5 = _swig_getalpha5() +var _wrap_beta5 unsafe.Pointer + +func _swig_getbeta5() (_swig_ret Enum_SS_Greeks5) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_beta5, _swig_p) + return +} +var Beta5 Enum_SS_Greeks5 = _swig_getbeta5() +type Enum_SS_Greeks6 int +var _wrap_alpha6 unsafe.Pointer + +func _swig_getalpha6() (_swig_ret Enum_SS_Greeks6) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_alpha6, _swig_p) + return +} +var Alpha6 Enum_SS_Greeks6 = _swig_getalpha6() +var _wrap_beta6 unsafe.Pointer + +func _swig_getbeta6() (_swig_ret Enum_SS_Greeks6) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_beta6, _swig_p) + return +} +var Beta6 Enum_SS_Greeks6 = _swig_getbeta6() +type Enum_SS_Greeks7 int +var _wrap_alpha7 unsafe.Pointer + +func _swig_getalpha7() (_swig_ret Enum_SS_Greeks7) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_alpha7, _swig_p) + return +} +var Alpha7 Enum_SS_Greeks7 = _swig_getalpha7() +var _wrap_beta7 unsafe.Pointer + +func _swig_getbeta7() (_swig_ret Enum_SS_Greeks7) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_beta7, _swig_p) + return +} +var Beta7 Enum_SS_Greeks7 = _swig_getbeta7() +type Enum_SS_Greeks8 int +var _wrap_theta8 unsafe.Pointer + +func _swig_gettheta8() (_swig_ret Enum_SS_Greeks8) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_theta8, _swig_p) + return +} +var Theta8 Enum_SS_Greeks8 = _swig_gettheta8() +type Enum_SS_Greeks9 int +var _wrap_theta9 unsafe.Pointer + +func _swig_gettheta9() (_swig_ret Enum_SS_Greeks9) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_theta9, _swig_p) + return +} +var Theta9 Enum_SS_Greeks9 = _swig_gettheta9() +type Enum_SS_Greeks10 int +var _wrap_theta10 unsafe.Pointer + +func _swig_gettheta10() (_swig_ret Enum_SS_Greeks10) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_theta10, _swig_p) + return +} +var Theta10 Enum_SS_Greeks10 = _swig_gettheta10() +type Enum_SS_Greeks11 int +var _wrap_theta11 unsafe.Pointer + +func _swig_gettheta11() (_swig_ret Enum_SS_Greeks11) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_theta11, _swig_p) + return +} +var Theta11 Enum_SS_Greeks11 = _swig_gettheta11() +type Greeks12 int +var _wrap_theta12 unsafe.Pointer + +func _swig_gettheta12() (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_theta12, _swig_p) + return +} +var Theta12 int = _swig_gettheta12() +type Enum_SS_Greeks13 int + diff --git a/Examples/test-suite/go/enum_missing.go b/Examples/test-suite/go/enum_missing.go new file mode 100644 index 000000000..0a86f64c8 --- /dev/null +++ b/Examples/test-suite/go/enum_missing.go @@ -0,0 +1,196 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../enum_missing.i + +package enum_missing + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrAVCodecContext uintptr + +func (p SwigcptrAVCodecContext) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrAVCodecContext) SwigIsAVCodecContext() { +} + +var _wrap_AVCodecContext_pix_fmt_set unsafe.Pointer + +func _swig_wrap_AVCodecContext_pix_fmt_set(base SwigcptrAVCodecContext, _ AVPixelFormat) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_AVCodecContext_pix_fmt_set, _swig_p) + return +} + +func (arg1 SwigcptrAVCodecContext) SetPix_fmt(arg2 AVPixelFormat) { + _swig_wrap_AVCodecContext_pix_fmt_set(arg1, arg2) +} + +var _wrap_AVCodecContext_pix_fmt_get unsafe.Pointer + +func _swig_wrap_AVCodecContext_pix_fmt_get(base SwigcptrAVCodecContext) (_ AVPixelFormat) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_AVCodecContext_pix_fmt_get, _swig_p) + return +} + +func (arg1 SwigcptrAVCodecContext) GetPix_fmt() (_swig_ret AVPixelFormat) { + return _swig_wrap_AVCodecContext_pix_fmt_get(arg1) +} + +var _wrap_AVCodecContext_pix_fmt2_set unsafe.Pointer + +func _swig_wrap_AVCodecContext_pix_fmt2_set(base SwigcptrAVCodecContext, _ AVPixelFormat2) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_AVCodecContext_pix_fmt2_set, _swig_p) + return +} + +func (arg1 SwigcptrAVCodecContext) SetPix_fmt2(arg2 AVPixelFormat2) { + _swig_wrap_AVCodecContext_pix_fmt2_set(arg1, arg2) +} + +var _wrap_AVCodecContext_pix_fmt2_get unsafe.Pointer + +func _swig_wrap_AVCodecContext_pix_fmt2_get(base SwigcptrAVCodecContext) (_ AVPixelFormat2) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_AVCodecContext_pix_fmt2_get, _swig_p) + return +} + +func (arg1 SwigcptrAVCodecContext) GetPix_fmt2() (_swig_ret AVPixelFormat2) { + return _swig_wrap_AVCodecContext_pix_fmt2_get(arg1) +} + +var _wrap_new_AVCodecContext unsafe.Pointer + +func _swig_wrap_new_AVCodecContext() (base SwigcptrAVCodecContext) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_AVCodecContext, _swig_p) + return +} + +func NewAVCodecContext() (_swig_ret AVCodecContext) { + return _swig_wrap_new_AVCodecContext() +} + +var _wrap_delete_AVCodecContext unsafe.Pointer + +func _swig_wrap_delete_AVCodecContext(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_AVCodecContext, _swig_p) + return +} + +func DeleteAVCodecContext(arg1 AVCodecContext) { + _swig_wrap_delete_AVCodecContext(arg1.Swigcptr()) +} + +type AVCodecContext interface { + Swigcptr() uintptr + SwigIsAVCodecContext() + SetPix_fmt(arg2 AVPixelFormat) + GetPix_fmt() (_swig_ret AVPixelFormat) + SetPix_fmt2(arg2 AVPixelFormat2) + GetPix_fmt2() (_swig_ret AVPixelFormat2) +} + +var _wrap_global_fmt_set unsafe.Pointer + +func _swig_wrap_global_fmt_set(base AVPixelFormat) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_global_fmt_set, _swig_p) + return +} + +func SetGlobal_fmt(arg1 AVPixelFormat) { + _swig_wrap_global_fmt_set(arg1) +} + +var _wrap_global_fmt_get unsafe.Pointer + +func GetGlobal_fmt() (_swig_ret AVPixelFormat) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_global_fmt_get, _swig_p) + return +} +var _wrap_global_fmt2_set unsafe.Pointer + +func _swig_wrap_global_fmt2_set(base AVPixelFormat2) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_global_fmt2_set, _swig_p) + return +} + +func SetGlobal_fmt2(arg1 AVPixelFormat2) { + _swig_wrap_global_fmt2_set(arg1) +} + +var _wrap_global_fmt2_get unsafe.Pointer + +func GetGlobal_fmt2() (_swig_ret AVPixelFormat2) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_global_fmt2_get, _swig_p) + return +} +var _wrap_use_pixel_format unsafe.Pointer + +func Use_pixel_format(arg1 AVPixelFormat) (_swig_ret AVPixelFormat) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_use_pixel_format, _swig_p) + return +} +var _wrap_use_pixel_format_ptr unsafe.Pointer + +func Use_pixel_format_ptr(arg1 *AVPixelFormat) (_swig_ret *AVPixelFormat) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_use_pixel_format_ptr, _swig_p) + return +} +var _wrap_use_pixel_format2 unsafe.Pointer + +func Use_pixel_format2(arg1 AVPixelFormat2) (_swig_ret AVPixelFormat2) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_use_pixel_format2, _swig_p) + return +} +var _wrap_use_pixel_format_ptr2 unsafe.Pointer + +func Use_pixel_format_ptr2(arg1 *AVPixelFormat2) (_swig_ret *AVPixelFormat2) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_use_pixel_format_ptr2, _swig_p) + return +} + +type AVPixelFormat2 int +type AVPixelFormat int + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/enum_plus.go b/Examples/test-suite/go/enum_plus.go new file mode 100644 index 000000000..8b5b7b7ef --- /dev/null +++ b/Examples/test-suite/go/enum_plus.go @@ -0,0 +1,83 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../enum_plus.i + +package enum_plus + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrIFoo uintptr + +func (p SwigcptrIFoo) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrIFoo) SwigIsIFoo() { +} + +var _wrap_Phoo_iFoo unsafe.Pointer + +func _swig_getiFoo_Phoo_iFoo() (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_Phoo_iFoo, _swig_p) + return +} +var IFooPhoo int = _swig_getiFoo_Phoo_iFoo() +var _wrap_new_iFoo unsafe.Pointer + +func _swig_wrap_new_iFoo() (base SwigcptrIFoo) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_iFoo, _swig_p) + return +} + +func NewIFoo() (_swig_ret IFoo) { + return _swig_wrap_new_iFoo() +} + +var _wrap_delete_iFoo unsafe.Pointer + +func _swig_wrap_delete_iFoo(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_iFoo, _swig_p) + return +} + +func DeleteIFoo(arg1 IFoo) { + _swig_wrap_delete_iFoo(arg1.Swigcptr()) +} + +type IFoo interface { + Swigcptr() uintptr + SwigIsIFoo() +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/enum_rename.go b/Examples/test-suite/go/enum_rename.go new file mode 100644 index 000000000..fe0bdc655 --- /dev/null +++ b/Examples/test-suite/go/enum_rename.go @@ -0,0 +1,71 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../enum_rename.i + +package enum_rename + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type Month int +var _wrap_M_Jan unsafe.Pointer + +func _swig_getM_Jan() (_swig_ret Month) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_M_Jan, _swig_p) + return +} +var M_Jan Month = _swig_getM_Jan() +var _wrap_May unsafe.Pointer + +func _swig_getMay() (_swig_ret Month) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_May, _swig_p) + return +} +var May Month = _swig_getMay() +var _wrap_M_Dec unsafe.Pointer + +func _swig_getM_Dec() (_swig_ret Month) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_M_Dec, _swig_p) + return +} +var M_Dec Month = _swig_getM_Dec() +type Severity int +var _wrap_S_Can unsafe.Pointer + +func _swig_getS_Can() (_swig_ret Severity) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_S_Can, _swig_p) + return +} +var S_Can Severity = _swig_getS_Can() +var _wrap_S_Must unsafe.Pointer + +func _swig_getS_Must() (_swig_ret Severity) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_S_Must, _swig_p) + return +} +var S_Must Severity = _swig_getS_Must() + diff --git a/Examples/test-suite/go/enum_scope_template.go b/Examples/test-suite/go/enum_scope_template.go new file mode 100644 index 000000000..911d5236d --- /dev/null +++ b/Examples/test-suite/go/enum_scope_template.go @@ -0,0 +1,120 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../enum_scope_template.i + +package enum_scope_template + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +var _wrap_chop unsafe.Pointer + +func Chop(arg1 Tree_Sl_int_Sg_Types) (_swig_ret Tree_Sl_int_Sg_Types) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_chop, _swig_p) + return +} +type SwigcptrTreeInt uintptr + +func (p SwigcptrTreeInt) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrTreeInt) SwigIsTreeInt() { +} + +type Tree_Sl_int_Sg_Types int +var _wrap_Oak_TreeInt unsafe.Pointer + +func _swig_getTreeInt_Oak_TreeInt() (_swig_ret Tree_Sl_int_Sg_Types) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_Oak_TreeInt, _swig_p) + return +} +var TreeIntOak Tree_Sl_int_Sg_Types = _swig_getTreeInt_Oak_TreeInt() +var _wrap_Fir_TreeInt unsafe.Pointer + +func _swig_getTreeInt_Fir_TreeInt() (_swig_ret Tree_Sl_int_Sg_Types) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_Fir_TreeInt, _swig_p) + return +} +var TreeIntFir Tree_Sl_int_Sg_Types = _swig_getTreeInt_Fir_TreeInt() +var _wrap_Cedar_TreeInt unsafe.Pointer + +func _swig_getTreeInt_Cedar_TreeInt() (_swig_ret Tree_Sl_int_Sg_Types) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_Cedar_TreeInt, _swig_p) + return +} +var TreeIntCedar Tree_Sl_int_Sg_Types = _swig_getTreeInt_Cedar_TreeInt() +var _wrap_TreeInt_chop unsafe.Pointer + +func _swig_wrap_TreeInt_chop(base SwigcptrTreeInt, _ Tree_Sl_int_Sg_Types) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_TreeInt_chop, _swig_p) + return +} + +func (arg1 SwigcptrTreeInt) Chop(arg2 Tree_Sl_int_Sg_Types) { + _swig_wrap_TreeInt_chop(arg1, arg2) +} + +var _wrap_new_TreeInt unsafe.Pointer + +func _swig_wrap_new_TreeInt() (base SwigcptrTreeInt) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_TreeInt, _swig_p) + return +} + +func NewTreeInt() (_swig_ret TreeInt) { + return _swig_wrap_new_TreeInt() +} + +var _wrap_delete_TreeInt unsafe.Pointer + +func _swig_wrap_delete_TreeInt(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_TreeInt, _swig_p) + return +} + +func DeleteTreeInt(arg1 TreeInt) { + _swig_wrap_delete_TreeInt(arg1.Swigcptr()) +} + +type TreeInt interface { + Swigcptr() uintptr + SwigIsTreeInt() + Chop(arg2 Tree_Sl_int_Sg_Types) +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/enum_template.go b/Examples/test-suite/go/enum_template.go new file mode 100644 index 000000000..fcdd47c22 --- /dev/null +++ b/Examples/test-suite/go/enum_template.go @@ -0,0 +1,119 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../enum_template.i + +package enum_template + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type ETest int +var _wrap_eTest0 unsafe.Pointer + +func _swig_geteTest0() (_swig_ret ETest) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_eTest0, _swig_p) + return +} +var ETest0 ETest = _swig_geteTest0() +var _wrap_eTest1 unsafe.Pointer + +func _swig_geteTest1() (_swig_ret ETest) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_eTest1, _swig_p) + return +} +var ETest1 ETest = _swig_geteTest1() +var _wrap_eTest2 unsafe.Pointer + +func _swig_geteTest2() (_swig_ret ETest) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_eTest2, _swig_p) + return +} +var ETest2 ETest = _swig_geteTest2() +var _wrap_TakeETest unsafe.Pointer + +func _swig_wrap_TakeETest(base ETest) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_TakeETest, _swig_p) + return +} + +func TakeETest(arg1 ETest) { + _swig_wrap_TakeETest(arg1) +} + +var _wrap_MakeETest unsafe.Pointer + +func MakeETest() (_swig_ret ETest) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_MakeETest, _swig_p) + return +} +type SwigcptrCTempl_ETest uintptr + +func (p SwigcptrCTempl_ETest) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrCTempl_ETest) SwigIsCTempl_ETest() { +} + +var _wrap_new_CTempl_ETest unsafe.Pointer + +func _swig_wrap_new_CTempl_ETest() (base SwigcptrCTempl_ETest) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_CTempl_ETest, _swig_p) + return +} + +func NewCTempl_ETest() (_swig_ret CTempl_ETest) { + return _swig_wrap_new_CTempl_ETest() +} + +var _wrap_delete_CTempl_ETest unsafe.Pointer + +func _swig_wrap_delete_CTempl_ETest(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_CTempl_ETest, _swig_p) + return +} + +func DeleteCTempl_ETest(arg1 CTempl_ETest) { + _swig_wrap_delete_CTempl_ETest(arg1.Swigcptr()) +} + +type CTempl_ETest interface { + Swigcptr() uintptr + SwigIsCTempl_ETest() +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/enum_template_runme b/Examples/test-suite/go/enum_template_runme new file mode 100755 index 000000000..89423b89e Binary files /dev/null and b/Examples/test-suite/go/enum_template_runme differ diff --git a/Examples/test-suite/go/enum_thorough.go b/Examples/test-suite/go/enum_thorough.go new file mode 100644 index 000000000..f4fb0df08 --- /dev/null +++ b/Examples/test-suite/go/enum_thorough.go @@ -0,0 +1,4294 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../enum_thorough.i + +package enum_thorough + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +var _wrap_AnonEnum1 unsafe.Pointer + +func _swig_getAnonEnum1() (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_AnonEnum1, _swig_p) + return +} +var AnonEnum1 int = _swig_getAnonEnum1() +var _wrap_AnonEnum2 unsafe.Pointer + +func _swig_getAnonEnum2() (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_AnonEnum2, _swig_p) + return +} +var AnonEnum2 int = _swig_getAnonEnum2() +var _wrap_ReallyAnInteger unsafe.Pointer + +func _swig_getReallyAnInteger() (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_ReallyAnInteger, _swig_p) + return +} +var ReallyAnInteger int = _swig_getReallyAnInteger() +var _wrap_AnonSpaceEnum1 unsafe.Pointer + +func _swig_getAnonSpaceEnum1() (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_AnonSpaceEnum1, _swig_p) + return +} +var AnonSpaceEnum1 int = _swig_getAnonSpaceEnum1() +var _wrap_AnonSpaceEnum2 unsafe.Pointer + +func _swig_getAnonSpaceEnum2() (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_AnonSpaceEnum2, _swig_p) + return +} +var AnonSpaceEnum2 int = _swig_getAnonSpaceEnum2() +type SwigcptrAnonStruct uintptr + +func (p SwigcptrAnonStruct) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrAnonStruct) SwigIsAnonStruct() { +} + +var _wrap_AnonStructEnum1_AnonStruct unsafe.Pointer + +func _swig_getAnonStruct_AnonStructEnum1_AnonStruct() (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_AnonStructEnum1_AnonStruct, _swig_p) + return +} +var AnonStructAnonStructEnum1 int = _swig_getAnonStruct_AnonStructEnum1_AnonStruct() +var _wrap_AnonStructEnum2_AnonStruct unsafe.Pointer + +func _swig_getAnonStruct_AnonStructEnum2_AnonStruct() (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_AnonStructEnum2_AnonStruct, _swig_p) + return +} +var AnonStructAnonStructEnum2 int = _swig_getAnonStruct_AnonStructEnum2_AnonStruct() +var _wrap_new_AnonStruct unsafe.Pointer + +func _swig_wrap_new_AnonStruct() (base SwigcptrAnonStruct) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_AnonStruct, _swig_p) + return +} + +func NewAnonStruct() (_swig_ret AnonStruct) { + return _swig_wrap_new_AnonStruct() +} + +var _wrap_delete_AnonStruct unsafe.Pointer + +func _swig_wrap_delete_AnonStruct(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_AnonStruct, _swig_p) + return +} + +func DeleteAnonStruct(arg1 AnonStruct) { + _swig_wrap_delete_AnonStruct(arg1.Swigcptr()) +} + +type AnonStruct interface { + Swigcptr() uintptr + SwigIsAnonStruct() +} + +type Colour int +var _wrap_red unsafe.Pointer + +func _swig_getred() (_swig_ret Colour) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_red, _swig_p) + return +} +var Red Colour = _swig_getred() +var _wrap_blue unsafe.Pointer + +func _swig_getblue() (_swig_ret Colour) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_blue, _swig_p) + return +} +var Blue Colour = _swig_getblue() +var _wrap_green unsafe.Pointer + +func _swig_getgreen() (_swig_ret Colour) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_green, _swig_p) + return +} +var Green Colour = _swig_getgreen() +var _wrap_colourTest1 unsafe.Pointer + +func ColourTest1(arg1 Colour) (_swig_ret Colour) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_colourTest1, _swig_p) + return +} +var _wrap_colourTest2 unsafe.Pointer + +func ColourTest2(arg1 Colour) (_swig_ret Colour) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_colourTest2, _swig_p) + return +} +var _wrap_colourTest3 unsafe.Pointer + +func ColourTest3(arg1 Colour) (_swig_ret Colour) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_colourTest3, _swig_p) + return +} +var _wrap_colourTest4 unsafe.Pointer + +func ColourTest4(arg1 Colour) (_swig_ret Colour) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_colourTest4, _swig_p) + return +} +var _wrap_myColour_set unsafe.Pointer + +func _swig_wrap_myColour_set(base Colour) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_myColour_set, _swig_p) + return +} + +func SetMyColour(arg1 Colour) { + _swig_wrap_myColour_set(arg1) +} + +var _wrap_myColour_get unsafe.Pointer + +func GetMyColour() (_swig_ret Colour) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_myColour_get, _swig_p) + return +} +type SwigcptrSpeedClass uintptr + +func (p SwigcptrSpeedClass) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrSpeedClass) SwigIsSpeedClass() { +} + +type SpeedClassSpeed int +var _wrap_slow_SpeedClass unsafe.Pointer + +func _swig_getSpeedClass_slow_SpeedClass() (_swig_ret SpeedClassSpeed) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_slow_SpeedClass, _swig_p) + return +} +var SpeedClassSlow SpeedClassSpeed = _swig_getSpeedClass_slow_SpeedClass() +var _wrap_medium_SpeedClass unsafe.Pointer + +func _swig_getSpeedClass_medium_SpeedClass() (_swig_ret SpeedClassSpeed) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_medium_SpeedClass, _swig_p) + return +} +var SpeedClassMedium SpeedClassSpeed = _swig_getSpeedClass_medium_SpeedClass() +var _wrap_fast_SpeedClass unsafe.Pointer + +func _swig_getSpeedClass_fast_SpeedClass() (_swig_ret SpeedClassSpeed) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_fast_SpeedClass, _swig_p) + return +} +var SpeedClassFast SpeedClassSpeed = _swig_getSpeedClass_fast_SpeedClass() +var _wrap_lightning_SpeedClass unsafe.Pointer + +func _swig_getSpeedClass_lightning_SpeedClass() (_swig_ret SpeedClassSpeed) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_lightning_SpeedClass, _swig_p) + return +} +var SpeedClassLightning SpeedClassSpeed = _swig_getSpeedClass_lightning_SpeedClass() +var _wrap_SpeedClass_speedTest0 unsafe.Pointer + +func _swig_wrap_SpeedClass_speedTest0(base SwigcptrSpeedClass, _ int) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_SpeedClass_speedTest0, _swig_p) + return +} + +func (arg1 SwigcptrSpeedClass) SpeedTest0(arg2 int) (_swig_ret int) { + return _swig_wrap_SpeedClass_speedTest0(arg1, arg2) +} + +var _wrap_SpeedClass_speedTest1 unsafe.Pointer + +func _swig_wrap_SpeedClass_speedTest1(base SwigcptrSpeedClass, _ SpeedClassSpeed) (_ SpeedClassSpeed) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_SpeedClass_speedTest1, _swig_p) + return +} + +func (arg1 SwigcptrSpeedClass) SpeedTest1(arg2 SpeedClassSpeed) (_swig_ret SpeedClassSpeed) { + return _swig_wrap_SpeedClass_speedTest1(arg1, arg2) +} + +var _wrap_SpeedClass_speedTest2 unsafe.Pointer + +func _swig_wrap_SpeedClass_speedTest2(base SwigcptrSpeedClass, _ SpeedClassSpeed) (_ SpeedClassSpeed) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_SpeedClass_speedTest2, _swig_p) + return +} + +func (arg1 SwigcptrSpeedClass) SpeedTest2(arg2 SpeedClassSpeed) (_swig_ret SpeedClassSpeed) { + return _swig_wrap_SpeedClass_speedTest2(arg1, arg2) +} + +var _wrap_SpeedClass_speedTest3 unsafe.Pointer + +func _swig_wrap_SpeedClass_speedTest3(base SwigcptrSpeedClass, _ SpeedClassSpeed) (_ SpeedClassSpeed) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_SpeedClass_speedTest3, _swig_p) + return +} + +func (arg1 SwigcptrSpeedClass) SpeedTest3(arg2 SpeedClassSpeed) (_swig_ret SpeedClassSpeed) { + return _swig_wrap_SpeedClass_speedTest3(arg1, arg2) +} + +var _wrap_SpeedClass_speedTest4 unsafe.Pointer + +func _swig_wrap_SpeedClass_speedTest4(base SwigcptrSpeedClass, _ SpeedClassSpeed) (_ SpeedClassSpeed) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_SpeedClass_speedTest4, _swig_p) + return +} + +func (arg1 SwigcptrSpeedClass) SpeedTest4(arg2 SpeedClassSpeed) (_swig_ret SpeedClassSpeed) { + return _swig_wrap_SpeedClass_speedTest4(arg1, arg2) +} + +var _wrap_SpeedClass_speedTest5 unsafe.Pointer + +func _swig_wrap_SpeedClass_speedTest5(base SwigcptrSpeedClass, _ SpeedClassSpeed) (_ SpeedClassSpeed) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_SpeedClass_speedTest5, _swig_p) + return +} + +func (arg1 SwigcptrSpeedClass) SpeedTest5(arg2 SpeedClassSpeed) (_swig_ret SpeedClassSpeed) { + return _swig_wrap_SpeedClass_speedTest5(arg1, arg2) +} + +var _wrap_SpeedClass_speedTest6 unsafe.Pointer + +func _swig_wrap_SpeedClass_speedTest6(base SwigcptrSpeedClass, _ SpeedClassSpeed) (_ SpeedClassSpeed) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_SpeedClass_speedTest6, _swig_p) + return +} + +func (arg1 SwigcptrSpeedClass) SpeedTest6(arg2 SpeedClassSpeed) (_swig_ret SpeedClassSpeed) { + return _swig_wrap_SpeedClass_speedTest6(arg1, arg2) +} + +var _wrap_SpeedClass_speedTest7 unsafe.Pointer + +func _swig_wrap_SpeedClass_speedTest7(base SwigcptrSpeedClass, _ *SpeedClassSpeed) (_ *SpeedClassSpeed) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_SpeedClass_speedTest7, _swig_p) + return +} + +func (arg1 SwigcptrSpeedClass) SpeedTest7(arg2 *SpeedClassSpeed) (_swig_ret *SpeedClassSpeed) { + return _swig_wrap_SpeedClass_speedTest7(arg1, arg2) +} + +var _wrap_SpeedClass_speedTest8 unsafe.Pointer + +func _swig_wrap_SpeedClass_speedTest8(base SwigcptrSpeedClass, _ *SpeedClassSpeed) (_ *SpeedClassSpeed) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_SpeedClass_speedTest8, _swig_p) + return +} + +func (arg1 SwigcptrSpeedClass) SpeedTest8(arg2 *SpeedClassSpeed) (_swig_ret *SpeedClassSpeed) { + return _swig_wrap_SpeedClass_speedTest8(arg1, arg2) +} + +var _wrap_SpeedClass_myColour2_get unsafe.Pointer + +func _swig_wrap_SpeedClass_myColour2_get(base SwigcptrSpeedClass) (_ Colour) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_SpeedClass_myColour2_get, _swig_p) + return +} + +func (arg1 SwigcptrSpeedClass) GetMyColour2() (_swig_ret Colour) { + return _swig_wrap_SpeedClass_myColour2_get(arg1) +} + +var _wrap_SpeedClass_mySpeedtd1_set unsafe.Pointer + +func _swig_wrap_SpeedClass_mySpeedtd1_set(base SwigcptrSpeedClass, _ SpeedClassSpeed) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_SpeedClass_mySpeedtd1_set, _swig_p) + return +} + +func (arg1 SwigcptrSpeedClass) SetMySpeedtd1(arg2 SpeedClassSpeed) { + _swig_wrap_SpeedClass_mySpeedtd1_set(arg1, arg2) +} + +var _wrap_SpeedClass_mySpeedtd1_get unsafe.Pointer + +func _swig_wrap_SpeedClass_mySpeedtd1_get(base SwigcptrSpeedClass) (_ SpeedClassSpeed) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_SpeedClass_mySpeedtd1_get, _swig_p) + return +} + +func (arg1 SwigcptrSpeedClass) GetMySpeedtd1() (_swig_ret SpeedClassSpeed) { + return _swig_wrap_SpeedClass_mySpeedtd1_get(arg1) +} + +var _wrap_new_SpeedClass unsafe.Pointer + +func _swig_wrap_new_SpeedClass() (base SwigcptrSpeedClass) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_SpeedClass, _swig_p) + return +} + +func NewSpeedClass() (_swig_ret SpeedClass) { + return _swig_wrap_new_SpeedClass() +} + +var _wrap_delete_SpeedClass unsafe.Pointer + +func _swig_wrap_delete_SpeedClass(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_SpeedClass, _swig_p) + return +} + +func DeleteSpeedClass(arg1 SpeedClass) { + _swig_wrap_delete_SpeedClass(arg1.Swigcptr()) +} + +type SpeedClass interface { + Swigcptr() uintptr + SwigIsSpeedClass() + SpeedTest0(arg2 int) (_swig_ret int) + SpeedTest1(arg2 SpeedClassSpeed) (_swig_ret SpeedClassSpeed) + SpeedTest2(arg2 SpeedClassSpeed) (_swig_ret SpeedClassSpeed) + SpeedTest3(arg2 SpeedClassSpeed) (_swig_ret SpeedClassSpeed) + SpeedTest4(arg2 SpeedClassSpeed) (_swig_ret SpeedClassSpeed) + SpeedTest5(arg2 SpeedClassSpeed) (_swig_ret SpeedClassSpeed) + SpeedTest6(arg2 SpeedClassSpeed) (_swig_ret SpeedClassSpeed) + SpeedTest7(arg2 *SpeedClassSpeed) (_swig_ret *SpeedClassSpeed) + SpeedTest8(arg2 *SpeedClassSpeed) (_swig_ret *SpeedClassSpeed) + GetMyColour2() (_swig_ret Colour) + SetMySpeedtd1(arg2 SpeedClassSpeed) + GetMySpeedtd1() (_swig_ret SpeedClassSpeed) +} + +var _wrap_speedTest0 unsafe.Pointer + +func SpeedTest0(arg1 int) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_speedTest0, _swig_p) + return +} +var _wrap_speedTest1 unsafe.Pointer + +func SpeedTest1(arg1 SpeedClassSpeed) (_swig_ret SpeedClassSpeed) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_speedTest1, _swig_p) + return +} +var _wrap_speedTest2 unsafe.Pointer + +func SpeedTest2(arg1 SpeedClassSpeed) (_swig_ret SpeedClassSpeed) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_speedTest2, _swig_p) + return +} +var _wrap_speedTest3 unsafe.Pointer + +func SpeedTest3(arg1 SpeedClassSpeed) (_swig_ret SpeedClassSpeed) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_speedTest3, _swig_p) + return +} +var _wrap_speedTest4 unsafe.Pointer + +func SpeedTest4(arg1 SpeedClassSpeed) (_swig_ret SpeedClassSpeed) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_speedTest4, _swig_p) + return +} +var _wrap_speedTest5 unsafe.Pointer + +func SpeedTest5(arg1 *SpeedClassSpeed) (_swig_ret *SpeedClassSpeed) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_speedTest5, _swig_p) + return +} +type Namedanon int +var _wrap_NamedAnon1 unsafe.Pointer + +func _swig_getNamedAnon1() (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_NamedAnon1, _swig_p) + return +} +var NamedAnon1 int = _swig_getNamedAnon1() +var _wrap_NamedAnon2 unsafe.Pointer + +func _swig_getNamedAnon2() (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_NamedAnon2, _swig_p) + return +} +var NamedAnon2 int = _swig_getNamedAnon2() +var _wrap_namedanonTest1 unsafe.Pointer + +func NamedanonTest1(arg1 Namedanon) (_swig_ret Namedanon) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_namedanonTest1, _swig_p) + return +} +type Twonamestag int +var _wrap_TwoNames1 unsafe.Pointer + +func _swig_getTwoNames1() (_swig_ret Twonamestag) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_TwoNames1, _swig_p) + return +} +var TwoNames1 Twonamestag = _swig_getTwoNames1() +var _wrap_TwoNames2 unsafe.Pointer + +func _swig_getTwoNames2() (_swig_ret Twonamestag) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_TwoNames2, _swig_p) + return +} +var TwoNames2 Twonamestag = _swig_getTwoNames2() +var _wrap_TwoNames3 unsafe.Pointer + +func _swig_getTwoNames3() (_swig_ret Twonamestag) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_TwoNames3, _swig_p) + return +} +var TwoNames3 Twonamestag = _swig_getTwoNames3() +var _wrap_twonamesTest1 unsafe.Pointer + +func TwonamesTest1(arg1 Twonamestag) (_swig_ret Twonamestag) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_twonamesTest1, _swig_p) + return +} +var _wrap_twonamesTest2 unsafe.Pointer + +func TwonamesTest2(arg1 Twonamestag) (_swig_ret Twonamestag) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_twonamesTest2, _swig_p) + return +} +var _wrap_twonamesTest3 unsafe.Pointer + +func TwonamesTest3(arg1 Twonamestag) (_swig_ret Twonamestag) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_twonamesTest3, _swig_p) + return +} +type SwigcptrTwoNamesStruct uintptr + +func (p SwigcptrTwoNamesStruct) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrTwoNamesStruct) SwigIsTwoNamesStruct() { +} + +type TwoNamesStructTwonamestag int +var _wrap_TwoNamesStruct1_TwoNamesStruct unsafe.Pointer + +func _swig_getTwoNamesStruct_TwoNamesStruct1_TwoNamesStruct() (_swig_ret TwoNamesStructTwonamestag) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_TwoNamesStruct1_TwoNamesStruct, _swig_p) + return +} +var TwoNamesStructTwoNamesStruct1 TwoNamesStructTwonamestag = _swig_getTwoNamesStruct_TwoNamesStruct1_TwoNamesStruct() +var _wrap_TwoNamesStruct2_TwoNamesStruct unsafe.Pointer + +func _swig_getTwoNamesStruct_TwoNamesStruct2_TwoNamesStruct() (_swig_ret TwoNamesStructTwonamestag) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_TwoNamesStruct2_TwoNamesStruct, _swig_p) + return +} +var TwoNamesStructTwoNamesStruct2 TwoNamesStructTwonamestag = _swig_getTwoNamesStruct_TwoNamesStruct2_TwoNamesStruct() +var _wrap_TwoNamesStruct_twonamesTest1 unsafe.Pointer + +func _swig_wrap_TwoNamesStruct_twonamesTest1(base SwigcptrTwoNamesStruct, _ TwoNamesStructTwonamestag) (_ TwoNamesStructTwonamestag) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_TwoNamesStruct_twonamesTest1, _swig_p) + return +} + +func (arg1 SwigcptrTwoNamesStruct) TwonamesTest1(arg2 TwoNamesStructTwonamestag) (_swig_ret TwoNamesStructTwonamestag) { + return _swig_wrap_TwoNamesStruct_twonamesTest1(arg1, arg2) +} + +var _wrap_TwoNamesStruct_twonamesTest2 unsafe.Pointer + +func _swig_wrap_TwoNamesStruct_twonamesTest2(base SwigcptrTwoNamesStruct, _ TwoNamesStructTwonamestag) (_ TwoNamesStructTwonamestag) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_TwoNamesStruct_twonamesTest2, _swig_p) + return +} + +func (arg1 SwigcptrTwoNamesStruct) TwonamesTest2(arg2 TwoNamesStructTwonamestag) (_swig_ret TwoNamesStructTwonamestag) { + return _swig_wrap_TwoNamesStruct_twonamesTest2(arg1, arg2) +} + +var _wrap_TwoNamesStruct_twonamesTest3 unsafe.Pointer + +func _swig_wrap_TwoNamesStruct_twonamesTest3(base SwigcptrTwoNamesStruct, _ TwoNamesStructTwonamestag) (_ TwoNamesStructTwonamestag) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_TwoNamesStruct_twonamesTest3, _swig_p) + return +} + +func (arg1 SwigcptrTwoNamesStruct) TwonamesTest3(arg2 TwoNamesStructTwonamestag) (_swig_ret TwoNamesStructTwonamestag) { + return _swig_wrap_TwoNamesStruct_twonamesTest3(arg1, arg2) +} + +var _wrap_new_TwoNamesStruct unsafe.Pointer + +func _swig_wrap_new_TwoNamesStruct() (base SwigcptrTwoNamesStruct) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_TwoNamesStruct, _swig_p) + return +} + +func NewTwoNamesStruct() (_swig_ret TwoNamesStruct) { + return _swig_wrap_new_TwoNamesStruct() +} + +var _wrap_delete_TwoNamesStruct unsafe.Pointer + +func _swig_wrap_delete_TwoNamesStruct(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_TwoNamesStruct, _swig_p) + return +} + +func DeleteTwoNamesStruct(arg1 TwoNamesStruct) { + _swig_wrap_delete_TwoNamesStruct(arg1.Swigcptr()) +} + +type TwoNamesStruct interface { + Swigcptr() uintptr + SwigIsTwoNamesStruct() + TwonamesTest1(arg2 TwoNamesStructTwonamestag) (_swig_ret TwoNamesStructTwonamestag) + TwonamesTest2(arg2 TwoNamesStructTwonamestag) (_swig_ret TwoNamesStructTwonamestag) + TwonamesTest3(arg2 TwoNamesStructTwonamestag) (_swig_ret TwoNamesStructTwonamestag) +} + +type AnonSpaceNamedanonspace int +var _wrap_NamedAnonSpace1 unsafe.Pointer + +func _swig_getNamedAnonSpace1() (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_NamedAnonSpace1, _swig_p) + return +} +var NamedAnonSpace1 int = _swig_getNamedAnonSpace1() +var _wrap_NamedAnonSpace2 unsafe.Pointer + +func _swig_getNamedAnonSpace2() (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_NamedAnonSpace2, _swig_p) + return +} +var NamedAnonSpace2 int = _swig_getNamedAnonSpace2() +var _wrap_namedanonspaceTest1 unsafe.Pointer + +func NamedanonspaceTest1(arg1 AnonSpaceNamedanonspace) (_swig_ret AnonSpaceNamedanonspace) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_namedanonspaceTest1, _swig_p) + return +} +var _wrap_namedanonspaceTest2 unsafe.Pointer + +func NamedanonspaceTest2(arg1 AnonSpaceNamedanonspace) (_swig_ret AnonSpaceNamedanonspace) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_namedanonspaceTest2, _swig_p) + return +} +var _wrap_namedanonspaceTest3 unsafe.Pointer + +func NamedanonspaceTest3(arg1 AnonSpaceNamedanonspace) (_swig_ret AnonSpaceNamedanonspace) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_namedanonspaceTest3, _swig_p) + return +} +var _wrap_namedanonspaceTest4 unsafe.Pointer + +func NamedanonspaceTest4(arg1 AnonSpaceNamedanonspace) (_swig_ret AnonSpaceNamedanonspace) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_namedanonspaceTest4, _swig_p) + return +} +var _wrap_scientistsTest1 unsafe.Pointer + +func ScientistsTest1(arg1 TemplateClass_Sl_int_Sg_Scientists) (_swig_ret TemplateClass_Sl_int_Sg_Scientists) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_scientistsTest1, _swig_p) + return +} +var _wrap_scientistsTest2 unsafe.Pointer + +func ScientistsTest2(arg1 TemplateClass_Sl_int_Sg_Scientists) (_swig_ret TemplateClass_Sl_int_Sg_Scientists) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_scientistsTest2, _swig_p) + return +} +var _wrap_scientistsTest3 unsafe.Pointer + +func ScientistsTest3(arg1 TemplateClass_Sl_int_Sg_Scientists) (_swig_ret TemplateClass_Sl_int_Sg_Scientists) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_scientistsTest3, _swig_p) + return +} +var _wrap_scientistsTest4 unsafe.Pointer + +func ScientistsTest4(arg1 TemplateClass_Sl_int_Sg_Scientists) (_swig_ret TemplateClass_Sl_int_Sg_Scientists) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_scientistsTest4, _swig_p) + return +} +var _wrap_scientistsTest5 unsafe.Pointer + +func ScientistsTest5(arg1 TemplateClass_Sl_int_Sg_Scientists) (_swig_ret TemplateClass_Sl_int_Sg_Scientists) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_scientistsTest5, _swig_p) + return +} +var _wrap_scientistsTest6 unsafe.Pointer + +func ScientistsTest6(arg1 TemplateClass_Sl_int_Sg_Scientists) (_swig_ret TemplateClass_Sl_int_Sg_Scientists) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_scientistsTest6, _swig_p) + return +} +var _wrap_scientistsTest7 unsafe.Pointer + +func ScientistsTest7(arg1 TemplateClass_Sl_int_Sg_Scientists) (_swig_ret TemplateClass_Sl_int_Sg_Scientists) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_scientistsTest7, _swig_p) + return +} +var _wrap_scientistsTest8 unsafe.Pointer + +func ScientistsTest8(arg1 *TemplateClass_Sl_int_Sg_Scientists) (_swig_ret *TemplateClass_Sl_int_Sg_Scientists) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_scientistsTest8, _swig_p) + return +} +var _wrap_scientistsNameTest1 unsafe.Pointer + +func ScientistsNameTest1(arg1 NameTClass_Sl_int_Sg_Scientists) (_swig_ret NameTClass_Sl_int_Sg_Scientists) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_scientistsNameTest1, _swig_p) + return +} +var _wrap_scientistsNameTest2 unsafe.Pointer + +func ScientistsNameTest2(arg1 NameTClass_Sl_int_Sg_Scientists) (_swig_ret NameTClass_Sl_int_Sg_Scientists) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_scientistsNameTest2, _swig_p) + return +} +var _wrap_scientistsNameTest3 unsafe.Pointer + +func ScientistsNameTest3(arg1 NameTClass_Sl_int_Sg_Scientists) (_swig_ret NameTClass_Sl_int_Sg_Scientists) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_scientistsNameTest3, _swig_p) + return +} +var _wrap_scientistsNameTest4 unsafe.Pointer + +func ScientistsNameTest4(arg1 NameTClass_Sl_int_Sg_Scientists) (_swig_ret NameTClass_Sl_int_Sg_Scientists) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_scientistsNameTest4, _swig_p) + return +} +var _wrap_scientistsNameTest5 unsafe.Pointer + +func ScientistsNameTest5(arg1 NameTClass_Sl_int_Sg_Scientists) (_swig_ret NameTClass_Sl_int_Sg_Scientists) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_scientistsNameTest5, _swig_p) + return +} +var _wrap_scientistsNameTest6 unsafe.Pointer + +func ScientistsNameTest6(arg1 NameTClass_Sl_int_Sg_Scientists) (_swig_ret NameTClass_Sl_int_Sg_Scientists) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_scientistsNameTest6, _swig_p) + return +} +var _wrap_scientistsNameTest7 unsafe.Pointer + +func ScientistsNameTest7(arg1 NameTClass_Sl_int_Sg_Scientists) (_swig_ret NameTClass_Sl_int_Sg_Scientists) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_scientistsNameTest7, _swig_p) + return +} +var _wrap_scientistsNameSpaceTest1 unsafe.Pointer + +func ScientistsNameSpaceTest1(arg1 NameTClass_Sl_int_Sg_Scientists) (_swig_ret NameTClass_Sl_int_Sg_Scientists) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_scientistsNameSpaceTest1, _swig_p) + return +} +var _wrap_scientistsNameSpaceTest2 unsafe.Pointer + +func ScientistsNameSpaceTest2(arg1 NameTClass_Sl_int_Sg_Scientists) (_swig_ret NameTClass_Sl_int_Sg_Scientists) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_scientistsNameSpaceTest2, _swig_p) + return +} +var _wrap_scientistsNameSpaceTest3 unsafe.Pointer + +func ScientistsNameSpaceTest3(arg1 NameTClass_Sl_int_Sg_Scientists) (_swig_ret NameTClass_Sl_int_Sg_Scientists) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_scientistsNameSpaceTest3, _swig_p) + return +} +var _wrap_scientistsNameSpaceTest4 unsafe.Pointer + +func ScientistsNameSpaceTest4(arg1 NameTClass_Sl_int_Sg_Scientists) (_swig_ret NameTClass_Sl_int_Sg_Scientists) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_scientistsNameSpaceTest4, _swig_p) + return +} +var _wrap_scientistsNameSpaceTest5 unsafe.Pointer + +func ScientistsNameSpaceTest5(arg1 NameTClass_Sl_int_Sg_Scientists) (_swig_ret NameTClass_Sl_int_Sg_Scientists) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_scientistsNameSpaceTest5, _swig_p) + return +} +var _wrap_scientistsNameSpaceTest6 unsafe.Pointer + +func ScientistsNameSpaceTest6(arg1 NameTClass_Sl_int_Sg_Scientists) (_swig_ret NameTClass_Sl_int_Sg_Scientists) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_scientistsNameSpaceTest6, _swig_p) + return +} +var _wrap_scientistsNameSpaceTest7 unsafe.Pointer + +func ScientistsNameSpaceTest7(arg1 NameTClass_Sl_int_Sg_Scientists) (_swig_ret NameTClass_Sl_int_Sg_Scientists) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_scientistsNameSpaceTest7, _swig_p) + return +} +var _wrap_scientistsNameSpaceTest8 unsafe.Pointer + +func ScientistsNameSpaceTest8(arg1 NameTClass_Sl_int_Sg_Scientists) (_swig_ret NameTClass_Sl_int_Sg_Scientists) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_scientistsNameSpaceTest8, _swig_p) + return +} +var _wrap_scientistsNameSpaceTest9 unsafe.Pointer + +func ScientistsNameSpaceTest9(arg1 NameTClass_Sl_int_Sg_Scientists) (_swig_ret NameTClass_Sl_int_Sg_Scientists) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_scientistsNameSpaceTest9, _swig_p) + return +} +var _wrap_scientistsNameSpaceTestA unsafe.Pointer + +func ScientistsNameSpaceTestA(arg1 NameTClass_Sl_int_Sg_Scientists) (_swig_ret NameTClass_Sl_int_Sg_Scientists) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_scientistsNameSpaceTestA, _swig_p) + return +} +var _wrap_scientistsNameSpaceTestB unsafe.Pointer + +func ScientistsNameSpaceTestB(arg1 NameTClass_Sl_int_Sg_Scientists) (_swig_ret NameTClass_Sl_int_Sg_Scientists) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_scientistsNameSpaceTestB, _swig_p) + return +} +var _wrap_scientistsNameSpaceTestC unsafe.Pointer + +func ScientistsNameSpaceTestC(arg1 NameTClass_Sl_int_Sg_Scientists) (_swig_ret NameTClass_Sl_int_Sg_Scientists) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_scientistsNameSpaceTestC, _swig_p) + return +} +var _wrap_scientistsNameSpaceTestD unsafe.Pointer + +func ScientistsNameSpaceTestD(arg1 NameTClass_Sl_int_Sg_Scientists) (_swig_ret NameTClass_Sl_int_Sg_Scientists) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_scientistsNameSpaceTestD, _swig_p) + return +} +var _wrap_scientistsNameSpaceTestE unsafe.Pointer + +func ScientistsNameSpaceTestE(arg1 NameTClass_Sl_int_Sg_Scientists) (_swig_ret NameTClass_Sl_int_Sg_Scientists) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_scientistsNameSpaceTestE, _swig_p) + return +} +var _wrap_scientistsNameSpaceTestF unsafe.Pointer + +func ScientistsNameSpaceTestF(arg1 NameTClass_Sl_int_Sg_Scientists) (_swig_ret NameTClass_Sl_int_Sg_Scientists) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_scientistsNameSpaceTestF, _swig_p) + return +} +var _wrap_scientistsNameSpaceTestG unsafe.Pointer + +func ScientistsNameSpaceTestG(arg1 NameTClass_Sl_int_Sg_Scientists) (_swig_ret NameTClass_Sl_int_Sg_Scientists) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_scientistsNameSpaceTestG, _swig_p) + return +} +var _wrap_scientistsNameSpaceTestH unsafe.Pointer + +func ScientistsNameSpaceTestH(arg1 NameTClass_Sl_int_Sg_Scientists) (_swig_ret NameTClass_Sl_int_Sg_Scientists) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_scientistsNameSpaceTestH, _swig_p) + return +} +var _wrap_scientistsNameSpaceTestI unsafe.Pointer + +func ScientistsNameSpaceTestI(arg1 NameTClass_Sl_int_Sg_Scientists) (_swig_ret NameTClass_Sl_int_Sg_Scientists) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_scientistsNameSpaceTestI, _swig_p) + return +} +var _wrap_scientistsNameSpaceTestJ unsafe.Pointer + +func ScientistsNameSpaceTestJ(arg1 NameTClass_Sl_int_Sg_Scientists) (_swig_ret NameTClass_Sl_int_Sg_Scientists) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_scientistsNameSpaceTestJ, _swig_p) + return +} +var _wrap_scientistsNameSpaceTestK unsafe.Pointer + +func ScientistsNameSpaceTestK(arg1 NameTClass_Sl_int_Sg_Scientists) (_swig_ret NameTClass_Sl_int_Sg_Scientists) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_scientistsNameSpaceTestK, _swig_p) + return +} +var _wrap_scientistsNameSpaceTestL unsafe.Pointer + +func ScientistsNameSpaceTestL(arg1 NameTClass_Sl_int_Sg_Scientists) (_swig_ret NameTClass_Sl_int_Sg_Scientists) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_scientistsNameSpaceTestL, _swig_p) + return +} +type SwigcptrTemplateClassInt uintptr + +func (p SwigcptrTemplateClassInt) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrTemplateClassInt) SwigIsTemplateClassInt() { +} + +type TemplateClass_Sl_int_Sg_Scientists int +var _wrap_einstein_TemplateClassInt unsafe.Pointer + +func _swig_getTemplateClassInt_einstein_TemplateClassInt() (_swig_ret TemplateClass_Sl_int_Sg_Scientists) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_einstein_TemplateClassInt, _swig_p) + return +} +var TemplateClassIntEinstein TemplateClass_Sl_int_Sg_Scientists = _swig_getTemplateClassInt_einstein_TemplateClassInt() +var _wrap_galileo_TemplateClassInt unsafe.Pointer + +func _swig_getTemplateClassInt_galileo_TemplateClassInt() (_swig_ret TemplateClass_Sl_int_Sg_Scientists) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_galileo_TemplateClassInt, _swig_p) + return +} +var TemplateClassIntGalileo TemplateClass_Sl_int_Sg_Scientists = _swig_getTemplateClassInt_galileo_TemplateClassInt() +var _wrap_TemplateClassInt_scientistsTest1 unsafe.Pointer + +func _swig_wrap_TemplateClassInt_scientistsTest1(base SwigcptrTemplateClassInt, _ TemplateClass_Sl_int_Sg_Scientists) (_ TemplateClass_Sl_int_Sg_Scientists) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_TemplateClassInt_scientistsTest1, _swig_p) + return +} + +func (arg1 SwigcptrTemplateClassInt) ScientistsTest1(arg2 TemplateClass_Sl_int_Sg_Scientists) (_swig_ret TemplateClass_Sl_int_Sg_Scientists) { + return _swig_wrap_TemplateClassInt_scientistsTest1(arg1, arg2) +} + +var _wrap_TemplateClassInt_scientistsTest2 unsafe.Pointer + +func _swig_wrap_TemplateClassInt_scientistsTest2(base SwigcptrTemplateClassInt, _ TemplateClass_Sl_int_Sg_Scientists) (_ TemplateClass_Sl_int_Sg_Scientists) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_TemplateClassInt_scientistsTest2, _swig_p) + return +} + +func (arg1 SwigcptrTemplateClassInt) ScientistsTest2(arg2 TemplateClass_Sl_int_Sg_Scientists) (_swig_ret TemplateClass_Sl_int_Sg_Scientists) { + return _swig_wrap_TemplateClassInt_scientistsTest2(arg1, arg2) +} + +var _wrap_TemplateClassInt_scientistsTest3 unsafe.Pointer + +func _swig_wrap_TemplateClassInt_scientistsTest3(base SwigcptrTemplateClassInt, _ TemplateClass_Sl_int_Sg_Scientists) (_ TemplateClass_Sl_int_Sg_Scientists) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_TemplateClassInt_scientistsTest3, _swig_p) + return +} + +func (arg1 SwigcptrTemplateClassInt) ScientistsTest3(arg2 TemplateClass_Sl_int_Sg_Scientists) (_swig_ret TemplateClass_Sl_int_Sg_Scientists) { + return _swig_wrap_TemplateClassInt_scientistsTest3(arg1, arg2) +} + +var _wrap_TemplateClassInt_scientistsTest4 unsafe.Pointer + +func _swig_wrap_TemplateClassInt_scientistsTest4(base SwigcptrTemplateClassInt, _ TemplateClass_Sl_int_Sg_Scientists) (_ TemplateClass_Sl_int_Sg_Scientists) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_TemplateClassInt_scientistsTest4, _swig_p) + return +} + +func (arg1 SwigcptrTemplateClassInt) ScientistsTest4(arg2 TemplateClass_Sl_int_Sg_Scientists) (_swig_ret TemplateClass_Sl_int_Sg_Scientists) { + return _swig_wrap_TemplateClassInt_scientistsTest4(arg1, arg2) +} + +var _wrap_TemplateClassInt_scientistsTest5 unsafe.Pointer + +func _swig_wrap_TemplateClassInt_scientistsTest5(base SwigcptrTemplateClassInt, _ TemplateClass_Sl_int_Sg_Scientists) (_ TemplateClass_Sl_int_Sg_Scientists) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_TemplateClassInt_scientistsTest5, _swig_p) + return +} + +func (arg1 SwigcptrTemplateClassInt) ScientistsTest5(arg2 TemplateClass_Sl_int_Sg_Scientists) (_swig_ret TemplateClass_Sl_int_Sg_Scientists) { + return _swig_wrap_TemplateClassInt_scientistsTest5(arg1, arg2) +} + +var _wrap_TemplateClassInt_scientistsTest6 unsafe.Pointer + +func _swig_wrap_TemplateClassInt_scientistsTest6(base SwigcptrTemplateClassInt, _ TemplateClass_Sl_int_Sg_Scientists) (_ TemplateClass_Sl_int_Sg_Scientists) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_TemplateClassInt_scientistsTest6, _swig_p) + return +} + +func (arg1 SwigcptrTemplateClassInt) ScientistsTest6(arg2 TemplateClass_Sl_int_Sg_Scientists) (_swig_ret TemplateClass_Sl_int_Sg_Scientists) { + return _swig_wrap_TemplateClassInt_scientistsTest6(arg1, arg2) +} + +var _wrap_TemplateClassInt_scientistsTest7 unsafe.Pointer + +func _swig_wrap_TemplateClassInt_scientistsTest7(base SwigcptrTemplateClassInt, _ TemplateClass_Sl_int_Sg_Scientists) (_ TemplateClass_Sl_int_Sg_Scientists) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_TemplateClassInt_scientistsTest7, _swig_p) + return +} + +func (arg1 SwigcptrTemplateClassInt) ScientistsTest7(arg2 TemplateClass_Sl_int_Sg_Scientists) (_swig_ret TemplateClass_Sl_int_Sg_Scientists) { + return _swig_wrap_TemplateClassInt_scientistsTest7(arg1, arg2) +} + +var _wrap_TemplateClassInt_scientistsTest8 unsafe.Pointer + +func _swig_wrap_TemplateClassInt_scientistsTest8(base SwigcptrTemplateClassInt, _ TemplateClass_Sl_int_Sg_Scientists) (_ TemplateClass_Sl_int_Sg_Scientists) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_TemplateClassInt_scientistsTest8, _swig_p) + return +} + +func (arg1 SwigcptrTemplateClassInt) ScientistsTest8(arg2 TemplateClass_Sl_int_Sg_Scientists) (_swig_ret TemplateClass_Sl_int_Sg_Scientists) { + return _swig_wrap_TemplateClassInt_scientistsTest8(arg1, arg2) +} + +var _wrap_TemplateClassInt_scientistsTest9 unsafe.Pointer + +func _swig_wrap_TemplateClassInt_scientistsTest9(base SwigcptrTemplateClassInt, _ TemplateClass_Sl_int_Sg_Scientists) (_ TemplateClass_Sl_int_Sg_Scientists) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_TemplateClassInt_scientistsTest9, _swig_p) + return +} + +func (arg1 SwigcptrTemplateClassInt) ScientistsTest9(arg2 TemplateClass_Sl_int_Sg_Scientists) (_swig_ret TemplateClass_Sl_int_Sg_Scientists) { + return _swig_wrap_TemplateClassInt_scientistsTest9(arg1, arg2) +} + +var _wrap_TemplateClassInt_scientistsTestB unsafe.Pointer + +func _swig_wrap_TemplateClassInt_scientistsTestB(base SwigcptrTemplateClassInt, _ TemplateClass_Sl_int_Sg_Scientists) (_ TemplateClass_Sl_int_Sg_Scientists) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_TemplateClassInt_scientistsTestB, _swig_p) + return +} + +func (arg1 SwigcptrTemplateClassInt) ScientistsTestB(arg2 TemplateClass_Sl_int_Sg_Scientists) (_swig_ret TemplateClass_Sl_int_Sg_Scientists) { + return _swig_wrap_TemplateClassInt_scientistsTestB(arg1, arg2) +} + +var _wrap_TemplateClassInt_scientistsTestD unsafe.Pointer + +func _swig_wrap_TemplateClassInt_scientistsTestD(base SwigcptrTemplateClassInt, _ TemplateClass_Sl_int_Sg_Scientists) (_ TemplateClass_Sl_int_Sg_Scientists) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_TemplateClassInt_scientistsTestD, _swig_p) + return +} + +func (arg1 SwigcptrTemplateClassInt) ScientistsTestD(arg2 TemplateClass_Sl_int_Sg_Scientists) (_swig_ret TemplateClass_Sl_int_Sg_Scientists) { + return _swig_wrap_TemplateClassInt_scientistsTestD(arg1, arg2) +} + +var _wrap_TemplateClassInt_scientistsTestE unsafe.Pointer + +func _swig_wrap_TemplateClassInt_scientistsTestE(base SwigcptrTemplateClassInt, _ TemplateClass_Sl_int_Sg_Scientists) (_ TemplateClass_Sl_int_Sg_Scientists) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_TemplateClassInt_scientistsTestE, _swig_p) + return +} + +func (arg1 SwigcptrTemplateClassInt) ScientistsTestE(arg2 TemplateClass_Sl_int_Sg_Scientists) (_swig_ret TemplateClass_Sl_int_Sg_Scientists) { + return _swig_wrap_TemplateClassInt_scientistsTestE(arg1, arg2) +} + +var _wrap_TemplateClassInt_scientistsTestF unsafe.Pointer + +func _swig_wrap_TemplateClassInt_scientistsTestF(base SwigcptrTemplateClassInt, _ TemplateClass_Sl_int_Sg_Scientists) (_ TemplateClass_Sl_int_Sg_Scientists) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_TemplateClassInt_scientistsTestF, _swig_p) + return +} + +func (arg1 SwigcptrTemplateClassInt) ScientistsTestF(arg2 TemplateClass_Sl_int_Sg_Scientists) (_swig_ret TemplateClass_Sl_int_Sg_Scientists) { + return _swig_wrap_TemplateClassInt_scientistsTestF(arg1, arg2) +} + +var _wrap_TemplateClassInt_scientistsTestG unsafe.Pointer + +func _swig_wrap_TemplateClassInt_scientistsTestG(base SwigcptrTemplateClassInt, _ TemplateClass_Sl_int_Sg_Scientists) (_ TemplateClass_Sl_int_Sg_Scientists) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_TemplateClassInt_scientistsTestG, _swig_p) + return +} + +func (arg1 SwigcptrTemplateClassInt) ScientistsTestG(arg2 TemplateClass_Sl_int_Sg_Scientists) (_swig_ret TemplateClass_Sl_int_Sg_Scientists) { + return _swig_wrap_TemplateClassInt_scientistsTestG(arg1, arg2) +} + +var _wrap_TemplateClassInt_scientistsTestH unsafe.Pointer + +func _swig_wrap_TemplateClassInt_scientistsTestH(base SwigcptrTemplateClassInt, _ TemplateClass_Sl_int_Sg_Scientists) (_ TemplateClass_Sl_int_Sg_Scientists) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_TemplateClassInt_scientistsTestH, _swig_p) + return +} + +func (arg1 SwigcptrTemplateClassInt) ScientistsTestH(arg2 TemplateClass_Sl_int_Sg_Scientists) (_swig_ret TemplateClass_Sl_int_Sg_Scientists) { + return _swig_wrap_TemplateClassInt_scientistsTestH(arg1, arg2) +} + +var _wrap_TemplateClassInt_scientistsTestI unsafe.Pointer + +func _swig_wrap_TemplateClassInt_scientistsTestI(base SwigcptrTemplateClassInt, _ TemplateClass_Sl_int_Sg_Scientists) (_ TemplateClass_Sl_int_Sg_Scientists) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_TemplateClassInt_scientistsTestI, _swig_p) + return +} + +func (arg1 SwigcptrTemplateClassInt) ScientistsTestI(arg2 TemplateClass_Sl_int_Sg_Scientists) (_swig_ret TemplateClass_Sl_int_Sg_Scientists) { + return _swig_wrap_TemplateClassInt_scientistsTestI(arg1, arg2) +} + +var _wrap_TemplateClassInt_scientistsTestJ unsafe.Pointer + +func _swig_wrap_TemplateClassInt_scientistsTestJ(base SwigcptrTemplateClassInt, _ *TemplateClass_Sl_int_Sg_Scientists) (_ *TemplateClass_Sl_int_Sg_Scientists) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_TemplateClassInt_scientistsTestJ, _swig_p) + return +} + +func (arg1 SwigcptrTemplateClassInt) ScientistsTestJ(arg2 *TemplateClass_Sl_int_Sg_Scientists) (_swig_ret *TemplateClass_Sl_int_Sg_Scientists) { + return _swig_wrap_TemplateClassInt_scientistsTestJ(arg1, arg2) +} + +var _wrap_new_TemplateClassInt unsafe.Pointer + +func _swig_wrap_new_TemplateClassInt() (base SwigcptrTemplateClassInt) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_TemplateClassInt, _swig_p) + return +} + +func NewTemplateClassInt() (_swig_ret TemplateClassInt) { + return _swig_wrap_new_TemplateClassInt() +} + +var _wrap_delete_TemplateClassInt unsafe.Pointer + +func _swig_wrap_delete_TemplateClassInt(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_TemplateClassInt, _swig_p) + return +} + +func DeleteTemplateClassInt(arg1 TemplateClassInt) { + _swig_wrap_delete_TemplateClassInt(arg1.Swigcptr()) +} + +type TemplateClassInt interface { + Swigcptr() uintptr + SwigIsTemplateClassInt() + ScientistsTest1(arg2 TemplateClass_Sl_int_Sg_Scientists) (_swig_ret TemplateClass_Sl_int_Sg_Scientists) + ScientistsTest2(arg2 TemplateClass_Sl_int_Sg_Scientists) (_swig_ret TemplateClass_Sl_int_Sg_Scientists) + ScientistsTest3(arg2 TemplateClass_Sl_int_Sg_Scientists) (_swig_ret TemplateClass_Sl_int_Sg_Scientists) + ScientistsTest4(arg2 TemplateClass_Sl_int_Sg_Scientists) (_swig_ret TemplateClass_Sl_int_Sg_Scientists) + ScientistsTest5(arg2 TemplateClass_Sl_int_Sg_Scientists) (_swig_ret TemplateClass_Sl_int_Sg_Scientists) + ScientistsTest6(arg2 TemplateClass_Sl_int_Sg_Scientists) (_swig_ret TemplateClass_Sl_int_Sg_Scientists) + ScientistsTest7(arg2 TemplateClass_Sl_int_Sg_Scientists) (_swig_ret TemplateClass_Sl_int_Sg_Scientists) + ScientistsTest8(arg2 TemplateClass_Sl_int_Sg_Scientists) (_swig_ret TemplateClass_Sl_int_Sg_Scientists) + ScientistsTest9(arg2 TemplateClass_Sl_int_Sg_Scientists) (_swig_ret TemplateClass_Sl_int_Sg_Scientists) + ScientistsTestB(arg2 TemplateClass_Sl_int_Sg_Scientists) (_swig_ret TemplateClass_Sl_int_Sg_Scientists) + ScientistsTestD(arg2 TemplateClass_Sl_int_Sg_Scientists) (_swig_ret TemplateClass_Sl_int_Sg_Scientists) + ScientistsTestE(arg2 TemplateClass_Sl_int_Sg_Scientists) (_swig_ret TemplateClass_Sl_int_Sg_Scientists) + ScientistsTestF(arg2 TemplateClass_Sl_int_Sg_Scientists) (_swig_ret TemplateClass_Sl_int_Sg_Scientists) + ScientistsTestG(arg2 TemplateClass_Sl_int_Sg_Scientists) (_swig_ret TemplateClass_Sl_int_Sg_Scientists) + ScientistsTestH(arg2 TemplateClass_Sl_int_Sg_Scientists) (_swig_ret TemplateClass_Sl_int_Sg_Scientists) + ScientistsTestI(arg2 TemplateClass_Sl_int_Sg_Scientists) (_swig_ret TemplateClass_Sl_int_Sg_Scientists) + ScientistsTestJ(arg2 *TemplateClass_Sl_int_Sg_Scientists) (_swig_ret *TemplateClass_Sl_int_Sg_Scientists) +} + +type SwigcptrTClassInt uintptr + +func (p SwigcptrTClassInt) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrTClassInt) SwigIsTClassInt() { +} + +type NameTClass_Sl_int_Sg_Scientists int +var _wrap_faraday_TClassInt unsafe.Pointer + +func _swig_getTClassInt_faraday_TClassInt() (_swig_ret NameTClass_Sl_int_Sg_Scientists) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_faraday_TClassInt, _swig_p) + return +} +var TClassIntFaraday NameTClass_Sl_int_Sg_Scientists = _swig_getTClassInt_faraday_TClassInt() +var _wrap_bell_TClassInt unsafe.Pointer + +func _swig_getTClassInt_bell_TClassInt() (_swig_ret NameTClass_Sl_int_Sg_Scientists) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_bell_TClassInt, _swig_p) + return +} +var TClassIntBell NameTClass_Sl_int_Sg_Scientists = _swig_getTClassInt_bell_TClassInt() +var _wrap_TClassInt_scientistsNameTest1 unsafe.Pointer + +func _swig_wrap_TClassInt_scientistsNameTest1(base SwigcptrTClassInt, _ NameTClass_Sl_int_Sg_Scientists) (_ NameTClass_Sl_int_Sg_Scientists) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_TClassInt_scientistsNameTest1, _swig_p) + return +} + +func (arg1 SwigcptrTClassInt) ScientistsNameTest1(arg2 NameTClass_Sl_int_Sg_Scientists) (_swig_ret NameTClass_Sl_int_Sg_Scientists) { + return _swig_wrap_TClassInt_scientistsNameTest1(arg1, arg2) +} + +var _wrap_TClassInt_scientistsNameTest2 unsafe.Pointer + +func _swig_wrap_TClassInt_scientistsNameTest2(base SwigcptrTClassInt, _ NameTClass_Sl_int_Sg_Scientists) (_ NameTClass_Sl_int_Sg_Scientists) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_TClassInt_scientistsNameTest2, _swig_p) + return +} + +func (arg1 SwigcptrTClassInt) ScientistsNameTest2(arg2 NameTClass_Sl_int_Sg_Scientists) (_swig_ret NameTClass_Sl_int_Sg_Scientists) { + return _swig_wrap_TClassInt_scientistsNameTest2(arg1, arg2) +} + +var _wrap_TClassInt_scientistsNameTest3 unsafe.Pointer + +func _swig_wrap_TClassInt_scientistsNameTest3(base SwigcptrTClassInt, _ NameTClass_Sl_int_Sg_Scientists) (_ NameTClass_Sl_int_Sg_Scientists) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_TClassInt_scientistsNameTest3, _swig_p) + return +} + +func (arg1 SwigcptrTClassInt) ScientistsNameTest3(arg2 NameTClass_Sl_int_Sg_Scientists) (_swig_ret NameTClass_Sl_int_Sg_Scientists) { + return _swig_wrap_TClassInt_scientistsNameTest3(arg1, arg2) +} + +var _wrap_TClassInt_scientistsNameTest4 unsafe.Pointer + +func _swig_wrap_TClassInt_scientistsNameTest4(base SwigcptrTClassInt, _ NameTClass_Sl_int_Sg_Scientists) (_ NameTClass_Sl_int_Sg_Scientists) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_TClassInt_scientistsNameTest4, _swig_p) + return +} + +func (arg1 SwigcptrTClassInt) ScientistsNameTest4(arg2 NameTClass_Sl_int_Sg_Scientists) (_swig_ret NameTClass_Sl_int_Sg_Scientists) { + return _swig_wrap_TClassInt_scientistsNameTest4(arg1, arg2) +} + +var _wrap_TClassInt_scientistsNameTest5 unsafe.Pointer + +func _swig_wrap_TClassInt_scientistsNameTest5(base SwigcptrTClassInt, _ NameTClass_Sl_int_Sg_Scientists) (_ NameTClass_Sl_int_Sg_Scientists) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_TClassInt_scientistsNameTest5, _swig_p) + return +} + +func (arg1 SwigcptrTClassInt) ScientistsNameTest5(arg2 NameTClass_Sl_int_Sg_Scientists) (_swig_ret NameTClass_Sl_int_Sg_Scientists) { + return _swig_wrap_TClassInt_scientistsNameTest5(arg1, arg2) +} + +var _wrap_TClassInt_scientistsNameTest6 unsafe.Pointer + +func _swig_wrap_TClassInt_scientistsNameTest6(base SwigcptrTClassInt, _ NameTClass_Sl_int_Sg_Scientists) (_ NameTClass_Sl_int_Sg_Scientists) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_TClassInt_scientistsNameTest6, _swig_p) + return +} + +func (arg1 SwigcptrTClassInt) ScientistsNameTest6(arg2 NameTClass_Sl_int_Sg_Scientists) (_swig_ret NameTClass_Sl_int_Sg_Scientists) { + return _swig_wrap_TClassInt_scientistsNameTest6(arg1, arg2) +} + +var _wrap_TClassInt_scientistsNameTest7 unsafe.Pointer + +func _swig_wrap_TClassInt_scientistsNameTest7(base SwigcptrTClassInt, _ NameTClass_Sl_int_Sg_Scientists) (_ NameTClass_Sl_int_Sg_Scientists) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_TClassInt_scientistsNameTest7, _swig_p) + return +} + +func (arg1 SwigcptrTClassInt) ScientistsNameTest7(arg2 NameTClass_Sl_int_Sg_Scientists) (_swig_ret NameTClass_Sl_int_Sg_Scientists) { + return _swig_wrap_TClassInt_scientistsNameTest7(arg1, arg2) +} + +var _wrap_TClassInt_scientistsNameTest8 unsafe.Pointer + +func _swig_wrap_TClassInt_scientistsNameTest8(base SwigcptrTClassInt, _ NameTClass_Sl_int_Sg_Scientists) (_ NameTClass_Sl_int_Sg_Scientists) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_TClassInt_scientistsNameTest8, _swig_p) + return +} + +func (arg1 SwigcptrTClassInt) ScientistsNameTest8(arg2 NameTClass_Sl_int_Sg_Scientists) (_swig_ret NameTClass_Sl_int_Sg_Scientists) { + return _swig_wrap_TClassInt_scientistsNameTest8(arg1, arg2) +} + +var _wrap_TClassInt_scientistsNameTest9 unsafe.Pointer + +func _swig_wrap_TClassInt_scientistsNameTest9(base SwigcptrTClassInt, _ NameTClass_Sl_int_Sg_Scientists) (_ NameTClass_Sl_int_Sg_Scientists) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_TClassInt_scientistsNameTest9, _swig_p) + return +} + +func (arg1 SwigcptrTClassInt) ScientistsNameTest9(arg2 NameTClass_Sl_int_Sg_Scientists) (_swig_ret NameTClass_Sl_int_Sg_Scientists) { + return _swig_wrap_TClassInt_scientistsNameTest9(arg1, arg2) +} + +var _wrap_TClassInt_scientistsNameTestB unsafe.Pointer + +func _swig_wrap_TClassInt_scientistsNameTestB(base SwigcptrTClassInt, _ NameTClass_Sl_int_Sg_Scientists) (_ NameTClass_Sl_int_Sg_Scientists) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_TClassInt_scientistsNameTestB, _swig_p) + return +} + +func (arg1 SwigcptrTClassInt) ScientistsNameTestB(arg2 NameTClass_Sl_int_Sg_Scientists) (_swig_ret NameTClass_Sl_int_Sg_Scientists) { + return _swig_wrap_TClassInt_scientistsNameTestB(arg1, arg2) +} + +var _wrap_TClassInt_scientistsNameTestD unsafe.Pointer + +func _swig_wrap_TClassInt_scientistsNameTestD(base SwigcptrTClassInt, _ NameTClass_Sl_int_Sg_Scientists) (_ NameTClass_Sl_int_Sg_Scientists) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_TClassInt_scientistsNameTestD, _swig_p) + return +} + +func (arg1 SwigcptrTClassInt) ScientistsNameTestD(arg2 NameTClass_Sl_int_Sg_Scientists) (_swig_ret NameTClass_Sl_int_Sg_Scientists) { + return _swig_wrap_TClassInt_scientistsNameTestD(arg1, arg2) +} + +var _wrap_TClassInt_scientistsNameTestE unsafe.Pointer + +func _swig_wrap_TClassInt_scientistsNameTestE(base SwigcptrTClassInt, _ NameTClass_Sl_int_Sg_Scientists) (_ NameTClass_Sl_int_Sg_Scientists) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_TClassInt_scientistsNameTestE, _swig_p) + return +} + +func (arg1 SwigcptrTClassInt) ScientistsNameTestE(arg2 NameTClass_Sl_int_Sg_Scientists) (_swig_ret NameTClass_Sl_int_Sg_Scientists) { + return _swig_wrap_TClassInt_scientistsNameTestE(arg1, arg2) +} + +var _wrap_TClassInt_scientistsNameTestF unsafe.Pointer + +func _swig_wrap_TClassInt_scientistsNameTestF(base SwigcptrTClassInt, _ NameTClass_Sl_int_Sg_Scientists) (_ NameTClass_Sl_int_Sg_Scientists) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_TClassInt_scientistsNameTestF, _swig_p) + return +} + +func (arg1 SwigcptrTClassInt) ScientistsNameTestF(arg2 NameTClass_Sl_int_Sg_Scientists) (_swig_ret NameTClass_Sl_int_Sg_Scientists) { + return _swig_wrap_TClassInt_scientistsNameTestF(arg1, arg2) +} + +var _wrap_TClassInt_scientistsNameTestG unsafe.Pointer + +func _swig_wrap_TClassInt_scientistsNameTestG(base SwigcptrTClassInt, _ NameTClass_Sl_int_Sg_Scientists) (_ NameTClass_Sl_int_Sg_Scientists) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_TClassInt_scientistsNameTestG, _swig_p) + return +} + +func (arg1 SwigcptrTClassInt) ScientistsNameTestG(arg2 NameTClass_Sl_int_Sg_Scientists) (_swig_ret NameTClass_Sl_int_Sg_Scientists) { + return _swig_wrap_TClassInt_scientistsNameTestG(arg1, arg2) +} + +var _wrap_TClassInt_scientistsNameTestH unsafe.Pointer + +func _swig_wrap_TClassInt_scientistsNameTestH(base SwigcptrTClassInt, _ NameTClass_Sl_int_Sg_Scientists) (_ NameTClass_Sl_int_Sg_Scientists) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_TClassInt_scientistsNameTestH, _swig_p) + return +} + +func (arg1 SwigcptrTClassInt) ScientistsNameTestH(arg2 NameTClass_Sl_int_Sg_Scientists) (_swig_ret NameTClass_Sl_int_Sg_Scientists) { + return _swig_wrap_TClassInt_scientistsNameTestH(arg1, arg2) +} + +var _wrap_TClassInt_scientistsNameTestI unsafe.Pointer + +func _swig_wrap_TClassInt_scientistsNameTestI(base SwigcptrTClassInt, _ NameTClass_Sl_int_Sg_Scientists) (_ NameTClass_Sl_int_Sg_Scientists) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_TClassInt_scientistsNameTestI, _swig_p) + return +} + +func (arg1 SwigcptrTClassInt) ScientistsNameTestI(arg2 NameTClass_Sl_int_Sg_Scientists) (_swig_ret NameTClass_Sl_int_Sg_Scientists) { + return _swig_wrap_TClassInt_scientistsNameTestI(arg1, arg2) +} + +var _wrap_TClassInt_scientistsNameSpaceTest1 unsafe.Pointer + +func _swig_wrap_TClassInt_scientistsNameSpaceTest1(base SwigcptrTClassInt, _ NameTClass_Sl_int_Sg_Scientists) (_ NameTClass_Sl_int_Sg_Scientists) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_TClassInt_scientistsNameSpaceTest1, _swig_p) + return +} + +func (arg1 SwigcptrTClassInt) ScientistsNameSpaceTest1(arg2 NameTClass_Sl_int_Sg_Scientists) (_swig_ret NameTClass_Sl_int_Sg_Scientists) { + return _swig_wrap_TClassInt_scientistsNameSpaceTest1(arg1, arg2) +} + +var _wrap_TClassInt_scientistsNameSpaceTest2 unsafe.Pointer + +func _swig_wrap_TClassInt_scientistsNameSpaceTest2(base SwigcptrTClassInt, _ NameTClass_Sl_int_Sg_Scientists) (_ NameTClass_Sl_int_Sg_Scientists) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_TClassInt_scientistsNameSpaceTest2, _swig_p) + return +} + +func (arg1 SwigcptrTClassInt) ScientistsNameSpaceTest2(arg2 NameTClass_Sl_int_Sg_Scientists) (_swig_ret NameTClass_Sl_int_Sg_Scientists) { + return _swig_wrap_TClassInt_scientistsNameSpaceTest2(arg1, arg2) +} + +var _wrap_TClassInt_scientistsNameSpaceTest3 unsafe.Pointer + +func _swig_wrap_TClassInt_scientistsNameSpaceTest3(base SwigcptrTClassInt, _ NameTClass_Sl_int_Sg_Scientists) (_ NameTClass_Sl_int_Sg_Scientists) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_TClassInt_scientistsNameSpaceTest3, _swig_p) + return +} + +func (arg1 SwigcptrTClassInt) ScientistsNameSpaceTest3(arg2 NameTClass_Sl_int_Sg_Scientists) (_swig_ret NameTClass_Sl_int_Sg_Scientists) { + return _swig_wrap_TClassInt_scientistsNameSpaceTest3(arg1, arg2) +} + +var _wrap_TClassInt_scientistsNameSpaceTest4 unsafe.Pointer + +func _swig_wrap_TClassInt_scientistsNameSpaceTest4(base SwigcptrTClassInt, _ NameTClass_Sl_int_Sg_Scientists) (_ NameTClass_Sl_int_Sg_Scientists) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_TClassInt_scientistsNameSpaceTest4, _swig_p) + return +} + +func (arg1 SwigcptrTClassInt) ScientistsNameSpaceTest4(arg2 NameTClass_Sl_int_Sg_Scientists) (_swig_ret NameTClass_Sl_int_Sg_Scientists) { + return _swig_wrap_TClassInt_scientistsNameSpaceTest4(arg1, arg2) +} + +var _wrap_TClassInt_scientistsNameSpaceTest5 unsafe.Pointer + +func _swig_wrap_TClassInt_scientistsNameSpaceTest5(base SwigcptrTClassInt, _ NameTClass_Sl_int_Sg_Scientists) (_ NameTClass_Sl_int_Sg_Scientists) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_TClassInt_scientistsNameSpaceTest5, _swig_p) + return +} + +func (arg1 SwigcptrTClassInt) ScientistsNameSpaceTest5(arg2 NameTClass_Sl_int_Sg_Scientists) (_swig_ret NameTClass_Sl_int_Sg_Scientists) { + return _swig_wrap_TClassInt_scientistsNameSpaceTest5(arg1, arg2) +} + +var _wrap_TClassInt_scientistsNameSpaceTest6 unsafe.Pointer + +func _swig_wrap_TClassInt_scientistsNameSpaceTest6(base SwigcptrTClassInt, _ NameTClass_Sl_int_Sg_Scientists) (_ NameTClass_Sl_int_Sg_Scientists) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_TClassInt_scientistsNameSpaceTest6, _swig_p) + return +} + +func (arg1 SwigcptrTClassInt) ScientistsNameSpaceTest6(arg2 NameTClass_Sl_int_Sg_Scientists) (_swig_ret NameTClass_Sl_int_Sg_Scientists) { + return _swig_wrap_TClassInt_scientistsNameSpaceTest6(arg1, arg2) +} + +var _wrap_TClassInt_scientistsNameSpaceTest7 unsafe.Pointer + +func _swig_wrap_TClassInt_scientistsNameSpaceTest7(base SwigcptrTClassInt, _ NameTClass_Sl_int_Sg_Scientists) (_ NameTClass_Sl_int_Sg_Scientists) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_TClassInt_scientistsNameSpaceTest7, _swig_p) + return +} + +func (arg1 SwigcptrTClassInt) ScientistsNameSpaceTest7(arg2 NameTClass_Sl_int_Sg_Scientists) (_swig_ret NameTClass_Sl_int_Sg_Scientists) { + return _swig_wrap_TClassInt_scientistsNameSpaceTest7(arg1, arg2) +} + +var _wrap_TClassInt_scientistsOtherTest1 unsafe.Pointer + +func _swig_wrap_TClassInt_scientistsOtherTest1(base SwigcptrTClassInt, _ TemplateClass_Sl_int_Sg_Scientists) (_ TemplateClass_Sl_int_Sg_Scientists) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_TClassInt_scientistsOtherTest1, _swig_p) + return +} + +func (arg1 SwigcptrTClassInt) ScientistsOtherTest1(arg2 TemplateClass_Sl_int_Sg_Scientists) (_swig_ret TemplateClass_Sl_int_Sg_Scientists) { + return _swig_wrap_TClassInt_scientistsOtherTest1(arg1, arg2) +} + +var _wrap_TClassInt_scientistsOtherTest2 unsafe.Pointer + +func _swig_wrap_TClassInt_scientistsOtherTest2(base SwigcptrTClassInt, _ TemplateClass_Sl_int_Sg_Scientists) (_ TemplateClass_Sl_int_Sg_Scientists) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_TClassInt_scientistsOtherTest2, _swig_p) + return +} + +func (arg1 SwigcptrTClassInt) ScientistsOtherTest2(arg2 TemplateClass_Sl_int_Sg_Scientists) (_swig_ret TemplateClass_Sl_int_Sg_Scientists) { + return _swig_wrap_TClassInt_scientistsOtherTest2(arg1, arg2) +} + +var _wrap_TClassInt_scientistsOtherTest3 unsafe.Pointer + +func _swig_wrap_TClassInt_scientistsOtherTest3(base SwigcptrTClassInt, _ TemplateClass_Sl_int_Sg_Scientists) (_ TemplateClass_Sl_int_Sg_Scientists) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_TClassInt_scientistsOtherTest3, _swig_p) + return +} + +func (arg1 SwigcptrTClassInt) ScientistsOtherTest3(arg2 TemplateClass_Sl_int_Sg_Scientists) (_swig_ret TemplateClass_Sl_int_Sg_Scientists) { + return _swig_wrap_TClassInt_scientistsOtherTest3(arg1, arg2) +} + +var _wrap_TClassInt_scientistsOtherTest4 unsafe.Pointer + +func _swig_wrap_TClassInt_scientistsOtherTest4(base SwigcptrTClassInt, _ TemplateClass_Sl_int_Sg_Scientists) (_ TemplateClass_Sl_int_Sg_Scientists) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_TClassInt_scientistsOtherTest4, _swig_p) + return +} + +func (arg1 SwigcptrTClassInt) ScientistsOtherTest4(arg2 TemplateClass_Sl_int_Sg_Scientists) (_swig_ret TemplateClass_Sl_int_Sg_Scientists) { + return _swig_wrap_TClassInt_scientistsOtherTest4(arg1, arg2) +} + +var _wrap_TClassInt_scientistsOtherTest5 unsafe.Pointer + +func _swig_wrap_TClassInt_scientistsOtherTest5(base SwigcptrTClassInt, _ TemplateClass_Sl_int_Sg_Scientists) (_ TemplateClass_Sl_int_Sg_Scientists) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_TClassInt_scientistsOtherTest5, _swig_p) + return +} + +func (arg1 SwigcptrTClassInt) ScientistsOtherTest5(arg2 TemplateClass_Sl_int_Sg_Scientists) (_swig_ret TemplateClass_Sl_int_Sg_Scientists) { + return _swig_wrap_TClassInt_scientistsOtherTest5(arg1, arg2) +} + +var _wrap_TClassInt_scientistsOtherTest6 unsafe.Pointer + +func _swig_wrap_TClassInt_scientistsOtherTest6(base SwigcptrTClassInt, _ TemplateClass_Sl_int_Sg_Scientists) (_ TemplateClass_Sl_int_Sg_Scientists) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_TClassInt_scientistsOtherTest6, _swig_p) + return +} + +func (arg1 SwigcptrTClassInt) ScientistsOtherTest6(arg2 TemplateClass_Sl_int_Sg_Scientists) (_swig_ret TemplateClass_Sl_int_Sg_Scientists) { + return _swig_wrap_TClassInt_scientistsOtherTest6(arg1, arg2) +} + +var _wrap_TClassInt_scientistsOtherTest7 unsafe.Pointer + +func _swig_wrap_TClassInt_scientistsOtherTest7(base SwigcptrTClassInt, _ TemplateClass_Sl_int_Sg_Scientists) (_ TemplateClass_Sl_int_Sg_Scientists) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_TClassInt_scientistsOtherTest7, _swig_p) + return +} + +func (arg1 SwigcptrTClassInt) ScientistsOtherTest7(arg2 TemplateClass_Sl_int_Sg_Scientists) (_swig_ret TemplateClass_Sl_int_Sg_Scientists) { + return _swig_wrap_TClassInt_scientistsOtherTest7(arg1, arg2) +} + +var _wrap_new_TClassInt unsafe.Pointer + +func _swig_wrap_new_TClassInt() (base SwigcptrTClassInt) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_TClassInt, _swig_p) + return +} + +func NewTClassInt() (_swig_ret TClassInt) { + return _swig_wrap_new_TClassInt() +} + +var _wrap_delete_TClassInt unsafe.Pointer + +func _swig_wrap_delete_TClassInt(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_TClassInt, _swig_p) + return +} + +func DeleteTClassInt(arg1 TClassInt) { + _swig_wrap_delete_TClassInt(arg1.Swigcptr()) +} + +type TClassInt interface { + Swigcptr() uintptr + SwigIsTClassInt() + ScientistsNameTest1(arg2 NameTClass_Sl_int_Sg_Scientists) (_swig_ret NameTClass_Sl_int_Sg_Scientists) + ScientistsNameTest2(arg2 NameTClass_Sl_int_Sg_Scientists) (_swig_ret NameTClass_Sl_int_Sg_Scientists) + ScientistsNameTest3(arg2 NameTClass_Sl_int_Sg_Scientists) (_swig_ret NameTClass_Sl_int_Sg_Scientists) + ScientistsNameTest4(arg2 NameTClass_Sl_int_Sg_Scientists) (_swig_ret NameTClass_Sl_int_Sg_Scientists) + ScientistsNameTest5(arg2 NameTClass_Sl_int_Sg_Scientists) (_swig_ret NameTClass_Sl_int_Sg_Scientists) + ScientistsNameTest6(arg2 NameTClass_Sl_int_Sg_Scientists) (_swig_ret NameTClass_Sl_int_Sg_Scientists) + ScientistsNameTest7(arg2 NameTClass_Sl_int_Sg_Scientists) (_swig_ret NameTClass_Sl_int_Sg_Scientists) + ScientistsNameTest8(arg2 NameTClass_Sl_int_Sg_Scientists) (_swig_ret NameTClass_Sl_int_Sg_Scientists) + ScientistsNameTest9(arg2 NameTClass_Sl_int_Sg_Scientists) (_swig_ret NameTClass_Sl_int_Sg_Scientists) + ScientistsNameTestB(arg2 NameTClass_Sl_int_Sg_Scientists) (_swig_ret NameTClass_Sl_int_Sg_Scientists) + ScientistsNameTestD(arg2 NameTClass_Sl_int_Sg_Scientists) (_swig_ret NameTClass_Sl_int_Sg_Scientists) + ScientistsNameTestE(arg2 NameTClass_Sl_int_Sg_Scientists) (_swig_ret NameTClass_Sl_int_Sg_Scientists) + ScientistsNameTestF(arg2 NameTClass_Sl_int_Sg_Scientists) (_swig_ret NameTClass_Sl_int_Sg_Scientists) + ScientistsNameTestG(arg2 NameTClass_Sl_int_Sg_Scientists) (_swig_ret NameTClass_Sl_int_Sg_Scientists) + ScientistsNameTestH(arg2 NameTClass_Sl_int_Sg_Scientists) (_swig_ret NameTClass_Sl_int_Sg_Scientists) + ScientistsNameTestI(arg2 NameTClass_Sl_int_Sg_Scientists) (_swig_ret NameTClass_Sl_int_Sg_Scientists) + ScientistsNameSpaceTest1(arg2 NameTClass_Sl_int_Sg_Scientists) (_swig_ret NameTClass_Sl_int_Sg_Scientists) + ScientistsNameSpaceTest2(arg2 NameTClass_Sl_int_Sg_Scientists) (_swig_ret NameTClass_Sl_int_Sg_Scientists) + ScientistsNameSpaceTest3(arg2 NameTClass_Sl_int_Sg_Scientists) (_swig_ret NameTClass_Sl_int_Sg_Scientists) + ScientistsNameSpaceTest4(arg2 NameTClass_Sl_int_Sg_Scientists) (_swig_ret NameTClass_Sl_int_Sg_Scientists) + ScientistsNameSpaceTest5(arg2 NameTClass_Sl_int_Sg_Scientists) (_swig_ret NameTClass_Sl_int_Sg_Scientists) + ScientistsNameSpaceTest6(arg2 NameTClass_Sl_int_Sg_Scientists) (_swig_ret NameTClass_Sl_int_Sg_Scientists) + ScientistsNameSpaceTest7(arg2 NameTClass_Sl_int_Sg_Scientists) (_swig_ret NameTClass_Sl_int_Sg_Scientists) + ScientistsOtherTest1(arg2 TemplateClass_Sl_int_Sg_Scientists) (_swig_ret TemplateClass_Sl_int_Sg_Scientists) + ScientistsOtherTest2(arg2 TemplateClass_Sl_int_Sg_Scientists) (_swig_ret TemplateClass_Sl_int_Sg_Scientists) + ScientistsOtherTest3(arg2 TemplateClass_Sl_int_Sg_Scientists) (_swig_ret TemplateClass_Sl_int_Sg_Scientists) + ScientistsOtherTest4(arg2 TemplateClass_Sl_int_Sg_Scientists) (_swig_ret TemplateClass_Sl_int_Sg_Scientists) + ScientistsOtherTest5(arg2 TemplateClass_Sl_int_Sg_Scientists) (_swig_ret TemplateClass_Sl_int_Sg_Scientists) + ScientistsOtherTest6(arg2 TemplateClass_Sl_int_Sg_Scientists) (_swig_ret TemplateClass_Sl_int_Sg_Scientists) + ScientistsOtherTest7(arg2 TemplateClass_Sl_int_Sg_Scientists) (_swig_ret TemplateClass_Sl_int_Sg_Scientists) +} + +type Old_name int +var _wrap_argh unsafe.Pointer + +func _swig_getargh() (_swig_ret Old_name) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_argh, _swig_p) + return +} +var Argh Old_name = _swig_getargh() +var _wrap_eek unsafe.Pointer + +func _swig_geteek() (_swig_ret Old_name) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_eek, _swig_p) + return +} +var Eek Old_name = _swig_geteek() +var _wrap_renameTest1 unsafe.Pointer + +func RenameTest1(arg1 Old_name) (_swig_ret Old_name) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_renameTest1, _swig_p) + return +} +var _wrap_renameTest2 unsafe.Pointer + +func RenameTest2(arg1 Old_name) (_swig_ret Old_name) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_renameTest2, _swig_p) + return +} +type SwigcptrNewNameStruct uintptr + +func (p SwigcptrNewNameStruct) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrNewNameStruct) SwigIsNewNameStruct() { +} + +type OldNameStructEnumeration int +var _wrap_whizz_NewNameStruct unsafe.Pointer + +func _swig_getNewNameStruct_whizz_NewNameStruct() (_swig_ret OldNameStructEnumeration) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_whizz_NewNameStruct, _swig_p) + return +} +var NewNameStructWhizz OldNameStructEnumeration = _swig_getNewNameStruct_whizz_NewNameStruct() +var _wrap_bang_NewNameStruct unsafe.Pointer + +func _swig_getNewNameStruct_bang_NewNameStruct() (_swig_ret OldNameStructEnumeration) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_bang_NewNameStruct, _swig_p) + return +} +var NewNameStructBang OldNameStructEnumeration = _swig_getNewNameStruct_bang_NewNameStruct() +var _wrap_pop_NewNameStruct unsafe.Pointer + +func _swig_getNewNameStruct_pop_NewNameStruct() (_swig_ret OldNameStructEnumeration) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_pop_NewNameStruct, _swig_p) + return +} +var NewNameStructPop OldNameStructEnumeration = _swig_getNewNameStruct_pop_NewNameStruct() +var _wrap_NewNameStruct_renameTest1 unsafe.Pointer + +func _swig_wrap_NewNameStruct_renameTest1(base SwigcptrNewNameStruct, _ OldNameStructEnumeration) (_ OldNameStructEnumeration) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_NewNameStruct_renameTest1, _swig_p) + return +} + +func (arg1 SwigcptrNewNameStruct) RenameTest1(arg2 OldNameStructEnumeration) (_swig_ret OldNameStructEnumeration) { + return _swig_wrap_NewNameStruct_renameTest1(arg1, arg2) +} + +var _wrap_NewNameStruct_renameTest2 unsafe.Pointer + +func _swig_wrap_NewNameStruct_renameTest2(base SwigcptrNewNameStruct, _ OldNameStructEnumeration) (_ OldNameStructEnumeration) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_NewNameStruct_renameTest2, _swig_p) + return +} + +func (arg1 SwigcptrNewNameStruct) RenameTest2(arg2 OldNameStructEnumeration) (_swig_ret OldNameStructEnumeration) { + return _swig_wrap_NewNameStruct_renameTest2(arg1, arg2) +} + +type OldNameStructSimple int +var _wrap_simple1_NewNameStruct unsafe.Pointer + +func _swig_getNewNameStruct_simple1_NewNameStruct() (_swig_ret OldNameStructSimple) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_simple1_NewNameStruct, _swig_p) + return +} +var NewNameStructSimple1 OldNameStructSimple = _swig_getNewNameStruct_simple1_NewNameStruct() +type OldNameStructDoublenametag int +var _wrap_doublename1_NewNameStruct unsafe.Pointer + +func _swig_getNewNameStruct_doublename1_NewNameStruct() (_swig_ret OldNameStructDoublenametag) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_doublename1_NewNameStruct, _swig_p) + return +} +var NewNameStructDoublename1 OldNameStructDoublenametag = _swig_getNewNameStruct_doublename1_NewNameStruct() +type OldNameStructSinglename int +var _wrap_singlename1_NewNameStruct unsafe.Pointer + +func _swig_getNewNameStruct_singlename1_NewNameStruct() (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_singlename1_NewNameStruct, _swig_p) + return +} +var NewNameStructSinglename1 int = _swig_getNewNameStruct_singlename1_NewNameStruct() +var _wrap_NewNameStruct_renameTest3 unsafe.Pointer + +func _swig_wrap_NewNameStruct_renameTest3(base SwigcptrNewNameStruct, _ OldNameStructSimple) (_ OldNameStructSimple) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_NewNameStruct_renameTest3, _swig_p) + return +} + +func (arg1 SwigcptrNewNameStruct) RenameTest3(arg2 OldNameStructSimple) (_swig_ret OldNameStructSimple) { + return _swig_wrap_NewNameStruct_renameTest3(arg1, arg2) +} + +var _wrap_NewNameStruct_renameTest4 unsafe.Pointer + +func _swig_wrap_NewNameStruct_renameTest4(base SwigcptrNewNameStruct, _ OldNameStructDoublenametag) (_ OldNameStructDoublenametag) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_NewNameStruct_renameTest4, _swig_p) + return +} + +func (arg1 SwigcptrNewNameStruct) RenameTest4(arg2 OldNameStructDoublenametag) (_swig_ret OldNameStructDoublenametag) { + return _swig_wrap_NewNameStruct_renameTest4(arg1, arg2) +} + +var _wrap_NewNameStruct_renameTest5 unsafe.Pointer + +func _swig_wrap_NewNameStruct_renameTest5(base SwigcptrNewNameStruct, _ OldNameStructDoublenametag) (_ OldNameStructDoublenametag) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_NewNameStruct_renameTest5, _swig_p) + return +} + +func (arg1 SwigcptrNewNameStruct) RenameTest5(arg2 OldNameStructDoublenametag) (_swig_ret OldNameStructDoublenametag) { + return _swig_wrap_NewNameStruct_renameTest5(arg1, arg2) +} + +var _wrap_NewNameStruct_renameTest6 unsafe.Pointer + +func _swig_wrap_NewNameStruct_renameTest6(base SwigcptrNewNameStruct, _ OldNameStructSinglename) (_ OldNameStructSinglename) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_NewNameStruct_renameTest6, _swig_p) + return +} + +func (arg1 SwigcptrNewNameStruct) RenameTest6(arg2 OldNameStructSinglename) (_swig_ret OldNameStructSinglename) { + return _swig_wrap_NewNameStruct_renameTest6(arg1, arg2) +} + +var _wrap_new_NewNameStruct unsafe.Pointer + +func _swig_wrap_new_NewNameStruct() (base SwigcptrNewNameStruct) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_NewNameStruct, _swig_p) + return +} + +func NewNewNameStruct() (_swig_ret NewNameStruct) { + return _swig_wrap_new_NewNameStruct() +} + +var _wrap_delete_NewNameStruct unsafe.Pointer + +func _swig_wrap_delete_NewNameStruct(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_NewNameStruct, _swig_p) + return +} + +func DeleteNewNameStruct(arg1 NewNameStruct) { + _swig_wrap_delete_NewNameStruct(arg1.Swigcptr()) +} + +type NewNameStruct interface { + Swigcptr() uintptr + SwigIsNewNameStruct() + RenameTest1(arg2 OldNameStructEnumeration) (_swig_ret OldNameStructEnumeration) + RenameTest2(arg2 OldNameStructEnumeration) (_swig_ret OldNameStructEnumeration) + RenameTest3(arg2 OldNameStructSimple) (_swig_ret OldNameStructSimple) + RenameTest4(arg2 OldNameStructDoublenametag) (_swig_ret OldNameStructDoublenametag) + RenameTest5(arg2 OldNameStructDoublenametag) (_swig_ret OldNameStructDoublenametag) + RenameTest6(arg2 OldNameStructSinglename) (_swig_ret OldNameStructSinglename) +} + +var _wrap_renameTest3 unsafe.Pointer + +func RenameTest3(arg1 OldNameStructEnumeration) (_swig_ret OldNameStructEnumeration) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_renameTest3, _swig_p) + return +} +var _wrap_renameTest4 unsafe.Pointer + +func RenameTest4(arg1 OldNameStructSimple) (_swig_ret OldNameStructSimple) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_renameTest4, _swig_p) + return +} +var _wrap_renameTest5 unsafe.Pointer + +func RenameTest5(arg1 OldNameStructDoublenametag) (_swig_ret OldNameStructDoublenametag) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_renameTest5, _swig_p) + return +} +var _wrap_renameTest6 unsafe.Pointer + +func RenameTest6(arg1 OldNameStructDoublenametag) (_swig_ret OldNameStructDoublenametag) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_renameTest6, _swig_p) + return +} +var _wrap_renameTest7 unsafe.Pointer + +func RenameTest7(arg1 OldNameStructSinglename) (_swig_ret OldNameStructSinglename) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_renameTest7, _swig_p) + return +} +type SwigcptrTreesClass uintptr + +func (p SwigcptrTreesClass) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrTreesClass) SwigIsTreesClass() { +} + +type TreesClassTrees int +var _wrap_oak_TreesClass unsafe.Pointer + +func _swig_getTreesClass_oak_TreesClass() (_swig_ret TreesClassTrees) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_oak_TreesClass, _swig_p) + return +} +var TreesClassOak TreesClassTrees = _swig_getTreesClass_oak_TreesClass() +var _wrap_fir_TreesClass unsafe.Pointer + +func _swig_getTreesClass_fir_TreesClass() (_swig_ret TreesClassTrees) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_fir_TreesClass, _swig_p) + return +} +var TreesClassFir TreesClassTrees = _swig_getTreesClass_fir_TreesClass() +var _wrap_pine_TreesClass unsafe.Pointer + +func _swig_getTreesClass_pine_TreesClass() (_swig_ret TreesClassTrees) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_pine_TreesClass, _swig_p) + return +} +var TreesClassPine TreesClassTrees = _swig_getTreesClass_pine_TreesClass() +var _wrap_TreesClass_treesTest1 unsafe.Pointer + +func _swig_wrap_TreesClass_treesTest1(base SwigcptrTreesClass, _ TreesClassTrees) (_ TreesClassTrees) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_TreesClass_treesTest1, _swig_p) + return +} + +func (arg1 SwigcptrTreesClass) TreesTest1(arg2 TreesClassTrees) (_swig_ret TreesClassTrees) { + return _swig_wrap_TreesClass_treesTest1(arg1, arg2) +} + +var _wrap_TreesClass_treesTest2 unsafe.Pointer + +func _swig_wrap_TreesClass_treesTest2(base SwigcptrTreesClass, _ TreesClassTrees) (_ TreesClassTrees) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_TreesClass_treesTest2, _swig_p) + return +} + +func (arg1 SwigcptrTreesClass) TreesTest2(arg2 TreesClassTrees) (_swig_ret TreesClassTrees) { + return _swig_wrap_TreesClass_treesTest2(arg1, arg2) +} + +var _wrap_TreesClass_treesTest3 unsafe.Pointer + +func _swig_wrap_TreesClass_treesTest3(base SwigcptrTreesClass, _ TreesClassTrees) (_ TreesClassTrees) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_TreesClass_treesTest3, _swig_p) + return +} + +func (arg1 SwigcptrTreesClass) TreesTest3(arg2 TreesClassTrees) (_swig_ret TreesClassTrees) { + return _swig_wrap_TreesClass_treesTest3(arg1, arg2) +} + +var _wrap_TreesClass_treesTest4 unsafe.Pointer + +func _swig_wrap_TreesClass_treesTest4(base SwigcptrTreesClass, _ TreesClassTrees) (_ TreesClassTrees) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_TreesClass_treesTest4, _swig_p) + return +} + +func (arg1 SwigcptrTreesClass) TreesTest4(arg2 TreesClassTrees) (_swig_ret TreesClassTrees) { + return _swig_wrap_TreesClass_treesTest4(arg1, arg2) +} + +var _wrap_TreesClass_treesTest5 unsafe.Pointer + +func _swig_wrap_TreesClass_treesTest5(base SwigcptrTreesClass, _ TreesClassTrees) (_ TreesClassTrees) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_TreesClass_treesTest5, _swig_p) + return +} + +func (arg1 SwigcptrTreesClass) TreesTest5(arg2 TreesClassTrees) (_swig_ret TreesClassTrees) { + return _swig_wrap_TreesClass_treesTest5(arg1, arg2) +} + +var _wrap_TreesClass_treesTest6 unsafe.Pointer + +func _swig_wrap_TreesClass_treesTest6(base SwigcptrTreesClass, _ TreesClassTrees) (_ TreesClassTrees) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_TreesClass_treesTest6, _swig_p) + return +} + +func (arg1 SwigcptrTreesClass) TreesTest6(arg2 TreesClassTrees) (_swig_ret TreesClassTrees) { + return _swig_wrap_TreesClass_treesTest6(arg1, arg2) +} + +var _wrap_TreesClass_treesTest7 unsafe.Pointer + +func _swig_wrap_TreesClass_treesTest7(base SwigcptrTreesClass, _ TreesClassTrees) (_ TreesClassTrees) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_TreesClass_treesTest7, _swig_p) + return +} + +func (arg1 SwigcptrTreesClass) TreesTest7(arg2 TreesClassTrees) (_swig_ret TreesClassTrees) { + return _swig_wrap_TreesClass_treesTest7(arg1, arg2) +} + +var _wrap_TreesClass_treesTest8 unsafe.Pointer + +func _swig_wrap_TreesClass_treesTest8(base SwigcptrTreesClass, _ TreesClassTrees) (_ TreesClassTrees) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_TreesClass_treesTest8, _swig_p) + return +} + +func (arg1 SwigcptrTreesClass) TreesTest8(arg2 TreesClassTrees) (_swig_ret TreesClassTrees) { + return _swig_wrap_TreesClass_treesTest8(arg1, arg2) +} + +var _wrap_TreesClass_treesTest9 unsafe.Pointer + +func _swig_wrap_TreesClass_treesTest9(base SwigcptrTreesClass, _ TreesClassTrees) (_ TreesClassTrees) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_TreesClass_treesTest9, _swig_p) + return +} + +func (arg1 SwigcptrTreesClass) TreesTest9(arg2 TreesClassTrees) (_swig_ret TreesClassTrees) { + return _swig_wrap_TreesClass_treesTest9(arg1, arg2) +} + +var _wrap_TreesClass_treesTestA unsafe.Pointer + +func _swig_wrap_TreesClass_treesTestA(base SwigcptrTreesClass, _ TreesClassTrees) (_ TreesClassTrees) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_TreesClass_treesTestA, _swig_p) + return +} + +func (arg1 SwigcptrTreesClass) TreesTestA(arg2 TreesClassTrees) (_swig_ret TreesClassTrees) { + return _swig_wrap_TreesClass_treesTestA(arg1, arg2) +} + +var _wrap_TreesClass_treesTestB unsafe.Pointer + +func _swig_wrap_TreesClass_treesTestB(base SwigcptrTreesClass, _ TreesClassTrees) (_ TreesClassTrees) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_TreesClass_treesTestB, _swig_p) + return +} + +func (arg1 SwigcptrTreesClass) TreesTestB(arg2 TreesClassTrees) (_swig_ret TreesClassTrees) { + return _swig_wrap_TreesClass_treesTestB(arg1, arg2) +} + +var _wrap_TreesClass_treesTestC unsafe.Pointer + +func _swig_wrap_TreesClass_treesTestC(base SwigcptrTreesClass, _ TreesClassTrees) (_ TreesClassTrees) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_TreesClass_treesTestC, _swig_p) + return +} + +func (arg1 SwigcptrTreesClass) TreesTestC(arg2 TreesClassTrees) (_swig_ret TreesClassTrees) { + return _swig_wrap_TreesClass_treesTestC(arg1, arg2) +} + +var _wrap_TreesClass_treesTestD unsafe.Pointer + +func _swig_wrap_TreesClass_treesTestD(base SwigcptrTreesClass, _ TreesClassTrees) (_ TreesClassTrees) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_TreesClass_treesTestD, _swig_p) + return +} + +func (arg1 SwigcptrTreesClass) TreesTestD(arg2 TreesClassTrees) (_swig_ret TreesClassTrees) { + return _swig_wrap_TreesClass_treesTestD(arg1, arg2) +} + +var _wrap_TreesClass_treesTestE unsafe.Pointer + +func _swig_wrap_TreesClass_treesTestE(base SwigcptrTreesClass, _ TreesClassTrees) (_ TreesClassTrees) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_TreesClass_treesTestE, _swig_p) + return +} + +func (arg1 SwigcptrTreesClass) TreesTestE(arg2 TreesClassTrees) (_swig_ret TreesClassTrees) { + return _swig_wrap_TreesClass_treesTestE(arg1, arg2) +} + +var _wrap_TreesClass_treesTestF unsafe.Pointer + +func _swig_wrap_TreesClass_treesTestF(base SwigcptrTreesClass, _ TreesClassTrees) (_ TreesClassTrees) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_TreesClass_treesTestF, _swig_p) + return +} + +func (arg1 SwigcptrTreesClass) TreesTestF(arg2 TreesClassTrees) (_swig_ret TreesClassTrees) { + return _swig_wrap_TreesClass_treesTestF(arg1, arg2) +} + +var _wrap_TreesClass_treesTestG unsafe.Pointer + +func _swig_wrap_TreesClass_treesTestG(base SwigcptrTreesClass, _ TreesClassTrees) (_ TreesClassTrees) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_TreesClass_treesTestG, _swig_p) + return +} + +func (arg1 SwigcptrTreesClass) TreesTestG(arg2 TreesClassTrees) (_swig_ret TreesClassTrees) { + return _swig_wrap_TreesClass_treesTestG(arg1, arg2) +} + +var _wrap_TreesClass_treesTestH unsafe.Pointer + +func _swig_wrap_TreesClass_treesTestH(base SwigcptrTreesClass, _ TreesClassTrees) (_ TreesClassTrees) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_TreesClass_treesTestH, _swig_p) + return +} + +func (arg1 SwigcptrTreesClass) TreesTestH(arg2 TreesClassTrees) (_swig_ret TreesClassTrees) { + return _swig_wrap_TreesClass_treesTestH(arg1, arg2) +} + +var _wrap_TreesClass_treesTestI unsafe.Pointer + +func _swig_wrap_TreesClass_treesTestI(base SwigcptrTreesClass, _ TreesClassTrees) (_ TreesClassTrees) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_TreesClass_treesTestI, _swig_p) + return +} + +func (arg1 SwigcptrTreesClass) TreesTestI(arg2 TreesClassTrees) (_swig_ret TreesClassTrees) { + return _swig_wrap_TreesClass_treesTestI(arg1, arg2) +} + +var _wrap_TreesClass_treesTestJ unsafe.Pointer + +func _swig_wrap_TreesClass_treesTestJ(base SwigcptrTreesClass, _ TreesClassTrees) (_ TreesClassTrees) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_TreesClass_treesTestJ, _swig_p) + return +} + +func (arg1 SwigcptrTreesClass) TreesTestJ(arg2 TreesClassTrees) (_swig_ret TreesClassTrees) { + return _swig_wrap_TreesClass_treesTestJ(arg1, arg2) +} + +var _wrap_TreesClass_treesTestK unsafe.Pointer + +func _swig_wrap_TreesClass_treesTestK(base SwigcptrTreesClass, _ TreesClassTrees) (_ TreesClassTrees) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_TreesClass_treesTestK, _swig_p) + return +} + +func (arg1 SwigcptrTreesClass) TreesTestK(arg2 TreesClassTrees) (_swig_ret TreesClassTrees) { + return _swig_wrap_TreesClass_treesTestK(arg1, arg2) +} + +var _wrap_TreesClass_treesTestL unsafe.Pointer + +func _swig_wrap_TreesClass_treesTestL(base SwigcptrTreesClass, _ TreesClassTrees) (_ TreesClassTrees) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_TreesClass_treesTestL, _swig_p) + return +} + +func (arg1 SwigcptrTreesClass) TreesTestL(arg2 TreesClassTrees) (_swig_ret TreesClassTrees) { + return _swig_wrap_TreesClass_treesTestL(arg1, arg2) +} + +var _wrap_TreesClass_treesTestM unsafe.Pointer + +func _swig_wrap_TreesClass_treesTestM(base SwigcptrTreesClass, _ TreesClassTrees) (_ TreesClassTrees) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_TreesClass_treesTestM, _swig_p) + return +} + +func (arg1 SwigcptrTreesClass) TreesTestM(arg2 TreesClassTrees) (_swig_ret TreesClassTrees) { + return _swig_wrap_TreesClass_treesTestM(arg1, arg2) +} + +var _wrap_TreesClass_treesTestN unsafe.Pointer + +func _swig_wrap_TreesClass_treesTestN(base SwigcptrTreesClass, _ TreesClassTrees) (_ TreesClassTrees) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_TreesClass_treesTestN, _swig_p) + return +} + +func (arg1 SwigcptrTreesClass) TreesTestN(arg2 TreesClassTrees) (_swig_ret TreesClassTrees) { + return _swig_wrap_TreesClass_treesTestN(arg1, arg2) +} + +var _wrap_TreesClass_treesTestO unsafe.Pointer + +func _swig_wrap_TreesClass_treesTestO(base SwigcptrTreesClass, _ TreesClassTrees) (_ TreesClassTrees) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_TreesClass_treesTestO, _swig_p) + return +} + +func (arg1 SwigcptrTreesClass) TreesTestO(arg2 TreesClassTrees) (_swig_ret TreesClassTrees) { + return _swig_wrap_TreesClass_treesTestO(arg1, arg2) +} + +var _wrap_new_TreesClass unsafe.Pointer + +func _swig_wrap_new_TreesClass() (base SwigcptrTreesClass) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_TreesClass, _swig_p) + return +} + +func NewTreesClass() (_swig_ret TreesClass) { + return _swig_wrap_new_TreesClass() +} + +var _wrap_delete_TreesClass unsafe.Pointer + +func _swig_wrap_delete_TreesClass(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_TreesClass, _swig_p) + return +} + +func DeleteTreesClass(arg1 TreesClass) { + _swig_wrap_delete_TreesClass(arg1.Swigcptr()) +} + +type TreesClass interface { + Swigcptr() uintptr + SwigIsTreesClass() + TreesTest1(arg2 TreesClassTrees) (_swig_ret TreesClassTrees) + TreesTest2(arg2 TreesClassTrees) (_swig_ret TreesClassTrees) + TreesTest3(arg2 TreesClassTrees) (_swig_ret TreesClassTrees) + TreesTest4(arg2 TreesClassTrees) (_swig_ret TreesClassTrees) + TreesTest5(arg2 TreesClassTrees) (_swig_ret TreesClassTrees) + TreesTest6(arg2 TreesClassTrees) (_swig_ret TreesClassTrees) + TreesTest7(arg2 TreesClassTrees) (_swig_ret TreesClassTrees) + TreesTest8(arg2 TreesClassTrees) (_swig_ret TreesClassTrees) + TreesTest9(arg2 TreesClassTrees) (_swig_ret TreesClassTrees) + TreesTestA(arg2 TreesClassTrees) (_swig_ret TreesClassTrees) + TreesTestB(arg2 TreesClassTrees) (_swig_ret TreesClassTrees) + TreesTestC(arg2 TreesClassTrees) (_swig_ret TreesClassTrees) + TreesTestD(arg2 TreesClassTrees) (_swig_ret TreesClassTrees) + TreesTestE(arg2 TreesClassTrees) (_swig_ret TreesClassTrees) + TreesTestF(arg2 TreesClassTrees) (_swig_ret TreesClassTrees) + TreesTestG(arg2 TreesClassTrees) (_swig_ret TreesClassTrees) + TreesTestH(arg2 TreesClassTrees) (_swig_ret TreesClassTrees) + TreesTestI(arg2 TreesClassTrees) (_swig_ret TreesClassTrees) + TreesTestJ(arg2 TreesClassTrees) (_swig_ret TreesClassTrees) + TreesTestK(arg2 TreesClassTrees) (_swig_ret TreesClassTrees) + TreesTestL(arg2 TreesClassTrees) (_swig_ret TreesClassTrees) + TreesTestM(arg2 TreesClassTrees) (_swig_ret TreesClassTrees) + TreesTestN(arg2 TreesClassTrees) (_swig_ret TreesClassTrees) + TreesTestO(arg2 TreesClassTrees) (_swig_ret TreesClassTrees) +} + +var _wrap_treesTest1 unsafe.Pointer + +func TreesTest1(arg1 TreesClassTrees) (_swig_ret TreesClassTrees) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_treesTest1, _swig_p) + return +} +var _wrap_treesTest2 unsafe.Pointer + +func TreesTest2(arg1 TreesClassTrees) (_swig_ret TreesClassTrees) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_treesTest2, _swig_p) + return +} +var _wrap_treesTest3 unsafe.Pointer + +func TreesTest3(arg1 TreesClassTrees) (_swig_ret TreesClassTrees) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_treesTest3, _swig_p) + return +} +var _wrap_treesTest4 unsafe.Pointer + +func TreesTest4(arg1 TreesClassTrees) (_swig_ret TreesClassTrees) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_treesTest4, _swig_p) + return +} +var _wrap_treesTest5 unsafe.Pointer + +func TreesTest5(arg1 TreesClassTrees) (_swig_ret TreesClassTrees) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_treesTest5, _swig_p) + return +} +var _wrap_treesTest6 unsafe.Pointer + +func TreesTest6(arg1 TreesClassTrees) (_swig_ret TreesClassTrees) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_treesTest6, _swig_p) + return +} +var _wrap_treesTest7 unsafe.Pointer + +func TreesTest7(arg1 TreesClassTrees) (_swig_ret TreesClassTrees) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_treesTest7, _swig_p) + return +} +var _wrap_treesTest8 unsafe.Pointer + +func TreesTest8(arg1 TreesClassTrees) (_swig_ret TreesClassTrees) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_treesTest8, _swig_p) + return +} +var _wrap_treesTest9 unsafe.Pointer + +func TreesTest9(arg1 TreesClassTrees) (_swig_ret TreesClassTrees) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_treesTest9, _swig_p) + return +} +var _wrap_treesTestA unsafe.Pointer + +func TreesTestA(arg1 TreesClassTrees) (_swig_ret TreesClassTrees) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_treesTestA, _swig_p) + return +} +var _wrap_treesTestB unsafe.Pointer + +func TreesTestB(arg1 TreesClassTrees) (_swig_ret TreesClassTrees) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_treesTestB, _swig_p) + return +} +var _wrap_treesTestC unsafe.Pointer + +func TreesTestC(arg1 TreesClassTrees) (_swig_ret TreesClassTrees) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_treesTestC, _swig_p) + return +} +var _wrap_treesTestD unsafe.Pointer + +func TreesTestD(arg1 TreesClassTrees) (_swig_ret TreesClassTrees) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_treesTestD, _swig_p) + return +} +var _wrap_treesTestE unsafe.Pointer + +func TreesTestE(arg1 TreesClassTrees) (_swig_ret TreesClassTrees) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_treesTestE, _swig_p) + return +} +var _wrap_treesTestF unsafe.Pointer + +func TreesTestF(arg1 TreesClassTrees) (_swig_ret TreesClassTrees) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_treesTestF, _swig_p) + return +} +var _wrap_treesTestG unsafe.Pointer + +func TreesTestG(arg1 TreesClassTrees) (_swig_ret TreesClassTrees) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_treesTestG, _swig_p) + return +} +var _wrap_treesTestH unsafe.Pointer + +func TreesTestH(arg1 TreesClassTrees) (_swig_ret TreesClassTrees) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_treesTestH, _swig_p) + return +} +var _wrap_treesTestI unsafe.Pointer + +func TreesTestI(arg1 TreesClassTrees) (_swig_ret TreesClassTrees) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_treesTestI, _swig_p) + return +} +var _wrap_treesTestJ unsafe.Pointer + +func TreesTestJ(arg1 TreesClassTrees) (_swig_ret TreesClassTrees) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_treesTestJ, _swig_p) + return +} +var _wrap_treesTestK unsafe.Pointer + +func TreesTestK(arg1 TreesClassTrees) (_swig_ret TreesClassTrees) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_treesTestK, _swig_p) + return +} +var _wrap_treesTestL unsafe.Pointer + +func TreesTestL(arg1 TreesClassTrees) (_swig_ret TreesClassTrees) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_treesTestL, _swig_p) + return +} +var _wrap_treesTestM unsafe.Pointer + +func TreesTestM(arg1 TreesClassTrees) (_swig_ret TreesClassTrees) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_treesTestM, _swig_p) + return +} +var _wrap_treesTestO unsafe.Pointer + +func TreesTestO(arg1 TreesClassTrees) (_swig_ret TreesClassTrees) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_treesTestO, _swig_p) + return +} +var _wrap_treesTestP unsafe.Pointer + +func TreesTestP(arg1 TreesClassTrees) (_swig_ret TreesClassTrees) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_treesTestP, _swig_p) + return +} +var _wrap_treesTestQ unsafe.Pointer + +func TreesTestQ(arg1 TreesClassTrees) (_swig_ret TreesClassTrees) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_treesTestQ, _swig_p) + return +} +var _wrap_treesTestR unsafe.Pointer + +func TreesTestR(arg1 TreesClassTrees) (_swig_ret TreesClassTrees) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_treesTestR, _swig_p) + return +} +type SwigcptrHairStruct uintptr + +func (p SwigcptrHairStruct) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrHairStruct) SwigIsHairStruct() { +} + +type CurlyGreasyHairStructHair int +var _wrap_blonde_HairStruct unsafe.Pointer + +func _swig_getHairStruct_blonde_HairStruct() (_swig_ret CurlyGreasyHairStructHair) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_blonde_HairStruct, _swig_p) + return +} +var HairStructBlonde CurlyGreasyHairStructHair = _swig_getHairStruct_blonde_HairStruct() +var _wrap_ginger_HairStruct unsafe.Pointer + +func _swig_getHairStruct_ginger_HairStruct() (_swig_ret CurlyGreasyHairStructHair) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_ginger_HairStruct, _swig_p) + return +} +var HairStructGinger CurlyGreasyHairStructHair = _swig_getHairStruct_ginger_HairStruct() +var _wrap_HairStruct_hairTest1 unsafe.Pointer + +func _swig_wrap_HairStruct_hairTest1(base SwigcptrHairStruct, _ CurlyGreasyHairStructHair) (_ CurlyGreasyHairStructHair) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_HairStruct_hairTest1, _swig_p) + return +} + +func (arg1 SwigcptrHairStruct) HairTest1(arg2 CurlyGreasyHairStructHair) (_swig_ret CurlyGreasyHairStructHair) { + return _swig_wrap_HairStruct_hairTest1(arg1, arg2) +} + +var _wrap_HairStruct_hairTest2 unsafe.Pointer + +func _swig_wrap_HairStruct_hairTest2(base SwigcptrHairStruct, _ CurlyGreasyHairStructHair) (_ CurlyGreasyHairStructHair) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_HairStruct_hairTest2, _swig_p) + return +} + +func (arg1 SwigcptrHairStruct) HairTest2(arg2 CurlyGreasyHairStructHair) (_swig_ret CurlyGreasyHairStructHair) { + return _swig_wrap_HairStruct_hairTest2(arg1, arg2) +} + +var _wrap_HairStruct_hairTest3 unsafe.Pointer + +func _swig_wrap_HairStruct_hairTest3(base SwigcptrHairStruct, _ CurlyGreasyHairStructHair) (_ CurlyGreasyHairStructHair) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_HairStruct_hairTest3, _swig_p) + return +} + +func (arg1 SwigcptrHairStruct) HairTest3(arg2 CurlyGreasyHairStructHair) (_swig_ret CurlyGreasyHairStructHair) { + return _swig_wrap_HairStruct_hairTest3(arg1, arg2) +} + +var _wrap_HairStruct_hairTest4 unsafe.Pointer + +func _swig_wrap_HairStruct_hairTest4(base SwigcptrHairStruct, _ CurlyGreasyHairStructHair) (_ CurlyGreasyHairStructHair) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_HairStruct_hairTest4, _swig_p) + return +} + +func (arg1 SwigcptrHairStruct) HairTest4(arg2 CurlyGreasyHairStructHair) (_swig_ret CurlyGreasyHairStructHair) { + return _swig_wrap_HairStruct_hairTest4(arg1, arg2) +} + +var _wrap_HairStruct_hairTest5 unsafe.Pointer + +func _swig_wrap_HairStruct_hairTest5(base SwigcptrHairStruct, _ CurlyGreasyHairStructHair) (_ CurlyGreasyHairStructHair) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_HairStruct_hairTest5, _swig_p) + return +} + +func (arg1 SwigcptrHairStruct) HairTest5(arg2 CurlyGreasyHairStructHair) (_swig_ret CurlyGreasyHairStructHair) { + return _swig_wrap_HairStruct_hairTest5(arg1, arg2) +} + +var _wrap_HairStruct_hairTest6 unsafe.Pointer + +func _swig_wrap_HairStruct_hairTest6(base SwigcptrHairStruct, _ CurlyGreasyHairStructHair) (_ CurlyGreasyHairStructHair) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_HairStruct_hairTest6, _swig_p) + return +} + +func (arg1 SwigcptrHairStruct) HairTest6(arg2 CurlyGreasyHairStructHair) (_swig_ret CurlyGreasyHairStructHair) { + return _swig_wrap_HairStruct_hairTest6(arg1, arg2) +} + +var _wrap_HairStruct_hairTest7 unsafe.Pointer + +func _swig_wrap_HairStruct_hairTest7(base SwigcptrHairStruct, _ CurlyGreasyHairStructHair) (_ CurlyGreasyHairStructHair) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_HairStruct_hairTest7, _swig_p) + return +} + +func (arg1 SwigcptrHairStruct) HairTest7(arg2 CurlyGreasyHairStructHair) (_swig_ret CurlyGreasyHairStructHair) { + return _swig_wrap_HairStruct_hairTest7(arg1, arg2) +} + +var _wrap_HairStruct_hairTest8 unsafe.Pointer + +func _swig_wrap_HairStruct_hairTest8(base SwigcptrHairStruct, _ CurlyGreasyHairStructHair) (_ CurlyGreasyHairStructHair) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_HairStruct_hairTest8, _swig_p) + return +} + +func (arg1 SwigcptrHairStruct) HairTest8(arg2 CurlyGreasyHairStructHair) (_swig_ret CurlyGreasyHairStructHair) { + return _swig_wrap_HairStruct_hairTest8(arg1, arg2) +} + +var _wrap_HairStruct_hairTest9 unsafe.Pointer + +func _swig_wrap_HairStruct_hairTest9(base SwigcptrHairStruct, _ CurlyGreasyHairStructHair) (_ CurlyGreasyHairStructHair) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_HairStruct_hairTest9, _swig_p) + return +} + +func (arg1 SwigcptrHairStruct) HairTest9(arg2 CurlyGreasyHairStructHair) (_swig_ret CurlyGreasyHairStructHair) { + return _swig_wrap_HairStruct_hairTest9(arg1, arg2) +} + +var _wrap_HairStruct_hairTestA unsafe.Pointer + +func _swig_wrap_HairStruct_hairTestA(base SwigcptrHairStruct, _ CurlyGreasyHairStructHair) (_ CurlyGreasyHairStructHair) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_HairStruct_hairTestA, _swig_p) + return +} + +func (arg1 SwigcptrHairStruct) HairTestA(arg2 CurlyGreasyHairStructHair) (_swig_ret CurlyGreasyHairStructHair) { + return _swig_wrap_HairStruct_hairTestA(arg1, arg2) +} + +var _wrap_HairStruct_hairTestB unsafe.Pointer + +func _swig_wrap_HairStruct_hairTestB(base SwigcptrHairStruct, _ CurlyGreasyHairStructHair) (_ CurlyGreasyHairStructHair) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_HairStruct_hairTestB, _swig_p) + return +} + +func (arg1 SwigcptrHairStruct) HairTestB(arg2 CurlyGreasyHairStructHair) (_swig_ret CurlyGreasyHairStructHair) { + return _swig_wrap_HairStruct_hairTestB(arg1, arg2) +} + +var _wrap_HairStruct_colourTest1 unsafe.Pointer + +func _swig_wrap_HairStruct_colourTest1(base SwigcptrHairStruct, _ Colour) (_ Colour) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_HairStruct_colourTest1, _swig_p) + return +} + +func (arg1 SwigcptrHairStruct) ColourTest1(arg2 Colour) (_swig_ret Colour) { + return _swig_wrap_HairStruct_colourTest1(arg1, arg2) +} + +var _wrap_HairStruct_colourTest2 unsafe.Pointer + +func _swig_wrap_HairStruct_colourTest2(base SwigcptrHairStruct, _ Colour) (_ Colour) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_HairStruct_colourTest2, _swig_p) + return +} + +func (arg1 SwigcptrHairStruct) ColourTest2(arg2 Colour) (_swig_ret Colour) { + return _swig_wrap_HairStruct_colourTest2(arg1, arg2) +} + +var _wrap_HairStruct_namedanonTest1 unsafe.Pointer + +func _swig_wrap_HairStruct_namedanonTest1(base SwigcptrHairStruct, _ Namedanon) (_ Namedanon) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_HairStruct_namedanonTest1, _swig_p) + return +} + +func (arg1 SwigcptrHairStruct) NamedanonTest1(arg2 Namedanon) (_swig_ret Namedanon) { + return _swig_wrap_HairStruct_namedanonTest1(arg1, arg2) +} + +var _wrap_HairStruct_namedanonspaceTest1 unsafe.Pointer + +func _swig_wrap_HairStruct_namedanonspaceTest1(base SwigcptrHairStruct, _ AnonSpaceNamedanonspace) (_ AnonSpaceNamedanonspace) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_HairStruct_namedanonspaceTest1, _swig_p) + return +} + +func (arg1 SwigcptrHairStruct) NamedanonspaceTest1(arg2 AnonSpaceNamedanonspace) (_swig_ret AnonSpaceNamedanonspace) { + return _swig_wrap_HairStruct_namedanonspaceTest1(arg1, arg2) +} + +var _wrap_HairStruct_treesGlobalTest1 unsafe.Pointer + +func _swig_wrap_HairStruct_treesGlobalTest1(base SwigcptrHairStruct, _ TreesClassTrees) (_ TreesClassTrees) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_HairStruct_treesGlobalTest1, _swig_p) + return +} + +func (arg1 SwigcptrHairStruct) TreesGlobalTest1(arg2 TreesClassTrees) (_swig_ret TreesClassTrees) { + return _swig_wrap_HairStruct_treesGlobalTest1(arg1, arg2) +} + +var _wrap_HairStruct_treesGlobalTest2 unsafe.Pointer + +func _swig_wrap_HairStruct_treesGlobalTest2(base SwigcptrHairStruct, _ TreesClassTrees) (_ TreesClassTrees) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_HairStruct_treesGlobalTest2, _swig_p) + return +} + +func (arg1 SwigcptrHairStruct) TreesGlobalTest2(arg2 TreesClassTrees) (_swig_ret TreesClassTrees) { + return _swig_wrap_HairStruct_treesGlobalTest2(arg1, arg2) +} + +var _wrap_HairStruct_treesGlobalTest3 unsafe.Pointer + +func _swig_wrap_HairStruct_treesGlobalTest3(base SwigcptrHairStruct, _ TreesClassTrees) (_ TreesClassTrees) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_HairStruct_treesGlobalTest3, _swig_p) + return +} + +func (arg1 SwigcptrHairStruct) TreesGlobalTest3(arg2 TreesClassTrees) (_swig_ret TreesClassTrees) { + return _swig_wrap_HairStruct_treesGlobalTest3(arg1, arg2) +} + +var _wrap_HairStruct_treesGlobalTest4 unsafe.Pointer + +func _swig_wrap_HairStruct_treesGlobalTest4(base SwigcptrHairStruct, _ TreesClassTrees) (_ TreesClassTrees) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_HairStruct_treesGlobalTest4, _swig_p) + return +} + +func (arg1 SwigcptrHairStruct) TreesGlobalTest4(arg2 TreesClassTrees) (_swig_ret TreesClassTrees) { + return _swig_wrap_HairStruct_treesGlobalTest4(arg1, arg2) +} + +var _wrap_HairStruct_treesGlobalTest5 unsafe.Pointer + +func _swig_wrap_HairStruct_treesGlobalTest5(base SwigcptrHairStruct, _ TreesClassTrees) (_ TreesClassTrees) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_HairStruct_treesGlobalTest5, _swig_p) + return +} + +func (arg1 SwigcptrHairStruct) TreesGlobalTest5(arg2 TreesClassTrees) (_swig_ret TreesClassTrees) { + return _swig_wrap_HairStruct_treesGlobalTest5(arg1, arg2) +} + +var _wrap_new_HairStruct unsafe.Pointer + +func _swig_wrap_new_HairStruct() (base SwigcptrHairStruct) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_HairStruct, _swig_p) + return +} + +func NewHairStruct() (_swig_ret HairStruct) { + return _swig_wrap_new_HairStruct() +} + +var _wrap_delete_HairStruct unsafe.Pointer + +func _swig_wrap_delete_HairStruct(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_HairStruct, _swig_p) + return +} + +func DeleteHairStruct(arg1 HairStruct) { + _swig_wrap_delete_HairStruct(arg1.Swigcptr()) +} + +type HairStruct interface { + Swigcptr() uintptr + SwigIsHairStruct() + HairTest1(arg2 CurlyGreasyHairStructHair) (_swig_ret CurlyGreasyHairStructHair) + HairTest2(arg2 CurlyGreasyHairStructHair) (_swig_ret CurlyGreasyHairStructHair) + HairTest3(arg2 CurlyGreasyHairStructHair) (_swig_ret CurlyGreasyHairStructHair) + HairTest4(arg2 CurlyGreasyHairStructHair) (_swig_ret CurlyGreasyHairStructHair) + HairTest5(arg2 CurlyGreasyHairStructHair) (_swig_ret CurlyGreasyHairStructHair) + HairTest6(arg2 CurlyGreasyHairStructHair) (_swig_ret CurlyGreasyHairStructHair) + HairTest7(arg2 CurlyGreasyHairStructHair) (_swig_ret CurlyGreasyHairStructHair) + HairTest8(arg2 CurlyGreasyHairStructHair) (_swig_ret CurlyGreasyHairStructHair) + HairTest9(arg2 CurlyGreasyHairStructHair) (_swig_ret CurlyGreasyHairStructHair) + HairTestA(arg2 CurlyGreasyHairStructHair) (_swig_ret CurlyGreasyHairStructHair) + HairTestB(arg2 CurlyGreasyHairStructHair) (_swig_ret CurlyGreasyHairStructHair) + ColourTest1(arg2 Colour) (_swig_ret Colour) + ColourTest2(arg2 Colour) (_swig_ret Colour) + NamedanonTest1(arg2 Namedanon) (_swig_ret Namedanon) + NamedanonspaceTest1(arg2 AnonSpaceNamedanonspace) (_swig_ret AnonSpaceNamedanonspace) + TreesGlobalTest1(arg2 TreesClassTrees) (_swig_ret TreesClassTrees) + TreesGlobalTest2(arg2 TreesClassTrees) (_swig_ret TreesClassTrees) + TreesGlobalTest3(arg2 TreesClassTrees) (_swig_ret TreesClassTrees) + TreesGlobalTest4(arg2 TreesClassTrees) (_swig_ret TreesClassTrees) + TreesGlobalTest5(arg2 TreesClassTrees) (_swig_ret TreesClassTrees) +} + +var _wrap_hairTest1 unsafe.Pointer + +func HairTest1(arg1 CurlyGreasyHairStructHair) (_swig_ret CurlyGreasyHairStructHair) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_hairTest1, _swig_p) + return +} +var _wrap_hairTest2 unsafe.Pointer + +func HairTest2(arg1 CurlyGreasyHairStructHair) (_swig_ret CurlyGreasyHairStructHair) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_hairTest2, _swig_p) + return +} +var _wrap_hairTest3 unsafe.Pointer + +func HairTest3(arg1 CurlyGreasyHairStructHair) (_swig_ret CurlyGreasyHairStructHair) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_hairTest3, _swig_p) + return +} +var _wrap_hairTest4 unsafe.Pointer + +func HairTest4(arg1 CurlyGreasyHairStructHair) (_swig_ret CurlyGreasyHairStructHair) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_hairTest4, _swig_p) + return +} +var _wrap_hairTest5 unsafe.Pointer + +func HairTest5(arg1 CurlyGreasyHairStructHair) (_swig_ret CurlyGreasyHairStructHair) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_hairTest5, _swig_p) + return +} +var _wrap_hairTest6 unsafe.Pointer + +func HairTest6(arg1 CurlyGreasyHairStructHair) (_swig_ret CurlyGreasyHairStructHair) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_hairTest6, _swig_p) + return +} +var _wrap_hairTest7 unsafe.Pointer + +func HairTest7(arg1 CurlyGreasyHairStructHair) (_swig_ret CurlyGreasyHairStructHair) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_hairTest7, _swig_p) + return +} +var _wrap_hairTest8 unsafe.Pointer + +func HairTest8(arg1 CurlyGreasyHairStructHair) (_swig_ret CurlyGreasyHairStructHair) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_hairTest8, _swig_p) + return +} +var _wrap_hairTest9 unsafe.Pointer + +func HairTest9(arg1 CurlyGreasyHairStructHair) (_swig_ret CurlyGreasyHairStructHair) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_hairTest9, _swig_p) + return +} +var _wrap_hairTestA unsafe.Pointer + +func HairTestA(arg1 CurlyGreasyHairStructHair) (_swig_ret CurlyGreasyHairStructHair) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_hairTestA, _swig_p) + return +} +var _wrap_hairTestB unsafe.Pointer + +func HairTestB(arg1 CurlyGreasyHairStructHair) (_swig_ret CurlyGreasyHairStructHair) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_hairTestB, _swig_p) + return +} +var _wrap_hairTestC unsafe.Pointer + +func HairTestC(arg1 *CurlyGreasyHairStructHair) (_swig_ret *CurlyGreasyHairStructHair) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_hairTestC, _swig_p) + return +} +var _wrap_hairTestA1 unsafe.Pointer + +func HairTestA1(arg1 CurlyGreasyHairStructHair) (_swig_ret CurlyGreasyHairStructHair) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_hairTestA1, _swig_p) + return +} +var _wrap_hairTestA2 unsafe.Pointer + +func HairTestA2(arg1 CurlyGreasyHairStructHair) (_swig_ret CurlyGreasyHairStructHair) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_hairTestA2, _swig_p) + return +} +var _wrap_hairTestA3 unsafe.Pointer + +func HairTestA3(arg1 CurlyGreasyHairStructHair) (_swig_ret CurlyGreasyHairStructHair) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_hairTestA3, _swig_p) + return +} +var _wrap_hairTestA4 unsafe.Pointer + +func HairTestA4(arg1 CurlyGreasyHairStructHair) (_swig_ret CurlyGreasyHairStructHair) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_hairTestA4, _swig_p) + return +} +var _wrap_hairTestA5 unsafe.Pointer + +func HairTestA5(arg1 CurlyGreasyHairStructHair) (_swig_ret CurlyGreasyHairStructHair) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_hairTestA5, _swig_p) + return +} +var _wrap_hairTestA6 unsafe.Pointer + +func HairTestA6(arg1 CurlyGreasyHairStructHair) (_swig_ret CurlyGreasyHairStructHair) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_hairTestA6, _swig_p) + return +} +var _wrap_hairTestA7 unsafe.Pointer + +func HairTestA7(arg1 CurlyGreasyHairStructHair) (_swig_ret CurlyGreasyHairStructHair) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_hairTestA7, _swig_p) + return +} +var _wrap_hairTestA8 unsafe.Pointer + +func HairTestA8(arg1 CurlyGreasyHairStructHair) (_swig_ret CurlyGreasyHairStructHair) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_hairTestA8, _swig_p) + return +} +var _wrap_hairTestA9 unsafe.Pointer + +func HairTestA9(arg1 CurlyGreasyHairStructHair) (_swig_ret CurlyGreasyHairStructHair) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_hairTestA9, _swig_p) + return +} +var _wrap_hairTestAA unsafe.Pointer + +func HairTestAA(arg1 CurlyGreasyHairStructHair) (_swig_ret CurlyGreasyHairStructHair) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_hairTestAA, _swig_p) + return +} +var _wrap_hairTestAB unsafe.Pointer + +func HairTestAB(arg1 CurlyGreasyHairStructHair) (_swig_ret CurlyGreasyHairStructHair) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_hairTestAB, _swig_p) + return +} +var _wrap_hairTestAC unsafe.Pointer + +func HairTestAC(arg1 *CurlyGreasyHairStructHair) (_swig_ret *CurlyGreasyHairStructHair) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_hairTestAC, _swig_p) + return +} +var _wrap_hairTestB1 unsafe.Pointer + +func HairTestB1(arg1 CurlyGreasyHairStructHair) (_swig_ret CurlyGreasyHairStructHair) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_hairTestB1, _swig_p) + return +} +var _wrap_hairTestB2 unsafe.Pointer + +func HairTestB2(arg1 CurlyGreasyHairStructHair) (_swig_ret CurlyGreasyHairStructHair) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_hairTestB2, _swig_p) + return +} +var _wrap_hairTestB3 unsafe.Pointer + +func HairTestB3(arg1 CurlyGreasyHairStructHair) (_swig_ret CurlyGreasyHairStructHair) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_hairTestB3, _swig_p) + return +} +var _wrap_hairTestB4 unsafe.Pointer + +func HairTestB4(arg1 CurlyGreasyHairStructHair) (_swig_ret CurlyGreasyHairStructHair) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_hairTestB4, _swig_p) + return +} +var _wrap_hairTestB5 unsafe.Pointer + +func HairTestB5(arg1 CurlyGreasyHairStructHair) (_swig_ret CurlyGreasyHairStructHair) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_hairTestB5, _swig_p) + return +} +var _wrap_hairTestB6 unsafe.Pointer + +func HairTestB6(arg1 CurlyGreasyHairStructHair) (_swig_ret CurlyGreasyHairStructHair) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_hairTestB6, _swig_p) + return +} +var _wrap_hairTestB7 unsafe.Pointer + +func HairTestB7(arg1 CurlyGreasyHairStructHair) (_swig_ret CurlyGreasyHairStructHair) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_hairTestB7, _swig_p) + return +} +var _wrap_hairTestB8 unsafe.Pointer + +func HairTestB8(arg1 CurlyGreasyHairStructHair) (_swig_ret CurlyGreasyHairStructHair) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_hairTestB8, _swig_p) + return +} +var _wrap_hairTestB9 unsafe.Pointer + +func HairTestB9(arg1 CurlyGreasyHairStructHair) (_swig_ret CurlyGreasyHairStructHair) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_hairTestB9, _swig_p) + return +} +var _wrap_hairTestBA unsafe.Pointer + +func HairTestBA(arg1 CurlyGreasyHairStructHair) (_swig_ret CurlyGreasyHairStructHair) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_hairTestBA, _swig_p) + return +} +var _wrap_hairTestBB unsafe.Pointer + +func HairTestBB(arg1 CurlyGreasyHairStructHair) (_swig_ret CurlyGreasyHairStructHair) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_hairTestBB, _swig_p) + return +} +var _wrap_hairTestBC unsafe.Pointer + +func HairTestBC(arg1 *CurlyGreasyHairStructHair) (_swig_ret *CurlyGreasyHairStructHair) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_hairTestBC, _swig_p) + return +} +var _wrap_hairTestC1 unsafe.Pointer + +func HairTestC1(arg1 CurlyGreasyHairStructHair) (_swig_ret CurlyGreasyHairStructHair) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_hairTestC1, _swig_p) + return +} +var _wrap_hairTestC2 unsafe.Pointer + +func HairTestC2(arg1 CurlyGreasyHairStructHair) (_swig_ret CurlyGreasyHairStructHair) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_hairTestC2, _swig_p) + return +} +var _wrap_hairTestC3 unsafe.Pointer + +func HairTestC3(arg1 CurlyGreasyHairStructHair) (_swig_ret CurlyGreasyHairStructHair) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_hairTestC3, _swig_p) + return +} +var _wrap_hairTestC4 unsafe.Pointer + +func HairTestC4(arg1 CurlyGreasyHairStructHair) (_swig_ret CurlyGreasyHairStructHair) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_hairTestC4, _swig_p) + return +} +var _wrap_hairTestC5 unsafe.Pointer + +func HairTestC5(arg1 CurlyGreasyHairStructHair) (_swig_ret CurlyGreasyHairStructHair) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_hairTestC5, _swig_p) + return +} +var _wrap_hairTestC6 unsafe.Pointer + +func HairTestC6(arg1 CurlyGreasyHairStructHair) (_swig_ret CurlyGreasyHairStructHair) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_hairTestC6, _swig_p) + return +} +var _wrap_hairTestC7 unsafe.Pointer + +func HairTestC7(arg1 CurlyGreasyHairStructHair) (_swig_ret CurlyGreasyHairStructHair) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_hairTestC7, _swig_p) + return +} +var _wrap_hairTestC8 unsafe.Pointer + +func HairTestC8(arg1 CurlyGreasyHairStructHair) (_swig_ret CurlyGreasyHairStructHair) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_hairTestC8, _swig_p) + return +} +var _wrap_hairTestC9 unsafe.Pointer + +func HairTestC9(arg1 CurlyGreasyHairStructHair) (_swig_ret CurlyGreasyHairStructHair) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_hairTestC9, _swig_p) + return +} +var _wrap_hairTestCA unsafe.Pointer + +func HairTestCA(arg1 CurlyGreasyHairStructHair) (_swig_ret CurlyGreasyHairStructHair) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_hairTestCA, _swig_p) + return +} +var _wrap_hairTestCB unsafe.Pointer + +func HairTestCB(arg1 CurlyGreasyHairStructHair) (_swig_ret CurlyGreasyHairStructHair) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_hairTestCB, _swig_p) + return +} +var _wrap_hairTestCC unsafe.Pointer + +func HairTestCC(arg1 *CurlyGreasyHairStructHair) (_swig_ret *CurlyGreasyHairStructHair) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_hairTestCC, _swig_p) + return +} +type SwigcptrFirStruct uintptr + +func (p SwigcptrFirStruct) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrFirStruct) SwigIsFirStruct() { +} + +var _wrap_FirStruct_hairTestFir1 unsafe.Pointer + +func _swig_wrap_FirStruct_hairTestFir1(base SwigcptrFirStruct, _ CurlyGreasyHairStructHair) (_ CurlyGreasyHairStructHair) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_FirStruct_hairTestFir1, _swig_p) + return +} + +func (arg1 SwigcptrFirStruct) HairTestFir1(arg2 CurlyGreasyHairStructHair) (_swig_ret CurlyGreasyHairStructHair) { + return _swig_wrap_FirStruct_hairTestFir1(arg1, arg2) +} + +var _wrap_FirStruct_hairTestFir2 unsafe.Pointer + +func _swig_wrap_FirStruct_hairTestFir2(base SwigcptrFirStruct, _ CurlyGreasyHairStructHair) (_ CurlyGreasyHairStructHair) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_FirStruct_hairTestFir2, _swig_p) + return +} + +func (arg1 SwigcptrFirStruct) HairTestFir2(arg2 CurlyGreasyHairStructHair) (_swig_ret CurlyGreasyHairStructHair) { + return _swig_wrap_FirStruct_hairTestFir2(arg1, arg2) +} + +var _wrap_FirStruct_hairTestFir3 unsafe.Pointer + +func _swig_wrap_FirStruct_hairTestFir3(base SwigcptrFirStruct, _ CurlyGreasyHairStructHair) (_ CurlyGreasyHairStructHair) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_FirStruct_hairTestFir3, _swig_p) + return +} + +func (arg1 SwigcptrFirStruct) HairTestFir3(arg2 CurlyGreasyHairStructHair) (_swig_ret CurlyGreasyHairStructHair) { + return _swig_wrap_FirStruct_hairTestFir3(arg1, arg2) +} + +var _wrap_FirStruct_hairTestFir4 unsafe.Pointer + +func _swig_wrap_FirStruct_hairTestFir4(base SwigcptrFirStruct, _ CurlyGreasyHairStructHair) (_ CurlyGreasyHairStructHair) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_FirStruct_hairTestFir4, _swig_p) + return +} + +func (arg1 SwigcptrFirStruct) HairTestFir4(arg2 CurlyGreasyHairStructHair) (_swig_ret CurlyGreasyHairStructHair) { + return _swig_wrap_FirStruct_hairTestFir4(arg1, arg2) +} + +var _wrap_FirStruct_hairTestFir5 unsafe.Pointer + +func _swig_wrap_FirStruct_hairTestFir5(base SwigcptrFirStruct, _ CurlyGreasyHairStructHair) (_ CurlyGreasyHairStructHair) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_FirStruct_hairTestFir5, _swig_p) + return +} + +func (arg1 SwigcptrFirStruct) HairTestFir5(arg2 CurlyGreasyHairStructHair) (_swig_ret CurlyGreasyHairStructHair) { + return _swig_wrap_FirStruct_hairTestFir5(arg1, arg2) +} + +var _wrap_FirStruct_hairTestFir6 unsafe.Pointer + +func _swig_wrap_FirStruct_hairTestFir6(base SwigcptrFirStruct, _ CurlyGreasyHairStructHair) (_ CurlyGreasyHairStructHair) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_FirStruct_hairTestFir6, _swig_p) + return +} + +func (arg1 SwigcptrFirStruct) HairTestFir6(arg2 CurlyGreasyHairStructHair) (_swig_ret CurlyGreasyHairStructHair) { + return _swig_wrap_FirStruct_hairTestFir6(arg1, arg2) +} + +var _wrap_FirStruct_hairTestFir7 unsafe.Pointer + +func _swig_wrap_FirStruct_hairTestFir7(base SwigcptrFirStruct, _ CurlyGreasyHairStructHair) (_ CurlyGreasyHairStructHair) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_FirStruct_hairTestFir7, _swig_p) + return +} + +func (arg1 SwigcptrFirStruct) HairTestFir7(arg2 CurlyGreasyHairStructHair) (_swig_ret CurlyGreasyHairStructHair) { + return _swig_wrap_FirStruct_hairTestFir7(arg1, arg2) +} + +var _wrap_FirStruct_hairTestFir8 unsafe.Pointer + +func _swig_wrap_FirStruct_hairTestFir8(base SwigcptrFirStruct, _ CurlyGreasyHairStructHair) (_ CurlyGreasyHairStructHair) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_FirStruct_hairTestFir8, _swig_p) + return +} + +func (arg1 SwigcptrFirStruct) HairTestFir8(arg2 CurlyGreasyHairStructHair) (_swig_ret CurlyGreasyHairStructHair) { + return _swig_wrap_FirStruct_hairTestFir8(arg1, arg2) +} + +var _wrap_FirStruct_hairTestFir9 unsafe.Pointer + +func _swig_wrap_FirStruct_hairTestFir9(base SwigcptrFirStruct, _ CurlyGreasyHairStructHair) (_ CurlyGreasyHairStructHair) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_FirStruct_hairTestFir9, _swig_p) + return +} + +func (arg1 SwigcptrFirStruct) HairTestFir9(arg2 CurlyGreasyHairStructHair) (_swig_ret CurlyGreasyHairStructHair) { + return _swig_wrap_FirStruct_hairTestFir9(arg1, arg2) +} + +var _wrap_FirStruct_hairTestFirA unsafe.Pointer + +func _swig_wrap_FirStruct_hairTestFirA(base SwigcptrFirStruct, _ CurlyGreasyHairStructHair) (_ CurlyGreasyHairStructHair) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_FirStruct_hairTestFirA, _swig_p) + return +} + +func (arg1 SwigcptrFirStruct) HairTestFirA(arg2 CurlyGreasyHairStructHair) (_swig_ret CurlyGreasyHairStructHair) { + return _swig_wrap_FirStruct_hairTestFirA(arg1, arg2) +} + +var _wrap_FirStruct_hairTestFirB unsafe.Pointer + +func _swig_wrap_FirStruct_hairTestFirB(base SwigcptrFirStruct, _ CurlyGreasyHairStructHair) (_ CurlyGreasyHairStructHair) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_FirStruct_hairTestFirB, _swig_p) + return +} + +func (arg1 SwigcptrFirStruct) HairTestFirB(arg2 CurlyGreasyHairStructHair) (_swig_ret CurlyGreasyHairStructHair) { + return _swig_wrap_FirStruct_hairTestFirB(arg1, arg2) +} + +var _wrap_new_FirStruct unsafe.Pointer + +func _swig_wrap_new_FirStruct() (base SwigcptrFirStruct) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_FirStruct, _swig_p) + return +} + +func NewFirStruct() (_swig_ret FirStruct) { + return _swig_wrap_new_FirStruct() +} + +var _wrap_delete_FirStruct unsafe.Pointer + +func _swig_wrap_delete_FirStruct(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_FirStruct, _swig_p) + return +} + +func DeleteFirStruct(arg1 FirStruct) { + _swig_wrap_delete_FirStruct(arg1.Swigcptr()) +} + +var _wrap_FirStruct_hairTest1 unsafe.Pointer + +func _swig_wrap_FirStruct_hairTest1(base SwigcptrFirStruct, _ CurlyGreasyHairStructHair) (_ CurlyGreasyHairStructHair) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_FirStruct_hairTest1, _swig_p) + return +} + +func (_swig_base SwigcptrFirStruct) HairTest1(arg1 CurlyGreasyHairStructHair) (_swig_ret CurlyGreasyHairStructHair) { + return _swig_wrap_FirStruct_hairTest1(_swig_base, arg1) +} + +var _wrap_FirStruct_hairTest2 unsafe.Pointer + +func _swig_wrap_FirStruct_hairTest2(base SwigcptrFirStruct, _ CurlyGreasyHairStructHair) (_ CurlyGreasyHairStructHair) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_FirStruct_hairTest2, _swig_p) + return +} + +func (_swig_base SwigcptrFirStruct) HairTest2(arg1 CurlyGreasyHairStructHair) (_swig_ret CurlyGreasyHairStructHair) { + return _swig_wrap_FirStruct_hairTest2(_swig_base, arg1) +} + +var _wrap_FirStruct_hairTest3 unsafe.Pointer + +func _swig_wrap_FirStruct_hairTest3(base SwigcptrFirStruct, _ CurlyGreasyHairStructHair) (_ CurlyGreasyHairStructHair) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_FirStruct_hairTest3, _swig_p) + return +} + +func (_swig_base SwigcptrFirStruct) HairTest3(arg1 CurlyGreasyHairStructHair) (_swig_ret CurlyGreasyHairStructHair) { + return _swig_wrap_FirStruct_hairTest3(_swig_base, arg1) +} + +var _wrap_FirStruct_hairTest4 unsafe.Pointer + +func _swig_wrap_FirStruct_hairTest4(base SwigcptrFirStruct, _ CurlyGreasyHairStructHair) (_ CurlyGreasyHairStructHair) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_FirStruct_hairTest4, _swig_p) + return +} + +func (_swig_base SwigcptrFirStruct) HairTest4(arg1 CurlyGreasyHairStructHair) (_swig_ret CurlyGreasyHairStructHair) { + return _swig_wrap_FirStruct_hairTest4(_swig_base, arg1) +} + +var _wrap_FirStruct_hairTest5 unsafe.Pointer + +func _swig_wrap_FirStruct_hairTest5(base SwigcptrFirStruct, _ CurlyGreasyHairStructHair) (_ CurlyGreasyHairStructHair) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_FirStruct_hairTest5, _swig_p) + return +} + +func (_swig_base SwigcptrFirStruct) HairTest5(arg1 CurlyGreasyHairStructHair) (_swig_ret CurlyGreasyHairStructHair) { + return _swig_wrap_FirStruct_hairTest5(_swig_base, arg1) +} + +var _wrap_FirStruct_hairTest6 unsafe.Pointer + +func _swig_wrap_FirStruct_hairTest6(base SwigcptrFirStruct, _ CurlyGreasyHairStructHair) (_ CurlyGreasyHairStructHair) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_FirStruct_hairTest6, _swig_p) + return +} + +func (_swig_base SwigcptrFirStruct) HairTest6(arg1 CurlyGreasyHairStructHair) (_swig_ret CurlyGreasyHairStructHair) { + return _swig_wrap_FirStruct_hairTest6(_swig_base, arg1) +} + +var _wrap_FirStruct_hairTest7 unsafe.Pointer + +func _swig_wrap_FirStruct_hairTest7(base SwigcptrFirStruct, _ CurlyGreasyHairStructHair) (_ CurlyGreasyHairStructHair) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_FirStruct_hairTest7, _swig_p) + return +} + +func (_swig_base SwigcptrFirStruct) HairTest7(arg1 CurlyGreasyHairStructHair) (_swig_ret CurlyGreasyHairStructHair) { + return _swig_wrap_FirStruct_hairTest7(_swig_base, arg1) +} + +var _wrap_FirStruct_hairTest8 unsafe.Pointer + +func _swig_wrap_FirStruct_hairTest8(base SwigcptrFirStruct, _ CurlyGreasyHairStructHair) (_ CurlyGreasyHairStructHair) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_FirStruct_hairTest8, _swig_p) + return +} + +func (_swig_base SwigcptrFirStruct) HairTest8(arg1 CurlyGreasyHairStructHair) (_swig_ret CurlyGreasyHairStructHair) { + return _swig_wrap_FirStruct_hairTest8(_swig_base, arg1) +} + +var _wrap_FirStruct_hairTest9 unsafe.Pointer + +func _swig_wrap_FirStruct_hairTest9(base SwigcptrFirStruct, _ CurlyGreasyHairStructHair) (_ CurlyGreasyHairStructHair) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_FirStruct_hairTest9, _swig_p) + return +} + +func (_swig_base SwigcptrFirStruct) HairTest9(arg1 CurlyGreasyHairStructHair) (_swig_ret CurlyGreasyHairStructHair) { + return _swig_wrap_FirStruct_hairTest9(_swig_base, arg1) +} + +var _wrap_FirStruct_hairTestA unsafe.Pointer + +func _swig_wrap_FirStruct_hairTestA(base SwigcptrFirStruct, _ CurlyGreasyHairStructHair) (_ CurlyGreasyHairStructHair) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_FirStruct_hairTestA, _swig_p) + return +} + +func (_swig_base SwigcptrFirStruct) HairTestA(arg1 CurlyGreasyHairStructHair) (_swig_ret CurlyGreasyHairStructHair) { + return _swig_wrap_FirStruct_hairTestA(_swig_base, arg1) +} + +var _wrap_FirStruct_hairTestB unsafe.Pointer + +func _swig_wrap_FirStruct_hairTestB(base SwigcptrFirStruct, _ CurlyGreasyHairStructHair) (_ CurlyGreasyHairStructHair) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_FirStruct_hairTestB, _swig_p) + return +} + +func (_swig_base SwigcptrFirStruct) HairTestB(arg1 CurlyGreasyHairStructHair) (_swig_ret CurlyGreasyHairStructHair) { + return _swig_wrap_FirStruct_hairTestB(_swig_base, arg1) +} + +var _wrap_FirStruct_colourTest1 unsafe.Pointer + +func _swig_wrap_FirStruct_colourTest1(base SwigcptrFirStruct, _ Colour) (_ Colour) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_FirStruct_colourTest1, _swig_p) + return +} + +func (_swig_base SwigcptrFirStruct) ColourTest1(arg1 Colour) (_swig_ret Colour) { + return _swig_wrap_FirStruct_colourTest1(_swig_base, arg1) +} + +var _wrap_FirStruct_colourTest2 unsafe.Pointer + +func _swig_wrap_FirStruct_colourTest2(base SwigcptrFirStruct, _ Colour) (_ Colour) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_FirStruct_colourTest2, _swig_p) + return +} + +func (_swig_base SwigcptrFirStruct) ColourTest2(arg1 Colour) (_swig_ret Colour) { + return _swig_wrap_FirStruct_colourTest2(_swig_base, arg1) +} + +var _wrap_FirStruct_namedanonTest1 unsafe.Pointer + +func _swig_wrap_FirStruct_namedanonTest1(base SwigcptrFirStruct, _ Namedanon) (_ Namedanon) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_FirStruct_namedanonTest1, _swig_p) + return +} + +func (_swig_base SwigcptrFirStruct) NamedanonTest1(arg1 Namedanon) (_swig_ret Namedanon) { + return _swig_wrap_FirStruct_namedanonTest1(_swig_base, arg1) +} + +var _wrap_FirStruct_namedanonspaceTest1 unsafe.Pointer + +func _swig_wrap_FirStruct_namedanonspaceTest1(base SwigcptrFirStruct, _ AnonSpaceNamedanonspace) (_ AnonSpaceNamedanonspace) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_FirStruct_namedanonspaceTest1, _swig_p) + return +} + +func (_swig_base SwigcptrFirStruct) NamedanonspaceTest1(arg1 AnonSpaceNamedanonspace) (_swig_ret AnonSpaceNamedanonspace) { + return _swig_wrap_FirStruct_namedanonspaceTest1(_swig_base, arg1) +} + +var _wrap_FirStruct_treesGlobalTest1 unsafe.Pointer + +func _swig_wrap_FirStruct_treesGlobalTest1(base SwigcptrFirStruct, _ TreesClassTrees) (_ TreesClassTrees) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_FirStruct_treesGlobalTest1, _swig_p) + return +} + +func (_swig_base SwigcptrFirStruct) TreesGlobalTest1(arg1 TreesClassTrees) (_swig_ret TreesClassTrees) { + return _swig_wrap_FirStruct_treesGlobalTest1(_swig_base, arg1) +} + +var _wrap_FirStruct_treesGlobalTest2 unsafe.Pointer + +func _swig_wrap_FirStruct_treesGlobalTest2(base SwigcptrFirStruct, _ TreesClassTrees) (_ TreesClassTrees) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_FirStruct_treesGlobalTest2, _swig_p) + return +} + +func (_swig_base SwigcptrFirStruct) TreesGlobalTest2(arg1 TreesClassTrees) (_swig_ret TreesClassTrees) { + return _swig_wrap_FirStruct_treesGlobalTest2(_swig_base, arg1) +} + +var _wrap_FirStruct_treesGlobalTest3 unsafe.Pointer + +func _swig_wrap_FirStruct_treesGlobalTest3(base SwigcptrFirStruct, _ TreesClassTrees) (_ TreesClassTrees) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_FirStruct_treesGlobalTest3, _swig_p) + return +} + +func (_swig_base SwigcptrFirStruct) TreesGlobalTest3(arg1 TreesClassTrees) (_swig_ret TreesClassTrees) { + return _swig_wrap_FirStruct_treesGlobalTest3(_swig_base, arg1) +} + +var _wrap_FirStruct_treesGlobalTest4 unsafe.Pointer + +func _swig_wrap_FirStruct_treesGlobalTest4(base SwigcptrFirStruct, _ TreesClassTrees) (_ TreesClassTrees) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_FirStruct_treesGlobalTest4, _swig_p) + return +} + +func (_swig_base SwigcptrFirStruct) TreesGlobalTest4(arg1 TreesClassTrees) (_swig_ret TreesClassTrees) { + return _swig_wrap_FirStruct_treesGlobalTest4(_swig_base, arg1) +} + +var _wrap_FirStruct_treesGlobalTest5 unsafe.Pointer + +func _swig_wrap_FirStruct_treesGlobalTest5(base SwigcptrFirStruct, _ TreesClassTrees) (_ TreesClassTrees) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_FirStruct_treesGlobalTest5, _swig_p) + return +} + +func (_swig_base SwigcptrFirStruct) TreesGlobalTest5(arg1 TreesClassTrees) (_swig_ret TreesClassTrees) { + return _swig_wrap_FirStruct_treesGlobalTest5(_swig_base, arg1) +} + +func (p SwigcptrFirStruct) SwigIsHairStruct() { +} + +func (p SwigcptrFirStruct) SwigGetHairStruct() HairStruct { + return SwigcptrHairStruct(p.Swigcptr()) +} + +type FirStruct interface { + Swigcptr() uintptr + SwigIsFirStruct() + HairTestFir1(arg2 CurlyGreasyHairStructHair) (_swig_ret CurlyGreasyHairStructHair) + HairTestFir2(arg2 CurlyGreasyHairStructHair) (_swig_ret CurlyGreasyHairStructHair) + HairTestFir3(arg2 CurlyGreasyHairStructHair) (_swig_ret CurlyGreasyHairStructHair) + HairTestFir4(arg2 CurlyGreasyHairStructHair) (_swig_ret CurlyGreasyHairStructHair) + HairTestFir5(arg2 CurlyGreasyHairStructHair) (_swig_ret CurlyGreasyHairStructHair) + HairTestFir6(arg2 CurlyGreasyHairStructHair) (_swig_ret CurlyGreasyHairStructHair) + HairTestFir7(arg2 CurlyGreasyHairStructHair) (_swig_ret CurlyGreasyHairStructHair) + HairTestFir8(arg2 CurlyGreasyHairStructHair) (_swig_ret CurlyGreasyHairStructHair) + HairTestFir9(arg2 CurlyGreasyHairStructHair) (_swig_ret CurlyGreasyHairStructHair) + HairTestFirA(arg2 CurlyGreasyHairStructHair) (_swig_ret CurlyGreasyHairStructHair) + HairTestFirB(arg2 CurlyGreasyHairStructHair) (_swig_ret CurlyGreasyHairStructHair) + HairTest1(arg1 CurlyGreasyHairStructHair) (_swig_ret CurlyGreasyHairStructHair) + HairTest2(arg1 CurlyGreasyHairStructHair) (_swig_ret CurlyGreasyHairStructHair) + HairTest3(arg1 CurlyGreasyHairStructHair) (_swig_ret CurlyGreasyHairStructHair) + HairTest4(arg1 CurlyGreasyHairStructHair) (_swig_ret CurlyGreasyHairStructHair) + HairTest5(arg1 CurlyGreasyHairStructHair) (_swig_ret CurlyGreasyHairStructHair) + HairTest6(arg1 CurlyGreasyHairStructHair) (_swig_ret CurlyGreasyHairStructHair) + HairTest7(arg1 CurlyGreasyHairStructHair) (_swig_ret CurlyGreasyHairStructHair) + HairTest8(arg1 CurlyGreasyHairStructHair) (_swig_ret CurlyGreasyHairStructHair) + HairTest9(arg1 CurlyGreasyHairStructHair) (_swig_ret CurlyGreasyHairStructHair) + HairTestA(arg1 CurlyGreasyHairStructHair) (_swig_ret CurlyGreasyHairStructHair) + HairTestB(arg1 CurlyGreasyHairStructHair) (_swig_ret CurlyGreasyHairStructHair) + ColourTest1(arg1 Colour) (_swig_ret Colour) + ColourTest2(arg1 Colour) (_swig_ret Colour) + NamedanonTest1(arg1 Namedanon) (_swig_ret Namedanon) + NamedanonspaceTest1(arg1 AnonSpaceNamedanonspace) (_swig_ret AnonSpaceNamedanonspace) + TreesGlobalTest1(arg1 TreesClassTrees) (_swig_ret TreesClassTrees) + TreesGlobalTest2(arg1 TreesClassTrees) (_swig_ret TreesClassTrees) + TreesGlobalTest3(arg1 TreesClassTrees) (_swig_ret TreesClassTrees) + TreesGlobalTest4(arg1 TreesClassTrees) (_swig_ret TreesClassTrees) + TreesGlobalTest5(arg1 TreesClassTrees) (_swig_ret TreesClassTrees) + SwigIsHairStruct() + SwigGetHairStruct() HairStruct +} + +type SwigcptrObscure uintptr + +func (p SwigcptrObscure) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrObscure) SwigIsObscure() { +} + +type ObscureZero int +type ObscureOne int +type ObscureTwo int +var _wrap_twoagain_Obscure unsafe.Pointer + +func _swig_getObscure_twoagain_Obscure() (_swig_ret ObscureTwo) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_twoagain_Obscure, _swig_p) + return +} +var ObscureTwoagain ObscureTwo = _swig_getObscure_twoagain_Obscure() +type ObscureEmpty int +type ObscureAlsoEmpty int +var _wrap_new_Obscure unsafe.Pointer + +func _swig_wrap_new_Obscure() (base SwigcptrObscure) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Obscure, _swig_p) + return +} + +func NewObscure() (_swig_ret Obscure) { + return _swig_wrap_new_Obscure() +} + +var _wrap_delete_Obscure unsafe.Pointer + +func _swig_wrap_delete_Obscure(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Obscure, _swig_p) + return +} + +func DeleteObscure(arg1 Obscure) { + _swig_wrap_delete_Obscure(arg1.Swigcptr()) +} + +type Obscure interface { + Swigcptr() uintptr + SwigIsObscure() +} + +var _wrap_globalinstance1 unsafe.Pointer + +func _swig_getglobalinstance1() (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_globalinstance1, _swig_p) + return +} +var Globalinstance1 int = _swig_getglobalinstance1() +var _wrap_globalinstance2 unsafe.Pointer + +func _swig_getglobalinstance2() (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_globalinstance2, _swig_p) + return +} +var Globalinstance2 int = _swig_getglobalinstance2() +var _wrap_globalinstance3 unsafe.Pointer + +func _swig_getglobalinstance3() (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_globalinstance3, _swig_p) + return +} +var Globalinstance3 int = _swig_getglobalinstance3() +var _wrap_GlobalInstance_set unsafe.Pointer + +func _swig_wrap_GlobalInstance_set(base int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_GlobalInstance_set, _swig_p) + return +} + +func SetGlobalInstance(arg1 int) { + _swig_wrap_GlobalInstance_set(arg1) +} + +var _wrap_GlobalInstance_get unsafe.Pointer + +func GetGlobalInstance() (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_GlobalInstance_get, _swig_p) + return +} +type SwigcptrInstances uintptr + +func (p SwigcptrInstances) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrInstances) SwigIsInstances() { +} + +var _wrap_memberinstance1_Instances unsafe.Pointer + +func _swig_getInstances_memberinstance1_Instances() (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_memberinstance1_Instances, _swig_p) + return +} +var InstancesMemberinstance1 int = _swig_getInstances_memberinstance1_Instances() +var _wrap_memberinstance2_Instances unsafe.Pointer + +func _swig_getInstances_memberinstance2_Instances() (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_memberinstance2_Instances, _swig_p) + return +} +var InstancesMemberinstance2 int = _swig_getInstances_memberinstance2_Instances() +var _wrap_memberinstance3_Instances unsafe.Pointer + +func _swig_getInstances_memberinstance3_Instances() (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_memberinstance3_Instances, _swig_p) + return +} +var InstancesMemberinstance3 int = _swig_getInstances_memberinstance3_Instances() +var _wrap_Instances_MemberInstance_set unsafe.Pointer + +func _swig_wrap_Instances_MemberInstance_set(base SwigcptrInstances, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Instances_MemberInstance_set, _swig_p) + return +} + +func (arg1 SwigcptrInstances) SetMemberInstance(arg2 int) { + _swig_wrap_Instances_MemberInstance_set(arg1, arg2) +} + +var _wrap_Instances_MemberInstance_get unsafe.Pointer + +func _swig_wrap_Instances_MemberInstance_get(base SwigcptrInstances) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Instances_MemberInstance_get, _swig_p) + return +} + +func (arg1 SwigcptrInstances) GetMemberInstance() (_swig_ret int) { + return _swig_wrap_Instances_MemberInstance_get(arg1) +} + +var _wrap_new_Instances unsafe.Pointer + +func _swig_wrap_new_Instances() (base SwigcptrInstances) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Instances, _swig_p) + return +} + +func NewInstances() (_swig_ret Instances) { + return _swig_wrap_new_Instances() +} + +var _wrap_delete_Instances unsafe.Pointer + +func _swig_wrap_delete_Instances(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Instances, _swig_p) + return +} + +func DeleteInstances(arg1 Instances) { + _swig_wrap_delete_Instances(arg1.Swigcptr()) +} + +type Instances interface { + Swigcptr() uintptr + SwigIsInstances() + SetMemberInstance(arg2 int) + GetMemberInstance() (_swig_ret int) +} + +type SwigcptrIgnoreTest uintptr + +func (p SwigcptrIgnoreTest) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrIgnoreTest) SwigIsIgnoreTest() { +} + +type IgnoreTestIgnoreA int +var _wrap_ignoreA_zero_IgnoreTest unsafe.Pointer + +func _swig_getIgnoreTest_ignoreA_zero_IgnoreTest() (_swig_ret IgnoreTestIgnoreA) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_ignoreA_zero_IgnoreTest, _swig_p) + return +} +var IgnoreTestIgnoreA_zero IgnoreTestIgnoreA = _swig_getIgnoreTest_ignoreA_zero_IgnoreTest() +var _wrap_ignoreA_three_IgnoreTest unsafe.Pointer + +func _swig_getIgnoreTest_ignoreA_three_IgnoreTest() (_swig_ret IgnoreTestIgnoreA) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_ignoreA_three_IgnoreTest, _swig_p) + return +} +var IgnoreTestIgnoreA_three IgnoreTestIgnoreA = _swig_getIgnoreTest_ignoreA_three_IgnoreTest() +var _wrap_ignoreA_ten_IgnoreTest unsafe.Pointer + +func _swig_getIgnoreTest_ignoreA_ten_IgnoreTest() (_swig_ret IgnoreTestIgnoreA) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_ignoreA_ten_IgnoreTest, _swig_p) + return +} +var IgnoreTestIgnoreA_ten IgnoreTestIgnoreA = _swig_getIgnoreTest_ignoreA_ten_IgnoreTest() +var _wrap_ignoreA_eleven_IgnoreTest unsafe.Pointer + +func _swig_getIgnoreTest_ignoreA_eleven_IgnoreTest() (_swig_ret IgnoreTestIgnoreA) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_ignoreA_eleven_IgnoreTest, _swig_p) + return +} +var IgnoreTestIgnoreA_eleven IgnoreTestIgnoreA = _swig_getIgnoreTest_ignoreA_eleven_IgnoreTest() +var _wrap_ignoreA_thirteen_IgnoreTest unsafe.Pointer + +func _swig_getIgnoreTest_ignoreA_thirteen_IgnoreTest() (_swig_ret IgnoreTestIgnoreA) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_ignoreA_thirteen_IgnoreTest, _swig_p) + return +} +var IgnoreTestIgnoreA_thirteen IgnoreTestIgnoreA = _swig_getIgnoreTest_ignoreA_thirteen_IgnoreTest() +var _wrap_ignoreA_fourteen_IgnoreTest unsafe.Pointer + +func _swig_getIgnoreTest_ignoreA_fourteen_IgnoreTest() (_swig_ret IgnoreTestIgnoreA) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_ignoreA_fourteen_IgnoreTest, _swig_p) + return +} +var IgnoreTestIgnoreA_fourteen IgnoreTestIgnoreA = _swig_getIgnoreTest_ignoreA_fourteen_IgnoreTest() +var _wrap_ignoreA_twenty_IgnoreTest unsafe.Pointer + +func _swig_getIgnoreTest_ignoreA_twenty_IgnoreTest() (_swig_ret IgnoreTestIgnoreA) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_ignoreA_twenty_IgnoreTest, _swig_p) + return +} +var IgnoreTestIgnoreA_twenty IgnoreTestIgnoreA = _swig_getIgnoreTest_ignoreA_twenty_IgnoreTest() +var _wrap_ignoreA_thirty_IgnoreTest unsafe.Pointer + +func _swig_getIgnoreTest_ignoreA_thirty_IgnoreTest() (_swig_ret IgnoreTestIgnoreA) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_ignoreA_thirty_IgnoreTest, _swig_p) + return +} +var IgnoreTestIgnoreA_thirty IgnoreTestIgnoreA = _swig_getIgnoreTest_ignoreA_thirty_IgnoreTest() +var _wrap_ignoreA_thirty_two_IgnoreTest unsafe.Pointer + +func _swig_getIgnoreTest_ignoreA_thirty_two_IgnoreTest() (_swig_ret IgnoreTestIgnoreA) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_ignoreA_thirty_two_IgnoreTest, _swig_p) + return +} +var IgnoreTestIgnoreA_thirty_two IgnoreTestIgnoreA = _swig_getIgnoreTest_ignoreA_thirty_two_IgnoreTest() +var _wrap_ignoreA_thirty_three_IgnoreTest unsafe.Pointer + +func _swig_getIgnoreTest_ignoreA_thirty_three_IgnoreTest() (_swig_ret IgnoreTestIgnoreA) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_ignoreA_thirty_three_IgnoreTest, _swig_p) + return +} +var IgnoreTestIgnoreA_thirty_three IgnoreTestIgnoreA = _swig_getIgnoreTest_ignoreA_thirty_three_IgnoreTest() +type IgnoreTestIgnoreB int +var _wrap_ignoreB_eleven_IgnoreTest unsafe.Pointer + +func _swig_getIgnoreTest_ignoreB_eleven_IgnoreTest() (_swig_ret IgnoreTestIgnoreB) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_ignoreB_eleven_IgnoreTest, _swig_p) + return +} +var IgnoreTestIgnoreB_eleven IgnoreTestIgnoreB = _swig_getIgnoreTest_ignoreB_eleven_IgnoreTest() +var _wrap_ignoreB_twelve_IgnoreTest unsafe.Pointer + +func _swig_getIgnoreTest_ignoreB_twelve_IgnoreTest() (_swig_ret IgnoreTestIgnoreB) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_ignoreB_twelve_IgnoreTest, _swig_p) + return +} +var IgnoreTestIgnoreB_twelve IgnoreTestIgnoreB = _swig_getIgnoreTest_ignoreB_twelve_IgnoreTest() +var _wrap_ignoreB_thirty_one_IgnoreTest unsafe.Pointer + +func _swig_getIgnoreTest_ignoreB_thirty_one_IgnoreTest() (_swig_ret IgnoreTestIgnoreB) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_ignoreB_thirty_one_IgnoreTest, _swig_p) + return +} +var IgnoreTestIgnoreB_thirty_one IgnoreTestIgnoreB = _swig_getIgnoreTest_ignoreB_thirty_one_IgnoreTest() +var _wrap_ignoreB_thirty_two_IgnoreTest unsafe.Pointer + +func _swig_getIgnoreTest_ignoreB_thirty_two_IgnoreTest() (_swig_ret IgnoreTestIgnoreB) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_ignoreB_thirty_two_IgnoreTest, _swig_p) + return +} +var IgnoreTestIgnoreB_thirty_two IgnoreTestIgnoreB = _swig_getIgnoreTest_ignoreB_thirty_two_IgnoreTest() +var _wrap_ignoreB_forty_one_IgnoreTest unsafe.Pointer + +func _swig_getIgnoreTest_ignoreB_forty_one_IgnoreTest() (_swig_ret IgnoreTestIgnoreB) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_ignoreB_forty_one_IgnoreTest, _swig_p) + return +} +var IgnoreTestIgnoreB_forty_one IgnoreTestIgnoreB = _swig_getIgnoreTest_ignoreB_forty_one_IgnoreTest() +var _wrap_ignoreB_forty_two_IgnoreTest unsafe.Pointer + +func _swig_getIgnoreTest_ignoreB_forty_two_IgnoreTest() (_swig_ret IgnoreTestIgnoreB) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_ignoreB_forty_two_IgnoreTest, _swig_p) + return +} +var IgnoreTestIgnoreB_forty_two IgnoreTestIgnoreB = _swig_getIgnoreTest_ignoreB_forty_two_IgnoreTest() +type IgnoreTestIgnoreC int +var _wrap_ignoreC_ten_IgnoreTest unsafe.Pointer + +func _swig_getIgnoreTest_ignoreC_ten_IgnoreTest() (_swig_ret IgnoreTestIgnoreC) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_ignoreC_ten_IgnoreTest, _swig_p) + return +} +var IgnoreTestIgnoreC_ten IgnoreTestIgnoreC = _swig_getIgnoreTest_ignoreC_ten_IgnoreTest() +var _wrap_ignoreC_twelve_IgnoreTest unsafe.Pointer + +func _swig_getIgnoreTest_ignoreC_twelve_IgnoreTest() (_swig_ret IgnoreTestIgnoreC) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_ignoreC_twelve_IgnoreTest, _swig_p) + return +} +var IgnoreTestIgnoreC_twelve IgnoreTestIgnoreC = _swig_getIgnoreTest_ignoreC_twelve_IgnoreTest() +var _wrap_ignoreC_twenty_IgnoreTest unsafe.Pointer + +func _swig_getIgnoreTest_ignoreC_twenty_IgnoreTest() (_swig_ret IgnoreTestIgnoreC) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_ignoreC_twenty_IgnoreTest, _swig_p) + return +} +var IgnoreTestIgnoreC_twenty IgnoreTestIgnoreC = _swig_getIgnoreTest_ignoreC_twenty_IgnoreTest() +var _wrap_ignoreC_thirty_IgnoreTest unsafe.Pointer + +func _swig_getIgnoreTest_ignoreC_thirty_IgnoreTest() (_swig_ret IgnoreTestIgnoreC) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_ignoreC_thirty_IgnoreTest, _swig_p) + return +} +var IgnoreTestIgnoreC_thirty IgnoreTestIgnoreC = _swig_getIgnoreTest_ignoreC_thirty_IgnoreTest() +var _wrap_ignoreC_thirty_two_IgnoreTest unsafe.Pointer + +func _swig_getIgnoreTest_ignoreC_thirty_two_IgnoreTest() (_swig_ret IgnoreTestIgnoreC) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_ignoreC_thirty_two_IgnoreTest, _swig_p) + return +} +var IgnoreTestIgnoreC_thirty_two IgnoreTestIgnoreC = _swig_getIgnoreTest_ignoreC_thirty_two_IgnoreTest() +var _wrap_ignoreC_forty_IgnoreTest unsafe.Pointer + +func _swig_getIgnoreTest_ignoreC_forty_IgnoreTest() (_swig_ret IgnoreTestIgnoreC) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_ignoreC_forty_IgnoreTest, _swig_p) + return +} +var IgnoreTestIgnoreC_forty IgnoreTestIgnoreC = _swig_getIgnoreTest_ignoreC_forty_IgnoreTest() +var _wrap_ignoreC_forty_two_IgnoreTest unsafe.Pointer + +func _swig_getIgnoreTest_ignoreC_forty_two_IgnoreTest() (_swig_ret IgnoreTestIgnoreC) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_ignoreC_forty_two_IgnoreTest, _swig_p) + return +} +var IgnoreTestIgnoreC_forty_two IgnoreTestIgnoreC = _swig_getIgnoreTest_ignoreC_forty_two_IgnoreTest() +type IgnoreTestIgnoreD int +var _wrap_ignoreD_twenty_one_IgnoreTest unsafe.Pointer + +func _swig_getIgnoreTest_ignoreD_twenty_one_IgnoreTest() (_swig_ret IgnoreTestIgnoreD) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_ignoreD_twenty_one_IgnoreTest, _swig_p) + return +} +var IgnoreTestIgnoreD_twenty_one IgnoreTestIgnoreD = _swig_getIgnoreTest_ignoreD_twenty_one_IgnoreTest() +var _wrap_ignoreD_twenty_two_IgnoreTest unsafe.Pointer + +func _swig_getIgnoreTest_ignoreD_twenty_two_IgnoreTest() (_swig_ret IgnoreTestIgnoreD) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_ignoreD_twenty_two_IgnoreTest, _swig_p) + return +} +var IgnoreTestIgnoreD_twenty_two IgnoreTestIgnoreD = _swig_getIgnoreTest_ignoreD_twenty_two_IgnoreTest() +type IgnoreTestIgnoreE int +var _wrap_ignoreE_zero_IgnoreTest unsafe.Pointer + +func _swig_getIgnoreTest_ignoreE_zero_IgnoreTest() (_swig_ret IgnoreTestIgnoreE) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_ignoreE_zero_IgnoreTest, _swig_p) + return +} +var IgnoreTestIgnoreE_zero IgnoreTestIgnoreE = _swig_getIgnoreTest_ignoreE_zero_IgnoreTest() +var _wrap_ignoreE_twenty_one_IgnoreTest unsafe.Pointer + +func _swig_getIgnoreTest_ignoreE_twenty_one_IgnoreTest() (_swig_ret IgnoreTestIgnoreE) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_ignoreE_twenty_one_IgnoreTest, _swig_p) + return +} +var IgnoreTestIgnoreE_twenty_one IgnoreTestIgnoreE = _swig_getIgnoreTest_ignoreE_twenty_one_IgnoreTest() +var _wrap_ignoreE_twenty_two_IgnoreTest unsafe.Pointer + +func _swig_getIgnoreTest_ignoreE_twenty_two_IgnoreTest() (_swig_ret IgnoreTestIgnoreE) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_ignoreE_twenty_two_IgnoreTest, _swig_p) + return +} +var IgnoreTestIgnoreE_twenty_two IgnoreTestIgnoreE = _swig_getIgnoreTest_ignoreE_twenty_two_IgnoreTest() +var _wrap_new_IgnoreTest unsafe.Pointer + +func _swig_wrap_new_IgnoreTest() (base SwigcptrIgnoreTest) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_IgnoreTest, _swig_p) + return +} + +func NewIgnoreTest() (_swig_ret IgnoreTest) { + return _swig_wrap_new_IgnoreTest() +} + +var _wrap_delete_IgnoreTest unsafe.Pointer + +func _swig_wrap_delete_IgnoreTest(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_IgnoreTest, _swig_p) + return +} + +func DeleteIgnoreTest(arg1 IgnoreTest) { + _swig_wrap_delete_IgnoreTest(arg1.Swigcptr()) +} + +type IgnoreTest interface { + Swigcptr() uintptr + SwigIsIgnoreTest() +} + +var _wrap_ignoreATest unsafe.Pointer + +func IgnoreATest(arg1 IgnoreTestIgnoreA) (_swig_ret IgnoreTestIgnoreA) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_ignoreATest, _swig_p) + return +} +var _wrap_ignoreBTest unsafe.Pointer + +func IgnoreBTest(arg1 IgnoreTestIgnoreB) (_swig_ret IgnoreTestIgnoreB) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_ignoreBTest, _swig_p) + return +} +var _wrap_ignoreCTest unsafe.Pointer + +func IgnoreCTest(arg1 IgnoreTestIgnoreC) (_swig_ret IgnoreTestIgnoreC) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_ignoreCTest, _swig_p) + return +} +var _wrap_ignoreDTest unsafe.Pointer + +func IgnoreDTest(arg1 IgnoreTestIgnoreD) (_swig_ret IgnoreTestIgnoreD) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_ignoreDTest, _swig_p) + return +} +var _wrap_ignoreETest unsafe.Pointer + +func IgnoreETest(arg1 IgnoreTestIgnoreE) (_swig_ret IgnoreTestIgnoreE) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_ignoreETest, _swig_p) + return +} +type RepeatSpaceRepeat int +var _wrap_one unsafe.Pointer + +func _swig_getone() (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_one, _swig_p) + return +} +var One int = _swig_getone() +var _wrap_initial unsafe.Pointer + +func _swig_getinitial() (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_initial, _swig_p) + return +} +var Initial int = _swig_getinitial() +var _wrap_two unsafe.Pointer + +func _swig_gettwo() (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_two, _swig_p) + return +} +var Two int = _swig_gettwo() +var _wrap_three unsafe.Pointer + +func _swig_getthree() (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_three, _swig_p) + return +} +var Three int = _swig_getthree() +var _wrap_llast unsafe.Pointer + +func _swig_getllast() (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_llast, _swig_p) + return +} +var Llast int = _swig_getllast() +var _wrap_end unsafe.Pointer + +func _swig_getend() (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_end, _swig_p) + return +} +var End int = _swig_getend() +var _wrap_repeatTest unsafe.Pointer + +func RepeatTest(arg1 RepeatSpaceRepeat) (_swig_ret RepeatSpaceRepeat) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_repeatTest, _swig_p) + return +} +type DifferentSpaceDifferentTypes int +var _wrap_typeint unsafe.Pointer + +func _swig_gettypeint() (_swig_ret DifferentSpaceDifferentTypes) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_typeint, _swig_p) + return +} +var Typeint DifferentSpaceDifferentTypes = _swig_gettypeint() +var _wrap_typeboolfalse unsafe.Pointer + +func _swig_gettypeboolfalse() (_swig_ret DifferentSpaceDifferentTypes) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_typeboolfalse, _swig_p) + return +} +var Typeboolfalse DifferentSpaceDifferentTypes = _swig_gettypeboolfalse() +var _wrap_typebooltrue unsafe.Pointer + +func _swig_gettypebooltrue() (_swig_ret DifferentSpaceDifferentTypes) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_typebooltrue, _swig_p) + return +} +var Typebooltrue DifferentSpaceDifferentTypes = _swig_gettypebooltrue() +var _wrap_typebooltwo unsafe.Pointer + +func _swig_gettypebooltwo() (_swig_ret DifferentSpaceDifferentTypes) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_typebooltwo, _swig_p) + return +} +var Typebooltwo DifferentSpaceDifferentTypes = _swig_gettypebooltwo() +var _wrap_typechar unsafe.Pointer + +func _swig_gettypechar() (_swig_ret DifferentSpaceDifferentTypes) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_typechar, _swig_p) + return +} +var Typechar DifferentSpaceDifferentTypes = _swig_gettypechar() +var _wrap_typedefaultint unsafe.Pointer + +func _swig_gettypedefaultint() (_swig_ret DifferentSpaceDifferentTypes) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_typedefaultint, _swig_p) + return +} +var Typedefaultint DifferentSpaceDifferentTypes = _swig_gettypedefaultint() +var _wrap_differentTypesTest unsafe.Pointer + +func DifferentTypesTest(arg1 DifferentSpaceDifferentTypes) (_swig_ret DifferentSpaceDifferentTypes) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_differentTypesTest, _swig_p) + return +} +var _wrap_global_typeint unsafe.Pointer + +func _swig_getglobal_typeint() (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_global_typeint, _swig_p) + return +} +var Global_typeint int = _swig_getglobal_typeint() +var _wrap_global_typeboolfalse unsafe.Pointer + +func _swig_getglobal_typeboolfalse() (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_global_typeboolfalse, _swig_p) + return +} +var Global_typeboolfalse int = _swig_getglobal_typeboolfalse() +var _wrap_global_typebooltrue unsafe.Pointer + +func _swig_getglobal_typebooltrue() (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_global_typebooltrue, _swig_p) + return +} +var Global_typebooltrue int = _swig_getglobal_typebooltrue() +var _wrap_global_typebooltwo unsafe.Pointer + +func _swig_getglobal_typebooltwo() (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_global_typebooltwo, _swig_p) + return +} +var Global_typebooltwo int = _swig_getglobal_typebooltwo() +var _wrap_global_typechar unsafe.Pointer + +func _swig_getglobal_typechar() (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_global_typechar, _swig_p) + return +} +var Global_typechar int = _swig_getglobal_typechar() +var _wrap_global_typedefaultint unsafe.Pointer + +func _swig_getglobal_typedefaultint() (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_global_typedefaultint, _swig_p) + return +} +var Global_typedefaultint int = _swig_getglobal_typedefaultint() +var _wrap_globalDifferentTypesTest unsafe.Pointer + +func GlobalDifferentTypesTest(arg1 int) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_globalDifferentTypesTest, _swig_p) + return +} +type DifferentSpaceDifferentTypesNoConst int +var _wrap_typeint_noconst unsafe.Pointer + +func _swig_gettypeint_noconst() (_swig_ret DifferentSpaceDifferentTypesNoConst) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_typeint_noconst, _swig_p) + return +} +var Typeint_noconst DifferentSpaceDifferentTypesNoConst = _swig_gettypeint_noconst() +var _wrap_typeboolfalse_noconst unsafe.Pointer + +func _swig_gettypeboolfalse_noconst() (_swig_ret DifferentSpaceDifferentTypesNoConst) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_typeboolfalse_noconst, _swig_p) + return +} +var Typeboolfalse_noconst DifferentSpaceDifferentTypesNoConst = _swig_gettypeboolfalse_noconst() +var _wrap_typebooltrue_noconst unsafe.Pointer + +func _swig_gettypebooltrue_noconst() (_swig_ret DifferentSpaceDifferentTypesNoConst) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_typebooltrue_noconst, _swig_p) + return +} +var Typebooltrue_noconst DifferentSpaceDifferentTypesNoConst = _swig_gettypebooltrue_noconst() +var _wrap_typebooltwo_noconst unsafe.Pointer + +func _swig_gettypebooltwo_noconst() (_swig_ret DifferentSpaceDifferentTypesNoConst) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_typebooltwo_noconst, _swig_p) + return +} +var Typebooltwo_noconst DifferentSpaceDifferentTypesNoConst = _swig_gettypebooltwo_noconst() +var _wrap_typechar_noconst unsafe.Pointer + +func _swig_gettypechar_noconst() (_swig_ret DifferentSpaceDifferentTypesNoConst) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_typechar_noconst, _swig_p) + return +} +var Typechar_noconst DifferentSpaceDifferentTypesNoConst = _swig_gettypechar_noconst() +var _wrap_typedefaultint_noconst unsafe.Pointer + +func _swig_gettypedefaultint_noconst() (_swig_ret DifferentSpaceDifferentTypesNoConst) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_typedefaultint_noconst, _swig_p) + return +} +var Typedefaultint_noconst DifferentSpaceDifferentTypesNoConst = _swig_gettypedefaultint_noconst() +var _wrap_global_typeint_noconst unsafe.Pointer + +func _swig_getglobal_typeint_noconst() (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_global_typeint_noconst, _swig_p) + return +} +var Global_typeint_noconst int = _swig_getglobal_typeint_noconst() +var _wrap_global_typeboolfalse_noconst unsafe.Pointer + +func _swig_getglobal_typeboolfalse_noconst() (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_global_typeboolfalse_noconst, _swig_p) + return +} +var Global_typeboolfalse_noconst int = _swig_getglobal_typeboolfalse_noconst() +var _wrap_global_typebooltrue_noconst unsafe.Pointer + +func _swig_getglobal_typebooltrue_noconst() (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_global_typebooltrue_noconst, _swig_p) + return +} +var Global_typebooltrue_noconst int = _swig_getglobal_typebooltrue_noconst() +var _wrap_global_typebooltwo_noconst unsafe.Pointer + +func _swig_getglobal_typebooltwo_noconst() (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_global_typebooltwo_noconst, _swig_p) + return +} +var Global_typebooltwo_noconst int = _swig_getglobal_typebooltwo_noconst() +var _wrap_global_typechar_noconst unsafe.Pointer + +func _swig_getglobal_typechar_noconst() (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_global_typechar_noconst, _swig_p) + return +} +var Global_typechar_noconst int = _swig_getglobal_typechar_noconst() +var _wrap_global_typedefaultint_noconst unsafe.Pointer + +func _swig_getglobal_typedefaultint_noconst() (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_global_typedefaultint_noconst, _swig_p) + return +} +var Global_typedefaultint_noconst int = _swig_getglobal_typedefaultint_noconst() + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/enum_var.go b/Examples/test-suite/go/enum_var.go new file mode 100644 index 000000000..e250cb631 --- /dev/null +++ b/Examples/test-suite/go/enum_var.go @@ -0,0 +1,73 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../enum_var.i + +package enum_var + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type Fruit int +var _wrap_APPLE unsafe.Pointer + +func _swig_getAPPLE() (_swig_ret Fruit) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_APPLE, _swig_p) + return +} +var APPLE Fruit = _swig_getAPPLE() +var _wrap_PEAR unsafe.Pointer + +func _swig_getPEAR() (_swig_ret Fruit) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_PEAR, _swig_p) + return +} +var PEAR Fruit = _swig_getPEAR() +var _wrap_test_set unsafe.Pointer + +func _swig_wrap_test_set(base Fruit) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_test_set, _swig_p) + return +} + +func SetTest(arg1 Fruit) { + _swig_wrap_test_set(arg1) +} + +var _wrap_test_get unsafe.Pointer + +func GetTest() (_swig_ret Fruit) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_test_get, _swig_p) + return +} + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/enums.go b/Examples/test-suite/go/enums.go new file mode 100644 index 000000000..8a781fae8 --- /dev/null +++ b/Examples/test-suite/go/enums.go @@ -0,0 +1,507 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../enums.i + +package enums + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type Foo1 int +var _wrap_CSP_ITERATION_FWD unsafe.Pointer + +func _swig_getCSP_ITERATION_FWD() (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_CSP_ITERATION_FWD, _swig_p) + return +} +var CSP_ITERATION_FWD int = _swig_getCSP_ITERATION_FWD() +var _wrap_CSP_ITERATION_BWD unsafe.Pointer + +func _swig_getCSP_ITERATION_BWD() (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_CSP_ITERATION_BWD, _swig_p) + return +} +var CSP_ITERATION_BWD int = _swig_getCSP_ITERATION_BWD() +type Enum_SS_foo2 int +var _wrap_ABCDE unsafe.Pointer + +func _swig_getABCDE() (_swig_ret Enum_SS_foo2) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_ABCDE, _swig_p) + return +} +var ABCDE Enum_SS_foo2 = _swig_getABCDE() +var _wrap_FGHJI unsafe.Pointer + +func _swig_getFGHJI() (_swig_ret Enum_SS_foo2) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_FGHJI, _swig_p) + return +} +var FGHJI Enum_SS_foo2 = _swig_getFGHJI() +var _wrap_bar1 unsafe.Pointer + +func _swig_wrap_bar1(base Foo1) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_bar1, _swig_p) + return +} + +func Bar1(arg1 Foo1) { + _swig_wrap_bar1(arg1) +} + +var _wrap_bar2 unsafe.Pointer + +func _swig_wrap_bar2(base Enum_SS_foo2) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_bar2, _swig_p) + return +} + +func Bar2(arg1 Enum_SS_foo2) { + _swig_wrap_bar2(arg1) +} + +var _wrap_bar3 unsafe.Pointer + +func _swig_wrap_bar3(base Enum_SS_foo2) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_bar3, _swig_p) + return +} + +func Bar3(arg1 Enum_SS_foo2) { + _swig_wrap_bar3(arg1) +} + +type Enum_SS_sad int +var _wrap_boo unsafe.Pointer + +func _swig_getboo() (_swig_ret Enum_SS_sad) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_boo, _swig_p) + return +} +var Boo Enum_SS_sad = _swig_getboo() +var _wrap_hoo unsafe.Pointer + +func _swig_gethoo() (_swig_ret Enum_SS_sad) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_hoo, _swig_p) + return +} +var Hoo Enum_SS_sad = _swig_gethoo() +var _wrap_globalinstance1 unsafe.Pointer + +func _swig_getglobalinstance1() (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_globalinstance1, _swig_p) + return +} +var Globalinstance1 int = _swig_getglobalinstance1() +var _wrap_globalinstance2 unsafe.Pointer + +func _swig_getglobalinstance2() (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_globalinstance2, _swig_p) + return +} +var Globalinstance2 int = _swig_getglobalinstance2() +var _wrap_globalinstance3 unsafe.Pointer + +func _swig_getglobalinstance3() (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_globalinstance3, _swig_p) + return +} +var Globalinstance3 int = _swig_getglobalinstance3() +var _wrap_GlobalInstance_set unsafe.Pointer + +func _swig_wrap_GlobalInstance_set(base int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_GlobalInstance_set, _swig_p) + return +} + +func SetGlobalInstance(arg1 int) { + _swig_wrap_GlobalInstance_set(arg1) +} + +var _wrap_GlobalInstance_get unsafe.Pointer + +func GetGlobalInstance() (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_GlobalInstance_get, _swig_p) + return +} +var _wrap_AnonEnum1 unsafe.Pointer + +func _swig_getAnonEnum1() (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_AnonEnum1, _swig_p) + return +} +var AnonEnum1 int = _swig_getAnonEnum1() +var _wrap_AnonEnum2 unsafe.Pointer + +func _swig_getAnonEnum2() (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_AnonEnum2, _swig_p) + return +} +var AnonEnum2 int = _swig_getAnonEnum2() +type SwigcptrFoo uintptr + +func (p SwigcptrFoo) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrFoo) SwigIsFoo() { +} + +var _wrap_BAR1_Foo unsafe.Pointer + +func _swig_getFoo_BAR1_Foo() (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_BAR1_Foo, _swig_p) + return +} +var FooBAR1 int = _swig_getFoo_BAR1_Foo() +var _wrap_BAR2_Foo unsafe.Pointer + +func _swig_getFoo_BAR2_Foo() (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_BAR2_Foo, _swig_p) + return +} +var FooBAR2 int = _swig_getFoo_BAR2_Foo() +var _wrap_Foo_e_set unsafe.Pointer + +func _swig_wrap_Foo_e_set(base SwigcptrFoo, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_e_set, _swig_p) + return +} + +func (arg1 SwigcptrFoo) SetE(arg2 int) { + _swig_wrap_Foo_e_set(arg1, arg2) +} + +var _wrap_Foo_e_get unsafe.Pointer + +func _swig_wrap_Foo_e_get(base SwigcptrFoo) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_e_get, _swig_p) + return +} + +func (arg1 SwigcptrFoo) GetE() (_swig_ret int) { + return _swig_wrap_Foo_e_get(arg1) +} + +var _wrap_new_Foo unsafe.Pointer + +func _swig_wrap_new_Foo() (base SwigcptrFoo) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Foo, _swig_p) + return +} + +func NewFoo() (_swig_ret Foo) { + return _swig_wrap_new_Foo() +} + +var _wrap_delete_Foo unsafe.Pointer + +func _swig_wrap_delete_Foo(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Foo, _swig_p) + return +} + +func DeleteFoo(arg1 Foo) { + _swig_wrap_delete_Foo(arg1.Swigcptr()) +} + +type Foo interface { + Swigcptr() uintptr + SwigIsFoo() + SetE(arg2 int) + GetE() (_swig_ret int) +} + +type SwigcptrIFoo uintptr + +func (p SwigcptrIFoo) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrIFoo) SwigIsIFoo() { +} + +var _wrap_Phoo_iFoo unsafe.Pointer + +func _swig_getiFoo_Phoo_iFoo() (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_Phoo_iFoo, _swig_p) + return +} +var IFooPhoo int = _swig_getiFoo_Phoo_iFoo() +var _wrap_Char_iFoo unsafe.Pointer + +func _swig_getiFoo_Char_iFoo() (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_Char_iFoo, _swig_p) + return +} +var IFooChar int = _swig_getiFoo_Char_iFoo() +var _wrap_iFoo_e_set unsafe.Pointer + +func _swig_wrap_iFoo_e_set(base SwigcptrIFoo, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_iFoo_e_set, _swig_p) + return +} + +func (arg1 SwigcptrIFoo) SetE(arg2 int) { + _swig_wrap_iFoo_e_set(arg1, arg2) +} + +var _wrap_iFoo_e_get unsafe.Pointer + +func _swig_wrap_iFoo_e_get(base SwigcptrIFoo) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_iFoo_e_get, _swig_p) + return +} + +func (arg1 SwigcptrIFoo) GetE() (_swig_ret int) { + return _swig_wrap_iFoo_e_get(arg1) +} + +var _wrap_new_iFoo unsafe.Pointer + +func _swig_wrap_new_iFoo() (base SwigcptrIFoo) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_iFoo, _swig_p) + return +} + +func NewIFoo() (_swig_ret IFoo) { + return _swig_wrap_new_iFoo() +} + +var _wrap_delete_iFoo unsafe.Pointer + +func _swig_wrap_delete_iFoo(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_iFoo, _swig_p) + return +} + +func DeleteIFoo(arg1 IFoo) { + _swig_wrap_delete_iFoo(arg1.Swigcptr()) +} + +type IFoo interface { + Swigcptr() uintptr + SwigIsIFoo() + SetE(arg2 int) + GetE() (_swig_ret int) +} + +type Enum_SS_Exclamation int +var _wrap_goodness unsafe.Pointer + +func _swig_getgoodness() (_swig_ret Enum_SS_Exclamation) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_goodness, _swig_p) + return +} +var Goodness Enum_SS_Exclamation = _swig_getgoodness() +var _wrap_gracious unsafe.Pointer + +func _swig_getgracious() (_swig_ret Enum_SS_Exclamation) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_gracious, _swig_p) + return +} +var Gracious Enum_SS_Exclamation = _swig_getgracious() +var _wrap_me unsafe.Pointer + +func _swig_getme() (_swig_ret Enum_SS_Exclamation) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_me, _swig_p) + return +} +var Me Enum_SS_Exclamation = _swig_getme() +var _wrap_enumInstance_set unsafe.Pointer + +func _swig_wrap_enumInstance_set(base Enum_SS_Exclamation) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_enumInstance_set, _swig_p) + return +} + +func SetEnumInstance(arg1 Enum_SS_Exclamation) { + _swig_wrap_enumInstance_set(arg1) +} + +var _wrap_enumInstance_get unsafe.Pointer + +func GetEnumInstance() (_swig_ret Enum_SS_Exclamation) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_enumInstance_get, _swig_p) + return +} +type Enum_SS_ContainYourself int +var _wrap_slap unsafe.Pointer + +func _swig_getslap() (_swig_ret Enum_SS_ContainYourself) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_slap, _swig_p) + return +} +var Slap Enum_SS_ContainYourself = _swig_getslap() +var _wrap_mine unsafe.Pointer + +func _swig_getmine() (_swig_ret Enum_SS_ContainYourself) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_mine, _swig_p) + return +} +var Mine Enum_SS_ContainYourself = _swig_getmine() +var _wrap_thigh unsafe.Pointer + +func _swig_getthigh() (_swig_ret Enum_SS_ContainYourself) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_thigh, _swig_p) + return +} +var Thigh Enum_SS_ContainYourself = _swig_getthigh() +var _wrap_Slap_set unsafe.Pointer + +func _swig_wrap_Slap_set(base Enum_SS_ContainYourself) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Slap_set, _swig_p) + return +} + +func SetSlap(arg1 Enum_SS_ContainYourself) { + _swig_wrap_Slap_set(arg1) +} + +var _wrap_Slap_get unsafe.Pointer + +func GetSlap() (_swig_ret Enum_SS_ContainYourself) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_Slap_get, _swig_p) + return +} +var _wrap_Mine_set unsafe.Pointer + +func _swig_wrap_Mine_set(base Enum_SS_ContainYourself) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Mine_set, _swig_p) + return +} + +func SetMine(arg1 Enum_SS_ContainYourself) { + _swig_wrap_Mine_set(arg1) +} + +var _wrap_Mine_get unsafe.Pointer + +func GetMine() (_swig_ret Enum_SS_ContainYourself) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_Mine_get, _swig_p) + return +} +var _wrap_Thigh_set unsafe.Pointer + +func _swig_wrap_Thigh_set(base Enum_SS_ContainYourself) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Thigh_set, _swig_p) + return +} + +func SetThigh(arg1 Enum_SS_ContainYourself) { + _swig_wrap_Thigh_set(arg1) +} + +var _wrap_Thigh_get unsafe.Pointer + +func GetThigh() (_swig_ret Enum_SS_ContainYourself) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_Thigh_get, _swig_p) + return +} +var _wrap_pThigh_set unsafe.Pointer + +func _swig_wrap_pThigh_set(base *Enum_SS_ContainYourself) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_pThigh_set, _swig_p) + return +} + +func SetPThigh(arg1 *Enum_SS_ContainYourself) { + _swig_wrap_pThigh_set(arg1) +} + +var _wrap_pThigh_get unsafe.Pointer + +func GetPThigh() (_swig_ret *Enum_SS_ContainYourself) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_pThigh_get, _swig_p) + return +} +var _wrap_arrayContainYourself_set unsafe.Pointer + +func _swig_wrap_arrayContainYourself_set(base *Enum_SS_ContainYourself) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_arrayContainYourself_set, _swig_p) + return +} + +func SetArrayContainYourself(arg1 *Enum_SS_ContainYourself) { + _swig_wrap_arrayContainYourself_set(arg1) +} + +var _wrap_arrayContainYourself_get unsafe.Pointer + +func GetArrayContainYourself() (_swig_ret *Enum_SS_ContainYourself) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_arrayContainYourself_get, _swig_p) + return +} + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/enums_runme b/Examples/test-suite/go/enums_runme new file mode 100755 index 000000000..786758034 Binary files /dev/null and b/Examples/test-suite/go/enums_runme differ diff --git a/Examples/test-suite/go/equality.go b/Examples/test-suite/go/equality.go new file mode 100644 index 000000000..9ec4bcd02 --- /dev/null +++ b/Examples/test-suite/go/equality.go @@ -0,0 +1,336 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../equality.i + +package equality + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrPoint uintptr + +func (p SwigcptrPoint) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrPoint) SwigIsPoint() { +} + +var _wrap_Point_x_set unsafe.Pointer + +func _swig_wrap_Point_x_set(base SwigcptrPoint, _ float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Point_x_set, _swig_p) + return +} + +func (arg1 SwigcptrPoint) SetX(arg2 float64) { + _swig_wrap_Point_x_set(arg1, arg2) +} + +var _wrap_Point_x_get unsafe.Pointer + +func _swig_wrap_Point_x_get(base SwigcptrPoint) (_ float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Point_x_get, _swig_p) + return +} + +func (arg1 SwigcptrPoint) GetX() (_swig_ret float64) { + return _swig_wrap_Point_x_get(arg1) +} + +var _wrap_Point_y_set unsafe.Pointer + +func _swig_wrap_Point_y_set(base SwigcptrPoint, _ float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Point_y_set, _swig_p) + return +} + +func (arg1 SwigcptrPoint) SetY(arg2 float64) { + _swig_wrap_Point_y_set(arg1, arg2) +} + +var _wrap_Point_y_get unsafe.Pointer + +func _swig_wrap_Point_y_get(base SwigcptrPoint) (_ float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Point_y_get, _swig_p) + return +} + +func (arg1 SwigcptrPoint) GetY() (_swig_ret float64) { + return _swig_wrap_Point_y_get(arg1) +} + +var _wrap_new_Point unsafe.Pointer + +func _swig_wrap_new_Point() (base SwigcptrPoint) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Point, _swig_p) + return +} + +func NewPoint() (_swig_ret Point) { + return _swig_wrap_new_Point() +} + +var _wrap_delete_Point unsafe.Pointer + +func _swig_wrap_delete_Point(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Point, _swig_p) + return +} + +func DeletePoint(arg1 Point) { + _swig_wrap_delete_Point(arg1.Swigcptr()) +} + +type Point interface { + Swigcptr() uintptr + SwigIsPoint() + SetX(arg2 float64) + GetX() (_swig_ret float64) + SetY(arg2 float64) + GetY() (_swig_ret float64) +} + +var _wrap_s_zeroPoint_get unsafe.Pointer + +func _swig_wrap_s_zeroPoint_get() (base SwigcptrPoint) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_s_zeroPoint_get, _swig_p) + return +} + +func GetS_zeroPoint() (_swig_ret Point) { + return _swig_wrap_s_zeroPoint_get() +} + +var _wrap_MakePoint unsafe.Pointer + +func _swig_wrap_MakePoint(base float64, _ float64) (_ SwigcptrPoint) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_MakePoint, _swig_p) + return +} + +func MakePoint(arg1 float64, arg2 float64) (_swig_ret Point) { + return _swig_wrap_MakePoint(arg1, arg2) +} + +var _wrap_GetZeroPointPtr unsafe.Pointer + +func _swig_wrap_GetZeroPointPtr() (base SwigcptrPoint) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_GetZeroPointPtr, _swig_p) + return +} + +func GetZeroPointPtr() (_swig_ret Point) { + return _swig_wrap_GetZeroPointPtr() +} + +var _wrap_GetZeroPointCopy unsafe.Pointer + +func _swig_wrap_GetZeroPointCopy() (base SwigcptrPoint) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_GetZeroPointCopy, _swig_p) + return +} + +func GetZeroPointCopy() (_swig_ret Point) { + return _swig_wrap_GetZeroPointCopy() +} + +type SwigcptrEqualOpDefined uintptr + +func (p SwigcptrEqualOpDefined) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrEqualOpDefined) SwigIsEqualOpDefined() { +} + +var _wrap_new_EqualOpDefined__SWIG_0 unsafe.Pointer + +func _swig_wrap_new_EqualOpDefined__SWIG_0() (base SwigcptrEqualOpDefined) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_EqualOpDefined__SWIG_0, _swig_p) + return +} + +func NewEqualOpDefined__SWIG_0() (_swig_ret EqualOpDefined) { + return _swig_wrap_new_EqualOpDefined__SWIG_0() +} + +var _wrap_new_EqualOpDefined__SWIG_1 unsafe.Pointer + +func _swig_wrap_new_EqualOpDefined__SWIG_1(base int) (_ SwigcptrEqualOpDefined) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_EqualOpDefined__SWIG_1, _swig_p) + return +} + +func NewEqualOpDefined__SWIG_1(arg1 int) (_swig_ret EqualOpDefined) { + return _swig_wrap_new_EqualOpDefined__SWIG_1(arg1) +} + +func NewEqualOpDefined(a ...interface{}) EqualOpDefined { + argc := len(a) + if argc == 0 { + return NewEqualOpDefined__SWIG_0() + } + if argc == 1 { + return NewEqualOpDefined__SWIG_1(a[0].(int)) + } + panic("No match for overloaded function call") +} + +var _wrap_EqualOpDefined_x_set unsafe.Pointer + +func _swig_wrap_EqualOpDefined_x_set(base SwigcptrEqualOpDefined, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_EqualOpDefined_x_set, _swig_p) + return +} + +func (arg1 SwigcptrEqualOpDefined) SetX(arg2 int) { + _swig_wrap_EqualOpDefined_x_set(arg1, arg2) +} + +var _wrap_EqualOpDefined_x_get unsafe.Pointer + +func _swig_wrap_EqualOpDefined_x_get(base SwigcptrEqualOpDefined) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_EqualOpDefined_x_get, _swig_p) + return +} + +func (arg1 SwigcptrEqualOpDefined) GetX() (_swig_ret int) { + return _swig_wrap_EqualOpDefined_x_get(arg1) +} + +var _wrap_delete_EqualOpDefined unsafe.Pointer + +func _swig_wrap_delete_EqualOpDefined(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_EqualOpDefined, _swig_p) + return +} + +func DeleteEqualOpDefined(arg1 EqualOpDefined) { + _swig_wrap_delete_EqualOpDefined(arg1.Swigcptr()) +} + +type EqualOpDefined interface { + Swigcptr() uintptr + SwigIsEqualOpDefined() + SetX(arg2 int) + GetX() (_swig_ret int) +} + +type SwigcptrEqualOpWrong uintptr + +func (p SwigcptrEqualOpWrong) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrEqualOpWrong) SwigIsEqualOpWrong() { +} + +var _wrap_EqualOpWrong_GetStaticObject unsafe.Pointer + +func _swig_wrap_EqualOpWrong_GetStaticObject() (base SwigcptrEqualOpWrong) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_EqualOpWrong_GetStaticObject, _swig_p) + return +} + +func EqualOpWrongGetStaticObject() (_swig_ret EqualOpWrong) { + return _swig_wrap_EqualOpWrong_GetStaticObject() +} + +var _wrap_new_EqualOpWrong unsafe.Pointer + +func _swig_wrap_new_EqualOpWrong() (base SwigcptrEqualOpWrong) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_EqualOpWrong, _swig_p) + return +} + +func NewEqualOpWrong() (_swig_ret EqualOpWrong) { + return _swig_wrap_new_EqualOpWrong() +} + +var _wrap_delete_EqualOpWrong unsafe.Pointer + +func _swig_wrap_delete_EqualOpWrong(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_EqualOpWrong, _swig_p) + return +} + +func DeleteEqualOpWrong(arg1 EqualOpWrong) { + _swig_wrap_delete_EqualOpWrong(arg1.Swigcptr()) +} + +type EqualOpWrong interface { + Swigcptr() uintptr + SwigIsEqualOpWrong() +} + +var _wrap_s_wrongEqOp_set unsafe.Pointer + +func _swig_wrap_s_wrongEqOp_set(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_s_wrongEqOp_set, _swig_p) + return +} + +func SetS_wrongEqOp(arg1 EqualOpWrong) { + _swig_wrap_s_wrongEqOp_set(arg1.Swigcptr()) +} + +var _wrap_s_wrongEqOp_get unsafe.Pointer + +func _swig_wrap_s_wrongEqOp_get() (base SwigcptrEqualOpWrong) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_s_wrongEqOp_get, _swig_p) + return +} + +func GetS_wrongEqOp() (_swig_ret EqualOpWrong) { + return _swig_wrap_s_wrongEqOp_get() +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/evil_diamond.go b/Examples/test-suite/go/evil_diamond.go new file mode 100644 index 000000000..cbcbd50fa --- /dev/null +++ b/Examples/test-suite/go/evil_diamond.go @@ -0,0 +1,250 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../evil_diamond.i + +package evil_diamond + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrFoo uintptr + +func (p SwigcptrFoo) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrFoo) SwigIsFoo() { +} + +var _wrap_new_foo unsafe.Pointer + +func _swig_wrap_new_foo() (base SwigcptrFoo) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_foo, _swig_p) + return +} + +func NewFoo() (_swig_ret Foo) { + return _swig_wrap_new_foo() +} + +var _wrap_delete_foo unsafe.Pointer + +func _swig_wrap_delete_foo(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_foo, _swig_p) + return +} + +func DeleteFoo(arg1 Foo) { + _swig_wrap_delete_foo(arg1.Swigcptr()) +} + +type Foo interface { + Swigcptr() uintptr + SwigIsFoo() +} + +type SwigcptrBar uintptr + +func (p SwigcptrBar) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrBar) SwigIsBar() { +} + +var _wrap_new_bar unsafe.Pointer + +func _swig_wrap_new_bar() (base SwigcptrBar) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_bar, _swig_p) + return +} + +func NewBar() (_swig_ret Bar) { + return _swig_wrap_new_bar() +} + +var _wrap_delete_bar unsafe.Pointer + +func _swig_wrap_delete_bar(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_bar, _swig_p) + return +} + +func DeleteBar(arg1 Bar) { + _swig_wrap_delete_bar(arg1.Swigcptr()) +} + +func (p SwigcptrBar) SwigIsFoo() { +} + +func (p SwigcptrBar) SwigGetFoo() Foo { + return SwigcptrFoo(p.Swigcptr()) +} + +type Bar interface { + Swigcptr() uintptr + SwigIsBar() + SwigIsFoo() + SwigGetFoo() Foo +} + +type SwigcptrBaz uintptr + +func (p SwigcptrBaz) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrBaz) SwigIsBaz() { +} + +var _wrap_new_baz unsafe.Pointer + +func _swig_wrap_new_baz() (base SwigcptrBaz) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_baz, _swig_p) + return +} + +func NewBaz() (_swig_ret Baz) { + return _swig_wrap_new_baz() +} + +var _wrap_delete_baz unsafe.Pointer + +func _swig_wrap_delete_baz(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_baz, _swig_p) + return +} + +func DeleteBaz(arg1 Baz) { + _swig_wrap_delete_baz(arg1.Swigcptr()) +} + +func (p SwigcptrBaz) SwigIsFoo() { +} + +func (p SwigcptrBaz) SwigGetFoo() Foo { + return SwigcptrFoo(p.Swigcptr()) +} + +type Baz interface { + Swigcptr() uintptr + SwigIsBaz() + SwigIsFoo() + SwigGetFoo() Foo +} + +type SwigcptrSpam uintptr + +func (p SwigcptrSpam) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrSpam) SwigIsSpam() { +} + +var _wrap_new_spam unsafe.Pointer + +func _swig_wrap_new_spam() (base SwigcptrSpam) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_spam, _swig_p) + return +} + +func NewSpam() (_swig_ret Spam) { + return _swig_wrap_new_spam() +} + +var _wrap_delete_spam unsafe.Pointer + +func _swig_wrap_delete_spam(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_spam, _swig_p) + return +} + +func DeleteSpam(arg1 Spam) { + _swig_wrap_delete_spam(arg1.Swigcptr()) +} + +func (p SwigcptrSpam) SwigIsBar() { +} + +func (p SwigcptrSpam) SwigGetBar() Bar { + return SwigcptrBar(p.Swigcptr()) +} + +func (p SwigcptrSpam) SwigIsFoo() { +} + +func (p SwigcptrSpam) SwigGetFoo() Foo { + return SwigcptrFoo(p.Swigcptr()) +} + +var _wrap_spam_SwigGetBaz unsafe.Pointer + +func _swig_wrap_spam_SwigGetBaz(base SwigcptrSpam) (_ SwigcptrBaz) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_spam_SwigGetBaz, _swig_p) + return +} + +func (arg1 SwigcptrSpam) SwigGetBaz() (_swig_ret Baz) { + return _swig_wrap_spam_SwigGetBaz(arg1) +} + +type Spam interface { + Swigcptr() uintptr + SwigIsSpam() + SwigIsBar() + SwigGetBar() Bar + SwigIsFoo() + SwigGetFoo() Foo + SwigGetBaz() (_swig_ret Baz) +} + +var _wrap_test unsafe.Pointer + +func _swig_wrap_test(base uintptr) (_ SwigcptrFoo) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_test, _swig_p) + return +} + +func Test(arg1 Foo) (_swig_ret Foo) { + return _swig_wrap_test(arg1.Swigcptr()) +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/evil_diamond_ns.go b/Examples/test-suite/go/evil_diamond_ns.go new file mode 100644 index 000000000..eb60a0842 --- /dev/null +++ b/Examples/test-suite/go/evil_diamond_ns.go @@ -0,0 +1,250 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../evil_diamond_ns.i + +package evil_diamond_ns + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrFoo uintptr + +func (p SwigcptrFoo) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrFoo) SwigIsFoo() { +} + +var _wrap_new_foo unsafe.Pointer + +func _swig_wrap_new_foo() (base SwigcptrFoo) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_foo, _swig_p) + return +} + +func NewFoo() (_swig_ret Foo) { + return _swig_wrap_new_foo() +} + +var _wrap_delete_foo unsafe.Pointer + +func _swig_wrap_delete_foo(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_foo, _swig_p) + return +} + +func DeleteFoo(arg1 Foo) { + _swig_wrap_delete_foo(arg1.Swigcptr()) +} + +type Foo interface { + Swigcptr() uintptr + SwigIsFoo() +} + +type SwigcptrBar uintptr + +func (p SwigcptrBar) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrBar) SwigIsBar() { +} + +var _wrap_new_bar unsafe.Pointer + +func _swig_wrap_new_bar() (base SwigcptrBar) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_bar, _swig_p) + return +} + +func NewBar() (_swig_ret Bar) { + return _swig_wrap_new_bar() +} + +var _wrap_delete_bar unsafe.Pointer + +func _swig_wrap_delete_bar(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_bar, _swig_p) + return +} + +func DeleteBar(arg1 Bar) { + _swig_wrap_delete_bar(arg1.Swigcptr()) +} + +func (p SwigcptrBar) SwigIsFoo() { +} + +func (p SwigcptrBar) SwigGetFoo() Foo { + return SwigcptrFoo(p.Swigcptr()) +} + +type Bar interface { + Swigcptr() uintptr + SwigIsBar() + SwigIsFoo() + SwigGetFoo() Foo +} + +type SwigcptrBaz uintptr + +func (p SwigcptrBaz) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrBaz) SwigIsBaz() { +} + +var _wrap_new_baz unsafe.Pointer + +func _swig_wrap_new_baz() (base SwigcptrBaz) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_baz, _swig_p) + return +} + +func NewBaz() (_swig_ret Baz) { + return _swig_wrap_new_baz() +} + +var _wrap_delete_baz unsafe.Pointer + +func _swig_wrap_delete_baz(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_baz, _swig_p) + return +} + +func DeleteBaz(arg1 Baz) { + _swig_wrap_delete_baz(arg1.Swigcptr()) +} + +func (p SwigcptrBaz) SwigIsFoo() { +} + +func (p SwigcptrBaz) SwigGetFoo() Foo { + return SwigcptrFoo(p.Swigcptr()) +} + +type Baz interface { + Swigcptr() uintptr + SwigIsBaz() + SwigIsFoo() + SwigGetFoo() Foo +} + +type SwigcptrSpam uintptr + +func (p SwigcptrSpam) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrSpam) SwigIsSpam() { +} + +var _wrap_new_spam unsafe.Pointer + +func _swig_wrap_new_spam() (base SwigcptrSpam) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_spam, _swig_p) + return +} + +func NewSpam() (_swig_ret Spam) { + return _swig_wrap_new_spam() +} + +var _wrap_delete_spam unsafe.Pointer + +func _swig_wrap_delete_spam(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_spam, _swig_p) + return +} + +func DeleteSpam(arg1 Spam) { + _swig_wrap_delete_spam(arg1.Swigcptr()) +} + +func (p SwigcptrSpam) SwigIsBar() { +} + +func (p SwigcptrSpam) SwigGetBar() Bar { + return SwigcptrBar(p.Swigcptr()) +} + +func (p SwigcptrSpam) SwigIsFoo() { +} + +func (p SwigcptrSpam) SwigGetFoo() Foo { + return SwigcptrFoo(p.Swigcptr()) +} + +var _wrap_spam_SwigGetBaz unsafe.Pointer + +func _swig_wrap_spam_SwigGetBaz(base SwigcptrSpam) (_ SwigcptrBaz) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_spam_SwigGetBaz, _swig_p) + return +} + +func (arg1 SwigcptrSpam) SwigGetBaz() (_swig_ret Baz) { + return _swig_wrap_spam_SwigGetBaz(arg1) +} + +type Spam interface { + Swigcptr() uintptr + SwigIsSpam() + SwigIsBar() + SwigGetBar() Bar + SwigIsFoo() + SwigGetFoo() Foo + SwigGetBaz() (_swig_ret Baz) +} + +var _wrap_test unsafe.Pointer + +func _swig_wrap_test(base uintptr) (_ SwigcptrFoo) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_test, _swig_p) + return +} + +func Test(arg1 Foo) (_swig_ret Foo) { + return _swig_wrap_test(arg1.Swigcptr()) +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/evil_diamond_prop.go b/Examples/test-suite/go/evil_diamond_prop.go new file mode 100644 index 000000000..def449b0a --- /dev/null +++ b/Examples/test-suite/go/evil_diamond_prop.go @@ -0,0 +1,484 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../evil_diamond_prop.i + +package evil_diamond_prop + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrFoo uintptr + +func (p SwigcptrFoo) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrFoo) SwigIsFoo() { +} + +var _wrap_foo__foo_set unsafe.Pointer + +func _swig_wrap_foo__foo_set(base SwigcptrFoo, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_foo__foo_set, _swig_p) + return +} + +func (arg1 SwigcptrFoo) SetX_foo(arg2 int) { + _swig_wrap_foo__foo_set(arg1, arg2) +} + +var _wrap_foo__foo_get unsafe.Pointer + +func _swig_wrap_foo__foo_get(base SwigcptrFoo) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_foo__foo_get, _swig_p) + return +} + +func (arg1 SwigcptrFoo) GetX_foo() (_swig_ret int) { + return _swig_wrap_foo__foo_get(arg1) +} + +var _wrap_new_foo unsafe.Pointer + +func _swig_wrap_new_foo() (base SwigcptrFoo) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_foo, _swig_p) + return +} + +func NewFoo() (_swig_ret Foo) { + return _swig_wrap_new_foo() +} + +var _wrap_delete_foo unsafe.Pointer + +func _swig_wrap_delete_foo(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_foo, _swig_p) + return +} + +func DeleteFoo(arg1 Foo) { + _swig_wrap_delete_foo(arg1.Swigcptr()) +} + +type Foo interface { + Swigcptr() uintptr + SwigIsFoo() + SetX_foo(arg2 int) + GetX_foo() (_swig_ret int) +} + +type SwigcptrBar uintptr + +func (p SwigcptrBar) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrBar) SwigIsBar() { +} + +var _wrap_bar__bar_set unsafe.Pointer + +func _swig_wrap_bar__bar_set(base SwigcptrBar, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_bar__bar_set, _swig_p) + return +} + +func (arg1 SwigcptrBar) SetX_bar(arg2 int) { + _swig_wrap_bar__bar_set(arg1, arg2) +} + +var _wrap_bar__bar_get unsafe.Pointer + +func _swig_wrap_bar__bar_get(base SwigcptrBar) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_bar__bar_get, _swig_p) + return +} + +func (arg1 SwigcptrBar) GetX_bar() (_swig_ret int) { + return _swig_wrap_bar__bar_get(arg1) +} + +var _wrap_new_bar unsafe.Pointer + +func _swig_wrap_new_bar() (base SwigcptrBar) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_bar, _swig_p) + return +} + +func NewBar() (_swig_ret Bar) { + return _swig_wrap_new_bar() +} + +var _wrap_delete_bar unsafe.Pointer + +func _swig_wrap_delete_bar(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_bar, _swig_p) + return +} + +func DeleteBar(arg1 Bar) { + _swig_wrap_delete_bar(arg1.Swigcptr()) +} + +var _wrap_Setbar_X_foo unsafe.Pointer + +func _swig_wrap_Setbar_X_foo(base SwigcptrBar, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Setbar_X_foo, _swig_p) + return +} + +func (_swig_base SwigcptrBar) SetX_foo(arg1 int) { + _swig_wrap_Setbar_X_foo(_swig_base, arg1) +} + +var _wrap_Getbar_X_foo unsafe.Pointer + +func _swig_wrap_Getbar_X_foo(base SwigcptrBar) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Getbar_X_foo, _swig_p) + return +} + +func (_swig_base SwigcptrBar) GetX_foo() (_swig_ret int) { + return _swig_wrap_Getbar_X_foo(_swig_base) +} + +func (p SwigcptrBar) SwigIsFoo() { +} + +func (p SwigcptrBar) SwigGetFoo() Foo { + return SwigcptrFoo(p.Swigcptr()) +} + +type Bar interface { + Swigcptr() uintptr + SwigIsBar() + SetX_bar(arg2 int) + GetX_bar() (_swig_ret int) + SetX_foo(arg1 int) + GetX_foo() (_swig_ret int) + SwigIsFoo() + SwigGetFoo() Foo +} + +type SwigcptrBaz uintptr + +func (p SwigcptrBaz) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrBaz) SwigIsBaz() { +} + +var _wrap_baz__baz_set unsafe.Pointer + +func _swig_wrap_baz__baz_set(base SwigcptrBaz, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_baz__baz_set, _swig_p) + return +} + +func (arg1 SwigcptrBaz) SetX_baz(arg2 int) { + _swig_wrap_baz__baz_set(arg1, arg2) +} + +var _wrap_baz__baz_get unsafe.Pointer + +func _swig_wrap_baz__baz_get(base SwigcptrBaz) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_baz__baz_get, _swig_p) + return +} + +func (arg1 SwigcptrBaz) GetX_baz() (_swig_ret int) { + return _swig_wrap_baz__baz_get(arg1) +} + +var _wrap_new_baz unsafe.Pointer + +func _swig_wrap_new_baz() (base SwigcptrBaz) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_baz, _swig_p) + return +} + +func NewBaz() (_swig_ret Baz) { + return _swig_wrap_new_baz() +} + +var _wrap_delete_baz unsafe.Pointer + +func _swig_wrap_delete_baz(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_baz, _swig_p) + return +} + +func DeleteBaz(arg1 Baz) { + _swig_wrap_delete_baz(arg1.Swigcptr()) +} + +var _wrap_Setbaz_X_foo unsafe.Pointer + +func _swig_wrap_Setbaz_X_foo(base SwigcptrBaz, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Setbaz_X_foo, _swig_p) + return +} + +func (_swig_base SwigcptrBaz) SetX_foo(arg1 int) { + _swig_wrap_Setbaz_X_foo(_swig_base, arg1) +} + +var _wrap_Getbaz_X_foo unsafe.Pointer + +func _swig_wrap_Getbaz_X_foo(base SwigcptrBaz) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Getbaz_X_foo, _swig_p) + return +} + +func (_swig_base SwigcptrBaz) GetX_foo() (_swig_ret int) { + return _swig_wrap_Getbaz_X_foo(_swig_base) +} + +func (p SwigcptrBaz) SwigIsFoo() { +} + +func (p SwigcptrBaz) SwigGetFoo() Foo { + return SwigcptrFoo(p.Swigcptr()) +} + +type Baz interface { + Swigcptr() uintptr + SwigIsBaz() + SetX_baz(arg2 int) + GetX_baz() (_swig_ret int) + SetX_foo(arg1 int) + GetX_foo() (_swig_ret int) + SwigIsFoo() + SwigGetFoo() Foo +} + +type SwigcptrSpam uintptr + +func (p SwigcptrSpam) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrSpam) SwigIsSpam() { +} + +var _wrap_spam__spam_set unsafe.Pointer + +func _swig_wrap_spam__spam_set(base SwigcptrSpam, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_spam__spam_set, _swig_p) + return +} + +func (arg1 SwigcptrSpam) SetX_spam(arg2 int) { + _swig_wrap_spam__spam_set(arg1, arg2) +} + +var _wrap_spam__spam_get unsafe.Pointer + +func _swig_wrap_spam__spam_get(base SwigcptrSpam) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_spam__spam_get, _swig_p) + return +} + +func (arg1 SwigcptrSpam) GetX_spam() (_swig_ret int) { + return _swig_wrap_spam__spam_get(arg1) +} + +var _wrap_new_spam unsafe.Pointer + +func _swig_wrap_new_spam() (base SwigcptrSpam) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_spam, _swig_p) + return +} + +func NewSpam() (_swig_ret Spam) { + return _swig_wrap_new_spam() +} + +var _wrap_delete_spam unsafe.Pointer + +func _swig_wrap_delete_spam(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_spam, _swig_p) + return +} + +func DeleteSpam(arg1 Spam) { + _swig_wrap_delete_spam(arg1.Swigcptr()) +} + +var _wrap_Setspam_X_bar unsafe.Pointer + +func _swig_wrap_Setspam_X_bar(base SwigcptrSpam, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Setspam_X_bar, _swig_p) + return +} + +func (_swig_base SwigcptrSpam) SetX_bar(arg1 int) { + _swig_wrap_Setspam_X_bar(_swig_base, arg1) +} + +var _wrap_Getspam_X_bar unsafe.Pointer + +func _swig_wrap_Getspam_X_bar(base SwigcptrSpam) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Getspam_X_bar, _swig_p) + return +} + +func (_swig_base SwigcptrSpam) GetX_bar() (_swig_ret int) { + return _swig_wrap_Getspam_X_bar(_swig_base) +} + +var _wrap_Setspam_X_foo unsafe.Pointer + +func _swig_wrap_Setspam_X_foo(base SwigcptrSpam, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Setspam_X_foo, _swig_p) + return +} + +func (_swig_base SwigcptrSpam) SetX_foo(arg1 int) { + _swig_wrap_Setspam_X_foo(_swig_base, arg1) +} + +var _wrap_Getspam_X_foo unsafe.Pointer + +func _swig_wrap_Getspam_X_foo(base SwigcptrSpam) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Getspam_X_foo, _swig_p) + return +} + +func (_swig_base SwigcptrSpam) GetX_foo() (_swig_ret int) { + return _swig_wrap_Getspam_X_foo(_swig_base) +} + +var _wrap_Setspam_X_baz unsafe.Pointer + +func _swig_wrap_Setspam_X_baz(base SwigcptrSpam, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Setspam_X_baz, _swig_p) + return +} + +func (_swig_base SwigcptrSpam) SetX_baz(arg1 int) { + _swig_wrap_Setspam_X_baz(_swig_base, arg1) +} + +var _wrap_Getspam_X_baz unsafe.Pointer + +func _swig_wrap_Getspam_X_baz(base SwigcptrSpam) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Getspam_X_baz, _swig_p) + return +} + +func (_swig_base SwigcptrSpam) GetX_baz() (_swig_ret int) { + return _swig_wrap_Getspam_X_baz(_swig_base) +} + +func (p SwigcptrSpam) SwigIsBar() { +} + +func (p SwigcptrSpam) SwigGetBar() Bar { + return SwigcptrBar(p.Swigcptr()) +} + +func (p SwigcptrSpam) SwigIsFoo() { +} + +func (p SwigcptrSpam) SwigGetFoo() Foo { + return SwigcptrFoo(p.Swigcptr()) +} + +var _wrap_spam_SwigGetBaz unsafe.Pointer + +func _swig_wrap_spam_SwigGetBaz(base SwigcptrSpam) (_ SwigcptrBaz) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_spam_SwigGetBaz, _swig_p) + return +} + +func (arg1 SwigcptrSpam) SwigGetBaz() (_swig_ret Baz) { + return _swig_wrap_spam_SwigGetBaz(arg1) +} + +type Spam interface { + Swigcptr() uintptr + SwigIsSpam() + SetX_spam(arg2 int) + GetX_spam() (_swig_ret int) + SetX_bar(arg1 int) + GetX_bar() (_swig_ret int) + SetX_foo(arg1 int) + GetX_foo() (_swig_ret int) + SetX_baz(arg1 int) + GetX_baz() (_swig_ret int) + SwigIsBar() + SwigGetBar() Bar + SwigIsFoo() + SwigGetFoo() Foo + SwigGetBaz() (_swig_ret Baz) +} + +var _wrap_test unsafe.Pointer + +func _swig_wrap_test(base uintptr) (_ SwigcptrFoo) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_test, _swig_p) + return +} + +func Test(arg1 Foo) (_swig_ret Foo) { + return _swig_wrap_test(arg1.Swigcptr()) +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/exception_order.go b/Examples/test-suite/go/exception_order.go new file mode 100644 index 000000000..dcf7a81cd --- /dev/null +++ b/Examples/test-suite/go/exception_order.go @@ -0,0 +1,441 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../exception_order.i + +package exception_order + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +var _wrap_efoovar_set unsafe.Pointer + +func _swig_wrap_efoovar_set(base int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_efoovar_set, _swig_p) + return +} + +func SetEfoovar(arg1 int) { + _swig_wrap_efoovar_set(arg1) +} + +var _wrap_efoovar_get unsafe.Pointer + +func GetEfoovar() (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_efoovar_get, _swig_p) + return +} +var _wrap_foovar_set unsafe.Pointer + +func _swig_wrap_foovar_set(base int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_foovar_set, _swig_p) + return +} + +func SetFoovar(arg1 int) { + _swig_wrap_foovar_set(arg1) +} + +var _wrap_foovar_get unsafe.Pointer + +func GetFoovar() (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_foovar_get, _swig_p) + return +} +var _wrap_cfoovar_get unsafe.Pointer + +func GetCfoovar() (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_cfoovar_get, _swig_p) + return +} +type SwigcptrE1 uintptr + +func (p SwigcptrE1) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrE1) SwigIsE1() { +} + +var _wrap_new_E1 unsafe.Pointer + +func _swig_wrap_new_E1() (base SwigcptrE1) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_E1, _swig_p) + return +} + +func NewE1() (_swig_ret E1) { + return _swig_wrap_new_E1() +} + +var _wrap_delete_E1 unsafe.Pointer + +func _swig_wrap_delete_E1(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_E1, _swig_p) + return +} + +func DeleteE1(arg1 E1) { + _swig_wrap_delete_E1(arg1.Swigcptr()) +} + +type E1 interface { + Swigcptr() uintptr + SwigIsE1() +} + +type SwigcptrE2 uintptr + +func (p SwigcptrE2) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrE2) SwigIsE2() { +} + +var _wrap_new_E2 unsafe.Pointer + +func _swig_wrap_new_E2() (base SwigcptrE2) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_E2, _swig_p) + return +} + +func NewE2() (_swig_ret E2) { + return _swig_wrap_new_E2() +} + +var _wrap_delete_E2 unsafe.Pointer + +func _swig_wrap_delete_E2(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_E2, _swig_p) + return +} + +func DeleteE2(arg1 E2) { + _swig_wrap_delete_E2(arg1.Swigcptr()) +} + +type E2 interface { + Swigcptr() uintptr + SwigIsE2() +} + +type SwigcptrE3 uintptr + +func (p SwigcptrE3) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrE3) SwigIsE3() { +} + +var _wrap_new_E3 unsafe.Pointer + +func _swig_wrap_new_E3() (base SwigcptrE3) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_E3, _swig_p) + return +} + +func NewE3() (_swig_ret E3) { + return _swig_wrap_new_E3() +} + +var _wrap_delete_E3 unsafe.Pointer + +func _swig_wrap_delete_E3(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_E3, _swig_p) + return +} + +func DeleteE3(arg1 E3) { + _swig_wrap_delete_E3(arg1.Swigcptr()) +} + +type E3 interface { + Swigcptr() uintptr + SwigIsE3() +} + +type SwigcptrA uintptr + +func (p SwigcptrA) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrA) SwigIsA() { +} + +var _wrap_A_sfoovar_set unsafe.Pointer + +func _swig_wrap_A_sfoovar_set(base int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_A_sfoovar_set, _swig_p) + return +} + +func SetASfoovar(arg1 int) { + _swig_wrap_A_sfoovar_set(arg1) +} + +var _wrap_A_sfoovar_get unsafe.Pointer + +func GetASfoovar() (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_A_sfoovar_get, _swig_p) + return +} +var _wrap_A_CSFOOVAR_A unsafe.Pointer + +func _swig_getA_A_CSFOOVAR_A() (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_A_CSFOOVAR_A, _swig_p) + return +} +var ACSFOOVAR int = _swig_getA_A_CSFOOVAR_A() +var _wrap_A_foovar_set unsafe.Pointer + +func _swig_wrap_A_foovar_set(base SwigcptrA, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_A_foovar_set, _swig_p) + return +} + +func (arg1 SwigcptrA) SetFoovar(arg2 int) { + _swig_wrap_A_foovar_set(arg1, arg2) +} + +var _wrap_A_foovar_get unsafe.Pointer + +func _swig_wrap_A_foovar_get(base SwigcptrA) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_A_foovar_get, _swig_p) + return +} + +func (arg1 SwigcptrA) GetFoovar() (_swig_ret int) { + return _swig_wrap_A_foovar_get(arg1) +} + +var _wrap_A_efoovar_set unsafe.Pointer + +func _swig_wrap_A_efoovar_set(base SwigcptrA, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_A_efoovar_set, _swig_p) + return +} + +func (arg1 SwigcptrA) SetEfoovar(arg2 int) { + _swig_wrap_A_efoovar_set(arg1, arg2) +} + +var _wrap_A_efoovar_get unsafe.Pointer + +func _swig_wrap_A_efoovar_get(base SwigcptrA) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_A_efoovar_get, _swig_p) + return +} + +func (arg1 SwigcptrA) GetEfoovar() (_swig_ret int) { + return _swig_wrap_A_efoovar_get(arg1) +} + +var _wrap_A_foo unsafe.Pointer + +func _swig_wrap_A_foo(base SwigcptrA) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_A_foo, _swig_p) + return +} + +func (arg1 SwigcptrA) Foo() (_swig_ret int) { + return _swig_wrap_A_foo(arg1) +} + +var _wrap_A_bar unsafe.Pointer + +func _swig_wrap_A_bar(base SwigcptrA) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_A_bar, _swig_p) + return +} + +func (arg1 SwigcptrA) Bar() (_swig_ret int) { + return _swig_wrap_A_bar(arg1) +} + +var _wrap_A_foobar unsafe.Pointer + +func _swig_wrap_A_foobar(base SwigcptrA) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_A_foobar, _swig_p) + return +} + +func (arg1 SwigcptrA) Foobar() (_swig_ret int) { + return _swig_wrap_A_foobar(arg1) +} + +var _wrap_A_barfoo unsafe.Pointer + +func _swig_wrap_A_barfoo(base SwigcptrA, _ int) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_A_barfoo, _swig_p) + return +} + +func (arg1 SwigcptrA) Barfoo(arg2 int) (_swig_ret int) { + return _swig_wrap_A_barfoo(arg1, arg2) +} + +var _wrap_new_A unsafe.Pointer + +func _swig_wrap_new_A() (base SwigcptrA) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_A, _swig_p) + return +} + +func NewA() (_swig_ret A) { + return _swig_wrap_new_A() +} + +var _wrap_delete_A unsafe.Pointer + +func _swig_wrap_delete_A(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_A, _swig_p) + return +} + +func DeleteA(arg1 A) { + _swig_wrap_delete_A(arg1.Swigcptr()) +} + +type A interface { + Swigcptr() uintptr + SwigIsA() + SetFoovar(arg2 int) + GetFoovar() (_swig_ret int) + SetEfoovar(arg2 int) + GetEfoovar() (_swig_ret int) + Foo() (_swig_ret int) + Bar() (_swig_ret int) + Foobar() (_swig_ret int) + Barfoo(arg2 int) (_swig_ret int) +} + +type SwigcptrET_i uintptr + +func (p SwigcptrET_i) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrET_i) SwigIsET_i() { +} + +var _wrap_new_ET_i unsafe.Pointer + +func _swig_wrap_new_ET_i() (base SwigcptrET_i) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_ET_i, _swig_p) + return +} + +func NewET_i() (_swig_ret ET_i) { + return _swig_wrap_new_ET_i() +} + +var _wrap_delete_ET_i unsafe.Pointer + +func _swig_wrap_delete_ET_i(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_ET_i, _swig_p) + return +} + +func DeleteET_i(arg1 ET_i) { + _swig_wrap_delete_ET_i(arg1.Swigcptr()) +} + +type ET_i interface { + Swigcptr() uintptr + SwigIsET_i() +} + +type SwigcptrET_d uintptr + +func (p SwigcptrET_d) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrET_d) SwigIsET_d() { +} + +var _wrap_new_ET_d unsafe.Pointer + +func _swig_wrap_new_ET_d() (base SwigcptrET_d) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_ET_d, _swig_p) + return +} + +func NewET_d() (_swig_ret ET_d) { + return _swig_wrap_new_ET_d() +} + +var _wrap_delete_ET_d unsafe.Pointer + +func _swig_wrap_delete_ET_d(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_ET_d, _swig_p) + return +} + +func DeleteET_d(arg1 ET_d) { + _swig_wrap_delete_ET_d(arg1.Swigcptr()) +} + +type ET_d interface { + Swigcptr() uintptr + SwigIsET_d() +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/exception_order_runme b/Examples/test-suite/go/exception_order_runme new file mode 100755 index 000000000..ef48aef39 Binary files /dev/null and b/Examples/test-suite/go/exception_order_runme differ diff --git a/Examples/test-suite/go/expressions.go b/Examples/test-suite/go/expressions.go new file mode 100644 index 000000000..c1aa6e46a --- /dev/null +++ b/Examples/test-suite/go/expressions.go @@ -0,0 +1,124 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../expressions.i + +package expressions + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrA uintptr + +func (p SwigcptrA) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrA) SwigIsA() { +} + +var _wrap_new_A__SWIG_0 unsafe.Pointer + +func _swig_wrap_new_A__SWIG_0() (base SwigcptrA) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_A__SWIG_0, _swig_p) + return +} + +func NewA__SWIG_0() (_swig_ret A) { + return _swig_wrap_new_A__SWIG_0() +} + +var _wrap_new_A__SWIG_1 unsafe.Pointer + +func _swig_wrap_new_A__SWIG_1(base int) (_ SwigcptrA) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_A__SWIG_1, _swig_p) + return +} + +func NewA__SWIG_1(arg1 int) (_swig_ret A) { + return _swig_wrap_new_A__SWIG_1(arg1) +} + +func NewA(a ...interface{}) A { + argc := len(a) + if argc == 0 { + return NewA__SWIG_0() + } + if argc == 1 { + return NewA__SWIG_1(a[0].(int)) + } + panic("No match for overloaded function call") +} + +var _wrap_A_k_set unsafe.Pointer + +func _swig_wrap_A_k_set(base SwigcptrA, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_A_k_set, _swig_p) + return +} + +func (arg1 SwigcptrA) SetK(arg2 int) { + _swig_wrap_A_k_set(arg1, arg2) +} + +var _wrap_A_k_get unsafe.Pointer + +func _swig_wrap_A_k_get(base SwigcptrA) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_A_k_get, _swig_p) + return +} + +func (arg1 SwigcptrA) GetK() (_swig_ret int) { + return _swig_wrap_A_k_get(arg1) +} + +var _wrap_delete_A unsafe.Pointer + +func _swig_wrap_delete_A(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_A, _swig_p) + return +} + +func DeleteA(arg1 A) { + _swig_wrap_delete_A(arg1.Swigcptr()) +} + +type A interface { + Swigcptr() uintptr + SwigIsA() + SetK(arg2 int) + GetK() (_swig_ret int) +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/extend.go b/Examples/test-suite/go/extend.go new file mode 100644 index 000000000..3a5b019af --- /dev/null +++ b/Examples/test-suite/go/extend.go @@ -0,0 +1,308 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../extend.i + +package extend + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrBase uintptr + +func (p SwigcptrBase) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrBase) SwigIsBase() { +} + +var _wrap_new_Base__SWIG_0 unsafe.Pointer + +func _swig_wrap_new_Base__SWIG_0(base int) (_ SwigcptrBase) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Base__SWIG_0, _swig_p) + return +} + +func NewBase__SWIG_0(arg1 int) (_swig_ret Base) { + return _swig_wrap_new_Base__SWIG_0(arg1) +} + +var _wrap_new_Base__SWIG_1 unsafe.Pointer + +func _swig_wrap_new_Base__SWIG_1() (base SwigcptrBase) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Base__SWIG_1, _swig_p) + return +} + +func NewBase__SWIG_1() (_swig_ret Base) { + return _swig_wrap_new_Base__SWIG_1() +} + +func NewBase(a ...interface{}) Base { + argc := len(a) + if argc == 0 { + return NewBase__SWIG_1() + } + if argc == 1 { + return NewBase__SWIG_0(a[0].(int)) + } + panic("No match for overloaded function call") +} + +var _wrap_Base_value_set unsafe.Pointer + +func _swig_wrap_Base_value_set(base SwigcptrBase, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Base_value_set, _swig_p) + return +} + +func (arg1 SwigcptrBase) SetValue(arg2 int) { + _swig_wrap_Base_value_set(arg1, arg2) +} + +var _wrap_Base_value_get unsafe.Pointer + +func _swig_wrap_Base_value_get(base SwigcptrBase) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Base_value_get, _swig_p) + return +} + +func (arg1 SwigcptrBase) GetValue() (_swig_ret int) { + return _swig_wrap_Base_value_get(arg1) +} + +var _wrap_Base_method unsafe.Pointer + +func _swig_wrap_Base_method(base SwigcptrBase, _ int) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Base_method, _swig_p) + return +} + +func (arg1 SwigcptrBase) Method(arg2 int) (_swig_ret int) { + return _swig_wrap_Base_method(arg1, arg2) +} + +var _wrap_delete_Base unsafe.Pointer + +func _swig_wrap_delete_Base(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Base, _swig_p) + return +} + +func DeleteBase(arg1 Base) { + _swig_wrap_delete_Base(arg1.Swigcptr()) +} + +var _wrap_Base_zeroVal unsafe.Pointer + +func BaseZeroVal() (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_Base_zeroVal, _swig_p) + return +} +var _wrap_Base_currentValue unsafe.Pointer + +func _swig_wrap_Base_currentValue(base SwigcptrBase) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Base_currentValue, _swig_p) + return +} + +func (arg1 SwigcptrBase) CurrentValue() (_swig_ret int) { + return _swig_wrap_Base_currentValue(arg1) +} + +var _wrap_Base_extendmethod unsafe.Pointer + +func _swig_wrap_Base_extendmethod(base SwigcptrBase, _ int) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Base_extendmethod, _swig_p) + return +} + +func (arg1 SwigcptrBase) Extendmethod(arg2 int) (_swig_ret int) { + return _swig_wrap_Base_extendmethod(arg1, arg2) +} + +type Base interface { + Swigcptr() uintptr + SwigIsBase() + SetValue(arg2 int) + GetValue() (_swig_ret int) + Method(arg2 int) (_swig_ret int) + CurrentValue() (_swig_ret int) + Extendmethod(arg2 int) (_swig_ret int) +} + +type SwigcptrDerived uintptr + +func (p SwigcptrDerived) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrDerived) SwigIsDerived() { +} + +var _wrap_Derived_actualval_set unsafe.Pointer + +func _swig_wrap_Derived_actualval_set(base SwigcptrDerived, _ float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Derived_actualval_set, _swig_p) + return +} + +func (arg1 SwigcptrDerived) SetActualval(arg2 float64) { + _swig_wrap_Derived_actualval_set(arg1, arg2) +} + +var _wrap_Derived_actualval_get unsafe.Pointer + +func _swig_wrap_Derived_actualval_get(base SwigcptrDerived) (_ float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Derived_actualval_get, _swig_p) + return +} + +func (arg1 SwigcptrDerived) GetActualval() (_swig_ret float64) { + return _swig_wrap_Derived_actualval_get(arg1) +} + +var _wrap_new_Derived unsafe.Pointer + +func _swig_wrap_new_Derived(base int) (_ SwigcptrDerived) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Derived, _swig_p) + return +} + +func NewDerived(arg1 int) (_swig_ret Derived) { + return _swig_wrap_new_Derived(arg1) +} + +var _wrap_Derived_method unsafe.Pointer + +func _swig_wrap_Derived_method(base SwigcptrDerived, _ int) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Derived_method, _swig_p) + return +} + +func (arg1 SwigcptrDerived) Method(arg2 int) (_swig_ret int) { + return _swig_wrap_Derived_method(arg1, arg2) +} + +var _wrap_Derived_extendval_set unsafe.Pointer + +func _swig_wrap_Derived_extendval_set(base SwigcptrDerived, _ float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Derived_extendval_set, _swig_p) + return +} + +func (arg1 SwigcptrDerived) SetExtendval(arg2 float64) { + _swig_wrap_Derived_extendval_set(arg1, arg2) +} + +var _wrap_Derived_extendval_get unsafe.Pointer + +func _swig_wrap_Derived_extendval_get(base SwigcptrDerived) (_ float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Derived_extendval_get, _swig_p) + return +} + +func (arg1 SwigcptrDerived) GetExtendval() (_swig_ret float64) { + return _swig_wrap_Derived_extendval_get(arg1) +} + +var _wrap_delete_Derived unsafe.Pointer + +func _swig_wrap_delete_Derived(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Derived, _swig_p) + return +} + +func DeleteDerived(arg1 Derived) { + _swig_wrap_delete_Derived(arg1.Swigcptr()) +} + +var _wrap_SetDerived_Value unsafe.Pointer + +func _swig_wrap_SetDerived_Value(base SwigcptrDerived, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_SetDerived_Value, _swig_p) + return +} + +func (_swig_base SwigcptrDerived) SetValue(arg1 int) { + _swig_wrap_SetDerived_Value(_swig_base, arg1) +} + +var _wrap_GetDerived_Value unsafe.Pointer + +func _swig_wrap_GetDerived_Value(base SwigcptrDerived) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_GetDerived_Value, _swig_p) + return +} + +func (_swig_base SwigcptrDerived) GetValue() (_swig_ret int) { + return _swig_wrap_GetDerived_Value(_swig_base) +} + +func (p SwigcptrDerived) SwigIsBase() { +} + +func (p SwigcptrDerived) SwigGetBase() Base { + return SwigcptrBase(p.Swigcptr()) +} + +type Derived interface { + Swigcptr() uintptr + SwigIsDerived() + SetActualval(arg2 float64) + GetActualval() (_swig_ret float64) + Method(arg2 int) (_swig_ret int) + SetExtendval(arg2 float64) + GetExtendval() (_swig_ret float64) + SetValue(arg1 int) + GetValue() (_swig_ret int) + SwigIsBase() + SwigGetBase() Base +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/extend_constructor_destructor.go b/Examples/test-suite/go/extend_constructor_destructor.go new file mode 100644 index 000000000..9d42a0fcd --- /dev/null +++ b/Examples/test-suite/go/extend_constructor_destructor.go @@ -0,0 +1,504 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../extend_constructor_destructor.i + +package extend_constructor_destructor + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +var _wrap_globalVar_set unsafe.Pointer + +func _swig_wrap_globalVar_set(base int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_globalVar_set, _swig_p) + return +} + +func SetGlobalVar(arg1 int) { + _swig_wrap_globalVar_set(arg1) +} + +var _wrap_globalVar_get unsafe.Pointer + +func GetGlobalVar() (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_globalVar_get, _swig_p) + return +} +type SwigcptrAStruct uintptr + +func (p SwigcptrAStruct) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrAStruct) SwigIsAStruct() { +} + +var _wrap_AStruct_ivar_set unsafe.Pointer + +func _swig_wrap_AStruct_ivar_set(base SwigcptrAStruct, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_AStruct_ivar_set, _swig_p) + return +} + +func (arg1 SwigcptrAStruct) SetIvar(arg2 int) { + _swig_wrap_AStruct_ivar_set(arg1, arg2) +} + +var _wrap_AStruct_ivar_get unsafe.Pointer + +func _swig_wrap_AStruct_ivar_get(base SwigcptrAStruct) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_AStruct_ivar_get, _swig_p) + return +} + +func (arg1 SwigcptrAStruct) GetIvar() (_swig_ret int) { + return _swig_wrap_AStruct_ivar_get(arg1) +} + +var _wrap_new_AStruct unsafe.Pointer + +func _swig_wrap_new_AStruct(base int) (_ SwigcptrAStruct) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_AStruct, _swig_p) + return +} + +func NewAStruct(arg1 int) (_swig_ret AStruct) { + return _swig_wrap_new_AStruct(arg1) +} + +var _wrap_delete_AStruct unsafe.Pointer + +func _swig_wrap_delete_AStruct(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_AStruct, _swig_p) + return +} + +func DeleteAStruct(arg1 AStruct) { + _swig_wrap_delete_AStruct(arg1.Swigcptr()) +} + +type AStruct interface { + Swigcptr() uintptr + SwigIsAStruct() + SetIvar(arg2 int) + GetIvar() (_swig_ret int) +} + +type SwigcptrBStruct uintptr + +func (p SwigcptrBStruct) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrBStruct) SwigIsBStruct() { +} + +var _wrap_BStruct_ivar_set unsafe.Pointer + +func _swig_wrap_BStruct_ivar_set(base SwigcptrBStruct, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_BStruct_ivar_set, _swig_p) + return +} + +func (arg1 SwigcptrBStruct) SetIvar(arg2 int) { + _swig_wrap_BStruct_ivar_set(arg1, arg2) +} + +var _wrap_BStruct_ivar_get unsafe.Pointer + +func _swig_wrap_BStruct_ivar_get(base SwigcptrBStruct) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_BStruct_ivar_get, _swig_p) + return +} + +func (arg1 SwigcptrBStruct) GetIvar() (_swig_ret int) { + return _swig_wrap_BStruct_ivar_get(arg1) +} + +var _wrap_new_BStruct unsafe.Pointer + +func _swig_wrap_new_BStruct(base int) (_ SwigcptrBStruct) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_BStruct, _swig_p) + return +} + +func NewBStruct(arg1 int) (_swig_ret BStruct) { + return _swig_wrap_new_BStruct(arg1) +} + +var _wrap_delete_BStruct unsafe.Pointer + +func _swig_wrap_delete_BStruct(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_BStruct, _swig_p) + return +} + +func DeleteBStruct(arg1 BStruct) { + _swig_wrap_delete_BStruct(arg1.Swigcptr()) +} + +type BStruct interface { + Swigcptr() uintptr + SwigIsBStruct() + SetIvar(arg2 int) + GetIvar() (_swig_ret int) +} + +type SwigcptrCStruct uintptr + +func (p SwigcptrCStruct) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrCStruct) SwigIsCStruct() { +} + +var _wrap_CStruct_ivar_set unsafe.Pointer + +func _swig_wrap_CStruct_ivar_set(base SwigcptrCStruct, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_CStruct_ivar_set, _swig_p) + return +} + +func (arg1 SwigcptrCStruct) SetIvar(arg2 int) { + _swig_wrap_CStruct_ivar_set(arg1, arg2) +} + +var _wrap_CStruct_ivar_get unsafe.Pointer + +func _swig_wrap_CStruct_ivar_get(base SwigcptrCStruct) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_CStruct_ivar_get, _swig_p) + return +} + +func (arg1 SwigcptrCStruct) GetIvar() (_swig_ret int) { + return _swig_wrap_CStruct_ivar_get(arg1) +} + +var _wrap_new_CStruct unsafe.Pointer + +func _swig_wrap_new_CStruct(base int) (_ SwigcptrCStruct) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_CStruct, _swig_p) + return +} + +func NewCStruct(arg1 int) (_swig_ret CStruct) { + return _swig_wrap_new_CStruct(arg1) +} + +var _wrap_delete_CStruct unsafe.Pointer + +func _swig_wrap_delete_CStruct(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_CStruct, _swig_p) + return +} + +func DeleteCStruct(arg1 CStruct) { + _swig_wrap_delete_CStruct(arg1.Swigcptr()) +} + +type CStruct interface { + Swigcptr() uintptr + SwigIsCStruct() + SetIvar(arg2 int) + GetIvar() (_swig_ret int) +} + +type SwigcptrDStruct uintptr + +func (p SwigcptrDStruct) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrDStruct) SwigIsDStruct() { +} + +var _wrap_DStruct_ivar_set unsafe.Pointer + +func _swig_wrap_DStruct_ivar_set(base SwigcptrDStruct, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_DStruct_ivar_set, _swig_p) + return +} + +func (arg1 SwigcptrDStruct) SetIvar(arg2 int) { + _swig_wrap_DStruct_ivar_set(arg1, arg2) +} + +var _wrap_DStruct_ivar_get unsafe.Pointer + +func _swig_wrap_DStruct_ivar_get(base SwigcptrDStruct) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_DStruct_ivar_get, _swig_p) + return +} + +func (arg1 SwigcptrDStruct) GetIvar() (_swig_ret int) { + return _swig_wrap_DStruct_ivar_get(arg1) +} + +var _wrap_new_DStruct unsafe.Pointer + +func _swig_wrap_new_DStruct(base int) (_ SwigcptrDStruct) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_DStruct, _swig_p) + return +} + +func NewDStruct(arg1 int) (_swig_ret DStruct) { + return _swig_wrap_new_DStruct(arg1) +} + +var _wrap_delete_DStruct unsafe.Pointer + +func _swig_wrap_delete_DStruct(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_DStruct, _swig_p) + return +} + +func DeleteDStruct(arg1 DStruct) { + _swig_wrap_delete_DStruct(arg1.Swigcptr()) +} + +type DStruct interface { + Swigcptr() uintptr + SwigIsDStruct() + SetIvar(arg2 int) + GetIvar() (_swig_ret int) +} + +type SwigcptrEStruct uintptr + +func (p SwigcptrEStruct) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrEStruct) SwigIsEStruct() { +} + +var _wrap_EStruct_ivar_set unsafe.Pointer + +func _swig_wrap_EStruct_ivar_set(base SwigcptrEStruct, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_EStruct_ivar_set, _swig_p) + return +} + +func (arg1 SwigcptrEStruct) SetIvar(arg2 int) { + _swig_wrap_EStruct_ivar_set(arg1, arg2) +} + +var _wrap_EStruct_ivar_get unsafe.Pointer + +func _swig_wrap_EStruct_ivar_get(base SwigcptrEStruct) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_EStruct_ivar_get, _swig_p) + return +} + +func (arg1 SwigcptrEStruct) GetIvar() (_swig_ret int) { + return _swig_wrap_EStruct_ivar_get(arg1) +} + +var _wrap_new_EStruct unsafe.Pointer + +func _swig_wrap_new_EStruct(base int) (_ SwigcptrEStruct) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_EStruct, _swig_p) + return +} + +func NewEStruct(arg1 int) (_swig_ret EStruct) { + return _swig_wrap_new_EStruct(arg1) +} + +var _wrap_delete_EStruct unsafe.Pointer + +func _swig_wrap_delete_EStruct(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_EStruct, _swig_p) + return +} + +func DeleteEStruct(arg1 EStruct) { + _swig_wrap_delete_EStruct(arg1.Swigcptr()) +} + +type EStruct interface { + Swigcptr() uintptr + SwigIsEStruct() + SetIvar(arg2 int) + GetIvar() (_swig_ret int) +} + +type SwigcptrFStruct uintptr + +func (p SwigcptrFStruct) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrFStruct) SwigIsFStruct() { +} + +var _wrap_FStruct_ivar_set unsafe.Pointer + +func _swig_wrap_FStruct_ivar_set(base SwigcptrFStruct, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_FStruct_ivar_set, _swig_p) + return +} + +func (arg1 SwigcptrFStruct) SetIvar(arg2 int) { + _swig_wrap_FStruct_ivar_set(arg1, arg2) +} + +var _wrap_FStruct_ivar_get unsafe.Pointer + +func _swig_wrap_FStruct_ivar_get(base SwigcptrFStruct) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_FStruct_ivar_get, _swig_p) + return +} + +func (arg1 SwigcptrFStruct) GetIvar() (_swig_ret int) { + return _swig_wrap_FStruct_ivar_get(arg1) +} + +var _wrap_new_FStruct unsafe.Pointer + +func _swig_wrap_new_FStruct(base int) (_ SwigcptrFStruct) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_FStruct, _swig_p) + return +} + +func NewFStruct(arg1 int) (_swig_ret FStruct) { + return _swig_wrap_new_FStruct(arg1) +} + +var _wrap_delete_FStruct unsafe.Pointer + +func _swig_wrap_delete_FStruct(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_FStruct, _swig_p) + return +} + +func DeleteFStruct(arg1 FStruct) { + _swig_wrap_delete_FStruct(arg1.Swigcptr()) +} + +type FStruct interface { + Swigcptr() uintptr + SwigIsFStruct() + SetIvar(arg2 int) + GetIvar() (_swig_ret int) +} + +type SwigcptrGStruct uintptr + +func (p SwigcptrGStruct) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrGStruct) SwigIsGStruct() { +} + +var _wrap_GStruct_ivar_set unsafe.Pointer + +func _swig_wrap_GStruct_ivar_set(base SwigcptrGStruct, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_GStruct_ivar_set, _swig_p) + return +} + +func (arg1 SwigcptrGStruct) SetIvar(arg2 int) { + _swig_wrap_GStruct_ivar_set(arg1, arg2) +} + +var _wrap_GStruct_ivar_get unsafe.Pointer + +func _swig_wrap_GStruct_ivar_get(base SwigcptrGStruct) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_GStruct_ivar_get, _swig_p) + return +} + +func (arg1 SwigcptrGStruct) GetIvar() (_swig_ret int) { + return _swig_wrap_GStruct_ivar_get(arg1) +} + +var _wrap_new_GStruct unsafe.Pointer + +func _swig_wrap_new_GStruct(base int) (_ SwigcptrGStruct) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_GStruct, _swig_p) + return +} + +func NewGStruct(arg1 int) (_swig_ret GStruct) { + return _swig_wrap_new_GStruct(arg1) +} + +var _wrap_delete_GStruct unsafe.Pointer + +func _swig_wrap_delete_GStruct(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_GStruct, _swig_p) + return +} + +func DeleteGStruct(arg1 GStruct) { + _swig_wrap_delete_GStruct(arg1.Swigcptr()) +} + +type GStruct interface { + Swigcptr() uintptr + SwigIsGStruct() + SetIvar(arg2 int) + GetIvar() (_swig_ret int) +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/extend_default.go b/Examples/test-suite/go/extend_default.go new file mode 100644 index 000000000..9b25ff800 --- /dev/null +++ b/Examples/test-suite/go/extend_default.go @@ -0,0 +1,1696 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../extend_default.i + +package extend_default + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrBefore uintptr + +func (p SwigcptrBefore) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrBefore) SwigIsBefore() { +} + +var _wrap_Before_d_set unsafe.Pointer + +func _swig_wrap_Before_d_set(base SwigcptrBefore, _ float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Before_d_set, _swig_p) + return +} + +func (arg1 SwigcptrBefore) SetD(arg2 float64) { + _swig_wrap_Before_d_set(arg1, arg2) +} + +var _wrap_Before_d_get unsafe.Pointer + +func _swig_wrap_Before_d_get(base SwigcptrBefore) (_ float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Before_d_get, _swig_p) + return +} + +func (arg1 SwigcptrBefore) GetD() (_swig_ret float64) { + return _swig_wrap_Before_d_get(arg1) +} + +var _wrap_Before_i_set unsafe.Pointer + +func _swig_wrap_Before_i_set(base SwigcptrBefore, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Before_i_set, _swig_p) + return +} + +func (arg1 SwigcptrBefore) SetI(arg2 int) { + _swig_wrap_Before_i_set(arg1, arg2) +} + +var _wrap_Before_i_get unsafe.Pointer + +func _swig_wrap_Before_i_get(base SwigcptrBefore) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Before_i_get, _swig_p) + return +} + +func (arg1 SwigcptrBefore) GetI() (_swig_ret int) { + return _swig_wrap_Before_i_get(arg1) +} + +var _wrap_new_Before__SWIG_0 unsafe.Pointer + +func _swig_wrap_new_Before__SWIG_0(base int, _ float64) (_ SwigcptrBefore) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Before__SWIG_0, _swig_p) + return +} + +func NewBefore__SWIG_0(arg1 int, arg2 float64) (_swig_ret Before) { + return _swig_wrap_new_Before__SWIG_0(arg1, arg2) +} + +var _wrap_new_Before__SWIG_1 unsafe.Pointer + +func _swig_wrap_new_Before__SWIG_1(base int) (_ SwigcptrBefore) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Before__SWIG_1, _swig_p) + return +} + +func NewBefore__SWIG_1(arg1 int) (_swig_ret Before) { + return _swig_wrap_new_Before__SWIG_1(arg1) +} + +var _wrap_new_Before__SWIG_2 unsafe.Pointer + +func _swig_wrap_new_Before__SWIG_2() (base SwigcptrBefore) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Before__SWIG_2, _swig_p) + return +} + +func NewBefore__SWIG_2() (_swig_ret Before) { + return _swig_wrap_new_Before__SWIG_2() +} + +func NewBefore(a ...interface{}) Before { + argc := len(a) + if argc == 0 { + return NewBefore__SWIG_2() + } + if argc == 1 { + return NewBefore__SWIG_1(a[0].(int)) + } + if argc == 2 { + return NewBefore__SWIG_0(a[0].(int), a[1].(float64)) + } + panic("No match for overloaded function call") +} + +var _wrap_Before_AddedStaticMethod__SWIG_0 unsafe.Pointer + +func BeforeAddedStaticMethod__SWIG_0(arg1 int, arg2 float64) (_swig_ret float64) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_Before_AddedStaticMethod__SWIG_0, _swig_p) + return +} +var _wrap_Before_AddedStaticMethod__SWIG_1 unsafe.Pointer + +func BeforeAddedStaticMethod__SWIG_1(arg1 int) (_swig_ret float64) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_Before_AddedStaticMethod__SWIG_1, _swig_p) + return +} +var _wrap_Before_AddedStaticMethod__SWIG_2 unsafe.Pointer + +func BeforeAddedStaticMethod__SWIG_2() (_swig_ret float64) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_Before_AddedStaticMethod__SWIG_2, _swig_p) + return +} +func BeforeAddedStaticMethod(a ...interface{}) float64 { + argc := len(a) + if argc == 0 { + return BeforeAddedStaticMethod__SWIG_2() + } + if argc == 1 { + return BeforeAddedStaticMethod__SWIG_1(a[0].(int)) + } + if argc == 2 { + return BeforeAddedStaticMethod__SWIG_0(a[0].(int), a[1].(float64)) + } + panic("No match for overloaded function call") +} + +var _wrap_Before_AddedMethod__SWIG_0 unsafe.Pointer + +func _swig_wrap_Before_AddedMethod__SWIG_0(base SwigcptrBefore, _ int, _ float64) (_ float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Before_AddedMethod__SWIG_0, _swig_p) + return +} + +func (arg1 SwigcptrBefore) AddedMethod__SWIG_0(arg2 int, arg3 float64) (_swig_ret float64) { + return _swig_wrap_Before_AddedMethod__SWIG_0(arg1, arg2, arg3) +} + +var _wrap_Before_AddedMethod__SWIG_1 unsafe.Pointer + +func _swig_wrap_Before_AddedMethod__SWIG_1(base SwigcptrBefore, _ int) (_ float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Before_AddedMethod__SWIG_1, _swig_p) + return +} + +func (arg1 SwigcptrBefore) AddedMethod__SWIG_1(arg2 int) (_swig_ret float64) { + return _swig_wrap_Before_AddedMethod__SWIG_1(arg1, arg2) +} + +var _wrap_Before_AddedMethod__SWIG_2 unsafe.Pointer + +func _swig_wrap_Before_AddedMethod__SWIG_2(base SwigcptrBefore) (_ float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Before_AddedMethod__SWIG_2, _swig_p) + return +} + +func (arg1 SwigcptrBefore) AddedMethod__SWIG_2() (_swig_ret float64) { + return _swig_wrap_Before_AddedMethod__SWIG_2(arg1) +} + +func (p SwigcptrBefore) AddedMethod(a ...interface{}) float64 { + argc := len(a) + if argc == 0 { + return p.AddedMethod__SWIG_2() + } + if argc == 1 { + return p.AddedMethod__SWIG_1(a[0].(int)) + } + if argc == 2 { + return p.AddedMethod__SWIG_0(a[0].(int), a[1].(float64)) + } + panic("No match for overloaded function call") +} + +var _wrap_delete_Before unsafe.Pointer + +func _swig_wrap_delete_Before(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Before, _swig_p) + return +} + +func DeleteBefore(arg1 Before) { + _swig_wrap_delete_Before(arg1.Swigcptr()) +} + +type Before interface { + Swigcptr() uintptr + SwigIsBefore() + SetD(arg2 float64) + GetD() (_swig_ret float64) + SetI(arg2 int) + GetI() (_swig_ret int) + AddedMethod(a ...interface{}) float64 +} + +type SwigcptrAfter uintptr + +func (p SwigcptrAfter) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrAfter) SwigIsAfter() { +} + +var _wrap_After_d_set unsafe.Pointer + +func _swig_wrap_After_d_set(base SwigcptrAfter, _ float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_After_d_set, _swig_p) + return +} + +func (arg1 SwigcptrAfter) SetD(arg2 float64) { + _swig_wrap_After_d_set(arg1, arg2) +} + +var _wrap_After_d_get unsafe.Pointer + +func _swig_wrap_After_d_get(base SwigcptrAfter) (_ float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_After_d_get, _swig_p) + return +} + +func (arg1 SwigcptrAfter) GetD() (_swig_ret float64) { + return _swig_wrap_After_d_get(arg1) +} + +var _wrap_After_i_set unsafe.Pointer + +func _swig_wrap_After_i_set(base SwigcptrAfter, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_After_i_set, _swig_p) + return +} + +func (arg1 SwigcptrAfter) SetI(arg2 int) { + _swig_wrap_After_i_set(arg1, arg2) +} + +var _wrap_After_i_get unsafe.Pointer + +func _swig_wrap_After_i_get(base SwigcptrAfter) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_After_i_get, _swig_p) + return +} + +func (arg1 SwigcptrAfter) GetI() (_swig_ret int) { + return _swig_wrap_After_i_get(arg1) +} + +var _wrap_new_After__SWIG_0 unsafe.Pointer + +func _swig_wrap_new_After__SWIG_0(base int, _ float64) (_ SwigcptrAfter) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_After__SWIG_0, _swig_p) + return +} + +func NewAfter__SWIG_0(arg1 int, arg2 float64) (_swig_ret After) { + return _swig_wrap_new_After__SWIG_0(arg1, arg2) +} + +var _wrap_new_After__SWIG_1 unsafe.Pointer + +func _swig_wrap_new_After__SWIG_1(base int) (_ SwigcptrAfter) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_After__SWIG_1, _swig_p) + return +} + +func NewAfter__SWIG_1(arg1 int) (_swig_ret After) { + return _swig_wrap_new_After__SWIG_1(arg1) +} + +var _wrap_new_After__SWIG_2 unsafe.Pointer + +func _swig_wrap_new_After__SWIG_2() (base SwigcptrAfter) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_After__SWIG_2, _swig_p) + return +} + +func NewAfter__SWIG_2() (_swig_ret After) { + return _swig_wrap_new_After__SWIG_2() +} + +func NewAfter(a ...interface{}) After { + argc := len(a) + if argc == 0 { + return NewAfter__SWIG_2() + } + if argc == 1 { + return NewAfter__SWIG_1(a[0].(int)) + } + if argc == 2 { + return NewAfter__SWIG_0(a[0].(int), a[1].(float64)) + } + panic("No match for overloaded function call") +} + +var _wrap_After_AddedStaticMethod__SWIG_0 unsafe.Pointer + +func AfterAddedStaticMethod__SWIG_0(arg1 int, arg2 float64) (_swig_ret float64) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_After_AddedStaticMethod__SWIG_0, _swig_p) + return +} +var _wrap_After_AddedStaticMethod__SWIG_1 unsafe.Pointer + +func AfterAddedStaticMethod__SWIG_1(arg1 int) (_swig_ret float64) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_After_AddedStaticMethod__SWIG_1, _swig_p) + return +} +var _wrap_After_AddedStaticMethod__SWIG_2 unsafe.Pointer + +func AfterAddedStaticMethod__SWIG_2() (_swig_ret float64) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_After_AddedStaticMethod__SWIG_2, _swig_p) + return +} +func AfterAddedStaticMethod(a ...interface{}) float64 { + argc := len(a) + if argc == 0 { + return AfterAddedStaticMethod__SWIG_2() + } + if argc == 1 { + return AfterAddedStaticMethod__SWIG_1(a[0].(int)) + } + if argc == 2 { + return AfterAddedStaticMethod__SWIG_0(a[0].(int), a[1].(float64)) + } + panic("No match for overloaded function call") +} + +var _wrap_After_AddedMethod__SWIG_0 unsafe.Pointer + +func _swig_wrap_After_AddedMethod__SWIG_0(base SwigcptrAfter, _ int, _ float64) (_ float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_After_AddedMethod__SWIG_0, _swig_p) + return +} + +func (arg1 SwigcptrAfter) AddedMethod__SWIG_0(arg2 int, arg3 float64) (_swig_ret float64) { + return _swig_wrap_After_AddedMethod__SWIG_0(arg1, arg2, arg3) +} + +var _wrap_After_AddedMethod__SWIG_1 unsafe.Pointer + +func _swig_wrap_After_AddedMethod__SWIG_1(base SwigcptrAfter, _ int) (_ float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_After_AddedMethod__SWIG_1, _swig_p) + return +} + +func (arg1 SwigcptrAfter) AddedMethod__SWIG_1(arg2 int) (_swig_ret float64) { + return _swig_wrap_After_AddedMethod__SWIG_1(arg1, arg2) +} + +var _wrap_After_AddedMethod__SWIG_2 unsafe.Pointer + +func _swig_wrap_After_AddedMethod__SWIG_2(base SwigcptrAfter) (_ float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_After_AddedMethod__SWIG_2, _swig_p) + return +} + +func (arg1 SwigcptrAfter) AddedMethod__SWIG_2() (_swig_ret float64) { + return _swig_wrap_After_AddedMethod__SWIG_2(arg1) +} + +func (p SwigcptrAfter) AddedMethod(a ...interface{}) float64 { + argc := len(a) + if argc == 0 { + return p.AddedMethod__SWIG_2() + } + if argc == 1 { + return p.AddedMethod__SWIG_1(a[0].(int)) + } + if argc == 2 { + return p.AddedMethod__SWIG_0(a[0].(int), a[1].(float64)) + } + panic("No match for overloaded function call") +} + +var _wrap_delete_After unsafe.Pointer + +func _swig_wrap_delete_After(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_After, _swig_p) + return +} + +func DeleteAfter(arg1 After) { + _swig_wrap_delete_After(arg1.Swigcptr()) +} + +type After interface { + Swigcptr() uintptr + SwigIsAfter() + SetD(arg2 float64) + GetD() (_swig_ret float64) + SetI(arg2 int) + GetI() (_swig_ret int) + AddedMethod(a ...interface{}) float64 +} + +type SwigcptrOverBefore uintptr + +func (p SwigcptrOverBefore) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrOverBefore) SwigIsOverBefore() { +} + +var _wrap_new_OverBefore__SWIG_0 unsafe.Pointer + +func _swig_wrap_new_OverBefore__SWIG_0(base string, _ int, _ float64) (_ SwigcptrOverBefore) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_OverBefore__SWIG_0, _swig_p) + return +} + +func NewOverBefore__SWIG_0(arg1 string, arg2 int, arg3 float64) (_swig_ret OverBefore) { + return _swig_wrap_new_OverBefore__SWIG_0(arg1, arg2, arg3) +} + +var _wrap_new_OverBefore__SWIG_1 unsafe.Pointer + +func _swig_wrap_new_OverBefore__SWIG_1(base string, _ int) (_ SwigcptrOverBefore) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_OverBefore__SWIG_1, _swig_p) + return +} + +func NewOverBefore__SWIG_1(arg1 string, arg2 int) (_swig_ret OverBefore) { + return _swig_wrap_new_OverBefore__SWIG_1(arg1, arg2) +} + +var _wrap_new_OverBefore__SWIG_2 unsafe.Pointer + +func _swig_wrap_new_OverBefore__SWIG_2(base string) (_ SwigcptrOverBefore) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_OverBefore__SWIG_2, _swig_p) + return +} + +func NewOverBefore__SWIG_2(arg1 string) (_swig_ret OverBefore) { + return _swig_wrap_new_OverBefore__SWIG_2(arg1) +} + +var _wrap_OverBefore_AddedStaticMethod__SWIG_0 unsafe.Pointer + +func OverBeforeAddedStaticMethod__SWIG_0(arg1 string, arg2 int, arg3 float64) (_swig_ret float64) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_OverBefore_AddedStaticMethod__SWIG_0, _swig_p) + return +} +var _wrap_OverBefore_AddedStaticMethod__SWIG_1 unsafe.Pointer + +func OverBeforeAddedStaticMethod__SWIG_1(arg1 string, arg2 int) (_swig_ret float64) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_OverBefore_AddedStaticMethod__SWIG_1, _swig_p) + return +} +var _wrap_OverBefore_AddedStaticMethod__SWIG_2 unsafe.Pointer + +func OverBeforeAddedStaticMethod__SWIG_2(arg1 string) (_swig_ret float64) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_OverBefore_AddedStaticMethod__SWIG_2, _swig_p) + return +} +var _wrap_OverBefore_AddedMethod__SWIG_0 unsafe.Pointer + +func _swig_wrap_OverBefore_AddedMethod__SWIG_0(base SwigcptrOverBefore, _ string, _ int, _ float64) (_ float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_OverBefore_AddedMethod__SWIG_0, _swig_p) + return +} + +func (arg1 SwigcptrOverBefore) AddedMethod__SWIG_0(arg2 string, arg3 int, arg4 float64) (_swig_ret float64) { + return _swig_wrap_OverBefore_AddedMethod__SWIG_0(arg1, arg2, arg3, arg4) +} + +var _wrap_OverBefore_AddedMethod__SWIG_1 unsafe.Pointer + +func _swig_wrap_OverBefore_AddedMethod__SWIG_1(base SwigcptrOverBefore, _ string, _ int) (_ float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_OverBefore_AddedMethod__SWIG_1, _swig_p) + return +} + +func (arg1 SwigcptrOverBefore) AddedMethod__SWIG_1(arg2 string, arg3 int) (_swig_ret float64) { + return _swig_wrap_OverBefore_AddedMethod__SWIG_1(arg1, arg2, arg3) +} + +var _wrap_OverBefore_AddedMethod__SWIG_2 unsafe.Pointer + +func _swig_wrap_OverBefore_AddedMethod__SWIG_2(base SwigcptrOverBefore, _ string) (_ float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_OverBefore_AddedMethod__SWIG_2, _swig_p) + return +} + +func (arg1 SwigcptrOverBefore) AddedMethod__SWIG_2(arg2 string) (_swig_ret float64) { + return _swig_wrap_OverBefore_AddedMethod__SWIG_2(arg1, arg2) +} + +var _wrap_OverBefore_d_set unsafe.Pointer + +func _swig_wrap_OverBefore_d_set(base SwigcptrOverBefore, _ float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_OverBefore_d_set, _swig_p) + return +} + +func (arg1 SwigcptrOverBefore) SetD(arg2 float64) { + _swig_wrap_OverBefore_d_set(arg1, arg2) +} + +var _wrap_OverBefore_d_get unsafe.Pointer + +func _swig_wrap_OverBefore_d_get(base SwigcptrOverBefore) (_ float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_OverBefore_d_get, _swig_p) + return +} + +func (arg1 SwigcptrOverBefore) GetD() (_swig_ret float64) { + return _swig_wrap_OverBefore_d_get(arg1) +} + +var _wrap_OverBefore_i_set unsafe.Pointer + +func _swig_wrap_OverBefore_i_set(base SwigcptrOverBefore, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_OverBefore_i_set, _swig_p) + return +} + +func (arg1 SwigcptrOverBefore) SetI(arg2 int) { + _swig_wrap_OverBefore_i_set(arg1, arg2) +} + +var _wrap_OverBefore_i_get unsafe.Pointer + +func _swig_wrap_OverBefore_i_get(base SwigcptrOverBefore) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_OverBefore_i_get, _swig_p) + return +} + +func (arg1 SwigcptrOverBefore) GetI() (_swig_ret int) { + return _swig_wrap_OverBefore_i_get(arg1) +} + +var _wrap_new_OverBefore__SWIG_3 unsafe.Pointer + +func _swig_wrap_new_OverBefore__SWIG_3(base int, _ float64) (_ SwigcptrOverBefore) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_OverBefore__SWIG_3, _swig_p) + return +} + +func NewOverBefore__SWIG_3(arg1 int, arg2 float64) (_swig_ret OverBefore) { + return _swig_wrap_new_OverBefore__SWIG_3(arg1, arg2) +} + +var _wrap_new_OverBefore__SWIG_4 unsafe.Pointer + +func _swig_wrap_new_OverBefore__SWIG_4(base int) (_ SwigcptrOverBefore) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_OverBefore__SWIG_4, _swig_p) + return +} + +func NewOverBefore__SWIG_4(arg1 int) (_swig_ret OverBefore) { + return _swig_wrap_new_OverBefore__SWIG_4(arg1) +} + +var _wrap_new_OverBefore__SWIG_5 unsafe.Pointer + +func _swig_wrap_new_OverBefore__SWIG_5() (base SwigcptrOverBefore) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_OverBefore__SWIG_5, _swig_p) + return +} + +func NewOverBefore__SWIG_5() (_swig_ret OverBefore) { + return _swig_wrap_new_OverBefore__SWIG_5() +} + +func NewOverBefore(a ...interface{}) OverBefore { + argc := len(a) + if argc == 0 { + return NewOverBefore__SWIG_5() + } + if argc == 1 { + if _, ok := a[0].(int); !ok { + goto check_2 + } + return NewOverBefore__SWIG_4(a[0].(int)) + } +check_2: + if argc == 1 { + return NewOverBefore__SWIG_2(a[0].(string)) + } + if argc == 2 { + if _, ok := a[0].(int); !ok { + goto check_4 + } + if _, ok := a[1].(float64); !ok { + goto check_4 + } + return NewOverBefore__SWIG_3(a[0].(int), a[1].(float64)) + } +check_4: + if argc == 2 { + return NewOverBefore__SWIG_1(a[0].(string), a[1].(int)) + } + if argc == 3 { + return NewOverBefore__SWIG_0(a[0].(string), a[1].(int), a[2].(float64)) + } + panic("No match for overloaded function call") +} + +var _wrap_OverBefore_AddedStaticMethod__SWIG_3 unsafe.Pointer + +func OverBeforeAddedStaticMethod__SWIG_3(arg1 int, arg2 float64) (_swig_ret float64) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_OverBefore_AddedStaticMethod__SWIG_3, _swig_p) + return +} +var _wrap_OverBefore_AddedStaticMethod__SWIG_4 unsafe.Pointer + +func OverBeforeAddedStaticMethod__SWIG_4(arg1 int) (_swig_ret float64) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_OverBefore_AddedStaticMethod__SWIG_4, _swig_p) + return +} +var _wrap_OverBefore_AddedStaticMethod__SWIG_5 unsafe.Pointer + +func OverBeforeAddedStaticMethod__SWIG_5() (_swig_ret float64) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_OverBefore_AddedStaticMethod__SWIG_5, _swig_p) + return +} +func OverBeforeAddedStaticMethod(a ...interface{}) float64 { + argc := len(a) + if argc == 0 { + return OverBeforeAddedStaticMethod__SWIG_5() + } + if argc == 1 { + if _, ok := a[0].(int); !ok { + goto check_2 + } + return OverBeforeAddedStaticMethod__SWIG_4(a[0].(int)) + } +check_2: + if argc == 1 { + return OverBeforeAddedStaticMethod__SWIG_2(a[0].(string)) + } + if argc == 2 { + if _, ok := a[0].(int); !ok { + goto check_4 + } + if _, ok := a[1].(float64); !ok { + goto check_4 + } + return OverBeforeAddedStaticMethod__SWIG_3(a[0].(int), a[1].(float64)) + } +check_4: + if argc == 2 { + return OverBeforeAddedStaticMethod__SWIG_1(a[0].(string), a[1].(int)) + } + if argc == 3 { + return OverBeforeAddedStaticMethod__SWIG_0(a[0].(string), a[1].(int), a[2].(float64)) + } + panic("No match for overloaded function call") +} + +var _wrap_OverBefore_AddedMethod__SWIG_3 unsafe.Pointer + +func _swig_wrap_OverBefore_AddedMethod__SWIG_3(base SwigcptrOverBefore, _ int, _ float64) (_ float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_OverBefore_AddedMethod__SWIG_3, _swig_p) + return +} + +func (arg1 SwigcptrOverBefore) AddedMethod__SWIG_3(arg2 int, arg3 float64) (_swig_ret float64) { + return _swig_wrap_OverBefore_AddedMethod__SWIG_3(arg1, arg2, arg3) +} + +var _wrap_OverBefore_AddedMethod__SWIG_4 unsafe.Pointer + +func _swig_wrap_OverBefore_AddedMethod__SWIG_4(base SwigcptrOverBefore, _ int) (_ float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_OverBefore_AddedMethod__SWIG_4, _swig_p) + return +} + +func (arg1 SwigcptrOverBefore) AddedMethod__SWIG_4(arg2 int) (_swig_ret float64) { + return _swig_wrap_OverBefore_AddedMethod__SWIG_4(arg1, arg2) +} + +var _wrap_OverBefore_AddedMethod__SWIG_5 unsafe.Pointer + +func _swig_wrap_OverBefore_AddedMethod__SWIG_5(base SwigcptrOverBefore) (_ float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_OverBefore_AddedMethod__SWIG_5, _swig_p) + return +} + +func (arg1 SwigcptrOverBefore) AddedMethod__SWIG_5() (_swig_ret float64) { + return _swig_wrap_OverBefore_AddedMethod__SWIG_5(arg1) +} + +func (p SwigcptrOverBefore) AddedMethod(a ...interface{}) float64 { + argc := len(a) + if argc == 0 { + return p.AddedMethod__SWIG_5() + } + if argc == 1 { + if _, ok := a[0].(int); !ok { + goto check_2 + } + return p.AddedMethod__SWIG_4(a[0].(int)) + } +check_2: + if argc == 1 { + return p.AddedMethod__SWIG_2(a[0].(string)) + } + if argc == 2 { + if _, ok := a[0].(int); !ok { + goto check_4 + } + if _, ok := a[1].(float64); !ok { + goto check_4 + } + return p.AddedMethod__SWIG_3(a[0].(int), a[1].(float64)) + } +check_4: + if argc == 2 { + return p.AddedMethod__SWIG_1(a[0].(string), a[1].(int)) + } + if argc == 3 { + return p.AddedMethod__SWIG_0(a[0].(string), a[1].(int), a[2].(float64)) + } + panic("No match for overloaded function call") +} + +var _wrap_delete_OverBefore unsafe.Pointer + +func _swig_wrap_delete_OverBefore(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_OverBefore, _swig_p) + return +} + +func DeleteOverBefore(arg1 OverBefore) { + _swig_wrap_delete_OverBefore(arg1.Swigcptr()) +} + +type OverBefore interface { + Swigcptr() uintptr + SwigIsOverBefore() + SetD(arg2 float64) + GetD() (_swig_ret float64) + SetI(arg2 int) + GetI() (_swig_ret int) + AddedMethod(a ...interface{}) float64 +} + +type SwigcptrOverAfter uintptr + +func (p SwigcptrOverAfter) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrOverAfter) SwigIsOverAfter() { +} + +var _wrap_new_OverAfter__SWIG_0 unsafe.Pointer + +func _swig_wrap_new_OverAfter__SWIG_0(base string, _ int, _ float64) (_ SwigcptrOverAfter) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_OverAfter__SWIG_0, _swig_p) + return +} + +func NewOverAfter__SWIG_0(arg1 string, arg2 int, arg3 float64) (_swig_ret OverAfter) { + return _swig_wrap_new_OverAfter__SWIG_0(arg1, arg2, arg3) +} + +var _wrap_new_OverAfter__SWIG_1 unsafe.Pointer + +func _swig_wrap_new_OverAfter__SWIG_1(base string, _ int) (_ SwigcptrOverAfter) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_OverAfter__SWIG_1, _swig_p) + return +} + +func NewOverAfter__SWIG_1(arg1 string, arg2 int) (_swig_ret OverAfter) { + return _swig_wrap_new_OverAfter__SWIG_1(arg1, arg2) +} + +var _wrap_new_OverAfter__SWIG_2 unsafe.Pointer + +func _swig_wrap_new_OverAfter__SWIG_2(base string) (_ SwigcptrOverAfter) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_OverAfter__SWIG_2, _swig_p) + return +} + +func NewOverAfter__SWIG_2(arg1 string) (_swig_ret OverAfter) { + return _swig_wrap_new_OverAfter__SWIG_2(arg1) +} + +var _wrap_OverAfter_AddedStaticMethod__SWIG_0 unsafe.Pointer + +func OverAfterAddedStaticMethod__SWIG_0(arg1 string, arg2 int, arg3 float64) (_swig_ret float64) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_OverAfter_AddedStaticMethod__SWIG_0, _swig_p) + return +} +var _wrap_OverAfter_AddedStaticMethod__SWIG_1 unsafe.Pointer + +func OverAfterAddedStaticMethod__SWIG_1(arg1 string, arg2 int) (_swig_ret float64) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_OverAfter_AddedStaticMethod__SWIG_1, _swig_p) + return +} +var _wrap_OverAfter_AddedStaticMethod__SWIG_2 unsafe.Pointer + +func OverAfterAddedStaticMethod__SWIG_2(arg1 string) (_swig_ret float64) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_OverAfter_AddedStaticMethod__SWIG_2, _swig_p) + return +} +var _wrap_OverAfter_AddedMethod__SWIG_0 unsafe.Pointer + +func _swig_wrap_OverAfter_AddedMethod__SWIG_0(base SwigcptrOverAfter, _ string, _ int, _ float64) (_ float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_OverAfter_AddedMethod__SWIG_0, _swig_p) + return +} + +func (arg1 SwigcptrOverAfter) AddedMethod__SWIG_0(arg2 string, arg3 int, arg4 float64) (_swig_ret float64) { + return _swig_wrap_OverAfter_AddedMethod__SWIG_0(arg1, arg2, arg3, arg4) +} + +var _wrap_OverAfter_AddedMethod__SWIG_1 unsafe.Pointer + +func _swig_wrap_OverAfter_AddedMethod__SWIG_1(base SwigcptrOverAfter, _ string, _ int) (_ float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_OverAfter_AddedMethod__SWIG_1, _swig_p) + return +} + +func (arg1 SwigcptrOverAfter) AddedMethod__SWIG_1(arg2 string, arg3 int) (_swig_ret float64) { + return _swig_wrap_OverAfter_AddedMethod__SWIG_1(arg1, arg2, arg3) +} + +var _wrap_OverAfter_AddedMethod__SWIG_2 unsafe.Pointer + +func _swig_wrap_OverAfter_AddedMethod__SWIG_2(base SwigcptrOverAfter, _ string) (_ float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_OverAfter_AddedMethod__SWIG_2, _swig_p) + return +} + +func (arg1 SwigcptrOverAfter) AddedMethod__SWIG_2(arg2 string) (_swig_ret float64) { + return _swig_wrap_OverAfter_AddedMethod__SWIG_2(arg1, arg2) +} + +var _wrap_OverAfter_d_set unsafe.Pointer + +func _swig_wrap_OverAfter_d_set(base SwigcptrOverAfter, _ float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_OverAfter_d_set, _swig_p) + return +} + +func (arg1 SwigcptrOverAfter) SetD(arg2 float64) { + _swig_wrap_OverAfter_d_set(arg1, arg2) +} + +var _wrap_OverAfter_d_get unsafe.Pointer + +func _swig_wrap_OverAfter_d_get(base SwigcptrOverAfter) (_ float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_OverAfter_d_get, _swig_p) + return +} + +func (arg1 SwigcptrOverAfter) GetD() (_swig_ret float64) { + return _swig_wrap_OverAfter_d_get(arg1) +} + +var _wrap_OverAfter_i_set unsafe.Pointer + +func _swig_wrap_OverAfter_i_set(base SwigcptrOverAfter, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_OverAfter_i_set, _swig_p) + return +} + +func (arg1 SwigcptrOverAfter) SetI(arg2 int) { + _swig_wrap_OverAfter_i_set(arg1, arg2) +} + +var _wrap_OverAfter_i_get unsafe.Pointer + +func _swig_wrap_OverAfter_i_get(base SwigcptrOverAfter) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_OverAfter_i_get, _swig_p) + return +} + +func (arg1 SwigcptrOverAfter) GetI() (_swig_ret int) { + return _swig_wrap_OverAfter_i_get(arg1) +} + +var _wrap_new_OverAfter__SWIG_3 unsafe.Pointer + +func _swig_wrap_new_OverAfter__SWIG_3(base int, _ float64) (_ SwigcptrOverAfter) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_OverAfter__SWIG_3, _swig_p) + return +} + +func NewOverAfter__SWIG_3(arg1 int, arg2 float64) (_swig_ret OverAfter) { + return _swig_wrap_new_OverAfter__SWIG_3(arg1, arg2) +} + +var _wrap_new_OverAfter__SWIG_4 unsafe.Pointer + +func _swig_wrap_new_OverAfter__SWIG_4(base int) (_ SwigcptrOverAfter) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_OverAfter__SWIG_4, _swig_p) + return +} + +func NewOverAfter__SWIG_4(arg1 int) (_swig_ret OverAfter) { + return _swig_wrap_new_OverAfter__SWIG_4(arg1) +} + +var _wrap_new_OverAfter__SWIG_5 unsafe.Pointer + +func _swig_wrap_new_OverAfter__SWIG_5() (base SwigcptrOverAfter) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_OverAfter__SWIG_5, _swig_p) + return +} + +func NewOverAfter__SWIG_5() (_swig_ret OverAfter) { + return _swig_wrap_new_OverAfter__SWIG_5() +} + +func NewOverAfter(a ...interface{}) OverAfter { + argc := len(a) + if argc == 0 { + return NewOverAfter__SWIG_5() + } + if argc == 1 { + if _, ok := a[0].(int); !ok { + goto check_2 + } + return NewOverAfter__SWIG_4(a[0].(int)) + } +check_2: + if argc == 1 { + return NewOverAfter__SWIG_2(a[0].(string)) + } + if argc == 2 { + if _, ok := a[0].(int); !ok { + goto check_4 + } + if _, ok := a[1].(float64); !ok { + goto check_4 + } + return NewOverAfter__SWIG_3(a[0].(int), a[1].(float64)) + } +check_4: + if argc == 2 { + return NewOverAfter__SWIG_1(a[0].(string), a[1].(int)) + } + if argc == 3 { + return NewOverAfter__SWIG_0(a[0].(string), a[1].(int), a[2].(float64)) + } + panic("No match for overloaded function call") +} + +var _wrap_OverAfter_AddedStaticMethod__SWIG_3 unsafe.Pointer + +func OverAfterAddedStaticMethod__SWIG_3(arg1 int, arg2 float64) (_swig_ret float64) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_OverAfter_AddedStaticMethod__SWIG_3, _swig_p) + return +} +var _wrap_OverAfter_AddedStaticMethod__SWIG_4 unsafe.Pointer + +func OverAfterAddedStaticMethod__SWIG_4(arg1 int) (_swig_ret float64) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_OverAfter_AddedStaticMethod__SWIG_4, _swig_p) + return +} +var _wrap_OverAfter_AddedStaticMethod__SWIG_5 unsafe.Pointer + +func OverAfterAddedStaticMethod__SWIG_5() (_swig_ret float64) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_OverAfter_AddedStaticMethod__SWIG_5, _swig_p) + return +} +func OverAfterAddedStaticMethod(a ...interface{}) float64 { + argc := len(a) + if argc == 0 { + return OverAfterAddedStaticMethod__SWIG_5() + } + if argc == 1 { + if _, ok := a[0].(int); !ok { + goto check_2 + } + return OverAfterAddedStaticMethod__SWIG_4(a[0].(int)) + } +check_2: + if argc == 1 { + return OverAfterAddedStaticMethod__SWIG_2(a[0].(string)) + } + if argc == 2 { + if _, ok := a[0].(int); !ok { + goto check_4 + } + if _, ok := a[1].(float64); !ok { + goto check_4 + } + return OverAfterAddedStaticMethod__SWIG_3(a[0].(int), a[1].(float64)) + } +check_4: + if argc == 2 { + return OverAfterAddedStaticMethod__SWIG_1(a[0].(string), a[1].(int)) + } + if argc == 3 { + return OverAfterAddedStaticMethod__SWIG_0(a[0].(string), a[1].(int), a[2].(float64)) + } + panic("No match for overloaded function call") +} + +var _wrap_OverAfter_AddedMethod__SWIG_3 unsafe.Pointer + +func _swig_wrap_OverAfter_AddedMethod__SWIG_3(base SwigcptrOverAfter, _ int, _ float64) (_ float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_OverAfter_AddedMethod__SWIG_3, _swig_p) + return +} + +func (arg1 SwigcptrOverAfter) AddedMethod__SWIG_3(arg2 int, arg3 float64) (_swig_ret float64) { + return _swig_wrap_OverAfter_AddedMethod__SWIG_3(arg1, arg2, arg3) +} + +var _wrap_OverAfter_AddedMethod__SWIG_4 unsafe.Pointer + +func _swig_wrap_OverAfter_AddedMethod__SWIG_4(base SwigcptrOverAfter, _ int) (_ float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_OverAfter_AddedMethod__SWIG_4, _swig_p) + return +} + +func (arg1 SwigcptrOverAfter) AddedMethod__SWIG_4(arg2 int) (_swig_ret float64) { + return _swig_wrap_OverAfter_AddedMethod__SWIG_4(arg1, arg2) +} + +var _wrap_OverAfter_AddedMethod__SWIG_5 unsafe.Pointer + +func _swig_wrap_OverAfter_AddedMethod__SWIG_5(base SwigcptrOverAfter) (_ float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_OverAfter_AddedMethod__SWIG_5, _swig_p) + return +} + +func (arg1 SwigcptrOverAfter) AddedMethod__SWIG_5() (_swig_ret float64) { + return _swig_wrap_OverAfter_AddedMethod__SWIG_5(arg1) +} + +func (p SwigcptrOverAfter) AddedMethod(a ...interface{}) float64 { + argc := len(a) + if argc == 0 { + return p.AddedMethod__SWIG_5() + } + if argc == 1 { + if _, ok := a[0].(int); !ok { + goto check_2 + } + return p.AddedMethod__SWIG_4(a[0].(int)) + } +check_2: + if argc == 1 { + return p.AddedMethod__SWIG_2(a[0].(string)) + } + if argc == 2 { + if _, ok := a[0].(int); !ok { + goto check_4 + } + if _, ok := a[1].(float64); !ok { + goto check_4 + } + return p.AddedMethod__SWIG_3(a[0].(int), a[1].(float64)) + } +check_4: + if argc == 2 { + return p.AddedMethod__SWIG_1(a[0].(string), a[1].(int)) + } + if argc == 3 { + return p.AddedMethod__SWIG_0(a[0].(string), a[1].(int), a[2].(float64)) + } + panic("No match for overloaded function call") +} + +var _wrap_delete_OverAfter unsafe.Pointer + +func _swig_wrap_delete_OverAfter(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_OverAfter, _swig_p) + return +} + +func DeleteOverAfter(arg1 OverAfter) { + _swig_wrap_delete_OverAfter(arg1.Swigcptr()) +} + +type OverAfter interface { + Swigcptr() uintptr + SwigIsOverAfter() + SetD(arg2 float64) + GetD() (_swig_ret float64) + SetI(arg2 int) + GetI() (_swig_ret int) + AddedMethod(a ...interface{}) float64 +} + +type SwigcptrOverride uintptr + +func (p SwigcptrOverride) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrOverride) SwigIsOverride() { +} + +var _wrap_Override_over__SWIG_0 unsafe.Pointer + +func _swig_wrap_Override_over__SWIG_0(base SwigcptrOverride) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Override_over__SWIG_0, _swig_p) + return +} + +func (arg1 SwigcptrOverride) Over__SWIG_0() (_swig_ret int) { + return _swig_wrap_Override_over__SWIG_0(arg1) +} + +var _wrap_Override_ride__SWIG_0 unsafe.Pointer + +func _swig_wrap_Override_ride__SWIG_0(base SwigcptrOverride, _ int) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Override_ride__SWIG_0, _swig_p) + return +} + +func (arg1 SwigcptrOverride) Ride__SWIG_0(arg2 int) (_swig_ret int) { + return _swig_wrap_Override_ride__SWIG_0(arg1, arg2) +} + +var _wrap_Override_ride__SWIG_1 unsafe.Pointer + +func _swig_wrap_Override_ride__SWIG_1(base SwigcptrOverride) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Override_ride__SWIG_1, _swig_p) + return +} + +func (arg1 SwigcptrOverride) Ride__SWIG_1() (_swig_ret int) { + return _swig_wrap_Override_ride__SWIG_1(arg1) +} + +func (p SwigcptrOverride) Ride(a ...interface{}) int { + argc := len(a) + if argc == 0 { + return p.Ride__SWIG_1() + } + if argc == 1 { + return p.Ride__SWIG_0(a[0].(int)) + } + panic("No match for overloaded function call") +} + +var _wrap_Override_overload__SWIG_0 unsafe.Pointer + +func _swig_wrap_Override_overload__SWIG_0(base SwigcptrOverride) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Override_overload__SWIG_0, _swig_p) + return +} + +func (arg1 SwigcptrOverride) Overload__SWIG_0() (_swig_ret int) { + return _swig_wrap_Override_overload__SWIG_0(arg1) +} + +var _wrap_Override_over__SWIG_1 unsafe.Pointer + +func _swig_wrap_Override_over__SWIG_1(base SwigcptrOverride, _ int) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Override_over__SWIG_1, _swig_p) + return +} + +func (arg1 SwigcptrOverride) Over__SWIG_1(arg2 int) (_swig_ret int) { + return _swig_wrap_Override_over__SWIG_1(arg1, arg2) +} + +func (p SwigcptrOverride) Over(a ...interface{}) int { + argc := len(a) + if argc == 0 { + return p.Over__SWIG_0() + } + if argc == 1 { + return p.Over__SWIG_1(a[0].(int)) + } + panic("No match for overloaded function call") +} + +var _wrap_Override_overload__SWIG_1 unsafe.Pointer + +func _swig_wrap_Override_overload__SWIG_1(base SwigcptrOverride, _ int) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Override_overload__SWIG_1, _swig_p) + return +} + +func (arg1 SwigcptrOverride) Overload__SWIG_1(arg2 int) (_swig_ret int) { + return _swig_wrap_Override_overload__SWIG_1(arg1, arg2) +} + +func (p SwigcptrOverride) Overload(a ...interface{}) int { + argc := len(a) + if argc == 0 { + return p.Overload__SWIG_0() + } + if argc == 1 { + return p.Overload__SWIG_1(a[0].(int)) + } + panic("No match for overloaded function call") +} + +var _wrap_new_Override unsafe.Pointer + +func _swig_wrap_new_Override() (base SwigcptrOverride) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Override, _swig_p) + return +} + +func NewOverride() (_swig_ret Override) { + return _swig_wrap_new_Override() +} + +var _wrap_delete_Override unsafe.Pointer + +func _swig_wrap_delete_Override(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Override, _swig_p) + return +} + +func DeleteOverride(arg1 Override) { + _swig_wrap_delete_Override(arg1.Swigcptr()) +} + +type Override interface { + Swigcptr() uintptr + SwigIsOverride() + Ride(a ...interface{}) int + Over(a ...interface{}) int + Overload(a ...interface{}) int +} + +type SwigcptrBase uintptr + +func (p SwigcptrBase) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrBase) SwigIsBase() { +} + +var _wrap_delete_Base unsafe.Pointer + +func _swig_wrap_delete_Base(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Base, _swig_p) + return +} + +func DeleteBase(arg1 Base) { + _swig_wrap_delete_Base(arg1.Swigcptr()) +} + +var _wrap_Base_realvirtual__SWIG_0 unsafe.Pointer + +func _swig_wrap_Base_realvirtual__SWIG_0(base SwigcptrBase, _ int) (_ *int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Base_realvirtual__SWIG_0, _swig_p) + return +} + +func (arg1 SwigcptrBase) Realvirtual__SWIG_0(arg2 int) (_swig_ret *int) { + return _swig_wrap_Base_realvirtual__SWIG_0(arg1, arg2) +} + +var _wrap_Base_realvirtual__SWIG_1 unsafe.Pointer + +func _swig_wrap_Base_realvirtual__SWIG_1(base SwigcptrBase) (_ *int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Base_realvirtual__SWIG_1, _swig_p) + return +} + +func (arg1 SwigcptrBase) Realvirtual__SWIG_1() (_swig_ret *int) { + return _swig_wrap_Base_realvirtual__SWIG_1(arg1) +} + +func (p SwigcptrBase) Realvirtual(a ...interface{}) *int { + argc := len(a) + if argc == 0 { + return p.Realvirtual__SWIG_1() + } + if argc == 1 { + return p.Realvirtual__SWIG_0(a[0].(int)) + } + panic("No match for overloaded function call") +} + +var _wrap_Base_virtualmethod__SWIG_0 unsafe.Pointer + +func _swig_wrap_Base_virtualmethod__SWIG_0(base SwigcptrBase, _ int) (_ *int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Base_virtualmethod__SWIG_0, _swig_p) + return +} + +func (arg1 SwigcptrBase) Virtualmethod__SWIG_0(arg2 int) (_swig_ret *int) { + return _swig_wrap_Base_virtualmethod__SWIG_0(arg1, arg2) +} + +var _wrap_Base_virtualmethod__SWIG_1 unsafe.Pointer + +func _swig_wrap_Base_virtualmethod__SWIG_1(base SwigcptrBase) (_ *int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Base_virtualmethod__SWIG_1, _swig_p) + return +} + +func (arg1 SwigcptrBase) Virtualmethod__SWIG_1() (_swig_ret *int) { + return _swig_wrap_Base_virtualmethod__SWIG_1(arg1) +} + +func (p SwigcptrBase) Virtualmethod(a ...interface{}) *int { + argc := len(a) + if argc == 0 { + return p.Virtualmethod__SWIG_1() + } + if argc == 1 { + return p.Virtualmethod__SWIG_0(a[0].(int)) + } + panic("No match for overloaded function call") +} + +var _wrap_Base_nonvirtual__SWIG_0 unsafe.Pointer + +func _swig_wrap_Base_nonvirtual__SWIG_0(base SwigcptrBase, _ int) (_ *int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Base_nonvirtual__SWIG_0, _swig_p) + return +} + +func (arg1 SwigcptrBase) Nonvirtual__SWIG_0(arg2 int) (_swig_ret *int) { + return _swig_wrap_Base_nonvirtual__SWIG_0(arg1, arg2) +} + +var _wrap_Base_nonvirtual__SWIG_1 unsafe.Pointer + +func _swig_wrap_Base_nonvirtual__SWIG_1(base SwigcptrBase) (_ *int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Base_nonvirtual__SWIG_1, _swig_p) + return +} + +func (arg1 SwigcptrBase) Nonvirtual__SWIG_1() (_swig_ret *int) { + return _swig_wrap_Base_nonvirtual__SWIG_1(arg1) +} + +func (p SwigcptrBase) Nonvirtual(a ...interface{}) *int { + argc := len(a) + if argc == 0 { + return p.Nonvirtual__SWIG_1() + } + if argc == 1 { + return p.Nonvirtual__SWIG_0(a[0].(int)) + } + panic("No match for overloaded function call") +} + +var _wrap_Base_static_method__SWIG_0 unsafe.Pointer + +func BaseStatic_method__SWIG_0(arg1 int) (_swig_ret *int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_Base_static_method__SWIG_0, _swig_p) + return +} +var _wrap_Base_static_method__SWIG_1 unsafe.Pointer + +func BaseStatic_method__SWIG_1() (_swig_ret *int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_Base_static_method__SWIG_1, _swig_p) + return +} +func BaseStatic_method(a ...interface{}) *int { + argc := len(a) + if argc == 0 { + return BaseStatic_method__SWIG_1() + } + if argc == 1 { + return BaseStatic_method__SWIG_0(a[0].(int)) + } + panic("No match for overloaded function call") +} + +var _wrap_new_Base unsafe.Pointer + +func _swig_wrap_new_Base() (base SwigcptrBase) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Base, _swig_p) + return +} + +func NewBase() (_swig_ret Base) { + return _swig_wrap_new_Base() +} + +type Base interface { + Swigcptr() uintptr + SwigIsBase() + Realvirtual(a ...interface{}) *int + Virtualmethod(a ...interface{}) *int + Nonvirtual(a ...interface{}) *int +} + +type SwigcptrDerived uintptr + +func (p SwigcptrDerived) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrDerived) SwigIsDerived() { +} + +var _wrap_Derived_virtualmethod__SWIG_0 unsafe.Pointer + +func _swig_wrap_Derived_virtualmethod__SWIG_0(base SwigcptrDerived, _ int) (_ *int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Derived_virtualmethod__SWIG_0, _swig_p) + return +} + +func (arg1 SwigcptrDerived) Virtualmethod__SWIG_0(arg2 int) (_swig_ret *int) { + return _swig_wrap_Derived_virtualmethod__SWIG_0(arg1, arg2) +} + +var _wrap_Derived_virtualmethod__SWIG_1 unsafe.Pointer + +func _swig_wrap_Derived_virtualmethod__SWIG_1(base SwigcptrDerived) (_ *int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Derived_virtualmethod__SWIG_1, _swig_p) + return +} + +func (arg1 SwigcptrDerived) Virtualmethod__SWIG_1() (_swig_ret *int) { + return _swig_wrap_Derived_virtualmethod__SWIG_1(arg1) +} + +func (p SwigcptrDerived) Virtualmethod(a ...interface{}) *int { + argc := len(a) + if argc == 0 { + return p.Virtualmethod__SWIG_1() + } + if argc == 1 { + return p.Virtualmethod__SWIG_0(a[0].(int)) + } + panic("No match for overloaded function call") +} + +var _wrap_Derived_nonvirtual__SWIG_0 unsafe.Pointer + +func _swig_wrap_Derived_nonvirtual__SWIG_0(base SwigcptrDerived, _ int) (_ *int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Derived_nonvirtual__SWIG_0, _swig_p) + return +} + +func (arg1 SwigcptrDerived) Nonvirtual__SWIG_0(arg2 int) (_swig_ret *int) { + return _swig_wrap_Derived_nonvirtual__SWIG_0(arg1, arg2) +} + +var _wrap_Derived_nonvirtual__SWIG_1 unsafe.Pointer + +func _swig_wrap_Derived_nonvirtual__SWIG_1(base SwigcptrDerived) (_ *int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Derived_nonvirtual__SWIG_1, _swig_p) + return +} + +func (arg1 SwigcptrDerived) Nonvirtual__SWIG_1() (_swig_ret *int) { + return _swig_wrap_Derived_nonvirtual__SWIG_1(arg1) +} + +func (p SwigcptrDerived) Nonvirtual(a ...interface{}) *int { + argc := len(a) + if argc == 0 { + return p.Nonvirtual__SWIG_1() + } + if argc == 1 { + return p.Nonvirtual__SWIG_0(a[0].(int)) + } + panic("No match for overloaded function call") +} + +var _wrap_Derived_static_method__SWIG_0 unsafe.Pointer + +func DerivedStatic_method__SWIG_0(arg1 int) (_swig_ret *int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_Derived_static_method__SWIG_0, _swig_p) + return +} +var _wrap_Derived_static_method__SWIG_1 unsafe.Pointer + +func DerivedStatic_method__SWIG_1() (_swig_ret *int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_Derived_static_method__SWIG_1, _swig_p) + return +} +func DerivedStatic_method(a ...interface{}) *int { + argc := len(a) + if argc == 0 { + return DerivedStatic_method__SWIG_1() + } + if argc == 1 { + return DerivedStatic_method__SWIG_0(a[0].(int)) + } + panic("No match for overloaded function call") +} + +var _wrap_Derived_realvirtual__SWIG_0 unsafe.Pointer + +func _swig_wrap_Derived_realvirtual__SWIG_0(base SwigcptrDerived, _ int) (_ *int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Derived_realvirtual__SWIG_0, _swig_p) + return +} + +func (arg1 SwigcptrDerived) Realvirtual__SWIG_0(arg2 int) (_swig_ret *int) { + return _swig_wrap_Derived_realvirtual__SWIG_0(arg1, arg2) +} + +var _wrap_Derived_realvirtual__SWIG_1 unsafe.Pointer + +func _swig_wrap_Derived_realvirtual__SWIG_1(base SwigcptrDerived) (_ *int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Derived_realvirtual__SWIG_1, _swig_p) + return +} + +func (arg1 SwigcptrDerived) Realvirtual__SWIG_1() (_swig_ret *int) { + return _swig_wrap_Derived_realvirtual__SWIG_1(arg1) +} + +func (p SwigcptrDerived) Realvirtual(a ...interface{}) *int { + argc := len(a) + if argc == 0 { + return p.Realvirtual__SWIG_1() + } + if argc == 1 { + return p.Realvirtual__SWIG_0(a[0].(int)) + } + panic("No match for overloaded function call") +} + +var _wrap_new_Derived unsafe.Pointer + +func _swig_wrap_new_Derived() (base SwigcptrDerived) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Derived, _swig_p) + return +} + +func NewDerived() (_swig_ret Derived) { + return _swig_wrap_new_Derived() +} + +var _wrap_delete_Derived unsafe.Pointer + +func _swig_wrap_delete_Derived(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Derived, _swig_p) + return +} + +func DeleteDerived(arg1 Derived) { + _swig_wrap_delete_Derived(arg1.Swigcptr()) +} + +func (p SwigcptrDerived) SwigIsBase() { +} + +func (p SwigcptrDerived) SwigGetBase() Base { + return SwigcptrBase(p.Swigcptr()) +} + +type Derived interface { + Swigcptr() uintptr + SwigIsDerived() + Virtualmethod(a ...interface{}) *int + Nonvirtual(a ...interface{}) *int + Realvirtual(a ...interface{}) *int + SwigIsBase() + SwigGetBase() Base +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/extend_placement.go b/Examples/test-suite/go/extend_placement.go new file mode 100644 index 000000000..94ef42a59 --- /dev/null +++ b/Examples/test-suite/go/extend_placement.go @@ -0,0 +1,815 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../extend_placement.i + +package extend_placement + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrFoo uintptr + +func (p SwigcptrFoo) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrFoo) SwigIsFoo() { +} + +var _wrap_new_Foo__SWIG_0 unsafe.Pointer + +func _swig_wrap_new_Foo__SWIG_0() (base SwigcptrFoo) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Foo__SWIG_0, _swig_p) + return +} + +func NewFoo__SWIG_0() (_swig_ret Foo) { + return _swig_wrap_new_Foo__SWIG_0() +} + +var _wrap_new_Foo__SWIG_1 unsafe.Pointer + +func _swig_wrap_new_Foo__SWIG_1(base int, _ int) (_ SwigcptrFoo) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Foo__SWIG_1, _swig_p) + return +} + +func NewFoo__SWIG_1(arg1 int, arg2 int) (_swig_ret Foo) { + return _swig_wrap_new_Foo__SWIG_1(arg1, arg2) +} + +var _wrap_Foo_spam__SWIG_0 unsafe.Pointer + +func _swig_wrap_Foo_spam__SWIG_0(base SwigcptrFoo) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_spam__SWIG_0, _swig_p) + return +} + +func (arg1 SwigcptrFoo) Spam__SWIG_0() (_swig_ret int) { + return _swig_wrap_Foo_spam__SWIG_0(arg1) +} + +var _wrap_Foo_spam__SWIG_1 unsafe.Pointer + +func _swig_wrap_Foo_spam__SWIG_1(base SwigcptrFoo, _ string) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_spam__SWIG_1, _swig_p) + return +} + +func (arg1 SwigcptrFoo) Spam__SWIG_1(arg2 string) (_swig_ret int) { + return _swig_wrap_Foo_spam__SWIG_1(arg1, arg2) +} + +var _wrap_new_Foo__SWIG_2 unsafe.Pointer + +func _swig_wrap_new_Foo__SWIG_2(base int) (_ SwigcptrFoo) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Foo__SWIG_2, _swig_p) + return +} + +func NewFoo__SWIG_2(arg1 int) (_swig_ret Foo) { + return _swig_wrap_new_Foo__SWIG_2(arg1) +} + +func NewFoo(a ...interface{}) Foo { + argc := len(a) + if argc == 0 { + return NewFoo__SWIG_0() + } + if argc == 1 { + return NewFoo__SWIG_2(a[0].(int)) + } + if argc == 2 { + return NewFoo__SWIG_1(a[0].(int), a[1].(int)) + } + panic("No match for overloaded function call") +} + +var _wrap_delete_Foo unsafe.Pointer + +func _swig_wrap_delete_Foo(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Foo, _swig_p) + return +} + +func DeleteFoo(arg1 Foo) { + _swig_wrap_delete_Foo(arg1.Swigcptr()) +} + +var _wrap_Foo_spam__SWIG_2 unsafe.Pointer + +func _swig_wrap_Foo_spam__SWIG_2(base SwigcptrFoo, _ int) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_spam__SWIG_2, _swig_p) + return +} + +func (arg1 SwigcptrFoo) Spam__SWIG_2(arg2 int) (_swig_ret int) { + return _swig_wrap_Foo_spam__SWIG_2(arg1, arg2) +} + +var _wrap_Foo_spam__SWIG_3 unsafe.Pointer + +func _swig_wrap_Foo_spam__SWIG_3(base SwigcptrFoo, _ int, _ int) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_spam__SWIG_3, _swig_p) + return +} + +func (arg1 SwigcptrFoo) Spam__SWIG_3(arg2 int, arg3 int) (_swig_ret int) { + return _swig_wrap_Foo_spam__SWIG_3(arg1, arg2, arg3) +} + +var _wrap_Foo_spam__SWIG_4 unsafe.Pointer + +func _swig_wrap_Foo_spam__SWIG_4(base SwigcptrFoo, _ int, _ int, _ int) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_spam__SWIG_4, _swig_p) + return +} + +func (arg1 SwigcptrFoo) Spam__SWIG_4(arg2 int, arg3 int, arg4 int) (_swig_ret int) { + return _swig_wrap_Foo_spam__SWIG_4(arg1, arg2, arg3, arg4) +} + +var _wrap_Foo_spam__SWIG_5 unsafe.Pointer + +func _swig_wrap_Foo_spam__SWIG_5(base SwigcptrFoo, _ uintptr, _ float64) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_spam__SWIG_5, _swig_p) + return +} + +func (arg1 SwigcptrFoo) Spam__SWIG_5(arg2 Foo, arg3 float64) (_swig_ret int) { + return _swig_wrap_Foo_spam__SWIG_5(arg1, arg2.Swigcptr(), arg3) +} + +var _wrap_Foo_spam__SWIG_6 unsafe.Pointer + +func _swig_wrap_Foo_spam__SWIG_6(base SwigcptrFoo, _ uintptr) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_spam__SWIG_6, _swig_p) + return +} + +func (arg1 SwigcptrFoo) Spam__SWIG_6(arg2 Foo) (_swig_ret int) { + return _swig_wrap_Foo_spam__SWIG_6(arg1, arg2.Swigcptr()) +} + +func (p SwigcptrFoo) Spam(a ...interface{}) int { + argc := len(a) + if argc == 0 { + return p.Spam__SWIG_0() + } + if argc == 1 { + if _, ok := a[0].(Foo); !ok { + goto check_2 + } + return p.Spam__SWIG_6(a[0].(Foo)) + } +check_2: + if argc == 1 { + if _, ok := a[0].(int); !ok { + goto check_3 + } + return p.Spam__SWIG_2(a[0].(int)) + } +check_3: + if argc == 1 { + return p.Spam__SWIG_1(a[0].(string)) + } + if argc == 2 { + if _, ok := a[0].(Foo); !ok { + goto check_5 + } + if _, ok := a[1].(float64); !ok { + goto check_5 + } + return p.Spam__SWIG_5(a[0].(Foo), a[1].(float64)) + } +check_5: + if argc == 2 { + return p.Spam__SWIG_3(a[0].(int), a[1].(int)) + } + if argc == 3 { + return p.Spam__SWIG_4(a[0].(int), a[1].(int), a[2].(int)) + } + panic("No match for overloaded function call") +} + +type Foo interface { + Swigcptr() uintptr + SwigIsFoo() + Spam(a ...interface{}) int +} + +type SwigcptrBar uintptr + +func (p SwigcptrBar) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrBar) SwigIsBar() { +} + +var _wrap_new_Bar__SWIG_0 unsafe.Pointer + +func _swig_wrap_new_Bar__SWIG_0() (base SwigcptrBar) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Bar__SWIG_0, _swig_p) + return +} + +func NewBar__SWIG_0() (_swig_ret Bar) { + return _swig_wrap_new_Bar__SWIG_0() +} + +var _wrap_Bar_spam__SWIG_0 unsafe.Pointer + +func _swig_wrap_Bar_spam__SWIG_0(base SwigcptrBar) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Bar_spam__SWIG_0, _swig_p) + return +} + +func (arg1 SwigcptrBar) Spam__SWIG_0() (_swig_ret int) { + return _swig_wrap_Bar_spam__SWIG_0(arg1) +} + +var _wrap_Bar_spam__SWIG_1 unsafe.Pointer + +func _swig_wrap_Bar_spam__SWIG_1(base SwigcptrBar, _ string) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Bar_spam__SWIG_1, _swig_p) + return +} + +func (arg1 SwigcptrBar) Spam__SWIG_1(arg2 string) (_swig_ret int) { + return _swig_wrap_Bar_spam__SWIG_1(arg1, arg2) +} + +var _wrap_new_Bar__SWIG_1 unsafe.Pointer + +func _swig_wrap_new_Bar__SWIG_1(base int) (_ SwigcptrBar) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Bar__SWIG_1, _swig_p) + return +} + +func NewBar__SWIG_1(arg1 int) (_swig_ret Bar) { + return _swig_wrap_new_Bar__SWIG_1(arg1) +} + +func NewBar(a ...interface{}) Bar { + argc := len(a) + if argc == 0 { + return NewBar__SWIG_0() + } + if argc == 1 { + return NewBar__SWIG_1(a[0].(int)) + } + panic("No match for overloaded function call") +} + +var _wrap_delete_Bar unsafe.Pointer + +func _swig_wrap_delete_Bar(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Bar, _swig_p) + return +} + +func DeleteBar(arg1 Bar) { + _swig_wrap_delete_Bar(arg1.Swigcptr()) +} + +var _wrap_Bar_spam__SWIG_2 unsafe.Pointer + +func _swig_wrap_Bar_spam__SWIG_2(base SwigcptrBar, _ int) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Bar_spam__SWIG_2, _swig_p) + return +} + +func (arg1 SwigcptrBar) Spam__SWIG_2(arg2 int) (_swig_ret int) { + return _swig_wrap_Bar_spam__SWIG_2(arg1, arg2) +} + +var _wrap_Bar_spam__SWIG_3 unsafe.Pointer + +func _swig_wrap_Bar_spam__SWIG_3(base SwigcptrBar, _ int, _ int) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Bar_spam__SWIG_3, _swig_p) + return +} + +func (arg1 SwigcptrBar) Spam__SWIG_3(arg2 int, arg3 int) (_swig_ret int) { + return _swig_wrap_Bar_spam__SWIG_3(arg1, arg2, arg3) +} + +var _wrap_Bar_spam__SWIG_4 unsafe.Pointer + +func _swig_wrap_Bar_spam__SWIG_4(base SwigcptrBar, _ int, _ int, _ int) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Bar_spam__SWIG_4, _swig_p) + return +} + +func (arg1 SwigcptrBar) Spam__SWIG_4(arg2 int, arg3 int, arg4 int) (_swig_ret int) { + return _swig_wrap_Bar_spam__SWIG_4(arg1, arg2, arg3, arg4) +} + +var _wrap_Bar_spam__SWIG_5 unsafe.Pointer + +func _swig_wrap_Bar_spam__SWIG_5(base SwigcptrBar, _ uintptr, _ float64) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Bar_spam__SWIG_5, _swig_p) + return +} + +func (arg1 SwigcptrBar) Spam__SWIG_5(arg2 Bar, arg3 float64) (_swig_ret int) { + return _swig_wrap_Bar_spam__SWIG_5(arg1, arg2.Swigcptr(), arg3) +} + +var _wrap_Bar_spam__SWIG_6 unsafe.Pointer + +func _swig_wrap_Bar_spam__SWIG_6(base SwigcptrBar, _ uintptr) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Bar_spam__SWIG_6, _swig_p) + return +} + +func (arg1 SwigcptrBar) Spam__SWIG_6(arg2 Bar) (_swig_ret int) { + return _swig_wrap_Bar_spam__SWIG_6(arg1, arg2.Swigcptr()) +} + +func (p SwigcptrBar) Spam(a ...interface{}) int { + argc := len(a) + if argc == 0 { + return p.Spam__SWIG_0() + } + if argc == 1 { + if _, ok := a[0].(Bar); !ok { + goto check_2 + } + return p.Spam__SWIG_6(a[0].(Bar)) + } +check_2: + if argc == 1 { + if _, ok := a[0].(int); !ok { + goto check_3 + } + return p.Spam__SWIG_2(a[0].(int)) + } +check_3: + if argc == 1 { + return p.Spam__SWIG_1(a[0].(string)) + } + if argc == 2 { + if _, ok := a[0].(Bar); !ok { + goto check_5 + } + if _, ok := a[1].(float64); !ok { + goto check_5 + } + return p.Spam__SWIG_5(a[0].(Bar), a[1].(float64)) + } +check_5: + if argc == 2 { + return p.Spam__SWIG_3(a[0].(int), a[1].(int)) + } + if argc == 3 { + return p.Spam__SWIG_4(a[0].(int), a[1].(int), a[2].(int)) + } + panic("No match for overloaded function call") +} + +type Bar interface { + Swigcptr() uintptr + SwigIsBar() + Spam(a ...interface{}) int +} + +type SwigcptrFooTi uintptr + +func (p SwigcptrFooTi) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrFooTi) SwigIsFooTi() { +} + +var _wrap_new_FooTi__SWIG_0 unsafe.Pointer + +func _swig_wrap_new_FooTi__SWIG_0() (base SwigcptrFooTi) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_FooTi__SWIG_0, _swig_p) + return +} + +func NewFooTi__SWIG_0() (_swig_ret FooTi) { + return _swig_wrap_new_FooTi__SWIG_0() +} + +var _wrap_new_FooTi__SWIG_1 unsafe.Pointer + +func _swig_wrap_new_FooTi__SWIG_1(base int, _ int) (_ SwigcptrFooTi) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_FooTi__SWIG_1, _swig_p) + return +} + +func NewFooTi__SWIG_1(arg1 int, arg2 int) (_swig_ret FooTi) { + return _swig_wrap_new_FooTi__SWIG_1(arg1, arg2) +} + +var _wrap_FooTi_spam__SWIG_0 unsafe.Pointer + +func _swig_wrap_FooTi_spam__SWIG_0(base SwigcptrFooTi) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_FooTi_spam__SWIG_0, _swig_p) + return +} + +func (arg1 SwigcptrFooTi) Spam__SWIG_0() (_swig_ret int) { + return _swig_wrap_FooTi_spam__SWIG_0(arg1) +} + +var _wrap_FooTi_spam__SWIG_1 unsafe.Pointer + +func _swig_wrap_FooTi_spam__SWIG_1(base SwigcptrFooTi, _ string) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_FooTi_spam__SWIG_1, _swig_p) + return +} + +func (arg1 SwigcptrFooTi) Spam__SWIG_1(arg2 string) (_swig_ret int) { + return _swig_wrap_FooTi_spam__SWIG_1(arg1, arg2) +} + +var _wrap_new_FooTi__SWIG_2 unsafe.Pointer + +func _swig_wrap_new_FooTi__SWIG_2(base int) (_ SwigcptrFooTi) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_FooTi__SWIG_2, _swig_p) + return +} + +func NewFooTi__SWIG_2(arg1 int) (_swig_ret FooTi) { + return _swig_wrap_new_FooTi__SWIG_2(arg1) +} + +func NewFooTi(a ...interface{}) FooTi { + argc := len(a) + if argc == 0 { + return NewFooTi__SWIG_0() + } + if argc == 1 { + return NewFooTi__SWIG_2(a[0].(int)) + } + if argc == 2 { + return NewFooTi__SWIG_1(a[0].(int), a[1].(int)) + } + panic("No match for overloaded function call") +} + +var _wrap_delete_FooTi unsafe.Pointer + +func _swig_wrap_delete_FooTi(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_FooTi, _swig_p) + return +} + +func DeleteFooTi(arg1 FooTi) { + _swig_wrap_delete_FooTi(arg1.Swigcptr()) +} + +var _wrap_FooTi_spam__SWIG_2 unsafe.Pointer + +func _swig_wrap_FooTi_spam__SWIG_2(base SwigcptrFooTi, _ int) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_FooTi_spam__SWIG_2, _swig_p) + return +} + +func (arg1 SwigcptrFooTi) Spam__SWIG_2(arg2 int) (_swig_ret int) { + return _swig_wrap_FooTi_spam__SWIG_2(arg1, arg2) +} + +var _wrap_FooTi_spam__SWIG_3 unsafe.Pointer + +func _swig_wrap_FooTi_spam__SWIG_3(base SwigcptrFooTi, _ int, _ int) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_FooTi_spam__SWIG_3, _swig_p) + return +} + +func (arg1 SwigcptrFooTi) Spam__SWIG_3(arg2 int, arg3 int) (_swig_ret int) { + return _swig_wrap_FooTi_spam__SWIG_3(arg1, arg2, arg3) +} + +var _wrap_FooTi_spam__SWIG_4 unsafe.Pointer + +func _swig_wrap_FooTi_spam__SWIG_4(base SwigcptrFooTi, _ int, _ int, _ int) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_FooTi_spam__SWIG_4, _swig_p) + return +} + +func (arg1 SwigcptrFooTi) Spam__SWIG_4(arg2 int, arg3 int, arg4 int) (_swig_ret int) { + return _swig_wrap_FooTi_spam__SWIG_4(arg1, arg2, arg3, arg4) +} + +var _wrap_FooTi_spam__SWIG_5 unsafe.Pointer + +func _swig_wrap_FooTi_spam__SWIG_5(base SwigcptrFooTi, _ uintptr, _ float64) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_FooTi_spam__SWIG_5, _swig_p) + return +} + +func (arg1 SwigcptrFooTi) Spam__SWIG_5(arg2 Foo, arg3 float64) (_swig_ret int) { + return _swig_wrap_FooTi_spam__SWIG_5(arg1, arg2.Swigcptr(), arg3) +} + +var _wrap_FooTi_spam__SWIG_6 unsafe.Pointer + +func _swig_wrap_FooTi_spam__SWIG_6(base SwigcptrFooTi, _ uintptr) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_FooTi_spam__SWIG_6, _swig_p) + return +} + +func (arg1 SwigcptrFooTi) Spam__SWIG_6(arg2 Foo) (_swig_ret int) { + return _swig_wrap_FooTi_spam__SWIG_6(arg1, arg2.Swigcptr()) +} + +func (p SwigcptrFooTi) Spam(a ...interface{}) int { + argc := len(a) + if argc == 0 { + return p.Spam__SWIG_0() + } + if argc == 1 { + if _, ok := a[0].(Foo); !ok { + goto check_2 + } + return p.Spam__SWIG_6(a[0].(Foo)) + } +check_2: + if argc == 1 { + if _, ok := a[0].(int); !ok { + goto check_3 + } + return p.Spam__SWIG_2(a[0].(int)) + } +check_3: + if argc == 1 { + return p.Spam__SWIG_1(a[0].(string)) + } + if argc == 2 { + if _, ok := a[0].(Foo); !ok { + goto check_5 + } + if _, ok := a[1].(float64); !ok { + goto check_5 + } + return p.Spam__SWIG_5(a[0].(Foo), a[1].(float64)) + } +check_5: + if argc == 2 { + return p.Spam__SWIG_3(a[0].(int), a[1].(int)) + } + if argc == 3 { + return p.Spam__SWIG_4(a[0].(int), a[1].(int), a[2].(int)) + } + panic("No match for overloaded function call") +} + +type FooTi interface { + Swigcptr() uintptr + SwigIsFooTi() + Spam(a ...interface{}) int +} + +type SwigcptrBarTi uintptr + +func (p SwigcptrBarTi) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrBarTi) SwigIsBarTi() { +} + +var _wrap_new_BarTi__SWIG_0 unsafe.Pointer + +func _swig_wrap_new_BarTi__SWIG_0() (base SwigcptrBarTi) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_BarTi__SWIG_0, _swig_p) + return +} + +func NewBarTi__SWIG_0() (_swig_ret BarTi) { + return _swig_wrap_new_BarTi__SWIG_0() +} + +var _wrap_BarTi_spam__SWIG_0 unsafe.Pointer + +func _swig_wrap_BarTi_spam__SWIG_0(base SwigcptrBarTi) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_BarTi_spam__SWIG_0, _swig_p) + return +} + +func (arg1 SwigcptrBarTi) Spam__SWIG_0() (_swig_ret int) { + return _swig_wrap_BarTi_spam__SWIG_0(arg1) +} + +var _wrap_BarTi_spam__SWIG_1 unsafe.Pointer + +func _swig_wrap_BarTi_spam__SWIG_1(base SwigcptrBarTi, _ string) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_BarTi_spam__SWIG_1, _swig_p) + return +} + +func (arg1 SwigcptrBarTi) Spam__SWIG_1(arg2 string) (_swig_ret int) { + return _swig_wrap_BarTi_spam__SWIG_1(arg1, arg2) +} + +var _wrap_new_BarTi__SWIG_1 unsafe.Pointer + +func _swig_wrap_new_BarTi__SWIG_1(base int) (_ SwigcptrBarTi) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_BarTi__SWIG_1, _swig_p) + return +} + +func NewBarTi__SWIG_1(arg1 int) (_swig_ret BarTi) { + return _swig_wrap_new_BarTi__SWIG_1(arg1) +} + +func NewBarTi(a ...interface{}) BarTi { + argc := len(a) + if argc == 0 { + return NewBarTi__SWIG_0() + } + if argc == 1 { + return NewBarTi__SWIG_1(a[0].(int)) + } + panic("No match for overloaded function call") +} + +var _wrap_delete_BarTi unsafe.Pointer + +func _swig_wrap_delete_BarTi(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_BarTi, _swig_p) + return +} + +func DeleteBarTi(arg1 BarTi) { + _swig_wrap_delete_BarTi(arg1.Swigcptr()) +} + +var _wrap_BarTi_spam__SWIG_2 unsafe.Pointer + +func _swig_wrap_BarTi_spam__SWIG_2(base SwigcptrBarTi, _ int) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_BarTi_spam__SWIG_2, _swig_p) + return +} + +func (arg1 SwigcptrBarTi) Spam__SWIG_2(arg2 int) (_swig_ret int) { + return _swig_wrap_BarTi_spam__SWIG_2(arg1, arg2) +} + +var _wrap_BarTi_spam__SWIG_3 unsafe.Pointer + +func _swig_wrap_BarTi_spam__SWIG_3(base SwigcptrBarTi, _ int, _ int) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_BarTi_spam__SWIG_3, _swig_p) + return +} + +func (arg1 SwigcptrBarTi) Spam__SWIG_3(arg2 int, arg3 int) (_swig_ret int) { + return _swig_wrap_BarTi_spam__SWIG_3(arg1, arg2, arg3) +} + +var _wrap_BarTi_spam__SWIG_4 unsafe.Pointer + +func _swig_wrap_BarTi_spam__SWIG_4(base SwigcptrBarTi, _ int, _ int, _ int) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_BarTi_spam__SWIG_4, _swig_p) + return +} + +func (arg1 SwigcptrBarTi) Spam__SWIG_4(arg2 int, arg3 int, arg4 int) (_swig_ret int) { + return _swig_wrap_BarTi_spam__SWIG_4(arg1, arg2, arg3, arg4) +} + +var _wrap_BarTi_spam__SWIG_5 unsafe.Pointer + +func _swig_wrap_BarTi_spam__SWIG_5(base SwigcptrBarTi, _ uintptr, _ float64) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_BarTi_spam__SWIG_5, _swig_p) + return +} + +func (arg1 SwigcptrBarTi) Spam__SWIG_5(arg2 Bar, arg3 float64) (_swig_ret int) { + return _swig_wrap_BarTi_spam__SWIG_5(arg1, arg2.Swigcptr(), arg3) +} + +var _wrap_BarTi_spam__SWIG_6 unsafe.Pointer + +func _swig_wrap_BarTi_spam__SWIG_6(base SwigcptrBarTi, _ uintptr) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_BarTi_spam__SWIG_6, _swig_p) + return +} + +func (arg1 SwigcptrBarTi) Spam__SWIG_6(arg2 Bar) (_swig_ret int) { + return _swig_wrap_BarTi_spam__SWIG_6(arg1, arg2.Swigcptr()) +} + +func (p SwigcptrBarTi) Spam(a ...interface{}) int { + argc := len(a) + if argc == 0 { + return p.Spam__SWIG_0() + } + if argc == 1 { + if _, ok := a[0].(Bar); !ok { + goto check_2 + } + return p.Spam__SWIG_6(a[0].(Bar)) + } +check_2: + if argc == 1 { + if _, ok := a[0].(int); !ok { + goto check_3 + } + return p.Spam__SWIG_2(a[0].(int)) + } +check_3: + if argc == 1 { + return p.Spam__SWIG_1(a[0].(string)) + } + if argc == 2 { + if _, ok := a[0].(Bar); !ok { + goto check_5 + } + if _, ok := a[1].(float64); !ok { + goto check_5 + } + return p.Spam__SWIG_5(a[0].(Bar), a[1].(float64)) + } +check_5: + if argc == 2 { + return p.Spam__SWIG_3(a[0].(int), a[1].(int)) + } + if argc == 3 { + return p.Spam__SWIG_4(a[0].(int), a[1].(int), a[2].(int)) + } + panic("No match for overloaded function call") +} + +type BarTi interface { + Swigcptr() uintptr + SwigIsBarTi() + Spam(a ...interface{}) int +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/extend_placement_runme b/Examples/test-suite/go/extend_placement_runme new file mode 100755 index 000000000..a209ef272 Binary files /dev/null and b/Examples/test-suite/go/extend_placement_runme differ diff --git a/Examples/test-suite/go/extend_special_variables.go b/Examples/test-suite/go/extend_special_variables.go new file mode 100644 index 000000000..dc3357e4a --- /dev/null +++ b/Examples/test-suite/go/extend_special_variables.go @@ -0,0 +1,162 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../extend_special_variables.i + +package extend_special_variables + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrForExtensionNewName uintptr + +func (p SwigcptrForExtensionNewName) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrForExtensionNewName) SwigIsForExtensionNewName() { +} + +var _wrap_new_ForExtensionNewName unsafe.Pointer + +func _swig_wrap_new_ForExtensionNewName() (base SwigcptrForExtensionNewName) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_ForExtensionNewName, _swig_p) + return +} + +func NewForExtensionNewName() (_swig_ret ForExtensionNewName) { + return _swig_wrap_new_ForExtensionNewName() +} + +var _wrap_ForExtensionNewName_extended_renamed__SWIG_0 unsafe.Pointer + +func _swig_wrap_ForExtensionNewName_extended_renamed__SWIG_0(base SwigcptrForExtensionNewName) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_ForExtensionNewName_extended_renamed__SWIG_0, _swig_p) + return +} + +func (arg1 SwigcptrForExtensionNewName) Extended_renamed__SWIG_0() (_swig_ret string) { + return _swig_wrap_ForExtensionNewName_extended_renamed__SWIG_0(arg1) +} + +var _wrap_ForExtensionNewName_extended_renamed__SWIG_1 unsafe.Pointer + +func _swig_wrap_ForExtensionNewName_extended_renamed__SWIG_1(base SwigcptrForExtensionNewName, _ int) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_ForExtensionNewName_extended_renamed__SWIG_1, _swig_p) + return +} + +func (arg1 SwigcptrForExtensionNewName) Extended_renamed__SWIG_1(arg2 int) (_swig_ret string) { + return _swig_wrap_ForExtensionNewName_extended_renamed__SWIG_1(arg1, arg2) +} + +func (p SwigcptrForExtensionNewName) Extended_renamed(a ...interface{}) string { + argc := len(a) + if argc == 0 { + return p.Extended_renamed__SWIG_0() + } + if argc == 1 { + return p.Extended_renamed__SWIG_1(a[0].(int)) + } + panic("No match for overloaded function call") +} + +var _wrap_delete_ForExtensionNewName unsafe.Pointer + +func _swig_wrap_delete_ForExtensionNewName(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_ForExtensionNewName, _swig_p) + return +} + +func DeleteForExtensionNewName(arg1 ForExtensionNewName) { + _swig_wrap_delete_ForExtensionNewName(arg1.Swigcptr()) +} + +type ForExtensionNewName interface { + Swigcptr() uintptr + SwigIsForExtensionNewName() + Extended_renamed(a ...interface{}) string +} + +type SwigcptrExtendTemplateInt uintptr + +func (p SwigcptrExtendTemplateInt) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrExtendTemplateInt) SwigIsExtendTemplateInt() { +} + +var _wrap_ExtendTemplateInt_extending unsafe.Pointer + +func _swig_wrap_ExtendTemplateInt_extending(base SwigcptrExtendTemplateInt) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_ExtendTemplateInt_extending, _swig_p) + return +} + +func (arg1 SwigcptrExtendTemplateInt) Extending() { + _swig_wrap_ExtendTemplateInt_extending(arg1) +} + +var _wrap_new_ExtendTemplateInt unsafe.Pointer + +func _swig_wrap_new_ExtendTemplateInt() (base SwigcptrExtendTemplateInt) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_ExtendTemplateInt, _swig_p) + return +} + +func NewExtendTemplateInt() (_swig_ret ExtendTemplateInt) { + return _swig_wrap_new_ExtendTemplateInt() +} + +var _wrap_delete_ExtendTemplateInt unsafe.Pointer + +func _swig_wrap_delete_ExtendTemplateInt(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_ExtendTemplateInt, _swig_p) + return +} + +func DeleteExtendTemplateInt(arg1 ExtendTemplateInt) { + _swig_wrap_delete_ExtendTemplateInt(arg1.Swigcptr()) +} + +type ExtendTemplateInt interface { + Swigcptr() uintptr + SwigIsExtendTemplateInt() + Extending() +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/extend_template.go b/Examples/test-suite/go/extend_template.go new file mode 100644 index 000000000..b127a06f4 --- /dev/null +++ b/Examples/test-suite/go/extend_template.go @@ -0,0 +1,101 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../extend_template.i + +package extend_template + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrFoo_0 uintptr + +func (p SwigcptrFoo_0) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrFoo_0) SwigIsFoo_0() { +} + +var _wrap_Foo_0_test1 unsafe.Pointer + +func _swig_wrap_Foo_0_test1(base SwigcptrFoo_0, _ int) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_0_test1, _swig_p) + return +} + +func (arg1 SwigcptrFoo_0) Test1(arg2 int) (_swig_ret int) { + return _swig_wrap_Foo_0_test1(arg1, arg2) +} + +var _wrap_Foo_0_test2 unsafe.Pointer + +func _swig_wrap_Foo_0_test2(base SwigcptrFoo_0, _ int) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_0_test2, _swig_p) + return +} + +func (arg1 SwigcptrFoo_0) Test2(arg2 int) (_swig_ret int) { + return _swig_wrap_Foo_0_test2(arg1, arg2) +} + +var _wrap_new_Foo_0 unsafe.Pointer + +func _swig_wrap_new_Foo_0() (base SwigcptrFoo_0) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Foo_0, _swig_p) + return +} + +func NewFoo_0() (_swig_ret Foo_0) { + return _swig_wrap_new_Foo_0() +} + +var _wrap_delete_Foo_0 unsafe.Pointer + +func _swig_wrap_delete_Foo_0(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Foo_0, _swig_p) + return +} + +func DeleteFoo_0(arg1 Foo_0) { + _swig_wrap_delete_Foo_0(arg1.Swigcptr()) +} + +type Foo_0 interface { + Swigcptr() uintptr + SwigIsFoo_0() + Test1(arg2 int) (_swig_ret int) + Test2(arg2 int) (_swig_ret int) +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/extend_template_ns.go b/Examples/test-suite/go/extend_template_ns.go new file mode 100644 index 000000000..5e1a0331c --- /dev/null +++ b/Examples/test-suite/go/extend_template_ns.go @@ -0,0 +1,118 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../extend_template_ns.i + +package extend_template_ns + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type OssTest int +var _wrap_One unsafe.Pointer + +func _swig_getOne() (_swig_ret OssTest) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_One, _swig_p) + return +} +var One OssTest = _swig_getOne() +var _wrap_Two unsafe.Pointer + +func _swig_getTwo() (_swig_ret OssTest) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_Two, _swig_p) + return +} +var Two OssTest = _swig_getTwo() +type SwigcptrFoo_One uintptr + +func (p SwigcptrFoo_One) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrFoo_One) SwigIsFoo_One() { +} + +var _wrap_Foo_One_test1 unsafe.Pointer + +func _swig_wrap_Foo_One_test1(base SwigcptrFoo_One, _ int) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_One_test1, _swig_p) + return +} + +func (arg1 SwigcptrFoo_One) Test1(arg2 int) (_swig_ret int) { + return _swig_wrap_Foo_One_test1(arg1, arg2) +} + +var _wrap_Foo_One_test2 unsafe.Pointer + +func _swig_wrap_Foo_One_test2(base SwigcptrFoo_One, _ int) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_One_test2, _swig_p) + return +} + +func (arg1 SwigcptrFoo_One) Test2(arg2 int) (_swig_ret int) { + return _swig_wrap_Foo_One_test2(arg1, arg2) +} + +var _wrap_new_Foo_One unsafe.Pointer + +func _swig_wrap_new_Foo_One() (base SwigcptrFoo_One) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Foo_One, _swig_p) + return +} + +func NewFoo_One() (_swig_ret Foo_One) { + return _swig_wrap_new_Foo_One() +} + +var _wrap_delete_Foo_One unsafe.Pointer + +func _swig_wrap_delete_Foo_One(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Foo_One, _swig_p) + return +} + +func DeleteFoo_One(arg1 Foo_One) { + _swig_wrap_delete_Foo_One(arg1.Swigcptr()) +} + +type Foo_One interface { + Swigcptr() uintptr + SwigIsFoo_One() + Test1(arg2 int) (_swig_ret int) + Test2(arg2 int) (_swig_ret int) +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/extend_template_ns_runme b/Examples/test-suite/go/extend_template_ns_runme new file mode 100755 index 000000000..828a6d988 Binary files /dev/null and b/Examples/test-suite/go/extend_template_ns_runme differ diff --git a/Examples/test-suite/go/extend_template_runme b/Examples/test-suite/go/extend_template_runme new file mode 100755 index 000000000..df5539670 Binary files /dev/null and b/Examples/test-suite/go/extend_template_runme differ diff --git a/Examples/test-suite/go/extend_typedef_class.go b/Examples/test-suite/go/extend_typedef_class.go new file mode 100644 index 000000000..58d10d5c7 --- /dev/null +++ b/Examples/test-suite/go/extend_typedef_class.go @@ -0,0 +1,653 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../extend_typedef_class.i + +package extend_typedef_class + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrAClass uintptr + +func (p SwigcptrAClass) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrAClass) SwigIsAClass() { +} + +var _wrap_AClass_membervar_set unsafe.Pointer + +func _swig_wrap_AClass_membervar_set(base SwigcptrAClass, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_AClass_membervar_set, _swig_p) + return +} + +func (arg1 SwigcptrAClass) SetMembervar(arg2 int) { + _swig_wrap_AClass_membervar_set(arg1, arg2) +} + +var _wrap_AClass_membervar_get unsafe.Pointer + +func _swig_wrap_AClass_membervar_get(base SwigcptrAClass) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_AClass_membervar_get, _swig_p) + return +} + +func (arg1 SwigcptrAClass) GetMembervar() (_swig_ret int) { + return _swig_wrap_AClass_membervar_get(arg1) +} + +var _wrap_AClass_getvar unsafe.Pointer + +func _swig_wrap_AClass_getvar(base SwigcptrAClass) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_AClass_getvar, _swig_p) + return +} + +func (arg1 SwigcptrAClass) Getvar() (_swig_ret int) { + return _swig_wrap_AClass_getvar(arg1) +} + +var _wrap_new_AClass unsafe.Pointer + +func _swig_wrap_new_AClass() (base SwigcptrAClass) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_AClass, _swig_p) + return +} + +func NewAClass() (_swig_ret AClass) { + return _swig_wrap_new_AClass() +} + +var _wrap_delete_AClass unsafe.Pointer + +func _swig_wrap_delete_AClass(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_AClass, _swig_p) + return +} + +func DeleteAClass(arg1 AClass) { + _swig_wrap_delete_AClass(arg1.Swigcptr()) +} + +type AClass interface { + Swigcptr() uintptr + SwigIsAClass() + SetMembervar(arg2 int) + GetMembervar() (_swig_ret int) + Getvar() (_swig_ret int) +} + +type SwigcptrBClass uintptr + +func (p SwigcptrBClass) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrBClass) SwigIsBClass() { +} + +var _wrap_BClass_membervar_set unsafe.Pointer + +func _swig_wrap_BClass_membervar_set(base SwigcptrBClass, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_BClass_membervar_set, _swig_p) + return +} + +func (arg1 SwigcptrBClass) SetMembervar(arg2 int) { + _swig_wrap_BClass_membervar_set(arg1, arg2) +} + +var _wrap_BClass_membervar_get unsafe.Pointer + +func _swig_wrap_BClass_membervar_get(base SwigcptrBClass) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_BClass_membervar_get, _swig_p) + return +} + +func (arg1 SwigcptrBClass) GetMembervar() (_swig_ret int) { + return _swig_wrap_BClass_membervar_get(arg1) +} + +var _wrap_BClass_getvar unsafe.Pointer + +func _swig_wrap_BClass_getvar(base SwigcptrBClass) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_BClass_getvar, _swig_p) + return +} + +func (arg1 SwigcptrBClass) Getvar() (_swig_ret int) { + return _swig_wrap_BClass_getvar(arg1) +} + +var _wrap_new_BClass unsafe.Pointer + +func _swig_wrap_new_BClass() (base SwigcptrBClass) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_BClass, _swig_p) + return +} + +func NewBClass() (_swig_ret BClass) { + return _swig_wrap_new_BClass() +} + +var _wrap_delete_BClass unsafe.Pointer + +func _swig_wrap_delete_BClass(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_BClass, _swig_p) + return +} + +func DeleteBClass(arg1 BClass) { + _swig_wrap_delete_BClass(arg1.Swigcptr()) +} + +type BClass interface { + Swigcptr() uintptr + SwigIsBClass() + SetMembervar(arg2 int) + GetMembervar() (_swig_ret int) + Getvar() (_swig_ret int) +} + +type SwigcptrCClass uintptr + +func (p SwigcptrCClass) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrCClass) SwigIsCClass() { +} + +var _wrap_CClass_membervar_set unsafe.Pointer + +func _swig_wrap_CClass_membervar_set(base SwigcptrCClass, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_CClass_membervar_set, _swig_p) + return +} + +func (arg1 SwigcptrCClass) SetMembervar(arg2 int) { + _swig_wrap_CClass_membervar_set(arg1, arg2) +} + +var _wrap_CClass_membervar_get unsafe.Pointer + +func _swig_wrap_CClass_membervar_get(base SwigcptrCClass) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_CClass_membervar_get, _swig_p) + return +} + +func (arg1 SwigcptrCClass) GetMembervar() (_swig_ret int) { + return _swig_wrap_CClass_membervar_get(arg1) +} + +var _wrap_CClass_getvar unsafe.Pointer + +func _swig_wrap_CClass_getvar(base SwigcptrCClass) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_CClass_getvar, _swig_p) + return +} + +func (arg1 SwigcptrCClass) Getvar() (_swig_ret int) { + return _swig_wrap_CClass_getvar(arg1) +} + +var _wrap_new_CClass unsafe.Pointer + +func _swig_wrap_new_CClass() (base SwigcptrCClass) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_CClass, _swig_p) + return +} + +func NewCClass() (_swig_ret CClass) { + return _swig_wrap_new_CClass() +} + +var _wrap_delete_CClass unsafe.Pointer + +func _swig_wrap_delete_CClass(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_CClass, _swig_p) + return +} + +func DeleteCClass(arg1 CClass) { + _swig_wrap_delete_CClass(arg1.Swigcptr()) +} + +type CClass interface { + Swigcptr() uintptr + SwigIsCClass() + SetMembervar(arg2 int) + GetMembervar() (_swig_ret int) + Getvar() (_swig_ret int) +} + +type SwigcptrDClass uintptr + +func (p SwigcptrDClass) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrDClass) SwigIsDClass() { +} + +var _wrap_DClass_membervar_set unsafe.Pointer + +func _swig_wrap_DClass_membervar_set(base SwigcptrDClass, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_DClass_membervar_set, _swig_p) + return +} + +func (arg1 SwigcptrDClass) SetMembervar(arg2 int) { + _swig_wrap_DClass_membervar_set(arg1, arg2) +} + +var _wrap_DClass_membervar_get unsafe.Pointer + +func _swig_wrap_DClass_membervar_get(base SwigcptrDClass) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_DClass_membervar_get, _swig_p) + return +} + +func (arg1 SwigcptrDClass) GetMembervar() (_swig_ret int) { + return _swig_wrap_DClass_membervar_get(arg1) +} + +var _wrap_DClass_getvar unsafe.Pointer + +func _swig_wrap_DClass_getvar(base SwigcptrDClass) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_DClass_getvar, _swig_p) + return +} + +func (arg1 SwigcptrDClass) Getvar() (_swig_ret int) { + return _swig_wrap_DClass_getvar(arg1) +} + +var _wrap_new_DClass unsafe.Pointer + +func _swig_wrap_new_DClass() (base SwigcptrDClass) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_DClass, _swig_p) + return +} + +func NewDClass() (_swig_ret DClass) { + return _swig_wrap_new_DClass() +} + +var _wrap_delete_DClass unsafe.Pointer + +func _swig_wrap_delete_DClass(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_DClass, _swig_p) + return +} + +func DeleteDClass(arg1 DClass) { + _swig_wrap_delete_DClass(arg1.Swigcptr()) +} + +type DClass interface { + Swigcptr() uintptr + SwigIsDClass() + SetMembervar(arg2 int) + GetMembervar() (_swig_ret int) + Getvar() (_swig_ret int) +} + +type SwigcptrAStruct uintptr + +func (p SwigcptrAStruct) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrAStruct) SwigIsAStruct() { +} + +var _wrap_AStruct_membervar_set unsafe.Pointer + +func _swig_wrap_AStruct_membervar_set(base SwigcptrAStruct, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_AStruct_membervar_set, _swig_p) + return +} + +func (arg1 SwigcptrAStruct) SetMembervar(arg2 int) { + _swig_wrap_AStruct_membervar_set(arg1, arg2) +} + +var _wrap_AStruct_membervar_get unsafe.Pointer + +func _swig_wrap_AStruct_membervar_get(base SwigcptrAStruct) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_AStruct_membervar_get, _swig_p) + return +} + +func (arg1 SwigcptrAStruct) GetMembervar() (_swig_ret int) { + return _swig_wrap_AStruct_membervar_get(arg1) +} + +var _wrap_AStruct_getvar unsafe.Pointer + +func _swig_wrap_AStruct_getvar(base SwigcptrAStruct) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_AStruct_getvar, _swig_p) + return +} + +func (arg1 SwigcptrAStruct) Getvar() (_swig_ret int) { + return _swig_wrap_AStruct_getvar(arg1) +} + +var _wrap_new_AStruct unsafe.Pointer + +func _swig_wrap_new_AStruct() (base SwigcptrAStruct) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_AStruct, _swig_p) + return +} + +func NewAStruct() (_swig_ret AStruct) { + return _swig_wrap_new_AStruct() +} + +var _wrap_delete_AStruct unsafe.Pointer + +func _swig_wrap_delete_AStruct(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_AStruct, _swig_p) + return +} + +func DeleteAStruct(arg1 AStruct) { + _swig_wrap_delete_AStruct(arg1.Swigcptr()) +} + +type AStruct interface { + Swigcptr() uintptr + SwigIsAStruct() + SetMembervar(arg2 int) + GetMembervar() (_swig_ret int) + Getvar() (_swig_ret int) +} + +type SwigcptrBStruct uintptr + +func (p SwigcptrBStruct) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrBStruct) SwigIsBStruct() { +} + +var _wrap_BStruct_membervar_set unsafe.Pointer + +func _swig_wrap_BStruct_membervar_set(base SwigcptrBStruct, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_BStruct_membervar_set, _swig_p) + return +} + +func (arg1 SwigcptrBStruct) SetMembervar(arg2 int) { + _swig_wrap_BStruct_membervar_set(arg1, arg2) +} + +var _wrap_BStruct_membervar_get unsafe.Pointer + +func _swig_wrap_BStruct_membervar_get(base SwigcptrBStruct) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_BStruct_membervar_get, _swig_p) + return +} + +func (arg1 SwigcptrBStruct) GetMembervar() (_swig_ret int) { + return _swig_wrap_BStruct_membervar_get(arg1) +} + +var _wrap_BStruct_getvar unsafe.Pointer + +func _swig_wrap_BStruct_getvar(base SwigcptrBStruct) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_BStruct_getvar, _swig_p) + return +} + +func (arg1 SwigcptrBStruct) Getvar() (_swig_ret int) { + return _swig_wrap_BStruct_getvar(arg1) +} + +var _wrap_new_BStruct unsafe.Pointer + +func _swig_wrap_new_BStruct() (base SwigcptrBStruct) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_BStruct, _swig_p) + return +} + +func NewBStruct() (_swig_ret BStruct) { + return _swig_wrap_new_BStruct() +} + +var _wrap_delete_BStruct unsafe.Pointer + +func _swig_wrap_delete_BStruct(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_BStruct, _swig_p) + return +} + +func DeleteBStruct(arg1 BStruct) { + _swig_wrap_delete_BStruct(arg1.Swigcptr()) +} + +type BStruct interface { + Swigcptr() uintptr + SwigIsBStruct() + SetMembervar(arg2 int) + GetMembervar() (_swig_ret int) + Getvar() (_swig_ret int) +} + +type SwigcptrCStruct uintptr + +func (p SwigcptrCStruct) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrCStruct) SwigIsCStruct() { +} + +var _wrap_CStruct_membervar_set unsafe.Pointer + +func _swig_wrap_CStruct_membervar_set(base SwigcptrCStruct, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_CStruct_membervar_set, _swig_p) + return +} + +func (arg1 SwigcptrCStruct) SetMembervar(arg2 int) { + _swig_wrap_CStruct_membervar_set(arg1, arg2) +} + +var _wrap_CStruct_membervar_get unsafe.Pointer + +func _swig_wrap_CStruct_membervar_get(base SwigcptrCStruct) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_CStruct_membervar_get, _swig_p) + return +} + +func (arg1 SwigcptrCStruct) GetMembervar() (_swig_ret int) { + return _swig_wrap_CStruct_membervar_get(arg1) +} + +var _wrap_CStruct_getvar unsafe.Pointer + +func _swig_wrap_CStruct_getvar(base SwigcptrCStruct) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_CStruct_getvar, _swig_p) + return +} + +func (arg1 SwigcptrCStruct) Getvar() (_swig_ret int) { + return _swig_wrap_CStruct_getvar(arg1) +} + +var _wrap_new_CStruct unsafe.Pointer + +func _swig_wrap_new_CStruct() (base SwigcptrCStruct) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_CStruct, _swig_p) + return +} + +func NewCStruct() (_swig_ret CStruct) { + return _swig_wrap_new_CStruct() +} + +var _wrap_delete_CStruct unsafe.Pointer + +func _swig_wrap_delete_CStruct(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_CStruct, _swig_p) + return +} + +func DeleteCStruct(arg1 CStruct) { + _swig_wrap_delete_CStruct(arg1.Swigcptr()) +} + +type CStruct interface { + Swigcptr() uintptr + SwigIsCStruct() + SetMembervar(arg2 int) + GetMembervar() (_swig_ret int) + Getvar() (_swig_ret int) +} + +type SwigcptrDStruct uintptr + +func (p SwigcptrDStruct) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrDStruct) SwigIsDStruct() { +} + +var _wrap_DStruct_membervar_set unsafe.Pointer + +func _swig_wrap_DStruct_membervar_set(base SwigcptrDStruct, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_DStruct_membervar_set, _swig_p) + return +} + +func (arg1 SwigcptrDStruct) SetMembervar(arg2 int) { + _swig_wrap_DStruct_membervar_set(arg1, arg2) +} + +var _wrap_DStruct_membervar_get unsafe.Pointer + +func _swig_wrap_DStruct_membervar_get(base SwigcptrDStruct) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_DStruct_membervar_get, _swig_p) + return +} + +func (arg1 SwigcptrDStruct) GetMembervar() (_swig_ret int) { + return _swig_wrap_DStruct_membervar_get(arg1) +} + +var _wrap_DStruct_getvar unsafe.Pointer + +func _swig_wrap_DStruct_getvar(base SwigcptrDStruct) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_DStruct_getvar, _swig_p) + return +} + +func (arg1 SwigcptrDStruct) Getvar() (_swig_ret int) { + return _swig_wrap_DStruct_getvar(arg1) +} + +var _wrap_new_DStruct unsafe.Pointer + +func _swig_wrap_new_DStruct() (base SwigcptrDStruct) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_DStruct, _swig_p) + return +} + +func NewDStruct() (_swig_ret DStruct) { + return _swig_wrap_new_DStruct() +} + +var _wrap_delete_DStruct unsafe.Pointer + +func _swig_wrap_delete_DStruct(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_DStruct, _swig_p) + return +} + +func DeleteDStruct(arg1 DStruct) { + _swig_wrap_delete_DStruct(arg1.Swigcptr()) +} + +type DStruct interface { + Swigcptr() uintptr + SwigIsDStruct() + SetMembervar(arg2 int) + GetMembervar() (_swig_ret int) + Getvar() (_swig_ret int) +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/extern_c.go b/Examples/test-suite/go/extern_c.go new file mode 100644 index 000000000..cbb1324f8 --- /dev/null +++ b/Examples/test-suite/go/extern_c.go @@ -0,0 +1,49 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../extern_c.i + +package extern_c + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +var _wrap_RealFunction unsafe.Pointer + +func _swig_wrap_RealFunction(base int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_RealFunction, _swig_p) + return +} + +func RealFunction(arg1 int) { + _swig_wrap_RealFunction(arg1) +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/extern_c_runme b/Examples/test-suite/go/extern_c_runme new file mode 100755 index 000000000..8eff8fd84 Binary files /dev/null and b/Examples/test-suite/go/extern_c_runme differ diff --git a/Examples/test-suite/go/extern_declaration.go b/Examples/test-suite/go/extern_declaration.go new file mode 100644 index 000000000..6a591d4d4 --- /dev/null +++ b/Examples/test-suite/go/extern_declaration.go @@ -0,0 +1,50 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../extern_declaration.i + +package extern_declaration + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +var _wrap_externimport unsafe.Pointer + +func Externimport(arg1 int) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_externimport, _swig_p) + return +} +var _wrap_externexport unsafe.Pointer + +func Externexport(arg1 int) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_externexport, _swig_p) + return +} +var _wrap_externstdcall unsafe.Pointer + +func Externstdcall(arg1 int) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_externstdcall, _swig_p) + return +} + diff --git a/Examples/test-suite/go/extern_namespace.go b/Examples/test-suite/go/extern_namespace.go new file mode 100644 index 000000000..0ceeca9c8 --- /dev/null +++ b/Examples/test-suite/go/extern_namespace.go @@ -0,0 +1,61 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../extern_namespace.i + +package extern_namespace + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +var _wrap_bar__SWIG_0 unsafe.Pointer + +func Bar__SWIG_0(arg1 int) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_bar__SWIG_0, _swig_p) + return +} +var _wrap_bar__SWIG_1 unsafe.Pointer + +func Bar__SWIG_1() (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_bar__SWIG_1, _swig_p) + return +} +func Bar(a ...interface{}) int { + argc := len(a) + if argc == 0 { + return Bar__SWIG_1() + } + if argc == 1 { + return Bar__SWIG_0(a[0].(int)) + } + panic("No match for overloaded function call") +} + +var _wrap_foobar unsafe.Pointer + +func Foobar(arg1 int) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_foobar, _swig_p) + return +} + diff --git a/Examples/test-suite/go/extern_throws.go b/Examples/test-suite/go/extern_throws.go new file mode 100644 index 000000000..10dd17c77 --- /dev/null +++ b/Examples/test-suite/go/extern_throws.go @@ -0,0 +1,36 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../extern_throws.i + +package extern_throws + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +var _wrap_get unsafe.Pointer + +func Get() (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_get, _swig_p) + return +} + diff --git a/Examples/test-suite/go/features.go b/Examples/test-suite/go/features.go new file mode 100644 index 000000000..9d2ee19d9 --- /dev/null +++ b/Examples/test-suite/go/features.go @@ -0,0 +1,834 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../features.i + +package features + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrSimple uintptr + +func (p SwigcptrSimple) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrSimple) SwigIsSimple() { +} + +var _wrap_new_Simple unsafe.Pointer + +func _swig_wrap_new_Simple() (base SwigcptrSimple) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Simple, _swig_p) + return +} + +func NewSimple() (_swig_ret Simple) { + return _swig_wrap_new_Simple() +} + +var _wrap_delete_Simple unsafe.Pointer + +func _swig_wrap_delete_Simple(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Simple, _swig_p) + return +} + +func DeleteSimple(arg1 Simple) { + _swig_wrap_delete_Simple(arg1.Swigcptr()) +} + +type Simple interface { + Swigcptr() uintptr + SwigIsSimple() +} + +type SwigcptrSimpleNS uintptr + +func (p SwigcptrSimpleNS) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrSimpleNS) SwigIsSimpleNS() { +} + +var _wrap_SimpleNS_method unsafe.Pointer + +func _swig_wrap_SimpleNS_method(base SwigcptrSimpleNS) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_SimpleNS_method, _swig_p) + return +} + +func (arg1 SwigcptrSimpleNS) Method() { + _swig_wrap_SimpleNS_method(arg1) +} + +var _wrap_SimpleNS_afunction unsafe.Pointer + +func _swig_wrap_SimpleNS_afunction(base SwigcptrSimpleNS) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_SimpleNS_afunction, _swig_p) + return +} + +func (arg1 SwigcptrSimpleNS) Afunction() { + _swig_wrap_SimpleNS_afunction(arg1) +} + +var _wrap_new_SimpleNS unsafe.Pointer + +func _swig_wrap_new_SimpleNS() (base SwigcptrSimpleNS) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_SimpleNS, _swig_p) + return +} + +func NewSimpleNS() (_swig_ret SimpleNS) { + return _swig_wrap_new_SimpleNS() +} + +var _wrap_delete_SimpleNS unsafe.Pointer + +func _swig_wrap_delete_SimpleNS(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_SimpleNS, _swig_p) + return +} + +func DeleteSimpleNS(arg1 SimpleNS) { + _swig_wrap_delete_SimpleNS(arg1.Swigcptr()) +} + +type SimpleNS interface { + Swigcptr() uintptr + SwigIsSimpleNS() + Method() + Afunction() +} + +var _wrap_FooBarInt unsafe.Pointer + +func _swig_wrap_FooBarInt(base int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_FooBarInt, _swig_p) + return +} + +func FooBarInt(arg1 int) { + _swig_wrap_FooBarInt(arg1) +} + +type SwigcptrSimpleInt uintptr + +func (p SwigcptrSimpleInt) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrSimpleInt) SwigIsSimpleInt() { +} + +var _wrap_new_SimpleInt unsafe.Pointer + +func _swig_wrap_new_SimpleInt() (base SwigcptrSimpleInt) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_SimpleInt, _swig_p) + return +} + +func NewSimpleInt() (_swig_ret SimpleInt) { + return _swig_wrap_new_SimpleInt() +} + +var _wrap_delete_SimpleInt unsafe.Pointer + +func _swig_wrap_delete_SimpleInt(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_SimpleInt, _swig_p) + return +} + +func DeleteSimpleInt(arg1 SimpleInt) { + _swig_wrap_delete_SimpleInt(arg1.Swigcptr()) +} + +type SimpleInt interface { + Swigcptr() uintptr + SwigIsSimpleInt() +} + +type SwigcptrTemplateInt uintptr + +func (p SwigcptrTemplateInt) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrTemplateInt) SwigIsTemplateInt() { +} + +var _wrap_new_TemplateInt__SWIG_0 unsafe.Pointer + +func _swig_wrap_new_TemplateInt__SWIG_0() (base SwigcptrTemplateInt) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_TemplateInt__SWIG_0, _swig_p) + return +} + +func NewTemplateInt__SWIG_0() (_swig_ret TemplateInt) { + return _swig_wrap_new_TemplateInt__SWIG_0() +} + +var _wrap_new_TemplateInt__SWIG_1 unsafe.Pointer + +func _swig_wrap_new_TemplateInt__SWIG_1(base uintptr) (_ SwigcptrTemplateInt) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_TemplateInt__SWIG_1, _swig_p) + return +} + +func NewTemplateInt__SWIG_1(arg1 TemplateInt) (_swig_ret TemplateInt) { + return _swig_wrap_new_TemplateInt__SWIG_1(arg1.Swigcptr()) +} + +func NewTemplateInt(a ...interface{}) TemplateInt { + argc := len(a) + if argc == 0 { + return NewTemplateInt__SWIG_0() + } + if argc == 1 { + return NewTemplateInt__SWIG_1(a[0].(TemplateInt)) + } + panic("No match for overloaded function call") +} + +var _wrap_delete_TemplateInt unsafe.Pointer + +func _swig_wrap_delete_TemplateInt(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_TemplateInt, _swig_p) + return +} + +func DeleteTemplateInt(arg1 TemplateInt) { + _swig_wrap_delete_TemplateInt(arg1.Swigcptr()) +} + +var _wrap_TemplateInt_foo unsafe.Pointer + +func _swig_wrap_TemplateInt_foo(base SwigcptrTemplateInt) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_TemplateInt_foo, _swig_p) + return +} + +func (arg1 SwigcptrTemplateInt) Foo() { + _swig_wrap_TemplateInt_foo(arg1) +} + +var _wrap_TemplateInt_bar unsafe.Pointer + +func _swig_wrap_TemplateInt_bar(base SwigcptrTemplateInt, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_TemplateInt_bar, _swig_p) + return +} + +func (arg1 SwigcptrTemplateInt) Bar(arg2 int) { + _swig_wrap_TemplateInt_bar(arg1, arg2) +} + +var _wrap_TemplateInt_get unsafe.Pointer + +func _swig_wrap_TemplateInt_get(base SwigcptrTemplateInt, _ int) (_ *int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_TemplateInt_get, _swig_p) + return +} + +func (arg1 SwigcptrTemplateInt) Get(arg2 int) (_swig_ret *int) { + return _swig_wrap_TemplateInt_get(arg1, arg2) +} + +var _wrap_TemplateInt_set unsafe.Pointer + +func _swig_wrap_TemplateInt_set(base SwigcptrTemplateInt, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_TemplateInt_set, _swig_p) + return +} + +func (arg1 SwigcptrTemplateInt) Set(arg2 int) { + _swig_wrap_TemplateInt_set(arg1, arg2) +} + +type TemplateInt interface { + Swigcptr() uintptr + SwigIsTemplateInt() + Foo() + Bar(arg2 int) + Get(arg2 int) (_swig_ret *int) + Set(arg2 int) +} + +type SwigcptrWildCards uintptr + +func (p SwigcptrWildCards) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrWildCards) SwigIsWildCards() { +} + +var _wrap_delete_WildCards unsafe.Pointer + +func _swig_wrap_delete_WildCards(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_WildCards, _swig_p) + return +} + +func DeleteWildCards(arg1 WildCards) { + _swig_wrap_delete_WildCards(arg1.Swigcptr()) +} + +var _wrap_WildCards_incy unsafe.Pointer + +func _swig_wrap_WildCards_incy(base SwigcptrWildCards, _ int) (_ SwigcptrWildCards) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_WildCards_incy, _swig_p) + return +} + +func (arg1 SwigcptrWildCards) Incy(arg2 int) (_swig_ret WildCards) { + return _swig_wrap_WildCards_incy(arg1, arg2) +} + +var _wrap_WildCards_wincy unsafe.Pointer + +func _swig_wrap_WildCards_wincy(base SwigcptrWildCards, _ int) (_ SwigcptrWildCards) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_WildCards_wincy, _swig_p) + return +} + +func (arg1 SwigcptrWildCards) Wincy(arg2 int) (_swig_ret WildCards) { + return _swig_wrap_WildCards_wincy(arg1, arg2) +} + +var _wrap_WildCards_spider unsafe.Pointer + +func _swig_wrap_WildCards_spider(base SwigcptrWildCards, _ int) (_ SwigcptrWildCards) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_WildCards_spider, _swig_p) + return +} + +func (arg1 SwigcptrWildCards) Spider(arg2 int) (_swig_ret WildCards) { + return _swig_wrap_WildCards_spider(arg1, arg2) +} + +var _wrap_new_WildCards unsafe.Pointer + +func _swig_wrap_new_WildCards() (base SwigcptrWildCards) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_WildCards, _swig_p) + return +} + +func NewWildCards() (_swig_ret WildCards) { + return _swig_wrap_new_WildCards() +} + +type WildCards interface { + Swigcptr() uintptr + SwigIsWildCards() + Incy(arg2 int) (_swig_ret WildCards) + Wincy(arg2 int) (_swig_ret WildCards) + Spider(arg2 int) (_swig_ret WildCards) +} + +type SwigcptrAnimals uintptr + +func (p SwigcptrAnimals) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrAnimals) SwigIsAnimals() { +} + +var _wrap_new_Animals__SWIG_0 unsafe.Pointer + +func _swig_wrap_new_Animals__SWIG_0(base int, _ float64) (_ SwigcptrAnimals) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Animals__SWIG_0, _swig_p) + return +} + +func NewAnimals__SWIG_0(arg1 int, arg2 float64) (_swig_ret Animals) { + return _swig_wrap_new_Animals__SWIG_0(arg1, arg2) +} + +var _wrap_new_Animals__SWIG_1 unsafe.Pointer + +func _swig_wrap_new_Animals__SWIG_1(base int) (_ SwigcptrAnimals) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Animals__SWIG_1, _swig_p) + return +} + +func NewAnimals__SWIG_1(arg1 int) (_swig_ret Animals) { + return _swig_wrap_new_Animals__SWIG_1(arg1) +} + +var _wrap_new_Animals__SWIG_2 unsafe.Pointer + +func _swig_wrap_new_Animals__SWIG_2() (base SwigcptrAnimals) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Animals__SWIG_2, _swig_p) + return +} + +func NewAnimals__SWIG_2() (_swig_ret Animals) { + return _swig_wrap_new_Animals__SWIG_2() +} + +func NewAnimals(a ...interface{}) Animals { + argc := len(a) + if argc == 0 { + return NewAnimals__SWIG_2() + } + if argc == 1 { + return NewAnimals__SWIG_1(a[0].(int)) + } + if argc == 2 { + return NewAnimals__SWIG_0(a[0].(int), a[1].(float64)) + } + panic("No match for overloaded function call") +} + +var _wrap_Animals_lions__SWIG_0 unsafe.Pointer + +func _swig_wrap_Animals_lions__SWIG_0(base SwigcptrAnimals, _ int, _ float64) (_ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Animals_lions__SWIG_0, _swig_p) + return +} + +func (arg1 SwigcptrAnimals) Lions__SWIG_0(arg2 int, arg3 float64) (_swig_ret uintptr) { + return _swig_wrap_Animals_lions__SWIG_0(arg1, arg2, arg3) +} + +var _wrap_Animals_lions__SWIG_1 unsafe.Pointer + +func _swig_wrap_Animals_lions__SWIG_1(base SwigcptrAnimals, _ int) (_ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Animals_lions__SWIG_1, _swig_p) + return +} + +func (arg1 SwigcptrAnimals) Lions__SWIG_1(arg2 int) (_swig_ret uintptr) { + return _swig_wrap_Animals_lions__SWIG_1(arg1, arg2) +} + +var _wrap_Animals_lions__SWIG_2 unsafe.Pointer + +func _swig_wrap_Animals_lions__SWIG_2(base SwigcptrAnimals) (_ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Animals_lions__SWIG_2, _swig_p) + return +} + +func (arg1 SwigcptrAnimals) Lions__SWIG_2() (_swig_ret uintptr) { + return _swig_wrap_Animals_lions__SWIG_2(arg1) +} + +func (p SwigcptrAnimals) Lions(a ...interface{}) uintptr { + argc := len(a) + if argc == 0 { + return p.Lions__SWIG_2() + } + if argc == 1 { + return p.Lions__SWIG_1(a[0].(int)) + } + if argc == 2 { + return p.Lions__SWIG_0(a[0].(int), a[1].(float64)) + } + panic("No match for overloaded function call") +} + +var _wrap_Animals_leopards__SWIG_0 unsafe.Pointer + +func _swig_wrap_Animals_leopards__SWIG_0(base SwigcptrAnimals, _ int, _ float64) (_ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Animals_leopards__SWIG_0, _swig_p) + return +} + +func (arg1 SwigcptrAnimals) Leopards__SWIG_0(arg2 int, arg3 float64) (_swig_ret uintptr) { + return _swig_wrap_Animals_leopards__SWIG_0(arg1, arg2, arg3) +} + +var _wrap_Animals_leopards__SWIG_1 unsafe.Pointer + +func _swig_wrap_Animals_leopards__SWIG_1(base SwigcptrAnimals, _ int) (_ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Animals_leopards__SWIG_1, _swig_p) + return +} + +func (arg1 SwigcptrAnimals) Leopards__SWIG_1(arg2 int) (_swig_ret uintptr) { + return _swig_wrap_Animals_leopards__SWIG_1(arg1, arg2) +} + +var _wrap_Animals_leopards__SWIG_2 unsafe.Pointer + +func _swig_wrap_Animals_leopards__SWIG_2(base SwigcptrAnimals) (_ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Animals_leopards__SWIG_2, _swig_p) + return +} + +func (arg1 SwigcptrAnimals) Leopards__SWIG_2() (_swig_ret uintptr) { + return _swig_wrap_Animals_leopards__SWIG_2(arg1) +} + +func (p SwigcptrAnimals) Leopards(a ...interface{}) uintptr { + argc := len(a) + if argc == 0 { + return p.Leopards__SWIG_2() + } + if argc == 1 { + return p.Leopards__SWIG_1(a[0].(int)) + } + if argc == 2 { + return p.Leopards__SWIG_0(a[0].(int), a[1].(float64)) + } + panic("No match for overloaded function call") +} + +var _wrap_Animals_cheetahs__SWIG_0 unsafe.Pointer + +func _swig_wrap_Animals_cheetahs__SWIG_0(base SwigcptrAnimals, _ int, _ float64) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Animals_cheetahs__SWIG_0, _swig_p) + return +} + +func (arg1 SwigcptrAnimals) Cheetahs__SWIG_0(arg2 int, arg3 float64) (_swig_ret int) { + return _swig_wrap_Animals_cheetahs__SWIG_0(arg1, arg2, arg3) +} + +var _wrap_Animals_cheetahs__SWIG_1 unsafe.Pointer + +func _swig_wrap_Animals_cheetahs__SWIG_1(base SwigcptrAnimals, _ int) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Animals_cheetahs__SWIG_1, _swig_p) + return +} + +func (arg1 SwigcptrAnimals) Cheetahs__SWIG_1(arg2 int) (_swig_ret int) { + return _swig_wrap_Animals_cheetahs__SWIG_1(arg1, arg2) +} + +var _wrap_Animals_cheetahs__SWIG_2 unsafe.Pointer + +func _swig_wrap_Animals_cheetahs__SWIG_2(base SwigcptrAnimals) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Animals_cheetahs__SWIG_2, _swig_p) + return +} + +func (arg1 SwigcptrAnimals) Cheetahs__SWIG_2() (_swig_ret int) { + return _swig_wrap_Animals_cheetahs__SWIG_2(arg1) +} + +func (p SwigcptrAnimals) Cheetahs(a ...interface{}) int { + argc := len(a) + if argc == 0 { + return p.Cheetahs__SWIG_2() + } + if argc == 1 { + return p.Cheetahs__SWIG_1(a[0].(int)) + } + if argc == 2 { + return p.Cheetahs__SWIG_0(a[0].(int), a[1].(float64)) + } + panic("No match for overloaded function call") +} + +var _wrap_Animals_jackal__SWIG_0 unsafe.Pointer + +func _swig_wrap_Animals_jackal__SWIG_0(base SwigcptrAnimals, _ int, _ float64) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Animals_jackal__SWIG_0, _swig_p) + return +} + +func (arg1 SwigcptrAnimals) Jackal__SWIG_0(arg2 int, arg3 float64) (_swig_ret int) { + return _swig_wrap_Animals_jackal__SWIG_0(arg1, arg2, arg3) +} + +var _wrap_Animals_jackal__SWIG_1 unsafe.Pointer + +func _swig_wrap_Animals_jackal__SWIG_1(base SwigcptrAnimals, _ int) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Animals_jackal__SWIG_1, _swig_p) + return +} + +func (arg1 SwigcptrAnimals) Jackal__SWIG_1(arg2 int) (_swig_ret int) { + return _swig_wrap_Animals_jackal__SWIG_1(arg1, arg2) +} + +var _wrap_Animals_jackal__SWIG_2 unsafe.Pointer + +func _swig_wrap_Animals_jackal__SWIG_2(base SwigcptrAnimals) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Animals_jackal__SWIG_2, _swig_p) + return +} + +func (arg1 SwigcptrAnimals) Jackal__SWIG_2() (_swig_ret int) { + return _swig_wrap_Animals_jackal__SWIG_2(arg1) +} + +func (p SwigcptrAnimals) Jackal(a ...interface{}) int { + argc := len(a) + if argc == 0 { + return p.Jackal__SWIG_2() + } + if argc == 1 { + return p.Jackal__SWIG_1(a[0].(int)) + } + if argc == 2 { + return p.Jackal__SWIG_0(a[0].(int), a[1].(float64)) + } + panic("No match for overloaded function call") +} + +var _wrap_delete_Animals unsafe.Pointer + +func _swig_wrap_delete_Animals(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Animals, _swig_p) + return +} + +func DeleteAnimals(arg1 Animals) { + _swig_wrap_delete_Animals(arg1.Swigcptr()) +} + +type Animals interface { + Swigcptr() uintptr + SwigIsAnimals() + Lions(a ...interface{}) uintptr + Leopards(a ...interface{}) uintptr + Cheetahs(a ...interface{}) int + Jackal(a ...interface{}) int +} + +type SwigcptrBase uintptr + +func (p SwigcptrBase) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrBase) SwigIsBase() { +} + +var _wrap_Base_virtualmethod unsafe.Pointer + +func _swig_wrap_Base_virtualmethod(base SwigcptrBase, _ int) (_ *string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Base_virtualmethod, _swig_p) + return +} + +func (arg1 SwigcptrBase) Virtualmethod(arg2 int) (_swig_ret *string) { + return _swig_wrap_Base_virtualmethod(arg1, arg2) +} + +var _wrap_delete_Base unsafe.Pointer + +func _swig_wrap_delete_Base(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Base, _swig_p) + return +} + +func DeleteBase(arg1 Base) { + _swig_wrap_delete_Base(arg1.Swigcptr()) +} + +var _wrap_new_Base unsafe.Pointer + +func _swig_wrap_new_Base() (base SwigcptrBase) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Base, _swig_p) + return +} + +func NewBase() (_swig_ret Base) { + return _swig_wrap_new_Base() +} + +type Base interface { + Swigcptr() uintptr + SwigIsBase() + Virtualmethod(arg2 int) (_swig_ret *string) +} + +type SwigcptrDerived uintptr + +func (p SwigcptrDerived) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrDerived) SwigIsDerived() { +} + +var _wrap_Derived_virtualmethod unsafe.Pointer + +func _swig_wrap_Derived_virtualmethod(base SwigcptrDerived, _ int) (_ *string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Derived_virtualmethod, _swig_p) + return +} + +func (arg1 SwigcptrDerived) Virtualmethod(arg2 int) (_swig_ret *string) { + return _swig_wrap_Derived_virtualmethod(arg1, arg2) +} + +var _wrap_new_Derived unsafe.Pointer + +func _swig_wrap_new_Derived() (base SwigcptrDerived) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Derived, _swig_p) + return +} + +func NewDerived() (_swig_ret Derived) { + return _swig_wrap_new_Derived() +} + +var _wrap_delete_Derived unsafe.Pointer + +func _swig_wrap_delete_Derived(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Derived, _swig_p) + return +} + +func DeleteDerived(arg1 Derived) { + _swig_wrap_delete_Derived(arg1.Swigcptr()) +} + +func (p SwigcptrDerived) SwigIsBase() { +} + +func (p SwigcptrDerived) SwigGetBase() Base { + return SwigcptrBase(p.Swigcptr()) +} + +type Derived interface { + Swigcptr() uintptr + SwigIsDerived() + Virtualmethod(arg2 int) (_swig_ret *string) + SwigIsBase() + SwigGetBase() Base +} + +type SwigcptrConversionOperators uintptr + +func (p SwigcptrConversionOperators) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrConversionOperators) SwigIsConversionOperators() { +} + +var _wrap_ConversionOperators_opbool unsafe.Pointer + +func _swig_wrap_ConversionOperators_opbool(base SwigcptrConversionOperators) (_ bool) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_ConversionOperators_opbool, _swig_p) + return +} + +func (arg1 SwigcptrConversionOperators) Opbool() (_swig_ret bool) { + return _swig_wrap_ConversionOperators_opbool(arg1) +} + +var _wrap_ConversionOperators_opuint unsafe.Pointer + +func _swig_wrap_ConversionOperators_opuint(base SwigcptrConversionOperators) (_ uint) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_ConversionOperators_opuint, _swig_p) + return +} + +func (arg1 SwigcptrConversionOperators) Opuint() (_swig_ret uint) { + return _swig_wrap_ConversionOperators_opuint(arg1) +} + +var _wrap_new_ConversionOperators unsafe.Pointer + +func _swig_wrap_new_ConversionOperators() (base SwigcptrConversionOperators) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_ConversionOperators, _swig_p) + return +} + +func NewConversionOperators() (_swig_ret ConversionOperators) { + return _swig_wrap_new_ConversionOperators() +} + +var _wrap_delete_ConversionOperators unsafe.Pointer + +func _swig_wrap_delete_ConversionOperators(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_ConversionOperators, _swig_p) + return +} + +func DeleteConversionOperators(arg1 ConversionOperators) { + _swig_wrap_delete_ConversionOperators(arg1.Swigcptr()) +} + +type ConversionOperators interface { + Swigcptr() uintptr + SwigIsConversionOperators() + Opbool() (_swig_ret bool) + Opuint() (_swig_ret uint) +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/fragments.go b/Examples/test-suite/go/fragments.go new file mode 100644 index 000000000..e76badf4e --- /dev/null +++ b/Examples/test-suite/go/fragments.go @@ -0,0 +1,43 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../fragments.i + +package fragments + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +var _wrap_bar unsafe.Pointer + +func Bar(arg1 int) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_bar, _swig_p) + return +} +var _wrap_foo unsafe.Pointer + +func Foo(arg1 int) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_foo, _swig_p) + return +} + diff --git a/Examples/test-suite/go/friends.go b/Examples/test-suite/go/friends.go new file mode 100644 index 000000000..e76c64350 --- /dev/null +++ b/Examples/test-suite/go/friends.go @@ -0,0 +1,451 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../friends.i + +package friends + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +var _wrap_globalscope unsafe.Pointer + +func _swig_wrap_globalscope() { + var _swig_p uintptr + _cgo_runtime_cgocall(_wrap_globalscope, _swig_p) + return +} + +func Globalscope() { + _swig_wrap_globalscope() +} + +type SwigcptrB uintptr + +func (p SwigcptrB) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrB) SwigIsB() { +} + +var _wrap_new_B unsafe.Pointer + +func _swig_wrap_new_B(base int) (_ SwigcptrB) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_B, _swig_p) + return +} + +func NewB(arg1 int) (_swig_ret B) { + return _swig_wrap_new_B(arg1) +} + +var _wrap_mix unsafe.Pointer + +func _swig_wrap_mix(base uintptr, _ uintptr) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_mix, _swig_p) + return +} + +func Mix(arg1 A, arg2 B) (_swig_ret int) { + return _swig_wrap_mix(arg1.Swigcptr(), arg2.Swigcptr()) +} + +var _wrap_delete_B unsafe.Pointer + +func _swig_wrap_delete_B(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_B, _swig_p) + return +} + +func DeleteB(arg1 B) { + _swig_wrap_delete_B(arg1.Swigcptr()) +} + +type B interface { + Swigcptr() uintptr + SwigIsB() +} + +type SwigcptrA uintptr + +func (p SwigcptrA) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrA) SwigIsA() { +} + +var _wrap_new_A unsafe.Pointer + +func _swig_wrap_new_A(base int) (_ SwigcptrA) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_A, _swig_p) + return +} + +func NewA(arg1 int) (_swig_ret A) { + return _swig_wrap_new_A(arg1) +} + +var _wrap_get_val1__SWIG_0 unsafe.Pointer + +func _swig_wrap_get_val1__SWIG_0(base uintptr) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_get_val1__SWIG_0, _swig_p) + return +} + +func Get_val1__SWIG_0(arg1 A) (_swig_ret int) { + return _swig_wrap_get_val1__SWIG_0(arg1.Swigcptr()) +} + +var _wrap_get_val1__SWIG_1 unsafe.Pointer + +func _swig_wrap_get_val1__SWIG_1(base uintptr, _ int) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_get_val1__SWIG_1, _swig_p) + return +} + +func Get_val1__SWIG_1(arg1 A, arg2 int) (_swig_ret int) { + return _swig_wrap_get_val1__SWIG_1(arg1.Swigcptr(), arg2) +} + +var _wrap_get_val2 unsafe.Pointer + +func _swig_wrap_get_val2(base uintptr) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_get_val2, _swig_p) + return +} + +func Get_val2(arg1 A) (_swig_ret int) { + return _swig_wrap_get_val2(arg1.Swigcptr()) +} + +var _wrap_get_val3 unsafe.Pointer + +func _swig_wrap_get_val3(base uintptr) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_get_val3, _swig_p) + return +} + +func Get_val3(arg1 A) (_swig_ret int) { + return _swig_wrap_get_val3(arg1.Swigcptr()) +} + +var _wrap_delete_A unsafe.Pointer + +func _swig_wrap_delete_A(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_A, _swig_p) + return +} + +func DeleteA(arg1 A) { + _swig_wrap_delete_A(arg1.Swigcptr()) +} + +type A interface { + Swigcptr() uintptr + SwigIsA() +} + +var _wrap_get_val1__SWIG_2 unsafe.Pointer + +func Get_val1__SWIG_2(arg1 int, arg2 int, arg3 int) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_get_val1__SWIG_2, _swig_p) + return +} +var _wrap_bas unsafe.Pointer + +func _swig_wrap_bas() { + var _swig_p uintptr + _cgo_runtime_cgocall(_wrap_bas, _swig_p) + return +} + +func Bas() { + _swig_wrap_bas() +} + +var _wrap_baz unsafe.Pointer + +func _swig_wrap_baz() { + var _swig_p uintptr + _cgo_runtime_cgocall(_wrap_baz, _swig_p) + return +} + +func Baz() { + _swig_wrap_baz() +} + +type SwigcptrFoo uintptr + +func (p SwigcptrFoo) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrFoo) SwigIsFoo() { +} + +var _wrap_new_Foo unsafe.Pointer + +func _swig_wrap_new_Foo() (base SwigcptrFoo) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Foo, _swig_p) + return +} + +func NewFoo() (_swig_ret Foo) { + return _swig_wrap_new_Foo() +} + +var _wrap_Foo_member unsafe.Pointer + +func _swig_wrap_Foo_member(base SwigcptrFoo) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_member, _swig_p) + return +} + +func (arg1 SwigcptrFoo) Member() { + _swig_wrap_Foo_member(arg1) +} + +var _wrap_delete_Foo unsafe.Pointer + +func _swig_wrap_delete_Foo(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Foo, _swig_p) + return +} + +func DeleteFoo(arg1 Foo) { + _swig_wrap_delete_Foo(arg1.Swigcptr()) +} + +type Foo interface { + Swigcptr() uintptr + SwigIsFoo() + Member() +} + +var _wrap_bar unsafe.Pointer + +func _swig_wrap_bar() { + var _swig_p uintptr + _cgo_runtime_cgocall(_wrap_bar, _swig_p) + return +} + +func Bar() { + _swig_wrap_bar() +} + +type SwigcptrD_i uintptr + +func (p SwigcptrD_i) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrD_i) SwigIsD_i() { +} + +var _wrap_new_D_i unsafe.Pointer + +func _swig_wrap_new_D_i(base int) (_ SwigcptrD_i) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_D_i, _swig_p) + return +} + +func NewD_i(arg1 int) (_swig_ret D_i) { + return _swig_wrap_new_D_i(arg1) +} + +var _wrap_get_val1__SWIG_4 unsafe.Pointer + +func _swig_wrap_get_val1__SWIG_4(base uintptr) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_get_val1__SWIG_4, _swig_p) + return +} + +func Get_val1__SWIG_4(arg1 D_i) (_swig_ret int) { + return _swig_wrap_get_val1__SWIG_4(arg1.Swigcptr()) +} + +var _wrap_set__SWIG_1 unsafe.Pointer + +func _swig_wrap_set__SWIG_1(base uintptr, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_set__SWIG_1, _swig_p) + return +} + +func Set__SWIG_1(arg1 D_i, arg2 int) { + _swig_wrap_set__SWIG_1(arg1.Swigcptr(), arg2) +} + +var _wrap_delete_D_i unsafe.Pointer + +func _swig_wrap_delete_D_i(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_D_i, _swig_p) + return +} + +func DeleteD_i(arg1 D_i) { + _swig_wrap_delete_D_i(arg1.Swigcptr()) +} + +type D_i interface { + Swigcptr() uintptr + SwigIsD_i() +} + +type SwigcptrD_d uintptr + +func (p SwigcptrD_d) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrD_d) SwigIsD_d() { +} + +var _wrap_new_D_d unsafe.Pointer + +func _swig_wrap_new_D_d(base float64) (_ SwigcptrD_d) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_D_d, _swig_p) + return +} + +func NewD_d(arg1 float64) (_swig_ret D_d) { + return _swig_wrap_new_D_d(arg1) +} + +var _wrap_get_val1__SWIG_5 unsafe.Pointer + +func _swig_wrap_get_val1__SWIG_5(base uintptr) (_ float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_get_val1__SWIG_5, _swig_p) + return +} + +func Get_val1__SWIG_5(arg1 D_d) (_swig_ret float64) { + return _swig_wrap_get_val1__SWIG_5(arg1.Swigcptr()) +} + +func Get_val1(a ...interface{}) interface{} { + argc := len(a) + if argc == 1 { + if _, ok := a[0].(A); !ok { + goto check_1 + } + return Get_val1__SWIG_0(a[0].(A)) + } +check_1: + if argc == 1 { + if _, ok := a[0].(D_i); !ok { + goto check_2 + } + return Get_val1__SWIG_4(a[0].(D_i)) + } +check_2: + if argc == 1 { + return Get_val1__SWIG_5(a[0].(D_d)) + } + if argc == 2 { + return Get_val1__SWIG_1(a[0].(A), a[1].(int)) + } + if argc == 3 { + return Get_val1__SWIG_2(a[0].(int), a[1].(int), a[2].(int)) + } + panic("No match for overloaded function call") +} + +var _wrap_set__SWIG_2 unsafe.Pointer + +func _swig_wrap_set__SWIG_2(base uintptr, _ float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_set__SWIG_2, _swig_p) + return +} + +func Set__SWIG_2(arg1 D_d, arg2 float64) { + _swig_wrap_set__SWIG_2(arg1.Swigcptr(), arg2) +} + +func Set(a ...interface{}) { + argc := len(a) + if argc == 2 { + if _, ok := a[0].(D_i); !ok { + goto check_1 + } + if _, ok := a[1].(int); !ok { + goto check_1 + } + Set__SWIG_1(a[0].(D_i), a[1].(int)) + return + } +check_1: + if argc == 2 { + Set__SWIG_2(a[0].(D_d), a[1].(float64)) + return + } + panic("No match for overloaded function call") +} + +var _wrap_delete_D_d unsafe.Pointer + +func _swig_wrap_delete_D_d(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_D_d, _swig_p) + return +} + +func DeleteD_d(arg1 D_d) { + _swig_wrap_delete_D_d(arg1.Swigcptr()) +} + +type D_d interface { + Swigcptr() uintptr + SwigIsD_d() +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/friends_runme b/Examples/test-suite/go/friends_runme new file mode 100755 index 000000000..d5ece09c3 Binary files /dev/null and b/Examples/test-suite/go/friends_runme differ diff --git a/Examples/test-suite/go/funcptr.go b/Examples/test-suite/go/funcptr.go new file mode 100644 index 000000000..0d9be944f --- /dev/null +++ b/Examples/test-suite/go/funcptr.go @@ -0,0 +1,338 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../funcptr.i + +package funcptr + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +var _wrap_distance unsafe.Pointer + +func _swig_wrap_distance(base *float64, _ *int, _ *_swig_fnptr, _ *float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_distance, _swig_p) + return +} + +func Distance(arg1 *float64, arg2 *int, arg3 *_swig_fnptr, arg4 *float64) { + _swig_wrap_distance(arg1, arg2, arg3, arg4) +} + +var _wrap_do_op unsafe.Pointer + +func Do_op(arg1 int, arg2 int, arg3 _swig_fnptr) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_do_op, _swig_p) + return +} +var _wrap_add unsafe.Pointer + +func Add(arg1 int, arg2 int) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_add, _swig_p) + return +} +var _wrap_subtract unsafe.Pointer + +func Subtract(arg1 int, arg2 int) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_subtract, _swig_p) + return +} +var _wrap_multiply unsafe.Pointer + +func Multiply(arg1 int, arg2 int) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_multiply, _swig_p) + return +} +var _wrap_nowt unsafe.Pointer + +func Nowt() (_swig_ret *int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_nowt, _swig_p) + return +} +var _wrap_nowt2 unsafe.Pointer + +func Nowt2() (_swig_ret *int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_nowt2, _swig_p) + return +} +type SwigcptrMyStruct uintptr + +func (p SwigcptrMyStruct) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrMyStruct) SwigIsMyStruct() { +} + +var _wrap_MyStruct_i_set unsafe.Pointer + +func _swig_wrap_MyStruct_i_set(base SwigcptrMyStruct, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_MyStruct_i_set, _swig_p) + return +} + +func (arg1 SwigcptrMyStruct) SetI(arg2 int) { + _swig_wrap_MyStruct_i_set(arg1, arg2) +} + +var _wrap_MyStruct_i_get unsafe.Pointer + +func _swig_wrap_MyStruct_i_get(base SwigcptrMyStruct) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_MyStruct_i_get, _swig_p) + return +} + +func (arg1 SwigcptrMyStruct) GetI() (_swig_ret int) { + return _swig_wrap_MyStruct_i_get(arg1) +} + +var _wrap_new_MyStruct unsafe.Pointer + +func _swig_wrap_new_MyStruct() (base SwigcptrMyStruct) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_MyStruct, _swig_p) + return +} + +func NewMyStruct() (_swig_ret MyStruct) { + return _swig_wrap_new_MyStruct() +} + +var _wrap_delete_MyStruct unsafe.Pointer + +func _swig_wrap_delete_MyStruct(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_MyStruct, _swig_p) + return +} + +func DeleteMyStruct(arg1 MyStruct) { + _swig_wrap_delete_MyStruct(arg1.Swigcptr()) +} + +type MyStruct interface { + Swigcptr() uintptr + SwigIsMyStruct() + SetI(arg2 int) + GetI() (_swig_ret int) +} + +var _wrap_mystructptr unsafe.Pointer + +func _swig_wrap_mystructptr() (base SwigcptrMyStruct) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_mystructptr, _swig_p) + return +} + +func Mystructptr() (_swig_ret MyStruct) { + return _swig_wrap_mystructptr() +} + +var _wrap_funcvar_set unsafe.Pointer + +func _swig_wrap_funcvar_set(base _swig_fnptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_funcvar_set, _swig_p) + return +} + +func SetFuncvar(arg1 _swig_fnptr) { + _swig_wrap_funcvar_set(arg1) +} + +var _wrap_funcvar_get unsafe.Pointer + +func GetFuncvar() (_swig_ret _swig_fnptr) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_funcvar_get, _swig_p) + return +} +var _wrap_funcvar2_set unsafe.Pointer + +func _swig_wrap_funcvar2_set(base _swig_fnptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_funcvar2_set, _swig_p) + return +} + +func SetFuncvar2(arg1 _swig_fnptr) { + _swig_wrap_funcvar2_set(arg1) +} + +var _wrap_funcvar2_get unsafe.Pointer + +func GetFuncvar2() (_swig_ret _swig_fnptr) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_funcvar2_get, _swig_p) + return +} +var _wrap_funcvar3_set unsafe.Pointer + +func _swig_wrap_funcvar3_set(base _swig_fnptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_funcvar3_set, _swig_p) + return +} + +func SetFuncvar3(arg1 _swig_fnptr) { + _swig_wrap_funcvar3_set(arg1) +} + +var _wrap_funcvar3_get unsafe.Pointer + +func GetFuncvar3() (_swig_ret _swig_fnptr) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_funcvar3_get, _swig_p) + return +} +var _wrap_funcvar4_set unsafe.Pointer + +func _swig_wrap_funcvar4_set(base _swig_fnptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_funcvar4_set, _swig_p) + return +} + +func SetFuncvar4(arg1 _swig_fnptr) { + _swig_wrap_funcvar4_set(arg1) +} + +var _wrap_funcvar4_get unsafe.Pointer + +func GetFuncvar4() (_swig_ret _swig_fnptr) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_funcvar4_get, _swig_p) + return +} +var _wrap_funcvar5_set unsafe.Pointer + +func _swig_wrap_funcvar5_set(base _swig_fnptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_funcvar5_set, _swig_p) + return +} + +func SetFuncvar5(arg1 _swig_fnptr) { + _swig_wrap_funcvar5_set(arg1) +} + +var _wrap_funcvar5_get unsafe.Pointer + +func GetFuncvar5() (_swig_ret _swig_fnptr) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_funcvar5_get, _swig_p) + return +} +var _wrap_pfunc0_set unsafe.Pointer + +func _swig_wrap_pfunc0_set(base _swig_fnptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_pfunc0_set, _swig_p) + return +} + +func SetPfunc0(arg1 _swig_fnptr) { + _swig_wrap_pfunc0_set(arg1) +} + +var _wrap_pfunc0_get unsafe.Pointer + +func GetPfunc0() (_swig_ret _swig_fnptr) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_pfunc0_get, _swig_p) + return +} +var _wrap_pfuncA_set unsafe.Pointer + +func _swig_wrap_pfuncA_set(base _swig_fnptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_pfuncA_set, _swig_p) + return +} + +func SetPfuncA(arg1 _swig_fnptr) { + _swig_wrap_pfuncA_set(arg1) +} + +var _wrap_pfuncA_get unsafe.Pointer + +func GetPfuncA() (_swig_ret _swig_fnptr) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_pfuncA_get, _swig_p) + return +} +var _wrap_pfunc1_set unsafe.Pointer + +func _swig_wrap_pfunc1_set(base _swig_fnptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_pfunc1_set, _swig_p) + return +} + +func SetPfunc1(arg1 _swig_fnptr) { + _swig_wrap_pfunc1_set(arg1) +} + +var _wrap_pfunc1_get unsafe.Pointer + +func GetPfunc1() (_swig_ret _swig_fnptr) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_pfunc1_get, _swig_p) + return +} +var _wrap_pfunc2_set unsafe.Pointer + +func _swig_wrap_pfunc2_set(base _swig_fnptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_pfunc2_set, _swig_p) + return +} + +func SetPfunc2(arg1 _swig_fnptr) { + _swig_wrap_pfunc2_set(arg1) +} + +var _wrap_pfunc2_get unsafe.Pointer + +func GetPfunc2() (_swig_ret _swig_fnptr) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_pfunc2_get, _swig_p) + return +} + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/funcptr_cpp.go b/Examples/test-suite/go/funcptr_cpp.go new file mode 100644 index 000000000..0071b7072 --- /dev/null +++ b/Examples/test-suite/go/funcptr_cpp.go @@ -0,0 +1,116 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../funcptr_cpp.i + +package funcptr_cpp + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +var _wrap_addByValue unsafe.Pointer + +func AddByValue(arg1 int, arg2 int) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_addByValue, _swig_p) + return +} +var _wrap_addByPointer unsafe.Pointer + +func AddByPointer(arg1 int, arg2 int) (_swig_ret *int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_addByPointer, _swig_p) + return +} +var _wrap_addByReference unsafe.Pointer + +func AddByReference(arg1 int, arg2 int) (_swig_ret *int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_addByReference, _swig_p) + return +} +var _wrap_call1 unsafe.Pointer + +func Call1(arg1 _swig_fnptr, arg2 int, arg3 int) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_call1, _swig_p) + return +} +var _wrap_call2 unsafe.Pointer + +func Call2(arg1 _swig_fnptr, arg2 int, arg3 int) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_call2, _swig_p) + return +} +var _wrap_call3 unsafe.Pointer + +func Call3(arg1 _swig_fnptr, arg2 int, arg3 int) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_call3, _swig_p) + return +} +var _wrap_ADD_BY_VALUE unsafe.Pointer + +func _swig_getADD_BY_VALUE() (_swig_ret _swig_fnptr) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_ADD_BY_VALUE, _swig_p) + return +} +var ADD_BY_VALUE _swig_fnptr = _swig_getADD_BY_VALUE() +var _wrap_ADD_BY_POINTER unsafe.Pointer + +func _swig_getADD_BY_POINTER() (_swig_ret _swig_fnptr) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_ADD_BY_POINTER, _swig_p) + return +} +var ADD_BY_POINTER _swig_fnptr = _swig_getADD_BY_POINTER() +var _wrap_ADD_BY_REFERENCE unsafe.Pointer + +func _swig_getADD_BY_REFERENCE() (_swig_ret _swig_fnptr) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_ADD_BY_REFERENCE, _swig_p) + return +} +var ADD_BY_REFERENCE _swig_fnptr = _swig_getADD_BY_REFERENCE() +var _wrap_typedef_call1 unsafe.Pointer + +func Typedef_call1(arg1 *_swig_fnptr, arg2 *_swig_fnptr) (_swig_ret uintptr) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_typedef_call1, _swig_p) + return +} +var _wrap_typedef_call2 unsafe.Pointer + +func Typedef_call2(arg1 *_swig_fnptr, arg2 *_swig_fnptr) (_swig_ret uintptr) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_typedef_call2, _swig_p) + return +} +var _wrap_typedef_call3 unsafe.Pointer + +func Typedef_call3(arg1 *_swig_fnptr, arg2 *_swig_fnptr) (_swig_ret uintptr) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_typedef_call3, _swig_p) + return +} + diff --git a/Examples/test-suite/go/function_typedef.go b/Examples/test-suite/go/function_typedef.go new file mode 100644 index 000000000..1d8cfcf25 --- /dev/null +++ b/Examples/test-suite/go/function_typedef.go @@ -0,0 +1,50 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../function_typedef.i + +package function_typedef + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +var _wrap_do_binop1 unsafe.Pointer + +func Do_binop1(arg1 *_swig_fnptr, arg2 int, arg3 int) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_do_binop1, _swig_p) + return +} +var _wrap_do_binop2 unsafe.Pointer + +func Do_binop2(arg1 *_swig_fnptr, arg2 int, arg3 int) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_do_binop2, _swig_p) + return +} +var _wrap_do_binop3 unsafe.Pointer + +func Do_binop3(arg1 _swig_fnptr, arg2 int, arg3 int) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_do_binop3, _swig_p) + return +} + diff --git a/Examples/test-suite/go/fvirtual.go b/Examples/test-suite/go/fvirtual.go new file mode 100644 index 000000000..1048e8b7d --- /dev/null +++ b/Examples/test-suite/go/fvirtual.go @@ -0,0 +1,171 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../fvirtual.i + +package fvirtual + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrNode uintptr + +func (p SwigcptrNode) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrNode) SwigIsNode() { +} + +var _wrap_Node_addChild unsafe.Pointer + +func _swig_wrap_Node_addChild(base SwigcptrNode, _ uintptr) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Node_addChild, _swig_p) + return +} + +func (arg1 SwigcptrNode) AddChild(arg2 Node) (_swig_ret int) { + return _swig_wrap_Node_addChild(arg1, arg2.Swigcptr()) +} + +var _wrap_delete_Node unsafe.Pointer + +func _swig_wrap_delete_Node(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Node, _swig_p) + return +} + +func DeleteNode(arg1 Node) { + _swig_wrap_delete_Node(arg1.Swigcptr()) +} + +var _wrap_new_Node unsafe.Pointer + +func _swig_wrap_new_Node() (base SwigcptrNode) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Node, _swig_p) + return +} + +func NewNode() (_swig_ret Node) { + return _swig_wrap_new_Node() +} + +type Node interface { + Swigcptr() uintptr + SwigIsNode() + AddChild(arg2 Node) (_swig_ret int) +} + +type SwigcptrNodeSwitch uintptr + +func (p SwigcptrNodeSwitch) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrNodeSwitch) SwigIsNodeSwitch() { +} + +var _wrap_NodeSwitch_addChild__SWIG_0 unsafe.Pointer + +func _swig_wrap_NodeSwitch_addChild__SWIG_0(base SwigcptrNodeSwitch, _ uintptr) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_NodeSwitch_addChild__SWIG_0, _swig_p) + return +} + +func (arg1 SwigcptrNodeSwitch) AddChild__SWIG_0(arg2 Node) (_swig_ret int) { + return _swig_wrap_NodeSwitch_addChild__SWIG_0(arg1, arg2.Swigcptr()) +} + +var _wrap_NodeSwitch_addChild__SWIG_1 unsafe.Pointer + +func _swig_wrap_NodeSwitch_addChild__SWIG_1(base SwigcptrNodeSwitch, _ uintptr, _ bool) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_NodeSwitch_addChild__SWIG_1, _swig_p) + return +} + +func (arg1 SwigcptrNodeSwitch) AddChild__SWIG_1(arg2 Node, arg3 bool) (_swig_ret int) { + return _swig_wrap_NodeSwitch_addChild__SWIG_1(arg1, arg2.Swigcptr(), arg3) +} + +func (p SwigcptrNodeSwitch) AddChild(a ...interface{}) int { + argc := len(a) + if argc == 1 { + return p.AddChild__SWIG_0(a[0].(Node)) + } + if argc == 2 { + return p.AddChild__SWIG_1(a[0].(Node), a[1].(bool)) + } + panic("No match for overloaded function call") +} + +var _wrap_delete_NodeSwitch unsafe.Pointer + +func _swig_wrap_delete_NodeSwitch(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_NodeSwitch, _swig_p) + return +} + +func DeleteNodeSwitch(arg1 NodeSwitch) { + _swig_wrap_delete_NodeSwitch(arg1.Swigcptr()) +} + +var _wrap_new_NodeSwitch unsafe.Pointer + +func _swig_wrap_new_NodeSwitch() (base SwigcptrNodeSwitch) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_NodeSwitch, _swig_p) + return +} + +func NewNodeSwitch() (_swig_ret NodeSwitch) { + return _swig_wrap_new_NodeSwitch() +} + +func (p SwigcptrNodeSwitch) SwigIsNode() { +} + +func (p SwigcptrNodeSwitch) SwigGetNode() Node { + return SwigcptrNode(p.Swigcptr()) +} + +type NodeSwitch interface { + Swigcptr() uintptr + SwigIsNodeSwitch() + AddChild(a ...interface{}) int + SwigIsNode() + SwigGetNode() Node +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/fvirtual_runme b/Examples/test-suite/go/fvirtual_runme new file mode 100755 index 000000000..5b9ade236 Binary files /dev/null and b/Examples/test-suite/go/fvirtual_runme differ diff --git a/Examples/test-suite/go/global_functions.go b/Examples/test-suite/go/global_functions.go new file mode 100644 index 000000000..efb347421 --- /dev/null +++ b/Examples/test-suite/go/global_functions.go @@ -0,0 +1,63 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../global_functions.i + +package global_functions + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +var _wrap_global_void unsafe.Pointer + +func _swig_wrap_global_void() { + var _swig_p uintptr + _cgo_runtime_cgocall(_wrap_global_void, _swig_p) + return +} + +func Global_void() { + _swig_wrap_global_void() +} + +var _wrap_global_one unsafe.Pointer + +func Global_one(arg1 int) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_global_one, _swig_p) + return +} +var _wrap_global_two unsafe.Pointer + +func Global_two(arg1 int, arg2 int) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_global_two, _swig_p) + return +} + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/global_namespace.go b/Examples/test-suite/go/global_namespace.go new file mode 100644 index 000000000..7ba3e2f8f --- /dev/null +++ b/Examples/test-suite/go/global_namespace.go @@ -0,0 +1,1039 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../global_namespace.i + +package global_namespace + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrKlass1 uintptr + +func (p SwigcptrKlass1) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrKlass1) SwigIsKlass1() { +} + +var _wrap_new_Klass1 unsafe.Pointer + +func _swig_wrap_new_Klass1() (base SwigcptrKlass1) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Klass1, _swig_p) + return +} + +func NewKlass1() (_swig_ret Klass1) { + return _swig_wrap_new_Klass1() +} + +var _wrap_delete_Klass1 unsafe.Pointer + +func _swig_wrap_delete_Klass1(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Klass1, _swig_p) + return +} + +func DeleteKlass1(arg1 Klass1) { + _swig_wrap_delete_Klass1(arg1.Swigcptr()) +} + +type Klass1 interface { + Swigcptr() uintptr + SwigIsKlass1() +} + +type SwigcptrKlass2 uintptr + +func (p SwigcptrKlass2) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrKlass2) SwigIsKlass2() { +} + +var _wrap_new_Klass2 unsafe.Pointer + +func _swig_wrap_new_Klass2() (base SwigcptrKlass2) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Klass2, _swig_p) + return +} + +func NewKlass2() (_swig_ret Klass2) { + return _swig_wrap_new_Klass2() +} + +var _wrap_delete_Klass2 unsafe.Pointer + +func _swig_wrap_delete_Klass2(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Klass2, _swig_p) + return +} + +func DeleteKlass2(arg1 Klass2) { + _swig_wrap_delete_Klass2(arg1.Swigcptr()) +} + +type Klass2 interface { + Swigcptr() uintptr + SwigIsKlass2() +} + +type SwigcptrKlass3 uintptr + +func (p SwigcptrKlass3) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrKlass3) SwigIsKlass3() { +} + +var _wrap_new_Klass3 unsafe.Pointer + +func _swig_wrap_new_Klass3() (base SwigcptrKlass3) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Klass3, _swig_p) + return +} + +func NewKlass3() (_swig_ret Klass3) { + return _swig_wrap_new_Klass3() +} + +var _wrap_delete_Klass3 unsafe.Pointer + +func _swig_wrap_delete_Klass3(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Klass3, _swig_p) + return +} + +func DeleteKlass3(arg1 Klass3) { + _swig_wrap_delete_Klass3(arg1.Swigcptr()) +} + +type Klass3 interface { + Swigcptr() uintptr + SwigIsKlass3() +} + +type SwigcptrKlass4 uintptr + +func (p SwigcptrKlass4) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrKlass4) SwigIsKlass4() { +} + +var _wrap_new_Klass4 unsafe.Pointer + +func _swig_wrap_new_Klass4() (base SwigcptrKlass4) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Klass4, _swig_p) + return +} + +func NewKlass4() (_swig_ret Klass4) { + return _swig_wrap_new_Klass4() +} + +var _wrap_delete_Klass4 unsafe.Pointer + +func _swig_wrap_delete_Klass4(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Klass4, _swig_p) + return +} + +func DeleteKlass4(arg1 Klass4) { + _swig_wrap_delete_Klass4(arg1.Swigcptr()) +} + +type Klass4 interface { + Swigcptr() uintptr + SwigIsKlass4() +} + +type SwigcptrKlass5 uintptr + +func (p SwigcptrKlass5) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrKlass5) SwigIsKlass5() { +} + +var _wrap_new_Klass5 unsafe.Pointer + +func _swig_wrap_new_Klass5() (base SwigcptrKlass5) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Klass5, _swig_p) + return +} + +func NewKlass5() (_swig_ret Klass5) { + return _swig_wrap_new_Klass5() +} + +var _wrap_delete_Klass5 unsafe.Pointer + +func _swig_wrap_delete_Klass5(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Klass5, _swig_p) + return +} + +func DeleteKlass5(arg1 Klass5) { + _swig_wrap_delete_Klass5(arg1.Swigcptr()) +} + +type Klass5 interface { + Swigcptr() uintptr + SwigIsKlass5() +} + +type SwigcptrKlass6 uintptr + +func (p SwigcptrKlass6) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrKlass6) SwigIsKlass6() { +} + +var _wrap_new_Klass6 unsafe.Pointer + +func _swig_wrap_new_Klass6() (base SwigcptrKlass6) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Klass6, _swig_p) + return +} + +func NewKlass6() (_swig_ret Klass6) { + return _swig_wrap_new_Klass6() +} + +var _wrap_delete_Klass6 unsafe.Pointer + +func _swig_wrap_delete_Klass6(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Klass6, _swig_p) + return +} + +func DeleteKlass6(arg1 Klass6) { + _swig_wrap_delete_Klass6(arg1.Swigcptr()) +} + +type Klass6 interface { + Swigcptr() uintptr + SwigIsKlass6() +} + +type SwigcptrKlass7 uintptr + +func (p SwigcptrKlass7) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrKlass7) SwigIsKlass7() { +} + +var _wrap_new_Klass7 unsafe.Pointer + +func _swig_wrap_new_Klass7() (base SwigcptrKlass7) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Klass7, _swig_p) + return +} + +func NewKlass7() (_swig_ret Klass7) { + return _swig_wrap_new_Klass7() +} + +var _wrap_delete_Klass7 unsafe.Pointer + +func _swig_wrap_delete_Klass7(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Klass7, _swig_p) + return +} + +func DeleteKlass7(arg1 Klass7) { + _swig_wrap_delete_Klass7(arg1.Swigcptr()) +} + +type Klass7 interface { + Swigcptr() uintptr + SwigIsKlass7() +} + +type SwigcptrKlassMethods uintptr + +func (p SwigcptrKlassMethods) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrKlassMethods) SwigIsKlassMethods() { +} + +var _wrap_KlassMethods_methodA unsafe.Pointer + +func _swig_wrap_KlassMethods_methodA(base uintptr, _ uintptr, _ uintptr, _ uintptr, _ uintptr, _ uintptr, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_KlassMethods_methodA, _swig_p) + return +} + +func KlassMethodsMethodA(arg1 Klass1, arg2 Klass2, arg3 Klass3, arg4 Klass4, arg5 Klass5, arg6 Klass6, arg7 Klass7) { + _swig_wrap_KlassMethods_methodA(arg1.Swigcptr(), arg2.Swigcptr(), arg3.Swigcptr(), arg4.Swigcptr(), arg5.Swigcptr(), arg6.Swigcptr(), arg7.Swigcptr()) +} + +var _wrap_KlassMethods_methodB unsafe.Pointer + +func _swig_wrap_KlassMethods_methodB(base uintptr, _ uintptr, _ uintptr, _ uintptr, _ uintptr, _ uintptr, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_KlassMethods_methodB, _swig_p) + return +} + +func KlassMethodsMethodB(arg1 Klass1, arg2 Klass2, arg3 Klass3, arg4 Klass4, arg5 Klass5, arg6 Klass6, arg7 Klass7) { + _swig_wrap_KlassMethods_methodB(arg1.Swigcptr(), arg2.Swigcptr(), arg3.Swigcptr(), arg4.Swigcptr(), arg5.Swigcptr(), arg6.Swigcptr(), arg7.Swigcptr()) +} + +var _wrap_new_KlassMethods unsafe.Pointer + +func _swig_wrap_new_KlassMethods() (base SwigcptrKlassMethods) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_KlassMethods, _swig_p) + return +} + +func NewKlassMethods() (_swig_ret KlassMethods) { + return _swig_wrap_new_KlassMethods() +} + +var _wrap_delete_KlassMethods unsafe.Pointer + +func _swig_wrap_delete_KlassMethods(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_KlassMethods, _swig_p) + return +} + +func DeleteKlassMethods(arg1 KlassMethods) { + _swig_wrap_delete_KlassMethods(arg1.Swigcptr()) +} + +type KlassMethods interface { + Swigcptr() uintptr + SwigIsKlassMethods() +} + +type SwigcptrXYZ1 uintptr + +func (p SwigcptrXYZ1) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrXYZ1) SwigIsXYZ1() { +} + +var _wrap_new_XYZ1 unsafe.Pointer + +func _swig_wrap_new_XYZ1() (base SwigcptrXYZ1) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_XYZ1, _swig_p) + return +} + +func NewXYZ1() (_swig_ret XYZ1) { + return _swig_wrap_new_XYZ1() +} + +var _wrap_delete_XYZ1 unsafe.Pointer + +func _swig_wrap_delete_XYZ1(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_XYZ1, _swig_p) + return +} + +func DeleteXYZ1(arg1 XYZ1) { + _swig_wrap_delete_XYZ1(arg1.Swigcptr()) +} + +type XYZ1 interface { + Swigcptr() uintptr + SwigIsXYZ1() +} + +type SwigcptrXYZ2 uintptr + +func (p SwigcptrXYZ2) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrXYZ2) SwigIsXYZ2() { +} + +var _wrap_new_XYZ2 unsafe.Pointer + +func _swig_wrap_new_XYZ2() (base SwigcptrXYZ2) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_XYZ2, _swig_p) + return +} + +func NewXYZ2() (_swig_ret XYZ2) { + return _swig_wrap_new_XYZ2() +} + +var _wrap_delete_XYZ2 unsafe.Pointer + +func _swig_wrap_delete_XYZ2(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_XYZ2, _swig_p) + return +} + +func DeleteXYZ2(arg1 XYZ2) { + _swig_wrap_delete_XYZ2(arg1.Swigcptr()) +} + +type XYZ2 interface { + Swigcptr() uintptr + SwigIsXYZ2() +} + +type SwigcptrXYZ3 uintptr + +func (p SwigcptrXYZ3) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrXYZ3) SwigIsXYZ3() { +} + +var _wrap_new_XYZ3 unsafe.Pointer + +func _swig_wrap_new_XYZ3() (base SwigcptrXYZ3) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_XYZ3, _swig_p) + return +} + +func NewXYZ3() (_swig_ret XYZ3) { + return _swig_wrap_new_XYZ3() +} + +var _wrap_delete_XYZ3 unsafe.Pointer + +func _swig_wrap_delete_XYZ3(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_XYZ3, _swig_p) + return +} + +func DeleteXYZ3(arg1 XYZ3) { + _swig_wrap_delete_XYZ3(arg1.Swigcptr()) +} + +type XYZ3 interface { + Swigcptr() uintptr + SwigIsXYZ3() +} + +type SwigcptrXYZ4 uintptr + +func (p SwigcptrXYZ4) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrXYZ4) SwigIsXYZ4() { +} + +var _wrap_new_XYZ4 unsafe.Pointer + +func _swig_wrap_new_XYZ4() (base SwigcptrXYZ4) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_XYZ4, _swig_p) + return +} + +func NewXYZ4() (_swig_ret XYZ4) { + return _swig_wrap_new_XYZ4() +} + +var _wrap_delete_XYZ4 unsafe.Pointer + +func _swig_wrap_delete_XYZ4(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_XYZ4, _swig_p) + return +} + +func DeleteXYZ4(arg1 XYZ4) { + _swig_wrap_delete_XYZ4(arg1.Swigcptr()) +} + +type XYZ4 interface { + Swigcptr() uintptr + SwigIsXYZ4() +} + +type SwigcptrXYZ5 uintptr + +func (p SwigcptrXYZ5) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrXYZ5) SwigIsXYZ5() { +} + +var _wrap_new_XYZ5 unsafe.Pointer + +func _swig_wrap_new_XYZ5() (base SwigcptrXYZ5) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_XYZ5, _swig_p) + return +} + +func NewXYZ5() (_swig_ret XYZ5) { + return _swig_wrap_new_XYZ5() +} + +var _wrap_delete_XYZ5 unsafe.Pointer + +func _swig_wrap_delete_XYZ5(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_XYZ5, _swig_p) + return +} + +func DeleteXYZ5(arg1 XYZ5) { + _swig_wrap_delete_XYZ5(arg1.Swigcptr()) +} + +type XYZ5 interface { + Swigcptr() uintptr + SwigIsXYZ5() +} + +type SwigcptrXYZ6 uintptr + +func (p SwigcptrXYZ6) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrXYZ6) SwigIsXYZ6() { +} + +var _wrap_new_XYZ6 unsafe.Pointer + +func _swig_wrap_new_XYZ6() (base SwigcptrXYZ6) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_XYZ6, _swig_p) + return +} + +func NewXYZ6() (_swig_ret XYZ6) { + return _swig_wrap_new_XYZ6() +} + +var _wrap_delete_XYZ6 unsafe.Pointer + +func _swig_wrap_delete_XYZ6(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_XYZ6, _swig_p) + return +} + +func DeleteXYZ6(arg1 XYZ6) { + _swig_wrap_delete_XYZ6(arg1.Swigcptr()) +} + +type XYZ6 interface { + Swigcptr() uintptr + SwigIsXYZ6() +} + +type SwigcptrXYZ7 uintptr + +func (p SwigcptrXYZ7) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrXYZ7) SwigIsXYZ7() { +} + +var _wrap_new_XYZ7 unsafe.Pointer + +func _swig_wrap_new_XYZ7() (base SwigcptrXYZ7) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_XYZ7, _swig_p) + return +} + +func NewXYZ7() (_swig_ret XYZ7) { + return _swig_wrap_new_XYZ7() +} + +var _wrap_delete_XYZ7 unsafe.Pointer + +func _swig_wrap_delete_XYZ7(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_XYZ7, _swig_p) + return +} + +func DeleteXYZ7(arg1 XYZ7) { + _swig_wrap_delete_XYZ7(arg1.Swigcptr()) +} + +type XYZ7 interface { + Swigcptr() uintptr + SwigIsXYZ7() +} + +type SwigcptrXYZMethods uintptr + +func (p SwigcptrXYZMethods) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrXYZMethods) SwigIsXYZMethods() { +} + +var _wrap_XYZMethods_methodA unsafe.Pointer + +func _swig_wrap_XYZMethods_methodA(base uintptr, _ uintptr, _ uintptr, _ uintptr, _ uintptr, _ uintptr, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_XYZMethods_methodA, _swig_p) + return +} + +func XYZMethodsMethodA(arg1 XYZ1, arg2 XYZ2, arg3 XYZ3, arg4 XYZ4, arg5 XYZ5, arg6 XYZ6, arg7 XYZ7) { + _swig_wrap_XYZMethods_methodA(arg1.Swigcptr(), arg2.Swigcptr(), arg3.Swigcptr(), arg4.Swigcptr(), arg5.Swigcptr(), arg6.Swigcptr(), arg7.Swigcptr()) +} + +var _wrap_XYZMethods_methodB unsafe.Pointer + +func _swig_wrap_XYZMethods_methodB(base uintptr, _ uintptr, _ uintptr, _ uintptr, _ uintptr, _ uintptr, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_XYZMethods_methodB, _swig_p) + return +} + +func XYZMethodsMethodB(arg1 XYZ1, arg2 XYZ2, arg3 XYZ3, arg4 XYZ4, arg5 XYZ5, arg6 XYZ6, arg7 XYZ7) { + _swig_wrap_XYZMethods_methodB(arg1.Swigcptr(), arg2.Swigcptr(), arg3.Swigcptr(), arg4.Swigcptr(), arg5.Swigcptr(), arg6.Swigcptr(), arg7.Swigcptr()) +} + +var _wrap_new_XYZMethods unsafe.Pointer + +func _swig_wrap_new_XYZMethods() (base SwigcptrXYZMethods) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_XYZMethods, _swig_p) + return +} + +func NewXYZMethods() (_swig_ret XYZMethods) { + return _swig_wrap_new_XYZMethods() +} + +var _wrap_delete_XYZMethods unsafe.Pointer + +func _swig_wrap_delete_XYZMethods(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_XYZMethods, _swig_p) + return +} + +func DeleteXYZMethods(arg1 XYZMethods) { + _swig_wrap_delete_XYZMethods(arg1.Swigcptr()) +} + +type XYZMethods interface { + Swigcptr() uintptr + SwigIsXYZMethods() +} + +type AnEnum1 int +var _wrap_anenum1 unsafe.Pointer + +func _swig_getanenum1() (_swig_ret AnEnum1) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_anenum1, _swig_p) + return +} +var Anenum1 AnEnum1 = _swig_getanenum1() +type AnEnum2 int +var _wrap_anenum2 unsafe.Pointer + +func _swig_getanenum2() (_swig_ret AnEnum2) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_anenum2, _swig_p) + return +} +var Anenum2 AnEnum2 = _swig_getanenum2() +type AnEnum3 int +var _wrap_anenum3 unsafe.Pointer + +func _swig_getanenum3() (_swig_ret AnEnum3) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_anenum3, _swig_p) + return +} +var Anenum3 AnEnum3 = _swig_getanenum3() +type SwigcptrAnEnumMethods uintptr + +func (p SwigcptrAnEnumMethods) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrAnEnumMethods) SwigIsAnEnumMethods() { +} + +var _wrap_AnEnumMethods_methodA unsafe.Pointer + +func _swig_wrap_AnEnumMethods_methodA(base AnEnum1, _ AnEnum2, _ *AnEnum3) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_AnEnumMethods_methodA, _swig_p) + return +} + +func AnEnumMethodsMethodA(arg1 AnEnum1, arg2 AnEnum2, arg3 *AnEnum3) { + _swig_wrap_AnEnumMethods_methodA(arg1, arg2, arg3) +} + +var _wrap_AnEnumMethods_methodB unsafe.Pointer + +func _swig_wrap_AnEnumMethods_methodB(base AnEnum1, _ AnEnum2, _ *AnEnum3) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_AnEnumMethods_methodB, _swig_p) + return +} + +func AnEnumMethodsMethodB(arg1 AnEnum1, arg2 AnEnum2, arg3 *AnEnum3) { + _swig_wrap_AnEnumMethods_methodB(arg1, arg2, arg3) +} + +var _wrap_new_AnEnumMethods unsafe.Pointer + +func _swig_wrap_new_AnEnumMethods() (base SwigcptrAnEnumMethods) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_AnEnumMethods, _swig_p) + return +} + +func NewAnEnumMethods() (_swig_ret AnEnumMethods) { + return _swig_wrap_new_AnEnumMethods() +} + +var _wrap_delete_AnEnumMethods unsafe.Pointer + +func _swig_wrap_delete_AnEnumMethods(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_AnEnumMethods, _swig_p) + return +} + +func DeleteAnEnumMethods(arg1 AnEnumMethods) { + _swig_wrap_delete_AnEnumMethods(arg1.Swigcptr()) +} + +type AnEnumMethods interface { + Swigcptr() uintptr + SwigIsAnEnumMethods() +} + +type SpaceTheEnum1 int +var _wrap_theenum1 unsafe.Pointer + +func _swig_gettheenum1() (_swig_ret SpaceTheEnum1) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_theenum1, _swig_p) + return +} +var Theenum1 SpaceTheEnum1 = _swig_gettheenum1() +type SpaceTheEnum2 int +var _wrap_theenum2 unsafe.Pointer + +func _swig_gettheenum2() (_swig_ret SpaceTheEnum2) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_theenum2, _swig_p) + return +} +var Theenum2 SpaceTheEnum2 = _swig_gettheenum2() +type SpaceTheEnum3 int +var _wrap_theenum3 unsafe.Pointer + +func _swig_gettheenum3() (_swig_ret SpaceTheEnum3) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_theenum3, _swig_p) + return +} +var Theenum3 SpaceTheEnum3 = _swig_gettheenum3() +type SwigcptrTheEnumMethods uintptr + +func (p SwigcptrTheEnumMethods) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrTheEnumMethods) SwigIsTheEnumMethods() { +} + +var _wrap_TheEnumMethods_methodA unsafe.Pointer + +func _swig_wrap_TheEnumMethods_methodA(base SpaceTheEnum1, _ SpaceTheEnum2, _ *SpaceTheEnum3) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_TheEnumMethods_methodA, _swig_p) + return +} + +func TheEnumMethodsMethodA(arg1 SpaceTheEnum1, arg2 SpaceTheEnum2, arg3 *SpaceTheEnum3) { + _swig_wrap_TheEnumMethods_methodA(arg1, arg2, arg3) +} + +var _wrap_TheEnumMethods_methodB unsafe.Pointer + +func _swig_wrap_TheEnumMethods_methodB(base SpaceTheEnum1, _ SpaceTheEnum2, _ *SpaceTheEnum3) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_TheEnumMethods_methodB, _swig_p) + return +} + +func TheEnumMethodsMethodB(arg1 SpaceTheEnum1, arg2 SpaceTheEnum2, arg3 *SpaceTheEnum3) { + _swig_wrap_TheEnumMethods_methodB(arg1, arg2, arg3) +} + +var _wrap_new_TheEnumMethods unsafe.Pointer + +func _swig_wrap_new_TheEnumMethods() (base SwigcptrTheEnumMethods) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_TheEnumMethods, _swig_p) + return +} + +func NewTheEnumMethods() (_swig_ret TheEnumMethods) { + return _swig_wrap_new_TheEnumMethods() +} + +var _wrap_delete_TheEnumMethods unsafe.Pointer + +func _swig_wrap_delete_TheEnumMethods(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_TheEnumMethods, _swig_p) + return +} + +func DeleteTheEnumMethods(arg1 TheEnumMethods) { + _swig_wrap_delete_TheEnumMethods(arg1.Swigcptr()) +} + +type TheEnumMethods interface { + Swigcptr() uintptr + SwigIsTheEnumMethods() +} + +var _wrap_getKlass1A unsafe.Pointer + +func _swig_wrap_getKlass1A() (base SwigcptrKlass1) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_getKlass1A, _swig_p) + return +} + +func GetKlass1A() (_swig_ret Klass1) { + return _swig_wrap_getKlass1A() +} + +var _wrap_getKlass1B unsafe.Pointer + +func _swig_wrap_getKlass1B() (base SwigcptrKlass1) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_getKlass1B, _swig_p) + return +} + +func GetKlass1B() (_swig_ret Klass1) { + return _swig_wrap_getKlass1B() +} + +var _wrap_getKlass2A unsafe.Pointer + +func _swig_wrap_getKlass2A() (base SwigcptrKlass2) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_getKlass2A, _swig_p) + return +} + +func GetKlass2A() (_swig_ret Klass2) { + return _swig_wrap_getKlass2A() +} + +var _wrap_getKlass2B unsafe.Pointer + +func _swig_wrap_getKlass2B() (base SwigcptrKlass2) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_getKlass2B, _swig_p) + return +} + +func GetKlass2B() (_swig_ret Klass2) { + return _swig_wrap_getKlass2B() +} + +var _wrap_getKlass3A unsafe.Pointer + +func _swig_wrap_getKlass3A() (base SwigcptrKlass3) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_getKlass3A, _swig_p) + return +} + +func GetKlass3A() (_swig_ret Klass3) { + return _swig_wrap_getKlass3A() +} + +var _wrap_getKlass3B unsafe.Pointer + +func _swig_wrap_getKlass3B() (base SwigcptrKlass3) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_getKlass3B, _swig_p) + return +} + +func GetKlass3B() (_swig_ret Klass3) { + return _swig_wrap_getKlass3B() +} + +var _wrap_getKlass4A unsafe.Pointer + +func _swig_wrap_getKlass4A() (base SwigcptrKlass4) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_getKlass4A, _swig_p) + return +} + +func GetKlass4A() (_swig_ret Klass4) { + return _swig_wrap_getKlass4A() +} + +var _wrap_getKlass4B unsafe.Pointer + +func _swig_wrap_getKlass4B() (base SwigcptrKlass4) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_getKlass4B, _swig_p) + return +} + +func GetKlass4B() (_swig_ret Klass4) { + return _swig_wrap_getKlass4B() +} + +var _wrap_getKlass5A unsafe.Pointer + +func _swig_wrap_getKlass5A() (base SwigcptrKlass5) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_getKlass5A, _swig_p) + return +} + +func GetKlass5A() (_swig_ret Klass5) { + return _swig_wrap_getKlass5A() +} + +var _wrap_getKlass5B unsafe.Pointer + +func _swig_wrap_getKlass5B() (base SwigcptrKlass5) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_getKlass5B, _swig_p) + return +} + +func GetKlass5B() (_swig_ret Klass5) { + return _swig_wrap_getKlass5B() +} + +var _wrap_getKlass6A unsafe.Pointer + +func _swig_wrap_getKlass6A() (base SwigcptrKlass6) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_getKlass6A, _swig_p) + return +} + +func GetKlass6A() (_swig_ret Klass6) { + return _swig_wrap_getKlass6A() +} + +var _wrap_getKlass6B unsafe.Pointer + +func _swig_wrap_getKlass6B() (base SwigcptrKlass6) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_getKlass6B, _swig_p) + return +} + +func GetKlass6B() (_swig_ret Klass6) { + return _swig_wrap_getKlass6B() +} + +var _wrap_getKlass7A unsafe.Pointer + +func _swig_wrap_getKlass7A() (base SwigcptrKlass7) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_getKlass7A, _swig_p) + return +} + +func GetKlass7A() (_swig_ret Klass7) { + return _swig_wrap_getKlass7A() +} + +var _wrap_getKlass7B unsafe.Pointer + +func _swig_wrap_getKlass7B() (base SwigcptrKlass7) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_getKlass7B, _swig_p) + return +} + +func GetKlass7B() (_swig_ret Klass7) { + return _swig_wrap_getKlass7B() +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/global_ns_arg.go b/Examples/test-suite/go/global_ns_arg.go new file mode 100644 index 000000000..5d67fc215 --- /dev/null +++ b/Examples/test-suite/go/global_ns_arg.go @@ -0,0 +1,43 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../global_ns_arg.i + +package global_ns_arg + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +var _wrap_foo unsafe.Pointer + +func Foo(arg1 int) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_foo, _swig_p) + return +} +var _wrap_bar_fn unsafe.Pointer + +func Bar_fn() (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_bar_fn, _swig_p) + return +} + diff --git a/Examples/test-suite/go/global_ns_arg_runme b/Examples/test-suite/go/global_ns_arg_runme new file mode 100755 index 000000000..e832d6e8f Binary files /dev/null and b/Examples/test-suite/go/global_ns_arg_runme differ diff --git a/Examples/test-suite/go/global_scope_types.go b/Examples/test-suite/go/global_scope_types.go new file mode 100644 index 000000000..dbf3c072d --- /dev/null +++ b/Examples/test-suite/go/global_scope_types.go @@ -0,0 +1,194 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../global_scope_types.i + +package global_scope_types + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrDingaling uintptr + +func (p SwigcptrDingaling) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrDingaling) SwigIsDingaling() { +} + +type Dingaling interface { + Swigcptr() uintptr + SwigIsDingaling() +} + +type SwigcptrTing uintptr + +func (p SwigcptrTing) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrTing) SwigIsTing() { +} + +var _wrap_new_Ting unsafe.Pointer + +func _swig_wrap_new_Ting() (base SwigcptrTing) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Ting, _swig_p) + return +} + +func NewTing() (_swig_ret Ting) { + return _swig_wrap_new_Ting() +} + +var _wrap_delete_Ting unsafe.Pointer + +func _swig_wrap_delete_Ting(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Ting, _swig_p) + return +} + +func DeleteTing(arg1 Ting) { + _swig_wrap_delete_Ting(arg1.Swigcptr()) +} + +type Ting interface { + Swigcptr() uintptr + SwigIsTing() +} + +type SwigcptrTest uintptr + +func (p SwigcptrTest) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrTest) SwigIsTest() { +} + +var _wrap_Test_something unsafe.Pointer + +func _swig_wrap_Test_something(base SwigcptrTest, _ uintptr, _ uintptr, _ uintptr, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Test_something, _swig_p) + return +} + +func (arg1 SwigcptrTest) Something(arg2 Dingaling, arg3 Dingaling, arg4 Dingaling, arg5 Dingaling) { + _swig_wrap_Test_something(arg1, arg2.Swigcptr(), arg3.Swigcptr(), arg4.Swigcptr(), arg5.Swigcptr()) +} + +var _wrap_Test_tsomething unsafe.Pointer + +func _swig_wrap_Test_tsomething(base SwigcptrTest, _ uintptr, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Test_tsomething, _swig_p) + return +} + +func (arg1 SwigcptrTest) Tsomething(arg2 MyTemplate_Sl__Dingaling_Sg_, arg3 MyTemplate_Sl_Dingaling_SS_const_Sm__Sg_) { + _swig_wrap_Test_tsomething(arg1, arg2.Swigcptr(), arg3.Swigcptr()) +} + +var _wrap_Test_nothing unsafe.Pointer + +func _swig_wrap_Test_nothing(base SwigcptrTest, _ uintptr, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Test_nothing, _swig_p) + return +} + +func (arg1 SwigcptrTest) Nothing(arg2 Ting, arg3 Ting) { + _swig_wrap_Test_nothing(arg1, arg2.Swigcptr(), arg3.Swigcptr()) +} + +var _wrap_new_Test unsafe.Pointer + +func _swig_wrap_new_Test() (base SwigcptrTest) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Test, _swig_p) + return +} + +func NewTest() (_swig_ret Test) { + return _swig_wrap_new_Test() +} + +var _wrap_delete_Test unsafe.Pointer + +func _swig_wrap_delete_Test(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Test, _swig_p) + return +} + +func DeleteTest(arg1 Test) { + _swig_wrap_delete_Test(arg1.Swigcptr()) +} + +type Test interface { + Swigcptr() uintptr + SwigIsTest() + Something(arg2 Dingaling, arg3 Dingaling, arg4 Dingaling, arg5 Dingaling) + Tsomething(arg2 MyTemplate_Sl__Dingaling_Sg_, arg3 MyTemplate_Sl_Dingaling_SS_const_Sm__Sg_) + Nothing(arg2 Ting, arg3 Ting) +} + +var _wrap_funcptrtest unsafe.Pointer + +func _swig_wrap_funcptrtest(base _swig_fnptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_funcptrtest, _swig_p) + return +} + +func Funcptrtest(arg1 _swig_fnptr) { + _swig_wrap_funcptrtest(arg1) +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + +type SwigcptrMyTemplate_Sl__Dingaling_Sg_ uintptr +type MyTemplate_Sl__Dingaling_Sg_ interface { + Swigcptr() uintptr; +} +func (p SwigcptrMyTemplate_Sl__Dingaling_Sg_) Swigcptr() uintptr { + return uintptr(p) +} + +type SwigcptrMyTemplate_Sl_Dingaling_SS_const_Sm__Sg_ uintptr +type MyTemplate_Sl_Dingaling_SS_const_Sm__Sg_ interface { + Swigcptr() uintptr; +} +func (p SwigcptrMyTemplate_Sl_Dingaling_SS_const_Sm__Sg_) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/global_vars.go b/Examples/test-suite/go/global_vars.go new file mode 100644 index 000000000..53b454234 --- /dev/null +++ b/Examples/test-suite/go/global_vars.go @@ -0,0 +1,378 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../global_vars.i + +package global_vars + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrA uintptr + +func (p SwigcptrA) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrA) SwigIsA() { +} + +var _wrap_A_x_set unsafe.Pointer + +func _swig_wrap_A_x_set(base SwigcptrA, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_A_x_set, _swig_p) + return +} + +func (arg1 SwigcptrA) SetX(arg2 int) { + _swig_wrap_A_x_set(arg1, arg2) +} + +var _wrap_A_x_get unsafe.Pointer + +func _swig_wrap_A_x_get(base SwigcptrA) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_A_x_get, _swig_p) + return +} + +func (arg1 SwigcptrA) GetX() (_swig_ret int) { + return _swig_wrap_A_x_get(arg1) +} + +var _wrap_new_A unsafe.Pointer + +func _swig_wrap_new_A() (base SwigcptrA) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_A, _swig_p) + return +} + +func NewA() (_swig_ret A) { + return _swig_wrap_new_A() +} + +var _wrap_delete_A unsafe.Pointer + +func _swig_wrap_delete_A(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_A, _swig_p) + return +} + +func DeleteA(arg1 A) { + _swig_wrap_delete_A(arg1.Swigcptr()) +} + +type A interface { + Swigcptr() uintptr + SwigIsA() + SetX(arg2 int) + GetX() (_swig_ret int) +} + +var _wrap_b_set unsafe.Pointer + +func _swig_wrap_b_set(base string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_b_set, _swig_p) + return +} + +func SetB(arg1 string) { + _swig_wrap_b_set(arg1) +} + +var _wrap_b_get unsafe.Pointer + +func GetB() (_swig_ret string) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_b_get, _swig_p) + return +} +var _wrap_a_set unsafe.Pointer + +func _swig_wrap_a_set(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_a_set, _swig_p) + return +} + +func SetA(arg1 A) { + _swig_wrap_a_set(arg1.Swigcptr()) +} + +var _wrap_a_get unsafe.Pointer + +func _swig_wrap_a_get() (base SwigcptrA) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_a_get, _swig_p) + return +} + +func GetA() (_swig_ret A) { + return _swig_wrap_a_get() +} + +var _wrap_ap_set unsafe.Pointer + +func _swig_wrap_ap_set(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_ap_set, _swig_p) + return +} + +func SetAp(arg1 A) { + _swig_wrap_ap_set(arg1.Swigcptr()) +} + +var _wrap_ap_get unsafe.Pointer + +func _swig_wrap_ap_get() (base SwigcptrA) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_ap_get, _swig_p) + return +} + +func GetAp() (_swig_ret A) { + return _swig_wrap_ap_get() +} + +var _wrap_cap_set unsafe.Pointer + +func _swig_wrap_cap_set(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_cap_set, _swig_p) + return +} + +func SetCap(arg1 A) { + _swig_wrap_cap_set(arg1.Swigcptr()) +} + +var _wrap_cap_get unsafe.Pointer + +func _swig_wrap_cap_get() (base SwigcptrA) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_cap_get, _swig_p) + return +} + +func GetCap() (_swig_ret A) { + return _swig_wrap_cap_get() +} + +var _wrap_ar_set unsafe.Pointer + +func _swig_wrap_ar_set(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_ar_set, _swig_p) + return +} + +func SetAr(arg1 A) { + _swig_wrap_ar_set(arg1.Swigcptr()) +} + +var _wrap_ar_get unsafe.Pointer + +func _swig_wrap_ar_get() (base SwigcptrA) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_ar_get, _swig_p) + return +} + +func GetAr() (_swig_ret A) { + return _swig_wrap_ar_get() +} + +var _wrap_x_set unsafe.Pointer + +func _swig_wrap_x_set(base int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_x_set, _swig_p) + return +} + +func SetX(arg1 int) { + _swig_wrap_x_set(arg1) +} + +var _wrap_x_get unsafe.Pointer + +func GetX() (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_x_get, _swig_p) + return +} +var _wrap_xp_set unsafe.Pointer + +func _swig_wrap_xp_set(base *int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_xp_set, _swig_p) + return +} + +func SetXp(arg1 *int) { + _swig_wrap_xp_set(arg1) +} + +var _wrap_xp_get unsafe.Pointer + +func GetXp() (_swig_ret *int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_xp_get, _swig_p) + return +} +var _wrap_c_member_set unsafe.Pointer + +func _swig_wrap_c_member_set(base *int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_c_member_set, _swig_p) + return +} + +func SetC_member(arg1 *int) { + _swig_wrap_c_member_set(arg1) +} + +var _wrap_c_member_get unsafe.Pointer + +func GetC_member() (_swig_ret *int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_c_member_get, _swig_p) + return +} +var _wrap_vp_set unsafe.Pointer + +func _swig_wrap_vp_set(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_vp_set, _swig_p) + return +} + +func SetVp(arg1 uintptr) { + _swig_wrap_vp_set(arg1) +} + +var _wrap_vp_get unsafe.Pointer + +func GetVp() (_swig_ret uintptr) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_vp_get, _swig_p) + return +} +type Hello int +var _wrap_Hi unsafe.Pointer + +func _swig_getHi() (_swig_ret Hello) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_Hi, _swig_p) + return +} +var Hi Hello = _swig_getHi() +var _wrap_Hola unsafe.Pointer + +func _swig_getHola() (_swig_ret Hello) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_Hola, _swig_p) + return +} +var Hola Hello = _swig_getHola() +var _wrap_h_set unsafe.Pointer + +func _swig_wrap_h_set(base Hello) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_h_set, _swig_p) + return +} + +func SetH(arg1 Hello) { + _swig_wrap_h_set(arg1) +} + +var _wrap_h_get unsafe.Pointer + +func GetH() (_swig_ret Hello) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_h_get, _swig_p) + return +} +var _wrap_hp_set unsafe.Pointer + +func _swig_wrap_hp_set(base *Hello) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_hp_set, _swig_p) + return +} + +func SetHp(arg1 *Hello) { + _swig_wrap_hp_set(arg1) +} + +var _wrap_hp_get unsafe.Pointer + +func GetHp() (_swig_ret *Hello) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_hp_get, _swig_p) + return +} +var _wrap_hr_set unsafe.Pointer + +func _swig_wrap_hr_set(base *Hello) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_hr_set, _swig_p) + return +} + +func SetHr(arg1 *Hello) { + _swig_wrap_hr_set(arg1) +} + +var _wrap_hr_get unsafe.Pointer + +func GetHr() (_swig_ret *Hello) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_hr_get, _swig_p) + return +} +var _wrap_init unsafe.Pointer + +func _swig_wrap_init() { + var _swig_p uintptr + _cgo_runtime_cgocall(_wrap_init, _swig_p) + return +} + +func Init() { + _swig_wrap_init() +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/go_director_inout.go b/Examples/test-suite/go/go_director_inout.go new file mode 100644 index 000000000..e99706285 --- /dev/null +++ b/Examples/test-suite/go/go_director_inout.go @@ -0,0 +1,360 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../go_director_inout.i + +package go_director_inout + +import "unsafe" +import _ "runtime/cgo" +import "encoding/json" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + + + +type GoRetStruct struct { + Str string +} + + +type SwigcptrMyStruct uintptr + +func (p SwigcptrMyStruct) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrMyStruct) SwigIsMyStruct() { +} + +var _wrap_MyStruct_str_set unsafe.Pointer + +func _swig_wrap_MyStruct_str_set(base SwigcptrMyStruct, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_MyStruct_str_set, _swig_p) + return +} + +func (arg1 SwigcptrMyStruct) SetStr(arg2 Std_string) { + _swig_wrap_MyStruct_str_set(arg1, arg2.Swigcptr()) +} + +var _wrap_MyStruct_str_get unsafe.Pointer + +func _swig_wrap_MyStruct_str_get(base SwigcptrMyStruct) (_ SwigcptrStd_string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_MyStruct_str_get, _swig_p) + return +} + +func (arg1 SwigcptrMyStruct) GetStr() (_swig_ret Std_string) { + return _swig_wrap_MyStruct_str_get(arg1) +} + +var _wrap_new_MyStruct unsafe.Pointer + +func _swig_wrap_new_MyStruct() (base SwigcptrMyStruct) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_MyStruct, _swig_p) + return +} + +func NewMyStruct() (_swig_ret MyStruct) { + return _swig_wrap_new_MyStruct() +} + +var _wrap_delete_MyStruct unsafe.Pointer + +func _swig_wrap_delete_MyStruct(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_MyStruct, _swig_p) + return +} + +func DeleteMyStruct(arg1 MyStruct) { + _swig_wrap_delete_MyStruct(arg1.Swigcptr()) +} + +type MyStruct interface { + Swigcptr() uintptr + SwigIsMyStruct() + SetStr(arg2 Std_string) + GetStr() (_swig_ret Std_string) +} + +type SwigcptrRetStruct uintptr + +func (p SwigcptrRetStruct) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrRetStruct) SwigIsRetStruct() { +} + +var _wrap_RetStruct_str_set unsafe.Pointer + +func _swig_wrap_RetStruct_str_set(base SwigcptrRetStruct, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_RetStruct_str_set, _swig_p) + return +} + +func (arg1 SwigcptrRetStruct) SetStr(arg2 Std_string) { + _swig_wrap_RetStruct_str_set(arg1, arg2.Swigcptr()) +} + +var _wrap_RetStruct_str_get unsafe.Pointer + +func _swig_wrap_RetStruct_str_get(base SwigcptrRetStruct) (_ SwigcptrStd_string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_RetStruct_str_get, _swig_p) + return +} + +func (arg1 SwigcptrRetStruct) GetStr() (_swig_ret Std_string) { + return _swig_wrap_RetStruct_str_get(arg1) +} + +var _wrap_new_RetStruct unsafe.Pointer + +func _swig_wrap_new_RetStruct() (base SwigcptrRetStruct) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_RetStruct, _swig_p) + return +} + +func NewRetStruct() (_swig_ret RetStruct) { + return _swig_wrap_new_RetStruct() +} + +var _wrap_delete_RetStruct unsafe.Pointer + +func _swig_wrap_delete_RetStruct(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_RetStruct, _swig_p) + return +} + +func DeleteRetStruct(arg1 RetStruct) { + _swig_wrap_delete_RetStruct(arg1.Swigcptr()) +} + +type RetStruct interface { + Swigcptr() uintptr + SwigIsRetStruct() + SetStr(arg2 Std_string) + GetStr() (_swig_ret Std_string) +} + +type _swig_DirectorMyClass struct { + SwigcptrMyClass + v interface{} +} + +func (p *_swig_DirectorMyClass) Swigcptr() uintptr { + return p.SwigcptrMyClass.Swigcptr() +} + +func (p *_swig_DirectorMyClass) SwigIsMyClass() { +} + +func (p *_swig_DirectorMyClass) DirectorInterface() interface{} { + return p.v +} + +var _wrap__swig_NewDirectorMyClassMyClass unsafe.Pointer + +func _swig_NewDirectorMyClassMyClass(_swig_director *_swig_DirectorMyClass) (_swig_ret SwigcptrMyClass) { + _swig_p := uintptr(unsafe.Pointer(&_swig_director)) + _cgo_runtime_cgocall(_wrap__swig_NewDirectorMyClassMyClass, _swig_p) + return +} + +func NewDirectorMyClass(v interface{}) MyClass { + p := &_swig_DirectorMyClass{0, v} + p.SwigcptrMyClass = _swig_NewDirectorMyClassMyClass(p) + return p +} + +var _wrap_DeleteDirectorMyClass unsafe.Pointer + +func _swig_wrap_DeleteDirectorMyClass(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_DeleteDirectorMyClass, _swig_p) + return +} + +func DeleteDirectorMyClass(arg1 MyClass) { + _swig_wrap_DeleteDirectorMyClass(arg1.Swigcptr()) +} + +func Swiggo_DeleteDirector_MyClass(p *_swig_DirectorMyClass) { + p.SwigcptrMyClass = 0 +} + +type _swig_DirectorInterfaceMyClassAdjust interface { + Adjust(map[string]interface{}) GoRetStruct +} + +var _wrap__swig_DirectorMyClass_upcall_Adjust unsafe.Pointer + +func _swig_wrap__swig_DirectorMyClass_upcall_Adjust(_swig_ptr SwigcptrMyClass, _ string) (_swig_ret string) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) + _cgo_runtime_cgocall(_wrap__swig_DirectorMyClass_upcall_Adjust, _swig_p) + return +} + +func (swig_p *_swig_DirectorMyClass) Adjust(s map[string]interface{}) GoRetStruct { + if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceMyClassAdjust); swig_ok { + return swig_g.Adjust(s) + } + var swig_r string + var _swig_i_0 string + if b, err := json.Marshal(s); err != nil { + panic(err) + } else { + _swig_i_0 = string(b) + } + swig_r = _swig_wrap__swig_DirectorMyClass_upcall_Adjust(swig_p.SwigcptrMyClass, _swig_i_0) + var swig_r_1 GoRetStruct + + swig_r_1 = GoRetStruct{Str: swig_r} + return swig_r_1 +} + +func DirectorMyClassAdjust(p MyClass, arg2 map[string]interface{}) GoRetStruct { + var swig_r string + var _swig_i_0 string + if b, err := json.Marshal(arg2); err != nil { + panic(err) + } else { + _swig_i_0 = string(b) + } + swig_r = _swig_wrap__swig_DirectorMyClass_upcall_Adjust(p.(*_swig_DirectorMyClass).SwigcptrMyClass, _swig_i_0) + var swig_r_1 GoRetStruct + + swig_r_1 = GoRetStruct{Str: swig_r} + return swig_r_1 +} + +func Swig_DirectorMyClass_callback_Adjust(p *_swig_DirectorMyClass, arg2 string) (swig_result string) { + var swig_r GoRetStruct + var _swig_i_0 map[string]interface{} + if err := json.Unmarshal([]byte(arg2), &_swig_i_0); err != nil { + panic(err) + } + swig_r = p.Adjust(_swig_i_0) + var swig_r_1 string + + swig_r_1 = swig_r.Str + return swig_r_1 +} + +type SwigcptrMyClass uintptr + +func (p SwigcptrMyClass) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrMyClass) SwigIsMyClass() { +} + +func (p SwigcptrMyClass) DirectorInterface() interface{} { + return nil +} + +var _wrap_delete_MyClass unsafe.Pointer + +func _swig_wrap_delete_MyClass(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_MyClass, _swig_p) + return +} + +func DeleteMyClass(arg1 MyClass) { + _swig_wrap_delete_MyClass(arg1.Swigcptr()) +} + +var _wrap_MyClass_Adjust unsafe.Pointer + +func _swig_wrap_MyClass_Adjust(base SwigcptrMyClass, _ string) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_MyClass_Adjust, _swig_p) + return +} + +func (arg1 SwigcptrMyClass) Adjust(arg2 map[string]interface{}) (_swig_ret GoRetStruct) { + var swig_r string + var _swig_i_1 string + if b, err := json.Marshal(arg2); err != nil { + panic(err) + } else { + _swig_i_1 = string(b) + } + swig_r = _swig_wrap_MyClass_Adjust(arg1, _swig_i_1) + var swig_r_1 GoRetStruct + + swig_r_1 = GoRetStruct{Str: swig_r} + return swig_r_1 +} + +var _wrap_new_MyClass unsafe.Pointer + +func _swig_wrap_new_MyClass() (base SwigcptrMyClass) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_MyClass, _swig_p) + return +} + +func NewMyClass() (_swig_ret MyClass) { + return _swig_wrap_new_MyClass() +} + +type MyClass interface { + Swigcptr() uintptr + SwigIsMyClass() + DirectorInterface() interface{} + Adjust(arg2 map[string]interface{}) (_swig_ret GoRetStruct) +} + + +type SwigcptrStd_string uintptr +type Std_string interface { + Swigcptr() uintptr; +} +func (p SwigcptrStd_string) Swigcptr() uintptr { + return uintptr(p) +} + +type SwigcptrSwigDirector_MyClass uintptr +type SwigDirector_MyClass interface { + Swigcptr() uintptr; +} +func (p SwigcptrSwigDirector_MyClass) Swigcptr() uintptr { + return uintptr(p) +} + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/go_director_inout_runme b/Examples/test-suite/go/go_director_inout_runme new file mode 100755 index 000000000..dba75e9b0 Binary files /dev/null and b/Examples/test-suite/go/go_director_inout_runme differ diff --git a/Examples/test-suite/go/go_director_inout_wrap.h b/Examples/test-suite/go/go_director_inout_wrap.h new file mode 100644 index 000000000..0be205b04 --- /dev/null +++ b/Examples/test-suite/go/go_director_inout_wrap.h @@ -0,0 +1,29 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../go_director_inout.i + +#ifndef SWIG_go_director_inout_WRAP_H_ +#define SWIG_go_director_inout_WRAP_H_ + +class SwigDirector_MyClass : public MyClass +{ + public: + SwigDirector_MyClass(void *swig_p); + virtual ~SwigDirector_MyClass(); + RetStruct _swig_upcall_Adjust(MyStruct s) { + return MyClass::Adjust(s); + } + virtual RetStruct Adjust(MyStruct s); + private: + void *go_val; +}; + +#endif diff --git a/Examples/test-suite/go/go_inout.go b/Examples/test-suite/go/go_inout.go new file mode 100644 index 000000000..6d8c34f5b --- /dev/null +++ b/Examples/test-suite/go/go_inout.go @@ -0,0 +1,355 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../go_inout.i + +package go_inout + +import "unsafe" +import _ "runtime/cgo" +import "encoding/json" +import "bytes" +import "encoding/binary" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + + + +type In json.Marshaler + + +type SwigcptrMyStruct uintptr + +func (p SwigcptrMyStruct) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrMyStruct) SwigIsMyStruct() { +} + +var _wrap_MyStruct_str_set unsafe.Pointer + +func _swig_wrap_MyStruct_str_set(base SwigcptrMyStruct, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_MyStruct_str_set, _swig_p) + return +} + +func (arg1 SwigcptrMyStruct) SetStr(arg2 Std_string) { + _swig_wrap_MyStruct_str_set(arg1, arg2.Swigcptr()) +} + +var _wrap_MyStruct_str_get unsafe.Pointer + +func _swig_wrap_MyStruct_str_get(base SwigcptrMyStruct) (_ SwigcptrStd_string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_MyStruct_str_get, _swig_p) + return +} + +func (arg1 SwigcptrMyStruct) GetStr() (_swig_ret Std_string) { + return _swig_wrap_MyStruct_str_get(arg1) +} + +var _wrap_new_MyStruct unsafe.Pointer + +func _swig_wrap_new_MyStruct() (base SwigcptrMyStruct) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_MyStruct, _swig_p) + return +} + +func NewMyStruct() (_swig_ret MyStruct) { + return _swig_wrap_new_MyStruct() +} + +var _wrap_delete_MyStruct unsafe.Pointer + +func _swig_wrap_delete_MyStruct(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_MyStruct, _swig_p) + return +} + +func DeleteMyStruct(arg1 MyStruct) { + _swig_wrap_delete_MyStruct(arg1.Swigcptr()) +} + +type MyStruct interface { + Swigcptr() uintptr + SwigIsMyStruct() + SetStr(arg2 Std_string) + GetStr() (_swig_ret Std_string) +} + +type SwigcptrRetStruct uintptr + +func (p SwigcptrRetStruct) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrRetStruct) SwigIsRetStruct() { +} + +var _wrap_RetStruct_str_set unsafe.Pointer + +func _swig_wrap_RetStruct_str_set(base SwigcptrRetStruct, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_RetStruct_str_set, _swig_p) + return +} + +func (arg1 SwigcptrRetStruct) SetStr(arg2 Std_string) { + _swig_wrap_RetStruct_str_set(arg1, arg2.Swigcptr()) +} + +var _wrap_RetStruct_str_get unsafe.Pointer + +func _swig_wrap_RetStruct_str_get(base SwigcptrRetStruct) (_ SwigcptrStd_string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_RetStruct_str_get, _swig_p) + return +} + +func (arg1 SwigcptrRetStruct) GetStr() (_swig_ret Std_string) { + return _swig_wrap_RetStruct_str_get(arg1) +} + +var _wrap_new_RetStruct unsafe.Pointer + +func _swig_wrap_new_RetStruct() (base SwigcptrRetStruct) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_RetStruct, _swig_p) + return +} + +func NewRetStruct() (_swig_ret RetStruct) { + return _swig_wrap_new_RetStruct() +} + +var _wrap_delete_RetStruct unsafe.Pointer + +func _swig_wrap_delete_RetStruct(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_RetStruct, _swig_p) + return +} + +func DeleteRetStruct(arg1 RetStruct) { + _swig_wrap_delete_RetStruct(arg1.Swigcptr()) +} + +type RetStruct interface { + Swigcptr() uintptr + SwigIsRetStruct() + SetStr(arg2 Std_string) + GetStr() (_swig_ret Std_string) +} + +var _wrap_Same unsafe.Pointer + +func _swig_wrap_Same(base string) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Same, _swig_p) + return +} + +func Same(arg1 In) (_swig_ret map[string]interface{}) { + var swig_r string + var _swig_i_0 string + { + b, err := arg1.MarshalJSON() + if err != nil { + panic(err) + } + _swig_i_0 = string(b) + } + swig_r = _swig_wrap_Same(_swig_i_0) + var swig_r_1 map[string]interface{} + + if err := json.Unmarshal([]byte(swig_r), &swig_r_1); err != nil { + panic(err) + } + return swig_r_1 +} + +type SwigcptrMyArray uintptr + +func (p SwigcptrMyArray) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrMyArray) SwigIsMyArray() { +} + +var _wrap_MyArray_strings_set unsafe.Pointer + +func _swig_wrap_MyArray_strings_set(base SwigcptrMyArray, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_MyArray_strings_set, _swig_p) + return +} + +func (arg1 SwigcptrMyArray) SetStrings(arg2 Std_vector_Sl_std_string_Sg_) { + _swig_wrap_MyArray_strings_set(arg1, arg2.Swigcptr()) +} + +var _wrap_MyArray_strings_get unsafe.Pointer + +func _swig_wrap_MyArray_strings_get(base SwigcptrMyArray) (_ SwigcptrStd_vector_Sl_std_string_Sg_) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_MyArray_strings_get, _swig_p) + return +} + +func (arg1 SwigcptrMyArray) GetStrings() (_swig_ret Std_vector_Sl_std_string_Sg_) { + return _swig_wrap_MyArray_strings_get(arg1) +} + +var _wrap_new_MyArray unsafe.Pointer + +func _swig_wrap_new_MyArray() (base SwigcptrMyArray) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_MyArray, _swig_p) + return +} + +func NewMyArray() (_swig_ret MyArray) { + return _swig_wrap_new_MyArray() +} + +var _wrap_delete_MyArray unsafe.Pointer + +func _swig_wrap_delete_MyArray(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_MyArray, _swig_p) + return +} + +func DeleteMyArray(arg1 MyArray) { + _swig_wrap_delete_MyArray(arg1.Swigcptr()) +} + +type MyArray interface { + Swigcptr() uintptr + SwigIsMyArray() + SetStrings(arg2 Std_vector_Sl_std_string_Sg_) + GetStrings() (_swig_ret Std_vector_Sl_std_string_Sg_) +} + +var _wrap_getuint64 unsafe.Pointer + +func _swig_wrap_getuint64(base string) (_ SwigcptrUint64_t) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_getuint64, _swig_p) + return +} + +func Getuint64(arg1 string) (_swig_ret Uint64_t) { + return _swig_wrap_getuint64(arg1) +} + +var _wrap_putuint64 unsafe.Pointer + +func _swig_wrap_putuint64(base uintptr, _ int64, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_putuint64, _swig_p) + return +} + +func Putuint64(arg1 Std_string, arg2 int64, arg3 Uint64_t) { + _swig_wrap_putuint64(arg1.Swigcptr(), arg2, arg3.Swigcptr()) +} + +var _wrap_DoubleArray unsafe.Pointer + +func _swig_wrap_DoubleArray(base *string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_DoubleArray, _swig_p) + return +} + +func DoubleArray(arg1 *[]string) { + var _swig_i_0 *string + { + var buf bytes.Buffer + bin := binary.LittleEndian + var b [8]byte + bin.PutUint64(b[:], uint64(len(*arg1))) + buf.Write(b[:]) + for _, s := range *arg1 { + bin.PutUint64(b[:], uint64(len(s))) + buf.Write(b[:]) + buf.WriteString(s) + } + str := buf.String() + _swig_i_0 = &str + } + _swig_wrap_DoubleArray(_swig_i_0) + + { + str := *_swig_i_0 + bin := binary.LittleEndian + size := bin.Uint64([]byte(str[:8])) + str = str[8:] + r := make([]string, size) + for i := range r { + len := bin.Uint64([]byte(str[:8])) + str = str[8:] + r[i] = str[:len] + str = str[len:] + } + *arg1 = r + } + +} + + +type SwigcptrStd_string uintptr +type Std_string interface { + Swigcptr() uintptr; +} +func (p SwigcptrStd_string) Swigcptr() uintptr { + return uintptr(p) +} + +type SwigcptrStd_vector_Sl_std_string_Sg_ uintptr +type Std_vector_Sl_std_string_Sg_ interface { + Swigcptr() uintptr; +} +func (p SwigcptrStd_vector_Sl_std_string_Sg_) Swigcptr() uintptr { + return uintptr(p) +} + +type SwigcptrUint64_t uintptr +type Uint64_t interface { + Swigcptr() uintptr; +} +func (p SwigcptrUint64_t) Swigcptr() uintptr { + return uintptr(p) +} + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/go_inout_runme b/Examples/test-suite/go/go_inout_runme new file mode 100755 index 000000000..9a919e577 Binary files /dev/null and b/Examples/test-suite/go/go_inout_runme differ diff --git a/Examples/test-suite/go/grouping.go b/Examples/test-suite/go/grouping.go new file mode 100644 index 000000000..7dd55f098 --- /dev/null +++ b/Examples/test-suite/go/grouping.go @@ -0,0 +1,92 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../grouping.i + +package grouping + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +var _wrap_test1 unsafe.Pointer + +func Test1(arg1 int) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_test1, _swig_p) + return +} +var _wrap_test2 unsafe.Pointer + +func Test2(arg1 int) (_swig_ret *int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_test2, _swig_p) + return +} +var _wrap_test3_set unsafe.Pointer + +func _swig_wrap_test3_set(base int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_test3_set, _swig_p) + return +} + +func SetTest3(arg1 int) { + _swig_wrap_test3_set(arg1) +} + +var _wrap_test3_get unsafe.Pointer + +func GetTest3() (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_test3_get, _swig_p) + return +} +var _wrap_do_unary unsafe.Pointer + +func Do_unary(arg1 int, arg2 *_swig_fnptr) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_do_unary, _swig_p) + return +} +var _wrap_negate unsafe.Pointer + +func Negate(arg1 int) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_negate, _swig_p) + return +} +var _wrap_NEGATE unsafe.Pointer + +func _swig_getNEGATE() (_swig_ret *_swig_fnptr) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_NEGATE, _swig_p) + return +} +var NEGATE *_swig_fnptr = _swig_getNEGATE() + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/grouping_runme b/Examples/test-suite/go/grouping_runme new file mode 100755 index 000000000..1327b4977 Binary files /dev/null and b/Examples/test-suite/go/grouping_runme differ diff --git a/Examples/test-suite/go/ignore_parameter.go b/Examples/test-suite/go/ignore_parameter.go new file mode 100644 index 000000000..5f866330c --- /dev/null +++ b/Examples/test-suite/go/ignore_parameter.go @@ -0,0 +1,307 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../ignore_parameter.i + +package ignore_parameter + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +var _wrap_jaguar unsafe.Pointer + +func Jaguar(arg1 int, arg2 float64) (_swig_ret string) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_jaguar, _swig_p) + return +} +var _wrap_lotus unsafe.Pointer + +func Lotus(arg1 string, arg2 float64) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_lotus, _swig_p) + return +} +var _wrap_tvr unsafe.Pointer + +func Tvr(arg1 string, arg2 int) (_swig_ret float64) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_tvr, _swig_p) + return +} +var _wrap_ferrari unsafe.Pointer + +func Ferrari() (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_ferrari, _swig_p) + return +} +type SwigcptrSportsCars uintptr + +func (p SwigcptrSportsCars) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrSportsCars) SwigIsSportsCars() { +} + +var _wrap_SportsCars_daimler unsafe.Pointer + +func _swig_wrap_SportsCars_daimler(base SwigcptrSportsCars, _ int, _ float64) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_SportsCars_daimler, _swig_p) + return +} + +func (arg1 SwigcptrSportsCars) Daimler(arg2 int, arg3 float64) (_swig_ret string) { + return _swig_wrap_SportsCars_daimler(arg1, arg2, arg3) +} + +var _wrap_SportsCars_astonmartin unsafe.Pointer + +func _swig_wrap_SportsCars_astonmartin(base SwigcptrSportsCars, _ string, _ float64) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_SportsCars_astonmartin, _swig_p) + return +} + +func (arg1 SwigcptrSportsCars) Astonmartin(arg2 string, arg3 float64) (_swig_ret int) { + return _swig_wrap_SportsCars_astonmartin(arg1, arg2, arg3) +} + +var _wrap_SportsCars_bugatti unsafe.Pointer + +func _swig_wrap_SportsCars_bugatti(base SwigcptrSportsCars, _ string, _ int) (_ float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_SportsCars_bugatti, _swig_p) + return +} + +func (arg1 SwigcptrSportsCars) Bugatti(arg2 string, arg3 int) (_swig_ret float64) { + return _swig_wrap_SportsCars_bugatti(arg1, arg2, arg3) +} + +var _wrap_SportsCars_lamborghini unsafe.Pointer + +func _swig_wrap_SportsCars_lamborghini(base SwigcptrSportsCars) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_SportsCars_lamborghini, _swig_p) + return +} + +func (arg1 SwigcptrSportsCars) Lamborghini() (_swig_ret int) { + return _swig_wrap_SportsCars_lamborghini(arg1) +} + +var _wrap_new_SportsCars unsafe.Pointer + +func _swig_wrap_new_SportsCars() (base SwigcptrSportsCars) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_SportsCars, _swig_p) + return +} + +func NewSportsCars() (_swig_ret SportsCars) { + return _swig_wrap_new_SportsCars() +} + +var _wrap_delete_SportsCars unsafe.Pointer + +func _swig_wrap_delete_SportsCars(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_SportsCars, _swig_p) + return +} + +func DeleteSportsCars(arg1 SportsCars) { + _swig_wrap_delete_SportsCars(arg1.Swigcptr()) +} + +type SportsCars interface { + Swigcptr() uintptr + SwigIsSportsCars() + Daimler(arg2 int, arg3 float64) (_swig_ret string) + Astonmartin(arg2 string, arg3 float64) (_swig_ret int) + Bugatti(arg2 string, arg3 int) (_swig_ret float64) + Lamborghini() (_swig_ret int) +} + +type SwigcptrMiniCooper uintptr + +func (p SwigcptrMiniCooper) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrMiniCooper) SwigIsMiniCooper() { +} + +var _wrap_new_MiniCooper unsafe.Pointer + +func _swig_wrap_new_MiniCooper(base int, _ float64) (_ SwigcptrMiniCooper) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_MiniCooper, _swig_p) + return +} + +func NewMiniCooper(arg1 int, arg2 float64) (_swig_ret MiniCooper) { + return _swig_wrap_new_MiniCooper(arg1, arg2) +} + +var _wrap_delete_MiniCooper unsafe.Pointer + +func _swig_wrap_delete_MiniCooper(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_MiniCooper, _swig_p) + return +} + +func DeleteMiniCooper(arg1 MiniCooper) { + _swig_wrap_delete_MiniCooper(arg1.Swigcptr()) +} + +type MiniCooper interface { + Swigcptr() uintptr + SwigIsMiniCooper() +} + +type SwigcptrMorrisMinor uintptr + +func (p SwigcptrMorrisMinor) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrMorrisMinor) SwigIsMorrisMinor() { +} + +var _wrap_new_MorrisMinor unsafe.Pointer + +func _swig_wrap_new_MorrisMinor(base string, _ float64) (_ SwigcptrMorrisMinor) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_MorrisMinor, _swig_p) + return +} + +func NewMorrisMinor(arg1 string, arg2 float64) (_swig_ret MorrisMinor) { + return _swig_wrap_new_MorrisMinor(arg1, arg2) +} + +var _wrap_delete_MorrisMinor unsafe.Pointer + +func _swig_wrap_delete_MorrisMinor(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_MorrisMinor, _swig_p) + return +} + +func DeleteMorrisMinor(arg1 MorrisMinor) { + _swig_wrap_delete_MorrisMinor(arg1.Swigcptr()) +} + +type MorrisMinor interface { + Swigcptr() uintptr + SwigIsMorrisMinor() +} + +type SwigcptrFordAnglia uintptr + +func (p SwigcptrFordAnglia) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrFordAnglia) SwigIsFordAnglia() { +} + +var _wrap_new_FordAnglia unsafe.Pointer + +func _swig_wrap_new_FordAnglia(base string, _ int) (_ SwigcptrFordAnglia) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_FordAnglia, _swig_p) + return +} + +func NewFordAnglia(arg1 string, arg2 int) (_swig_ret FordAnglia) { + return _swig_wrap_new_FordAnglia(arg1, arg2) +} + +var _wrap_delete_FordAnglia unsafe.Pointer + +func _swig_wrap_delete_FordAnglia(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_FordAnglia, _swig_p) + return +} + +func DeleteFordAnglia(arg1 FordAnglia) { + _swig_wrap_delete_FordAnglia(arg1.Swigcptr()) +} + +type FordAnglia interface { + Swigcptr() uintptr + SwigIsFordAnglia() +} + +type SwigcptrAustinAllegro uintptr + +func (p SwigcptrAustinAllegro) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrAustinAllegro) SwigIsAustinAllegro() { +} + +var _wrap_new_AustinAllegro unsafe.Pointer + +func _swig_wrap_new_AustinAllegro() (base SwigcptrAustinAllegro) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_AustinAllegro, _swig_p) + return +} + +func NewAustinAllegro() (_swig_ret AustinAllegro) { + return _swig_wrap_new_AustinAllegro() +} + +var _wrap_delete_AustinAllegro unsafe.Pointer + +func _swig_wrap_delete_AustinAllegro(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_AustinAllegro, _swig_p) + return +} + +func DeleteAustinAllegro(arg1 AustinAllegro) { + _swig_wrap_delete_AustinAllegro(arg1.Swigcptr()) +} + +type AustinAllegro interface { + Swigcptr() uintptr + SwigIsAustinAllegro() +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/ignore_template_constructor.go b/Examples/test-suite/go/ignore_template_constructor.go new file mode 100644 index 000000000..0ff6c71bc --- /dev/null +++ b/Examples/test-suite/go/ignore_template_constructor.go @@ -0,0 +1,275 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../ignore_template_constructor.i + +package ignore_template_constructor + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrFlow uintptr + +func (p SwigcptrFlow) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrFlow) SwigIsFlow() { +} + +var _wrap_new_Flow__SWIG_0 unsafe.Pointer + +func _swig_wrap_new_Flow__SWIG_0() (base SwigcptrFlow) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Flow__SWIG_0, _swig_p) + return +} + +func NewFlow__SWIG_0() (_swig_ret Flow) { + return _swig_wrap_new_Flow__SWIG_0() +} + +var _wrap_new_Flow__SWIG_1 unsafe.Pointer + +func _swig_wrap_new_Flow__SWIG_1(base float64) (_ SwigcptrFlow) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Flow__SWIG_1, _swig_p) + return +} + +func NewFlow__SWIG_1(arg1 float64) (_swig_ret Flow) { + return _swig_wrap_new_Flow__SWIG_1(arg1) +} + +func NewFlow(a ...interface{}) Flow { + argc := len(a) + if argc == 0 { + return NewFlow__SWIG_0() + } + if argc == 1 { + return NewFlow__SWIG_1(a[0].(float64)) + } + panic("No match for overloaded function call") +} + +var _wrap_delete_Flow unsafe.Pointer + +func _swig_wrap_delete_Flow(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Flow, _swig_p) + return +} + +func DeleteFlow(arg1 Flow) { + _swig_wrap_delete_Flow(arg1.Swigcptr()) +} + +type Flow interface { + Swigcptr() uintptr + SwigIsFlow() +} + +type SwigcptrVectFlow uintptr + +func (p SwigcptrVectFlow) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrVectFlow) SwigIsVectFlow() { +} + +var _wrap_new_VectFlow__SWIG_0 unsafe.Pointer + +func _swig_wrap_new_VectFlow__SWIG_0() (base SwigcptrVectFlow) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_VectFlow__SWIG_0, _swig_p) + return +} + +func NewVectFlow__SWIG_0() (_swig_ret VectFlow) { + return _swig_wrap_new_VectFlow__SWIG_0() +} + +var _wrap_new_VectFlow__SWIG_1 unsafe.Pointer + +func _swig_wrap_new_VectFlow__SWIG_1(base int64) (_ SwigcptrVectFlow) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_VectFlow__SWIG_1, _swig_p) + return +} + +func NewVectFlow__SWIG_1(arg1 int64) (_swig_ret VectFlow) { + return _swig_wrap_new_VectFlow__SWIG_1(arg1) +} + +func NewVectFlow(a ...interface{}) VectFlow { + argc := len(a) + if argc == 0 { + return NewVectFlow__SWIG_0() + } + if argc == 1 { + return NewVectFlow__SWIG_1(a[0].(int64)) + } + panic("No match for overloaded function call") +} + +var _wrap_VectFlow_size unsafe.Pointer + +func _swig_wrap_VectFlow_size(base SwigcptrVectFlow) (_ int64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_VectFlow_size, _swig_p) + return +} + +func (arg1 SwigcptrVectFlow) Size() (_swig_ret int64) { + return _swig_wrap_VectFlow_size(arg1) +} + +var _wrap_VectFlow_capacity unsafe.Pointer + +func _swig_wrap_VectFlow_capacity(base SwigcptrVectFlow) (_ int64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_VectFlow_capacity, _swig_p) + return +} + +func (arg1 SwigcptrVectFlow) Capacity() (_swig_ret int64) { + return _swig_wrap_VectFlow_capacity(arg1) +} + +var _wrap_VectFlow_reserve unsafe.Pointer + +func _swig_wrap_VectFlow_reserve(base SwigcptrVectFlow, _ int64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_VectFlow_reserve, _swig_p) + return +} + +func (arg1 SwigcptrVectFlow) Reserve(arg2 int64) { + _swig_wrap_VectFlow_reserve(arg1, arg2) +} + +var _wrap_VectFlow_isEmpty unsafe.Pointer + +func _swig_wrap_VectFlow_isEmpty(base SwigcptrVectFlow) (_ bool) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_VectFlow_isEmpty, _swig_p) + return +} + +func (arg1 SwigcptrVectFlow) IsEmpty() (_swig_ret bool) { + return _swig_wrap_VectFlow_isEmpty(arg1) +} + +var _wrap_VectFlow_clear unsafe.Pointer + +func _swig_wrap_VectFlow_clear(base SwigcptrVectFlow) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_VectFlow_clear, _swig_p) + return +} + +func (arg1 SwigcptrVectFlow) Clear() { + _swig_wrap_VectFlow_clear(arg1) +} + +var _wrap_VectFlow_add unsafe.Pointer + +func _swig_wrap_VectFlow_add(base SwigcptrVectFlow, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_VectFlow_add, _swig_p) + return +} + +func (arg1 SwigcptrVectFlow) Add(arg2 Flow) { + _swig_wrap_VectFlow_add(arg1, arg2.Swigcptr()) +} + +var _wrap_VectFlow_get unsafe.Pointer + +func _swig_wrap_VectFlow_get(base SwigcptrVectFlow, _ int) (_ SwigcptrFlow) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_VectFlow_get, _swig_p) + return +} + +func (arg1 SwigcptrVectFlow) Get(arg2 int) (_swig_ret Flow) { + return _swig_wrap_VectFlow_get(arg1, arg2) +} + +var _wrap_VectFlow_set unsafe.Pointer + +func _swig_wrap_VectFlow_set(base SwigcptrVectFlow, _ int, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_VectFlow_set, _swig_p) + return +} + +func (arg1 SwigcptrVectFlow) Set(arg2 int, arg3 Flow) { + _swig_wrap_VectFlow_set(arg1, arg2, arg3.Swigcptr()) +} + +var _wrap_delete_VectFlow unsafe.Pointer + +func _swig_wrap_delete_VectFlow(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_VectFlow, _swig_p) + return +} + +func DeleteVectFlow(arg1 VectFlow) { + _swig_wrap_delete_VectFlow(arg1.Swigcptr()) +} + +type VectFlow interface { + Swigcptr() uintptr + SwigIsVectFlow() + Size() (_swig_ret int64) + Capacity() (_swig_ret int64) + Reserve(arg2 int64) + IsEmpty() (_swig_ret bool) + Clear() + Add(arg2 Flow) + Get(arg2 int) (_swig_ret Flow) + Set(arg2 int, arg3 Flow) +} + +var _wrap_inandout unsafe.Pointer + +func _swig_wrap_inandout(base uintptr) (_ SwigcptrVectFlow) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_inandout, _swig_p) + return +} + +func Inandout(arg1 VectFlow) (_swig_ret VectFlow) { + return _swig_wrap_inandout(arg1.Swigcptr()) +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/immutable_values.go b/Examples/test-suite/go/immutable_values.go new file mode 100644 index 000000000..09be91c21 --- /dev/null +++ b/Examples/test-suite/go/immutable_values.go @@ -0,0 +1,81 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../immutable_values.i + +package immutable_values + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +const ABC int = -11 +type Enum_SS_count int +var _wrap_Zero unsafe.Pointer + +func _swig_getZero() (_swig_ret Enum_SS_count) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_Zero, _swig_p) + return +} +var Zero Enum_SS_count = _swig_getZero() +var _wrap_One unsafe.Pointer + +func _swig_getOne() (_swig_ret Enum_SS_count) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_One, _swig_p) + return +} +var One Enum_SS_count = _swig_getOne() +var _wrap_Two unsafe.Pointer + +func _swig_getTwo() (_swig_ret Enum_SS_count) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_Two, _swig_p) + return +} +var Two Enum_SS_count = _swig_getTwo() +const XYZ int = -22 +type Enum_SS_backwards int +var _wrap_Tre unsafe.Pointer + +func _swig_getTre() (_swig_ret Enum_SS_backwards) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_Tre, _swig_p) + return +} +var Tre Enum_SS_backwards = _swig_getTre() +var _wrap_Duo unsafe.Pointer + +func _swig_getDuo() (_swig_ret Enum_SS_backwards) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_Duo, _swig_p) + return +} +var Duo Enum_SS_backwards = _swig_getDuo() +var _wrap_Uno unsafe.Pointer + +func _swig_getUno() (_swig_ret Enum_SS_backwards) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_Uno, _swig_p) + return +} +var Uno Enum_SS_backwards = _swig_getUno() + diff --git a/Examples/test-suite/go/import_nomodule.go b/Examples/test-suite/go/import_nomodule.go new file mode 100644 index 000000000..31df272dc --- /dev/null +++ b/Examples/test-suite/go/import_nomodule.go @@ -0,0 +1,128 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../import_nomodule.i + +package import_nomodule + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +var _wrap_create_Foo unsafe.Pointer + +func _swig_wrap_create_Foo() (base SwigcptrFoo) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_create_Foo, _swig_p) + return +} + +func Create_Foo() (_swig_ret Foo) { + return _swig_wrap_create_Foo() +} + +var _wrap_delete_Foo unsafe.Pointer + +func _swig_wrap_delete_Foo(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Foo, _swig_p) + return +} + +func Delete_Foo(arg1 Foo) { + _swig_wrap_delete_Foo(arg1.Swigcptr()) +} + +var _wrap_test1 unsafe.Pointer + +func _swig_wrap_test1(base uintptr, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_test1, _swig_p) + return +} + +func Test1(arg1 Foo, arg2 int) { + _swig_wrap_test1(arg1.Swigcptr(), arg2) +} + +type SwigcptrBar uintptr + +func (p SwigcptrBar) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrBar) SwigIsBar() { +} + +var _wrap_new_Bar unsafe.Pointer + +func _swig_wrap_new_Bar() (base SwigcptrBar) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Bar, _swig_p) + return +} + +func NewBar() (_swig_ret Bar) { + return _swig_wrap_new_Bar() +} + +var _wrap_delete_Bar unsafe.Pointer + +func _swig_wrap_delete_Bar(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Bar, _swig_p) + return +} + +func DeleteBar(arg1 Bar) { + _swig_wrap_delete_Bar(arg1.Swigcptr()) +} + +func (p SwigcptrBar) SwigIsFoo() { +} + +func (p SwigcptrBar) SwigGetFoo() Foo { + return SwigcptrFoo(p.Swigcptr()) +} + +type Bar interface { + Swigcptr() uintptr + SwigIsBar() + SwigIsFoo() + SwigGetFoo() Foo +} + + +type SwigcptrFoo uintptr +type Foo interface { + Swigcptr() uintptr; +} +func (p SwigcptrFoo) Swigcptr() uintptr { + return uintptr(p) +} + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/import_nomodule_runme b/Examples/test-suite/go/import_nomodule_runme new file mode 100755 index 000000000..c3d6a9043 Binary files /dev/null and b/Examples/test-suite/go/import_nomodule_runme differ diff --git a/Examples/test-suite/go/import_stl_a.go b/Examples/test-suite/go/import_stl_a.go new file mode 100644 index 000000000..f47af5bdf --- /dev/null +++ b/Examples/test-suite/go/import_stl_a.go @@ -0,0 +1,202 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../import_stl_a.i + +package import_stl_a + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrVectorInt uintptr + +func (p SwigcptrVectorInt) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrVectorInt) SwigIsVectorInt() { +} + +var _wrap_new_VectorInt__SWIG_0 unsafe.Pointer + +func _swig_wrap_new_VectorInt__SWIG_0() (base SwigcptrVectorInt) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_VectorInt__SWIG_0, _swig_p) + return +} + +func NewVectorInt__SWIG_0() (_swig_ret VectorInt) { + return _swig_wrap_new_VectorInt__SWIG_0() +} + +var _wrap_new_VectorInt__SWIG_1 unsafe.Pointer + +func _swig_wrap_new_VectorInt__SWIG_1(base int64) (_ SwigcptrVectorInt) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_VectorInt__SWIG_1, _swig_p) + return +} + +func NewVectorInt__SWIG_1(arg1 int64) (_swig_ret VectorInt) { + return _swig_wrap_new_VectorInt__SWIG_1(arg1) +} + +func NewVectorInt(a ...interface{}) VectorInt { + argc := len(a) + if argc == 0 { + return NewVectorInt__SWIG_0() + } + if argc == 1 { + return NewVectorInt__SWIG_1(a[0].(int64)) + } + panic("No match for overloaded function call") +} + +var _wrap_VectorInt_size unsafe.Pointer + +func _swig_wrap_VectorInt_size(base SwigcptrVectorInt) (_ int64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_VectorInt_size, _swig_p) + return +} + +func (arg1 SwigcptrVectorInt) Size() (_swig_ret int64) { + return _swig_wrap_VectorInt_size(arg1) +} + +var _wrap_VectorInt_capacity unsafe.Pointer + +func _swig_wrap_VectorInt_capacity(base SwigcptrVectorInt) (_ int64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_VectorInt_capacity, _swig_p) + return +} + +func (arg1 SwigcptrVectorInt) Capacity() (_swig_ret int64) { + return _swig_wrap_VectorInt_capacity(arg1) +} + +var _wrap_VectorInt_reserve unsafe.Pointer + +func _swig_wrap_VectorInt_reserve(base SwigcptrVectorInt, _ int64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_VectorInt_reserve, _swig_p) + return +} + +func (arg1 SwigcptrVectorInt) Reserve(arg2 int64) { + _swig_wrap_VectorInt_reserve(arg1, arg2) +} + +var _wrap_VectorInt_isEmpty unsafe.Pointer + +func _swig_wrap_VectorInt_isEmpty(base SwigcptrVectorInt) (_ bool) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_VectorInt_isEmpty, _swig_p) + return +} + +func (arg1 SwigcptrVectorInt) IsEmpty() (_swig_ret bool) { + return _swig_wrap_VectorInt_isEmpty(arg1) +} + +var _wrap_VectorInt_clear unsafe.Pointer + +func _swig_wrap_VectorInt_clear(base SwigcptrVectorInt) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_VectorInt_clear, _swig_p) + return +} + +func (arg1 SwigcptrVectorInt) Clear() { + _swig_wrap_VectorInt_clear(arg1) +} + +var _wrap_VectorInt_add unsafe.Pointer + +func _swig_wrap_VectorInt_add(base SwigcptrVectorInt, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_VectorInt_add, _swig_p) + return +} + +func (arg1 SwigcptrVectorInt) Add(arg2 int) { + _swig_wrap_VectorInt_add(arg1, arg2) +} + +var _wrap_VectorInt_get unsafe.Pointer + +func _swig_wrap_VectorInt_get(base SwigcptrVectorInt, _ int) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_VectorInt_get, _swig_p) + return +} + +func (arg1 SwigcptrVectorInt) Get(arg2 int) (_swig_ret int) { + return _swig_wrap_VectorInt_get(arg1, arg2) +} + +var _wrap_VectorInt_set unsafe.Pointer + +func _swig_wrap_VectorInt_set(base SwigcptrVectorInt, _ int, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_VectorInt_set, _swig_p) + return +} + +func (arg1 SwigcptrVectorInt) Set(arg2 int, arg3 int) { + _swig_wrap_VectorInt_set(arg1, arg2, arg3) +} + +var _wrap_delete_VectorInt unsafe.Pointer + +func _swig_wrap_delete_VectorInt(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_VectorInt, _swig_p) + return +} + +func DeleteVectorInt(arg1 VectorInt) { + _swig_wrap_delete_VectorInt(arg1.Swigcptr()) +} + +type VectorInt interface { + Swigcptr() uintptr + SwigIsVectorInt() + Size() (_swig_ret int64) + Capacity() (_swig_ret int64) + Reserve(arg2 int64) + IsEmpty() (_swig_ret bool) + Clear() + Add(arg2 int) + Get(arg2 int) (_swig_ret int) + Set(arg2 int, arg3 int) +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/import_stl_b.go b/Examples/test-suite/go/import_stl_b.go new file mode 100644 index 000000000..87bef05d5 --- /dev/null +++ b/Examples/test-suite/go/import_stl_b.go @@ -0,0 +1,42 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../import_stl_b.i + +package import_stl_b + +import "unsafe" +import _ "runtime/cgo" +import "import_stl_a" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +var _wrap_process_vector unsafe.Pointer + +func _swig_wrap_process_vector(base uintptr) (_ import_stl_a.SwigcptrVectorInt) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_process_vector, _swig_p) + return +} + +func Process_vector(arg1 import_stl_a.VectorInt) (_swig_ret import_stl_a.VectorInt) { + return _swig_wrap_process_vector(arg1.Swigcptr()) +} + + diff --git a/Examples/test-suite/go/imports_a.go b/Examples/test-suite/go/imports_a.go new file mode 100644 index 000000000..feef97609 --- /dev/null +++ b/Examples/test-suite/go/imports_a.go @@ -0,0 +1,155 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../imports_a.i + +package imports_a + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type GlobalEnum int +var _wrap_globalenum1 unsafe.Pointer + +func _swig_getglobalenum1() (_swig_ret GlobalEnum) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_globalenum1, _swig_p) + return +} +var Globalenum1 GlobalEnum = _swig_getglobalenum1() +var _wrap_globalenum2 unsafe.Pointer + +func _swig_getglobalenum2() (_swig_ret GlobalEnum) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_globalenum2, _swig_p) + return +} +var Globalenum2 GlobalEnum = _swig_getglobalenum2() +var _wrap_global_test unsafe.Pointer + +func Global_test(arg1 GlobalEnum) (_swig_ret GlobalEnum) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_global_test, _swig_p) + return +} +type SwigcptrA uintptr + +func (p SwigcptrA) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrA) SwigIsA() { +} + +var _wrap_new_A unsafe.Pointer + +func _swig_wrap_new_A() (base SwigcptrA) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_A, _swig_p) + return +} + +func NewA() (_swig_ret A) { + return _swig_wrap_new_A() +} + +var _wrap_delete_A unsafe.Pointer + +func _swig_wrap_delete_A(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_A, _swig_p) + return +} + +func DeleteA(arg1 A) { + _swig_wrap_delete_A(arg1.Swigcptr()) +} + +var _wrap_A_hello unsafe.Pointer + +func _swig_wrap_A_hello(base SwigcptrA) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_A_hello, _swig_p) + return +} + +func (arg1 SwigcptrA) Hello() { + _swig_wrap_A_hello(arg1) +} + +type AMemberEnum int +var _wrap_memberenum1_A unsafe.Pointer + +func _swig_getA_memberenum1_A() (_swig_ret AMemberEnum) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_memberenum1_A, _swig_p) + return +} +var AMemberenum1 AMemberEnum = _swig_getA_memberenum1_A() +var _wrap_memberenum2_A unsafe.Pointer + +func _swig_getA_memberenum2_A() (_swig_ret AMemberEnum) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_memberenum2_A, _swig_p) + return +} +var AMemberenum2 AMemberEnum = _swig_getA_memberenum2_A() +var _wrap_A_member_virtual_test unsafe.Pointer + +func _swig_wrap_A_member_virtual_test(base SwigcptrA, _ AMemberEnum) (_ AMemberEnum) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_A_member_virtual_test, _swig_p) + return +} + +func (arg1 SwigcptrA) Member_virtual_test(arg2 AMemberEnum) (_swig_ret AMemberEnum) { + return _swig_wrap_A_member_virtual_test(arg1, arg2) +} + +var _wrap_A_global_virtual_test unsafe.Pointer + +func _swig_wrap_A_global_virtual_test(base SwigcptrA, _ GlobalEnum) (_ GlobalEnum) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_A_global_virtual_test, _swig_p) + return +} + +func (arg1 SwigcptrA) Global_virtual_test(arg2 GlobalEnum) (_swig_ret GlobalEnum) { + return _swig_wrap_A_global_virtual_test(arg1, arg2) +} + +type A interface { + Swigcptr() uintptr + SwigIsA() + Hello() + Member_virtual_test(arg2 AMemberEnum) (_swig_ret AMemberEnum) + Global_virtual_test(arg2 GlobalEnum) (_swig_ret GlobalEnum) +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/imports_b.go b/Examples/test-suite/go/imports_b.go new file mode 100644 index 000000000..71f9dc8df --- /dev/null +++ b/Examples/test-suite/go/imports_b.go @@ -0,0 +1,264 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../imports_b.i + +package imports_b + +import "unsafe" +import _ "runtime/cgo" +import "imports_a" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrB uintptr + +func (p SwigcptrB) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrB) SwigIsB() { +} + +var _wrap_new_B unsafe.Pointer + +func _swig_wrap_new_B() (base SwigcptrB) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_B, _swig_p) + return +} + +func NewB() (_swig_ret B) { + return _swig_wrap_new_B() +} + +var _wrap_B_bye unsafe.Pointer + +func _swig_wrap_B_bye(base SwigcptrB) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_B_bye, _swig_p) + return +} + +func (arg1 SwigcptrB) Bye() { + _swig_wrap_B_bye(arg1) +} + +var _wrap_B_member_virtual_test unsafe.Pointer + +func _swig_wrap_B_member_virtual_test(base SwigcptrB, _ imports_a.AMemberEnum) (_ imports_a.AMemberEnum) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_B_member_virtual_test, _swig_p) + return +} + +func (arg1 SwigcptrB) Member_virtual_test(arg2 imports_a.AMemberEnum) (_swig_ret imports_a.AMemberEnum) { + return _swig_wrap_B_member_virtual_test(arg1, arg2) +} + +var _wrap_B_global_virtual_test unsafe.Pointer + +func _swig_wrap_B_global_virtual_test(base SwigcptrB, _ imports_a.GlobalEnum) (_ imports_a.GlobalEnum) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_B_global_virtual_test, _swig_p) + return +} + +func (arg1 SwigcptrB) Global_virtual_test(arg2 imports_a.GlobalEnum) (_swig_ret imports_a.GlobalEnum) { + return _swig_wrap_B_global_virtual_test(arg1, arg2) +} + +var _wrap_delete_B unsafe.Pointer + +func _swig_wrap_delete_B(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_B, _swig_p) + return +} + +func DeleteB(arg1 B) { + _swig_wrap_delete_B(arg1.Swigcptr()) +} + +var _wrap_B_hello unsafe.Pointer + +func _swig_wrap_B_hello(base SwigcptrB) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_B_hello, _swig_p) + return +} + +func (_swig_base SwigcptrB) Hello() { + _swig_wrap_B_hello(_swig_base) +} + +func (p SwigcptrB) SwigIsA() { +} + +func (p SwigcptrB) SwigGetA() imports_a.A { + return imports_a.SwigcptrA(p.Swigcptr()) +} + +type B interface { + Swigcptr() uintptr + SwigIsB() + Bye() + Member_virtual_test(arg2 imports_a.AMemberEnum) (_swig_ret imports_a.AMemberEnum) + Global_virtual_test(arg2 imports_a.GlobalEnum) (_swig_ret imports_a.GlobalEnum) + Hello() + SwigIsA() + SwigGetA() imports_a.A +} + +var _wrap_global_test__SWIG_1 unsafe.Pointer + +func Global_test__SWIG_1(arg1 imports_a.AMemberEnum) (_swig_ret imports_a.AMemberEnum) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_global_test__SWIG_1, _swig_p) + return +} +func Global_test(a ...interface{}) imports_a.AMemberEnum { + argc := len(a) + if argc == 1 { + return Global_test__SWIG_1(a[0].(imports_a.AMemberEnum)) + } + panic("No match for overloaded function call") +} + +type SwigcptrC uintptr + +func (p SwigcptrC) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrC) SwigIsC() { +} + +var _wrap_C_get_a unsafe.Pointer + +func _swig_wrap_C_get_a(base SwigcptrC, _ uintptr) (_ imports_a.SwigcptrA) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_C_get_a, _swig_p) + return +} + +func (arg1 SwigcptrC) Get_a(arg2 imports_a.A) (_swig_ret imports_a.A) { + return _swig_wrap_C_get_a(arg1, arg2.Swigcptr()) +} + +var _wrap_C_get_a_type unsafe.Pointer + +func _swig_wrap_C_get_a_type(base SwigcptrC, _ uintptr) (_ imports_a.SwigcptrA) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_C_get_a_type, _swig_p) + return +} + +func (arg1 SwigcptrC) Get_a_type(arg2 imports_a.A) (_swig_ret imports_a.A) { + return _swig_wrap_C_get_a_type(arg1, arg2.Swigcptr()) +} + +var _wrap_new_C unsafe.Pointer + +func _swig_wrap_new_C() (base SwigcptrC) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_C, _swig_p) + return +} + +func NewC() (_swig_ret C) { + return _swig_wrap_new_C() +} + +var _wrap_delete_C unsafe.Pointer + +func _swig_wrap_delete_C(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_C, _swig_p) + return +} + +func DeleteC(arg1 C) { + _swig_wrap_delete_C(arg1.Swigcptr()) +} + +var _wrap_C_hello unsafe.Pointer + +func _swig_wrap_C_hello(base SwigcptrC) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_C_hello, _swig_p) + return +} + +func (_swig_base SwigcptrC) Hello() { + _swig_wrap_C_hello(_swig_base) +} + +var _wrap_C_member_virtual_test unsafe.Pointer + +func _swig_wrap_C_member_virtual_test(base SwigcptrC, _ imports_a.AMemberEnum) (_ imports_a.AMemberEnum) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_C_member_virtual_test, _swig_p) + return +} + +func (_swig_base SwigcptrC) Member_virtual_test(arg1 imports_a.AMemberEnum) (_swig_ret imports_a.AMemberEnum) { + return _swig_wrap_C_member_virtual_test(_swig_base, arg1) +} + +var _wrap_C_global_virtual_test unsafe.Pointer + +func _swig_wrap_C_global_virtual_test(base SwigcptrC, _ imports_a.GlobalEnum) (_ imports_a.GlobalEnum) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_C_global_virtual_test, _swig_p) + return +} + +func (_swig_base SwigcptrC) Global_virtual_test(arg1 imports_a.GlobalEnum) (_swig_ret imports_a.GlobalEnum) { + return _swig_wrap_C_global_virtual_test(_swig_base, arg1) +} + +func (p SwigcptrC) SwigIsA() { +} + +func (p SwigcptrC) SwigGetA() imports_a.A { + return imports_a.SwigcptrA(p.Swigcptr()) +} + +type C interface { + Swigcptr() uintptr + SwigIsC() + Get_a(arg2 imports_a.A) (_swig_ret imports_a.A) + Get_a_type(arg2 imports_a.A) (_swig_ret imports_a.A) + Hello() + Member_virtual_test(arg1 imports_a.AMemberEnum) (_swig_ret imports_a.AMemberEnum) + Global_virtual_test(arg1 imports_a.GlobalEnum) (_swig_ret imports_a.GlobalEnum) + SwigIsA() + SwigGetA() imports_a.A +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/imports_runme b/Examples/test-suite/go/imports_runme new file mode 100755 index 000000000..cd83e8b0d Binary files /dev/null and b/Examples/test-suite/go/imports_runme differ diff --git a/Examples/test-suite/go/inctest.go b/Examples/test-suite/go/inctest.go new file mode 100644 index 000000000..ec261508a --- /dev/null +++ b/Examples/test-suite/go/inctest.go @@ -0,0 +1,307 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../inctest.i + +package inctest + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrA uintptr + +func (p SwigcptrA) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrA) SwigIsA() { +} + +var _wrap_A_aa_set unsafe.Pointer + +func _swig_wrap_A_aa_set(base SwigcptrA, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_A_aa_set, _swig_p) + return +} + +func (arg1 SwigcptrA) SetAa(arg2 int) { + _swig_wrap_A_aa_set(arg1, arg2) +} + +var _wrap_A_aa_get unsafe.Pointer + +func _swig_wrap_A_aa_get(base SwigcptrA) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_A_aa_get, _swig_p) + return +} + +func (arg1 SwigcptrA) GetAa() (_swig_ret int) { + return _swig_wrap_A_aa_get(arg1) +} + +var _wrap_new_A unsafe.Pointer + +func _swig_wrap_new_A() (base SwigcptrA) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_A, _swig_p) + return +} + +func NewA() (_swig_ret A) { + return _swig_wrap_new_A() +} + +var _wrap_delete_A unsafe.Pointer + +func _swig_wrap_delete_A(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_A, _swig_p) + return +} + +func DeleteA(arg1 A) { + _swig_wrap_delete_A(arg1.Swigcptr()) +} + +type A interface { + Swigcptr() uintptr + SwigIsA() + SetAa(arg2 int) + GetAa() (_swig_ret int) +} + +var _wrap_importtest1 unsafe.Pointer + +func Importtest1(arg1 int) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_importtest1, _swig_p) + return +} +type SwigcptrB uintptr + +func (p SwigcptrB) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrB) SwigIsB() { +} + +var _wrap_B_bb_set unsafe.Pointer + +func _swig_wrap_B_bb_set(base SwigcptrB, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_B_bb_set, _swig_p) + return +} + +func (arg1 SwigcptrB) SetBb(arg2 int) { + _swig_wrap_B_bb_set(arg1, arg2) +} + +var _wrap_B_bb_get unsafe.Pointer + +func _swig_wrap_B_bb_get(base SwigcptrB) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_B_bb_get, _swig_p) + return +} + +func (arg1 SwigcptrB) GetBb() (_swig_ret int) { + return _swig_wrap_B_bb_get(arg1) +} + +var _wrap_new_B unsafe.Pointer + +func _swig_wrap_new_B() (base SwigcptrB) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_B, _swig_p) + return +} + +func NewB() (_swig_ret B) { + return _swig_wrap_new_B() +} + +var _wrap_delete_B unsafe.Pointer + +func _swig_wrap_delete_B(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_B, _swig_p) + return +} + +func DeleteB(arg1 B) { + _swig_wrap_delete_B(arg1.Swigcptr()) +} + +type B interface { + Swigcptr() uintptr + SwigIsB() + SetBb(arg2 int) + GetBb() (_swig_ret int) +} + +var _wrap_importtest2 unsafe.Pointer + +func Importtest2(arg1 string) (_swig_ret string) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_importtest2, _swig_p) + return +} +type SwigcptrMY_TYPES uintptr + +func (p SwigcptrMY_TYPES) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrMY_TYPES) SwigIsMY_TYPES() { +} + +var _wrap_new_MY_TYPES unsafe.Pointer + +func _swig_wrap_new_MY_TYPES() (base SwigcptrMY_TYPES) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_MY_TYPES, _swig_p) + return +} + +func NewMY_TYPES() (_swig_ret MY_TYPES) { + return _swig_wrap_new_MY_TYPES() +} + +var _wrap_delete_MY_TYPES unsafe.Pointer + +func _swig_wrap_delete_MY_TYPES(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_MY_TYPES, _swig_p) + return +} + +func DeleteMY_TYPES(arg1 MY_TYPES) { + _swig_wrap_delete_MY_TYPES(arg1.Swigcptr()) +} + +type MY_TYPES interface { + Swigcptr() uintptr + SwigIsMY_TYPES() +} + +type SwigcptrMY_THINGS uintptr + +func (p SwigcptrMY_THINGS) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrMY_THINGS) SwigIsMY_THINGS() { +} + +var _wrap_MY_THINGS_IntegerMember_set unsafe.Pointer + +func _swig_wrap_MY_THINGS_IntegerMember_set(base SwigcptrMY_THINGS, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_MY_THINGS_IntegerMember_set, _swig_p) + return +} + +func (arg1 SwigcptrMY_THINGS) SetIntegerMember(arg2 int) { + _swig_wrap_MY_THINGS_IntegerMember_set(arg1, arg2) +} + +var _wrap_MY_THINGS_IntegerMember_get unsafe.Pointer + +func _swig_wrap_MY_THINGS_IntegerMember_get(base SwigcptrMY_THINGS) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_MY_THINGS_IntegerMember_get, _swig_p) + return +} + +func (arg1 SwigcptrMY_THINGS) GetIntegerMember() (_swig_ret int) { + return _swig_wrap_MY_THINGS_IntegerMember_get(arg1) +} + +var _wrap_MY_THINGS_DoubleMember_set unsafe.Pointer + +func _swig_wrap_MY_THINGS_DoubleMember_set(base SwigcptrMY_THINGS, _ float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_MY_THINGS_DoubleMember_set, _swig_p) + return +} + +func (arg1 SwigcptrMY_THINGS) SetDoubleMember(arg2 float64) { + _swig_wrap_MY_THINGS_DoubleMember_set(arg1, arg2) +} + +var _wrap_MY_THINGS_DoubleMember_get unsafe.Pointer + +func _swig_wrap_MY_THINGS_DoubleMember_get(base SwigcptrMY_THINGS) (_ float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_MY_THINGS_DoubleMember_get, _swig_p) + return +} + +func (arg1 SwigcptrMY_THINGS) GetDoubleMember() (_swig_ret float64) { + return _swig_wrap_MY_THINGS_DoubleMember_get(arg1) +} + +var _wrap_new_MY_THINGS unsafe.Pointer + +func _swig_wrap_new_MY_THINGS() (base SwigcptrMY_THINGS) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_MY_THINGS, _swig_p) + return +} + +func NewMY_THINGS() (_swig_ret MY_THINGS) { + return _swig_wrap_new_MY_THINGS() +} + +var _wrap_delete_MY_THINGS unsafe.Pointer + +func _swig_wrap_delete_MY_THINGS(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_MY_THINGS, _swig_p) + return +} + +func DeleteMY_THINGS(arg1 MY_THINGS) { + _swig_wrap_delete_MY_THINGS(arg1.Swigcptr()) +} + +type MY_THINGS interface { + Swigcptr() uintptr + SwigIsMY_THINGS() + SetIntegerMember(arg2 int) + GetIntegerMember() (_swig_ret int) + SetDoubleMember(arg2 float64) + GetDoubleMember() (_swig_ret float64) +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/inctest_runme b/Examples/test-suite/go/inctest_runme new file mode 100755 index 000000000..c7f30ef30 Binary files /dev/null and b/Examples/test-suite/go/inctest_runme differ diff --git a/Examples/test-suite/go/infinity.go b/Examples/test-suite/go/infinity.go new file mode 100644 index 000000000..d31f9f51f --- /dev/null +++ b/Examples/test-suite/go/infinity.go @@ -0,0 +1,63 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../infinity.i + +package infinity + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +var _wrap_INFINITY_get unsafe.Pointer + +func GetINFINITY() (_swig_ret float64) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_INFINITY_get, _swig_p) + return +} +var _wrap_initialise_MYINFINITY unsafe.Pointer + +func _swig_wrap_initialise_MYINFINITY() { + var _swig_p uintptr + _cgo_runtime_cgocall(_wrap_initialise_MYINFINITY, _swig_p) + return +} + +func Initialise_MYINFINITY() { + _swig_wrap_initialise_MYINFINITY() +} + +var _wrap_use_infinity unsafe.Pointer + +func Use_infinity(arg1 float32) (_swig_ret float32) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_use_infinity, _swig_p) + return +} + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/inherit.go b/Examples/test-suite/go/inherit.go new file mode 100644 index 000000000..38bbd5f1c --- /dev/null +++ b/Examples/test-suite/go/inherit.go @@ -0,0 +1,155 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../inherit.i + +package inherit + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +var _wrap_Foo unsafe.Pointer + +func Foo() (_swig_ret string) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_Foo, _swig_p) + return +} +type SwigcptrCBase uintptr + +func (p SwigcptrCBase) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrCBase) SwigIsCBase() { +} + +var _wrap_CBase_Foo unsafe.Pointer + +func _swig_wrap_CBase_Foo(base SwigcptrCBase) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_CBase_Foo, _swig_p) + return +} + +func (arg1 SwigcptrCBase) Foo() (_swig_ret string) { + return _swig_wrap_CBase_Foo(arg1) +} + +var _wrap_new_CBase unsafe.Pointer + +func _swig_wrap_new_CBase() (base SwigcptrCBase) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_CBase, _swig_p) + return +} + +func NewCBase() (_swig_ret CBase) { + return _swig_wrap_new_CBase() +} + +var _wrap_delete_CBase unsafe.Pointer + +func _swig_wrap_delete_CBase(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_CBase, _swig_p) + return +} + +func DeleteCBase(arg1 CBase) { + _swig_wrap_delete_CBase(arg1.Swigcptr()) +} + +type CBase interface { + Swigcptr() uintptr + SwigIsCBase() + Foo() (_swig_ret string) +} + +type SwigcptrCDerived uintptr + +func (p SwigcptrCDerived) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrCDerived) SwigIsCDerived() { +} + +var _wrap_new_CDerived unsafe.Pointer + +func _swig_wrap_new_CDerived() (base SwigcptrCDerived) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_CDerived, _swig_p) + return +} + +func NewCDerived() (_swig_ret CDerived) { + return _swig_wrap_new_CDerived() +} + +var _wrap_delete_CDerived unsafe.Pointer + +func _swig_wrap_delete_CDerived(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_CDerived, _swig_p) + return +} + +func DeleteCDerived(arg1 CDerived) { + _swig_wrap_delete_CDerived(arg1.Swigcptr()) +} + +var _wrap_CDerived_Foo unsafe.Pointer + +func _swig_wrap_CDerived_Foo(base SwigcptrCDerived) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_CDerived_Foo, _swig_p) + return +} + +func (_swig_base SwigcptrCDerived) Foo() (_swig_ret string) { + return _swig_wrap_CDerived_Foo(_swig_base) +} + +func (p SwigcptrCDerived) SwigIsCBase() { +} + +func (p SwigcptrCDerived) SwigGetCBase() CBase { + return SwigcptrCBase(p.Swigcptr()) +} + +type CDerived interface { + Swigcptr() uintptr + SwigIsCDerived() + Foo() (_swig_ret string) + SwigIsCBase() + SwigGetCBase() CBase +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/inherit_missing.go b/Examples/test-suite/go/inherit_missing.go new file mode 100644 index 000000000..927944400 --- /dev/null +++ b/Examples/test-suite/go/inherit_missing.go @@ -0,0 +1,192 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../inherit_missing.i + +package inherit_missing + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrBar uintptr + +func (p SwigcptrBar) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrBar) SwigIsBar() { +} + +var _wrap_delete_Bar unsafe.Pointer + +func _swig_wrap_delete_Bar(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Bar, _swig_p) + return +} + +func DeleteBar(arg1 Bar) { + _swig_wrap_delete_Bar(arg1.Swigcptr()) +} + +var _wrap_Bar_blah unsafe.Pointer + +func _swig_wrap_Bar_blah(base SwigcptrBar) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Bar_blah, _swig_p) + return +} + +func (arg1 SwigcptrBar) Blah() (_swig_ret string) { + return _swig_wrap_Bar_blah(arg1) +} + +var _wrap_new_Bar unsafe.Pointer + +func _swig_wrap_new_Bar() (base SwigcptrBar) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Bar, _swig_p) + return +} + +func NewBar() (_swig_ret Bar) { + return _swig_wrap_new_Bar() +} + +type Bar interface { + Swigcptr() uintptr + SwigIsBar() + Blah() (_swig_ret string) +} + +type SwigcptrSpam uintptr + +func (p SwigcptrSpam) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrSpam) SwigIsSpam() { +} + +var _wrap_Spam_blah unsafe.Pointer + +func _swig_wrap_Spam_blah(base SwigcptrSpam) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Spam_blah, _swig_p) + return +} + +func (arg1 SwigcptrSpam) Blah() (_swig_ret string) { + return _swig_wrap_Spam_blah(arg1) +} + +var _wrap_new_Spam unsafe.Pointer + +func _swig_wrap_new_Spam() (base SwigcptrSpam) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Spam, _swig_p) + return +} + +func NewSpam() (_swig_ret Spam) { + return _swig_wrap_new_Spam() +} + +var _wrap_delete_Spam unsafe.Pointer + +func _swig_wrap_delete_Spam(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Spam, _swig_p) + return +} + +func DeleteSpam(arg1 Spam) { + _swig_wrap_delete_Spam(arg1.Swigcptr()) +} + +func (p SwigcptrSpam) SwigIsBar() { +} + +func (p SwigcptrSpam) SwigGetBar() Bar { + return SwigcptrBar(p.Swigcptr()) +} + +type Spam interface { + Swigcptr() uintptr + SwigIsSpam() + Blah() (_swig_ret string) + SwigIsBar() + SwigGetBar() Bar +} + +var _wrap_new_Foo unsafe.Pointer + +func _swig_wrap_new_Foo() (base SwigcptrFoo) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Foo, _swig_p) + return +} + +func New_Foo() (_swig_ret Foo) { + return _swig_wrap_new_Foo() +} + +var _wrap_delete_Foo unsafe.Pointer + +func _swig_wrap_delete_Foo(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Foo, _swig_p) + return +} + +func Delete_Foo(arg1 Foo) { + _swig_wrap_delete_Foo(arg1.Swigcptr()) +} + +var _wrap_do_blah unsafe.Pointer + +func _swig_wrap_do_blah(base uintptr) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_do_blah, _swig_p) + return +} + +func Do_blah(arg1 Foo) (_swig_ret string) { + return _swig_wrap_do_blah(arg1.Swigcptr()) +} + + +type SwigcptrFoo uintptr +type Foo interface { + Swigcptr() uintptr; +} +func (p SwigcptrFoo) Swigcptr() uintptr { + return uintptr(p) +} + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/inherit_missing_runme b/Examples/test-suite/go/inherit_missing_runme new file mode 100755 index 000000000..b8a39bc5b Binary files /dev/null and b/Examples/test-suite/go/inherit_missing_runme differ diff --git a/Examples/test-suite/go/inherit_same_name.go b/Examples/test-suite/go/inherit_same_name.go new file mode 100644 index 000000000..6993a8b93 --- /dev/null +++ b/Examples/test-suite/go/inherit_same_name.go @@ -0,0 +1,204 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../inherit_same_name.i + +package inherit_same_name + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrBase uintptr + +func (p SwigcptrBase) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrBase) SwigIsBase() { +} + +var _wrap_new_Base unsafe.Pointer + +func _swig_wrap_new_Base() (base SwigcptrBase) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Base, _swig_p) + return +} + +func NewBase() (_swig_ret Base) { + return _swig_wrap_new_Base() +} + +var _wrap_delete_Base unsafe.Pointer + +func _swig_wrap_delete_Base(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Base, _swig_p) + return +} + +func DeleteBase(arg1 Base) { + _swig_wrap_delete_Base(arg1.Swigcptr()) +} + +type Base interface { + Swigcptr() uintptr + SwigIsBase() +} + +type SwigcptrDerived uintptr + +func (p SwigcptrDerived) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrDerived) SwigIsDerived() { +} + +var _wrap_Derived_MethodOrVariable unsafe.Pointer + +func _swig_wrap_Derived_MethodOrVariable(base SwigcptrDerived) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Derived_MethodOrVariable, _swig_p) + return +} + +func (arg1 SwigcptrDerived) MethodOrVariable() { + _swig_wrap_Derived_MethodOrVariable(arg1) +} + +var _wrap_new_Derived unsafe.Pointer + +func _swig_wrap_new_Derived() (base SwigcptrDerived) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Derived, _swig_p) + return +} + +func NewDerived() (_swig_ret Derived) { + return _swig_wrap_new_Derived() +} + +var _wrap_delete_Derived unsafe.Pointer + +func _swig_wrap_delete_Derived(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Derived, _swig_p) + return +} + +func DeleteDerived(arg1 Derived) { + _swig_wrap_delete_Derived(arg1.Swigcptr()) +} + +func (p SwigcptrDerived) SwigIsBase() { +} + +func (p SwigcptrDerived) SwigGetBase() Base { + return SwigcptrBase(p.Swigcptr()) +} + +type Derived interface { + Swigcptr() uintptr + SwigIsDerived() + MethodOrVariable() + SwigIsBase() + SwigGetBase() Base +} + +type SwigcptrBottom uintptr + +func (p SwigcptrBottom) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrBottom) SwigIsBottom() { +} + +var _wrap_Bottom_MethodOrVariable unsafe.Pointer + +func _swig_wrap_Bottom_MethodOrVariable(base SwigcptrBottom) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Bottom_MethodOrVariable, _swig_p) + return +} + +func (arg1 SwigcptrBottom) MethodOrVariable() { + _swig_wrap_Bottom_MethodOrVariable(arg1) +} + +var _wrap_new_Bottom unsafe.Pointer + +func _swig_wrap_new_Bottom() (base SwigcptrBottom) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Bottom, _swig_p) + return +} + +func NewBottom() (_swig_ret Bottom) { + return _swig_wrap_new_Bottom() +} + +var _wrap_delete_Bottom unsafe.Pointer + +func _swig_wrap_delete_Bottom(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Bottom, _swig_p) + return +} + +func DeleteBottom(arg1 Bottom) { + _swig_wrap_delete_Bottom(arg1.Swigcptr()) +} + +func (p SwigcptrBottom) SwigIsDerived() { +} + +func (p SwigcptrBottom) SwigGetDerived() Derived { + return SwigcptrDerived(p.Swigcptr()) +} + +func (p SwigcptrBottom) SwigIsBase() { +} + +func (p SwigcptrBottom) SwigGetBase() Base { + return SwigcptrBase(p.Swigcptr()) +} + +type Bottom interface { + Swigcptr() uintptr + SwigIsBottom() + MethodOrVariable() + SwigIsDerived() + SwigGetDerived() Derived + SwigIsBase() + SwigGetBase() Base +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/inherit_target_language.go b/Examples/test-suite/go/inherit_target_language.go new file mode 100644 index 000000000..cb8656bdb --- /dev/null +++ b/Examples/test-suite/go/inherit_target_language.go @@ -0,0 +1,714 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../inherit_target_language.i + +package inherit_target_language + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrBase2 uintptr + +func (p SwigcptrBase2) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrBase2) SwigIsBase2() { +} + +var _wrap_delete_Base2 unsafe.Pointer + +func _swig_wrap_delete_Base2(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Base2, _swig_p) + return +} + +func DeleteBase2(arg1 Base2) { + _swig_wrap_delete_Base2(arg1.Swigcptr()) +} + +var _wrap_new_Base2 unsafe.Pointer + +func _swig_wrap_new_Base2() (base SwigcptrBase2) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Base2, _swig_p) + return +} + +func NewBase2() (_swig_ret Base2) { + return _swig_wrap_new_Base2() +} + +type Base2 interface { + Swigcptr() uintptr + SwigIsBase2() +} + +type SwigcptrDerived1 uintptr + +func (p SwigcptrDerived1) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrDerived1) SwigIsDerived1() { +} + +var _wrap_new_Derived1 unsafe.Pointer + +func _swig_wrap_new_Derived1() (base SwigcptrDerived1) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Derived1, _swig_p) + return +} + +func NewDerived1() (_swig_ret Derived1) { + return _swig_wrap_new_Derived1() +} + +var _wrap_delete_Derived1 unsafe.Pointer + +func _swig_wrap_delete_Derived1(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Derived1, _swig_p) + return +} + +func DeleteDerived1(arg1 Derived1) { + _swig_wrap_delete_Derived1(arg1.Swigcptr()) +} + +type Derived1 interface { + Swigcptr() uintptr + SwigIsDerived1() +} + +type SwigcptrDerived2 uintptr + +func (p SwigcptrDerived2) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrDerived2) SwigIsDerived2() { +} + +var _wrap_new_Derived2 unsafe.Pointer + +func _swig_wrap_new_Derived2() (base SwigcptrDerived2) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Derived2, _swig_p) + return +} + +func NewDerived2() (_swig_ret Derived2) { + return _swig_wrap_new_Derived2() +} + +var _wrap_delete_Derived2 unsafe.Pointer + +func _swig_wrap_delete_Derived2(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Derived2, _swig_p) + return +} + +func DeleteDerived2(arg1 Derived2) { + _swig_wrap_delete_Derived2(arg1.Swigcptr()) +} + +func (p SwigcptrDerived2) SwigIsBase2() { +} + +func (p SwigcptrDerived2) SwigGetBase2() Base2 { + return SwigcptrBase2(p.Swigcptr()) +} + +type Derived2 interface { + Swigcptr() uintptr + SwigIsDerived2() + SwigIsBase2() + SwigGetBase2() Base2 +} + +type SwigcptrMBase2a uintptr + +func (p SwigcptrMBase2a) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrMBase2a) SwigIsMBase2a() { +} + +var _wrap_delete_MBase2a unsafe.Pointer + +func _swig_wrap_delete_MBase2a(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_MBase2a, _swig_p) + return +} + +func DeleteMBase2a(arg1 MBase2a) { + _swig_wrap_delete_MBase2a(arg1.Swigcptr()) +} + +var _wrap_MBase2a_c unsafe.Pointer + +func _swig_wrap_MBase2a_c(base SwigcptrMBase2a) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_MBase2a_c, _swig_p) + return +} + +func (arg1 SwigcptrMBase2a) C() { + _swig_wrap_MBase2a_c(arg1) +} + +var _wrap_new_MBase2a unsafe.Pointer + +func _swig_wrap_new_MBase2a() (base SwigcptrMBase2a) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_MBase2a, _swig_p) + return +} + +func NewMBase2a() (_swig_ret MBase2a) { + return _swig_wrap_new_MBase2a() +} + +type MBase2a interface { + Swigcptr() uintptr + SwigIsMBase2a() + C() +} + +type SwigcptrMBase2b uintptr + +func (p SwigcptrMBase2b) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrMBase2b) SwigIsMBase2b() { +} + +var _wrap_delete_MBase2b unsafe.Pointer + +func _swig_wrap_delete_MBase2b(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_MBase2b, _swig_p) + return +} + +func DeleteMBase2b(arg1 MBase2b) { + _swig_wrap_delete_MBase2b(arg1.Swigcptr()) +} + +var _wrap_MBase2b_d unsafe.Pointer + +func _swig_wrap_MBase2b_d(base SwigcptrMBase2b) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_MBase2b_d, _swig_p) + return +} + +func (arg1 SwigcptrMBase2b) D() { + _swig_wrap_MBase2b_d(arg1) +} + +var _wrap_new_MBase2b unsafe.Pointer + +func _swig_wrap_new_MBase2b() (base SwigcptrMBase2b) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_MBase2b, _swig_p) + return +} + +func NewMBase2b() (_swig_ret MBase2b) { + return _swig_wrap_new_MBase2b() +} + +type MBase2b interface { + Swigcptr() uintptr + SwigIsMBase2b() + D() +} + +type SwigcptrMultipleDerived1 uintptr + +func (p SwigcptrMultipleDerived1) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrMultipleDerived1) SwigIsMultipleDerived1() { +} + +var _wrap_new_MultipleDerived1 unsafe.Pointer + +func _swig_wrap_new_MultipleDerived1() (base SwigcptrMultipleDerived1) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_MultipleDerived1, _swig_p) + return +} + +func NewMultipleDerived1() (_swig_ret MultipleDerived1) { + return _swig_wrap_new_MultipleDerived1() +} + +var _wrap_delete_MultipleDerived1 unsafe.Pointer + +func _swig_wrap_delete_MultipleDerived1(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_MultipleDerived1, _swig_p) + return +} + +func DeleteMultipleDerived1(arg1 MultipleDerived1) { + _swig_wrap_delete_MultipleDerived1(arg1.Swigcptr()) +} + +type MultipleDerived1 interface { + Swigcptr() uintptr + SwigIsMultipleDerived1() +} + +type SwigcptrMultipleDerived2 uintptr + +func (p SwigcptrMultipleDerived2) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrMultipleDerived2) SwigIsMultipleDerived2() { +} + +var _wrap_new_MultipleDerived2 unsafe.Pointer + +func _swig_wrap_new_MultipleDerived2() (base SwigcptrMultipleDerived2) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_MultipleDerived2, _swig_p) + return +} + +func NewMultipleDerived2() (_swig_ret MultipleDerived2) { + return _swig_wrap_new_MultipleDerived2() +} + +var _wrap_delete_MultipleDerived2 unsafe.Pointer + +func _swig_wrap_delete_MultipleDerived2(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_MultipleDerived2, _swig_p) + return +} + +func DeleteMultipleDerived2(arg1 MultipleDerived2) { + _swig_wrap_delete_MultipleDerived2(arg1.Swigcptr()) +} + +var _wrap_MultipleDerived2_d unsafe.Pointer + +func _swig_wrap_MultipleDerived2_d(base SwigcptrMultipleDerived2) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_MultipleDerived2_d, _swig_p) + return +} + +func (_swig_base SwigcptrMultipleDerived2) D() { + _swig_wrap_MultipleDerived2_d(_swig_base) +} + +var _wrap_MultipleDerived2_SwigGetMBase2b unsafe.Pointer + +func _swig_wrap_MultipleDerived2_SwigGetMBase2b(base SwigcptrMultipleDerived2) (_ SwigcptrMBase2b) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_MultipleDerived2_SwigGetMBase2b, _swig_p) + return +} + +func (arg1 SwigcptrMultipleDerived2) SwigGetMBase2b() (_swig_ret MBase2b) { + return _swig_wrap_MultipleDerived2_SwigGetMBase2b(arg1) +} + +type MultipleDerived2 interface { + Swigcptr() uintptr + SwigIsMultipleDerived2() + D() + SwigGetMBase2b() (_swig_ret MBase2b) +} + +type SwigcptrMBase3b uintptr + +func (p SwigcptrMBase3b) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrMBase3b) SwigIsMBase3b() { +} + +var _wrap_delete_MBase3b unsafe.Pointer + +func _swig_wrap_delete_MBase3b(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_MBase3b, _swig_p) + return +} + +func DeleteMBase3b(arg1 MBase3b) { + _swig_wrap_delete_MBase3b(arg1.Swigcptr()) +} + +var _wrap_MBase3b_f unsafe.Pointer + +func _swig_wrap_MBase3b_f(base SwigcptrMBase3b) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_MBase3b_f, _swig_p) + return +} + +func (arg1 SwigcptrMBase3b) F() { + _swig_wrap_MBase3b_f(arg1) +} + +var _wrap_new_MBase3b unsafe.Pointer + +func _swig_wrap_new_MBase3b() (base SwigcptrMBase3b) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_MBase3b, _swig_p) + return +} + +func NewMBase3b() (_swig_ret MBase3b) { + return _swig_wrap_new_MBase3b() +} + +type MBase3b interface { + Swigcptr() uintptr + SwigIsMBase3b() + F() +} + +type SwigcptrMBase4a uintptr + +func (p SwigcptrMBase4a) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrMBase4a) SwigIsMBase4a() { +} + +var _wrap_delete_MBase4a unsafe.Pointer + +func _swig_wrap_delete_MBase4a(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_MBase4a, _swig_p) + return +} + +func DeleteMBase4a(arg1 MBase4a) { + _swig_wrap_delete_MBase4a(arg1.Swigcptr()) +} + +var _wrap_MBase4a_g unsafe.Pointer + +func _swig_wrap_MBase4a_g(base SwigcptrMBase4a) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_MBase4a_g, _swig_p) + return +} + +func (arg1 SwigcptrMBase4a) G() { + _swig_wrap_MBase4a_g(arg1) +} + +var _wrap_new_MBase4a unsafe.Pointer + +func _swig_wrap_new_MBase4a() (base SwigcptrMBase4a) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_MBase4a, _swig_p) + return +} + +func NewMBase4a() (_swig_ret MBase4a) { + return _swig_wrap_new_MBase4a() +} + +type MBase4a interface { + Swigcptr() uintptr + SwigIsMBase4a() + G() +} + +type SwigcptrMultipleDerived3 uintptr + +func (p SwigcptrMultipleDerived3) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrMultipleDerived3) SwigIsMultipleDerived3() { +} + +var _wrap_new_MultipleDerived3 unsafe.Pointer + +func _swig_wrap_new_MultipleDerived3() (base SwigcptrMultipleDerived3) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_MultipleDerived3, _swig_p) + return +} + +func NewMultipleDerived3() (_swig_ret MultipleDerived3) { + return _swig_wrap_new_MultipleDerived3() +} + +var _wrap_delete_MultipleDerived3 unsafe.Pointer + +func _swig_wrap_delete_MultipleDerived3(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_MultipleDerived3, _swig_p) + return +} + +func DeleteMultipleDerived3(arg1 MultipleDerived3) { + _swig_wrap_delete_MultipleDerived3(arg1.Swigcptr()) +} + +var _wrap_MultipleDerived3_f unsafe.Pointer + +func _swig_wrap_MultipleDerived3_f(base SwigcptrMultipleDerived3) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_MultipleDerived3_f, _swig_p) + return +} + +func (_swig_base SwigcptrMultipleDerived3) F() { + _swig_wrap_MultipleDerived3_f(_swig_base) +} + +var _wrap_MultipleDerived3_SwigGetMBase3b unsafe.Pointer + +func _swig_wrap_MultipleDerived3_SwigGetMBase3b(base SwigcptrMultipleDerived3) (_ SwigcptrMBase3b) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_MultipleDerived3_SwigGetMBase3b, _swig_p) + return +} + +func (arg1 SwigcptrMultipleDerived3) SwigGetMBase3b() (_swig_ret MBase3b) { + return _swig_wrap_MultipleDerived3_SwigGetMBase3b(arg1) +} + +type MultipleDerived3 interface { + Swigcptr() uintptr + SwigIsMultipleDerived3() + F() + SwigGetMBase3b() (_swig_ret MBase3b) +} + +type SwigcptrMultipleDerived4 uintptr + +func (p SwigcptrMultipleDerived4) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrMultipleDerived4) SwigIsMultipleDerived4() { +} + +var _wrap_new_MultipleDerived4 unsafe.Pointer + +func _swig_wrap_new_MultipleDerived4() (base SwigcptrMultipleDerived4) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_MultipleDerived4, _swig_p) + return +} + +func NewMultipleDerived4() (_swig_ret MultipleDerived4) { + return _swig_wrap_new_MultipleDerived4() +} + +var _wrap_delete_MultipleDerived4 unsafe.Pointer + +func _swig_wrap_delete_MultipleDerived4(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_MultipleDerived4, _swig_p) + return +} + +func DeleteMultipleDerived4(arg1 MultipleDerived4) { + _swig_wrap_delete_MultipleDerived4(arg1.Swigcptr()) +} + +var _wrap_MultipleDerived4_g unsafe.Pointer + +func _swig_wrap_MultipleDerived4_g(base SwigcptrMultipleDerived4) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_MultipleDerived4_g, _swig_p) + return +} + +func (_swig_base SwigcptrMultipleDerived4) G() { + _swig_wrap_MultipleDerived4_g(_swig_base) +} + +func (p SwigcptrMultipleDerived4) SwigIsMBase4a() { +} + +func (p SwigcptrMultipleDerived4) SwigGetMBase4a() MBase4a { + return SwigcptrMBase4a(p.Swigcptr()) +} + +type MultipleDerived4 interface { + Swigcptr() uintptr + SwigIsMultipleDerived4() + G() + SwigIsMBase4a() + SwigGetMBase4a() MBase4a +} + +type SwigcptrBaseX uintptr + +func (p SwigcptrBaseX) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrBaseX) SwigIsBaseX() { +} + +var _wrap_delete_BaseX unsafe.Pointer + +func _swig_wrap_delete_BaseX(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_BaseX, _swig_p) + return +} + +func DeleteBaseX(arg1 BaseX) { + _swig_wrap_delete_BaseX(arg1.Swigcptr()) +} + +var _wrap_BaseX_basex unsafe.Pointer + +func _swig_wrap_BaseX_basex(base SwigcptrBaseX) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_BaseX_basex, _swig_p) + return +} + +func (arg1 SwigcptrBaseX) Basex() { + _swig_wrap_BaseX_basex(arg1) +} + +var _wrap_new_BaseX unsafe.Pointer + +func _swig_wrap_new_BaseX() (base SwigcptrBaseX) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_BaseX, _swig_p) + return +} + +func NewBaseX() (_swig_ret BaseX) { + return _swig_wrap_new_BaseX() +} + +type BaseX interface { + Swigcptr() uintptr + SwigIsBaseX() + Basex() +} + +type SwigcptrDerivedX uintptr + +func (p SwigcptrDerivedX) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrDerivedX) SwigIsDerivedX() { +} + +var _wrap_DerivedX_derivedx unsafe.Pointer + +func _swig_wrap_DerivedX_derivedx(base SwigcptrDerivedX) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_DerivedX_derivedx, _swig_p) + return +} + +func (arg1 SwigcptrDerivedX) Derivedx() { + _swig_wrap_DerivedX_derivedx(arg1) +} + +var _wrap_new_DerivedX unsafe.Pointer + +func _swig_wrap_new_DerivedX() (base SwigcptrDerivedX) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_DerivedX, _swig_p) + return +} + +func NewDerivedX() (_swig_ret DerivedX) { + return _swig_wrap_new_DerivedX() +} + +var _wrap_delete_DerivedX unsafe.Pointer + +func _swig_wrap_delete_DerivedX(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_DerivedX, _swig_p) + return +} + +func DeleteDerivedX(arg1 DerivedX) { + _swig_wrap_delete_DerivedX(arg1.Swigcptr()) +} + +var _wrap_DerivedX_basex unsafe.Pointer + +func _swig_wrap_DerivedX_basex(base SwigcptrDerivedX) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_DerivedX_basex, _swig_p) + return +} + +func (_swig_base SwigcptrDerivedX) Basex() { + _swig_wrap_DerivedX_basex(_swig_base) +} + +func (p SwigcptrDerivedX) SwigIsBaseX() { +} + +func (p SwigcptrDerivedX) SwigGetBaseX() BaseX { + return SwigcptrBaseX(p.Swigcptr()) +} + +type DerivedX interface { + Swigcptr() uintptr + SwigIsDerivedX() + Derivedx() + Basex() + SwigIsBaseX() + SwigGetBaseX() BaseX +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/inherit_void_arg.go b/Examples/test-suite/go/inherit_void_arg.go new file mode 100644 index 000000000..45f811ccf --- /dev/null +++ b/Examples/test-suite/go/inherit_void_arg.go @@ -0,0 +1,136 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../inherit_void_arg.i + +package inherit_void_arg + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrA uintptr + +func (p SwigcptrA) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrA) SwigIsA() { +} + +var _wrap_delete_A unsafe.Pointer + +func _swig_wrap_delete_A(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_A, _swig_p) + return +} + +func DeleteA(arg1 A) { + _swig_wrap_delete_A(arg1.Swigcptr()) +} + +var _wrap_A_f unsafe.Pointer + +func _swig_wrap_A_f(base SwigcptrA) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_A_f, _swig_p) + return +} + +func (arg1 SwigcptrA) F() { + _swig_wrap_A_f(arg1) +} + +type A interface { + Swigcptr() uintptr + SwigIsA() + F() +} + +type SwigcptrB uintptr + +func (p SwigcptrB) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrB) SwigIsB() { +} + +var _wrap_B_f unsafe.Pointer + +func _swig_wrap_B_f(base SwigcptrB) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_B_f, _swig_p) + return +} + +func (arg1 SwigcptrB) F() { + _swig_wrap_B_f(arg1) +} + +var _wrap_new_B unsafe.Pointer + +func _swig_wrap_new_B() (base SwigcptrB) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_B, _swig_p) + return +} + +func NewB() (_swig_ret B) { + return _swig_wrap_new_B() +} + +var _wrap_delete_B unsafe.Pointer + +func _swig_wrap_delete_B(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_B, _swig_p) + return +} + +func DeleteB(arg1 B) { + _swig_wrap_delete_B(arg1.Swigcptr()) +} + +func (p SwigcptrB) SwigIsA() { +} + +func (p SwigcptrB) SwigGetA() A { + return SwigcptrA(p.Swigcptr()) +} + +type B interface { + Swigcptr() uintptr + SwigIsB() + F() + SwigIsA() + SwigGetA() A +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/inline_initializer.go b/Examples/test-suite/go/inline_initializer.go new file mode 100644 index 000000000..7bcc24cbb --- /dev/null +++ b/Examples/test-suite/go/inline_initializer.go @@ -0,0 +1,75 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../inline_initializer.i + +package inline_initializer + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrFoo uintptr + +func (p SwigcptrFoo) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrFoo) SwigIsFoo() { +} + +var _wrap_new_Foo unsafe.Pointer + +func _swig_wrap_new_Foo(base int) (_ SwigcptrFoo) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Foo, _swig_p) + return +} + +func NewFoo(arg1 int) (_swig_ret Foo) { + return _swig_wrap_new_Foo(arg1) +} + +var _wrap_delete_Foo unsafe.Pointer + +func _swig_wrap_delete_Foo(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Foo, _swig_p) + return +} + +func DeleteFoo(arg1 Foo) { + _swig_wrap_delete_Foo(arg1.Swigcptr()) +} + +type Foo interface { + Swigcptr() uintptr + SwigIsFoo() +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/insert_directive.go b/Examples/test-suite/go/insert_directive.go new file mode 100644 index 000000000..2ba7b644b --- /dev/null +++ b/Examples/test-suite/go/insert_directive.go @@ -0,0 +1,29 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../insert_directive.i + +package insert_directive + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + + diff --git a/Examples/test-suite/go/integers.go b/Examples/test-suite/go/integers.go new file mode 100644 index 000000000..7807af933 --- /dev/null +++ b/Examples/test-suite/go/integers.go @@ -0,0 +1,169 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../integers.i + +package integers + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +var _wrap_signed_char_identity unsafe.Pointer + +func Signed_char_identity(arg1 int8) (_swig_ret int8) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_signed_char_identity, _swig_p) + return +} +var _wrap_unsigned_char_identity unsafe.Pointer + +func Unsigned_char_identity(arg1 byte) (_swig_ret byte) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_unsigned_char_identity, _swig_p) + return +} +var _wrap_signed_short_identity unsafe.Pointer + +func Signed_short_identity(arg1 int16) (_swig_ret int16) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_signed_short_identity, _swig_p) + return +} +var _wrap_unsigned_short_identity unsafe.Pointer + +func Unsigned_short_identity(arg1 uint16) (_swig_ret uint16) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_unsigned_short_identity, _swig_p) + return +} +var _wrap_signed_int_identity unsafe.Pointer + +func Signed_int_identity(arg1 int) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_signed_int_identity, _swig_p) + return +} +var _wrap_unsigned_int_identity unsafe.Pointer + +func Unsigned_int_identity(arg1 uint) (_swig_ret uint) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_unsigned_int_identity, _swig_p) + return +} +var _wrap_signed_long_identity unsafe.Pointer + +func Signed_long_identity(arg1 int64) (_swig_ret int64) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_signed_long_identity, _swig_p) + return +} +var _wrap_unsigned_long_identity unsafe.Pointer + +func Unsigned_long_identity(arg1 uint64) (_swig_ret uint64) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_unsigned_long_identity, _swig_p) + return +} +var _wrap_signed_long_long_identity unsafe.Pointer + +func Signed_long_long_identity(arg1 int64) (_swig_ret int64) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_signed_long_long_identity, _swig_p) + return +} +var _wrap_unsigned_long_long_identity unsafe.Pointer + +func Unsigned_long_long_identity(arg1 uint64) (_swig_ret uint64) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_unsigned_long_long_identity, _swig_p) + return +} +var _wrap_signed_char_size unsafe.Pointer + +func Signed_char_size() (_swig_ret int64) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_signed_char_size, _swig_p) + return +} +var _wrap_unsigned_char_size unsafe.Pointer + +func Unsigned_char_size() (_swig_ret int64) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_unsigned_char_size, _swig_p) + return +} +var _wrap_signed_short_size unsafe.Pointer + +func Signed_short_size() (_swig_ret int64) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_signed_short_size, _swig_p) + return +} +var _wrap_unsigned_short_size unsafe.Pointer + +func Unsigned_short_size() (_swig_ret int64) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_unsigned_short_size, _swig_p) + return +} +var _wrap_signed_int_size unsafe.Pointer + +func Signed_int_size() (_swig_ret int64) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_signed_int_size, _swig_p) + return +} +var _wrap_unsigned_int_size unsafe.Pointer + +func Unsigned_int_size() (_swig_ret int64) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_unsigned_int_size, _swig_p) + return +} +var _wrap_signed_long_size unsafe.Pointer + +func Signed_long_size() (_swig_ret int64) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_signed_long_size, _swig_p) + return +} +var _wrap_unsigned_long_size unsafe.Pointer + +func Unsigned_long_size() (_swig_ret int64) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_unsigned_long_size, _swig_p) + return +} +var _wrap_signed_long_long_size unsafe.Pointer + +func Signed_long_long_size() (_swig_ret int64) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_signed_long_long_size, _swig_p) + return +} +var _wrap_unsigned_long_long_size unsafe.Pointer + +func Unsigned_long_long_size() (_swig_ret int64) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_unsigned_long_long_size, _swig_p) + return +} + diff --git a/Examples/test-suite/go/keyword_rename.go b/Examples/test-suite/go/keyword_rename.go new file mode 100644 index 000000000..94fe44d5c --- /dev/null +++ b/Examples/test-suite/go/keyword_rename.go @@ -0,0 +1,185 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../keyword_rename.i + +package keyword_rename + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +var _wrap_in unsafe.Pointer + +func In(arg1 int) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_in, _swig_p) + return +} +var _wrap_except unsafe.Pointer + +func Except(arg1 int) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_except, _swig_p) + return +} +var _wrap_pass unsafe.Pointer + +func Pass(arg1 int) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_pass, _swig_p) + return +} +var _wrap_tie unsafe.Pointer + +func Tie(arg1 int) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_tie, _swig_p) + return +} +var _wrap_use unsafe.Pointer + +func Use(arg1 int) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_use, _swig_p) + return +} +var _wrap_implements unsafe.Pointer + +func Implements(arg1 int) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_implements, _swig_p) + return +} +var _wrap_synchronized unsafe.Pointer + +func Synchronized(arg1 int) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_synchronized, _swig_p) + return +} +var _wrap_string unsafe.Pointer + +func String(arg1 int) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_string, _swig_p) + return +} +type SwigcptrSealed uintptr + +func (p SwigcptrSealed) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrSealed) SwigIsSealed() { +} + +var _wrap_sealed_i_set unsafe.Pointer + +func _swig_wrap_sealed_i_set(base SwigcptrSealed, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_sealed_i_set, _swig_p) + return +} + +func (arg1 SwigcptrSealed) SetI(arg2 int) { + _swig_wrap_sealed_i_set(arg1, arg2) +} + +var _wrap_sealed_i_get unsafe.Pointer + +func _swig_wrap_sealed_i_get(base SwigcptrSealed) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_sealed_i_get, _swig_p) + return +} + +func (arg1 SwigcptrSealed) GetI() (_swig_ret int) { + return _swig_wrap_sealed_i_get(arg1) +} + +var _wrap_new_sealed unsafe.Pointer + +func _swig_wrap_new_sealed() (base SwigcptrSealed) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_sealed, _swig_p) + return +} + +func NewSealed() (_swig_ret Sealed) { + return _swig_wrap_new_sealed() +} + +var _wrap_delete_sealed unsafe.Pointer + +func _swig_wrap_delete_sealed(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_sealed, _swig_p) + return +} + +func DeleteSealed(arg1 Sealed) { + _swig_wrap_delete_sealed(arg1.Swigcptr()) +} + +type Sealed interface { + Swigcptr() uintptr + SwigIsSealed() + SetI(arg2 int) + GetI() (_swig_ret int) +} + +var _wrap_Xgo unsafe.Pointer + +func Xgo(arg1 int) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_Xgo, _swig_p) + return +} +var _wrap_Xchan unsafe.Pointer + +func Xchan(arg1 int) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_Xchan, _swig_p) + return +} +var _wrap_end unsafe.Pointer + +func End(arg1 int) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_end, _swig_p) + return +} +var _wrap_nil unsafe.Pointer + +func Nil(arg1 int) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_nil, _swig_p) + return +} + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/keyword_rename_runme b/Examples/test-suite/go/keyword_rename_runme new file mode 100755 index 000000000..b6ae7fe73 Binary files /dev/null and b/Examples/test-suite/go/keyword_rename_runme differ diff --git a/Examples/test-suite/go/kind.go b/Examples/test-suite/go/kind.go new file mode 100644 index 000000000..79eaeeeb2 --- /dev/null +++ b/Examples/test-suite/go/kind.go @@ -0,0 +1,392 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../kind.i + +package kind + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrFoo uintptr + +func (p SwigcptrFoo) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrFoo) SwigIsFoo() { +} + +var _wrap_new_foo unsafe.Pointer + +func _swig_wrap_new_foo() (base SwigcptrFoo) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_foo, _swig_p) + return +} + +func NewFoo() (_swig_ret Foo) { + return _swig_wrap_new_foo() +} + +var _wrap_delete_foo unsafe.Pointer + +func _swig_wrap_delete_foo(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_foo, _swig_p) + return +} + +func DeleteFoo(arg1 Foo) { + _swig_wrap_delete_foo(arg1.Swigcptr()) +} + +type Foo interface { + Swigcptr() uintptr + SwigIsFoo() +} + +type SwigcptrBar uintptr + +func (p SwigcptrBar) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrBar) SwigIsBar() { +} + +var _wrap_new_bar unsafe.Pointer + +func _swig_wrap_new_bar() (base SwigcptrBar) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_bar, _swig_p) + return +} + +func NewBar() (_swig_ret Bar) { + return _swig_wrap_new_bar() +} + +var _wrap_delete_bar unsafe.Pointer + +func _swig_wrap_delete_bar(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_bar, _swig_p) + return +} + +func DeleteBar(arg1 Bar) { + _swig_wrap_delete_bar(arg1.Swigcptr()) +} + +type Bar interface { + Swigcptr() uintptr + SwigIsBar() +} + +type SwigcptrUni uintptr + +func (p SwigcptrUni) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrUni) SwigIsUni() { +} + +var _wrap_new_uni unsafe.Pointer + +func _swig_wrap_new_uni() (base SwigcptrUni) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_uni, _swig_p) + return +} + +func NewUni() (_swig_ret Uni) { + return _swig_wrap_new_uni() +} + +var _wrap_delete_uni unsafe.Pointer + +func _swig_wrap_delete_uni(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_uni, _swig_p) + return +} + +func DeleteUni(arg1 Uni) { + _swig_wrap_delete_uni(arg1.Swigcptr()) +} + +type Uni interface { + Swigcptr() uintptr + SwigIsUni() +} + +type SwigcptrTest uintptr + +func (p SwigcptrTest) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrTest) SwigIsTest() { +} + +var _wrap_test_foofn unsafe.Pointer + +func _swig_wrap_test_foofn(base SwigcptrTest, _ uintptr, _ uintptr, _ uintptr, _ uintptr, _ uintptr, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_test_foofn, _swig_p) + return +} + +func (arg1 SwigcptrTest) Foofn(arg2 Foo, arg3 Foo, arg4 Foo, arg5 Foo, arg6 Foo, arg7 Foo) { + _swig_wrap_test_foofn(arg1, arg2.Swigcptr(), arg3.Swigcptr(), arg4.Swigcptr(), arg5.Swigcptr(), arg6.Swigcptr(), arg7.Swigcptr()) +} + +var _wrap_test_barfn unsafe.Pointer + +func _swig_wrap_test_barfn(base SwigcptrTest, _ uintptr, _ uintptr, _ uintptr, _ uintptr, _ uintptr, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_test_barfn, _swig_p) + return +} + +func (arg1 SwigcptrTest) Barfn(arg2 Bar, arg3 Bar, arg4 Bar, arg5 Bar, arg6 Bar, arg7 Bar) { + _swig_wrap_test_barfn(arg1, arg2.Swigcptr(), arg3.Swigcptr(), arg4.Swigcptr(), arg5.Swigcptr(), arg6.Swigcptr(), arg7.Swigcptr()) +} + +var _wrap_test_unifn unsafe.Pointer + +func _swig_wrap_test_unifn(base SwigcptrTest, _ uintptr, _ uintptr, _ uintptr, _ uintptr, _ uintptr, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_test_unifn, _swig_p) + return +} + +func (arg1 SwigcptrTest) Unifn(arg2 Uni, arg3 Uni, arg4 Uni, arg5 Uni, arg6 Myuni, arg7 Myuni) { + _swig_wrap_test_unifn(arg1, arg2.Swigcptr(), arg3.Swigcptr(), arg4.Swigcptr(), arg5.Swigcptr(), arg6.Swigcptr(), arg7.Swigcptr()) +} + +var _wrap_test_myFooMember_set unsafe.Pointer + +func _swig_wrap_test_myFooMember_set(base SwigcptrTest, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_test_myFooMember_set, _swig_p) + return +} + +func (arg1 SwigcptrTest) SetMyFooMember(arg2 Foo) { + _swig_wrap_test_myFooMember_set(arg1, arg2.Swigcptr()) +} + +var _wrap_test_myFooMember_get unsafe.Pointer + +func _swig_wrap_test_myFooMember_get(base SwigcptrTest) (_ SwigcptrFoo) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_test_myFooMember_get, _swig_p) + return +} + +func (arg1 SwigcptrTest) GetMyFooMember() (_swig_ret Foo) { + return _swig_wrap_test_myFooMember_get(arg1) +} + +var _wrap_test_myBarMember_set unsafe.Pointer + +func _swig_wrap_test_myBarMember_set(base SwigcptrTest, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_test_myBarMember_set, _swig_p) + return +} + +func (arg1 SwigcptrTest) SetMyBarMember(arg2 Bar) { + _swig_wrap_test_myBarMember_set(arg1, arg2.Swigcptr()) +} + +var _wrap_test_myBarMember_get unsafe.Pointer + +func _swig_wrap_test_myBarMember_get(base SwigcptrTest) (_ SwigcptrBar) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_test_myBarMember_get, _swig_p) + return +} + +func (arg1 SwigcptrTest) GetMyBarMember() (_swig_ret Bar) { + return _swig_wrap_test_myBarMember_get(arg1) +} + +var _wrap_test_myUniMember_set unsafe.Pointer + +func _swig_wrap_test_myUniMember_set(base SwigcptrTest, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_test_myUniMember_set, _swig_p) + return +} + +func (arg1 SwigcptrTest) SetMyUniMember(arg2 Uni) { + _swig_wrap_test_myUniMember_set(arg1, arg2.Swigcptr()) +} + +var _wrap_test_myUniMember_get unsafe.Pointer + +func _swig_wrap_test_myUniMember_get(base SwigcptrTest) (_ SwigcptrUni) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_test_myUniMember_get, _swig_p) + return +} + +func (arg1 SwigcptrTest) GetMyUniMember() (_swig_ret Uni) { + return _swig_wrap_test_myUniMember_get(arg1) +} + +var _wrap_test_mypFooMember_set unsafe.Pointer + +func _swig_wrap_test_mypFooMember_set(base SwigcptrTest, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_test_mypFooMember_set, _swig_p) + return +} + +func (arg1 SwigcptrTest) SetMypFooMember(arg2 Foo) { + _swig_wrap_test_mypFooMember_set(arg1, arg2.Swigcptr()) +} + +var _wrap_test_mypFooMember_get unsafe.Pointer + +func _swig_wrap_test_mypFooMember_get(base SwigcptrTest) (_ SwigcptrFoo) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_test_mypFooMember_get, _swig_p) + return +} + +func (arg1 SwigcptrTest) GetMypFooMember() (_swig_ret Foo) { + return _swig_wrap_test_mypFooMember_get(arg1) +} + +var _wrap_test_mypBarMember_set unsafe.Pointer + +func _swig_wrap_test_mypBarMember_set(base SwigcptrTest, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_test_mypBarMember_set, _swig_p) + return +} + +func (arg1 SwigcptrTest) SetMypBarMember(arg2 Bar) { + _swig_wrap_test_mypBarMember_set(arg1, arg2.Swigcptr()) +} + +var _wrap_test_mypBarMember_get unsafe.Pointer + +func _swig_wrap_test_mypBarMember_get(base SwigcptrTest) (_ SwigcptrBar) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_test_mypBarMember_get, _swig_p) + return +} + +func (arg1 SwigcptrTest) GetMypBarMember() (_swig_ret Bar) { + return _swig_wrap_test_mypBarMember_get(arg1) +} + +var _wrap_test_mypUniMember_set unsafe.Pointer + +func _swig_wrap_test_mypUniMember_set(base SwigcptrTest, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_test_mypUniMember_set, _swig_p) + return +} + +func (arg1 SwigcptrTest) SetMypUniMember(arg2 Uni) { + _swig_wrap_test_mypUniMember_set(arg1, arg2.Swigcptr()) +} + +var _wrap_test_mypUniMember_get unsafe.Pointer + +func _swig_wrap_test_mypUniMember_get(base SwigcptrTest) (_ SwigcptrUni) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_test_mypUniMember_get, _swig_p) + return +} + +func (arg1 SwigcptrTest) GetMypUniMember() (_swig_ret Uni) { + return _swig_wrap_test_mypUniMember_get(arg1) +} + +var _wrap_new_test unsafe.Pointer + +func _swig_wrap_new_test() (base SwigcptrTest) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_test, _swig_p) + return +} + +func NewTest() (_swig_ret Test) { + return _swig_wrap_new_test() +} + +var _wrap_delete_test unsafe.Pointer + +func _swig_wrap_delete_test(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_test, _swig_p) + return +} + +func DeleteTest(arg1 Test) { + _swig_wrap_delete_test(arg1.Swigcptr()) +} + +type Test interface { + Swigcptr() uintptr + SwigIsTest() + Foofn(arg2 Foo, arg3 Foo, arg4 Foo, arg5 Foo, arg6 Foo, arg7 Foo) + Barfn(arg2 Bar, arg3 Bar, arg4 Bar, arg5 Bar, arg6 Bar, arg7 Bar) + Unifn(arg2 Uni, arg3 Uni, arg4 Uni, arg5 Uni, arg6 Myuni, arg7 Myuni) + SetMyFooMember(arg2 Foo) + GetMyFooMember() (_swig_ret Foo) + SetMyBarMember(arg2 Bar) + GetMyBarMember() (_swig_ret Bar) + SetMyUniMember(arg2 Uni) + GetMyUniMember() (_swig_ret Uni) + SetMypFooMember(arg2 Foo) + GetMypFooMember() (_swig_ret Foo) + SetMypBarMember(arg2 Bar) + GetMypBarMember() (_swig_ret Bar) + SetMypUniMember(arg2 Uni) + GetMypUniMember() (_swig_ret Uni) +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + +type SwigcptrMyuni uintptr +type Myuni interface { + Swigcptr() uintptr; +} +func (p SwigcptrMyuni) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/langobj.go b/Examples/test-suite/go/langobj.go new file mode 100644 index 000000000..36aa23339 --- /dev/null +++ b/Examples/test-suite/go/langobj.go @@ -0,0 +1,36 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../langobj.i + +package langobj + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +var _wrap_identity unsafe.Pointer + +func Identity(arg1 uintptr) (_swig_ret uintptr) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_identity, _swig_p) + return +} + diff --git a/Examples/test-suite/go/lextype.go b/Examples/test-suite/go/lextype.go new file mode 100644 index 000000000..7aa39bfcb --- /dev/null +++ b/Examples/test-suite/go/lextype.go @@ -0,0 +1,70 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../lextype.i + +package lextype + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +const HEIGHT_Giraffe int = 100 +const WIDTH_Giraffe int = 5 +var _wrap_eat unsafe.Pointer + +func _swig_wrap_eat(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_eat, _swig_p) + return +} + +func Eat(arg1 uintptr) { + _swig_wrap_eat(arg1) +} + +var _wrap_drink unsafe.Pointer + +func _swig_wrap_drink(base *uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_drink, _swig_p) + return +} + +func Drink(arg1 *uintptr) { + _swig_wrap_drink(arg1) +} + +var _wrap_mate unsafe.Pointer + +func Mate(arg1 *uintptr) (_swig_ret uintptr) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_mate, _swig_p) + return +} + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/li_attribute.go b/Examples/test-suite/go/li_attribute.go new file mode 100644 index 000000000..be5331738 --- /dev/null +++ b/Examples/test-suite/go/li_attribute.go @@ -0,0 +1,576 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../li_attribute.i + +package li_attribute + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrA uintptr + +func (p SwigcptrA) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrA) SwigIsA() { +} + +var _wrap_new_A unsafe.Pointer + +func _swig_wrap_new_A(base int, _ int, _ int) (_ SwigcptrA) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_A, _swig_p) + return +} + +func NewA(arg1 int, arg2 int, arg3 int) (_swig_ret A) { + return _swig_wrap_new_A(arg1, arg2, arg3) +} + +var _wrap_A_a_set unsafe.Pointer + +func _swig_wrap_A_a_set(base SwigcptrA, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_A_a_set, _swig_p) + return +} + +func (arg1 SwigcptrA) SetA(arg2 int) { + _swig_wrap_A_a_set(arg1, arg2) +} + +var _wrap_A_a_get unsafe.Pointer + +func _swig_wrap_A_a_get(base SwigcptrA) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_A_a_get, _swig_p) + return +} + +func (arg1 SwigcptrA) GetA() (_swig_ret int) { + return _swig_wrap_A_a_get(arg1) +} + +var _wrap_A_b_set unsafe.Pointer + +func _swig_wrap_A_b_set(base SwigcptrA, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_A_b_set, _swig_p) + return +} + +func (arg1 SwigcptrA) SetB(arg2 int) { + _swig_wrap_A_b_set(arg1, arg2) +} + +var _wrap_A_b_get unsafe.Pointer + +func _swig_wrap_A_b_get(base SwigcptrA) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_A_b_get, _swig_p) + return +} + +func (arg1 SwigcptrA) GetB() (_swig_ret int) { + return _swig_wrap_A_b_get(arg1) +} + +var _wrap_A_c_get unsafe.Pointer + +func _swig_wrap_A_c_get(base SwigcptrA) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_A_c_get, _swig_p) + return +} + +func (arg1 SwigcptrA) GetC() (_swig_ret int) { + return _swig_wrap_A_c_get(arg1) +} + +var _wrap_A_d_set unsafe.Pointer + +func _swig_wrap_A_d_set(base SwigcptrA, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_A_d_set, _swig_p) + return +} + +func (arg1 SwigcptrA) SetD(arg2 int) { + _swig_wrap_A_d_set(arg1, arg2) +} + +var _wrap_A_d_get unsafe.Pointer + +func _swig_wrap_A_d_get(base SwigcptrA) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_A_d_get, _swig_p) + return +} + +func (arg1 SwigcptrA) GetD() (_swig_ret int) { + return _swig_wrap_A_d_get(arg1) +} + +var _wrap_delete_A unsafe.Pointer + +func _swig_wrap_delete_A(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_A, _swig_p) + return +} + +func DeleteA(arg1 A) { + _swig_wrap_delete_A(arg1.Swigcptr()) +} + +type A interface { + Swigcptr() uintptr + SwigIsA() + SetA(arg2 int) + GetA() (_swig_ret int) + SetB(arg2 int) + GetB() (_swig_ret int) + GetC() (_swig_ret int) + SetD(arg2 int) + GetD() (_swig_ret int) +} + +type SwigcptrB uintptr + +func (p SwigcptrB) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrB) SwigIsB() { +} + +var _wrap_new_B unsafe.Pointer + +func _swig_wrap_new_B(base uintptr) (_ SwigcptrB) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_B, _swig_p) + return +} + +func NewB(arg1 A) (_swig_ret B) { + return _swig_wrap_new_B(arg1.Swigcptr()) +} + +var _wrap_B_a_set unsafe.Pointer + +func _swig_wrap_B_a_set(base SwigcptrB, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_B_a_set, _swig_p) + return +} + +func (arg1 SwigcptrB) SetA(arg2 A) { + _swig_wrap_B_a_set(arg1, arg2.Swigcptr()) +} + +var _wrap_B_a_get unsafe.Pointer + +func _swig_wrap_B_a_get(base SwigcptrB) (_ SwigcptrA) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_B_a_get, _swig_p) + return +} + +func (arg1 SwigcptrB) GetA() (_swig_ret A) { + return _swig_wrap_B_a_get(arg1) +} + +var _wrap_delete_B unsafe.Pointer + +func _swig_wrap_delete_B(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_B, _swig_p) + return +} + +func DeleteB(arg1 B) { + _swig_wrap_delete_B(arg1.Swigcptr()) +} + +type B interface { + Swigcptr() uintptr + SwigIsB() + SetA(arg2 A) + GetA() (_swig_ret A) +} + +type SwigcptrParam_i uintptr + +func (p SwigcptrParam_i) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrParam_i) SwigIsParam_i() { +} + +var _wrap_new_Param_i unsafe.Pointer + +func _swig_wrap_new_Param_i(base int) (_ SwigcptrParam_i) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Param_i, _swig_p) + return +} + +func NewParam_i(arg1 int) (_swig_ret Param_i) { + return _swig_wrap_new_Param_i(arg1) +} + +var _wrap_Param_i_value_set unsafe.Pointer + +func _swig_wrap_Param_i_value_set(base SwigcptrParam_i, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Param_i_value_set, _swig_p) + return +} + +func (arg1 SwigcptrParam_i) SetValue(arg2 int) { + _swig_wrap_Param_i_value_set(arg1, arg2) +} + +var _wrap_Param_i_value_get unsafe.Pointer + +func _swig_wrap_Param_i_value_get(base SwigcptrParam_i) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Param_i_value_get, _swig_p) + return +} + +func (arg1 SwigcptrParam_i) GetValue() (_swig_ret int) { + return _swig_wrap_Param_i_value_get(arg1) +} + +var _wrap_delete_Param_i unsafe.Pointer + +func _swig_wrap_delete_Param_i(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Param_i, _swig_p) + return +} + +func DeleteParam_i(arg1 Param_i) { + _swig_wrap_delete_Param_i(arg1.Swigcptr()) +} + +type Param_i interface { + Swigcptr() uintptr + SwigIsParam_i() + SetValue(arg2 int) + GetValue() (_swig_ret int) +} + +type SwigcptrMyFoo uintptr + +func (p SwigcptrMyFoo) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrMyFoo) SwigIsMyFoo() { +} + +var _wrap_new_MyFoo unsafe.Pointer + +func _swig_wrap_new_MyFoo() (base SwigcptrMyFoo) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_MyFoo, _swig_p) + return +} + +func NewMyFoo() (_swig_ret MyFoo) { + return _swig_wrap_new_MyFoo() +} + +var _wrap_MyFoo_x_set unsafe.Pointer + +func _swig_wrap_MyFoo_x_set(base SwigcptrMyFoo, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_MyFoo_x_set, _swig_p) + return +} + +func (arg1 SwigcptrMyFoo) SetX(arg2 int) { + _swig_wrap_MyFoo_x_set(arg1, arg2) +} + +var _wrap_MyFoo_x_get unsafe.Pointer + +func _swig_wrap_MyFoo_x_get(base SwigcptrMyFoo) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_MyFoo_x_get, _swig_p) + return +} + +func (arg1 SwigcptrMyFoo) GetX() (_swig_ret int) { + return _swig_wrap_MyFoo_x_get(arg1) +} + +var _wrap_delete_MyFoo unsafe.Pointer + +func _swig_wrap_delete_MyFoo(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_MyFoo, _swig_p) + return +} + +func DeleteMyFoo(arg1 MyFoo) { + _swig_wrap_delete_MyFoo(arg1.Swigcptr()) +} + +type MyFoo interface { + Swigcptr() uintptr + SwigIsMyFoo() + SetX(arg2 int) + GetX() (_swig_ret int) +} + +type SwigcptrMyClass uintptr + +func (p SwigcptrMyClass) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrMyClass) SwigIsMyClass() { +} + +var _wrap_MyClass_Foo_set unsafe.Pointer + +func _swig_wrap_MyClass_Foo_set(base SwigcptrMyClass, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_MyClass_Foo_set, _swig_p) + return +} + +func (arg1 SwigcptrMyClass) SetFoo(arg2 MyFoo) { + _swig_wrap_MyClass_Foo_set(arg1, arg2.Swigcptr()) +} + +var _wrap_MyClass_Foo_get unsafe.Pointer + +func _swig_wrap_MyClass_Foo_get(base SwigcptrMyClass) (_ SwigcptrMyFoo) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_MyClass_Foo_get, _swig_p) + return +} + +func (arg1 SwigcptrMyClass) GetFoo() (_swig_ret MyFoo) { + return _swig_wrap_MyClass_Foo_get(arg1) +} + +var _wrap_new_MyClass unsafe.Pointer + +func _swig_wrap_new_MyClass() (base SwigcptrMyClass) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_MyClass, _swig_p) + return +} + +func NewMyClass() (_swig_ret MyClass) { + return _swig_wrap_new_MyClass() +} + +var _wrap_delete_MyClass unsafe.Pointer + +func _swig_wrap_delete_MyClass(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_MyClass, _swig_p) + return +} + +func DeleteMyClass(arg1 MyClass) { + _swig_wrap_delete_MyClass(arg1.Swigcptr()) +} + +type MyClass interface { + Swigcptr() uintptr + SwigIsMyClass() + SetFoo(arg2 MyFoo) + GetFoo() (_swig_ret MyFoo) +} + +type SwigcptrMyClassVal uintptr + +func (p SwigcptrMyClassVal) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrMyClassVal) SwigIsMyClassVal() { +} + +var _wrap_MyClassVal_ReadWriteFoo_set unsafe.Pointer + +func _swig_wrap_MyClassVal_ReadWriteFoo_set(base SwigcptrMyClassVal, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_MyClassVal_ReadWriteFoo_set, _swig_p) + return +} + +func (arg1 SwigcptrMyClassVal) SetReadWriteFoo(arg2 MyFoo) { + _swig_wrap_MyClassVal_ReadWriteFoo_set(arg1, arg2.Swigcptr()) +} + +var _wrap_MyClassVal_ReadWriteFoo_get unsafe.Pointer + +func _swig_wrap_MyClassVal_ReadWriteFoo_get(base SwigcptrMyClassVal) (_ SwigcptrMyFoo) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_MyClassVal_ReadWriteFoo_get, _swig_p) + return +} + +func (arg1 SwigcptrMyClassVal) GetReadWriteFoo() (_swig_ret MyFoo) { + return _swig_wrap_MyClassVal_ReadWriteFoo_get(arg1) +} + +var _wrap_MyClassVal_ReadOnlyFoo_get unsafe.Pointer + +func _swig_wrap_MyClassVal_ReadOnlyFoo_get(base SwigcptrMyClassVal) (_ SwigcptrMyFoo) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_MyClassVal_ReadOnlyFoo_get, _swig_p) + return +} + +func (arg1 SwigcptrMyClassVal) GetReadOnlyFoo() (_swig_ret MyFoo) { + return _swig_wrap_MyClassVal_ReadOnlyFoo_get(arg1) +} + +var _wrap_new_MyClassVal unsafe.Pointer + +func _swig_wrap_new_MyClassVal() (base SwigcptrMyClassVal) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_MyClassVal, _swig_p) + return +} + +func NewMyClassVal() (_swig_ret MyClassVal) { + return _swig_wrap_new_MyClassVal() +} + +var _wrap_delete_MyClassVal unsafe.Pointer + +func _swig_wrap_delete_MyClassVal(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_MyClassVal, _swig_p) + return +} + +func DeleteMyClassVal(arg1 MyClassVal) { + _swig_wrap_delete_MyClassVal(arg1.Swigcptr()) +} + +type MyClassVal interface { + Swigcptr() uintptr + SwigIsMyClassVal() + SetReadWriteFoo(arg2 MyFoo) + GetReadWriteFoo() (_swig_ret MyFoo) + GetReadOnlyFoo() (_swig_ret MyFoo) +} + +type SwigcptrMyStringyClass uintptr + +func (p SwigcptrMyStringyClass) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrMyStringyClass) SwigIsMyStringyClass() { +} + +var _wrap_new_MyStringyClass unsafe.Pointer + +func _swig_wrap_new_MyStringyClass(base string) (_ SwigcptrMyStringyClass) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_MyStringyClass, _swig_p) + return +} + +func NewMyStringyClass(arg1 string) (_swig_ret MyStringyClass) { + return _swig_wrap_new_MyStringyClass(arg1) +} + +var _wrap_MyStringyClass_ReadWriteString_set unsafe.Pointer + +func _swig_wrap_MyStringyClass_ReadWriteString_set(base SwigcptrMyStringyClass, _ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_MyStringyClass_ReadWriteString_set, _swig_p) + return +} + +func (arg1 SwigcptrMyStringyClass) SetReadWriteString(arg2 string) { + _swig_wrap_MyStringyClass_ReadWriteString_set(arg1, arg2) +} + +var _wrap_MyStringyClass_ReadWriteString_get unsafe.Pointer + +func _swig_wrap_MyStringyClass_ReadWriteString_get(base SwigcptrMyStringyClass) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_MyStringyClass_ReadWriteString_get, _swig_p) + return +} + +func (arg1 SwigcptrMyStringyClass) GetReadWriteString() (_swig_ret string) { + return _swig_wrap_MyStringyClass_ReadWriteString_get(arg1) +} + +var _wrap_MyStringyClass_ReadOnlyString_get unsafe.Pointer + +func _swig_wrap_MyStringyClass_ReadOnlyString_get(base SwigcptrMyStringyClass) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_MyStringyClass_ReadOnlyString_get, _swig_p) + return +} + +func (arg1 SwigcptrMyStringyClass) GetReadOnlyString() (_swig_ret string) { + return _swig_wrap_MyStringyClass_ReadOnlyString_get(arg1) +} + +var _wrap_delete_MyStringyClass unsafe.Pointer + +func _swig_wrap_delete_MyStringyClass(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_MyStringyClass, _swig_p) + return +} + +func DeleteMyStringyClass(arg1 MyStringyClass) { + _swig_wrap_delete_MyStringyClass(arg1.Swigcptr()) +} + +type MyStringyClass interface { + Swigcptr() uintptr + SwigIsMyStringyClass() + SetReadWriteString(arg2 string) + GetReadWriteString() (_swig_ret string) + GetReadOnlyString() (_swig_ret string) +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/li_attribute_runme b/Examples/test-suite/go/li_attribute_runme new file mode 100755 index 000000000..f6f612ff4 Binary files /dev/null and b/Examples/test-suite/go/li_attribute_runme differ diff --git a/Examples/test-suite/go/li_attribute_template.go b/Examples/test-suite/go/li_attribute_template.go new file mode 100644 index 000000000..2b5afa26c --- /dev/null +++ b/Examples/test-suite/go/li_attribute_template.go @@ -0,0 +1,411 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../li_attribute_template.i + +package li_attribute_template + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrFoo uintptr + +func (p SwigcptrFoo) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrFoo) SwigIsFoo() { +} + +var _wrap_new_Foo unsafe.Pointer + +func _swig_wrap_new_Foo(base int) (_ SwigcptrFoo) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Foo, _swig_p) + return +} + +func NewFoo(arg1 int) (_swig_ret Foo) { + return _swig_wrap_new_Foo(arg1) +} + +var _wrap_Foo_value_set unsafe.Pointer + +func _swig_wrap_Foo_value_set(base SwigcptrFoo, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_value_set, _swig_p) + return +} + +func (arg1 SwigcptrFoo) SetValue(arg2 int) { + _swig_wrap_Foo_value_set(arg1, arg2) +} + +var _wrap_Foo_value_get unsafe.Pointer + +func _swig_wrap_Foo_value_get(base SwigcptrFoo) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_value_get, _swig_p) + return +} + +func (arg1 SwigcptrFoo) GetValue() (_swig_ret int) { + return _swig_wrap_Foo_value_get(arg1) +} + +var _wrap_delete_Foo unsafe.Pointer + +func _swig_wrap_delete_Foo(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Foo, _swig_p) + return +} + +func DeleteFoo(arg1 Foo) { + _swig_wrap_delete_Foo(arg1.Swigcptr()) +} + +type Foo interface { + Swigcptr() uintptr + SwigIsFoo() + SetValue(arg2 int) + GetValue() (_swig_ret int) +} + +type SwigcptrPair_intint uintptr + +func (p SwigcptrPair_intint) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrPair_intint) SwigIsPair_intint() { +} + +var _wrap_new_pair_intint unsafe.Pointer + +func _swig_wrap_new_pair_intint(base int, _ int) (_ SwigcptrPair_intint) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_pair_intint, _swig_p) + return +} + +func NewPair_intint(arg1 int, arg2 int) (_swig_ret Pair_intint) { + return _swig_wrap_new_pair_intint(arg1, arg2) +} + +var _wrap_pair_intint_first_set unsafe.Pointer + +func _swig_wrap_pair_intint_first_set(base SwigcptrPair_intint, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_pair_intint_first_set, _swig_p) + return +} + +func (arg1 SwigcptrPair_intint) SetFirst(arg2 int) { + _swig_wrap_pair_intint_first_set(arg1, arg2) +} + +var _wrap_pair_intint_first_get unsafe.Pointer + +func _swig_wrap_pair_intint_first_get(base SwigcptrPair_intint) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_pair_intint_first_get, _swig_p) + return +} + +func (arg1 SwigcptrPair_intint) GetFirst() (_swig_ret int) { + return _swig_wrap_pair_intint_first_get(arg1) +} + +var _wrap_pair_intint_second_set unsafe.Pointer + +func _swig_wrap_pair_intint_second_set(base SwigcptrPair_intint, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_pair_intint_second_set, _swig_p) + return +} + +func (arg1 SwigcptrPair_intint) SetSecond(arg2 int) { + _swig_wrap_pair_intint_second_set(arg1, arg2) +} + +var _wrap_pair_intint_second_get unsafe.Pointer + +func _swig_wrap_pair_intint_second_get(base SwigcptrPair_intint) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_pair_intint_second_get, _swig_p) + return +} + +func (arg1 SwigcptrPair_intint) GetSecond() (_swig_ret int) { + return _swig_wrap_pair_intint_second_get(arg1) +} + +var _wrap_delete_pair_intint unsafe.Pointer + +func _swig_wrap_delete_pair_intint(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_pair_intint, _swig_p) + return +} + +func DeletePair_intint(arg1 Pair_intint) { + _swig_wrap_delete_pair_intint(arg1.Swigcptr()) +} + +type Pair_intint interface { + Swigcptr() uintptr + SwigIsPair_intint() + SetFirst(arg2 int) + GetFirst() (_swig_ret int) + SetSecond(arg2 int) + GetSecond() (_swig_ret int) +} + +type SwigcptrCintint uintptr + +func (p SwigcptrCintint) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrCintint) SwigIsCintint() { +} + +var _wrap_new_Cintint unsafe.Pointer + +func _swig_wrap_new_Cintint(base int, _ int, _ int) (_ SwigcptrCintint) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Cintint, _swig_p) + return +} + +func NewCintint(arg1 int, arg2 int, arg3 int) (_swig_ret Cintint) { + return _swig_wrap_new_Cintint(arg1, arg2, arg3) +} + +var _wrap_Cintint_a_set unsafe.Pointer + +func _swig_wrap_Cintint_a_set(base SwigcptrCintint, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Cintint_a_set, _swig_p) + return +} + +func (arg1 SwigcptrCintint) SetA(arg2 int) { + _swig_wrap_Cintint_a_set(arg1, arg2) +} + +var _wrap_Cintint_a_get unsafe.Pointer + +func _swig_wrap_Cintint_a_get(base SwigcptrCintint) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Cintint_a_get, _swig_p) + return +} + +func (arg1 SwigcptrCintint) GetA() (_swig_ret int) { + return _swig_wrap_Cintint_a_get(arg1) +} + +var _wrap_Cintint_b_set unsafe.Pointer + +func _swig_wrap_Cintint_b_set(base SwigcptrCintint, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Cintint_b_set, _swig_p) + return +} + +func (arg1 SwigcptrCintint) SetB(arg2 int) { + _swig_wrap_Cintint_b_set(arg1, arg2) +} + +var _wrap_Cintint_b_get unsafe.Pointer + +func _swig_wrap_Cintint_b_get(base SwigcptrCintint) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Cintint_b_get, _swig_p) + return +} + +func (arg1 SwigcptrCintint) GetB() (_swig_ret int) { + return _swig_wrap_Cintint_b_get(arg1) +} + +var _wrap_Cintint_str_set unsafe.Pointer + +func _swig_wrap_Cintint_str_set(base SwigcptrCintint, _ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Cintint_str_set, _swig_p) + return +} + +func (arg1 SwigcptrCintint) SetStr(arg2 string) { + _swig_wrap_Cintint_str_set(arg1, arg2) +} + +var _wrap_Cintint_str_get unsafe.Pointer + +func _swig_wrap_Cintint_str_get(base SwigcptrCintint) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Cintint_str_get, _swig_p) + return +} + +func (arg1 SwigcptrCintint) GetStr() (_swig_ret string) { + return _swig_wrap_Cintint_str_get(arg1) +} + +var _wrap_Cintint_d_set unsafe.Pointer + +func _swig_wrap_Cintint_d_set(base SwigcptrCintint, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Cintint_d_set, _swig_p) + return +} + +func (arg1 SwigcptrCintint) SetD(arg2 Foo) { + _swig_wrap_Cintint_d_set(arg1, arg2.Swigcptr()) +} + +var _wrap_Cintint_d_get unsafe.Pointer + +func _swig_wrap_Cintint_d_get(base SwigcptrCintint) (_ SwigcptrFoo) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Cintint_d_get, _swig_p) + return +} + +func (arg1 SwigcptrCintint) GetD() (_swig_ret Foo) { + return _swig_wrap_Cintint_d_get(arg1) +} + +var _wrap_Cintint_e_set unsafe.Pointer + +func _swig_wrap_Cintint_e_set(base SwigcptrCintint, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Cintint_e_set, _swig_p) + return +} + +func (arg1 SwigcptrCintint) SetE(arg2 Foo) { + _swig_wrap_Cintint_e_set(arg1, arg2.Swigcptr()) +} + +var _wrap_Cintint_e_get unsafe.Pointer + +func _swig_wrap_Cintint_e_get(base SwigcptrCintint) (_ SwigcptrFoo) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Cintint_e_get, _swig_p) + return +} + +func (arg1 SwigcptrCintint) GetE() (_swig_ret Foo) { + return _swig_wrap_Cintint_e_get(arg1) +} + +var _wrap_Cintint_f_set unsafe.Pointer + +func _swig_wrap_Cintint_f_set(base SwigcptrCintint, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Cintint_f_set, _swig_p) + return +} + +func (arg1 SwigcptrCintint) SetF(arg2 Pair_intint) { + _swig_wrap_Cintint_f_set(arg1, arg2.Swigcptr()) +} + +var _wrap_Cintint_f_get unsafe.Pointer + +func _swig_wrap_Cintint_f_get(base SwigcptrCintint) (_ SwigcptrPair_intint) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Cintint_f_get, _swig_p) + return +} + +func (arg1 SwigcptrCintint) GetF() (_swig_ret Pair_intint) { + return _swig_wrap_Cintint_f_get(arg1) +} + +var _wrap_Cintint_g_set unsafe.Pointer + +func _swig_wrap_Cintint_g_set(base SwigcptrCintint, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Cintint_g_set, _swig_p) + return +} + +func (arg1 SwigcptrCintint) SetG(arg2 Pair_intint) { + _swig_wrap_Cintint_g_set(arg1, arg2.Swigcptr()) +} + +var _wrap_Cintint_g_get unsafe.Pointer + +func _swig_wrap_Cintint_g_get(base SwigcptrCintint) (_ SwigcptrPair_intint) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Cintint_g_get, _swig_p) + return +} + +func (arg1 SwigcptrCintint) GetG() (_swig_ret Pair_intint) { + return _swig_wrap_Cintint_g_get(arg1) +} + +var _wrap_delete_Cintint unsafe.Pointer + +func _swig_wrap_delete_Cintint(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Cintint, _swig_p) + return +} + +func DeleteCintint(arg1 Cintint) { + _swig_wrap_delete_Cintint(arg1.Swigcptr()) +} + +type Cintint interface { + Swigcptr() uintptr + SwigIsCintint() + SetA(arg2 int) + GetA() (_swig_ret int) + SetB(arg2 int) + GetB() (_swig_ret int) + SetStr(arg2 string) + GetStr() (_swig_ret string) + SetD(arg2 Foo) + GetD() (_swig_ret Foo) + SetE(arg2 Foo) + GetE() (_swig_ret Foo) + SetF(arg2 Pair_intint) + GetF() (_swig_ret Pair_intint) + SetG(arg2 Pair_intint) + GetG() (_swig_ret Pair_intint) +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/li_boost_shared_ptr.go b/Examples/test-suite/go/li_boost_shared_ptr.go new file mode 100644 index 000000000..de3f8d872 --- /dev/null +++ b/Examples/test-suite/go/li_boost_shared_ptr.go @@ -0,0 +1,1856 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../li_boost_shared_ptr.i + +package li_boost_shared_ptr + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +var _wrap_debug_shared_set unsafe.Pointer + +func _swig_wrap_debug_shared_set(base bool) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_debug_shared_set, _swig_p) + return +} + +func SetDebug_shared(arg1 bool) { + _swig_wrap_debug_shared_set(arg1) +} + +var _wrap_debug_shared_get unsafe.Pointer + +func GetDebug_shared() (_swig_ret bool) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_debug_shared_get, _swig_p) + return +} +type SwigcptrKlass uintptr + +func (p SwigcptrKlass) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrKlass) SwigIsKlass() { +} + +var _wrap_new_Klass__SWIG_0 unsafe.Pointer + +func _swig_wrap_new_Klass__SWIG_0() (base SwigcptrKlass) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Klass__SWIG_0, _swig_p) + return +} + +func NewKlass__SWIG_0() (_swig_ret Klass) { + return _swig_wrap_new_Klass__SWIG_0() +} + +var _wrap_new_Klass__SWIG_1 unsafe.Pointer + +func _swig_wrap_new_Klass__SWIG_1(base string) (_ SwigcptrKlass) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Klass__SWIG_1, _swig_p) + return +} + +func NewKlass__SWIG_1(arg1 string) (_swig_ret Klass) { + return _swig_wrap_new_Klass__SWIG_1(arg1) +} + +var _wrap_delete_Klass unsafe.Pointer + +func _swig_wrap_delete_Klass(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Klass, _swig_p) + return +} + +func DeleteKlass(arg1 Klass) { + _swig_wrap_delete_Klass(arg1.Swigcptr()) +} + +var _wrap_Klass_getValue unsafe.Pointer + +func _swig_wrap_Klass_getValue(base SwigcptrKlass) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Klass_getValue, _swig_p) + return +} + +func (arg1 SwigcptrKlass) GetValue() (_swig_ret string) { + return _swig_wrap_Klass_getValue(arg1) +} + +var _wrap_Klass_append unsafe.Pointer + +func _swig_wrap_Klass_append(base SwigcptrKlass, _ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Klass_append, _swig_p) + return +} + +func (arg1 SwigcptrKlass) Append(arg2 string) { + _swig_wrap_Klass_append(arg1, arg2) +} + +var _wrap_new_Klass__SWIG_2 unsafe.Pointer + +func _swig_wrap_new_Klass__SWIG_2(base uintptr) (_ SwigcptrKlass) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Klass__SWIG_2, _swig_p) + return +} + +func NewKlass__SWIG_2(arg1 Klass) (_swig_ret Klass) { + return _swig_wrap_new_Klass__SWIG_2(arg1.Swigcptr()) +} + +func NewKlass(a ...interface{}) Klass { + argc := len(a) + if argc == 0 { + return NewKlass__SWIG_0() + } + if argc == 1 { + if _, ok := a[0].(string); !ok { + goto check_2 + } + return NewKlass__SWIG_1(a[0].(string)) + } +check_2: + if argc == 1 { + return NewKlass__SWIG_2(a[0].(Klass)) + } + panic("No match for overloaded function call") +} + +var _wrap_Klass_getTotal_count unsafe.Pointer + +func KlassGetTotal_count() (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_Klass_getTotal_count, _swig_p) + return +} +type Klass interface { + Swigcptr() uintptr + SwigIsKlass() + GetValue() (_swig_ret string) + Append(arg2 string) +} + +type SwigcptrKlassDerived uintptr + +func (p SwigcptrKlassDerived) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrKlassDerived) SwigIsKlassDerived() { +} + +var _wrap_new_KlassDerived__SWIG_0 unsafe.Pointer + +func _swig_wrap_new_KlassDerived__SWIG_0() (base SwigcptrKlassDerived) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_KlassDerived__SWIG_0, _swig_p) + return +} + +func NewKlassDerived__SWIG_0() (_swig_ret KlassDerived) { + return _swig_wrap_new_KlassDerived__SWIG_0() +} + +var _wrap_new_KlassDerived__SWIG_1 unsafe.Pointer + +func _swig_wrap_new_KlassDerived__SWIG_1(base string) (_ SwigcptrKlassDerived) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_KlassDerived__SWIG_1, _swig_p) + return +} + +func NewKlassDerived__SWIG_1(arg1 string) (_swig_ret KlassDerived) { + return _swig_wrap_new_KlassDerived__SWIG_1(arg1) +} + +var _wrap_new_KlassDerived__SWIG_2 unsafe.Pointer + +func _swig_wrap_new_KlassDerived__SWIG_2(base uintptr) (_ SwigcptrKlassDerived) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_KlassDerived__SWIG_2, _swig_p) + return +} + +func NewKlassDerived__SWIG_2(arg1 KlassDerived) (_swig_ret KlassDerived) { + return _swig_wrap_new_KlassDerived__SWIG_2(arg1.Swigcptr()) +} + +func NewKlassDerived(a ...interface{}) KlassDerived { + argc := len(a) + if argc == 0 { + return NewKlassDerived__SWIG_0() + } + if argc == 1 { + if _, ok := a[0].(string); !ok { + goto check_2 + } + return NewKlassDerived__SWIG_1(a[0].(string)) + } +check_2: + if argc == 1 { + return NewKlassDerived__SWIG_2(a[0].(KlassDerived)) + } + panic("No match for overloaded function call") +} + +var _wrap_delete_KlassDerived unsafe.Pointer + +func _swig_wrap_delete_KlassDerived(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_KlassDerived, _swig_p) + return +} + +func DeleteKlassDerived(arg1 KlassDerived) { + _swig_wrap_delete_KlassDerived(arg1.Swigcptr()) +} + +var _wrap_KlassDerived_getValue unsafe.Pointer + +func _swig_wrap_KlassDerived_getValue(base SwigcptrKlassDerived) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_KlassDerived_getValue, _swig_p) + return +} + +func (arg1 SwigcptrKlassDerived) GetValue() (_swig_ret string) { + return _swig_wrap_KlassDerived_getValue(arg1) +} + +var _wrap_KlassDerived_append unsafe.Pointer + +func _swig_wrap_KlassDerived_append(base SwigcptrKlassDerived, _ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_KlassDerived_append, _swig_p) + return +} + +func (_swig_base SwigcptrKlassDerived) Append(arg1 string) { + _swig_wrap_KlassDerived_append(_swig_base, arg1) +} + +var _wrap_KlassDerived_getTotal_count unsafe.Pointer + +func KlassDerivedGetTotal_count() (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_KlassDerived_getTotal_count, _swig_p) + return +} +var _wrap_KlassDerived_SwigGetKlass unsafe.Pointer + +func _swig_wrap_KlassDerived_SwigGetKlass(base SwigcptrKlassDerived) (_ SwigcptrKlass) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_KlassDerived_SwigGetKlass, _swig_p) + return +} + +func (arg1 SwigcptrKlassDerived) SwigGetKlass() (_swig_ret Klass) { + return _swig_wrap_KlassDerived_SwigGetKlass(arg1) +} + +type KlassDerived interface { + Swigcptr() uintptr + SwigIsKlassDerived() + GetValue() (_swig_ret string) + Append(arg1 string) + SwigGetKlass() (_swig_ret Klass) +} + +var _wrap_derivedpointertest unsafe.Pointer + +func _swig_wrap_derivedpointertest(base uintptr) (_ SwigcptrKlassDerived) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_derivedpointertest, _swig_p) + return +} + +func Derivedpointertest(arg1 KlassDerived) (_swig_ret KlassDerived) { + return _swig_wrap_derivedpointertest(arg1.Swigcptr()) +} + +var _wrap_derivedreftest unsafe.Pointer + +func _swig_wrap_derivedreftest(base uintptr) (_ SwigcptrKlassDerived) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_derivedreftest, _swig_p) + return +} + +func Derivedreftest(arg1 KlassDerived) (_swig_ret KlassDerived) { + return _swig_wrap_derivedreftest(arg1.Swigcptr()) +} + +var _wrap_derivedsmartptrtest unsafe.Pointer + +func _swig_wrap_derivedsmartptrtest(base uintptr) (_ SwigcptrSwigBoost_shared_ptr_Sl_Space_KlassDerived_Sg_) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_derivedsmartptrtest, _swig_p) + return +} + +func Derivedsmartptrtest(arg1 SwigBoost_shared_ptr_Sl_Space_KlassDerived_Sg_) (_swig_ret SwigBoost_shared_ptr_Sl_Space_KlassDerived_Sg_) { + return _swig_wrap_derivedsmartptrtest(arg1.Swigcptr()) +} + +var _wrap_derivedsmartptrpointertest unsafe.Pointer + +func _swig_wrap_derivedsmartptrpointertest(base uintptr) (_ SwigcptrSwigBoost_shared_ptr_Sl_Space_KlassDerived_Sg_) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_derivedsmartptrpointertest, _swig_p) + return +} + +func Derivedsmartptrpointertest(arg1 SwigBoost_shared_ptr_Sl_Space_KlassDerived_Sg_) (_swig_ret SwigBoost_shared_ptr_Sl_Space_KlassDerived_Sg_) { + return _swig_wrap_derivedsmartptrpointertest(arg1.Swigcptr()) +} + +var _wrap_derivedsmartptrreftest unsafe.Pointer + +func _swig_wrap_derivedsmartptrreftest(base uintptr) (_ SwigcptrSwigBoost_shared_ptr_Sl_Space_KlassDerived_Sg_) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_derivedsmartptrreftest, _swig_p) + return +} + +func Derivedsmartptrreftest(arg1 SwigBoost_shared_ptr_Sl_Space_KlassDerived_Sg_) (_swig_ret SwigBoost_shared_ptr_Sl_Space_KlassDerived_Sg_) { + return _swig_wrap_derivedsmartptrreftest(arg1.Swigcptr()) +} + +var _wrap_derivedsmartptrpointerreftest unsafe.Pointer + +func _swig_wrap_derivedsmartptrpointerreftest(base uintptr) (_ SwigcptrSwigBoost_shared_ptr_Sl_Space_KlassDerived_Sg_) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_derivedsmartptrpointerreftest, _swig_p) + return +} + +func Derivedsmartptrpointerreftest(arg1 SwigBoost_shared_ptr_Sl_Space_KlassDerived_Sg_) (_swig_ret SwigBoost_shared_ptr_Sl_Space_KlassDerived_Sg_) { + return _swig_wrap_derivedsmartptrpointerreftest(arg1.Swigcptr()) +} + +type SwigcptrKlass2ndDerived uintptr + +func (p SwigcptrKlass2ndDerived) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrKlass2ndDerived) SwigIsKlass2ndDerived() { +} + +var _wrap_new_Klass2ndDerived__SWIG_0 unsafe.Pointer + +func _swig_wrap_new_Klass2ndDerived__SWIG_0() (base SwigcptrKlass2ndDerived) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Klass2ndDerived__SWIG_0, _swig_p) + return +} + +func NewKlass2ndDerived__SWIG_0() (_swig_ret Klass2ndDerived) { + return _swig_wrap_new_Klass2ndDerived__SWIG_0() +} + +var _wrap_new_Klass2ndDerived__SWIG_1 unsafe.Pointer + +func _swig_wrap_new_Klass2ndDerived__SWIG_1(base string) (_ SwigcptrKlass2ndDerived) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Klass2ndDerived__SWIG_1, _swig_p) + return +} + +func NewKlass2ndDerived__SWIG_1(arg1 string) (_swig_ret Klass2ndDerived) { + return _swig_wrap_new_Klass2ndDerived__SWIG_1(arg1) +} + +func NewKlass2ndDerived(a ...interface{}) Klass2ndDerived { + argc := len(a) + if argc == 0 { + return NewKlass2ndDerived__SWIG_0() + } + if argc == 1 { + return NewKlass2ndDerived__SWIG_1(a[0].(string)) + } + panic("No match for overloaded function call") +} + +var _wrap_delete_Klass2ndDerived unsafe.Pointer + +func _swig_wrap_delete_Klass2ndDerived(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Klass2ndDerived, _swig_p) + return +} + +func DeleteKlass2ndDerived(arg1 Klass2ndDerived) { + _swig_wrap_delete_Klass2ndDerived(arg1.Swigcptr()) +} + +var _wrap_Klass2ndDerived_getValue unsafe.Pointer + +func _swig_wrap_Klass2ndDerived_getValue(base SwigcptrKlass2ndDerived) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Klass2ndDerived_getValue, _swig_p) + return +} + +func (_swig_base SwigcptrKlass2ndDerived) GetValue() (_swig_ret string) { + return _swig_wrap_Klass2ndDerived_getValue(_swig_base) +} + +var _wrap_Klass2ndDerived_append unsafe.Pointer + +func _swig_wrap_Klass2ndDerived_append(base SwigcptrKlass2ndDerived, _ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Klass2ndDerived_append, _swig_p) + return +} + +func (_swig_base SwigcptrKlass2ndDerived) Append(arg1 string) { + _swig_wrap_Klass2ndDerived_append(_swig_base, arg1) +} + +var _wrap_Klass2ndDerived_getTotal_count unsafe.Pointer + +func Klass2ndDerivedGetTotal_count() (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_Klass2ndDerived_getTotal_count, _swig_p) + return +} +func (p SwigcptrKlass2ndDerived) SwigIsKlass() { +} + +func (p SwigcptrKlass2ndDerived) SwigGetKlass() Klass { + return SwigcptrKlass(p.Swigcptr()) +} + +type Klass2ndDerived interface { + Swigcptr() uintptr + SwigIsKlass2ndDerived() + GetValue() (_swig_ret string) + Append(arg1 string) + SwigIsKlass() + SwigGetKlass() Klass +} + +type SwigcptrKlass3rdDerived uintptr + +func (p SwigcptrKlass3rdDerived) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrKlass3rdDerived) SwigIsKlass3rdDerived() { +} + +var _wrap_new_Klass3rdDerived__SWIG_0 unsafe.Pointer + +func _swig_wrap_new_Klass3rdDerived__SWIG_0() (base SwigcptrKlass3rdDerived) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Klass3rdDerived__SWIG_0, _swig_p) + return +} + +func NewKlass3rdDerived__SWIG_0() (_swig_ret Klass3rdDerived) { + return _swig_wrap_new_Klass3rdDerived__SWIG_0() +} + +var _wrap_new_Klass3rdDerived__SWIG_1 unsafe.Pointer + +func _swig_wrap_new_Klass3rdDerived__SWIG_1(base string) (_ SwigcptrKlass3rdDerived) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Klass3rdDerived__SWIG_1, _swig_p) + return +} + +func NewKlass3rdDerived__SWIG_1(arg1 string) (_swig_ret Klass3rdDerived) { + return _swig_wrap_new_Klass3rdDerived__SWIG_1(arg1) +} + +func NewKlass3rdDerived(a ...interface{}) Klass3rdDerived { + argc := len(a) + if argc == 0 { + return NewKlass3rdDerived__SWIG_0() + } + if argc == 1 { + return NewKlass3rdDerived__SWIG_1(a[0].(string)) + } + panic("No match for overloaded function call") +} + +var _wrap_delete_Klass3rdDerived unsafe.Pointer + +func _swig_wrap_delete_Klass3rdDerived(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Klass3rdDerived, _swig_p) + return +} + +func DeleteKlass3rdDerived(arg1 Klass3rdDerived) { + _swig_wrap_delete_Klass3rdDerived(arg1.Swigcptr()) +} + +var _wrap_Klass3rdDerived_getValue unsafe.Pointer + +func _swig_wrap_Klass3rdDerived_getValue(base SwigcptrKlass3rdDerived) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Klass3rdDerived_getValue, _swig_p) + return +} + +func (arg1 SwigcptrKlass3rdDerived) GetValue() (_swig_ret string) { + return _swig_wrap_Klass3rdDerived_getValue(arg1) +} + +var _wrap_Klass3rdDerived_append unsafe.Pointer + +func _swig_wrap_Klass3rdDerived_append(base SwigcptrKlass3rdDerived, _ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Klass3rdDerived_append, _swig_p) + return +} + +func (_swig_base SwigcptrKlass3rdDerived) Append(arg1 string) { + _swig_wrap_Klass3rdDerived_append(_swig_base, arg1) +} + +var _wrap_Klass3rdDerived_getTotal_count unsafe.Pointer + +func Klass3rdDerivedGetTotal_count() (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_Klass3rdDerived_getTotal_count, _swig_p) + return +} +var _wrap_Klass3rdDerived_SwigGetKlass2ndDerived unsafe.Pointer + +func _swig_wrap_Klass3rdDerived_SwigGetKlass2ndDerived(base SwigcptrKlass3rdDerived) (_ SwigcptrKlass2ndDerived) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Klass3rdDerived_SwigGetKlass2ndDerived, _swig_p) + return +} + +func (arg1 SwigcptrKlass3rdDerived) SwigGetKlass2ndDerived() (_swig_ret Klass2ndDerived) { + return _swig_wrap_Klass3rdDerived_SwigGetKlass2ndDerived(arg1) +} + +func (p SwigcptrKlass3rdDerived) SwigGetKlass() Klass { + return p.SwigGetKlass2ndDerived().SwigGetKlass() +} + +type Klass3rdDerived interface { + Swigcptr() uintptr + SwigIsKlass3rdDerived() + GetValue() (_swig_ret string) + Append(arg1 string) + SwigGetKlass2ndDerived() (_swig_ret Klass2ndDerived) + SwigGetKlass() Klass +} + +var _wrap_test3rdupcast unsafe.Pointer + +func _swig_wrap_test3rdupcast(base uintptr) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_test3rdupcast, _swig_p) + return +} + +func Test3rdupcast(arg1 SwigBoost_shared_ptr_Sl_Space_Klass_Sg_) (_swig_ret string) { + return _swig_wrap_test3rdupcast(arg1.Swigcptr()) +} + +var _wrap_factorycreate unsafe.Pointer + +func _swig_wrap_factorycreate() (base SwigcptrSwigBoost_shared_ptr_Sl_Space_Klass_Sg_) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_factorycreate, _swig_p) + return +} + +func Factorycreate() (_swig_ret SwigBoost_shared_ptr_Sl_Space_Klass_Sg_) { + return _swig_wrap_factorycreate() +} + +var _wrap_smartpointertest unsafe.Pointer + +func _swig_wrap_smartpointertest(base uintptr) (_ SwigcptrSwigBoost_shared_ptr_Sl_Space_Klass_Sg_) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_smartpointertest, _swig_p) + return +} + +func Smartpointertest(arg1 SwigBoost_shared_ptr_Sl_Space_Klass_Sg_) (_swig_ret SwigBoost_shared_ptr_Sl_Space_Klass_Sg_) { + return _swig_wrap_smartpointertest(arg1.Swigcptr()) +} + +var _wrap_smartpointerpointertest unsafe.Pointer + +func _swig_wrap_smartpointerpointertest(base uintptr) (_ SwigcptrSwigBoost_shared_ptr_Sl_Space_Klass_Sg_) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_smartpointerpointertest, _swig_p) + return +} + +func Smartpointerpointertest(arg1 SwigBoost_shared_ptr_Sl_Space_Klass_Sg_) (_swig_ret SwigBoost_shared_ptr_Sl_Space_Klass_Sg_) { + return _swig_wrap_smartpointerpointertest(arg1.Swigcptr()) +} + +var _wrap_smartpointerreftest unsafe.Pointer + +func _swig_wrap_smartpointerreftest(base uintptr) (_ SwigcptrSwigBoost_shared_ptr_Sl_Space_Klass_Sg_) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_smartpointerreftest, _swig_p) + return +} + +func Smartpointerreftest(arg1 SwigBoost_shared_ptr_Sl_Space_Klass_Sg_) (_swig_ret SwigBoost_shared_ptr_Sl_Space_Klass_Sg_) { + return _swig_wrap_smartpointerreftest(arg1.Swigcptr()) +} + +var _wrap_smartpointerpointerreftest unsafe.Pointer + +func _swig_wrap_smartpointerpointerreftest(base uintptr) (_ SwigcptrSwigBoost_shared_ptr_Sl_Space_Klass_Sg_) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_smartpointerpointerreftest, _swig_p) + return +} + +func Smartpointerpointerreftest(arg1 SwigBoost_shared_ptr_Sl_Space_Klass_Sg_) (_swig_ret SwigBoost_shared_ptr_Sl_Space_Klass_Sg_) { + return _swig_wrap_smartpointerpointerreftest(arg1.Swigcptr()) +} + +var _wrap_constsmartpointertest unsafe.Pointer + +func _swig_wrap_constsmartpointertest(base uintptr) (_ SwigcptrSwigBoost_shared_ptr_Sl_Space_Klass_SS_const_Sg_) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_constsmartpointertest, _swig_p) + return +} + +func Constsmartpointertest(arg1 SwigBoost_shared_ptr_Sl_Space_Klass_SS_const_Sg_) (_swig_ret SwigBoost_shared_ptr_Sl_Space_Klass_SS_const_Sg_) { + return _swig_wrap_constsmartpointertest(arg1.Swigcptr()) +} + +var _wrap_constsmartpointerpointertest unsafe.Pointer + +func _swig_wrap_constsmartpointerpointertest(base uintptr) (_ SwigcptrSwigBoost_shared_ptr_Sl_Space_Klass_SS_const_Sg_) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_constsmartpointerpointertest, _swig_p) + return +} + +func Constsmartpointerpointertest(arg1 SwigBoost_shared_ptr_Sl_Space_Klass_SS_const_Sg_) (_swig_ret SwigBoost_shared_ptr_Sl_Space_Klass_SS_const_Sg_) { + return _swig_wrap_constsmartpointerpointertest(arg1.Swigcptr()) +} + +var _wrap_constsmartpointerreftest unsafe.Pointer + +func _swig_wrap_constsmartpointerreftest(base uintptr) (_ SwigcptrSwigBoost_shared_ptr_Sl_Space_Klass_SS_const_Sg_) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_constsmartpointerreftest, _swig_p) + return +} + +func Constsmartpointerreftest(arg1 SwigBoost_shared_ptr_Sl_Space_Klass_SS_const_Sg_) (_swig_ret SwigBoost_shared_ptr_Sl_Space_Klass_SS_const_Sg_) { + return _swig_wrap_constsmartpointerreftest(arg1.Swigcptr()) +} + +var _wrap_valuetest unsafe.Pointer + +func _swig_wrap_valuetest(base uintptr) (_ SwigcptrKlass) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_valuetest, _swig_p) + return +} + +func Valuetest(arg1 Klass) (_swig_ret Klass) { + return _swig_wrap_valuetest(arg1.Swigcptr()) +} + +var _wrap_pointertest unsafe.Pointer + +func _swig_wrap_pointertest(base uintptr) (_ SwigcptrKlass) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_pointertest, _swig_p) + return +} + +func Pointertest(arg1 Klass) (_swig_ret Klass) { + return _swig_wrap_pointertest(arg1.Swigcptr()) +} + +var _wrap_reftest unsafe.Pointer + +func _swig_wrap_reftest(base uintptr) (_ SwigcptrKlass) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_reftest, _swig_p) + return +} + +func Reftest(arg1 Klass) (_swig_ret Klass) { + return _swig_wrap_reftest(arg1.Swigcptr()) +} + +var _wrap_pointerreftest unsafe.Pointer + +func _swig_wrap_pointerreftest(base uintptr) (_ SwigcptrKlass) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_pointerreftest, _swig_p) + return +} + +func Pointerreftest(arg1 Klass) (_swig_ret Klass) { + return _swig_wrap_pointerreftest(arg1.Swigcptr()) +} + +var _wrap_nullsmartpointerpointertest unsafe.Pointer + +func _swig_wrap_nullsmartpointerpointertest(base uintptr) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_nullsmartpointerpointertest, _swig_p) + return +} + +func Nullsmartpointerpointertest(arg1 SwigBoost_shared_ptr_Sl_Space_Klass_Sg_) (_swig_ret string) { + return _swig_wrap_nullsmartpointerpointertest(arg1.Swigcptr()) +} + +var _wrap_pointerownertest unsafe.Pointer + +func _swig_wrap_pointerownertest() (base SwigcptrKlass) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_pointerownertest, _swig_p) + return +} + +func Pointerownertest() (_swig_ret Klass) { + return _swig_wrap_pointerownertest() +} + +var _wrap_smartpointerpointerownertest unsafe.Pointer + +func _swig_wrap_smartpointerpointerownertest() (base SwigcptrSwigBoost_shared_ptr_Sl_Space_Klass_Sg_) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_smartpointerpointerownertest, _swig_p) + return +} + +func Smartpointerpointerownertest() (_swig_ret SwigBoost_shared_ptr_Sl_Space_Klass_Sg_) { + return _swig_wrap_smartpointerpointerownertest() +} + +var _wrap_use_count__SWIG_0 unsafe.Pointer + +func _swig_wrap_use_count__SWIG_0(base uintptr) (_ int64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_use_count__SWIG_0, _swig_p) + return +} + +func Use_count__SWIG_0(arg1 SwigBoost_shared_ptr_Sl_Space_Klass3rdDerived_Sg_) (_swig_ret int64) { + return _swig_wrap_use_count__SWIG_0(arg1.Swigcptr()) +} + +var _wrap_use_count__SWIG_1 unsafe.Pointer + +func _swig_wrap_use_count__SWIG_1(base uintptr) (_ int64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_use_count__SWIG_1, _swig_p) + return +} + +func Use_count__SWIG_1(arg1 SwigBoost_shared_ptr_Sl_Space_Klass2ndDerived_Sg_) (_swig_ret int64) { + return _swig_wrap_use_count__SWIG_1(arg1.Swigcptr()) +} + +var _wrap_use_count__SWIG_2 unsafe.Pointer + +func _swig_wrap_use_count__SWIG_2(base uintptr) (_ int64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_use_count__SWIG_2, _swig_p) + return +} + +func Use_count__SWIG_2(arg1 SwigBoost_shared_ptr_Sl_Space_KlassDerived_Sg_) (_swig_ret int64) { + return _swig_wrap_use_count__SWIG_2(arg1.Swigcptr()) +} + +var _wrap_use_count__SWIG_3 unsafe.Pointer + +func _swig_wrap_use_count__SWIG_3(base uintptr) (_ int64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_use_count__SWIG_3, _swig_p) + return +} + +func Use_count__SWIG_3(arg1 SwigBoost_shared_ptr_Sl_Space_Klass_Sg_) (_swig_ret int64) { + return _swig_wrap_use_count__SWIG_3(arg1.Swigcptr()) +} + +func Use_count(a ...interface{}) int64 { + argc := len(a) + if argc == 1 { + if _, ok := a[0].(SwigBoost_shared_ptr_Sl_Space_Klass3rdDerived_Sg_); !ok { + goto check_1 + } + return Use_count__SWIG_0(a[0].(SwigBoost_shared_ptr_Sl_Space_Klass3rdDerived_Sg_)) + } +check_1: + if argc == 1 { + if _, ok := a[0].(SwigBoost_shared_ptr_Sl_Space_Klass2ndDerived_Sg_); !ok { + goto check_2 + } + return Use_count__SWIG_1(a[0].(SwigBoost_shared_ptr_Sl_Space_Klass2ndDerived_Sg_)) + } +check_2: + if argc == 1 { + if _, ok := a[0].(SwigBoost_shared_ptr_Sl_Space_KlassDerived_Sg_); !ok { + goto check_3 + } + return Use_count__SWIG_2(a[0].(SwigBoost_shared_ptr_Sl_Space_KlassDerived_Sg_)) + } +check_3: + if argc == 1 { + return Use_count__SWIG_3(a[0].(SwigBoost_shared_ptr_Sl_Space_Klass_Sg_)) + } + panic("No match for overloaded function call") +} + +var _wrap_ref_1 unsafe.Pointer + +func _swig_wrap_ref_1() (base SwigcptrSwigBoost_shared_ptr_Sl_Space_Klass_Sg_) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_ref_1, _swig_p) + return +} + +func Ref_1() (_swig_ret SwigBoost_shared_ptr_Sl_Space_Klass_Sg_) { + return _swig_wrap_ref_1() +} + +var _wrap_overload_rawbyval__SWIG_0 unsafe.Pointer + +func Overload_rawbyval__SWIG_0(arg1 int) (_swig_ret string) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_overload_rawbyval__SWIG_0, _swig_p) + return +} +var _wrap_overload_rawbyval__SWIG_1 unsafe.Pointer + +func _swig_wrap_overload_rawbyval__SWIG_1(base uintptr) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_overload_rawbyval__SWIG_1, _swig_p) + return +} + +func Overload_rawbyval__SWIG_1(arg1 Klass) (_swig_ret string) { + return _swig_wrap_overload_rawbyval__SWIG_1(arg1.Swigcptr()) +} + +func Overload_rawbyval(a ...interface{}) string { + argc := len(a) + if argc == 1 { + if _, ok := a[0].(Klass); !ok { + goto check_1 + } + return Overload_rawbyval__SWIG_1(a[0].(Klass)) + } +check_1: + if argc == 1 { + return Overload_rawbyval__SWIG_0(a[0].(int)) + } + panic("No match for overloaded function call") +} + +var _wrap_overload_rawbyref__SWIG_0 unsafe.Pointer + +func Overload_rawbyref__SWIG_0(arg1 int) (_swig_ret string) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_overload_rawbyref__SWIG_0, _swig_p) + return +} +var _wrap_overload_rawbyref__SWIG_1 unsafe.Pointer + +func _swig_wrap_overload_rawbyref__SWIG_1(base uintptr) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_overload_rawbyref__SWIG_1, _swig_p) + return +} + +func Overload_rawbyref__SWIG_1(arg1 Klass) (_swig_ret string) { + return _swig_wrap_overload_rawbyref__SWIG_1(arg1.Swigcptr()) +} + +func Overload_rawbyref(a ...interface{}) string { + argc := len(a) + if argc == 1 { + if _, ok := a[0].(Klass); !ok { + goto check_1 + } + return Overload_rawbyref__SWIG_1(a[0].(Klass)) + } +check_1: + if argc == 1 { + return Overload_rawbyref__SWIG_0(a[0].(int)) + } + panic("No match for overloaded function call") +} + +var _wrap_overload_rawbyptr__SWIG_0 unsafe.Pointer + +func Overload_rawbyptr__SWIG_0(arg1 int) (_swig_ret string) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_overload_rawbyptr__SWIG_0, _swig_p) + return +} +var _wrap_overload_rawbyptr__SWIG_1 unsafe.Pointer + +func _swig_wrap_overload_rawbyptr__SWIG_1(base uintptr) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_overload_rawbyptr__SWIG_1, _swig_p) + return +} + +func Overload_rawbyptr__SWIG_1(arg1 Klass) (_swig_ret string) { + return _swig_wrap_overload_rawbyptr__SWIG_1(arg1.Swigcptr()) +} + +func Overload_rawbyptr(a ...interface{}) string { + argc := len(a) + if argc == 1 { + if _, ok := a[0].(Klass); !ok { + goto check_1 + } + return Overload_rawbyptr__SWIG_1(a[0].(Klass)) + } +check_1: + if argc == 1 { + return Overload_rawbyptr__SWIG_0(a[0].(int)) + } + panic("No match for overloaded function call") +} + +var _wrap_overload_rawbyptrref__SWIG_0 unsafe.Pointer + +func Overload_rawbyptrref__SWIG_0(arg1 int) (_swig_ret string) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_overload_rawbyptrref__SWIG_0, _swig_p) + return +} +var _wrap_overload_rawbyptrref__SWIG_1 unsafe.Pointer + +func _swig_wrap_overload_rawbyptrref__SWIG_1(base uintptr) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_overload_rawbyptrref__SWIG_1, _swig_p) + return +} + +func Overload_rawbyptrref__SWIG_1(arg1 Klass) (_swig_ret string) { + return _swig_wrap_overload_rawbyptrref__SWIG_1(arg1.Swigcptr()) +} + +func Overload_rawbyptrref(a ...interface{}) string { + argc := len(a) + if argc == 1 { + if _, ok := a[0].(Klass); !ok { + goto check_1 + } + return Overload_rawbyptrref__SWIG_1(a[0].(Klass)) + } +check_1: + if argc == 1 { + return Overload_rawbyptrref__SWIG_0(a[0].(int)) + } + panic("No match for overloaded function call") +} + +var _wrap_overload_smartbyval__SWIG_0 unsafe.Pointer + +func Overload_smartbyval__SWIG_0(arg1 int) (_swig_ret string) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_overload_smartbyval__SWIG_0, _swig_p) + return +} +var _wrap_overload_smartbyval__SWIG_1 unsafe.Pointer + +func _swig_wrap_overload_smartbyval__SWIG_1(base uintptr) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_overload_smartbyval__SWIG_1, _swig_p) + return +} + +func Overload_smartbyval__SWIG_1(arg1 SwigBoost_shared_ptr_Sl_Space_Klass_Sg_) (_swig_ret string) { + return _swig_wrap_overload_smartbyval__SWIG_1(arg1.Swigcptr()) +} + +func Overload_smartbyval(a ...interface{}) string { + argc := len(a) + if argc == 1 { + if _, ok := a[0].(SwigBoost_shared_ptr_Sl_Space_Klass_Sg_); !ok { + goto check_1 + } + return Overload_smartbyval__SWIG_1(a[0].(SwigBoost_shared_ptr_Sl_Space_Klass_Sg_)) + } +check_1: + if argc == 1 { + return Overload_smartbyval__SWIG_0(a[0].(int)) + } + panic("No match for overloaded function call") +} + +var _wrap_overload_smartbyref__SWIG_0 unsafe.Pointer + +func Overload_smartbyref__SWIG_0(arg1 int) (_swig_ret string) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_overload_smartbyref__SWIG_0, _swig_p) + return +} +var _wrap_overload_smartbyref__SWIG_1 unsafe.Pointer + +func _swig_wrap_overload_smartbyref__SWIG_1(base uintptr) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_overload_smartbyref__SWIG_1, _swig_p) + return +} + +func Overload_smartbyref__SWIG_1(arg1 SwigBoost_shared_ptr_Sl_Space_Klass_Sg_) (_swig_ret string) { + return _swig_wrap_overload_smartbyref__SWIG_1(arg1.Swigcptr()) +} + +func Overload_smartbyref(a ...interface{}) string { + argc := len(a) + if argc == 1 { + if _, ok := a[0].(SwigBoost_shared_ptr_Sl_Space_Klass_Sg_); !ok { + goto check_1 + } + return Overload_smartbyref__SWIG_1(a[0].(SwigBoost_shared_ptr_Sl_Space_Klass_Sg_)) + } +check_1: + if argc == 1 { + return Overload_smartbyref__SWIG_0(a[0].(int)) + } + panic("No match for overloaded function call") +} + +var _wrap_overload_smartbyptr__SWIG_0 unsafe.Pointer + +func Overload_smartbyptr__SWIG_0(arg1 int) (_swig_ret string) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_overload_smartbyptr__SWIG_0, _swig_p) + return +} +var _wrap_overload_smartbyptr__SWIG_1 unsafe.Pointer + +func _swig_wrap_overload_smartbyptr__SWIG_1(base uintptr) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_overload_smartbyptr__SWIG_1, _swig_p) + return +} + +func Overload_smartbyptr__SWIG_1(arg1 SwigBoost_shared_ptr_Sl_Space_Klass_Sg_) (_swig_ret string) { + return _swig_wrap_overload_smartbyptr__SWIG_1(arg1.Swigcptr()) +} + +func Overload_smartbyptr(a ...interface{}) string { + argc := len(a) + if argc == 1 { + if _, ok := a[0].(SwigBoost_shared_ptr_Sl_Space_Klass_Sg_); !ok { + goto check_1 + } + return Overload_smartbyptr__SWIG_1(a[0].(SwigBoost_shared_ptr_Sl_Space_Klass_Sg_)) + } +check_1: + if argc == 1 { + return Overload_smartbyptr__SWIG_0(a[0].(int)) + } + panic("No match for overloaded function call") +} + +var _wrap_overload_smartbyptrref__SWIG_0 unsafe.Pointer + +func Overload_smartbyptrref__SWIG_0(arg1 int) (_swig_ret string) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_overload_smartbyptrref__SWIG_0, _swig_p) + return +} +var _wrap_overload_smartbyptrref__SWIG_1 unsafe.Pointer + +func _swig_wrap_overload_smartbyptrref__SWIG_1(base uintptr) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_overload_smartbyptrref__SWIG_1, _swig_p) + return +} + +func Overload_smartbyptrref__SWIG_1(arg1 SwigBoost_shared_ptr_Sl_Space_Klass_Sg_) (_swig_ret string) { + return _swig_wrap_overload_smartbyptrref__SWIG_1(arg1.Swigcptr()) +} + +func Overload_smartbyptrref(a ...interface{}) string { + argc := len(a) + if argc == 1 { + if _, ok := a[0].(SwigBoost_shared_ptr_Sl_Space_Klass_Sg_); !ok { + goto check_1 + } + return Overload_smartbyptrref__SWIG_1(a[0].(SwigBoost_shared_ptr_Sl_Space_Klass_Sg_)) + } +check_1: + if argc == 1 { + return Overload_smartbyptrref__SWIG_0(a[0].(int)) + } + panic("No match for overloaded function call") +} + +type SwigcptrMemberVariables uintptr + +func (p SwigcptrMemberVariables) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrMemberVariables) SwigIsMemberVariables() { +} + +var _wrap_new_MemberVariables unsafe.Pointer + +func _swig_wrap_new_MemberVariables() (base SwigcptrMemberVariables) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_MemberVariables, _swig_p) + return +} + +func NewMemberVariables() (_swig_ret MemberVariables) { + return _swig_wrap_new_MemberVariables() +} + +var _wrap_MemberVariables_SmartMemberValue_set unsafe.Pointer + +func _swig_wrap_MemberVariables_SmartMemberValue_set(base SwigcptrMemberVariables, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_MemberVariables_SmartMemberValue_set, _swig_p) + return +} + +func (arg1 SwigcptrMemberVariables) SetSmartMemberValue(arg2 SwigBoost_shared_ptr_Sl_Space_Klass_Sg_) { + _swig_wrap_MemberVariables_SmartMemberValue_set(arg1, arg2.Swigcptr()) +} + +var _wrap_MemberVariables_SmartMemberValue_get unsafe.Pointer + +func _swig_wrap_MemberVariables_SmartMemberValue_get(base SwigcptrMemberVariables) (_ SwigcptrSwigBoost_shared_ptr_Sl_Space_Klass_Sg_) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_MemberVariables_SmartMemberValue_get, _swig_p) + return +} + +func (arg1 SwigcptrMemberVariables) GetSmartMemberValue() (_swig_ret SwigBoost_shared_ptr_Sl_Space_Klass_Sg_) { + return _swig_wrap_MemberVariables_SmartMemberValue_get(arg1) +} + +var _wrap_MemberVariables_SmartMemberPointer_set unsafe.Pointer + +func _swig_wrap_MemberVariables_SmartMemberPointer_set(base SwigcptrMemberVariables, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_MemberVariables_SmartMemberPointer_set, _swig_p) + return +} + +func (arg1 SwigcptrMemberVariables) SetSmartMemberPointer(arg2 SwigBoost_shared_ptr_Sl_Space_Klass_Sg_) { + _swig_wrap_MemberVariables_SmartMemberPointer_set(arg1, arg2.Swigcptr()) +} + +var _wrap_MemberVariables_SmartMemberPointer_get unsafe.Pointer + +func _swig_wrap_MemberVariables_SmartMemberPointer_get(base SwigcptrMemberVariables) (_ SwigcptrSwigBoost_shared_ptr_Sl_Space_Klass_Sg_) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_MemberVariables_SmartMemberPointer_get, _swig_p) + return +} + +func (arg1 SwigcptrMemberVariables) GetSmartMemberPointer() (_swig_ret SwigBoost_shared_ptr_Sl_Space_Klass_Sg_) { + return _swig_wrap_MemberVariables_SmartMemberPointer_get(arg1) +} + +var _wrap_MemberVariables_SmartMemberReference_set unsafe.Pointer + +func _swig_wrap_MemberVariables_SmartMemberReference_set(base SwigcptrMemberVariables, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_MemberVariables_SmartMemberReference_set, _swig_p) + return +} + +func (arg1 SwigcptrMemberVariables) SetSmartMemberReference(arg2 SwigBoost_shared_ptr_Sl_Space_Klass_Sg_) { + _swig_wrap_MemberVariables_SmartMemberReference_set(arg1, arg2.Swigcptr()) +} + +var _wrap_MemberVariables_SmartMemberReference_get unsafe.Pointer + +func _swig_wrap_MemberVariables_SmartMemberReference_get(base SwigcptrMemberVariables) (_ SwigcptrSwigBoost_shared_ptr_Sl_Space_Klass_Sg_) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_MemberVariables_SmartMemberReference_get, _swig_p) + return +} + +func (arg1 SwigcptrMemberVariables) GetSmartMemberReference() (_swig_ret SwigBoost_shared_ptr_Sl_Space_Klass_Sg_) { + return _swig_wrap_MemberVariables_SmartMemberReference_get(arg1) +} + +var _wrap_MemberVariables_MemberValue_set unsafe.Pointer + +func _swig_wrap_MemberVariables_MemberValue_set(base SwigcptrMemberVariables, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_MemberVariables_MemberValue_set, _swig_p) + return +} + +func (arg1 SwigcptrMemberVariables) SetMemberValue(arg2 Klass) { + _swig_wrap_MemberVariables_MemberValue_set(arg1, arg2.Swigcptr()) +} + +var _wrap_MemberVariables_MemberValue_get unsafe.Pointer + +func _swig_wrap_MemberVariables_MemberValue_get(base SwigcptrMemberVariables) (_ SwigcptrKlass) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_MemberVariables_MemberValue_get, _swig_p) + return +} + +func (arg1 SwigcptrMemberVariables) GetMemberValue() (_swig_ret Klass) { + return _swig_wrap_MemberVariables_MemberValue_get(arg1) +} + +var _wrap_MemberVariables_MemberPointer_set unsafe.Pointer + +func _swig_wrap_MemberVariables_MemberPointer_set(base SwigcptrMemberVariables, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_MemberVariables_MemberPointer_set, _swig_p) + return +} + +func (arg1 SwigcptrMemberVariables) SetMemberPointer(arg2 Klass) { + _swig_wrap_MemberVariables_MemberPointer_set(arg1, arg2.Swigcptr()) +} + +var _wrap_MemberVariables_MemberPointer_get unsafe.Pointer + +func _swig_wrap_MemberVariables_MemberPointer_get(base SwigcptrMemberVariables) (_ SwigcptrKlass) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_MemberVariables_MemberPointer_get, _swig_p) + return +} + +func (arg1 SwigcptrMemberVariables) GetMemberPointer() (_swig_ret Klass) { + return _swig_wrap_MemberVariables_MemberPointer_get(arg1) +} + +var _wrap_MemberVariables_MemberReference_set unsafe.Pointer + +func _swig_wrap_MemberVariables_MemberReference_set(base SwigcptrMemberVariables, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_MemberVariables_MemberReference_set, _swig_p) + return +} + +func (arg1 SwigcptrMemberVariables) SetMemberReference(arg2 Klass) { + _swig_wrap_MemberVariables_MemberReference_set(arg1, arg2.Swigcptr()) +} + +var _wrap_MemberVariables_MemberReference_get unsafe.Pointer + +func _swig_wrap_MemberVariables_MemberReference_get(base SwigcptrMemberVariables) (_ SwigcptrKlass) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_MemberVariables_MemberReference_get, _swig_p) + return +} + +func (arg1 SwigcptrMemberVariables) GetMemberReference() (_swig_ret Klass) { + return _swig_wrap_MemberVariables_MemberReference_get(arg1) +} + +var _wrap_delete_MemberVariables unsafe.Pointer + +func _swig_wrap_delete_MemberVariables(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_MemberVariables, _swig_p) + return +} + +func DeleteMemberVariables(arg1 MemberVariables) { + _swig_wrap_delete_MemberVariables(arg1.Swigcptr()) +} + +type MemberVariables interface { + Swigcptr() uintptr + SwigIsMemberVariables() + SetSmartMemberValue(arg2 SwigBoost_shared_ptr_Sl_Space_Klass_Sg_) + GetSmartMemberValue() (_swig_ret SwigBoost_shared_ptr_Sl_Space_Klass_Sg_) + SetSmartMemberPointer(arg2 SwigBoost_shared_ptr_Sl_Space_Klass_Sg_) + GetSmartMemberPointer() (_swig_ret SwigBoost_shared_ptr_Sl_Space_Klass_Sg_) + SetSmartMemberReference(arg2 SwigBoost_shared_ptr_Sl_Space_Klass_Sg_) + GetSmartMemberReference() (_swig_ret SwigBoost_shared_ptr_Sl_Space_Klass_Sg_) + SetMemberValue(arg2 Klass) + GetMemberValue() (_swig_ret Klass) + SetMemberPointer(arg2 Klass) + GetMemberPointer() (_swig_ret Klass) + SetMemberReference(arg2 Klass) + GetMemberReference() (_swig_ret Klass) +} + +var _wrap_GlobalSmartValue_set unsafe.Pointer + +func _swig_wrap_GlobalSmartValue_set(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_GlobalSmartValue_set, _swig_p) + return +} + +func SetGlobalSmartValue(arg1 SwigBoost_shared_ptr_Sl_Space_Klass_Sg_) { + _swig_wrap_GlobalSmartValue_set(arg1.Swigcptr()) +} + +var _wrap_GlobalSmartValue_get unsafe.Pointer + +func _swig_wrap_GlobalSmartValue_get() (base SwigcptrSwigBoost_shared_ptr_Sl_Space_Klass_Sg_) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_GlobalSmartValue_get, _swig_p) + return +} + +func GetGlobalSmartValue() (_swig_ret SwigBoost_shared_ptr_Sl_Space_Klass_Sg_) { + return _swig_wrap_GlobalSmartValue_get() +} + +var _wrap_GlobalValue_set unsafe.Pointer + +func _swig_wrap_GlobalValue_set(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_GlobalValue_set, _swig_p) + return +} + +func SetGlobalValue(arg1 Klass) { + _swig_wrap_GlobalValue_set(arg1.Swigcptr()) +} + +var _wrap_GlobalValue_get unsafe.Pointer + +func _swig_wrap_GlobalValue_get() (base SwigcptrKlass) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_GlobalValue_get, _swig_p) + return +} + +func GetGlobalValue() (_swig_ret Klass) { + return _swig_wrap_GlobalValue_get() +} + +var _wrap_GlobalPointer_set unsafe.Pointer + +func _swig_wrap_GlobalPointer_set(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_GlobalPointer_set, _swig_p) + return +} + +func SetGlobalPointer(arg1 Klass) { + _swig_wrap_GlobalPointer_set(arg1.Swigcptr()) +} + +var _wrap_GlobalPointer_get unsafe.Pointer + +func _swig_wrap_GlobalPointer_get() (base SwigcptrKlass) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_GlobalPointer_get, _swig_p) + return +} + +func GetGlobalPointer() (_swig_ret Klass) { + return _swig_wrap_GlobalPointer_get() +} + +var _wrap_GlobalReference_set unsafe.Pointer + +func _swig_wrap_GlobalReference_set(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_GlobalReference_set, _swig_p) + return +} + +func SetGlobalReference(arg1 Klass) { + _swig_wrap_GlobalReference_set(arg1.Swigcptr()) +} + +var _wrap_GlobalReference_get unsafe.Pointer + +func _swig_wrap_GlobalReference_get() (base SwigcptrKlass) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_GlobalReference_get, _swig_p) + return +} + +func GetGlobalReference() (_swig_ret Klass) { + return _swig_wrap_GlobalReference_get() +} + +type SwigcptrBaseIntDouble uintptr + +func (p SwigcptrBaseIntDouble) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrBaseIntDouble) SwigIsBaseIntDouble() { +} + +var _wrap_BaseIntDouble_klassBase_set unsafe.Pointer + +func _swig_wrap_BaseIntDouble_klassBase_set(base SwigcptrBaseIntDouble, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_BaseIntDouble_klassBase_set, _swig_p) + return +} + +func (arg1 SwigcptrBaseIntDouble) SetKlassBase(arg2 Klass) { + _swig_wrap_BaseIntDouble_klassBase_set(arg1, arg2.Swigcptr()) +} + +var _wrap_BaseIntDouble_klassBase_get unsafe.Pointer + +func _swig_wrap_BaseIntDouble_klassBase_get(base SwigcptrBaseIntDouble) (_ SwigcptrKlass) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_BaseIntDouble_klassBase_get, _swig_p) + return +} + +func (arg1 SwigcptrBaseIntDouble) GetKlassBase() (_swig_ret Klass) { + return _swig_wrap_BaseIntDouble_klassBase_get(arg1) +} + +var _wrap_BaseIntDouble_baseVal1_set unsafe.Pointer + +func _swig_wrap_BaseIntDouble_baseVal1_set(base SwigcptrBaseIntDouble, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_BaseIntDouble_baseVal1_set, _swig_p) + return +} + +func (arg1 SwigcptrBaseIntDouble) SetBaseVal1(arg2 int) { + _swig_wrap_BaseIntDouble_baseVal1_set(arg1, arg2) +} + +var _wrap_BaseIntDouble_baseVal1_get unsafe.Pointer + +func _swig_wrap_BaseIntDouble_baseVal1_get(base SwigcptrBaseIntDouble) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_BaseIntDouble_baseVal1_get, _swig_p) + return +} + +func (arg1 SwigcptrBaseIntDouble) GetBaseVal1() (_swig_ret int) { + return _swig_wrap_BaseIntDouble_baseVal1_get(arg1) +} + +var _wrap_BaseIntDouble_baseVal2_set unsafe.Pointer + +func _swig_wrap_BaseIntDouble_baseVal2_set(base SwigcptrBaseIntDouble, _ float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_BaseIntDouble_baseVal2_set, _swig_p) + return +} + +func (arg1 SwigcptrBaseIntDouble) SetBaseVal2(arg2 float64) { + _swig_wrap_BaseIntDouble_baseVal2_set(arg1, arg2) +} + +var _wrap_BaseIntDouble_baseVal2_get unsafe.Pointer + +func _swig_wrap_BaseIntDouble_baseVal2_get(base SwigcptrBaseIntDouble) (_ float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_BaseIntDouble_baseVal2_get, _swig_p) + return +} + +func (arg1 SwigcptrBaseIntDouble) GetBaseVal2() (_swig_ret float64) { + return _swig_wrap_BaseIntDouble_baseVal2_get(arg1) +} + +var _wrap_new_BaseIntDouble unsafe.Pointer + +func _swig_wrap_new_BaseIntDouble(base int, _ float64) (_ SwigcptrBaseIntDouble) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_BaseIntDouble, _swig_p) + return +} + +func NewBaseIntDouble(arg1 int, arg2 float64) (_swig_ret BaseIntDouble) { + return _swig_wrap_new_BaseIntDouble(arg1, arg2) +} + +var _wrap_BaseIntDouble_getValue unsafe.Pointer + +func _swig_wrap_BaseIntDouble_getValue(base SwigcptrBaseIntDouble) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_BaseIntDouble_getValue, _swig_p) + return +} + +func (arg1 SwigcptrBaseIntDouble) GetValue() (_swig_ret string) { + return _swig_wrap_BaseIntDouble_getValue(arg1) +} + +var _wrap_delete_BaseIntDouble unsafe.Pointer + +func _swig_wrap_delete_BaseIntDouble(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_BaseIntDouble, _swig_p) + return +} + +func DeleteBaseIntDouble(arg1 BaseIntDouble) { + _swig_wrap_delete_BaseIntDouble(arg1.Swigcptr()) +} + +type BaseIntDouble interface { + Swigcptr() uintptr + SwigIsBaseIntDouble() + SetKlassBase(arg2 Klass) + GetKlassBase() (_swig_ret Klass) + SetBaseVal1(arg2 int) + GetBaseVal1() (_swig_ret int) + SetBaseVal2(arg2 float64) + GetBaseVal2() (_swig_ret float64) + GetValue() (_swig_ret string) +} + +var _wrap_pair_id2 unsafe.Pointer + +func _swig_wrap_pair_id2(base uintptr) (_ SwigcptrPairIntDouble) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_pair_id2, _swig_p) + return +} + +func Pair_id2(arg1 PairIntDouble) (_swig_ret PairIntDouble) { + return _swig_wrap_pair_id2(arg1.Swigcptr()) +} + +var _wrap_pair_id1 unsafe.Pointer + +func _swig_wrap_pair_id1(base uintptr) (_ SwigcptrSwigBoost_shared_ptr_Sl_Pair_Sl_int_Sc_double_Sg__Sg_) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_pair_id1, _swig_p) + return +} + +func Pair_id1(arg1 SwigBoost_shared_ptr_Sl_Pair_Sl_int_Sc_double_Sg__Sg_) (_swig_ret SwigBoost_shared_ptr_Sl_Pair_Sl_int_Sc_double_Sg__Sg_) { + return _swig_wrap_pair_id1(arg1.Swigcptr()) +} + +type SwigcptrPairIntDouble uintptr + +func (p SwigcptrPairIntDouble) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrPairIntDouble) SwigIsPairIntDouble() { +} + +var _wrap_PairIntDouble_klassPair_set unsafe.Pointer + +func _swig_wrap_PairIntDouble_klassPair_set(base SwigcptrPairIntDouble, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_PairIntDouble_klassPair_set, _swig_p) + return +} + +func (arg1 SwigcptrPairIntDouble) SetKlassPair(arg2 Klass) { + _swig_wrap_PairIntDouble_klassPair_set(arg1, arg2.Swigcptr()) +} + +var _wrap_PairIntDouble_klassPair_get unsafe.Pointer + +func _swig_wrap_PairIntDouble_klassPair_get(base SwigcptrPairIntDouble) (_ SwigcptrKlass) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_PairIntDouble_klassPair_get, _swig_p) + return +} + +func (arg1 SwigcptrPairIntDouble) GetKlassPair() (_swig_ret Klass) { + return _swig_wrap_PairIntDouble_klassPair_get(arg1) +} + +var _wrap_PairIntDouble_val1_set unsafe.Pointer + +func _swig_wrap_PairIntDouble_val1_set(base SwigcptrPairIntDouble, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_PairIntDouble_val1_set, _swig_p) + return +} + +func (arg1 SwigcptrPairIntDouble) SetVal1(arg2 int) { + _swig_wrap_PairIntDouble_val1_set(arg1, arg2) +} + +var _wrap_PairIntDouble_val1_get unsafe.Pointer + +func _swig_wrap_PairIntDouble_val1_get(base SwigcptrPairIntDouble) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_PairIntDouble_val1_get, _swig_p) + return +} + +func (arg1 SwigcptrPairIntDouble) GetVal1() (_swig_ret int) { + return _swig_wrap_PairIntDouble_val1_get(arg1) +} + +var _wrap_PairIntDouble_val2_set unsafe.Pointer + +func _swig_wrap_PairIntDouble_val2_set(base SwigcptrPairIntDouble, _ float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_PairIntDouble_val2_set, _swig_p) + return +} + +func (arg1 SwigcptrPairIntDouble) SetVal2(arg2 float64) { + _swig_wrap_PairIntDouble_val2_set(arg1, arg2) +} + +var _wrap_PairIntDouble_val2_get unsafe.Pointer + +func _swig_wrap_PairIntDouble_val2_get(base SwigcptrPairIntDouble) (_ float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_PairIntDouble_val2_get, _swig_p) + return +} + +func (arg1 SwigcptrPairIntDouble) GetVal2() (_swig_ret float64) { + return _swig_wrap_PairIntDouble_val2_get(arg1) +} + +var _wrap_new_PairIntDouble unsafe.Pointer + +func _swig_wrap_new_PairIntDouble(base int, _ float64) (_ SwigcptrPairIntDouble) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_PairIntDouble, _swig_p) + return +} + +func NewPairIntDouble(arg1 int, arg2 float64) (_swig_ret PairIntDouble) { + return _swig_wrap_new_PairIntDouble(arg1, arg2) +} + +var _wrap_PairIntDouble_getValue unsafe.Pointer + +func _swig_wrap_PairIntDouble_getValue(base SwigcptrPairIntDouble) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_PairIntDouble_getValue, _swig_p) + return +} + +func (arg1 SwigcptrPairIntDouble) GetValue() (_swig_ret string) { + return _swig_wrap_PairIntDouble_getValue(arg1) +} + +var _wrap_delete_PairIntDouble unsafe.Pointer + +func _swig_wrap_delete_PairIntDouble(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_PairIntDouble, _swig_p) + return +} + +func DeletePairIntDouble(arg1 PairIntDouble) { + _swig_wrap_delete_PairIntDouble(arg1.Swigcptr()) +} + +var _wrap_SetPairIntDouble_KlassBase unsafe.Pointer + +func _swig_wrap_SetPairIntDouble_KlassBase(base SwigcptrPairIntDouble, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_SetPairIntDouble_KlassBase, _swig_p) + return +} + +func (_swig_base SwigcptrPairIntDouble) SetKlassBase(arg1 Klass) { + _swig_wrap_SetPairIntDouble_KlassBase(_swig_base, arg1.Swigcptr()) +} + +var _wrap_GetPairIntDouble_KlassBase unsafe.Pointer + +func _swig_wrap_GetPairIntDouble_KlassBase(base SwigcptrPairIntDouble) (_ SwigcptrKlass) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_GetPairIntDouble_KlassBase, _swig_p) + return +} + +func (_swig_base SwigcptrPairIntDouble) GetKlassBase() (_swig_ret Klass) { + return _swig_wrap_GetPairIntDouble_KlassBase(_swig_base) +} + +var _wrap_SetPairIntDouble_BaseVal1 unsafe.Pointer + +func _swig_wrap_SetPairIntDouble_BaseVal1(base SwigcptrPairIntDouble, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_SetPairIntDouble_BaseVal1, _swig_p) + return +} + +func (_swig_base SwigcptrPairIntDouble) SetBaseVal1(arg1 int) { + _swig_wrap_SetPairIntDouble_BaseVal1(_swig_base, arg1) +} + +var _wrap_GetPairIntDouble_BaseVal1 unsafe.Pointer + +func _swig_wrap_GetPairIntDouble_BaseVal1(base SwigcptrPairIntDouble) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_GetPairIntDouble_BaseVal1, _swig_p) + return +} + +func (_swig_base SwigcptrPairIntDouble) GetBaseVal1() (_swig_ret int) { + return _swig_wrap_GetPairIntDouble_BaseVal1(_swig_base) +} + +var _wrap_SetPairIntDouble_BaseVal2 unsafe.Pointer + +func _swig_wrap_SetPairIntDouble_BaseVal2(base SwigcptrPairIntDouble, _ float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_SetPairIntDouble_BaseVal2, _swig_p) + return +} + +func (_swig_base SwigcptrPairIntDouble) SetBaseVal2(arg1 float64) { + _swig_wrap_SetPairIntDouble_BaseVal2(_swig_base, arg1) +} + +var _wrap_GetPairIntDouble_BaseVal2 unsafe.Pointer + +func _swig_wrap_GetPairIntDouble_BaseVal2(base SwigcptrPairIntDouble) (_ float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_GetPairIntDouble_BaseVal2, _swig_p) + return +} + +func (_swig_base SwigcptrPairIntDouble) GetBaseVal2() (_swig_ret float64) { + return _swig_wrap_GetPairIntDouble_BaseVal2(_swig_base) +} + +func (p SwigcptrPairIntDouble) SwigIsBaseIntDouble() { +} + +func (p SwigcptrPairIntDouble) SwigGetBaseIntDouble() BaseIntDouble { + return SwigcptrBaseIntDouble(p.Swigcptr()) +} + +type PairIntDouble interface { + Swigcptr() uintptr + SwigIsPairIntDouble() + SetKlassPair(arg2 Klass) + GetKlassPair() (_swig_ret Klass) + SetVal1(arg2 int) + GetVal1() (_swig_ret int) + SetVal2(arg2 float64) + GetVal2() (_swig_ret float64) + GetValue() (_swig_ret string) + SetKlassBase(arg1 Klass) + GetKlassBase() (_swig_ret Klass) + SetBaseVal1(arg1 int) + GetBaseVal1() (_swig_ret int) + SetBaseVal2(arg1 float64) + GetBaseVal2() (_swig_ret float64) + SwigIsBaseIntDouble() + SwigGetBaseIntDouble() BaseIntDouble +} + +var _wrap_NOT_COUNTING_get unsafe.Pointer + +func GetNOT_COUNTING() (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_NOT_COUNTING_get, _swig_p) + return +} +var _wrap_shared_ptr_wrapper_count unsafe.Pointer + +func Shared_ptr_wrapper_count() (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_shared_ptr_wrapper_count, _swig_p) + return +} + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + +type SwigcptrSwigBoost_shared_ptr_Sl_Pair_Sl_int_Sc_double_Sg__Sg_ uintptr +type SwigBoost_shared_ptr_Sl_Pair_Sl_int_Sc_double_Sg__Sg_ interface { + Swigcptr() uintptr; +} +func (p SwigcptrSwigBoost_shared_ptr_Sl_Pair_Sl_int_Sc_double_Sg__Sg_) Swigcptr() uintptr { + return uintptr(p) +} + +type SwigcptrSwigBoost_shared_ptr_Sl_Space_Klass_SS_const_Sg_ uintptr +type SwigBoost_shared_ptr_Sl_Space_Klass_SS_const_Sg_ interface { + Swigcptr() uintptr; +} +func (p SwigcptrSwigBoost_shared_ptr_Sl_Space_Klass_SS_const_Sg_) Swigcptr() uintptr { + return uintptr(p) +} + +type SwigcptrSwigBoost_shared_ptr_Sl_Space_Klass_Sg_ uintptr +type SwigBoost_shared_ptr_Sl_Space_Klass_Sg_ interface { + Swigcptr() uintptr; +} +func (p SwigcptrSwigBoost_shared_ptr_Sl_Space_Klass_Sg_) Swigcptr() uintptr { + return uintptr(p) +} + +type SwigcptrSwigBoost_shared_ptr_Sl_Space_Klass2ndDerived_Sg_ uintptr +type SwigBoost_shared_ptr_Sl_Space_Klass2ndDerived_Sg_ interface { + Swigcptr() uintptr; +} +func (p SwigcptrSwigBoost_shared_ptr_Sl_Space_Klass2ndDerived_Sg_) Swigcptr() uintptr { + return uintptr(p) +} + +type SwigcptrSwigBoost_shared_ptr_Sl_Space_Klass3rdDerived_Sg_ uintptr +type SwigBoost_shared_ptr_Sl_Space_Klass3rdDerived_Sg_ interface { + Swigcptr() uintptr; +} +func (p SwigcptrSwigBoost_shared_ptr_Sl_Space_Klass3rdDerived_Sg_) Swigcptr() uintptr { + return uintptr(p) +} + +type SwigcptrSwigBoost_shared_ptr_Sl_Space_KlassDerived_Sg_ uintptr +type SwigBoost_shared_ptr_Sl_Space_KlassDerived_Sg_ interface { + Swigcptr() uintptr; +} +func (p SwigcptrSwigBoost_shared_ptr_Sl_Space_KlassDerived_Sg_) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/li_boost_shared_ptr_attribute.go b/Examples/test-suite/go/li_boost_shared_ptr_attribute.go new file mode 100644 index 000000000..76e2d0172 --- /dev/null +++ b/Examples/test-suite/go/li_boost_shared_ptr_attribute.go @@ -0,0 +1,29 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../li_boost_shared_ptr_attribute.i + +package li_boost_shared_ptr_attribute + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + + diff --git a/Examples/test-suite/go/li_boost_shared_ptr_bits.go b/Examples/test-suite/go/li_boost_shared_ptr_bits.go new file mode 100644 index 000000000..d292aa634 --- /dev/null +++ b/Examples/test-suite/go/li_boost_shared_ptr_bits.go @@ -0,0 +1,417 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../li_boost_shared_ptr_bits.i + +package li_boost_shared_ptr_bits + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrNonDynamic uintptr + +func (p SwigcptrNonDynamic) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrNonDynamic) SwigIsNonDynamic() { +} + +var _wrap_NonDynamic_i_set unsafe.Pointer + +func _swig_wrap_NonDynamic_i_set(base SwigcptrNonDynamic, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_NonDynamic_i_set, _swig_p) + return +} + +func (arg1 SwigcptrNonDynamic) SetI(arg2 int) { + _swig_wrap_NonDynamic_i_set(arg1, arg2) +} + +var _wrap_NonDynamic_i_get unsafe.Pointer + +func _swig_wrap_NonDynamic_i_get(base SwigcptrNonDynamic) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_NonDynamic_i_get, _swig_p) + return +} + +func (arg1 SwigcptrNonDynamic) GetI() (_swig_ret int) { + return _swig_wrap_NonDynamic_i_get(arg1) +} + +var _wrap_new_NonDynamic unsafe.Pointer + +func _swig_wrap_new_NonDynamic() (base SwigcptrNonDynamic) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_NonDynamic, _swig_p) + return +} + +func NewNonDynamic() (_swig_ret NonDynamic) { + return _swig_wrap_new_NonDynamic() +} + +var _wrap_delete_NonDynamic unsafe.Pointer + +func _swig_wrap_delete_NonDynamic(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_NonDynamic, _swig_p) + return +} + +func DeleteNonDynamic(arg1 NonDynamic) { + _swig_wrap_delete_NonDynamic(arg1.Swigcptr()) +} + +type NonDynamic interface { + Swigcptr() uintptr + SwigIsNonDynamic() + SetI(arg2 int) + GetI() (_swig_ret int) +} + +var _wrap_boing unsafe.Pointer + +func _swig_wrap_boing(base uintptr) (_ SwigcptrBoost_shared_ptr_Sl_NonDynamic_Sg_) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_boing, _swig_p) + return +} + +func Boing(arg1 Boost_shared_ptr_Sl_NonDynamic_Sg_) (_swig_ret Boost_shared_ptr_Sl_NonDynamic_Sg_) { + return _swig_wrap_boing(arg1.Swigcptr()) +} + +type SwigcptrIntHolder uintptr + +func (p SwigcptrIntHolder) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrIntHolder) SwigIsIntHolder() { +} + +var _wrap_IntHolder_val_set unsafe.Pointer + +func _swig_wrap_IntHolder_val_set(base SwigcptrIntHolder, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_IntHolder_val_set, _swig_p) + return +} + +func (arg1 SwigcptrIntHolder) SetVal(arg2 int) { + _swig_wrap_IntHolder_val_set(arg1, arg2) +} + +var _wrap_IntHolder_val_get unsafe.Pointer + +func _swig_wrap_IntHolder_val_get(base SwigcptrIntHolder) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_IntHolder_val_get, _swig_p) + return +} + +func (arg1 SwigcptrIntHolder) GetVal() (_swig_ret int) { + return _swig_wrap_IntHolder_val_get(arg1) +} + +var _wrap_new_IntHolder unsafe.Pointer + +func _swig_wrap_new_IntHolder(base int) (_ SwigcptrIntHolder) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_IntHolder, _swig_p) + return +} + +func NewIntHolder(arg1 int) (_swig_ret IntHolder) { + return _swig_wrap_new_IntHolder(arg1) +} + +var _wrap_delete_IntHolder unsafe.Pointer + +func _swig_wrap_delete_IntHolder(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_IntHolder, _swig_p) + return +} + +func DeleteIntHolder(arg1 IntHolder) { + _swig_wrap_delete_IntHolder(arg1.Swigcptr()) +} + +type IntHolder interface { + Swigcptr() uintptr + SwigIsIntHolder() + SetVal(arg2 int) + GetVal() (_swig_ret int) +} + +var _wrap_sum unsafe.Pointer + +func _swig_wrap_sum(base uintptr) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_sum, _swig_p) + return +} + +func Sum(arg1 VectorIntHolder) (_swig_ret int) { + return _swig_wrap_sum(arg1.Swigcptr()) +} + +type SwigcptrVectorIntHolder uintptr + +func (p SwigcptrVectorIntHolder) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrVectorIntHolder) SwigIsVectorIntHolder() { +} + +var _wrap_new_VectorIntHolder__SWIG_0 unsafe.Pointer + +func _swig_wrap_new_VectorIntHolder__SWIG_0() (base SwigcptrVectorIntHolder) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_VectorIntHolder__SWIG_0, _swig_p) + return +} + +func NewVectorIntHolder__SWIG_0() (_swig_ret VectorIntHolder) { + return _swig_wrap_new_VectorIntHolder__SWIG_0() +} + +var _wrap_new_VectorIntHolder__SWIG_1 unsafe.Pointer + +func _swig_wrap_new_VectorIntHolder__SWIG_1(base int64) (_ SwigcptrVectorIntHolder) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_VectorIntHolder__SWIG_1, _swig_p) + return +} + +func NewVectorIntHolder__SWIG_1(arg1 int64) (_swig_ret VectorIntHolder) { + return _swig_wrap_new_VectorIntHolder__SWIG_1(arg1) +} + +func NewVectorIntHolder(a ...interface{}) VectorIntHolder { + argc := len(a) + if argc == 0 { + return NewVectorIntHolder__SWIG_0() + } + if argc == 1 { + return NewVectorIntHolder__SWIG_1(a[0].(int64)) + } + panic("No match for overloaded function call") +} + +var _wrap_VectorIntHolder_size unsafe.Pointer + +func _swig_wrap_VectorIntHolder_size(base SwigcptrVectorIntHolder) (_ int64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_VectorIntHolder_size, _swig_p) + return +} + +func (arg1 SwigcptrVectorIntHolder) Size() (_swig_ret int64) { + return _swig_wrap_VectorIntHolder_size(arg1) +} + +var _wrap_VectorIntHolder_capacity unsafe.Pointer + +func _swig_wrap_VectorIntHolder_capacity(base SwigcptrVectorIntHolder) (_ int64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_VectorIntHolder_capacity, _swig_p) + return +} + +func (arg1 SwigcptrVectorIntHolder) Capacity() (_swig_ret int64) { + return _swig_wrap_VectorIntHolder_capacity(arg1) +} + +var _wrap_VectorIntHolder_reserve unsafe.Pointer + +func _swig_wrap_VectorIntHolder_reserve(base SwigcptrVectorIntHolder, _ int64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_VectorIntHolder_reserve, _swig_p) + return +} + +func (arg1 SwigcptrVectorIntHolder) Reserve(arg2 int64) { + _swig_wrap_VectorIntHolder_reserve(arg1, arg2) +} + +var _wrap_VectorIntHolder_isEmpty unsafe.Pointer + +func _swig_wrap_VectorIntHolder_isEmpty(base SwigcptrVectorIntHolder) (_ bool) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_VectorIntHolder_isEmpty, _swig_p) + return +} + +func (arg1 SwigcptrVectorIntHolder) IsEmpty() (_swig_ret bool) { + return _swig_wrap_VectorIntHolder_isEmpty(arg1) +} + +var _wrap_VectorIntHolder_clear unsafe.Pointer + +func _swig_wrap_VectorIntHolder_clear(base SwigcptrVectorIntHolder) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_VectorIntHolder_clear, _swig_p) + return +} + +func (arg1 SwigcptrVectorIntHolder) Clear() { + _swig_wrap_VectorIntHolder_clear(arg1) +} + +var _wrap_VectorIntHolder_add unsafe.Pointer + +func _swig_wrap_VectorIntHolder_add(base SwigcptrVectorIntHolder, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_VectorIntHolder_add, _swig_p) + return +} + +func (arg1 SwigcptrVectorIntHolder) Add(arg2 Boost_shared_ptr_Sl_IntHolder_Sg_) { + _swig_wrap_VectorIntHolder_add(arg1, arg2.Swigcptr()) +} + +var _wrap_VectorIntHolder_get unsafe.Pointer + +func _swig_wrap_VectorIntHolder_get(base SwigcptrVectorIntHolder, _ int) (_ SwigcptrBoost_shared_ptr_Sl_IntHolder_Sg_) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_VectorIntHolder_get, _swig_p) + return +} + +func (arg1 SwigcptrVectorIntHolder) Get(arg2 int) (_swig_ret Boost_shared_ptr_Sl_IntHolder_Sg_) { + return _swig_wrap_VectorIntHolder_get(arg1, arg2) +} + +var _wrap_VectorIntHolder_set unsafe.Pointer + +func _swig_wrap_VectorIntHolder_set(base SwigcptrVectorIntHolder, _ int, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_VectorIntHolder_set, _swig_p) + return +} + +func (arg1 SwigcptrVectorIntHolder) Set(arg2 int, arg3 Boost_shared_ptr_Sl_IntHolder_Sg_) { + _swig_wrap_VectorIntHolder_set(arg1, arg2, arg3.Swigcptr()) +} + +var _wrap_delete_VectorIntHolder unsafe.Pointer + +func _swig_wrap_delete_VectorIntHolder(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_VectorIntHolder, _swig_p) + return +} + +func DeleteVectorIntHolder(arg1 VectorIntHolder) { + _swig_wrap_delete_VectorIntHolder(arg1.Swigcptr()) +} + +type VectorIntHolder interface { + Swigcptr() uintptr + SwigIsVectorIntHolder() + Size() (_swig_ret int64) + Capacity() (_swig_ret int64) + Reserve(arg2 int64) + IsEmpty() (_swig_ret bool) + Clear() + Add(arg2 Boost_shared_ptr_Sl_IntHolder_Sg_) + Get(arg2 int) (_swig_ret Boost_shared_ptr_Sl_IntHolder_Sg_) + Set(arg2 int, arg3 Boost_shared_ptr_Sl_IntHolder_Sg_) +} + +type SwigcptrHiddenDestructor uintptr + +func (p SwigcptrHiddenDestructor) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrHiddenDestructor) SwigIsHiddenDestructor() { +} + +var _wrap_HiddenDestructor_create unsafe.Pointer + +func _swig_wrap_HiddenDestructor_create() (base SwigcptrBoost_shared_ptr_Sl_HiddenDestructor_Sg_) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_HiddenDestructor_create, _swig_p) + return +} + +func HiddenDestructorCreate() (_swig_ret Boost_shared_ptr_Sl_HiddenDestructor_Sg_) { + return _swig_wrap_HiddenDestructor_create() +} + +var _wrap_HiddenDestructor_doit unsafe.Pointer + +func _swig_wrap_HiddenDestructor_doit(base SwigcptrHiddenDestructor) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_HiddenDestructor_doit, _swig_p) + return +} + +func (arg1 SwigcptrHiddenDestructor) Doit() { + _swig_wrap_HiddenDestructor_doit(arg1) +} + +type HiddenDestructor interface { + Swigcptr() uintptr + SwigIsHiddenDestructor() + Doit() +} + + +type SwigcptrBoost_shared_ptr_Sl_NonDynamic_Sg_ uintptr +type Boost_shared_ptr_Sl_NonDynamic_Sg_ interface { + Swigcptr() uintptr; +} +func (p SwigcptrBoost_shared_ptr_Sl_NonDynamic_Sg_) Swigcptr() uintptr { + return uintptr(p) +} + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + +type SwigcptrBoost_shared_ptr_Sl_IntHolder_Sg_ uintptr +type Boost_shared_ptr_Sl_IntHolder_Sg_ interface { + Swigcptr() uintptr; +} +func (p SwigcptrBoost_shared_ptr_Sl_IntHolder_Sg_) Swigcptr() uintptr { + return uintptr(p) +} + +type SwigcptrBoost_shared_ptr_Sl_HiddenDestructor_Sg_ uintptr +type Boost_shared_ptr_Sl_HiddenDestructor_Sg_ interface { + Swigcptr() uintptr; +} +func (p SwigcptrBoost_shared_ptr_Sl_HiddenDestructor_Sg_) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/li_boost_shared_ptr_template.go b/Examples/test-suite/go/li_boost_shared_ptr_template.go new file mode 100644 index 000000000..fba6ed8dd --- /dev/null +++ b/Examples/test-suite/go/li_boost_shared_ptr_template.go @@ -0,0 +1,343 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../li_boost_shared_ptr_template.i + +package li_boost_shared_ptr_template + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +var _wrap_bar_getter unsafe.Pointer + +func _swig_wrap_bar_getter(base uintptr) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_bar_getter, _swig_p) + return +} + +func Bar_getter(arg1 BaseINTEGER) (_swig_ret int) { + return _swig_wrap_bar_getter(arg1.Swigcptr()) +} + +type SwigcptrBaseINTEGER uintptr + +func (p SwigcptrBaseINTEGER) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrBaseINTEGER) SwigIsBaseINTEGER() { +} + +var _wrap_BaseINTEGER_bar unsafe.Pointer + +func _swig_wrap_BaseINTEGER_bar(base SwigcptrBaseINTEGER) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_BaseINTEGER_bar, _swig_p) + return +} + +func (arg1 SwigcptrBaseINTEGER) Bar() (_swig_ret int) { + return _swig_wrap_BaseINTEGER_bar(arg1) +} + +var _wrap_new_BaseINTEGER unsafe.Pointer + +func _swig_wrap_new_BaseINTEGER() (base SwigcptrBaseINTEGER) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_BaseINTEGER, _swig_p) + return +} + +func NewBaseINTEGER() (_swig_ret BaseINTEGER) { + return _swig_wrap_new_BaseINTEGER() +} + +var _wrap_delete_BaseINTEGER unsafe.Pointer + +func _swig_wrap_delete_BaseINTEGER(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_BaseINTEGER, _swig_p) + return +} + +func DeleteBaseINTEGER(arg1 BaseINTEGER) { + _swig_wrap_delete_BaseINTEGER(arg1.Swigcptr()) +} + +type BaseINTEGER interface { + Swigcptr() uintptr + SwigIsBaseINTEGER() + Bar() (_swig_ret int) +} + +type SwigcptrDerivedINTEGER uintptr + +func (p SwigcptrDerivedINTEGER) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrDerivedINTEGER) SwigIsDerivedINTEGER() { +} + +var _wrap_DerivedINTEGER_bar unsafe.Pointer + +func _swig_wrap_DerivedINTEGER_bar(base SwigcptrDerivedINTEGER) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_DerivedINTEGER_bar, _swig_p) + return +} + +func (arg1 SwigcptrDerivedINTEGER) Bar() (_swig_ret int) { + return _swig_wrap_DerivedINTEGER_bar(arg1) +} + +var _wrap_new_DerivedINTEGER unsafe.Pointer + +func _swig_wrap_new_DerivedINTEGER() (base SwigcptrDerivedINTEGER) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_DerivedINTEGER, _swig_p) + return +} + +func NewDerivedINTEGER() (_swig_ret DerivedINTEGER) { + return _swig_wrap_new_DerivedINTEGER() +} + +var _wrap_delete_DerivedINTEGER unsafe.Pointer + +func _swig_wrap_delete_DerivedINTEGER(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_DerivedINTEGER, _swig_p) + return +} + +func DeleteDerivedINTEGER(arg1 DerivedINTEGER) { + _swig_wrap_delete_DerivedINTEGER(arg1.Swigcptr()) +} + +func (p SwigcptrDerivedINTEGER) SwigIsBaseINTEGER() { +} + +func (p SwigcptrDerivedINTEGER) SwigGetBaseINTEGER() BaseINTEGER { + return SwigcptrBaseINTEGER(p.Swigcptr()) +} + +type DerivedINTEGER interface { + Swigcptr() uintptr + SwigIsDerivedINTEGER() + Bar() (_swig_ret int) + SwigIsBaseINTEGER() + SwigGetBaseINTEGER() BaseINTEGER +} + +var _wrap_bar2_getter unsafe.Pointer + +func _swig_wrap_bar2_getter(base uintptr) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_bar2_getter, _swig_p) + return +} + +func Bar2_getter(arg1 BaseDefaultInt) (_swig_ret int) { + return _swig_wrap_bar2_getter(arg1.Swigcptr()) +} + +type SwigcptrBaseDefaultInt uintptr + +func (p SwigcptrBaseDefaultInt) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrBaseDefaultInt) SwigIsBaseDefaultInt() { +} + +var _wrap_BaseDefaultInt_bar2 unsafe.Pointer + +func _swig_wrap_BaseDefaultInt_bar2(base SwigcptrBaseDefaultInt) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_BaseDefaultInt_bar2, _swig_p) + return +} + +func (arg1 SwigcptrBaseDefaultInt) Bar2() (_swig_ret int) { + return _swig_wrap_BaseDefaultInt_bar2(arg1) +} + +var _wrap_new_BaseDefaultInt unsafe.Pointer + +func _swig_wrap_new_BaseDefaultInt() (base SwigcptrBaseDefaultInt) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_BaseDefaultInt, _swig_p) + return +} + +func NewBaseDefaultInt() (_swig_ret BaseDefaultInt) { + return _swig_wrap_new_BaseDefaultInt() +} + +var _wrap_delete_BaseDefaultInt unsafe.Pointer + +func _swig_wrap_delete_BaseDefaultInt(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_BaseDefaultInt, _swig_p) + return +} + +func DeleteBaseDefaultInt(arg1 BaseDefaultInt) { + _swig_wrap_delete_BaseDefaultInt(arg1.Swigcptr()) +} + +type BaseDefaultInt interface { + Swigcptr() uintptr + SwigIsBaseDefaultInt() + Bar2() (_swig_ret int) +} + +type SwigcptrDerivedDefaultInt uintptr + +func (p SwigcptrDerivedDefaultInt) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrDerivedDefaultInt) SwigIsDerivedDefaultInt() { +} + +var _wrap_DerivedDefaultInt_bar2 unsafe.Pointer + +func _swig_wrap_DerivedDefaultInt_bar2(base SwigcptrDerivedDefaultInt) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_DerivedDefaultInt_bar2, _swig_p) + return +} + +func (arg1 SwigcptrDerivedDefaultInt) Bar2() (_swig_ret int) { + return _swig_wrap_DerivedDefaultInt_bar2(arg1) +} + +var _wrap_new_DerivedDefaultInt unsafe.Pointer + +func _swig_wrap_new_DerivedDefaultInt() (base SwigcptrDerivedDefaultInt) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_DerivedDefaultInt, _swig_p) + return +} + +func NewDerivedDefaultInt() (_swig_ret DerivedDefaultInt) { + return _swig_wrap_new_DerivedDefaultInt() +} + +var _wrap_delete_DerivedDefaultInt unsafe.Pointer + +func _swig_wrap_delete_DerivedDefaultInt(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_DerivedDefaultInt, _swig_p) + return +} + +func DeleteDerivedDefaultInt(arg1 DerivedDefaultInt) { + _swig_wrap_delete_DerivedDefaultInt(arg1.Swigcptr()) +} + +func (p SwigcptrDerivedDefaultInt) SwigIsBaseDefaultInt() { +} + +func (p SwigcptrDerivedDefaultInt) SwigGetBaseDefaultInt() BaseDefaultInt { + return SwigcptrBaseDefaultInt(p.Swigcptr()) +} + +type DerivedDefaultInt interface { + Swigcptr() uintptr + SwigIsDerivedDefaultInt() + Bar2() (_swig_ret int) + SwigIsBaseDefaultInt() + SwigGetBaseDefaultInt() BaseDefaultInt +} + +type SwigcptrDerivedDefaultInt2 uintptr + +func (p SwigcptrDerivedDefaultInt2) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrDerivedDefaultInt2) SwigIsDerivedDefaultInt2() { +} + +var _wrap_DerivedDefaultInt2_bar2 unsafe.Pointer + +func _swig_wrap_DerivedDefaultInt2_bar2(base SwigcptrDerivedDefaultInt2) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_DerivedDefaultInt2_bar2, _swig_p) + return +} + +func (arg1 SwigcptrDerivedDefaultInt2) Bar2() (_swig_ret int) { + return _swig_wrap_DerivedDefaultInt2_bar2(arg1) +} + +var _wrap_new_DerivedDefaultInt2 unsafe.Pointer + +func _swig_wrap_new_DerivedDefaultInt2() (base SwigcptrDerivedDefaultInt2) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_DerivedDefaultInt2, _swig_p) + return +} + +func NewDerivedDefaultInt2() (_swig_ret DerivedDefaultInt2) { + return _swig_wrap_new_DerivedDefaultInt2() +} + +var _wrap_delete_DerivedDefaultInt2 unsafe.Pointer + +func _swig_wrap_delete_DerivedDefaultInt2(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_DerivedDefaultInt2, _swig_p) + return +} + +func DeleteDerivedDefaultInt2(arg1 DerivedDefaultInt2) { + _swig_wrap_delete_DerivedDefaultInt2(arg1.Swigcptr()) +} + +func (p SwigcptrDerivedDefaultInt2) SwigIsBaseDefaultInt() { +} + +func (p SwigcptrDerivedDefaultInt2) SwigGetBaseDefaultInt() BaseDefaultInt { + return SwigcptrBaseDefaultInt(p.Swigcptr()) +} + +type DerivedDefaultInt2 interface { + Swigcptr() uintptr + SwigIsDerivedDefaultInt2() + Bar2() (_swig_ret int) + SwigIsBaseDefaultInt() + SwigGetBaseDefaultInt() BaseDefaultInt +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/li_carrays.go b/Examples/test-suite/go/li_carrays.go new file mode 100644 index 000000000..9a9d6b035 --- /dev/null +++ b/Examples/test-suite/go/li_carrays.go @@ -0,0 +1,529 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../li_carrays.i + +package li_carrays + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +var _wrap_new_intArray unsafe.Pointer + +func New_intArray(arg1 int) (_swig_ret *int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_new_intArray, _swig_p) + return +} +var _wrap_delete_intArray unsafe.Pointer + +func _swig_wrap_delete_intArray(base *int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_intArray, _swig_p) + return +} + +func Delete_intArray(arg1 *int) { + _swig_wrap_delete_intArray(arg1) +} + +var _wrap_intArray_getitem unsafe.Pointer + +func IntArray_getitem(arg1 *int, arg2 int) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_intArray_getitem, _swig_p) + return +} +var _wrap_intArray_setitem unsafe.Pointer + +func _swig_wrap_intArray_setitem(base *int, _ int, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_intArray_setitem, _swig_p) + return +} + +func IntArray_setitem(arg1 *int, arg2 int, arg3 int) { + _swig_wrap_intArray_setitem(arg1, arg2, arg3) +} + +type SwigcptrDoubleArray uintptr + +func (p SwigcptrDoubleArray) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrDoubleArray) SwigIsDoubleArray() { +} + +var _wrap_new_doubleArray unsafe.Pointer + +func _swig_wrap_new_doubleArray(base int) (_ SwigcptrDoubleArray) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_doubleArray, _swig_p) + return +} + +func NewDoubleArray(arg1 int) (_swig_ret DoubleArray) { + return _swig_wrap_new_doubleArray(arg1) +} + +var _wrap_delete_doubleArray unsafe.Pointer + +func _swig_wrap_delete_doubleArray(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_doubleArray, _swig_p) + return +} + +func DeleteDoubleArray(arg1 DoubleArray) { + _swig_wrap_delete_doubleArray(arg1.Swigcptr()) +} + +var _wrap_doubleArray_getitem unsafe.Pointer + +func _swig_wrap_doubleArray_getitem(base SwigcptrDoubleArray, _ int) (_ float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_doubleArray_getitem, _swig_p) + return +} + +func (arg1 SwigcptrDoubleArray) Getitem(arg2 int) (_swig_ret float64) { + return _swig_wrap_doubleArray_getitem(arg1, arg2) +} + +var _wrap_doubleArray_setitem unsafe.Pointer + +func _swig_wrap_doubleArray_setitem(base SwigcptrDoubleArray, _ int, _ float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_doubleArray_setitem, _swig_p) + return +} + +func (arg1 SwigcptrDoubleArray) Setitem(arg2 int, arg3 float64) { + _swig_wrap_doubleArray_setitem(arg1, arg2, arg3) +} + +var _wrap_doubleArray_cast unsafe.Pointer + +func _swig_wrap_doubleArray_cast(base SwigcptrDoubleArray) (_ *float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_doubleArray_cast, _swig_p) + return +} + +func (arg1 SwigcptrDoubleArray) Cast() (_swig_ret *float64) { + return _swig_wrap_doubleArray_cast(arg1) +} + +var _wrap_doubleArray_frompointer unsafe.Pointer + +func _swig_wrap_doubleArray_frompointer(base *float64) (_ SwigcptrDoubleArray) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_doubleArray_frompointer, _swig_p) + return +} + +func DoubleArrayFrompointer(arg1 *float64) (_swig_ret DoubleArray) { + return _swig_wrap_doubleArray_frompointer(arg1) +} + +type DoubleArray interface { + Swigcptr() uintptr + SwigIsDoubleArray() + Getitem(arg2 int) (_swig_ret float64) + Setitem(arg2 int, arg3 float64) + Cast() (_swig_ret *float64) +} + +type SwigcptrXY uintptr + +func (p SwigcptrXY) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrXY) SwigIsXY() { +} + +var _wrap_XY_x_set unsafe.Pointer + +func _swig_wrap_XY_x_set(base SwigcptrXY, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_XY_x_set, _swig_p) + return +} + +func (arg1 SwigcptrXY) SetX(arg2 int) { + _swig_wrap_XY_x_set(arg1, arg2) +} + +var _wrap_XY_x_get unsafe.Pointer + +func _swig_wrap_XY_x_get(base SwigcptrXY) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_XY_x_get, _swig_p) + return +} + +func (arg1 SwigcptrXY) GetX() (_swig_ret int) { + return _swig_wrap_XY_x_get(arg1) +} + +var _wrap_XY_y_set unsafe.Pointer + +func _swig_wrap_XY_y_set(base SwigcptrXY, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_XY_y_set, _swig_p) + return +} + +func (arg1 SwigcptrXY) SetY(arg2 int) { + _swig_wrap_XY_y_set(arg1, arg2) +} + +var _wrap_XY_y_get unsafe.Pointer + +func _swig_wrap_XY_y_get(base SwigcptrXY) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_XY_y_get, _swig_p) + return +} + +func (arg1 SwigcptrXY) GetY() (_swig_ret int) { + return _swig_wrap_XY_y_get(arg1) +} + +var _wrap_new_XY unsafe.Pointer + +func _swig_wrap_new_XY() (base SwigcptrXY) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_XY, _swig_p) + return +} + +func NewXY() (_swig_ret XY) { + return _swig_wrap_new_XY() +} + +var _wrap_delete_XY unsafe.Pointer + +func _swig_wrap_delete_XY(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_XY, _swig_p) + return +} + +func DeleteXY(arg1 XY) { + _swig_wrap_delete_XY(arg1.Swigcptr()) +} + +type XY interface { + Swigcptr() uintptr + SwigIsXY() + SetX(arg2 int) + GetX() (_swig_ret int) + SetY(arg2 int) + GetY() (_swig_ret int) +} + +var _wrap_globalXYArray_set unsafe.Pointer + +func _swig_wrap_globalXYArray_set(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_globalXYArray_set, _swig_p) + return +} + +func SetGlobalXYArray(arg1 XY) { + _swig_wrap_globalXYArray_set(arg1.Swigcptr()) +} + +var _wrap_globalXYArray_get unsafe.Pointer + +func _swig_wrap_globalXYArray_get() (base SwigcptrXY) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_globalXYArray_get, _swig_p) + return +} + +func GetGlobalXYArray() (_swig_ret XY) { + return _swig_wrap_globalXYArray_get() +} + +type SwigcptrAB uintptr + +func (p SwigcptrAB) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrAB) SwigIsAB() { +} + +var _wrap_AB_a_set unsafe.Pointer + +func _swig_wrap_AB_a_set(base SwigcptrAB, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_AB_a_set, _swig_p) + return +} + +func (arg1 SwigcptrAB) SetA(arg2 int) { + _swig_wrap_AB_a_set(arg1, arg2) +} + +var _wrap_AB_a_get unsafe.Pointer + +func _swig_wrap_AB_a_get(base SwigcptrAB) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_AB_a_get, _swig_p) + return +} + +func (arg1 SwigcptrAB) GetA() (_swig_ret int) { + return _swig_wrap_AB_a_get(arg1) +} + +var _wrap_AB_b_set unsafe.Pointer + +func _swig_wrap_AB_b_set(base SwigcptrAB, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_AB_b_set, _swig_p) + return +} + +func (arg1 SwigcptrAB) SetB(arg2 int) { + _swig_wrap_AB_b_set(arg1, arg2) +} + +var _wrap_AB_b_get unsafe.Pointer + +func _swig_wrap_AB_b_get(base SwigcptrAB) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_AB_b_get, _swig_p) + return +} + +func (arg1 SwigcptrAB) GetB() (_swig_ret int) { + return _swig_wrap_AB_b_get(arg1) +} + +var _wrap_new_AB unsafe.Pointer + +func _swig_wrap_new_AB() (base SwigcptrAB) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_AB, _swig_p) + return +} + +func NewAB() (_swig_ret AB) { + return _swig_wrap_new_AB() +} + +var _wrap_delete_AB unsafe.Pointer + +func _swig_wrap_delete_AB(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_AB, _swig_p) + return +} + +func DeleteAB(arg1 AB) { + _swig_wrap_delete_AB(arg1.Swigcptr()) +} + +type AB interface { + Swigcptr() uintptr + SwigIsAB() + SetA(arg2 int) + GetA() (_swig_ret int) + SetB(arg2 int) + GetB() (_swig_ret int) +} + +var _wrap_globalABArray_set unsafe.Pointer + +func _swig_wrap_globalABArray_set(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_globalABArray_set, _swig_p) + return +} + +func SetGlobalABArray(arg1 AB) { + _swig_wrap_globalABArray_set(arg1.Swigcptr()) +} + +var _wrap_globalABArray_get unsafe.Pointer + +func _swig_wrap_globalABArray_get() (base SwigcptrAB) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_globalABArray_get, _swig_p) + return +} + +func GetGlobalABArray() (_swig_ret AB) { + return _swig_wrap_globalABArray_get() +} + +type SwigcptrXYArray uintptr + +func (p SwigcptrXYArray) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrXYArray) SwigIsXYArray() { +} + +var _wrap_new_XYArray unsafe.Pointer + +func _swig_wrap_new_XYArray(base int) (_ SwigcptrXYArray) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_XYArray, _swig_p) + return +} + +func NewXYArray(arg1 int) (_swig_ret XYArray) { + return _swig_wrap_new_XYArray(arg1) +} + +var _wrap_delete_XYArray unsafe.Pointer + +func _swig_wrap_delete_XYArray(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_XYArray, _swig_p) + return +} + +func DeleteXYArray(arg1 XYArray) { + _swig_wrap_delete_XYArray(arg1.Swigcptr()) +} + +var _wrap_XYArray_getitem unsafe.Pointer + +func _swig_wrap_XYArray_getitem(base SwigcptrXYArray, _ int) (_ SwigcptrXY) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_XYArray_getitem, _swig_p) + return +} + +func (arg1 SwigcptrXYArray) Getitem(arg2 int) (_swig_ret XY) { + return _swig_wrap_XYArray_getitem(arg1, arg2) +} + +var _wrap_XYArray_setitem unsafe.Pointer + +func _swig_wrap_XYArray_setitem(base SwigcptrXYArray, _ int, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_XYArray_setitem, _swig_p) + return +} + +func (arg1 SwigcptrXYArray) Setitem(arg2 int, arg3 XY) { + _swig_wrap_XYArray_setitem(arg1, arg2, arg3.Swigcptr()) +} + +var _wrap_XYArray_cast unsafe.Pointer + +func _swig_wrap_XYArray_cast(base SwigcptrXYArray) (_ SwigcptrXY) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_XYArray_cast, _swig_p) + return +} + +func (arg1 SwigcptrXYArray) Cast() (_swig_ret XY) { + return _swig_wrap_XYArray_cast(arg1) +} + +var _wrap_XYArray_frompointer unsafe.Pointer + +func _swig_wrap_XYArray_frompointer(base uintptr) (_ SwigcptrXYArray) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_XYArray_frompointer, _swig_p) + return +} + +func XYArrayFrompointer(arg1 XY) (_swig_ret XYArray) { + return _swig_wrap_XYArray_frompointer(arg1.Swigcptr()) +} + +type XYArray interface { + Swigcptr() uintptr + SwigIsXYArray() + Getitem(arg2 int) (_swig_ret XY) + Setitem(arg2 int, arg3 XY) + Cast() (_swig_ret XY) +} + +var _wrap_new_ABArray unsafe.Pointer + +func _swig_wrap_new_ABArray(base int) (_ SwigcptrAB) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_ABArray, _swig_p) + return +} + +func New_ABArray(arg1 int) (_swig_ret AB) { + return _swig_wrap_new_ABArray(arg1) +} + +var _wrap_delete_ABArray unsafe.Pointer + +func _swig_wrap_delete_ABArray(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_ABArray, _swig_p) + return +} + +func Delete_ABArray(arg1 AB) { + _swig_wrap_delete_ABArray(arg1.Swigcptr()) +} + +var _wrap_ABArray_getitem unsafe.Pointer + +func _swig_wrap_ABArray_getitem(base uintptr, _ int) (_ SwigcptrAB) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_ABArray_getitem, _swig_p) + return +} + +func ABArray_getitem(arg1 AB, arg2 int) (_swig_ret AB) { + return _swig_wrap_ABArray_getitem(arg1.Swigcptr(), arg2) +} + +var _wrap_ABArray_setitem unsafe.Pointer + +func _swig_wrap_ABArray_setitem(base uintptr, _ int, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_ABArray_setitem, _swig_p) + return +} + +func ABArray_setitem(arg1 AB, arg2 int, arg3 AB) { + _swig_wrap_ABArray_setitem(arg1.Swigcptr(), arg2, arg3.Swigcptr()) +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/li_carrays_runme b/Examples/test-suite/go/li_carrays_runme new file mode 100755 index 000000000..67404be6a Binary files /dev/null and b/Examples/test-suite/go/li_carrays_runme differ diff --git a/Examples/test-suite/go/li_cdata.go b/Examples/test-suite/go/li_cdata.go new file mode 100644 index 000000000..3e645731f --- /dev/null +++ b/Examples/test-suite/go/li_cdata.go @@ -0,0 +1,104 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../li_cdata.i + +package li_cdata + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +var _wrap_cdata unsafe.Pointer + +func _swig_wrap_cdata(base int, _ uintptr, _ int) (_ []byte ) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_cdata, _swig_p) + return +} + +func Cdata(arg1 uintptr, _swig_args ...interface{}) (_swig_ret []byte ) { + var arg2 int + if len(_swig_args) > 0 { + arg2 = _swig_args[0].(int) + } + return _swig_wrap_cdata(len(_swig_args), arg1, arg2) +} + +var _wrap_memmove unsafe.Pointer + +func _swig_wrap_memmove(base uintptr, _ string, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_memmove, _swig_p) + return +} + +func Memmove(arg1 uintptr, arg2 string, arg3 int) { + _swig_wrap_memmove(arg1, arg2, arg3) +} + +var _wrap_cdata_int unsafe.Pointer + +func _swig_wrap_cdata_int(base int, _ *int, _ int) (_ []byte ) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_cdata_int, _swig_p) + return +} + +func Cdata_int(arg1 *int, _swig_args ...interface{}) (_swig_ret []byte ) { + var arg2 int + if len(_swig_args) > 0 { + arg2 = _swig_args[0].(int) + } + return _swig_wrap_cdata_int(len(_swig_args), arg1, arg2) +} + +var _wrap_cdata_double unsafe.Pointer + +func _swig_wrap_cdata_double(base int, _ *float64, _ int) (_ []byte ) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_cdata_double, _swig_p) + return +} + +func Cdata_double(arg1 *float64, _swig_args ...interface{}) (_swig_ret []byte ) { + var arg2 int + if len(_swig_args) > 0 { + arg2 = _swig_args[0].(int) + } + return _swig_wrap_cdata_double(len(_swig_args), arg1, arg2) +} + +var _wrap_malloc unsafe.Pointer + +func Malloc(arg1 int64) (_swig_ret uintptr) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_malloc, _swig_p) + return +} + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/li_cdata_runme b/Examples/test-suite/go/li_cdata_runme new file mode 100755 index 000000000..196f24f7e Binary files /dev/null and b/Examples/test-suite/go/li_cdata_runme differ diff --git a/Examples/test-suite/go/li_cmalloc.go b/Examples/test-suite/go/li_cmalloc.go new file mode 100644 index 000000000..8a032c376 --- /dev/null +++ b/Examples/test-suite/go/li_cmalloc.go @@ -0,0 +1,272 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../li_cmalloc.i + +package li_cmalloc + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +var _wrap_malloc_int unsafe.Pointer + +func _swig_wrap_malloc_int(base int, _ int) (_ *int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_malloc_int, _swig_p) + return +} + +func Malloc_int(_swig_args ...interface{}) (_swig_ret *int) { + var arg1 int + if len(_swig_args) > 0 { + arg1 = _swig_args[0].(int) + } + return _swig_wrap_malloc_int(len(_swig_args), arg1) +} + +var _wrap_calloc_int unsafe.Pointer + +func _swig_wrap_calloc_int(base int, _ int, _ int) (_ *int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_calloc_int, _swig_p) + return +} + +func Calloc_int(_swig_args ...interface{}) (_swig_ret *int) { + var arg1 int + if len(_swig_args) > 0 { + arg1 = _swig_args[0].(int) + } + var arg2 int + if len(_swig_args) > 1 { + arg2 = _swig_args[1].(int) + } + return _swig_wrap_calloc_int(len(_swig_args), arg1, arg2) +} + +var _wrap_realloc_int unsafe.Pointer + +func Realloc_int(arg1 *int, arg2 int) (_swig_ret *int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_realloc_int, _swig_p) + return +} +var _wrap_free_int unsafe.Pointer + +func _swig_wrap_free_int(base *int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_free_int, _swig_p) + return +} + +func Free_int(arg1 *int) { + _swig_wrap_free_int(arg1) +} + +var _wrap_sizeof_int unsafe.Pointer + +func _swig_getsizeof_int() (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_sizeof_int, _swig_p) + return +} +var Sizeof_int int = _swig_getsizeof_int() +var _wrap_malloc_double unsafe.Pointer + +func _swig_wrap_malloc_double(base int, _ int) (_ *float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_malloc_double, _swig_p) + return +} + +func Malloc_double(_swig_args ...interface{}) (_swig_ret *float64) { + var arg1 int + if len(_swig_args) > 0 { + arg1 = _swig_args[0].(int) + } + return _swig_wrap_malloc_double(len(_swig_args), arg1) +} + +var _wrap_calloc_double unsafe.Pointer + +func _swig_wrap_calloc_double(base int, _ int, _ int) (_ *float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_calloc_double, _swig_p) + return +} + +func Calloc_double(_swig_args ...interface{}) (_swig_ret *float64) { + var arg1 int + if len(_swig_args) > 0 { + arg1 = _swig_args[0].(int) + } + var arg2 int + if len(_swig_args) > 1 { + arg2 = _swig_args[1].(int) + } + return _swig_wrap_calloc_double(len(_swig_args), arg1, arg2) +} + +var _wrap_realloc_double unsafe.Pointer + +func Realloc_double(arg1 *float64, arg2 int) (_swig_ret *float64) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_realloc_double, _swig_p) + return +} +var _wrap_free_double unsafe.Pointer + +func _swig_wrap_free_double(base *float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_free_double, _swig_p) + return +} + +func Free_double(arg1 *float64) { + _swig_wrap_free_double(arg1) +} + +var _wrap_sizeof_double unsafe.Pointer + +func _swig_getsizeof_double() (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_sizeof_double, _swig_p) + return +} +var Sizeof_double int = _swig_getsizeof_double() +var _wrap_malloc_void unsafe.Pointer + +func Malloc_void(arg1 int) (_swig_ret uintptr) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_malloc_void, _swig_p) + return +} +var _wrap_calloc_void unsafe.Pointer + +func _swig_wrap_calloc_void(base int, _ int, _ int) (_ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_calloc_void, _swig_p) + return +} + +func Calloc_void(_swig_args ...interface{}) (_swig_ret uintptr) { + var arg1 int + if len(_swig_args) > 0 { + arg1 = _swig_args[0].(int) + } + var arg2 int + if len(_swig_args) > 1 { + arg2 = _swig_args[1].(int) + } + return _swig_wrap_calloc_void(len(_swig_args), arg1, arg2) +} + +var _wrap_realloc_void unsafe.Pointer + +func Realloc_void(arg1 uintptr, arg2 int) (_swig_ret uintptr) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_realloc_void, _swig_p) + return +} +var _wrap_free_void unsafe.Pointer + +func _swig_wrap_free_void(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_free_void, _swig_p) + return +} + +func Free_void(arg1 uintptr) { + _swig_wrap_free_void(arg1) +} + +var _wrap_malloc_intp unsafe.Pointer + +func _swig_wrap_malloc_intp(base int, _ int) (_ **int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_malloc_intp, _swig_p) + return +} + +func Malloc_intp(_swig_args ...interface{}) (_swig_ret **int) { + var arg1 int + if len(_swig_args) > 0 { + arg1 = _swig_args[0].(int) + } + return _swig_wrap_malloc_intp(len(_swig_args), arg1) +} + +var _wrap_calloc_intp unsafe.Pointer + +func _swig_wrap_calloc_intp(base int, _ int, _ int) (_ **int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_calloc_intp, _swig_p) + return +} + +func Calloc_intp(_swig_args ...interface{}) (_swig_ret **int) { + var arg1 int + if len(_swig_args) > 0 { + arg1 = _swig_args[0].(int) + } + var arg2 int + if len(_swig_args) > 1 { + arg2 = _swig_args[1].(int) + } + return _swig_wrap_calloc_intp(len(_swig_args), arg1, arg2) +} + +var _wrap_realloc_intp unsafe.Pointer + +func Realloc_intp(arg1 **int, arg2 int) (_swig_ret **int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_realloc_intp, _swig_p) + return +} +var _wrap_free_intp unsafe.Pointer + +func _swig_wrap_free_intp(base **int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_free_intp, _swig_p) + return +} + +func Free_intp(arg1 **int) { + _swig_wrap_free_intp(arg1) +} + +var _wrap_sizeof_intp unsafe.Pointer + +func _swig_getsizeof_intp() (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_sizeof_intp, _swig_p) + return +} +var Sizeof_intp int = _swig_getsizeof_intp() + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/li_cmalloc_runme b/Examples/test-suite/go/li_cmalloc_runme new file mode 100755 index 000000000..f6bf4f7a7 Binary files /dev/null and b/Examples/test-suite/go/li_cmalloc_runme differ diff --git a/Examples/test-suite/go/li_constraints.go b/Examples/test-suite/go/li_constraints.go new file mode 100644 index 000000000..db57d888e --- /dev/null +++ b/Examples/test-suite/go/li_constraints.go @@ -0,0 +1,109 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../li_constraints.i + +package li_constraints + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +var _wrap_test_nonnegative unsafe.Pointer + +func _swig_wrap_test_nonnegative(base float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_test_nonnegative, _swig_p) + return +} + +func Test_nonnegative(arg1 float64) { + _swig_wrap_test_nonnegative(arg1) +} + +var _wrap_test_nonpositive unsafe.Pointer + +func _swig_wrap_test_nonpositive(base float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_test_nonpositive, _swig_p) + return +} + +func Test_nonpositive(arg1 float64) { + _swig_wrap_test_nonpositive(arg1) +} + +var _wrap_test_positive unsafe.Pointer + +func _swig_wrap_test_positive(base float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_test_positive, _swig_p) + return +} + +func Test_positive(arg1 float64) { + _swig_wrap_test_positive(arg1) +} + +var _wrap_test_negative unsafe.Pointer + +func _swig_wrap_test_negative(base float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_test_negative, _swig_p) + return +} + +func Test_negative(arg1 float64) { + _swig_wrap_test_negative(arg1) +} + +var _wrap_test_nonzero unsafe.Pointer + +func _swig_wrap_test_nonzero(base float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_test_nonzero, _swig_p) + return +} + +func Test_nonzero(arg1 float64) { + _swig_wrap_test_nonzero(arg1) +} + +var _wrap_test_nonnull unsafe.Pointer + +func _swig_wrap_test_nonnull(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_test_nonnull, _swig_p) + return +} + +func Test_nonnull(arg1 uintptr) { + _swig_wrap_test_nonnull(arg1) +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/li_cpointer.go b/Examples/test-suite/go/li_cpointer.go new file mode 100644 index 000000000..a2c425a86 --- /dev/null +++ b/Examples/test-suite/go/li_cpointer.go @@ -0,0 +1,178 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../li_cpointer.i + +package li_cpointer + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +var _wrap_new_intp unsafe.Pointer + +func New_intp() (_swig_ret *int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_new_intp, _swig_p) + return +} +var _wrap_copy_intp unsafe.Pointer + +func Copy_intp(arg1 int) (_swig_ret *int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_copy_intp, _swig_p) + return +} +var _wrap_delete_intp unsafe.Pointer + +func _swig_wrap_delete_intp(base *int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_intp, _swig_p) + return +} + +func Delete_intp(arg1 *int) { + _swig_wrap_delete_intp(arg1) +} + +var _wrap_intp_assign unsafe.Pointer + +func _swig_wrap_intp_assign(base *int, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_intp_assign, _swig_p) + return +} + +func Intp_assign(arg1 *int, arg2 int) { + _swig_wrap_intp_assign(arg1, arg2) +} + +var _wrap_intp_value unsafe.Pointer + +func Intp_value(arg1 *int) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_intp_value, _swig_p) + return +} +type SwigcptrDoublep uintptr + +func (p SwigcptrDoublep) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrDoublep) SwigIsDoublep() { +} + +var _wrap_new_doublep unsafe.Pointer + +func _swig_wrap_new_doublep() (base SwigcptrDoublep) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_doublep, _swig_p) + return +} + +func NewDoublep() (_swig_ret Doublep) { + return _swig_wrap_new_doublep() +} + +var _wrap_delete_doublep unsafe.Pointer + +func _swig_wrap_delete_doublep(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_doublep, _swig_p) + return +} + +func DeleteDoublep(arg1 Doublep) { + _swig_wrap_delete_doublep(arg1.Swigcptr()) +} + +var _wrap_doublep_assign unsafe.Pointer + +func _swig_wrap_doublep_assign(base SwigcptrDoublep, _ float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_doublep_assign, _swig_p) + return +} + +func (arg1 SwigcptrDoublep) Assign(arg2 float64) { + _swig_wrap_doublep_assign(arg1, arg2) +} + +var _wrap_doublep_value unsafe.Pointer + +func _swig_wrap_doublep_value(base SwigcptrDoublep) (_ float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_doublep_value, _swig_p) + return +} + +func (arg1 SwigcptrDoublep) Value() (_swig_ret float64) { + return _swig_wrap_doublep_value(arg1) +} + +var _wrap_doublep_cast unsafe.Pointer + +func _swig_wrap_doublep_cast(base SwigcptrDoublep) (_ *float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_doublep_cast, _swig_p) + return +} + +func (arg1 SwigcptrDoublep) Cast() (_swig_ret *float64) { + return _swig_wrap_doublep_cast(arg1) +} + +var _wrap_doublep_frompointer unsafe.Pointer + +func _swig_wrap_doublep_frompointer(base *float64) (_ SwigcptrDoublep) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_doublep_frompointer, _swig_p) + return +} + +func DoublepFrompointer(arg1 *float64) (_swig_ret Doublep) { + return _swig_wrap_doublep_frompointer(arg1) +} + +type Doublep interface { + Swigcptr() uintptr + SwigIsDoublep() + Assign(arg2 float64) + Value() (_swig_ret float64) + Cast() (_swig_ret *float64) +} + +var _wrap_int_to_uint unsafe.Pointer + +func Int_to_uint(arg1 int) (_swig_ret uint) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_int_to_uint, _swig_p) + return +} + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/li_cpointer_runme b/Examples/test-suite/go/li_cpointer_runme new file mode 100755 index 000000000..612390139 Binary files /dev/null and b/Examples/test-suite/go/li_cpointer_runme differ diff --git a/Examples/test-suite/go/li_math.go b/Examples/test-suite/go/li_math.go new file mode 100644 index 000000000..bf882e136 --- /dev/null +++ b/Examples/test-suite/go/li_math.go @@ -0,0 +1,175 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../li_math.i + +package li_math + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +var _wrap_cos unsafe.Pointer + +func Cos(arg1 float64) (_swig_ret float64) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_cos, _swig_p) + return +} +var _wrap_sin unsafe.Pointer + +func Sin(arg1 float64) (_swig_ret float64) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_sin, _swig_p) + return +} +var _wrap_tan unsafe.Pointer + +func Tan(arg1 float64) (_swig_ret float64) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_tan, _swig_p) + return +} +var _wrap_acos unsafe.Pointer + +func Acos(arg1 float64) (_swig_ret float64) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_acos, _swig_p) + return +} +var _wrap_asin unsafe.Pointer + +func Asin(arg1 float64) (_swig_ret float64) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_asin, _swig_p) + return +} +var _wrap_atan unsafe.Pointer + +func Atan(arg1 float64) (_swig_ret float64) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_atan, _swig_p) + return +} +var _wrap_atan2 unsafe.Pointer + +func Atan2(arg1 float64, arg2 float64) (_swig_ret float64) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_atan2, _swig_p) + return +} +var _wrap_cosh unsafe.Pointer + +func Cosh(arg1 float64) (_swig_ret float64) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_cosh, _swig_p) + return +} +var _wrap_sinh unsafe.Pointer + +func Sinh(arg1 float64) (_swig_ret float64) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_sinh, _swig_p) + return +} +var _wrap_tanh unsafe.Pointer + +func Tanh(arg1 float64) (_swig_ret float64) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_tanh, _swig_p) + return +} +var _wrap_exp unsafe.Pointer + +func Exp(arg1 float64) (_swig_ret float64) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_exp, _swig_p) + return +} +var _wrap_log unsafe.Pointer + +func Log(arg1 float64) (_swig_ret float64) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_log, _swig_p) + return +} +var _wrap_log10 unsafe.Pointer + +func Log10(arg1 float64) (_swig_ret float64) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_log10, _swig_p) + return +} +var _wrap_pow unsafe.Pointer + +func Pow(arg1 float64, arg2 float64) (_swig_ret float64) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_pow, _swig_p) + return +} +var _wrap_sqrt unsafe.Pointer + +func Sqrt(arg1 float64) (_swig_ret float64) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_sqrt, _swig_p) + return +} +var _wrap_fabs unsafe.Pointer + +func Fabs(arg1 float64) (_swig_ret float64) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_fabs, _swig_p) + return +} +var _wrap_ceil unsafe.Pointer + +func Ceil(arg1 float64) (_swig_ret float64) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_ceil, _swig_p) + return +} +var _wrap_floor unsafe.Pointer + +func Floor(arg1 float64) (_swig_ret float64) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_floor, _swig_p) + return +} +var _wrap_fmod unsafe.Pointer + +func Fmod(arg1 float64, arg2 float64) (_swig_ret float64) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_fmod, _swig_p) + return +} +const M_E float64 = 2.7182818284590452354 +const M_LOG2E float64 = 1.4426950408889634074 +const M_LOG10E float64 = 0.43429448190325182765 +const M_LN2 float64 = 0.69314718055994530942 +const M_LN10 float64 = 2.30258509299404568402 +const M_PI float64 = 3.14159265358979323846 +const M_PI_2 float64 = 1.57079632679489661923 +const M_PI_4 float64 = 0.78539816339744830962 +const M_1_PI float64 = 0.31830988618379067154 +const M_2_PI float64 = 0.63661977236758134308 +const M_2_SQRTPI float64 = 1.12837916709551257390 +const M_SQRT2 float64 = 1.41421356237309504880 +const M_SQRT1_2 float64 = 0.70710678118654752440 + diff --git a/Examples/test-suite/go/li_std_auto_ptr.go b/Examples/test-suite/go/li_std_auto_ptr.go new file mode 100644 index 000000000..4954ac911 --- /dev/null +++ b/Examples/test-suite/go/li_std_auto_ptr.go @@ -0,0 +1,29 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../li_std_auto_ptr.i + +package li_std_auto_ptr + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + + diff --git a/Examples/test-suite/go/li_std_combinations.go b/Examples/test-suite/go/li_std_combinations.go new file mode 100644 index 000000000..8942dbc69 --- /dev/null +++ b/Examples/test-suite/go/li_std_combinations.go @@ -0,0 +1,1374 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../li_std_combinations.i + +package li_std_combinations + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrVectorInt uintptr + +func (p SwigcptrVectorInt) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrVectorInt) SwigIsVectorInt() { +} + +var _wrap_new_VectorInt__SWIG_0 unsafe.Pointer + +func _swig_wrap_new_VectorInt__SWIG_0() (base SwigcptrVectorInt) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_VectorInt__SWIG_0, _swig_p) + return +} + +func NewVectorInt__SWIG_0() (_swig_ret VectorInt) { + return _swig_wrap_new_VectorInt__SWIG_0() +} + +var _wrap_new_VectorInt__SWIG_1 unsafe.Pointer + +func _swig_wrap_new_VectorInt__SWIG_1(base int64) (_ SwigcptrVectorInt) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_VectorInt__SWIG_1, _swig_p) + return +} + +func NewVectorInt__SWIG_1(arg1 int64) (_swig_ret VectorInt) { + return _swig_wrap_new_VectorInt__SWIG_1(arg1) +} + +func NewVectorInt(a ...interface{}) VectorInt { + argc := len(a) + if argc == 0 { + return NewVectorInt__SWIG_0() + } + if argc == 1 { + return NewVectorInt__SWIG_1(a[0].(int64)) + } + panic("No match for overloaded function call") +} + +var _wrap_VectorInt_size unsafe.Pointer + +func _swig_wrap_VectorInt_size(base SwigcptrVectorInt) (_ int64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_VectorInt_size, _swig_p) + return +} + +func (arg1 SwigcptrVectorInt) Size() (_swig_ret int64) { + return _swig_wrap_VectorInt_size(arg1) +} + +var _wrap_VectorInt_capacity unsafe.Pointer + +func _swig_wrap_VectorInt_capacity(base SwigcptrVectorInt) (_ int64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_VectorInt_capacity, _swig_p) + return +} + +func (arg1 SwigcptrVectorInt) Capacity() (_swig_ret int64) { + return _swig_wrap_VectorInt_capacity(arg1) +} + +var _wrap_VectorInt_reserve unsafe.Pointer + +func _swig_wrap_VectorInt_reserve(base SwigcptrVectorInt, _ int64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_VectorInt_reserve, _swig_p) + return +} + +func (arg1 SwigcptrVectorInt) Reserve(arg2 int64) { + _swig_wrap_VectorInt_reserve(arg1, arg2) +} + +var _wrap_VectorInt_isEmpty unsafe.Pointer + +func _swig_wrap_VectorInt_isEmpty(base SwigcptrVectorInt) (_ bool) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_VectorInt_isEmpty, _swig_p) + return +} + +func (arg1 SwigcptrVectorInt) IsEmpty() (_swig_ret bool) { + return _swig_wrap_VectorInt_isEmpty(arg1) +} + +var _wrap_VectorInt_clear unsafe.Pointer + +func _swig_wrap_VectorInt_clear(base SwigcptrVectorInt) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_VectorInt_clear, _swig_p) + return +} + +func (arg1 SwigcptrVectorInt) Clear() { + _swig_wrap_VectorInt_clear(arg1) +} + +var _wrap_VectorInt_add unsafe.Pointer + +func _swig_wrap_VectorInt_add(base SwigcptrVectorInt, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_VectorInt_add, _swig_p) + return +} + +func (arg1 SwigcptrVectorInt) Add(arg2 int) { + _swig_wrap_VectorInt_add(arg1, arg2) +} + +var _wrap_VectorInt_get unsafe.Pointer + +func _swig_wrap_VectorInt_get(base SwigcptrVectorInt, _ int) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_VectorInt_get, _swig_p) + return +} + +func (arg1 SwigcptrVectorInt) Get(arg2 int) (_swig_ret int) { + return _swig_wrap_VectorInt_get(arg1, arg2) +} + +var _wrap_VectorInt_set unsafe.Pointer + +func _swig_wrap_VectorInt_set(base SwigcptrVectorInt, _ int, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_VectorInt_set, _swig_p) + return +} + +func (arg1 SwigcptrVectorInt) Set(arg2 int, arg3 int) { + _swig_wrap_VectorInt_set(arg1, arg2, arg3) +} + +var _wrap_delete_VectorInt unsafe.Pointer + +func _swig_wrap_delete_VectorInt(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_VectorInt, _swig_p) + return +} + +func DeleteVectorInt(arg1 VectorInt) { + _swig_wrap_delete_VectorInt(arg1.Swigcptr()) +} + +type VectorInt interface { + Swigcptr() uintptr + SwigIsVectorInt() + Size() (_swig_ret int64) + Capacity() (_swig_ret int64) + Reserve(arg2 int64) + IsEmpty() (_swig_ret bool) + Clear() + Add(arg2 int) + Get(arg2 int) (_swig_ret int) + Set(arg2 int, arg3 int) +} + +type SwigcptrVectorString uintptr + +func (p SwigcptrVectorString) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrVectorString) SwigIsVectorString() { +} + +var _wrap_new_VectorString__SWIG_0 unsafe.Pointer + +func _swig_wrap_new_VectorString__SWIG_0() (base SwigcptrVectorString) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_VectorString__SWIG_0, _swig_p) + return +} + +func NewVectorString__SWIG_0() (_swig_ret VectorString) { + return _swig_wrap_new_VectorString__SWIG_0() +} + +var _wrap_new_VectorString__SWIG_1 unsafe.Pointer + +func _swig_wrap_new_VectorString__SWIG_1(base int64) (_ SwigcptrVectorString) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_VectorString__SWIG_1, _swig_p) + return +} + +func NewVectorString__SWIG_1(arg1 int64) (_swig_ret VectorString) { + return _swig_wrap_new_VectorString__SWIG_1(arg1) +} + +func NewVectorString(a ...interface{}) VectorString { + argc := len(a) + if argc == 0 { + return NewVectorString__SWIG_0() + } + if argc == 1 { + return NewVectorString__SWIG_1(a[0].(int64)) + } + panic("No match for overloaded function call") +} + +var _wrap_VectorString_size unsafe.Pointer + +func _swig_wrap_VectorString_size(base SwigcptrVectorString) (_ int64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_VectorString_size, _swig_p) + return +} + +func (arg1 SwigcptrVectorString) Size() (_swig_ret int64) { + return _swig_wrap_VectorString_size(arg1) +} + +var _wrap_VectorString_capacity unsafe.Pointer + +func _swig_wrap_VectorString_capacity(base SwigcptrVectorString) (_ int64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_VectorString_capacity, _swig_p) + return +} + +func (arg1 SwigcptrVectorString) Capacity() (_swig_ret int64) { + return _swig_wrap_VectorString_capacity(arg1) +} + +var _wrap_VectorString_reserve unsafe.Pointer + +func _swig_wrap_VectorString_reserve(base SwigcptrVectorString, _ int64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_VectorString_reserve, _swig_p) + return +} + +func (arg1 SwigcptrVectorString) Reserve(arg2 int64) { + _swig_wrap_VectorString_reserve(arg1, arg2) +} + +var _wrap_VectorString_isEmpty unsafe.Pointer + +func _swig_wrap_VectorString_isEmpty(base SwigcptrVectorString) (_ bool) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_VectorString_isEmpty, _swig_p) + return +} + +func (arg1 SwigcptrVectorString) IsEmpty() (_swig_ret bool) { + return _swig_wrap_VectorString_isEmpty(arg1) +} + +var _wrap_VectorString_clear unsafe.Pointer + +func _swig_wrap_VectorString_clear(base SwigcptrVectorString) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_VectorString_clear, _swig_p) + return +} + +func (arg1 SwigcptrVectorString) Clear() { + _swig_wrap_VectorString_clear(arg1) +} + +var _wrap_VectorString_add unsafe.Pointer + +func _swig_wrap_VectorString_add(base SwigcptrVectorString, _ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_VectorString_add, _swig_p) + return +} + +func (arg1 SwigcptrVectorString) Add(arg2 string) { + _swig_wrap_VectorString_add(arg1, arg2) +} + +var _wrap_VectorString_get unsafe.Pointer + +func _swig_wrap_VectorString_get(base SwigcptrVectorString, _ int) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_VectorString_get, _swig_p) + return +} + +func (arg1 SwigcptrVectorString) Get(arg2 int) (_swig_ret string) { + return _swig_wrap_VectorString_get(arg1, arg2) +} + +var _wrap_VectorString_set unsafe.Pointer + +func _swig_wrap_VectorString_set(base SwigcptrVectorString, _ int, _ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_VectorString_set, _swig_p) + return +} + +func (arg1 SwigcptrVectorString) Set(arg2 int, arg3 string) { + _swig_wrap_VectorString_set(arg1, arg2, arg3) +} + +var _wrap_delete_VectorString unsafe.Pointer + +func _swig_wrap_delete_VectorString(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_VectorString, _swig_p) + return +} + +func DeleteVectorString(arg1 VectorString) { + _swig_wrap_delete_VectorString(arg1.Swigcptr()) +} + +type VectorString interface { + Swigcptr() uintptr + SwigIsVectorString() + Size() (_swig_ret int64) + Capacity() (_swig_ret int64) + Reserve(arg2 int64) + IsEmpty() (_swig_ret bool) + Clear() + Add(arg2 string) + Get(arg2 int) (_swig_ret string) + Set(arg2 int, arg3 string) +} + +type SwigcptrPairIntString uintptr + +func (p SwigcptrPairIntString) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrPairIntString) SwigIsPairIntString() { +} + +var _wrap_new_PairIntString__SWIG_0 unsafe.Pointer + +func _swig_wrap_new_PairIntString__SWIG_0() (base SwigcptrPairIntString) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_PairIntString__SWIG_0, _swig_p) + return +} + +func NewPairIntString__SWIG_0() (_swig_ret PairIntString) { + return _swig_wrap_new_PairIntString__SWIG_0() +} + +var _wrap_new_PairIntString__SWIG_1 unsafe.Pointer + +func _swig_wrap_new_PairIntString__SWIG_1(base int, _ string) (_ SwigcptrPairIntString) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_PairIntString__SWIG_1, _swig_p) + return +} + +func NewPairIntString__SWIG_1(arg1 int, arg2 string) (_swig_ret PairIntString) { + return _swig_wrap_new_PairIntString__SWIG_1(arg1, arg2) +} + +var _wrap_new_PairIntString__SWIG_2 unsafe.Pointer + +func _swig_wrap_new_PairIntString__SWIG_2(base uintptr) (_ SwigcptrPairIntString) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_PairIntString__SWIG_2, _swig_p) + return +} + +func NewPairIntString__SWIG_2(arg1 PairIntString) (_swig_ret PairIntString) { + return _swig_wrap_new_PairIntString__SWIG_2(arg1.Swigcptr()) +} + +func NewPairIntString(a ...interface{}) PairIntString { + argc := len(a) + if argc == 0 { + return NewPairIntString__SWIG_0() + } + if argc == 1 { + return NewPairIntString__SWIG_2(a[0].(PairIntString)) + } + if argc == 2 { + return NewPairIntString__SWIG_1(a[0].(int), a[1].(string)) + } + panic("No match for overloaded function call") +} + +var _wrap_PairIntString_first_set unsafe.Pointer + +func _swig_wrap_PairIntString_first_set(base SwigcptrPairIntString, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_PairIntString_first_set, _swig_p) + return +} + +func (arg1 SwigcptrPairIntString) SetFirst(arg2 int) { + _swig_wrap_PairIntString_first_set(arg1, arg2) +} + +var _wrap_PairIntString_first_get unsafe.Pointer + +func _swig_wrap_PairIntString_first_get(base SwigcptrPairIntString) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_PairIntString_first_get, _swig_p) + return +} + +func (arg1 SwigcptrPairIntString) GetFirst() (_swig_ret int) { + return _swig_wrap_PairIntString_first_get(arg1) +} + +var _wrap_PairIntString_second_set unsafe.Pointer + +func _swig_wrap_PairIntString_second_set(base SwigcptrPairIntString, _ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_PairIntString_second_set, _swig_p) + return +} + +func (arg1 SwigcptrPairIntString) SetSecond(arg2 string) { + _swig_wrap_PairIntString_second_set(arg1, arg2) +} + +var _wrap_PairIntString_second_get unsafe.Pointer + +func _swig_wrap_PairIntString_second_get(base SwigcptrPairIntString) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_PairIntString_second_get, _swig_p) + return +} + +func (arg1 SwigcptrPairIntString) GetSecond() (_swig_ret string) { + return _swig_wrap_PairIntString_second_get(arg1) +} + +var _wrap_delete_PairIntString unsafe.Pointer + +func _swig_wrap_delete_PairIntString(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_PairIntString, _swig_p) + return +} + +func DeletePairIntString(arg1 PairIntString) { + _swig_wrap_delete_PairIntString(arg1.Swigcptr()) +} + +type PairIntString interface { + Swigcptr() uintptr + SwigIsPairIntString() + SetFirst(arg2 int) + GetFirst() (_swig_ret int) + SetSecond(arg2 string) + GetSecond() (_swig_ret string) +} + +type SwigcptrVectorPairIntString uintptr + +func (p SwigcptrVectorPairIntString) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrVectorPairIntString) SwigIsVectorPairIntString() { +} + +var _wrap_new_VectorPairIntString__SWIG_0 unsafe.Pointer + +func _swig_wrap_new_VectorPairIntString__SWIG_0() (base SwigcptrVectorPairIntString) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_VectorPairIntString__SWIG_0, _swig_p) + return +} + +func NewVectorPairIntString__SWIG_0() (_swig_ret VectorPairIntString) { + return _swig_wrap_new_VectorPairIntString__SWIG_0() +} + +var _wrap_new_VectorPairIntString__SWIG_1 unsafe.Pointer + +func _swig_wrap_new_VectorPairIntString__SWIG_1(base int64) (_ SwigcptrVectorPairIntString) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_VectorPairIntString__SWIG_1, _swig_p) + return +} + +func NewVectorPairIntString__SWIG_1(arg1 int64) (_swig_ret VectorPairIntString) { + return _swig_wrap_new_VectorPairIntString__SWIG_1(arg1) +} + +func NewVectorPairIntString(a ...interface{}) VectorPairIntString { + argc := len(a) + if argc == 0 { + return NewVectorPairIntString__SWIG_0() + } + if argc == 1 { + return NewVectorPairIntString__SWIG_1(a[0].(int64)) + } + panic("No match for overloaded function call") +} + +var _wrap_VectorPairIntString_size unsafe.Pointer + +func _swig_wrap_VectorPairIntString_size(base SwigcptrVectorPairIntString) (_ int64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_VectorPairIntString_size, _swig_p) + return +} + +func (arg1 SwigcptrVectorPairIntString) Size() (_swig_ret int64) { + return _swig_wrap_VectorPairIntString_size(arg1) +} + +var _wrap_VectorPairIntString_capacity unsafe.Pointer + +func _swig_wrap_VectorPairIntString_capacity(base SwigcptrVectorPairIntString) (_ int64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_VectorPairIntString_capacity, _swig_p) + return +} + +func (arg1 SwigcptrVectorPairIntString) Capacity() (_swig_ret int64) { + return _swig_wrap_VectorPairIntString_capacity(arg1) +} + +var _wrap_VectorPairIntString_reserve unsafe.Pointer + +func _swig_wrap_VectorPairIntString_reserve(base SwigcptrVectorPairIntString, _ int64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_VectorPairIntString_reserve, _swig_p) + return +} + +func (arg1 SwigcptrVectorPairIntString) Reserve(arg2 int64) { + _swig_wrap_VectorPairIntString_reserve(arg1, arg2) +} + +var _wrap_VectorPairIntString_isEmpty unsafe.Pointer + +func _swig_wrap_VectorPairIntString_isEmpty(base SwigcptrVectorPairIntString) (_ bool) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_VectorPairIntString_isEmpty, _swig_p) + return +} + +func (arg1 SwigcptrVectorPairIntString) IsEmpty() (_swig_ret bool) { + return _swig_wrap_VectorPairIntString_isEmpty(arg1) +} + +var _wrap_VectorPairIntString_clear unsafe.Pointer + +func _swig_wrap_VectorPairIntString_clear(base SwigcptrVectorPairIntString) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_VectorPairIntString_clear, _swig_p) + return +} + +func (arg1 SwigcptrVectorPairIntString) Clear() { + _swig_wrap_VectorPairIntString_clear(arg1) +} + +var _wrap_VectorPairIntString_add unsafe.Pointer + +func _swig_wrap_VectorPairIntString_add(base SwigcptrVectorPairIntString, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_VectorPairIntString_add, _swig_p) + return +} + +func (arg1 SwigcptrVectorPairIntString) Add(arg2 PairIntString) { + _swig_wrap_VectorPairIntString_add(arg1, arg2.Swigcptr()) +} + +var _wrap_VectorPairIntString_get unsafe.Pointer + +func _swig_wrap_VectorPairIntString_get(base SwigcptrVectorPairIntString, _ int) (_ SwigcptrPairIntString) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_VectorPairIntString_get, _swig_p) + return +} + +func (arg1 SwigcptrVectorPairIntString) Get(arg2 int) (_swig_ret PairIntString) { + return _swig_wrap_VectorPairIntString_get(arg1, arg2) +} + +var _wrap_VectorPairIntString_set unsafe.Pointer + +func _swig_wrap_VectorPairIntString_set(base SwigcptrVectorPairIntString, _ int, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_VectorPairIntString_set, _swig_p) + return +} + +func (arg1 SwigcptrVectorPairIntString) Set(arg2 int, arg3 PairIntString) { + _swig_wrap_VectorPairIntString_set(arg1, arg2, arg3.Swigcptr()) +} + +var _wrap_delete_VectorPairIntString unsafe.Pointer + +func _swig_wrap_delete_VectorPairIntString(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_VectorPairIntString, _swig_p) + return +} + +func DeleteVectorPairIntString(arg1 VectorPairIntString) { + _swig_wrap_delete_VectorPairIntString(arg1.Swigcptr()) +} + +type VectorPairIntString interface { + Swigcptr() uintptr + SwigIsVectorPairIntString() + Size() (_swig_ret int64) + Capacity() (_swig_ret int64) + Reserve(arg2 int64) + IsEmpty() (_swig_ret bool) + Clear() + Add(arg2 PairIntString) + Get(arg2 int) (_swig_ret PairIntString) + Set(arg2 int, arg3 PairIntString) +} + +type SwigcptrPairIntVectorString uintptr + +func (p SwigcptrPairIntVectorString) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrPairIntVectorString) SwigIsPairIntVectorString() { +} + +var _wrap_new_PairIntVectorString__SWIG_0 unsafe.Pointer + +func _swig_wrap_new_PairIntVectorString__SWIG_0() (base SwigcptrPairIntVectorString) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_PairIntVectorString__SWIG_0, _swig_p) + return +} + +func NewPairIntVectorString__SWIG_0() (_swig_ret PairIntVectorString) { + return _swig_wrap_new_PairIntVectorString__SWIG_0() +} + +var _wrap_new_PairIntVectorString__SWIG_1 unsafe.Pointer + +func _swig_wrap_new_PairIntVectorString__SWIG_1(base int, _ uintptr) (_ SwigcptrPairIntVectorString) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_PairIntVectorString__SWIG_1, _swig_p) + return +} + +func NewPairIntVectorString__SWIG_1(arg1 int, arg2 VectorString) (_swig_ret PairIntVectorString) { + return _swig_wrap_new_PairIntVectorString__SWIG_1(arg1, arg2.Swigcptr()) +} + +var _wrap_new_PairIntVectorString__SWIG_2 unsafe.Pointer + +func _swig_wrap_new_PairIntVectorString__SWIG_2(base uintptr) (_ SwigcptrPairIntVectorString) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_PairIntVectorString__SWIG_2, _swig_p) + return +} + +func NewPairIntVectorString__SWIG_2(arg1 PairIntVectorString) (_swig_ret PairIntVectorString) { + return _swig_wrap_new_PairIntVectorString__SWIG_2(arg1.Swigcptr()) +} + +func NewPairIntVectorString(a ...interface{}) PairIntVectorString { + argc := len(a) + if argc == 0 { + return NewPairIntVectorString__SWIG_0() + } + if argc == 1 { + return NewPairIntVectorString__SWIG_2(a[0].(PairIntVectorString)) + } + if argc == 2 { + return NewPairIntVectorString__SWIG_1(a[0].(int), a[1].(VectorString)) + } + panic("No match for overloaded function call") +} + +var _wrap_PairIntVectorString_first_set unsafe.Pointer + +func _swig_wrap_PairIntVectorString_first_set(base SwigcptrPairIntVectorString, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_PairIntVectorString_first_set, _swig_p) + return +} + +func (arg1 SwigcptrPairIntVectorString) SetFirst(arg2 int) { + _swig_wrap_PairIntVectorString_first_set(arg1, arg2) +} + +var _wrap_PairIntVectorString_first_get unsafe.Pointer + +func _swig_wrap_PairIntVectorString_first_get(base SwigcptrPairIntVectorString) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_PairIntVectorString_first_get, _swig_p) + return +} + +func (arg1 SwigcptrPairIntVectorString) GetFirst() (_swig_ret int) { + return _swig_wrap_PairIntVectorString_first_get(arg1) +} + +var _wrap_PairIntVectorString_second_set unsafe.Pointer + +func _swig_wrap_PairIntVectorString_second_set(base SwigcptrPairIntVectorString, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_PairIntVectorString_second_set, _swig_p) + return +} + +func (arg1 SwigcptrPairIntVectorString) SetSecond(arg2 VectorString) { + _swig_wrap_PairIntVectorString_second_set(arg1, arg2.Swigcptr()) +} + +var _wrap_PairIntVectorString_second_get unsafe.Pointer + +func _swig_wrap_PairIntVectorString_second_get(base SwigcptrPairIntVectorString) (_ SwigcptrVectorString) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_PairIntVectorString_second_get, _swig_p) + return +} + +func (arg1 SwigcptrPairIntVectorString) GetSecond() (_swig_ret VectorString) { + return _swig_wrap_PairIntVectorString_second_get(arg1) +} + +var _wrap_delete_PairIntVectorString unsafe.Pointer + +func _swig_wrap_delete_PairIntVectorString(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_PairIntVectorString, _swig_p) + return +} + +func DeletePairIntVectorString(arg1 PairIntVectorString) { + _swig_wrap_delete_PairIntVectorString(arg1.Swigcptr()) +} + +type PairIntVectorString interface { + Swigcptr() uintptr + SwigIsPairIntVectorString() + SetFirst(arg2 int) + GetFirst() (_swig_ret int) + SetSecond(arg2 VectorString) + GetSecond() (_swig_ret VectorString) +} + +type SwigcptrVectorVectorString uintptr + +func (p SwigcptrVectorVectorString) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrVectorVectorString) SwigIsVectorVectorString() { +} + +var _wrap_new_VectorVectorString__SWIG_0 unsafe.Pointer + +func _swig_wrap_new_VectorVectorString__SWIG_0() (base SwigcptrVectorVectorString) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_VectorVectorString__SWIG_0, _swig_p) + return +} + +func NewVectorVectorString__SWIG_0() (_swig_ret VectorVectorString) { + return _swig_wrap_new_VectorVectorString__SWIG_0() +} + +var _wrap_new_VectorVectorString__SWIG_1 unsafe.Pointer + +func _swig_wrap_new_VectorVectorString__SWIG_1(base int64) (_ SwigcptrVectorVectorString) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_VectorVectorString__SWIG_1, _swig_p) + return +} + +func NewVectorVectorString__SWIG_1(arg1 int64) (_swig_ret VectorVectorString) { + return _swig_wrap_new_VectorVectorString__SWIG_1(arg1) +} + +func NewVectorVectorString(a ...interface{}) VectorVectorString { + argc := len(a) + if argc == 0 { + return NewVectorVectorString__SWIG_0() + } + if argc == 1 { + return NewVectorVectorString__SWIG_1(a[0].(int64)) + } + panic("No match for overloaded function call") +} + +var _wrap_VectorVectorString_size unsafe.Pointer + +func _swig_wrap_VectorVectorString_size(base SwigcptrVectorVectorString) (_ int64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_VectorVectorString_size, _swig_p) + return +} + +func (arg1 SwigcptrVectorVectorString) Size() (_swig_ret int64) { + return _swig_wrap_VectorVectorString_size(arg1) +} + +var _wrap_VectorVectorString_capacity unsafe.Pointer + +func _swig_wrap_VectorVectorString_capacity(base SwigcptrVectorVectorString) (_ int64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_VectorVectorString_capacity, _swig_p) + return +} + +func (arg1 SwigcptrVectorVectorString) Capacity() (_swig_ret int64) { + return _swig_wrap_VectorVectorString_capacity(arg1) +} + +var _wrap_VectorVectorString_reserve unsafe.Pointer + +func _swig_wrap_VectorVectorString_reserve(base SwigcptrVectorVectorString, _ int64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_VectorVectorString_reserve, _swig_p) + return +} + +func (arg1 SwigcptrVectorVectorString) Reserve(arg2 int64) { + _swig_wrap_VectorVectorString_reserve(arg1, arg2) +} + +var _wrap_VectorVectorString_isEmpty unsafe.Pointer + +func _swig_wrap_VectorVectorString_isEmpty(base SwigcptrVectorVectorString) (_ bool) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_VectorVectorString_isEmpty, _swig_p) + return +} + +func (arg1 SwigcptrVectorVectorString) IsEmpty() (_swig_ret bool) { + return _swig_wrap_VectorVectorString_isEmpty(arg1) +} + +var _wrap_VectorVectorString_clear unsafe.Pointer + +func _swig_wrap_VectorVectorString_clear(base SwigcptrVectorVectorString) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_VectorVectorString_clear, _swig_p) + return +} + +func (arg1 SwigcptrVectorVectorString) Clear() { + _swig_wrap_VectorVectorString_clear(arg1) +} + +var _wrap_VectorVectorString_add unsafe.Pointer + +func _swig_wrap_VectorVectorString_add(base SwigcptrVectorVectorString, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_VectorVectorString_add, _swig_p) + return +} + +func (arg1 SwigcptrVectorVectorString) Add(arg2 VectorString) { + _swig_wrap_VectorVectorString_add(arg1, arg2.Swigcptr()) +} + +var _wrap_VectorVectorString_get unsafe.Pointer + +func _swig_wrap_VectorVectorString_get(base SwigcptrVectorVectorString, _ int) (_ SwigcptrVectorString) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_VectorVectorString_get, _swig_p) + return +} + +func (arg1 SwigcptrVectorVectorString) Get(arg2 int) (_swig_ret VectorString) { + return _swig_wrap_VectorVectorString_get(arg1, arg2) +} + +var _wrap_VectorVectorString_set unsafe.Pointer + +func _swig_wrap_VectorVectorString_set(base SwigcptrVectorVectorString, _ int, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_VectorVectorString_set, _swig_p) + return +} + +func (arg1 SwigcptrVectorVectorString) Set(arg2 int, arg3 VectorString) { + _swig_wrap_VectorVectorString_set(arg1, arg2, arg3.Swigcptr()) +} + +var _wrap_delete_VectorVectorString unsafe.Pointer + +func _swig_wrap_delete_VectorVectorString(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_VectorVectorString, _swig_p) + return +} + +func DeleteVectorVectorString(arg1 VectorVectorString) { + _swig_wrap_delete_VectorVectorString(arg1.Swigcptr()) +} + +type VectorVectorString interface { + Swigcptr() uintptr + SwigIsVectorVectorString() + Size() (_swig_ret int64) + Capacity() (_swig_ret int64) + Reserve(arg2 int64) + IsEmpty() (_swig_ret bool) + Clear() + Add(arg2 VectorString) + Get(arg2 int) (_swig_ret VectorString) + Set(arg2 int, arg3 VectorString) +} + +type SwigcptrPairIntPairIntString uintptr + +func (p SwigcptrPairIntPairIntString) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrPairIntPairIntString) SwigIsPairIntPairIntString() { +} + +var _wrap_new_PairIntPairIntString__SWIG_0 unsafe.Pointer + +func _swig_wrap_new_PairIntPairIntString__SWIG_0() (base SwigcptrPairIntPairIntString) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_PairIntPairIntString__SWIG_0, _swig_p) + return +} + +func NewPairIntPairIntString__SWIG_0() (_swig_ret PairIntPairIntString) { + return _swig_wrap_new_PairIntPairIntString__SWIG_0() +} + +var _wrap_new_PairIntPairIntString__SWIG_1 unsafe.Pointer + +func _swig_wrap_new_PairIntPairIntString__SWIG_1(base int, _ uintptr) (_ SwigcptrPairIntPairIntString) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_PairIntPairIntString__SWIG_1, _swig_p) + return +} + +func NewPairIntPairIntString__SWIG_1(arg1 int, arg2 PairIntString) (_swig_ret PairIntPairIntString) { + return _swig_wrap_new_PairIntPairIntString__SWIG_1(arg1, arg2.Swigcptr()) +} + +var _wrap_new_PairIntPairIntString__SWIG_2 unsafe.Pointer + +func _swig_wrap_new_PairIntPairIntString__SWIG_2(base uintptr) (_ SwigcptrPairIntPairIntString) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_PairIntPairIntString__SWIG_2, _swig_p) + return +} + +func NewPairIntPairIntString__SWIG_2(arg1 PairIntPairIntString) (_swig_ret PairIntPairIntString) { + return _swig_wrap_new_PairIntPairIntString__SWIG_2(arg1.Swigcptr()) +} + +func NewPairIntPairIntString(a ...interface{}) PairIntPairIntString { + argc := len(a) + if argc == 0 { + return NewPairIntPairIntString__SWIG_0() + } + if argc == 1 { + return NewPairIntPairIntString__SWIG_2(a[0].(PairIntPairIntString)) + } + if argc == 2 { + return NewPairIntPairIntString__SWIG_1(a[0].(int), a[1].(PairIntString)) + } + panic("No match for overloaded function call") +} + +var _wrap_PairIntPairIntString_first_set unsafe.Pointer + +func _swig_wrap_PairIntPairIntString_first_set(base SwigcptrPairIntPairIntString, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_PairIntPairIntString_first_set, _swig_p) + return +} + +func (arg1 SwigcptrPairIntPairIntString) SetFirst(arg2 int) { + _swig_wrap_PairIntPairIntString_first_set(arg1, arg2) +} + +var _wrap_PairIntPairIntString_first_get unsafe.Pointer + +func _swig_wrap_PairIntPairIntString_first_get(base SwigcptrPairIntPairIntString) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_PairIntPairIntString_first_get, _swig_p) + return +} + +func (arg1 SwigcptrPairIntPairIntString) GetFirst() (_swig_ret int) { + return _swig_wrap_PairIntPairIntString_first_get(arg1) +} + +var _wrap_PairIntPairIntString_second_set unsafe.Pointer + +func _swig_wrap_PairIntPairIntString_second_set(base SwigcptrPairIntPairIntString, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_PairIntPairIntString_second_set, _swig_p) + return +} + +func (arg1 SwigcptrPairIntPairIntString) SetSecond(arg2 PairIntString) { + _swig_wrap_PairIntPairIntString_second_set(arg1, arg2.Swigcptr()) +} + +var _wrap_PairIntPairIntString_second_get unsafe.Pointer + +func _swig_wrap_PairIntPairIntString_second_get(base SwigcptrPairIntPairIntString) (_ SwigcptrPairIntString) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_PairIntPairIntString_second_get, _swig_p) + return +} + +func (arg1 SwigcptrPairIntPairIntString) GetSecond() (_swig_ret PairIntString) { + return _swig_wrap_PairIntPairIntString_second_get(arg1) +} + +var _wrap_delete_PairIntPairIntString unsafe.Pointer + +func _swig_wrap_delete_PairIntPairIntString(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_PairIntPairIntString, _swig_p) + return +} + +func DeletePairIntPairIntString(arg1 PairIntPairIntString) { + _swig_wrap_delete_PairIntPairIntString(arg1.Swigcptr()) +} + +type PairIntPairIntString interface { + Swigcptr() uintptr + SwigIsPairIntPairIntString() + SetFirst(arg2 int) + GetFirst() (_swig_ret int) + SetSecond(arg2 PairIntString) + GetSecond() (_swig_ret PairIntString) +} + +type SwigcptrPairDoubleString uintptr + +func (p SwigcptrPairDoubleString) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrPairDoubleString) SwigIsPairDoubleString() { +} + +var _wrap_new_PairDoubleString__SWIG_0 unsafe.Pointer + +func _swig_wrap_new_PairDoubleString__SWIG_0() (base SwigcptrPairDoubleString) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_PairDoubleString__SWIG_0, _swig_p) + return +} + +func NewPairDoubleString__SWIG_0() (_swig_ret PairDoubleString) { + return _swig_wrap_new_PairDoubleString__SWIG_0() +} + +var _wrap_new_PairDoubleString__SWIG_1 unsafe.Pointer + +func _swig_wrap_new_PairDoubleString__SWIG_1(base float64, _ string) (_ SwigcptrPairDoubleString) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_PairDoubleString__SWIG_1, _swig_p) + return +} + +func NewPairDoubleString__SWIG_1(arg1 float64, arg2 string) (_swig_ret PairDoubleString) { + return _swig_wrap_new_PairDoubleString__SWIG_1(arg1, arg2) +} + +var _wrap_new_PairDoubleString__SWIG_2 unsafe.Pointer + +func _swig_wrap_new_PairDoubleString__SWIG_2(base uintptr) (_ SwigcptrPairDoubleString) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_PairDoubleString__SWIG_2, _swig_p) + return +} + +func NewPairDoubleString__SWIG_2(arg1 PairDoubleString) (_swig_ret PairDoubleString) { + return _swig_wrap_new_PairDoubleString__SWIG_2(arg1.Swigcptr()) +} + +func NewPairDoubleString(a ...interface{}) PairDoubleString { + argc := len(a) + if argc == 0 { + return NewPairDoubleString__SWIG_0() + } + if argc == 1 { + return NewPairDoubleString__SWIG_2(a[0].(PairDoubleString)) + } + if argc == 2 { + return NewPairDoubleString__SWIG_1(a[0].(float64), a[1].(string)) + } + panic("No match for overloaded function call") +} + +var _wrap_PairDoubleString_first_set unsafe.Pointer + +func _swig_wrap_PairDoubleString_first_set(base SwigcptrPairDoubleString, _ float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_PairDoubleString_first_set, _swig_p) + return +} + +func (arg1 SwigcptrPairDoubleString) SetFirst(arg2 float64) { + _swig_wrap_PairDoubleString_first_set(arg1, arg2) +} + +var _wrap_PairDoubleString_first_get unsafe.Pointer + +func _swig_wrap_PairDoubleString_first_get(base SwigcptrPairDoubleString) (_ float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_PairDoubleString_first_get, _swig_p) + return +} + +func (arg1 SwigcptrPairDoubleString) GetFirst() (_swig_ret float64) { + return _swig_wrap_PairDoubleString_first_get(arg1) +} + +var _wrap_PairDoubleString_second_set unsafe.Pointer + +func _swig_wrap_PairDoubleString_second_set(base SwigcptrPairDoubleString, _ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_PairDoubleString_second_set, _swig_p) + return +} + +func (arg1 SwigcptrPairDoubleString) SetSecond(arg2 string) { + _swig_wrap_PairDoubleString_second_set(arg1, arg2) +} + +var _wrap_PairDoubleString_second_get unsafe.Pointer + +func _swig_wrap_PairDoubleString_second_get(base SwigcptrPairDoubleString) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_PairDoubleString_second_get, _swig_p) + return +} + +func (arg1 SwigcptrPairDoubleString) GetSecond() (_swig_ret string) { + return _swig_wrap_PairDoubleString_second_get(arg1) +} + +var _wrap_delete_PairDoubleString unsafe.Pointer + +func _swig_wrap_delete_PairDoubleString(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_PairDoubleString, _swig_p) + return +} + +func DeletePairDoubleString(arg1 PairDoubleString) { + _swig_wrap_delete_PairDoubleString(arg1.Swigcptr()) +} + +type PairDoubleString interface { + Swigcptr() uintptr + SwigIsPairDoubleString() + SetFirst(arg2 float64) + GetFirst() (_swig_ret float64) + SetSecond(arg2 string) + GetSecond() (_swig_ret string) +} + +type SwigcptrVectorPairDoubleString uintptr + +func (p SwigcptrVectorPairDoubleString) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrVectorPairDoubleString) SwigIsVectorPairDoubleString() { +} + +var _wrap_new_VectorPairDoubleString__SWIG_0 unsafe.Pointer + +func _swig_wrap_new_VectorPairDoubleString__SWIG_0() (base SwigcptrVectorPairDoubleString) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_VectorPairDoubleString__SWIG_0, _swig_p) + return +} + +func NewVectorPairDoubleString__SWIG_0() (_swig_ret VectorPairDoubleString) { + return _swig_wrap_new_VectorPairDoubleString__SWIG_0() +} + +var _wrap_new_VectorPairDoubleString__SWIG_1 unsafe.Pointer + +func _swig_wrap_new_VectorPairDoubleString__SWIG_1(base int64) (_ SwigcptrVectorPairDoubleString) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_VectorPairDoubleString__SWIG_1, _swig_p) + return +} + +func NewVectorPairDoubleString__SWIG_1(arg1 int64) (_swig_ret VectorPairDoubleString) { + return _swig_wrap_new_VectorPairDoubleString__SWIG_1(arg1) +} + +func NewVectorPairDoubleString(a ...interface{}) VectorPairDoubleString { + argc := len(a) + if argc == 0 { + return NewVectorPairDoubleString__SWIG_0() + } + if argc == 1 { + return NewVectorPairDoubleString__SWIG_1(a[0].(int64)) + } + panic("No match for overloaded function call") +} + +var _wrap_VectorPairDoubleString_size unsafe.Pointer + +func _swig_wrap_VectorPairDoubleString_size(base SwigcptrVectorPairDoubleString) (_ int64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_VectorPairDoubleString_size, _swig_p) + return +} + +func (arg1 SwigcptrVectorPairDoubleString) Size() (_swig_ret int64) { + return _swig_wrap_VectorPairDoubleString_size(arg1) +} + +var _wrap_VectorPairDoubleString_capacity unsafe.Pointer + +func _swig_wrap_VectorPairDoubleString_capacity(base SwigcptrVectorPairDoubleString) (_ int64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_VectorPairDoubleString_capacity, _swig_p) + return +} + +func (arg1 SwigcptrVectorPairDoubleString) Capacity() (_swig_ret int64) { + return _swig_wrap_VectorPairDoubleString_capacity(arg1) +} + +var _wrap_VectorPairDoubleString_reserve unsafe.Pointer + +func _swig_wrap_VectorPairDoubleString_reserve(base SwigcptrVectorPairDoubleString, _ int64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_VectorPairDoubleString_reserve, _swig_p) + return +} + +func (arg1 SwigcptrVectorPairDoubleString) Reserve(arg2 int64) { + _swig_wrap_VectorPairDoubleString_reserve(arg1, arg2) +} + +var _wrap_VectorPairDoubleString_isEmpty unsafe.Pointer + +func _swig_wrap_VectorPairDoubleString_isEmpty(base SwigcptrVectorPairDoubleString) (_ bool) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_VectorPairDoubleString_isEmpty, _swig_p) + return +} + +func (arg1 SwigcptrVectorPairDoubleString) IsEmpty() (_swig_ret bool) { + return _swig_wrap_VectorPairDoubleString_isEmpty(arg1) +} + +var _wrap_VectorPairDoubleString_clear unsafe.Pointer + +func _swig_wrap_VectorPairDoubleString_clear(base SwigcptrVectorPairDoubleString) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_VectorPairDoubleString_clear, _swig_p) + return +} + +func (arg1 SwigcptrVectorPairDoubleString) Clear() { + _swig_wrap_VectorPairDoubleString_clear(arg1) +} + +var _wrap_VectorPairDoubleString_add unsafe.Pointer + +func _swig_wrap_VectorPairDoubleString_add(base SwigcptrVectorPairDoubleString, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_VectorPairDoubleString_add, _swig_p) + return +} + +func (arg1 SwigcptrVectorPairDoubleString) Add(arg2 PairDoubleString) { + _swig_wrap_VectorPairDoubleString_add(arg1, arg2.Swigcptr()) +} + +var _wrap_VectorPairDoubleString_get unsafe.Pointer + +func _swig_wrap_VectorPairDoubleString_get(base SwigcptrVectorPairDoubleString, _ int) (_ SwigcptrPairDoubleString) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_VectorPairDoubleString_get, _swig_p) + return +} + +func (arg1 SwigcptrVectorPairDoubleString) Get(arg2 int) (_swig_ret PairDoubleString) { + return _swig_wrap_VectorPairDoubleString_get(arg1, arg2) +} + +var _wrap_VectorPairDoubleString_set unsafe.Pointer + +func _swig_wrap_VectorPairDoubleString_set(base SwigcptrVectorPairDoubleString, _ int, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_VectorPairDoubleString_set, _swig_p) + return +} + +func (arg1 SwigcptrVectorPairDoubleString) Set(arg2 int, arg3 PairDoubleString) { + _swig_wrap_VectorPairDoubleString_set(arg1, arg2, arg3.Swigcptr()) +} + +var _wrap_delete_VectorPairDoubleString unsafe.Pointer + +func _swig_wrap_delete_VectorPairDoubleString(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_VectorPairDoubleString, _swig_p) + return +} + +func DeleteVectorPairDoubleString(arg1 VectorPairDoubleString) { + _swig_wrap_delete_VectorPairDoubleString(arg1.Swigcptr()) +} + +type VectorPairDoubleString interface { + Swigcptr() uintptr + SwigIsVectorPairDoubleString() + Size() (_swig_ret int64) + Capacity() (_swig_ret int64) + Reserve(arg2 int64) + IsEmpty() (_swig_ret bool) + Clear() + Add(arg2 PairDoubleString) + Get(arg2 int) (_swig_ret PairDoubleString) + Set(arg2 int, arg3 PairDoubleString) +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/li_std_deque.go b/Examples/test-suite/go/li_std_deque.go new file mode 100644 index 000000000..21aef968e --- /dev/null +++ b/Examples/test-suite/go/li_std_deque.go @@ -0,0 +1,1174 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../li_std_deque.i + +package li_std_deque + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrIntDeque uintptr + +func (p SwigcptrIntDeque) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrIntDeque) SwigIsIntDeque() { +} + +var _wrap_IntDeque_empty unsafe.Pointer + +func _swig_wrap_IntDeque_empty(base SwigcptrIntDeque) (_ bool) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_IntDeque_empty, _swig_p) + return +} + +func (arg1 SwigcptrIntDeque) Empty() (_swig_ret bool) { + return _swig_wrap_IntDeque_empty(arg1) +} + +var _wrap_new_IntDeque__SWIG_0 unsafe.Pointer + +func _swig_wrap_new_IntDeque__SWIG_0() (base SwigcptrIntDeque) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_IntDeque__SWIG_0, _swig_p) + return +} + +func NewIntDeque__SWIG_0() (_swig_ret IntDeque) { + return _swig_wrap_new_IntDeque__SWIG_0() +} + +var _wrap_new_IntDeque__SWIG_1 unsafe.Pointer + +func _swig_wrap_new_IntDeque__SWIG_1(base uint, _ int) (_ SwigcptrIntDeque) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_IntDeque__SWIG_1, _swig_p) + return +} + +func NewIntDeque__SWIG_1(arg1 uint, arg2 int) (_swig_ret IntDeque) { + return _swig_wrap_new_IntDeque__SWIG_1(arg1, arg2) +} + +var _wrap_new_IntDeque__SWIG_2 unsafe.Pointer + +func _swig_wrap_new_IntDeque__SWIG_2(base uint) (_ SwigcptrIntDeque) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_IntDeque__SWIG_2, _swig_p) + return +} + +func NewIntDeque__SWIG_2(arg1 uint) (_swig_ret IntDeque) { + return _swig_wrap_new_IntDeque__SWIG_2(arg1) +} + +var _wrap_new_IntDeque__SWIG_3 unsafe.Pointer + +func _swig_wrap_new_IntDeque__SWIG_3(base uintptr) (_ SwigcptrIntDeque) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_IntDeque__SWIG_3, _swig_p) + return +} + +func NewIntDeque__SWIG_3(arg1 IntDeque) (_swig_ret IntDeque) { + return _swig_wrap_new_IntDeque__SWIG_3(arg1.Swigcptr()) +} + +func NewIntDeque(a ...interface{}) IntDeque { + argc := len(a) + if argc == 0 { + return NewIntDeque__SWIG_0() + } + if argc == 1 { + if _, ok := a[0].(IntDeque); !ok { + goto check_2 + } + return NewIntDeque__SWIG_3(a[0].(IntDeque)) + } +check_2: + if argc == 1 { + return NewIntDeque__SWIG_2(a[0].(uint)) + } + if argc == 2 { + return NewIntDeque__SWIG_1(a[0].(uint), a[1].(int)) + } + panic("No match for overloaded function call") +} + +var _wrap_delete_IntDeque unsafe.Pointer + +func _swig_wrap_delete_IntDeque(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_IntDeque, _swig_p) + return +} + +func DeleteIntDeque(arg1 IntDeque) { + _swig_wrap_delete_IntDeque(arg1.Swigcptr()) +} + +var _wrap_IntDeque_assign unsafe.Pointer + +func _swig_wrap_IntDeque_assign(base SwigcptrIntDeque, _ uint, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_IntDeque_assign, _swig_p) + return +} + +func (arg1 SwigcptrIntDeque) Assign(arg2 uint, arg3 int) { + _swig_wrap_IntDeque_assign(arg1, arg2, arg3) +} + +var _wrap_IntDeque_swap unsafe.Pointer + +func _swig_wrap_IntDeque_swap(base SwigcptrIntDeque, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_IntDeque_swap, _swig_p) + return +} + +func (arg1 SwigcptrIntDeque) Swap(arg2 IntDeque) { + _swig_wrap_IntDeque_swap(arg1, arg2.Swigcptr()) +} + +var _wrap_IntDeque_size unsafe.Pointer + +func _swig_wrap_IntDeque_size(base SwigcptrIntDeque) (_ uint) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_IntDeque_size, _swig_p) + return +} + +func (arg1 SwigcptrIntDeque) Size() (_swig_ret uint) { + return _swig_wrap_IntDeque_size(arg1) +} + +var _wrap_IntDeque_max_size unsafe.Pointer + +func _swig_wrap_IntDeque_max_size(base SwigcptrIntDeque) (_ uint) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_IntDeque_max_size, _swig_p) + return +} + +func (arg1 SwigcptrIntDeque) Max_size() (_swig_ret uint) { + return _swig_wrap_IntDeque_max_size(arg1) +} + +var _wrap_IntDeque_resize__SWIG_0 unsafe.Pointer + +func _swig_wrap_IntDeque_resize__SWIG_0(base SwigcptrIntDeque, _ uint, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_IntDeque_resize__SWIG_0, _swig_p) + return +} + +func (arg1 SwigcptrIntDeque) Resize__SWIG_0(arg2 uint, arg3 int) { + _swig_wrap_IntDeque_resize__SWIG_0(arg1, arg2, arg3) +} + +var _wrap_IntDeque_resize__SWIG_1 unsafe.Pointer + +func _swig_wrap_IntDeque_resize__SWIG_1(base SwigcptrIntDeque, _ uint) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_IntDeque_resize__SWIG_1, _swig_p) + return +} + +func (arg1 SwigcptrIntDeque) Resize__SWIG_1(arg2 uint) { + _swig_wrap_IntDeque_resize__SWIG_1(arg1, arg2) +} + +func (p SwigcptrIntDeque) Resize(a ...interface{}) { + argc := len(a) + if argc == 1 { + p.Resize__SWIG_1(a[0].(uint)) + return + } + if argc == 2 { + p.Resize__SWIG_0(a[0].(uint), a[1].(int)) + return + } + panic("No match for overloaded function call") +} + +var _wrap_IntDeque_front unsafe.Pointer + +func _swig_wrap_IntDeque_front(base SwigcptrIntDeque) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_IntDeque_front, _swig_p) + return +} + +func (arg1 SwigcptrIntDeque) Front() (_swig_ret int) { + return _swig_wrap_IntDeque_front(arg1) +} + +var _wrap_IntDeque_back unsafe.Pointer + +func _swig_wrap_IntDeque_back(base SwigcptrIntDeque) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_IntDeque_back, _swig_p) + return +} + +func (arg1 SwigcptrIntDeque) Back() (_swig_ret int) { + return _swig_wrap_IntDeque_back(arg1) +} + +var _wrap_IntDeque_push_front unsafe.Pointer + +func _swig_wrap_IntDeque_push_front(base SwigcptrIntDeque, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_IntDeque_push_front, _swig_p) + return +} + +func (arg1 SwigcptrIntDeque) Push_front(arg2 int) { + _swig_wrap_IntDeque_push_front(arg1, arg2) +} + +var _wrap_IntDeque_push_back unsafe.Pointer + +func _swig_wrap_IntDeque_push_back(base SwigcptrIntDeque, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_IntDeque_push_back, _swig_p) + return +} + +func (arg1 SwigcptrIntDeque) Push_back(arg2 int) { + _swig_wrap_IntDeque_push_back(arg1, arg2) +} + +var _wrap_IntDeque_pop_front unsafe.Pointer + +func _swig_wrap_IntDeque_pop_front(base SwigcptrIntDeque) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_IntDeque_pop_front, _swig_p) + return +} + +func (arg1 SwigcptrIntDeque) Pop_front() { + _swig_wrap_IntDeque_pop_front(arg1) +} + +var _wrap_IntDeque_pop_back unsafe.Pointer + +func _swig_wrap_IntDeque_pop_back(base SwigcptrIntDeque) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_IntDeque_pop_back, _swig_p) + return +} + +func (arg1 SwigcptrIntDeque) Pop_back() { + _swig_wrap_IntDeque_pop_back(arg1) +} + +var _wrap_IntDeque_clear unsafe.Pointer + +func _swig_wrap_IntDeque_clear(base SwigcptrIntDeque) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_IntDeque_clear, _swig_p) + return +} + +func (arg1 SwigcptrIntDeque) Clear() { + _swig_wrap_IntDeque_clear(arg1) +} + +var _wrap_IntDeque_getitem unsafe.Pointer + +func _swig_wrap_IntDeque_getitem(base SwigcptrIntDeque, _ int) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_IntDeque_getitem, _swig_p) + return +} + +func (arg1 SwigcptrIntDeque) Getitem(arg2 int) (_swig_ret int) { + return _swig_wrap_IntDeque_getitem(arg1, arg2) +} + +var _wrap_IntDeque_setitem unsafe.Pointer + +func _swig_wrap_IntDeque_setitem(base SwigcptrIntDeque, _ int, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_IntDeque_setitem, _swig_p) + return +} + +func (arg1 SwigcptrIntDeque) Setitem(arg2 int, arg3 int) { + _swig_wrap_IntDeque_setitem(arg1, arg2, arg3) +} + +var _wrap_IntDeque_delitem unsafe.Pointer + +func _swig_wrap_IntDeque_delitem(base SwigcptrIntDeque, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_IntDeque_delitem, _swig_p) + return +} + +func (arg1 SwigcptrIntDeque) Delitem(arg2 int) { + _swig_wrap_IntDeque_delitem(arg1, arg2) +} + +var _wrap_IntDeque_getslice unsafe.Pointer + +func _swig_wrap_IntDeque_getslice(base SwigcptrIntDeque, _ int, _ int) (_ SwigcptrIntDeque) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_IntDeque_getslice, _swig_p) + return +} + +func (arg1 SwigcptrIntDeque) Getslice(arg2 int, arg3 int) (_swig_ret IntDeque) { + return _swig_wrap_IntDeque_getslice(arg1, arg2, arg3) +} + +var _wrap_IntDeque_setslice unsafe.Pointer + +func _swig_wrap_IntDeque_setslice(base SwigcptrIntDeque, _ int, _ int, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_IntDeque_setslice, _swig_p) + return +} + +func (arg1 SwigcptrIntDeque) Setslice(arg2 int, arg3 int, arg4 IntDeque) { + _swig_wrap_IntDeque_setslice(arg1, arg2, arg3, arg4.Swigcptr()) +} + +var _wrap_IntDeque_delslice unsafe.Pointer + +func _swig_wrap_IntDeque_delslice(base SwigcptrIntDeque, _ int, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_IntDeque_delslice, _swig_p) + return +} + +func (arg1 SwigcptrIntDeque) Delslice(arg2 int, arg3 int) { + _swig_wrap_IntDeque_delslice(arg1, arg2, arg3) +} + +type IntDeque interface { + Swigcptr() uintptr + SwigIsIntDeque() + Empty() (_swig_ret bool) + Assign(arg2 uint, arg3 int) + Swap(arg2 IntDeque) + Size() (_swig_ret uint) + Max_size() (_swig_ret uint) + Resize(a ...interface{}) + Front() (_swig_ret int) + Back() (_swig_ret int) + Push_front(arg2 int) + Push_back(arg2 int) + Pop_front() + Pop_back() + Clear() + Getitem(arg2 int) (_swig_ret int) + Setitem(arg2 int, arg3 int) + Delitem(arg2 int) + Getslice(arg2 int, arg3 int) (_swig_ret IntDeque) + Setslice(arg2 int, arg3 int, arg4 IntDeque) + Delslice(arg2 int, arg3 int) +} + +type SwigcptrDoubleDeque uintptr + +func (p SwigcptrDoubleDeque) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrDoubleDeque) SwigIsDoubleDeque() { +} + +var _wrap_DoubleDeque_empty unsafe.Pointer + +func _swig_wrap_DoubleDeque_empty(base SwigcptrDoubleDeque) (_ bool) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_DoubleDeque_empty, _swig_p) + return +} + +func (arg1 SwigcptrDoubleDeque) Empty() (_swig_ret bool) { + return _swig_wrap_DoubleDeque_empty(arg1) +} + +var _wrap_new_DoubleDeque__SWIG_0 unsafe.Pointer + +func _swig_wrap_new_DoubleDeque__SWIG_0() (base SwigcptrDoubleDeque) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_DoubleDeque__SWIG_0, _swig_p) + return +} + +func NewDoubleDeque__SWIG_0() (_swig_ret DoubleDeque) { + return _swig_wrap_new_DoubleDeque__SWIG_0() +} + +var _wrap_new_DoubleDeque__SWIG_1 unsafe.Pointer + +func _swig_wrap_new_DoubleDeque__SWIG_1(base uint, _ float64) (_ SwigcptrDoubleDeque) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_DoubleDeque__SWIG_1, _swig_p) + return +} + +func NewDoubleDeque__SWIG_1(arg1 uint, arg2 float64) (_swig_ret DoubleDeque) { + return _swig_wrap_new_DoubleDeque__SWIG_1(arg1, arg2) +} + +var _wrap_new_DoubleDeque__SWIG_2 unsafe.Pointer + +func _swig_wrap_new_DoubleDeque__SWIG_2(base uint) (_ SwigcptrDoubleDeque) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_DoubleDeque__SWIG_2, _swig_p) + return +} + +func NewDoubleDeque__SWIG_2(arg1 uint) (_swig_ret DoubleDeque) { + return _swig_wrap_new_DoubleDeque__SWIG_2(arg1) +} + +var _wrap_new_DoubleDeque__SWIG_3 unsafe.Pointer + +func _swig_wrap_new_DoubleDeque__SWIG_3(base uintptr) (_ SwigcptrDoubleDeque) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_DoubleDeque__SWIG_3, _swig_p) + return +} + +func NewDoubleDeque__SWIG_3(arg1 DoubleDeque) (_swig_ret DoubleDeque) { + return _swig_wrap_new_DoubleDeque__SWIG_3(arg1.Swigcptr()) +} + +func NewDoubleDeque(a ...interface{}) DoubleDeque { + argc := len(a) + if argc == 0 { + return NewDoubleDeque__SWIG_0() + } + if argc == 1 { + if _, ok := a[0].(DoubleDeque); !ok { + goto check_2 + } + return NewDoubleDeque__SWIG_3(a[0].(DoubleDeque)) + } +check_2: + if argc == 1 { + return NewDoubleDeque__SWIG_2(a[0].(uint)) + } + if argc == 2 { + return NewDoubleDeque__SWIG_1(a[0].(uint), a[1].(float64)) + } + panic("No match for overloaded function call") +} + +var _wrap_delete_DoubleDeque unsafe.Pointer + +func _swig_wrap_delete_DoubleDeque(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_DoubleDeque, _swig_p) + return +} + +func DeleteDoubleDeque(arg1 DoubleDeque) { + _swig_wrap_delete_DoubleDeque(arg1.Swigcptr()) +} + +var _wrap_DoubleDeque_assign unsafe.Pointer + +func _swig_wrap_DoubleDeque_assign(base SwigcptrDoubleDeque, _ uint, _ float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_DoubleDeque_assign, _swig_p) + return +} + +func (arg1 SwigcptrDoubleDeque) Assign(arg2 uint, arg3 float64) { + _swig_wrap_DoubleDeque_assign(arg1, arg2, arg3) +} + +var _wrap_DoubleDeque_swap unsafe.Pointer + +func _swig_wrap_DoubleDeque_swap(base SwigcptrDoubleDeque, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_DoubleDeque_swap, _swig_p) + return +} + +func (arg1 SwigcptrDoubleDeque) Swap(arg2 DoubleDeque) { + _swig_wrap_DoubleDeque_swap(arg1, arg2.Swigcptr()) +} + +var _wrap_DoubleDeque_size unsafe.Pointer + +func _swig_wrap_DoubleDeque_size(base SwigcptrDoubleDeque) (_ uint) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_DoubleDeque_size, _swig_p) + return +} + +func (arg1 SwigcptrDoubleDeque) Size() (_swig_ret uint) { + return _swig_wrap_DoubleDeque_size(arg1) +} + +var _wrap_DoubleDeque_max_size unsafe.Pointer + +func _swig_wrap_DoubleDeque_max_size(base SwigcptrDoubleDeque) (_ uint) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_DoubleDeque_max_size, _swig_p) + return +} + +func (arg1 SwigcptrDoubleDeque) Max_size() (_swig_ret uint) { + return _swig_wrap_DoubleDeque_max_size(arg1) +} + +var _wrap_DoubleDeque_resize__SWIG_0 unsafe.Pointer + +func _swig_wrap_DoubleDeque_resize__SWIG_0(base SwigcptrDoubleDeque, _ uint, _ float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_DoubleDeque_resize__SWIG_0, _swig_p) + return +} + +func (arg1 SwigcptrDoubleDeque) Resize__SWIG_0(arg2 uint, arg3 float64) { + _swig_wrap_DoubleDeque_resize__SWIG_0(arg1, arg2, arg3) +} + +var _wrap_DoubleDeque_resize__SWIG_1 unsafe.Pointer + +func _swig_wrap_DoubleDeque_resize__SWIG_1(base SwigcptrDoubleDeque, _ uint) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_DoubleDeque_resize__SWIG_1, _swig_p) + return +} + +func (arg1 SwigcptrDoubleDeque) Resize__SWIG_1(arg2 uint) { + _swig_wrap_DoubleDeque_resize__SWIG_1(arg1, arg2) +} + +func (p SwigcptrDoubleDeque) Resize(a ...interface{}) { + argc := len(a) + if argc == 1 { + p.Resize__SWIG_1(a[0].(uint)) + return + } + if argc == 2 { + p.Resize__SWIG_0(a[0].(uint), a[1].(float64)) + return + } + panic("No match for overloaded function call") +} + +var _wrap_DoubleDeque_front unsafe.Pointer + +func _swig_wrap_DoubleDeque_front(base SwigcptrDoubleDeque) (_ float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_DoubleDeque_front, _swig_p) + return +} + +func (arg1 SwigcptrDoubleDeque) Front() (_swig_ret float64) { + return _swig_wrap_DoubleDeque_front(arg1) +} + +var _wrap_DoubleDeque_back unsafe.Pointer + +func _swig_wrap_DoubleDeque_back(base SwigcptrDoubleDeque) (_ float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_DoubleDeque_back, _swig_p) + return +} + +func (arg1 SwigcptrDoubleDeque) Back() (_swig_ret float64) { + return _swig_wrap_DoubleDeque_back(arg1) +} + +var _wrap_DoubleDeque_push_front unsafe.Pointer + +func _swig_wrap_DoubleDeque_push_front(base SwigcptrDoubleDeque, _ float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_DoubleDeque_push_front, _swig_p) + return +} + +func (arg1 SwigcptrDoubleDeque) Push_front(arg2 float64) { + _swig_wrap_DoubleDeque_push_front(arg1, arg2) +} + +var _wrap_DoubleDeque_push_back unsafe.Pointer + +func _swig_wrap_DoubleDeque_push_back(base SwigcptrDoubleDeque, _ float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_DoubleDeque_push_back, _swig_p) + return +} + +func (arg1 SwigcptrDoubleDeque) Push_back(arg2 float64) { + _swig_wrap_DoubleDeque_push_back(arg1, arg2) +} + +var _wrap_DoubleDeque_pop_front unsafe.Pointer + +func _swig_wrap_DoubleDeque_pop_front(base SwigcptrDoubleDeque) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_DoubleDeque_pop_front, _swig_p) + return +} + +func (arg1 SwigcptrDoubleDeque) Pop_front() { + _swig_wrap_DoubleDeque_pop_front(arg1) +} + +var _wrap_DoubleDeque_pop_back unsafe.Pointer + +func _swig_wrap_DoubleDeque_pop_back(base SwigcptrDoubleDeque) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_DoubleDeque_pop_back, _swig_p) + return +} + +func (arg1 SwigcptrDoubleDeque) Pop_back() { + _swig_wrap_DoubleDeque_pop_back(arg1) +} + +var _wrap_DoubleDeque_clear unsafe.Pointer + +func _swig_wrap_DoubleDeque_clear(base SwigcptrDoubleDeque) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_DoubleDeque_clear, _swig_p) + return +} + +func (arg1 SwigcptrDoubleDeque) Clear() { + _swig_wrap_DoubleDeque_clear(arg1) +} + +var _wrap_DoubleDeque_getitem unsafe.Pointer + +func _swig_wrap_DoubleDeque_getitem(base SwigcptrDoubleDeque, _ int) (_ float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_DoubleDeque_getitem, _swig_p) + return +} + +func (arg1 SwigcptrDoubleDeque) Getitem(arg2 int) (_swig_ret float64) { + return _swig_wrap_DoubleDeque_getitem(arg1, arg2) +} + +var _wrap_DoubleDeque_setitem unsafe.Pointer + +func _swig_wrap_DoubleDeque_setitem(base SwigcptrDoubleDeque, _ int, _ float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_DoubleDeque_setitem, _swig_p) + return +} + +func (arg1 SwigcptrDoubleDeque) Setitem(arg2 int, arg3 float64) { + _swig_wrap_DoubleDeque_setitem(arg1, arg2, arg3) +} + +var _wrap_DoubleDeque_delitem unsafe.Pointer + +func _swig_wrap_DoubleDeque_delitem(base SwigcptrDoubleDeque, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_DoubleDeque_delitem, _swig_p) + return +} + +func (arg1 SwigcptrDoubleDeque) Delitem(arg2 int) { + _swig_wrap_DoubleDeque_delitem(arg1, arg2) +} + +var _wrap_DoubleDeque_getslice unsafe.Pointer + +func _swig_wrap_DoubleDeque_getslice(base SwigcptrDoubleDeque, _ int, _ int) (_ SwigcptrDoubleDeque) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_DoubleDeque_getslice, _swig_p) + return +} + +func (arg1 SwigcptrDoubleDeque) Getslice(arg2 int, arg3 int) (_swig_ret DoubleDeque) { + return _swig_wrap_DoubleDeque_getslice(arg1, arg2, arg3) +} + +var _wrap_DoubleDeque_setslice unsafe.Pointer + +func _swig_wrap_DoubleDeque_setslice(base SwigcptrDoubleDeque, _ int, _ int, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_DoubleDeque_setslice, _swig_p) + return +} + +func (arg1 SwigcptrDoubleDeque) Setslice(arg2 int, arg3 int, arg4 DoubleDeque) { + _swig_wrap_DoubleDeque_setslice(arg1, arg2, arg3, arg4.Swigcptr()) +} + +var _wrap_DoubleDeque_delslice unsafe.Pointer + +func _swig_wrap_DoubleDeque_delslice(base SwigcptrDoubleDeque, _ int, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_DoubleDeque_delslice, _swig_p) + return +} + +func (arg1 SwigcptrDoubleDeque) Delslice(arg2 int, arg3 int) { + _swig_wrap_DoubleDeque_delslice(arg1, arg2, arg3) +} + +type DoubleDeque interface { + Swigcptr() uintptr + SwigIsDoubleDeque() + Empty() (_swig_ret bool) + Assign(arg2 uint, arg3 float64) + Swap(arg2 DoubleDeque) + Size() (_swig_ret uint) + Max_size() (_swig_ret uint) + Resize(a ...interface{}) + Front() (_swig_ret float64) + Back() (_swig_ret float64) + Push_front(arg2 float64) + Push_back(arg2 float64) + Pop_front() + Pop_back() + Clear() + Getitem(arg2 int) (_swig_ret float64) + Setitem(arg2 int, arg3 float64) + Delitem(arg2 int) + Getslice(arg2 int, arg3 int) (_swig_ret DoubleDeque) + Setslice(arg2 int, arg3 int, arg4 DoubleDeque) + Delslice(arg2 int, arg3 int) +} + +type SwigcptrRealDeque uintptr + +func (p SwigcptrRealDeque) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrRealDeque) SwigIsRealDeque() { +} + +var _wrap_RealDeque_empty unsafe.Pointer + +func _swig_wrap_RealDeque_empty(base SwigcptrRealDeque) (_ bool) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_RealDeque_empty, _swig_p) + return +} + +func (arg1 SwigcptrRealDeque) Empty() (_swig_ret bool) { + return _swig_wrap_RealDeque_empty(arg1) +} + +var _wrap_new_RealDeque__SWIG_0 unsafe.Pointer + +func _swig_wrap_new_RealDeque__SWIG_0() (base SwigcptrRealDeque) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_RealDeque__SWIG_0, _swig_p) + return +} + +func NewRealDeque__SWIG_0() (_swig_ret RealDeque) { + return _swig_wrap_new_RealDeque__SWIG_0() +} + +var _wrap_new_RealDeque__SWIG_1 unsafe.Pointer + +func _swig_wrap_new_RealDeque__SWIG_1(base uint, _ float32) (_ SwigcptrRealDeque) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_RealDeque__SWIG_1, _swig_p) + return +} + +func NewRealDeque__SWIG_1(arg1 uint, arg2 float32) (_swig_ret RealDeque) { + return _swig_wrap_new_RealDeque__SWIG_1(arg1, arg2) +} + +var _wrap_new_RealDeque__SWIG_2 unsafe.Pointer + +func _swig_wrap_new_RealDeque__SWIG_2(base uint) (_ SwigcptrRealDeque) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_RealDeque__SWIG_2, _swig_p) + return +} + +func NewRealDeque__SWIG_2(arg1 uint) (_swig_ret RealDeque) { + return _swig_wrap_new_RealDeque__SWIG_2(arg1) +} + +var _wrap_new_RealDeque__SWIG_3 unsafe.Pointer + +func _swig_wrap_new_RealDeque__SWIG_3(base uintptr) (_ SwigcptrRealDeque) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_RealDeque__SWIG_3, _swig_p) + return +} + +func NewRealDeque__SWIG_3(arg1 RealDeque) (_swig_ret RealDeque) { + return _swig_wrap_new_RealDeque__SWIG_3(arg1.Swigcptr()) +} + +func NewRealDeque(a ...interface{}) RealDeque { + argc := len(a) + if argc == 0 { + return NewRealDeque__SWIG_0() + } + if argc == 1 { + if _, ok := a[0].(RealDeque); !ok { + goto check_2 + } + return NewRealDeque__SWIG_3(a[0].(RealDeque)) + } +check_2: + if argc == 1 { + return NewRealDeque__SWIG_2(a[0].(uint)) + } + if argc == 2 { + return NewRealDeque__SWIG_1(a[0].(uint), a[1].(float32)) + } + panic("No match for overloaded function call") +} + +var _wrap_delete_RealDeque unsafe.Pointer + +func _swig_wrap_delete_RealDeque(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_RealDeque, _swig_p) + return +} + +func DeleteRealDeque(arg1 RealDeque) { + _swig_wrap_delete_RealDeque(arg1.Swigcptr()) +} + +var _wrap_RealDeque_assign unsafe.Pointer + +func _swig_wrap_RealDeque_assign(base SwigcptrRealDeque, _ uint, _ float32) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_RealDeque_assign, _swig_p) + return +} + +func (arg1 SwigcptrRealDeque) Assign(arg2 uint, arg3 float32) { + _swig_wrap_RealDeque_assign(arg1, arg2, arg3) +} + +var _wrap_RealDeque_swap unsafe.Pointer + +func _swig_wrap_RealDeque_swap(base SwigcptrRealDeque, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_RealDeque_swap, _swig_p) + return +} + +func (arg1 SwigcptrRealDeque) Swap(arg2 RealDeque) { + _swig_wrap_RealDeque_swap(arg1, arg2.Swigcptr()) +} + +var _wrap_RealDeque_size unsafe.Pointer + +func _swig_wrap_RealDeque_size(base SwigcptrRealDeque) (_ uint) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_RealDeque_size, _swig_p) + return +} + +func (arg1 SwigcptrRealDeque) Size() (_swig_ret uint) { + return _swig_wrap_RealDeque_size(arg1) +} + +var _wrap_RealDeque_max_size unsafe.Pointer + +func _swig_wrap_RealDeque_max_size(base SwigcptrRealDeque) (_ uint) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_RealDeque_max_size, _swig_p) + return +} + +func (arg1 SwigcptrRealDeque) Max_size() (_swig_ret uint) { + return _swig_wrap_RealDeque_max_size(arg1) +} + +var _wrap_RealDeque_resize__SWIG_0 unsafe.Pointer + +func _swig_wrap_RealDeque_resize__SWIG_0(base SwigcptrRealDeque, _ uint, _ float32) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_RealDeque_resize__SWIG_0, _swig_p) + return +} + +func (arg1 SwigcptrRealDeque) Resize__SWIG_0(arg2 uint, arg3 float32) { + _swig_wrap_RealDeque_resize__SWIG_0(arg1, arg2, arg3) +} + +var _wrap_RealDeque_resize__SWIG_1 unsafe.Pointer + +func _swig_wrap_RealDeque_resize__SWIG_1(base SwigcptrRealDeque, _ uint) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_RealDeque_resize__SWIG_1, _swig_p) + return +} + +func (arg1 SwigcptrRealDeque) Resize__SWIG_1(arg2 uint) { + _swig_wrap_RealDeque_resize__SWIG_1(arg1, arg2) +} + +func (p SwigcptrRealDeque) Resize(a ...interface{}) { + argc := len(a) + if argc == 1 { + p.Resize__SWIG_1(a[0].(uint)) + return + } + if argc == 2 { + p.Resize__SWIG_0(a[0].(uint), a[1].(float32)) + return + } + panic("No match for overloaded function call") +} + +var _wrap_RealDeque_front unsafe.Pointer + +func _swig_wrap_RealDeque_front(base SwigcptrRealDeque) (_ float32) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_RealDeque_front, _swig_p) + return +} + +func (arg1 SwigcptrRealDeque) Front() (_swig_ret float32) { + return _swig_wrap_RealDeque_front(arg1) +} + +var _wrap_RealDeque_back unsafe.Pointer + +func _swig_wrap_RealDeque_back(base SwigcptrRealDeque) (_ float32) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_RealDeque_back, _swig_p) + return +} + +func (arg1 SwigcptrRealDeque) Back() (_swig_ret float32) { + return _swig_wrap_RealDeque_back(arg1) +} + +var _wrap_RealDeque_push_front unsafe.Pointer + +func _swig_wrap_RealDeque_push_front(base SwigcptrRealDeque, _ float32) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_RealDeque_push_front, _swig_p) + return +} + +func (arg1 SwigcptrRealDeque) Push_front(arg2 float32) { + _swig_wrap_RealDeque_push_front(arg1, arg2) +} + +var _wrap_RealDeque_push_back unsafe.Pointer + +func _swig_wrap_RealDeque_push_back(base SwigcptrRealDeque, _ float32) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_RealDeque_push_back, _swig_p) + return +} + +func (arg1 SwigcptrRealDeque) Push_back(arg2 float32) { + _swig_wrap_RealDeque_push_back(arg1, arg2) +} + +var _wrap_RealDeque_pop_front unsafe.Pointer + +func _swig_wrap_RealDeque_pop_front(base SwigcptrRealDeque) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_RealDeque_pop_front, _swig_p) + return +} + +func (arg1 SwigcptrRealDeque) Pop_front() { + _swig_wrap_RealDeque_pop_front(arg1) +} + +var _wrap_RealDeque_pop_back unsafe.Pointer + +func _swig_wrap_RealDeque_pop_back(base SwigcptrRealDeque) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_RealDeque_pop_back, _swig_p) + return +} + +func (arg1 SwigcptrRealDeque) Pop_back() { + _swig_wrap_RealDeque_pop_back(arg1) +} + +var _wrap_RealDeque_clear unsafe.Pointer + +func _swig_wrap_RealDeque_clear(base SwigcptrRealDeque) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_RealDeque_clear, _swig_p) + return +} + +func (arg1 SwigcptrRealDeque) Clear() { + _swig_wrap_RealDeque_clear(arg1) +} + +var _wrap_RealDeque_getitem unsafe.Pointer + +func _swig_wrap_RealDeque_getitem(base SwigcptrRealDeque, _ int) (_ float32) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_RealDeque_getitem, _swig_p) + return +} + +func (arg1 SwigcptrRealDeque) Getitem(arg2 int) (_swig_ret float32) { + return _swig_wrap_RealDeque_getitem(arg1, arg2) +} + +var _wrap_RealDeque_setitem unsafe.Pointer + +func _swig_wrap_RealDeque_setitem(base SwigcptrRealDeque, _ int, _ float32) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_RealDeque_setitem, _swig_p) + return +} + +func (arg1 SwigcptrRealDeque) Setitem(arg2 int, arg3 float32) { + _swig_wrap_RealDeque_setitem(arg1, arg2, arg3) +} + +var _wrap_RealDeque_delitem unsafe.Pointer + +func _swig_wrap_RealDeque_delitem(base SwigcptrRealDeque, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_RealDeque_delitem, _swig_p) + return +} + +func (arg1 SwigcptrRealDeque) Delitem(arg2 int) { + _swig_wrap_RealDeque_delitem(arg1, arg2) +} + +var _wrap_RealDeque_getslice unsafe.Pointer + +func _swig_wrap_RealDeque_getslice(base SwigcptrRealDeque, _ int, _ int) (_ SwigcptrRealDeque) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_RealDeque_getslice, _swig_p) + return +} + +func (arg1 SwigcptrRealDeque) Getslice(arg2 int, arg3 int) (_swig_ret RealDeque) { + return _swig_wrap_RealDeque_getslice(arg1, arg2, arg3) +} + +var _wrap_RealDeque_setslice unsafe.Pointer + +func _swig_wrap_RealDeque_setslice(base SwigcptrRealDeque, _ int, _ int, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_RealDeque_setslice, _swig_p) + return +} + +func (arg1 SwigcptrRealDeque) Setslice(arg2 int, arg3 int, arg4 RealDeque) { + _swig_wrap_RealDeque_setslice(arg1, arg2, arg3, arg4.Swigcptr()) +} + +var _wrap_RealDeque_delslice unsafe.Pointer + +func _swig_wrap_RealDeque_delslice(base SwigcptrRealDeque, _ int, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_RealDeque_delslice, _swig_p) + return +} + +func (arg1 SwigcptrRealDeque) Delslice(arg2 int, arg3 int) { + _swig_wrap_RealDeque_delslice(arg1, arg2, arg3) +} + +type RealDeque interface { + Swigcptr() uintptr + SwigIsRealDeque() + Empty() (_swig_ret bool) + Assign(arg2 uint, arg3 float32) + Swap(arg2 RealDeque) + Size() (_swig_ret uint) + Max_size() (_swig_ret uint) + Resize(a ...interface{}) + Front() (_swig_ret float32) + Back() (_swig_ret float32) + Push_front(arg2 float32) + Push_back(arg2 float32) + Pop_front() + Pop_back() + Clear() + Getitem(arg2 int) (_swig_ret float32) + Setitem(arg2 int, arg3 float32) + Delitem(arg2 int) + Getslice(arg2 int, arg3 int) (_swig_ret RealDeque) + Setslice(arg2 int, arg3 int, arg4 RealDeque) + Delslice(arg2 int, arg3 int) +} + +var _wrap_average unsafe.Pointer + +func _swig_wrap_average(base uintptr) (_ float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_average, _swig_p) + return +} + +func Average(arg1 IntDeque) (_swig_ret float64) { + return _swig_wrap_average(arg1.Swigcptr()) +} + +var _wrap_half unsafe.Pointer + +func _swig_wrap_half(base uintptr) (_ SwigcptrRealDeque) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_half, _swig_p) + return +} + +func Half(arg1 RealDeque) (_swig_ret RealDeque) { + return _swig_wrap_half(arg1.Swigcptr()) +} + +var _wrap_halve_in_place unsafe.Pointer + +func _swig_wrap_halve_in_place(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_halve_in_place, _swig_p) + return +} + +func Halve_in_place(arg1 DoubleDeque) { + _swig_wrap_halve_in_place(arg1.Swigcptr()) +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/li_std_except.go b/Examples/test-suite/go/li_std_except.go new file mode 100644 index 000000000..80815e971 --- /dev/null +++ b/Examples/test-suite/go/li_std_except.go @@ -0,0 +1,346 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../li_std_except.i + +package li_std_except + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrE1 uintptr + +func (p SwigcptrE1) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrE1) SwigIsE1() { +} + +var _wrap_new_E1 unsafe.Pointer + +func _swig_wrap_new_E1() (base SwigcptrE1) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_E1, _swig_p) + return +} + +func NewE1() (_swig_ret E1) { + return _swig_wrap_new_E1() +} + +var _wrap_delete_E1 unsafe.Pointer + +func _swig_wrap_delete_E1(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_E1, _swig_p) + return +} + +func DeleteE1(arg1 E1) { + _swig_wrap_delete_E1(arg1.Swigcptr()) +} + +type E1 interface { + Swigcptr() uintptr + SwigIsE1() +} + +type SwigcptrE2 uintptr + +func (p SwigcptrE2) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrE2) SwigIsE2() { +} + +var _wrap_new_E2 unsafe.Pointer + +func _swig_wrap_new_E2() (base SwigcptrE2) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_E2, _swig_p) + return +} + +func NewE2() (_swig_ret E2) { + return _swig_wrap_new_E2() +} + +var _wrap_delete_E2 unsafe.Pointer + +func _swig_wrap_delete_E2(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_E2, _swig_p) + return +} + +func DeleteE2(arg1 E2) { + _swig_wrap_delete_E2(arg1.Swigcptr()) +} + +type E2 interface { + Swigcptr() uintptr + SwigIsE2() +} + +type SwigcptrTest uintptr + +func (p SwigcptrTest) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrTest) SwigIsTest() { +} + +var _wrap_Test_foo1 unsafe.Pointer + +func _swig_wrap_Test_foo1(base SwigcptrTest) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Test_foo1, _swig_p) + return +} + +func (arg1 SwigcptrTest) Foo1() (_swig_ret int) { + return _swig_wrap_Test_foo1(arg1) +} + +var _wrap_Test_foo2 unsafe.Pointer + +func _swig_wrap_Test_foo2(base SwigcptrTest) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Test_foo2, _swig_p) + return +} + +func (arg1 SwigcptrTest) Foo2() (_swig_ret int) { + return _swig_wrap_Test_foo2(arg1) +} + +var _wrap_Test_foo3 unsafe.Pointer + +func _swig_wrap_Test_foo3(base SwigcptrTest) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Test_foo3, _swig_p) + return +} + +func (arg1 SwigcptrTest) Foo3() (_swig_ret int) { + return _swig_wrap_Test_foo3(arg1) +} + +var _wrap_Test_foo4 unsafe.Pointer + +func _swig_wrap_Test_foo4(base SwigcptrTest) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Test_foo4, _swig_p) + return +} + +func (arg1 SwigcptrTest) Foo4() (_swig_ret int) { + return _swig_wrap_Test_foo4(arg1) +} + +var _wrap_Test_throw_bad_exception unsafe.Pointer + +func _swig_wrap_Test_throw_bad_exception(base SwigcptrTest) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Test_throw_bad_exception, _swig_p) + return +} + +func (arg1 SwigcptrTest) Throw_bad_exception() { + _swig_wrap_Test_throw_bad_exception(arg1) +} + +var _wrap_Test_throw_domain_error unsafe.Pointer + +func _swig_wrap_Test_throw_domain_error(base SwigcptrTest) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Test_throw_domain_error, _swig_p) + return +} + +func (arg1 SwigcptrTest) Throw_domain_error() { + _swig_wrap_Test_throw_domain_error(arg1) +} + +var _wrap_Test_throw_exception unsafe.Pointer + +func _swig_wrap_Test_throw_exception(base SwigcptrTest) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Test_throw_exception, _swig_p) + return +} + +func (arg1 SwigcptrTest) Throw_exception() { + _swig_wrap_Test_throw_exception(arg1) +} + +var _wrap_Test_throw_invalid_argument unsafe.Pointer + +func _swig_wrap_Test_throw_invalid_argument(base SwigcptrTest) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Test_throw_invalid_argument, _swig_p) + return +} + +func (arg1 SwigcptrTest) Throw_invalid_argument() { + _swig_wrap_Test_throw_invalid_argument(arg1) +} + +var _wrap_Test_throw_length_error unsafe.Pointer + +func _swig_wrap_Test_throw_length_error(base SwigcptrTest) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Test_throw_length_error, _swig_p) + return +} + +func (arg1 SwigcptrTest) Throw_length_error() { + _swig_wrap_Test_throw_length_error(arg1) +} + +var _wrap_Test_throw_logic_error unsafe.Pointer + +func _swig_wrap_Test_throw_logic_error(base SwigcptrTest) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Test_throw_logic_error, _swig_p) + return +} + +func (arg1 SwigcptrTest) Throw_logic_error() { + _swig_wrap_Test_throw_logic_error(arg1) +} + +var _wrap_Test_throw_out_of_range unsafe.Pointer + +func _swig_wrap_Test_throw_out_of_range(base SwigcptrTest) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Test_throw_out_of_range, _swig_p) + return +} + +func (arg1 SwigcptrTest) Throw_out_of_range() { + _swig_wrap_Test_throw_out_of_range(arg1) +} + +var _wrap_Test_throw_overflow_error unsafe.Pointer + +func _swig_wrap_Test_throw_overflow_error(base SwigcptrTest) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Test_throw_overflow_error, _swig_p) + return +} + +func (arg1 SwigcptrTest) Throw_overflow_error() { + _swig_wrap_Test_throw_overflow_error(arg1) +} + +var _wrap_Test_throw_range_error unsafe.Pointer + +func _swig_wrap_Test_throw_range_error(base SwigcptrTest) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Test_throw_range_error, _swig_p) + return +} + +func (arg1 SwigcptrTest) Throw_range_error() { + _swig_wrap_Test_throw_range_error(arg1) +} + +var _wrap_Test_throw_runtime_error unsafe.Pointer + +func _swig_wrap_Test_throw_runtime_error(base SwigcptrTest) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Test_throw_runtime_error, _swig_p) + return +} + +func (arg1 SwigcptrTest) Throw_runtime_error() { + _swig_wrap_Test_throw_runtime_error(arg1) +} + +var _wrap_Test_throw_underflow_error unsafe.Pointer + +func _swig_wrap_Test_throw_underflow_error(base SwigcptrTest) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Test_throw_underflow_error, _swig_p) + return +} + +func (arg1 SwigcptrTest) Throw_underflow_error() { + _swig_wrap_Test_throw_underflow_error(arg1) +} + +var _wrap_new_Test unsafe.Pointer + +func _swig_wrap_new_Test() (base SwigcptrTest) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Test, _swig_p) + return +} + +func NewTest() (_swig_ret Test) { + return _swig_wrap_new_Test() +} + +var _wrap_delete_Test unsafe.Pointer + +func _swig_wrap_delete_Test(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Test, _swig_p) + return +} + +func DeleteTest(arg1 Test) { + _swig_wrap_delete_Test(arg1.Swigcptr()) +} + +type Test interface { + Swigcptr() uintptr + SwigIsTest() + Foo1() (_swig_ret int) + Foo2() (_swig_ret int) + Foo3() (_swig_ret int) + Foo4() (_swig_ret int) + Throw_bad_exception() + Throw_domain_error() + Throw_exception() + Throw_invalid_argument() + Throw_length_error() + Throw_logic_error() + Throw_out_of_range() + Throw_overflow_error() + Throw_range_error() + Throw_runtime_error() + Throw_underflow_error() +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/li_std_except_as_class.go b/Examples/test-suite/go/li_std_except_as_class.go new file mode 100644 index 000000000..0c654c612 --- /dev/null +++ b/Examples/test-suite/go/li_std_except_as_class.go @@ -0,0 +1,49 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../li_std_except_as_class.i + +package li_std_except_as_class + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +var _wrap_test_domain_error unsafe.Pointer + +func _swig_wrap_test_domain_error() { + var _swig_p uintptr + _cgo_runtime_cgocall(_wrap_test_domain_error, _swig_p) + return +} + +func Test_domain_error() { + _swig_wrap_test_domain_error() +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/li_std_map.go b/Examples/test-suite/go/li_std_map.go new file mode 100644 index 000000000..5413a9b01 --- /dev/null +++ b/Examples/test-suite/go/li_std_map.go @@ -0,0 +1,2700 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../li_std_map.i + +package li_std_map + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrMap uintptr + +func (p SwigcptrMap) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrMap) SwigIsMap() { +} + +var _wrap_map_val_set unsafe.Pointer + +func _swig_wrap_map_val_set(base SwigcptrMap, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_map_val_set, _swig_p) + return +} + +func (arg1 SwigcptrMap) SetVal(arg2 int) { + _swig_wrap_map_val_set(arg1, arg2) +} + +var _wrap_map_val_get unsafe.Pointer + +func _swig_wrap_map_val_get(base SwigcptrMap) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_map_val_get, _swig_p) + return +} + +func (arg1 SwigcptrMap) GetVal() (_swig_ret int) { + return _swig_wrap_map_val_get(arg1) +} + +var _wrap_new_map unsafe.Pointer + +func _swig_wrap_new_map(base int) (_ SwigcptrMap) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_map, _swig_p) + return +} + +func NewMap(arg1 int) (_swig_ret Map) { + return _swig_wrap_new_map(arg1) +} + +var _wrap_delete_map unsafe.Pointer + +func _swig_wrap_delete_map(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_map, _swig_p) + return +} + +func DeleteMap(arg1 Map) { + _swig_wrap_delete_map(arg1.Swigcptr()) +} + +type Map interface { + Swigcptr() uintptr + SwigIsMap() + SetVal(arg2 int) + GetVal() (_swig_ret int) +} + +type SwigcptrIntIntMap uintptr + +func (p SwigcptrIntIntMap) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrIntIntMap) SwigIsIntIntMap() { +} + +var _wrap_new_IntIntMap__SWIG_0 unsafe.Pointer + +func _swig_wrap_new_IntIntMap__SWIG_0() (base SwigcptrIntIntMap) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_IntIntMap__SWIG_0, _swig_p) + return +} + +func NewIntIntMap__SWIG_0() (_swig_ret IntIntMap) { + return _swig_wrap_new_IntIntMap__SWIG_0() +} + +var _wrap_new_IntIntMap__SWIG_1 unsafe.Pointer + +func _swig_wrap_new_IntIntMap__SWIG_1(base uintptr) (_ SwigcptrIntIntMap) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_IntIntMap__SWIG_1, _swig_p) + return +} + +func NewIntIntMap__SWIG_1(arg1 IntIntMap) (_swig_ret IntIntMap) { + return _swig_wrap_new_IntIntMap__SWIG_1(arg1.Swigcptr()) +} + +func NewIntIntMap(a ...interface{}) IntIntMap { + argc := len(a) + if argc == 0 { + return NewIntIntMap__SWIG_0() + } + if argc == 1 { + return NewIntIntMap__SWIG_1(a[0].(IntIntMap)) + } + panic("No match for overloaded function call") +} + +var _wrap_IntIntMap_size unsafe.Pointer + +func _swig_wrap_IntIntMap_size(base SwigcptrIntIntMap) (_ uint) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_IntIntMap_size, _swig_p) + return +} + +func (arg1 SwigcptrIntIntMap) Size() (_swig_ret uint) { + return _swig_wrap_IntIntMap_size(arg1) +} + +var _wrap_IntIntMap_empty unsafe.Pointer + +func _swig_wrap_IntIntMap_empty(base SwigcptrIntIntMap) (_ bool) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_IntIntMap_empty, _swig_p) + return +} + +func (arg1 SwigcptrIntIntMap) Empty() (_swig_ret bool) { + return _swig_wrap_IntIntMap_empty(arg1) +} + +var _wrap_IntIntMap_clear unsafe.Pointer + +func _swig_wrap_IntIntMap_clear(base SwigcptrIntIntMap) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_IntIntMap_clear, _swig_p) + return +} + +func (arg1 SwigcptrIntIntMap) Clear() { + _swig_wrap_IntIntMap_clear(arg1) +} + +var _wrap_IntIntMap_get unsafe.Pointer + +func _swig_wrap_IntIntMap_get(base SwigcptrIntIntMap, _ int) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_IntIntMap_get, _swig_p) + return +} + +func (arg1 SwigcptrIntIntMap) Get(arg2 int) (_swig_ret int) { + return _swig_wrap_IntIntMap_get(arg1, arg2) +} + +var _wrap_IntIntMap_set unsafe.Pointer + +func _swig_wrap_IntIntMap_set(base SwigcptrIntIntMap, _ int, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_IntIntMap_set, _swig_p) + return +} + +func (arg1 SwigcptrIntIntMap) Set(arg2 int, arg3 int) { + _swig_wrap_IntIntMap_set(arg1, arg2, arg3) +} + +var _wrap_IntIntMap_del unsafe.Pointer + +func _swig_wrap_IntIntMap_del(base SwigcptrIntIntMap, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_IntIntMap_del, _swig_p) + return +} + +func (arg1 SwigcptrIntIntMap) Del(arg2 int) { + _swig_wrap_IntIntMap_del(arg1, arg2) +} + +var _wrap_IntIntMap_has_key unsafe.Pointer + +func _swig_wrap_IntIntMap_has_key(base SwigcptrIntIntMap, _ int) (_ bool) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_IntIntMap_has_key, _swig_p) + return +} + +func (arg1 SwigcptrIntIntMap) Has_key(arg2 int) (_swig_ret bool) { + return _swig_wrap_IntIntMap_has_key(arg1, arg2) +} + +var _wrap_delete_IntIntMap unsafe.Pointer + +func _swig_wrap_delete_IntIntMap(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_IntIntMap, _swig_p) + return +} + +func DeleteIntIntMap(arg1 IntIntMap) { + _swig_wrap_delete_IntIntMap(arg1.Swigcptr()) +} + +type IntIntMap interface { + Swigcptr() uintptr + SwigIsIntIntMap() + Size() (_swig_ret uint) + Empty() (_swig_ret bool) + Clear() + Get(arg2 int) (_swig_ret int) + Set(arg2 int, arg3 int) + Del(arg2 int) + Has_key(arg2 int) (_swig_ret bool) +} + +type SwigcptrStringIntMap uintptr + +func (p SwigcptrStringIntMap) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrStringIntMap) SwigIsStringIntMap() { +} + +var _wrap_new_StringIntMap__SWIG_0 unsafe.Pointer + +func _swig_wrap_new_StringIntMap__SWIG_0() (base SwigcptrStringIntMap) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_StringIntMap__SWIG_0, _swig_p) + return +} + +func NewStringIntMap__SWIG_0() (_swig_ret StringIntMap) { + return _swig_wrap_new_StringIntMap__SWIG_0() +} + +var _wrap_new_StringIntMap__SWIG_1 unsafe.Pointer + +func _swig_wrap_new_StringIntMap__SWIG_1(base uintptr) (_ SwigcptrStringIntMap) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_StringIntMap__SWIG_1, _swig_p) + return +} + +func NewStringIntMap__SWIG_1(arg1 StringIntMap) (_swig_ret StringIntMap) { + return _swig_wrap_new_StringIntMap__SWIG_1(arg1.Swigcptr()) +} + +func NewStringIntMap(a ...interface{}) StringIntMap { + argc := len(a) + if argc == 0 { + return NewStringIntMap__SWIG_0() + } + if argc == 1 { + return NewStringIntMap__SWIG_1(a[0].(StringIntMap)) + } + panic("No match for overloaded function call") +} + +var _wrap_StringIntMap_size unsafe.Pointer + +func _swig_wrap_StringIntMap_size(base SwigcptrStringIntMap) (_ uint) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_StringIntMap_size, _swig_p) + return +} + +func (arg1 SwigcptrStringIntMap) Size() (_swig_ret uint) { + return _swig_wrap_StringIntMap_size(arg1) +} + +var _wrap_StringIntMap_empty unsafe.Pointer + +func _swig_wrap_StringIntMap_empty(base SwigcptrStringIntMap) (_ bool) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_StringIntMap_empty, _swig_p) + return +} + +func (arg1 SwigcptrStringIntMap) Empty() (_swig_ret bool) { + return _swig_wrap_StringIntMap_empty(arg1) +} + +var _wrap_StringIntMap_clear unsafe.Pointer + +func _swig_wrap_StringIntMap_clear(base SwigcptrStringIntMap) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_StringIntMap_clear, _swig_p) + return +} + +func (arg1 SwigcptrStringIntMap) Clear() { + _swig_wrap_StringIntMap_clear(arg1) +} + +var _wrap_StringIntMap_get unsafe.Pointer + +func _swig_wrap_StringIntMap_get(base SwigcptrStringIntMap, _ string) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_StringIntMap_get, _swig_p) + return +} + +func (arg1 SwigcptrStringIntMap) Get(arg2 string) (_swig_ret int) { + return _swig_wrap_StringIntMap_get(arg1, arg2) +} + +var _wrap_StringIntMap_set unsafe.Pointer + +func _swig_wrap_StringIntMap_set(base SwigcptrStringIntMap, _ string, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_StringIntMap_set, _swig_p) + return +} + +func (arg1 SwigcptrStringIntMap) Set(arg2 string, arg3 int) { + _swig_wrap_StringIntMap_set(arg1, arg2, arg3) +} + +var _wrap_StringIntMap_del unsafe.Pointer + +func _swig_wrap_StringIntMap_del(base SwigcptrStringIntMap, _ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_StringIntMap_del, _swig_p) + return +} + +func (arg1 SwigcptrStringIntMap) Del(arg2 string) { + _swig_wrap_StringIntMap_del(arg1, arg2) +} + +var _wrap_StringIntMap_has_key unsafe.Pointer + +func _swig_wrap_StringIntMap_has_key(base SwigcptrStringIntMap, _ string) (_ bool) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_StringIntMap_has_key, _swig_p) + return +} + +func (arg1 SwigcptrStringIntMap) Has_key(arg2 string) (_swig_ret bool) { + return _swig_wrap_StringIntMap_has_key(arg1, arg2) +} + +var _wrap_delete_StringIntMap unsafe.Pointer + +func _swig_wrap_delete_StringIntMap(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_StringIntMap, _swig_p) + return +} + +func DeleteStringIntMap(arg1 StringIntMap) { + _swig_wrap_delete_StringIntMap(arg1.Swigcptr()) +} + +type StringIntMap interface { + Swigcptr() uintptr + SwigIsStringIntMap() + Size() (_swig_ret uint) + Empty() (_swig_ret bool) + Clear() + Get(arg2 string) (_swig_ret int) + Set(arg2 string, arg3 int) + Del(arg2 string) + Has_key(arg2 string) (_swig_ret bool) +} + +var _wrap_valueAverage unsafe.Pointer + +func _swig_wrap_valueAverage(base uintptr) (_ float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_valueAverage, _swig_p) + return +} + +func ValueAverage(arg1 StringIntMap) (_swig_ret float64) { + return _swig_wrap_valueAverage(arg1.Swigcptr()) +} + +var _wrap_stringifyKeys unsafe.Pointer + +func _swig_wrap_stringifyKeys(base uintptr) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_stringifyKeys, _swig_p) + return +} + +func StringifyKeys(arg1 StringIntMap) (_swig_ret string) { + return _swig_wrap_stringifyKeys(arg1.Swigcptr()) +} + +type SwigcptrStruct uintptr + +func (p SwigcptrStruct) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrStruct) SwigIsStruct() { +} + +var _wrap_Struct_num_set unsafe.Pointer + +func _swig_wrap_Struct_num_set(base SwigcptrStruct, _ float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Struct_num_set, _swig_p) + return +} + +func (arg1 SwigcptrStruct) SetNum(arg2 float64) { + _swig_wrap_Struct_num_set(arg1, arg2) +} + +var _wrap_Struct_num_get unsafe.Pointer + +func _swig_wrap_Struct_num_get(base SwigcptrStruct) (_ float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Struct_num_get, _swig_p) + return +} + +func (arg1 SwigcptrStruct) GetNum() (_swig_ret float64) { + return _swig_wrap_Struct_num_get(arg1) +} + +var _wrap_new_Struct__SWIG_0 unsafe.Pointer + +func _swig_wrap_new_Struct__SWIG_0() (base SwigcptrStruct) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Struct__SWIG_0, _swig_p) + return +} + +func NewStruct__SWIG_0() (_swig_ret Struct) { + return _swig_wrap_new_Struct__SWIG_0() +} + +var _wrap_new_Struct__SWIG_1 unsafe.Pointer + +func _swig_wrap_new_Struct__SWIG_1(base float64) (_ SwigcptrStruct) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Struct__SWIG_1, _swig_p) + return +} + +func NewStruct__SWIG_1(arg1 float64) (_swig_ret Struct) { + return _swig_wrap_new_Struct__SWIG_1(arg1) +} + +func NewStruct(a ...interface{}) Struct { + argc := len(a) + if argc == 0 { + return NewStruct__SWIG_0() + } + if argc == 1 { + return NewStruct__SWIG_1(a[0].(float64)) + } + panic("No match for overloaded function call") +} + +var _wrap_delete_Struct unsafe.Pointer + +func _swig_wrap_delete_Struct(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Struct, _swig_p) + return +} + +func DeleteStruct(arg1 Struct) { + _swig_wrap_delete_Struct(arg1.Swigcptr()) +} + +type Struct interface { + Swigcptr() uintptr + SwigIsStruct() + SetNum(arg2 float64) + GetNum() (_swig_ret float64) +} + +type SwigcptrIntIntPtrMap uintptr + +func (p SwigcptrIntIntPtrMap) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrIntIntPtrMap) SwigIsIntIntPtrMap() { +} + +var _wrap_new_IntIntPtrMap__SWIG_0 unsafe.Pointer + +func _swig_wrap_new_IntIntPtrMap__SWIG_0() (base SwigcptrIntIntPtrMap) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_IntIntPtrMap__SWIG_0, _swig_p) + return +} + +func NewIntIntPtrMap__SWIG_0() (_swig_ret IntIntPtrMap) { + return _swig_wrap_new_IntIntPtrMap__SWIG_0() +} + +var _wrap_new_IntIntPtrMap__SWIG_1 unsafe.Pointer + +func _swig_wrap_new_IntIntPtrMap__SWIG_1(base uintptr) (_ SwigcptrIntIntPtrMap) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_IntIntPtrMap__SWIG_1, _swig_p) + return +} + +func NewIntIntPtrMap__SWIG_1(arg1 IntIntPtrMap) (_swig_ret IntIntPtrMap) { + return _swig_wrap_new_IntIntPtrMap__SWIG_1(arg1.Swigcptr()) +} + +func NewIntIntPtrMap(a ...interface{}) IntIntPtrMap { + argc := len(a) + if argc == 0 { + return NewIntIntPtrMap__SWIG_0() + } + if argc == 1 { + return NewIntIntPtrMap__SWIG_1(a[0].(IntIntPtrMap)) + } + panic("No match for overloaded function call") +} + +var _wrap_IntIntPtrMap_size unsafe.Pointer + +func _swig_wrap_IntIntPtrMap_size(base SwigcptrIntIntPtrMap) (_ uint) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_IntIntPtrMap_size, _swig_p) + return +} + +func (arg1 SwigcptrIntIntPtrMap) Size() (_swig_ret uint) { + return _swig_wrap_IntIntPtrMap_size(arg1) +} + +var _wrap_IntIntPtrMap_empty unsafe.Pointer + +func _swig_wrap_IntIntPtrMap_empty(base SwigcptrIntIntPtrMap) (_ bool) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_IntIntPtrMap_empty, _swig_p) + return +} + +func (arg1 SwigcptrIntIntPtrMap) Empty() (_swig_ret bool) { + return _swig_wrap_IntIntPtrMap_empty(arg1) +} + +var _wrap_IntIntPtrMap_clear unsafe.Pointer + +func _swig_wrap_IntIntPtrMap_clear(base SwigcptrIntIntPtrMap) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_IntIntPtrMap_clear, _swig_p) + return +} + +func (arg1 SwigcptrIntIntPtrMap) Clear() { + _swig_wrap_IntIntPtrMap_clear(arg1) +} + +var _wrap_IntIntPtrMap_get unsafe.Pointer + +func _swig_wrap_IntIntPtrMap_get(base SwigcptrIntIntPtrMap, _ int) (_ *int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_IntIntPtrMap_get, _swig_p) + return +} + +func (arg1 SwigcptrIntIntPtrMap) Get(arg2 int) (_swig_ret *int) { + return _swig_wrap_IntIntPtrMap_get(arg1, arg2) +} + +var _wrap_IntIntPtrMap_set unsafe.Pointer + +func _swig_wrap_IntIntPtrMap_set(base SwigcptrIntIntPtrMap, _ int, _ *int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_IntIntPtrMap_set, _swig_p) + return +} + +func (arg1 SwigcptrIntIntPtrMap) Set(arg2 int, arg3 *int) { + _swig_wrap_IntIntPtrMap_set(arg1, arg2, arg3) +} + +var _wrap_IntIntPtrMap_del unsafe.Pointer + +func _swig_wrap_IntIntPtrMap_del(base SwigcptrIntIntPtrMap, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_IntIntPtrMap_del, _swig_p) + return +} + +func (arg1 SwigcptrIntIntPtrMap) Del(arg2 int) { + _swig_wrap_IntIntPtrMap_del(arg1, arg2) +} + +var _wrap_IntIntPtrMap_has_key unsafe.Pointer + +func _swig_wrap_IntIntPtrMap_has_key(base SwigcptrIntIntPtrMap, _ int) (_ bool) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_IntIntPtrMap_has_key, _swig_p) + return +} + +func (arg1 SwigcptrIntIntPtrMap) Has_key(arg2 int) (_swig_ret bool) { + return _swig_wrap_IntIntPtrMap_has_key(arg1, arg2) +} + +var _wrap_delete_IntIntPtrMap unsafe.Pointer + +func _swig_wrap_delete_IntIntPtrMap(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_IntIntPtrMap, _swig_p) + return +} + +func DeleteIntIntPtrMap(arg1 IntIntPtrMap) { + _swig_wrap_delete_IntIntPtrMap(arg1.Swigcptr()) +} + +type IntIntPtrMap interface { + Swigcptr() uintptr + SwigIsIntIntPtrMap() + Size() (_swig_ret uint) + Empty() (_swig_ret bool) + Clear() + Get(arg2 int) (_swig_ret *int) + Set(arg2 int, arg3 *int) + Del(arg2 int) + Has_key(arg2 int) (_swig_ret bool) +} + +type SwigcptrIntConstIntPtrMap uintptr + +func (p SwigcptrIntConstIntPtrMap) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrIntConstIntPtrMap) SwigIsIntConstIntPtrMap() { +} + +var _wrap_new_IntConstIntPtrMap__SWIG_0 unsafe.Pointer + +func _swig_wrap_new_IntConstIntPtrMap__SWIG_0() (base SwigcptrIntConstIntPtrMap) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_IntConstIntPtrMap__SWIG_0, _swig_p) + return +} + +func NewIntConstIntPtrMap__SWIG_0() (_swig_ret IntConstIntPtrMap) { + return _swig_wrap_new_IntConstIntPtrMap__SWIG_0() +} + +var _wrap_new_IntConstIntPtrMap__SWIG_1 unsafe.Pointer + +func _swig_wrap_new_IntConstIntPtrMap__SWIG_1(base uintptr) (_ SwigcptrIntConstIntPtrMap) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_IntConstIntPtrMap__SWIG_1, _swig_p) + return +} + +func NewIntConstIntPtrMap__SWIG_1(arg1 IntConstIntPtrMap) (_swig_ret IntConstIntPtrMap) { + return _swig_wrap_new_IntConstIntPtrMap__SWIG_1(arg1.Swigcptr()) +} + +func NewIntConstIntPtrMap(a ...interface{}) IntConstIntPtrMap { + argc := len(a) + if argc == 0 { + return NewIntConstIntPtrMap__SWIG_0() + } + if argc == 1 { + return NewIntConstIntPtrMap__SWIG_1(a[0].(IntConstIntPtrMap)) + } + panic("No match for overloaded function call") +} + +var _wrap_IntConstIntPtrMap_size unsafe.Pointer + +func _swig_wrap_IntConstIntPtrMap_size(base SwigcptrIntConstIntPtrMap) (_ uint) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_IntConstIntPtrMap_size, _swig_p) + return +} + +func (arg1 SwigcptrIntConstIntPtrMap) Size() (_swig_ret uint) { + return _swig_wrap_IntConstIntPtrMap_size(arg1) +} + +var _wrap_IntConstIntPtrMap_empty unsafe.Pointer + +func _swig_wrap_IntConstIntPtrMap_empty(base SwigcptrIntConstIntPtrMap) (_ bool) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_IntConstIntPtrMap_empty, _swig_p) + return +} + +func (arg1 SwigcptrIntConstIntPtrMap) Empty() (_swig_ret bool) { + return _swig_wrap_IntConstIntPtrMap_empty(arg1) +} + +var _wrap_IntConstIntPtrMap_clear unsafe.Pointer + +func _swig_wrap_IntConstIntPtrMap_clear(base SwigcptrIntConstIntPtrMap) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_IntConstIntPtrMap_clear, _swig_p) + return +} + +func (arg1 SwigcptrIntConstIntPtrMap) Clear() { + _swig_wrap_IntConstIntPtrMap_clear(arg1) +} + +var _wrap_IntConstIntPtrMap_get unsafe.Pointer + +func _swig_wrap_IntConstIntPtrMap_get(base SwigcptrIntConstIntPtrMap, _ int) (_ *int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_IntConstIntPtrMap_get, _swig_p) + return +} + +func (arg1 SwigcptrIntConstIntPtrMap) Get(arg2 int) (_swig_ret *int) { + return _swig_wrap_IntConstIntPtrMap_get(arg1, arg2) +} + +var _wrap_IntConstIntPtrMap_set unsafe.Pointer + +func _swig_wrap_IntConstIntPtrMap_set(base SwigcptrIntConstIntPtrMap, _ int, _ *int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_IntConstIntPtrMap_set, _swig_p) + return +} + +func (arg1 SwigcptrIntConstIntPtrMap) Set(arg2 int, arg3 *int) { + _swig_wrap_IntConstIntPtrMap_set(arg1, arg2, arg3) +} + +var _wrap_IntConstIntPtrMap_del unsafe.Pointer + +func _swig_wrap_IntConstIntPtrMap_del(base SwigcptrIntConstIntPtrMap, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_IntConstIntPtrMap_del, _swig_p) + return +} + +func (arg1 SwigcptrIntConstIntPtrMap) Del(arg2 int) { + _swig_wrap_IntConstIntPtrMap_del(arg1, arg2) +} + +var _wrap_IntConstIntPtrMap_has_key unsafe.Pointer + +func _swig_wrap_IntConstIntPtrMap_has_key(base SwigcptrIntConstIntPtrMap, _ int) (_ bool) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_IntConstIntPtrMap_has_key, _swig_p) + return +} + +func (arg1 SwigcptrIntConstIntPtrMap) Has_key(arg2 int) (_swig_ret bool) { + return _swig_wrap_IntConstIntPtrMap_has_key(arg1, arg2) +} + +var _wrap_delete_IntConstIntPtrMap unsafe.Pointer + +func _swig_wrap_delete_IntConstIntPtrMap(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_IntConstIntPtrMap, _swig_p) + return +} + +func DeleteIntConstIntPtrMap(arg1 IntConstIntPtrMap) { + _swig_wrap_delete_IntConstIntPtrMap(arg1.Swigcptr()) +} + +type IntConstIntPtrMap interface { + Swigcptr() uintptr + SwigIsIntConstIntPtrMap() + Size() (_swig_ret uint) + Empty() (_swig_ret bool) + Clear() + Get(arg2 int) (_swig_ret *int) + Set(arg2 int, arg3 *int) + Del(arg2 int) + Has_key(arg2 int) (_swig_ret bool) +} + +type SwigcptrIntStructMap uintptr + +func (p SwigcptrIntStructMap) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrIntStructMap) SwigIsIntStructMap() { +} + +var _wrap_new_IntStructMap__SWIG_0 unsafe.Pointer + +func _swig_wrap_new_IntStructMap__SWIG_0() (base SwigcptrIntStructMap) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_IntStructMap__SWIG_0, _swig_p) + return +} + +func NewIntStructMap__SWIG_0() (_swig_ret IntStructMap) { + return _swig_wrap_new_IntStructMap__SWIG_0() +} + +var _wrap_new_IntStructMap__SWIG_1 unsafe.Pointer + +func _swig_wrap_new_IntStructMap__SWIG_1(base uintptr) (_ SwigcptrIntStructMap) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_IntStructMap__SWIG_1, _swig_p) + return +} + +func NewIntStructMap__SWIG_1(arg1 IntStructMap) (_swig_ret IntStructMap) { + return _swig_wrap_new_IntStructMap__SWIG_1(arg1.Swigcptr()) +} + +func NewIntStructMap(a ...interface{}) IntStructMap { + argc := len(a) + if argc == 0 { + return NewIntStructMap__SWIG_0() + } + if argc == 1 { + return NewIntStructMap__SWIG_1(a[0].(IntStructMap)) + } + panic("No match for overloaded function call") +} + +var _wrap_IntStructMap_size unsafe.Pointer + +func _swig_wrap_IntStructMap_size(base SwigcptrIntStructMap) (_ uint) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_IntStructMap_size, _swig_p) + return +} + +func (arg1 SwigcptrIntStructMap) Size() (_swig_ret uint) { + return _swig_wrap_IntStructMap_size(arg1) +} + +var _wrap_IntStructMap_empty unsafe.Pointer + +func _swig_wrap_IntStructMap_empty(base SwigcptrIntStructMap) (_ bool) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_IntStructMap_empty, _swig_p) + return +} + +func (arg1 SwigcptrIntStructMap) Empty() (_swig_ret bool) { + return _swig_wrap_IntStructMap_empty(arg1) +} + +var _wrap_IntStructMap_clear unsafe.Pointer + +func _swig_wrap_IntStructMap_clear(base SwigcptrIntStructMap) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_IntStructMap_clear, _swig_p) + return +} + +func (arg1 SwigcptrIntStructMap) Clear() { + _swig_wrap_IntStructMap_clear(arg1) +} + +var _wrap_IntStructMap_get unsafe.Pointer + +func _swig_wrap_IntStructMap_get(base SwigcptrIntStructMap, _ int) (_ SwigcptrStruct) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_IntStructMap_get, _swig_p) + return +} + +func (arg1 SwigcptrIntStructMap) Get(arg2 int) (_swig_ret Struct) { + return _swig_wrap_IntStructMap_get(arg1, arg2) +} + +var _wrap_IntStructMap_set unsafe.Pointer + +func _swig_wrap_IntStructMap_set(base SwigcptrIntStructMap, _ int, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_IntStructMap_set, _swig_p) + return +} + +func (arg1 SwigcptrIntStructMap) Set(arg2 int, arg3 Struct) { + _swig_wrap_IntStructMap_set(arg1, arg2, arg3.Swigcptr()) +} + +var _wrap_IntStructMap_del unsafe.Pointer + +func _swig_wrap_IntStructMap_del(base SwigcptrIntStructMap, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_IntStructMap_del, _swig_p) + return +} + +func (arg1 SwigcptrIntStructMap) Del(arg2 int) { + _swig_wrap_IntStructMap_del(arg1, arg2) +} + +var _wrap_IntStructMap_has_key unsafe.Pointer + +func _swig_wrap_IntStructMap_has_key(base SwigcptrIntStructMap, _ int) (_ bool) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_IntStructMap_has_key, _swig_p) + return +} + +func (arg1 SwigcptrIntStructMap) Has_key(arg2 int) (_swig_ret bool) { + return _swig_wrap_IntStructMap_has_key(arg1, arg2) +} + +var _wrap_delete_IntStructMap unsafe.Pointer + +func _swig_wrap_delete_IntStructMap(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_IntStructMap, _swig_p) + return +} + +func DeleteIntStructMap(arg1 IntStructMap) { + _swig_wrap_delete_IntStructMap(arg1.Swigcptr()) +} + +type IntStructMap interface { + Swigcptr() uintptr + SwigIsIntStructMap() + Size() (_swig_ret uint) + Empty() (_swig_ret bool) + Clear() + Get(arg2 int) (_swig_ret Struct) + Set(arg2 int, arg3 Struct) + Del(arg2 int) + Has_key(arg2 int) (_swig_ret bool) +} + +type SwigcptrIntStructPtrMap uintptr + +func (p SwigcptrIntStructPtrMap) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrIntStructPtrMap) SwigIsIntStructPtrMap() { +} + +var _wrap_new_IntStructPtrMap__SWIG_0 unsafe.Pointer + +func _swig_wrap_new_IntStructPtrMap__SWIG_0() (base SwigcptrIntStructPtrMap) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_IntStructPtrMap__SWIG_0, _swig_p) + return +} + +func NewIntStructPtrMap__SWIG_0() (_swig_ret IntStructPtrMap) { + return _swig_wrap_new_IntStructPtrMap__SWIG_0() +} + +var _wrap_new_IntStructPtrMap__SWIG_1 unsafe.Pointer + +func _swig_wrap_new_IntStructPtrMap__SWIG_1(base uintptr) (_ SwigcptrIntStructPtrMap) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_IntStructPtrMap__SWIG_1, _swig_p) + return +} + +func NewIntStructPtrMap__SWIG_1(arg1 IntStructPtrMap) (_swig_ret IntStructPtrMap) { + return _swig_wrap_new_IntStructPtrMap__SWIG_1(arg1.Swigcptr()) +} + +func NewIntStructPtrMap(a ...interface{}) IntStructPtrMap { + argc := len(a) + if argc == 0 { + return NewIntStructPtrMap__SWIG_0() + } + if argc == 1 { + return NewIntStructPtrMap__SWIG_1(a[0].(IntStructPtrMap)) + } + panic("No match for overloaded function call") +} + +var _wrap_IntStructPtrMap_size unsafe.Pointer + +func _swig_wrap_IntStructPtrMap_size(base SwigcptrIntStructPtrMap) (_ uint) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_IntStructPtrMap_size, _swig_p) + return +} + +func (arg1 SwigcptrIntStructPtrMap) Size() (_swig_ret uint) { + return _swig_wrap_IntStructPtrMap_size(arg1) +} + +var _wrap_IntStructPtrMap_empty unsafe.Pointer + +func _swig_wrap_IntStructPtrMap_empty(base SwigcptrIntStructPtrMap) (_ bool) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_IntStructPtrMap_empty, _swig_p) + return +} + +func (arg1 SwigcptrIntStructPtrMap) Empty() (_swig_ret bool) { + return _swig_wrap_IntStructPtrMap_empty(arg1) +} + +var _wrap_IntStructPtrMap_clear unsafe.Pointer + +func _swig_wrap_IntStructPtrMap_clear(base SwigcptrIntStructPtrMap) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_IntStructPtrMap_clear, _swig_p) + return +} + +func (arg1 SwigcptrIntStructPtrMap) Clear() { + _swig_wrap_IntStructPtrMap_clear(arg1) +} + +var _wrap_IntStructPtrMap_get unsafe.Pointer + +func _swig_wrap_IntStructPtrMap_get(base SwigcptrIntStructPtrMap, _ int) (_ SwigcptrStruct) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_IntStructPtrMap_get, _swig_p) + return +} + +func (arg1 SwigcptrIntStructPtrMap) Get(arg2 int) (_swig_ret Struct) { + return _swig_wrap_IntStructPtrMap_get(arg1, arg2) +} + +var _wrap_IntStructPtrMap_set unsafe.Pointer + +func _swig_wrap_IntStructPtrMap_set(base SwigcptrIntStructPtrMap, _ int, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_IntStructPtrMap_set, _swig_p) + return +} + +func (arg1 SwigcptrIntStructPtrMap) Set(arg2 int, arg3 Struct) { + _swig_wrap_IntStructPtrMap_set(arg1, arg2, arg3.Swigcptr()) +} + +var _wrap_IntStructPtrMap_del unsafe.Pointer + +func _swig_wrap_IntStructPtrMap_del(base SwigcptrIntStructPtrMap, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_IntStructPtrMap_del, _swig_p) + return +} + +func (arg1 SwigcptrIntStructPtrMap) Del(arg2 int) { + _swig_wrap_IntStructPtrMap_del(arg1, arg2) +} + +var _wrap_IntStructPtrMap_has_key unsafe.Pointer + +func _swig_wrap_IntStructPtrMap_has_key(base SwigcptrIntStructPtrMap, _ int) (_ bool) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_IntStructPtrMap_has_key, _swig_p) + return +} + +func (arg1 SwigcptrIntStructPtrMap) Has_key(arg2 int) (_swig_ret bool) { + return _swig_wrap_IntStructPtrMap_has_key(arg1, arg2) +} + +var _wrap_delete_IntStructPtrMap unsafe.Pointer + +func _swig_wrap_delete_IntStructPtrMap(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_IntStructPtrMap, _swig_p) + return +} + +func DeleteIntStructPtrMap(arg1 IntStructPtrMap) { + _swig_wrap_delete_IntStructPtrMap(arg1.Swigcptr()) +} + +type IntStructPtrMap interface { + Swigcptr() uintptr + SwigIsIntStructPtrMap() + Size() (_swig_ret uint) + Empty() (_swig_ret bool) + Clear() + Get(arg2 int) (_swig_ret Struct) + Set(arg2 int, arg3 Struct) + Del(arg2 int) + Has_key(arg2 int) (_swig_ret bool) +} + +type SwigcptrIntStructConstPtrMap uintptr + +func (p SwigcptrIntStructConstPtrMap) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrIntStructConstPtrMap) SwigIsIntStructConstPtrMap() { +} + +var _wrap_new_IntStructConstPtrMap__SWIG_0 unsafe.Pointer + +func _swig_wrap_new_IntStructConstPtrMap__SWIG_0() (base SwigcptrIntStructConstPtrMap) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_IntStructConstPtrMap__SWIG_0, _swig_p) + return +} + +func NewIntStructConstPtrMap__SWIG_0() (_swig_ret IntStructConstPtrMap) { + return _swig_wrap_new_IntStructConstPtrMap__SWIG_0() +} + +var _wrap_new_IntStructConstPtrMap__SWIG_1 unsafe.Pointer + +func _swig_wrap_new_IntStructConstPtrMap__SWIG_1(base uintptr) (_ SwigcptrIntStructConstPtrMap) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_IntStructConstPtrMap__SWIG_1, _swig_p) + return +} + +func NewIntStructConstPtrMap__SWIG_1(arg1 IntStructConstPtrMap) (_swig_ret IntStructConstPtrMap) { + return _swig_wrap_new_IntStructConstPtrMap__SWIG_1(arg1.Swigcptr()) +} + +func NewIntStructConstPtrMap(a ...interface{}) IntStructConstPtrMap { + argc := len(a) + if argc == 0 { + return NewIntStructConstPtrMap__SWIG_0() + } + if argc == 1 { + return NewIntStructConstPtrMap__SWIG_1(a[0].(IntStructConstPtrMap)) + } + panic("No match for overloaded function call") +} + +var _wrap_IntStructConstPtrMap_size unsafe.Pointer + +func _swig_wrap_IntStructConstPtrMap_size(base SwigcptrIntStructConstPtrMap) (_ uint) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_IntStructConstPtrMap_size, _swig_p) + return +} + +func (arg1 SwigcptrIntStructConstPtrMap) Size() (_swig_ret uint) { + return _swig_wrap_IntStructConstPtrMap_size(arg1) +} + +var _wrap_IntStructConstPtrMap_empty unsafe.Pointer + +func _swig_wrap_IntStructConstPtrMap_empty(base SwigcptrIntStructConstPtrMap) (_ bool) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_IntStructConstPtrMap_empty, _swig_p) + return +} + +func (arg1 SwigcptrIntStructConstPtrMap) Empty() (_swig_ret bool) { + return _swig_wrap_IntStructConstPtrMap_empty(arg1) +} + +var _wrap_IntStructConstPtrMap_clear unsafe.Pointer + +func _swig_wrap_IntStructConstPtrMap_clear(base SwigcptrIntStructConstPtrMap) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_IntStructConstPtrMap_clear, _swig_p) + return +} + +func (arg1 SwigcptrIntStructConstPtrMap) Clear() { + _swig_wrap_IntStructConstPtrMap_clear(arg1) +} + +var _wrap_IntStructConstPtrMap_get unsafe.Pointer + +func _swig_wrap_IntStructConstPtrMap_get(base SwigcptrIntStructConstPtrMap, _ int) (_ SwigcptrStruct) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_IntStructConstPtrMap_get, _swig_p) + return +} + +func (arg1 SwigcptrIntStructConstPtrMap) Get(arg2 int) (_swig_ret Struct) { + return _swig_wrap_IntStructConstPtrMap_get(arg1, arg2) +} + +var _wrap_IntStructConstPtrMap_set unsafe.Pointer + +func _swig_wrap_IntStructConstPtrMap_set(base SwigcptrIntStructConstPtrMap, _ int, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_IntStructConstPtrMap_set, _swig_p) + return +} + +func (arg1 SwigcptrIntStructConstPtrMap) Set(arg2 int, arg3 Struct) { + _swig_wrap_IntStructConstPtrMap_set(arg1, arg2, arg3.Swigcptr()) +} + +var _wrap_IntStructConstPtrMap_del unsafe.Pointer + +func _swig_wrap_IntStructConstPtrMap_del(base SwigcptrIntStructConstPtrMap, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_IntStructConstPtrMap_del, _swig_p) + return +} + +func (arg1 SwigcptrIntStructConstPtrMap) Del(arg2 int) { + _swig_wrap_IntStructConstPtrMap_del(arg1, arg2) +} + +var _wrap_IntStructConstPtrMap_has_key unsafe.Pointer + +func _swig_wrap_IntStructConstPtrMap_has_key(base SwigcptrIntStructConstPtrMap, _ int) (_ bool) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_IntStructConstPtrMap_has_key, _swig_p) + return +} + +func (arg1 SwigcptrIntStructConstPtrMap) Has_key(arg2 int) (_swig_ret bool) { + return _swig_wrap_IntStructConstPtrMap_has_key(arg1, arg2) +} + +var _wrap_delete_IntStructConstPtrMap unsafe.Pointer + +func _swig_wrap_delete_IntStructConstPtrMap(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_IntStructConstPtrMap, _swig_p) + return +} + +func DeleteIntStructConstPtrMap(arg1 IntStructConstPtrMap) { + _swig_wrap_delete_IntStructConstPtrMap(arg1.Swigcptr()) +} + +type IntStructConstPtrMap interface { + Swigcptr() uintptr + SwigIsIntStructConstPtrMap() + Size() (_swig_ret uint) + Empty() (_swig_ret bool) + Clear() + Get(arg2 int) (_swig_ret Struct) + Set(arg2 int, arg3 Struct) + Del(arg2 int) + Has_key(arg2 int) (_swig_ret bool) +} + +type SwigcptrStructPtrIntMap uintptr + +func (p SwigcptrStructPtrIntMap) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrStructPtrIntMap) SwigIsStructPtrIntMap() { +} + +var _wrap_new_StructPtrIntMap__SWIG_0 unsafe.Pointer + +func _swig_wrap_new_StructPtrIntMap__SWIG_0() (base SwigcptrStructPtrIntMap) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_StructPtrIntMap__SWIG_0, _swig_p) + return +} + +func NewStructPtrIntMap__SWIG_0() (_swig_ret StructPtrIntMap) { + return _swig_wrap_new_StructPtrIntMap__SWIG_0() +} + +var _wrap_new_StructPtrIntMap__SWIG_1 unsafe.Pointer + +func _swig_wrap_new_StructPtrIntMap__SWIG_1(base uintptr) (_ SwigcptrStructPtrIntMap) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_StructPtrIntMap__SWIG_1, _swig_p) + return +} + +func NewStructPtrIntMap__SWIG_1(arg1 StructPtrIntMap) (_swig_ret StructPtrIntMap) { + return _swig_wrap_new_StructPtrIntMap__SWIG_1(arg1.Swigcptr()) +} + +func NewStructPtrIntMap(a ...interface{}) StructPtrIntMap { + argc := len(a) + if argc == 0 { + return NewStructPtrIntMap__SWIG_0() + } + if argc == 1 { + return NewStructPtrIntMap__SWIG_1(a[0].(StructPtrIntMap)) + } + panic("No match for overloaded function call") +} + +var _wrap_StructPtrIntMap_size unsafe.Pointer + +func _swig_wrap_StructPtrIntMap_size(base SwigcptrStructPtrIntMap) (_ uint) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_StructPtrIntMap_size, _swig_p) + return +} + +func (arg1 SwigcptrStructPtrIntMap) Size() (_swig_ret uint) { + return _swig_wrap_StructPtrIntMap_size(arg1) +} + +var _wrap_StructPtrIntMap_empty unsafe.Pointer + +func _swig_wrap_StructPtrIntMap_empty(base SwigcptrStructPtrIntMap) (_ bool) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_StructPtrIntMap_empty, _swig_p) + return +} + +func (arg1 SwigcptrStructPtrIntMap) Empty() (_swig_ret bool) { + return _swig_wrap_StructPtrIntMap_empty(arg1) +} + +var _wrap_StructPtrIntMap_clear unsafe.Pointer + +func _swig_wrap_StructPtrIntMap_clear(base SwigcptrStructPtrIntMap) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_StructPtrIntMap_clear, _swig_p) + return +} + +func (arg1 SwigcptrStructPtrIntMap) Clear() { + _swig_wrap_StructPtrIntMap_clear(arg1) +} + +var _wrap_StructPtrIntMap_get unsafe.Pointer + +func _swig_wrap_StructPtrIntMap_get(base SwigcptrStructPtrIntMap, _ uintptr) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_StructPtrIntMap_get, _swig_p) + return +} + +func (arg1 SwigcptrStructPtrIntMap) Get(arg2 Struct) (_swig_ret int) { + return _swig_wrap_StructPtrIntMap_get(arg1, arg2.Swigcptr()) +} + +var _wrap_StructPtrIntMap_set unsafe.Pointer + +func _swig_wrap_StructPtrIntMap_set(base SwigcptrStructPtrIntMap, _ uintptr, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_StructPtrIntMap_set, _swig_p) + return +} + +func (arg1 SwigcptrStructPtrIntMap) Set(arg2 Struct, arg3 int) { + _swig_wrap_StructPtrIntMap_set(arg1, arg2.Swigcptr(), arg3) +} + +var _wrap_StructPtrIntMap_del unsafe.Pointer + +func _swig_wrap_StructPtrIntMap_del(base SwigcptrStructPtrIntMap, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_StructPtrIntMap_del, _swig_p) + return +} + +func (arg1 SwigcptrStructPtrIntMap) Del(arg2 Struct) { + _swig_wrap_StructPtrIntMap_del(arg1, arg2.Swigcptr()) +} + +var _wrap_StructPtrIntMap_has_key unsafe.Pointer + +func _swig_wrap_StructPtrIntMap_has_key(base SwigcptrStructPtrIntMap, _ uintptr) (_ bool) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_StructPtrIntMap_has_key, _swig_p) + return +} + +func (arg1 SwigcptrStructPtrIntMap) Has_key(arg2 Struct) (_swig_ret bool) { + return _swig_wrap_StructPtrIntMap_has_key(arg1, arg2.Swigcptr()) +} + +var _wrap_delete_StructPtrIntMap unsafe.Pointer + +func _swig_wrap_delete_StructPtrIntMap(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_StructPtrIntMap, _swig_p) + return +} + +func DeleteStructPtrIntMap(arg1 StructPtrIntMap) { + _swig_wrap_delete_StructPtrIntMap(arg1.Swigcptr()) +} + +type StructPtrIntMap interface { + Swigcptr() uintptr + SwigIsStructPtrIntMap() + Size() (_swig_ret uint) + Empty() (_swig_ret bool) + Clear() + Get(arg2 Struct) (_swig_ret int) + Set(arg2 Struct, arg3 int) + Del(arg2 Struct) + Has_key(arg2 Struct) (_swig_ret bool) +} + +type SwigcptrStructIntMap uintptr + +func (p SwigcptrStructIntMap) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrStructIntMap) SwigIsStructIntMap() { +} + +var _wrap_new_StructIntMap__SWIG_0 unsafe.Pointer + +func _swig_wrap_new_StructIntMap__SWIG_0() (base SwigcptrStructIntMap) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_StructIntMap__SWIG_0, _swig_p) + return +} + +func NewStructIntMap__SWIG_0() (_swig_ret StructIntMap) { + return _swig_wrap_new_StructIntMap__SWIG_0() +} + +var _wrap_new_StructIntMap__SWIG_1 unsafe.Pointer + +func _swig_wrap_new_StructIntMap__SWIG_1(base uintptr) (_ SwigcptrStructIntMap) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_StructIntMap__SWIG_1, _swig_p) + return +} + +func NewStructIntMap__SWIG_1(arg1 StructIntMap) (_swig_ret StructIntMap) { + return _swig_wrap_new_StructIntMap__SWIG_1(arg1.Swigcptr()) +} + +func NewStructIntMap(a ...interface{}) StructIntMap { + argc := len(a) + if argc == 0 { + return NewStructIntMap__SWIG_0() + } + if argc == 1 { + return NewStructIntMap__SWIG_1(a[0].(StructIntMap)) + } + panic("No match for overloaded function call") +} + +var _wrap_StructIntMap_size unsafe.Pointer + +func _swig_wrap_StructIntMap_size(base SwigcptrStructIntMap) (_ uint) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_StructIntMap_size, _swig_p) + return +} + +func (arg1 SwigcptrStructIntMap) Size() (_swig_ret uint) { + return _swig_wrap_StructIntMap_size(arg1) +} + +var _wrap_StructIntMap_empty unsafe.Pointer + +func _swig_wrap_StructIntMap_empty(base SwigcptrStructIntMap) (_ bool) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_StructIntMap_empty, _swig_p) + return +} + +func (arg1 SwigcptrStructIntMap) Empty() (_swig_ret bool) { + return _swig_wrap_StructIntMap_empty(arg1) +} + +var _wrap_StructIntMap_clear unsafe.Pointer + +func _swig_wrap_StructIntMap_clear(base SwigcptrStructIntMap) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_StructIntMap_clear, _swig_p) + return +} + +func (arg1 SwigcptrStructIntMap) Clear() { + _swig_wrap_StructIntMap_clear(arg1) +} + +var _wrap_StructIntMap_get unsafe.Pointer + +func _swig_wrap_StructIntMap_get(base SwigcptrStructIntMap, _ uintptr) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_StructIntMap_get, _swig_p) + return +} + +func (arg1 SwigcptrStructIntMap) Get(arg2 Struct) (_swig_ret int) { + return _swig_wrap_StructIntMap_get(arg1, arg2.Swigcptr()) +} + +var _wrap_StructIntMap_set unsafe.Pointer + +func _swig_wrap_StructIntMap_set(base SwigcptrStructIntMap, _ uintptr, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_StructIntMap_set, _swig_p) + return +} + +func (arg1 SwigcptrStructIntMap) Set(arg2 Struct, arg3 int) { + _swig_wrap_StructIntMap_set(arg1, arg2.Swigcptr(), arg3) +} + +var _wrap_StructIntMap_del unsafe.Pointer + +func _swig_wrap_StructIntMap_del(base SwigcptrStructIntMap, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_StructIntMap_del, _swig_p) + return +} + +func (arg1 SwigcptrStructIntMap) Del(arg2 Struct) { + _swig_wrap_StructIntMap_del(arg1, arg2.Swigcptr()) +} + +var _wrap_StructIntMap_has_key unsafe.Pointer + +func _swig_wrap_StructIntMap_has_key(base SwigcptrStructIntMap, _ uintptr) (_ bool) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_StructIntMap_has_key, _swig_p) + return +} + +func (arg1 SwigcptrStructIntMap) Has_key(arg2 Struct) (_swig_ret bool) { + return _swig_wrap_StructIntMap_has_key(arg1, arg2.Swigcptr()) +} + +var _wrap_delete_StructIntMap unsafe.Pointer + +func _swig_wrap_delete_StructIntMap(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_StructIntMap, _swig_p) + return +} + +func DeleteStructIntMap(arg1 StructIntMap) { + _swig_wrap_delete_StructIntMap(arg1.Swigcptr()) +} + +type StructIntMap interface { + Swigcptr() uintptr + SwigIsStructIntMap() + Size() (_swig_ret uint) + Empty() (_swig_ret bool) + Clear() + Get(arg2 Struct) (_swig_ret int) + Set(arg2 Struct, arg3 int) + Del(arg2 Struct) + Has_key(arg2 Struct) (_swig_ret bool) +} + +type SwigcptrA uintptr + +func (p SwigcptrA) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrA) SwigIsA() { +} + +var _wrap_A_val_set unsafe.Pointer + +func _swig_wrap_A_val_set(base SwigcptrA, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_A_val_set, _swig_p) + return +} + +func (arg1 SwigcptrA) SetVal(arg2 int) { + _swig_wrap_A_val_set(arg1, arg2) +} + +var _wrap_A_val_get unsafe.Pointer + +func _swig_wrap_A_val_get(base SwigcptrA) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_A_val_get, _swig_p) + return +} + +func (arg1 SwigcptrA) GetVal() (_swig_ret int) { + return _swig_wrap_A_val_get(arg1) +} + +var _wrap_new_A__SWIG_0 unsafe.Pointer + +func _swig_wrap_new_A__SWIG_0(base int) (_ SwigcptrA) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_A__SWIG_0, _swig_p) + return +} + +func NewA__SWIG_0(arg1 int) (_swig_ret A) { + return _swig_wrap_new_A__SWIG_0(arg1) +} + +var _wrap_new_A__SWIG_1 unsafe.Pointer + +func _swig_wrap_new_A__SWIG_1() (base SwigcptrA) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_A__SWIG_1, _swig_p) + return +} + +func NewA__SWIG_1() (_swig_ret A) { + return _swig_wrap_new_A__SWIG_1() +} + +func NewA(a ...interface{}) A { + argc := len(a) + if argc == 0 { + return NewA__SWIG_1() + } + if argc == 1 { + return NewA__SWIG_0(a[0].(int)) + } + panic("No match for overloaded function call") +} + +var _wrap_delete_A unsafe.Pointer + +func _swig_wrap_delete_A(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_A, _swig_p) + return +} + +func DeleteA(arg1 A) { + _swig_wrap_delete_A(arg1.Swigcptr()) +} + +type A interface { + Swigcptr() uintptr + SwigIsA() + SetVal(arg2 int) + GetVal() (_swig_ret int) +} + +type SwigcptrPairii uintptr + +func (p SwigcptrPairii) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrPairii) SwigIsPairii() { +} + +var _wrap_new_pairii__SWIG_0 unsafe.Pointer + +func _swig_wrap_new_pairii__SWIG_0() (base SwigcptrPairii) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_pairii__SWIG_0, _swig_p) + return +} + +func NewPairii__SWIG_0() (_swig_ret Pairii) { + return _swig_wrap_new_pairii__SWIG_0() +} + +var _wrap_new_pairii__SWIG_1 unsafe.Pointer + +func _swig_wrap_new_pairii__SWIG_1(base int, _ int) (_ SwigcptrPairii) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_pairii__SWIG_1, _swig_p) + return +} + +func NewPairii__SWIG_1(arg1 int, arg2 int) (_swig_ret Pairii) { + return _swig_wrap_new_pairii__SWIG_1(arg1, arg2) +} + +var _wrap_new_pairii__SWIG_2 unsafe.Pointer + +func _swig_wrap_new_pairii__SWIG_2(base uintptr) (_ SwigcptrPairii) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_pairii__SWIG_2, _swig_p) + return +} + +func NewPairii__SWIG_2(arg1 Pairii) (_swig_ret Pairii) { + return _swig_wrap_new_pairii__SWIG_2(arg1.Swigcptr()) +} + +func NewPairii(a ...interface{}) Pairii { + argc := len(a) + if argc == 0 { + return NewPairii__SWIG_0() + } + if argc == 1 { + return NewPairii__SWIG_2(a[0].(Pairii)) + } + if argc == 2 { + return NewPairii__SWIG_1(a[0].(int), a[1].(int)) + } + panic("No match for overloaded function call") +} + +var _wrap_pairii_first_set unsafe.Pointer + +func _swig_wrap_pairii_first_set(base SwigcptrPairii, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_pairii_first_set, _swig_p) + return +} + +func (arg1 SwigcptrPairii) SetFirst(arg2 int) { + _swig_wrap_pairii_first_set(arg1, arg2) +} + +var _wrap_pairii_first_get unsafe.Pointer + +func _swig_wrap_pairii_first_get(base SwigcptrPairii) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_pairii_first_get, _swig_p) + return +} + +func (arg1 SwigcptrPairii) GetFirst() (_swig_ret int) { + return _swig_wrap_pairii_first_get(arg1) +} + +var _wrap_pairii_second_set unsafe.Pointer + +func _swig_wrap_pairii_second_set(base SwigcptrPairii, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_pairii_second_set, _swig_p) + return +} + +func (arg1 SwigcptrPairii) SetSecond(arg2 int) { + _swig_wrap_pairii_second_set(arg1, arg2) +} + +var _wrap_pairii_second_get unsafe.Pointer + +func _swig_wrap_pairii_second_get(base SwigcptrPairii) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_pairii_second_get, _swig_p) + return +} + +func (arg1 SwigcptrPairii) GetSecond() (_swig_ret int) { + return _swig_wrap_pairii_second_get(arg1) +} + +var _wrap_delete_pairii unsafe.Pointer + +func _swig_wrap_delete_pairii(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_pairii, _swig_p) + return +} + +func DeletePairii(arg1 Pairii) { + _swig_wrap_delete_pairii(arg1.Swigcptr()) +} + +type Pairii interface { + Swigcptr() uintptr + SwigIsPairii() + SetFirst(arg2 int) + GetFirst() (_swig_ret int) + SetSecond(arg2 int) + GetSecond() (_swig_ret int) +} + +type SwigcptrPairAA uintptr + +func (p SwigcptrPairAA) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrPairAA) SwigIsPairAA() { +} + +var _wrap_new_pairAA__SWIG_0 unsafe.Pointer + +func _swig_wrap_new_pairAA__SWIG_0() (base SwigcptrPairAA) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_pairAA__SWIG_0, _swig_p) + return +} + +func NewPairAA__SWIG_0() (_swig_ret PairAA) { + return _swig_wrap_new_pairAA__SWIG_0() +} + +var _wrap_new_pairAA__SWIG_1 unsafe.Pointer + +func _swig_wrap_new_pairAA__SWIG_1(base int, _ uintptr) (_ SwigcptrPairAA) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_pairAA__SWIG_1, _swig_p) + return +} + +func NewPairAA__SWIG_1(arg1 int, arg2 A) (_swig_ret PairAA) { + return _swig_wrap_new_pairAA__SWIG_1(arg1, arg2.Swigcptr()) +} + +var _wrap_new_pairAA__SWIG_2 unsafe.Pointer + +func _swig_wrap_new_pairAA__SWIG_2(base uintptr) (_ SwigcptrPairAA) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_pairAA__SWIG_2, _swig_p) + return +} + +func NewPairAA__SWIG_2(arg1 PairAA) (_swig_ret PairAA) { + return _swig_wrap_new_pairAA__SWIG_2(arg1.Swigcptr()) +} + +func NewPairAA(a ...interface{}) PairAA { + argc := len(a) + if argc == 0 { + return NewPairAA__SWIG_0() + } + if argc == 1 { + return NewPairAA__SWIG_2(a[0].(PairAA)) + } + if argc == 2 { + return NewPairAA__SWIG_1(a[0].(int), a[1].(A)) + } + panic("No match for overloaded function call") +} + +var _wrap_pairAA_first_set unsafe.Pointer + +func _swig_wrap_pairAA_first_set(base SwigcptrPairAA, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_pairAA_first_set, _swig_p) + return +} + +func (arg1 SwigcptrPairAA) SetFirst(arg2 int) { + _swig_wrap_pairAA_first_set(arg1, arg2) +} + +var _wrap_pairAA_first_get unsafe.Pointer + +func _swig_wrap_pairAA_first_get(base SwigcptrPairAA) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_pairAA_first_get, _swig_p) + return +} + +func (arg1 SwigcptrPairAA) GetFirst() (_swig_ret int) { + return _swig_wrap_pairAA_first_get(arg1) +} + +var _wrap_pairAA_second_set unsafe.Pointer + +func _swig_wrap_pairAA_second_set(base SwigcptrPairAA, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_pairAA_second_set, _swig_p) + return +} + +func (arg1 SwigcptrPairAA) SetSecond(arg2 A) { + _swig_wrap_pairAA_second_set(arg1, arg2.Swigcptr()) +} + +var _wrap_pairAA_second_get unsafe.Pointer + +func _swig_wrap_pairAA_second_get(base SwigcptrPairAA) (_ SwigcptrA) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_pairAA_second_get, _swig_p) + return +} + +func (arg1 SwigcptrPairAA) GetSecond() (_swig_ret A) { + return _swig_wrap_pairAA_second_get(arg1) +} + +var _wrap_delete_pairAA unsafe.Pointer + +func _swig_wrap_delete_pairAA(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_pairAA, _swig_p) + return +} + +func DeletePairAA(arg1 PairAA) { + _swig_wrap_delete_pairAA(arg1.Swigcptr()) +} + +type PairAA interface { + Swigcptr() uintptr + SwigIsPairAA() + SetFirst(arg2 int) + GetFirst() (_swig_ret int) + SetSecond(arg2 A) + GetSecond() (_swig_ret A) +} + +type SwigcptrPairA uintptr + +func (p SwigcptrPairA) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrPairA) SwigIsPairA() { +} + +var _wrap_new_pairA__SWIG_0 unsafe.Pointer + +func _swig_wrap_new_pairA__SWIG_0() (base SwigcptrPairA) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_pairA__SWIG_0, _swig_p) + return +} + +func NewPairA__SWIG_0() (_swig_ret PairA) { + return _swig_wrap_new_pairA__SWIG_0() +} + +var _wrap_new_pairA__SWIG_1 unsafe.Pointer + +func _swig_wrap_new_pairA__SWIG_1(base int, _ uintptr) (_ SwigcptrPairA) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_pairA__SWIG_1, _swig_p) + return +} + +func NewPairA__SWIG_1(arg1 int, arg2 A) (_swig_ret PairA) { + return _swig_wrap_new_pairA__SWIG_1(arg1, arg2.Swigcptr()) +} + +var _wrap_new_pairA__SWIG_2 unsafe.Pointer + +func _swig_wrap_new_pairA__SWIG_2(base uintptr) (_ SwigcptrPairA) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_pairA__SWIG_2, _swig_p) + return +} + +func NewPairA__SWIG_2(arg1 PairA) (_swig_ret PairA) { + return _swig_wrap_new_pairA__SWIG_2(arg1.Swigcptr()) +} + +func NewPairA(a ...interface{}) PairA { + argc := len(a) + if argc == 0 { + return NewPairA__SWIG_0() + } + if argc == 1 { + return NewPairA__SWIG_2(a[0].(PairA)) + } + if argc == 2 { + return NewPairA__SWIG_1(a[0].(int), a[1].(A)) + } + panic("No match for overloaded function call") +} + +var _wrap_pairA_first_set unsafe.Pointer + +func _swig_wrap_pairA_first_set(base SwigcptrPairA, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_pairA_first_set, _swig_p) + return +} + +func (arg1 SwigcptrPairA) SetFirst(arg2 int) { + _swig_wrap_pairA_first_set(arg1, arg2) +} + +var _wrap_pairA_first_get unsafe.Pointer + +func _swig_wrap_pairA_first_get(base SwigcptrPairA) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_pairA_first_get, _swig_p) + return +} + +func (arg1 SwigcptrPairA) GetFirst() (_swig_ret int) { + return _swig_wrap_pairA_first_get(arg1) +} + +var _wrap_pairA_second_set unsafe.Pointer + +func _swig_wrap_pairA_second_set(base SwigcptrPairA, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_pairA_second_set, _swig_p) + return +} + +func (arg1 SwigcptrPairA) SetSecond(arg2 A) { + _swig_wrap_pairA_second_set(arg1, arg2.Swigcptr()) +} + +var _wrap_pairA_second_get unsafe.Pointer + +func _swig_wrap_pairA_second_get(base SwigcptrPairA) (_ SwigcptrA) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_pairA_second_get, _swig_p) + return +} + +func (arg1 SwigcptrPairA) GetSecond() (_swig_ret A) { + return _swig_wrap_pairA_second_get(arg1) +} + +var _wrap_delete_pairA unsafe.Pointer + +func _swig_wrap_delete_pairA(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_pairA, _swig_p) + return +} + +func DeletePairA(arg1 PairA) { + _swig_wrap_delete_pairA(arg1.Swigcptr()) +} + +type PairA interface { + Swigcptr() uintptr + SwigIsPairA() + SetFirst(arg2 int) + GetFirst() (_swig_ret int) + SetSecond(arg2 A) + GetSecond() (_swig_ret A) +} + +type SwigcptrMapA uintptr + +func (p SwigcptrMapA) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrMapA) SwigIsMapA() { +} + +var _wrap_new_mapA__SWIG_0 unsafe.Pointer + +func _swig_wrap_new_mapA__SWIG_0() (base SwigcptrMapA) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_mapA__SWIG_0, _swig_p) + return +} + +func NewMapA__SWIG_0() (_swig_ret MapA) { + return _swig_wrap_new_mapA__SWIG_0() +} + +var _wrap_new_mapA__SWIG_1 unsafe.Pointer + +func _swig_wrap_new_mapA__SWIG_1(base uintptr) (_ SwigcptrMapA) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_mapA__SWIG_1, _swig_p) + return +} + +func NewMapA__SWIG_1(arg1 MapA) (_swig_ret MapA) { + return _swig_wrap_new_mapA__SWIG_1(arg1.Swigcptr()) +} + +func NewMapA(a ...interface{}) MapA { + argc := len(a) + if argc == 0 { + return NewMapA__SWIG_0() + } + if argc == 1 { + return NewMapA__SWIG_1(a[0].(MapA)) + } + panic("No match for overloaded function call") +} + +var _wrap_mapA_size unsafe.Pointer + +func _swig_wrap_mapA_size(base SwigcptrMapA) (_ uint) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_mapA_size, _swig_p) + return +} + +func (arg1 SwigcptrMapA) Size() (_swig_ret uint) { + return _swig_wrap_mapA_size(arg1) +} + +var _wrap_mapA_empty unsafe.Pointer + +func _swig_wrap_mapA_empty(base SwigcptrMapA) (_ bool) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_mapA_empty, _swig_p) + return +} + +func (arg1 SwigcptrMapA) Empty() (_swig_ret bool) { + return _swig_wrap_mapA_empty(arg1) +} + +var _wrap_mapA_clear unsafe.Pointer + +func _swig_wrap_mapA_clear(base SwigcptrMapA) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_mapA_clear, _swig_p) + return +} + +func (arg1 SwigcptrMapA) Clear() { + _swig_wrap_mapA_clear(arg1) +} + +var _wrap_mapA_get unsafe.Pointer + +func _swig_wrap_mapA_get(base SwigcptrMapA, _ int) (_ SwigcptrA) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_mapA_get, _swig_p) + return +} + +func (arg1 SwigcptrMapA) Get(arg2 int) (_swig_ret A) { + return _swig_wrap_mapA_get(arg1, arg2) +} + +var _wrap_mapA_set unsafe.Pointer + +func _swig_wrap_mapA_set(base SwigcptrMapA, _ int, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_mapA_set, _swig_p) + return +} + +func (arg1 SwigcptrMapA) Set(arg2 int, arg3 A) { + _swig_wrap_mapA_set(arg1, arg2, arg3.Swigcptr()) +} + +var _wrap_mapA_del unsafe.Pointer + +func _swig_wrap_mapA_del(base SwigcptrMapA, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_mapA_del, _swig_p) + return +} + +func (arg1 SwigcptrMapA) Del(arg2 int) { + _swig_wrap_mapA_del(arg1, arg2) +} + +var _wrap_mapA_has_key unsafe.Pointer + +func _swig_wrap_mapA_has_key(base SwigcptrMapA, _ int) (_ bool) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_mapA_has_key, _swig_p) + return +} + +func (arg1 SwigcptrMapA) Has_key(arg2 int) (_swig_ret bool) { + return _swig_wrap_mapA_has_key(arg1, arg2) +} + +var _wrap_delete_mapA unsafe.Pointer + +func _swig_wrap_delete_mapA(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_mapA, _swig_p) + return +} + +func DeleteMapA(arg1 MapA) { + _swig_wrap_delete_mapA(arg1.Swigcptr()) +} + +type MapA interface { + Swigcptr() uintptr + SwigIsMapA() + Size() (_swig_ret uint) + Empty() (_swig_ret bool) + Clear() + Get(arg2 int) (_swig_ret A) + Set(arg2 int, arg3 A) + Del(arg2 int) + Has_key(arg2 int) (_swig_ret bool) +} + +type SwigcptrPaircA1 uintptr + +func (p SwigcptrPaircA1) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrPaircA1) SwigIsPaircA1() { +} + +var _wrap_new_paircA1__SWIG_0 unsafe.Pointer + +func _swig_wrap_new_paircA1__SWIG_0() (base SwigcptrPaircA1) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_paircA1__SWIG_0, _swig_p) + return +} + +func NewPaircA1__SWIG_0() (_swig_ret PaircA1) { + return _swig_wrap_new_paircA1__SWIG_0() +} + +var _wrap_new_paircA1__SWIG_1 unsafe.Pointer + +func _swig_wrap_new_paircA1__SWIG_1(base int, _ uintptr) (_ SwigcptrPaircA1) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_paircA1__SWIG_1, _swig_p) + return +} + +func NewPaircA1__SWIG_1(arg1 int, arg2 A) (_swig_ret PaircA1) { + return _swig_wrap_new_paircA1__SWIG_1(arg1, arg2.Swigcptr()) +} + +var _wrap_new_paircA1__SWIG_2 unsafe.Pointer + +func _swig_wrap_new_paircA1__SWIG_2(base uintptr) (_ SwigcptrPaircA1) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_paircA1__SWIG_2, _swig_p) + return +} + +func NewPaircA1__SWIG_2(arg1 PaircA1) (_swig_ret PaircA1) { + return _swig_wrap_new_paircA1__SWIG_2(arg1.Swigcptr()) +} + +func NewPaircA1(a ...interface{}) PaircA1 { + argc := len(a) + if argc == 0 { + return NewPaircA1__SWIG_0() + } + if argc == 1 { + return NewPaircA1__SWIG_2(a[0].(PaircA1)) + } + if argc == 2 { + return NewPaircA1__SWIG_1(a[0].(int), a[1].(A)) + } + panic("No match for overloaded function call") +} + +var _wrap_paircA1_first_get unsafe.Pointer + +func _swig_wrap_paircA1_first_get(base SwigcptrPaircA1) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_paircA1_first_get, _swig_p) + return +} + +func (arg1 SwigcptrPaircA1) GetFirst() (_swig_ret int) { + return _swig_wrap_paircA1_first_get(arg1) +} + +var _wrap_paircA1_second_set unsafe.Pointer + +func _swig_wrap_paircA1_second_set(base SwigcptrPaircA1, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_paircA1_second_set, _swig_p) + return +} + +func (arg1 SwigcptrPaircA1) SetSecond(arg2 A) { + _swig_wrap_paircA1_second_set(arg1, arg2.Swigcptr()) +} + +var _wrap_paircA1_second_get unsafe.Pointer + +func _swig_wrap_paircA1_second_get(base SwigcptrPaircA1) (_ SwigcptrA) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_paircA1_second_get, _swig_p) + return +} + +func (arg1 SwigcptrPaircA1) GetSecond() (_swig_ret A) { + return _swig_wrap_paircA1_second_get(arg1) +} + +var _wrap_delete_paircA1 unsafe.Pointer + +func _swig_wrap_delete_paircA1(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_paircA1, _swig_p) + return +} + +func DeletePaircA1(arg1 PaircA1) { + _swig_wrap_delete_paircA1(arg1.Swigcptr()) +} + +type PaircA1 interface { + Swigcptr() uintptr + SwigIsPaircA1() + GetFirst() (_swig_ret int) + SetSecond(arg2 A) + GetSecond() (_swig_ret A) +} + +type SwigcptrPaircA2 uintptr + +func (p SwigcptrPaircA2) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrPaircA2) SwigIsPaircA2() { +} + +var _wrap_new_paircA2__SWIG_0 unsafe.Pointer + +func _swig_wrap_new_paircA2__SWIG_0() (base SwigcptrPaircA2) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_paircA2__SWIG_0, _swig_p) + return +} + +func NewPaircA2__SWIG_0() (_swig_ret PaircA2) { + return _swig_wrap_new_paircA2__SWIG_0() +} + +var _wrap_new_paircA2__SWIG_1 unsafe.Pointer + +func _swig_wrap_new_paircA2__SWIG_1(base int, _ uintptr) (_ SwigcptrPaircA2) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_paircA2__SWIG_1, _swig_p) + return +} + +func NewPaircA2__SWIG_1(arg1 int, arg2 A) (_swig_ret PaircA2) { + return _swig_wrap_new_paircA2__SWIG_1(arg1, arg2.Swigcptr()) +} + +var _wrap_new_paircA2__SWIG_2 unsafe.Pointer + +func _swig_wrap_new_paircA2__SWIG_2(base uintptr) (_ SwigcptrPaircA2) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_paircA2__SWIG_2, _swig_p) + return +} + +func NewPaircA2__SWIG_2(arg1 PaircA2) (_swig_ret PaircA2) { + return _swig_wrap_new_paircA2__SWIG_2(arg1.Swigcptr()) +} + +func NewPaircA2(a ...interface{}) PaircA2 { + argc := len(a) + if argc == 0 { + return NewPaircA2__SWIG_0() + } + if argc == 1 { + return NewPaircA2__SWIG_2(a[0].(PaircA2)) + } + if argc == 2 { + return NewPaircA2__SWIG_1(a[0].(int), a[1].(A)) + } + panic("No match for overloaded function call") +} + +var _wrap_paircA2_first_get unsafe.Pointer + +func _swig_wrap_paircA2_first_get(base SwigcptrPaircA2) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_paircA2_first_get, _swig_p) + return +} + +func (arg1 SwigcptrPaircA2) GetFirst() (_swig_ret int) { + return _swig_wrap_paircA2_first_get(arg1) +} + +var _wrap_paircA2_second_set unsafe.Pointer + +func _swig_wrap_paircA2_second_set(base SwigcptrPaircA2, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_paircA2_second_set, _swig_p) + return +} + +func (arg1 SwigcptrPaircA2) SetSecond(arg2 A) { + _swig_wrap_paircA2_second_set(arg1, arg2.Swigcptr()) +} + +var _wrap_paircA2_second_get unsafe.Pointer + +func _swig_wrap_paircA2_second_get(base SwigcptrPaircA2) (_ SwigcptrA) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_paircA2_second_get, _swig_p) + return +} + +func (arg1 SwigcptrPaircA2) GetSecond() (_swig_ret A) { + return _swig_wrap_paircA2_second_get(arg1) +} + +var _wrap_delete_paircA2 unsafe.Pointer + +func _swig_wrap_delete_paircA2(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_paircA2, _swig_p) + return +} + +func DeletePaircA2(arg1 PaircA2) { + _swig_wrap_delete_paircA2(arg1.Swigcptr()) +} + +type PaircA2 interface { + Swigcptr() uintptr + SwigIsPaircA2() + GetFirst() (_swig_ret int) + SetSecond(arg2 A) + GetSecond() (_swig_ret A) +} + +type SwigcptrPairiiA uintptr + +func (p SwigcptrPairiiA) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrPairiiA) SwigIsPairiiA() { +} + +var _wrap_new_pairiiA__SWIG_0 unsafe.Pointer + +func _swig_wrap_new_pairiiA__SWIG_0() (base SwigcptrPairiiA) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_pairiiA__SWIG_0, _swig_p) + return +} + +func NewPairiiA__SWIG_0() (_swig_ret PairiiA) { + return _swig_wrap_new_pairiiA__SWIG_0() +} + +var _wrap_new_pairiiA__SWIG_1 unsafe.Pointer + +func _swig_wrap_new_pairiiA__SWIG_1(base int, _ uintptr) (_ SwigcptrPairiiA) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_pairiiA__SWIG_1, _swig_p) + return +} + +func NewPairiiA__SWIG_1(arg1 int, arg2 PairA) (_swig_ret PairiiA) { + return _swig_wrap_new_pairiiA__SWIG_1(arg1, arg2.Swigcptr()) +} + +var _wrap_new_pairiiA__SWIG_2 unsafe.Pointer + +func _swig_wrap_new_pairiiA__SWIG_2(base uintptr) (_ SwigcptrPairiiA) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_pairiiA__SWIG_2, _swig_p) + return +} + +func NewPairiiA__SWIG_2(arg1 PairiiA) (_swig_ret PairiiA) { + return _swig_wrap_new_pairiiA__SWIG_2(arg1.Swigcptr()) +} + +func NewPairiiA(a ...interface{}) PairiiA { + argc := len(a) + if argc == 0 { + return NewPairiiA__SWIG_0() + } + if argc == 1 { + return NewPairiiA__SWIG_2(a[0].(PairiiA)) + } + if argc == 2 { + return NewPairiiA__SWIG_1(a[0].(int), a[1].(PairA)) + } + panic("No match for overloaded function call") +} + +var _wrap_pairiiA_first_set unsafe.Pointer + +func _swig_wrap_pairiiA_first_set(base SwigcptrPairiiA, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_pairiiA_first_set, _swig_p) + return +} + +func (arg1 SwigcptrPairiiA) SetFirst(arg2 int) { + _swig_wrap_pairiiA_first_set(arg1, arg2) +} + +var _wrap_pairiiA_first_get unsafe.Pointer + +func _swig_wrap_pairiiA_first_get(base SwigcptrPairiiA) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_pairiiA_first_get, _swig_p) + return +} + +func (arg1 SwigcptrPairiiA) GetFirst() (_swig_ret int) { + return _swig_wrap_pairiiA_first_get(arg1) +} + +var _wrap_pairiiA_second_set unsafe.Pointer + +func _swig_wrap_pairiiA_second_set(base SwigcptrPairiiA, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_pairiiA_second_set, _swig_p) + return +} + +func (arg1 SwigcptrPairiiA) SetSecond(arg2 PairA) { + _swig_wrap_pairiiA_second_set(arg1, arg2.Swigcptr()) +} + +var _wrap_pairiiA_second_get unsafe.Pointer + +func _swig_wrap_pairiiA_second_get(base SwigcptrPairiiA) (_ SwigcptrPairA) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_pairiiA_second_get, _swig_p) + return +} + +func (arg1 SwigcptrPairiiA) GetSecond() (_swig_ret PairA) { + return _swig_wrap_pairiiA_second_get(arg1) +} + +var _wrap_delete_pairiiA unsafe.Pointer + +func _swig_wrap_delete_pairiiA(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_pairiiA, _swig_p) + return +} + +func DeletePairiiA(arg1 PairiiA) { + _swig_wrap_delete_pairiiA(arg1.Swigcptr()) +} + +type PairiiA interface { + Swigcptr() uintptr + SwigIsPairiiA() + SetFirst(arg2 int) + GetFirst() (_swig_ret int) + SetSecond(arg2 PairA) + GetSecond() (_swig_ret PairA) +} + +type SwigcptrPairiiAc uintptr + +func (p SwigcptrPairiiAc) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrPairiiAc) SwigIsPairiiAc() { +} + +var _wrap_new_pairiiAc__SWIG_0 unsafe.Pointer + +func _swig_wrap_new_pairiiAc__SWIG_0() (base SwigcptrPairiiAc) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_pairiiAc__SWIG_0, _swig_p) + return +} + +func NewPairiiAc__SWIG_0() (_swig_ret PairiiAc) { + return _swig_wrap_new_pairiiAc__SWIG_0() +} + +var _wrap_new_pairiiAc__SWIG_1 unsafe.Pointer + +func _swig_wrap_new_pairiiAc__SWIG_1(base int, _ uintptr) (_ SwigcptrPairiiAc) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_pairiiAc__SWIG_1, _swig_p) + return +} + +func NewPairiiAc__SWIG_1(arg1 int, arg2 PairA) (_swig_ret PairiiAc) { + return _swig_wrap_new_pairiiAc__SWIG_1(arg1, arg2.Swigcptr()) +} + +var _wrap_new_pairiiAc__SWIG_2 unsafe.Pointer + +func _swig_wrap_new_pairiiAc__SWIG_2(base uintptr) (_ SwigcptrPairiiAc) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_pairiiAc__SWIG_2, _swig_p) + return +} + +func NewPairiiAc__SWIG_2(arg1 PairiiAc) (_swig_ret PairiiAc) { + return _swig_wrap_new_pairiiAc__SWIG_2(arg1.Swigcptr()) +} + +func NewPairiiAc(a ...interface{}) PairiiAc { + argc := len(a) + if argc == 0 { + return NewPairiiAc__SWIG_0() + } + if argc == 1 { + return NewPairiiAc__SWIG_2(a[0].(PairiiAc)) + } + if argc == 2 { + return NewPairiiAc__SWIG_1(a[0].(int), a[1].(PairA)) + } + panic("No match for overloaded function call") +} + +var _wrap_pairiiAc_first_set unsafe.Pointer + +func _swig_wrap_pairiiAc_first_set(base SwigcptrPairiiAc, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_pairiiAc_first_set, _swig_p) + return +} + +func (arg1 SwigcptrPairiiAc) SetFirst(arg2 int) { + _swig_wrap_pairiiAc_first_set(arg1, arg2) +} + +var _wrap_pairiiAc_first_get unsafe.Pointer + +func _swig_wrap_pairiiAc_first_get(base SwigcptrPairiiAc) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_pairiiAc_first_get, _swig_p) + return +} + +func (arg1 SwigcptrPairiiAc) GetFirst() (_swig_ret int) { + return _swig_wrap_pairiiAc_first_get(arg1) +} + +var _wrap_pairiiAc_second_get unsafe.Pointer + +func _swig_wrap_pairiiAc_second_get(base SwigcptrPairiiAc) (_ SwigcptrPairA) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_pairiiAc_second_get, _swig_p) + return +} + +func (arg1 SwigcptrPairiiAc) GetSecond() (_swig_ret PairA) { + return _swig_wrap_pairiiAc_second_get(arg1) +} + +var _wrap_delete_pairiiAc unsafe.Pointer + +func _swig_wrap_delete_pairiiAc(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_pairiiAc, _swig_p) + return +} + +func DeletePairiiAc(arg1 PairiiAc) { + _swig_wrap_delete_pairiiAc(arg1.Swigcptr()) +} + +type PairiiAc interface { + Swigcptr() uintptr + SwigIsPairiiAc() + SetFirst(arg2 int) + GetFirst() (_swig_ret int) + GetSecond() (_swig_ret PairA) +} + +var _wrap_p_identa unsafe.Pointer + +func _swig_wrap_p_identa(base uintptr) (_ SwigcptrPairA) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_p_identa, _swig_p) + return +} + +func P_identa(arg1 PairA) (_swig_ret PairA) { + return _swig_wrap_p_identa(arg1.Swigcptr()) +} + +var _wrap_m_identa unsafe.Pointer + +func _swig_wrap_m_identa(base uintptr) (_ SwigcptrMapA) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_m_identa, _swig_p) + return +} + +func M_identa(arg1 MapA) (_swig_ret MapA) { + return _swig_wrap_m_identa(arg1.Swigcptr()) +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/li_std_map_runme b/Examples/test-suite/go/li_std_map_runme new file mode 100755 index 000000000..ab7aa0af1 Binary files /dev/null and b/Examples/test-suite/go/li_std_map_runme differ diff --git a/Examples/test-suite/go/li_std_pair.go b/Examples/test-suite/go/li_std_pair.go new file mode 100644 index 000000000..fba461400 --- /dev/null +++ b/Examples/test-suite/go/li_std_pair.go @@ -0,0 +1,249 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../li_std_pair.i + +package li_std_pair + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrIntPair uintptr + +func (p SwigcptrIntPair) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrIntPair) SwigIsIntPair() { +} + +var _wrap_new_IntPair__SWIG_0 unsafe.Pointer + +func _swig_wrap_new_IntPair__SWIG_0() (base SwigcptrIntPair) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_IntPair__SWIG_0, _swig_p) + return +} + +func NewIntPair__SWIG_0() (_swig_ret IntPair) { + return _swig_wrap_new_IntPair__SWIG_0() +} + +var _wrap_new_IntPair__SWIG_1 unsafe.Pointer + +func _swig_wrap_new_IntPair__SWIG_1(base int, _ int) (_ SwigcptrIntPair) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_IntPair__SWIG_1, _swig_p) + return +} + +func NewIntPair__SWIG_1(arg1 int, arg2 int) (_swig_ret IntPair) { + return _swig_wrap_new_IntPair__SWIG_1(arg1, arg2) +} + +var _wrap_new_IntPair__SWIG_2 unsafe.Pointer + +func _swig_wrap_new_IntPair__SWIG_2(base uintptr) (_ SwigcptrIntPair) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_IntPair__SWIG_2, _swig_p) + return +} + +func NewIntPair__SWIG_2(arg1 IntPair) (_swig_ret IntPair) { + return _swig_wrap_new_IntPair__SWIG_2(arg1.Swigcptr()) +} + +func NewIntPair(a ...interface{}) IntPair { + argc := len(a) + if argc == 0 { + return NewIntPair__SWIG_0() + } + if argc == 1 { + return NewIntPair__SWIG_2(a[0].(IntPair)) + } + if argc == 2 { + return NewIntPair__SWIG_1(a[0].(int), a[1].(int)) + } + panic("No match for overloaded function call") +} + +var _wrap_IntPair_first_set unsafe.Pointer + +func _swig_wrap_IntPair_first_set(base SwigcptrIntPair, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_IntPair_first_set, _swig_p) + return +} + +func (arg1 SwigcptrIntPair) SetFirst(arg2 int) { + _swig_wrap_IntPair_first_set(arg1, arg2) +} + +var _wrap_IntPair_first_get unsafe.Pointer + +func _swig_wrap_IntPair_first_get(base SwigcptrIntPair) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_IntPair_first_get, _swig_p) + return +} + +func (arg1 SwigcptrIntPair) GetFirst() (_swig_ret int) { + return _swig_wrap_IntPair_first_get(arg1) +} + +var _wrap_IntPair_second_set unsafe.Pointer + +func _swig_wrap_IntPair_second_set(base SwigcptrIntPair, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_IntPair_second_set, _swig_p) + return +} + +func (arg1 SwigcptrIntPair) SetSecond(arg2 int) { + _swig_wrap_IntPair_second_set(arg1, arg2) +} + +var _wrap_IntPair_second_get unsafe.Pointer + +func _swig_wrap_IntPair_second_get(base SwigcptrIntPair) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_IntPair_second_get, _swig_p) + return +} + +func (arg1 SwigcptrIntPair) GetSecond() (_swig_ret int) { + return _swig_wrap_IntPair_second_get(arg1) +} + +var _wrap_delete_IntPair unsafe.Pointer + +func _swig_wrap_delete_IntPair(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_IntPair, _swig_p) + return +} + +func DeleteIntPair(arg1 IntPair) { + _swig_wrap_delete_IntPair(arg1.Swigcptr()) +} + +type IntPair interface { + Swigcptr() uintptr + SwigIsIntPair() + SetFirst(arg2 int) + GetFirst() (_swig_ret int) + SetSecond(arg2 int) + GetSecond() (_swig_ret int) +} + +var _wrap_makeIntPair unsafe.Pointer + +func _swig_wrap_makeIntPair(base int, _ int) (_ SwigcptrIntPair) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_makeIntPair, _swig_p) + return +} + +func MakeIntPair(arg1 int, arg2 int) (_swig_ret IntPair) { + return _swig_wrap_makeIntPair(arg1, arg2) +} + +var _wrap_makeIntPairPtr unsafe.Pointer + +func _swig_wrap_makeIntPairPtr(base int, _ int) (_ SwigcptrIntPair) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_makeIntPairPtr, _swig_p) + return +} + +func MakeIntPairPtr(arg1 int, arg2 int) (_swig_ret IntPair) { + return _swig_wrap_makeIntPairPtr(arg1, arg2) +} + +var _wrap_makeIntPairRef unsafe.Pointer + +func _swig_wrap_makeIntPairRef(base int, _ int) (_ SwigcptrIntPair) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_makeIntPairRef, _swig_p) + return +} + +func MakeIntPairRef(arg1 int, arg2 int) (_swig_ret IntPair) { + return _swig_wrap_makeIntPairRef(arg1, arg2) +} + +var _wrap_makeIntPairConstRef unsafe.Pointer + +func _swig_wrap_makeIntPairConstRef(base int, _ int) (_ SwigcptrIntPair) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_makeIntPairConstRef, _swig_p) + return +} + +func MakeIntPairConstRef(arg1 int, arg2 int) (_swig_ret IntPair) { + return _swig_wrap_makeIntPairConstRef(arg1, arg2) +} + +var _wrap_product1 unsafe.Pointer + +func _swig_wrap_product1(base uintptr) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_product1, _swig_p) + return +} + +func Product1(arg1 IntPair) (_swig_ret int) { + return _swig_wrap_product1(arg1.Swigcptr()) +} + +var _wrap_product2 unsafe.Pointer + +func _swig_wrap_product2(base uintptr) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_product2, _swig_p) + return +} + +func Product2(arg1 IntPair) (_swig_ret int) { + return _swig_wrap_product2(arg1.Swigcptr()) +} + +var _wrap_product3 unsafe.Pointer + +func _swig_wrap_product3(base uintptr) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_product3, _swig_p) + return +} + +func Product3(arg1 IntPair) (_swig_ret int) { + return _swig_wrap_product3(arg1.Swigcptr()) +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/li_std_pair_using.go b/Examples/test-suite/go/li_std_pair_using.go new file mode 100644 index 000000000..8ae4917a5 --- /dev/null +++ b/Examples/test-suite/go/li_std_pair_using.go @@ -0,0 +1,305 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../li_std_pair_using.i + +package li_std_pair_using + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrStringStringPair uintptr + +func (p SwigcptrStringStringPair) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrStringStringPair) SwigIsStringStringPair() { +} + +var _wrap_new_StringStringPair__SWIG_0 unsafe.Pointer + +func _swig_wrap_new_StringStringPair__SWIG_0() (base SwigcptrStringStringPair) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_StringStringPair__SWIG_0, _swig_p) + return +} + +func NewStringStringPair__SWIG_0() (_swig_ret StringStringPair) { + return _swig_wrap_new_StringStringPair__SWIG_0() +} + +var _wrap_new_StringStringPair__SWIG_1 unsafe.Pointer + +func _swig_wrap_new_StringStringPair__SWIG_1(base string, _ string) (_ SwigcptrStringStringPair) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_StringStringPair__SWIG_1, _swig_p) + return +} + +func NewStringStringPair__SWIG_1(arg1 string, arg2 string) (_swig_ret StringStringPair) { + return _swig_wrap_new_StringStringPair__SWIG_1(arg1, arg2) +} + +var _wrap_new_StringStringPair__SWIG_2 unsafe.Pointer + +func _swig_wrap_new_StringStringPair__SWIG_2(base uintptr) (_ SwigcptrStringStringPair) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_StringStringPair__SWIG_2, _swig_p) + return +} + +func NewStringStringPair__SWIG_2(arg1 StringStringPair) (_swig_ret StringStringPair) { + return _swig_wrap_new_StringStringPair__SWIG_2(arg1.Swigcptr()) +} + +func NewStringStringPair(a ...interface{}) StringStringPair { + argc := len(a) + if argc == 0 { + return NewStringStringPair__SWIG_0() + } + if argc == 1 { + return NewStringStringPair__SWIG_2(a[0].(StringStringPair)) + } + if argc == 2 { + return NewStringStringPair__SWIG_1(a[0].(string), a[1].(string)) + } + panic("No match for overloaded function call") +} + +var _wrap_StringStringPair_first_set unsafe.Pointer + +func _swig_wrap_StringStringPair_first_set(base SwigcptrStringStringPair, _ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_StringStringPair_first_set, _swig_p) + return +} + +func (arg1 SwigcptrStringStringPair) SetFirst(arg2 string) { + _swig_wrap_StringStringPair_first_set(arg1, arg2) +} + +var _wrap_StringStringPair_first_get unsafe.Pointer + +func _swig_wrap_StringStringPair_first_get(base SwigcptrStringStringPair) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_StringStringPair_first_get, _swig_p) + return +} + +func (arg1 SwigcptrStringStringPair) GetFirst() (_swig_ret string) { + return _swig_wrap_StringStringPair_first_get(arg1) +} + +var _wrap_StringStringPair_second_set unsafe.Pointer + +func _swig_wrap_StringStringPair_second_set(base SwigcptrStringStringPair, _ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_StringStringPair_second_set, _swig_p) + return +} + +func (arg1 SwigcptrStringStringPair) SetSecond(arg2 string) { + _swig_wrap_StringStringPair_second_set(arg1, arg2) +} + +var _wrap_StringStringPair_second_get unsafe.Pointer + +func _swig_wrap_StringStringPair_second_get(base SwigcptrStringStringPair) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_StringStringPair_second_get, _swig_p) + return +} + +func (arg1 SwigcptrStringStringPair) GetSecond() (_swig_ret string) { + return _swig_wrap_StringStringPair_second_get(arg1) +} + +var _wrap_delete_StringStringPair unsafe.Pointer + +func _swig_wrap_delete_StringStringPair(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_StringStringPair, _swig_p) + return +} + +func DeleteStringStringPair(arg1 StringStringPair) { + _swig_wrap_delete_StringStringPair(arg1.Swigcptr()) +} + +type StringStringPair interface { + Swigcptr() uintptr + SwigIsStringStringPair() + SetFirst(arg2 string) + GetFirst() (_swig_ret string) + SetSecond(arg2 string) + GetSecond() (_swig_ret string) +} + +type SwigcptrStringIntPair uintptr + +func (p SwigcptrStringIntPair) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrStringIntPair) SwigIsStringIntPair() { +} + +var _wrap_new_StringIntPair__SWIG_0 unsafe.Pointer + +func _swig_wrap_new_StringIntPair__SWIG_0() (base SwigcptrStringIntPair) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_StringIntPair__SWIG_0, _swig_p) + return +} + +func NewStringIntPair__SWIG_0() (_swig_ret StringIntPair) { + return _swig_wrap_new_StringIntPair__SWIG_0() +} + +var _wrap_new_StringIntPair__SWIG_1 unsafe.Pointer + +func _swig_wrap_new_StringIntPair__SWIG_1(base string, _ int) (_ SwigcptrStringIntPair) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_StringIntPair__SWIG_1, _swig_p) + return +} + +func NewStringIntPair__SWIG_1(arg1 string, arg2 int) (_swig_ret StringIntPair) { + return _swig_wrap_new_StringIntPair__SWIG_1(arg1, arg2) +} + +var _wrap_new_StringIntPair__SWIG_2 unsafe.Pointer + +func _swig_wrap_new_StringIntPair__SWIG_2(base uintptr) (_ SwigcptrStringIntPair) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_StringIntPair__SWIG_2, _swig_p) + return +} + +func NewStringIntPair__SWIG_2(arg1 StringIntPair) (_swig_ret StringIntPair) { + return _swig_wrap_new_StringIntPair__SWIG_2(arg1.Swigcptr()) +} + +func NewStringIntPair(a ...interface{}) StringIntPair { + argc := len(a) + if argc == 0 { + return NewStringIntPair__SWIG_0() + } + if argc == 1 { + return NewStringIntPair__SWIG_2(a[0].(StringIntPair)) + } + if argc == 2 { + return NewStringIntPair__SWIG_1(a[0].(string), a[1].(int)) + } + panic("No match for overloaded function call") +} + +var _wrap_StringIntPair_first_set unsafe.Pointer + +func _swig_wrap_StringIntPair_first_set(base SwigcptrStringIntPair, _ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_StringIntPair_first_set, _swig_p) + return +} + +func (arg1 SwigcptrStringIntPair) SetFirst(arg2 string) { + _swig_wrap_StringIntPair_first_set(arg1, arg2) +} + +var _wrap_StringIntPair_first_get unsafe.Pointer + +func _swig_wrap_StringIntPair_first_get(base SwigcptrStringIntPair) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_StringIntPair_first_get, _swig_p) + return +} + +func (arg1 SwigcptrStringIntPair) GetFirst() (_swig_ret string) { + return _swig_wrap_StringIntPair_first_get(arg1) +} + +var _wrap_StringIntPair_second_set unsafe.Pointer + +func _swig_wrap_StringIntPair_second_set(base SwigcptrStringIntPair, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_StringIntPair_second_set, _swig_p) + return +} + +func (arg1 SwigcptrStringIntPair) SetSecond(arg2 int) { + _swig_wrap_StringIntPair_second_set(arg1, arg2) +} + +var _wrap_StringIntPair_second_get unsafe.Pointer + +func _swig_wrap_StringIntPair_second_get(base SwigcptrStringIntPair) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_StringIntPair_second_get, _swig_p) + return +} + +func (arg1 SwigcptrStringIntPair) GetSecond() (_swig_ret int) { + return _swig_wrap_StringIntPair_second_get(arg1) +} + +var _wrap_delete_StringIntPair unsafe.Pointer + +func _swig_wrap_delete_StringIntPair(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_StringIntPair, _swig_p) + return +} + +func DeleteStringIntPair(arg1 StringIntPair) { + _swig_wrap_delete_StringIntPair(arg1.Swigcptr()) +} + +type StringIntPair interface { + Swigcptr() uintptr + SwigIsStringIntPair() + SetFirst(arg2 string) + GetFirst() (_swig_ret string) + SetSecond(arg2 int) + GetSecond() (_swig_ret int) +} + +var _wrap_bounce unsafe.Pointer + +func _swig_wrap_bounce(base uintptr) (_ SwigcptrStringStringPair) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_bounce, _swig_p) + return +} + +func Bounce(arg1 StringStringPair) (_swig_ret StringStringPair) { + return _swig_wrap_bounce(arg1.Swigcptr()) +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/li_std_string.go b/Examples/test-suite/go/li_std_string.go new file mode 100644 index 000000000..b8f1a9f49 --- /dev/null +++ b/Examples/test-suite/go/li_std_string.go @@ -0,0 +1,487 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../li_std_string.i + +package li_std_string + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +var _wrap_test_value unsafe.Pointer + +func Test_value(arg1 string) (_swig_ret string) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_test_value, _swig_p) + return +} +var _wrap_test_const_reference unsafe.Pointer + +func Test_const_reference(arg1 string) (_swig_ret string) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_test_const_reference, _swig_p) + return +} +var _wrap_test_pointer unsafe.Pointer + +func _swig_wrap_test_pointer(base *string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_test_pointer, _swig_p) + return +} + +func Test_pointer(arg1 *string) { + _swig_wrap_test_pointer(arg1) +} + +var _wrap_test_pointer_out unsafe.Pointer + +func Test_pointer_out() (_swig_ret *string) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_test_pointer_out, _swig_p) + return +} +var _wrap_test_const_pointer unsafe.Pointer + +func _swig_wrap_test_const_pointer(base *string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_test_const_pointer, _swig_p) + return +} + +func Test_const_pointer(arg1 *string) { + _swig_wrap_test_const_pointer(arg1) +} + +var _wrap_test_const_pointer_out unsafe.Pointer + +func Test_const_pointer_out() (_swig_ret *string) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_test_const_pointer_out, _swig_p) + return +} +var _wrap_test_reference unsafe.Pointer + +func _swig_wrap_test_reference(base *string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_test_reference, _swig_p) + return +} + +func Test_reference(arg1 *string) { + _swig_wrap_test_reference(arg1) +} + +var _wrap_test_reference_out unsafe.Pointer + +func Test_reference_out() (_swig_ret *string) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_test_reference_out, _swig_p) + return +} +var _wrap_test_reference_input unsafe.Pointer + +func Test_reference_input(arg1 *string) (_swig_ret string) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_test_reference_input, _swig_p) + return +} +var _wrap_test_reference_inout unsafe.Pointer + +func _swig_wrap_test_reference_inout(base *string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_test_reference_inout, _swig_p) + return +} + +func Test_reference_inout(arg1 *string) { + _swig_wrap_test_reference_inout(arg1) +} + +var _wrap_test_throw unsafe.Pointer + +func _swig_wrap_test_throw() { + var _swig_p uintptr + _cgo_runtime_cgocall(_wrap_test_throw, _swig_p) + return +} + +func Test_throw() { + _swig_wrap_test_throw() +} + +var _wrap_test_const_reference_throw unsafe.Pointer + +func _swig_wrap_test_const_reference_throw() { + var _swig_p uintptr + _cgo_runtime_cgocall(_wrap_test_const_reference_throw, _swig_p) + return +} + +func Test_const_reference_throw() { + _swig_wrap_test_const_reference_throw() +} + +var _wrap_test_pointer_throw unsafe.Pointer + +func _swig_wrap_test_pointer_throw() { + var _swig_p uintptr + _cgo_runtime_cgocall(_wrap_test_pointer_throw, _swig_p) + return +} + +func Test_pointer_throw() { + _swig_wrap_test_pointer_throw() +} + +var _wrap_test_const_pointer_throw unsafe.Pointer + +func _swig_wrap_test_const_pointer_throw() { + var _swig_p uintptr + _cgo_runtime_cgocall(_wrap_test_const_pointer_throw, _swig_p) + return +} + +func Test_const_pointer_throw() { + _swig_wrap_test_const_pointer_throw() +} + +var _wrap_GlobalString_set unsafe.Pointer + +func _swig_wrap_GlobalString_set(base string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_GlobalString_set, _swig_p) + return +} + +func SetGlobalString(arg1 string) { + _swig_wrap_GlobalString_set(arg1) +} + +var _wrap_GlobalString_get unsafe.Pointer + +func GetGlobalString() (_swig_ret string) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_GlobalString_get, _swig_p) + return +} +var _wrap_GlobalString2_set unsafe.Pointer + +func _swig_wrap_GlobalString2_set(base string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_GlobalString2_set, _swig_p) + return +} + +func SetGlobalString2(arg1 string) { + _swig_wrap_GlobalString2_set(arg1) +} + +var _wrap_GlobalString2_get unsafe.Pointer + +func GetGlobalString2() (_swig_ret string) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_GlobalString2_get, _swig_p) + return +} +var _wrap_ConstGlobalString_get unsafe.Pointer + +func GetConstGlobalString() (_swig_ret string) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_ConstGlobalString_get, _swig_p) + return +} +type SwigcptrStructure uintptr + +func (p SwigcptrStructure) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrStructure) SwigIsStructure() { +} + +var _wrap_Structure_MemberString_set unsafe.Pointer + +func _swig_wrap_Structure_MemberString_set(base SwigcptrStructure, _ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Structure_MemberString_set, _swig_p) + return +} + +func (arg1 SwigcptrStructure) SetMemberString(arg2 string) { + _swig_wrap_Structure_MemberString_set(arg1, arg2) +} + +var _wrap_Structure_MemberString_get unsafe.Pointer + +func _swig_wrap_Structure_MemberString_get(base SwigcptrStructure) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Structure_MemberString_get, _swig_p) + return +} + +func (arg1 SwigcptrStructure) GetMemberString() (_swig_ret string) { + return _swig_wrap_Structure_MemberString_get(arg1) +} + +var _wrap_Structure_MemberString2_set unsafe.Pointer + +func _swig_wrap_Structure_MemberString2_set(base SwigcptrStructure, _ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Structure_MemberString2_set, _swig_p) + return +} + +func (arg1 SwigcptrStructure) SetMemberString2(arg2 string) { + _swig_wrap_Structure_MemberString2_set(arg1, arg2) +} + +var _wrap_Structure_MemberString2_get unsafe.Pointer + +func _swig_wrap_Structure_MemberString2_get(base SwigcptrStructure) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Structure_MemberString2_get, _swig_p) + return +} + +func (arg1 SwigcptrStructure) GetMemberString2() (_swig_ret string) { + return _swig_wrap_Structure_MemberString2_get(arg1) +} + +var _wrap_Structure_StaticMemberString_set unsafe.Pointer + +func _swig_wrap_Structure_StaticMemberString_set(base string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Structure_StaticMemberString_set, _swig_p) + return +} + +func SetStructureStaticMemberString(arg1 string) { + _swig_wrap_Structure_StaticMemberString_set(arg1) +} + +var _wrap_Structure_StaticMemberString_get unsafe.Pointer + +func GetStructureStaticMemberString() (_swig_ret string) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_Structure_StaticMemberString_get, _swig_p) + return +} +var _wrap_Structure_StaticMemberString2_set unsafe.Pointer + +func _swig_wrap_Structure_StaticMemberString2_set(base string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Structure_StaticMemberString2_set, _swig_p) + return +} + +func SetStructureStaticMemberString2(arg1 string) { + _swig_wrap_Structure_StaticMemberString2_set(arg1) +} + +var _wrap_Structure_StaticMemberString2_get unsafe.Pointer + +func GetStructureStaticMemberString2() (_swig_ret string) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_Structure_StaticMemberString2_get, _swig_p) + return +} +var _wrap_Structure_ConstMemberString_get unsafe.Pointer + +func _swig_wrap_Structure_ConstMemberString_get(base SwigcptrStructure) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Structure_ConstMemberString_get, _swig_p) + return +} + +func (arg1 SwigcptrStructure) GetConstMemberString() (_swig_ret string) { + return _swig_wrap_Structure_ConstMemberString_get(arg1) +} + +var _wrap_Structure_ConstStaticMemberString_get unsafe.Pointer + +func GetStructureConstStaticMemberString() (_swig_ret string) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_Structure_ConstStaticMemberString_get, _swig_p) + return +} +var _wrap_new_Structure unsafe.Pointer + +func _swig_wrap_new_Structure() (base SwigcptrStructure) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Structure, _swig_p) + return +} + +func NewStructure() (_swig_ret Structure) { + return _swig_wrap_new_Structure() +} + +var _wrap_delete_Structure unsafe.Pointer + +func _swig_wrap_delete_Structure(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Structure, _swig_p) + return +} + +func DeleteStructure(arg1 Structure) { + _swig_wrap_delete_Structure(arg1.Swigcptr()) +} + +type Structure interface { + Swigcptr() uintptr + SwigIsStructure() + SetMemberString(arg2 string) + GetMemberString() (_swig_ret string) + SetMemberString2(arg2 string) + GetMemberString2() (_swig_ret string) + GetConstMemberString() (_swig_ret string) +} + +type SwigcptrFoo uintptr + +func (p SwigcptrFoo) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrFoo) SwigIsFoo() { +} + +var _wrap_Foo_test__SWIG_0 unsafe.Pointer + +func _swig_wrap_Foo_test__SWIG_0(base SwigcptrFoo, _ uint64) (_ uint64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_test__SWIG_0, _swig_p) + return +} + +func (arg1 SwigcptrFoo) Test__SWIG_0(arg2 uint64) (_swig_ret uint64) { + return _swig_wrap_Foo_test__SWIG_0(arg1, arg2) +} + +var _wrap_Foo_test__SWIG_1 unsafe.Pointer + +func _swig_wrap_Foo_test__SWIG_1(base SwigcptrFoo, _ string) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_test__SWIG_1, _swig_p) + return +} + +func (arg1 SwigcptrFoo) Test__SWIG_1(arg2 string) (_swig_ret string) { + return _swig_wrap_Foo_test__SWIG_1(arg1, arg2) +} + +func (p SwigcptrFoo) Test(a ...interface{}) interface{} { + argc := len(a) + if argc == 1 { + if _, ok := a[0].(string); !ok { + goto check_1 + } + return p.Test__SWIG_1(a[0].(string)) + } +check_1: + if argc == 1 { + return p.Test__SWIG_0(a[0].(uint64)) + } + panic("No match for overloaded function call") +} + +var _wrap_Foo_testl unsafe.Pointer + +func _swig_wrap_Foo_testl(base SwigcptrFoo, _ uint64) (_ uint64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_testl, _swig_p) + return +} + +func (arg1 SwigcptrFoo) Testl(arg2 uint64) (_swig_ret uint64) { + return _swig_wrap_Foo_testl(arg1, arg2) +} + +var _wrap_new_Foo unsafe.Pointer + +func _swig_wrap_new_Foo() (base SwigcptrFoo) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Foo, _swig_p) + return +} + +func NewFoo() (_swig_ret Foo) { + return _swig_wrap_new_Foo() +} + +var _wrap_delete_Foo unsafe.Pointer + +func _swig_wrap_delete_Foo(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Foo, _swig_p) + return +} + +func DeleteFoo(arg1 Foo) { + _swig_wrap_delete_Foo(arg1.Swigcptr()) +} + +type Foo interface { + Swigcptr() uintptr + SwigIsFoo() + Test(a ...interface{}) interface{} + Testl(arg2 uint64) (_swig_ret uint64) +} + +var _wrap_stdstring_empty unsafe.Pointer + +func Stdstring_empty() (_swig_ret string) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_stdstring_empty, _swig_p) + return +} +var _wrap_c_empty unsafe.Pointer + +func C_empty() (_swig_ret string) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_c_empty, _swig_p) + return +} +var _wrap_c_null unsafe.Pointer + +func C_null() (_swig_ret string) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_c_null, _swig_p) + return +} +var _wrap_get_null unsafe.Pointer + +func Get_null(arg1 string) (_swig_ret string) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_get_null, _swig_p) + return +} + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/li_std_vector.go b/Examples/test-suite/go/li_std_vector.go new file mode 100644 index 000000000..736af7f2d --- /dev/null +++ b/Examples/test-suite/go/li_std_vector.go @@ -0,0 +1,3412 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../li_std_vector.i + +package li_std_vector + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrIntVector uintptr + +func (p SwigcptrIntVector) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrIntVector) SwigIsIntVector() { +} + +var _wrap_new_IntVector__SWIG_0 unsafe.Pointer + +func _swig_wrap_new_IntVector__SWIG_0() (base SwigcptrIntVector) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_IntVector__SWIG_0, _swig_p) + return +} + +func NewIntVector__SWIG_0() (_swig_ret IntVector) { + return _swig_wrap_new_IntVector__SWIG_0() +} + +var _wrap_new_IntVector__SWIG_1 unsafe.Pointer + +func _swig_wrap_new_IntVector__SWIG_1(base int64) (_ SwigcptrIntVector) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_IntVector__SWIG_1, _swig_p) + return +} + +func NewIntVector__SWIG_1(arg1 int64) (_swig_ret IntVector) { + return _swig_wrap_new_IntVector__SWIG_1(arg1) +} + +func NewIntVector(a ...interface{}) IntVector { + argc := len(a) + if argc == 0 { + return NewIntVector__SWIG_0() + } + if argc == 1 { + return NewIntVector__SWIG_1(a[0].(int64)) + } + panic("No match for overloaded function call") +} + +var _wrap_IntVector_size unsafe.Pointer + +func _swig_wrap_IntVector_size(base SwigcptrIntVector) (_ int64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_IntVector_size, _swig_p) + return +} + +func (arg1 SwigcptrIntVector) Size() (_swig_ret int64) { + return _swig_wrap_IntVector_size(arg1) +} + +var _wrap_IntVector_capacity unsafe.Pointer + +func _swig_wrap_IntVector_capacity(base SwigcptrIntVector) (_ int64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_IntVector_capacity, _swig_p) + return +} + +func (arg1 SwigcptrIntVector) Capacity() (_swig_ret int64) { + return _swig_wrap_IntVector_capacity(arg1) +} + +var _wrap_IntVector_reserve unsafe.Pointer + +func _swig_wrap_IntVector_reserve(base SwigcptrIntVector, _ int64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_IntVector_reserve, _swig_p) + return +} + +func (arg1 SwigcptrIntVector) Reserve(arg2 int64) { + _swig_wrap_IntVector_reserve(arg1, arg2) +} + +var _wrap_IntVector_isEmpty unsafe.Pointer + +func _swig_wrap_IntVector_isEmpty(base SwigcptrIntVector) (_ bool) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_IntVector_isEmpty, _swig_p) + return +} + +func (arg1 SwigcptrIntVector) IsEmpty() (_swig_ret bool) { + return _swig_wrap_IntVector_isEmpty(arg1) +} + +var _wrap_IntVector_clear unsafe.Pointer + +func _swig_wrap_IntVector_clear(base SwigcptrIntVector) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_IntVector_clear, _swig_p) + return +} + +func (arg1 SwigcptrIntVector) Clear() { + _swig_wrap_IntVector_clear(arg1) +} + +var _wrap_IntVector_add unsafe.Pointer + +func _swig_wrap_IntVector_add(base SwigcptrIntVector, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_IntVector_add, _swig_p) + return +} + +func (arg1 SwigcptrIntVector) Add(arg2 int) { + _swig_wrap_IntVector_add(arg1, arg2) +} + +var _wrap_IntVector_get unsafe.Pointer + +func _swig_wrap_IntVector_get(base SwigcptrIntVector, _ int) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_IntVector_get, _swig_p) + return +} + +func (arg1 SwigcptrIntVector) Get(arg2 int) (_swig_ret int) { + return _swig_wrap_IntVector_get(arg1, arg2) +} + +var _wrap_IntVector_set unsafe.Pointer + +func _swig_wrap_IntVector_set(base SwigcptrIntVector, _ int, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_IntVector_set, _swig_p) + return +} + +func (arg1 SwigcptrIntVector) Set(arg2 int, arg3 int) { + _swig_wrap_IntVector_set(arg1, arg2, arg3) +} + +var _wrap_delete_IntVector unsafe.Pointer + +func _swig_wrap_delete_IntVector(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_IntVector, _swig_p) + return +} + +func DeleteIntVector(arg1 IntVector) { + _swig_wrap_delete_IntVector(arg1.Swigcptr()) +} + +type IntVector interface { + Swigcptr() uintptr + SwigIsIntVector() + Size() (_swig_ret int64) + Capacity() (_swig_ret int64) + Reserve(arg2 int64) + IsEmpty() (_swig_ret bool) + Clear() + Add(arg2 int) + Get(arg2 int) (_swig_ret int) + Set(arg2 int, arg3 int) +} + +type SwigcptrBoolVector uintptr + +func (p SwigcptrBoolVector) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrBoolVector) SwigIsBoolVector() { +} + +var _wrap_new_BoolVector__SWIG_0 unsafe.Pointer + +func _swig_wrap_new_BoolVector__SWIG_0() (base SwigcptrBoolVector) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_BoolVector__SWIG_0, _swig_p) + return +} + +func NewBoolVector__SWIG_0() (_swig_ret BoolVector) { + return _swig_wrap_new_BoolVector__SWIG_0() +} + +var _wrap_new_BoolVector__SWIG_1 unsafe.Pointer + +func _swig_wrap_new_BoolVector__SWIG_1(base int64) (_ SwigcptrBoolVector) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_BoolVector__SWIG_1, _swig_p) + return +} + +func NewBoolVector__SWIG_1(arg1 int64) (_swig_ret BoolVector) { + return _swig_wrap_new_BoolVector__SWIG_1(arg1) +} + +func NewBoolVector(a ...interface{}) BoolVector { + argc := len(a) + if argc == 0 { + return NewBoolVector__SWIG_0() + } + if argc == 1 { + return NewBoolVector__SWIG_1(a[0].(int64)) + } + panic("No match for overloaded function call") +} + +var _wrap_BoolVector_size unsafe.Pointer + +func _swig_wrap_BoolVector_size(base SwigcptrBoolVector) (_ int64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_BoolVector_size, _swig_p) + return +} + +func (arg1 SwigcptrBoolVector) Size() (_swig_ret int64) { + return _swig_wrap_BoolVector_size(arg1) +} + +var _wrap_BoolVector_capacity unsafe.Pointer + +func _swig_wrap_BoolVector_capacity(base SwigcptrBoolVector) (_ int64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_BoolVector_capacity, _swig_p) + return +} + +func (arg1 SwigcptrBoolVector) Capacity() (_swig_ret int64) { + return _swig_wrap_BoolVector_capacity(arg1) +} + +var _wrap_BoolVector_reserve unsafe.Pointer + +func _swig_wrap_BoolVector_reserve(base SwigcptrBoolVector, _ int64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_BoolVector_reserve, _swig_p) + return +} + +func (arg1 SwigcptrBoolVector) Reserve(arg2 int64) { + _swig_wrap_BoolVector_reserve(arg1, arg2) +} + +var _wrap_BoolVector_isEmpty unsafe.Pointer + +func _swig_wrap_BoolVector_isEmpty(base SwigcptrBoolVector) (_ bool) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_BoolVector_isEmpty, _swig_p) + return +} + +func (arg1 SwigcptrBoolVector) IsEmpty() (_swig_ret bool) { + return _swig_wrap_BoolVector_isEmpty(arg1) +} + +var _wrap_BoolVector_clear unsafe.Pointer + +func _swig_wrap_BoolVector_clear(base SwigcptrBoolVector) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_BoolVector_clear, _swig_p) + return +} + +func (arg1 SwigcptrBoolVector) Clear() { + _swig_wrap_BoolVector_clear(arg1) +} + +var _wrap_BoolVector_add unsafe.Pointer + +func _swig_wrap_BoolVector_add(base SwigcptrBoolVector, _ bool) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_BoolVector_add, _swig_p) + return +} + +func (arg1 SwigcptrBoolVector) Add(arg2 bool) { + _swig_wrap_BoolVector_add(arg1, arg2) +} + +var _wrap_BoolVector_get unsafe.Pointer + +func _swig_wrap_BoolVector_get(base SwigcptrBoolVector, _ int) (_ bool) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_BoolVector_get, _swig_p) + return +} + +func (arg1 SwigcptrBoolVector) Get(arg2 int) (_swig_ret bool) { + return _swig_wrap_BoolVector_get(arg1, arg2) +} + +var _wrap_BoolVector_set unsafe.Pointer + +func _swig_wrap_BoolVector_set(base SwigcptrBoolVector, _ int, _ bool) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_BoolVector_set, _swig_p) + return +} + +func (arg1 SwigcptrBoolVector) Set(arg2 int, arg3 bool) { + _swig_wrap_BoolVector_set(arg1, arg2, arg3) +} + +var _wrap_delete_BoolVector unsafe.Pointer + +func _swig_wrap_delete_BoolVector(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_BoolVector, _swig_p) + return +} + +func DeleteBoolVector(arg1 BoolVector) { + _swig_wrap_delete_BoolVector(arg1.Swigcptr()) +} + +type BoolVector interface { + Swigcptr() uintptr + SwigIsBoolVector() + Size() (_swig_ret int64) + Capacity() (_swig_ret int64) + Reserve(arg2 int64) + IsEmpty() (_swig_ret bool) + Clear() + Add(arg2 bool) + Get(arg2 int) (_swig_ret bool) + Set(arg2 int, arg3 bool) +} + +type SwigcptrCharVector uintptr + +func (p SwigcptrCharVector) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrCharVector) SwigIsCharVector() { +} + +var _wrap_new_CharVector__SWIG_0 unsafe.Pointer + +func _swig_wrap_new_CharVector__SWIG_0() (base SwigcptrCharVector) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_CharVector__SWIG_0, _swig_p) + return +} + +func NewCharVector__SWIG_0() (_swig_ret CharVector) { + return _swig_wrap_new_CharVector__SWIG_0() +} + +var _wrap_new_CharVector__SWIG_1 unsafe.Pointer + +func _swig_wrap_new_CharVector__SWIG_1(base int64) (_ SwigcptrCharVector) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_CharVector__SWIG_1, _swig_p) + return +} + +func NewCharVector__SWIG_1(arg1 int64) (_swig_ret CharVector) { + return _swig_wrap_new_CharVector__SWIG_1(arg1) +} + +func NewCharVector(a ...interface{}) CharVector { + argc := len(a) + if argc == 0 { + return NewCharVector__SWIG_0() + } + if argc == 1 { + return NewCharVector__SWIG_1(a[0].(int64)) + } + panic("No match for overloaded function call") +} + +var _wrap_CharVector_size unsafe.Pointer + +func _swig_wrap_CharVector_size(base SwigcptrCharVector) (_ int64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_CharVector_size, _swig_p) + return +} + +func (arg1 SwigcptrCharVector) Size() (_swig_ret int64) { + return _swig_wrap_CharVector_size(arg1) +} + +var _wrap_CharVector_capacity unsafe.Pointer + +func _swig_wrap_CharVector_capacity(base SwigcptrCharVector) (_ int64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_CharVector_capacity, _swig_p) + return +} + +func (arg1 SwigcptrCharVector) Capacity() (_swig_ret int64) { + return _swig_wrap_CharVector_capacity(arg1) +} + +var _wrap_CharVector_reserve unsafe.Pointer + +func _swig_wrap_CharVector_reserve(base SwigcptrCharVector, _ int64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_CharVector_reserve, _swig_p) + return +} + +func (arg1 SwigcptrCharVector) Reserve(arg2 int64) { + _swig_wrap_CharVector_reserve(arg1, arg2) +} + +var _wrap_CharVector_isEmpty unsafe.Pointer + +func _swig_wrap_CharVector_isEmpty(base SwigcptrCharVector) (_ bool) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_CharVector_isEmpty, _swig_p) + return +} + +func (arg1 SwigcptrCharVector) IsEmpty() (_swig_ret bool) { + return _swig_wrap_CharVector_isEmpty(arg1) +} + +var _wrap_CharVector_clear unsafe.Pointer + +func _swig_wrap_CharVector_clear(base SwigcptrCharVector) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_CharVector_clear, _swig_p) + return +} + +func (arg1 SwigcptrCharVector) Clear() { + _swig_wrap_CharVector_clear(arg1) +} + +var _wrap_CharVector_add unsafe.Pointer + +func _swig_wrap_CharVector_add(base SwigcptrCharVector, _ byte) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_CharVector_add, _swig_p) + return +} + +func (arg1 SwigcptrCharVector) Add(arg2 byte) { + _swig_wrap_CharVector_add(arg1, arg2) +} + +var _wrap_CharVector_get unsafe.Pointer + +func _swig_wrap_CharVector_get(base SwigcptrCharVector, _ int) (_ byte) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_CharVector_get, _swig_p) + return +} + +func (arg1 SwigcptrCharVector) Get(arg2 int) (_swig_ret byte) { + return _swig_wrap_CharVector_get(arg1, arg2) +} + +var _wrap_CharVector_set unsafe.Pointer + +func _swig_wrap_CharVector_set(base SwigcptrCharVector, _ int, _ byte) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_CharVector_set, _swig_p) + return +} + +func (arg1 SwigcptrCharVector) Set(arg2 int, arg3 byte) { + _swig_wrap_CharVector_set(arg1, arg2, arg3) +} + +var _wrap_delete_CharVector unsafe.Pointer + +func _swig_wrap_delete_CharVector(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_CharVector, _swig_p) + return +} + +func DeleteCharVector(arg1 CharVector) { + _swig_wrap_delete_CharVector(arg1.Swigcptr()) +} + +type CharVector interface { + Swigcptr() uintptr + SwigIsCharVector() + Size() (_swig_ret int64) + Capacity() (_swig_ret int64) + Reserve(arg2 int64) + IsEmpty() (_swig_ret bool) + Clear() + Add(arg2 byte) + Get(arg2 int) (_swig_ret byte) + Set(arg2 int, arg3 byte) +} + +type SwigcptrShortVector uintptr + +func (p SwigcptrShortVector) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrShortVector) SwigIsShortVector() { +} + +var _wrap_new_ShortVector__SWIG_0 unsafe.Pointer + +func _swig_wrap_new_ShortVector__SWIG_0() (base SwigcptrShortVector) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_ShortVector__SWIG_0, _swig_p) + return +} + +func NewShortVector__SWIG_0() (_swig_ret ShortVector) { + return _swig_wrap_new_ShortVector__SWIG_0() +} + +var _wrap_new_ShortVector__SWIG_1 unsafe.Pointer + +func _swig_wrap_new_ShortVector__SWIG_1(base int64) (_ SwigcptrShortVector) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_ShortVector__SWIG_1, _swig_p) + return +} + +func NewShortVector__SWIG_1(arg1 int64) (_swig_ret ShortVector) { + return _swig_wrap_new_ShortVector__SWIG_1(arg1) +} + +func NewShortVector(a ...interface{}) ShortVector { + argc := len(a) + if argc == 0 { + return NewShortVector__SWIG_0() + } + if argc == 1 { + return NewShortVector__SWIG_1(a[0].(int64)) + } + panic("No match for overloaded function call") +} + +var _wrap_ShortVector_size unsafe.Pointer + +func _swig_wrap_ShortVector_size(base SwigcptrShortVector) (_ int64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_ShortVector_size, _swig_p) + return +} + +func (arg1 SwigcptrShortVector) Size() (_swig_ret int64) { + return _swig_wrap_ShortVector_size(arg1) +} + +var _wrap_ShortVector_capacity unsafe.Pointer + +func _swig_wrap_ShortVector_capacity(base SwigcptrShortVector) (_ int64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_ShortVector_capacity, _swig_p) + return +} + +func (arg1 SwigcptrShortVector) Capacity() (_swig_ret int64) { + return _swig_wrap_ShortVector_capacity(arg1) +} + +var _wrap_ShortVector_reserve unsafe.Pointer + +func _swig_wrap_ShortVector_reserve(base SwigcptrShortVector, _ int64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_ShortVector_reserve, _swig_p) + return +} + +func (arg1 SwigcptrShortVector) Reserve(arg2 int64) { + _swig_wrap_ShortVector_reserve(arg1, arg2) +} + +var _wrap_ShortVector_isEmpty unsafe.Pointer + +func _swig_wrap_ShortVector_isEmpty(base SwigcptrShortVector) (_ bool) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_ShortVector_isEmpty, _swig_p) + return +} + +func (arg1 SwigcptrShortVector) IsEmpty() (_swig_ret bool) { + return _swig_wrap_ShortVector_isEmpty(arg1) +} + +var _wrap_ShortVector_clear unsafe.Pointer + +func _swig_wrap_ShortVector_clear(base SwigcptrShortVector) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_ShortVector_clear, _swig_p) + return +} + +func (arg1 SwigcptrShortVector) Clear() { + _swig_wrap_ShortVector_clear(arg1) +} + +var _wrap_ShortVector_add unsafe.Pointer + +func _swig_wrap_ShortVector_add(base SwigcptrShortVector, _ int16) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_ShortVector_add, _swig_p) + return +} + +func (arg1 SwigcptrShortVector) Add(arg2 int16) { + _swig_wrap_ShortVector_add(arg1, arg2) +} + +var _wrap_ShortVector_get unsafe.Pointer + +func _swig_wrap_ShortVector_get(base SwigcptrShortVector, _ int) (_ int16) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_ShortVector_get, _swig_p) + return +} + +func (arg1 SwigcptrShortVector) Get(arg2 int) (_swig_ret int16) { + return _swig_wrap_ShortVector_get(arg1, arg2) +} + +var _wrap_ShortVector_set unsafe.Pointer + +func _swig_wrap_ShortVector_set(base SwigcptrShortVector, _ int, _ int16) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_ShortVector_set, _swig_p) + return +} + +func (arg1 SwigcptrShortVector) Set(arg2 int, arg3 int16) { + _swig_wrap_ShortVector_set(arg1, arg2, arg3) +} + +var _wrap_delete_ShortVector unsafe.Pointer + +func _swig_wrap_delete_ShortVector(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_ShortVector, _swig_p) + return +} + +func DeleteShortVector(arg1 ShortVector) { + _swig_wrap_delete_ShortVector(arg1.Swigcptr()) +} + +type ShortVector interface { + Swigcptr() uintptr + SwigIsShortVector() + Size() (_swig_ret int64) + Capacity() (_swig_ret int64) + Reserve(arg2 int64) + IsEmpty() (_swig_ret bool) + Clear() + Add(arg2 int16) + Get(arg2 int) (_swig_ret int16) + Set(arg2 int, arg3 int16) +} + +type SwigcptrLongVector uintptr + +func (p SwigcptrLongVector) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrLongVector) SwigIsLongVector() { +} + +var _wrap_new_LongVector__SWIG_0 unsafe.Pointer + +func _swig_wrap_new_LongVector__SWIG_0() (base SwigcptrLongVector) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_LongVector__SWIG_0, _swig_p) + return +} + +func NewLongVector__SWIG_0() (_swig_ret LongVector) { + return _swig_wrap_new_LongVector__SWIG_0() +} + +var _wrap_new_LongVector__SWIG_1 unsafe.Pointer + +func _swig_wrap_new_LongVector__SWIG_1(base int64) (_ SwigcptrLongVector) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_LongVector__SWIG_1, _swig_p) + return +} + +func NewLongVector__SWIG_1(arg1 int64) (_swig_ret LongVector) { + return _swig_wrap_new_LongVector__SWIG_1(arg1) +} + +func NewLongVector(a ...interface{}) LongVector { + argc := len(a) + if argc == 0 { + return NewLongVector__SWIG_0() + } + if argc == 1 { + return NewLongVector__SWIG_1(a[0].(int64)) + } + panic("No match for overloaded function call") +} + +var _wrap_LongVector_size unsafe.Pointer + +func _swig_wrap_LongVector_size(base SwigcptrLongVector) (_ int64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_LongVector_size, _swig_p) + return +} + +func (arg1 SwigcptrLongVector) Size() (_swig_ret int64) { + return _swig_wrap_LongVector_size(arg1) +} + +var _wrap_LongVector_capacity unsafe.Pointer + +func _swig_wrap_LongVector_capacity(base SwigcptrLongVector) (_ int64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_LongVector_capacity, _swig_p) + return +} + +func (arg1 SwigcptrLongVector) Capacity() (_swig_ret int64) { + return _swig_wrap_LongVector_capacity(arg1) +} + +var _wrap_LongVector_reserve unsafe.Pointer + +func _swig_wrap_LongVector_reserve(base SwigcptrLongVector, _ int64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_LongVector_reserve, _swig_p) + return +} + +func (arg1 SwigcptrLongVector) Reserve(arg2 int64) { + _swig_wrap_LongVector_reserve(arg1, arg2) +} + +var _wrap_LongVector_isEmpty unsafe.Pointer + +func _swig_wrap_LongVector_isEmpty(base SwigcptrLongVector) (_ bool) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_LongVector_isEmpty, _swig_p) + return +} + +func (arg1 SwigcptrLongVector) IsEmpty() (_swig_ret bool) { + return _swig_wrap_LongVector_isEmpty(arg1) +} + +var _wrap_LongVector_clear unsafe.Pointer + +func _swig_wrap_LongVector_clear(base SwigcptrLongVector) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_LongVector_clear, _swig_p) + return +} + +func (arg1 SwigcptrLongVector) Clear() { + _swig_wrap_LongVector_clear(arg1) +} + +var _wrap_LongVector_add unsafe.Pointer + +func _swig_wrap_LongVector_add(base SwigcptrLongVector, _ int64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_LongVector_add, _swig_p) + return +} + +func (arg1 SwigcptrLongVector) Add(arg2 int64) { + _swig_wrap_LongVector_add(arg1, arg2) +} + +var _wrap_LongVector_get unsafe.Pointer + +func _swig_wrap_LongVector_get(base SwigcptrLongVector, _ int) (_ int64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_LongVector_get, _swig_p) + return +} + +func (arg1 SwigcptrLongVector) Get(arg2 int) (_swig_ret int64) { + return _swig_wrap_LongVector_get(arg1, arg2) +} + +var _wrap_LongVector_set unsafe.Pointer + +func _swig_wrap_LongVector_set(base SwigcptrLongVector, _ int, _ int64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_LongVector_set, _swig_p) + return +} + +func (arg1 SwigcptrLongVector) Set(arg2 int, arg3 int64) { + _swig_wrap_LongVector_set(arg1, arg2, arg3) +} + +var _wrap_delete_LongVector unsafe.Pointer + +func _swig_wrap_delete_LongVector(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_LongVector, _swig_p) + return +} + +func DeleteLongVector(arg1 LongVector) { + _swig_wrap_delete_LongVector(arg1.Swigcptr()) +} + +type LongVector interface { + Swigcptr() uintptr + SwigIsLongVector() + Size() (_swig_ret int64) + Capacity() (_swig_ret int64) + Reserve(arg2 int64) + IsEmpty() (_swig_ret bool) + Clear() + Add(arg2 int64) + Get(arg2 int) (_swig_ret int64) + Set(arg2 int, arg3 int64) +} + +type SwigcptrUCharVector uintptr + +func (p SwigcptrUCharVector) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrUCharVector) SwigIsUCharVector() { +} + +var _wrap_new_UCharVector__SWIG_0 unsafe.Pointer + +func _swig_wrap_new_UCharVector__SWIG_0() (base SwigcptrUCharVector) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_UCharVector__SWIG_0, _swig_p) + return +} + +func NewUCharVector__SWIG_0() (_swig_ret UCharVector) { + return _swig_wrap_new_UCharVector__SWIG_0() +} + +var _wrap_new_UCharVector__SWIG_1 unsafe.Pointer + +func _swig_wrap_new_UCharVector__SWIG_1(base int64) (_ SwigcptrUCharVector) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_UCharVector__SWIG_1, _swig_p) + return +} + +func NewUCharVector__SWIG_1(arg1 int64) (_swig_ret UCharVector) { + return _swig_wrap_new_UCharVector__SWIG_1(arg1) +} + +func NewUCharVector(a ...interface{}) UCharVector { + argc := len(a) + if argc == 0 { + return NewUCharVector__SWIG_0() + } + if argc == 1 { + return NewUCharVector__SWIG_1(a[0].(int64)) + } + panic("No match for overloaded function call") +} + +var _wrap_UCharVector_size unsafe.Pointer + +func _swig_wrap_UCharVector_size(base SwigcptrUCharVector) (_ int64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_UCharVector_size, _swig_p) + return +} + +func (arg1 SwigcptrUCharVector) Size() (_swig_ret int64) { + return _swig_wrap_UCharVector_size(arg1) +} + +var _wrap_UCharVector_capacity unsafe.Pointer + +func _swig_wrap_UCharVector_capacity(base SwigcptrUCharVector) (_ int64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_UCharVector_capacity, _swig_p) + return +} + +func (arg1 SwigcptrUCharVector) Capacity() (_swig_ret int64) { + return _swig_wrap_UCharVector_capacity(arg1) +} + +var _wrap_UCharVector_reserve unsafe.Pointer + +func _swig_wrap_UCharVector_reserve(base SwigcptrUCharVector, _ int64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_UCharVector_reserve, _swig_p) + return +} + +func (arg1 SwigcptrUCharVector) Reserve(arg2 int64) { + _swig_wrap_UCharVector_reserve(arg1, arg2) +} + +var _wrap_UCharVector_isEmpty unsafe.Pointer + +func _swig_wrap_UCharVector_isEmpty(base SwigcptrUCharVector) (_ bool) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_UCharVector_isEmpty, _swig_p) + return +} + +func (arg1 SwigcptrUCharVector) IsEmpty() (_swig_ret bool) { + return _swig_wrap_UCharVector_isEmpty(arg1) +} + +var _wrap_UCharVector_clear unsafe.Pointer + +func _swig_wrap_UCharVector_clear(base SwigcptrUCharVector) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_UCharVector_clear, _swig_p) + return +} + +func (arg1 SwigcptrUCharVector) Clear() { + _swig_wrap_UCharVector_clear(arg1) +} + +var _wrap_UCharVector_add unsafe.Pointer + +func _swig_wrap_UCharVector_add(base SwigcptrUCharVector, _ byte) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_UCharVector_add, _swig_p) + return +} + +func (arg1 SwigcptrUCharVector) Add(arg2 byte) { + _swig_wrap_UCharVector_add(arg1, arg2) +} + +var _wrap_UCharVector_get unsafe.Pointer + +func _swig_wrap_UCharVector_get(base SwigcptrUCharVector, _ int) (_ byte) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_UCharVector_get, _swig_p) + return +} + +func (arg1 SwigcptrUCharVector) Get(arg2 int) (_swig_ret byte) { + return _swig_wrap_UCharVector_get(arg1, arg2) +} + +var _wrap_UCharVector_set unsafe.Pointer + +func _swig_wrap_UCharVector_set(base SwigcptrUCharVector, _ int, _ byte) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_UCharVector_set, _swig_p) + return +} + +func (arg1 SwigcptrUCharVector) Set(arg2 int, arg3 byte) { + _swig_wrap_UCharVector_set(arg1, arg2, arg3) +} + +var _wrap_delete_UCharVector unsafe.Pointer + +func _swig_wrap_delete_UCharVector(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_UCharVector, _swig_p) + return +} + +func DeleteUCharVector(arg1 UCharVector) { + _swig_wrap_delete_UCharVector(arg1.Swigcptr()) +} + +type UCharVector interface { + Swigcptr() uintptr + SwigIsUCharVector() + Size() (_swig_ret int64) + Capacity() (_swig_ret int64) + Reserve(arg2 int64) + IsEmpty() (_swig_ret bool) + Clear() + Add(arg2 byte) + Get(arg2 int) (_swig_ret byte) + Set(arg2 int, arg3 byte) +} + +type SwigcptrUIntVector uintptr + +func (p SwigcptrUIntVector) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrUIntVector) SwigIsUIntVector() { +} + +var _wrap_new_UIntVector__SWIG_0 unsafe.Pointer + +func _swig_wrap_new_UIntVector__SWIG_0() (base SwigcptrUIntVector) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_UIntVector__SWIG_0, _swig_p) + return +} + +func NewUIntVector__SWIG_0() (_swig_ret UIntVector) { + return _swig_wrap_new_UIntVector__SWIG_0() +} + +var _wrap_new_UIntVector__SWIG_1 unsafe.Pointer + +func _swig_wrap_new_UIntVector__SWIG_1(base int64) (_ SwigcptrUIntVector) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_UIntVector__SWIG_1, _swig_p) + return +} + +func NewUIntVector__SWIG_1(arg1 int64) (_swig_ret UIntVector) { + return _swig_wrap_new_UIntVector__SWIG_1(arg1) +} + +func NewUIntVector(a ...interface{}) UIntVector { + argc := len(a) + if argc == 0 { + return NewUIntVector__SWIG_0() + } + if argc == 1 { + return NewUIntVector__SWIG_1(a[0].(int64)) + } + panic("No match for overloaded function call") +} + +var _wrap_UIntVector_size unsafe.Pointer + +func _swig_wrap_UIntVector_size(base SwigcptrUIntVector) (_ int64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_UIntVector_size, _swig_p) + return +} + +func (arg1 SwigcptrUIntVector) Size() (_swig_ret int64) { + return _swig_wrap_UIntVector_size(arg1) +} + +var _wrap_UIntVector_capacity unsafe.Pointer + +func _swig_wrap_UIntVector_capacity(base SwigcptrUIntVector) (_ int64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_UIntVector_capacity, _swig_p) + return +} + +func (arg1 SwigcptrUIntVector) Capacity() (_swig_ret int64) { + return _swig_wrap_UIntVector_capacity(arg1) +} + +var _wrap_UIntVector_reserve unsafe.Pointer + +func _swig_wrap_UIntVector_reserve(base SwigcptrUIntVector, _ int64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_UIntVector_reserve, _swig_p) + return +} + +func (arg1 SwigcptrUIntVector) Reserve(arg2 int64) { + _swig_wrap_UIntVector_reserve(arg1, arg2) +} + +var _wrap_UIntVector_isEmpty unsafe.Pointer + +func _swig_wrap_UIntVector_isEmpty(base SwigcptrUIntVector) (_ bool) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_UIntVector_isEmpty, _swig_p) + return +} + +func (arg1 SwigcptrUIntVector) IsEmpty() (_swig_ret bool) { + return _swig_wrap_UIntVector_isEmpty(arg1) +} + +var _wrap_UIntVector_clear unsafe.Pointer + +func _swig_wrap_UIntVector_clear(base SwigcptrUIntVector) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_UIntVector_clear, _swig_p) + return +} + +func (arg1 SwigcptrUIntVector) Clear() { + _swig_wrap_UIntVector_clear(arg1) +} + +var _wrap_UIntVector_add unsafe.Pointer + +func _swig_wrap_UIntVector_add(base SwigcptrUIntVector, _ uint) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_UIntVector_add, _swig_p) + return +} + +func (arg1 SwigcptrUIntVector) Add(arg2 uint) { + _swig_wrap_UIntVector_add(arg1, arg2) +} + +var _wrap_UIntVector_get unsafe.Pointer + +func _swig_wrap_UIntVector_get(base SwigcptrUIntVector, _ int) (_ uint) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_UIntVector_get, _swig_p) + return +} + +func (arg1 SwigcptrUIntVector) Get(arg2 int) (_swig_ret uint) { + return _swig_wrap_UIntVector_get(arg1, arg2) +} + +var _wrap_UIntVector_set unsafe.Pointer + +func _swig_wrap_UIntVector_set(base SwigcptrUIntVector, _ int, _ uint) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_UIntVector_set, _swig_p) + return +} + +func (arg1 SwigcptrUIntVector) Set(arg2 int, arg3 uint) { + _swig_wrap_UIntVector_set(arg1, arg2, arg3) +} + +var _wrap_delete_UIntVector unsafe.Pointer + +func _swig_wrap_delete_UIntVector(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_UIntVector, _swig_p) + return +} + +func DeleteUIntVector(arg1 UIntVector) { + _swig_wrap_delete_UIntVector(arg1.Swigcptr()) +} + +type UIntVector interface { + Swigcptr() uintptr + SwigIsUIntVector() + Size() (_swig_ret int64) + Capacity() (_swig_ret int64) + Reserve(arg2 int64) + IsEmpty() (_swig_ret bool) + Clear() + Add(arg2 uint) + Get(arg2 int) (_swig_ret uint) + Set(arg2 int, arg3 uint) +} + +type SwigcptrUShortVector uintptr + +func (p SwigcptrUShortVector) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrUShortVector) SwigIsUShortVector() { +} + +var _wrap_new_UShortVector__SWIG_0 unsafe.Pointer + +func _swig_wrap_new_UShortVector__SWIG_0() (base SwigcptrUShortVector) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_UShortVector__SWIG_0, _swig_p) + return +} + +func NewUShortVector__SWIG_0() (_swig_ret UShortVector) { + return _swig_wrap_new_UShortVector__SWIG_0() +} + +var _wrap_new_UShortVector__SWIG_1 unsafe.Pointer + +func _swig_wrap_new_UShortVector__SWIG_1(base int64) (_ SwigcptrUShortVector) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_UShortVector__SWIG_1, _swig_p) + return +} + +func NewUShortVector__SWIG_1(arg1 int64) (_swig_ret UShortVector) { + return _swig_wrap_new_UShortVector__SWIG_1(arg1) +} + +func NewUShortVector(a ...interface{}) UShortVector { + argc := len(a) + if argc == 0 { + return NewUShortVector__SWIG_0() + } + if argc == 1 { + return NewUShortVector__SWIG_1(a[0].(int64)) + } + panic("No match for overloaded function call") +} + +var _wrap_UShortVector_size unsafe.Pointer + +func _swig_wrap_UShortVector_size(base SwigcptrUShortVector) (_ int64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_UShortVector_size, _swig_p) + return +} + +func (arg1 SwigcptrUShortVector) Size() (_swig_ret int64) { + return _swig_wrap_UShortVector_size(arg1) +} + +var _wrap_UShortVector_capacity unsafe.Pointer + +func _swig_wrap_UShortVector_capacity(base SwigcptrUShortVector) (_ int64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_UShortVector_capacity, _swig_p) + return +} + +func (arg1 SwigcptrUShortVector) Capacity() (_swig_ret int64) { + return _swig_wrap_UShortVector_capacity(arg1) +} + +var _wrap_UShortVector_reserve unsafe.Pointer + +func _swig_wrap_UShortVector_reserve(base SwigcptrUShortVector, _ int64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_UShortVector_reserve, _swig_p) + return +} + +func (arg1 SwigcptrUShortVector) Reserve(arg2 int64) { + _swig_wrap_UShortVector_reserve(arg1, arg2) +} + +var _wrap_UShortVector_isEmpty unsafe.Pointer + +func _swig_wrap_UShortVector_isEmpty(base SwigcptrUShortVector) (_ bool) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_UShortVector_isEmpty, _swig_p) + return +} + +func (arg1 SwigcptrUShortVector) IsEmpty() (_swig_ret bool) { + return _swig_wrap_UShortVector_isEmpty(arg1) +} + +var _wrap_UShortVector_clear unsafe.Pointer + +func _swig_wrap_UShortVector_clear(base SwigcptrUShortVector) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_UShortVector_clear, _swig_p) + return +} + +func (arg1 SwigcptrUShortVector) Clear() { + _swig_wrap_UShortVector_clear(arg1) +} + +var _wrap_UShortVector_add unsafe.Pointer + +func _swig_wrap_UShortVector_add(base SwigcptrUShortVector, _ uint16) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_UShortVector_add, _swig_p) + return +} + +func (arg1 SwigcptrUShortVector) Add(arg2 uint16) { + _swig_wrap_UShortVector_add(arg1, arg2) +} + +var _wrap_UShortVector_get unsafe.Pointer + +func _swig_wrap_UShortVector_get(base SwigcptrUShortVector, _ int) (_ uint16) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_UShortVector_get, _swig_p) + return +} + +func (arg1 SwigcptrUShortVector) Get(arg2 int) (_swig_ret uint16) { + return _swig_wrap_UShortVector_get(arg1, arg2) +} + +var _wrap_UShortVector_set unsafe.Pointer + +func _swig_wrap_UShortVector_set(base SwigcptrUShortVector, _ int, _ uint16) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_UShortVector_set, _swig_p) + return +} + +func (arg1 SwigcptrUShortVector) Set(arg2 int, arg3 uint16) { + _swig_wrap_UShortVector_set(arg1, arg2, arg3) +} + +var _wrap_delete_UShortVector unsafe.Pointer + +func _swig_wrap_delete_UShortVector(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_UShortVector, _swig_p) + return +} + +func DeleteUShortVector(arg1 UShortVector) { + _swig_wrap_delete_UShortVector(arg1.Swigcptr()) +} + +type UShortVector interface { + Swigcptr() uintptr + SwigIsUShortVector() + Size() (_swig_ret int64) + Capacity() (_swig_ret int64) + Reserve(arg2 int64) + IsEmpty() (_swig_ret bool) + Clear() + Add(arg2 uint16) + Get(arg2 int) (_swig_ret uint16) + Set(arg2 int, arg3 uint16) +} + +type SwigcptrULongVector uintptr + +func (p SwigcptrULongVector) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrULongVector) SwigIsULongVector() { +} + +var _wrap_new_ULongVector__SWIG_0 unsafe.Pointer + +func _swig_wrap_new_ULongVector__SWIG_0() (base SwigcptrULongVector) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_ULongVector__SWIG_0, _swig_p) + return +} + +func NewULongVector__SWIG_0() (_swig_ret ULongVector) { + return _swig_wrap_new_ULongVector__SWIG_0() +} + +var _wrap_new_ULongVector__SWIG_1 unsafe.Pointer + +func _swig_wrap_new_ULongVector__SWIG_1(base int64) (_ SwigcptrULongVector) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_ULongVector__SWIG_1, _swig_p) + return +} + +func NewULongVector__SWIG_1(arg1 int64) (_swig_ret ULongVector) { + return _swig_wrap_new_ULongVector__SWIG_1(arg1) +} + +func NewULongVector(a ...interface{}) ULongVector { + argc := len(a) + if argc == 0 { + return NewULongVector__SWIG_0() + } + if argc == 1 { + return NewULongVector__SWIG_1(a[0].(int64)) + } + panic("No match for overloaded function call") +} + +var _wrap_ULongVector_size unsafe.Pointer + +func _swig_wrap_ULongVector_size(base SwigcptrULongVector) (_ int64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_ULongVector_size, _swig_p) + return +} + +func (arg1 SwigcptrULongVector) Size() (_swig_ret int64) { + return _swig_wrap_ULongVector_size(arg1) +} + +var _wrap_ULongVector_capacity unsafe.Pointer + +func _swig_wrap_ULongVector_capacity(base SwigcptrULongVector) (_ int64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_ULongVector_capacity, _swig_p) + return +} + +func (arg1 SwigcptrULongVector) Capacity() (_swig_ret int64) { + return _swig_wrap_ULongVector_capacity(arg1) +} + +var _wrap_ULongVector_reserve unsafe.Pointer + +func _swig_wrap_ULongVector_reserve(base SwigcptrULongVector, _ int64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_ULongVector_reserve, _swig_p) + return +} + +func (arg1 SwigcptrULongVector) Reserve(arg2 int64) { + _swig_wrap_ULongVector_reserve(arg1, arg2) +} + +var _wrap_ULongVector_isEmpty unsafe.Pointer + +func _swig_wrap_ULongVector_isEmpty(base SwigcptrULongVector) (_ bool) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_ULongVector_isEmpty, _swig_p) + return +} + +func (arg1 SwigcptrULongVector) IsEmpty() (_swig_ret bool) { + return _swig_wrap_ULongVector_isEmpty(arg1) +} + +var _wrap_ULongVector_clear unsafe.Pointer + +func _swig_wrap_ULongVector_clear(base SwigcptrULongVector) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_ULongVector_clear, _swig_p) + return +} + +func (arg1 SwigcptrULongVector) Clear() { + _swig_wrap_ULongVector_clear(arg1) +} + +var _wrap_ULongVector_add unsafe.Pointer + +func _swig_wrap_ULongVector_add(base SwigcptrULongVector, _ uint64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_ULongVector_add, _swig_p) + return +} + +func (arg1 SwigcptrULongVector) Add(arg2 uint64) { + _swig_wrap_ULongVector_add(arg1, arg2) +} + +var _wrap_ULongVector_get unsafe.Pointer + +func _swig_wrap_ULongVector_get(base SwigcptrULongVector, _ int) (_ uint64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_ULongVector_get, _swig_p) + return +} + +func (arg1 SwigcptrULongVector) Get(arg2 int) (_swig_ret uint64) { + return _swig_wrap_ULongVector_get(arg1, arg2) +} + +var _wrap_ULongVector_set unsafe.Pointer + +func _swig_wrap_ULongVector_set(base SwigcptrULongVector, _ int, _ uint64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_ULongVector_set, _swig_p) + return +} + +func (arg1 SwigcptrULongVector) Set(arg2 int, arg3 uint64) { + _swig_wrap_ULongVector_set(arg1, arg2, arg3) +} + +var _wrap_delete_ULongVector unsafe.Pointer + +func _swig_wrap_delete_ULongVector(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_ULongVector, _swig_p) + return +} + +func DeleteULongVector(arg1 ULongVector) { + _swig_wrap_delete_ULongVector(arg1.Swigcptr()) +} + +type ULongVector interface { + Swigcptr() uintptr + SwigIsULongVector() + Size() (_swig_ret int64) + Capacity() (_swig_ret int64) + Reserve(arg2 int64) + IsEmpty() (_swig_ret bool) + Clear() + Add(arg2 uint64) + Get(arg2 int) (_swig_ret uint64) + Set(arg2 int, arg3 uint64) +} + +type SwigcptrDoubleVector uintptr + +func (p SwigcptrDoubleVector) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrDoubleVector) SwigIsDoubleVector() { +} + +var _wrap_new_DoubleVector__SWIG_0 unsafe.Pointer + +func _swig_wrap_new_DoubleVector__SWIG_0() (base SwigcptrDoubleVector) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_DoubleVector__SWIG_0, _swig_p) + return +} + +func NewDoubleVector__SWIG_0() (_swig_ret DoubleVector) { + return _swig_wrap_new_DoubleVector__SWIG_0() +} + +var _wrap_new_DoubleVector__SWIG_1 unsafe.Pointer + +func _swig_wrap_new_DoubleVector__SWIG_1(base int64) (_ SwigcptrDoubleVector) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_DoubleVector__SWIG_1, _swig_p) + return +} + +func NewDoubleVector__SWIG_1(arg1 int64) (_swig_ret DoubleVector) { + return _swig_wrap_new_DoubleVector__SWIG_1(arg1) +} + +func NewDoubleVector(a ...interface{}) DoubleVector { + argc := len(a) + if argc == 0 { + return NewDoubleVector__SWIG_0() + } + if argc == 1 { + return NewDoubleVector__SWIG_1(a[0].(int64)) + } + panic("No match for overloaded function call") +} + +var _wrap_DoubleVector_size unsafe.Pointer + +func _swig_wrap_DoubleVector_size(base SwigcptrDoubleVector) (_ int64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_DoubleVector_size, _swig_p) + return +} + +func (arg1 SwigcptrDoubleVector) Size() (_swig_ret int64) { + return _swig_wrap_DoubleVector_size(arg1) +} + +var _wrap_DoubleVector_capacity unsafe.Pointer + +func _swig_wrap_DoubleVector_capacity(base SwigcptrDoubleVector) (_ int64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_DoubleVector_capacity, _swig_p) + return +} + +func (arg1 SwigcptrDoubleVector) Capacity() (_swig_ret int64) { + return _swig_wrap_DoubleVector_capacity(arg1) +} + +var _wrap_DoubleVector_reserve unsafe.Pointer + +func _swig_wrap_DoubleVector_reserve(base SwigcptrDoubleVector, _ int64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_DoubleVector_reserve, _swig_p) + return +} + +func (arg1 SwigcptrDoubleVector) Reserve(arg2 int64) { + _swig_wrap_DoubleVector_reserve(arg1, arg2) +} + +var _wrap_DoubleVector_isEmpty unsafe.Pointer + +func _swig_wrap_DoubleVector_isEmpty(base SwigcptrDoubleVector) (_ bool) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_DoubleVector_isEmpty, _swig_p) + return +} + +func (arg1 SwigcptrDoubleVector) IsEmpty() (_swig_ret bool) { + return _swig_wrap_DoubleVector_isEmpty(arg1) +} + +var _wrap_DoubleVector_clear unsafe.Pointer + +func _swig_wrap_DoubleVector_clear(base SwigcptrDoubleVector) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_DoubleVector_clear, _swig_p) + return +} + +func (arg1 SwigcptrDoubleVector) Clear() { + _swig_wrap_DoubleVector_clear(arg1) +} + +var _wrap_DoubleVector_add unsafe.Pointer + +func _swig_wrap_DoubleVector_add(base SwigcptrDoubleVector, _ float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_DoubleVector_add, _swig_p) + return +} + +func (arg1 SwigcptrDoubleVector) Add(arg2 float64) { + _swig_wrap_DoubleVector_add(arg1, arg2) +} + +var _wrap_DoubleVector_get unsafe.Pointer + +func _swig_wrap_DoubleVector_get(base SwigcptrDoubleVector, _ int) (_ float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_DoubleVector_get, _swig_p) + return +} + +func (arg1 SwigcptrDoubleVector) Get(arg2 int) (_swig_ret float64) { + return _swig_wrap_DoubleVector_get(arg1, arg2) +} + +var _wrap_DoubleVector_set unsafe.Pointer + +func _swig_wrap_DoubleVector_set(base SwigcptrDoubleVector, _ int, _ float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_DoubleVector_set, _swig_p) + return +} + +func (arg1 SwigcptrDoubleVector) Set(arg2 int, arg3 float64) { + _swig_wrap_DoubleVector_set(arg1, arg2, arg3) +} + +var _wrap_delete_DoubleVector unsafe.Pointer + +func _swig_wrap_delete_DoubleVector(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_DoubleVector, _swig_p) + return +} + +func DeleteDoubleVector(arg1 DoubleVector) { + _swig_wrap_delete_DoubleVector(arg1.Swigcptr()) +} + +type DoubleVector interface { + Swigcptr() uintptr + SwigIsDoubleVector() + Size() (_swig_ret int64) + Capacity() (_swig_ret int64) + Reserve(arg2 int64) + IsEmpty() (_swig_ret bool) + Clear() + Add(arg2 float64) + Get(arg2 int) (_swig_ret float64) + Set(arg2 int, arg3 float64) +} + +type SwigcptrStringVector uintptr + +func (p SwigcptrStringVector) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrStringVector) SwigIsStringVector() { +} + +var _wrap_new_StringVector__SWIG_0 unsafe.Pointer + +func _swig_wrap_new_StringVector__SWIG_0() (base SwigcptrStringVector) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_StringVector__SWIG_0, _swig_p) + return +} + +func NewStringVector__SWIG_0() (_swig_ret StringVector) { + return _swig_wrap_new_StringVector__SWIG_0() +} + +var _wrap_new_StringVector__SWIG_1 unsafe.Pointer + +func _swig_wrap_new_StringVector__SWIG_1(base int64) (_ SwigcptrStringVector) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_StringVector__SWIG_1, _swig_p) + return +} + +func NewStringVector__SWIG_1(arg1 int64) (_swig_ret StringVector) { + return _swig_wrap_new_StringVector__SWIG_1(arg1) +} + +func NewStringVector(a ...interface{}) StringVector { + argc := len(a) + if argc == 0 { + return NewStringVector__SWIG_0() + } + if argc == 1 { + return NewStringVector__SWIG_1(a[0].(int64)) + } + panic("No match for overloaded function call") +} + +var _wrap_StringVector_size unsafe.Pointer + +func _swig_wrap_StringVector_size(base SwigcptrStringVector) (_ int64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_StringVector_size, _swig_p) + return +} + +func (arg1 SwigcptrStringVector) Size() (_swig_ret int64) { + return _swig_wrap_StringVector_size(arg1) +} + +var _wrap_StringVector_capacity unsafe.Pointer + +func _swig_wrap_StringVector_capacity(base SwigcptrStringVector) (_ int64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_StringVector_capacity, _swig_p) + return +} + +func (arg1 SwigcptrStringVector) Capacity() (_swig_ret int64) { + return _swig_wrap_StringVector_capacity(arg1) +} + +var _wrap_StringVector_reserve unsafe.Pointer + +func _swig_wrap_StringVector_reserve(base SwigcptrStringVector, _ int64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_StringVector_reserve, _swig_p) + return +} + +func (arg1 SwigcptrStringVector) Reserve(arg2 int64) { + _swig_wrap_StringVector_reserve(arg1, arg2) +} + +var _wrap_StringVector_isEmpty unsafe.Pointer + +func _swig_wrap_StringVector_isEmpty(base SwigcptrStringVector) (_ bool) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_StringVector_isEmpty, _swig_p) + return +} + +func (arg1 SwigcptrStringVector) IsEmpty() (_swig_ret bool) { + return _swig_wrap_StringVector_isEmpty(arg1) +} + +var _wrap_StringVector_clear unsafe.Pointer + +func _swig_wrap_StringVector_clear(base SwigcptrStringVector) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_StringVector_clear, _swig_p) + return +} + +func (arg1 SwigcptrStringVector) Clear() { + _swig_wrap_StringVector_clear(arg1) +} + +var _wrap_StringVector_add unsafe.Pointer + +func _swig_wrap_StringVector_add(base SwigcptrStringVector, _ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_StringVector_add, _swig_p) + return +} + +func (arg1 SwigcptrStringVector) Add(arg2 string) { + _swig_wrap_StringVector_add(arg1, arg2) +} + +var _wrap_StringVector_get unsafe.Pointer + +func _swig_wrap_StringVector_get(base SwigcptrStringVector, _ int) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_StringVector_get, _swig_p) + return +} + +func (arg1 SwigcptrStringVector) Get(arg2 int) (_swig_ret string) { + return _swig_wrap_StringVector_get(arg1, arg2) +} + +var _wrap_StringVector_set unsafe.Pointer + +func _swig_wrap_StringVector_set(base SwigcptrStringVector, _ int, _ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_StringVector_set, _swig_p) + return +} + +func (arg1 SwigcptrStringVector) Set(arg2 int, arg3 string) { + _swig_wrap_StringVector_set(arg1, arg2, arg3) +} + +var _wrap_delete_StringVector unsafe.Pointer + +func _swig_wrap_delete_StringVector(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_StringVector, _swig_p) + return +} + +func DeleteStringVector(arg1 StringVector) { + _swig_wrap_delete_StringVector(arg1.Swigcptr()) +} + +type StringVector interface { + Swigcptr() uintptr + SwigIsStringVector() + Size() (_swig_ret int64) + Capacity() (_swig_ret int64) + Reserve(arg2 int64) + IsEmpty() (_swig_ret bool) + Clear() + Add(arg2 string) + Get(arg2 int) (_swig_ret string) + Set(arg2 int, arg3 string) +} + +var _wrap_typedef_test unsafe.Pointer + +func Typedef_test(arg1 int64) (_swig_ret int64) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_typedef_test, _swig_p) + return +} +type SwigcptrRealVector uintptr + +func (p SwigcptrRealVector) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrRealVector) SwigIsRealVector() { +} + +var _wrap_new_RealVector__SWIG_0 unsafe.Pointer + +func _swig_wrap_new_RealVector__SWIG_0() (base SwigcptrRealVector) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_RealVector__SWIG_0, _swig_p) + return +} + +func NewRealVector__SWIG_0() (_swig_ret RealVector) { + return _swig_wrap_new_RealVector__SWIG_0() +} + +var _wrap_new_RealVector__SWIG_1 unsafe.Pointer + +func _swig_wrap_new_RealVector__SWIG_1(base int64) (_ SwigcptrRealVector) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_RealVector__SWIG_1, _swig_p) + return +} + +func NewRealVector__SWIG_1(arg1 int64) (_swig_ret RealVector) { + return _swig_wrap_new_RealVector__SWIG_1(arg1) +} + +func NewRealVector(a ...interface{}) RealVector { + argc := len(a) + if argc == 0 { + return NewRealVector__SWIG_0() + } + if argc == 1 { + return NewRealVector__SWIG_1(a[0].(int64)) + } + panic("No match for overloaded function call") +} + +var _wrap_RealVector_size unsafe.Pointer + +func _swig_wrap_RealVector_size(base SwigcptrRealVector) (_ int64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_RealVector_size, _swig_p) + return +} + +func (arg1 SwigcptrRealVector) Size() (_swig_ret int64) { + return _swig_wrap_RealVector_size(arg1) +} + +var _wrap_RealVector_capacity unsafe.Pointer + +func _swig_wrap_RealVector_capacity(base SwigcptrRealVector) (_ int64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_RealVector_capacity, _swig_p) + return +} + +func (arg1 SwigcptrRealVector) Capacity() (_swig_ret int64) { + return _swig_wrap_RealVector_capacity(arg1) +} + +var _wrap_RealVector_reserve unsafe.Pointer + +func _swig_wrap_RealVector_reserve(base SwigcptrRealVector, _ int64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_RealVector_reserve, _swig_p) + return +} + +func (arg1 SwigcptrRealVector) Reserve(arg2 int64) { + _swig_wrap_RealVector_reserve(arg1, arg2) +} + +var _wrap_RealVector_isEmpty unsafe.Pointer + +func _swig_wrap_RealVector_isEmpty(base SwigcptrRealVector) (_ bool) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_RealVector_isEmpty, _swig_p) + return +} + +func (arg1 SwigcptrRealVector) IsEmpty() (_swig_ret bool) { + return _swig_wrap_RealVector_isEmpty(arg1) +} + +var _wrap_RealVector_clear unsafe.Pointer + +func _swig_wrap_RealVector_clear(base SwigcptrRealVector) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_RealVector_clear, _swig_p) + return +} + +func (arg1 SwigcptrRealVector) Clear() { + _swig_wrap_RealVector_clear(arg1) +} + +var _wrap_RealVector_add unsafe.Pointer + +func _swig_wrap_RealVector_add(base SwigcptrRealVector, _ float32) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_RealVector_add, _swig_p) + return +} + +func (arg1 SwigcptrRealVector) Add(arg2 float32) { + _swig_wrap_RealVector_add(arg1, arg2) +} + +var _wrap_RealVector_get unsafe.Pointer + +func _swig_wrap_RealVector_get(base SwigcptrRealVector, _ int) (_ float32) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_RealVector_get, _swig_p) + return +} + +func (arg1 SwigcptrRealVector) Get(arg2 int) (_swig_ret float32) { + return _swig_wrap_RealVector_get(arg1, arg2) +} + +var _wrap_RealVector_set unsafe.Pointer + +func _swig_wrap_RealVector_set(base SwigcptrRealVector, _ int, _ float32) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_RealVector_set, _swig_p) + return +} + +func (arg1 SwigcptrRealVector) Set(arg2 int, arg3 float32) { + _swig_wrap_RealVector_set(arg1, arg2, arg3) +} + +var _wrap_delete_RealVector unsafe.Pointer + +func _swig_wrap_delete_RealVector(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_RealVector, _swig_p) + return +} + +func DeleteRealVector(arg1 RealVector) { + _swig_wrap_delete_RealVector(arg1.Swigcptr()) +} + +type RealVector interface { + Swigcptr() uintptr + SwigIsRealVector() + Size() (_swig_ret int64) + Capacity() (_swig_ret int64) + Reserve(arg2 int64) + IsEmpty() (_swig_ret bool) + Clear() + Add(arg2 float32) + Get(arg2 int) (_swig_ret float32) + Set(arg2 int, arg3 float32) +} + +var _wrap_average unsafe.Pointer + +func _swig_wrap_average(base uintptr) (_ float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_average, _swig_p) + return +} + +func Average(arg1 IntVector) (_swig_ret float64) { + return _swig_wrap_average(arg1.Swigcptr()) +} + +var _wrap_half unsafe.Pointer + +func _swig_wrap_half(base uintptr) (_ SwigcptrRealVector) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_half, _swig_p) + return +} + +func Half(arg1 RealVector) (_swig_ret RealVector) { + return _swig_wrap_half(arg1.Swigcptr()) +} + +var _wrap_halve_in_place unsafe.Pointer + +func _swig_wrap_halve_in_place(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_halve_in_place, _swig_p) + return +} + +func Halve_in_place(arg1 DoubleVector) { + _swig_wrap_halve_in_place(arg1.Swigcptr()) +} + +type SwigcptrStruct uintptr + +func (p SwigcptrStruct) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrStruct) SwigIsStruct() { +} + +var _wrap_Struct_num_set unsafe.Pointer + +func _swig_wrap_Struct_num_set(base SwigcptrStruct, _ float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Struct_num_set, _swig_p) + return +} + +func (arg1 SwigcptrStruct) SetNum(arg2 float64) { + _swig_wrap_Struct_num_set(arg1, arg2) +} + +var _wrap_Struct_num_get unsafe.Pointer + +func _swig_wrap_Struct_num_get(base SwigcptrStruct) (_ float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Struct_num_get, _swig_p) + return +} + +func (arg1 SwigcptrStruct) GetNum() (_swig_ret float64) { + return _swig_wrap_Struct_num_get(arg1) +} + +var _wrap_new_Struct__SWIG_0 unsafe.Pointer + +func _swig_wrap_new_Struct__SWIG_0() (base SwigcptrStruct) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Struct__SWIG_0, _swig_p) + return +} + +func NewStruct__SWIG_0() (_swig_ret Struct) { + return _swig_wrap_new_Struct__SWIG_0() +} + +var _wrap_new_Struct__SWIG_1 unsafe.Pointer + +func _swig_wrap_new_Struct__SWIG_1(base float64) (_ SwigcptrStruct) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Struct__SWIG_1, _swig_p) + return +} + +func NewStruct__SWIG_1(arg1 float64) (_swig_ret Struct) { + return _swig_wrap_new_Struct__SWIG_1(arg1) +} + +func NewStruct(a ...interface{}) Struct { + argc := len(a) + if argc == 0 { + return NewStruct__SWIG_0() + } + if argc == 1 { + return NewStruct__SWIG_1(a[0].(float64)) + } + panic("No match for overloaded function call") +} + +var _wrap_delete_Struct unsafe.Pointer + +func _swig_wrap_delete_Struct(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Struct, _swig_p) + return +} + +func DeleteStruct(arg1 Struct) { + _swig_wrap_delete_Struct(arg1.Swigcptr()) +} + +type Struct interface { + Swigcptr() uintptr + SwigIsStruct() + SetNum(arg2 float64) + GetNum() (_swig_ret float64) +} + +type SwigcptrStructure uintptr + +func (p SwigcptrStructure) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrStructure) SwigIsStructure() { +} + +var _wrap_Structure_num_set unsafe.Pointer + +func _swig_wrap_Structure_num_set(base SwigcptrStructure, _ float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Structure_num_set, _swig_p) + return +} + +func (arg1 SwigcptrStructure) SetNum(arg2 float64) { + _swig_wrap_Structure_num_set(arg1, arg2) +} + +var _wrap_Structure_num_get unsafe.Pointer + +func _swig_wrap_Structure_num_get(base SwigcptrStructure) (_ float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Structure_num_get, _swig_p) + return +} + +func (arg1 SwigcptrStructure) GetNum() (_swig_ret float64) { + return _swig_wrap_Structure_num_get(arg1) +} + +var _wrap_new_Structure__SWIG_0 unsafe.Pointer + +func _swig_wrap_new_Structure__SWIG_0() (base SwigcptrStructure) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Structure__SWIG_0, _swig_p) + return +} + +func NewStructure__SWIG_0() (_swig_ret Structure) { + return _swig_wrap_new_Structure__SWIG_0() +} + +var _wrap_new_Structure__SWIG_1 unsafe.Pointer + +func _swig_wrap_new_Structure__SWIG_1(base float64) (_ SwigcptrStructure) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Structure__SWIG_1, _swig_p) + return +} + +func NewStructure__SWIG_1(arg1 float64) (_swig_ret Structure) { + return _swig_wrap_new_Structure__SWIG_1(arg1) +} + +func NewStructure(a ...interface{}) Structure { + argc := len(a) + if argc == 0 { + return NewStructure__SWIG_0() + } + if argc == 1 { + return NewStructure__SWIG_1(a[0].(float64)) + } + panic("No match for overloaded function call") +} + +var _wrap_delete_Structure unsafe.Pointer + +func _swig_wrap_delete_Structure(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Structure, _swig_p) + return +} + +func DeleteStructure(arg1 Structure) { + _swig_wrap_delete_Structure(arg1.Swigcptr()) +} + +type Structure interface { + Swigcptr() uintptr + SwigIsStructure() + SetNum(arg2 float64) + GetNum() (_swig_ret float64) +} + +var _wrap_vecreal unsafe.Pointer + +func _swig_wrap_vecreal(base uintptr) (_ SwigcptrRealVector) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_vecreal, _swig_p) + return +} + +func Vecreal(arg1 RealVector) (_swig_ret RealVector) { + return _swig_wrap_vecreal(arg1.Swigcptr()) +} + +var _wrap_vecintptr__SWIG_0 unsafe.Pointer + +func _swig_wrap_vecintptr__SWIG_0(base uintptr) (_ SwigcptrIntVector) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_vecintptr__SWIG_0, _swig_p) + return +} + +func Vecintptr__SWIG_0(arg1 IntVector) (_swig_ret IntVector) { + return _swig_wrap_vecintptr__SWIG_0(arg1.Swigcptr()) +} + +var _wrap_vecintptr__SWIG_1 unsafe.Pointer + +func _swig_wrap_vecintptr__SWIG_1(base uintptr) (_ SwigcptrIntPtrVector) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_vecintptr__SWIG_1, _swig_p) + return +} + +func Vecintptr__SWIG_1(arg1 IntPtrVector) (_swig_ret IntPtrVector) { + return _swig_wrap_vecintptr__SWIG_1(arg1.Swigcptr()) +} + +func Vecintptr(a ...interface{}) interface{} { + argc := len(a) + if argc == 1 { + if _, ok := a[0].(IntVector); !ok { + goto check_1 + } + return Vecintptr__SWIG_0(a[0].(IntVector)) + } +check_1: + if argc == 1 { + return Vecintptr__SWIG_1(a[0].(IntPtrVector)) + } + panic("No match for overloaded function call") +} + +var _wrap_vecintconstptr unsafe.Pointer + +func _swig_wrap_vecintconstptr(base uintptr) (_ SwigcptrIntConstPtrVector) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_vecintconstptr, _swig_p) + return +} + +func Vecintconstptr(arg1 IntConstPtrVector) (_swig_ret IntConstPtrVector) { + return _swig_wrap_vecintconstptr(arg1.Swigcptr()) +} + +var _wrap_vecstruct unsafe.Pointer + +func _swig_wrap_vecstruct(base uintptr) (_ SwigcptrStructVector) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_vecstruct, _swig_p) + return +} + +func Vecstruct(arg1 StructVector) (_swig_ret StructVector) { + return _swig_wrap_vecstruct(arg1.Swigcptr()) +} + +var _wrap_vecstructptr unsafe.Pointer + +func _swig_wrap_vecstructptr(base uintptr) (_ SwigcptrStructPtrVector) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_vecstructptr, _swig_p) + return +} + +func Vecstructptr(arg1 StructPtrVector) (_swig_ret StructPtrVector) { + return _swig_wrap_vecstructptr(arg1.Swigcptr()) +} + +var _wrap_vecstructconstptr unsafe.Pointer + +func _swig_wrap_vecstructconstptr(base uintptr) (_ SwigcptrStructConstPtrVector) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_vecstructconstptr, _swig_p) + return +} + +func Vecstructconstptr(arg1 StructConstPtrVector) (_swig_ret StructConstPtrVector) { + return _swig_wrap_vecstructconstptr(arg1.Swigcptr()) +} + +type SwigcptrIntPtrVector uintptr + +func (p SwigcptrIntPtrVector) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrIntPtrVector) SwigIsIntPtrVector() { +} + +var _wrap_new_IntPtrVector__SWIG_0 unsafe.Pointer + +func _swig_wrap_new_IntPtrVector__SWIG_0() (base SwigcptrIntPtrVector) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_IntPtrVector__SWIG_0, _swig_p) + return +} + +func NewIntPtrVector__SWIG_0() (_swig_ret IntPtrVector) { + return _swig_wrap_new_IntPtrVector__SWIG_0() +} + +var _wrap_new_IntPtrVector__SWIG_1 unsafe.Pointer + +func _swig_wrap_new_IntPtrVector__SWIG_1(base int64) (_ SwigcptrIntPtrVector) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_IntPtrVector__SWIG_1, _swig_p) + return +} + +func NewIntPtrVector__SWIG_1(arg1 int64) (_swig_ret IntPtrVector) { + return _swig_wrap_new_IntPtrVector__SWIG_1(arg1) +} + +func NewIntPtrVector(a ...interface{}) IntPtrVector { + argc := len(a) + if argc == 0 { + return NewIntPtrVector__SWIG_0() + } + if argc == 1 { + return NewIntPtrVector__SWIG_1(a[0].(int64)) + } + panic("No match for overloaded function call") +} + +var _wrap_IntPtrVector_size unsafe.Pointer + +func _swig_wrap_IntPtrVector_size(base SwigcptrIntPtrVector) (_ int64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_IntPtrVector_size, _swig_p) + return +} + +func (arg1 SwigcptrIntPtrVector) Size() (_swig_ret int64) { + return _swig_wrap_IntPtrVector_size(arg1) +} + +var _wrap_IntPtrVector_capacity unsafe.Pointer + +func _swig_wrap_IntPtrVector_capacity(base SwigcptrIntPtrVector) (_ int64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_IntPtrVector_capacity, _swig_p) + return +} + +func (arg1 SwigcptrIntPtrVector) Capacity() (_swig_ret int64) { + return _swig_wrap_IntPtrVector_capacity(arg1) +} + +var _wrap_IntPtrVector_reserve unsafe.Pointer + +func _swig_wrap_IntPtrVector_reserve(base SwigcptrIntPtrVector, _ int64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_IntPtrVector_reserve, _swig_p) + return +} + +func (arg1 SwigcptrIntPtrVector) Reserve(arg2 int64) { + _swig_wrap_IntPtrVector_reserve(arg1, arg2) +} + +var _wrap_IntPtrVector_isEmpty unsafe.Pointer + +func _swig_wrap_IntPtrVector_isEmpty(base SwigcptrIntPtrVector) (_ bool) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_IntPtrVector_isEmpty, _swig_p) + return +} + +func (arg1 SwigcptrIntPtrVector) IsEmpty() (_swig_ret bool) { + return _swig_wrap_IntPtrVector_isEmpty(arg1) +} + +var _wrap_IntPtrVector_clear unsafe.Pointer + +func _swig_wrap_IntPtrVector_clear(base SwigcptrIntPtrVector) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_IntPtrVector_clear, _swig_p) + return +} + +func (arg1 SwigcptrIntPtrVector) Clear() { + _swig_wrap_IntPtrVector_clear(arg1) +} + +var _wrap_IntPtrVector_add unsafe.Pointer + +func _swig_wrap_IntPtrVector_add(base SwigcptrIntPtrVector, _ *int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_IntPtrVector_add, _swig_p) + return +} + +func (arg1 SwigcptrIntPtrVector) Add(arg2 *int) { + _swig_wrap_IntPtrVector_add(arg1, arg2) +} + +var _wrap_IntPtrVector_get unsafe.Pointer + +func _swig_wrap_IntPtrVector_get(base SwigcptrIntPtrVector, _ int) (_ *int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_IntPtrVector_get, _swig_p) + return +} + +func (arg1 SwigcptrIntPtrVector) Get(arg2 int) (_swig_ret *int) { + return _swig_wrap_IntPtrVector_get(arg1, arg2) +} + +var _wrap_IntPtrVector_set unsafe.Pointer + +func _swig_wrap_IntPtrVector_set(base SwigcptrIntPtrVector, _ int, _ *int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_IntPtrVector_set, _swig_p) + return +} + +func (arg1 SwigcptrIntPtrVector) Set(arg2 int, arg3 *int) { + _swig_wrap_IntPtrVector_set(arg1, arg2, arg3) +} + +var _wrap_delete_IntPtrVector unsafe.Pointer + +func _swig_wrap_delete_IntPtrVector(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_IntPtrVector, _swig_p) + return +} + +func DeleteIntPtrVector(arg1 IntPtrVector) { + _swig_wrap_delete_IntPtrVector(arg1.Swigcptr()) +} + +type IntPtrVector interface { + Swigcptr() uintptr + SwigIsIntPtrVector() + Size() (_swig_ret int64) + Capacity() (_swig_ret int64) + Reserve(arg2 int64) + IsEmpty() (_swig_ret bool) + Clear() + Add(arg2 *int) + Get(arg2 int) (_swig_ret *int) + Set(arg2 int, arg3 *int) +} + +type SwigcptrIntConstPtrVector uintptr + +func (p SwigcptrIntConstPtrVector) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrIntConstPtrVector) SwigIsIntConstPtrVector() { +} + +var _wrap_new_IntConstPtrVector__SWIG_0 unsafe.Pointer + +func _swig_wrap_new_IntConstPtrVector__SWIG_0() (base SwigcptrIntConstPtrVector) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_IntConstPtrVector__SWIG_0, _swig_p) + return +} + +func NewIntConstPtrVector__SWIG_0() (_swig_ret IntConstPtrVector) { + return _swig_wrap_new_IntConstPtrVector__SWIG_0() +} + +var _wrap_new_IntConstPtrVector__SWIG_1 unsafe.Pointer + +func _swig_wrap_new_IntConstPtrVector__SWIG_1(base int64) (_ SwigcptrIntConstPtrVector) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_IntConstPtrVector__SWIG_1, _swig_p) + return +} + +func NewIntConstPtrVector__SWIG_1(arg1 int64) (_swig_ret IntConstPtrVector) { + return _swig_wrap_new_IntConstPtrVector__SWIG_1(arg1) +} + +func NewIntConstPtrVector(a ...interface{}) IntConstPtrVector { + argc := len(a) + if argc == 0 { + return NewIntConstPtrVector__SWIG_0() + } + if argc == 1 { + return NewIntConstPtrVector__SWIG_1(a[0].(int64)) + } + panic("No match for overloaded function call") +} + +var _wrap_IntConstPtrVector_size unsafe.Pointer + +func _swig_wrap_IntConstPtrVector_size(base SwigcptrIntConstPtrVector) (_ int64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_IntConstPtrVector_size, _swig_p) + return +} + +func (arg1 SwigcptrIntConstPtrVector) Size() (_swig_ret int64) { + return _swig_wrap_IntConstPtrVector_size(arg1) +} + +var _wrap_IntConstPtrVector_capacity unsafe.Pointer + +func _swig_wrap_IntConstPtrVector_capacity(base SwigcptrIntConstPtrVector) (_ int64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_IntConstPtrVector_capacity, _swig_p) + return +} + +func (arg1 SwigcptrIntConstPtrVector) Capacity() (_swig_ret int64) { + return _swig_wrap_IntConstPtrVector_capacity(arg1) +} + +var _wrap_IntConstPtrVector_reserve unsafe.Pointer + +func _swig_wrap_IntConstPtrVector_reserve(base SwigcptrIntConstPtrVector, _ int64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_IntConstPtrVector_reserve, _swig_p) + return +} + +func (arg1 SwigcptrIntConstPtrVector) Reserve(arg2 int64) { + _swig_wrap_IntConstPtrVector_reserve(arg1, arg2) +} + +var _wrap_IntConstPtrVector_isEmpty unsafe.Pointer + +func _swig_wrap_IntConstPtrVector_isEmpty(base SwigcptrIntConstPtrVector) (_ bool) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_IntConstPtrVector_isEmpty, _swig_p) + return +} + +func (arg1 SwigcptrIntConstPtrVector) IsEmpty() (_swig_ret bool) { + return _swig_wrap_IntConstPtrVector_isEmpty(arg1) +} + +var _wrap_IntConstPtrVector_clear unsafe.Pointer + +func _swig_wrap_IntConstPtrVector_clear(base SwigcptrIntConstPtrVector) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_IntConstPtrVector_clear, _swig_p) + return +} + +func (arg1 SwigcptrIntConstPtrVector) Clear() { + _swig_wrap_IntConstPtrVector_clear(arg1) +} + +var _wrap_IntConstPtrVector_add unsafe.Pointer + +func _swig_wrap_IntConstPtrVector_add(base SwigcptrIntConstPtrVector, _ *int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_IntConstPtrVector_add, _swig_p) + return +} + +func (arg1 SwigcptrIntConstPtrVector) Add(arg2 *int) { + _swig_wrap_IntConstPtrVector_add(arg1, arg2) +} + +var _wrap_IntConstPtrVector_get unsafe.Pointer + +func _swig_wrap_IntConstPtrVector_get(base SwigcptrIntConstPtrVector, _ int) (_ *int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_IntConstPtrVector_get, _swig_p) + return +} + +func (arg1 SwigcptrIntConstPtrVector) Get(arg2 int) (_swig_ret *int) { + return _swig_wrap_IntConstPtrVector_get(arg1, arg2) +} + +var _wrap_IntConstPtrVector_set unsafe.Pointer + +func _swig_wrap_IntConstPtrVector_set(base SwigcptrIntConstPtrVector, _ int, _ *int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_IntConstPtrVector_set, _swig_p) + return +} + +func (arg1 SwigcptrIntConstPtrVector) Set(arg2 int, arg3 *int) { + _swig_wrap_IntConstPtrVector_set(arg1, arg2, arg3) +} + +var _wrap_delete_IntConstPtrVector unsafe.Pointer + +func _swig_wrap_delete_IntConstPtrVector(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_IntConstPtrVector, _swig_p) + return +} + +func DeleteIntConstPtrVector(arg1 IntConstPtrVector) { + _swig_wrap_delete_IntConstPtrVector(arg1.Swigcptr()) +} + +type IntConstPtrVector interface { + Swigcptr() uintptr + SwigIsIntConstPtrVector() + Size() (_swig_ret int64) + Capacity() (_swig_ret int64) + Reserve(arg2 int64) + IsEmpty() (_swig_ret bool) + Clear() + Add(arg2 *int) + Get(arg2 int) (_swig_ret *int) + Set(arg2 int, arg3 *int) +} + +type SwigcptrStructVector uintptr + +func (p SwigcptrStructVector) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrStructVector) SwigIsStructVector() { +} + +var _wrap_new_StructVector__SWIG_0 unsafe.Pointer + +func _swig_wrap_new_StructVector__SWIG_0() (base SwigcptrStructVector) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_StructVector__SWIG_0, _swig_p) + return +} + +func NewStructVector__SWIG_0() (_swig_ret StructVector) { + return _swig_wrap_new_StructVector__SWIG_0() +} + +var _wrap_new_StructVector__SWIG_1 unsafe.Pointer + +func _swig_wrap_new_StructVector__SWIG_1(base int64) (_ SwigcptrStructVector) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_StructVector__SWIG_1, _swig_p) + return +} + +func NewStructVector__SWIG_1(arg1 int64) (_swig_ret StructVector) { + return _swig_wrap_new_StructVector__SWIG_1(arg1) +} + +func NewStructVector(a ...interface{}) StructVector { + argc := len(a) + if argc == 0 { + return NewStructVector__SWIG_0() + } + if argc == 1 { + return NewStructVector__SWIG_1(a[0].(int64)) + } + panic("No match for overloaded function call") +} + +var _wrap_StructVector_size unsafe.Pointer + +func _swig_wrap_StructVector_size(base SwigcptrStructVector) (_ int64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_StructVector_size, _swig_p) + return +} + +func (arg1 SwigcptrStructVector) Size() (_swig_ret int64) { + return _swig_wrap_StructVector_size(arg1) +} + +var _wrap_StructVector_capacity unsafe.Pointer + +func _swig_wrap_StructVector_capacity(base SwigcptrStructVector) (_ int64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_StructVector_capacity, _swig_p) + return +} + +func (arg1 SwigcptrStructVector) Capacity() (_swig_ret int64) { + return _swig_wrap_StructVector_capacity(arg1) +} + +var _wrap_StructVector_reserve unsafe.Pointer + +func _swig_wrap_StructVector_reserve(base SwigcptrStructVector, _ int64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_StructVector_reserve, _swig_p) + return +} + +func (arg1 SwigcptrStructVector) Reserve(arg2 int64) { + _swig_wrap_StructVector_reserve(arg1, arg2) +} + +var _wrap_StructVector_isEmpty unsafe.Pointer + +func _swig_wrap_StructVector_isEmpty(base SwigcptrStructVector) (_ bool) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_StructVector_isEmpty, _swig_p) + return +} + +func (arg1 SwigcptrStructVector) IsEmpty() (_swig_ret bool) { + return _swig_wrap_StructVector_isEmpty(arg1) +} + +var _wrap_StructVector_clear unsafe.Pointer + +func _swig_wrap_StructVector_clear(base SwigcptrStructVector) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_StructVector_clear, _swig_p) + return +} + +func (arg1 SwigcptrStructVector) Clear() { + _swig_wrap_StructVector_clear(arg1) +} + +var _wrap_StructVector_add unsafe.Pointer + +func _swig_wrap_StructVector_add(base SwigcptrStructVector, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_StructVector_add, _swig_p) + return +} + +func (arg1 SwigcptrStructVector) Add(arg2 Struct) { + _swig_wrap_StructVector_add(arg1, arg2.Swigcptr()) +} + +var _wrap_StructVector_get unsafe.Pointer + +func _swig_wrap_StructVector_get(base SwigcptrStructVector, _ int) (_ SwigcptrStruct) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_StructVector_get, _swig_p) + return +} + +func (arg1 SwigcptrStructVector) Get(arg2 int) (_swig_ret Struct) { + return _swig_wrap_StructVector_get(arg1, arg2) +} + +var _wrap_StructVector_set unsafe.Pointer + +func _swig_wrap_StructVector_set(base SwigcptrStructVector, _ int, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_StructVector_set, _swig_p) + return +} + +func (arg1 SwigcptrStructVector) Set(arg2 int, arg3 Struct) { + _swig_wrap_StructVector_set(arg1, arg2, arg3.Swigcptr()) +} + +var _wrap_delete_StructVector unsafe.Pointer + +func _swig_wrap_delete_StructVector(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_StructVector, _swig_p) + return +} + +func DeleteStructVector(arg1 StructVector) { + _swig_wrap_delete_StructVector(arg1.Swigcptr()) +} + +type StructVector interface { + Swigcptr() uintptr + SwigIsStructVector() + Size() (_swig_ret int64) + Capacity() (_swig_ret int64) + Reserve(arg2 int64) + IsEmpty() (_swig_ret bool) + Clear() + Add(arg2 Struct) + Get(arg2 int) (_swig_ret Struct) + Set(arg2 int, arg3 Struct) +} + +type SwigcptrStructPtrVector uintptr + +func (p SwigcptrStructPtrVector) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrStructPtrVector) SwigIsStructPtrVector() { +} + +var _wrap_new_StructPtrVector__SWIG_0 unsafe.Pointer + +func _swig_wrap_new_StructPtrVector__SWIG_0() (base SwigcptrStructPtrVector) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_StructPtrVector__SWIG_0, _swig_p) + return +} + +func NewStructPtrVector__SWIG_0() (_swig_ret StructPtrVector) { + return _swig_wrap_new_StructPtrVector__SWIG_0() +} + +var _wrap_new_StructPtrVector__SWIG_1 unsafe.Pointer + +func _swig_wrap_new_StructPtrVector__SWIG_1(base int64) (_ SwigcptrStructPtrVector) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_StructPtrVector__SWIG_1, _swig_p) + return +} + +func NewStructPtrVector__SWIG_1(arg1 int64) (_swig_ret StructPtrVector) { + return _swig_wrap_new_StructPtrVector__SWIG_1(arg1) +} + +func NewStructPtrVector(a ...interface{}) StructPtrVector { + argc := len(a) + if argc == 0 { + return NewStructPtrVector__SWIG_0() + } + if argc == 1 { + return NewStructPtrVector__SWIG_1(a[0].(int64)) + } + panic("No match for overloaded function call") +} + +var _wrap_StructPtrVector_size unsafe.Pointer + +func _swig_wrap_StructPtrVector_size(base SwigcptrStructPtrVector) (_ int64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_StructPtrVector_size, _swig_p) + return +} + +func (arg1 SwigcptrStructPtrVector) Size() (_swig_ret int64) { + return _swig_wrap_StructPtrVector_size(arg1) +} + +var _wrap_StructPtrVector_capacity unsafe.Pointer + +func _swig_wrap_StructPtrVector_capacity(base SwigcptrStructPtrVector) (_ int64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_StructPtrVector_capacity, _swig_p) + return +} + +func (arg1 SwigcptrStructPtrVector) Capacity() (_swig_ret int64) { + return _swig_wrap_StructPtrVector_capacity(arg1) +} + +var _wrap_StructPtrVector_reserve unsafe.Pointer + +func _swig_wrap_StructPtrVector_reserve(base SwigcptrStructPtrVector, _ int64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_StructPtrVector_reserve, _swig_p) + return +} + +func (arg1 SwigcptrStructPtrVector) Reserve(arg2 int64) { + _swig_wrap_StructPtrVector_reserve(arg1, arg2) +} + +var _wrap_StructPtrVector_isEmpty unsafe.Pointer + +func _swig_wrap_StructPtrVector_isEmpty(base SwigcptrStructPtrVector) (_ bool) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_StructPtrVector_isEmpty, _swig_p) + return +} + +func (arg1 SwigcptrStructPtrVector) IsEmpty() (_swig_ret bool) { + return _swig_wrap_StructPtrVector_isEmpty(arg1) +} + +var _wrap_StructPtrVector_clear unsafe.Pointer + +func _swig_wrap_StructPtrVector_clear(base SwigcptrStructPtrVector) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_StructPtrVector_clear, _swig_p) + return +} + +func (arg1 SwigcptrStructPtrVector) Clear() { + _swig_wrap_StructPtrVector_clear(arg1) +} + +var _wrap_StructPtrVector_add unsafe.Pointer + +func _swig_wrap_StructPtrVector_add(base SwigcptrStructPtrVector, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_StructPtrVector_add, _swig_p) + return +} + +func (arg1 SwigcptrStructPtrVector) Add(arg2 Struct) { + _swig_wrap_StructPtrVector_add(arg1, arg2.Swigcptr()) +} + +var _wrap_StructPtrVector_get unsafe.Pointer + +func _swig_wrap_StructPtrVector_get(base SwigcptrStructPtrVector, _ int) (_ SwigcptrStruct) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_StructPtrVector_get, _swig_p) + return +} + +func (arg1 SwigcptrStructPtrVector) Get(arg2 int) (_swig_ret Struct) { + return _swig_wrap_StructPtrVector_get(arg1, arg2) +} + +var _wrap_StructPtrVector_set unsafe.Pointer + +func _swig_wrap_StructPtrVector_set(base SwigcptrStructPtrVector, _ int, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_StructPtrVector_set, _swig_p) + return +} + +func (arg1 SwigcptrStructPtrVector) Set(arg2 int, arg3 Struct) { + _swig_wrap_StructPtrVector_set(arg1, arg2, arg3.Swigcptr()) +} + +var _wrap_delete_StructPtrVector unsafe.Pointer + +func _swig_wrap_delete_StructPtrVector(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_StructPtrVector, _swig_p) + return +} + +func DeleteStructPtrVector(arg1 StructPtrVector) { + _swig_wrap_delete_StructPtrVector(arg1.Swigcptr()) +} + +type StructPtrVector interface { + Swigcptr() uintptr + SwigIsStructPtrVector() + Size() (_swig_ret int64) + Capacity() (_swig_ret int64) + Reserve(arg2 int64) + IsEmpty() (_swig_ret bool) + Clear() + Add(arg2 Struct) + Get(arg2 int) (_swig_ret Struct) + Set(arg2 int, arg3 Struct) +} + +type SwigcptrStructConstPtrVector uintptr + +func (p SwigcptrStructConstPtrVector) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrStructConstPtrVector) SwigIsStructConstPtrVector() { +} + +var _wrap_new_StructConstPtrVector__SWIG_0 unsafe.Pointer + +func _swig_wrap_new_StructConstPtrVector__SWIG_0() (base SwigcptrStructConstPtrVector) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_StructConstPtrVector__SWIG_0, _swig_p) + return +} + +func NewStructConstPtrVector__SWIG_0() (_swig_ret StructConstPtrVector) { + return _swig_wrap_new_StructConstPtrVector__SWIG_0() +} + +var _wrap_new_StructConstPtrVector__SWIG_1 unsafe.Pointer + +func _swig_wrap_new_StructConstPtrVector__SWIG_1(base int64) (_ SwigcptrStructConstPtrVector) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_StructConstPtrVector__SWIG_1, _swig_p) + return +} + +func NewStructConstPtrVector__SWIG_1(arg1 int64) (_swig_ret StructConstPtrVector) { + return _swig_wrap_new_StructConstPtrVector__SWIG_1(arg1) +} + +func NewStructConstPtrVector(a ...interface{}) StructConstPtrVector { + argc := len(a) + if argc == 0 { + return NewStructConstPtrVector__SWIG_0() + } + if argc == 1 { + return NewStructConstPtrVector__SWIG_1(a[0].(int64)) + } + panic("No match for overloaded function call") +} + +var _wrap_StructConstPtrVector_size unsafe.Pointer + +func _swig_wrap_StructConstPtrVector_size(base SwigcptrStructConstPtrVector) (_ int64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_StructConstPtrVector_size, _swig_p) + return +} + +func (arg1 SwigcptrStructConstPtrVector) Size() (_swig_ret int64) { + return _swig_wrap_StructConstPtrVector_size(arg1) +} + +var _wrap_StructConstPtrVector_capacity unsafe.Pointer + +func _swig_wrap_StructConstPtrVector_capacity(base SwigcptrStructConstPtrVector) (_ int64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_StructConstPtrVector_capacity, _swig_p) + return +} + +func (arg1 SwigcptrStructConstPtrVector) Capacity() (_swig_ret int64) { + return _swig_wrap_StructConstPtrVector_capacity(arg1) +} + +var _wrap_StructConstPtrVector_reserve unsafe.Pointer + +func _swig_wrap_StructConstPtrVector_reserve(base SwigcptrStructConstPtrVector, _ int64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_StructConstPtrVector_reserve, _swig_p) + return +} + +func (arg1 SwigcptrStructConstPtrVector) Reserve(arg2 int64) { + _swig_wrap_StructConstPtrVector_reserve(arg1, arg2) +} + +var _wrap_StructConstPtrVector_isEmpty unsafe.Pointer + +func _swig_wrap_StructConstPtrVector_isEmpty(base SwigcptrStructConstPtrVector) (_ bool) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_StructConstPtrVector_isEmpty, _swig_p) + return +} + +func (arg1 SwigcptrStructConstPtrVector) IsEmpty() (_swig_ret bool) { + return _swig_wrap_StructConstPtrVector_isEmpty(arg1) +} + +var _wrap_StructConstPtrVector_clear unsafe.Pointer + +func _swig_wrap_StructConstPtrVector_clear(base SwigcptrStructConstPtrVector) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_StructConstPtrVector_clear, _swig_p) + return +} + +func (arg1 SwigcptrStructConstPtrVector) Clear() { + _swig_wrap_StructConstPtrVector_clear(arg1) +} + +var _wrap_StructConstPtrVector_add unsafe.Pointer + +func _swig_wrap_StructConstPtrVector_add(base SwigcptrStructConstPtrVector, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_StructConstPtrVector_add, _swig_p) + return +} + +func (arg1 SwigcptrStructConstPtrVector) Add(arg2 Struct) { + _swig_wrap_StructConstPtrVector_add(arg1, arg2.Swigcptr()) +} + +var _wrap_StructConstPtrVector_get unsafe.Pointer + +func _swig_wrap_StructConstPtrVector_get(base SwigcptrStructConstPtrVector, _ int) (_ SwigcptrStruct) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_StructConstPtrVector_get, _swig_p) + return +} + +func (arg1 SwigcptrStructConstPtrVector) Get(arg2 int) (_swig_ret Struct) { + return _swig_wrap_StructConstPtrVector_get(arg1, arg2) +} + +var _wrap_StructConstPtrVector_set unsafe.Pointer + +func _swig_wrap_StructConstPtrVector_set(base SwigcptrStructConstPtrVector, _ int, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_StructConstPtrVector_set, _swig_p) + return +} + +func (arg1 SwigcptrStructConstPtrVector) Set(arg2 int, arg3 Struct) { + _swig_wrap_StructConstPtrVector_set(arg1, arg2, arg3.Swigcptr()) +} + +var _wrap_delete_StructConstPtrVector unsafe.Pointer + +func _swig_wrap_delete_StructConstPtrVector(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_StructConstPtrVector, _swig_p) + return +} + +func DeleteStructConstPtrVector(arg1 StructConstPtrVector) { + _swig_wrap_delete_StructConstPtrVector(arg1.Swigcptr()) +} + +type StructConstPtrVector interface { + Swigcptr() uintptr + SwigIsStructConstPtrVector() + Size() (_swig_ret int64) + Capacity() (_swig_ret int64) + Reserve(arg2 int64) + IsEmpty() (_swig_ret bool) + Clear() + Add(arg2 Struct) + Get(arg2 int) (_swig_ret Struct) + Set(arg2 int, arg3 Struct) +} + +type SwigcptrMyClass uintptr + +func (p SwigcptrMyClass) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrMyClass) SwigIsMyClass() { +} + +var _wrap_new_MyClass unsafe.Pointer + +func _swig_wrap_new_MyClass() (base SwigcptrMyClass) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_MyClass, _swig_p) + return +} + +func NewMyClass() (_swig_ret MyClass) { + return _swig_wrap_new_MyClass() +} + +var _wrap_delete_MyClass unsafe.Pointer + +func _swig_wrap_delete_MyClass(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_MyClass, _swig_p) + return +} + +func DeleteMyClass(arg1 MyClass) { + _swig_wrap_delete_MyClass(arg1.Swigcptr()) +} + +type MyClass interface { + Swigcptr() uintptr + SwigIsMyClass() +} + +type SwigcptrMyClassPtrVector uintptr + +func (p SwigcptrMyClassPtrVector) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrMyClassPtrVector) SwigIsMyClassPtrVector() { +} + +var _wrap_new_MyClassPtrVector__SWIG_0 unsafe.Pointer + +func _swig_wrap_new_MyClassPtrVector__SWIG_0() (base SwigcptrMyClassPtrVector) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_MyClassPtrVector__SWIG_0, _swig_p) + return +} + +func NewMyClassPtrVector__SWIG_0() (_swig_ret MyClassPtrVector) { + return _swig_wrap_new_MyClassPtrVector__SWIG_0() +} + +var _wrap_new_MyClassPtrVector__SWIG_1 unsafe.Pointer + +func _swig_wrap_new_MyClassPtrVector__SWIG_1(base int64) (_ SwigcptrMyClassPtrVector) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_MyClassPtrVector__SWIG_1, _swig_p) + return +} + +func NewMyClassPtrVector__SWIG_1(arg1 int64) (_swig_ret MyClassPtrVector) { + return _swig_wrap_new_MyClassPtrVector__SWIG_1(arg1) +} + +func NewMyClassPtrVector(a ...interface{}) MyClassPtrVector { + argc := len(a) + if argc == 0 { + return NewMyClassPtrVector__SWIG_0() + } + if argc == 1 { + return NewMyClassPtrVector__SWIG_1(a[0].(int64)) + } + panic("No match for overloaded function call") +} + +var _wrap_MyClassPtrVector_size unsafe.Pointer + +func _swig_wrap_MyClassPtrVector_size(base SwigcptrMyClassPtrVector) (_ int64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_MyClassPtrVector_size, _swig_p) + return +} + +func (arg1 SwigcptrMyClassPtrVector) Size() (_swig_ret int64) { + return _swig_wrap_MyClassPtrVector_size(arg1) +} + +var _wrap_MyClassPtrVector_capacity unsafe.Pointer + +func _swig_wrap_MyClassPtrVector_capacity(base SwigcptrMyClassPtrVector) (_ int64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_MyClassPtrVector_capacity, _swig_p) + return +} + +func (arg1 SwigcptrMyClassPtrVector) Capacity() (_swig_ret int64) { + return _swig_wrap_MyClassPtrVector_capacity(arg1) +} + +var _wrap_MyClassPtrVector_reserve unsafe.Pointer + +func _swig_wrap_MyClassPtrVector_reserve(base SwigcptrMyClassPtrVector, _ int64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_MyClassPtrVector_reserve, _swig_p) + return +} + +func (arg1 SwigcptrMyClassPtrVector) Reserve(arg2 int64) { + _swig_wrap_MyClassPtrVector_reserve(arg1, arg2) +} + +var _wrap_MyClassPtrVector_isEmpty unsafe.Pointer + +func _swig_wrap_MyClassPtrVector_isEmpty(base SwigcptrMyClassPtrVector) (_ bool) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_MyClassPtrVector_isEmpty, _swig_p) + return +} + +func (arg1 SwigcptrMyClassPtrVector) IsEmpty() (_swig_ret bool) { + return _swig_wrap_MyClassPtrVector_isEmpty(arg1) +} + +var _wrap_MyClassPtrVector_clear unsafe.Pointer + +func _swig_wrap_MyClassPtrVector_clear(base SwigcptrMyClassPtrVector) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_MyClassPtrVector_clear, _swig_p) + return +} + +func (arg1 SwigcptrMyClassPtrVector) Clear() { + _swig_wrap_MyClassPtrVector_clear(arg1) +} + +var _wrap_MyClassPtrVector_add unsafe.Pointer + +func _swig_wrap_MyClassPtrVector_add(base SwigcptrMyClassPtrVector, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_MyClassPtrVector_add, _swig_p) + return +} + +func (arg1 SwigcptrMyClassPtrVector) Add(arg2 MyClass) { + _swig_wrap_MyClassPtrVector_add(arg1, arg2.Swigcptr()) +} + +var _wrap_MyClassPtrVector_get unsafe.Pointer + +func _swig_wrap_MyClassPtrVector_get(base SwigcptrMyClassPtrVector, _ int) (_ SwigcptrMyClass) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_MyClassPtrVector_get, _swig_p) + return +} + +func (arg1 SwigcptrMyClassPtrVector) Get(arg2 int) (_swig_ret MyClass) { + return _swig_wrap_MyClassPtrVector_get(arg1, arg2) +} + +var _wrap_MyClassPtrVector_set unsafe.Pointer + +func _swig_wrap_MyClassPtrVector_set(base SwigcptrMyClassPtrVector, _ int, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_MyClassPtrVector_set, _swig_p) + return +} + +func (arg1 SwigcptrMyClassPtrVector) Set(arg2 int, arg3 MyClass) { + _swig_wrap_MyClassPtrVector_set(arg1, arg2, arg3.Swigcptr()) +} + +var _wrap_delete_MyClassPtrVector unsafe.Pointer + +func _swig_wrap_delete_MyClassPtrVector(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_MyClassPtrVector, _swig_p) + return +} + +func DeleteMyClassPtrVector(arg1 MyClassPtrVector) { + _swig_wrap_delete_MyClassPtrVector(arg1.Swigcptr()) +} + +type MyClassPtrVector interface { + Swigcptr() uintptr + SwigIsMyClassPtrVector() + Size() (_swig_ret int64) + Capacity() (_swig_ret int64) + Reserve(arg2 int64) + IsEmpty() (_swig_ret bool) + Clear() + Add(arg2 MyClass) + Get(arg2 int) (_swig_ret MyClass) + Set(arg2 int, arg3 MyClass) +} + +type SwigcptrRetsMetadata uintptr + +func (p SwigcptrRetsMetadata) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrRetsMetadata) SwigIsRetsMetadata() { +} + +var _wrap_RetsMetadata_GetAllResources unsafe.Pointer + +func _swig_wrap_RetsMetadata_GetAllResources(base SwigcptrRetsMetadata, _ int64) (_ SwigcptrMyClassPtrVector) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_RetsMetadata_GetAllResources, _swig_p) + return +} + +func (arg1 SwigcptrRetsMetadata) GetAllResources(arg2 int64) (_swig_ret MyClassPtrVector) { + return _swig_wrap_RetsMetadata_GetAllResources(arg1, arg2) +} + +var _wrap_new_RetsMetadata unsafe.Pointer + +func _swig_wrap_new_RetsMetadata() (base SwigcptrRetsMetadata) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_RetsMetadata, _swig_p) + return +} + +func NewRetsMetadata() (_swig_ret RetsMetadata) { + return _swig_wrap_new_RetsMetadata() +} + +var _wrap_delete_RetsMetadata unsafe.Pointer + +func _swig_wrap_delete_RetsMetadata(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_RetsMetadata, _swig_p) + return +} + +func DeleteRetsMetadata(arg1 RetsMetadata) { + _swig_wrap_delete_RetsMetadata(arg1.Swigcptr()) +} + +type RetsMetadata interface { + Swigcptr() uintptr + SwigIsRetsMetadata() + GetAllResources(arg2 int64) (_swig_ret MyClassPtrVector) +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/li_std_vector_enum.go b/Examples/test-suite/go/li_std_vector_enum.go new file mode 100644 index 000000000..335520588 --- /dev/null +++ b/Examples/test-suite/go/li_std_vector_enum.go @@ -0,0 +1,304 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../li_std_vector_enum.i + +package li_std_vector_enum + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrEnumVector uintptr + +func (p SwigcptrEnumVector) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrEnumVector) SwigIsEnumVector() { +} + +var _wrap_new_EnumVector unsafe.Pointer + +func _swig_wrap_new_EnumVector() (base SwigcptrEnumVector) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_EnumVector, _swig_p) + return +} + +func NewEnumVector() (_swig_ret EnumVector) { + return _swig_wrap_new_EnumVector() +} + +type EnumVectorNumbers int +var _wrap_ten_EnumVector unsafe.Pointer + +func _swig_getEnumVector_ten_EnumVector() (_swig_ret EnumVectorNumbers) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_ten_EnumVector, _swig_p) + return +} +var EnumVectorTen EnumVectorNumbers = _swig_getEnumVector_ten_EnumVector() +var _wrap_twenty_EnumVector unsafe.Pointer + +func _swig_getEnumVector_twenty_EnumVector() (_swig_ret EnumVectorNumbers) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_twenty_EnumVector, _swig_p) + return +} +var EnumVectorTwenty EnumVectorNumbers = _swig_getEnumVector_twenty_EnumVector() +var _wrap_thirty_EnumVector unsafe.Pointer + +func _swig_getEnumVector_thirty_EnumVector() (_swig_ret EnumVectorNumbers) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_thirty_EnumVector, _swig_p) + return +} +var EnumVectorThirty EnumVectorNumbers = _swig_getEnumVector_thirty_EnumVector() +var _wrap_EnumVector_nums_set unsafe.Pointer + +func _swig_wrap_EnumVector_nums_set(base SwigcptrEnumVector, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_EnumVector_nums_set, _swig_p) + return +} + +func (arg1 SwigcptrEnumVector) SetNums(arg2 Vector_numbers) { + _swig_wrap_EnumVector_nums_set(arg1, arg2.Swigcptr()) +} + +var _wrap_EnumVector_nums_get unsafe.Pointer + +func _swig_wrap_EnumVector_nums_get(base SwigcptrEnumVector) (_ SwigcptrVector_numbers) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_EnumVector_nums_get, _swig_p) + return +} + +func (arg1 SwigcptrEnumVector) GetNums() (_swig_ret Vector_numbers) { + return _swig_wrap_EnumVector_nums_get(arg1) +} + +var _wrap_EnumVector_fill_numbers unsafe.Pointer + +func _swig_wrap_EnumVector_fill_numbers(base SwigcptrEnumVector) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_EnumVector_fill_numbers, _swig_p) + return +} + +func (arg1 SwigcptrEnumVector) Fill_numbers() { + _swig_wrap_EnumVector_fill_numbers(arg1) +} + +var _wrap_delete_EnumVector unsafe.Pointer + +func _swig_wrap_delete_EnumVector(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_EnumVector, _swig_p) + return +} + +func DeleteEnumVector(arg1 EnumVector) { + _swig_wrap_delete_EnumVector(arg1.Swigcptr()) +} + +type EnumVector interface { + Swigcptr() uintptr + SwigIsEnumVector() + SetNums(arg2 Vector_numbers) + GetNums() (_swig_ret Vector_numbers) + Fill_numbers() +} + +type SwigcptrVector_numbers uintptr + +func (p SwigcptrVector_numbers) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrVector_numbers) SwigIsVector_numbers() { +} + +var _wrap_new_vector_numbers__SWIG_0 unsafe.Pointer + +func _swig_wrap_new_vector_numbers__SWIG_0() (base SwigcptrVector_numbers) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_vector_numbers__SWIG_0, _swig_p) + return +} + +func NewVector_numbers__SWIG_0() (_swig_ret Vector_numbers) { + return _swig_wrap_new_vector_numbers__SWIG_0() +} + +var _wrap_new_vector_numbers__SWIG_1 unsafe.Pointer + +func _swig_wrap_new_vector_numbers__SWIG_1(base int64) (_ SwigcptrVector_numbers) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_vector_numbers__SWIG_1, _swig_p) + return +} + +func NewVector_numbers__SWIG_1(arg1 int64) (_swig_ret Vector_numbers) { + return _swig_wrap_new_vector_numbers__SWIG_1(arg1) +} + +func NewVector_numbers(a ...interface{}) Vector_numbers { + argc := len(a) + if argc == 0 { + return NewVector_numbers__SWIG_0() + } + if argc == 1 { + return NewVector_numbers__SWIG_1(a[0].(int64)) + } + panic("No match for overloaded function call") +} + +var _wrap_vector_numbers_size unsafe.Pointer + +func _swig_wrap_vector_numbers_size(base SwigcptrVector_numbers) (_ int64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_vector_numbers_size, _swig_p) + return +} + +func (arg1 SwigcptrVector_numbers) Size() (_swig_ret int64) { + return _swig_wrap_vector_numbers_size(arg1) +} + +var _wrap_vector_numbers_capacity unsafe.Pointer + +func _swig_wrap_vector_numbers_capacity(base SwigcptrVector_numbers) (_ int64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_vector_numbers_capacity, _swig_p) + return +} + +func (arg1 SwigcptrVector_numbers) Capacity() (_swig_ret int64) { + return _swig_wrap_vector_numbers_capacity(arg1) +} + +var _wrap_vector_numbers_reserve unsafe.Pointer + +func _swig_wrap_vector_numbers_reserve(base SwigcptrVector_numbers, _ int64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_vector_numbers_reserve, _swig_p) + return +} + +func (arg1 SwigcptrVector_numbers) Reserve(arg2 int64) { + _swig_wrap_vector_numbers_reserve(arg1, arg2) +} + +var _wrap_vector_numbers_isEmpty unsafe.Pointer + +func _swig_wrap_vector_numbers_isEmpty(base SwigcptrVector_numbers) (_ bool) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_vector_numbers_isEmpty, _swig_p) + return +} + +func (arg1 SwigcptrVector_numbers) IsEmpty() (_swig_ret bool) { + return _swig_wrap_vector_numbers_isEmpty(arg1) +} + +var _wrap_vector_numbers_clear unsafe.Pointer + +func _swig_wrap_vector_numbers_clear(base SwigcptrVector_numbers) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_vector_numbers_clear, _swig_p) + return +} + +func (arg1 SwigcptrVector_numbers) Clear() { + _swig_wrap_vector_numbers_clear(arg1) +} + +var _wrap_vector_numbers_add unsafe.Pointer + +func _swig_wrap_vector_numbers_add(base SwigcptrVector_numbers, _ *EnumVectorNumbers) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_vector_numbers_add, _swig_p) + return +} + +func (arg1 SwigcptrVector_numbers) Add(arg2 *EnumVectorNumbers) { + _swig_wrap_vector_numbers_add(arg1, arg2) +} + +var _wrap_vector_numbers_get unsafe.Pointer + +func _swig_wrap_vector_numbers_get(base SwigcptrVector_numbers, _ int) (_ *EnumVectorNumbers) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_vector_numbers_get, _swig_p) + return +} + +func (arg1 SwigcptrVector_numbers) Get(arg2 int) (_swig_ret *EnumVectorNumbers) { + return _swig_wrap_vector_numbers_get(arg1, arg2) +} + +var _wrap_vector_numbers_set unsafe.Pointer + +func _swig_wrap_vector_numbers_set(base SwigcptrVector_numbers, _ int, _ *EnumVectorNumbers) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_vector_numbers_set, _swig_p) + return +} + +func (arg1 SwigcptrVector_numbers) Set(arg2 int, arg3 *EnumVectorNumbers) { + _swig_wrap_vector_numbers_set(arg1, arg2, arg3) +} + +var _wrap_delete_vector_numbers unsafe.Pointer + +func _swig_wrap_delete_vector_numbers(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_vector_numbers, _swig_p) + return +} + +func DeleteVector_numbers(arg1 Vector_numbers) { + _swig_wrap_delete_vector_numbers(arg1.Swigcptr()) +} + +type Vector_numbers interface { + Swigcptr() uintptr + SwigIsVector_numbers() + Size() (_swig_ret int64) + Capacity() (_swig_ret int64) + Reserve(arg2 int64) + IsEmpty() (_swig_ret bool) + Clear() + Add(arg2 *EnumVectorNumbers) + Get(arg2 int) (_swig_ret *EnumVectorNumbers) + Set(arg2 int, arg3 *EnumVectorNumbers) +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/li_std_vector_member_var.go b/Examples/test-suite/go/li_std_vector_member_var.go new file mode 100644 index 000000000..b58619888 --- /dev/null +++ b/Examples/test-suite/go/li_std_vector_member_var.go @@ -0,0 +1,459 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../li_std_vector_member_var.i + +package li_std_vector_member_var + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrVectorDbl uintptr + +func (p SwigcptrVectorDbl) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrVectorDbl) SwigIsVectorDbl() { +} + +var _wrap_new_vectorDbl__SWIG_0 unsafe.Pointer + +func _swig_wrap_new_vectorDbl__SWIG_0() (base SwigcptrVectorDbl) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_vectorDbl__SWIG_0, _swig_p) + return +} + +func NewVectorDbl__SWIG_0() (_swig_ret VectorDbl) { + return _swig_wrap_new_vectorDbl__SWIG_0() +} + +var _wrap_new_vectorDbl__SWIG_1 unsafe.Pointer + +func _swig_wrap_new_vectorDbl__SWIG_1(base int64) (_ SwigcptrVectorDbl) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_vectorDbl__SWIG_1, _swig_p) + return +} + +func NewVectorDbl__SWIG_1(arg1 int64) (_swig_ret VectorDbl) { + return _swig_wrap_new_vectorDbl__SWIG_1(arg1) +} + +func NewVectorDbl(a ...interface{}) VectorDbl { + argc := len(a) + if argc == 0 { + return NewVectorDbl__SWIG_0() + } + if argc == 1 { + return NewVectorDbl__SWIG_1(a[0].(int64)) + } + panic("No match for overloaded function call") +} + +var _wrap_vectorDbl_size unsafe.Pointer + +func _swig_wrap_vectorDbl_size(base SwigcptrVectorDbl) (_ int64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_vectorDbl_size, _swig_p) + return +} + +func (arg1 SwigcptrVectorDbl) Size() (_swig_ret int64) { + return _swig_wrap_vectorDbl_size(arg1) +} + +var _wrap_vectorDbl_capacity unsafe.Pointer + +func _swig_wrap_vectorDbl_capacity(base SwigcptrVectorDbl) (_ int64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_vectorDbl_capacity, _swig_p) + return +} + +func (arg1 SwigcptrVectorDbl) Capacity() (_swig_ret int64) { + return _swig_wrap_vectorDbl_capacity(arg1) +} + +var _wrap_vectorDbl_reserve unsafe.Pointer + +func _swig_wrap_vectorDbl_reserve(base SwigcptrVectorDbl, _ int64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_vectorDbl_reserve, _swig_p) + return +} + +func (arg1 SwigcptrVectorDbl) Reserve(arg2 int64) { + _swig_wrap_vectorDbl_reserve(arg1, arg2) +} + +var _wrap_vectorDbl_isEmpty unsafe.Pointer + +func _swig_wrap_vectorDbl_isEmpty(base SwigcptrVectorDbl) (_ bool) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_vectorDbl_isEmpty, _swig_p) + return +} + +func (arg1 SwigcptrVectorDbl) IsEmpty() (_swig_ret bool) { + return _swig_wrap_vectorDbl_isEmpty(arg1) +} + +var _wrap_vectorDbl_clear unsafe.Pointer + +func _swig_wrap_vectorDbl_clear(base SwigcptrVectorDbl) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_vectorDbl_clear, _swig_p) + return +} + +func (arg1 SwigcptrVectorDbl) Clear() { + _swig_wrap_vectorDbl_clear(arg1) +} + +var _wrap_vectorDbl_add unsafe.Pointer + +func _swig_wrap_vectorDbl_add(base SwigcptrVectorDbl, _ float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_vectorDbl_add, _swig_p) + return +} + +func (arg1 SwigcptrVectorDbl) Add(arg2 float64) { + _swig_wrap_vectorDbl_add(arg1, arg2) +} + +var _wrap_vectorDbl_get unsafe.Pointer + +func _swig_wrap_vectorDbl_get(base SwigcptrVectorDbl, _ int) (_ float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_vectorDbl_get, _swig_p) + return +} + +func (arg1 SwigcptrVectorDbl) Get(arg2 int) (_swig_ret float64) { + return _swig_wrap_vectorDbl_get(arg1, arg2) +} + +var _wrap_vectorDbl_set unsafe.Pointer + +func _swig_wrap_vectorDbl_set(base SwigcptrVectorDbl, _ int, _ float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_vectorDbl_set, _swig_p) + return +} + +func (arg1 SwigcptrVectorDbl) Set(arg2 int, arg3 float64) { + _swig_wrap_vectorDbl_set(arg1, arg2, arg3) +} + +var _wrap_delete_vectorDbl unsafe.Pointer + +func _swig_wrap_delete_vectorDbl(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_vectorDbl, _swig_p) + return +} + +func DeleteVectorDbl(arg1 VectorDbl) { + _swig_wrap_delete_vectorDbl(arg1.Swigcptr()) +} + +type VectorDbl interface { + Swigcptr() uintptr + SwigIsVectorDbl() + Size() (_swig_ret int64) + Capacity() (_swig_ret int64) + Reserve(arg2 int64) + IsEmpty() (_swig_ret bool) + Clear() + Add(arg2 float64) + Get(arg2 int) (_swig_ret float64) + Set(arg2 int, arg3 float64) +} + +type SwigcptrTest uintptr + +func (p SwigcptrTest) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrTest) SwigIsTest() { +} + +var _wrap_Test_v_set unsafe.Pointer + +func _swig_wrap_Test_v_set(base SwigcptrTest, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Test_v_set, _swig_p) + return +} + +func (arg1 SwigcptrTest) SetV(arg2 VectorDbl) { + _swig_wrap_Test_v_set(arg1, arg2.Swigcptr()) +} + +var _wrap_Test_v_get unsafe.Pointer + +func _swig_wrap_Test_v_get(base SwigcptrTest) (_ SwigcptrVectorDbl) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Test_v_get, _swig_p) + return +} + +func (arg1 SwigcptrTest) GetV() (_swig_ret VectorDbl) { + return _swig_wrap_Test_v_get(arg1) +} + +var _wrap_Test_x_set unsafe.Pointer + +func _swig_wrap_Test_x_set(base SwigcptrTest, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Test_x_set, _swig_p) + return +} + +func (arg1 SwigcptrTest) SetX(arg2 int) { + _swig_wrap_Test_x_set(arg1, arg2) +} + +var _wrap_Test_x_get unsafe.Pointer + +func _swig_wrap_Test_x_get(base SwigcptrTest) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Test_x_get, _swig_p) + return +} + +func (arg1 SwigcptrTest) GetX() (_swig_ret int) { + return _swig_wrap_Test_x_get(arg1) +} + +var _wrap_new_Test unsafe.Pointer + +func _swig_wrap_new_Test() (base SwigcptrTest) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Test, _swig_p) + return +} + +func NewTest() (_swig_ret Test) { + return _swig_wrap_new_Test() +} + +var _wrap_Test_f unsafe.Pointer + +func _swig_wrap_Test_f(base SwigcptrTest, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Test_f, _swig_p) + return +} + +func (arg1 SwigcptrTest) F(arg2 int) { + _swig_wrap_Test_f(arg1, arg2) +} + +var _wrap_delete_Test unsafe.Pointer + +func _swig_wrap_delete_Test(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Test, _swig_p) + return +} + +func DeleteTest(arg1 Test) { + _swig_wrap_delete_Test(arg1.Swigcptr()) +} + +type Test interface { + Swigcptr() uintptr + SwigIsTest() + SetV(arg2 VectorDbl) + GetV() (_swig_ret VectorDbl) + SetX(arg2 int) + GetX() (_swig_ret int) + F(arg2 int) +} + +type SwigcptrS uintptr + +func (p SwigcptrS) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrS) SwigIsS() { +} + +var _wrap_S_x_set unsafe.Pointer + +func _swig_wrap_S_x_set(base SwigcptrS, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_S_x_set, _swig_p) + return +} + +func (arg1 SwigcptrS) SetX(arg2 int) { + _swig_wrap_S_x_set(arg1, arg2) +} + +var _wrap_S_x_get unsafe.Pointer + +func _swig_wrap_S_x_get(base SwigcptrS) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_S_x_get, _swig_p) + return +} + +func (arg1 SwigcptrS) GetX() (_swig_ret int) { + return _swig_wrap_S_x_get(arg1) +} + +var _wrap_new_S unsafe.Pointer + +func _swig_wrap_new_S() (base SwigcptrS) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_S, _swig_p) + return +} + +func NewS() (_swig_ret S) { + return _swig_wrap_new_S() +} + +var _wrap_delete_S unsafe.Pointer + +func _swig_wrap_delete_S(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_S, _swig_p) + return +} + +func DeleteS(arg1 S) { + _swig_wrap_delete_S(arg1.Swigcptr()) +} + +type S interface { + Swigcptr() uintptr + SwigIsS() + SetX(arg2 int) + GetX() (_swig_ret int) +} + +type SwigcptrT uintptr + +func (p SwigcptrT) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrT) SwigIsT() { +} + +var _wrap_T_start_t_set unsafe.Pointer + +func _swig_wrap_T_start_t_set(base SwigcptrT, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_T_start_t_set, _swig_p) + return +} + +func (arg1 SwigcptrT) SetStart_t(arg2 S) { + _swig_wrap_T_start_t_set(arg1, arg2.Swigcptr()) +} + +var _wrap_T_start_t_get unsafe.Pointer + +func _swig_wrap_T_start_t_get(base SwigcptrT) (_ SwigcptrS) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_T_start_t_get, _swig_p) + return +} + +func (arg1 SwigcptrT) GetStart_t() (_swig_ret S) { + return _swig_wrap_T_start_t_get(arg1) +} + +var _wrap_T_length_set unsafe.Pointer + +func _swig_wrap_T_length_set(base SwigcptrT, _ uint) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_T_length_set, _swig_p) + return +} + +func (arg1 SwigcptrT) SetLength(arg2 uint) { + _swig_wrap_T_length_set(arg1, arg2) +} + +var _wrap_T_length_get unsafe.Pointer + +func _swig_wrap_T_length_get(base SwigcptrT) (_ uint) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_T_length_get, _swig_p) + return +} + +func (arg1 SwigcptrT) GetLength() (_swig_ret uint) { + return _swig_wrap_T_length_get(arg1) +} + +var _wrap_new_T unsafe.Pointer + +func _swig_wrap_new_T() (base SwigcptrT) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_T, _swig_p) + return +} + +func NewT() (_swig_ret T) { + return _swig_wrap_new_T() +} + +var _wrap_delete_T unsafe.Pointer + +func _swig_wrap_delete_T(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_T, _swig_p) + return +} + +func DeleteT(arg1 T) { + _swig_wrap_delete_T(arg1.Swigcptr()) +} + +type T interface { + Swigcptr() uintptr + SwigIsT() + SetStart_t(arg2 S) + GetStart_t() (_swig_ret S) + SetLength(arg2 uint) + GetLength() (_swig_ret uint) +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/li_stdint.go b/Examples/test-suite/go/li_stdint.go new file mode 100644 index 000000000..cd5d0b0ab --- /dev/null +++ b/Examples/test-suite/go/li_stdint.go @@ -0,0 +1,943 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../li_stdint.i + +package li_stdint + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrStdInts uintptr + +func (p SwigcptrStdInts) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrStdInts) SwigIsStdInts() { +} + +var _wrap_StdInts_int8_member_set unsafe.Pointer + +func _swig_wrap_StdInts_int8_member_set(base SwigcptrStdInts, _ int8) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_StdInts_int8_member_set, _swig_p) + return +} + +func (arg1 SwigcptrStdInts) SetInt8_member(arg2 int8) { + _swig_wrap_StdInts_int8_member_set(arg1, arg2) +} + +var _wrap_StdInts_int8_member_get unsafe.Pointer + +func _swig_wrap_StdInts_int8_member_get(base SwigcptrStdInts) (_ int8) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_StdInts_int8_member_get, _swig_p) + return +} + +func (arg1 SwigcptrStdInts) GetInt8_member() (_swig_ret int8) { + return _swig_wrap_StdInts_int8_member_get(arg1) +} + +var _wrap_StdInts_int16_member_set unsafe.Pointer + +func _swig_wrap_StdInts_int16_member_set(base SwigcptrStdInts, _ int16) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_StdInts_int16_member_set, _swig_p) + return +} + +func (arg1 SwigcptrStdInts) SetInt16_member(arg2 int16) { + _swig_wrap_StdInts_int16_member_set(arg1, arg2) +} + +var _wrap_StdInts_int16_member_get unsafe.Pointer + +func _swig_wrap_StdInts_int16_member_get(base SwigcptrStdInts) (_ int16) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_StdInts_int16_member_get, _swig_p) + return +} + +func (arg1 SwigcptrStdInts) GetInt16_member() (_swig_ret int16) { + return _swig_wrap_StdInts_int16_member_get(arg1) +} + +var _wrap_StdInts_int32_member_set unsafe.Pointer + +func _swig_wrap_StdInts_int32_member_set(base SwigcptrStdInts, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_StdInts_int32_member_set, _swig_p) + return +} + +func (arg1 SwigcptrStdInts) SetInt32_member(arg2 int) { + _swig_wrap_StdInts_int32_member_set(arg1, arg2) +} + +var _wrap_StdInts_int32_member_get unsafe.Pointer + +func _swig_wrap_StdInts_int32_member_get(base SwigcptrStdInts) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_StdInts_int32_member_get, _swig_p) + return +} + +func (arg1 SwigcptrStdInts) GetInt32_member() (_swig_ret int) { + return _swig_wrap_StdInts_int32_member_get(arg1) +} + +var _wrap_StdInts_int64_member_set unsafe.Pointer + +func _swig_wrap_StdInts_int64_member_set(base SwigcptrStdInts, _ int64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_StdInts_int64_member_set, _swig_p) + return +} + +func (arg1 SwigcptrStdInts) SetInt64_member(arg2 int64) { + _swig_wrap_StdInts_int64_member_set(arg1, arg2) +} + +var _wrap_StdInts_int64_member_get unsafe.Pointer + +func _swig_wrap_StdInts_int64_member_get(base SwigcptrStdInts) (_ int64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_StdInts_int64_member_get, _swig_p) + return +} + +func (arg1 SwigcptrStdInts) GetInt64_member() (_swig_ret int64) { + return _swig_wrap_StdInts_int64_member_get(arg1) +} + +var _wrap_StdInts_uint8_member_set unsafe.Pointer + +func _swig_wrap_StdInts_uint8_member_set(base SwigcptrStdInts, _ byte) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_StdInts_uint8_member_set, _swig_p) + return +} + +func (arg1 SwigcptrStdInts) SetUint8_member(arg2 byte) { + _swig_wrap_StdInts_uint8_member_set(arg1, arg2) +} + +var _wrap_StdInts_uint8_member_get unsafe.Pointer + +func _swig_wrap_StdInts_uint8_member_get(base SwigcptrStdInts) (_ byte) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_StdInts_uint8_member_get, _swig_p) + return +} + +func (arg1 SwigcptrStdInts) GetUint8_member() (_swig_ret byte) { + return _swig_wrap_StdInts_uint8_member_get(arg1) +} + +var _wrap_StdInts_uint16_member_set unsafe.Pointer + +func _swig_wrap_StdInts_uint16_member_set(base SwigcptrStdInts, _ uint16) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_StdInts_uint16_member_set, _swig_p) + return +} + +func (arg1 SwigcptrStdInts) SetUint16_member(arg2 uint16) { + _swig_wrap_StdInts_uint16_member_set(arg1, arg2) +} + +var _wrap_StdInts_uint16_member_get unsafe.Pointer + +func _swig_wrap_StdInts_uint16_member_get(base SwigcptrStdInts) (_ uint16) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_StdInts_uint16_member_get, _swig_p) + return +} + +func (arg1 SwigcptrStdInts) GetUint16_member() (_swig_ret uint16) { + return _swig_wrap_StdInts_uint16_member_get(arg1) +} + +var _wrap_StdInts_uint32_member_set unsafe.Pointer + +func _swig_wrap_StdInts_uint32_member_set(base SwigcptrStdInts, _ uint) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_StdInts_uint32_member_set, _swig_p) + return +} + +func (arg1 SwigcptrStdInts) SetUint32_member(arg2 uint) { + _swig_wrap_StdInts_uint32_member_set(arg1, arg2) +} + +var _wrap_StdInts_uint32_member_get unsafe.Pointer + +func _swig_wrap_StdInts_uint32_member_get(base SwigcptrStdInts) (_ uint) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_StdInts_uint32_member_get, _swig_p) + return +} + +func (arg1 SwigcptrStdInts) GetUint32_member() (_swig_ret uint) { + return _swig_wrap_StdInts_uint32_member_get(arg1) +} + +var _wrap_StdInts_uint64_member_set unsafe.Pointer + +func _swig_wrap_StdInts_uint64_member_set(base SwigcptrStdInts, _ uint64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_StdInts_uint64_member_set, _swig_p) + return +} + +func (arg1 SwigcptrStdInts) SetUint64_member(arg2 uint64) { + _swig_wrap_StdInts_uint64_member_set(arg1, arg2) +} + +var _wrap_StdInts_uint64_member_get unsafe.Pointer + +func _swig_wrap_StdInts_uint64_member_get(base SwigcptrStdInts) (_ uint64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_StdInts_uint64_member_get, _swig_p) + return +} + +func (arg1 SwigcptrStdInts) GetUint64_member() (_swig_ret uint64) { + return _swig_wrap_StdInts_uint64_member_get(arg1) +} + +var _wrap_new_StdInts unsafe.Pointer + +func _swig_wrap_new_StdInts() (base SwigcptrStdInts) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_StdInts, _swig_p) + return +} + +func NewStdInts() (_swig_ret StdInts) { + return _swig_wrap_new_StdInts() +} + +var _wrap_delete_StdInts unsafe.Pointer + +func _swig_wrap_delete_StdInts(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_StdInts, _swig_p) + return +} + +func DeleteStdInts(arg1 StdInts) { + _swig_wrap_delete_StdInts(arg1.Swigcptr()) +} + +type StdInts interface { + Swigcptr() uintptr + SwigIsStdInts() + SetInt8_member(arg2 int8) + GetInt8_member() (_swig_ret int8) + SetInt16_member(arg2 int16) + GetInt16_member() (_swig_ret int16) + SetInt32_member(arg2 int) + GetInt32_member() (_swig_ret int) + SetInt64_member(arg2 int64) + GetInt64_member() (_swig_ret int64) + SetUint8_member(arg2 byte) + GetUint8_member() (_swig_ret byte) + SetUint16_member(arg2 uint16) + GetUint16_member() (_swig_ret uint16) + SetUint32_member(arg2 uint) + GetUint32_member() (_swig_ret uint) + SetUint64_member(arg2 uint64) + GetUint64_member() (_swig_ret uint64) +} + +var _wrap_int8_td unsafe.Pointer + +func Int8_td(arg1 int8) (_swig_ret int8) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_int8_td, _swig_p) + return +} +var _wrap_int16_td unsafe.Pointer + +func Int16_td(arg1 int16) (_swig_ret int16) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_int16_td, _swig_p) + return +} +var _wrap_int32_td unsafe.Pointer + +func Int32_td(arg1 int) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_int32_td, _swig_p) + return +} +var _wrap_int64_td unsafe.Pointer + +func Int64_td(arg1 int64) (_swig_ret int64) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_int64_td, _swig_p) + return +} +var _wrap_uint8_td unsafe.Pointer + +func Uint8_td(arg1 int8) (_swig_ret byte) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_uint8_td, _swig_p) + return +} +var _wrap_uint16_td unsafe.Pointer + +func Uint16_td(arg1 int16) (_swig_ret uint16) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_uint16_td, _swig_p) + return +} +var _wrap_uint32_td unsafe.Pointer + +func Uint32_td(arg1 int) (_swig_ret uint) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_uint32_td, _swig_p) + return +} +var _wrap_uint64_td unsafe.Pointer + +func Uint64_td(arg1 int64) (_swig_ret uint64) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_uint64_td, _swig_p) + return +} +type SwigcptrStdIntFasts uintptr + +func (p SwigcptrStdIntFasts) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrStdIntFasts) SwigIsStdIntFasts() { +} + +var _wrap_StdIntFasts_int_fast8_member_set unsafe.Pointer + +func _swig_wrap_StdIntFasts_int_fast8_member_set(base SwigcptrStdIntFasts, _ int8) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_StdIntFasts_int_fast8_member_set, _swig_p) + return +} + +func (arg1 SwigcptrStdIntFasts) SetInt_fast8_member(arg2 int8) { + _swig_wrap_StdIntFasts_int_fast8_member_set(arg1, arg2) +} + +var _wrap_StdIntFasts_int_fast8_member_get unsafe.Pointer + +func _swig_wrap_StdIntFasts_int_fast8_member_get(base SwigcptrStdIntFasts) (_ int8) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_StdIntFasts_int_fast8_member_get, _swig_p) + return +} + +func (arg1 SwigcptrStdIntFasts) GetInt_fast8_member() (_swig_ret int8) { + return _swig_wrap_StdIntFasts_int_fast8_member_get(arg1) +} + +var _wrap_StdIntFasts_int_fast16_member_set unsafe.Pointer + +func _swig_wrap_StdIntFasts_int_fast16_member_set(base SwigcptrStdIntFasts, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_StdIntFasts_int_fast16_member_set, _swig_p) + return +} + +func (arg1 SwigcptrStdIntFasts) SetInt_fast16_member(arg2 int) { + _swig_wrap_StdIntFasts_int_fast16_member_set(arg1, arg2) +} + +var _wrap_StdIntFasts_int_fast16_member_get unsafe.Pointer + +func _swig_wrap_StdIntFasts_int_fast16_member_get(base SwigcptrStdIntFasts) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_StdIntFasts_int_fast16_member_get, _swig_p) + return +} + +func (arg1 SwigcptrStdIntFasts) GetInt_fast16_member() (_swig_ret int) { + return _swig_wrap_StdIntFasts_int_fast16_member_get(arg1) +} + +var _wrap_StdIntFasts_int_fast32_member_set unsafe.Pointer + +func _swig_wrap_StdIntFasts_int_fast32_member_set(base SwigcptrStdIntFasts, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_StdIntFasts_int_fast32_member_set, _swig_p) + return +} + +func (arg1 SwigcptrStdIntFasts) SetInt_fast32_member(arg2 int) { + _swig_wrap_StdIntFasts_int_fast32_member_set(arg1, arg2) +} + +var _wrap_StdIntFasts_int_fast32_member_get unsafe.Pointer + +func _swig_wrap_StdIntFasts_int_fast32_member_get(base SwigcptrStdIntFasts) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_StdIntFasts_int_fast32_member_get, _swig_p) + return +} + +func (arg1 SwigcptrStdIntFasts) GetInt_fast32_member() (_swig_ret int) { + return _swig_wrap_StdIntFasts_int_fast32_member_get(arg1) +} + +var _wrap_StdIntFasts_int_fast64_member_set unsafe.Pointer + +func _swig_wrap_StdIntFasts_int_fast64_member_set(base SwigcptrStdIntFasts, _ int64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_StdIntFasts_int_fast64_member_set, _swig_p) + return +} + +func (arg1 SwigcptrStdIntFasts) SetInt_fast64_member(arg2 int64) { + _swig_wrap_StdIntFasts_int_fast64_member_set(arg1, arg2) +} + +var _wrap_StdIntFasts_int_fast64_member_get unsafe.Pointer + +func _swig_wrap_StdIntFasts_int_fast64_member_get(base SwigcptrStdIntFasts) (_ int64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_StdIntFasts_int_fast64_member_get, _swig_p) + return +} + +func (arg1 SwigcptrStdIntFasts) GetInt_fast64_member() (_swig_ret int64) { + return _swig_wrap_StdIntFasts_int_fast64_member_get(arg1) +} + +var _wrap_StdIntFasts_uint_fast8_member_set unsafe.Pointer + +func _swig_wrap_StdIntFasts_uint_fast8_member_set(base SwigcptrStdIntFasts, _ byte) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_StdIntFasts_uint_fast8_member_set, _swig_p) + return +} + +func (arg1 SwigcptrStdIntFasts) SetUint_fast8_member(arg2 byte) { + _swig_wrap_StdIntFasts_uint_fast8_member_set(arg1, arg2) +} + +var _wrap_StdIntFasts_uint_fast8_member_get unsafe.Pointer + +func _swig_wrap_StdIntFasts_uint_fast8_member_get(base SwigcptrStdIntFasts) (_ byte) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_StdIntFasts_uint_fast8_member_get, _swig_p) + return +} + +func (arg1 SwigcptrStdIntFasts) GetUint_fast8_member() (_swig_ret byte) { + return _swig_wrap_StdIntFasts_uint_fast8_member_get(arg1) +} + +var _wrap_StdIntFasts_uint_fast16_member_set unsafe.Pointer + +func _swig_wrap_StdIntFasts_uint_fast16_member_set(base SwigcptrStdIntFasts, _ uint) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_StdIntFasts_uint_fast16_member_set, _swig_p) + return +} + +func (arg1 SwigcptrStdIntFasts) SetUint_fast16_member(arg2 uint) { + _swig_wrap_StdIntFasts_uint_fast16_member_set(arg1, arg2) +} + +var _wrap_StdIntFasts_uint_fast16_member_get unsafe.Pointer + +func _swig_wrap_StdIntFasts_uint_fast16_member_get(base SwigcptrStdIntFasts) (_ uint) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_StdIntFasts_uint_fast16_member_get, _swig_p) + return +} + +func (arg1 SwigcptrStdIntFasts) GetUint_fast16_member() (_swig_ret uint) { + return _swig_wrap_StdIntFasts_uint_fast16_member_get(arg1) +} + +var _wrap_StdIntFasts_uint_fast32_member_set unsafe.Pointer + +func _swig_wrap_StdIntFasts_uint_fast32_member_set(base SwigcptrStdIntFasts, _ uint) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_StdIntFasts_uint_fast32_member_set, _swig_p) + return +} + +func (arg1 SwigcptrStdIntFasts) SetUint_fast32_member(arg2 uint) { + _swig_wrap_StdIntFasts_uint_fast32_member_set(arg1, arg2) +} + +var _wrap_StdIntFasts_uint_fast32_member_get unsafe.Pointer + +func _swig_wrap_StdIntFasts_uint_fast32_member_get(base SwigcptrStdIntFasts) (_ uint) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_StdIntFasts_uint_fast32_member_get, _swig_p) + return +} + +func (arg1 SwigcptrStdIntFasts) GetUint_fast32_member() (_swig_ret uint) { + return _swig_wrap_StdIntFasts_uint_fast32_member_get(arg1) +} + +var _wrap_StdIntFasts_uint_fast64_member_set unsafe.Pointer + +func _swig_wrap_StdIntFasts_uint_fast64_member_set(base SwigcptrStdIntFasts, _ uint64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_StdIntFasts_uint_fast64_member_set, _swig_p) + return +} + +func (arg1 SwigcptrStdIntFasts) SetUint_fast64_member(arg2 uint64) { + _swig_wrap_StdIntFasts_uint_fast64_member_set(arg1, arg2) +} + +var _wrap_StdIntFasts_uint_fast64_member_get unsafe.Pointer + +func _swig_wrap_StdIntFasts_uint_fast64_member_get(base SwigcptrStdIntFasts) (_ uint64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_StdIntFasts_uint_fast64_member_get, _swig_p) + return +} + +func (arg1 SwigcptrStdIntFasts) GetUint_fast64_member() (_swig_ret uint64) { + return _swig_wrap_StdIntFasts_uint_fast64_member_get(arg1) +} + +var _wrap_new_StdIntFasts unsafe.Pointer + +func _swig_wrap_new_StdIntFasts() (base SwigcptrStdIntFasts) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_StdIntFasts, _swig_p) + return +} + +func NewStdIntFasts() (_swig_ret StdIntFasts) { + return _swig_wrap_new_StdIntFasts() +} + +var _wrap_delete_StdIntFasts unsafe.Pointer + +func _swig_wrap_delete_StdIntFasts(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_StdIntFasts, _swig_p) + return +} + +func DeleteStdIntFasts(arg1 StdIntFasts) { + _swig_wrap_delete_StdIntFasts(arg1.Swigcptr()) +} + +type StdIntFasts interface { + Swigcptr() uintptr + SwigIsStdIntFasts() + SetInt_fast8_member(arg2 int8) + GetInt_fast8_member() (_swig_ret int8) + SetInt_fast16_member(arg2 int) + GetInt_fast16_member() (_swig_ret int) + SetInt_fast32_member(arg2 int) + GetInt_fast32_member() (_swig_ret int) + SetInt_fast64_member(arg2 int64) + GetInt_fast64_member() (_swig_ret int64) + SetUint_fast8_member(arg2 byte) + GetUint_fast8_member() (_swig_ret byte) + SetUint_fast16_member(arg2 uint) + GetUint_fast16_member() (_swig_ret uint) + SetUint_fast32_member(arg2 uint) + GetUint_fast32_member() (_swig_ret uint) + SetUint_fast64_member(arg2 uint64) + GetUint_fast64_member() (_swig_ret uint64) +} + +var _wrap_int_fast8_td unsafe.Pointer + +func Int_fast8_td(arg1 int8) (_swig_ret int8) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_int_fast8_td, _swig_p) + return +} +var _wrap_int_fast16_td unsafe.Pointer + +func Int_fast16_td(arg1 int) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_int_fast16_td, _swig_p) + return +} +var _wrap_int_fast32_td unsafe.Pointer + +func Int_fast32_td(arg1 int) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_int_fast32_td, _swig_p) + return +} +var _wrap_int_fast64_td unsafe.Pointer + +func Int_fast64_td(arg1 int64) (_swig_ret int64) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_int_fast64_td, _swig_p) + return +} +var _wrap_uint_fast8_td unsafe.Pointer + +func Uint_fast8_td(arg1 int8) (_swig_ret byte) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_uint_fast8_td, _swig_p) + return +} +var _wrap_uint_fast16_td unsafe.Pointer + +func Uint_fast16_td(arg1 int) (_swig_ret uint) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_uint_fast16_td, _swig_p) + return +} +var _wrap_uint_fast32_td unsafe.Pointer + +func Uint_fast32_td(arg1 int) (_swig_ret uint) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_uint_fast32_td, _swig_p) + return +} +var _wrap_uint_fast64_td unsafe.Pointer + +func Uint_fast64_td(arg1 int64) (_swig_ret uint64) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_uint_fast64_td, _swig_p) + return +} +type SwigcptrStdIntLeasts uintptr + +func (p SwigcptrStdIntLeasts) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrStdIntLeasts) SwigIsStdIntLeasts() { +} + +var _wrap_StdIntLeasts_int_least8_member_set unsafe.Pointer + +func _swig_wrap_StdIntLeasts_int_least8_member_set(base SwigcptrStdIntLeasts, _ int8) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_StdIntLeasts_int_least8_member_set, _swig_p) + return +} + +func (arg1 SwigcptrStdIntLeasts) SetInt_least8_member(arg2 int8) { + _swig_wrap_StdIntLeasts_int_least8_member_set(arg1, arg2) +} + +var _wrap_StdIntLeasts_int_least8_member_get unsafe.Pointer + +func _swig_wrap_StdIntLeasts_int_least8_member_get(base SwigcptrStdIntLeasts) (_ int8) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_StdIntLeasts_int_least8_member_get, _swig_p) + return +} + +func (arg1 SwigcptrStdIntLeasts) GetInt_least8_member() (_swig_ret int8) { + return _swig_wrap_StdIntLeasts_int_least8_member_get(arg1) +} + +var _wrap_StdIntLeasts_int_least16_member_set unsafe.Pointer + +func _swig_wrap_StdIntLeasts_int_least16_member_set(base SwigcptrStdIntLeasts, _ int16) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_StdIntLeasts_int_least16_member_set, _swig_p) + return +} + +func (arg1 SwigcptrStdIntLeasts) SetInt_least16_member(arg2 int16) { + _swig_wrap_StdIntLeasts_int_least16_member_set(arg1, arg2) +} + +var _wrap_StdIntLeasts_int_least16_member_get unsafe.Pointer + +func _swig_wrap_StdIntLeasts_int_least16_member_get(base SwigcptrStdIntLeasts) (_ int16) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_StdIntLeasts_int_least16_member_get, _swig_p) + return +} + +func (arg1 SwigcptrStdIntLeasts) GetInt_least16_member() (_swig_ret int16) { + return _swig_wrap_StdIntLeasts_int_least16_member_get(arg1) +} + +var _wrap_StdIntLeasts_int_least32_member_set unsafe.Pointer + +func _swig_wrap_StdIntLeasts_int_least32_member_set(base SwigcptrStdIntLeasts, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_StdIntLeasts_int_least32_member_set, _swig_p) + return +} + +func (arg1 SwigcptrStdIntLeasts) SetInt_least32_member(arg2 int) { + _swig_wrap_StdIntLeasts_int_least32_member_set(arg1, arg2) +} + +var _wrap_StdIntLeasts_int_least32_member_get unsafe.Pointer + +func _swig_wrap_StdIntLeasts_int_least32_member_get(base SwigcptrStdIntLeasts) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_StdIntLeasts_int_least32_member_get, _swig_p) + return +} + +func (arg1 SwigcptrStdIntLeasts) GetInt_least32_member() (_swig_ret int) { + return _swig_wrap_StdIntLeasts_int_least32_member_get(arg1) +} + +var _wrap_StdIntLeasts_int_least64_member_set unsafe.Pointer + +func _swig_wrap_StdIntLeasts_int_least64_member_set(base SwigcptrStdIntLeasts, _ int64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_StdIntLeasts_int_least64_member_set, _swig_p) + return +} + +func (arg1 SwigcptrStdIntLeasts) SetInt_least64_member(arg2 int64) { + _swig_wrap_StdIntLeasts_int_least64_member_set(arg1, arg2) +} + +var _wrap_StdIntLeasts_int_least64_member_get unsafe.Pointer + +func _swig_wrap_StdIntLeasts_int_least64_member_get(base SwigcptrStdIntLeasts) (_ int64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_StdIntLeasts_int_least64_member_get, _swig_p) + return +} + +func (arg1 SwigcptrStdIntLeasts) GetInt_least64_member() (_swig_ret int64) { + return _swig_wrap_StdIntLeasts_int_least64_member_get(arg1) +} + +var _wrap_StdIntLeasts_uint_least8_member_set unsafe.Pointer + +func _swig_wrap_StdIntLeasts_uint_least8_member_set(base SwigcptrStdIntLeasts, _ byte) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_StdIntLeasts_uint_least8_member_set, _swig_p) + return +} + +func (arg1 SwigcptrStdIntLeasts) SetUint_least8_member(arg2 byte) { + _swig_wrap_StdIntLeasts_uint_least8_member_set(arg1, arg2) +} + +var _wrap_StdIntLeasts_uint_least8_member_get unsafe.Pointer + +func _swig_wrap_StdIntLeasts_uint_least8_member_get(base SwigcptrStdIntLeasts) (_ byte) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_StdIntLeasts_uint_least8_member_get, _swig_p) + return +} + +func (arg1 SwigcptrStdIntLeasts) GetUint_least8_member() (_swig_ret byte) { + return _swig_wrap_StdIntLeasts_uint_least8_member_get(arg1) +} + +var _wrap_StdIntLeasts_uint_least16_member_set unsafe.Pointer + +func _swig_wrap_StdIntLeasts_uint_least16_member_set(base SwigcptrStdIntLeasts, _ uint16) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_StdIntLeasts_uint_least16_member_set, _swig_p) + return +} + +func (arg1 SwigcptrStdIntLeasts) SetUint_least16_member(arg2 uint16) { + _swig_wrap_StdIntLeasts_uint_least16_member_set(arg1, arg2) +} + +var _wrap_StdIntLeasts_uint_least16_member_get unsafe.Pointer + +func _swig_wrap_StdIntLeasts_uint_least16_member_get(base SwigcptrStdIntLeasts) (_ uint16) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_StdIntLeasts_uint_least16_member_get, _swig_p) + return +} + +func (arg1 SwigcptrStdIntLeasts) GetUint_least16_member() (_swig_ret uint16) { + return _swig_wrap_StdIntLeasts_uint_least16_member_get(arg1) +} + +var _wrap_StdIntLeasts_uint_least32_member_set unsafe.Pointer + +func _swig_wrap_StdIntLeasts_uint_least32_member_set(base SwigcptrStdIntLeasts, _ uint) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_StdIntLeasts_uint_least32_member_set, _swig_p) + return +} + +func (arg1 SwigcptrStdIntLeasts) SetUint_least32_member(arg2 uint) { + _swig_wrap_StdIntLeasts_uint_least32_member_set(arg1, arg2) +} + +var _wrap_StdIntLeasts_uint_least32_member_get unsafe.Pointer + +func _swig_wrap_StdIntLeasts_uint_least32_member_get(base SwigcptrStdIntLeasts) (_ uint) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_StdIntLeasts_uint_least32_member_get, _swig_p) + return +} + +func (arg1 SwigcptrStdIntLeasts) GetUint_least32_member() (_swig_ret uint) { + return _swig_wrap_StdIntLeasts_uint_least32_member_get(arg1) +} + +var _wrap_StdIntLeasts_uint_least64_member_set unsafe.Pointer + +func _swig_wrap_StdIntLeasts_uint_least64_member_set(base SwigcptrStdIntLeasts, _ uint64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_StdIntLeasts_uint_least64_member_set, _swig_p) + return +} + +func (arg1 SwigcptrStdIntLeasts) SetUint_least64_member(arg2 uint64) { + _swig_wrap_StdIntLeasts_uint_least64_member_set(arg1, arg2) +} + +var _wrap_StdIntLeasts_uint_least64_member_get unsafe.Pointer + +func _swig_wrap_StdIntLeasts_uint_least64_member_get(base SwigcptrStdIntLeasts) (_ uint64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_StdIntLeasts_uint_least64_member_get, _swig_p) + return +} + +func (arg1 SwigcptrStdIntLeasts) GetUint_least64_member() (_swig_ret uint64) { + return _swig_wrap_StdIntLeasts_uint_least64_member_get(arg1) +} + +var _wrap_new_StdIntLeasts unsafe.Pointer + +func _swig_wrap_new_StdIntLeasts() (base SwigcptrStdIntLeasts) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_StdIntLeasts, _swig_p) + return +} + +func NewStdIntLeasts() (_swig_ret StdIntLeasts) { + return _swig_wrap_new_StdIntLeasts() +} + +var _wrap_delete_StdIntLeasts unsafe.Pointer + +func _swig_wrap_delete_StdIntLeasts(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_StdIntLeasts, _swig_p) + return +} + +func DeleteStdIntLeasts(arg1 StdIntLeasts) { + _swig_wrap_delete_StdIntLeasts(arg1.Swigcptr()) +} + +type StdIntLeasts interface { + Swigcptr() uintptr + SwigIsStdIntLeasts() + SetInt_least8_member(arg2 int8) + GetInt_least8_member() (_swig_ret int8) + SetInt_least16_member(arg2 int16) + GetInt_least16_member() (_swig_ret int16) + SetInt_least32_member(arg2 int) + GetInt_least32_member() (_swig_ret int) + SetInt_least64_member(arg2 int64) + GetInt_least64_member() (_swig_ret int64) + SetUint_least8_member(arg2 byte) + GetUint_least8_member() (_swig_ret byte) + SetUint_least16_member(arg2 uint16) + GetUint_least16_member() (_swig_ret uint16) + SetUint_least32_member(arg2 uint) + GetUint_least32_member() (_swig_ret uint) + SetUint_least64_member(arg2 uint64) + GetUint_least64_member() (_swig_ret uint64) +} + +var _wrap_int_least8_td unsafe.Pointer + +func Int_least8_td(arg1 int8) (_swig_ret int8) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_int_least8_td, _swig_p) + return +} +var _wrap_int_least16_td unsafe.Pointer + +func Int_least16_td(arg1 int16) (_swig_ret int16) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_int_least16_td, _swig_p) + return +} +var _wrap_int_least32_td unsafe.Pointer + +func Int_least32_td(arg1 int) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_int_least32_td, _swig_p) + return +} +var _wrap_int_least64_td unsafe.Pointer + +func Int_least64_td(arg1 int64) (_swig_ret int64) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_int_least64_td, _swig_p) + return +} +var _wrap_uint_least8_td unsafe.Pointer + +func Uint_least8_td(arg1 int8) (_swig_ret byte) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_uint_least8_td, _swig_p) + return +} +var _wrap_uint_least16_td unsafe.Pointer + +func Uint_least16_td(arg1 int16) (_swig_ret uint16) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_uint_least16_td, _swig_p) + return +} +var _wrap_uint_least32_td unsafe.Pointer + +func Uint_least32_td(arg1 int) (_swig_ret uint) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_uint_least32_td, _swig_p) + return +} +var _wrap_uint_least64_td unsafe.Pointer + +func Uint_least64_td(arg1 int64) (_swig_ret uint64) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_uint_least64_td, _swig_p) + return +} + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/li_swigtype_inout.go b/Examples/test-suite/go/li_swigtype_inout.go new file mode 100644 index 000000000..82019831b --- /dev/null +++ b/Examples/test-suite/go/li_swigtype_inout.go @@ -0,0 +1,218 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../li_swigtype_inout.i + +package li_swigtype_inout + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrXXX uintptr + +func (p SwigcptrXXX) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrXXX) SwigIsXXX() { +} + +var _wrap_new_XXX__SWIG_0 unsafe.Pointer + +func _swig_wrap_new_XXX__SWIG_0(base int) (_ SwigcptrXXX) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_XXX__SWIG_0, _swig_p) + return +} + +func NewXXX__SWIG_0(arg1 int) (_swig_ret XXX) { + return _swig_wrap_new_XXX__SWIG_0(arg1) +} + +var _wrap_new_XXX__SWIG_1 unsafe.Pointer + +func _swig_wrap_new_XXX__SWIG_1(base uintptr) (_ SwigcptrXXX) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_XXX__SWIG_1, _swig_p) + return +} + +func NewXXX__SWIG_1(arg1 XXX) (_swig_ret XXX) { + return _swig_wrap_new_XXX__SWIG_1(arg1.Swigcptr()) +} + +func NewXXX(a ...interface{}) XXX { + argc := len(a) + if argc == 1 { + if _, ok := a[0].(XXX); !ok { + goto check_1 + } + return NewXXX__SWIG_1(a[0].(XXX)) + } +check_1: + if argc == 1 { + return NewXXX__SWIG_0(a[0].(int)) + } + panic("No match for overloaded function call") +} + +var _wrap_delete_XXX unsafe.Pointer + +func _swig_wrap_delete_XXX(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_XXX, _swig_p) + return +} + +func DeleteXXX(arg1 XXX) { + _swig_wrap_delete_XXX(arg1.Swigcptr()) +} + +var _wrap_XXX_showInfo unsafe.Pointer + +func _swig_wrap_XXX_showInfo(base SwigcptrXXX) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_XXX_showInfo, _swig_p) + return +} + +func (arg1 SwigcptrXXX) ShowInfo() { + _swig_wrap_XXX_showInfo(arg1) +} + +var _wrap_XXX_value_set unsafe.Pointer + +func _swig_wrap_XXX_value_set(base SwigcptrXXX, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_XXX_value_set, _swig_p) + return +} + +func (arg1 SwigcptrXXX) SetValue(arg2 int) { + _swig_wrap_XXX_value_set(arg1, arg2) +} + +var _wrap_XXX_value_get unsafe.Pointer + +func _swig_wrap_XXX_value_get(base SwigcptrXXX) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_XXX_value_get, _swig_p) + return +} + +func (arg1 SwigcptrXXX) GetValue() (_swig_ret int) { + return _swig_wrap_XXX_value_get(arg1) +} + +var _wrap_XXX_debug_XXX unsafe.Pointer + +func _swig_getXXX_XXX_debug_XXX() (_swig_ret bool) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_XXX_debug_XXX, _swig_p) + return +} +var XXXDebug bool = _swig_getXXX_XXX_debug_XXX() +var _wrap_XXX_count_set unsafe.Pointer + +func _swig_wrap_XXX_count_set(base int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_XXX_count_set, _swig_p) + return +} + +func SetXXXCount(arg1 int) { + _swig_wrap_XXX_count_set(arg1) +} + +var _wrap_XXX_count_get unsafe.Pointer + +func GetXXXCount() (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_XXX_count_get, _swig_p) + return +} +type XXX interface { + Swigcptr() uintptr + SwigIsXXX() + ShowInfo() + SetValue(arg2 int) + GetValue() (_swig_ret int) +} + +var _wrap_ptr_ref_out unsafe.Pointer + +func _swig_wrap_ptr_ref_out(base uintptr, _ uintptr, _ uintptr, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_ptr_ref_out, _swig_p) + return +} + +func Ptr_ref_out(arg1 XXX, arg2 XXX, arg3 XXX, arg4 XXX) { + _swig_wrap_ptr_ref_out(arg1.Swigcptr(), arg2.Swigcptr(), arg3.Swigcptr(), arg4.Swigcptr()) +} + +type SwigcptrConstructorTest uintptr + +func (p SwigcptrConstructorTest) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrConstructorTest) SwigIsConstructorTest() { +} + +var _wrap_new_ConstructorTest unsafe.Pointer + +func _swig_wrap_new_ConstructorTest(base uintptr, _ uintptr, _ uintptr, _ uintptr) (_ SwigcptrConstructorTest) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_ConstructorTest, _swig_p) + return +} + +func NewConstructorTest(arg1 XXX, arg2 XXX, arg3 XXX, arg4 XXX) (_swig_ret ConstructorTest) { + return _swig_wrap_new_ConstructorTest(arg1.Swigcptr(), arg2.Swigcptr(), arg3.Swigcptr(), arg4.Swigcptr()) +} + +var _wrap_delete_ConstructorTest unsafe.Pointer + +func _swig_wrap_delete_ConstructorTest(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_ConstructorTest, _swig_p) + return +} + +func DeleteConstructorTest(arg1 ConstructorTest) { + _swig_wrap_delete_ConstructorTest(arg1.Swigcptr()) +} + +type ConstructorTest interface { + Swigcptr() uintptr + SwigIsConstructorTest() +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/li_typemaps.go b/Examples/test-suite/go/li_typemaps.go new file mode 100644 index 000000000..88448449d --- /dev/null +++ b/Examples/test-suite/go/li_typemaps.go @@ -0,0 +1,931 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../li_typemaps.i + +package li_typemaps + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrFoo uintptr + +func (p SwigcptrFoo) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrFoo) SwigIsFoo() { +} + +var _wrap_Foo_a_set unsafe.Pointer + +func _swig_wrap_Foo_a_set(base SwigcptrFoo, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_a_set, _swig_p) + return +} + +func (arg1 SwigcptrFoo) SetA(arg2 int) { + _swig_wrap_Foo_a_set(arg1, arg2) +} + +var _wrap_Foo_a_get unsafe.Pointer + +func _swig_wrap_Foo_a_get(base SwigcptrFoo) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_a_get, _swig_p) + return +} + +func (arg1 SwigcptrFoo) GetA() (_swig_ret int) { + return _swig_wrap_Foo_a_get(arg1) +} + +var _wrap_new_Foo unsafe.Pointer + +func _swig_wrap_new_Foo() (base SwigcptrFoo) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Foo, _swig_p) + return +} + +func NewFoo() (_swig_ret Foo) { + return _swig_wrap_new_Foo() +} + +var _wrap_delete_Foo unsafe.Pointer + +func _swig_wrap_delete_Foo(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Foo, _swig_p) + return +} + +func DeleteFoo(arg1 Foo) { + _swig_wrap_delete_Foo(arg1.Swigcptr()) +} + +type Foo interface { + Swigcptr() uintptr + SwigIsFoo() + SetA(arg2 int) + GetA() (_swig_ret int) +} + +var _wrap_in_bool unsafe.Pointer + +func In_bool(arg1 bool) (_swig_ret bool) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_in_bool, _swig_p) + return +} +var _wrap_in_int unsafe.Pointer + +func In_int(arg1 int) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_in_int, _swig_p) + return +} +var _wrap_in_long unsafe.Pointer + +func In_long(arg1 int64) (_swig_ret int64) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_in_long, _swig_p) + return +} +var _wrap_in_short unsafe.Pointer + +func In_short(arg1 int16) (_swig_ret int16) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_in_short, _swig_p) + return +} +var _wrap_in_uint unsafe.Pointer + +func In_uint(arg1 uint) (_swig_ret uint) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_in_uint, _swig_p) + return +} +var _wrap_in_ushort unsafe.Pointer + +func In_ushort(arg1 uint16) (_swig_ret uint16) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_in_ushort, _swig_p) + return +} +var _wrap_in_ulong unsafe.Pointer + +func In_ulong(arg1 uint64) (_swig_ret uint64) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_in_ulong, _swig_p) + return +} +var _wrap_in_uchar unsafe.Pointer + +func In_uchar(arg1 byte) (_swig_ret byte) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_in_uchar, _swig_p) + return +} +var _wrap_in_schar unsafe.Pointer + +func In_schar(arg1 int8) (_swig_ret int8) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_in_schar, _swig_p) + return +} +var _wrap_in_float unsafe.Pointer + +func In_float(arg1 float32) (_swig_ret float32) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_in_float, _swig_p) + return +} +var _wrap_in_double unsafe.Pointer + +func In_double(arg1 float64) (_swig_ret float64) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_in_double, _swig_p) + return +} +var _wrap_in_longlong unsafe.Pointer + +func In_longlong(arg1 int64) (_swig_ret int64) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_in_longlong, _swig_p) + return +} +var _wrap_in_ulonglong unsafe.Pointer + +func In_ulonglong(arg1 uint64) (_swig_ret uint64) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_in_ulonglong, _swig_p) + return +} +var _wrap_inr_bool unsafe.Pointer + +func Inr_bool(arg1 bool) (_swig_ret bool) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_inr_bool, _swig_p) + return +} +var _wrap_inr_int unsafe.Pointer + +func Inr_int(arg1 int) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_inr_int, _swig_p) + return +} +var _wrap_inr_long unsafe.Pointer + +func Inr_long(arg1 int64) (_swig_ret int64) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_inr_long, _swig_p) + return +} +var _wrap_inr_short unsafe.Pointer + +func Inr_short(arg1 int16) (_swig_ret int16) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_inr_short, _swig_p) + return +} +var _wrap_inr_uint unsafe.Pointer + +func Inr_uint(arg1 uint) (_swig_ret uint) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_inr_uint, _swig_p) + return +} +var _wrap_inr_ushort unsafe.Pointer + +func Inr_ushort(arg1 uint16) (_swig_ret uint16) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_inr_ushort, _swig_p) + return +} +var _wrap_inr_ulong unsafe.Pointer + +func Inr_ulong(arg1 uint64) (_swig_ret uint64) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_inr_ulong, _swig_p) + return +} +var _wrap_inr_uchar unsafe.Pointer + +func Inr_uchar(arg1 byte) (_swig_ret byte) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_inr_uchar, _swig_p) + return +} +var _wrap_inr_schar unsafe.Pointer + +func Inr_schar(arg1 int8) (_swig_ret int8) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_inr_schar, _swig_p) + return +} +var _wrap_inr_float unsafe.Pointer + +func Inr_float(arg1 float32) (_swig_ret float32) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_inr_float, _swig_p) + return +} +var _wrap_inr_double unsafe.Pointer + +func Inr_double(arg1 float64) (_swig_ret float64) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_inr_double, _swig_p) + return +} +var _wrap_inr_longlong unsafe.Pointer + +func Inr_longlong(arg1 int64) (_swig_ret int64) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_inr_longlong, _swig_p) + return +} +var _wrap_inr_ulonglong unsafe.Pointer + +func Inr_ulonglong(arg1 uint64) (_swig_ret uint64) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_inr_ulonglong, _swig_p) + return +} +var _wrap_out_bool unsafe.Pointer + +func _swig_wrap_out_bool(base bool, _ []bool) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_out_bool, _swig_p) + return +} + +func Out_bool(arg1 bool, arg2 []bool) { + _swig_wrap_out_bool(arg1, arg2) +} + +var _wrap_out_int unsafe.Pointer + +func _swig_wrap_out_int(base int, _ []int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_out_int, _swig_p) + return +} + +func Out_int(arg1 int, arg2 []int) { + _swig_wrap_out_int(arg1, arg2) +} + +var _wrap_out_short unsafe.Pointer + +func _swig_wrap_out_short(base int16, _ []int16) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_out_short, _swig_p) + return +} + +func Out_short(arg1 int16, arg2 []int16) { + _swig_wrap_out_short(arg1, arg2) +} + +var _wrap_out_long unsafe.Pointer + +func _swig_wrap_out_long(base int64, _ []int64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_out_long, _swig_p) + return +} + +func Out_long(arg1 int64, arg2 []int64) { + _swig_wrap_out_long(arg1, arg2) +} + +var _wrap_out_uint unsafe.Pointer + +func _swig_wrap_out_uint(base uint, _ []uint) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_out_uint, _swig_p) + return +} + +func Out_uint(arg1 uint, arg2 []uint) { + _swig_wrap_out_uint(arg1, arg2) +} + +var _wrap_out_ushort unsafe.Pointer + +func _swig_wrap_out_ushort(base uint16, _ []uint16) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_out_ushort, _swig_p) + return +} + +func Out_ushort(arg1 uint16, arg2 []uint16) { + _swig_wrap_out_ushort(arg1, arg2) +} + +var _wrap_out_ulong unsafe.Pointer + +func _swig_wrap_out_ulong(base uint64, _ []uint64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_out_ulong, _swig_p) + return +} + +func Out_ulong(arg1 uint64, arg2 []uint64) { + _swig_wrap_out_ulong(arg1, arg2) +} + +var _wrap_out_uchar unsafe.Pointer + +func _swig_wrap_out_uchar(base byte, _ []byte) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_out_uchar, _swig_p) + return +} + +func Out_uchar(arg1 byte, arg2 []byte) { + _swig_wrap_out_uchar(arg1, arg2) +} + +var _wrap_out_schar unsafe.Pointer + +func _swig_wrap_out_schar(base int8, _ []int8) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_out_schar, _swig_p) + return +} + +func Out_schar(arg1 int8, arg2 []int8) { + _swig_wrap_out_schar(arg1, arg2) +} + +var _wrap_out_float unsafe.Pointer + +func _swig_wrap_out_float(base float32, _ []float32) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_out_float, _swig_p) + return +} + +func Out_float(arg1 float32, arg2 []float32) { + _swig_wrap_out_float(arg1, arg2) +} + +var _wrap_out_double unsafe.Pointer + +func _swig_wrap_out_double(base float64, _ []float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_out_double, _swig_p) + return +} + +func Out_double(arg1 float64, arg2 []float64) { + _swig_wrap_out_double(arg1, arg2) +} + +var _wrap_out_longlong unsafe.Pointer + +func _swig_wrap_out_longlong(base int64, _ []int64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_out_longlong, _swig_p) + return +} + +func Out_longlong(arg1 int64, arg2 []int64) { + _swig_wrap_out_longlong(arg1, arg2) +} + +var _wrap_out_ulonglong unsafe.Pointer + +func _swig_wrap_out_ulonglong(base uint64, _ []uint64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_out_ulonglong, _swig_p) + return +} + +func Out_ulonglong(arg1 uint64, arg2 []uint64) { + _swig_wrap_out_ulonglong(arg1, arg2) +} + +var _wrap_out_foo unsafe.Pointer + +func _swig_wrap_out_foo(base int, _ []int) (_ SwigcptrFoo) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_out_foo, _swig_p) + return +} + +func Out_foo(arg1 int, arg2 []int) (_swig_ret Foo) { + return _swig_wrap_out_foo(arg1, arg2) +} + +var _wrap_outr_bool unsafe.Pointer + +func _swig_wrap_outr_bool(base bool, _ []bool) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_outr_bool, _swig_p) + return +} + +func Outr_bool(arg1 bool, arg2 []bool) { + _swig_wrap_outr_bool(arg1, arg2) +} + +var _wrap_outr_int unsafe.Pointer + +func _swig_wrap_outr_int(base int, _ []int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_outr_int, _swig_p) + return +} + +func Outr_int(arg1 int, arg2 []int) { + _swig_wrap_outr_int(arg1, arg2) +} + +var _wrap_outr_short unsafe.Pointer + +func _swig_wrap_outr_short(base int16, _ []int16) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_outr_short, _swig_p) + return +} + +func Outr_short(arg1 int16, arg2 []int16) { + _swig_wrap_outr_short(arg1, arg2) +} + +var _wrap_outr_long unsafe.Pointer + +func _swig_wrap_outr_long(base int64, _ []int64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_outr_long, _swig_p) + return +} + +func Outr_long(arg1 int64, arg2 []int64) { + _swig_wrap_outr_long(arg1, arg2) +} + +var _wrap_outr_uint unsafe.Pointer + +func _swig_wrap_outr_uint(base uint, _ []uint) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_outr_uint, _swig_p) + return +} + +func Outr_uint(arg1 uint, arg2 []uint) { + _swig_wrap_outr_uint(arg1, arg2) +} + +var _wrap_outr_ushort unsafe.Pointer + +func _swig_wrap_outr_ushort(base uint16, _ []uint16) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_outr_ushort, _swig_p) + return +} + +func Outr_ushort(arg1 uint16, arg2 []uint16) { + _swig_wrap_outr_ushort(arg1, arg2) +} + +var _wrap_outr_ulong unsafe.Pointer + +func _swig_wrap_outr_ulong(base uint64, _ []uint64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_outr_ulong, _swig_p) + return +} + +func Outr_ulong(arg1 uint64, arg2 []uint64) { + _swig_wrap_outr_ulong(arg1, arg2) +} + +var _wrap_outr_uchar unsafe.Pointer + +func _swig_wrap_outr_uchar(base byte, _ []byte) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_outr_uchar, _swig_p) + return +} + +func Outr_uchar(arg1 byte, arg2 []byte) { + _swig_wrap_outr_uchar(arg1, arg2) +} + +var _wrap_outr_schar unsafe.Pointer + +func _swig_wrap_outr_schar(base int8, _ []int8) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_outr_schar, _swig_p) + return +} + +func Outr_schar(arg1 int8, arg2 []int8) { + _swig_wrap_outr_schar(arg1, arg2) +} + +var _wrap_outr_float unsafe.Pointer + +func _swig_wrap_outr_float(base float32, _ []float32) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_outr_float, _swig_p) + return +} + +func Outr_float(arg1 float32, arg2 []float32) { + _swig_wrap_outr_float(arg1, arg2) +} + +var _wrap_outr_double unsafe.Pointer + +func _swig_wrap_outr_double(base float64, _ []float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_outr_double, _swig_p) + return +} + +func Outr_double(arg1 float64, arg2 []float64) { + _swig_wrap_outr_double(arg1, arg2) +} + +var _wrap_outr_longlong unsafe.Pointer + +func _swig_wrap_outr_longlong(base int64, _ []int64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_outr_longlong, _swig_p) + return +} + +func Outr_longlong(arg1 int64, arg2 []int64) { + _swig_wrap_outr_longlong(arg1, arg2) +} + +var _wrap_outr_ulonglong unsafe.Pointer + +func _swig_wrap_outr_ulonglong(base uint64, _ []uint64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_outr_ulonglong, _swig_p) + return +} + +func Outr_ulonglong(arg1 uint64, arg2 []uint64) { + _swig_wrap_outr_ulonglong(arg1, arg2) +} + +var _wrap_inout_bool unsafe.Pointer + +func _swig_wrap_inout_bool(base []bool) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_inout_bool, _swig_p) + return +} + +func Inout_bool(arg1 []bool) { + _swig_wrap_inout_bool(arg1) +} + +var _wrap_inout_int unsafe.Pointer + +func _swig_wrap_inout_int(base []int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_inout_int, _swig_p) + return +} + +func Inout_int(arg1 []int) { + _swig_wrap_inout_int(arg1) +} + +var _wrap_inout_short unsafe.Pointer + +func _swig_wrap_inout_short(base []int16) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_inout_short, _swig_p) + return +} + +func Inout_short(arg1 []int16) { + _swig_wrap_inout_short(arg1) +} + +var _wrap_inout_long unsafe.Pointer + +func _swig_wrap_inout_long(base []int64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_inout_long, _swig_p) + return +} + +func Inout_long(arg1 []int64) { + _swig_wrap_inout_long(arg1) +} + +var _wrap_inout_uint unsafe.Pointer + +func _swig_wrap_inout_uint(base []uint) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_inout_uint, _swig_p) + return +} + +func Inout_uint(arg1 []uint) { + _swig_wrap_inout_uint(arg1) +} + +var _wrap_inout_ushort unsafe.Pointer + +func _swig_wrap_inout_ushort(base []uint16) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_inout_ushort, _swig_p) + return +} + +func Inout_ushort(arg1 []uint16) { + _swig_wrap_inout_ushort(arg1) +} + +var _wrap_inout_ulong unsafe.Pointer + +func _swig_wrap_inout_ulong(base []uint64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_inout_ulong, _swig_p) + return +} + +func Inout_ulong(arg1 []uint64) { + _swig_wrap_inout_ulong(arg1) +} + +var _wrap_inout_uchar unsafe.Pointer + +func _swig_wrap_inout_uchar(base []byte) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_inout_uchar, _swig_p) + return +} + +func Inout_uchar(arg1 []byte) { + _swig_wrap_inout_uchar(arg1) +} + +var _wrap_inout_schar unsafe.Pointer + +func _swig_wrap_inout_schar(base []int8) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_inout_schar, _swig_p) + return +} + +func Inout_schar(arg1 []int8) { + _swig_wrap_inout_schar(arg1) +} + +var _wrap_inout_float unsafe.Pointer + +func _swig_wrap_inout_float(base []float32) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_inout_float, _swig_p) + return +} + +func Inout_float(arg1 []float32) { + _swig_wrap_inout_float(arg1) +} + +var _wrap_inout_double unsafe.Pointer + +func _swig_wrap_inout_double(base []float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_inout_double, _swig_p) + return +} + +func Inout_double(arg1 []float64) { + _swig_wrap_inout_double(arg1) +} + +var _wrap_inout_longlong unsafe.Pointer + +func _swig_wrap_inout_longlong(base []int64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_inout_longlong, _swig_p) + return +} + +func Inout_longlong(arg1 []int64) { + _swig_wrap_inout_longlong(arg1) +} + +var _wrap_inout_ulonglong unsafe.Pointer + +func _swig_wrap_inout_ulonglong(base []uint64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_inout_ulonglong, _swig_p) + return +} + +func Inout_ulonglong(arg1 []uint64) { + _swig_wrap_inout_ulonglong(arg1) +} + +var _wrap_inoutr_bool unsafe.Pointer + +func _swig_wrap_inoutr_bool(base []bool) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_inoutr_bool, _swig_p) + return +} + +func Inoutr_bool(arg1 []bool) { + _swig_wrap_inoutr_bool(arg1) +} + +var _wrap_inoutr_int unsafe.Pointer + +func _swig_wrap_inoutr_int(base []int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_inoutr_int, _swig_p) + return +} + +func Inoutr_int(arg1 []int) { + _swig_wrap_inoutr_int(arg1) +} + +var _wrap_inoutr_short unsafe.Pointer + +func _swig_wrap_inoutr_short(base []int16) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_inoutr_short, _swig_p) + return +} + +func Inoutr_short(arg1 []int16) { + _swig_wrap_inoutr_short(arg1) +} + +var _wrap_inoutr_long unsafe.Pointer + +func _swig_wrap_inoutr_long(base []int64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_inoutr_long, _swig_p) + return +} + +func Inoutr_long(arg1 []int64) { + _swig_wrap_inoutr_long(arg1) +} + +var _wrap_inoutr_uint unsafe.Pointer + +func _swig_wrap_inoutr_uint(base []uint) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_inoutr_uint, _swig_p) + return +} + +func Inoutr_uint(arg1 []uint) { + _swig_wrap_inoutr_uint(arg1) +} + +var _wrap_inoutr_ushort unsafe.Pointer + +func _swig_wrap_inoutr_ushort(base []uint16) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_inoutr_ushort, _swig_p) + return +} + +func Inoutr_ushort(arg1 []uint16) { + _swig_wrap_inoutr_ushort(arg1) +} + +var _wrap_inoutr_ulong unsafe.Pointer + +func _swig_wrap_inoutr_ulong(base []uint64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_inoutr_ulong, _swig_p) + return +} + +func Inoutr_ulong(arg1 []uint64) { + _swig_wrap_inoutr_ulong(arg1) +} + +var _wrap_inoutr_uchar unsafe.Pointer + +func _swig_wrap_inoutr_uchar(base []byte) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_inoutr_uchar, _swig_p) + return +} + +func Inoutr_uchar(arg1 []byte) { + _swig_wrap_inoutr_uchar(arg1) +} + +var _wrap_inoutr_schar unsafe.Pointer + +func _swig_wrap_inoutr_schar(base []int8) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_inoutr_schar, _swig_p) + return +} + +func Inoutr_schar(arg1 []int8) { + _swig_wrap_inoutr_schar(arg1) +} + +var _wrap_inoutr_float unsafe.Pointer + +func _swig_wrap_inoutr_float(base []float32) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_inoutr_float, _swig_p) + return +} + +func Inoutr_float(arg1 []float32) { + _swig_wrap_inoutr_float(arg1) +} + +var _wrap_inoutr_double unsafe.Pointer + +func _swig_wrap_inoutr_double(base []float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_inoutr_double, _swig_p) + return +} + +func Inoutr_double(arg1 []float64) { + _swig_wrap_inoutr_double(arg1) +} + +var _wrap_inoutr_longlong unsafe.Pointer + +func _swig_wrap_inoutr_longlong(base []int64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_inoutr_longlong, _swig_p) + return +} + +func Inoutr_longlong(arg1 []int64) { + _swig_wrap_inoutr_longlong(arg1) +} + +var _wrap_inoutr_ulonglong unsafe.Pointer + +func _swig_wrap_inoutr_ulonglong(base []uint64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_inoutr_ulonglong, _swig_p) + return +} + +func Inoutr_ulonglong(arg1 []uint64) { + _swig_wrap_inoutr_ulonglong(arg1) +} + +var _wrap_inoutr_int2 unsafe.Pointer + +func _swig_wrap_inoutr_int2(base []int, _ []int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_inoutr_int2, _swig_p) + return +} + +func Inoutr_int2(arg1 []int, arg2 []int) { + _swig_wrap_inoutr_int2(arg1, arg2) +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/li_typemaps_apply.go b/Examples/test-suite/go/li_typemaps_apply.go new file mode 100644 index 000000000..b9b4d0694 --- /dev/null +++ b/Examples/test-suite/go/li_typemaps_apply.go @@ -0,0 +1,575 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../li_typemaps_apply.i + +package li_typemaps_apply + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +var _wrap_input_ptr_bool unsafe.Pointer + +func Input_ptr_bool(arg1 bool) (_swig_ret bool) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_input_ptr_bool, _swig_p) + return +} +var _wrap_input_ref_bool unsafe.Pointer + +func Input_ref_bool(arg1 bool) (_swig_ret bool) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_input_ref_bool, _swig_p) + return +} +var _wrap_output_ptr_bool unsafe.Pointer + +func Output_ptr_bool(arg1 bool, arg2 []bool) (_swig_ret []bool) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_output_ptr_bool, _swig_p) + return +} +var _wrap_output_ref_bool unsafe.Pointer + +func Output_ref_bool(arg1 bool, arg2 []bool) (_swig_ret []bool) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_output_ref_bool, _swig_p) + return +} +var _wrap_inout_ptr_bool unsafe.Pointer + +func Inout_ptr_bool(arg1 []bool) (_swig_ret []bool) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_inout_ptr_bool, _swig_p) + return +} +var _wrap_inout_ref_bool unsafe.Pointer + +func Inout_ref_bool(arg1 []bool) (_swig_ret []bool) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_inout_ref_bool, _swig_p) + return +} +var _wrap_input_ptr_int unsafe.Pointer + +func Input_ptr_int(arg1 int) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_input_ptr_int, _swig_p) + return +} +var _wrap_input_ref_int unsafe.Pointer + +func Input_ref_int(arg1 int) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_input_ref_int, _swig_p) + return +} +var _wrap_output_ptr_int unsafe.Pointer + +func Output_ptr_int(arg1 int, arg2 []int) (_swig_ret []int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_output_ptr_int, _swig_p) + return +} +var _wrap_output_ref_int unsafe.Pointer + +func Output_ref_int(arg1 int, arg2 []int) (_swig_ret []int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_output_ref_int, _swig_p) + return +} +var _wrap_inout_ptr_int unsafe.Pointer + +func Inout_ptr_int(arg1 []int) (_swig_ret []int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_inout_ptr_int, _swig_p) + return +} +var _wrap_inout_ref_int unsafe.Pointer + +func Inout_ref_int(arg1 []int) (_swig_ret []int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_inout_ref_int, _swig_p) + return +} +var _wrap_input_ptr_short unsafe.Pointer + +func Input_ptr_short(arg1 int16) (_swig_ret int16) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_input_ptr_short, _swig_p) + return +} +var _wrap_input_ref_short unsafe.Pointer + +func Input_ref_short(arg1 int16) (_swig_ret int16) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_input_ref_short, _swig_p) + return +} +var _wrap_output_ptr_short unsafe.Pointer + +func Output_ptr_short(arg1 int16, arg2 []int16) (_swig_ret []int16) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_output_ptr_short, _swig_p) + return +} +var _wrap_output_ref_short unsafe.Pointer + +func Output_ref_short(arg1 int16, arg2 []int16) (_swig_ret []int16) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_output_ref_short, _swig_p) + return +} +var _wrap_inout_ptr_short unsafe.Pointer + +func Inout_ptr_short(arg1 []int16) (_swig_ret []int16) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_inout_ptr_short, _swig_p) + return +} +var _wrap_inout_ref_short unsafe.Pointer + +func Inout_ref_short(arg1 []int16) (_swig_ret []int16) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_inout_ref_short, _swig_p) + return +} +var _wrap_input_ptr_long unsafe.Pointer + +func Input_ptr_long(arg1 int64) (_swig_ret int64) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_input_ptr_long, _swig_p) + return +} +var _wrap_input_ref_long unsafe.Pointer + +func Input_ref_long(arg1 int64) (_swig_ret int64) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_input_ref_long, _swig_p) + return +} +var _wrap_output_ptr_long unsafe.Pointer + +func Output_ptr_long(arg1 int64, arg2 []int64) (_swig_ret []int64) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_output_ptr_long, _swig_p) + return +} +var _wrap_output_ref_long unsafe.Pointer + +func Output_ref_long(arg1 int64, arg2 []int64) (_swig_ret []int64) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_output_ref_long, _swig_p) + return +} +var _wrap_inout_ptr_long unsafe.Pointer + +func Inout_ptr_long(arg1 []int64) (_swig_ret []int64) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_inout_ptr_long, _swig_p) + return +} +var _wrap_inout_ref_long unsafe.Pointer + +func Inout_ref_long(arg1 []int64) (_swig_ret []int64) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_inout_ref_long, _swig_p) + return +} +var _wrap_input_ptr_uint unsafe.Pointer + +func Input_ptr_uint(arg1 uint) (_swig_ret uint) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_input_ptr_uint, _swig_p) + return +} +var _wrap_input_ref_uint unsafe.Pointer + +func Input_ref_uint(arg1 uint) (_swig_ret uint) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_input_ref_uint, _swig_p) + return +} +var _wrap_output_ptr_uint unsafe.Pointer + +func Output_ptr_uint(arg1 uint, arg2 []uint) (_swig_ret []uint) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_output_ptr_uint, _swig_p) + return +} +var _wrap_output_ref_uint unsafe.Pointer + +func Output_ref_uint(arg1 uint, arg2 []uint) (_swig_ret []uint) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_output_ref_uint, _swig_p) + return +} +var _wrap_inout_ptr_uint unsafe.Pointer + +func Inout_ptr_uint(arg1 []uint) (_swig_ret []uint) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_inout_ptr_uint, _swig_p) + return +} +var _wrap_inout_ref_uint unsafe.Pointer + +func Inout_ref_uint(arg1 []uint) (_swig_ret []uint) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_inout_ref_uint, _swig_p) + return +} +var _wrap_input_ptr_ushort unsafe.Pointer + +func Input_ptr_ushort(arg1 uint16) (_swig_ret uint16) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_input_ptr_ushort, _swig_p) + return +} +var _wrap_input_ref_ushort unsafe.Pointer + +func Input_ref_ushort(arg1 uint16) (_swig_ret uint16) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_input_ref_ushort, _swig_p) + return +} +var _wrap_output_ptr_ushort unsafe.Pointer + +func Output_ptr_ushort(arg1 uint16, arg2 []uint16) (_swig_ret []uint16) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_output_ptr_ushort, _swig_p) + return +} +var _wrap_output_ref_ushort unsafe.Pointer + +func Output_ref_ushort(arg1 uint16, arg2 []uint16) (_swig_ret []uint16) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_output_ref_ushort, _swig_p) + return +} +var _wrap_inout_ptr_ushort unsafe.Pointer + +func Inout_ptr_ushort(arg1 []uint16) (_swig_ret []uint16) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_inout_ptr_ushort, _swig_p) + return +} +var _wrap_inout_ref_ushort unsafe.Pointer + +func Inout_ref_ushort(arg1 []uint16) (_swig_ret []uint16) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_inout_ref_ushort, _swig_p) + return +} +var _wrap_input_ptr_ulong unsafe.Pointer + +func Input_ptr_ulong(arg1 uint64) (_swig_ret uint64) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_input_ptr_ulong, _swig_p) + return +} +var _wrap_input_ref_ulong unsafe.Pointer + +func Input_ref_ulong(arg1 uint64) (_swig_ret uint64) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_input_ref_ulong, _swig_p) + return +} +var _wrap_output_ptr_ulong unsafe.Pointer + +func Output_ptr_ulong(arg1 uint64, arg2 []uint64) (_swig_ret []uint64) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_output_ptr_ulong, _swig_p) + return +} +var _wrap_output_ref_ulong unsafe.Pointer + +func Output_ref_ulong(arg1 uint64, arg2 []uint64) (_swig_ret []uint64) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_output_ref_ulong, _swig_p) + return +} +var _wrap_inout_ptr_ulong unsafe.Pointer + +func Inout_ptr_ulong(arg1 []uint64) (_swig_ret []uint64) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_inout_ptr_ulong, _swig_p) + return +} +var _wrap_inout_ref_ulong unsafe.Pointer + +func Inout_ref_ulong(arg1 []uint64) (_swig_ret []uint64) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_inout_ref_ulong, _swig_p) + return +} +var _wrap_input_ptr_uchar unsafe.Pointer + +func Input_ptr_uchar(arg1 byte) (_swig_ret byte) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_input_ptr_uchar, _swig_p) + return +} +var _wrap_input_ref_uchar unsafe.Pointer + +func Input_ref_uchar(arg1 byte) (_swig_ret byte) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_input_ref_uchar, _swig_p) + return +} +var _wrap_output_ptr_uchar unsafe.Pointer + +func Output_ptr_uchar(arg1 byte, arg2 []byte) (_swig_ret []byte) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_output_ptr_uchar, _swig_p) + return +} +var _wrap_output_ref_uchar unsafe.Pointer + +func Output_ref_uchar(arg1 byte, arg2 []byte) (_swig_ret []byte) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_output_ref_uchar, _swig_p) + return +} +var _wrap_inout_ptr_uchar unsafe.Pointer + +func Inout_ptr_uchar(arg1 []byte) (_swig_ret []byte) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_inout_ptr_uchar, _swig_p) + return +} +var _wrap_inout_ref_uchar unsafe.Pointer + +func Inout_ref_uchar(arg1 []byte) (_swig_ret []byte) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_inout_ref_uchar, _swig_p) + return +} +var _wrap_input_ptr_schar unsafe.Pointer + +func Input_ptr_schar(arg1 int8) (_swig_ret int8) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_input_ptr_schar, _swig_p) + return +} +var _wrap_input_ref_schar unsafe.Pointer + +func Input_ref_schar(arg1 int8) (_swig_ret int8) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_input_ref_schar, _swig_p) + return +} +var _wrap_output_ptr_schar unsafe.Pointer + +func Output_ptr_schar(arg1 int8, arg2 []int8) (_swig_ret []int8) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_output_ptr_schar, _swig_p) + return +} +var _wrap_output_ref_schar unsafe.Pointer + +func Output_ref_schar(arg1 int8, arg2 []int8) (_swig_ret []int8) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_output_ref_schar, _swig_p) + return +} +var _wrap_inout_ptr_schar unsafe.Pointer + +func Inout_ptr_schar(arg1 []int8) (_swig_ret []int8) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_inout_ptr_schar, _swig_p) + return +} +var _wrap_inout_ref_schar unsafe.Pointer + +func Inout_ref_schar(arg1 []int8) (_swig_ret []int8) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_inout_ref_schar, _swig_p) + return +} +var _wrap_input_ptr_float unsafe.Pointer + +func Input_ptr_float(arg1 float32) (_swig_ret float32) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_input_ptr_float, _swig_p) + return +} +var _wrap_input_ref_float unsafe.Pointer + +func Input_ref_float(arg1 float32) (_swig_ret float32) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_input_ref_float, _swig_p) + return +} +var _wrap_output_ptr_float unsafe.Pointer + +func Output_ptr_float(arg1 float32, arg2 []float32) (_swig_ret []float32) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_output_ptr_float, _swig_p) + return +} +var _wrap_output_ref_float unsafe.Pointer + +func Output_ref_float(arg1 float32, arg2 []float32) (_swig_ret []float32) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_output_ref_float, _swig_p) + return +} +var _wrap_inout_ptr_float unsafe.Pointer + +func Inout_ptr_float(arg1 []float32) (_swig_ret []float32) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_inout_ptr_float, _swig_p) + return +} +var _wrap_inout_ref_float unsafe.Pointer + +func Inout_ref_float(arg1 []float32) (_swig_ret []float32) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_inout_ref_float, _swig_p) + return +} +var _wrap_input_ptr_double unsafe.Pointer + +func Input_ptr_double(arg1 float64) (_swig_ret float64) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_input_ptr_double, _swig_p) + return +} +var _wrap_input_ref_double unsafe.Pointer + +func Input_ref_double(arg1 float64) (_swig_ret float64) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_input_ref_double, _swig_p) + return +} +var _wrap_output_ptr_double unsafe.Pointer + +func Output_ptr_double(arg1 float64, arg2 []float64) (_swig_ret []float64) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_output_ptr_double, _swig_p) + return +} +var _wrap_output_ref_double unsafe.Pointer + +func Output_ref_double(arg1 float64, arg2 []float64) (_swig_ret []float64) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_output_ref_double, _swig_p) + return +} +var _wrap_inout_ptr_double unsafe.Pointer + +func Inout_ptr_double(arg1 []float64) (_swig_ret []float64) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_inout_ptr_double, _swig_p) + return +} +var _wrap_inout_ref_double unsafe.Pointer + +func Inout_ref_double(arg1 []float64) (_swig_ret []float64) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_inout_ref_double, _swig_p) + return +} +var _wrap_input_ptr_longlong unsafe.Pointer + +func Input_ptr_longlong(arg1 int64) (_swig_ret int64) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_input_ptr_longlong, _swig_p) + return +} +var _wrap_input_ref_longlong unsafe.Pointer + +func Input_ref_longlong(arg1 int64) (_swig_ret int64) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_input_ref_longlong, _swig_p) + return +} +var _wrap_output_ptr_longlong unsafe.Pointer + +func Output_ptr_longlong(arg1 int64, arg2 []int64) (_swig_ret []int64) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_output_ptr_longlong, _swig_p) + return +} +var _wrap_output_ref_longlong unsafe.Pointer + +func Output_ref_longlong(arg1 int64, arg2 []int64) (_swig_ret []int64) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_output_ref_longlong, _swig_p) + return +} +var _wrap_inout_ptr_longlong unsafe.Pointer + +func Inout_ptr_longlong(arg1 []int64) (_swig_ret []int64) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_inout_ptr_longlong, _swig_p) + return +} +var _wrap_inout_ref_longlong unsafe.Pointer + +func Inout_ref_longlong(arg1 []int64) (_swig_ret []int64) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_inout_ref_longlong, _swig_p) + return +} +var _wrap_input_ptr_ulonglong unsafe.Pointer + +func Input_ptr_ulonglong(arg1 uint64) (_swig_ret uint64) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_input_ptr_ulonglong, _swig_p) + return +} +var _wrap_input_ref_ulonglong unsafe.Pointer + +func Input_ref_ulonglong(arg1 uint64) (_swig_ret uint64) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_input_ref_ulonglong, _swig_p) + return +} +var _wrap_output_ptr_ulonglong unsafe.Pointer + +func Output_ptr_ulonglong(arg1 uint64, arg2 []uint64) (_swig_ret []uint64) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_output_ptr_ulonglong, _swig_p) + return +} +var _wrap_output_ref_ulonglong unsafe.Pointer + +func Output_ref_ulonglong(arg1 uint64, arg2 []uint64) (_swig_ret []uint64) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_output_ref_ulonglong, _swig_p) + return +} +var _wrap_inout_ptr_ulonglong unsafe.Pointer + +func Inout_ptr_ulonglong(arg1 []uint64) (_swig_ret []uint64) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_inout_ptr_ulonglong, _swig_p) + return +} +var _wrap_inout_ref_ulonglong unsafe.Pointer + +func Inout_ref_ulonglong(arg1 []uint64) (_swig_ret []uint64) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_inout_ref_ulonglong, _swig_p) + return +} + diff --git a/Examples/test-suite/go/li_windows.go b/Examples/test-suite/go/li_windows.go new file mode 100644 index 000000000..c8e035584 --- /dev/null +++ b/Examples/test-suite/go/li_windows.go @@ -0,0 +1,624 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../li_windows.i + +package li_windows + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +var _wrap_int8_val unsafe.Pointer + +func Int8_val(arg1 int8) (_swig_ret int8) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_int8_val, _swig_p) + return +} +var _wrap_int16_val unsafe.Pointer + +func Int16_val(arg1 int16) (_swig_ret int16) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_int16_val, _swig_p) + return +} +var _wrap_int32_val unsafe.Pointer + +func Int32_val(arg1 int) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_int32_val, _swig_p) + return +} +var _wrap_int64_val unsafe.Pointer + +func Int64_val(arg1 int64) (_swig_ret int64) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_int64_val, _swig_p) + return +} +var _wrap_uint8_val unsafe.Pointer + +func Uint8_val(arg1 byte) (_swig_ret byte) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_uint8_val, _swig_p) + return +} +var _wrap_uint16_val unsafe.Pointer + +func Uint16_val(arg1 uint16) (_swig_ret uint16) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_uint16_val, _swig_p) + return +} +var _wrap_uint32_val unsafe.Pointer + +func Uint32_val(arg1 uint) (_swig_ret uint) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_uint32_val, _swig_p) + return +} +var _wrap_uint64_val unsafe.Pointer + +func Uint64_val(arg1 uint64) (_swig_ret uint64) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_uint64_val, _swig_p) + return +} +var _wrap_int8_ref unsafe.Pointer + +func Int8_ref(arg1 int8) (_swig_ret int8) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_int8_ref, _swig_p) + return +} +var _wrap_int16_ref unsafe.Pointer + +func Int16_ref(arg1 int16) (_swig_ret int16) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_int16_ref, _swig_p) + return +} +var _wrap_int32_ref unsafe.Pointer + +func Int32_ref(arg1 int) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_int32_ref, _swig_p) + return +} +var _wrap_int64_ref unsafe.Pointer + +func Int64_ref(arg1 int64) (_swig_ret int64) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_int64_ref, _swig_p) + return +} +var _wrap_uint8_ref unsafe.Pointer + +func Uint8_ref(arg1 byte) (_swig_ret byte) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_uint8_ref, _swig_p) + return +} +var _wrap_uint16_ref unsafe.Pointer + +func Uint16_ref(arg1 uint16) (_swig_ret uint16) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_uint16_ref, _swig_p) + return +} +var _wrap_uint32_ref unsafe.Pointer + +func Uint32_ref(arg1 uint) (_swig_ret uint) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_uint32_ref, _swig_p) + return +} +var _wrap_uint64_ref unsafe.Pointer + +func Uint64_ref(arg1 uint64) (_swig_ret uint64) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_uint64_ref, _swig_p) + return +} +var _wrap_int8_global_set unsafe.Pointer + +func _swig_wrap_int8_global_set(base int8) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_int8_global_set, _swig_p) + return +} + +func SetInt8_global(arg1 int8) { + _swig_wrap_int8_global_set(arg1) +} + +var _wrap_int8_global_get unsafe.Pointer + +func GetInt8_global() (_swig_ret int8) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_int8_global_get, _swig_p) + return +} +var _wrap_int16_global_set unsafe.Pointer + +func _swig_wrap_int16_global_set(base int16) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_int16_global_set, _swig_p) + return +} + +func SetInt16_global(arg1 int16) { + _swig_wrap_int16_global_set(arg1) +} + +var _wrap_int16_global_get unsafe.Pointer + +func GetInt16_global() (_swig_ret int16) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_int16_global_get, _swig_p) + return +} +var _wrap_int32_global_set unsafe.Pointer + +func _swig_wrap_int32_global_set(base int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_int32_global_set, _swig_p) + return +} + +func SetInt32_global(arg1 int) { + _swig_wrap_int32_global_set(arg1) +} + +var _wrap_int32_global_get unsafe.Pointer + +func GetInt32_global() (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_int32_global_get, _swig_p) + return +} +var _wrap_int64_global_set unsafe.Pointer + +func _swig_wrap_int64_global_set(base int64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_int64_global_set, _swig_p) + return +} + +func SetInt64_global(arg1 int64) { + _swig_wrap_int64_global_set(arg1) +} + +var _wrap_int64_global_get unsafe.Pointer + +func GetInt64_global() (_swig_ret int64) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_int64_global_get, _swig_p) + return +} +var _wrap_uint8_global_set unsafe.Pointer + +func _swig_wrap_uint8_global_set(base byte) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_uint8_global_set, _swig_p) + return +} + +func SetUint8_global(arg1 byte) { + _swig_wrap_uint8_global_set(arg1) +} + +var _wrap_uint8_global_get unsafe.Pointer + +func GetUint8_global() (_swig_ret byte) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_uint8_global_get, _swig_p) + return +} +var _wrap_uint16_global_set unsafe.Pointer + +func _swig_wrap_uint16_global_set(base uint16) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_uint16_global_set, _swig_p) + return +} + +func SetUint16_global(arg1 uint16) { + _swig_wrap_uint16_global_set(arg1) +} + +var _wrap_uint16_global_get unsafe.Pointer + +func GetUint16_global() (_swig_ret uint16) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_uint16_global_get, _swig_p) + return +} +var _wrap_uint32_global_set unsafe.Pointer + +func _swig_wrap_uint32_global_set(base uint) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_uint32_global_set, _swig_p) + return +} + +func SetUint32_global(arg1 uint) { + _swig_wrap_uint32_global_set(arg1) +} + +var _wrap_uint32_global_get unsafe.Pointer + +func GetUint32_global() (_swig_ret uint) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_uint32_global_get, _swig_p) + return +} +var _wrap_uint64_global_set unsafe.Pointer + +func _swig_wrap_uint64_global_set(base uint64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_uint64_global_set, _swig_p) + return +} + +func SetUint64_global(arg1 uint64) { + _swig_wrap_uint64_global_set(arg1) +} + +var _wrap_uint64_global_get unsafe.Pointer + +func GetUint64_global() (_swig_ret uint64) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_uint64_global_get, _swig_p) + return +} +type SwigcptrWindowsInts uintptr + +func (p SwigcptrWindowsInts) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrWindowsInts) SwigIsWindowsInts() { +} + +var _wrap_WindowsInts_int8_member_set unsafe.Pointer + +func _swig_wrap_WindowsInts_int8_member_set(base SwigcptrWindowsInts, _ int8) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_WindowsInts_int8_member_set, _swig_p) + return +} + +func (arg1 SwigcptrWindowsInts) SetInt8_member(arg2 int8) { + _swig_wrap_WindowsInts_int8_member_set(arg1, arg2) +} + +var _wrap_WindowsInts_int8_member_get unsafe.Pointer + +func _swig_wrap_WindowsInts_int8_member_get(base SwigcptrWindowsInts) (_ int8) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_WindowsInts_int8_member_get, _swig_p) + return +} + +func (arg1 SwigcptrWindowsInts) GetInt8_member() (_swig_ret int8) { + return _swig_wrap_WindowsInts_int8_member_get(arg1) +} + +var _wrap_WindowsInts_int16_member_set unsafe.Pointer + +func _swig_wrap_WindowsInts_int16_member_set(base SwigcptrWindowsInts, _ int16) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_WindowsInts_int16_member_set, _swig_p) + return +} + +func (arg1 SwigcptrWindowsInts) SetInt16_member(arg2 int16) { + _swig_wrap_WindowsInts_int16_member_set(arg1, arg2) +} + +var _wrap_WindowsInts_int16_member_get unsafe.Pointer + +func _swig_wrap_WindowsInts_int16_member_get(base SwigcptrWindowsInts) (_ int16) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_WindowsInts_int16_member_get, _swig_p) + return +} + +func (arg1 SwigcptrWindowsInts) GetInt16_member() (_swig_ret int16) { + return _swig_wrap_WindowsInts_int16_member_get(arg1) +} + +var _wrap_WindowsInts_int32_member_set unsafe.Pointer + +func _swig_wrap_WindowsInts_int32_member_set(base SwigcptrWindowsInts, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_WindowsInts_int32_member_set, _swig_p) + return +} + +func (arg1 SwigcptrWindowsInts) SetInt32_member(arg2 int) { + _swig_wrap_WindowsInts_int32_member_set(arg1, arg2) +} + +var _wrap_WindowsInts_int32_member_get unsafe.Pointer + +func _swig_wrap_WindowsInts_int32_member_get(base SwigcptrWindowsInts) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_WindowsInts_int32_member_get, _swig_p) + return +} + +func (arg1 SwigcptrWindowsInts) GetInt32_member() (_swig_ret int) { + return _swig_wrap_WindowsInts_int32_member_get(arg1) +} + +var _wrap_WindowsInts_int64_member_set unsafe.Pointer + +func _swig_wrap_WindowsInts_int64_member_set(base SwigcptrWindowsInts, _ int64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_WindowsInts_int64_member_set, _swig_p) + return +} + +func (arg1 SwigcptrWindowsInts) SetInt64_member(arg2 int64) { + _swig_wrap_WindowsInts_int64_member_set(arg1, arg2) +} + +var _wrap_WindowsInts_int64_member_get unsafe.Pointer + +func _swig_wrap_WindowsInts_int64_member_get(base SwigcptrWindowsInts) (_ int64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_WindowsInts_int64_member_get, _swig_p) + return +} + +func (arg1 SwigcptrWindowsInts) GetInt64_member() (_swig_ret int64) { + return _swig_wrap_WindowsInts_int64_member_get(arg1) +} + +var _wrap_WindowsInts_uint8_member_set unsafe.Pointer + +func _swig_wrap_WindowsInts_uint8_member_set(base SwigcptrWindowsInts, _ byte) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_WindowsInts_uint8_member_set, _swig_p) + return +} + +func (arg1 SwigcptrWindowsInts) SetUint8_member(arg2 byte) { + _swig_wrap_WindowsInts_uint8_member_set(arg1, arg2) +} + +var _wrap_WindowsInts_uint8_member_get unsafe.Pointer + +func _swig_wrap_WindowsInts_uint8_member_get(base SwigcptrWindowsInts) (_ byte) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_WindowsInts_uint8_member_get, _swig_p) + return +} + +func (arg1 SwigcptrWindowsInts) GetUint8_member() (_swig_ret byte) { + return _swig_wrap_WindowsInts_uint8_member_get(arg1) +} + +var _wrap_WindowsInts_uint16_member_set unsafe.Pointer + +func _swig_wrap_WindowsInts_uint16_member_set(base SwigcptrWindowsInts, _ uint16) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_WindowsInts_uint16_member_set, _swig_p) + return +} + +func (arg1 SwigcptrWindowsInts) SetUint16_member(arg2 uint16) { + _swig_wrap_WindowsInts_uint16_member_set(arg1, arg2) +} + +var _wrap_WindowsInts_uint16_member_get unsafe.Pointer + +func _swig_wrap_WindowsInts_uint16_member_get(base SwigcptrWindowsInts) (_ uint16) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_WindowsInts_uint16_member_get, _swig_p) + return +} + +func (arg1 SwigcptrWindowsInts) GetUint16_member() (_swig_ret uint16) { + return _swig_wrap_WindowsInts_uint16_member_get(arg1) +} + +var _wrap_WindowsInts_uint32_member_set unsafe.Pointer + +func _swig_wrap_WindowsInts_uint32_member_set(base SwigcptrWindowsInts, _ uint) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_WindowsInts_uint32_member_set, _swig_p) + return +} + +func (arg1 SwigcptrWindowsInts) SetUint32_member(arg2 uint) { + _swig_wrap_WindowsInts_uint32_member_set(arg1, arg2) +} + +var _wrap_WindowsInts_uint32_member_get unsafe.Pointer + +func _swig_wrap_WindowsInts_uint32_member_get(base SwigcptrWindowsInts) (_ uint) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_WindowsInts_uint32_member_get, _swig_p) + return +} + +func (arg1 SwigcptrWindowsInts) GetUint32_member() (_swig_ret uint) { + return _swig_wrap_WindowsInts_uint32_member_get(arg1) +} + +var _wrap_WindowsInts_uint64_member_set unsafe.Pointer + +func _swig_wrap_WindowsInts_uint64_member_set(base SwigcptrWindowsInts, _ uint64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_WindowsInts_uint64_member_set, _swig_p) + return +} + +func (arg1 SwigcptrWindowsInts) SetUint64_member(arg2 uint64) { + _swig_wrap_WindowsInts_uint64_member_set(arg1, arg2) +} + +var _wrap_WindowsInts_uint64_member_get unsafe.Pointer + +func _swig_wrap_WindowsInts_uint64_member_get(base SwigcptrWindowsInts) (_ uint64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_WindowsInts_uint64_member_get, _swig_p) + return +} + +func (arg1 SwigcptrWindowsInts) GetUint64_member() (_swig_ret uint64) { + return _swig_wrap_WindowsInts_uint64_member_get(arg1) +} + +var _wrap_new_WindowsInts unsafe.Pointer + +func _swig_wrap_new_WindowsInts() (base SwigcptrWindowsInts) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_WindowsInts, _swig_p) + return +} + +func NewWindowsInts() (_swig_ret WindowsInts) { + return _swig_wrap_new_WindowsInts() +} + +var _wrap_delete_WindowsInts unsafe.Pointer + +func _swig_wrap_delete_WindowsInts(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_WindowsInts, _swig_p) + return +} + +func DeleteWindowsInts(arg1 WindowsInts) { + _swig_wrap_delete_WindowsInts(arg1.Swigcptr()) +} + +type WindowsInts interface { + Swigcptr() uintptr + SwigIsWindowsInts() + SetInt8_member(arg2 int8) + GetInt8_member() (_swig_ret int8) + SetInt16_member(arg2 int16) + GetInt16_member() (_swig_ret int16) + SetInt32_member(arg2 int) + GetInt32_member() (_swig_ret int) + SetInt64_member(arg2 int64) + GetInt64_member() (_swig_ret int64) + SetUint8_member(arg2 byte) + GetUint8_member() (_swig_ret byte) + SetUint16_member(arg2 uint16) + GetUint16_member() (_swig_ret uint16) + SetUint32_member(arg2 uint) + GetUint32_member() (_swig_ret uint) + SetUint64_member(arg2 uint64) + GetUint64_member() (_swig_ret uint64) +} + +var _wrap_int8_td unsafe.Pointer + +func Int8_td(arg1 int8) (_swig_ret int8) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_int8_td, _swig_p) + return +} +var _wrap_int16_td unsafe.Pointer + +func Int16_td(arg1 int16) (_swig_ret int16) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_int16_td, _swig_p) + return +} +var _wrap_int32_td unsafe.Pointer + +func Int32_td(arg1 int) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_int32_td, _swig_p) + return +} +var _wrap_int64_td unsafe.Pointer + +func Int64_td(arg1 int64) (_swig_ret int64) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_int64_td, _swig_p) + return +} +var _wrap_uint8_td unsafe.Pointer + +func Uint8_td(arg1 int8) (_swig_ret byte) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_uint8_td, _swig_p) + return +} +var _wrap_uint16_td unsafe.Pointer + +func Uint16_td(arg1 int16) (_swig_ret uint16) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_uint16_td, _swig_p) + return +} +var _wrap_uint32_td unsafe.Pointer + +func Uint32_td(arg1 int) (_swig_ret uint) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_uint32_td, _swig_p) + return +} +var _wrap_uint64_td unsafe.Pointer + +func Uint64_td(arg1 int64) (_swig_ret uint64) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_uint64_td, _swig_p) + return +} +var _wrap_declspecstdcall unsafe.Pointer + +func Declspecstdcall(arg1 int) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_declspecstdcall, _swig_p) + return +} +var _wrap_mefod unsafe.Pointer + +func Mefod(arg1 uint) (_swig_ret uint) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_mefod, _swig_p) + return +} +var _wrap_funktion unsafe.Pointer + +func Funktion(arg1 string) (_swig_ret string) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_funktion, _swig_p) + return +} + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/long_long.go b/Examples/test-suite/go/long_long.go new file mode 100644 index 000000000..783876eb2 --- /dev/null +++ b/Examples/test-suite/go/long_long.go @@ -0,0 +1,195 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../long_long.i + +package long_long + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +var _wrap_foo1 unsafe.Pointer + +func _swig_wrap_foo1(base int64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_foo1, _swig_p) + return +} + +func Foo1(arg1 int64) { + _swig_wrap_foo1(arg1) +} + +var _wrap_foo2 unsafe.Pointer + +func _swig_wrap_foo2(base int64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_foo2, _swig_p) + return +} + +func Foo2(arg1 int64) { + _swig_wrap_foo2(arg1) +} + +var _wrap_foo3 unsafe.Pointer + +func _swig_wrap_foo3(base int64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_foo3, _swig_p) + return +} + +func Foo3(arg1 int64) { + _swig_wrap_foo3(arg1) +} + +var _wrap_foo4 unsafe.Pointer + +func _swig_wrap_foo4(base uint64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_foo4, _swig_p) + return +} + +func Foo4(arg1 uint64) { + _swig_wrap_foo4(arg1) +} + +var _wrap_foo5 unsafe.Pointer + +func _swig_wrap_foo5(base int64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_foo5, _swig_p) + return +} + +func Foo5(arg1 int64) { + _swig_wrap_foo5(arg1) +} + +var _wrap_foo6 unsafe.Pointer + +func _swig_wrap_foo6(base uint64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_foo6, _swig_p) + return +} + +func Foo6(arg1 uint64) { + _swig_wrap_foo6(arg1) +} + +var _wrap_bar1 unsafe.Pointer + +func Bar1() (_swig_ret int64) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_bar1, _swig_p) + return +} +var _wrap_bar2 unsafe.Pointer + +func Bar2() (_swig_ret int64) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_bar2, _swig_p) + return +} +var _wrap_bar3 unsafe.Pointer + +func Bar3() (_swig_ret int64) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_bar3, _swig_p) + return +} +var _wrap_bar4 unsafe.Pointer + +func Bar4() (_swig_ret uint64) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_bar4, _swig_p) + return +} +var _wrap_bar5 unsafe.Pointer + +func Bar5() (_swig_ret int64) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_bar5, _swig_p) + return +} +var _wrap_bar6 unsafe.Pointer + +func Bar6() (_swig_ret uint64) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_bar6, _swig_p) + return +} +var _wrap_ll_set unsafe.Pointer + +func _swig_wrap_ll_set(base int64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_ll_set, _swig_p) + return +} + +func SetLl(arg1 int64) { + _swig_wrap_ll_set(arg1) +} + +var _wrap_ll_get unsafe.Pointer + +func GetLl() (_swig_ret int64) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_ll_get, _swig_p) + return +} +var _wrap_ull_set unsafe.Pointer + +func _swig_wrap_ull_set(base uint64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_ull_set, _swig_p) + return +} + +func SetUll(arg1 uint64) { + _swig_wrap_ull_set(arg1) +} + +var _wrap_ull_get unsafe.Pointer + +func GetUll() (_swig_ret uint64) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_ull_get, _swig_p) + return +} +const Lconst1 int64 = 1234567890 +const Lconst2 uint64 = 1234567890 +const Lconst3 int64 = 1234567 +const Lconst4 uint64 = 1234567 +const Lconst5 int64 = 987654321 +const Lconst6 uint64 = 987654321 + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/long_long_apply.go b/Examples/test-suite/go/long_long_apply.go new file mode 100644 index 000000000..cf6432912 --- /dev/null +++ b/Examples/test-suite/go/long_long_apply.go @@ -0,0 +1,241 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../long_long_apply.i + +package long_long_apply + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +var _wrap_value1 unsafe.Pointer + +func Value1(arg1 int64) (_swig_ret int64) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_value1, _swig_p) + return +} +var _wrap_value2 unsafe.Pointer + +func Value2(arg1 uint64) (_swig_ret uint64) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_value2, _swig_p) + return +} +var _wrap_ref1 unsafe.Pointer + +func Ref1(arg1 int64) (_swig_ret int64) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_ref1, _swig_p) + return +} +var _wrap_ref2 unsafe.Pointer + +func Ref2(arg1 uint64) (_swig_ret uint64) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_ref2, _swig_p) + return +} +var _wrap_global1_set unsafe.Pointer + +func _swig_wrap_global1_set(base int64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_global1_set, _swig_p) + return +} + +func SetGlobal1(arg1 int64) { + _swig_wrap_global1_set(arg1) +} + +var _wrap_global1_get unsafe.Pointer + +func GetGlobal1() (_swig_ret int64) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_global1_get, _swig_p) + return +} +var _wrap_global2_set unsafe.Pointer + +func _swig_wrap_global2_set(base uint64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_global2_set, _swig_p) + return +} + +func SetGlobal2(arg1 uint64) { + _swig_wrap_global2_set(arg1) +} + +var _wrap_global2_get unsafe.Pointer + +func GetGlobal2() (_swig_ret uint64) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_global2_get, _swig_p) + return +} +var _wrap_global_ref1_get unsafe.Pointer + +func GetGlobal_ref1() (_swig_ret int64) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_global_ref1_get, _swig_p) + return +} +var _wrap_global_ref2_get unsafe.Pointer + +func GetGlobal_ref2() (_swig_ret uint64) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_global_ref2_get, _swig_p) + return +} +var _wrap_in_longlong unsafe.Pointer + +func In_longlong(arg1 int64) (_swig_ret int64) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_in_longlong, _swig_p) + return +} +var _wrap_in_ulonglong unsafe.Pointer + +func In_ulonglong(arg1 uint64) (_swig_ret uint64) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_in_ulonglong, _swig_p) + return +} +var _wrap_inr_longlong unsafe.Pointer + +func Inr_longlong(arg1 int64) (_swig_ret int64) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_inr_longlong, _swig_p) + return +} +var _wrap_inr_ulonglong unsafe.Pointer + +func Inr_ulonglong(arg1 uint64) (_swig_ret uint64) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_inr_ulonglong, _swig_p) + return +} +var _wrap_out_longlong unsafe.Pointer + +func _swig_wrap_out_longlong(base int64, _ []int64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_out_longlong, _swig_p) + return +} + +func Out_longlong(arg1 int64, arg2 []int64) { + _swig_wrap_out_longlong(arg1, arg2) +} + +var _wrap_out_ulonglong unsafe.Pointer + +func _swig_wrap_out_ulonglong(base uint64, _ []uint64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_out_ulonglong, _swig_p) + return +} + +func Out_ulonglong(arg1 uint64, arg2 []uint64) { + _swig_wrap_out_ulonglong(arg1, arg2) +} + +var _wrap_outr_longlong unsafe.Pointer + +func _swig_wrap_outr_longlong(base int64, _ []int64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_outr_longlong, _swig_p) + return +} + +func Outr_longlong(arg1 int64, arg2 []int64) { + _swig_wrap_outr_longlong(arg1, arg2) +} + +var _wrap_outr_ulonglong unsafe.Pointer + +func _swig_wrap_outr_ulonglong(base uint64, _ []uint64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_outr_ulonglong, _swig_p) + return +} + +func Outr_ulonglong(arg1 uint64, arg2 []uint64) { + _swig_wrap_outr_ulonglong(arg1, arg2) +} + +var _wrap_inout_longlong unsafe.Pointer + +func _swig_wrap_inout_longlong(base []int64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_inout_longlong, _swig_p) + return +} + +func Inout_longlong(arg1 []int64) { + _swig_wrap_inout_longlong(arg1) +} + +var _wrap_inout_ulonglong unsafe.Pointer + +func _swig_wrap_inout_ulonglong(base []uint64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_inout_ulonglong, _swig_p) + return +} + +func Inout_ulonglong(arg1 []uint64) { + _swig_wrap_inout_ulonglong(arg1) +} + +var _wrap_inoutr_longlong unsafe.Pointer + +func _swig_wrap_inoutr_longlong(base []int64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_inoutr_longlong, _swig_p) + return +} + +func Inoutr_longlong(arg1 []int64) { + _swig_wrap_inoutr_longlong(arg1) +} + +var _wrap_inoutr_ulonglong unsafe.Pointer + +func _swig_wrap_inoutr_ulonglong(base []uint64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_inoutr_ulonglong, _swig_p) + return +} + +func Inoutr_ulonglong(arg1 []uint64) { + _swig_wrap_inoutr_ulonglong(arg1) +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/member_funcptr_galore.go b/Examples/test-suite/go/member_funcptr_galore.go new file mode 100644 index 000000000..554b06255 --- /dev/null +++ b/Examples/test-suite/go/member_funcptr_galore.go @@ -0,0 +1,432 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../member_funcptr_galore.i + +package member_funcptr_galore + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrFunktions uintptr + +func (p SwigcptrFunktions) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrFunktions) SwigIsFunktions() { +} + +var _wrap_Funktions_addByValue unsafe.Pointer + +func _swig_wrap_Funktions_addByValue(base SwigcptrFunktions, _ int, _ int) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Funktions_addByValue, _swig_p) + return +} + +func (arg1 SwigcptrFunktions) AddByValue(arg2 int, arg3 int) (_swig_ret int) { + return _swig_wrap_Funktions_addByValue(arg1, arg2, arg3) +} + +var _wrap_Funktions_addByPointer unsafe.Pointer + +func _swig_wrap_Funktions_addByPointer(base SwigcptrFunktions, _ int, _ int) (_ *int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Funktions_addByPointer, _swig_p) + return +} + +func (arg1 SwigcptrFunktions) AddByPointer(arg2 int, arg3 int) (_swig_ret *int) { + return _swig_wrap_Funktions_addByPointer(arg1, arg2, arg3) +} + +var _wrap_Funktions_addByReference unsafe.Pointer + +func _swig_wrap_Funktions_addByReference(base SwigcptrFunktions, _ int, _ int) (_ *int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Funktions_addByReference, _swig_p) + return +} + +func (arg1 SwigcptrFunktions) AddByReference(arg2 int, arg3 int) (_swig_ret *int) { + return _swig_wrap_Funktions_addByReference(arg1, arg2, arg3) +} + +var _wrap_new_Funktions unsafe.Pointer + +func _swig_wrap_new_Funktions() (base SwigcptrFunktions) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Funktions, _swig_p) + return +} + +func NewFunktions() (_swig_ret Funktions) { + return _swig_wrap_new_Funktions() +} + +var _wrap_delete_Funktions unsafe.Pointer + +func _swig_wrap_delete_Funktions(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Funktions, _swig_p) + return +} + +func DeleteFunktions(arg1 Funktions) { + _swig_wrap_delete_Funktions(arg1.Swigcptr()) +} + +type Funktions interface { + Swigcptr() uintptr + SwigIsFunktions() + AddByValue(arg2 int, arg3 int) (_swig_ret int) + AddByPointer(arg2 int, arg3 int) (_swig_ret *int) + AddByReference(arg2 int, arg3 int) (_swig_ret *int) +} + +type SwigcptrShape uintptr + +func (p SwigcptrShape) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrShape) SwigIsShape() { +} + +var _wrap_Shape_x_set unsafe.Pointer + +func _swig_wrap_Shape_x_set(base SwigcptrShape, _ float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Shape_x_set, _swig_p) + return +} + +func (arg1 SwigcptrShape) SetX(arg2 float64) { + _swig_wrap_Shape_x_set(arg1, arg2) +} + +var _wrap_Shape_x_get unsafe.Pointer + +func _swig_wrap_Shape_x_get(base SwigcptrShape) (_ float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Shape_x_get, _swig_p) + return +} + +func (arg1 SwigcptrShape) GetX() (_swig_ret float64) { + return _swig_wrap_Shape_x_get(arg1) +} + +var _wrap_Shape_y_set unsafe.Pointer + +func _swig_wrap_Shape_y_set(base SwigcptrShape, _ float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Shape_y_set, _swig_p) + return +} + +func (arg1 SwigcptrShape) SetY(arg2 float64) { + _swig_wrap_Shape_y_set(arg1, arg2) +} + +var _wrap_Shape_y_get unsafe.Pointer + +func _swig_wrap_Shape_y_get(base SwigcptrShape) (_ float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Shape_y_get, _swig_p) + return +} + +func (arg1 SwigcptrShape) GetY() (_swig_ret float64) { + return _swig_wrap_Shape_y_get(arg1) +} + +var _wrap_Shape_z_set unsafe.Pointer + +func _swig_wrap_Shape_z_set(base SwigcptrShape, _ *float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Shape_z_set, _swig_p) + return +} + +func (arg1 SwigcptrShape) SetZ(arg2 *float64) { + _swig_wrap_Shape_z_set(arg1, arg2) +} + +var _wrap_Shape_z_get unsafe.Pointer + +func _swig_wrap_Shape_z_get(base SwigcptrShape) (_ *float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Shape_z_get, _swig_p) + return +} + +func (arg1 SwigcptrShape) GetZ() (_swig_ret *float64) { + return _swig_wrap_Shape_z_get(arg1) +} + +var _wrap_Shape_move unsafe.Pointer + +func _swig_wrap_Shape_move(base SwigcptrShape, _ float64, _ float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Shape_move, _swig_p) + return +} + +func (arg1 SwigcptrShape) Move(arg2 float64, arg3 float64) { + _swig_wrap_Shape_move(arg1, arg2, arg3) +} + +var _wrap_Shape_area unsafe.Pointer + +func _swig_wrap_Shape_area(base SwigcptrShape, _ uintptr, _ _swig_memberptr) (_ float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Shape_area, _swig_p) + return +} + +func (arg1 SwigcptrShape) Area(arg2 Shape, arg3 _swig_memberptr) (_swig_ret float64) { + return _swig_wrap_Shape_area(arg1, arg2.Swigcptr(), arg3) +} + +var _wrap_Shape_abc unsafe.Pointer + +func _swig_wrap_Shape_abc(base SwigcptrShape, _ uintptr, _ uintptr) (_ float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Shape_abc, _swig_p) + return +} + +func (arg1 SwigcptrShape) Abc(arg2 Thing_Sl_short_Sg_, arg3 Thing_Sl_Space_Shape_SS_const_Sm__Sg_) (_swig_ret float64) { + return _swig_wrap_Shape_abc(arg1, arg2.Swigcptr(), arg3.Swigcptr()) +} + +var _wrap_new_Shape unsafe.Pointer + +func _swig_wrap_new_Shape() (base SwigcptrShape) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Shape, _swig_p) + return +} + +func NewShape() (_swig_ret Shape) { + return _swig_wrap_new_Shape() +} + +var _wrap_delete_Shape unsafe.Pointer + +func _swig_wrap_delete_Shape(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Shape, _swig_p) + return +} + +func DeleteShape(arg1 Shape) { + _swig_wrap_delete_Shape(arg1.Swigcptr()) +} + +type Shape interface { + Swigcptr() uintptr + SwigIsShape() + SetX(arg2 float64) + GetX() (_swig_ret float64) + SetY(arg2 float64) + GetY() (_swig_ret float64) + SetZ(arg2 *float64) + GetZ() (_swig_ret *float64) + Move(arg2 float64, arg3 float64) + Area(arg2 Shape, arg3 _swig_memberptr) (_swig_ret float64) + Abc(arg2 Thing_Sl_short_Sg_, arg3 Thing_Sl_Space_Shape_SS_const_Sm__Sg_) (_swig_ret float64) +} + +var _wrap_do_op unsafe.Pointer + +func _swig_wrap_do_op(base uintptr, _ _swig_memberptr) (_ float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_do_op, _swig_p) + return +} + +func Do_op(arg1 Shape, arg2 _swig_memberptr) (_swig_ret float64) { + return _swig_wrap_do_op(arg1.Swigcptr(), arg2) +} + +var _wrap_areapt unsafe.Pointer + +func Areapt() (_swig_ret _swig_memberptr) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_areapt, _swig_p) + return +} +var _wrap_abcpt unsafe.Pointer + +func Abcpt() (_swig_ret _swig_memberptr) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_abcpt, _swig_p) + return +} +var _wrap_areavar_set unsafe.Pointer + +func _swig_wrap_areavar_set(base _swig_memberptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_areavar_set, _swig_p) + return +} + +func SetAreavar(arg1 _swig_memberptr) { + _swig_wrap_areavar_set(arg1) +} + +var _wrap_areavar_get unsafe.Pointer + +func GetAreavar() (_swig_ret _swig_memberptr) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_areavar_get, _swig_p) + return +} +var _wrap_abcvar_set unsafe.Pointer + +func _swig_wrap_abcvar_set(base _swig_memberptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_abcvar_set, _swig_p) + return +} + +func SetAbcvar(arg1 _swig_memberptr) { + _swig_wrap_abcvar_set(arg1) +} + +var _wrap_abcvar_get unsafe.Pointer + +func GetAbcvar() (_swig_ret _swig_memberptr) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_abcvar_get, _swig_p) + return +} +var _wrap_AREAPT unsafe.Pointer + +func _swig_getAREAPT() (_swig_ret _swig_memberptr) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_AREAPT, _swig_p) + return +} +var AREAPT _swig_memberptr = _swig_getAREAPT() +var _wrap_PERIMPT unsafe.Pointer + +func _swig_getPERIMPT() (_swig_ret _swig_memberptr) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_PERIMPT, _swig_p) + return +} +var PERIMPT _swig_memberptr = _swig_getPERIMPT() +var _wrap_NULLPT unsafe.Pointer + +func _swig_getNULLPT() (_swig_ret _swig_memberptr) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_NULLPT, _swig_p) + return +} +var NULLPT _swig_memberptr = _swig_getNULLPT() +var _wrap_call1 unsafe.Pointer + +func Call1(arg1 _swig_memberptr, arg2 int, arg3 int) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_call1, _swig_p) + return +} +var _wrap_call2 unsafe.Pointer + +func Call2(arg1 _swig_memberptr, arg2 int, arg3 int) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_call2, _swig_p) + return +} +var _wrap_call3 unsafe.Pointer + +func Call3(arg1 _swig_memberptr, arg2 int, arg3 int) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_call3, _swig_p) + return +} +var _wrap_ADD_BY_VALUE unsafe.Pointer + +func _swig_getADD_BY_VALUE() (_swig_ret _swig_memberptr) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_ADD_BY_VALUE, _swig_p) + return +} +var ADD_BY_VALUE _swig_memberptr = _swig_getADD_BY_VALUE() +var _wrap_ADD_BY_POINTER unsafe.Pointer + +func _swig_getADD_BY_POINTER() (_swig_ret _swig_memberptr) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_ADD_BY_POINTER, _swig_p) + return +} +var ADD_BY_POINTER _swig_memberptr = _swig_getADD_BY_POINTER() +var _wrap_ADD_BY_REFERENCE unsafe.Pointer + +func _swig_getADD_BY_REFERENCE() (_swig_ret _swig_memberptr) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_ADD_BY_REFERENCE, _swig_p) + return +} +var ADD_BY_REFERENCE _swig_memberptr = _swig_getADD_BY_REFERENCE() +var _wrap_unreal1 unsafe.Pointer + +func Unreal1(arg1 _swig_memberptr) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_unreal1, _swig_p) + return +} +var _wrap_unreal2 unsafe.Pointer + +func Unreal2(arg1 _swig_memberptr) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_unreal2, _swig_p) + return +} + +type SwigcptrThing_Sl_short_Sg_ uintptr +type Thing_Sl_short_Sg_ interface { + Swigcptr() uintptr; +} +func (p SwigcptrThing_Sl_short_Sg_) Swigcptr() uintptr { + return uintptr(p) +} + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + +type SwigcptrThing_Sl_Space_Shape_SS_const_Sm__Sg_ uintptr +type Thing_Sl_Space_Shape_SS_const_Sm__Sg_ interface { + Swigcptr() uintptr; +} +func (p SwigcptrThing_Sl_Space_Shape_SS_const_Sm__Sg_) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/member_pointer.go b/Examples/test-suite/go/member_pointer.go new file mode 100644 index 000000000..3a6cb8556 --- /dev/null +++ b/Examples/test-suite/go/member_pointer.go @@ -0,0 +1,737 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../member_pointer.i + +package member_pointer + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrShape uintptr + +func (p SwigcptrShape) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrShape) SwigIsShape() { +} + +var _wrap_delete_Shape unsafe.Pointer + +func _swig_wrap_delete_Shape(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Shape, _swig_p) + return +} + +func DeleteShape(arg1 Shape) { + _swig_wrap_delete_Shape(arg1.Swigcptr()) +} + +var _wrap_Shape_x_set unsafe.Pointer + +func _swig_wrap_Shape_x_set(base SwigcptrShape, _ float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Shape_x_set, _swig_p) + return +} + +func (arg1 SwigcptrShape) SetX(arg2 float64) { + _swig_wrap_Shape_x_set(arg1, arg2) +} + +var _wrap_Shape_x_get unsafe.Pointer + +func _swig_wrap_Shape_x_get(base SwigcptrShape) (_ float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Shape_x_get, _swig_p) + return +} + +func (arg1 SwigcptrShape) GetX() (_swig_ret float64) { + return _swig_wrap_Shape_x_get(arg1) +} + +var _wrap_Shape_y_set unsafe.Pointer + +func _swig_wrap_Shape_y_set(base SwigcptrShape, _ float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Shape_y_set, _swig_p) + return +} + +func (arg1 SwigcptrShape) SetY(arg2 float64) { + _swig_wrap_Shape_y_set(arg1, arg2) +} + +var _wrap_Shape_y_get unsafe.Pointer + +func _swig_wrap_Shape_y_get(base SwigcptrShape) (_ float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Shape_y_get, _swig_p) + return +} + +func (arg1 SwigcptrShape) GetY() (_swig_ret float64) { + return _swig_wrap_Shape_y_get(arg1) +} + +var _wrap_Shape_z_set unsafe.Pointer + +func _swig_wrap_Shape_z_set(base SwigcptrShape, _ *float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Shape_z_set, _swig_p) + return +} + +func (arg1 SwigcptrShape) SetZ(arg2 *float64) { + _swig_wrap_Shape_z_set(arg1, arg2) +} + +var _wrap_Shape_z_get unsafe.Pointer + +func _swig_wrap_Shape_z_get(base SwigcptrShape) (_ *float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Shape_z_get, _swig_p) + return +} + +func (arg1 SwigcptrShape) GetZ() (_swig_ret *float64) { + return _swig_wrap_Shape_z_get(arg1) +} + +var _wrap_Shape_move unsafe.Pointer + +func _swig_wrap_Shape_move(base SwigcptrShape, _ float64, _ float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Shape_move, _swig_p) + return +} + +func (arg1 SwigcptrShape) Move(arg2 float64, arg3 float64) { + _swig_wrap_Shape_move(arg1, arg2, arg3) +} + +var _wrap_Shape_area unsafe.Pointer + +func _swig_wrap_Shape_area(base SwigcptrShape) (_ float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Shape_area, _swig_p) + return +} + +func (arg1 SwigcptrShape) Area() (_swig_ret float64) { + return _swig_wrap_Shape_area(arg1) +} + +var _wrap_Shape_perimeter unsafe.Pointer + +func _swig_wrap_Shape_perimeter(base SwigcptrShape) (_ float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Shape_perimeter, _swig_p) + return +} + +func (arg1 SwigcptrShape) Perimeter() (_swig_ret float64) { + return _swig_wrap_Shape_perimeter(arg1) +} + +var _wrap_Shape_nshapes_set unsafe.Pointer + +func _swig_wrap_Shape_nshapes_set(base int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Shape_nshapes_set, _swig_p) + return +} + +func SetShapeNshapes(arg1 int) { + _swig_wrap_Shape_nshapes_set(arg1) +} + +var _wrap_Shape_nshapes_get unsafe.Pointer + +func GetShapeNshapes() (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_Shape_nshapes_get, _swig_p) + return +} +type Shape interface { + Swigcptr() uintptr + SwigIsShape() + SetX(arg2 float64) + GetX() (_swig_ret float64) + SetY(arg2 float64) + GetY() (_swig_ret float64) + SetZ(arg2 *float64) + GetZ() (_swig_ret *float64) + Move(arg2 float64, arg3 float64) + Area() (_swig_ret float64) + Perimeter() (_swig_ret float64) +} + +type SwigcptrCircle uintptr + +func (p SwigcptrCircle) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrCircle) SwigIsCircle() { +} + +var _wrap_new_Circle unsafe.Pointer + +func _swig_wrap_new_Circle(base float64) (_ SwigcptrCircle) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Circle, _swig_p) + return +} + +func NewCircle(arg1 float64) (_swig_ret Circle) { + return _swig_wrap_new_Circle(arg1) +} + +var _wrap_Circle_area unsafe.Pointer + +func _swig_wrap_Circle_area(base SwigcptrCircle) (_ float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Circle_area, _swig_p) + return +} + +func (arg1 SwigcptrCircle) Area() (_swig_ret float64) { + return _swig_wrap_Circle_area(arg1) +} + +var _wrap_Circle_perimeter unsafe.Pointer + +func _swig_wrap_Circle_perimeter(base SwigcptrCircle) (_ float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Circle_perimeter, _swig_p) + return +} + +func (arg1 SwigcptrCircle) Perimeter() (_swig_ret float64) { + return _swig_wrap_Circle_perimeter(arg1) +} + +var _wrap_delete_Circle unsafe.Pointer + +func _swig_wrap_delete_Circle(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Circle, _swig_p) + return +} + +func DeleteCircle(arg1 Circle) { + _swig_wrap_delete_Circle(arg1.Swigcptr()) +} + +var _wrap_SetCircle_X unsafe.Pointer + +func _swig_wrap_SetCircle_X(base SwigcptrCircle, _ float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_SetCircle_X, _swig_p) + return +} + +func (_swig_base SwigcptrCircle) SetX(arg1 float64) { + _swig_wrap_SetCircle_X(_swig_base, arg1) +} + +var _wrap_GetCircle_X unsafe.Pointer + +func _swig_wrap_GetCircle_X(base SwigcptrCircle) (_ float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_GetCircle_X, _swig_p) + return +} + +func (_swig_base SwigcptrCircle) GetX() (_swig_ret float64) { + return _swig_wrap_GetCircle_X(_swig_base) +} + +var _wrap_SetCircle_Y unsafe.Pointer + +func _swig_wrap_SetCircle_Y(base SwigcptrCircle, _ float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_SetCircle_Y, _swig_p) + return +} + +func (_swig_base SwigcptrCircle) SetY(arg1 float64) { + _swig_wrap_SetCircle_Y(_swig_base, arg1) +} + +var _wrap_GetCircle_Y unsafe.Pointer + +func _swig_wrap_GetCircle_Y(base SwigcptrCircle) (_ float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_GetCircle_Y, _swig_p) + return +} + +func (_swig_base SwigcptrCircle) GetY() (_swig_ret float64) { + return _swig_wrap_GetCircle_Y(_swig_base) +} + +var _wrap_SetCircle_Z unsafe.Pointer + +func _swig_wrap_SetCircle_Z(base SwigcptrCircle, _ *float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_SetCircle_Z, _swig_p) + return +} + +func (_swig_base SwigcptrCircle) SetZ(arg1 *float64) { + _swig_wrap_SetCircle_Z(_swig_base, arg1) +} + +var _wrap_GetCircle_Z unsafe.Pointer + +func _swig_wrap_GetCircle_Z(base SwigcptrCircle) (_ *float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_GetCircle_Z, _swig_p) + return +} + +func (_swig_base SwigcptrCircle) GetZ() (_swig_ret *float64) { + return _swig_wrap_GetCircle_Z(_swig_base) +} + +var _wrap_Circle_move unsafe.Pointer + +func _swig_wrap_Circle_move(base SwigcptrCircle, _ float64, _ float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Circle_move, _swig_p) + return +} + +func (_swig_base SwigcptrCircle) Move(arg1 float64, arg2 float64) { + _swig_wrap_Circle_move(_swig_base, arg1, arg2) +} + +func (p SwigcptrCircle) SwigIsShape() { +} + +func (p SwigcptrCircle) SwigGetShape() Shape { + return SwigcptrShape(p.Swigcptr()) +} + +type Circle interface { + Swigcptr() uintptr + SwigIsCircle() + Area() (_swig_ret float64) + Perimeter() (_swig_ret float64) + SetX(arg1 float64) + GetX() (_swig_ret float64) + SetY(arg1 float64) + GetY() (_swig_ret float64) + SetZ(arg1 *float64) + GetZ() (_swig_ret *float64) + Move(arg1 float64, arg2 float64) + SwigIsShape() + SwigGetShape() Shape +} + +type SwigcptrSquare uintptr + +func (p SwigcptrSquare) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrSquare) SwigIsSquare() { +} + +var _wrap_new_Square unsafe.Pointer + +func _swig_wrap_new_Square(base float64) (_ SwigcptrSquare) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Square, _swig_p) + return +} + +func NewSquare(arg1 float64) (_swig_ret Square) { + return _swig_wrap_new_Square(arg1) +} + +var _wrap_Square_area unsafe.Pointer + +func _swig_wrap_Square_area(base SwigcptrSquare) (_ float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Square_area, _swig_p) + return +} + +func (arg1 SwigcptrSquare) Area() (_swig_ret float64) { + return _swig_wrap_Square_area(arg1) +} + +var _wrap_Square_perimeter unsafe.Pointer + +func _swig_wrap_Square_perimeter(base SwigcptrSquare) (_ float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Square_perimeter, _swig_p) + return +} + +func (arg1 SwigcptrSquare) Perimeter() (_swig_ret float64) { + return _swig_wrap_Square_perimeter(arg1) +} + +var _wrap_delete_Square unsafe.Pointer + +func _swig_wrap_delete_Square(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Square, _swig_p) + return +} + +func DeleteSquare(arg1 Square) { + _swig_wrap_delete_Square(arg1.Swigcptr()) +} + +var _wrap_SetSquare_X unsafe.Pointer + +func _swig_wrap_SetSquare_X(base SwigcptrSquare, _ float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_SetSquare_X, _swig_p) + return +} + +func (_swig_base SwigcptrSquare) SetX(arg1 float64) { + _swig_wrap_SetSquare_X(_swig_base, arg1) +} + +var _wrap_GetSquare_X unsafe.Pointer + +func _swig_wrap_GetSquare_X(base SwigcptrSquare) (_ float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_GetSquare_X, _swig_p) + return +} + +func (_swig_base SwigcptrSquare) GetX() (_swig_ret float64) { + return _swig_wrap_GetSquare_X(_swig_base) +} + +var _wrap_SetSquare_Y unsafe.Pointer + +func _swig_wrap_SetSquare_Y(base SwigcptrSquare, _ float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_SetSquare_Y, _swig_p) + return +} + +func (_swig_base SwigcptrSquare) SetY(arg1 float64) { + _swig_wrap_SetSquare_Y(_swig_base, arg1) +} + +var _wrap_GetSquare_Y unsafe.Pointer + +func _swig_wrap_GetSquare_Y(base SwigcptrSquare) (_ float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_GetSquare_Y, _swig_p) + return +} + +func (_swig_base SwigcptrSquare) GetY() (_swig_ret float64) { + return _swig_wrap_GetSquare_Y(_swig_base) +} + +var _wrap_SetSquare_Z unsafe.Pointer + +func _swig_wrap_SetSquare_Z(base SwigcptrSquare, _ *float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_SetSquare_Z, _swig_p) + return +} + +func (_swig_base SwigcptrSquare) SetZ(arg1 *float64) { + _swig_wrap_SetSquare_Z(_swig_base, arg1) +} + +var _wrap_GetSquare_Z unsafe.Pointer + +func _swig_wrap_GetSquare_Z(base SwigcptrSquare) (_ *float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_GetSquare_Z, _swig_p) + return +} + +func (_swig_base SwigcptrSquare) GetZ() (_swig_ret *float64) { + return _swig_wrap_GetSquare_Z(_swig_base) +} + +var _wrap_Square_move unsafe.Pointer + +func _swig_wrap_Square_move(base SwigcptrSquare, _ float64, _ float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Square_move, _swig_p) + return +} + +func (_swig_base SwigcptrSquare) Move(arg1 float64, arg2 float64) { + _swig_wrap_Square_move(_swig_base, arg1, arg2) +} + +func (p SwigcptrSquare) SwigIsShape() { +} + +func (p SwigcptrSquare) SwigGetShape() Shape { + return SwigcptrShape(p.Swigcptr()) +} + +type Square interface { + Swigcptr() uintptr + SwigIsSquare() + Area() (_swig_ret float64) + Perimeter() (_swig_ret float64) + SetX(arg1 float64) + GetX() (_swig_ret float64) + SetY(arg1 float64) + GetY() (_swig_ret float64) + SetZ(arg1 *float64) + GetZ() (_swig_ret *float64) + Move(arg1 float64, arg2 float64) + SwigIsShape() + SwigGetShape() Shape +} + +var _wrap_do_op unsafe.Pointer + +func _swig_wrap_do_op(base uintptr, _ _swig_memberptr) (_ float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_do_op, _swig_p) + return +} + +func Do_op(arg1 Shape, arg2 _swig_memberptr) (_swig_ret float64) { + return _swig_wrap_do_op(arg1.Swigcptr(), arg2) +} + +var _wrap_areapt unsafe.Pointer + +func Areapt() (_swig_ret _swig_memberptr) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_areapt, _swig_p) + return +} +var _wrap_perimeterpt unsafe.Pointer + +func Perimeterpt() (_swig_ret _swig_memberptr) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_perimeterpt, _swig_p) + return +} +var _wrap_areavar_set unsafe.Pointer + +func _swig_wrap_areavar_set(base _swig_memberptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_areavar_set, _swig_p) + return +} + +func SetAreavar(arg1 _swig_memberptr) { + _swig_wrap_areavar_set(arg1) +} + +var _wrap_areavar_get unsafe.Pointer + +func GetAreavar() (_swig_ret _swig_memberptr) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_areavar_get, _swig_p) + return +} +var _wrap_perimetervar_set unsafe.Pointer + +func _swig_wrap_perimetervar_set(base _swig_memberptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_perimetervar_set, _swig_p) + return +} + +func SetPerimetervar(arg1 _swig_memberptr) { + _swig_wrap_perimetervar_set(arg1) +} + +var _wrap_perimetervar_get unsafe.Pointer + +func GetPerimetervar() (_swig_ret _swig_memberptr) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_perimetervar_get, _swig_p) + return +} +var _wrap_AREAPT unsafe.Pointer + +func _swig_getAREAPT() (_swig_ret _swig_memberptr) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_AREAPT, _swig_p) + return +} +var AREAPT _swig_memberptr = _swig_getAREAPT() +var _wrap_PERIMPT unsafe.Pointer + +func _swig_getPERIMPT() (_swig_ret _swig_memberptr) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_PERIMPT, _swig_p) + return +} +var PERIMPT _swig_memberptr = _swig_getPERIMPT() +var _wrap_NULLPT unsafe.Pointer + +func _swig_getNULLPT() (_swig_ret _swig_memberptr) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_NULLPT, _swig_p) + return +} +var NULLPT _swig_memberptr = _swig_getNULLPT() +type SwigcptrFunktions uintptr + +func (p SwigcptrFunktions) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrFunktions) SwigIsFunktions() { +} + +var _wrap_Funktions_addByValue unsafe.Pointer + +func _swig_wrap_Funktions_addByValue(base SwigcptrFunktions, _ int, _ int) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Funktions_addByValue, _swig_p) + return +} + +func (arg1 SwigcptrFunktions) AddByValue(arg2 int, arg3 int) (_swig_ret int) { + return _swig_wrap_Funktions_addByValue(arg1, arg2, arg3) +} + +var _wrap_Funktions_addByPointer unsafe.Pointer + +func _swig_wrap_Funktions_addByPointer(base SwigcptrFunktions, _ int, _ int) (_ *int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Funktions_addByPointer, _swig_p) + return +} + +func (arg1 SwigcptrFunktions) AddByPointer(arg2 int, arg3 int) (_swig_ret *int) { + return _swig_wrap_Funktions_addByPointer(arg1, arg2, arg3) +} + +var _wrap_Funktions_addByReference unsafe.Pointer + +func _swig_wrap_Funktions_addByReference(base SwigcptrFunktions, _ int, _ int) (_ *int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Funktions_addByReference, _swig_p) + return +} + +func (arg1 SwigcptrFunktions) AddByReference(arg2 int, arg3 int) (_swig_ret *int) { + return _swig_wrap_Funktions_addByReference(arg1, arg2, arg3) +} + +var _wrap_new_Funktions unsafe.Pointer + +func _swig_wrap_new_Funktions() (base SwigcptrFunktions) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Funktions, _swig_p) + return +} + +func NewFunktions() (_swig_ret Funktions) { + return _swig_wrap_new_Funktions() +} + +var _wrap_delete_Funktions unsafe.Pointer + +func _swig_wrap_delete_Funktions(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Funktions, _swig_p) + return +} + +func DeleteFunktions(arg1 Funktions) { + _swig_wrap_delete_Funktions(arg1.Swigcptr()) +} + +type Funktions interface { + Swigcptr() uintptr + SwigIsFunktions() + AddByValue(arg2 int, arg3 int) (_swig_ret int) + AddByPointer(arg2 int, arg3 int) (_swig_ret *int) + AddByReference(arg2 int, arg3 int) (_swig_ret *int) +} + +var _wrap_call1 unsafe.Pointer + +func Call1(arg1 _swig_memberptr, arg2 int, arg3 int) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_call1, _swig_p) + return +} +var _wrap_call2 unsafe.Pointer + +func Call2(arg1 _swig_memberptr, arg2 int, arg3 int) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_call2, _swig_p) + return +} +var _wrap_call3 unsafe.Pointer + +func Call3(arg1 _swig_memberptr, arg2 int, arg3 int) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_call3, _swig_p) + return +} +var _wrap_ADD_BY_VALUE unsafe.Pointer + +func _swig_getADD_BY_VALUE() (_swig_ret _swig_memberptr) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_ADD_BY_VALUE, _swig_p) + return +} +var ADD_BY_VALUE _swig_memberptr = _swig_getADD_BY_VALUE() +var _wrap_ADD_BY_POINTER unsafe.Pointer + +func _swig_getADD_BY_POINTER() (_swig_ret _swig_memberptr) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_ADD_BY_POINTER, _swig_p) + return +} +var ADD_BY_POINTER _swig_memberptr = _swig_getADD_BY_POINTER() +var _wrap_ADD_BY_REFERENCE unsafe.Pointer + +func _swig_getADD_BY_REFERENCE() (_swig_ret _swig_memberptr) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_ADD_BY_REFERENCE, _swig_p) + return +} +var ADD_BY_REFERENCE _swig_memberptr = _swig_getADD_BY_REFERENCE() + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/member_pointer_runme b/Examples/test-suite/go/member_pointer_runme new file mode 100755 index 000000000..4260d872e Binary files /dev/null and b/Examples/test-suite/go/member_pointer_runme differ diff --git a/Examples/test-suite/go/member_template.go b/Examples/test-suite/go/member_template.go new file mode 100644 index 000000000..a305b50f0 --- /dev/null +++ b/Examples/test-suite/go/member_template.go @@ -0,0 +1,165 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../member_template.i + +package member_template + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrFooint uintptr + +func (p SwigcptrFooint) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrFooint) SwigIsFooint() { +} + +var _wrap_Fooint_maxi unsafe.Pointer + +func _swig_wrap_Fooint_maxi(base SwigcptrFooint, _ int, _ int) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Fooint_maxi, _swig_p) + return +} + +func (arg1 SwigcptrFooint) Maxi(arg2 int, arg3 int) (_swig_ret int) { + return _swig_wrap_Fooint_maxi(arg1, arg2, arg3) +} + +var _wrap_Fooint_maxd unsafe.Pointer + +func _swig_wrap_Fooint_maxd(base SwigcptrFooint, _ float64, _ float64) (_ float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Fooint_maxd, _swig_p) + return +} + +func (arg1 SwigcptrFooint) Maxd(arg2 float64, arg3 float64) (_swig_ret float64) { + return _swig_wrap_Fooint_maxd(arg1, arg2, arg3) +} + +var _wrap_new_Fooint unsafe.Pointer + +func _swig_wrap_new_Fooint() (base SwigcptrFooint) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Fooint, _swig_p) + return +} + +func NewFooint() (_swig_ret Fooint) { + return _swig_wrap_new_Fooint() +} + +var _wrap_delete_Fooint unsafe.Pointer + +func _swig_wrap_delete_Fooint(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Fooint, _swig_p) + return +} + +func DeleteFooint(arg1 Fooint) { + _swig_wrap_delete_Fooint(arg1.Swigcptr()) +} + +type Fooint interface { + Swigcptr() uintptr + SwigIsFooint() + Maxi(arg2 int, arg3 int) (_swig_ret int) + Maxd(arg2 float64, arg3 float64) (_swig_ret float64) +} + +type SwigcptrFoodouble uintptr + +func (p SwigcptrFoodouble) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrFoodouble) SwigIsFoodouble() { +} + +var _wrap_Foodouble_maxi unsafe.Pointer + +func _swig_wrap_Foodouble_maxi(base SwigcptrFoodouble, _ int, _ int) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foodouble_maxi, _swig_p) + return +} + +func (arg1 SwigcptrFoodouble) Maxi(arg2 int, arg3 int) (_swig_ret int) { + return _swig_wrap_Foodouble_maxi(arg1, arg2, arg3) +} + +var _wrap_Foodouble_maxd unsafe.Pointer + +func _swig_wrap_Foodouble_maxd(base SwigcptrFoodouble, _ float64, _ float64) (_ float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foodouble_maxd, _swig_p) + return +} + +func (arg1 SwigcptrFoodouble) Maxd(arg2 float64, arg3 float64) (_swig_ret float64) { + return _swig_wrap_Foodouble_maxd(arg1, arg2, arg3) +} + +var _wrap_new_Foodouble unsafe.Pointer + +func _swig_wrap_new_Foodouble() (base SwigcptrFoodouble) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Foodouble, _swig_p) + return +} + +func NewFoodouble() (_swig_ret Foodouble) { + return _swig_wrap_new_Foodouble() +} + +var _wrap_delete_Foodouble unsafe.Pointer + +func _swig_wrap_delete_Foodouble(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Foodouble, _swig_p) + return +} + +func DeleteFoodouble(arg1 Foodouble) { + _swig_wrap_delete_Foodouble(arg1.Swigcptr()) +} + +type Foodouble interface { + Swigcptr() uintptr + SwigIsFoodouble() + Maxi(arg2 int, arg3 int) (_swig_ret int) + Maxd(arg2 float64, arg3 float64) (_swig_ret float64) +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/memberin_extend.go b/Examples/test-suite/go/memberin_extend.go new file mode 100644 index 000000000..de9f51ee3 --- /dev/null +++ b/Examples/test-suite/go/memberin_extend.go @@ -0,0 +1,101 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../memberin_extend.i + +package memberin_extend + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrExtendMe uintptr + +func (p SwigcptrExtendMe) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrExtendMe) SwigIsExtendMe() { +} + +var _wrap_ExtendMe_thing_set unsafe.Pointer + +func _swig_wrap_ExtendMe_thing_set(base SwigcptrExtendMe, _ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_ExtendMe_thing_set, _swig_p) + return +} + +func (arg1 SwigcptrExtendMe) SetThing(arg2 string) { + _swig_wrap_ExtendMe_thing_set(arg1, arg2) +} + +var _wrap_ExtendMe_thing_get unsafe.Pointer + +func _swig_wrap_ExtendMe_thing_get(base SwigcptrExtendMe) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_ExtendMe_thing_get, _swig_p) + return +} + +func (arg1 SwigcptrExtendMe) GetThing() (_swig_ret string) { + return _swig_wrap_ExtendMe_thing_get(arg1) +} + +var _wrap_new_ExtendMe unsafe.Pointer + +func _swig_wrap_new_ExtendMe() (base SwigcptrExtendMe) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_ExtendMe, _swig_p) + return +} + +func NewExtendMe() (_swig_ret ExtendMe) { + return _swig_wrap_new_ExtendMe() +} + +var _wrap_delete_ExtendMe unsafe.Pointer + +func _swig_wrap_delete_ExtendMe(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_ExtendMe, _swig_p) + return +} + +func DeleteExtendMe(arg1 ExtendMe) { + _swig_wrap_delete_ExtendMe(arg1.Swigcptr()) +} + +type ExtendMe interface { + Swigcptr() uintptr + SwigIsExtendMe() + SetThing(arg2 string) + GetThing() (_swig_ret string) +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/memberin_extend_c.go b/Examples/test-suite/go/memberin_extend_c.go new file mode 100644 index 000000000..4f128e9a3 --- /dev/null +++ b/Examples/test-suite/go/memberin_extend_c.go @@ -0,0 +1,101 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../memberin_extend_c.i + +package memberin_extend_c + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrPerson uintptr + +func (p SwigcptrPerson) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrPerson) SwigIsPerson() { +} + +var _wrap_Person_name_set unsafe.Pointer + +func _swig_wrap_Person_name_set(base SwigcptrPerson, _ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Person_name_set, _swig_p) + return +} + +func (arg1 SwigcptrPerson) SetName(arg2 string) { + _swig_wrap_Person_name_set(arg1, arg2) +} + +var _wrap_Person_name_get unsafe.Pointer + +func _swig_wrap_Person_name_get(base SwigcptrPerson) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Person_name_get, _swig_p) + return +} + +func (arg1 SwigcptrPerson) GetName() (_swig_ret string) { + return _swig_wrap_Person_name_get(arg1) +} + +var _wrap_new_Person unsafe.Pointer + +func _swig_wrap_new_Person() (base SwigcptrPerson) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Person, _swig_p) + return +} + +func NewPerson() (_swig_ret Person) { + return _swig_wrap_new_Person() +} + +var _wrap_delete_Person unsafe.Pointer + +func _swig_wrap_delete_Person(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Person, _swig_p) + return +} + +func DeletePerson(arg1 Person) { + _swig_wrap_delete_Person(arg1.Swigcptr()) +} + +type Person interface { + Swigcptr() uintptr + SwigIsPerson() + SetName(arg2 string) + GetName() (_swig_ret string) +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/memberin_extend_c_runme b/Examples/test-suite/go/memberin_extend_c_runme new file mode 100755 index 000000000..6836c2671 Binary files /dev/null and b/Examples/test-suite/go/memberin_extend_c_runme differ diff --git a/Examples/test-suite/go/minherit.go b/Examples/test-suite/go/minherit.go new file mode 100644 index 000000000..7c63cc646 --- /dev/null +++ b/Examples/test-suite/go/minherit.go @@ -0,0 +1,612 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../minherit.i + +package minherit + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrFoo uintptr + +func (p SwigcptrFoo) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrFoo) SwigIsFoo() { +} + +var _wrap_new_Foo unsafe.Pointer + +func _swig_wrap_new_Foo() (base SwigcptrFoo) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Foo, _swig_p) + return +} + +func NewFoo() (_swig_ret Foo) { + return _swig_wrap_new_Foo() +} + +var _wrap_delete_Foo unsafe.Pointer + +func _swig_wrap_delete_Foo(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Foo, _swig_p) + return +} + +func DeleteFoo(arg1 Foo) { + _swig_wrap_delete_Foo(arg1.Swigcptr()) +} + +var _wrap_Foo_xget unsafe.Pointer + +func _swig_wrap_Foo_xget(base SwigcptrFoo) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_xget, _swig_p) + return +} + +func (arg1 SwigcptrFoo) Xget() (_swig_ret int) { + return _swig_wrap_Foo_xget(arg1) +} + +type Foo interface { + Swigcptr() uintptr + SwigIsFoo() + Xget() (_swig_ret int) +} + +var _wrap_toFooPtr unsafe.Pointer + +func _swig_wrap_toFooPtr(base uintptr) (_ SwigcptrFoo) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_toFooPtr, _swig_p) + return +} + +func ToFooPtr(arg1 Foo) (_swig_ret Foo) { + return _swig_wrap_toFooPtr(arg1.Swigcptr()) +} + +type SwigcptrBar uintptr + +func (p SwigcptrBar) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrBar) SwigIsBar() { +} + +var _wrap_new_Bar unsafe.Pointer + +func _swig_wrap_new_Bar() (base SwigcptrBar) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Bar, _swig_p) + return +} + +func NewBar() (_swig_ret Bar) { + return _swig_wrap_new_Bar() +} + +var _wrap_delete_Bar unsafe.Pointer + +func _swig_wrap_delete_Bar(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Bar, _swig_p) + return +} + +func DeleteBar(arg1 Bar) { + _swig_wrap_delete_Bar(arg1.Swigcptr()) +} + +var _wrap_Bar_yget unsafe.Pointer + +func _swig_wrap_Bar_yget(base SwigcptrBar) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Bar_yget, _swig_p) + return +} + +func (arg1 SwigcptrBar) Yget() (_swig_ret int) { + return _swig_wrap_Bar_yget(arg1) +} + +type Bar interface { + Swigcptr() uintptr + SwigIsBar() + Yget() (_swig_ret int) +} + +var _wrap_toBarPtr unsafe.Pointer + +func _swig_wrap_toBarPtr(base uintptr) (_ SwigcptrBar) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_toBarPtr, _swig_p) + return +} + +func ToBarPtr(arg1 Bar) (_swig_ret Bar) { + return _swig_wrap_toBarPtr(arg1.Swigcptr()) +} + +type SwigcptrFooBar uintptr + +func (p SwigcptrFooBar) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrFooBar) SwigIsFooBar() { +} + +var _wrap_new_FooBar unsafe.Pointer + +func _swig_wrap_new_FooBar() (base SwigcptrFooBar) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_FooBar, _swig_p) + return +} + +func NewFooBar() (_swig_ret FooBar) { + return _swig_wrap_new_FooBar() +} + +var _wrap_FooBar_zget unsafe.Pointer + +func _swig_wrap_FooBar_zget(base SwigcptrFooBar) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_FooBar_zget, _swig_p) + return +} + +func (arg1 SwigcptrFooBar) Zget() (_swig_ret int) { + return _swig_wrap_FooBar_zget(arg1) +} + +var _wrap_delete_FooBar unsafe.Pointer + +func _swig_wrap_delete_FooBar(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_FooBar, _swig_p) + return +} + +func DeleteFooBar(arg1 FooBar) { + _swig_wrap_delete_FooBar(arg1.Swigcptr()) +} + +var _wrap_FooBar_xget unsafe.Pointer + +func _swig_wrap_FooBar_xget(base SwigcptrFooBar) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_FooBar_xget, _swig_p) + return +} + +func (_swig_base SwigcptrFooBar) Xget() (_swig_ret int) { + return _swig_wrap_FooBar_xget(_swig_base) +} + +var _wrap_FooBar_yget unsafe.Pointer + +func _swig_wrap_FooBar_yget(base SwigcptrFooBar) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_FooBar_yget, _swig_p) + return +} + +func (_swig_base SwigcptrFooBar) Yget() (_swig_ret int) { + return _swig_wrap_FooBar_yget(_swig_base) +} + +func (p SwigcptrFooBar) SwigIsFoo() { +} + +func (p SwigcptrFooBar) SwigGetFoo() Foo { + return SwigcptrFoo(p.Swigcptr()) +} + +var _wrap_FooBar_SwigGetBar unsafe.Pointer + +func _swig_wrap_FooBar_SwigGetBar(base SwigcptrFooBar) (_ SwigcptrBar) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_FooBar_SwigGetBar, _swig_p) + return +} + +func (arg1 SwigcptrFooBar) SwigGetBar() (_swig_ret Bar) { + return _swig_wrap_FooBar_SwigGetBar(arg1) +} + +type FooBar interface { + Swigcptr() uintptr + SwigIsFooBar() + Zget() (_swig_ret int) + Xget() (_swig_ret int) + Yget() (_swig_ret int) + SwigIsFoo() + SwigGetFoo() Foo + SwigGetBar() (_swig_ret Bar) +} + +var _wrap_toFooBarPtr unsafe.Pointer + +func _swig_wrap_toFooBarPtr(base uintptr) (_ SwigcptrFooBar) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_toFooBarPtr, _swig_p) + return +} + +func ToFooBarPtr(arg1 FooBar) (_swig_ret FooBar) { + return _swig_wrap_toFooBarPtr(arg1.Swigcptr()) +} + +type SwigcptrSpam uintptr + +func (p SwigcptrSpam) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrSpam) SwigIsSpam() { +} + +var _wrap_new_Spam unsafe.Pointer + +func _swig_wrap_new_Spam() (base SwigcptrSpam) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Spam, _swig_p) + return +} + +func NewSpam() (_swig_ret Spam) { + return _swig_wrap_new_Spam() +} + +var _wrap_Spam_wget unsafe.Pointer + +func _swig_wrap_Spam_wget(base SwigcptrSpam) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Spam_wget, _swig_p) + return +} + +func (arg1 SwigcptrSpam) Wget() (_swig_ret int) { + return _swig_wrap_Spam_wget(arg1) +} + +var _wrap_delete_Spam unsafe.Pointer + +func _swig_wrap_delete_Spam(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Spam, _swig_p) + return +} + +func DeleteSpam(arg1 Spam) { + _swig_wrap_delete_Spam(arg1.Swigcptr()) +} + +var _wrap_Spam_zget unsafe.Pointer + +func _swig_wrap_Spam_zget(base SwigcptrSpam) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Spam_zget, _swig_p) + return +} + +func (_swig_base SwigcptrSpam) Zget() (_swig_ret int) { + return _swig_wrap_Spam_zget(_swig_base) +} + +var _wrap_Spam_xget unsafe.Pointer + +func _swig_wrap_Spam_xget(base SwigcptrSpam) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Spam_xget, _swig_p) + return +} + +func (_swig_base SwigcptrSpam) Xget() (_swig_ret int) { + return _swig_wrap_Spam_xget(_swig_base) +} + +var _wrap_Spam_yget unsafe.Pointer + +func _swig_wrap_Spam_yget(base SwigcptrSpam) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Spam_yget, _swig_p) + return +} + +func (_swig_base SwigcptrSpam) Yget() (_swig_ret int) { + return _swig_wrap_Spam_yget(_swig_base) +} + +func (p SwigcptrSpam) SwigIsFooBar() { +} + +func (p SwigcptrSpam) SwigGetFooBar() FooBar { + return SwigcptrFooBar(p.Swigcptr()) +} + +func (p SwigcptrSpam) SwigIsFoo() { +} + +func (p SwigcptrSpam) SwigGetFoo() Foo { + return SwigcptrFoo(p.Swigcptr()) +} + +func (p SwigcptrSpam) SwigGetBar() Bar { + return p.SwigGetFooBar().SwigGetBar() +} + +type Spam interface { + Swigcptr() uintptr + SwigIsSpam() + Wget() (_swig_ret int) + Zget() (_swig_ret int) + Xget() (_swig_ret int) + Yget() (_swig_ret int) + SwigIsFooBar() + SwigGetFooBar() FooBar + SwigIsFoo() + SwigGetFoo() Foo + SwigGetBar() Bar +} + +var _wrap_toSpamPtr unsafe.Pointer + +func _swig_wrap_toSpamPtr(base uintptr) (_ SwigcptrSpam) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_toSpamPtr, _swig_p) + return +} + +func ToSpamPtr(arg1 Spam) (_swig_ret Spam) { + return _swig_wrap_toSpamPtr(arg1.Swigcptr()) +} + +var _wrap_xget unsafe.Pointer + +func _swig_wrap_xget(base uintptr) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_xget, _swig_p) + return +} + +func Xget(arg1 Foo) (_swig_ret int) { + return _swig_wrap_xget(arg1.Swigcptr()) +} + +var _wrap_yget unsafe.Pointer + +func _swig_wrap_yget(base uintptr) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_yget, _swig_p) + return +} + +func Yget(arg1 Bar) (_swig_ret int) { + return _swig_wrap_yget(arg1.Swigcptr()) +} + +var _wrap_zget unsafe.Pointer + +func _swig_wrap_zget(base uintptr) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_zget, _swig_p) + return +} + +func Zget(arg1 FooBar) (_swig_ret int) { + return _swig_wrap_zget(arg1.Swigcptr()) +} + +var _wrap_wget unsafe.Pointer + +func _swig_wrap_wget(base uintptr) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_wget, _swig_p) + return +} + +func Wget(arg1 Spam) (_swig_ret int) { + return _swig_wrap_wget(arg1.Swigcptr()) +} + +type SwigcptrIntVector uintptr + +func (p SwigcptrIntVector) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrIntVector) SwigIsIntVector() { +} + +var _wrap_new_IntVector__SWIG_0 unsafe.Pointer + +func _swig_wrap_new_IntVector__SWIG_0() (base SwigcptrIntVector) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_IntVector__SWIG_0, _swig_p) + return +} + +func NewIntVector__SWIG_0() (_swig_ret IntVector) { + return _swig_wrap_new_IntVector__SWIG_0() +} + +var _wrap_new_IntVector__SWIG_1 unsafe.Pointer + +func _swig_wrap_new_IntVector__SWIG_1(base int64) (_ SwigcptrIntVector) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_IntVector__SWIG_1, _swig_p) + return +} + +func NewIntVector__SWIG_1(arg1 int64) (_swig_ret IntVector) { + return _swig_wrap_new_IntVector__SWIG_1(arg1) +} + +func NewIntVector(a ...interface{}) IntVector { + argc := len(a) + if argc == 0 { + return NewIntVector__SWIG_0() + } + if argc == 1 { + return NewIntVector__SWIG_1(a[0].(int64)) + } + panic("No match for overloaded function call") +} + +var _wrap_IntVector_size unsafe.Pointer + +func _swig_wrap_IntVector_size(base SwigcptrIntVector) (_ int64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_IntVector_size, _swig_p) + return +} + +func (arg1 SwigcptrIntVector) Size() (_swig_ret int64) { + return _swig_wrap_IntVector_size(arg1) +} + +var _wrap_IntVector_capacity unsafe.Pointer + +func _swig_wrap_IntVector_capacity(base SwigcptrIntVector) (_ int64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_IntVector_capacity, _swig_p) + return +} + +func (arg1 SwigcptrIntVector) Capacity() (_swig_ret int64) { + return _swig_wrap_IntVector_capacity(arg1) +} + +var _wrap_IntVector_reserve unsafe.Pointer + +func _swig_wrap_IntVector_reserve(base SwigcptrIntVector, _ int64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_IntVector_reserve, _swig_p) + return +} + +func (arg1 SwigcptrIntVector) Reserve(arg2 int64) { + _swig_wrap_IntVector_reserve(arg1, arg2) +} + +var _wrap_IntVector_isEmpty unsafe.Pointer + +func _swig_wrap_IntVector_isEmpty(base SwigcptrIntVector) (_ bool) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_IntVector_isEmpty, _swig_p) + return +} + +func (arg1 SwigcptrIntVector) IsEmpty() (_swig_ret bool) { + return _swig_wrap_IntVector_isEmpty(arg1) +} + +var _wrap_IntVector_clear unsafe.Pointer + +func _swig_wrap_IntVector_clear(base SwigcptrIntVector) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_IntVector_clear, _swig_p) + return +} + +func (arg1 SwigcptrIntVector) Clear() { + _swig_wrap_IntVector_clear(arg1) +} + +var _wrap_IntVector_add unsafe.Pointer + +func _swig_wrap_IntVector_add(base SwigcptrIntVector, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_IntVector_add, _swig_p) + return +} + +func (arg1 SwigcptrIntVector) Add(arg2 int) { + _swig_wrap_IntVector_add(arg1, arg2) +} + +var _wrap_IntVector_get unsafe.Pointer + +func _swig_wrap_IntVector_get(base SwigcptrIntVector, _ int) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_IntVector_get, _swig_p) + return +} + +func (arg1 SwigcptrIntVector) Get(arg2 int) (_swig_ret int) { + return _swig_wrap_IntVector_get(arg1, arg2) +} + +var _wrap_IntVector_set unsafe.Pointer + +func _swig_wrap_IntVector_set(base SwigcptrIntVector, _ int, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_IntVector_set, _swig_p) + return +} + +func (arg1 SwigcptrIntVector) Set(arg2 int, arg3 int) { + _swig_wrap_IntVector_set(arg1, arg2, arg3) +} + +var _wrap_delete_IntVector unsafe.Pointer + +func _swig_wrap_delete_IntVector(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_IntVector, _swig_p) + return +} + +func DeleteIntVector(arg1 IntVector) { + _swig_wrap_delete_IntVector(arg1.Swigcptr()) +} + +type IntVector interface { + Swigcptr() uintptr + SwigIsIntVector() + Size() (_swig_ret int64) + Capacity() (_swig_ret int64) + Reserve(arg2 int64) + IsEmpty() (_swig_ret bool) + Clear() + Add(arg2 int) + Get(arg2 int) (_swig_ret int) + Set(arg2 int, arg3 int) +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/minherit2.go b/Examples/test-suite/go/minherit2.go new file mode 100644 index 000000000..cef2d9dce --- /dev/null +++ b/Examples/test-suite/go/minherit2.go @@ -0,0 +1,201 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../minherit2.i + +package minherit2 + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrIRemoteSyncIO uintptr + +func (p SwigcptrIRemoteSyncIO) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrIRemoteSyncIO) SwigIsIRemoteSyncIO() { +} + +var _wrap_delete_IRemoteSyncIO unsafe.Pointer + +func _swig_wrap_delete_IRemoteSyncIO(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_IRemoteSyncIO, _swig_p) + return +} + +func DeleteIRemoteSyncIO(arg1 IRemoteSyncIO) { + _swig_wrap_delete_IRemoteSyncIO(arg1.Swigcptr()) +} + +var _wrap_IRemoteSyncIO_syncmethod unsafe.Pointer + +func _swig_wrap_IRemoteSyncIO_syncmethod(base SwigcptrIRemoteSyncIO) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_IRemoteSyncIO_syncmethod, _swig_p) + return +} + +func (arg1 SwigcptrIRemoteSyncIO) Syncmethod() { + _swig_wrap_IRemoteSyncIO_syncmethod(arg1) +} + +type IRemoteSyncIO interface { + Swigcptr() uintptr + SwigIsIRemoteSyncIO() + Syncmethod() +} + +type SwigcptrIRemoteAsyncIO uintptr + +func (p SwigcptrIRemoteAsyncIO) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrIRemoteAsyncIO) SwigIsIRemoteAsyncIO() { +} + +var _wrap_delete_IRemoteAsyncIO unsafe.Pointer + +func _swig_wrap_delete_IRemoteAsyncIO(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_IRemoteAsyncIO, _swig_p) + return +} + +func DeleteIRemoteAsyncIO(arg1 IRemoteAsyncIO) { + _swig_wrap_delete_IRemoteAsyncIO(arg1.Swigcptr()) +} + +var _wrap_IRemoteAsyncIO_asyncmethod unsafe.Pointer + +func _swig_wrap_IRemoteAsyncIO_asyncmethod(base SwigcptrIRemoteAsyncIO) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_IRemoteAsyncIO_asyncmethod, _swig_p) + return +} + +func (arg1 SwigcptrIRemoteAsyncIO) Asyncmethod() { + _swig_wrap_IRemoteAsyncIO_asyncmethod(arg1) +} + +type IRemoteAsyncIO interface { + Swigcptr() uintptr + SwigIsIRemoteAsyncIO() + Asyncmethod() +} + +type SwigcptrRemoteMpe uintptr + +func (p SwigcptrRemoteMpe) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrRemoteMpe) SwigIsRemoteMpe() { +} + +var _wrap_RemoteMpe_syncmethod unsafe.Pointer + +func _swig_wrap_RemoteMpe_syncmethod(base SwigcptrRemoteMpe) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_RemoteMpe_syncmethod, _swig_p) + return +} + +func (arg1 SwigcptrRemoteMpe) Syncmethod() { + _swig_wrap_RemoteMpe_syncmethod(arg1) +} + +var _wrap_RemoteMpe_asyncmethod unsafe.Pointer + +func _swig_wrap_RemoteMpe_asyncmethod(base SwigcptrRemoteMpe) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_RemoteMpe_asyncmethod, _swig_p) + return +} + +func (arg1 SwigcptrRemoteMpe) Asyncmethod() { + _swig_wrap_RemoteMpe_asyncmethod(arg1) +} + +var _wrap_new_RemoteMpe unsafe.Pointer + +func _swig_wrap_new_RemoteMpe() (base SwigcptrRemoteMpe) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_RemoteMpe, _swig_p) + return +} + +func NewRemoteMpe() (_swig_ret RemoteMpe) { + return _swig_wrap_new_RemoteMpe() +} + +var _wrap_delete_RemoteMpe unsafe.Pointer + +func _swig_wrap_delete_RemoteMpe(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_RemoteMpe, _swig_p) + return +} + +func DeleteRemoteMpe(arg1 RemoteMpe) { + _swig_wrap_delete_RemoteMpe(arg1.Swigcptr()) +} + +func (p SwigcptrRemoteMpe) SwigIsIRemoteSyncIO() { +} + +func (p SwigcptrRemoteMpe) SwigGetIRemoteSyncIO() IRemoteSyncIO { + return SwigcptrIRemoteSyncIO(p.Swigcptr()) +} + +var _wrap_RemoteMpe_SwigGetIRemoteAsyncIO unsafe.Pointer + +func _swig_wrap_RemoteMpe_SwigGetIRemoteAsyncIO(base SwigcptrRemoteMpe) (_ SwigcptrIRemoteAsyncIO) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_RemoteMpe_SwigGetIRemoteAsyncIO, _swig_p) + return +} + +func (arg1 SwigcptrRemoteMpe) SwigGetIRemoteAsyncIO() (_swig_ret IRemoteAsyncIO) { + return _swig_wrap_RemoteMpe_SwigGetIRemoteAsyncIO(arg1) +} + +type RemoteMpe interface { + Swigcptr() uintptr + SwigIsRemoteMpe() + Syncmethod() + Asyncmethod() + SwigIsIRemoteSyncIO() + SwigGetIRemoteSyncIO() IRemoteSyncIO + SwigGetIRemoteAsyncIO() (_swig_ret IRemoteAsyncIO) +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/minherit_runme b/Examples/test-suite/go/minherit_runme new file mode 100755 index 000000000..69e32c2f4 Binary files /dev/null and b/Examples/test-suite/go/minherit_runme differ diff --git a/Examples/test-suite/go/mixed_types.go b/Examples/test-suite/go/mixed_types.go new file mode 100644 index 000000000..635df222e --- /dev/null +++ b/Examples/test-suite/go/mixed_types.go @@ -0,0 +1,839 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../mixed_types.i + +package mixed_types + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +var _wrap_ref_pointer__SWIG_0 unsafe.Pointer + +func Ref_pointer__SWIG_0(arg1 *uintptr) (_swig_ret uintptr) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_ref_pointer__SWIG_0, _swig_p) + return +} +type SwigcptrA uintptr + +func (p SwigcptrA) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrA) SwigIsA() { +} + +var _wrap_new_A unsafe.Pointer + +func _swig_wrap_new_A() (base SwigcptrA) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_A, _swig_p) + return +} + +func NewA() (_swig_ret A) { + return _swig_wrap_new_A() +} + +var _wrap_delete_A unsafe.Pointer + +func _swig_wrap_delete_A(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_A, _swig_p) + return +} + +func DeleteA(arg1 A) { + _swig_wrap_delete_A(arg1.Swigcptr()) +} + +type A interface { + Swigcptr() uintptr + SwigIsA() +} + +var _wrap_ref_pointer__SWIG_1 unsafe.Pointer + +func _swig_wrap_ref_pointer__SWIG_1(base uintptr) (_ SwigcptrA) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_ref_pointer__SWIG_1, _swig_p) + return +} + +func Ref_pointer__SWIG_1(arg1 A) (_swig_ret A) { + return _swig_wrap_ref_pointer__SWIG_1(arg1.Swigcptr()) +} + +func Ref_pointer(a ...interface{}) interface{} { + argc := len(a) + if argc == 1 { + if _, ok := a[0].(*uintptr); !ok { + goto check_1 + } + return Ref_pointer__SWIG_0(a[0].(*uintptr)) + } +check_1: + if argc == 1 { + return Ref_pointer__SWIG_1(a[0].(A)) + } + panic("No match for overloaded function call") +} + +var _wrap_ref_pointer_1 unsafe.Pointer + +func _swig_wrap_ref_pointer_1(base uintptr) (_ SwigcptrA) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_ref_pointer_1, _swig_p) + return +} + +func Ref_pointer_1(arg1 A) (_swig_ret A) { + return _swig_wrap_ref_pointer_1(arg1.Swigcptr()) +} + +var _wrap_pointer_1 unsafe.Pointer + +func _swig_wrap_pointer_1(base uintptr) (_ SwigcptrA) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_pointer_1, _swig_p) + return +} + +func Pointer_1(arg1 A) (_swig_ret A) { + return _swig_wrap_pointer_1(arg1.Swigcptr()) +} + +var _wrap_ref_const unsafe.Pointer + +func _swig_wrap_ref_const(base uintptr) (_ SwigcptrA) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_ref_const, _swig_p) + return +} + +func Ref_const(arg1 A) (_swig_ret A) { + return _swig_wrap_ref_const(arg1.Swigcptr()) +} + +type Hello int +var _wrap_hi unsafe.Pointer + +func _swig_gethi() (_swig_ret Hello) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_hi, _swig_p) + return +} +var Hi Hello = _swig_gethi() +var _wrap_sint unsafe.Pointer + +func Sint(arg1 int) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_sint, _swig_p) + return +} +var _wrap_ref_int unsafe.Pointer + +func Ref_int(arg1 int) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_ref_int, _swig_p) + return +} +var _wrap_senum unsafe.Pointer + +func Senum(arg1 Hello) (_swig_ret Hello) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_senum, _swig_p) + return +} +var _wrap_ref_enum unsafe.Pointer + +func Ref_enum(arg1 *Hello) (_swig_ret *Hello) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_ref_enum, _swig_p) + return +} +var _wrap_rptr_const unsafe.Pointer + +func _swig_wrap_rptr_const(base uintptr) (_ SwigcptrA) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_rptr_const, _swig_p) + return +} + +func Rptr_const(arg1 A) (_swig_ret A) { + return _swig_wrap_rptr_const(arg1.Swigcptr()) +} + +var _wrap_rptr_const2 unsafe.Pointer + +func _swig_wrap_rptr_const2(base uintptr) (_ SwigcptrA) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_rptr_const2, _swig_p) + return +} + +func Rptr_const2(arg1 A) (_swig_ret A) { + return _swig_wrap_rptr_const2(arg1.Swigcptr()) +} + +var _wrap_rptr_void unsafe.Pointer + +func Rptr_void(arg1 *uintptr) (_swig_ret *uintptr) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_rptr_void, _swig_p) + return +} +var _wrap_cref_a unsafe.Pointer + +func _swig_wrap_cref_a(base uintptr) (_ SwigcptrA) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_cref_a, _swig_p) + return +} + +func Cref_a(arg1 A) (_swig_ret A) { + return _swig_wrap_cref_a(arg1.Swigcptr()) +} + +var _wrap_ref_a unsafe.Pointer + +func _swig_wrap_ref_a(base uintptr) (_ SwigcptrA) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_ref_a, _swig_p) + return +} + +func Ref_a(arg1 A) (_swig_ret A) { + return _swig_wrap_ref_a(arg1.Swigcptr()) +} + +var _wrap_test_a unsafe.Pointer + +func Test_a(arg1 string, arg2 string, arg3 string, arg4 string) (_swig_ret string) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_test_a, _swig_p) + return +} +var _wrap_test_b unsafe.Pointer + +func Test_b(arg1 string) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_test_b, _swig_p) + return +} +var _wrap_test_c unsafe.Pointer + +func Test_c(arg1 *string) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_test_c, _swig_p) + return +} +var _wrap_test_d unsafe.Pointer + +func Test_d(arg1 *string) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_test_d, _swig_p) + return +} +var _wrap_test_e unsafe.Pointer + +func _swig_wrap_test_e(base uintptr) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_test_e, _swig_p) + return +} + +func Test_e(arg1 NameT_Sl_char_Sg_) (_swig_ret int) { + return _swig_wrap_test_e(arg1.Swigcptr()) +} + +var _wrap_test_f unsafe.Pointer + +func _swig_wrap_test_f(base uintptr) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_test_f, _swig_p) + return +} + +func Test_f(arg1 NameT_Sl_char_Sg_) (_swig_ret int) { + return _swig_wrap_test_f(arg1.Swigcptr()) +} + +var _wrap_test_g unsafe.Pointer + +func _swig_wrap_test_g(base uintptr) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_test_g, _swig_p) + return +} + +func Test_g(arg1 NameT_Sl_char_Sg_) (_swig_ret int) { + return _swig_wrap_test_g(arg1.Swigcptr()) +} + +type SwigcptrFoo uintptr + +func (p SwigcptrFoo) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrFoo) SwigIsFoo() { +} + +var _wrap_Foo_foo unsafe.Pointer + +func _swig_wrap_Foo_foo(base SwigcptrFoo, _ uintptr) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_foo, _swig_p) + return +} + +func (arg1 SwigcptrFoo) Foo(arg2 A) (_swig_ret int) { + return _swig_wrap_Foo_foo(arg1, arg2.Swigcptr()) +} + +var _wrap_Foo_foon unsafe.Pointer + +func _swig_wrap_Foo_foon(base SwigcptrFoo, _ *string) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_foon, _swig_p) + return +} + +func (arg1 SwigcptrFoo) Foon(arg2 *string) (_swig_ret int) { + return _swig_wrap_Foo_foon(arg1, arg2) +} + +var _wrap_new_Foo unsafe.Pointer + +func _swig_wrap_new_Foo() (base SwigcptrFoo) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Foo, _swig_p) + return +} + +func NewFoo() (_swig_ret Foo) { + return _swig_wrap_new_Foo() +} + +var _wrap_delete_Foo unsafe.Pointer + +func _swig_wrap_delete_Foo(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Foo, _swig_p) + return +} + +func DeleteFoo(arg1 Foo) { + _swig_wrap_delete_Foo(arg1.Swigcptr()) +} + +type Foo interface { + Swigcptr() uintptr + SwigIsFoo() + Foo(arg2 A) (_swig_ret int) + Foon(arg2 *string) (_swig_ret int) +} + +const ARRAY_LEN_X int = 2 +const ARRAY_LEN_Y int = 4 +type Finger int +var _wrap_One unsafe.Pointer + +func _swig_getOne() (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_One, _swig_p) + return +} +var One int = _swig_getOne() +var _wrap_Two unsafe.Pointer + +func _swig_getTwo() (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_Two, _swig_p) + return +} +var Two int = _swig_getTwo() +var _wrap_Three unsafe.Pointer + +func _swig_getThree() (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_Three, _swig_p) + return +} +var Three int = _swig_getThree() +var _wrap_Four unsafe.Pointer + +func _swig_getFour() (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_Four, _swig_p) + return +} +var Four int = _swig_getFour() +var _wrap_Five unsafe.Pointer + +func _swig_getFive() (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_Five, _swig_p) + return +} +var Five int = _swig_getFive() +type SwigcptrSimpleStruct uintptr + +func (p SwigcptrSimpleStruct) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrSimpleStruct) SwigIsSimpleStruct() { +} + +var _wrap_SimpleStruct_double_field_set unsafe.Pointer + +func _swig_wrap_SimpleStruct_double_field_set(base SwigcptrSimpleStruct, _ float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_SimpleStruct_double_field_set, _swig_p) + return +} + +func (arg1 SwigcptrSimpleStruct) SetDouble_field(arg2 float64) { + _swig_wrap_SimpleStruct_double_field_set(arg1, arg2) +} + +var _wrap_SimpleStruct_double_field_get unsafe.Pointer + +func _swig_wrap_SimpleStruct_double_field_get(base SwigcptrSimpleStruct) (_ float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_SimpleStruct_double_field_get, _swig_p) + return +} + +func (arg1 SwigcptrSimpleStruct) GetDouble_field() (_swig_ret float64) { + return _swig_wrap_SimpleStruct_double_field_get(arg1) +} + +var _wrap_new_SimpleStruct unsafe.Pointer + +func _swig_wrap_new_SimpleStruct() (base SwigcptrSimpleStruct) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_SimpleStruct, _swig_p) + return +} + +func NewSimpleStruct() (_swig_ret SimpleStruct) { + return _swig_wrap_new_SimpleStruct() +} + +var _wrap_delete_SimpleStruct unsafe.Pointer + +func _swig_wrap_delete_SimpleStruct(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_SimpleStruct, _swig_p) + return +} + +func DeleteSimpleStruct(arg1 SimpleStruct) { + _swig_wrap_delete_SimpleStruct(arg1.Swigcptr()) +} + +type SimpleStruct interface { + Swigcptr() uintptr + SwigIsSimpleStruct() + SetDouble_field(arg2 float64) + GetDouble_field() (_swig_ret float64) +} + +var _wrap_array_c_set unsafe.Pointer + +func _swig_wrap_array_c_set(base *string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_array_c_set, _swig_p) + return +} + +func SetArray_c(arg1 *string) { + _swig_wrap_array_c_set(arg1) +} + +var _wrap_array_c_get unsafe.Pointer + +func GetArray_c() (_swig_ret *string) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_array_c_get, _swig_p) + return +} +var _wrap_array_sc_set unsafe.Pointer + +func _swig_wrap_array_sc_set(base *string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_array_sc_set, _swig_p) + return +} + +func SetArray_sc(arg1 *string) { + _swig_wrap_array_sc_set(arg1) +} + +var _wrap_array_sc_get unsafe.Pointer + +func GetArray_sc() (_swig_ret *string) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_array_sc_get, _swig_p) + return +} +var _wrap_array_uc_set unsafe.Pointer + +func _swig_wrap_array_uc_set(base *string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_array_uc_set, _swig_p) + return +} + +func SetArray_uc(arg1 *string) { + _swig_wrap_array_uc_set(arg1) +} + +var _wrap_array_uc_get unsafe.Pointer + +func GetArray_uc() (_swig_ret *string) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_array_uc_get, _swig_p) + return +} +var _wrap_array_s_set unsafe.Pointer + +func _swig_wrap_array_s_set(base **int16) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_array_s_set, _swig_p) + return +} + +func SetArray_s(arg1 **int16) { + _swig_wrap_array_s_set(arg1) +} + +var _wrap_array_s_get unsafe.Pointer + +func GetArray_s() (_swig_ret **int16) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_array_s_get, _swig_p) + return +} +var _wrap_array_us_set unsafe.Pointer + +func _swig_wrap_array_us_set(base **uint16) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_array_us_set, _swig_p) + return +} + +func SetArray_us(arg1 **uint16) { + _swig_wrap_array_us_set(arg1) +} + +var _wrap_array_us_get unsafe.Pointer + +func GetArray_us() (_swig_ret **uint16) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_array_us_get, _swig_p) + return +} +var _wrap_array_i_set unsafe.Pointer + +func _swig_wrap_array_i_set(base **int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_array_i_set, _swig_p) + return +} + +func SetArray_i(arg1 **int) { + _swig_wrap_array_i_set(arg1) +} + +var _wrap_array_i_get unsafe.Pointer + +func GetArray_i() (_swig_ret **int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_array_i_get, _swig_p) + return +} +var _wrap_array_ui_set unsafe.Pointer + +func _swig_wrap_array_ui_set(base **uint) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_array_ui_set, _swig_p) + return +} + +func SetArray_ui(arg1 **uint) { + _swig_wrap_array_ui_set(arg1) +} + +var _wrap_array_ui_get unsafe.Pointer + +func GetArray_ui() (_swig_ret **uint) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_array_ui_get, _swig_p) + return +} +var _wrap_array_l_set unsafe.Pointer + +func _swig_wrap_array_l_set(base **int64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_array_l_set, _swig_p) + return +} + +func SetArray_l(arg1 **int64) { + _swig_wrap_array_l_set(arg1) +} + +var _wrap_array_l_get unsafe.Pointer + +func GetArray_l() (_swig_ret **int64) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_array_l_get, _swig_p) + return +} +var _wrap_array_ul_set unsafe.Pointer + +func _swig_wrap_array_ul_set(base **uint64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_array_ul_set, _swig_p) + return +} + +func SetArray_ul(arg1 **uint64) { + _swig_wrap_array_ul_set(arg1) +} + +var _wrap_array_ul_get unsafe.Pointer + +func GetArray_ul() (_swig_ret **uint64) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_array_ul_get, _swig_p) + return +} +var _wrap_array_ll_set unsafe.Pointer + +func _swig_wrap_array_ll_set(base **int64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_array_ll_set, _swig_p) + return +} + +func SetArray_ll(arg1 **int64) { + _swig_wrap_array_ll_set(arg1) +} + +var _wrap_array_ll_get unsafe.Pointer + +func GetArray_ll() (_swig_ret **int64) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_array_ll_get, _swig_p) + return +} +var _wrap_array_f_set unsafe.Pointer + +func _swig_wrap_array_f_set(base **float32) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_array_f_set, _swig_p) + return +} + +func SetArray_f(arg1 **float32) { + _swig_wrap_array_f_set(arg1) +} + +var _wrap_array_f_get unsafe.Pointer + +func GetArray_f() (_swig_ret **float32) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_array_f_get, _swig_p) + return +} +var _wrap_array_d_set unsafe.Pointer + +func _swig_wrap_array_d_set(base **float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_array_d_set, _swig_p) + return +} + +func SetArray_d(arg1 **float64) { + _swig_wrap_array_d_set(arg1) +} + +var _wrap_array_d_get unsafe.Pointer + +func GetArray_d() (_swig_ret **float64) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_array_d_get, _swig_p) + return +} +var _wrap_array_struct_set unsafe.Pointer + +func _swig_wrap_array_struct_set(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_array_struct_set, _swig_p) + return +} + +func SetArray_struct(arg1 SimpleStruct) { + _swig_wrap_array_struct_set(arg1.Swigcptr()) +} + +var _wrap_array_struct_get unsafe.Pointer + +func _swig_wrap_array_struct_get() (base SwigcptrSimpleStruct) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_array_struct_get, _swig_p) + return +} + +func GetArray_struct() (_swig_ret SimpleStruct) { + return _swig_wrap_array_struct_get() +} + +var _wrap_array_structpointers_set unsafe.Pointer + +func _swig_wrap_array_structpointers_set(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_array_structpointers_set, _swig_p) + return +} + +func SetArray_structpointers(arg1 SimpleStruct) { + _swig_wrap_array_structpointers_set(arg1.Swigcptr()) +} + +var _wrap_array_structpointers_get unsafe.Pointer + +func _swig_wrap_array_structpointers_get() (base SwigcptrSimpleStruct) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_array_structpointers_get, _swig_p) + return +} + +func GetArray_structpointers() (_swig_ret SimpleStruct) { + return _swig_wrap_array_structpointers_get() +} + +var _wrap_array_ipointers_set unsafe.Pointer + +func _swig_wrap_array_ipointers_set(base ***int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_array_ipointers_set, _swig_p) + return +} + +func SetArray_ipointers(arg1 ***int) { + _swig_wrap_array_ipointers_set(arg1) +} + +var _wrap_array_ipointers_get unsafe.Pointer + +func GetArray_ipointers() (_swig_ret ***int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_array_ipointers_get, _swig_p) + return +} +var _wrap_array_enum_set unsafe.Pointer + +func _swig_wrap_array_enum_set(base **Finger) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_array_enum_set, _swig_p) + return +} + +func SetArray_enum(arg1 **Finger) { + _swig_wrap_array_enum_set(arg1) +} + +var _wrap_array_enum_get unsafe.Pointer + +func GetArray_enum() (_swig_ret **Finger) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_array_enum_get, _swig_p) + return +} +var _wrap_array_enumpointers_set unsafe.Pointer + +func _swig_wrap_array_enumpointers_set(base ***Finger) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_array_enumpointers_set, _swig_p) + return +} + +func SetArray_enumpointers(arg1 ***Finger) { + _swig_wrap_array_enumpointers_set(arg1) +} + +var _wrap_array_enumpointers_get unsafe.Pointer + +func GetArray_enumpointers() (_swig_ret ***Finger) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_array_enumpointers_get, _swig_p) + return +} +var _wrap_array_const_i_get unsafe.Pointer + +func GetArray_const_i() (_swig_ret **int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_array_const_i_get, _swig_p) + return +} +var _wrap_fn_taking_arrays unsafe.Pointer + +func _swig_wrap_fn_taking_arrays(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_fn_taking_arrays, _swig_p) + return +} + +func Fn_taking_arrays(arg1 SimpleStruct) { + _swig_wrap_fn_taking_arrays(arg1.Swigcptr()) +} + +var _wrap_get_2d_array unsafe.Pointer + +func Get_2d_array(arg1 **int, arg2 int, arg3 int) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_get_2d_array, _swig_p) + return +} + +type SwigcptrNameT_Sl_char_Sg_ uintptr +type NameT_Sl_char_Sg_ interface { + Swigcptr() uintptr; +} +func (p SwigcptrNameT_Sl_char_Sg_) Swigcptr() uintptr { + return uintptr(p) +} + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/mod_a.go b/Examples/test-suite/go/mod_a.go new file mode 100644 index 000000000..8ca8c58e5 --- /dev/null +++ b/Examples/test-suite/go/mod_a.go @@ -0,0 +1,182 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../mod_a.i + +package mod_a + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrA uintptr + +func (p SwigcptrA) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrA) SwigIsA() { +} + +var _wrap_new_A unsafe.Pointer + +func _swig_wrap_new_A() (base SwigcptrA) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_A, _swig_p) + return +} + +func NewA() (_swig_ret A) { + return _swig_wrap_new_A() +} + +var _wrap_A_GetC unsafe.Pointer + +func _swig_wrap_A_GetC(base SwigcptrA) (_ SwigcptrC) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_A_GetC, _swig_p) + return +} + +func (arg1 SwigcptrA) GetC() (_swig_ret C) { + return _swig_wrap_A_GetC(arg1) +} + +var _wrap_A_DoSomething unsafe.Pointer + +func _swig_wrap_A_DoSomething(base SwigcptrA, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_A_DoSomething, _swig_p) + return +} + +func (arg1 SwigcptrA) DoSomething(arg2 A) { + _swig_wrap_A_DoSomething(arg1, arg2.Swigcptr()) +} + +var _wrap_delete_A unsafe.Pointer + +func _swig_wrap_delete_A(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_A, _swig_p) + return +} + +func DeleteA(arg1 A) { + _swig_wrap_delete_A(arg1.Swigcptr()) +} + +type A interface { + Swigcptr() uintptr + SwigIsA() + GetC() (_swig_ret C) + DoSomething(arg2 A) +} + +type SwigcptrB uintptr + +func (p SwigcptrB) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrB) SwigIsB() { +} + +var _wrap_new_B unsafe.Pointer + +func _swig_wrap_new_B() (base SwigcptrB) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_B, _swig_p) + return +} + +func NewB() (_swig_ret B) { + return _swig_wrap_new_B() +} + +var _wrap_delete_B unsafe.Pointer + +func _swig_wrap_delete_B(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_B, _swig_p) + return +} + +func DeleteB(arg1 B) { + _swig_wrap_delete_B(arg1.Swigcptr()) +} + +var _wrap_B_GetC unsafe.Pointer + +func _swig_wrap_B_GetC(base SwigcptrB) (_ SwigcptrC) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_B_GetC, _swig_p) + return +} + +func (_swig_base SwigcptrB) GetC() (_swig_ret C) { + return _swig_wrap_B_GetC(_swig_base) +} + +var _wrap_B_DoSomething unsafe.Pointer + +func _swig_wrap_B_DoSomething(base SwigcptrB, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_B_DoSomething, _swig_p) + return +} + +func (_swig_base SwigcptrB) DoSomething(arg1 A) { + _swig_wrap_B_DoSomething(_swig_base, arg1.Swigcptr()) +} + +func (p SwigcptrB) SwigIsA() { +} + +func (p SwigcptrB) SwigGetA() A { + return SwigcptrA(p.Swigcptr()) +} + +type B interface { + Swigcptr() uintptr + SwigIsB() + GetC() (_swig_ret C) + DoSomething(arg1 A) + SwigIsA() + SwigGetA() A +} + + +type SwigcptrC uintptr +type C interface { + Swigcptr() uintptr; +} +func (p SwigcptrC) Swigcptr() uintptr { + return uintptr(p) +} + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/mod_b.go b/Examples/test-suite/go/mod_b.go new file mode 100644 index 000000000..dcd2cddf5 --- /dev/null +++ b/Examples/test-suite/go/mod_b.go @@ -0,0 +1,211 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../mod_b.i + +package mod_b + +import "unsafe" +import _ "runtime/cgo" +import "mod_a" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrC uintptr + +func (p SwigcptrC) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrC) SwigIsC() { +} + +var _wrap_new_C unsafe.Pointer + +func _swig_wrap_new_C() (base SwigcptrC) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_C, _swig_p) + return +} + +func NewC() (_swig_ret C) { + return _swig_wrap_new_C() +} + +var _wrap_delete_C unsafe.Pointer + +func _swig_wrap_delete_C(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_C, _swig_p) + return +} + +func DeleteC(arg1 C) { + _swig_wrap_delete_C(arg1.Swigcptr()) +} + +var _wrap_C_GetC unsafe.Pointer + +func _swig_wrap_C_GetC(base SwigcptrC) (_ SwigcptrC) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_C_GetC, _swig_p) + return +} + +func (_swig_base SwigcptrC) GetC() (_swig_ret C) { + return _swig_wrap_C_GetC(_swig_base) +} + +var _wrap_C_DoSomething unsafe.Pointer + +func _swig_wrap_C_DoSomething(base SwigcptrC, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_C_DoSomething, _swig_p) + return +} + +func (_swig_base SwigcptrC) DoSomething(arg1 mod_a.A) { + _swig_wrap_C_DoSomething(_swig_base, arg1.Swigcptr()) +} + +func (p SwigcptrC) SwigIsB() { +} + +func (p SwigcptrC) SwigGetB() mod_a.B { + return mod_a.SwigcptrB(p.Swigcptr()) +} + +func (p SwigcptrC) SwigIsA() { +} + +func (p SwigcptrC) SwigGetA() mod_a.A { + return mod_a.SwigcptrA(p.Swigcptr()) +} + +type C interface { + Swigcptr() uintptr + SwigIsC() + GetC() (_swig_ret C) + DoSomething(arg1 mod_a.A) + SwigIsB() + SwigGetB() mod_a.B + SwigIsA() + SwigGetA() mod_a.A +} + +type SwigcptrD uintptr + +func (p SwigcptrD) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrD) SwigIsD() { +} + +var _wrap_new_D unsafe.Pointer + +func _swig_wrap_new_D() (base SwigcptrD) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_D, _swig_p) + return +} + +func NewD() (_swig_ret D) { + return _swig_wrap_new_D() +} + +var _wrap_delete_D unsafe.Pointer + +func _swig_wrap_delete_D(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_D, _swig_p) + return +} + +func DeleteD(arg1 D) { + _swig_wrap_delete_D(arg1.Swigcptr()) +} + +var _wrap_D_GetC unsafe.Pointer + +func _swig_wrap_D_GetC(base SwigcptrD) (_ SwigcptrC) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_D_GetC, _swig_p) + return +} + +func (_swig_base SwigcptrD) GetC() (_swig_ret C) { + return _swig_wrap_D_GetC(_swig_base) +} + +var _wrap_D_DoSomething unsafe.Pointer + +func _swig_wrap_D_DoSomething(base SwigcptrD, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_D_DoSomething, _swig_p) + return +} + +func (_swig_base SwigcptrD) DoSomething(arg1 mod_a.A) { + _swig_wrap_D_DoSomething(_swig_base, arg1.Swigcptr()) +} + +func (p SwigcptrD) SwigIsC() { +} + +func (p SwigcptrD) SwigGetC() C { + return SwigcptrC(p.Swigcptr()) +} + +func (p SwigcptrD) SwigIsB() { +} + +func (p SwigcptrD) SwigGetB() mod_a.B { + return mod_a.SwigcptrB(p.Swigcptr()) +} + +func (p SwigcptrD) SwigIsA() { +} + +func (p SwigcptrD) SwigGetA() mod_a.A { + return mod_a.SwigcptrA(p.Swigcptr()) +} + +type D interface { + Swigcptr() uintptr + SwigIsD() + GetC() (_swig_ret C) + DoSomething(arg1 mod_a.A) + SwigIsC() + SwigGetC() C + SwigIsB() + SwigGetB() mod_a.B + SwigIsA() + SwigGetA() mod_a.A +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/mod_runme b/Examples/test-suite/go/mod_runme new file mode 100755 index 000000000..462d85c55 Binary files /dev/null and b/Examples/test-suite/go/mod_runme differ diff --git a/Examples/test-suite/go/multi_import_a.go b/Examples/test-suite/go/multi_import_a.go new file mode 100644 index 000000000..0de4ce7a7 --- /dev/null +++ b/Examples/test-suite/go/multi_import_a.go @@ -0,0 +1,111 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../multi_import_a.i + +package multi_import_a + +import "unsafe" +import _ "runtime/cgo" +import "multi_import_b" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrZZZ uintptr + +func (p SwigcptrZZZ) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrZZZ) SwigIsZZZ() { +} + +var _wrap_ZZZ_testz unsafe.Pointer + +func _swig_wrap_ZZZ_testz(base SwigcptrZZZ) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_ZZZ_testz, _swig_p) + return +} + +func (arg1 SwigcptrZZZ) Testz() (_swig_ret int) { + return _swig_wrap_ZZZ_testz(arg1) +} + +var _wrap_new_ZZZ unsafe.Pointer + +func _swig_wrap_new_ZZZ() (base SwigcptrZZZ) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_ZZZ, _swig_p) + return +} + +func NewZZZ() (_swig_ret ZZZ) { + return _swig_wrap_new_ZZZ() +} + +var _wrap_delete_ZZZ unsafe.Pointer + +func _swig_wrap_delete_ZZZ(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_ZZZ, _swig_p) + return +} + +func DeleteZZZ(arg1 ZZZ) { + _swig_wrap_delete_ZZZ(arg1.Swigcptr()) +} + +var _wrap_ZZZ_testx unsafe.Pointer + +func _swig_wrap_ZZZ_testx(base SwigcptrZZZ) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_ZZZ_testx, _swig_p) + return +} + +func (_swig_base SwigcptrZZZ) Testx() (_swig_ret int) { + return _swig_wrap_ZZZ_testx(_swig_base) +} + +func (p SwigcptrZZZ) SwigIsXXX() { +} + +func (p SwigcptrZZZ) SwigGetXXX() multi_import_b.XXX { + return multi_import_b.SwigcptrXXX(p.Swigcptr()) +} + +type ZZZ interface { + Swigcptr() uintptr + SwigIsZZZ() + Testz() (_swig_ret int) + Testx() (_swig_ret int) + SwigIsXXX() + SwigGetXXX() multi_import_b.XXX +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/multi_import_b.go b/Examples/test-suite/go/multi_import_b.go new file mode 100644 index 000000000..7b3f1e142 --- /dev/null +++ b/Examples/test-suite/go/multi_import_b.go @@ -0,0 +1,161 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../multi_import_b.i + +package multi_import_b + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrXXX uintptr + +func (p SwigcptrXXX) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrXXX) SwigIsXXX() { +} + +var _wrap_XXX_testx unsafe.Pointer + +func _swig_wrap_XXX_testx(base SwigcptrXXX) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_XXX_testx, _swig_p) + return +} + +func (arg1 SwigcptrXXX) Testx() (_swig_ret int) { + return _swig_wrap_XXX_testx(arg1) +} + +var _wrap_new_XXX unsafe.Pointer + +func _swig_wrap_new_XXX() (base SwigcptrXXX) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_XXX, _swig_p) + return +} + +func NewXXX() (_swig_ret XXX) { + return _swig_wrap_new_XXX() +} + +var _wrap_delete_XXX unsafe.Pointer + +func _swig_wrap_delete_XXX(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_XXX, _swig_p) + return +} + +func DeleteXXX(arg1 XXX) { + _swig_wrap_delete_XXX(arg1.Swigcptr()) +} + +type XXX interface { + Swigcptr() uintptr + SwigIsXXX() + Testx() (_swig_ret int) +} + +type SwigcptrYYY uintptr + +func (p SwigcptrYYY) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrYYY) SwigIsYYY() { +} + +var _wrap_YYY_testy unsafe.Pointer + +func _swig_wrap_YYY_testy(base SwigcptrYYY) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_YYY_testy, _swig_p) + return +} + +func (arg1 SwigcptrYYY) Testy() (_swig_ret int) { + return _swig_wrap_YYY_testy(arg1) +} + +var _wrap_new_YYY unsafe.Pointer + +func _swig_wrap_new_YYY() (base SwigcptrYYY) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_YYY, _swig_p) + return +} + +func NewYYY() (_swig_ret YYY) { + return _swig_wrap_new_YYY() +} + +var _wrap_delete_YYY unsafe.Pointer + +func _swig_wrap_delete_YYY(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_YYY, _swig_p) + return +} + +func DeleteYYY(arg1 YYY) { + _swig_wrap_delete_YYY(arg1.Swigcptr()) +} + +var _wrap_YYY_testx unsafe.Pointer + +func _swig_wrap_YYY_testx(base SwigcptrYYY) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_YYY_testx, _swig_p) + return +} + +func (_swig_base SwigcptrYYY) Testx() (_swig_ret int) { + return _swig_wrap_YYY_testx(_swig_base) +} + +func (p SwigcptrYYY) SwigIsXXX() { +} + +func (p SwigcptrYYY) SwigGetXXX() XXX { + return SwigcptrXXX(p.Swigcptr()) +} + +type YYY interface { + Swigcptr() uintptr + SwigIsYYY() + Testy() (_swig_ret int) + Testx() (_swig_ret int) + SwigIsXXX() + SwigGetXXX() XXX +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/multi_import_runme b/Examples/test-suite/go/multi_import_runme new file mode 100755 index 000000000..496623d1b Binary files /dev/null and b/Examples/test-suite/go/multi_import_runme differ diff --git a/Examples/test-suite/go/multiple_inheritance.go b/Examples/test-suite/go/multiple_inheritance.go new file mode 100644 index 000000000..aefc76ceb --- /dev/null +++ b/Examples/test-suite/go/multiple_inheritance.go @@ -0,0 +1,718 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../multiple_inheritance.i + +package multiple_inheritance + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrBar uintptr + +func (p SwigcptrBar) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrBar) SwigIsBar() { +} + +var _wrap_delete_Bar unsafe.Pointer + +func _swig_wrap_delete_Bar(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Bar, _swig_p) + return +} + +func DeleteBar(arg1 Bar) { + _swig_wrap_delete_Bar(arg1.Swigcptr()) +} + +var _wrap_Bar_bar unsafe.Pointer + +func _swig_wrap_Bar_bar(base SwigcptrBar) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Bar_bar, _swig_p) + return +} + +func (arg1 SwigcptrBar) Bar() (_swig_ret int) { + return _swig_wrap_Bar_bar(arg1) +} + +var _wrap_new_Bar unsafe.Pointer + +func _swig_wrap_new_Bar() (base SwigcptrBar) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Bar, _swig_p) + return +} + +func NewBar() (_swig_ret Bar) { + return _swig_wrap_new_Bar() +} + +type Bar interface { + Swigcptr() uintptr + SwigIsBar() + Bar() (_swig_ret int) +} + +type SwigcptrFoo uintptr + +func (p SwigcptrFoo) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrFoo) SwigIsFoo() { +} + +var _wrap_delete_Foo unsafe.Pointer + +func _swig_wrap_delete_Foo(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Foo, _swig_p) + return +} + +func DeleteFoo(arg1 Foo) { + _swig_wrap_delete_Foo(arg1.Swigcptr()) +} + +var _wrap_Foo_foo unsafe.Pointer + +func _swig_wrap_Foo_foo(base SwigcptrFoo) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_foo, _swig_p) + return +} + +func (arg1 SwigcptrFoo) Foo() (_swig_ret int) { + return _swig_wrap_Foo_foo(arg1) +} + +var _wrap_new_Foo unsafe.Pointer + +func _swig_wrap_new_Foo() (base SwigcptrFoo) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Foo, _swig_p) + return +} + +func NewFoo() (_swig_ret Foo) { + return _swig_wrap_new_Foo() +} + +type Foo interface { + Swigcptr() uintptr + SwigIsFoo() + Foo() (_swig_ret int) +} + +type SwigcptrSpamInt uintptr + +func (p SwigcptrSpamInt) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrSpamInt) SwigIsSpamInt() { +} + +var _wrap_delete_SpamInt unsafe.Pointer + +func _swig_wrap_delete_SpamInt(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_SpamInt, _swig_p) + return +} + +func DeleteSpamInt(arg1 SpamInt) { + _swig_wrap_delete_SpamInt(arg1.Swigcptr()) +} + +var _wrap_SpamInt_spam unsafe.Pointer + +func _swig_wrap_SpamInt_spam(base SwigcptrSpamInt, _ int) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_SpamInt_spam, _swig_p) + return +} + +func (arg1 SwigcptrSpamInt) Spam(arg2 int) (_swig_ret int) { + return _swig_wrap_SpamInt_spam(arg1, arg2) +} + +var _wrap_new_SpamInt unsafe.Pointer + +func _swig_wrap_new_SpamInt() (base SwigcptrSpamInt) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_SpamInt, _swig_p) + return +} + +func NewSpamInt() (_swig_ret SpamInt) { + return _swig_wrap_new_SpamInt() +} + +type SpamInt interface { + Swigcptr() uintptr + SwigIsSpamInt() + Spam(arg2 int) (_swig_ret int) +} + +type SwigcptrFooBar uintptr + +func (p SwigcptrFooBar) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrFooBar) SwigIsFooBar() { +} + +var _wrap_FooBar_fooBar unsafe.Pointer + +func _swig_wrap_FooBar_fooBar(base SwigcptrFooBar) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_FooBar_fooBar, _swig_p) + return +} + +func (arg1 SwigcptrFooBar) FooBar() (_swig_ret int) { + return _swig_wrap_FooBar_fooBar(arg1) +} + +var _wrap_new_FooBar unsafe.Pointer + +func _swig_wrap_new_FooBar() (base SwigcptrFooBar) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_FooBar, _swig_p) + return +} + +func NewFooBar() (_swig_ret FooBar) { + return _swig_wrap_new_FooBar() +} + +var _wrap_delete_FooBar unsafe.Pointer + +func _swig_wrap_delete_FooBar(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_FooBar, _swig_p) + return +} + +func DeleteFooBar(arg1 FooBar) { + _swig_wrap_delete_FooBar(arg1.Swigcptr()) +} + +var _wrap_FooBar_foo unsafe.Pointer + +func _swig_wrap_FooBar_foo(base SwigcptrFooBar) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_FooBar_foo, _swig_p) + return +} + +func (_swig_base SwigcptrFooBar) Foo() (_swig_ret int) { + return _swig_wrap_FooBar_foo(_swig_base) +} + +var _wrap_FooBar_bar unsafe.Pointer + +func _swig_wrap_FooBar_bar(base SwigcptrFooBar) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_FooBar_bar, _swig_p) + return +} + +func (_swig_base SwigcptrFooBar) Bar() (_swig_ret int) { + return _swig_wrap_FooBar_bar(_swig_base) +} + +func (p SwigcptrFooBar) SwigIsFoo() { +} + +func (p SwigcptrFooBar) SwigGetFoo() Foo { + return SwigcptrFoo(p.Swigcptr()) +} + +var _wrap_FooBar_SwigGetBar unsafe.Pointer + +func _swig_wrap_FooBar_SwigGetBar(base SwigcptrFooBar) (_ SwigcptrBar) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_FooBar_SwigGetBar, _swig_p) + return +} + +func (arg1 SwigcptrFooBar) SwigGetBar() (_swig_ret Bar) { + return _swig_wrap_FooBar_SwigGetBar(arg1) +} + +type FooBar interface { + Swigcptr() uintptr + SwigIsFooBar() + FooBar() (_swig_ret int) + Foo() (_swig_ret int) + Bar() (_swig_ret int) + SwigIsFoo() + SwigGetFoo() Foo + SwigGetBar() (_swig_ret Bar) +} + +type SwigcptrFooBarSpam uintptr + +func (p SwigcptrFooBarSpam) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrFooBarSpam) SwigIsFooBarSpam() { +} + +var _wrap_FooBarSpam_fooBarSpam unsafe.Pointer + +func _swig_wrap_FooBarSpam_fooBarSpam(base SwigcptrFooBarSpam) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_FooBarSpam_fooBarSpam, _swig_p) + return +} + +func (arg1 SwigcptrFooBarSpam) FooBarSpam() (_swig_ret int) { + return _swig_wrap_FooBarSpam_fooBarSpam(arg1) +} + +var _wrap_new_FooBarSpam unsafe.Pointer + +func _swig_wrap_new_FooBarSpam() (base SwigcptrFooBarSpam) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_FooBarSpam, _swig_p) + return +} + +func NewFooBarSpam() (_swig_ret FooBarSpam) { + return _swig_wrap_new_FooBarSpam() +} + +var _wrap_delete_FooBarSpam unsafe.Pointer + +func _swig_wrap_delete_FooBarSpam(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_FooBarSpam, _swig_p) + return +} + +func DeleteFooBarSpam(arg1 FooBarSpam) { + _swig_wrap_delete_FooBarSpam(arg1.Swigcptr()) +} + +var _wrap_FooBarSpam_foo unsafe.Pointer + +func _swig_wrap_FooBarSpam_foo(base SwigcptrFooBarSpam) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_FooBarSpam_foo, _swig_p) + return +} + +func (_swig_base SwigcptrFooBarSpam) Foo() (_swig_ret int) { + return _swig_wrap_FooBarSpam_foo(_swig_base) +} + +var _wrap_FooBarSpam_bar unsafe.Pointer + +func _swig_wrap_FooBarSpam_bar(base SwigcptrFooBarSpam) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_FooBarSpam_bar, _swig_p) + return +} + +func (_swig_base SwigcptrFooBarSpam) Bar() (_swig_ret int) { + return _swig_wrap_FooBarSpam_bar(_swig_base) +} + +var _wrap_FooBarSpam_spam unsafe.Pointer + +func _swig_wrap_FooBarSpam_spam(base SwigcptrFooBarSpam, _ int) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_FooBarSpam_spam, _swig_p) + return +} + +func (_swig_base SwigcptrFooBarSpam) Spam(arg1 int) (_swig_ret int) { + return _swig_wrap_FooBarSpam_spam(_swig_base, arg1) +} + +func (p SwigcptrFooBarSpam) SwigIsFoo() { +} + +func (p SwigcptrFooBarSpam) SwigGetFoo() Foo { + return SwigcptrFoo(p.Swigcptr()) +} + +var _wrap_FooBarSpam_SwigGetBar unsafe.Pointer + +func _swig_wrap_FooBarSpam_SwigGetBar(base SwigcptrFooBarSpam) (_ SwigcptrBar) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_FooBarSpam_SwigGetBar, _swig_p) + return +} + +func (arg1 SwigcptrFooBarSpam) SwigGetBar() (_swig_ret Bar) { + return _swig_wrap_FooBarSpam_SwigGetBar(arg1) +} + +var _wrap_FooBarSpam_SwigGetSpamInt unsafe.Pointer + +func _swig_wrap_FooBarSpam_SwigGetSpamInt(base SwigcptrFooBarSpam) (_ SwigcptrSpamInt) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_FooBarSpam_SwigGetSpamInt, _swig_p) + return +} + +func (arg1 SwigcptrFooBarSpam) SwigGetSpamInt() (_swig_ret SpamInt) { + return _swig_wrap_FooBarSpam_SwigGetSpamInt(arg1) +} + +type FooBarSpam interface { + Swigcptr() uintptr + SwigIsFooBarSpam() + FooBarSpam() (_swig_ret int) + Foo() (_swig_ret int) + Bar() (_swig_ret int) + Spam(arg1 int) (_swig_ret int) + SwigIsFoo() + SwigGetFoo() Foo + SwigGetBar() (_swig_ret Bar) + SwigGetSpamInt() (_swig_ret SpamInt) +} + +type SwigcptrIgnoreDerived1 uintptr + +func (p SwigcptrIgnoreDerived1) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrIgnoreDerived1) SwigIsIgnoreDerived1() { +} + +var _wrap_IgnoreDerived1_ignorederived1 unsafe.Pointer + +func _swig_wrap_IgnoreDerived1_ignorederived1(base SwigcptrIgnoreDerived1) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_IgnoreDerived1_ignorederived1, _swig_p) + return +} + +func (arg1 SwigcptrIgnoreDerived1) Ignorederived1() (_swig_ret int) { + return _swig_wrap_IgnoreDerived1_ignorederived1(arg1) +} + +var _wrap_new_IgnoreDerived1 unsafe.Pointer + +func _swig_wrap_new_IgnoreDerived1() (base SwigcptrIgnoreDerived1) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_IgnoreDerived1, _swig_p) + return +} + +func NewIgnoreDerived1() (_swig_ret IgnoreDerived1) { + return _swig_wrap_new_IgnoreDerived1() +} + +var _wrap_delete_IgnoreDerived1 unsafe.Pointer + +func _swig_wrap_delete_IgnoreDerived1(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_IgnoreDerived1, _swig_p) + return +} + +func DeleteIgnoreDerived1(arg1 IgnoreDerived1) { + _swig_wrap_delete_IgnoreDerived1(arg1.Swigcptr()) +} + +var _wrap_IgnoreDerived1_bar unsafe.Pointer + +func _swig_wrap_IgnoreDerived1_bar(base SwigcptrIgnoreDerived1) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_IgnoreDerived1_bar, _swig_p) + return +} + +func (_swig_base SwigcptrIgnoreDerived1) Bar() (_swig_ret int) { + return _swig_wrap_IgnoreDerived1_bar(_swig_base) +} + +var _wrap_IgnoreDerived1_SwigGetBar unsafe.Pointer + +func _swig_wrap_IgnoreDerived1_SwigGetBar(base SwigcptrIgnoreDerived1) (_ SwigcptrBar) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_IgnoreDerived1_SwigGetBar, _swig_p) + return +} + +func (arg1 SwigcptrIgnoreDerived1) SwigGetBar() (_swig_ret Bar) { + return _swig_wrap_IgnoreDerived1_SwigGetBar(arg1) +} + +type IgnoreDerived1 interface { + Swigcptr() uintptr + SwigIsIgnoreDerived1() + Ignorederived1() (_swig_ret int) + Bar() (_swig_ret int) + SwigGetBar() (_swig_ret Bar) +} + +type SwigcptrIgnoreDerived2 uintptr + +func (p SwigcptrIgnoreDerived2) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrIgnoreDerived2) SwigIsIgnoreDerived2() { +} + +var _wrap_IgnoreDerived2_ignorederived2 unsafe.Pointer + +func _swig_wrap_IgnoreDerived2_ignorederived2(base SwigcptrIgnoreDerived2) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_IgnoreDerived2_ignorederived2, _swig_p) + return +} + +func (arg1 SwigcptrIgnoreDerived2) Ignorederived2() (_swig_ret int) { + return _swig_wrap_IgnoreDerived2_ignorederived2(arg1) +} + +var _wrap_new_IgnoreDerived2 unsafe.Pointer + +func _swig_wrap_new_IgnoreDerived2() (base SwigcptrIgnoreDerived2) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_IgnoreDerived2, _swig_p) + return +} + +func NewIgnoreDerived2() (_swig_ret IgnoreDerived2) { + return _swig_wrap_new_IgnoreDerived2() +} + +var _wrap_delete_IgnoreDerived2 unsafe.Pointer + +func _swig_wrap_delete_IgnoreDerived2(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_IgnoreDerived2, _swig_p) + return +} + +func DeleteIgnoreDerived2(arg1 IgnoreDerived2) { + _swig_wrap_delete_IgnoreDerived2(arg1.Swigcptr()) +} + +var _wrap_IgnoreDerived2_bar unsafe.Pointer + +func _swig_wrap_IgnoreDerived2_bar(base SwigcptrIgnoreDerived2) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_IgnoreDerived2_bar, _swig_p) + return +} + +func (_swig_base SwigcptrIgnoreDerived2) Bar() (_swig_ret int) { + return _swig_wrap_IgnoreDerived2_bar(_swig_base) +} + +var _wrap_IgnoreDerived2_SwigGetBar unsafe.Pointer + +func _swig_wrap_IgnoreDerived2_SwigGetBar(base SwigcptrIgnoreDerived2) (_ SwigcptrBar) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_IgnoreDerived2_SwigGetBar, _swig_p) + return +} + +func (arg1 SwigcptrIgnoreDerived2) SwigGetBar() (_swig_ret Bar) { + return _swig_wrap_IgnoreDerived2_SwigGetBar(arg1) +} + +type IgnoreDerived2 interface { + Swigcptr() uintptr + SwigIsIgnoreDerived2() + Ignorederived2() (_swig_ret int) + Bar() (_swig_ret int) + SwigGetBar() (_swig_ret Bar) +} + +type SwigcptrIgnoreDerived3 uintptr + +func (p SwigcptrIgnoreDerived3) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrIgnoreDerived3) SwigIsIgnoreDerived3() { +} + +var _wrap_IgnoreDerived3_ignorederived3 unsafe.Pointer + +func _swig_wrap_IgnoreDerived3_ignorederived3(base SwigcptrIgnoreDerived3) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_IgnoreDerived3_ignorederived3, _swig_p) + return +} + +func (arg1 SwigcptrIgnoreDerived3) Ignorederived3() (_swig_ret int) { + return _swig_wrap_IgnoreDerived3_ignorederived3(arg1) +} + +var _wrap_new_IgnoreDerived3 unsafe.Pointer + +func _swig_wrap_new_IgnoreDerived3() (base SwigcptrIgnoreDerived3) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_IgnoreDerived3, _swig_p) + return +} + +func NewIgnoreDerived3() (_swig_ret IgnoreDerived3) { + return _swig_wrap_new_IgnoreDerived3() +} + +var _wrap_delete_IgnoreDerived3 unsafe.Pointer + +func _swig_wrap_delete_IgnoreDerived3(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_IgnoreDerived3, _swig_p) + return +} + +func DeleteIgnoreDerived3(arg1 IgnoreDerived3) { + _swig_wrap_delete_IgnoreDerived3(arg1.Swigcptr()) +} + +var _wrap_IgnoreDerived3_bar unsafe.Pointer + +func _swig_wrap_IgnoreDerived3_bar(base SwigcptrIgnoreDerived3) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_IgnoreDerived3_bar, _swig_p) + return +} + +func (_swig_base SwigcptrIgnoreDerived3) Bar() (_swig_ret int) { + return _swig_wrap_IgnoreDerived3_bar(_swig_base) +} + +var _wrap_IgnoreDerived3_SwigGetBar unsafe.Pointer + +func _swig_wrap_IgnoreDerived3_SwigGetBar(base SwigcptrIgnoreDerived3) (_ SwigcptrBar) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_IgnoreDerived3_SwigGetBar, _swig_p) + return +} + +func (arg1 SwigcptrIgnoreDerived3) SwigGetBar() (_swig_ret Bar) { + return _swig_wrap_IgnoreDerived3_SwigGetBar(arg1) +} + +type IgnoreDerived3 interface { + Swigcptr() uintptr + SwigIsIgnoreDerived3() + Ignorederived3() (_swig_ret int) + Bar() (_swig_ret int) + SwigGetBar() (_swig_ret Bar) +} + +type SwigcptrIgnoreDerived4 uintptr + +func (p SwigcptrIgnoreDerived4) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrIgnoreDerived4) SwigIsIgnoreDerived4() { +} + +var _wrap_IgnoreDerived4_ignorederived4 unsafe.Pointer + +func _swig_wrap_IgnoreDerived4_ignorederived4(base SwigcptrIgnoreDerived4) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_IgnoreDerived4_ignorederived4, _swig_p) + return +} + +func (arg1 SwigcptrIgnoreDerived4) Ignorederived4() (_swig_ret int) { + return _swig_wrap_IgnoreDerived4_ignorederived4(arg1) +} + +var _wrap_new_IgnoreDerived4 unsafe.Pointer + +func _swig_wrap_new_IgnoreDerived4() (base SwigcptrIgnoreDerived4) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_IgnoreDerived4, _swig_p) + return +} + +func NewIgnoreDerived4() (_swig_ret IgnoreDerived4) { + return _swig_wrap_new_IgnoreDerived4() +} + +var _wrap_delete_IgnoreDerived4 unsafe.Pointer + +func _swig_wrap_delete_IgnoreDerived4(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_IgnoreDerived4, _swig_p) + return +} + +func DeleteIgnoreDerived4(arg1 IgnoreDerived4) { + _swig_wrap_delete_IgnoreDerived4(arg1.Swigcptr()) +} + +var _wrap_IgnoreDerived4_bar unsafe.Pointer + +func _swig_wrap_IgnoreDerived4_bar(base SwigcptrIgnoreDerived4) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_IgnoreDerived4_bar, _swig_p) + return +} + +func (_swig_base SwigcptrIgnoreDerived4) Bar() (_swig_ret int) { + return _swig_wrap_IgnoreDerived4_bar(_swig_base) +} + +func (p SwigcptrIgnoreDerived4) SwigIsBar() { +} + +func (p SwigcptrIgnoreDerived4) SwigGetBar() Bar { + return SwigcptrBar(p.Swigcptr()) +} + +type IgnoreDerived4 interface { + Swigcptr() uintptr + SwigIsIgnoreDerived4() + Ignorederived4() (_swig_ret int) + Bar() (_swig_ret int) + SwigIsBar() + SwigGetBar() Bar +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/name.go b/Examples/test-suite/go/name.go new file mode 100644 index 000000000..0a65598ca --- /dev/null +++ b/Examples/test-suite/go/name.go @@ -0,0 +1,69 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../name.i + +package name + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +var _wrap_foo_2 unsafe.Pointer + +func _swig_wrap_foo_2() { + var _swig_p uintptr + _cgo_runtime_cgocall(_wrap_foo_2, _swig_p) + return +} + +func Foo_2() { + _swig_wrap_foo_2() +} + +var _wrap_bar_2_set unsafe.Pointer + +func _swig_wrap_bar_2_set(base int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_bar_2_set, _swig_p) + return +} + +func SetBar_2(arg1 int) { + _swig_wrap_bar_2_set(arg1) +} + +var _wrap_bar_2_get unsafe.Pointer + +func GetBar_2() (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_bar_2_get, _swig_p) + return +} +const Baz_2 int = 47 + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/name_cxx.go b/Examples/test-suite/go/name_cxx.go new file mode 100644 index 000000000..6c0ab893b --- /dev/null +++ b/Examples/test-suite/go/name_cxx.go @@ -0,0 +1,146 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../name_cxx.i + +package name_cxx + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +var _wrap_bar_int unsafe.Pointer + +func _swig_wrap_bar_int(base int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_bar_int, _swig_p) + return +} + +func Bar_int(arg1 int) { + _swig_wrap_bar_int(arg1) +} + +var _wrap_bar_double unsafe.Pointer + +func _swig_wrap_bar_double(base float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_bar_double, _swig_p) + return +} + +func Bar_double(arg1 float64) { + _swig_wrap_bar_double(arg1) +} + +type SwigcptrAA uintptr + +func (p SwigcptrAA) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrAA) SwigIsAA() { +} + +var _wrap_new_AA unsafe.Pointer + +func _swig_wrap_new_AA() (base SwigcptrAA) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_AA, _swig_p) + return +} + +func NewAA() (_swig_ret AA) { + return _swig_wrap_new_AA() +} + +var _wrap_delete_AA unsafe.Pointer + +func _swig_wrap_delete_AA(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_AA, _swig_p) + return +} + +func DeleteAA(arg1 AA) { + _swig_wrap_delete_AA(arg1.Swigcptr()) +} + +type AA interface { + Swigcptr() uintptr + SwigIsAA() +} + +type SwigcptrB uintptr + +func (p SwigcptrB) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrB) SwigIsB() { +} + +var _wrap_new_B unsafe.Pointer + +func _swig_wrap_new_B() (base SwigcptrB) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_B, _swig_p) + return +} + +func NewB() (_swig_ret B) { + return _swig_wrap_new_B() +} + +var _wrap_delete_B unsafe.Pointer + +func _swig_wrap_delete_B(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_B, _swig_p) + return +} + +func DeleteB(arg1 B) { + _swig_wrap_delete_B(arg1.Swigcptr()) +} + +func (p SwigcptrB) SwigIsAA() { +} + +func (p SwigcptrB) SwigGetAA() AA { + return SwigcptrAA(p.Swigcptr()) +} + +type B interface { + Swigcptr() uintptr + SwigIsB() + SwigIsAA() + SwigGetAA() AA +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/name_warnings.go b/Examples/test-suite/go/name_warnings.go new file mode 100644 index 000000000..ceb55ece7 --- /dev/null +++ b/Examples/test-suite/go/name_warnings.go @@ -0,0 +1,169 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../name_warnings.i + +package name_warnings + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrA uintptr + +func (p SwigcptrA) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrA) SwigIsA() { +} + +var _wrap_A_clone unsafe.Pointer + +func _swig_wrap_A_clone(base SwigcptrA, _ int) (_ SwigcptrA) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_A_clone, _swig_p) + return +} + +func (arg1 SwigcptrA) Clone(arg2 int) (_swig_ret A) { + return _swig_wrap_A_clone(arg1, arg2) +} + +var _wrap_delete_A unsafe.Pointer + +func _swig_wrap_delete_A(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_A, _swig_p) + return +} + +func DeleteA(arg1 A) { + _swig_wrap_delete_A(arg1.Swigcptr()) +} + +var _wrap_new_A unsafe.Pointer + +func _swig_wrap_new_A() (base SwigcptrA) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_A, _swig_p) + return +} + +func NewA() (_swig_ret A) { + return _swig_wrap_new_A() +} + +type A interface { + Swigcptr() uintptr + SwigIsA() + Clone(arg2 int) (_swig_ret A) +} + +type SwigcptrB uintptr + +func (p SwigcptrB) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrB) SwigIsB() { +} + +var _wrap_new_B unsafe.Pointer + +func _swig_wrap_new_B() (base SwigcptrB) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_B, _swig_p) + return +} + +func NewB() (_swig_ret B) { + return _swig_wrap_new_B() +} + +var _wrap_delete_B unsafe.Pointer + +func _swig_wrap_delete_B(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_B, _swig_p) + return +} + +func DeleteB(arg1 B) { + _swig_wrap_delete_B(arg1.Swigcptr()) +} + +var _wrap_B_clone unsafe.Pointer + +func _swig_wrap_B_clone(base SwigcptrB, _ int) (_ SwigcptrA) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_B_clone, _swig_p) + return +} + +func (_swig_base SwigcptrB) Clone(arg1 int) (_swig_ret A) { + return _swig_wrap_B_clone(_swig_base, arg1) +} + +func (p SwigcptrB) SwigIsA() { +} + +func (p SwigcptrB) SwigGetA() A { + return SwigcptrA(p.Swigcptr()) +} + +type B interface { + Swigcptr() uintptr + SwigIsB() + Clone(arg1 int) (_swig_ret A) + SwigIsA() + SwigGetA() A +} + +var _wrap_max_i unsafe.Pointer + +func Max_i(arg1 int, arg2 int) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_max_i, _swig_p) + return +} +var _wrap_foo unsafe.Pointer + +func Foo(arg1 float64, arg2 float64) (_swig_ret float64) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_foo, _swig_p) + return +} +var _wrap_bar unsafe.Pointer + +func Bar(arg1 float64, arg2 bool) (_swig_ret float64) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_bar, _swig_p) + return +} + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/namespace_class.go b/Examples/test-suite/go/namespace_class.go new file mode 100644 index 000000000..7629f12e8 --- /dev/null +++ b/Examples/test-suite/go/namespace_class.go @@ -0,0 +1,1280 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../namespace_class.i + +package namespace_class + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +var _wrap_FooBarInt unsafe.Pointer + +func _swig_wrap_FooBarInt(base int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_FooBarInt, _swig_p) + return +} + +func FooBarInt(arg1 int) { + _swig_wrap_FooBarInt(arg1) +} + +var _wrap_BarFooInt unsafe.Pointer + +func _swig_wrap_BarFooInt(base int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_BarFooInt, _swig_p) + return +} + +func BarFooInt(arg1 int) { + _swig_wrap_BarFooInt(arg1) +} + +type TestHello int +var _wrap_Hi unsafe.Pointer + +func _swig_getHi() (_swig_ret TestHello) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_Hi, _swig_p) + return +} +var Hi TestHello = _swig_getHi() +type SwigcptrBar uintptr + +func (p SwigcptrBar) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrBar) SwigIsBar() { +} + +var _wrap_Bar_foo unsafe.Pointer + +func _swig_wrap_Bar_foo(base SwigcptrBar, _ TestHello) (_ TestHello) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Bar_foo, _swig_p) + return +} + +func (arg1 SwigcptrBar) Foo(arg2 TestHello) (_swig_ret TestHello) { + return _swig_wrap_Bar_foo(arg1, arg2) +} + +var _wrap_new_Bar unsafe.Pointer + +func _swig_wrap_new_Bar() (base SwigcptrBar) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Bar, _swig_p) + return +} + +func NewBar() (_swig_ret Bar) { + return _swig_wrap_new_Bar() +} + +var _wrap_delete_Bar unsafe.Pointer + +func _swig_wrap_delete_Bar(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Bar, _swig_p) + return +} + +func DeleteBar(arg1 Bar) { + _swig_wrap_delete_Bar(arg1.Swigcptr()) +} + +type Bar interface { + Swigcptr() uintptr + SwigIsBar() + Foo(arg2 TestHello) (_swig_ret TestHello) +} + +var _wrap_a_set unsafe.Pointer + +func _swig_wrap_a_set(base int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_a_set, _swig_p) + return +} + +func SetA(arg1 int) { + _swig_wrap_a_set(arg1) +} + +var _wrap_a_get unsafe.Pointer + +func GetA() (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_a_get, _swig_p) + return +} +type SwigcptrFoo uintptr + +func (p SwigcptrFoo) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrFoo) SwigIsFoo() { +} + +var _wrap_Foo_bar unsafe.Pointer + +func _swig_wrap_Foo_bar(base SwigcptrFoo, _ TestHello) (_ TestHello) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_bar, _swig_p) + return +} + +func (arg1 SwigcptrFoo) Bar(arg2 TestHello) (_swig_ret TestHello) { + return _swig_wrap_Foo_bar(arg1, arg2) +} + +var _wrap_new_Foo unsafe.Pointer + +func _swig_wrap_new_Foo() (base SwigcptrFoo) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Foo, _swig_p) + return +} + +func NewFoo() (_swig_ret Foo) { + return _swig_wrap_new_Foo() +} + +var _wrap_delete_Foo unsafe.Pointer + +func _swig_wrap_delete_Foo(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Foo, _swig_p) + return +} + +func DeleteFoo(arg1 Foo) { + _swig_wrap_delete_Foo(arg1.Swigcptr()) +} + +var _wrap_Foo_foo unsafe.Pointer + +func _swig_wrap_Foo_foo(base SwigcptrFoo, _ TestHello) (_ TestHello) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_foo, _swig_p) + return +} + +func (_swig_base SwigcptrFoo) Foo(arg1 TestHello) (_swig_ret TestHello) { + return _swig_wrap_Foo_foo(_swig_base, arg1) +} + +func (p SwigcptrFoo) SwigIsBar() { +} + +func (p SwigcptrFoo) SwigGetBar() Bar { + return SwigcptrBar(p.Swigcptr()) +} + +type Foo interface { + Swigcptr() uintptr + SwigIsFoo() + Bar(arg2 TestHello) (_swig_ret TestHello) + Foo(arg1 TestHello) (_swig_ret TestHello) + SwigIsBar() + SwigGetBar() Bar +} + +type SwigcptrTest uintptr + +func (p SwigcptrTest) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrTest) SwigIsTest() { +} + +var _wrap_Test_foo unsafe.Pointer + +func _swig_wrap_Test_foo(base SwigcptrTest, _ TestHello) (_ TestHello) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Test_foo, _swig_p) + return +} + +func (arg1 SwigcptrTest) Foo(arg2 TestHello) (_swig_ret TestHello) { + return _swig_wrap_Test_foo(arg1, arg2) +} + +var _wrap_new_Test unsafe.Pointer + +func _swig_wrap_new_Test() (base SwigcptrTest) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Test, _swig_p) + return +} + +func NewTest() (_swig_ret Test) { + return _swig_wrap_new_Test() +} + +var _wrap_delete_Test unsafe.Pointer + +func _swig_wrap_delete_Test(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Test, _swig_p) + return +} + +func DeleteTest(arg1 Test) { + _swig_wrap_delete_Test(arg1.Swigcptr()) +} + +type Test interface { + Swigcptr() uintptr + SwigIsTest() + Foo(arg2 TestHello) (_swig_ret TestHello) +} + +type SwigcptrBor uintptr + +func (p SwigcptrBor) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrBor) SwigIsBor() { +} + +var _wrap_Bor_foo unsafe.Pointer + +func _swig_wrap_Bor_foo(base SwigcptrBor, _ TestHello) (_ TestHello) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Bor_foo, _swig_p) + return +} + +func (arg1 SwigcptrBor) Foo(arg2 TestHello) (_swig_ret TestHello) { + return _swig_wrap_Bor_foo(arg1, arg2) +} + +var _wrap_new_Bor unsafe.Pointer + +func _swig_wrap_new_Bor() (base SwigcptrBor) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Bor, _swig_p) + return +} + +func NewBor() (_swig_ret Bor) { + return _swig_wrap_new_Bor() +} + +var _wrap_delete_Bor unsafe.Pointer + +func _swig_wrap_delete_Bor(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Bor, _swig_p) + return +} + +func DeleteBor(arg1 Bor) { + _swig_wrap_delete_Bor(arg1.Swigcptr()) +} + +type Bor interface { + Swigcptr() uintptr + SwigIsBor() + Foo(arg2 TestHello) (_swig_ret TestHello) +} + +type SwigcptrFoobar uintptr + +func (p SwigcptrFoobar) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrFoobar) SwigIsFoobar() { +} + +var _wrap_Foobar_bar unsafe.Pointer + +func _swig_wrap_Foobar_bar(base SwigcptrFoobar, _ TestHello) (_ TestHello) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foobar_bar, _swig_p) + return +} + +func (arg1 SwigcptrFoobar) Bar(arg2 TestHello) (_swig_ret TestHello) { + return _swig_wrap_Foobar_bar(arg1, arg2) +} + +var _wrap_new_Foobar unsafe.Pointer + +func _swig_wrap_new_Foobar() (base SwigcptrFoobar) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Foobar, _swig_p) + return +} + +func NewFoobar() (_swig_ret Foobar) { + return _swig_wrap_new_Foobar() +} + +var _wrap_delete_Foobar unsafe.Pointer + +func _swig_wrap_delete_Foobar(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Foobar, _swig_p) + return +} + +func DeleteFoobar(arg1 Foobar) { + _swig_wrap_delete_Foobar(arg1.Swigcptr()) +} + +var _wrap_Foobar_foo unsafe.Pointer + +func _swig_wrap_Foobar_foo(base SwigcptrFoobar, _ TestHello) (_ TestHello) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foobar_foo, _swig_p) + return +} + +func (_swig_base SwigcptrFoobar) Foo(arg1 TestHello) (_swig_ret TestHello) { + return _swig_wrap_Foobar_foo(_swig_base, arg1) +} + +func (p SwigcptrFoobar) SwigIsBar() { +} + +func (p SwigcptrFoobar) SwigGetBar() Bar { + return SwigcptrBar(p.Swigcptr()) +} + +type Foobar interface { + Swigcptr() uintptr + SwigIsFoobar() + Bar(arg2 TestHello) (_swig_ret TestHello) + Foo(arg1 TestHello) (_swig_ret TestHello) + SwigIsBar() + SwigGetBar() Bar +} + +type SwigcptrFooT_i uintptr + +func (p SwigcptrFooT_i) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrFooT_i) SwigIsFooT_i() { +} + +var _wrap_FooT_i_quack unsafe.Pointer + +func _swig_wrap_FooT_i_quack(base SwigcptrFooT_i, _ int) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_FooT_i_quack, _swig_p) + return +} + +func (arg1 SwigcptrFooT_i) Quack(arg2 int) (_swig_ret int) { + return _swig_wrap_FooT_i_quack(arg1, arg2) +} + +var _wrap_new_FooT_i unsafe.Pointer + +func _swig_wrap_new_FooT_i() (base SwigcptrFooT_i) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_FooT_i, _swig_p) + return +} + +func NewFooT_i() (_swig_ret FooT_i) { + return _swig_wrap_new_FooT_i() +} + +var _wrap_delete_FooT_i unsafe.Pointer + +func _swig_wrap_delete_FooT_i(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_FooT_i, _swig_p) + return +} + +func DeleteFooT_i(arg1 FooT_i) { + _swig_wrap_delete_FooT_i(arg1.Swigcptr()) +} + +type FooT_i interface { + Swigcptr() uintptr + SwigIsFooT_i() + Quack(arg2 int) (_swig_ret int) +} + +type SwigcptrFooT_H uintptr + +func (p SwigcptrFooT_H) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrFooT_H) SwigIsFooT_H() { +} + +var _wrap_FooT_H_foo unsafe.Pointer + +func _swig_wrap_FooT_H_foo(base SwigcptrFooT_H, _ TestHello) (_ TestHello) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_FooT_H_foo, _swig_p) + return +} + +func (arg1 SwigcptrFooT_H) Foo(arg2 TestHello) (_swig_ret TestHello) { + return _swig_wrap_FooT_H_foo(arg1, arg2) +} + +var _wrap_FooT_H_bar unsafe.Pointer + +func _swig_wrap_FooT_H_bar(base SwigcptrFooT_H, _ TestHello) (_ TestHello) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_FooT_H_bar, _swig_p) + return +} + +func (arg1 SwigcptrFooT_H) Bar(arg2 TestHello) (_swig_ret TestHello) { + return _swig_wrap_FooT_H_bar(arg1, arg2) +} + +var _wrap_new_FooT_H unsafe.Pointer + +func _swig_wrap_new_FooT_H() (base SwigcptrFooT_H) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_FooT_H, _swig_p) + return +} + +func NewFooT_H() (_swig_ret FooT_H) { + return _swig_wrap_new_FooT_H() +} + +var _wrap_delete_FooT_H unsafe.Pointer + +func _swig_wrap_delete_FooT_H(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_FooT_H, _swig_p) + return +} + +func DeleteFooT_H(arg1 FooT_H) { + _swig_wrap_delete_FooT_H(arg1.Swigcptr()) +} + +type FooT_H interface { + Swigcptr() uintptr + SwigIsFooT_H() + Foo(arg2 TestHello) (_swig_ret TestHello) + Bar(arg2 TestHello) (_swig_ret TestHello) +} + +type SwigcptrFooT_d uintptr + +func (p SwigcptrFooT_d) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrFooT_d) SwigIsFooT_d() { +} + +var _wrap_FooT_d_moo unsafe.Pointer + +func _swig_wrap_FooT_d_moo(base SwigcptrFooT_d, _ float64) (_ float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_FooT_d_moo, _swig_p) + return +} + +func (arg1 SwigcptrFooT_d) Moo(arg2 float64) (_swig_ret float64) { + return _swig_wrap_FooT_d_moo(arg1, arg2) +} + +var _wrap_new_FooT_d unsafe.Pointer + +func _swig_wrap_new_FooT_d() (base SwigcptrFooT_d) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_FooT_d, _swig_p) + return +} + +func NewFooT_d() (_swig_ret FooT_d) { + return _swig_wrap_new_FooT_d() +} + +var _wrap_delete_FooT_d unsafe.Pointer + +func _swig_wrap_delete_FooT_d(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_FooT_d, _swig_p) + return +} + +func DeleteFooT_d(arg1 FooT_d) { + _swig_wrap_delete_FooT_d(arg1.Swigcptr()) +} + +type FooT_d interface { + Swigcptr() uintptr + SwigIsFooT_d() + Moo(arg2 float64) (_swig_ret float64) +} + +type SwigcptrBarT_H uintptr + +func (p SwigcptrBarT_H) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrBarT_H) SwigIsBarT_H() { +} + +var _wrap_new_BarT_H unsafe.Pointer + +func _swig_wrap_new_BarT_H() (base SwigcptrBarT_H) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_BarT_H, _swig_p) + return +} + +func NewBarT_H() (_swig_ret BarT_H) { + return _swig_wrap_new_BarT_H() +} + +var _wrap_delete_BarT_H unsafe.Pointer + +func _swig_wrap_delete_BarT_H(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_BarT_H, _swig_p) + return +} + +func DeleteBarT_H(arg1 BarT_H) { + _swig_wrap_delete_BarT_H(arg1.Swigcptr()) +} + +type BarT_H interface { + Swigcptr() uintptr + SwigIsBarT_H() +} + +type SwigcptrPoo_i uintptr + +func (p SwigcptrPoo_i) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrPoo_i) SwigIsPoo_i() { +} + +var _wrap_new_Poo_i unsafe.Pointer + +func _swig_wrap_new_Poo_i() (base SwigcptrPoo_i) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Poo_i, _swig_p) + return +} + +func NewPoo_i() (_swig_ret Poo_i) { + return _swig_wrap_new_Poo_i() +} + +var _wrap_delete_Poo_i unsafe.Pointer + +func _swig_wrap_delete_Poo_i(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Poo_i, _swig_p) + return +} + +func DeletePoo_i(arg1 Poo_i) { + _swig_wrap_delete_Poo_i(arg1.Swigcptr()) +} + +type Poo_i interface { + Swigcptr() uintptr + SwigIsPoo_i() +} + +type SwigcptrBooT_H uintptr + +func (p SwigcptrBooT_H) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrBooT_H) SwigIsBooT_H() { +} + +var _wrap_new_BooT_H unsafe.Pointer + +func _swig_wrap_new_BooT_H() (base SwigcptrBooT_H) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_BooT_H, _swig_p) + return +} + +func NewBooT_H() (_swig_ret BooT_H) { + return _swig_wrap_new_BooT_H() +} + +var _wrap_delete_BooT_H unsafe.Pointer + +func _swig_wrap_delete_BooT_H(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_BooT_H, _swig_p) + return +} + +func DeleteBooT_H(arg1 BooT_H) { + _swig_wrap_delete_BooT_H(arg1.Swigcptr()) +} + +type BooT_H interface { + Swigcptr() uintptr + SwigIsBooT_H() +} + +type SwigcptrBooT_i uintptr + +func (p SwigcptrBooT_i) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrBooT_i) SwigIsBooT_i() { +} + +var _wrap_new_BooT_i unsafe.Pointer + +func _swig_wrap_new_BooT_i() (base SwigcptrBooT_i) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_BooT_i, _swig_p) + return +} + +func NewBooT_i() (_swig_ret BooT_i) { + return _swig_wrap_new_BooT_i() +} + +var _wrap_delete_BooT_i unsafe.Pointer + +func _swig_wrap_delete_BooT_i(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_BooT_i, _swig_p) + return +} + +func DeleteBooT_i(arg1 BooT_i) { + _swig_wrap_delete_BooT_i(arg1.Swigcptr()) +} + +type BooT_i interface { + Swigcptr() uintptr + SwigIsBooT_i() +} + +type SwigcptrEulerT3D uintptr + +func (p SwigcptrEulerT3D) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrEulerT3D) SwigIsEulerT3D() { +} + +var _wrap_EulerT3D_hello unsafe.Pointer + +func _swig_wrap_EulerT3D_hello() { + var _swig_p uintptr + _cgo_runtime_cgocall(_wrap_EulerT3D_hello, _swig_p) + return +} + +func EulerT3DHello() { + _swig_wrap_EulerT3D_hello() +} + +var _wrap_EulerT3D_toFrame unsafe.Pointer + +func _swig_wrap_EulerT3D_toFrame(base int, _ int, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_EulerT3D_toFrame, _swig_p) + return +} + +func EulerT3DToFrame(arg1 int, arg2 int, arg3 int) { + _swig_wrap_EulerT3D_toFrame(arg1, arg2, arg3) +} + +var _wrap_EulerT3D_callint unsafe.Pointer + +func _swig_wrap_EulerT3D_callint(base SwigcptrEulerT3D, _ *int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_EulerT3D_callint, _swig_p) + return +} + +func (arg1 SwigcptrEulerT3D) Callint(arg2 *int) { + _swig_wrap_EulerT3D_callint(arg1, arg2) +} + +var _wrap_EulerT3D_lessint unsafe.Pointer + +func _swig_wrap_EulerT3D_lessint(base SwigcptrEulerT3D, _ *int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_EulerT3D_lessint, _swig_p) + return +} + +func (arg1 SwigcptrEulerT3D) Lessint(arg2 *int) { + _swig_wrap_EulerT3D_lessint(arg1, arg2) +} + +var _wrap_EulerT3D_callfooi unsafe.Pointer + +func _swig_wrap_EulerT3D_callfooi(base SwigcptrEulerT3D, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_EulerT3D_callfooi, _swig_p) + return +} + +func (arg1 SwigcptrEulerT3D) Callfooi(arg2 FooT_i) { + _swig_wrap_EulerT3D_callfooi(arg1, arg2.Swigcptr()) +} + +var _wrap_EulerT3D_lessfooi unsafe.Pointer + +func _swig_wrap_EulerT3D_lessfooi(base SwigcptrEulerT3D, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_EulerT3D_lessfooi, _swig_p) + return +} + +func (arg1 SwigcptrEulerT3D) Lessfooi(arg2 FooT_i) { + _swig_wrap_EulerT3D_lessfooi(arg1, arg2.Swigcptr()) +} + +var _wrap_new_EulerT3D unsafe.Pointer + +func _swig_wrap_new_EulerT3D() (base SwigcptrEulerT3D) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_EulerT3D, _swig_p) + return +} + +func NewEulerT3D() (_swig_ret EulerT3D) { + return _swig_wrap_new_EulerT3D() +} + +var _wrap_delete_EulerT3D unsafe.Pointer + +func _swig_wrap_delete_EulerT3D(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_EulerT3D, _swig_p) + return +} + +func DeleteEulerT3D(arg1 EulerT3D) { + _swig_wrap_delete_EulerT3D(arg1.Swigcptr()) +} + +type EulerT3D interface { + Swigcptr() uintptr + SwigIsEulerT3D() + Callint(arg2 *int) + Lessint(arg2 *int) + Callfooi(arg2 FooT_i) + Lessfooi(arg2 FooT_i) +} + +type SwigcptrAla uintptr + +func (p SwigcptrAla) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrAla) SwigIsAla() { +} + +var _wrap_new_Ala unsafe.Pointer + +func _swig_wrap_new_Ala() (base SwigcptrAla) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Ala, _swig_p) + return +} + +func NewAla() (_swig_ret Ala) { + return _swig_wrap_new_Ala() +} + +var _wrap_Ala_hi unsafe.Pointer + +func _swig_wrap_Ala_hi() { + var _swig_p uintptr + _cgo_runtime_cgocall(_wrap_Ala_hi, _swig_p) + return +} + +func AlaHi() { + _swig_wrap_Ala_hi() +} + +var _wrap_delete_Ala unsafe.Pointer + +func _swig_wrap_delete_Ala(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Ala, _swig_p) + return +} + +func DeleteAla(arg1 Ala) { + _swig_wrap_delete_Ala(arg1.Swigcptr()) +} + +type Ala interface { + Swigcptr() uintptr + SwigIsAla() +} + +type SwigcptrFile uintptr + +func (p SwigcptrFile) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrFile) SwigIsFile() { +} + +var _wrap_new_File unsafe.Pointer + +func _swig_wrap_new_File() (base SwigcptrFile) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_File, _swig_p) + return +} + +func NewFile() (_swig_ret File) { + return _swig_wrap_new_File() +} + +var _wrap_delete_File unsafe.Pointer + +func _swig_wrap_delete_File(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_File, _swig_p) + return +} + +func DeleteFile(arg1 File) { + _swig_wrap_delete_File(arg1.Swigcptr()) +} + +type File interface { + Swigcptr() uintptr + SwigIsFile() +} + +type SwigcptrAudioProperties uintptr + +func (p SwigcptrAudioProperties) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrAudioProperties) SwigIsAudioProperties() { +} + +var _wrap_new_AudioProperties unsafe.Pointer + +func _swig_wrap_new_AudioProperties() (base SwigcptrAudioProperties) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_AudioProperties, _swig_p) + return +} + +func NewAudioProperties() (_swig_ret AudioProperties) { + return _swig_wrap_new_AudioProperties() +} + +var _wrap_delete_AudioProperties unsafe.Pointer + +func _swig_wrap_delete_AudioProperties(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_AudioProperties, _swig_p) + return +} + +func DeleteAudioProperties(arg1 AudioProperties) { + _swig_wrap_delete_AudioProperties(arg1.Swigcptr()) +} + +type AudioProperties interface { + Swigcptr() uintptr + SwigIsAudioProperties() +} + +type SwigcptrAudioPropertiesFile uintptr + +func (p SwigcptrAudioPropertiesFile) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrAudioPropertiesFile) SwigIsAudioPropertiesFile() { +} + +var _wrap_new_AudioPropertiesFile unsafe.Pointer + +func _swig_wrap_new_AudioPropertiesFile() (base SwigcptrAudioPropertiesFile) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_AudioPropertiesFile, _swig_p) + return +} + +func NewAudioPropertiesFile() (_swig_ret AudioPropertiesFile) { + return _swig_wrap_new_AudioPropertiesFile() +} + +var _wrap_delete_AudioPropertiesFile unsafe.Pointer + +func _swig_wrap_delete_AudioPropertiesFile(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_AudioPropertiesFile, _swig_p) + return +} + +func DeleteAudioPropertiesFile(arg1 AudioPropertiesFile) { + _swig_wrap_delete_AudioPropertiesFile(arg1.Swigcptr()) +} + +type AudioPropertiesFile interface { + Swigcptr() uintptr + SwigIsAudioPropertiesFile() +} + +type SwigcptrProperties uintptr + +func (p SwigcptrProperties) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrProperties) SwigIsProperties() { +} + +var _wrap_new_Properties unsafe.Pointer + +func _swig_wrap_new_Properties(base uintptr) (_ SwigcptrProperties) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Properties, _swig_p) + return +} + +func NewProperties(arg1 FLACFile) (_swig_ret Properties) { + return _swig_wrap_new_Properties(arg1.Swigcptr()) +} + +var _wrap_delete_Properties unsafe.Pointer + +func _swig_wrap_delete_Properties(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Properties, _swig_p) + return +} + +func DeleteProperties(arg1 Properties) { + _swig_wrap_delete_Properties(arg1.Swigcptr()) +} + +func (p SwigcptrProperties) SwigIsAudioProperties() { +} + +func (p SwigcptrProperties) SwigGetAudioProperties() AudioProperties { + return SwigcptrAudioProperties(p.Swigcptr()) +} + +type Properties interface { + Swigcptr() uintptr + SwigIsProperties() + SwigIsAudioProperties() + SwigGetAudioProperties() AudioProperties +} + +type SwigcptrPropertiesFile uintptr + +func (p SwigcptrPropertiesFile) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrPropertiesFile) SwigIsPropertiesFile() { +} + +var _wrap_new_PropertiesFile__SWIG_0 unsafe.Pointer + +func _swig_wrap_new_PropertiesFile__SWIG_0(base uintptr) (_ SwigcptrPropertiesFile) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_PropertiesFile__SWIG_0, _swig_p) + return +} + +func NewPropertiesFile__SWIG_0(arg1 File) (_swig_ret PropertiesFile) { + return _swig_wrap_new_PropertiesFile__SWIG_0(arg1.Swigcptr()) +} + +var _wrap_new_PropertiesFile__SWIG_1 unsafe.Pointer + +func _swig_wrap_new_PropertiesFile__SWIG_1() (base SwigcptrPropertiesFile) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_PropertiesFile__SWIG_1, _swig_p) + return +} + +func NewPropertiesFile__SWIG_1() (_swig_ret PropertiesFile) { + return _swig_wrap_new_PropertiesFile__SWIG_1() +} + +func NewPropertiesFile(a ...interface{}) PropertiesFile { + argc := len(a) + if argc == 0 { + return NewPropertiesFile__SWIG_1() + } + if argc == 1 { + return NewPropertiesFile__SWIG_0(a[0].(File)) + } + panic("No match for overloaded function call") +} + +var _wrap_delete_PropertiesFile unsafe.Pointer + +func _swig_wrap_delete_PropertiesFile(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_PropertiesFile, _swig_p) + return +} + +func DeletePropertiesFile(arg1 PropertiesFile) { + _swig_wrap_delete_PropertiesFile(arg1.Swigcptr()) +} + +func (p SwigcptrPropertiesFile) SwigIsAudioPropertiesFile() { +} + +func (p SwigcptrPropertiesFile) SwigGetAudioPropertiesFile() AudioPropertiesFile { + return SwigcptrAudioPropertiesFile(p.Swigcptr()) +} + +type PropertiesFile interface { + Swigcptr() uintptr + SwigIsPropertiesFile() + SwigIsAudioPropertiesFile() + SwigGetAudioPropertiesFile() AudioPropertiesFile +} + +type SwigcptrPropertiesFree uintptr + +func (p SwigcptrPropertiesFree) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrPropertiesFree) SwigIsPropertiesFree() { +} + +var _wrap_new_PropertiesFree unsafe.Pointer + +func _swig_wrap_new_PropertiesFree(base uintptr) (_ SwigcptrPropertiesFree) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_PropertiesFree, _swig_p) + return +} + +func NewPropertiesFree(arg1 FLACFile) (_swig_ret PropertiesFree) { + return _swig_wrap_new_PropertiesFree(arg1.Swigcptr()) +} + +var _wrap_delete_PropertiesFree unsafe.Pointer + +func _swig_wrap_delete_PropertiesFree(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_PropertiesFree, _swig_p) + return +} + +func DeletePropertiesFree(arg1 PropertiesFree) { + _swig_wrap_delete_PropertiesFree(arg1.Swigcptr()) +} + +func (p SwigcptrPropertiesFree) SwigIsAudioProperties() { +} + +func (p SwigcptrPropertiesFree) SwigGetAudioProperties() AudioProperties { + return SwigcptrAudioProperties(p.Swigcptr()) +} + +type PropertiesFree interface { + Swigcptr() uintptr + SwigIsPropertiesFree() + SwigIsAudioProperties() + SwigGetAudioProperties() AudioProperties +} + +type SwigcptrFooFilePrivate uintptr + +func (p SwigcptrFooFilePrivate) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrFooFilePrivate) SwigIsFooFilePrivate() { +} + +var _wrap_new_FooFilePrivate unsafe.Pointer + +func _swig_wrap_new_FooFilePrivate(base uintptr) (_ SwigcptrFooFilePrivate) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_FooFilePrivate, _swig_p) + return +} + +func NewFooFilePrivate(arg1 File) (_swig_ret FooFilePrivate) { + return _swig_wrap_new_FooFilePrivate(arg1.Swigcptr()) +} + +var _wrap_delete_FooFilePrivate unsafe.Pointer + +func _swig_wrap_delete_FooFilePrivate(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_FooFilePrivate, _swig_p) + return +} + +func DeleteFooFilePrivate(arg1 FooFilePrivate) { + _swig_wrap_delete_FooFilePrivate(arg1.Swigcptr()) +} + +type FooFilePrivate interface { + Swigcptr() uintptr + SwigIsFooFilePrivate() +} + +type SwigcptrFooFile uintptr + +func (p SwigcptrFooFile) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrFooFile) SwigIsFooFile() { +} + +var _wrap_new_FooFile unsafe.Pointer + +func _swig_wrap_new_FooFile(base uintptr) (_ SwigcptrFooFile) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_FooFile, _swig_p) + return +} + +func NewFooFile(arg1 File) (_swig_ret FooFile) { + return _swig_wrap_new_FooFile(arg1.Swigcptr()) +} + +var _wrap_delete_FooFile unsafe.Pointer + +func _swig_wrap_delete_FooFile(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_FooFile, _swig_p) + return +} + +func DeleteFooFile(arg1 FooFile) { + _swig_wrap_delete_FooFile(arg1.Swigcptr()) +} + +func (p SwigcptrFooFile) SwigIsPropertiesFile() { +} + +func (p SwigcptrFooFile) SwigGetPropertiesFile() PropertiesFile { + return SwigcptrPropertiesFile(p.Swigcptr()) +} + +func (p SwigcptrFooFile) SwigIsAudioPropertiesFile() { +} + +func (p SwigcptrFooFile) SwigGetAudioPropertiesFile() AudioPropertiesFile { + return SwigcptrAudioPropertiesFile(p.Swigcptr()) +} + +type FooFile interface { + Swigcptr() uintptr + SwigIsFooFile() + SwigIsPropertiesFile() + SwigGetPropertiesFile() PropertiesFile + SwigIsAudioPropertiesFile() + SwigGetAudioPropertiesFile() AudioPropertiesFile +} + +type SwigcptrFLACFile uintptr + +func (p SwigcptrFLACFile) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrFLACFile) SwigIsFLACFile() { +} + +var _wrap_new_FLACFile unsafe.Pointer + +func _swig_wrap_new_FLACFile() (base SwigcptrFLACFile) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_FLACFile, _swig_p) + return +} + +func NewFLACFile() (_swig_ret FLACFile) { + return _swig_wrap_new_FLACFile() +} + +var _wrap_delete_FLACFile unsafe.Pointer + +func _swig_wrap_delete_FLACFile(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_FLACFile, _swig_p) + return +} + +func DeleteFLACFile(arg1 FLACFile) { + _swig_wrap_delete_FLACFile(arg1.Swigcptr()) +} + +type FLACFile interface { + Swigcptr() uintptr + SwigIsFLACFile() +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/namespace_class_runme b/Examples/test-suite/go/namespace_class_runme new file mode 100755 index 000000000..9f4c939b4 Binary files /dev/null and b/Examples/test-suite/go/namespace_class_runme differ diff --git a/Examples/test-suite/go/namespace_enum.go b/Examples/test-suite/go/namespace_enum.go new file mode 100644 index 000000000..a2ef92b83 --- /dev/null +++ b/Examples/test-suite/go/namespace_enum.go @@ -0,0 +1,117 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../namespace_enum.i + +package namespace_enum + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type FooSwig int +var _wrap_LAGER unsafe.Pointer + +func _swig_getLAGER() (_swig_ret FooSwig) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_LAGER, _swig_p) + return +} +var LAGER FooSwig = _swig_getLAGER() +var _wrap_STOUT unsafe.Pointer + +func _swig_getSTOUT() (_swig_ret FooSwig) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_STOUT, _swig_p) + return +} +var STOUT FooSwig = _swig_getSTOUT() +var _wrap_ALE unsafe.Pointer + +func _swig_getALE() (_swig_ret FooSwig) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_ALE, _swig_p) + return +} +var ALE FooSwig = _swig_getALE() +type SwigcptrBar uintptr + +func (p SwigcptrBar) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrBar) SwigIsBar() { +} + +type FooBarSpeed int +var _wrap_SLOW_Bar unsafe.Pointer + +func _swig_getBar_SLOW_Bar() (_swig_ret FooBarSpeed) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_SLOW_Bar, _swig_p) + return +} +var BarSLOW FooBarSpeed = _swig_getBar_SLOW_Bar() +var _wrap_FAST_Bar unsafe.Pointer + +func _swig_getBar_FAST_Bar() (_swig_ret FooBarSpeed) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_FAST_Bar, _swig_p) + return +} +var BarFAST FooBarSpeed = _swig_getBar_FAST_Bar() +var _wrap_new_Bar unsafe.Pointer + +func _swig_wrap_new_Bar() (base SwigcptrBar) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Bar, _swig_p) + return +} + +func NewBar() (_swig_ret Bar) { + return _swig_wrap_new_Bar() +} + +var _wrap_delete_Bar unsafe.Pointer + +func _swig_wrap_delete_Bar(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Bar, _swig_p) + return +} + +func DeleteBar(arg1 Bar) { + _swig_wrap_delete_Bar(arg1.Swigcptr()) +} + +type Bar interface { + Swigcptr() uintptr + SwigIsBar() +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/namespace_extend.go b/Examples/test-suite/go/namespace_extend.go new file mode 100644 index 000000000..1c544bb8b --- /dev/null +++ b/Examples/test-suite/go/namespace_extend.go @@ -0,0 +1,88 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../namespace_extend.i + +package namespace_extend + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrBar uintptr + +func (p SwigcptrBar) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrBar) SwigIsBar() { +} + +var _wrap_new_bar unsafe.Pointer + +func _swig_wrap_new_bar() (base SwigcptrBar) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_bar, _swig_p) + return +} + +func NewBar() (_swig_ret Bar) { + return _swig_wrap_new_bar() +} + +var _wrap_delete_bar unsafe.Pointer + +func _swig_wrap_delete_bar(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_bar, _swig_p) + return +} + +func DeleteBar(arg1 Bar) { + _swig_wrap_delete_bar(arg1.Swigcptr()) +} + +var _wrap_bar_blah unsafe.Pointer + +func _swig_wrap_bar_blah(base SwigcptrBar, _ int) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_bar_blah, _swig_p) + return +} + +func (arg1 SwigcptrBar) Blah(arg2 int) (_swig_ret int) { + return _swig_wrap_bar_blah(arg1, arg2) +} + +type Bar interface { + Swigcptr() uintptr + SwigIsBar() + Blah(arg2 int) (_swig_ret int) +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/namespace_forward_declaration.go b/Examples/test-suite/go/namespace_forward_declaration.go new file mode 100644 index 000000000..2f4999995 --- /dev/null +++ b/Examples/test-suite/go/namespace_forward_declaration.go @@ -0,0 +1,211 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../namespace_forward_declaration.i + +package namespace_forward_declaration + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrYYY uintptr + +func (p SwigcptrYYY) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrYYY) SwigIsYYY() { +} + +var _wrap_YYY_yyy unsafe.Pointer + +func _swig_wrap_YYY_yyy(base SwigcptrYYY, _ int) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_YYY_yyy, _swig_p) + return +} + +func (arg1 SwigcptrYYY) Yyy(arg2 int) (_swig_ret int) { + return _swig_wrap_YYY_yyy(arg1, arg2) +} + +var _wrap_new_YYY unsafe.Pointer + +func _swig_wrap_new_YYY() (base SwigcptrYYY) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_YYY, _swig_p) + return +} + +func NewYYY() (_swig_ret YYY) { + return _swig_wrap_new_YYY() +} + +var _wrap_delete_YYY unsafe.Pointer + +func _swig_wrap_delete_YYY(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_YYY, _swig_p) + return +} + +func DeleteYYY(arg1 YYY) { + _swig_wrap_delete_YYY(arg1.Swigcptr()) +} + +type YYY interface { + Swigcptr() uintptr + SwigIsYYY() + Yyy(arg2 int) (_swig_ret int) +} + +type SwigcptrXXX uintptr + +func (p SwigcptrXXX) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrXXX) SwigIsXXX() { +} + +var _wrap_XXX_xxx unsafe.Pointer + +func _swig_wrap_XXX_xxx(base SwigcptrXXX, _ int) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_XXX_xxx, _swig_p) + return +} + +func (arg1 SwigcptrXXX) Xxx(arg2 int) (_swig_ret int) { + return _swig_wrap_XXX_xxx(arg1, arg2) +} + +var _wrap_new_XXX unsafe.Pointer + +func _swig_wrap_new_XXX() (base SwigcptrXXX) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_XXX, _swig_p) + return +} + +func NewXXX() (_swig_ret XXX) { + return _swig_wrap_new_XXX() +} + +var _wrap_delete_XXX unsafe.Pointer + +func _swig_wrap_delete_XXX(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_XXX, _swig_p) + return +} + +func DeleteXXX(arg1 XXX) { + _swig_wrap_delete_XXX(arg1.Swigcptr()) +} + +type XXX interface { + Swigcptr() uintptr + SwigIsXXX() + Xxx(arg2 int) (_swig_ret int) +} + +var _wrap_testXXX1 unsafe.Pointer + +func _swig_wrap_testXXX1(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_testXXX1, _swig_p) + return +} + +func TestXXX1(arg1 XXX) { + _swig_wrap_testXXX1(arg1.Swigcptr()) +} + +var _wrap_testXXX2 unsafe.Pointer + +func _swig_wrap_testXXX2(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_testXXX2, _swig_p) + return +} + +func TestXXX2(arg1 XXX) { + _swig_wrap_testXXX2(arg1.Swigcptr()) +} + +var _wrap_testXXX3 unsafe.Pointer + +func _swig_wrap_testXXX3(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_testXXX3, _swig_p) + return +} + +func TestXXX3(arg1 XXX) { + _swig_wrap_testXXX3(arg1.Swigcptr()) +} + +var _wrap_testYYY1 unsafe.Pointer + +func _swig_wrap_testYYY1(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_testYYY1, _swig_p) + return +} + +func TestYYY1(arg1 YYY) { + _swig_wrap_testYYY1(arg1.Swigcptr()) +} + +var _wrap_testYYY2 unsafe.Pointer + +func _swig_wrap_testYYY2(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_testYYY2, _swig_p) + return +} + +func TestYYY2(arg1 YYY) { + _swig_wrap_testYYY2(arg1.Swigcptr()) +} + +var _wrap_testYYY3 unsafe.Pointer + +func _swig_wrap_testYYY3(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_testYYY3, _swig_p) + return +} + +func TestYYY3(arg1 YYY) { + _swig_wrap_testYYY3(arg1.Swigcptr()) +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/namespace_nested.go b/Examples/test-suite/go/namespace_nested.go new file mode 100644 index 000000000..e70205153 --- /dev/null +++ b/Examples/test-suite/go/namespace_nested.go @@ -0,0 +1,339 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../namespace_nested.i + +package namespace_nested + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrHi0 uintptr + +func (p SwigcptrHi0) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrHi0) SwigIsHi0() { +} + +var _wrap_new_hi0 unsafe.Pointer + +func _swig_wrap_new_hi0() (base SwigcptrHi0) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_hi0, _swig_p) + return +} + +func NewHi0() (_swig_ret Hi0) { + return _swig_wrap_new_hi0() +} + +var _wrap_delete_hi0 unsafe.Pointer + +func _swig_wrap_delete_hi0(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_hi0, _swig_p) + return +} + +func DeleteHi0(arg1 Hi0) { + _swig_wrap_delete_hi0(arg1.Swigcptr()) +} + +type Hi0 interface { + Swigcptr() uintptr + SwigIsHi0() +} + +type SwigcptrHi_hi0 uintptr + +func (p SwigcptrHi_hi0) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrHi_hi0) SwigIsHi_hi0() { +} + +var _wrap_new_Hi_hi0 unsafe.Pointer + +func _swig_wrap_new_Hi_hi0() (base SwigcptrHi_hi0) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Hi_hi0, _swig_p) + return +} + +func NewHi_hi0() (_swig_ret Hi_hi0) { + return _swig_wrap_new_Hi_hi0() +} + +var _wrap_delete_Hi_hi0 unsafe.Pointer + +func _swig_wrap_delete_Hi_hi0(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Hi_hi0, _swig_p) + return +} + +func DeleteHi_hi0(arg1 Hi_hi0) { + _swig_wrap_delete_Hi_hi0(arg1.Swigcptr()) +} + +func (p SwigcptrHi_hi0) SwigIsHi0() { +} + +func (p SwigcptrHi_hi0) SwigGetHi0() Hi0 { + return SwigcptrHi0(p.Swigcptr()) +} + +type Hi_hi0 interface { + Swigcptr() uintptr + SwigIsHi_hi0() + SwigIsHi0() + SwigGetHi0() Hi0 +} + +type SwigcptrHi1_hi0 uintptr + +func (p SwigcptrHi1_hi0) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrHi1_hi0) SwigIsHi1_hi0() { +} + +var _wrap_new_hi1_hi0 unsafe.Pointer + +func _swig_wrap_new_hi1_hi0() (base SwigcptrHi1_hi0) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_hi1_hi0, _swig_p) + return +} + +func NewHi1_hi0() (_swig_ret Hi1_hi0) { + return _swig_wrap_new_hi1_hi0() +} + +var _wrap_delete_hi1_hi0 unsafe.Pointer + +func _swig_wrap_delete_hi1_hi0(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_hi1_hi0, _swig_p) + return +} + +func DeleteHi1_hi0(arg1 Hi1_hi0) { + _swig_wrap_delete_hi1_hi0(arg1.Swigcptr()) +} + +func (p SwigcptrHi1_hi0) SwigIsHi_hi0() { +} + +func (p SwigcptrHi1_hi0) SwigGetHi_hi0() Hi_hi0 { + return SwigcptrHi_hi0(p.Swigcptr()) +} + +func (p SwigcptrHi1_hi0) SwigIsHi0() { +} + +func (p SwigcptrHi1_hi0) SwigGetHi0() Hi0 { + return SwigcptrHi0(p.Swigcptr()) +} + +type Hi1_hi0 interface { + Swigcptr() uintptr + SwigIsHi1_hi0() + SwigIsHi_hi0() + SwigGetHi_hi0() Hi_hi0 + SwigIsHi0() + SwigGetHi0() Hi0 +} + +type SwigcptrMyFoo uintptr + +func (p SwigcptrMyFoo) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrMyFoo) SwigIsMyFoo() { +} + +var _wrap_new_MyFoo unsafe.Pointer + +func _swig_wrap_new_MyFoo() (base SwigcptrMyFoo) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_MyFoo, _swig_p) + return +} + +func NewMyFoo() (_swig_ret MyFoo) { + return _swig_wrap_new_MyFoo() +} + +var _wrap_delete_MyFoo unsafe.Pointer + +func _swig_wrap_delete_MyFoo(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_MyFoo, _swig_p) + return +} + +func DeleteMyFoo(arg1 MyFoo) { + _swig_wrap_delete_MyFoo(arg1.Swigcptr()) +} + +type MyFoo interface { + Swigcptr() uintptr + SwigIsMyFoo() +} + +type SwigcptrBar uintptr + +func (p SwigcptrBar) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrBar) SwigIsBar() { +} + +var _wrap_new_Bar unsafe.Pointer + +func _swig_wrap_new_Bar() (base SwigcptrBar) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Bar, _swig_p) + return +} + +func NewBar() (_swig_ret Bar) { + return _swig_wrap_new_Bar() +} + +var _wrap_delete_Bar unsafe.Pointer + +func _swig_wrap_delete_Bar(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Bar, _swig_p) + return +} + +func DeleteBar(arg1 Bar) { + _swig_wrap_delete_Bar(arg1.Swigcptr()) +} + +type Bar interface { + Swigcptr() uintptr + SwigIsBar() +} + +type SwigcptrFoo uintptr + +func (p SwigcptrFoo) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrFoo) SwigIsFoo() { +} + +var _wrap_new_Foo unsafe.Pointer + +func _swig_wrap_new_Foo() (base SwigcptrFoo) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Foo, _swig_p) + return +} + +func NewFoo() (_swig_ret Foo) { + return _swig_wrap_new_Foo() +} + +var _wrap_delete_Foo unsafe.Pointer + +func _swig_wrap_delete_Foo(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Foo, _swig_p) + return +} + +func DeleteFoo(arg1 Foo) { + _swig_wrap_delete_Foo(arg1.Swigcptr()) +} + +type Foo interface { + Swigcptr() uintptr + SwigIsFoo() +} + +type SwigcptrConnectedSubgraphFinder uintptr + +func (p SwigcptrConnectedSubgraphFinder) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrConnectedSubgraphFinder) SwigIsConnectedSubgraphFinder() { +} + +var _wrap_new_ConnectedSubgraphFinder unsafe.Pointer + +func _swig_wrap_new_ConnectedSubgraphFinder(base int) (_ SwigcptrConnectedSubgraphFinder) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_ConnectedSubgraphFinder, _swig_p) + return +} + +func NewConnectedSubgraphFinder(arg1 int) (_swig_ret ConnectedSubgraphFinder) { + return _swig_wrap_new_ConnectedSubgraphFinder(arg1) +} + +var _wrap_delete_ConnectedSubgraphFinder unsafe.Pointer + +func _swig_wrap_delete_ConnectedSubgraphFinder(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_ConnectedSubgraphFinder, _swig_p) + return +} + +func DeleteConnectedSubgraphFinder(arg1 ConnectedSubgraphFinder) { + _swig_wrap_delete_ConnectedSubgraphFinder(arg1.Swigcptr()) +} + +func (p SwigcptrConnectedSubgraphFinder) SwigIsFoo() { +} + +func (p SwigcptrConnectedSubgraphFinder) SwigGetFoo() Foo { + return SwigcptrFoo(p.Swigcptr()) +} + +type ConnectedSubgraphFinder interface { + Swigcptr() uintptr + SwigIsConnectedSubgraphFinder() + SwigIsFoo() + SwigGetFoo() Foo +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/namespace_spaces.go b/Examples/test-suite/go/namespace_spaces.go new file mode 100644 index 000000000..56a8904e0 --- /dev/null +++ b/Examples/test-suite/go/namespace_spaces.go @@ -0,0 +1,140 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../namespace_spaces.i + +package namespace_spaces + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrFoo uintptr + +func (p SwigcptrFoo) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrFoo) SwigIsFoo() { +} + +var _wrap_new_Foo unsafe.Pointer + +func _swig_wrap_new_Foo() (base SwigcptrFoo) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Foo, _swig_p) + return +} + +func NewFoo() (_swig_ret Foo) { + return _swig_wrap_new_Foo() +} + +var _wrap_delete_Foo unsafe.Pointer + +func _swig_wrap_delete_Foo(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Foo, _swig_p) + return +} + +func DeleteFoo(arg1 Foo) { + _swig_wrap_delete_Foo(arg1.Swigcptr()) +} + +var _wrap_Foo_blah unsafe.Pointer + +func _swig_wrap_Foo_blah(base SwigcptrFoo, _ int) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_blah, _swig_p) + return +} + +func (arg1 SwigcptrFoo) Blah(arg2 int) (_swig_ret int) { + return _swig_wrap_Foo_blah(arg1, arg2) +} + +var _wrap_Foo_spam unsafe.Pointer + +func _swig_wrap_Foo_spam(base SwigcptrFoo, _ int) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_spam, _swig_p) + return +} + +func (arg1 SwigcptrFoo) Spam(arg2 int) (_swig_ret int) { + return _swig_wrap_Foo_spam(arg1, arg2) +} + +var _wrap_Foo_bar unsafe.Pointer + +func _swig_wrap_Foo_bar(base SwigcptrFoo, _ int) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_bar, _swig_p) + return +} + +func (arg1 SwigcptrFoo) Bar(arg2 int) (_swig_ret int) { + return _swig_wrap_Foo_bar(arg1, arg2) +} + +var _wrap_Foo_func_ptr_set unsafe.Pointer + +func _swig_wrap_Foo_func_ptr_set(base SwigcptrFoo, _ _swig_memberptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_func_ptr_set, _swig_p) + return +} + +func (arg1 SwigcptrFoo) SetFunc_ptr(arg2 _swig_memberptr) { + _swig_wrap_Foo_func_ptr_set(arg1, arg2) +} + +var _wrap_Foo_func_ptr_get unsafe.Pointer + +func _swig_wrap_Foo_func_ptr_get(base SwigcptrFoo) (_ _swig_memberptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_func_ptr_get, _swig_p) + return +} + +func (arg1 SwigcptrFoo) GetFunc_ptr() (_swig_ret _swig_memberptr) { + return _swig_wrap_Foo_func_ptr_get(arg1) +} + +type Foo interface { + Swigcptr() uintptr + SwigIsFoo() + Blah(arg2 int) (_swig_ret int) + Spam(arg2 int) (_swig_ret int) + Bar(arg2 int) (_swig_ret int) + SetFunc_ptr(arg2 _swig_memberptr) + GetFunc_ptr() (_swig_ret _swig_memberptr) +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/namespace_template.go b/Examples/test-suite/go/namespace_template.go new file mode 100644 index 000000000..4af8c70f0 --- /dev/null +++ b/Examples/test-suite/go/namespace_template.go @@ -0,0 +1,269 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../namespace_template.i + +package namespace_template + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +var _wrap_maxint unsafe.Pointer + +func Maxint(arg1 int, arg2 int) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_maxint, _swig_p) + return +} +type SwigcptrVectorint uintptr + +func (p SwigcptrVectorint) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrVectorint) SwigIsVectorint() { +} + +var _wrap_new_vectorint unsafe.Pointer + +func _swig_wrap_new_vectorint() (base SwigcptrVectorint) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_vectorint, _swig_p) + return +} + +func NewVectorint() (_swig_ret Vectorint) { + return _swig_wrap_new_vectorint() +} + +var _wrap_delete_vectorint unsafe.Pointer + +func _swig_wrap_delete_vectorint(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_vectorint, _swig_p) + return +} + +func DeleteVectorint(arg1 Vectorint) { + _swig_wrap_delete_vectorint(arg1.Swigcptr()) +} + +var _wrap_vectorint_blah unsafe.Pointer + +func _swig_wrap_vectorint_blah(base SwigcptrVectorint, _ int) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_vectorint_blah, _swig_p) + return +} + +func (arg1 SwigcptrVectorint) Blah(arg2 int) (_swig_ret string) { + return _swig_wrap_vectorint_blah(arg1, arg2) +} + +type Vectorint interface { + Swigcptr() uintptr + SwigIsVectorint() + Blah(arg2 int) (_swig_ret string) +} + +var _wrap_maxshort unsafe.Pointer + +func Maxshort(arg1 int16, arg2 int16) (_swig_ret int16) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_maxshort, _swig_p) + return +} +type SwigcptrVectorshort uintptr + +func (p SwigcptrVectorshort) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrVectorshort) SwigIsVectorshort() { +} + +var _wrap_new_vectorshort unsafe.Pointer + +func _swig_wrap_new_vectorshort() (base SwigcptrVectorshort) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_vectorshort, _swig_p) + return +} + +func NewVectorshort() (_swig_ret Vectorshort) { + return _swig_wrap_new_vectorshort() +} + +var _wrap_delete_vectorshort unsafe.Pointer + +func _swig_wrap_delete_vectorshort(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_vectorshort, _swig_p) + return +} + +func DeleteVectorshort(arg1 Vectorshort) { + _swig_wrap_delete_vectorshort(arg1.Swigcptr()) +} + +var _wrap_vectorshort_blah unsafe.Pointer + +func _swig_wrap_vectorshort_blah(base SwigcptrVectorshort, _ int16) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_vectorshort_blah, _swig_p) + return +} + +func (arg1 SwigcptrVectorshort) Blah(arg2 int16) (_swig_ret string) { + return _swig_wrap_vectorshort_blah(arg1, arg2) +} + +type Vectorshort interface { + Swigcptr() uintptr + SwigIsVectorshort() + Blah(arg2 int16) (_swig_ret string) +} + +var _wrap_maxlong unsafe.Pointer + +func Maxlong(arg1 int64, arg2 int64) (_swig_ret int64) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_maxlong, _swig_p) + return +} +type SwigcptrVectorlong uintptr + +func (p SwigcptrVectorlong) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrVectorlong) SwigIsVectorlong() { +} + +var _wrap_new_vectorlong unsafe.Pointer + +func _swig_wrap_new_vectorlong() (base SwigcptrVectorlong) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_vectorlong, _swig_p) + return +} + +func NewVectorlong() (_swig_ret Vectorlong) { + return _swig_wrap_new_vectorlong() +} + +var _wrap_delete_vectorlong unsafe.Pointer + +func _swig_wrap_delete_vectorlong(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_vectorlong, _swig_p) + return +} + +func DeleteVectorlong(arg1 Vectorlong) { + _swig_wrap_delete_vectorlong(arg1.Swigcptr()) +} + +var _wrap_vectorlong_blah unsafe.Pointer + +func _swig_wrap_vectorlong_blah(base SwigcptrVectorlong, _ int64) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_vectorlong_blah, _swig_p) + return +} + +func (arg1 SwigcptrVectorlong) Blah(arg2 int64) (_swig_ret string) { + return _swig_wrap_vectorlong_blah(arg1, arg2) +} + +type Vectorlong interface { + Swigcptr() uintptr + SwigIsVectorlong() + Blah(arg2 int64) (_swig_ret string) +} + +var _wrap_maxInteger unsafe.Pointer + +func MaxInteger(arg1 int, arg2 int) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_maxInteger, _swig_p) + return +} +type SwigcptrVectorInteger uintptr + +func (p SwigcptrVectorInteger) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrVectorInteger) SwigIsVectorInteger() { +} + +var _wrap_new_vectorInteger unsafe.Pointer + +func _swig_wrap_new_vectorInteger() (base SwigcptrVectorInteger) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_vectorInteger, _swig_p) + return +} + +func NewVectorInteger() (_swig_ret VectorInteger) { + return _swig_wrap_new_vectorInteger() +} + +var _wrap_delete_vectorInteger unsafe.Pointer + +func _swig_wrap_delete_vectorInteger(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_vectorInteger, _swig_p) + return +} + +func DeleteVectorInteger(arg1 VectorInteger) { + _swig_wrap_delete_vectorInteger(arg1.Swigcptr()) +} + +var _wrap_vectorInteger_blah unsafe.Pointer + +func _swig_wrap_vectorInteger_blah(base SwigcptrVectorInteger, _ int) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_vectorInteger_blah, _swig_p) + return +} + +func (arg1 SwigcptrVectorInteger) Blah(arg2 int) (_swig_ret string) { + return _swig_wrap_vectorInteger_blah(arg1, arg2) +} + +type VectorInteger interface { + Swigcptr() uintptr + SwigIsVectorInteger() + Blah(arg2 int) (_swig_ret string) +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/namespace_typedef_class.go b/Examples/test-suite/go/namespace_typedef_class.go new file mode 100644 index 000000000..8e8448e5c --- /dev/null +++ b/Examples/test-suite/go/namespace_typedef_class.go @@ -0,0 +1,165 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../namespace_typedef_class.i + +package namespace_typedef_class + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrS1 uintptr + +func (p SwigcptrS1) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrS1) SwigIsS1() { +} + +var _wrap_S1_n_set unsafe.Pointer + +func _swig_wrap_S1_n_set(base SwigcptrS1, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_S1_n_set, _swig_p) + return +} + +func (arg1 SwigcptrS1) SetN(arg2 int) { + _swig_wrap_S1_n_set(arg1, arg2) +} + +var _wrap_S1_n_get unsafe.Pointer + +func _swig_wrap_S1_n_get(base SwigcptrS1) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_S1_n_get, _swig_p) + return +} + +func (arg1 SwigcptrS1) GetN() (_swig_ret int) { + return _swig_wrap_S1_n_get(arg1) +} + +var _wrap_new_S1 unsafe.Pointer + +func _swig_wrap_new_S1() (base SwigcptrS1) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_S1, _swig_p) + return +} + +func NewS1() (_swig_ret S1) { + return _swig_wrap_new_S1() +} + +var _wrap_delete_S1 unsafe.Pointer + +func _swig_wrap_delete_S1(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_S1, _swig_p) + return +} + +func DeleteS1(arg1 S1) { + _swig_wrap_delete_S1(arg1.Swigcptr()) +} + +type S1 interface { + Swigcptr() uintptr + SwigIsS1() + SetN(arg2 int) + GetN() (_swig_ret int) +} + +type SwigcptrS2 uintptr + +func (p SwigcptrS2) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrS2) SwigIsS2() { +} + +var _wrap_S2_n_set unsafe.Pointer + +func _swig_wrap_S2_n_set(base SwigcptrS2, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_S2_n_set, _swig_p) + return +} + +func (arg1 SwigcptrS2) SetN(arg2 int) { + _swig_wrap_S2_n_set(arg1, arg2) +} + +var _wrap_S2_n_get unsafe.Pointer + +func _swig_wrap_S2_n_get(base SwigcptrS2) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_S2_n_get, _swig_p) + return +} + +func (arg1 SwigcptrS2) GetN() (_swig_ret int) { + return _swig_wrap_S2_n_get(arg1) +} + +var _wrap_new_S2 unsafe.Pointer + +func _swig_wrap_new_S2() (base SwigcptrS2) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_S2, _swig_p) + return +} + +func NewS2() (_swig_ret S2) { + return _swig_wrap_new_S2() +} + +var _wrap_delete_S2 unsafe.Pointer + +func _swig_wrap_delete_S2(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_S2, _swig_p) + return +} + +func DeleteS2(arg1 S2) { + _swig_wrap_delete_S2(arg1.Swigcptr()) +} + +type S2 interface { + Swigcptr() uintptr + SwigIsS2() + SetN(arg2 int) + GetN() (_swig_ret int) +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/namespace_typemap.go b/Examples/test-suite/go/namespace_typemap.go new file mode 100644 index 000000000..5fdb44d84 --- /dev/null +++ b/Examples/test-suite/go/namespace_typemap.go @@ -0,0 +1,204 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../namespace_typemap.i + +package namespace_typemap + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +var _wrap_stest1 unsafe.Pointer + +func Stest1(arg1 string) (_swig_ret string) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_stest1, _swig_p) + return +} +var _wrap_ctest1 unsafe.Pointer + +func Ctest1(arg1 complex128) (_swig_ret float64) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_ctest1, _swig_p) + return +} +var _wrap_stest2 unsafe.Pointer + +func Stest2(arg1 string) (_swig_ret string) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_stest2, _swig_p) + return +} +var _wrap_ctest2 unsafe.Pointer + +func Ctest2(arg1 complex128) (_swig_ret float64) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_ctest2, _swig_p) + return +} +var _wrap_stest3 unsafe.Pointer + +func Stest3(arg1 string) (_swig_ret string) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_stest3, _swig_p) + return +} +var _wrap_ctest3 unsafe.Pointer + +func Ctest3(arg1 complex128) (_swig_ret float64) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_ctest3, _swig_p) + return +} +var _wrap_stest4 unsafe.Pointer + +func Stest4(arg1 string) (_swig_ret string) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_stest4, _swig_p) + return +} +var _wrap_ctest4 unsafe.Pointer + +func Ctest4(arg1 complex128) (_swig_ret float64) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_ctest4, _swig_p) + return +} +var _wrap_stest5 unsafe.Pointer + +func Stest5(arg1 string) (_swig_ret string) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_stest5, _swig_p) + return +} +var _wrap_ctest5 unsafe.Pointer + +func Ctest5(arg1 complex128) (_swig_ret float64) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_ctest5, _swig_p) + return +} +var _wrap_stest6 unsafe.Pointer + +func Stest6(arg1 string) (_swig_ret string) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_stest6, _swig_p) + return +} +var _wrap_ctest6 unsafe.Pointer + +func Ctest6(arg1 complex128) (_swig_ret float64) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_ctest6, _swig_p) + return +} +var _wrap_stest7 unsafe.Pointer + +func Stest7(arg1 string) (_swig_ret string) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_stest7, _swig_p) + return +} +var _wrap_ctest7 unsafe.Pointer + +func Ctest7(arg1 complex128) (_swig_ret float64) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_ctest7, _swig_p) + return +} +var _wrap_stest8 unsafe.Pointer + +func Stest8(arg1 string) (_swig_ret string) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_stest8, _swig_p) + return +} +var _wrap_ctest8 unsafe.Pointer + +func Ctest8(arg1 complex128) (_swig_ret float64) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_ctest8, _swig_p) + return +} +var _wrap_stest9 unsafe.Pointer + +func Stest9(arg1 string) (_swig_ret string) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_stest9, _swig_p) + return +} +var _wrap_ctest9 unsafe.Pointer + +func Ctest9(arg1 complex128) (_swig_ret float64) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_ctest9, _swig_p) + return +} +var _wrap_stest10 unsafe.Pointer + +func Stest10(arg1 string) (_swig_ret string) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_stest10, _swig_p) + return +} +var _wrap_ctest10 unsafe.Pointer + +func Ctest10(arg1 complex128) (_swig_ret float64) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_ctest10, _swig_p) + return +} +var _wrap_stest11 unsafe.Pointer + +func Stest11(arg1 string) (_swig_ret string) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_stest11, _swig_p) + return +} +var _wrap_ctest11 unsafe.Pointer + +func Ctest11(arg1 complex128) (_swig_ret float64) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_ctest11, _swig_p) + return +} +var _wrap_stest12 unsafe.Pointer + +func Stest12(arg1 string) (_swig_ret string) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_stest12, _swig_p) + return +} +var _wrap_ctest12 unsafe.Pointer + +func Ctest12(arg1 complex128) (_swig_ret float64) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_ctest12, _swig_p) + return +} +var _wrap_ttest1 unsafe.Pointer + +func Ttest1(arg1 int) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_ttest1, _swig_p) + return +} + diff --git a/Examples/test-suite/go/namespace_typemap_runme b/Examples/test-suite/go/namespace_typemap_runme new file mode 100755 index 000000000..18ebaa3c4 Binary files /dev/null and b/Examples/test-suite/go/namespace_typemap_runme differ diff --git a/Examples/test-suite/go/namespace_union.go b/Examples/test-suite/go/namespace_union.go new file mode 100644 index 000000000..a6754d656 --- /dev/null +++ b/Examples/test-suite/go/namespace_union.go @@ -0,0 +1,101 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../namespace_union.i + +package namespace_union + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrVariant uintptr + +func (p SwigcptrVariant) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrVariant) SwigIsVariant() { +} + +var _wrap_new_Variant unsafe.Pointer + +func _swig_wrap_new_Variant() (base SwigcptrVariant) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Variant, _swig_p) + return +} + +func NewVariant() (_swig_ret Variant) { + return _swig_wrap_new_Variant() +} + +var _wrap_Variant_varType_set unsafe.Pointer + +func _swig_wrap_Variant_varType_set(base SwigcptrVariant, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Variant_varType_set, _swig_p) + return +} + +func (arg1 SwigcptrVariant) SetVarType(arg2 int) { + _swig_wrap_Variant_varType_set(arg1, arg2) +} + +var _wrap_Variant_varType_get unsafe.Pointer + +func _swig_wrap_Variant_varType_get(base SwigcptrVariant) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Variant_varType_get, _swig_p) + return +} + +func (arg1 SwigcptrVariant) GetVarType() (_swig_ret int) { + return _swig_wrap_Variant_varType_get(arg1) +} + +var _wrap_delete_Variant unsafe.Pointer + +func _swig_wrap_delete_Variant(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Variant, _swig_p) + return +} + +func DeleteVariant(arg1 Variant) { + _swig_wrap_delete_Variant(arg1.Swigcptr()) +} + +type Variant interface { + Swigcptr() uintptr + SwigIsVariant() + SetVarType(arg2 int) + GetVarType() (_swig_ret int) +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/namespace_virtual_method.go b/Examples/test-suite/go/namespace_virtual_method.go new file mode 100644 index 000000000..5f391ead6 --- /dev/null +++ b/Examples/test-suite/go/namespace_virtual_method.go @@ -0,0 +1,144 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../namespace_virtual_method.i + +package namespace_virtual_method + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrFoo uintptr + +func (p SwigcptrFoo) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrFoo) SwigIsFoo() { +} + +var _wrap_delete_Foo unsafe.Pointer + +func _swig_wrap_delete_Foo(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Foo, _swig_p) + return +} + +func DeleteFoo(arg1 Foo) { + _swig_wrap_delete_Foo(arg1.Swigcptr()) +} + +var _wrap_Foo_bar unsafe.Pointer + +func _swig_wrap_Foo_bar(base SwigcptrFoo, _ uintptr) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_bar, _swig_p) + return +} + +func (arg1 SwigcptrFoo) Bar(arg2 A_B_Foo) (_swig_ret int) { + return _swig_wrap_Foo_bar(arg1, arg2.Swigcptr()) +} + +type Foo interface { + Swigcptr() uintptr + SwigIsFoo() + Bar(arg2 A_B_Foo) (_swig_ret int) +} + +type SwigcptrSpam uintptr + +func (p SwigcptrSpam) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrSpam) SwigIsSpam() { +} + +var _wrap_new_Spam unsafe.Pointer + +func _swig_wrap_new_Spam() (base SwigcptrSpam) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Spam, _swig_p) + return +} + +func NewSpam() (_swig_ret Spam) { + return _swig_wrap_new_Spam() +} + +var _wrap_delete_Spam unsafe.Pointer + +func _swig_wrap_delete_Spam(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Spam, _swig_p) + return +} + +func DeleteSpam(arg1 Spam) { + _swig_wrap_delete_Spam(arg1.Swigcptr()) +} + +var _wrap_Spam_bar unsafe.Pointer + +func _swig_wrap_Spam_bar(base SwigcptrSpam, _ uintptr) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Spam_bar, _swig_p) + return +} + +func (arg1 SwigcptrSpam) Bar(arg2 A_B_Foo) (_swig_ret int) { + return _swig_wrap_Spam_bar(arg1, arg2.Swigcptr()) +} + +func (p SwigcptrSpam) SwigIsFoo() { +} + +func (p SwigcptrSpam) SwigGetFoo() Foo { + return SwigcptrFoo(p.Swigcptr()) +} + +type Spam interface { + Swigcptr() uintptr + SwigIsSpam() + Bar(arg2 A_B_Foo) (_swig_ret int) + SwigIsFoo() + SwigGetFoo() Foo +} + + +type SwigcptrA_B_Foo uintptr +type A_B_Foo interface { + Swigcptr() uintptr; +} +func (p SwigcptrA_B_Foo) Swigcptr() uintptr { + return uintptr(p) +} + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/namespace_virtual_method_runme b/Examples/test-suite/go/namespace_virtual_method_runme new file mode 100755 index 000000000..45d022639 Binary files /dev/null and b/Examples/test-suite/go/namespace_virtual_method_runme differ diff --git a/Examples/test-suite/go/naturalvar.go b/Examples/test-suite/go/naturalvar.go new file mode 100644 index 000000000..d7120476a --- /dev/null +++ b/Examples/test-suite/go/naturalvar.go @@ -0,0 +1,234 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../naturalvar.i + +package naturalvar + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrFoo uintptr + +func (p SwigcptrFoo) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrFoo) SwigIsFoo() { +} + +var _wrap_new_Foo unsafe.Pointer + +func _swig_wrap_new_Foo() (base SwigcptrFoo) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Foo, _swig_p) + return +} + +func NewFoo() (_swig_ret Foo) { + return _swig_wrap_new_Foo() +} + +var _wrap_delete_Foo unsafe.Pointer + +func _swig_wrap_delete_Foo(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Foo, _swig_p) + return +} + +func DeleteFoo(arg1 Foo) { + _swig_wrap_delete_Foo(arg1.Swigcptr()) +} + +type Foo interface { + Swigcptr() uintptr + SwigIsFoo() +} + +var _wrap_f_set unsafe.Pointer + +func _swig_wrap_f_set(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_f_set, _swig_p) + return +} + +func SetF(arg1 Foo) { + _swig_wrap_f_set(arg1.Swigcptr()) +} + +var _wrap_f_get unsafe.Pointer + +func _swig_wrap_f_get() (base SwigcptrFoo) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_f_get, _swig_p) + return +} + +func GetF() (_swig_ret Foo) { + return _swig_wrap_f_get() +} + +var _wrap_s_set unsafe.Pointer + +func _swig_wrap_s_set(base string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_s_set, _swig_p) + return +} + +func SetS(arg1 string) { + _swig_wrap_s_set(arg1) +} + +var _wrap_s_get unsafe.Pointer + +func GetS() (_swig_ret string) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_s_get, _swig_p) + return +} +type SwigcptrBar uintptr + +func (p SwigcptrBar) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrBar) SwigIsBar() { +} + +var _wrap_Bar_i_set unsafe.Pointer + +func _swig_wrap_Bar_i_set(base SwigcptrBar, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Bar_i_set, _swig_p) + return +} + +func (arg1 SwigcptrBar) SetI(arg2 int) { + _swig_wrap_Bar_i_set(arg1, arg2) +} + +var _wrap_Bar_i_get unsafe.Pointer + +func _swig_wrap_Bar_i_get(base SwigcptrBar) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Bar_i_get, _swig_p) + return +} + +func (arg1 SwigcptrBar) GetI() (_swig_ret int) { + return _swig_wrap_Bar_i_get(arg1) +} + +var _wrap_Bar_f_set unsafe.Pointer + +func _swig_wrap_Bar_f_set(base SwigcptrBar, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Bar_f_set, _swig_p) + return +} + +func (arg1 SwigcptrBar) SetF(arg2 Foo) { + _swig_wrap_Bar_f_set(arg1, arg2.Swigcptr()) +} + +var _wrap_Bar_f_get unsafe.Pointer + +func _swig_wrap_Bar_f_get(base SwigcptrBar) (_ SwigcptrFoo) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Bar_f_get, _swig_p) + return +} + +func (arg1 SwigcptrBar) GetF() (_swig_ret Foo) { + return _swig_wrap_Bar_f_get(arg1) +} + +var _wrap_Bar_s_set unsafe.Pointer + +func _swig_wrap_Bar_s_set(base SwigcptrBar, _ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Bar_s_set, _swig_p) + return +} + +func (arg1 SwigcptrBar) SetS(arg2 string) { + _swig_wrap_Bar_s_set(arg1, arg2) +} + +var _wrap_Bar_s_get unsafe.Pointer + +func _swig_wrap_Bar_s_get(base SwigcptrBar) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Bar_s_get, _swig_p) + return +} + +func (arg1 SwigcptrBar) GetS() (_swig_ret string) { + return _swig_wrap_Bar_s_get(arg1) +} + +var _wrap_new_Bar unsafe.Pointer + +func _swig_wrap_new_Bar() (base SwigcptrBar) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Bar, _swig_p) + return +} + +func NewBar() (_swig_ret Bar) { + return _swig_wrap_new_Bar() +} + +var _wrap_delete_Bar unsafe.Pointer + +func _swig_wrap_delete_Bar(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Bar, _swig_p) + return +} + +func DeleteBar(arg1 Bar) { + _swig_wrap_delete_Bar(arg1.Swigcptr()) +} + +type Bar interface { + Swigcptr() uintptr + SwigIsBar() + SetI(arg2 int) + GetI() (_swig_ret int) + SetF(arg2 Foo) + GetF() (_swig_ret Foo) + SetS(arg2 string) + GetS() (_swig_ret string) +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/naturalvar_more.go b/Examples/test-suite/go/naturalvar_more.go new file mode 100644 index 000000000..3cbada1bb --- /dev/null +++ b/Examples/test-suite/go/naturalvar_more.go @@ -0,0 +1,506 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../naturalvar_more.i + +package naturalvar_more + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrK uintptr + +func (p SwigcptrK) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrK) SwigIsK() { +} + +var _wrap_new_K unsafe.Pointer + +func _swig_wrap_new_K() (base SwigcptrK) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_K, _swig_p) + return +} + +func NewK() (_swig_ret K) { + return _swig_wrap_new_K() +} + +var _wrap_delete_K unsafe.Pointer + +func _swig_wrap_delete_K(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_K, _swig_p) + return +} + +func DeleteK(arg1 K) { + _swig_wrap_delete_K(arg1.Swigcptr()) +} + +type K interface { + Swigcptr() uintptr + SwigIsK() +} + +var _wrap_glob_set unsafe.Pointer + +func _swig_wrap_glob_set(base int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_glob_set, _swig_p) + return +} + +func SetGlob(arg1 int) { + _swig_wrap_glob_set(arg1) +} + +var _wrap_glob_get unsafe.Pointer + +func GetGlob() (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_glob_get, _swig_p) + return +} +type SpaceE int +var _wrap_E1 unsafe.Pointer + +func _swig_getE1() (_swig_ret SpaceE) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_E1, _swig_p) + return +} +var E1 SpaceE = _swig_getE1() +var _wrap_E2 unsafe.Pointer + +func _swig_getE2() (_swig_ret SpaceE) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_E2, _swig_p) + return +} +var E2 SpaceE = _swig_getE2() +var _wrap_E3 unsafe.Pointer + +func _swig_getE3() (_swig_ret SpaceE) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_E3, _swig_p) + return +} +var E3 SpaceE = _swig_getE3() +type SwigcptrTE uintptr + +func (p SwigcptrTE) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrTE) SwigIsTE() { +} + +var _wrap_new_TE unsafe.Pointer + +func _swig_wrap_new_TE() (base SwigcptrTE) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_TE, _swig_p) + return +} + +func NewTE() (_swig_ret TE) { + return _swig_wrap_new_TE() +} + +var _wrap_delete_TE unsafe.Pointer + +func _swig_wrap_delete_TE(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_TE, _swig_p) + return +} + +func DeleteTE(arg1 TE) { + _swig_wrap_delete_TE(arg1.Swigcptr()) +} + +type TE interface { + Swigcptr() uintptr + SwigIsTE() +} + +type SwigcptrVectorString uintptr + +func (p SwigcptrVectorString) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrVectorString) SwigIsVectorString() { +} + +var _wrap_new_VectorString__SWIG_0 unsafe.Pointer + +func _swig_wrap_new_VectorString__SWIG_0() (base SwigcptrVectorString) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_VectorString__SWIG_0, _swig_p) + return +} + +func NewVectorString__SWIG_0() (_swig_ret VectorString) { + return _swig_wrap_new_VectorString__SWIG_0() +} + +var _wrap_new_VectorString__SWIG_1 unsafe.Pointer + +func _swig_wrap_new_VectorString__SWIG_1(base int64) (_ SwigcptrVectorString) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_VectorString__SWIG_1, _swig_p) + return +} + +func NewVectorString__SWIG_1(arg1 int64) (_swig_ret VectorString) { + return _swig_wrap_new_VectorString__SWIG_1(arg1) +} + +func NewVectorString(a ...interface{}) VectorString { + argc := len(a) + if argc == 0 { + return NewVectorString__SWIG_0() + } + if argc == 1 { + return NewVectorString__SWIG_1(a[0].(int64)) + } + panic("No match for overloaded function call") +} + +var _wrap_VectorString_size unsafe.Pointer + +func _swig_wrap_VectorString_size(base SwigcptrVectorString) (_ int64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_VectorString_size, _swig_p) + return +} + +func (arg1 SwigcptrVectorString) Size() (_swig_ret int64) { + return _swig_wrap_VectorString_size(arg1) +} + +var _wrap_VectorString_capacity unsafe.Pointer + +func _swig_wrap_VectorString_capacity(base SwigcptrVectorString) (_ int64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_VectorString_capacity, _swig_p) + return +} + +func (arg1 SwigcptrVectorString) Capacity() (_swig_ret int64) { + return _swig_wrap_VectorString_capacity(arg1) +} + +var _wrap_VectorString_reserve unsafe.Pointer + +func _swig_wrap_VectorString_reserve(base SwigcptrVectorString, _ int64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_VectorString_reserve, _swig_p) + return +} + +func (arg1 SwigcptrVectorString) Reserve(arg2 int64) { + _swig_wrap_VectorString_reserve(arg1, arg2) +} + +var _wrap_VectorString_isEmpty unsafe.Pointer + +func _swig_wrap_VectorString_isEmpty(base SwigcptrVectorString) (_ bool) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_VectorString_isEmpty, _swig_p) + return +} + +func (arg1 SwigcptrVectorString) IsEmpty() (_swig_ret bool) { + return _swig_wrap_VectorString_isEmpty(arg1) +} + +var _wrap_VectorString_clear unsafe.Pointer + +func _swig_wrap_VectorString_clear(base SwigcptrVectorString) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_VectorString_clear, _swig_p) + return +} + +func (arg1 SwigcptrVectorString) Clear() { + _swig_wrap_VectorString_clear(arg1) +} + +var _wrap_VectorString_add unsafe.Pointer + +func _swig_wrap_VectorString_add(base SwigcptrVectorString, _ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_VectorString_add, _swig_p) + return +} + +func (arg1 SwigcptrVectorString) Add(arg2 string) { + _swig_wrap_VectorString_add(arg1, arg2) +} + +var _wrap_VectorString_get unsafe.Pointer + +func _swig_wrap_VectorString_get(base SwigcptrVectorString, _ int) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_VectorString_get, _swig_p) + return +} + +func (arg1 SwigcptrVectorString) Get(arg2 int) (_swig_ret string) { + return _swig_wrap_VectorString_get(arg1, arg2) +} + +var _wrap_VectorString_set unsafe.Pointer + +func _swig_wrap_VectorString_set(base SwigcptrVectorString, _ int, _ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_VectorString_set, _swig_p) + return +} + +func (arg1 SwigcptrVectorString) Set(arg2 int, arg3 string) { + _swig_wrap_VectorString_set(arg1, arg2, arg3) +} + +var _wrap_delete_VectorString unsafe.Pointer + +func _swig_wrap_delete_VectorString(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_VectorString, _swig_p) + return +} + +func DeleteVectorString(arg1 VectorString) { + _swig_wrap_delete_VectorString(arg1.Swigcptr()) +} + +type VectorString interface { + Swigcptr() uintptr + SwigIsVectorString() + Size() (_swig_ret int64) + Capacity() (_swig_ret int64) + Reserve(arg2 int64) + IsEmpty() (_swig_ret bool) + Clear() + Add(arg2 string) + Get(arg2 int) (_swig_ret string) + Set(arg2 int, arg3 string) +} + +type SwigcptrS uintptr + +func (p SwigcptrS) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrS) SwigIsS() { +} + +var _wrap_S_te_set unsafe.Pointer + +func _swig_wrap_S_te_set(base SwigcptrS, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_S_te_set, _swig_p) + return +} + +func (arg1 SwigcptrS) SetTe(arg2 TE) { + _swig_wrap_S_te_set(arg1, arg2.Swigcptr()) +} + +var _wrap_S_te_get unsafe.Pointer + +func _swig_wrap_S_te_get(base SwigcptrS) (_ SwigcptrTE) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_S_te_get, _swig_p) + return +} + +func (arg1 SwigcptrS) GetTe() (_swig_ret TE) { + return _swig_wrap_S_te_get(arg1) +} + +var _wrap_S_const_te_get unsafe.Pointer + +func _swig_wrap_S_const_te_get(base SwigcptrS) (_ SwigcptrTE) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_S_const_te_get, _swig_p) + return +} + +func (arg1 SwigcptrS) GetConst_te() (_swig_ret TE) { + return _swig_wrap_S_const_te_get(arg1) +} + +var _wrap_S_const_string_member_get unsafe.Pointer + +func _swig_wrap_S_const_string_member_get(base SwigcptrS) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_S_const_string_member_get, _swig_p) + return +} + +func (arg1 SwigcptrS) GetConst_string_member() (_swig_ret string) { + return _swig_wrap_S_const_string_member_get(arg1) +} + +var _wrap_S_string_member_set unsafe.Pointer + +func _swig_wrap_S_string_member_set(base SwigcptrS, _ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_S_string_member_set, _swig_p) + return +} + +func (arg1 SwigcptrS) SetString_member(arg2 string) { + _swig_wrap_S_string_member_set(arg1, arg2) +} + +var _wrap_S_string_member_get unsafe.Pointer + +func _swig_wrap_S_string_member_get(base SwigcptrS) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_S_string_member_get, _swig_p) + return +} + +func (arg1 SwigcptrS) GetString_member() (_swig_ret string) { + return _swig_wrap_S_string_member_get(arg1) +} + +var _wrap_S_hidden_set unsafe.Pointer + +func _swig_wrap_S_hidden_set(base SwigcptrS, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_S_hidden_set, _swig_p) + return +} + +func (arg1 SwigcptrS) SetHidden(arg2 Hidden) { + _swig_wrap_S_hidden_set(arg1, arg2.Swigcptr()) +} + +var _wrap_S_hidden_get unsafe.Pointer + +func _swig_wrap_S_hidden_get(base SwigcptrS) (_ SwigcptrHidden) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_S_hidden_get, _swig_p) + return +} + +func (arg1 SwigcptrS) GetHidden() (_swig_ret Hidden) { + return _swig_wrap_S_hidden_get(arg1) +} + +var _wrap_S_noidea_set unsafe.Pointer + +func _swig_wrap_S_noidea_set(base SwigcptrS, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_S_noidea_set, _swig_p) + return +} + +func (arg1 SwigcptrS) SetNoidea(arg2 Ace_NoIdea_Sl_Hidden_Sg_) { + _swig_wrap_S_noidea_set(arg1, arg2.Swigcptr()) +} + +var _wrap_S_noidea_get unsafe.Pointer + +func _swig_wrap_S_noidea_get(base SwigcptrS) (_ SwigcptrAce_NoIdea_Sl_Hidden_Sg_) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_S_noidea_get, _swig_p) + return +} + +func (arg1 SwigcptrS) GetNoidea() (_swig_ret Ace_NoIdea_Sl_Hidden_Sg_) { + return _swig_wrap_S_noidea_get(arg1) +} + +var _wrap_new_S unsafe.Pointer + +func _swig_wrap_new_S() (base SwigcptrS) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_S, _swig_p) + return +} + +func NewS() (_swig_ret S) { + return _swig_wrap_new_S() +} + +var _wrap_delete_S unsafe.Pointer + +func _swig_wrap_delete_S(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_S, _swig_p) + return +} + +func DeleteS(arg1 S) { + _swig_wrap_delete_S(arg1.Swigcptr()) +} + +type S interface { + Swigcptr() uintptr + SwigIsS() + SetTe(arg2 TE) + GetTe() (_swig_ret TE) + GetConst_te() (_swig_ret TE) + GetConst_string_member() (_swig_ret string) + SetString_member(arg2 string) + GetString_member() (_swig_ret string) + SetHidden(arg2 Hidden) + GetHidden() (_swig_ret Hidden) + SetNoidea(arg2 Ace_NoIdea_Sl_Hidden_Sg_) + GetNoidea() (_swig_ret Ace_NoIdea_Sl_Hidden_Sg_) +} + + +type SwigcptrAce_NoIdea_Sl_Hidden_Sg_ uintptr +type Ace_NoIdea_Sl_Hidden_Sg_ interface { + Swigcptr() uintptr; +} +func (p SwigcptrAce_NoIdea_Sl_Hidden_Sg_) Swigcptr() uintptr { + return uintptr(p) +} + +type SwigcptrHidden uintptr +type Hidden interface { + Swigcptr() uintptr; +} +func (p SwigcptrHidden) Swigcptr() uintptr { + return uintptr(p) +} + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/naturalvar_onoff.go b/Examples/test-suite/go/naturalvar_onoff.go new file mode 100644 index 000000000..9d5490344 --- /dev/null +++ b/Examples/test-suite/go/naturalvar_onoff.go @@ -0,0 +1,383 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../naturalvar_onoff.i + +package naturalvar_onoff + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrMember1 uintptr + +func (p SwigcptrMember1) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrMember1) SwigIsMember1() { +} + +var _wrap_new_Member1 unsafe.Pointer + +func _swig_wrap_new_Member1() (base SwigcptrMember1) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Member1, _swig_p) + return +} + +func NewMember1() (_swig_ret Member1) { + return _swig_wrap_new_Member1() +} + +var _wrap_delete_Member1 unsafe.Pointer + +func _swig_wrap_delete_Member1(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Member1, _swig_p) + return +} + +func DeleteMember1(arg1 Member1) { + _swig_wrap_delete_Member1(arg1.Swigcptr()) +} + +type Member1 interface { + Swigcptr() uintptr + SwigIsMember1() +} + +type SwigcptrMember2 uintptr + +func (p SwigcptrMember2) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrMember2) SwigIsMember2() { +} + +var _wrap_new_Member2 unsafe.Pointer + +func _swig_wrap_new_Member2() (base SwigcptrMember2) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Member2, _swig_p) + return +} + +func NewMember2() (_swig_ret Member2) { + return _swig_wrap_new_Member2() +} + +var _wrap_delete_Member2 unsafe.Pointer + +func _swig_wrap_delete_Member2(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Member2, _swig_p) + return +} + +func DeleteMember2(arg1 Member2) { + _swig_wrap_delete_Member2(arg1.Swigcptr()) +} + +type Member2 interface { + Swigcptr() uintptr + SwigIsMember2() +} + +type SwigcptrMember3 uintptr + +func (p SwigcptrMember3) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrMember3) SwigIsMember3() { +} + +var _wrap_new_Member3 unsafe.Pointer + +func _swig_wrap_new_Member3() (base SwigcptrMember3) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Member3, _swig_p) + return +} + +func NewMember3() (_swig_ret Member3) { + return _swig_wrap_new_Member3() +} + +var _wrap_delete_Member3 unsafe.Pointer + +func _swig_wrap_delete_Member3(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Member3, _swig_p) + return +} + +func DeleteMember3(arg1 Member3) { + _swig_wrap_delete_Member3(arg1.Swigcptr()) +} + +type Member3 interface { + Swigcptr() uintptr + SwigIsMember3() +} + +type SwigcptrMember4 uintptr + +func (p SwigcptrMember4) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrMember4) SwigIsMember4() { +} + +var _wrap_new_Member4 unsafe.Pointer + +func _swig_wrap_new_Member4() (base SwigcptrMember4) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Member4, _swig_p) + return +} + +func NewMember4() (_swig_ret Member4) { + return _swig_wrap_new_Member4() +} + +var _wrap_delete_Member4 unsafe.Pointer + +func _swig_wrap_delete_Member4(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Member4, _swig_p) + return +} + +func DeleteMember4(arg1 Member4) { + _swig_wrap_delete_Member4(arg1.Swigcptr()) +} + +type Member4 interface { + Swigcptr() uintptr + SwigIsMember4() +} + +type SwigcptrVars uintptr + +func (p SwigcptrVars) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrVars) SwigIsVars() { +} + +var _wrap_Vars_member1On_set unsafe.Pointer + +func _swig_wrap_Vars_member1On_set(base SwigcptrVars, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Vars_member1On_set, _swig_p) + return +} + +func (arg1 SwigcptrVars) SetMember1On(arg2 Member1) { + _swig_wrap_Vars_member1On_set(arg1, arg2.Swigcptr()) +} + +var _wrap_Vars_member1On_get unsafe.Pointer + +func _swig_wrap_Vars_member1On_get(base SwigcptrVars) (_ SwigcptrMember1) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Vars_member1On_get, _swig_p) + return +} + +func (arg1 SwigcptrVars) GetMember1On() (_swig_ret Member1) { + return _swig_wrap_Vars_member1On_get(arg1) +} + +var _wrap_Vars_member2Off_set unsafe.Pointer + +func _swig_wrap_Vars_member2Off_set(base SwigcptrVars, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Vars_member2Off_set, _swig_p) + return +} + +func (arg1 SwigcptrVars) SetMember2Off(arg2 Member2) { + _swig_wrap_Vars_member2Off_set(arg1, arg2.Swigcptr()) +} + +var _wrap_Vars_member2Off_get unsafe.Pointer + +func _swig_wrap_Vars_member2Off_get(base SwigcptrVars) (_ SwigcptrMember2) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Vars_member2Off_get, _swig_p) + return +} + +func (arg1 SwigcptrVars) GetMember2Off() (_swig_ret Member2) { + return _swig_wrap_Vars_member2Off_get(arg1) +} + +var _wrap_Vars_member3Off_set unsafe.Pointer + +func _swig_wrap_Vars_member3Off_set(base SwigcptrVars, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Vars_member3Off_set, _swig_p) + return +} + +func (arg1 SwigcptrVars) SetMember3Off(arg2 Member3) { + _swig_wrap_Vars_member3Off_set(arg1, arg2.Swigcptr()) +} + +var _wrap_Vars_member3Off_get unsafe.Pointer + +func _swig_wrap_Vars_member3Off_get(base SwigcptrVars) (_ SwigcptrMember3) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Vars_member3Off_get, _swig_p) + return +} + +func (arg1 SwigcptrVars) GetMember3Off() (_swig_ret Member3) { + return _swig_wrap_Vars_member3Off_get(arg1) +} + +var _wrap_Vars_member3On_set unsafe.Pointer + +func _swig_wrap_Vars_member3On_set(base SwigcptrVars, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Vars_member3On_set, _swig_p) + return +} + +func (arg1 SwigcptrVars) SetMember3On(arg2 Member3) { + _swig_wrap_Vars_member3On_set(arg1, arg2.Swigcptr()) +} + +var _wrap_Vars_member3On_get unsafe.Pointer + +func _swig_wrap_Vars_member3On_get(base SwigcptrVars) (_ SwigcptrMember3) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Vars_member3On_get, _swig_p) + return +} + +func (arg1 SwigcptrVars) GetMember3On() (_swig_ret Member3) { + return _swig_wrap_Vars_member3On_get(arg1) +} + +var _wrap_Vars_member4Off_set unsafe.Pointer + +func _swig_wrap_Vars_member4Off_set(base SwigcptrVars, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Vars_member4Off_set, _swig_p) + return +} + +func (arg1 SwigcptrVars) SetMember4Off(arg2 Member4) { + _swig_wrap_Vars_member4Off_set(arg1, arg2.Swigcptr()) +} + +var _wrap_Vars_member4Off_get unsafe.Pointer + +func _swig_wrap_Vars_member4Off_get(base SwigcptrVars) (_ SwigcptrMember4) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Vars_member4Off_get, _swig_p) + return +} + +func (arg1 SwigcptrVars) GetMember4Off() (_swig_ret Member4) { + return _swig_wrap_Vars_member4Off_get(arg1) +} + +var _wrap_Vars_member4On_set unsafe.Pointer + +func _swig_wrap_Vars_member4On_set(base SwigcptrVars, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Vars_member4On_set, _swig_p) + return +} + +func (arg1 SwigcptrVars) SetMember4On(arg2 Member4) { + _swig_wrap_Vars_member4On_set(arg1, arg2.Swigcptr()) +} + +var _wrap_Vars_member4On_get unsafe.Pointer + +func _swig_wrap_Vars_member4On_get(base SwigcptrVars) (_ SwigcptrMember4) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Vars_member4On_get, _swig_p) + return +} + +func (arg1 SwigcptrVars) GetMember4On() (_swig_ret Member4) { + return _swig_wrap_Vars_member4On_get(arg1) +} + +var _wrap_new_Vars unsafe.Pointer + +func _swig_wrap_new_Vars() (base SwigcptrVars) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Vars, _swig_p) + return +} + +func NewVars() (_swig_ret Vars) { + return _swig_wrap_new_Vars() +} + +var _wrap_delete_Vars unsafe.Pointer + +func _swig_wrap_delete_Vars(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Vars, _swig_p) + return +} + +func DeleteVars(arg1 Vars) { + _swig_wrap_delete_Vars(arg1.Swigcptr()) +} + +type Vars interface { + Swigcptr() uintptr + SwigIsVars() + SetMember1On(arg2 Member1) + GetMember1On() (_swig_ret Member1) + SetMember2Off(arg2 Member2) + GetMember2Off() (_swig_ret Member2) + SetMember3Off(arg2 Member3) + GetMember3Off() (_swig_ret Member3) + SetMember3On(arg2 Member3) + GetMember3On() (_swig_ret Member3) + SetMember4Off(arg2 Member4) + GetMember4Off() (_swig_ret Member4) + SetMember4On(arg2 Member4) + GetMember4On() (_swig_ret Member4) +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/naturalvar_runme b/Examples/test-suite/go/naturalvar_runme new file mode 100755 index 000000000..799b5ff44 Binary files /dev/null and b/Examples/test-suite/go/naturalvar_runme differ diff --git a/Examples/test-suite/go/nested.go b/Examples/test-suite/go/nested.go new file mode 100644 index 000000000..4ec3692d1 --- /dev/null +++ b/Examples/test-suite/go/nested.go @@ -0,0 +1,910 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../nested.i + +package nested + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrTestStruct uintptr + +func (p SwigcptrTestStruct) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrTestStruct) SwigIsTestStruct() { +} + +var _wrap_TestStruct_a_set unsafe.Pointer + +func _swig_wrap_TestStruct_a_set(base SwigcptrTestStruct, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_TestStruct_a_set, _swig_p) + return +} + +func (arg1 SwigcptrTestStruct) SetA(arg2 int) { + _swig_wrap_TestStruct_a_set(arg1, arg2) +} + +var _wrap_TestStruct_a_get unsafe.Pointer + +func _swig_wrap_TestStruct_a_get(base SwigcptrTestStruct) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_TestStruct_a_get, _swig_p) + return +} + +func (arg1 SwigcptrTestStruct) GetA() (_swig_ret int) { + return _swig_wrap_TestStruct_a_get(arg1) +} + +var _wrap_new_TestStruct unsafe.Pointer + +func _swig_wrap_new_TestStruct() (base SwigcptrTestStruct) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_TestStruct, _swig_p) + return +} + +func NewTestStruct() (_swig_ret TestStruct) { + return _swig_wrap_new_TestStruct() +} + +var _wrap_delete_TestStruct unsafe.Pointer + +func _swig_wrap_delete_TestStruct(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_TestStruct, _swig_p) + return +} + +func DeleteTestStruct(arg1 TestStruct) { + _swig_wrap_delete_TestStruct(arg1.Swigcptr()) +} + +type TestStruct interface { + Swigcptr() uintptr + SwigIsTestStruct() + SetA(arg2 int) + GetA() (_swig_ret int) +} + +type SwigcptrOuterStructNamed uintptr + +func (p SwigcptrOuterStructNamed) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrOuterStructNamed) SwigIsOuterStructNamed() { +} + +var _wrap_OuterStructNamed_inner_struct_named_set unsafe.Pointer + +func _swig_wrap_OuterStructNamed_inner_struct_named_set(base SwigcptrOuterStructNamed, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_OuterStructNamed_inner_struct_named_set, _swig_p) + return +} + +func (arg1 SwigcptrOuterStructNamed) SetInner_struct_named(arg2 InnerStructNamed) { + _swig_wrap_OuterStructNamed_inner_struct_named_set(arg1, arg2.Swigcptr()) +} + +var _wrap_OuterStructNamed_inner_struct_named_get unsafe.Pointer + +func _swig_wrap_OuterStructNamed_inner_struct_named_get(base SwigcptrOuterStructNamed) (_ SwigcptrInnerStructNamed) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_OuterStructNamed_inner_struct_named_get, _swig_p) + return +} + +func (arg1 SwigcptrOuterStructNamed) GetInner_struct_named() (_swig_ret InnerStructNamed) { + return _swig_wrap_OuterStructNamed_inner_struct_named_get(arg1) +} + +var _wrap_OuterStructNamed_inner_union_named_set unsafe.Pointer + +func _swig_wrap_OuterStructNamed_inner_union_named_set(base SwigcptrOuterStructNamed, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_OuterStructNamed_inner_union_named_set, _swig_p) + return +} + +func (arg1 SwigcptrOuterStructNamed) SetInner_union_named(arg2 InnerUnionNamed) { + _swig_wrap_OuterStructNamed_inner_union_named_set(arg1, arg2.Swigcptr()) +} + +var _wrap_OuterStructNamed_inner_union_named_get unsafe.Pointer + +func _swig_wrap_OuterStructNamed_inner_union_named_get(base SwigcptrOuterStructNamed) (_ SwigcptrInnerUnionNamed) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_OuterStructNamed_inner_union_named_get, _swig_p) + return +} + +func (arg1 SwigcptrOuterStructNamed) GetInner_union_named() (_swig_ret InnerUnionNamed) { + return _swig_wrap_OuterStructNamed_inner_union_named_get(arg1) +} + +var _wrap_new_OuterStructNamed unsafe.Pointer + +func _swig_wrap_new_OuterStructNamed() (base SwigcptrOuterStructNamed) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_OuterStructNamed, _swig_p) + return +} + +func NewOuterStructNamed() (_swig_ret OuterStructNamed) { + return _swig_wrap_new_OuterStructNamed() +} + +var _wrap_delete_OuterStructNamed unsafe.Pointer + +func _swig_wrap_delete_OuterStructNamed(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_OuterStructNamed, _swig_p) + return +} + +func DeleteOuterStructNamed(arg1 OuterStructNamed) { + _swig_wrap_delete_OuterStructNamed(arg1.Swigcptr()) +} + +type OuterStructNamed interface { + Swigcptr() uintptr + SwigIsOuterStructNamed() + SetInner_struct_named(arg2 InnerStructNamed) + GetInner_struct_named() (_swig_ret InnerStructNamed) + SetInner_union_named(arg2 InnerUnionNamed) + GetInner_union_named() (_swig_ret InnerUnionNamed) +} + +type SwigcptrInnerStructNamed uintptr + +func (p SwigcptrInnerStructNamed) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrInnerStructNamed) SwigIsInnerStructNamed() { +} + +var _wrap_InnerStructNamed_dd_set unsafe.Pointer + +func _swig_wrap_InnerStructNamed_dd_set(base SwigcptrInnerStructNamed, _ float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_InnerStructNamed_dd_set, _swig_p) + return +} + +func (arg1 SwigcptrInnerStructNamed) SetDd(arg2 float64) { + _swig_wrap_InnerStructNamed_dd_set(arg1, arg2) +} + +var _wrap_InnerStructNamed_dd_get unsafe.Pointer + +func _swig_wrap_InnerStructNamed_dd_get(base SwigcptrInnerStructNamed) (_ float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_InnerStructNamed_dd_get, _swig_p) + return +} + +func (arg1 SwigcptrInnerStructNamed) GetDd() (_swig_ret float64) { + return _swig_wrap_InnerStructNamed_dd_get(arg1) +} + +var _wrap_new_InnerStructNamed unsafe.Pointer + +func _swig_wrap_new_InnerStructNamed() (base SwigcptrInnerStructNamed) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_InnerStructNamed, _swig_p) + return +} + +func NewInnerStructNamed() (_swig_ret InnerStructNamed) { + return _swig_wrap_new_InnerStructNamed() +} + +var _wrap_delete_InnerStructNamed unsafe.Pointer + +func _swig_wrap_delete_InnerStructNamed(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_InnerStructNamed, _swig_p) + return +} + +func DeleteInnerStructNamed(arg1 InnerStructNamed) { + _swig_wrap_delete_InnerStructNamed(arg1.Swigcptr()) +} + +type InnerStructNamed interface { + Swigcptr() uintptr + SwigIsInnerStructNamed() + SetDd(arg2 float64) + GetDd() (_swig_ret float64) +} + +type SwigcptrInnerUnionNamed uintptr + +func (p SwigcptrInnerUnionNamed) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrInnerUnionNamed) SwigIsInnerUnionNamed() { +} + +var _wrap_InnerUnionNamed_ee_set unsafe.Pointer + +func _swig_wrap_InnerUnionNamed_ee_set(base SwigcptrInnerUnionNamed, _ float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_InnerUnionNamed_ee_set, _swig_p) + return +} + +func (arg1 SwigcptrInnerUnionNamed) SetEe(arg2 float64) { + _swig_wrap_InnerUnionNamed_ee_set(arg1, arg2) +} + +var _wrap_InnerUnionNamed_ee_get unsafe.Pointer + +func _swig_wrap_InnerUnionNamed_ee_get(base SwigcptrInnerUnionNamed) (_ float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_InnerUnionNamed_ee_get, _swig_p) + return +} + +func (arg1 SwigcptrInnerUnionNamed) GetEe() (_swig_ret float64) { + return _swig_wrap_InnerUnionNamed_ee_get(arg1) +} + +var _wrap_InnerUnionNamed_ff_set unsafe.Pointer + +func _swig_wrap_InnerUnionNamed_ff_set(base SwigcptrInnerUnionNamed, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_InnerUnionNamed_ff_set, _swig_p) + return +} + +func (arg1 SwigcptrInnerUnionNamed) SetFf(arg2 int) { + _swig_wrap_InnerUnionNamed_ff_set(arg1, arg2) +} + +var _wrap_InnerUnionNamed_ff_get unsafe.Pointer + +func _swig_wrap_InnerUnionNamed_ff_get(base SwigcptrInnerUnionNamed) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_InnerUnionNamed_ff_get, _swig_p) + return +} + +func (arg1 SwigcptrInnerUnionNamed) GetFf() (_swig_ret int) { + return _swig_wrap_InnerUnionNamed_ff_get(arg1) +} + +var _wrap_new_InnerUnionNamed unsafe.Pointer + +func _swig_wrap_new_InnerUnionNamed() (base SwigcptrInnerUnionNamed) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_InnerUnionNamed, _swig_p) + return +} + +func NewInnerUnionNamed() (_swig_ret InnerUnionNamed) { + return _swig_wrap_new_InnerUnionNamed() +} + +var _wrap_delete_InnerUnionNamed unsafe.Pointer + +func _swig_wrap_delete_InnerUnionNamed(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_InnerUnionNamed, _swig_p) + return +} + +func DeleteInnerUnionNamed(arg1 InnerUnionNamed) { + _swig_wrap_delete_InnerUnionNamed(arg1.Swigcptr()) +} + +type InnerUnionNamed interface { + Swigcptr() uintptr + SwigIsInnerUnionNamed() + SetEe(arg2 float64) + GetEe() (_swig_ret float64) + SetFf(arg2 int) + GetFf() (_swig_ret int) +} + +type SwigcptrOuterStructUnnamed uintptr + +func (p SwigcptrOuterStructUnnamed) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrOuterStructUnnamed) SwigIsOuterStructUnnamed() { +} + +var _wrap_OuterStructUnnamed_inner_struct_unnamed_get unsafe.Pointer + +func _swig_wrap_OuterStructUnnamed_inner_struct_unnamed_get(base SwigcptrOuterStructUnnamed) (_ SwigcptrOuterStructUnnamed_inner_struct_unnamed) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_OuterStructUnnamed_inner_struct_unnamed_get, _swig_p) + return +} + +func (arg1 SwigcptrOuterStructUnnamed) GetInner_struct_unnamed() (_swig_ret OuterStructUnnamed_inner_struct_unnamed) { + return _swig_wrap_OuterStructUnnamed_inner_struct_unnamed_get(arg1) +} + +var _wrap_OuterStructUnnamed_inner_union_unnamed_get unsafe.Pointer + +func _swig_wrap_OuterStructUnnamed_inner_union_unnamed_get(base SwigcptrOuterStructUnnamed) (_ SwigcptrOuterStructUnnamed_inner_union_unnamed) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_OuterStructUnnamed_inner_union_unnamed_get, _swig_p) + return +} + +func (arg1 SwigcptrOuterStructUnnamed) GetInner_union_unnamed() (_swig_ret OuterStructUnnamed_inner_union_unnamed) { + return _swig_wrap_OuterStructUnnamed_inner_union_unnamed_get(arg1) +} + +var _wrap_new_OuterStructUnnamed unsafe.Pointer + +func _swig_wrap_new_OuterStructUnnamed() (base SwigcptrOuterStructUnnamed) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_OuterStructUnnamed, _swig_p) + return +} + +func NewOuterStructUnnamed() (_swig_ret OuterStructUnnamed) { + return _swig_wrap_new_OuterStructUnnamed() +} + +var _wrap_delete_OuterStructUnnamed unsafe.Pointer + +func _swig_wrap_delete_OuterStructUnnamed(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_OuterStructUnnamed, _swig_p) + return +} + +func DeleteOuterStructUnnamed(arg1 OuterStructUnnamed) { + _swig_wrap_delete_OuterStructUnnamed(arg1.Swigcptr()) +} + +type OuterStructUnnamed interface { + Swigcptr() uintptr + SwigIsOuterStructUnnamed() + GetInner_struct_unnamed() (_swig_ret OuterStructUnnamed_inner_struct_unnamed) + GetInner_union_unnamed() (_swig_ret OuterStructUnnamed_inner_union_unnamed) +} + +type SwigcptrOuterStructUnnamed_inner_union_unnamed uintptr + +func (p SwigcptrOuterStructUnnamed_inner_union_unnamed) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrOuterStructUnnamed_inner_union_unnamed) SwigIsOuterStructUnnamed_inner_union_unnamed() { +} + +var _wrap_OuterStructUnnamed_inner_union_unnamed_yy_set unsafe.Pointer + +func _swig_wrap_OuterStructUnnamed_inner_union_unnamed_yy_set(base SwigcptrOuterStructUnnamed_inner_union_unnamed, _ float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_OuterStructUnnamed_inner_union_unnamed_yy_set, _swig_p) + return +} + +func (arg1 SwigcptrOuterStructUnnamed_inner_union_unnamed) SetYy(arg2 float64) { + _swig_wrap_OuterStructUnnamed_inner_union_unnamed_yy_set(arg1, arg2) +} + +var _wrap_OuterStructUnnamed_inner_union_unnamed_yy_get unsafe.Pointer + +func _swig_wrap_OuterStructUnnamed_inner_union_unnamed_yy_get(base SwigcptrOuterStructUnnamed_inner_union_unnamed) (_ float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_OuterStructUnnamed_inner_union_unnamed_yy_get, _swig_p) + return +} + +func (arg1 SwigcptrOuterStructUnnamed_inner_union_unnamed) GetYy() (_swig_ret float64) { + return _swig_wrap_OuterStructUnnamed_inner_union_unnamed_yy_get(arg1) +} + +var _wrap_OuterStructUnnamed_inner_union_unnamed_zz_set unsafe.Pointer + +func _swig_wrap_OuterStructUnnamed_inner_union_unnamed_zz_set(base SwigcptrOuterStructUnnamed_inner_union_unnamed, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_OuterStructUnnamed_inner_union_unnamed_zz_set, _swig_p) + return +} + +func (arg1 SwigcptrOuterStructUnnamed_inner_union_unnamed) SetZz(arg2 int) { + _swig_wrap_OuterStructUnnamed_inner_union_unnamed_zz_set(arg1, arg2) +} + +var _wrap_OuterStructUnnamed_inner_union_unnamed_zz_get unsafe.Pointer + +func _swig_wrap_OuterStructUnnamed_inner_union_unnamed_zz_get(base SwigcptrOuterStructUnnamed_inner_union_unnamed) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_OuterStructUnnamed_inner_union_unnamed_zz_get, _swig_p) + return +} + +func (arg1 SwigcptrOuterStructUnnamed_inner_union_unnamed) GetZz() (_swig_ret int) { + return _swig_wrap_OuterStructUnnamed_inner_union_unnamed_zz_get(arg1) +} + +var _wrap_new_OuterStructUnnamed_inner_union_unnamed unsafe.Pointer + +func _swig_wrap_new_OuterStructUnnamed_inner_union_unnamed() (base SwigcptrOuterStructUnnamed_inner_union_unnamed) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_OuterStructUnnamed_inner_union_unnamed, _swig_p) + return +} + +func NewOuterStructUnnamed_inner_union_unnamed() (_swig_ret OuterStructUnnamed_inner_union_unnamed) { + return _swig_wrap_new_OuterStructUnnamed_inner_union_unnamed() +} + +var _wrap_delete_OuterStructUnnamed_inner_union_unnamed unsafe.Pointer + +func _swig_wrap_delete_OuterStructUnnamed_inner_union_unnamed(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_OuterStructUnnamed_inner_union_unnamed, _swig_p) + return +} + +func DeleteOuterStructUnnamed_inner_union_unnamed(arg1 OuterStructUnnamed_inner_union_unnamed) { + _swig_wrap_delete_OuterStructUnnamed_inner_union_unnamed(arg1.Swigcptr()) +} + +type OuterStructUnnamed_inner_union_unnamed interface { + Swigcptr() uintptr + SwigIsOuterStructUnnamed_inner_union_unnamed() + SetYy(arg2 float64) + GetYy() (_swig_ret float64) + SetZz(arg2 int) + GetZz() (_swig_ret int) +} + +type SwigcptrOuterStructUnnamed_inner_struct_unnamed uintptr + +func (p SwigcptrOuterStructUnnamed_inner_struct_unnamed) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrOuterStructUnnamed_inner_struct_unnamed) SwigIsOuterStructUnnamed_inner_struct_unnamed() { +} + +var _wrap_OuterStructUnnamed_inner_struct_unnamed_xx_set unsafe.Pointer + +func _swig_wrap_OuterStructUnnamed_inner_struct_unnamed_xx_set(base SwigcptrOuterStructUnnamed_inner_struct_unnamed, _ float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_OuterStructUnnamed_inner_struct_unnamed_xx_set, _swig_p) + return +} + +func (arg1 SwigcptrOuterStructUnnamed_inner_struct_unnamed) SetXx(arg2 float64) { + _swig_wrap_OuterStructUnnamed_inner_struct_unnamed_xx_set(arg1, arg2) +} + +var _wrap_OuterStructUnnamed_inner_struct_unnamed_xx_get unsafe.Pointer + +func _swig_wrap_OuterStructUnnamed_inner_struct_unnamed_xx_get(base SwigcptrOuterStructUnnamed_inner_struct_unnamed) (_ float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_OuterStructUnnamed_inner_struct_unnamed_xx_get, _swig_p) + return +} + +func (arg1 SwigcptrOuterStructUnnamed_inner_struct_unnamed) GetXx() (_swig_ret float64) { + return _swig_wrap_OuterStructUnnamed_inner_struct_unnamed_xx_get(arg1) +} + +var _wrap_new_OuterStructUnnamed_inner_struct_unnamed unsafe.Pointer + +func _swig_wrap_new_OuterStructUnnamed_inner_struct_unnamed() (base SwigcptrOuterStructUnnamed_inner_struct_unnamed) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_OuterStructUnnamed_inner_struct_unnamed, _swig_p) + return +} + +func NewOuterStructUnnamed_inner_struct_unnamed() (_swig_ret OuterStructUnnamed_inner_struct_unnamed) { + return _swig_wrap_new_OuterStructUnnamed_inner_struct_unnamed() +} + +var _wrap_delete_OuterStructUnnamed_inner_struct_unnamed unsafe.Pointer + +func _swig_wrap_delete_OuterStructUnnamed_inner_struct_unnamed(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_OuterStructUnnamed_inner_struct_unnamed, _swig_p) + return +} + +func DeleteOuterStructUnnamed_inner_struct_unnamed(arg1 OuterStructUnnamed_inner_struct_unnamed) { + _swig_wrap_delete_OuterStructUnnamed_inner_struct_unnamed(arg1.Swigcptr()) +} + +type OuterStructUnnamed_inner_struct_unnamed interface { + Swigcptr() uintptr + SwigIsOuterStructUnnamed_inner_struct_unnamed() + SetXx(arg2 float64) + GetXx() (_swig_ret float64) +} + +type SwigcptrOuterStruct uintptr + +func (p SwigcptrOuterStruct) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrOuterStruct) SwigIsOuterStruct() { +} + +var _wrap_OuterStruct_EmbeddedUnion_get unsafe.Pointer + +func _swig_wrap_OuterStruct_EmbeddedUnion_get(base SwigcptrOuterStruct) (_ SwigcptrOuterStruct_EmbeddedUnion) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_OuterStruct_EmbeddedUnion_get, _swig_p) + return +} + +func (arg1 SwigcptrOuterStruct) GetEmbeddedUnion() (_swig_ret OuterStruct_EmbeddedUnion) { + return _swig_wrap_OuterStruct_EmbeddedUnion_get(arg1) +} + +var _wrap_new_OuterStruct unsafe.Pointer + +func _swig_wrap_new_OuterStruct() (base SwigcptrOuterStruct) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_OuterStruct, _swig_p) + return +} + +func NewOuterStruct() (_swig_ret OuterStruct) { + return _swig_wrap_new_OuterStruct() +} + +var _wrap_delete_OuterStruct unsafe.Pointer + +func _swig_wrap_delete_OuterStruct(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_OuterStruct, _swig_p) + return +} + +func DeleteOuterStruct(arg1 OuterStruct) { + _swig_wrap_delete_OuterStruct(arg1.Swigcptr()) +} + +type OuterStruct interface { + Swigcptr() uintptr + SwigIsOuterStruct() + GetEmbeddedUnion() (_swig_ret OuterStruct_EmbeddedUnion) +} + +type SwigcptrOuterStruct_EmbeddedUnion uintptr + +func (p SwigcptrOuterStruct_EmbeddedUnion) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrOuterStruct_EmbeddedUnion) SwigIsOuterStruct_EmbeddedUnion() { +} + +var _wrap_OuterStruct_EmbeddedUnion_OuterNestedStruct_get unsafe.Pointer + +func _swig_wrap_OuterStruct_EmbeddedUnion_OuterNestedStruct_get(base SwigcptrOuterStruct_EmbeddedUnion) (_ SwigcptrOuter_nested_struct) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_OuterStruct_EmbeddedUnion_OuterNestedStruct_get, _swig_p) + return +} + +func (arg1 SwigcptrOuterStruct_EmbeddedUnion) GetOuterNestedStruct() (_swig_ret Outer_nested_struct) { + return _swig_wrap_OuterStruct_EmbeddedUnion_OuterNestedStruct_get(arg1) +} + +var _wrap_new_OuterStruct_EmbeddedUnion unsafe.Pointer + +func _swig_wrap_new_OuterStruct_EmbeddedUnion() (base SwigcptrOuterStruct_EmbeddedUnion) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_OuterStruct_EmbeddedUnion, _swig_p) + return +} + +func NewOuterStruct_EmbeddedUnion() (_swig_ret OuterStruct_EmbeddedUnion) { + return _swig_wrap_new_OuterStruct_EmbeddedUnion() +} + +var _wrap_delete_OuterStruct_EmbeddedUnion unsafe.Pointer + +func _swig_wrap_delete_OuterStruct_EmbeddedUnion(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_OuterStruct_EmbeddedUnion, _swig_p) + return +} + +func DeleteOuterStruct_EmbeddedUnion(arg1 OuterStruct_EmbeddedUnion) { + _swig_wrap_delete_OuterStruct_EmbeddedUnion(arg1.Swigcptr()) +} + +type OuterStruct_EmbeddedUnion interface { + Swigcptr() uintptr + SwigIsOuterStruct_EmbeddedUnion() + GetOuterNestedStruct() (_swig_ret Outer_nested_struct) +} + +type SwigcptrInner_nested_union uintptr + +func (p SwigcptrInner_nested_union) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrInner_nested_union) SwigIsInner_nested_union() { +} + +const BAD_STYLE int = 1 +var _wrap_inner_nested_union_red_set unsafe.Pointer + +func _swig_wrap_inner_nested_union_red_set(base SwigcptrInner_nested_union, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_inner_nested_union_red_set, _swig_p) + return +} + +func (arg1 SwigcptrInner_nested_union) SetRed(arg2 int) { + _swig_wrap_inner_nested_union_red_set(arg1, arg2) +} + +var _wrap_inner_nested_union_red_get unsafe.Pointer + +func _swig_wrap_inner_nested_union_red_get(base SwigcptrInner_nested_union) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_inner_nested_union_red_get, _swig_p) + return +} + +func (arg1 SwigcptrInner_nested_union) GetRed() (_swig_ret int) { + return _swig_wrap_inner_nested_union_red_get(arg1) +} + +var _wrap_inner_nested_union_green_set unsafe.Pointer + +func _swig_wrap_inner_nested_union_green_set(base SwigcptrInner_nested_union, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_inner_nested_union_green_set, _swig_p) + return +} + +func (arg1 SwigcptrInner_nested_union) SetGreen(arg2 TestStruct) { + _swig_wrap_inner_nested_union_green_set(arg1, arg2.Swigcptr()) +} + +var _wrap_inner_nested_union_green_get unsafe.Pointer + +func _swig_wrap_inner_nested_union_green_get(base SwigcptrInner_nested_union) (_ SwigcptrTestStruct) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_inner_nested_union_green_get, _swig_p) + return +} + +func (arg1 SwigcptrInner_nested_union) GetGreen() (_swig_ret TestStruct) { + return _swig_wrap_inner_nested_union_green_get(arg1) +} + +var _wrap_new_inner_nested_union unsafe.Pointer + +func _swig_wrap_new_inner_nested_union() (base SwigcptrInner_nested_union) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_inner_nested_union, _swig_p) + return +} + +func NewInner_nested_union() (_swig_ret Inner_nested_union) { + return _swig_wrap_new_inner_nested_union() +} + +var _wrap_delete_inner_nested_union unsafe.Pointer + +func _swig_wrap_delete_inner_nested_union(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_inner_nested_union, _swig_p) + return +} + +func DeleteInner_nested_union(arg1 Inner_nested_union) { + _swig_wrap_delete_inner_nested_union(arg1.Swigcptr()) +} + +type Inner_nested_union interface { + Swigcptr() uintptr + SwigIsInner_nested_union() + SetRed(arg2 int) + GetRed() (_swig_ret int) + SetGreen(arg2 TestStruct) + GetGreen() (_swig_ret TestStruct) +} + +type SwigcptrInner_nested_struct uintptr + +func (p SwigcptrInner_nested_struct) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrInner_nested_struct) SwigIsInner_nested_struct() { +} + +var _wrap_inner_nested_struct_blue_set unsafe.Pointer + +func _swig_wrap_inner_nested_struct_blue_set(base SwigcptrInner_nested_struct, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_inner_nested_struct_blue_set, _swig_p) + return +} + +func (arg1 SwigcptrInner_nested_struct) SetBlue(arg2 int) { + _swig_wrap_inner_nested_struct_blue_set(arg1, arg2) +} + +var _wrap_inner_nested_struct_blue_get unsafe.Pointer + +func _swig_wrap_inner_nested_struct_blue_get(base SwigcptrInner_nested_struct) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_inner_nested_struct_blue_get, _swig_p) + return +} + +func (arg1 SwigcptrInner_nested_struct) GetBlue() (_swig_ret int) { + return _swig_wrap_inner_nested_struct_blue_get(arg1) +} + +var _wrap_new_inner_nested_struct unsafe.Pointer + +func _swig_wrap_new_inner_nested_struct() (base SwigcptrInner_nested_struct) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_inner_nested_struct, _swig_p) + return +} + +func NewInner_nested_struct() (_swig_ret Inner_nested_struct) { + return _swig_wrap_new_inner_nested_struct() +} + +var _wrap_delete_inner_nested_struct unsafe.Pointer + +func _swig_wrap_delete_inner_nested_struct(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_inner_nested_struct, _swig_p) + return +} + +func DeleteInner_nested_struct(arg1 Inner_nested_struct) { + _swig_wrap_delete_inner_nested_struct(arg1.Swigcptr()) +} + +type Inner_nested_struct interface { + Swigcptr() uintptr + SwigIsInner_nested_struct() + SetBlue(arg2 int) + GetBlue() (_swig_ret int) +} + +type SwigcptrOuter_nested_struct uintptr + +func (p SwigcptrOuter_nested_struct) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrOuter_nested_struct) SwigIsOuter_nested_struct() { +} + +var _wrap_outer_nested_struct_InnerNestedUnion_set unsafe.Pointer + +func _swig_wrap_outer_nested_struct_InnerNestedUnion_set(base SwigcptrOuter_nested_struct, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_outer_nested_struct_InnerNestedUnion_set, _swig_p) + return +} + +func (arg1 SwigcptrOuter_nested_struct) SetInnerNestedUnion(arg2 Inner_nested_union) { + _swig_wrap_outer_nested_struct_InnerNestedUnion_set(arg1, arg2.Swigcptr()) +} + +var _wrap_outer_nested_struct_InnerNestedUnion_get unsafe.Pointer + +func _swig_wrap_outer_nested_struct_InnerNestedUnion_get(base SwigcptrOuter_nested_struct) (_ SwigcptrInner_nested_union) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_outer_nested_struct_InnerNestedUnion_get, _swig_p) + return +} + +func (arg1 SwigcptrOuter_nested_struct) GetInnerNestedUnion() (_swig_ret Inner_nested_union) { + return _swig_wrap_outer_nested_struct_InnerNestedUnion_get(arg1) +} + +var _wrap_outer_nested_struct_InnerNestedStruct_set unsafe.Pointer + +func _swig_wrap_outer_nested_struct_InnerNestedStruct_set(base SwigcptrOuter_nested_struct, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_outer_nested_struct_InnerNestedStruct_set, _swig_p) + return +} + +func (arg1 SwigcptrOuter_nested_struct) SetInnerNestedStruct(arg2 Inner_nested_struct) { + _swig_wrap_outer_nested_struct_InnerNestedStruct_set(arg1, arg2.Swigcptr()) +} + +var _wrap_outer_nested_struct_InnerNestedStruct_get unsafe.Pointer + +func _swig_wrap_outer_nested_struct_InnerNestedStruct_get(base SwigcptrOuter_nested_struct) (_ SwigcptrInner_nested_struct) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_outer_nested_struct_InnerNestedStruct_get, _swig_p) + return +} + +func (arg1 SwigcptrOuter_nested_struct) GetInnerNestedStruct() (_swig_ret Inner_nested_struct) { + return _swig_wrap_outer_nested_struct_InnerNestedStruct_get(arg1) +} + +var _wrap_new_outer_nested_struct unsafe.Pointer + +func _swig_wrap_new_outer_nested_struct() (base SwigcptrOuter_nested_struct) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_outer_nested_struct, _swig_p) + return +} + +func NewOuter_nested_struct() (_swig_ret Outer_nested_struct) { + return _swig_wrap_new_outer_nested_struct() +} + +var _wrap_delete_outer_nested_struct unsafe.Pointer + +func _swig_wrap_delete_outer_nested_struct(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_outer_nested_struct, _swig_p) + return +} + +func DeleteOuter_nested_struct(arg1 Outer_nested_struct) { + _swig_wrap_delete_outer_nested_struct(arg1.Swigcptr()) +} + +type Outer_nested_struct interface { + Swigcptr() uintptr + SwigIsOuter_nested_struct() + SetInnerNestedUnion(arg2 Inner_nested_union) + GetInnerNestedUnion() (_swig_ret Inner_nested_union) + SetInnerNestedStruct(arg2 Inner_nested_struct) + GetInnerNestedStruct() (_swig_ret Inner_nested_struct) +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/nested_class.go b/Examples/test-suite/go/nested_class.go new file mode 100644 index 000000000..ac3656639 --- /dev/null +++ b/Examples/test-suite/go/nested_class.go @@ -0,0 +1,850 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../nested_class.i + +package nested_class + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrOuter uintptr + +func (p SwigcptrOuter) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrOuter) SwigIsOuter() { +} + +var _wrap_Outer_InnerClass2Instance_set unsafe.Pointer + +func _swig_wrap_Outer_InnerClass2Instance_set(base SwigcptrOuter, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Outer_InnerClass2Instance_set, _swig_p) + return +} + +func (arg1 SwigcptrOuter) SetInnerClass2Instance(arg2 Outer_InnerClass2) { + _swig_wrap_Outer_InnerClass2Instance_set(arg1, arg2.Swigcptr()) +} + +var _wrap_Outer_InnerClass2Instance_get unsafe.Pointer + +func _swig_wrap_Outer_InnerClass2Instance_get(base SwigcptrOuter) (_ SwigcptrOuter_InnerClass2) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Outer_InnerClass2Instance_get, _swig_p) + return +} + +func (arg1 SwigcptrOuter) GetInnerClass2Instance() (_swig_ret Outer_InnerClass2) { + return _swig_wrap_Outer_InnerClass2Instance_get(arg1) +} + +var _wrap_Outer_InnerStruct2Instance_set unsafe.Pointer + +func _swig_wrap_Outer_InnerStruct2Instance_set(base SwigcptrOuter, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Outer_InnerStruct2Instance_set, _swig_p) + return +} + +func (arg1 SwigcptrOuter) SetInnerStruct2Instance(arg2 Outer_InnerStruct2) { + _swig_wrap_Outer_InnerStruct2Instance_set(arg1, arg2.Swigcptr()) +} + +var _wrap_Outer_InnerStruct2Instance_get unsafe.Pointer + +func _swig_wrap_Outer_InnerStruct2Instance_get(base SwigcptrOuter) (_ SwigcptrOuter_InnerStruct2) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Outer_InnerStruct2Instance_get, _swig_p) + return +} + +func (arg1 SwigcptrOuter) GetInnerStruct2Instance() (_swig_ret Outer_InnerStruct2) { + return _swig_wrap_Outer_InnerStruct2Instance_get(arg1) +} + +var _wrap_Outer_InnerUnion2Instance_set unsafe.Pointer + +func _swig_wrap_Outer_InnerUnion2Instance_set(base SwigcptrOuter, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Outer_InnerUnion2Instance_set, _swig_p) + return +} + +func (arg1 SwigcptrOuter) SetInnerUnion2Instance(arg2 Outer_InnerUnion2) { + _swig_wrap_Outer_InnerUnion2Instance_set(arg1, arg2.Swigcptr()) +} + +var _wrap_Outer_InnerUnion2Instance_get unsafe.Pointer + +func _swig_wrap_Outer_InnerUnion2Instance_get(base SwigcptrOuter) (_ SwigcptrOuter_InnerUnion2) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Outer_InnerUnion2Instance_get, _swig_p) + return +} + +func (arg1 SwigcptrOuter) GetInnerUnion2Instance() (_swig_ret Outer_InnerUnion2) { + return _swig_wrap_Outer_InnerUnion2Instance_get(arg1) +} + +var _wrap_Outer_makeInnerStruct1 unsafe.Pointer + +func _swig_wrap_Outer_makeInnerStruct1(base SwigcptrOuter) (_ SwigcptrOuter_InnerStruct1) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Outer_makeInnerStruct1, _swig_p) + return +} + +func (arg1 SwigcptrOuter) MakeInnerStruct1() (_swig_ret Outer_InnerStruct1) { + return _swig_wrap_Outer_makeInnerStruct1(arg1) +} + +var _wrap_Outer_makeInnerClass1 unsafe.Pointer + +func _swig_wrap_Outer_makeInnerClass1(base SwigcptrOuter) (_ SwigcptrOuter_InnerClass1) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Outer_makeInnerClass1, _swig_p) + return +} + +func (arg1 SwigcptrOuter) MakeInnerClass1() (_swig_ret Outer_InnerClass1) { + return _swig_wrap_Outer_makeInnerClass1(arg1) +} + +var _wrap_Outer_makeInnerUnion1 unsafe.Pointer + +func _swig_wrap_Outer_makeInnerUnion1(base SwigcptrOuter) (_ SwigcptrOuter_InnerUnion1) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Outer_makeInnerUnion1, _swig_p) + return +} + +func (arg1 SwigcptrOuter) MakeInnerUnion1() (_swig_ret Outer_InnerUnion1) { + return _swig_wrap_Outer_makeInnerUnion1(arg1) +} + +var _wrap_Outer_makeInnerStruct2 unsafe.Pointer + +func _swig_wrap_Outer_makeInnerStruct2(base SwigcptrOuter) (_ SwigcptrOuter_InnerStruct2) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Outer_makeInnerStruct2, _swig_p) + return +} + +func (arg1 SwigcptrOuter) MakeInnerStruct2() (_swig_ret Outer_InnerStruct2) { + return _swig_wrap_Outer_makeInnerStruct2(arg1) +} + +var _wrap_Outer_makeInnerClass2 unsafe.Pointer + +func _swig_wrap_Outer_makeInnerClass2(base SwigcptrOuter) (_ SwigcptrOuter_InnerClass2) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Outer_makeInnerClass2, _swig_p) + return +} + +func (arg1 SwigcptrOuter) MakeInnerClass2() (_swig_ret Outer_InnerClass2) { + return _swig_wrap_Outer_makeInnerClass2(arg1) +} + +var _wrap_Outer_makeInnerUnion2 unsafe.Pointer + +func _swig_wrap_Outer_makeInnerUnion2(base SwigcptrOuter) (_ SwigcptrOuter_InnerUnion2) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Outer_makeInnerUnion2, _swig_p) + return +} + +func (arg1 SwigcptrOuter) MakeInnerUnion2() (_swig_ret Outer_InnerUnion2) { + return _swig_wrap_Outer_makeInnerUnion2(arg1) +} + +var _wrap_Outer_makeInnerStruct4Typedef unsafe.Pointer + +func _swig_wrap_Outer_makeInnerStruct4Typedef(base SwigcptrOuter) (_ SwigcptrOuter_InnerStruct4Typedef) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Outer_makeInnerStruct4Typedef, _swig_p) + return +} + +func (arg1 SwigcptrOuter) MakeInnerStruct4Typedef() (_swig_ret Outer_InnerStruct4Typedef) { + return _swig_wrap_Outer_makeInnerStruct4Typedef(arg1) +} + +var _wrap_Outer_makeInnerClass4Typedef unsafe.Pointer + +func _swig_wrap_Outer_makeInnerClass4Typedef(base SwigcptrOuter) (_ SwigcptrOuter_InnerClass4Typedef) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Outer_makeInnerClass4Typedef, _swig_p) + return +} + +func (arg1 SwigcptrOuter) MakeInnerClass4Typedef() (_swig_ret Outer_InnerClass4Typedef) { + return _swig_wrap_Outer_makeInnerClass4Typedef(arg1) +} + +var _wrap_Outer_makeInnerUnion4Typedef unsafe.Pointer + +func _swig_wrap_Outer_makeInnerUnion4Typedef(base SwigcptrOuter) (_ SwigcptrOuter_InnerUnion4Typedef) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Outer_makeInnerUnion4Typedef, _swig_p) + return +} + +func (arg1 SwigcptrOuter) MakeInnerUnion4Typedef() (_swig_ret Outer_InnerUnion4Typedef) { + return _swig_wrap_Outer_makeInnerUnion4Typedef(arg1) +} + +var _wrap_Outer_makeInnerStruct5 unsafe.Pointer + +func _swig_wrap_Outer_makeInnerStruct5(base SwigcptrOuter) (_ SwigcptrOuter_InnerStruct5) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Outer_makeInnerStruct5, _swig_p) + return +} + +func (arg1 SwigcptrOuter) MakeInnerStruct5() (_swig_ret Outer_InnerStruct5) { + return _swig_wrap_Outer_makeInnerStruct5(arg1) +} + +var _wrap_Outer_makeInnerClass5 unsafe.Pointer + +func _swig_wrap_Outer_makeInnerClass5(base SwigcptrOuter) (_ SwigcptrOuter_InnerClass5) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Outer_makeInnerClass5, _swig_p) + return +} + +func (arg1 SwigcptrOuter) MakeInnerClass5() (_swig_ret Outer_InnerClass5) { + return _swig_wrap_Outer_makeInnerClass5(arg1) +} + +var _wrap_Outer_makeInnerUnion5 unsafe.Pointer + +func _swig_wrap_Outer_makeInnerUnion5(base SwigcptrOuter) (_ SwigcptrOuter_InnerUnion5) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Outer_makeInnerUnion5, _swig_p) + return +} + +func (arg1 SwigcptrOuter) MakeInnerUnion5() (_swig_ret Outer_InnerUnion5) { + return _swig_wrap_Outer_makeInnerUnion5(arg1) +} + +var _wrap_Outer_makeInnerStruct5Typedef unsafe.Pointer + +func _swig_wrap_Outer_makeInnerStruct5Typedef(base SwigcptrOuter) (_ SwigcptrOuter_InnerStruct5) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Outer_makeInnerStruct5Typedef, _swig_p) + return +} + +func (arg1 SwigcptrOuter) MakeInnerStruct5Typedef() (_swig_ret Outer_InnerStruct5) { + return _swig_wrap_Outer_makeInnerStruct5Typedef(arg1) +} + +var _wrap_Outer_makeInnerClass5Typedef unsafe.Pointer + +func _swig_wrap_Outer_makeInnerClass5Typedef(base SwigcptrOuter) (_ SwigcptrOuter_InnerClass5) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Outer_makeInnerClass5Typedef, _swig_p) + return +} + +func (arg1 SwigcptrOuter) MakeInnerClass5Typedef() (_swig_ret Outer_InnerClass5) { + return _swig_wrap_Outer_makeInnerClass5Typedef(arg1) +} + +var _wrap_Outer_makeInnerUnion5Typedef unsafe.Pointer + +func _swig_wrap_Outer_makeInnerUnion5Typedef(base SwigcptrOuter) (_ SwigcptrOuter_InnerUnion5) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Outer_makeInnerUnion5Typedef, _swig_p) + return +} + +func (arg1 SwigcptrOuter) MakeInnerUnion5Typedef() (_swig_ret Outer_InnerUnion5) { + return _swig_wrap_Outer_makeInnerUnion5Typedef(arg1) +} + +var _wrap_Outer_MultipleInstance1_set unsafe.Pointer + +func _swig_wrap_Outer_MultipleInstance1_set(base SwigcptrOuter, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Outer_MultipleInstance1_set, _swig_p) + return +} + +func (arg1 SwigcptrOuter) SetMultipleInstance1(arg2 Outer_InnerMultiple) { + _swig_wrap_Outer_MultipleInstance1_set(arg1, arg2.Swigcptr()) +} + +var _wrap_Outer_MultipleInstance1_get unsafe.Pointer + +func _swig_wrap_Outer_MultipleInstance1_get(base SwigcptrOuter) (_ SwigcptrOuter_InnerMultiple) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Outer_MultipleInstance1_get, _swig_p) + return +} + +func (arg1 SwigcptrOuter) GetMultipleInstance1() (_swig_ret Outer_InnerMultiple) { + return _swig_wrap_Outer_MultipleInstance1_get(arg1) +} + +var _wrap_Outer_MultipleInstance2_set unsafe.Pointer + +func _swig_wrap_Outer_MultipleInstance2_set(base SwigcptrOuter, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Outer_MultipleInstance2_set, _swig_p) + return +} + +func (arg1 SwigcptrOuter) SetMultipleInstance2(arg2 Outer_InnerMultiple) { + _swig_wrap_Outer_MultipleInstance2_set(arg1, arg2.Swigcptr()) +} + +var _wrap_Outer_MultipleInstance2_get unsafe.Pointer + +func _swig_wrap_Outer_MultipleInstance2_get(base SwigcptrOuter) (_ SwigcptrOuter_InnerMultiple) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Outer_MultipleInstance2_get, _swig_p) + return +} + +func (arg1 SwigcptrOuter) GetMultipleInstance2() (_swig_ret Outer_InnerMultiple) { + return _swig_wrap_Outer_MultipleInstance2_get(arg1) +} + +var _wrap_Outer_MultipleInstance3_set unsafe.Pointer + +func _swig_wrap_Outer_MultipleInstance3_set(base SwigcptrOuter, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Outer_MultipleInstance3_set, _swig_p) + return +} + +func (arg1 SwigcptrOuter) SetMultipleInstance3(arg2 Outer_InnerMultiple) { + _swig_wrap_Outer_MultipleInstance3_set(arg1, arg2.Swigcptr()) +} + +var _wrap_Outer_MultipleInstance3_get unsafe.Pointer + +func _swig_wrap_Outer_MultipleInstance3_get(base SwigcptrOuter) (_ SwigcptrOuter_InnerMultiple) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Outer_MultipleInstance3_get, _swig_p) + return +} + +func (arg1 SwigcptrOuter) GetMultipleInstance3() (_swig_ret Outer_InnerMultiple) { + return _swig_wrap_Outer_MultipleInstance3_get(arg1) +} + +var _wrap_Outer_MultipleInstance4_set unsafe.Pointer + +func _swig_wrap_Outer_MultipleInstance4_set(base SwigcptrOuter, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Outer_MultipleInstance4_set, _swig_p) + return +} + +func (arg1 SwigcptrOuter) SetMultipleInstance4(arg2 Outer_InnerMultiple) { + _swig_wrap_Outer_MultipleInstance4_set(arg1, arg2.Swigcptr()) +} + +var _wrap_Outer_MultipleInstance4_get unsafe.Pointer + +func _swig_wrap_Outer_MultipleInstance4_get(base SwigcptrOuter) (_ SwigcptrOuter_InnerMultiple) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Outer_MultipleInstance4_get, _swig_p) + return +} + +func (arg1 SwigcptrOuter) GetMultipleInstance4() (_swig_ret Outer_InnerMultiple) { + return _swig_wrap_Outer_MultipleInstance4_get(arg1) +} + +var _wrap_Outer_MultipleDerivedInstance1_set unsafe.Pointer + +func _swig_wrap_Outer_MultipleDerivedInstance1_set(base SwigcptrOuter, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Outer_MultipleDerivedInstance1_set, _swig_p) + return +} + +func (arg1 SwigcptrOuter) SetMultipleDerivedInstance1(arg2 Outer_InnerMultipleDerived) { + _swig_wrap_Outer_MultipleDerivedInstance1_set(arg1, arg2.Swigcptr()) +} + +var _wrap_Outer_MultipleDerivedInstance1_get unsafe.Pointer + +func _swig_wrap_Outer_MultipleDerivedInstance1_get(base SwigcptrOuter) (_ SwigcptrOuter_InnerMultipleDerived) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Outer_MultipleDerivedInstance1_get, _swig_p) + return +} + +func (arg1 SwigcptrOuter) GetMultipleDerivedInstance1() (_swig_ret Outer_InnerMultipleDerived) { + return _swig_wrap_Outer_MultipleDerivedInstance1_get(arg1) +} + +var _wrap_Outer_MultipleDerivedInstance2_set unsafe.Pointer + +func _swig_wrap_Outer_MultipleDerivedInstance2_set(base SwigcptrOuter, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Outer_MultipleDerivedInstance2_set, _swig_p) + return +} + +func (arg1 SwigcptrOuter) SetMultipleDerivedInstance2(arg2 Outer_InnerMultipleDerived) { + _swig_wrap_Outer_MultipleDerivedInstance2_set(arg1, arg2.Swigcptr()) +} + +var _wrap_Outer_MultipleDerivedInstance2_get unsafe.Pointer + +func _swig_wrap_Outer_MultipleDerivedInstance2_get(base SwigcptrOuter) (_ SwigcptrOuter_InnerMultipleDerived) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Outer_MultipleDerivedInstance2_get, _swig_p) + return +} + +func (arg1 SwigcptrOuter) GetMultipleDerivedInstance2() (_swig_ret Outer_InnerMultipleDerived) { + return _swig_wrap_Outer_MultipleDerivedInstance2_get(arg1) +} + +var _wrap_Outer_MultipleDerivedInstance3_set unsafe.Pointer + +func _swig_wrap_Outer_MultipleDerivedInstance3_set(base SwigcptrOuter, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Outer_MultipleDerivedInstance3_set, _swig_p) + return +} + +func (arg1 SwigcptrOuter) SetMultipleDerivedInstance3(arg2 Outer_InnerMultipleDerived) { + _swig_wrap_Outer_MultipleDerivedInstance3_set(arg1, arg2.Swigcptr()) +} + +var _wrap_Outer_MultipleDerivedInstance3_get unsafe.Pointer + +func _swig_wrap_Outer_MultipleDerivedInstance3_get(base SwigcptrOuter) (_ SwigcptrOuter_InnerMultipleDerived) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Outer_MultipleDerivedInstance3_get, _swig_p) + return +} + +func (arg1 SwigcptrOuter) GetMultipleDerivedInstance3() (_swig_ret Outer_InnerMultipleDerived) { + return _swig_wrap_Outer_MultipleDerivedInstance3_get(arg1) +} + +var _wrap_Outer_MultipleDerivedInstance4_set unsafe.Pointer + +func _swig_wrap_Outer_MultipleDerivedInstance4_set(base SwigcptrOuter, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Outer_MultipleDerivedInstance4_set, _swig_p) + return +} + +func (arg1 SwigcptrOuter) SetMultipleDerivedInstance4(arg2 Outer_InnerMultipleDerived) { + _swig_wrap_Outer_MultipleDerivedInstance4_set(arg1, arg2.Swigcptr()) +} + +var _wrap_Outer_MultipleDerivedInstance4_get unsafe.Pointer + +func _swig_wrap_Outer_MultipleDerivedInstance4_get(base SwigcptrOuter) (_ SwigcptrOuter_InnerMultipleDerived) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Outer_MultipleDerivedInstance4_get, _swig_p) + return +} + +func (arg1 SwigcptrOuter) GetMultipleDerivedInstance4() (_swig_ret Outer_InnerMultipleDerived) { + return _swig_wrap_Outer_MultipleDerivedInstance4_get(arg1) +} + +var _wrap_Outer_makeInnerMultipleAnonTypedef1 unsafe.Pointer + +func _swig_wrap_Outer_makeInnerMultipleAnonTypedef1(base SwigcptrOuter) (_ SwigcptrOuter_InnerMultipleAnonTypedef1) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Outer_makeInnerMultipleAnonTypedef1, _swig_p) + return +} + +func (arg1 SwigcptrOuter) MakeInnerMultipleAnonTypedef1() (_swig_ret Outer_InnerMultipleAnonTypedef1) { + return _swig_wrap_Outer_makeInnerMultipleAnonTypedef1(arg1) +} + +var _wrap_Outer_makeInnerMultipleAnonTypedef2 unsafe.Pointer + +func _swig_wrap_Outer_makeInnerMultipleAnonTypedef2(base SwigcptrOuter) (_ SwigcptrOuter_InnerMultipleAnonTypedef2) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Outer_makeInnerMultipleAnonTypedef2, _swig_p) + return +} + +func (arg1 SwigcptrOuter) MakeInnerMultipleAnonTypedef2() (_swig_ret Outer_InnerMultipleAnonTypedef2) { + return _swig_wrap_Outer_makeInnerMultipleAnonTypedef2(arg1) +} + +var _wrap_Outer_makeInnerMultipleAnonTypedef3 unsafe.Pointer + +func _swig_wrap_Outer_makeInnerMultipleAnonTypedef3(base SwigcptrOuter) (_ SwigcptrOuter_InnerMultipleAnonTypedef3) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Outer_makeInnerMultipleAnonTypedef3, _swig_p) + return +} + +func (arg1 SwigcptrOuter) MakeInnerMultipleAnonTypedef3() (_swig_ret Outer_InnerMultipleAnonTypedef3) { + return _swig_wrap_Outer_makeInnerMultipleAnonTypedef3(arg1) +} + +var _wrap_Outer_makeInnerMultipleNamedTypedef unsafe.Pointer + +func _swig_wrap_Outer_makeInnerMultipleNamedTypedef(base SwigcptrOuter) (_ SwigcptrOuter_InnerMultipleNamedTypedef) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Outer_makeInnerMultipleNamedTypedef, _swig_p) + return +} + +func (arg1 SwigcptrOuter) MakeInnerMultipleNamedTypedef() (_swig_ret Outer_InnerMultipleNamedTypedef) { + return _swig_wrap_Outer_makeInnerMultipleNamedTypedef(arg1) +} + +var _wrap_Outer_makeInnerMultipleNamedTypedef1 unsafe.Pointer + +func _swig_wrap_Outer_makeInnerMultipleNamedTypedef1(base SwigcptrOuter) (_ SwigcptrOuter_InnerMultipleNamedTypedef) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Outer_makeInnerMultipleNamedTypedef1, _swig_p) + return +} + +func (arg1 SwigcptrOuter) MakeInnerMultipleNamedTypedef1() (_swig_ret Outer_InnerMultipleNamedTypedef) { + return _swig_wrap_Outer_makeInnerMultipleNamedTypedef1(arg1) +} + +var _wrap_Outer_makeInnerMultipleNamedTypedef2 unsafe.Pointer + +func _swig_wrap_Outer_makeInnerMultipleNamedTypedef2(base SwigcptrOuter) (_ SwigcptrOuter_InnerMultipleNamedTypedef) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Outer_makeInnerMultipleNamedTypedef2, _swig_p) + return +} + +func (arg1 SwigcptrOuter) MakeInnerMultipleNamedTypedef2() (_swig_ret Outer_InnerMultipleNamedTypedef) { + return _swig_wrap_Outer_makeInnerMultipleNamedTypedef2(arg1) +} + +var _wrap_Outer_makeInnerMultipleNamedTypedef3 unsafe.Pointer + +func _swig_wrap_Outer_makeInnerMultipleNamedTypedef3(base SwigcptrOuter) (_ SwigcptrOuter_InnerMultipleNamedTypedef) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Outer_makeInnerMultipleNamedTypedef3, _swig_p) + return +} + +func (arg1 SwigcptrOuter) MakeInnerMultipleNamedTypedef3() (_swig_ret Outer_InnerMultipleNamedTypedef) { + return _swig_wrap_Outer_makeInnerMultipleNamedTypedef3(arg1) +} + +var _wrap_Outer_makeInnerSameName unsafe.Pointer + +func _swig_wrap_Outer_makeInnerSameName(base SwigcptrOuter) (_ SwigcptrOuter_InnerSameName) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Outer_makeInnerSameName, _swig_p) + return +} + +func (arg1 SwigcptrOuter) MakeInnerSameName() (_swig_ret Outer_InnerSameName) { + return _swig_wrap_Outer_makeInnerSameName(arg1) +} + +var _wrap_new_Outer unsafe.Pointer + +func _swig_wrap_new_Outer() (base SwigcptrOuter) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Outer, _swig_p) + return +} + +func NewOuter() (_swig_ret Outer) { + return _swig_wrap_new_Outer() +} + +var _wrap_delete_Outer unsafe.Pointer + +func _swig_wrap_delete_Outer(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Outer, _swig_p) + return +} + +func DeleteOuter(arg1 Outer) { + _swig_wrap_delete_Outer(arg1.Swigcptr()) +} + +type Outer interface { + Swigcptr() uintptr + SwigIsOuter() + SetInnerClass2Instance(arg2 Outer_InnerClass2) + GetInnerClass2Instance() (_swig_ret Outer_InnerClass2) + SetInnerStruct2Instance(arg2 Outer_InnerStruct2) + GetInnerStruct2Instance() (_swig_ret Outer_InnerStruct2) + SetInnerUnion2Instance(arg2 Outer_InnerUnion2) + GetInnerUnion2Instance() (_swig_ret Outer_InnerUnion2) + MakeInnerStruct1() (_swig_ret Outer_InnerStruct1) + MakeInnerClass1() (_swig_ret Outer_InnerClass1) + MakeInnerUnion1() (_swig_ret Outer_InnerUnion1) + MakeInnerStruct2() (_swig_ret Outer_InnerStruct2) + MakeInnerClass2() (_swig_ret Outer_InnerClass2) + MakeInnerUnion2() (_swig_ret Outer_InnerUnion2) + MakeInnerStruct4Typedef() (_swig_ret Outer_InnerStruct4Typedef) + MakeInnerClass4Typedef() (_swig_ret Outer_InnerClass4Typedef) + MakeInnerUnion4Typedef() (_swig_ret Outer_InnerUnion4Typedef) + MakeInnerStruct5() (_swig_ret Outer_InnerStruct5) + MakeInnerClass5() (_swig_ret Outer_InnerClass5) + MakeInnerUnion5() (_swig_ret Outer_InnerUnion5) + MakeInnerStruct5Typedef() (_swig_ret Outer_InnerStruct5) + MakeInnerClass5Typedef() (_swig_ret Outer_InnerClass5) + MakeInnerUnion5Typedef() (_swig_ret Outer_InnerUnion5) + SetMultipleInstance1(arg2 Outer_InnerMultiple) + GetMultipleInstance1() (_swig_ret Outer_InnerMultiple) + SetMultipleInstance2(arg2 Outer_InnerMultiple) + GetMultipleInstance2() (_swig_ret Outer_InnerMultiple) + SetMultipleInstance3(arg2 Outer_InnerMultiple) + GetMultipleInstance3() (_swig_ret Outer_InnerMultiple) + SetMultipleInstance4(arg2 Outer_InnerMultiple) + GetMultipleInstance4() (_swig_ret Outer_InnerMultiple) + SetMultipleDerivedInstance1(arg2 Outer_InnerMultipleDerived) + GetMultipleDerivedInstance1() (_swig_ret Outer_InnerMultipleDerived) + SetMultipleDerivedInstance2(arg2 Outer_InnerMultipleDerived) + GetMultipleDerivedInstance2() (_swig_ret Outer_InnerMultipleDerived) + SetMultipleDerivedInstance3(arg2 Outer_InnerMultipleDerived) + GetMultipleDerivedInstance3() (_swig_ret Outer_InnerMultipleDerived) + SetMultipleDerivedInstance4(arg2 Outer_InnerMultipleDerived) + GetMultipleDerivedInstance4() (_swig_ret Outer_InnerMultipleDerived) + MakeInnerMultipleAnonTypedef1() (_swig_ret Outer_InnerMultipleAnonTypedef1) + MakeInnerMultipleAnonTypedef2() (_swig_ret Outer_InnerMultipleAnonTypedef2) + MakeInnerMultipleAnonTypedef3() (_swig_ret Outer_InnerMultipleAnonTypedef3) + MakeInnerMultipleNamedTypedef() (_swig_ret Outer_InnerMultipleNamedTypedef) + MakeInnerMultipleNamedTypedef1() (_swig_ret Outer_InnerMultipleNamedTypedef) + MakeInnerMultipleNamedTypedef2() (_swig_ret Outer_InnerMultipleNamedTypedef) + MakeInnerMultipleNamedTypedef3() (_swig_ret Outer_InnerMultipleNamedTypedef) + MakeInnerSameName() (_swig_ret Outer_InnerSameName) +} + +type SwigcptrOuter2 uintptr + +func (p SwigcptrOuter2) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrOuter2) SwigIsOuter2() { +} + +var _wrap_new_Outer2 unsafe.Pointer + +func _swig_wrap_new_Outer2() (base SwigcptrOuter2) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Outer2, _swig_p) + return +} + +func NewOuter2() (_swig_ret Outer2) { + return _swig_wrap_new_Outer2() +} + +var _wrap_delete_Outer2 unsafe.Pointer + +func _swig_wrap_delete_Outer2(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Outer2, _swig_p) + return +} + +func DeleteOuter2(arg1 Outer2) { + _swig_wrap_delete_Outer2(arg1.Swigcptr()) +} + +type Outer2 interface { + Swigcptr() uintptr + SwigIsOuter2() +} + + +type SwigcptrOuter_InnerClass5 uintptr +type Outer_InnerClass5 interface { + Swigcptr() uintptr; +} +func (p SwigcptrOuter_InnerClass5) Swigcptr() uintptr { + return uintptr(p) +} + +type SwigcptrOuter_InnerMultipleDerived uintptr +type Outer_InnerMultipleDerived interface { + Swigcptr() uintptr; +} +func (p SwigcptrOuter_InnerMultipleDerived) Swigcptr() uintptr { + return uintptr(p) +} + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + +type SwigcptrOuter_InnerStruct1 uintptr +type Outer_InnerStruct1 interface { + Swigcptr() uintptr; +} +func (p SwigcptrOuter_InnerStruct1) Swigcptr() uintptr { + return uintptr(p) +} + +type SwigcptrOuter_InnerStruct2 uintptr +type Outer_InnerStruct2 interface { + Swigcptr() uintptr; +} +func (p SwigcptrOuter_InnerStruct2) Swigcptr() uintptr { + return uintptr(p) +} + +type SwigcptrOuter_InnerUnion4Typedef uintptr +type Outer_InnerUnion4Typedef interface { + Swigcptr() uintptr; +} +func (p SwigcptrOuter_InnerUnion4Typedef) Swigcptr() uintptr { + return uintptr(p) +} + +type SwigcptrOuter_InnerClass4Typedef uintptr +type Outer_InnerClass4Typedef interface { + Swigcptr() uintptr; +} +func (p SwigcptrOuter_InnerClass4Typedef) Swigcptr() uintptr { + return uintptr(p) +} + +type SwigcptrOuter_InnerStruct4Typedef uintptr +type Outer_InnerStruct4Typedef interface { + Swigcptr() uintptr; +} +func (p SwigcptrOuter_InnerStruct4Typedef) Swigcptr() uintptr { + return uintptr(p) +} + +type SwigcptrOuter_InnerMultipleNamedTypedef uintptr +type Outer_InnerMultipleNamedTypedef interface { + Swigcptr() uintptr; +} +func (p SwigcptrOuter_InnerMultipleNamedTypedef) Swigcptr() uintptr { + return uintptr(p) +} + +type SwigcptrOuter_InnerStruct5 uintptr +type Outer_InnerStruct5 interface { + Swigcptr() uintptr; +} +func (p SwigcptrOuter_InnerStruct5) Swigcptr() uintptr { + return uintptr(p) +} + +type SwigcptrOuter_InnerMultipleAnonTypedef1 uintptr +type Outer_InnerMultipleAnonTypedef1 interface { + Swigcptr() uintptr; +} +func (p SwigcptrOuter_InnerMultipleAnonTypedef1) Swigcptr() uintptr { + return uintptr(p) +} + +type SwigcptrOuter_InnerMultipleAnonTypedef2 uintptr +type Outer_InnerMultipleAnonTypedef2 interface { + Swigcptr() uintptr; +} +func (p SwigcptrOuter_InnerMultipleAnonTypedef2) Swigcptr() uintptr { + return uintptr(p) +} + +type SwigcptrOuter_InnerUnion1 uintptr +type Outer_InnerUnion1 interface { + Swigcptr() uintptr; +} +func (p SwigcptrOuter_InnerUnion1) Swigcptr() uintptr { + return uintptr(p) +} + +type SwigcptrOuter_InnerMultipleAnonTypedef3 uintptr +type Outer_InnerMultipleAnonTypedef3 interface { + Swigcptr() uintptr; +} +func (p SwigcptrOuter_InnerMultipleAnonTypedef3) Swigcptr() uintptr { + return uintptr(p) +} + +type SwigcptrOuter_InnerUnion2 uintptr +type Outer_InnerUnion2 interface { + Swigcptr() uintptr; +} +func (p SwigcptrOuter_InnerUnion2) Swigcptr() uintptr { + return uintptr(p) +} + +type SwigcptrOuter_InnerClass1 uintptr +type Outer_InnerClass1 interface { + Swigcptr() uintptr; +} +func (p SwigcptrOuter_InnerClass1) Swigcptr() uintptr { + return uintptr(p) +} + +type SwigcptrOuter_InnerMultiple uintptr +type Outer_InnerMultiple interface { + Swigcptr() uintptr; +} +func (p SwigcptrOuter_InnerMultiple) Swigcptr() uintptr { + return uintptr(p) +} + +type SwigcptrOuter_InnerClass2 uintptr +type Outer_InnerClass2 interface { + Swigcptr() uintptr; +} +func (p SwigcptrOuter_InnerClass2) Swigcptr() uintptr { + return uintptr(p) +} + +type SwigcptrOuter_InnerSameName uintptr +type Outer_InnerSameName interface { + Swigcptr() uintptr; +} +func (p SwigcptrOuter_InnerSameName) Swigcptr() uintptr { + return uintptr(p) +} + +type SwigcptrOuter_InnerUnion5 uintptr +type Outer_InnerUnion5 interface { + Swigcptr() uintptr; +} +func (p SwigcptrOuter_InnerUnion5) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/nested_comment.go b/Examples/test-suite/go/nested_comment.go new file mode 100644 index 000000000..0668255b8 --- /dev/null +++ b/Examples/test-suite/go/nested_comment.go @@ -0,0 +1,113 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../nested_comment.i + +package nested_comment + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrS2 uintptr + +func (p SwigcptrS2) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrS2) SwigIsS2() { +} + +var _wrap_new_s2 unsafe.Pointer + +func _swig_wrap_new_s2() (base SwigcptrS2) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_s2, _swig_p) + return +} + +func NewS2() (_swig_ret S2) { + return _swig_wrap_new_s2() +} + +var _wrap_delete_s2 unsafe.Pointer + +func _swig_wrap_delete_s2(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_s2, _swig_p) + return +} + +func DeleteS2(arg1 S2) { + _swig_wrap_delete_s2(arg1.Swigcptr()) +} + +type S2 interface { + Swigcptr() uintptr + SwigIsS2() +} + +type SwigcptrA uintptr + +func (p SwigcptrA) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrA) SwigIsA() { +} + +var _wrap_new_a unsafe.Pointer + +func _swig_wrap_new_a() (base SwigcptrA) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_a, _swig_p) + return +} + +func NewA() (_swig_ret A) { + return _swig_wrap_new_a() +} + +var _wrap_delete_a unsafe.Pointer + +func _swig_wrap_delete_a(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_a, _swig_p) + return +} + +func DeleteA(arg1 A) { + _swig_wrap_delete_a(arg1.Swigcptr()) +} + +type A interface { + Swigcptr() uintptr + SwigIsA() +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/nested_directors.go b/Examples/test-suite/go/nested_directors.go new file mode 100644 index 000000000..02f6adffa --- /dev/null +++ b/Examples/test-suite/go/nested_directors.go @@ -0,0 +1,299 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../nested_directors.i + +package nested_directors + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type _swig_DirectorBase struct { + SwigcptrBase + v interface{} +} + +func (p *_swig_DirectorBase) Swigcptr() uintptr { + return p.SwigcptrBase.Swigcptr() +} + +func (p *_swig_DirectorBase) SwigIsBase() { +} + +func (p *_swig_DirectorBase) DirectorInterface() interface{} { + return p.v +} + +var _wrap__swig_NewDirectorBaseBase unsafe.Pointer + +func _swig_NewDirectorBaseBase(_swig_director *_swig_DirectorBase) (_swig_ret SwigcptrBase) { + _swig_p := uintptr(unsafe.Pointer(&_swig_director)) + _cgo_runtime_cgocall(_wrap__swig_NewDirectorBaseBase, _swig_p) + return +} + +func NewDirectorBase(v interface{}) Base { + p := &_swig_DirectorBase{0, v} + p.SwigcptrBase = _swig_NewDirectorBaseBase(p) + return p +} + +var _wrap_DeleteDirectorBase unsafe.Pointer + +func _swig_wrap_DeleteDirectorBase(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_DeleteDirectorBase, _swig_p) + return +} + +func DeleteDirectorBase(arg1 Base) { + _swig_wrap_DeleteDirectorBase(arg1.Swigcptr()) +} + +func Swiggo_DeleteDirector_Base(p *_swig_DirectorBase) { + p.SwigcptrBase = 0 +} + +type _swig_DirectorInterfaceBaseDoNothing interface { + DoNothing() bool +} + +func (swig_p *_swig_DirectorBase) DoNothing() bool { + if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceBaseDoNothing); swig_ok { + return swig_g.DoNothing() + } + panic("call to pure virtual method") +} + +func Swig_DirectorBase_callback_DoNothing(p *_swig_DirectorBase) (swig_result bool) { + var swig_r bool + swig_r = p.DoNothing() + return swig_r +} + +type SwigcptrBase uintptr + +func (p SwigcptrBase) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrBase) SwigIsBase() { +} + +func (p SwigcptrBase) DirectorInterface() interface{} { + return nil +} + +var _wrap_delete_Base unsafe.Pointer + +func _swig_wrap_delete_Base(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Base, _swig_p) + return +} + +func DeleteBase(arg1 Base) { + _swig_wrap_delete_Base(arg1.Swigcptr()) +} + +var _wrap_new_Base unsafe.Pointer + +func _swig_wrap_new_Base() (base SwigcptrBase) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Base, _swig_p) + return +} + +func NewBase() (_swig_ret Base) { + return _swig_wrap_new_Base() +} + +type Base interface { + Swigcptr() uintptr + SwigIsBase() + DirectorInterface() interface{} +} + +type _swig_DirectorSub struct { + SwigcptrSub + v interface{} +} + +func (p *_swig_DirectorSub) Swigcptr() uintptr { + return p.SwigcptrSub.Swigcptr() +} + +func (p *_swig_DirectorSub) SwigIsSub() { +} + +func (p *_swig_DirectorSub) DirectorInterface() interface{} { + return p.v +} + +var _wrap__swig_NewDirectorSubSub unsafe.Pointer + +func _swig_NewDirectorSubSub(_swig_director *_swig_DirectorSub) (_swig_ret SwigcptrSub) { + _swig_p := uintptr(unsafe.Pointer(&_swig_director)) + _cgo_runtime_cgocall(_wrap__swig_NewDirectorSubSub, _swig_p) + return +} + +func NewDirectorSub(v interface{}) Sub { + p := &_swig_DirectorSub{0, v} + p.SwigcptrSub = _swig_NewDirectorSubSub(p) + return p +} + +var _wrap_DeleteDirectorSub unsafe.Pointer + +func _swig_wrap_DeleteDirectorSub(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_DeleteDirectorSub, _swig_p) + return +} + +func DeleteDirectorSub(arg1 Sub) { + _swig_wrap_DeleteDirectorSub(arg1.Swigcptr()) +} + +func Swiggo_DeleteDirector_Sub(p *_swig_DirectorSub) { + p.SwigcptrSub = 0 +} + +type _swig_DirectorInterfaceSubDoNothing interface { + DoNothing() bool +} + +func (swig_p *_swig_DirectorSub) DoNothing() bool { + if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceSubDoNothing); swig_ok { + return swig_g.DoNothing() + } + panic("call to pure virtual method") +} + +func Swig_DirectorSub_callback_DoNothing(p *_swig_DirectorSub) (swig_result bool) { + var swig_r bool + swig_r = p.DoNothing() + return swig_r +} + +type _swig_DirectorInterfaceSubGetValue interface { + GetValue() bool +} + +var _wrap__swig_DirectorSub_upcall_GetValue unsafe.Pointer + +func _swig_wrap__swig_DirectorSub_upcall_GetValue(_swig_ptr SwigcptrSub) (_swig_ret bool) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) + _cgo_runtime_cgocall(_wrap__swig_DirectorSub_upcall_GetValue, _swig_p) + return +} + +func (swig_p *_swig_DirectorSub) GetValue() bool { + if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceSubGetValue); swig_ok { + return swig_g.GetValue() + } + var swig_r bool + swig_r = _swig_wrap__swig_DirectorSub_upcall_GetValue(swig_p.SwigcptrSub) + return swig_r +} + +func DirectorSubGetValue(p Sub) bool { + var swig_r bool + swig_r = _swig_wrap__swig_DirectorSub_upcall_GetValue(p.(*_swig_DirectorSub).SwigcptrSub) + return swig_r +} + +func Swig_DirectorSub_callback_GetValue(p *_swig_DirectorSub) (swig_result bool) { + var swig_r bool + swig_r = p.GetValue() + return swig_r +} + +type SwigcptrSub uintptr + +func (p SwigcptrSub) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrSub) SwigIsSub() { +} + +func (p SwigcptrSub) DirectorInterface() interface{} { + return nil +} + +var _wrap_delete_Sub unsafe.Pointer + +func _swig_wrap_delete_Sub(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Sub, _swig_p) + return +} + +func DeleteSub(arg1 Sub) { + _swig_wrap_delete_Sub(arg1.Swigcptr()) +} + +var _wrap_new_Sub unsafe.Pointer + +func _swig_wrap_new_Sub() (base SwigcptrSub) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Sub, _swig_p) + return +} + +func NewSub() (_swig_ret Sub) { + return _swig_wrap_new_Sub() +} + +func (p SwigcptrSub) SwigIsBase() { +} + +func (p SwigcptrSub) SwigGetBase() Base { + return SwigcptrBase(p.Swigcptr()) +} + +type Sub interface { + Swigcptr() uintptr + SwigIsSub() + DirectorInterface() interface{} + SwigIsBase() + SwigGetBase() Base +} + + +type SwigcptrSwigDirector_Sub uintptr +type SwigDirector_Sub interface { + Swigcptr() uintptr; +} +func (p SwigcptrSwigDirector_Sub) Swigcptr() uintptr { + return uintptr(p) +} + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/nested_directors_wrap.h b/Examples/test-suite/go/nested_directors_wrap.h new file mode 100644 index 000000000..e2bd53c6b --- /dev/null +++ b/Examples/test-suite/go/nested_directors_wrap.h @@ -0,0 +1,41 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../nested_directors.i + +#ifndef SWIG_nested_directors_WRAP_H_ +#define SWIG_nested_directors_WRAP_H_ + +class SwigDirector_Base : public NN::Base +{ + public: + SwigDirector_Base(void *swig_p); + virtual ~SwigDirector_Base(); + virtual bool DoNothing(); + private: + void *go_val; +}; + +class SwigDirector_Sub : public NN::Sub +{ + public: + SwigDirector_Sub(void *swig_p); + virtual ~SwigDirector_Sub(); + virtual bool DoNothing(); + bool _swig_upcall_GetValue() const { + return NN::Sub::GetValue(); + } + virtual bool GetValue() const; + using NN::Sub::DoSomething; + private: + void *go_val; +}; + +#endif diff --git a/Examples/test-suite/go/nested_extend_c.go b/Examples/test-suite/go/nested_extend_c.go new file mode 100644 index 000000000..284a87f31 --- /dev/null +++ b/Examples/test-suite/go/nested_extend_c.go @@ -0,0 +1,875 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../nested_extend_c.i + +package nested_extend_c + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrNestedA uintptr + +func (p SwigcptrNestedA) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrNestedA) SwigIsNestedA() { +} + +var _wrap_NestedA_hiA_instance_set unsafe.Pointer + +func _swig_wrap_NestedA_hiA_instance_set(base SwigcptrNestedA, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_NestedA_hiA_instance_set, _swig_p) + return +} + +func (arg1 SwigcptrNestedA) SetHiA_instance(arg2 HiA) { + _swig_wrap_NestedA_hiA_instance_set(arg1, arg2.Swigcptr()) +} + +var _wrap_NestedA_hiA_instance_get unsafe.Pointer + +func _swig_wrap_NestedA_hiA_instance_get(base SwigcptrNestedA) (_ SwigcptrHiA) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_NestedA_hiA_instance_get, _swig_p) + return +} + +func (arg1 SwigcptrNestedA) GetHiA_instance() (_swig_ret HiA) { + return _swig_wrap_NestedA_hiA_instance_get(arg1) +} + +var _wrap_NestedA_lowA_instance_set unsafe.Pointer + +func _swig_wrap_NestedA_lowA_instance_set(base SwigcptrNestedA, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_NestedA_lowA_instance_set, _swig_p) + return +} + +func (arg1 SwigcptrNestedA) SetLowA_instance(arg2 LowA) { + _swig_wrap_NestedA_lowA_instance_set(arg1, arg2.Swigcptr()) +} + +var _wrap_NestedA_lowA_instance_get unsafe.Pointer + +func _swig_wrap_NestedA_lowA_instance_get(base SwigcptrNestedA) (_ SwigcptrLowA) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_NestedA_lowA_instance_get, _swig_p) + return +} + +func (arg1 SwigcptrNestedA) GetLowA_instance() (_swig_ret LowA) { + return _swig_wrap_NestedA_lowA_instance_get(arg1) +} + +var _wrap_NestedA_a_set unsafe.Pointer + +func _swig_wrap_NestedA_a_set(base SwigcptrNestedA, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_NestedA_a_set, _swig_p) + return +} + +func (arg1 SwigcptrNestedA) SetA(arg2 int) { + _swig_wrap_NestedA_a_set(arg1, arg2) +} + +var _wrap_NestedA_a_get unsafe.Pointer + +func _swig_wrap_NestedA_a_get(base SwigcptrNestedA) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_NestedA_a_get, _swig_p) + return +} + +func (arg1 SwigcptrNestedA) GetA() (_swig_ret int) { + return _swig_wrap_NestedA_a_get(arg1) +} + +var _wrap_NestedA_swig_size_NestedA unsafe.Pointer + +func _swig_getNestedA_NestedA_swig_size_NestedA() (_swig_ret int64) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_NestedA_swig_size_NestedA, _swig_p) + return +} +var NestedASwig_size int64 = _swig_getNestedA_NestedA_swig_size_NestedA() +var _wrap_new_NestedA unsafe.Pointer + +func _swig_wrap_new_NestedA() (base SwigcptrNestedA) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_NestedA, _swig_p) + return +} + +func NewNestedA() (_swig_ret NestedA) { + return _swig_wrap_new_NestedA() +} + +var _wrap_delete_NestedA unsafe.Pointer + +func _swig_wrap_delete_NestedA(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_NestedA, _swig_p) + return +} + +func DeleteNestedA(arg1 NestedA) { + _swig_wrap_delete_NestedA(arg1.Swigcptr()) +} + +type NestedA interface { + Swigcptr() uintptr + SwigIsNestedA() + SetHiA_instance(arg2 HiA) + GetHiA_instance() (_swig_ret HiA) + SetLowA_instance(arg2 LowA) + GetLowA_instance() (_swig_ret LowA) + SetA(arg2 int) + GetA() (_swig_ret int) +} + +type SwigcptrHiA uintptr + +func (p SwigcptrHiA) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrHiA) SwigIsHiA() { +} + +var _wrap_hiA_c_set unsafe.Pointer + +func _swig_wrap_hiA_c_set(base SwigcptrHiA, _ byte) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_hiA_c_set, _swig_p) + return +} + +func (arg1 SwigcptrHiA) SetC(arg2 byte) { + _swig_wrap_hiA_c_set(arg1, arg2) +} + +var _wrap_hiA_c_get unsafe.Pointer + +func _swig_wrap_hiA_c_get(base SwigcptrHiA) (_ byte) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_hiA_c_get, _swig_p) + return +} + +func (arg1 SwigcptrHiA) GetC() (_swig_ret byte) { + return _swig_wrap_hiA_c_get(arg1) +} + +var _wrap_hiA_d_set unsafe.Pointer + +func _swig_wrap_hiA_d_set(base SwigcptrHiA, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_hiA_d_set, _swig_p) + return +} + +func (arg1 SwigcptrHiA) SetD(arg2 int) { + _swig_wrap_hiA_d_set(arg1, arg2) +} + +var _wrap_hiA_d_get unsafe.Pointer + +func _swig_wrap_hiA_d_get(base SwigcptrHiA) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_hiA_d_get, _swig_p) + return +} + +func (arg1 SwigcptrHiA) GetD() (_swig_ret int) { + return _swig_wrap_hiA_d_get(arg1) +} + +var _wrap_new_hiA unsafe.Pointer + +func _swig_wrap_new_hiA() (base SwigcptrHiA) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_hiA, _swig_p) + return +} + +func NewHiA() (_swig_ret HiA) { + return _swig_wrap_new_hiA() +} + +var _wrap_hiA_hi_extend unsafe.Pointer + +func _swig_wrap_hiA_hi_extend(base SwigcptrHiA) (_ byte) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_hiA_hi_extend, _swig_p) + return +} + +func (arg1 SwigcptrHiA) Hi_extend() (_swig_ret byte) { + return _swig_wrap_hiA_hi_extend(arg1) +} + +var _wrap_hiA_swig_size_hiA unsafe.Pointer + +func _swig_gethiA_hiA_swig_size_hiA() (_swig_ret int64) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_hiA_swig_size_hiA, _swig_p) + return +} +var HiASwig_size int64 = _swig_gethiA_hiA_swig_size_hiA() +var _wrap_delete_hiA unsafe.Pointer + +func _swig_wrap_delete_hiA(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_hiA, _swig_p) + return +} + +func DeleteHiA(arg1 HiA) { + _swig_wrap_delete_hiA(arg1.Swigcptr()) +} + +type HiA interface { + Swigcptr() uintptr + SwigIsHiA() + SetC(arg2 byte) + GetC() (_swig_ret byte) + SetD(arg2 int) + GetD() (_swig_ret int) + Hi_extend() (_swig_ret byte) +} + +type SwigcptrLowA uintptr + +func (p SwigcptrLowA) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrLowA) SwigIsLowA() { +} + +var _wrap_lowA_name_set unsafe.Pointer + +func _swig_wrap_lowA_name_set(base SwigcptrLowA, _ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_lowA_name_set, _swig_p) + return +} + +func (arg1 SwigcptrLowA) SetName(arg2 string) { + _swig_wrap_lowA_name_set(arg1, arg2) +} + +var _wrap_lowA_name_get unsafe.Pointer + +func _swig_wrap_lowA_name_get(base SwigcptrLowA) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_lowA_name_get, _swig_p) + return +} + +func (arg1 SwigcptrLowA) GetName() (_swig_ret string) { + return _swig_wrap_lowA_name_get(arg1) +} + +var _wrap_lowA_num_set unsafe.Pointer + +func _swig_wrap_lowA_num_set(base SwigcptrLowA, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_lowA_num_set, _swig_p) + return +} + +func (arg1 SwigcptrLowA) SetNum(arg2 int) { + _swig_wrap_lowA_num_set(arg1, arg2) +} + +var _wrap_lowA_num_get unsafe.Pointer + +func _swig_wrap_lowA_num_get(base SwigcptrLowA) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_lowA_num_get, _swig_p) + return +} + +func (arg1 SwigcptrLowA) GetNum() (_swig_ret int) { + return _swig_wrap_lowA_num_get(arg1) +} + +var _wrap_new_lowA unsafe.Pointer + +func _swig_wrap_new_lowA() (base SwigcptrLowA) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_lowA, _swig_p) + return +} + +func NewLowA() (_swig_ret LowA) { + return _swig_wrap_new_lowA() +} + +var _wrap_lowA_low_extend unsafe.Pointer + +func _swig_wrap_lowA_low_extend(base SwigcptrLowA) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_lowA_low_extend, _swig_p) + return +} + +func (arg1 SwigcptrLowA) Low_extend() (_swig_ret int) { + return _swig_wrap_lowA_low_extend(arg1) +} + +var _wrap_lowA_swig_size_lowA unsafe.Pointer + +func _swig_getlowA_lowA_swig_size_lowA() (_swig_ret int64) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_lowA_swig_size_lowA, _swig_p) + return +} +var LowASwig_size int64 = _swig_getlowA_lowA_swig_size_lowA() +var _wrap_delete_lowA unsafe.Pointer + +func _swig_wrap_delete_lowA(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_lowA, _swig_p) + return +} + +func DeleteLowA(arg1 LowA) { + _swig_wrap_delete_lowA(arg1.Swigcptr()) +} + +type LowA interface { + Swigcptr() uintptr + SwigIsLowA() + SetName(arg2 string) + GetName() (_swig_ret string) + SetNum(arg2 int) + GetNum() (_swig_ret int) + Low_extend() (_swig_ret int) +} + +type SwigcptrNestedB uintptr + +func (p SwigcptrNestedB) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrNestedB) SwigIsNestedB() { +} + +var _wrap_NestedB_hiB_instance_get unsafe.Pointer + +func _swig_wrap_NestedB_hiB_instance_get(base SwigcptrNestedB) (_ SwigcptrHiB) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_NestedB_hiB_instance_get, _swig_p) + return +} + +func (arg1 SwigcptrNestedB) GetHiB_instance() (_swig_ret HiB) { + return _swig_wrap_NestedB_hiB_instance_get(arg1) +} + +var _wrap_NestedB_lowB_instance_get unsafe.Pointer + +func _swig_wrap_NestedB_lowB_instance_get(base SwigcptrNestedB) (_ SwigcptrLowB) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_NestedB_lowB_instance_get, _swig_p) + return +} + +func (arg1 SwigcptrNestedB) GetLowB_instance() (_swig_ret LowB) { + return _swig_wrap_NestedB_lowB_instance_get(arg1) +} + +var _wrap_NestedB_a_set unsafe.Pointer + +func _swig_wrap_NestedB_a_set(base SwigcptrNestedB, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_NestedB_a_set, _swig_p) + return +} + +func (arg1 SwigcptrNestedB) SetA(arg2 int) { + _swig_wrap_NestedB_a_set(arg1, arg2) +} + +var _wrap_NestedB_a_get unsafe.Pointer + +func _swig_wrap_NestedB_a_get(base SwigcptrNestedB) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_NestedB_a_get, _swig_p) + return +} + +func (arg1 SwigcptrNestedB) GetA() (_swig_ret int) { + return _swig_wrap_NestedB_a_get(arg1) +} + +var _wrap_new_NestedB unsafe.Pointer + +func _swig_wrap_new_NestedB() (base SwigcptrNestedB) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_NestedB, _swig_p) + return +} + +func NewNestedB() (_swig_ret NestedB) { + return _swig_wrap_new_NestedB() +} + +var _wrap_delete_NestedB unsafe.Pointer + +func _swig_wrap_delete_NestedB(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_NestedB, _swig_p) + return +} + +func DeleteNestedB(arg1 NestedB) { + _swig_wrap_delete_NestedB(arg1.Swigcptr()) +} + +type NestedB interface { + Swigcptr() uintptr + SwigIsNestedB() + GetHiB_instance() (_swig_ret HiB) + GetLowB_instance() (_swig_ret LowB) + SetA(arg2 int) + GetA() (_swig_ret int) +} + +type SwigcptrHiB uintptr + +func (p SwigcptrHiB) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrHiB) SwigIsHiB() { +} + +var _wrap_hiB_c_set unsafe.Pointer + +func _swig_wrap_hiB_c_set(base SwigcptrHiB, _ byte) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_hiB_c_set, _swig_p) + return +} + +func (arg1 SwigcptrHiB) SetC(arg2 byte) { + _swig_wrap_hiB_c_set(arg1, arg2) +} + +var _wrap_hiB_c_get unsafe.Pointer + +func _swig_wrap_hiB_c_get(base SwigcptrHiB) (_ byte) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_hiB_c_get, _swig_p) + return +} + +func (arg1 SwigcptrHiB) GetC() (_swig_ret byte) { + return _swig_wrap_hiB_c_get(arg1) +} + +var _wrap_hiB_d_set unsafe.Pointer + +func _swig_wrap_hiB_d_set(base SwigcptrHiB, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_hiB_d_set, _swig_p) + return +} + +func (arg1 SwigcptrHiB) SetD(arg2 int) { + _swig_wrap_hiB_d_set(arg1, arg2) +} + +var _wrap_hiB_d_get unsafe.Pointer + +func _swig_wrap_hiB_d_get(base SwigcptrHiB) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_hiB_d_get, _swig_p) + return +} + +func (arg1 SwigcptrHiB) GetD() (_swig_ret int) { + return _swig_wrap_hiB_d_get(arg1) +} + +var _wrap_new_hiB unsafe.Pointer + +func _swig_wrap_new_hiB() (base SwigcptrHiB) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_hiB, _swig_p) + return +} + +func NewHiB() (_swig_ret HiB) { + return _swig_wrap_new_hiB() +} + +var _wrap_hiB_hi_extend unsafe.Pointer + +func _swig_wrap_hiB_hi_extend(base SwigcptrHiB) (_ byte) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_hiB_hi_extend, _swig_p) + return +} + +func (arg1 SwigcptrHiB) Hi_extend() (_swig_ret byte) { + return _swig_wrap_hiB_hi_extend(arg1) +} + +var _wrap_hiB_swig_size_hiB unsafe.Pointer + +func _swig_gethiB_hiB_swig_size_hiB() (_swig_ret int64) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_hiB_swig_size_hiB, _swig_p) + return +} +var HiBSwig_size int64 = _swig_gethiB_hiB_swig_size_hiB() +var _wrap_delete_hiB unsafe.Pointer + +func _swig_wrap_delete_hiB(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_hiB, _swig_p) + return +} + +func DeleteHiB(arg1 HiB) { + _swig_wrap_delete_hiB(arg1.Swigcptr()) +} + +type HiB interface { + Swigcptr() uintptr + SwigIsHiB() + SetC(arg2 byte) + GetC() (_swig_ret byte) + SetD(arg2 int) + GetD() (_swig_ret int) + Hi_extend() (_swig_ret byte) +} + +type SwigcptrLowB uintptr + +func (p SwigcptrLowB) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrLowB) SwigIsLowB() { +} + +var _wrap_lowB_name_set unsafe.Pointer + +func _swig_wrap_lowB_name_set(base SwigcptrLowB, _ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_lowB_name_set, _swig_p) + return +} + +func (arg1 SwigcptrLowB) SetName(arg2 string) { + _swig_wrap_lowB_name_set(arg1, arg2) +} + +var _wrap_lowB_name_get unsafe.Pointer + +func _swig_wrap_lowB_name_get(base SwigcptrLowB) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_lowB_name_get, _swig_p) + return +} + +func (arg1 SwigcptrLowB) GetName() (_swig_ret string) { + return _swig_wrap_lowB_name_get(arg1) +} + +var _wrap_lowB_num_set unsafe.Pointer + +func _swig_wrap_lowB_num_set(base SwigcptrLowB, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_lowB_num_set, _swig_p) + return +} + +func (arg1 SwigcptrLowB) SetNum(arg2 int) { + _swig_wrap_lowB_num_set(arg1, arg2) +} + +var _wrap_lowB_num_get unsafe.Pointer + +func _swig_wrap_lowB_num_get(base SwigcptrLowB) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_lowB_num_get, _swig_p) + return +} + +func (arg1 SwigcptrLowB) GetNum() (_swig_ret int) { + return _swig_wrap_lowB_num_get(arg1) +} + +var _wrap_new_lowB unsafe.Pointer + +func _swig_wrap_new_lowB() (base SwigcptrLowB) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_lowB, _swig_p) + return +} + +func NewLowB() (_swig_ret LowB) { + return _swig_wrap_new_lowB() +} + +var _wrap_lowB_low_extend unsafe.Pointer + +func _swig_wrap_lowB_low_extend(base SwigcptrLowB) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_lowB_low_extend, _swig_p) + return +} + +func (arg1 SwigcptrLowB) Low_extend() (_swig_ret int) { + return _swig_wrap_lowB_low_extend(arg1) +} + +var _wrap_lowB_swig_size_lowB unsafe.Pointer + +func _swig_getlowB_lowB_swig_size_lowB() (_swig_ret int64) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_lowB_swig_size_lowB, _swig_p) + return +} +var LowBSwig_size int64 = _swig_getlowB_lowB_swig_size_lowB() +var _wrap_delete_lowB unsafe.Pointer + +func _swig_wrap_delete_lowB(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_lowB, _swig_p) + return +} + +func DeleteLowB(arg1 LowB) { + _swig_wrap_delete_lowB(arg1.Swigcptr()) +} + +type LowB interface { + Swigcptr() uintptr + SwigIsLowB() + SetName(arg2 string) + GetName() (_swig_ret string) + SetNum(arg2 int) + GetNum() (_swig_ret int) + Low_extend() (_swig_ret int) +} + +type SwigcptrFOO uintptr + +func (p SwigcptrFOO) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrFOO) SwigIsFOO() { +} + +var _wrap_FOO_a_set unsafe.Pointer + +func _swig_wrap_FOO_a_set(base SwigcptrFOO, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_FOO_a_set, _swig_p) + return +} + +func (arg1 SwigcptrFOO) SetA(arg2 int) { + _swig_wrap_FOO_a_set(arg1, arg2) +} + +var _wrap_FOO_a_get unsafe.Pointer + +func _swig_wrap_FOO_a_get(base SwigcptrFOO) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_FOO_a_get, _swig_p) + return +} + +func (arg1 SwigcptrFOO) GetA() (_swig_ret int) { + return _swig_wrap_FOO_a_get(arg1) +} + +var _wrap_FOO_bar_get unsafe.Pointer + +func _swig_wrap_FOO_bar_get(base SwigcptrFOO) (_ SwigcptrFOO_bar) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_FOO_bar_get, _swig_p) + return +} + +func (arg1 SwigcptrFOO) GetBar() (_swig_ret FOO_bar) { + return _swig_wrap_FOO_bar_get(arg1) +} + +var _wrap_new_FOO unsafe.Pointer + +func _swig_wrap_new_FOO() (base SwigcptrFOO) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_FOO, _swig_p) + return +} + +func NewFOO() (_swig_ret FOO) { + return _swig_wrap_new_FOO() +} + +var _wrap_delete_FOO unsafe.Pointer + +func _swig_wrap_delete_FOO(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_FOO, _swig_p) + return +} + +func DeleteFOO(arg1 FOO) { + _swig_wrap_delete_FOO(arg1.Swigcptr()) +} + +type FOO interface { + Swigcptr() uintptr + SwigIsFOO() + SetA(arg2 int) + GetA() (_swig_ret int) + GetBar() (_swig_ret FOO_bar) +} + +type SwigcptrFOO_bar uintptr + +func (p SwigcptrFOO_bar) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrFOO_bar) SwigIsFOO_bar() { +} + +var _wrap_FOO_bar_c_set unsafe.Pointer + +func _swig_wrap_FOO_bar_c_set(base SwigcptrFOO_bar, _ byte) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_FOO_bar_c_set, _swig_p) + return +} + +func (arg1 SwigcptrFOO_bar) SetC(arg2 byte) { + _swig_wrap_FOO_bar_c_set(arg1, arg2) +} + +var _wrap_FOO_bar_c_get unsafe.Pointer + +func _swig_wrap_FOO_bar_c_get(base SwigcptrFOO_bar) (_ byte) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_FOO_bar_c_get, _swig_p) + return +} + +func (arg1 SwigcptrFOO_bar) GetC() (_swig_ret byte) { + return _swig_wrap_FOO_bar_c_get(arg1) +} + +var _wrap_FOO_bar_d_set unsafe.Pointer + +func _swig_wrap_FOO_bar_d_set(base SwigcptrFOO_bar, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_FOO_bar_d_set, _swig_p) + return +} + +func (arg1 SwigcptrFOO_bar) SetD(arg2 int) { + _swig_wrap_FOO_bar_d_set(arg1, arg2) +} + +var _wrap_FOO_bar_d_get unsafe.Pointer + +func _swig_wrap_FOO_bar_d_get(base SwigcptrFOO_bar) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_FOO_bar_d_get, _swig_p) + return +} + +func (arg1 SwigcptrFOO_bar) GetD() (_swig_ret int) { + return _swig_wrap_FOO_bar_d_get(arg1) +} + +var _wrap_FOO_bar_bar_extend unsafe.Pointer + +func _swig_wrap_FOO_bar_bar_extend(base SwigcptrFOO_bar) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_FOO_bar_bar_extend, _swig_p) + return +} + +func (arg1 SwigcptrFOO_bar) Bar_extend() { + _swig_wrap_FOO_bar_bar_extend(arg1) +} + +var _wrap_new_FOO_bar unsafe.Pointer + +func _swig_wrap_new_FOO_bar() (base SwigcptrFOO_bar) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_FOO_bar, _swig_p) + return +} + +func NewFOO_bar() (_swig_ret FOO_bar) { + return _swig_wrap_new_FOO_bar() +} + +var _wrap_delete_FOO_bar unsafe.Pointer + +func _swig_wrap_delete_FOO_bar(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_FOO_bar, _swig_p) + return +} + +func DeleteFOO_bar(arg1 FOO_bar) { + _swig_wrap_delete_FOO_bar(arg1.Swigcptr()) +} + +type FOO_bar interface { + Swigcptr() uintptr + SwigIsFOO_bar() + SetC(arg2 byte) + GetC() (_swig_ret byte) + SetD(arg2 int) + GetD() (_swig_ret int) + Bar_extend() +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/nested_scope.go b/Examples/test-suite/go/nested_scope.go new file mode 100644 index 000000000..ae4d2b7a9 --- /dev/null +++ b/Examples/test-suite/go/nested_scope.go @@ -0,0 +1,203 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../nested_scope.i + +package nested_scope + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrGlobal_ uintptr + +func (p SwigcptrGlobal_) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrGlobal_) SwigIsGlobal_() { +} + +var _wrap_Global__instance_set unsafe.Pointer + +func _swig_wrap_Global__instance_set(base SwigcptrGlobal_, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Global__instance_set, _swig_p) + return +} + +func (arg1 SwigcptrGlobal_) SetInstance(arg2 Nested) { + _swig_wrap_Global__instance_set(arg1, arg2.Swigcptr()) +} + +var _wrap_Global__instance_get unsafe.Pointer + +func _swig_wrap_Global__instance_get(base SwigcptrGlobal_) (_ SwigcptrNested) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Global__instance_get, _swig_p) + return +} + +func (arg1 SwigcptrGlobal_) GetInstance() (_swig_ret Nested) { + return _swig_wrap_Global__instance_get(arg1) +} + +var _wrap_new_Global_ unsafe.Pointer + +func _swig_wrap_new_Global_() (base SwigcptrGlobal_) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Global_, _swig_p) + return +} + +func NewGlobal_() (_swig_ret Global_) { + return _swig_wrap_new_Global_() +} + +var _wrap_delete_Global_ unsafe.Pointer + +func _swig_wrap_delete_Global_(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Global_, _swig_p) + return +} + +func DeleteGlobal_(arg1 Global_) { + _swig_wrap_delete_Global_(arg1.Swigcptr()) +} + +type Global_ interface { + Swigcptr() uintptr + SwigIsGlobal_() + SetInstance(arg2 Nested) + GetInstance() (_swig_ret Nested) +} + +type SwigcptrOuter uintptr + +func (p SwigcptrOuter) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrOuter) SwigIsOuter() { +} + +var _wrap_new_Outer unsafe.Pointer + +func _swig_wrap_new_Outer() (base SwigcptrOuter) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Outer, _swig_p) + return +} + +func NewOuter() (_swig_ret Outer) { + return _swig_wrap_new_Outer() +} + +var _wrap_delete_Outer unsafe.Pointer + +func _swig_wrap_delete_Outer(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Outer, _swig_p) + return +} + +func DeleteOuter(arg1 Outer) { + _swig_wrap_delete_Outer(arg1.Swigcptr()) +} + +type Outer interface { + Swigcptr() uintptr + SwigIsOuter() +} + +type SwigcptrNested uintptr + +func (p SwigcptrNested) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrNested) SwigIsNested() { +} + +var _wrap_Nested_data_set unsafe.Pointer + +func _swig_wrap_Nested_data_set(base SwigcptrNested, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Nested_data_set, _swig_p) + return +} + +func (arg1 SwigcptrNested) SetData(arg2 int) { + _swig_wrap_Nested_data_set(arg1, arg2) +} + +var _wrap_Nested_data_get unsafe.Pointer + +func _swig_wrap_Nested_data_get(base SwigcptrNested) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Nested_data_get, _swig_p) + return +} + +func (arg1 SwigcptrNested) GetData() (_swig_ret int) { + return _swig_wrap_Nested_data_get(arg1) +} + +var _wrap_new_Nested unsafe.Pointer + +func _swig_wrap_new_Nested() (base SwigcptrNested) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Nested, _swig_p) + return +} + +func NewNested() (_swig_ret Nested) { + return _swig_wrap_new_Nested() +} + +var _wrap_delete_Nested unsafe.Pointer + +func _swig_wrap_delete_Nested(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Nested, _swig_p) + return +} + +func DeleteNested(arg1 Nested) { + _swig_wrap_delete_Nested(arg1.Swigcptr()) +} + +type Nested interface { + Swigcptr() uintptr + SwigIsNested() + SetData(arg2 int) + GetData() (_swig_ret int) +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/nested_structs.go b/Examples/test-suite/go/nested_structs.go new file mode 100644 index 000000000..79ca10941 --- /dev/null +++ b/Examples/test-suite/go/nested_structs.go @@ -0,0 +1,470 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../nested_structs.i + +package nested_structs + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrOuter uintptr + +func (p SwigcptrOuter) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrOuter) SwigIsOuter() { +} + +var _wrap_Outer_inside1_set unsafe.Pointer + +func _swig_wrap_Outer_inside1_set(base SwigcptrOuter, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Outer_inside1_set, _swig_p) + return +} + +func (arg1 SwigcptrOuter) SetInside1(arg2 Named) { + _swig_wrap_Outer_inside1_set(arg1, arg2.Swigcptr()) +} + +var _wrap_Outer_inside1_get unsafe.Pointer + +func _swig_wrap_Outer_inside1_get(base SwigcptrOuter) (_ SwigcptrNamed) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Outer_inside1_get, _swig_p) + return +} + +func (arg1 SwigcptrOuter) GetInside1() (_swig_ret Named) { + return _swig_wrap_Outer_inside1_get(arg1) +} + +var _wrap_Outer_inside2_set unsafe.Pointer + +func _swig_wrap_Outer_inside2_set(base SwigcptrOuter, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Outer_inside2_set, _swig_p) + return +} + +func (arg1 SwigcptrOuter) SetInside2(arg2 Named) { + _swig_wrap_Outer_inside2_set(arg1, arg2.Swigcptr()) +} + +var _wrap_Outer_inside2_get unsafe.Pointer + +func _swig_wrap_Outer_inside2_get(base SwigcptrOuter) (_ SwigcptrNamed) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Outer_inside2_get, _swig_p) + return +} + +func (arg1 SwigcptrOuter) GetInside2() (_swig_ret Named) { + return _swig_wrap_Outer_inside2_get(arg1) +} + +var _wrap_Outer_inside3_set unsafe.Pointer + +func _swig_wrap_Outer_inside3_set(base SwigcptrOuter, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Outer_inside3_set, _swig_p) + return +} + +func (arg1 SwigcptrOuter) SetInside3(arg2 Named) { + _swig_wrap_Outer_inside3_set(arg1, arg2.Swigcptr()) +} + +var _wrap_Outer_inside3_get unsafe.Pointer + +func _swig_wrap_Outer_inside3_get(base SwigcptrOuter) (_ SwigcptrNamed) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Outer_inside3_get, _swig_p) + return +} + +func (arg1 SwigcptrOuter) GetInside3() (_swig_ret Named) { + return _swig_wrap_Outer_inside3_get(arg1) +} + +var _wrap_Outer_inside4_set unsafe.Pointer + +func _swig_wrap_Outer_inside4_set(base SwigcptrOuter, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Outer_inside4_set, _swig_p) + return +} + +func (arg1 SwigcptrOuter) SetInside4(arg2 Named) { + _swig_wrap_Outer_inside4_set(arg1, arg2.Swigcptr()) +} + +var _wrap_Outer_inside4_get unsafe.Pointer + +func _swig_wrap_Outer_inside4_get(base SwigcptrOuter) (_ SwigcptrNamed) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Outer_inside4_get, _swig_p) + return +} + +func (arg1 SwigcptrOuter) GetInside4() (_swig_ret Named) { + return _swig_wrap_Outer_inside4_get(arg1) +} + +var _wrap_Outer_inside5_set unsafe.Pointer + +func _swig_wrap_Outer_inside5_set(base SwigcptrOuter, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Outer_inside5_set, _swig_p) + return +} + +func (arg1 SwigcptrOuter) SetInside5(arg2 Named) { + _swig_wrap_Outer_inside5_set(arg1, arg2.Swigcptr()) +} + +var _wrap_Outer_inside5_get unsafe.Pointer + +func _swig_wrap_Outer_inside5_get(base SwigcptrOuter) (_ SwigcptrNamed) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Outer_inside5_get, _swig_p) + return +} + +func (arg1 SwigcptrOuter) GetInside5() (_swig_ret Named) { + return _swig_wrap_Outer_inside5_get(arg1) +} + +var _wrap_Outer_inner1_get unsafe.Pointer + +func _swig_wrap_Outer_inner1_get(base SwigcptrOuter) (_ SwigcptrOuter_inner1) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Outer_inner1_get, _swig_p) + return +} + +func (arg1 SwigcptrOuter) GetInner1() (_swig_ret Outer_inner1) { + return _swig_wrap_Outer_inner1_get(arg1) +} + +var _wrap_Outer_inner2_get unsafe.Pointer + +func _swig_wrap_Outer_inner2_get(base SwigcptrOuter) (_ SwigcptrOuter_inner1) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Outer_inner2_get, _swig_p) + return +} + +func (arg1 SwigcptrOuter) GetInner2() (_swig_ret Outer_inner1) { + return _swig_wrap_Outer_inner2_get(arg1) +} + +var _wrap_Outer_inner3_get unsafe.Pointer + +func _swig_wrap_Outer_inner3_get(base SwigcptrOuter) (_ SwigcptrOuter_inner1) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Outer_inner3_get, _swig_p) + return +} + +func (arg1 SwigcptrOuter) GetInner3() (_swig_ret Outer_inner1) { + return _swig_wrap_Outer_inner3_get(arg1) +} + +var _wrap_Outer_inner4_get unsafe.Pointer + +func _swig_wrap_Outer_inner4_get(base SwigcptrOuter) (_ SwigcptrOuter_inner1) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Outer_inner4_get, _swig_p) + return +} + +func (arg1 SwigcptrOuter) GetInner4() (_swig_ret Outer_inner1) { + return _swig_wrap_Outer_inner4_get(arg1) +} + +var _wrap_Outer_inner5_get unsafe.Pointer + +func _swig_wrap_Outer_inner5_get(base SwigcptrOuter) (_ SwigcptrOuter_inner1) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Outer_inner5_get, _swig_p) + return +} + +func (arg1 SwigcptrOuter) GetInner5() (_swig_ret Outer_inner1) { + return _swig_wrap_Outer_inner5_get(arg1) +} + +var _wrap_new_Outer unsafe.Pointer + +func _swig_wrap_new_Outer() (base SwigcptrOuter) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Outer, _swig_p) + return +} + +func NewOuter() (_swig_ret Outer) { + return _swig_wrap_new_Outer() +} + +var _wrap_delete_Outer unsafe.Pointer + +func _swig_wrap_delete_Outer(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Outer, _swig_p) + return +} + +func DeleteOuter(arg1 Outer) { + _swig_wrap_delete_Outer(arg1.Swigcptr()) +} + +type Outer interface { + Swigcptr() uintptr + SwigIsOuter() + SetInside1(arg2 Named) + GetInside1() (_swig_ret Named) + SetInside2(arg2 Named) + GetInside2() (_swig_ret Named) + SetInside3(arg2 Named) + GetInside3() (_swig_ret Named) + SetInside4(arg2 Named) + GetInside4() (_swig_ret Named) + SetInside5(arg2 Named) + GetInside5() (_swig_ret Named) + GetInner1() (_swig_ret Outer_inner1) + GetInner2() (_swig_ret Outer_inner1) + GetInner3() (_swig_ret Outer_inner1) + GetInner4() (_swig_ret Outer_inner1) + GetInner5() (_swig_ret Outer_inner1) +} + +type SwigcptrOuter_inner1 uintptr + +func (p SwigcptrOuter_inner1) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrOuter_inner1) SwigIsOuter_inner1() { +} + +var _wrap_Outer_inner1_val_set unsafe.Pointer + +func _swig_wrap_Outer_inner1_val_set(base SwigcptrOuter_inner1, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Outer_inner1_val_set, _swig_p) + return +} + +func (arg1 SwigcptrOuter_inner1) SetVal(arg2 int) { + _swig_wrap_Outer_inner1_val_set(arg1, arg2) +} + +var _wrap_Outer_inner1_val_get unsafe.Pointer + +func _swig_wrap_Outer_inner1_val_get(base SwigcptrOuter_inner1) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Outer_inner1_val_get, _swig_p) + return +} + +func (arg1 SwigcptrOuter_inner1) GetVal() (_swig_ret int) { + return _swig_wrap_Outer_inner1_val_get(arg1) +} + +var _wrap_new_Outer_inner1 unsafe.Pointer + +func _swig_wrap_new_Outer_inner1() (base SwigcptrOuter_inner1) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Outer_inner1, _swig_p) + return +} + +func NewOuter_inner1() (_swig_ret Outer_inner1) { + return _swig_wrap_new_Outer_inner1() +} + +var _wrap_delete_Outer_inner1 unsafe.Pointer + +func _swig_wrap_delete_Outer_inner1(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Outer_inner1, _swig_p) + return +} + +func DeleteOuter_inner1(arg1 Outer_inner1) { + _swig_wrap_delete_Outer_inner1(arg1.Swigcptr()) +} + +type Outer_inner1 interface { + Swigcptr() uintptr + SwigIsOuter_inner1() + SetVal(arg2 int) + GetVal() (_swig_ret int) +} + +type SwigcptrNamed uintptr + +func (p SwigcptrNamed) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrNamed) SwigIsNamed() { +} + +var _wrap_Named_val_set unsafe.Pointer + +func _swig_wrap_Named_val_set(base SwigcptrNamed, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Named_val_set, _swig_p) + return +} + +func (arg1 SwigcptrNamed) SetVal(arg2 int) { + _swig_wrap_Named_val_set(arg1, arg2) +} + +var _wrap_Named_val_get unsafe.Pointer + +func _swig_wrap_Named_val_get(base SwigcptrNamed) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Named_val_get, _swig_p) + return +} + +func (arg1 SwigcptrNamed) GetVal() (_swig_ret int) { + return _swig_wrap_Named_val_get(arg1) +} + +var _wrap_new_Named unsafe.Pointer + +func _swig_wrap_new_Named() (base SwigcptrNamed) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Named, _swig_p) + return +} + +func NewNamed() (_swig_ret Named) { + return _swig_wrap_new_Named() +} + +var _wrap_delete_Named unsafe.Pointer + +func _swig_wrap_delete_Named(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Named, _swig_p) + return +} + +func DeleteNamed(arg1 Named) { + _swig_wrap_delete_Named(arg1.Swigcptr()) +} + +type Named interface { + Swigcptr() uintptr + SwigIsNamed() + SetVal(arg2 int) + GetVal() (_swig_ret int) +} + +var _wrap_outer_set unsafe.Pointer + +func _swig_wrap_outer_set(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_outer_set, _swig_p) + return +} + +func SetOuter(arg1 Outer) { + _swig_wrap_outer_set(arg1.Swigcptr()) +} + +var _wrap_outer_get unsafe.Pointer + +func _swig_wrap_outer_get() (base SwigcptrOuter) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_outer_get, _swig_p) + return +} + +func GetOuter() (_swig_ret Outer) { + return _swig_wrap_outer_get() +} + +var _wrap_setValues unsafe.Pointer + +func _swig_wrap_setValues(base uintptr, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_setValues, _swig_p) + return +} + +func SetValues(arg1 Outer, arg2 int) { + _swig_wrap_setValues(arg1.Swigcptr(), arg2) +} + +var _wrap_getInside1Val unsafe.Pointer + +func _swig_wrap_getInside1Val(base uintptr) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_getInside1Val, _swig_p) + return +} + +func GetInside1Val(arg1 Outer) (_swig_ret int) { + return _swig_wrap_getInside1Val(arg1.Swigcptr()) +} + +var _wrap_nestedByVal unsafe.Pointer + +func _swig_wrap_nestedByVal(base uintptr) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_nestedByVal, _swig_p) + return +} + +func NestedByVal(arg1 Named) (_swig_ret int) { + return _swig_wrap_nestedByVal(arg1.Swigcptr()) +} + +var _wrap_nestedByPtr unsafe.Pointer + +func _swig_wrap_nestedByPtr(base uintptr) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_nestedByPtr, _swig_p) + return +} + +func NestedByPtr(arg1 Named) (_swig_ret int) { + return _swig_wrap_nestedByPtr(arg1.Swigcptr()) +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/nested_workaround.go b/Examples/test-suite/go/nested_workaround.go new file mode 100644 index 000000000..5ecffc810 --- /dev/null +++ b/Examples/test-suite/go/nested_workaround.go @@ -0,0 +1,201 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../nested_workaround.i + +package nested_workaround + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrOuter uintptr + +func (p SwigcptrOuter) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrOuter) SwigIsOuter() { +} + +var _wrap_Outer_createInner unsafe.Pointer + +func _swig_wrap_Outer_createInner(base SwigcptrOuter, _ int) (_ SwigcptrInner) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Outer_createInner, _swig_p) + return +} + +func (arg1 SwigcptrOuter) CreateInner(arg2 int) (_swig_ret Inner) { + return _swig_wrap_Outer_createInner(arg1, arg2) +} + +var _wrap_Outer_getInnerValue unsafe.Pointer + +func _swig_wrap_Outer_getInnerValue(base SwigcptrOuter, _ uintptr) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Outer_getInnerValue, _swig_p) + return +} + +func (arg1 SwigcptrOuter) GetInnerValue(arg2 Inner) (_swig_ret int) { + return _swig_wrap_Outer_getInnerValue(arg1, arg2.Swigcptr()) +} + +var _wrap_Outer_doubleInnerValue unsafe.Pointer + +func _swig_wrap_Outer_doubleInnerValue(base SwigcptrOuter, _ uintptr) (_ SwigcptrInner) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Outer_doubleInnerValue, _swig_p) + return +} + +func (arg1 SwigcptrOuter) DoubleInnerValue(arg2 Inner) (_swig_ret Inner) { + return _swig_wrap_Outer_doubleInnerValue(arg1, arg2.Swigcptr()) +} + +var _wrap_new_Outer unsafe.Pointer + +func _swig_wrap_new_Outer() (base SwigcptrOuter) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Outer, _swig_p) + return +} + +func NewOuter() (_swig_ret Outer) { + return _swig_wrap_new_Outer() +} + +var _wrap_delete_Outer unsafe.Pointer + +func _swig_wrap_delete_Outer(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Outer, _swig_p) + return +} + +func DeleteOuter(arg1 Outer) { + _swig_wrap_delete_Outer(arg1.Swigcptr()) +} + +type Outer interface { + Swigcptr() uintptr + SwigIsOuter() + CreateInner(arg2 int) (_swig_ret Inner) + GetInnerValue(arg2 Inner) (_swig_ret int) + DoubleInnerValue(arg2 Inner) (_swig_ret Inner) +} + +type SwigcptrInner uintptr + +func (p SwigcptrInner) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrInner) SwigIsInner() { +} + +var _wrap_new_Inner__SWIG_0 unsafe.Pointer + +func _swig_wrap_new_Inner__SWIG_0(base int) (_ SwigcptrInner) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Inner__SWIG_0, _swig_p) + return +} + +func NewInner__SWIG_0(arg1 int) (_swig_ret Inner) { + return _swig_wrap_new_Inner__SWIG_0(arg1) +} + +var _wrap_new_Inner__SWIG_1 unsafe.Pointer + +func _swig_wrap_new_Inner__SWIG_1() (base SwigcptrInner) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Inner__SWIG_1, _swig_p) + return +} + +func NewInner__SWIG_1() (_swig_ret Inner) { + return _swig_wrap_new_Inner__SWIG_1() +} + +func NewInner(a ...interface{}) Inner { + argc := len(a) + if argc == 0 { + return NewInner__SWIG_1() + } + if argc == 1 { + return NewInner__SWIG_0(a[0].(int)) + } + panic("No match for overloaded function call") +} + +var _wrap_Inner_setValue unsafe.Pointer + +func _swig_wrap_Inner_setValue(base SwigcptrInner, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Inner_setValue, _swig_p) + return +} + +func (arg1 SwigcptrInner) SetValue(arg2 int) { + _swig_wrap_Inner_setValue(arg1, arg2) +} + +var _wrap_Inner_getValue unsafe.Pointer + +func _swig_wrap_Inner_getValue(base SwigcptrInner) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Inner_getValue, _swig_p) + return +} + +func (arg1 SwigcptrInner) GetValue() (_swig_ret int) { + return _swig_wrap_Inner_getValue(arg1) +} + +var _wrap_delete_Inner unsafe.Pointer + +func _swig_wrap_delete_Inner(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Inner, _swig_p) + return +} + +func DeleteInner(arg1 Inner) { + _swig_wrap_delete_Inner(arg1.Swigcptr()) +} + +type Inner interface { + Swigcptr() uintptr + SwigIsInner() + SetValue(arg2 int) + GetValue() (_swig_ret int) +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/nested_workaround_runme b/Examples/test-suite/go/nested_workaround_runme new file mode 100755 index 000000000..dcfc224c5 Binary files /dev/null and b/Examples/test-suite/go/nested_workaround_runme differ diff --git a/Examples/test-suite/go/newobject1.go b/Examples/test-suite/go/newobject1.go new file mode 100644 index 000000000..71faa6c51 --- /dev/null +++ b/Examples/test-suite/go/newobject1.go @@ -0,0 +1,95 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../newobject1.i + +package newobject1 + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrFoo uintptr + +func (p SwigcptrFoo) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrFoo) SwigIsFoo() { +} + +var _wrap_Foo_makeFoo unsafe.Pointer + +func _swig_wrap_Foo_makeFoo() (base SwigcptrFoo) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_makeFoo, _swig_p) + return +} + +func FooMakeFoo() (_swig_ret Foo) { + return _swig_wrap_Foo_makeFoo() +} + +var _wrap_Foo_makeMore unsafe.Pointer + +func _swig_wrap_Foo_makeMore(base SwigcptrFoo) (_ SwigcptrFoo) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_makeMore, _swig_p) + return +} + +func (arg1 SwigcptrFoo) MakeMore() (_swig_ret Foo) { + return _swig_wrap_Foo_makeMore(arg1) +} + +var _wrap_Foo_fooCount unsafe.Pointer + +func FooFooCount() (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_Foo_fooCount, _swig_p) + return +} +var _wrap_delete_Foo unsafe.Pointer + +func _swig_wrap_delete_Foo(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Foo, _swig_p) + return +} + +func DeleteFoo(arg1 Foo) { + _swig_wrap_delete_Foo(arg1.Swigcptr()) +} + +type Foo interface { + Swigcptr() uintptr + SwigIsFoo() + MakeMore() (_swig_ret Foo) +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/newobject2.go b/Examples/test-suite/go/newobject2.go new file mode 100644 index 000000000..d8d38c76d --- /dev/null +++ b/Examples/test-suite/go/newobject2.go @@ -0,0 +1,132 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../newobject2.i + +package newobject2 + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrFoo uintptr + +func (p SwigcptrFoo) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrFoo) SwigIsFoo() { +} + +var _wrap_Foo_dummy_set unsafe.Pointer + +func _swig_wrap_Foo_dummy_set(base SwigcptrFoo, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_dummy_set, _swig_p) + return +} + +func (arg1 SwigcptrFoo) SetDummy(arg2 int) { + _swig_wrap_Foo_dummy_set(arg1, arg2) +} + +var _wrap_Foo_dummy_get unsafe.Pointer + +func _swig_wrap_Foo_dummy_get(base SwigcptrFoo) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_dummy_get, _swig_p) + return +} + +func (arg1 SwigcptrFoo) GetDummy() (_swig_ret int) { + return _swig_wrap_Foo_dummy_get(arg1) +} + +var _wrap_delete_Foo unsafe.Pointer + +func _swig_wrap_delete_Foo(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Foo, _swig_p) + return +} + +func DeleteFoo(arg1 Foo) { + _swig_wrap_delete_Foo(arg1.Swigcptr()) +} + +var _wrap_new_Foo unsafe.Pointer + +func _swig_wrap_new_Foo() (base SwigcptrFoo) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Foo, _swig_p) + return +} + +func NewFoo() (_swig_ret Foo) { + return _swig_wrap_new_Foo() +} + +type Foo interface { + Swigcptr() uintptr + SwigIsFoo() + SetDummy(arg2 int) + GetDummy() (_swig_ret int) +} + +var _wrap_makeFoo unsafe.Pointer + +func _swig_wrap_makeFoo() (base SwigcptrFoo) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_makeFoo, _swig_p) + return +} + +func MakeFoo() (_swig_ret Foo) { + return _swig_wrap_makeFoo() +} + +var _wrap_fooCount unsafe.Pointer + +func FooCount() (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_fooCount, _swig_p) + return +} +var _wrap_do_stuff unsafe.Pointer + +func _swig_wrap_do_stuff(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_do_stuff, _swig_p) + return +} + +func Do_stuff(arg1 Foo) { + _swig_wrap_do_stuff(arg1.Swigcptr()) +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/nspace.go b/Examples/test-suite/go/nspace.go new file mode 100644 index 000000000..25d158c8d --- /dev/null +++ b/Examples/test-suite/go/nspace.go @@ -0,0 +1,29 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../nspace.i + +package nspace + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + + diff --git a/Examples/test-suite/go/nspace_extend.go b/Examples/test-suite/go/nspace_extend.go new file mode 100644 index 000000000..89ae7fb04 --- /dev/null +++ b/Examples/test-suite/go/nspace_extend.go @@ -0,0 +1,29 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../nspace_extend.i + +package nspace_extend + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + + diff --git a/Examples/test-suite/go/null_pointer.go b/Examples/test-suite/go/null_pointer.go new file mode 100644 index 000000000..13d6a7914 --- /dev/null +++ b/Examples/test-suite/go/null_pointer.go @@ -0,0 +1,99 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../null_pointer.i + +package null_pointer + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrA uintptr + +func (p SwigcptrA) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrA) SwigIsA() { +} + +var _wrap_new_A unsafe.Pointer + +func _swig_wrap_new_A() (base SwigcptrA) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_A, _swig_p) + return +} + +func NewA() (_swig_ret A) { + return _swig_wrap_new_A() +} + +var _wrap_delete_A unsafe.Pointer + +func _swig_wrap_delete_A(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_A, _swig_p) + return +} + +func DeleteA(arg1 A) { + _swig_wrap_delete_A(arg1.Swigcptr()) +} + +type A interface { + Swigcptr() uintptr + SwigIsA() +} + +var _wrap_Xfunc unsafe.Pointer + +func _swig_wrap_Xfunc(base uintptr) (_ bool) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Xfunc, _swig_p) + return +} + +func Xfunc(arg1 A) (_swig_ret bool) { + return _swig_wrap_Xfunc(arg1.Swigcptr()) +} + +var _wrap_getnull unsafe.Pointer + +func _swig_wrap_getnull() (base SwigcptrA) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_getnull, _swig_p) + return +} + +func Getnull() (_swig_ret A) { + return _swig_wrap_getnull() +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/operator_overload.go b/Examples/test-suite/go/operator_overload.go new file mode 100644 index 000000000..1ce96277d --- /dev/null +++ b/Examples/test-suite/go/operator_overload.go @@ -0,0 +1,1152 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../operator_overload.i + +package operator_overload + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrOp uintptr + +func (p SwigcptrOp) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrOp) SwigIsOp() { +} + +var _wrap_Op_i_set unsafe.Pointer + +func _swig_wrap_Op_i_set(base SwigcptrOp, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Op_i_set, _swig_p) + return +} + +func (arg1 SwigcptrOp) SetI(arg2 int) { + _swig_wrap_Op_i_set(arg1, arg2) +} + +var _wrap_Op_i_get unsafe.Pointer + +func _swig_wrap_Op_i_get(base SwigcptrOp) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Op_i_get, _swig_p) + return +} + +func (arg1 SwigcptrOp) GetI() (_swig_ret int) { + return _swig_wrap_Op_i_get(arg1) +} + +var _wrap_new_Op__SWIG_0 unsafe.Pointer + +func _swig_wrap_new_Op__SWIG_0(base int) (_ SwigcptrOp) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Op__SWIG_0, _swig_p) + return +} + +func NewOp__SWIG_0(arg1 int) (_swig_ret Op) { + return _swig_wrap_new_Op__SWIG_0(arg1) +} + +var _wrap_new_Op__SWIG_1 unsafe.Pointer + +func _swig_wrap_new_Op__SWIG_1() (base SwigcptrOp) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Op__SWIG_1, _swig_p) + return +} + +func NewOp__SWIG_1() (_swig_ret Op) { + return _swig_wrap_new_Op__SWIG_1() +} + +var _wrap_new_Op__SWIG_2 unsafe.Pointer + +func _swig_wrap_new_Op__SWIG_2(base uintptr) (_ SwigcptrOp) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Op__SWIG_2, _swig_p) + return +} + +func NewOp__SWIG_2(arg1 Op) (_swig_ret Op) { + return _swig_wrap_new_Op__SWIG_2(arg1.Swigcptr()) +} + +func NewOp(a ...interface{}) Op { + argc := len(a) + if argc == 0 { + return NewOp__SWIG_1() + } + if argc == 1 { + if _, ok := a[0].(Op); !ok { + goto check_2 + } + return NewOp__SWIG_2(a[0].(Op)) + } +check_2: + if argc == 1 { + return NewOp__SWIG_0(a[0].(int)) + } + panic("No match for overloaded function call") +} + +var _wrap_delete_Op unsafe.Pointer + +func _swig_wrap_delete_Op(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Op, _swig_p) + return +} + +func DeleteOp(arg1 Op) { + _swig_wrap_delete_Op(arg1.Swigcptr()) +} + +var _wrap_And unsafe.Pointer + +func _swig_wrap_And(base uintptr, _ uintptr) (_ SwigcptrOp) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_And, _swig_p) + return +} + +func And(arg1 Op, arg2 Op) (_swig_ret Op) { + return _swig_wrap_And(arg1.Swigcptr(), arg2.Swigcptr()) +} + +var _wrap_Or unsafe.Pointer + +func _swig_wrap_Or(base uintptr, _ uintptr) (_ SwigcptrOp) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Or, _swig_p) + return +} + +func Or(arg1 Op, arg2 Op) (_swig_ret Op) { + return _swig_wrap_Or(arg1.Swigcptr(), arg2.Swigcptr()) +} + +var _wrap_Op_Equal unsafe.Pointer + +func _swig_wrap_Op_Equal(base SwigcptrOp, _ uintptr) (_ SwigcptrOp) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Op_Equal, _swig_p) + return +} + +func (arg1 SwigcptrOp) Equal(arg2 Op) (_swig_ret Op) { + return _swig_wrap_Op_Equal(arg1, arg2.Swigcptr()) +} + +var _wrap_Op_PlusEqual unsafe.Pointer + +func _swig_wrap_Op_PlusEqual(base SwigcptrOp, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Op_PlusEqual, _swig_p) + return +} + +func (arg1 SwigcptrOp) PlusEqual(arg2 Op) { + _swig_wrap_Op_PlusEqual(arg1, arg2.Swigcptr()) +} + +var _wrap_Op_MinusEqual unsafe.Pointer + +func _swig_wrap_Op_MinusEqual(base SwigcptrOp, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Op_MinusEqual, _swig_p) + return +} + +func (arg1 SwigcptrOp) MinusEqual(arg2 Op) { + _swig_wrap_Op_MinusEqual(arg1, arg2.Swigcptr()) +} + +var _wrap_Op_MultiplyEqual unsafe.Pointer + +func _swig_wrap_Op_MultiplyEqual(base SwigcptrOp, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Op_MultiplyEqual, _swig_p) + return +} + +func (arg1 SwigcptrOp) MultiplyEqual(arg2 Op) { + _swig_wrap_Op_MultiplyEqual(arg1, arg2.Swigcptr()) +} + +var _wrap_Op_DivideEqual unsafe.Pointer + +func _swig_wrap_Op_DivideEqual(base SwigcptrOp, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Op_DivideEqual, _swig_p) + return +} + +func (arg1 SwigcptrOp) DivideEqual(arg2 Op) { + _swig_wrap_Op_DivideEqual(arg1, arg2.Swigcptr()) +} + +var _wrap_Op_PercentEqual unsafe.Pointer + +func _swig_wrap_Op_PercentEqual(base SwigcptrOp, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Op_PercentEqual, _swig_p) + return +} + +func (arg1 SwigcptrOp) PercentEqual(arg2 Op) { + _swig_wrap_Op_PercentEqual(arg1, arg2.Swigcptr()) +} + +var _wrap_Plus unsafe.Pointer + +func _swig_wrap_Plus(base uintptr, _ uintptr) (_ SwigcptrOp) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Plus, _swig_p) + return +} + +func Plus(arg1 Op, arg2 Op) (_swig_ret Op) { + return _swig_wrap_Plus(arg1.Swigcptr(), arg2.Swigcptr()) +} + +var _wrap_Minus unsafe.Pointer + +func _swig_wrap_Minus(base uintptr, _ uintptr) (_ SwigcptrOp) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Minus, _swig_p) + return +} + +func Minus(arg1 Op, arg2 Op) (_swig_ret Op) { + return _swig_wrap_Minus(arg1.Swigcptr(), arg2.Swigcptr()) +} + +var _wrap_Multiply unsafe.Pointer + +func _swig_wrap_Multiply(base uintptr, _ uintptr) (_ SwigcptrOp) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Multiply, _swig_p) + return +} + +func Multiply(arg1 Op, arg2 Op) (_swig_ret Op) { + return _swig_wrap_Multiply(arg1.Swigcptr(), arg2.Swigcptr()) +} + +var _wrap_Divide unsafe.Pointer + +func _swig_wrap_Divide(base uintptr, _ uintptr) (_ SwigcptrOp) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Divide, _swig_p) + return +} + +func Divide(arg1 Op, arg2 Op) (_swig_ret Op) { + return _swig_wrap_Divide(arg1.Swigcptr(), arg2.Swigcptr()) +} + +var _wrap_Percent unsafe.Pointer + +func _swig_wrap_Percent(base uintptr, _ uintptr) (_ SwigcptrOp) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Percent, _swig_p) + return +} + +func Percent(arg1 Op, arg2 Op) (_swig_ret Op) { + return _swig_wrap_Percent(arg1.Swigcptr(), arg2.Swigcptr()) +} + +var _wrap_Op_Minus__SWIG_0 unsafe.Pointer + +func _swig_wrap_Op_Minus__SWIG_0(base SwigcptrOp) (_ SwigcptrOp) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Op_Minus__SWIG_0, _swig_p) + return +} + +func (arg1 SwigcptrOp) Minus__SWIG_0() (_swig_ret Op) { + return _swig_wrap_Op_Minus__SWIG_0(arg1) +} + +var _wrap_Op_Not unsafe.Pointer + +func _swig_wrap_Op_Not(base SwigcptrOp) (_ bool) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Op_Not, _swig_p) + return +} + +func (arg1 SwigcptrOp) Not() (_swig_ret bool) { + return _swig_wrap_Op_Not(arg1) +} + +var _wrap_Op_IndexIntoConst unsafe.Pointer + +func _swig_wrap_Op_IndexIntoConst(base SwigcptrOp, _ uint) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Op_IndexIntoConst, _swig_p) + return +} + +func (arg1 SwigcptrOp) IndexIntoConst(arg2 uint) (_swig_ret int) { + return _swig_wrap_Op_IndexIntoConst(arg1, arg2) +} + +var _wrap_Op_IndexInto unsafe.Pointer + +func _swig_wrap_Op_IndexInto(base SwigcptrOp, _ uint) (_ *int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Op_IndexInto, _swig_p) + return +} + +func (arg1 SwigcptrOp) IndexInto(arg2 uint) (_swig_ret *int) { + return _swig_wrap_Op_IndexInto(arg1, arg2) +} + +var _wrap_Op_Functor__SWIG_0 unsafe.Pointer + +func _swig_wrap_Op_Functor__SWIG_0(base SwigcptrOp, _ int) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Op_Functor__SWIG_0, _swig_p) + return +} + +func (arg1 SwigcptrOp) Functor__SWIG_0(arg2 int) (_swig_ret int) { + return _swig_wrap_Op_Functor__SWIG_0(arg1, arg2) +} + +var _wrap_Op_Functor__SWIG_1 unsafe.Pointer + +func _swig_wrap_Op_Functor__SWIG_1(base SwigcptrOp) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Op_Functor__SWIG_1, _swig_p) + return +} + +func (arg1 SwigcptrOp) Functor__SWIG_1() (_swig_ret int) { + return _swig_wrap_Op_Functor__SWIG_1(arg1) +} + +var _wrap_Op_Functor__SWIG_2 unsafe.Pointer + +func _swig_wrap_Op_Functor__SWIG_2(base SwigcptrOp, _ int, _ int) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Op_Functor__SWIG_2, _swig_p) + return +} + +func (arg1 SwigcptrOp) Functor__SWIG_2(arg2 int, arg3 int) (_swig_ret int) { + return _swig_wrap_Op_Functor__SWIG_2(arg1, arg2, arg3) +} + +func (p SwigcptrOp) Functor(a ...interface{}) int { + argc := len(a) + if argc == 0 { + return p.Functor__SWIG_1() + } + if argc == 1 { + return p.Functor__SWIG_0(a[0].(int)) + } + if argc == 2 { + return p.Functor__SWIG_2(a[0].(int), a[1].(int)) + } + panic("No match for overloaded function call") +} + +var _wrap_Op_PlusPlusPrefix unsafe.Pointer + +func _swig_wrap_Op_PlusPlusPrefix(base SwigcptrOp) (_ SwigcptrOp) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Op_PlusPlusPrefix, _swig_p) + return +} + +func (arg1 SwigcptrOp) PlusPlusPrefix() (_swig_ret Op) { + return _swig_wrap_Op_PlusPlusPrefix(arg1) +} + +var _wrap_Op_PlusPlusPostfix unsafe.Pointer + +func _swig_wrap_Op_PlusPlusPostfix(base SwigcptrOp, _ int) (_ SwigcptrOp) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Op_PlusPlusPostfix, _swig_p) + return +} + +func (arg1 SwigcptrOp) PlusPlusPostfix(arg2 int) (_swig_ret Op) { + return _swig_wrap_Op_PlusPlusPostfix(arg1, arg2) +} + +var _wrap_Op_MinusMinusPrefix unsafe.Pointer + +func _swig_wrap_Op_MinusMinusPrefix(base SwigcptrOp) (_ SwigcptrOp) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Op_MinusMinusPrefix, _swig_p) + return +} + +func (arg1 SwigcptrOp) MinusMinusPrefix() (_swig_ret Op) { + return _swig_wrap_Op_MinusMinusPrefix(arg1) +} + +var _wrap_Op_MinusMinusPostfix unsafe.Pointer + +func _swig_wrap_Op_MinusMinusPostfix(base SwigcptrOp, _ int) (_ SwigcptrOp) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Op_MinusMinusPostfix, _swig_p) + return +} + +func (arg1 SwigcptrOp) MinusMinusPostfix(arg2 int) (_swig_ret Op) { + return _swig_wrap_Op_MinusMinusPostfix(arg1, arg2) +} + +var _wrap_Op_DoubleCast unsafe.Pointer + +func _swig_wrap_Op_DoubleCast(base SwigcptrOp) (_ float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Op_DoubleCast, _swig_p) + return +} + +func (arg1 SwigcptrOp) DoubleCast() (_swig_ret float64) { + return _swig_wrap_Op_DoubleCast(arg1) +} + +var _wrap_Op_IntCast unsafe.Pointer + +func _swig_wrap_Op_IntCast(base SwigcptrOp) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Op_IntCast, _swig_p) + return +} + +func (arg1 SwigcptrOp) IntCast() (_swig_ret int) { + return _swig_wrap_Op_IntCast(arg1) +} + +var _wrap_Op_sanity_check unsafe.Pointer + +func _swig_wrap_Op_sanity_check() { + var _swig_p uintptr + _cgo_runtime_cgocall(_wrap_Op_sanity_check, _swig_p) + return +} + +func OpSanity_check() { + _swig_wrap_Op_sanity_check() +} + +var _wrap_Op_And unsafe.Pointer + +func _swig_wrap_Op_And(base SwigcptrOp, _ uintptr) (_ SwigcptrOp) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Op_And, _swig_p) + return +} + +func (arg1 SwigcptrOp) And(arg2 Op) (_swig_ret Op) { + return _swig_wrap_Op_And(arg1, arg2.Swigcptr()) +} + +var _wrap_Op_Or unsafe.Pointer + +func _swig_wrap_Op_Or(base SwigcptrOp, _ uintptr) (_ SwigcptrOp) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Op_Or, _swig_p) + return +} + +func (arg1 SwigcptrOp) Or(arg2 Op) (_swig_ret Op) { + return _swig_wrap_Op_Or(arg1, arg2.Swigcptr()) +} + +var _wrap_Op_Plus unsafe.Pointer + +func _swig_wrap_Op_Plus(base SwigcptrOp, _ uintptr) (_ SwigcptrOp) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Op_Plus, _swig_p) + return +} + +func (arg1 SwigcptrOp) Plus(arg2 Op) (_swig_ret Op) { + return _swig_wrap_Op_Plus(arg1, arg2.Swigcptr()) +} + +var _wrap_Op_Minus__SWIG_1 unsafe.Pointer + +func _swig_wrap_Op_Minus__SWIG_1(base SwigcptrOp, _ uintptr) (_ SwigcptrOp) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Op_Minus__SWIG_1, _swig_p) + return +} + +func (arg1 SwigcptrOp) Minus__SWIG_1(arg2 Op) (_swig_ret Op) { + return _swig_wrap_Op_Minus__SWIG_1(arg1, arg2.Swigcptr()) +} + +func (p SwigcptrOp) Minus(a ...interface{}) Op { + argc := len(a) + if argc == 0 { + return p.Minus__SWIG_0() + } + if argc == 1 { + return p.Minus__SWIG_1(a[0].(Op)) + } + panic("No match for overloaded function call") +} + +var _wrap_Op_Multiply unsafe.Pointer + +func _swig_wrap_Op_Multiply(base SwigcptrOp, _ uintptr) (_ SwigcptrOp) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Op_Multiply, _swig_p) + return +} + +func (arg1 SwigcptrOp) Multiply(arg2 Op) (_swig_ret Op) { + return _swig_wrap_Op_Multiply(arg1, arg2.Swigcptr()) +} + +var _wrap_Op_Divide unsafe.Pointer + +func _swig_wrap_Op_Divide(base SwigcptrOp, _ uintptr) (_ SwigcptrOp) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Op_Divide, _swig_p) + return +} + +func (arg1 SwigcptrOp) Divide(arg2 Op) (_swig_ret Op) { + return _swig_wrap_Op_Divide(arg1, arg2.Swigcptr()) +} + +var _wrap_Op_Percent unsafe.Pointer + +func _swig_wrap_Op_Percent(base SwigcptrOp, _ uintptr) (_ SwigcptrOp) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Op_Percent, _swig_p) + return +} + +func (arg1 SwigcptrOp) Percent(arg2 Op) (_swig_ret Op) { + return _swig_wrap_Op_Percent(arg1, arg2.Swigcptr()) +} + +var _wrap_Op_EqualEqual unsafe.Pointer + +func _swig_wrap_Op_EqualEqual(base SwigcptrOp, _ uintptr) (_ bool) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Op_EqualEqual, _swig_p) + return +} + +func (arg1 SwigcptrOp) EqualEqual(arg2 Op) (_swig_ret bool) { + return _swig_wrap_Op_EqualEqual(arg1, arg2.Swigcptr()) +} + +var _wrap_Op_NotEqual unsafe.Pointer + +func _swig_wrap_Op_NotEqual(base SwigcptrOp, _ uintptr) (_ bool) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Op_NotEqual, _swig_p) + return +} + +func (arg1 SwigcptrOp) NotEqual(arg2 Op) (_swig_ret bool) { + return _swig_wrap_Op_NotEqual(arg1, arg2.Swigcptr()) +} + +var _wrap_Op_LessThan unsafe.Pointer + +func _swig_wrap_Op_LessThan(base SwigcptrOp, _ uintptr) (_ bool) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Op_LessThan, _swig_p) + return +} + +func (arg1 SwigcptrOp) LessThan(arg2 Op) (_swig_ret bool) { + return _swig_wrap_Op_LessThan(arg1, arg2.Swigcptr()) +} + +var _wrap_Op_LessThanEqual unsafe.Pointer + +func _swig_wrap_Op_LessThanEqual(base SwigcptrOp, _ uintptr) (_ bool) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Op_LessThanEqual, _swig_p) + return +} + +func (arg1 SwigcptrOp) LessThanEqual(arg2 Op) (_swig_ret bool) { + return _swig_wrap_Op_LessThanEqual(arg1, arg2.Swigcptr()) +} + +var _wrap_Op_GreaterThan unsafe.Pointer + +func _swig_wrap_Op_GreaterThan(base SwigcptrOp, _ uintptr) (_ bool) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Op_GreaterThan, _swig_p) + return +} + +func (arg1 SwigcptrOp) GreaterThan(arg2 Op) (_swig_ret bool) { + return _swig_wrap_Op_GreaterThan(arg1, arg2.Swigcptr()) +} + +var _wrap_Op_GreaterThanEqual unsafe.Pointer + +func _swig_wrap_Op_GreaterThanEqual(base SwigcptrOp, _ uintptr) (_ bool) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Op_GreaterThanEqual, _swig_p) + return +} + +func (arg1 SwigcptrOp) GreaterThanEqual(arg2 Op) (_swig_ret bool) { + return _swig_wrap_Op_GreaterThanEqual(arg1, arg2.Swigcptr()) +} + +var _wrap_Op___rsub__ unsafe.Pointer + +func _swig_wrap_Op___rsub__(base SwigcptrOp, _ int) (_ SwigcptrOp) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Op___rsub__, _swig_p) + return +} + +func (arg1 SwigcptrOp) X__rsub__(arg2 int) (_swig_ret Op) { + return _swig_wrap_Op___rsub__(arg1, arg2) +} + +var _wrap_Op___str__ unsafe.Pointer + +func _swig_wrap_Op___str__(base SwigcptrOp) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Op___str__, _swig_p) + return +} + +func (arg1 SwigcptrOp) X__str__() (_swig_ret string) { + return _swig_wrap_Op___str__(arg1) +} + +var _wrap_Op___getitem__ unsafe.Pointer + +func _swig_wrap_Op___getitem__(base SwigcptrOp, _ uint) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Op___getitem__, _swig_p) + return +} + +func (arg1 SwigcptrOp) X__getitem__(arg2 uint) (_swig_ret int) { + return _swig_wrap_Op___getitem__(arg1, arg2) +} + +var _wrap_Op___setitem__ unsafe.Pointer + +func _swig_wrap_Op___setitem__(base SwigcptrOp, _ uint, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Op___setitem__, _swig_p) + return +} + +func (arg1 SwigcptrOp) X__setitem__(arg2 uint, arg3 int) { + _swig_wrap_Op___setitem__(arg1, arg2, arg3) +} + +type Op interface { + Swigcptr() uintptr + SwigIsOp() + SetI(arg2 int) + GetI() (_swig_ret int) + Equal(arg2 Op) (_swig_ret Op) + PlusEqual(arg2 Op) + MinusEqual(arg2 Op) + MultiplyEqual(arg2 Op) + DivideEqual(arg2 Op) + PercentEqual(arg2 Op) + Not() (_swig_ret bool) + IndexIntoConst(arg2 uint) (_swig_ret int) + IndexInto(arg2 uint) (_swig_ret *int) + Functor(a ...interface{}) int + PlusPlusPrefix() (_swig_ret Op) + PlusPlusPostfix(arg2 int) (_swig_ret Op) + MinusMinusPrefix() (_swig_ret Op) + MinusMinusPostfix(arg2 int) (_swig_ret Op) + DoubleCast() (_swig_ret float64) + IntCast() (_swig_ret int) + And(arg2 Op) (_swig_ret Op) + Or(arg2 Op) (_swig_ret Op) + Plus(arg2 Op) (_swig_ret Op) + Minus(a ...interface{}) Op + Multiply(arg2 Op) (_swig_ret Op) + Divide(arg2 Op) (_swig_ret Op) + Percent(arg2 Op) (_swig_ret Op) + EqualEqual(arg2 Op) (_swig_ret bool) + NotEqual(arg2 Op) (_swig_ret bool) + LessThan(arg2 Op) (_swig_ret bool) + LessThanEqual(arg2 Op) (_swig_ret bool) + GreaterThan(arg2 Op) (_swig_ret bool) + GreaterThanEqual(arg2 Op) (_swig_ret bool) + X__rsub__(arg2 int) (_swig_ret Op) + X__str__() (_swig_ret string) + X__getitem__(arg2 uint) (_swig_ret int) + X__setitem__(arg2 uint, arg3 int) +} + +var _wrap_EqualEqual unsafe.Pointer + +func _swig_wrap_EqualEqual(base uintptr, _ uintptr) (_ bool) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_EqualEqual, _swig_p) + return +} + +func EqualEqual(arg1 Op, arg2 Op) (_swig_ret bool) { + return _swig_wrap_EqualEqual(arg1.Swigcptr(), arg2.Swigcptr()) +} + +var _wrap_NotEqual unsafe.Pointer + +func _swig_wrap_NotEqual(base uintptr, _ uintptr) (_ bool) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_NotEqual, _swig_p) + return +} + +func NotEqual(arg1 Op, arg2 Op) (_swig_ret bool) { + return _swig_wrap_NotEqual(arg1.Swigcptr(), arg2.Swigcptr()) +} + +var _wrap_LessThan unsafe.Pointer + +func _swig_wrap_LessThan(base uintptr, _ uintptr) (_ bool) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_LessThan, _swig_p) + return +} + +func LessThan(arg1 Op, arg2 Op) (_swig_ret bool) { + return _swig_wrap_LessThan(arg1.Swigcptr(), arg2.Swigcptr()) +} + +var _wrap_LessThanEqual unsafe.Pointer + +func _swig_wrap_LessThanEqual(base uintptr, _ uintptr) (_ bool) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_LessThanEqual, _swig_p) + return +} + +func LessThanEqual(arg1 Op, arg2 Op) (_swig_ret bool) { + return _swig_wrap_LessThanEqual(arg1.Swigcptr(), arg2.Swigcptr()) +} + +var _wrap_GreaterThan unsafe.Pointer + +func _swig_wrap_GreaterThan(base uintptr, _ uintptr) (_ bool) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_GreaterThan, _swig_p) + return +} + +func GreaterThan(arg1 Op, arg2 Op) (_swig_ret bool) { + return _swig_wrap_GreaterThan(arg1.Swigcptr(), arg2.Swigcptr()) +} + +var _wrap_GreaterThanEqual unsafe.Pointer + +func _swig_wrap_GreaterThanEqual(base uintptr, _ uintptr) (_ bool) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_GreaterThanEqual, _swig_p) + return +} + +func GreaterThanEqual(arg1 Op, arg2 Op) (_swig_ret bool) { + return _swig_wrap_GreaterThanEqual(arg1.Swigcptr(), arg2.Swigcptr()) +} + +type SwigcptrOpDerived uintptr + +func (p SwigcptrOpDerived) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrOpDerived) SwigIsOpDerived() { +} + +var _wrap_new_OpDerived__SWIG_0 unsafe.Pointer + +func _swig_wrap_new_OpDerived__SWIG_0(base int) (_ SwigcptrOpDerived) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_OpDerived__SWIG_0, _swig_p) + return +} + +func NewOpDerived__SWIG_0(arg1 int) (_swig_ret OpDerived) { + return _swig_wrap_new_OpDerived__SWIG_0(arg1) +} + +var _wrap_new_OpDerived__SWIG_1 unsafe.Pointer + +func _swig_wrap_new_OpDerived__SWIG_1() (base SwigcptrOpDerived) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_OpDerived__SWIG_1, _swig_p) + return +} + +func NewOpDerived__SWIG_1() (_swig_ret OpDerived) { + return _swig_wrap_new_OpDerived__SWIG_1() +} + +func NewOpDerived(a ...interface{}) OpDerived { + argc := len(a) + if argc == 0 { + return NewOpDerived__SWIG_1() + } + if argc == 1 { + return NewOpDerived__SWIG_0(a[0].(int)) + } + panic("No match for overloaded function call") +} + +var _wrap_OpDerived_IntCast unsafe.Pointer + +func _swig_wrap_OpDerived_IntCast(base SwigcptrOpDerived) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_OpDerived_IntCast, _swig_p) + return +} + +func (arg1 SwigcptrOpDerived) IntCast() (_swig_ret int) { + return _swig_wrap_OpDerived_IntCast(arg1) +} + +var _wrap_delete_OpDerived unsafe.Pointer + +func _swig_wrap_delete_OpDerived(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_OpDerived, _swig_p) + return +} + +func DeleteOpDerived(arg1 OpDerived) { + _swig_wrap_delete_OpDerived(arg1.Swigcptr()) +} + +var _wrap_SetOpDerived_I unsafe.Pointer + +func _swig_wrap_SetOpDerived_I(base SwigcptrOpDerived, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_SetOpDerived_I, _swig_p) + return +} + +func (_swig_base SwigcptrOpDerived) SetI(arg1 int) { + _swig_wrap_SetOpDerived_I(_swig_base, arg1) +} + +var _wrap_GetOpDerived_I unsafe.Pointer + +func _swig_wrap_GetOpDerived_I(base SwigcptrOpDerived) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_GetOpDerived_I, _swig_p) + return +} + +func (_swig_base SwigcptrOpDerived) GetI() (_swig_ret int) { + return _swig_wrap_GetOpDerived_I(_swig_base) +} + +var _wrap_OpDerived_Equal unsafe.Pointer + +func _swig_wrap_OpDerived_Equal(base SwigcptrOpDerived, _ uintptr) (_ SwigcptrOp) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_OpDerived_Equal, _swig_p) + return +} + +func (_swig_base SwigcptrOpDerived) Equal(arg1 Op) (_swig_ret Op) { + return _swig_wrap_OpDerived_Equal(_swig_base, arg1.Swigcptr()) +} + +var _wrap_OpDerived_PlusEqual unsafe.Pointer + +func _swig_wrap_OpDerived_PlusEqual(base SwigcptrOpDerived, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_OpDerived_PlusEqual, _swig_p) + return +} + +func (_swig_base SwigcptrOpDerived) PlusEqual(arg1 Op) { + _swig_wrap_OpDerived_PlusEqual(_swig_base, arg1.Swigcptr()) +} + +var _wrap_OpDerived_MinusEqual unsafe.Pointer + +func _swig_wrap_OpDerived_MinusEqual(base SwigcptrOpDerived, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_OpDerived_MinusEqual, _swig_p) + return +} + +func (_swig_base SwigcptrOpDerived) MinusEqual(arg1 Op) { + _swig_wrap_OpDerived_MinusEqual(_swig_base, arg1.Swigcptr()) +} + +var _wrap_OpDerived_MultiplyEqual unsafe.Pointer + +func _swig_wrap_OpDerived_MultiplyEqual(base SwigcptrOpDerived, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_OpDerived_MultiplyEqual, _swig_p) + return +} + +func (_swig_base SwigcptrOpDerived) MultiplyEqual(arg1 Op) { + _swig_wrap_OpDerived_MultiplyEqual(_swig_base, arg1.Swigcptr()) +} + +var _wrap_OpDerived_DivideEqual unsafe.Pointer + +func _swig_wrap_OpDerived_DivideEqual(base SwigcptrOpDerived, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_OpDerived_DivideEqual, _swig_p) + return +} + +func (_swig_base SwigcptrOpDerived) DivideEqual(arg1 Op) { + _swig_wrap_OpDerived_DivideEqual(_swig_base, arg1.Swigcptr()) +} + +var _wrap_OpDerived_PercentEqual unsafe.Pointer + +func _swig_wrap_OpDerived_PercentEqual(base SwigcptrOpDerived, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_OpDerived_PercentEqual, _swig_p) + return +} + +func (_swig_base SwigcptrOpDerived) PercentEqual(arg1 Op) { + _swig_wrap_OpDerived_PercentEqual(_swig_base, arg1.Swigcptr()) +} + +var _wrap_OpDerived_Minus__SWIG_0 unsafe.Pointer + +func _swig_wrap_OpDerived_Minus__SWIG_0(base SwigcptrOpDerived) (_ SwigcptrOp) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_OpDerived_Minus__SWIG_0, _swig_p) + return +} + +func (_swig_base SwigcptrOpDerived) Minus__SWIG_0() (_swig_ret Op) { + return _swig_wrap_OpDerived_Minus__SWIG_0(_swig_base) +} + +var _wrap_OpDerived_Minus__SWIG_1 unsafe.Pointer + +func _swig_wrap_OpDerived_Minus__SWIG_1(base SwigcptrOpDerived, _ uintptr) (_ SwigcptrOp) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_OpDerived_Minus__SWIG_1, _swig_p) + return +} + +func (_swig_base SwigcptrOpDerived) Minus__SWIG_1(arg1 Op) (_swig_ret Op) { + return _swig_wrap_OpDerived_Minus__SWIG_1(_swig_base, arg1.Swigcptr()) +} + +func (p SwigcptrOpDerived) Minus(a ...interface{}) Op { + argc := len(a) + if argc == 0 { + return p.Minus__SWIG_0() + } + if argc == 1 { + return p.Minus__SWIG_1(a[0].(Op)) + } + panic("No match for overloaded function call") +} + +var _wrap_OpDerived_Not unsafe.Pointer + +func _swig_wrap_OpDerived_Not(base SwigcptrOpDerived) (_ bool) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_OpDerived_Not, _swig_p) + return +} + +func (_swig_base SwigcptrOpDerived) Not() (_swig_ret bool) { + return _swig_wrap_OpDerived_Not(_swig_base) +} + +var _wrap_OpDerived_IndexIntoConst unsafe.Pointer + +func _swig_wrap_OpDerived_IndexIntoConst(base SwigcptrOpDerived, _ uint) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_OpDerived_IndexIntoConst, _swig_p) + return +} + +func (_swig_base SwigcptrOpDerived) IndexIntoConst(arg1 uint) (_swig_ret int) { + return _swig_wrap_OpDerived_IndexIntoConst(_swig_base, arg1) +} + +var _wrap_OpDerived_Functor__SWIG_0 unsafe.Pointer + +func _swig_wrap_OpDerived_Functor__SWIG_0(base SwigcptrOpDerived, _ int) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_OpDerived_Functor__SWIG_0, _swig_p) + return +} + +func (_swig_base SwigcptrOpDerived) Functor__SWIG_0(arg1 int) (_swig_ret int) { + return _swig_wrap_OpDerived_Functor__SWIG_0(_swig_base, arg1) +} + +var _wrap_OpDerived_Functor__SWIG_1 unsafe.Pointer + +func _swig_wrap_OpDerived_Functor__SWIG_1(base SwigcptrOpDerived) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_OpDerived_Functor__SWIG_1, _swig_p) + return +} + +func (_swig_base SwigcptrOpDerived) Functor__SWIG_1() (_swig_ret int) { + return _swig_wrap_OpDerived_Functor__SWIG_1(_swig_base) +} + +var _wrap_OpDerived_Functor__SWIG_2 unsafe.Pointer + +func _swig_wrap_OpDerived_Functor__SWIG_2(base SwigcptrOpDerived, _ int, _ int) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_OpDerived_Functor__SWIG_2, _swig_p) + return +} + +func (_swig_base SwigcptrOpDerived) Functor__SWIG_2(arg1 int, arg2 int) (_swig_ret int) { + return _swig_wrap_OpDerived_Functor__SWIG_2(_swig_base, arg1, arg2) +} + +func (p SwigcptrOpDerived) Functor(a ...interface{}) int { + argc := len(a) + if argc == 0 { + return p.Functor__SWIG_1() + } + if argc == 1 { + return p.Functor__SWIG_0(a[0].(int)) + } + if argc == 2 { + return p.Functor__SWIG_2(a[0].(int), a[1].(int)) + } + panic("No match for overloaded function call") +} + +var _wrap_OpDerived_PlusPlusPrefix unsafe.Pointer + +func _swig_wrap_OpDerived_PlusPlusPrefix(base SwigcptrOpDerived) (_ SwigcptrOp) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_OpDerived_PlusPlusPrefix, _swig_p) + return +} + +func (_swig_base SwigcptrOpDerived) PlusPlusPrefix() (_swig_ret Op) { + return _swig_wrap_OpDerived_PlusPlusPrefix(_swig_base) +} + +var _wrap_OpDerived_MinusMinusPrefix unsafe.Pointer + +func _swig_wrap_OpDerived_MinusMinusPrefix(base SwigcptrOpDerived) (_ SwigcptrOp) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_OpDerived_MinusMinusPrefix, _swig_p) + return +} + +func (_swig_base SwigcptrOpDerived) MinusMinusPrefix() (_swig_ret Op) { + return _swig_wrap_OpDerived_MinusMinusPrefix(_swig_base) +} + +var _wrap_OpDerived_DoubleCast unsafe.Pointer + +func _swig_wrap_OpDerived_DoubleCast(base SwigcptrOpDerived) (_ float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_OpDerived_DoubleCast, _swig_p) + return +} + +func (_swig_base SwigcptrOpDerived) DoubleCast() (_swig_ret float64) { + return _swig_wrap_OpDerived_DoubleCast(_swig_base) +} + +var _wrap_OpDerived_sanity_check unsafe.Pointer + +func _swig_wrap_OpDerived_sanity_check() { + var _swig_p uintptr + _cgo_runtime_cgocall(_wrap_OpDerived_sanity_check, _swig_p) + return +} + +func OpDerivedSanity_check() { + _swig_wrap_OpDerived_sanity_check() +} + +func (p SwigcptrOpDerived) SwigIsOp() { +} + +func (p SwigcptrOpDerived) SwigGetOp() Op { + return SwigcptrOp(p.Swigcptr()) +} + +type OpDerived interface { + Swigcptr() uintptr + SwigIsOpDerived() + IntCast() (_swig_ret int) + SetI(arg1 int) + GetI() (_swig_ret int) + Equal(arg1 Op) (_swig_ret Op) + PlusEqual(arg1 Op) + MinusEqual(arg1 Op) + MultiplyEqual(arg1 Op) + DivideEqual(arg1 Op) + PercentEqual(arg1 Op) + Minus(a ...interface{}) Op + Not() (_swig_ret bool) + IndexIntoConst(arg1 uint) (_swig_ret int) + Functor(a ...interface{}) int + PlusPlusPrefix() (_swig_ret Op) + MinusMinusPrefix() (_swig_ret Op) + DoubleCast() (_swig_ret float64) + SwigIsOp() + SwigGetOp() Op +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/operator_overload_break.go b/Examples/test-suite/go/operator_overload_break.go new file mode 100644 index 000000000..131a858dc --- /dev/null +++ b/Examples/test-suite/go/operator_overload_break.go @@ -0,0 +1,287 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../operator_overload_break.i + +package operator_overload_break + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrOp uintptr + +func (p SwigcptrOp) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrOp) SwigIsOp() { +} + +var _wrap_new_Op__SWIG_0 unsafe.Pointer + +func _swig_wrap_new_Op__SWIG_0(base int) (_ SwigcptrOp) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Op__SWIG_0, _swig_p) + return +} + +func NewOp__SWIG_0(arg1 int) (_swig_ret Op) { + return _swig_wrap_new_Op__SWIG_0(arg1) +} + +var _wrap_new_Op__SWIG_1 unsafe.Pointer + +func _swig_wrap_new_Op__SWIG_1(base uintptr) (_ SwigcptrOp) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Op__SWIG_1, _swig_p) + return +} + +func NewOp__SWIG_1(arg1 Op) (_swig_ret Op) { + return _swig_wrap_new_Op__SWIG_1(arg1.Swigcptr()) +} + +func NewOp(a ...interface{}) Op { + argc := len(a) + if argc == 1 { + if _, ok := a[0].(Op); !ok { + goto check_1 + } + return NewOp__SWIG_1(a[0].(Op)) + } +check_1: + if argc == 1 { + return NewOp__SWIG_0(a[0].(int)) + } + panic("No match for overloaded function call") +} + +var _wrap_Op_EqualEqual__SWIG_0 unsafe.Pointer + +func _swig_wrap_Op_EqualEqual__SWIG_0(base SwigcptrOp, _ uintptr) (_ bool) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Op_EqualEqual__SWIG_0, _swig_p) + return +} + +func (arg1 SwigcptrOp) EqualEqual__SWIG_0(arg2 Op) (_swig_ret bool) { + return _swig_wrap_Op_EqualEqual__SWIG_0(arg1, arg2.Swigcptr()) +} + +var _wrap_Op_EqualEqual__SWIG_1 unsafe.Pointer + +func _swig_wrap_Op_EqualEqual__SWIG_1(base SwigcptrOp, _ int) (_ bool) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Op_EqualEqual__SWIG_1, _swig_p) + return +} + +func (arg1 SwigcptrOp) EqualEqual__SWIG_1(arg2 int) (_swig_ret bool) { + return _swig_wrap_Op_EqualEqual__SWIG_1(arg1, arg2) +} + +func (p SwigcptrOp) EqualEqual(a ...interface{}) bool { + argc := len(a) + if argc == 1 { + if _, ok := a[0].(Op); !ok { + goto check_1 + } + return p.EqualEqual__SWIG_0(a[0].(Op)) + } +check_1: + if argc == 1 { + return p.EqualEqual__SWIG_1(a[0].(int)) + } + panic("No match for overloaded function call") +} + +var _wrap_Op_Plus__SWIG_0 unsafe.Pointer + +func _swig_wrap_Op_Plus__SWIG_0(base SwigcptrOp, _ uintptr) (_ SwigcptrOp) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Op_Plus__SWIG_0, _swig_p) + return +} + +func (arg1 SwigcptrOp) Plus__SWIG_0(arg2 Op) (_swig_ret Op) { + return _swig_wrap_Op_Plus__SWIG_0(arg1, arg2.Swigcptr()) +} + +var _wrap_Op_Plus__SWIG_1 unsafe.Pointer + +func _swig_wrap_Op_Plus__SWIG_1(base SwigcptrOp, _ int) (_ SwigcptrOp) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Op_Plus__SWIG_1, _swig_p) + return +} + +func (arg1 SwigcptrOp) Plus__SWIG_1(arg2 int) (_swig_ret Op) { + return _swig_wrap_Op_Plus__SWIG_1(arg1, arg2) +} + +func (p SwigcptrOp) Plus(a ...interface{}) Op { + argc := len(a) + if argc == 1 { + if _, ok := a[0].(Op); !ok { + goto check_1 + } + return p.Plus__SWIG_0(a[0].(Op)) + } +check_1: + if argc == 1 { + return p.Plus__SWIG_1(a[0].(int)) + } + panic("No match for overloaded function call") +} + +var _wrap_Op_Minus__SWIG_0 unsafe.Pointer + +func _swig_wrap_Op_Minus__SWIG_0(base SwigcptrOp, _ uintptr) (_ SwigcptrOp) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Op_Minus__SWIG_0, _swig_p) + return +} + +func (arg1 SwigcptrOp) Minus__SWIG_0(arg2 Op) (_swig_ret Op) { + return _swig_wrap_Op_Minus__SWIG_0(arg1, arg2.Swigcptr()) +} + +var _wrap_Op_Minus__SWIG_1 unsafe.Pointer + +func _swig_wrap_Op_Minus__SWIG_1(base SwigcptrOp, _ int) (_ SwigcptrOp) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Op_Minus__SWIG_1, _swig_p) + return +} + +func (arg1 SwigcptrOp) Minus__SWIG_1(arg2 int) (_swig_ret Op) { + return _swig_wrap_Op_Minus__SWIG_1(arg1, arg2) +} + +func (p SwigcptrOp) Minus(a ...interface{}) Op { + argc := len(a) + if argc == 1 { + if _, ok := a[0].(Op); !ok { + goto check_1 + } + return p.Minus__SWIG_0(a[0].(Op)) + } +check_1: + if argc == 1 { + return p.Minus__SWIG_1(a[0].(int)) + } + panic("No match for overloaded function call") +} + +var _wrap_Op___rsub__ unsafe.Pointer + +func _swig_wrap_Op___rsub__(base SwigcptrOp, _ int) (_ SwigcptrOp) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Op___rsub__, _swig_p) + return +} + +func (arg1 SwigcptrOp) X__rsub__(arg2 int) (_swig_ret Op) { + return _swig_wrap_Op___rsub__(arg1, arg2) +} + +var _wrap_Op_PlusPlusPrefix unsafe.Pointer + +func _swig_wrap_Op_PlusPlusPrefix(base SwigcptrOp) (_ SwigcptrOp) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Op_PlusPlusPrefix, _swig_p) + return +} + +func (arg1 SwigcptrOp) PlusPlusPrefix() (_swig_ret Op) { + return _swig_wrap_Op_PlusPlusPrefix(arg1) +} + +var _wrap_Op_PrintK unsafe.Pointer + +func _swig_wrap_Op_PrintK(base SwigcptrOp) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Op_PrintK, _swig_p) + return +} + +func (arg1 SwigcptrOp) PrintK() { + _swig_wrap_Op_PrintK(arg1) +} + +var _wrap_Op_k_set unsafe.Pointer + +func _swig_wrap_Op_k_set(base SwigcptrOp, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Op_k_set, _swig_p) + return +} + +func (arg1 SwigcptrOp) SetK(arg2 int) { + _swig_wrap_Op_k_set(arg1, arg2) +} + +var _wrap_Op_k_get unsafe.Pointer + +func _swig_wrap_Op_k_get(base SwigcptrOp) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Op_k_get, _swig_p) + return +} + +func (arg1 SwigcptrOp) GetK() (_swig_ret int) { + return _swig_wrap_Op_k_get(arg1) +} + +var _wrap_delete_Op unsafe.Pointer + +func _swig_wrap_delete_Op(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Op, _swig_p) + return +} + +func DeleteOp(arg1 Op) { + _swig_wrap_delete_Op(arg1.Swigcptr()) +} + +type Op interface { + Swigcptr() uintptr + SwigIsOp() + EqualEqual(a ...interface{}) bool + Plus(a ...interface{}) Op + Minus(a ...interface{}) Op + X__rsub__(arg2 int) (_swig_ret Op) + PlusPlusPrefix() (_swig_ret Op) + PrintK() + SetK(arg2 int) + GetK() (_swig_ret int) +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/operator_pointer_ref.go b/Examples/test-suite/go/operator_pointer_ref.go new file mode 100644 index 000000000..d011bd433 --- /dev/null +++ b/Examples/test-suite/go/operator_pointer_ref.go @@ -0,0 +1,111 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../operator_pointer_ref.i + +package operator_pointer_ref + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrMyClass uintptr + +func (p SwigcptrMyClass) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrMyClass) SwigIsMyClass() { +} + +var _wrap_new_MyClass__SWIG_0 unsafe.Pointer + +func _swig_wrap_new_MyClass__SWIG_0(base string) (_ SwigcptrMyClass) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_MyClass__SWIG_0, _swig_p) + return +} + +func NewMyClass__SWIG_0(arg1 string) (_swig_ret MyClass) { + return _swig_wrap_new_MyClass__SWIG_0(arg1) +} + +var _wrap_new_MyClass__SWIG_1 unsafe.Pointer + +func _swig_wrap_new_MyClass__SWIG_1() (base SwigcptrMyClass) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_MyClass__SWIG_1, _swig_p) + return +} + +func NewMyClass__SWIG_1() (_swig_ret MyClass) { + return _swig_wrap_new_MyClass__SWIG_1() +} + +func NewMyClass(a ...interface{}) MyClass { + argc := len(a) + if argc == 0 { + return NewMyClass__SWIG_1() + } + if argc == 1 { + return NewMyClass__SWIG_0(a[0].(string)) + } + panic("No match for overloaded function call") +} + +var _wrap_delete_MyClass unsafe.Pointer + +func _swig_wrap_delete_MyClass(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_MyClass, _swig_p) + return +} + +func DeleteMyClass(arg1 MyClass) { + _swig_wrap_delete_MyClass(arg1.Swigcptr()) +} + +var _wrap_MyClass_AsCharStarRef unsafe.Pointer + +func _swig_wrap_MyClass_AsCharStarRef(base SwigcptrMyClass) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_MyClass_AsCharStarRef, _swig_p) + return +} + +func (arg1 SwigcptrMyClass) AsCharStarRef() (_swig_ret string) { + return _swig_wrap_MyClass_AsCharStarRef(arg1) +} + +type MyClass interface { + Swigcptr() uintptr + SwigIsMyClass() + AsCharStarRef() (_swig_ret string) +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/operbool.go b/Examples/test-suite/go/operbool.go new file mode 100644 index 000000000..472f02e02 --- /dev/null +++ b/Examples/test-suite/go/operbool.go @@ -0,0 +1,88 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../operbool.i + +package operbool + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrTest uintptr + +func (p SwigcptrTest) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrTest) SwigIsTest() { +} + +var _wrap_Test_operator_bool unsafe.Pointer + +func _swig_wrap_Test_operator_bool(base SwigcptrTest) (_ bool) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Test_operator_bool, _swig_p) + return +} + +func (arg1 SwigcptrTest) Operator_bool() (_swig_ret bool) { + return _swig_wrap_Test_operator_bool(arg1) +} + +var _wrap_new_Test unsafe.Pointer + +func _swig_wrap_new_Test() (base SwigcptrTest) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Test, _swig_p) + return +} + +func NewTest() (_swig_ret Test) { + return _swig_wrap_new_Test() +} + +var _wrap_delete_Test unsafe.Pointer + +func _swig_wrap_delete_Test(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Test, _swig_p) + return +} + +func DeleteTest(arg1 Test) { + _swig_wrap_delete_Test(arg1.Swigcptr()) +} + +type Test interface { + Swigcptr() uintptr + SwigIsTest() + Operator_bool() (_swig_ret bool) +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/ordering.go b/Examples/test-suite/go/ordering.go new file mode 100644 index 000000000..94a821508 --- /dev/null +++ b/Examples/test-suite/go/ordering.go @@ -0,0 +1,101 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../ordering.i + +package ordering + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrKlass uintptr + +func (p SwigcptrKlass) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrKlass) SwigIsKlass() { +} + +var _wrap_Klass_variable_set unsafe.Pointer + +func _swig_wrap_Klass_variable_set(base SwigcptrKlass, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Klass_variable_set, _swig_p) + return +} + +func (arg1 SwigcptrKlass) SetVariable(arg2 int) { + _swig_wrap_Klass_variable_set(arg1, arg2) +} + +var _wrap_Klass_variable_get unsafe.Pointer + +func _swig_wrap_Klass_variable_get(base SwigcptrKlass) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Klass_variable_get, _swig_p) + return +} + +func (arg1 SwigcptrKlass) GetVariable() (_swig_ret int) { + return _swig_wrap_Klass_variable_get(arg1) +} + +var _wrap_new_Klass unsafe.Pointer + +func _swig_wrap_new_Klass() (base SwigcptrKlass) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Klass, _swig_p) + return +} + +func NewKlass() (_swig_ret Klass) { + return _swig_wrap_new_Klass() +} + +var _wrap_delete_Klass unsafe.Pointer + +func _swig_wrap_delete_Klass(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Klass, _swig_p) + return +} + +func DeleteKlass(arg1 Klass) { + _swig_wrap_delete_Klass(arg1.Swigcptr()) +} + +type Klass interface { + Swigcptr() uintptr + SwigIsKlass() + SetVariable(arg2 int) + GetVariable() (_swig_ret int) +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/overload_bool.go b/Examples/test-suite/go/overload_bool.go new file mode 100644 index 000000000..8c11c1ee8 --- /dev/null +++ b/Examples/test-suite/go/overload_bool.go @@ -0,0 +1,143 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../overload_bool.i + +package overload_bool + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +var _wrap_overloaded__SWIG_0 unsafe.Pointer + +func Overloaded__SWIG_0(arg1 bool) (_swig_ret string) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_overloaded__SWIG_0, _swig_p) + return +} +var _wrap_overloaded__SWIG_1 unsafe.Pointer + +func Overloaded__SWIG_1(arg1 int) (_swig_ret string) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_overloaded__SWIG_1, _swig_p) + return +} +var _wrap_overloaded__SWIG_2 unsafe.Pointer + +func Overloaded__SWIG_2(arg1 string) (_swig_ret string) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_overloaded__SWIG_2, _swig_p) + return +} +func Overloaded(a ...interface{}) string { + argc := len(a) + if argc == 1 { + if _, ok := a[0].(bool); !ok { + goto check_1 + } + return Overloaded__SWIG_0(a[0].(bool)) + } +check_1: + if argc == 1 { + if _, ok := a[0].(int); !ok { + goto check_2 + } + return Overloaded__SWIG_1(a[0].(int)) + } +check_2: + if argc == 1 { + return Overloaded__SWIG_2(a[0].(string)) + } + panic("No match for overloaded function call") +} + +var _wrap_boolfunction unsafe.Pointer + +func Boolfunction(arg1 bool) (_swig_ret string) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_boolfunction, _swig_p) + return +} +var _wrap_intfunction unsafe.Pointer + +func Intfunction(arg1 int) (_swig_ret string) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_intfunction, _swig_p) + return +} +var _wrap_overloaded_ref__SWIG_0 unsafe.Pointer + +func Overloaded_ref__SWIG_0(arg1 bool) (_swig_ret string) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_overloaded_ref__SWIG_0, _swig_p) + return +} +var _wrap_overloaded_ref__SWIG_1 unsafe.Pointer + +func Overloaded_ref__SWIG_1(arg1 int) (_swig_ret string) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_overloaded_ref__SWIG_1, _swig_p) + return +} +var _wrap_overloaded_ref__SWIG_2 unsafe.Pointer + +func Overloaded_ref__SWIG_2(arg1 string) (_swig_ret string) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_overloaded_ref__SWIG_2, _swig_p) + return +} +func Overloaded_ref(a ...interface{}) string { + argc := len(a) + if argc == 1 { + if _, ok := a[0].(bool); !ok { + goto check_1 + } + return Overloaded_ref__SWIG_0(a[0].(bool)) + } +check_1: + if argc == 1 { + if _, ok := a[0].(int); !ok { + goto check_2 + } + return Overloaded_ref__SWIG_1(a[0].(int)) + } +check_2: + if argc == 1 { + return Overloaded_ref__SWIG_2(a[0].(string)) + } + panic("No match for overloaded function call") +} + +var _wrap_boolfunction_ref unsafe.Pointer + +func Boolfunction_ref(arg1 bool) (_swig_ret string) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_boolfunction_ref, _swig_p) + return +} +var _wrap_intfunction_ref unsafe.Pointer + +func Intfunction_ref(arg1 int) (_swig_ret string) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_intfunction_ref, _swig_p) + return +} + diff --git a/Examples/test-suite/go/overload_copy.go b/Examples/test-suite/go/overload_copy.go new file mode 100644 index 000000000..a7b239ba4 --- /dev/null +++ b/Examples/test-suite/go/overload_copy.go @@ -0,0 +1,98 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../overload_copy.i + +package overload_copy + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrFoo uintptr + +func (p SwigcptrFoo) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrFoo) SwigIsFoo() { +} + +var _wrap_new_Foo__SWIG_0 unsafe.Pointer + +func _swig_wrap_new_Foo__SWIG_0() (base SwigcptrFoo) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Foo__SWIG_0, _swig_p) + return +} + +func NewFoo__SWIG_0() (_swig_ret Foo) { + return _swig_wrap_new_Foo__SWIG_0() +} + +var _wrap_new_Foo__SWIG_1 unsafe.Pointer + +func _swig_wrap_new_Foo__SWIG_1(base uintptr) (_ SwigcptrFoo) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Foo__SWIG_1, _swig_p) + return +} + +func NewFoo__SWIG_1(arg1 Foo) (_swig_ret Foo) { + return _swig_wrap_new_Foo__SWIG_1(arg1.Swigcptr()) +} + +func NewFoo(a ...interface{}) Foo { + argc := len(a) + if argc == 0 { + return NewFoo__SWIG_0() + } + if argc == 1 { + return NewFoo__SWIG_1(a[0].(Foo)) + } + panic("No match for overloaded function call") +} + +var _wrap_delete_Foo unsafe.Pointer + +func _swig_wrap_delete_Foo(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Foo, _swig_p) + return +} + +func DeleteFoo(arg1 Foo) { + _swig_wrap_delete_Foo(arg1.Swigcptr()) +} + +type Foo interface { + Swigcptr() uintptr + SwigIsFoo() +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/overload_copy_runme b/Examples/test-suite/go/overload_copy_runme new file mode 100755 index 000000000..dedcf988a Binary files /dev/null and b/Examples/test-suite/go/overload_copy_runme differ diff --git a/Examples/test-suite/go/overload_extend.go b/Examples/test-suite/go/overload_extend.go new file mode 100644 index 000000000..fc3ea70c7 --- /dev/null +++ b/Examples/test-suite/go/overload_extend.go @@ -0,0 +1,248 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../overload_extend.i + +package overload_extend + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrFoo uintptr + +func (p SwigcptrFoo) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrFoo) SwigIsFoo() { +} + +var _wrap_Foo_variable_set unsafe.Pointer + +func _swig_wrap_Foo_variable_set(base SwigcptrFoo, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_variable_set, _swig_p) + return +} + +func (arg1 SwigcptrFoo) SetVariable(arg2 int) { + _swig_wrap_Foo_variable_set(arg1, arg2) +} + +var _wrap_Foo_variable_get unsafe.Pointer + +func _swig_wrap_Foo_variable_get(base SwigcptrFoo) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_variable_get, _swig_p) + return +} + +func (arg1 SwigcptrFoo) GetVariable() (_swig_ret int) { + return _swig_wrap_Foo_variable_get(arg1) +} + +var _wrap_Foo_test__SWIG_0 unsafe.Pointer + +func _swig_wrap_Foo_test__SWIG_0(base SwigcptrFoo) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_test__SWIG_0, _swig_p) + return +} + +func (arg1 SwigcptrFoo) Test__SWIG_0() (_swig_ret int) { + return _swig_wrap_Foo_test__SWIG_0(arg1) +} + +var _wrap_Foo_test__SWIG_1 unsafe.Pointer + +func _swig_wrap_Foo_test__SWIG_1(base SwigcptrFoo, _ int) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_test__SWIG_1, _swig_p) + return +} + +func (arg1 SwigcptrFoo) Test__SWIG_1(arg2 int) (_swig_ret int) { + return _swig_wrap_Foo_test__SWIG_1(arg1, arg2) +} + +var _wrap_Foo_test__SWIG_2 unsafe.Pointer + +func _swig_wrap_Foo_test__SWIG_2(base SwigcptrFoo, _ string) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_test__SWIG_2, _swig_p) + return +} + +func (arg1 SwigcptrFoo) Test__SWIG_2(arg2 string) (_swig_ret int) { + return _swig_wrap_Foo_test__SWIG_2(arg1, arg2) +} + +var _wrap_Foo_test__SWIG_3 unsafe.Pointer + +func _swig_wrap_Foo_test__SWIG_3(base int, _ SwigcptrFoo, _ float64, _ float64) (_ float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_test__SWIG_3, _swig_p) + return +} + +func (arg1 SwigcptrFoo) Test__SWIG_3(arg2 float64, _swig_args ...interface{}) (_swig_ret float64) { + var arg3 float64 + if len(_swig_args) > 0 { + arg3 = _swig_args[0].(float64) + } + return _swig_wrap_Foo_test__SWIG_3(len(_swig_args), arg1, arg2, arg3) +} + +func (p SwigcptrFoo) Test(a ...interface{}) interface{} { + argc := len(a) + if argc == 0 { + return p.Test__SWIG_0() + } + if argc == 1 { + if _, ok := a[0].(int); !ok { + goto check_2 + } + return p.Test__SWIG_1(a[0].(int)) + } +check_2: + if argc >= 1 && argc <= 2 { + if _, ok := a[0].(float64); !ok { + goto check_3 + } + switch argc { + case 1: + return p.Test__SWIG_3(a[0].(float64)) + case 2: + return p.Test__SWIG_3(a[0].(float64), a[1]) + } + } +check_3: + if argc == 1 { + return p.Test__SWIG_2(a[0].(string)) + } + panic("No match for overloaded function call") +} + +var _wrap_new_Foo unsafe.Pointer + +func _swig_wrap_new_Foo() (base SwigcptrFoo) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Foo, _swig_p) + return +} + +func NewFoo() (_swig_ret Foo) { + return _swig_wrap_new_Foo() +} + +var _wrap_delete_Foo unsafe.Pointer + +func _swig_wrap_delete_Foo(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Foo, _swig_p) + return +} + +func DeleteFoo(arg1 Foo) { + _swig_wrap_delete_Foo(arg1.Swigcptr()) +} + +type Foo interface { + Swigcptr() uintptr + SwigIsFoo() + SetVariable(arg2 int) + GetVariable() (_swig_ret int) + Test(a ...interface{}) interface{} +} + +type SwigcptrBar uintptr + +func (p SwigcptrBar) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrBar) SwigIsBar() { +} + +var _wrap_new_Bar unsafe.Pointer + +func _swig_wrap_new_Bar() (base SwigcptrBar) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Bar, _swig_p) + return +} + +func NewBar() (_swig_ret Bar) { + return _swig_wrap_new_Bar() +} + +var _wrap_delete_Bar unsafe.Pointer + +func _swig_wrap_delete_Bar(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Bar, _swig_p) + return +} + +func DeleteBar(arg1 Bar) { + _swig_wrap_delete_Bar(arg1.Swigcptr()) +} + +var _wrap_Bar_variable_set unsafe.Pointer + +func _swig_wrap_Bar_variable_set(base SwigcptrBar, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Bar_variable_set, _swig_p) + return +} + +func (arg1 SwigcptrBar) SetVariable(arg2 int) { + _swig_wrap_Bar_variable_set(arg1, arg2) +} + +var _wrap_Bar_variable_get unsafe.Pointer + +func _swig_wrap_Bar_variable_get(base SwigcptrBar) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Bar_variable_get, _swig_p) + return +} + +func (arg1 SwigcptrBar) GetVariable() (_swig_ret int) { + return _swig_wrap_Bar_variable_get(arg1) +} + +type Bar interface { + Swigcptr() uintptr + SwigIsBar() + SetVariable(arg2 int) + GetVariable() (_swig_ret int) +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/overload_extend_runme b/Examples/test-suite/go/overload_extend_runme new file mode 100755 index 000000000..fe478c241 Binary files /dev/null and b/Examples/test-suite/go/overload_extend_runme differ diff --git a/Examples/test-suite/go/overload_extendc.go b/Examples/test-suite/go/overload_extendc.go new file mode 100644 index 000000000..3123c48de --- /dev/null +++ b/Examples/test-suite/go/overload_extendc.go @@ -0,0 +1,226 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../overload_extendc.i + +package overload_extendc + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrFoo uintptr + +func (p SwigcptrFoo) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrFoo) SwigIsFoo() { +} + +var _wrap_Foo_dummy_set unsafe.Pointer + +func _swig_wrap_Foo_dummy_set(base SwigcptrFoo, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_dummy_set, _swig_p) + return +} + +func (arg1 SwigcptrFoo) SetDummy(arg2 int) { + _swig_wrap_Foo_dummy_set(arg1, arg2) +} + +var _wrap_Foo_dummy_get unsafe.Pointer + +func _swig_wrap_Foo_dummy_get(base SwigcptrFoo) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_dummy_get, _swig_p) + return +} + +func (arg1 SwigcptrFoo) GetDummy() (_swig_ret int) { + return _swig_wrap_Foo_dummy_get(arg1) +} + +var _wrap_Foo_test__SWIG_0 unsafe.Pointer + +func _swig_wrap_Foo_test__SWIG_0(base SwigcptrFoo, _ int) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_test__SWIG_0, _swig_p) + return +} + +func (arg1 SwigcptrFoo) Test__SWIG_0(arg2 int) (_swig_ret int) { + return _swig_wrap_Foo_test__SWIG_0(arg1, arg2) +} + +var _wrap_Foo_test__SWIG_1 unsafe.Pointer + +func _swig_wrap_Foo_test__SWIG_1(base SwigcptrFoo, _ string) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_test__SWIG_1, _swig_p) + return +} + +func (arg1 SwigcptrFoo) Test__SWIG_1(arg2 string) (_swig_ret int) { + return _swig_wrap_Foo_test__SWIG_1(arg1, arg2) +} + +var _wrap_Foo_test__SWIG_2 unsafe.Pointer + +func _swig_wrap_Foo_test__SWIG_2(base SwigcptrFoo, _ float64, _ float64) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_test__SWIG_2, _swig_p) + return +} + +func (arg1 SwigcptrFoo) Test__SWIG_2(arg2 float64, arg3 float64) (_swig_ret int) { + return _swig_wrap_Foo_test__SWIG_2(arg1, arg2, arg3) +} + +var _wrap_Foo_test__SWIG_3 unsafe.Pointer + +func _swig_wrap_Foo_test__SWIG_3(base int, _ SwigcptrFoo, _ string, _ int, _ int) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_test__SWIG_3, _swig_p) + return +} + +func (arg1 SwigcptrFoo) Test__SWIG_3(arg2 string, arg3 int, _swig_args ...interface{}) (_swig_ret int) { + var arg4 int + if len(_swig_args) > 0 { + arg4 = _swig_args[0].(int) + } + return _swig_wrap_Foo_test__SWIG_3(len(_swig_args), arg1, arg2, arg3, arg4) +} + +var _wrap_Foo_test__SWIG_4 unsafe.Pointer + +func _swig_wrap_Foo_test__SWIG_4(base int, _ SwigcptrFoo, _ uintptr, _ int, _ int) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_test__SWIG_4, _swig_p) + return +} + +func (arg1 SwigcptrFoo) Test__SWIG_4(arg2 Foo, _swig_args ...interface{}) (_swig_ret int) { + var arg3 int + if len(_swig_args) > 0 { + arg3 = _swig_args[0].(int) + } + var arg4 int + if len(_swig_args) > 1 { + arg4 = _swig_args[1].(int) + } + return _swig_wrap_Foo_test__SWIG_4(len(_swig_args), arg1, arg2.Swigcptr(), arg3, arg4) +} + +func (p SwigcptrFoo) Test(a ...interface{}) int { + argc := len(a) + if argc >= 1 && argc <= 3 { + if _, ok := a[0].(Foo); !ok { + goto check_1 + } + if argc > 1 { + if _, ok := a[1].(int); !ok { + goto check_1 + } + } + switch argc { + case 1: + return p.Test__SWIG_4(a[0].(Foo)) + case 2: + return p.Test__SWIG_4(a[0].(Foo), a[1]) + case 3: + return p.Test__SWIG_4(a[0].(Foo), a[1], a[2]) + } + } +check_1: + if argc == 1 { + if _, ok := a[0].(int); !ok { + goto check_2 + } + return p.Test__SWIG_0(a[0].(int)) + } +check_2: + if argc == 1 { + return p.Test__SWIG_1(a[0].(string)) + } + if argc == 2 { + if _, ok := a[0].(float64); !ok { + goto check_4 + } + if _, ok := a[1].(float64); !ok { + goto check_4 + } + return p.Test__SWIG_2(a[0].(float64), a[1].(float64)) + } +check_4: + if argc >= 2 && argc <= 3 { + switch argc { + case 2: + return p.Test__SWIG_3(a[0].(string), a[1].(int)) + case 3: + return p.Test__SWIG_3(a[0].(string), a[1].(int), a[2]) + } + } + panic("No match for overloaded function call") +} + +var _wrap_new_Foo unsafe.Pointer + +func _swig_wrap_new_Foo() (base SwigcptrFoo) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Foo, _swig_p) + return +} + +func NewFoo() (_swig_ret Foo) { + return _swig_wrap_new_Foo() +} + +var _wrap_delete_Foo unsafe.Pointer + +func _swig_wrap_delete_Foo(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Foo, _swig_p) + return +} + +func DeleteFoo(arg1 Foo) { + _swig_wrap_delete_Foo(arg1.Swigcptr()) +} + +type Foo interface { + Swigcptr() uintptr + SwigIsFoo() + SetDummy(arg2 int) + GetDummy() (_swig_ret int) + Test(a ...interface{}) int +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/overload_extendc_runme b/Examples/test-suite/go/overload_extendc_runme new file mode 100755 index 000000000..7c1d7bcab Binary files /dev/null and b/Examples/test-suite/go/overload_extendc_runme differ diff --git a/Examples/test-suite/go/overload_method.go b/Examples/test-suite/go/overload_method.go new file mode 100644 index 000000000..9ed580a0b --- /dev/null +++ b/Examples/test-suite/go/overload_method.go @@ -0,0 +1,125 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../overload_method.i + +package overload_method + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrBase uintptr + +func (p SwigcptrBase) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrBase) SwigIsBase() { +} + +var _wrap_new_Base unsafe.Pointer + +func _swig_wrap_new_Base() (base SwigcptrBase) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Base, _swig_p) + return +} + +func NewBase() (_swig_ret Base) { + return _swig_wrap_new_Base() +} + +var _wrap_Base_method unsafe.Pointer + +func _swig_wrap_Base_method(base SwigcptrBase) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Base_method, _swig_p) + return +} + +func (arg1 SwigcptrBase) Method() (_swig_ret int) { + return _swig_wrap_Base_method(arg1) +} + +var _wrap_Base_overloaded_method__SWIG_0 unsafe.Pointer + +func _swig_wrap_Base_overloaded_method__SWIG_0(base SwigcptrBase, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Base_overloaded_method__SWIG_0, _swig_p) + return +} + +func (arg1 SwigcptrBase) Overloaded_method__SWIG_0(arg2 int) { + _swig_wrap_Base_overloaded_method__SWIG_0(arg1, arg2) +} + +var _wrap_Base_overloaded_method__SWIG_1 unsafe.Pointer + +func _swig_wrap_Base_overloaded_method__SWIG_1(base SwigcptrBase) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Base_overloaded_method__SWIG_1, _swig_p) + return +} + +func (arg1 SwigcptrBase) Overloaded_method__SWIG_1() (_swig_ret int) { + return _swig_wrap_Base_overloaded_method__SWIG_1(arg1) +} + +func (p SwigcptrBase) Overloaded_method(a ...interface{}) interface{} { + argc := len(a) + if argc == 0 { + return p.Overloaded_method__SWIG_1() + } + if argc == 1 { + p.Overloaded_method__SWIG_0(a[0].(int)) + return 0 + } + panic("No match for overloaded function call") +} + +var _wrap_delete_Base unsafe.Pointer + +func _swig_wrap_delete_Base(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Base, _swig_p) + return +} + +func DeleteBase(arg1 Base) { + _swig_wrap_delete_Base(arg1.Swigcptr()) +} + +type Base interface { + Swigcptr() uintptr + SwigIsBase() + Method() (_swig_ret int) + Overloaded_method(a ...interface{}) interface{} +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/overload_numeric.go b/Examples/test-suite/go/overload_numeric.go new file mode 100644 index 000000000..1e416bb6f --- /dev/null +++ b/Examples/test-suite/go/overload_numeric.go @@ -0,0 +1,340 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../overload_numeric.i + +package overload_numeric + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrLimits uintptr + +func (p SwigcptrLimits) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrLimits) SwigIsLimits() { +} + +var _wrap_Limits_schar_min unsafe.Pointer + +func _swig_wrap_Limits_schar_min(base SwigcptrLimits) (_ int8) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Limits_schar_min, _swig_p) + return +} + +func (arg1 SwigcptrLimits) Schar_min() (_swig_ret int8) { + return _swig_wrap_Limits_schar_min(arg1) +} + +var _wrap_Limits_schar_max unsafe.Pointer + +func _swig_wrap_Limits_schar_max(base SwigcptrLimits) (_ int8) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Limits_schar_max, _swig_p) + return +} + +func (arg1 SwigcptrLimits) Schar_max() (_swig_ret int8) { + return _swig_wrap_Limits_schar_max(arg1) +} + +var _wrap_Limits_shrt_min unsafe.Pointer + +func _swig_wrap_Limits_shrt_min(base SwigcptrLimits) (_ int16) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Limits_shrt_min, _swig_p) + return +} + +func (arg1 SwigcptrLimits) Shrt_min() (_swig_ret int16) { + return _swig_wrap_Limits_shrt_min(arg1) +} + +var _wrap_Limits_shrt_max unsafe.Pointer + +func _swig_wrap_Limits_shrt_max(base SwigcptrLimits) (_ int16) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Limits_shrt_max, _swig_p) + return +} + +func (arg1 SwigcptrLimits) Shrt_max() (_swig_ret int16) { + return _swig_wrap_Limits_shrt_max(arg1) +} + +var _wrap_Limits_int_min unsafe.Pointer + +func _swig_wrap_Limits_int_min(base SwigcptrLimits) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Limits_int_min, _swig_p) + return +} + +func (arg1 SwigcptrLimits) Int_min() (_swig_ret int) { + return _swig_wrap_Limits_int_min(arg1) +} + +var _wrap_Limits_int_max unsafe.Pointer + +func _swig_wrap_Limits_int_max(base SwigcptrLimits) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Limits_int_max, _swig_p) + return +} + +func (arg1 SwigcptrLimits) Int_max() (_swig_ret int) { + return _swig_wrap_Limits_int_max(arg1) +} + +var _wrap_Limits_flt_min unsafe.Pointer + +func _swig_wrap_Limits_flt_min(base SwigcptrLimits) (_ float32) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Limits_flt_min, _swig_p) + return +} + +func (arg1 SwigcptrLimits) Flt_min() (_swig_ret float32) { + return _swig_wrap_Limits_flt_min(arg1) +} + +var _wrap_Limits_flt_max unsafe.Pointer + +func _swig_wrap_Limits_flt_max(base SwigcptrLimits) (_ float32) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Limits_flt_max, _swig_p) + return +} + +func (arg1 SwigcptrLimits) Flt_max() (_swig_ret float32) { + return _swig_wrap_Limits_flt_max(arg1) +} + +var _wrap_Limits_dbl_max unsafe.Pointer + +func _swig_wrap_Limits_dbl_max(base SwigcptrLimits) (_ float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Limits_dbl_max, _swig_p) + return +} + +func (arg1 SwigcptrLimits) Dbl_max() (_swig_ret float64) { + return _swig_wrap_Limits_dbl_max(arg1) +} + +var _wrap_new_Limits unsafe.Pointer + +func _swig_wrap_new_Limits() (base SwigcptrLimits) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Limits, _swig_p) + return +} + +func NewLimits() (_swig_ret Limits) { + return _swig_wrap_new_Limits() +} + +var _wrap_delete_Limits unsafe.Pointer + +func _swig_wrap_delete_Limits(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Limits, _swig_p) + return +} + +func DeleteLimits(arg1 Limits) { + _swig_wrap_delete_Limits(arg1.Swigcptr()) +} + +type Limits interface { + Swigcptr() uintptr + SwigIsLimits() + Schar_min() (_swig_ret int8) + Schar_max() (_swig_ret int8) + Shrt_min() (_swig_ret int16) + Shrt_max() (_swig_ret int16) + Int_min() (_swig_ret int) + Int_max() (_swig_ret int) + Flt_min() (_swig_ret float32) + Flt_max() (_swig_ret float32) + Dbl_max() (_swig_ret float64) +} + +type SwigcptrNums uintptr + +func (p SwigcptrNums) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrNums) SwigIsNums() { +} + +var _wrap_Nums_over__SWIG_0 unsafe.Pointer + +func _swig_wrap_Nums_over__SWIG_0(base SwigcptrNums, _ int8) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Nums_over__SWIG_0, _swig_p) + return +} + +func (arg1 SwigcptrNums) Over__SWIG_0(arg2 int8) (_swig_ret string) { + return _swig_wrap_Nums_over__SWIG_0(arg1, arg2) +} + +var _wrap_Nums_over__SWIG_1 unsafe.Pointer + +func _swig_wrap_Nums_over__SWIG_1(base SwigcptrNums, _ int16) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Nums_over__SWIG_1, _swig_p) + return +} + +func (arg1 SwigcptrNums) Over__SWIG_1(arg2 int16) (_swig_ret string) { + return _swig_wrap_Nums_over__SWIG_1(arg1, arg2) +} + +var _wrap_Nums_over__SWIG_2 unsafe.Pointer + +func _swig_wrap_Nums_over__SWIG_2(base SwigcptrNums, _ int) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Nums_over__SWIG_2, _swig_p) + return +} + +func (arg1 SwigcptrNums) Over__SWIG_2(arg2 int) (_swig_ret string) { + return _swig_wrap_Nums_over__SWIG_2(arg1, arg2) +} + +var _wrap_Nums_over__SWIG_3 unsafe.Pointer + +func _swig_wrap_Nums_over__SWIG_3(base SwigcptrNums, _ float32) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Nums_over__SWIG_3, _swig_p) + return +} + +func (arg1 SwigcptrNums) Over__SWIG_3(arg2 float32) (_swig_ret string) { + return _swig_wrap_Nums_over__SWIG_3(arg1, arg2) +} + +var _wrap_Nums_over__SWIG_4 unsafe.Pointer + +func _swig_wrap_Nums_over__SWIG_4(base SwigcptrNums, _ float64) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Nums_over__SWIG_4, _swig_p) + return +} + +func (arg1 SwigcptrNums) Over__SWIG_4(arg2 float64) (_swig_ret string) { + return _swig_wrap_Nums_over__SWIG_4(arg1, arg2) +} + +func (p SwigcptrNums) Over(a ...interface{}) string { + argc := len(a) + if argc == 1 { + if _, ok := a[0].(int8); !ok { + goto check_1 + } + return p.Over__SWIG_0(a[0].(int8)) + } +check_1: + if argc == 1 { + if _, ok := a[0].(int16); !ok { + goto check_2 + } + return p.Over__SWIG_1(a[0].(int16)) + } +check_2: + if argc == 1 { + if _, ok := a[0].(int); !ok { + goto check_3 + } + return p.Over__SWIG_2(a[0].(int)) + } +check_3: + if argc == 1 { + if _, ok := a[0].(float32); !ok { + goto check_4 + } + return p.Over__SWIG_3(a[0].(float32)) + } +check_4: + if argc == 1 { + return p.Over__SWIG_4(a[0].(float64)) + } + panic("No match for overloaded function call") +} + +var _wrap_Nums_doublebounce unsafe.Pointer + +func _swig_wrap_Nums_doublebounce(base SwigcptrNums, _ float64) (_ float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Nums_doublebounce, _swig_p) + return +} + +func (arg1 SwigcptrNums) Doublebounce(arg2 float64) (_swig_ret float64) { + return _swig_wrap_Nums_doublebounce(arg1, arg2) +} + +var _wrap_new_Nums unsafe.Pointer + +func _swig_wrap_new_Nums() (base SwigcptrNums) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Nums, _swig_p) + return +} + +func NewNums() (_swig_ret Nums) { + return _swig_wrap_new_Nums() +} + +var _wrap_delete_Nums unsafe.Pointer + +func _swig_wrap_delete_Nums(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Nums, _swig_p) + return +} + +func DeleteNums(arg1 Nums) { + _swig_wrap_delete_Nums(arg1.Swigcptr()) +} + +type Nums interface { + Swigcptr() uintptr + SwigIsNums() + Over(a ...interface{}) string + Doublebounce(arg2 float64) (_swig_ret float64) +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/overload_polymorphic.go b/Examples/test-suite/go/overload_polymorphic.go new file mode 100644 index 000000000..38d83bbe3 --- /dev/null +++ b/Examples/test-suite/go/overload_polymorphic.go @@ -0,0 +1,156 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../overload_polymorphic.i + +package overload_polymorphic + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrBase uintptr + +func (p SwigcptrBase) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrBase) SwigIsBase() { +} + +var _wrap_new_Base unsafe.Pointer + +func _swig_wrap_new_Base() (base SwigcptrBase) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Base, _swig_p) + return +} + +func NewBase() (_swig_ret Base) { + return _swig_wrap_new_Base() +} + +var _wrap_delete_Base unsafe.Pointer + +func _swig_wrap_delete_Base(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Base, _swig_p) + return +} + +func DeleteBase(arg1 Base) { + _swig_wrap_delete_Base(arg1.Swigcptr()) +} + +type Base interface { + Swigcptr() uintptr + SwigIsBase() +} + +type SwigcptrDerived uintptr + +func (p SwigcptrDerived) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrDerived) SwigIsDerived() { +} + +var _wrap_new_Derived unsafe.Pointer + +func _swig_wrap_new_Derived() (base SwigcptrDerived) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Derived, _swig_p) + return +} + +func NewDerived() (_swig_ret Derived) { + return _swig_wrap_new_Derived() +} + +var _wrap_delete_Derived unsafe.Pointer + +func _swig_wrap_delete_Derived(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Derived, _swig_p) + return +} + +func DeleteDerived(arg1 Derived) { + _swig_wrap_delete_Derived(arg1.Swigcptr()) +} + +func (p SwigcptrDerived) SwigIsBase() { +} + +func (p SwigcptrDerived) SwigGetBase() Base { + return SwigcptrBase(p.Swigcptr()) +} + +type Derived interface { + Swigcptr() uintptr + SwigIsDerived() + SwigIsBase() + SwigGetBase() Base +} + +var _wrap_test__SWIG_0 unsafe.Pointer + +func _swig_wrap_test__SWIG_0(base uintptr) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_test__SWIG_0, _swig_p) + return +} + +func Test__SWIG_0(arg1 Base) (_swig_ret int) { + return _swig_wrap_test__SWIG_0(arg1.Swigcptr()) +} + +var _wrap_test__SWIG_1 unsafe.Pointer + +func Test__SWIG_1(arg1 int) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_test__SWIG_1, _swig_p) + return +} +func Test(a ...interface{}) int { + argc := len(a) + if argc == 1 { + if _, ok := a[0].(Base); !ok { + goto check_1 + } + return Test__SWIG_0(a[0].(Base)) + } +check_1: + if argc == 1 { + return Test__SWIG_1(a[0].(int)) + } + panic("No match for overloaded function call") +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/overload_polymorphic_runme b/Examples/test-suite/go/overload_polymorphic_runme new file mode 100755 index 000000000..f1249bc18 Binary files /dev/null and b/Examples/test-suite/go/overload_polymorphic_runme differ diff --git a/Examples/test-suite/go/overload_polymorphic_runme.go b/Examples/test-suite/go/overload_polymorphic_runme.go new file mode 100644 index 000000000..1720e1a4d --- /dev/null +++ b/Examples/test-suite/go/overload_polymorphic_runme.go @@ -0,0 +1,11 @@ +package main + +import "./overload_polymorphic" + +func main(){ + t := overload_polymorphic.NewDerived() + + if overload_polymorphic.Test(t) != 0 { + panic("failed") + } +} diff --git a/Examples/test-suite/go/overload_polymorphic_runme.go~ b/Examples/test-suite/go/overload_polymorphic_runme.go~ new file mode 100644 index 000000000..ae5aa036d --- /dev/null +++ b/Examples/test-suite/go/overload_polymorphic_runme.go~ @@ -0,0 +1,11 @@ +package main + +import "./overload_polymorphic" + +func main(){ + t := overload_polymorphic.NewDerived() + + if overload_polymorphic.Test(t) != 1 { + panic("failed") + } +} diff --git a/Examples/test-suite/go/overload_rename.go b/Examples/test-suite/go/overload_rename.go new file mode 100644 index 000000000..dfcb639b0 --- /dev/null +++ b/Examples/test-suite/go/overload_rename.go @@ -0,0 +1,133 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../overload_rename.i + +package overload_rename + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrFoo uintptr + +func (p SwigcptrFoo) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrFoo) SwigIsFoo() { +} + +var _wrap_new_Foo__SWIG_0 unsafe.Pointer + +func _swig_wrap_new_Foo__SWIG_0(base float32, _ float32) (_ SwigcptrFoo) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Foo__SWIG_0, _swig_p) + return +} + +func NewFoo__SWIG_0(arg1 float32, arg2 float32) (_swig_ret Foo) { + return _swig_wrap_new_Foo__SWIG_0(arg1, arg2) +} + +var _wrap_new_Foo__SWIG_1 unsafe.Pointer + +func _swig_wrap_new_Foo__SWIG_1(base float32) (_ SwigcptrFoo) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Foo__SWIG_1, _swig_p) + return +} + +func NewFoo__SWIG_1(arg1 float32) (_swig_ret Foo) { + return _swig_wrap_new_Foo__SWIG_1(arg1) +} + +func NewFoo(a ...interface{}) Foo { + argc := len(a) + if argc == 1 { + return NewFoo__SWIG_1(a[0].(float32)) + } + if argc == 2 { + return NewFoo__SWIG_0(a[0].(float32), a[1].(float32)) + } + panic("No match for overloaded function call") +} + +var _wrap_new_Foo_int__SWIG_0 unsafe.Pointer + +func _swig_wrap_new_Foo_int__SWIG_0(base float32, _ int, _ float32) (_ SwigcptrFoo) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Foo_int__SWIG_0, _swig_p) + return +} + +func NewFoo_int__SWIG_0(arg1 float32, arg2 int, arg3 float32) (_swig_ret Foo) { + return _swig_wrap_new_Foo_int__SWIG_0(arg1, arg2, arg3) +} + +var _wrap_new_Foo_int__SWIG_1 unsafe.Pointer + +func _swig_wrap_new_Foo_int__SWIG_1(base float32, _ int) (_ SwigcptrFoo) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Foo_int__SWIG_1, _swig_p) + return +} + +func NewFoo_int__SWIG_1(arg1 float32, arg2 int) (_swig_ret Foo) { + return _swig_wrap_new_Foo_int__SWIG_1(arg1, arg2) +} + +func NewFoo_int(a ...interface{}) Foo { + argc := len(a) + if argc == 2 { + return NewFoo_int__SWIG_1(a[0].(float32), a[1].(int)) + } + if argc == 3 { + return NewFoo_int__SWIG_0(a[0].(float32), a[1].(int), a[2].(float32)) + } + panic("No match for overloaded function call") +} + +var _wrap_delete_Foo unsafe.Pointer + +func _swig_wrap_delete_Foo(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Foo, _swig_p) + return +} + +func DeleteFoo(arg1 Foo) { + _swig_wrap_delete_Foo(arg1.Swigcptr()) +} + +type Foo interface { + Swigcptr() uintptr + SwigIsFoo() +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/overload_rename_runme b/Examples/test-suite/go/overload_rename_runme new file mode 100755 index 000000000..987910277 Binary files /dev/null and b/Examples/test-suite/go/overload_rename_runme differ diff --git a/Examples/test-suite/go/overload_return_type.go b/Examples/test-suite/go/overload_return_type.go new file mode 100644 index 000000000..8291131b2 --- /dev/null +++ b/Examples/test-suite/go/overload_return_type.go @@ -0,0 +1,215 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../overload_return_type.i + +package overload_return_type + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrA uintptr + +func (p SwigcptrA) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrA) SwigIsA() { +} + +var _wrap_new_A unsafe.Pointer + +func _swig_wrap_new_A() (base SwigcptrA) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_A, _swig_p) + return +} + +func NewA() (_swig_ret A) { + return _swig_wrap_new_A() +} + +var _wrap_delete_A unsafe.Pointer + +func _swig_wrap_delete_A(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_A, _swig_p) + return +} + +func DeleteA(arg1 A) { + _swig_wrap_delete_A(arg1.Swigcptr()) +} + +type A interface { + Swigcptr() uintptr + SwigIsA() +} + +type SwigcptrB uintptr + +func (p SwigcptrB) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrB) SwigIsB() { +} + +var _wrap_B_foo__SWIG_0 unsafe.Pointer + +func _swig_wrap_B_foo__SWIG_0(base SwigcptrB, _ int) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_B_foo__SWIG_0, _swig_p) + return +} + +func (arg1 SwigcptrB) Foo__SWIG_0(arg2 int) (_swig_ret int) { + return _swig_wrap_B_foo__SWIG_0(arg1, arg2) +} + +var _wrap_B_foo__SWIG_1 unsafe.Pointer + +func _swig_wrap_B_foo__SWIG_1(base SwigcptrB, _ string) (_ SwigcptrA) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_B_foo__SWIG_1, _swig_p) + return +} + +func (arg1 SwigcptrB) Foo__SWIG_1(arg2 string) (_swig_ret A) { + return _swig_wrap_B_foo__SWIG_1(arg1, arg2) +} + +func (p SwigcptrB) Foo(a ...interface{}) interface{} { + argc := len(a) + if argc == 1 { + if _, ok := a[0].(int); !ok { + goto check_1 + } + return p.Foo__SWIG_0(a[0].(int)) + } +check_1: + if argc == 1 { + return p.Foo__SWIG_1(a[0].(string)) + } + panic("No match for overloaded function call") +} + +var _wrap_new_B unsafe.Pointer + +func _swig_wrap_new_B() (base SwigcptrB) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_B, _swig_p) + return +} + +func NewB() (_swig_ret B) { + return _swig_wrap_new_B() +} + +var _wrap_delete_B unsafe.Pointer + +func _swig_wrap_delete_B(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_B, _swig_p) + return +} + +func DeleteB(arg1 B) { + _swig_wrap_delete_B(arg1.Swigcptr()) +} + +type B interface { + Swigcptr() uintptr + SwigIsB() + Foo(a ...interface{}) interface{} +} + +var _wrap_foo__SWIG_0 unsafe.Pointer + +func _swig_wrap_foo__SWIG_0(base int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_foo__SWIG_0, _swig_p) + return +} + +func Foo__SWIG_0(arg1 int) { + _swig_wrap_foo__SWIG_0(arg1) +} + +var _wrap_foo__SWIG_1 unsafe.Pointer + +func Foo__SWIG_1() (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_foo__SWIG_1, _swig_p) + return +} +func Foo(a ...interface{}) interface{} { + argc := len(a) + if argc == 0 { + return Foo__SWIG_1() + } + if argc == 1 { + Foo__SWIG_0(a[0].(int)) + return 0 + } + panic("No match for overloaded function call") +} + +var _wrap_bar__SWIG_0 unsafe.Pointer + +func Bar__SWIG_0() (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_bar__SWIG_0, _swig_p) + return +} +var _wrap_bar__SWIG_1 unsafe.Pointer + +func _swig_wrap_bar__SWIG_1(base int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_bar__SWIG_1, _swig_p) + return +} + +func Bar__SWIG_1(arg1 int) { + _swig_wrap_bar__SWIG_1(arg1) +} + +func Bar(a ...interface{}) interface{} { + argc := len(a) + if argc == 0 { + return Bar__SWIG_0() + } + if argc == 1 { + Bar__SWIG_1(a[0].(int)) + return 0 + } + panic("No match for overloaded function call") +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/overload_simple.go b/Examples/test-suite/go/overload_simple.go new file mode 100644 index 000000000..a09d30154 --- /dev/null +++ b/Examples/test-suite/go/overload_simple.go @@ -0,0 +1,1060 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../overload_simple.i + +package overload_simple + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrFoos uintptr + +func (p SwigcptrFoos) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrFoos) SwigIsFoos() { +} + +var _wrap_new_Foos unsafe.Pointer + +func _swig_wrap_new_Foos() (base SwigcptrFoos) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Foos, _swig_p) + return +} + +func NewFoos() (_swig_ret Foos) { + return _swig_wrap_new_Foos() +} + +var _wrap_delete_Foos unsafe.Pointer + +func _swig_wrap_delete_Foos(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Foos, _swig_p) + return +} + +func DeleteFoos(arg1 Foos) { + _swig_wrap_delete_Foos(arg1.Swigcptr()) +} + +type Foos interface { + Swigcptr() uintptr + SwigIsFoos() +} + +type SwigcptrBar uintptr + +func (p SwigcptrBar) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrBar) SwigIsBar() { +} + +var _wrap_new_Bar__SWIG_0 unsafe.Pointer + +func _swig_wrap_new_Bar__SWIG_0(base int) (_ SwigcptrBar) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Bar__SWIG_0, _swig_p) + return +} + +func NewBar__SWIG_0(arg1 int) (_swig_ret Bar) { + return _swig_wrap_new_Bar__SWIG_0(arg1) +} + +var _wrap_new_Bar__SWIG_1 unsafe.Pointer + +func _swig_wrap_new_Bar__SWIG_1() (base SwigcptrBar) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Bar__SWIG_1, _swig_p) + return +} + +func NewBar__SWIG_1() (_swig_ret Bar) { + return _swig_wrap_new_Bar__SWIG_1() +} + +func NewBar(a ...interface{}) Bar { + argc := len(a) + if argc == 0 { + return NewBar__SWIG_1() + } + if argc == 1 { + return NewBar__SWIG_0(a[0].(int)) + } + panic("No match for overloaded function call") +} + +var _wrap_Bar_foo__SWIG_0 unsafe.Pointer + +func BarFoo__SWIG_0(arg1 int, arg2 int) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_Bar_foo__SWIG_0, _swig_p) + return +} +var _wrap_Bar_foo__SWIG_1 unsafe.Pointer + +func BarFoo__SWIG_1(arg1 int) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_Bar_foo__SWIG_1, _swig_p) + return +} +var _wrap_Bar_foo__SWIG_2 unsafe.Pointer + +func BarFoo__SWIG_2() (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_Bar_foo__SWIG_2, _swig_p) + return +} +func BarFoo(a ...interface{}) int { + argc := len(a) + if argc == 0 { + return BarFoo__SWIG_2() + } + if argc == 1 { + return BarFoo__SWIG_1(a[0].(int)) + } + if argc == 2 { + return BarFoo__SWIG_0(a[0].(int), a[1].(int)) + } + panic("No match for overloaded function call") +} + +var _wrap_Bar_num_set unsafe.Pointer + +func _swig_wrap_Bar_num_set(base SwigcptrBar, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Bar_num_set, _swig_p) + return +} + +func (arg1 SwigcptrBar) SetNum(arg2 int) { + _swig_wrap_Bar_num_set(arg1, arg2) +} + +var _wrap_Bar_num_get unsafe.Pointer + +func _swig_wrap_Bar_num_get(base SwigcptrBar) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Bar_num_get, _swig_p) + return +} + +func (arg1 SwigcptrBar) GetNum() (_swig_ret int) { + return _swig_wrap_Bar_num_get(arg1) +} + +var _wrap_delete_Bar unsafe.Pointer + +func _swig_wrap_delete_Bar(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Bar, _swig_p) + return +} + +func DeleteBar(arg1 Bar) { + _swig_wrap_delete_Bar(arg1.Swigcptr()) +} + +type Bar interface { + Swigcptr() uintptr + SwigIsBar() + SetNum(arg2 int) + GetNum() (_swig_ret int) +} + +var _wrap_foo__SWIG_0 unsafe.Pointer + +func Foo__SWIG_0() (_swig_ret string) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_foo__SWIG_0, _swig_p) + return +} +var _wrap_foo__SWIG_1 unsafe.Pointer + +func Foo__SWIG_1(arg1 int) (_swig_ret string) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_foo__SWIG_1, _swig_p) + return +} +var _wrap_foo__SWIG_2 unsafe.Pointer + +func Foo__SWIG_2(arg1 float64) (_swig_ret string) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_foo__SWIG_2, _swig_p) + return +} +var _wrap_foo__SWIG_3 unsafe.Pointer + +func Foo__SWIG_3(arg1 string) (_swig_ret string) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_foo__SWIG_3, _swig_p) + return +} +var _wrap_foo__SWIG_4 unsafe.Pointer + +func _swig_wrap_foo__SWIG_4(base uintptr) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_foo__SWIG_4, _swig_p) + return +} + +func Foo__SWIG_4(arg1 Foos) (_swig_ret string) { + return _swig_wrap_foo__SWIG_4(arg1.Swigcptr()) +} + +var _wrap_foo__SWIG_5 unsafe.Pointer + +func _swig_wrap_foo__SWIG_5(base uintptr) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_foo__SWIG_5, _swig_p) + return +} + +func Foo__SWIG_5(arg1 Bar) (_swig_ret string) { + return _swig_wrap_foo__SWIG_5(arg1.Swigcptr()) +} + +var _wrap_foo__SWIG_6 unsafe.Pointer + +func Foo__SWIG_6(arg1 uintptr) (_swig_ret string) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_foo__SWIG_6, _swig_p) + return +} +var _wrap_foo__SWIG_7 unsafe.Pointer + +func _swig_wrap_foo__SWIG_7(base uintptr, _ int) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_foo__SWIG_7, _swig_p) + return +} + +func Foo__SWIG_7(arg1 Foos, arg2 int) (_swig_ret string) { + return _swig_wrap_foo__SWIG_7(arg1.Swigcptr(), arg2) +} + +var _wrap_foo__SWIG_8 unsafe.Pointer + +func _swig_wrap_foo__SWIG_8(base float64, _ uintptr) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_foo__SWIG_8, _swig_p) + return +} + +func Foo__SWIG_8(arg1 float64, arg2 Bar) (_swig_ret string) { + return _swig_wrap_foo__SWIG_8(arg1, arg2.Swigcptr()) +} + +func Foo(a ...interface{}) string { + argc := len(a) + if argc == 0 { + return Foo__SWIG_0() + } + if argc == 1 { + if _, ok := a[0].(Foos); !ok { + goto check_2 + } + return Foo__SWIG_4(a[0].(Foos)) + } +check_2: + if argc == 1 { + if _, ok := a[0].(Bar); !ok { + goto check_3 + } + return Foo__SWIG_5(a[0].(Bar)) + } +check_3: + if argc == 1 { + if _, ok := a[0].(uintptr); !ok { + goto check_4 + } + return Foo__SWIG_6(a[0].(uintptr)) + } +check_4: + if argc == 1 { + if _, ok := a[0].(int); !ok { + goto check_5 + } + return Foo__SWIG_1(a[0].(int)) + } +check_5: + if argc == 1 { + if _, ok := a[0].(float64); !ok { + goto check_6 + } + return Foo__SWIG_2(a[0].(float64)) + } +check_6: + if argc == 1 { + return Foo__SWIG_3(a[0].(string)) + } + if argc == 2 { + if _, ok := a[0].(Foos); !ok { + goto check_8 + } + if _, ok := a[1].(int); !ok { + goto check_8 + } + return Foo__SWIG_7(a[0].(Foos), a[1].(int)) + } +check_8: + if argc == 2 { + return Foo__SWIG_8(a[0].(float64), a[1].(Bar)) + } + panic("No match for overloaded function call") +} + +var _wrap_blah__SWIG_0 unsafe.Pointer + +func Blah__SWIG_0(arg1 float64) (_swig_ret string) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_blah__SWIG_0, _swig_p) + return +} +var _wrap_blah__SWIG_1 unsafe.Pointer + +func Blah__SWIG_1(arg1 string) (_swig_ret string) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_blah__SWIG_1, _swig_p) + return +} +func Blah(a ...interface{}) string { + argc := len(a) + if argc == 1 { + if _, ok := a[0].(float64); !ok { + goto check_1 + } + return Blah__SWIG_0(a[0].(float64)) + } +check_1: + if argc == 1 { + return Blah__SWIG_1(a[0].(string)) + } + panic("No match for overloaded function call") +} + +type SwigcptrSpam uintptr + +func (p SwigcptrSpam) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrSpam) SwigIsSpam() { +} + +var _wrap_new_Spam__SWIG_0 unsafe.Pointer + +func _swig_wrap_new_Spam__SWIG_0() (base SwigcptrSpam) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Spam__SWIG_0, _swig_p) + return +} + +func NewSpam__SWIG_0() (_swig_ret Spam) { + return _swig_wrap_new_Spam__SWIG_0() +} + +var _wrap_new_Spam__SWIG_1 unsafe.Pointer + +func _swig_wrap_new_Spam__SWIG_1(base int) (_ SwigcptrSpam) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Spam__SWIG_1, _swig_p) + return +} + +func NewSpam__SWIG_1(arg1 int) (_swig_ret Spam) { + return _swig_wrap_new_Spam__SWIG_1(arg1) +} + +var _wrap_new_Spam__SWIG_2 unsafe.Pointer + +func _swig_wrap_new_Spam__SWIG_2(base float64) (_ SwigcptrSpam) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Spam__SWIG_2, _swig_p) + return +} + +func NewSpam__SWIG_2(arg1 float64) (_swig_ret Spam) { + return _swig_wrap_new_Spam__SWIG_2(arg1) +} + +var _wrap_new_Spam__SWIG_3 unsafe.Pointer + +func _swig_wrap_new_Spam__SWIG_3(base string) (_ SwigcptrSpam) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Spam__SWIG_3, _swig_p) + return +} + +func NewSpam__SWIG_3(arg1 string) (_swig_ret Spam) { + return _swig_wrap_new_Spam__SWIG_3(arg1) +} + +var _wrap_new_Spam__SWIG_4 unsafe.Pointer + +func _swig_wrap_new_Spam__SWIG_4(base uintptr) (_ SwigcptrSpam) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Spam__SWIG_4, _swig_p) + return +} + +func NewSpam__SWIG_4(arg1 Foos) (_swig_ret Spam) { + return _swig_wrap_new_Spam__SWIG_4(arg1.Swigcptr()) +} + +var _wrap_new_Spam__SWIG_5 unsafe.Pointer + +func _swig_wrap_new_Spam__SWIG_5(base uintptr) (_ SwigcptrSpam) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Spam__SWIG_5, _swig_p) + return +} + +func NewSpam__SWIG_5(arg1 Bar) (_swig_ret Spam) { + return _swig_wrap_new_Spam__SWIG_5(arg1.Swigcptr()) +} + +var _wrap_new_Spam__SWIG_6 unsafe.Pointer + +func _swig_wrap_new_Spam__SWIG_6(base uintptr) (_ SwigcptrSpam) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Spam__SWIG_6, _swig_p) + return +} + +func NewSpam__SWIG_6(arg1 uintptr) (_swig_ret Spam) { + return _swig_wrap_new_Spam__SWIG_6(arg1) +} + +func NewSpam(a ...interface{}) Spam { + argc := len(a) + if argc == 0 { + return NewSpam__SWIG_0() + } + if argc == 1 { + if _, ok := a[0].(Foos); !ok { + goto check_2 + } + return NewSpam__SWIG_4(a[0].(Foos)) + } +check_2: + if argc == 1 { + if _, ok := a[0].(Bar); !ok { + goto check_3 + } + return NewSpam__SWIG_5(a[0].(Bar)) + } +check_3: + if argc == 1 { + if _, ok := a[0].(uintptr); !ok { + goto check_4 + } + return NewSpam__SWIG_6(a[0].(uintptr)) + } +check_4: + if argc == 1 { + if _, ok := a[0].(int); !ok { + goto check_5 + } + return NewSpam__SWIG_1(a[0].(int)) + } +check_5: + if argc == 1 { + if _, ok := a[0].(float64); !ok { + goto check_6 + } + return NewSpam__SWIG_2(a[0].(float64)) + } +check_6: + if argc == 1 { + return NewSpam__SWIG_3(a[0].(string)) + } + panic("No match for overloaded function call") +} + +var _wrap_Spam_Xtype_get unsafe.Pointer + +func _swig_wrap_Spam_Xtype_get(base SwigcptrSpam) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Spam_Xtype_get, _swig_p) + return +} + +func (arg1 SwigcptrSpam) GetXtype() (_swig_ret string) { + return _swig_wrap_Spam_Xtype_get(arg1) +} + +var _wrap_Spam_foo__SWIG_0 unsafe.Pointer + +func _swig_wrap_Spam_foo__SWIG_0(base SwigcptrSpam, _ int) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Spam_foo__SWIG_0, _swig_p) + return +} + +func (arg1 SwigcptrSpam) Foo__SWIG_0(arg2 int) (_swig_ret string) { + return _swig_wrap_Spam_foo__SWIG_0(arg1, arg2) +} + +var _wrap_Spam_foo__SWIG_1 unsafe.Pointer + +func _swig_wrap_Spam_foo__SWIG_1(base SwigcptrSpam, _ float64) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Spam_foo__SWIG_1, _swig_p) + return +} + +func (arg1 SwigcptrSpam) Foo__SWIG_1(arg2 float64) (_swig_ret string) { + return _swig_wrap_Spam_foo__SWIG_1(arg1, arg2) +} + +var _wrap_Spam_foo__SWIG_2 unsafe.Pointer + +func _swig_wrap_Spam_foo__SWIG_2(base SwigcptrSpam, _ string) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Spam_foo__SWIG_2, _swig_p) + return +} + +func (arg1 SwigcptrSpam) Foo__SWIG_2(arg2 string) (_swig_ret string) { + return _swig_wrap_Spam_foo__SWIG_2(arg1, arg2) +} + +var _wrap_Spam_foo__SWIG_3 unsafe.Pointer + +func _swig_wrap_Spam_foo__SWIG_3(base SwigcptrSpam, _ uintptr) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Spam_foo__SWIG_3, _swig_p) + return +} + +func (arg1 SwigcptrSpam) Foo__SWIG_3(arg2 Foos) (_swig_ret string) { + return _swig_wrap_Spam_foo__SWIG_3(arg1, arg2.Swigcptr()) +} + +var _wrap_Spam_foo__SWIG_4 unsafe.Pointer + +func _swig_wrap_Spam_foo__SWIG_4(base SwigcptrSpam, _ uintptr) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Spam_foo__SWIG_4, _swig_p) + return +} + +func (arg1 SwigcptrSpam) Foo__SWIG_4(arg2 Bar) (_swig_ret string) { + return _swig_wrap_Spam_foo__SWIG_4(arg1, arg2.Swigcptr()) +} + +var _wrap_Spam_foo__SWIG_5 unsafe.Pointer + +func _swig_wrap_Spam_foo__SWIG_5(base SwigcptrSpam, _ uintptr) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Spam_foo__SWIG_5, _swig_p) + return +} + +func (arg1 SwigcptrSpam) Foo__SWIG_5(arg2 uintptr) (_swig_ret string) { + return _swig_wrap_Spam_foo__SWIG_5(arg1, arg2) +} + +func (p SwigcptrSpam) Foo(a ...interface{}) string { + argc := len(a) + if argc == 1 { + if _, ok := a[0].(Foos); !ok { + goto check_1 + } + return p.Foo__SWIG_3(a[0].(Foos)) + } +check_1: + if argc == 1 { + if _, ok := a[0].(Bar); !ok { + goto check_2 + } + return p.Foo__SWIG_4(a[0].(Bar)) + } +check_2: + if argc == 1 { + if _, ok := a[0].(uintptr); !ok { + goto check_3 + } + return p.Foo__SWIG_5(a[0].(uintptr)) + } +check_3: + if argc == 1 { + if _, ok := a[0].(int); !ok { + goto check_4 + } + return p.Foo__SWIG_0(a[0].(int)) + } +check_4: + if argc == 1 { + if _, ok := a[0].(float64); !ok { + goto check_5 + } + return p.Foo__SWIG_1(a[0].(float64)) + } +check_5: + if argc == 1 { + return p.Foo__SWIG_2(a[0].(string)) + } + panic("No match for overloaded function call") +} + +var _wrap_Spam_bar__SWIG_0 unsafe.Pointer + +func SpamBar__SWIG_0(arg1 int) (_swig_ret string) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_Spam_bar__SWIG_0, _swig_p) + return +} +var _wrap_Spam_bar__SWIG_1 unsafe.Pointer + +func SpamBar__SWIG_1(arg1 float64) (_swig_ret string) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_Spam_bar__SWIG_1, _swig_p) + return +} +var _wrap_Spam_bar__SWIG_2 unsafe.Pointer + +func SpamBar__SWIG_2(arg1 string) (_swig_ret string) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_Spam_bar__SWIG_2, _swig_p) + return +} +var _wrap_Spam_bar__SWIG_3 unsafe.Pointer + +func _swig_wrap_Spam_bar__SWIG_3(base uintptr) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Spam_bar__SWIG_3, _swig_p) + return +} + +func SpamBar__SWIG_3(arg1 Foos) (_swig_ret string) { + return _swig_wrap_Spam_bar__SWIG_3(arg1.Swigcptr()) +} + +var _wrap_Spam_bar__SWIG_4 unsafe.Pointer + +func _swig_wrap_Spam_bar__SWIG_4(base uintptr) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Spam_bar__SWIG_4, _swig_p) + return +} + +func SpamBar__SWIG_4(arg1 Bar) (_swig_ret string) { + return _swig_wrap_Spam_bar__SWIG_4(arg1.Swigcptr()) +} + +var _wrap_Spam_bar__SWIG_5 unsafe.Pointer + +func SpamBar__SWIG_5(arg1 uintptr) (_swig_ret string) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_Spam_bar__SWIG_5, _swig_p) + return +} +func SpamBar(a ...interface{}) string { + argc := len(a) + if argc == 1 { + if _, ok := a[0].(Foos); !ok { + goto check_1 + } + return SpamBar__SWIG_3(a[0].(Foos)) + } +check_1: + if argc == 1 { + if _, ok := a[0].(Bar); !ok { + goto check_2 + } + return SpamBar__SWIG_4(a[0].(Bar)) + } +check_2: + if argc == 1 { + if _, ok := a[0].(uintptr); !ok { + goto check_3 + } + return SpamBar__SWIG_5(a[0].(uintptr)) + } +check_3: + if argc == 1 { + if _, ok := a[0].(int); !ok { + goto check_4 + } + return SpamBar__SWIG_0(a[0].(int)) + } +check_4: + if argc == 1 { + if _, ok := a[0].(float64); !ok { + goto check_5 + } + return SpamBar__SWIG_1(a[0].(float64)) + } +check_5: + if argc == 1 { + return SpamBar__SWIG_2(a[0].(string)) + } + panic("No match for overloaded function call") +} + +var _wrap_delete_Spam unsafe.Pointer + +func _swig_wrap_delete_Spam(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Spam, _swig_p) + return +} + +func DeleteSpam(arg1 Spam) { + _swig_wrap_delete_Spam(arg1.Swigcptr()) +} + +type Spam interface { + Swigcptr() uintptr + SwigIsSpam() + GetXtype() (_swig_ret string) + Foo(a ...interface{}) string +} + +var _wrap_fbool__SWIG_0 unsafe.Pointer + +func Fbool__SWIG_0(arg1 bool) (_swig_ret bool) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_fbool__SWIG_0, _swig_p) + return +} +var _wrap_fbool__SWIG_1 unsafe.Pointer + +func Fbool__SWIG_1(arg1 int) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_fbool__SWIG_1, _swig_p) + return +} +func Fbool(a ...interface{}) interface{} { + argc := len(a) + if argc == 1 { + if _, ok := a[0].(bool); !ok { + goto check_1 + } + return Fbool__SWIG_0(a[0].(bool)) + } +check_1: + if argc == 1 { + return Fbool__SWIG_1(a[0].(int)) + } + panic("No match for overloaded function call") +} + +var _wrap_fint unsafe.Pointer + +func Fint(arg1 int) (_swig_ret string) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_fint, _swig_p) + return +} +var _wrap_fdouble unsafe.Pointer + +func Fdouble(arg1 float64) (_swig_ret string) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_fdouble, _swig_p) + return +} +var _wrap_num__SWIG_0 unsafe.Pointer + +func Num__SWIG_0(arg1 int) (_swig_ret string) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_num__SWIG_0, _swig_p) + return +} +var _wrap_num__SWIG_1 unsafe.Pointer + +func Num__SWIG_1(arg1 float64) (_swig_ret string) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_num__SWIG_1, _swig_p) + return +} +func Num(a ...interface{}) string { + argc := len(a) + if argc == 1 { + if _, ok := a[0].(int); !ok { + goto check_1 + } + return Num__SWIG_0(a[0].(int)) + } +check_1: + if argc == 1 { + return Num__SWIG_1(a[0].(float64)) + } + panic("No match for overloaded function call") +} + +var _wrap_fid__SWIG_0 unsafe.Pointer + +func Fid__SWIG_0(arg1 int, arg2 int) (_swig_ret string) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_fid__SWIG_0, _swig_p) + return +} +var _wrap_fid__SWIG_1 unsafe.Pointer + +func Fid__SWIG_1(arg1 int, arg2 float64) (_swig_ret string) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_fid__SWIG_1, _swig_p) + return +} +var _wrap_fid__SWIG_2 unsafe.Pointer + +func Fid__SWIG_2(arg1 float64, arg2 int) (_swig_ret string) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_fid__SWIG_2, _swig_p) + return +} +var _wrap_fid__SWIG_3 unsafe.Pointer + +func Fid__SWIG_3(arg1 float64, arg2 float64) (_swig_ret string) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_fid__SWIG_3, _swig_p) + return +} +func Fid(a ...interface{}) string { + argc := len(a) + if argc == 2 { + if _, ok := a[0].(int); !ok { + goto check_1 + } + if _, ok := a[1].(int); !ok { + goto check_1 + } + return Fid__SWIG_0(a[0].(int), a[1].(int)) + } +check_1: + if argc == 2 { + if _, ok := a[0].(int); !ok { + goto check_2 + } + if _, ok := a[1].(float64); !ok { + goto check_2 + } + return Fid__SWIG_1(a[0].(int), a[1].(float64)) + } +check_2: + if argc == 2 { + if _, ok := a[1].(int); !ok { + goto check_3 + } + return Fid__SWIG_2(a[0].(float64), a[1].(int)) + } +check_3: + if argc == 2 { + return Fid__SWIG_3(a[0].(float64), a[1].(float64)) + } + panic("No match for overloaded function call") +} + +var _wrap_ull__SWIG_0 unsafe.Pointer + +func Ull__SWIG_0() (_swig_ret uint64) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_ull__SWIG_0, _swig_p) + return +} +var _wrap_ull__SWIG_1 unsafe.Pointer + +func Ull__SWIG_1(arg1 uint64) (_swig_ret uint64) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_ull__SWIG_1, _swig_p) + return +} +func Ull(a ...interface{}) uint64 { + argc := len(a) + if argc == 0 { + return Ull__SWIG_0() + } + if argc == 1 { + return Ull__SWIG_1(a[0].(uint64)) + } + panic("No match for overloaded function call") +} + +var _wrap_ll__SWIG_0 unsafe.Pointer + +func Ll__SWIG_0() (_swig_ret int64) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_ll__SWIG_0, _swig_p) + return +} +var _wrap_ll__SWIG_1 unsafe.Pointer + +func Ll__SWIG_1(arg1 int64) (_swig_ret int64) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_ll__SWIG_1, _swig_p) + return +} +func Ll(a ...interface{}) int64 { + argc := len(a) + if argc == 0 { + return Ll__SWIG_0() + } + if argc == 1 { + return Ll__SWIG_1(a[0].(int64)) + } + panic("No match for overloaded function call") +} + +var _wrap_malloc_void unsafe.Pointer + +func Malloc_void(arg1 int) (_swig_ret uintptr) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_malloc_void, _swig_p) + return +} +var _wrap_free_void unsafe.Pointer + +func _swig_wrap_free_void(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_free_void, _swig_p) + return +} + +func Free_void(arg1 uintptr) { + _swig_wrap_free_void(arg1) +} + +type SwigcptrClassA uintptr + +func (p SwigcptrClassA) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrClassA) SwigIsClassA() { +} + +var _wrap_new_ClassA unsafe.Pointer + +func _swig_wrap_new_ClassA() (base SwigcptrClassA) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_ClassA, _swig_p) + return +} + +func NewClassA() (_swig_ret ClassA) { + return _swig_wrap_new_ClassA() +} + +var _wrap_ClassA_method1__SWIG_0 unsafe.Pointer + +func _swig_wrap_ClassA_method1__SWIG_0(base SwigcptrClassA) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_ClassA_method1__SWIG_0, _swig_p) + return +} + +func (arg1 SwigcptrClassA) Method1__SWIG_0() (_swig_ret int) { + return _swig_wrap_ClassA_method1__SWIG_0(arg1) +} + +var _wrap_ClassA_method1__SWIG_1 unsafe.Pointer + +func _swig_wrap_ClassA_method1__SWIG_1(base SwigcptrClassA, _ int) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_ClassA_method1__SWIG_1, _swig_p) + return +} + +func (arg1 SwigcptrClassA) Method1__SWIG_1(arg2 int) (_swig_ret int) { + return _swig_wrap_ClassA_method1__SWIG_1(arg1, arg2) +} + +func (p SwigcptrClassA) Method1(a ...interface{}) int { + argc := len(a) + if argc == 0 { + return p.Method1__SWIG_0() + } + if argc == 1 { + return p.Method1__SWIG_1(a[0].(int)) + } + panic("No match for overloaded function call") +} + +var _wrap_delete_ClassA unsafe.Pointer + +func _swig_wrap_delete_ClassA(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_ClassA, _swig_p) + return +} + +func DeleteClassA(arg1 ClassA) { + _swig_wrap_delete_ClassA(arg1.Swigcptr()) +} + +type ClassA interface { + Swigcptr() uintptr + SwigIsClassA() + Method1(a ...interface{}) int +} + +var _wrap_int_object__SWIG_0 unsafe.Pointer + +func _swig_wrap_int_object__SWIG_0(base uintptr) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_int_object__SWIG_0, _swig_p) + return +} + +func Int_object__SWIG_0(arg1 Spam) (_swig_ret int) { + return _swig_wrap_int_object__SWIG_0(arg1.Swigcptr()) +} + +var _wrap_int_object__SWIG_1 unsafe.Pointer + +func Int_object__SWIG_1(arg1 int) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_int_object__SWIG_1, _swig_p) + return +} +func Int_object(a ...interface{}) int { + argc := len(a) + if argc == 1 { + if _, ok := a[0].(Spam); !ok { + goto check_1 + } + return Int_object__SWIG_0(a[0].(Spam)) + } +check_1: + if argc == 1 { + return Int_object__SWIG_1(a[0].(int)) + } + panic("No match for overloaded function call") +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/overload_simple_runme b/Examples/test-suite/go/overload_simple_runme new file mode 100755 index 000000000..94cf3ce48 Binary files /dev/null and b/Examples/test-suite/go/overload_simple_runme differ diff --git a/Examples/test-suite/go/overload_subtype.go b/Examples/test-suite/go/overload_subtype.go new file mode 100644 index 000000000..37dbe4400 --- /dev/null +++ b/Examples/test-suite/go/overload_subtype.go @@ -0,0 +1,161 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../overload_subtype.i + +package overload_subtype + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrFoo uintptr + +func (p SwigcptrFoo) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrFoo) SwigIsFoo() { +} + +var _wrap_new_Foo unsafe.Pointer + +func _swig_wrap_new_Foo() (base SwigcptrFoo) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Foo, _swig_p) + return +} + +func NewFoo() (_swig_ret Foo) { + return _swig_wrap_new_Foo() +} + +var _wrap_delete_Foo unsafe.Pointer + +func _swig_wrap_delete_Foo(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Foo, _swig_p) + return +} + +func DeleteFoo(arg1 Foo) { + _swig_wrap_delete_Foo(arg1.Swigcptr()) +} + +type Foo interface { + Swigcptr() uintptr + SwigIsFoo() +} + +type SwigcptrBar uintptr + +func (p SwigcptrBar) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrBar) SwigIsBar() { +} + +var _wrap_new_Bar unsafe.Pointer + +func _swig_wrap_new_Bar() (base SwigcptrBar) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Bar, _swig_p) + return +} + +func NewBar() (_swig_ret Bar) { + return _swig_wrap_new_Bar() +} + +var _wrap_delete_Bar unsafe.Pointer + +func _swig_wrap_delete_Bar(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Bar, _swig_p) + return +} + +func DeleteBar(arg1 Bar) { + _swig_wrap_delete_Bar(arg1.Swigcptr()) +} + +func (p SwigcptrBar) SwigIsFoo() { +} + +func (p SwigcptrBar) SwigGetFoo() Foo { + return SwigcptrFoo(p.Swigcptr()) +} + +type Bar interface { + Swigcptr() uintptr + SwigIsBar() + SwigIsFoo() + SwigGetFoo() Foo +} + +var _wrap_spam__SWIG_0 unsafe.Pointer + +func _swig_wrap_spam__SWIG_0(base uintptr) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_spam__SWIG_0, _swig_p) + return +} + +func Spam__SWIG_0(arg1 Foo) (_swig_ret int) { + return _swig_wrap_spam__SWIG_0(arg1.Swigcptr()) +} + +var _wrap_spam__SWIG_1 unsafe.Pointer + +func _swig_wrap_spam__SWIG_1(base uintptr) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_spam__SWIG_1, _swig_p) + return +} + +func Spam__SWIG_1(arg1 Bar) (_swig_ret int) { + return _swig_wrap_spam__SWIG_1(arg1.Swigcptr()) +} + +func Spam(a ...interface{}) int { + argc := len(a) + if argc == 1 { + if _, ok := a[0].(Bar); !ok { + goto check_1 + } + return Spam__SWIG_1(a[0].(Bar)) + } +check_1: + if argc == 1 { + return Spam__SWIG_0(a[0].(Foo)) + } + panic("No match for overloaded function call") +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/overload_subtype_runme b/Examples/test-suite/go/overload_subtype_runme new file mode 100755 index 000000000..adf12382f Binary files /dev/null and b/Examples/test-suite/go/overload_subtype_runme differ diff --git a/Examples/test-suite/go/overload_template.go b/Examples/test-suite/go/overload_template.go new file mode 100644 index 000000000..2d800049e --- /dev/null +++ b/Examples/test-suite/go/overload_template.go @@ -0,0 +1,1185 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../overload_template.i + +package overload_template + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +var _wrap_foo__SWIG_0 unsafe.Pointer + +func Foo__SWIG_0() (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_foo__SWIG_0, _swig_p) + return +} +var _wrap_foo__SWIG_2 unsafe.Pointer + +func Foo__SWIG_2(arg1 int) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_foo__SWIG_2, _swig_p) + return +} +var _wrap_foo__SWIG_3 unsafe.Pointer + +func Foo__SWIG_3(arg1 float64) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_foo__SWIG_3, _swig_p) + return +} +func Foo(a ...interface{}) int { + argc := len(a) + if argc == 0 { + return Foo__SWIG_0() + } + if argc == 1 { + if _, ok := a[0].(int); !ok { + goto check_2 + } + return Foo__SWIG_2(a[0].(int)) + } +check_2: + if argc == 1 { + return Foo__SWIG_3(a[0].(float64)) + } + panic("No match for overloaded function call") +} + +var _wrap_maximum__SWIG_1 unsafe.Pointer + +func Maximum__SWIG_1(arg1 int, arg2 int) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_maximum__SWIG_1, _swig_p) + return +} +var _wrap_maximum__SWIG_2 unsafe.Pointer + +func Maximum__SWIG_2(arg1 float64, arg2 float64) (_swig_ret float64) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_maximum__SWIG_2, _swig_p) + return +} +func Maximum(a ...interface{}) interface{} { + argc := len(a) + if argc == 2 { + if _, ok := a[0].(int); !ok { + goto check_1 + } + if _, ok := a[1].(int); !ok { + goto check_1 + } + return Maximum__SWIG_1(a[0].(int), a[1].(int)) + } +check_1: + if argc == 2 { + return Maximum__SWIG_2(a[0].(float64), a[1].(float64)) + } + panic("No match for overloaded function call") +} + +var _wrap_mix1__SWIG_0 unsafe.Pointer + +func Mix1__SWIG_0(arg1 string) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_mix1__SWIG_0, _swig_p) + return +} +var _wrap_mix1__SWIG_3 unsafe.Pointer + +func Mix1__SWIG_3(arg1 float64, arg2 float64) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_mix1__SWIG_3, _swig_p) + return +} +var _wrap_mix1__SWIG_4 unsafe.Pointer + +func Mix1__SWIG_4(arg1 float64) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_mix1__SWIG_4, _swig_p) + return +} +func Mix1(a ...interface{}) int { + argc := len(a) + if argc == 1 { + if _, ok := a[0].(float64); !ok { + goto check_1 + } + return Mix1__SWIG_4(a[0].(float64)) + } +check_1: + if argc == 1 { + return Mix1__SWIG_0(a[0].(string)) + } + if argc == 2 { + return Mix1__SWIG_3(a[0].(float64), a[1].(float64)) + } + panic("No match for overloaded function call") +} + +var _wrap_mix2__SWIG_1 unsafe.Pointer + +func Mix2__SWIG_1(arg1 string) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_mix2__SWIG_1, _swig_p) + return +} +var _wrap_mix2__SWIG_3 unsafe.Pointer + +func Mix2__SWIG_3(arg1 float64, arg2 float64) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_mix2__SWIG_3, _swig_p) + return +} +var _wrap_mix2__SWIG_4 unsafe.Pointer + +func Mix2__SWIG_4(arg1 float64) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_mix2__SWIG_4, _swig_p) + return +} +func Mix2(a ...interface{}) int { + argc := len(a) + if argc == 1 { + if _, ok := a[0].(float64); !ok { + goto check_1 + } + return Mix2__SWIG_4(a[0].(float64)) + } +check_1: + if argc == 1 { + return Mix2__SWIG_1(a[0].(string)) + } + if argc == 2 { + return Mix2__SWIG_3(a[0].(float64), a[1].(float64)) + } + panic("No match for overloaded function call") +} + +var _wrap_mix3__SWIG_2 unsafe.Pointer + +func Mix3__SWIG_2(arg1 string) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_mix3__SWIG_2, _swig_p) + return +} +var _wrap_mix3__SWIG_3 unsafe.Pointer + +func Mix3__SWIG_3(arg1 float64, arg2 float64) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_mix3__SWIG_3, _swig_p) + return +} +var _wrap_mix3__SWIG_4 unsafe.Pointer + +func Mix3__SWIG_4(arg1 float64) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_mix3__SWIG_4, _swig_p) + return +} +func Mix3(a ...interface{}) int { + argc := len(a) + if argc == 1 { + if _, ok := a[0].(float64); !ok { + goto check_1 + } + return Mix3__SWIG_4(a[0].(float64)) + } +check_1: + if argc == 1 { + return Mix3__SWIG_2(a[0].(string)) + } + if argc == 2 { + return Mix3__SWIG_3(a[0].(float64), a[1].(float64)) + } + panic("No match for overloaded function call") +} + +var _wrap_overtparams1__SWIG_2 unsafe.Pointer + +func Overtparams1__SWIG_2(arg1 int) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_overtparams1__SWIG_2, _swig_p) + return +} +var _wrap_overtparams1__SWIG_3 unsafe.Pointer + +func Overtparams1__SWIG_3(arg1 float64, arg2 int) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_overtparams1__SWIG_3, _swig_p) + return +} +func Overtparams1(a ...interface{}) int { + argc := len(a) + if argc == 1 { + return Overtparams1__SWIG_2(a[0].(int)) + } + if argc == 2 { + return Overtparams1__SWIG_3(a[0].(float64), a[1].(int)) + } + panic("No match for overloaded function call") +} + +var _wrap_overtparams2 unsafe.Pointer + +func Overtparams2(arg1 float64, arg2 int) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_overtparams2, _swig_p) + return +} +var _wrap_overloaded__SWIG_1 unsafe.Pointer + +func Overloaded__SWIG_1() (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_overloaded__SWIG_1, _swig_p) + return +} +var _wrap_overloaded__SWIG_3 unsafe.Pointer + +func Overloaded__SWIG_3(arg1 float64, arg2 int) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_overloaded__SWIG_3, _swig_p) + return +} +func Overloaded(a ...interface{}) int { + argc := len(a) + if argc == 0 { + return Overloaded__SWIG_1() + } + if argc == 2 { + return Overloaded__SWIG_3(a[0].(float64), a[1].(int)) + } + panic("No match for overloaded function call") +} + +var _wrap_overloadedagain__SWIG_0 unsafe.Pointer + +func Overloadedagain__SWIG_0(arg1 string) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_overloadedagain__SWIG_0, _swig_p) + return +} +var _wrap_overloadedagain__SWIG_3 unsafe.Pointer + +func Overloadedagain__SWIG_3() (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_overloadedagain__SWIG_3, _swig_p) + return +} +func Overloadedagain(a ...interface{}) int { + argc := len(a) + if argc == 0 { + return Overloadedagain__SWIG_3() + } + if argc == 1 { + return Overloadedagain__SWIG_0(a[0].(string)) + } + panic("No match for overloaded function call") +} + +var _wrap_xyz unsafe.Pointer + +func _swig_wrap_xyz() { + var _swig_p uintptr + _cgo_runtime_cgocall(_wrap_xyz, _swig_p) + return +} + +func Xyz() { + _swig_wrap_xyz() +} + +var _wrap_xyz_double unsafe.Pointer + +func _swig_wrap_xyz_double() { + var _swig_p uintptr + _cgo_runtime_cgocall(_wrap_xyz_double, _swig_p) + return +} + +func Xyz_double() { + _swig_wrap_xyz_double() +} + +var _wrap_xyz_int unsafe.Pointer + +func _swig_wrap_xyz_int() { + var _swig_p uintptr + _cgo_runtime_cgocall(_wrap_xyz_int, _swig_p) + return +} + +func Xyz_int() { + _swig_wrap_xyz_int() +} + +var _wrap_specialization__SWIG_4 unsafe.Pointer + +func Specialization__SWIG_4(arg1 int) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_specialization__SWIG_4, _swig_p) + return +} +var _wrap_specialization__SWIG_5 unsafe.Pointer + +func Specialization__SWIG_5(arg1 float64) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_specialization__SWIG_5, _swig_p) + return +} +var _wrap_specialization__SWIG_6 unsafe.Pointer + +func Specialization__SWIG_6(arg1 int, arg2 int) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_specialization__SWIG_6, _swig_p) + return +} +var _wrap_specialization__SWIG_7 unsafe.Pointer + +func Specialization__SWIG_7(arg1 float64, arg2 float64) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_specialization__SWIG_7, _swig_p) + return +} +var _wrap_specialization__SWIG_8 unsafe.Pointer + +func Specialization__SWIG_8(arg1 string, arg2 string) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_specialization__SWIG_8, _swig_p) + return +} +func Specialization(a ...interface{}) int { + argc := len(a) + if argc == 1 { + if _, ok := a[0].(int); !ok { + goto check_1 + } + return Specialization__SWIG_4(a[0].(int)) + } +check_1: + if argc == 1 { + return Specialization__SWIG_5(a[0].(float64)) + } + if argc == 2 { + if _, ok := a[0].(int); !ok { + goto check_3 + } + if _, ok := a[1].(int); !ok { + goto check_3 + } + return Specialization__SWIG_6(a[0].(int), a[1].(int)) + } +check_3: + if argc == 2 { + if _, ok := a[0].(float64); !ok { + goto check_4 + } + if _, ok := a[1].(float64); !ok { + goto check_4 + } + return Specialization__SWIG_7(a[0].(float64), a[1].(float64)) + } +check_4: + if argc == 2 { + return Specialization__SWIG_8(a[0].(string), a[1].(string)) + } + panic("No match for overloaded function call") +} + +var _wrap_overload__SWIG_0 unsafe.Pointer + +func Overload__SWIG_0(arg1 string) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_overload__SWIG_0, _swig_p) + return +} +var _wrap_overload__SWIG_4 unsafe.Pointer + +func Overload__SWIG_4() (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_overload__SWIG_4, _swig_p) + return +} +type SwigcptrKlass uintptr + +func (p SwigcptrKlass) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrKlass) SwigIsKlass() { +} + +var _wrap_new_Klass unsafe.Pointer + +func _swig_wrap_new_Klass() (base SwigcptrKlass) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Klass, _swig_p) + return +} + +func NewKlass() (_swig_ret Klass) { + return _swig_wrap_new_Klass() +} + +var _wrap_delete_Klass unsafe.Pointer + +func _swig_wrap_delete_Klass(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Klass, _swig_p) + return +} + +func DeleteKlass(arg1 Klass) { + _swig_wrap_delete_Klass(arg1.Swigcptr()) +} + +type Klass interface { + Swigcptr() uintptr + SwigIsKlass() +} + +var _wrap_overload__SWIG_5 unsafe.Pointer + +func Overload__SWIG_5(arg1 int) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_overload__SWIG_5, _swig_p) + return +} +var _wrap_overload__SWIG_6 unsafe.Pointer + +func Overload__SWIG_6(arg1 int, arg2 int) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_overload__SWIG_6, _swig_p) + return +} +var _wrap_overload__SWIG_7 unsafe.Pointer + +func Overload__SWIG_7(arg1 int, arg2 string) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_overload__SWIG_7, _swig_p) + return +} +var _wrap_overload__SWIG_8 unsafe.Pointer + +func _swig_wrap_overload__SWIG_8(base uintptr) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_overload__SWIG_8, _swig_p) + return +} + +func Overload__SWIG_8(arg1 Klass) (_swig_ret int) { + return _swig_wrap_overload__SWIG_8(arg1.Swigcptr()) +} + +var _wrap_overload__SWIG_9 unsafe.Pointer + +func _swig_wrap_overload__SWIG_9(base uintptr, _ uintptr) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_overload__SWIG_9, _swig_p) + return +} + +func Overload__SWIG_9(arg1 Klass, arg2 Klass) (_swig_ret int) { + return _swig_wrap_overload__SWIG_9(arg1.Swigcptr(), arg2.Swigcptr()) +} + +var _wrap_overload__SWIG_10 unsafe.Pointer + +func _swig_wrap_overload__SWIG_10(base uintptr, _ string) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_overload__SWIG_10, _swig_p) + return +} + +func Overload__SWIG_10(arg1 Klass, arg2 string) (_swig_ret int) { + return _swig_wrap_overload__SWIG_10(arg1.Swigcptr(), arg2) +} + +var _wrap_overload__SWIG_11 unsafe.Pointer + +func Overload__SWIG_11(arg1 float64) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_overload__SWIG_11, _swig_p) + return +} +var _wrap_overload__SWIG_12 unsafe.Pointer + +func Overload__SWIG_12(arg1 float64, arg2 float64) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_overload__SWIG_12, _swig_p) + return +} +var _wrap_overload__SWIG_13 unsafe.Pointer + +func Overload__SWIG_13(arg1 float64, arg2 string) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_overload__SWIG_13, _swig_p) + return +} +func Overload(a ...interface{}) int { + argc := len(a) + if argc == 0 { + return Overload__SWIG_4() + } + if argc == 1 { + if _, ok := a[0].(Klass); !ok { + goto check_2 + } + return Overload__SWIG_8(a[0].(Klass)) + } +check_2: + if argc == 1 { + if _, ok := a[0].(int); !ok { + goto check_3 + } + return Overload__SWIG_5(a[0].(int)) + } +check_3: + if argc == 1 { + if _, ok := a[0].(float64); !ok { + goto check_4 + } + return Overload__SWIG_11(a[0].(float64)) + } +check_4: + if argc == 1 { + return Overload__SWIG_0(a[0].(string)) + } + if argc == 2 { + if _, ok := a[0].(Klass); !ok { + goto check_6 + } + if _, ok := a[1].(Klass); !ok { + goto check_6 + } + return Overload__SWIG_9(a[0].(Klass), a[1].(Klass)) + } +check_6: + if argc == 2 { + if _, ok := a[0].(Klass); !ok { + goto check_7 + } + if _, ok := a[1].(string); !ok { + goto check_7 + } + return Overload__SWIG_10(a[0].(Klass), a[1].(string)) + } +check_7: + if argc == 2 { + if _, ok := a[0].(int); !ok { + goto check_8 + } + if _, ok := a[1].(int); !ok { + goto check_8 + } + return Overload__SWIG_6(a[0].(int), a[1].(int)) + } +check_8: + if argc == 2 { + if _, ok := a[0].(int); !ok { + goto check_9 + } + if _, ok := a[1].(string); !ok { + goto check_9 + } + return Overload__SWIG_7(a[0].(int), a[1].(string)) + } +check_9: + if argc == 2 { + if _, ok := a[1].(float64); !ok { + goto check_10 + } + return Overload__SWIG_12(a[0].(float64), a[1].(float64)) + } +check_10: + if argc == 2 { + return Overload__SWIG_13(a[0].(float64), a[1].(string)) + } + panic("No match for overloaded function call") +} + +var _wrap_nsoverload__SWIG_0 unsafe.Pointer + +func Nsoverload__SWIG_0(arg1 string) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_nsoverload__SWIG_0, _swig_p) + return +} +var _wrap_nsoverload__SWIG_4 unsafe.Pointer + +func Nsoverload__SWIG_4() (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_nsoverload__SWIG_4, _swig_p) + return +} +var _wrap_nsoverload__SWIG_5 unsafe.Pointer + +func Nsoverload__SWIG_5(arg1 int) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_nsoverload__SWIG_5, _swig_p) + return +} +var _wrap_nsoverload__SWIG_6 unsafe.Pointer + +func Nsoverload__SWIG_6(arg1 int, arg2 int) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_nsoverload__SWIG_6, _swig_p) + return +} +var _wrap_nsoverload__SWIG_7 unsafe.Pointer + +func Nsoverload__SWIG_7(arg1 int, arg2 string) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_nsoverload__SWIG_7, _swig_p) + return +} +var _wrap_nsoverload__SWIG_8 unsafe.Pointer + +func _swig_wrap_nsoverload__SWIG_8(base uintptr) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_nsoverload__SWIG_8, _swig_p) + return +} + +func Nsoverload__SWIG_8(arg1 Klass) (_swig_ret int) { + return _swig_wrap_nsoverload__SWIG_8(arg1.Swigcptr()) +} + +var _wrap_nsoverload__SWIG_9 unsafe.Pointer + +func _swig_wrap_nsoverload__SWIG_9(base uintptr, _ uintptr) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_nsoverload__SWIG_9, _swig_p) + return +} + +func Nsoverload__SWIG_9(arg1 Klass, arg2 Klass) (_swig_ret int) { + return _swig_wrap_nsoverload__SWIG_9(arg1.Swigcptr(), arg2.Swigcptr()) +} + +var _wrap_nsoverload__SWIG_10 unsafe.Pointer + +func _swig_wrap_nsoverload__SWIG_10(base uintptr, _ string) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_nsoverload__SWIG_10, _swig_p) + return +} + +func Nsoverload__SWIG_10(arg1 Klass, arg2 string) (_swig_ret int) { + return _swig_wrap_nsoverload__SWIG_10(arg1.Swigcptr(), arg2) +} + +var _wrap_nsoverload__SWIG_11 unsafe.Pointer + +func Nsoverload__SWIG_11(arg1 float64) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_nsoverload__SWIG_11, _swig_p) + return +} +var _wrap_nsoverload__SWIG_12 unsafe.Pointer + +func Nsoverload__SWIG_12(arg1 float64, arg2 float64) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_nsoverload__SWIG_12, _swig_p) + return +} +var _wrap_nsoverload__SWIG_13 unsafe.Pointer + +func Nsoverload__SWIG_13(arg1 float64, arg2 string) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_nsoverload__SWIG_13, _swig_p) + return +} +func Nsoverload(a ...interface{}) int { + argc := len(a) + if argc == 0 { + return Nsoverload__SWIG_4() + } + if argc == 1 { + if _, ok := a[0].(Klass); !ok { + goto check_2 + } + return Nsoverload__SWIG_8(a[0].(Klass)) + } +check_2: + if argc == 1 { + if _, ok := a[0].(int); !ok { + goto check_3 + } + return Nsoverload__SWIG_5(a[0].(int)) + } +check_3: + if argc == 1 { + if _, ok := a[0].(float64); !ok { + goto check_4 + } + return Nsoverload__SWIG_11(a[0].(float64)) + } +check_4: + if argc == 1 { + return Nsoverload__SWIG_0(a[0].(string)) + } + if argc == 2 { + if _, ok := a[0].(Klass); !ok { + goto check_6 + } + if _, ok := a[1].(Klass); !ok { + goto check_6 + } + return Nsoverload__SWIG_9(a[0].(Klass), a[1].(Klass)) + } +check_6: + if argc == 2 { + if _, ok := a[0].(Klass); !ok { + goto check_7 + } + if _, ok := a[1].(string); !ok { + goto check_7 + } + return Nsoverload__SWIG_10(a[0].(Klass), a[1].(string)) + } +check_7: + if argc == 2 { + if _, ok := a[0].(int); !ok { + goto check_8 + } + if _, ok := a[1].(int); !ok { + goto check_8 + } + return Nsoverload__SWIG_6(a[0].(int), a[1].(int)) + } +check_8: + if argc == 2 { + if _, ok := a[0].(int); !ok { + goto check_9 + } + if _, ok := a[1].(string); !ok { + goto check_9 + } + return Nsoverload__SWIG_7(a[0].(int), a[1].(string)) + } +check_9: + if argc == 2 { + if _, ok := a[1].(float64); !ok { + goto check_10 + } + return Nsoverload__SWIG_12(a[0].(float64), a[1].(float64)) + } +check_10: + if argc == 2 { + return Nsoverload__SWIG_13(a[0].(float64), a[1].(string)) + } + panic("No match for overloaded function call") +} + +type SwigcptrA uintptr + +func (p SwigcptrA) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrA) SwigIsA() { +} + +var _wrap_A_foo__SWIG_0 unsafe.Pointer + +func _swig_wrap_A_foo__SWIG_0(base float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_A_foo__SWIG_0, _swig_p) + return +} + +func AFoo__SWIG_0(arg1 float64) { + _swig_wrap_A_foo__SWIG_0(arg1) +} + +var _wrap_A_foo__SWIG_1 unsafe.Pointer + +func _swig_wrap_A_foo__SWIG_1(base int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_A_foo__SWIG_1, _swig_p) + return +} + +func AFoo__SWIG_1(arg1 int) { + _swig_wrap_A_foo__SWIG_1(arg1) +} + +var _wrap_A_foo__SWIG_2 unsafe.Pointer + +func _swig_wrap_A_foo__SWIG_2(base byte) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_A_foo__SWIG_2, _swig_p) + return +} + +func AFoo__SWIG_2(arg1 byte) { + _swig_wrap_A_foo__SWIG_2(arg1) +} + +func AFoo(a ...interface{}) { + argc := len(a) + if argc == 1 { + if _, ok := a[0].(int); !ok { + goto check_1 + } + AFoo__SWIG_1(a[0].(int)) + return + } +check_1: + if argc == 1 { + if _, ok := a[0].(float64); !ok { + goto check_2 + } + AFoo__SWIG_0(a[0].(float64)) + return + } +check_2: + if argc == 1 { + AFoo__SWIG_2(a[0].(byte)) + return + } + panic("No match for overloaded function call") +} + +var _wrap_new_A unsafe.Pointer + +func _swig_wrap_new_A() (base SwigcptrA) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_A, _swig_p) + return +} + +func NewA() (_swig_ret A) { + return _swig_wrap_new_A() +} + +var _wrap_delete_A unsafe.Pointer + +func _swig_wrap_delete_A(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_A, _swig_p) + return +} + +func DeleteA(arg1 A) { + _swig_wrap_delete_A(arg1.Swigcptr()) +} + +type A interface { + Swigcptr() uintptr + SwigIsA() +} + +type SwigcptrB uintptr + +func (p SwigcptrB) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrB) SwigIsB() { +} + +var _wrap_B_foo__SWIG_0 unsafe.Pointer + +func _swig_wrap_B_foo__SWIG_0(base SwigcptrB, _ float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_B_foo__SWIG_0, _swig_p) + return +} + +func (arg1 SwigcptrB) Foo__SWIG_0(arg2 float64) { + _swig_wrap_B_foo__SWIG_0(arg1, arg2) +} + +var _wrap_B_foo__SWIG_1 unsafe.Pointer + +func _swig_wrap_B_foo__SWIG_1(base SwigcptrB, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_B_foo__SWIG_1, _swig_p) + return +} + +func (arg1 SwigcptrB) Foo__SWIG_1(arg2 int) { + _swig_wrap_B_foo__SWIG_1(arg1, arg2) +} + +var _wrap_B_foo__SWIG_2 unsafe.Pointer + +func _swig_wrap_B_foo__SWIG_2(base SwigcptrB, _ byte) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_B_foo__SWIG_2, _swig_p) + return +} + +func (arg1 SwigcptrB) Foo__SWIG_2(arg2 byte) { + _swig_wrap_B_foo__SWIG_2(arg1, arg2) +} + +func (p SwigcptrB) Foo(a ...interface{}) { + argc := len(a) + if argc == 1 { + if _, ok := a[0].(int); !ok { + goto check_1 + } + p.Foo__SWIG_1(a[0].(int)) + return + } +check_1: + if argc == 1 { + if _, ok := a[0].(float64); !ok { + goto check_2 + } + p.Foo__SWIG_0(a[0].(float64)) + return + } +check_2: + if argc == 1 { + p.Foo__SWIG_2(a[0].(byte)) + return + } + panic("No match for overloaded function call") +} + +var _wrap_new_B unsafe.Pointer + +func _swig_wrap_new_B() (base SwigcptrB) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_B, _swig_p) + return +} + +func NewB() (_swig_ret B) { + return _swig_wrap_new_B() +} + +var _wrap_delete_B unsafe.Pointer + +func _swig_wrap_delete_B(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_B, _swig_p) + return +} + +func DeleteB(arg1 B) { + _swig_wrap_delete_B(arg1.Swigcptr()) +} + +type B interface { + Swigcptr() uintptr + SwigIsB() + Foo(a ...interface{}) +} + +type SwigcptrBar_d uintptr + +func (p SwigcptrBar_d) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrBar_d) SwigIsBar_d() { +} + +var _wrap_Bar_d_foo__SWIG_0 unsafe.Pointer + +func _swig_wrap_Bar_d_foo__SWIG_0(base SwigcptrBar_d, _ float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Bar_d_foo__SWIG_0, _swig_p) + return +} + +func (arg1 SwigcptrBar_d) Foo__SWIG_0(arg2 float64) { + _swig_wrap_Bar_d_foo__SWIG_0(arg1, arg2) +} + +var _wrap_Bar_d_foo__SWIG_1 unsafe.Pointer + +func _swig_wrap_Bar_d_foo__SWIG_1(base SwigcptrBar_d, _ float64, _ float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Bar_d_foo__SWIG_1, _swig_p) + return +} + +func (arg1 SwigcptrBar_d) Foo__SWIG_1(arg2 float64, arg3 float64) { + _swig_wrap_Bar_d_foo__SWIG_1(arg1, arg2, arg3) +} + +var _wrap_Bar_d_foo__SWIG_2 unsafe.Pointer + +func _swig_wrap_Bar_d_foo__SWIG_2(base SwigcptrBar_d, _ int, _ int, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Bar_d_foo__SWIG_2, _swig_p) + return +} + +func (arg1 SwigcptrBar_d) Foo__SWIG_2(arg2 int, arg3 int, arg4 int) { + _swig_wrap_Bar_d_foo__SWIG_2(arg1, arg2, arg3, arg4) +} + +func (p SwigcptrBar_d) Foo(a ...interface{}) { + argc := len(a) + if argc == 1 { + p.Foo__SWIG_0(a[0].(float64)) + return + } + if argc == 2 { + p.Foo__SWIG_1(a[0].(float64), a[1].(float64)) + return + } + if argc == 3 { + p.Foo__SWIG_2(a[0].(int), a[1].(int), a[2].(int)) + return + } + panic("No match for overloaded function call") +} + +var _wrap_new_Bar_d unsafe.Pointer + +func _swig_wrap_new_Bar_d() (base SwigcptrBar_d) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Bar_d, _swig_p) + return +} + +func NewBar_d() (_swig_ret Bar_d) { + return _swig_wrap_new_Bar_d() +} + +var _wrap_delete_Bar_d unsafe.Pointer + +func _swig_wrap_delete_Bar_d(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Bar_d, _swig_p) + return +} + +func DeleteBar_d(arg1 Bar_d) { + _swig_wrap_delete_Bar_d(arg1.Swigcptr()) +} + +type Bar_d interface { + Swigcptr() uintptr + SwigIsBar_d() + Foo(a ...interface{}) +} + +type SwigcptrFoo_d uintptr + +func (p SwigcptrFoo_d) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrFoo_d) SwigIsFoo_d() { +} + +var _wrap_Foo_d_bar__SWIG_0 unsafe.Pointer + +func _swig_wrap_Foo_d_bar__SWIG_0(base SwigcptrFoo_d, _ float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_d_bar__SWIG_0, _swig_p) + return +} + +func (arg1 SwigcptrFoo_d) Bar__SWIG_0(arg2 float64) { + _swig_wrap_Foo_d_bar__SWIG_0(arg1, arg2) +} + +var _wrap_Foo_d_bar__SWIG_1 unsafe.Pointer + +func _swig_wrap_Foo_d_bar__SWIG_1(base SwigcptrFoo_d, _ float64, _ float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_d_bar__SWIG_1, _swig_p) + return +} + +func (arg1 SwigcptrFoo_d) Bar__SWIG_1(arg2 float64, arg3 float64) { + _swig_wrap_Foo_d_bar__SWIG_1(arg1, arg2, arg3) +} + +var _wrap_Foo_d_bar__SWIG_2 unsafe.Pointer + +func _swig_wrap_Foo_d_bar__SWIG_2(base SwigcptrFoo_d, _ int, _ int, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_d_bar__SWIG_2, _swig_p) + return +} + +func (arg1 SwigcptrFoo_d) Bar__SWIG_2(arg2 int, arg3 int, arg4 int) { + _swig_wrap_Foo_d_bar__SWIG_2(arg1, arg2, arg3, arg4) +} + +func (p SwigcptrFoo_d) Bar(a ...interface{}) { + argc := len(a) + if argc == 1 { + p.Bar__SWIG_0(a[0].(float64)) + return + } + if argc == 2 { + p.Bar__SWIG_1(a[0].(float64), a[1].(float64)) + return + } + if argc == 3 { + p.Bar__SWIG_2(a[0].(int), a[1].(int), a[2].(int)) + return + } + panic("No match for overloaded function call") +} + +var _wrap_new_Foo_d unsafe.Pointer + +func _swig_wrap_new_Foo_d() (base SwigcptrFoo_d) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Foo_d, _swig_p) + return +} + +func NewFoo_d() (_swig_ret Foo_d) { + return _swig_wrap_new_Foo_d() +} + +var _wrap_delete_Foo_d unsafe.Pointer + +func _swig_wrap_delete_Foo_d(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Foo_d, _swig_p) + return +} + +func DeleteFoo_d(arg1 Foo_d) { + _swig_wrap_delete_Foo_d(arg1.Swigcptr()) +} + +type Foo_d interface { + Swigcptr() uintptr + SwigIsFoo_d() + Bar(a ...interface{}) +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/overload_template_fast.go b/Examples/test-suite/go/overload_template_fast.go new file mode 100644 index 000000000..0bfd3a5b6 --- /dev/null +++ b/Examples/test-suite/go/overload_template_fast.go @@ -0,0 +1,1185 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../overload_template_fast.i + +package overload_template_fast + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +var _wrap_foo__SWIG_0 unsafe.Pointer + +func Foo__SWIG_0() (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_foo__SWIG_0, _swig_p) + return +} +var _wrap_foo__SWIG_2 unsafe.Pointer + +func Foo__SWIG_2(arg1 int) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_foo__SWIG_2, _swig_p) + return +} +var _wrap_foo__SWIG_3 unsafe.Pointer + +func Foo__SWIG_3(arg1 float64) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_foo__SWIG_3, _swig_p) + return +} +func Foo(a ...interface{}) int { + argc := len(a) + if argc == 0 { + return Foo__SWIG_0() + } + if argc == 1 { + if _, ok := a[0].(int); !ok { + goto check_2 + } + return Foo__SWIG_2(a[0].(int)) + } +check_2: + if argc == 1 { + return Foo__SWIG_3(a[0].(float64)) + } + panic("No match for overloaded function call") +} + +var _wrap_maximum__SWIG_1 unsafe.Pointer + +func Maximum__SWIG_1(arg1 int, arg2 int) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_maximum__SWIG_1, _swig_p) + return +} +var _wrap_maximum__SWIG_2 unsafe.Pointer + +func Maximum__SWIG_2(arg1 float64, arg2 float64) (_swig_ret float64) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_maximum__SWIG_2, _swig_p) + return +} +func Maximum(a ...interface{}) interface{} { + argc := len(a) + if argc == 2 { + if _, ok := a[0].(int); !ok { + goto check_1 + } + if _, ok := a[1].(int); !ok { + goto check_1 + } + return Maximum__SWIG_1(a[0].(int), a[1].(int)) + } +check_1: + if argc == 2 { + return Maximum__SWIG_2(a[0].(float64), a[1].(float64)) + } + panic("No match for overloaded function call") +} + +var _wrap_mix1__SWIG_0 unsafe.Pointer + +func Mix1__SWIG_0(arg1 string) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_mix1__SWIG_0, _swig_p) + return +} +var _wrap_mix1__SWIG_3 unsafe.Pointer + +func Mix1__SWIG_3(arg1 float64, arg2 float64) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_mix1__SWIG_3, _swig_p) + return +} +var _wrap_mix1__SWIG_4 unsafe.Pointer + +func Mix1__SWIG_4(arg1 float64) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_mix1__SWIG_4, _swig_p) + return +} +func Mix1(a ...interface{}) int { + argc := len(a) + if argc == 1 { + if _, ok := a[0].(float64); !ok { + goto check_1 + } + return Mix1__SWIG_4(a[0].(float64)) + } +check_1: + if argc == 1 { + return Mix1__SWIG_0(a[0].(string)) + } + if argc == 2 { + return Mix1__SWIG_3(a[0].(float64), a[1].(float64)) + } + panic("No match for overloaded function call") +} + +var _wrap_mix2__SWIG_1 unsafe.Pointer + +func Mix2__SWIG_1(arg1 string) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_mix2__SWIG_1, _swig_p) + return +} +var _wrap_mix2__SWIG_3 unsafe.Pointer + +func Mix2__SWIG_3(arg1 float64, arg2 float64) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_mix2__SWIG_3, _swig_p) + return +} +var _wrap_mix2__SWIG_4 unsafe.Pointer + +func Mix2__SWIG_4(arg1 float64) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_mix2__SWIG_4, _swig_p) + return +} +func Mix2(a ...interface{}) int { + argc := len(a) + if argc == 1 { + if _, ok := a[0].(float64); !ok { + goto check_1 + } + return Mix2__SWIG_4(a[0].(float64)) + } +check_1: + if argc == 1 { + return Mix2__SWIG_1(a[0].(string)) + } + if argc == 2 { + return Mix2__SWIG_3(a[0].(float64), a[1].(float64)) + } + panic("No match for overloaded function call") +} + +var _wrap_mix3__SWIG_2 unsafe.Pointer + +func Mix3__SWIG_2(arg1 string) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_mix3__SWIG_2, _swig_p) + return +} +var _wrap_mix3__SWIG_3 unsafe.Pointer + +func Mix3__SWIG_3(arg1 float64, arg2 float64) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_mix3__SWIG_3, _swig_p) + return +} +var _wrap_mix3__SWIG_4 unsafe.Pointer + +func Mix3__SWIG_4(arg1 float64) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_mix3__SWIG_4, _swig_p) + return +} +func Mix3(a ...interface{}) int { + argc := len(a) + if argc == 1 { + if _, ok := a[0].(float64); !ok { + goto check_1 + } + return Mix3__SWIG_4(a[0].(float64)) + } +check_1: + if argc == 1 { + return Mix3__SWIG_2(a[0].(string)) + } + if argc == 2 { + return Mix3__SWIG_3(a[0].(float64), a[1].(float64)) + } + panic("No match for overloaded function call") +} + +var _wrap_overtparams1__SWIG_2 unsafe.Pointer + +func Overtparams1__SWIG_2(arg1 int) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_overtparams1__SWIG_2, _swig_p) + return +} +var _wrap_overtparams1__SWIG_3 unsafe.Pointer + +func Overtparams1__SWIG_3(arg1 float64, arg2 int) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_overtparams1__SWIG_3, _swig_p) + return +} +func Overtparams1(a ...interface{}) int { + argc := len(a) + if argc == 1 { + return Overtparams1__SWIG_2(a[0].(int)) + } + if argc == 2 { + return Overtparams1__SWIG_3(a[0].(float64), a[1].(int)) + } + panic("No match for overloaded function call") +} + +var _wrap_overtparams2 unsafe.Pointer + +func Overtparams2(arg1 float64, arg2 int) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_overtparams2, _swig_p) + return +} +var _wrap_overloaded__SWIG_1 unsafe.Pointer + +func Overloaded__SWIG_1() (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_overloaded__SWIG_1, _swig_p) + return +} +var _wrap_overloaded__SWIG_3 unsafe.Pointer + +func Overloaded__SWIG_3(arg1 float64, arg2 int) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_overloaded__SWIG_3, _swig_p) + return +} +func Overloaded(a ...interface{}) int { + argc := len(a) + if argc == 0 { + return Overloaded__SWIG_1() + } + if argc == 2 { + return Overloaded__SWIG_3(a[0].(float64), a[1].(int)) + } + panic("No match for overloaded function call") +} + +var _wrap_overloadedagain__SWIG_0 unsafe.Pointer + +func Overloadedagain__SWIG_0(arg1 string) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_overloadedagain__SWIG_0, _swig_p) + return +} +var _wrap_overloadedagain__SWIG_3 unsafe.Pointer + +func Overloadedagain__SWIG_3() (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_overloadedagain__SWIG_3, _swig_p) + return +} +func Overloadedagain(a ...interface{}) int { + argc := len(a) + if argc == 0 { + return Overloadedagain__SWIG_3() + } + if argc == 1 { + return Overloadedagain__SWIG_0(a[0].(string)) + } + panic("No match for overloaded function call") +} + +var _wrap_xyz unsafe.Pointer + +func _swig_wrap_xyz() { + var _swig_p uintptr + _cgo_runtime_cgocall(_wrap_xyz, _swig_p) + return +} + +func Xyz() { + _swig_wrap_xyz() +} + +var _wrap_xyz_double unsafe.Pointer + +func _swig_wrap_xyz_double() { + var _swig_p uintptr + _cgo_runtime_cgocall(_wrap_xyz_double, _swig_p) + return +} + +func Xyz_double() { + _swig_wrap_xyz_double() +} + +var _wrap_xyz_int unsafe.Pointer + +func _swig_wrap_xyz_int() { + var _swig_p uintptr + _cgo_runtime_cgocall(_wrap_xyz_int, _swig_p) + return +} + +func Xyz_int() { + _swig_wrap_xyz_int() +} + +var _wrap_specialization__SWIG_4 unsafe.Pointer + +func Specialization__SWIG_4(arg1 int) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_specialization__SWIG_4, _swig_p) + return +} +var _wrap_specialization__SWIG_5 unsafe.Pointer + +func Specialization__SWIG_5(arg1 float64) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_specialization__SWIG_5, _swig_p) + return +} +var _wrap_specialization__SWIG_6 unsafe.Pointer + +func Specialization__SWIG_6(arg1 int, arg2 int) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_specialization__SWIG_6, _swig_p) + return +} +var _wrap_specialization__SWIG_7 unsafe.Pointer + +func Specialization__SWIG_7(arg1 float64, arg2 float64) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_specialization__SWIG_7, _swig_p) + return +} +var _wrap_specialization__SWIG_8 unsafe.Pointer + +func Specialization__SWIG_8(arg1 string, arg2 string) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_specialization__SWIG_8, _swig_p) + return +} +func Specialization(a ...interface{}) int { + argc := len(a) + if argc == 1 { + if _, ok := a[0].(int); !ok { + goto check_1 + } + return Specialization__SWIG_4(a[0].(int)) + } +check_1: + if argc == 1 { + return Specialization__SWIG_5(a[0].(float64)) + } + if argc == 2 { + if _, ok := a[0].(int); !ok { + goto check_3 + } + if _, ok := a[1].(int); !ok { + goto check_3 + } + return Specialization__SWIG_6(a[0].(int), a[1].(int)) + } +check_3: + if argc == 2 { + if _, ok := a[0].(float64); !ok { + goto check_4 + } + if _, ok := a[1].(float64); !ok { + goto check_4 + } + return Specialization__SWIG_7(a[0].(float64), a[1].(float64)) + } +check_4: + if argc == 2 { + return Specialization__SWIG_8(a[0].(string), a[1].(string)) + } + panic("No match for overloaded function call") +} + +var _wrap_overload__SWIG_0 unsafe.Pointer + +func Overload__SWIG_0(arg1 string) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_overload__SWIG_0, _swig_p) + return +} +var _wrap_overload__SWIG_4 unsafe.Pointer + +func Overload__SWIG_4() (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_overload__SWIG_4, _swig_p) + return +} +type SwigcptrKlass uintptr + +func (p SwigcptrKlass) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrKlass) SwigIsKlass() { +} + +var _wrap_new_Klass unsafe.Pointer + +func _swig_wrap_new_Klass() (base SwigcptrKlass) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Klass, _swig_p) + return +} + +func NewKlass() (_swig_ret Klass) { + return _swig_wrap_new_Klass() +} + +var _wrap_delete_Klass unsafe.Pointer + +func _swig_wrap_delete_Klass(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Klass, _swig_p) + return +} + +func DeleteKlass(arg1 Klass) { + _swig_wrap_delete_Klass(arg1.Swigcptr()) +} + +type Klass interface { + Swigcptr() uintptr + SwigIsKlass() +} + +var _wrap_overload__SWIG_5 unsafe.Pointer + +func Overload__SWIG_5(arg1 int) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_overload__SWIG_5, _swig_p) + return +} +var _wrap_overload__SWIG_6 unsafe.Pointer + +func Overload__SWIG_6(arg1 int, arg2 int) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_overload__SWIG_6, _swig_p) + return +} +var _wrap_overload__SWIG_7 unsafe.Pointer + +func Overload__SWIG_7(arg1 int, arg2 string) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_overload__SWIG_7, _swig_p) + return +} +var _wrap_overload__SWIG_8 unsafe.Pointer + +func _swig_wrap_overload__SWIG_8(base uintptr) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_overload__SWIG_8, _swig_p) + return +} + +func Overload__SWIG_8(arg1 Klass) (_swig_ret int) { + return _swig_wrap_overload__SWIG_8(arg1.Swigcptr()) +} + +var _wrap_overload__SWIG_9 unsafe.Pointer + +func _swig_wrap_overload__SWIG_9(base uintptr, _ uintptr) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_overload__SWIG_9, _swig_p) + return +} + +func Overload__SWIG_9(arg1 Klass, arg2 Klass) (_swig_ret int) { + return _swig_wrap_overload__SWIG_9(arg1.Swigcptr(), arg2.Swigcptr()) +} + +var _wrap_overload__SWIG_10 unsafe.Pointer + +func _swig_wrap_overload__SWIG_10(base uintptr, _ string) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_overload__SWIG_10, _swig_p) + return +} + +func Overload__SWIG_10(arg1 Klass, arg2 string) (_swig_ret int) { + return _swig_wrap_overload__SWIG_10(arg1.Swigcptr(), arg2) +} + +var _wrap_overload__SWIG_11 unsafe.Pointer + +func Overload__SWIG_11(arg1 float64) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_overload__SWIG_11, _swig_p) + return +} +var _wrap_overload__SWIG_12 unsafe.Pointer + +func Overload__SWIG_12(arg1 float64, arg2 float64) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_overload__SWIG_12, _swig_p) + return +} +var _wrap_overload__SWIG_13 unsafe.Pointer + +func Overload__SWIG_13(arg1 float64, arg2 string) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_overload__SWIG_13, _swig_p) + return +} +func Overload(a ...interface{}) int { + argc := len(a) + if argc == 0 { + return Overload__SWIG_4() + } + if argc == 1 { + if _, ok := a[0].(Klass); !ok { + goto check_2 + } + return Overload__SWIG_8(a[0].(Klass)) + } +check_2: + if argc == 1 { + if _, ok := a[0].(int); !ok { + goto check_3 + } + return Overload__SWIG_5(a[0].(int)) + } +check_3: + if argc == 1 { + if _, ok := a[0].(float64); !ok { + goto check_4 + } + return Overload__SWIG_11(a[0].(float64)) + } +check_4: + if argc == 1 { + return Overload__SWIG_0(a[0].(string)) + } + if argc == 2 { + if _, ok := a[0].(Klass); !ok { + goto check_6 + } + if _, ok := a[1].(Klass); !ok { + goto check_6 + } + return Overload__SWIG_9(a[0].(Klass), a[1].(Klass)) + } +check_6: + if argc == 2 { + if _, ok := a[0].(Klass); !ok { + goto check_7 + } + if _, ok := a[1].(string); !ok { + goto check_7 + } + return Overload__SWIG_10(a[0].(Klass), a[1].(string)) + } +check_7: + if argc == 2 { + if _, ok := a[0].(int); !ok { + goto check_8 + } + if _, ok := a[1].(int); !ok { + goto check_8 + } + return Overload__SWIG_6(a[0].(int), a[1].(int)) + } +check_8: + if argc == 2 { + if _, ok := a[0].(int); !ok { + goto check_9 + } + if _, ok := a[1].(string); !ok { + goto check_9 + } + return Overload__SWIG_7(a[0].(int), a[1].(string)) + } +check_9: + if argc == 2 { + if _, ok := a[1].(float64); !ok { + goto check_10 + } + return Overload__SWIG_12(a[0].(float64), a[1].(float64)) + } +check_10: + if argc == 2 { + return Overload__SWIG_13(a[0].(float64), a[1].(string)) + } + panic("No match for overloaded function call") +} + +var _wrap_nsoverload__SWIG_0 unsafe.Pointer + +func Nsoverload__SWIG_0(arg1 string) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_nsoverload__SWIG_0, _swig_p) + return +} +var _wrap_nsoverload__SWIG_4 unsafe.Pointer + +func Nsoverload__SWIG_4() (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_nsoverload__SWIG_4, _swig_p) + return +} +var _wrap_nsoverload__SWIG_5 unsafe.Pointer + +func Nsoverload__SWIG_5(arg1 int) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_nsoverload__SWIG_5, _swig_p) + return +} +var _wrap_nsoverload__SWIG_6 unsafe.Pointer + +func Nsoverload__SWIG_6(arg1 int, arg2 int) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_nsoverload__SWIG_6, _swig_p) + return +} +var _wrap_nsoverload__SWIG_7 unsafe.Pointer + +func Nsoverload__SWIG_7(arg1 int, arg2 string) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_nsoverload__SWIG_7, _swig_p) + return +} +var _wrap_nsoverload__SWIG_8 unsafe.Pointer + +func _swig_wrap_nsoverload__SWIG_8(base uintptr) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_nsoverload__SWIG_8, _swig_p) + return +} + +func Nsoverload__SWIG_8(arg1 Klass) (_swig_ret int) { + return _swig_wrap_nsoverload__SWIG_8(arg1.Swigcptr()) +} + +var _wrap_nsoverload__SWIG_9 unsafe.Pointer + +func _swig_wrap_nsoverload__SWIG_9(base uintptr, _ uintptr) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_nsoverload__SWIG_9, _swig_p) + return +} + +func Nsoverload__SWIG_9(arg1 Klass, arg2 Klass) (_swig_ret int) { + return _swig_wrap_nsoverload__SWIG_9(arg1.Swigcptr(), arg2.Swigcptr()) +} + +var _wrap_nsoverload__SWIG_10 unsafe.Pointer + +func _swig_wrap_nsoverload__SWIG_10(base uintptr, _ string) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_nsoverload__SWIG_10, _swig_p) + return +} + +func Nsoverload__SWIG_10(arg1 Klass, arg2 string) (_swig_ret int) { + return _swig_wrap_nsoverload__SWIG_10(arg1.Swigcptr(), arg2) +} + +var _wrap_nsoverload__SWIG_11 unsafe.Pointer + +func Nsoverload__SWIG_11(arg1 float64) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_nsoverload__SWIG_11, _swig_p) + return +} +var _wrap_nsoverload__SWIG_12 unsafe.Pointer + +func Nsoverload__SWIG_12(arg1 float64, arg2 float64) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_nsoverload__SWIG_12, _swig_p) + return +} +var _wrap_nsoverload__SWIG_13 unsafe.Pointer + +func Nsoverload__SWIG_13(arg1 float64, arg2 string) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_nsoverload__SWIG_13, _swig_p) + return +} +func Nsoverload(a ...interface{}) int { + argc := len(a) + if argc == 0 { + return Nsoverload__SWIG_4() + } + if argc == 1 { + if _, ok := a[0].(Klass); !ok { + goto check_2 + } + return Nsoverload__SWIG_8(a[0].(Klass)) + } +check_2: + if argc == 1 { + if _, ok := a[0].(int); !ok { + goto check_3 + } + return Nsoverload__SWIG_5(a[0].(int)) + } +check_3: + if argc == 1 { + if _, ok := a[0].(float64); !ok { + goto check_4 + } + return Nsoverload__SWIG_11(a[0].(float64)) + } +check_4: + if argc == 1 { + return Nsoverload__SWIG_0(a[0].(string)) + } + if argc == 2 { + if _, ok := a[0].(Klass); !ok { + goto check_6 + } + if _, ok := a[1].(Klass); !ok { + goto check_6 + } + return Nsoverload__SWIG_9(a[0].(Klass), a[1].(Klass)) + } +check_6: + if argc == 2 { + if _, ok := a[0].(Klass); !ok { + goto check_7 + } + if _, ok := a[1].(string); !ok { + goto check_7 + } + return Nsoverload__SWIG_10(a[0].(Klass), a[1].(string)) + } +check_7: + if argc == 2 { + if _, ok := a[0].(int); !ok { + goto check_8 + } + if _, ok := a[1].(int); !ok { + goto check_8 + } + return Nsoverload__SWIG_6(a[0].(int), a[1].(int)) + } +check_8: + if argc == 2 { + if _, ok := a[0].(int); !ok { + goto check_9 + } + if _, ok := a[1].(string); !ok { + goto check_9 + } + return Nsoverload__SWIG_7(a[0].(int), a[1].(string)) + } +check_9: + if argc == 2 { + if _, ok := a[1].(float64); !ok { + goto check_10 + } + return Nsoverload__SWIG_12(a[0].(float64), a[1].(float64)) + } +check_10: + if argc == 2 { + return Nsoverload__SWIG_13(a[0].(float64), a[1].(string)) + } + panic("No match for overloaded function call") +} + +type SwigcptrA uintptr + +func (p SwigcptrA) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrA) SwigIsA() { +} + +var _wrap_A_foo__SWIG_0 unsafe.Pointer + +func _swig_wrap_A_foo__SWIG_0(base float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_A_foo__SWIG_0, _swig_p) + return +} + +func AFoo__SWIG_0(arg1 float64) { + _swig_wrap_A_foo__SWIG_0(arg1) +} + +var _wrap_A_foo__SWIG_1 unsafe.Pointer + +func _swig_wrap_A_foo__SWIG_1(base int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_A_foo__SWIG_1, _swig_p) + return +} + +func AFoo__SWIG_1(arg1 int) { + _swig_wrap_A_foo__SWIG_1(arg1) +} + +var _wrap_A_foo__SWIG_2 unsafe.Pointer + +func _swig_wrap_A_foo__SWIG_2(base byte) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_A_foo__SWIG_2, _swig_p) + return +} + +func AFoo__SWIG_2(arg1 byte) { + _swig_wrap_A_foo__SWIG_2(arg1) +} + +func AFoo(a ...interface{}) { + argc := len(a) + if argc == 1 { + if _, ok := a[0].(int); !ok { + goto check_1 + } + AFoo__SWIG_1(a[0].(int)) + return + } +check_1: + if argc == 1 { + if _, ok := a[0].(float64); !ok { + goto check_2 + } + AFoo__SWIG_0(a[0].(float64)) + return + } +check_2: + if argc == 1 { + AFoo__SWIG_2(a[0].(byte)) + return + } + panic("No match for overloaded function call") +} + +var _wrap_new_A unsafe.Pointer + +func _swig_wrap_new_A() (base SwigcptrA) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_A, _swig_p) + return +} + +func NewA() (_swig_ret A) { + return _swig_wrap_new_A() +} + +var _wrap_delete_A unsafe.Pointer + +func _swig_wrap_delete_A(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_A, _swig_p) + return +} + +func DeleteA(arg1 A) { + _swig_wrap_delete_A(arg1.Swigcptr()) +} + +type A interface { + Swigcptr() uintptr + SwigIsA() +} + +type SwigcptrB uintptr + +func (p SwigcptrB) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrB) SwigIsB() { +} + +var _wrap_B_foo__SWIG_0 unsafe.Pointer + +func _swig_wrap_B_foo__SWIG_0(base SwigcptrB, _ float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_B_foo__SWIG_0, _swig_p) + return +} + +func (arg1 SwigcptrB) Foo__SWIG_0(arg2 float64) { + _swig_wrap_B_foo__SWIG_0(arg1, arg2) +} + +var _wrap_B_foo__SWIG_1 unsafe.Pointer + +func _swig_wrap_B_foo__SWIG_1(base SwigcptrB, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_B_foo__SWIG_1, _swig_p) + return +} + +func (arg1 SwigcptrB) Foo__SWIG_1(arg2 int) { + _swig_wrap_B_foo__SWIG_1(arg1, arg2) +} + +var _wrap_B_foo__SWIG_2 unsafe.Pointer + +func _swig_wrap_B_foo__SWIG_2(base SwigcptrB, _ byte) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_B_foo__SWIG_2, _swig_p) + return +} + +func (arg1 SwigcptrB) Foo__SWIG_2(arg2 byte) { + _swig_wrap_B_foo__SWIG_2(arg1, arg2) +} + +func (p SwigcptrB) Foo(a ...interface{}) { + argc := len(a) + if argc == 1 { + if _, ok := a[0].(int); !ok { + goto check_1 + } + p.Foo__SWIG_1(a[0].(int)) + return + } +check_1: + if argc == 1 { + if _, ok := a[0].(float64); !ok { + goto check_2 + } + p.Foo__SWIG_0(a[0].(float64)) + return + } +check_2: + if argc == 1 { + p.Foo__SWIG_2(a[0].(byte)) + return + } + panic("No match for overloaded function call") +} + +var _wrap_new_B unsafe.Pointer + +func _swig_wrap_new_B() (base SwigcptrB) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_B, _swig_p) + return +} + +func NewB() (_swig_ret B) { + return _swig_wrap_new_B() +} + +var _wrap_delete_B unsafe.Pointer + +func _swig_wrap_delete_B(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_B, _swig_p) + return +} + +func DeleteB(arg1 B) { + _swig_wrap_delete_B(arg1.Swigcptr()) +} + +type B interface { + Swigcptr() uintptr + SwigIsB() + Foo(a ...interface{}) +} + +type SwigcptrBar_d uintptr + +func (p SwigcptrBar_d) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrBar_d) SwigIsBar_d() { +} + +var _wrap_Bar_d_foo__SWIG_0 unsafe.Pointer + +func _swig_wrap_Bar_d_foo__SWIG_0(base SwigcptrBar_d, _ float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Bar_d_foo__SWIG_0, _swig_p) + return +} + +func (arg1 SwigcptrBar_d) Foo__SWIG_0(arg2 float64) { + _swig_wrap_Bar_d_foo__SWIG_0(arg1, arg2) +} + +var _wrap_Bar_d_foo__SWIG_1 unsafe.Pointer + +func _swig_wrap_Bar_d_foo__SWIG_1(base SwigcptrBar_d, _ float64, _ float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Bar_d_foo__SWIG_1, _swig_p) + return +} + +func (arg1 SwigcptrBar_d) Foo__SWIG_1(arg2 float64, arg3 float64) { + _swig_wrap_Bar_d_foo__SWIG_1(arg1, arg2, arg3) +} + +var _wrap_Bar_d_foo__SWIG_2 unsafe.Pointer + +func _swig_wrap_Bar_d_foo__SWIG_2(base SwigcptrBar_d, _ int, _ int, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Bar_d_foo__SWIG_2, _swig_p) + return +} + +func (arg1 SwigcptrBar_d) Foo__SWIG_2(arg2 int, arg3 int, arg4 int) { + _swig_wrap_Bar_d_foo__SWIG_2(arg1, arg2, arg3, arg4) +} + +func (p SwigcptrBar_d) Foo(a ...interface{}) { + argc := len(a) + if argc == 1 { + p.Foo__SWIG_0(a[0].(float64)) + return + } + if argc == 2 { + p.Foo__SWIG_1(a[0].(float64), a[1].(float64)) + return + } + if argc == 3 { + p.Foo__SWIG_2(a[0].(int), a[1].(int), a[2].(int)) + return + } + panic("No match for overloaded function call") +} + +var _wrap_new_Bar_d unsafe.Pointer + +func _swig_wrap_new_Bar_d() (base SwigcptrBar_d) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Bar_d, _swig_p) + return +} + +func NewBar_d() (_swig_ret Bar_d) { + return _swig_wrap_new_Bar_d() +} + +var _wrap_delete_Bar_d unsafe.Pointer + +func _swig_wrap_delete_Bar_d(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Bar_d, _swig_p) + return +} + +func DeleteBar_d(arg1 Bar_d) { + _swig_wrap_delete_Bar_d(arg1.Swigcptr()) +} + +type Bar_d interface { + Swigcptr() uintptr + SwigIsBar_d() + Foo(a ...interface{}) +} + +type SwigcptrFoo_d uintptr + +func (p SwigcptrFoo_d) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrFoo_d) SwigIsFoo_d() { +} + +var _wrap_Foo_d_bar__SWIG_0 unsafe.Pointer + +func _swig_wrap_Foo_d_bar__SWIG_0(base SwigcptrFoo_d, _ float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_d_bar__SWIG_0, _swig_p) + return +} + +func (arg1 SwigcptrFoo_d) Bar__SWIG_0(arg2 float64) { + _swig_wrap_Foo_d_bar__SWIG_0(arg1, arg2) +} + +var _wrap_Foo_d_bar__SWIG_1 unsafe.Pointer + +func _swig_wrap_Foo_d_bar__SWIG_1(base SwigcptrFoo_d, _ float64, _ float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_d_bar__SWIG_1, _swig_p) + return +} + +func (arg1 SwigcptrFoo_d) Bar__SWIG_1(arg2 float64, arg3 float64) { + _swig_wrap_Foo_d_bar__SWIG_1(arg1, arg2, arg3) +} + +var _wrap_Foo_d_bar__SWIG_2 unsafe.Pointer + +func _swig_wrap_Foo_d_bar__SWIG_2(base SwigcptrFoo_d, _ int, _ int, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_d_bar__SWIG_2, _swig_p) + return +} + +func (arg1 SwigcptrFoo_d) Bar__SWIG_2(arg2 int, arg3 int, arg4 int) { + _swig_wrap_Foo_d_bar__SWIG_2(arg1, arg2, arg3, arg4) +} + +func (p SwigcptrFoo_d) Bar(a ...interface{}) { + argc := len(a) + if argc == 1 { + p.Bar__SWIG_0(a[0].(float64)) + return + } + if argc == 2 { + p.Bar__SWIG_1(a[0].(float64), a[1].(float64)) + return + } + if argc == 3 { + p.Bar__SWIG_2(a[0].(int), a[1].(int), a[2].(int)) + return + } + panic("No match for overloaded function call") +} + +var _wrap_new_Foo_d unsafe.Pointer + +func _swig_wrap_new_Foo_d() (base SwigcptrFoo_d) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Foo_d, _swig_p) + return +} + +func NewFoo_d() (_swig_ret Foo_d) { + return _swig_wrap_new_Foo_d() +} + +var _wrap_delete_Foo_d unsafe.Pointer + +func _swig_wrap_delete_Foo_d(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Foo_d, _swig_p) + return +} + +func DeleteFoo_d(arg1 Foo_d) { + _swig_wrap_delete_Foo_d(arg1.Swigcptr()) +} + +type Foo_d interface { + Swigcptr() uintptr + SwigIsFoo_d() + Bar(a ...interface{}) +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/overload_template_fast_runme b/Examples/test-suite/go/overload_template_fast_runme new file mode 100755 index 000000000..d74cd0045 Binary files /dev/null and b/Examples/test-suite/go/overload_template_fast_runme differ diff --git a/Examples/test-suite/go/overload_template_runme b/Examples/test-suite/go/overload_template_runme new file mode 100755 index 000000000..1d20b2fce Binary files /dev/null and b/Examples/test-suite/go/overload_template_runme differ diff --git a/Examples/test-suite/go/packageoption_a.go b/Examples/test-suite/go/packageoption_a.go new file mode 100644 index 000000000..a949eed62 --- /dev/null +++ b/Examples/test-suite/go/packageoption_a.go @@ -0,0 +1,152 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../packageoption_a.i + +package packageoption_a + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrA uintptr + +func (p SwigcptrA) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrA) SwigIsA() { +} + +var _wrap_A_testInt unsafe.Pointer + +func _swig_wrap_A_testInt(base SwigcptrA) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_A_testInt, _swig_p) + return +} + +func (arg1 SwigcptrA) TestInt() (_swig_ret int) { + return _swig_wrap_A_testInt(arg1) +} + +var _wrap_new_A unsafe.Pointer + +func _swig_wrap_new_A() (base SwigcptrA) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_A, _swig_p) + return +} + +func NewA() (_swig_ret A) { + return _swig_wrap_new_A() +} + +var _wrap_delete_A unsafe.Pointer + +func _swig_wrap_delete_A(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_A, _swig_p) + return +} + +func DeleteA(arg1 A) { + _swig_wrap_delete_A(arg1.Swigcptr()) +} + +type A interface { + Swigcptr() uintptr + SwigIsA() + TestInt() (_swig_ret int) +} + +type SwigcptrBase uintptr + +func (p SwigcptrBase) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrBase) SwigIsBase() { +} + +var _wrap_Base_vmethod unsafe.Pointer + +func _swig_wrap_Base_vmethod(base SwigcptrBase) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Base_vmethod, _swig_p) + return +} + +func (arg1 SwigcptrBase) Vmethod() (_swig_ret int) { + return _swig_wrap_Base_vmethod(arg1) +} + +var _wrap_Base_basemethod unsafe.Pointer + +func _swig_wrap_Base_basemethod(base SwigcptrBase) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Base_basemethod, _swig_p) + return +} + +func (arg1 SwigcptrBase) Basemethod() (_swig_ret int) { + return _swig_wrap_Base_basemethod(arg1) +} + +var _wrap_delete_Base unsafe.Pointer + +func _swig_wrap_delete_Base(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Base, _swig_p) + return +} + +func DeleteBase(arg1 Base) { + _swig_wrap_delete_Base(arg1.Swigcptr()) +} + +var _wrap_new_Base unsafe.Pointer + +func _swig_wrap_new_Base() (base SwigcptrBase) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Base, _swig_p) + return +} + +func NewBase() (_swig_ret Base) { + return _swig_wrap_new_Base() +} + +type Base interface { + Swigcptr() uintptr + SwigIsBase() + Vmethod() (_swig_ret int) + Basemethod() (_swig_ret int) +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/packageoption_b.go b/Examples/test-suite/go/packageoption_b.go new file mode 100644 index 000000000..6c86df625 --- /dev/null +++ b/Examples/test-suite/go/packageoption_b.go @@ -0,0 +1,88 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../packageoption_b.i + +package packageoption_b + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrB uintptr + +func (p SwigcptrB) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrB) SwigIsB() { +} + +var _wrap_B_testInt unsafe.Pointer + +func _swig_wrap_B_testInt(base SwigcptrB) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_B_testInt, _swig_p) + return +} + +func (arg1 SwigcptrB) TestInt() (_swig_ret int) { + return _swig_wrap_B_testInt(arg1) +} + +var _wrap_new_B unsafe.Pointer + +func _swig_wrap_new_B() (base SwigcptrB) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_B, _swig_p) + return +} + +func NewB() (_swig_ret B) { + return _swig_wrap_new_B() +} + +var _wrap_delete_B unsafe.Pointer + +func _swig_wrap_delete_B(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_B, _swig_p) + return +} + +func DeleteB(arg1 B) { + _swig_wrap_delete_B(arg1.Swigcptr()) +} + +type B interface { + Swigcptr() uintptr + SwigIsB() + TestInt() (_swig_ret int) +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/packageoption_c.go b/Examples/test-suite/go/packageoption_c.go new file mode 100644 index 000000000..21a9f09f1 --- /dev/null +++ b/Examples/test-suite/go/packageoption_c.go @@ -0,0 +1,111 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../packageoption_c.i + +package packageoption_c + +import "unsafe" +import _ "runtime/cgo" +import "packageoption_a" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrDerived uintptr + +func (p SwigcptrDerived) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrDerived) SwigIsDerived() { +} + +var _wrap_Derived_vmethod unsafe.Pointer + +func _swig_wrap_Derived_vmethod(base SwigcptrDerived) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Derived_vmethod, _swig_p) + return +} + +func (arg1 SwigcptrDerived) Vmethod() (_swig_ret int) { + return _swig_wrap_Derived_vmethod(arg1) +} + +var _wrap_delete_Derived unsafe.Pointer + +func _swig_wrap_delete_Derived(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Derived, _swig_p) + return +} + +func DeleteDerived(arg1 Derived) { + _swig_wrap_delete_Derived(arg1.Swigcptr()) +} + +var _wrap_new_Derived unsafe.Pointer + +func _swig_wrap_new_Derived() (base SwigcptrDerived) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Derived, _swig_p) + return +} + +func NewDerived() (_swig_ret Derived) { + return _swig_wrap_new_Derived() +} + +var _wrap_Derived_basemethod unsafe.Pointer + +func _swig_wrap_Derived_basemethod(base SwigcptrDerived) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Derived_basemethod, _swig_p) + return +} + +func (_swig_base SwigcptrDerived) Basemethod() (_swig_ret int) { + return _swig_wrap_Derived_basemethod(_swig_base) +} + +func (p SwigcptrDerived) SwigIsBase() { +} + +func (p SwigcptrDerived) SwigGetBase() packageoption_a.Base { + return packageoption_a.SwigcptrBase(p.Swigcptr()) +} + +type Derived interface { + Swigcptr() uintptr + SwigIsDerived() + Vmethod() (_swig_ret int) + Basemethod() (_swig_ret int) + SwigIsBase() + SwigGetBase() packageoption_a.Base +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/pointer_reference.go b/Examples/test-suite/go/pointer_reference.go new file mode 100644 index 000000000..638599f52 --- /dev/null +++ b/Examples/test-suite/go/pointer_reference.go @@ -0,0 +1,219 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../pointer_reference.i + +package pointer_reference + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +var _wrap_foo unsafe.Pointer + +func _swig_wrap_foo(base **int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_foo, _swig_p) + return +} + +func Foo(arg1 **int) { + _swig_wrap_foo(arg1) +} + +type SwigcptrStruct uintptr + +func (p SwigcptrStruct) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrStruct) SwigIsStruct() { +} + +var _wrap_Struct_value_set unsafe.Pointer + +func _swig_wrap_Struct_value_set(base SwigcptrStruct, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Struct_value_set, _swig_p) + return +} + +func (arg1 SwigcptrStruct) SetValue(arg2 int) { + _swig_wrap_Struct_value_set(arg1, arg2) +} + +var _wrap_Struct_value_get unsafe.Pointer + +func _swig_wrap_Struct_value_get(base SwigcptrStruct) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Struct_value_get, _swig_p) + return +} + +func (arg1 SwigcptrStruct) GetValue() (_swig_ret int) { + return _swig_wrap_Struct_value_get(arg1) +} + +var _wrap_new_Struct unsafe.Pointer + +func _swig_wrap_new_Struct(base int) (_ SwigcptrStruct) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Struct, _swig_p) + return +} + +func NewStruct(arg1 int) (_swig_ret Struct) { + return _swig_wrap_new_Struct(arg1) +} + +var _wrap_Struct_instance_set unsafe.Pointer + +func _swig_wrap_Struct_instance_set(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Struct_instance_set, _swig_p) + return +} + +func SetStructInstance(arg1 Struct) { + _swig_wrap_Struct_instance_set(arg1.Swigcptr()) +} + +var _wrap_Struct_instance_get unsafe.Pointer + +func _swig_wrap_Struct_instance_get() (base SwigcptrStruct) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Struct_instance_get, _swig_p) + return +} + +func GetStructInstance() (_swig_ret Struct) { + return _swig_wrap_Struct_instance_get() +} + +var _wrap_Struct_pInstance_set unsafe.Pointer + +func _swig_wrap_Struct_pInstance_set(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Struct_pInstance_set, _swig_p) + return +} + +func SetStructPInstance(arg1 Struct) { + _swig_wrap_Struct_pInstance_set(arg1.Swigcptr()) +} + +var _wrap_Struct_pInstance_get unsafe.Pointer + +func _swig_wrap_Struct_pInstance_get() (base SwigcptrStruct) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Struct_pInstance_get, _swig_p) + return +} + +func GetStructPInstance() (_swig_ret Struct) { + return _swig_wrap_Struct_pInstance_get() +} + +var _wrap_delete_Struct unsafe.Pointer + +func _swig_wrap_delete_Struct(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Struct, _swig_p) + return +} + +func DeleteStruct(arg1 Struct) { + _swig_wrap_delete_Struct(arg1.Swigcptr()) +} + +type Struct interface { + Swigcptr() uintptr + SwigIsStruct() + SetValue(arg2 int) + GetValue() (_swig_ret int) +} + +var _wrap_set unsafe.Pointer + +func _swig_wrap_set(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_set, _swig_p) + return +} + +func Set(arg1 Struct) { + _swig_wrap_set(arg1.Swigcptr()) +} + +var _wrap_get unsafe.Pointer + +func _swig_wrap_get() (base SwigcptrStruct) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_get, _swig_p) + return +} + +func Get() (_swig_ret Struct) { + return _swig_wrap_get() +} + +var _wrap_overloading__SWIG_0 unsafe.Pointer + +func Overloading__SWIG_0(arg1 int) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_overloading__SWIG_0, _swig_p) + return +} +var _wrap_overloading__SWIG_1 unsafe.Pointer + +func _swig_wrap_overloading__SWIG_1(base uintptr) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_overloading__SWIG_1, _swig_p) + return +} + +func Overloading__SWIG_1(arg1 Struct) (_swig_ret int) { + return _swig_wrap_overloading__SWIG_1(arg1.Swigcptr()) +} + +func Overloading(a ...interface{}) int { + argc := len(a) + if argc == 1 { + if _, ok := a[0].(Struct); !ok { + goto check_1 + } + return Overloading__SWIG_1(a[0].(Struct)) + } +check_1: + if argc == 1 { + return Overloading__SWIG_0(a[0].(int)) + } + panic("No match for overloaded function call") +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/preproc.go b/Examples/test-suite/go/preproc.go new file mode 100644 index 000000000..1b0c0a389 --- /dev/null +++ b/Examples/test-suite/go/preproc.go @@ -0,0 +1,403 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../preproc.i + +package preproc + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +const SLASHSLASH string = "//" +var _wrap_hello0 unsafe.Pointer + +func Hello0() (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_hello0, _swig_p) + return +} +var _wrap_hello1 unsafe.Pointer + +func Hello1() (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_hello1, _swig_p) + return +} +var _wrap_hello2 unsafe.Pointer + +func Hello2() (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_hello2, _swig_p) + return +} +var _wrap_f unsafe.Pointer + +func F(arg1 int) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_f, _swig_p) + return +} +const A5 string = "helloworld" +const B5 int = 3+4 +var _wrap_c5 unsafe.Pointer + +func _swig_getc5() (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_c5, _swig_p) + return +} +var C5 int = _swig_getc5() +const D5 int = 123 +const C1 string = "hello" +const ALONG_NAME int = 42 +const C4 string = "Hello" +var _wrap_a6 unsafe.Pointer + +func _swig_geta6() (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_a6, _swig_p) + return +} +var A6 int = _swig_geta6() +var _wrap_b6 unsafe.Pointer + +func _swig_getb6() (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_b6, _swig_p) + return +} +var B6 int = _swig_getb6() +var _wrap_c6 unsafe.Pointer + +func _swig_getc6() (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_c6, _swig_p) + return +} +var C6 int = _swig_getc6() +var _wrap_d6 unsafe.Pointer + +func _swig_getd6() (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_d6, _swig_p) + return +} +var D6 int = _swig_getd6() +type SwigcptrEmbeddedDefines uintptr + +func (p SwigcptrEmbeddedDefines) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrEmbeddedDefines) SwigIsEmbeddedDefines() { +} + +var _wrap_EmbeddedDefines_dummy_set unsafe.Pointer + +func _swig_wrap_EmbeddedDefines_dummy_set(base SwigcptrEmbeddedDefines, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_EmbeddedDefines_dummy_set, _swig_p) + return +} + +func (arg1 SwigcptrEmbeddedDefines) SetDummy(arg2 int) { + _swig_wrap_EmbeddedDefines_dummy_set(arg1, arg2) +} + +var _wrap_EmbeddedDefines_dummy_get unsafe.Pointer + +func _swig_wrap_EmbeddedDefines_dummy_get(base SwigcptrEmbeddedDefines) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_EmbeddedDefines_dummy_get, _swig_p) + return +} + +func (arg1 SwigcptrEmbeddedDefines) GetDummy() (_swig_ret int) { + return _swig_wrap_EmbeddedDefines_dummy_get(arg1) +} + +const EMBEDDED_DEFINE int = 44 +const EMBEDDED_SWIG_CONSTANT int = 55 +var _wrap_new_EmbeddedDefines unsafe.Pointer + +func _swig_wrap_new_EmbeddedDefines() (base SwigcptrEmbeddedDefines) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_EmbeddedDefines, _swig_p) + return +} + +func NewEmbeddedDefines() (_swig_ret EmbeddedDefines) { + return _swig_wrap_new_EmbeddedDefines() +} + +var _wrap_delete_EmbeddedDefines unsafe.Pointer + +func _swig_wrap_delete_EmbeddedDefines(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_EmbeddedDefines, _swig_p) + return +} + +func DeleteEmbeddedDefines(arg1 EmbeddedDefines) { + _swig_wrap_delete_EmbeddedDefines(arg1.Swigcptr()) +} + +type EmbeddedDefines interface { + Swigcptr() uintptr + SwigIsEmbeddedDefines() + SetDummy(arg2 int) + GetDummy() (_swig_ret int) +} + +const A1 int = 1+2 +const A2 int = 3-4 +var _wrap_A3 unsafe.Pointer + +func _swig_getA3() (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_A3, _swig_p) + return +} +var A3 int = _swig_getA3() +var _wrap_A4 unsafe.Pointer + +func _swig_getA4() (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_A4, _swig_p) + return +} +var A4 int = _swig_getA4() +var _wrap_A7 unsafe.Pointer + +func _swig_getA7() (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_A7, _swig_p) + return +} +var A7 int = _swig_getA7() +var _wrap_A8 unsafe.Pointer + +func _swig_getA8() (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_A8, _swig_p) + return +} +var A8 int = _swig_getA8() +var _wrap_A9 unsafe.Pointer + +func _swig_getA9() (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_A9, _swig_p) + return +} +var A9 int = _swig_getA9() +var _wrap_A10 unsafe.Pointer + +func _swig_getA10() (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_A10, _swig_p) + return +} +var A10 int = _swig_getA10() +var _wrap_A11 unsafe.Pointer + +func _swig_getA11() (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_A11, _swig_p) + return +} +var A11 int = _swig_getA11() +var _wrap_A12 unsafe.Pointer + +func _swig_getA12() (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_A12, _swig_p) + return +} +var A12 int = _swig_getA12() +var _wrap_A13 unsafe.Pointer + +func _swig_getA13() (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_A13, _swig_p) + return +} +var A13 int = _swig_getA13() +const X__GMP_HAVE_CONST int = 0 +const X__GMP_HAVE_PROTOTYPES int = 0 +const X__GMP_HAVE_TOKEN_PASTE int = 0 +const ONE int = 1 +const One int = 1 +const Two int = 2 +const Three int = 3 +var _wrap_endif_get unsafe.Pointer + +func GetEndif() (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_endif_get, _swig_p) + return +} +var _wrap_define_get unsafe.Pointer + +func GetDefine() (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_define_get, _swig_p) + return +} +var _wrap_defined_get unsafe.Pointer + +func GetDefined() (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_defined_get, _swig_p) + return +} +var _wrap_test unsafe.Pointer + +func Test(arg1 int) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_test, _swig_p) + return +} +var _wrap_SOME_MASK_DEF unsafe.Pointer + +func _swig_getSOME_MASK_DEF() (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_SOME_MASK_DEF, _swig_p) + return +} +var SOME_MASK_DEF int = _swig_getSOME_MASK_DEF() +var _wrap_BOLTZMANN unsafe.Pointer + +func _swig_getBOLTZMANN() (_swig_ret float64) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_BOLTZMANN, _swig_p) + return +} +var BOLTZMANN float64 = _swig_getBOLTZMANN() +var _wrap_AVOGADRO unsafe.Pointer + +func _swig_getAVOGADRO() (_swig_ret float64) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_AVOGADRO, _swig_p) + return +} +var AVOGADRO float64 = _swig_getAVOGADRO() +var _wrap_RGAS unsafe.Pointer + +func _swig_getRGAS() (_swig_ret float64) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_RGAS, _swig_p) + return +} +var RGAS float64 = _swig_getRGAS() +var _wrap_RGASX unsafe.Pointer + +func _swig_getRGASX() (_swig_ret float64) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_RGASX, _swig_p) + return +} +var RGASX float64 = _swig_getRGASX() +type SwigcptrTypeNameTraits uintptr + +func (p SwigcptrTypeNameTraits) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrTypeNameTraits) SwigIsTypeNameTraits() { +} + +var _wrap_TypeNameTraits_val_set unsafe.Pointer + +func _swig_wrap_TypeNameTraits_val_set(base SwigcptrTypeNameTraits, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_TypeNameTraits_val_set, _swig_p) + return +} + +func (arg1 SwigcptrTypeNameTraits) SetVal(arg2 int) { + _swig_wrap_TypeNameTraits_val_set(arg1, arg2) +} + +var _wrap_TypeNameTraits_val_get unsafe.Pointer + +func _swig_wrap_TypeNameTraits_val_get(base SwigcptrTypeNameTraits) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_TypeNameTraits_val_get, _swig_p) + return +} + +func (arg1 SwigcptrTypeNameTraits) GetVal() (_swig_ret int) { + return _swig_wrap_TypeNameTraits_val_get(arg1) +} + +var _wrap_new_TypeNameTraits unsafe.Pointer + +func _swig_wrap_new_TypeNameTraits() (base SwigcptrTypeNameTraits) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_TypeNameTraits, _swig_p) + return +} + +func NewTypeNameTraits() (_swig_ret TypeNameTraits) { + return _swig_wrap_new_TypeNameTraits() +} + +var _wrap_delete_TypeNameTraits unsafe.Pointer + +func _swig_wrap_delete_TypeNameTraits(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_TypeNameTraits, _swig_p) + return +} + +func DeleteTypeNameTraits(arg1 TypeNameTraits) { + _swig_wrap_delete_TypeNameTraits(arg1.Swigcptr()) +} + +type TypeNameTraits interface { + Swigcptr() uintptr + SwigIsTypeNameTraits() + SetVal(arg2 int) + GetVal() (_swig_ret int) +} + +var _wrap_method unsafe.Pointer + +func _swig_wrap_method(base uintptr) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_method, _swig_p) + return +} + +func Method(arg1 TypeNameTraits) (_swig_ret int) { + return _swig_wrap_method(arg1.Swigcptr()) +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/preproc_constants.go b/Examples/test-suite/go/preproc_constants.go new file mode 100644 index 000000000..17279e3d9 --- /dev/null +++ b/Examples/test-suite/go/preproc_constants.go @@ -0,0 +1,246 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../preproc_constants.i + +package preproc_constants + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +const CONST_INT1 int = 10 +const CONST_INT2 int = 0xFF +const CONST_UINT1 uint = 10 +const CONST_UINT2 uint = 10 +const CONST_UINT3 uint = 0xFF +const CONST_UINT4 uint = 0xFF +const CONST_LONG1 int64 = 10 +const CONST_LONG2 int64 = 10 +const CONST_LONG3 int64 = 0xFF +const CONST_LONG4 int64 = 0xFF +const CONST_LLONG1 int64 = 10 +const CONST_LLONG2 int64 = 10 +const CONST_LLONG3 int64 = 0xFF +const CONST_LLONG4 int64 = 0xFF +const CONST_ULLONG1 uint64 = 10 +const CONST_ULLONG2 uint64 = 10 +const CONST_ULLONG3 uint64 = 0xFF +const CONST_ULLONG4 uint64 = 0xFF +const CONST_DOUBLE1 float64 = 10e1 +const CONST_DOUBLE2 float64 = 10E1 +const CONST_DOUBLE3 float64 = 12.3 +const CONST_DOUBLE4 float64 = 12. +const CONST_DOUBLE5 float64 = 12.3 +const CONST_DOUBLE6 float64 = 12.3 +const CONST_BOOL1 bool = true +const CONST_BOOL2 bool = false +const CONST_CHAR byte = 'x' +const CONST_STRING1 string = "const string" +const CONST_STRING2 string = "const string" +const CONST_STRING3 string = "log-revprops" +var _wrap_INT_AND_BOOL unsafe.Pointer + +func _swig_getINT_AND_BOOL() (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_INT_AND_BOOL, _swig_p) + return +} +var INT_AND_BOOL int = _swig_getINT_AND_BOOL() +var _wrap_INT_AND_INT unsafe.Pointer + +func _swig_getINT_AND_INT() (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_INT_AND_INT, _swig_p) + return +} +var INT_AND_INT int = _swig_getINT_AND_INT() +var _wrap_INT_AND_UINT unsafe.Pointer + +func _swig_getINT_AND_UINT() (_swig_ret uint) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_INT_AND_UINT, _swig_p) + return +} +var INT_AND_UINT uint = _swig_getINT_AND_UINT() +var _wrap_INT_AND_LONG unsafe.Pointer + +func _swig_getINT_AND_LONG() (_swig_ret int64) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_INT_AND_LONG, _swig_p) + return +} +var INT_AND_LONG int64 = _swig_getINT_AND_LONG() +var _wrap_INT_AND_ULONG unsafe.Pointer + +func _swig_getINT_AND_ULONG() (_swig_ret uint64) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_INT_AND_ULONG, _swig_p) + return +} +var INT_AND_ULONG uint64 = _swig_getINT_AND_ULONG() +var _wrap_INT_AND_LLONG unsafe.Pointer + +func _swig_getINT_AND_LLONG() (_swig_ret int64) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_INT_AND_LLONG, _swig_p) + return +} +var INT_AND_LLONG int64 = _swig_getINT_AND_LLONG() +var _wrap_INT_AND_ULLONG unsafe.Pointer + +func _swig_getINT_AND_ULLONG() (_swig_ret uint64) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_INT_AND_ULLONG, _swig_p) + return +} +var INT_AND_ULLONG uint64 = _swig_getINT_AND_ULLONG() +var _wrap_BOOL_AND_BOOL unsafe.Pointer + +func _swig_getBOOL_AND_BOOL() (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_BOOL_AND_BOOL, _swig_p) + return +} +var BOOL_AND_BOOL int = _swig_getBOOL_AND_BOOL() +var _wrap_EXPR_MULTIPLY unsafe.Pointer + +func _swig_getEXPR_MULTIPLY() (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_EXPR_MULTIPLY, _swig_p) + return +} +var EXPR_MULTIPLY int = _swig_getEXPR_MULTIPLY() +var _wrap_EXPR_DIVIDE unsafe.Pointer + +func _swig_getEXPR_DIVIDE() (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_EXPR_DIVIDE, _swig_p) + return +} +var EXPR_DIVIDE int = _swig_getEXPR_DIVIDE() +const EXPR_PLUS int = 0xFF+2 +const EXPR_MINUS int = 0xFF+2 +var _wrap_EXPR_LSHIFT unsafe.Pointer + +func _swig_getEXPR_LSHIFT() (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_EXPR_LSHIFT, _swig_p) + return +} +var EXPR_LSHIFT int = _swig_getEXPR_LSHIFT() +var _wrap_EXPR_RSHIFT unsafe.Pointer + +func _swig_getEXPR_RSHIFT() (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_EXPR_RSHIFT, _swig_p) + return +} +var EXPR_RSHIFT int = _swig_getEXPR_RSHIFT() +var _wrap_EXPR_LTE unsafe.Pointer + +func _swig_getEXPR_LTE() (_swig_ret bool) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_EXPR_LTE, _swig_p) + return +} +var EXPR_LTE bool = _swig_getEXPR_LTE() +var _wrap_EXPR_GTE unsafe.Pointer + +func _swig_getEXPR_GTE() (_swig_ret bool) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_EXPR_GTE, _swig_p) + return +} +var EXPR_GTE bool = _swig_getEXPR_GTE() +var _wrap_EXPR_INEQUALITY unsafe.Pointer + +func _swig_getEXPR_INEQUALITY() (_swig_ret bool) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_EXPR_INEQUALITY, _swig_p) + return +} +var EXPR_INEQUALITY bool = _swig_getEXPR_INEQUALITY() +var _wrap_EXPR_EQUALITY unsafe.Pointer + +func _swig_getEXPR_EQUALITY() (_swig_ret bool) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_EXPR_EQUALITY, _swig_p) + return +} +var EXPR_EQUALITY bool = _swig_getEXPR_EQUALITY() +var _wrap_EXPR_AND unsafe.Pointer + +func _swig_getEXPR_AND() (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_EXPR_AND, _swig_p) + return +} +var EXPR_AND int = _swig_getEXPR_AND() +var _wrap_EXPR_XOR unsafe.Pointer + +func _swig_getEXPR_XOR() (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_EXPR_XOR, _swig_p) + return +} +var EXPR_XOR int = _swig_getEXPR_XOR() +var _wrap_EXPR_OR unsafe.Pointer + +func _swig_getEXPR_OR() (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_EXPR_OR, _swig_p) + return +} +var EXPR_OR int = _swig_getEXPR_OR() +var _wrap_EXPR_LAND unsafe.Pointer + +func _swig_getEXPR_LAND() (_swig_ret bool) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_EXPR_LAND, _swig_p) + return +} +var EXPR_LAND bool = _swig_getEXPR_LAND() +var _wrap_EXPR_LOR unsafe.Pointer + +func _swig_getEXPR_LOR() (_swig_ret bool) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_EXPR_LOR, _swig_p) + return +} +var EXPR_LOR bool = _swig_getEXPR_LOR() +var _wrap_EXPR_CONDITIONAL unsafe.Pointer + +func _swig_getEXPR_CONDITIONAL() (_swig_ret float64) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_EXPR_CONDITIONAL, _swig_p) + return +} +var EXPR_CONDITIONAL float64 = _swig_getEXPR_CONDITIONAL() +type MyEnum int +var _wrap_kValue unsafe.Pointer + +func _swig_getkValue() (_swig_ret MyEnum) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_kValue, _swig_p) + return +} +var KValue MyEnum = _swig_getkValue() + diff --git a/Examples/test-suite/go/preproc_constants_c.go b/Examples/test-suite/go/preproc_constants_c.go new file mode 100644 index 000000000..5db835913 --- /dev/null +++ b/Examples/test-suite/go/preproc_constants_c.go @@ -0,0 +1,246 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../preproc_constants_c.i + +package preproc_constants_c + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +const CONST_INT1 int = 10 +const CONST_INT2 int = 0xFF +const CONST_UINT1 uint = 10 +const CONST_UINT2 uint = 10 +const CONST_UINT3 uint = 0xFF +const CONST_UINT4 uint = 0xFF +const CONST_LONG1 int64 = 10 +const CONST_LONG2 int64 = 10 +const CONST_LONG3 int64 = 0xFF +const CONST_LONG4 int64 = 0xFF +const CONST_LLONG1 int64 = 10 +const CONST_LLONG2 int64 = 10 +const CONST_LLONG3 int64 = 0xFF +const CONST_LLONG4 int64 = 0xFF +const CONST_ULLONG1 uint64 = 10 +const CONST_ULLONG2 uint64 = 10 +const CONST_ULLONG3 uint64 = 0xFF +const CONST_ULLONG4 uint64 = 0xFF +const CONST_DOUBLE1 float64 = 10e1 +const CONST_DOUBLE2 float64 = 10E1 +const CONST_DOUBLE3 float64 = 12.3 +const CONST_DOUBLE4 float64 = 12. +const CONST_DOUBLE5 float64 = 12.3 +const CONST_DOUBLE6 float64 = 12.3 +const CONST_BOOL1 int = 1 +const CONST_BOOL2 int = 0 +const CONST_CHAR byte = 'x' +const CONST_STRING1 string = "const string" +const CONST_STRING2 string = "const string" +const CONST_STRING3 string = "log-revprops" +var _wrap_INT_AND_BOOL unsafe.Pointer + +func _swig_getINT_AND_BOOL() (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_INT_AND_BOOL, _swig_p) + return +} +var INT_AND_BOOL int = _swig_getINT_AND_BOOL() +var _wrap_INT_AND_INT unsafe.Pointer + +func _swig_getINT_AND_INT() (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_INT_AND_INT, _swig_p) + return +} +var INT_AND_INT int = _swig_getINT_AND_INT() +var _wrap_INT_AND_UINT unsafe.Pointer + +func _swig_getINT_AND_UINT() (_swig_ret uint) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_INT_AND_UINT, _swig_p) + return +} +var INT_AND_UINT uint = _swig_getINT_AND_UINT() +var _wrap_INT_AND_LONG unsafe.Pointer + +func _swig_getINT_AND_LONG() (_swig_ret int64) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_INT_AND_LONG, _swig_p) + return +} +var INT_AND_LONG int64 = _swig_getINT_AND_LONG() +var _wrap_INT_AND_ULONG unsafe.Pointer + +func _swig_getINT_AND_ULONG() (_swig_ret uint64) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_INT_AND_ULONG, _swig_p) + return +} +var INT_AND_ULONG uint64 = _swig_getINT_AND_ULONG() +var _wrap_INT_AND_LLONG unsafe.Pointer + +func _swig_getINT_AND_LLONG() (_swig_ret int64) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_INT_AND_LLONG, _swig_p) + return +} +var INT_AND_LLONG int64 = _swig_getINT_AND_LLONG() +var _wrap_INT_AND_ULLONG unsafe.Pointer + +func _swig_getINT_AND_ULLONG() (_swig_ret uint64) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_INT_AND_ULLONG, _swig_p) + return +} +var INT_AND_ULLONG uint64 = _swig_getINT_AND_ULLONG() +var _wrap_BOOL_AND_BOOL unsafe.Pointer + +func _swig_getBOOL_AND_BOOL() (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_BOOL_AND_BOOL, _swig_p) + return +} +var BOOL_AND_BOOL int = _swig_getBOOL_AND_BOOL() +var _wrap_EXPR_MULTIPLY unsafe.Pointer + +func _swig_getEXPR_MULTIPLY() (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_EXPR_MULTIPLY, _swig_p) + return +} +var EXPR_MULTIPLY int = _swig_getEXPR_MULTIPLY() +var _wrap_EXPR_DIVIDE unsafe.Pointer + +func _swig_getEXPR_DIVIDE() (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_EXPR_DIVIDE, _swig_p) + return +} +var EXPR_DIVIDE int = _swig_getEXPR_DIVIDE() +const EXPR_PLUS int = 0xFF+2 +const EXPR_MINUS int = 0xFF+2 +var _wrap_EXPR_LSHIFT unsafe.Pointer + +func _swig_getEXPR_LSHIFT() (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_EXPR_LSHIFT, _swig_p) + return +} +var EXPR_LSHIFT int = _swig_getEXPR_LSHIFT() +var _wrap_EXPR_RSHIFT unsafe.Pointer + +func _swig_getEXPR_RSHIFT() (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_EXPR_RSHIFT, _swig_p) + return +} +var EXPR_RSHIFT int = _swig_getEXPR_RSHIFT() +var _wrap_EXPR_LTE unsafe.Pointer + +func _swig_getEXPR_LTE() (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_EXPR_LTE, _swig_p) + return +} +var EXPR_LTE int = _swig_getEXPR_LTE() +var _wrap_EXPR_GTE unsafe.Pointer + +func _swig_getEXPR_GTE() (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_EXPR_GTE, _swig_p) + return +} +var EXPR_GTE int = _swig_getEXPR_GTE() +var _wrap_EXPR_INEQUALITY unsafe.Pointer + +func _swig_getEXPR_INEQUALITY() (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_EXPR_INEQUALITY, _swig_p) + return +} +var EXPR_INEQUALITY int = _swig_getEXPR_INEQUALITY() +var _wrap_EXPR_EQUALITY unsafe.Pointer + +func _swig_getEXPR_EQUALITY() (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_EXPR_EQUALITY, _swig_p) + return +} +var EXPR_EQUALITY int = _swig_getEXPR_EQUALITY() +var _wrap_EXPR_AND unsafe.Pointer + +func _swig_getEXPR_AND() (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_EXPR_AND, _swig_p) + return +} +var EXPR_AND int = _swig_getEXPR_AND() +var _wrap_EXPR_XOR unsafe.Pointer + +func _swig_getEXPR_XOR() (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_EXPR_XOR, _swig_p) + return +} +var EXPR_XOR int = _swig_getEXPR_XOR() +var _wrap_EXPR_OR unsafe.Pointer + +func _swig_getEXPR_OR() (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_EXPR_OR, _swig_p) + return +} +var EXPR_OR int = _swig_getEXPR_OR() +var _wrap_EXPR_LAND unsafe.Pointer + +func _swig_getEXPR_LAND() (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_EXPR_LAND, _swig_p) + return +} +var EXPR_LAND int = _swig_getEXPR_LAND() +var _wrap_EXPR_LOR unsafe.Pointer + +func _swig_getEXPR_LOR() (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_EXPR_LOR, _swig_p) + return +} +var EXPR_LOR int = _swig_getEXPR_LOR() +var _wrap_EXPR_CONDITIONAL unsafe.Pointer + +func _swig_getEXPR_CONDITIONAL() (_swig_ret float64) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_EXPR_CONDITIONAL, _swig_p) + return +} +var EXPR_CONDITIONAL float64 = _swig_getEXPR_CONDITIONAL() +type Enum_SS_MyEnum int +var _wrap_kValue unsafe.Pointer + +func _swig_getkValue() (_swig_ret Enum_SS_MyEnum) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_kValue, _swig_p) + return +} +var KValue Enum_SS_MyEnum = _swig_getkValue() + diff --git a/Examples/test-suite/go/preproc_defined.go b/Examples/test-suite/go/preproc_defined.go new file mode 100644 index 000000000..442480e7d --- /dev/null +++ b/Examples/test-suite/go/preproc_defined.go @@ -0,0 +1,144 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../preproc_defined.i + +package preproc_defined + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +var _wrap_call_checking unsafe.Pointer + +func Call_checking() (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_call_checking, _swig_p) + return +} +var _wrap_thing unsafe.Pointer + +func _swig_wrap_thing(base int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_thing, _swig_p) + return +} + +func Thing(arg1 int) { + _swig_wrap_thing(arg1) +} + +var _wrap_stuff unsafe.Pointer + +func _swig_wrap_stuff(base int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_stuff, _swig_p) + return +} + +func Stuff(arg1 int) { + _swig_wrap_stuff(arg1) +} + +type SwigcptrDefined uintptr + +func (p SwigcptrDefined) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrDefined) SwigIsDefined() { +} + +var _wrap_Defined_defined_set unsafe.Pointer + +func _swig_wrap_Defined_defined_set(base SwigcptrDefined, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Defined_defined_set, _swig_p) + return +} + +func (arg1 SwigcptrDefined) SetDefined(arg2 int) { + _swig_wrap_Defined_defined_set(arg1, arg2) +} + +var _wrap_Defined_defined_get unsafe.Pointer + +func _swig_wrap_Defined_defined_get(base SwigcptrDefined) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Defined_defined_get, _swig_p) + return +} + +func (arg1 SwigcptrDefined) GetDefined() (_swig_ret int) { + return _swig_wrap_Defined_defined_get(arg1) +} + +var _wrap_new_Defined unsafe.Pointer + +func _swig_wrap_new_Defined() (base SwigcptrDefined) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Defined, _swig_p) + return +} + +func NewDefined() (_swig_ret Defined) { + return _swig_wrap_new_Defined() +} + +var _wrap_delete_Defined unsafe.Pointer + +func _swig_wrap_delete_Defined(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Defined, _swig_p) + return +} + +func DeleteDefined(arg1 Defined) { + _swig_wrap_delete_Defined(arg1.Swigcptr()) +} + +type Defined interface { + Swigcptr() uintptr + SwigIsDefined() + SetDefined(arg2 int) + GetDefined() (_swig_ret int) +} + +var _wrap_bumpf unsafe.Pointer + +func _swig_wrap_bumpf(base int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_bumpf, _swig_p) + return +} + +func Bumpf(arg1 int) { + _swig_wrap_bumpf(arg1) +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/preproc_include.go b/Examples/test-suite/go/preproc_include.go new file mode 100644 index 000000000..fd6b855f7 --- /dev/null +++ b/Examples/test-suite/go/preproc_include.go @@ -0,0 +1,84 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../preproc_include.i + +package preproc_include + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +var _wrap_multiply10 unsafe.Pointer + +func Multiply10(arg1 int) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_multiply10, _swig_p) + return +} +var _wrap_multiply20 unsafe.Pointer + +func Multiply20(arg1 int) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_multiply20, _swig_p) + return +} +const PREPROC_INCLUDE_C string = "preproc_include_c.h" +var _wrap_multiply30 unsafe.Pointer + +func Multiply30(arg1 int) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_multiply30, _swig_p) + return +} +var _wrap_multiply40 unsafe.Pointer + +func Multiply40(arg1 int) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_multiply40, _swig_p) + return +} +const INCLUDE_E string = "preproc_include_e withspace.h" +var _wrap_multiply50 unsafe.Pointer + +func Multiply50(arg1 int) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_multiply50, _swig_p) + return +} +const INCLUDE_F string = "preproc_include_f withspace.h" +var _wrap_multiply60 unsafe.Pointer + +func Multiply60(arg1 int) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_multiply60, _swig_p) + return +} +var _wrap_multiply70 unsafe.Pointer + +func Multiply70(arg1 int) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_multiply70, _swig_p) + return +} +const Const1 int = 1 +const Const2 int = 2 +const Const3 int = 3 + diff --git a/Examples/test-suite/go/preproc_line_file.go b/Examples/test-suite/go/preproc_line_file.go new file mode 100644 index 000000000..ab0fe1ea9 --- /dev/null +++ b/Examples/test-suite/go/preproc_line_file.go @@ -0,0 +1,316 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../preproc_line_file.i + +package preproc_line_file + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +const MYLINE int = 4 +const MYLINE_ADJUSTED int = 5+100 +const MYFILE string = "./../preproc_line_file.i" +const MYFILE_ADJUSTED string = "./../preproc_line_file.i.bak" +const MY_STRINGNUM_A string = "my15" +const MY_STRINGNUM_B string = "my16" +var _wrap_thing27_get unsafe.Pointer + +func GetThing27() (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_thing27_get, _swig_p) + return +} +var _wrap_thing28_get unsafe.Pointer + +func GetThing28() (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_thing28_get, _swig_p) + return +} +const MYLINE2 int = 30 +type SwigcptrSillyStruct uintptr + +func (p SwigcptrSillyStruct) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrSillyStruct) SwigIsSillyStruct() { +} + +var _wrap_SillyStruct_num_set unsafe.Pointer + +func _swig_wrap_SillyStruct_num_set(base SwigcptrSillyStruct, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_SillyStruct_num_set, _swig_p) + return +} + +func (arg1 SwigcptrSillyStruct) SetNum(arg2 int) { + _swig_wrap_SillyStruct_num_set(arg1, arg2) +} + +var _wrap_SillyStruct_num_get unsafe.Pointer + +func _swig_wrap_SillyStruct_num_get(base SwigcptrSillyStruct) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_SillyStruct_num_get, _swig_p) + return +} + +func (arg1 SwigcptrSillyStruct) GetNum() (_swig_ret int) { + return _swig_wrap_SillyStruct_num_get(arg1) +} + +var _wrap_new_SillyStruct unsafe.Pointer + +func _swig_wrap_new_SillyStruct() (base SwigcptrSillyStruct) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_SillyStruct, _swig_p) + return +} + +func NewSillyStruct() (_swig_ret SillyStruct) { + return _swig_wrap_new_SillyStruct() +} + +var _wrap_delete_SillyStruct unsafe.Pointer + +func _swig_wrap_delete_SillyStruct(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_SillyStruct, _swig_p) + return +} + +func DeleteSillyStruct(arg1 SillyStruct) { + _swig_wrap_delete_SillyStruct(arg1.Swigcptr()) +} + +type SillyStruct interface { + Swigcptr() uintptr + SwigIsSillyStruct() + SetNum(arg2 int) + GetNum() (_swig_ret int) +} + +type SwigcptrSillyMacroClass uintptr + +func (p SwigcptrSillyMacroClass) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrSillyMacroClass) SwigIsSillyMacroClass() { +} + +var _wrap_SillyMacroClass_num_set unsafe.Pointer + +func _swig_wrap_SillyMacroClass_num_set(base SwigcptrSillyMacroClass, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_SillyMacroClass_num_set, _swig_p) + return +} + +func (arg1 SwigcptrSillyMacroClass) SetNum(arg2 int) { + _swig_wrap_SillyMacroClass_num_set(arg1, arg2) +} + +var _wrap_SillyMacroClass_num_get unsafe.Pointer + +func _swig_wrap_SillyMacroClass_num_get(base SwigcptrSillyMacroClass) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_SillyMacroClass_num_get, _swig_p) + return +} + +func (arg1 SwigcptrSillyMacroClass) GetNum() (_swig_ret int) { + return _swig_wrap_SillyMacroClass_num_get(arg1) +} + +var _wrap_new_SillyMacroClass unsafe.Pointer + +func _swig_wrap_new_SillyMacroClass() (base SwigcptrSillyMacroClass) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_SillyMacroClass, _swig_p) + return +} + +func NewSillyMacroClass() (_swig_ret SillyMacroClass) { + return _swig_wrap_new_SillyMacroClass() +} + +var _wrap_delete_SillyMacroClass unsafe.Pointer + +func _swig_wrap_delete_SillyMacroClass(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_SillyMacroClass, _swig_p) + return +} + +func DeleteSillyMacroClass(arg1 SillyMacroClass) { + _swig_wrap_delete_SillyMacroClass(arg1.Swigcptr()) +} + +type SillyMacroClass interface { + Swigcptr() uintptr + SwigIsSillyMacroClass() + SetNum(arg2 int) + GetNum() (_swig_ret int) +} + +type SwigcptrSillyMultipleMacroStruct uintptr + +func (p SwigcptrSillyMultipleMacroStruct) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrSillyMultipleMacroStruct) SwigIsSillyMultipleMacroStruct() { +} + +var _wrap_SillyMultipleMacroStruct_num_set unsafe.Pointer + +func _swig_wrap_SillyMultipleMacroStruct_num_set(base SwigcptrSillyMultipleMacroStruct, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_SillyMultipleMacroStruct_num_set, _swig_p) + return +} + +func (arg1 SwigcptrSillyMultipleMacroStruct) SetNum(arg2 int) { + _swig_wrap_SillyMultipleMacroStruct_num_set(arg1, arg2) +} + +var _wrap_SillyMultipleMacroStruct_num_get unsafe.Pointer + +func _swig_wrap_SillyMultipleMacroStruct_num_get(base SwigcptrSillyMultipleMacroStruct) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_SillyMultipleMacroStruct_num_get, _swig_p) + return +} + +func (arg1 SwigcptrSillyMultipleMacroStruct) GetNum() (_swig_ret int) { + return _swig_wrap_SillyMultipleMacroStruct_num_get(arg1) +} + +var _wrap_new_SillyMultipleMacroStruct unsafe.Pointer + +func _swig_wrap_new_SillyMultipleMacroStruct() (base SwigcptrSillyMultipleMacroStruct) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_SillyMultipleMacroStruct, _swig_p) + return +} + +func NewSillyMultipleMacroStruct() (_swig_ret SillyMultipleMacroStruct) { + return _swig_wrap_new_SillyMultipleMacroStruct() +} + +var _wrap_delete_SillyMultipleMacroStruct unsafe.Pointer + +func _swig_wrap_delete_SillyMultipleMacroStruct(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_SillyMultipleMacroStruct, _swig_p) + return +} + +func DeleteSillyMultipleMacroStruct(arg1 SillyMultipleMacroStruct) { + _swig_wrap_delete_SillyMultipleMacroStruct(arg1.Swigcptr()) +} + +type SillyMultipleMacroStruct interface { + Swigcptr() uintptr + SwigIsSillyMultipleMacroStruct() + SetNum(arg2 int) + GetNum() (_swig_ret int) +} + +const INLINE_FILE string = "./../preproc_line_file.i" +const INLINE_LINE int = 87 +type SwigcptrSlash uintptr + +func (p SwigcptrSlash) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrSlash) SwigIsSlash() { +} + +var _wrap_Slash_num_set unsafe.Pointer + +func _swig_wrap_Slash_num_set(base SwigcptrSlash, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Slash_num_set, _swig_p) + return +} + +func (arg1 SwigcptrSlash) SetNum(arg2 int) { + _swig_wrap_Slash_num_set(arg1, arg2) +} + +var _wrap_Slash_num_get unsafe.Pointer + +func _swig_wrap_Slash_num_get(base SwigcptrSlash) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Slash_num_get, _swig_p) + return +} + +func (arg1 SwigcptrSlash) GetNum() (_swig_ret int) { + return _swig_wrap_Slash_num_get(arg1) +} + +var _wrap_new_Slash unsafe.Pointer + +func _swig_wrap_new_Slash() (base SwigcptrSlash) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Slash, _swig_p) + return +} + +func NewSlash() (_swig_ret Slash) { + return _swig_wrap_new_Slash() +} + +var _wrap_delete_Slash unsafe.Pointer + +func _swig_wrap_delete_Slash(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Slash, _swig_p) + return +} + +func DeleteSlash(arg1 Slash) { + _swig_wrap_delete_Slash(arg1.Swigcptr()) +} + +type Slash interface { + Swigcptr() uintptr + SwigIsSlash() + SetNum(arg2 int) + GetNum() (_swig_ret int) +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/preproc_runme b/Examples/test-suite/go/preproc_runme new file mode 100755 index 000000000..1f6e6c4dc Binary files /dev/null and b/Examples/test-suite/go/preproc_runme differ diff --git a/Examples/test-suite/go/primitive_ref.go b/Examples/test-suite/go/primitive_ref.go new file mode 100644 index 000000000..3e21da11f --- /dev/null +++ b/Examples/test-suite/go/primitive_ref.go @@ -0,0 +1,233 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../primitive_ref.i + +package primitive_ref + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +var _wrap_ref_int unsafe.Pointer + +func Ref_int(arg1 int) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_ref_int, _swig_p) + return +} +var _wrap_ref_uint unsafe.Pointer + +func Ref_uint(arg1 uint) (_swig_ret uint) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_ref_uint, _swig_p) + return +} +var _wrap_ref_short unsafe.Pointer + +func Ref_short(arg1 int16) (_swig_ret int16) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_ref_short, _swig_p) + return +} +var _wrap_ref_ushort unsafe.Pointer + +func Ref_ushort(arg1 uint16) (_swig_ret uint16) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_ref_ushort, _swig_p) + return +} +var _wrap_ref_long unsafe.Pointer + +func Ref_long(arg1 int64) (_swig_ret int64) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_ref_long, _swig_p) + return +} +var _wrap_ref_ulong unsafe.Pointer + +func Ref_ulong(arg1 uint64) (_swig_ret uint64) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_ref_ulong, _swig_p) + return +} +var _wrap_ref_schar unsafe.Pointer + +func Ref_schar(arg1 int8) (_swig_ret int8) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_ref_schar, _swig_p) + return +} +var _wrap_ref_uchar unsafe.Pointer + +func Ref_uchar(arg1 byte) (_swig_ret byte) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_ref_uchar, _swig_p) + return +} +var _wrap_ref_char unsafe.Pointer + +func Ref_char(arg1 byte) (_swig_ret byte) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_ref_char, _swig_p) + return +} +var _wrap_ref_float unsafe.Pointer + +func Ref_float(arg1 float32) (_swig_ret float32) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_ref_float, _swig_p) + return +} +var _wrap_ref_double unsafe.Pointer + +func Ref_double(arg1 float64) (_swig_ret float64) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_ref_double, _swig_p) + return +} +var _wrap_ref_bool unsafe.Pointer + +func Ref_bool(arg1 bool) (_swig_ret bool) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_ref_bool, _swig_p) + return +} +var _wrap_ref_longlong unsafe.Pointer + +func Ref_longlong(arg1 int64) (_swig_ret int64) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_ref_longlong, _swig_p) + return +} +var _wrap_ref_ulonglong unsafe.Pointer + +func Ref_ulonglong(arg1 uint64) (_swig_ret uint64) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_ref_ulonglong, _swig_p) + return +} +var _wrap_ref_over__SWIG_0 unsafe.Pointer + +func Ref_over__SWIG_0(arg1 int) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_ref_over__SWIG_0, _swig_p) + return +} +type SwigcptrA uintptr + +func (p SwigcptrA) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrA) SwigIsA() { +} + +var _wrap_A_v_set unsafe.Pointer + +func _swig_wrap_A_v_set(base SwigcptrA, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_A_v_set, _swig_p) + return +} + +func (arg1 SwigcptrA) SetV(arg2 int) { + _swig_wrap_A_v_set(arg1, arg2) +} + +var _wrap_A_v_get unsafe.Pointer + +func _swig_wrap_A_v_get(base SwigcptrA) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_A_v_get, _swig_p) + return +} + +func (arg1 SwigcptrA) GetV() (_swig_ret int) { + return _swig_wrap_A_v_get(arg1) +} + +var _wrap_new_A unsafe.Pointer + +func _swig_wrap_new_A(base int) (_ SwigcptrA) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_A, _swig_p) + return +} + +func NewA(arg1 int) (_swig_ret A) { + return _swig_wrap_new_A(arg1) +} + +var _wrap_delete_A unsafe.Pointer + +func _swig_wrap_delete_A(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_A, _swig_p) + return +} + +func DeleteA(arg1 A) { + _swig_wrap_delete_A(arg1.Swigcptr()) +} + +type A interface { + Swigcptr() uintptr + SwigIsA() + SetV(arg2 int) + GetV() (_swig_ret int) +} + +var _wrap_ref_over__SWIG_1 unsafe.Pointer + +func _swig_wrap_ref_over__SWIG_1(base uintptr) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_ref_over__SWIG_1, _swig_p) + return +} + +func Ref_over__SWIG_1(arg1 A) (_swig_ret int) { + return _swig_wrap_ref_over__SWIG_1(arg1.Swigcptr()) +} + +func Ref_over(a ...interface{}) int { + argc := len(a) + if argc == 1 { + if _, ok := a[0].(A); !ok { + goto check_1 + } + return Ref_over__SWIG_1(a[0].(A)) + } +check_1: + if argc == 1 { + return Ref_over__SWIG_0(a[0].(int)) + } + panic("No match for overloaded function call") +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/primitive_ref_runme b/Examples/test-suite/go/primitive_ref_runme new file mode 100755 index 000000000..c43b8ae5c Binary files /dev/null and b/Examples/test-suite/go/primitive_ref_runme differ diff --git a/Examples/test-suite/go/private_assign.go b/Examples/test-suite/go/private_assign.go new file mode 100644 index 000000000..a1f6fe823 --- /dev/null +++ b/Examples/test-suite/go/private_assign.go @@ -0,0 +1,190 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../private_assign.i + +package private_assign + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrFoo uintptr + +func (p SwigcptrFoo) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrFoo) SwigIsFoo() { +} + +var _wrap_Foo_bar unsafe.Pointer + +func _swig_wrap_Foo_bar(base SwigcptrFoo) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_bar, _swig_p) + return +} + +func (arg1 SwigcptrFoo) Bar() { + _swig_wrap_Foo_bar(arg1) +} + +var _wrap_new_Foo unsafe.Pointer + +func _swig_wrap_new_Foo() (base SwigcptrFoo) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Foo, _swig_p) + return +} + +func NewFoo() (_swig_ret Foo) { + return _swig_wrap_new_Foo() +} + +var _wrap_delete_Foo unsafe.Pointer + +func _swig_wrap_delete_Foo(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Foo, _swig_p) + return +} + +func DeleteFoo(arg1 Foo) { + _swig_wrap_delete_Foo(arg1.Swigcptr()) +} + +type Foo interface { + Swigcptr() uintptr + SwigIsFoo() + Bar() +} + +var _wrap_blah unsafe.Pointer + +func _swig_wrap_blah() (base SwigcptrFoo) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_blah, _swig_p) + return +} + +func Blah() (_swig_ret Foo) { + return _swig_wrap_blah() +} + +type SwigcptrBar uintptr + +func (p SwigcptrBar) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrBar) SwigIsBar() { +} + +var _wrap_new_Bar unsafe.Pointer + +func _swig_wrap_new_Bar() (base SwigcptrBar) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Bar, _swig_p) + return +} + +func NewBar() (_swig_ret Bar) { + return _swig_wrap_new_Bar() +} + +var _wrap_delete_Bar unsafe.Pointer + +func _swig_wrap_delete_Bar(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Bar, _swig_p) + return +} + +func DeleteBar(arg1 Bar) { + _swig_wrap_delete_Bar(arg1.Swigcptr()) +} + +type Bar interface { + Swigcptr() uintptr + SwigIsBar() +} + +type SwigcptrTROOT uintptr + +func (p SwigcptrTROOT) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrTROOT) SwigIsTROOT() { +} + +var _wrap_delete_TROOT unsafe.Pointer + +func _swig_wrap_delete_TROOT(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_TROOT, _swig_p) + return +} + +func DeleteTROOT(arg1 TROOT) { + _swig_wrap_delete_TROOT(arg1.Swigcptr()) +} + +type TROOT interface { + Swigcptr() uintptr + SwigIsTROOT() +} + +type SwigcptrA uintptr + +func (p SwigcptrA) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrA) SwigIsA() { +} + +var _wrap_delete_A unsafe.Pointer + +func _swig_wrap_delete_A(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_A, _swig_p) + return +} + +func DeleteA(arg1 A) { + _swig_wrap_delete_A(arg1.Swigcptr()) +} + +type A interface { + Swigcptr() uintptr + SwigIsA() +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/protected_rename.go b/Examples/test-suite/go/protected_rename.go new file mode 100644 index 000000000..e0bec854d --- /dev/null +++ b/Examples/test-suite/go/protected_rename.go @@ -0,0 +1,88 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../protected_rename.i + +package protected_rename + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrFoo uintptr + +func (p SwigcptrFoo) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrFoo) SwigIsFoo() { +} + +var _wrap_Foo_x unsafe.Pointer + +func _swig_wrap_Foo_x(base SwigcptrFoo) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_x, _swig_p) + return +} + +func (arg1 SwigcptrFoo) X() { + _swig_wrap_Foo_x(arg1) +} + +var _wrap_new_Foo unsafe.Pointer + +func _swig_wrap_new_Foo() (base SwigcptrFoo) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Foo, _swig_p) + return +} + +func NewFoo() (_swig_ret Foo) { + return _swig_wrap_new_Foo() +} + +var _wrap_delete_Foo unsafe.Pointer + +func _swig_wrap_delete_Foo(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Foo, _swig_p) + return +} + +func DeleteFoo(arg1 Foo) { + _swig_wrap_delete_Foo(arg1.Swigcptr()) +} + +type Foo interface { + Swigcptr() uintptr + SwigIsFoo() + X() +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/pure_virtual.go b/Examples/test-suite/go/pure_virtual.go new file mode 100644 index 000000000..38b9fa74c --- /dev/null +++ b/Examples/test-suite/go/pure_virtual.go @@ -0,0 +1,537 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../pure_virtual.i + +package pure_virtual + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrA uintptr + +func (p SwigcptrA) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrA) SwigIsA() { +} + +var _wrap_delete_A unsafe.Pointer + +func _swig_wrap_delete_A(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_A, _swig_p) + return +} + +func DeleteA(arg1 A) { + _swig_wrap_delete_A(arg1.Swigcptr()) +} + +var _wrap_A_something unsafe.Pointer + +func _swig_wrap_A_something(base SwigcptrA) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_A_something, _swig_p) + return +} + +func (arg1 SwigcptrA) Something() { + _swig_wrap_A_something(arg1) +} + +var _wrap_A_method unsafe.Pointer + +func _swig_wrap_A_method(base SwigcptrA) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_A_method, _swig_p) + return +} + +func (arg1 SwigcptrA) Method() { + _swig_wrap_A_method(arg1) +} + +type A interface { + Swigcptr() uintptr + SwigIsA() + Something() + Method() +} + +type SwigcptrB uintptr + +func (p SwigcptrB) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrB) SwigIsB() { +} + +var _wrap_new_B unsafe.Pointer + +func _swig_wrap_new_B() (base SwigcptrB) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_B, _swig_p) + return +} + +func NewB() (_swig_ret B) { + return _swig_wrap_new_B() +} + +var _wrap_delete_B unsafe.Pointer + +func _swig_wrap_delete_B(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_B, _swig_p) + return +} + +func DeleteB(arg1 B) { + _swig_wrap_delete_B(arg1.Swigcptr()) +} + +var _wrap_B_something unsafe.Pointer + +func _swig_wrap_B_something(base SwigcptrB) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_B_something, _swig_p) + return +} + +func (arg1 SwigcptrB) Something() { + _swig_wrap_B_something(arg1) +} + +var _wrap_B_method unsafe.Pointer + +func _swig_wrap_B_method(base SwigcptrB) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_B_method, _swig_p) + return +} + +func (arg1 SwigcptrB) Method() { + _swig_wrap_B_method(arg1) +} + +func (p SwigcptrB) SwigIsA() { +} + +func (p SwigcptrB) SwigGetA() A { + return SwigcptrA(p.Swigcptr()) +} + +type B interface { + Swigcptr() uintptr + SwigIsB() + Something() + Method() + SwigIsA() + SwigGetA() A +} + +type SwigcptrC uintptr + +func (p SwigcptrC) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrC) SwigIsC() { +} + +var _wrap_delete_C unsafe.Pointer + +func _swig_wrap_delete_C(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_C, _swig_p) + return +} + +func DeleteC(arg1 C) { + _swig_wrap_delete_C(arg1.Swigcptr()) +} + +var _wrap_C_method unsafe.Pointer + +func _swig_wrap_C_method(base SwigcptrC) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_C_method, _swig_p) + return +} + +func (arg1 SwigcptrC) Method() { + _swig_wrap_C_method(arg1) +} + +var _wrap_C_something unsafe.Pointer + +func _swig_wrap_C_something(base SwigcptrC) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_C_something, _swig_p) + return +} + +func (_swig_base SwigcptrC) Something() { + _swig_wrap_C_something(_swig_base) +} + +func (p SwigcptrC) SwigIsA() { +} + +func (p SwigcptrC) SwigGetA() A { + return SwigcptrA(p.Swigcptr()) +} + +type C interface { + Swigcptr() uintptr + SwigIsC() + Method() + Something() + SwigIsA() + SwigGetA() A +} + +type SwigcptrD uintptr + +func (p SwigcptrD) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrD) SwigIsD() { +} + +var _wrap_delete_D unsafe.Pointer + +func _swig_wrap_delete_D(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_D, _swig_p) + return +} + +func DeleteD(arg1 D) { + _swig_wrap_delete_D(arg1.Swigcptr()) +} + +var _wrap_D_something unsafe.Pointer + +func _swig_wrap_D_something(base SwigcptrD) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_D_something, _swig_p) + return +} + +func (arg1 SwigcptrD) Something() { + _swig_wrap_D_something(arg1) +} + +var _wrap_new_D unsafe.Pointer + +func _swig_wrap_new_D() (base SwigcptrD) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_D, _swig_p) + return +} + +func NewD() (_swig_ret D) { + return _swig_wrap_new_D() +} + +var _wrap_D_method unsafe.Pointer + +func _swig_wrap_D_method(base SwigcptrD) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_D_method, _swig_p) + return +} + +func (_swig_base SwigcptrD) Method() { + _swig_wrap_D_method(_swig_base) +} + +func (p SwigcptrD) SwigIsC() { +} + +func (p SwigcptrD) SwigGetC() C { + return SwigcptrC(p.Swigcptr()) +} + +func (p SwigcptrD) SwigIsA() { +} + +func (p SwigcptrD) SwigGetA() A { + return SwigcptrA(p.Swigcptr()) +} + +type D interface { + Swigcptr() uintptr + SwigIsD() + Something() + Method() + SwigIsC() + SwigGetC() C + SwigIsA() + SwigGetA() A +} + +type SwigcptrAA uintptr + +func (p SwigcptrAA) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrAA) SwigIsAA() { +} + +var _wrap_delete_AA unsafe.Pointer + +func _swig_wrap_delete_AA(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_AA, _swig_p) + return +} + +func DeleteAA(arg1 AA) { + _swig_wrap_delete_AA(arg1.Swigcptr()) +} + +var _wrap_AA_method2 unsafe.Pointer + +func _swig_wrap_AA_method2(base SwigcptrAA) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_AA_method2, _swig_p) + return +} + +func (arg1 SwigcptrAA) Method2() { + _swig_wrap_AA_method2(arg1) +} + +type AA interface { + Swigcptr() uintptr + SwigIsAA() + Method2() +} + +type SwigcptrE uintptr + +func (p SwigcptrE) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrE) SwigIsE() { +} + +var _wrap_E_something unsafe.Pointer + +func _swig_wrap_E_something(base SwigcptrE) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_E_something, _swig_p) + return +} + +func (arg1 SwigcptrE) Something() { + _swig_wrap_E_something(arg1) +} + +var _wrap_E_method unsafe.Pointer + +func _swig_wrap_E_method(base SwigcptrE) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_E_method, _swig_p) + return +} + +func (_swig_base SwigcptrE) Method() { + _swig_wrap_E_method(_swig_base) +} + +var _wrap_E_method2 unsafe.Pointer + +func _swig_wrap_E_method2(base SwigcptrE) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_E_method2, _swig_p) + return +} + +func (_swig_base SwigcptrE) Method2() { + _swig_wrap_E_method2(_swig_base) +} + +func (p SwigcptrE) SwigIsC() { +} + +func (p SwigcptrE) SwigGetC() C { + return SwigcptrC(p.Swigcptr()) +} + +func (p SwigcptrE) SwigIsA() { +} + +func (p SwigcptrE) SwigGetA() A { + return SwigcptrA(p.Swigcptr()) +} + +var _wrap_E_SwigGetAA unsafe.Pointer + +func _swig_wrap_E_SwigGetAA(base SwigcptrE) (_ SwigcptrAA) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_E_SwigGetAA, _swig_p) + return +} + +func (arg1 SwigcptrE) SwigGetAA() (_swig_ret AA) { + return _swig_wrap_E_SwigGetAA(arg1) +} + +type E interface { + Swigcptr() uintptr + SwigIsE() + Something() + Method() + Method2() + SwigIsC() + SwigGetC() C + SwigIsA() + SwigGetA() A + SwigGetAA() (_swig_ret AA) +} + +type SwigcptrF uintptr + +func (p SwigcptrF) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrF) SwigIsF() { +} + +var _wrap_F_method2 unsafe.Pointer + +func _swig_wrap_F_method2(base SwigcptrF) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_F_method2, _swig_p) + return +} + +func (arg1 SwigcptrF) Method2() { + _swig_wrap_F_method2(arg1) +} + +var _wrap_new_F unsafe.Pointer + +func _swig_wrap_new_F() (base SwigcptrF) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_F, _swig_p) + return +} + +func NewF() (_swig_ret F) { + return _swig_wrap_new_F() +} + +var _wrap_delete_F unsafe.Pointer + +func _swig_wrap_delete_F(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_F, _swig_p) + return +} + +func DeleteF(arg1 F) { + _swig_wrap_delete_F(arg1.Swigcptr()) +} + +var _wrap_F_something unsafe.Pointer + +func _swig_wrap_F_something(base SwigcptrF) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_F_something, _swig_p) + return +} + +func (_swig_base SwigcptrF) Something() { + _swig_wrap_F_something(_swig_base) +} + +var _wrap_F_method unsafe.Pointer + +func _swig_wrap_F_method(base SwigcptrF) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_F_method, _swig_p) + return +} + +func (_swig_base SwigcptrF) Method() { + _swig_wrap_F_method(_swig_base) +} + +func (p SwigcptrF) SwigIsE() { +} + +func (p SwigcptrF) SwigGetE() E { + return SwigcptrE(p.Swigcptr()) +} + +func (p SwigcptrF) SwigIsC() { +} + +func (p SwigcptrF) SwigGetC() C { + return SwigcptrC(p.Swigcptr()) +} + +func (p SwigcptrF) SwigIsA() { +} + +func (p SwigcptrF) SwigGetA() A { + return SwigcptrA(p.Swigcptr()) +} + +func (p SwigcptrF) SwigGetAA() AA { + return p.SwigGetE().SwigGetAA() +} + +type F interface { + Swigcptr() uintptr + SwigIsF() + Method2() + Something() + Method() + SwigIsE() + SwigGetE() E + SwigIsC() + SwigGetC() C + SwigIsA() + SwigGetA() A + SwigGetAA() AA +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/redefined.go b/Examples/test-suite/go/redefined.go new file mode 100644 index 000000000..3326ad380 --- /dev/null +++ b/Examples/test-suite/go/redefined.go @@ -0,0 +1,134 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../redefined.i + +package redefined + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +const Agua int = 0 +const REDUNDANT int = 1 +var _wrap_hello unsafe.Pointer + +func Hello(arg1 int) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_hello, _swig_p) + return +} +type SwigcptrA uintptr + +func (p SwigcptrA) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrA) SwigIsA() { +} + +var _wrap_foo unsafe.Pointer + +func _swig_wrap_foo(base uintptr, _ uintptr) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_foo, _swig_p) + return +} + +func Foo(arg1 A, arg2 B) (_swig_ret int) { + return _swig_wrap_foo(arg1.Swigcptr(), arg2.Swigcptr()) +} + +var _wrap_new_A unsafe.Pointer + +func _swig_wrap_new_A() (base SwigcptrA) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_A, _swig_p) + return +} + +func NewA() (_swig_ret A) { + return _swig_wrap_new_A() +} + +var _wrap_delete_A unsafe.Pointer + +func _swig_wrap_delete_A(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_A, _swig_p) + return +} + +func DeleteA(arg1 A) { + _swig_wrap_delete_A(arg1.Swigcptr()) +} + +type A interface { + Swigcptr() uintptr + SwigIsA() +} + +type SwigcptrB uintptr + +func (p SwigcptrB) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrB) SwigIsB() { +} + +var _wrap_new_B unsafe.Pointer + +func _swig_wrap_new_B() (base SwigcptrB) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_B, _swig_p) + return +} + +func NewB() (_swig_ret B) { + return _swig_wrap_new_B() +} + +var _wrap_delete_B unsafe.Pointer + +func _swig_wrap_delete_B(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_B, _swig_p) + return +} + +func DeleteB(arg1 B) { + _swig_wrap_delete_B(arg1.Swigcptr()) +} + +type B interface { + Swigcptr() uintptr + SwigIsB() +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/redefined_not.go b/Examples/test-suite/go/redefined_not.go new file mode 100644 index 000000000..73ab4b2a5 --- /dev/null +++ b/Examples/test-suite/go/redefined_not.go @@ -0,0 +1,29 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../redefined_not.i + +package redefined_not + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + + diff --git a/Examples/test-suite/go/refcount.go b/Examples/test-suite/go/refcount.go new file mode 100644 index 000000000..ddfca5b4e --- /dev/null +++ b/Examples/test-suite/go/refcount.go @@ -0,0 +1,797 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../refcount.i + +package refcount + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrRCObjBase uintptr + +func (p SwigcptrRCObjBase) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrRCObjBase) SwigIsRCObjBase() { +} + +var _wrap_RCObjBase_ref_count unsafe.Pointer + +func _swig_wrap_RCObjBase_ref_count(base SwigcptrRCObjBase) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_RCObjBase_ref_count, _swig_p) + return +} + +func (arg1 SwigcptrRCObjBase) Ref_count() (_swig_ret int) { + return _swig_wrap_RCObjBase_ref_count(arg1) +} + +var _wrap_RCObjBase_addref unsafe.Pointer + +func _swig_wrap_RCObjBase_addref(base SwigcptrRCObjBase) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_RCObjBase_addref, _swig_p) + return +} + +func (arg1 SwigcptrRCObjBase) Addref() (_swig_ret int) { + return _swig_wrap_RCObjBase_addref(arg1) +} + +var _wrap_RCObjBase_delref unsafe.Pointer + +func _swig_wrap_RCObjBase_delref(base SwigcptrRCObjBase) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_RCObjBase_delref, _swig_p) + return +} + +func (arg1 SwigcptrRCObjBase) Delref() (_swig_ret int) { + return _swig_wrap_RCObjBase_delref(arg1) +} + +type RCObjBase interface { + Swigcptr() uintptr + SwigIsRCObjBase() + Ref_count() (_swig_ret int) + Addref() (_swig_ret int) + Delref() (_swig_ret int) +} + +type SwigcptrRCObj uintptr + +func (p SwigcptrRCObj) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrRCObj) SwigIsRCObj() { +} + +var _wrap_delete_RCObj unsafe.Pointer + +func _swig_wrap_delete_RCObj(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_RCObj, _swig_p) + return +} + +func DeleteRCObj(arg1 RCObj) { + _swig_wrap_delete_RCObj(arg1.Swigcptr()) +} + +var _wrap_RCObj_ref_count unsafe.Pointer + +func _swig_wrap_RCObj_ref_count(base SwigcptrRCObj) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_RCObj_ref_count, _swig_p) + return +} + +func (_swig_base SwigcptrRCObj) Ref_count() (_swig_ret int) { + return _swig_wrap_RCObj_ref_count(_swig_base) +} + +var _wrap_RCObj_addref unsafe.Pointer + +func _swig_wrap_RCObj_addref(base SwigcptrRCObj) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_RCObj_addref, _swig_p) + return +} + +func (_swig_base SwigcptrRCObj) Addref() (_swig_ret int) { + return _swig_wrap_RCObj_addref(_swig_base) +} + +var _wrap_RCObj_delref unsafe.Pointer + +func _swig_wrap_RCObj_delref(base SwigcptrRCObj) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_RCObj_delref, _swig_p) + return +} + +func (_swig_base SwigcptrRCObj) Delref() (_swig_ret int) { + return _swig_wrap_RCObj_delref(_swig_base) +} + +func (p SwigcptrRCObj) SwigIsRCObjBase() { +} + +func (p SwigcptrRCObj) SwigGetRCObjBase() RCObjBase { + return SwigcptrRCObjBase(p.Swigcptr()) +} + +type RCObj interface { + Swigcptr() uintptr + SwigIsRCObj() + Ref_count() (_swig_ret int) + Addref() (_swig_ret int) + Delref() (_swig_ret int) + SwigIsRCObjBase() + SwigGetRCObjBase() RCObjBase +} + +type SwigcptrA uintptr + +func (p SwigcptrA) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrA) SwigIsA() { +} + +var _wrap_new_A unsafe.Pointer + +func _swig_wrap_new_A() (base SwigcptrA) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_A, _swig_p) + return +} + +func NewA() (_swig_ret A) { + return _swig_wrap_new_A() +} + +var _wrap_delete_A unsafe.Pointer + +func _swig_wrap_delete_A(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_A, _swig_p) + return +} + +func DeleteA(arg1 A) { + _swig_wrap_delete_A(arg1.Swigcptr()) +} + +var _wrap_A_ref_count unsafe.Pointer + +func _swig_wrap_A_ref_count(base SwigcptrA) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_A_ref_count, _swig_p) + return +} + +func (_swig_base SwigcptrA) Ref_count() (_swig_ret int) { + return _swig_wrap_A_ref_count(_swig_base) +} + +var _wrap_A_addref unsafe.Pointer + +func _swig_wrap_A_addref(base SwigcptrA) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_A_addref, _swig_p) + return +} + +func (_swig_base SwigcptrA) Addref() (_swig_ret int) { + return _swig_wrap_A_addref(_swig_base) +} + +var _wrap_A_delref unsafe.Pointer + +func _swig_wrap_A_delref(base SwigcptrA) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_A_delref, _swig_p) + return +} + +func (_swig_base SwigcptrA) Delref() (_swig_ret int) { + return _swig_wrap_A_delref(_swig_base) +} + +func (p SwigcptrA) SwigIsRCObj() { +} + +func (p SwigcptrA) SwigGetRCObj() RCObj { + return SwigcptrRCObj(p.Swigcptr()) +} + +func (p SwigcptrA) SwigIsRCObjBase() { +} + +func (p SwigcptrA) SwigGetRCObjBase() RCObjBase { + return SwigcptrRCObjBase(p.Swigcptr()) +} + +type A interface { + Swigcptr() uintptr + SwigIsA() + Ref_count() (_swig_ret int) + Addref() (_swig_ret int) + Delref() (_swig_ret int) + SwigIsRCObj() + SwigGetRCObj() RCObj + SwigIsRCObjBase() + SwigGetRCObjBase() RCObjBase +} + +type SwigcptrA1 uintptr + +func (p SwigcptrA1) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrA1) SwigIsA1() { +} + +var _wrap_delete_A1 unsafe.Pointer + +func _swig_wrap_delete_A1(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_A1, _swig_p) + return +} + +func DeleteA1(arg1 A1) { + _swig_wrap_delete_A1(arg1.Swigcptr()) +} + +var _wrap_A1_ref_count unsafe.Pointer + +func _swig_wrap_A1_ref_count(base SwigcptrA1) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_A1_ref_count, _swig_p) + return +} + +func (_swig_base SwigcptrA1) Ref_count() (_swig_ret int) { + return _swig_wrap_A1_ref_count(_swig_base) +} + +var _wrap_A1_addref unsafe.Pointer + +func _swig_wrap_A1_addref(base SwigcptrA1) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_A1_addref, _swig_p) + return +} + +func (_swig_base SwigcptrA1) Addref() (_swig_ret int) { + return _swig_wrap_A1_addref(_swig_base) +} + +var _wrap_A1_delref unsafe.Pointer + +func _swig_wrap_A1_delref(base SwigcptrA1) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_A1_delref, _swig_p) + return +} + +func (_swig_base SwigcptrA1) Delref() (_swig_ret int) { + return _swig_wrap_A1_delref(_swig_base) +} + +func (p SwigcptrA1) SwigIsA() { +} + +func (p SwigcptrA1) SwigGetA() A { + return SwigcptrA(p.Swigcptr()) +} + +func (p SwigcptrA1) SwigIsRCObj() { +} + +func (p SwigcptrA1) SwigGetRCObj() RCObj { + return SwigcptrRCObj(p.Swigcptr()) +} + +func (p SwigcptrA1) SwigIsRCObjBase() { +} + +func (p SwigcptrA1) SwigGetRCObjBase() RCObjBase { + return SwigcptrRCObjBase(p.Swigcptr()) +} + +type A1 interface { + Swigcptr() uintptr + SwigIsA1() + Ref_count() (_swig_ret int) + Addref() (_swig_ret int) + Delref() (_swig_ret int) + SwigIsA() + SwigGetA() A + SwigIsRCObj() + SwigGetRCObj() RCObj + SwigIsRCObjBase() + SwigGetRCObjBase() RCObjBase +} + +type SwigcptrA2 uintptr + +func (p SwigcptrA2) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrA2) SwigIsA2() { +} + +var _wrap_new_A2 unsafe.Pointer + +func _swig_wrap_new_A2() (base SwigcptrA2) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_A2, _swig_p) + return +} + +func NewA2() (_swig_ret A2) { + return _swig_wrap_new_A2() +} + +var _wrap_delete_A2 unsafe.Pointer + +func _swig_wrap_delete_A2(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_A2, _swig_p) + return +} + +func DeleteA2(arg1 A2) { + _swig_wrap_delete_A2(arg1.Swigcptr()) +} + +var _wrap_A2_ref_count unsafe.Pointer + +func _swig_wrap_A2_ref_count(base SwigcptrA2) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_A2_ref_count, _swig_p) + return +} + +func (_swig_base SwigcptrA2) Ref_count() (_swig_ret int) { + return _swig_wrap_A2_ref_count(_swig_base) +} + +var _wrap_A2_addref unsafe.Pointer + +func _swig_wrap_A2_addref(base SwigcptrA2) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_A2_addref, _swig_p) + return +} + +func (_swig_base SwigcptrA2) Addref() (_swig_ret int) { + return _swig_wrap_A2_addref(_swig_base) +} + +var _wrap_A2_delref unsafe.Pointer + +func _swig_wrap_A2_delref(base SwigcptrA2) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_A2_delref, _swig_p) + return +} + +func (_swig_base SwigcptrA2) Delref() (_swig_ret int) { + return _swig_wrap_A2_delref(_swig_base) +} + +func (p SwigcptrA2) SwigIsA() { +} + +func (p SwigcptrA2) SwigGetA() A { + return SwigcptrA(p.Swigcptr()) +} + +func (p SwigcptrA2) SwigIsRCObj() { +} + +func (p SwigcptrA2) SwigGetRCObj() RCObj { + return SwigcptrRCObj(p.Swigcptr()) +} + +func (p SwigcptrA2) SwigIsRCObjBase() { +} + +func (p SwigcptrA2) SwigGetRCObjBase() RCObjBase { + return SwigcptrRCObjBase(p.Swigcptr()) +} + +type A2 interface { + Swigcptr() uintptr + SwigIsA2() + Ref_count() (_swig_ret int) + Addref() (_swig_ret int) + Delref() (_swig_ret int) + SwigIsA() + SwigGetA() A + SwigIsRCObj() + SwigGetRCObj() RCObj + SwigIsRCObjBase() + SwigGetRCObjBase() RCObjBase +} + +type SwigcptrA3 uintptr + +func (p SwigcptrA3) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrA3) SwigIsA3() { +} + +var _wrap_new_A3 unsafe.Pointer + +func _swig_wrap_new_A3() (base SwigcptrA3) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_A3, _swig_p) + return +} + +func NewA3() (_swig_ret A3) { + return _swig_wrap_new_A3() +} + +var _wrap_delete_A3 unsafe.Pointer + +func _swig_wrap_delete_A3(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_A3, _swig_p) + return +} + +func DeleteA3(arg1 A3) { + _swig_wrap_delete_A3(arg1.Swigcptr()) +} + +var _wrap_A3_ref_count unsafe.Pointer + +func _swig_wrap_A3_ref_count(base SwigcptrA3) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_A3_ref_count, _swig_p) + return +} + +func (_swig_base SwigcptrA3) Ref_count() (_swig_ret int) { + return _swig_wrap_A3_ref_count(_swig_base) +} + +var _wrap_A3_addref unsafe.Pointer + +func _swig_wrap_A3_addref(base SwigcptrA3) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_A3_addref, _swig_p) + return +} + +func (_swig_base SwigcptrA3) Addref() (_swig_ret int) { + return _swig_wrap_A3_addref(_swig_base) +} + +var _wrap_A3_delref unsafe.Pointer + +func _swig_wrap_A3_delref(base SwigcptrA3) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_A3_delref, _swig_p) + return +} + +func (_swig_base SwigcptrA3) Delref() (_swig_ret int) { + return _swig_wrap_A3_delref(_swig_base) +} + +func (p SwigcptrA3) SwigIsA1() { +} + +func (p SwigcptrA3) SwigGetA1() A1 { + return SwigcptrA1(p.Swigcptr()) +} + +func (p SwigcptrA3) SwigIsA() { +} + +func (p SwigcptrA3) SwigGetA() A { + return SwigcptrA(p.Swigcptr()) +} + +func (p SwigcptrA3) SwigIsRCObj() { +} + +func (p SwigcptrA3) SwigGetRCObj() RCObj { + return SwigcptrRCObj(p.Swigcptr()) +} + +func (p SwigcptrA3) SwigIsRCObjBase() { +} + +func (p SwigcptrA3) SwigGetRCObjBase() RCObjBase { + return SwigcptrRCObjBase(p.Swigcptr()) +} + +type A3 interface { + Swigcptr() uintptr + SwigIsA3() + Ref_count() (_swig_ret int) + Addref() (_swig_ret int) + Delref() (_swig_ret int) + SwigIsA1() + SwigGetA1() A1 + SwigIsA() + SwigGetA() A + SwigIsRCObj() + SwigGetRCObj() RCObj + SwigIsRCObjBase() + SwigGetRCObjBase() RCObjBase +} + +type SwigcptrB uintptr + +func (p SwigcptrB) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrB) SwigIsB() { +} + +var _wrap_new_B unsafe.Pointer + +func _swig_wrap_new_B(base uintptr) (_ SwigcptrB) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_B, _swig_p) + return +} + +func NewB(arg1 A) (_swig_ret B) { + return _swig_wrap_new_B(arg1.Swigcptr()) +} + +var _wrap_B_get_a unsafe.Pointer + +func _swig_wrap_B_get_a(base SwigcptrB) (_ SwigcptrA) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_B_get_a, _swig_p) + return +} + +func (arg1 SwigcptrB) Get_a() (_swig_ret A) { + return _swig_wrap_B_get_a(arg1) +} + +var _wrap_B_create unsafe.Pointer + +func _swig_wrap_B_create(base uintptr) (_ SwigcptrB) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_B_create, _swig_p) + return +} + +func BCreate(arg1 A) (_swig_ret B) { + return _swig_wrap_B_create(arg1.Swigcptr()) +} + +var _wrap_B_cloner unsafe.Pointer + +func _swig_wrap_B_cloner(base SwigcptrB) (_ SwigcptrB) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_B_cloner, _swig_p) + return +} + +func (arg1 SwigcptrB) Cloner() (_swig_ret B) { + return _swig_wrap_B_cloner(arg1) +} + +var _wrap_delete_B unsafe.Pointer + +func _swig_wrap_delete_B(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_B, _swig_p) + return +} + +func DeleteB(arg1 B) { + _swig_wrap_delete_B(arg1.Swigcptr()) +} + +var _wrap_B_get_rca unsafe.Pointer + +func _swig_wrap_B_get_rca(base SwigcptrB) (_ SwigcptrRCPtr_Sl_A_Sg_) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_B_get_rca, _swig_p) + return +} + +func (arg1 SwigcptrB) Get_rca() (_swig_ret RCPtr_Sl_A_Sg_) { + return _swig_wrap_B_get_rca(arg1) +} + +var _wrap_B_ref_count unsafe.Pointer + +func _swig_wrap_B_ref_count(base SwigcptrB) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_B_ref_count, _swig_p) + return +} + +func (_swig_base SwigcptrB) Ref_count() (_swig_ret int) { + return _swig_wrap_B_ref_count(_swig_base) +} + +var _wrap_B_addref unsafe.Pointer + +func _swig_wrap_B_addref(base SwigcptrB) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_B_addref, _swig_p) + return +} + +func (_swig_base SwigcptrB) Addref() (_swig_ret int) { + return _swig_wrap_B_addref(_swig_base) +} + +var _wrap_B_delref unsafe.Pointer + +func _swig_wrap_B_delref(base SwigcptrB) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_B_delref, _swig_p) + return +} + +func (_swig_base SwigcptrB) Delref() (_swig_ret int) { + return _swig_wrap_B_delref(_swig_base) +} + +func (p SwigcptrB) SwigIsRCObj() { +} + +func (p SwigcptrB) SwigGetRCObj() RCObj { + return SwigcptrRCObj(p.Swigcptr()) +} + +func (p SwigcptrB) SwigIsRCObjBase() { +} + +func (p SwigcptrB) SwigGetRCObjBase() RCObjBase { + return SwigcptrRCObjBase(p.Swigcptr()) +} + +type B interface { + Swigcptr() uintptr + SwigIsB() + Get_a() (_swig_ret A) + Cloner() (_swig_ret B) + Get_rca() (_swig_ret RCPtr_Sl_A_Sg_) + Ref_count() (_swig_ret int) + Addref() (_swig_ret int) + Delref() (_swig_ret int) + SwigIsRCObj() + SwigGetRCObj() RCObj + SwigIsRCObjBase() + SwigGetRCObjBase() RCObjBase +} + +var _wrap_global_create unsafe.Pointer + +func _swig_wrap_global_create(base uintptr) (_ SwigcptrB) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_global_create, _swig_p) + return +} + +func Global_create(arg1 A) (_swig_ret B) { + return _swig_wrap_global_create(arg1.Swigcptr()) +} + +type SwigcptrFactory uintptr + +func (p SwigcptrFactory) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrFactory) SwigIsFactory() { +} + +var _wrap_Factory_create unsafe.Pointer + +func _swig_wrap_Factory_create(base uintptr) (_ SwigcptrB) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Factory_create, _swig_p) + return +} + +func FactoryCreate(arg1 A) (_swig_ret B) { + return _swig_wrap_Factory_create(arg1.Swigcptr()) +} + +var _wrap_Factory_create2 unsafe.Pointer + +func _swig_wrap_Factory_create2(base SwigcptrFactory, _ uintptr) (_ SwigcptrB) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Factory_create2, _swig_p) + return +} + +func (arg1 SwigcptrFactory) Create2(arg2 A) (_swig_ret B) { + return _swig_wrap_Factory_create2(arg1, arg2.Swigcptr()) +} + +var _wrap_new_Factory unsafe.Pointer + +func _swig_wrap_new_Factory() (base SwigcptrFactory) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Factory, _swig_p) + return +} + +func NewFactory() (_swig_ret Factory) { + return _swig_wrap_new_Factory() +} + +var _wrap_delete_Factory unsafe.Pointer + +func _swig_wrap_delete_Factory(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Factory, _swig_p) + return +} + +func DeleteFactory(arg1 Factory) { + _swig_wrap_delete_Factory(arg1.Swigcptr()) +} + +type Factory interface { + Swigcptr() uintptr + SwigIsFactory() + Create2(arg2 A) (_swig_ret B) +} + + +type SwigcptrRCPtr_Sl_A_Sg_ uintptr +type RCPtr_Sl_A_Sg_ interface { + Swigcptr() uintptr; +} +func (p SwigcptrRCPtr_Sl_A_Sg_) Swigcptr() uintptr { + return uintptr(p) +} + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/refcount_runme b/Examples/test-suite/go/refcount_runme new file mode 100755 index 000000000..b379b29f8 Binary files /dev/null and b/Examples/test-suite/go/refcount_runme differ diff --git a/Examples/test-suite/go/reference_global_vars.go b/Examples/test-suite/go/reference_global_vars.go new file mode 100644 index 000000000..23300088c --- /dev/null +++ b/Examples/test-suite/go/reference_global_vars.go @@ -0,0 +1,756 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../reference_global_vars.i + +package reference_global_vars + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrTestClass uintptr + +func (p SwigcptrTestClass) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrTestClass) SwigIsTestClass() { +} + +var _wrap_TestClass_num_set unsafe.Pointer + +func _swig_wrap_TestClass_num_set(base SwigcptrTestClass, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_TestClass_num_set, _swig_p) + return +} + +func (arg1 SwigcptrTestClass) SetNum(arg2 int) { + _swig_wrap_TestClass_num_set(arg1, arg2) +} + +var _wrap_TestClass_num_get unsafe.Pointer + +func _swig_wrap_TestClass_num_get(base SwigcptrTestClass) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_TestClass_num_get, _swig_p) + return +} + +func (arg1 SwigcptrTestClass) GetNum() (_swig_ret int) { + return _swig_wrap_TestClass_num_get(arg1) +} + +var _wrap_new_TestClass__SWIG_0 unsafe.Pointer + +func _swig_wrap_new_TestClass__SWIG_0(base int) (_ SwigcptrTestClass) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_TestClass__SWIG_0, _swig_p) + return +} + +func NewTestClass__SWIG_0(arg1 int) (_swig_ret TestClass) { + return _swig_wrap_new_TestClass__SWIG_0(arg1) +} + +var _wrap_new_TestClass__SWIG_1 unsafe.Pointer + +func _swig_wrap_new_TestClass__SWIG_1() (base SwigcptrTestClass) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_TestClass__SWIG_1, _swig_p) + return +} + +func NewTestClass__SWIG_1() (_swig_ret TestClass) { + return _swig_wrap_new_TestClass__SWIG_1() +} + +func NewTestClass(a ...interface{}) TestClass { + argc := len(a) + if argc == 0 { + return NewTestClass__SWIG_1() + } + if argc == 1 { + return NewTestClass__SWIG_0(a[0].(int)) + } + panic("No match for overloaded function call") +} + +var _wrap_delete_TestClass unsafe.Pointer + +func _swig_wrap_delete_TestClass(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_TestClass, _swig_p) + return +} + +func DeleteTestClass(arg1 TestClass) { + _swig_wrap_delete_TestClass(arg1.Swigcptr()) +} + +type TestClass interface { + Swigcptr() uintptr + SwigIsTestClass() + SetNum(arg2 int) + GetNum() (_swig_ret int) +} + +var _wrap_getconstTC unsafe.Pointer + +func _swig_wrap_getconstTC() (base SwigcptrTestClass) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_getconstTC, _swig_p) + return +} + +func GetconstTC() (_swig_ret TestClass) { + return _swig_wrap_getconstTC() +} + +var _wrap_var_bool_set unsafe.Pointer + +func _swig_wrap_var_bool_set(base *bool) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_var_bool_set, _swig_p) + return +} + +func SetVar_bool(arg1 *bool) { + _swig_wrap_var_bool_set(arg1) +} + +var _wrap_var_bool_get unsafe.Pointer + +func GetVar_bool() (_swig_ret *bool) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_var_bool_get, _swig_p) + return +} +var _wrap_setref_bool unsafe.Pointer + +func Setref_bool(arg1 *bool) (_swig_ret bool) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_setref_bool, _swig_p) + return +} +var _wrap_createref_bool unsafe.Pointer + +func Createref_bool(arg1 bool) (_swig_ret *bool) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_createref_bool, _swig_p) + return +} +var _wrap_value_bool unsafe.Pointer + +func Value_bool(arg1 *bool) (_swig_ret bool) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_value_bool, _swig_p) + return +} +var _wrap_var_char_set unsafe.Pointer + +func _swig_wrap_var_char_set(base *byte) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_var_char_set, _swig_p) + return +} + +func SetVar_char(arg1 *byte) { + _swig_wrap_var_char_set(arg1) +} + +var _wrap_var_char_get unsafe.Pointer + +func GetVar_char() (_swig_ret *byte) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_var_char_get, _swig_p) + return +} +var _wrap_setref_char unsafe.Pointer + +func Setref_char(arg1 *byte) (_swig_ret byte) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_setref_char, _swig_p) + return +} +var _wrap_createref_char unsafe.Pointer + +func Createref_char(arg1 byte) (_swig_ret *byte) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_createref_char, _swig_p) + return +} +var _wrap_value_char unsafe.Pointer + +func Value_char(arg1 *byte) (_swig_ret byte) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_value_char, _swig_p) + return +} +var _wrap_var_unsigned_char_set unsafe.Pointer + +func _swig_wrap_var_unsigned_char_set(base *byte) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_var_unsigned_char_set, _swig_p) + return +} + +func SetVar_unsigned_char(arg1 *byte) { + _swig_wrap_var_unsigned_char_set(arg1) +} + +var _wrap_var_unsigned_char_get unsafe.Pointer + +func GetVar_unsigned_char() (_swig_ret *byte) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_var_unsigned_char_get, _swig_p) + return +} +var _wrap_setref_unsigned_char unsafe.Pointer + +func Setref_unsigned_char(arg1 *byte) (_swig_ret byte) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_setref_unsigned_char, _swig_p) + return +} +var _wrap_createref_unsigned_char unsafe.Pointer + +func Createref_unsigned_char(arg1 byte) (_swig_ret *byte) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_createref_unsigned_char, _swig_p) + return +} +var _wrap_value_unsigned_char unsafe.Pointer + +func Value_unsigned_char(arg1 *byte) (_swig_ret byte) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_value_unsigned_char, _swig_p) + return +} +var _wrap_var_signed_char_set unsafe.Pointer + +func _swig_wrap_var_signed_char_set(base *int8) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_var_signed_char_set, _swig_p) + return +} + +func SetVar_signed_char(arg1 *int8) { + _swig_wrap_var_signed_char_set(arg1) +} + +var _wrap_var_signed_char_get unsafe.Pointer + +func GetVar_signed_char() (_swig_ret *int8) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_var_signed_char_get, _swig_p) + return +} +var _wrap_setref_signed_char unsafe.Pointer + +func Setref_signed_char(arg1 *int8) (_swig_ret int8) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_setref_signed_char, _swig_p) + return +} +var _wrap_createref_signed_char unsafe.Pointer + +func Createref_signed_char(arg1 int8) (_swig_ret *int8) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_createref_signed_char, _swig_p) + return +} +var _wrap_value_signed_char unsafe.Pointer + +func Value_signed_char(arg1 *int8) (_swig_ret int8) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_value_signed_char, _swig_p) + return +} +var _wrap_var_short_set unsafe.Pointer + +func _swig_wrap_var_short_set(base *int16) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_var_short_set, _swig_p) + return +} + +func SetVar_short(arg1 *int16) { + _swig_wrap_var_short_set(arg1) +} + +var _wrap_var_short_get unsafe.Pointer + +func GetVar_short() (_swig_ret *int16) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_var_short_get, _swig_p) + return +} +var _wrap_setref_short unsafe.Pointer + +func Setref_short(arg1 *int16) (_swig_ret int16) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_setref_short, _swig_p) + return +} +var _wrap_createref_short unsafe.Pointer + +func Createref_short(arg1 int16) (_swig_ret *int16) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_createref_short, _swig_p) + return +} +var _wrap_value_short unsafe.Pointer + +func Value_short(arg1 *int16) (_swig_ret int16) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_value_short, _swig_p) + return +} +var _wrap_var_unsigned_short_set unsafe.Pointer + +func _swig_wrap_var_unsigned_short_set(base *uint16) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_var_unsigned_short_set, _swig_p) + return +} + +func SetVar_unsigned_short(arg1 *uint16) { + _swig_wrap_var_unsigned_short_set(arg1) +} + +var _wrap_var_unsigned_short_get unsafe.Pointer + +func GetVar_unsigned_short() (_swig_ret *uint16) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_var_unsigned_short_get, _swig_p) + return +} +var _wrap_setref_unsigned_short unsafe.Pointer + +func Setref_unsigned_short(arg1 *uint16) (_swig_ret uint16) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_setref_unsigned_short, _swig_p) + return +} +var _wrap_createref_unsigned_short unsafe.Pointer + +func Createref_unsigned_short(arg1 uint16) (_swig_ret *uint16) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_createref_unsigned_short, _swig_p) + return +} +var _wrap_value_unsigned_short unsafe.Pointer + +func Value_unsigned_short(arg1 *uint16) (_swig_ret uint16) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_value_unsigned_short, _swig_p) + return +} +var _wrap_var_int_set unsafe.Pointer + +func _swig_wrap_var_int_set(base *int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_var_int_set, _swig_p) + return +} + +func SetVar_int(arg1 *int) { + _swig_wrap_var_int_set(arg1) +} + +var _wrap_var_int_get unsafe.Pointer + +func GetVar_int() (_swig_ret *int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_var_int_get, _swig_p) + return +} +var _wrap_setref_int unsafe.Pointer + +func Setref_int(arg1 *int) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_setref_int, _swig_p) + return +} +var _wrap_createref_int unsafe.Pointer + +func Createref_int(arg1 int) (_swig_ret *int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_createref_int, _swig_p) + return +} +var _wrap_value_int unsafe.Pointer + +func Value_int(arg1 *int) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_value_int, _swig_p) + return +} +var _wrap_var_unsigned_int_set unsafe.Pointer + +func _swig_wrap_var_unsigned_int_set(base *uint) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_var_unsigned_int_set, _swig_p) + return +} + +func SetVar_unsigned_int(arg1 *uint) { + _swig_wrap_var_unsigned_int_set(arg1) +} + +var _wrap_var_unsigned_int_get unsafe.Pointer + +func GetVar_unsigned_int() (_swig_ret *uint) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_var_unsigned_int_get, _swig_p) + return +} +var _wrap_setref_unsigned_int unsafe.Pointer + +func Setref_unsigned_int(arg1 *uint) (_swig_ret uint) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_setref_unsigned_int, _swig_p) + return +} +var _wrap_createref_unsigned_int unsafe.Pointer + +func Createref_unsigned_int(arg1 uint) (_swig_ret *uint) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_createref_unsigned_int, _swig_p) + return +} +var _wrap_value_unsigned_int unsafe.Pointer + +func Value_unsigned_int(arg1 *uint) (_swig_ret uint) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_value_unsigned_int, _swig_p) + return +} +var _wrap_var_long_set unsafe.Pointer + +func _swig_wrap_var_long_set(base *int64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_var_long_set, _swig_p) + return +} + +func SetVar_long(arg1 *int64) { + _swig_wrap_var_long_set(arg1) +} + +var _wrap_var_long_get unsafe.Pointer + +func GetVar_long() (_swig_ret *int64) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_var_long_get, _swig_p) + return +} +var _wrap_setref_long unsafe.Pointer + +func Setref_long(arg1 *int64) (_swig_ret int64) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_setref_long, _swig_p) + return +} +var _wrap_createref_long unsafe.Pointer + +func Createref_long(arg1 int64) (_swig_ret *int64) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_createref_long, _swig_p) + return +} +var _wrap_value_long unsafe.Pointer + +func Value_long(arg1 *int64) (_swig_ret int64) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_value_long, _swig_p) + return +} +var _wrap_var_unsigned_long_set unsafe.Pointer + +func _swig_wrap_var_unsigned_long_set(base *uint64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_var_unsigned_long_set, _swig_p) + return +} + +func SetVar_unsigned_long(arg1 *uint64) { + _swig_wrap_var_unsigned_long_set(arg1) +} + +var _wrap_var_unsigned_long_get unsafe.Pointer + +func GetVar_unsigned_long() (_swig_ret *uint64) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_var_unsigned_long_get, _swig_p) + return +} +var _wrap_setref_unsigned_long unsafe.Pointer + +func Setref_unsigned_long(arg1 *uint64) (_swig_ret uint64) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_setref_unsigned_long, _swig_p) + return +} +var _wrap_createref_unsigned_long unsafe.Pointer + +func Createref_unsigned_long(arg1 uint64) (_swig_ret *uint64) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_createref_unsigned_long, _swig_p) + return +} +var _wrap_value_unsigned_long unsafe.Pointer + +func Value_unsigned_long(arg1 *uint64) (_swig_ret uint64) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_value_unsigned_long, _swig_p) + return +} +var _wrap_var_float_set unsafe.Pointer + +func _swig_wrap_var_float_set(base *float32) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_var_float_set, _swig_p) + return +} + +func SetVar_float(arg1 *float32) { + _swig_wrap_var_float_set(arg1) +} + +var _wrap_var_float_get unsafe.Pointer + +func GetVar_float() (_swig_ret *float32) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_var_float_get, _swig_p) + return +} +var _wrap_setref_float unsafe.Pointer + +func Setref_float(arg1 *float32) (_swig_ret float32) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_setref_float, _swig_p) + return +} +var _wrap_createref_float unsafe.Pointer + +func Createref_float(arg1 float32) (_swig_ret *float32) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_createref_float, _swig_p) + return +} +var _wrap_value_float unsafe.Pointer + +func Value_float(arg1 *float32) (_swig_ret float32) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_value_float, _swig_p) + return +} +var _wrap_var_double_set unsafe.Pointer + +func _swig_wrap_var_double_set(base *float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_var_double_set, _swig_p) + return +} + +func SetVar_double(arg1 *float64) { + _swig_wrap_var_double_set(arg1) +} + +var _wrap_var_double_get unsafe.Pointer + +func GetVar_double() (_swig_ret *float64) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_var_double_get, _swig_p) + return +} +var _wrap_setref_double unsafe.Pointer + +func Setref_double(arg1 *float64) (_swig_ret float64) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_setref_double, _swig_p) + return +} +var _wrap_createref_double unsafe.Pointer + +func Createref_double(arg1 float64) (_swig_ret *float64) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_createref_double, _swig_p) + return +} +var _wrap_value_double unsafe.Pointer + +func Value_double(arg1 *float64) (_swig_ret float64) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_value_double, _swig_p) + return +} +var _wrap_var_long_long_set unsafe.Pointer + +func _swig_wrap_var_long_long_set(base *int64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_var_long_long_set, _swig_p) + return +} + +func SetVar_long_long(arg1 *int64) { + _swig_wrap_var_long_long_set(arg1) +} + +var _wrap_var_long_long_get unsafe.Pointer + +func GetVar_long_long() (_swig_ret *int64) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_var_long_long_get, _swig_p) + return +} +var _wrap_setref_long_long unsafe.Pointer + +func Setref_long_long(arg1 *int64) (_swig_ret int64) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_setref_long_long, _swig_p) + return +} +var _wrap_createref_long_long unsafe.Pointer + +func Createref_long_long(arg1 int64) (_swig_ret *int64) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_createref_long_long, _swig_p) + return +} +var _wrap_value_long_long unsafe.Pointer + +func Value_long_long(arg1 *int64) (_swig_ret int64) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_value_long_long, _swig_p) + return +} +var _wrap_var_unsigned_long_long_set unsafe.Pointer + +func _swig_wrap_var_unsigned_long_long_set(base *uint64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_var_unsigned_long_long_set, _swig_p) + return +} + +func SetVar_unsigned_long_long(arg1 *uint64) { + _swig_wrap_var_unsigned_long_long_set(arg1) +} + +var _wrap_var_unsigned_long_long_get unsafe.Pointer + +func GetVar_unsigned_long_long() (_swig_ret *uint64) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_var_unsigned_long_long_get, _swig_p) + return +} +var _wrap_setref_unsigned_long_long unsafe.Pointer + +func Setref_unsigned_long_long(arg1 *uint64) (_swig_ret uint64) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_setref_unsigned_long_long, _swig_p) + return +} +var _wrap_createref_unsigned_long_long unsafe.Pointer + +func Createref_unsigned_long_long(arg1 uint64) (_swig_ret *uint64) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_createref_unsigned_long_long, _swig_p) + return +} +var _wrap_value_unsigned_long_long unsafe.Pointer + +func Value_unsigned_long_long(arg1 *uint64) (_swig_ret uint64) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_value_unsigned_long_long, _swig_p) + return +} +var _wrap_var_TestClass_set unsafe.Pointer + +func _swig_wrap_var_TestClass_set(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_var_TestClass_set, _swig_p) + return +} + +func SetVar_TestClass(arg1 TestClass) { + _swig_wrap_var_TestClass_set(arg1.Swigcptr()) +} + +var _wrap_var_TestClass_get unsafe.Pointer + +func _swig_wrap_var_TestClass_get() (base SwigcptrTestClass) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_var_TestClass_get, _swig_p) + return +} + +func GetVar_TestClass() (_swig_ret TestClass) { + return _swig_wrap_var_TestClass_get() +} + +var _wrap_setref_TestClass unsafe.Pointer + +func _swig_wrap_setref_TestClass(base uintptr) (_ SwigcptrTestClass) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_setref_TestClass, _swig_p) + return +} + +func Setref_TestClass(arg1 TestClass) (_swig_ret TestClass) { + return _swig_wrap_setref_TestClass(arg1.Swigcptr()) +} + +var _wrap_createref_TestClass unsafe.Pointer + +func _swig_wrap_createref_TestClass(base uintptr) (_ SwigcptrTestClass) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_createref_TestClass, _swig_p) + return +} + +func Createref_TestClass(arg1 TestClass) (_swig_ret TestClass) { + return _swig_wrap_createref_TestClass(arg1.Swigcptr()) +} + +var _wrap_value_TestClass unsafe.Pointer + +func _swig_wrap_value_TestClass(base uintptr) (_ SwigcptrTestClass) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_value_TestClass, _swig_p) + return +} + +func Value_TestClass(arg1 TestClass) (_swig_ret TestClass) { + return _swig_wrap_value_TestClass(arg1.Swigcptr()) +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/reference_global_vars_runme b/Examples/test-suite/go/reference_global_vars_runme new file mode 100755 index 000000000..f7e400a73 Binary files /dev/null and b/Examples/test-suite/go/reference_global_vars_runme differ diff --git a/Examples/test-suite/go/register_par.go b/Examples/test-suite/go/register_par.go new file mode 100644 index 000000000..f52f46490 --- /dev/null +++ b/Examples/test-suite/go/register_par.go @@ -0,0 +1,57 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../register_par.i + +package register_par + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +var _wrap_clear_tree_flags unsafe.Pointer + +func _swig_wrap_clear_tree_flags(base uintptr, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_clear_tree_flags, _swig_p) + return +} + +func Clear_tree_flags(arg1 Tree, arg2 int) { + _swig_wrap_clear_tree_flags(arg1.Swigcptr(), arg2) +} + + +type SwigcptrTree uintptr +type Tree interface { + Swigcptr() uintptr; +} +func (p SwigcptrTree) Swigcptr() uintptr { + return uintptr(p) +} + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/rename1.go b/Examples/test-suite/go/rename1.go new file mode 100644 index 000000000..a23dc4fe1 --- /dev/null +++ b/Examples/test-suite/go/rename1.go @@ -0,0 +1,1023 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../rename1.i + +package rename1 + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrKlass uintptr + +func (p SwigcptrKlass) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrKlass) SwigIsKlass() { +} + +var _wrap_new_Klass__SWIG_0 unsafe.Pointer + +func _swig_wrap_new_Klass__SWIG_0(base int) (_ SwigcptrKlass) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Klass__SWIG_0, _swig_p) + return +} + +func NewKlass__SWIG_0(arg1 int) (_swig_ret Klass) { + return _swig_wrap_new_Klass__SWIG_0(arg1) +} + +var _wrap_new_Klass__SWIG_1 unsafe.Pointer + +func _swig_wrap_new_Klass__SWIG_1() (base SwigcptrKlass) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Klass__SWIG_1, _swig_p) + return +} + +func NewKlass__SWIG_1() (_swig_ret Klass) { + return _swig_wrap_new_Klass__SWIG_1() +} + +func NewKlass(a ...interface{}) Klass { + argc := len(a) + if argc == 0 { + return NewKlass__SWIG_1() + } + if argc == 1 { + return NewKlass__SWIG_0(a[0].(int)) + } + panic("No match for overloaded function call") +} + +var _wrap_delete_Klass unsafe.Pointer + +func _swig_wrap_delete_Klass(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Klass, _swig_p) + return +} + +func DeleteKlass(arg1 Klass) { + _swig_wrap_delete_Klass(arg1.Swigcptr()) +} + +type Klass interface { + Swigcptr() uintptr + SwigIsKlass() +} + +type SwigcptrAnother uintptr + +func (p SwigcptrAnother) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrAnother) SwigIsAnother() { +} + +var _wrap_new_Another unsafe.Pointer + +func _swig_wrap_new_Another() (base SwigcptrAnother) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Another, _swig_p) + return +} + +func NewAnother() (_swig_ret Another) { + return _swig_wrap_new_Another() +} + +var _wrap_delete_Another unsafe.Pointer + +func _swig_wrap_delete_Another(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Another, _swig_p) + return +} + +func DeleteAnother(arg1 Another) { + _swig_wrap_delete_Another(arg1.Swigcptr()) +} + +type Another interface { + Swigcptr() uintptr + SwigIsAnother() +} + +type SpaceEnu int +var _wrap_En1 unsafe.Pointer + +func _swig_getEn1() (_swig_ret SpaceEnu) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_En1, _swig_p) + return +} +var En1 SpaceEnu = _swig_getEn1() +var _wrap_En2 unsafe.Pointer + +func _swig_getEn2() (_swig_ret SpaceEnu) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_En2, _swig_p) + return +} +var En2 SpaceEnu = _swig_getEn2() +var _wrap_En3 unsafe.Pointer + +func _swig_getEn3() (_swig_ret SpaceEnu) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_En3, _swig_p) + return +} +var En3 SpaceEnu = _swig_getEn3() +type SwigcptrABC uintptr + +func (p SwigcptrABC) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrABC) SwigIsABC() { +} + +var _wrap_ABC_methodABC unsafe.Pointer + +func _swig_wrap_ABC_methodABC(base SwigcptrABC, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_ABC_methodABC, _swig_p) + return +} + +func (arg1 SwigcptrABC) MethodABC(arg2 ABC) { + _swig_wrap_ABC_methodABC(arg1, arg2.Swigcptr()) +} + +var _wrap_ABC_methodKlass unsafe.Pointer + +func _swig_wrap_ABC_methodKlass(base SwigcptrABC, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_ABC_methodKlass, _swig_p) + return +} + +func (arg1 SwigcptrABC) MethodKlass(arg2 Klass) { + _swig_wrap_ABC_methodKlass(arg1, arg2.Swigcptr()) +} + +var _wrap_ABC_opABC unsafe.Pointer + +func _swig_wrap_ABC_opABC(base SwigcptrABC) (_ SwigcptrABC) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_ABC_opABC, _swig_p) + return +} + +func (arg1 SwigcptrABC) OpABC() (_swig_ret ABC) { + return _swig_wrap_ABC_opABC(arg1) +} + +var _wrap_ABC_opKlass unsafe.Pointer + +func _swig_wrap_ABC_opKlass(base SwigcptrABC) (_ SwigcptrKlass) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_ABC_opKlass, _swig_p) + return +} + +func (arg1 SwigcptrABC) OpKlass() (_swig_ret Klass) { + return _swig_wrap_ABC_opKlass(arg1) +} + +var _wrap_new_ABC unsafe.Pointer + +func _swig_wrap_new_ABC() (base SwigcptrABC) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_ABC, _swig_p) + return +} + +func NewABC() (_swig_ret ABC) { + return _swig_wrap_new_ABC() +} + +var _wrap_delete_ABC unsafe.Pointer + +func _swig_wrap_delete_ABC(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_ABC, _swig_p) + return +} + +func DeleteABC(arg1 ABC) { + _swig_wrap_delete_ABC(arg1.Swigcptr()) +} + +type ABC interface { + Swigcptr() uintptr + SwigIsABC() + MethodABC(arg2 ABC) + MethodKlass(arg2 Klass) + OpABC() (_swig_ret ABC) + OpKlass() (_swig_ret Klass) +} + +type SwigcptrXYZInt uintptr + +func (p SwigcptrXYZInt) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrXYZInt) SwigIsXYZInt() { +} + +var _wrap_XYZInt_opIntPtrA unsafe.Pointer + +func _swig_wrap_XYZInt_opIntPtrA(base SwigcptrXYZInt) (_ SwigcptrNotXYZInt) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_XYZInt_opIntPtrA, _swig_p) + return +} + +func (arg1 SwigcptrXYZInt) OpIntPtrA() (_swig_ret NotXYZInt) { + return _swig_wrap_XYZInt_opIntPtrA(arg1) +} + +var _wrap_XYZInt_opIntPtrB unsafe.Pointer + +func _swig_wrap_XYZInt_opIntPtrB(base SwigcptrXYZInt) (_ SwigcptrXYZInt) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_XYZInt_opIntPtrB, _swig_p) + return +} + +func (arg1 SwigcptrXYZInt) OpIntPtrB() (_swig_ret XYZInt) { + return _swig_wrap_XYZInt_opIntPtrB(arg1) +} + +var _wrap_XYZInt_opAnother2 unsafe.Pointer + +func _swig_wrap_XYZInt_opAnother2(base SwigcptrXYZInt) (_ SwigcptrAnother) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_XYZInt_opAnother2, _swig_p) + return +} + +func (arg1 SwigcptrXYZInt) OpAnother2() (_swig_ret Another) { + return _swig_wrap_XYZInt_opAnother2(arg1) +} + +var _wrap_XYZInt_tMethod2 unsafe.Pointer + +func _swig_wrap_XYZInt_tMethod2(base SwigcptrXYZInt, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_XYZInt_tMethod2, _swig_p) + return +} + +func (arg1 SwigcptrXYZInt) TMethod2(arg2 int) { + _swig_wrap_XYZInt_tMethod2(arg1, arg2) +} + +var _wrap_XYZInt_tMethodNotXYZ2 unsafe.Pointer + +func _swig_wrap_XYZInt_tMethodNotXYZ2(base SwigcptrXYZInt, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_XYZInt_tMethodNotXYZ2, _swig_p) + return +} + +func (arg1 SwigcptrXYZInt) TMethodNotXYZ2(arg2 NotXYZInt) { + _swig_wrap_XYZInt_tMethodNotXYZ2(arg1, arg2.Swigcptr()) +} + +var _wrap_XYZInt_tMethodXYZ2 unsafe.Pointer + +func _swig_wrap_XYZInt_tMethodXYZ2(base SwigcptrXYZInt, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_XYZInt_tMethodXYZ2, _swig_p) + return +} + +func (arg1 SwigcptrXYZInt) TMethodXYZ2(arg2 XYZInt) { + _swig_wrap_XYZInt_tMethodXYZ2(arg1, arg2.Swigcptr()) +} + +var _wrap_XYZInt_opT2 unsafe.Pointer + +func _swig_wrap_XYZInt_opT2(base SwigcptrXYZInt) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_XYZInt_opT2, _swig_p) + return +} + +func (arg1 SwigcptrXYZInt) OpT2() (_swig_ret int) { + return _swig_wrap_XYZInt_opT2(arg1) +} + +var _wrap_XYZInt_opNotXYZ2 unsafe.Pointer + +func _swig_wrap_XYZInt_opNotXYZ2(base SwigcptrXYZInt) (_ SwigcptrNotXYZInt) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_XYZInt_opNotXYZ2, _swig_p) + return +} + +func (arg1 SwigcptrXYZInt) OpNotXYZ2() (_swig_ret NotXYZInt) { + return _swig_wrap_XYZInt_opNotXYZ2(arg1) +} + +var _wrap_XYZInt_opXYZ2 unsafe.Pointer + +func _swig_wrap_XYZInt_opXYZ2(base SwigcptrXYZInt) (_ SwigcptrXYZInt) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_XYZInt_opXYZ2, _swig_p) + return +} + +func (arg1 SwigcptrXYZInt) OpXYZ2() (_swig_ret XYZInt) { + return _swig_wrap_XYZInt_opXYZ2(arg1) +} + +var _wrap_new_XYZInt unsafe.Pointer + +func _swig_wrap_new_XYZInt() (base SwigcptrXYZInt) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_XYZInt, _swig_p) + return +} + +func NewXYZInt() (_swig_ret XYZInt) { + return _swig_wrap_new_XYZInt() +} + +var _wrap_delete_XYZInt unsafe.Pointer + +func _swig_wrap_delete_XYZInt(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_XYZInt, _swig_p) + return +} + +func DeleteXYZInt(arg1 XYZInt) { + _swig_wrap_delete_XYZInt(arg1.Swigcptr()) +} + +type XYZInt interface { + Swigcptr() uintptr + SwigIsXYZInt() + OpIntPtrA() (_swig_ret NotXYZInt) + OpIntPtrB() (_swig_ret XYZInt) + OpAnother2() (_swig_ret Another) + TMethod2(arg2 int) + TMethodNotXYZ2(arg2 NotXYZInt) + TMethodXYZ2(arg2 XYZInt) + OpT2() (_swig_ret int) + OpNotXYZ2() (_swig_ret NotXYZInt) + OpXYZ2() (_swig_ret XYZInt) +} + +type SwigcptrXYZDouble uintptr + +func (p SwigcptrXYZDouble) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrXYZDouble) SwigIsXYZDouble() { +} + +var _wrap_XYZDouble_opIntPtrA unsafe.Pointer + +func _swig_wrap_XYZDouble_opIntPtrA(base SwigcptrXYZDouble) (_ SwigcptrNotXYZInt) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_XYZDouble_opIntPtrA, _swig_p) + return +} + +func (arg1 SwigcptrXYZDouble) OpIntPtrA() (_swig_ret NotXYZInt) { + return _swig_wrap_XYZDouble_opIntPtrA(arg1) +} + +var _wrap_XYZDouble_opIntPtrB unsafe.Pointer + +func _swig_wrap_XYZDouble_opIntPtrB(base SwigcptrXYZDouble) (_ SwigcptrXYZInt) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_XYZDouble_opIntPtrB, _swig_p) + return +} + +func (arg1 SwigcptrXYZDouble) OpIntPtrB() (_swig_ret XYZInt) { + return _swig_wrap_XYZDouble_opIntPtrB(arg1) +} + +var _wrap_XYZDouble_opAnother1 unsafe.Pointer + +func _swig_wrap_XYZDouble_opAnother1(base SwigcptrXYZDouble) (_ SwigcptrAnother) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_XYZDouble_opAnother1, _swig_p) + return +} + +func (arg1 SwigcptrXYZDouble) OpAnother1() (_swig_ret Another) { + return _swig_wrap_XYZDouble_opAnother1(arg1) +} + +var _wrap_XYZDouble_tMethod1 unsafe.Pointer + +func _swig_wrap_XYZDouble_tMethod1(base SwigcptrXYZDouble, _ float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_XYZDouble_tMethod1, _swig_p) + return +} + +func (arg1 SwigcptrXYZDouble) TMethod1(arg2 float64) { + _swig_wrap_XYZDouble_tMethod1(arg1, arg2) +} + +var _wrap_XYZDouble_tMethodNotXYZ1 unsafe.Pointer + +func _swig_wrap_XYZDouble_tMethodNotXYZ1(base SwigcptrXYZDouble, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_XYZDouble_tMethodNotXYZ1, _swig_p) + return +} + +func (arg1 SwigcptrXYZDouble) TMethodNotXYZ1(arg2 NotXYZDouble) { + _swig_wrap_XYZDouble_tMethodNotXYZ1(arg1, arg2.Swigcptr()) +} + +var _wrap_XYZDouble_tMethodXYZ1 unsafe.Pointer + +func _swig_wrap_XYZDouble_tMethodXYZ1(base SwigcptrXYZDouble, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_XYZDouble_tMethodXYZ1, _swig_p) + return +} + +func (arg1 SwigcptrXYZDouble) TMethodXYZ1(arg2 XYZDouble) { + _swig_wrap_XYZDouble_tMethodXYZ1(arg1, arg2.Swigcptr()) +} + +var _wrap_XYZDouble_opT1 unsafe.Pointer + +func _swig_wrap_XYZDouble_opT1(base SwigcptrXYZDouble) (_ float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_XYZDouble_opT1, _swig_p) + return +} + +func (arg1 SwigcptrXYZDouble) OpT1() (_swig_ret float64) { + return _swig_wrap_XYZDouble_opT1(arg1) +} + +var _wrap_XYZDouble_opNotXYZ1 unsafe.Pointer + +func _swig_wrap_XYZDouble_opNotXYZ1(base SwigcptrXYZDouble) (_ SwigcptrNotXYZDouble) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_XYZDouble_opNotXYZ1, _swig_p) + return +} + +func (arg1 SwigcptrXYZDouble) OpNotXYZ1() (_swig_ret NotXYZDouble) { + return _swig_wrap_XYZDouble_opNotXYZ1(arg1) +} + +var _wrap_XYZDouble_opXYZ1 unsafe.Pointer + +func _swig_wrap_XYZDouble_opXYZ1(base SwigcptrXYZDouble) (_ SwigcptrXYZDouble) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_XYZDouble_opXYZ1, _swig_p) + return +} + +func (arg1 SwigcptrXYZDouble) OpXYZ1() (_swig_ret XYZDouble) { + return _swig_wrap_XYZDouble_opXYZ1(arg1) +} + +var _wrap_new_XYZDouble unsafe.Pointer + +func _swig_wrap_new_XYZDouble() (base SwigcptrXYZDouble) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_XYZDouble, _swig_p) + return +} + +func NewXYZDouble() (_swig_ret XYZDouble) { + return _swig_wrap_new_XYZDouble() +} + +var _wrap_delete_XYZDouble unsafe.Pointer + +func _swig_wrap_delete_XYZDouble(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_XYZDouble, _swig_p) + return +} + +func DeleteXYZDouble(arg1 XYZDouble) { + _swig_wrap_delete_XYZDouble(arg1.Swigcptr()) +} + +type XYZDouble interface { + Swigcptr() uintptr + SwigIsXYZDouble() + OpIntPtrA() (_swig_ret NotXYZInt) + OpIntPtrB() (_swig_ret XYZInt) + OpAnother1() (_swig_ret Another) + TMethod1(arg2 float64) + TMethodNotXYZ1(arg2 NotXYZDouble) + TMethodXYZ1(arg2 XYZDouble) + OpT1() (_swig_ret float64) + OpNotXYZ1() (_swig_ret NotXYZDouble) + OpXYZ1() (_swig_ret XYZDouble) +} + +type SwigcptrXYZKlass uintptr + +func (p SwigcptrXYZKlass) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrXYZKlass) SwigIsXYZKlass() { +} + +var _wrap_XYZKlass_opIntPtrA unsafe.Pointer + +func _swig_wrap_XYZKlass_opIntPtrA(base SwigcptrXYZKlass) (_ SwigcptrNotXYZInt) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_XYZKlass_opIntPtrA, _swig_p) + return +} + +func (arg1 SwigcptrXYZKlass) OpIntPtrA() (_swig_ret NotXYZInt) { + return _swig_wrap_XYZKlass_opIntPtrA(arg1) +} + +var _wrap_XYZKlass_opIntPtrB unsafe.Pointer + +func _swig_wrap_XYZKlass_opIntPtrB(base SwigcptrXYZKlass) (_ SwigcptrXYZInt) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_XYZKlass_opIntPtrB, _swig_p) + return +} + +func (arg1 SwigcptrXYZKlass) OpIntPtrB() (_swig_ret XYZInt) { + return _swig_wrap_XYZKlass_opIntPtrB(arg1) +} + +var _wrap_XYZKlass_opAnother3 unsafe.Pointer + +func _swig_wrap_XYZKlass_opAnother3(base SwigcptrXYZKlass) (_ SwigcptrAnother) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_XYZKlass_opAnother3, _swig_p) + return +} + +func (arg1 SwigcptrXYZKlass) OpAnother3() (_swig_ret Another) { + return _swig_wrap_XYZKlass_opAnother3(arg1) +} + +var _wrap_XYZKlass_tMethod3 unsafe.Pointer + +func _swig_wrap_XYZKlass_tMethod3(base SwigcptrXYZKlass, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_XYZKlass_tMethod3, _swig_p) + return +} + +func (arg1 SwigcptrXYZKlass) TMethod3(arg2 Klass) { + _swig_wrap_XYZKlass_tMethod3(arg1, arg2.Swigcptr()) +} + +var _wrap_XYZKlass_tMethodNotXYZ3 unsafe.Pointer + +func _swig_wrap_XYZKlass_tMethodNotXYZ3(base SwigcptrXYZKlass, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_XYZKlass_tMethodNotXYZ3, _swig_p) + return +} + +func (arg1 SwigcptrXYZKlass) TMethodNotXYZ3(arg2 NotXYZKlass) { + _swig_wrap_XYZKlass_tMethodNotXYZ3(arg1, arg2.Swigcptr()) +} + +var _wrap_XYZKlass_tMethodXYZ3 unsafe.Pointer + +func _swig_wrap_XYZKlass_tMethodXYZ3(base SwigcptrXYZKlass, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_XYZKlass_tMethodXYZ3, _swig_p) + return +} + +func (arg1 SwigcptrXYZKlass) TMethodXYZ3(arg2 XYZKlass) { + _swig_wrap_XYZKlass_tMethodXYZ3(arg1, arg2.Swigcptr()) +} + +var _wrap_XYZKlass_opT3 unsafe.Pointer + +func _swig_wrap_XYZKlass_opT3(base SwigcptrXYZKlass) (_ SwigcptrKlass) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_XYZKlass_opT3, _swig_p) + return +} + +func (arg1 SwigcptrXYZKlass) OpT3() (_swig_ret Klass) { + return _swig_wrap_XYZKlass_opT3(arg1) +} + +var _wrap_XYZKlass_opNotXYZ3 unsafe.Pointer + +func _swig_wrap_XYZKlass_opNotXYZ3(base SwigcptrXYZKlass) (_ SwigcptrNotXYZKlass) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_XYZKlass_opNotXYZ3, _swig_p) + return +} + +func (arg1 SwigcptrXYZKlass) OpNotXYZ3() (_swig_ret NotXYZKlass) { + return _swig_wrap_XYZKlass_opNotXYZ3(arg1) +} + +var _wrap_XYZKlass_opXYZ3 unsafe.Pointer + +func _swig_wrap_XYZKlass_opXYZ3(base SwigcptrXYZKlass) (_ SwigcptrXYZKlass) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_XYZKlass_opXYZ3, _swig_p) + return +} + +func (arg1 SwigcptrXYZKlass) OpXYZ3() (_swig_ret XYZKlass) { + return _swig_wrap_XYZKlass_opXYZ3(arg1) +} + +var _wrap_new_XYZKlass unsafe.Pointer + +func _swig_wrap_new_XYZKlass() (base SwigcptrXYZKlass) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_XYZKlass, _swig_p) + return +} + +func NewXYZKlass() (_swig_ret XYZKlass) { + return _swig_wrap_new_XYZKlass() +} + +var _wrap_delete_XYZKlass unsafe.Pointer + +func _swig_wrap_delete_XYZKlass(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_XYZKlass, _swig_p) + return +} + +func DeleteXYZKlass(arg1 XYZKlass) { + _swig_wrap_delete_XYZKlass(arg1.Swigcptr()) +} + +type XYZKlass interface { + Swigcptr() uintptr + SwigIsXYZKlass() + OpIntPtrA() (_swig_ret NotXYZInt) + OpIntPtrB() (_swig_ret XYZInt) + OpAnother3() (_swig_ret Another) + TMethod3(arg2 Klass) + TMethodNotXYZ3(arg2 NotXYZKlass) + TMethodXYZ3(arg2 XYZKlass) + OpT3() (_swig_ret Klass) + OpNotXYZ3() (_swig_ret NotXYZKlass) + OpXYZ3() (_swig_ret XYZKlass) +} + +type SwigcptrXYZEnu uintptr + +func (p SwigcptrXYZEnu) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrXYZEnu) SwigIsXYZEnu() { +} + +var _wrap_XYZEnu_opIntPtrA unsafe.Pointer + +func _swig_wrap_XYZEnu_opIntPtrA(base SwigcptrXYZEnu) (_ SwigcptrNotXYZInt) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_XYZEnu_opIntPtrA, _swig_p) + return +} + +func (arg1 SwigcptrXYZEnu) OpIntPtrA() (_swig_ret NotXYZInt) { + return _swig_wrap_XYZEnu_opIntPtrA(arg1) +} + +var _wrap_XYZEnu_opIntPtrB unsafe.Pointer + +func _swig_wrap_XYZEnu_opIntPtrB(base SwigcptrXYZEnu) (_ SwigcptrXYZInt) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_XYZEnu_opIntPtrB, _swig_p) + return +} + +func (arg1 SwigcptrXYZEnu) OpIntPtrB() (_swig_ret XYZInt) { + return _swig_wrap_XYZEnu_opIntPtrB(arg1) +} + +var _wrap_XYZEnu_opAnother4 unsafe.Pointer + +func _swig_wrap_XYZEnu_opAnother4(base SwigcptrXYZEnu) (_ SwigcptrAnother) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_XYZEnu_opAnother4, _swig_p) + return +} + +func (arg1 SwigcptrXYZEnu) OpAnother4() (_swig_ret Another) { + return _swig_wrap_XYZEnu_opAnother4(arg1) +} + +var _wrap_XYZEnu_tMethod4 unsafe.Pointer + +func _swig_wrap_XYZEnu_tMethod4(base SwigcptrXYZEnu, _ SpaceEnu) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_XYZEnu_tMethod4, _swig_p) + return +} + +func (arg1 SwigcptrXYZEnu) TMethod4(arg2 SpaceEnu) { + _swig_wrap_XYZEnu_tMethod4(arg1, arg2) +} + +var _wrap_XYZEnu_tMethodNotXYZ4 unsafe.Pointer + +func _swig_wrap_XYZEnu_tMethodNotXYZ4(base SwigcptrXYZEnu, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_XYZEnu_tMethodNotXYZ4, _swig_p) + return +} + +func (arg1 SwigcptrXYZEnu) TMethodNotXYZ4(arg2 NotXYZEnu) { + _swig_wrap_XYZEnu_tMethodNotXYZ4(arg1, arg2.Swigcptr()) +} + +var _wrap_XYZEnu_tMethodXYZ4 unsafe.Pointer + +func _swig_wrap_XYZEnu_tMethodXYZ4(base SwigcptrXYZEnu, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_XYZEnu_tMethodXYZ4, _swig_p) + return +} + +func (arg1 SwigcptrXYZEnu) TMethodXYZ4(arg2 XYZEnu) { + _swig_wrap_XYZEnu_tMethodXYZ4(arg1, arg2.Swigcptr()) +} + +var _wrap_XYZEnu_opT4 unsafe.Pointer + +func _swig_wrap_XYZEnu_opT4(base SwigcptrXYZEnu) (_ SpaceEnu) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_XYZEnu_opT4, _swig_p) + return +} + +func (arg1 SwigcptrXYZEnu) OpT4() (_swig_ret SpaceEnu) { + return _swig_wrap_XYZEnu_opT4(arg1) +} + +var _wrap_XYZEnu_opNotXYZ4 unsafe.Pointer + +func _swig_wrap_XYZEnu_opNotXYZ4(base SwigcptrXYZEnu) (_ SwigcptrNotXYZEnu) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_XYZEnu_opNotXYZ4, _swig_p) + return +} + +func (arg1 SwigcptrXYZEnu) OpNotXYZ4() (_swig_ret NotXYZEnu) { + return _swig_wrap_XYZEnu_opNotXYZ4(arg1) +} + +var _wrap_XYZEnu_opXYZ4 unsafe.Pointer + +func _swig_wrap_XYZEnu_opXYZ4(base SwigcptrXYZEnu) (_ SwigcptrXYZEnu) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_XYZEnu_opXYZ4, _swig_p) + return +} + +func (arg1 SwigcptrXYZEnu) OpXYZ4() (_swig_ret XYZEnu) { + return _swig_wrap_XYZEnu_opXYZ4(arg1) +} + +var _wrap_new_XYZEnu unsafe.Pointer + +func _swig_wrap_new_XYZEnu() (base SwigcptrXYZEnu) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_XYZEnu, _swig_p) + return +} + +func NewXYZEnu() (_swig_ret XYZEnu) { + return _swig_wrap_new_XYZEnu() +} + +var _wrap_delete_XYZEnu unsafe.Pointer + +func _swig_wrap_delete_XYZEnu(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_XYZEnu, _swig_p) + return +} + +func DeleteXYZEnu(arg1 XYZEnu) { + _swig_wrap_delete_XYZEnu(arg1.Swigcptr()) +} + +type XYZEnu interface { + Swigcptr() uintptr + SwigIsXYZEnu() + OpIntPtrA() (_swig_ret NotXYZInt) + OpIntPtrB() (_swig_ret XYZInt) + OpAnother4() (_swig_ret Another) + TMethod4(arg2 SpaceEnu) + TMethodNotXYZ4(arg2 NotXYZEnu) + TMethodXYZ4(arg2 XYZEnu) + OpT4() (_swig_ret SpaceEnu) + OpNotXYZ4() (_swig_ret NotXYZEnu) + OpXYZ4() (_swig_ret XYZEnu) +} + +type SwigcptrNotXYZInt uintptr + +func (p SwigcptrNotXYZInt) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrNotXYZInt) SwigIsNotXYZInt() { +} + +var _wrap_new_NotXYZInt unsafe.Pointer + +func _swig_wrap_new_NotXYZInt() (base SwigcptrNotXYZInt) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_NotXYZInt, _swig_p) + return +} + +func NewNotXYZInt() (_swig_ret NotXYZInt) { + return _swig_wrap_new_NotXYZInt() +} + +var _wrap_delete_NotXYZInt unsafe.Pointer + +func _swig_wrap_delete_NotXYZInt(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_NotXYZInt, _swig_p) + return +} + +func DeleteNotXYZInt(arg1 NotXYZInt) { + _swig_wrap_delete_NotXYZInt(arg1.Swigcptr()) +} + +type NotXYZInt interface { + Swigcptr() uintptr + SwigIsNotXYZInt() +} + +type SwigcptrNotXYZDouble uintptr + +func (p SwigcptrNotXYZDouble) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrNotXYZDouble) SwigIsNotXYZDouble() { +} + +var _wrap_new_NotXYZDouble unsafe.Pointer + +func _swig_wrap_new_NotXYZDouble() (base SwigcptrNotXYZDouble) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_NotXYZDouble, _swig_p) + return +} + +func NewNotXYZDouble() (_swig_ret NotXYZDouble) { + return _swig_wrap_new_NotXYZDouble() +} + +var _wrap_delete_NotXYZDouble unsafe.Pointer + +func _swig_wrap_delete_NotXYZDouble(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_NotXYZDouble, _swig_p) + return +} + +func DeleteNotXYZDouble(arg1 NotXYZDouble) { + _swig_wrap_delete_NotXYZDouble(arg1.Swigcptr()) +} + +type NotXYZDouble interface { + Swigcptr() uintptr + SwigIsNotXYZDouble() +} + +type SwigcptrNotXYZKlass uintptr + +func (p SwigcptrNotXYZKlass) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrNotXYZKlass) SwigIsNotXYZKlass() { +} + +var _wrap_new_NotXYZKlass unsafe.Pointer + +func _swig_wrap_new_NotXYZKlass() (base SwigcptrNotXYZKlass) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_NotXYZKlass, _swig_p) + return +} + +func NewNotXYZKlass() (_swig_ret NotXYZKlass) { + return _swig_wrap_new_NotXYZKlass() +} + +var _wrap_delete_NotXYZKlass unsafe.Pointer + +func _swig_wrap_delete_NotXYZKlass(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_NotXYZKlass, _swig_p) + return +} + +func DeleteNotXYZKlass(arg1 NotXYZKlass) { + _swig_wrap_delete_NotXYZKlass(arg1.Swigcptr()) +} + +type NotXYZKlass interface { + Swigcptr() uintptr + SwigIsNotXYZKlass() +} + +type SwigcptrNotXYZEnu uintptr + +func (p SwigcptrNotXYZEnu) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrNotXYZEnu) SwigIsNotXYZEnu() { +} + +var _wrap_new_NotXYZEnu unsafe.Pointer + +func _swig_wrap_new_NotXYZEnu() (base SwigcptrNotXYZEnu) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_NotXYZEnu, _swig_p) + return +} + +func NewNotXYZEnu() (_swig_ret NotXYZEnu) { + return _swig_wrap_new_NotXYZEnu() +} + +var _wrap_delete_NotXYZEnu unsafe.Pointer + +func _swig_wrap_delete_NotXYZEnu(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_NotXYZEnu, _swig_p) + return +} + +func DeleteNotXYZEnu(arg1 NotXYZEnu) { + _swig_wrap_delete_NotXYZEnu(arg1.Swigcptr()) +} + +type NotXYZEnu interface { + Swigcptr() uintptr + SwigIsNotXYZEnu() +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/rename2.go b/Examples/test-suite/go/rename2.go new file mode 100644 index 000000000..106dc07ff --- /dev/null +++ b/Examples/test-suite/go/rename2.go @@ -0,0 +1,1023 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../rename2.i + +package rename2 + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrKlass uintptr + +func (p SwigcptrKlass) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrKlass) SwigIsKlass() { +} + +var _wrap_new_Klass__SWIG_0 unsafe.Pointer + +func _swig_wrap_new_Klass__SWIG_0(base int) (_ SwigcptrKlass) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Klass__SWIG_0, _swig_p) + return +} + +func NewKlass__SWIG_0(arg1 int) (_swig_ret Klass) { + return _swig_wrap_new_Klass__SWIG_0(arg1) +} + +var _wrap_new_Klass__SWIG_1 unsafe.Pointer + +func _swig_wrap_new_Klass__SWIG_1() (base SwigcptrKlass) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Klass__SWIG_1, _swig_p) + return +} + +func NewKlass__SWIG_1() (_swig_ret Klass) { + return _swig_wrap_new_Klass__SWIG_1() +} + +func NewKlass(a ...interface{}) Klass { + argc := len(a) + if argc == 0 { + return NewKlass__SWIG_1() + } + if argc == 1 { + return NewKlass__SWIG_0(a[0].(int)) + } + panic("No match for overloaded function call") +} + +var _wrap_delete_Klass unsafe.Pointer + +func _swig_wrap_delete_Klass(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Klass, _swig_p) + return +} + +func DeleteKlass(arg1 Klass) { + _swig_wrap_delete_Klass(arg1.Swigcptr()) +} + +type Klass interface { + Swigcptr() uintptr + SwigIsKlass() +} + +type SwigcptrAnother uintptr + +func (p SwigcptrAnother) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrAnother) SwigIsAnother() { +} + +var _wrap_new_Another unsafe.Pointer + +func _swig_wrap_new_Another() (base SwigcptrAnother) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Another, _swig_p) + return +} + +func NewAnother() (_swig_ret Another) { + return _swig_wrap_new_Another() +} + +var _wrap_delete_Another unsafe.Pointer + +func _swig_wrap_delete_Another(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Another, _swig_p) + return +} + +func DeleteAnother(arg1 Another) { + _swig_wrap_delete_Another(arg1.Swigcptr()) +} + +type Another interface { + Swigcptr() uintptr + SwigIsAnother() +} + +type SpaceEnu int +var _wrap_En1 unsafe.Pointer + +func _swig_getEn1() (_swig_ret SpaceEnu) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_En1, _swig_p) + return +} +var En1 SpaceEnu = _swig_getEn1() +var _wrap_En2 unsafe.Pointer + +func _swig_getEn2() (_swig_ret SpaceEnu) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_En2, _swig_p) + return +} +var En2 SpaceEnu = _swig_getEn2() +var _wrap_En3 unsafe.Pointer + +func _swig_getEn3() (_swig_ret SpaceEnu) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_En3, _swig_p) + return +} +var En3 SpaceEnu = _swig_getEn3() +type SwigcptrABC uintptr + +func (p SwigcptrABC) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrABC) SwigIsABC() { +} + +var _wrap_ABC_methodABC unsafe.Pointer + +func _swig_wrap_ABC_methodABC(base SwigcptrABC, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_ABC_methodABC, _swig_p) + return +} + +func (arg1 SwigcptrABC) MethodABC(arg2 ABC) { + _swig_wrap_ABC_methodABC(arg1, arg2.Swigcptr()) +} + +var _wrap_ABC_methodKlass unsafe.Pointer + +func _swig_wrap_ABC_methodKlass(base SwigcptrABC, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_ABC_methodKlass, _swig_p) + return +} + +func (arg1 SwigcptrABC) MethodKlass(arg2 Klass) { + _swig_wrap_ABC_methodKlass(arg1, arg2.Swigcptr()) +} + +var _wrap_ABC_opABC unsafe.Pointer + +func _swig_wrap_ABC_opABC(base SwigcptrABC) (_ SwigcptrABC) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_ABC_opABC, _swig_p) + return +} + +func (arg1 SwigcptrABC) OpABC() (_swig_ret ABC) { + return _swig_wrap_ABC_opABC(arg1) +} + +var _wrap_ABC_opKlass unsafe.Pointer + +func _swig_wrap_ABC_opKlass(base SwigcptrABC) (_ SwigcptrKlass) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_ABC_opKlass, _swig_p) + return +} + +func (arg1 SwigcptrABC) OpKlass() (_swig_ret Klass) { + return _swig_wrap_ABC_opKlass(arg1) +} + +var _wrap_new_ABC unsafe.Pointer + +func _swig_wrap_new_ABC() (base SwigcptrABC) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_ABC, _swig_p) + return +} + +func NewABC() (_swig_ret ABC) { + return _swig_wrap_new_ABC() +} + +var _wrap_delete_ABC unsafe.Pointer + +func _swig_wrap_delete_ABC(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_ABC, _swig_p) + return +} + +func DeleteABC(arg1 ABC) { + _swig_wrap_delete_ABC(arg1.Swigcptr()) +} + +type ABC interface { + Swigcptr() uintptr + SwigIsABC() + MethodABC(arg2 ABC) + MethodKlass(arg2 Klass) + OpABC() (_swig_ret ABC) + OpKlass() (_swig_ret Klass) +} + +type SwigcptrXYZInt uintptr + +func (p SwigcptrXYZInt) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrXYZInt) SwigIsXYZInt() { +} + +var _wrap_XYZInt_opIntPtrA unsafe.Pointer + +func _swig_wrap_XYZInt_opIntPtrA(base SwigcptrXYZInt) (_ SwigcptrNotXYZInt) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_XYZInt_opIntPtrA, _swig_p) + return +} + +func (arg1 SwigcptrXYZInt) OpIntPtrA() (_swig_ret NotXYZInt) { + return _swig_wrap_XYZInt_opIntPtrA(arg1) +} + +var _wrap_XYZInt_opIntPtrB unsafe.Pointer + +func _swig_wrap_XYZInt_opIntPtrB(base SwigcptrXYZInt) (_ SwigcptrXYZInt) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_XYZInt_opIntPtrB, _swig_p) + return +} + +func (arg1 SwigcptrXYZInt) OpIntPtrB() (_swig_ret XYZInt) { + return _swig_wrap_XYZInt_opIntPtrB(arg1) +} + +var _wrap_XYZInt_opAnother2 unsafe.Pointer + +func _swig_wrap_XYZInt_opAnother2(base SwigcptrXYZInt) (_ SwigcptrAnother) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_XYZInt_opAnother2, _swig_p) + return +} + +func (arg1 SwigcptrXYZInt) OpAnother2() (_swig_ret Another) { + return _swig_wrap_XYZInt_opAnother2(arg1) +} + +var _wrap_XYZInt_tMethod2 unsafe.Pointer + +func _swig_wrap_XYZInt_tMethod2(base SwigcptrXYZInt, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_XYZInt_tMethod2, _swig_p) + return +} + +func (arg1 SwigcptrXYZInt) TMethod2(arg2 int) { + _swig_wrap_XYZInt_tMethod2(arg1, arg2) +} + +var _wrap_XYZInt_tMethodNotXYZ2 unsafe.Pointer + +func _swig_wrap_XYZInt_tMethodNotXYZ2(base SwigcptrXYZInt, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_XYZInt_tMethodNotXYZ2, _swig_p) + return +} + +func (arg1 SwigcptrXYZInt) TMethodNotXYZ2(arg2 NotXYZInt) { + _swig_wrap_XYZInt_tMethodNotXYZ2(arg1, arg2.Swigcptr()) +} + +var _wrap_XYZInt_tMethodXYZ2 unsafe.Pointer + +func _swig_wrap_XYZInt_tMethodXYZ2(base SwigcptrXYZInt, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_XYZInt_tMethodXYZ2, _swig_p) + return +} + +func (arg1 SwigcptrXYZInt) TMethodXYZ2(arg2 XYZInt) { + _swig_wrap_XYZInt_tMethodXYZ2(arg1, arg2.Swigcptr()) +} + +var _wrap_XYZInt_opT2 unsafe.Pointer + +func _swig_wrap_XYZInt_opT2(base SwigcptrXYZInt) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_XYZInt_opT2, _swig_p) + return +} + +func (arg1 SwigcptrXYZInt) OpT2() (_swig_ret int) { + return _swig_wrap_XYZInt_opT2(arg1) +} + +var _wrap_XYZInt_opNotXYZ2 unsafe.Pointer + +func _swig_wrap_XYZInt_opNotXYZ2(base SwigcptrXYZInt) (_ SwigcptrNotXYZInt) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_XYZInt_opNotXYZ2, _swig_p) + return +} + +func (arg1 SwigcptrXYZInt) OpNotXYZ2() (_swig_ret NotXYZInt) { + return _swig_wrap_XYZInt_opNotXYZ2(arg1) +} + +var _wrap_XYZInt_opXYZ2 unsafe.Pointer + +func _swig_wrap_XYZInt_opXYZ2(base SwigcptrXYZInt) (_ SwigcptrXYZInt) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_XYZInt_opXYZ2, _swig_p) + return +} + +func (arg1 SwigcptrXYZInt) OpXYZ2() (_swig_ret XYZInt) { + return _swig_wrap_XYZInt_opXYZ2(arg1) +} + +var _wrap_new_XYZInt unsafe.Pointer + +func _swig_wrap_new_XYZInt() (base SwigcptrXYZInt) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_XYZInt, _swig_p) + return +} + +func NewXYZInt() (_swig_ret XYZInt) { + return _swig_wrap_new_XYZInt() +} + +var _wrap_delete_XYZInt unsafe.Pointer + +func _swig_wrap_delete_XYZInt(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_XYZInt, _swig_p) + return +} + +func DeleteXYZInt(arg1 XYZInt) { + _swig_wrap_delete_XYZInt(arg1.Swigcptr()) +} + +type XYZInt interface { + Swigcptr() uintptr + SwigIsXYZInt() + OpIntPtrA() (_swig_ret NotXYZInt) + OpIntPtrB() (_swig_ret XYZInt) + OpAnother2() (_swig_ret Another) + TMethod2(arg2 int) + TMethodNotXYZ2(arg2 NotXYZInt) + TMethodXYZ2(arg2 XYZInt) + OpT2() (_swig_ret int) + OpNotXYZ2() (_swig_ret NotXYZInt) + OpXYZ2() (_swig_ret XYZInt) +} + +type SwigcptrXYZDouble uintptr + +func (p SwigcptrXYZDouble) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrXYZDouble) SwigIsXYZDouble() { +} + +var _wrap_XYZDouble_opIntPtrA unsafe.Pointer + +func _swig_wrap_XYZDouble_opIntPtrA(base SwigcptrXYZDouble) (_ SwigcptrNotXYZInt) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_XYZDouble_opIntPtrA, _swig_p) + return +} + +func (arg1 SwigcptrXYZDouble) OpIntPtrA() (_swig_ret NotXYZInt) { + return _swig_wrap_XYZDouble_opIntPtrA(arg1) +} + +var _wrap_XYZDouble_opIntPtrB unsafe.Pointer + +func _swig_wrap_XYZDouble_opIntPtrB(base SwigcptrXYZDouble) (_ SwigcptrXYZInt) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_XYZDouble_opIntPtrB, _swig_p) + return +} + +func (arg1 SwigcptrXYZDouble) OpIntPtrB() (_swig_ret XYZInt) { + return _swig_wrap_XYZDouble_opIntPtrB(arg1) +} + +var _wrap_XYZDouble_opAnother1 unsafe.Pointer + +func _swig_wrap_XYZDouble_opAnother1(base SwigcptrXYZDouble) (_ SwigcptrAnother) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_XYZDouble_opAnother1, _swig_p) + return +} + +func (arg1 SwigcptrXYZDouble) OpAnother1() (_swig_ret Another) { + return _swig_wrap_XYZDouble_opAnother1(arg1) +} + +var _wrap_XYZDouble_tMethod1 unsafe.Pointer + +func _swig_wrap_XYZDouble_tMethod1(base SwigcptrXYZDouble, _ float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_XYZDouble_tMethod1, _swig_p) + return +} + +func (arg1 SwigcptrXYZDouble) TMethod1(arg2 float64) { + _swig_wrap_XYZDouble_tMethod1(arg1, arg2) +} + +var _wrap_XYZDouble_tMethodNotXYZ1 unsafe.Pointer + +func _swig_wrap_XYZDouble_tMethodNotXYZ1(base SwigcptrXYZDouble, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_XYZDouble_tMethodNotXYZ1, _swig_p) + return +} + +func (arg1 SwigcptrXYZDouble) TMethodNotXYZ1(arg2 NotXYZDouble) { + _swig_wrap_XYZDouble_tMethodNotXYZ1(arg1, arg2.Swigcptr()) +} + +var _wrap_XYZDouble_tMethodXYZ1 unsafe.Pointer + +func _swig_wrap_XYZDouble_tMethodXYZ1(base SwigcptrXYZDouble, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_XYZDouble_tMethodXYZ1, _swig_p) + return +} + +func (arg1 SwigcptrXYZDouble) TMethodXYZ1(arg2 XYZDouble) { + _swig_wrap_XYZDouble_tMethodXYZ1(arg1, arg2.Swigcptr()) +} + +var _wrap_XYZDouble_opT1 unsafe.Pointer + +func _swig_wrap_XYZDouble_opT1(base SwigcptrXYZDouble) (_ float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_XYZDouble_opT1, _swig_p) + return +} + +func (arg1 SwigcptrXYZDouble) OpT1() (_swig_ret float64) { + return _swig_wrap_XYZDouble_opT1(arg1) +} + +var _wrap_XYZDouble_opNotXYZ1 unsafe.Pointer + +func _swig_wrap_XYZDouble_opNotXYZ1(base SwigcptrXYZDouble) (_ SwigcptrNotXYZDouble) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_XYZDouble_opNotXYZ1, _swig_p) + return +} + +func (arg1 SwigcptrXYZDouble) OpNotXYZ1() (_swig_ret NotXYZDouble) { + return _swig_wrap_XYZDouble_opNotXYZ1(arg1) +} + +var _wrap_XYZDouble_opXYZ1 unsafe.Pointer + +func _swig_wrap_XYZDouble_opXYZ1(base SwigcptrXYZDouble) (_ SwigcptrXYZDouble) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_XYZDouble_opXYZ1, _swig_p) + return +} + +func (arg1 SwigcptrXYZDouble) OpXYZ1() (_swig_ret XYZDouble) { + return _swig_wrap_XYZDouble_opXYZ1(arg1) +} + +var _wrap_new_XYZDouble unsafe.Pointer + +func _swig_wrap_new_XYZDouble() (base SwigcptrXYZDouble) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_XYZDouble, _swig_p) + return +} + +func NewXYZDouble() (_swig_ret XYZDouble) { + return _swig_wrap_new_XYZDouble() +} + +var _wrap_delete_XYZDouble unsafe.Pointer + +func _swig_wrap_delete_XYZDouble(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_XYZDouble, _swig_p) + return +} + +func DeleteXYZDouble(arg1 XYZDouble) { + _swig_wrap_delete_XYZDouble(arg1.Swigcptr()) +} + +type XYZDouble interface { + Swigcptr() uintptr + SwigIsXYZDouble() + OpIntPtrA() (_swig_ret NotXYZInt) + OpIntPtrB() (_swig_ret XYZInt) + OpAnother1() (_swig_ret Another) + TMethod1(arg2 float64) + TMethodNotXYZ1(arg2 NotXYZDouble) + TMethodXYZ1(arg2 XYZDouble) + OpT1() (_swig_ret float64) + OpNotXYZ1() (_swig_ret NotXYZDouble) + OpXYZ1() (_swig_ret XYZDouble) +} + +type SwigcptrXYZKlass uintptr + +func (p SwigcptrXYZKlass) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrXYZKlass) SwigIsXYZKlass() { +} + +var _wrap_XYZKlass_opIntPtrA unsafe.Pointer + +func _swig_wrap_XYZKlass_opIntPtrA(base SwigcptrXYZKlass) (_ SwigcptrNotXYZInt) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_XYZKlass_opIntPtrA, _swig_p) + return +} + +func (arg1 SwigcptrXYZKlass) OpIntPtrA() (_swig_ret NotXYZInt) { + return _swig_wrap_XYZKlass_opIntPtrA(arg1) +} + +var _wrap_XYZKlass_opIntPtrB unsafe.Pointer + +func _swig_wrap_XYZKlass_opIntPtrB(base SwigcptrXYZKlass) (_ SwigcptrXYZInt) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_XYZKlass_opIntPtrB, _swig_p) + return +} + +func (arg1 SwigcptrXYZKlass) OpIntPtrB() (_swig_ret XYZInt) { + return _swig_wrap_XYZKlass_opIntPtrB(arg1) +} + +var _wrap_XYZKlass_opAnother3 unsafe.Pointer + +func _swig_wrap_XYZKlass_opAnother3(base SwigcptrXYZKlass) (_ SwigcptrAnother) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_XYZKlass_opAnother3, _swig_p) + return +} + +func (arg1 SwigcptrXYZKlass) OpAnother3() (_swig_ret Another) { + return _swig_wrap_XYZKlass_opAnother3(arg1) +} + +var _wrap_XYZKlass_tMethod3 unsafe.Pointer + +func _swig_wrap_XYZKlass_tMethod3(base SwigcptrXYZKlass, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_XYZKlass_tMethod3, _swig_p) + return +} + +func (arg1 SwigcptrXYZKlass) TMethod3(arg2 Klass) { + _swig_wrap_XYZKlass_tMethod3(arg1, arg2.Swigcptr()) +} + +var _wrap_XYZKlass_tMethodNotXYZ3 unsafe.Pointer + +func _swig_wrap_XYZKlass_tMethodNotXYZ3(base SwigcptrXYZKlass, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_XYZKlass_tMethodNotXYZ3, _swig_p) + return +} + +func (arg1 SwigcptrXYZKlass) TMethodNotXYZ3(arg2 NotXYZKlass) { + _swig_wrap_XYZKlass_tMethodNotXYZ3(arg1, arg2.Swigcptr()) +} + +var _wrap_XYZKlass_tMethodXYZ3 unsafe.Pointer + +func _swig_wrap_XYZKlass_tMethodXYZ3(base SwigcptrXYZKlass, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_XYZKlass_tMethodXYZ3, _swig_p) + return +} + +func (arg1 SwigcptrXYZKlass) TMethodXYZ3(arg2 XYZKlass) { + _swig_wrap_XYZKlass_tMethodXYZ3(arg1, arg2.Swigcptr()) +} + +var _wrap_XYZKlass_opT3 unsafe.Pointer + +func _swig_wrap_XYZKlass_opT3(base SwigcptrXYZKlass) (_ SwigcptrKlass) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_XYZKlass_opT3, _swig_p) + return +} + +func (arg1 SwigcptrXYZKlass) OpT3() (_swig_ret Klass) { + return _swig_wrap_XYZKlass_opT3(arg1) +} + +var _wrap_XYZKlass_opNotXYZ3 unsafe.Pointer + +func _swig_wrap_XYZKlass_opNotXYZ3(base SwigcptrXYZKlass) (_ SwigcptrNotXYZKlass) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_XYZKlass_opNotXYZ3, _swig_p) + return +} + +func (arg1 SwigcptrXYZKlass) OpNotXYZ3() (_swig_ret NotXYZKlass) { + return _swig_wrap_XYZKlass_opNotXYZ3(arg1) +} + +var _wrap_XYZKlass_opXYZ3 unsafe.Pointer + +func _swig_wrap_XYZKlass_opXYZ3(base SwigcptrXYZKlass) (_ SwigcptrXYZKlass) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_XYZKlass_opXYZ3, _swig_p) + return +} + +func (arg1 SwigcptrXYZKlass) OpXYZ3() (_swig_ret XYZKlass) { + return _swig_wrap_XYZKlass_opXYZ3(arg1) +} + +var _wrap_new_XYZKlass unsafe.Pointer + +func _swig_wrap_new_XYZKlass() (base SwigcptrXYZKlass) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_XYZKlass, _swig_p) + return +} + +func NewXYZKlass() (_swig_ret XYZKlass) { + return _swig_wrap_new_XYZKlass() +} + +var _wrap_delete_XYZKlass unsafe.Pointer + +func _swig_wrap_delete_XYZKlass(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_XYZKlass, _swig_p) + return +} + +func DeleteXYZKlass(arg1 XYZKlass) { + _swig_wrap_delete_XYZKlass(arg1.Swigcptr()) +} + +type XYZKlass interface { + Swigcptr() uintptr + SwigIsXYZKlass() + OpIntPtrA() (_swig_ret NotXYZInt) + OpIntPtrB() (_swig_ret XYZInt) + OpAnother3() (_swig_ret Another) + TMethod3(arg2 Klass) + TMethodNotXYZ3(arg2 NotXYZKlass) + TMethodXYZ3(arg2 XYZKlass) + OpT3() (_swig_ret Klass) + OpNotXYZ3() (_swig_ret NotXYZKlass) + OpXYZ3() (_swig_ret XYZKlass) +} + +type SwigcptrXYZEnu uintptr + +func (p SwigcptrXYZEnu) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrXYZEnu) SwigIsXYZEnu() { +} + +var _wrap_XYZEnu_opIntPtrA unsafe.Pointer + +func _swig_wrap_XYZEnu_opIntPtrA(base SwigcptrXYZEnu) (_ SwigcptrNotXYZInt) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_XYZEnu_opIntPtrA, _swig_p) + return +} + +func (arg1 SwigcptrXYZEnu) OpIntPtrA() (_swig_ret NotXYZInt) { + return _swig_wrap_XYZEnu_opIntPtrA(arg1) +} + +var _wrap_XYZEnu_opIntPtrB unsafe.Pointer + +func _swig_wrap_XYZEnu_opIntPtrB(base SwigcptrXYZEnu) (_ SwigcptrXYZInt) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_XYZEnu_opIntPtrB, _swig_p) + return +} + +func (arg1 SwigcptrXYZEnu) OpIntPtrB() (_swig_ret XYZInt) { + return _swig_wrap_XYZEnu_opIntPtrB(arg1) +} + +var _wrap_XYZEnu_opAnother4 unsafe.Pointer + +func _swig_wrap_XYZEnu_opAnother4(base SwigcptrXYZEnu) (_ SwigcptrAnother) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_XYZEnu_opAnother4, _swig_p) + return +} + +func (arg1 SwigcptrXYZEnu) OpAnother4() (_swig_ret Another) { + return _swig_wrap_XYZEnu_opAnother4(arg1) +} + +var _wrap_XYZEnu_tMethod4 unsafe.Pointer + +func _swig_wrap_XYZEnu_tMethod4(base SwigcptrXYZEnu, _ SpaceEnu) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_XYZEnu_tMethod4, _swig_p) + return +} + +func (arg1 SwigcptrXYZEnu) TMethod4(arg2 SpaceEnu) { + _swig_wrap_XYZEnu_tMethod4(arg1, arg2) +} + +var _wrap_XYZEnu_tMethodNotXYZ4 unsafe.Pointer + +func _swig_wrap_XYZEnu_tMethodNotXYZ4(base SwigcptrXYZEnu, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_XYZEnu_tMethodNotXYZ4, _swig_p) + return +} + +func (arg1 SwigcptrXYZEnu) TMethodNotXYZ4(arg2 NotXYZEnu) { + _swig_wrap_XYZEnu_tMethodNotXYZ4(arg1, arg2.Swigcptr()) +} + +var _wrap_XYZEnu_tMethodXYZ4 unsafe.Pointer + +func _swig_wrap_XYZEnu_tMethodXYZ4(base SwigcptrXYZEnu, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_XYZEnu_tMethodXYZ4, _swig_p) + return +} + +func (arg1 SwigcptrXYZEnu) TMethodXYZ4(arg2 XYZEnu) { + _swig_wrap_XYZEnu_tMethodXYZ4(arg1, arg2.Swigcptr()) +} + +var _wrap_XYZEnu_opT4 unsafe.Pointer + +func _swig_wrap_XYZEnu_opT4(base SwigcptrXYZEnu) (_ SpaceEnu) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_XYZEnu_opT4, _swig_p) + return +} + +func (arg1 SwigcptrXYZEnu) OpT4() (_swig_ret SpaceEnu) { + return _swig_wrap_XYZEnu_opT4(arg1) +} + +var _wrap_XYZEnu_opNotXYZ4 unsafe.Pointer + +func _swig_wrap_XYZEnu_opNotXYZ4(base SwigcptrXYZEnu) (_ SwigcptrNotXYZEnu) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_XYZEnu_opNotXYZ4, _swig_p) + return +} + +func (arg1 SwigcptrXYZEnu) OpNotXYZ4() (_swig_ret NotXYZEnu) { + return _swig_wrap_XYZEnu_opNotXYZ4(arg1) +} + +var _wrap_XYZEnu_opXYZ4 unsafe.Pointer + +func _swig_wrap_XYZEnu_opXYZ4(base SwigcptrXYZEnu) (_ SwigcptrXYZEnu) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_XYZEnu_opXYZ4, _swig_p) + return +} + +func (arg1 SwigcptrXYZEnu) OpXYZ4() (_swig_ret XYZEnu) { + return _swig_wrap_XYZEnu_opXYZ4(arg1) +} + +var _wrap_new_XYZEnu unsafe.Pointer + +func _swig_wrap_new_XYZEnu() (base SwigcptrXYZEnu) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_XYZEnu, _swig_p) + return +} + +func NewXYZEnu() (_swig_ret XYZEnu) { + return _swig_wrap_new_XYZEnu() +} + +var _wrap_delete_XYZEnu unsafe.Pointer + +func _swig_wrap_delete_XYZEnu(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_XYZEnu, _swig_p) + return +} + +func DeleteXYZEnu(arg1 XYZEnu) { + _swig_wrap_delete_XYZEnu(arg1.Swigcptr()) +} + +type XYZEnu interface { + Swigcptr() uintptr + SwigIsXYZEnu() + OpIntPtrA() (_swig_ret NotXYZInt) + OpIntPtrB() (_swig_ret XYZInt) + OpAnother4() (_swig_ret Another) + TMethod4(arg2 SpaceEnu) + TMethodNotXYZ4(arg2 NotXYZEnu) + TMethodXYZ4(arg2 XYZEnu) + OpT4() (_swig_ret SpaceEnu) + OpNotXYZ4() (_swig_ret NotXYZEnu) + OpXYZ4() (_swig_ret XYZEnu) +} + +type SwigcptrNotXYZInt uintptr + +func (p SwigcptrNotXYZInt) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrNotXYZInt) SwigIsNotXYZInt() { +} + +var _wrap_new_NotXYZInt unsafe.Pointer + +func _swig_wrap_new_NotXYZInt() (base SwigcptrNotXYZInt) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_NotXYZInt, _swig_p) + return +} + +func NewNotXYZInt() (_swig_ret NotXYZInt) { + return _swig_wrap_new_NotXYZInt() +} + +var _wrap_delete_NotXYZInt unsafe.Pointer + +func _swig_wrap_delete_NotXYZInt(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_NotXYZInt, _swig_p) + return +} + +func DeleteNotXYZInt(arg1 NotXYZInt) { + _swig_wrap_delete_NotXYZInt(arg1.Swigcptr()) +} + +type NotXYZInt interface { + Swigcptr() uintptr + SwigIsNotXYZInt() +} + +type SwigcptrNotXYZDouble uintptr + +func (p SwigcptrNotXYZDouble) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrNotXYZDouble) SwigIsNotXYZDouble() { +} + +var _wrap_new_NotXYZDouble unsafe.Pointer + +func _swig_wrap_new_NotXYZDouble() (base SwigcptrNotXYZDouble) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_NotXYZDouble, _swig_p) + return +} + +func NewNotXYZDouble() (_swig_ret NotXYZDouble) { + return _swig_wrap_new_NotXYZDouble() +} + +var _wrap_delete_NotXYZDouble unsafe.Pointer + +func _swig_wrap_delete_NotXYZDouble(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_NotXYZDouble, _swig_p) + return +} + +func DeleteNotXYZDouble(arg1 NotXYZDouble) { + _swig_wrap_delete_NotXYZDouble(arg1.Swigcptr()) +} + +type NotXYZDouble interface { + Swigcptr() uintptr + SwigIsNotXYZDouble() +} + +type SwigcptrNotXYZKlass uintptr + +func (p SwigcptrNotXYZKlass) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrNotXYZKlass) SwigIsNotXYZKlass() { +} + +var _wrap_new_NotXYZKlass unsafe.Pointer + +func _swig_wrap_new_NotXYZKlass() (base SwigcptrNotXYZKlass) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_NotXYZKlass, _swig_p) + return +} + +func NewNotXYZKlass() (_swig_ret NotXYZKlass) { + return _swig_wrap_new_NotXYZKlass() +} + +var _wrap_delete_NotXYZKlass unsafe.Pointer + +func _swig_wrap_delete_NotXYZKlass(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_NotXYZKlass, _swig_p) + return +} + +func DeleteNotXYZKlass(arg1 NotXYZKlass) { + _swig_wrap_delete_NotXYZKlass(arg1.Swigcptr()) +} + +type NotXYZKlass interface { + Swigcptr() uintptr + SwigIsNotXYZKlass() +} + +type SwigcptrNotXYZEnu uintptr + +func (p SwigcptrNotXYZEnu) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrNotXYZEnu) SwigIsNotXYZEnu() { +} + +var _wrap_new_NotXYZEnu unsafe.Pointer + +func _swig_wrap_new_NotXYZEnu() (base SwigcptrNotXYZEnu) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_NotXYZEnu, _swig_p) + return +} + +func NewNotXYZEnu() (_swig_ret NotXYZEnu) { + return _swig_wrap_new_NotXYZEnu() +} + +var _wrap_delete_NotXYZEnu unsafe.Pointer + +func _swig_wrap_delete_NotXYZEnu(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_NotXYZEnu, _swig_p) + return +} + +func DeleteNotXYZEnu(arg1 NotXYZEnu) { + _swig_wrap_delete_NotXYZEnu(arg1.Swigcptr()) +} + +type NotXYZEnu interface { + Swigcptr() uintptr + SwigIsNotXYZEnu() +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/rename3.go b/Examples/test-suite/go/rename3.go new file mode 100644 index 000000000..ff8bcf360 --- /dev/null +++ b/Examples/test-suite/go/rename3.go @@ -0,0 +1,1023 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../rename3.i + +package rename3 + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrKlass uintptr + +func (p SwigcptrKlass) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrKlass) SwigIsKlass() { +} + +var _wrap_new_Klass__SWIG_0 unsafe.Pointer + +func _swig_wrap_new_Klass__SWIG_0(base int) (_ SwigcptrKlass) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Klass__SWIG_0, _swig_p) + return +} + +func NewKlass__SWIG_0(arg1 int) (_swig_ret Klass) { + return _swig_wrap_new_Klass__SWIG_0(arg1) +} + +var _wrap_new_Klass__SWIG_1 unsafe.Pointer + +func _swig_wrap_new_Klass__SWIG_1() (base SwigcptrKlass) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Klass__SWIG_1, _swig_p) + return +} + +func NewKlass__SWIG_1() (_swig_ret Klass) { + return _swig_wrap_new_Klass__SWIG_1() +} + +func NewKlass(a ...interface{}) Klass { + argc := len(a) + if argc == 0 { + return NewKlass__SWIG_1() + } + if argc == 1 { + return NewKlass__SWIG_0(a[0].(int)) + } + panic("No match for overloaded function call") +} + +var _wrap_delete_Klass unsafe.Pointer + +func _swig_wrap_delete_Klass(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Klass, _swig_p) + return +} + +func DeleteKlass(arg1 Klass) { + _swig_wrap_delete_Klass(arg1.Swigcptr()) +} + +type Klass interface { + Swigcptr() uintptr + SwigIsKlass() +} + +type SwigcptrAnother uintptr + +func (p SwigcptrAnother) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrAnother) SwigIsAnother() { +} + +var _wrap_new_Another unsafe.Pointer + +func _swig_wrap_new_Another() (base SwigcptrAnother) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Another, _swig_p) + return +} + +func NewAnother() (_swig_ret Another) { + return _swig_wrap_new_Another() +} + +var _wrap_delete_Another unsafe.Pointer + +func _swig_wrap_delete_Another(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Another, _swig_p) + return +} + +func DeleteAnother(arg1 Another) { + _swig_wrap_delete_Another(arg1.Swigcptr()) +} + +type Another interface { + Swigcptr() uintptr + SwigIsAnother() +} + +type SpaceEnu int +var _wrap_En1 unsafe.Pointer + +func _swig_getEn1() (_swig_ret SpaceEnu) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_En1, _swig_p) + return +} +var En1 SpaceEnu = _swig_getEn1() +var _wrap_En2 unsafe.Pointer + +func _swig_getEn2() (_swig_ret SpaceEnu) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_En2, _swig_p) + return +} +var En2 SpaceEnu = _swig_getEn2() +var _wrap_En3 unsafe.Pointer + +func _swig_getEn3() (_swig_ret SpaceEnu) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_En3, _swig_p) + return +} +var En3 SpaceEnu = _swig_getEn3() +type SwigcptrABC uintptr + +func (p SwigcptrABC) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrABC) SwigIsABC() { +} + +var _wrap_ABC_methodABC unsafe.Pointer + +func _swig_wrap_ABC_methodABC(base SwigcptrABC, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_ABC_methodABC, _swig_p) + return +} + +func (arg1 SwigcptrABC) MethodABC(arg2 ABC) { + _swig_wrap_ABC_methodABC(arg1, arg2.Swigcptr()) +} + +var _wrap_ABC_methodKlass unsafe.Pointer + +func _swig_wrap_ABC_methodKlass(base SwigcptrABC, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_ABC_methodKlass, _swig_p) + return +} + +func (arg1 SwigcptrABC) MethodKlass(arg2 Klass) { + _swig_wrap_ABC_methodKlass(arg1, arg2.Swigcptr()) +} + +var _wrap_ABC_opABC unsafe.Pointer + +func _swig_wrap_ABC_opABC(base SwigcptrABC) (_ SwigcptrABC) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_ABC_opABC, _swig_p) + return +} + +func (arg1 SwigcptrABC) OpABC() (_swig_ret ABC) { + return _swig_wrap_ABC_opABC(arg1) +} + +var _wrap_ABC_opKlass unsafe.Pointer + +func _swig_wrap_ABC_opKlass(base SwigcptrABC) (_ SwigcptrKlass) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_ABC_opKlass, _swig_p) + return +} + +func (arg1 SwigcptrABC) OpKlass() (_swig_ret Klass) { + return _swig_wrap_ABC_opKlass(arg1) +} + +var _wrap_new_ABC unsafe.Pointer + +func _swig_wrap_new_ABC() (base SwigcptrABC) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_ABC, _swig_p) + return +} + +func NewABC() (_swig_ret ABC) { + return _swig_wrap_new_ABC() +} + +var _wrap_delete_ABC unsafe.Pointer + +func _swig_wrap_delete_ABC(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_ABC, _swig_p) + return +} + +func DeleteABC(arg1 ABC) { + _swig_wrap_delete_ABC(arg1.Swigcptr()) +} + +type ABC interface { + Swigcptr() uintptr + SwigIsABC() + MethodABC(arg2 ABC) + MethodKlass(arg2 Klass) + OpABC() (_swig_ret ABC) + OpKlass() (_swig_ret Klass) +} + +type SwigcptrXYZInt uintptr + +func (p SwigcptrXYZInt) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrXYZInt) SwigIsXYZInt() { +} + +var _wrap_XYZInt_opIntPtrA unsafe.Pointer + +func _swig_wrap_XYZInt_opIntPtrA(base SwigcptrXYZInt) (_ SwigcptrNotXYZInt) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_XYZInt_opIntPtrA, _swig_p) + return +} + +func (arg1 SwigcptrXYZInt) OpIntPtrA() (_swig_ret NotXYZInt) { + return _swig_wrap_XYZInt_opIntPtrA(arg1) +} + +var _wrap_XYZInt_opIntPtrB unsafe.Pointer + +func _swig_wrap_XYZInt_opIntPtrB(base SwigcptrXYZInt) (_ SwigcptrXYZInt) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_XYZInt_opIntPtrB, _swig_p) + return +} + +func (arg1 SwigcptrXYZInt) OpIntPtrB() (_swig_ret XYZInt) { + return _swig_wrap_XYZInt_opIntPtrB(arg1) +} + +var _wrap_XYZInt_opAnother2 unsafe.Pointer + +func _swig_wrap_XYZInt_opAnother2(base SwigcptrXYZInt) (_ SwigcptrAnother) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_XYZInt_opAnother2, _swig_p) + return +} + +func (arg1 SwigcptrXYZInt) OpAnother2() (_swig_ret Another) { + return _swig_wrap_XYZInt_opAnother2(arg1) +} + +var _wrap_XYZInt_tMethod2 unsafe.Pointer + +func _swig_wrap_XYZInt_tMethod2(base SwigcptrXYZInt, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_XYZInt_tMethod2, _swig_p) + return +} + +func (arg1 SwigcptrXYZInt) TMethod2(arg2 int) { + _swig_wrap_XYZInt_tMethod2(arg1, arg2) +} + +var _wrap_XYZInt_tMethodNotXYZ2 unsafe.Pointer + +func _swig_wrap_XYZInt_tMethodNotXYZ2(base SwigcptrXYZInt, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_XYZInt_tMethodNotXYZ2, _swig_p) + return +} + +func (arg1 SwigcptrXYZInt) TMethodNotXYZ2(arg2 NotXYZInt) { + _swig_wrap_XYZInt_tMethodNotXYZ2(arg1, arg2.Swigcptr()) +} + +var _wrap_XYZInt_tMethodXYZ2 unsafe.Pointer + +func _swig_wrap_XYZInt_tMethodXYZ2(base SwigcptrXYZInt, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_XYZInt_tMethodXYZ2, _swig_p) + return +} + +func (arg1 SwigcptrXYZInt) TMethodXYZ2(arg2 XYZInt) { + _swig_wrap_XYZInt_tMethodXYZ2(arg1, arg2.Swigcptr()) +} + +var _wrap_XYZInt_opT2 unsafe.Pointer + +func _swig_wrap_XYZInt_opT2(base SwigcptrXYZInt) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_XYZInt_opT2, _swig_p) + return +} + +func (arg1 SwigcptrXYZInt) OpT2() (_swig_ret int) { + return _swig_wrap_XYZInt_opT2(arg1) +} + +var _wrap_XYZInt_opNotXYZ2 unsafe.Pointer + +func _swig_wrap_XYZInt_opNotXYZ2(base SwigcptrXYZInt) (_ SwigcptrNotXYZInt) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_XYZInt_opNotXYZ2, _swig_p) + return +} + +func (arg1 SwigcptrXYZInt) OpNotXYZ2() (_swig_ret NotXYZInt) { + return _swig_wrap_XYZInt_opNotXYZ2(arg1) +} + +var _wrap_XYZInt_opXYZ2 unsafe.Pointer + +func _swig_wrap_XYZInt_opXYZ2(base SwigcptrXYZInt) (_ SwigcptrXYZInt) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_XYZInt_opXYZ2, _swig_p) + return +} + +func (arg1 SwigcptrXYZInt) OpXYZ2() (_swig_ret XYZInt) { + return _swig_wrap_XYZInt_opXYZ2(arg1) +} + +var _wrap_new_XYZInt unsafe.Pointer + +func _swig_wrap_new_XYZInt() (base SwigcptrXYZInt) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_XYZInt, _swig_p) + return +} + +func NewXYZInt() (_swig_ret XYZInt) { + return _swig_wrap_new_XYZInt() +} + +var _wrap_delete_XYZInt unsafe.Pointer + +func _swig_wrap_delete_XYZInt(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_XYZInt, _swig_p) + return +} + +func DeleteXYZInt(arg1 XYZInt) { + _swig_wrap_delete_XYZInt(arg1.Swigcptr()) +} + +type XYZInt interface { + Swigcptr() uintptr + SwigIsXYZInt() + OpIntPtrA() (_swig_ret NotXYZInt) + OpIntPtrB() (_swig_ret XYZInt) + OpAnother2() (_swig_ret Another) + TMethod2(arg2 int) + TMethodNotXYZ2(arg2 NotXYZInt) + TMethodXYZ2(arg2 XYZInt) + OpT2() (_swig_ret int) + OpNotXYZ2() (_swig_ret NotXYZInt) + OpXYZ2() (_swig_ret XYZInt) +} + +type SwigcptrXYZDouble uintptr + +func (p SwigcptrXYZDouble) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrXYZDouble) SwigIsXYZDouble() { +} + +var _wrap_XYZDouble_opIntPtrA unsafe.Pointer + +func _swig_wrap_XYZDouble_opIntPtrA(base SwigcptrXYZDouble) (_ SwigcptrNotXYZInt) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_XYZDouble_opIntPtrA, _swig_p) + return +} + +func (arg1 SwigcptrXYZDouble) OpIntPtrA() (_swig_ret NotXYZInt) { + return _swig_wrap_XYZDouble_opIntPtrA(arg1) +} + +var _wrap_XYZDouble_opIntPtrB unsafe.Pointer + +func _swig_wrap_XYZDouble_opIntPtrB(base SwigcptrXYZDouble) (_ SwigcptrXYZInt) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_XYZDouble_opIntPtrB, _swig_p) + return +} + +func (arg1 SwigcptrXYZDouble) OpIntPtrB() (_swig_ret XYZInt) { + return _swig_wrap_XYZDouble_opIntPtrB(arg1) +} + +var _wrap_XYZDouble_opAnother1 unsafe.Pointer + +func _swig_wrap_XYZDouble_opAnother1(base SwigcptrXYZDouble) (_ SwigcptrAnother) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_XYZDouble_opAnother1, _swig_p) + return +} + +func (arg1 SwigcptrXYZDouble) OpAnother1() (_swig_ret Another) { + return _swig_wrap_XYZDouble_opAnother1(arg1) +} + +var _wrap_XYZDouble_tMethod1 unsafe.Pointer + +func _swig_wrap_XYZDouble_tMethod1(base SwigcptrXYZDouble, _ float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_XYZDouble_tMethod1, _swig_p) + return +} + +func (arg1 SwigcptrXYZDouble) TMethod1(arg2 float64) { + _swig_wrap_XYZDouble_tMethod1(arg1, arg2) +} + +var _wrap_XYZDouble_tMethodNotXYZ1 unsafe.Pointer + +func _swig_wrap_XYZDouble_tMethodNotXYZ1(base SwigcptrXYZDouble, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_XYZDouble_tMethodNotXYZ1, _swig_p) + return +} + +func (arg1 SwigcptrXYZDouble) TMethodNotXYZ1(arg2 NotXYZDouble) { + _swig_wrap_XYZDouble_tMethodNotXYZ1(arg1, arg2.Swigcptr()) +} + +var _wrap_XYZDouble_tMethodXYZ1 unsafe.Pointer + +func _swig_wrap_XYZDouble_tMethodXYZ1(base SwigcptrXYZDouble, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_XYZDouble_tMethodXYZ1, _swig_p) + return +} + +func (arg1 SwigcptrXYZDouble) TMethodXYZ1(arg2 XYZDouble) { + _swig_wrap_XYZDouble_tMethodXYZ1(arg1, arg2.Swigcptr()) +} + +var _wrap_XYZDouble_opT1 unsafe.Pointer + +func _swig_wrap_XYZDouble_opT1(base SwigcptrXYZDouble) (_ float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_XYZDouble_opT1, _swig_p) + return +} + +func (arg1 SwigcptrXYZDouble) OpT1() (_swig_ret float64) { + return _swig_wrap_XYZDouble_opT1(arg1) +} + +var _wrap_XYZDouble_opNotXYZ1 unsafe.Pointer + +func _swig_wrap_XYZDouble_opNotXYZ1(base SwigcptrXYZDouble) (_ SwigcptrNotXYZDouble) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_XYZDouble_opNotXYZ1, _swig_p) + return +} + +func (arg1 SwigcptrXYZDouble) OpNotXYZ1() (_swig_ret NotXYZDouble) { + return _swig_wrap_XYZDouble_opNotXYZ1(arg1) +} + +var _wrap_XYZDouble_opXYZ1 unsafe.Pointer + +func _swig_wrap_XYZDouble_opXYZ1(base SwigcptrXYZDouble) (_ SwigcptrXYZDouble) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_XYZDouble_opXYZ1, _swig_p) + return +} + +func (arg1 SwigcptrXYZDouble) OpXYZ1() (_swig_ret XYZDouble) { + return _swig_wrap_XYZDouble_opXYZ1(arg1) +} + +var _wrap_new_XYZDouble unsafe.Pointer + +func _swig_wrap_new_XYZDouble() (base SwigcptrXYZDouble) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_XYZDouble, _swig_p) + return +} + +func NewXYZDouble() (_swig_ret XYZDouble) { + return _swig_wrap_new_XYZDouble() +} + +var _wrap_delete_XYZDouble unsafe.Pointer + +func _swig_wrap_delete_XYZDouble(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_XYZDouble, _swig_p) + return +} + +func DeleteXYZDouble(arg1 XYZDouble) { + _swig_wrap_delete_XYZDouble(arg1.Swigcptr()) +} + +type XYZDouble interface { + Swigcptr() uintptr + SwigIsXYZDouble() + OpIntPtrA() (_swig_ret NotXYZInt) + OpIntPtrB() (_swig_ret XYZInt) + OpAnother1() (_swig_ret Another) + TMethod1(arg2 float64) + TMethodNotXYZ1(arg2 NotXYZDouble) + TMethodXYZ1(arg2 XYZDouble) + OpT1() (_swig_ret float64) + OpNotXYZ1() (_swig_ret NotXYZDouble) + OpXYZ1() (_swig_ret XYZDouble) +} + +type SwigcptrXYZKlass uintptr + +func (p SwigcptrXYZKlass) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrXYZKlass) SwigIsXYZKlass() { +} + +var _wrap_XYZKlass_opIntPtrA unsafe.Pointer + +func _swig_wrap_XYZKlass_opIntPtrA(base SwigcptrXYZKlass) (_ SwigcptrNotXYZInt) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_XYZKlass_opIntPtrA, _swig_p) + return +} + +func (arg1 SwigcptrXYZKlass) OpIntPtrA() (_swig_ret NotXYZInt) { + return _swig_wrap_XYZKlass_opIntPtrA(arg1) +} + +var _wrap_XYZKlass_opIntPtrB unsafe.Pointer + +func _swig_wrap_XYZKlass_opIntPtrB(base SwigcptrXYZKlass) (_ SwigcptrXYZInt) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_XYZKlass_opIntPtrB, _swig_p) + return +} + +func (arg1 SwigcptrXYZKlass) OpIntPtrB() (_swig_ret XYZInt) { + return _swig_wrap_XYZKlass_opIntPtrB(arg1) +} + +var _wrap_XYZKlass_opAnother3 unsafe.Pointer + +func _swig_wrap_XYZKlass_opAnother3(base SwigcptrXYZKlass) (_ SwigcptrAnother) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_XYZKlass_opAnother3, _swig_p) + return +} + +func (arg1 SwigcptrXYZKlass) OpAnother3() (_swig_ret Another) { + return _swig_wrap_XYZKlass_opAnother3(arg1) +} + +var _wrap_XYZKlass_tMethod3 unsafe.Pointer + +func _swig_wrap_XYZKlass_tMethod3(base SwigcptrXYZKlass, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_XYZKlass_tMethod3, _swig_p) + return +} + +func (arg1 SwigcptrXYZKlass) TMethod3(arg2 Klass) { + _swig_wrap_XYZKlass_tMethod3(arg1, arg2.Swigcptr()) +} + +var _wrap_XYZKlass_tMethodNotXYZ3 unsafe.Pointer + +func _swig_wrap_XYZKlass_tMethodNotXYZ3(base SwigcptrXYZKlass, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_XYZKlass_tMethodNotXYZ3, _swig_p) + return +} + +func (arg1 SwigcptrXYZKlass) TMethodNotXYZ3(arg2 NotXYZKlass) { + _swig_wrap_XYZKlass_tMethodNotXYZ3(arg1, arg2.Swigcptr()) +} + +var _wrap_XYZKlass_tMethodXYZ3 unsafe.Pointer + +func _swig_wrap_XYZKlass_tMethodXYZ3(base SwigcptrXYZKlass, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_XYZKlass_tMethodXYZ3, _swig_p) + return +} + +func (arg1 SwigcptrXYZKlass) TMethodXYZ3(arg2 XYZKlass) { + _swig_wrap_XYZKlass_tMethodXYZ3(arg1, arg2.Swigcptr()) +} + +var _wrap_XYZKlass_opT3 unsafe.Pointer + +func _swig_wrap_XYZKlass_opT3(base SwigcptrXYZKlass) (_ SwigcptrKlass) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_XYZKlass_opT3, _swig_p) + return +} + +func (arg1 SwigcptrXYZKlass) OpT3() (_swig_ret Klass) { + return _swig_wrap_XYZKlass_opT3(arg1) +} + +var _wrap_XYZKlass_opNotXYZ3 unsafe.Pointer + +func _swig_wrap_XYZKlass_opNotXYZ3(base SwigcptrXYZKlass) (_ SwigcptrNotXYZKlass) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_XYZKlass_opNotXYZ3, _swig_p) + return +} + +func (arg1 SwigcptrXYZKlass) OpNotXYZ3() (_swig_ret NotXYZKlass) { + return _swig_wrap_XYZKlass_opNotXYZ3(arg1) +} + +var _wrap_XYZKlass_opXYZ3 unsafe.Pointer + +func _swig_wrap_XYZKlass_opXYZ3(base SwigcptrXYZKlass) (_ SwigcptrXYZKlass) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_XYZKlass_opXYZ3, _swig_p) + return +} + +func (arg1 SwigcptrXYZKlass) OpXYZ3() (_swig_ret XYZKlass) { + return _swig_wrap_XYZKlass_opXYZ3(arg1) +} + +var _wrap_new_XYZKlass unsafe.Pointer + +func _swig_wrap_new_XYZKlass() (base SwigcptrXYZKlass) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_XYZKlass, _swig_p) + return +} + +func NewXYZKlass() (_swig_ret XYZKlass) { + return _swig_wrap_new_XYZKlass() +} + +var _wrap_delete_XYZKlass unsafe.Pointer + +func _swig_wrap_delete_XYZKlass(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_XYZKlass, _swig_p) + return +} + +func DeleteXYZKlass(arg1 XYZKlass) { + _swig_wrap_delete_XYZKlass(arg1.Swigcptr()) +} + +type XYZKlass interface { + Swigcptr() uintptr + SwigIsXYZKlass() + OpIntPtrA() (_swig_ret NotXYZInt) + OpIntPtrB() (_swig_ret XYZInt) + OpAnother3() (_swig_ret Another) + TMethod3(arg2 Klass) + TMethodNotXYZ3(arg2 NotXYZKlass) + TMethodXYZ3(arg2 XYZKlass) + OpT3() (_swig_ret Klass) + OpNotXYZ3() (_swig_ret NotXYZKlass) + OpXYZ3() (_swig_ret XYZKlass) +} + +type SwigcptrXYZEnu uintptr + +func (p SwigcptrXYZEnu) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrXYZEnu) SwigIsXYZEnu() { +} + +var _wrap_XYZEnu_opIntPtrA unsafe.Pointer + +func _swig_wrap_XYZEnu_opIntPtrA(base SwigcptrXYZEnu) (_ SwigcptrNotXYZInt) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_XYZEnu_opIntPtrA, _swig_p) + return +} + +func (arg1 SwigcptrXYZEnu) OpIntPtrA() (_swig_ret NotXYZInt) { + return _swig_wrap_XYZEnu_opIntPtrA(arg1) +} + +var _wrap_XYZEnu_opIntPtrB unsafe.Pointer + +func _swig_wrap_XYZEnu_opIntPtrB(base SwigcptrXYZEnu) (_ SwigcptrXYZInt) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_XYZEnu_opIntPtrB, _swig_p) + return +} + +func (arg1 SwigcptrXYZEnu) OpIntPtrB() (_swig_ret XYZInt) { + return _swig_wrap_XYZEnu_opIntPtrB(arg1) +} + +var _wrap_XYZEnu_opAnother4 unsafe.Pointer + +func _swig_wrap_XYZEnu_opAnother4(base SwigcptrXYZEnu) (_ SwigcptrAnother) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_XYZEnu_opAnother4, _swig_p) + return +} + +func (arg1 SwigcptrXYZEnu) OpAnother4() (_swig_ret Another) { + return _swig_wrap_XYZEnu_opAnother4(arg1) +} + +var _wrap_XYZEnu_tMethod4 unsafe.Pointer + +func _swig_wrap_XYZEnu_tMethod4(base SwigcptrXYZEnu, _ SpaceEnu) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_XYZEnu_tMethod4, _swig_p) + return +} + +func (arg1 SwigcptrXYZEnu) TMethod4(arg2 SpaceEnu) { + _swig_wrap_XYZEnu_tMethod4(arg1, arg2) +} + +var _wrap_XYZEnu_tMethodNotXYZ4 unsafe.Pointer + +func _swig_wrap_XYZEnu_tMethodNotXYZ4(base SwigcptrXYZEnu, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_XYZEnu_tMethodNotXYZ4, _swig_p) + return +} + +func (arg1 SwigcptrXYZEnu) TMethodNotXYZ4(arg2 NotXYZEnu) { + _swig_wrap_XYZEnu_tMethodNotXYZ4(arg1, arg2.Swigcptr()) +} + +var _wrap_XYZEnu_tMethodXYZ4 unsafe.Pointer + +func _swig_wrap_XYZEnu_tMethodXYZ4(base SwigcptrXYZEnu, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_XYZEnu_tMethodXYZ4, _swig_p) + return +} + +func (arg1 SwigcptrXYZEnu) TMethodXYZ4(arg2 XYZEnu) { + _swig_wrap_XYZEnu_tMethodXYZ4(arg1, arg2.Swigcptr()) +} + +var _wrap_XYZEnu_opT4 unsafe.Pointer + +func _swig_wrap_XYZEnu_opT4(base SwigcptrXYZEnu) (_ SpaceEnu) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_XYZEnu_opT4, _swig_p) + return +} + +func (arg1 SwigcptrXYZEnu) OpT4() (_swig_ret SpaceEnu) { + return _swig_wrap_XYZEnu_opT4(arg1) +} + +var _wrap_XYZEnu_opNotXYZ4 unsafe.Pointer + +func _swig_wrap_XYZEnu_opNotXYZ4(base SwigcptrXYZEnu) (_ SwigcptrNotXYZEnu) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_XYZEnu_opNotXYZ4, _swig_p) + return +} + +func (arg1 SwigcptrXYZEnu) OpNotXYZ4() (_swig_ret NotXYZEnu) { + return _swig_wrap_XYZEnu_opNotXYZ4(arg1) +} + +var _wrap_XYZEnu_opXYZ4 unsafe.Pointer + +func _swig_wrap_XYZEnu_opXYZ4(base SwigcptrXYZEnu) (_ SwigcptrXYZEnu) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_XYZEnu_opXYZ4, _swig_p) + return +} + +func (arg1 SwigcptrXYZEnu) OpXYZ4() (_swig_ret XYZEnu) { + return _swig_wrap_XYZEnu_opXYZ4(arg1) +} + +var _wrap_new_XYZEnu unsafe.Pointer + +func _swig_wrap_new_XYZEnu() (base SwigcptrXYZEnu) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_XYZEnu, _swig_p) + return +} + +func NewXYZEnu() (_swig_ret XYZEnu) { + return _swig_wrap_new_XYZEnu() +} + +var _wrap_delete_XYZEnu unsafe.Pointer + +func _swig_wrap_delete_XYZEnu(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_XYZEnu, _swig_p) + return +} + +func DeleteXYZEnu(arg1 XYZEnu) { + _swig_wrap_delete_XYZEnu(arg1.Swigcptr()) +} + +type XYZEnu interface { + Swigcptr() uintptr + SwigIsXYZEnu() + OpIntPtrA() (_swig_ret NotXYZInt) + OpIntPtrB() (_swig_ret XYZInt) + OpAnother4() (_swig_ret Another) + TMethod4(arg2 SpaceEnu) + TMethodNotXYZ4(arg2 NotXYZEnu) + TMethodXYZ4(arg2 XYZEnu) + OpT4() (_swig_ret SpaceEnu) + OpNotXYZ4() (_swig_ret NotXYZEnu) + OpXYZ4() (_swig_ret XYZEnu) +} + +type SwigcptrNotXYZInt uintptr + +func (p SwigcptrNotXYZInt) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrNotXYZInt) SwigIsNotXYZInt() { +} + +var _wrap_new_NotXYZInt unsafe.Pointer + +func _swig_wrap_new_NotXYZInt() (base SwigcptrNotXYZInt) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_NotXYZInt, _swig_p) + return +} + +func NewNotXYZInt() (_swig_ret NotXYZInt) { + return _swig_wrap_new_NotXYZInt() +} + +var _wrap_delete_NotXYZInt unsafe.Pointer + +func _swig_wrap_delete_NotXYZInt(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_NotXYZInt, _swig_p) + return +} + +func DeleteNotXYZInt(arg1 NotXYZInt) { + _swig_wrap_delete_NotXYZInt(arg1.Swigcptr()) +} + +type NotXYZInt interface { + Swigcptr() uintptr + SwigIsNotXYZInt() +} + +type SwigcptrNotXYZDouble uintptr + +func (p SwigcptrNotXYZDouble) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrNotXYZDouble) SwigIsNotXYZDouble() { +} + +var _wrap_new_NotXYZDouble unsafe.Pointer + +func _swig_wrap_new_NotXYZDouble() (base SwigcptrNotXYZDouble) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_NotXYZDouble, _swig_p) + return +} + +func NewNotXYZDouble() (_swig_ret NotXYZDouble) { + return _swig_wrap_new_NotXYZDouble() +} + +var _wrap_delete_NotXYZDouble unsafe.Pointer + +func _swig_wrap_delete_NotXYZDouble(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_NotXYZDouble, _swig_p) + return +} + +func DeleteNotXYZDouble(arg1 NotXYZDouble) { + _swig_wrap_delete_NotXYZDouble(arg1.Swigcptr()) +} + +type NotXYZDouble interface { + Swigcptr() uintptr + SwigIsNotXYZDouble() +} + +type SwigcptrNotXYZKlass uintptr + +func (p SwigcptrNotXYZKlass) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrNotXYZKlass) SwigIsNotXYZKlass() { +} + +var _wrap_new_NotXYZKlass unsafe.Pointer + +func _swig_wrap_new_NotXYZKlass() (base SwigcptrNotXYZKlass) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_NotXYZKlass, _swig_p) + return +} + +func NewNotXYZKlass() (_swig_ret NotXYZKlass) { + return _swig_wrap_new_NotXYZKlass() +} + +var _wrap_delete_NotXYZKlass unsafe.Pointer + +func _swig_wrap_delete_NotXYZKlass(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_NotXYZKlass, _swig_p) + return +} + +func DeleteNotXYZKlass(arg1 NotXYZKlass) { + _swig_wrap_delete_NotXYZKlass(arg1.Swigcptr()) +} + +type NotXYZKlass interface { + Swigcptr() uintptr + SwigIsNotXYZKlass() +} + +type SwigcptrNotXYZEnu uintptr + +func (p SwigcptrNotXYZEnu) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrNotXYZEnu) SwigIsNotXYZEnu() { +} + +var _wrap_new_NotXYZEnu unsafe.Pointer + +func _swig_wrap_new_NotXYZEnu() (base SwigcptrNotXYZEnu) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_NotXYZEnu, _swig_p) + return +} + +func NewNotXYZEnu() (_swig_ret NotXYZEnu) { + return _swig_wrap_new_NotXYZEnu() +} + +var _wrap_delete_NotXYZEnu unsafe.Pointer + +func _swig_wrap_delete_NotXYZEnu(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_NotXYZEnu, _swig_p) + return +} + +func DeleteNotXYZEnu(arg1 NotXYZEnu) { + _swig_wrap_delete_NotXYZEnu(arg1.Swigcptr()) +} + +type NotXYZEnu interface { + Swigcptr() uintptr + SwigIsNotXYZEnu() +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/rename4.go b/Examples/test-suite/go/rename4.go new file mode 100644 index 000000000..09ffa1f62 --- /dev/null +++ b/Examples/test-suite/go/rename4.go @@ -0,0 +1,1023 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../rename4.i + +package rename4 + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrKlass uintptr + +func (p SwigcptrKlass) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrKlass) SwigIsKlass() { +} + +var _wrap_new_Klass__SWIG_0 unsafe.Pointer + +func _swig_wrap_new_Klass__SWIG_0(base int) (_ SwigcptrKlass) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Klass__SWIG_0, _swig_p) + return +} + +func NewKlass__SWIG_0(arg1 int) (_swig_ret Klass) { + return _swig_wrap_new_Klass__SWIG_0(arg1) +} + +var _wrap_new_Klass__SWIG_1 unsafe.Pointer + +func _swig_wrap_new_Klass__SWIG_1() (base SwigcptrKlass) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Klass__SWIG_1, _swig_p) + return +} + +func NewKlass__SWIG_1() (_swig_ret Klass) { + return _swig_wrap_new_Klass__SWIG_1() +} + +func NewKlass(a ...interface{}) Klass { + argc := len(a) + if argc == 0 { + return NewKlass__SWIG_1() + } + if argc == 1 { + return NewKlass__SWIG_0(a[0].(int)) + } + panic("No match for overloaded function call") +} + +var _wrap_delete_Klass unsafe.Pointer + +func _swig_wrap_delete_Klass(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Klass, _swig_p) + return +} + +func DeleteKlass(arg1 Klass) { + _swig_wrap_delete_Klass(arg1.Swigcptr()) +} + +type Klass interface { + Swigcptr() uintptr + SwigIsKlass() +} + +type SwigcptrAnother uintptr + +func (p SwigcptrAnother) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrAnother) SwigIsAnother() { +} + +var _wrap_new_Another unsafe.Pointer + +func _swig_wrap_new_Another() (base SwigcptrAnother) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Another, _swig_p) + return +} + +func NewAnother() (_swig_ret Another) { + return _swig_wrap_new_Another() +} + +var _wrap_delete_Another unsafe.Pointer + +func _swig_wrap_delete_Another(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Another, _swig_p) + return +} + +func DeleteAnother(arg1 Another) { + _swig_wrap_delete_Another(arg1.Swigcptr()) +} + +type Another interface { + Swigcptr() uintptr + SwigIsAnother() +} + +type SpaceEnu int +var _wrap_En1 unsafe.Pointer + +func _swig_getEn1() (_swig_ret SpaceEnu) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_En1, _swig_p) + return +} +var En1 SpaceEnu = _swig_getEn1() +var _wrap_En2 unsafe.Pointer + +func _swig_getEn2() (_swig_ret SpaceEnu) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_En2, _swig_p) + return +} +var En2 SpaceEnu = _swig_getEn2() +var _wrap_En3 unsafe.Pointer + +func _swig_getEn3() (_swig_ret SpaceEnu) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_En3, _swig_p) + return +} +var En3 SpaceEnu = _swig_getEn3() +type SwigcptrABC uintptr + +func (p SwigcptrABC) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrABC) SwigIsABC() { +} + +var _wrap_ABC_methodABC unsafe.Pointer + +func _swig_wrap_ABC_methodABC(base SwigcptrABC, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_ABC_methodABC, _swig_p) + return +} + +func (arg1 SwigcptrABC) MethodABC(arg2 ABC) { + _swig_wrap_ABC_methodABC(arg1, arg2.Swigcptr()) +} + +var _wrap_ABC_methodKlass unsafe.Pointer + +func _swig_wrap_ABC_methodKlass(base SwigcptrABC, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_ABC_methodKlass, _swig_p) + return +} + +func (arg1 SwigcptrABC) MethodKlass(arg2 Klass) { + _swig_wrap_ABC_methodKlass(arg1, arg2.Swigcptr()) +} + +var _wrap_ABC_opABC unsafe.Pointer + +func _swig_wrap_ABC_opABC(base SwigcptrABC) (_ SwigcptrABC) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_ABC_opABC, _swig_p) + return +} + +func (arg1 SwigcptrABC) OpABC() (_swig_ret ABC) { + return _swig_wrap_ABC_opABC(arg1) +} + +var _wrap_ABC_opKlass unsafe.Pointer + +func _swig_wrap_ABC_opKlass(base SwigcptrABC) (_ SwigcptrKlass) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_ABC_opKlass, _swig_p) + return +} + +func (arg1 SwigcptrABC) OpKlass() (_swig_ret Klass) { + return _swig_wrap_ABC_opKlass(arg1) +} + +var _wrap_new_ABC unsafe.Pointer + +func _swig_wrap_new_ABC() (base SwigcptrABC) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_ABC, _swig_p) + return +} + +func NewABC() (_swig_ret ABC) { + return _swig_wrap_new_ABC() +} + +var _wrap_delete_ABC unsafe.Pointer + +func _swig_wrap_delete_ABC(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_ABC, _swig_p) + return +} + +func DeleteABC(arg1 ABC) { + _swig_wrap_delete_ABC(arg1.Swigcptr()) +} + +type ABC interface { + Swigcptr() uintptr + SwigIsABC() + MethodABC(arg2 ABC) + MethodKlass(arg2 Klass) + OpABC() (_swig_ret ABC) + OpKlass() (_swig_ret Klass) +} + +type SwigcptrXYZInt uintptr + +func (p SwigcptrXYZInt) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrXYZInt) SwigIsXYZInt() { +} + +var _wrap_XYZInt_opIntPtrA unsafe.Pointer + +func _swig_wrap_XYZInt_opIntPtrA(base SwigcptrXYZInt) (_ SwigcptrNotXYZInt) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_XYZInt_opIntPtrA, _swig_p) + return +} + +func (arg1 SwigcptrXYZInt) OpIntPtrA() (_swig_ret NotXYZInt) { + return _swig_wrap_XYZInt_opIntPtrA(arg1) +} + +var _wrap_XYZInt_opIntPtrB unsafe.Pointer + +func _swig_wrap_XYZInt_opIntPtrB(base SwigcptrXYZInt) (_ SwigcptrXYZInt) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_XYZInt_opIntPtrB, _swig_p) + return +} + +func (arg1 SwigcptrXYZInt) OpIntPtrB() (_swig_ret XYZInt) { + return _swig_wrap_XYZInt_opIntPtrB(arg1) +} + +var _wrap_XYZInt_opAnother2 unsafe.Pointer + +func _swig_wrap_XYZInt_opAnother2(base SwigcptrXYZInt) (_ SwigcptrAnother) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_XYZInt_opAnother2, _swig_p) + return +} + +func (arg1 SwigcptrXYZInt) OpAnother2() (_swig_ret Another) { + return _swig_wrap_XYZInt_opAnother2(arg1) +} + +var _wrap_XYZInt_tMethod2 unsafe.Pointer + +func _swig_wrap_XYZInt_tMethod2(base SwigcptrXYZInt, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_XYZInt_tMethod2, _swig_p) + return +} + +func (arg1 SwigcptrXYZInt) TMethod2(arg2 int) { + _swig_wrap_XYZInt_tMethod2(arg1, arg2) +} + +var _wrap_XYZInt_tMethodNotXYZ2 unsafe.Pointer + +func _swig_wrap_XYZInt_tMethodNotXYZ2(base SwigcptrXYZInt, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_XYZInt_tMethodNotXYZ2, _swig_p) + return +} + +func (arg1 SwigcptrXYZInt) TMethodNotXYZ2(arg2 NotXYZInt) { + _swig_wrap_XYZInt_tMethodNotXYZ2(arg1, arg2.Swigcptr()) +} + +var _wrap_XYZInt_tMethodXYZ2 unsafe.Pointer + +func _swig_wrap_XYZInt_tMethodXYZ2(base SwigcptrXYZInt, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_XYZInt_tMethodXYZ2, _swig_p) + return +} + +func (arg1 SwigcptrXYZInt) TMethodXYZ2(arg2 XYZInt) { + _swig_wrap_XYZInt_tMethodXYZ2(arg1, arg2.Swigcptr()) +} + +var _wrap_XYZInt_opT2 unsafe.Pointer + +func _swig_wrap_XYZInt_opT2(base SwigcptrXYZInt) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_XYZInt_opT2, _swig_p) + return +} + +func (arg1 SwigcptrXYZInt) OpT2() (_swig_ret int) { + return _swig_wrap_XYZInt_opT2(arg1) +} + +var _wrap_XYZInt_opNotXYZ2 unsafe.Pointer + +func _swig_wrap_XYZInt_opNotXYZ2(base SwigcptrXYZInt) (_ SwigcptrNotXYZInt) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_XYZInt_opNotXYZ2, _swig_p) + return +} + +func (arg1 SwigcptrXYZInt) OpNotXYZ2() (_swig_ret NotXYZInt) { + return _swig_wrap_XYZInt_opNotXYZ2(arg1) +} + +var _wrap_XYZInt_opXYZ2 unsafe.Pointer + +func _swig_wrap_XYZInt_opXYZ2(base SwigcptrXYZInt) (_ SwigcptrXYZInt) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_XYZInt_opXYZ2, _swig_p) + return +} + +func (arg1 SwigcptrXYZInt) OpXYZ2() (_swig_ret XYZInt) { + return _swig_wrap_XYZInt_opXYZ2(arg1) +} + +var _wrap_new_XYZInt unsafe.Pointer + +func _swig_wrap_new_XYZInt() (base SwigcptrXYZInt) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_XYZInt, _swig_p) + return +} + +func NewXYZInt() (_swig_ret XYZInt) { + return _swig_wrap_new_XYZInt() +} + +var _wrap_delete_XYZInt unsafe.Pointer + +func _swig_wrap_delete_XYZInt(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_XYZInt, _swig_p) + return +} + +func DeleteXYZInt(arg1 XYZInt) { + _swig_wrap_delete_XYZInt(arg1.Swigcptr()) +} + +type XYZInt interface { + Swigcptr() uintptr + SwigIsXYZInt() + OpIntPtrA() (_swig_ret NotXYZInt) + OpIntPtrB() (_swig_ret XYZInt) + OpAnother2() (_swig_ret Another) + TMethod2(arg2 int) + TMethodNotXYZ2(arg2 NotXYZInt) + TMethodXYZ2(arg2 XYZInt) + OpT2() (_swig_ret int) + OpNotXYZ2() (_swig_ret NotXYZInt) + OpXYZ2() (_swig_ret XYZInt) +} + +type SwigcptrXYZDouble uintptr + +func (p SwigcptrXYZDouble) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrXYZDouble) SwigIsXYZDouble() { +} + +var _wrap_XYZDouble_opIntPtrA unsafe.Pointer + +func _swig_wrap_XYZDouble_opIntPtrA(base SwigcptrXYZDouble) (_ SwigcptrNotXYZInt) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_XYZDouble_opIntPtrA, _swig_p) + return +} + +func (arg1 SwigcptrXYZDouble) OpIntPtrA() (_swig_ret NotXYZInt) { + return _swig_wrap_XYZDouble_opIntPtrA(arg1) +} + +var _wrap_XYZDouble_opIntPtrB unsafe.Pointer + +func _swig_wrap_XYZDouble_opIntPtrB(base SwigcptrXYZDouble) (_ SwigcptrXYZInt) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_XYZDouble_opIntPtrB, _swig_p) + return +} + +func (arg1 SwigcptrXYZDouble) OpIntPtrB() (_swig_ret XYZInt) { + return _swig_wrap_XYZDouble_opIntPtrB(arg1) +} + +var _wrap_XYZDouble_opAnother1 unsafe.Pointer + +func _swig_wrap_XYZDouble_opAnother1(base SwigcptrXYZDouble) (_ SwigcptrAnother) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_XYZDouble_opAnother1, _swig_p) + return +} + +func (arg1 SwigcptrXYZDouble) OpAnother1() (_swig_ret Another) { + return _swig_wrap_XYZDouble_opAnother1(arg1) +} + +var _wrap_XYZDouble_tMethod1 unsafe.Pointer + +func _swig_wrap_XYZDouble_tMethod1(base SwigcptrXYZDouble, _ float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_XYZDouble_tMethod1, _swig_p) + return +} + +func (arg1 SwigcptrXYZDouble) TMethod1(arg2 float64) { + _swig_wrap_XYZDouble_tMethod1(arg1, arg2) +} + +var _wrap_XYZDouble_tMethodNotXYZ1 unsafe.Pointer + +func _swig_wrap_XYZDouble_tMethodNotXYZ1(base SwigcptrXYZDouble, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_XYZDouble_tMethodNotXYZ1, _swig_p) + return +} + +func (arg1 SwigcptrXYZDouble) TMethodNotXYZ1(arg2 NotXYZDouble) { + _swig_wrap_XYZDouble_tMethodNotXYZ1(arg1, arg2.Swigcptr()) +} + +var _wrap_XYZDouble_tMethodXYZ1 unsafe.Pointer + +func _swig_wrap_XYZDouble_tMethodXYZ1(base SwigcptrXYZDouble, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_XYZDouble_tMethodXYZ1, _swig_p) + return +} + +func (arg1 SwigcptrXYZDouble) TMethodXYZ1(arg2 XYZDouble) { + _swig_wrap_XYZDouble_tMethodXYZ1(arg1, arg2.Swigcptr()) +} + +var _wrap_XYZDouble_opT1 unsafe.Pointer + +func _swig_wrap_XYZDouble_opT1(base SwigcptrXYZDouble) (_ float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_XYZDouble_opT1, _swig_p) + return +} + +func (arg1 SwigcptrXYZDouble) OpT1() (_swig_ret float64) { + return _swig_wrap_XYZDouble_opT1(arg1) +} + +var _wrap_XYZDouble_opNotXYZ1 unsafe.Pointer + +func _swig_wrap_XYZDouble_opNotXYZ1(base SwigcptrXYZDouble) (_ SwigcptrNotXYZDouble) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_XYZDouble_opNotXYZ1, _swig_p) + return +} + +func (arg1 SwigcptrXYZDouble) OpNotXYZ1() (_swig_ret NotXYZDouble) { + return _swig_wrap_XYZDouble_opNotXYZ1(arg1) +} + +var _wrap_XYZDouble_opXYZ1 unsafe.Pointer + +func _swig_wrap_XYZDouble_opXYZ1(base SwigcptrXYZDouble) (_ SwigcptrXYZDouble) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_XYZDouble_opXYZ1, _swig_p) + return +} + +func (arg1 SwigcptrXYZDouble) OpXYZ1() (_swig_ret XYZDouble) { + return _swig_wrap_XYZDouble_opXYZ1(arg1) +} + +var _wrap_new_XYZDouble unsafe.Pointer + +func _swig_wrap_new_XYZDouble() (base SwigcptrXYZDouble) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_XYZDouble, _swig_p) + return +} + +func NewXYZDouble() (_swig_ret XYZDouble) { + return _swig_wrap_new_XYZDouble() +} + +var _wrap_delete_XYZDouble unsafe.Pointer + +func _swig_wrap_delete_XYZDouble(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_XYZDouble, _swig_p) + return +} + +func DeleteXYZDouble(arg1 XYZDouble) { + _swig_wrap_delete_XYZDouble(arg1.Swigcptr()) +} + +type XYZDouble interface { + Swigcptr() uintptr + SwigIsXYZDouble() + OpIntPtrA() (_swig_ret NotXYZInt) + OpIntPtrB() (_swig_ret XYZInt) + OpAnother1() (_swig_ret Another) + TMethod1(arg2 float64) + TMethodNotXYZ1(arg2 NotXYZDouble) + TMethodXYZ1(arg2 XYZDouble) + OpT1() (_swig_ret float64) + OpNotXYZ1() (_swig_ret NotXYZDouble) + OpXYZ1() (_swig_ret XYZDouble) +} + +type SwigcptrXYZKlass uintptr + +func (p SwigcptrXYZKlass) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrXYZKlass) SwigIsXYZKlass() { +} + +var _wrap_XYZKlass_opIntPtrA unsafe.Pointer + +func _swig_wrap_XYZKlass_opIntPtrA(base SwigcptrXYZKlass) (_ SwigcptrNotXYZInt) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_XYZKlass_opIntPtrA, _swig_p) + return +} + +func (arg1 SwigcptrXYZKlass) OpIntPtrA() (_swig_ret NotXYZInt) { + return _swig_wrap_XYZKlass_opIntPtrA(arg1) +} + +var _wrap_XYZKlass_opIntPtrB unsafe.Pointer + +func _swig_wrap_XYZKlass_opIntPtrB(base SwigcptrXYZKlass) (_ SwigcptrXYZInt) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_XYZKlass_opIntPtrB, _swig_p) + return +} + +func (arg1 SwigcptrXYZKlass) OpIntPtrB() (_swig_ret XYZInt) { + return _swig_wrap_XYZKlass_opIntPtrB(arg1) +} + +var _wrap_XYZKlass_opAnother3 unsafe.Pointer + +func _swig_wrap_XYZKlass_opAnother3(base SwigcptrXYZKlass) (_ SwigcptrAnother) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_XYZKlass_opAnother3, _swig_p) + return +} + +func (arg1 SwigcptrXYZKlass) OpAnother3() (_swig_ret Another) { + return _swig_wrap_XYZKlass_opAnother3(arg1) +} + +var _wrap_XYZKlass_tMethod3 unsafe.Pointer + +func _swig_wrap_XYZKlass_tMethod3(base SwigcptrXYZKlass, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_XYZKlass_tMethod3, _swig_p) + return +} + +func (arg1 SwigcptrXYZKlass) TMethod3(arg2 Klass) { + _swig_wrap_XYZKlass_tMethod3(arg1, arg2.Swigcptr()) +} + +var _wrap_XYZKlass_tMethodNotXYZ3 unsafe.Pointer + +func _swig_wrap_XYZKlass_tMethodNotXYZ3(base SwigcptrXYZKlass, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_XYZKlass_tMethodNotXYZ3, _swig_p) + return +} + +func (arg1 SwigcptrXYZKlass) TMethodNotXYZ3(arg2 NotXYZKlass) { + _swig_wrap_XYZKlass_tMethodNotXYZ3(arg1, arg2.Swigcptr()) +} + +var _wrap_XYZKlass_tMethodXYZ3 unsafe.Pointer + +func _swig_wrap_XYZKlass_tMethodXYZ3(base SwigcptrXYZKlass, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_XYZKlass_tMethodXYZ3, _swig_p) + return +} + +func (arg1 SwigcptrXYZKlass) TMethodXYZ3(arg2 XYZKlass) { + _swig_wrap_XYZKlass_tMethodXYZ3(arg1, arg2.Swigcptr()) +} + +var _wrap_XYZKlass_opT3 unsafe.Pointer + +func _swig_wrap_XYZKlass_opT3(base SwigcptrXYZKlass) (_ SwigcptrKlass) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_XYZKlass_opT3, _swig_p) + return +} + +func (arg1 SwigcptrXYZKlass) OpT3() (_swig_ret Klass) { + return _swig_wrap_XYZKlass_opT3(arg1) +} + +var _wrap_XYZKlass_opNotXYZ3 unsafe.Pointer + +func _swig_wrap_XYZKlass_opNotXYZ3(base SwigcptrXYZKlass) (_ SwigcptrNotXYZKlass) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_XYZKlass_opNotXYZ3, _swig_p) + return +} + +func (arg1 SwigcptrXYZKlass) OpNotXYZ3() (_swig_ret NotXYZKlass) { + return _swig_wrap_XYZKlass_opNotXYZ3(arg1) +} + +var _wrap_XYZKlass_opXYZ3 unsafe.Pointer + +func _swig_wrap_XYZKlass_opXYZ3(base SwigcptrXYZKlass) (_ SwigcptrXYZKlass) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_XYZKlass_opXYZ3, _swig_p) + return +} + +func (arg1 SwigcptrXYZKlass) OpXYZ3() (_swig_ret XYZKlass) { + return _swig_wrap_XYZKlass_opXYZ3(arg1) +} + +var _wrap_new_XYZKlass unsafe.Pointer + +func _swig_wrap_new_XYZKlass() (base SwigcptrXYZKlass) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_XYZKlass, _swig_p) + return +} + +func NewXYZKlass() (_swig_ret XYZKlass) { + return _swig_wrap_new_XYZKlass() +} + +var _wrap_delete_XYZKlass unsafe.Pointer + +func _swig_wrap_delete_XYZKlass(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_XYZKlass, _swig_p) + return +} + +func DeleteXYZKlass(arg1 XYZKlass) { + _swig_wrap_delete_XYZKlass(arg1.Swigcptr()) +} + +type XYZKlass interface { + Swigcptr() uintptr + SwigIsXYZKlass() + OpIntPtrA() (_swig_ret NotXYZInt) + OpIntPtrB() (_swig_ret XYZInt) + OpAnother3() (_swig_ret Another) + TMethod3(arg2 Klass) + TMethodNotXYZ3(arg2 NotXYZKlass) + TMethodXYZ3(arg2 XYZKlass) + OpT3() (_swig_ret Klass) + OpNotXYZ3() (_swig_ret NotXYZKlass) + OpXYZ3() (_swig_ret XYZKlass) +} + +type SwigcptrXYZEnu uintptr + +func (p SwigcptrXYZEnu) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrXYZEnu) SwigIsXYZEnu() { +} + +var _wrap_XYZEnu_opIntPtrA unsafe.Pointer + +func _swig_wrap_XYZEnu_opIntPtrA(base SwigcptrXYZEnu) (_ SwigcptrNotXYZInt) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_XYZEnu_opIntPtrA, _swig_p) + return +} + +func (arg1 SwigcptrXYZEnu) OpIntPtrA() (_swig_ret NotXYZInt) { + return _swig_wrap_XYZEnu_opIntPtrA(arg1) +} + +var _wrap_XYZEnu_opIntPtrB unsafe.Pointer + +func _swig_wrap_XYZEnu_opIntPtrB(base SwigcptrXYZEnu) (_ SwigcptrXYZInt) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_XYZEnu_opIntPtrB, _swig_p) + return +} + +func (arg1 SwigcptrXYZEnu) OpIntPtrB() (_swig_ret XYZInt) { + return _swig_wrap_XYZEnu_opIntPtrB(arg1) +} + +var _wrap_XYZEnu_opAnother4 unsafe.Pointer + +func _swig_wrap_XYZEnu_opAnother4(base SwigcptrXYZEnu) (_ SwigcptrAnother) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_XYZEnu_opAnother4, _swig_p) + return +} + +func (arg1 SwigcptrXYZEnu) OpAnother4() (_swig_ret Another) { + return _swig_wrap_XYZEnu_opAnother4(arg1) +} + +var _wrap_XYZEnu_tMethod4 unsafe.Pointer + +func _swig_wrap_XYZEnu_tMethod4(base SwigcptrXYZEnu, _ SpaceEnu) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_XYZEnu_tMethod4, _swig_p) + return +} + +func (arg1 SwigcptrXYZEnu) TMethod4(arg2 SpaceEnu) { + _swig_wrap_XYZEnu_tMethod4(arg1, arg2) +} + +var _wrap_XYZEnu_tMethodNotXYZ4 unsafe.Pointer + +func _swig_wrap_XYZEnu_tMethodNotXYZ4(base SwigcptrXYZEnu, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_XYZEnu_tMethodNotXYZ4, _swig_p) + return +} + +func (arg1 SwigcptrXYZEnu) TMethodNotXYZ4(arg2 NotXYZEnu) { + _swig_wrap_XYZEnu_tMethodNotXYZ4(arg1, arg2.Swigcptr()) +} + +var _wrap_XYZEnu_tMethodXYZ4 unsafe.Pointer + +func _swig_wrap_XYZEnu_tMethodXYZ4(base SwigcptrXYZEnu, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_XYZEnu_tMethodXYZ4, _swig_p) + return +} + +func (arg1 SwigcptrXYZEnu) TMethodXYZ4(arg2 XYZEnu) { + _swig_wrap_XYZEnu_tMethodXYZ4(arg1, arg2.Swigcptr()) +} + +var _wrap_XYZEnu_opT4 unsafe.Pointer + +func _swig_wrap_XYZEnu_opT4(base SwigcptrXYZEnu) (_ SpaceEnu) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_XYZEnu_opT4, _swig_p) + return +} + +func (arg1 SwigcptrXYZEnu) OpT4() (_swig_ret SpaceEnu) { + return _swig_wrap_XYZEnu_opT4(arg1) +} + +var _wrap_XYZEnu_opNotXYZ4 unsafe.Pointer + +func _swig_wrap_XYZEnu_opNotXYZ4(base SwigcptrXYZEnu) (_ SwigcptrNotXYZEnu) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_XYZEnu_opNotXYZ4, _swig_p) + return +} + +func (arg1 SwigcptrXYZEnu) OpNotXYZ4() (_swig_ret NotXYZEnu) { + return _swig_wrap_XYZEnu_opNotXYZ4(arg1) +} + +var _wrap_XYZEnu_opXYZ4 unsafe.Pointer + +func _swig_wrap_XYZEnu_opXYZ4(base SwigcptrXYZEnu) (_ SwigcptrXYZEnu) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_XYZEnu_opXYZ4, _swig_p) + return +} + +func (arg1 SwigcptrXYZEnu) OpXYZ4() (_swig_ret XYZEnu) { + return _swig_wrap_XYZEnu_opXYZ4(arg1) +} + +var _wrap_new_XYZEnu unsafe.Pointer + +func _swig_wrap_new_XYZEnu() (base SwigcptrXYZEnu) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_XYZEnu, _swig_p) + return +} + +func NewXYZEnu() (_swig_ret XYZEnu) { + return _swig_wrap_new_XYZEnu() +} + +var _wrap_delete_XYZEnu unsafe.Pointer + +func _swig_wrap_delete_XYZEnu(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_XYZEnu, _swig_p) + return +} + +func DeleteXYZEnu(arg1 XYZEnu) { + _swig_wrap_delete_XYZEnu(arg1.Swigcptr()) +} + +type XYZEnu interface { + Swigcptr() uintptr + SwigIsXYZEnu() + OpIntPtrA() (_swig_ret NotXYZInt) + OpIntPtrB() (_swig_ret XYZInt) + OpAnother4() (_swig_ret Another) + TMethod4(arg2 SpaceEnu) + TMethodNotXYZ4(arg2 NotXYZEnu) + TMethodXYZ4(arg2 XYZEnu) + OpT4() (_swig_ret SpaceEnu) + OpNotXYZ4() (_swig_ret NotXYZEnu) + OpXYZ4() (_swig_ret XYZEnu) +} + +type SwigcptrNotXYZInt uintptr + +func (p SwigcptrNotXYZInt) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrNotXYZInt) SwigIsNotXYZInt() { +} + +var _wrap_new_NotXYZInt unsafe.Pointer + +func _swig_wrap_new_NotXYZInt() (base SwigcptrNotXYZInt) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_NotXYZInt, _swig_p) + return +} + +func NewNotXYZInt() (_swig_ret NotXYZInt) { + return _swig_wrap_new_NotXYZInt() +} + +var _wrap_delete_NotXYZInt unsafe.Pointer + +func _swig_wrap_delete_NotXYZInt(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_NotXYZInt, _swig_p) + return +} + +func DeleteNotXYZInt(arg1 NotXYZInt) { + _swig_wrap_delete_NotXYZInt(arg1.Swigcptr()) +} + +type NotXYZInt interface { + Swigcptr() uintptr + SwigIsNotXYZInt() +} + +type SwigcptrNotXYZDouble uintptr + +func (p SwigcptrNotXYZDouble) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrNotXYZDouble) SwigIsNotXYZDouble() { +} + +var _wrap_new_NotXYZDouble unsafe.Pointer + +func _swig_wrap_new_NotXYZDouble() (base SwigcptrNotXYZDouble) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_NotXYZDouble, _swig_p) + return +} + +func NewNotXYZDouble() (_swig_ret NotXYZDouble) { + return _swig_wrap_new_NotXYZDouble() +} + +var _wrap_delete_NotXYZDouble unsafe.Pointer + +func _swig_wrap_delete_NotXYZDouble(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_NotXYZDouble, _swig_p) + return +} + +func DeleteNotXYZDouble(arg1 NotXYZDouble) { + _swig_wrap_delete_NotXYZDouble(arg1.Swigcptr()) +} + +type NotXYZDouble interface { + Swigcptr() uintptr + SwigIsNotXYZDouble() +} + +type SwigcptrNotXYZKlass uintptr + +func (p SwigcptrNotXYZKlass) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrNotXYZKlass) SwigIsNotXYZKlass() { +} + +var _wrap_new_NotXYZKlass unsafe.Pointer + +func _swig_wrap_new_NotXYZKlass() (base SwigcptrNotXYZKlass) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_NotXYZKlass, _swig_p) + return +} + +func NewNotXYZKlass() (_swig_ret NotXYZKlass) { + return _swig_wrap_new_NotXYZKlass() +} + +var _wrap_delete_NotXYZKlass unsafe.Pointer + +func _swig_wrap_delete_NotXYZKlass(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_NotXYZKlass, _swig_p) + return +} + +func DeleteNotXYZKlass(arg1 NotXYZKlass) { + _swig_wrap_delete_NotXYZKlass(arg1.Swigcptr()) +} + +type NotXYZKlass interface { + Swigcptr() uintptr + SwigIsNotXYZKlass() +} + +type SwigcptrNotXYZEnu uintptr + +func (p SwigcptrNotXYZEnu) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrNotXYZEnu) SwigIsNotXYZEnu() { +} + +var _wrap_new_NotXYZEnu unsafe.Pointer + +func _swig_wrap_new_NotXYZEnu() (base SwigcptrNotXYZEnu) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_NotXYZEnu, _swig_p) + return +} + +func NewNotXYZEnu() (_swig_ret NotXYZEnu) { + return _swig_wrap_new_NotXYZEnu() +} + +var _wrap_delete_NotXYZEnu unsafe.Pointer + +func _swig_wrap_delete_NotXYZEnu(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_NotXYZEnu, _swig_p) + return +} + +func DeleteNotXYZEnu(arg1 NotXYZEnu) { + _swig_wrap_delete_NotXYZEnu(arg1.Swigcptr()) +} + +type NotXYZEnu interface { + Swigcptr() uintptr + SwigIsNotXYZEnu() +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/rename_pcre_encoder.go b/Examples/test-suite/go/rename_pcre_encoder.go new file mode 100644 index 000000000..468cd366f --- /dev/null +++ b/Examples/test-suite/go/rename_pcre_encoder.go @@ -0,0 +1,274 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../rename_pcre_encoder.i + +package rename_pcre_encoder + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrSomeWidget uintptr + +func (p SwigcptrSomeWidget) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrSomeWidget) SwigIsSomeWidget() { +} + +var _wrap_SomeWidget_put_borderWidth unsafe.Pointer + +func _swig_wrap_SomeWidget_put_borderWidth(base SwigcptrSomeWidget, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_SomeWidget_put_borderWidth, _swig_p) + return +} + +func (arg1 SwigcptrSomeWidget) Put_borderWidth(arg2 int) { + _swig_wrap_SomeWidget_put_borderWidth(arg1, arg2) +} + +var _wrap_SomeWidget_get_borderWidth unsafe.Pointer + +func _swig_wrap_SomeWidget_get_borderWidth(base SwigcptrSomeWidget) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_SomeWidget_get_borderWidth, _swig_p) + return +} + +func (arg1 SwigcptrSomeWidget) Get_borderWidth() (_swig_ret int) { + return _swig_wrap_SomeWidget_get_borderWidth(arg1) +} + +var _wrap_SomeWidget_put_size unsafe.Pointer + +func _swig_wrap_SomeWidget_put_size(base SwigcptrSomeWidget, _ int, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_SomeWidget_put_size, _swig_p) + return +} + +func (arg1 SwigcptrSomeWidget) Put_size(arg2 int, arg3 int) { + _swig_wrap_SomeWidget_put_size(arg1, arg2, arg3) +} + +var _wrap_SomeWidget_m_width_set unsafe.Pointer + +func _swig_wrap_SomeWidget_m_width_set(base SwigcptrSomeWidget, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_SomeWidget_m_width_set, _swig_p) + return +} + +func (arg1 SwigcptrSomeWidget) SetM_width(arg2 int) { + _swig_wrap_SomeWidget_m_width_set(arg1, arg2) +} + +var _wrap_SomeWidget_m_width_get unsafe.Pointer + +func _swig_wrap_SomeWidget_m_width_get(base SwigcptrSomeWidget) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_SomeWidget_m_width_get, _swig_p) + return +} + +func (arg1 SwigcptrSomeWidget) GetM_width() (_swig_ret int) { + return _swig_wrap_SomeWidget_m_width_get(arg1) +} + +var _wrap_new_SomeWidget unsafe.Pointer + +func _swig_wrap_new_SomeWidget() (base SwigcptrSomeWidget) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_SomeWidget, _swig_p) + return +} + +func NewSomeWidget() (_swig_ret SomeWidget) { + return _swig_wrap_new_SomeWidget() +} + +var _wrap_delete_SomeWidget unsafe.Pointer + +func _swig_wrap_delete_SomeWidget(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_SomeWidget, _swig_p) + return +} + +func DeleteSomeWidget(arg1 SomeWidget) { + _swig_wrap_delete_SomeWidget(arg1.Swigcptr()) +} + +type SomeWidget interface { + Swigcptr() uintptr + SwigIsSomeWidget() + Put_borderWidth(arg2 int) + Get_borderWidth() (_swig_ret int) + Put_size(arg2 int, arg3 int) + SetM_width(arg2 int) + GetM_width() (_swig_ret int) +} + +type SwigcptrAnotherWidget uintptr + +func (p SwigcptrAnotherWidget) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrAnotherWidget) SwigIsAnotherWidget() { +} + +var _wrap_AnotherWidget_DoSomething unsafe.Pointer + +func _swig_wrap_AnotherWidget_DoSomething(base SwigcptrAnotherWidget) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_AnotherWidget_DoSomething, _swig_p) + return +} + +func (arg1 SwigcptrAnotherWidget) DoSomething() { + _swig_wrap_AnotherWidget_DoSomething(arg1) +} + +var _wrap_new_AnotherWidget unsafe.Pointer + +func _swig_wrap_new_AnotherWidget() (base SwigcptrAnotherWidget) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_AnotherWidget, _swig_p) + return +} + +func NewAnotherWidget() (_swig_ret AnotherWidget) { + return _swig_wrap_new_AnotherWidget() +} + +var _wrap_delete_AnotherWidget unsafe.Pointer + +func _swig_wrap_delete_AnotherWidget(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_AnotherWidget, _swig_p) + return +} + +func DeleteAnotherWidget(arg1 AnotherWidget) { + _swig_wrap_delete_AnotherWidget(arg1.Swigcptr()) +} + +type AnotherWidget interface { + Swigcptr() uintptr + SwigIsAnotherWidget() + DoSomething() +} + +type SwigcptrWxEVTSomeEvent uintptr + +func (p SwigcptrWxEVTSomeEvent) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrWxEVTSomeEvent) SwigIsWxEVTSomeEvent() { +} + +var _wrap_new_wxEVTSomeEvent unsafe.Pointer + +func _swig_wrap_new_wxEVTSomeEvent() (base SwigcptrWxEVTSomeEvent) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_wxEVTSomeEvent, _swig_p) + return +} + +func NewWxEVTSomeEvent() (_swig_ret WxEVTSomeEvent) { + return _swig_wrap_new_wxEVTSomeEvent() +} + +var _wrap_delete_wxEVTSomeEvent unsafe.Pointer + +func _swig_wrap_delete_wxEVTSomeEvent(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_wxEVTSomeEvent, _swig_p) + return +} + +func DeleteWxEVTSomeEvent(arg1 WxEVTSomeEvent) { + _swig_wrap_delete_wxEVTSomeEvent(arg1.Swigcptr()) +} + +type WxEVTSomeEvent interface { + Swigcptr() uintptr + SwigIsWxEVTSomeEvent() +} + +type SwigcptrXUnchangedName uintptr + +func (p SwigcptrXUnchangedName) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrXUnchangedName) SwigIsXUnchangedName() { +} + +var _wrap_new_xUnchangedName unsafe.Pointer + +func _swig_wrap_new_xUnchangedName() (base SwigcptrXUnchangedName) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_xUnchangedName, _swig_p) + return +} + +func NewXUnchangedName() (_swig_ret XUnchangedName) { + return _swig_wrap_new_xUnchangedName() +} + +var _wrap_delete_xUnchangedName unsafe.Pointer + +func _swig_wrap_delete_xUnchangedName(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_xUnchangedName, _swig_p) + return +} + +func DeleteXUnchangedName(arg1 XUnchangedName) { + _swig_wrap_delete_xUnchangedName(arg1.Swigcptr()) +} + +type XUnchangedName interface { + Swigcptr() uintptr + SwigIsXUnchangedName() +} + +var _wrap_StartINSAneAndUNSAvoryTraNSAtlanticRaNSAck unsafe.Pointer + +func StartINSAneAndUNSAvoryTraNSAtlanticRaNSAck() (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_StartINSAneAndUNSAvoryTraNSAtlanticRaNSAck, _swig_p) + return +} + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/rename_pcre_enum.go b/Examples/test-suite/go/rename_pcre_enum.go new file mode 100644 index 000000000..c14159c59 --- /dev/null +++ b/Examples/test-suite/go/rename_pcre_enum.go @@ -0,0 +1,96 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../rename_pcre_enum.i + +package rename_pcre_enum + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type Foo int +var _wrap_First unsafe.Pointer + +func _swig_getFirst() (_swig_ret Foo) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_First, _swig_p) + return +} +var First Foo = _swig_getFirst() +var _wrap_Second unsafe.Pointer + +func _swig_getSecond() (_swig_ret Foo) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_Second, _swig_p) + return +} +var Second Foo = _swig_getSecond() +type BoundaryCondition int +var _wrap_MinMax unsafe.Pointer + +func _swig_getMinMax() (_swig_ret BoundaryCondition) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_MinMax, _swig_p) + return +} +var MinMax BoundaryCondition = _swig_getMinMax() +var _wrap_MaxMin unsafe.Pointer + +func _swig_getMaxMin() (_swig_ret BoundaryCondition) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_MaxMin, _swig_p) + return +} +var MaxMin BoundaryCondition = _swig_getMaxMin() +var _wrap_MaxMax unsafe.Pointer + +func _swig_getMaxMax() (_swig_ret BoundaryCondition) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_MaxMax, _swig_p) + return +} +var MaxMax BoundaryCondition = _swig_getMaxMax() +type Colour int +var _wrap_red unsafe.Pointer + +func _swig_getred() (_swig_ret Colour) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_red, _swig_p) + return +} +var Red Colour = _swig_getred() +var _wrap_blue unsafe.Pointer + +func _swig_getblue() (_swig_ret Colour) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_blue, _swig_p) + return +} +var Blue Colour = _swig_getblue() +var _wrap_green unsafe.Pointer + +func _swig_getgreen() (_swig_ret Colour) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_green, _swig_p) + return +} +var Green Colour = _swig_getgreen() + diff --git a/Examples/test-suite/go/rename_predicates.go b/Examples/test-suite/go/rename_predicates.go new file mode 100644 index 000000000..d85ed19e1 --- /dev/null +++ b/Examples/test-suite/go/rename_predicates.go @@ -0,0 +1,424 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../rename_predicates.i + +package rename_predicates + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrRenamePredicates uintptr + +func (p SwigcptrRenamePredicates) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrRenamePredicates) SwigIsRenamePredicates() { +} + +var _wrap_new_RenamePredicates__SWIG_0 unsafe.Pointer + +func _swig_wrap_new_RenamePredicates__SWIG_0(base int) (_ SwigcptrRenamePredicates) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_RenamePredicates__SWIG_0, _swig_p) + return +} + +func NewRenamePredicates__SWIG_0(arg1 int) (_swig_ret RenamePredicates) { + return _swig_wrap_new_RenamePredicates__SWIG_0(arg1) +} + +var _wrap_new_RenamePredicates__SWIG_1 unsafe.Pointer + +func _swig_wrap_new_RenamePredicates__SWIG_1() (base SwigcptrRenamePredicates) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_RenamePredicates__SWIG_1, _swig_p) + return +} + +func NewRenamePredicates__SWIG_1() (_swig_ret RenamePredicates) { + return _swig_wrap_new_RenamePredicates__SWIG_1() +} + +func NewRenamePredicates(a ...interface{}) RenamePredicates { + argc := len(a) + if argc == 0 { + return NewRenamePredicates__SWIG_1() + } + if argc == 1 { + return NewRenamePredicates__SWIG_0(a[0].(int)) + } + panic("No match for overloaded function call") +} + +var _wrap_RenamePredicates_MF_member_function unsafe.Pointer + +func _swig_wrap_RenamePredicates_MF_member_function(base SwigcptrRenamePredicates) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_RenamePredicates_MF_member_function, _swig_p) + return +} + +func (arg1 SwigcptrRenamePredicates) MF_member_function() { + _swig_wrap_RenamePredicates_MF_member_function(arg1) +} + +var _wrap_RenamePredicates_MF_static_member_function unsafe.Pointer + +func _swig_wrap_RenamePredicates_MF_static_member_function() { + var _swig_p uintptr + _cgo_runtime_cgocall(_wrap_RenamePredicates_MF_static_member_function, _swig_p) + return +} + +func RenamePredicatesMF_static_member_function() { + _swig_wrap_RenamePredicates_MF_static_member_function() +} + +var _wrap_RenamePredicates_MV_member_variable_set unsafe.Pointer + +func _swig_wrap_RenamePredicates_MV_member_variable_set(base SwigcptrRenamePredicates, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_RenamePredicates_MV_member_variable_set, _swig_p) + return +} + +func (arg1 SwigcptrRenamePredicates) SetMV_member_variable(arg2 int) { + _swig_wrap_RenamePredicates_MV_member_variable_set(arg1, arg2) +} + +var _wrap_RenamePredicates_MV_member_variable_get unsafe.Pointer + +func _swig_wrap_RenamePredicates_MV_member_variable_get(base SwigcptrRenamePredicates) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_RenamePredicates_MV_member_variable_get, _swig_p) + return +} + +func (arg1 SwigcptrRenamePredicates) GetMV_member_variable() (_swig_ret int) { + return _swig_wrap_RenamePredicates_MV_member_variable_get(arg1) +} + +var _wrap_RenamePredicates_MV_static_member_variable_set unsafe.Pointer + +func _swig_wrap_RenamePredicates_MV_static_member_variable_set(base int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_RenamePredicates_MV_static_member_variable_set, _swig_p) + return +} + +func SetRenamePredicatesMV_static_member_variable(arg1 int) { + _swig_wrap_RenamePredicates_MV_static_member_variable_set(arg1) +} + +var _wrap_RenamePredicates_MV_static_member_variable_get unsafe.Pointer + +func GetRenamePredicatesMV_static_member_variable() (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_RenamePredicates_MV_static_member_variable_get, _swig_p) + return +} +var _wrap_RenamePredicates_MF_extend_function_before unsafe.Pointer + +func _swig_wrap_RenamePredicates_MF_extend_function_before(base SwigcptrRenamePredicates) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_RenamePredicates_MF_extend_function_before, _swig_p) + return +} + +func (arg1 SwigcptrRenamePredicates) MF_extend_function_before() { + _swig_wrap_RenamePredicates_MF_extend_function_before(arg1) +} + +var _wrap_RenamePredicates_MF_extend_function_after unsafe.Pointer + +func _swig_wrap_RenamePredicates_MF_extend_function_after(base SwigcptrRenamePredicates) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_RenamePredicates_MF_extend_function_after, _swig_p) + return +} + +func (arg1 SwigcptrRenamePredicates) MF_extend_function_after() { + _swig_wrap_RenamePredicates_MF_extend_function_after(arg1) +} + +var _wrap_delete_RenamePredicates unsafe.Pointer + +func _swig_wrap_delete_RenamePredicates(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_RenamePredicates, _swig_p) + return +} + +func DeleteRenamePredicates(arg1 RenamePredicates) { + _swig_wrap_delete_RenamePredicates(arg1.Swigcptr()) +} + +type RenamePredicates interface { + Swigcptr() uintptr + SwigIsRenamePredicates() + MF_member_function() + SetMV_member_variable(arg2 int) + GetMV_member_variable() (_swig_ret int) + MF_extend_function_before() + MF_extend_function_after() +} + +var _wrap_GV_global_variable_set unsafe.Pointer + +func _swig_wrap_GV_global_variable_set(base int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_GV_global_variable_set, _swig_p) + return +} + +func SetGV_global_variable(arg1 int) { + _swig_wrap_GV_global_variable_set(arg1) +} + +var _wrap_GV_global_variable_get unsafe.Pointer + +func GetGV_global_variable() (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_GV_global_variable_get, _swig_p) + return +} +var _wrap_GF_global_function unsafe.Pointer + +func _swig_wrap_GF_global_function() { + var _swig_p uintptr + _cgo_runtime_cgocall(_wrap_GF_global_function, _swig_p) + return +} + +func GF_global_function() { + _swig_wrap_GF_global_function() +} + +var _wrap_UC_UPPERCASE unsafe.Pointer + +func _swig_wrap_UC_UPPERCASE() { + var _swig_p uintptr + _cgo_runtime_cgocall(_wrap_UC_UPPERCASE, _swig_p) + return +} + +func UC_UPPERCASE() { + _swig_wrap_UC_UPPERCASE() +} + +var _wrap_LC_lowercase unsafe.Pointer + +func _swig_wrap_LC_lowercase() { + var _swig_p uintptr + _cgo_runtime_cgocall(_wrap_LC_lowercase, _swig_p) + return +} + +func LC_lowercase() { + _swig_wrap_LC_lowercase() +} + +var _wrap_TI_Title unsafe.Pointer + +func _swig_wrap_TI_Title() { + var _swig_p uintptr + _cgo_runtime_cgocall(_wrap_TI_Title, _swig_p) + return +} + +func TI_Title() { + _swig_wrap_TI_Title() +} + +var _wrap_FU_FirstUpperCase unsafe.Pointer + +func _swig_wrap_FU_FirstUpperCase() { + var _swig_p uintptr + _cgo_runtime_cgocall(_wrap_FU_FirstUpperCase, _swig_p) + return +} + +func FU_FirstUpperCase() { + _swig_wrap_FU_FirstUpperCase() +} + +var _wrap_FL_firstLowerCase unsafe.Pointer + +func _swig_wrap_FL_firstLowerCase() { + var _swig_p uintptr + _cgo_runtime_cgocall(_wrap_FL_firstLowerCase, _swig_p) + return +} + +func FL_firstLowerCase() { + _swig_wrap_FL_firstLowerCase() +} + +var _wrap_CA_CamelCase unsafe.Pointer + +func _swig_wrap_CA_CamelCase() { + var _swig_p uintptr + _cgo_runtime_cgocall(_wrap_CA_CamelCase, _swig_p) + return +} + +func CA_CamelCase() { + _swig_wrap_CA_CamelCase() +} + +var _wrap_LC_lowerCamelCase unsafe.Pointer + +func _swig_wrap_LC_lowerCamelCase() { + var _swig_p uintptr + _cgo_runtime_cgocall(_wrap_LC_lowerCamelCase, _swig_p) + return +} + +func LC_lowerCamelCase() { + _swig_wrap_LC_lowerCamelCase() +} + +var _wrap_UC_under_case_it unsafe.Pointer + +func _swig_wrap_UC_under_case_it() { + var _swig_p uintptr + _cgo_runtime_cgocall(_wrap_UC_under_case_it, _swig_p) + return +} + +func UC_under_case_it() { + _swig_wrap_UC_under_case_it() +} + +type SwigcptrExtendCheck uintptr + +func (p SwigcptrExtendCheck) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrExtendCheck) SwigIsExtendCheck() { +} + +var _wrap_ExtendCheck_MF_real_member1 unsafe.Pointer + +func _swig_wrap_ExtendCheck_MF_real_member1(base SwigcptrExtendCheck) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_ExtendCheck_MF_real_member1, _swig_p) + return +} + +func (arg1 SwigcptrExtendCheck) MF_real_member1() { + _swig_wrap_ExtendCheck_MF_real_member1(arg1) +} + +var _wrap_ExtendCheck_EX_EXTENDMETHOD2 unsafe.Pointer + +func _swig_wrap_ExtendCheck_EX_EXTENDMETHOD2(base SwigcptrExtendCheck) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_ExtendCheck_EX_EXTENDMETHOD2, _swig_p) + return +} + +func (arg1 SwigcptrExtendCheck) EX_EXTENDMETHOD2() { + _swig_wrap_ExtendCheck_EX_EXTENDMETHOD2(arg1) +} + +var _wrap_ExtendCheck_MF_real_member2 unsafe.Pointer + +func _swig_wrap_ExtendCheck_MF_real_member2(base SwigcptrExtendCheck) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_ExtendCheck_MF_real_member2, _swig_p) + return +} + +func (arg1 SwigcptrExtendCheck) MF_real_member2() { + _swig_wrap_ExtendCheck_MF_real_member2(arg1) +} + +var _wrap_ExtendCheck_EX_EXTENDMETHOD1 unsafe.Pointer + +func _swig_wrap_ExtendCheck_EX_EXTENDMETHOD1(base SwigcptrExtendCheck) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_ExtendCheck_EX_EXTENDMETHOD1, _swig_p) + return +} + +func (arg1 SwigcptrExtendCheck) EX_EXTENDMETHOD1() { + _swig_wrap_ExtendCheck_EX_EXTENDMETHOD1(arg1) +} + +var _wrap_ExtendCheck_EX_EXTENDMETHOD3 unsafe.Pointer + +func _swig_wrap_ExtendCheck_EX_EXTENDMETHOD3(base SwigcptrExtendCheck) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_ExtendCheck_EX_EXTENDMETHOD3, _swig_p) + return +} + +func (arg1 SwigcptrExtendCheck) EX_EXTENDMETHOD3() { + _swig_wrap_ExtendCheck_EX_EXTENDMETHOD3(arg1) +} + +var _wrap_new_ExtendCheck unsafe.Pointer + +func _swig_wrap_new_ExtendCheck() (base SwigcptrExtendCheck) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_ExtendCheck, _swig_p) + return +} + +func NewExtendCheck() (_swig_ret ExtendCheck) { + return _swig_wrap_new_ExtendCheck() +} + +var _wrap_delete_ExtendCheck unsafe.Pointer + +func _swig_wrap_delete_ExtendCheck(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_ExtendCheck, _swig_p) + return +} + +func DeleteExtendCheck(arg1 ExtendCheck) { + _swig_wrap_delete_ExtendCheck(arg1.Swigcptr()) +} + +type ExtendCheck interface { + Swigcptr() uintptr + SwigIsExtendCheck() + MF_real_member1() + EX_EXTENDMETHOD2() + MF_real_member2() + EX_EXTENDMETHOD1() + EX_EXTENDMETHOD3() +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/rename_scope.go b/Examples/test-suite/go/rename_scope.go new file mode 100644 index 000000000..f37f1d5b0 --- /dev/null +++ b/Examples/test-suite/go/rename_scope.go @@ -0,0 +1,300 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../rename_scope.i + +package rename_scope + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type OssPolarization int +var _wrap_UnaryPolarization unsafe.Pointer + +func _swig_getUnaryPolarization() (_swig_ret OssPolarization) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_UnaryPolarization, _swig_p) + return +} +var UnaryPolarization OssPolarization = _swig_getUnaryPolarization() +var _wrap_BinaryPolarization unsafe.Pointer + +func _swig_getBinaryPolarization() (_swig_ret OssPolarization) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_BinaryPolarization, _swig_p) + return +} +var BinaryPolarization OssPolarization = _swig_getBinaryPolarization() +type SwigcptrInterface_UP uintptr + +func (p SwigcptrInterface_UP) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrInterface_UP) SwigIsInterface_UP() { +} + +var _wrap_new_Interface_UP unsafe.Pointer + +func _swig_wrap_new_Interface_UP() (base SwigcptrInterface_UP) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Interface_UP, _swig_p) + return +} + +func NewInterface_UP() (_swig_ret Interface_UP) { + return _swig_wrap_new_Interface_UP() +} + +var _wrap_delete_Interface_UP unsafe.Pointer + +func _swig_wrap_delete_Interface_UP(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Interface_UP, _swig_p) + return +} + +func DeleteInterface_UP(arg1 Interface_UP) { + _swig_wrap_delete_Interface_UP(arg1.Swigcptr()) +} + +type Interface_UP interface { + Swigcptr() uintptr + SwigIsInterface_UP() +} + +type SwigcptrInterface_BP uintptr + +func (p SwigcptrInterface_BP) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrInterface_BP) SwigIsInterface_BP() { +} + +var _wrap_new_Interface_BP unsafe.Pointer + +func _swig_wrap_new_Interface_BP() (base SwigcptrInterface_BP) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Interface_BP, _swig_p) + return +} + +func NewInterface_BP() (_swig_ret Interface_BP) { + return _swig_wrap_new_Interface_BP() +} + +var _wrap_delete_Interface_BP unsafe.Pointer + +func _swig_wrap_delete_Interface_BP(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Interface_BP, _swig_p) + return +} + +func DeleteInterface_BP(arg1 Interface_BP) { + _swig_wrap_delete_Interface_BP(arg1.Swigcptr()) +} + +type Interface_BP interface { + Swigcptr() uintptr + SwigIsInterface_BP() +} + +type SwigcptrNatural_UP uintptr + +func (p SwigcptrNatural_UP) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrNatural_UP) SwigIsNatural_UP() { +} + +var _wrap_Natural_UP_rtest unsafe.Pointer + +func _swig_wrap_Natural_UP_rtest(base SwigcptrNatural_UP) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Natural_UP_rtest, _swig_p) + return +} + +func (arg1 SwigcptrNatural_UP) Rtest() (_swig_ret int) { + return _swig_wrap_Natural_UP_rtest(arg1) +} + +var _wrap_new_Natural_UP unsafe.Pointer + +func _swig_wrap_new_Natural_UP() (base SwigcptrNatural_UP) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Natural_UP, _swig_p) + return +} + +func NewNatural_UP() (_swig_ret Natural_UP) { + return _swig_wrap_new_Natural_UP() +} + +var _wrap_delete_Natural_UP unsafe.Pointer + +func _swig_wrap_delete_Natural_UP(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Natural_UP, _swig_p) + return +} + +func DeleteNatural_UP(arg1 Natural_UP) { + _swig_wrap_delete_Natural_UP(arg1.Swigcptr()) +} + +func (p SwigcptrNatural_UP) SwigIsInterface_UP() { +} + +func (p SwigcptrNatural_UP) SwigGetInterface_UP() Interface_UP { + return SwigcptrInterface_UP(p.Swigcptr()) +} + +type Natural_UP interface { + Swigcptr() uintptr + SwigIsNatural_UP() + Rtest() (_swig_ret int) + SwigIsInterface_UP() + SwigGetInterface_UP() Interface_UP +} + +type SwigcptrNatural_BP uintptr + +func (p SwigcptrNatural_BP) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrNatural_BP) SwigIsNatural_BP() { +} + +var _wrap_Natural_BP_rtest unsafe.Pointer + +func _swig_wrap_Natural_BP_rtest(base SwigcptrNatural_BP) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Natural_BP_rtest, _swig_p) + return +} + +func (arg1 SwigcptrNatural_BP) Rtest() (_swig_ret int) { + return _swig_wrap_Natural_BP_rtest(arg1) +} + +var _wrap_new_Natural_BP unsafe.Pointer + +func _swig_wrap_new_Natural_BP() (base SwigcptrNatural_BP) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Natural_BP, _swig_p) + return +} + +func NewNatural_BP() (_swig_ret Natural_BP) { + return _swig_wrap_new_Natural_BP() +} + +var _wrap_delete_Natural_BP unsafe.Pointer + +func _swig_wrap_delete_Natural_BP(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Natural_BP, _swig_p) + return +} + +func DeleteNatural_BP(arg1 Natural_BP) { + _swig_wrap_delete_Natural_BP(arg1.Swigcptr()) +} + +func (p SwigcptrNatural_BP) SwigIsInterface_BP() { +} + +func (p SwigcptrNatural_BP) SwigGetInterface_BP() Interface_BP { + return SwigcptrInterface_BP(p.Swigcptr()) +} + +type Natural_BP interface { + Swigcptr() uintptr + SwigIsNatural_BP() + Rtest() (_swig_ret int) + SwigIsInterface_BP() + SwigGetInterface_BP() Interface_BP +} + +type SwigcptrBucket uintptr + +func (p SwigcptrBucket) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrBucket) SwigIsBucket() { +} + +var _wrap_new_Bucket unsafe.Pointer + +func _swig_wrap_new_Bucket() (base SwigcptrBucket) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Bucket, _swig_p) + return +} + +func NewBucket() (_swig_ret Bucket) { + return _swig_wrap_new_Bucket() +} + +var _wrap_equals unsafe.Pointer + +func _swig_wrap_equals(base uintptr, _ uintptr) (_ bool) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_equals, _swig_p) + return +} + +func Equals(arg1 Bucket, arg2 Bucket) (_swig_ret bool) { + return _swig_wrap_equals(arg1.Swigcptr(), arg2.Swigcptr()) +} + +var _wrap_delete_Bucket unsafe.Pointer + +func _swig_wrap_delete_Bucket(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Bucket, _swig_p) + return +} + +func DeleteBucket(arg1 Bucket) { + _swig_wrap_delete_Bucket(arg1.Swigcptr()) +} + +type Bucket interface { + Swigcptr() uintptr + SwigIsBucket() +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/rename_scope_runme b/Examples/test-suite/go/rename_scope_runme new file mode 100755 index 000000000..36112680e Binary files /dev/null and b/Examples/test-suite/go/rename_scope_runme differ diff --git a/Examples/test-suite/go/rename_simple.go b/Examples/test-suite/go/rename_simple.go new file mode 100644 index 000000000..92b20e273 --- /dev/null +++ b/Examples/test-suite/go/rename_simple.go @@ -0,0 +1,190 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../rename_simple.i + +package rename_simple + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrNewStruct uintptr + +func (p SwigcptrNewStruct) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrNewStruct) SwigIsNewStruct() { +} + +var _wrap_ONE_NewStruct unsafe.Pointer + +func _swig_getNewStruct_ONE_NewStruct() (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_ONE_NewStruct, _swig_p) + return +} +var NewStructONE int = _swig_getNewStruct_ONE_NewStruct() +var _wrap_TWO_NewStruct unsafe.Pointer + +func _swig_getNewStruct_TWO_NewStruct() (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_TWO_NewStruct, _swig_p) + return +} +var NewStructTWO int = _swig_getNewStruct_TWO_NewStruct() +var _wrap_THREE_NewStruct unsafe.Pointer + +func _swig_getNewStruct_THREE_NewStruct() (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_THREE_NewStruct, _swig_p) + return +} +var NewStructTHREE int = _swig_getNewStruct_THREE_NewStruct() +var _wrap_new_NewStruct unsafe.Pointer + +func _swig_wrap_new_NewStruct() (base SwigcptrNewStruct) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_NewStruct, _swig_p) + return +} + +func NewNewStruct() (_swig_ret NewStruct) { + return _swig_wrap_new_NewStruct() +} + +var _wrap_NewStruct_NewInstanceVariable_set unsafe.Pointer + +func _swig_wrap_NewStruct_NewInstanceVariable_set(base SwigcptrNewStruct, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_NewStruct_NewInstanceVariable_set, _swig_p) + return +} + +func (arg1 SwigcptrNewStruct) SetNewInstanceVariable(arg2 int) { + _swig_wrap_NewStruct_NewInstanceVariable_set(arg1, arg2) +} + +var _wrap_NewStruct_NewInstanceVariable_get unsafe.Pointer + +func _swig_wrap_NewStruct_NewInstanceVariable_get(base SwigcptrNewStruct) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_NewStruct_NewInstanceVariable_get, _swig_p) + return +} + +func (arg1 SwigcptrNewStruct) GetNewInstanceVariable() (_swig_ret int) { + return _swig_wrap_NewStruct_NewInstanceVariable_get(arg1) +} + +var _wrap_NewStruct_NewInstanceMethod unsafe.Pointer + +func _swig_wrap_NewStruct_NewInstanceMethod(base SwigcptrNewStruct) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_NewStruct_NewInstanceMethod, _swig_p) + return +} + +func (arg1 SwigcptrNewStruct) NewInstanceMethod() (_swig_ret int) { + return _swig_wrap_NewStruct_NewInstanceMethod(arg1) +} + +var _wrap_NewStruct_NewStaticVariable_set unsafe.Pointer + +func _swig_wrap_NewStruct_NewStaticVariable_set(base int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_NewStruct_NewStaticVariable_set, _swig_p) + return +} + +func SetNewStructNewStaticVariable(arg1 int) { + _swig_wrap_NewStruct_NewStaticVariable_set(arg1) +} + +var _wrap_NewStruct_NewStaticVariable_get unsafe.Pointer + +func GetNewStructNewStaticVariable() (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_NewStruct_NewStaticVariable_get, _swig_p) + return +} +var _wrap_NewStruct_NewStaticMethod unsafe.Pointer + +func NewStructNewStaticMethod() (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_NewStruct_NewStaticMethod, _swig_p) + return +} +var _wrap_delete_NewStruct unsafe.Pointer + +func _swig_wrap_delete_NewStruct(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_NewStruct, _swig_p) + return +} + +func DeleteNewStruct(arg1 NewStruct) { + _swig_wrap_delete_NewStruct(arg1.Swigcptr()) +} + +type NewStruct interface { + Swigcptr() uintptr + SwigIsNewStruct() + SetNewInstanceVariable(arg2 int) + GetNewInstanceVariable() (_swig_ret int) + NewInstanceMethod() (_swig_ret int) +} + +var _wrap_NewFunction unsafe.Pointer + +func NewFunction() (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_NewFunction, _swig_p) + return +} +var _wrap_NewGlobalVariable_set unsafe.Pointer + +func _swig_wrap_NewGlobalVariable_set(base int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_NewGlobalVariable_set, _swig_p) + return +} + +func SetNewGlobalVariable(arg1 int) { + _swig_wrap_NewGlobalVariable_set(arg1) +} + +var _wrap_NewGlobalVariable_get unsafe.Pointer + +func GetNewGlobalVariable() (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_NewGlobalVariable_get, _swig_p) + return +} + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/rename_simple_runme b/Examples/test-suite/go/rename_simple_runme new file mode 100755 index 000000000..df2bb2983 Binary files /dev/null and b/Examples/test-suite/go/rename_simple_runme differ diff --git a/Examples/test-suite/go/rename_strip_encoder.go b/Examples/test-suite/go/rename_strip_encoder.go new file mode 100644 index 000000000..e0cedabb9 --- /dev/null +++ b/Examples/test-suite/go/rename_strip_encoder.go @@ -0,0 +1,126 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../rename_strip_encoder.i + +package rename_strip_encoder + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrSomeWidget uintptr + +func (p SwigcptrSomeWidget) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrSomeWidget) SwigIsSomeWidget() { +} + +var _wrap_new_SomeWidget unsafe.Pointer + +func _swig_wrap_new_SomeWidget() (base SwigcptrSomeWidget) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_SomeWidget, _swig_p) + return +} + +func NewSomeWidget() (_swig_ret SomeWidget) { + return _swig_wrap_new_SomeWidget() +} + +var _wrap_delete_SomeWidget unsafe.Pointer + +func _swig_wrap_delete_SomeWidget(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_SomeWidget, _swig_p) + return +} + +func DeleteSomeWidget(arg1 SomeWidget) { + _swig_wrap_delete_SomeWidget(arg1.Swigcptr()) +} + +type SomeWidget interface { + Swigcptr() uintptr + SwigIsSomeWidget() +} + +type SwigcptrAnotherWidget uintptr + +func (p SwigcptrAnotherWidget) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrAnotherWidget) SwigIsAnotherWidget() { +} + +var _wrap_AnotherWidget_DoSomething unsafe.Pointer + +func _swig_wrap_AnotherWidget_DoSomething(base SwigcptrAnotherWidget) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_AnotherWidget_DoSomething, _swig_p) + return +} + +func (arg1 SwigcptrAnotherWidget) DoSomething() { + _swig_wrap_AnotherWidget_DoSomething(arg1) +} + +var _wrap_new_AnotherWidget unsafe.Pointer + +func _swig_wrap_new_AnotherWidget() (base SwigcptrAnotherWidget) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_AnotherWidget, _swig_p) + return +} + +func NewAnotherWidget() (_swig_ret AnotherWidget) { + return _swig_wrap_new_AnotherWidget() +} + +var _wrap_delete_AnotherWidget unsafe.Pointer + +func _swig_wrap_delete_AnotherWidget(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_AnotherWidget, _swig_p) + return +} + +func DeleteAnotherWidget(arg1 AnotherWidget) { + _swig_wrap_delete_AnotherWidget(arg1.Swigcptr()) +} + +type AnotherWidget interface { + Swigcptr() uintptr + SwigIsAnotherWidget() + DoSomething() +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/rename_strip_encoder_runme b/Examples/test-suite/go/rename_strip_encoder_runme new file mode 100755 index 000000000..dd7dcd5b8 Binary files /dev/null and b/Examples/test-suite/go/rename_strip_encoder_runme differ diff --git a/Examples/test-suite/go/restrict_cplusplus.go b/Examples/test-suite/go/restrict_cplusplus.go new file mode 100644 index 000000000..4c0706a33 --- /dev/null +++ b/Examples/test-suite/go/restrict_cplusplus.go @@ -0,0 +1,101 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../restrict_cplusplus.i + +package restrict_cplusplus + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrFoo uintptr + +func (p SwigcptrFoo) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrFoo) SwigIsFoo() { +} + +var _wrap_Foo_restrict_set unsafe.Pointer + +func _swig_wrap_Foo_restrict_set(base SwigcptrFoo, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_restrict_set, _swig_p) + return +} + +func (arg1 SwigcptrFoo) SetRestrict(arg2 int) { + _swig_wrap_Foo_restrict_set(arg1, arg2) +} + +var _wrap_Foo_restrict_get unsafe.Pointer + +func _swig_wrap_Foo_restrict_get(base SwigcptrFoo) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_restrict_get, _swig_p) + return +} + +func (arg1 SwigcptrFoo) GetRestrict() (_swig_ret int) { + return _swig_wrap_Foo_restrict_get(arg1) +} + +var _wrap_new_Foo unsafe.Pointer + +func _swig_wrap_new_Foo() (base SwigcptrFoo) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Foo, _swig_p) + return +} + +func NewFoo() (_swig_ret Foo) { + return _swig_wrap_new_Foo() +} + +var _wrap_delete_Foo unsafe.Pointer + +func _swig_wrap_delete_Foo(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Foo, _swig_p) + return +} + +func DeleteFoo(arg1 Foo) { + _swig_wrap_delete_Foo(arg1.Swigcptr()) +} + +type Foo interface { + Swigcptr() uintptr + SwigIsFoo() + SetRestrict(arg2 int) + GetRestrict() (_swig_ret int) +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/ret_by_value.go b/Examples/test-suite/go/ret_by_value.go new file mode 100644 index 000000000..e8ffd5700 --- /dev/null +++ b/Examples/test-suite/go/ret_by_value.go @@ -0,0 +1,139 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../ret_by_value.i + +package ret_by_value + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrTest uintptr + +func (p SwigcptrTest) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrTest) SwigIsTest() { +} + +var _wrap_test_myInt_set unsafe.Pointer + +func _swig_wrap_test_myInt_set(base SwigcptrTest, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_test_myInt_set, _swig_p) + return +} + +func (arg1 SwigcptrTest) SetMyInt(arg2 int) { + _swig_wrap_test_myInt_set(arg1, arg2) +} + +var _wrap_test_myInt_get unsafe.Pointer + +func _swig_wrap_test_myInt_get(base SwigcptrTest) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_test_myInt_get, _swig_p) + return +} + +func (arg1 SwigcptrTest) GetMyInt() (_swig_ret int) { + return _swig_wrap_test_myInt_get(arg1) +} + +var _wrap_test_myShort_set unsafe.Pointer + +func _swig_wrap_test_myShort_set(base SwigcptrTest, _ int16) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_test_myShort_set, _swig_p) + return +} + +func (arg1 SwigcptrTest) SetMyShort(arg2 int16) { + _swig_wrap_test_myShort_set(arg1, arg2) +} + +var _wrap_test_myShort_get unsafe.Pointer + +func _swig_wrap_test_myShort_get(base SwigcptrTest) (_ int16) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_test_myShort_get, _swig_p) + return +} + +func (arg1 SwigcptrTest) GetMyShort() (_swig_ret int16) { + return _swig_wrap_test_myShort_get(arg1) +} + +var _wrap_new_test unsafe.Pointer + +func _swig_wrap_new_test() (base SwigcptrTest) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_test, _swig_p) + return +} + +func NewTest() (_swig_ret Test) { + return _swig_wrap_new_test() +} + +var _wrap_delete_test unsafe.Pointer + +func _swig_wrap_delete_test(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_test, _swig_p) + return +} + +func DeleteTest(arg1 Test) { + _swig_wrap_delete_test(arg1.Swigcptr()) +} + +type Test interface { + Swigcptr() uintptr + SwigIsTest() + SetMyInt(arg2 int) + GetMyInt() (_swig_ret int) + SetMyShort(arg2 int16) + GetMyShort() (_swig_ret int16) +} + +var _wrap_get_test unsafe.Pointer + +func _swig_wrap_get_test() (base SwigcptrTest) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_get_test, _swig_p) + return +} + +func Get_test() (_swig_ret Test) { + return _swig_wrap_get_test() +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/ret_by_value_runme b/Examples/test-suite/go/ret_by_value_runme new file mode 100755 index 000000000..0ac7b6d8e Binary files /dev/null and b/Examples/test-suite/go/ret_by_value_runme differ diff --git a/Examples/test-suite/go/return_const_value.go b/Examples/test-suite/go/return_const_value.go new file mode 100644 index 000000000..489d0fbe7 --- /dev/null +++ b/Examples/test-suite/go/return_const_value.go @@ -0,0 +1,257 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../return_const_value.i + +package return_const_value + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrFoo uintptr + +func (p SwigcptrFoo) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrFoo) SwigIsFoo() { +} + +var _wrap_Foo__val_set unsafe.Pointer + +func _swig_wrap_Foo__val_set(base SwigcptrFoo, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo__val_set, _swig_p) + return +} + +func (arg1 SwigcptrFoo) SetX_val(arg2 int) { + _swig_wrap_Foo__val_set(arg1, arg2) +} + +var _wrap_Foo__val_get unsafe.Pointer + +func _swig_wrap_Foo__val_get(base SwigcptrFoo) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo__val_get, _swig_p) + return +} + +func (arg1 SwigcptrFoo) GetX_val() (_swig_ret int) { + return _swig_wrap_Foo__val_get(arg1) +} + +var _wrap_new_Foo unsafe.Pointer + +func _swig_wrap_new_Foo(base int) (_ SwigcptrFoo) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Foo, _swig_p) + return +} + +func NewFoo(arg1 int) (_swig_ret Foo) { + return _swig_wrap_new_Foo(arg1) +} + +var _wrap_Foo_getVal unsafe.Pointer + +func _swig_wrap_Foo_getVal(base SwigcptrFoo) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_getVal, _swig_p) + return +} + +func (arg1 SwigcptrFoo) GetVal() (_swig_ret int) { + return _swig_wrap_Foo_getVal(arg1) +} + +var _wrap_delete_Foo unsafe.Pointer + +func _swig_wrap_delete_Foo(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Foo, _swig_p) + return +} + +func DeleteFoo(arg1 Foo) { + _swig_wrap_delete_Foo(arg1.Swigcptr()) +} + +type Foo interface { + Swigcptr() uintptr + SwigIsFoo() + SetX_val(arg2 int) + GetX_val() (_swig_ret int) + GetVal() (_swig_ret int) +} + +type SwigcptrFoo_ptr uintptr + +func (p SwigcptrFoo_ptr) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrFoo_ptr) SwigIsFoo_ptr() { +} + +var _wrap_new_Foo_ptr__SWIG_0 unsafe.Pointer + +func _swig_wrap_new_Foo_ptr__SWIG_0(base uintptr, _ bool) (_ SwigcptrFoo_ptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Foo_ptr__SWIG_0, _swig_p) + return +} + +func NewFoo_ptr__SWIG_0(arg1 Foo, arg2 bool) (_swig_ret Foo_ptr) { + return _swig_wrap_new_Foo_ptr__SWIG_0(arg1.Swigcptr(), arg2) +} + +var _wrap_new_Foo_ptr__SWIG_1 unsafe.Pointer + +func _swig_wrap_new_Foo_ptr__SWIG_1(base uintptr) (_ SwigcptrFoo_ptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Foo_ptr__SWIG_1, _swig_p) + return +} + +func NewFoo_ptr__SWIG_1(arg1 Foo) (_swig_ret Foo_ptr) { + return _swig_wrap_new_Foo_ptr__SWIG_1(arg1.Swigcptr()) +} + +var _wrap_Foo_ptr_getPtr unsafe.Pointer + +func _swig_wrap_Foo_ptr_getPtr() (base SwigcptrFoo_ptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_ptr_getPtr, _swig_p) + return +} + +func Foo_ptrGetPtr() (_swig_ret Foo_ptr) { + return _swig_wrap_Foo_ptr_getPtr() +} + +var _wrap_Foo_ptr_getConstPtr unsafe.Pointer + +func _swig_wrap_Foo_ptr_getConstPtr() (base SwigcptrFoo_ptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_ptr_getConstPtr, _swig_p) + return +} + +func Foo_ptrGetConstPtr() (_swig_ret Foo_ptr) { + return _swig_wrap_Foo_ptr_getConstPtr() +} + +var _wrap_Foo_ptr___deref__ unsafe.Pointer + +func _swig_wrap_Foo_ptr___deref__(base SwigcptrFoo_ptr) (_ SwigcptrFoo) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_ptr___deref__, _swig_p) + return +} + +func (arg1 SwigcptrFoo_ptr) X__deref__() (_swig_ret Foo) { + return _swig_wrap_Foo_ptr___deref__(arg1) +} + +var _wrap_new_Foo_ptr__SWIG_2 unsafe.Pointer + +func _swig_wrap_new_Foo_ptr__SWIG_2(base uintptr) (_ SwigcptrFoo_ptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Foo_ptr__SWIG_2, _swig_p) + return +} + +func NewFoo_ptr__SWIG_2(arg1 Foo_ptr) (_swig_ret Foo_ptr) { + return _swig_wrap_new_Foo_ptr__SWIG_2(arg1.Swigcptr()) +} + +func NewFoo_ptr(a ...interface{}) Foo_ptr { + argc := len(a) + if argc == 1 { + if _, ok := a[0].(Foo); !ok { + goto check_1 + } + return NewFoo_ptr__SWIG_1(a[0].(Foo)) + } +check_1: + if argc == 1 { + return NewFoo_ptr__SWIG_2(a[0].(Foo_ptr)) + } + if argc == 2 { + return NewFoo_ptr__SWIG_0(a[0].(Foo), a[1].(bool)) + } + panic("No match for overloaded function call") +} + +var _wrap_delete_Foo_ptr unsafe.Pointer + +func _swig_wrap_delete_Foo_ptr(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Foo_ptr, _swig_p) + return +} + +func DeleteFoo_ptr(arg1 Foo_ptr) { + _swig_wrap_delete_Foo_ptr(arg1.Swigcptr()) +} + +var _wrap_Foo_ptr__val_get unsafe.Pointer + +func _swig_wrap_Foo_ptr__val_get(base SwigcptrFoo_ptr) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_ptr__val_get, _swig_p) + return +} + +func (arg1 SwigcptrFoo_ptr) GetX_val() (_swig_ret int) { + return _swig_wrap_Foo_ptr__val_get(arg1) +} + +var _wrap_Foo_ptr_getVal unsafe.Pointer + +func _swig_wrap_Foo_ptr_getVal(base SwigcptrFoo_ptr) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_ptr_getVal, _swig_p) + return +} + +func (arg1 SwigcptrFoo_ptr) GetVal() (_swig_ret int) { + return _swig_wrap_Foo_ptr_getVal(arg1) +} + +type Foo_ptr interface { + Swigcptr() uintptr + SwigIsFoo_ptr() + X__deref__() (_swig_ret Foo) + GetX_val() (_swig_ret int) + GetVal() (_swig_ret int) +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/return_const_value_runme b/Examples/test-suite/go/return_const_value_runme new file mode 100755 index 000000000..5de430b26 Binary files /dev/null and b/Examples/test-suite/go/return_const_value_runme differ diff --git a/Examples/test-suite/go/return_value_scope.go b/Examples/test-suite/go/return_value_scope.go new file mode 100644 index 000000000..f00e591cb --- /dev/null +++ b/Examples/test-suite/go/return_value_scope.go @@ -0,0 +1,164 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../return_value_scope.i + +package return_value_scope + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrFoo uintptr + +func (p SwigcptrFoo) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrFoo) SwigIsFoo() { +} + +var _wrap_new_Foo unsafe.Pointer + +func _swig_wrap_new_Foo(base int) (_ SwigcptrFoo) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Foo, _swig_p) + return +} + +func NewFoo(arg1 int) (_swig_ret Foo) { + return _swig_wrap_new_Foo(arg1) +} + +var _wrap_delete_Foo unsafe.Pointer + +func _swig_wrap_delete_Foo(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Foo, _swig_p) + return +} + +func DeleteFoo(arg1 Foo) { + _swig_wrap_delete_Foo(arg1.Swigcptr()) +} + +type Foo interface { + Swigcptr() uintptr + SwigIsFoo() +} + +type SwigcptrBar uintptr + +func (p SwigcptrBar) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrBar) SwigIsBar() { +} + +var _wrap_new_Bar unsafe.Pointer + +func _swig_wrap_new_Bar() (base SwigcptrBar) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Bar, _swig_p) + return +} + +func NewBar() (_swig_ret Bar) { + return _swig_wrap_new_Bar() +} + +var _wrap_delete_Bar unsafe.Pointer + +func _swig_wrap_delete_Bar(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Bar, _swig_p) + return +} + +func DeleteBar(arg1 Bar) { + _swig_wrap_delete_Bar(arg1.Swigcptr()) +} + +type Bar interface { + Swigcptr() uintptr + SwigIsBar() +} + +type SwigcptrSpam uintptr + +func (p SwigcptrSpam) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrSpam) SwigIsSpam() { +} + +var _wrap_Spam_test unsafe.Pointer + +func _swig_wrap_Spam_test(base SwigcptrSpam) (_ SwigcptrFoo) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Spam_test, _swig_p) + return +} + +func (arg1 SwigcptrSpam) Test() (_swig_ret Foo) { + return _swig_wrap_Spam_test(arg1) +} + +var _wrap_new_Spam unsafe.Pointer + +func _swig_wrap_new_Spam() (base SwigcptrSpam) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Spam, _swig_p) + return +} + +func NewSpam() (_swig_ret Spam) { + return _swig_wrap_new_Spam() +} + +var _wrap_delete_Spam unsafe.Pointer + +func _swig_wrap_delete_Spam(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Spam, _swig_p) + return +} + +func DeleteSpam(arg1 Spam) { + _swig_wrap_delete_Spam(arg1.Swigcptr()) +} + +type Spam interface { + Swigcptr() uintptr + SwigIsSpam() + Test() (_swig_ret Foo) +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/rname.go b/Examples/test-suite/go/rname.go new file mode 100644 index 000000000..7498f2829 --- /dev/null +++ b/Examples/test-suite/go/rname.go @@ -0,0 +1,292 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../rname.i + +package rname + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrBar uintptr + +func (p SwigcptrBar) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrBar) SwigIsBar() { +} + +var _wrap_Bar_foo_i unsafe.Pointer + +func _swig_wrap_Bar_foo_i(base SwigcptrBar, _ int) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Bar_foo_i, _swig_p) + return +} + +func (arg1 SwigcptrBar) Foo_i(arg2 int) (_swig_ret string) { + return _swig_wrap_Bar_foo_i(arg1, arg2) +} + +var _wrap_Bar_foo_d unsafe.Pointer + +func _swig_wrap_Bar_foo_d(base SwigcptrBar, _ float64) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Bar_foo_d, _swig_p) + return +} + +func (arg1 SwigcptrBar) Foo_d(arg2 float64) (_swig_ret string) { + return _swig_wrap_Bar_foo_d(arg1, arg2) +} + +var _wrap_Bar_foo unsafe.Pointer + +func _swig_wrap_Bar_foo(base SwigcptrBar, _ int16) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Bar_foo, _swig_p) + return +} + +func (arg1 SwigcptrBar) Foo(arg2 int16) (_swig_ret string) { + return _swig_wrap_Bar_foo(arg1, arg2) +} + +var _wrap_Bar_foo_u unsafe.Pointer + +func _swig_wrap_Bar_foo_u(base SwigcptrBar, _ uint) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Bar_foo_u, _swig_p) + return +} + +func (arg1 SwigcptrBar) Foo_u(arg2 uint) (_swig_ret string) { + return _swig_wrap_Bar_foo_u(arg1, arg2) +} + +var _wrap_new_Bar unsafe.Pointer + +func _swig_wrap_new_Bar() (base SwigcptrBar) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Bar, _swig_p) + return +} + +func NewBar() (_swig_ret Bar) { + return _swig_wrap_new_Bar() +} + +var _wrap_delete_Bar unsafe.Pointer + +func _swig_wrap_delete_Bar(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Bar, _swig_p) + return +} + +func DeleteBar(arg1 Bar) { + _swig_wrap_delete_Bar(arg1.Swigcptr()) +} + +type Bar interface { + Swigcptr() uintptr + SwigIsBar() + Foo_i(arg2 int) (_swig_ret string) + Foo_d(arg2 float64) (_swig_ret string) + Foo(arg2 int16) (_swig_ret string) + Foo_u(arg2 uint) (_swig_ret string) +} + +var _wrap_foo_i unsafe.Pointer + +func Foo_i(arg1 int) (_swig_ret string) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_foo_i, _swig_p) + return +} +var _wrap_foo_d unsafe.Pointer + +func Foo_d(arg1 float64) (_swig_ret string) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_foo_d, _swig_p) + return +} +var _wrap_foo_s unsafe.Pointer + +func Foo_s(arg1 int16) (_swig_ret string) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_foo_s, _swig_p) + return +} +var _wrap_foo unsafe.Pointer + +func Foo(arg1 uint) (_swig_ret string) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_foo, _swig_p) + return +} +type SwigcptrRenamedBase uintptr + +func (p SwigcptrRenamedBase) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrRenamedBase) SwigIsRenamedBase() { +} + +var _wrap_new_RenamedBase unsafe.Pointer + +func _swig_wrap_new_RenamedBase() (base SwigcptrRenamedBase) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_RenamedBase, _swig_p) + return +} + +func NewRenamedBase() (_swig_ret RenamedBase) { + return _swig_wrap_new_RenamedBase() +} + +var _wrap_delete_RenamedBase unsafe.Pointer + +func _swig_wrap_delete_RenamedBase(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_RenamedBase, _swig_p) + return +} + +func DeleteRenamedBase(arg1 RenamedBase) { + _swig_wrap_delete_RenamedBase(arg1.Swigcptr()) +} + +var _wrap_RenamedBase_fn unsafe.Pointer + +func _swig_wrap_RenamedBase_fn(base SwigcptrRenamedBase, _ uintptr, _ uintptr, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_RenamedBase_fn, _swig_p) + return +} + +func (arg1 SwigcptrRenamedBase) Fn(arg2 RenamedBase, arg3 RenamedBase, arg4 RenamedBase) { + _swig_wrap_RenamedBase_fn(arg1, arg2.Swigcptr(), arg3.Swigcptr(), arg4.Swigcptr()) +} + +var _wrap_RenamedBase_newname unsafe.Pointer + +func _swig_wrap_RenamedBase_newname(base SwigcptrRenamedBase, _ float64) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_RenamedBase_newname, _swig_p) + return +} + +func (arg1 SwigcptrRenamedBase) Newname(arg2 float64) (_swig_ret string) { + return _swig_wrap_RenamedBase_newname(arg1, arg2) +} + +type RenamedBase interface { + Swigcptr() uintptr + SwigIsRenamedBase() + Fn(arg2 RenamedBase, arg3 RenamedBase, arg4 RenamedBase) + Newname(arg2 float64) (_swig_ret string) +} + +type SwigcptrRenamedDerived uintptr + +func (p SwigcptrRenamedDerived) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrRenamedDerived) SwigIsRenamedDerived() { +} + +var _wrap_new_RenamedDerived unsafe.Pointer + +func _swig_wrap_new_RenamedDerived() (base SwigcptrRenamedDerived) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_RenamedDerived, _swig_p) + return +} + +func NewRenamedDerived() (_swig_ret RenamedDerived) { + return _swig_wrap_new_RenamedDerived() +} + +var _wrap_delete_RenamedDerived unsafe.Pointer + +func _swig_wrap_delete_RenamedDerived(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_RenamedDerived, _swig_p) + return +} + +func DeleteRenamedDerived(arg1 RenamedDerived) { + _swig_wrap_delete_RenamedDerived(arg1.Swigcptr()) +} + +var _wrap_RenamedDerived_Xfunc unsafe.Pointer + +func _swig_wrap_RenamedDerived_Xfunc(base SwigcptrRenamedDerived, _ uintptr, _ uintptr, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_RenamedDerived_Xfunc, _swig_p) + return +} + +func (arg1 SwigcptrRenamedDerived) Xfunc(arg2 RenamedBase, arg3 RenamedBase, arg4 RenamedBase) { + _swig_wrap_RenamedDerived_Xfunc(arg1, arg2.Swigcptr(), arg3.Swigcptr(), arg4.Swigcptr()) +} + +var _wrap_RenamedDerived_newname unsafe.Pointer + +func _swig_wrap_RenamedDerived_newname(base SwigcptrRenamedDerived, _ float64) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_RenamedDerived_newname, _swig_p) + return +} + +func (arg1 SwigcptrRenamedDerived) Newname(arg2 float64) (_swig_ret string) { + return _swig_wrap_RenamedDerived_newname(arg1, arg2) +} + +func (p SwigcptrRenamedDerived) SwigIsRenamedBase() { +} + +func (p SwigcptrRenamedDerived) SwigGetRenamedBase() RenamedBase { + return SwigcptrRenamedBase(p.Swigcptr()) +} + +type RenamedDerived interface { + Swigcptr() uintptr + SwigIsRenamedDerived() + Xfunc(arg2 RenamedBase, arg3 RenamedBase, arg4 RenamedBase) + Newname(arg2 float64) (_swig_ret string) + SwigIsRenamedBase() + SwigGetRenamedBase() RenamedBase +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/samename.go b/Examples/test-suite/go/samename.go new file mode 100644 index 000000000..322192826 --- /dev/null +++ b/Examples/test-suite/go/samename.go @@ -0,0 +1,88 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../samename.i + +package samename + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrSamename uintptr + +func (p SwigcptrSamename) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrSamename) SwigIsSamename() { +} + +var _wrap_samename_do_something unsafe.Pointer + +func _swig_wrap_samename_do_something(base SwigcptrSamename) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_samename_do_something, _swig_p) + return +} + +func (arg1 SwigcptrSamename) Do_something() { + _swig_wrap_samename_do_something(arg1) +} + +var _wrap_new_samename unsafe.Pointer + +func _swig_wrap_new_samename() (base SwigcptrSamename) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_samename, _swig_p) + return +} + +func NewSamename() (_swig_ret Samename) { + return _swig_wrap_new_samename() +} + +var _wrap_delete_samename unsafe.Pointer + +func _swig_wrap_delete_samename(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_samename, _swig_p) + return +} + +func DeleteSamename(arg1 Samename) { + _swig_wrap_delete_samename(arg1.Swigcptr()) +} + +type Samename interface { + Swigcptr() uintptr + SwigIsSamename() + Do_something() +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/simple_array.go b/Examples/test-suite/go/simple_array.go new file mode 100644 index 000000000..2dfe676fb --- /dev/null +++ b/Examples/test-suite/go/simple_array.go @@ -0,0 +1,201 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../simple_array.i + +package simple_array + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +var _wrap_x_set unsafe.Pointer + +func _swig_wrap_x_set(base *int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_x_set, _swig_p) + return +} + +func SetX(arg1 *int) { + _swig_wrap_x_set(arg1) +} + +var _wrap_x_get unsafe.Pointer + +func GetX() (_swig_ret *int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_x_get, _swig_p) + return +} +var _wrap_y_set unsafe.Pointer + +func _swig_wrap_y_set(base *float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_y_set, _swig_p) + return +} + +func SetY(arg1 *float64) { + _swig_wrap_y_set(arg1) +} + +var _wrap_y_get unsafe.Pointer + +func GetY() (_swig_ret *float64) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_y_get, _swig_p) + return +} +type SwigcptrBarArray uintptr + +func (p SwigcptrBarArray) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrBarArray) SwigIsBarArray() { +} + +var _wrap_BarArray_i_set unsafe.Pointer + +func _swig_wrap_BarArray_i_set(base SwigcptrBarArray, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_BarArray_i_set, _swig_p) + return +} + +func (arg1 SwigcptrBarArray) SetI(arg2 int) { + _swig_wrap_BarArray_i_set(arg1, arg2) +} + +var _wrap_BarArray_i_get unsafe.Pointer + +func _swig_wrap_BarArray_i_get(base SwigcptrBarArray) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_BarArray_i_get, _swig_p) + return +} + +func (arg1 SwigcptrBarArray) GetI() (_swig_ret int) { + return _swig_wrap_BarArray_i_get(arg1) +} + +var _wrap_BarArray_d_set unsafe.Pointer + +func _swig_wrap_BarArray_d_set(base SwigcptrBarArray, _ float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_BarArray_d_set, _swig_p) + return +} + +func (arg1 SwigcptrBarArray) SetD(arg2 float64) { + _swig_wrap_BarArray_d_set(arg1, arg2) +} + +var _wrap_BarArray_d_get unsafe.Pointer + +func _swig_wrap_BarArray_d_get(base SwigcptrBarArray) (_ float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_BarArray_d_get, _swig_p) + return +} + +func (arg1 SwigcptrBarArray) GetD() (_swig_ret float64) { + return _swig_wrap_BarArray_d_get(arg1) +} + +var _wrap_new_BarArray unsafe.Pointer + +func _swig_wrap_new_BarArray() (base SwigcptrBarArray) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_BarArray, _swig_p) + return +} + +func NewBarArray() (_swig_ret BarArray) { + return _swig_wrap_new_BarArray() +} + +var _wrap_delete_BarArray unsafe.Pointer + +func _swig_wrap_delete_BarArray(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_BarArray, _swig_p) + return +} + +func DeleteBarArray(arg1 BarArray) { + _swig_wrap_delete_BarArray(arg1.Swigcptr()) +} + +type BarArray interface { + Swigcptr() uintptr + SwigIsBarArray() + SetI(arg2 int) + GetI() (_swig_ret int) + SetD(arg2 float64) + GetD() (_swig_ret float64) +} + +var _wrap_bars_set unsafe.Pointer + +func _swig_wrap_bars_set(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_bars_set, _swig_p) + return +} + +func SetBars(arg1 BarArray) { + _swig_wrap_bars_set(arg1.Swigcptr()) +} + +var _wrap_bars_get unsafe.Pointer + +func _swig_wrap_bars_get() (base SwigcptrBarArray) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_bars_get, _swig_p) + return +} + +func GetBars() (_swig_ret BarArray) { + return _swig_wrap_bars_get() +} + +var _wrap_initArray unsafe.Pointer + +func _swig_wrap_initArray() { + var _swig_p uintptr + _cgo_runtime_cgocall(_wrap_initArray, _swig_p) + return +} + +func InitArray() { + _swig_wrap_initArray() +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/sizeof_pointer.go b/Examples/test-suite/go/sizeof_pointer.go new file mode 100644 index 000000000..50ca2a54e --- /dev/null +++ b/Examples/test-suite/go/sizeof_pointer.go @@ -0,0 +1,153 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../sizeof_pointer.i + +package sizeof_pointer + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrSizeofPointerTest uintptr + +func (p SwigcptrSizeofPointerTest) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrSizeofPointerTest) SwigIsSizeofPointerTest() { +} + +var _wrap_SizeofPointerTest_array1_set unsafe.Pointer + +func _swig_wrap_SizeofPointerTest_array1_set(base SwigcptrSizeofPointerTest, _ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_SizeofPointerTest_array1_set, _swig_p) + return +} + +func (arg1 SwigcptrSizeofPointerTest) SetArray1(arg2 string) { + _swig_wrap_SizeofPointerTest_array1_set(arg1, arg2) +} + +var _wrap_SizeofPointerTest_array1_get unsafe.Pointer + +func _swig_wrap_SizeofPointerTest_array1_get(base SwigcptrSizeofPointerTest) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_SizeofPointerTest_array1_get, _swig_p) + return +} + +func (arg1 SwigcptrSizeofPointerTest) GetArray1() (_swig_ret string) { + return _swig_wrap_SizeofPointerTest_array1_get(arg1) +} + +var _wrap_SizeofPointerTest_array2_set unsafe.Pointer + +func _swig_wrap_SizeofPointerTest_array2_set(base SwigcptrSizeofPointerTest, _ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_SizeofPointerTest_array2_set, _swig_p) + return +} + +func (arg1 SwigcptrSizeofPointerTest) SetArray2(arg2 string) { + _swig_wrap_SizeofPointerTest_array2_set(arg1, arg2) +} + +var _wrap_SizeofPointerTest_array2_get unsafe.Pointer + +func _swig_wrap_SizeofPointerTest_array2_get(base SwigcptrSizeofPointerTest) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_SizeofPointerTest_array2_get, _swig_p) + return +} + +func (arg1 SwigcptrSizeofPointerTest) GetArray2() (_swig_ret string) { + return _swig_wrap_SizeofPointerTest_array2_get(arg1) +} + +var _wrap_SizeofPointerTest_array3_set unsafe.Pointer + +func _swig_wrap_SizeofPointerTest_array3_set(base SwigcptrSizeofPointerTest, _ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_SizeofPointerTest_array3_set, _swig_p) + return +} + +func (arg1 SwigcptrSizeofPointerTest) SetArray3(arg2 string) { + _swig_wrap_SizeofPointerTest_array3_set(arg1, arg2) +} + +var _wrap_SizeofPointerTest_array3_get unsafe.Pointer + +func _swig_wrap_SizeofPointerTest_array3_get(base SwigcptrSizeofPointerTest) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_SizeofPointerTest_array3_get, _swig_p) + return +} + +func (arg1 SwigcptrSizeofPointerTest) GetArray3() (_swig_ret string) { + return _swig_wrap_SizeofPointerTest_array3_get(arg1) +} + +var _wrap_new_SizeofPointerTest unsafe.Pointer + +func _swig_wrap_new_SizeofPointerTest() (base SwigcptrSizeofPointerTest) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_SizeofPointerTest, _swig_p) + return +} + +func NewSizeofPointerTest() (_swig_ret SizeofPointerTest) { + return _swig_wrap_new_SizeofPointerTest() +} + +var _wrap_delete_SizeofPointerTest unsafe.Pointer + +func _swig_wrap_delete_SizeofPointerTest(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_SizeofPointerTest, _swig_p) + return +} + +func DeleteSizeofPointerTest(arg1 SizeofPointerTest) { + _swig_wrap_delete_SizeofPointerTest(arg1.Swigcptr()) +} + +type SizeofPointerTest interface { + Swigcptr() uintptr + SwigIsSizeofPointerTest() + SetArray1(arg2 string) + GetArray1() (_swig_ret string) + SetArray2(arg2 string) + GetArray2() (_swig_ret string) + SetArray3(arg2 string) + GetArray3() (_swig_ret string) +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/sizet.go b/Examples/test-suite/go/sizet.go new file mode 100644 index 000000000..99deb22ed --- /dev/null +++ b/Examples/test-suite/go/sizet.go @@ -0,0 +1,57 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../sizet.i + +package sizet + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +var _wrap_test1 unsafe.Pointer + +func Test1(arg1 int64) (_swig_ret int64) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_test1, _swig_p) + return +} +var _wrap_test2 unsafe.Pointer + +func Test2(arg1 int64) (_swig_ret int64) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_test2, _swig_p) + return +} +var _wrap_test3 unsafe.Pointer + +func Test3(arg1 int64) (_swig_ret int64) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_test3, _swig_p) + return +} +var _wrap_test4 unsafe.Pointer + +func Test4(arg1 int64) (_swig_ret int64) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_test4, _swig_p) + return +} + diff --git a/Examples/test-suite/go/smart_pointer_const.go b/Examples/test-suite/go/smart_pointer_const.go new file mode 100644 index 000000000..9baad6c4b --- /dev/null +++ b/Examples/test-suite/go/smart_pointer_const.go @@ -0,0 +1,204 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../smart_pointer_const.i + +package smart_pointer_const + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrFoo uintptr + +func (p SwigcptrFoo) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrFoo) SwigIsFoo() { +} + +var _wrap_Foo_x_set unsafe.Pointer + +func _swig_wrap_Foo_x_set(base SwigcptrFoo, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_x_set, _swig_p) + return +} + +func (arg1 SwigcptrFoo) SetX(arg2 int) { + _swig_wrap_Foo_x_set(arg1, arg2) +} + +var _wrap_Foo_x_get unsafe.Pointer + +func _swig_wrap_Foo_x_get(base SwigcptrFoo) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_x_get, _swig_p) + return +} + +func (arg1 SwigcptrFoo) GetX() (_swig_ret int) { + return _swig_wrap_Foo_x_get(arg1) +} + +var _wrap_Foo_getx unsafe.Pointer + +func _swig_wrap_Foo_getx(base SwigcptrFoo) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_getx, _swig_p) + return +} + +func (arg1 SwigcptrFoo) Getx() (_swig_ret int) { + return _swig_wrap_Foo_getx(arg1) +} + +var _wrap_new_Foo unsafe.Pointer + +func _swig_wrap_new_Foo() (base SwigcptrFoo) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Foo, _swig_p) + return +} + +func NewFoo() (_swig_ret Foo) { + return _swig_wrap_new_Foo() +} + +var _wrap_delete_Foo unsafe.Pointer + +func _swig_wrap_delete_Foo(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Foo, _swig_p) + return +} + +func DeleteFoo(arg1 Foo) { + _swig_wrap_delete_Foo(arg1.Swigcptr()) +} + +type Foo interface { + Swigcptr() uintptr + SwigIsFoo() + SetX(arg2 int) + GetX() (_swig_ret int) + Getx() (_swig_ret int) +} + +type SwigcptrBar uintptr + +func (p SwigcptrBar) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrBar) SwigIsBar() { +} + +var _wrap_new_Bar unsafe.Pointer + +func _swig_wrap_new_Bar(base uintptr) (_ SwigcptrBar) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Bar, _swig_p) + return +} + +func NewBar(arg1 Foo) (_swig_ret Bar) { + return _swig_wrap_new_Bar(arg1.Swigcptr()) +} + +var _wrap_Bar___deref__ unsafe.Pointer + +func _swig_wrap_Bar___deref__(base SwigcptrBar) (_ SwigcptrFoo) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Bar___deref__, _swig_p) + return +} + +func (arg1 SwigcptrBar) X__deref__() (_swig_ret Foo) { + return _swig_wrap_Bar___deref__(arg1) +} + +var _wrap_delete_Bar unsafe.Pointer + +func _swig_wrap_delete_Bar(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Bar, _swig_p) + return +} + +func DeleteBar(arg1 Bar) { + _swig_wrap_delete_Bar(arg1.Swigcptr()) +} + +var _wrap_Bar_x_set unsafe.Pointer + +func _swig_wrap_Bar_x_set(base SwigcptrBar, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Bar_x_set, _swig_p) + return +} + +func (arg1 SwigcptrBar) SetX(arg2 int) { + _swig_wrap_Bar_x_set(arg1, arg2) +} + +var _wrap_Bar_x_get unsafe.Pointer + +func _swig_wrap_Bar_x_get(base SwigcptrBar) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Bar_x_get, _swig_p) + return +} + +func (arg1 SwigcptrBar) GetX() (_swig_ret int) { + return _swig_wrap_Bar_x_get(arg1) +} + +var _wrap_Bar_getx unsafe.Pointer + +func _swig_wrap_Bar_getx(base SwigcptrBar) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Bar_getx, _swig_p) + return +} + +func (arg1 SwigcptrBar) Getx() (_swig_ret int) { + return _swig_wrap_Bar_getx(arg1) +} + +type Bar interface { + Swigcptr() uintptr + SwigIsBar() + X__deref__() (_swig_ret Foo) + SetX(arg2 int) + GetX() (_swig_ret int) + Getx() (_swig_ret int) +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/smart_pointer_const2.go b/Examples/test-suite/go/smart_pointer_const2.go new file mode 100644 index 000000000..dd10755fd --- /dev/null +++ b/Examples/test-suite/go/smart_pointer_const2.go @@ -0,0 +1,204 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../smart_pointer_const2.i + +package smart_pointer_const2 + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrFoo uintptr + +func (p SwigcptrFoo) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrFoo) SwigIsFoo() { +} + +var _wrap_Foo_x_set unsafe.Pointer + +func _swig_wrap_Foo_x_set(base SwigcptrFoo, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_x_set, _swig_p) + return +} + +func (arg1 SwigcptrFoo) SetX(arg2 int) { + _swig_wrap_Foo_x_set(arg1, arg2) +} + +var _wrap_Foo_x_get unsafe.Pointer + +func _swig_wrap_Foo_x_get(base SwigcptrFoo) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_x_get, _swig_p) + return +} + +func (arg1 SwigcptrFoo) GetX() (_swig_ret int) { + return _swig_wrap_Foo_x_get(arg1) +} + +var _wrap_Foo_getx unsafe.Pointer + +func _swig_wrap_Foo_getx(base SwigcptrFoo) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_getx, _swig_p) + return +} + +func (arg1 SwigcptrFoo) Getx() (_swig_ret int) { + return _swig_wrap_Foo_getx(arg1) +} + +var _wrap_Foo_test unsafe.Pointer + +func _swig_wrap_Foo_test(base SwigcptrFoo) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_test, _swig_p) + return +} + +func (arg1 SwigcptrFoo) Test() (_swig_ret int) { + return _swig_wrap_Foo_test(arg1) +} + +var _wrap_new_Foo unsafe.Pointer + +func _swig_wrap_new_Foo() (base SwigcptrFoo) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Foo, _swig_p) + return +} + +func NewFoo() (_swig_ret Foo) { + return _swig_wrap_new_Foo() +} + +var _wrap_delete_Foo unsafe.Pointer + +func _swig_wrap_delete_Foo(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Foo, _swig_p) + return +} + +func DeleteFoo(arg1 Foo) { + _swig_wrap_delete_Foo(arg1.Swigcptr()) +} + +type Foo interface { + Swigcptr() uintptr + SwigIsFoo() + SetX(arg2 int) + GetX() (_swig_ret int) + Getx() (_swig_ret int) + Test() (_swig_ret int) +} + +type SwigcptrBar uintptr + +func (p SwigcptrBar) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrBar) SwigIsBar() { +} + +var _wrap_new_Bar unsafe.Pointer + +func _swig_wrap_new_Bar(base uintptr) (_ SwigcptrBar) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Bar, _swig_p) + return +} + +func NewBar(arg1 Foo) (_swig_ret Bar) { + return _swig_wrap_new_Bar(arg1.Swigcptr()) +} + +var _wrap_Bar___deref__ unsafe.Pointer + +func _swig_wrap_Bar___deref__(base SwigcptrBar) (_ SwigcptrFoo) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Bar___deref__, _swig_p) + return +} + +func (arg1 SwigcptrBar) X__deref__() (_swig_ret Foo) { + return _swig_wrap_Bar___deref__(arg1) +} + +var _wrap_delete_Bar unsafe.Pointer + +func _swig_wrap_delete_Bar(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Bar, _swig_p) + return +} + +func DeleteBar(arg1 Bar) { + _swig_wrap_delete_Bar(arg1.Swigcptr()) +} + +var _wrap_Bar_x_get unsafe.Pointer + +func _swig_wrap_Bar_x_get(base SwigcptrBar) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Bar_x_get, _swig_p) + return +} + +func (arg1 SwigcptrBar) GetX() (_swig_ret int) { + return _swig_wrap_Bar_x_get(arg1) +} + +var _wrap_Bar_getx unsafe.Pointer + +func _swig_wrap_Bar_getx(base SwigcptrBar) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Bar_getx, _swig_p) + return +} + +func (arg1 SwigcptrBar) Getx() (_swig_ret int) { + return _swig_wrap_Bar_getx(arg1) +} + +type Bar interface { + Swigcptr() uintptr + SwigIsBar() + X__deref__() (_swig_ret Foo) + GetX() (_swig_ret int) + Getx() (_swig_ret int) +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/smart_pointer_const_overload.go b/Examples/test-suite/go/smart_pointer_const_overload.go new file mode 100644 index 000000000..9b6ef9b5b --- /dev/null +++ b/Examples/test-suite/go/smart_pointer_const_overload.go @@ -0,0 +1,805 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../smart_pointer_const_overload.i + +package smart_pointer_const_overload + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +var _wrap_CONST_ACCESS_set unsafe.Pointer + +func _swig_wrap_CONST_ACCESS_set(base int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_CONST_ACCESS_set, _swig_p) + return +} + +func SetCONST_ACCESS(arg1 int) { + _swig_wrap_CONST_ACCESS_set(arg1) +} + +var _wrap_CONST_ACCESS_get unsafe.Pointer + +func GetCONST_ACCESS() (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_CONST_ACCESS_get, _swig_p) + return +} +var _wrap_MUTABLE_ACCESS_set unsafe.Pointer + +func _swig_wrap_MUTABLE_ACCESS_set(base int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_MUTABLE_ACCESS_set, _swig_p) + return +} + +func SetMUTABLE_ACCESS(arg1 int) { + _swig_wrap_MUTABLE_ACCESS_set(arg1) +} + +var _wrap_MUTABLE_ACCESS_get unsafe.Pointer + +func GetMUTABLE_ACCESS() (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_MUTABLE_ACCESS_get, _swig_p) + return +} +var _wrap_new_int unsafe.Pointer + +func New_int(arg1 int) (_swig_ret *int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_new_int, _swig_p) + return +} +var _wrap_get_int unsafe.Pointer + +func Get_int(arg1 *int) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_get_int, _swig_p) + return +} +var _wrap_set_int unsafe.Pointer + +func _swig_wrap_set_int(base *int, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_set_int, _swig_p) + return +} + +func Set_int(arg1 *int, arg2 int) { + _swig_wrap_set_int(arg1, arg2) +} + +var _wrap_delete_int unsafe.Pointer + +func _swig_wrap_delete_int(base *int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_int, _swig_p) + return +} + +func Delete_int(arg1 *int) { + _swig_wrap_delete_int(arg1) +} + +type SwigcptrFoo uintptr + +func (p SwigcptrFoo) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrFoo) SwigIsFoo() { +} + +var _wrap_Foo_x_set unsafe.Pointer + +func _swig_wrap_Foo_x_set(base SwigcptrFoo, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_x_set, _swig_p) + return +} + +func (arg1 SwigcptrFoo) SetX(arg2 int) { + _swig_wrap_Foo_x_set(arg1, arg2) +} + +var _wrap_Foo_x_get unsafe.Pointer + +func _swig_wrap_Foo_x_get(base SwigcptrFoo) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_x_get, _swig_p) + return +} + +func (arg1 SwigcptrFoo) GetX() (_swig_ret int) { + return _swig_wrap_Foo_x_get(arg1) +} + +var _wrap_Foo_xp_get unsafe.Pointer + +func _swig_wrap_Foo_xp_get(base SwigcptrFoo) (_ *int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_xp_get, _swig_p) + return +} + +func (arg1 SwigcptrFoo) GetXp() (_swig_ret *int) { + return _swig_wrap_Foo_xp_get(arg1) +} + +var _wrap_Foo_y_get unsafe.Pointer + +func _swig_wrap_Foo_y_get(base SwigcptrFoo) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_y_get, _swig_p) + return +} + +func (arg1 SwigcptrFoo) GetY() (_swig_ret int) { + return _swig_wrap_Foo_y_get(arg1) +} + +var _wrap_Foo_yp_set unsafe.Pointer + +func _swig_wrap_Foo_yp_set(base SwigcptrFoo, _ *int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_yp_set, _swig_p) + return +} + +func (arg1 SwigcptrFoo) SetYp(arg2 *int) { + _swig_wrap_Foo_yp_set(arg1, arg2) +} + +var _wrap_Foo_yp_get unsafe.Pointer + +func _swig_wrap_Foo_yp_get(base SwigcptrFoo) (_ *int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_yp_get, _swig_p) + return +} + +func (arg1 SwigcptrFoo) GetYp() (_swig_ret *int) { + return _swig_wrap_Foo_yp_get(arg1) +} + +var _wrap_Foo_access_set unsafe.Pointer + +func _swig_wrap_Foo_access_set(base SwigcptrFoo, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_access_set, _swig_p) + return +} + +func (arg1 SwigcptrFoo) SetAccess(arg2 int) { + _swig_wrap_Foo_access_set(arg1, arg2) +} + +var _wrap_Foo_access_get unsafe.Pointer + +func _swig_wrap_Foo_access_get(base SwigcptrFoo) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_access_get, _swig_p) + return +} + +func (arg1 SwigcptrFoo) GetAccess() (_swig_ret int) { + return _swig_wrap_Foo_access_get(arg1) +} + +var _wrap_new_Foo unsafe.Pointer + +func _swig_wrap_new_Foo() (base SwigcptrFoo) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Foo, _swig_p) + return +} + +func NewFoo() (_swig_ret Foo) { + return _swig_wrap_new_Foo() +} + +var _wrap_Foo_getx unsafe.Pointer + +func _swig_wrap_Foo_getx(base SwigcptrFoo) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_getx, _swig_p) + return +} + +func (arg1 SwigcptrFoo) Getx() (_swig_ret int) { + return _swig_wrap_Foo_getx(arg1) +} + +var _wrap_Foo_setx unsafe.Pointer + +func _swig_wrap_Foo_setx(base SwigcptrFoo, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_setx, _swig_p) + return +} + +func (arg1 SwigcptrFoo) Setx(arg2 int) { + _swig_wrap_Foo_setx(arg1, arg2) +} + +var _wrap_Foo_stat unsafe.Pointer + +func _swig_wrap_Foo_stat() { + var _swig_p uintptr + _cgo_runtime_cgocall(_wrap_Foo_stat, _swig_p) + return +} + +func FooStat() { + _swig_wrap_Foo_stat() +} + +var _wrap_Foo_getx2 unsafe.Pointer + +func _swig_wrap_Foo_getx2(base SwigcptrFoo) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_getx2, _swig_p) + return +} + +func (arg1 SwigcptrFoo) Getx2() (_swig_ret int) { + return _swig_wrap_Foo_getx2(arg1) +} + +var _wrap_Foo_setx2 unsafe.Pointer + +func _swig_wrap_Foo_setx2(base SwigcptrFoo, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_setx2, _swig_p) + return +} + +func (arg1 SwigcptrFoo) Setx2(arg2 int) { + _swig_wrap_Foo_setx2(arg1, arg2) +} + +var _wrap_delete_Foo unsafe.Pointer + +func _swig_wrap_delete_Foo(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Foo, _swig_p) + return +} + +func DeleteFoo(arg1 Foo) { + _swig_wrap_delete_Foo(arg1.Swigcptr()) +} + +type Foo interface { + Swigcptr() uintptr + SwigIsFoo() + SetX(arg2 int) + GetX() (_swig_ret int) + GetXp() (_swig_ret *int) + GetY() (_swig_ret int) + SetYp(arg2 *int) + GetYp() (_swig_ret *int) + SetAccess(arg2 int) + GetAccess() (_swig_ret int) + Getx() (_swig_ret int) + Setx(arg2 int) + Getx2() (_swig_ret int) + Setx2(arg2 int) +} + +type SwigcptrBar uintptr + +func (p SwigcptrBar) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrBar) SwigIsBar() { +} + +var _wrap_new_Bar unsafe.Pointer + +func _swig_wrap_new_Bar(base uintptr) (_ SwigcptrBar) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Bar, _swig_p) + return +} + +func NewBar(arg1 Foo) (_swig_ret Bar) { + return _swig_wrap_new_Bar(arg1.Swigcptr()) +} + +var _wrap_Bar___deref____SWIG_0 unsafe.Pointer + +func _swig_wrap_Bar___deref____SWIG_0(base SwigcptrBar) (_ SwigcptrFoo) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Bar___deref____SWIG_0, _swig_p) + return +} + +func (arg1 SwigcptrBar) X__deref____SWIG_0() (_swig_ret Foo) { + return _swig_wrap_Bar___deref____SWIG_0(arg1) +} + +var _wrap_Bar___deref____SWIG_1 unsafe.Pointer + +func _swig_wrap_Bar___deref____SWIG_1(base SwigcptrBar) (_ SwigcptrFoo) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Bar___deref____SWIG_1, _swig_p) + return +} + +func (arg1 SwigcptrBar) X__deref____SWIG_1() (_swig_ret Foo) { + return _swig_wrap_Bar___deref____SWIG_1(arg1) +} + +func (p SwigcptrBar) X__deref__(a ...interface{}) interface{} { + argc := len(a) + if argc == 0 { + return p.X__deref____SWIG_0() + } + if argc == 0 { + return p.X__deref____SWIG_1() + } + panic("No match for overloaded function call") +} + +var _wrap_delete_Bar unsafe.Pointer + +func _swig_wrap_delete_Bar(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Bar, _swig_p) + return +} + +func DeleteBar(arg1 Bar) { + _swig_wrap_delete_Bar(arg1.Swigcptr()) +} + +var _wrap_Bar_x_set unsafe.Pointer + +func _swig_wrap_Bar_x_set(base SwigcptrBar, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Bar_x_set, _swig_p) + return +} + +func (arg1 SwigcptrBar) SetX(arg2 int) { + _swig_wrap_Bar_x_set(arg1, arg2) +} + +var _wrap_Bar_x_get unsafe.Pointer + +func _swig_wrap_Bar_x_get(base SwigcptrBar) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Bar_x_get, _swig_p) + return +} + +func (arg1 SwigcptrBar) GetX() (_swig_ret int) { + return _swig_wrap_Bar_x_get(arg1) +} + +var _wrap_Bar_xp_get unsafe.Pointer + +func _swig_wrap_Bar_xp_get(base SwigcptrBar) (_ *int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Bar_xp_get, _swig_p) + return +} + +func (arg1 SwigcptrBar) GetXp() (_swig_ret *int) { + return _swig_wrap_Bar_xp_get(arg1) +} + +var _wrap_Bar_y_get unsafe.Pointer + +func _swig_wrap_Bar_y_get(base SwigcptrBar) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Bar_y_get, _swig_p) + return +} + +func (arg1 SwigcptrBar) GetY() (_swig_ret int) { + return _swig_wrap_Bar_y_get(arg1) +} + +var _wrap_Bar_yp_set unsafe.Pointer + +func _swig_wrap_Bar_yp_set(base SwigcptrBar, _ *int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Bar_yp_set, _swig_p) + return +} + +func (arg1 SwigcptrBar) SetYp(arg2 *int) { + _swig_wrap_Bar_yp_set(arg1, arg2) +} + +var _wrap_Bar_yp_get unsafe.Pointer + +func _swig_wrap_Bar_yp_get(base SwigcptrBar) (_ *int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Bar_yp_get, _swig_p) + return +} + +func (arg1 SwigcptrBar) GetYp() (_swig_ret *int) { + return _swig_wrap_Bar_yp_get(arg1) +} + +var _wrap_Bar_access_set unsafe.Pointer + +func _swig_wrap_Bar_access_set(base SwigcptrBar, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Bar_access_set, _swig_p) + return +} + +func (arg1 SwigcptrBar) SetAccess(arg2 int) { + _swig_wrap_Bar_access_set(arg1, arg2) +} + +var _wrap_Bar_access_get unsafe.Pointer + +func _swig_wrap_Bar_access_get(base SwigcptrBar) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Bar_access_get, _swig_p) + return +} + +func (arg1 SwigcptrBar) GetAccess() (_swig_ret int) { + return _swig_wrap_Bar_access_get(arg1) +} + +var _wrap_Bar_getx unsafe.Pointer + +func _swig_wrap_Bar_getx(base SwigcptrBar) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Bar_getx, _swig_p) + return +} + +func (arg1 SwigcptrBar) Getx() (_swig_ret int) { + return _swig_wrap_Bar_getx(arg1) +} + +var _wrap_Bar_setx unsafe.Pointer + +func _swig_wrap_Bar_setx(base SwigcptrBar, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Bar_setx, _swig_p) + return +} + +func (arg1 SwigcptrBar) Setx(arg2 int) { + _swig_wrap_Bar_setx(arg1, arg2) +} + +var _wrap_Bar_stat unsafe.Pointer + +func _swig_wrap_Bar_stat(base SwigcptrBar) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Bar_stat, _swig_p) + return +} + +func (arg1 SwigcptrBar) Stat() { + _swig_wrap_Bar_stat(arg1) +} + +var _wrap_Bar_getx2 unsafe.Pointer + +func _swig_wrap_Bar_getx2(base SwigcptrBar) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Bar_getx2, _swig_p) + return +} + +func (arg1 SwigcptrBar) Getx2() (_swig_ret int) { + return _swig_wrap_Bar_getx2(arg1) +} + +var _wrap_Bar_setx2 unsafe.Pointer + +func _swig_wrap_Bar_setx2(base SwigcptrBar, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Bar_setx2, _swig_p) + return +} + +func (arg1 SwigcptrBar) Setx2(arg2 int) { + _swig_wrap_Bar_setx2(arg1, arg2) +} + +type Bar interface { + Swigcptr() uintptr + SwigIsBar() + X__deref__(a ...interface{}) interface{} + SetX(arg2 int) + GetX() (_swig_ret int) + GetXp() (_swig_ret *int) + GetY() (_swig_ret int) + SetYp(arg2 *int) + GetYp() (_swig_ret *int) + SetAccess(arg2 int) + GetAccess() (_swig_ret int) + Getx() (_swig_ret int) + Setx(arg2 int) + Stat() + Getx2() (_swig_ret int) + Setx2(arg2 int) +} + +type SwigcptrBar2 uintptr + +func (p SwigcptrBar2) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrBar2) SwigIsBar2() { +} + +var _wrap_new_Bar2 unsafe.Pointer + +func _swig_wrap_new_Bar2(base uintptr) (_ SwigcptrBar2) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Bar2, _swig_p) + return +} + +func NewBar2(arg1 Foo) (_swig_ret Bar2) { + return _swig_wrap_new_Bar2(arg1.Swigcptr()) +} + +var _wrap_Bar2___deref____SWIG_0 unsafe.Pointer + +func _swig_wrap_Bar2___deref____SWIG_0(base SwigcptrBar2) (_ SwigcptrFoo) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Bar2___deref____SWIG_0, _swig_p) + return +} + +func (arg1 SwigcptrBar2) X__deref____SWIG_0() (_swig_ret Foo) { + return _swig_wrap_Bar2___deref____SWIG_0(arg1) +} + +var _wrap_Bar2___deref____SWIG_1 unsafe.Pointer + +func _swig_wrap_Bar2___deref____SWIG_1(base SwigcptrBar2) (_ SwigcptrFoo) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Bar2___deref____SWIG_1, _swig_p) + return +} + +func (arg1 SwigcptrBar2) X__deref____SWIG_1() (_swig_ret Foo) { + return _swig_wrap_Bar2___deref____SWIG_1(arg1) +} + +func (p SwigcptrBar2) X__deref__(a ...interface{}) interface{} { + argc := len(a) + if argc == 0 { + return p.X__deref____SWIG_0() + } + if argc == 0 { + return p.X__deref____SWIG_1() + } + panic("No match for overloaded function call") +} + +var _wrap_delete_Bar2 unsafe.Pointer + +func _swig_wrap_delete_Bar2(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Bar2, _swig_p) + return +} + +func DeleteBar2(arg1 Bar2) { + _swig_wrap_delete_Bar2(arg1.Swigcptr()) +} + +var _wrap_Bar2_x_set unsafe.Pointer + +func _swig_wrap_Bar2_x_set(base SwigcptrBar2, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Bar2_x_set, _swig_p) + return +} + +func (arg1 SwigcptrBar2) SetX(arg2 int) { + _swig_wrap_Bar2_x_set(arg1, arg2) +} + +var _wrap_Bar2_x_get unsafe.Pointer + +func _swig_wrap_Bar2_x_get(base SwigcptrBar2) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Bar2_x_get, _swig_p) + return +} + +func (arg1 SwigcptrBar2) GetX() (_swig_ret int) { + return _swig_wrap_Bar2_x_get(arg1) +} + +var _wrap_Bar2_xp_get unsafe.Pointer + +func _swig_wrap_Bar2_xp_get(base SwigcptrBar2) (_ *int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Bar2_xp_get, _swig_p) + return +} + +func (arg1 SwigcptrBar2) GetXp() (_swig_ret *int) { + return _swig_wrap_Bar2_xp_get(arg1) +} + +var _wrap_Bar2_y_get unsafe.Pointer + +func _swig_wrap_Bar2_y_get(base SwigcptrBar2) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Bar2_y_get, _swig_p) + return +} + +func (arg1 SwigcptrBar2) GetY() (_swig_ret int) { + return _swig_wrap_Bar2_y_get(arg1) +} + +var _wrap_Bar2_yp_set unsafe.Pointer + +func _swig_wrap_Bar2_yp_set(base SwigcptrBar2, _ *int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Bar2_yp_set, _swig_p) + return +} + +func (arg1 SwigcptrBar2) SetYp(arg2 *int) { + _swig_wrap_Bar2_yp_set(arg1, arg2) +} + +var _wrap_Bar2_yp_get unsafe.Pointer + +func _swig_wrap_Bar2_yp_get(base SwigcptrBar2) (_ *int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Bar2_yp_get, _swig_p) + return +} + +func (arg1 SwigcptrBar2) GetYp() (_swig_ret *int) { + return _swig_wrap_Bar2_yp_get(arg1) +} + +var _wrap_Bar2_access_set unsafe.Pointer + +func _swig_wrap_Bar2_access_set(base SwigcptrBar2, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Bar2_access_set, _swig_p) + return +} + +func (arg1 SwigcptrBar2) SetAccess(arg2 int) { + _swig_wrap_Bar2_access_set(arg1, arg2) +} + +var _wrap_Bar2_access_get unsafe.Pointer + +func _swig_wrap_Bar2_access_get(base SwigcptrBar2) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Bar2_access_get, _swig_p) + return +} + +func (arg1 SwigcptrBar2) GetAccess() (_swig_ret int) { + return _swig_wrap_Bar2_access_get(arg1) +} + +var _wrap_Bar2_getx unsafe.Pointer + +func _swig_wrap_Bar2_getx(base SwigcptrBar2) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Bar2_getx, _swig_p) + return +} + +func (arg1 SwigcptrBar2) Getx() (_swig_ret int) { + return _swig_wrap_Bar2_getx(arg1) +} + +var _wrap_Bar2_setx unsafe.Pointer + +func _swig_wrap_Bar2_setx(base SwigcptrBar2, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Bar2_setx, _swig_p) + return +} + +func (arg1 SwigcptrBar2) Setx(arg2 int) { + _swig_wrap_Bar2_setx(arg1, arg2) +} + +var _wrap_Bar2_stat unsafe.Pointer + +func _swig_wrap_Bar2_stat(base SwigcptrBar2) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Bar2_stat, _swig_p) + return +} + +func (arg1 SwigcptrBar2) Stat() { + _swig_wrap_Bar2_stat(arg1) +} + +var _wrap_Bar2_getx2 unsafe.Pointer + +func _swig_wrap_Bar2_getx2(base SwigcptrBar2) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Bar2_getx2, _swig_p) + return +} + +func (arg1 SwigcptrBar2) Getx2() (_swig_ret int) { + return _swig_wrap_Bar2_getx2(arg1) +} + +var _wrap_Bar2_setx2 unsafe.Pointer + +func _swig_wrap_Bar2_setx2(base SwigcptrBar2, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Bar2_setx2, _swig_p) + return +} + +func (arg1 SwigcptrBar2) Setx2(arg2 int) { + _swig_wrap_Bar2_setx2(arg1, arg2) +} + +type Bar2 interface { + Swigcptr() uintptr + SwigIsBar2() + X__deref__(a ...interface{}) interface{} + SetX(arg2 int) + GetX() (_swig_ret int) + GetXp() (_swig_ret *int) + GetY() (_swig_ret int) + SetYp(arg2 *int) + GetYp() (_swig_ret *int) + SetAccess(arg2 int) + GetAccess() (_swig_ret int) + Getx() (_swig_ret int) + Setx(arg2 int) + Stat() + Getx2() (_swig_ret int) + Setx2(arg2 int) +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/smart_pointer_extend.go b/Examples/test-suite/go/smart_pointer_extend.go new file mode 100644 index 000000000..c42f5afa7 --- /dev/null +++ b/Examples/test-suite/go/smart_pointer_extend.go @@ -0,0 +1,1107 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../smart_pointer_extend.i + +package smart_pointer_extend + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrCBase uintptr + +func (p SwigcptrCBase) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrCBase) SwigIsCBase() { +} + +var _wrap_CBase_hello unsafe.Pointer + +func CBaseHello() (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_CBase_hello, _swig_p) + return +} +var _wrap_CBase_x_set unsafe.Pointer + +func _swig_wrap_CBase_x_set(base SwigcptrCBase, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_CBase_x_set, _swig_p) + return +} + +func (arg1 SwigcptrCBase) SetX(arg2 int) { + _swig_wrap_CBase_x_set(arg1, arg2) +} + +var _wrap_CBase_x_get unsafe.Pointer + +func _swig_wrap_CBase_x_get(base SwigcptrCBase) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_CBase_x_get, _swig_p) + return +} + +func (arg1 SwigcptrCBase) GetX() (_swig_ret int) { + return _swig_wrap_CBase_x_get(arg1) +} + +var _wrap_CBase_z_CBase unsafe.Pointer + +func _swig_getCBase_CBase_z_CBase() (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_CBase_z_CBase, _swig_p) + return +} +var CBaseZ int = _swig_getCBase_CBase_z_CBase() +var _wrap_CBase_foo unsafe.Pointer + +func _swig_wrap_CBase_foo(base SwigcptrCBase) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_CBase_foo, _swig_p) + return +} + +func (arg1 SwigcptrCBase) Foo() (_swig_ret int) { + return _swig_wrap_CBase_foo(arg1) +} + +var _wrap_CBase_bar unsafe.Pointer + +func _swig_wrap_CBase_bar(base SwigcptrCBase) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_CBase_bar, _swig_p) + return +} + +func (arg1 SwigcptrCBase) Bar() (_swig_ret int) { + return _swig_wrap_CBase_bar(arg1) +} + +var _wrap_CBase_boo unsafe.Pointer + +func _swig_wrap_CBase_boo(base SwigcptrCBase, _ int) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_CBase_boo, _swig_p) + return +} + +func (arg1 SwigcptrCBase) Boo(arg2 int) (_swig_ret int) { + return _swig_wrap_CBase_boo(arg1, arg2) +} + +var _wrap_new_CBase unsafe.Pointer + +func _swig_wrap_new_CBase() (base SwigcptrCBase) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_CBase, _swig_p) + return +} + +func NewCBase() (_swig_ret CBase) { + return _swig_wrap_new_CBase() +} + +var _wrap_delete_CBase unsafe.Pointer + +func _swig_wrap_delete_CBase(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_CBase, _swig_p) + return +} + +func DeleteCBase(arg1 CBase) { + _swig_wrap_delete_CBase(arg1.Swigcptr()) +} + +type CBase interface { + Swigcptr() uintptr + SwigIsCBase() + SetX(arg2 int) + GetX() (_swig_ret int) + Foo() (_swig_ret int) + Bar() (_swig_ret int) + Boo(arg2 int) (_swig_ret int) +} + +type SwigcptrCDerived uintptr + +func (p SwigcptrCDerived) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrCDerived) SwigIsCDerived() { +} + +var _wrap_CDerived_foo unsafe.Pointer + +func _swig_wrap_CDerived_foo(base SwigcptrCDerived) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_CDerived_foo, _swig_p) + return +} + +func (arg1 SwigcptrCDerived) Foo() (_swig_ret int) { + return _swig_wrap_CDerived_foo(arg1) +} + +var _wrap_new_CDerived unsafe.Pointer + +func _swig_wrap_new_CDerived() (base SwigcptrCDerived) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_CDerived, _swig_p) + return +} + +func NewCDerived() (_swig_ret CDerived) { + return _swig_wrap_new_CDerived() +} + +var _wrap_delete_CDerived unsafe.Pointer + +func _swig_wrap_delete_CDerived(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_CDerived, _swig_p) + return +} + +func DeleteCDerived(arg1 CDerived) { + _swig_wrap_delete_CDerived(arg1.Swigcptr()) +} + +var _wrap_CDerived_hello unsafe.Pointer + +func CDerivedHello() (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_CDerived_hello, _swig_p) + return +} +var _wrap_SetCDerived_X unsafe.Pointer + +func _swig_wrap_SetCDerived_X(base SwigcptrCDerived, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_SetCDerived_X, _swig_p) + return +} + +func (_swig_base SwigcptrCDerived) SetX(arg1 int) { + _swig_wrap_SetCDerived_X(_swig_base, arg1) +} + +var _wrap_GetCDerived_X unsafe.Pointer + +func _swig_wrap_GetCDerived_X(base SwigcptrCDerived) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_GetCDerived_X, _swig_p) + return +} + +func (_swig_base SwigcptrCDerived) GetX() (_swig_ret int) { + return _swig_wrap_GetCDerived_X(_swig_base) +} + +func (p SwigcptrCDerived) SwigIsCBase() { +} + +func (p SwigcptrCDerived) SwigGetCBase() CBase { + return SwigcptrCBase(p.Swigcptr()) +} + +type CDerived interface { + Swigcptr() uintptr + SwigIsCDerived() + Foo() (_swig_ret int) + SetX(arg1 int) + GetX() (_swig_ret int) + SwigIsCBase() + SwigGetCBase() CBase +} + +type SwigcptrCPtr uintptr + +func (p SwigcptrCPtr) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrCPtr) SwigIsCPtr() { +} + +var _wrap_CPtr___deref__ unsafe.Pointer + +func _swig_wrap_CPtr___deref__(base SwigcptrCPtr) (_ SwigcptrCDerived) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_CPtr___deref__, _swig_p) + return +} + +func (arg1 SwigcptrCPtr) X__deref__() (_swig_ret CDerived) { + return _swig_wrap_CPtr___deref__(arg1) +} + +var _wrap_new_CPtr unsafe.Pointer + +func _swig_wrap_new_CPtr() (base SwigcptrCPtr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_CPtr, _swig_p) + return +} + +func NewCPtr() (_swig_ret CPtr) { + return _swig_wrap_new_CPtr() +} + +var _wrap_delete_CPtr unsafe.Pointer + +func _swig_wrap_delete_CPtr(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_CPtr, _swig_p) + return +} + +func DeleteCPtr(arg1 CPtr) { + _swig_wrap_delete_CPtr(arg1.Swigcptr()) +} + +var _wrap_CPtr_foo unsafe.Pointer + +func _swig_wrap_CPtr_foo(base SwigcptrCPtr) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_CPtr_foo, _swig_p) + return +} + +func (arg1 SwigcptrCPtr) Foo() (_swig_ret int) { + return _swig_wrap_CPtr_foo(arg1) +} + +var _wrap_CPtr_hello unsafe.Pointer + +func _swig_wrap_CPtr_hello(base SwigcptrCPtr) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_CPtr_hello, _swig_p) + return +} + +func (arg1 SwigcptrCPtr) Hello() (_swig_ret int) { + return _swig_wrap_CPtr_hello(arg1) +} + +var _wrap_CPtr_x_set unsafe.Pointer + +func _swig_wrap_CPtr_x_set(base SwigcptrCPtr, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_CPtr_x_set, _swig_p) + return +} + +func (arg1 SwigcptrCPtr) SetX(arg2 int) { + _swig_wrap_CPtr_x_set(arg1, arg2) +} + +var _wrap_CPtr_x_get unsafe.Pointer + +func _swig_wrap_CPtr_x_get(base SwigcptrCPtr) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_CPtr_x_get, _swig_p) + return +} + +func (arg1 SwigcptrCPtr) GetX() (_swig_ret int) { + return _swig_wrap_CPtr_x_get(arg1) +} + +var _wrap_CPtr_z_get unsafe.Pointer + +func _swig_wrap_CPtr_z_get(base SwigcptrCPtr) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_CPtr_z_get, _swig_p) + return +} + +func (arg1 SwigcptrCPtr) GetZ() (_swig_ret int) { + return _swig_wrap_CPtr_z_get(arg1) +} + +var _wrap_CPtr_bar unsafe.Pointer + +func _swig_wrap_CPtr_bar(base SwigcptrCPtr) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_CPtr_bar, _swig_p) + return +} + +func (arg1 SwigcptrCPtr) Bar() (_swig_ret int) { + return _swig_wrap_CPtr_bar(arg1) +} + +var _wrap_CPtr_boo unsafe.Pointer + +func _swig_wrap_CPtr_boo(base SwigcptrCPtr, _ int) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_CPtr_boo, _swig_p) + return +} + +func (arg1 SwigcptrCPtr) Boo(arg2 int) (_swig_ret int) { + return _swig_wrap_CPtr_boo(arg1, arg2) +} + +type CPtr interface { + Swigcptr() uintptr + SwigIsCPtr() + X__deref__() (_swig_ret CDerived) + Foo() (_swig_ret int) + Hello() (_swig_ret int) + SetX(arg2 int) + GetX() (_swig_ret int) + GetZ() (_swig_ret int) + Bar() (_swig_ret int) + Boo(arg2 int) (_swig_ret int) +} + +var _wrap_get_hello unsafe.Pointer + +func _swig_wrap_get_hello(base uintptr) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_get_hello, _swig_p) + return +} + +func Get_hello(arg1 CPtr) (_swig_ret int) { + return _swig_wrap_get_hello(arg1.Swigcptr()) +} + +type SwigcptrCPtrConst uintptr + +func (p SwigcptrCPtrConst) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrCPtrConst) SwigIsCPtrConst() { +} + +var _wrap_CPtrConst___deref__ unsafe.Pointer + +func _swig_wrap_CPtrConst___deref__(base SwigcptrCPtrConst) (_ SwigcptrCDerived) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_CPtrConst___deref__, _swig_p) + return +} + +func (arg1 SwigcptrCPtrConst) X__deref__() (_swig_ret CDerived) { + return _swig_wrap_CPtrConst___deref__(arg1) +} + +var _wrap_new_CPtrConst unsafe.Pointer + +func _swig_wrap_new_CPtrConst() (base SwigcptrCPtrConst) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_CPtrConst, _swig_p) + return +} + +func NewCPtrConst() (_swig_ret CPtrConst) { + return _swig_wrap_new_CPtrConst() +} + +var _wrap_delete_CPtrConst unsafe.Pointer + +func _swig_wrap_delete_CPtrConst(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_CPtrConst, _swig_p) + return +} + +func DeleteCPtrConst(arg1 CPtrConst) { + _swig_wrap_delete_CPtrConst(arg1.Swigcptr()) +} + +var _wrap_CPtrConst_x_get unsafe.Pointer + +func _swig_wrap_CPtrConst_x_get(base SwigcptrCPtrConst) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_CPtrConst_x_get, _swig_p) + return +} + +func (arg1 SwigcptrCPtrConst) GetX() (_swig_ret int) { + return _swig_wrap_CPtrConst_x_get(arg1) +} + +var _wrap_CPtrConst_z_get unsafe.Pointer + +func _swig_wrap_CPtrConst_z_get(base SwigcptrCPtrConst) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_CPtrConst_z_get, _swig_p) + return +} + +func (arg1 SwigcptrCPtrConst) GetZ() (_swig_ret int) { + return _swig_wrap_CPtrConst_z_get(arg1) +} + +type CPtrConst interface { + Swigcptr() uintptr + SwigIsCPtrConst() + X__deref__() (_swig_ret CDerived) + GetX() (_swig_ret int) + GetZ() (_swig_ret int) +} + +type SwigcptrFoo uintptr + +func (p SwigcptrFoo) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrFoo) SwigIsFoo() { +} + +var _wrap_Foo_extension__SWIG_0 unsafe.Pointer + +func _swig_wrap_Foo_extension__SWIG_0(base SwigcptrFoo, _ int, _ int) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_extension__SWIG_0, _swig_p) + return +} + +func (arg1 SwigcptrFoo) Extension__SWIG_0(arg2 int, arg3 int) (_swig_ret int) { + return _swig_wrap_Foo_extension__SWIG_0(arg1, arg2, arg3) +} + +var _wrap_Foo_extension__SWIG_1 unsafe.Pointer + +func _swig_wrap_Foo_extension__SWIG_1(base SwigcptrFoo, _ int) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_extension__SWIG_1, _swig_p) + return +} + +func (arg1 SwigcptrFoo) Extension__SWIG_1(arg2 int) (_swig_ret int) { + return _swig_wrap_Foo_extension__SWIG_1(arg1, arg2) +} + +var _wrap_Foo_extension__SWIG_2 unsafe.Pointer + +func _swig_wrap_Foo_extension__SWIG_2(base SwigcptrFoo) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_extension__SWIG_2, _swig_p) + return +} + +func (arg1 SwigcptrFoo) Extension__SWIG_2() (_swig_ret int) { + return _swig_wrap_Foo_extension__SWIG_2(arg1) +} + +func (p SwigcptrFoo) Extension(a ...interface{}) int { + argc := len(a) + if argc == 0 { + return p.Extension__SWIG_2() + } + if argc == 1 { + return p.Extension__SWIG_1(a[0].(int)) + } + if argc == 2 { + return p.Extension__SWIG_0(a[0].(int), a[1].(int)) + } + panic("No match for overloaded function call") +} + +var _wrap_new_Foo unsafe.Pointer + +func _swig_wrap_new_Foo() (base SwigcptrFoo) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Foo, _swig_p) + return +} + +func NewFoo() (_swig_ret Foo) { + return _swig_wrap_new_Foo() +} + +var _wrap_delete_Foo unsafe.Pointer + +func _swig_wrap_delete_Foo(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Foo, _swig_p) + return +} + +func DeleteFoo(arg1 Foo) { + _swig_wrap_delete_Foo(arg1.Swigcptr()) +} + +type Foo interface { + Swigcptr() uintptr + SwigIsFoo() + Extension(a ...interface{}) int +} + +type SwigcptrBar uintptr + +func (p SwigcptrBar) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrBar) SwigIsBar() { +} + +var _wrap_new_Bar unsafe.Pointer + +func _swig_wrap_new_Bar(base uintptr) (_ SwigcptrBar) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Bar, _swig_p) + return +} + +func NewBar(arg1 Foo) (_swig_ret Bar) { + return _swig_wrap_new_Bar(arg1.Swigcptr()) +} + +var _wrap_Bar___deref__ unsafe.Pointer + +func _swig_wrap_Bar___deref__(base SwigcptrBar) (_ SwigcptrFoo) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Bar___deref__, _swig_p) + return +} + +func (arg1 SwigcptrBar) X__deref__() (_swig_ret Foo) { + return _swig_wrap_Bar___deref__(arg1) +} + +var _wrap_delete_Bar unsafe.Pointer + +func _swig_wrap_delete_Bar(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Bar, _swig_p) + return +} + +func DeleteBar(arg1 Bar) { + _swig_wrap_delete_Bar(arg1.Swigcptr()) +} + +var _wrap_Bar_extension__SWIG_0 unsafe.Pointer + +func _swig_wrap_Bar_extension__SWIG_0(base SwigcptrBar, _ int, _ int) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Bar_extension__SWIG_0, _swig_p) + return +} + +func (arg1 SwigcptrBar) Extension__SWIG_0(arg2 int, arg3 int) (_swig_ret int) { + return _swig_wrap_Bar_extension__SWIG_0(arg1, arg2, arg3) +} + +var _wrap_Bar_extension__SWIG_1 unsafe.Pointer + +func _swig_wrap_Bar_extension__SWIG_1(base SwigcptrBar, _ int) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Bar_extension__SWIG_1, _swig_p) + return +} + +func (arg1 SwigcptrBar) Extension__SWIG_1(arg2 int) (_swig_ret int) { + return _swig_wrap_Bar_extension__SWIG_1(arg1, arg2) +} + +var _wrap_Bar_extension__SWIG_2 unsafe.Pointer + +func _swig_wrap_Bar_extension__SWIG_2(base SwigcptrBar) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Bar_extension__SWIG_2, _swig_p) + return +} + +func (arg1 SwigcptrBar) Extension__SWIG_2() (_swig_ret int) { + return _swig_wrap_Bar_extension__SWIG_2(arg1) +} + +func (p SwigcptrBar) Extension(a ...interface{}) int { + argc := len(a) + if argc == 0 { + return p.Extension__SWIG_2() + } + if argc == 1 { + return p.Extension__SWIG_1(a[0].(int)) + } + if argc == 2 { + return p.Extension__SWIG_0(a[0].(int), a[1].(int)) + } + panic("No match for overloaded function call") +} + +type Bar interface { + Swigcptr() uintptr + SwigIsBar() + X__deref__() (_swig_ret Foo) + Extension(a ...interface{}) int +} + +type SwigcptrCFoo uintptr + +func (p SwigcptrCFoo) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrCFoo) SwigIsCFoo() { +} + +var _wrap_CFoo_StatFun__SWIG_0 unsafe.Pointer + +func _swig_wrap_CFoo_StatFun__SWIG_0() { + var _swig_p uintptr + _cgo_runtime_cgocall(_wrap_CFoo_StatFun__SWIG_0, _swig_p) + return +} + +func CFooStatFun__SWIG_0() { + _swig_wrap_CFoo_StatFun__SWIG_0() +} + +var _wrap_CFoo_StatFun__SWIG_1 unsafe.Pointer + +func _swig_wrap_CFoo_StatFun__SWIG_1(base int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_CFoo_StatFun__SWIG_1, _swig_p) + return +} + +func CFooStatFun__SWIG_1(arg1 int) { + _swig_wrap_CFoo_StatFun__SWIG_1(arg1) +} + +func CFooStatFun(a ...interface{}) { + argc := len(a) + if argc == 0 { + CFooStatFun__SWIG_0() + return + } + if argc == 1 { + CFooStatFun__SWIG_1(a[0].(int)) + return + } + panic("No match for overloaded function call") +} + +var _wrap_CFoo_HoHoHo unsafe.Pointer + +func _swig_wrap_CFoo_HoHoHo(base int, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_CFoo_HoHoHo, _swig_p) + return +} + +func CFooHoHoHo(arg1 int, arg2 int) { + _swig_wrap_CFoo_HoHoHo(arg1, arg2) +} + +var _wrap_new_CFoo unsafe.Pointer + +func _swig_wrap_new_CFoo() (base SwigcptrCFoo) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_CFoo, _swig_p) + return +} + +func NewCFoo() (_swig_ret CFoo) { + return _swig_wrap_new_CFoo() +} + +var _wrap_delete_CFoo unsafe.Pointer + +func _swig_wrap_delete_CFoo(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_CFoo, _swig_p) + return +} + +func DeleteCFoo(arg1 CFoo) { + _swig_wrap_delete_CFoo(arg1.Swigcptr()) +} + +type CFoo interface { + Swigcptr() uintptr + SwigIsCFoo() +} + +type SwigcptrCPtrFoo uintptr + +func (p SwigcptrCPtrFoo) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrCPtrFoo) SwigIsCPtrFoo() { +} + +var _wrap_CPtrFoo___deref__ unsafe.Pointer + +func _swig_wrap_CPtrFoo___deref__(base SwigcptrCPtrFoo) (_ SwigcptrCFoo) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_CPtrFoo___deref__, _swig_p) + return +} + +func (arg1 SwigcptrCPtrFoo) X__deref__() (_swig_ret CFoo) { + return _swig_wrap_CPtrFoo___deref__(arg1) +} + +var _wrap_new_CPtrFoo unsafe.Pointer + +func _swig_wrap_new_CPtrFoo() (base SwigcptrCPtrFoo) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_CPtrFoo, _swig_p) + return +} + +func NewCPtrFoo() (_swig_ret CPtrFoo) { + return _swig_wrap_new_CPtrFoo() +} + +var _wrap_delete_CPtrFoo unsafe.Pointer + +func _swig_wrap_delete_CPtrFoo(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_CPtrFoo, _swig_p) + return +} + +func DeleteCPtrFoo(arg1 CPtrFoo) { + _swig_wrap_delete_CPtrFoo(arg1.Swigcptr()) +} + +var _wrap_CPtrFoo_StatFun__SWIG_0 unsafe.Pointer + +func _swig_wrap_CPtrFoo_StatFun__SWIG_0(base SwigcptrCPtrFoo) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_CPtrFoo_StatFun__SWIG_0, _swig_p) + return +} + +func (arg1 SwigcptrCPtrFoo) StatFun__SWIG_0() { + _swig_wrap_CPtrFoo_StatFun__SWIG_0(arg1) +} + +var _wrap_CPtrFoo_StatFun__SWIG_1 unsafe.Pointer + +func _swig_wrap_CPtrFoo_StatFun__SWIG_1(base SwigcptrCPtrFoo, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_CPtrFoo_StatFun__SWIG_1, _swig_p) + return +} + +func (arg1 SwigcptrCPtrFoo) StatFun__SWIG_1(arg2 int) { + _swig_wrap_CPtrFoo_StatFun__SWIG_1(arg1, arg2) +} + +func (p SwigcptrCPtrFoo) StatFun(a ...interface{}) { + argc := len(a) + if argc == 0 { + p.StatFun__SWIG_0() + return + } + if argc == 1 { + p.StatFun__SWIG_1(a[0].(int)) + return + } + panic("No match for overloaded function call") +} + +var _wrap_CPtrFoo_HoHoHo unsafe.Pointer + +func _swig_wrap_CPtrFoo_HoHoHo(base SwigcptrCPtrFoo, _ int, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_CPtrFoo_HoHoHo, _swig_p) + return +} + +func (arg1 SwigcptrCPtrFoo) HoHoHo(arg2 int, arg3 int) { + _swig_wrap_CPtrFoo_HoHoHo(arg1, arg2, arg3) +} + +type CPtrFoo interface { + Swigcptr() uintptr + SwigIsCPtrFoo() + X__deref__() (_swig_ret CFoo) + StatFun(a ...interface{}) + HoHoHo(arg2 int, arg3 int) +} + +type SwigcptrDPtrFoo uintptr + +func (p SwigcptrDPtrFoo) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrDPtrFoo) SwigIsDPtrFoo() { +} + +var _wrap_new_DPtrFoo unsafe.Pointer + +func _swig_wrap_new_DPtrFoo(base uintptr) (_ SwigcptrDPtrFoo) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_DPtrFoo, _swig_p) + return +} + +func NewDPtrFoo(arg1 DFoo) (_swig_ret DPtrFoo) { + return _swig_wrap_new_DPtrFoo(arg1.Swigcptr()) +} + +var _wrap_DPtrFoo___deref__ unsafe.Pointer + +func _swig_wrap_DPtrFoo___deref__(base SwigcptrDPtrFoo) (_ SwigcptrDFoo) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_DPtrFoo___deref__, _swig_p) + return +} + +func (arg1 SwigcptrDPtrFoo) X__deref__() (_swig_ret DFoo) { + return _swig_wrap_DPtrFoo___deref__(arg1) +} + +var _wrap_delete_DPtrFoo unsafe.Pointer + +func _swig_wrap_delete_DPtrFoo(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_DPtrFoo, _swig_p) + return +} + +func DeleteDPtrFoo(arg1 DPtrFoo) { + _swig_wrap_delete_DPtrFoo(arg1.Swigcptr()) +} + +var _wrap_DPtrFoo_F unsafe.Pointer + +func _swig_wrap_DPtrFoo_F(base SwigcptrDPtrFoo) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_DPtrFoo_F, _swig_p) + return +} + +func (arg1 SwigcptrDPtrFoo) F() { + _swig_wrap_DPtrFoo_F(arg1) +} + +var _wrap_DPtrFoo_SExt__SWIG_0 unsafe.Pointer + +func _swig_wrap_DPtrFoo_SExt__SWIG_0(base SwigcptrDPtrFoo, _ int) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_DPtrFoo_SExt__SWIG_0, _swig_p) + return +} + +func (arg1 SwigcptrDPtrFoo) SExt__SWIG_0(arg2 int) (_swig_ret int) { + return _swig_wrap_DPtrFoo_SExt__SWIG_0(arg1, arg2) +} + +var _wrap_DPtrFoo_SExt__SWIG_1 unsafe.Pointer + +func _swig_wrap_DPtrFoo_SExt__SWIG_1(base SwigcptrDPtrFoo) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_DPtrFoo_SExt__SWIG_1, _swig_p) + return +} + +func (arg1 SwigcptrDPtrFoo) SExt__SWIG_1() (_swig_ret int) { + return _swig_wrap_DPtrFoo_SExt__SWIG_1(arg1) +} + +func (p SwigcptrDPtrFoo) SExt(a ...interface{}) int { + argc := len(a) + if argc == 0 { + return p.SExt__SWIG_1() + } + if argc == 1 { + return p.SExt__SWIG_0(a[0].(int)) + } + panic("No match for overloaded function call") +} + +var _wrap_DPtrFoo_Ext__SWIG_0 unsafe.Pointer + +func _swig_wrap_DPtrFoo_Ext__SWIG_0(base SwigcptrDPtrFoo, _ int) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_DPtrFoo_Ext__SWIG_0, _swig_p) + return +} + +func (arg1 SwigcptrDPtrFoo) Ext__SWIG_0(arg2 int) (_swig_ret int) { + return _swig_wrap_DPtrFoo_Ext__SWIG_0(arg1, arg2) +} + +var _wrap_DPtrFoo_Ext__SWIG_1 unsafe.Pointer + +func _swig_wrap_DPtrFoo_Ext__SWIG_1(base SwigcptrDPtrFoo) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_DPtrFoo_Ext__SWIG_1, _swig_p) + return +} + +func (arg1 SwigcptrDPtrFoo) Ext__SWIG_1() (_swig_ret int) { + return _swig_wrap_DPtrFoo_Ext__SWIG_1(arg1) +} + +func (p SwigcptrDPtrFoo) Ext(a ...interface{}) int { + argc := len(a) + if argc == 0 { + return p.Ext__SWIG_1() + } + if argc == 1 { + return p.Ext__SWIG_0(a[0].(int)) + } + panic("No match for overloaded function call") +} + +type DPtrFoo interface { + Swigcptr() uintptr + SwigIsDPtrFoo() + X__deref__() (_swig_ret DFoo) + F() + SExt(a ...interface{}) int + Ext(a ...interface{}) int +} + +type SwigcptrDFoo uintptr + +func (p SwigcptrDFoo) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrDFoo) SwigIsDFoo() { +} + +var _wrap_DFoo_F unsafe.Pointer + +func _swig_wrap_DFoo_F(base SwigcptrDFoo) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_DFoo_F, _swig_p) + return +} + +func (arg1 SwigcptrDFoo) F() { + _swig_wrap_DFoo_F(arg1) +} + +var _wrap_DFoo_SExt__SWIG_0 unsafe.Pointer + +func DFooSExt__SWIG_0(arg1 int) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_DFoo_SExt__SWIG_0, _swig_p) + return +} +var _wrap_DFoo_SExt__SWIG_1 unsafe.Pointer + +func DFooSExt__SWIG_1() (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_DFoo_SExt__SWIG_1, _swig_p) + return +} +func DFooSExt(a ...interface{}) int { + argc := len(a) + if argc == 0 { + return DFooSExt__SWIG_1() + } + if argc == 1 { + return DFooSExt__SWIG_0(a[0].(int)) + } + panic("No match for overloaded function call") +} + +var _wrap_DFoo_Ext__SWIG_0 unsafe.Pointer + +func _swig_wrap_DFoo_Ext__SWIG_0(base SwigcptrDFoo, _ int) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_DFoo_Ext__SWIG_0, _swig_p) + return +} + +func (arg1 SwigcptrDFoo) Ext__SWIG_0(arg2 int) (_swig_ret int) { + return _swig_wrap_DFoo_Ext__SWIG_0(arg1, arg2) +} + +var _wrap_DFoo_Ext__SWIG_1 unsafe.Pointer + +func _swig_wrap_DFoo_Ext__SWIG_1(base SwigcptrDFoo) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_DFoo_Ext__SWIG_1, _swig_p) + return +} + +func (arg1 SwigcptrDFoo) Ext__SWIG_1() (_swig_ret int) { + return _swig_wrap_DFoo_Ext__SWIG_1(arg1) +} + +func (p SwigcptrDFoo) Ext(a ...interface{}) int { + argc := len(a) + if argc == 0 { + return p.Ext__SWIG_1() + } + if argc == 1 { + return p.Ext__SWIG_0(a[0].(int)) + } + panic("No match for overloaded function call") +} + +var _wrap_new_DFoo unsafe.Pointer + +func _swig_wrap_new_DFoo() (base SwigcptrDFoo) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_DFoo, _swig_p) + return +} + +func NewDFoo() (_swig_ret DFoo) { + return _swig_wrap_new_DFoo() +} + +var _wrap_delete_DFoo unsafe.Pointer + +func _swig_wrap_delete_DFoo(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_DFoo, _swig_p) + return +} + +func DeleteDFoo(arg1 DFoo) { + _swig_wrap_delete_DFoo(arg1.Swigcptr()) +} + +type DFoo interface { + Swigcptr() uintptr + SwigIsDFoo() + F() + Ext(a ...interface{}) int +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/smart_pointer_extend_runme b/Examples/test-suite/go/smart_pointer_extend_runme new file mode 100755 index 000000000..120c1d3ba Binary files /dev/null and b/Examples/test-suite/go/smart_pointer_extend_runme differ diff --git a/Examples/test-suite/go/smart_pointer_inherit.go b/Examples/test-suite/go/smart_pointer_inherit.go new file mode 100644 index 000000000..f58dba6b0 --- /dev/null +++ b/Examples/test-suite/go/smart_pointer_inherit.go @@ -0,0 +1,1007 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../smart_pointer_inherit.i + +package smart_pointer_inherit + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrBase uintptr + +func (p SwigcptrBase) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrBase) SwigIsBase() { +} + +var _wrap_delete_Base unsafe.Pointer + +func _swig_wrap_delete_Base(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Base, _swig_p) + return +} + +func DeleteBase(arg1 Base) { + _swig_wrap_delete_Base(arg1.Swigcptr()) +} + +var _wrap_Base_value unsafe.Pointer + +func _swig_wrap_Base_value(base SwigcptrBase) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Base_value, _swig_p) + return +} + +func (arg1 SwigcptrBase) Value() (_swig_ret int) { + return _swig_wrap_Base_value(arg1) +} + +var _wrap_Base_value2 unsafe.Pointer + +func _swig_wrap_Base_value2(base SwigcptrBase) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Base_value2, _swig_p) + return +} + +func (arg1 SwigcptrBase) Value2() (_swig_ret int) { + return _swig_wrap_Base_value2(arg1) +} + +var _wrap_Base_value3 unsafe.Pointer + +func _swig_wrap_Base_value3(base SwigcptrBase) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Base_value3, _swig_p) + return +} + +func (arg1 SwigcptrBase) Value3() (_swig_ret int) { + return _swig_wrap_Base_value3(arg1) +} + +var _wrap_Base_valuehide unsafe.Pointer + +func _swig_wrap_Base_valuehide(base SwigcptrBase) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Base_valuehide, _swig_p) + return +} + +func (arg1 SwigcptrBase) Valuehide() (_swig_ret int) { + return _swig_wrap_Base_valuehide(arg1) +} + +var _wrap_Base_val_set unsafe.Pointer + +func _swig_wrap_Base_val_set(base SwigcptrBase, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Base_val_set, _swig_p) + return +} + +func (arg1 SwigcptrBase) SetVal(arg2 int) { + _swig_wrap_Base_val_set(arg1, arg2) +} + +var _wrap_Base_val_get unsafe.Pointer + +func _swig_wrap_Base_val_get(base SwigcptrBase) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Base_val_get, _swig_p) + return +} + +func (arg1 SwigcptrBase) GetVal() (_swig_ret int) { + return _swig_wrap_Base_val_get(arg1) +} + +type Base interface { + Swigcptr() uintptr + SwigIsBase() + Value() (_swig_ret int) + Value2() (_swig_ret int) + Value3() (_swig_ret int) + Valuehide() (_swig_ret int) + SetVal(arg2 int) + GetVal() (_swig_ret int) +} + +type SwigcptrDerived uintptr + +func (p SwigcptrDerived) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrDerived) SwigIsDerived() { +} + +var _wrap_new_Derived unsafe.Pointer + +func _swig_wrap_new_Derived(base int) (_ SwigcptrDerived) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Derived, _swig_p) + return +} + +func NewDerived(arg1 int) (_swig_ret Derived) { + return _swig_wrap_new_Derived(arg1) +} + +var _wrap_Derived_value unsafe.Pointer + +func _swig_wrap_Derived_value(base SwigcptrDerived) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Derived_value, _swig_p) + return +} + +func (arg1 SwigcptrDerived) Value() (_swig_ret int) { + return _swig_wrap_Derived_value(arg1) +} + +var _wrap_Derived_value3 unsafe.Pointer + +func _swig_wrap_Derived_value3(base SwigcptrDerived) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Derived_value3, _swig_p) + return +} + +func (arg1 SwigcptrDerived) Value3() (_swig_ret int) { + return _swig_wrap_Derived_value3(arg1) +} + +var _wrap_Derived_valuehide unsafe.Pointer + +func _swig_wrap_Derived_valuehide(base SwigcptrDerived) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Derived_valuehide, _swig_p) + return +} + +func (arg1 SwigcptrDerived) Valuehide() (_swig_ret int) { + return _swig_wrap_Derived_valuehide(arg1) +} + +var _wrap_delete_Derived unsafe.Pointer + +func _swig_wrap_delete_Derived(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Derived, _swig_p) + return +} + +func DeleteDerived(arg1 Derived) { + _swig_wrap_delete_Derived(arg1.Swigcptr()) +} + +var _wrap_Derived_value2 unsafe.Pointer + +func _swig_wrap_Derived_value2(base SwigcptrDerived) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Derived_value2, _swig_p) + return +} + +func (_swig_base SwigcptrDerived) Value2() (_swig_ret int) { + return _swig_wrap_Derived_value2(_swig_base) +} + +var _wrap_SetDerived_Val unsafe.Pointer + +func _swig_wrap_SetDerived_Val(base SwigcptrDerived, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_SetDerived_Val, _swig_p) + return +} + +func (_swig_base SwigcptrDerived) SetVal(arg1 int) { + _swig_wrap_SetDerived_Val(_swig_base, arg1) +} + +var _wrap_GetDerived_Val unsafe.Pointer + +func _swig_wrap_GetDerived_Val(base SwigcptrDerived) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_GetDerived_Val, _swig_p) + return +} + +func (_swig_base SwigcptrDerived) GetVal() (_swig_ret int) { + return _swig_wrap_GetDerived_Val(_swig_base) +} + +func (p SwigcptrDerived) SwigIsBase() { +} + +func (p SwigcptrDerived) SwigGetBase() Base { + return SwigcptrBase(p.Swigcptr()) +} + +type Derived interface { + Swigcptr() uintptr + SwigIsDerived() + Value() (_swig_ret int) + Value3() (_swig_ret int) + Valuehide() (_swig_ret int) + Value2() (_swig_ret int) + SetVal(arg1 int) + GetVal() (_swig_ret int) + SwigIsBase() + SwigGetBase() Base +} + +type SwigcptrSmartBase uintptr + +func (p SwigcptrSmartBase) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrSmartBase) SwigIsSmartBase() { +} + +var _wrap_new_SmartBase unsafe.Pointer + +func _swig_wrap_new_SmartBase(base uintptr) (_ SwigcptrSmartBase) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_SmartBase, _swig_p) + return +} + +func NewSmartBase(arg1 Base) (_swig_ret SmartBase) { + return _swig_wrap_new_SmartBase(arg1.Swigcptr()) +} + +var _wrap_SmartBase___deref__ unsafe.Pointer + +func _swig_wrap_SmartBase___deref__(base SwigcptrSmartBase) (_ SwigcptrBase) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_SmartBase___deref__, _swig_p) + return +} + +func (arg1 SwigcptrSmartBase) X__deref__() (_swig_ret Base) { + return _swig_wrap_SmartBase___deref__(arg1) +} + +var _wrap_delete_SmartBase unsafe.Pointer + +func _swig_wrap_delete_SmartBase(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_SmartBase, _swig_p) + return +} + +func DeleteSmartBase(arg1 SmartBase) { + _swig_wrap_delete_SmartBase(arg1.Swigcptr()) +} + +var _wrap_SmartBase_value unsafe.Pointer + +func _swig_wrap_SmartBase_value(base SwigcptrSmartBase) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_SmartBase_value, _swig_p) + return +} + +func (arg1 SwigcptrSmartBase) Value() (_swig_ret int) { + return _swig_wrap_SmartBase_value(arg1) +} + +var _wrap_SmartBase_value2 unsafe.Pointer + +func _swig_wrap_SmartBase_value2(base SwigcptrSmartBase) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_SmartBase_value2, _swig_p) + return +} + +func (arg1 SwigcptrSmartBase) Value2() (_swig_ret int) { + return _swig_wrap_SmartBase_value2(arg1) +} + +var _wrap_SmartBase_value3 unsafe.Pointer + +func _swig_wrap_SmartBase_value3(base SwigcptrSmartBase) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_SmartBase_value3, _swig_p) + return +} + +func (arg1 SwigcptrSmartBase) Value3() (_swig_ret int) { + return _swig_wrap_SmartBase_value3(arg1) +} + +var _wrap_SmartBase_valuehide unsafe.Pointer + +func _swig_wrap_SmartBase_valuehide(base SwigcptrSmartBase) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_SmartBase_valuehide, _swig_p) + return +} + +func (arg1 SwigcptrSmartBase) Valuehide() (_swig_ret int) { + return _swig_wrap_SmartBase_valuehide(arg1) +} + +var _wrap_SmartBase_val_set unsafe.Pointer + +func _swig_wrap_SmartBase_val_set(base SwigcptrSmartBase, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_SmartBase_val_set, _swig_p) + return +} + +func (arg1 SwigcptrSmartBase) SetVal(arg2 int) { + _swig_wrap_SmartBase_val_set(arg1, arg2) +} + +var _wrap_SmartBase_val_get unsafe.Pointer + +func _swig_wrap_SmartBase_val_get(base SwigcptrSmartBase) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_SmartBase_val_get, _swig_p) + return +} + +func (arg1 SwigcptrSmartBase) GetVal() (_swig_ret int) { + return _swig_wrap_SmartBase_val_get(arg1) +} + +type SmartBase interface { + Swigcptr() uintptr + SwigIsSmartBase() + X__deref__() (_swig_ret Base) + Value() (_swig_ret int) + Value2() (_swig_ret int) + Value3() (_swig_ret int) + Valuehide() (_swig_ret int) + SetVal(arg2 int) + GetVal() (_swig_ret int) +} + +type SwigcptrSmartDerived uintptr + +func (p SwigcptrSmartDerived) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrSmartDerived) SwigIsSmartDerived() { +} + +var _wrap_new_SmartDerived unsafe.Pointer + +func _swig_wrap_new_SmartDerived(base uintptr) (_ SwigcptrSmartDerived) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_SmartDerived, _swig_p) + return +} + +func NewSmartDerived(arg1 Derived) (_swig_ret SmartDerived) { + return _swig_wrap_new_SmartDerived(arg1.Swigcptr()) +} + +var _wrap_SmartDerived___deref__ unsafe.Pointer + +func _swig_wrap_SmartDerived___deref__(base SwigcptrSmartDerived) (_ SwigcptrDerived) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_SmartDerived___deref__, _swig_p) + return +} + +func (arg1 SwigcptrSmartDerived) X__deref__() (_swig_ret Derived) { + return _swig_wrap_SmartDerived___deref__(arg1) +} + +var _wrap_delete_SmartDerived unsafe.Pointer + +func _swig_wrap_delete_SmartDerived(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_SmartDerived, _swig_p) + return +} + +func DeleteSmartDerived(arg1 SmartDerived) { + _swig_wrap_delete_SmartDerived(arg1.Swigcptr()) +} + +var _wrap_SmartDerived_value unsafe.Pointer + +func _swig_wrap_SmartDerived_value(base SwigcptrSmartDerived) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_SmartDerived_value, _swig_p) + return +} + +func (arg1 SwigcptrSmartDerived) Value() (_swig_ret int) { + return _swig_wrap_SmartDerived_value(arg1) +} + +var _wrap_SmartDerived_value3 unsafe.Pointer + +func _swig_wrap_SmartDerived_value3(base SwigcptrSmartDerived) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_SmartDerived_value3, _swig_p) + return +} + +func (arg1 SwigcptrSmartDerived) Value3() (_swig_ret int) { + return _swig_wrap_SmartDerived_value3(arg1) +} + +var _wrap_SmartDerived_valuehide unsafe.Pointer + +func _swig_wrap_SmartDerived_valuehide(base SwigcptrSmartDerived) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_SmartDerived_valuehide, _swig_p) + return +} + +func (arg1 SwigcptrSmartDerived) Valuehide() (_swig_ret int) { + return _swig_wrap_SmartDerived_valuehide(arg1) +} + +var _wrap_SmartDerived_value2 unsafe.Pointer + +func _swig_wrap_SmartDerived_value2(base SwigcptrSmartDerived) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_SmartDerived_value2, _swig_p) + return +} + +func (arg1 SwigcptrSmartDerived) Value2() (_swig_ret int) { + return _swig_wrap_SmartDerived_value2(arg1) +} + +var _wrap_SmartDerived_val_set unsafe.Pointer + +func _swig_wrap_SmartDerived_val_set(base SwigcptrSmartDerived, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_SmartDerived_val_set, _swig_p) + return +} + +func (arg1 SwigcptrSmartDerived) SetVal(arg2 int) { + _swig_wrap_SmartDerived_val_set(arg1, arg2) +} + +var _wrap_SmartDerived_val_get unsafe.Pointer + +func _swig_wrap_SmartDerived_val_get(base SwigcptrSmartDerived) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_SmartDerived_val_get, _swig_p) + return +} + +func (arg1 SwigcptrSmartDerived) GetVal() (_swig_ret int) { + return _swig_wrap_SmartDerived_val_get(arg1) +} + +type SmartDerived interface { + Swigcptr() uintptr + SwigIsSmartDerived() + X__deref__() (_swig_ret Derived) + Value() (_swig_ret int) + Value3() (_swig_ret int) + Valuehide() (_swig_ret int) + Value2() (_swig_ret int) + SetVal(arg2 int) + GetVal() (_swig_ret int) +} + +type SwigcptrItkLevelSetNodeUS2 uintptr + +func (p SwigcptrItkLevelSetNodeUS2) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrItkLevelSetNodeUS2) SwigIsItkLevelSetNodeUS2() { +} + +var _wrap_new_ItkLevelSetNodeUS2 unsafe.Pointer + +func _swig_wrap_new_ItkLevelSetNodeUS2() (base SwigcptrItkLevelSetNodeUS2) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_ItkLevelSetNodeUS2, _swig_p) + return +} + +func NewItkLevelSetNodeUS2() (_swig_ret ItkLevelSetNodeUS2) { + return _swig_wrap_new_ItkLevelSetNodeUS2() +} + +var _wrap_delete_ItkLevelSetNodeUS2 unsafe.Pointer + +func _swig_wrap_delete_ItkLevelSetNodeUS2(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_ItkLevelSetNodeUS2, _swig_p) + return +} + +func DeleteItkLevelSetNodeUS2(arg1 ItkLevelSetNodeUS2) { + _swig_wrap_delete_ItkLevelSetNodeUS2(arg1.Swigcptr()) +} + +type ItkLevelSetNodeUS2 interface { + Swigcptr() uintptr + SwigIsItkLevelSetNodeUS2() +} + +type SwigcptrVectorLevelSetNodeUS2 uintptr + +func (p SwigcptrVectorLevelSetNodeUS2) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrVectorLevelSetNodeUS2) SwigIsVectorLevelSetNodeUS2() { +} + +var _wrap_new_VectorLevelSetNodeUS2__SWIG_0 unsafe.Pointer + +func _swig_wrap_new_VectorLevelSetNodeUS2__SWIG_0() (base SwigcptrVectorLevelSetNodeUS2) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_VectorLevelSetNodeUS2__SWIG_0, _swig_p) + return +} + +func NewVectorLevelSetNodeUS2__SWIG_0() (_swig_ret VectorLevelSetNodeUS2) { + return _swig_wrap_new_VectorLevelSetNodeUS2__SWIG_0() +} + +var _wrap_new_VectorLevelSetNodeUS2__SWIG_1 unsafe.Pointer + +func _swig_wrap_new_VectorLevelSetNodeUS2__SWIG_1(base int64) (_ SwigcptrVectorLevelSetNodeUS2) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_VectorLevelSetNodeUS2__SWIG_1, _swig_p) + return +} + +func NewVectorLevelSetNodeUS2__SWIG_1(arg1 int64) (_swig_ret VectorLevelSetNodeUS2) { + return _swig_wrap_new_VectorLevelSetNodeUS2__SWIG_1(arg1) +} + +func NewVectorLevelSetNodeUS2(a ...interface{}) VectorLevelSetNodeUS2 { + argc := len(a) + if argc == 0 { + return NewVectorLevelSetNodeUS2__SWIG_0() + } + if argc == 1 { + return NewVectorLevelSetNodeUS2__SWIG_1(a[0].(int64)) + } + panic("No match for overloaded function call") +} + +var _wrap_VectorLevelSetNodeUS2_size unsafe.Pointer + +func _swig_wrap_VectorLevelSetNodeUS2_size(base SwigcptrVectorLevelSetNodeUS2) (_ int64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_VectorLevelSetNodeUS2_size, _swig_p) + return +} + +func (arg1 SwigcptrVectorLevelSetNodeUS2) Size() (_swig_ret int64) { + return _swig_wrap_VectorLevelSetNodeUS2_size(arg1) +} + +var _wrap_VectorLevelSetNodeUS2_capacity unsafe.Pointer + +func _swig_wrap_VectorLevelSetNodeUS2_capacity(base SwigcptrVectorLevelSetNodeUS2) (_ int64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_VectorLevelSetNodeUS2_capacity, _swig_p) + return +} + +func (arg1 SwigcptrVectorLevelSetNodeUS2) Capacity() (_swig_ret int64) { + return _swig_wrap_VectorLevelSetNodeUS2_capacity(arg1) +} + +var _wrap_VectorLevelSetNodeUS2_reserve unsafe.Pointer + +func _swig_wrap_VectorLevelSetNodeUS2_reserve(base SwigcptrVectorLevelSetNodeUS2, _ int64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_VectorLevelSetNodeUS2_reserve, _swig_p) + return +} + +func (arg1 SwigcptrVectorLevelSetNodeUS2) Reserve(arg2 int64) { + _swig_wrap_VectorLevelSetNodeUS2_reserve(arg1, arg2) +} + +var _wrap_VectorLevelSetNodeUS2_isEmpty unsafe.Pointer + +func _swig_wrap_VectorLevelSetNodeUS2_isEmpty(base SwigcptrVectorLevelSetNodeUS2) (_ bool) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_VectorLevelSetNodeUS2_isEmpty, _swig_p) + return +} + +func (arg1 SwigcptrVectorLevelSetNodeUS2) IsEmpty() (_swig_ret bool) { + return _swig_wrap_VectorLevelSetNodeUS2_isEmpty(arg1) +} + +var _wrap_VectorLevelSetNodeUS2_clear unsafe.Pointer + +func _swig_wrap_VectorLevelSetNodeUS2_clear(base SwigcptrVectorLevelSetNodeUS2) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_VectorLevelSetNodeUS2_clear, _swig_p) + return +} + +func (arg1 SwigcptrVectorLevelSetNodeUS2) Clear() { + _swig_wrap_VectorLevelSetNodeUS2_clear(arg1) +} + +var _wrap_VectorLevelSetNodeUS2_add unsafe.Pointer + +func _swig_wrap_VectorLevelSetNodeUS2_add(base SwigcptrVectorLevelSetNodeUS2, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_VectorLevelSetNodeUS2_add, _swig_p) + return +} + +func (arg1 SwigcptrVectorLevelSetNodeUS2) Add(arg2 ItkLevelSetNodeUS2) { + _swig_wrap_VectorLevelSetNodeUS2_add(arg1, arg2.Swigcptr()) +} + +var _wrap_VectorLevelSetNodeUS2_get unsafe.Pointer + +func _swig_wrap_VectorLevelSetNodeUS2_get(base SwigcptrVectorLevelSetNodeUS2, _ int) (_ SwigcptrItkLevelSetNodeUS2) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_VectorLevelSetNodeUS2_get, _swig_p) + return +} + +func (arg1 SwigcptrVectorLevelSetNodeUS2) Get(arg2 int) (_swig_ret ItkLevelSetNodeUS2) { + return _swig_wrap_VectorLevelSetNodeUS2_get(arg1, arg2) +} + +var _wrap_VectorLevelSetNodeUS2_set unsafe.Pointer + +func _swig_wrap_VectorLevelSetNodeUS2_set(base SwigcptrVectorLevelSetNodeUS2, _ int, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_VectorLevelSetNodeUS2_set, _swig_p) + return +} + +func (arg1 SwigcptrVectorLevelSetNodeUS2) Set(arg2 int, arg3 ItkLevelSetNodeUS2) { + _swig_wrap_VectorLevelSetNodeUS2_set(arg1, arg2, arg3.Swigcptr()) +} + +var _wrap_delete_VectorLevelSetNodeUS2 unsafe.Pointer + +func _swig_wrap_delete_VectorLevelSetNodeUS2(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_VectorLevelSetNodeUS2, _swig_p) + return +} + +func DeleteVectorLevelSetNodeUS2(arg1 VectorLevelSetNodeUS2) { + _swig_wrap_delete_VectorLevelSetNodeUS2(arg1.Swigcptr()) +} + +type VectorLevelSetNodeUS2 interface { + Swigcptr() uintptr + SwigIsVectorLevelSetNodeUS2() + Size() (_swig_ret int64) + Capacity() (_swig_ret int64) + Reserve(arg2 int64) + IsEmpty() (_swig_ret bool) + Clear() + Add(arg2 ItkLevelSetNodeUS2) + Get(arg2 int) (_swig_ret ItkLevelSetNodeUS2) + Set(arg2 int, arg3 ItkLevelSetNodeUS2) +} + +type SwigcptrItkVectorContainerUILSNUS2 uintptr + +func (p SwigcptrItkVectorContainerUILSNUS2) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrItkVectorContainerUILSNUS2) SwigIsItkVectorContainerUILSNUS2() { +} + +var _wrap_new_ItkVectorContainerUILSNUS2 unsafe.Pointer + +func _swig_wrap_new_ItkVectorContainerUILSNUS2() (base SwigcptrItkVectorContainerUILSNUS2) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_ItkVectorContainerUILSNUS2, _swig_p) + return +} + +func NewItkVectorContainerUILSNUS2() (_swig_ret ItkVectorContainerUILSNUS2) { + return _swig_wrap_new_ItkVectorContainerUILSNUS2() +} + +var _wrap_delete_ItkVectorContainerUILSNUS2 unsafe.Pointer + +func _swig_wrap_delete_ItkVectorContainerUILSNUS2(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_ItkVectorContainerUILSNUS2, _swig_p) + return +} + +func DeleteItkVectorContainerUILSNUS2(arg1 ItkVectorContainerUILSNUS2) { + _swig_wrap_delete_ItkVectorContainerUILSNUS2(arg1.Swigcptr()) +} + +var _wrap_ItkVectorContainerUILSNUS2_size unsafe.Pointer + +func _swig_wrap_ItkVectorContainerUILSNUS2_size(base SwigcptrItkVectorContainerUILSNUS2) (_ int64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_ItkVectorContainerUILSNUS2_size, _swig_p) + return +} + +func (_swig_base SwigcptrItkVectorContainerUILSNUS2) Size() (_swig_ret int64) { + return _swig_wrap_ItkVectorContainerUILSNUS2_size(_swig_base) +} + +var _wrap_ItkVectorContainerUILSNUS2_capacity unsafe.Pointer + +func _swig_wrap_ItkVectorContainerUILSNUS2_capacity(base SwigcptrItkVectorContainerUILSNUS2) (_ int64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_ItkVectorContainerUILSNUS2_capacity, _swig_p) + return +} + +func (_swig_base SwigcptrItkVectorContainerUILSNUS2) Capacity() (_swig_ret int64) { + return _swig_wrap_ItkVectorContainerUILSNUS2_capacity(_swig_base) +} + +var _wrap_ItkVectorContainerUILSNUS2_reserve unsafe.Pointer + +func _swig_wrap_ItkVectorContainerUILSNUS2_reserve(base SwigcptrItkVectorContainerUILSNUS2, _ int64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_ItkVectorContainerUILSNUS2_reserve, _swig_p) + return +} + +func (_swig_base SwigcptrItkVectorContainerUILSNUS2) Reserve(arg1 int64) { + _swig_wrap_ItkVectorContainerUILSNUS2_reserve(_swig_base, arg1) +} + +var _wrap_ItkVectorContainerUILSNUS2_isEmpty unsafe.Pointer + +func _swig_wrap_ItkVectorContainerUILSNUS2_isEmpty(base SwigcptrItkVectorContainerUILSNUS2) (_ bool) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_ItkVectorContainerUILSNUS2_isEmpty, _swig_p) + return +} + +func (_swig_base SwigcptrItkVectorContainerUILSNUS2) IsEmpty() (_swig_ret bool) { + return _swig_wrap_ItkVectorContainerUILSNUS2_isEmpty(_swig_base) +} + +var _wrap_ItkVectorContainerUILSNUS2_clear unsafe.Pointer + +func _swig_wrap_ItkVectorContainerUILSNUS2_clear(base SwigcptrItkVectorContainerUILSNUS2) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_ItkVectorContainerUILSNUS2_clear, _swig_p) + return +} + +func (_swig_base SwigcptrItkVectorContainerUILSNUS2) Clear() { + _swig_wrap_ItkVectorContainerUILSNUS2_clear(_swig_base) +} + +var _wrap_ItkVectorContainerUILSNUS2_add unsafe.Pointer + +func _swig_wrap_ItkVectorContainerUILSNUS2_add(base SwigcptrItkVectorContainerUILSNUS2, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_ItkVectorContainerUILSNUS2_add, _swig_p) + return +} + +func (_swig_base SwigcptrItkVectorContainerUILSNUS2) Add(arg1 ItkLevelSetNodeUS2) { + _swig_wrap_ItkVectorContainerUILSNUS2_add(_swig_base, arg1.Swigcptr()) +} + +func (p SwigcptrItkVectorContainerUILSNUS2) SwigIsVectorLevelSetNodeUS2() { +} + +func (p SwigcptrItkVectorContainerUILSNUS2) SwigGetVectorLevelSetNodeUS2() VectorLevelSetNodeUS2 { + return SwigcptrVectorLevelSetNodeUS2(p.Swigcptr()) +} + +type ItkVectorContainerUILSNUS2 interface { + Swigcptr() uintptr + SwigIsItkVectorContainerUILSNUS2() + Size() (_swig_ret int64) + Capacity() (_swig_ret int64) + Reserve(arg1 int64) + IsEmpty() (_swig_ret bool) + Clear() + Add(arg1 ItkLevelSetNodeUS2) + SwigIsVectorLevelSetNodeUS2() + SwigGetVectorLevelSetNodeUS2() VectorLevelSetNodeUS2 +} + +type SwigcptrItkVectorContainerUILSNUS2_Pointer uintptr + +func (p SwigcptrItkVectorContainerUILSNUS2_Pointer) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrItkVectorContainerUILSNUS2_Pointer) SwigIsItkVectorContainerUILSNUS2_Pointer() { +} + +var _wrap_ItkVectorContainerUILSNUS2_Pointer___deref__ unsafe.Pointer + +func _swig_wrap_ItkVectorContainerUILSNUS2_Pointer___deref__(base SwigcptrItkVectorContainerUILSNUS2_Pointer) (_ SwigcptrItkVectorContainerUILSNUS2) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_ItkVectorContainerUILSNUS2_Pointer___deref__, _swig_p) + return +} + +func (arg1 SwigcptrItkVectorContainerUILSNUS2_Pointer) X__deref__() (_swig_ret ItkVectorContainerUILSNUS2) { + return _swig_wrap_ItkVectorContainerUILSNUS2_Pointer___deref__(arg1) +} + +var _wrap_new_ItkVectorContainerUILSNUS2_Pointer unsafe.Pointer + +func _swig_wrap_new_ItkVectorContainerUILSNUS2_Pointer() (base SwigcptrItkVectorContainerUILSNUS2_Pointer) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_ItkVectorContainerUILSNUS2_Pointer, _swig_p) + return +} + +func NewItkVectorContainerUILSNUS2_Pointer() (_swig_ret ItkVectorContainerUILSNUS2_Pointer) { + return _swig_wrap_new_ItkVectorContainerUILSNUS2_Pointer() +} + +var _wrap_delete_ItkVectorContainerUILSNUS2_Pointer unsafe.Pointer + +func _swig_wrap_delete_ItkVectorContainerUILSNUS2_Pointer(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_ItkVectorContainerUILSNUS2_Pointer, _swig_p) + return +} + +func DeleteItkVectorContainerUILSNUS2_Pointer(arg1 ItkVectorContainerUILSNUS2_Pointer) { + _swig_wrap_delete_ItkVectorContainerUILSNUS2_Pointer(arg1.Swigcptr()) +} + +var _wrap_ItkVectorContainerUILSNUS2_Pointer_size unsafe.Pointer + +func _swig_wrap_ItkVectorContainerUILSNUS2_Pointer_size(base SwigcptrItkVectorContainerUILSNUS2_Pointer) (_ int64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_ItkVectorContainerUILSNUS2_Pointer_size, _swig_p) + return +} + +func (arg1 SwigcptrItkVectorContainerUILSNUS2_Pointer) Size() (_swig_ret int64) { + return _swig_wrap_ItkVectorContainerUILSNUS2_Pointer_size(arg1) +} + +var _wrap_ItkVectorContainerUILSNUS2_Pointer_capacity unsafe.Pointer + +func _swig_wrap_ItkVectorContainerUILSNUS2_Pointer_capacity(base SwigcptrItkVectorContainerUILSNUS2_Pointer) (_ int64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_ItkVectorContainerUILSNUS2_Pointer_capacity, _swig_p) + return +} + +func (arg1 SwigcptrItkVectorContainerUILSNUS2_Pointer) Capacity() (_swig_ret int64) { + return _swig_wrap_ItkVectorContainerUILSNUS2_Pointer_capacity(arg1) +} + +var _wrap_ItkVectorContainerUILSNUS2_Pointer_reserve unsafe.Pointer + +func _swig_wrap_ItkVectorContainerUILSNUS2_Pointer_reserve(base SwigcptrItkVectorContainerUILSNUS2_Pointer, _ int64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_ItkVectorContainerUILSNUS2_Pointer_reserve, _swig_p) + return +} + +func (arg1 SwigcptrItkVectorContainerUILSNUS2_Pointer) Reserve(arg2 int64) { + _swig_wrap_ItkVectorContainerUILSNUS2_Pointer_reserve(arg1, arg2) +} + +var _wrap_ItkVectorContainerUILSNUS2_Pointer_isEmpty unsafe.Pointer + +func _swig_wrap_ItkVectorContainerUILSNUS2_Pointer_isEmpty(base SwigcptrItkVectorContainerUILSNUS2_Pointer) (_ bool) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_ItkVectorContainerUILSNUS2_Pointer_isEmpty, _swig_p) + return +} + +func (arg1 SwigcptrItkVectorContainerUILSNUS2_Pointer) IsEmpty() (_swig_ret bool) { + return _swig_wrap_ItkVectorContainerUILSNUS2_Pointer_isEmpty(arg1) +} + +var _wrap_ItkVectorContainerUILSNUS2_Pointer_clear unsafe.Pointer + +func _swig_wrap_ItkVectorContainerUILSNUS2_Pointer_clear(base SwigcptrItkVectorContainerUILSNUS2_Pointer) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_ItkVectorContainerUILSNUS2_Pointer_clear, _swig_p) + return +} + +func (arg1 SwigcptrItkVectorContainerUILSNUS2_Pointer) Clear() { + _swig_wrap_ItkVectorContainerUILSNUS2_Pointer_clear(arg1) +} + +var _wrap_ItkVectorContainerUILSNUS2_Pointer_add unsafe.Pointer + +func _swig_wrap_ItkVectorContainerUILSNUS2_Pointer_add(base SwigcptrItkVectorContainerUILSNUS2_Pointer, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_ItkVectorContainerUILSNUS2_Pointer_add, _swig_p) + return +} + +func (arg1 SwigcptrItkVectorContainerUILSNUS2_Pointer) Add(arg2 ItkLevelSetNodeUS2) { + _swig_wrap_ItkVectorContainerUILSNUS2_Pointer_add(arg1, arg2.Swigcptr()) +} + +var _wrap_ItkVectorContainerUILSNUS2_Pointer_get unsafe.Pointer + +func _swig_wrap_ItkVectorContainerUILSNUS2_Pointer_get(base SwigcptrItkVectorContainerUILSNUS2_Pointer, _ int) (_ SwigcptrItkLevelSetNodeUS2) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_ItkVectorContainerUILSNUS2_Pointer_get, _swig_p) + return +} + +func (arg1 SwigcptrItkVectorContainerUILSNUS2_Pointer) Get(arg2 int) (_swig_ret ItkLevelSetNodeUS2) { + return _swig_wrap_ItkVectorContainerUILSNUS2_Pointer_get(arg1, arg2) +} + +var _wrap_ItkVectorContainerUILSNUS2_Pointer_set unsafe.Pointer + +func _swig_wrap_ItkVectorContainerUILSNUS2_Pointer_set(base SwigcptrItkVectorContainerUILSNUS2_Pointer, _ int, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_ItkVectorContainerUILSNUS2_Pointer_set, _swig_p) + return +} + +func (arg1 SwigcptrItkVectorContainerUILSNUS2_Pointer) Set(arg2 int, arg3 ItkLevelSetNodeUS2) { + _swig_wrap_ItkVectorContainerUILSNUS2_Pointer_set(arg1, arg2, arg3.Swigcptr()) +} + +type ItkVectorContainerUILSNUS2_Pointer interface { + Swigcptr() uintptr + SwigIsItkVectorContainerUILSNUS2_Pointer() + X__deref__() (_swig_ret ItkVectorContainerUILSNUS2) + Size() (_swig_ret int64) + Capacity() (_swig_ret int64) + Reserve(arg2 int64) + IsEmpty() (_swig_ret bool) + Clear() + Add(arg2 ItkLevelSetNodeUS2) + Get(arg2 int) (_swig_ret ItkLevelSetNodeUS2) + Set(arg2 int, arg3 ItkLevelSetNodeUS2) +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/smart_pointer_member.go b/Examples/test-suite/go/smart_pointer_member.go new file mode 100644 index 000000000..36c07f7e6 --- /dev/null +++ b/Examples/test-suite/go/smart_pointer_member.go @@ -0,0 +1,483 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../smart_pointer_member.i + +package smart_pointer_member + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrFoo uintptr + +func (p SwigcptrFoo) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrFoo) SwigIsFoo() { +} + +var _wrap_Foo_x_set unsafe.Pointer + +func _swig_wrap_Foo_x_set(base SwigcptrFoo, _ *int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_x_set, _swig_p) + return +} + +func (arg1 SwigcptrFoo) SetX(arg2 *int) { + _swig_wrap_Foo_x_set(arg1, arg2) +} + +var _wrap_Foo_x_get unsafe.Pointer + +func _swig_wrap_Foo_x_get(base SwigcptrFoo) (_ *int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_x_get, _swig_p) + return +} + +func (arg1 SwigcptrFoo) GetX() (_swig_ret *int) { + return _swig_wrap_Foo_x_get(arg1) +} + +var _wrap_Foo_y_set unsafe.Pointer + +func _swig_wrap_Foo_y_set(base SwigcptrFoo, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_y_set, _swig_p) + return +} + +func (arg1 SwigcptrFoo) SetY(arg2 int) { + _swig_wrap_Foo_y_set(arg1, arg2) +} + +var _wrap_Foo_y_get unsafe.Pointer + +func _swig_wrap_Foo_y_get(base SwigcptrFoo) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_y_get, _swig_p) + return +} + +func (arg1 SwigcptrFoo) GetY() (_swig_ret int) { + return _swig_wrap_Foo_y_get(arg1) +} + +var _wrap_Foo_z_get unsafe.Pointer + +func GetFooZ() (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_Foo_z_get, _swig_p) + return +} +var _wrap_Foo_ZZ_Foo unsafe.Pointer + +func _swig_getFoo_Foo_ZZ_Foo() (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_Foo_ZZ_Foo, _swig_p) + return +} +var FooZZ int = _swig_getFoo_Foo_ZZ_Foo() +var _wrap_Foo_zx_set unsafe.Pointer + +func _swig_wrap_Foo_zx_set(base int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_zx_set, _swig_p) + return +} + +func SetFooZx(arg1 int) { + _swig_wrap_Foo_zx_set(arg1) +} + +var _wrap_Foo_zx_get unsafe.Pointer + +func GetFooZx() (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_Foo_zx_get, _swig_p) + return +} +var _wrap_Foo_boo unsafe.Pointer + +func FooBoo() (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_Foo_boo, _swig_p) + return +} +var _wrap_new_Foo unsafe.Pointer + +func _swig_wrap_new_Foo() (base SwigcptrFoo) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Foo, _swig_p) + return +} + +func NewFoo() (_swig_ret Foo) { + return _swig_wrap_new_Foo() +} + +var _wrap_delete_Foo unsafe.Pointer + +func _swig_wrap_delete_Foo(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Foo, _swig_p) + return +} + +func DeleteFoo(arg1 Foo) { + _swig_wrap_delete_Foo(arg1.Swigcptr()) +} + +type Foo interface { + Swigcptr() uintptr + SwigIsFoo() + SetX(arg2 *int) + GetX() (_swig_ret *int) + SetY(arg2 int) + GetY() (_swig_ret int) +} + +type SwigcptrBar uintptr + +func (p SwigcptrBar) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrBar) SwigIsBar() { +} + +var _wrap_new_Bar unsafe.Pointer + +func _swig_wrap_new_Bar(base uintptr) (_ SwigcptrBar) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Bar, _swig_p) + return +} + +func NewBar(arg1 Foo) (_swig_ret Bar) { + return _swig_wrap_new_Bar(arg1.Swigcptr()) +} + +var _wrap_Bar___deref__ unsafe.Pointer + +func _swig_wrap_Bar___deref__(base SwigcptrBar) (_ SwigcptrFoo) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Bar___deref__, _swig_p) + return +} + +func (arg1 SwigcptrBar) X__deref__() (_swig_ret Foo) { + return _swig_wrap_Bar___deref__(arg1) +} + +var _wrap_Bar_bua unsafe.Pointer + +func BarBua() (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_Bar_bua, _swig_p) + return +} +var _wrap_delete_Bar unsafe.Pointer + +func _swig_wrap_delete_Bar(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Bar, _swig_p) + return +} + +func DeleteBar(arg1 Bar) { + _swig_wrap_delete_Bar(arg1.Swigcptr()) +} + +var _wrap_Bar_x_set unsafe.Pointer + +func _swig_wrap_Bar_x_set(base SwigcptrBar, _ *int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Bar_x_set, _swig_p) + return +} + +func (arg1 SwigcptrBar) SetX(arg2 *int) { + _swig_wrap_Bar_x_set(arg1, arg2) +} + +var _wrap_Bar_x_get unsafe.Pointer + +func _swig_wrap_Bar_x_get(base SwigcptrBar) (_ *int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Bar_x_get, _swig_p) + return +} + +func (arg1 SwigcptrBar) GetX() (_swig_ret *int) { + return _swig_wrap_Bar_x_get(arg1) +} + +var _wrap_Bar_y_set unsafe.Pointer + +func _swig_wrap_Bar_y_set(base SwigcptrBar, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Bar_y_set, _swig_p) + return +} + +func (arg1 SwigcptrBar) SetY(arg2 int) { + _swig_wrap_Bar_y_set(arg1, arg2) +} + +var _wrap_Bar_y_get unsafe.Pointer + +func _swig_wrap_Bar_y_get(base SwigcptrBar) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Bar_y_get, _swig_p) + return +} + +func (arg1 SwigcptrBar) GetY() (_swig_ret int) { + return _swig_wrap_Bar_y_get(arg1) +} + +var _wrap_Bar_z_get unsafe.Pointer + +func _swig_wrap_Bar_z_get(base SwigcptrBar) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Bar_z_get, _swig_p) + return +} + +func (arg1 SwigcptrBar) GetZ() (_swig_ret int) { + return _swig_wrap_Bar_z_get(arg1) +} + +var _wrap_Bar_ZZ_get unsafe.Pointer + +func _swig_wrap_Bar_ZZ_get(base SwigcptrBar) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Bar_ZZ_get, _swig_p) + return +} + +func (arg1 SwigcptrBar) GetZZ() (_swig_ret int) { + return _swig_wrap_Bar_ZZ_get(arg1) +} + +var _wrap_Bar_zx_set unsafe.Pointer + +func _swig_wrap_Bar_zx_set(base SwigcptrBar, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Bar_zx_set, _swig_p) + return +} + +func (arg1 SwigcptrBar) SetZx(arg2 int) { + _swig_wrap_Bar_zx_set(arg1, arg2) +} + +var _wrap_Bar_zx_get unsafe.Pointer + +func _swig_wrap_Bar_zx_get(base SwigcptrBar) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Bar_zx_get, _swig_p) + return +} + +func (arg1 SwigcptrBar) GetZx() (_swig_ret int) { + return _swig_wrap_Bar_zx_get(arg1) +} + +var _wrap_Bar_boo unsafe.Pointer + +func _swig_wrap_Bar_boo(base SwigcptrBar) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Bar_boo, _swig_p) + return +} + +func (arg1 SwigcptrBar) Boo() (_swig_ret int) { + return _swig_wrap_Bar_boo(arg1) +} + +type Bar interface { + Swigcptr() uintptr + SwigIsBar() + X__deref__() (_swig_ret Foo) + SetX(arg2 *int) + GetX() (_swig_ret *int) + SetY(arg2 int) + GetY() (_swig_ret int) + GetZ() (_swig_ret int) + GetZZ() (_swig_ret int) + SetZx(arg2 int) + GetZx() (_swig_ret int) + Boo() (_swig_ret int) +} + +type SwigcptrCBar uintptr + +func (p SwigcptrCBar) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrCBar) SwigIsCBar() { +} + +var _wrap_new_CBar unsafe.Pointer + +func _swig_wrap_new_CBar(base uintptr) (_ SwigcptrCBar) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_CBar, _swig_p) + return +} + +func NewCBar(arg1 Foo) (_swig_ret CBar) { + return _swig_wrap_new_CBar(arg1.Swigcptr()) +} + +var _wrap_CBar___deref__ unsafe.Pointer + +func _swig_wrap_CBar___deref__(base SwigcptrCBar) (_ SwigcptrFoo) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_CBar___deref__, _swig_p) + return +} + +func (arg1 SwigcptrCBar) X__deref__() (_swig_ret Foo) { + return _swig_wrap_CBar___deref__(arg1) +} + +var _wrap_delete_CBar unsafe.Pointer + +func _swig_wrap_delete_CBar(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_CBar, _swig_p) + return +} + +func DeleteCBar(arg1 CBar) { + _swig_wrap_delete_CBar(arg1.Swigcptr()) +} + +var _wrap_CBar_x_get unsafe.Pointer + +func _swig_wrap_CBar_x_get(base SwigcptrCBar) (_ *int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_CBar_x_get, _swig_p) + return +} + +func (arg1 SwigcptrCBar) GetX() (_swig_ret *int) { + return _swig_wrap_CBar_x_get(arg1) +} + +var _wrap_CBar_y_get unsafe.Pointer + +func _swig_wrap_CBar_y_get(base SwigcptrCBar) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_CBar_y_get, _swig_p) + return +} + +func (arg1 SwigcptrCBar) GetY() (_swig_ret int) { + return _swig_wrap_CBar_y_get(arg1) +} + +var _wrap_CBar_z_get unsafe.Pointer + +func _swig_wrap_CBar_z_get(base SwigcptrCBar) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_CBar_z_get, _swig_p) + return +} + +func (arg1 SwigcptrCBar) GetZ() (_swig_ret int) { + return _swig_wrap_CBar_z_get(arg1) +} + +var _wrap_CBar_ZZ_get unsafe.Pointer + +func _swig_wrap_CBar_ZZ_get(base SwigcptrCBar) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_CBar_ZZ_get, _swig_p) + return +} + +func (arg1 SwigcptrCBar) GetZZ() (_swig_ret int) { + return _swig_wrap_CBar_ZZ_get(arg1) +} + +var _wrap_CBar_zx_get unsafe.Pointer + +func _swig_wrap_CBar_zx_get(base SwigcptrCBar) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_CBar_zx_get, _swig_p) + return +} + +func (arg1 SwigcptrCBar) GetZx() (_swig_ret int) { + return _swig_wrap_CBar_zx_get(arg1) +} + +type CBar interface { + Swigcptr() uintptr + SwigIsCBar() + X__deref__() (_swig_ret Foo) + GetX() (_swig_ret *int) + GetY() (_swig_ret int) + GetZ() (_swig_ret int) + GetZZ() (_swig_ret int) + GetZx() (_swig_ret int) +} + +var _wrap_get_y unsafe.Pointer + +func _swig_wrap_get_y(base uintptr) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_get_y, _swig_p) + return +} + +func Get_y(arg1 Bar) (_swig_ret int) { + return _swig_wrap_get_y(arg1.Swigcptr()) +} + +var _wrap_get_z unsafe.Pointer + +func _swig_wrap_get_z(base uintptr) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_get_z, _swig_p) + return +} + +func Get_z(arg1 Bar) (_swig_ret int) { + return _swig_wrap_get_z(arg1.Swigcptr()) +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/smart_pointer_member_runme b/Examples/test-suite/go/smart_pointer_member_runme new file mode 100755 index 000000000..04be2c275 Binary files /dev/null and b/Examples/test-suite/go/smart_pointer_member_runme differ diff --git a/Examples/test-suite/go/smart_pointer_multi.go b/Examples/test-suite/go/smart_pointer_multi.go new file mode 100644 index 000000000..9b1b30f15 --- /dev/null +++ b/Examples/test-suite/go/smart_pointer_multi.go @@ -0,0 +1,384 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../smart_pointer_multi.i + +package smart_pointer_multi + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrFoo uintptr + +func (p SwigcptrFoo) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrFoo) SwigIsFoo() { +} + +var _wrap_Foo_x_set unsafe.Pointer + +func _swig_wrap_Foo_x_set(base SwigcptrFoo, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_x_set, _swig_p) + return +} + +func (arg1 SwigcptrFoo) SetX(arg2 int) { + _swig_wrap_Foo_x_set(arg1, arg2) +} + +var _wrap_Foo_x_get unsafe.Pointer + +func _swig_wrap_Foo_x_get(base SwigcptrFoo) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_x_get, _swig_p) + return +} + +func (arg1 SwigcptrFoo) GetX() (_swig_ret int) { + return _swig_wrap_Foo_x_get(arg1) +} + +var _wrap_Foo_getx unsafe.Pointer + +func _swig_wrap_Foo_getx(base SwigcptrFoo) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_getx, _swig_p) + return +} + +func (arg1 SwigcptrFoo) Getx() (_swig_ret int) { + return _swig_wrap_Foo_getx(arg1) +} + +var _wrap_new_Foo unsafe.Pointer + +func _swig_wrap_new_Foo() (base SwigcptrFoo) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Foo, _swig_p) + return +} + +func NewFoo() (_swig_ret Foo) { + return _swig_wrap_new_Foo() +} + +var _wrap_delete_Foo unsafe.Pointer + +func _swig_wrap_delete_Foo(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Foo, _swig_p) + return +} + +func DeleteFoo(arg1 Foo) { + _swig_wrap_delete_Foo(arg1.Swigcptr()) +} + +type Foo interface { + Swigcptr() uintptr + SwigIsFoo() + SetX(arg2 int) + GetX() (_swig_ret int) + Getx() (_swig_ret int) +} + +type SwigcptrBar uintptr + +func (p SwigcptrBar) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrBar) SwigIsBar() { +} + +var _wrap_new_Bar unsafe.Pointer + +func _swig_wrap_new_Bar(base uintptr) (_ SwigcptrBar) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Bar, _swig_p) + return +} + +func NewBar(arg1 Foo) (_swig_ret Bar) { + return _swig_wrap_new_Bar(arg1.Swigcptr()) +} + +var _wrap_Bar___deref__ unsafe.Pointer + +func _swig_wrap_Bar___deref__(base SwigcptrBar) (_ SwigcptrFoo) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Bar___deref__, _swig_p) + return +} + +func (arg1 SwigcptrBar) X__deref__() (_swig_ret Foo) { + return _swig_wrap_Bar___deref__(arg1) +} + +var _wrap_delete_Bar unsafe.Pointer + +func _swig_wrap_delete_Bar(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Bar, _swig_p) + return +} + +func DeleteBar(arg1 Bar) { + _swig_wrap_delete_Bar(arg1.Swigcptr()) +} + +var _wrap_Bar_x_set unsafe.Pointer + +func _swig_wrap_Bar_x_set(base SwigcptrBar, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Bar_x_set, _swig_p) + return +} + +func (arg1 SwigcptrBar) SetX(arg2 int) { + _swig_wrap_Bar_x_set(arg1, arg2) +} + +var _wrap_Bar_x_get unsafe.Pointer + +func _swig_wrap_Bar_x_get(base SwigcptrBar) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Bar_x_get, _swig_p) + return +} + +func (arg1 SwigcptrBar) GetX() (_swig_ret int) { + return _swig_wrap_Bar_x_get(arg1) +} + +var _wrap_Bar_getx unsafe.Pointer + +func _swig_wrap_Bar_getx(base SwigcptrBar) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Bar_getx, _swig_p) + return +} + +func (arg1 SwigcptrBar) Getx() (_swig_ret int) { + return _swig_wrap_Bar_getx(arg1) +} + +type Bar interface { + Swigcptr() uintptr + SwigIsBar() + X__deref__() (_swig_ret Foo) + SetX(arg2 int) + GetX() (_swig_ret int) + Getx() (_swig_ret int) +} + +type SwigcptrSpam uintptr + +func (p SwigcptrSpam) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrSpam) SwigIsSpam() { +} + +var _wrap_new_Spam unsafe.Pointer + +func _swig_wrap_new_Spam(base uintptr) (_ SwigcptrSpam) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Spam, _swig_p) + return +} + +func NewSpam(arg1 Bar) (_swig_ret Spam) { + return _swig_wrap_new_Spam(arg1.Swigcptr()) +} + +var _wrap_Spam___deref__ unsafe.Pointer + +func _swig_wrap_Spam___deref__(base SwigcptrSpam) (_ SwigcptrBar) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Spam___deref__, _swig_p) + return +} + +func (arg1 SwigcptrSpam) X__deref__() (_swig_ret Bar) { + return _swig_wrap_Spam___deref__(arg1) +} + +var _wrap_delete_Spam unsafe.Pointer + +func _swig_wrap_delete_Spam(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Spam, _swig_p) + return +} + +func DeleteSpam(arg1 Spam) { + _swig_wrap_delete_Spam(arg1.Swigcptr()) +} + +var _wrap_Spam_x_set unsafe.Pointer + +func _swig_wrap_Spam_x_set(base SwigcptrSpam, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Spam_x_set, _swig_p) + return +} + +func (arg1 SwigcptrSpam) SetX(arg2 int) { + _swig_wrap_Spam_x_set(arg1, arg2) +} + +var _wrap_Spam_x_get unsafe.Pointer + +func _swig_wrap_Spam_x_get(base SwigcptrSpam) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Spam_x_get, _swig_p) + return +} + +func (arg1 SwigcptrSpam) GetX() (_swig_ret int) { + return _swig_wrap_Spam_x_get(arg1) +} + +var _wrap_Spam_getx unsafe.Pointer + +func _swig_wrap_Spam_getx(base SwigcptrSpam) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Spam_getx, _swig_p) + return +} + +func (arg1 SwigcptrSpam) Getx() (_swig_ret int) { + return _swig_wrap_Spam_getx(arg1) +} + +type Spam interface { + Swigcptr() uintptr + SwigIsSpam() + X__deref__() (_swig_ret Bar) + SetX(arg2 int) + GetX() (_swig_ret int) + Getx() (_swig_ret int) +} + +type SwigcptrGrok uintptr + +func (p SwigcptrGrok) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrGrok) SwigIsGrok() { +} + +var _wrap_new_Grok unsafe.Pointer + +func _swig_wrap_new_Grok(base uintptr) (_ SwigcptrGrok) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Grok, _swig_p) + return +} + +func NewGrok(arg1 Bar) (_swig_ret Grok) { + return _swig_wrap_new_Grok(arg1.Swigcptr()) +} + +var _wrap_Grok___deref__ unsafe.Pointer + +func _swig_wrap_Grok___deref__(base SwigcptrGrok) (_ SwigcptrBar) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Grok___deref__, _swig_p) + return +} + +func (arg1 SwigcptrGrok) X__deref__() (_swig_ret Bar) { + return _swig_wrap_Grok___deref__(arg1) +} + +var _wrap_delete_Grok unsafe.Pointer + +func _swig_wrap_delete_Grok(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Grok, _swig_p) + return +} + +func DeleteGrok(arg1 Grok) { + _swig_wrap_delete_Grok(arg1.Swigcptr()) +} + +var _wrap_Grok_x_set unsafe.Pointer + +func _swig_wrap_Grok_x_set(base SwigcptrGrok, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Grok_x_set, _swig_p) + return +} + +func (arg1 SwigcptrGrok) SetX(arg2 int) { + _swig_wrap_Grok_x_set(arg1, arg2) +} + +var _wrap_Grok_x_get unsafe.Pointer + +func _swig_wrap_Grok_x_get(base SwigcptrGrok) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Grok_x_get, _swig_p) + return +} + +func (arg1 SwigcptrGrok) GetX() (_swig_ret int) { + return _swig_wrap_Grok_x_get(arg1) +} + +var _wrap_Grok_getx unsafe.Pointer + +func _swig_wrap_Grok_getx(base SwigcptrGrok) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Grok_getx, _swig_p) + return +} + +func (arg1 SwigcptrGrok) Getx() (_swig_ret int) { + return _swig_wrap_Grok_getx(arg1) +} + +type Grok interface { + Swigcptr() uintptr + SwigIsGrok() + X__deref__() (_swig_ret Bar) + SetX(arg2 int) + GetX() (_swig_ret int) + Getx() (_swig_ret int) +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/smart_pointer_multi_runme b/Examples/test-suite/go/smart_pointer_multi_runme new file mode 100755 index 000000000..3c0d785c9 Binary files /dev/null and b/Examples/test-suite/go/smart_pointer_multi_runme differ diff --git a/Examples/test-suite/go/smart_pointer_multi_typedef.go b/Examples/test-suite/go/smart_pointer_multi_typedef.go new file mode 100644 index 000000000..a272cf972 --- /dev/null +++ b/Examples/test-suite/go/smart_pointer_multi_typedef.go @@ -0,0 +1,384 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../smart_pointer_multi_typedef.i + +package smart_pointer_multi_typedef + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrFoo uintptr + +func (p SwigcptrFoo) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrFoo) SwigIsFoo() { +} + +var _wrap_Foo_x_set unsafe.Pointer + +func _swig_wrap_Foo_x_set(base SwigcptrFoo, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_x_set, _swig_p) + return +} + +func (arg1 SwigcptrFoo) SetX(arg2 int) { + _swig_wrap_Foo_x_set(arg1, arg2) +} + +var _wrap_Foo_x_get unsafe.Pointer + +func _swig_wrap_Foo_x_get(base SwigcptrFoo) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_x_get, _swig_p) + return +} + +func (arg1 SwigcptrFoo) GetX() (_swig_ret int) { + return _swig_wrap_Foo_x_get(arg1) +} + +var _wrap_Foo_getx unsafe.Pointer + +func _swig_wrap_Foo_getx(base SwigcptrFoo) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_getx, _swig_p) + return +} + +func (arg1 SwigcptrFoo) Getx() (_swig_ret int) { + return _swig_wrap_Foo_getx(arg1) +} + +var _wrap_new_Foo unsafe.Pointer + +func _swig_wrap_new_Foo() (base SwigcptrFoo) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Foo, _swig_p) + return +} + +func NewFoo() (_swig_ret Foo) { + return _swig_wrap_new_Foo() +} + +var _wrap_delete_Foo unsafe.Pointer + +func _swig_wrap_delete_Foo(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Foo, _swig_p) + return +} + +func DeleteFoo(arg1 Foo) { + _swig_wrap_delete_Foo(arg1.Swigcptr()) +} + +type Foo interface { + Swigcptr() uintptr + SwigIsFoo() + SetX(arg2 int) + GetX() (_swig_ret int) + Getx() (_swig_ret int) +} + +type SwigcptrBar uintptr + +func (p SwigcptrBar) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrBar) SwigIsBar() { +} + +var _wrap_new_Bar unsafe.Pointer + +func _swig_wrap_new_Bar(base uintptr) (_ SwigcptrBar) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Bar, _swig_p) + return +} + +func NewBar(arg1 Foo) (_swig_ret Bar) { + return _swig_wrap_new_Bar(arg1.Swigcptr()) +} + +var _wrap_Bar___deref__ unsafe.Pointer + +func _swig_wrap_Bar___deref__(base SwigcptrBar) (_ SwigcptrFoo) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Bar___deref__, _swig_p) + return +} + +func (arg1 SwigcptrBar) X__deref__() (_swig_ret Foo) { + return _swig_wrap_Bar___deref__(arg1) +} + +var _wrap_delete_Bar unsafe.Pointer + +func _swig_wrap_delete_Bar(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Bar, _swig_p) + return +} + +func DeleteBar(arg1 Bar) { + _swig_wrap_delete_Bar(arg1.Swigcptr()) +} + +var _wrap_Bar_x_set unsafe.Pointer + +func _swig_wrap_Bar_x_set(base SwigcptrBar, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Bar_x_set, _swig_p) + return +} + +func (arg1 SwigcptrBar) SetX(arg2 int) { + _swig_wrap_Bar_x_set(arg1, arg2) +} + +var _wrap_Bar_x_get unsafe.Pointer + +func _swig_wrap_Bar_x_get(base SwigcptrBar) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Bar_x_get, _swig_p) + return +} + +func (arg1 SwigcptrBar) GetX() (_swig_ret int) { + return _swig_wrap_Bar_x_get(arg1) +} + +var _wrap_Bar_getx unsafe.Pointer + +func _swig_wrap_Bar_getx(base SwigcptrBar) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Bar_getx, _swig_p) + return +} + +func (arg1 SwigcptrBar) Getx() (_swig_ret int) { + return _swig_wrap_Bar_getx(arg1) +} + +type Bar interface { + Swigcptr() uintptr + SwigIsBar() + X__deref__() (_swig_ret Foo) + SetX(arg2 int) + GetX() (_swig_ret int) + Getx() (_swig_ret int) +} + +type SwigcptrSpam uintptr + +func (p SwigcptrSpam) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrSpam) SwigIsSpam() { +} + +var _wrap_new_Spam unsafe.Pointer + +func _swig_wrap_new_Spam(base uintptr) (_ SwigcptrSpam) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Spam, _swig_p) + return +} + +func NewSpam(arg1 Bar) (_swig_ret Spam) { + return _swig_wrap_new_Spam(arg1.Swigcptr()) +} + +var _wrap_Spam___deref__ unsafe.Pointer + +func _swig_wrap_Spam___deref__(base SwigcptrSpam) (_ SwigcptrBar) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Spam___deref__, _swig_p) + return +} + +func (arg1 SwigcptrSpam) X__deref__() (_swig_ret Bar) { + return _swig_wrap_Spam___deref__(arg1) +} + +var _wrap_delete_Spam unsafe.Pointer + +func _swig_wrap_delete_Spam(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Spam, _swig_p) + return +} + +func DeleteSpam(arg1 Spam) { + _swig_wrap_delete_Spam(arg1.Swigcptr()) +} + +var _wrap_Spam_x_set unsafe.Pointer + +func _swig_wrap_Spam_x_set(base SwigcptrSpam, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Spam_x_set, _swig_p) + return +} + +func (arg1 SwigcptrSpam) SetX(arg2 int) { + _swig_wrap_Spam_x_set(arg1, arg2) +} + +var _wrap_Spam_x_get unsafe.Pointer + +func _swig_wrap_Spam_x_get(base SwigcptrSpam) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Spam_x_get, _swig_p) + return +} + +func (arg1 SwigcptrSpam) GetX() (_swig_ret int) { + return _swig_wrap_Spam_x_get(arg1) +} + +var _wrap_Spam_getx unsafe.Pointer + +func _swig_wrap_Spam_getx(base SwigcptrSpam) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Spam_getx, _swig_p) + return +} + +func (arg1 SwigcptrSpam) Getx() (_swig_ret int) { + return _swig_wrap_Spam_getx(arg1) +} + +type Spam interface { + Swigcptr() uintptr + SwigIsSpam() + X__deref__() (_swig_ret Bar) + SetX(arg2 int) + GetX() (_swig_ret int) + Getx() (_swig_ret int) +} + +type SwigcptrGrok uintptr + +func (p SwigcptrGrok) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrGrok) SwigIsGrok() { +} + +var _wrap_new_Grok unsafe.Pointer + +func _swig_wrap_new_Grok(base uintptr) (_ SwigcptrGrok) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Grok, _swig_p) + return +} + +func NewGrok(arg1 Bar) (_swig_ret Grok) { + return _swig_wrap_new_Grok(arg1.Swigcptr()) +} + +var _wrap_Grok___deref__ unsafe.Pointer + +func _swig_wrap_Grok___deref__(base SwigcptrGrok) (_ SwigcptrBar) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Grok___deref__, _swig_p) + return +} + +func (arg1 SwigcptrGrok) X__deref__() (_swig_ret Bar) { + return _swig_wrap_Grok___deref__(arg1) +} + +var _wrap_delete_Grok unsafe.Pointer + +func _swig_wrap_delete_Grok(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Grok, _swig_p) + return +} + +func DeleteGrok(arg1 Grok) { + _swig_wrap_delete_Grok(arg1.Swigcptr()) +} + +var _wrap_Grok_x_set unsafe.Pointer + +func _swig_wrap_Grok_x_set(base SwigcptrGrok, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Grok_x_set, _swig_p) + return +} + +func (arg1 SwigcptrGrok) SetX(arg2 int) { + _swig_wrap_Grok_x_set(arg1, arg2) +} + +var _wrap_Grok_x_get unsafe.Pointer + +func _swig_wrap_Grok_x_get(base SwigcptrGrok) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Grok_x_get, _swig_p) + return +} + +func (arg1 SwigcptrGrok) GetX() (_swig_ret int) { + return _swig_wrap_Grok_x_get(arg1) +} + +var _wrap_Grok_getx unsafe.Pointer + +func _swig_wrap_Grok_getx(base SwigcptrGrok) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Grok_getx, _swig_p) + return +} + +func (arg1 SwigcptrGrok) Getx() (_swig_ret int) { + return _swig_wrap_Grok_getx(arg1) +} + +type Grok interface { + Swigcptr() uintptr + SwigIsGrok() + X__deref__() (_swig_ret Bar) + SetX(arg2 int) + GetX() (_swig_ret int) + Getx() (_swig_ret int) +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/smart_pointer_multi_typedef_runme b/Examples/test-suite/go/smart_pointer_multi_typedef_runme new file mode 100755 index 000000000..2bbd3e1ce Binary files /dev/null and b/Examples/test-suite/go/smart_pointer_multi_typedef_runme differ diff --git a/Examples/test-suite/go/smart_pointer_namespace.go b/Examples/test-suite/go/smart_pointer_namespace.go new file mode 100644 index 000000000..09fccbdd1 --- /dev/null +++ b/Examples/test-suite/go/smart_pointer_namespace.go @@ -0,0 +1,267 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../smart_pointer_namespace.i + +package smart_pointer_namespace + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrObj1 uintptr + +func (p SwigcptrObj1) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrObj1) SwigIsObj1() { +} + +var _wrap_new_Obj1 unsafe.Pointer + +func _swig_wrap_new_Obj1() (base SwigcptrObj1) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Obj1, _swig_p) + return +} + +func NewObj1() (_swig_ret Obj1) { + return _swig_wrap_new_Obj1() +} + +var _wrap_Obj1_donothing unsafe.Pointer + +func _swig_wrap_Obj1_donothing(base SwigcptrObj1) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Obj1_donothing, _swig_p) + return +} + +func (arg1 SwigcptrObj1) Donothing() { + _swig_wrap_Obj1_donothing(arg1) +} + +var _wrap_delete_Obj1 unsafe.Pointer + +func _swig_wrap_delete_Obj1(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Obj1, _swig_p) + return +} + +func DeleteObj1(arg1 Obj1) { + _swig_wrap_delete_Obj1(arg1.Swigcptr()) +} + +type Obj1 interface { + Swigcptr() uintptr + SwigIsObj1() + Donothing() +} + +type SwigcptrObj1_ptr uintptr + +func (p SwigcptrObj1_ptr) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrObj1_ptr) SwigIsObj1_ptr() { +} + +var _wrap_new_Obj1_ptr unsafe.Pointer + +func _swig_wrap_new_Obj1_ptr(base uintptr) (_ SwigcptrObj1_ptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Obj1_ptr, _swig_p) + return +} + +func NewObj1_ptr(arg1 Obj1) (_swig_ret Obj1_ptr) { + return _swig_wrap_new_Obj1_ptr(arg1.Swigcptr()) +} + +var _wrap_delete_Obj1_ptr unsafe.Pointer + +func _swig_wrap_delete_Obj1_ptr(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Obj1_ptr, _swig_p) + return +} + +func DeleteObj1_ptr(arg1 Obj1_ptr) { + _swig_wrap_delete_Obj1_ptr(arg1.Swigcptr()) +} + +var _wrap_Obj1_ptr___deref__ unsafe.Pointer + +func _swig_wrap_Obj1_ptr___deref__(base SwigcptrObj1_ptr) (_ SwigcptrObj1) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Obj1_ptr___deref__, _swig_p) + return +} + +func (arg1 SwigcptrObj1_ptr) X__deref__() (_swig_ret Obj1) { + return _swig_wrap_Obj1_ptr___deref__(arg1) +} + +var _wrap_Obj1_ptr_donothing unsafe.Pointer + +func _swig_wrap_Obj1_ptr_donothing(base SwigcptrObj1_ptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Obj1_ptr_donothing, _swig_p) + return +} + +func (arg1 SwigcptrObj1_ptr) Donothing() { + _swig_wrap_Obj1_ptr_donothing(arg1) +} + +type Obj1_ptr interface { + Swigcptr() uintptr + SwigIsObj1_ptr() + X__deref__() (_swig_ret Obj1) + Donothing() +} + +type SwigcptrObj2 uintptr + +func (p SwigcptrObj2) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrObj2) SwigIsObj2() { +} + +var _wrap_new_Obj2 unsafe.Pointer + +func _swig_wrap_new_Obj2() (base SwigcptrObj2) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Obj2, _swig_p) + return +} + +func NewObj2() (_swig_ret Obj2) { + return _swig_wrap_new_Obj2() +} + +var _wrap_Obj2_donothing unsafe.Pointer + +func _swig_wrap_Obj2_donothing(base SwigcptrObj2) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Obj2_donothing, _swig_p) + return +} + +func (arg1 SwigcptrObj2) Donothing() { + _swig_wrap_Obj2_donothing(arg1) +} + +var _wrap_delete_Obj2 unsafe.Pointer + +func _swig_wrap_delete_Obj2(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Obj2, _swig_p) + return +} + +func DeleteObj2(arg1 Obj2) { + _swig_wrap_delete_Obj2(arg1.Swigcptr()) +} + +type Obj2 interface { + Swigcptr() uintptr + SwigIsObj2() + Donothing() +} + +type SwigcptrObj2_ptr uintptr + +func (p SwigcptrObj2_ptr) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrObj2_ptr) SwigIsObj2_ptr() { +} + +var _wrap_new_Obj2_ptr unsafe.Pointer + +func _swig_wrap_new_Obj2_ptr(base uintptr) (_ SwigcptrObj2_ptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Obj2_ptr, _swig_p) + return +} + +func NewObj2_ptr(arg1 Obj2) (_swig_ret Obj2_ptr) { + return _swig_wrap_new_Obj2_ptr(arg1.Swigcptr()) +} + +var _wrap_delete_Obj2_ptr unsafe.Pointer + +func _swig_wrap_delete_Obj2_ptr(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Obj2_ptr, _swig_p) + return +} + +func DeleteObj2_ptr(arg1 Obj2_ptr) { + _swig_wrap_delete_Obj2_ptr(arg1.Swigcptr()) +} + +var _wrap_Obj2_ptr___deref__ unsafe.Pointer + +func _swig_wrap_Obj2_ptr___deref__(base SwigcptrObj2_ptr) (_ SwigcptrObj2) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Obj2_ptr___deref__, _swig_p) + return +} + +func (arg1 SwigcptrObj2_ptr) X__deref__() (_swig_ret Obj2) { + return _swig_wrap_Obj2_ptr___deref__(arg1) +} + +var _wrap_Obj2_ptr_donothing unsafe.Pointer + +func _swig_wrap_Obj2_ptr_donothing(base SwigcptrObj2_ptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Obj2_ptr_donothing, _swig_p) + return +} + +func (arg1 SwigcptrObj2_ptr) Donothing() { + _swig_wrap_Obj2_ptr_donothing(arg1) +} + +type Obj2_ptr interface { + Swigcptr() uintptr + SwigIsObj2_ptr() + X__deref__() (_swig_ret Obj2) + Donothing() +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/smart_pointer_namespace2.go b/Examples/test-suite/go/smart_pointer_namespace2.go new file mode 100644 index 000000000..dbefe5b5d --- /dev/null +++ b/Examples/test-suite/go/smart_pointer_namespace2.go @@ -0,0 +1,267 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../smart_pointer_namespace2.i + +package smart_pointer_namespace2 + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrObj1 uintptr + +func (p SwigcptrObj1) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrObj1) SwigIsObj1() { +} + +var _wrap_new_Obj1 unsafe.Pointer + +func _swig_wrap_new_Obj1() (base SwigcptrObj1) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Obj1, _swig_p) + return +} + +func NewObj1() (_swig_ret Obj1) { + return _swig_wrap_new_Obj1() +} + +var _wrap_Obj1_donothing unsafe.Pointer + +func _swig_wrap_Obj1_donothing(base SwigcptrObj1) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Obj1_donothing, _swig_p) + return +} + +func (arg1 SwigcptrObj1) Donothing() { + _swig_wrap_Obj1_donothing(arg1) +} + +var _wrap_delete_Obj1 unsafe.Pointer + +func _swig_wrap_delete_Obj1(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Obj1, _swig_p) + return +} + +func DeleteObj1(arg1 Obj1) { + _swig_wrap_delete_Obj1(arg1.Swigcptr()) +} + +type Obj1 interface { + Swigcptr() uintptr + SwigIsObj1() + Donothing() +} + +type SwigcptrObj1_ptr uintptr + +func (p SwigcptrObj1_ptr) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrObj1_ptr) SwigIsObj1_ptr() { +} + +var _wrap_new_Obj1_ptr unsafe.Pointer + +func _swig_wrap_new_Obj1_ptr(base uintptr) (_ SwigcptrObj1_ptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Obj1_ptr, _swig_p) + return +} + +func NewObj1_ptr(arg1 Obj1) (_swig_ret Obj1_ptr) { + return _swig_wrap_new_Obj1_ptr(arg1.Swigcptr()) +} + +var _wrap_delete_Obj1_ptr unsafe.Pointer + +func _swig_wrap_delete_Obj1_ptr(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Obj1_ptr, _swig_p) + return +} + +func DeleteObj1_ptr(arg1 Obj1_ptr) { + _swig_wrap_delete_Obj1_ptr(arg1.Swigcptr()) +} + +var _wrap_Obj1_ptr___deref__ unsafe.Pointer + +func _swig_wrap_Obj1_ptr___deref__(base SwigcptrObj1_ptr) (_ SwigcptrObj1) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Obj1_ptr___deref__, _swig_p) + return +} + +func (arg1 SwigcptrObj1_ptr) X__deref__() (_swig_ret Obj1) { + return _swig_wrap_Obj1_ptr___deref__(arg1) +} + +var _wrap_Obj1_ptr_donothing unsafe.Pointer + +func _swig_wrap_Obj1_ptr_donothing(base SwigcptrObj1_ptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Obj1_ptr_donothing, _swig_p) + return +} + +func (arg1 SwigcptrObj1_ptr) Donothing() { + _swig_wrap_Obj1_ptr_donothing(arg1) +} + +type Obj1_ptr interface { + Swigcptr() uintptr + SwigIsObj1_ptr() + X__deref__() (_swig_ret Obj1) + Donothing() +} + +type SwigcptrObj2 uintptr + +func (p SwigcptrObj2) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrObj2) SwigIsObj2() { +} + +var _wrap_new_Obj2 unsafe.Pointer + +func _swig_wrap_new_Obj2() (base SwigcptrObj2) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Obj2, _swig_p) + return +} + +func NewObj2() (_swig_ret Obj2) { + return _swig_wrap_new_Obj2() +} + +var _wrap_Obj2_donothing unsafe.Pointer + +func _swig_wrap_Obj2_donothing(base SwigcptrObj2) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Obj2_donothing, _swig_p) + return +} + +func (arg1 SwigcptrObj2) Donothing() { + _swig_wrap_Obj2_donothing(arg1) +} + +var _wrap_delete_Obj2 unsafe.Pointer + +func _swig_wrap_delete_Obj2(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Obj2, _swig_p) + return +} + +func DeleteObj2(arg1 Obj2) { + _swig_wrap_delete_Obj2(arg1.Swigcptr()) +} + +type Obj2 interface { + Swigcptr() uintptr + SwigIsObj2() + Donothing() +} + +type SwigcptrObj2_ptr uintptr + +func (p SwigcptrObj2_ptr) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrObj2_ptr) SwigIsObj2_ptr() { +} + +var _wrap_new_Obj2_ptr unsafe.Pointer + +func _swig_wrap_new_Obj2_ptr(base uintptr) (_ SwigcptrObj2_ptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Obj2_ptr, _swig_p) + return +} + +func NewObj2_ptr(arg1 Obj2) (_swig_ret Obj2_ptr) { + return _swig_wrap_new_Obj2_ptr(arg1.Swigcptr()) +} + +var _wrap_delete_Obj2_ptr unsafe.Pointer + +func _swig_wrap_delete_Obj2_ptr(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Obj2_ptr, _swig_p) + return +} + +func DeleteObj2_ptr(arg1 Obj2_ptr) { + _swig_wrap_delete_Obj2_ptr(arg1.Swigcptr()) +} + +var _wrap_Obj2_ptr___deref__ unsafe.Pointer + +func _swig_wrap_Obj2_ptr___deref__(base SwigcptrObj2_ptr) (_ SwigcptrObj2) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Obj2_ptr___deref__, _swig_p) + return +} + +func (arg1 SwigcptrObj2_ptr) X__deref__() (_swig_ret Obj2) { + return _swig_wrap_Obj2_ptr___deref__(arg1) +} + +var _wrap_Obj2_ptr_donothing unsafe.Pointer + +func _swig_wrap_Obj2_ptr_donothing(base SwigcptrObj2_ptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Obj2_ptr_donothing, _swig_p) + return +} + +func (arg1 SwigcptrObj2_ptr) Donothing() { + _swig_wrap_Obj2_ptr_donothing(arg1) +} + +type Obj2_ptr interface { + Swigcptr() uintptr + SwigIsObj2_ptr() + X__deref__() (_swig_ret Obj2) + Donothing() +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/smart_pointer_not.go b/Examples/test-suite/go/smart_pointer_not.go new file mode 100644 index 000000000..381afdfe5 --- /dev/null +++ b/Examples/test-suite/go/smart_pointer_not.go @@ -0,0 +1,267 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../smart_pointer_not.i + +package smart_pointer_not + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrFoo uintptr + +func (p SwigcptrFoo) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrFoo) SwigIsFoo() { +} + +var _wrap_Foo_x_set unsafe.Pointer + +func _swig_wrap_Foo_x_set(base SwigcptrFoo, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_x_set, _swig_p) + return +} + +func (arg1 SwigcptrFoo) SetX(arg2 int) { + _swig_wrap_Foo_x_set(arg1, arg2) +} + +var _wrap_Foo_x_get unsafe.Pointer + +func _swig_wrap_Foo_x_get(base SwigcptrFoo) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_x_get, _swig_p) + return +} + +func (arg1 SwigcptrFoo) GetX() (_swig_ret int) { + return _swig_wrap_Foo_x_get(arg1) +} + +var _wrap_Foo_getx unsafe.Pointer + +func _swig_wrap_Foo_getx(base SwigcptrFoo) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_getx, _swig_p) + return +} + +func (arg1 SwigcptrFoo) Getx() (_swig_ret int) { + return _swig_wrap_Foo_getx(arg1) +} + +var _wrap_new_Foo unsafe.Pointer + +func _swig_wrap_new_Foo() (base SwigcptrFoo) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Foo, _swig_p) + return +} + +func NewFoo() (_swig_ret Foo) { + return _swig_wrap_new_Foo() +} + +var _wrap_delete_Foo unsafe.Pointer + +func _swig_wrap_delete_Foo(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Foo, _swig_p) + return +} + +func DeleteFoo(arg1 Foo) { + _swig_wrap_delete_Foo(arg1.Swigcptr()) +} + +type Foo interface { + Swigcptr() uintptr + SwigIsFoo() + SetX(arg2 int) + GetX() (_swig_ret int) + Getx() (_swig_ret int) +} + +type SwigcptrBar uintptr + +func (p SwigcptrBar) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrBar) SwigIsBar() { +} + +var _wrap_new_Bar unsafe.Pointer + +func _swig_wrap_new_Bar(base uintptr) (_ SwigcptrBar) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Bar, _swig_p) + return +} + +func NewBar(arg1 Foo) (_swig_ret Bar) { + return _swig_wrap_new_Bar(arg1.Swigcptr()) +} + +var _wrap_Bar___deref__ unsafe.Pointer + +func _swig_wrap_Bar___deref__(base SwigcptrBar) (_ SwigcptrFoo) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Bar___deref__, _swig_p) + return +} + +func (arg1 SwigcptrBar) X__deref__() (_swig_ret Foo) { + return _swig_wrap_Bar___deref__(arg1) +} + +var _wrap_delete_Bar unsafe.Pointer + +func _swig_wrap_delete_Bar(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Bar, _swig_p) + return +} + +func DeleteBar(arg1 Bar) { + _swig_wrap_delete_Bar(arg1.Swigcptr()) +} + +type Bar interface { + Swigcptr() uintptr + SwigIsBar() + X__deref__() (_swig_ret Foo) +} + +type SwigcptrSpam uintptr + +func (p SwigcptrSpam) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrSpam) SwigIsSpam() { +} + +var _wrap_new_Spam unsafe.Pointer + +func _swig_wrap_new_Spam(base uintptr) (_ SwigcptrSpam) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Spam, _swig_p) + return +} + +func NewSpam(arg1 Foo) (_swig_ret Spam) { + return _swig_wrap_new_Spam(arg1.Swigcptr()) +} + +var _wrap_Spam___deref__ unsafe.Pointer + +func _swig_wrap_Spam___deref__(base SwigcptrSpam) (_ SwigcptrFoo) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Spam___deref__, _swig_p) + return +} + +func (arg1 SwigcptrSpam) X__deref__() (_swig_ret Foo) { + return _swig_wrap_Spam___deref__(arg1) +} + +var _wrap_delete_Spam unsafe.Pointer + +func _swig_wrap_delete_Spam(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Spam, _swig_p) + return +} + +func DeleteSpam(arg1 Spam) { + _swig_wrap_delete_Spam(arg1.Swigcptr()) +} + +type Spam interface { + Swigcptr() uintptr + SwigIsSpam() + X__deref__() (_swig_ret Foo) +} + +type SwigcptrGrok uintptr + +func (p SwigcptrGrok) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrGrok) SwigIsGrok() { +} + +var _wrap_new_Grok unsafe.Pointer + +func _swig_wrap_new_Grok(base uintptr) (_ SwigcptrGrok) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Grok, _swig_p) + return +} + +func NewGrok(arg1 Foo) (_swig_ret Grok) { + return _swig_wrap_new_Grok(arg1.Swigcptr()) +} + +var _wrap_Grok___deref__ unsafe.Pointer + +func _swig_wrap_Grok___deref__(base SwigcptrGrok) (_ SwigcptrFoo) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Grok___deref__, _swig_p) + return +} + +func (arg1 SwigcptrGrok) X__deref__() (_swig_ret Foo) { + return _swig_wrap_Grok___deref__(arg1) +} + +var _wrap_delete_Grok unsafe.Pointer + +func _swig_wrap_delete_Grok(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Grok, _swig_p) + return +} + +func DeleteGrok(arg1 Grok) { + _swig_wrap_delete_Grok(arg1.Swigcptr()) +} + +type Grok interface { + Swigcptr() uintptr + SwigIsGrok() + X__deref__() (_swig_ret Foo) +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/smart_pointer_overload.go b/Examples/test-suite/go/smart_pointer_overload.go new file mode 100644 index 000000000..d90aea0ec --- /dev/null +++ b/Examples/test-suite/go/smart_pointer_overload.go @@ -0,0 +1,296 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../smart_pointer_overload.i + +package smart_pointer_overload + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrFoo uintptr + +func (p SwigcptrFoo) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrFoo) SwigIsFoo() { +} + +var _wrap_Foo_x_set unsafe.Pointer + +func _swig_wrap_Foo_x_set(base SwigcptrFoo, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_x_set, _swig_p) + return +} + +func (arg1 SwigcptrFoo) SetX(arg2 int) { + _swig_wrap_Foo_x_set(arg1, arg2) +} + +var _wrap_Foo_x_get unsafe.Pointer + +func _swig_wrap_Foo_x_get(base SwigcptrFoo) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_x_get, _swig_p) + return +} + +func (arg1 SwigcptrFoo) GetX() (_swig_ret int) { + return _swig_wrap_Foo_x_get(arg1) +} + +var _wrap_Foo_test__SWIG_0 unsafe.Pointer + +func _swig_wrap_Foo_test__SWIG_0(base SwigcptrFoo, _ int) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_test__SWIG_0, _swig_p) + return +} + +func (arg1 SwigcptrFoo) Test__SWIG_0(arg2 int) (_swig_ret int) { + return _swig_wrap_Foo_test__SWIG_0(arg1, arg2) +} + +var _wrap_Foo_test__SWIG_1 unsafe.Pointer + +func _swig_wrap_Foo_test__SWIG_1(base SwigcptrFoo, _ float64) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_test__SWIG_1, _swig_p) + return +} + +func (arg1 SwigcptrFoo) Test__SWIG_1(arg2 float64) (_swig_ret int) { + return _swig_wrap_Foo_test__SWIG_1(arg1, arg2) +} + +var _wrap_Foo_test__SWIG_2 unsafe.Pointer + +func _swig_wrap_Foo_test__SWIG_2(base SwigcptrFoo, _ string) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_test__SWIG_2, _swig_p) + return +} + +func (arg1 SwigcptrFoo) Test__SWIG_2(arg2 string) (_swig_ret int) { + return _swig_wrap_Foo_test__SWIG_2(arg1, arg2) +} + +func (p SwigcptrFoo) Test(a ...interface{}) int { + argc := len(a) + if argc == 1 { + if _, ok := a[0].(int); !ok { + goto check_1 + } + return p.Test__SWIG_0(a[0].(int)) + } +check_1: + if argc == 1 { + if _, ok := a[0].(float64); !ok { + goto check_2 + } + return p.Test__SWIG_1(a[0].(float64)) + } +check_2: + if argc == 1 { + return p.Test__SWIG_2(a[0].(string)) + } + panic("No match for overloaded function call") +} + +var _wrap_new_Foo unsafe.Pointer + +func _swig_wrap_new_Foo() (base SwigcptrFoo) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Foo, _swig_p) + return +} + +func NewFoo() (_swig_ret Foo) { + return _swig_wrap_new_Foo() +} + +var _wrap_delete_Foo unsafe.Pointer + +func _swig_wrap_delete_Foo(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Foo, _swig_p) + return +} + +func DeleteFoo(arg1 Foo) { + _swig_wrap_delete_Foo(arg1.Swigcptr()) +} + +type Foo interface { + Swigcptr() uintptr + SwigIsFoo() + SetX(arg2 int) + GetX() (_swig_ret int) + Test(a ...interface{}) int +} + +type SwigcptrBar uintptr + +func (p SwigcptrBar) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrBar) SwigIsBar() { +} + +var _wrap_new_Bar unsafe.Pointer + +func _swig_wrap_new_Bar(base uintptr) (_ SwigcptrBar) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Bar, _swig_p) + return +} + +func NewBar(arg1 Foo) (_swig_ret Bar) { + return _swig_wrap_new_Bar(arg1.Swigcptr()) +} + +var _wrap_Bar___deref__ unsafe.Pointer + +func _swig_wrap_Bar___deref__(base SwigcptrBar) (_ SwigcptrFoo) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Bar___deref__, _swig_p) + return +} + +func (arg1 SwigcptrBar) X__deref__() (_swig_ret Foo) { + return _swig_wrap_Bar___deref__(arg1) +} + +var _wrap_delete_Bar unsafe.Pointer + +func _swig_wrap_delete_Bar(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Bar, _swig_p) + return +} + +func DeleteBar(arg1 Bar) { + _swig_wrap_delete_Bar(arg1.Swigcptr()) +} + +var _wrap_Bar_x_set unsafe.Pointer + +func _swig_wrap_Bar_x_set(base SwigcptrBar, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Bar_x_set, _swig_p) + return +} + +func (arg1 SwigcptrBar) SetX(arg2 int) { + _swig_wrap_Bar_x_set(arg1, arg2) +} + +var _wrap_Bar_x_get unsafe.Pointer + +func _swig_wrap_Bar_x_get(base SwigcptrBar) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Bar_x_get, _swig_p) + return +} + +func (arg1 SwigcptrBar) GetX() (_swig_ret int) { + return _swig_wrap_Bar_x_get(arg1) +} + +var _wrap_Bar_test__SWIG_0 unsafe.Pointer + +func _swig_wrap_Bar_test__SWIG_0(base SwigcptrBar, _ int) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Bar_test__SWIG_0, _swig_p) + return +} + +func (arg1 SwigcptrBar) Test__SWIG_0(arg2 int) (_swig_ret int) { + return _swig_wrap_Bar_test__SWIG_0(arg1, arg2) +} + +var _wrap_Bar_test__SWIG_1 unsafe.Pointer + +func _swig_wrap_Bar_test__SWIG_1(base SwigcptrBar, _ float64) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Bar_test__SWIG_1, _swig_p) + return +} + +func (arg1 SwigcptrBar) Test__SWIG_1(arg2 float64) (_swig_ret int) { + return _swig_wrap_Bar_test__SWIG_1(arg1, arg2) +} + +var _wrap_Bar_test__SWIG_2 unsafe.Pointer + +func _swig_wrap_Bar_test__SWIG_2(base SwigcptrBar, _ string) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Bar_test__SWIG_2, _swig_p) + return +} + +func (arg1 SwigcptrBar) Test__SWIG_2(arg2 string) (_swig_ret int) { + return _swig_wrap_Bar_test__SWIG_2(arg1, arg2) +} + +func (p SwigcptrBar) Test(a ...interface{}) int { + argc := len(a) + if argc == 1 { + if _, ok := a[0].(int); !ok { + goto check_1 + } + return p.Test__SWIG_0(a[0].(int)) + } +check_1: + if argc == 1 { + if _, ok := a[0].(float64); !ok { + goto check_2 + } + return p.Test__SWIG_1(a[0].(float64)) + } +check_2: + if argc == 1 { + return p.Test__SWIG_2(a[0].(string)) + } + panic("No match for overloaded function call") +} + +type Bar interface { + Swigcptr() uintptr + SwigIsBar() + X__deref__() (_swig_ret Foo) + SetX(arg2 int) + GetX() (_swig_ret int) + Test(a ...interface{}) int +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/smart_pointer_overload_runme b/Examples/test-suite/go/smart_pointer_overload_runme new file mode 100755 index 000000000..6eb06c48d Binary files /dev/null and b/Examples/test-suite/go/smart_pointer_overload_runme differ diff --git a/Examples/test-suite/go/smart_pointer_protected.go b/Examples/test-suite/go/smart_pointer_protected.go new file mode 100644 index 000000000..0003a5181 --- /dev/null +++ b/Examples/test-suite/go/smart_pointer_protected.go @@ -0,0 +1,265 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../smart_pointer_protected.i + +package smart_pointer_protected + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrA uintptr + +func (p SwigcptrA) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrA) SwigIsA() { +} + +var _wrap_delete_A unsafe.Pointer + +func _swig_wrap_delete_A(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_A, _swig_p) + return +} + +func DeleteA(arg1 A) { + _swig_wrap_delete_A(arg1.Swigcptr()) +} + +var _wrap_A_value unsafe.Pointer + +func _swig_wrap_A_value(base SwigcptrA, _ uintptr) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_A_value, _swig_p) + return +} + +func (arg1 SwigcptrA) Value(arg2 A) (_swig_ret int) { + return _swig_wrap_A_value(arg1, arg2.Swigcptr()) +} + +var _wrap_A_index_set unsafe.Pointer + +func _swig_wrap_A_index_set(base SwigcptrA, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_A_index_set, _swig_p) + return +} + +func (arg1 SwigcptrA) SetIndex(arg2 int) { + _swig_wrap_A_index_set(arg1, arg2) +} + +var _wrap_A_index_get unsafe.Pointer + +func _swig_wrap_A_index_get(base SwigcptrA) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_A_index_get, _swig_p) + return +} + +func (arg1 SwigcptrA) GetIndex() (_swig_ret int) { + return _swig_wrap_A_index_get(arg1) +} + +type A interface { + Swigcptr() uintptr + SwigIsA() + Value(arg2 A) (_swig_ret int) + SetIndex(arg2 int) + GetIndex() (_swig_ret int) +} + +type SwigcptrB uintptr + +func (p SwigcptrB) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrB) SwigIsB() { +} + +var _wrap_new_B unsafe.Pointer + +func _swig_wrap_new_B() (base SwigcptrB) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_B, _swig_p) + return +} + +func NewB() (_swig_ret B) { + return _swig_wrap_new_B() +} + +var _wrap_delete_B unsafe.Pointer + +func _swig_wrap_delete_B(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_B, _swig_p) + return +} + +func DeleteB(arg1 B) { + _swig_wrap_delete_B(arg1.Swigcptr()) +} + +var _wrap_B_value unsafe.Pointer + +func _swig_wrap_B_value(base SwigcptrB, _ uintptr) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_B_value, _swig_p) + return +} + +func (_swig_base SwigcptrB) Value(arg1 A) (_swig_ret int) { + return _swig_wrap_B_value(_swig_base, arg1.Swigcptr()) +} + +var _wrap_SetB_Index unsafe.Pointer + +func _swig_wrap_SetB_Index(base SwigcptrB, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_SetB_Index, _swig_p) + return +} + +func (_swig_base SwigcptrB) SetIndex(arg1 int) { + _swig_wrap_SetB_Index(_swig_base, arg1) +} + +var _wrap_GetB_Index unsafe.Pointer + +func _swig_wrap_GetB_Index(base SwigcptrB) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_GetB_Index, _swig_p) + return +} + +func (_swig_base SwigcptrB) GetIndex() (_swig_ret int) { + return _swig_wrap_GetB_Index(_swig_base) +} + +func (p SwigcptrB) SwigIsA() { +} + +func (p SwigcptrB) SwigGetA() A { + return SwigcptrA(p.Swigcptr()) +} + +type B interface { + Swigcptr() uintptr + SwigIsB() + Value(arg1 A) (_swig_ret int) + SetIndex(arg1 int) + GetIndex() (_swig_ret int) + SwigIsA() + SwigGetA() A +} + +type SwigcptrC uintptr + +func (p SwigcptrC) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrC) SwigIsC() { +} + +var _wrap_C___deref__ unsafe.Pointer + +func _swig_wrap_C___deref__(base SwigcptrC) (_ SwigcptrB) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_C___deref__, _swig_p) + return +} + +func (arg1 SwigcptrC) X__deref__() (_swig_ret B) { + return _swig_wrap_C___deref__(arg1) +} + +var _wrap_new_C unsafe.Pointer + +func _swig_wrap_new_C() (base SwigcptrC) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_C, _swig_p) + return +} + +func NewC() (_swig_ret C) { + return _swig_wrap_new_C() +} + +var _wrap_delete_C unsafe.Pointer + +func _swig_wrap_delete_C(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_C, _swig_p) + return +} + +func DeleteC(arg1 C) { + _swig_wrap_delete_C(arg1.Swigcptr()) +} + +var _wrap_C_index_set unsafe.Pointer + +func _swig_wrap_C_index_set(base SwigcptrC, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_C_index_set, _swig_p) + return +} + +func (arg1 SwigcptrC) SetIndex(arg2 int) { + _swig_wrap_C_index_set(arg1, arg2) +} + +var _wrap_C_index_get unsafe.Pointer + +func _swig_wrap_C_index_get(base SwigcptrC) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_C_index_get, _swig_p) + return +} + +func (arg1 SwigcptrC) GetIndex() (_swig_ret int) { + return _swig_wrap_C_index_get(arg1) +} + +type C interface { + Swigcptr() uintptr + SwigIsC() + X__deref__() (_swig_ret B) + SetIndex(arg2 int) + GetIndex() (_swig_ret int) +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/smart_pointer_rename.go b/Examples/test-suite/go/smart_pointer_rename.go new file mode 100644 index 000000000..1f967df2b --- /dev/null +++ b/Examples/test-suite/go/smart_pointer_rename.go @@ -0,0 +1,191 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../smart_pointer_rename.i + +package smart_pointer_rename + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrFoo uintptr + +func (p SwigcptrFoo) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrFoo) SwigIsFoo() { +} + +var _wrap_Foo_ftest1 unsafe.Pointer + +func _swig_wrap_Foo_ftest1(base SwigcptrFoo, _ int) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_ftest1, _swig_p) + return +} + +func (arg1 SwigcptrFoo) Ftest1(arg2 int) (_swig_ret int) { + return _swig_wrap_Foo_ftest1(arg1, arg2) +} + +var _wrap_Foo_ftest2 unsafe.Pointer + +func _swig_wrap_Foo_ftest2(base SwigcptrFoo, _ int, _ int) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_ftest2, _swig_p) + return +} + +func (arg1 SwigcptrFoo) Ftest2(arg2 int, arg3 int) (_swig_ret int) { + return _swig_wrap_Foo_ftest2(arg1, arg2, arg3) +} + +var _wrap_new_Foo unsafe.Pointer + +func _swig_wrap_new_Foo() (base SwigcptrFoo) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Foo, _swig_p) + return +} + +func NewFoo() (_swig_ret Foo) { + return _swig_wrap_new_Foo() +} + +var _wrap_delete_Foo unsafe.Pointer + +func _swig_wrap_delete_Foo(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Foo, _swig_p) + return +} + +func DeleteFoo(arg1 Foo) { + _swig_wrap_delete_Foo(arg1.Swigcptr()) +} + +type Foo interface { + Swigcptr() uintptr + SwigIsFoo() + Ftest1(arg2 int) (_swig_ret int) + Ftest2(arg2 int, arg3 int) (_swig_ret int) +} + +type SwigcptrBar uintptr + +func (p SwigcptrBar) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrBar) SwigIsBar() { +} + +var _wrap_new_Bar unsafe.Pointer + +func _swig_wrap_new_Bar(base uintptr) (_ SwigcptrBar) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Bar, _swig_p) + return +} + +func NewBar(arg1 Foo) (_swig_ret Bar) { + return _swig_wrap_new_Bar(arg1.Swigcptr()) +} + +var _wrap_Bar___deref__ unsafe.Pointer + +func _swig_wrap_Bar___deref__(base SwigcptrBar) (_ SwigcptrFoo) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Bar___deref__, _swig_p) + return +} + +func (arg1 SwigcptrBar) X__deref__() (_swig_ret Foo) { + return _swig_wrap_Bar___deref__(arg1) +} + +var _wrap_Bar_test unsafe.Pointer + +func _swig_wrap_Bar_test(base SwigcptrBar) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Bar_test, _swig_p) + return +} + +func (arg1 SwigcptrBar) Test() (_swig_ret int) { + return _swig_wrap_Bar_test(arg1) +} + +var _wrap_delete_Bar unsafe.Pointer + +func _swig_wrap_delete_Bar(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Bar, _swig_p) + return +} + +func DeleteBar(arg1 Bar) { + _swig_wrap_delete_Bar(arg1.Swigcptr()) +} + +var _wrap_Bar_ftest1 unsafe.Pointer + +func _swig_wrap_Bar_ftest1(base SwigcptrBar, _ int) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Bar_ftest1, _swig_p) + return +} + +func (arg1 SwigcptrBar) Ftest1(arg2 int) (_swig_ret int) { + return _swig_wrap_Bar_ftest1(arg1, arg2) +} + +var _wrap_Bar_ftest2 unsafe.Pointer + +func _swig_wrap_Bar_ftest2(base SwigcptrBar, _ int, _ int) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Bar_ftest2, _swig_p) + return +} + +func (arg1 SwigcptrBar) Ftest2(arg2 int, arg3 int) (_swig_ret int) { + return _swig_wrap_Bar_ftest2(arg1, arg2, arg3) +} + +type Bar interface { + Swigcptr() uintptr + SwigIsBar() + X__deref__() (_swig_ret Foo) + Test() (_swig_ret int) + Ftest1(arg2 int) (_swig_ret int) + Ftest2(arg2 int, arg3 int) (_swig_ret int) +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/smart_pointer_rename_runme b/Examples/test-suite/go/smart_pointer_rename_runme new file mode 100755 index 000000000..6e712dd20 Binary files /dev/null and b/Examples/test-suite/go/smart_pointer_rename_runme differ diff --git a/Examples/test-suite/go/smart_pointer_simple.go b/Examples/test-suite/go/smart_pointer_simple.go new file mode 100644 index 000000000..d3d5b934e --- /dev/null +++ b/Examples/test-suite/go/smart_pointer_simple.go @@ -0,0 +1,204 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../smart_pointer_simple.i + +package smart_pointer_simple + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrFoo uintptr + +func (p SwigcptrFoo) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrFoo) SwigIsFoo() { +} + +var _wrap_Foo_x_set unsafe.Pointer + +func _swig_wrap_Foo_x_set(base SwigcptrFoo, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_x_set, _swig_p) + return +} + +func (arg1 SwigcptrFoo) SetX(arg2 int) { + _swig_wrap_Foo_x_set(arg1, arg2) +} + +var _wrap_Foo_x_get unsafe.Pointer + +func _swig_wrap_Foo_x_get(base SwigcptrFoo) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_x_get, _swig_p) + return +} + +func (arg1 SwigcptrFoo) GetX() (_swig_ret int) { + return _swig_wrap_Foo_x_get(arg1) +} + +var _wrap_Foo_getx unsafe.Pointer + +func _swig_wrap_Foo_getx(base SwigcptrFoo) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_getx, _swig_p) + return +} + +func (arg1 SwigcptrFoo) Getx() (_swig_ret int) { + return _swig_wrap_Foo_getx(arg1) +} + +var _wrap_new_Foo unsafe.Pointer + +func _swig_wrap_new_Foo() (base SwigcptrFoo) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Foo, _swig_p) + return +} + +func NewFoo() (_swig_ret Foo) { + return _swig_wrap_new_Foo() +} + +var _wrap_delete_Foo unsafe.Pointer + +func _swig_wrap_delete_Foo(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Foo, _swig_p) + return +} + +func DeleteFoo(arg1 Foo) { + _swig_wrap_delete_Foo(arg1.Swigcptr()) +} + +type Foo interface { + Swigcptr() uintptr + SwigIsFoo() + SetX(arg2 int) + GetX() (_swig_ret int) + Getx() (_swig_ret int) +} + +type SwigcptrBar uintptr + +func (p SwigcptrBar) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrBar) SwigIsBar() { +} + +var _wrap_new_Bar unsafe.Pointer + +func _swig_wrap_new_Bar(base uintptr) (_ SwigcptrBar) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Bar, _swig_p) + return +} + +func NewBar(arg1 Foo) (_swig_ret Bar) { + return _swig_wrap_new_Bar(arg1.Swigcptr()) +} + +var _wrap_Bar___deref__ unsafe.Pointer + +func _swig_wrap_Bar___deref__(base SwigcptrBar) (_ SwigcptrFoo) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Bar___deref__, _swig_p) + return +} + +func (arg1 SwigcptrBar) X__deref__() (_swig_ret Foo) { + return _swig_wrap_Bar___deref__(arg1) +} + +var _wrap_delete_Bar unsafe.Pointer + +func _swig_wrap_delete_Bar(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Bar, _swig_p) + return +} + +func DeleteBar(arg1 Bar) { + _swig_wrap_delete_Bar(arg1.Swigcptr()) +} + +var _wrap_Bar_x_set unsafe.Pointer + +func _swig_wrap_Bar_x_set(base SwigcptrBar, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Bar_x_set, _swig_p) + return +} + +func (arg1 SwigcptrBar) SetX(arg2 int) { + _swig_wrap_Bar_x_set(arg1, arg2) +} + +var _wrap_Bar_x_get unsafe.Pointer + +func _swig_wrap_Bar_x_get(base SwigcptrBar) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Bar_x_get, _swig_p) + return +} + +func (arg1 SwigcptrBar) GetX() (_swig_ret int) { + return _swig_wrap_Bar_x_get(arg1) +} + +var _wrap_Bar_getx unsafe.Pointer + +func _swig_wrap_Bar_getx(base SwigcptrBar) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Bar_getx, _swig_p) + return +} + +func (arg1 SwigcptrBar) Getx() (_swig_ret int) { + return _swig_wrap_Bar_getx(arg1) +} + +type Bar interface { + Swigcptr() uintptr + SwigIsBar() + X__deref__() (_swig_ret Foo) + SetX(arg2 int) + GetX() (_swig_ret int) + Getx() (_swig_ret int) +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/smart_pointer_simple_runme b/Examples/test-suite/go/smart_pointer_simple_runme new file mode 100755 index 000000000..b759a8c23 Binary files /dev/null and b/Examples/test-suite/go/smart_pointer_simple_runme differ diff --git a/Examples/test-suite/go/smart_pointer_static.go b/Examples/test-suite/go/smart_pointer_static.go new file mode 100644 index 000000000..bf096a805 --- /dev/null +++ b/Examples/test-suite/go/smart_pointer_static.go @@ -0,0 +1,196 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../smart_pointer_static.i + +package smart_pointer_static + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrMyHandle_Foo2 uintptr + +func (p SwigcptrMyHandle_Foo2) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrMyHandle_Foo2) SwigIsMyHandle_Foo2() { +} + +var _wrap_MyHandle_Foo2___deref__ unsafe.Pointer + +func _swig_wrap_MyHandle_Foo2___deref__(base SwigcptrMyHandle_Foo2) (_ SwigcptrFoo2) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_MyHandle_Foo2___deref__, _swig_p) + return +} + +func (arg1 SwigcptrMyHandle_Foo2) X__deref__() (_swig_ret Foo2) { + return _swig_wrap_MyHandle_Foo2___deref__(arg1) +} + +var _wrap_new_MyHandle_Foo2 unsafe.Pointer + +func _swig_wrap_new_MyHandle_Foo2() (base SwigcptrMyHandle_Foo2) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_MyHandle_Foo2, _swig_p) + return +} + +func NewMyHandle_Foo2() (_swig_ret MyHandle_Foo2) { + return _swig_wrap_new_MyHandle_Foo2() +} + +var _wrap_delete_MyHandle_Foo2 unsafe.Pointer + +func _swig_wrap_delete_MyHandle_Foo2(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_MyHandle_Foo2, _swig_p) + return +} + +func DeleteMyHandle_Foo2(arg1 MyHandle_Foo2) { + _swig_wrap_delete_MyHandle_Foo2(arg1.Swigcptr()) +} + +var _wrap_MyHandle_Foo2_sum__SWIG_0 unsafe.Pointer + +func _swig_wrap_MyHandle_Foo2_sum__SWIG_0(base SwigcptrMyHandle_Foo2, _ int, _ int) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_MyHandle_Foo2_sum__SWIG_0, _swig_p) + return +} + +func (arg1 SwigcptrMyHandle_Foo2) Sum__SWIG_0(arg2 int, arg3 int) (_swig_ret int) { + return _swig_wrap_MyHandle_Foo2_sum__SWIG_0(arg1, arg2, arg3) +} + +var _wrap_MyHandle_Foo2_sum__SWIG_1 unsafe.Pointer + +func _swig_wrap_MyHandle_Foo2_sum__SWIG_1(base SwigcptrMyHandle_Foo2, _ int, _ int, _ int) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_MyHandle_Foo2_sum__SWIG_1, _swig_p) + return +} + +func (arg1 SwigcptrMyHandle_Foo2) Sum__SWIG_1(arg2 int, arg3 int, arg4 int) (_swig_ret int) { + return _swig_wrap_MyHandle_Foo2_sum__SWIG_1(arg1, arg2, arg3, arg4) +} + +func (p SwigcptrMyHandle_Foo2) Sum(a ...interface{}) int { + argc := len(a) + if argc == 2 { + return p.Sum__SWIG_0(a[0].(int), a[1].(int)) + } + if argc == 3 { + return p.Sum__SWIG_1(a[0].(int), a[1].(int), a[2].(int)) + } + panic("No match for overloaded function call") +} + +type MyHandle_Foo2 interface { + Swigcptr() uintptr + SwigIsMyHandle_Foo2() + X__deref__() (_swig_ret Foo2) + Sum(a ...interface{}) int +} + +type SwigcptrFoo2 uintptr + +func (p SwigcptrFoo2) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrFoo2) SwigIsFoo2() { +} + +var _wrap_delete_Foo2 unsafe.Pointer + +func _swig_wrap_delete_Foo2(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Foo2, _swig_p) + return +} + +func DeleteFoo2(arg1 Foo2) { + _swig_wrap_delete_Foo2(arg1.Swigcptr()) +} + +var _wrap_Foo2_sum__SWIG_0 unsafe.Pointer + +func _swig_wrap_Foo2_sum__SWIG_0(base SwigcptrFoo2, _ int, _ int) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo2_sum__SWIG_0, _swig_p) + return +} + +func (arg1 SwigcptrFoo2) Sum__SWIG_0(arg2 int, arg3 int) (_swig_ret int) { + return _swig_wrap_Foo2_sum__SWIG_0(arg1, arg2, arg3) +} + +var _wrap_Foo2_sum__SWIG_1 unsafe.Pointer + +func Foo2Sum__SWIG_1(arg1 int, arg2 int, arg3 int) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_Foo2_sum__SWIG_1, _swig_p) + return +} +func Foo2Sum(a ...interface{}) int { + argc := len(a) + if argc == 3 { + if _, ok := a[0].(Foo2); !ok { + goto check_1 + } + return a[0].(SwigcptrFoo2).Sum__SWIG_0(a[1].(int), a[2].(int)) + } +check_1: + if argc == 3 { + return Foo2Sum__SWIG_1(a[0].(int), a[1].(int), a[2].(int)) + } + panic("No match for overloaded function call") +} + +var _wrap_new_Foo2 unsafe.Pointer + +func _swig_wrap_new_Foo2() (base SwigcptrFoo2) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Foo2, _swig_p) + return +} + +func NewFoo2() (_swig_ret Foo2) { + return _swig_wrap_new_Foo2() +} + +type Foo2 interface { + Swigcptr() uintptr + SwigIsFoo2() +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/smart_pointer_template_const_overload.go b/Examples/test-suite/go/smart_pointer_template_const_overload.go new file mode 100644 index 000000000..562b0c3ed --- /dev/null +++ b/Examples/test-suite/go/smart_pointer_template_const_overload.go @@ -0,0 +1,373 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../smart_pointer_template_const_overload.i + +package smart_pointer_template_const_overload + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrFooImplementation uintptr + +func (p SwigcptrFooImplementation) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrFooImplementation) SwigIsFooImplementation() { +} + +var _wrap_FooImplementation_mingy unsafe.Pointer + +func _swig_wrap_FooImplementation_mingy(base SwigcptrFooImplementation) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_FooImplementation_mingy, _swig_p) + return +} + +func (arg1 SwigcptrFooImplementation) Mingy() (_swig_ret int) { + return _swig_wrap_FooImplementation_mingy(arg1) +} + +var _wrap_FooImplementation_constmingy unsafe.Pointer + +func _swig_wrap_FooImplementation_constmingy(base SwigcptrFooImplementation) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_FooImplementation_constmingy, _swig_p) + return +} + +func (arg1 SwigcptrFooImplementation) Constmingy() (_swig_ret int) { + return _swig_wrap_FooImplementation_constmingy(arg1) +} + +var _wrap_FooImplementation_thingy unsafe.Pointer + +func FooImplementationThingy() (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_FooImplementation_thingy, _swig_p) + return +} +var _wrap_FooImplementation_svariable_set unsafe.Pointer + +func _swig_wrap_FooImplementation_svariable_set(base int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_FooImplementation_svariable_set, _swig_p) + return +} + +func SetFooImplementationSvariable(arg1 int) { + _swig_wrap_FooImplementation_svariable_set(arg1) +} + +var _wrap_FooImplementation_svariable_get unsafe.Pointer + +func GetFooImplementationSvariable() (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_FooImplementation_svariable_get, _swig_p) + return +} +var _wrap_FooImplementation_constsvariable_get unsafe.Pointer + +func GetFooImplementationConstsvariable() (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_FooImplementation_constsvariable_get, _swig_p) + return +} +var _wrap_FooImplementation_normalvariable_set unsafe.Pointer + +func _swig_wrap_FooImplementation_normalvariable_set(base SwigcptrFooImplementation, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_FooImplementation_normalvariable_set, _swig_p) + return +} + +func (arg1 SwigcptrFooImplementation) SetNormalvariable(arg2 int) { + _swig_wrap_FooImplementation_normalvariable_set(arg1, arg2) +} + +var _wrap_FooImplementation_normalvariable_get unsafe.Pointer + +func _swig_wrap_FooImplementation_normalvariable_get(base SwigcptrFooImplementation) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_FooImplementation_normalvariable_get, _swig_p) + return +} + +func (arg1 SwigcptrFooImplementation) GetNormalvariable() (_swig_ret int) { + return _swig_wrap_FooImplementation_normalvariable_get(arg1) +} + +var _wrap_new_FooImplementation unsafe.Pointer + +func _swig_wrap_new_FooImplementation() (base SwigcptrFooImplementation) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_FooImplementation, _swig_p) + return +} + +func NewFooImplementation() (_swig_ret FooImplementation) { + return _swig_wrap_new_FooImplementation() +} + +var _wrap_delete_FooImplementation unsafe.Pointer + +func _swig_wrap_delete_FooImplementation(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_FooImplementation, _swig_p) + return +} + +func DeleteFooImplementation(arg1 FooImplementation) { + _swig_wrap_delete_FooImplementation(arg1.Swigcptr()) +} + +type FooImplementation interface { + Swigcptr() uintptr + SwigIsFooImplementation() + Mingy() (_swig_ret int) + Constmingy() (_swig_ret int) + SetNormalvariable(arg2 int) + GetNormalvariable() (_swig_ret int) +} + +var _wrap_tester unsafe.Pointer + +func _swig_wrap_tester() { + var _swig_p uintptr + _cgo_runtime_cgocall(_wrap_tester, _swig_p) + return +} + +func Tester() { + _swig_wrap_tester() +} + +type SwigcptrFooSmartPointer uintptr + +func (p SwigcptrFooSmartPointer) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrFooSmartPointer) SwigIsFooSmartPointer() { +} + +var _wrap_new_FooSmartPointer__SWIG_0 unsafe.Pointer + +func _swig_wrap_new_FooSmartPointer__SWIG_0(base uintptr) (_ SwigcptrFooSmartPointer) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_FooSmartPointer__SWIG_0, _swig_p) + return +} + +func NewFooSmartPointer__SWIG_0(arg1 FooImplementation) (_swig_ret FooSmartPointer) { + return _swig_wrap_new_FooSmartPointer__SWIG_0(arg1.Swigcptr()) +} + +var _wrap_new_FooSmartPointer__SWIG_1 unsafe.Pointer + +func _swig_wrap_new_FooSmartPointer__SWIG_1() (base SwigcptrFooSmartPointer) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_FooSmartPointer__SWIG_1, _swig_p) + return +} + +func NewFooSmartPointer__SWIG_1() (_swig_ret FooSmartPointer) { + return _swig_wrap_new_FooSmartPointer__SWIG_1() +} + +func NewFooSmartPointer(a ...interface{}) FooSmartPointer { + argc := len(a) + if argc == 0 { + return NewFooSmartPointer__SWIG_1() + } + if argc == 1 { + return NewFooSmartPointer__SWIG_0(a[0].(FooImplementation)) + } + panic("No match for overloaded function call") +} + +var _wrap_FooSmartPointer___deref____SWIG_0 unsafe.Pointer + +func _swig_wrap_FooSmartPointer___deref____SWIG_0(base SwigcptrFooSmartPointer) (_ SwigcptrFooImplementation) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_FooSmartPointer___deref____SWIG_0, _swig_p) + return +} + +func (arg1 SwigcptrFooSmartPointer) X__deref____SWIG_0() (_swig_ret FooImplementation) { + return _swig_wrap_FooSmartPointer___deref____SWIG_0(arg1) +} + +var _wrap_FooSmartPointer___deref____SWIG_1 unsafe.Pointer + +func _swig_wrap_FooSmartPointer___deref____SWIG_1(base SwigcptrFooSmartPointer) (_ SwigcptrFooImplementation) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_FooSmartPointer___deref____SWIG_1, _swig_p) + return +} + +func (arg1 SwigcptrFooSmartPointer) X__deref____SWIG_1() (_swig_ret FooImplementation) { + return _swig_wrap_FooSmartPointer___deref____SWIG_1(arg1) +} + +func (p SwigcptrFooSmartPointer) X__deref__(a ...interface{}) interface{} { + argc := len(a) + if argc == 0 { + return p.X__deref____SWIG_0() + } + if argc == 0 { + return p.X__deref____SWIG_1() + } + panic("No match for overloaded function call") +} + +var _wrap_delete_FooSmartPointer unsafe.Pointer + +func _swig_wrap_delete_FooSmartPointer(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_FooSmartPointer, _swig_p) + return +} + +func DeleteFooSmartPointer(arg1 FooSmartPointer) { + _swig_wrap_delete_FooSmartPointer(arg1.Swigcptr()) +} + +var _wrap_FooSmartPointer_mingy unsafe.Pointer + +func _swig_wrap_FooSmartPointer_mingy(base SwigcptrFooSmartPointer) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_FooSmartPointer_mingy, _swig_p) + return +} + +func (arg1 SwigcptrFooSmartPointer) Mingy() (_swig_ret int) { + return _swig_wrap_FooSmartPointer_mingy(arg1) +} + +var _wrap_FooSmartPointer_constmingy unsafe.Pointer + +func _swig_wrap_FooSmartPointer_constmingy(base SwigcptrFooSmartPointer) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_FooSmartPointer_constmingy, _swig_p) + return +} + +func (arg1 SwigcptrFooSmartPointer) Constmingy() (_swig_ret int) { + return _swig_wrap_FooSmartPointer_constmingy(arg1) +} + +var _wrap_FooSmartPointer_thingy unsafe.Pointer + +func _swig_wrap_FooSmartPointer_thingy(base SwigcptrFooSmartPointer) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_FooSmartPointer_thingy, _swig_p) + return +} + +func (arg1 SwigcptrFooSmartPointer) Thingy() (_swig_ret int) { + return _swig_wrap_FooSmartPointer_thingy(arg1) +} + +var _wrap_FooSmartPointer_svariable_set unsafe.Pointer + +func _swig_wrap_FooSmartPointer_svariable_set(base SwigcptrFooSmartPointer, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_FooSmartPointer_svariable_set, _swig_p) + return +} + +func (arg1 SwigcptrFooSmartPointer) SetSvariable(arg2 int) { + _swig_wrap_FooSmartPointer_svariable_set(arg1, arg2) +} + +var _wrap_FooSmartPointer_svariable_get unsafe.Pointer + +func _swig_wrap_FooSmartPointer_svariable_get(base SwigcptrFooSmartPointer) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_FooSmartPointer_svariable_get, _swig_p) + return +} + +func (arg1 SwigcptrFooSmartPointer) GetSvariable() (_swig_ret int) { + return _swig_wrap_FooSmartPointer_svariable_get(arg1) +} + +var _wrap_FooSmartPointer_constsvariable_get unsafe.Pointer + +func _swig_wrap_FooSmartPointer_constsvariable_get(base SwigcptrFooSmartPointer) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_FooSmartPointer_constsvariable_get, _swig_p) + return +} + +func (arg1 SwigcptrFooSmartPointer) GetConstsvariable() (_swig_ret int) { + return _swig_wrap_FooSmartPointer_constsvariable_get(arg1) +} + +var _wrap_FooSmartPointer_normalvariable_set unsafe.Pointer + +func _swig_wrap_FooSmartPointer_normalvariable_set(base SwigcptrFooSmartPointer, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_FooSmartPointer_normalvariable_set, _swig_p) + return +} + +func (arg1 SwigcptrFooSmartPointer) SetNormalvariable(arg2 int) { + _swig_wrap_FooSmartPointer_normalvariable_set(arg1, arg2) +} + +var _wrap_FooSmartPointer_normalvariable_get unsafe.Pointer + +func _swig_wrap_FooSmartPointer_normalvariable_get(base SwigcptrFooSmartPointer) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_FooSmartPointer_normalvariable_get, _swig_p) + return +} + +func (arg1 SwigcptrFooSmartPointer) GetNormalvariable() (_swig_ret int) { + return _swig_wrap_FooSmartPointer_normalvariable_get(arg1) +} + +type FooSmartPointer interface { + Swigcptr() uintptr + SwigIsFooSmartPointer() + X__deref__(a ...interface{}) interface{} + Mingy() (_swig_ret int) + Constmingy() (_swig_ret int) + Thingy() (_swig_ret int) + SetSvariable(arg2 int) + GetSvariable() (_swig_ret int) + GetConstsvariable() (_swig_ret int) + SetNormalvariable(arg2 int) + GetNormalvariable() (_swig_ret int) +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/smart_pointer_template_defaults_overload.go b/Examples/test-suite/go/smart_pointer_template_defaults_overload.go new file mode 100644 index 000000000..1ac97b7be --- /dev/null +++ b/Examples/test-suite/go/smart_pointer_template_defaults_overload.go @@ -0,0 +1,748 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../smart_pointer_template_defaults_overload.i + +package smart_pointer_template_defaults_overload + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrStringDoubleMap uintptr + +func (p SwigcptrStringDoubleMap) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrStringDoubleMap) SwigIsStringDoubleMap() { +} + +var _wrap_new_StringDoubleMap__SWIG_0 unsafe.Pointer + +func _swig_wrap_new_StringDoubleMap__SWIG_0() (base SwigcptrStringDoubleMap) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_StringDoubleMap__SWIG_0, _swig_p) + return +} + +func NewStringDoubleMap__SWIG_0() (_swig_ret StringDoubleMap) { + return _swig_wrap_new_StringDoubleMap__SWIG_0() +} + +var _wrap_new_StringDoubleMap__SWIG_1 unsafe.Pointer + +func _swig_wrap_new_StringDoubleMap__SWIG_1(base uintptr) (_ SwigcptrStringDoubleMap) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_StringDoubleMap__SWIG_1, _swig_p) + return +} + +func NewStringDoubleMap__SWIG_1(arg1 StringDoubleMap) (_swig_ret StringDoubleMap) { + return _swig_wrap_new_StringDoubleMap__SWIG_1(arg1.Swigcptr()) +} + +func NewStringDoubleMap(a ...interface{}) StringDoubleMap { + argc := len(a) + if argc == 0 { + return NewStringDoubleMap__SWIG_0() + } + if argc == 1 { + return NewStringDoubleMap__SWIG_1(a[0].(StringDoubleMap)) + } + panic("No match for overloaded function call") +} + +var _wrap_StringDoubleMap_size unsafe.Pointer + +func _swig_wrap_StringDoubleMap_size(base SwigcptrStringDoubleMap) (_ uint) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_StringDoubleMap_size, _swig_p) + return +} + +func (arg1 SwigcptrStringDoubleMap) Size() (_swig_ret uint) { + return _swig_wrap_StringDoubleMap_size(arg1) +} + +var _wrap_StringDoubleMap_empty unsafe.Pointer + +func _swig_wrap_StringDoubleMap_empty(base SwigcptrStringDoubleMap) (_ bool) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_StringDoubleMap_empty, _swig_p) + return +} + +func (arg1 SwigcptrStringDoubleMap) Empty() (_swig_ret bool) { + return _swig_wrap_StringDoubleMap_empty(arg1) +} + +var _wrap_StringDoubleMap_clear unsafe.Pointer + +func _swig_wrap_StringDoubleMap_clear(base SwigcptrStringDoubleMap) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_StringDoubleMap_clear, _swig_p) + return +} + +func (arg1 SwigcptrStringDoubleMap) Clear() { + _swig_wrap_StringDoubleMap_clear(arg1) +} + +var _wrap_StringDoubleMap_get unsafe.Pointer + +func _swig_wrap_StringDoubleMap_get(base SwigcptrStringDoubleMap, _ string) (_ float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_StringDoubleMap_get, _swig_p) + return +} + +func (arg1 SwigcptrStringDoubleMap) Get(arg2 string) (_swig_ret float64) { + return _swig_wrap_StringDoubleMap_get(arg1, arg2) +} + +var _wrap_StringDoubleMap_set unsafe.Pointer + +func _swig_wrap_StringDoubleMap_set(base SwigcptrStringDoubleMap, _ string, _ float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_StringDoubleMap_set, _swig_p) + return +} + +func (arg1 SwigcptrStringDoubleMap) Set(arg2 string, arg3 float64) { + _swig_wrap_StringDoubleMap_set(arg1, arg2, arg3) +} + +var _wrap_StringDoubleMap_del unsafe.Pointer + +func _swig_wrap_StringDoubleMap_del(base SwigcptrStringDoubleMap, _ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_StringDoubleMap_del, _swig_p) + return +} + +func (arg1 SwigcptrStringDoubleMap) Del(arg2 string) { + _swig_wrap_StringDoubleMap_del(arg1, arg2) +} + +var _wrap_StringDoubleMap_has_key unsafe.Pointer + +func _swig_wrap_StringDoubleMap_has_key(base SwigcptrStringDoubleMap, _ string) (_ bool) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_StringDoubleMap_has_key, _swig_p) + return +} + +func (arg1 SwigcptrStringDoubleMap) Has_key(arg2 string) (_swig_ret bool) { + return _swig_wrap_StringDoubleMap_has_key(arg1, arg2) +} + +var _wrap_delete_StringDoubleMap unsafe.Pointer + +func _swig_wrap_delete_StringDoubleMap(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_StringDoubleMap, _swig_p) + return +} + +func DeleteStringDoubleMap(arg1 StringDoubleMap) { + _swig_wrap_delete_StringDoubleMap(arg1.Swigcptr()) +} + +type StringDoubleMap interface { + Swigcptr() uintptr + SwigIsStringDoubleMap() + Size() (_swig_ret uint) + Empty() (_swig_ret bool) + Clear() + Get(arg2 string) (_swig_ret float64) + Set(arg2 string, arg3 float64) + Del(arg2 string) + Has_key(arg2 string) (_swig_ret bool) +} + +type SwigcptrWrappedMap uintptr + +func (p SwigcptrWrappedMap) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrWrappedMap) SwigIsWrappedMap() { +} + +var _wrap_new_WrappedMap unsafe.Pointer + +func _swig_wrap_new_WrappedMap(base uintptr) (_ SwigcptrWrappedMap) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_WrappedMap, _swig_p) + return +} + +func NewWrappedMap(arg1 StringDoubleMap) (_swig_ret WrappedMap) { + return _swig_wrap_new_WrappedMap(arg1.Swigcptr()) +} + +var _wrap_WrappedMap___deref____SWIG_0 unsafe.Pointer + +func _swig_wrap_WrappedMap___deref____SWIG_0(base SwigcptrWrappedMap) (_ SwigcptrStringDoubleMap) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_WrappedMap___deref____SWIG_0, _swig_p) + return +} + +func (arg1 SwigcptrWrappedMap) X__deref____SWIG_0() (_swig_ret StringDoubleMap) { + return _swig_wrap_WrappedMap___deref____SWIG_0(arg1) +} + +var _wrap_WrappedMap___deref____SWIG_1 unsafe.Pointer + +func _swig_wrap_WrappedMap___deref____SWIG_1(base SwigcptrWrappedMap) (_ SwigcptrStringDoubleMap) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_WrappedMap___deref____SWIG_1, _swig_p) + return +} + +func (arg1 SwigcptrWrappedMap) X__deref____SWIG_1() (_swig_ret StringDoubleMap) { + return _swig_wrap_WrappedMap___deref____SWIG_1(arg1) +} + +func (p SwigcptrWrappedMap) X__deref__(a ...interface{}) interface{} { + argc := len(a) + if argc == 0 { + return p.X__deref____SWIG_0() + } + if argc == 0 { + return p.X__deref____SWIG_1() + } + panic("No match for overloaded function call") +} + +var _wrap_delete_WrappedMap unsafe.Pointer + +func _swig_wrap_delete_WrappedMap(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_WrappedMap, _swig_p) + return +} + +func DeleteWrappedMap(arg1 WrappedMap) { + _swig_wrap_delete_WrappedMap(arg1.Swigcptr()) +} + +var _wrap_WrappedMap_size unsafe.Pointer + +func _swig_wrap_WrappedMap_size(base SwigcptrWrappedMap) (_ uint) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_WrappedMap_size, _swig_p) + return +} + +func (arg1 SwigcptrWrappedMap) Size() (_swig_ret uint) { + return _swig_wrap_WrappedMap_size(arg1) +} + +var _wrap_WrappedMap_empty unsafe.Pointer + +func _swig_wrap_WrappedMap_empty(base SwigcptrWrappedMap) (_ bool) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_WrappedMap_empty, _swig_p) + return +} + +func (arg1 SwigcptrWrappedMap) Empty() (_swig_ret bool) { + return _swig_wrap_WrappedMap_empty(arg1) +} + +var _wrap_WrappedMap_clear unsafe.Pointer + +func _swig_wrap_WrappedMap_clear(base SwigcptrWrappedMap) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_WrappedMap_clear, _swig_p) + return +} + +func (arg1 SwigcptrWrappedMap) Clear() { + _swig_wrap_WrappedMap_clear(arg1) +} + +var _wrap_WrappedMap_get unsafe.Pointer + +func _swig_wrap_WrappedMap_get(base SwigcptrWrappedMap, _ string) (_ float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_WrappedMap_get, _swig_p) + return +} + +func (arg1 SwigcptrWrappedMap) Get(arg2 string) (_swig_ret float64) { + return _swig_wrap_WrappedMap_get(arg1, arg2) +} + +var _wrap_WrappedMap_set unsafe.Pointer + +func _swig_wrap_WrappedMap_set(base SwigcptrWrappedMap, _ string, _ float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_WrappedMap_set, _swig_p) + return +} + +func (arg1 SwigcptrWrappedMap) Set(arg2 string, arg3 float64) { + _swig_wrap_WrappedMap_set(arg1, arg2, arg3) +} + +var _wrap_WrappedMap_del unsafe.Pointer + +func _swig_wrap_WrappedMap_del(base SwigcptrWrappedMap, _ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_WrappedMap_del, _swig_p) + return +} + +func (arg1 SwigcptrWrappedMap) Del(arg2 string) { + _swig_wrap_WrappedMap_del(arg1, arg2) +} + +var _wrap_WrappedMap_has_key unsafe.Pointer + +func _swig_wrap_WrappedMap_has_key(base SwigcptrWrappedMap, _ string) (_ bool) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_WrappedMap_has_key, _swig_p) + return +} + +func (arg1 SwigcptrWrappedMap) Has_key(arg2 string) (_swig_ret bool) { + return _swig_wrap_WrappedMap_has_key(arg1, arg2) +} + +type WrappedMap interface { + Swigcptr() uintptr + SwigIsWrappedMap() + X__deref__(a ...interface{}) interface{} + Size() (_swig_ret uint) + Empty() (_swig_ret bool) + Clear() + Get(arg2 string) (_swig_ret float64) + Set(arg2 string, arg3 float64) + Del(arg2 string) + Has_key(arg2 string) (_swig_ret bool) +} + +type SwigcptrContainerInt uintptr + +func (p SwigcptrContainerInt) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrContainerInt) SwigIsContainerInt() { +} + +var _wrap_ContainerInt_rubout__SWIG_0 unsafe.Pointer + +func _swig_wrap_ContainerInt_rubout__SWIG_0(base SwigcptrContainerInt) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_ContainerInt_rubout__SWIG_0, _swig_p) + return +} + +func (arg1 SwigcptrContainerInt) Rubout__SWIG_0() (_swig_ret int) { + return _swig_wrap_ContainerInt_rubout__SWIG_0(arg1) +} + +var _wrap_ContainerInt_rubout__SWIG_1 unsafe.Pointer + +func _swig_wrap_ContainerInt_rubout__SWIG_1(base SwigcptrContainerInt, _ float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_ContainerInt_rubout__SWIG_1, _swig_p) + return +} + +func (arg1 SwigcptrContainerInt) Rubout__SWIG_1(arg2 float64) { + _swig_wrap_ContainerInt_rubout__SWIG_1(arg1, arg2) +} + +var _wrap_ContainerInt_factory__SWIG_0 unsafe.Pointer + +func _swig_wrap_ContainerInt_factory__SWIG_0() (base SwigcptrContainerInt) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_ContainerInt_factory__SWIG_0, _swig_p) + return +} + +func ContainerIntFactory__SWIG_0() (_swig_ret ContainerInt) { + return _swig_wrap_ContainerInt_factory__SWIG_0() +} + +var _wrap_ContainerInt_factory__SWIG_1 unsafe.Pointer + +func _swig_wrap_ContainerInt_factory__SWIG_1(base bool) (_ SwigcptrContainerInt) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_ContainerInt_factory__SWIG_1, _swig_p) + return +} + +func ContainerIntFactory__SWIG_1(arg1 bool) (_swig_ret ContainerInt) { + return _swig_wrap_ContainerInt_factory__SWIG_1(arg1) +} + +func ContainerIntFactory(a ...interface{}) ContainerInt { + argc := len(a) + if argc == 0 { + return ContainerIntFactory__SWIG_0() + } + if argc == 1 { + return ContainerIntFactory__SWIG_1(a[0].(bool)) + } + panic("No match for overloaded function call") +} + +var _wrap_ContainerInt_staticstuff unsafe.Pointer + +func _swig_wrap_ContainerInt_staticstuff(base bool) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_ContainerInt_staticstuff, _swig_p) + return +} + +func ContainerIntStaticstuff(arg1 bool) { + _swig_wrap_ContainerInt_staticstuff(arg1) +} + +var _wrap_ContainerInt_rubout__SWIG_2 unsafe.Pointer + +func _swig_wrap_ContainerInt_rubout__SWIG_2(base SwigcptrContainerInt, _ bool) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_ContainerInt_rubout__SWIG_2, _swig_p) + return +} + +func (arg1 SwigcptrContainerInt) Rubout__SWIG_2(arg2 bool) { + _swig_wrap_ContainerInt_rubout__SWIG_2(arg1, arg2) +} + +var _wrap_ContainerInt_rubout__SWIG_3 unsafe.Pointer + +func _swig_wrap_ContainerInt_rubout__SWIG_3(base SwigcptrContainerInt, _ int, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_ContainerInt_rubout__SWIG_3, _swig_p) + return +} + +func (arg1 SwigcptrContainerInt) Rubout__SWIG_3(arg2 int, arg3 int) { + _swig_wrap_ContainerInt_rubout__SWIG_3(arg1, arg2, arg3) +} + +var _wrap_ContainerInt_rubout__SWIG_4 unsafe.Pointer + +func _swig_wrap_ContainerInt_rubout__SWIG_4(base SwigcptrContainerInt, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_ContainerInt_rubout__SWIG_4, _swig_p) + return +} + +func (arg1 SwigcptrContainerInt) Rubout__SWIG_4(arg2 int) { + _swig_wrap_ContainerInt_rubout__SWIG_4(arg1, arg2) +} + +func (p SwigcptrContainerInt) Rubout(a ...interface{}) interface{} { + argc := len(a) + if argc == 0 { + return p.Rubout__SWIG_0() + } + if argc == 1 { + if _, ok := a[0].(bool); !ok { + goto check_2 + } + p.Rubout__SWIG_2(a[0].(bool)) + return 0 + } +check_2: + if argc == 1 { + if _, ok := a[0].(int); !ok { + goto check_3 + } + p.Rubout__SWIG_4(a[0].(int)) + return 0 + } +check_3: + if argc == 1 { + p.Rubout__SWIG_1(a[0].(float64)) + return 0 + } + if argc == 2 { + p.Rubout__SWIG_3(a[0].(int), a[1].(int)) + return 0 + } + panic("No match for overloaded function call") +} + +var _wrap_new_ContainerInt unsafe.Pointer + +func _swig_wrap_new_ContainerInt() (base SwigcptrContainerInt) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_ContainerInt, _swig_p) + return +} + +func NewContainerInt() (_swig_ret ContainerInt) { + return _swig_wrap_new_ContainerInt() +} + +var _wrap_delete_ContainerInt unsafe.Pointer + +func _swig_wrap_delete_ContainerInt(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_ContainerInt, _swig_p) + return +} + +func DeleteContainerInt(arg1 ContainerInt) { + _swig_wrap_delete_ContainerInt(arg1.Swigcptr()) +} + +type ContainerInt interface { + Swigcptr() uintptr + SwigIsContainerInt() + Rubout(a ...interface{}) interface{} +} + +type SwigcptrWrapContainerInt uintptr + +func (p SwigcptrWrapContainerInt) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrWrapContainerInt) SwigIsWrapContainerInt() { +} + +var _wrap_new_WrapContainerInt unsafe.Pointer + +func _swig_wrap_new_WrapContainerInt(base uintptr) (_ SwigcptrWrapContainerInt) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_WrapContainerInt, _swig_p) + return +} + +func NewWrapContainerInt(arg1 ContainerInt) (_swig_ret WrapContainerInt) { + return _swig_wrap_new_WrapContainerInt(arg1.Swigcptr()) +} + +var _wrap_WrapContainerInt___deref____SWIG_0 unsafe.Pointer + +func _swig_wrap_WrapContainerInt___deref____SWIG_0(base SwigcptrWrapContainerInt) (_ SwigcptrContainerInt) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_WrapContainerInt___deref____SWIG_0, _swig_p) + return +} + +func (arg1 SwigcptrWrapContainerInt) X__deref____SWIG_0() (_swig_ret ContainerInt) { + return _swig_wrap_WrapContainerInt___deref____SWIG_0(arg1) +} + +var _wrap_WrapContainerInt___deref____SWIG_1 unsafe.Pointer + +func _swig_wrap_WrapContainerInt___deref____SWIG_1(base SwigcptrWrapContainerInt) (_ SwigcptrContainerInt) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_WrapContainerInt___deref____SWIG_1, _swig_p) + return +} + +func (arg1 SwigcptrWrapContainerInt) X__deref____SWIG_1() (_swig_ret ContainerInt) { + return _swig_wrap_WrapContainerInt___deref____SWIG_1(arg1) +} + +func (p SwigcptrWrapContainerInt) X__deref__(a ...interface{}) interface{} { + argc := len(a) + if argc == 0 { + return p.X__deref____SWIG_0() + } + if argc == 0 { + return p.X__deref____SWIG_1() + } + panic("No match for overloaded function call") +} + +var _wrap_delete_WrapContainerInt unsafe.Pointer + +func _swig_wrap_delete_WrapContainerInt(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_WrapContainerInt, _swig_p) + return +} + +func DeleteWrapContainerInt(arg1 WrapContainerInt) { + _swig_wrap_delete_WrapContainerInt(arg1.Swigcptr()) +} + +var _wrap_WrapContainerInt_rubout__SWIG_0 unsafe.Pointer + +func _swig_wrap_WrapContainerInt_rubout__SWIG_0(base SwigcptrWrapContainerInt) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_WrapContainerInt_rubout__SWIG_0, _swig_p) + return +} + +func (arg1 SwigcptrWrapContainerInt) Rubout__SWIG_0() (_swig_ret int) { + return _swig_wrap_WrapContainerInt_rubout__SWIG_0(arg1) +} + +var _wrap_WrapContainerInt_rubout__SWIG_1 unsafe.Pointer + +func _swig_wrap_WrapContainerInt_rubout__SWIG_1(base SwigcptrWrapContainerInt, _ float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_WrapContainerInt_rubout__SWIG_1, _swig_p) + return +} + +func (arg1 SwigcptrWrapContainerInt) Rubout__SWIG_1(arg2 float64) { + _swig_wrap_WrapContainerInt_rubout__SWIG_1(arg1, arg2) +} + +var _wrap_WrapContainerInt_rubout__SWIG_2 unsafe.Pointer + +func _swig_wrap_WrapContainerInt_rubout__SWIG_2(base SwigcptrWrapContainerInt, _ bool) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_WrapContainerInt_rubout__SWIG_2, _swig_p) + return +} + +func (arg1 SwigcptrWrapContainerInt) Rubout__SWIG_2(arg2 bool) { + _swig_wrap_WrapContainerInt_rubout__SWIG_2(arg1, arg2) +} + +var _wrap_WrapContainerInt_rubout__SWIG_3 unsafe.Pointer + +func _swig_wrap_WrapContainerInt_rubout__SWIG_3(base SwigcptrWrapContainerInt, _ int, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_WrapContainerInt_rubout__SWIG_3, _swig_p) + return +} + +func (arg1 SwigcptrWrapContainerInt) Rubout__SWIG_3(arg2 int, arg3 int) { + _swig_wrap_WrapContainerInt_rubout__SWIG_3(arg1, arg2, arg3) +} + +var _wrap_WrapContainerInt_rubout__SWIG_4 unsafe.Pointer + +func _swig_wrap_WrapContainerInt_rubout__SWIG_4(base SwigcptrWrapContainerInt, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_WrapContainerInt_rubout__SWIG_4, _swig_p) + return +} + +func (arg1 SwigcptrWrapContainerInt) Rubout__SWIG_4(arg2 int) { + _swig_wrap_WrapContainerInt_rubout__SWIG_4(arg1, arg2) +} + +func (p SwigcptrWrapContainerInt) Rubout(a ...interface{}) interface{} { + argc := len(a) + if argc == 0 { + return p.Rubout__SWIG_0() + } + if argc == 1 { + if _, ok := a[0].(bool); !ok { + goto check_2 + } + p.Rubout__SWIG_2(a[0].(bool)) + return 0 + } +check_2: + if argc == 1 { + if _, ok := a[0].(int); !ok { + goto check_3 + } + p.Rubout__SWIG_4(a[0].(int)) + return 0 + } +check_3: + if argc == 1 { + p.Rubout__SWIG_1(a[0].(float64)) + return 0 + } + if argc == 2 { + p.Rubout__SWIG_3(a[0].(int), a[1].(int)) + return 0 + } + panic("No match for overloaded function call") +} + +var _wrap_WrapContainerInt_factory__SWIG_0 unsafe.Pointer + +func _swig_wrap_WrapContainerInt_factory__SWIG_0(base SwigcptrWrapContainerInt) (_ SwigcptrContainerInt) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_WrapContainerInt_factory__SWIG_0, _swig_p) + return +} + +func (arg1 SwigcptrWrapContainerInt) Factory__SWIG_0() (_swig_ret ContainerInt) { + return _swig_wrap_WrapContainerInt_factory__SWIG_0(arg1) +} + +var _wrap_WrapContainerInt_factory__SWIG_1 unsafe.Pointer + +func _swig_wrap_WrapContainerInt_factory__SWIG_1(base SwigcptrWrapContainerInt, _ bool) (_ SwigcptrContainerInt) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_WrapContainerInt_factory__SWIG_1, _swig_p) + return +} + +func (arg1 SwigcptrWrapContainerInt) Factory__SWIG_1(arg2 bool) (_swig_ret ContainerInt) { + return _swig_wrap_WrapContainerInt_factory__SWIG_1(arg1, arg2) +} + +func (p SwigcptrWrapContainerInt) Factory(a ...interface{}) ContainerInt { + argc := len(a) + if argc == 0 { + return p.Factory__SWIG_0() + } + if argc == 1 { + return p.Factory__SWIG_1(a[0].(bool)) + } + panic("No match for overloaded function call") +} + +var _wrap_WrapContainerInt_staticstuff unsafe.Pointer + +func _swig_wrap_WrapContainerInt_staticstuff(base SwigcptrWrapContainerInt, _ bool) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_WrapContainerInt_staticstuff, _swig_p) + return +} + +func (arg1 SwigcptrWrapContainerInt) Staticstuff(arg2 bool) { + _swig_wrap_WrapContainerInt_staticstuff(arg1, arg2) +} + +type WrapContainerInt interface { + Swigcptr() uintptr + SwigIsWrapContainerInt() + X__deref__(a ...interface{}) interface{} + Rubout(a ...interface{}) interface{} + Factory(a ...interface{}) ContainerInt + Staticstuff(arg2 bool) +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/smart_pointer_templatemethods.go b/Examples/test-suite/go/smart_pointer_templatemethods.go new file mode 100644 index 000000000..1fe3bd40c --- /dev/null +++ b/Examples/test-suite/go/smart_pointer_templatemethods.go @@ -0,0 +1,431 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../smart_pointer_templatemethods.i + +package smart_pointer_templatemethods + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrInterfaceId uintptr + +func (p SwigcptrInterfaceId) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrInterfaceId) SwigIsInterfaceId() { +} + +var _wrap_new_InterfaceId__SWIG_0 unsafe.Pointer + +func _swig_wrap_new_InterfaceId__SWIG_0(base uint16) (_ SwigcptrInterfaceId) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_InterfaceId__SWIG_0, _swig_p) + return +} + +func NewInterfaceId__SWIG_0(arg1 uint16) (_swig_ret InterfaceId) { + return _swig_wrap_new_InterfaceId__SWIG_0(arg1) +} + +var _wrap_new_InterfaceId__SWIG_1 unsafe.Pointer + +func _swig_wrap_new_InterfaceId__SWIG_1() (base SwigcptrInterfaceId) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_InterfaceId__SWIG_1, _swig_p) + return +} + +func NewInterfaceId__SWIG_1() (_swig_ret InterfaceId) { + return _swig_wrap_new_InterfaceId__SWIG_1() +} + +func NewInterfaceId(a ...interface{}) InterfaceId { + argc := len(a) + if argc == 0 { + return NewInterfaceId__SWIG_1() + } + if argc == 1 { + return NewInterfaceId__SWIG_0(a[0].(uint16)) + } + panic("No match for overloaded function call") +} + +var _wrap_delete_InterfaceId unsafe.Pointer + +func _swig_wrap_delete_InterfaceId(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_InterfaceId, _swig_p) + return +} + +func DeleteInterfaceId(arg1 InterfaceId) { + _swig_wrap_delete_InterfaceId(arg1.Swigcptr()) +} + +type InterfaceId interface { + Swigcptr() uintptr + SwigIsInterfaceId() +} + +type SwigcptrObjct uintptr + +func (p SwigcptrObjct) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrObjct) SwigIsObjct() { +} + +var _wrap_new_Objct unsafe.Pointer + +func _swig_wrap_new_Objct() (base SwigcptrObjct) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Objct, _swig_p) + return +} + +func NewObjct() (_swig_ret Objct) { + return _swig_wrap_new_Objct() +} + +var _wrap_delete_Objct unsafe.Pointer + +func _swig_wrap_delete_Objct(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Objct, _swig_p) + return +} + +func DeleteObjct(arg1 Objct) { + _swig_wrap_delete_Objct(arg1.Swigcptr()) +} + +var _wrap_Objct_DisposeObjct unsafe.Pointer + +func _swig_wrap_Objct_DisposeObjct(base SwigcptrObjct) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Objct_DisposeObjct, _swig_p) + return +} + +func (arg1 SwigcptrObjct) DisposeObjct() { + _swig_wrap_Objct_DisposeObjct(arg1) +} + +var _wrap_Objct_QueryInterfaceObjct unsafe.Pointer + +func _swig_wrap_Objct_QueryInterfaceObjct(base SwigcptrObjct, _ uintptr) (_ SwigcptrPtrObjct) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Objct_QueryInterfaceObjct, _swig_p) + return +} + +func (arg1 SwigcptrObjct) QueryInterfaceObjct(arg2 InterfaceId) (_swig_ret PtrObjct) { + return _swig_wrap_Objct_QueryInterfaceObjct(arg1, arg2.Swigcptr()) +} + +type Objct interface { + Swigcptr() uintptr + SwigIsObjct() + DisposeObjct() + QueryInterfaceObjct(arg2 InterfaceId) (_swig_ret PtrObjct) +} + +type SwigcptrPtrObjct uintptr + +func (p SwigcptrPtrObjct) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrPtrObjct) SwigIsPtrObjct() { +} + +var _wrap_new_PtrObjct unsafe.Pointer + +func _swig_wrap_new_PtrObjct() (base SwigcptrPtrObjct) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_PtrObjct, _swig_p) + return +} + +func NewPtrObjct() (_swig_ret PtrObjct) { + return _swig_wrap_new_PtrObjct() +} + +var _wrap_PtrObjct___deref__ unsafe.Pointer + +func _swig_wrap_PtrObjct___deref__(base SwigcptrPtrObjct) (_ SwigcptrObjct) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_PtrObjct___deref__, _swig_p) + return +} + +func (arg1 SwigcptrPtrObjct) X__deref__() (_swig_ret Objct) { + return _swig_wrap_PtrObjct___deref__(arg1) +} + +var _wrap_delete_PtrObjct unsafe.Pointer + +func _swig_wrap_delete_PtrObjct(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_PtrObjct, _swig_p) + return +} + +func DeletePtrObjct(arg1 PtrObjct) { + _swig_wrap_delete_PtrObjct(arg1.Swigcptr()) +} + +var _wrap_PtrObjct_DisposeObjct unsafe.Pointer + +func _swig_wrap_PtrObjct_DisposeObjct(base SwigcptrPtrObjct) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_PtrObjct_DisposeObjct, _swig_p) + return +} + +func (arg1 SwigcptrPtrObjct) DisposeObjct() { + _swig_wrap_PtrObjct_DisposeObjct(arg1) +} + +var _wrap_PtrObjct_QueryInterfaceObjct unsafe.Pointer + +func _swig_wrap_PtrObjct_QueryInterfaceObjct(base SwigcptrPtrObjct, _ uintptr) (_ SwigcptrPtrObjct) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_PtrObjct_QueryInterfaceObjct, _swig_p) + return +} + +func (arg1 SwigcptrPtrObjct) QueryInterfaceObjct(arg2 InterfaceId) (_swig_ret PtrObjct) { + return _swig_wrap_PtrObjct_QueryInterfaceObjct(arg1, arg2.Swigcptr()) +} + +type PtrObjct interface { + Swigcptr() uintptr + SwigIsPtrObjct() + X__deref__() (_swig_ret Objct) + DisposeObjct() + QueryInterfaceObjct(arg2 InterfaceId) (_swig_ret PtrObjct) +} + +type SwigcptrPtrInt uintptr + +func (p SwigcptrPtrInt) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrPtrInt) SwigIsPtrInt() { +} + +var _wrap_new_PtrInt unsafe.Pointer + +func _swig_wrap_new_PtrInt() (base SwigcptrPtrInt) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_PtrInt, _swig_p) + return +} + +func NewPtrInt() (_swig_ret PtrInt) { + return _swig_wrap_new_PtrInt() +} + +var _wrap_PtrInt___deref__ unsafe.Pointer + +func _swig_wrap_PtrInt___deref__(base SwigcptrPtrInt) (_ *int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_PtrInt___deref__, _swig_p) + return +} + +func (arg1 SwigcptrPtrInt) X__deref__() (_swig_ret *int) { + return _swig_wrap_PtrInt___deref__(arg1) +} + +var _wrap_delete_PtrInt unsafe.Pointer + +func _swig_wrap_delete_PtrInt(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_PtrInt, _swig_p) + return +} + +func DeletePtrInt(arg1 PtrInt) { + _swig_wrap_delete_PtrInt(arg1.Swigcptr()) +} + +type PtrInt interface { + Swigcptr() uintptr + SwigIsPtrInt() + X__deref__() (_swig_ret *int) +} + +type SwigcptrObjektInt uintptr + +func (p SwigcptrObjektInt) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrObjektInt) SwigIsObjektInt() { +} + +var _wrap_new_ObjektInt unsafe.Pointer + +func _swig_wrap_new_ObjektInt() (base SwigcptrObjektInt) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_ObjektInt, _swig_p) + return +} + +func NewObjektInt() (_swig_ret ObjektInt) { + return _swig_wrap_new_ObjektInt() +} + +var _wrap_delete_ObjektInt unsafe.Pointer + +func _swig_wrap_delete_ObjektInt(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_ObjektInt, _swig_p) + return +} + +func DeleteObjektInt(arg1 ObjektInt) { + _swig_wrap_delete_ObjektInt(arg1.Swigcptr()) +} + +var _wrap_ObjektInt_QueryInterface unsafe.Pointer + +func _swig_wrap_ObjektInt_QueryInterface(base SwigcptrObjektInt, _ uintptr) (_ SwigcptrPtrInt) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_ObjektInt_QueryInterface, _swig_p) + return +} + +func (arg1 SwigcptrObjektInt) QueryInterface(arg2 InterfaceId) (_swig_ret PtrInt) { + return _swig_wrap_ObjektInt_QueryInterface(arg1, arg2.Swigcptr()) +} + +var _wrap_ObjektInt_DisposeObjekt unsafe.Pointer + +func _swig_wrap_ObjektInt_DisposeObjekt(base SwigcptrObjektInt) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_ObjektInt_DisposeObjekt, _swig_p) + return +} + +func (arg1 SwigcptrObjektInt) DisposeObjekt() { + _swig_wrap_ObjektInt_DisposeObjekt(arg1) +} + +type ObjektInt interface { + Swigcptr() uintptr + SwigIsObjektInt() + QueryInterface(arg2 InterfaceId) (_swig_ret PtrInt) + DisposeObjekt() +} + +type SwigcptrPtrObjektInt uintptr + +func (p SwigcptrPtrObjektInt) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrPtrObjektInt) SwigIsPtrObjektInt() { +} + +var _wrap_new_PtrObjektInt unsafe.Pointer + +func _swig_wrap_new_PtrObjektInt() (base SwigcptrPtrObjektInt) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_PtrObjektInt, _swig_p) + return +} + +func NewPtrObjektInt() (_swig_ret PtrObjektInt) { + return _swig_wrap_new_PtrObjektInt() +} + +var _wrap_PtrObjektInt___deref__ unsafe.Pointer + +func _swig_wrap_PtrObjektInt___deref__(base SwigcptrPtrObjektInt) (_ SwigcptrObjektInt) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_PtrObjektInt___deref__, _swig_p) + return +} + +func (arg1 SwigcptrPtrObjektInt) X__deref__() (_swig_ret ObjektInt) { + return _swig_wrap_PtrObjektInt___deref__(arg1) +} + +var _wrap_delete_PtrObjektInt unsafe.Pointer + +func _swig_wrap_delete_PtrObjektInt(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_PtrObjektInt, _swig_p) + return +} + +func DeletePtrObjektInt(arg1 PtrObjektInt) { + _swig_wrap_delete_PtrObjektInt(arg1.Swigcptr()) +} + +var _wrap_PtrObjektInt_QueryInterface unsafe.Pointer + +func _swig_wrap_PtrObjektInt_QueryInterface(base SwigcptrPtrObjektInt, _ uintptr) (_ SwigcptrPtrInt) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_PtrObjektInt_QueryInterface, _swig_p) + return +} + +func (arg1 SwigcptrPtrObjektInt) QueryInterface(arg2 InterfaceId) (_swig_ret PtrInt) { + return _swig_wrap_PtrObjektInt_QueryInterface(arg1, arg2.Swigcptr()) +} + +var _wrap_PtrObjektInt_DisposeObjekt unsafe.Pointer + +func _swig_wrap_PtrObjektInt_DisposeObjekt(base SwigcptrPtrObjektInt) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_PtrObjektInt_DisposeObjekt, _swig_p) + return +} + +func (arg1 SwigcptrPtrObjektInt) DisposeObjekt() { + _swig_wrap_PtrObjektInt_DisposeObjekt(arg1) +} + +type PtrObjektInt interface { + Swigcptr() uintptr + SwigIsPtrObjektInt() + X__deref__() (_swig_ret ObjektInt) + QueryInterface(arg2 InterfaceId) (_swig_ret PtrInt) + DisposeObjekt() +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/smart_pointer_templatevariables.go b/Examples/test-suite/go/smart_pointer_templatevariables.go new file mode 100644 index 000000000..463d41287 --- /dev/null +++ b/Examples/test-suite/go/smart_pointer_templatevariables.go @@ -0,0 +1,277 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../smart_pointer_templatevariables.i + +package smart_pointer_templatevariables + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +var _wrap_create unsafe.Pointer + +func _swig_wrap_create(base int, _ int16) (_ SwigcptrDiffImContainer_D) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_create, _swig_p) + return +} + +func Create(arg1 int, arg2 int16) (_swig_ret DiffImContainer_D) { + return _swig_wrap_create(arg1, arg2) +} + +type SwigcptrBasicString uintptr + +func (p SwigcptrBasicString) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrBasicString) SwigIsBasicString() { +} + +var _wrap_BasicString_npos_set unsafe.Pointer + +func _swig_wrap_BasicString_npos_set(base SwigcptrBasicString, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_BasicString_npos_set, _swig_p) + return +} + +func (arg1 SwigcptrBasicString) SetNpos(arg2 int) { + _swig_wrap_BasicString_npos_set(arg1, arg2) +} + +var _wrap_BasicString_npos_get unsafe.Pointer + +func _swig_wrap_BasicString_npos_get(base SwigcptrBasicString) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_BasicString_npos_get, _swig_p) + return +} + +func (arg1 SwigcptrBasicString) GetNpos() (_swig_ret int) { + return _swig_wrap_BasicString_npos_get(arg1) +} + +var _wrap_new_BasicString unsafe.Pointer + +func _swig_wrap_new_BasicString() (base SwigcptrBasicString) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_BasicString, _swig_p) + return +} + +func NewBasicString() (_swig_ret BasicString) { + return _swig_wrap_new_BasicString() +} + +var _wrap_delete_BasicString unsafe.Pointer + +func _swig_wrap_delete_BasicString(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_BasicString, _swig_p) + return +} + +func DeleteBasicString(arg1 BasicString) { + _swig_wrap_delete_BasicString(arg1.Swigcptr()) +} + +type BasicString interface { + Swigcptr() uintptr + SwigIsBasicString() + SetNpos(arg2 int) + GetNpos() (_swig_ret int) +} + +type SwigcptrDiffImContainer_D uintptr + +func (p SwigcptrDiffImContainer_D) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrDiffImContainer_D) SwigIsDiffImContainer_D() { +} + +var _wrap_DiffImContainer_D_id_set unsafe.Pointer + +func _swig_wrap_DiffImContainer_D_id_set(base SwigcptrDiffImContainer_D, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_DiffImContainer_D_id_set, _swig_p) + return +} + +func (arg1 SwigcptrDiffImContainer_D) SetId(arg2 int) { + _swig_wrap_DiffImContainer_D_id_set(arg1, arg2) +} + +var _wrap_DiffImContainer_D_id_get unsafe.Pointer + +func _swig_wrap_DiffImContainer_D_id_get(base SwigcptrDiffImContainer_D) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_DiffImContainer_D_id_get, _swig_p) + return +} + +func (arg1 SwigcptrDiffImContainer_D) GetId() (_swig_ret int) { + return _swig_wrap_DiffImContainer_D_id_get(arg1) +} + +var _wrap_new_DiffImContainer_D unsafe.Pointer + +func _swig_wrap_new_DiffImContainer_D() (base SwigcptrDiffImContainer_D) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_DiffImContainer_D, _swig_p) + return +} + +func NewDiffImContainer_D() (_swig_ret DiffImContainer_D) { + return _swig_wrap_new_DiffImContainer_D() +} + +var _wrap_delete_DiffImContainer_D unsafe.Pointer + +func _swig_wrap_delete_DiffImContainer_D(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_DiffImContainer_D, _swig_p) + return +} + +func DeleteDiffImContainer_D(arg1 DiffImContainer_D) { + _swig_wrap_delete_DiffImContainer_D(arg1.Swigcptr()) +} + +type DiffImContainer_D interface { + Swigcptr() uintptr + SwigIsDiffImContainer_D() + SetId(arg2 int) + GetId() (_swig_ret int) +} + +type SwigcptrDiffImContainerPtr_D uintptr + +func (p SwigcptrDiffImContainerPtr_D) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrDiffImContainerPtr_D) SwigIsDiffImContainerPtr_D() { +} + +var _wrap_new_DiffImContainerPtr_D__SWIG_0 unsafe.Pointer + +func _swig_wrap_new_DiffImContainerPtr_D__SWIG_0(base uintptr) (_ SwigcptrDiffImContainerPtr_D) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_DiffImContainerPtr_D__SWIG_0, _swig_p) + return +} + +func NewDiffImContainerPtr_D__SWIG_0(arg1 DiffImContainer_D) (_swig_ret DiffImContainerPtr_D) { + return _swig_wrap_new_DiffImContainerPtr_D__SWIG_0(arg1.Swigcptr()) +} + +var _wrap_new_DiffImContainerPtr_D__SWIG_1 unsafe.Pointer + +func _swig_wrap_new_DiffImContainerPtr_D__SWIG_1() (base SwigcptrDiffImContainerPtr_D) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_DiffImContainerPtr_D__SWIG_1, _swig_p) + return +} + +func NewDiffImContainerPtr_D__SWIG_1() (_swig_ret DiffImContainerPtr_D) { + return _swig_wrap_new_DiffImContainerPtr_D__SWIG_1() +} + +func NewDiffImContainerPtr_D(a ...interface{}) DiffImContainerPtr_D { + argc := len(a) + if argc == 0 { + return NewDiffImContainerPtr_D__SWIG_1() + } + if argc == 1 { + return NewDiffImContainerPtr_D__SWIG_0(a[0].(DiffImContainer_D)) + } + panic("No match for overloaded function call") +} + +var _wrap_delete_DiffImContainerPtr_D unsafe.Pointer + +func _swig_wrap_delete_DiffImContainerPtr_D(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_DiffImContainerPtr_D, _swig_p) + return +} + +func DeleteDiffImContainerPtr_D(arg1 DiffImContainerPtr_D) { + _swig_wrap_delete_DiffImContainerPtr_D(arg1.Swigcptr()) +} + +var _wrap_DiffImContainerPtr_D___deref__ unsafe.Pointer + +func _swig_wrap_DiffImContainerPtr_D___deref__(base SwigcptrDiffImContainerPtr_D) (_ SwigcptrDiffImContainer_D) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_DiffImContainerPtr_D___deref__, _swig_p) + return +} + +func (arg1 SwigcptrDiffImContainerPtr_D) X__deref__() (_swig_ret DiffImContainer_D) { + return _swig_wrap_DiffImContainerPtr_D___deref__(arg1) +} + +var _wrap_DiffImContainerPtr_D_id_set unsafe.Pointer + +func _swig_wrap_DiffImContainerPtr_D_id_set(base SwigcptrDiffImContainerPtr_D, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_DiffImContainerPtr_D_id_set, _swig_p) + return +} + +func (arg1 SwigcptrDiffImContainerPtr_D) SetId(arg2 int) { + _swig_wrap_DiffImContainerPtr_D_id_set(arg1, arg2) +} + +var _wrap_DiffImContainerPtr_D_id_get unsafe.Pointer + +func _swig_wrap_DiffImContainerPtr_D_id_get(base SwigcptrDiffImContainerPtr_D) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_DiffImContainerPtr_D_id_get, _swig_p) + return +} + +func (arg1 SwigcptrDiffImContainerPtr_D) GetId() (_swig_ret int) { + return _swig_wrap_DiffImContainerPtr_D_id_get(arg1) +} + +type DiffImContainerPtr_D interface { + Swigcptr() uintptr + SwigIsDiffImContainerPtr_D() + X__deref__() (_swig_ret DiffImContainer_D) + SetId(arg2 int) + GetId() (_swig_ret int) +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/smart_pointer_templatevariables_runme b/Examples/test-suite/go/smart_pointer_templatevariables_runme new file mode 100755 index 000000000..e405cf1fd Binary files /dev/null and b/Examples/test-suite/go/smart_pointer_templatevariables_runme differ diff --git a/Examples/test-suite/go/smart_pointer_typedef.go b/Examples/test-suite/go/smart_pointer_typedef.go new file mode 100644 index 000000000..78126f9ec --- /dev/null +++ b/Examples/test-suite/go/smart_pointer_typedef.go @@ -0,0 +1,204 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../smart_pointer_typedef.i + +package smart_pointer_typedef + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrFoo uintptr + +func (p SwigcptrFoo) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrFoo) SwigIsFoo() { +} + +var _wrap_Foo_x_set unsafe.Pointer + +func _swig_wrap_Foo_x_set(base SwigcptrFoo, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_x_set, _swig_p) + return +} + +func (arg1 SwigcptrFoo) SetX(arg2 int) { + _swig_wrap_Foo_x_set(arg1, arg2) +} + +var _wrap_Foo_x_get unsafe.Pointer + +func _swig_wrap_Foo_x_get(base SwigcptrFoo) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_x_get, _swig_p) + return +} + +func (arg1 SwigcptrFoo) GetX() (_swig_ret int) { + return _swig_wrap_Foo_x_get(arg1) +} + +var _wrap_Foo_getx unsafe.Pointer + +func _swig_wrap_Foo_getx(base SwigcptrFoo) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_getx, _swig_p) + return +} + +func (arg1 SwigcptrFoo) Getx() (_swig_ret int) { + return _swig_wrap_Foo_getx(arg1) +} + +var _wrap_new_Foo unsafe.Pointer + +func _swig_wrap_new_Foo() (base SwigcptrFoo) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Foo, _swig_p) + return +} + +func NewFoo() (_swig_ret Foo) { + return _swig_wrap_new_Foo() +} + +var _wrap_delete_Foo unsafe.Pointer + +func _swig_wrap_delete_Foo(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Foo, _swig_p) + return +} + +func DeleteFoo(arg1 Foo) { + _swig_wrap_delete_Foo(arg1.Swigcptr()) +} + +type Foo interface { + Swigcptr() uintptr + SwigIsFoo() + SetX(arg2 int) + GetX() (_swig_ret int) + Getx() (_swig_ret int) +} + +type SwigcptrBar uintptr + +func (p SwigcptrBar) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrBar) SwigIsBar() { +} + +var _wrap_new_Bar unsafe.Pointer + +func _swig_wrap_new_Bar(base uintptr) (_ SwigcptrBar) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Bar, _swig_p) + return +} + +func NewBar(arg1 Foo) (_swig_ret Bar) { + return _swig_wrap_new_Bar(arg1.Swigcptr()) +} + +var _wrap_Bar___deref__ unsafe.Pointer + +func _swig_wrap_Bar___deref__(base SwigcptrBar) (_ SwigcptrFoo) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Bar___deref__, _swig_p) + return +} + +func (arg1 SwigcptrBar) X__deref__() (_swig_ret Foo) { + return _swig_wrap_Bar___deref__(arg1) +} + +var _wrap_delete_Bar unsafe.Pointer + +func _swig_wrap_delete_Bar(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Bar, _swig_p) + return +} + +func DeleteBar(arg1 Bar) { + _swig_wrap_delete_Bar(arg1.Swigcptr()) +} + +var _wrap_Bar_x_set unsafe.Pointer + +func _swig_wrap_Bar_x_set(base SwigcptrBar, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Bar_x_set, _swig_p) + return +} + +func (arg1 SwigcptrBar) SetX(arg2 int) { + _swig_wrap_Bar_x_set(arg1, arg2) +} + +var _wrap_Bar_x_get unsafe.Pointer + +func _swig_wrap_Bar_x_get(base SwigcptrBar) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Bar_x_get, _swig_p) + return +} + +func (arg1 SwigcptrBar) GetX() (_swig_ret int) { + return _swig_wrap_Bar_x_get(arg1) +} + +var _wrap_Bar_getx unsafe.Pointer + +func _swig_wrap_Bar_getx(base SwigcptrBar) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Bar_getx, _swig_p) + return +} + +func (arg1 SwigcptrBar) Getx() (_swig_ret int) { + return _swig_wrap_Bar_getx(arg1) +} + +type Bar interface { + Swigcptr() uintptr + SwigIsBar() + X__deref__() (_swig_ret Foo) + SetX(arg2 int) + GetX() (_swig_ret int) + Getx() (_swig_ret int) +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/smart_pointer_typedef_runme b/Examples/test-suite/go/smart_pointer_typedef_runme new file mode 100755 index 000000000..0e25d343e Binary files /dev/null and b/Examples/test-suite/go/smart_pointer_typedef_runme differ diff --git a/Examples/test-suite/go/sneaky1.go b/Examples/test-suite/go/sneaky1.go new file mode 100644 index 000000000..d2791da28 --- /dev/null +++ b/Examples/test-suite/go/sneaky1.go @@ -0,0 +1,57 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../sneaky1.i + +package sneaky1 + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +var _wrap_add unsafe.Pointer + +func Add(arg1 int, arg2 int) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_add, _swig_p) + return +} +var _wrap_subtract unsafe.Pointer + +func Subtract(arg1 int, arg2 int) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_subtract, _swig_p) + return +} +var _wrap_mul unsafe.Pointer + +func Mul(arg1 int, arg2 int) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_mul, _swig_p) + return +} +var _wrap_divide unsafe.Pointer + +func Divide(arg1 int, arg2 int) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_divide, _swig_p) + return +} + diff --git a/Examples/test-suite/go/sneaky1_runme b/Examples/test-suite/go/sneaky1_runme new file mode 100755 index 000000000..744553450 Binary files /dev/null and b/Examples/test-suite/go/sneaky1_runme differ diff --git a/Examples/test-suite/go/special_variable_macros.go b/Examples/test-suite/go/special_variable_macros.go new file mode 100644 index 000000000..913fdbb8b --- /dev/null +++ b/Examples/test-suite/go/special_variable_macros.go @@ -0,0 +1,414 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../special_variable_macros.i + +package special_variable_macros + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrName uintptr + +func (p SwigcptrName) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrName) SwigIsName() { +} + +var _wrap_new_Name__SWIG_0 unsafe.Pointer + +func _swig_wrap_new_Name__SWIG_0(base string) (_ SwigcptrName) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Name__SWIG_0, _swig_p) + return +} + +func NewName__SWIG_0(arg1 string) (_swig_ret Name) { + return _swig_wrap_new_Name__SWIG_0(arg1) +} + +var _wrap_new_Name__SWIG_1 unsafe.Pointer + +func _swig_wrap_new_Name__SWIG_1() (base SwigcptrName) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Name__SWIG_1, _swig_p) + return +} + +func NewName__SWIG_1() (_swig_ret Name) { + return _swig_wrap_new_Name__SWIG_1() +} + +var _wrap_new_Name__SWIG_2 unsafe.Pointer + +func _swig_wrap_new_Name__SWIG_2(base uintptr) (_ SwigcptrName) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Name__SWIG_2, _swig_p) + return +} + +func NewName__SWIG_2(arg1 Name) (_swig_ret Name) { + return _swig_wrap_new_Name__SWIG_2(arg1.Swigcptr()) +} + +func NewName(a ...interface{}) Name { + argc := len(a) + if argc == 0 { + return NewName__SWIG_1() + } + if argc == 1 { + if _, ok := a[0].(Name); !ok { + goto check_2 + } + return NewName__SWIG_2(a[0].(Name)) + } +check_2: + if argc == 1 { + return NewName__SWIG_0(a[0].(string)) + } + panic("No match for overloaded function call") +} + +var _wrap_delete_Name unsafe.Pointer + +func _swig_wrap_delete_Name(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Name, _swig_p) + return +} + +func DeleteName(arg1 Name) { + _swig_wrap_delete_Name(arg1.Swigcptr()) +} + +var _wrap_Name_getName unsafe.Pointer + +func _swig_wrap_Name_getName(base SwigcptrName) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Name_getName, _swig_p) + return +} + +func (arg1 SwigcptrName) GetName() (_swig_ret string) { + return _swig_wrap_Name_getName(arg1) +} + +var _wrap_Name_getNamePtr unsafe.Pointer + +func _swig_wrap_Name_getNamePtr(base SwigcptrName) (_ SwigcptrName) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Name_getNamePtr, _swig_p) + return +} + +func (arg1 SwigcptrName) GetNamePtr() (_swig_ret Name) { + return _swig_wrap_Name_getNamePtr(arg1) +} + +type Name interface { + Swigcptr() uintptr + SwigIsName() + GetName() (_swig_ret string) + GetNamePtr() (_swig_ret Name) +} + +type SwigcptrNameWrap uintptr + +func (p SwigcptrNameWrap) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrNameWrap) SwigIsNameWrap() { +} + +var _wrap_new_NameWrap__SWIG_0 unsafe.Pointer + +func _swig_wrap_new_NameWrap__SWIG_0(base string) (_ SwigcptrNameWrap) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_NameWrap__SWIG_0, _swig_p) + return +} + +func NewNameWrap__SWIG_0(arg1 string) (_swig_ret NameWrap) { + return _swig_wrap_new_NameWrap__SWIG_0(arg1) +} + +var _wrap_new_NameWrap__SWIG_1 unsafe.Pointer + +func _swig_wrap_new_NameWrap__SWIG_1() (base SwigcptrNameWrap) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_NameWrap__SWIG_1, _swig_p) + return +} + +func NewNameWrap__SWIG_1() (_swig_ret NameWrap) { + return _swig_wrap_new_NameWrap__SWIG_1() +} + +func NewNameWrap(a ...interface{}) NameWrap { + argc := len(a) + if argc == 0 { + return NewNameWrap__SWIG_1() + } + if argc == 1 { + return NewNameWrap__SWIG_0(a[0].(string)) + } + panic("No match for overloaded function call") +} + +var _wrap_NameWrap_getNamePtr unsafe.Pointer + +func _swig_wrap_NameWrap_getNamePtr(base SwigcptrNameWrap) (_ SwigcptrName) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_NameWrap_getNamePtr, _swig_p) + return +} + +func (arg1 SwigcptrNameWrap) GetNamePtr() (_swig_ret Name) { + return _swig_wrap_NameWrap_getNamePtr(arg1) +} + +var _wrap_delete_NameWrap unsafe.Pointer + +func _swig_wrap_delete_NameWrap(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_NameWrap, _swig_p) + return +} + +func DeleteNameWrap(arg1 NameWrap) { + _swig_wrap_delete_NameWrap(arg1.Swigcptr()) +} + +type NameWrap interface { + Swigcptr() uintptr + SwigIsNameWrap() + GetNamePtr() (_swig_ret Name) +} + +var _wrap_testFred unsafe.Pointer + +func _swig_wrap_testFred(base uintptr) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_testFred, _swig_p) + return +} + +func TestFred(arg1 Name) (_swig_ret string) { + return _swig_wrap_testFred(arg1.Swigcptr()) +} + +var _wrap_testJack unsafe.Pointer + +func _swig_wrap_testJack(base uintptr) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_testJack, _swig_p) + return +} + +func TestJack(arg1 Name) (_swig_ret string) { + return _swig_wrap_testJack(arg1.Swigcptr()) +} + +var _wrap_testJill unsafe.Pointer + +func _swig_wrap_testJill(base uintptr) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_testJill, _swig_p) + return +} + +func TestJill(arg1 Name) (_swig_ret string) { + return _swig_wrap_testJill(arg1.Swigcptr()) +} + +var _wrap_testMary unsafe.Pointer + +func _swig_wrap_testMary(base uintptr) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_testMary, _swig_p) + return +} + +func TestMary(arg1 Name) (_swig_ret string) { + return _swig_wrap_testMary(arg1.Swigcptr()) +} + +var _wrap_testJames unsafe.Pointer + +func _swig_wrap_testJames(base uintptr) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_testJames, _swig_p) + return +} + +func TestJames(arg1 Name) (_swig_ret string) { + return _swig_wrap_testJames(arg1.Swigcptr()) +} + +var _wrap_testJim unsafe.Pointer + +func _swig_wrap_testJim(base uintptr) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_testJim, _swig_p) + return +} + +func TestJim(arg1 Name) (_swig_ret string) { + return _swig_wrap_testJim(arg1.Swigcptr()) +} + +var _wrap_testJohn unsafe.Pointer + +func _swig_wrap_testJohn(base uintptr) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_testJohn, _swig_p) + return +} + +func TestJohn(arg1 PairIntBool) (_swig_ret int) { + return _swig_wrap_testJohn(arg1.Swigcptr()) +} + +type SwigcptrPairIntBool uintptr + +func (p SwigcptrPairIntBool) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrPairIntBool) SwigIsPairIntBool() { +} + +var _wrap_new_PairIntBool__SWIG_0 unsafe.Pointer + +func _swig_wrap_new_PairIntBool__SWIG_0(base int, _ bool) (_ SwigcptrPairIntBool) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_PairIntBool__SWIG_0, _swig_p) + return +} + +func NewPairIntBool__SWIG_0(arg1 int, arg2 bool) (_swig_ret PairIntBool) { + return _swig_wrap_new_PairIntBool__SWIG_0(arg1, arg2) +} + +var _wrap_new_PairIntBool__SWIG_1 unsafe.Pointer + +func _swig_wrap_new_PairIntBool__SWIG_1() (base SwigcptrPairIntBool) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_PairIntBool__SWIG_1, _swig_p) + return +} + +func NewPairIntBool__SWIG_1() (_swig_ret PairIntBool) { + return _swig_wrap_new_PairIntBool__SWIG_1() +} + +func NewPairIntBool(a ...interface{}) PairIntBool { + argc := len(a) + if argc == 0 { + return NewPairIntBool__SWIG_1() + } + if argc == 2 { + return NewPairIntBool__SWIG_0(a[0].(int), a[1].(bool)) + } + panic("No match for overloaded function call") +} + +var _wrap_PairIntBool_first_set unsafe.Pointer + +func _swig_wrap_PairIntBool_first_set(base SwigcptrPairIntBool, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_PairIntBool_first_set, _swig_p) + return +} + +func (arg1 SwigcptrPairIntBool) SetFirst(arg2 int) { + _swig_wrap_PairIntBool_first_set(arg1, arg2) +} + +var _wrap_PairIntBool_first_get unsafe.Pointer + +func _swig_wrap_PairIntBool_first_get(base SwigcptrPairIntBool) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_PairIntBool_first_get, _swig_p) + return +} + +func (arg1 SwigcptrPairIntBool) GetFirst() (_swig_ret int) { + return _swig_wrap_PairIntBool_first_get(arg1) +} + +var _wrap_PairIntBool_second_set unsafe.Pointer + +func _swig_wrap_PairIntBool_second_set(base SwigcptrPairIntBool, _ bool) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_PairIntBool_second_set, _swig_p) + return +} + +func (arg1 SwigcptrPairIntBool) SetSecond(arg2 bool) { + _swig_wrap_PairIntBool_second_set(arg1, arg2) +} + +var _wrap_PairIntBool_second_get unsafe.Pointer + +func _swig_wrap_PairIntBool_second_get(base SwigcptrPairIntBool) (_ bool) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_PairIntBool_second_get, _swig_p) + return +} + +func (arg1 SwigcptrPairIntBool) GetSecond() (_swig_ret bool) { + return _swig_wrap_PairIntBool_second_get(arg1) +} + +var _wrap_delete_PairIntBool unsafe.Pointer + +func _swig_wrap_delete_PairIntBool(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_PairIntBool, _swig_p) + return +} + +func DeletePairIntBool(arg1 PairIntBool) { + _swig_wrap_delete_PairIntBool(arg1.Swigcptr()) +} + +type PairIntBool interface { + Swigcptr() uintptr + SwigIsPairIntBool() + SetFirst(arg2 int) + GetFirst() (_swig_ret int) + SetSecond(arg2 bool) + GetSecond() (_swig_ret bool) +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/special_variable_macros_runme b/Examples/test-suite/go/special_variable_macros_runme new file mode 100755 index 000000000..397403867 Binary files /dev/null and b/Examples/test-suite/go/special_variable_macros_runme differ diff --git a/Examples/test-suite/go/special_variables.go b/Examples/test-suite/go/special_variables.go new file mode 100644 index 000000000..881ae38d6 --- /dev/null +++ b/Examples/test-suite/go/special_variables.go @@ -0,0 +1,621 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../special_variables.i + +package special_variables + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +var _wrap_testmethod unsafe.Pointer + +func _swig_wrap_testmethod(base int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_testmethod, _swig_p) + return +} + +func Testmethod(arg1 int) { + _swig_wrap_testmethod(arg1) +} + +type SwigcptrKKK uintptr + +func (p SwigcptrKKK) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrKKK) SwigIsKKK() { +} + +var _wrap_KKK_testmethod unsafe.Pointer + +func _swig_wrap_KKK_testmethod(base SwigcptrKKK, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_KKK_testmethod, _swig_p) + return +} + +func (arg1 SwigcptrKKK) Testmethod(arg2 int) { + _swig_wrap_KKK_testmethod(arg1, arg2) +} + +var _wrap_KKK_teststaticmethod unsafe.Pointer + +func _swig_wrap_KKK_teststaticmethod(base int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_KKK_teststaticmethod, _swig_p) + return +} + +func KKKTeststaticmethod(arg1 int) { + _swig_wrap_KKK_teststaticmethod(arg1) +} + +var _wrap_new_KKK unsafe.Pointer + +func _swig_wrap_new_KKK() (base SwigcptrKKK) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_KKK, _swig_p) + return +} + +func NewKKK() (_swig_ret KKK) { + return _swig_wrap_new_KKK() +} + +var _wrap_delete_KKK unsafe.Pointer + +func _swig_wrap_delete_KKK(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_KKK, _swig_p) + return +} + +func DeleteKKK(arg1 KKK) { + _swig_wrap_delete_KKK(arg1.Swigcptr()) +} + +type KKK interface { + Swigcptr() uintptr + SwigIsKKK() + Testmethod(arg2 int) +} + +var _wrap_ExceptionVars unsafe.Pointer + +func ExceptionVars(arg1 float64, arg2 float64) (_swig_ret string) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_ExceptionVars, _swig_p) + return +} +var _wrap_overloadedmethod__SWIG_0 unsafe.Pointer + +func Overloadedmethod__SWIG_0(arg1 float64) (_swig_ret string) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_overloadedmethod__SWIG_0, _swig_p) + return +} +var _wrap_overloadedmethod__SWIG_1 unsafe.Pointer + +func Overloadedmethod__SWIG_1() (_swig_ret string) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_overloadedmethod__SWIG_1, _swig_p) + return +} +func Overloadedmethod(a ...interface{}) string { + argc := len(a) + if argc == 0 { + return Overloadedmethod__SWIG_1() + } + if argc == 1 { + return Overloadedmethod__SWIG_0(a[0].(float64)) + } + panic("No match for overloaded function call") +} + +var _wrap_declaration_set unsafe.Pointer + +func _swig_wrap_declaration_set(base string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_declaration_set, _swig_p) + return +} + +func SetDeclaration(arg1 string) { + _swig_wrap_declaration_set(arg1) +} + +var _wrap_declaration_get unsafe.Pointer + +func GetDeclaration() (_swig_ret string) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_declaration_get, _swig_p) + return +} +type SwigcptrABC uintptr + +func (p SwigcptrABC) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrABC) SwigIsABC() { +} + +var _wrap_new_ABC__SWIG_0 unsafe.Pointer + +func _swig_wrap_new_ABC__SWIG_0(base int, _ float64) (_ SwigcptrABC) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_ABC__SWIG_0, _swig_p) + return +} + +func NewABC__SWIG_0(arg1 int, arg2 float64) (_swig_ret ABC) { + return _swig_wrap_new_ABC__SWIG_0(arg1, arg2) +} + +var _wrap_new_ABC__SWIG_1 unsafe.Pointer + +func _swig_wrap_new_ABC__SWIG_1() (base SwigcptrABC) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_ABC__SWIG_1, _swig_p) + return +} + +func NewABC__SWIG_1() (_swig_ret ABC) { + return _swig_wrap_new_ABC__SWIG_1() +} + +func NewABC(a ...interface{}) ABC { + argc := len(a) + if argc == 0 { + return NewABC__SWIG_1() + } + if argc == 2 { + return NewABC__SWIG_0(a[0].(int), a[1].(float64)) + } + panic("No match for overloaded function call") +} + +var _wrap_ABC_staticmethod unsafe.Pointer + +func ABCStaticmethod(arg1 int, arg2 bool) (_swig_ret *int16) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_ABC_staticmethod, _swig_p) + return +} +var _wrap_ABC_instancemethod__SWIG_0 unsafe.Pointer + +func _swig_wrap_ABC_instancemethod__SWIG_0(base SwigcptrABC, _ int, _ bool) (_ *int16) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_ABC_instancemethod__SWIG_0, _swig_p) + return +} + +func (arg1 SwigcptrABC) Instancemethod__SWIG_0(arg2 int, arg3 bool) (_swig_ret *int16) { + return _swig_wrap_ABC_instancemethod__SWIG_0(arg1, arg2, arg3) +} + +var _wrap_ABC_instancemethod__SWIG_1 unsafe.Pointer + +func _swig_wrap_ABC_instancemethod__SWIG_1(base SwigcptrABC, _ int) (_ *int16) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_ABC_instancemethod__SWIG_1, _swig_p) + return +} + +func (arg1 SwigcptrABC) Instancemethod__SWIG_1(arg2 int) (_swig_ret *int16) { + return _swig_wrap_ABC_instancemethod__SWIG_1(arg1, arg2) +} + +func (p SwigcptrABC) Instancemethod(a ...interface{}) *int16 { + argc := len(a) + if argc == 1 { + return p.Instancemethod__SWIG_1(a[0].(int)) + } + if argc == 2 { + return p.Instancemethod__SWIG_0(a[0].(int), a[1].(bool)) + } + panic("No match for overloaded function call") +} + +var _wrap_ABC_constmethod unsafe.Pointer + +func _swig_wrap_ABC_constmethod(base SwigcptrABC, _ int) (_ *int16) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_ABC_constmethod, _swig_p) + return +} + +func (arg1 SwigcptrABC) Constmethod(arg2 int) (_swig_ret *int16) { + return _swig_wrap_ABC_constmethod(arg1, arg2) +} + +var _wrap_delete_ABC unsafe.Pointer + +func _swig_wrap_delete_ABC(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_ABC, _swig_p) + return +} + +func DeleteABC(arg1 ABC) { + _swig_wrap_delete_ABC(arg1.Swigcptr()) +} + +type ABC interface { + Swigcptr() uintptr + SwigIsABC() + Instancemethod(a ...interface{}) *int16 + Constmethod(arg2 int) (_swig_ret *int16) +} + +var _wrap_globtemplate unsafe.Pointer + +func _swig_wrap_globtemplate(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_globtemplate, _swig_p) + return +} + +func Globtemplate(arg1 TemplateABC) { + _swig_wrap_globtemplate(arg1.Swigcptr()) +} + +type SwigcptrTemplateABC uintptr + +func (p SwigcptrTemplateABC) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrTemplateABC) SwigIsTemplateABC() { +} + +var _wrap_TemplateABC_tmethod unsafe.Pointer + +func _swig_wrap_TemplateABC_tmethod(base SwigcptrTemplateABC, _ uintptr) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_TemplateABC_tmethod, _swig_p) + return +} + +func (arg1 SwigcptrTemplateABC) Tmethod(arg2 ABC) (_swig_ret string) { + return _swig_wrap_TemplateABC_tmethod(arg1, arg2.Swigcptr()) +} + +var _wrap_new_TemplateABC unsafe.Pointer + +func _swig_wrap_new_TemplateABC() (base SwigcptrTemplateABC) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_TemplateABC, _swig_p) + return +} + +func NewTemplateABC() (_swig_ret TemplateABC) { + return _swig_wrap_new_TemplateABC() +} + +var _wrap_delete_TemplateABC unsafe.Pointer + +func _swig_wrap_delete_TemplateABC(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_TemplateABC, _swig_p) + return +} + +func DeleteTemplateABC(arg1 TemplateABC) { + _swig_wrap_delete_TemplateABC(arg1.Swigcptr()) +} + +type TemplateABC interface { + Swigcptr() uintptr + SwigIsTemplateABC() + Tmethod(arg2 ABC) (_swig_ret string) +} + +var _wrap_director_testmethod unsafe.Pointer + +func _swig_wrap_director_testmethod(base int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_director_testmethod, _swig_p) + return +} + +func Director_testmethod(arg1 int) { + _swig_wrap_director_testmethod(arg1) +} + +type _swig_DirectorDirectorTest struct { + SwigcptrDirectorTest + v interface{} +} + +func (p *_swig_DirectorDirectorTest) Swigcptr() uintptr { + return p.SwigcptrDirectorTest.Swigcptr() +} + +func (p *_swig_DirectorDirectorTest) SwigIsDirectorTest() { +} + +func (p *_swig_DirectorDirectorTest) DirectorInterface() interface{} { + return p.v +} + +var _wrap__swig_NewDirectorDirectorTestDirectorTest unsafe.Pointer + +func _swig_NewDirectorDirectorTestDirectorTest(_swig_director *_swig_DirectorDirectorTest) (_swig_ret SwigcptrDirectorTest) { + _swig_p := uintptr(unsafe.Pointer(&_swig_director)) + _cgo_runtime_cgocall(_wrap__swig_NewDirectorDirectorTestDirectorTest, _swig_p) + return +} + +func NewDirectorDirectorTest(v interface{}) DirectorTest { + p := &_swig_DirectorDirectorTest{0, v} + p.SwigcptrDirectorTest = _swig_NewDirectorDirectorTestDirectorTest(p) + return p +} + +type _swig_DirectorInterfaceDirectorTestDirector_testmethod interface { + Director_testmethod(int) +} + +var _wrap__swig_DirectorDirectorTest_upcall_Director_testmethod unsafe.Pointer + +func _swig_wrap__swig_DirectorDirectorTest_upcall_Director_testmethod(_swig_ptr SwigcptrDirectorTest, _ int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) + _cgo_runtime_cgocall(_wrap__swig_DirectorDirectorTest_upcall_Director_testmethod, _swig_p) + return +} + +func (swig_p *_swig_DirectorDirectorTest) Director_testmethod(i int) { + if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceDirectorTestDirector_testmethod); swig_ok { + swig_g.Director_testmethod(i) + return + } + _swig_wrap__swig_DirectorDirectorTest_upcall_Director_testmethod(swig_p.SwigcptrDirectorTest, i) +} + +func DirectorDirectorTestDirector_testmethod(p DirectorTest, arg2 int) { + _swig_wrap__swig_DirectorDirectorTest_upcall_Director_testmethod(p.(*_swig_DirectorDirectorTest).SwigcptrDirectorTest, arg2) +} + +func Swig_DirectorDirectorTest_callback_director_testmethod(p *_swig_DirectorDirectorTest, arg2 int) { + p.Director_testmethod(arg2) +} + +var _wrap_DeleteDirectorDirectorTest unsafe.Pointer + +func _swig_wrap_DeleteDirectorDirectorTest(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_DeleteDirectorDirectorTest, _swig_p) + return +} + +func DeleteDirectorDirectorTest(arg1 DirectorTest) { + _swig_wrap_DeleteDirectorDirectorTest(arg1.Swigcptr()) +} + +func Swiggo_DeleteDirector_DirectorTest(p *_swig_DirectorDirectorTest) { + p.SwigcptrDirectorTest = 0 +} + +type SwigcptrDirectorTest uintptr + +func (p SwigcptrDirectorTest) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrDirectorTest) SwigIsDirectorTest() { +} + +func (p SwigcptrDirectorTest) DirectorInterface() interface{} { + return nil +} + +var _wrap_DirectorTest_director_testmethod unsafe.Pointer + +func _swig_wrap_DirectorTest_director_testmethod(base SwigcptrDirectorTest, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_DirectorTest_director_testmethod, _swig_p) + return +} + +func (arg1 SwigcptrDirectorTest) Director_testmethod(arg2 int) { + _swig_wrap_DirectorTest_director_testmethod(arg1, arg2) +} + +var _wrap_delete_DirectorTest unsafe.Pointer + +func _swig_wrap_delete_DirectorTest(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_DirectorTest, _swig_p) + return +} + +func DeleteDirectorTest(arg1 DirectorTest) { + _swig_wrap_delete_DirectorTest(arg1.Swigcptr()) +} + +var _wrap_new_DirectorTest unsafe.Pointer + +func _swig_wrap_new_DirectorTest() (base SwigcptrDirectorTest) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_DirectorTest, _swig_p) + return +} + +func NewDirectorTest() (_swig_ret DirectorTest) { + return _swig_wrap_new_DirectorTest() +} + +type DirectorTest interface { + Swigcptr() uintptr + SwigIsDirectorTest() + DirectorInterface() interface{} + Director_testmethod(arg2 int) +} + +type SwigcptrDEFNewName uintptr + +func (p SwigcptrDEFNewName) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrDEFNewName) SwigIsDEFNewName() { +} + +var _wrap_DEFNewName_instance_def unsafe.Pointer + +func _swig_wrap_DEFNewName_instance_def(base SwigcptrDEFNewName) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_DEFNewName_instance_def, _swig_p) + return +} + +func (arg1 SwigcptrDEFNewName) Instance_def() { + _swig_wrap_DEFNewName_instance_def(arg1) +} + +var _wrap_DEFNewName_static_def unsafe.Pointer + +func _swig_wrap_DEFNewName_static_def() { + var _swig_p uintptr + _cgo_runtime_cgocall(_wrap_DEFNewName_static_def, _swig_p) + return +} + +func DEFNewNameStatic_def() { + _swig_wrap_DEFNewName_static_def() +} + +var _wrap_new_DEFNewName unsafe.Pointer + +func _swig_wrap_new_DEFNewName() (base SwigcptrDEFNewName) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_DEFNewName, _swig_p) + return +} + +func NewDEFNewName() (_swig_ret DEFNewName) { + return _swig_wrap_new_DEFNewName() +} + +var _wrap_delete_DEFNewName unsafe.Pointer + +func _swig_wrap_delete_DEFNewName(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_DEFNewName, _swig_p) + return +} + +func DeleteDEFNewName(arg1 DEFNewName) { + _swig_wrap_delete_DEFNewName(arg1.Swigcptr()) +} + +var _wrap_DEFNewName_staticmethod unsafe.Pointer + +func DEFNewNameStaticmethod(arg1 int, arg2 bool) (_swig_ret *int16) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_DEFNewName_staticmethod, _swig_p) + return +} +var _wrap_DEFNewName_instancemethod__SWIG_0 unsafe.Pointer + +func _swig_wrap_DEFNewName_instancemethod__SWIG_0(base SwigcptrDEFNewName, _ int, _ bool) (_ *int16) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_DEFNewName_instancemethod__SWIG_0, _swig_p) + return +} + +func (_swig_base SwigcptrDEFNewName) Instancemethod__SWIG_0(arg1 int, arg2 bool) (_swig_ret *int16) { + return _swig_wrap_DEFNewName_instancemethod__SWIG_0(_swig_base, arg1, arg2) +} + +var _wrap_DEFNewName_instancemethod__SWIG_1 unsafe.Pointer + +func _swig_wrap_DEFNewName_instancemethod__SWIG_1(base SwigcptrDEFNewName, _ int) (_ *int16) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_DEFNewName_instancemethod__SWIG_1, _swig_p) + return +} + +func (_swig_base SwigcptrDEFNewName) Instancemethod__SWIG_1(arg1 int) (_swig_ret *int16) { + return _swig_wrap_DEFNewName_instancemethod__SWIG_1(_swig_base, arg1) +} + +func (p SwigcptrDEFNewName) Instancemethod(a ...interface{}) *int16 { + argc := len(a) + if argc == 1 { + return p.Instancemethod__SWIG_1(a[0].(int)) + } + if argc == 2 { + return p.Instancemethod__SWIG_0(a[0].(int), a[1].(bool)) + } + panic("No match for overloaded function call") +} + +var _wrap_DEFNewName_constmethod unsafe.Pointer + +func _swig_wrap_DEFNewName_constmethod(base SwigcptrDEFNewName, _ int) (_ *int16) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_DEFNewName_constmethod, _swig_p) + return +} + +func (_swig_base SwigcptrDEFNewName) Constmethod(arg1 int) (_swig_ret *int16) { + return _swig_wrap_DEFNewName_constmethod(_swig_base, arg1) +} + +func (p SwigcptrDEFNewName) SwigIsABC() { +} + +func (p SwigcptrDEFNewName) SwigGetABC() ABC { + return SwigcptrABC(p.Swigcptr()) +} + +type DEFNewName interface { + Swigcptr() uintptr + SwigIsDEFNewName() + Instance_def() + Instancemethod(a ...interface{}) *int16 + Constmethod(arg1 int) (_swig_ret *int16) + SwigIsABC() + SwigGetABC() ABC +} + + +type SwigcptrSwigDirector_DirectorTest uintptr +type SwigDirector_DirectorTest interface { + Swigcptr() uintptr; +} +func (p SwigcptrSwigDirector_DirectorTest) Swigcptr() uintptr { + return uintptr(p) +} + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/special_variables_wrap.h b/Examples/test-suite/go/special_variables_wrap.h new file mode 100644 index 000000000..09f9a0ced --- /dev/null +++ b/Examples/test-suite/go/special_variables_wrap.h @@ -0,0 +1,29 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../special_variables.i + +#ifndef SWIG_special_variables_WRAP_H_ +#define SWIG_special_variables_WRAP_H_ + +class SwigDirector_DirectorTest : public DirectorTest +{ + public: + SwigDirector_DirectorTest(void *swig_p); + void _swig_upcall_director_testmethod(int i) { + DirectorTest::director_testmethod(i); + } + virtual void director_testmethod(int i); + virtual ~SwigDirector_DirectorTest(); + private: + void *go_val; +}; + +#endif diff --git a/Examples/test-suite/go/static_array_member.go b/Examples/test-suite/go/static_array_member.go new file mode 100644 index 000000000..ecb5b1015 --- /dev/null +++ b/Examples/test-suite/go/static_array_member.go @@ -0,0 +1,75 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../static_array_member.i + +package static_array_member + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrRB uintptr + +func (p SwigcptrRB) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrRB) SwigIsRB() { +} + +var _wrap_new_RB unsafe.Pointer + +func _swig_wrap_new_RB() (base SwigcptrRB) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_RB, _swig_p) + return +} + +func NewRB() (_swig_ret RB) { + return _swig_wrap_new_RB() +} + +var _wrap_delete_RB unsafe.Pointer + +func _swig_wrap_delete_RB(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_RB, _swig_p) + return +} + +func DeleteRB(arg1 RB) { + _swig_wrap_delete_RB(arg1.Swigcptr()) +} + +type RB interface { + Swigcptr() uintptr + SwigIsRB() +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/static_const_member.go b/Examples/test-suite/go/static_const_member.go new file mode 100644 index 000000000..4be143258 --- /dev/null +++ b/Examples/test-suite/go/static_const_member.go @@ -0,0 +1,107 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../static_const_member.i + +package static_const_member + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrX uintptr + +func (p SwigcptrX) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrX) SwigIsX() { +} + +var _wrap_X_PN_X unsafe.Pointer + +func _swig_getX_X_PN_X() (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_X_PN_X, _swig_p) + return +} +var XPN int = _swig_getX_X_PN_X() +var _wrap_X_CN_X unsafe.Pointer + +func _swig_getX_X_CN_X() (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_X_CN_X, _swig_p) + return +} +var XCN int = _swig_getX_X_CN_X() +var _wrap_X_EN_X unsafe.Pointer + +func _swig_getX_X_EN_X() (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_X_EN_X, _swig_p) + return +} +var XEN int = _swig_getX_X_EN_X() +var _wrap_X_CHARTEST_X unsafe.Pointer + +func _swig_getX_X_CHARTEST_X() (_swig_ret byte) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_X_CHARTEST_X, _swig_p) + return +} +var XCHARTEST byte = _swig_getX_X_CHARTEST_X() +var _wrap_new_X unsafe.Pointer + +func _swig_wrap_new_X() (base SwigcptrX) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_X, _swig_p) + return +} + +func NewX() (_swig_ret X) { + return _swig_wrap_new_X() +} + +var _wrap_delete_X unsafe.Pointer + +func _swig_wrap_delete_X(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_X, _swig_p) + return +} + +func DeleteX(arg1 X) { + _swig_wrap_delete_X(arg1.Swigcptr()) +} + +type X interface { + Swigcptr() uintptr + SwigIsX() +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/static_const_member_2.go b/Examples/test-suite/go/static_const_member_2.go new file mode 100644 index 000000000..af4e91a6d --- /dev/null +++ b/Examples/test-suite/go/static_const_member_2.go @@ -0,0 +1,283 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../static_const_member_2.i + +package static_const_member_2 + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrCavityPackFlags uintptr + +func (p SwigcptrCavityPackFlags) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrCavityPackFlags) SwigIsCavityPackFlags() { +} + +var _wrap_CavityPackFlags_forward_field_CavityPackFlags unsafe.Pointer + +func _swig_getCavityPackFlags_CavityPackFlags_forward_field_CavityPackFlags() (_swig_ret uint) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_CavityPackFlags_forward_field_CavityPackFlags, _swig_p) + return +} +var CavityPackFlagsForward_field uint = _swig_getCavityPackFlags_CavityPackFlags_forward_field_CavityPackFlags() +var _wrap_CavityPackFlags_backward_field_CavityPackFlags unsafe.Pointer + +func _swig_getCavityPackFlags_CavityPackFlags_backward_field_CavityPackFlags() (_swig_ret uint) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_CavityPackFlags_backward_field_CavityPackFlags, _swig_p) + return +} +var CavityPackFlagsBackward_field uint = _swig_getCavityPackFlags_CavityPackFlags_backward_field_CavityPackFlags() +var _wrap_CavityPackFlags_cavity_flags_get unsafe.Pointer + +func GetCavityPackFlagsCavity_flags() (_swig_ret uint) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_CavityPackFlags_cavity_flags_get, _swig_p) + return +} +var _wrap_CavityPackFlags_flags_set unsafe.Pointer + +func _swig_wrap_CavityPackFlags_flags_set(base uint) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_CavityPackFlags_flags_set, _swig_p) + return +} + +func SetCavityPackFlagsFlags(arg1 uint) { + _swig_wrap_CavityPackFlags_flags_set(arg1) +} + +var _wrap_CavityPackFlags_flags_get unsafe.Pointer + +func GetCavityPackFlagsFlags() (_swig_ret uint) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_CavityPackFlags_flags_get, _swig_p) + return +} +var _wrap_CavityPackFlags_reftest_get unsafe.Pointer + +func GetCavityPackFlagsReftest() (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_CavityPackFlags_reftest_get, _swig_p) + return +} +var _wrap_new_CavityPackFlags unsafe.Pointer + +func _swig_wrap_new_CavityPackFlags() (base SwigcptrCavityPackFlags) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_CavityPackFlags, _swig_p) + return +} + +func NewCavityPackFlags() (_swig_ret CavityPackFlags) { + return _swig_wrap_new_CavityPackFlags() +} + +var _wrap_delete_CavityPackFlags unsafe.Pointer + +func _swig_wrap_delete_CavityPackFlags(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_CavityPackFlags, _swig_p) + return +} + +func DeleteCavityPackFlags(arg1 CavityPackFlags) { + _swig_wrap_delete_CavityPackFlags(arg1.Swigcptr()) +} + +type CavityPackFlags interface { + Swigcptr() uintptr + SwigIsCavityPackFlags() +} + +type SwigcptrTest_int uintptr + +func (p SwigcptrTest_int) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrTest_int) SwigIsTest_int() { +} + +var _wrap_LeftIndex_Test_int unsafe.Pointer + +func _swig_getTest_int_LeftIndex_Test_int() (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_LeftIndex_Test_int, _swig_p) + return +} +var Test_intLeftIndex int = _swig_getTest_int_LeftIndex_Test_int() +var _wrap_RightIndex_Test_int unsafe.Pointer + +func _swig_getTest_int_RightIndex_Test_int() (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_RightIndex_Test_int, _swig_p) + return +} +var Test_intRightIndex int = _swig_getTest_int_RightIndex_Test_int() +var _wrap_Test_int_current_profile_Test_int unsafe.Pointer + +func _swig_getTest_int_Test_int_current_profile_Test_int() (_swig_ret uint) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_Test_int_current_profile_Test_int, _swig_p) + return +} +var Test_intCurrent_profile uint = _swig_getTest_int_Test_int_current_profile_Test_int() +var _wrap_new_Test_int unsafe.Pointer + +func _swig_wrap_new_Test_int() (base SwigcptrTest_int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Test_int, _swig_p) + return +} + +func NewTest_int() (_swig_ret Test_int) { + return _swig_wrap_new_Test_int() +} + +var _wrap_delete_Test_int unsafe.Pointer + +func _swig_wrap_delete_Test_int(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Test_int, _swig_p) + return +} + +func DeleteTest_int(arg1 Test_int) { + _swig_wrap_delete_Test_int(arg1.Swigcptr()) +} + +func (p SwigcptrTest_int) SwigIsCavityPackFlags() { +} + +func (p SwigcptrTest_int) SwigGetCavityPackFlags() CavityPackFlags { + return SwigcptrCavityPackFlags(p.Swigcptr()) +} + +type Test_int interface { + Swigcptr() uintptr + SwigIsTest_int() + SwigIsCavityPackFlags() + SwigGetCavityPackFlags() CavityPackFlags +} + +type SwigcptrFoo uintptr + +func (p SwigcptrFoo) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrFoo) SwigIsFoo() { +} + +var _wrap_Foo_val_set unsafe.Pointer + +func _swig_wrap_Foo_val_set(base SwigcptrFoo, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_val_set, _swig_p) + return +} + +func (arg1 SwigcptrFoo) SetVal(arg2 int) { + _swig_wrap_Foo_val_set(arg1, arg2) +} + +var _wrap_Foo_val_get unsafe.Pointer + +func _swig_wrap_Foo_val_get(base SwigcptrFoo) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_val_get, _swig_p) + return +} + +func (arg1 SwigcptrFoo) GetVal() (_swig_ret int) { + return _swig_wrap_Foo_val_get(arg1) +} + +var _wrap_new_Foo unsafe.Pointer + +func _swig_wrap_new_Foo(base int) (_ SwigcptrFoo) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Foo, _swig_p) + return +} + +func NewFoo(arg1 int) (_swig_ret Foo) { + return _swig_wrap_new_Foo(arg1) +} + +var _wrap_Foo_BAR_get unsafe.Pointer + +func _swig_wrap_Foo_BAR_get() (base SwigcptrFoo) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_BAR_get, _swig_p) + return +} + +func GetFooBAR() (_swig_ret Foo) { + return _swig_wrap_Foo_BAR_get() +} + +var _wrap_Foo_BAZ_get unsafe.Pointer + +func _swig_wrap_Foo_BAZ_get() (base SwigcptrFoo) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_BAZ_get, _swig_p) + return +} + +func GetFooBAZ() (_swig_ret Foo) { + return _swig_wrap_Foo_BAZ_get() +} + +var _wrap_delete_Foo unsafe.Pointer + +func _swig_wrap_delete_Foo(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Foo, _swig_p) + return +} + +func DeleteFoo(arg1 Foo) { + _swig_wrap_delete_Foo(arg1.Swigcptr()) +} + +type Foo interface { + Swigcptr() uintptr + SwigIsFoo() + SetVal(arg2 int) + GetVal() (_swig_ret int) +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/static_const_member_2_runme b/Examples/test-suite/go/static_const_member_2_runme new file mode 100755 index 000000000..33dea6a0e Binary files /dev/null and b/Examples/test-suite/go/static_const_member_2_runme differ diff --git a/Examples/test-suite/go/string_simple.go b/Examples/test-suite/go/string_simple.go new file mode 100644 index 000000000..eccde2e30 --- /dev/null +++ b/Examples/test-suite/go/string_simple.go @@ -0,0 +1,36 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../string_simple.i + +package string_simple + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +var _wrap_copy_string unsafe.Pointer + +func Copy_string(arg1 string) (_swig_ret string) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_copy_string, _swig_p) + return +} + diff --git a/Examples/test-suite/go/struct_initialization.go b/Examples/test-suite/go/struct_initialization.go new file mode 100644 index 000000000..152d7c581 --- /dev/null +++ b/Examples/test-suite/go/struct_initialization.go @@ -0,0 +1,709 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../struct_initialization.i + +package struct_initialization + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrStructA uintptr + +func (p SwigcptrStructA) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrStructA) SwigIsStructA() { +} + +var _wrap_StructA_x_set unsafe.Pointer + +func _swig_wrap_StructA_x_set(base SwigcptrStructA, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_StructA_x_set, _swig_p) + return +} + +func (arg1 SwigcptrStructA) SetX(arg2 int) { + _swig_wrap_StructA_x_set(arg1, arg2) +} + +var _wrap_StructA_x_get unsafe.Pointer + +func _swig_wrap_StructA_x_get(base SwigcptrStructA) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_StructA_x_get, _swig_p) + return +} + +func (arg1 SwigcptrStructA) GetX() (_swig_ret int) { + return _swig_wrap_StructA_x_get(arg1) +} + +var _wrap_new_StructA unsafe.Pointer + +func _swig_wrap_new_StructA() (base SwigcptrStructA) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_StructA, _swig_p) + return +} + +func NewStructA() (_swig_ret StructA) { + return _swig_wrap_new_StructA() +} + +var _wrap_delete_StructA unsafe.Pointer + +func _swig_wrap_delete_StructA(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_StructA, _swig_p) + return +} + +func DeleteStructA(arg1 StructA) { + _swig_wrap_delete_StructA(arg1.Swigcptr()) +} + +type StructA interface { + Swigcptr() uintptr + SwigIsStructA() + SetX(arg2 int) + GetX() (_swig_ret int) +} + +var _wrap_instanceA1_set unsafe.Pointer + +func _swig_wrap_instanceA1_set(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_instanceA1_set, _swig_p) + return +} + +func SetInstanceA1(arg1 StructA) { + _swig_wrap_instanceA1_set(arg1.Swigcptr()) +} + +var _wrap_instanceA1_get unsafe.Pointer + +func _swig_wrap_instanceA1_get() (base SwigcptrStructA) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_instanceA1_get, _swig_p) + return +} + +func GetInstanceA1() (_swig_ret StructA) { + return _swig_wrap_instanceA1_get() +} + +type SwigcptrStructB uintptr + +func (p SwigcptrStructB) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrStructB) SwigIsStructB() { +} + +var _wrap_StructB_x_set unsafe.Pointer + +func _swig_wrap_StructB_x_set(base SwigcptrStructB, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_StructB_x_set, _swig_p) + return +} + +func (arg1 SwigcptrStructB) SetX(arg2 int) { + _swig_wrap_StructB_x_set(arg1, arg2) +} + +var _wrap_StructB_x_get unsafe.Pointer + +func _swig_wrap_StructB_x_get(base SwigcptrStructB) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_StructB_x_get, _swig_p) + return +} + +func (arg1 SwigcptrStructB) GetX() (_swig_ret int) { + return _swig_wrap_StructB_x_get(arg1) +} + +var _wrap_new_StructB unsafe.Pointer + +func _swig_wrap_new_StructB() (base SwigcptrStructB) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_StructB, _swig_p) + return +} + +func NewStructB() (_swig_ret StructB) { + return _swig_wrap_new_StructB() +} + +var _wrap_delete_StructB unsafe.Pointer + +func _swig_wrap_delete_StructB(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_StructB, _swig_p) + return +} + +func DeleteStructB(arg1 StructB) { + _swig_wrap_delete_StructB(arg1.Swigcptr()) +} + +type StructB interface { + Swigcptr() uintptr + SwigIsStructB() + SetX(arg2 int) + GetX() (_swig_ret int) +} + +var _wrap_instanceB1_set unsafe.Pointer + +func _swig_wrap_instanceB1_set(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_instanceB1_set, _swig_p) + return +} + +func SetInstanceB1(arg1 StructB) { + _swig_wrap_instanceB1_set(arg1.Swigcptr()) +} + +var _wrap_instanceB1_get unsafe.Pointer + +func _swig_wrap_instanceB1_get() (base SwigcptrStructB) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_instanceB1_get, _swig_p) + return +} + +func GetInstanceB1() (_swig_ret StructB) { + return _swig_wrap_instanceB1_get() +} + +var _wrap_instanceB2_set unsafe.Pointer + +func _swig_wrap_instanceB2_set(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_instanceB2_set, _swig_p) + return +} + +func SetInstanceB2(arg1 StructB) { + _swig_wrap_instanceB2_set(arg1.Swigcptr()) +} + +var _wrap_instanceB2_get unsafe.Pointer + +func _swig_wrap_instanceB2_get() (base SwigcptrStructB) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_instanceB2_get, _swig_p) + return +} + +func GetInstanceB2() (_swig_ret StructB) { + return _swig_wrap_instanceB2_get() +} + +var _wrap_instanceB3_set unsafe.Pointer + +func _swig_wrap_instanceB3_set(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_instanceB3_set, _swig_p) + return +} + +func SetInstanceB3(arg1 StructB) { + _swig_wrap_instanceB3_set(arg1.Swigcptr()) +} + +var _wrap_instanceB3_get unsafe.Pointer + +func _swig_wrap_instanceB3_get() (base SwigcptrStructB) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_instanceB3_get, _swig_p) + return +} + +func GetInstanceB3() (_swig_ret StructB) { + return _swig_wrap_instanceB3_get() +} + +type SwigcptrStructC uintptr + +func (p SwigcptrStructC) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrStructC) SwigIsStructC() { +} + +var _wrap_StructC_x_set unsafe.Pointer + +func _swig_wrap_StructC_x_set(base SwigcptrStructC, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_StructC_x_set, _swig_p) + return +} + +func (arg1 SwigcptrStructC) SetX(arg2 int) { + _swig_wrap_StructC_x_set(arg1, arg2) +} + +var _wrap_StructC_x_get unsafe.Pointer + +func _swig_wrap_StructC_x_get(base SwigcptrStructC) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_StructC_x_get, _swig_p) + return +} + +func (arg1 SwigcptrStructC) GetX() (_swig_ret int) { + return _swig_wrap_StructC_x_get(arg1) +} + +var _wrap_new_StructC unsafe.Pointer + +func _swig_wrap_new_StructC() (base SwigcptrStructC) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_StructC, _swig_p) + return +} + +func NewStructC() (_swig_ret StructC) { + return _swig_wrap_new_StructC() +} + +var _wrap_delete_StructC unsafe.Pointer + +func _swig_wrap_delete_StructC(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_StructC, _swig_p) + return +} + +func DeleteStructC(arg1 StructC) { + _swig_wrap_delete_StructC(arg1.Swigcptr()) +} + +type StructC interface { + Swigcptr() uintptr + SwigIsStructC() + SetX(arg2 int) + GetX() (_swig_ret int) +} + +var _wrap_instanceC1_set unsafe.Pointer + +func _swig_wrap_instanceC1_set(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_instanceC1_set, _swig_p) + return +} + +func SetInstanceC1(arg1 StructC) { + _swig_wrap_instanceC1_set(arg1.Swigcptr()) +} + +var _wrap_instanceC1_get unsafe.Pointer + +func _swig_wrap_instanceC1_get() (base SwigcptrStructC) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_instanceC1_get, _swig_p) + return +} + +func GetInstanceC1() (_swig_ret StructC) { + return _swig_wrap_instanceC1_get() +} + +type SwigcptrStructD uintptr + +func (p SwigcptrStructD) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrStructD) SwigIsStructD() { +} + +var _wrap_StructD_x_set unsafe.Pointer + +func _swig_wrap_StructD_x_set(base SwigcptrStructD, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_StructD_x_set, _swig_p) + return +} + +func (arg1 SwigcptrStructD) SetX(arg2 int) { + _swig_wrap_StructD_x_set(arg1, arg2) +} + +var _wrap_StructD_x_get unsafe.Pointer + +func _swig_wrap_StructD_x_get(base SwigcptrStructD) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_StructD_x_get, _swig_p) + return +} + +func (arg1 SwigcptrStructD) GetX() (_swig_ret int) { + return _swig_wrap_StructD_x_get(arg1) +} + +var _wrap_new_StructD unsafe.Pointer + +func _swig_wrap_new_StructD() (base SwigcptrStructD) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_StructD, _swig_p) + return +} + +func NewStructD() (_swig_ret StructD) { + return _swig_wrap_new_StructD() +} + +var _wrap_delete_StructD unsafe.Pointer + +func _swig_wrap_delete_StructD(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_StructD, _swig_p) + return +} + +func DeleteStructD(arg1 StructD) { + _swig_wrap_delete_StructD(arg1.Swigcptr()) +} + +type StructD interface { + Swigcptr() uintptr + SwigIsStructD() + SetX(arg2 int) + GetX() (_swig_ret int) +} + +var _wrap_instanceD1_set unsafe.Pointer + +func _swig_wrap_instanceD1_set(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_instanceD1_set, _swig_p) + return +} + +func SetInstanceD1(arg1 StructD) { + _swig_wrap_instanceD1_set(arg1.Swigcptr()) +} + +var _wrap_instanceD1_get unsafe.Pointer + +func _swig_wrap_instanceD1_get() (base SwigcptrStructD) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_instanceD1_get, _swig_p) + return +} + +func GetInstanceD1() (_swig_ret StructD) { + return _swig_wrap_instanceD1_get() +} + +var _wrap_instanceD2_set unsafe.Pointer + +func _swig_wrap_instanceD2_set(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_instanceD2_set, _swig_p) + return +} + +func SetInstanceD2(arg1 StructD) { + _swig_wrap_instanceD2_set(arg1.Swigcptr()) +} + +var _wrap_instanceD2_get unsafe.Pointer + +func _swig_wrap_instanceD2_get() (base SwigcptrStructD) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_instanceD2_get, _swig_p) + return +} + +func GetInstanceD2() (_swig_ret StructD) { + return _swig_wrap_instanceD2_get() +} + +var _wrap_instanceD3_set unsafe.Pointer + +func _swig_wrap_instanceD3_set(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_instanceD3_set, _swig_p) + return +} + +func SetInstanceD3(arg1 StructD) { + _swig_wrap_instanceD3_set(arg1.Swigcptr()) +} + +var _wrap_instanceD3_get unsafe.Pointer + +func _swig_wrap_instanceD3_get() (base SwigcptrStructD) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_instanceD3_get, _swig_p) + return +} + +func GetInstanceD3() (_swig_ret StructD) { + return _swig_wrap_instanceD3_get() +} + +type SwigcptrStructE uintptr + +func (p SwigcptrStructE) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrStructE) SwigIsStructE() { +} + +var _wrap_StructE_x_set unsafe.Pointer + +func _swig_wrap_StructE_x_set(base SwigcptrStructE, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_StructE_x_set, _swig_p) + return +} + +func (arg1 SwigcptrStructE) SetX(arg2 int) { + _swig_wrap_StructE_x_set(arg1, arg2) +} + +var _wrap_StructE_x_get unsafe.Pointer + +func _swig_wrap_StructE_x_get(base SwigcptrStructE) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_StructE_x_get, _swig_p) + return +} + +func (arg1 SwigcptrStructE) GetX() (_swig_ret int) { + return _swig_wrap_StructE_x_get(arg1) +} + +var _wrap_new_StructE unsafe.Pointer + +func _swig_wrap_new_StructE() (base SwigcptrStructE) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_StructE, _swig_p) + return +} + +func NewStructE() (_swig_ret StructE) { + return _swig_wrap_new_StructE() +} + +var _wrap_delete_StructE unsafe.Pointer + +func _swig_wrap_delete_StructE(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_StructE, _swig_p) + return +} + +func DeleteStructE(arg1 StructE) { + _swig_wrap_delete_StructE(arg1.Swigcptr()) +} + +type StructE interface { + Swigcptr() uintptr + SwigIsStructE() + SetX(arg2 int) + GetX() (_swig_ret int) +} + +var _wrap_instanceE1_set unsafe.Pointer + +func _swig_wrap_instanceE1_set(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_instanceE1_set, _swig_p) + return +} + +func SetInstanceE1(arg1 StructE) { + _swig_wrap_instanceE1_set(arg1.Swigcptr()) +} + +var _wrap_instanceE1_get unsafe.Pointer + +func _swig_wrap_instanceE1_get() (base SwigcptrStructE) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_instanceE1_get, _swig_p) + return +} + +func GetInstanceE1() (_swig_ret StructE) { + return _swig_wrap_instanceE1_get() +} + +type SwigcptrStructF uintptr + +func (p SwigcptrStructF) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrStructF) SwigIsStructF() { +} + +var _wrap_StructF_x_set unsafe.Pointer + +func _swig_wrap_StructF_x_set(base SwigcptrStructF, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_StructF_x_set, _swig_p) + return +} + +func (arg1 SwigcptrStructF) SetX(arg2 int) { + _swig_wrap_StructF_x_set(arg1, arg2) +} + +var _wrap_StructF_x_get unsafe.Pointer + +func _swig_wrap_StructF_x_get(base SwigcptrStructF) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_StructF_x_get, _swig_p) + return +} + +func (arg1 SwigcptrStructF) GetX() (_swig_ret int) { + return _swig_wrap_StructF_x_get(arg1) +} + +var _wrap_new_StructF unsafe.Pointer + +func _swig_wrap_new_StructF() (base SwigcptrStructF) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_StructF, _swig_p) + return +} + +func NewStructF() (_swig_ret StructF) { + return _swig_wrap_new_StructF() +} + +var _wrap_delete_StructF unsafe.Pointer + +func _swig_wrap_delete_StructF(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_StructF, _swig_p) + return +} + +func DeleteStructF(arg1 StructF) { + _swig_wrap_delete_StructF(arg1.Swigcptr()) +} + +type StructF interface { + Swigcptr() uintptr + SwigIsStructF() + SetX(arg2 int) + GetX() (_swig_ret int) +} + +var _wrap_instanceF1_set unsafe.Pointer + +func _swig_wrap_instanceF1_set(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_instanceF1_set, _swig_p) + return +} + +func SetInstanceF1(arg1 StructF) { + _swig_wrap_instanceF1_set(arg1.Swigcptr()) +} + +var _wrap_instanceF1_get unsafe.Pointer + +func _swig_wrap_instanceF1_get() (base SwigcptrStructF) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_instanceF1_get, _swig_p) + return +} + +func GetInstanceF1() (_swig_ret StructF) { + return _swig_wrap_instanceF1_get() +} + +var _wrap_instanceF2_set unsafe.Pointer + +func _swig_wrap_instanceF2_set(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_instanceF2_set, _swig_p) + return +} + +func SetInstanceF2(arg1 StructF) { + _swig_wrap_instanceF2_set(arg1.Swigcptr()) +} + +var _wrap_instanceF2_get unsafe.Pointer + +func _swig_wrap_instanceF2_get() (base SwigcptrStructF) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_instanceF2_get, _swig_p) + return +} + +func GetInstanceF2() (_swig_ret StructF) { + return _swig_wrap_instanceF2_get() +} + +var _wrap_instanceF3_set unsafe.Pointer + +func _swig_wrap_instanceF3_set(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_instanceF3_set, _swig_p) + return +} + +func SetInstanceF3(arg1 StructF) { + _swig_wrap_instanceF3_set(arg1.Swigcptr()) +} + +var _wrap_instanceF3_get unsafe.Pointer + +func _swig_wrap_instanceF3_get() (base SwigcptrStructF) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_instanceF3_get, _swig_p) + return +} + +func GetInstanceF3() (_swig_ret StructF) { + return _swig_wrap_instanceF3_get() +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/struct_initialization_cpp.go b/Examples/test-suite/go/struct_initialization_cpp.go new file mode 100644 index 000000000..f59284bcb --- /dev/null +++ b/Examples/test-suite/go/struct_initialization_cpp.go @@ -0,0 +1,709 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../struct_initialization_cpp.i + +package struct_initialization_cpp + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrStructA uintptr + +func (p SwigcptrStructA) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrStructA) SwigIsStructA() { +} + +var _wrap_StructA_x_set unsafe.Pointer + +func _swig_wrap_StructA_x_set(base SwigcptrStructA, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_StructA_x_set, _swig_p) + return +} + +func (arg1 SwigcptrStructA) SetX(arg2 int) { + _swig_wrap_StructA_x_set(arg1, arg2) +} + +var _wrap_StructA_x_get unsafe.Pointer + +func _swig_wrap_StructA_x_get(base SwigcptrStructA) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_StructA_x_get, _swig_p) + return +} + +func (arg1 SwigcptrStructA) GetX() (_swig_ret int) { + return _swig_wrap_StructA_x_get(arg1) +} + +var _wrap_new_StructA unsafe.Pointer + +func _swig_wrap_new_StructA() (base SwigcptrStructA) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_StructA, _swig_p) + return +} + +func NewStructA() (_swig_ret StructA) { + return _swig_wrap_new_StructA() +} + +var _wrap_delete_StructA unsafe.Pointer + +func _swig_wrap_delete_StructA(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_StructA, _swig_p) + return +} + +func DeleteStructA(arg1 StructA) { + _swig_wrap_delete_StructA(arg1.Swigcptr()) +} + +type StructA interface { + Swigcptr() uintptr + SwigIsStructA() + SetX(arg2 int) + GetX() (_swig_ret int) +} + +var _wrap_instanceA1_set unsafe.Pointer + +func _swig_wrap_instanceA1_set(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_instanceA1_set, _swig_p) + return +} + +func SetInstanceA1(arg1 StructA) { + _swig_wrap_instanceA1_set(arg1.Swigcptr()) +} + +var _wrap_instanceA1_get unsafe.Pointer + +func _swig_wrap_instanceA1_get() (base SwigcptrStructA) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_instanceA1_get, _swig_p) + return +} + +func GetInstanceA1() (_swig_ret StructA) { + return _swig_wrap_instanceA1_get() +} + +type SwigcptrStructB uintptr + +func (p SwigcptrStructB) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrStructB) SwigIsStructB() { +} + +var _wrap_StructB_x_set unsafe.Pointer + +func _swig_wrap_StructB_x_set(base SwigcptrStructB, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_StructB_x_set, _swig_p) + return +} + +func (arg1 SwigcptrStructB) SetX(arg2 int) { + _swig_wrap_StructB_x_set(arg1, arg2) +} + +var _wrap_StructB_x_get unsafe.Pointer + +func _swig_wrap_StructB_x_get(base SwigcptrStructB) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_StructB_x_get, _swig_p) + return +} + +func (arg1 SwigcptrStructB) GetX() (_swig_ret int) { + return _swig_wrap_StructB_x_get(arg1) +} + +var _wrap_new_StructB unsafe.Pointer + +func _swig_wrap_new_StructB() (base SwigcptrStructB) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_StructB, _swig_p) + return +} + +func NewStructB() (_swig_ret StructB) { + return _swig_wrap_new_StructB() +} + +var _wrap_delete_StructB unsafe.Pointer + +func _swig_wrap_delete_StructB(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_StructB, _swig_p) + return +} + +func DeleteStructB(arg1 StructB) { + _swig_wrap_delete_StructB(arg1.Swigcptr()) +} + +type StructB interface { + Swigcptr() uintptr + SwigIsStructB() + SetX(arg2 int) + GetX() (_swig_ret int) +} + +var _wrap_instanceB1_set unsafe.Pointer + +func _swig_wrap_instanceB1_set(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_instanceB1_set, _swig_p) + return +} + +func SetInstanceB1(arg1 StructB) { + _swig_wrap_instanceB1_set(arg1.Swigcptr()) +} + +var _wrap_instanceB1_get unsafe.Pointer + +func _swig_wrap_instanceB1_get() (base SwigcptrStructB) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_instanceB1_get, _swig_p) + return +} + +func GetInstanceB1() (_swig_ret StructB) { + return _swig_wrap_instanceB1_get() +} + +var _wrap_instanceB2_set unsafe.Pointer + +func _swig_wrap_instanceB2_set(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_instanceB2_set, _swig_p) + return +} + +func SetInstanceB2(arg1 StructB) { + _swig_wrap_instanceB2_set(arg1.Swigcptr()) +} + +var _wrap_instanceB2_get unsafe.Pointer + +func _swig_wrap_instanceB2_get() (base SwigcptrStructB) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_instanceB2_get, _swig_p) + return +} + +func GetInstanceB2() (_swig_ret StructB) { + return _swig_wrap_instanceB2_get() +} + +var _wrap_instanceB3_set unsafe.Pointer + +func _swig_wrap_instanceB3_set(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_instanceB3_set, _swig_p) + return +} + +func SetInstanceB3(arg1 StructB) { + _swig_wrap_instanceB3_set(arg1.Swigcptr()) +} + +var _wrap_instanceB3_get unsafe.Pointer + +func _swig_wrap_instanceB3_get() (base SwigcptrStructB) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_instanceB3_get, _swig_p) + return +} + +func GetInstanceB3() (_swig_ret StructB) { + return _swig_wrap_instanceB3_get() +} + +type SwigcptrStructC uintptr + +func (p SwigcptrStructC) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrStructC) SwigIsStructC() { +} + +var _wrap_StructC_x_set unsafe.Pointer + +func _swig_wrap_StructC_x_set(base SwigcptrStructC, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_StructC_x_set, _swig_p) + return +} + +func (arg1 SwigcptrStructC) SetX(arg2 int) { + _swig_wrap_StructC_x_set(arg1, arg2) +} + +var _wrap_StructC_x_get unsafe.Pointer + +func _swig_wrap_StructC_x_get(base SwigcptrStructC) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_StructC_x_get, _swig_p) + return +} + +func (arg1 SwigcptrStructC) GetX() (_swig_ret int) { + return _swig_wrap_StructC_x_get(arg1) +} + +var _wrap_new_StructC unsafe.Pointer + +func _swig_wrap_new_StructC() (base SwigcptrStructC) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_StructC, _swig_p) + return +} + +func NewStructC() (_swig_ret StructC) { + return _swig_wrap_new_StructC() +} + +var _wrap_delete_StructC unsafe.Pointer + +func _swig_wrap_delete_StructC(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_StructC, _swig_p) + return +} + +func DeleteStructC(arg1 StructC) { + _swig_wrap_delete_StructC(arg1.Swigcptr()) +} + +type StructC interface { + Swigcptr() uintptr + SwigIsStructC() + SetX(arg2 int) + GetX() (_swig_ret int) +} + +var _wrap_instanceC1_set unsafe.Pointer + +func _swig_wrap_instanceC1_set(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_instanceC1_set, _swig_p) + return +} + +func SetInstanceC1(arg1 StructC) { + _swig_wrap_instanceC1_set(arg1.Swigcptr()) +} + +var _wrap_instanceC1_get unsafe.Pointer + +func _swig_wrap_instanceC1_get() (base SwigcptrStructC) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_instanceC1_get, _swig_p) + return +} + +func GetInstanceC1() (_swig_ret StructC) { + return _swig_wrap_instanceC1_get() +} + +type SwigcptrStructD uintptr + +func (p SwigcptrStructD) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrStructD) SwigIsStructD() { +} + +var _wrap_StructD_x_set unsafe.Pointer + +func _swig_wrap_StructD_x_set(base SwigcptrStructD, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_StructD_x_set, _swig_p) + return +} + +func (arg1 SwigcptrStructD) SetX(arg2 int) { + _swig_wrap_StructD_x_set(arg1, arg2) +} + +var _wrap_StructD_x_get unsafe.Pointer + +func _swig_wrap_StructD_x_get(base SwigcptrStructD) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_StructD_x_get, _swig_p) + return +} + +func (arg1 SwigcptrStructD) GetX() (_swig_ret int) { + return _swig_wrap_StructD_x_get(arg1) +} + +var _wrap_new_StructD unsafe.Pointer + +func _swig_wrap_new_StructD() (base SwigcptrStructD) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_StructD, _swig_p) + return +} + +func NewStructD() (_swig_ret StructD) { + return _swig_wrap_new_StructD() +} + +var _wrap_delete_StructD unsafe.Pointer + +func _swig_wrap_delete_StructD(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_StructD, _swig_p) + return +} + +func DeleteStructD(arg1 StructD) { + _swig_wrap_delete_StructD(arg1.Swigcptr()) +} + +type StructD interface { + Swigcptr() uintptr + SwigIsStructD() + SetX(arg2 int) + GetX() (_swig_ret int) +} + +var _wrap_instanceD1_set unsafe.Pointer + +func _swig_wrap_instanceD1_set(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_instanceD1_set, _swig_p) + return +} + +func SetInstanceD1(arg1 StructD) { + _swig_wrap_instanceD1_set(arg1.Swigcptr()) +} + +var _wrap_instanceD1_get unsafe.Pointer + +func _swig_wrap_instanceD1_get() (base SwigcptrStructD) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_instanceD1_get, _swig_p) + return +} + +func GetInstanceD1() (_swig_ret StructD) { + return _swig_wrap_instanceD1_get() +} + +var _wrap_instanceD2_set unsafe.Pointer + +func _swig_wrap_instanceD2_set(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_instanceD2_set, _swig_p) + return +} + +func SetInstanceD2(arg1 StructD) { + _swig_wrap_instanceD2_set(arg1.Swigcptr()) +} + +var _wrap_instanceD2_get unsafe.Pointer + +func _swig_wrap_instanceD2_get() (base SwigcptrStructD) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_instanceD2_get, _swig_p) + return +} + +func GetInstanceD2() (_swig_ret StructD) { + return _swig_wrap_instanceD2_get() +} + +var _wrap_instanceD3_set unsafe.Pointer + +func _swig_wrap_instanceD3_set(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_instanceD3_set, _swig_p) + return +} + +func SetInstanceD3(arg1 StructD) { + _swig_wrap_instanceD3_set(arg1.Swigcptr()) +} + +var _wrap_instanceD3_get unsafe.Pointer + +func _swig_wrap_instanceD3_get() (base SwigcptrStructD) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_instanceD3_get, _swig_p) + return +} + +func GetInstanceD3() (_swig_ret StructD) { + return _swig_wrap_instanceD3_get() +} + +type SwigcptrStructE uintptr + +func (p SwigcptrStructE) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrStructE) SwigIsStructE() { +} + +var _wrap_StructE_x_set unsafe.Pointer + +func _swig_wrap_StructE_x_set(base SwigcptrStructE, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_StructE_x_set, _swig_p) + return +} + +func (arg1 SwigcptrStructE) SetX(arg2 int) { + _swig_wrap_StructE_x_set(arg1, arg2) +} + +var _wrap_StructE_x_get unsafe.Pointer + +func _swig_wrap_StructE_x_get(base SwigcptrStructE) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_StructE_x_get, _swig_p) + return +} + +func (arg1 SwigcptrStructE) GetX() (_swig_ret int) { + return _swig_wrap_StructE_x_get(arg1) +} + +var _wrap_new_StructE unsafe.Pointer + +func _swig_wrap_new_StructE() (base SwigcptrStructE) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_StructE, _swig_p) + return +} + +func NewStructE() (_swig_ret StructE) { + return _swig_wrap_new_StructE() +} + +var _wrap_delete_StructE unsafe.Pointer + +func _swig_wrap_delete_StructE(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_StructE, _swig_p) + return +} + +func DeleteStructE(arg1 StructE) { + _swig_wrap_delete_StructE(arg1.Swigcptr()) +} + +type StructE interface { + Swigcptr() uintptr + SwigIsStructE() + SetX(arg2 int) + GetX() (_swig_ret int) +} + +var _wrap_instanceE1_set unsafe.Pointer + +func _swig_wrap_instanceE1_set(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_instanceE1_set, _swig_p) + return +} + +func SetInstanceE1(arg1 StructE) { + _swig_wrap_instanceE1_set(arg1.Swigcptr()) +} + +var _wrap_instanceE1_get unsafe.Pointer + +func _swig_wrap_instanceE1_get() (base SwigcptrStructE) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_instanceE1_get, _swig_p) + return +} + +func GetInstanceE1() (_swig_ret StructE) { + return _swig_wrap_instanceE1_get() +} + +type SwigcptrStructF uintptr + +func (p SwigcptrStructF) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrStructF) SwigIsStructF() { +} + +var _wrap_StructF_x_set unsafe.Pointer + +func _swig_wrap_StructF_x_set(base SwigcptrStructF, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_StructF_x_set, _swig_p) + return +} + +func (arg1 SwigcptrStructF) SetX(arg2 int) { + _swig_wrap_StructF_x_set(arg1, arg2) +} + +var _wrap_StructF_x_get unsafe.Pointer + +func _swig_wrap_StructF_x_get(base SwigcptrStructF) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_StructF_x_get, _swig_p) + return +} + +func (arg1 SwigcptrStructF) GetX() (_swig_ret int) { + return _swig_wrap_StructF_x_get(arg1) +} + +var _wrap_new_StructF unsafe.Pointer + +func _swig_wrap_new_StructF() (base SwigcptrStructF) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_StructF, _swig_p) + return +} + +func NewStructF() (_swig_ret StructF) { + return _swig_wrap_new_StructF() +} + +var _wrap_delete_StructF unsafe.Pointer + +func _swig_wrap_delete_StructF(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_StructF, _swig_p) + return +} + +func DeleteStructF(arg1 StructF) { + _swig_wrap_delete_StructF(arg1.Swigcptr()) +} + +type StructF interface { + Swigcptr() uintptr + SwigIsStructF() + SetX(arg2 int) + GetX() (_swig_ret int) +} + +var _wrap_instanceF1_set unsafe.Pointer + +func _swig_wrap_instanceF1_set(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_instanceF1_set, _swig_p) + return +} + +func SetInstanceF1(arg1 StructF) { + _swig_wrap_instanceF1_set(arg1.Swigcptr()) +} + +var _wrap_instanceF1_get unsafe.Pointer + +func _swig_wrap_instanceF1_get() (base SwigcptrStructF) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_instanceF1_get, _swig_p) + return +} + +func GetInstanceF1() (_swig_ret StructF) { + return _swig_wrap_instanceF1_get() +} + +var _wrap_instanceF2_set unsafe.Pointer + +func _swig_wrap_instanceF2_set(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_instanceF2_set, _swig_p) + return +} + +func SetInstanceF2(arg1 StructF) { + _swig_wrap_instanceF2_set(arg1.Swigcptr()) +} + +var _wrap_instanceF2_get unsafe.Pointer + +func _swig_wrap_instanceF2_get() (base SwigcptrStructF) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_instanceF2_get, _swig_p) + return +} + +func GetInstanceF2() (_swig_ret StructF) { + return _swig_wrap_instanceF2_get() +} + +var _wrap_instanceF3_set unsafe.Pointer + +func _swig_wrap_instanceF3_set(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_instanceF3_set, _swig_p) + return +} + +func SetInstanceF3(arg1 StructF) { + _swig_wrap_instanceF3_set(arg1.Swigcptr()) +} + +var _wrap_instanceF3_get unsafe.Pointer + +func _swig_wrap_instanceF3_get() (base SwigcptrStructF) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_instanceF3_get, _swig_p) + return +} + +func GetInstanceF3() (_swig_ret StructF) { + return _swig_wrap_instanceF3_get() +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/struct_initialization_runme b/Examples/test-suite/go/struct_initialization_runme new file mode 100755 index 000000000..a637928a5 Binary files /dev/null and b/Examples/test-suite/go/struct_initialization_runme differ diff --git a/Examples/test-suite/go/struct_rename.go b/Examples/test-suite/go/struct_rename.go new file mode 100644 index 000000000..5c9aa6eee --- /dev/null +++ b/Examples/test-suite/go/struct_rename.go @@ -0,0 +1,101 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../struct_rename.i + +package struct_rename + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrBar uintptr + +func (p SwigcptrBar) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrBar) SwigIsBar() { +} + +var _wrap_Bar_x_set unsafe.Pointer + +func _swig_wrap_Bar_x_set(base SwigcptrBar, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Bar_x_set, _swig_p) + return +} + +func (arg1 SwigcptrBar) SetX(arg2 int) { + _swig_wrap_Bar_x_set(arg1, arg2) +} + +var _wrap_Bar_x_get unsafe.Pointer + +func _swig_wrap_Bar_x_get(base SwigcptrBar) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Bar_x_get, _swig_p) + return +} + +func (arg1 SwigcptrBar) GetX() (_swig_ret int) { + return _swig_wrap_Bar_x_get(arg1) +} + +var _wrap_new_Bar unsafe.Pointer + +func _swig_wrap_new_Bar() (base SwigcptrBar) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Bar, _swig_p) + return +} + +func NewBar() (_swig_ret Bar) { + return _swig_wrap_new_Bar() +} + +var _wrap_delete_Bar unsafe.Pointer + +func _swig_wrap_delete_Bar(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Bar, _swig_p) + return +} + +func DeleteBar(arg1 Bar) { + _swig_wrap_delete_Bar(arg1.Swigcptr()) +} + +type Bar interface { + Swigcptr() uintptr + SwigIsBar() + SetX(arg2 int) + GetX() (_swig_ret int) +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/struct_rename_runme b/Examples/test-suite/go/struct_rename_runme new file mode 100755 index 000000000..67ae92a4c Binary files /dev/null and b/Examples/test-suite/go/struct_rename_runme differ diff --git a/Examples/test-suite/go/struct_value.go b/Examples/test-suite/go/struct_value.go new file mode 100644 index 000000000..1d56cb142 --- /dev/null +++ b/Examples/test-suite/go/struct_value.go @@ -0,0 +1,191 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../struct_value.i + +package struct_value + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrFoo uintptr + +func (p SwigcptrFoo) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrFoo) SwigIsFoo() { +} + +var _wrap_Foo_x_set unsafe.Pointer + +func _swig_wrap_Foo_x_set(base SwigcptrFoo, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_x_set, _swig_p) + return +} + +func (arg1 SwigcptrFoo) SetX(arg2 int) { + _swig_wrap_Foo_x_set(arg1, arg2) +} + +var _wrap_Foo_x_get unsafe.Pointer + +func _swig_wrap_Foo_x_get(base SwigcptrFoo) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_x_get, _swig_p) + return +} + +func (arg1 SwigcptrFoo) GetX() (_swig_ret int) { + return _swig_wrap_Foo_x_get(arg1) +} + +var _wrap_new_Foo unsafe.Pointer + +func _swig_wrap_new_Foo() (base SwigcptrFoo) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Foo, _swig_p) + return +} + +func NewFoo() (_swig_ret Foo) { + return _swig_wrap_new_Foo() +} + +var _wrap_delete_Foo unsafe.Pointer + +func _swig_wrap_delete_Foo(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Foo, _swig_p) + return +} + +func DeleteFoo(arg1 Foo) { + _swig_wrap_delete_Foo(arg1.Swigcptr()) +} + +type Foo interface { + Swigcptr() uintptr + SwigIsFoo() + SetX(arg2 int) + GetX() (_swig_ret int) +} + +type SwigcptrBar uintptr + +func (p SwigcptrBar) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrBar) SwigIsBar() { +} + +var _wrap_Bar_a_set unsafe.Pointer + +func _swig_wrap_Bar_a_set(base SwigcptrBar, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Bar_a_set, _swig_p) + return +} + +func (arg1 SwigcptrBar) SetA(arg2 Foo) { + _swig_wrap_Bar_a_set(arg1, arg2.Swigcptr()) +} + +var _wrap_Bar_a_get unsafe.Pointer + +func _swig_wrap_Bar_a_get(base SwigcptrBar) (_ SwigcptrFoo) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Bar_a_get, _swig_p) + return +} + +func (arg1 SwigcptrBar) GetA() (_swig_ret Foo) { + return _swig_wrap_Bar_a_get(arg1) +} + +var _wrap_Bar_b_set unsafe.Pointer + +func _swig_wrap_Bar_b_set(base SwigcptrBar, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Bar_b_set, _swig_p) + return +} + +func (arg1 SwigcptrBar) SetB(arg2 Foo) { + _swig_wrap_Bar_b_set(arg1, arg2.Swigcptr()) +} + +var _wrap_Bar_b_get unsafe.Pointer + +func _swig_wrap_Bar_b_get(base SwigcptrBar) (_ SwigcptrFoo) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Bar_b_get, _swig_p) + return +} + +func (arg1 SwigcptrBar) GetB() (_swig_ret Foo) { + return _swig_wrap_Bar_b_get(arg1) +} + +var _wrap_new_Bar unsafe.Pointer + +func _swig_wrap_new_Bar() (base SwigcptrBar) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Bar, _swig_p) + return +} + +func NewBar() (_swig_ret Bar) { + return _swig_wrap_new_Bar() +} + +var _wrap_delete_Bar unsafe.Pointer + +func _swig_wrap_delete_Bar(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Bar, _swig_p) + return +} + +func DeleteBar(arg1 Bar) { + _swig_wrap_delete_Bar(arg1.Swigcptr()) +} + +type Bar interface { + Swigcptr() uintptr + SwigIsBar() + SetA(arg2 Foo) + GetA() (_swig_ret Foo) + SetB(arg2 Foo) + GetB() (_swig_ret Foo) +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/struct_value_runme b/Examples/test-suite/go/struct_value_runme new file mode 100755 index 000000000..dd1b701bf Binary files /dev/null and b/Examples/test-suite/go/struct_value_runme differ diff --git a/Examples/test-suite/go/symbol_clash.go b/Examples/test-suite/go/symbol_clash.go new file mode 100644 index 000000000..fcc78a267 --- /dev/null +++ b/Examples/test-suite/go/symbol_clash.go @@ -0,0 +1,29 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../symbol_clash.i + +package symbol_clash + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + + diff --git a/Examples/test-suite/go/template_arg_replace.go b/Examples/test-suite/go/template_arg_replace.go new file mode 100644 index 000000000..62b0c7738 --- /dev/null +++ b/Examples/test-suite/go/template_arg_replace.go @@ -0,0 +1,88 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../template_arg_replace.i + +package template_arg_replace + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrMatrix33f uintptr + +func (p SwigcptrMatrix33f) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrMatrix33f) SwigIsMatrix33f() { +} + +var _wrap_matrix33f_Func unsafe.Pointer + +func _swig_wrap_matrix33f_Func(base SwigcptrMatrix33f, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_matrix33f_Func, _swig_p) + return +} + +func (arg1 SwigcptrMatrix33f) Func(arg2 Matrix33f) { + _swig_wrap_matrix33f_Func(arg1, arg2.Swigcptr()) +} + +var _wrap_new_matrix33f unsafe.Pointer + +func _swig_wrap_new_matrix33f() (base SwigcptrMatrix33f) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_matrix33f, _swig_p) + return +} + +func NewMatrix33f() (_swig_ret Matrix33f) { + return _swig_wrap_new_matrix33f() +} + +var _wrap_delete_matrix33f unsafe.Pointer + +func _swig_wrap_delete_matrix33f(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_matrix33f, _swig_p) + return +} + +func DeleteMatrix33f(arg1 Matrix33f) { + _swig_wrap_delete_matrix33f(arg1.Swigcptr()) +} + +type Matrix33f interface { + Swigcptr() uintptr + SwigIsMatrix33f() + Func(arg2 Matrix33f) +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/template_arg_scope.go b/Examples/test-suite/go/template_arg_scope.go new file mode 100644 index 000000000..942880886 --- /dev/null +++ b/Examples/test-suite/go/template_arg_scope.go @@ -0,0 +1,96 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../template_arg_scope.i + +package template_arg_scope + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrBar uintptr + +func (p SwigcptrBar) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrBar) SwigIsBar() { +} + +var _wrap_new_Bar unsafe.Pointer + +func _swig_wrap_new_Bar() (base SwigcptrBar) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Bar, _swig_p) + return +} + +func NewBar() (_swig_ret Bar) { + return _swig_wrap_new_Bar() +} + +var _wrap_Bar_spam unsafe.Pointer + +func _swig_wrap_Bar_spam(base SwigcptrBar, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Bar_spam, _swig_p) + return +} + +func (arg1 SwigcptrBar) Spam(arg2 Foo_Sl_Bar_Sg_) { + _swig_wrap_Bar_spam(arg1, arg2.Swigcptr()) +} + +var _wrap_delete_Bar unsafe.Pointer + +func _swig_wrap_delete_Bar(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Bar, _swig_p) + return +} + +func DeleteBar(arg1 Bar) { + _swig_wrap_delete_Bar(arg1.Swigcptr()) +} + +type Bar interface { + Swigcptr() uintptr + SwigIsBar() + Spam(arg2 Foo_Sl_Bar_Sg_) +} + + +type SwigcptrFoo_Sl_Bar_Sg_ uintptr +type Foo_Sl_Bar_Sg_ interface { + Swigcptr() uintptr; +} +func (p SwigcptrFoo_Sl_Bar_Sg_) Swigcptr() uintptr { + return uintptr(p) +} + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/template_arg_typename.go b/Examples/test-suite/go/template_arg_typename.go new file mode 100644 index 000000000..43c22cc46 --- /dev/null +++ b/Examples/test-suite/go/template_arg_typename.go @@ -0,0 +1,122 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../template_arg_typename.i + +package template_arg_typename + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrUnaryFunction_bool_bool uintptr + +func (p SwigcptrUnaryFunction_bool_bool) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrUnaryFunction_bool_bool) SwigIsUnaryFunction_bool_bool() { +} + +var _wrap_new_UnaryFunction_bool_bool unsafe.Pointer + +func _swig_wrap_new_UnaryFunction_bool_bool() (base SwigcptrUnaryFunction_bool_bool) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_UnaryFunction_bool_bool, _swig_p) + return +} + +func NewUnaryFunction_bool_bool() (_swig_ret UnaryFunction_bool_bool) { + return _swig_wrap_new_UnaryFunction_bool_bool() +} + +var _wrap_delete_UnaryFunction_bool_bool unsafe.Pointer + +func _swig_wrap_delete_UnaryFunction_bool_bool(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_UnaryFunction_bool_bool, _swig_p) + return +} + +func DeleteUnaryFunction_bool_bool(arg1 UnaryFunction_bool_bool) { + _swig_wrap_delete_UnaryFunction_bool_bool(arg1.Swigcptr()) +} + +type UnaryFunction_bool_bool interface { + Swigcptr() uintptr + SwigIsUnaryFunction_bool_bool() +} + +type SwigcptrBoolUnaryFunction_bool uintptr + +func (p SwigcptrBoolUnaryFunction_bool) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrBoolUnaryFunction_bool) SwigIsBoolUnaryFunction_bool() { +} + +var _wrap_new_BoolUnaryFunction_bool unsafe.Pointer + +func _swig_wrap_new_BoolUnaryFunction_bool(base *uintptr) (_ SwigcptrBoolUnaryFunction_bool) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_BoolUnaryFunction_bool, _swig_p) + return +} + +func NewBoolUnaryFunction_bool(arg1 *uintptr) (_swig_ret BoolUnaryFunction_bool) { + return _swig_wrap_new_BoolUnaryFunction_bool(arg1) +} + +var _wrap_delete_BoolUnaryFunction_bool unsafe.Pointer + +func _swig_wrap_delete_BoolUnaryFunction_bool(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_BoolUnaryFunction_bool, _swig_p) + return +} + +func DeleteBoolUnaryFunction_bool(arg1 BoolUnaryFunction_bool) { + _swig_wrap_delete_BoolUnaryFunction_bool(arg1.Swigcptr()) +} + +func (p SwigcptrBoolUnaryFunction_bool) SwigIsUnaryFunction_bool_bool() { +} + +func (p SwigcptrBoolUnaryFunction_bool) SwigGetUnaryFunction_bool_bool() UnaryFunction_bool_bool { + return SwigcptrUnaryFunction_bool_bool(p.Swigcptr()) +} + +type BoolUnaryFunction_bool interface { + Swigcptr() uintptr + SwigIsBoolUnaryFunction_bool() + SwigIsUnaryFunction_bool_bool() + SwigGetUnaryFunction_bool_bool() UnaryFunction_bool_bool +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/template_array_numeric.go b/Examples/test-suite/go/template_array_numeric.go new file mode 100644 index 000000000..f114be4d2 --- /dev/null +++ b/Examples/test-suite/go/template_array_numeric.go @@ -0,0 +1,110 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../template_array_numeric.i + +package template_array_numeric + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrArray4f uintptr + +func (p SwigcptrArray4f) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrArray4f) SwigIsArray4f() { +} + +var _wrap_new_Array4f__SWIG_0 unsafe.Pointer + +func _swig_wrap_new_Array4f__SWIG_0() (base SwigcptrArray4f) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Array4f__SWIG_0, _swig_p) + return +} + +func NewArray4f__SWIG_0() (_swig_ret Array4f) { + return _swig_wrap_new_Array4f__SWIG_0() +} + +var _wrap_new_Array4f__SWIG_1 unsafe.Pointer + +func _swig_wrap_new_Array4f__SWIG_1(base *float32) (_ SwigcptrArray4f) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Array4f__SWIG_1, _swig_p) + return +} + +func NewArray4f__SWIG_1(arg1 *float32) (_swig_ret Array4f) { + return _swig_wrap_new_Array4f__SWIG_1(arg1) +} + +func NewArray4f(a ...interface{}) Array4f { + argc := len(a) + if argc == 0 { + return NewArray4f__SWIG_0() + } + if argc == 1 { + return NewArray4f__SWIG_1(a[0].(*float32)) + } + panic("No match for overloaded function call") +} + +var _wrap_delete_Array4f unsafe.Pointer + +func _swig_wrap_delete_Array4f(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Array4f, _swig_p) + return +} + +func DeleteArray4f(arg1 Array4f) { + _swig_wrap_delete_Array4f(arg1.Swigcptr()) +} + +type Array4f interface { + Swigcptr() uintptr + SwigIsArray4f() +} + +var _wrap_make_array4f unsafe.Pointer + +func _swig_wrap_make_array4f(base *float32) (_ SwigcptrArray4f) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_make_array4f, _swig_p) + return +} + +func Make_array4f(arg1 *float32) (_swig_ret Array4f) { + return _swig_wrap_make_array4f(arg1) +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/template_base_template.go b/Examples/test-suite/go/template_base_template.go new file mode 100644 index 000000000..96e545c17 --- /dev/null +++ b/Examples/test-suite/go/template_base_template.go @@ -0,0 +1,160 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../template_base_template.i + +package template_base_template + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrTraits_dd uintptr + +func (p SwigcptrTraits_dd) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrTraits_dd) SwigIsTraits_dd() { +} + +var _wrap_new_traits_dd unsafe.Pointer + +func _swig_wrap_new_traits_dd() (base SwigcptrTraits_dd) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_traits_dd, _swig_p) + return +} + +func NewTraits_dd() (_swig_ret Traits_dd) { + return _swig_wrap_new_traits_dd() +} + +var _wrap_delete_traits_dd unsafe.Pointer + +func _swig_wrap_delete_traits_dd(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_traits_dd, _swig_p) + return +} + +func DeleteTraits_dd(arg1 Traits_dd) { + _swig_wrap_delete_traits_dd(arg1.Swigcptr()) +} + +type Traits_dd interface { + Swigcptr() uintptr + SwigIsTraits_dd() +} + +type SwigcptrFunktion_dd uintptr + +func (p SwigcptrFunktion_dd) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrFunktion_dd) SwigIsFunktion_dd() { +} + +var _wrap_new_Funktion_dd unsafe.Pointer + +func _swig_wrap_new_Funktion_dd() (base SwigcptrFunktion_dd) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Funktion_dd, _swig_p) + return +} + +func NewFunktion_dd() (_swig_ret Funktion_dd) { + return _swig_wrap_new_Funktion_dd() +} + +var _wrap_delete_Funktion_dd unsafe.Pointer + +func _swig_wrap_delete_Funktion_dd(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Funktion_dd, _swig_p) + return +} + +func DeleteFunktion_dd(arg1 Funktion_dd) { + _swig_wrap_delete_Funktion_dd(arg1.Swigcptr()) +} + +type Funktion_dd interface { + Swigcptr() uintptr + SwigIsFunktion_dd() +} + +type SwigcptrKlass_dd uintptr + +func (p SwigcptrKlass_dd) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrKlass_dd) SwigIsKlass_dd() { +} + +var _wrap_new_Klass_dd unsafe.Pointer + +func _swig_wrap_new_Klass_dd() (base SwigcptrKlass_dd) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Klass_dd, _swig_p) + return +} + +func NewKlass_dd() (_swig_ret Klass_dd) { + return _swig_wrap_new_Klass_dd() +} + +var _wrap_delete_Klass_dd unsafe.Pointer + +func _swig_wrap_delete_Klass_dd(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Klass_dd, _swig_p) + return +} + +func DeleteKlass_dd(arg1 Klass_dd) { + _swig_wrap_delete_Klass_dd(arg1.Swigcptr()) +} + +func (p SwigcptrKlass_dd) SwigIsFunktion_dd() { +} + +func (p SwigcptrKlass_dd) SwigGetFunktion_dd() Funktion_dd { + return SwigcptrFunktion_dd(p.Swigcptr()) +} + +type Klass_dd interface { + Swigcptr() uintptr + SwigIsKlass_dd() + SwigIsFunktion_dd() + SwigGetFunktion_dd() Funktion_dd +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/template_basic.go b/Examples/test-suite/go/template_basic.go new file mode 100644 index 000000000..d4bb23bf2 --- /dev/null +++ b/Examples/test-suite/go/template_basic.go @@ -0,0 +1,289 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../template_basic.i + +package template_basic + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +var _wrap_maxint unsafe.Pointer + +func Maxint(arg1 int, arg2 int) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_maxint, _swig_p) + return +} +var _wrap_maxdouble unsafe.Pointer + +func Maxdouble(arg1 float64, arg2 float64) (_swig_ret float64) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_maxdouble, _swig_p) + return +} +type SwigcptrVecint uintptr + +func (p SwigcptrVecint) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrVecint) SwigIsVecint() { +} + +var _wrap_new_vecint unsafe.Pointer + +func _swig_wrap_new_vecint(base int) (_ SwigcptrVecint) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_vecint, _swig_p) + return +} + +func NewVecint(arg1 int) (_swig_ret Vecint) { + return _swig_wrap_new_vecint(arg1) +} + +var _wrap_vecint_get unsafe.Pointer + +func _swig_wrap_vecint_get(base SwigcptrVecint, _ int) (_ *int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_vecint_get, _swig_p) + return +} + +func (arg1 SwigcptrVecint) Get(arg2 int) (_swig_ret *int) { + return _swig_wrap_vecint_get(arg1, arg2) +} + +var _wrap_vecint_set unsafe.Pointer + +func _swig_wrap_vecint_set(base SwigcptrVecint, _ int, _ *int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_vecint_set, _swig_p) + return +} + +func (arg1 SwigcptrVecint) Set(arg2 int, arg3 *int) { + _swig_wrap_vecint_set(arg1, arg2, arg3) +} + +var _wrap_vecint_testconst unsafe.Pointer + +func _swig_wrap_vecint_testconst(base SwigcptrVecint, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_vecint_testconst, _swig_p) + return +} + +func (arg1 SwigcptrVecint) Testconst(arg2 int) { + _swig_wrap_vecint_testconst(arg1, arg2) +} + +var _wrap_delete_vecint unsafe.Pointer + +func _swig_wrap_delete_vecint(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_vecint, _swig_p) + return +} + +func DeleteVecint(arg1 Vecint) { + _swig_wrap_delete_vecint(arg1.Swigcptr()) +} + +type Vecint interface { + Swigcptr() uintptr + SwigIsVecint() + Get(arg2 int) (_swig_ret *int) + Set(arg2 int, arg3 *int) + Testconst(arg2 int) +} + +type SwigcptrVecdouble uintptr + +func (p SwigcptrVecdouble) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrVecdouble) SwigIsVecdouble() { +} + +var _wrap_new_vecdouble unsafe.Pointer + +func _swig_wrap_new_vecdouble(base int) (_ SwigcptrVecdouble) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_vecdouble, _swig_p) + return +} + +func NewVecdouble(arg1 int) (_swig_ret Vecdouble) { + return _swig_wrap_new_vecdouble(arg1) +} + +var _wrap_vecdouble_get unsafe.Pointer + +func _swig_wrap_vecdouble_get(base SwigcptrVecdouble, _ int) (_ *float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_vecdouble_get, _swig_p) + return +} + +func (arg1 SwigcptrVecdouble) Get(arg2 int) (_swig_ret *float64) { + return _swig_wrap_vecdouble_get(arg1, arg2) +} + +var _wrap_vecdouble_set unsafe.Pointer + +func _swig_wrap_vecdouble_set(base SwigcptrVecdouble, _ int, _ *float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_vecdouble_set, _swig_p) + return +} + +func (arg1 SwigcptrVecdouble) Set(arg2 int, arg3 *float64) { + _swig_wrap_vecdouble_set(arg1, arg2, arg3) +} + +var _wrap_vecdouble_testconst unsafe.Pointer + +func _swig_wrap_vecdouble_testconst(base SwigcptrVecdouble, _ float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_vecdouble_testconst, _swig_p) + return +} + +func (arg1 SwigcptrVecdouble) Testconst(arg2 float64) { + _swig_wrap_vecdouble_testconst(arg1, arg2) +} + +var _wrap_delete_vecdouble unsafe.Pointer + +func _swig_wrap_delete_vecdouble(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_vecdouble, _swig_p) + return +} + +func DeleteVecdouble(arg1 Vecdouble) { + _swig_wrap_delete_vecdouble(arg1.Swigcptr()) +} + +type Vecdouble interface { + Swigcptr() uintptr + SwigIsVecdouble() + Get(arg2 int) (_swig_ret *float64) + Set(arg2 int, arg3 *float64) + Testconst(arg2 float64) +} + +var _wrap_maxintp unsafe.Pointer + +func Maxintp(arg1 **int, arg2 **int) (_swig_ret **int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_maxintp, _swig_p) + return +} +type SwigcptrVecintp uintptr + +func (p SwigcptrVecintp) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrVecintp) SwigIsVecintp() { +} + +var _wrap_new_vecintp unsafe.Pointer + +func _swig_wrap_new_vecintp(base int) (_ SwigcptrVecintp) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_vecintp, _swig_p) + return +} + +func NewVecintp(arg1 int) (_swig_ret Vecintp) { + return _swig_wrap_new_vecintp(arg1) +} + +var _wrap_vecintp_get unsafe.Pointer + +func _swig_wrap_vecintp_get(base SwigcptrVecintp, _ int) (_ ***int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_vecintp_get, _swig_p) + return +} + +func (arg1 SwigcptrVecintp) Get(arg2 int) (_swig_ret ***int) { + return _swig_wrap_vecintp_get(arg1, arg2) +} + +var _wrap_vecintp_set unsafe.Pointer + +func _swig_wrap_vecintp_set(base SwigcptrVecintp, _ int, _ ***int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_vecintp_set, _swig_p) + return +} + +func (arg1 SwigcptrVecintp) Set(arg2 int, arg3 ***int) { + _swig_wrap_vecintp_set(arg1, arg2, arg3) +} + +var _wrap_vecintp_testconst unsafe.Pointer + +func _swig_wrap_vecintp_testconst(base SwigcptrVecintp, _ **int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_vecintp_testconst, _swig_p) + return +} + +func (arg1 SwigcptrVecintp) Testconst(arg2 **int) { + _swig_wrap_vecintp_testconst(arg1, arg2) +} + +var _wrap_delete_vecintp unsafe.Pointer + +func _swig_wrap_delete_vecintp(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_vecintp, _swig_p) + return +} + +func DeleteVecintp(arg1 Vecintp) { + _swig_wrap_delete_vecintp(arg1.Swigcptr()) +} + +type Vecintp interface { + Swigcptr() uintptr + SwigIsVecintp() + Get(arg2 int) (_swig_ret ***int) + Set(arg2 int, arg3 ***int) + Testconst(arg2 **int) +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/template_classes.go b/Examples/test-suite/go/template_classes.go new file mode 100644 index 000000000..ffbb94187 --- /dev/null +++ b/Examples/test-suite/go/template_classes.go @@ -0,0 +1,152 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../template_classes.i + +package template_classes + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrPointInt uintptr + +func (p SwigcptrPointInt) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrPointInt) SwigIsPointInt() { +} + +var _wrap_PointInt_getX unsafe.Pointer + +func _swig_wrap_PointInt_getX(base SwigcptrPointInt) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_PointInt_getX, _swig_p) + return +} + +func (arg1 SwigcptrPointInt) GetX() (_swig_ret int) { + return _swig_wrap_PointInt_getX(arg1) +} + +var _wrap_new_PointInt unsafe.Pointer + +func _swig_wrap_new_PointInt() (base SwigcptrPointInt) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_PointInt, _swig_p) + return +} + +func NewPointInt() (_swig_ret PointInt) { + return _swig_wrap_new_PointInt() +} + +var _wrap_delete_PointInt unsafe.Pointer + +func _swig_wrap_delete_PointInt(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_PointInt, _swig_p) + return +} + +func DeletePointInt(arg1 PointInt) { + _swig_wrap_delete_PointInt(arg1.Swigcptr()) +} + +type PointInt interface { + Swigcptr() uintptr + SwigIsPointInt() + GetX() (_swig_ret int) +} + +type SwigcptrRectangleInt uintptr + +func (p SwigcptrRectangleInt) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrRectangleInt) SwigIsRectangleInt() { +} + +var _wrap_RectangleInt_getPoint unsafe.Pointer + +func _swig_wrap_RectangleInt_getPoint(base SwigcptrRectangleInt) (_ SwigcptrPointInt) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_RectangleInt_getPoint, _swig_p) + return +} + +func (arg1 SwigcptrRectangleInt) GetPoint() (_swig_ret PointInt) { + return _swig_wrap_RectangleInt_getPoint(arg1) +} + +var _wrap_RectangleInt_setPoint unsafe.Pointer + +func _swig_wrap_RectangleInt_setPoint(base SwigcptrRectangleInt, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_RectangleInt_setPoint, _swig_p) + return +} + +func (arg1 SwigcptrRectangleInt) SetPoint(arg2 PointInt) { + _swig_wrap_RectangleInt_setPoint(arg1, arg2.Swigcptr()) +} + +var _wrap_new_RectangleInt unsafe.Pointer + +func _swig_wrap_new_RectangleInt() (base SwigcptrRectangleInt) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_RectangleInt, _swig_p) + return +} + +func NewRectangleInt() (_swig_ret RectangleInt) { + return _swig_wrap_new_RectangleInt() +} + +var _wrap_delete_RectangleInt unsafe.Pointer + +func _swig_wrap_delete_RectangleInt(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_RectangleInt, _swig_p) + return +} + +func DeleteRectangleInt(arg1 RectangleInt) { + _swig_wrap_delete_RectangleInt(arg1.Swigcptr()) +} + +type RectangleInt interface { + Swigcptr() uintptr + SwigIsRectangleInt() + GetPoint() (_swig_ret PointInt) + SetPoint(arg2 PointInt) +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/template_const_ref.go b/Examples/test-suite/go/template_const_ref.go new file mode 100644 index 000000000..99b9a0680 --- /dev/null +++ b/Examples/test-suite/go/template_const_ref.go @@ -0,0 +1,177 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../template_const_ref.i + +package template_const_ref + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrBar uintptr + +func (p SwigcptrBar) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrBar) SwigIsBar() { +} + +var _wrap_new_Bar unsafe.Pointer + +func _swig_wrap_new_Bar() (base SwigcptrBar) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Bar, _swig_p) + return +} + +func NewBar() (_swig_ret Bar) { + return _swig_wrap_new_Bar() +} + +var _wrap_delete_Bar unsafe.Pointer + +func _swig_wrap_delete_Bar(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Bar, _swig_p) + return +} + +func DeleteBar(arg1 Bar) { + _swig_wrap_delete_Bar(arg1.Swigcptr()) +} + +type Bar interface { + Swigcptr() uintptr + SwigIsBar() +} + +type SwigcptrFoob uintptr + +func (p SwigcptrFoob) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrFoob) SwigIsFoob() { +} + +var _wrap_Foob_bar unsafe.Pointer + +func _swig_wrap_Foob_bar(base SwigcptrFoob, _ uintptr) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foob_bar, _swig_p) + return +} + +func (arg1 SwigcptrFoob) Bar(arg2 Bar) (_swig_ret string) { + return _swig_wrap_Foob_bar(arg1, arg2.Swigcptr()) +} + +var _wrap_new_Foob unsafe.Pointer + +func _swig_wrap_new_Foob() (base SwigcptrFoob) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Foob, _swig_p) + return +} + +func NewFoob() (_swig_ret Foob) { + return _swig_wrap_new_Foob() +} + +var _wrap_delete_Foob unsafe.Pointer + +func _swig_wrap_delete_Foob(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Foob, _swig_p) + return +} + +func DeleteFoob(arg1 Foob) { + _swig_wrap_delete_Foob(arg1.Swigcptr()) +} + +type Foob interface { + Swigcptr() uintptr + SwigIsFoob() + Bar(arg2 Bar) (_swig_ret string) +} + +type SwigcptrFooi uintptr + +func (p SwigcptrFooi) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrFooi) SwigIsFooi() { +} + +var _wrap_Fooi_bar unsafe.Pointer + +func _swig_wrap_Fooi_bar(base SwigcptrFooi, _ *int) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Fooi_bar, _swig_p) + return +} + +func (arg1 SwigcptrFooi) Bar(arg2 *int) (_swig_ret string) { + return _swig_wrap_Fooi_bar(arg1, arg2) +} + +var _wrap_new_Fooi unsafe.Pointer + +func _swig_wrap_new_Fooi() (base SwigcptrFooi) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Fooi, _swig_p) + return +} + +func NewFooi() (_swig_ret Fooi) { + return _swig_wrap_new_Fooi() +} + +var _wrap_delete_Fooi unsafe.Pointer + +func _swig_wrap_delete_Fooi(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Fooi, _swig_p) + return +} + +func DeleteFooi(arg1 Fooi) { + _swig_wrap_delete_Fooi(arg1.Swigcptr()) +} + +type Fooi interface { + Swigcptr() uintptr + SwigIsFooi() + Bar(arg2 *int) (_swig_ret string) +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/template_construct.go b/Examples/test-suite/go/template_construct.go new file mode 100644 index 000000000..b6abfb002 --- /dev/null +++ b/Examples/test-suite/go/template_construct.go @@ -0,0 +1,75 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../template_construct.i + +package template_construct + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrFoo_int uintptr + +func (p SwigcptrFoo_int) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrFoo_int) SwigIsFoo_int() { +} + +var _wrap_new_Foo_int unsafe.Pointer + +func _swig_wrap_new_Foo_int(base int) (_ SwigcptrFoo_int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Foo_int, _swig_p) + return +} + +func NewFoo_int(arg1 int) (_swig_ret Foo_int) { + return _swig_wrap_new_Foo_int(arg1) +} + +var _wrap_delete_Foo_int unsafe.Pointer + +func _swig_wrap_delete_Foo_int(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Foo_int, _swig_p) + return +} + +func DeleteFoo_int(arg1 Foo_int) { + _swig_wrap_delete_Foo_int(arg1.Swigcptr()) +} + +type Foo_int interface { + Swigcptr() uintptr + SwigIsFoo_int() +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/template_default.go b/Examples/test-suite/go/template_default.go new file mode 100644 index 000000000..7b29b2962 --- /dev/null +++ b/Examples/test-suite/go/template_default.go @@ -0,0 +1,793 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../template_default.i + +package template_default + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrParm uintptr + +func (p SwigcptrParm) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrParm) SwigIsParm() { +} + +var _wrap_new_Parm unsafe.Pointer + +func _swig_wrap_new_Parm() (base SwigcptrParm) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Parm, _swig_p) + return +} + +func NewParm() (_swig_ret Parm) { + return _swig_wrap_new_Parm() +} + +var _wrap_delete_Parm unsafe.Pointer + +func _swig_wrap_delete_Parm(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Parm, _swig_p) + return +} + +func DeleteParm(arg1 Parm) { + _swig_wrap_delete_Parm(arg1.Swigcptr()) +} + +type Parm interface { + Swigcptr() uintptr + SwigIsParm() +} + +var _wrap_one_get unsafe.Pointer + +func GetOne() (_swig_ret uint) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_one_get, _swig_p) + return +} +var _wrap_two_get unsafe.Pointer + +func GetTwo() (_swig_ret uint) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_two_get, _swig_p) + return +} +type SwigcptrA_p uintptr + +func (p SwigcptrA_p) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrA_p) SwigIsA_p() { +} + +var _wrap_new_A_p unsafe.Pointer + +func _swig_wrap_new_A_p() (base SwigcptrA_p) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_A_p, _swig_p) + return +} + +func NewA_p() (_swig_ret A_p) { + return _swig_wrap_new_A_p() +} + +var _wrap_delete_A_p unsafe.Pointer + +func _swig_wrap_delete_A_p(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_A_p, _swig_p) + return +} + +func DeleteA_p(arg1 A_p) { + _swig_wrap_delete_A_p(arg1.Swigcptr()) +} + +type A_p interface { + Swigcptr() uintptr + SwigIsA_p() +} + +type SwigcptrN_1p uintptr + +func (p SwigcptrN_1p) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrN_1p) SwigIsN_1p() { +} + +var _wrap_new_N_1p unsafe.Pointer + +func _swig_wrap_new_N_1p() (base SwigcptrN_1p) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_N_1p, _swig_p) + return +} + +func NewN_1p() (_swig_ret N_1p) { + return _swig_wrap_new_N_1p() +} + +var _wrap_delete_N_1p unsafe.Pointer + +func _swig_wrap_delete_N_1p(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_N_1p, _swig_p) + return +} + +func DeleteN_1p(arg1 N_1p) { + _swig_wrap_delete_N_1p(arg1.Swigcptr()) +} + +type N_1p interface { + Swigcptr() uintptr + SwigIsN_1p() +} + +type SwigcptrA_ii uintptr + +func (p SwigcptrA_ii) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrA_ii) SwigIsA_ii() { +} + +var _wrap_A_ii_bar unsafe.Pointer + +func _swig_wrap_A_ii_bar(base SwigcptrA_ii) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_A_ii_bar, _swig_p) + return +} + +func (arg1 SwigcptrA_ii) Bar() (_swig_ret int) { + return _swig_wrap_A_ii_bar(arg1) +} + +var _wrap_new_A_ii unsafe.Pointer + +func _swig_wrap_new_A_ii() (base SwigcptrA_ii) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_A_ii, _swig_p) + return +} + +func NewA_ii() (_swig_ret A_ii) { + return _swig_wrap_new_A_ii() +} + +var _wrap_delete_A_ii unsafe.Pointer + +func _swig_wrap_delete_A_ii(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_A_ii, _swig_p) + return +} + +func DeleteA_ii(arg1 A_ii) { + _swig_wrap_delete_A_ii(arg1.Swigcptr()) +} + +type A_ii interface { + Swigcptr() uintptr + SwigIsA_ii() + Bar() (_swig_ret int) +} + +type SwigcptrA_d uintptr + +func (p SwigcptrA_d) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrA_d) SwigIsA_d() { +} + +var _wrap_A_d_bar unsafe.Pointer + +func _swig_wrap_A_d_bar(base SwigcptrA_d) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_A_d_bar, _swig_p) + return +} + +func (arg1 SwigcptrA_d) Bar() (_swig_ret int) { + return _swig_wrap_A_d_bar(arg1) +} + +var _wrap_new_A_d unsafe.Pointer + +func _swig_wrap_new_A_d() (base SwigcptrA_d) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_A_d, _swig_p) + return +} + +func NewA_d() (_swig_ret A_d) { + return _swig_wrap_new_A_d() +} + +var _wrap_delete_A_d unsafe.Pointer + +func _swig_wrap_delete_A_d(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_A_d, _swig_p) + return +} + +func DeleteA_d(arg1 A_d) { + _swig_wrap_delete_A_d(arg1.Swigcptr()) +} + +type A_d interface { + Swigcptr() uintptr + SwigIsA_d() + Bar() (_swig_ret int) +} + +type SwigcptrN_d uintptr + +func (p SwigcptrN_d) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrN_d) SwigIsN_d() { +} + +var _wrap_N_d_bar unsafe.Pointer + +func _swig_wrap_N_d_bar(base SwigcptrN_d) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_N_d_bar, _swig_p) + return +} + +func (arg1 SwigcptrN_d) Bar() (_swig_ret int) { + return _swig_wrap_N_d_bar(arg1) +} + +var _wrap_new_N_d unsafe.Pointer + +func _swig_wrap_new_N_d() (base SwigcptrN_d) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_N_d, _swig_p) + return +} + +func NewN_d() (_swig_ret N_d) { + return _swig_wrap_new_N_d() +} + +var _wrap_delete_N_d unsafe.Pointer + +func _swig_wrap_delete_N_d(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_N_d, _swig_p) + return +} + +func DeleteN_d(arg1 N_d) { + _swig_wrap_delete_N_d(arg1.Swigcptr()) +} + +type N_d interface { + Swigcptr() uintptr + SwigIsN_d() + Bar() (_swig_ret int) +} + +type SwigcptrB uintptr + +func (p SwigcptrB) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrB) SwigIsB() { +} + +var _wrap_new_B unsafe.Pointer + +func _swig_wrap_new_B() (base SwigcptrB) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_B, _swig_p) + return +} + +func NewB() (_swig_ret B) { + return _swig_wrap_new_B() +} + +var _wrap_delete_B unsafe.Pointer + +func _swig_wrap_delete_B(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_B, _swig_p) + return +} + +func DeleteB(arg1 B) { + _swig_wrap_delete_B(arg1.Swigcptr()) +} + +func (p SwigcptrB) SwigIsA_ii() { +} + +func (p SwigcptrB) SwigGetA_ii() A_ii { + return SwigcptrA_ii(p.Swigcptr()) +} + +type B interface { + Swigcptr() uintptr + SwigIsB() + SwigIsA_ii() + SwigGetA_ii() A_ii +} + +type SwigcptrC uintptr + +func (p SwigcptrC) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrC) SwigIsC() { +} + +var _wrap_new_C unsafe.Pointer + +func _swig_wrap_new_C() (base SwigcptrC) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_C, _swig_p) + return +} + +func NewC() (_swig_ret C) { + return _swig_wrap_new_C() +} + +var _wrap_delete_C unsafe.Pointer + +func _swig_wrap_delete_C(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_C, _swig_p) + return +} + +func DeleteC(arg1 C) { + _swig_wrap_delete_C(arg1.Swigcptr()) +} + +func (p SwigcptrC) SwigIsN_d() { +} + +func (p SwigcptrC) SwigGetN_d() N_d { + return SwigcptrN_d(p.Swigcptr()) +} + +type C interface { + Swigcptr() uintptr + SwigIsC() + SwigIsN_d() + SwigGetN_d() N_d +} + +var _wrap_get_a1 unsafe.Pointer + +func _swig_wrap_get_a1(base uintptr) (_ SwigcptrA_ii) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_get_a1, _swig_p) + return +} + +func Get_a1(arg1 A_ii) (_swig_ret A_ii) { + return _swig_wrap_get_a1(arg1.Swigcptr()) +} + +var _wrap_get_a2 unsafe.Pointer + +func _swig_wrap_get_a2(base uintptr) (_ SwigcptrA_ii) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_get_a2, _swig_p) + return +} + +func Get_a2(arg1 A_ii) (_swig_ret A_ii) { + return _swig_wrap_get_a2(arg1.Swigcptr()) +} + +type SwigcptrTraits uintptr + +func (p SwigcptrTraits) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrTraits) SwigIsTraits() { +} + +var _wrap_Traits_c_Traits unsafe.Pointer + +func _swig_getTraits_Traits_c_Traits() (_swig_ret uint) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_Traits_c_Traits, _swig_p) + return +} +var TraitsC uint = _swig_getTraits_Traits_c_Traits() +var _wrap_new_Traits unsafe.Pointer + +func _swig_wrap_new_Traits() (base SwigcptrTraits) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Traits, _swig_p) + return +} + +func NewTraits() (_swig_ret Traits) { + return _swig_wrap_new_Traits() +} + +var _wrap_delete_Traits unsafe.Pointer + +func _swig_wrap_delete_Traits(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Traits, _swig_p) + return +} + +func DeleteTraits(arg1 Traits) { + _swig_wrap_delete_Traits(arg1.Swigcptr()) +} + +type Traits interface { + Swigcptr() uintptr + SwigIsTraits() +} + +type SwigcptrDoo uintptr + +func (p SwigcptrDoo) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrDoo) SwigIsDoo() { +} + +var _wrap_new_Doo unsafe.Pointer + +func _swig_wrap_new_Doo() (base SwigcptrDoo) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Doo, _swig_p) + return +} + +func NewDoo() (_swig_ret Doo) { + return _swig_wrap_new_Doo() +} + +var _wrap_delete_Doo unsafe.Pointer + +func _swig_wrap_delete_Doo(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Doo, _swig_p) + return +} + +func DeleteDoo(arg1 Doo) { + _swig_wrap_delete_Doo(arg1.Swigcptr()) +} + +func (p SwigcptrDoo) SwigIsN_d() { +} + +func (p SwigcptrDoo) SwigGetN_d() N_d { + return SwigcptrN_d(p.Swigcptr()) +} + +type Doo interface { + Swigcptr() uintptr + SwigIsDoo() + SwigIsN_d() + SwigGetN_d() N_d +} + +type SwigcptrBoo uintptr + +func (p SwigcptrBoo) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrBoo) SwigIsBoo() { +} + +var _wrap_new_Boo unsafe.Pointer + +func _swig_wrap_new_Boo() (base SwigcptrBoo) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Boo, _swig_p) + return +} + +func NewBoo() (_swig_ret Boo) { + return _swig_wrap_new_Boo() +} + +var _wrap_delete_Boo unsafe.Pointer + +func _swig_wrap_delete_Boo(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Boo, _swig_p) + return +} + +func DeleteBoo(arg1 Boo) { + _swig_wrap_delete_Boo(arg1.Swigcptr()) +} + +func (p SwigcptrBoo) SwigIsDoo() { +} + +func (p SwigcptrBoo) SwigGetDoo() Doo { + return SwigcptrDoo(p.Swigcptr()) +} + +func (p SwigcptrBoo) SwigIsN_d() { +} + +func (p SwigcptrBoo) SwigGetN_d() N_d { + return SwigcptrN_d(p.Swigcptr()) +} + +type Boo interface { + Swigcptr() uintptr + SwigIsBoo() + SwigIsDoo() + SwigGetDoo() Doo + SwigIsN_d() + SwigGetN_d() N_d +} + +type SwigcptrDer uintptr + +func (p SwigcptrDer) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrDer) SwigIsDer() { +} + +var _wrap_new_Der unsafe.Pointer + +func _swig_wrap_new_Der() (base SwigcptrDer) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Der, _swig_p) + return +} + +func NewDer() (_swig_ret Der) { + return _swig_wrap_new_Der() +} + +var _wrap_delete_Der unsafe.Pointer + +func _swig_wrap_delete_Der(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Der, _swig_p) + return +} + +func DeleteDer(arg1 Der) { + _swig_wrap_delete_Der(arg1.Swigcptr()) +} + +func (p SwigcptrDer) SwigIsBoo() { +} + +func (p SwigcptrDer) SwigGetBoo() Boo { + return SwigcptrBoo(p.Swigcptr()) +} + +func (p SwigcptrDer) SwigIsDoo() { +} + +func (p SwigcptrDer) SwigGetDoo() Doo { + return SwigcptrDoo(p.Swigcptr()) +} + +func (p SwigcptrDer) SwigIsN_d() { +} + +func (p SwigcptrDer) SwigGetN_d() N_d { + return SwigcptrN_d(p.Swigcptr()) +} + +type Der interface { + Swigcptr() uintptr + SwigIsDer() + SwigIsBoo() + SwigGetBoo() Boo + SwigIsDoo() + SwigGetDoo() Doo + SwigIsN_d() + SwigGetN_d() N_d +} + +type SwigcptrCFoo uintptr + +func (p SwigcptrCFoo) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrCFoo) SwigIsCFoo() { +} + +var _wrap_new_CFoo unsafe.Pointer + +func _swig_wrap_new_CFoo() (base SwigcptrCFoo) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_CFoo, _swig_p) + return +} + +func NewCFoo() (_swig_ret CFoo) { + return _swig_wrap_new_CFoo() +} + +var _wrap_delete_CFoo unsafe.Pointer + +func _swig_wrap_delete_CFoo(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_CFoo, _swig_p) + return +} + +func DeleteCFoo(arg1 CFoo) { + _swig_wrap_delete_CFoo(arg1.Swigcptr()) +} + +type CFoo interface { + Swigcptr() uintptr + SwigIsCFoo() +} + +var _wrap_foo unsafe.Pointer + +func Foo(arg1 *_swig_fnptr, arg2 *_swig_fnptr, arg3 *_swig_fnptr) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_foo, _swig_p) + return +} +var _wrap_g__SWIG_0 unsafe.Pointer + +func _swig_wrap_g__SWIG_0(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_g__SWIG_0, _swig_p) + return +} + +func G__SWIG_0(arg1 Std_vector_Sl_double_Sg_) { + _swig_wrap_g__SWIG_0(arg1.Swigcptr()) +} + +var _wrap_g__SWIG_1 unsafe.Pointer + +func _swig_wrap_g__SWIG_1() { + var _swig_p uintptr + _cgo_runtime_cgocall(_wrap_g__SWIG_1, _swig_p) + return +} + +func G__SWIG_1() { + _swig_wrap_g__SWIG_1() +} + +func G(a ...interface{}) { + argc := len(a) + if argc == 0 { + G__SWIG_1() + return + } + if argc == 1 { + G__SWIG_0(a[0].(Std_vector_Sl_double_Sg_)) + return + } + panic("No match for overloaded function call") +} + +var _wrap_q__SWIG_0 unsafe.Pointer + +func _swig_wrap_q__SWIG_0(base float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_q__SWIG_0, _swig_p) + return +} + +func Q__SWIG_0(arg1 float64) { + _swig_wrap_q__SWIG_0(arg1) +} + +var _wrap_q__SWIG_1 unsafe.Pointer + +func _swig_wrap_q__SWIG_1() { + var _swig_p uintptr + _cgo_runtime_cgocall(_wrap_q__SWIG_1, _swig_p) + return +} + +func Q__SWIG_1() { + _swig_wrap_q__SWIG_1() +} + +func Q(a ...interface{}) { + argc := len(a) + if argc == 0 { + Q__SWIG_1() + return + } + if argc == 1 { + Q__SWIG_0(a[0].(float64)) + return + } + panic("No match for overloaded function call") +} + +var _wrap_Bf unsafe.Pointer + +func _swig_getBf() (_swig_ret _swig_fnptr) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_Bf, _swig_p) + return +} +var Bf _swig_fnptr = _swig_getBf() +var _wrap_Cf unsafe.Pointer + +func _swig_getCf() (_swig_ret _swig_fnptr) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_Cf, _swig_p) + return +} +var Cf _swig_fnptr = _swig_getCf() + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + +type SwigcptrStd_vector_Sl_double_Sg_ uintptr +type Std_vector_Sl_double_Sg_ interface { + Swigcptr() uintptr; +} +func (p SwigcptrStd_vector_Sl_double_Sg_) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/template_default2.go b/Examples/test-suite/go/template_default2.go new file mode 100644 index 000000000..fe4f1acb2 --- /dev/null +++ b/Examples/test-suite/go/template_default2.go @@ -0,0 +1,279 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../template_default2.i + +package template_default2 + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type OssPolarization int +var _wrap_UnaryPolarization unsafe.Pointer + +func _swig_getUnaryPolarization() (_swig_ret OssPolarization) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_UnaryPolarization, _swig_p) + return +} +var UnaryPolarization OssPolarization = _swig_getUnaryPolarization() +var _wrap_BinaryPolarization unsafe.Pointer + +func _swig_getBinaryPolarization() (_swig_ret OssPolarization) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_BinaryPolarization, _swig_p) + return +} +var BinaryPolarization OssPolarization = _swig_getBinaryPolarization() +type SwigcptrTraits uintptr + +func (p SwigcptrTraits) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrTraits) SwigIsTraits() { +} + +var _wrap_traits_pmode_traits unsafe.Pointer + +func _swig_gettraits_traits_pmode_traits() (_swig_ret OssPolarization) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_traits_pmode_traits, _swig_p) + return +} +var TraitsPmode OssPolarization = _swig_gettraits_traits_pmode_traits() +var _wrap_new_traits unsafe.Pointer + +func _swig_wrap_new_traits() (base SwigcptrTraits) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_traits, _swig_p) + return +} + +func NewTraits() (_swig_ret Traits) { + return _swig_wrap_new_traits() +} + +var _wrap_delete_traits unsafe.Pointer + +func _swig_wrap_delete_traits(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_traits, _swig_p) + return +} + +func DeleteTraits(arg1 Traits) { + _swig_wrap_delete_traits(arg1.Swigcptr()) +} + +type Traits interface { + Swigcptr() uintptr + SwigIsTraits() +} + +type SwigcptrInterface_UP uintptr + +func (p SwigcptrInterface_UP) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrInterface_UP) SwigIsInterface_UP() { +} + +var _wrap_new_Interface_UP unsafe.Pointer + +func _swig_wrap_new_Interface_UP() (base SwigcptrInterface_UP) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Interface_UP, _swig_p) + return +} + +func NewInterface_UP() (_swig_ret Interface_UP) { + return _swig_wrap_new_Interface_UP() +} + +var _wrap_delete_Interface_UP unsafe.Pointer + +func _swig_wrap_delete_Interface_UP(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Interface_UP, _swig_p) + return +} + +func DeleteInterface_UP(arg1 Interface_UP) { + _swig_wrap_delete_Interface_UP(arg1.Swigcptr()) +} + +type Interface_UP interface { + Swigcptr() uintptr + SwigIsInterface_UP() +} + +type SwigcptrModule_UP1 uintptr + +func (p SwigcptrModule_UP1) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrModule_UP1) SwigIsModule_UP1() { +} + +var _wrap_new_Module_UP1 unsafe.Pointer + +func _swig_wrap_new_Module_UP1() (base SwigcptrModule_UP1) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Module_UP1, _swig_p) + return +} + +func NewModule_UP1() (_swig_ret Module_UP1) { + return _swig_wrap_new_Module_UP1() +} + +var _wrap_delete_Module_UP1 unsafe.Pointer + +func _swig_wrap_delete_Module_UP1(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Module_UP1, _swig_p) + return +} + +func DeleteModule_UP1(arg1 Module_UP1) { + _swig_wrap_delete_Module_UP1(arg1.Swigcptr()) +} + +func (p SwigcptrModule_UP1) SwigIsInterface_UP() { +} + +func (p SwigcptrModule_UP1) SwigGetInterface_UP() Interface_UP { + return SwigcptrInterface_UP(p.Swigcptr()) +} + +type Module_UP1 interface { + Swigcptr() uintptr + SwigIsModule_UP1() + SwigIsInterface_UP() + SwigGetInterface_UP() Interface_UP +} + +type SwigcptrModule_UP2 uintptr + +func (p SwigcptrModule_UP2) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrModule_UP2) SwigIsModule_UP2() { +} + +var _wrap_new_Module_UP2 unsafe.Pointer + +func _swig_wrap_new_Module_UP2() (base SwigcptrModule_UP2) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Module_UP2, _swig_p) + return +} + +func NewModule_UP2() (_swig_ret Module_UP2) { + return _swig_wrap_new_Module_UP2() +} + +var _wrap_delete_Module_UP2 unsafe.Pointer + +func _swig_wrap_delete_Module_UP2(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Module_UP2, _swig_p) + return +} + +func DeleteModule_UP2(arg1 Module_UP2) { + _swig_wrap_delete_Module_UP2(arg1.Swigcptr()) +} + +func (p SwigcptrModule_UP2) SwigIsInterface_UP() { +} + +func (p SwigcptrModule_UP2) SwigGetInterface_UP() Interface_UP { + return SwigcptrInterface_UP(p.Swigcptr()) +} + +type Module_UP2 interface { + Swigcptr() uintptr + SwigIsModule_UP2() + SwigIsInterface_UP() + SwigGetInterface_UP() Interface_UP +} + +type SwigcptrModule_UP3 uintptr + +func (p SwigcptrModule_UP3) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrModule_UP3) SwigIsModule_UP3() { +} + +var _wrap_new_Module_UP3 unsafe.Pointer + +func _swig_wrap_new_Module_UP3() (base SwigcptrModule_UP3) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Module_UP3, _swig_p) + return +} + +func NewModule_UP3() (_swig_ret Module_UP3) { + return _swig_wrap_new_Module_UP3() +} + +var _wrap_delete_Module_UP3 unsafe.Pointer + +func _swig_wrap_delete_Module_UP3(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Module_UP3, _swig_p) + return +} + +func DeleteModule_UP3(arg1 Module_UP3) { + _swig_wrap_delete_Module_UP3(arg1.Swigcptr()) +} + +func (p SwigcptrModule_UP3) SwigIsInterface_UP() { +} + +func (p SwigcptrModule_UP3) SwigGetInterface_UP() Interface_UP { + return SwigcptrInterface_UP(p.Swigcptr()) +} + +type Module_UP3 interface { + Swigcptr() uintptr + SwigIsModule_UP3() + SwigIsInterface_UP() + SwigGetInterface_UP() Interface_UP +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/template_default_arg.go b/Examples/test-suite/go/template_default_arg.go new file mode 100644 index 000000000..ba18b8240 --- /dev/null +++ b/Examples/test-suite/go/template_default_arg.go @@ -0,0 +1,2105 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../template_default_arg.i + +package template_default_arg + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +var _wrap_foob__SWIG_0 unsafe.Pointer + +func _swig_wrap_foob__SWIG_0(base uintptr) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_foob__SWIG_0, _swig_p) + return +} + +func Foob__SWIG_0(arg1 Foo_int) (_swig_ret int) { + return _swig_wrap_foob__SWIG_0(arg1.Swigcptr()) +} + +var _wrap_foob__SWIG_1 unsafe.Pointer + +func Foob__SWIG_1() (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_foob__SWIG_1, _swig_p) + return +} +func Foob(a ...interface{}) int { + argc := len(a) + if argc == 0 { + return Foob__SWIG_1() + } + if argc == 1 { + return Foob__SWIG_0(a[0].(Foo_int)) + } + panic("No match for overloaded function call") +} + +type SwigcptrFoo_int uintptr + +func (p SwigcptrFoo_int) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrFoo_int) SwigIsFoo_int() { +} + +var _wrap_new_Foo_int__SWIG_0 unsafe.Pointer + +func _swig_wrap_new_Foo_int__SWIG_0(base uint) (_ SwigcptrFoo_int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Foo_int__SWIG_0, _swig_p) + return +} + +func NewFoo_int__SWIG_0(arg1 uint) (_swig_ret Foo_int) { + return _swig_wrap_new_Foo_int__SWIG_0(arg1) +} + +var _wrap_new_Foo_int__SWIG_1 unsafe.Pointer + +func _swig_wrap_new_Foo_int__SWIG_1() (base SwigcptrFoo_int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Foo_int__SWIG_1, _swig_p) + return +} + +func NewFoo_int__SWIG_1() (_swig_ret Foo_int) { + return _swig_wrap_new_Foo_int__SWIG_1() +} + +func NewFoo_int(a ...interface{}) Foo_int { + argc := len(a) + if argc == 0 { + return NewFoo_int__SWIG_1() + } + if argc == 1 { + return NewFoo_int__SWIG_0(a[0].(uint)) + } + panic("No match for overloaded function call") +} + +var _wrap_delete_Foo_int unsafe.Pointer + +func _swig_wrap_delete_Foo_int(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Foo_int, _swig_p) + return +} + +func DeleteFoo_int(arg1 Foo_int) { + _swig_wrap_delete_Foo_int(arg1.Swigcptr()) +} + +type Foo_int interface { + Swigcptr() uintptr + SwigIsFoo_int() +} + +type SwigcptrHello_int uintptr + +func (p SwigcptrHello_int) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrHello_int) SwigIsHello_int() { +} + +var _wrap_new_Hello_int__SWIG_0 unsafe.Pointer + +func _swig_wrap_new_Hello_int__SWIG_0(base uint) (_ SwigcptrHello_int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Hello_int__SWIG_0, _swig_p) + return +} + +func NewHello_int__SWIG_0(arg1 uint) (_swig_ret Hello_int) { + return _swig_wrap_new_Hello_int__SWIG_0(arg1) +} + +var _wrap_new_Hello_int__SWIG_1 unsafe.Pointer + +func _swig_wrap_new_Hello_int__SWIG_1() (base SwigcptrHello_int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Hello_int__SWIG_1, _swig_p) + return +} + +func NewHello_int__SWIG_1() (_swig_ret Hello_int) { + return _swig_wrap_new_Hello_int__SWIG_1() +} + +func NewHello_int(a ...interface{}) Hello_int { + argc := len(a) + if argc == 0 { + return NewHello_int__SWIG_1() + } + if argc == 1 { + return NewHello_int__SWIG_0(a[0].(uint)) + } + panic("No match for overloaded function call") +} + +type Hello_Sl_int_Sg_Hi int +var _wrap_hi_Hello_int unsafe.Pointer + +func _swig_getHello_int_hi_Hello_int() (_swig_ret Hello_Sl_int_Sg_Hi) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_hi_Hello_int, _swig_p) + return +} +var Hello_intHi Hello_Sl_int_Sg_Hi = _swig_getHello_int_hi_Hello_int() +var _wrap_hello_Hello_int unsafe.Pointer + +func _swig_getHello_int_hello_Hello_int() (_swig_ret Hello_Sl_int_Sg_Hi) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_hello_Hello_int, _swig_p) + return +} +var Hello_intHello Hello_Sl_int_Sg_Hi = _swig_getHello_int_hello_Hello_int() +var _wrap_Hello_int_foo__SWIG_0 unsafe.Pointer + +func _swig_wrap_Hello_int_foo__SWIG_0(base SwigcptrHello_int, _ Hello_Sl_int_Sg_Hi) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Hello_int_foo__SWIG_0, _swig_p) + return +} + +func (arg1 SwigcptrHello_int) Foo__SWIG_0(arg2 Hello_Sl_int_Sg_Hi) { + _swig_wrap_Hello_int_foo__SWIG_0(arg1, arg2) +} + +var _wrap_Hello_int_foo__SWIG_1 unsafe.Pointer + +func _swig_wrap_Hello_int_foo__SWIG_1(base SwigcptrHello_int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Hello_int_foo__SWIG_1, _swig_p) + return +} + +func (arg1 SwigcptrHello_int) Foo__SWIG_1() { + _swig_wrap_Hello_int_foo__SWIG_1(arg1) +} + +func (p SwigcptrHello_int) Foo(a ...interface{}) { + argc := len(a) + if argc == 0 { + p.Foo__SWIG_1() + return + } + if argc == 1 { + p.Foo__SWIG_0(a[0].(Hello_Sl_int_Sg_Hi)) + return + } + panic("No match for overloaded function call") +} + +var _wrap_delete_Hello_int unsafe.Pointer + +func _swig_wrap_delete_Hello_int(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Hello_int, _swig_p) + return +} + +func DeleteHello_int(arg1 Hello_int) { + _swig_wrap_delete_Hello_int(arg1.Swigcptr()) +} + +type Hello_int interface { + Swigcptr() uintptr + SwigIsHello_int() + Foo(a ...interface{}) +} + +type SwigcptrX_int uintptr + +func (p SwigcptrX_int) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrX_int) SwigIsX_int() { +} + +var _wrap_new_X_int__SWIG_0 unsafe.Pointer + +func _swig_wrap_new_X_int__SWIG_0(base int) (_ SwigcptrX_int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_X_int__SWIG_0, _swig_p) + return +} + +func NewX_int__SWIG_0(arg1 int) (_swig_ret X_int) { + return _swig_wrap_new_X_int__SWIG_0(arg1) +} + +var _wrap_new_X_int__SWIG_1 unsafe.Pointer + +func _swig_wrap_new_X_int__SWIG_1() (base SwigcptrX_int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_X_int__SWIG_1, _swig_p) + return +} + +func NewX_int__SWIG_1() (_swig_ret X_int) { + return _swig_wrap_new_X_int__SWIG_1() +} + +var _wrap_new_X_int__SWIG_2 unsafe.Pointer + +func _swig_wrap_new_X_int__SWIG_2(base float64, _ int) (_ SwigcptrX_int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_X_int__SWIG_2, _swig_p) + return +} + +func NewX_int__SWIG_2(arg1 float64, arg2 int) (_swig_ret X_int) { + return _swig_wrap_new_X_int__SWIG_2(arg1, arg2) +} + +var _wrap_new_X_int__SWIG_3 unsafe.Pointer + +func _swig_wrap_new_X_int__SWIG_3(base float64) (_ SwigcptrX_int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_X_int__SWIG_3, _swig_p) + return +} + +func NewX_int__SWIG_3(arg1 float64) (_swig_ret X_int) { + return _swig_wrap_new_X_int__SWIG_3(arg1) +} + +func NewX_int(a ...interface{}) X_int { + argc := len(a) + if argc == 0 { + return NewX_int__SWIG_1() + } + if argc == 1 { + if _, ok := a[0].(int); !ok { + goto check_2 + } + return NewX_int__SWIG_0(a[0].(int)) + } +check_2: + if argc == 1 { + return NewX_int__SWIG_3(a[0].(float64)) + } + if argc == 2 { + return NewX_int__SWIG_2(a[0].(float64), a[1].(int)) + } + panic("No match for overloaded function call") +} + +var _wrap_X_int_meth__SWIG_0 unsafe.Pointer + +func _swig_wrap_X_int_meth__SWIG_0(base SwigcptrX_int, _ float64, _ int) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_X_int_meth__SWIG_0, _swig_p) + return +} + +func (arg1 SwigcptrX_int) Meth__SWIG_0(arg2 float64, arg3 int) (_swig_ret int) { + return _swig_wrap_X_int_meth__SWIG_0(arg1, arg2, arg3) +} + +var _wrap_X_int_meth__SWIG_1 unsafe.Pointer + +func _swig_wrap_X_int_meth__SWIG_1(base SwigcptrX_int, _ float64) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_X_int_meth__SWIG_1, _swig_p) + return +} + +func (arg1 SwigcptrX_int) Meth__SWIG_1(arg2 float64) (_swig_ret int) { + return _swig_wrap_X_int_meth__SWIG_1(arg1, arg2) +} + +var _wrap_X_int_meth__SWIG_2 unsafe.Pointer + +func _swig_wrap_X_int_meth__SWIG_2(base SwigcptrX_int, _ int) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_X_int_meth__SWIG_2, _swig_p) + return +} + +func (arg1 SwigcptrX_int) Meth__SWIG_2(arg2 int) (_swig_ret int) { + return _swig_wrap_X_int_meth__SWIG_2(arg1, arg2) +} + +var _wrap_X_int_meth__SWIG_3 unsafe.Pointer + +func _swig_wrap_X_int_meth__SWIG_3(base SwigcptrX_int) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_X_int_meth__SWIG_3, _swig_p) + return +} + +func (arg1 SwigcptrX_int) Meth__SWIG_3() (_swig_ret int) { + return _swig_wrap_X_int_meth__SWIG_3(arg1) +} + +func (p SwigcptrX_int) Meth(a ...interface{}) interface{} { + argc := len(a) + if argc == 0 { + return p.Meth__SWIG_3() + } + if argc == 1 { + if _, ok := a[0].(int); !ok { + goto check_2 + } + return p.Meth__SWIG_2(a[0].(int)) + } +check_2: + if argc == 1 { + return p.Meth__SWIG_1(a[0].(float64)) + } + if argc == 2 { + return p.Meth__SWIG_0(a[0].(float64), a[1].(int)) + } + panic("No match for overloaded function call") +} + +var _wrap_delete_X_int unsafe.Pointer + +func _swig_wrap_delete_X_int(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_X_int, _swig_p) + return +} + +func DeleteX_int(arg1 X_int) { + _swig_wrap_delete_X_int(arg1.Swigcptr()) +} + +type X_int interface { + Swigcptr() uintptr + SwigIsX_int() + Meth(a ...interface{}) interface{} +} + +type SwigcptrX_longlong uintptr + +func (p SwigcptrX_longlong) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrX_longlong) SwigIsX_longlong() { +} + +var _wrap_new_X_longlong__SWIG_0 unsafe.Pointer + +func _swig_wrap_new_X_longlong__SWIG_0(base int64) (_ SwigcptrX_longlong) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_X_longlong__SWIG_0, _swig_p) + return +} + +func NewX_longlong__SWIG_0(arg1 int64) (_swig_ret X_longlong) { + return _swig_wrap_new_X_longlong__SWIG_0(arg1) +} + +var _wrap_new_X_longlong__SWIG_1 unsafe.Pointer + +func _swig_wrap_new_X_longlong__SWIG_1() (base SwigcptrX_longlong) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_X_longlong__SWIG_1, _swig_p) + return +} + +func NewX_longlong__SWIG_1() (_swig_ret X_longlong) { + return _swig_wrap_new_X_longlong__SWIG_1() +} + +var _wrap_new_X_longlong__SWIG_2 unsafe.Pointer + +func _swig_wrap_new_X_longlong__SWIG_2(base float64, _ int64) (_ SwigcptrX_longlong) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_X_longlong__SWIG_2, _swig_p) + return +} + +func NewX_longlong__SWIG_2(arg1 float64, arg2 int64) (_swig_ret X_longlong) { + return _swig_wrap_new_X_longlong__SWIG_2(arg1, arg2) +} + +var _wrap_new_X_longlong__SWIG_3 unsafe.Pointer + +func _swig_wrap_new_X_longlong__SWIG_3(base float64) (_ SwigcptrX_longlong) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_X_longlong__SWIG_3, _swig_p) + return +} + +func NewX_longlong__SWIG_3(arg1 float64) (_swig_ret X_longlong) { + return _swig_wrap_new_X_longlong__SWIG_3(arg1) +} + +func NewX_longlong(a ...interface{}) X_longlong { + argc := len(a) + if argc == 0 { + return NewX_longlong__SWIG_1() + } + if argc == 1 { + if _, ok := a[0].(int64); !ok { + goto check_2 + } + return NewX_longlong__SWIG_0(a[0].(int64)) + } +check_2: + if argc == 1 { + return NewX_longlong__SWIG_3(a[0].(float64)) + } + if argc == 2 { + return NewX_longlong__SWIG_2(a[0].(float64), a[1].(int64)) + } + panic("No match for overloaded function call") +} + +var _wrap_X_longlong_meth__SWIG_0 unsafe.Pointer + +func _swig_wrap_X_longlong_meth__SWIG_0(base SwigcptrX_longlong, _ float64, _ int64) (_ int64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_X_longlong_meth__SWIG_0, _swig_p) + return +} + +func (arg1 SwigcptrX_longlong) Meth__SWIG_0(arg2 float64, arg3 int64) (_swig_ret int64) { + return _swig_wrap_X_longlong_meth__SWIG_0(arg1, arg2, arg3) +} + +var _wrap_X_longlong_meth__SWIG_1 unsafe.Pointer + +func _swig_wrap_X_longlong_meth__SWIG_1(base SwigcptrX_longlong, _ float64) (_ int64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_X_longlong_meth__SWIG_1, _swig_p) + return +} + +func (arg1 SwigcptrX_longlong) Meth__SWIG_1(arg2 float64) (_swig_ret int64) { + return _swig_wrap_X_longlong_meth__SWIG_1(arg1, arg2) +} + +var _wrap_X_longlong_meth__SWIG_2 unsafe.Pointer + +func _swig_wrap_X_longlong_meth__SWIG_2(base SwigcptrX_longlong, _ int64) (_ int64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_X_longlong_meth__SWIG_2, _swig_p) + return +} + +func (arg1 SwigcptrX_longlong) Meth__SWIG_2(arg2 int64) (_swig_ret int64) { + return _swig_wrap_X_longlong_meth__SWIG_2(arg1, arg2) +} + +var _wrap_X_longlong_meth__SWIG_3 unsafe.Pointer + +func _swig_wrap_X_longlong_meth__SWIG_3(base SwigcptrX_longlong) (_ int64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_X_longlong_meth__SWIG_3, _swig_p) + return +} + +func (arg1 SwigcptrX_longlong) Meth__SWIG_3() (_swig_ret int64) { + return _swig_wrap_X_longlong_meth__SWIG_3(arg1) +} + +func (p SwigcptrX_longlong) Meth(a ...interface{}) interface{} { + argc := len(a) + if argc == 0 { + return p.Meth__SWIG_3() + } + if argc == 1 { + if _, ok := a[0].(int64); !ok { + goto check_2 + } + return p.Meth__SWIG_2(a[0].(int64)) + } +check_2: + if argc == 1 { + return p.Meth__SWIG_1(a[0].(float64)) + } + if argc == 2 { + return p.Meth__SWIG_0(a[0].(float64), a[1].(int64)) + } + panic("No match for overloaded function call") +} + +var _wrap_delete_X_longlong unsafe.Pointer + +func _swig_wrap_delete_X_longlong(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_X_longlong, _swig_p) + return +} + +func DeleteX_longlong(arg1 X_longlong) { + _swig_wrap_delete_X_longlong(arg1.Swigcptr()) +} + +type X_longlong interface { + Swigcptr() uintptr + SwigIsX_longlong() + Meth(a ...interface{}) interface{} +} + +type SwigcptrX_unsigned uintptr + +func (p SwigcptrX_unsigned) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrX_unsigned) SwigIsX_unsigned() { +} + +var _wrap_new_X_unsigned__SWIG_0 unsafe.Pointer + +func _swig_wrap_new_X_unsigned__SWIG_0(base uint) (_ SwigcptrX_unsigned) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_X_unsigned__SWIG_0, _swig_p) + return +} + +func NewX_unsigned__SWIG_0(arg1 uint) (_swig_ret X_unsigned) { + return _swig_wrap_new_X_unsigned__SWIG_0(arg1) +} + +var _wrap_new_X_unsigned__SWIG_1 unsafe.Pointer + +func _swig_wrap_new_X_unsigned__SWIG_1() (base SwigcptrX_unsigned) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_X_unsigned__SWIG_1, _swig_p) + return +} + +func NewX_unsigned__SWIG_1() (_swig_ret X_unsigned) { + return _swig_wrap_new_X_unsigned__SWIG_1() +} + +var _wrap_new_X_unsigned__SWIG_2 unsafe.Pointer + +func _swig_wrap_new_X_unsigned__SWIG_2(base float64, _ uint) (_ SwigcptrX_unsigned) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_X_unsigned__SWIG_2, _swig_p) + return +} + +func NewX_unsigned__SWIG_2(arg1 float64, arg2 uint) (_swig_ret X_unsigned) { + return _swig_wrap_new_X_unsigned__SWIG_2(arg1, arg2) +} + +var _wrap_new_X_unsigned__SWIG_3 unsafe.Pointer + +func _swig_wrap_new_X_unsigned__SWIG_3(base float64) (_ SwigcptrX_unsigned) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_X_unsigned__SWIG_3, _swig_p) + return +} + +func NewX_unsigned__SWIG_3(arg1 float64) (_swig_ret X_unsigned) { + return _swig_wrap_new_X_unsigned__SWIG_3(arg1) +} + +func NewX_unsigned(a ...interface{}) X_unsigned { + argc := len(a) + if argc == 0 { + return NewX_unsigned__SWIG_1() + } + if argc == 1 { + if _, ok := a[0].(uint); !ok { + goto check_2 + } + return NewX_unsigned__SWIG_0(a[0].(uint)) + } +check_2: + if argc == 1 { + return NewX_unsigned__SWIG_3(a[0].(float64)) + } + if argc == 2 { + return NewX_unsigned__SWIG_2(a[0].(float64), a[1].(uint)) + } + panic("No match for overloaded function call") +} + +var _wrap_X_unsigned_meth__SWIG_0 unsafe.Pointer + +func _swig_wrap_X_unsigned_meth__SWIG_0(base SwigcptrX_unsigned, _ float64, _ uint) (_ uint) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_X_unsigned_meth__SWIG_0, _swig_p) + return +} + +func (arg1 SwigcptrX_unsigned) Meth__SWIG_0(arg2 float64, arg3 uint) (_swig_ret uint) { + return _swig_wrap_X_unsigned_meth__SWIG_0(arg1, arg2, arg3) +} + +var _wrap_X_unsigned_meth__SWIG_1 unsafe.Pointer + +func _swig_wrap_X_unsigned_meth__SWIG_1(base SwigcptrX_unsigned, _ float64) (_ uint) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_X_unsigned_meth__SWIG_1, _swig_p) + return +} + +func (arg1 SwigcptrX_unsigned) Meth__SWIG_1(arg2 float64) (_swig_ret uint) { + return _swig_wrap_X_unsigned_meth__SWIG_1(arg1, arg2) +} + +var _wrap_X_unsigned_meth__SWIG_2 unsafe.Pointer + +func _swig_wrap_X_unsigned_meth__SWIG_2(base SwigcptrX_unsigned, _ uint) (_ uint) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_X_unsigned_meth__SWIG_2, _swig_p) + return +} + +func (arg1 SwigcptrX_unsigned) Meth__SWIG_2(arg2 uint) (_swig_ret uint) { + return _swig_wrap_X_unsigned_meth__SWIG_2(arg1, arg2) +} + +var _wrap_X_unsigned_meth__SWIG_3 unsafe.Pointer + +func _swig_wrap_X_unsigned_meth__SWIG_3(base SwigcptrX_unsigned) (_ uint) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_X_unsigned_meth__SWIG_3, _swig_p) + return +} + +func (arg1 SwigcptrX_unsigned) Meth__SWIG_3() (_swig_ret uint) { + return _swig_wrap_X_unsigned_meth__SWIG_3(arg1) +} + +func (p SwigcptrX_unsigned) Meth(a ...interface{}) interface{} { + argc := len(a) + if argc == 0 { + return p.Meth__SWIG_3() + } + if argc == 1 { + if _, ok := a[0].(uint); !ok { + goto check_2 + } + return p.Meth__SWIG_2(a[0].(uint)) + } +check_2: + if argc == 1 { + return p.Meth__SWIG_1(a[0].(float64)) + } + if argc == 2 { + return p.Meth__SWIG_0(a[0].(float64), a[1].(uint)) + } + panic("No match for overloaded function call") +} + +var _wrap_delete_X_unsigned unsafe.Pointer + +func _swig_wrap_delete_X_unsigned(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_X_unsigned, _swig_p) + return +} + +func DeleteX_unsigned(arg1 X_unsigned) { + _swig_wrap_delete_X_unsigned(arg1.Swigcptr()) +} + +type X_unsigned interface { + Swigcptr() uintptr + SwigIsX_unsigned() + Meth(a ...interface{}) interface{} +} + +type SwigcptrY_unsigned uintptr + +func (p SwigcptrY_unsigned) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrY_unsigned) SwigIsY_unsigned() { +} + +var _wrap_Y_unsigned_meth_SWIG_0_0 unsafe.Pointer + +func _swig_wrap_Y_unsigned_meth_SWIG_0_0(base SwigcptrY_unsigned, _ float64, _ uint) (_ uint) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Y_unsigned_meth_SWIG_0_0, _swig_p) + return +} + +func (arg1 SwigcptrY_unsigned) Meth_SWIG_0_0(arg2 float64, arg3 uint) (_swig_ret uint) { + return _swig_wrap_Y_unsigned_meth_SWIG_0_0(arg1, arg2, arg3) +} + +var _wrap_Y_unsigned_meth_SWIG_0_1 unsafe.Pointer + +func _swig_wrap_Y_unsigned_meth_SWIG_0_1(base SwigcptrY_unsigned, _ float64) (_ uint) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Y_unsigned_meth_SWIG_0_1, _swig_p) + return +} + +func (arg1 SwigcptrY_unsigned) Meth_SWIG_0_1(arg2 float64) (_swig_ret uint) { + return _swig_wrap_Y_unsigned_meth_SWIG_0_1(arg1, arg2) +} + +var _wrap_Y_unsigned_meth_SWIG_0_2 unsafe.Pointer + +func _swig_wrap_Y_unsigned_meth_SWIG_0_2(base SwigcptrY_unsigned, _ uint) (_ uint) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Y_unsigned_meth_SWIG_0_2, _swig_p) + return +} + +func (arg1 SwigcptrY_unsigned) Meth_SWIG_0_2(arg2 uint) (_swig_ret uint) { + return _swig_wrap_Y_unsigned_meth_SWIG_0_2(arg1, arg2) +} + +var _wrap_Y_unsigned_meth_SWIG_0_3 unsafe.Pointer + +func _swig_wrap_Y_unsigned_meth_SWIG_0_3(base SwigcptrY_unsigned) (_ uint) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Y_unsigned_meth_SWIG_0_3, _swig_p) + return +} + +func (arg1 SwigcptrY_unsigned) Meth_SWIG_0_3() (_swig_ret uint) { + return _swig_wrap_Y_unsigned_meth_SWIG_0_3(arg1) +} + +func (p SwigcptrY_unsigned) Meth(a ...interface{}) interface{} { + argc := len(a) + if argc == 0 { + return p.Meth_SWIG_0_3() + } + if argc == 1 { + if _, ok := a[0].(uint); !ok { + goto check_2 + } + return p.Meth_SWIG_0_2(a[0].(uint)) + } +check_2: + if argc == 1 { + return p.Meth_SWIG_0_1(a[0].(float64)) + } + if argc == 2 { + return p.Meth_SWIG_0_0(a[0].(float64), a[1].(uint)) + } + panic("No match for overloaded function call") +} + +var _wrap_new_Y_unsigned unsafe.Pointer + +func _swig_wrap_new_Y_unsigned() (base SwigcptrY_unsigned) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Y_unsigned, _swig_p) + return +} + +func NewY_unsigned() (_swig_ret Y_unsigned) { + return _swig_wrap_new_Y_unsigned() +} + +var _wrap_delete_Y_unsigned unsafe.Pointer + +func _swig_wrap_delete_Y_unsigned(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Y_unsigned, _swig_p) + return +} + +func DeleteY_unsigned(arg1 Y_unsigned) { + _swig_wrap_delete_Y_unsigned(arg1.Swigcptr()) +} + +type Y_unsigned interface { + Swigcptr() uintptr + SwigIsY_unsigned() + Meth(a ...interface{}) interface{} +} + +type SwigcptrX_hello_unsigned uintptr + +func (p SwigcptrX_hello_unsigned) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrX_hello_unsigned) SwigIsX_hello_unsigned() { +} + +var _wrap_new_X_hello_unsigned__SWIG_0 unsafe.Pointer + +func _swig_wrap_new_X_hello_unsigned__SWIG_0(base uintptr) (_ SwigcptrX_hello_unsigned) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_X_hello_unsigned__SWIG_0, _swig_p) + return +} + +func NewX_hello_unsigned__SWIG_0(arg1 Hello_int) (_swig_ret X_hello_unsigned) { + return _swig_wrap_new_X_hello_unsigned__SWIG_0(arg1.Swigcptr()) +} + +var _wrap_new_X_hello_unsigned__SWIG_1 unsafe.Pointer + +func _swig_wrap_new_X_hello_unsigned__SWIG_1() (base SwigcptrX_hello_unsigned) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_X_hello_unsigned__SWIG_1, _swig_p) + return +} + +func NewX_hello_unsigned__SWIG_1() (_swig_ret X_hello_unsigned) { + return _swig_wrap_new_X_hello_unsigned__SWIG_1() +} + +var _wrap_new_X_hello_unsigned__SWIG_2 unsafe.Pointer + +func _swig_wrap_new_X_hello_unsigned__SWIG_2(base float64, _ uintptr) (_ SwigcptrX_hello_unsigned) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_X_hello_unsigned__SWIG_2, _swig_p) + return +} + +func NewX_hello_unsigned__SWIG_2(arg1 float64, arg2 Hello_int) (_swig_ret X_hello_unsigned) { + return _swig_wrap_new_X_hello_unsigned__SWIG_2(arg1, arg2.Swigcptr()) +} + +var _wrap_new_X_hello_unsigned__SWIG_3 unsafe.Pointer + +func _swig_wrap_new_X_hello_unsigned__SWIG_3(base float64) (_ SwigcptrX_hello_unsigned) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_X_hello_unsigned__SWIG_3, _swig_p) + return +} + +func NewX_hello_unsigned__SWIG_3(arg1 float64) (_swig_ret X_hello_unsigned) { + return _swig_wrap_new_X_hello_unsigned__SWIG_3(arg1) +} + +func NewX_hello_unsigned(a ...interface{}) X_hello_unsigned { + argc := len(a) + if argc == 0 { + return NewX_hello_unsigned__SWIG_1() + } + if argc == 1 { + if _, ok := a[0].(Hello_int); !ok { + goto check_2 + } + return NewX_hello_unsigned__SWIG_0(a[0].(Hello_int)) + } +check_2: + if argc == 1 { + return NewX_hello_unsigned__SWIG_3(a[0].(float64)) + } + if argc == 2 { + return NewX_hello_unsigned__SWIG_2(a[0].(float64), a[1].(Hello_int)) + } + panic("No match for overloaded function call") +} + +var _wrap_X_hello_unsigned_meth__SWIG_0 unsafe.Pointer + +func _swig_wrap_X_hello_unsigned_meth__SWIG_0(base SwigcptrX_hello_unsigned, _ float64, _ uintptr) (_ SwigcptrHello_int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_X_hello_unsigned_meth__SWIG_0, _swig_p) + return +} + +func (arg1 SwigcptrX_hello_unsigned) Meth__SWIG_0(arg2 float64, arg3 Hello_int) (_swig_ret Hello_int) { + return _swig_wrap_X_hello_unsigned_meth__SWIG_0(arg1, arg2, arg3.Swigcptr()) +} + +var _wrap_X_hello_unsigned_meth__SWIG_1 unsafe.Pointer + +func _swig_wrap_X_hello_unsigned_meth__SWIG_1(base SwigcptrX_hello_unsigned, _ float64) (_ SwigcptrHello_int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_X_hello_unsigned_meth__SWIG_1, _swig_p) + return +} + +func (arg1 SwigcptrX_hello_unsigned) Meth__SWIG_1(arg2 float64) (_swig_ret Hello_int) { + return _swig_wrap_X_hello_unsigned_meth__SWIG_1(arg1, arg2) +} + +var _wrap_X_hello_unsigned_meth__SWIG_2 unsafe.Pointer + +func _swig_wrap_X_hello_unsigned_meth__SWIG_2(base SwigcptrX_hello_unsigned, _ uintptr) (_ SwigcptrHello_int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_X_hello_unsigned_meth__SWIG_2, _swig_p) + return +} + +func (arg1 SwigcptrX_hello_unsigned) Meth__SWIG_2(arg2 Hello_int) (_swig_ret Hello_int) { + return _swig_wrap_X_hello_unsigned_meth__SWIG_2(arg1, arg2.Swigcptr()) +} + +var _wrap_X_hello_unsigned_meth__SWIG_3 unsafe.Pointer + +func _swig_wrap_X_hello_unsigned_meth__SWIG_3(base SwigcptrX_hello_unsigned) (_ SwigcptrHello_int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_X_hello_unsigned_meth__SWIG_3, _swig_p) + return +} + +func (arg1 SwigcptrX_hello_unsigned) Meth__SWIG_3() (_swig_ret Hello_int) { + return _swig_wrap_X_hello_unsigned_meth__SWIG_3(arg1) +} + +func (p SwigcptrX_hello_unsigned) Meth(a ...interface{}) interface{} { + argc := len(a) + if argc == 0 { + return p.Meth__SWIG_3() + } + if argc == 1 { + if _, ok := a[0].(Hello_int); !ok { + goto check_2 + } + return p.Meth__SWIG_2(a[0].(Hello_int)) + } +check_2: + if argc == 1 { + return p.Meth__SWIG_1(a[0].(float64)) + } + if argc == 2 { + return p.Meth__SWIG_0(a[0].(float64), a[1].(Hello_int)) + } + panic("No match for overloaded function call") +} + +var _wrap_delete_X_hello_unsigned unsafe.Pointer + +func _swig_wrap_delete_X_hello_unsigned(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_X_hello_unsigned, _swig_p) + return +} + +func DeleteX_hello_unsigned(arg1 X_hello_unsigned) { + _swig_wrap_delete_X_hello_unsigned(arg1.Swigcptr()) +} + +type X_hello_unsigned interface { + Swigcptr() uintptr + SwigIsX_hello_unsigned() + Meth(a ...interface{}) interface{} +} + +type SwigcptrY_hello_unsigned uintptr + +func (p SwigcptrY_hello_unsigned) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrY_hello_unsigned) SwigIsY_hello_unsigned() { +} + +var _wrap_Y_hello_unsigned_meth_SWIG_0_0 unsafe.Pointer + +func _swig_wrap_Y_hello_unsigned_meth_SWIG_0_0(base SwigcptrY_hello_unsigned, _ float64, _ uintptr) (_ SwigcptrHello_int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Y_hello_unsigned_meth_SWIG_0_0, _swig_p) + return +} + +func (arg1 SwigcptrY_hello_unsigned) Meth_SWIG_0_0(arg2 float64, arg3 Hello_int) (_swig_ret Hello_int) { + return _swig_wrap_Y_hello_unsigned_meth_SWIG_0_0(arg1, arg2, arg3.Swigcptr()) +} + +var _wrap_Y_hello_unsigned_meth_SWIG_0_1 unsafe.Pointer + +func _swig_wrap_Y_hello_unsigned_meth_SWIG_0_1(base SwigcptrY_hello_unsigned, _ float64) (_ SwigcptrHello_int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Y_hello_unsigned_meth_SWIG_0_1, _swig_p) + return +} + +func (arg1 SwigcptrY_hello_unsigned) Meth_SWIG_0_1(arg2 float64) (_swig_ret Hello_int) { + return _swig_wrap_Y_hello_unsigned_meth_SWIG_0_1(arg1, arg2) +} + +var _wrap_Y_hello_unsigned_meth_SWIG_0_2 unsafe.Pointer + +func _swig_wrap_Y_hello_unsigned_meth_SWIG_0_2(base SwigcptrY_hello_unsigned, _ uintptr) (_ SwigcptrHello_int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Y_hello_unsigned_meth_SWIG_0_2, _swig_p) + return +} + +func (arg1 SwigcptrY_hello_unsigned) Meth_SWIG_0_2(arg2 Hello_int) (_swig_ret Hello_int) { + return _swig_wrap_Y_hello_unsigned_meth_SWIG_0_2(arg1, arg2.Swigcptr()) +} + +var _wrap_Y_hello_unsigned_meth_SWIG_0_3 unsafe.Pointer + +func _swig_wrap_Y_hello_unsigned_meth_SWIG_0_3(base SwigcptrY_hello_unsigned) (_ SwigcptrHello_int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Y_hello_unsigned_meth_SWIG_0_3, _swig_p) + return +} + +func (arg1 SwigcptrY_hello_unsigned) Meth_SWIG_0_3() (_swig_ret Hello_int) { + return _swig_wrap_Y_hello_unsigned_meth_SWIG_0_3(arg1) +} + +func (p SwigcptrY_hello_unsigned) Meth(a ...interface{}) interface{} { + argc := len(a) + if argc == 0 { + return p.Meth_SWIG_0_3() + } + if argc == 1 { + if _, ok := a[0].(Hello_int); !ok { + goto check_2 + } + return p.Meth_SWIG_0_2(a[0].(Hello_int)) + } +check_2: + if argc == 1 { + return p.Meth_SWIG_0_1(a[0].(float64)) + } + if argc == 2 { + return p.Meth_SWIG_0_0(a[0].(float64), a[1].(Hello_int)) + } + panic("No match for overloaded function call") +} + +var _wrap_new_Y_hello_unsigned unsafe.Pointer + +func _swig_wrap_new_Y_hello_unsigned() (base SwigcptrY_hello_unsigned) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Y_hello_unsigned, _swig_p) + return +} + +func NewY_hello_unsigned() (_swig_ret Y_hello_unsigned) { + return _swig_wrap_new_Y_hello_unsigned() +} + +var _wrap_delete_Y_hello_unsigned unsafe.Pointer + +func _swig_wrap_delete_Y_hello_unsigned(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Y_hello_unsigned, _swig_p) + return +} + +func DeleteY_hello_unsigned(arg1 Y_hello_unsigned) { + _swig_wrap_delete_Y_hello_unsigned(arg1.Swigcptr()) +} + +type Y_hello_unsigned interface { + Swigcptr() uintptr + SwigIsY_hello_unsigned() + Meth(a ...interface{}) interface{} +} + +type SwigcptrX_Foo_Foo_int uintptr + +func (p SwigcptrX_Foo_Foo_int) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrX_Foo_Foo_int) SwigIsX_Foo_Foo_int() { +} + +var _wrap_new_X_Foo_Foo_int__SWIG_0 unsafe.Pointer + +func _swig_wrap_new_X_Foo_Foo_int__SWIG_0(base uintptr) (_ SwigcptrX_Foo_Foo_int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_X_Foo_Foo_int__SWIG_0, _swig_p) + return +} + +func NewX_Foo_Foo_int__SWIG_0(arg1 Foo_Sl_Foo_Sl_int_Sg__Sg_) (_swig_ret X_Foo_Foo_int) { + return _swig_wrap_new_X_Foo_Foo_int__SWIG_0(arg1.Swigcptr()) +} + +var _wrap_new_X_Foo_Foo_int__SWIG_1 unsafe.Pointer + +func _swig_wrap_new_X_Foo_Foo_int__SWIG_1() (base SwigcptrX_Foo_Foo_int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_X_Foo_Foo_int__SWIG_1, _swig_p) + return +} + +func NewX_Foo_Foo_int__SWIG_1() (_swig_ret X_Foo_Foo_int) { + return _swig_wrap_new_X_Foo_Foo_int__SWIG_1() +} + +var _wrap_new_X_Foo_Foo_int__SWIG_2 unsafe.Pointer + +func _swig_wrap_new_X_Foo_Foo_int__SWIG_2(base float64, _ uintptr) (_ SwigcptrX_Foo_Foo_int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_X_Foo_Foo_int__SWIG_2, _swig_p) + return +} + +func NewX_Foo_Foo_int__SWIG_2(arg1 float64, arg2 Foo_Sl_Foo_Sl_int_Sg__Sg_) (_swig_ret X_Foo_Foo_int) { + return _swig_wrap_new_X_Foo_Foo_int__SWIG_2(arg1, arg2.Swigcptr()) +} + +var _wrap_new_X_Foo_Foo_int__SWIG_3 unsafe.Pointer + +func _swig_wrap_new_X_Foo_Foo_int__SWIG_3(base float64) (_ SwigcptrX_Foo_Foo_int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_X_Foo_Foo_int__SWIG_3, _swig_p) + return +} + +func NewX_Foo_Foo_int__SWIG_3(arg1 float64) (_swig_ret X_Foo_Foo_int) { + return _swig_wrap_new_X_Foo_Foo_int__SWIG_3(arg1) +} + +func NewX_Foo_Foo_int(a ...interface{}) X_Foo_Foo_int { + argc := len(a) + if argc == 0 { + return NewX_Foo_Foo_int__SWIG_1() + } + if argc == 1 { + if _, ok := a[0].(Foo_Sl_Foo_Sl_int_Sg__Sg_); !ok { + goto check_2 + } + return NewX_Foo_Foo_int__SWIG_0(a[0].(Foo_Sl_Foo_Sl_int_Sg__Sg_)) + } +check_2: + if argc == 1 { + return NewX_Foo_Foo_int__SWIG_3(a[0].(float64)) + } + if argc == 2 { + return NewX_Foo_Foo_int__SWIG_2(a[0].(float64), a[1].(Foo_Sl_Foo_Sl_int_Sg__Sg_)) + } + panic("No match for overloaded function call") +} + +var _wrap_X_Foo_Foo_int_meth__SWIG_0 unsafe.Pointer + +func _swig_wrap_X_Foo_Foo_int_meth__SWIG_0(base SwigcptrX_Foo_Foo_int, _ float64, _ uintptr) (_ SwigcptrFoo_Sl_Foo_Sl_int_Sg__Sg_) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_X_Foo_Foo_int_meth__SWIG_0, _swig_p) + return +} + +func (arg1 SwigcptrX_Foo_Foo_int) Meth__SWIG_0(arg2 float64, arg3 Foo_Sl_Foo_Sl_int_Sg__Sg_) (_swig_ret Foo_Sl_Foo_Sl_int_Sg__Sg_) { + return _swig_wrap_X_Foo_Foo_int_meth__SWIG_0(arg1, arg2, arg3.Swigcptr()) +} + +var _wrap_X_Foo_Foo_int_meth__SWIG_1 unsafe.Pointer + +func _swig_wrap_X_Foo_Foo_int_meth__SWIG_1(base SwigcptrX_Foo_Foo_int, _ float64) (_ SwigcptrFoo_Sl_Foo_Sl_int_Sg__Sg_) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_X_Foo_Foo_int_meth__SWIG_1, _swig_p) + return +} + +func (arg1 SwigcptrX_Foo_Foo_int) Meth__SWIG_1(arg2 float64) (_swig_ret Foo_Sl_Foo_Sl_int_Sg__Sg_) { + return _swig_wrap_X_Foo_Foo_int_meth__SWIG_1(arg1, arg2) +} + +var _wrap_X_Foo_Foo_int_meth__SWIG_2 unsafe.Pointer + +func _swig_wrap_X_Foo_Foo_int_meth__SWIG_2(base SwigcptrX_Foo_Foo_int, _ uintptr) (_ SwigcptrFoo_Sl_Foo_Sl_int_Sg__Sg_) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_X_Foo_Foo_int_meth__SWIG_2, _swig_p) + return +} + +func (arg1 SwigcptrX_Foo_Foo_int) Meth__SWIG_2(arg2 Foo_Sl_Foo_Sl_int_Sg__Sg_) (_swig_ret Foo_Sl_Foo_Sl_int_Sg__Sg_) { + return _swig_wrap_X_Foo_Foo_int_meth__SWIG_2(arg1, arg2.Swigcptr()) +} + +var _wrap_X_Foo_Foo_int_meth__SWIG_3 unsafe.Pointer + +func _swig_wrap_X_Foo_Foo_int_meth__SWIG_3(base SwigcptrX_Foo_Foo_int) (_ SwigcptrFoo_Sl_Foo_Sl_int_Sg__Sg_) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_X_Foo_Foo_int_meth__SWIG_3, _swig_p) + return +} + +func (arg1 SwigcptrX_Foo_Foo_int) Meth__SWIG_3() (_swig_ret Foo_Sl_Foo_Sl_int_Sg__Sg_) { + return _swig_wrap_X_Foo_Foo_int_meth__SWIG_3(arg1) +} + +func (p SwigcptrX_Foo_Foo_int) Meth(a ...interface{}) interface{} { + argc := len(a) + if argc == 0 { + return p.Meth__SWIG_3() + } + if argc == 1 { + if _, ok := a[0].(Foo_Sl_Foo_Sl_int_Sg__Sg_); !ok { + goto check_2 + } + return p.Meth__SWIG_2(a[0].(Foo_Sl_Foo_Sl_int_Sg__Sg_)) + } +check_2: + if argc == 1 { + return p.Meth__SWIG_1(a[0].(float64)) + } + if argc == 2 { + return p.Meth__SWIG_0(a[0].(float64), a[1].(Foo_Sl_Foo_Sl_int_Sg__Sg_)) + } + panic("No match for overloaded function call") +} + +var _wrap_delete_X_Foo_Foo_int unsafe.Pointer + +func _swig_wrap_delete_X_Foo_Foo_int(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_X_Foo_Foo_int, _swig_p) + return +} + +func DeleteX_Foo_Foo_int(arg1 X_Foo_Foo_int) { + _swig_wrap_delete_X_Foo_Foo_int(arg1.Swigcptr()) +} + +type X_Foo_Foo_int interface { + Swigcptr() uintptr + SwigIsX_Foo_Foo_int() + Meth(a ...interface{}) interface{} +} + +type SwigcptrZ_8 uintptr + +func (p SwigcptrZ_8) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrZ_8) SwigIsZ_8() { +} + +var _wrap_new_Z_8__SWIG_0 unsafe.Pointer + +func _swig_wrap_new_Z_8__SWIG_0(base int) (_ SwigcptrZ_8) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Z_8__SWIG_0, _swig_p) + return +} + +func NewZ_8__SWIG_0(arg1 int) (_swig_ret Z_8) { + return _swig_wrap_new_Z_8__SWIG_0(arg1) +} + +var _wrap_new_Z_8__SWIG_1 unsafe.Pointer + +func _swig_wrap_new_Z_8__SWIG_1() (base SwigcptrZ_8) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Z_8__SWIG_1, _swig_p) + return +} + +func NewZ_8__SWIG_1() (_swig_ret Z_8) { + return _swig_wrap_new_Z_8__SWIG_1() +} + +var _wrap_new_Z_8__SWIG_2 unsafe.Pointer + +func _swig_wrap_new_Z_8__SWIG_2(base float64, _ int) (_ SwigcptrZ_8) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Z_8__SWIG_2, _swig_p) + return +} + +func NewZ_8__SWIG_2(arg1 float64, arg2 int) (_swig_ret Z_8) { + return _swig_wrap_new_Z_8__SWIG_2(arg1, arg2) +} + +var _wrap_new_Z_8__SWIG_3 unsafe.Pointer + +func _swig_wrap_new_Z_8__SWIG_3(base float64) (_ SwigcptrZ_8) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Z_8__SWIG_3, _swig_p) + return +} + +func NewZ_8__SWIG_3(arg1 float64) (_swig_ret Z_8) { + return _swig_wrap_new_Z_8__SWIG_3(arg1) +} + +func NewZ_8(a ...interface{}) Z_8 { + argc := len(a) + if argc == 0 { + return NewZ_8__SWIG_1() + } + if argc == 1 { + if _, ok := a[0].(int); !ok { + goto check_2 + } + return NewZ_8__SWIG_0(a[0].(int)) + } +check_2: + if argc == 1 { + return NewZ_8__SWIG_3(a[0].(float64)) + } + if argc == 2 { + return NewZ_8__SWIG_2(a[0].(float64), a[1].(int)) + } + panic("No match for overloaded function call") +} + +var _wrap_delete_Z_8 unsafe.Pointer + +func _swig_wrap_delete_Z_8(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Z_8, _swig_p) + return +} + +func DeleteZ_8(arg1 Z_8) { + _swig_wrap_delete_Z_8(arg1.Swigcptr()) +} + +type Z_8 interface { + Swigcptr() uintptr + SwigIsZ_8() +} + +type SwigcptrFoo_Z_8 uintptr + +func (p SwigcptrFoo_Z_8) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrFoo_Z_8) SwigIsFoo_Z_8() { +} + +var _wrap_new_Foo_Z_8__SWIG_0 unsafe.Pointer + +func _swig_wrap_new_Foo_Z_8__SWIG_0(base uint) (_ SwigcptrFoo_Z_8) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Foo_Z_8__SWIG_0, _swig_p) + return +} + +func NewFoo_Z_8__SWIG_0(arg1 uint) (_swig_ret Foo_Z_8) { + return _swig_wrap_new_Foo_Z_8__SWIG_0(arg1) +} + +var _wrap_new_Foo_Z_8__SWIG_1 unsafe.Pointer + +func _swig_wrap_new_Foo_Z_8__SWIG_1() (base SwigcptrFoo_Z_8) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Foo_Z_8__SWIG_1, _swig_p) + return +} + +func NewFoo_Z_8__SWIG_1() (_swig_ret Foo_Z_8) { + return _swig_wrap_new_Foo_Z_8__SWIG_1() +} + +func NewFoo_Z_8(a ...interface{}) Foo_Z_8 { + argc := len(a) + if argc == 0 { + return NewFoo_Z_8__SWIG_1() + } + if argc == 1 { + return NewFoo_Z_8__SWIG_0(a[0].(uint)) + } + panic("No match for overloaded function call") +} + +var _wrap_delete_Foo_Z_8 unsafe.Pointer + +func _swig_wrap_delete_Foo_Z_8(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Foo_Z_8, _swig_p) + return +} + +func DeleteFoo_Z_8(arg1 Foo_Z_8) { + _swig_wrap_delete_Foo_Z_8(arg1.Swigcptr()) +} + +type Foo_Z_8 interface { + Swigcptr() uintptr + SwigIsFoo_Z_8() +} + +type SwigcptrX_Foo_Z_8 uintptr + +func (p SwigcptrX_Foo_Z_8) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrX_Foo_Z_8) SwigIsX_Foo_Z_8() { +} + +var _wrap_new_X_Foo_Z_8__SWIG_0 unsafe.Pointer + +func _swig_wrap_new_X_Foo_Z_8__SWIG_0(base uintptr) (_ SwigcptrX_Foo_Z_8) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_X_Foo_Z_8__SWIG_0, _swig_p) + return +} + +func NewX_Foo_Z_8__SWIG_0(arg1 Foo_Z_8) (_swig_ret X_Foo_Z_8) { + return _swig_wrap_new_X_Foo_Z_8__SWIG_0(arg1.Swigcptr()) +} + +var _wrap_new_X_Foo_Z_8__SWIG_1 unsafe.Pointer + +func _swig_wrap_new_X_Foo_Z_8__SWIG_1() (base SwigcptrX_Foo_Z_8) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_X_Foo_Z_8__SWIG_1, _swig_p) + return +} + +func NewX_Foo_Z_8__SWIG_1() (_swig_ret X_Foo_Z_8) { + return _swig_wrap_new_X_Foo_Z_8__SWIG_1() +} + +var _wrap_new_X_Foo_Z_8__SWIG_2 unsafe.Pointer + +func _swig_wrap_new_X_Foo_Z_8__SWIG_2(base float64, _ uintptr) (_ SwigcptrX_Foo_Z_8) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_X_Foo_Z_8__SWIG_2, _swig_p) + return +} + +func NewX_Foo_Z_8__SWIG_2(arg1 float64, arg2 Foo_Z_8) (_swig_ret X_Foo_Z_8) { + return _swig_wrap_new_X_Foo_Z_8__SWIG_2(arg1, arg2.Swigcptr()) +} + +var _wrap_new_X_Foo_Z_8__SWIG_3 unsafe.Pointer + +func _swig_wrap_new_X_Foo_Z_8__SWIG_3(base float64) (_ SwigcptrX_Foo_Z_8) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_X_Foo_Z_8__SWIG_3, _swig_p) + return +} + +func NewX_Foo_Z_8__SWIG_3(arg1 float64) (_swig_ret X_Foo_Z_8) { + return _swig_wrap_new_X_Foo_Z_8__SWIG_3(arg1) +} + +func NewX_Foo_Z_8(a ...interface{}) X_Foo_Z_8 { + argc := len(a) + if argc == 0 { + return NewX_Foo_Z_8__SWIG_1() + } + if argc == 1 { + if _, ok := a[0].(Foo_Z_8); !ok { + goto check_2 + } + return NewX_Foo_Z_8__SWIG_0(a[0].(Foo_Z_8)) + } +check_2: + if argc == 1 { + return NewX_Foo_Z_8__SWIG_3(a[0].(float64)) + } + if argc == 2 { + return NewX_Foo_Z_8__SWIG_2(a[0].(float64), a[1].(Foo_Z_8)) + } + panic("No match for overloaded function call") +} + +var _wrap_X_Foo_Z_8_meth__SWIG_0 unsafe.Pointer + +func _swig_wrap_X_Foo_Z_8_meth__SWIG_0(base SwigcptrX_Foo_Z_8, _ float64, _ uintptr) (_ SwigcptrFoo_Z_8) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_X_Foo_Z_8_meth__SWIG_0, _swig_p) + return +} + +func (arg1 SwigcptrX_Foo_Z_8) Meth__SWIG_0(arg2 float64, arg3 Foo_Z_8) (_swig_ret Foo_Z_8) { + return _swig_wrap_X_Foo_Z_8_meth__SWIG_0(arg1, arg2, arg3.Swigcptr()) +} + +var _wrap_X_Foo_Z_8_meth__SWIG_1 unsafe.Pointer + +func _swig_wrap_X_Foo_Z_8_meth__SWIG_1(base SwigcptrX_Foo_Z_8, _ float64) (_ SwigcptrFoo_Z_8) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_X_Foo_Z_8_meth__SWIG_1, _swig_p) + return +} + +func (arg1 SwigcptrX_Foo_Z_8) Meth__SWIG_1(arg2 float64) (_swig_ret Foo_Z_8) { + return _swig_wrap_X_Foo_Z_8_meth__SWIG_1(arg1, arg2) +} + +var _wrap_X_Foo_Z_8_meth__SWIG_2 unsafe.Pointer + +func _swig_wrap_X_Foo_Z_8_meth__SWIG_2(base SwigcptrX_Foo_Z_8, _ uintptr) (_ SwigcptrFoo_Z_8) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_X_Foo_Z_8_meth__SWIG_2, _swig_p) + return +} + +func (arg1 SwigcptrX_Foo_Z_8) Meth__SWIG_2(arg2 Foo_Z_8) (_swig_ret Foo_Z_8) { + return _swig_wrap_X_Foo_Z_8_meth__SWIG_2(arg1, arg2.Swigcptr()) +} + +var _wrap_X_Foo_Z_8_meth__SWIG_3 unsafe.Pointer + +func _swig_wrap_X_Foo_Z_8_meth__SWIG_3(base SwigcptrX_Foo_Z_8) (_ SwigcptrFoo_Z_8) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_X_Foo_Z_8_meth__SWIG_3, _swig_p) + return +} + +func (arg1 SwigcptrX_Foo_Z_8) Meth__SWIG_3() (_swig_ret Foo_Z_8) { + return _swig_wrap_X_Foo_Z_8_meth__SWIG_3(arg1) +} + +func (p SwigcptrX_Foo_Z_8) Meth(a ...interface{}) interface{} { + argc := len(a) + if argc == 0 { + return p.Meth__SWIG_3() + } + if argc == 1 { + if _, ok := a[0].(Foo_Z_8); !ok { + goto check_2 + } + return p.Meth__SWIG_2(a[0].(Foo_Z_8)) + } +check_2: + if argc == 1 { + return p.Meth__SWIG_1(a[0].(float64)) + } + if argc == 2 { + return p.Meth__SWIG_0(a[0].(float64), a[1].(Foo_Z_8)) + } + panic("No match for overloaded function call") +} + +var _wrap_delete_X_Foo_Z_8 unsafe.Pointer + +func _swig_wrap_delete_X_Foo_Z_8(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_X_Foo_Z_8, _swig_p) + return +} + +func DeleteX_Foo_Z_8(arg1 X_Foo_Z_8) { + _swig_wrap_delete_X_Foo_Z_8(arg1.Swigcptr()) +} + +type X_Foo_Z_8 interface { + Swigcptr() uintptr + SwigIsX_Foo_Z_8() + Meth(a ...interface{}) interface{} +} + +type SwigcptrBar uintptr + +func (p SwigcptrBar) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrBar) SwigIsBar() { +} + +var _wrap_new_Bar unsafe.Pointer + +func _swig_wrap_new_Bar(base uint) (_ SwigcptrBar) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Bar, _swig_p) + return +} + +func NewBar(arg1 uint) (_swig_ret Bar) { + return _swig_wrap_new_Bar(arg1) +} + +var _wrap_delete_Bar unsafe.Pointer + +func _swig_wrap_delete_Bar(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Bar, _swig_p) + return +} + +func DeleteBar(arg1 Bar) { + _swig_wrap_delete_Bar(arg1.Swigcptr()) +} + +var _wrap_Bar_foo__SWIG_0 unsafe.Pointer + +func _swig_wrap_Bar_foo__SWIG_0(base SwigcptrBar, _ Hello_Sl_int_Sg_Hi) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Bar_foo__SWIG_0, _swig_p) + return +} + +func (_swig_base SwigcptrBar) Foo__SWIG_0(arg1 Hello_Sl_int_Sg_Hi) { + _swig_wrap_Bar_foo__SWIG_0(_swig_base, arg1) +} + +var _wrap_Bar_foo__SWIG_1 unsafe.Pointer + +func _swig_wrap_Bar_foo__SWIG_1(base SwigcptrBar) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Bar_foo__SWIG_1, _swig_p) + return +} + +func (_swig_base SwigcptrBar) Foo__SWIG_1() { + _swig_wrap_Bar_foo__SWIG_1(_swig_base) +} + +func (p SwigcptrBar) Foo(a ...interface{}) { + argc := len(a) + if argc == 0 { + p.Foo__SWIG_1() + return + } + if argc == 1 { + p.Foo__SWIG_0(a[0].(Hello_Sl_int_Sg_Hi)) + return + } + panic("No match for overloaded function call") +} + +func (p SwigcptrBar) SwigIsHello_int() { +} + +func (p SwigcptrBar) SwigGetHello_int() Hello_int { + return SwigcptrHello_int(p.Swigcptr()) +} + +type Bar interface { + Swigcptr() uintptr + SwigIsBar() + Foo(a ...interface{}) + SwigIsHello_int() + SwigGetHello_int() Hello_int +} + +var _wrap_ott__SWIG_6 unsafe.Pointer + +func _swig_wrap_ott__SWIG_6(base uintptr) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_ott__SWIG_6, _swig_p) + return +} + +func Ott__SWIG_6(arg1 Foo_int) (_swig_ret int) { + return _swig_wrap_ott__SWIG_6(arg1.Swigcptr()) +} + +var _wrap_ott__SWIG_10 unsafe.Pointer + +func Ott__SWIG_10(arg1 int, arg2 int) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_ott__SWIG_10, _swig_p) + return +} +var _wrap_ott__SWIG_11 unsafe.Pointer + +func Ott__SWIG_11(arg1 int) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_ott__SWIG_11, _swig_p) + return +} +var _wrap_ott__SWIG_12 unsafe.Pointer + +func Ott__SWIG_12() (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_ott__SWIG_12, _swig_p) + return +} +var _wrap_ott__SWIG_13 unsafe.Pointer + +func Ott__SWIG_13(arg1 string, arg2 int, arg3 int) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_ott__SWIG_13, _swig_p) + return +} +var _wrap_ott__SWIG_14 unsafe.Pointer + +func Ott__SWIG_14(arg1 string, arg2 int) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_ott__SWIG_14, _swig_p) + return +} +var _wrap_ott__SWIG_15 unsafe.Pointer + +func Ott__SWIG_15(arg1 string) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_ott__SWIG_15, _swig_p) + return +} +var _wrap_ott__SWIG_16 unsafe.Pointer + +func _swig_wrap_ott__SWIG_16(base uintptr, _ float64) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_ott__SWIG_16, _swig_p) + return +} + +func Ott__SWIG_16(arg1 Hello_int, arg2 float64) (_swig_ret int) { + return _swig_wrap_ott__SWIG_16(arg1.Swigcptr(), arg2) +} + +var _wrap_ott__SWIG_17 unsafe.Pointer + +func _swig_wrap_ott__SWIG_17(base uintptr) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_ott__SWIG_17, _swig_p) + return +} + +func Ott__SWIG_17(arg1 Hello_int) (_swig_ret int) { + return _swig_wrap_ott__SWIG_17(arg1.Swigcptr()) +} + +func Ott(a ...interface{}) int { + argc := len(a) + if argc == 0 { + return Ott__SWIG_12() + } + if argc == 1 { + if _, ok := a[0].(Foo_int); !ok { + goto check_2 + } + return Ott__SWIG_6(a[0].(Foo_int)) + } +check_2: + if argc == 1 { + if _, ok := a[0].(Hello_int); !ok { + goto check_3 + } + return Ott__SWIG_17(a[0].(Hello_int)) + } +check_3: + if argc == 1 { + if _, ok := a[0].(int); !ok { + goto check_4 + } + return Ott__SWIG_11(a[0].(int)) + } +check_4: + if argc == 1 { + return Ott__SWIG_15(a[0].(string)) + } + if argc == 2 { + if _, ok := a[0].(Hello_int); !ok { + goto check_6 + } + if _, ok := a[1].(float64); !ok { + goto check_6 + } + return Ott__SWIG_16(a[0].(Hello_int), a[1].(float64)) + } +check_6: + if argc == 2 { + if _, ok := a[0].(int); !ok { + goto check_7 + } + return Ott__SWIG_10(a[0].(int), a[1].(int)) + } +check_7: + if argc == 2 { + return Ott__SWIG_14(a[0].(string), a[1].(int)) + } + if argc == 3 { + return Ott__SWIG_13(a[0].(string), a[1].(int), a[2].(int)) + } + panic("No match for overloaded function call") +} + +var _wrap_ottint__SWIG_0 unsafe.Pointer + +func _swig_wrap_ottint__SWIG_0(base uintptr, _ int) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_ottint__SWIG_0, _swig_p) + return +} + +func Ottint__SWIG_0(arg1 Hello_int, arg2 int) (_swig_ret int) { + return _swig_wrap_ottint__SWIG_0(arg1.Swigcptr(), arg2) +} + +var _wrap_ottint__SWIG_1 unsafe.Pointer + +func _swig_wrap_ottint__SWIG_1(base uintptr) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_ottint__SWIG_1, _swig_p) + return +} + +func Ottint__SWIG_1(arg1 Hello_int) (_swig_ret int) { + return _swig_wrap_ottint__SWIG_1(arg1.Swigcptr()) +} + +func Ottint(a ...interface{}) int { + argc := len(a) + if argc == 1 { + return Ottint__SWIG_1(a[0].(Hello_int)) + } + if argc == 2 { + return Ottint__SWIG_0(a[0].(Hello_int), a[1].(int)) + } + panic("No match for overloaded function call") +} + +var _wrap_ottstring__SWIG_0 unsafe.Pointer + +func _swig_wrap_ottstring__SWIG_0(base uintptr, _ string) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_ottstring__SWIG_0, _swig_p) + return +} + +func Ottstring__SWIG_0(arg1 Hello_int, arg2 string) (_swig_ret int) { + return _swig_wrap_ottstring__SWIG_0(arg1.Swigcptr(), arg2) +} + +var _wrap_ottstring__SWIG_1 unsafe.Pointer + +func _swig_wrap_ottstring__SWIG_1(base uintptr) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_ottstring__SWIG_1, _swig_p) + return +} + +func Ottstring__SWIG_1(arg1 Hello_int) (_swig_ret int) { + return _swig_wrap_ottstring__SWIG_1(arg1.Swigcptr()) +} + +func Ottstring(a ...interface{}) int { + argc := len(a) + if argc == 1 { + return Ottstring__SWIG_1(a[0].(Hello_int)) + } + if argc == 2 { + return Ottstring__SWIG_0(a[0].(Hello_int), a[1].(string)) + } + panic("No match for overloaded function call") +} + +var _wrap_nsott__SWIG_6 unsafe.Pointer + +func _swig_wrap_nsott__SWIG_6(base uintptr) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_nsott__SWIG_6, _swig_p) + return +} + +func Nsott__SWIG_6(arg1 Foo_int) (_swig_ret int) { + return _swig_wrap_nsott__SWIG_6(arg1.Swigcptr()) +} + +var _wrap_nsott__SWIG_10 unsafe.Pointer + +func Nsott__SWIG_10(arg1 int, arg2 int) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_nsott__SWIG_10, _swig_p) + return +} +var _wrap_nsott__SWIG_11 unsafe.Pointer + +func Nsott__SWIG_11(arg1 int) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_nsott__SWIG_11, _swig_p) + return +} +var _wrap_nsott__SWIG_12 unsafe.Pointer + +func Nsott__SWIG_12() (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_nsott__SWIG_12, _swig_p) + return +} +var _wrap_nsott__SWIG_13 unsafe.Pointer + +func Nsott__SWIG_13(arg1 string, arg2 int, arg3 int) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_nsott__SWIG_13, _swig_p) + return +} +var _wrap_nsott__SWIG_14 unsafe.Pointer + +func Nsott__SWIG_14(arg1 string, arg2 int) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_nsott__SWIG_14, _swig_p) + return +} +var _wrap_nsott__SWIG_15 unsafe.Pointer + +func Nsott__SWIG_15(arg1 string) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_nsott__SWIG_15, _swig_p) + return +} +var _wrap_nsott__SWIG_16 unsafe.Pointer + +func _swig_wrap_nsott__SWIG_16(base uintptr, _ float64) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_nsott__SWIG_16, _swig_p) + return +} + +func Nsott__SWIG_16(arg1 Hello_int, arg2 float64) (_swig_ret int) { + return _swig_wrap_nsott__SWIG_16(arg1.Swigcptr(), arg2) +} + +var _wrap_nsott__SWIG_17 unsafe.Pointer + +func _swig_wrap_nsott__SWIG_17(base uintptr) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_nsott__SWIG_17, _swig_p) + return +} + +func Nsott__SWIG_17(arg1 Hello_int) (_swig_ret int) { + return _swig_wrap_nsott__SWIG_17(arg1.Swigcptr()) +} + +func Nsott(a ...interface{}) int { + argc := len(a) + if argc == 0 { + return Nsott__SWIG_12() + } + if argc == 1 { + if _, ok := a[0].(Foo_int); !ok { + goto check_2 + } + return Nsott__SWIG_6(a[0].(Foo_int)) + } +check_2: + if argc == 1 { + if _, ok := a[0].(Hello_int); !ok { + goto check_3 + } + return Nsott__SWIG_17(a[0].(Hello_int)) + } +check_3: + if argc == 1 { + if _, ok := a[0].(int); !ok { + goto check_4 + } + return Nsott__SWIG_11(a[0].(int)) + } +check_4: + if argc == 1 { + return Nsott__SWIG_15(a[0].(string)) + } + if argc == 2 { + if _, ok := a[0].(Hello_int); !ok { + goto check_6 + } + if _, ok := a[1].(float64); !ok { + goto check_6 + } + return Nsott__SWIG_16(a[0].(Hello_int), a[1].(float64)) + } +check_6: + if argc == 2 { + if _, ok := a[0].(int); !ok { + goto check_7 + } + return Nsott__SWIG_10(a[0].(int), a[1].(int)) + } +check_7: + if argc == 2 { + return Nsott__SWIG_14(a[0].(string), a[1].(int)) + } + if argc == 3 { + return Nsott__SWIG_13(a[0].(string), a[1].(int), a[2].(int)) + } + panic("No match for overloaded function call") +} + +var _wrap_nsottint__SWIG_0 unsafe.Pointer + +func _swig_wrap_nsottint__SWIG_0(base uintptr, _ int) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_nsottint__SWIG_0, _swig_p) + return +} + +func Nsottint__SWIG_0(arg1 Hello_int, arg2 int) (_swig_ret int) { + return _swig_wrap_nsottint__SWIG_0(arg1.Swigcptr(), arg2) +} + +var _wrap_nsottint__SWIG_1 unsafe.Pointer + +func _swig_wrap_nsottint__SWIG_1(base uintptr) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_nsottint__SWIG_1, _swig_p) + return +} + +func Nsottint__SWIG_1(arg1 Hello_int) (_swig_ret int) { + return _swig_wrap_nsottint__SWIG_1(arg1.Swigcptr()) +} + +func Nsottint(a ...interface{}) int { + argc := len(a) + if argc == 1 { + return Nsottint__SWIG_1(a[0].(Hello_int)) + } + if argc == 2 { + return Nsottint__SWIG_0(a[0].(Hello_int), a[1].(int)) + } + panic("No match for overloaded function call") +} + +var _wrap_nsottstring__SWIG_0 unsafe.Pointer + +func _swig_wrap_nsottstring__SWIG_0(base uintptr, _ string) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_nsottstring__SWIG_0, _swig_p) + return +} + +func Nsottstring__SWIG_0(arg1 Hello_int, arg2 string) (_swig_ret int) { + return _swig_wrap_nsottstring__SWIG_0(arg1.Swigcptr(), arg2) +} + +var _wrap_nsottstring__SWIG_1 unsafe.Pointer + +func _swig_wrap_nsottstring__SWIG_1(base uintptr) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_nsottstring__SWIG_1, _swig_p) + return +} + +func Nsottstring__SWIG_1(arg1 Hello_int) (_swig_ret int) { + return _swig_wrap_nsottstring__SWIG_1(arg1.Swigcptr()) +} + +func Nsottstring(a ...interface{}) int { + argc := len(a) + if argc == 1 { + return Nsottstring__SWIG_1(a[0].(Hello_int)) + } + if argc == 2 { + return Nsottstring__SWIG_0(a[0].(Hello_int), a[1].(string)) + } + panic("No match for overloaded function call") +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + +type SwigcptrFoo_Sl_Foo_Sl_int_Sg__Sg_ uintptr +type Foo_Sl_Foo_Sl_int_Sg__Sg_ interface { + Swigcptr() uintptr; +} +func (p SwigcptrFoo_Sl_Foo_Sl_int_Sg__Sg_) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/template_default_arg_runme b/Examples/test-suite/go/template_default_arg_runme new file mode 100755 index 000000000..475840cbb Binary files /dev/null and b/Examples/test-suite/go/template_default_arg_runme differ diff --git a/Examples/test-suite/go/template_default_arg_virtual_destructor.go b/Examples/test-suite/go/template_default_arg_virtual_destructor.go new file mode 100644 index 000000000..a63d7719d --- /dev/null +++ b/Examples/test-suite/go/template_default_arg_virtual_destructor.go @@ -0,0 +1,151 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../template_default_arg_virtual_destructor.i + +package template_default_arg_virtual_destructor + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrA uintptr + +func (p SwigcptrA) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrA) SwigIsA() { +} + +var _wrap_new_A unsafe.Pointer + +func _swig_wrap_new_A() (base SwigcptrA) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_A, _swig_p) + return +} + +func NewA() (_swig_ret A) { + return _swig_wrap_new_A() +} + +var _wrap_delete_A unsafe.Pointer + +func _swig_wrap_delete_A(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_A, _swig_p) + return +} + +func DeleteA(arg1 A) { + _swig_wrap_delete_A(arg1.Swigcptr()) +} + +type A interface { + Swigcptr() uintptr + SwigIsA() +} + +type SwigcptrB_AF uintptr + +func (p SwigcptrB_AF) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrB_AF) SwigIsB_AF() { +} + +var _wrap_new_B_AF unsafe.Pointer + +func _swig_wrap_new_B_AF(base float32) (_ SwigcptrB_AF) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_B_AF, _swig_p) + return +} + +func NewB_AF(arg1 float32) (_swig_ret B_AF) { + return _swig_wrap_new_B_AF(arg1) +} + +var _wrap_delete_B_AF unsafe.Pointer + +func _swig_wrap_delete_B_AF(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_B_AF, _swig_p) + return +} + +func DeleteB_AF(arg1 B_AF) { + _swig_wrap_delete_B_AF(arg1.Swigcptr()) +} + +type B_AF interface { + Swigcptr() uintptr + SwigIsB_AF() +} + +type SwigcptrB_A uintptr + +func (p SwigcptrB_A) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrB_A) SwigIsB_A() { +} + +var _wrap_new_B_A unsafe.Pointer + +func _swig_wrap_new_B_A(base int, _ int) (_ SwigcptrB_A) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_B_A, _swig_p) + return +} + +func NewB_A(arg1 int, arg2 int) (_swig_ret B_A) { + return _swig_wrap_new_B_A(arg1, arg2) +} + +var _wrap_delete_B_A unsafe.Pointer + +func _swig_wrap_delete_B_A(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_B_A, _swig_p) + return +} + +func DeleteB_A(arg1 B_A) { + _swig_wrap_delete_B_A(arg1.Swigcptr()) +} + +type B_A interface { + Swigcptr() uintptr + SwigIsB_A() +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/template_default_class_parms.go b/Examples/test-suite/go/template_default_class_parms.go new file mode 100644 index 000000000..5b073bcad --- /dev/null +++ b/Examples/test-suite/go/template_default_class_parms.go @@ -0,0 +1,525 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../template_default_class_parms.i + +package template_default_class_parms + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrSomeType uintptr + +func (p SwigcptrSomeType) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrSomeType) SwigIsSomeType() { +} + +var _wrap_new_SomeType unsafe.Pointer + +func _swig_wrap_new_SomeType() (base SwigcptrSomeType) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_SomeType, _swig_p) + return +} + +func NewSomeType() (_swig_ret SomeType) { + return _swig_wrap_new_SomeType() +} + +var _wrap_delete_SomeType unsafe.Pointer + +func _swig_wrap_delete_SomeType(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_SomeType, _swig_p) + return +} + +func DeleteSomeType(arg1 SomeType) { + _swig_wrap_delete_SomeType(arg1.Swigcptr()) +} + +type SomeType interface { + Swigcptr() uintptr + SwigIsSomeType() +} + +type SwigcptrAnotherType uintptr + +func (p SwigcptrAnotherType) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrAnotherType) SwigIsAnotherType() { +} + +var _wrap_new_AnotherType unsafe.Pointer + +func _swig_wrap_new_AnotherType() (base SwigcptrAnotherType) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_AnotherType, _swig_p) + return +} + +func NewAnotherType() (_swig_ret AnotherType) { + return _swig_wrap_new_AnotherType() +} + +var _wrap_delete_AnotherType unsafe.Pointer + +func _swig_wrap_delete_AnotherType(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_AnotherType, _swig_p) + return +} + +func DeleteAnotherType(arg1 AnotherType) { + _swig_wrap_delete_AnotherType(arg1.Swigcptr()) +} + +type AnotherType interface { + Swigcptr() uintptr + SwigIsAnotherType() +} + +type SwigcptrDefaultBar uintptr + +func (p SwigcptrDefaultBar) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrDefaultBar) SwigIsDefaultBar() { +} + +var _wrap_DefaultBar_CType_set unsafe.Pointer + +func _swig_wrap_DefaultBar_CType_set(base SwigcptrDefaultBar, _ float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_DefaultBar_CType_set, _swig_p) + return +} + +func (arg1 SwigcptrDefaultBar) SetCType(arg2 float64) { + _swig_wrap_DefaultBar_CType_set(arg1, arg2) +} + +var _wrap_DefaultBar_CType_get unsafe.Pointer + +func _swig_wrap_DefaultBar_CType_get(base SwigcptrDefaultBar) (_ float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_DefaultBar_CType_get, _swig_p) + return +} + +func (arg1 SwigcptrDefaultBar) GetCType() (_swig_ret float64) { + return _swig_wrap_DefaultBar_CType_get(arg1) +} + +var _wrap_DefaultBar_DType_set unsafe.Pointer + +func _swig_wrap_DefaultBar_DType_set(base SwigcptrDefaultBar, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_DefaultBar_DType_set, _swig_p) + return +} + +func (arg1 SwigcptrDefaultBar) SetDType(arg2 SomeType) { + _swig_wrap_DefaultBar_DType_set(arg1, arg2.Swigcptr()) +} + +var _wrap_DefaultBar_DType_get unsafe.Pointer + +func _swig_wrap_DefaultBar_DType_get(base SwigcptrDefaultBar) (_ SwigcptrSomeType) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_DefaultBar_DType_get, _swig_p) + return +} + +func (arg1 SwigcptrDefaultBar) GetDType() (_swig_ret SomeType) { + return _swig_wrap_DefaultBar_DType_get(arg1) +} + +var _wrap_DefaultBar_EType_set unsafe.Pointer + +func _swig_wrap_DefaultBar_EType_set(base SwigcptrDefaultBar, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_DefaultBar_EType_set, _swig_p) + return +} + +func (arg1 SwigcptrDefaultBar) SetEType(arg2 int) { + _swig_wrap_DefaultBar_EType_set(arg1, arg2) +} + +var _wrap_DefaultBar_EType_get unsafe.Pointer + +func _swig_wrap_DefaultBar_EType_get(base SwigcptrDefaultBar) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_DefaultBar_EType_get, _swig_p) + return +} + +func (arg1 SwigcptrDefaultBar) GetEType() (_swig_ret int) { + return _swig_wrap_DefaultBar_EType_get(arg1) +} + +var _wrap_new_DefaultBar unsafe.Pointer + +func _swig_wrap_new_DefaultBar(base float64, _ uintptr, _ int) (_ SwigcptrDefaultBar) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_DefaultBar, _swig_p) + return +} + +func NewDefaultBar(arg1 float64, arg2 SomeType, arg3 int) (_swig_ret DefaultBar) { + return _swig_wrap_new_DefaultBar(arg1, arg2.Swigcptr(), arg3) +} + +var _wrap_DefaultBar_method unsafe.Pointer + +func _swig_wrap_DefaultBar_method(base SwigcptrDefaultBar, _ float64, _ uintptr, _ int) (_ float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_DefaultBar_method, _swig_p) + return +} + +func (arg1 SwigcptrDefaultBar) Method(arg2 float64, arg3 SomeType, arg4 int) (_swig_ret float64) { + return _swig_wrap_DefaultBar_method(arg1, arg2, arg3.Swigcptr(), arg4) +} + +var _wrap_delete_DefaultBar unsafe.Pointer + +func _swig_wrap_delete_DefaultBar(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_DefaultBar, _swig_p) + return +} + +func DeleteDefaultBar(arg1 DefaultBar) { + _swig_wrap_delete_DefaultBar(arg1.Swigcptr()) +} + +type DefaultBar interface { + Swigcptr() uintptr + SwigIsDefaultBar() + SetCType(arg2 float64) + GetCType() (_swig_ret float64) + SetDType(arg2 SomeType) + GetDType() (_swig_ret SomeType) + SetEType(arg2 int) + GetEType() (_swig_ret int) + Method(arg2 float64, arg3 SomeType, arg4 int) (_swig_ret float64) +} + +type SwigcptrDefaultFoo uintptr + +func (p SwigcptrDefaultFoo) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrDefaultFoo) SwigIsDefaultFoo() { +} + +var _wrap_DefaultFoo_TType_set unsafe.Pointer + +func _swig_wrap_DefaultFoo_TType_set(base SwigcptrDefaultFoo, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_DefaultFoo_TType_set, _swig_p) + return +} + +func (arg1 SwigcptrDefaultFoo) SetTType(arg2 SomeType) { + _swig_wrap_DefaultFoo_TType_set(arg1, arg2.Swigcptr()) +} + +var _wrap_DefaultFoo_TType_get unsafe.Pointer + +func _swig_wrap_DefaultFoo_TType_get(base SwigcptrDefaultFoo) (_ SwigcptrSomeType) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_DefaultFoo_TType_get, _swig_p) + return +} + +func (arg1 SwigcptrDefaultFoo) GetTType() (_swig_ret SomeType) { + return _swig_wrap_DefaultFoo_TType_get(arg1) +} + +var _wrap_new_DefaultFoo unsafe.Pointer + +func _swig_wrap_new_DefaultFoo(base uintptr) (_ SwigcptrDefaultFoo) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_DefaultFoo, _swig_p) + return +} + +func NewDefaultFoo(arg1 SomeType) (_swig_ret DefaultFoo) { + return _swig_wrap_new_DefaultFoo(arg1.Swigcptr()) +} + +var _wrap_DefaultFoo_method unsafe.Pointer + +func _swig_wrap_DefaultFoo_method(base SwigcptrDefaultFoo, _ uintptr) (_ SwigcptrSomeType) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_DefaultFoo_method, _swig_p) + return +} + +func (arg1 SwigcptrDefaultFoo) Method(arg2 SomeType) (_swig_ret SomeType) { + return _swig_wrap_DefaultFoo_method(arg1, arg2.Swigcptr()) +} + +var _wrap_delete_DefaultFoo unsafe.Pointer + +func _swig_wrap_delete_DefaultFoo(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_DefaultFoo, _swig_p) + return +} + +func DeleteDefaultFoo(arg1 DefaultFoo) { + _swig_wrap_delete_DefaultFoo(arg1.Swigcptr()) +} + +type DefaultFoo interface { + Swigcptr() uintptr + SwigIsDefaultFoo() + SetTType(arg2 SomeType) + GetTType() (_swig_ret SomeType) + Method(arg2 SomeType) (_swig_ret SomeType) +} + +type SwigcptrBarAnotherTypeBool uintptr + +func (p SwigcptrBarAnotherTypeBool) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrBarAnotherTypeBool) SwigIsBarAnotherTypeBool() { +} + +var _wrap_BarAnotherTypeBool_CType_set unsafe.Pointer + +func _swig_wrap_BarAnotherTypeBool_CType_set(base SwigcptrBarAnotherTypeBool, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_BarAnotherTypeBool_CType_set, _swig_p) + return +} + +func (arg1 SwigcptrBarAnotherTypeBool) SetCType(arg2 AnotherType) { + _swig_wrap_BarAnotherTypeBool_CType_set(arg1, arg2.Swigcptr()) +} + +var _wrap_BarAnotherTypeBool_CType_get unsafe.Pointer + +func _swig_wrap_BarAnotherTypeBool_CType_get(base SwigcptrBarAnotherTypeBool) (_ SwigcptrAnotherType) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_BarAnotherTypeBool_CType_get, _swig_p) + return +} + +func (arg1 SwigcptrBarAnotherTypeBool) GetCType() (_swig_ret AnotherType) { + return _swig_wrap_BarAnotherTypeBool_CType_get(arg1) +} + +var _wrap_BarAnotherTypeBool_DType_set unsafe.Pointer + +func _swig_wrap_BarAnotherTypeBool_DType_set(base SwigcptrBarAnotherTypeBool, _ bool) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_BarAnotherTypeBool_DType_set, _swig_p) + return +} + +func (arg1 SwigcptrBarAnotherTypeBool) SetDType(arg2 bool) { + _swig_wrap_BarAnotherTypeBool_DType_set(arg1, arg2) +} + +var _wrap_BarAnotherTypeBool_DType_get unsafe.Pointer + +func _swig_wrap_BarAnotherTypeBool_DType_get(base SwigcptrBarAnotherTypeBool) (_ bool) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_BarAnotherTypeBool_DType_get, _swig_p) + return +} + +func (arg1 SwigcptrBarAnotherTypeBool) GetDType() (_swig_ret bool) { + return _swig_wrap_BarAnotherTypeBool_DType_get(arg1) +} + +var _wrap_BarAnotherTypeBool_EType_set unsafe.Pointer + +func _swig_wrap_BarAnotherTypeBool_EType_set(base SwigcptrBarAnotherTypeBool, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_BarAnotherTypeBool_EType_set, _swig_p) + return +} + +func (arg1 SwigcptrBarAnotherTypeBool) SetEType(arg2 int) { + _swig_wrap_BarAnotherTypeBool_EType_set(arg1, arg2) +} + +var _wrap_BarAnotherTypeBool_EType_get unsafe.Pointer + +func _swig_wrap_BarAnotherTypeBool_EType_get(base SwigcptrBarAnotherTypeBool) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_BarAnotherTypeBool_EType_get, _swig_p) + return +} + +func (arg1 SwigcptrBarAnotherTypeBool) GetEType() (_swig_ret int) { + return _swig_wrap_BarAnotherTypeBool_EType_get(arg1) +} + +var _wrap_new_BarAnotherTypeBool unsafe.Pointer + +func _swig_wrap_new_BarAnotherTypeBool(base uintptr, _ bool, _ int) (_ SwigcptrBarAnotherTypeBool) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_BarAnotherTypeBool, _swig_p) + return +} + +func NewBarAnotherTypeBool(arg1 AnotherType, arg2 bool, arg3 int) (_swig_ret BarAnotherTypeBool) { + return _swig_wrap_new_BarAnotherTypeBool(arg1.Swigcptr(), arg2, arg3) +} + +var _wrap_BarAnotherTypeBool_method unsafe.Pointer + +func _swig_wrap_BarAnotherTypeBool_method(base SwigcptrBarAnotherTypeBool, _ uintptr, _ bool, _ int) (_ SwigcptrAnotherType) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_BarAnotherTypeBool_method, _swig_p) + return +} + +func (arg1 SwigcptrBarAnotherTypeBool) Method(arg2 AnotherType, arg3 bool, arg4 int) (_swig_ret AnotherType) { + return _swig_wrap_BarAnotherTypeBool_method(arg1, arg2.Swigcptr(), arg3, arg4) +} + +var _wrap_delete_BarAnotherTypeBool unsafe.Pointer + +func _swig_wrap_delete_BarAnotherTypeBool(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_BarAnotherTypeBool, _swig_p) + return +} + +func DeleteBarAnotherTypeBool(arg1 BarAnotherTypeBool) { + _swig_wrap_delete_BarAnotherTypeBool(arg1.Swigcptr()) +} + +type BarAnotherTypeBool interface { + Swigcptr() uintptr + SwigIsBarAnotherTypeBool() + SetCType(arg2 AnotherType) + GetCType() (_swig_ret AnotherType) + SetDType(arg2 bool) + GetDType() (_swig_ret bool) + SetEType(arg2 int) + GetEType() (_swig_ret int) + Method(arg2 AnotherType, arg3 bool, arg4 int) (_swig_ret AnotherType) +} + +type SwigcptrFooAnotherType uintptr + +func (p SwigcptrFooAnotherType) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrFooAnotherType) SwigIsFooAnotherType() { +} + +var _wrap_FooAnotherType_TType_set unsafe.Pointer + +func _swig_wrap_FooAnotherType_TType_set(base SwigcptrFooAnotherType, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_FooAnotherType_TType_set, _swig_p) + return +} + +func (arg1 SwigcptrFooAnotherType) SetTType(arg2 AnotherType) { + _swig_wrap_FooAnotherType_TType_set(arg1, arg2.Swigcptr()) +} + +var _wrap_FooAnotherType_TType_get unsafe.Pointer + +func _swig_wrap_FooAnotherType_TType_get(base SwigcptrFooAnotherType) (_ SwigcptrAnotherType) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_FooAnotherType_TType_get, _swig_p) + return +} + +func (arg1 SwigcptrFooAnotherType) GetTType() (_swig_ret AnotherType) { + return _swig_wrap_FooAnotherType_TType_get(arg1) +} + +var _wrap_new_FooAnotherType unsafe.Pointer + +func _swig_wrap_new_FooAnotherType(base uintptr) (_ SwigcptrFooAnotherType) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_FooAnotherType, _swig_p) + return +} + +func NewFooAnotherType(arg1 AnotherType) (_swig_ret FooAnotherType) { + return _swig_wrap_new_FooAnotherType(arg1.Swigcptr()) +} + +var _wrap_FooAnotherType_method unsafe.Pointer + +func _swig_wrap_FooAnotherType_method(base SwigcptrFooAnotherType, _ uintptr) (_ SwigcptrAnotherType) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_FooAnotherType_method, _swig_p) + return +} + +func (arg1 SwigcptrFooAnotherType) Method(arg2 AnotherType) (_swig_ret AnotherType) { + return _swig_wrap_FooAnotherType_method(arg1, arg2.Swigcptr()) +} + +var _wrap_delete_FooAnotherType unsafe.Pointer + +func _swig_wrap_delete_FooAnotherType(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_FooAnotherType, _swig_p) + return +} + +func DeleteFooAnotherType(arg1 FooAnotherType) { + _swig_wrap_delete_FooAnotherType(arg1.Swigcptr()) +} + +type FooAnotherType interface { + Swigcptr() uintptr + SwigIsFooAnotherType() + SetTType(arg2 AnotherType) + GetTType() (_swig_ret AnotherType) + Method(arg2 AnotherType) (_swig_ret AnotherType) +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/template_default_class_parms_typedef.go b/Examples/test-suite/go/template_default_class_parms_typedef.go new file mode 100644 index 000000000..4638c3168 --- /dev/null +++ b/Examples/test-suite/go/template_default_class_parms_typedef.go @@ -0,0 +1,983 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../template_default_class_parms_typedef.i + +package template_default_class_parms_typedef + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrSomeType uintptr + +func (p SwigcptrSomeType) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrSomeType) SwigIsSomeType() { +} + +var _wrap_new_SomeType unsafe.Pointer + +func _swig_wrap_new_SomeType() (base SwigcptrSomeType) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_SomeType, _swig_p) + return +} + +func NewSomeType() (_swig_ret SomeType) { + return _swig_wrap_new_SomeType() +} + +var _wrap_delete_SomeType unsafe.Pointer + +func _swig_wrap_delete_SomeType(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_SomeType, _swig_p) + return +} + +func DeleteSomeType(arg1 SomeType) { + _swig_wrap_delete_SomeType(arg1.Swigcptr()) +} + +type SomeType interface { + Swigcptr() uintptr + SwigIsSomeType() +} + +type SwigcptrAnotherType uintptr + +func (p SwigcptrAnotherType) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrAnotherType) SwigIsAnotherType() { +} + +var _wrap_new_AnotherType unsafe.Pointer + +func _swig_wrap_new_AnotherType() (base SwigcptrAnotherType) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_AnotherType, _swig_p) + return +} + +func NewAnotherType() (_swig_ret AnotherType) { + return _swig_wrap_new_AnotherType() +} + +var _wrap_delete_AnotherType unsafe.Pointer + +func _swig_wrap_delete_AnotherType(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_AnotherType, _swig_p) + return +} + +func DeleteAnotherType(arg1 AnotherType) { + _swig_wrap_delete_AnotherType(arg1.Swigcptr()) +} + +type AnotherType interface { + Swigcptr() uintptr + SwigIsAnotherType() +} + +type SwigcptrDefaultBar uintptr + +func (p SwigcptrDefaultBar) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrDefaultBar) SwigIsDefaultBar() { +} + +var _wrap_DefaultBar_CType_set unsafe.Pointer + +func _swig_wrap_DefaultBar_CType_set(base SwigcptrDefaultBar, _ float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_DefaultBar_CType_set, _swig_p) + return +} + +func (arg1 SwigcptrDefaultBar) SetCType(arg2 float64) { + _swig_wrap_DefaultBar_CType_set(arg1, arg2) +} + +var _wrap_DefaultBar_CType_get unsafe.Pointer + +func _swig_wrap_DefaultBar_CType_get(base SwigcptrDefaultBar) (_ float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_DefaultBar_CType_get, _swig_p) + return +} + +func (arg1 SwigcptrDefaultBar) GetCType() (_swig_ret float64) { + return _swig_wrap_DefaultBar_CType_get(arg1) +} + +var _wrap_DefaultBar_DType_set unsafe.Pointer + +func _swig_wrap_DefaultBar_DType_set(base SwigcptrDefaultBar, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_DefaultBar_DType_set, _swig_p) + return +} + +func (arg1 SwigcptrDefaultBar) SetDType(arg2 SomeType) { + _swig_wrap_DefaultBar_DType_set(arg1, arg2.Swigcptr()) +} + +var _wrap_DefaultBar_DType_get unsafe.Pointer + +func _swig_wrap_DefaultBar_DType_get(base SwigcptrDefaultBar) (_ SwigcptrSomeType) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_DefaultBar_DType_get, _swig_p) + return +} + +func (arg1 SwigcptrDefaultBar) GetDType() (_swig_ret SomeType) { + return _swig_wrap_DefaultBar_DType_get(arg1) +} + +var _wrap_DefaultBar_EType_set unsafe.Pointer + +func _swig_wrap_DefaultBar_EType_set(base SwigcptrDefaultBar, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_DefaultBar_EType_set, _swig_p) + return +} + +func (arg1 SwigcptrDefaultBar) SetEType(arg2 int) { + _swig_wrap_DefaultBar_EType_set(arg1, arg2) +} + +var _wrap_DefaultBar_EType_get unsafe.Pointer + +func _swig_wrap_DefaultBar_EType_get(base SwigcptrDefaultBar) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_DefaultBar_EType_get, _swig_p) + return +} + +func (arg1 SwigcptrDefaultBar) GetEType() (_swig_ret int) { + return _swig_wrap_DefaultBar_EType_get(arg1) +} + +var _wrap_new_DefaultBar__SWIG_0 unsafe.Pointer + +func _swig_wrap_new_DefaultBar__SWIG_0(base float64, _ uintptr, _ int) (_ SwigcptrDefaultBar) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_DefaultBar__SWIG_0, _swig_p) + return +} + +func NewDefaultBar__SWIG_0(arg1 float64, arg2 SomeType, arg3 int) (_swig_ret DefaultBar) { + return _swig_wrap_new_DefaultBar__SWIG_0(arg1, arg2.Swigcptr(), arg3) +} + +var _wrap_DefaultBar_method unsafe.Pointer + +func _swig_wrap_DefaultBar_method(base SwigcptrDefaultBar, _ float64, _ uintptr, _ int) (_ float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_DefaultBar_method, _swig_p) + return +} + +func (arg1 SwigcptrDefaultBar) Method(arg2 float64, arg3 SomeType, arg4 int) (_swig_ret float64) { + return _swig_wrap_DefaultBar_method(arg1, arg2, arg3.Swigcptr(), arg4) +} + +var _wrap_new_DefaultBar__SWIG_1 unsafe.Pointer + +func _swig_wrap_new_DefaultBar__SWIG_1(base bool, _ float64, _ uintptr, _ int) (_ SwigcptrDefaultBar) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_DefaultBar__SWIG_1, _swig_p) + return +} + +func NewDefaultBar__SWIG_1(arg1 bool, arg2 float64, arg3 SomeType, arg4 int) (_swig_ret DefaultBar) { + return _swig_wrap_new_DefaultBar__SWIG_1(arg1, arg2, arg3.Swigcptr(), arg4) +} + +var _wrap_DefaultBar_method_1 unsafe.Pointer + +func _swig_wrap_DefaultBar_method_1(base SwigcptrDefaultBar, _ float64, _ uintptr, _ int) (_ float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_DefaultBar_method_1, _swig_p) + return +} + +func (arg1 SwigcptrDefaultBar) Method_1(arg2 float64, arg3 SomeType, arg4 int) (_swig_ret float64) { + return _swig_wrap_DefaultBar_method_1(arg1, arg2, arg3.Swigcptr(), arg4) +} + +var _wrap_new_DefaultBar__SWIG_2 unsafe.Pointer + +func _swig_wrap_new_DefaultBar__SWIG_2(base bool, _ bool, _ float64, _ uintptr, _ int) (_ SwigcptrDefaultBar) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_DefaultBar__SWIG_2, _swig_p) + return +} + +func NewDefaultBar__SWIG_2(arg1 bool, arg2 bool, arg3 float64, arg4 SomeType, arg5 int) (_swig_ret DefaultBar) { + return _swig_wrap_new_DefaultBar__SWIG_2(arg1, arg2, arg3, arg4.Swigcptr(), arg5) +} + +var _wrap_DefaultBar_method_2 unsafe.Pointer + +func _swig_wrap_DefaultBar_method_2(base SwigcptrDefaultBar, _ float64, _ uintptr, _ int) (_ float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_DefaultBar_method_2, _swig_p) + return +} + +func (arg1 SwigcptrDefaultBar) Method_2(arg2 float64, arg3 SomeType, arg4 int) (_swig_ret float64) { + return _swig_wrap_DefaultBar_method_2(arg1, arg2, arg3.Swigcptr(), arg4) +} + +var _wrap_new_DefaultBar__SWIG_3 unsafe.Pointer + +func _swig_wrap_new_DefaultBar__SWIG_3(base bool, _ bool, _ bool, _ float64, _ uintptr, _ int) (_ SwigcptrDefaultBar) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_DefaultBar__SWIG_3, _swig_p) + return +} + +func NewDefaultBar__SWIG_3(arg1 bool, arg2 bool, arg3 bool, arg4 float64, arg5 SomeType, arg6 int) (_swig_ret DefaultBar) { + return _swig_wrap_new_DefaultBar__SWIG_3(arg1, arg2, arg3, arg4, arg5.Swigcptr(), arg6) +} + +func NewDefaultBar(a ...interface{}) DefaultBar { + argc := len(a) + if argc == 3 { + return NewDefaultBar__SWIG_0(a[0].(float64), a[1].(SomeType), a[2].(int)) + } + if argc == 4 { + return NewDefaultBar__SWIG_1(a[0].(bool), a[1].(float64), a[2].(SomeType), a[3].(int)) + } + if argc == 5 { + return NewDefaultBar__SWIG_2(a[0].(bool), a[1].(bool), a[2].(float64), a[3].(SomeType), a[4].(int)) + } + if argc == 6 { + return NewDefaultBar__SWIG_3(a[0].(bool), a[1].(bool), a[2].(bool), a[3].(float64), a[4].(SomeType), a[5].(int)) + } + panic("No match for overloaded function call") +} + +var _wrap_DefaultBar_method_3 unsafe.Pointer + +func _swig_wrap_DefaultBar_method_3(base SwigcptrDefaultBar, _ float64, _ uintptr, _ int) (_ float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_DefaultBar_method_3, _swig_p) + return +} + +func (arg1 SwigcptrDefaultBar) Method_3(arg2 float64, arg3 SomeType, arg4 int) (_swig_ret float64) { + return _swig_wrap_DefaultBar_method_3(arg1, arg2, arg3.Swigcptr(), arg4) +} + +var _wrap_delete_DefaultBar unsafe.Pointer + +func _swig_wrap_delete_DefaultBar(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_DefaultBar, _swig_p) + return +} + +func DeleteDefaultBar(arg1 DefaultBar) { + _swig_wrap_delete_DefaultBar(arg1.Swigcptr()) +} + +type DefaultBar interface { + Swigcptr() uintptr + SwigIsDefaultBar() + SetCType(arg2 float64) + GetCType() (_swig_ret float64) + SetDType(arg2 SomeType) + GetDType() (_swig_ret SomeType) + SetEType(arg2 int) + GetEType() (_swig_ret int) + Method(arg2 float64, arg3 SomeType, arg4 int) (_swig_ret float64) + Method_1(arg2 float64, arg3 SomeType, arg4 int) (_swig_ret float64) + Method_2(arg2 float64, arg3 SomeType, arg4 int) (_swig_ret float64) + Method_3(arg2 float64, arg3 SomeType, arg4 int) (_swig_ret float64) +} + +type SwigcptrDefaultFoo uintptr + +func (p SwigcptrDefaultFoo) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrDefaultFoo) SwigIsDefaultFoo() { +} + +var _wrap_DefaultFoo_TType_set unsafe.Pointer + +func _swig_wrap_DefaultFoo_TType_set(base SwigcptrDefaultFoo, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_DefaultFoo_TType_set, _swig_p) + return +} + +func (arg1 SwigcptrDefaultFoo) SetTType(arg2 SomeType) { + _swig_wrap_DefaultFoo_TType_set(arg1, arg2.Swigcptr()) +} + +var _wrap_DefaultFoo_TType_get unsafe.Pointer + +func _swig_wrap_DefaultFoo_TType_get(base SwigcptrDefaultFoo) (_ SwigcptrSomeType) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_DefaultFoo_TType_get, _swig_p) + return +} + +func (arg1 SwigcptrDefaultFoo) GetTType() (_swig_ret SomeType) { + return _swig_wrap_DefaultFoo_TType_get(arg1) +} + +var _wrap_new_DefaultFoo__SWIG_0 unsafe.Pointer + +func _swig_wrap_new_DefaultFoo__SWIG_0(base uintptr) (_ SwigcptrDefaultFoo) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_DefaultFoo__SWIG_0, _swig_p) + return +} + +func NewDefaultFoo__SWIG_0(arg1 SomeType) (_swig_ret DefaultFoo) { + return _swig_wrap_new_DefaultFoo__SWIG_0(arg1.Swigcptr()) +} + +var _wrap_DefaultFoo_method unsafe.Pointer + +func _swig_wrap_DefaultFoo_method(base SwigcptrDefaultFoo, _ uintptr) (_ SwigcptrSomeType) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_DefaultFoo_method, _swig_p) + return +} + +func (arg1 SwigcptrDefaultFoo) Method(arg2 SomeType) (_swig_ret SomeType) { + return _swig_wrap_DefaultFoo_method(arg1, arg2.Swigcptr()) +} + +var _wrap_new_DefaultFoo__SWIG_1 unsafe.Pointer + +func _swig_wrap_new_DefaultFoo__SWIG_1(base uintptr, _ uintptr) (_ SwigcptrDefaultFoo) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_DefaultFoo__SWIG_1, _swig_p) + return +} + +func NewDefaultFoo__SWIG_1(arg1 SomeType, arg2 SomeType) (_swig_ret DefaultFoo) { + return _swig_wrap_new_DefaultFoo__SWIG_1(arg1.Swigcptr(), arg2.Swigcptr()) +} + +var _wrap_DefaultFoo_method_A unsafe.Pointer + +func _swig_wrap_DefaultFoo_method_A(base SwigcptrDefaultFoo, _ uintptr) (_ SwigcptrSomeType) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_DefaultFoo_method_A, _swig_p) + return +} + +func (arg1 SwigcptrDefaultFoo) Method_A(arg2 SomeType) (_swig_ret SomeType) { + return _swig_wrap_DefaultFoo_method_A(arg1, arg2.Swigcptr()) +} + +var _wrap_new_DefaultFoo__SWIG_2 unsafe.Pointer + +func _swig_wrap_new_DefaultFoo__SWIG_2(base uintptr, _ uintptr, _ uintptr) (_ SwigcptrDefaultFoo) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_DefaultFoo__SWIG_2, _swig_p) + return +} + +func NewDefaultFoo__SWIG_2(arg1 SomeType, arg2 SomeType, arg3 SomeType) (_swig_ret DefaultFoo) { + return _swig_wrap_new_DefaultFoo__SWIG_2(arg1.Swigcptr(), arg2.Swigcptr(), arg3.Swigcptr()) +} + +var _wrap_DefaultFoo_method_B unsafe.Pointer + +func _swig_wrap_DefaultFoo_method_B(base SwigcptrDefaultFoo, _ uintptr) (_ SwigcptrSomeType) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_DefaultFoo_method_B, _swig_p) + return +} + +func (arg1 SwigcptrDefaultFoo) Method_B(arg2 SomeType) (_swig_ret SomeType) { + return _swig_wrap_DefaultFoo_method_B(arg1, arg2.Swigcptr()) +} + +var _wrap_new_DefaultFoo__SWIG_3 unsafe.Pointer + +func _swig_wrap_new_DefaultFoo__SWIG_3(base uintptr, _ uintptr, _ uintptr, _ uintptr) (_ SwigcptrDefaultFoo) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_DefaultFoo__SWIG_3, _swig_p) + return +} + +func NewDefaultFoo__SWIG_3(arg1 SomeType, arg2 SomeType, arg3 SomeType, arg4 SomeType) (_swig_ret DefaultFoo) { + return _swig_wrap_new_DefaultFoo__SWIG_3(arg1.Swigcptr(), arg2.Swigcptr(), arg3.Swigcptr(), arg4.Swigcptr()) +} + +func NewDefaultFoo(a ...interface{}) DefaultFoo { + argc := len(a) + if argc == 1 { + return NewDefaultFoo__SWIG_0(a[0].(SomeType)) + } + if argc == 2 { + return NewDefaultFoo__SWIG_1(a[0].(SomeType), a[1].(SomeType)) + } + if argc == 3 { + return NewDefaultFoo__SWIG_2(a[0].(SomeType), a[1].(SomeType), a[2].(SomeType)) + } + if argc == 4 { + return NewDefaultFoo__SWIG_3(a[0].(SomeType), a[1].(SomeType), a[2].(SomeType), a[3].(SomeType)) + } + panic("No match for overloaded function call") +} + +var _wrap_DefaultFoo_method_C unsafe.Pointer + +func _swig_wrap_DefaultFoo_method_C(base SwigcptrDefaultFoo, _ uintptr) (_ SwigcptrSomeType) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_DefaultFoo_method_C, _swig_p) + return +} + +func (arg1 SwigcptrDefaultFoo) Method_C(arg2 SomeType) (_swig_ret SomeType) { + return _swig_wrap_DefaultFoo_method_C(arg1, arg2.Swigcptr()) +} + +var _wrap_delete_DefaultFoo unsafe.Pointer + +func _swig_wrap_delete_DefaultFoo(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_DefaultFoo, _swig_p) + return +} + +func DeleteDefaultFoo(arg1 DefaultFoo) { + _swig_wrap_delete_DefaultFoo(arg1.Swigcptr()) +} + +type DefaultFoo interface { + Swigcptr() uintptr + SwigIsDefaultFoo() + SetTType(arg2 SomeType) + GetTType() (_swig_ret SomeType) + Method(arg2 SomeType) (_swig_ret SomeType) + Method_A(arg2 SomeType) (_swig_ret SomeType) + Method_B(arg2 SomeType) (_swig_ret SomeType) + Method_C(arg2 SomeType) (_swig_ret SomeType) +} + +type SwigcptrBarAnotherTypeBool uintptr + +func (p SwigcptrBarAnotherTypeBool) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrBarAnotherTypeBool) SwigIsBarAnotherTypeBool() { +} + +var _wrap_BarAnotherTypeBool_CType_set unsafe.Pointer + +func _swig_wrap_BarAnotherTypeBool_CType_set(base SwigcptrBarAnotherTypeBool, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_BarAnotherTypeBool_CType_set, _swig_p) + return +} + +func (arg1 SwigcptrBarAnotherTypeBool) SetCType(arg2 AnotherType) { + _swig_wrap_BarAnotherTypeBool_CType_set(arg1, arg2.Swigcptr()) +} + +var _wrap_BarAnotherTypeBool_CType_get unsafe.Pointer + +func _swig_wrap_BarAnotherTypeBool_CType_get(base SwigcptrBarAnotherTypeBool) (_ SwigcptrAnotherType) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_BarAnotherTypeBool_CType_get, _swig_p) + return +} + +func (arg1 SwigcptrBarAnotherTypeBool) GetCType() (_swig_ret AnotherType) { + return _swig_wrap_BarAnotherTypeBool_CType_get(arg1) +} + +var _wrap_BarAnotherTypeBool_DType_set unsafe.Pointer + +func _swig_wrap_BarAnotherTypeBool_DType_set(base SwigcptrBarAnotherTypeBool, _ bool) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_BarAnotherTypeBool_DType_set, _swig_p) + return +} + +func (arg1 SwigcptrBarAnotherTypeBool) SetDType(arg2 bool) { + _swig_wrap_BarAnotherTypeBool_DType_set(arg1, arg2) +} + +var _wrap_BarAnotherTypeBool_DType_get unsafe.Pointer + +func _swig_wrap_BarAnotherTypeBool_DType_get(base SwigcptrBarAnotherTypeBool) (_ bool) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_BarAnotherTypeBool_DType_get, _swig_p) + return +} + +func (arg1 SwigcptrBarAnotherTypeBool) GetDType() (_swig_ret bool) { + return _swig_wrap_BarAnotherTypeBool_DType_get(arg1) +} + +var _wrap_BarAnotherTypeBool_EType_set unsafe.Pointer + +func _swig_wrap_BarAnotherTypeBool_EType_set(base SwigcptrBarAnotherTypeBool, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_BarAnotherTypeBool_EType_set, _swig_p) + return +} + +func (arg1 SwigcptrBarAnotherTypeBool) SetEType(arg2 int) { + _swig_wrap_BarAnotherTypeBool_EType_set(arg1, arg2) +} + +var _wrap_BarAnotherTypeBool_EType_get unsafe.Pointer + +func _swig_wrap_BarAnotherTypeBool_EType_get(base SwigcptrBarAnotherTypeBool) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_BarAnotherTypeBool_EType_get, _swig_p) + return +} + +func (arg1 SwigcptrBarAnotherTypeBool) GetEType() (_swig_ret int) { + return _swig_wrap_BarAnotherTypeBool_EType_get(arg1) +} + +var _wrap_new_BarAnotherTypeBool__SWIG_0 unsafe.Pointer + +func _swig_wrap_new_BarAnotherTypeBool__SWIG_0(base uintptr, _ bool, _ int) (_ SwigcptrBarAnotherTypeBool) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_BarAnotherTypeBool__SWIG_0, _swig_p) + return +} + +func NewBarAnotherTypeBool__SWIG_0(arg1 AnotherType, arg2 bool, arg3 int) (_swig_ret BarAnotherTypeBool) { + return _swig_wrap_new_BarAnotherTypeBool__SWIG_0(arg1.Swigcptr(), arg2, arg3) +} + +var _wrap_BarAnotherTypeBool_method unsafe.Pointer + +func _swig_wrap_BarAnotherTypeBool_method(base SwigcptrBarAnotherTypeBool, _ uintptr, _ bool, _ int) (_ SwigcptrAnotherType) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_BarAnotherTypeBool_method, _swig_p) + return +} + +func (arg1 SwigcptrBarAnotherTypeBool) Method(arg2 AnotherType, arg3 bool, arg4 int) (_swig_ret AnotherType) { + return _swig_wrap_BarAnotherTypeBool_method(arg1, arg2.Swigcptr(), arg3, arg4) +} + +var _wrap_new_BarAnotherTypeBool__SWIG_1 unsafe.Pointer + +func _swig_wrap_new_BarAnotherTypeBool__SWIG_1(base bool, _ uintptr, _ bool, _ int) (_ SwigcptrBarAnotherTypeBool) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_BarAnotherTypeBool__SWIG_1, _swig_p) + return +} + +func NewBarAnotherTypeBool__SWIG_1(arg1 bool, arg2 AnotherType, arg3 bool, arg4 int) (_swig_ret BarAnotherTypeBool) { + return _swig_wrap_new_BarAnotherTypeBool__SWIG_1(arg1, arg2.Swigcptr(), arg3, arg4) +} + +var _wrap_BarAnotherTypeBool_method_1 unsafe.Pointer + +func _swig_wrap_BarAnotherTypeBool_method_1(base SwigcptrBarAnotherTypeBool, _ uintptr, _ bool, _ int) (_ SwigcptrAnotherType) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_BarAnotherTypeBool_method_1, _swig_p) + return +} + +func (arg1 SwigcptrBarAnotherTypeBool) Method_1(arg2 AnotherType, arg3 bool, arg4 int) (_swig_ret AnotherType) { + return _swig_wrap_BarAnotherTypeBool_method_1(arg1, arg2.Swigcptr(), arg3, arg4) +} + +var _wrap_new_BarAnotherTypeBool__SWIG_2 unsafe.Pointer + +func _swig_wrap_new_BarAnotherTypeBool__SWIG_2(base bool, _ bool, _ uintptr, _ bool, _ int) (_ SwigcptrBarAnotherTypeBool) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_BarAnotherTypeBool__SWIG_2, _swig_p) + return +} + +func NewBarAnotherTypeBool__SWIG_2(arg1 bool, arg2 bool, arg3 AnotherType, arg4 bool, arg5 int) (_swig_ret BarAnotherTypeBool) { + return _swig_wrap_new_BarAnotherTypeBool__SWIG_2(arg1, arg2, arg3.Swigcptr(), arg4, arg5) +} + +var _wrap_BarAnotherTypeBool_method_2 unsafe.Pointer + +func _swig_wrap_BarAnotherTypeBool_method_2(base SwigcptrBarAnotherTypeBool, _ uintptr, _ bool, _ int) (_ SwigcptrAnotherType) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_BarAnotherTypeBool_method_2, _swig_p) + return +} + +func (arg1 SwigcptrBarAnotherTypeBool) Method_2(arg2 AnotherType, arg3 bool, arg4 int) (_swig_ret AnotherType) { + return _swig_wrap_BarAnotherTypeBool_method_2(arg1, arg2.Swigcptr(), arg3, arg4) +} + +var _wrap_new_BarAnotherTypeBool__SWIG_3 unsafe.Pointer + +func _swig_wrap_new_BarAnotherTypeBool__SWIG_3(base bool, _ bool, _ bool, _ uintptr, _ bool, _ int) (_ SwigcptrBarAnotherTypeBool) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_BarAnotherTypeBool__SWIG_3, _swig_p) + return +} + +func NewBarAnotherTypeBool__SWIG_3(arg1 bool, arg2 bool, arg3 bool, arg4 AnotherType, arg5 bool, arg6 int) (_swig_ret BarAnotherTypeBool) { + return _swig_wrap_new_BarAnotherTypeBool__SWIG_3(arg1, arg2, arg3, arg4.Swigcptr(), arg5, arg6) +} + +func NewBarAnotherTypeBool(a ...interface{}) BarAnotherTypeBool { + argc := len(a) + if argc == 3 { + return NewBarAnotherTypeBool__SWIG_0(a[0].(AnotherType), a[1].(bool), a[2].(int)) + } + if argc == 4 { + return NewBarAnotherTypeBool__SWIG_1(a[0].(bool), a[1].(AnotherType), a[2].(bool), a[3].(int)) + } + if argc == 5 { + return NewBarAnotherTypeBool__SWIG_2(a[0].(bool), a[1].(bool), a[2].(AnotherType), a[3].(bool), a[4].(int)) + } + if argc == 6 { + return NewBarAnotherTypeBool__SWIG_3(a[0].(bool), a[1].(bool), a[2].(bool), a[3].(AnotherType), a[4].(bool), a[5].(int)) + } + panic("No match for overloaded function call") +} + +var _wrap_BarAnotherTypeBool_method_3 unsafe.Pointer + +func _swig_wrap_BarAnotherTypeBool_method_3(base SwigcptrBarAnotherTypeBool, _ uintptr, _ bool, _ int) (_ SwigcptrAnotherType) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_BarAnotherTypeBool_method_3, _swig_p) + return +} + +func (arg1 SwigcptrBarAnotherTypeBool) Method_3(arg2 AnotherType, arg3 bool, arg4 int) (_swig_ret AnotherType) { + return _swig_wrap_BarAnotherTypeBool_method_3(arg1, arg2.Swigcptr(), arg3, arg4) +} + +var _wrap_delete_BarAnotherTypeBool unsafe.Pointer + +func _swig_wrap_delete_BarAnotherTypeBool(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_BarAnotherTypeBool, _swig_p) + return +} + +func DeleteBarAnotherTypeBool(arg1 BarAnotherTypeBool) { + _swig_wrap_delete_BarAnotherTypeBool(arg1.Swigcptr()) +} + +type BarAnotherTypeBool interface { + Swigcptr() uintptr + SwigIsBarAnotherTypeBool() + SetCType(arg2 AnotherType) + GetCType() (_swig_ret AnotherType) + SetDType(arg2 bool) + GetDType() (_swig_ret bool) + SetEType(arg2 int) + GetEType() (_swig_ret int) + Method(arg2 AnotherType, arg3 bool, arg4 int) (_swig_ret AnotherType) + Method_1(arg2 AnotherType, arg3 bool, arg4 int) (_swig_ret AnotherType) + Method_2(arg2 AnotherType, arg3 bool, arg4 int) (_swig_ret AnotherType) + Method_3(arg2 AnotherType, arg3 bool, arg4 int) (_swig_ret AnotherType) +} + +type SwigcptrFooAnotherType uintptr + +func (p SwigcptrFooAnotherType) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrFooAnotherType) SwigIsFooAnotherType() { +} + +var _wrap_FooAnotherType_TType_set unsafe.Pointer + +func _swig_wrap_FooAnotherType_TType_set(base SwigcptrFooAnotherType, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_FooAnotherType_TType_set, _swig_p) + return +} + +func (arg1 SwigcptrFooAnotherType) SetTType(arg2 AnotherType) { + _swig_wrap_FooAnotherType_TType_set(arg1, arg2.Swigcptr()) +} + +var _wrap_FooAnotherType_TType_get unsafe.Pointer + +func _swig_wrap_FooAnotherType_TType_get(base SwigcptrFooAnotherType) (_ SwigcptrAnotherType) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_FooAnotherType_TType_get, _swig_p) + return +} + +func (arg1 SwigcptrFooAnotherType) GetTType() (_swig_ret AnotherType) { + return _swig_wrap_FooAnotherType_TType_get(arg1) +} + +var _wrap_new_FooAnotherType__SWIG_0 unsafe.Pointer + +func _swig_wrap_new_FooAnotherType__SWIG_0(base uintptr) (_ SwigcptrFooAnotherType) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_FooAnotherType__SWIG_0, _swig_p) + return +} + +func NewFooAnotherType__SWIG_0(arg1 AnotherType) (_swig_ret FooAnotherType) { + return _swig_wrap_new_FooAnotherType__SWIG_0(arg1.Swigcptr()) +} + +var _wrap_FooAnotherType_method unsafe.Pointer + +func _swig_wrap_FooAnotherType_method(base SwigcptrFooAnotherType, _ uintptr) (_ SwigcptrAnotherType) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_FooAnotherType_method, _swig_p) + return +} + +func (arg1 SwigcptrFooAnotherType) Method(arg2 AnotherType) (_swig_ret AnotherType) { + return _swig_wrap_FooAnotherType_method(arg1, arg2.Swigcptr()) +} + +var _wrap_new_FooAnotherType__SWIG_1 unsafe.Pointer + +func _swig_wrap_new_FooAnotherType__SWIG_1(base uintptr, _ uintptr) (_ SwigcptrFooAnotherType) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_FooAnotherType__SWIG_1, _swig_p) + return +} + +func NewFooAnotherType__SWIG_1(arg1 AnotherType, arg2 AnotherType) (_swig_ret FooAnotherType) { + return _swig_wrap_new_FooAnotherType__SWIG_1(arg1.Swigcptr(), arg2.Swigcptr()) +} + +var _wrap_FooAnotherType_method_A unsafe.Pointer + +func _swig_wrap_FooAnotherType_method_A(base SwigcptrFooAnotherType, _ uintptr) (_ SwigcptrAnotherType) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_FooAnotherType_method_A, _swig_p) + return +} + +func (arg1 SwigcptrFooAnotherType) Method_A(arg2 AnotherType) (_swig_ret AnotherType) { + return _swig_wrap_FooAnotherType_method_A(arg1, arg2.Swigcptr()) +} + +var _wrap_new_FooAnotherType__SWIG_2 unsafe.Pointer + +func _swig_wrap_new_FooAnotherType__SWIG_2(base uintptr, _ uintptr, _ uintptr) (_ SwigcptrFooAnotherType) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_FooAnotherType__SWIG_2, _swig_p) + return +} + +func NewFooAnotherType__SWIG_2(arg1 AnotherType, arg2 AnotherType, arg3 AnotherType) (_swig_ret FooAnotherType) { + return _swig_wrap_new_FooAnotherType__SWIG_2(arg1.Swigcptr(), arg2.Swigcptr(), arg3.Swigcptr()) +} + +var _wrap_FooAnotherType_method_B unsafe.Pointer + +func _swig_wrap_FooAnotherType_method_B(base SwigcptrFooAnotherType, _ uintptr) (_ SwigcptrAnotherType) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_FooAnotherType_method_B, _swig_p) + return +} + +func (arg1 SwigcptrFooAnotherType) Method_B(arg2 AnotherType) (_swig_ret AnotherType) { + return _swig_wrap_FooAnotherType_method_B(arg1, arg2.Swigcptr()) +} + +var _wrap_new_FooAnotherType__SWIG_3 unsafe.Pointer + +func _swig_wrap_new_FooAnotherType__SWIG_3(base uintptr, _ uintptr, _ uintptr, _ uintptr) (_ SwigcptrFooAnotherType) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_FooAnotherType__SWIG_3, _swig_p) + return +} + +func NewFooAnotherType__SWIG_3(arg1 AnotherType, arg2 AnotherType, arg3 AnotherType, arg4 AnotherType) (_swig_ret FooAnotherType) { + return _swig_wrap_new_FooAnotherType__SWIG_3(arg1.Swigcptr(), arg2.Swigcptr(), arg3.Swigcptr(), arg4.Swigcptr()) +} + +func NewFooAnotherType(a ...interface{}) FooAnotherType { + argc := len(a) + if argc == 1 { + return NewFooAnotherType__SWIG_0(a[0].(AnotherType)) + } + if argc == 2 { + return NewFooAnotherType__SWIG_1(a[0].(AnotherType), a[1].(AnotherType)) + } + if argc == 3 { + return NewFooAnotherType__SWIG_2(a[0].(AnotherType), a[1].(AnotherType), a[2].(AnotherType)) + } + if argc == 4 { + return NewFooAnotherType__SWIG_3(a[0].(AnotherType), a[1].(AnotherType), a[2].(AnotherType), a[3].(AnotherType)) + } + panic("No match for overloaded function call") +} + +var _wrap_FooAnotherType_method_C unsafe.Pointer + +func _swig_wrap_FooAnotherType_method_C(base SwigcptrFooAnotherType, _ uintptr) (_ SwigcptrAnotherType) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_FooAnotherType_method_C, _swig_p) + return +} + +func (arg1 SwigcptrFooAnotherType) Method_C(arg2 AnotherType) (_swig_ret AnotherType) { + return _swig_wrap_FooAnotherType_method_C(arg1, arg2.Swigcptr()) +} + +var _wrap_delete_FooAnotherType unsafe.Pointer + +func _swig_wrap_delete_FooAnotherType(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_FooAnotherType, _swig_p) + return +} + +func DeleteFooAnotherType(arg1 FooAnotherType) { + _swig_wrap_delete_FooAnotherType(arg1.Swigcptr()) +} + +type FooAnotherType interface { + Swigcptr() uintptr + SwigIsFooAnotherType() + SetTType(arg2 AnotherType) + GetTType() (_swig_ret AnotherType) + Method(arg2 AnotherType) (_swig_ret AnotherType) + Method_A(arg2 AnotherType) (_swig_ret AnotherType) + Method_B(arg2 AnotherType) (_swig_ret AnotherType) + Method_C(arg2 AnotherType) (_swig_ret AnotherType) +} + +type SwigcptrUsesBarDouble uintptr + +func (p SwigcptrUsesBarDouble) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrUsesBarDouble) SwigIsUsesBarDouble() { +} + +var _wrap_UsesBarDouble_use_A unsafe.Pointer + +func _swig_wrap_UsesBarDouble_use_A(base SwigcptrUsesBarDouble, _ float64, _ uintptr, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_UsesBarDouble_use_A, _swig_p) + return +} + +func (arg1 SwigcptrUsesBarDouble) Use_A(arg2 float64, arg3 SomeType, arg4 int) { + _swig_wrap_UsesBarDouble_use_A(arg1, arg2, arg3.Swigcptr(), arg4) +} + +var _wrap_UsesBarDouble_use_B unsafe.Pointer + +func _swig_wrap_UsesBarDouble_use_B(base SwigcptrUsesBarDouble, _ float64, _ uintptr, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_UsesBarDouble_use_B, _swig_p) + return +} + +func (arg1 SwigcptrUsesBarDouble) Use_B(arg2 float64, arg3 SomeType, arg4 int) { + _swig_wrap_UsesBarDouble_use_B(arg1, arg2, arg3.Swigcptr(), arg4) +} + +var _wrap_UsesBarDouble_use_C unsafe.Pointer + +func _swig_wrap_UsesBarDouble_use_C(base SwigcptrUsesBarDouble, _ float64, _ uintptr, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_UsesBarDouble_use_C, _swig_p) + return +} + +func (arg1 SwigcptrUsesBarDouble) Use_C(arg2 float64, arg3 SomeType, arg4 int) { + _swig_wrap_UsesBarDouble_use_C(arg1, arg2, arg3.Swigcptr(), arg4) +} + +var _wrap_UsesBarDouble_use_D unsafe.Pointer + +func _swig_wrap_UsesBarDouble_use_D(base SwigcptrUsesBarDouble, _ float64, _ uintptr, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_UsesBarDouble_use_D, _swig_p) + return +} + +func (arg1 SwigcptrUsesBarDouble) Use_D(arg2 float64, arg3 SomeType, arg4 int) { + _swig_wrap_UsesBarDouble_use_D(arg1, arg2, arg3.Swigcptr(), arg4) +} + +var _wrap_new_UsesBarDouble unsafe.Pointer + +func _swig_wrap_new_UsesBarDouble() (base SwigcptrUsesBarDouble) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_UsesBarDouble, _swig_p) + return +} + +func NewUsesBarDouble() (_swig_ret UsesBarDouble) { + return _swig_wrap_new_UsesBarDouble() +} + +var _wrap_delete_UsesBarDouble unsafe.Pointer + +func _swig_wrap_delete_UsesBarDouble(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_UsesBarDouble, _swig_p) + return +} + +func DeleteUsesBarDouble(arg1 UsesBarDouble) { + _swig_wrap_delete_UsesBarDouble(arg1.Swigcptr()) +} + +type UsesBarDouble interface { + Swigcptr() uintptr + SwigIsUsesBarDouble() + Use_A(arg2 float64, arg3 SomeType, arg4 int) + Use_B(arg2 float64, arg3 SomeType, arg4 int) + Use_C(arg2 float64, arg3 SomeType, arg4 int) + Use_D(arg2 float64, arg3 SomeType, arg4 int) +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/template_default_inherit.go b/Examples/test-suite/go/template_default_inherit.go new file mode 100644 index 000000000..6fae760d6 --- /dev/null +++ b/Examples/test-suite/go/template_default_inherit.go @@ -0,0 +1,168 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../template_default_inherit.i + +package template_default_inherit + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrA_int uintptr + +func (p SwigcptrA_int) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrA_int) SwigIsA_int() { +} + +var _wrap_A_int_nindex_A_int unsafe.Pointer + +func _swig_getA_int_A_int_nindex_A_int() (_swig_ret uint) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_A_int_nindex_A_int, _swig_p) + return +} +var A_intNindex uint = _swig_getA_int_A_int_nindex_A_int() +var _wrap_new_A_int unsafe.Pointer + +func _swig_wrap_new_A_int() (base SwigcptrA_int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_A_int, _swig_p) + return +} + +func NewA_int() (_swig_ret A_int) { + return _swig_wrap_new_A_int() +} + +var _wrap_delete_A_int unsafe.Pointer + +func _swig_wrap_delete_A_int(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_A_int, _swig_p) + return +} + +func DeleteA_int(arg1 A_int) { + _swig_wrap_delete_A_int(arg1.Swigcptr()) +} + +type A_int interface { + Swigcptr() uintptr + SwigIsA_int() +} + +type SwigcptrB_int uintptr + +func (p SwigcptrB_int) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrB_int) SwigIsB_int() { +} + +var _wrap_B_int_say_hi__SWIG_0 unsafe.Pointer + +func _swig_wrap_B_int_say_hi__SWIG_0(base SwigcptrB_int, _ uint) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_B_int_say_hi__SWIG_0, _swig_p) + return +} + +func (arg1 SwigcptrB_int) Say_hi__SWIG_0(arg2 uint) { + _swig_wrap_B_int_say_hi__SWIG_0(arg1, arg2) +} + +var _wrap_B_int_say_hi__SWIG_1 unsafe.Pointer + +func _swig_wrap_B_int_say_hi__SWIG_1(base SwigcptrB_int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_B_int_say_hi__SWIG_1, _swig_p) + return +} + +func (arg1 SwigcptrB_int) Say_hi__SWIG_1() { + _swig_wrap_B_int_say_hi__SWIG_1(arg1) +} + +func (p SwigcptrB_int) Say_hi(a ...interface{}) { + argc := len(a) + if argc == 0 { + p.Say_hi__SWIG_1() + return + } + if argc == 1 { + p.Say_hi__SWIG_0(a[0].(uint)) + return + } + panic("No match for overloaded function call") +} + +var _wrap_new_B_int unsafe.Pointer + +func _swig_wrap_new_B_int() (base SwigcptrB_int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_B_int, _swig_p) + return +} + +func NewB_int() (_swig_ret B_int) { + return _swig_wrap_new_B_int() +} + +var _wrap_delete_B_int unsafe.Pointer + +func _swig_wrap_delete_B_int(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_B_int, _swig_p) + return +} + +func DeleteB_int(arg1 B_int) { + _swig_wrap_delete_B_int(arg1.Swigcptr()) +} + +func (p SwigcptrB_int) SwigIsA_int() { +} + +func (p SwigcptrB_int) SwigGetA_int() A_int { + return SwigcptrA_int(p.Swigcptr()) +} + +type B_int interface { + Swigcptr() uintptr + SwigIsB_int() + Say_hi(a ...interface{}) + SwigIsA_int() + SwigGetA_int() A_int +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/template_default_qualify.go b/Examples/test-suite/go/template_default_qualify.go new file mode 100644 index 000000000..067fd7e88 --- /dev/null +++ b/Examples/test-suite/go/template_default_qualify.go @@ -0,0 +1,241 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../template_default_qualify.i + +package template_default_qualify + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type OssPolarization int +var _wrap_UnaryPolarization unsafe.Pointer + +func _swig_getUnaryPolarization() (_swig_ret OssPolarization) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_UnaryPolarization, _swig_p) + return +} +var UnaryPolarization OssPolarization = _swig_getUnaryPolarization() +var _wrap_BinaryPolarization unsafe.Pointer + +func _swig_getBinaryPolarization() (_swig_ret OssPolarization) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_BinaryPolarization, _swig_p) + return +} +var BinaryPolarization OssPolarization = _swig_getBinaryPolarization() +type SwigcptrEtraits uintptr + +func (p SwigcptrEtraits) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrEtraits) SwigIsEtraits() { +} + +var _wrap_etraits_pmode_etraits unsafe.Pointer + +func _swig_getetraits_etraits_pmode_etraits() (_swig_ret OssPolarization) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_etraits_pmode_etraits, _swig_p) + return +} +var EtraitsPmode OssPolarization = _swig_getetraits_etraits_pmode_etraits() +var _wrap_new_etraits unsafe.Pointer + +func _swig_wrap_new_etraits() (base SwigcptrEtraits) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_etraits, _swig_p) + return +} + +func NewEtraits() (_swig_ret Etraits) { + return _swig_wrap_new_etraits() +} + +var _wrap_delete_etraits unsafe.Pointer + +func _swig_wrap_delete_etraits(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_etraits, _swig_p) + return +} + +func DeleteEtraits(arg1 Etraits) { + _swig_wrap_delete_etraits(arg1.Swigcptr()) +} + +type Etraits interface { + Swigcptr() uintptr + SwigIsEtraits() +} + +type SwigcptrInterface_UP uintptr + +func (p SwigcptrInterface_UP) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrInterface_UP) SwigIsInterface_UP() { +} + +var _wrap_new_Interface_UP unsafe.Pointer + +func _swig_wrap_new_Interface_UP() (base SwigcptrInterface_UP) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Interface_UP, _swig_p) + return +} + +func NewInterface_UP() (_swig_ret Interface_UP) { + return _swig_wrap_new_Interface_UP() +} + +var _wrap_delete_Interface_UP unsafe.Pointer + +func _swig_wrap_delete_Interface_UP(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Interface_UP, _swig_p) + return +} + +func DeleteInterface_UP(arg1 Interface_UP) { + _swig_wrap_delete_Interface_UP(arg1.Swigcptr()) +} + +type Interface_UP interface { + Swigcptr() uintptr + SwigIsInterface_UP() +} + +type SwigcptrModule_etraits uintptr + +func (p SwigcptrModule_etraits) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrModule_etraits) SwigIsModule_etraits() { +} + +var _wrap_new_Module_etraits unsafe.Pointer + +func _swig_wrap_new_Module_etraits() (base SwigcptrModule_etraits) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Module_etraits, _swig_p) + return +} + +func NewModule_etraits() (_swig_ret Module_etraits) { + return _swig_wrap_new_Module_etraits() +} + +var _wrap_delete_Module_etraits unsafe.Pointer + +func _swig_wrap_delete_Module_etraits(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Module_etraits, _swig_p) + return +} + +func DeleteModule_etraits(arg1 Module_etraits) { + _swig_wrap_delete_Module_etraits(arg1.Swigcptr()) +} + +func (p SwigcptrModule_etraits) SwigIsInterface_UP() { +} + +func (p SwigcptrModule_etraits) SwigGetInterface_UP() Interface_UP { + return SwigcptrInterface_UP(p.Swigcptr()) +} + +type Module_etraits interface { + Swigcptr() uintptr + SwigIsModule_etraits() + SwigIsInterface_UP() + SwigGetInterface_UP() Interface_UP +} + +type SwigcptrHModule1 uintptr + +func (p SwigcptrHModule1) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrHModule1) SwigIsHModule1() { +} + +var _wrap_new_HModule1 unsafe.Pointer + +func _swig_wrap_new_HModule1() (base SwigcptrHModule1) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_HModule1, _swig_p) + return +} + +func NewHModule1() (_swig_ret HModule1) { + return _swig_wrap_new_HModule1() +} + +var _wrap_delete_HModule1 unsafe.Pointer + +func _swig_wrap_delete_HModule1(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_HModule1, _swig_p) + return +} + +func DeleteHModule1(arg1 HModule1) { + _swig_wrap_delete_HModule1(arg1.Swigcptr()) +} + +func (p SwigcptrHModule1) SwigIsModule_etraits() { +} + +func (p SwigcptrHModule1) SwigGetModule_etraits() Module_etraits { + return SwigcptrModule_etraits(p.Swigcptr()) +} + +func (p SwigcptrHModule1) SwigIsInterface_UP() { +} + +func (p SwigcptrHModule1) SwigGetInterface_UP() Interface_UP { + return SwigcptrInterface_UP(p.Swigcptr()) +} + +type HModule1 interface { + Swigcptr() uintptr + SwigIsHModule1() + SwigIsModule_etraits() + SwigGetModule_etraits() Module_etraits + SwigIsInterface_UP() + SwigGetInterface_UP() Interface_UP +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/template_default_vw.go b/Examples/test-suite/go/template_default_vw.go new file mode 100644 index 000000000..01c110ce4 --- /dev/null +++ b/Examples/test-suite/go/template_default_vw.go @@ -0,0 +1,159 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../template_default_vw.i + +package template_default_vw + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrSomeClass uintptr + +func (p SwigcptrSomeClass) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrSomeClass) SwigIsSomeClass() { +} + +var _wrap_new_SomeClass unsafe.Pointer + +func _swig_wrap_new_SomeClass() (base SwigcptrSomeClass) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_SomeClass, _swig_p) + return +} + +func NewSomeClass() (_swig_ret SomeClass) { + return _swig_wrap_new_SomeClass() +} + +var _wrap_delete_SomeClass unsafe.Pointer + +func _swig_wrap_delete_SomeClass(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_SomeClass, _swig_p) + return +} + +func DeleteSomeClass(arg1 SomeClass) { + _swig_wrap_delete_SomeClass(arg1.Swigcptr()) +} + +type SomeClass interface { + Swigcptr() uintptr + SwigIsSomeClass() +} + +type SwigcptrAnotherClass uintptr + +func (p SwigcptrAnotherClass) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrAnotherClass) SwigIsAnotherClass() { +} + +var _wrap_AnotherClass_someFunc__SWIG_0 unsafe.Pointer + +func _swig_wrap_AnotherClass_someFunc__SWIG_0(base SwigcptrAnotherClass, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_AnotherClass_someFunc__SWIG_0, _swig_p) + return +} + +func (arg1 SwigcptrAnotherClass) SomeFunc__SWIG_0(arg2 Handle_Sl_SomeClass_Sg_) { + _swig_wrap_AnotherClass_someFunc__SWIG_0(arg1, arg2.Swigcptr()) +} + +var _wrap_AnotherClass_someFunc__SWIG_1 unsafe.Pointer + +func _swig_wrap_AnotherClass_someFunc__SWIG_1(base SwigcptrAnotherClass) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_AnotherClass_someFunc__SWIG_1, _swig_p) + return +} + +func (arg1 SwigcptrAnotherClass) SomeFunc__SWIG_1() { + _swig_wrap_AnotherClass_someFunc__SWIG_1(arg1) +} + +func (p SwigcptrAnotherClass) SomeFunc(a ...interface{}) { + argc := len(a) + if argc == 0 { + p.SomeFunc__SWIG_1() + return + } + if argc == 1 { + p.SomeFunc__SWIG_0(a[0].(Handle_Sl_SomeClass_Sg_)) + return + } + panic("No match for overloaded function call") +} + +var _wrap_new_AnotherClass unsafe.Pointer + +func _swig_wrap_new_AnotherClass() (base SwigcptrAnotherClass) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_AnotherClass, _swig_p) + return +} + +func NewAnotherClass() (_swig_ret AnotherClass) { + return _swig_wrap_new_AnotherClass() +} + +var _wrap_delete_AnotherClass unsafe.Pointer + +func _swig_wrap_delete_AnotherClass(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_AnotherClass, _swig_p) + return +} + +func DeleteAnotherClass(arg1 AnotherClass) { + _swig_wrap_delete_AnotherClass(arg1.Swigcptr()) +} + +type AnotherClass interface { + Swigcptr() uintptr + SwigIsAnotherClass() + SomeFunc(a ...interface{}) +} + + +type SwigcptrHandle_Sl_SomeClass_Sg_ uintptr +type Handle_Sl_SomeClass_Sg_ interface { + Swigcptr() uintptr; +} +func (p SwigcptrHandle_Sl_SomeClass_Sg_) Swigcptr() uintptr { + return uintptr(p) +} + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/template_enum.go b/Examples/test-suite/go/template_enum.go new file mode 100644 index 000000000..2fc607b4e --- /dev/null +++ b/Examples/test-suite/go/template_enum.go @@ -0,0 +1,263 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../template_enum.i + +package template_enum + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrFoo_i uintptr + +func (p SwigcptrFoo_i) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrFoo_i) SwigIsFoo_i() { +} + +var _wrap_FOO_foo_i unsafe.Pointer + +func _swig_getfoo_i_FOO_foo_i() (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_FOO_foo_i, _swig_p) + return +} +var Foo_iFOO int = _swig_getfoo_i_FOO_foo_i() +var _wrap_BAR_foo_i unsafe.Pointer + +func _swig_getfoo_i_BAR_foo_i() (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_BAR_foo_i, _swig_p) + return +} +var Foo_iBAR int = _swig_getfoo_i_BAR_foo_i() +var _wrap_new_foo_i unsafe.Pointer + +func _swig_wrap_new_foo_i() (base SwigcptrFoo_i) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_foo_i, _swig_p) + return +} + +func NewFoo_i() (_swig_ret Foo_i) { + return _swig_wrap_new_foo_i() +} + +var _wrap_delete_foo_i unsafe.Pointer + +func _swig_wrap_delete_foo_i(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_foo_i, _swig_p) + return +} + +func DeleteFoo_i(arg1 Foo_i) { + _swig_wrap_delete_foo_i(arg1.Swigcptr()) +} + +type Foo_i interface { + Swigcptr() uintptr + SwigIsFoo_i() +} + +type SwigcptrFoo_d uintptr + +func (p SwigcptrFoo_d) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrFoo_d) SwigIsFoo_d() { +} + +var _wrap_FOO_foo_d unsafe.Pointer + +func _swig_getfoo_d_FOO_foo_d() (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_FOO_foo_d, _swig_p) + return +} +var Foo_dFOO int = _swig_getfoo_d_FOO_foo_d() +var _wrap_BAR_foo_d unsafe.Pointer + +func _swig_getfoo_d_BAR_foo_d() (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_BAR_foo_d, _swig_p) + return +} +var Foo_dBAR int = _swig_getfoo_d_BAR_foo_d() +var _wrap_new_foo_d unsafe.Pointer + +func _swig_wrap_new_foo_d() (base SwigcptrFoo_d) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_foo_d, _swig_p) + return +} + +func NewFoo_d() (_swig_ret Foo_d) { + return _swig_wrap_new_foo_d() +} + +var _wrap_delete_foo_d unsafe.Pointer + +func _swig_wrap_delete_foo_d(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_foo_d, _swig_p) + return +} + +func DeleteFoo_d(arg1 Foo_d) { + _swig_wrap_delete_foo_d(arg1.Swigcptr()) +} + +type Foo_d interface { + Swigcptr() uintptr + SwigIsFoo_d() +} + +type SwigcptrRGBTraits uintptr + +func (p SwigcptrRGBTraits) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrRGBTraits) SwigIsRGBTraits() { +} + +var _wrap_NumComponents_RGBTraits unsafe.Pointer + +func _swig_getRGBTraits_NumComponents_RGBTraits() (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_NumComponents_RGBTraits, _swig_p) + return +} +var RGBTraitsNumComponents int = _swig_getRGBTraits_NumComponents_RGBTraits() +var _wrap_new_RGBTraits unsafe.Pointer + +func _swig_wrap_new_RGBTraits() (base SwigcptrRGBTraits) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_RGBTraits, _swig_p) + return +} + +func NewRGBTraits() (_swig_ret RGBTraits) { + return _swig_wrap_new_RGBTraits() +} + +var _wrap_delete_RGBTraits unsafe.Pointer + +func _swig_wrap_delete_RGBTraits(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_RGBTraits, _swig_p) + return +} + +func DeleteRGBTraits(arg1 RGBTraits) { + _swig_wrap_delete_RGBTraits(arg1.Swigcptr()) +} + +type RGBTraits interface { + Swigcptr() uintptr + SwigIsRGBTraits() +} + +type SwigcptrColor uintptr + +func (p SwigcptrColor) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrColor) SwigIsColor() { +} + +var _wrap_NumComponents_Color unsafe.Pointer + +func _swig_getColor_NumComponents_Color() (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_NumComponents_Color, _swig_p) + return +} +var ColorNumComponents int = _swig_getColor_NumComponents_Color() +var _wrap_Color_data_set unsafe.Pointer + +func _swig_wrap_Color_data_set(base SwigcptrColor, _ *float32) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Color_data_set, _swig_p) + return +} + +func (arg1 SwigcptrColor) SetData(arg2 *float32) { + _swig_wrap_Color_data_set(arg1, arg2) +} + +var _wrap_Color_data_get unsafe.Pointer + +func _swig_wrap_Color_data_get(base SwigcptrColor) (_ *float32) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Color_data_get, _swig_p) + return +} + +func (arg1 SwigcptrColor) GetData() (_swig_ret *float32) { + return _swig_wrap_Color_data_get(arg1) +} + +var _wrap_new_Color unsafe.Pointer + +func _swig_wrap_new_Color() (base SwigcptrColor) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Color, _swig_p) + return +} + +func NewColor() (_swig_ret Color) { + return _swig_wrap_new_Color() +} + +var _wrap_delete_Color unsafe.Pointer + +func _swig_wrap_delete_Color(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Color, _swig_p) + return +} + +func DeleteColor(arg1 Color) { + _swig_wrap_delete_Color(arg1.Swigcptr()) +} + +type Color interface { + Swigcptr() uintptr + SwigIsColor() + SetData(arg2 *float32) + GetData() (_swig_ret *float32) +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/template_enum_ns_inherit.go b/Examples/test-suite/go/template_enum_ns_inherit.go new file mode 100644 index 000000000..ddb617e92 --- /dev/null +++ b/Examples/test-suite/go/template_enum_ns_inherit.go @@ -0,0 +1,271 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../template_enum_ns_inherit.i + +package template_enum_ns_inherit + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type OssPolarization int +var _wrap_UnaryPolarization unsafe.Pointer + +func _swig_getUnaryPolarization() (_swig_ret OssPolarization) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_UnaryPolarization, _swig_p) + return +} +var UnaryPolarization OssPolarization = _swig_getUnaryPolarization() +var _wrap_BinaryPolarization unsafe.Pointer + +func _swig_getBinaryPolarization() (_swig_ret OssPolarization) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_BinaryPolarization, _swig_p) + return +} +var BinaryPolarization OssPolarization = _swig_getBinaryPolarization() +type SwigcptrInterface_UP uintptr + +func (p SwigcptrInterface_UP) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrInterface_UP) SwigIsInterface_UP() { +} + +var _wrap_new_Interface_UP unsafe.Pointer + +func _swig_wrap_new_Interface_UP() (base SwigcptrInterface_UP) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Interface_UP, _swig_p) + return +} + +func NewInterface_UP() (_swig_ret Interface_UP) { + return _swig_wrap_new_Interface_UP() +} + +var _wrap_delete_Interface_UP unsafe.Pointer + +func _swig_wrap_delete_Interface_UP(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Interface_UP, _swig_p) + return +} + +func DeleteInterface_UP(arg1 Interface_UP) { + _swig_wrap_delete_Interface_UP(arg1.Swigcptr()) +} + +type Interface_UP interface { + Swigcptr() uintptr + SwigIsInterface_UP() +} + +type SwigcptrModule_UPIUP uintptr + +func (p SwigcptrModule_UPIUP) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrModule_UPIUP) SwigIsModule_UPIUP() { +} + +var _wrap_new_Module_UPIUP unsafe.Pointer + +func _swig_wrap_new_Module_UPIUP() (base SwigcptrModule_UPIUP) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Module_UPIUP, _swig_p) + return +} + +func NewModule_UPIUP() (_swig_ret Module_UPIUP) { + return _swig_wrap_new_Module_UPIUP() +} + +var _wrap_delete_Module_UPIUP unsafe.Pointer + +func _swig_wrap_delete_Module_UPIUP(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Module_UPIUP, _swig_p) + return +} + +func DeleteModule_UPIUP(arg1 Module_UPIUP) { + _swig_wrap_delete_Module_UPIUP(arg1.Swigcptr()) +} + +type Module_UPIUP interface { + Swigcptr() uintptr + SwigIsModule_UPIUP() +} + +type SwigcptrHInterface1 uintptr + +func (p SwigcptrHInterface1) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrHInterface1) SwigIsHInterface1() { +} + +var _wrap_new_HInterface1 unsafe.Pointer + +func _swig_wrap_new_HInterface1() (base SwigcptrHInterface1) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_HInterface1, _swig_p) + return +} + +func NewHInterface1() (_swig_ret HInterface1) { + return _swig_wrap_new_HInterface1() +} + +var _wrap_delete_HInterface1 unsafe.Pointer + +func _swig_wrap_delete_HInterface1(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_HInterface1, _swig_p) + return +} + +func DeleteHInterface1(arg1 HInterface1) { + _swig_wrap_delete_HInterface1(arg1.Swigcptr()) +} + +func (p SwigcptrHInterface1) SwigIsInterface_UP() { +} + +func (p SwigcptrHInterface1) SwigGetInterface_UP() Interface_UP { + return SwigcptrInterface_UP(p.Swigcptr()) +} + +type HInterface1 interface { + Swigcptr() uintptr + SwigIsHInterface1() + SwigIsInterface_UP() + SwigGetInterface_UP() Interface_UP +} + +type SwigcptrHInterface2 uintptr + +func (p SwigcptrHInterface2) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrHInterface2) SwigIsHInterface2() { +} + +var _wrap_new_HInterface2 unsafe.Pointer + +func _swig_wrap_new_HInterface2() (base SwigcptrHInterface2) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_HInterface2, _swig_p) + return +} + +func NewHInterface2() (_swig_ret HInterface2) { + return _swig_wrap_new_HInterface2() +} + +var _wrap_delete_HInterface2 unsafe.Pointer + +func _swig_wrap_delete_HInterface2(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_HInterface2, _swig_p) + return +} + +func DeleteHInterface2(arg1 HInterface2) { + _swig_wrap_delete_HInterface2(arg1.Swigcptr()) +} + +func (p SwigcptrHInterface2) SwigIsInterface_UP() { +} + +func (p SwigcptrHInterface2) SwigGetInterface_UP() Interface_UP { + return SwigcptrInterface_UP(p.Swigcptr()) +} + +type HInterface2 interface { + Swigcptr() uintptr + SwigIsHInterface2() + SwigIsInterface_UP() + SwigGetInterface_UP() Interface_UP +} + +type SwigcptrHModule1 uintptr + +func (p SwigcptrHModule1) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrHModule1) SwigIsHModule1() { +} + +var _wrap_new_HModule1 unsafe.Pointer + +func _swig_wrap_new_HModule1() (base SwigcptrHModule1) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_HModule1, _swig_p) + return +} + +func NewHModule1() (_swig_ret HModule1) { + return _swig_wrap_new_HModule1() +} + +var _wrap_delete_HModule1 unsafe.Pointer + +func _swig_wrap_delete_HModule1(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_HModule1, _swig_p) + return +} + +func DeleteHModule1(arg1 HModule1) { + _swig_wrap_delete_HModule1(arg1.Swigcptr()) +} + +func (p SwigcptrHModule1) SwigIsModule_UPIUP() { +} + +func (p SwigcptrHModule1) SwigGetModule_UPIUP() Module_UPIUP { + return SwigcptrModule_UPIUP(p.Swigcptr()) +} + +type HModule1 interface { + Swigcptr() uintptr + SwigIsHModule1() + SwigIsModule_UPIUP() + SwigGetModule_UPIUP() Module_UPIUP +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/template_enum_typedef.go b/Examples/test-suite/go/template_enum_typedef.go new file mode 100644 index 000000000..9a6ed25cd --- /dev/null +++ b/Examples/test-suite/go/template_enum_typedef.go @@ -0,0 +1,197 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../template_enum_typedef.i + +package template_enum_typedef + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type OssPolarization int +var _wrap_UnaryPolarization unsafe.Pointer + +func _swig_getUnaryPolarization() (_swig_ret OssPolarization) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_UnaryPolarization, _swig_p) + return +} +var UnaryPolarization OssPolarization = _swig_getUnaryPolarization() +var _wrap_BinaryPolarization unsafe.Pointer + +func _swig_getBinaryPolarization() (_swig_ret OssPolarization) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_BinaryPolarization, _swig_p) + return +} +var BinaryPolarization OssPolarization = _swig_getBinaryPolarization() +type SwigcptrEtraits uintptr + +func (p SwigcptrEtraits) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrEtraits) SwigIsEtraits() { +} + +var _wrap_etraits_pmode_etraits unsafe.Pointer + +func _swig_getetraits_etraits_pmode_etraits() (_swig_ret OssPolarization) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_etraits_pmode_etraits, _swig_p) + return +} +var EtraitsPmode OssPolarization = _swig_getetraits_etraits_pmode_etraits() +var _wrap_new_etraits unsafe.Pointer + +func _swig_wrap_new_etraits() (base SwigcptrEtraits) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_etraits, _swig_p) + return +} + +func NewEtraits() (_swig_ret Etraits) { + return _swig_wrap_new_etraits() +} + +var _wrap_delete_etraits unsafe.Pointer + +func _swig_wrap_delete_etraits(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_etraits, _swig_p) + return +} + +func DeleteEtraits(arg1 Etraits) { + _swig_wrap_delete_etraits(arg1.Swigcptr()) +} + +type Etraits interface { + Swigcptr() uintptr + SwigIsEtraits() +} + +type SwigcptrInterface_UP uintptr + +func (p SwigcptrInterface_UP) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrInterface_UP) SwigIsInterface_UP() { +} + +var _wrap_new_Interface_UP unsafe.Pointer + +func _swig_wrap_new_Interface_UP() (base SwigcptrInterface_UP) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Interface_UP, _swig_p) + return +} + +func NewInterface_UP() (_swig_ret Interface_UP) { + return _swig_wrap_new_Interface_UP() +} + +var _wrap_delete_Interface_UP unsafe.Pointer + +func _swig_wrap_delete_Interface_UP(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Interface_UP, _swig_p) + return +} + +func DeleteInterface_UP(arg1 Interface_UP) { + _swig_wrap_delete_Interface_UP(arg1.Swigcptr()) +} + +type Interface_UP interface { + Swigcptr() uintptr + SwigIsInterface_UP() +} + +type SwigcptrModule_UP uintptr + +func (p SwigcptrModule_UP) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrModule_UP) SwigIsModule_UP() { +} + +var _wrap_Module_UP_P_Module_UP unsafe.Pointer + +func _swig_getModule_UP_Module_UP_P_Module_UP() (_swig_ret OssPolarization) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_Module_UP_P_Module_UP, _swig_p) + return +} +var Module_UPP OssPolarization = _swig_getModule_UP_Module_UP_P_Module_UP() +var _wrap_Module_UP_get unsafe.Pointer + +func _swig_wrap_Module_UP_get(base SwigcptrModule_UP, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Module_UP_get, _swig_p) + return +} + +func (arg1 SwigcptrModule_UP) Get(arg2 Interface_UP) { + _swig_wrap_Module_UP_get(arg1, arg2.Swigcptr()) +} + +var _wrap_new_Module_UP unsafe.Pointer + +func _swig_wrap_new_Module_UP() (base SwigcptrModule_UP) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Module_UP, _swig_p) + return +} + +func NewModule_UP() (_swig_ret Module_UP) { + return _swig_wrap_new_Module_UP() +} + +var _wrap_delete_Module_UP unsafe.Pointer + +func _swig_wrap_delete_Module_UP(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Module_UP, _swig_p) + return +} + +func DeleteModule_UP(arg1 Module_UP) { + _swig_wrap_delete_Module_UP(arg1.Swigcptr()) +} + +type Module_UP interface { + Swigcptr() uintptr + SwigIsModule_UP() + Get(arg2 Interface_UP) +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/template_explicit.go b/Examples/test-suite/go/template_explicit.go new file mode 100644 index 000000000..69f91688e --- /dev/null +++ b/Examples/test-suite/go/template_explicit.go @@ -0,0 +1,289 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../template_explicit.i + +package template_explicit + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +var _wrap_maxint unsafe.Pointer + +func Maxint(arg1 int, arg2 int) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_maxint, _swig_p) + return +} +var _wrap_maxdouble unsafe.Pointer + +func Maxdouble(arg1 float64, arg2 float64) (_swig_ret float64) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_maxdouble, _swig_p) + return +} +type SwigcptrVecint uintptr + +func (p SwigcptrVecint) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrVecint) SwigIsVecint() { +} + +var _wrap_new_vecint unsafe.Pointer + +func _swig_wrap_new_vecint(base int) (_ SwigcptrVecint) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_vecint, _swig_p) + return +} + +func NewVecint(arg1 int) (_swig_ret Vecint) { + return _swig_wrap_new_vecint(arg1) +} + +var _wrap_vecint_get unsafe.Pointer + +func _swig_wrap_vecint_get(base SwigcptrVecint, _ int) (_ *int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_vecint_get, _swig_p) + return +} + +func (arg1 SwigcptrVecint) Get(arg2 int) (_swig_ret *int) { + return _swig_wrap_vecint_get(arg1, arg2) +} + +var _wrap_vecint_set unsafe.Pointer + +func _swig_wrap_vecint_set(base SwigcptrVecint, _ int, _ *int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_vecint_set, _swig_p) + return +} + +func (arg1 SwigcptrVecint) Set(arg2 int, arg3 *int) { + _swig_wrap_vecint_set(arg1, arg2, arg3) +} + +var _wrap_vecint_testconst unsafe.Pointer + +func _swig_wrap_vecint_testconst(base SwigcptrVecint, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_vecint_testconst, _swig_p) + return +} + +func (arg1 SwigcptrVecint) Testconst(arg2 int) { + _swig_wrap_vecint_testconst(arg1, arg2) +} + +var _wrap_delete_vecint unsafe.Pointer + +func _swig_wrap_delete_vecint(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_vecint, _swig_p) + return +} + +func DeleteVecint(arg1 Vecint) { + _swig_wrap_delete_vecint(arg1.Swigcptr()) +} + +type Vecint interface { + Swigcptr() uintptr + SwigIsVecint() + Get(arg2 int) (_swig_ret *int) + Set(arg2 int, arg3 *int) + Testconst(arg2 int) +} + +type SwigcptrVecdouble uintptr + +func (p SwigcptrVecdouble) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrVecdouble) SwigIsVecdouble() { +} + +var _wrap_new_vecdouble unsafe.Pointer + +func _swig_wrap_new_vecdouble(base int) (_ SwigcptrVecdouble) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_vecdouble, _swig_p) + return +} + +func NewVecdouble(arg1 int) (_swig_ret Vecdouble) { + return _swig_wrap_new_vecdouble(arg1) +} + +var _wrap_vecdouble_get unsafe.Pointer + +func _swig_wrap_vecdouble_get(base SwigcptrVecdouble, _ int) (_ *float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_vecdouble_get, _swig_p) + return +} + +func (arg1 SwigcptrVecdouble) Get(arg2 int) (_swig_ret *float64) { + return _swig_wrap_vecdouble_get(arg1, arg2) +} + +var _wrap_vecdouble_set unsafe.Pointer + +func _swig_wrap_vecdouble_set(base SwigcptrVecdouble, _ int, _ *float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_vecdouble_set, _swig_p) + return +} + +func (arg1 SwigcptrVecdouble) Set(arg2 int, arg3 *float64) { + _swig_wrap_vecdouble_set(arg1, arg2, arg3) +} + +var _wrap_vecdouble_testconst unsafe.Pointer + +func _swig_wrap_vecdouble_testconst(base SwigcptrVecdouble, _ float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_vecdouble_testconst, _swig_p) + return +} + +func (arg1 SwigcptrVecdouble) Testconst(arg2 float64) { + _swig_wrap_vecdouble_testconst(arg1, arg2) +} + +var _wrap_delete_vecdouble unsafe.Pointer + +func _swig_wrap_delete_vecdouble(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_vecdouble, _swig_p) + return +} + +func DeleteVecdouble(arg1 Vecdouble) { + _swig_wrap_delete_vecdouble(arg1.Swigcptr()) +} + +type Vecdouble interface { + Swigcptr() uintptr + SwigIsVecdouble() + Get(arg2 int) (_swig_ret *float64) + Set(arg2 int, arg3 *float64) + Testconst(arg2 float64) +} + +var _wrap_maxintp unsafe.Pointer + +func Maxintp(arg1 **int, arg2 **int) (_swig_ret **int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_maxintp, _swig_p) + return +} +type SwigcptrVecintp uintptr + +func (p SwigcptrVecintp) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrVecintp) SwigIsVecintp() { +} + +var _wrap_new_vecintp unsafe.Pointer + +func _swig_wrap_new_vecintp(base int) (_ SwigcptrVecintp) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_vecintp, _swig_p) + return +} + +func NewVecintp(arg1 int) (_swig_ret Vecintp) { + return _swig_wrap_new_vecintp(arg1) +} + +var _wrap_vecintp_get unsafe.Pointer + +func _swig_wrap_vecintp_get(base SwigcptrVecintp, _ int) (_ ***int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_vecintp_get, _swig_p) + return +} + +func (arg1 SwigcptrVecintp) Get(arg2 int) (_swig_ret ***int) { + return _swig_wrap_vecintp_get(arg1, arg2) +} + +var _wrap_vecintp_set unsafe.Pointer + +func _swig_wrap_vecintp_set(base SwigcptrVecintp, _ int, _ ***int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_vecintp_set, _swig_p) + return +} + +func (arg1 SwigcptrVecintp) Set(arg2 int, arg3 ***int) { + _swig_wrap_vecintp_set(arg1, arg2, arg3) +} + +var _wrap_vecintp_testconst unsafe.Pointer + +func _swig_wrap_vecintp_testconst(base SwigcptrVecintp, _ **int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_vecintp_testconst, _swig_p) + return +} + +func (arg1 SwigcptrVecintp) Testconst(arg2 **int) { + _swig_wrap_vecintp_testconst(arg1, arg2) +} + +var _wrap_delete_vecintp unsafe.Pointer + +func _swig_wrap_delete_vecintp(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_vecintp, _swig_p) + return +} + +func DeleteVecintp(arg1 Vecintp) { + _swig_wrap_delete_vecintp(arg1.Swigcptr()) +} + +type Vecintp interface { + Swigcptr() uintptr + SwigIsVecintp() + Get(arg2 int) (_swig_ret ***int) + Set(arg2 int, arg3 ***int) + Testconst(arg2 **int) +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/template_extend1.go b/Examples/test-suite/go/template_extend1.go new file mode 100644 index 000000000..7990a6b76 --- /dev/null +++ b/Examples/test-suite/go/template_extend1.go @@ -0,0 +1,139 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../template_extend1.i + +package template_extend1 + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrLBaz uintptr + +func (p SwigcptrLBaz) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrLBaz) SwigIsLBaz() { +} + +var _wrap_lBaz_foo unsafe.Pointer + +func _swig_wrap_lBaz_foo(base SwigcptrLBaz) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_lBaz_foo, _swig_p) + return +} + +func (arg1 SwigcptrLBaz) Foo() (_swig_ret string) { + return _swig_wrap_lBaz_foo(arg1) +} + +var _wrap_new_lBaz unsafe.Pointer + +func _swig_wrap_new_lBaz() (base SwigcptrLBaz) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_lBaz, _swig_p) + return +} + +func NewLBaz() (_swig_ret LBaz) { + return _swig_wrap_new_lBaz() +} + +var _wrap_delete_lBaz unsafe.Pointer + +func _swig_wrap_delete_lBaz(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_lBaz, _swig_p) + return +} + +func DeleteLBaz(arg1 LBaz) { + _swig_wrap_delete_lBaz(arg1.Swigcptr()) +} + +type LBaz interface { + Swigcptr() uintptr + SwigIsLBaz() + Foo() (_swig_ret string) +} + +type SwigcptrDBaz uintptr + +func (p SwigcptrDBaz) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrDBaz) SwigIsDBaz() { +} + +var _wrap_dBaz_foo unsafe.Pointer + +func _swig_wrap_dBaz_foo(base SwigcptrDBaz) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_dBaz_foo, _swig_p) + return +} + +func (arg1 SwigcptrDBaz) Foo() (_swig_ret string) { + return _swig_wrap_dBaz_foo(arg1) +} + +var _wrap_new_dBaz unsafe.Pointer + +func _swig_wrap_new_dBaz() (base SwigcptrDBaz) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_dBaz, _swig_p) + return +} + +func NewDBaz() (_swig_ret DBaz) { + return _swig_wrap_new_dBaz() +} + +var _wrap_delete_dBaz unsafe.Pointer + +func _swig_wrap_delete_dBaz(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_dBaz, _swig_p) + return +} + +func DeleteDBaz(arg1 DBaz) { + _swig_wrap_delete_dBaz(arg1.Swigcptr()) +} + +type DBaz interface { + Swigcptr() uintptr + SwigIsDBaz() + Foo() (_swig_ret string) +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/template_extend1_runme b/Examples/test-suite/go/template_extend1_runme new file mode 100755 index 000000000..c14e341b9 Binary files /dev/null and b/Examples/test-suite/go/template_extend1_runme differ diff --git a/Examples/test-suite/go/template_extend2.go b/Examples/test-suite/go/template_extend2.go new file mode 100644 index 000000000..9e7f8fa4e --- /dev/null +++ b/Examples/test-suite/go/template_extend2.go @@ -0,0 +1,139 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../template_extend2.i + +package template_extend2 + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrLBaz uintptr + +func (p SwigcptrLBaz) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrLBaz) SwigIsLBaz() { +} + +var _wrap_lBaz_foo unsafe.Pointer + +func _swig_wrap_lBaz_foo(base SwigcptrLBaz) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_lBaz_foo, _swig_p) + return +} + +func (arg1 SwigcptrLBaz) Foo() (_swig_ret string) { + return _swig_wrap_lBaz_foo(arg1) +} + +var _wrap_new_lBaz unsafe.Pointer + +func _swig_wrap_new_lBaz() (base SwigcptrLBaz) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_lBaz, _swig_p) + return +} + +func NewLBaz() (_swig_ret LBaz) { + return _swig_wrap_new_lBaz() +} + +var _wrap_delete_lBaz unsafe.Pointer + +func _swig_wrap_delete_lBaz(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_lBaz, _swig_p) + return +} + +func DeleteLBaz(arg1 LBaz) { + _swig_wrap_delete_lBaz(arg1.Swigcptr()) +} + +type LBaz interface { + Swigcptr() uintptr + SwigIsLBaz() + Foo() (_swig_ret string) +} + +type SwigcptrDBaz uintptr + +func (p SwigcptrDBaz) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrDBaz) SwigIsDBaz() { +} + +var _wrap_dBaz_foo unsafe.Pointer + +func _swig_wrap_dBaz_foo(base SwigcptrDBaz) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_dBaz_foo, _swig_p) + return +} + +func (arg1 SwigcptrDBaz) Foo() (_swig_ret string) { + return _swig_wrap_dBaz_foo(arg1) +} + +var _wrap_new_dBaz unsafe.Pointer + +func _swig_wrap_new_dBaz() (base SwigcptrDBaz) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_dBaz, _swig_p) + return +} + +func NewDBaz() (_swig_ret DBaz) { + return _swig_wrap_new_dBaz() +} + +var _wrap_delete_dBaz unsafe.Pointer + +func _swig_wrap_delete_dBaz(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_dBaz, _swig_p) + return +} + +func DeleteDBaz(arg1 DBaz) { + _swig_wrap_delete_dBaz(arg1.Swigcptr()) +} + +type DBaz interface { + Swigcptr() uintptr + SwigIsDBaz() + Foo() (_swig_ret string) +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/template_extend2_runme b/Examples/test-suite/go/template_extend2_runme new file mode 100755 index 000000000..6808440b7 Binary files /dev/null and b/Examples/test-suite/go/template_extend2_runme differ diff --git a/Examples/test-suite/go/template_extend_overload.go b/Examples/test-suite/go/template_extend_overload.go new file mode 100644 index 000000000..bb4712470 --- /dev/null +++ b/Examples/test-suite/go/template_extend_overload.go @@ -0,0 +1,400 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../template_extend_overload.i + +package template_extend_overload + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrA_double uintptr + +func (p SwigcptrA_double) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrA_double) SwigIsA_double() { +} + +var _wrap_A_double_compose__SWIG_0 unsafe.Pointer + +func _swig_wrap_A_double_compose__SWIG_0(base SwigcptrA_double, _ uintptr) (_ SwigcptrA_bool) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_A_double_compose__SWIG_0, _swig_p) + return +} + +func (arg1 SwigcptrA_double) Compose__SWIG_0(arg2 B_Sl_double_Sc_bool_Sg_) (_swig_ret A_bool) { + return _swig_wrap_A_double_compose__SWIG_0(arg1, arg2.Swigcptr()) +} + +var _wrap_A_double_compose__SWIG_1 unsafe.Pointer + +func _swig_wrap_A_double_compose__SWIG_1(base SwigcptrA_double, _ uintptr) (_ SwigcptrA_double) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_A_double_compose__SWIG_1, _swig_p) + return +} + +func (arg1 SwigcptrA_double) Compose__SWIG_1(arg2 B_Sl_double_Sc_double_Sg_) (_swig_ret A_double) { + return _swig_wrap_A_double_compose__SWIG_1(arg1, arg2.Swigcptr()) +} + +var _wrap_A_double_compose__SWIG_2 unsafe.Pointer + +func _swig_wrap_A_double_compose__SWIG_2(base SwigcptrA_double, _ uintptr) (_ SwigcptrA_int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_A_double_compose__SWIG_2, _swig_p) + return +} + +func (arg1 SwigcptrA_double) Compose__SWIG_2(arg2 B_Sl_double_Sc_int_Sg_) (_swig_ret A_int) { + return _swig_wrap_A_double_compose__SWIG_2(arg1, arg2.Swigcptr()) +} + +func (p SwigcptrA_double) Compose(a ...interface{}) interface{} { + argc := len(a) + if argc == 1 { + if _, ok := a[0].(B_Sl_double_Sc_bool_Sg_); !ok { + goto check_1 + } + return p.Compose__SWIG_0(a[0].(B_Sl_double_Sc_bool_Sg_)) + } +check_1: + if argc == 1 { + if _, ok := a[0].(B_Sl_double_Sc_double_Sg_); !ok { + goto check_2 + } + return p.Compose__SWIG_1(a[0].(B_Sl_double_Sc_double_Sg_)) + } +check_2: + if argc == 1 { + return p.Compose__SWIG_2(a[0].(B_Sl_double_Sc_int_Sg_)) + } + panic("No match for overloaded function call") +} + +var _wrap_new_A_double unsafe.Pointer + +func _swig_wrap_new_A_double() (base SwigcptrA_double) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_A_double, _swig_p) + return +} + +func NewA_double() (_swig_ret A_double) { + return _swig_wrap_new_A_double() +} + +var _wrap_delete_A_double unsafe.Pointer + +func _swig_wrap_delete_A_double(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_A_double, _swig_p) + return +} + +func DeleteA_double(arg1 A_double) { + _swig_wrap_delete_A_double(arg1.Swigcptr()) +} + +type A_double interface { + Swigcptr() uintptr + SwigIsA_double() + Compose(a ...interface{}) interface{} +} + +type SwigcptrA_int uintptr + +func (p SwigcptrA_int) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrA_int) SwigIsA_int() { +} + +var _wrap_A_int_compose__SWIG_0 unsafe.Pointer + +func _swig_wrap_A_int_compose__SWIG_0(base SwigcptrA_int, _ uintptr) (_ SwigcptrA_bool) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_A_int_compose__SWIG_0, _swig_p) + return +} + +func (arg1 SwigcptrA_int) Compose__SWIG_0(arg2 B_Sl_int_Sc_bool_Sg_) (_swig_ret A_bool) { + return _swig_wrap_A_int_compose__SWIG_0(arg1, arg2.Swigcptr()) +} + +var _wrap_A_int_compose__SWIG_1 unsafe.Pointer + +func _swig_wrap_A_int_compose__SWIG_1(base SwigcptrA_int, _ uintptr) (_ SwigcptrA_double) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_A_int_compose__SWIG_1, _swig_p) + return +} + +func (arg1 SwigcptrA_int) Compose__SWIG_1(arg2 B_Sl_int_Sc_double_Sg_) (_swig_ret A_double) { + return _swig_wrap_A_int_compose__SWIG_1(arg1, arg2.Swigcptr()) +} + +var _wrap_A_int_compose__SWIG_2 unsafe.Pointer + +func _swig_wrap_A_int_compose__SWIG_2(base SwigcptrA_int, _ uintptr) (_ SwigcptrA_int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_A_int_compose__SWIG_2, _swig_p) + return +} + +func (arg1 SwigcptrA_int) Compose__SWIG_2(arg2 B_Sl_int_Sc_int_Sg_) (_swig_ret A_int) { + return _swig_wrap_A_int_compose__SWIG_2(arg1, arg2.Swigcptr()) +} + +func (p SwigcptrA_int) Compose(a ...interface{}) interface{} { + argc := len(a) + if argc == 1 { + if _, ok := a[0].(B_Sl_int_Sc_bool_Sg_); !ok { + goto check_1 + } + return p.Compose__SWIG_0(a[0].(B_Sl_int_Sc_bool_Sg_)) + } +check_1: + if argc == 1 { + if _, ok := a[0].(B_Sl_int_Sc_double_Sg_); !ok { + goto check_2 + } + return p.Compose__SWIG_1(a[0].(B_Sl_int_Sc_double_Sg_)) + } +check_2: + if argc == 1 { + return p.Compose__SWIG_2(a[0].(B_Sl_int_Sc_int_Sg_)) + } + panic("No match for overloaded function call") +} + +var _wrap_new_A_int unsafe.Pointer + +func _swig_wrap_new_A_int() (base SwigcptrA_int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_A_int, _swig_p) + return +} + +func NewA_int() (_swig_ret A_int) { + return _swig_wrap_new_A_int() +} + +var _wrap_delete_A_int unsafe.Pointer + +func _swig_wrap_delete_A_int(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_A_int, _swig_p) + return +} + +func DeleteA_int(arg1 A_int) { + _swig_wrap_delete_A_int(arg1.Swigcptr()) +} + +type A_int interface { + Swigcptr() uintptr + SwigIsA_int() + Compose(a ...interface{}) interface{} +} + +type SwigcptrA_bool uintptr + +func (p SwigcptrA_bool) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrA_bool) SwigIsA_bool() { +} + +var _wrap_A_bool_compose__SWIG_0 unsafe.Pointer + +func _swig_wrap_A_bool_compose__SWIG_0(base SwigcptrA_bool, _ uintptr) (_ SwigcptrA_bool) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_A_bool_compose__SWIG_0, _swig_p) + return +} + +func (arg1 SwigcptrA_bool) Compose__SWIG_0(arg2 B_Sl_bool_Sc_bool_Sg_) (_swig_ret A_bool) { + return _swig_wrap_A_bool_compose__SWIG_0(arg1, arg2.Swigcptr()) +} + +var _wrap_A_bool_compose__SWIG_1 unsafe.Pointer + +func _swig_wrap_A_bool_compose__SWIG_1(base SwigcptrA_bool, _ uintptr) (_ SwigcptrA_double) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_A_bool_compose__SWIG_1, _swig_p) + return +} + +func (arg1 SwigcptrA_bool) Compose__SWIG_1(arg2 B_Sl_bool_Sc_double_Sg_) (_swig_ret A_double) { + return _swig_wrap_A_bool_compose__SWIG_1(arg1, arg2.Swigcptr()) +} + +var _wrap_A_bool_compose__SWIG_2 unsafe.Pointer + +func _swig_wrap_A_bool_compose__SWIG_2(base SwigcptrA_bool, _ uintptr) (_ SwigcptrA_int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_A_bool_compose__SWIG_2, _swig_p) + return +} + +func (arg1 SwigcptrA_bool) Compose__SWIG_2(arg2 B_Sl_bool_Sc_int_Sg_) (_swig_ret A_int) { + return _swig_wrap_A_bool_compose__SWIG_2(arg1, arg2.Swigcptr()) +} + +func (p SwigcptrA_bool) Compose(a ...interface{}) interface{} { + argc := len(a) + if argc == 1 { + if _, ok := a[0].(B_Sl_bool_Sc_bool_Sg_); !ok { + goto check_1 + } + return p.Compose__SWIG_0(a[0].(B_Sl_bool_Sc_bool_Sg_)) + } +check_1: + if argc == 1 { + if _, ok := a[0].(B_Sl_bool_Sc_double_Sg_); !ok { + goto check_2 + } + return p.Compose__SWIG_1(a[0].(B_Sl_bool_Sc_double_Sg_)) + } +check_2: + if argc == 1 { + return p.Compose__SWIG_2(a[0].(B_Sl_bool_Sc_int_Sg_)) + } + panic("No match for overloaded function call") +} + +var _wrap_new_A_bool unsafe.Pointer + +func _swig_wrap_new_A_bool() (base SwigcptrA_bool) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_A_bool, _swig_p) + return +} + +func NewA_bool() (_swig_ret A_bool) { + return _swig_wrap_new_A_bool() +} + +var _wrap_delete_A_bool unsafe.Pointer + +func _swig_wrap_delete_A_bool(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_A_bool, _swig_p) + return +} + +func DeleteA_bool(arg1 A_bool) { + _swig_wrap_delete_A_bool(arg1.Swigcptr()) +} + +type A_bool interface { + Swigcptr() uintptr + SwigIsA_bool() + Compose(a ...interface{}) interface{} +} + + +type SwigcptrB_Sl_double_Sc_bool_Sg_ uintptr +type B_Sl_double_Sc_bool_Sg_ interface { + Swigcptr() uintptr; +} +func (p SwigcptrB_Sl_double_Sc_bool_Sg_) Swigcptr() uintptr { + return uintptr(p) +} + +type SwigcptrB_Sl_int_Sc_bool_Sg_ uintptr +type B_Sl_int_Sc_bool_Sg_ interface { + Swigcptr() uintptr; +} +func (p SwigcptrB_Sl_int_Sc_bool_Sg_) Swigcptr() uintptr { + return uintptr(p) +} + +type SwigcptrB_Sl_bool_Sc_bool_Sg_ uintptr +type B_Sl_bool_Sc_bool_Sg_ interface { + Swigcptr() uintptr; +} +func (p SwigcptrB_Sl_bool_Sc_bool_Sg_) Swigcptr() uintptr { + return uintptr(p) +} + +type SwigcptrB_Sl_double_Sc_double_Sg_ uintptr +type B_Sl_double_Sc_double_Sg_ interface { + Swigcptr() uintptr; +} +func (p SwigcptrB_Sl_double_Sc_double_Sg_) Swigcptr() uintptr { + return uintptr(p) +} + +type SwigcptrB_Sl_double_Sc_int_Sg_ uintptr +type B_Sl_double_Sc_int_Sg_ interface { + Swigcptr() uintptr; +} +func (p SwigcptrB_Sl_double_Sc_int_Sg_) Swigcptr() uintptr { + return uintptr(p) +} + +type SwigcptrB_Sl_int_Sc_double_Sg_ uintptr +type B_Sl_int_Sc_double_Sg_ interface { + Swigcptr() uintptr; +} +func (p SwigcptrB_Sl_int_Sc_double_Sg_) Swigcptr() uintptr { + return uintptr(p) +} + +type SwigcptrB_Sl_bool_Sc_double_Sg_ uintptr +type B_Sl_bool_Sc_double_Sg_ interface { + Swigcptr() uintptr; +} +func (p SwigcptrB_Sl_bool_Sc_double_Sg_) Swigcptr() uintptr { + return uintptr(p) +} + +type SwigcptrB_Sl_int_Sc_int_Sg_ uintptr +type B_Sl_int_Sc_int_Sg_ interface { + Swigcptr() uintptr; +} +func (p SwigcptrB_Sl_int_Sc_int_Sg_) Swigcptr() uintptr { + return uintptr(p) +} + +type SwigcptrB_Sl_bool_Sc_int_Sg_ uintptr +type B_Sl_bool_Sc_int_Sg_ interface { + Swigcptr() uintptr; +} +func (p SwigcptrB_Sl_bool_Sc_int_Sg_) Swigcptr() uintptr { + return uintptr(p) +} + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/template_extend_overload_2.go b/Examples/test-suite/go/template_extend_overload_2.go new file mode 100644 index 000000000..5eef74577 --- /dev/null +++ b/Examples/test-suite/go/template_extend_overload_2.go @@ -0,0 +1,385 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../template_extend_overload_2.i + +package template_extend_overload_2 + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrA uintptr + +func (p SwigcptrA) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrA) SwigIsA() { +} + +var _wrap_new_A__SWIG_0 unsafe.Pointer + +func _swig_wrap_new_A__SWIG_0() (base SwigcptrA) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_A__SWIG_0, _swig_p) + return +} + +func NewA__SWIG_0() (_swig_ret A) { + return _swig_wrap_new_A__SWIG_0() +} + +var _wrap_new_A__SWIG_1 unsafe.Pointer + +func _swig_wrap_new_A__SWIG_1(base int) (_ SwigcptrA) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_A__SWIG_1, _swig_p) + return +} + +func NewA__SWIG_1(arg1 int) (_swig_ret A) { + return _swig_wrap_new_A__SWIG_1(arg1) +} + +var _wrap_A_hi__SWIG_0 unsafe.Pointer + +func _swig_wrap_A_hi__SWIG_0(base SwigcptrA) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_A_hi__SWIG_0, _swig_p) + return +} + +func (arg1 SwigcptrA) Hi__SWIG_0() (_swig_ret int) { + return _swig_wrap_A_hi__SWIG_0(arg1) +} + +var _wrap_A_hi__SWIG_1 unsafe.Pointer + +func _swig_wrap_A_hi__SWIG_1(base SwigcptrA, _ int) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_A_hi__SWIG_1, _swig_p) + return +} + +func (arg1 SwigcptrA) Hi__SWIG_1(arg2 int) (_swig_ret int) { + return _swig_wrap_A_hi__SWIG_1(arg1, arg2) +} + +func (p SwigcptrA) Hi(a ...interface{}) int { + argc := len(a) + if argc == 0 { + return p.Hi__SWIG_0() + } + if argc == 1 { + return p.Hi__SWIG_1(a[0].(int)) + } + panic("No match for overloaded function call") +} + +var _wrap_new_A__SWIG_2 unsafe.Pointer + +func _swig_wrap_new_A__SWIG_2(base float64) (_ SwigcptrA) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_A__SWIG_2, _swig_p) + return +} + +func NewA__SWIG_2(arg1 float64) (_swig_ret A) { + return _swig_wrap_new_A__SWIG_2(arg1) +} + +func NewA(a ...interface{}) A { + argc := len(a) + if argc == 0 { + return NewA__SWIG_0() + } + if argc == 1 { + if _, ok := a[0].(int); !ok { + goto check_2 + } + return NewA__SWIG_1(a[0].(int)) + } +check_2: + if argc == 1 { + return NewA__SWIG_2(a[0].(float64)) + } + panic("No match for overloaded function call") +} + +var _wrap_delete_A unsafe.Pointer + +func _swig_wrap_delete_A(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_A, _swig_p) + return +} + +func DeleteA(arg1 A) { + _swig_wrap_delete_A(arg1.Swigcptr()) +} + +type A interface { + Swigcptr() uintptr + SwigIsA() + Hi(a ...interface{}) int +} + +type SwigcptrAT_double uintptr + +func (p SwigcptrAT_double) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrAT_double) SwigIsAT_double() { +} + +var _wrap_new_AT_double__SWIG_0 unsafe.Pointer + +func _swig_wrap_new_AT_double__SWIG_0() (base SwigcptrAT_double) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_AT_double__SWIG_0, _swig_p) + return +} + +func NewAT_double__SWIG_0() (_swig_ret AT_double) { + return _swig_wrap_new_AT_double__SWIG_0() +} + +var _wrap_new_AT_double__SWIG_1 unsafe.Pointer + +func _swig_wrap_new_AT_double__SWIG_1(base int) (_ SwigcptrAT_double) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_AT_double__SWIG_1, _swig_p) + return +} + +func NewAT_double__SWIG_1(arg1 int) (_swig_ret AT_double) { + return _swig_wrap_new_AT_double__SWIG_1(arg1) +} + +var _wrap_AT_double_hi__SWIG_0 unsafe.Pointer + +func _swig_wrap_AT_double_hi__SWIG_0(base SwigcptrAT_double) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_AT_double_hi__SWIG_0, _swig_p) + return +} + +func (arg1 SwigcptrAT_double) Hi__SWIG_0() (_swig_ret int) { + return _swig_wrap_AT_double_hi__SWIG_0(arg1) +} + +var _wrap_AT_double_hi__SWIG_1 unsafe.Pointer + +func _swig_wrap_AT_double_hi__SWIG_1(base SwigcptrAT_double, _ int) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_AT_double_hi__SWIG_1, _swig_p) + return +} + +func (arg1 SwigcptrAT_double) Hi__SWIG_1(arg2 int) (_swig_ret int) { + return _swig_wrap_AT_double_hi__SWIG_1(arg1, arg2) +} + +func (p SwigcptrAT_double) Hi(a ...interface{}) int { + argc := len(a) + if argc == 0 { + return p.Hi__SWIG_0() + } + if argc == 1 { + return p.Hi__SWIG_1(a[0].(int)) + } + panic("No match for overloaded function call") +} + +var _wrap_new_AT_double__SWIG_2 unsafe.Pointer + +func _swig_wrap_new_AT_double__SWIG_2(base float64) (_ SwigcptrAT_double) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_AT_double__SWIG_2, _swig_p) + return +} + +func NewAT_double__SWIG_2(arg1 float64) (_swig_ret AT_double) { + return _swig_wrap_new_AT_double__SWIG_2(arg1) +} + +func NewAT_double(a ...interface{}) AT_double { + argc := len(a) + if argc == 0 { + return NewAT_double__SWIG_0() + } + if argc == 1 { + if _, ok := a[0].(int); !ok { + goto check_2 + } + return NewAT_double__SWIG_1(a[0].(int)) + } +check_2: + if argc == 1 { + return NewAT_double__SWIG_2(a[0].(float64)) + } + panic("No match for overloaded function call") +} + +var _wrap_delete_AT_double unsafe.Pointer + +func _swig_wrap_delete_AT_double(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_AT_double, _swig_p) + return +} + +func DeleteAT_double(arg1 AT_double) { + _swig_wrap_delete_AT_double(arg1.Swigcptr()) +} + +type AT_double interface { + Swigcptr() uintptr + SwigIsAT_double() + Hi(a ...interface{}) int +} + +type SwigcptrBT_double uintptr + +func (p SwigcptrBT_double) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrBT_double) SwigIsBT_double() { +} + +var _wrap_new_BT_double__SWIG_0 unsafe.Pointer + +func _swig_wrap_new_BT_double__SWIG_0() (base SwigcptrBT_double) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_BT_double__SWIG_0, _swig_p) + return +} + +func NewBT_double__SWIG_0() (_swig_ret BT_double) { + return _swig_wrap_new_BT_double__SWIG_0() +} + +var _wrap_new_BT_double__SWIG_1 unsafe.Pointer + +func _swig_wrap_new_BT_double__SWIG_1(base int) (_ SwigcptrBT_double) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_BT_double__SWIG_1, _swig_p) + return +} + +func NewBT_double__SWIG_1(arg1 int) (_swig_ret BT_double) { + return _swig_wrap_new_BT_double__SWIG_1(arg1) +} + +var _wrap_BT_double_hi__SWIG_0 unsafe.Pointer + +func _swig_wrap_BT_double_hi__SWIG_0(base SwigcptrBT_double) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_BT_double_hi__SWIG_0, _swig_p) + return +} + +func (arg1 SwigcptrBT_double) Hi__SWIG_0() (_swig_ret int) { + return _swig_wrap_BT_double_hi__SWIG_0(arg1) +} + +var _wrap_BT_double_hi__SWIG_1 unsafe.Pointer + +func _swig_wrap_BT_double_hi__SWIG_1(base SwigcptrBT_double, _ int) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_BT_double_hi__SWIG_1, _swig_p) + return +} + +func (arg1 SwigcptrBT_double) Hi__SWIG_1(arg2 int) (_swig_ret int) { + return _swig_wrap_BT_double_hi__SWIG_1(arg1, arg2) +} + +func (p SwigcptrBT_double) Hi(a ...interface{}) int { + argc := len(a) + if argc == 0 { + return p.Hi__SWIG_0() + } + if argc == 1 { + return p.Hi__SWIG_1(a[0].(int)) + } + panic("No match for overloaded function call") +} + +var _wrap_new_BT_double__SWIG_2 unsafe.Pointer + +func _swig_wrap_new_BT_double__SWIG_2(base float64) (_ SwigcptrBT_double) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_BT_double__SWIG_2, _swig_p) + return +} + +func NewBT_double__SWIG_2(arg1 float64) (_swig_ret BT_double) { + return _swig_wrap_new_BT_double__SWIG_2(arg1) +} + +func NewBT_double(a ...interface{}) BT_double { + argc := len(a) + if argc == 0 { + return NewBT_double__SWIG_0() + } + if argc == 1 { + if _, ok := a[0].(int); !ok { + goto check_2 + } + return NewBT_double__SWIG_1(a[0].(int)) + } +check_2: + if argc == 1 { + return NewBT_double__SWIG_2(a[0].(float64)) + } + panic("No match for overloaded function call") +} + +var _wrap_delete_BT_double unsafe.Pointer + +func _swig_wrap_delete_BT_double(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_BT_double, _swig_p) + return +} + +func DeleteBT_double(arg1 BT_double) { + _swig_wrap_delete_BT_double(arg1.Swigcptr()) +} + +type BT_double interface { + Swigcptr() uintptr + SwigIsBT_double() + Hi(a ...interface{}) int +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/template_forward.go b/Examples/test-suite/go/template_forward.go new file mode 100644 index 000000000..e9af0f5c0 --- /dev/null +++ b/Examples/test-suite/go/template_forward.go @@ -0,0 +1,378 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../template_forward.i + +package template_forward + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +var _wrap_test1 unsafe.Pointer + +func _swig_wrap_test1(base uintptr) (_ float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_test1, _swig_p) + return +} + +func Test1(arg1 Foo_bar_Sl_double_Sg_) (_swig_ret float64) { + return _swig_wrap_test1(arg1.Swigcptr()) +} + +var _wrap_test2 unsafe.Pointer + +func _swig_wrap_test2() (base SwigcptrFoo_bar_Sl_double_Sg_) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_test2, _swig_p) + return +} + +func Test2() (_swig_ret Foo_bar_Sl_double_Sg_) { + return _swig_wrap_test2() +} + +type SwigcptrDescribable uintptr + +func (p SwigcptrDescribable) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrDescribable) SwigIsDescribable() { +} + +var _wrap_Describable_describe unsafe.Pointer + +func _swig_wrap_Describable_describe(base SwigcptrDescribable) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Describable_describe, _swig_p) + return +} + +func (arg1 SwigcptrDescribable) Describe() { + _swig_wrap_Describable_describe(arg1) +} + +var _wrap_new_Describable unsafe.Pointer + +func _swig_wrap_new_Describable() (base SwigcptrDescribable) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Describable, _swig_p) + return +} + +func NewDescribable() (_swig_ret Describable) { + return _swig_wrap_new_Describable() +} + +var _wrap_delete_Describable unsafe.Pointer + +func _swig_wrap_delete_Describable(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Describable, _swig_p) + return +} + +func DeleteDescribable(arg1 Describable) { + _swig_wrap_delete_Describable(arg1.Swigcptr()) +} + +type Describable interface { + Swigcptr() uintptr + SwigIsDescribable() + Describe() +} + +type SwigcptrLinearOpBase_double uintptr + +func (p SwigcptrLinearOpBase_double) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrLinearOpBase_double) SwigIsLinearOpBase_double() { +} + +var _wrap_new_LinearOpBase_double unsafe.Pointer + +func _swig_wrap_new_LinearOpBase_double() (base SwigcptrLinearOpBase_double) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_LinearOpBase_double, _swig_p) + return +} + +func NewLinearOpBase_double() (_swig_ret LinearOpBase_double) { + return _swig_wrap_new_LinearOpBase_double() +} + +var _wrap_delete_LinearOpBase_double unsafe.Pointer + +func _swig_wrap_delete_LinearOpBase_double(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_LinearOpBase_double, _swig_p) + return +} + +func DeleteLinearOpBase_double(arg1 LinearOpBase_double) { + _swig_wrap_delete_LinearOpBase_double(arg1.Swigcptr()) +} + +var _wrap_LinearOpBase_double_describe unsafe.Pointer + +func _swig_wrap_LinearOpBase_double_describe(base SwigcptrLinearOpBase_double) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_LinearOpBase_double_describe, _swig_p) + return +} + +func (_swig_base SwigcptrLinearOpBase_double) Describe() { + _swig_wrap_LinearOpBase_double_describe(_swig_base) +} + +func (p SwigcptrLinearOpBase_double) SwigIsDescribable() { +} + +func (p SwigcptrLinearOpBase_double) SwigGetDescribable() Describable { + return SwigcptrDescribable(p.Swigcptr()) +} + +type LinearOpBase_double interface { + Swigcptr() uintptr + SwigIsLinearOpBase_double() + Describe() + SwigIsDescribable() + SwigGetDescribable() Describable +} + +type SwigcptrVectorBase_double uintptr + +func (p SwigcptrVectorBase_double) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrVectorBase_double) SwigIsVectorBase_double() { +} + +var _wrap_VectorBase_double_describe unsafe.Pointer + +func _swig_wrap_VectorBase_double_describe(base SwigcptrVectorBase_double) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_VectorBase_double_describe, _swig_p) + return +} + +func (arg1 SwigcptrVectorBase_double) Describe() { + _swig_wrap_VectorBase_double_describe(arg1) +} + +var _wrap_new_VectorBase_double unsafe.Pointer + +func _swig_wrap_new_VectorBase_double() (base SwigcptrVectorBase_double) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_VectorBase_double, _swig_p) + return +} + +func NewVectorBase_double() (_swig_ret VectorBase_double) { + return _swig_wrap_new_VectorBase_double() +} + +var _wrap_delete_VectorBase_double unsafe.Pointer + +func _swig_wrap_delete_VectorBase_double(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_VectorBase_double, _swig_p) + return +} + +func DeleteVectorBase_double(arg1 VectorBase_double) { + _swig_wrap_delete_VectorBase_double(arg1.Swigcptr()) +} + +func (p SwigcptrVectorBase_double) SwigIsLinearOpBase_double() { +} + +func (p SwigcptrVectorBase_double) SwigGetLinearOpBase_double() LinearOpBase_double { + return SwigcptrLinearOpBase_double(p.Swigcptr()) +} + +func (p SwigcptrVectorBase_double) SwigIsDescribable() { +} + +func (p SwigcptrVectorBase_double) SwigGetDescribable() Describable { + return SwigcptrDescribable(p.Swigcptr()) +} + +type VectorBase_double interface { + Swigcptr() uintptr + SwigIsVectorBase_double() + Describe() + SwigIsLinearOpBase_double() + SwigGetLinearOpBase_double() LinearOpBase_double + SwigIsDescribable() + SwigGetDescribable() Describable +} + +type SwigcptrLinearOpBase_int uintptr + +func (p SwigcptrLinearOpBase_int) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrLinearOpBase_int) SwigIsLinearOpBase_int() { +} + +var _wrap_new_LinearOpBase_int unsafe.Pointer + +func _swig_wrap_new_LinearOpBase_int() (base SwigcptrLinearOpBase_int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_LinearOpBase_int, _swig_p) + return +} + +func NewLinearOpBase_int() (_swig_ret LinearOpBase_int) { + return _swig_wrap_new_LinearOpBase_int() +} + +var _wrap_delete_LinearOpBase_int unsafe.Pointer + +func _swig_wrap_delete_LinearOpBase_int(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_LinearOpBase_int, _swig_p) + return +} + +func DeleteLinearOpBase_int(arg1 LinearOpBase_int) { + _swig_wrap_delete_LinearOpBase_int(arg1.Swigcptr()) +} + +var _wrap_LinearOpBase_int_describe unsafe.Pointer + +func _swig_wrap_LinearOpBase_int_describe(base SwigcptrLinearOpBase_int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_LinearOpBase_int_describe, _swig_p) + return +} + +func (_swig_base SwigcptrLinearOpBase_int) Describe() { + _swig_wrap_LinearOpBase_int_describe(_swig_base) +} + +func (p SwigcptrLinearOpBase_int) SwigIsDescribable() { +} + +func (p SwigcptrLinearOpBase_int) SwigGetDescribable() Describable { + return SwigcptrDescribable(p.Swigcptr()) +} + +type LinearOpBase_int interface { + Swigcptr() uintptr + SwigIsLinearOpBase_int() + Describe() + SwigIsDescribable() + SwigGetDescribable() Describable +} + +type SwigcptrVectorBase_int uintptr + +func (p SwigcptrVectorBase_int) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrVectorBase_int) SwigIsVectorBase_int() { +} + +var _wrap_VectorBase_int_describe unsafe.Pointer + +func _swig_wrap_VectorBase_int_describe(base SwigcptrVectorBase_int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_VectorBase_int_describe, _swig_p) + return +} + +func (arg1 SwigcptrVectorBase_int) Describe() { + _swig_wrap_VectorBase_int_describe(arg1) +} + +var _wrap_new_VectorBase_int unsafe.Pointer + +func _swig_wrap_new_VectorBase_int() (base SwigcptrVectorBase_int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_VectorBase_int, _swig_p) + return +} + +func NewVectorBase_int() (_swig_ret VectorBase_int) { + return _swig_wrap_new_VectorBase_int() +} + +var _wrap_delete_VectorBase_int unsafe.Pointer + +func _swig_wrap_delete_VectorBase_int(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_VectorBase_int, _swig_p) + return +} + +func DeleteVectorBase_int(arg1 VectorBase_int) { + _swig_wrap_delete_VectorBase_int(arg1.Swigcptr()) +} + +func (p SwigcptrVectorBase_int) SwigIsLinearOpBase_int() { +} + +func (p SwigcptrVectorBase_int) SwigGetLinearOpBase_int() LinearOpBase_int { + return SwigcptrLinearOpBase_int(p.Swigcptr()) +} + +func (p SwigcptrVectorBase_int) SwigIsDescribable() { +} + +func (p SwigcptrVectorBase_int) SwigGetDescribable() Describable { + return SwigcptrDescribable(p.Swigcptr()) +} + +type VectorBase_int interface { + Swigcptr() uintptr + SwigIsVectorBase_int() + Describe() + SwigIsLinearOpBase_int() + SwigGetLinearOpBase_int() LinearOpBase_int + SwigIsDescribable() + SwigGetDescribable() Describable +} + + +type SwigcptrFoo_bar_Sl_double_Sg_ uintptr +type Foo_bar_Sl_double_Sg_ interface { + Swigcptr() uintptr; +} +func (p SwigcptrFoo_bar_Sl_double_Sg_) Swigcptr() uintptr { + return uintptr(p) +} + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/template_inherit.go b/Examples/test-suite/go/template_inherit.go new file mode 100644 index 000000000..e60aa816d --- /dev/null +++ b/Examples/test-suite/go/template_inherit.go @@ -0,0 +1,484 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../template_inherit.i + +package template_inherit + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrFooInt uintptr + +func (p SwigcptrFooInt) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrFooInt) SwigIsFooInt() { +} + +var _wrap_delete_FooInt unsafe.Pointer + +func _swig_wrap_delete_FooInt(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_FooInt, _swig_p) + return +} + +func DeleteFooInt(arg1 FooInt) { + _swig_wrap_delete_FooInt(arg1.Swigcptr()) +} + +var _wrap_FooInt_blah unsafe.Pointer + +func _swig_wrap_FooInt_blah(base SwigcptrFooInt) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_FooInt_blah, _swig_p) + return +} + +func (arg1 SwigcptrFooInt) Blah() (_swig_ret string) { + return _swig_wrap_FooInt_blah(arg1) +} + +var _wrap_FooInt_foomethod unsafe.Pointer + +func _swig_wrap_FooInt_foomethod(base SwigcptrFooInt) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_FooInt_foomethod, _swig_p) + return +} + +func (arg1 SwigcptrFooInt) Foomethod() (_swig_ret string) { + return _swig_wrap_FooInt_foomethod(arg1) +} + +var _wrap_new_FooInt unsafe.Pointer + +func _swig_wrap_new_FooInt() (base SwigcptrFooInt) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_FooInt, _swig_p) + return +} + +func NewFooInt() (_swig_ret FooInt) { + return _swig_wrap_new_FooInt() +} + +type FooInt interface { + Swigcptr() uintptr + SwigIsFooInt() + Blah() (_swig_ret string) + Foomethod() (_swig_ret string) +} + +type SwigcptrFooDouble uintptr + +func (p SwigcptrFooDouble) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrFooDouble) SwigIsFooDouble() { +} + +var _wrap_delete_FooDouble unsafe.Pointer + +func _swig_wrap_delete_FooDouble(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_FooDouble, _swig_p) + return +} + +func DeleteFooDouble(arg1 FooDouble) { + _swig_wrap_delete_FooDouble(arg1.Swigcptr()) +} + +var _wrap_FooDouble_blah unsafe.Pointer + +func _swig_wrap_FooDouble_blah(base SwigcptrFooDouble) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_FooDouble_blah, _swig_p) + return +} + +func (arg1 SwigcptrFooDouble) Blah() (_swig_ret string) { + return _swig_wrap_FooDouble_blah(arg1) +} + +var _wrap_FooDouble_foomethod unsafe.Pointer + +func _swig_wrap_FooDouble_foomethod(base SwigcptrFooDouble) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_FooDouble_foomethod, _swig_p) + return +} + +func (arg1 SwigcptrFooDouble) Foomethod() (_swig_ret string) { + return _swig_wrap_FooDouble_foomethod(arg1) +} + +var _wrap_new_FooDouble unsafe.Pointer + +func _swig_wrap_new_FooDouble() (base SwigcptrFooDouble) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_FooDouble, _swig_p) + return +} + +func NewFooDouble() (_swig_ret FooDouble) { + return _swig_wrap_new_FooDouble() +} + +type FooDouble interface { + Swigcptr() uintptr + SwigIsFooDouble() + Blah() (_swig_ret string) + Foomethod() (_swig_ret string) +} + +type SwigcptrFooUInt uintptr + +func (p SwigcptrFooUInt) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrFooUInt) SwigIsFooUInt() { +} + +var _wrap_delete_FooUInt unsafe.Pointer + +func _swig_wrap_delete_FooUInt(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_FooUInt, _swig_p) + return +} + +func DeleteFooUInt(arg1 FooUInt) { + _swig_wrap_delete_FooUInt(arg1.Swigcptr()) +} + +var _wrap_FooUInt_blah unsafe.Pointer + +func _swig_wrap_FooUInt_blah(base SwigcptrFooUInt) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_FooUInt_blah, _swig_p) + return +} + +func (arg1 SwigcptrFooUInt) Blah() (_swig_ret string) { + return _swig_wrap_FooUInt_blah(arg1) +} + +var _wrap_FooUInt_foomethod unsafe.Pointer + +func _swig_wrap_FooUInt_foomethod(base SwigcptrFooUInt) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_FooUInt_foomethod, _swig_p) + return +} + +func (arg1 SwigcptrFooUInt) Foomethod() (_swig_ret string) { + return _swig_wrap_FooUInt_foomethod(arg1) +} + +var _wrap_new_FooUInt unsafe.Pointer + +func _swig_wrap_new_FooUInt() (base SwigcptrFooUInt) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_FooUInt, _swig_p) + return +} + +func NewFooUInt() (_swig_ret FooUInt) { + return _swig_wrap_new_FooUInt() +} + +type FooUInt interface { + Swigcptr() uintptr + SwigIsFooUInt() + Blah() (_swig_ret string) + Foomethod() (_swig_ret string) +} + +type SwigcptrBarInt uintptr + +func (p SwigcptrBarInt) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrBarInt) SwigIsBarInt() { +} + +var _wrap_BarInt_blah unsafe.Pointer + +func _swig_wrap_BarInt_blah(base SwigcptrBarInt) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_BarInt_blah, _swig_p) + return +} + +func (arg1 SwigcptrBarInt) Blah() (_swig_ret string) { + return _swig_wrap_BarInt_blah(arg1) +} + +var _wrap_new_BarInt unsafe.Pointer + +func _swig_wrap_new_BarInt() (base SwigcptrBarInt) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_BarInt, _swig_p) + return +} + +func NewBarInt() (_swig_ret BarInt) { + return _swig_wrap_new_BarInt() +} + +var _wrap_delete_BarInt unsafe.Pointer + +func _swig_wrap_delete_BarInt(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_BarInt, _swig_p) + return +} + +func DeleteBarInt(arg1 BarInt) { + _swig_wrap_delete_BarInt(arg1.Swigcptr()) +} + +var _wrap_BarInt_foomethod unsafe.Pointer + +func _swig_wrap_BarInt_foomethod(base SwigcptrBarInt) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_BarInt_foomethod, _swig_p) + return +} + +func (_swig_base SwigcptrBarInt) Foomethod() (_swig_ret string) { + return _swig_wrap_BarInt_foomethod(_swig_base) +} + +func (p SwigcptrBarInt) SwigIsFooInt() { +} + +func (p SwigcptrBarInt) SwigGetFooInt() FooInt { + return SwigcptrFooInt(p.Swigcptr()) +} + +type BarInt interface { + Swigcptr() uintptr + SwigIsBarInt() + Blah() (_swig_ret string) + Foomethod() (_swig_ret string) + SwigIsFooInt() + SwigGetFooInt() FooInt +} + +type SwigcptrBarDouble uintptr + +func (p SwigcptrBarDouble) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrBarDouble) SwigIsBarDouble() { +} + +var _wrap_BarDouble_blah unsafe.Pointer + +func _swig_wrap_BarDouble_blah(base SwigcptrBarDouble) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_BarDouble_blah, _swig_p) + return +} + +func (arg1 SwigcptrBarDouble) Blah() (_swig_ret string) { + return _swig_wrap_BarDouble_blah(arg1) +} + +var _wrap_new_BarDouble unsafe.Pointer + +func _swig_wrap_new_BarDouble() (base SwigcptrBarDouble) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_BarDouble, _swig_p) + return +} + +func NewBarDouble() (_swig_ret BarDouble) { + return _swig_wrap_new_BarDouble() +} + +var _wrap_delete_BarDouble unsafe.Pointer + +func _swig_wrap_delete_BarDouble(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_BarDouble, _swig_p) + return +} + +func DeleteBarDouble(arg1 BarDouble) { + _swig_wrap_delete_BarDouble(arg1.Swigcptr()) +} + +var _wrap_BarDouble_foomethod unsafe.Pointer + +func _swig_wrap_BarDouble_foomethod(base SwigcptrBarDouble) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_BarDouble_foomethod, _swig_p) + return +} + +func (_swig_base SwigcptrBarDouble) Foomethod() (_swig_ret string) { + return _swig_wrap_BarDouble_foomethod(_swig_base) +} + +func (p SwigcptrBarDouble) SwigIsFooDouble() { +} + +func (p SwigcptrBarDouble) SwigGetFooDouble() FooDouble { + return SwigcptrFooDouble(p.Swigcptr()) +} + +type BarDouble interface { + Swigcptr() uintptr + SwigIsBarDouble() + Blah() (_swig_ret string) + Foomethod() (_swig_ret string) + SwigIsFooDouble() + SwigGetFooDouble() FooDouble +} + +type SwigcptrBarUInt uintptr + +func (p SwigcptrBarUInt) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrBarUInt) SwigIsBarUInt() { +} + +var _wrap_BarUInt_blah unsafe.Pointer + +func _swig_wrap_BarUInt_blah(base SwigcptrBarUInt) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_BarUInt_blah, _swig_p) + return +} + +func (arg1 SwigcptrBarUInt) Blah() (_swig_ret string) { + return _swig_wrap_BarUInt_blah(arg1) +} + +var _wrap_new_BarUInt unsafe.Pointer + +func _swig_wrap_new_BarUInt() (base SwigcptrBarUInt) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_BarUInt, _swig_p) + return +} + +func NewBarUInt() (_swig_ret BarUInt) { + return _swig_wrap_new_BarUInt() +} + +var _wrap_delete_BarUInt unsafe.Pointer + +func _swig_wrap_delete_BarUInt(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_BarUInt, _swig_p) + return +} + +func DeleteBarUInt(arg1 BarUInt) { + _swig_wrap_delete_BarUInt(arg1.Swigcptr()) +} + +var _wrap_BarUInt_foomethod unsafe.Pointer + +func _swig_wrap_BarUInt_foomethod(base SwigcptrBarUInt) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_BarUInt_foomethod, _swig_p) + return +} + +func (_swig_base SwigcptrBarUInt) Foomethod() (_swig_ret string) { + return _swig_wrap_BarUInt_foomethod(_swig_base) +} + +func (p SwigcptrBarUInt) SwigIsFooUInt() { +} + +func (p SwigcptrBarUInt) SwigGetFooUInt() FooUInt { + return SwigcptrFooUInt(p.Swigcptr()) +} + +type BarUInt interface { + Swigcptr() uintptr + SwigIsBarUInt() + Blah() (_swig_ret string) + Foomethod() (_swig_ret string) + SwigIsFooUInt() + SwigGetFooUInt() FooUInt +} + +var _wrap_invoke_blah_int unsafe.Pointer + +func _swig_wrap_invoke_blah_int(base uintptr) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_invoke_blah_int, _swig_p) + return +} + +func Invoke_blah_int(arg1 FooInt) (_swig_ret string) { + return _swig_wrap_invoke_blah_int(arg1.Swigcptr()) +} + +var _wrap_invoke_blah_double unsafe.Pointer + +func _swig_wrap_invoke_blah_double(base uintptr) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_invoke_blah_double, _swig_p) + return +} + +func Invoke_blah_double(arg1 FooDouble) (_swig_ret string) { + return _swig_wrap_invoke_blah_double(arg1.Swigcptr()) +} + +var _wrap_invoke_blah_uint unsafe.Pointer + +func _swig_wrap_invoke_blah_uint(base uintptr) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_invoke_blah_uint, _swig_p) + return +} + +func Invoke_blah_uint(arg1 FooUInt) (_swig_ret string) { + return _swig_wrap_invoke_blah_uint(arg1.Swigcptr()) +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/template_inherit_abstract.go b/Examples/test-suite/go/template_inherit_abstract.go new file mode 100644 index 000000000..8caf1feee --- /dev/null +++ b/Examples/test-suite/go/template_inherit_abstract.go @@ -0,0 +1,358 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../template_inherit_abstract.i + +package template_inherit_abstract + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrModuleBase uintptr + +func (p SwigcptrModuleBase) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrModuleBase) SwigIsModuleBase() { +} + +var _wrap_delete_ModuleBase unsafe.Pointer + +func _swig_wrap_delete_ModuleBase(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_ModuleBase, _swig_p) + return +} + +func DeleteModuleBase(arg1 ModuleBase) { + _swig_wrap_delete_ModuleBase(arg1.Swigcptr()) +} + +var _wrap_ModuleBase_get unsafe.Pointer + +func _swig_wrap_ModuleBase_get(base SwigcptrModuleBase) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_ModuleBase_get, _swig_p) + return +} + +func (arg1 SwigcptrModuleBase) Get() (_swig_ret int) { + return _swig_wrap_ModuleBase_get(arg1) +} + +type ModuleBase interface { + Swigcptr() uintptr + SwigIsModuleBase() + Get() (_swig_ret int) +} + +type SwigcptrB uintptr + +func (p SwigcptrB) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrB) SwigIsB() { +} + +var _wrap_new_B unsafe.Pointer + +func _swig_wrap_new_B() (base SwigcptrB) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_B, _swig_p) + return +} + +func NewB() (_swig_ret B) { + return _swig_wrap_new_B() +} + +var _wrap_delete_B unsafe.Pointer + +func _swig_wrap_delete_B(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_B, _swig_p) + return +} + +func DeleteB(arg1 B) { + _swig_wrap_delete_B(arg1.Swigcptr()) +} + +type B interface { + Swigcptr() uintptr + SwigIsB() +} + +type SwigcptrWrap_B uintptr + +func (p SwigcptrWrap_B) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrWrap_B) SwigIsWrap_B() { +} + +var _wrap_new_Wrap_B unsafe.Pointer + +func _swig_wrap_new_Wrap_B() (base SwigcptrWrap_B) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Wrap_B, _swig_p) + return +} + +func NewWrap_B() (_swig_ret Wrap_B) { + return _swig_wrap_new_Wrap_B() +} + +var _wrap_delete_Wrap_B unsafe.Pointer + +func _swig_wrap_delete_Wrap_B(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Wrap_B, _swig_p) + return +} + +func DeleteWrap_B(arg1 Wrap_B) { + _swig_wrap_delete_Wrap_B(arg1.Swigcptr()) +} + +type Wrap_B interface { + Swigcptr() uintptr + SwigIsWrap_B() +} + +type SwigcptrModule_B uintptr + +func (p SwigcptrModule_B) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrModule_B) SwigIsModule_B() { +} + +var _wrap_delete_Module_B unsafe.Pointer + +func _swig_wrap_delete_Module_B(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Module_B, _swig_p) + return +} + +func DeleteModule_B(arg1 Module_B) { + _swig_wrap_delete_Module_B(arg1.Swigcptr()) +} + +var _wrap_Module_B_get unsafe.Pointer + +func _swig_wrap_Module_B_get(base SwigcptrModule_B) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Module_B_get, _swig_p) + return +} + +func (_swig_base SwigcptrModule_B) Get() (_swig_ret int) { + return _swig_wrap_Module_B_get(_swig_base) +} + +func (p SwigcptrModule_B) SwigIsWrap_B() { +} + +func (p SwigcptrModule_B) SwigGetWrap_B() Wrap_B { + return SwigcptrWrap_B(p.Swigcptr()) +} + +var _wrap_Module_B_SwigGetModuleBase unsafe.Pointer + +func _swig_wrap_Module_B_SwigGetModuleBase(base SwigcptrModule_B) (_ SwigcptrModuleBase) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Module_B_SwigGetModuleBase, _swig_p) + return +} + +func (arg1 SwigcptrModule_B) SwigGetModuleBase() (_swig_ret ModuleBase) { + return _swig_wrap_Module_B_SwigGetModuleBase(arg1) +} + +type Module_B interface { + Swigcptr() uintptr + SwigIsModule_B() + Get() (_swig_ret int) + SwigIsWrap_B() + SwigGetWrap_B() Wrap_B + SwigGetModuleBase() (_swig_ret ModuleBase) +} + +type SwigcptrHModule_B uintptr + +func (p SwigcptrHModule_B) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrHModule_B) SwigIsHModule_B() { +} + +var _wrap_delete_HModule_B unsafe.Pointer + +func _swig_wrap_delete_HModule_B(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_HModule_B, _swig_p) + return +} + +func DeleteHModule_B(arg1 HModule_B) { + _swig_wrap_delete_HModule_B(arg1.Swigcptr()) +} + +var _wrap_HModule_B_get unsafe.Pointer + +func _swig_wrap_HModule_B_get(base SwigcptrHModule_B) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_HModule_B_get, _swig_p) + return +} + +func (_swig_base SwigcptrHModule_B) Get() (_swig_ret int) { + return _swig_wrap_HModule_B_get(_swig_base) +} + +func (p SwigcptrHModule_B) SwigIsModule_B() { +} + +func (p SwigcptrHModule_B) SwigGetModule_B() Module_B { + return SwigcptrModule_B(p.Swigcptr()) +} + +func (p SwigcptrHModule_B) SwigIsWrap_B() { +} + +func (p SwigcptrHModule_B) SwigGetWrap_B() Wrap_B { + return SwigcptrWrap_B(p.Swigcptr()) +} + +func (p SwigcptrHModule_B) SwigGetModuleBase() ModuleBase { + return p.SwigGetModule_B().SwigGetModuleBase() +} + +type HModule_B interface { + Swigcptr() uintptr + SwigIsHModule_B() + Get() (_swig_ret int) + SwigIsModule_B() + SwigGetModule_B() Module_B + SwigIsWrap_B() + SwigGetWrap_B() Wrap_B + SwigGetModuleBase() ModuleBase +} + +type SwigcptrTest uintptr + +func (p SwigcptrTest) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrTest) SwigIsTest() { +} + +var _wrap_test_get unsafe.Pointer + +func _swig_wrap_test_get(base SwigcptrTest) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_test_get, _swig_p) + return +} + +func (arg1 SwigcptrTest) Get() (_swig_ret int) { + return _swig_wrap_test_get(arg1) +} + +var _wrap_new_test unsafe.Pointer + +func _swig_wrap_new_test() (base SwigcptrTest) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_test, _swig_p) + return +} + +func NewTest() (_swig_ret Test) { + return _swig_wrap_new_test() +} + +var _wrap_delete_test unsafe.Pointer + +func _swig_wrap_delete_test(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_test, _swig_p) + return +} + +func DeleteTest(arg1 Test) { + _swig_wrap_delete_test(arg1.Swigcptr()) +} + +func (p SwigcptrTest) SwigIsHModule_B() { +} + +func (p SwigcptrTest) SwigGetHModule_B() HModule_B { + return SwigcptrHModule_B(p.Swigcptr()) +} + +func (p SwigcptrTest) SwigIsModule_B() { +} + +func (p SwigcptrTest) SwigGetModule_B() Module_B { + return SwigcptrModule_B(p.Swigcptr()) +} + +func (p SwigcptrTest) SwigIsWrap_B() { +} + +func (p SwigcptrTest) SwigGetWrap_B() Wrap_B { + return SwigcptrWrap_B(p.Swigcptr()) +} + +func (p SwigcptrTest) SwigGetModuleBase() ModuleBase { + return p.SwigGetHModule_B().SwigGetModule_B().SwigGetModuleBase() +} + +type Test interface { + Swigcptr() uintptr + SwigIsTest() + Get() (_swig_ret int) + SwigIsHModule_B() + SwigGetHModule_B() HModule_B + SwigIsModule_B() + SwigGetModule_B() Module_B + SwigIsWrap_B() + SwigGetWrap_B() Wrap_B + SwigGetModuleBase() ModuleBase +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/template_inherit_runme b/Examples/test-suite/go/template_inherit_runme new file mode 100755 index 000000000..3d9050afa Binary files /dev/null and b/Examples/test-suite/go/template_inherit_runme differ diff --git a/Examples/test-suite/go/template_int_const.go b/Examples/test-suite/go/template_int_const.go new file mode 100644 index 000000000..e419369de --- /dev/null +++ b/Examples/test-suite/go/template_int_const.go @@ -0,0 +1,410 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../template_int_const.i + +package template_int_const + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type Polarization int +var _wrap_UnaryPolarization unsafe.Pointer + +func _swig_getUnaryPolarization() (_swig_ret Polarization) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_UnaryPolarization, _swig_p) + return +} +var UnaryPolarization Polarization = _swig_getUnaryPolarization() +var _wrap_BinaryPolarization unsafe.Pointer + +func _swig_getBinaryPolarization() (_swig_ret Polarization) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_BinaryPolarization, _swig_p) + return +} +var BinaryPolarization Polarization = _swig_getBinaryPolarization() +type SwigcptrInterface_traits uintptr + +func (p SwigcptrInterface_traits) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrInterface_traits) SwigIsInterface_traits() { +} + +var _wrap_interface_traits_polarization_interface_traits unsafe.Pointer + +func _swig_getinterface_traits_interface_traits_polarization_interface_traits() (_swig_ret Polarization) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_interface_traits_polarization_interface_traits, _swig_p) + return +} +var Interface_traitsPolarization Polarization = _swig_getinterface_traits_interface_traits_polarization_interface_traits() +var _wrap_new_interface_traits unsafe.Pointer + +func _swig_wrap_new_interface_traits() (base SwigcptrInterface_traits) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_interface_traits, _swig_p) + return +} + +func NewInterface_traits() (_swig_ret Interface_traits) { + return _swig_wrap_new_interface_traits() +} + +var _wrap_delete_interface_traits unsafe.Pointer + +func _swig_wrap_delete_interface_traits(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_interface_traits, _swig_p) + return +} + +func DeleteInterface_traits(arg1 Interface_traits) { + _swig_wrap_delete_interface_traits(arg1.Swigcptr()) +} + +type Interface_traits interface { + Swigcptr() uintptr + SwigIsInterface_traits() +} + +type SwigcptrModule_traits uintptr + +func (p SwigcptrModule_traits) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrModule_traits) SwigIsModule_traits() { +} + +var _wrap_module_traits_category_module_traits unsafe.Pointer + +func _swig_getmodule_traits_module_traits_category_module_traits() (_swig_ret uint) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_module_traits_category_module_traits, _swig_p) + return +} +var Module_traitsCategory uint = _swig_getmodule_traits_module_traits_category_module_traits() +var _wrap_new_module_traits unsafe.Pointer + +func _swig_wrap_new_module_traits() (base SwigcptrModule_traits) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_module_traits, _swig_p) + return +} + +func NewModule_traits() (_swig_ret Module_traits) { + return _swig_wrap_new_module_traits() +} + +var _wrap_delete_module_traits unsafe.Pointer + +func _swig_wrap_delete_module_traits(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_module_traits, _swig_p) + return +} + +func DeleteModule_traits(arg1 Module_traits) { + _swig_wrap_delete_module_traits(arg1.Swigcptr()) +} + +type Module_traits interface { + Swigcptr() uintptr + SwigIsModule_traits() +} + +type SwigcptrInterface_UP uintptr + +func (p SwigcptrInterface_UP) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrInterface_UP) SwigIsInterface_UP() { +} + +var _wrap_new_Interface_UP unsafe.Pointer + +func _swig_wrap_new_Interface_UP() (base SwigcptrInterface_UP) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Interface_UP, _swig_p) + return +} + +func NewInterface_UP() (_swig_ret Interface_UP) { + return _swig_wrap_new_Interface_UP() +} + +var _wrap_delete_Interface_UP unsafe.Pointer + +func _swig_wrap_delete_Interface_UP(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Interface_UP, _swig_p) + return +} + +func DeleteInterface_UP(arg1 Interface_UP) { + _swig_wrap_delete_Interface_UP(arg1.Swigcptr()) +} + +type Interface_UP interface { + Swigcptr() uintptr + SwigIsInterface_UP() +} + +type SwigcptrModule_1 uintptr + +func (p SwigcptrModule_1) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrModule_1) SwigIsModule_1() { +} + +var _wrap_new_Module_1 unsafe.Pointer + +func _swig_wrap_new_Module_1() (base SwigcptrModule_1) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Module_1, _swig_p) + return +} + +func NewModule_1() (_swig_ret Module_1) { + return _swig_wrap_new_Module_1() +} + +var _wrap_delete_Module_1 unsafe.Pointer + +func _swig_wrap_delete_Module_1(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Module_1, _swig_p) + return +} + +func DeleteModule_1(arg1 Module_1) { + _swig_wrap_delete_Module_1(arg1.Swigcptr()) +} + +type Module_1 interface { + Swigcptr() uintptr + SwigIsModule_1() +} + +type SwigcptrExtInterface1 uintptr + +func (p SwigcptrExtInterface1) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrExtInterface1) SwigIsExtInterface1() { +} + +var _wrap_new_ExtInterface1 unsafe.Pointer + +func _swig_wrap_new_ExtInterface1() (base SwigcptrExtInterface1) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_ExtInterface1, _swig_p) + return +} + +func NewExtInterface1() (_swig_ret ExtInterface1) { + return _swig_wrap_new_ExtInterface1() +} + +var _wrap_delete_ExtInterface1 unsafe.Pointer + +func _swig_wrap_delete_ExtInterface1(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_ExtInterface1, _swig_p) + return +} + +func DeleteExtInterface1(arg1 ExtInterface1) { + _swig_wrap_delete_ExtInterface1(arg1.Swigcptr()) +} + +func (p SwigcptrExtInterface1) SwigIsInterface_UP() { +} + +func (p SwigcptrExtInterface1) SwigGetInterface_UP() Interface_UP { + return SwigcptrInterface_UP(p.Swigcptr()) +} + +type ExtInterface1 interface { + Swigcptr() uintptr + SwigIsExtInterface1() + SwigIsInterface_UP() + SwigGetInterface_UP() Interface_UP +} + +type SwigcptrExtInterface2 uintptr + +func (p SwigcptrExtInterface2) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrExtInterface2) SwigIsExtInterface2() { +} + +var _wrap_new_ExtInterface2 unsafe.Pointer + +func _swig_wrap_new_ExtInterface2() (base SwigcptrExtInterface2) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_ExtInterface2, _swig_p) + return +} + +func NewExtInterface2() (_swig_ret ExtInterface2) { + return _swig_wrap_new_ExtInterface2() +} + +var _wrap_delete_ExtInterface2 unsafe.Pointer + +func _swig_wrap_delete_ExtInterface2(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_ExtInterface2, _swig_p) + return +} + +func DeleteExtInterface2(arg1 ExtInterface2) { + _swig_wrap_delete_ExtInterface2(arg1.Swigcptr()) +} + +func (p SwigcptrExtInterface2) SwigIsInterface_UP() { +} + +func (p SwigcptrExtInterface2) SwigGetInterface_UP() Interface_UP { + return SwigcptrInterface_UP(p.Swigcptr()) +} + +type ExtInterface2 interface { + Swigcptr() uintptr + SwigIsExtInterface2() + SwigIsInterface_UP() + SwigGetInterface_UP() Interface_UP +} + +type SwigcptrExtModule1 uintptr + +func (p SwigcptrExtModule1) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrExtModule1) SwigIsExtModule1() { +} + +var _wrap_new_ExtModule1 unsafe.Pointer + +func _swig_wrap_new_ExtModule1() (base SwigcptrExtModule1) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_ExtModule1, _swig_p) + return +} + +func NewExtModule1() (_swig_ret ExtModule1) { + return _swig_wrap_new_ExtModule1() +} + +var _wrap_delete_ExtModule1 unsafe.Pointer + +func _swig_wrap_delete_ExtModule1(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_ExtModule1, _swig_p) + return +} + +func DeleteExtModule1(arg1 ExtModule1) { + _swig_wrap_delete_ExtModule1(arg1.Swigcptr()) +} + +func (p SwigcptrExtModule1) SwigIsModule_1() { +} + +func (p SwigcptrExtModule1) SwigGetModule_1() Module_1 { + return SwigcptrModule_1(p.Swigcptr()) +} + +type ExtModule1 interface { + Swigcptr() uintptr + SwigIsExtModule1() + SwigIsModule_1() + SwigGetModule_1() Module_1 +} + +type SwigcptrExtModule2 uintptr + +func (p SwigcptrExtModule2) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrExtModule2) SwigIsExtModule2() { +} + +var _wrap_new_ExtModule2 unsafe.Pointer + +func _swig_wrap_new_ExtModule2() (base SwigcptrExtModule2) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_ExtModule2, _swig_p) + return +} + +func NewExtModule2() (_swig_ret ExtModule2) { + return _swig_wrap_new_ExtModule2() +} + +var _wrap_delete_ExtModule2 unsafe.Pointer + +func _swig_wrap_delete_ExtModule2(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_ExtModule2, _swig_p) + return +} + +func DeleteExtModule2(arg1 ExtModule2) { + _swig_wrap_delete_ExtModule2(arg1.Swigcptr()) +} + +func (p SwigcptrExtModule2) SwigIsModule_1() { +} + +func (p SwigcptrExtModule2) SwigGetModule_1() Module_1 { + return SwigcptrModule_1(p.Swigcptr()) +} + +type ExtModule2 interface { + Swigcptr() uintptr + SwigIsExtModule2() + SwigIsModule_1() + SwigGetModule_1() Module_1 +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/template_methods.go b/Examples/test-suite/go/template_methods.go new file mode 100644 index 000000000..fff042e8b --- /dev/null +++ b/Examples/test-suite/go/template_methods.go @@ -0,0 +1,322 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../template_methods.i + +package template_methods + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +var _wrap_convolve1Bool__SWIG_0 unsafe.Pointer + +func Convolve1Bool__SWIG_0() (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_convolve1Bool__SWIG_0, _swig_p) + return +} +var _wrap_convolve1Bool__SWIG_1 unsafe.Pointer + +func _swig_wrap_convolve1Bool__SWIG_1(base bool) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_convolve1Bool__SWIG_1, _swig_p) + return +} + +func Convolve1Bool__SWIG_1(arg1 bool) { + _swig_wrap_convolve1Bool__SWIG_1(arg1) +} + +func Convolve1Bool(a ...interface{}) interface{} { + argc := len(a) + if argc == 0 { + return Convolve1Bool__SWIG_0() + } + if argc == 1 { + Convolve1Bool__SWIG_1(a[0].(bool)) + return 0 + } + panic("No match for overloaded function call") +} + +var _wrap_convolve2Float unsafe.Pointer + +func Convolve2Float() (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_convolve2Float, _swig_p) + return +} +var _wrap_convolve3FloatRenamed unsafe.Pointer + +func _swig_wrap_convolve3FloatRenamed(base float32) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_convolve3FloatRenamed, _swig_p) + return +} + +func Convolve3FloatRenamed(arg1 float32) { + _swig_wrap_convolve3FloatRenamed(arg1) +} + +var _wrap_convolve4Float unsafe.Pointer + +func Convolve4Float() (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_convolve4Float, _swig_p) + return +} +var _wrap_convolve4FloatRenamed unsafe.Pointer + +func _swig_wrap_convolve4FloatRenamed(base float32) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_convolve4FloatRenamed, _swig_p) + return +} + +func Convolve4FloatRenamed(arg1 float32) { + _swig_wrap_convolve4FloatRenamed(arg1) +} + +var _wrap_convolve5FloatRenamed__SWIG_0 unsafe.Pointer + +func Convolve5FloatRenamed__SWIG_0() (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_convolve5FloatRenamed__SWIG_0, _swig_p) + return +} +var _wrap_convolve5FloatRenamed__SWIG_1 unsafe.Pointer + +func _swig_wrap_convolve5FloatRenamed__SWIG_1(base float32) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_convolve5FloatRenamed__SWIG_1, _swig_p) + return +} + +func Convolve5FloatRenamed__SWIG_1(arg1 float32) { + _swig_wrap_convolve5FloatRenamed__SWIG_1(arg1) +} + +func Convolve5FloatRenamed(a ...interface{}) interface{} { + argc := len(a) + if argc == 0 { + return Convolve5FloatRenamed__SWIG_0() + } + if argc == 1 { + Convolve5FloatRenamed__SWIG_1(a[0].(float32)) + return 0 + } + panic("No match for overloaded function call") +} + +type SwigcptrKlass uintptr + +func (p SwigcptrKlass) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrKlass) SwigIsKlass() { +} + +var _wrap_Klass_KlassTMethodBoolRenamed unsafe.Pointer + +func _swig_wrap_Klass_KlassTMethodBoolRenamed(base SwigcptrKlass, _ bool) (_ bool) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Klass_KlassTMethodBoolRenamed, _swig_p) + return +} + +func (arg1 SwigcptrKlass) KlassTMethodBoolRenamed(arg2 bool) (_swig_ret bool) { + return _swig_wrap_Klass_KlassTMethodBoolRenamed(arg1, arg2) +} + +var _wrap_Klass_KlassTMethodBool unsafe.Pointer + +func _swig_wrap_Klass_KlassTMethodBool(base SwigcptrKlass) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Klass_KlassTMethodBool, _swig_p) + return +} + +func (arg1 SwigcptrKlass) KlassTMethodBool() { + _swig_wrap_Klass_KlassTMethodBool(arg1) +} + +var _wrap_Klass_KlassStaticTMethodBoolRenamed unsafe.Pointer + +func KlassKlassStaticTMethodBoolRenamed(arg1 bool) (_swig_ret bool) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_Klass_KlassStaticTMethodBoolRenamed, _swig_p) + return +} +var _wrap_Klass_KlassStaticTMethodBool unsafe.Pointer + +func _swig_wrap_Klass_KlassStaticTMethodBool() { + var _swig_p uintptr + _cgo_runtime_cgocall(_wrap_Klass_KlassStaticTMethodBool, _swig_p) + return +} + +func KlassKlassStaticTMethodBool() { + _swig_wrap_Klass_KlassStaticTMethodBool() +} + +var _wrap_new_Klass unsafe.Pointer + +func _swig_wrap_new_Klass() (base SwigcptrKlass) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Klass, _swig_p) + return +} + +func NewKlass() (_swig_ret Klass) { + return _swig_wrap_new_Klass() +} + +var _wrap_delete_Klass unsafe.Pointer + +func _swig_wrap_delete_Klass(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Klass, _swig_p) + return +} + +func DeleteKlass(arg1 Klass) { + _swig_wrap_delete_Klass(arg1.Swigcptr()) +} + +type Klass interface { + Swigcptr() uintptr + SwigIsKlass() + KlassTMethodBoolRenamed(arg2 bool) (_swig_ret bool) + KlassTMethodBool() +} + +type SwigcptrComponentProperties uintptr + +func (p SwigcptrComponentProperties) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrComponentProperties) SwigIsComponentProperties() { +} + +var _wrap_new_ComponentProperties unsafe.Pointer + +func _swig_wrap_new_ComponentProperties() (base SwigcptrComponentProperties) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_ComponentProperties, _swig_p) + return +} + +func NewComponentProperties() (_swig_ret ComponentProperties) { + return _swig_wrap_new_ComponentProperties() +} + +var _wrap_delete_ComponentProperties unsafe.Pointer + +func _swig_wrap_delete_ComponentProperties(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_ComponentProperties, _swig_p) + return +} + +func DeleteComponentProperties(arg1 ComponentProperties) { + _swig_wrap_delete_ComponentProperties(arg1.Swigcptr()) +} + +var _wrap_ComponentProperties_adda__SWIG_3 unsafe.Pointer + +func _swig_wrap_ComponentProperties_adda__SWIG_3(base SwigcptrComponentProperties, _ string, _ string, _ string, _ float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_ComponentProperties_adda__SWIG_3, _swig_p) + return +} + +func (arg1 SwigcptrComponentProperties) Adda__SWIG_3(arg2 string, arg3 string, arg4 string, arg5 float64) { + _swig_wrap_ComponentProperties_adda__SWIG_3(arg1, arg2, arg3, arg4, arg5) +} + +var _wrap_ComponentProperties_adda__SWIG_4 unsafe.Pointer + +func _swig_wrap_ComponentProperties_adda__SWIG_4(base SwigcptrComponentProperties, _ string, _ string, _ string, _ string, _ string, _ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_ComponentProperties_adda__SWIG_4, _swig_p) + return +} + +func (arg1 SwigcptrComponentProperties) Adda__SWIG_4(arg2 string, arg3 string, arg4 string, arg5 string, arg6 string, arg7 string) { + _swig_wrap_ComponentProperties_adda__SWIG_4(arg1, arg2, arg3, arg4, arg5, arg6, arg7) +} + +var _wrap_ComponentProperties_adda__SWIG_5 unsafe.Pointer + +func _swig_wrap_ComponentProperties_adda__SWIG_5(base SwigcptrComponentProperties, _ string, _ int, _ string, _ int, _ string, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_ComponentProperties_adda__SWIG_5, _swig_p) + return +} + +func (arg1 SwigcptrComponentProperties) Adda__SWIG_5(arg2 string, arg3 int, arg4 string, arg5 int, arg6 string, arg7 int) { + _swig_wrap_ComponentProperties_adda__SWIG_5(arg1, arg2, arg3, arg4, arg5, arg6, arg7) +} + +func (p SwigcptrComponentProperties) Adda(a ...interface{}) { + argc := len(a) + if argc == 4 { + p.Adda__SWIG_3(a[0].(string), a[1].(string), a[2].(string), a[3].(float64)) + return + } + if argc == 6 { + if _, ok := a[1].(string); !ok { + goto check_2 + } + if _, ok := a[3].(string); !ok { + goto check_2 + } + if _, ok := a[5].(string); !ok { + goto check_2 + } + p.Adda__SWIG_4(a[0].(string), a[1].(string), a[2].(string), a[3].(string), a[4].(string), a[5].(string)) + return + } +check_2: + if argc == 6 { + p.Adda__SWIG_5(a[0].(string), a[1].(int), a[2].(string), a[3].(int), a[4].(string), a[5].(int)) + return + } + panic("No match for overloaded function call") +} + +type ComponentProperties interface { + Swigcptr() uintptr + SwigIsComponentProperties() + Adda(a ...interface{}) +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/template_namespace_forward_declaration.go b/Examples/test-suite/go/template_namespace_forward_declaration.go new file mode 100644 index 000000000..56b0ccfd6 --- /dev/null +++ b/Examples/test-suite/go/template_namespace_forward_declaration.go @@ -0,0 +1,211 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../template_namespace_forward_declaration.i + +package template_namespace_forward_declaration + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +var _wrap_testXXX1 unsafe.Pointer + +func _swig_wrap_testXXX1(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_testXXX1, _swig_p) + return +} + +func TestXXX1(arg1 XXXInt) { + _swig_wrap_testXXX1(arg1.Swigcptr()) +} + +var _wrap_testXXX2 unsafe.Pointer + +func _swig_wrap_testXXX2(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_testXXX2, _swig_p) + return +} + +func TestXXX2(arg1 XXXInt) { + _swig_wrap_testXXX2(arg1.Swigcptr()) +} + +var _wrap_testXXX3 unsafe.Pointer + +func _swig_wrap_testXXX3(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_testXXX3, _swig_p) + return +} + +func TestXXX3(arg1 XXXInt) { + _swig_wrap_testXXX3(arg1.Swigcptr()) +} + +var _wrap_testYYY1 unsafe.Pointer + +func _swig_wrap_testYYY1(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_testYYY1, _swig_p) + return +} + +func TestYYY1(arg1 YYYInt) { + _swig_wrap_testYYY1(arg1.Swigcptr()) +} + +var _wrap_testYYY2 unsafe.Pointer + +func _swig_wrap_testYYY2(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_testYYY2, _swig_p) + return +} + +func TestYYY2(arg1 YYYInt) { + _swig_wrap_testYYY2(arg1.Swigcptr()) +} + +var _wrap_testYYY3 unsafe.Pointer + +func _swig_wrap_testYYY3(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_testYYY3, _swig_p) + return +} + +func TestYYY3(arg1 YYYInt) { + _swig_wrap_testYYY3(arg1.Swigcptr()) +} + +type SwigcptrXXXInt uintptr + +func (p SwigcptrXXXInt) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrXXXInt) SwigIsXXXInt() { +} + +var _wrap_XXXInt_xxx unsafe.Pointer + +func _swig_wrap_XXXInt_xxx(base SwigcptrXXXInt, _ int) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_XXXInt_xxx, _swig_p) + return +} + +func (arg1 SwigcptrXXXInt) Xxx(arg2 int) (_swig_ret int) { + return _swig_wrap_XXXInt_xxx(arg1, arg2) +} + +var _wrap_new_XXXInt unsafe.Pointer + +func _swig_wrap_new_XXXInt() (base SwigcptrXXXInt) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_XXXInt, _swig_p) + return +} + +func NewXXXInt() (_swig_ret XXXInt) { + return _swig_wrap_new_XXXInt() +} + +var _wrap_delete_XXXInt unsafe.Pointer + +func _swig_wrap_delete_XXXInt(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_XXXInt, _swig_p) + return +} + +func DeleteXXXInt(arg1 XXXInt) { + _swig_wrap_delete_XXXInt(arg1.Swigcptr()) +} + +type XXXInt interface { + Swigcptr() uintptr + SwigIsXXXInt() + Xxx(arg2 int) (_swig_ret int) +} + +type SwigcptrYYYInt uintptr + +func (p SwigcptrYYYInt) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrYYYInt) SwigIsYYYInt() { +} + +var _wrap_YYYInt_yyy unsafe.Pointer + +func _swig_wrap_YYYInt_yyy(base SwigcptrYYYInt, _ int) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_YYYInt_yyy, _swig_p) + return +} + +func (arg1 SwigcptrYYYInt) Yyy(arg2 int) (_swig_ret int) { + return _swig_wrap_YYYInt_yyy(arg1, arg2) +} + +var _wrap_new_YYYInt unsafe.Pointer + +func _swig_wrap_new_YYYInt() (base SwigcptrYYYInt) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_YYYInt, _swig_p) + return +} + +func NewYYYInt() (_swig_ret YYYInt) { + return _swig_wrap_new_YYYInt() +} + +var _wrap_delete_YYYInt unsafe.Pointer + +func _swig_wrap_delete_YYYInt(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_YYYInt, _swig_p) + return +} + +func DeleteYYYInt(arg1 YYYInt) { + _swig_wrap_delete_YYYInt(arg1.Swigcptr()) +} + +type YYYInt interface { + Swigcptr() uintptr + SwigIsYYYInt() + Yyy(arg2 int) (_swig_ret int) +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/template_nested.go b/Examples/test-suite/go/template_nested.go new file mode 100644 index 000000000..43bfddec3 --- /dev/null +++ b/Examples/test-suite/go/template_nested.go @@ -0,0 +1,919 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../template_nested.i + +package template_nested + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrNormalClass uintptr + +func (p SwigcptrNormalClass) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrNormalClass) SwigIsNormalClass() { +} + +var _wrap_new_NormalClass unsafe.Pointer + +func _swig_wrap_new_NormalClass() (base SwigcptrNormalClass) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_NormalClass, _swig_p) + return +} + +func NewNormalClass() (_swig_ret NormalClass) { + return _swig_wrap_new_NormalClass() +} + +var _wrap_delete_NormalClass unsafe.Pointer + +func _swig_wrap_delete_NormalClass(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_NormalClass, _swig_p) + return +} + +func DeleteNormalClass(arg1 NormalClass) { + _swig_wrap_delete_NormalClass(arg1.Swigcptr()) +} + +type NormalClass interface { + Swigcptr() uintptr + SwigIsNormalClass() +} + +type SwigcptrT_NormalTemplateNormalClass uintptr + +func (p SwigcptrT_NormalTemplateNormalClass) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrT_NormalTemplateNormalClass) SwigIsT_NormalTemplateNormalClass() { +} + +var _wrap_T_NormalTemplateNormalClass_tmethod unsafe.Pointer + +func _swig_wrap_T_NormalTemplateNormalClass_tmethod(base SwigcptrT_NormalTemplateNormalClass, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_T_NormalTemplateNormalClass_tmethod, _swig_p) + return +} + +func (arg1 SwigcptrT_NormalTemplateNormalClass) Tmethod(arg2 NormalClass) { + _swig_wrap_T_NormalTemplateNormalClass_tmethod(arg1, arg2.Swigcptr()) +} + +var _wrap_new_T_NormalTemplateNormalClass unsafe.Pointer + +func _swig_wrap_new_T_NormalTemplateNormalClass() (base SwigcptrT_NormalTemplateNormalClass) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_T_NormalTemplateNormalClass, _swig_p) + return +} + +func NewT_NormalTemplateNormalClass() (_swig_ret T_NormalTemplateNormalClass) { + return _swig_wrap_new_T_NormalTemplateNormalClass() +} + +var _wrap_delete_T_NormalTemplateNormalClass unsafe.Pointer + +func _swig_wrap_delete_T_NormalTemplateNormalClass(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_T_NormalTemplateNormalClass, _swig_p) + return +} + +func DeleteT_NormalTemplateNormalClass(arg1 T_NormalTemplateNormalClass) { + _swig_wrap_delete_T_NormalTemplateNormalClass(arg1.Swigcptr()) +} + +type T_NormalTemplateNormalClass interface { + Swigcptr() uintptr + SwigIsT_NormalTemplateNormalClass() + Tmethod(arg2 NormalClass) +} + +type SwigcptrT_NormalTemplateInt uintptr + +func (p SwigcptrT_NormalTemplateInt) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrT_NormalTemplateInt) SwigIsT_NormalTemplateInt() { +} + +var _wrap_T_NormalTemplateInt_tmethod unsafe.Pointer + +func _swig_wrap_T_NormalTemplateInt_tmethod(base SwigcptrT_NormalTemplateInt, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_T_NormalTemplateInt_tmethod, _swig_p) + return +} + +func (arg1 SwigcptrT_NormalTemplateInt) Tmethod(arg2 int) { + _swig_wrap_T_NormalTemplateInt_tmethod(arg1, arg2) +} + +var _wrap_new_T_NormalTemplateInt unsafe.Pointer + +func _swig_wrap_new_T_NormalTemplateInt() (base SwigcptrT_NormalTemplateInt) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_T_NormalTemplateInt, _swig_p) + return +} + +func NewT_NormalTemplateInt() (_swig_ret T_NormalTemplateInt) { + return _swig_wrap_new_T_NormalTemplateInt() +} + +var _wrap_delete_T_NormalTemplateInt unsafe.Pointer + +func _swig_wrap_delete_T_NormalTemplateInt(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_T_NormalTemplateInt, _swig_p) + return +} + +func DeleteT_NormalTemplateInt(arg1 T_NormalTemplateInt) { + _swig_wrap_delete_T_NormalTemplateInt(arg1.Swigcptr()) +} + +type T_NormalTemplateInt interface { + Swigcptr() uintptr + SwigIsT_NormalTemplateInt() + Tmethod(arg2 int) +} + +type SwigcptrT_NormalTemplateDouble uintptr + +func (p SwigcptrT_NormalTemplateDouble) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrT_NormalTemplateDouble) SwigIsT_NormalTemplateDouble() { +} + +var _wrap_T_NormalTemplateDouble_tmethod unsafe.Pointer + +func _swig_wrap_T_NormalTemplateDouble_tmethod(base SwigcptrT_NormalTemplateDouble, _ float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_T_NormalTemplateDouble_tmethod, _swig_p) + return +} + +func (arg1 SwigcptrT_NormalTemplateDouble) Tmethod(arg2 float64) { + _swig_wrap_T_NormalTemplateDouble_tmethod(arg1, arg2) +} + +var _wrap_new_T_NormalTemplateDouble unsafe.Pointer + +func _swig_wrap_new_T_NormalTemplateDouble() (base SwigcptrT_NormalTemplateDouble) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_T_NormalTemplateDouble, _swig_p) + return +} + +func NewT_NormalTemplateDouble() (_swig_ret T_NormalTemplateDouble) { + return _swig_wrap_new_T_NormalTemplateDouble() +} + +var _wrap_delete_T_NormalTemplateDouble unsafe.Pointer + +func _swig_wrap_delete_T_NormalTemplateDouble(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_T_NormalTemplateDouble, _swig_p) + return +} + +func DeleteT_NormalTemplateDouble(arg1 T_NormalTemplateDouble) { + _swig_wrap_delete_T_NormalTemplateDouble(arg1.Swigcptr()) +} + +type T_NormalTemplateDouble interface { + Swigcptr() uintptr + SwigIsT_NormalTemplateDouble() + Tmethod(arg2 float64) +} + +type SwigcptrOuterClass uintptr + +func (p SwigcptrOuterClass) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrOuterClass) SwigIsOuterClass() { +} + +var _wrap_OuterClass_useInner1 unsafe.Pointer + +func _swig_wrap_OuterClass_useInner1(base SwigcptrOuterClass, _ uintptr) (_ SwigcptrT_OuterClassInner1Int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_OuterClass_useInner1, _swig_p) + return +} + +func (arg1 SwigcptrOuterClass) UseInner1(arg2 T_OuterClassInner1Int) (_swig_ret T_OuterClassInner1Int) { + return _swig_wrap_OuterClass_useInner1(arg1, arg2.Swigcptr()) +} + +var _wrap_OuterClass_useInner2 unsafe.Pointer + +func _swig_wrap_OuterClass_useInner2(base SwigcptrOuterClass, _ uintptr) (_ SwigcptrT_OuterClassInner2Int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_OuterClass_useInner2, _swig_p) + return +} + +func (arg1 SwigcptrOuterClass) UseInner2(arg2 T_OuterClassInner2Int) (_swig_ret T_OuterClassInner2Int) { + return _swig_wrap_OuterClass_useInner2(arg1, arg2.Swigcptr()) +} + +var _wrap_OuterClass_useInner2Again unsafe.Pointer + +func _swig_wrap_OuterClass_useInner2Again(base SwigcptrOuterClass, _ uintptr) (_ SwigcptrT_OuterClassInner2NormalClass) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_OuterClass_useInner2Again, _swig_p) + return +} + +func (arg1 SwigcptrOuterClass) UseInner2Again(arg2 T_OuterClassInner2NormalClass) (_swig_ret T_OuterClassInner2NormalClass) { + return _swig_wrap_OuterClass_useInner2Again(arg1, arg2.Swigcptr()) +} + +var _wrap_OuterClass_iii_set unsafe.Pointer + +func _swig_wrap_OuterClass_iii_set(base SwigcptrOuterClass, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_OuterClass_iii_set, _swig_p) + return +} + +func (arg1 SwigcptrOuterClass) SetIii(arg2 int) { + _swig_wrap_OuterClass_iii_set(arg1, arg2) +} + +var _wrap_OuterClass_iii_get unsafe.Pointer + +func _swig_wrap_OuterClass_iii_get(base SwigcptrOuterClass) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_OuterClass_iii_get, _swig_p) + return +} + +func (arg1 SwigcptrOuterClass) GetIii() (_swig_ret int) { + return _swig_wrap_OuterClass_iii_get(arg1) +} + +var _wrap_OuterClass_T_OuterTMethodNormalClass unsafe.Pointer + +func _swig_wrap_OuterClass_T_OuterTMethodNormalClass(base SwigcptrOuterClass, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_OuterClass_T_OuterTMethodNormalClass, _swig_p) + return +} + +func (arg1 SwigcptrOuterClass) T_OuterTMethodNormalClass(arg2 NormalClass) { + _swig_wrap_OuterClass_T_OuterTMethodNormalClass(arg1, arg2.Swigcptr()) +} + +var _wrap_new_OuterClass unsafe.Pointer + +func _swig_wrap_new_OuterClass() (base SwigcptrOuterClass) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_OuterClass, _swig_p) + return +} + +func NewOuterClass() (_swig_ret OuterClass) { + return _swig_wrap_new_OuterClass() +} + +var _wrap_delete_OuterClass unsafe.Pointer + +func _swig_wrap_delete_OuterClass(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_OuterClass, _swig_p) + return +} + +func DeleteOuterClass(arg1 OuterClass) { + _swig_wrap_delete_OuterClass(arg1.Swigcptr()) +} + +type OuterClass interface { + Swigcptr() uintptr + SwigIsOuterClass() + UseInner1(arg2 T_OuterClassInner1Int) (_swig_ret T_OuterClassInner1Int) + UseInner2(arg2 T_OuterClassInner2Int) (_swig_ret T_OuterClassInner2Int) + UseInner2Again(arg2 T_OuterClassInner2NormalClass) (_swig_ret T_OuterClassInner2NormalClass) + SetIii(arg2 int) + GetIii() (_swig_ret int) + T_OuterTMethodNormalClass(arg2 NormalClass) +} + +type SwigcptrT_OuterClassInner1Double uintptr + +func (p SwigcptrT_OuterClassInner1Double) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrT_OuterClassInner1Double) SwigIsT_OuterClassInner1Double() { +} + +var _wrap_new_T_OuterClassInner1Double unsafe.Pointer + +func _swig_wrap_new_T_OuterClassInner1Double() (base SwigcptrT_OuterClassInner1Double) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_T_OuterClassInner1Double, _swig_p) + return +} + +func NewT_OuterClassInner1Double() (_swig_ret T_OuterClassInner1Double) { + return _swig_wrap_new_T_OuterClassInner1Double() +} + +var _wrap_delete_T_OuterClassInner1Double unsafe.Pointer + +func _swig_wrap_delete_T_OuterClassInner1Double(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_T_OuterClassInner1Double, _swig_p) + return +} + +func DeleteT_OuterClassInner1Double(arg1 T_OuterClassInner1Double) { + _swig_wrap_delete_T_OuterClassInner1Double(arg1.Swigcptr()) +} + +type T_OuterClassInner1Double interface { + Swigcptr() uintptr + SwigIsT_OuterClassInner1Double() +} + +type SwigcptrT_OuterClassInner2Double uintptr + +func (p SwigcptrT_OuterClassInner2Double) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrT_OuterClassInner2Double) SwigIsT_OuterClassInner2Double() { +} + +var _wrap_T_OuterClassInner2Double_embeddedVar_set unsafe.Pointer + +func _swig_wrap_T_OuterClassInner2Double_embeddedVar_set(base SwigcptrT_OuterClassInner2Double, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_T_OuterClassInner2Double_embeddedVar_set, _swig_p) + return +} + +func (arg1 SwigcptrT_OuterClassInner2Double) SetEmbeddedVar(arg2 int) { + _swig_wrap_T_OuterClassInner2Double_embeddedVar_set(arg1, arg2) +} + +var _wrap_T_OuterClassInner2Double_embeddedVar_get unsafe.Pointer + +func _swig_wrap_T_OuterClassInner2Double_embeddedVar_get(base SwigcptrT_OuterClassInner2Double) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_T_OuterClassInner2Double_embeddedVar_get, _swig_p) + return +} + +func (arg1 SwigcptrT_OuterClassInner2Double) GetEmbeddedVar() (_swig_ret int) { + return _swig_wrap_T_OuterClassInner2Double_embeddedVar_get(arg1) +} + +var _wrap_new_T_OuterClassInner2Double unsafe.Pointer + +func _swig_wrap_new_T_OuterClassInner2Double() (base SwigcptrT_OuterClassInner2Double) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_T_OuterClassInner2Double, _swig_p) + return +} + +func NewT_OuterClassInner2Double() (_swig_ret T_OuterClassInner2Double) { + return _swig_wrap_new_T_OuterClassInner2Double() +} + +var _wrap_delete_T_OuterClassInner2Double unsafe.Pointer + +func _swig_wrap_delete_T_OuterClassInner2Double(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_T_OuterClassInner2Double, _swig_p) + return +} + +func DeleteT_OuterClassInner2Double(arg1 T_OuterClassInner2Double) { + _swig_wrap_delete_T_OuterClassInner2Double(arg1.Swigcptr()) +} + +func (p SwigcptrT_OuterClassInner2Double) SwigIsT_NormalTemplateDouble() { +} + +func (p SwigcptrT_OuterClassInner2Double) SwigGetT_NormalTemplateDouble() T_NormalTemplateDouble { + return SwigcptrT_NormalTemplateDouble(p.Swigcptr()) +} + +type T_OuterClassInner2Double interface { + Swigcptr() uintptr + SwigIsT_OuterClassInner2Double() + SetEmbeddedVar(arg2 int) + GetEmbeddedVar() (_swig_ret int) + SwigIsT_NormalTemplateDouble() + SwigGetT_NormalTemplateDouble() T_NormalTemplateDouble +} + +type SwigcptrT_OuterClassInner1Int uintptr + +func (p SwigcptrT_OuterClassInner1Int) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrT_OuterClassInner1Int) SwigIsT_OuterClassInner1Int() { +} + +var _wrap_new_T_OuterClassInner1Int unsafe.Pointer + +func _swig_wrap_new_T_OuterClassInner1Int() (base SwigcptrT_OuterClassInner1Int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_T_OuterClassInner1Int, _swig_p) + return +} + +func NewT_OuterClassInner1Int() (_swig_ret T_OuterClassInner1Int) { + return _swig_wrap_new_T_OuterClassInner1Int() +} + +var _wrap_delete_T_OuterClassInner1Int unsafe.Pointer + +func _swig_wrap_delete_T_OuterClassInner1Int(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_T_OuterClassInner1Int, _swig_p) + return +} + +func DeleteT_OuterClassInner1Int(arg1 T_OuterClassInner1Int) { + _swig_wrap_delete_T_OuterClassInner1Int(arg1.Swigcptr()) +} + +type T_OuterClassInner1Int interface { + Swigcptr() uintptr + SwigIsT_OuterClassInner1Int() +} + +type SwigcptrT_OuterClassInner2NormalClass uintptr + +func (p SwigcptrT_OuterClassInner2NormalClass) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrT_OuterClassInner2NormalClass) SwigIsT_OuterClassInner2NormalClass() { +} + +var _wrap_T_OuterClassInner2NormalClass_embeddedVar_set unsafe.Pointer + +func _swig_wrap_T_OuterClassInner2NormalClass_embeddedVar_set(base SwigcptrT_OuterClassInner2NormalClass, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_T_OuterClassInner2NormalClass_embeddedVar_set, _swig_p) + return +} + +func (arg1 SwigcptrT_OuterClassInner2NormalClass) SetEmbeddedVar(arg2 int) { + _swig_wrap_T_OuterClassInner2NormalClass_embeddedVar_set(arg1, arg2) +} + +var _wrap_T_OuterClassInner2NormalClass_embeddedVar_get unsafe.Pointer + +func _swig_wrap_T_OuterClassInner2NormalClass_embeddedVar_get(base SwigcptrT_OuterClassInner2NormalClass) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_T_OuterClassInner2NormalClass_embeddedVar_get, _swig_p) + return +} + +func (arg1 SwigcptrT_OuterClassInner2NormalClass) GetEmbeddedVar() (_swig_ret int) { + return _swig_wrap_T_OuterClassInner2NormalClass_embeddedVar_get(arg1) +} + +var _wrap_new_T_OuterClassInner2NormalClass unsafe.Pointer + +func _swig_wrap_new_T_OuterClassInner2NormalClass() (base SwigcptrT_OuterClassInner2NormalClass) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_T_OuterClassInner2NormalClass, _swig_p) + return +} + +func NewT_OuterClassInner2NormalClass() (_swig_ret T_OuterClassInner2NormalClass) { + return _swig_wrap_new_T_OuterClassInner2NormalClass() +} + +var _wrap_delete_T_OuterClassInner2NormalClass unsafe.Pointer + +func _swig_wrap_delete_T_OuterClassInner2NormalClass(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_T_OuterClassInner2NormalClass, _swig_p) + return +} + +func DeleteT_OuterClassInner2NormalClass(arg1 T_OuterClassInner2NormalClass) { + _swig_wrap_delete_T_OuterClassInner2NormalClass(arg1.Swigcptr()) +} + +func (p SwigcptrT_OuterClassInner2NormalClass) SwigIsT_NormalTemplateNormalClass() { +} + +func (p SwigcptrT_OuterClassInner2NormalClass) SwigGetT_NormalTemplateNormalClass() T_NormalTemplateNormalClass { + return SwigcptrT_NormalTemplateNormalClass(p.Swigcptr()) +} + +type T_OuterClassInner2NormalClass interface { + Swigcptr() uintptr + SwigIsT_OuterClassInner2NormalClass() + SetEmbeddedVar(arg2 int) + GetEmbeddedVar() (_swig_ret int) + SwigIsT_NormalTemplateNormalClass() + SwigGetT_NormalTemplateNormalClass() T_NormalTemplateNormalClass +} + +type SwigcptrT_OuterClassInner2Int uintptr + +func (p SwigcptrT_OuterClassInner2Int) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrT_OuterClassInner2Int) SwigIsT_OuterClassInner2Int() { +} + +var _wrap_T_OuterClassInner2Int_embeddedVar_set unsafe.Pointer + +func _swig_wrap_T_OuterClassInner2Int_embeddedVar_set(base SwigcptrT_OuterClassInner2Int, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_T_OuterClassInner2Int_embeddedVar_set, _swig_p) + return +} + +func (arg1 SwigcptrT_OuterClassInner2Int) SetEmbeddedVar(arg2 int) { + _swig_wrap_T_OuterClassInner2Int_embeddedVar_set(arg1, arg2) +} + +var _wrap_T_OuterClassInner2Int_embeddedVar_get unsafe.Pointer + +func _swig_wrap_T_OuterClassInner2Int_embeddedVar_get(base SwigcptrT_OuterClassInner2Int) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_T_OuterClassInner2Int_embeddedVar_get, _swig_p) + return +} + +func (arg1 SwigcptrT_OuterClassInner2Int) GetEmbeddedVar() (_swig_ret int) { + return _swig_wrap_T_OuterClassInner2Int_embeddedVar_get(arg1) +} + +var _wrap_new_T_OuterClassInner2Int unsafe.Pointer + +func _swig_wrap_new_T_OuterClassInner2Int() (base SwigcptrT_OuterClassInner2Int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_T_OuterClassInner2Int, _swig_p) + return +} + +func NewT_OuterClassInner2Int() (_swig_ret T_OuterClassInner2Int) { + return _swig_wrap_new_T_OuterClassInner2Int() +} + +var _wrap_delete_T_OuterClassInner2Int unsafe.Pointer + +func _swig_wrap_delete_T_OuterClassInner2Int(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_T_OuterClassInner2Int, _swig_p) + return +} + +func DeleteT_OuterClassInner2Int(arg1 T_OuterClassInner2Int) { + _swig_wrap_delete_T_OuterClassInner2Int(arg1.Swigcptr()) +} + +func (p SwigcptrT_OuterClassInner2Int) SwigIsT_NormalTemplateInt() { +} + +func (p SwigcptrT_OuterClassInner2Int) SwigGetT_NormalTemplateInt() T_NormalTemplateInt { + return SwigcptrT_NormalTemplateInt(p.Swigcptr()) +} + +type T_OuterClassInner2Int interface { + Swigcptr() uintptr + SwigIsT_OuterClassInner2Int() + SetEmbeddedVar(arg2 int) + GetEmbeddedVar() (_swig_ret int) + SwigIsT_NormalTemplateInt() + SwigGetT_NormalTemplateInt() T_NormalTemplateInt +} + +type SwigcptrABC uintptr + +func (p SwigcptrABC) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrABC) SwigIsABC() { +} + +var _wrap_new_ABC unsafe.Pointer + +func _swig_wrap_new_ABC() (base SwigcptrABC) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_ABC, _swig_p) + return +} + +func NewABC() (_swig_ret ABC) { + return _swig_wrap_new_ABC() +} + +var _wrap_delete_ABC unsafe.Pointer + +func _swig_wrap_delete_ABC(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_ABC, _swig_p) + return +} + +func DeleteABC(arg1 ABC) { + _swig_wrap_delete_ABC(arg1.Swigcptr()) +} + +type ABC interface { + Swigcptr() uintptr + SwigIsABC() +} + +type SwigcptrTemplateFuncs uintptr + +func (p SwigcptrTemplateFuncs) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrTemplateFuncs) SwigIsTemplateFuncs() { +} + +var _wrap_TemplateFuncs_T_TemplateFuncs1Int unsafe.Pointer + +func _swig_wrap_TemplateFuncs_T_TemplateFuncs1Int(base SwigcptrTemplateFuncs, _ int) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_TemplateFuncs_T_TemplateFuncs1Int, _swig_p) + return +} + +func (arg1 SwigcptrTemplateFuncs) T_TemplateFuncs1Int(arg2 int) (_swig_ret int) { + return _swig_wrap_TemplateFuncs_T_TemplateFuncs1Int(arg1, arg2) +} + +var _wrap_TemplateFuncs_T_TemplateFuncs2Double unsafe.Pointer + +func _swig_wrap_TemplateFuncs_T_TemplateFuncs2Double(base SwigcptrTemplateFuncs, _ float64) (_ float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_TemplateFuncs_T_TemplateFuncs2Double, _swig_p) + return +} + +func (arg1 SwigcptrTemplateFuncs) T_TemplateFuncs2Double(arg2 float64) (_swig_ret float64) { + return _swig_wrap_TemplateFuncs_T_TemplateFuncs2Double(arg1, arg2) +} + +var _wrap_new_TemplateFuncs unsafe.Pointer + +func _swig_wrap_new_TemplateFuncs() (base SwigcptrTemplateFuncs) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_TemplateFuncs, _swig_p) + return +} + +func NewTemplateFuncs() (_swig_ret TemplateFuncs) { + return _swig_wrap_new_TemplateFuncs() +} + +var _wrap_delete_TemplateFuncs unsafe.Pointer + +func _swig_wrap_delete_TemplateFuncs(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_TemplateFuncs, _swig_p) + return +} + +func DeleteTemplateFuncs(arg1 TemplateFuncs) { + _swig_wrap_delete_TemplateFuncs(arg1.Swigcptr()) +} + +type TemplateFuncs interface { + Swigcptr() uintptr + SwigIsTemplateFuncs() + T_TemplateFuncs1Int(arg2 int) (_swig_ret int) + T_TemplateFuncs2Double(arg2 float64) (_swig_ret float64) +} + +type SwigcptrT_NestedOuterTemplateDouble uintptr + +func (p SwigcptrT_NestedOuterTemplateDouble) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrT_NestedOuterTemplateDouble) SwigIsT_NestedOuterTemplateDouble() { +} + +var _wrap_T_NestedOuterTemplateDouble_hohum unsafe.Pointer + +func _swig_wrap_T_NestedOuterTemplateDouble_hohum(base SwigcptrT_NestedOuterTemplateDouble, _ float64) (_ float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_T_NestedOuterTemplateDouble_hohum, _swig_p) + return +} + +func (arg1 SwigcptrT_NestedOuterTemplateDouble) Hohum(arg2 float64) (_swig_ret float64) { + return _swig_wrap_T_NestedOuterTemplateDouble_hohum(arg1, arg2) +} + +var _wrap_T_NestedOuterTemplateDouble_useNestedInnerTemplate1 unsafe.Pointer + +func _swig_wrap_T_NestedOuterTemplateDouble_useNestedInnerTemplate1(base SwigcptrT_NestedOuterTemplateDouble, _ uintptr) (_ SwigcptrNs_OuterTemplate_Sl_double_Sg__NestedInnerTemplate1_Sl_short_Sg_) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_T_NestedOuterTemplateDouble_useNestedInnerTemplate1, _swig_p) + return +} + +func (arg1 SwigcptrT_NestedOuterTemplateDouble) UseNestedInnerTemplate1(arg2 Ns_OuterTemplate_Sl_double_Sg__NestedInnerTemplate1_Sl_short_Sg_) (_swig_ret Ns_OuterTemplate_Sl_double_Sg__NestedInnerTemplate1_Sl_short_Sg_) { + return _swig_wrap_T_NestedOuterTemplateDouble_useNestedInnerTemplate1(arg1, arg2.Swigcptr()) +} + +var _wrap_T_NestedOuterTemplateDouble_useNestedInnerTemplate2 unsafe.Pointer + +func _swig_wrap_T_NestedOuterTemplateDouble_useNestedInnerTemplate2(base SwigcptrT_NestedOuterTemplateDouble, _ uintptr) (_ SwigcptrNs_OuterTemplate_Sl_double_Sg__NestedInnerTemplate2_Sl_short_Sg_) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_T_NestedOuterTemplateDouble_useNestedInnerTemplate2, _swig_p) + return +} + +func (arg1 SwigcptrT_NestedOuterTemplateDouble) UseNestedInnerTemplate2(arg2 Ns_OuterTemplate_Sl_double_Sg__NestedInnerTemplate2_Sl_short_Sg_) (_swig_ret Ns_OuterTemplate_Sl_double_Sg__NestedInnerTemplate2_Sl_short_Sg_) { + return _swig_wrap_T_NestedOuterTemplateDouble_useNestedInnerTemplate2(arg1, arg2.Swigcptr()) +} + +var _wrap_T_NestedOuterTemplateDouble_useNestedInnerTemplate3 unsafe.Pointer + +func _swig_wrap_T_NestedOuterTemplateDouble_useNestedInnerTemplate3(base SwigcptrT_NestedOuterTemplateDouble, _ uintptr) (_ SwigcptrNs_OuterTemplate_Sl_double_Sg__NestedInnerTemplate3_Sl_short_Sg_) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_T_NestedOuterTemplateDouble_useNestedInnerTemplate3, _swig_p) + return +} + +func (arg1 SwigcptrT_NestedOuterTemplateDouble) UseNestedInnerTemplate3(arg2 Ns_OuterTemplate_Sl_double_Sg__NestedInnerTemplate3_Sl_short_Sg_) (_swig_ret Ns_OuterTemplate_Sl_double_Sg__NestedInnerTemplate3_Sl_short_Sg_) { + return _swig_wrap_T_NestedOuterTemplateDouble_useNestedInnerTemplate3(arg1, arg2.Swigcptr()) +} + +var _wrap_T_NestedOuterTemplateDouble_useNestedStruct unsafe.Pointer + +func _swig_wrap_T_NestedOuterTemplateDouble_useNestedStruct(base SwigcptrT_NestedOuterTemplateDouble, _ uintptr) (_ SwigcptrNestedStruct) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_T_NestedOuterTemplateDouble_useNestedStruct, _swig_p) + return +} + +func (arg1 SwigcptrT_NestedOuterTemplateDouble) UseNestedStruct(arg2 NestedStruct) (_swig_ret NestedStruct) { + return _swig_wrap_T_NestedOuterTemplateDouble_useNestedStruct(arg1, arg2.Swigcptr()) +} + +var _wrap_new_T_NestedOuterTemplateDouble unsafe.Pointer + +func _swig_wrap_new_T_NestedOuterTemplateDouble() (base SwigcptrT_NestedOuterTemplateDouble) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_T_NestedOuterTemplateDouble, _swig_p) + return +} + +func NewT_NestedOuterTemplateDouble() (_swig_ret T_NestedOuterTemplateDouble) { + return _swig_wrap_new_T_NestedOuterTemplateDouble() +} + +var _wrap_delete_T_NestedOuterTemplateDouble unsafe.Pointer + +func _swig_wrap_delete_T_NestedOuterTemplateDouble(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_T_NestedOuterTemplateDouble, _swig_p) + return +} + +func DeleteT_NestedOuterTemplateDouble(arg1 T_NestedOuterTemplateDouble) { + _swig_wrap_delete_T_NestedOuterTemplateDouble(arg1.Swigcptr()) +} + +type T_NestedOuterTemplateDouble interface { + Swigcptr() uintptr + SwigIsT_NestedOuterTemplateDouble() + Hohum(arg2 float64) (_swig_ret float64) + UseNestedInnerTemplate1(arg2 Ns_OuterTemplate_Sl_double_Sg__NestedInnerTemplate1_Sl_short_Sg_) (_swig_ret Ns_OuterTemplate_Sl_double_Sg__NestedInnerTemplate1_Sl_short_Sg_) + UseNestedInnerTemplate2(arg2 Ns_OuterTemplate_Sl_double_Sg__NestedInnerTemplate2_Sl_short_Sg_) (_swig_ret Ns_OuterTemplate_Sl_double_Sg__NestedInnerTemplate2_Sl_short_Sg_) + UseNestedInnerTemplate3(arg2 Ns_OuterTemplate_Sl_double_Sg__NestedInnerTemplate3_Sl_short_Sg_) (_swig_ret Ns_OuterTemplate_Sl_double_Sg__NestedInnerTemplate3_Sl_short_Sg_) + UseNestedStruct(arg2 NestedStruct) (_swig_ret NestedStruct) +} + +type SwigcptrNestedStruct uintptr + +func (p SwigcptrNestedStruct) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrNestedStruct) SwigIsNestedStruct() { +} + +var _wrap_new_NestedStruct unsafe.Pointer + +func _swig_wrap_new_NestedStruct() (base SwigcptrNestedStruct) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_NestedStruct, _swig_p) + return +} + +func NewNestedStruct() (_swig_ret NestedStruct) { + return _swig_wrap_new_NestedStruct() +} + +var _wrap_NestedStruct_hohum unsafe.Pointer + +func _swig_wrap_NestedStruct_hohum(base SwigcptrNestedStruct) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_NestedStruct_hohum, _swig_p) + return +} + +func (arg1 SwigcptrNestedStruct) Hohum() { + _swig_wrap_NestedStruct_hohum(arg1) +} + +var _wrap_delete_NestedStruct unsafe.Pointer + +func _swig_wrap_delete_NestedStruct(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_NestedStruct, _swig_p) + return +} + +func DeleteNestedStruct(arg1 NestedStruct) { + _swig_wrap_delete_NestedStruct(arg1.Swigcptr()) +} + +type NestedStruct interface { + Swigcptr() uintptr + SwigIsNestedStruct() + Hohum() +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + +type SwigcptrNs_OuterTemplate_Sl_double_Sg__NestedInnerTemplate3_Sl_short_Sg_ uintptr +type Ns_OuterTemplate_Sl_double_Sg__NestedInnerTemplate3_Sl_short_Sg_ interface { + Swigcptr() uintptr; +} +func (p SwigcptrNs_OuterTemplate_Sl_double_Sg__NestedInnerTemplate3_Sl_short_Sg_) Swigcptr() uintptr { + return uintptr(p) +} + +type SwigcptrNs_OuterTemplate_Sl_double_Sg__NestedInnerTemplate2_Sl_short_Sg_ uintptr +type Ns_OuterTemplate_Sl_double_Sg__NestedInnerTemplate2_Sl_short_Sg_ interface { + Swigcptr() uintptr; +} +func (p SwigcptrNs_OuterTemplate_Sl_double_Sg__NestedInnerTemplate2_Sl_short_Sg_) Swigcptr() uintptr { + return uintptr(p) +} + +type SwigcptrNs_OuterTemplate_Sl_double_Sg__NestedInnerTemplate1_Sl_short_Sg_ uintptr +type Ns_OuterTemplate_Sl_double_Sg__NestedInnerTemplate1_Sl_short_Sg_ interface { + Swigcptr() uintptr; +} +func (p SwigcptrNs_OuterTemplate_Sl_double_Sg__NestedInnerTemplate1_Sl_short_Sg_) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/template_nested_typemaps.go b/Examples/test-suite/go/template_nested_typemaps.go new file mode 100644 index 000000000..4b6ee25fb --- /dev/null +++ b/Examples/test-suite/go/template_nested_typemaps.go @@ -0,0 +1,182 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../template_nested_typemaps.i + +package template_nested_typemaps + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +var _wrap_globalInt1 unsafe.Pointer + +func GlobalInt1(arg1 int) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_globalInt1, _swig_p) + return +} +var _wrap_globalShort1 unsafe.Pointer + +func GlobalShort1(arg1 int16) (_swig_ret int16) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_globalShort1, _swig_p) + return +} +var _wrap_globalInt2 unsafe.Pointer + +func GlobalInt2(arg1 int) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_globalInt2, _swig_p) + return +} +var _wrap_globalShort2 unsafe.Pointer + +func GlobalShort2(arg1 int16) (_swig_ret int16) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_globalShort2, _swig_p) + return +} +type SwigcptrBreezeString uintptr + +func (p SwigcptrBreezeString) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrBreezeString) SwigIsBreezeString() { +} + +var _wrap_BreezeString_methodInt1 unsafe.Pointer + +func _swig_wrap_BreezeString_methodInt1(base SwigcptrBreezeString, _ int) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_BreezeString_methodInt1, _swig_p) + return +} + +func (arg1 SwigcptrBreezeString) MethodInt1(arg2 int) (_swig_ret int) { + return _swig_wrap_BreezeString_methodInt1(arg1, arg2) +} + +var _wrap_BreezeString_methodInt2 unsafe.Pointer + +func _swig_wrap_BreezeString_methodInt2(base SwigcptrBreezeString, _ int) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_BreezeString_methodInt2, _swig_p) + return +} + +func (arg1 SwigcptrBreezeString) MethodInt2(arg2 int) (_swig_ret int) { + return _swig_wrap_BreezeString_methodInt2(arg1, arg2) +} + +var _wrap_BreezeString_takeIt unsafe.Pointer + +func _swig_wrap_BreezeString_takeIt(base SwigcptrBreezeString, _ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_BreezeString_takeIt, _swig_p) + return +} + +func (arg1 SwigcptrBreezeString) TakeIt(arg2 string) { + _swig_wrap_BreezeString_takeIt(arg1, arg2) +} + +var _wrap_BreezeString_methodShort1 unsafe.Pointer + +func _swig_wrap_BreezeString_methodShort1(base SwigcptrBreezeString, _ int16) (_ int16) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_BreezeString_methodShort1, _swig_p) + return +} + +func (arg1 SwigcptrBreezeString) MethodShort1(arg2 int16) (_swig_ret int16) { + return _swig_wrap_BreezeString_methodShort1(arg1, arg2) +} + +var _wrap_BreezeString_methodShort2 unsafe.Pointer + +func _swig_wrap_BreezeString_methodShort2(base SwigcptrBreezeString, _ int16) (_ int16) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_BreezeString_methodShort2, _swig_p) + return +} + +func (arg1 SwigcptrBreezeString) MethodShort2(arg2 int16) (_swig_ret int16) { + return _swig_wrap_BreezeString_methodShort2(arg1, arg2) +} + +var _wrap_new_BreezeString unsafe.Pointer + +func _swig_wrap_new_BreezeString() (base SwigcptrBreezeString) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_BreezeString, _swig_p) + return +} + +func NewBreezeString() (_swig_ret BreezeString) { + return _swig_wrap_new_BreezeString() +} + +var _wrap_delete_BreezeString unsafe.Pointer + +func _swig_wrap_delete_BreezeString(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_BreezeString, _swig_p) + return +} + +func DeleteBreezeString(arg1 BreezeString) { + _swig_wrap_delete_BreezeString(arg1.Swigcptr()) +} + +type BreezeString interface { + Swigcptr() uintptr + SwigIsBreezeString() + MethodInt1(arg2 int) (_swig_ret int) + MethodInt2(arg2 int) (_swig_ret int) + TakeIt(arg2 string) + MethodShort1(arg2 int16) (_swig_ret int16) + MethodShort2(arg2 int16) (_swig_ret int16) +} + +var _wrap_globalInt3 unsafe.Pointer + +func GlobalInt3(arg1 int) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_globalInt3, _swig_p) + return +} +var _wrap_globalShort3 unsafe.Pointer + +func GlobalShort3(arg1 int16) (_swig_ret int16) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_globalShort3, _swig_p) + return +} + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/template_ns.go b/Examples/test-suite/go/template_ns.go new file mode 100644 index 000000000..d4b268d58 --- /dev/null +++ b/Examples/test-suite/go/template_ns.go @@ -0,0 +1,263 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../template_ns.i + +package template_ns + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrPairii uintptr + +func (p SwigcptrPairii) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrPairii) SwigIsPairii() { +} + +var _wrap_pairii_first_set unsafe.Pointer + +func _swig_wrap_pairii_first_set(base SwigcptrPairii, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_pairii_first_set, _swig_p) + return +} + +func (arg1 SwigcptrPairii) SetFirst(arg2 int) { + _swig_wrap_pairii_first_set(arg1, arg2) +} + +var _wrap_pairii_first_get unsafe.Pointer + +func _swig_wrap_pairii_first_get(base SwigcptrPairii) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_pairii_first_get, _swig_p) + return +} + +func (arg1 SwigcptrPairii) GetFirst() (_swig_ret int) { + return _swig_wrap_pairii_first_get(arg1) +} + +var _wrap_pairii_second_set unsafe.Pointer + +func _swig_wrap_pairii_second_set(base SwigcptrPairii, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_pairii_second_set, _swig_p) + return +} + +func (arg1 SwigcptrPairii) SetSecond(arg2 int) { + _swig_wrap_pairii_second_set(arg1, arg2) +} + +var _wrap_pairii_second_get unsafe.Pointer + +func _swig_wrap_pairii_second_get(base SwigcptrPairii) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_pairii_second_get, _swig_p) + return +} + +func (arg1 SwigcptrPairii) GetSecond() (_swig_ret int) { + return _swig_wrap_pairii_second_get(arg1) +} + +var _wrap_new_pairii__SWIG_0 unsafe.Pointer + +func _swig_wrap_new_pairii__SWIG_0(base int, _ int) (_ SwigcptrPairii) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_pairii__SWIG_0, _swig_p) + return +} + +func NewPairii__SWIG_0(arg1 int, arg2 int) (_swig_ret Pairii) { + return _swig_wrap_new_pairii__SWIG_0(arg1, arg2) +} + +var _wrap_new_pairii__SWIG_1 unsafe.Pointer + +func _swig_wrap_new_pairii__SWIG_1(base uintptr) (_ SwigcptrPairii) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_pairii__SWIG_1, _swig_p) + return +} + +func NewPairii__SWIG_1(arg1 Pairii) (_swig_ret Pairii) { + return _swig_wrap_new_pairii__SWIG_1(arg1.Swigcptr()) +} + +func NewPairii(a ...interface{}) Pairii { + argc := len(a) + if argc == 1 { + return NewPairii__SWIG_1(a[0].(Pairii)) + } + if argc == 2 { + return NewPairii__SWIG_0(a[0].(int), a[1].(int)) + } + panic("No match for overloaded function call") +} + +var _wrap_delete_pairii unsafe.Pointer + +func _swig_wrap_delete_pairii(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_pairii, _swig_p) + return +} + +func DeletePairii(arg1 Pairii) { + _swig_wrap_delete_pairii(arg1.Swigcptr()) +} + +type Pairii interface { + Swigcptr() uintptr + SwigIsPairii() + SetFirst(arg2 int) + GetFirst() (_swig_ret int) + SetSecond(arg2 int) + GetSecond() (_swig_ret int) +} + +type SwigcptrPairdd uintptr + +func (p SwigcptrPairdd) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrPairdd) SwigIsPairdd() { +} + +var _wrap_pairdd_first_set unsafe.Pointer + +func _swig_wrap_pairdd_first_set(base SwigcptrPairdd, _ float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_pairdd_first_set, _swig_p) + return +} + +func (arg1 SwigcptrPairdd) SetFirst(arg2 float64) { + _swig_wrap_pairdd_first_set(arg1, arg2) +} + +var _wrap_pairdd_first_get unsafe.Pointer + +func _swig_wrap_pairdd_first_get(base SwigcptrPairdd) (_ float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_pairdd_first_get, _swig_p) + return +} + +func (arg1 SwigcptrPairdd) GetFirst() (_swig_ret float64) { + return _swig_wrap_pairdd_first_get(arg1) +} + +var _wrap_pairdd_second_set unsafe.Pointer + +func _swig_wrap_pairdd_second_set(base SwigcptrPairdd, _ float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_pairdd_second_set, _swig_p) + return +} + +func (arg1 SwigcptrPairdd) SetSecond(arg2 float64) { + _swig_wrap_pairdd_second_set(arg1, arg2) +} + +var _wrap_pairdd_second_get unsafe.Pointer + +func _swig_wrap_pairdd_second_get(base SwigcptrPairdd) (_ float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_pairdd_second_get, _swig_p) + return +} + +func (arg1 SwigcptrPairdd) GetSecond() (_swig_ret float64) { + return _swig_wrap_pairdd_second_get(arg1) +} + +var _wrap_new_pairdd__SWIG_0 unsafe.Pointer + +func _swig_wrap_new_pairdd__SWIG_0(base float64, _ float64) (_ SwigcptrPairdd) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_pairdd__SWIG_0, _swig_p) + return +} + +func NewPairdd__SWIG_0(arg1 float64, arg2 float64) (_swig_ret Pairdd) { + return _swig_wrap_new_pairdd__SWIG_0(arg1, arg2) +} + +var _wrap_new_pairdd__SWIG_1 unsafe.Pointer + +func _swig_wrap_new_pairdd__SWIG_1(base uintptr) (_ SwigcptrPairdd) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_pairdd__SWIG_1, _swig_p) + return +} + +func NewPairdd__SWIG_1(arg1 Pairdd) (_swig_ret Pairdd) { + return _swig_wrap_new_pairdd__SWIG_1(arg1.Swigcptr()) +} + +func NewPairdd(a ...interface{}) Pairdd { + argc := len(a) + if argc == 1 { + return NewPairdd__SWIG_1(a[0].(Pairdd)) + } + if argc == 2 { + return NewPairdd__SWIG_0(a[0].(float64), a[1].(float64)) + } + panic("No match for overloaded function call") +} + +var _wrap_delete_pairdd unsafe.Pointer + +func _swig_wrap_delete_pairdd(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_pairdd, _swig_p) + return +} + +func DeletePairdd(arg1 Pairdd) { + _swig_wrap_delete_pairdd(arg1.Swigcptr()) +} + +type Pairdd interface { + Swigcptr() uintptr + SwigIsPairdd() + SetFirst(arg2 float64) + GetFirst() (_swig_ret float64) + SetSecond(arg2 float64) + GetSecond() (_swig_ret float64) +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/template_ns2.go b/Examples/test-suite/go/template_ns2.go new file mode 100644 index 000000000..6c592006d --- /dev/null +++ b/Examples/test-suite/go/template_ns2.go @@ -0,0 +1,69 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../template_ns2.i + +package template_ns2 + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +var _wrap_test1 unsafe.Pointer + +func _swig_wrap_test1(base uintptr) (_ SwigcptrFoo_bar_Sl_int_Sg_) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_test1, _swig_p) + return +} + +func Test1(arg1 Foo_bar_Sl_int_Sg_) (_swig_ret Foo_bar_Sl_int_Sg_) { + return _swig_wrap_test1(arg1.Swigcptr()) +} + +var _wrap_test2 unsafe.Pointer + +func _swig_wrap_test2(base uintptr) (_ SwigcptrFoo_bar_Sl_int_Sm__Sg_) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_test2, _swig_p) + return +} + +func Test2(arg1 Foo_bar_Sl_int_Sm__Sg_) (_swig_ret Foo_bar_Sl_int_Sm__Sg_) { + return _swig_wrap_test2(arg1.Swigcptr()) +} + + +type SwigcptrFoo_bar_Sl_int_Sm__Sg_ uintptr +type Foo_bar_Sl_int_Sm__Sg_ interface { + Swigcptr() uintptr; +} +func (p SwigcptrFoo_bar_Sl_int_Sm__Sg_) Swigcptr() uintptr { + return uintptr(p) +} + +type SwigcptrFoo_bar_Sl_int_Sg_ uintptr +type Foo_bar_Sl_int_Sg_ interface { + Swigcptr() uintptr; +} +func (p SwigcptrFoo_bar_Sl_int_Sg_) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/template_ns3.go b/Examples/test-suite/go/template_ns3.go new file mode 100644 index 000000000..41844f4db --- /dev/null +++ b/Examples/test-suite/go/template_ns3.go @@ -0,0 +1,88 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../template_ns3.i + +package template_ns3 + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrBari uintptr + +func (p SwigcptrBari) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrBari) SwigIsBari() { +} + +var _wrap_bari_test unsafe.Pointer + +func _swig_wrap_bari_test(base SwigcptrBari, _ int) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_bari_test, _swig_p) + return +} + +func (arg1 SwigcptrBari) Test(arg2 int) (_swig_ret int) { + return _swig_wrap_bari_test(arg1, arg2) +} + +var _wrap_new_bari unsafe.Pointer + +func _swig_wrap_new_bari() (base SwigcptrBari) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_bari, _swig_p) + return +} + +func NewBari() (_swig_ret Bari) { + return _swig_wrap_new_bari() +} + +var _wrap_delete_bari unsafe.Pointer + +func _swig_wrap_delete_bari(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_bari, _swig_p) + return +} + +func DeleteBari(arg1 Bari) { + _swig_wrap_delete_bari(arg1.Swigcptr()) +} + +type Bari interface { + Swigcptr() uintptr + SwigIsBari() + Test(arg2 int) (_swig_ret int) +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/template_ns4.go b/Examples/test-suite/go/template_ns4.go new file mode 100644 index 000000000..e21230ff3 --- /dev/null +++ b/Examples/test-suite/go/template_ns4.go @@ -0,0 +1,267 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../template_ns4.i + +package template_ns4 + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrDouble uintptr + +func (p SwigcptrDouble) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrDouble) SwigIsDouble() { +} + +var _wrap_new_Double unsafe.Pointer + +func _swig_wrap_new_Double() (base SwigcptrDouble) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Double, _swig_p) + return +} + +func NewDouble() (_swig_ret Double) { + return _swig_wrap_new_Double() +} + +var _wrap_delete_Double unsafe.Pointer + +func _swig_wrap_delete_Double(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Double, _swig_p) + return +} + +func DeleteDouble(arg1 Double) { + _swig_wrap_delete_Double(arg1.Swigcptr()) +} + +type Double interface { + Swigcptr() uintptr + SwigIsDouble() +} + +type SwigcptrFunction_DD uintptr + +func (p SwigcptrFunction_DD) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrFunction_DD) SwigIsFunction_DD() { +} + +var _wrap_Function_DD_test unsafe.Pointer + +func _swig_wrap_Function_DD_test(base SwigcptrFunction_DD) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Function_DD_test, _swig_p) + return +} + +func (arg1 SwigcptrFunction_DD) Test() (_swig_ret string) { + return _swig_wrap_Function_DD_test(arg1) +} + +var _wrap_new_Function_DD unsafe.Pointer + +func _swig_wrap_new_Function_DD() (base SwigcptrFunction_DD) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Function_DD, _swig_p) + return +} + +func NewFunction_DD() (_swig_ret Function_DD) { + return _swig_wrap_new_Function_DD() +} + +var _wrap_delete_Function_DD unsafe.Pointer + +func _swig_wrap_delete_Function_DD(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Function_DD, _swig_p) + return +} + +func DeleteFunction_DD(arg1 Function_DD) { + _swig_wrap_delete_Function_DD(arg1.Swigcptr()) +} + +type Function_DD interface { + Swigcptr() uintptr + SwigIsFunction_DD() + Test() (_swig_ret string) +} + +type SwigcptrArithFunction_DD uintptr + +func (p SwigcptrArithFunction_DD) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrArithFunction_DD) SwigIsArithFunction_DD() { +} + +var _wrap_new_ArithFunction_DD unsafe.Pointer + +func _swig_wrap_new_ArithFunction_DD() (base SwigcptrArithFunction_DD) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_ArithFunction_DD, _swig_p) + return +} + +func NewArithFunction_DD() (_swig_ret ArithFunction_DD) { + return _swig_wrap_new_ArithFunction_DD() +} + +var _wrap_delete_ArithFunction_DD unsafe.Pointer + +func _swig_wrap_delete_ArithFunction_DD(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_ArithFunction_DD, _swig_p) + return +} + +func DeleteArithFunction_DD(arg1 ArithFunction_DD) { + _swig_wrap_delete_ArithFunction_DD(arg1.Swigcptr()) +} + +var _wrap_ArithFunction_DD_test unsafe.Pointer + +func _swig_wrap_ArithFunction_DD_test(base SwigcptrArithFunction_DD) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_ArithFunction_DD_test, _swig_p) + return +} + +func (_swig_base SwigcptrArithFunction_DD) Test() (_swig_ret string) { + return _swig_wrap_ArithFunction_DD_test(_swig_base) +} + +func (p SwigcptrArithFunction_DD) SwigIsFunction_DD() { +} + +func (p SwigcptrArithFunction_DD) SwigGetFunction_DD() Function_DD { + return SwigcptrFunction_DD(p.Swigcptr()) +} + +type ArithFunction_DD interface { + Swigcptr() uintptr + SwigIsArithFunction_DD() + Test() (_swig_ret string) + SwigIsFunction_DD() + SwigGetFunction_DD() Function_DD +} + +type SwigcptrClass_DD uintptr + +func (p SwigcptrClass_DD) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrClass_DD) SwigIsClass_DD() { +} + +var _wrap_new_Class_DD unsafe.Pointer + +func _swig_wrap_new_Class_DD() (base SwigcptrClass_DD) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Class_DD, _swig_p) + return +} + +func NewClass_DD() (_swig_ret Class_DD) { + return _swig_wrap_new_Class_DD() +} + +var _wrap_delete_Class_DD unsafe.Pointer + +func _swig_wrap_delete_Class_DD(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Class_DD, _swig_p) + return +} + +func DeleteClass_DD(arg1 Class_DD) { + _swig_wrap_delete_Class_DD(arg1.Swigcptr()) +} + +var _wrap_Class_DD_test unsafe.Pointer + +func _swig_wrap_Class_DD_test(base SwigcptrClass_DD) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Class_DD_test, _swig_p) + return +} + +func (_swig_base SwigcptrClass_DD) Test() (_swig_ret string) { + return _swig_wrap_Class_DD_test(_swig_base) +} + +func (p SwigcptrClass_DD) SwigIsArithFunction_DD() { +} + +func (p SwigcptrClass_DD) SwigGetArithFunction_DD() ArithFunction_DD { + return SwigcptrArithFunction_DD(p.Swigcptr()) +} + +func (p SwigcptrClass_DD) SwigIsFunction_DD() { +} + +func (p SwigcptrClass_DD) SwigGetFunction_DD() Function_DD { + return SwigcptrFunction_DD(p.Swigcptr()) +} + +type Class_DD interface { + Swigcptr() uintptr + SwigIsClass_DD() + Test() (_swig_ret string) + SwigIsArithFunction_DD() + SwigGetArithFunction_DD() ArithFunction_DD + SwigIsFunction_DD() + SwigGetFunction_DD() Function_DD +} + +var _wrap_make_Class_DD unsafe.Pointer + +func _swig_wrap_make_Class_DD() (base SwigcptrArithFunction_DD) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_make_Class_DD, _swig_p) + return +} + +func Make_Class_DD() (_swig_ret ArithFunction_DD) { + return _swig_wrap_make_Class_DD() +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/template_ns4_runme b/Examples/test-suite/go/template_ns4_runme new file mode 100755 index 000000000..a6829a6d0 Binary files /dev/null and b/Examples/test-suite/go/template_ns4_runme differ diff --git a/Examples/test-suite/go/template_ns_enum.go b/Examples/test-suite/go/template_ns_enum.go new file mode 100644 index 000000000..5d5eac73f --- /dev/null +++ b/Examples/test-suite/go/template_ns_enum.go @@ -0,0 +1,66 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../template_ns_enum.i + +package template_ns_enum + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type HelloHello int +var _wrap_Hi unsafe.Pointer + +func _swig_getHi() (_swig_ret HelloHello) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_Hi, _swig_p) + return +} +var Hi HelloHello = _swig_getHi() +var _wrap_Hola unsafe.Pointer + +func _swig_getHola() (_swig_ret HelloHello) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_Hola, _swig_p) + return +} +var Hola HelloHello = _swig_getHola() +var _wrap_say_hi unsafe.Pointer + +func _swig_wrap_say_hi() (base SwigcptrHello_traits_Sl_hello_Hi_Sg__value_type) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_say_hi, _swig_p) + return +} + +func Say_hi() (_swig_ret Hello_traits_Sl_hello_Hi_Sg__value_type) { + return _swig_wrap_say_hi() +} + + +type SwigcptrHello_traits_Sl_hello_Hi_Sg__value_type uintptr +type Hello_traits_Sl_hello_Hi_Sg__value_type interface { + Swigcptr() uintptr; +} +func (p SwigcptrHello_traits_Sl_hello_Hi_Sg__value_type) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/template_ns_enum2.go b/Examples/test-suite/go/template_ns_enum2.go new file mode 100644 index 000000000..c82e3e771 --- /dev/null +++ b/Examples/test-suite/go/template_ns_enum2.go @@ -0,0 +1,113 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../template_ns_enum2.i + +package template_ns_enum2 + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type HiHello int +var _wrap_Hi unsafe.Pointer + +func _swig_getHi() (_swig_ret HiHello) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_Hi, _swig_p) + return +} +var Hi HiHello = _swig_getHi() +var _wrap_Hola unsafe.Pointer + +func _swig_getHola() (_swig_ret HiHello) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_Hola, _swig_p) + return +} +var Hola HiHello = _swig_getHola() +type SwigcptrB uintptr + +func (p SwigcptrB) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrB) SwigIsB() { +} + +var _wrap_B_evaluate unsafe.Pointer + +func _swig_wrap_B_evaluate(base SwigcptrB, _ uintptr) (_ SwigcptrHi_traits_Sl_hi_Hola_Sg__value_type) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_B_evaluate, _swig_p) + return +} + +func (arg1 SwigcptrB) Evaluate(arg2 Hi_traits_Sl_hi_Hola_Sg__value_type) (_swig_ret Hi_traits_Sl_hi_Hola_Sg__value_type) { + return _swig_wrap_B_evaluate(arg1, arg2.Swigcptr()) +} + +var _wrap_new_B unsafe.Pointer + +func _swig_wrap_new_B() (base SwigcptrB) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_B, _swig_p) + return +} + +func NewB() (_swig_ret B) { + return _swig_wrap_new_B() +} + +var _wrap_delete_B unsafe.Pointer + +func _swig_wrap_delete_B(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_B, _swig_p) + return +} + +func DeleteB(arg1 B) { + _swig_wrap_delete_B(arg1.Swigcptr()) +} + +type B interface { + Swigcptr() uintptr + SwigIsB() + Evaluate(arg2 Hi_traits_Sl_hi_Hola_Sg__value_type) (_swig_ret Hi_traits_Sl_hi_Hola_Sg__value_type) +} + + +type SwigcptrHi_traits_Sl_hi_Hola_Sg__value_type uintptr +type Hi_traits_Sl_hi_Hola_Sg__value_type interface { + Swigcptr() uintptr; +} +func (p SwigcptrHi_traits_Sl_hi_Hola_Sg__value_type) Swigcptr() uintptr { + return uintptr(p) +} + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/template_ns_inherit.go b/Examples/test-suite/go/template_ns_inherit.go new file mode 100644 index 000000000..219432a15 --- /dev/null +++ b/Examples/test-suite/go/template_ns_inherit.go @@ -0,0 +1,122 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../template_ns_inherit.i + +package template_ns_inherit + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrVUnaryFunction_id uintptr + +func (p SwigcptrVUnaryFunction_id) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrVUnaryFunction_id) SwigIsVUnaryFunction_id() { +} + +var _wrap_new_VUnaryFunction_id unsafe.Pointer + +func _swig_wrap_new_VUnaryFunction_id() (base SwigcptrVUnaryFunction_id) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_VUnaryFunction_id, _swig_p) + return +} + +func NewVUnaryFunction_id() (_swig_ret VUnaryFunction_id) { + return _swig_wrap_new_VUnaryFunction_id() +} + +var _wrap_delete_VUnaryFunction_id unsafe.Pointer + +func _swig_wrap_delete_VUnaryFunction_id(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_VUnaryFunction_id, _swig_p) + return +} + +func DeleteVUnaryFunction_id(arg1 VUnaryFunction_id) { + _swig_wrap_delete_VUnaryFunction_id(arg1.Swigcptr()) +} + +type VUnaryFunction_id interface { + Swigcptr() uintptr + SwigIsVUnaryFunction_id() +} + +type SwigcptrUnaryFunction_id uintptr + +func (p SwigcptrUnaryFunction_id) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrUnaryFunction_id) SwigIsUnaryFunction_id() { +} + +var _wrap_new_UnaryFunction_id unsafe.Pointer + +func _swig_wrap_new_UnaryFunction_id() (base SwigcptrUnaryFunction_id) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_UnaryFunction_id, _swig_p) + return +} + +func NewUnaryFunction_id() (_swig_ret UnaryFunction_id) { + return _swig_wrap_new_UnaryFunction_id() +} + +var _wrap_delete_UnaryFunction_id unsafe.Pointer + +func _swig_wrap_delete_UnaryFunction_id(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_UnaryFunction_id, _swig_p) + return +} + +func DeleteUnaryFunction_id(arg1 UnaryFunction_id) { + _swig_wrap_delete_UnaryFunction_id(arg1.Swigcptr()) +} + +func (p SwigcptrUnaryFunction_id) SwigIsVUnaryFunction_id() { +} + +func (p SwigcptrUnaryFunction_id) SwigGetVUnaryFunction_id() VUnaryFunction_id { + return SwigcptrVUnaryFunction_id(p.Swigcptr()) +} + +type UnaryFunction_id interface { + Swigcptr() uintptr + SwigIsUnaryFunction_id() + SwigIsVUnaryFunction_id() + SwigGetVUnaryFunction_id() VUnaryFunction_id +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/template_ns_runme b/Examples/test-suite/go/template_ns_runme new file mode 100755 index 000000000..03b5d5494 Binary files /dev/null and b/Examples/test-suite/go/template_ns_runme differ diff --git a/Examples/test-suite/go/template_ns_scope.go b/Examples/test-suite/go/template_ns_scope.go new file mode 100644 index 000000000..17ad559f8 --- /dev/null +++ b/Examples/test-suite/go/template_ns_scope.go @@ -0,0 +1,152 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../template_ns_scope.i + +package template_ns_scope + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type HiHello int +var _wrap_Hi unsafe.Pointer + +func _swig_getHi() (_swig_ret HiHello) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_Hi, _swig_p) + return +} +var Hi HiHello = _swig_getHi() +var _wrap_Hola unsafe.Pointer + +func _swig_getHola() (_swig_ret HiHello) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_Hola, _swig_p) + return +} +var Hola HiHello = _swig_getHola() +type SwigcptrA_Hi uintptr + +func (p SwigcptrA_Hi) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrA_Hi) SwigIsA_Hi() { +} + +var _wrap_new_A_Hi unsafe.Pointer + +func _swig_wrap_new_A_Hi() (base SwigcptrA_Hi) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_A_Hi, _swig_p) + return +} + +func NewA_Hi() (_swig_ret A_Hi) { + return _swig_wrap_new_A_Hi() +} + +var _wrap_delete_A_Hi unsafe.Pointer + +func _swig_wrap_delete_A_Hi(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_A_Hi, _swig_p) + return +} + +func DeleteA_Hi(arg1 A_Hi) { + _swig_wrap_delete_A_Hi(arg1.Swigcptr()) +} + +type A_Hi interface { + Swigcptr() uintptr + SwigIsA_Hi() +} + +type SwigcptrB_Hi uintptr + +func (p SwigcptrB_Hi) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrB_Hi) SwigIsB_Hi() { +} + +var _wrap_B_Hi_say_hi unsafe.Pointer + +func _swig_wrap_B_Hi_say_hi(base SwigcptrB_Hi) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_B_Hi_say_hi, _swig_p) + return +} + +func (arg1 SwigcptrB_Hi) Say_hi() (_swig_ret int) { + return _swig_wrap_B_Hi_say_hi(arg1) +} + +var _wrap_new_B_Hi unsafe.Pointer + +func _swig_wrap_new_B_Hi() (base SwigcptrB_Hi) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_B_Hi, _swig_p) + return +} + +func NewB_Hi() (_swig_ret B_Hi) { + return _swig_wrap_new_B_Hi() +} + +var _wrap_delete_B_Hi unsafe.Pointer + +func _swig_wrap_delete_B_Hi(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_B_Hi, _swig_p) + return +} + +func DeleteB_Hi(arg1 B_Hi) { + _swig_wrap_delete_B_Hi(arg1.Swigcptr()) +} + +func (p SwigcptrB_Hi) SwigIsA_Hi() { +} + +func (p SwigcptrB_Hi) SwigGetA_Hi() A_Hi { + return SwigcptrA_Hi(p.Swigcptr()) +} + +type B_Hi interface { + Swigcptr() uintptr + SwigIsB_Hi() + Say_hi() (_swig_ret int) + SwigIsA_Hi() + SwigGetA_Hi() A_Hi +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/template_opaque.go b/Examples/test-suite/go/template_opaque.go new file mode 100644 index 000000000..c69b80297 --- /dev/null +++ b/Examples/test-suite/go/template_opaque.go @@ -0,0 +1,259 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../template_opaque.i + +package template_opaque + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +var _wrap_FillVector__SWIG_0 unsafe.Pointer + +func _swig_wrap_FillVector__SWIG_0(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_FillVector__SWIG_0, _swig_p) + return +} + +func FillVector__SWIG_0(arg1 OpaqueVectorType) { + _swig_wrap_FillVector__SWIG_0(arg1.Swigcptr()) +} + +var _wrap_FillVector__SWIG_1 unsafe.Pointer + +func _swig_wrap_FillVector__SWIG_1(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_FillVector__SWIG_1, _swig_p) + return +} + +func FillVector__SWIG_1(arg1 Std_vector_Sl_enum_SS_Hello_Sg_) { + _swig_wrap_FillVector__SWIG_1(arg1.Swigcptr()) +} + +func FillVector(a ...interface{}) { + argc := len(a) + if argc == 1 { + if _, ok := a[0].(OpaqueVectorType); !ok { + goto check_1 + } + FillVector__SWIG_0(a[0].(OpaqueVectorType)) + return + } +check_1: + if argc == 1 { + FillVector__SWIG_1(a[0].(Std_vector_Sl_enum_SS_Hello_Sg_)) + return + } + panic("No match for overloaded function call") +} + +type SwigcptrOpaqueVectorType uintptr + +func (p SwigcptrOpaqueVectorType) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrOpaqueVectorType) SwigIsOpaqueVectorType() { +} + +var _wrap_new_OpaqueVectorType__SWIG_0 unsafe.Pointer + +func _swig_wrap_new_OpaqueVectorType__SWIG_0() (base SwigcptrOpaqueVectorType) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_OpaqueVectorType__SWIG_0, _swig_p) + return +} + +func NewOpaqueVectorType__SWIG_0() (_swig_ret OpaqueVectorType) { + return _swig_wrap_new_OpaqueVectorType__SWIG_0() +} + +var _wrap_new_OpaqueVectorType__SWIG_1 unsafe.Pointer + +func _swig_wrap_new_OpaqueVectorType__SWIG_1(base int64) (_ SwigcptrOpaqueVectorType) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_OpaqueVectorType__SWIG_1, _swig_p) + return +} + +func NewOpaqueVectorType__SWIG_1(arg1 int64) (_swig_ret OpaqueVectorType) { + return _swig_wrap_new_OpaqueVectorType__SWIG_1(arg1) +} + +func NewOpaqueVectorType(a ...interface{}) OpaqueVectorType { + argc := len(a) + if argc == 0 { + return NewOpaqueVectorType__SWIG_0() + } + if argc == 1 { + return NewOpaqueVectorType__SWIG_1(a[0].(int64)) + } + panic("No match for overloaded function call") +} + +var _wrap_OpaqueVectorType_size unsafe.Pointer + +func _swig_wrap_OpaqueVectorType_size(base SwigcptrOpaqueVectorType) (_ int64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_OpaqueVectorType_size, _swig_p) + return +} + +func (arg1 SwigcptrOpaqueVectorType) Size() (_swig_ret int64) { + return _swig_wrap_OpaqueVectorType_size(arg1) +} + +var _wrap_OpaqueVectorType_capacity unsafe.Pointer + +func _swig_wrap_OpaqueVectorType_capacity(base SwigcptrOpaqueVectorType) (_ int64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_OpaqueVectorType_capacity, _swig_p) + return +} + +func (arg1 SwigcptrOpaqueVectorType) Capacity() (_swig_ret int64) { + return _swig_wrap_OpaqueVectorType_capacity(arg1) +} + +var _wrap_OpaqueVectorType_reserve unsafe.Pointer + +func _swig_wrap_OpaqueVectorType_reserve(base SwigcptrOpaqueVectorType, _ int64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_OpaqueVectorType_reserve, _swig_p) + return +} + +func (arg1 SwigcptrOpaqueVectorType) Reserve(arg2 int64) { + _swig_wrap_OpaqueVectorType_reserve(arg1, arg2) +} + +var _wrap_OpaqueVectorType_isEmpty unsafe.Pointer + +func _swig_wrap_OpaqueVectorType_isEmpty(base SwigcptrOpaqueVectorType) (_ bool) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_OpaqueVectorType_isEmpty, _swig_p) + return +} + +func (arg1 SwigcptrOpaqueVectorType) IsEmpty() (_swig_ret bool) { + return _swig_wrap_OpaqueVectorType_isEmpty(arg1) +} + +var _wrap_OpaqueVectorType_clear unsafe.Pointer + +func _swig_wrap_OpaqueVectorType_clear(base SwigcptrOpaqueVectorType) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_OpaqueVectorType_clear, _swig_p) + return +} + +func (arg1 SwigcptrOpaqueVectorType) Clear() { + _swig_wrap_OpaqueVectorType_clear(arg1) +} + +var _wrap_OpaqueVectorType_add unsafe.Pointer + +func _swig_wrap_OpaqueVectorType_add(base SwigcptrOpaqueVectorType, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_OpaqueVectorType_add, _swig_p) + return +} + +func (arg1 SwigcptrOpaqueVectorType) Add(arg2 A_OpaqueStruct) { + _swig_wrap_OpaqueVectorType_add(arg1, arg2.Swigcptr()) +} + +var _wrap_OpaqueVectorType_get unsafe.Pointer + +func _swig_wrap_OpaqueVectorType_get(base SwigcptrOpaqueVectorType, _ int) (_ SwigcptrA_OpaqueStruct) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_OpaqueVectorType_get, _swig_p) + return +} + +func (arg1 SwigcptrOpaqueVectorType) Get(arg2 int) (_swig_ret A_OpaqueStruct) { + return _swig_wrap_OpaqueVectorType_get(arg1, arg2) +} + +var _wrap_OpaqueVectorType_set unsafe.Pointer + +func _swig_wrap_OpaqueVectorType_set(base SwigcptrOpaqueVectorType, _ int, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_OpaqueVectorType_set, _swig_p) + return +} + +func (arg1 SwigcptrOpaqueVectorType) Set(arg2 int, arg3 A_OpaqueStruct) { + _swig_wrap_OpaqueVectorType_set(arg1, arg2, arg3.Swigcptr()) +} + +var _wrap_delete_OpaqueVectorType unsafe.Pointer + +func _swig_wrap_delete_OpaqueVectorType(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_OpaqueVectorType, _swig_p) + return +} + +func DeleteOpaqueVectorType(arg1 OpaqueVectorType) { + _swig_wrap_delete_OpaqueVectorType(arg1.Swigcptr()) +} + +type OpaqueVectorType interface { + Swigcptr() uintptr + SwigIsOpaqueVectorType() + Size() (_swig_ret int64) + Capacity() (_swig_ret int64) + Reserve(arg2 int64) + IsEmpty() (_swig_ret bool) + Clear() + Add(arg2 A_OpaqueStruct) + Get(arg2 int) (_swig_ret A_OpaqueStruct) + Set(arg2 int, arg3 A_OpaqueStruct) +} + + +type SwigcptrStd_vector_Sl_enum_SS_Hello_Sg_ uintptr +type Std_vector_Sl_enum_SS_Hello_Sg_ interface { + Swigcptr() uintptr; +} +func (p SwigcptrStd_vector_Sl_enum_SS_Hello_Sg_) Swigcptr() uintptr { + return uintptr(p) +} + +type SwigcptrA_OpaqueStruct uintptr +type A_OpaqueStruct interface { + Swigcptr() uintptr; +} +func (p SwigcptrA_OpaqueStruct) Swigcptr() uintptr { + return uintptr(p) +} + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/template_opaque_runme b/Examples/test-suite/go/template_opaque_runme new file mode 100755 index 000000000..d0d93f80b Binary files /dev/null and b/Examples/test-suite/go/template_opaque_runme differ diff --git a/Examples/test-suite/go/template_partial_arg.go b/Examples/test-suite/go/template_partial_arg.go new file mode 100644 index 000000000..2eb381b6c --- /dev/null +++ b/Examples/test-suite/go/template_partial_arg.go @@ -0,0 +1,203 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../template_partial_arg.i + +package template_partial_arg + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrBar uintptr + +func (p SwigcptrBar) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrBar) SwigIsBar() { +} + +var _wrap_new_Bar unsafe.Pointer + +func _swig_wrap_new_Bar() (base SwigcptrBar) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Bar, _swig_p) + return +} + +func NewBar() (_swig_ret Bar) { + return _swig_wrap_new_Bar() +} + +var _wrap_delete_Bar unsafe.Pointer + +func _swig_wrap_delete_Bar(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Bar, _swig_p) + return +} + +func DeleteBar(arg1 Bar) { + _swig_wrap_delete_Bar(arg1.Swigcptr()) +} + +type Bar interface { + Swigcptr() uintptr + SwigIsBar() +} + +type SwigcptrFoo1 uintptr + +func (p SwigcptrFoo1) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrFoo1) SwigIsFoo1() { +} + +var _wrap_Foo1_bar unsafe.Pointer + +func _swig_wrap_Foo1_bar(base SwigcptrFoo1) (_ SwigcptrBar) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo1_bar, _swig_p) + return +} + +func (arg1 SwigcptrFoo1) Bar() (_swig_ret Bar) { + return _swig_wrap_Foo1_bar(arg1) +} + +var _wrap_Foo1_baz unsafe.Pointer + +func _swig_wrap_Foo1_baz(base SwigcptrFoo1) (_ SwigcptrBar) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo1_baz, _swig_p) + return +} + +func (arg1 SwigcptrFoo1) Baz() (_swig_ret Bar) { + return _swig_wrap_Foo1_baz(arg1) +} + +var _wrap_new_Foo1 unsafe.Pointer + +func _swig_wrap_new_Foo1() (base SwigcptrFoo1) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Foo1, _swig_p) + return +} + +func NewFoo1() (_swig_ret Foo1) { + return _swig_wrap_new_Foo1() +} + +var _wrap_delete_Foo1 unsafe.Pointer + +func _swig_wrap_delete_Foo1(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Foo1, _swig_p) + return +} + +func DeleteFoo1(arg1 Foo1) { + _swig_wrap_delete_Foo1(arg1.Swigcptr()) +} + +type Foo1 interface { + Swigcptr() uintptr + SwigIsFoo1() + Bar() (_swig_ret Bar) + Baz() (_swig_ret Bar) +} + +type SwigcptrFoo2 uintptr + +func (p SwigcptrFoo2) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrFoo2) SwigIsFoo2() { +} + +var _wrap_Foo2_bar unsafe.Pointer + +func _swig_wrap_Foo2_bar(base SwigcptrFoo2) (_ SwigcptrBar) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo2_bar, _swig_p) + return +} + +func (arg1 SwigcptrFoo2) Bar() (_swig_ret Bar) { + return _swig_wrap_Foo2_bar(arg1) +} + +var _wrap_Foo2_baz unsafe.Pointer + +func _swig_wrap_Foo2_baz(base SwigcptrFoo2) (_ SwigcptrBar) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo2_baz, _swig_p) + return +} + +func (arg1 SwigcptrFoo2) Baz() (_swig_ret Bar) { + return _swig_wrap_Foo2_baz(arg1) +} + +var _wrap_new_Foo2 unsafe.Pointer + +func _swig_wrap_new_Foo2() (base SwigcptrFoo2) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Foo2, _swig_p) + return +} + +func NewFoo2() (_swig_ret Foo2) { + return _swig_wrap_new_Foo2() +} + +var _wrap_delete_Foo2 unsafe.Pointer + +func _swig_wrap_delete_Foo2(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Foo2, _swig_p) + return +} + +func DeleteFoo2(arg1 Foo2) { + _swig_wrap_delete_Foo2(arg1.Swigcptr()) +} + +type Foo2 interface { + Swigcptr() uintptr + SwigIsFoo2() + Bar() (_swig_ret Bar) + Baz() (_swig_ret Bar) +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/template_partial_specialization.go b/Examples/test-suite/go/template_partial_specialization.go new file mode 100644 index 000000000..71fa10017 --- /dev/null +++ b/Examples/test-suite/go/template_partial_specialization.go @@ -0,0 +1,1962 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../template_partial_specialization.i + +package template_partial_specialization + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrA uintptr + +func (p SwigcptrA) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrA) SwigIsA() { +} + +var _wrap_A_a unsafe.Pointer + +func _swig_wrap_A_a(base SwigcptrA) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_A_a, _swig_p) + return +} + +func (arg1 SwigcptrA) A() { + _swig_wrap_A_a(arg1) +} + +var _wrap_new_A unsafe.Pointer + +func _swig_wrap_new_A() (base SwigcptrA) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_A, _swig_p) + return +} + +func NewA() (_swig_ret A) { + return _swig_wrap_new_A() +} + +var _wrap_delete_A unsafe.Pointer + +func _swig_wrap_delete_A(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_A, _swig_p) + return +} + +func DeleteA(arg1 A) { + _swig_wrap_delete_A(arg1.Swigcptr()) +} + +type A interface { + Swigcptr() uintptr + SwigIsA() + A() +} + +type SwigcptrB uintptr + +func (p SwigcptrB) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrB) SwigIsB() { +} + +var _wrap_B_b unsafe.Pointer + +func _swig_wrap_B_b(base SwigcptrB) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_B_b, _swig_p) + return +} + +func (arg1 SwigcptrB) B() { + _swig_wrap_B_b(arg1) +} + +var _wrap_new_B unsafe.Pointer + +func _swig_wrap_new_B() (base SwigcptrB) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_B, _swig_p) + return +} + +func NewB() (_swig_ret B) { + return _swig_wrap_new_B() +} + +var _wrap_delete_B unsafe.Pointer + +func _swig_wrap_delete_B(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_B, _swig_p) + return +} + +func DeleteB(arg1 B) { + _swig_wrap_delete_B(arg1.Swigcptr()) +} + +type B interface { + Swigcptr() uintptr + SwigIsB() + B() +} + +type SwigcptrC uintptr + +func (p SwigcptrC) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrC) SwigIsC() { +} + +var _wrap_C_c unsafe.Pointer + +func _swig_wrap_C_c(base SwigcptrC) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_C_c, _swig_p) + return +} + +func (arg1 SwigcptrC) C() { + _swig_wrap_C_c(arg1) +} + +var _wrap_new_C unsafe.Pointer + +func _swig_wrap_new_C() (base SwigcptrC) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_C, _swig_p) + return +} + +func NewC() (_swig_ret C) { + return _swig_wrap_new_C() +} + +var _wrap_delete_C unsafe.Pointer + +func _swig_wrap_delete_C(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_C, _swig_p) + return +} + +func DeleteC(arg1 C) { + _swig_wrap_delete_C(arg1.Swigcptr()) +} + +type C interface { + Swigcptr() uintptr + SwigIsC() + C() +} + +type SwigcptrD uintptr + +func (p SwigcptrD) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrD) SwigIsD() { +} + +var _wrap_D_d unsafe.Pointer + +func _swig_wrap_D_d(base SwigcptrD) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_D_d, _swig_p) + return +} + +func (arg1 SwigcptrD) D() { + _swig_wrap_D_d(arg1) +} + +var _wrap_new_D unsafe.Pointer + +func _swig_wrap_new_D() (base SwigcptrD) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_D, _swig_p) + return +} + +func NewD() (_swig_ret D) { + return _swig_wrap_new_D() +} + +var _wrap_delete_D unsafe.Pointer + +func _swig_wrap_delete_D(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_D, _swig_p) + return +} + +func DeleteD(arg1 D) { + _swig_wrap_delete_D(arg1.Swigcptr()) +} + +type D interface { + Swigcptr() uintptr + SwigIsD() + D() +} + +type SwigcptrE uintptr + +func (p SwigcptrE) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrE) SwigIsE() { +} + +var _wrap_E_e unsafe.Pointer + +func _swig_wrap_E_e(base SwigcptrE) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_E_e, _swig_p) + return +} + +func (arg1 SwigcptrE) E() { + _swig_wrap_E_e(arg1) +} + +var _wrap_new_E unsafe.Pointer + +func _swig_wrap_new_E() (base SwigcptrE) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_E, _swig_p) + return +} + +func NewE() (_swig_ret E) { + return _swig_wrap_new_E() +} + +var _wrap_delete_E unsafe.Pointer + +func _swig_wrap_delete_E(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_E, _swig_p) + return +} + +func DeleteE(arg1 E) { + _swig_wrap_delete_E(arg1.Swigcptr()) +} + +type E interface { + Swigcptr() uintptr + SwigIsE() + E() +} + +type SwigcptrF uintptr + +func (p SwigcptrF) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrF) SwigIsF() { +} + +var _wrap_F_f unsafe.Pointer + +func _swig_wrap_F_f(base SwigcptrF) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_F_f, _swig_p) + return +} + +func (arg1 SwigcptrF) F() { + _swig_wrap_F_f(arg1) +} + +var _wrap_new_F unsafe.Pointer + +func _swig_wrap_new_F() (base SwigcptrF) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_F, _swig_p) + return +} + +func NewF() (_swig_ret F) { + return _swig_wrap_new_F() +} + +var _wrap_delete_F unsafe.Pointer + +func _swig_wrap_delete_F(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_F, _swig_p) + return +} + +func DeleteF(arg1 F) { + _swig_wrap_delete_F(arg1.Swigcptr()) +} + +type F interface { + Swigcptr() uintptr + SwigIsF() + F() +} + +type SwigcptrG uintptr + +func (p SwigcptrG) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrG) SwigIsG() { +} + +var _wrap_G_g unsafe.Pointer + +func _swig_wrap_G_g(base SwigcptrG) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_G_g, _swig_p) + return +} + +func (arg1 SwigcptrG) G() { + _swig_wrap_G_g(arg1) +} + +var _wrap_new_G unsafe.Pointer + +func _swig_wrap_new_G() (base SwigcptrG) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_G, _swig_p) + return +} + +func NewG() (_swig_ret G) { + return _swig_wrap_new_G() +} + +var _wrap_delete_G unsafe.Pointer + +func _swig_wrap_delete_G(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_G, _swig_p) + return +} + +func DeleteG(arg1 G) { + _swig_wrap_delete_G(arg1.Swigcptr()) +} + +type G interface { + Swigcptr() uintptr + SwigIsG() + G() +} + +type SwigcptrH uintptr + +func (p SwigcptrH) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrH) SwigIsH() { +} + +var _wrap_H_h unsafe.Pointer + +func _swig_wrap_H_h(base SwigcptrH) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_H_h, _swig_p) + return +} + +func (arg1 SwigcptrH) H() { + _swig_wrap_H_h(arg1) +} + +var _wrap_new_H unsafe.Pointer + +func _swig_wrap_new_H() (base SwigcptrH) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_H, _swig_p) + return +} + +func NewH() (_swig_ret H) { + return _swig_wrap_new_H() +} + +var _wrap_delete_H unsafe.Pointer + +func _swig_wrap_delete_H(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_H, _swig_p) + return +} + +func DeleteH(arg1 H) { + _swig_wrap_delete_H(arg1.Swigcptr()) +} + +type H interface { + Swigcptr() uintptr + SwigIsH() + H() +} + +type SwigcptrI uintptr + +func (p SwigcptrI) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrI) SwigIsI() { +} + +var _wrap_I_i unsafe.Pointer + +func _swig_wrap_I_i(base SwigcptrI) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_I_i, _swig_p) + return +} + +func (arg1 SwigcptrI) I() { + _swig_wrap_I_i(arg1) +} + +var _wrap_new_I unsafe.Pointer + +func _swig_wrap_new_I() (base SwigcptrI) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_I, _swig_p) + return +} + +func NewI() (_swig_ret I) { + return _swig_wrap_new_I() +} + +var _wrap_delete_I unsafe.Pointer + +func _swig_wrap_delete_I(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_I, _swig_p) + return +} + +func DeleteI(arg1 I) { + _swig_wrap_delete_I(arg1.Swigcptr()) +} + +type I interface { + Swigcptr() uintptr + SwigIsI() + I() +} + +type SwigcptrJ uintptr + +func (p SwigcptrJ) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrJ) SwigIsJ() { +} + +var _wrap_J_j unsafe.Pointer + +func _swig_wrap_J_j(base SwigcptrJ) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_J_j, _swig_p) + return +} + +func (arg1 SwigcptrJ) J() { + _swig_wrap_J_j(arg1) +} + +var _wrap_new_J unsafe.Pointer + +func _swig_wrap_new_J() (base SwigcptrJ) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_J, _swig_p) + return +} + +func NewJ() (_swig_ret J) { + return _swig_wrap_new_J() +} + +var _wrap_delete_J unsafe.Pointer + +func _swig_wrap_delete_J(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_J, _swig_p) + return +} + +func DeleteJ(arg1 J) { + _swig_wrap_delete_J(arg1.Swigcptr()) +} + +type J interface { + Swigcptr() uintptr + SwigIsJ() + J() +} + +type SwigcptrK uintptr + +func (p SwigcptrK) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrK) SwigIsK() { +} + +var _wrap_K_k unsafe.Pointer + +func _swig_wrap_K_k(base SwigcptrK) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_K_k, _swig_p) + return +} + +func (arg1 SwigcptrK) K() { + _swig_wrap_K_k(arg1) +} + +var _wrap_new_K unsafe.Pointer + +func _swig_wrap_new_K() (base SwigcptrK) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_K, _swig_p) + return +} + +func NewK() (_swig_ret K) { + return _swig_wrap_new_K() +} + +var _wrap_delete_K unsafe.Pointer + +func _swig_wrap_delete_K(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_K, _swig_p) + return +} + +func DeleteK(arg1 K) { + _swig_wrap_delete_K(arg1.Swigcptr()) +} + +type K interface { + Swigcptr() uintptr + SwigIsK() + K() +} + +type SwigcptrL uintptr + +func (p SwigcptrL) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrL) SwigIsL() { +} + +var _wrap_L_l unsafe.Pointer + +func _swig_wrap_L_l(base SwigcptrL) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_L_l, _swig_p) + return +} + +func (arg1 SwigcptrL) L() { + _swig_wrap_L_l(arg1) +} + +var _wrap_new_L unsafe.Pointer + +func _swig_wrap_new_L() (base SwigcptrL) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_L, _swig_p) + return +} + +func NewL() (_swig_ret L) { + return _swig_wrap_new_L() +} + +var _wrap_delete_L unsafe.Pointer + +func _swig_wrap_delete_L(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_L, _swig_p) + return +} + +func DeleteL(arg1 L) { + _swig_wrap_delete_L(arg1.Swigcptr()) +} + +type L interface { + Swigcptr() uintptr + SwigIsL() + L() +} + +type SwigcptrBB uintptr + +func (p SwigcptrBB) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrBB) SwigIsBB() { +} + +var _wrap_BB_b unsafe.Pointer + +func _swig_wrap_BB_b(base SwigcptrBB) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_BB_b, _swig_p) + return +} + +func (arg1 SwigcptrBB) B() { + _swig_wrap_BB_b(arg1) +} + +var _wrap_new_BB unsafe.Pointer + +func _swig_wrap_new_BB() (base SwigcptrBB) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_BB, _swig_p) + return +} + +func NewBB() (_swig_ret BB) { + return _swig_wrap_new_BB() +} + +var _wrap_delete_BB unsafe.Pointer + +func _swig_wrap_delete_BB(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_BB, _swig_p) + return +} + +func DeleteBB(arg1 BB) { + _swig_wrap_delete_BB(arg1.Swigcptr()) +} + +type BB interface { + Swigcptr() uintptr + SwigIsBB() + B() +} + +type SwigcptrBBB uintptr + +func (p SwigcptrBBB) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrBBB) SwigIsBBB() { +} + +var _wrap_BBB_b unsafe.Pointer + +func _swig_wrap_BBB_b(base SwigcptrBBB) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_BBB_b, _swig_p) + return +} + +func (arg1 SwigcptrBBB) B() { + _swig_wrap_BBB_b(arg1) +} + +var _wrap_new_BBB unsafe.Pointer + +func _swig_wrap_new_BBB() (base SwigcptrBBB) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_BBB, _swig_p) + return +} + +func NewBBB() (_swig_ret BBB) { + return _swig_wrap_new_BBB() +} + +var _wrap_delete_BBB unsafe.Pointer + +func _swig_wrap_delete_BBB(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_BBB, _swig_p) + return +} + +func DeleteBBB(arg1 BBB) { + _swig_wrap_delete_BBB(arg1.Swigcptr()) +} + +type BBB interface { + Swigcptr() uintptr + SwigIsBBB() + B() +} + +type SwigcptrBBBB uintptr + +func (p SwigcptrBBBB) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrBBBB) SwigIsBBBB() { +} + +var _wrap_BBBB_b unsafe.Pointer + +func _swig_wrap_BBBB_b(base SwigcptrBBBB) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_BBBB_b, _swig_p) + return +} + +func (arg1 SwigcptrBBBB) B() { + _swig_wrap_BBBB_b(arg1) +} + +var _wrap_new_BBBB unsafe.Pointer + +func _swig_wrap_new_BBBB() (base SwigcptrBBBB) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_BBBB, _swig_p) + return +} + +func NewBBBB() (_swig_ret BBBB) { + return _swig_wrap_new_BBBB() +} + +var _wrap_delete_BBBB unsafe.Pointer + +func _swig_wrap_delete_BBBB(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_BBBB, _swig_p) + return +} + +func DeleteBBBB(arg1 BBBB) { + _swig_wrap_delete_BBBB(arg1.Swigcptr()) +} + +type BBBB interface { + Swigcptr() uintptr + SwigIsBBBB() + B() +} + +type SwigcptrBBBBB uintptr + +func (p SwigcptrBBBBB) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrBBBBB) SwigIsBBBBB() { +} + +var _wrap_BBBBB_b unsafe.Pointer + +func _swig_wrap_BBBBB_b(base SwigcptrBBBBB) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_BBBBB_b, _swig_p) + return +} + +func (arg1 SwigcptrBBBBB) B() { + _swig_wrap_BBBBB_b(arg1) +} + +var _wrap_new_BBBBB unsafe.Pointer + +func _swig_wrap_new_BBBBB() (base SwigcptrBBBBB) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_BBBBB, _swig_p) + return +} + +func NewBBBBB() (_swig_ret BBBBB) { + return _swig_wrap_new_BBBBB() +} + +var _wrap_delete_BBBBB unsafe.Pointer + +func _swig_wrap_delete_BBBBB(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_BBBBB, _swig_p) + return +} + +func DeleteBBBBB(arg1 BBBBB) { + _swig_wrap_delete_BBBBB(arg1.Swigcptr()) +} + +type BBBBB interface { + Swigcptr() uintptr + SwigIsBBBBB() + B() +} + +type SwigcptrB1 uintptr + +func (p SwigcptrB1) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrB1) SwigIsB1() { +} + +var _wrap_B1_b unsafe.Pointer + +func _swig_wrap_B1_b(base SwigcptrB1) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_B1_b, _swig_p) + return +} + +func (arg1 SwigcptrB1) B() { + _swig_wrap_B1_b(arg1) +} + +var _wrap_new_B1 unsafe.Pointer + +func _swig_wrap_new_B1() (base SwigcptrB1) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_B1, _swig_p) + return +} + +func NewB1() (_swig_ret B1) { + return _swig_wrap_new_B1() +} + +var _wrap_delete_B1 unsafe.Pointer + +func _swig_wrap_delete_B1(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_B1, _swig_p) + return +} + +func DeleteB1(arg1 B1) { + _swig_wrap_delete_B1(arg1.Swigcptr()) +} + +type B1 interface { + Swigcptr() uintptr + SwigIsB1() + B() +} + +type SwigcptrB2 uintptr + +func (p SwigcptrB2) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrB2) SwigIsB2() { +} + +var _wrap_B2_b unsafe.Pointer + +func _swig_wrap_B2_b(base SwigcptrB2) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_B2_b, _swig_p) + return +} + +func (arg1 SwigcptrB2) B() { + _swig_wrap_B2_b(arg1) +} + +var _wrap_new_B2 unsafe.Pointer + +func _swig_wrap_new_B2() (base SwigcptrB2) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_B2, _swig_p) + return +} + +func NewB2() (_swig_ret B2) { + return _swig_wrap_new_B2() +} + +var _wrap_delete_B2 unsafe.Pointer + +func _swig_wrap_delete_B2(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_B2, _swig_p) + return +} + +func DeleteB2(arg1 B2) { + _swig_wrap_delete_B2(arg1.Swigcptr()) +} + +type B2 interface { + Swigcptr() uintptr + SwigIsB2() + B() +} + +type SwigcptrB3 uintptr + +func (p SwigcptrB3) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrB3) SwigIsB3() { +} + +var _wrap_B3_b unsafe.Pointer + +func _swig_wrap_B3_b(base SwigcptrB3) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_B3_b, _swig_p) + return +} + +func (arg1 SwigcptrB3) B() { + _swig_wrap_B3_b(arg1) +} + +var _wrap_new_B3 unsafe.Pointer + +func _swig_wrap_new_B3() (base SwigcptrB3) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_B3, _swig_p) + return +} + +func NewB3() (_swig_ret B3) { + return _swig_wrap_new_B3() +} + +var _wrap_delete_B3 unsafe.Pointer + +func _swig_wrap_delete_B3(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_B3, _swig_p) + return +} + +func DeleteB3(arg1 B3) { + _swig_wrap_delete_B3(arg1.Swigcptr()) +} + +type B3 interface { + Swigcptr() uintptr + SwigIsB3() + B() +} + +type SwigcptrB4 uintptr + +func (p SwigcptrB4) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrB4) SwigIsB4() { +} + +var _wrap_B4_b unsafe.Pointer + +func _swig_wrap_B4_b(base SwigcptrB4) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_B4_b, _swig_p) + return +} + +func (arg1 SwigcptrB4) B() { + _swig_wrap_B4_b(arg1) +} + +var _wrap_new_B4 unsafe.Pointer + +func _swig_wrap_new_B4() (base SwigcptrB4) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_B4, _swig_p) + return +} + +func NewB4() (_swig_ret B4) { + return _swig_wrap_new_B4() +} + +var _wrap_delete_B4 unsafe.Pointer + +func _swig_wrap_delete_B4(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_B4, _swig_p) + return +} + +func DeleteB4(arg1 B4) { + _swig_wrap_delete_B4(arg1.Swigcptr()) +} + +type B4 interface { + Swigcptr() uintptr + SwigIsB4() + B() +} + +type SwigcptrConcrete uintptr + +func (p SwigcptrConcrete) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrConcrete) SwigIsConcrete() { +} + +var _wrap_new_Concrete unsafe.Pointer + +func _swig_wrap_new_Concrete() (base SwigcptrConcrete) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Concrete, _swig_p) + return +} + +func NewConcrete() (_swig_ret Concrete) { + return _swig_wrap_new_Concrete() +} + +var _wrap_delete_Concrete unsafe.Pointer + +func _swig_wrap_delete_Concrete(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Concrete, _swig_p) + return +} + +func DeleteConcrete(arg1 Concrete) { + _swig_wrap_delete_Concrete(arg1.Swigcptr()) +} + +type Concrete interface { + Swigcptr() uintptr + SwigIsConcrete() +} + +type SwigcptrA_ uintptr + +func (p SwigcptrA_) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrA_) SwigIsA_() { +} + +var _wrap_A__a unsafe.Pointer + +func _swig_wrap_A__a(base SwigcptrA_) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_A__a, _swig_p) + return +} + +func (arg1 SwigcptrA_) A() { + _swig_wrap_A__a(arg1) +} + +var _wrap_new_A_ unsafe.Pointer + +func _swig_wrap_new_A_() (base SwigcptrA_) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_A_, _swig_p) + return +} + +func NewA_() (_swig_ret A_) { + return _swig_wrap_new_A_() +} + +var _wrap_delete_A_ unsafe.Pointer + +func _swig_wrap_delete_A_(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_A_, _swig_p) + return +} + +func DeleteA_(arg1 A_) { + _swig_wrap_delete_A_(arg1.Swigcptr()) +} + +type A_ interface { + Swigcptr() uintptr + SwigIsA_() + A() +} + +type SwigcptrB_ uintptr + +func (p SwigcptrB_) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrB_) SwigIsB_() { +} + +var _wrap_B__b unsafe.Pointer + +func _swig_wrap_B__b(base SwigcptrB_) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_B__b, _swig_p) + return +} + +func (arg1 SwigcptrB_) B() { + _swig_wrap_B__b(arg1) +} + +var _wrap_new_B_ unsafe.Pointer + +func _swig_wrap_new_B_() (base SwigcptrB_) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_B_, _swig_p) + return +} + +func NewB_() (_swig_ret B_) { + return _swig_wrap_new_B_() +} + +var _wrap_delete_B_ unsafe.Pointer + +func _swig_wrap_delete_B_(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_B_, _swig_p) + return +} + +func DeleteB_(arg1 B_) { + _swig_wrap_delete_B_(arg1.Swigcptr()) +} + +type B_ interface { + Swigcptr() uintptr + SwigIsB_() + B() +} + +type SwigcptrC_ uintptr + +func (p SwigcptrC_) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrC_) SwigIsC_() { +} + +var _wrap_C__c unsafe.Pointer + +func _swig_wrap_C__c(base SwigcptrC_) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_C__c, _swig_p) + return +} + +func (arg1 SwigcptrC_) C() { + _swig_wrap_C__c(arg1) +} + +var _wrap_new_C_ unsafe.Pointer + +func _swig_wrap_new_C_() (base SwigcptrC_) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_C_, _swig_p) + return +} + +func NewC_() (_swig_ret C_) { + return _swig_wrap_new_C_() +} + +var _wrap_delete_C_ unsafe.Pointer + +func _swig_wrap_delete_C_(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_C_, _swig_p) + return +} + +func DeleteC_(arg1 C_) { + _swig_wrap_delete_C_(arg1.Swigcptr()) +} + +type C_ interface { + Swigcptr() uintptr + SwigIsC_() + C() +} + +type SwigcptrD_ uintptr + +func (p SwigcptrD_) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrD_) SwigIsD_() { +} + +var _wrap_D__d unsafe.Pointer + +func _swig_wrap_D__d(base SwigcptrD_) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_D__d, _swig_p) + return +} + +func (arg1 SwigcptrD_) D() { + _swig_wrap_D__d(arg1) +} + +var _wrap_new_D_ unsafe.Pointer + +func _swig_wrap_new_D_() (base SwigcptrD_) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_D_, _swig_p) + return +} + +func NewD_() (_swig_ret D_) { + return _swig_wrap_new_D_() +} + +var _wrap_delete_D_ unsafe.Pointer + +func _swig_wrap_delete_D_(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_D_, _swig_p) + return +} + +func DeleteD_(arg1 D_) { + _swig_wrap_delete_D_(arg1.Swigcptr()) +} + +type D_ interface { + Swigcptr() uintptr + SwigIsD_() + D() +} + +type SwigcptrE_ uintptr + +func (p SwigcptrE_) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrE_) SwigIsE_() { +} + +var _wrap_E__e unsafe.Pointer + +func _swig_wrap_E__e(base SwigcptrE_) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_E__e, _swig_p) + return +} + +func (arg1 SwigcptrE_) E() { + _swig_wrap_E__e(arg1) +} + +var _wrap_new_E_ unsafe.Pointer + +func _swig_wrap_new_E_() (base SwigcptrE_) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_E_, _swig_p) + return +} + +func NewE_() (_swig_ret E_) { + return _swig_wrap_new_E_() +} + +var _wrap_delete_E_ unsafe.Pointer + +func _swig_wrap_delete_E_(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_E_, _swig_p) + return +} + +func DeleteE_(arg1 E_) { + _swig_wrap_delete_E_(arg1.Swigcptr()) +} + +type E_ interface { + Swigcptr() uintptr + SwigIsE_() + E() +} + +type SwigcptrF_ uintptr + +func (p SwigcptrF_) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrF_) SwigIsF_() { +} + +var _wrap_F__f unsafe.Pointer + +func _swig_wrap_F__f(base SwigcptrF_) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_F__f, _swig_p) + return +} + +func (arg1 SwigcptrF_) F() { + _swig_wrap_F__f(arg1) +} + +var _wrap_new_F_ unsafe.Pointer + +func _swig_wrap_new_F_() (base SwigcptrF_) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_F_, _swig_p) + return +} + +func NewF_() (_swig_ret F_) { + return _swig_wrap_new_F_() +} + +var _wrap_delete_F_ unsafe.Pointer + +func _swig_wrap_delete_F_(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_F_, _swig_p) + return +} + +func DeleteF_(arg1 F_) { + _swig_wrap_delete_F_(arg1.Swigcptr()) +} + +type F_ interface { + Swigcptr() uintptr + SwigIsF_() + F() +} + +type SwigcptrG_ uintptr + +func (p SwigcptrG_) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrG_) SwigIsG_() { +} + +var _wrap_G__g unsafe.Pointer + +func _swig_wrap_G__g(base SwigcptrG_) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_G__g, _swig_p) + return +} + +func (arg1 SwigcptrG_) G() { + _swig_wrap_G__g(arg1) +} + +var _wrap_new_G_ unsafe.Pointer + +func _swig_wrap_new_G_() (base SwigcptrG_) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_G_, _swig_p) + return +} + +func NewG_() (_swig_ret G_) { + return _swig_wrap_new_G_() +} + +var _wrap_delete_G_ unsafe.Pointer + +func _swig_wrap_delete_G_(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_G_, _swig_p) + return +} + +func DeleteG_(arg1 G_) { + _swig_wrap_delete_G_(arg1.Swigcptr()) +} + +type G_ interface { + Swigcptr() uintptr + SwigIsG_() + G() +} + +type SwigcptrC1_ uintptr + +func (p SwigcptrC1_) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrC1_) SwigIsC1_() { +} + +var _wrap_C1__c unsafe.Pointer + +func _swig_wrap_C1__c(base SwigcptrC1_) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_C1__c, _swig_p) + return +} + +func (arg1 SwigcptrC1_) C() { + _swig_wrap_C1__c(arg1) +} + +var _wrap_new_C1_ unsafe.Pointer + +func _swig_wrap_new_C1_() (base SwigcptrC1_) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_C1_, _swig_p) + return +} + +func NewC1_() (_swig_ret C1_) { + return _swig_wrap_new_C1_() +} + +var _wrap_delete_C1_ unsafe.Pointer + +func _swig_wrap_delete_C1_(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_C1_, _swig_p) + return +} + +func DeleteC1_(arg1 C1_) { + _swig_wrap_delete_C1_(arg1.Swigcptr()) +} + +type C1_ interface { + Swigcptr() uintptr + SwigIsC1_() + C() +} + +type SwigcptrC2_ uintptr + +func (p SwigcptrC2_) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrC2_) SwigIsC2_() { +} + +var _wrap_C2__c unsafe.Pointer + +func _swig_wrap_C2__c(base SwigcptrC2_) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_C2__c, _swig_p) + return +} + +func (arg1 SwigcptrC2_) C() { + _swig_wrap_C2__c(arg1) +} + +var _wrap_new_C2_ unsafe.Pointer + +func _swig_wrap_new_C2_() (base SwigcptrC2_) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_C2_, _swig_p) + return +} + +func NewC2_() (_swig_ret C2_) { + return _swig_wrap_new_C2_() +} + +var _wrap_delete_C2_ unsafe.Pointer + +func _swig_wrap_delete_C2_(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_C2_, _swig_p) + return +} + +func DeleteC2_(arg1 C2_) { + _swig_wrap_delete_C2_(arg1.Swigcptr()) +} + +type C2_ interface { + Swigcptr() uintptr + SwigIsC2_() + C() +} + +type SwigcptrC3_ uintptr + +func (p SwigcptrC3_) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrC3_) SwigIsC3_() { +} + +var _wrap_C3__c unsafe.Pointer + +func _swig_wrap_C3__c(base SwigcptrC3_) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_C3__c, _swig_p) + return +} + +func (arg1 SwigcptrC3_) C() { + _swig_wrap_C3__c(arg1) +} + +var _wrap_new_C3_ unsafe.Pointer + +func _swig_wrap_new_C3_() (base SwigcptrC3_) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_C3_, _swig_p) + return +} + +func NewC3_() (_swig_ret C3_) { + return _swig_wrap_new_C3_() +} + +var _wrap_delete_C3_ unsafe.Pointer + +func _swig_wrap_delete_C3_(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_C3_, _swig_p) + return +} + +func DeleteC3_(arg1 C3_) { + _swig_wrap_delete_C3_(arg1.Swigcptr()) +} + +type C3_ interface { + Swigcptr() uintptr + SwigIsC3_() + C() +} + +type SwigcptrC4_ uintptr + +func (p SwigcptrC4_) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrC4_) SwigIsC4_() { +} + +var _wrap_C4__c unsafe.Pointer + +func _swig_wrap_C4__c(base SwigcptrC4_) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_C4__c, _swig_p) + return +} + +func (arg1 SwigcptrC4_) C() { + _swig_wrap_C4__c(arg1) +} + +var _wrap_new_C4_ unsafe.Pointer + +func _swig_wrap_new_C4_() (base SwigcptrC4_) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_C4_, _swig_p) + return +} + +func NewC4_() (_swig_ret C4_) { + return _swig_wrap_new_C4_() +} + +var _wrap_delete_C4_ unsafe.Pointer + +func _swig_wrap_delete_C4_(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_C4_, _swig_p) + return +} + +func DeleteC4_(arg1 C4_) { + _swig_wrap_delete_C4_(arg1.Swigcptr()) +} + +type C4_ interface { + Swigcptr() uintptr + SwigIsC4_() + C() +} + +type SwigcptrB1_ uintptr + +func (p SwigcptrB1_) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrB1_) SwigIsB1_() { +} + +var _wrap_B1__b unsafe.Pointer + +func _swig_wrap_B1__b(base SwigcptrB1_) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_B1__b, _swig_p) + return +} + +func (arg1 SwigcptrB1_) B() { + _swig_wrap_B1__b(arg1) +} + +var _wrap_new_B1_ unsafe.Pointer + +func _swig_wrap_new_B1_() (base SwigcptrB1_) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_B1_, _swig_p) + return +} + +func NewB1_() (_swig_ret B1_) { + return _swig_wrap_new_B1_() +} + +var _wrap_delete_B1_ unsafe.Pointer + +func _swig_wrap_delete_B1_(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_B1_, _swig_p) + return +} + +func DeleteB1_(arg1 B1_) { + _swig_wrap_delete_B1_(arg1.Swigcptr()) +} + +type B1_ interface { + Swigcptr() uintptr + SwigIsB1_() + B() +} + +type SwigcptrE1_ uintptr + +func (p SwigcptrE1_) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrE1_) SwigIsE1_() { +} + +var _wrap_E1__e unsafe.Pointer + +func _swig_wrap_E1__e(base SwigcptrE1_) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_E1__e, _swig_p) + return +} + +func (arg1 SwigcptrE1_) E() { + _swig_wrap_E1__e(arg1) +} + +var _wrap_new_E1_ unsafe.Pointer + +func _swig_wrap_new_E1_() (base SwigcptrE1_) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_E1_, _swig_p) + return +} + +func NewE1_() (_swig_ret E1_) { + return _swig_wrap_new_E1_() +} + +var _wrap_delete_E1_ unsafe.Pointer + +func _swig_wrap_delete_E1_(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_E1_, _swig_p) + return +} + +func DeleteE1_(arg1 E1_) { + _swig_wrap_delete_E1_(arg1.Swigcptr()) +} + +type E1_ interface { + Swigcptr() uintptr + SwigIsE1_() + E() +} + +type SwigcptrE2_ uintptr + +func (p SwigcptrE2_) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrE2_) SwigIsE2_() { +} + +var _wrap_E2__e unsafe.Pointer + +func _swig_wrap_E2__e(base SwigcptrE2_) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_E2__e, _swig_p) + return +} + +func (arg1 SwigcptrE2_) E() { + _swig_wrap_E2__e(arg1) +} + +var _wrap_new_E2_ unsafe.Pointer + +func _swig_wrap_new_E2_() (base SwigcptrE2_) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_E2_, _swig_p) + return +} + +func NewE2_() (_swig_ret E2_) { + return _swig_wrap_new_E2_() +} + +var _wrap_delete_E2_ unsafe.Pointer + +func _swig_wrap_delete_E2_(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_E2_, _swig_p) + return +} + +func DeleteE2_(arg1 E2_) { + _swig_wrap_delete_E2_(arg1.Swigcptr()) +} + +type E2_ interface { + Swigcptr() uintptr + SwigIsE2_() + E() +} + +type SwigcptrH_ uintptr + +func (p SwigcptrH_) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrH_) SwigIsH_() { +} + +var _wrap_H__h unsafe.Pointer + +func _swig_wrap_H__h(base SwigcptrH_) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_H__h, _swig_p) + return +} + +func (arg1 SwigcptrH_) H() { + _swig_wrap_H__h(arg1) +} + +var _wrap_new_H_ unsafe.Pointer + +func _swig_wrap_new_H_() (base SwigcptrH_) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_H_, _swig_p) + return +} + +func NewH_() (_swig_ret H_) { + return _swig_wrap_new_H_() +} + +var _wrap_delete_H_ unsafe.Pointer + +func _swig_wrap_delete_H_(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_H_, _swig_p) + return +} + +func DeleteH_(arg1 H_) { + _swig_wrap_delete_H_(arg1.Swigcptr()) +} + +type H_ interface { + Swigcptr() uintptr + SwigIsH_() + H() +} + +type SwigcptrFiveParm1 uintptr + +func (p SwigcptrFiveParm1) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrFiveParm1) SwigIsFiveParm1() { +} + +var _wrap_FiveParm1_b unsafe.Pointer + +func _swig_wrap_FiveParm1_b(base SwigcptrFiveParm1) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_FiveParm1_b, _swig_p) + return +} + +func (arg1 SwigcptrFiveParm1) B() { + _swig_wrap_FiveParm1_b(arg1) +} + +var _wrap_new_FiveParm1 unsafe.Pointer + +func _swig_wrap_new_FiveParm1() (base SwigcptrFiveParm1) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_FiveParm1, _swig_p) + return +} + +func NewFiveParm1() (_swig_ret FiveParm1) { + return _swig_wrap_new_FiveParm1() +} + +var _wrap_delete_FiveParm1 unsafe.Pointer + +func _swig_wrap_delete_FiveParm1(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_FiveParm1, _swig_p) + return +} + +func DeleteFiveParm1(arg1 FiveParm1) { + _swig_wrap_delete_FiveParm1(arg1.Swigcptr()) +} + +type FiveParm1 interface { + Swigcptr() uintptr + SwigIsFiveParm1() + B() +} + +type SwigcptrThreeParmInt uintptr + +func (p SwigcptrThreeParmInt) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrThreeParmInt) SwigIsThreeParmInt() { +} + +var _wrap_ThreeParmInt_a2 unsafe.Pointer + +func _swig_wrap_ThreeParmInt_a2(base SwigcptrThreeParmInt) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_ThreeParmInt_a2, _swig_p) + return +} + +func (arg1 SwigcptrThreeParmInt) A2() { + _swig_wrap_ThreeParmInt_a2(arg1) +} + +var _wrap_new_ThreeParmInt unsafe.Pointer + +func _swig_wrap_new_ThreeParmInt() (base SwigcptrThreeParmInt) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_ThreeParmInt, _swig_p) + return +} + +func NewThreeParmInt() (_swig_ret ThreeParmInt) { + return _swig_wrap_new_ThreeParmInt() +} + +var _wrap_delete_ThreeParmInt unsafe.Pointer + +func _swig_wrap_delete_ThreeParmInt(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_ThreeParmInt, _swig_p) + return +} + +func DeleteThreeParmInt(arg1 ThreeParmInt) { + _swig_wrap_delete_ThreeParmInt(arg1.Swigcptr()) +} + +type ThreeParmInt interface { + Swigcptr() uintptr + SwigIsThreeParmInt() + A2() +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/template_partial_specialization_typedef.go b/Examples/test-suite/go/template_partial_specialization_typedef.go new file mode 100644 index 000000000..cc06cfe83 --- /dev/null +++ b/Examples/test-suite/go/template_partial_specialization_typedef.go @@ -0,0 +1,1809 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../template_partial_specialization_typedef.i + +package template_partial_specialization_typedef + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrA uintptr + +func (p SwigcptrA) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrA) SwigIsA() { +} + +var _wrap_A_a unsafe.Pointer + +func _swig_wrap_A_a(base SwigcptrA) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_A_a, _swig_p) + return +} + +func (arg1 SwigcptrA) A() { + _swig_wrap_A_a(arg1) +} + +var _wrap_new_A unsafe.Pointer + +func _swig_wrap_new_A() (base SwigcptrA) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_A, _swig_p) + return +} + +func NewA() (_swig_ret A) { + return _swig_wrap_new_A() +} + +var _wrap_delete_A unsafe.Pointer + +func _swig_wrap_delete_A(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_A, _swig_p) + return +} + +func DeleteA(arg1 A) { + _swig_wrap_delete_A(arg1.Swigcptr()) +} + +type A interface { + Swigcptr() uintptr + SwigIsA() + A() +} + +type SwigcptrB uintptr + +func (p SwigcptrB) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrB) SwigIsB() { +} + +var _wrap_B_b unsafe.Pointer + +func _swig_wrap_B_b(base SwigcptrB) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_B_b, _swig_p) + return +} + +func (arg1 SwigcptrB) B() { + _swig_wrap_B_b(arg1) +} + +var _wrap_new_B unsafe.Pointer + +func _swig_wrap_new_B() (base SwigcptrB) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_B, _swig_p) + return +} + +func NewB() (_swig_ret B) { + return _swig_wrap_new_B() +} + +var _wrap_delete_B unsafe.Pointer + +func _swig_wrap_delete_B(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_B, _swig_p) + return +} + +func DeleteB(arg1 B) { + _swig_wrap_delete_B(arg1.Swigcptr()) +} + +type B interface { + Swigcptr() uintptr + SwigIsB() + B() +} + +type SwigcptrC uintptr + +func (p SwigcptrC) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrC) SwigIsC() { +} + +var _wrap_C_c unsafe.Pointer + +func _swig_wrap_C_c(base SwigcptrC) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_C_c, _swig_p) + return +} + +func (arg1 SwigcptrC) C() { + _swig_wrap_C_c(arg1) +} + +var _wrap_new_C unsafe.Pointer + +func _swig_wrap_new_C() (base SwigcptrC) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_C, _swig_p) + return +} + +func NewC() (_swig_ret C) { + return _swig_wrap_new_C() +} + +var _wrap_delete_C unsafe.Pointer + +func _swig_wrap_delete_C(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_C, _swig_p) + return +} + +func DeleteC(arg1 C) { + _swig_wrap_delete_C(arg1.Swigcptr()) +} + +type C interface { + Swigcptr() uintptr + SwigIsC() + C() +} + +type SwigcptrD uintptr + +func (p SwigcptrD) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrD) SwigIsD() { +} + +var _wrap_D_d unsafe.Pointer + +func _swig_wrap_D_d(base SwigcptrD) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_D_d, _swig_p) + return +} + +func (arg1 SwigcptrD) D() { + _swig_wrap_D_d(arg1) +} + +var _wrap_new_D unsafe.Pointer + +func _swig_wrap_new_D() (base SwigcptrD) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_D, _swig_p) + return +} + +func NewD() (_swig_ret D) { + return _swig_wrap_new_D() +} + +var _wrap_delete_D unsafe.Pointer + +func _swig_wrap_delete_D(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_D, _swig_p) + return +} + +func DeleteD(arg1 D) { + _swig_wrap_delete_D(arg1.Swigcptr()) +} + +type D interface { + Swigcptr() uintptr + SwigIsD() + D() +} + +type SwigcptrE uintptr + +func (p SwigcptrE) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrE) SwigIsE() { +} + +var _wrap_E_e unsafe.Pointer + +func _swig_wrap_E_e(base SwigcptrE) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_E_e, _swig_p) + return +} + +func (arg1 SwigcptrE) E() { + _swig_wrap_E_e(arg1) +} + +var _wrap_new_E unsafe.Pointer + +func _swig_wrap_new_E() (base SwigcptrE) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_E, _swig_p) + return +} + +func NewE() (_swig_ret E) { + return _swig_wrap_new_E() +} + +var _wrap_delete_E unsafe.Pointer + +func _swig_wrap_delete_E(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_E, _swig_p) + return +} + +func DeleteE(arg1 E) { + _swig_wrap_delete_E(arg1.Swigcptr()) +} + +type E interface { + Swigcptr() uintptr + SwigIsE() + E() +} + +type SwigcptrF uintptr + +func (p SwigcptrF) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrF) SwigIsF() { +} + +var _wrap_F_f unsafe.Pointer + +func _swig_wrap_F_f(base SwigcptrF) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_F_f, _swig_p) + return +} + +func (arg1 SwigcptrF) F() { + _swig_wrap_F_f(arg1) +} + +var _wrap_new_F unsafe.Pointer + +func _swig_wrap_new_F() (base SwigcptrF) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_F, _swig_p) + return +} + +func NewF() (_swig_ret F) { + return _swig_wrap_new_F() +} + +var _wrap_delete_F unsafe.Pointer + +func _swig_wrap_delete_F(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_F, _swig_p) + return +} + +func DeleteF(arg1 F) { + _swig_wrap_delete_F(arg1.Swigcptr()) +} + +type F interface { + Swigcptr() uintptr + SwigIsF() + F() +} + +type SwigcptrG uintptr + +func (p SwigcptrG) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrG) SwigIsG() { +} + +var _wrap_G_g unsafe.Pointer + +func _swig_wrap_G_g(base SwigcptrG) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_G_g, _swig_p) + return +} + +func (arg1 SwigcptrG) G() { + _swig_wrap_G_g(arg1) +} + +var _wrap_new_G unsafe.Pointer + +func _swig_wrap_new_G() (base SwigcptrG) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_G, _swig_p) + return +} + +func NewG() (_swig_ret G) { + return _swig_wrap_new_G() +} + +var _wrap_delete_G unsafe.Pointer + +func _swig_wrap_delete_G(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_G, _swig_p) + return +} + +func DeleteG(arg1 G) { + _swig_wrap_delete_G(arg1.Swigcptr()) +} + +type G interface { + Swigcptr() uintptr + SwigIsG() + G() +} + +type SwigcptrH uintptr + +func (p SwigcptrH) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrH) SwigIsH() { +} + +var _wrap_H_h unsafe.Pointer + +func _swig_wrap_H_h(base SwigcptrH) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_H_h, _swig_p) + return +} + +func (arg1 SwigcptrH) H() { + _swig_wrap_H_h(arg1) +} + +var _wrap_new_H unsafe.Pointer + +func _swig_wrap_new_H() (base SwigcptrH) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_H, _swig_p) + return +} + +func NewH() (_swig_ret H) { + return _swig_wrap_new_H() +} + +var _wrap_delete_H unsafe.Pointer + +func _swig_wrap_delete_H(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_H, _swig_p) + return +} + +func DeleteH(arg1 H) { + _swig_wrap_delete_H(arg1.Swigcptr()) +} + +type H interface { + Swigcptr() uintptr + SwigIsH() + H() +} + +type SwigcptrI uintptr + +func (p SwigcptrI) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrI) SwigIsI() { +} + +var _wrap_I_i unsafe.Pointer + +func _swig_wrap_I_i(base SwigcptrI) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_I_i, _swig_p) + return +} + +func (arg1 SwigcptrI) I() { + _swig_wrap_I_i(arg1) +} + +var _wrap_new_I unsafe.Pointer + +func _swig_wrap_new_I() (base SwigcptrI) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_I, _swig_p) + return +} + +func NewI() (_swig_ret I) { + return _swig_wrap_new_I() +} + +var _wrap_delete_I unsafe.Pointer + +func _swig_wrap_delete_I(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_I, _swig_p) + return +} + +func DeleteI(arg1 I) { + _swig_wrap_delete_I(arg1.Swigcptr()) +} + +type I interface { + Swigcptr() uintptr + SwigIsI() + I() +} + +type SwigcptrJ uintptr + +func (p SwigcptrJ) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrJ) SwigIsJ() { +} + +var _wrap_J_j unsafe.Pointer + +func _swig_wrap_J_j(base SwigcptrJ) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_J_j, _swig_p) + return +} + +func (arg1 SwigcptrJ) J() { + _swig_wrap_J_j(arg1) +} + +var _wrap_new_J unsafe.Pointer + +func _swig_wrap_new_J() (base SwigcptrJ) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_J, _swig_p) + return +} + +func NewJ() (_swig_ret J) { + return _swig_wrap_new_J() +} + +var _wrap_delete_J unsafe.Pointer + +func _swig_wrap_delete_J(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_J, _swig_p) + return +} + +func DeleteJ(arg1 J) { + _swig_wrap_delete_J(arg1.Swigcptr()) +} + +type J interface { + Swigcptr() uintptr + SwigIsJ() + J() +} + +type SwigcptrK uintptr + +func (p SwigcptrK) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrK) SwigIsK() { +} + +var _wrap_K_k unsafe.Pointer + +func _swig_wrap_K_k(base SwigcptrK) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_K_k, _swig_p) + return +} + +func (arg1 SwigcptrK) K() { + _swig_wrap_K_k(arg1) +} + +var _wrap_new_K unsafe.Pointer + +func _swig_wrap_new_K() (base SwigcptrK) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_K, _swig_p) + return +} + +func NewK() (_swig_ret K) { + return _swig_wrap_new_K() +} + +var _wrap_delete_K unsafe.Pointer + +func _swig_wrap_delete_K(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_K, _swig_p) + return +} + +func DeleteK(arg1 K) { + _swig_wrap_delete_K(arg1.Swigcptr()) +} + +type K interface { + Swigcptr() uintptr + SwigIsK() + K() +} + +type SwigcptrL uintptr + +func (p SwigcptrL) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrL) SwigIsL() { +} + +var _wrap_L_l unsafe.Pointer + +func _swig_wrap_L_l(base SwigcptrL) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_L_l, _swig_p) + return +} + +func (arg1 SwigcptrL) L() { + _swig_wrap_L_l(arg1) +} + +var _wrap_new_L unsafe.Pointer + +func _swig_wrap_new_L() (base SwigcptrL) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_L, _swig_p) + return +} + +func NewL() (_swig_ret L) { + return _swig_wrap_new_L() +} + +var _wrap_delete_L unsafe.Pointer + +func _swig_wrap_delete_L(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_L, _swig_p) + return +} + +func DeleteL(arg1 L) { + _swig_wrap_delete_L(arg1.Swigcptr()) +} + +type L interface { + Swigcptr() uintptr + SwigIsL() + L() +} + +type SwigcptrBB uintptr + +func (p SwigcptrBB) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrBB) SwigIsBB() { +} + +var _wrap_BB_b unsafe.Pointer + +func _swig_wrap_BB_b(base SwigcptrBB) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_BB_b, _swig_p) + return +} + +func (arg1 SwigcptrBB) B() { + _swig_wrap_BB_b(arg1) +} + +var _wrap_new_BB unsafe.Pointer + +func _swig_wrap_new_BB() (base SwigcptrBB) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_BB, _swig_p) + return +} + +func NewBB() (_swig_ret BB) { + return _swig_wrap_new_BB() +} + +var _wrap_delete_BB unsafe.Pointer + +func _swig_wrap_delete_BB(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_BB, _swig_p) + return +} + +func DeleteBB(arg1 BB) { + _swig_wrap_delete_BB(arg1.Swigcptr()) +} + +type BB interface { + Swigcptr() uintptr + SwigIsBB() + B() +} + +type SwigcptrBBB uintptr + +func (p SwigcptrBBB) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrBBB) SwigIsBBB() { +} + +var _wrap_BBB_b unsafe.Pointer + +func _swig_wrap_BBB_b(base SwigcptrBBB) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_BBB_b, _swig_p) + return +} + +func (arg1 SwigcptrBBB) B() { + _swig_wrap_BBB_b(arg1) +} + +var _wrap_new_BBB unsafe.Pointer + +func _swig_wrap_new_BBB() (base SwigcptrBBB) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_BBB, _swig_p) + return +} + +func NewBBB() (_swig_ret BBB) { + return _swig_wrap_new_BBB() +} + +var _wrap_delete_BBB unsafe.Pointer + +func _swig_wrap_delete_BBB(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_BBB, _swig_p) + return +} + +func DeleteBBB(arg1 BBB) { + _swig_wrap_delete_BBB(arg1.Swigcptr()) +} + +type BBB interface { + Swigcptr() uintptr + SwigIsBBB() + B() +} + +type SwigcptrBBBB uintptr + +func (p SwigcptrBBBB) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrBBBB) SwigIsBBBB() { +} + +var _wrap_BBBB_b unsafe.Pointer + +func _swig_wrap_BBBB_b(base SwigcptrBBBB) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_BBBB_b, _swig_p) + return +} + +func (arg1 SwigcptrBBBB) B() { + _swig_wrap_BBBB_b(arg1) +} + +var _wrap_new_BBBB unsafe.Pointer + +func _swig_wrap_new_BBBB() (base SwigcptrBBBB) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_BBBB, _swig_p) + return +} + +func NewBBBB() (_swig_ret BBBB) { + return _swig_wrap_new_BBBB() +} + +var _wrap_delete_BBBB unsafe.Pointer + +func _swig_wrap_delete_BBBB(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_BBBB, _swig_p) + return +} + +func DeleteBBBB(arg1 BBBB) { + _swig_wrap_delete_BBBB(arg1.Swigcptr()) +} + +type BBBB interface { + Swigcptr() uintptr + SwigIsBBBB() + B() +} + +type SwigcptrBBBBB uintptr + +func (p SwigcptrBBBBB) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrBBBBB) SwigIsBBBBB() { +} + +var _wrap_BBBBB_b unsafe.Pointer + +func _swig_wrap_BBBBB_b(base SwigcptrBBBBB) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_BBBBB_b, _swig_p) + return +} + +func (arg1 SwigcptrBBBBB) B() { + _swig_wrap_BBBBB_b(arg1) +} + +var _wrap_new_BBBBB unsafe.Pointer + +func _swig_wrap_new_BBBBB() (base SwigcptrBBBBB) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_BBBBB, _swig_p) + return +} + +func NewBBBBB() (_swig_ret BBBBB) { + return _swig_wrap_new_BBBBB() +} + +var _wrap_delete_BBBBB unsafe.Pointer + +func _swig_wrap_delete_BBBBB(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_BBBBB, _swig_p) + return +} + +func DeleteBBBBB(arg1 BBBBB) { + _swig_wrap_delete_BBBBB(arg1.Swigcptr()) +} + +type BBBBB interface { + Swigcptr() uintptr + SwigIsBBBBB() + B() +} + +type SwigcptrB1 uintptr + +func (p SwigcptrB1) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrB1) SwigIsB1() { +} + +var _wrap_B1_b unsafe.Pointer + +func _swig_wrap_B1_b(base SwigcptrB1) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_B1_b, _swig_p) + return +} + +func (arg1 SwigcptrB1) B() { + _swig_wrap_B1_b(arg1) +} + +var _wrap_new_B1 unsafe.Pointer + +func _swig_wrap_new_B1() (base SwigcptrB1) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_B1, _swig_p) + return +} + +func NewB1() (_swig_ret B1) { + return _swig_wrap_new_B1() +} + +var _wrap_delete_B1 unsafe.Pointer + +func _swig_wrap_delete_B1(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_B1, _swig_p) + return +} + +func DeleteB1(arg1 B1) { + _swig_wrap_delete_B1(arg1.Swigcptr()) +} + +type B1 interface { + Swigcptr() uintptr + SwigIsB1() + B() +} + +type SwigcptrB2 uintptr + +func (p SwigcptrB2) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrB2) SwigIsB2() { +} + +var _wrap_B2_b unsafe.Pointer + +func _swig_wrap_B2_b(base SwigcptrB2) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_B2_b, _swig_p) + return +} + +func (arg1 SwigcptrB2) B() { + _swig_wrap_B2_b(arg1) +} + +var _wrap_new_B2 unsafe.Pointer + +func _swig_wrap_new_B2() (base SwigcptrB2) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_B2, _swig_p) + return +} + +func NewB2() (_swig_ret B2) { + return _swig_wrap_new_B2() +} + +var _wrap_delete_B2 unsafe.Pointer + +func _swig_wrap_delete_B2(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_B2, _swig_p) + return +} + +func DeleteB2(arg1 B2) { + _swig_wrap_delete_B2(arg1.Swigcptr()) +} + +type B2 interface { + Swigcptr() uintptr + SwigIsB2() + B() +} + +type SwigcptrB3 uintptr + +func (p SwigcptrB3) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrB3) SwigIsB3() { +} + +var _wrap_B3_b unsafe.Pointer + +func _swig_wrap_B3_b(base SwigcptrB3) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_B3_b, _swig_p) + return +} + +func (arg1 SwigcptrB3) B() { + _swig_wrap_B3_b(arg1) +} + +var _wrap_new_B3 unsafe.Pointer + +func _swig_wrap_new_B3() (base SwigcptrB3) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_B3, _swig_p) + return +} + +func NewB3() (_swig_ret B3) { + return _swig_wrap_new_B3() +} + +var _wrap_delete_B3 unsafe.Pointer + +func _swig_wrap_delete_B3(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_B3, _swig_p) + return +} + +func DeleteB3(arg1 B3) { + _swig_wrap_delete_B3(arg1.Swigcptr()) +} + +type B3 interface { + Swigcptr() uintptr + SwigIsB3() + B() +} + +type SwigcptrB4 uintptr + +func (p SwigcptrB4) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrB4) SwigIsB4() { +} + +var _wrap_B4_b unsafe.Pointer + +func _swig_wrap_B4_b(base SwigcptrB4) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_B4_b, _swig_p) + return +} + +func (arg1 SwigcptrB4) B() { + _swig_wrap_B4_b(arg1) +} + +var _wrap_new_B4 unsafe.Pointer + +func _swig_wrap_new_B4() (base SwigcptrB4) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_B4, _swig_p) + return +} + +func NewB4() (_swig_ret B4) { + return _swig_wrap_new_B4() +} + +var _wrap_delete_B4 unsafe.Pointer + +func _swig_wrap_delete_B4(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_B4, _swig_p) + return +} + +func DeleteB4(arg1 B4) { + _swig_wrap_delete_B4(arg1.Swigcptr()) +} + +type B4 interface { + Swigcptr() uintptr + SwigIsB4() + B() +} + +type SwigcptrConcrete uintptr + +func (p SwigcptrConcrete) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrConcrete) SwigIsConcrete() { +} + +var _wrap_new_Concrete unsafe.Pointer + +func _swig_wrap_new_Concrete() (base SwigcptrConcrete) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Concrete, _swig_p) + return +} + +func NewConcrete() (_swig_ret Concrete) { + return _swig_wrap_new_Concrete() +} + +var _wrap_delete_Concrete unsafe.Pointer + +func _swig_wrap_delete_Concrete(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Concrete, _swig_p) + return +} + +func DeleteConcrete(arg1 Concrete) { + _swig_wrap_delete_Concrete(arg1.Swigcptr()) +} + +type Concrete interface { + Swigcptr() uintptr + SwigIsConcrete() +} + +type SwigcptrA_ uintptr + +func (p SwigcptrA_) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrA_) SwigIsA_() { +} + +var _wrap_A__a unsafe.Pointer + +func _swig_wrap_A__a(base SwigcptrA_) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_A__a, _swig_p) + return +} + +func (arg1 SwigcptrA_) A() { + _swig_wrap_A__a(arg1) +} + +var _wrap_new_A_ unsafe.Pointer + +func _swig_wrap_new_A_() (base SwigcptrA_) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_A_, _swig_p) + return +} + +func NewA_() (_swig_ret A_) { + return _swig_wrap_new_A_() +} + +var _wrap_delete_A_ unsafe.Pointer + +func _swig_wrap_delete_A_(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_A_, _swig_p) + return +} + +func DeleteA_(arg1 A_) { + _swig_wrap_delete_A_(arg1.Swigcptr()) +} + +type A_ interface { + Swigcptr() uintptr + SwigIsA_() + A() +} + +type SwigcptrB_ uintptr + +func (p SwigcptrB_) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrB_) SwigIsB_() { +} + +var _wrap_B__b unsafe.Pointer + +func _swig_wrap_B__b(base SwigcptrB_) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_B__b, _swig_p) + return +} + +func (arg1 SwigcptrB_) B() { + _swig_wrap_B__b(arg1) +} + +var _wrap_new_B_ unsafe.Pointer + +func _swig_wrap_new_B_() (base SwigcptrB_) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_B_, _swig_p) + return +} + +func NewB_() (_swig_ret B_) { + return _swig_wrap_new_B_() +} + +var _wrap_delete_B_ unsafe.Pointer + +func _swig_wrap_delete_B_(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_B_, _swig_p) + return +} + +func DeleteB_(arg1 B_) { + _swig_wrap_delete_B_(arg1.Swigcptr()) +} + +type B_ interface { + Swigcptr() uintptr + SwigIsB_() + B() +} + +type SwigcptrC_ uintptr + +func (p SwigcptrC_) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrC_) SwigIsC_() { +} + +var _wrap_C__c unsafe.Pointer + +func _swig_wrap_C__c(base SwigcptrC_) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_C__c, _swig_p) + return +} + +func (arg1 SwigcptrC_) C() { + _swig_wrap_C__c(arg1) +} + +var _wrap_new_C_ unsafe.Pointer + +func _swig_wrap_new_C_() (base SwigcptrC_) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_C_, _swig_p) + return +} + +func NewC_() (_swig_ret C_) { + return _swig_wrap_new_C_() +} + +var _wrap_delete_C_ unsafe.Pointer + +func _swig_wrap_delete_C_(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_C_, _swig_p) + return +} + +func DeleteC_(arg1 C_) { + _swig_wrap_delete_C_(arg1.Swigcptr()) +} + +type C_ interface { + Swigcptr() uintptr + SwigIsC_() + C() +} + +type SwigcptrD_ uintptr + +func (p SwigcptrD_) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrD_) SwigIsD_() { +} + +var _wrap_D__d unsafe.Pointer + +func _swig_wrap_D__d(base SwigcptrD_) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_D__d, _swig_p) + return +} + +func (arg1 SwigcptrD_) D() { + _swig_wrap_D__d(arg1) +} + +var _wrap_new_D_ unsafe.Pointer + +func _swig_wrap_new_D_() (base SwigcptrD_) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_D_, _swig_p) + return +} + +func NewD_() (_swig_ret D_) { + return _swig_wrap_new_D_() +} + +var _wrap_delete_D_ unsafe.Pointer + +func _swig_wrap_delete_D_(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_D_, _swig_p) + return +} + +func DeleteD_(arg1 D_) { + _swig_wrap_delete_D_(arg1.Swigcptr()) +} + +type D_ interface { + Swigcptr() uintptr + SwigIsD_() + D() +} + +type SwigcptrE_ uintptr + +func (p SwigcptrE_) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrE_) SwigIsE_() { +} + +var _wrap_E__e unsafe.Pointer + +func _swig_wrap_E__e(base SwigcptrE_) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_E__e, _swig_p) + return +} + +func (arg1 SwigcptrE_) E() { + _swig_wrap_E__e(arg1) +} + +var _wrap_new_E_ unsafe.Pointer + +func _swig_wrap_new_E_() (base SwigcptrE_) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_E_, _swig_p) + return +} + +func NewE_() (_swig_ret E_) { + return _swig_wrap_new_E_() +} + +var _wrap_delete_E_ unsafe.Pointer + +func _swig_wrap_delete_E_(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_E_, _swig_p) + return +} + +func DeleteE_(arg1 E_) { + _swig_wrap_delete_E_(arg1.Swigcptr()) +} + +type E_ interface { + Swigcptr() uintptr + SwigIsE_() + E() +} + +type SwigcptrF_ uintptr + +func (p SwigcptrF_) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrF_) SwigIsF_() { +} + +var _wrap_F__f unsafe.Pointer + +func _swig_wrap_F__f(base SwigcptrF_) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_F__f, _swig_p) + return +} + +func (arg1 SwigcptrF_) F() { + _swig_wrap_F__f(arg1) +} + +var _wrap_new_F_ unsafe.Pointer + +func _swig_wrap_new_F_() (base SwigcptrF_) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_F_, _swig_p) + return +} + +func NewF_() (_swig_ret F_) { + return _swig_wrap_new_F_() +} + +var _wrap_delete_F_ unsafe.Pointer + +func _swig_wrap_delete_F_(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_F_, _swig_p) + return +} + +func DeleteF_(arg1 F_) { + _swig_wrap_delete_F_(arg1.Swigcptr()) +} + +type F_ interface { + Swigcptr() uintptr + SwigIsF_() + F() +} + +type SwigcptrG_ uintptr + +func (p SwigcptrG_) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrG_) SwigIsG_() { +} + +var _wrap_G__g unsafe.Pointer + +func _swig_wrap_G__g(base SwigcptrG_) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_G__g, _swig_p) + return +} + +func (arg1 SwigcptrG_) G() { + _swig_wrap_G__g(arg1) +} + +var _wrap_new_G_ unsafe.Pointer + +func _swig_wrap_new_G_() (base SwigcptrG_) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_G_, _swig_p) + return +} + +func NewG_() (_swig_ret G_) { + return _swig_wrap_new_G_() +} + +var _wrap_delete_G_ unsafe.Pointer + +func _swig_wrap_delete_G_(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_G_, _swig_p) + return +} + +func DeleteG_(arg1 G_) { + _swig_wrap_delete_G_(arg1.Swigcptr()) +} + +type G_ interface { + Swigcptr() uintptr + SwigIsG_() + G() +} + +type SwigcptrC1_ uintptr + +func (p SwigcptrC1_) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrC1_) SwigIsC1_() { +} + +var _wrap_C1__c unsafe.Pointer + +func _swig_wrap_C1__c(base SwigcptrC1_) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_C1__c, _swig_p) + return +} + +func (arg1 SwigcptrC1_) C() { + _swig_wrap_C1__c(arg1) +} + +var _wrap_new_C1_ unsafe.Pointer + +func _swig_wrap_new_C1_() (base SwigcptrC1_) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_C1_, _swig_p) + return +} + +func NewC1_() (_swig_ret C1_) { + return _swig_wrap_new_C1_() +} + +var _wrap_delete_C1_ unsafe.Pointer + +func _swig_wrap_delete_C1_(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_C1_, _swig_p) + return +} + +func DeleteC1_(arg1 C1_) { + _swig_wrap_delete_C1_(arg1.Swigcptr()) +} + +type C1_ interface { + Swigcptr() uintptr + SwigIsC1_() + C() +} + +type SwigcptrC2_ uintptr + +func (p SwigcptrC2_) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrC2_) SwigIsC2_() { +} + +var _wrap_C2__c unsafe.Pointer + +func _swig_wrap_C2__c(base SwigcptrC2_) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_C2__c, _swig_p) + return +} + +func (arg1 SwigcptrC2_) C() { + _swig_wrap_C2__c(arg1) +} + +var _wrap_new_C2_ unsafe.Pointer + +func _swig_wrap_new_C2_() (base SwigcptrC2_) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_C2_, _swig_p) + return +} + +func NewC2_() (_swig_ret C2_) { + return _swig_wrap_new_C2_() +} + +var _wrap_delete_C2_ unsafe.Pointer + +func _swig_wrap_delete_C2_(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_C2_, _swig_p) + return +} + +func DeleteC2_(arg1 C2_) { + _swig_wrap_delete_C2_(arg1.Swigcptr()) +} + +type C2_ interface { + Swigcptr() uintptr + SwigIsC2_() + C() +} + +type SwigcptrC3_ uintptr + +func (p SwigcptrC3_) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrC3_) SwigIsC3_() { +} + +var _wrap_C3__c unsafe.Pointer + +func _swig_wrap_C3__c(base SwigcptrC3_) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_C3__c, _swig_p) + return +} + +func (arg1 SwigcptrC3_) C() { + _swig_wrap_C3__c(arg1) +} + +var _wrap_new_C3_ unsafe.Pointer + +func _swig_wrap_new_C3_() (base SwigcptrC3_) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_C3_, _swig_p) + return +} + +func NewC3_() (_swig_ret C3_) { + return _swig_wrap_new_C3_() +} + +var _wrap_delete_C3_ unsafe.Pointer + +func _swig_wrap_delete_C3_(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_C3_, _swig_p) + return +} + +func DeleteC3_(arg1 C3_) { + _swig_wrap_delete_C3_(arg1.Swigcptr()) +} + +type C3_ interface { + Swigcptr() uintptr + SwigIsC3_() + C() +} + +type SwigcptrC4_ uintptr + +func (p SwigcptrC4_) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrC4_) SwigIsC4_() { +} + +var _wrap_C4__c unsafe.Pointer + +func _swig_wrap_C4__c(base SwigcptrC4_) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_C4__c, _swig_p) + return +} + +func (arg1 SwigcptrC4_) C() { + _swig_wrap_C4__c(arg1) +} + +var _wrap_new_C4_ unsafe.Pointer + +func _swig_wrap_new_C4_() (base SwigcptrC4_) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_C4_, _swig_p) + return +} + +func NewC4_() (_swig_ret C4_) { + return _swig_wrap_new_C4_() +} + +var _wrap_delete_C4_ unsafe.Pointer + +func _swig_wrap_delete_C4_(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_C4_, _swig_p) + return +} + +func DeleteC4_(arg1 C4_) { + _swig_wrap_delete_C4_(arg1.Swigcptr()) +} + +type C4_ interface { + Swigcptr() uintptr + SwigIsC4_() + C() +} + +type SwigcptrB1_ uintptr + +func (p SwigcptrB1_) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrB1_) SwigIsB1_() { +} + +var _wrap_B1__b unsafe.Pointer + +func _swig_wrap_B1__b(base SwigcptrB1_) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_B1__b, _swig_p) + return +} + +func (arg1 SwigcptrB1_) B() { + _swig_wrap_B1__b(arg1) +} + +var _wrap_new_B1_ unsafe.Pointer + +func _swig_wrap_new_B1_() (base SwigcptrB1_) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_B1_, _swig_p) + return +} + +func NewB1_() (_swig_ret B1_) { + return _swig_wrap_new_B1_() +} + +var _wrap_delete_B1_ unsafe.Pointer + +func _swig_wrap_delete_B1_(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_B1_, _swig_p) + return +} + +func DeleteB1_(arg1 B1_) { + _swig_wrap_delete_B1_(arg1.Swigcptr()) +} + +type B1_ interface { + Swigcptr() uintptr + SwigIsB1_() + B() +} + +type SwigcptrE1_ uintptr + +func (p SwigcptrE1_) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrE1_) SwigIsE1_() { +} + +var _wrap_E1__e unsafe.Pointer + +func _swig_wrap_E1__e(base SwigcptrE1_) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_E1__e, _swig_p) + return +} + +func (arg1 SwigcptrE1_) E() { + _swig_wrap_E1__e(arg1) +} + +var _wrap_new_E1_ unsafe.Pointer + +func _swig_wrap_new_E1_() (base SwigcptrE1_) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_E1_, _swig_p) + return +} + +func NewE1_() (_swig_ret E1_) { + return _swig_wrap_new_E1_() +} + +var _wrap_delete_E1_ unsafe.Pointer + +func _swig_wrap_delete_E1_(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_E1_, _swig_p) + return +} + +func DeleteE1_(arg1 E1_) { + _swig_wrap_delete_E1_(arg1.Swigcptr()) +} + +type E1_ interface { + Swigcptr() uintptr + SwigIsE1_() + E() +} + +type SwigcptrE2_ uintptr + +func (p SwigcptrE2_) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrE2_) SwigIsE2_() { +} + +var _wrap_E2__e unsafe.Pointer + +func _swig_wrap_E2__e(base SwigcptrE2_) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_E2__e, _swig_p) + return +} + +func (arg1 SwigcptrE2_) E() { + _swig_wrap_E2__e(arg1) +} + +var _wrap_new_E2_ unsafe.Pointer + +func _swig_wrap_new_E2_() (base SwigcptrE2_) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_E2_, _swig_p) + return +} + +func NewE2_() (_swig_ret E2_) { + return _swig_wrap_new_E2_() +} + +var _wrap_delete_E2_ unsafe.Pointer + +func _swig_wrap_delete_E2_(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_E2_, _swig_p) + return +} + +func DeleteE2_(arg1 E2_) { + _swig_wrap_delete_E2_(arg1.Swigcptr()) +} + +type E2_ interface { + Swigcptr() uintptr + SwigIsE2_() + E() +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/template_qualifier.go b/Examples/test-suite/go/template_qualifier.go new file mode 100644 index 000000000..4549d2f69 --- /dev/null +++ b/Examples/test-suite/go/template_qualifier.go @@ -0,0 +1,88 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../template_qualifier.i + +package template_qualifier + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrX uintptr + +func (p SwigcptrX) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrX) SwigIsX() { +} + +var _wrap_X_xalloc_int unsafe.Pointer + +func _swig_wrap_X_xalloc_int(base SwigcptrX) (_ SwigcptrX) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_X_xalloc_int, _swig_p) + return +} + +func (arg1 SwigcptrX) Xalloc_int() (_swig_ret X) { + return _swig_wrap_X_xalloc_int(arg1) +} + +var _wrap_new_X unsafe.Pointer + +func _swig_wrap_new_X() (base SwigcptrX) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_X, _swig_p) + return +} + +func NewX() (_swig_ret X) { + return _swig_wrap_new_X() +} + +var _wrap_delete_X unsafe.Pointer + +func _swig_wrap_delete_X(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_X, _swig_p) + return +} + +func DeleteX(arg1 X) { + _swig_wrap_delete_X(arg1.Swigcptr()) +} + +type X interface { + Swigcptr() uintptr + SwigIsX() + Xalloc_int() (_swig_ret X) +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/template_ref_type.go b/Examples/test-suite/go/template_ref_type.go new file mode 100644 index 000000000..53ea6bfd1 --- /dev/null +++ b/Examples/test-suite/go/template_ref_type.go @@ -0,0 +1,203 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../template_ref_type.i + +package template_ref_type + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrX uintptr + +func (p SwigcptrX) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrX) SwigIsX() { +} + +var _wrap_X__i_set unsafe.Pointer + +func _swig_wrap_X__i_set(base SwigcptrX, _ uint) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_X__i_set, _swig_p) + return +} + +func (arg1 SwigcptrX) SetX_i(arg2 uint) { + _swig_wrap_X__i_set(arg1, arg2) +} + +var _wrap_X__i_get unsafe.Pointer + +func _swig_wrap_X__i_get(base SwigcptrX) (_ uint) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_X__i_get, _swig_p) + return +} + +func (arg1 SwigcptrX) GetX_i() (_swig_ret uint) { + return _swig_wrap_X__i_get(arg1) +} + +var _wrap_new_X unsafe.Pointer + +func _swig_wrap_new_X() (base SwigcptrX) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_X, _swig_p) + return +} + +func NewX() (_swig_ret X) { + return _swig_wrap_new_X() +} + +var _wrap_delete_X unsafe.Pointer + +func _swig_wrap_delete_X(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_X, _swig_p) + return +} + +func DeleteX(arg1 X) { + _swig_wrap_delete_X(arg1.Swigcptr()) +} + +type X interface { + Swigcptr() uintptr + SwigIsX() + SetX_i(arg2 uint) + GetX_i() (_swig_ret uint) +} + +type SwigcptrXC uintptr + +func (p SwigcptrXC) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrXC) SwigIsXC() { +} + +var _wrap_new_XC unsafe.Pointer + +func _swig_wrap_new_XC() (base SwigcptrXC) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_XC, _swig_p) + return +} + +func NewXC() (_swig_ret XC) { + return _swig_wrap_new_XC() +} + +var _wrap_XC_reset unsafe.Pointer + +func _swig_wrap_XC_reset(base SwigcptrXC) (_ bool) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_XC_reset, _swig_p) + return +} + +func (arg1 SwigcptrXC) Reset() (_swig_ret bool) { + return _swig_wrap_XC_reset(arg1) +} + +var _wrap_delete_XC unsafe.Pointer + +func _swig_wrap_delete_XC(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_XC, _swig_p) + return +} + +func DeleteXC(arg1 XC) { + _swig_wrap_delete_XC(arg1.Swigcptr()) +} + +type XC interface { + Swigcptr() uintptr + SwigIsXC() + Reset() (_swig_ret bool) +} + +type SwigcptrY uintptr + +func (p SwigcptrY) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrY) SwigIsY() { +} + +var _wrap_new_Y unsafe.Pointer + +func _swig_wrap_new_Y() (base SwigcptrY) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Y, _swig_p) + return +} + +func NewY() (_swig_ret Y) { + return _swig_wrap_new_Y() +} + +var _wrap_Y_find unsafe.Pointer + +func _swig_wrap_Y_find(base SwigcptrY, _ uintptr) (_ bool) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Y_find, _swig_p) + return +} + +func (arg1 SwigcptrY) Find(arg2 XC) (_swig_ret bool) { + return _swig_wrap_Y_find(arg1, arg2.Swigcptr()) +} + +var _wrap_delete_Y unsafe.Pointer + +func _swig_wrap_delete_Y(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Y, _swig_p) + return +} + +func DeleteY(arg1 Y) { + _swig_wrap_delete_Y(arg1.Swigcptr()) +} + +type Y interface { + Swigcptr() uintptr + SwigIsY() + Find(arg2 XC) (_swig_ret bool) +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/template_ref_type_runme b/Examples/test-suite/go/template_ref_type_runme new file mode 100755 index 000000000..439d6a507 Binary files /dev/null and b/Examples/test-suite/go/template_ref_type_runme differ diff --git a/Examples/test-suite/go/template_rename.go b/Examples/test-suite/go/template_rename.go new file mode 100644 index 000000000..18490cbab --- /dev/null +++ b/Examples/test-suite/go/template_rename.go @@ -0,0 +1,267 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../template_rename.i + +package template_rename + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrIFoo uintptr + +func (p SwigcptrIFoo) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrIFoo) SwigIsIFoo() { +} + +var _wrap_iFoo_blah_test unsafe.Pointer + +func _swig_wrap_iFoo_blah_test(base SwigcptrIFoo, _ int) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_iFoo_blah_test, _swig_p) + return +} + +func (arg1 SwigcptrIFoo) Blah_test(arg2 int) (_swig_ret int) { + return _swig_wrap_iFoo_blah_test(arg1, arg2) +} + +var _wrap_iFoo_spam_test unsafe.Pointer + +func _swig_wrap_iFoo_spam_test(base SwigcptrIFoo, _ int) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_iFoo_spam_test, _swig_p) + return +} + +func (arg1 SwigcptrIFoo) Spam_test(arg2 int) (_swig_ret int) { + return _swig_wrap_iFoo_spam_test(arg1, arg2) +} + +var _wrap_iFoo_groki_test unsafe.Pointer + +func _swig_wrap_iFoo_groki_test(base SwigcptrIFoo, _ int) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_iFoo_groki_test, _swig_p) + return +} + +func (arg1 SwigcptrIFoo) Groki_test(arg2 int) (_swig_ret int) { + return _swig_wrap_iFoo_groki_test(arg1, arg2) +} + +var _wrap_new_iFoo unsafe.Pointer + +func _swig_wrap_new_iFoo() (base SwigcptrIFoo) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_iFoo, _swig_p) + return +} + +func NewIFoo() (_swig_ret IFoo) { + return _swig_wrap_new_iFoo() +} + +var _wrap_delete_iFoo unsafe.Pointer + +func _swig_wrap_delete_iFoo(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_iFoo, _swig_p) + return +} + +func DeleteIFoo(arg1 IFoo) { + _swig_wrap_delete_iFoo(arg1.Swigcptr()) +} + +type IFoo interface { + Swigcptr() uintptr + SwigIsIFoo() + Blah_test(arg2 int) (_swig_ret int) + Spam_test(arg2 int) (_swig_ret int) + Groki_test(arg2 int) (_swig_ret int) +} + +type SwigcptrDFoo uintptr + +func (p SwigcptrDFoo) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrDFoo) SwigIsDFoo() { +} + +var _wrap_dFoo_blah_test unsafe.Pointer + +func _swig_wrap_dFoo_blah_test(base SwigcptrDFoo, _ int) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_dFoo_blah_test, _swig_p) + return +} + +func (arg1 SwigcptrDFoo) Blah_test(arg2 int) (_swig_ret int) { + return _swig_wrap_dFoo_blah_test(arg1, arg2) +} + +var _wrap_dFoo_spam unsafe.Pointer + +func _swig_wrap_dFoo_spam(base SwigcptrDFoo, _ int) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_dFoo_spam, _swig_p) + return +} + +func (arg1 SwigcptrDFoo) Spam(arg2 int) (_swig_ret int) { + return _swig_wrap_dFoo_spam(arg1, arg2) +} + +var _wrap_dFoo_grok_test unsafe.Pointer + +func _swig_wrap_dFoo_grok_test(base SwigcptrDFoo, _ int) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_dFoo_grok_test, _swig_p) + return +} + +func (arg1 SwigcptrDFoo) Grok_test(arg2 int) (_swig_ret int) { + return _swig_wrap_dFoo_grok_test(arg1, arg2) +} + +var _wrap_new_dFoo unsafe.Pointer + +func _swig_wrap_new_dFoo() (base SwigcptrDFoo) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_dFoo, _swig_p) + return +} + +func NewDFoo() (_swig_ret DFoo) { + return _swig_wrap_new_dFoo() +} + +var _wrap_delete_dFoo unsafe.Pointer + +func _swig_wrap_delete_dFoo(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_dFoo, _swig_p) + return +} + +func DeleteDFoo(arg1 DFoo) { + _swig_wrap_delete_dFoo(arg1.Swigcptr()) +} + +type DFoo interface { + Swigcptr() uintptr + SwigIsDFoo() + Blah_test(arg2 int) (_swig_ret int) + Spam(arg2 int) (_swig_ret int) + Grok_test(arg2 int) (_swig_ret int) +} + +type SwigcptrFlow uintptr + +func (p SwigcptrFlow) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrFlow) SwigIsFlow() { +} + +var _wrap_new_Flow unsafe.Pointer + +func _swig_wrap_new_Flow(base float64) (_ SwigcptrFlow) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Flow, _swig_p) + return +} + +func NewFlow(arg1 float64) (_swig_ret Flow) { + return _swig_wrap_new_Flow(arg1) +} + +var _wrap_delete_Flow unsafe.Pointer + +func _swig_wrap_delete_Flow(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Flow, _swig_p) + return +} + +func DeleteFlow(arg1 Flow) { + _swig_wrap_delete_Flow(arg1.Swigcptr()) +} + +type Flow interface { + Swigcptr() uintptr + SwigIsFlow() +} + +type SwigcptrVectFlow uintptr + +func (p SwigcptrVectFlow) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrVectFlow) SwigIsVectFlow() { +} + +var _wrap_new_VectFlow unsafe.Pointer + +func _swig_wrap_new_VectFlow() (base SwigcptrVectFlow) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_VectFlow, _swig_p) + return +} + +func NewVectFlow() (_swig_ret VectFlow) { + return _swig_wrap_new_VectFlow() +} + +var _wrap_delete_VectFlow unsafe.Pointer + +func _swig_wrap_delete_VectFlow(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_VectFlow, _swig_p) + return +} + +func DeleteVectFlow(arg1 VectFlow) { + _swig_wrap_delete_VectFlow(arg1.Swigcptr()) +} + +type VectFlow interface { + Swigcptr() uintptr + SwigIsVectFlow() +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/template_rename_runme b/Examples/test-suite/go/template_rename_runme new file mode 100755 index 000000000..0d8a6626d Binary files /dev/null and b/Examples/test-suite/go/template_rename_runme differ diff --git a/Examples/test-suite/go/template_retvalue.go b/Examples/test-suite/go/template_retvalue.go new file mode 100644 index 000000000..10e6c29d7 --- /dev/null +++ b/Examples/test-suite/go/template_retvalue.go @@ -0,0 +1,202 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../template_retvalue.i + +package template_retvalue + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type Hello int +var _wrap_Hi unsafe.Pointer + +func _swig_getHi() (_swig_ret Hello) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_Hi, _swig_p) + return +} +var Hi Hello = _swig_getHi() +var _wrap_Hola unsafe.Pointer + +func _swig_getHola() (_swig_ret Hello) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_Hola, _swig_p) + return +} +var Hola Hello = _swig_getHola() +type SwigcptrC uintptr + +func (p SwigcptrC) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrC) SwigIsC() { +} + +var _wrap_new_C unsafe.Pointer + +func _swig_wrap_new_C(base int) (_ SwigcptrC) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_C, _swig_p) + return +} + +func NewC(arg1 int) (_swig_ret C) { + return _swig_wrap_new_C(arg1) +} + +var _wrap_delete_C unsafe.Pointer + +func _swig_wrap_delete_C(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_C, _swig_p) + return +} + +func DeleteC(arg1 C) { + _swig_wrap_delete_C(arg1.Swigcptr()) +} + +type C interface { + Swigcptr() uintptr + SwigIsC() +} + +type SwigcptrA_Hi uintptr + +func (p SwigcptrA_Hi) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrA_Hi) SwigIsA_Hi() { +} + +var _wrap_new_A_Hi unsafe.Pointer + +func _swig_wrap_new_A_Hi(base int) (_ SwigcptrA_Hi) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_A_Hi, _swig_p) + return +} + +func NewA_Hi(arg1 int) (_swig_ret A_Hi) { + return _swig_wrap_new_A_Hi(arg1) +} + +var _wrap_delete_A_Hi unsafe.Pointer + +func _swig_wrap_delete_A_Hi(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_A_Hi, _swig_p) + return +} + +func DeleteA_Hi(arg1 A_Hi) { + _swig_wrap_delete_A_Hi(arg1.Swigcptr()) +} + +type A_Hi interface { + Swigcptr() uintptr + SwigIsA_Hi() +} + +type SwigcptrB_Hola uintptr + +func (p SwigcptrB_Hola) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrB_Hola) SwigIsB_Hola() { +} + +var _wrap_B_Hola_get_c unsafe.Pointer + +func _swig_wrap_B_Hola_get_c(base SwigcptrB_Hola) (_ SwigcptrC) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_B_Hola_get_c, _swig_p) + return +} + +func (arg1 SwigcptrB_Hola) Get_c() (_swig_ret C) { + return _swig_wrap_B_Hola_get_c(arg1) +} + +var _wrap_B_Hola_get_a unsafe.Pointer + +func _swig_wrap_B_Hola_get_a(base SwigcptrB_Hola) (_ SwigcptrA_Sl_Hola_Sg_) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_B_Hola_get_a, _swig_p) + return +} + +func (arg1 SwigcptrB_Hola) Get_a() (_swig_ret A_Sl_Hola_Sg_) { + return _swig_wrap_B_Hola_get_a(arg1) +} + +var _wrap_new_B_Hola unsafe.Pointer + +func _swig_wrap_new_B_Hola() (base SwigcptrB_Hola) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_B_Hola, _swig_p) + return +} + +func NewB_Hola() (_swig_ret B_Hola) { + return _swig_wrap_new_B_Hola() +} + +var _wrap_delete_B_Hola unsafe.Pointer + +func _swig_wrap_delete_B_Hola(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_B_Hola, _swig_p) + return +} + +func DeleteB_Hola(arg1 B_Hola) { + _swig_wrap_delete_B_Hola(arg1.Swigcptr()) +} + +type B_Hola interface { + Swigcptr() uintptr + SwigIsB_Hola() + Get_c() (_swig_ret C) + Get_a() (_swig_ret A_Sl_Hola_Sg_) +} + + +type SwigcptrA_Sl_Hola_Sg_ uintptr +type A_Sl_Hola_Sg_ interface { + Swigcptr() uintptr; +} +func (p SwigcptrA_Sl_Hola_Sg_) Swigcptr() uintptr { + return uintptr(p) +} + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/template_specialization.go b/Examples/test-suite/go/template_specialization.go new file mode 100644 index 000000000..6b7a26fc6 --- /dev/null +++ b/Examples/test-suite/go/template_specialization.go @@ -0,0 +1,152 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../template_specialization.i + +package template_specialization + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrUnaryFunction_double uintptr + +func (p SwigcptrUnaryFunction_double) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrUnaryFunction_double) SwigIsUnaryFunction_double() { +} + +var _wrap_UnaryFunction_double_negate unsafe.Pointer + +func _swig_wrap_UnaryFunction_double_negate(base SwigcptrUnaryFunction_double) (_ SwigcptrUnaryFunction_double) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_UnaryFunction_double_negate, _swig_p) + return +} + +func (arg1 SwigcptrUnaryFunction_double) Negate() (_swig_ret UnaryFunction_double) { + return _swig_wrap_UnaryFunction_double_negate(arg1) +} + +var _wrap_new_UnaryFunction_double unsafe.Pointer + +func _swig_wrap_new_UnaryFunction_double() (base SwigcptrUnaryFunction_double) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_UnaryFunction_double, _swig_p) + return +} + +func NewUnaryFunction_double() (_swig_ret UnaryFunction_double) { + return _swig_wrap_new_UnaryFunction_double() +} + +var _wrap_delete_UnaryFunction_double unsafe.Pointer + +func _swig_wrap_delete_UnaryFunction_double(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_UnaryFunction_double, _swig_p) + return +} + +func DeleteUnaryFunction_double(arg1 UnaryFunction_double) { + _swig_wrap_delete_UnaryFunction_double(arg1.Swigcptr()) +} + +type UnaryFunction_double interface { + Swigcptr() uintptr + SwigIsUnaryFunction_double() + Negate() (_swig_ret UnaryFunction_double) +} + +type SwigcptrUnaryFunction_bool uintptr + +func (p SwigcptrUnaryFunction_bool) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrUnaryFunction_bool) SwigIsUnaryFunction_bool() { +} + +var _wrap_UnaryFunction_bool_not1 unsafe.Pointer + +func _swig_wrap_UnaryFunction_bool_not1(base SwigcptrUnaryFunction_bool) (_ SwigcptrUnaryFunction_bool) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_UnaryFunction_bool_not1, _swig_p) + return +} + +func (arg1 SwigcptrUnaryFunction_bool) Not1() (_swig_ret UnaryFunction_bool) { + return _swig_wrap_UnaryFunction_bool_not1(arg1) +} + +var _wrap_UnaryFunction_bool_foo unsafe.Pointer + +func _swig_wrap_UnaryFunction_bool_foo(base SwigcptrUnaryFunction_bool, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_UnaryFunction_bool_foo, _swig_p) + return +} + +func (arg1 SwigcptrUnaryFunction_bool) Foo(arg2 UnaryFunction_bool) { + _swig_wrap_UnaryFunction_bool_foo(arg1, arg2.Swigcptr()) +} + +var _wrap_new_UnaryFunction_bool unsafe.Pointer + +func _swig_wrap_new_UnaryFunction_bool() (base SwigcptrUnaryFunction_bool) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_UnaryFunction_bool, _swig_p) + return +} + +func NewUnaryFunction_bool() (_swig_ret UnaryFunction_bool) { + return _swig_wrap_new_UnaryFunction_bool() +} + +var _wrap_delete_UnaryFunction_bool unsafe.Pointer + +func _swig_wrap_delete_UnaryFunction_bool(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_UnaryFunction_bool, _swig_p) + return +} + +func DeleteUnaryFunction_bool(arg1 UnaryFunction_bool) { + _swig_wrap_delete_UnaryFunction_bool(arg1.Swigcptr()) +} + +type UnaryFunction_bool interface { + Swigcptr() uintptr + SwigIsUnaryFunction_bool() + Not1() (_swig_ret UnaryFunction_bool) + Foo(arg2 UnaryFunction_bool) +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/template_specialization_defarg.go b/Examples/test-suite/go/template_specialization_defarg.go new file mode 100644 index 000000000..b9b66377e --- /dev/null +++ b/Examples/test-suite/go/template_specialization_defarg.go @@ -0,0 +1,368 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../template_specialization_defarg.i + +package template_specialization_defarg + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrC_i uintptr + +func (p SwigcptrC_i) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrC_i) SwigIsC_i() { +} + +var _wrap_C_i_hi unsafe.Pointer + +func _swig_wrap_C_i_hi(base SwigcptrC_i) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_C_i_hi, _swig_p) + return +} + +func (arg1 SwigcptrC_i) Hi() (_swig_ret int) { + return _swig_wrap_C_i_hi(arg1) +} + +var _wrap_new_C_i unsafe.Pointer + +func _swig_wrap_new_C_i(base int) (_ SwigcptrC_i) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_C_i, _swig_p) + return +} + +func NewC_i(arg1 int) (_swig_ret C_i) { + return _swig_wrap_new_C_i(arg1) +} + +var _wrap_delete_C_i unsafe.Pointer + +func _swig_wrap_delete_C_i(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_C_i, _swig_p) + return +} + +func DeleteC_i(arg1 C_i) { + _swig_wrap_delete_C_i(arg1.Swigcptr()) +} + +type C_i interface { + Swigcptr() uintptr + SwigIsC_i() + Hi() (_swig_ret int) +} + +type SwigcptrC_dd uintptr + +func (p SwigcptrC_dd) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrC_dd) SwigIsC_dd() { +} + +var _wrap_C_dd_hello unsafe.Pointer + +func _swig_wrap_C_dd_hello(base SwigcptrC_dd) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_C_dd_hello, _swig_p) + return +} + +func (arg1 SwigcptrC_dd) Hello() (_swig_ret int) { + return _swig_wrap_C_dd_hello(arg1) +} + +var _wrap_new_C_dd unsafe.Pointer + +func _swig_wrap_new_C_dd(base float64) (_ SwigcptrC_dd) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_C_dd, _swig_p) + return +} + +func NewC_dd(arg1 float64) (_swig_ret C_dd) { + return _swig_wrap_new_C_dd(arg1) +} + +var _wrap_delete_C_dd unsafe.Pointer + +func _swig_wrap_delete_C_dd(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_C_dd, _swig_p) + return +} + +func DeleteC_dd(arg1 C_dd) { + _swig_wrap_delete_C_dd(arg1.Swigcptr()) +} + +type C_dd interface { + Swigcptr() uintptr + SwigIsC_dd() + Hello() (_swig_ret int) +} + +type SwigcptrC_d uintptr + +func (p SwigcptrC_d) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrC_d) SwigIsC_d() { +} + +var _wrap_C_d_hello unsafe.Pointer + +func _swig_wrap_C_d_hello(base SwigcptrC_d) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_C_d_hello, _swig_p) + return +} + +func (arg1 SwigcptrC_d) Hello() (_swig_ret int) { + return _swig_wrap_C_d_hello(arg1) +} + +var _wrap_new_C_d unsafe.Pointer + +func _swig_wrap_new_C_d(base float64) (_ SwigcptrC_d) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_C_d, _swig_p) + return +} + +func NewC_d(arg1 float64) (_swig_ret C_d) { + return _swig_wrap_new_C_d(arg1) +} + +var _wrap_delete_C_d unsafe.Pointer + +func _swig_wrap_delete_C_d(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_C_d, _swig_p) + return +} + +func DeleteC_d(arg1 C_d) { + _swig_wrap_delete_C_d(arg1.Swigcptr()) +} + +type C_d interface { + Swigcptr() uintptr + SwigIsC_d() + Hello() (_swig_ret int) +} + +type SwigcptrD_i uintptr + +func (p SwigcptrD_i) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrD_i) SwigIsD_i() { +} + +var _wrap_new_D_i unsafe.Pointer + +func _swig_wrap_new_D_i(base int) (_ SwigcptrD_i) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_D_i, _swig_p) + return +} + +func NewD_i(arg1 int) (_swig_ret D_i) { + return _swig_wrap_new_D_i(arg1) +} + +var _wrap_delete_D_i unsafe.Pointer + +func _swig_wrap_delete_D_i(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_D_i, _swig_p) + return +} + +func DeleteD_i(arg1 D_i) { + _swig_wrap_delete_D_i(arg1.Swigcptr()) +} + +type D_i interface { + Swigcptr() uintptr + SwigIsD_i() +} + +type SwigcptrD_d uintptr + +func (p SwigcptrD_d) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrD_d) SwigIsD_d() { +} + +var _wrap_new_D_d unsafe.Pointer + +func _swig_wrap_new_D_d() (base SwigcptrD_d) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_D_d, _swig_p) + return +} + +func NewD_d() (_swig_ret D_d) { + return _swig_wrap_new_D_d() +} + +var _wrap_D_d_foo unsafe.Pointer + +func _swig_wrap_D_d_foo(base SwigcptrD_d) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_D_d_foo, _swig_p) + return +} + +func (arg1 SwigcptrD_d) Foo() (_swig_ret int) { + return _swig_wrap_D_d_foo(arg1) +} + +var _wrap_delete_D_d unsafe.Pointer + +func _swig_wrap_delete_D_d(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_D_d, _swig_p) + return +} + +func DeleteD_d(arg1 D_d) { + _swig_wrap_delete_D_d(arg1.Swigcptr()) +} + +type D_d interface { + Swigcptr() uintptr + SwigIsD_d() + Foo() (_swig_ret int) +} + +type SwigcptrVector_i uintptr + +func (p SwigcptrVector_i) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrVector_i) SwigIsVector_i() { +} + +var _wrap_new_Vector_i unsafe.Pointer + +func _swig_wrap_new_Vector_i(base int) (_ SwigcptrVector_i) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Vector_i, _swig_p) + return +} + +func NewVector_i(arg1 int) (_swig_ret Vector_i) { + return _swig_wrap_new_Vector_i(arg1) +} + +var _wrap_delete_Vector_i unsafe.Pointer + +func _swig_wrap_delete_Vector_i(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Vector_i, _swig_p) + return +} + +func DeleteVector_i(arg1 Vector_i) { + _swig_wrap_delete_Vector_i(arg1.Swigcptr()) +} + +type Vector_i interface { + Swigcptr() uintptr + SwigIsVector_i() +} + +type SwigcptrVector_d uintptr + +func (p SwigcptrVector_d) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrVector_d) SwigIsVector_d() { +} + +var _wrap_new_Vector_d unsafe.Pointer + +func _swig_wrap_new_Vector_d() (base SwigcptrVector_d) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Vector_d, _swig_p) + return +} + +func NewVector_d() (_swig_ret Vector_d) { + return _swig_wrap_new_Vector_d() +} + +var _wrap_Vector_d_foo unsafe.Pointer + +func _swig_wrap_Vector_d_foo(base SwigcptrVector_d) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Vector_d_foo, _swig_p) + return +} + +func (arg1 SwigcptrVector_d) Foo() (_swig_ret int) { + return _swig_wrap_Vector_d_foo(arg1) +} + +var _wrap_delete_Vector_d unsafe.Pointer + +func _swig_wrap_delete_Vector_d(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Vector_d, _swig_p) + return +} + +func DeleteVector_d(arg1 Vector_d) { + _swig_wrap_delete_Vector_d(arg1.Swigcptr()) +} + +type Vector_d interface { + Swigcptr() uintptr + SwigIsVector_d() + Foo() (_swig_ret int) +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/template_specialization_enum.go b/Examples/test-suite/go/template_specialization_enum.go new file mode 100644 index 000000000..40fc24677 --- /dev/null +++ b/Examples/test-suite/go/template_specialization_enum.go @@ -0,0 +1,218 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../template_specialization_enum.i + +package template_specialization_enum + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type Hello int +var _wrap_hi unsafe.Pointer + +func _swig_gethi() (_swig_ret Hello) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_hi, _swig_p) + return +} +var Hi Hello = _swig_gethi() +type SwigcptrBase_dd uintptr + +func (p SwigcptrBase_dd) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrBase_dd) SwigIsBase_dd() { +} + +var _wrap_new_Base_dd unsafe.Pointer + +func _swig_wrap_new_Base_dd() (base SwigcptrBase_dd) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Base_dd, _swig_p) + return +} + +func NewBase_dd() (_swig_ret Base_dd) { + return _swig_wrap_new_Base_dd() +} + +var _wrap_delete_Base_dd unsafe.Pointer + +func _swig_wrap_delete_Base_dd(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Base_dd, _swig_p) + return +} + +func DeleteBase_dd(arg1 Base_dd) { + _swig_wrap_delete_Base_dd(arg1.Swigcptr()) +} + +type Base_dd interface { + Swigcptr() uintptr + SwigIsBase_dd() +} + +type SwigcptrBase_ii uintptr + +func (p SwigcptrBase_ii) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrBase_ii) SwigIsBase_ii() { +} + +var _wrap_new_Base_ii unsafe.Pointer + +func _swig_wrap_new_Base_ii() (base SwigcptrBase_ii) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Base_ii, _swig_p) + return +} + +func NewBase_ii() (_swig_ret Base_ii) { + return _swig_wrap_new_Base_ii() +} + +var _wrap_delete_Base_ii unsafe.Pointer + +func _swig_wrap_delete_Base_ii(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Base_ii, _swig_p) + return +} + +func DeleteBase_ii(arg1 Base_ii) { + _swig_wrap_delete_Base_ii(arg1.Swigcptr()) +} + +type Base_ii interface { + Swigcptr() uintptr + SwigIsBase_ii() +} + +type SwigcptrC_i uintptr + +func (p SwigcptrC_i) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrC_i) SwigIsC_i() { +} + +var _wrap_C_i_fhi unsafe.Pointer + +func _swig_wrap_C_i_fhi(base SwigcptrC_i) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_C_i_fhi, _swig_p) + return +} + +func (arg1 SwigcptrC_i) Fhi() (_swig_ret int) { + return _swig_wrap_C_i_fhi(arg1) +} + +var _wrap_delete_C_i unsafe.Pointer + +func _swig_wrap_delete_C_i(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_C_i, _swig_p) + return +} + +func DeleteC_i(arg1 C_i) { + _swig_wrap_delete_C_i(arg1.Swigcptr()) +} + +func (p SwigcptrC_i) SwigIsBase_dd() { +} + +func (p SwigcptrC_i) SwigGetBase_dd() Base_dd { + return SwigcptrBase_dd(p.Swigcptr()) +} + +type C_i interface { + Swigcptr() uintptr + SwigIsC_i() + Fhi() (_swig_ret int) + SwigIsBase_dd() + SwigGetBase_dd() Base_dd +} + +type SwigcptrC_d uintptr + +func (p SwigcptrC_d) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrC_d) SwigIsC_d() { +} + +var _wrap_C_d_fhello unsafe.Pointer + +func _swig_wrap_C_d_fhello(base SwigcptrC_d) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_C_d_fhello, _swig_p) + return +} + +func (arg1 SwigcptrC_d) Fhello() (_swig_ret int) { + return _swig_wrap_C_d_fhello(arg1) +} + +var _wrap_delete_C_d unsafe.Pointer + +func _swig_wrap_delete_C_d(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_C_d, _swig_p) + return +} + +func DeleteC_d(arg1 C_d) { + _swig_wrap_delete_C_d(arg1.Swigcptr()) +} + +func (p SwigcptrC_d) SwigIsBase_ii() { +} + +func (p SwigcptrC_d) SwigGetBase_ii() Base_ii { + return SwigcptrBase_ii(p.Swigcptr()) +} + +type C_d interface { + Swigcptr() uintptr + SwigIsC_d() + Fhello() (_swig_ret int) + SwigIsBase_ii() + SwigGetBase_ii() Base_ii +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/template_static.go b/Examples/test-suite/go/template_static.go new file mode 100644 index 000000000..5dc9d9660 --- /dev/null +++ b/Examples/test-suite/go/template_static.go @@ -0,0 +1,196 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../template_static.i + +package template_static + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrFoo_i uintptr + +func (p SwigcptrFoo_i) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrFoo_i) SwigIsFoo_i() { +} + +var _wrap_foo_i_test_set unsafe.Pointer + +func _swig_wrap_foo_i_test_set(base int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_foo_i_test_set, _swig_p) + return +} + +func SetFoo_iTest(arg1 int) { + _swig_wrap_foo_i_test_set(arg1) +} + +var _wrap_foo_i_test_get unsafe.Pointer + +func GetFoo_iTest() (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_foo_i_test_get, _swig_p) + return +} +var _wrap_new_foo_i unsafe.Pointer + +func _swig_wrap_new_foo_i() (base SwigcptrFoo_i) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_foo_i, _swig_p) + return +} + +func NewFoo_i() (_swig_ret Foo_i) { + return _swig_wrap_new_foo_i() +} + +var _wrap_delete_foo_i unsafe.Pointer + +func _swig_wrap_delete_foo_i(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_foo_i, _swig_p) + return +} + +func DeleteFoo_i(arg1 Foo_i) { + _swig_wrap_delete_foo_i(arg1.Swigcptr()) +} + +type Foo_i interface { + Swigcptr() uintptr + SwigIsFoo_i() +} + +type SwigcptrFoo_d uintptr + +func (p SwigcptrFoo_d) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrFoo_d) SwigIsFoo_d() { +} + +var _wrap_foo_d_test_set unsafe.Pointer + +func _swig_wrap_foo_d_test_set(base int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_foo_d_test_set, _swig_p) + return +} + +func SetFoo_dTest(arg1 int) { + _swig_wrap_foo_d_test_set(arg1) +} + +var _wrap_foo_d_test_get unsafe.Pointer + +func GetFoo_dTest() (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_foo_d_test_get, _swig_p) + return +} +var _wrap_new_foo_d unsafe.Pointer + +func _swig_wrap_new_foo_d() (base SwigcptrFoo_d) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_foo_d, _swig_p) + return +} + +func NewFoo_d() (_swig_ret Foo_d) { + return _swig_wrap_new_foo_d() +} + +var _wrap_delete_foo_d unsafe.Pointer + +func _swig_wrap_delete_foo_d(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_foo_d, _swig_p) + return +} + +func DeleteFoo_d(arg1 Foo_d) { + _swig_wrap_delete_foo_d(arg1.Swigcptr()) +} + +type Foo_d interface { + Swigcptr() uintptr + SwigIsFoo_d() +} + +type SwigcptrFoo uintptr + +func (p SwigcptrFoo) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrFoo) SwigIsFoo() { +} + +var _wrap_Foo_bar_double unsafe.Pointer + +func FooBar_double(arg1 int) (_swig_ret float64) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_Foo_bar_double, _swig_p) + return +} +var _wrap_new_Foo unsafe.Pointer + +func _swig_wrap_new_Foo() (base SwigcptrFoo) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Foo, _swig_p) + return +} + +func NewFoo() (_swig_ret Foo) { + return _swig_wrap_new_Foo() +} + +var _wrap_delete_Foo unsafe.Pointer + +func _swig_wrap_delete_Foo(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Foo, _swig_p) + return +} + +func DeleteFoo(arg1 Foo) { + _swig_wrap_delete_Foo(arg1.Swigcptr()) +} + +type Foo interface { + Swigcptr() uintptr + SwigIsFoo() +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/template_static_runme b/Examples/test-suite/go/template_static_runme new file mode 100755 index 000000000..4065ea8e4 Binary files /dev/null and b/Examples/test-suite/go/template_static_runme differ diff --git a/Examples/test-suite/go/template_tbase_template.go b/Examples/test-suite/go/template_tbase_template.go new file mode 100644 index 000000000..0f78b0cff --- /dev/null +++ b/Examples/test-suite/go/template_tbase_template.go @@ -0,0 +1,198 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../template_tbase_template.i + +package template_tbase_template + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrTraits_dd uintptr + +func (p SwigcptrTraits_dd) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrTraits_dd) SwigIsTraits_dd() { +} + +var _wrap_new_traits_dd unsafe.Pointer + +func _swig_wrap_new_traits_dd() (base SwigcptrTraits_dd) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_traits_dd, _swig_p) + return +} + +func NewTraits_dd() (_swig_ret Traits_dd) { + return _swig_wrap_new_traits_dd() +} + +var _wrap_delete_traits_dd unsafe.Pointer + +func _swig_wrap_delete_traits_dd(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_traits_dd, _swig_p) + return +} + +func DeleteTraits_dd(arg1 Traits_dd) { + _swig_wrap_delete_traits_dd(arg1.Swigcptr()) +} + +type Traits_dd interface { + Swigcptr() uintptr + SwigIsTraits_dd() +} + +type SwigcptrFunktion_dd uintptr + +func (p SwigcptrFunktion_dd) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrFunktion_dd) SwigIsFunktion_dd() { +} + +var _wrap_Funktion_dd_test unsafe.Pointer + +func _swig_wrap_Funktion_dd_test(base SwigcptrFunktion_dd) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Funktion_dd_test, _swig_p) + return +} + +func (arg1 SwigcptrFunktion_dd) Test() (_swig_ret string) { + return _swig_wrap_Funktion_dd_test(arg1) +} + +var _wrap_new_Funktion_dd unsafe.Pointer + +func _swig_wrap_new_Funktion_dd() (base SwigcptrFunktion_dd) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Funktion_dd, _swig_p) + return +} + +func NewFunktion_dd() (_swig_ret Funktion_dd) { + return _swig_wrap_new_Funktion_dd() +} + +var _wrap_delete_Funktion_dd unsafe.Pointer + +func _swig_wrap_delete_Funktion_dd(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Funktion_dd, _swig_p) + return +} + +func DeleteFunktion_dd(arg1 Funktion_dd) { + _swig_wrap_delete_Funktion_dd(arg1.Swigcptr()) +} + +type Funktion_dd interface { + Swigcptr() uintptr + SwigIsFunktion_dd() + Test() (_swig_ret string) +} + +type SwigcptrClass_dd uintptr + +func (p SwigcptrClass_dd) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrClass_dd) SwigIsClass_dd() { +} + +var _wrap_new_Class_dd unsafe.Pointer + +func _swig_wrap_new_Class_dd() (base SwigcptrClass_dd) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Class_dd, _swig_p) + return +} + +func NewClass_dd() (_swig_ret Class_dd) { + return _swig_wrap_new_Class_dd() +} + +var _wrap_delete_Class_dd unsafe.Pointer + +func _swig_wrap_delete_Class_dd(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Class_dd, _swig_p) + return +} + +func DeleteClass_dd(arg1 Class_dd) { + _swig_wrap_delete_Class_dd(arg1.Swigcptr()) +} + +var _wrap_Class_dd_test unsafe.Pointer + +func _swig_wrap_Class_dd_test(base SwigcptrClass_dd) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Class_dd_test, _swig_p) + return +} + +func (_swig_base SwigcptrClass_dd) Test() (_swig_ret string) { + return _swig_wrap_Class_dd_test(_swig_base) +} + +func (p SwigcptrClass_dd) SwigIsFunktion_dd() { +} + +func (p SwigcptrClass_dd) SwigGetFunktion_dd() Funktion_dd { + return SwigcptrFunktion_dd(p.Swigcptr()) +} + +type Class_dd interface { + Swigcptr() uintptr + SwigIsClass_dd() + Test() (_swig_ret string) + SwigIsFunktion_dd() + SwigGetFunktion_dd() Funktion_dd +} + +var _wrap_make_Class_dd unsafe.Pointer + +func _swig_wrap_make_Class_dd() (base SwigcptrFunktion_dd) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_make_Class_dd, _swig_p) + return +} + +func Make_Class_dd() (_swig_ret Funktion_dd) { + return _swig_wrap_make_Class_dd() +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/template_tbase_template_runme b/Examples/test-suite/go/template_tbase_template_runme new file mode 100755 index 000000000..64e808a02 Binary files /dev/null and b/Examples/test-suite/go/template_tbase_template_runme differ diff --git a/Examples/test-suite/go/template_template_parameters.go b/Examples/test-suite/go/template_template_parameters.go new file mode 100644 index 000000000..37f34a689 --- /dev/null +++ b/Examples/test-suite/go/template_template_parameters.go @@ -0,0 +1,297 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../template_template_parameters.i + +package template_template_parameters + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +var _wrap_TestInstantiations unsafe.Pointer + +func _swig_wrap_TestInstantiations() { + var _swig_p uintptr + _cgo_runtime_cgocall(_wrap_TestInstantiations, _swig_p) + return +} + +func TestInstantiations() { + _swig_wrap_TestInstantiations() +} + +type SwigcptrListImplFastBool uintptr + +func (p SwigcptrListImplFastBool) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrListImplFastBool) SwigIsListImplFastBool() { +} + +var _wrap_new_ListImplFastBool unsafe.Pointer + +func _swig_wrap_new_ListImplFastBool() (base SwigcptrListImplFastBool) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_ListImplFastBool, _swig_p) + return +} + +func NewListImplFastBool() (_swig_ret ListImplFastBool) { + return _swig_wrap_new_ListImplFastBool() +} + +var _wrap_delete_ListImplFastBool unsafe.Pointer + +func _swig_wrap_delete_ListImplFastBool(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_ListImplFastBool, _swig_p) + return +} + +func DeleteListImplFastBool(arg1 ListImplFastBool) { + _swig_wrap_delete_ListImplFastBool(arg1.Swigcptr()) +} + +type ListImplFastBool interface { + Swigcptr() uintptr + SwigIsListImplFastBool() +} + +type SwigcptrListFastBool uintptr + +func (p SwigcptrListFastBool) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrListFastBool) SwigIsListFastBool() { +} + +var _wrap_ListFastBool_item_set unsafe.Pointer + +func _swig_wrap_ListFastBool_item_set(base SwigcptrListFastBool, _ bool) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_ListFastBool_item_set, _swig_p) + return +} + +func (arg1 SwigcptrListFastBool) SetItem(arg2 bool) { + _swig_wrap_ListFastBool_item_set(arg1, arg2) +} + +var _wrap_ListFastBool_item_get unsafe.Pointer + +func _swig_wrap_ListFastBool_item_get(base SwigcptrListFastBool) (_ bool) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_ListFastBool_item_get, _swig_p) + return +} + +func (arg1 SwigcptrListFastBool) GetItem() (_swig_ret bool) { + return _swig_wrap_ListFastBool_item_get(arg1) +} + +var _wrap_ListFastBool_xx unsafe.Pointer + +func _swig_wrap_ListFastBool_xx(base SwigcptrListFastBool) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_ListFastBool_xx, _swig_p) + return +} + +func (arg1 SwigcptrListFastBool) Xx() { + _swig_wrap_ListFastBool_xx(arg1) +} + +var _wrap_new_ListFastBool unsafe.Pointer + +func _swig_wrap_new_ListFastBool() (base SwigcptrListFastBool) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_ListFastBool, _swig_p) + return +} + +func NewListFastBool() (_swig_ret ListFastBool) { + return _swig_wrap_new_ListFastBool() +} + +var _wrap_delete_ListFastBool unsafe.Pointer + +func _swig_wrap_delete_ListFastBool(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_ListFastBool, _swig_p) + return +} + +func DeleteListFastBool(arg1 ListFastBool) { + _swig_wrap_delete_ListFastBool(arg1.Swigcptr()) +} + +func (p SwigcptrListFastBool) SwigIsListImplFastBool() { +} + +func (p SwigcptrListFastBool) SwigGetListImplFastBool() ListImplFastBool { + return SwigcptrListImplFastBool(p.Swigcptr()) +} + +type ListFastBool interface { + Swigcptr() uintptr + SwigIsListFastBool() + SetItem(arg2 bool) + GetItem() (_swig_ret bool) + Xx() + SwigIsListImplFastBool() + SwigGetListImplFastBool() ListImplFastBool +} + +type SwigcptrListImplFastDouble uintptr + +func (p SwigcptrListImplFastDouble) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrListImplFastDouble) SwigIsListImplFastDouble() { +} + +var _wrap_new_ListImplFastDouble unsafe.Pointer + +func _swig_wrap_new_ListImplFastDouble() (base SwigcptrListImplFastDouble) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_ListImplFastDouble, _swig_p) + return +} + +func NewListImplFastDouble() (_swig_ret ListImplFastDouble) { + return _swig_wrap_new_ListImplFastDouble() +} + +var _wrap_delete_ListImplFastDouble unsafe.Pointer + +func _swig_wrap_delete_ListImplFastDouble(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_ListImplFastDouble, _swig_p) + return +} + +func DeleteListImplFastDouble(arg1 ListImplFastDouble) { + _swig_wrap_delete_ListImplFastDouble(arg1.Swigcptr()) +} + +type ListImplFastDouble interface { + Swigcptr() uintptr + SwigIsListImplFastDouble() +} + +type SwigcptrListDefaultDouble uintptr + +func (p SwigcptrListDefaultDouble) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrListDefaultDouble) SwigIsListDefaultDouble() { +} + +var _wrap_ListDefaultDouble_item_set unsafe.Pointer + +func _swig_wrap_ListDefaultDouble_item_set(base SwigcptrListDefaultDouble, _ float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_ListDefaultDouble_item_set, _swig_p) + return +} + +func (arg1 SwigcptrListDefaultDouble) SetItem(arg2 float64) { + _swig_wrap_ListDefaultDouble_item_set(arg1, arg2) +} + +var _wrap_ListDefaultDouble_item_get unsafe.Pointer + +func _swig_wrap_ListDefaultDouble_item_get(base SwigcptrListDefaultDouble) (_ float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_ListDefaultDouble_item_get, _swig_p) + return +} + +func (arg1 SwigcptrListDefaultDouble) GetItem() (_swig_ret float64) { + return _swig_wrap_ListDefaultDouble_item_get(arg1) +} + +var _wrap_ListDefaultDouble_xx unsafe.Pointer + +func _swig_wrap_ListDefaultDouble_xx(base SwigcptrListDefaultDouble) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_ListDefaultDouble_xx, _swig_p) + return +} + +func (arg1 SwigcptrListDefaultDouble) Xx() { + _swig_wrap_ListDefaultDouble_xx(arg1) +} + +var _wrap_new_ListDefaultDouble unsafe.Pointer + +func _swig_wrap_new_ListDefaultDouble() (base SwigcptrListDefaultDouble) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_ListDefaultDouble, _swig_p) + return +} + +func NewListDefaultDouble() (_swig_ret ListDefaultDouble) { + return _swig_wrap_new_ListDefaultDouble() +} + +var _wrap_delete_ListDefaultDouble unsafe.Pointer + +func _swig_wrap_delete_ListDefaultDouble(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_ListDefaultDouble, _swig_p) + return +} + +func DeleteListDefaultDouble(arg1 ListDefaultDouble) { + _swig_wrap_delete_ListDefaultDouble(arg1.Swigcptr()) +} + +func (p SwigcptrListDefaultDouble) SwigIsListImplFastDouble() { +} + +func (p SwigcptrListDefaultDouble) SwigGetListImplFastDouble() ListImplFastDouble { + return SwigcptrListImplFastDouble(p.Swigcptr()) +} + +type ListDefaultDouble interface { + Swigcptr() uintptr + SwigIsListDefaultDouble() + SetItem(arg2 float64) + GetItem() (_swig_ret float64) + Xx() + SwigIsListImplFastDouble() + SwigGetListImplFastDouble() ListImplFastDouble +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/template_type_namespace.go b/Examples/test-suite/go/template_type_namespace.go new file mode 100644 index 000000000..eb6253111 --- /dev/null +++ b/Examples/test-suite/go/template_type_namespace.go @@ -0,0 +1,214 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../template_type_namespace.i + +package template_type_namespace + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrString_vector uintptr + +func (p SwigcptrString_vector) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrString_vector) SwigIsString_vector() { +} + +var _wrap_new_string_vector__SWIG_0 unsafe.Pointer + +func _swig_wrap_new_string_vector__SWIG_0() (base SwigcptrString_vector) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_string_vector__SWIG_0, _swig_p) + return +} + +func NewString_vector__SWIG_0() (_swig_ret String_vector) { + return _swig_wrap_new_string_vector__SWIG_0() +} + +var _wrap_new_string_vector__SWIG_1 unsafe.Pointer + +func _swig_wrap_new_string_vector__SWIG_1(base int64) (_ SwigcptrString_vector) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_string_vector__SWIG_1, _swig_p) + return +} + +func NewString_vector__SWIG_1(arg1 int64) (_swig_ret String_vector) { + return _swig_wrap_new_string_vector__SWIG_1(arg1) +} + +func NewString_vector(a ...interface{}) String_vector { + argc := len(a) + if argc == 0 { + return NewString_vector__SWIG_0() + } + if argc == 1 { + return NewString_vector__SWIG_1(a[0].(int64)) + } + panic("No match for overloaded function call") +} + +var _wrap_string_vector_size unsafe.Pointer + +func _swig_wrap_string_vector_size(base SwigcptrString_vector) (_ int64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_string_vector_size, _swig_p) + return +} + +func (arg1 SwigcptrString_vector) Size() (_swig_ret int64) { + return _swig_wrap_string_vector_size(arg1) +} + +var _wrap_string_vector_capacity unsafe.Pointer + +func _swig_wrap_string_vector_capacity(base SwigcptrString_vector) (_ int64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_string_vector_capacity, _swig_p) + return +} + +func (arg1 SwigcptrString_vector) Capacity() (_swig_ret int64) { + return _swig_wrap_string_vector_capacity(arg1) +} + +var _wrap_string_vector_reserve unsafe.Pointer + +func _swig_wrap_string_vector_reserve(base SwigcptrString_vector, _ int64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_string_vector_reserve, _swig_p) + return +} + +func (arg1 SwigcptrString_vector) Reserve(arg2 int64) { + _swig_wrap_string_vector_reserve(arg1, arg2) +} + +var _wrap_string_vector_isEmpty unsafe.Pointer + +func _swig_wrap_string_vector_isEmpty(base SwigcptrString_vector) (_ bool) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_string_vector_isEmpty, _swig_p) + return +} + +func (arg1 SwigcptrString_vector) IsEmpty() (_swig_ret bool) { + return _swig_wrap_string_vector_isEmpty(arg1) +} + +var _wrap_string_vector_clear unsafe.Pointer + +func _swig_wrap_string_vector_clear(base SwigcptrString_vector) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_string_vector_clear, _swig_p) + return +} + +func (arg1 SwigcptrString_vector) Clear() { + _swig_wrap_string_vector_clear(arg1) +} + +var _wrap_string_vector_add unsafe.Pointer + +func _swig_wrap_string_vector_add(base SwigcptrString_vector, _ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_string_vector_add, _swig_p) + return +} + +func (arg1 SwigcptrString_vector) Add(arg2 string) { + _swig_wrap_string_vector_add(arg1, arg2) +} + +var _wrap_string_vector_get unsafe.Pointer + +func _swig_wrap_string_vector_get(base SwigcptrString_vector, _ int) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_string_vector_get, _swig_p) + return +} + +func (arg1 SwigcptrString_vector) Get(arg2 int) (_swig_ret string) { + return _swig_wrap_string_vector_get(arg1, arg2) +} + +var _wrap_string_vector_set unsafe.Pointer + +func _swig_wrap_string_vector_set(base SwigcptrString_vector, _ int, _ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_string_vector_set, _swig_p) + return +} + +func (arg1 SwigcptrString_vector) Set(arg2 int, arg3 string) { + _swig_wrap_string_vector_set(arg1, arg2, arg3) +} + +var _wrap_delete_string_vector unsafe.Pointer + +func _swig_wrap_delete_string_vector(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_string_vector, _swig_p) + return +} + +func DeleteString_vector(arg1 String_vector) { + _swig_wrap_delete_string_vector(arg1.Swigcptr()) +} + +type String_vector interface { + Swigcptr() uintptr + SwigIsString_vector() + Size() (_swig_ret int64) + Capacity() (_swig_ret int64) + Reserve(arg2 int64) + IsEmpty() (_swig_ret bool) + Clear() + Add(arg2 string) + Get(arg2 int) (_swig_ret string) + Set(arg2 int, arg3 string) +} + +var _wrap_foo unsafe.Pointer + +func _swig_wrap_foo() (base SwigcptrString_vector) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_foo, _swig_p) + return +} + +func Foo() (_swig_ret String_vector) { + return _swig_wrap_foo() +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/template_type_namespace_runme b/Examples/test-suite/go/template_type_namespace_runme new file mode 100755 index 000000000..65afce038 Binary files /dev/null and b/Examples/test-suite/go/template_type_namespace_runme differ diff --git a/Examples/test-suite/go/template_typedef.go b/Examples/test-suite/go/template_typedef.go new file mode 100644 index 000000000..1f179e277 --- /dev/null +++ b/Examples/test-suite/go/template_typedef.go @@ -0,0 +1,444 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../template_typedef.i + +package template_typedef + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrUnaryFunctionBase uintptr + +func (p SwigcptrUnaryFunctionBase) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrUnaryFunctionBase) SwigIsUnaryFunctionBase() { +} + +var _wrap_new_UnaryFunctionBase unsafe.Pointer + +func _swig_wrap_new_UnaryFunctionBase() (base SwigcptrUnaryFunctionBase) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_UnaryFunctionBase, _swig_p) + return +} + +func NewUnaryFunctionBase() (_swig_ret UnaryFunctionBase) { + return _swig_wrap_new_UnaryFunctionBase() +} + +var _wrap_delete_UnaryFunctionBase unsafe.Pointer + +func _swig_wrap_delete_UnaryFunctionBase(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_UnaryFunctionBase, _swig_p) + return +} + +func DeleteUnaryFunctionBase(arg1 UnaryFunctionBase) { + _swig_wrap_delete_UnaryFunctionBase(arg1.Swigcptr()) +} + +type UnaryFunctionBase interface { + Swigcptr() uintptr + SwigIsUnaryFunctionBase() +} + +type SwigcptrUnaryFunction_float_float uintptr + +func (p SwigcptrUnaryFunction_float_float) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrUnaryFunction_float_float) SwigIsUnaryFunction_float_float() { +} + +var _wrap_new_UnaryFunction_float_float unsafe.Pointer + +func _swig_wrap_new_UnaryFunction_float_float() (base SwigcptrUnaryFunction_float_float) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_UnaryFunction_float_float, _swig_p) + return +} + +func NewUnaryFunction_float_float() (_swig_ret UnaryFunction_float_float) { + return _swig_wrap_new_UnaryFunction_float_float() +} + +var _wrap_delete_UnaryFunction_float_float unsafe.Pointer + +func _swig_wrap_delete_UnaryFunction_float_float(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_UnaryFunction_float_float, _swig_p) + return +} + +func DeleteUnaryFunction_float_float(arg1 UnaryFunction_float_float) { + _swig_wrap_delete_UnaryFunction_float_float(arg1.Swigcptr()) +} + +func (p SwigcptrUnaryFunction_float_float) SwigIsUnaryFunctionBase() { +} + +func (p SwigcptrUnaryFunction_float_float) SwigGetUnaryFunctionBase() UnaryFunctionBase { + return SwigcptrUnaryFunctionBase(p.Swigcptr()) +} + +type UnaryFunction_float_float interface { + Swigcptr() uintptr + SwigIsUnaryFunction_float_float() + SwigIsUnaryFunctionBase() + SwigGetUnaryFunctionBase() UnaryFunctionBase +} + +type SwigcptrArithUnaryFunction_float_float uintptr + +func (p SwigcptrArithUnaryFunction_float_float) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrArithUnaryFunction_float_float) SwigIsArithUnaryFunction_float_float() { +} + +var _wrap_new_ArithUnaryFunction_float_float unsafe.Pointer + +func _swig_wrap_new_ArithUnaryFunction_float_float() (base SwigcptrArithUnaryFunction_float_float) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_ArithUnaryFunction_float_float, _swig_p) + return +} + +func NewArithUnaryFunction_float_float() (_swig_ret ArithUnaryFunction_float_float) { + return _swig_wrap_new_ArithUnaryFunction_float_float() +} + +var _wrap_delete_ArithUnaryFunction_float_float unsafe.Pointer + +func _swig_wrap_delete_ArithUnaryFunction_float_float(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_ArithUnaryFunction_float_float, _swig_p) + return +} + +func DeleteArithUnaryFunction_float_float(arg1 ArithUnaryFunction_float_float) { + _swig_wrap_delete_ArithUnaryFunction_float_float(arg1.Swigcptr()) +} + +func (p SwigcptrArithUnaryFunction_float_float) SwigIsUnaryFunction_float_float() { +} + +func (p SwigcptrArithUnaryFunction_float_float) SwigGetUnaryFunction_float_float() UnaryFunction_float_float { + return SwigcptrUnaryFunction_float_float(p.Swigcptr()) +} + +func (p SwigcptrArithUnaryFunction_float_float) SwigIsUnaryFunctionBase() { +} + +func (p SwigcptrArithUnaryFunction_float_float) SwigGetUnaryFunctionBase() UnaryFunctionBase { + return SwigcptrUnaryFunctionBase(p.Swigcptr()) +} + +type ArithUnaryFunction_float_float interface { + Swigcptr() uintptr + SwigIsArithUnaryFunction_float_float() + SwigIsUnaryFunction_float_float() + SwigGetUnaryFunction_float_float() UnaryFunction_float_float + SwigIsUnaryFunctionBase() + SwigGetUnaryFunctionBase() UnaryFunctionBase +} + +var _wrap_make_Identity_float unsafe.Pointer + +func _swig_wrap_make_Identity_float() (base SwigcptrArithUnaryFunction_float_float) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_make_Identity_float, _swig_p) + return +} + +func Make_Identity_float() (_swig_ret ArithUnaryFunction_float_float) { + return _swig_wrap_make_Identity_float() +} + +type SwigcptrUnaryFunction_reald_reald uintptr + +func (p SwigcptrUnaryFunction_reald_reald) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrUnaryFunction_reald_reald) SwigIsUnaryFunction_reald_reald() { +} + +var _wrap_new_UnaryFunction_reald_reald unsafe.Pointer + +func _swig_wrap_new_UnaryFunction_reald_reald() (base SwigcptrUnaryFunction_reald_reald) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_UnaryFunction_reald_reald, _swig_p) + return +} + +func NewUnaryFunction_reald_reald() (_swig_ret UnaryFunction_reald_reald) { + return _swig_wrap_new_UnaryFunction_reald_reald() +} + +var _wrap_delete_UnaryFunction_reald_reald unsafe.Pointer + +func _swig_wrap_delete_UnaryFunction_reald_reald(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_UnaryFunction_reald_reald, _swig_p) + return +} + +func DeleteUnaryFunction_reald_reald(arg1 UnaryFunction_reald_reald) { + _swig_wrap_delete_UnaryFunction_reald_reald(arg1.Swigcptr()) +} + +func (p SwigcptrUnaryFunction_reald_reald) SwigIsUnaryFunctionBase() { +} + +func (p SwigcptrUnaryFunction_reald_reald) SwigGetUnaryFunctionBase() UnaryFunctionBase { + return SwigcptrUnaryFunctionBase(p.Swigcptr()) +} + +type UnaryFunction_reald_reald interface { + Swigcptr() uintptr + SwigIsUnaryFunction_reald_reald() + SwigIsUnaryFunctionBase() + SwigGetUnaryFunctionBase() UnaryFunctionBase +} + +type SwigcptrArithUnaryFunction_reald_reald uintptr + +func (p SwigcptrArithUnaryFunction_reald_reald) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrArithUnaryFunction_reald_reald) SwigIsArithUnaryFunction_reald_reald() { +} + +var _wrap_new_ArithUnaryFunction_reald_reald unsafe.Pointer + +func _swig_wrap_new_ArithUnaryFunction_reald_reald() (base SwigcptrArithUnaryFunction_reald_reald) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_ArithUnaryFunction_reald_reald, _swig_p) + return +} + +func NewArithUnaryFunction_reald_reald() (_swig_ret ArithUnaryFunction_reald_reald) { + return _swig_wrap_new_ArithUnaryFunction_reald_reald() +} + +var _wrap_delete_ArithUnaryFunction_reald_reald unsafe.Pointer + +func _swig_wrap_delete_ArithUnaryFunction_reald_reald(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_ArithUnaryFunction_reald_reald, _swig_p) + return +} + +func DeleteArithUnaryFunction_reald_reald(arg1 ArithUnaryFunction_reald_reald) { + _swig_wrap_delete_ArithUnaryFunction_reald_reald(arg1.Swigcptr()) +} + +func (p SwigcptrArithUnaryFunction_reald_reald) SwigIsUnaryFunction_reald_reald() { +} + +func (p SwigcptrArithUnaryFunction_reald_reald) SwigGetUnaryFunction_reald_reald() UnaryFunction_reald_reald { + return SwigcptrUnaryFunction_reald_reald(p.Swigcptr()) +} + +func (p SwigcptrArithUnaryFunction_reald_reald) SwigIsUnaryFunctionBase() { +} + +func (p SwigcptrArithUnaryFunction_reald_reald) SwigGetUnaryFunctionBase() UnaryFunctionBase { + return SwigcptrUnaryFunctionBase(p.Swigcptr()) +} + +type ArithUnaryFunction_reald_reald interface { + Swigcptr() uintptr + SwigIsArithUnaryFunction_reald_reald() + SwigIsUnaryFunction_reald_reald() + SwigGetUnaryFunction_reald_reald() UnaryFunction_reald_reald + SwigIsUnaryFunctionBase() + SwigGetUnaryFunctionBase() UnaryFunctionBase +} + +var _wrap_make_Identity_reald unsafe.Pointer + +func _swig_wrap_make_Identity_reald() (base SwigcptrArithUnaryFunction_reald_reald) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_make_Identity_reald, _swig_p) + return +} + +func Make_Identity_reald() (_swig_ret ArithUnaryFunction_reald_reald) { + return _swig_wrap_make_Identity_reald() +} + +type SwigcptrUnaryFunction_float_reald uintptr + +func (p SwigcptrUnaryFunction_float_reald) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrUnaryFunction_float_reald) SwigIsUnaryFunction_float_reald() { +} + +var _wrap_new_UnaryFunction_float_reald unsafe.Pointer + +func _swig_wrap_new_UnaryFunction_float_reald() (base SwigcptrUnaryFunction_float_reald) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_UnaryFunction_float_reald, _swig_p) + return +} + +func NewUnaryFunction_float_reald() (_swig_ret UnaryFunction_float_reald) { + return _swig_wrap_new_UnaryFunction_float_reald() +} + +var _wrap_delete_UnaryFunction_float_reald unsafe.Pointer + +func _swig_wrap_delete_UnaryFunction_float_reald(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_UnaryFunction_float_reald, _swig_p) + return +} + +func DeleteUnaryFunction_float_reald(arg1 UnaryFunction_float_reald) { + _swig_wrap_delete_UnaryFunction_float_reald(arg1.Swigcptr()) +} + +func (p SwigcptrUnaryFunction_float_reald) SwigIsUnaryFunctionBase() { +} + +func (p SwigcptrUnaryFunction_float_reald) SwigGetUnaryFunctionBase() UnaryFunctionBase { + return SwigcptrUnaryFunctionBase(p.Swigcptr()) +} + +type UnaryFunction_float_reald interface { + Swigcptr() uintptr + SwigIsUnaryFunction_float_reald() + SwigIsUnaryFunctionBase() + SwigGetUnaryFunctionBase() UnaryFunctionBase +} + +type SwigcptrArithUnaryFunction_float_reald uintptr + +func (p SwigcptrArithUnaryFunction_float_reald) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrArithUnaryFunction_float_reald) SwigIsArithUnaryFunction_float_reald() { +} + +var _wrap_new_ArithUnaryFunction_float_reald unsafe.Pointer + +func _swig_wrap_new_ArithUnaryFunction_float_reald() (base SwigcptrArithUnaryFunction_float_reald) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_ArithUnaryFunction_float_reald, _swig_p) + return +} + +func NewArithUnaryFunction_float_reald() (_swig_ret ArithUnaryFunction_float_reald) { + return _swig_wrap_new_ArithUnaryFunction_float_reald() +} + +var _wrap_delete_ArithUnaryFunction_float_reald unsafe.Pointer + +func _swig_wrap_delete_ArithUnaryFunction_float_reald(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_ArithUnaryFunction_float_reald, _swig_p) + return +} + +func DeleteArithUnaryFunction_float_reald(arg1 ArithUnaryFunction_float_reald) { + _swig_wrap_delete_ArithUnaryFunction_float_reald(arg1.Swigcptr()) +} + +func (p SwigcptrArithUnaryFunction_float_reald) SwigIsUnaryFunction_float_reald() { +} + +func (p SwigcptrArithUnaryFunction_float_reald) SwigGetUnaryFunction_float_reald() UnaryFunction_float_reald { + return SwigcptrUnaryFunction_float_reald(p.Swigcptr()) +} + +func (p SwigcptrArithUnaryFunction_float_reald) SwigIsUnaryFunctionBase() { +} + +func (p SwigcptrArithUnaryFunction_float_reald) SwigGetUnaryFunctionBase() UnaryFunctionBase { + return SwigcptrUnaryFunctionBase(p.Swigcptr()) +} + +type ArithUnaryFunction_float_reald interface { + Swigcptr() uintptr + SwigIsArithUnaryFunction_float_reald() + SwigIsUnaryFunction_float_reald() + SwigGetUnaryFunction_float_reald() UnaryFunction_float_reald + SwigIsUnaryFunctionBase() + SwigGetUnaryFunctionBase() UnaryFunctionBase +} + +var _wrap_make_Multiplies_float_float_reald_reald unsafe.Pointer + +func _swig_wrap_make_Multiplies_float_float_reald_reald(base uintptr, _ uintptr) (_ SwigcptrArithUnaryFunction_float_reald) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_make_Multiplies_float_float_reald_reald, _swig_p) + return +} + +func Make_Multiplies_float_float_reald_reald(arg1 ArithUnaryFunction_float_float, arg2 ArithUnaryFunction_reald_reald) (_swig_ret ArithUnaryFunction_float_reald) { + return _swig_wrap_make_Multiplies_float_float_reald_reald(arg1.Swigcptr(), arg2.Swigcptr()) +} + +var _wrap_make_Multiplies_float_float_float_float unsafe.Pointer + +func _swig_wrap_make_Multiplies_float_float_float_float(base uintptr, _ uintptr) (_ SwigcptrArithUnaryFunction_float_float) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_make_Multiplies_float_float_float_float, _swig_p) + return +} + +func Make_Multiplies_float_float_float_float(arg1 ArithUnaryFunction_float_float, arg2 ArithUnaryFunction_float_float) (_swig_ret ArithUnaryFunction_float_float) { + return _swig_wrap_make_Multiplies_float_float_float_float(arg1.Swigcptr(), arg2.Swigcptr()) +} + +var _wrap_make_Multiplies_reald_reald_reald_reald unsafe.Pointer + +func _swig_wrap_make_Multiplies_reald_reald_reald_reald(base uintptr, _ uintptr) (_ SwigcptrArithUnaryFunction_reald_reald) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_make_Multiplies_reald_reald_reald_reald, _swig_p) + return +} + +func Make_Multiplies_reald_reald_reald_reald(arg1 ArithUnaryFunction_reald_reald, arg2 ArithUnaryFunction_reald_reald) (_swig_ret ArithUnaryFunction_reald_reald) { + return _swig_wrap_make_Multiplies_reald_reald_reald_reald(arg1.Swigcptr(), arg2.Swigcptr()) +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/template_typedef_class_template.go b/Examples/test-suite/go/template_typedef_class_template.go new file mode 100644 index 000000000..77409546e --- /dev/null +++ b/Examples/test-suite/go/template_typedef_class_template.go @@ -0,0 +1,294 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../template_typedef_class_template.i + +package template_typedef_class_template + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrA uintptr + +func (p SwigcptrA) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrA) SwigIsA() { +} + +var _wrap_A_val_set unsafe.Pointer + +func _swig_wrap_A_val_set(base SwigcptrA, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_A_val_set, _swig_p) + return +} + +func (arg1 SwigcptrA) SetVal(arg2 int) { + _swig_wrap_A_val_set(arg1, arg2) +} + +var _wrap_A_val_get unsafe.Pointer + +func _swig_wrap_A_val_get(base SwigcptrA) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_A_val_get, _swig_p) + return +} + +func (arg1 SwigcptrA) GetVal() (_swig_ret int) { + return _swig_wrap_A_val_get(arg1) +} + +var _wrap_new_A__SWIG_0 unsafe.Pointer + +func _swig_wrap_new_A__SWIG_0(base int) (_ SwigcptrA) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_A__SWIG_0, _swig_p) + return +} + +func NewA__SWIG_0(arg1 int) (_swig_ret A) { + return _swig_wrap_new_A__SWIG_0(arg1) +} + +var _wrap_new_A__SWIG_1 unsafe.Pointer + +func _swig_wrap_new_A__SWIG_1() (base SwigcptrA) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_A__SWIG_1, _swig_p) + return +} + +func NewA__SWIG_1() (_swig_ret A) { + return _swig_wrap_new_A__SWIG_1() +} + +func NewA(a ...interface{}) A { + argc := len(a) + if argc == 0 { + return NewA__SWIG_1() + } + if argc == 1 { + return NewA__SWIG_0(a[0].(int)) + } + panic("No match for overloaded function call") +} + +var _wrap_delete_A unsafe.Pointer + +func _swig_wrap_delete_A(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_A, _swig_p) + return +} + +func DeleteA(arg1 A) { + _swig_wrap_delete_A(arg1.Swigcptr()) +} + +type A interface { + Swigcptr() uintptr + SwigIsA() + SetVal(arg2 int) + GetVal() (_swig_ret int) +} + +type SwigcptrPairA uintptr + +func (p SwigcptrPairA) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrPairA) SwigIsPairA() { +} + +var _wrap_PairA_first_set unsafe.Pointer + +func _swig_wrap_PairA_first_set(base SwigcptrPairA, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_PairA_first_set, _swig_p) + return +} + +func (arg1 SwigcptrPairA) SetFirst(arg2 int) { + _swig_wrap_PairA_first_set(arg1, arg2) +} + +var _wrap_PairA_first_get unsafe.Pointer + +func _swig_wrap_PairA_first_get(base SwigcptrPairA) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_PairA_first_get, _swig_p) + return +} + +func (arg1 SwigcptrPairA) GetFirst() (_swig_ret int) { + return _swig_wrap_PairA_first_get(arg1) +} + +var _wrap_PairA_second_set unsafe.Pointer + +func _swig_wrap_PairA_second_set(base SwigcptrPairA, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_PairA_second_set, _swig_p) + return +} + +func (arg1 SwigcptrPairA) SetSecond(arg2 A) { + _swig_wrap_PairA_second_set(arg1, arg2.Swigcptr()) +} + +var _wrap_PairA_second_get unsafe.Pointer + +func _swig_wrap_PairA_second_get(base SwigcptrPairA) (_ SwigcptrA) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_PairA_second_get, _swig_p) + return +} + +func (arg1 SwigcptrPairA) GetSecond() (_swig_ret A) { + return _swig_wrap_PairA_second_get(arg1) +} + +var _wrap_new_PairA unsafe.Pointer + +func _swig_wrap_new_PairA() (base SwigcptrPairA) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_PairA, _swig_p) + return +} + +func NewPairA() (_swig_ret PairA) { + return _swig_wrap_new_PairA() +} + +var _wrap_delete_PairA unsafe.Pointer + +func _swig_wrap_delete_PairA(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_PairA, _swig_p) + return +} + +func DeletePairA(arg1 PairA) { + _swig_wrap_delete_PairA(arg1.Swigcptr()) +} + +type PairA interface { + Swigcptr() uintptr + SwigIsPairA() + SetFirst(arg2 int) + GetFirst() (_swig_ret int) + SetSecond(arg2 A) + GetSecond() (_swig_ret A) +} + +type SwigcptrMultimapA uintptr + +func (p SwigcptrMultimapA) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrMultimapA) SwigIsMultimapA() { +} + +var _wrap_MultimapA_equal_range_1 unsafe.Pointer + +func _swig_wrap_MultimapA_equal_range_1(base SwigcptrMultimapA, _ int) (_ SwigcptrStandard_Pair_Sl_Standard_Multimap_Sl_int_Sc_A_Sm__Sg__iterator_Sc_Standard_Multimap_Sl_int_Sc_A_Sm__Sg__iterator_Sg_) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_MultimapA_equal_range_1, _swig_p) + return +} + +func (arg1 SwigcptrMultimapA) Equal_range_1(arg2 int) (_swig_ret Standard_Pair_Sl_Standard_Multimap_Sl_int_Sc_A_Sm__Sg__iterator_Sc_Standard_Multimap_Sl_int_Sc_A_Sm__Sg__iterator_Sg_) { + return _swig_wrap_MultimapA_equal_range_1(arg1, arg2) +} + +var _wrap_MultimapA_equal_range_2 unsafe.Pointer + +func _swig_wrap_MultimapA_equal_range_2(base SwigcptrMultimapA, _ int) (_ SwigcptrStandard_Pair_Sl_Standard_Multimap_Sl_int_Sc_A_Sm__Sg__const_iterator_Sc_Standard_Multimap_Sl_int_Sc_A_Sm__Sg__const_iterator_Sg_) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_MultimapA_equal_range_2, _swig_p) + return +} + +func (arg1 SwigcptrMultimapA) Equal_range_2(arg2 int) (_swig_ret Standard_Pair_Sl_Standard_Multimap_Sl_int_Sc_A_Sm__Sg__const_iterator_Sc_Standard_Multimap_Sl_int_Sc_A_Sm__Sg__const_iterator_Sg_) { + return _swig_wrap_MultimapA_equal_range_2(arg1, arg2) +} + +var _wrap_new_MultimapA unsafe.Pointer + +func _swig_wrap_new_MultimapA() (base SwigcptrMultimapA) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_MultimapA, _swig_p) + return +} + +func NewMultimapA() (_swig_ret MultimapA) { + return _swig_wrap_new_MultimapA() +} + +var _wrap_delete_MultimapA unsafe.Pointer + +func _swig_wrap_delete_MultimapA(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_MultimapA, _swig_p) + return +} + +func DeleteMultimapA(arg1 MultimapA) { + _swig_wrap_delete_MultimapA(arg1.Swigcptr()) +} + +type MultimapA interface { + Swigcptr() uintptr + SwigIsMultimapA() + Equal_range_1(arg2 int) (_swig_ret Standard_Pair_Sl_Standard_Multimap_Sl_int_Sc_A_Sm__Sg__iterator_Sc_Standard_Multimap_Sl_int_Sc_A_Sm__Sg__iterator_Sg_) + Equal_range_2(arg2 int) (_swig_ret Standard_Pair_Sl_Standard_Multimap_Sl_int_Sc_A_Sm__Sg__const_iterator_Sc_Standard_Multimap_Sl_int_Sc_A_Sm__Sg__const_iterator_Sg_) +} + + +type SwigcptrStandard_Pair_Sl_Standard_Multimap_Sl_int_Sc_A_Sm__Sg__const_iterator_Sc_Standard_Multimap_Sl_int_Sc_A_Sm__Sg__const_iterator_Sg_ uintptr +type Standard_Pair_Sl_Standard_Multimap_Sl_int_Sc_A_Sm__Sg__const_iterator_Sc_Standard_Multimap_Sl_int_Sc_A_Sm__Sg__const_iterator_Sg_ interface { + Swigcptr() uintptr; +} +func (p SwigcptrStandard_Pair_Sl_Standard_Multimap_Sl_int_Sc_A_Sm__Sg__const_iterator_Sc_Standard_Multimap_Sl_int_Sc_A_Sm__Sg__const_iterator_Sg_) Swigcptr() uintptr { + return uintptr(p) +} + +type SwigcptrStandard_Pair_Sl_Standard_Multimap_Sl_int_Sc_A_Sm__Sg__iterator_Sc_Standard_Multimap_Sl_int_Sc_A_Sm__Sg__iterator_Sg_ uintptr +type Standard_Pair_Sl_Standard_Multimap_Sl_int_Sc_A_Sm__Sg__iterator_Sc_Standard_Multimap_Sl_int_Sc_A_Sm__Sg__iterator_Sg_ interface { + Swigcptr() uintptr; +} +func (p SwigcptrStandard_Pair_Sl_Standard_Multimap_Sl_int_Sc_A_Sm__Sg__iterator_Sc_Standard_Multimap_Sl_int_Sc_A_Sm__Sg__iterator_Sg_) Swigcptr() uintptr { + return uintptr(p) +} + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/template_typedef_cplx.go b/Examples/test-suite/go/template_typedef_cplx.go new file mode 100644 index 000000000..c84dd2eb9 --- /dev/null +++ b/Examples/test-suite/go/template_typedef_cplx.go @@ -0,0 +1,456 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../template_typedef_cplx.i + +package template_typedef_cplx + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrUnaryFunctionBase uintptr + +func (p SwigcptrUnaryFunctionBase) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrUnaryFunctionBase) SwigIsUnaryFunctionBase() { +} + +var _wrap_new_UnaryFunctionBase unsafe.Pointer + +func _swig_wrap_new_UnaryFunctionBase() (base SwigcptrUnaryFunctionBase) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_UnaryFunctionBase, _swig_p) + return +} + +func NewUnaryFunctionBase() (_swig_ret UnaryFunctionBase) { + return _swig_wrap_new_UnaryFunctionBase() +} + +var _wrap_delete_UnaryFunctionBase unsafe.Pointer + +func _swig_wrap_delete_UnaryFunctionBase(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_UnaryFunctionBase, _swig_p) + return +} + +func DeleteUnaryFunctionBase(arg1 UnaryFunctionBase) { + _swig_wrap_delete_UnaryFunctionBase(arg1.Swigcptr()) +} + +type UnaryFunctionBase interface { + Swigcptr() uintptr + SwigIsUnaryFunctionBase() +} + +type SwigcptrUnaryFunction_double_double uintptr + +func (p SwigcptrUnaryFunction_double_double) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrUnaryFunction_double_double) SwigIsUnaryFunction_double_double() { +} + +var _wrap_new_UnaryFunction_double_double unsafe.Pointer + +func _swig_wrap_new_UnaryFunction_double_double() (base SwigcptrUnaryFunction_double_double) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_UnaryFunction_double_double, _swig_p) + return +} + +func NewUnaryFunction_double_double() (_swig_ret UnaryFunction_double_double) { + return _swig_wrap_new_UnaryFunction_double_double() +} + +var _wrap_delete_UnaryFunction_double_double unsafe.Pointer + +func _swig_wrap_delete_UnaryFunction_double_double(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_UnaryFunction_double_double, _swig_p) + return +} + +func DeleteUnaryFunction_double_double(arg1 UnaryFunction_double_double) { + _swig_wrap_delete_UnaryFunction_double_double(arg1.Swigcptr()) +} + +func (p SwigcptrUnaryFunction_double_double) SwigIsUnaryFunctionBase() { +} + +func (p SwigcptrUnaryFunction_double_double) SwigGetUnaryFunctionBase() UnaryFunctionBase { + return SwigcptrUnaryFunctionBase(p.Swigcptr()) +} + +type UnaryFunction_double_double interface { + Swigcptr() uintptr + SwigIsUnaryFunction_double_double() + SwigIsUnaryFunctionBase() + SwigGetUnaryFunctionBase() UnaryFunctionBase +} + +type SwigcptrArithUnaryFunction_double_double uintptr + +func (p SwigcptrArithUnaryFunction_double_double) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrArithUnaryFunction_double_double) SwigIsArithUnaryFunction_double_double() { +} + +var _wrap_new_ArithUnaryFunction_double_double unsafe.Pointer + +func _swig_wrap_new_ArithUnaryFunction_double_double() (base SwigcptrArithUnaryFunction_double_double) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_ArithUnaryFunction_double_double, _swig_p) + return +} + +func NewArithUnaryFunction_double_double() (_swig_ret ArithUnaryFunction_double_double) { + return _swig_wrap_new_ArithUnaryFunction_double_double() +} + +var _wrap_delete_ArithUnaryFunction_double_double unsafe.Pointer + +func _swig_wrap_delete_ArithUnaryFunction_double_double(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_ArithUnaryFunction_double_double, _swig_p) + return +} + +func DeleteArithUnaryFunction_double_double(arg1 ArithUnaryFunction_double_double) { + _swig_wrap_delete_ArithUnaryFunction_double_double(arg1.Swigcptr()) +} + +func (p SwigcptrArithUnaryFunction_double_double) SwigIsUnaryFunction_double_double() { +} + +func (p SwigcptrArithUnaryFunction_double_double) SwigGetUnaryFunction_double_double() UnaryFunction_double_double { + return SwigcptrUnaryFunction_double_double(p.Swigcptr()) +} + +func (p SwigcptrArithUnaryFunction_double_double) SwigIsUnaryFunctionBase() { +} + +func (p SwigcptrArithUnaryFunction_double_double) SwigGetUnaryFunctionBase() UnaryFunctionBase { + return SwigcptrUnaryFunctionBase(p.Swigcptr()) +} + +type ArithUnaryFunction_double_double interface { + Swigcptr() uintptr + SwigIsArithUnaryFunction_double_double() + SwigIsUnaryFunction_double_double() + SwigGetUnaryFunction_double_double() UnaryFunction_double_double + SwigIsUnaryFunctionBase() + SwigGetUnaryFunctionBase() UnaryFunctionBase +} + +var _wrap_make_Identity_double unsafe.Pointer + +func _swig_wrap_make_Identity_double() (base SwigcptrArithUnaryFunction_double_double) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_make_Identity_double, _swig_p) + return +} + +func Make_Identity_double() (_swig_ret ArithUnaryFunction_double_double) { + return _swig_wrap_make_Identity_double() +} + +type SwigcptrUnaryFunction_complex_complex uintptr + +func (p SwigcptrUnaryFunction_complex_complex) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrUnaryFunction_complex_complex) SwigIsUnaryFunction_complex_complex() { +} + +var _wrap_new_UnaryFunction_complex_complex unsafe.Pointer + +func _swig_wrap_new_UnaryFunction_complex_complex() (base SwigcptrUnaryFunction_complex_complex) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_UnaryFunction_complex_complex, _swig_p) + return +} + +func NewUnaryFunction_complex_complex() (_swig_ret UnaryFunction_complex_complex) { + return _swig_wrap_new_UnaryFunction_complex_complex() +} + +var _wrap_delete_UnaryFunction_complex_complex unsafe.Pointer + +func _swig_wrap_delete_UnaryFunction_complex_complex(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_UnaryFunction_complex_complex, _swig_p) + return +} + +func DeleteUnaryFunction_complex_complex(arg1 UnaryFunction_complex_complex) { + _swig_wrap_delete_UnaryFunction_complex_complex(arg1.Swigcptr()) +} + +func (p SwigcptrUnaryFunction_complex_complex) SwigIsUnaryFunctionBase() { +} + +func (p SwigcptrUnaryFunction_complex_complex) SwigGetUnaryFunctionBase() UnaryFunctionBase { + return SwigcptrUnaryFunctionBase(p.Swigcptr()) +} + +type UnaryFunction_complex_complex interface { + Swigcptr() uintptr + SwigIsUnaryFunction_complex_complex() + SwigIsUnaryFunctionBase() + SwigGetUnaryFunctionBase() UnaryFunctionBase +} + +type SwigcptrArithUnaryFunction_complex_complex uintptr + +func (p SwigcptrArithUnaryFunction_complex_complex) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrArithUnaryFunction_complex_complex) SwigIsArithUnaryFunction_complex_complex() { +} + +var _wrap_new_ArithUnaryFunction_complex_complex unsafe.Pointer + +func _swig_wrap_new_ArithUnaryFunction_complex_complex() (base SwigcptrArithUnaryFunction_complex_complex) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_ArithUnaryFunction_complex_complex, _swig_p) + return +} + +func NewArithUnaryFunction_complex_complex() (_swig_ret ArithUnaryFunction_complex_complex) { + return _swig_wrap_new_ArithUnaryFunction_complex_complex() +} + +var _wrap_delete_ArithUnaryFunction_complex_complex unsafe.Pointer + +func _swig_wrap_delete_ArithUnaryFunction_complex_complex(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_ArithUnaryFunction_complex_complex, _swig_p) + return +} + +func DeleteArithUnaryFunction_complex_complex(arg1 ArithUnaryFunction_complex_complex) { + _swig_wrap_delete_ArithUnaryFunction_complex_complex(arg1.Swigcptr()) +} + +func (p SwigcptrArithUnaryFunction_complex_complex) SwigIsUnaryFunction_complex_complex() { +} + +func (p SwigcptrArithUnaryFunction_complex_complex) SwigGetUnaryFunction_complex_complex() UnaryFunction_complex_complex { + return SwigcptrUnaryFunction_complex_complex(p.Swigcptr()) +} + +func (p SwigcptrArithUnaryFunction_complex_complex) SwigIsUnaryFunctionBase() { +} + +func (p SwigcptrArithUnaryFunction_complex_complex) SwigGetUnaryFunctionBase() UnaryFunctionBase { + return SwigcptrUnaryFunctionBase(p.Swigcptr()) +} + +type ArithUnaryFunction_complex_complex interface { + Swigcptr() uintptr + SwigIsArithUnaryFunction_complex_complex() + SwigIsUnaryFunction_complex_complex() + SwigGetUnaryFunction_complex_complex() UnaryFunction_complex_complex + SwigIsUnaryFunctionBase() + SwigGetUnaryFunctionBase() UnaryFunctionBase +} + +var _wrap_make_Identity_complex unsafe.Pointer + +func _swig_wrap_make_Identity_complex() (base SwigcptrArithUnaryFunction_complex_complex) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_make_Identity_complex, _swig_p) + return +} + +func Make_Identity_complex() (_swig_ret ArithUnaryFunction_complex_complex) { + return _swig_wrap_make_Identity_complex() +} + +type SwigcptrUnaryFunction_double_complex uintptr + +func (p SwigcptrUnaryFunction_double_complex) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrUnaryFunction_double_complex) SwigIsUnaryFunction_double_complex() { +} + +var _wrap_new_UnaryFunction_double_complex unsafe.Pointer + +func _swig_wrap_new_UnaryFunction_double_complex() (base SwigcptrUnaryFunction_double_complex) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_UnaryFunction_double_complex, _swig_p) + return +} + +func NewUnaryFunction_double_complex() (_swig_ret UnaryFunction_double_complex) { + return _swig_wrap_new_UnaryFunction_double_complex() +} + +var _wrap_delete_UnaryFunction_double_complex unsafe.Pointer + +func _swig_wrap_delete_UnaryFunction_double_complex(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_UnaryFunction_double_complex, _swig_p) + return +} + +func DeleteUnaryFunction_double_complex(arg1 UnaryFunction_double_complex) { + _swig_wrap_delete_UnaryFunction_double_complex(arg1.Swigcptr()) +} + +func (p SwigcptrUnaryFunction_double_complex) SwigIsUnaryFunctionBase() { +} + +func (p SwigcptrUnaryFunction_double_complex) SwigGetUnaryFunctionBase() UnaryFunctionBase { + return SwigcptrUnaryFunctionBase(p.Swigcptr()) +} + +type UnaryFunction_double_complex interface { + Swigcptr() uintptr + SwigIsUnaryFunction_double_complex() + SwigIsUnaryFunctionBase() + SwigGetUnaryFunctionBase() UnaryFunctionBase +} + +type SwigcptrArithUnaryFunction_double_complex uintptr + +func (p SwigcptrArithUnaryFunction_double_complex) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrArithUnaryFunction_double_complex) SwigIsArithUnaryFunction_double_complex() { +} + +var _wrap_new_ArithUnaryFunction_double_complex unsafe.Pointer + +func _swig_wrap_new_ArithUnaryFunction_double_complex() (base SwigcptrArithUnaryFunction_double_complex) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_ArithUnaryFunction_double_complex, _swig_p) + return +} + +func NewArithUnaryFunction_double_complex() (_swig_ret ArithUnaryFunction_double_complex) { + return _swig_wrap_new_ArithUnaryFunction_double_complex() +} + +var _wrap_delete_ArithUnaryFunction_double_complex unsafe.Pointer + +func _swig_wrap_delete_ArithUnaryFunction_double_complex(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_ArithUnaryFunction_double_complex, _swig_p) + return +} + +func DeleteArithUnaryFunction_double_complex(arg1 ArithUnaryFunction_double_complex) { + _swig_wrap_delete_ArithUnaryFunction_double_complex(arg1.Swigcptr()) +} + +func (p SwigcptrArithUnaryFunction_double_complex) SwigIsUnaryFunction_double_complex() { +} + +func (p SwigcptrArithUnaryFunction_double_complex) SwigGetUnaryFunction_double_complex() UnaryFunction_double_complex { + return SwigcptrUnaryFunction_double_complex(p.Swigcptr()) +} + +func (p SwigcptrArithUnaryFunction_double_complex) SwigIsUnaryFunctionBase() { +} + +func (p SwigcptrArithUnaryFunction_double_complex) SwigGetUnaryFunctionBase() UnaryFunctionBase { + return SwigcptrUnaryFunctionBase(p.Swigcptr()) +} + +type ArithUnaryFunction_double_complex interface { + Swigcptr() uintptr + SwigIsArithUnaryFunction_double_complex() + SwigIsUnaryFunction_double_complex() + SwigGetUnaryFunction_double_complex() UnaryFunction_double_complex + SwigIsUnaryFunctionBase() + SwigGetUnaryFunctionBase() UnaryFunctionBase +} + +var _wrap_make_Multiplies_double_double_complex_complex unsafe.Pointer + +func _swig_wrap_make_Multiplies_double_double_complex_complex(base uintptr, _ uintptr) (_ SwigcptrArithUnaryFunction_double_complex) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_make_Multiplies_double_double_complex_complex, _swig_p) + return +} + +func Make_Multiplies_double_double_complex_complex(arg1 ArithUnaryFunction_double_double, arg2 ArithUnaryFunction_complex_complex) (_swig_ret ArithUnaryFunction_double_complex) { + return _swig_wrap_make_Multiplies_double_double_complex_complex(arg1.Swigcptr(), arg2.Swigcptr()) +} + +var _wrap_make_Multiplies_double_double_double_double unsafe.Pointer + +func _swig_wrap_make_Multiplies_double_double_double_double(base uintptr, _ uintptr) (_ SwigcptrArithUnaryFunction_double_double) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_make_Multiplies_double_double_double_double, _swig_p) + return +} + +func Make_Multiplies_double_double_double_double(arg1 ArithUnaryFunction_double_double, arg2 ArithUnaryFunction_double_double) (_swig_ret ArithUnaryFunction_double_double) { + return _swig_wrap_make_Multiplies_double_double_double_double(arg1.Swigcptr(), arg2.Swigcptr()) +} + +var _wrap_make_Multiplies_complex_complex_complex_complex unsafe.Pointer + +func _swig_wrap_make_Multiplies_complex_complex_complex_complex(base uintptr, _ uintptr) (_ SwigcptrArithUnaryFunction_complex_complex) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_make_Multiplies_complex_complex_complex_complex, _swig_p) + return +} + +func Make_Multiplies_complex_complex_complex_complex(arg1 ArithUnaryFunction_complex_complex, arg2 ArithUnaryFunction_complex_complex) (_swig_ret ArithUnaryFunction_complex_complex) { + return _swig_wrap_make_Multiplies_complex_complex_complex_complex(arg1.Swigcptr(), arg2.Swigcptr()) +} + +var _wrap_make_Multiplies_complex_complex_double_double unsafe.Pointer + +func _swig_wrap_make_Multiplies_complex_complex_double_double(base uintptr, _ uintptr) (_ SwigcptrArithUnaryFunction_double_complex) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_make_Multiplies_complex_complex_double_double, _swig_p) + return +} + +func Make_Multiplies_complex_complex_double_double(arg1 ArithUnaryFunction_complex_complex, arg2 ArithUnaryFunction_double_double) (_swig_ret ArithUnaryFunction_double_complex) { + return _swig_wrap_make_Multiplies_complex_complex_double_double(arg1.Swigcptr(), arg2.Swigcptr()) +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/template_typedef_cplx2.go b/Examples/test-suite/go/template_typedef_cplx2.go new file mode 100644 index 000000000..36ecb343f --- /dev/null +++ b/Examples/test-suite/go/template_typedef_cplx2.go @@ -0,0 +1,664 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../template_typedef_cplx2.i + +package template_typedef_cplx2 + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrUnaryFunctionBase uintptr + +func (p SwigcptrUnaryFunctionBase) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrUnaryFunctionBase) SwigIsUnaryFunctionBase() { +} + +var _wrap_UnaryFunctionBase_get_base_value unsafe.Pointer + +func _swig_wrap_UnaryFunctionBase_get_base_value(base SwigcptrUnaryFunctionBase) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_UnaryFunctionBase_get_base_value, _swig_p) + return +} + +func (arg1 SwigcptrUnaryFunctionBase) Get_base_value() (_swig_ret int) { + return _swig_wrap_UnaryFunctionBase_get_base_value(arg1) +} + +var _wrap_new_UnaryFunctionBase unsafe.Pointer + +func _swig_wrap_new_UnaryFunctionBase() (base SwigcptrUnaryFunctionBase) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_UnaryFunctionBase, _swig_p) + return +} + +func NewUnaryFunctionBase() (_swig_ret UnaryFunctionBase) { + return _swig_wrap_new_UnaryFunctionBase() +} + +var _wrap_delete_UnaryFunctionBase unsafe.Pointer + +func _swig_wrap_delete_UnaryFunctionBase(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_UnaryFunctionBase, _swig_p) + return +} + +func DeleteUnaryFunctionBase(arg1 UnaryFunctionBase) { + _swig_wrap_delete_UnaryFunctionBase(arg1.Swigcptr()) +} + +type UnaryFunctionBase interface { + Swigcptr() uintptr + SwigIsUnaryFunctionBase() + Get_base_value() (_swig_ret int) +} + +type SwigcptrUnaryFunction_double_double uintptr + +func (p SwigcptrUnaryFunction_double_double) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrUnaryFunction_double_double) SwigIsUnaryFunction_double_double() { +} + +var _wrap_UnaryFunction_double_double_get_value unsafe.Pointer + +func _swig_wrap_UnaryFunction_double_double_get_value(base SwigcptrUnaryFunction_double_double) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_UnaryFunction_double_double_get_value, _swig_p) + return +} + +func (arg1 SwigcptrUnaryFunction_double_double) Get_value() (_swig_ret int) { + return _swig_wrap_UnaryFunction_double_double_get_value(arg1) +} + +var _wrap_new_UnaryFunction_double_double unsafe.Pointer + +func _swig_wrap_new_UnaryFunction_double_double() (base SwigcptrUnaryFunction_double_double) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_UnaryFunction_double_double, _swig_p) + return +} + +func NewUnaryFunction_double_double() (_swig_ret UnaryFunction_double_double) { + return _swig_wrap_new_UnaryFunction_double_double() +} + +var _wrap_delete_UnaryFunction_double_double unsafe.Pointer + +func _swig_wrap_delete_UnaryFunction_double_double(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_UnaryFunction_double_double, _swig_p) + return +} + +func DeleteUnaryFunction_double_double(arg1 UnaryFunction_double_double) { + _swig_wrap_delete_UnaryFunction_double_double(arg1.Swigcptr()) +} + +var _wrap_UnaryFunction_double_double_get_base_value unsafe.Pointer + +func _swig_wrap_UnaryFunction_double_double_get_base_value(base SwigcptrUnaryFunction_double_double) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_UnaryFunction_double_double_get_base_value, _swig_p) + return +} + +func (_swig_base SwigcptrUnaryFunction_double_double) Get_base_value() (_swig_ret int) { + return _swig_wrap_UnaryFunction_double_double_get_base_value(_swig_base) +} + +func (p SwigcptrUnaryFunction_double_double) SwigIsUnaryFunctionBase() { +} + +func (p SwigcptrUnaryFunction_double_double) SwigGetUnaryFunctionBase() UnaryFunctionBase { + return SwigcptrUnaryFunctionBase(p.Swigcptr()) +} + +type UnaryFunction_double_double interface { + Swigcptr() uintptr + SwigIsUnaryFunction_double_double() + Get_value() (_swig_ret int) + Get_base_value() (_swig_ret int) + SwigIsUnaryFunctionBase() + SwigGetUnaryFunctionBase() UnaryFunctionBase +} + +type SwigcptrArithUnaryFunction_double_double uintptr + +func (p SwigcptrArithUnaryFunction_double_double) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrArithUnaryFunction_double_double) SwigIsArithUnaryFunction_double_double() { +} + +var _wrap_ArithUnaryFunction_double_double_get_arith_value unsafe.Pointer + +func _swig_wrap_ArithUnaryFunction_double_double_get_arith_value(base SwigcptrArithUnaryFunction_double_double) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_ArithUnaryFunction_double_double_get_arith_value, _swig_p) + return +} + +func (arg1 SwigcptrArithUnaryFunction_double_double) Get_arith_value() (_swig_ret int) { + return _swig_wrap_ArithUnaryFunction_double_double_get_arith_value(arg1) +} + +var _wrap_new_ArithUnaryFunction_double_double unsafe.Pointer + +func _swig_wrap_new_ArithUnaryFunction_double_double() (base SwigcptrArithUnaryFunction_double_double) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_ArithUnaryFunction_double_double, _swig_p) + return +} + +func NewArithUnaryFunction_double_double() (_swig_ret ArithUnaryFunction_double_double) { + return _swig_wrap_new_ArithUnaryFunction_double_double() +} + +var _wrap_delete_ArithUnaryFunction_double_double unsafe.Pointer + +func _swig_wrap_delete_ArithUnaryFunction_double_double(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_ArithUnaryFunction_double_double, _swig_p) + return +} + +func DeleteArithUnaryFunction_double_double(arg1 ArithUnaryFunction_double_double) { + _swig_wrap_delete_ArithUnaryFunction_double_double(arg1.Swigcptr()) +} + +var _wrap_ArithUnaryFunction_double_double_get_value unsafe.Pointer + +func _swig_wrap_ArithUnaryFunction_double_double_get_value(base SwigcptrArithUnaryFunction_double_double) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_ArithUnaryFunction_double_double_get_value, _swig_p) + return +} + +func (_swig_base SwigcptrArithUnaryFunction_double_double) Get_value() (_swig_ret int) { + return _swig_wrap_ArithUnaryFunction_double_double_get_value(_swig_base) +} + +var _wrap_ArithUnaryFunction_double_double_get_base_value unsafe.Pointer + +func _swig_wrap_ArithUnaryFunction_double_double_get_base_value(base SwigcptrArithUnaryFunction_double_double) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_ArithUnaryFunction_double_double_get_base_value, _swig_p) + return +} + +func (_swig_base SwigcptrArithUnaryFunction_double_double) Get_base_value() (_swig_ret int) { + return _swig_wrap_ArithUnaryFunction_double_double_get_base_value(_swig_base) +} + +func (p SwigcptrArithUnaryFunction_double_double) SwigIsUnaryFunction_double_double() { +} + +func (p SwigcptrArithUnaryFunction_double_double) SwigGetUnaryFunction_double_double() UnaryFunction_double_double { + return SwigcptrUnaryFunction_double_double(p.Swigcptr()) +} + +func (p SwigcptrArithUnaryFunction_double_double) SwigIsUnaryFunctionBase() { +} + +func (p SwigcptrArithUnaryFunction_double_double) SwigGetUnaryFunctionBase() UnaryFunctionBase { + return SwigcptrUnaryFunctionBase(p.Swigcptr()) +} + +type ArithUnaryFunction_double_double interface { + Swigcptr() uintptr + SwigIsArithUnaryFunction_double_double() + Get_arith_value() (_swig_ret int) + Get_value() (_swig_ret int) + Get_base_value() (_swig_ret int) + SwigIsUnaryFunction_double_double() + SwigGetUnaryFunction_double_double() UnaryFunction_double_double + SwigIsUnaryFunctionBase() + SwigGetUnaryFunctionBase() UnaryFunctionBase +} + +var _wrap_make_Identity_double unsafe.Pointer + +func _swig_wrap_make_Identity_double() (base SwigcptrArithUnaryFunction_double_double) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_make_Identity_double, _swig_p) + return +} + +func Make_Identity_double() (_swig_ret ArithUnaryFunction_double_double) { + return _swig_wrap_make_Identity_double() +} + +type SwigcptrUnaryFunction_complex_complex uintptr + +func (p SwigcptrUnaryFunction_complex_complex) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrUnaryFunction_complex_complex) SwigIsUnaryFunction_complex_complex() { +} + +var _wrap_UnaryFunction_complex_complex_get_value unsafe.Pointer + +func _swig_wrap_UnaryFunction_complex_complex_get_value(base SwigcptrUnaryFunction_complex_complex) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_UnaryFunction_complex_complex_get_value, _swig_p) + return +} + +func (arg1 SwigcptrUnaryFunction_complex_complex) Get_value() (_swig_ret int) { + return _swig_wrap_UnaryFunction_complex_complex_get_value(arg1) +} + +var _wrap_new_UnaryFunction_complex_complex unsafe.Pointer + +func _swig_wrap_new_UnaryFunction_complex_complex() (base SwigcptrUnaryFunction_complex_complex) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_UnaryFunction_complex_complex, _swig_p) + return +} + +func NewUnaryFunction_complex_complex() (_swig_ret UnaryFunction_complex_complex) { + return _swig_wrap_new_UnaryFunction_complex_complex() +} + +var _wrap_delete_UnaryFunction_complex_complex unsafe.Pointer + +func _swig_wrap_delete_UnaryFunction_complex_complex(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_UnaryFunction_complex_complex, _swig_p) + return +} + +func DeleteUnaryFunction_complex_complex(arg1 UnaryFunction_complex_complex) { + _swig_wrap_delete_UnaryFunction_complex_complex(arg1.Swigcptr()) +} + +var _wrap_UnaryFunction_complex_complex_get_base_value unsafe.Pointer + +func _swig_wrap_UnaryFunction_complex_complex_get_base_value(base SwigcptrUnaryFunction_complex_complex) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_UnaryFunction_complex_complex_get_base_value, _swig_p) + return +} + +func (_swig_base SwigcptrUnaryFunction_complex_complex) Get_base_value() (_swig_ret int) { + return _swig_wrap_UnaryFunction_complex_complex_get_base_value(_swig_base) +} + +func (p SwigcptrUnaryFunction_complex_complex) SwigIsUnaryFunctionBase() { +} + +func (p SwigcptrUnaryFunction_complex_complex) SwigGetUnaryFunctionBase() UnaryFunctionBase { + return SwigcptrUnaryFunctionBase(p.Swigcptr()) +} + +type UnaryFunction_complex_complex interface { + Swigcptr() uintptr + SwigIsUnaryFunction_complex_complex() + Get_value() (_swig_ret int) + Get_base_value() (_swig_ret int) + SwigIsUnaryFunctionBase() + SwigGetUnaryFunctionBase() UnaryFunctionBase +} + +type SwigcptrArithUnaryFunction_complex_complex uintptr + +func (p SwigcptrArithUnaryFunction_complex_complex) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrArithUnaryFunction_complex_complex) SwigIsArithUnaryFunction_complex_complex() { +} + +var _wrap_ArithUnaryFunction_complex_complex_get_arith_value unsafe.Pointer + +func _swig_wrap_ArithUnaryFunction_complex_complex_get_arith_value(base SwigcptrArithUnaryFunction_complex_complex) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_ArithUnaryFunction_complex_complex_get_arith_value, _swig_p) + return +} + +func (arg1 SwigcptrArithUnaryFunction_complex_complex) Get_arith_value() (_swig_ret int) { + return _swig_wrap_ArithUnaryFunction_complex_complex_get_arith_value(arg1) +} + +var _wrap_new_ArithUnaryFunction_complex_complex unsafe.Pointer + +func _swig_wrap_new_ArithUnaryFunction_complex_complex() (base SwigcptrArithUnaryFunction_complex_complex) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_ArithUnaryFunction_complex_complex, _swig_p) + return +} + +func NewArithUnaryFunction_complex_complex() (_swig_ret ArithUnaryFunction_complex_complex) { + return _swig_wrap_new_ArithUnaryFunction_complex_complex() +} + +var _wrap_delete_ArithUnaryFunction_complex_complex unsafe.Pointer + +func _swig_wrap_delete_ArithUnaryFunction_complex_complex(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_ArithUnaryFunction_complex_complex, _swig_p) + return +} + +func DeleteArithUnaryFunction_complex_complex(arg1 ArithUnaryFunction_complex_complex) { + _swig_wrap_delete_ArithUnaryFunction_complex_complex(arg1.Swigcptr()) +} + +var _wrap_ArithUnaryFunction_complex_complex_get_value unsafe.Pointer + +func _swig_wrap_ArithUnaryFunction_complex_complex_get_value(base SwigcptrArithUnaryFunction_complex_complex) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_ArithUnaryFunction_complex_complex_get_value, _swig_p) + return +} + +func (_swig_base SwigcptrArithUnaryFunction_complex_complex) Get_value() (_swig_ret int) { + return _swig_wrap_ArithUnaryFunction_complex_complex_get_value(_swig_base) +} + +var _wrap_ArithUnaryFunction_complex_complex_get_base_value unsafe.Pointer + +func _swig_wrap_ArithUnaryFunction_complex_complex_get_base_value(base SwigcptrArithUnaryFunction_complex_complex) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_ArithUnaryFunction_complex_complex_get_base_value, _swig_p) + return +} + +func (_swig_base SwigcptrArithUnaryFunction_complex_complex) Get_base_value() (_swig_ret int) { + return _swig_wrap_ArithUnaryFunction_complex_complex_get_base_value(_swig_base) +} + +func (p SwigcptrArithUnaryFunction_complex_complex) SwigIsUnaryFunction_complex_complex() { +} + +func (p SwigcptrArithUnaryFunction_complex_complex) SwigGetUnaryFunction_complex_complex() UnaryFunction_complex_complex { + return SwigcptrUnaryFunction_complex_complex(p.Swigcptr()) +} + +func (p SwigcptrArithUnaryFunction_complex_complex) SwigIsUnaryFunctionBase() { +} + +func (p SwigcptrArithUnaryFunction_complex_complex) SwigGetUnaryFunctionBase() UnaryFunctionBase { + return SwigcptrUnaryFunctionBase(p.Swigcptr()) +} + +type ArithUnaryFunction_complex_complex interface { + Swigcptr() uintptr + SwigIsArithUnaryFunction_complex_complex() + Get_arith_value() (_swig_ret int) + Get_value() (_swig_ret int) + Get_base_value() (_swig_ret int) + SwigIsUnaryFunction_complex_complex() + SwigGetUnaryFunction_complex_complex() UnaryFunction_complex_complex + SwigIsUnaryFunctionBase() + SwigGetUnaryFunctionBase() UnaryFunctionBase +} + +var _wrap_make_Identity_complex unsafe.Pointer + +func _swig_wrap_make_Identity_complex() (base SwigcptrArithUnaryFunction_complex_complex) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_make_Identity_complex, _swig_p) + return +} + +func Make_Identity_complex() (_swig_ret ArithUnaryFunction_complex_complex) { + return _swig_wrap_make_Identity_complex() +} + +type SwigcptrUnaryFunction_double_complex uintptr + +func (p SwigcptrUnaryFunction_double_complex) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrUnaryFunction_double_complex) SwigIsUnaryFunction_double_complex() { +} + +var _wrap_UnaryFunction_double_complex_get_value unsafe.Pointer + +func _swig_wrap_UnaryFunction_double_complex_get_value(base SwigcptrUnaryFunction_double_complex) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_UnaryFunction_double_complex_get_value, _swig_p) + return +} + +func (arg1 SwigcptrUnaryFunction_double_complex) Get_value() (_swig_ret int) { + return _swig_wrap_UnaryFunction_double_complex_get_value(arg1) +} + +var _wrap_new_UnaryFunction_double_complex unsafe.Pointer + +func _swig_wrap_new_UnaryFunction_double_complex() (base SwigcptrUnaryFunction_double_complex) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_UnaryFunction_double_complex, _swig_p) + return +} + +func NewUnaryFunction_double_complex() (_swig_ret UnaryFunction_double_complex) { + return _swig_wrap_new_UnaryFunction_double_complex() +} + +var _wrap_delete_UnaryFunction_double_complex unsafe.Pointer + +func _swig_wrap_delete_UnaryFunction_double_complex(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_UnaryFunction_double_complex, _swig_p) + return +} + +func DeleteUnaryFunction_double_complex(arg1 UnaryFunction_double_complex) { + _swig_wrap_delete_UnaryFunction_double_complex(arg1.Swigcptr()) +} + +var _wrap_UnaryFunction_double_complex_get_base_value unsafe.Pointer + +func _swig_wrap_UnaryFunction_double_complex_get_base_value(base SwigcptrUnaryFunction_double_complex) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_UnaryFunction_double_complex_get_base_value, _swig_p) + return +} + +func (_swig_base SwigcptrUnaryFunction_double_complex) Get_base_value() (_swig_ret int) { + return _swig_wrap_UnaryFunction_double_complex_get_base_value(_swig_base) +} + +func (p SwigcptrUnaryFunction_double_complex) SwigIsUnaryFunctionBase() { +} + +func (p SwigcptrUnaryFunction_double_complex) SwigGetUnaryFunctionBase() UnaryFunctionBase { + return SwigcptrUnaryFunctionBase(p.Swigcptr()) +} + +type UnaryFunction_double_complex interface { + Swigcptr() uintptr + SwigIsUnaryFunction_double_complex() + Get_value() (_swig_ret int) + Get_base_value() (_swig_ret int) + SwigIsUnaryFunctionBase() + SwigGetUnaryFunctionBase() UnaryFunctionBase +} + +type SwigcptrArithUnaryFunction_double_complex uintptr + +func (p SwigcptrArithUnaryFunction_double_complex) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrArithUnaryFunction_double_complex) SwigIsArithUnaryFunction_double_complex() { +} + +var _wrap_ArithUnaryFunction_double_complex_get_arith_value unsafe.Pointer + +func _swig_wrap_ArithUnaryFunction_double_complex_get_arith_value(base SwigcptrArithUnaryFunction_double_complex) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_ArithUnaryFunction_double_complex_get_arith_value, _swig_p) + return +} + +func (arg1 SwigcptrArithUnaryFunction_double_complex) Get_arith_value() (_swig_ret int) { + return _swig_wrap_ArithUnaryFunction_double_complex_get_arith_value(arg1) +} + +var _wrap_new_ArithUnaryFunction_double_complex unsafe.Pointer + +func _swig_wrap_new_ArithUnaryFunction_double_complex() (base SwigcptrArithUnaryFunction_double_complex) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_ArithUnaryFunction_double_complex, _swig_p) + return +} + +func NewArithUnaryFunction_double_complex() (_swig_ret ArithUnaryFunction_double_complex) { + return _swig_wrap_new_ArithUnaryFunction_double_complex() +} + +var _wrap_delete_ArithUnaryFunction_double_complex unsafe.Pointer + +func _swig_wrap_delete_ArithUnaryFunction_double_complex(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_ArithUnaryFunction_double_complex, _swig_p) + return +} + +func DeleteArithUnaryFunction_double_complex(arg1 ArithUnaryFunction_double_complex) { + _swig_wrap_delete_ArithUnaryFunction_double_complex(arg1.Swigcptr()) +} + +var _wrap_ArithUnaryFunction_double_complex_get_value unsafe.Pointer + +func _swig_wrap_ArithUnaryFunction_double_complex_get_value(base SwigcptrArithUnaryFunction_double_complex) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_ArithUnaryFunction_double_complex_get_value, _swig_p) + return +} + +func (_swig_base SwigcptrArithUnaryFunction_double_complex) Get_value() (_swig_ret int) { + return _swig_wrap_ArithUnaryFunction_double_complex_get_value(_swig_base) +} + +var _wrap_ArithUnaryFunction_double_complex_get_base_value unsafe.Pointer + +func _swig_wrap_ArithUnaryFunction_double_complex_get_base_value(base SwigcptrArithUnaryFunction_double_complex) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_ArithUnaryFunction_double_complex_get_base_value, _swig_p) + return +} + +func (_swig_base SwigcptrArithUnaryFunction_double_complex) Get_base_value() (_swig_ret int) { + return _swig_wrap_ArithUnaryFunction_double_complex_get_base_value(_swig_base) +} + +func (p SwigcptrArithUnaryFunction_double_complex) SwigIsUnaryFunction_double_complex() { +} + +func (p SwigcptrArithUnaryFunction_double_complex) SwigGetUnaryFunction_double_complex() UnaryFunction_double_complex { + return SwigcptrUnaryFunction_double_complex(p.Swigcptr()) +} + +func (p SwigcptrArithUnaryFunction_double_complex) SwigIsUnaryFunctionBase() { +} + +func (p SwigcptrArithUnaryFunction_double_complex) SwigGetUnaryFunctionBase() UnaryFunctionBase { + return SwigcptrUnaryFunctionBase(p.Swigcptr()) +} + +type ArithUnaryFunction_double_complex interface { + Swigcptr() uintptr + SwigIsArithUnaryFunction_double_complex() + Get_arith_value() (_swig_ret int) + Get_value() (_swig_ret int) + Get_base_value() (_swig_ret int) + SwigIsUnaryFunction_double_complex() + SwigGetUnaryFunction_double_complex() UnaryFunction_double_complex + SwigIsUnaryFunctionBase() + SwigGetUnaryFunctionBase() UnaryFunctionBase +} + +var _wrap_make_Multiplies_double_double_complex_complex unsafe.Pointer + +func _swig_wrap_make_Multiplies_double_double_complex_complex(base uintptr, _ uintptr) (_ SwigcptrArithUnaryFunction_double_complex) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_make_Multiplies_double_double_complex_complex, _swig_p) + return +} + +func Make_Multiplies_double_double_complex_complex(arg1 ArithUnaryFunction_double_double, arg2 ArithUnaryFunction_complex_complex) (_swig_ret ArithUnaryFunction_double_complex) { + return _swig_wrap_make_Multiplies_double_double_complex_complex(arg1.Swigcptr(), arg2.Swigcptr()) +} + +var _wrap_make_Multiplies_double_double_double_double unsafe.Pointer + +func _swig_wrap_make_Multiplies_double_double_double_double(base uintptr, _ uintptr) (_ SwigcptrArithUnaryFunction_double_double) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_make_Multiplies_double_double_double_double, _swig_p) + return +} + +func Make_Multiplies_double_double_double_double(arg1 ArithUnaryFunction_double_double, arg2 ArithUnaryFunction_double_double) (_swig_ret ArithUnaryFunction_double_double) { + return _swig_wrap_make_Multiplies_double_double_double_double(arg1.Swigcptr(), arg2.Swigcptr()) +} + +var _wrap_make_Multiplies_complex_complex_complex_complex unsafe.Pointer + +func _swig_wrap_make_Multiplies_complex_complex_complex_complex(base uintptr, _ uintptr) (_ SwigcptrArithUnaryFunction_complex_complex) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_make_Multiplies_complex_complex_complex_complex, _swig_p) + return +} + +func Make_Multiplies_complex_complex_complex_complex(arg1 ArithUnaryFunction_complex_complex, arg2 ArithUnaryFunction_complex_complex) (_swig_ret ArithUnaryFunction_complex_complex) { + return _swig_wrap_make_Multiplies_complex_complex_complex_complex(arg1.Swigcptr(), arg2.Swigcptr()) +} + +var _wrap_make_Multiplies_complex_complex_double_double unsafe.Pointer + +func _swig_wrap_make_Multiplies_complex_complex_double_double(base uintptr, _ uintptr) (_ SwigcptrArithUnaryFunction_double_complex) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_make_Multiplies_complex_complex_double_double, _swig_p) + return +} + +func Make_Multiplies_complex_complex_double_double(arg1 ArithUnaryFunction_complex_complex, arg2 ArithUnaryFunction_double_double) (_swig_ret ArithUnaryFunction_double_complex) { + return _swig_wrap_make_Multiplies_complex_complex_double_double(arg1.Swigcptr(), arg2.Swigcptr()) +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/template_typedef_cplx3.go b/Examples/test-suite/go/template_typedef_cplx3.go new file mode 100644 index 000000000..f11865ec9 --- /dev/null +++ b/Examples/test-suite/go/template_typedef_cplx3.go @@ -0,0 +1,896 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../template_typedef_cplx3.i + +package template_typedef_cplx3 + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrUnaryFunctionBase uintptr + +func (p SwigcptrUnaryFunctionBase) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrUnaryFunctionBase) SwigIsUnaryFunctionBase() { +} + +var _wrap_UnaryFunctionBase_get_base_value unsafe.Pointer + +func _swig_wrap_UnaryFunctionBase_get_base_value(base SwigcptrUnaryFunctionBase) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_UnaryFunctionBase_get_base_value, _swig_p) + return +} + +func (arg1 SwigcptrUnaryFunctionBase) Get_base_value() (_swig_ret int) { + return _swig_wrap_UnaryFunctionBase_get_base_value(arg1) +} + +var _wrap_new_UnaryFunctionBase unsafe.Pointer + +func _swig_wrap_new_UnaryFunctionBase() (base SwigcptrUnaryFunctionBase) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_UnaryFunctionBase, _swig_p) + return +} + +func NewUnaryFunctionBase() (_swig_ret UnaryFunctionBase) { + return _swig_wrap_new_UnaryFunctionBase() +} + +var _wrap_delete_UnaryFunctionBase unsafe.Pointer + +func _swig_wrap_delete_UnaryFunctionBase(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_UnaryFunctionBase, _swig_p) + return +} + +func DeleteUnaryFunctionBase(arg1 UnaryFunctionBase) { + _swig_wrap_delete_UnaryFunctionBase(arg1.Swigcptr()) +} + +type UnaryFunctionBase interface { + Swigcptr() uintptr + SwigIsUnaryFunctionBase() + Get_base_value() (_swig_ret int) +} + +type SwigcptrUnaryFunction_double_double uintptr + +func (p SwigcptrUnaryFunction_double_double) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrUnaryFunction_double_double) SwigIsUnaryFunction_double_double() { +} + +var _wrap_UnaryFunction_double_double_get_value unsafe.Pointer + +func _swig_wrap_UnaryFunction_double_double_get_value(base SwigcptrUnaryFunction_double_double) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_UnaryFunction_double_double_get_value, _swig_p) + return +} + +func (arg1 SwigcptrUnaryFunction_double_double) Get_value() (_swig_ret int) { + return _swig_wrap_UnaryFunction_double_double_get_value(arg1) +} + +var _wrap_new_UnaryFunction_double_double unsafe.Pointer + +func _swig_wrap_new_UnaryFunction_double_double() (base SwigcptrUnaryFunction_double_double) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_UnaryFunction_double_double, _swig_p) + return +} + +func NewUnaryFunction_double_double() (_swig_ret UnaryFunction_double_double) { + return _swig_wrap_new_UnaryFunction_double_double() +} + +var _wrap_delete_UnaryFunction_double_double unsafe.Pointer + +func _swig_wrap_delete_UnaryFunction_double_double(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_UnaryFunction_double_double, _swig_p) + return +} + +func DeleteUnaryFunction_double_double(arg1 UnaryFunction_double_double) { + _swig_wrap_delete_UnaryFunction_double_double(arg1.Swigcptr()) +} + +var _wrap_UnaryFunction_double_double_get_base_value unsafe.Pointer + +func _swig_wrap_UnaryFunction_double_double_get_base_value(base SwigcptrUnaryFunction_double_double) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_UnaryFunction_double_double_get_base_value, _swig_p) + return +} + +func (_swig_base SwigcptrUnaryFunction_double_double) Get_base_value() (_swig_ret int) { + return _swig_wrap_UnaryFunction_double_double_get_base_value(_swig_base) +} + +func (p SwigcptrUnaryFunction_double_double) SwigIsUnaryFunctionBase() { +} + +func (p SwigcptrUnaryFunction_double_double) SwigGetUnaryFunctionBase() UnaryFunctionBase { + return SwigcptrUnaryFunctionBase(p.Swigcptr()) +} + +type UnaryFunction_double_double interface { + Swigcptr() uintptr + SwigIsUnaryFunction_double_double() + Get_value() (_swig_ret int) + Get_base_value() (_swig_ret int) + SwigIsUnaryFunctionBase() + SwigGetUnaryFunctionBase() UnaryFunctionBase +} + +type SwigcptrArithUnaryFunction_double_double uintptr + +func (p SwigcptrArithUnaryFunction_double_double) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrArithUnaryFunction_double_double) SwigIsArithUnaryFunction_double_double() { +} + +var _wrap_ArithUnaryFunction_double_double_get_arith_value unsafe.Pointer + +func _swig_wrap_ArithUnaryFunction_double_double_get_arith_value(base SwigcptrArithUnaryFunction_double_double) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_ArithUnaryFunction_double_double_get_arith_value, _swig_p) + return +} + +func (arg1 SwigcptrArithUnaryFunction_double_double) Get_arith_value() (_swig_ret int) { + return _swig_wrap_ArithUnaryFunction_double_double_get_arith_value(arg1) +} + +var _wrap_new_ArithUnaryFunction_double_double unsafe.Pointer + +func _swig_wrap_new_ArithUnaryFunction_double_double() (base SwigcptrArithUnaryFunction_double_double) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_ArithUnaryFunction_double_double, _swig_p) + return +} + +func NewArithUnaryFunction_double_double() (_swig_ret ArithUnaryFunction_double_double) { + return _swig_wrap_new_ArithUnaryFunction_double_double() +} + +var _wrap_delete_ArithUnaryFunction_double_double unsafe.Pointer + +func _swig_wrap_delete_ArithUnaryFunction_double_double(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_ArithUnaryFunction_double_double, _swig_p) + return +} + +func DeleteArithUnaryFunction_double_double(arg1 ArithUnaryFunction_double_double) { + _swig_wrap_delete_ArithUnaryFunction_double_double(arg1.Swigcptr()) +} + +var _wrap_ArithUnaryFunction_double_double_get_value unsafe.Pointer + +func _swig_wrap_ArithUnaryFunction_double_double_get_value(base SwigcptrArithUnaryFunction_double_double) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_ArithUnaryFunction_double_double_get_value, _swig_p) + return +} + +func (_swig_base SwigcptrArithUnaryFunction_double_double) Get_value() (_swig_ret int) { + return _swig_wrap_ArithUnaryFunction_double_double_get_value(_swig_base) +} + +var _wrap_ArithUnaryFunction_double_double_get_base_value unsafe.Pointer + +func _swig_wrap_ArithUnaryFunction_double_double_get_base_value(base SwigcptrArithUnaryFunction_double_double) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_ArithUnaryFunction_double_double_get_base_value, _swig_p) + return +} + +func (_swig_base SwigcptrArithUnaryFunction_double_double) Get_base_value() (_swig_ret int) { + return _swig_wrap_ArithUnaryFunction_double_double_get_base_value(_swig_base) +} + +func (p SwigcptrArithUnaryFunction_double_double) SwigIsUnaryFunction_double_double() { +} + +func (p SwigcptrArithUnaryFunction_double_double) SwigGetUnaryFunction_double_double() UnaryFunction_double_double { + return SwigcptrUnaryFunction_double_double(p.Swigcptr()) +} + +func (p SwigcptrArithUnaryFunction_double_double) SwigIsUnaryFunctionBase() { +} + +func (p SwigcptrArithUnaryFunction_double_double) SwigGetUnaryFunctionBase() UnaryFunctionBase { + return SwigcptrUnaryFunctionBase(p.Swigcptr()) +} + +type ArithUnaryFunction_double_double interface { + Swigcptr() uintptr + SwigIsArithUnaryFunction_double_double() + Get_arith_value() (_swig_ret int) + Get_value() (_swig_ret int) + Get_base_value() (_swig_ret int) + SwigIsUnaryFunction_double_double() + SwigGetUnaryFunction_double_double() UnaryFunction_double_double + SwigIsUnaryFunctionBase() + SwigGetUnaryFunctionBase() UnaryFunctionBase +} + +var _wrap_make_Identity_double unsafe.Pointer + +func _swig_wrap_make_Identity_double() (base SwigcptrArithUnaryFunction_double_double) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_make_Identity_double, _swig_p) + return +} + +func Make_Identity_double() (_swig_ret ArithUnaryFunction_double_double) { + return _swig_wrap_make_Identity_double() +} + +type SwigcptrUnaryFunction_complex_complex uintptr + +func (p SwigcptrUnaryFunction_complex_complex) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrUnaryFunction_complex_complex) SwigIsUnaryFunction_complex_complex() { +} + +var _wrap_UnaryFunction_complex_complex_get_value unsafe.Pointer + +func _swig_wrap_UnaryFunction_complex_complex_get_value(base SwigcptrUnaryFunction_complex_complex) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_UnaryFunction_complex_complex_get_value, _swig_p) + return +} + +func (arg1 SwigcptrUnaryFunction_complex_complex) Get_value() (_swig_ret int) { + return _swig_wrap_UnaryFunction_complex_complex_get_value(arg1) +} + +var _wrap_new_UnaryFunction_complex_complex unsafe.Pointer + +func _swig_wrap_new_UnaryFunction_complex_complex() (base SwigcptrUnaryFunction_complex_complex) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_UnaryFunction_complex_complex, _swig_p) + return +} + +func NewUnaryFunction_complex_complex() (_swig_ret UnaryFunction_complex_complex) { + return _swig_wrap_new_UnaryFunction_complex_complex() +} + +var _wrap_delete_UnaryFunction_complex_complex unsafe.Pointer + +func _swig_wrap_delete_UnaryFunction_complex_complex(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_UnaryFunction_complex_complex, _swig_p) + return +} + +func DeleteUnaryFunction_complex_complex(arg1 UnaryFunction_complex_complex) { + _swig_wrap_delete_UnaryFunction_complex_complex(arg1.Swigcptr()) +} + +var _wrap_UnaryFunction_complex_complex_get_base_value unsafe.Pointer + +func _swig_wrap_UnaryFunction_complex_complex_get_base_value(base SwigcptrUnaryFunction_complex_complex) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_UnaryFunction_complex_complex_get_base_value, _swig_p) + return +} + +func (_swig_base SwigcptrUnaryFunction_complex_complex) Get_base_value() (_swig_ret int) { + return _swig_wrap_UnaryFunction_complex_complex_get_base_value(_swig_base) +} + +func (p SwigcptrUnaryFunction_complex_complex) SwigIsUnaryFunctionBase() { +} + +func (p SwigcptrUnaryFunction_complex_complex) SwigGetUnaryFunctionBase() UnaryFunctionBase { + return SwigcptrUnaryFunctionBase(p.Swigcptr()) +} + +type UnaryFunction_complex_complex interface { + Swigcptr() uintptr + SwigIsUnaryFunction_complex_complex() + Get_value() (_swig_ret int) + Get_base_value() (_swig_ret int) + SwigIsUnaryFunctionBase() + SwigGetUnaryFunctionBase() UnaryFunctionBase +} + +type SwigcptrArithUnaryFunction_complex_complex uintptr + +func (p SwigcptrArithUnaryFunction_complex_complex) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrArithUnaryFunction_complex_complex) SwigIsArithUnaryFunction_complex_complex() { +} + +var _wrap_ArithUnaryFunction_complex_complex_get_arith_value unsafe.Pointer + +func _swig_wrap_ArithUnaryFunction_complex_complex_get_arith_value(base SwigcptrArithUnaryFunction_complex_complex) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_ArithUnaryFunction_complex_complex_get_arith_value, _swig_p) + return +} + +func (arg1 SwigcptrArithUnaryFunction_complex_complex) Get_arith_value() (_swig_ret int) { + return _swig_wrap_ArithUnaryFunction_complex_complex_get_arith_value(arg1) +} + +var _wrap_new_ArithUnaryFunction_complex_complex unsafe.Pointer + +func _swig_wrap_new_ArithUnaryFunction_complex_complex() (base SwigcptrArithUnaryFunction_complex_complex) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_ArithUnaryFunction_complex_complex, _swig_p) + return +} + +func NewArithUnaryFunction_complex_complex() (_swig_ret ArithUnaryFunction_complex_complex) { + return _swig_wrap_new_ArithUnaryFunction_complex_complex() +} + +var _wrap_delete_ArithUnaryFunction_complex_complex unsafe.Pointer + +func _swig_wrap_delete_ArithUnaryFunction_complex_complex(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_ArithUnaryFunction_complex_complex, _swig_p) + return +} + +func DeleteArithUnaryFunction_complex_complex(arg1 ArithUnaryFunction_complex_complex) { + _swig_wrap_delete_ArithUnaryFunction_complex_complex(arg1.Swigcptr()) +} + +var _wrap_ArithUnaryFunction_complex_complex_get_value unsafe.Pointer + +func _swig_wrap_ArithUnaryFunction_complex_complex_get_value(base SwigcptrArithUnaryFunction_complex_complex) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_ArithUnaryFunction_complex_complex_get_value, _swig_p) + return +} + +func (_swig_base SwigcptrArithUnaryFunction_complex_complex) Get_value() (_swig_ret int) { + return _swig_wrap_ArithUnaryFunction_complex_complex_get_value(_swig_base) +} + +var _wrap_ArithUnaryFunction_complex_complex_get_base_value unsafe.Pointer + +func _swig_wrap_ArithUnaryFunction_complex_complex_get_base_value(base SwigcptrArithUnaryFunction_complex_complex) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_ArithUnaryFunction_complex_complex_get_base_value, _swig_p) + return +} + +func (_swig_base SwigcptrArithUnaryFunction_complex_complex) Get_base_value() (_swig_ret int) { + return _swig_wrap_ArithUnaryFunction_complex_complex_get_base_value(_swig_base) +} + +func (p SwigcptrArithUnaryFunction_complex_complex) SwigIsUnaryFunction_complex_complex() { +} + +func (p SwigcptrArithUnaryFunction_complex_complex) SwigGetUnaryFunction_complex_complex() UnaryFunction_complex_complex { + return SwigcptrUnaryFunction_complex_complex(p.Swigcptr()) +} + +func (p SwigcptrArithUnaryFunction_complex_complex) SwigIsUnaryFunctionBase() { +} + +func (p SwigcptrArithUnaryFunction_complex_complex) SwigGetUnaryFunctionBase() UnaryFunctionBase { + return SwigcptrUnaryFunctionBase(p.Swigcptr()) +} + +type ArithUnaryFunction_complex_complex interface { + Swigcptr() uintptr + SwigIsArithUnaryFunction_complex_complex() + Get_arith_value() (_swig_ret int) + Get_value() (_swig_ret int) + Get_base_value() (_swig_ret int) + SwigIsUnaryFunction_complex_complex() + SwigGetUnaryFunction_complex_complex() UnaryFunction_complex_complex + SwigIsUnaryFunctionBase() + SwigGetUnaryFunctionBase() UnaryFunctionBase +} + +var _wrap_make_Identity_complex unsafe.Pointer + +func _swig_wrap_make_Identity_complex() (base SwigcptrArithUnaryFunction_complex_complex) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_make_Identity_complex, _swig_p) + return +} + +func Make_Identity_complex() (_swig_ret ArithUnaryFunction_complex_complex) { + return _swig_wrap_make_Identity_complex() +} + +type SwigcptrUnaryFunction_double_complex uintptr + +func (p SwigcptrUnaryFunction_double_complex) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrUnaryFunction_double_complex) SwigIsUnaryFunction_double_complex() { +} + +var _wrap_UnaryFunction_double_complex_get_value unsafe.Pointer + +func _swig_wrap_UnaryFunction_double_complex_get_value(base SwigcptrUnaryFunction_double_complex) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_UnaryFunction_double_complex_get_value, _swig_p) + return +} + +func (arg1 SwigcptrUnaryFunction_double_complex) Get_value() (_swig_ret int) { + return _swig_wrap_UnaryFunction_double_complex_get_value(arg1) +} + +var _wrap_new_UnaryFunction_double_complex unsafe.Pointer + +func _swig_wrap_new_UnaryFunction_double_complex() (base SwigcptrUnaryFunction_double_complex) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_UnaryFunction_double_complex, _swig_p) + return +} + +func NewUnaryFunction_double_complex() (_swig_ret UnaryFunction_double_complex) { + return _swig_wrap_new_UnaryFunction_double_complex() +} + +var _wrap_delete_UnaryFunction_double_complex unsafe.Pointer + +func _swig_wrap_delete_UnaryFunction_double_complex(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_UnaryFunction_double_complex, _swig_p) + return +} + +func DeleteUnaryFunction_double_complex(arg1 UnaryFunction_double_complex) { + _swig_wrap_delete_UnaryFunction_double_complex(arg1.Swigcptr()) +} + +var _wrap_UnaryFunction_double_complex_get_base_value unsafe.Pointer + +func _swig_wrap_UnaryFunction_double_complex_get_base_value(base SwigcptrUnaryFunction_double_complex) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_UnaryFunction_double_complex_get_base_value, _swig_p) + return +} + +func (_swig_base SwigcptrUnaryFunction_double_complex) Get_base_value() (_swig_ret int) { + return _swig_wrap_UnaryFunction_double_complex_get_base_value(_swig_base) +} + +func (p SwigcptrUnaryFunction_double_complex) SwigIsUnaryFunctionBase() { +} + +func (p SwigcptrUnaryFunction_double_complex) SwigGetUnaryFunctionBase() UnaryFunctionBase { + return SwigcptrUnaryFunctionBase(p.Swigcptr()) +} + +type UnaryFunction_double_complex interface { + Swigcptr() uintptr + SwigIsUnaryFunction_double_complex() + Get_value() (_swig_ret int) + Get_base_value() (_swig_ret int) + SwigIsUnaryFunctionBase() + SwigGetUnaryFunctionBase() UnaryFunctionBase +} + +type SwigcptrArithUnaryFunction_double_complex uintptr + +func (p SwigcptrArithUnaryFunction_double_complex) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrArithUnaryFunction_double_complex) SwigIsArithUnaryFunction_double_complex() { +} + +var _wrap_ArithUnaryFunction_double_complex_get_arith_value unsafe.Pointer + +func _swig_wrap_ArithUnaryFunction_double_complex_get_arith_value(base SwigcptrArithUnaryFunction_double_complex) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_ArithUnaryFunction_double_complex_get_arith_value, _swig_p) + return +} + +func (arg1 SwigcptrArithUnaryFunction_double_complex) Get_arith_value() (_swig_ret int) { + return _swig_wrap_ArithUnaryFunction_double_complex_get_arith_value(arg1) +} + +var _wrap_new_ArithUnaryFunction_double_complex unsafe.Pointer + +func _swig_wrap_new_ArithUnaryFunction_double_complex() (base SwigcptrArithUnaryFunction_double_complex) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_ArithUnaryFunction_double_complex, _swig_p) + return +} + +func NewArithUnaryFunction_double_complex() (_swig_ret ArithUnaryFunction_double_complex) { + return _swig_wrap_new_ArithUnaryFunction_double_complex() +} + +var _wrap_delete_ArithUnaryFunction_double_complex unsafe.Pointer + +func _swig_wrap_delete_ArithUnaryFunction_double_complex(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_ArithUnaryFunction_double_complex, _swig_p) + return +} + +func DeleteArithUnaryFunction_double_complex(arg1 ArithUnaryFunction_double_complex) { + _swig_wrap_delete_ArithUnaryFunction_double_complex(arg1.Swigcptr()) +} + +var _wrap_ArithUnaryFunction_double_complex_get_value unsafe.Pointer + +func _swig_wrap_ArithUnaryFunction_double_complex_get_value(base SwigcptrArithUnaryFunction_double_complex) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_ArithUnaryFunction_double_complex_get_value, _swig_p) + return +} + +func (_swig_base SwigcptrArithUnaryFunction_double_complex) Get_value() (_swig_ret int) { + return _swig_wrap_ArithUnaryFunction_double_complex_get_value(_swig_base) +} + +var _wrap_ArithUnaryFunction_double_complex_get_base_value unsafe.Pointer + +func _swig_wrap_ArithUnaryFunction_double_complex_get_base_value(base SwigcptrArithUnaryFunction_double_complex) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_ArithUnaryFunction_double_complex_get_base_value, _swig_p) + return +} + +func (_swig_base SwigcptrArithUnaryFunction_double_complex) Get_base_value() (_swig_ret int) { + return _swig_wrap_ArithUnaryFunction_double_complex_get_base_value(_swig_base) +} + +func (p SwigcptrArithUnaryFunction_double_complex) SwigIsUnaryFunction_double_complex() { +} + +func (p SwigcptrArithUnaryFunction_double_complex) SwigGetUnaryFunction_double_complex() UnaryFunction_double_complex { + return SwigcptrUnaryFunction_double_complex(p.Swigcptr()) +} + +func (p SwigcptrArithUnaryFunction_double_complex) SwigIsUnaryFunctionBase() { +} + +func (p SwigcptrArithUnaryFunction_double_complex) SwigGetUnaryFunctionBase() UnaryFunctionBase { + return SwigcptrUnaryFunctionBase(p.Swigcptr()) +} + +type ArithUnaryFunction_double_complex interface { + Swigcptr() uintptr + SwigIsArithUnaryFunction_double_complex() + Get_arith_value() (_swig_ret int) + Get_value() (_swig_ret int) + Get_base_value() (_swig_ret int) + SwigIsUnaryFunction_double_complex() + SwigGetUnaryFunction_double_complex() UnaryFunction_double_complex + SwigIsUnaryFunctionBase() + SwigGetUnaryFunctionBase() UnaryFunctionBase +} + +var _wrap_make_Multiplies_double_double_complex_complex unsafe.Pointer + +func _swig_wrap_make_Multiplies_double_double_complex_complex(base uintptr, _ uintptr) (_ SwigcptrArithUnaryFunction_double_complex) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_make_Multiplies_double_double_complex_complex, _swig_p) + return +} + +func Make_Multiplies_double_double_complex_complex(arg1 ArithUnaryFunction_double_double, arg2 ArithUnaryFunction_complex_complex) (_swig_ret ArithUnaryFunction_double_complex) { + return _swig_wrap_make_Multiplies_double_double_complex_complex(arg1.Swigcptr(), arg2.Swigcptr()) +} + +var _wrap_make_Multiplies_double_double_double_double unsafe.Pointer + +func _swig_wrap_make_Multiplies_double_double_double_double(base uintptr, _ uintptr) (_ SwigcptrArithUnaryFunction_double_double) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_make_Multiplies_double_double_double_double, _swig_p) + return +} + +func Make_Multiplies_double_double_double_double(arg1 ArithUnaryFunction_double_double, arg2 ArithUnaryFunction_double_double) (_swig_ret ArithUnaryFunction_double_double) { + return _swig_wrap_make_Multiplies_double_double_double_double(arg1.Swigcptr(), arg2.Swigcptr()) +} + +var _wrap_make_Multiplies_complex_complex_complex_complex unsafe.Pointer + +func _swig_wrap_make_Multiplies_complex_complex_complex_complex(base uintptr, _ uintptr) (_ SwigcptrArithUnaryFunction_complex_complex) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_make_Multiplies_complex_complex_complex_complex, _swig_p) + return +} + +func Make_Multiplies_complex_complex_complex_complex(arg1 ArithUnaryFunction_complex_complex, arg2 ArithUnaryFunction_complex_complex) (_swig_ret ArithUnaryFunction_complex_complex) { + return _swig_wrap_make_Multiplies_complex_complex_complex_complex(arg1.Swigcptr(), arg2.Swigcptr()) +} + +var _wrap_make_Multiplies_complex_complex_double_double unsafe.Pointer + +func _swig_wrap_make_Multiplies_complex_complex_double_double(base uintptr, _ uintptr) (_ SwigcptrArithUnaryFunction_double_complex) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_make_Multiplies_complex_complex_double_double, _swig_p) + return +} + +func Make_Multiplies_complex_complex_double_double(arg1 ArithUnaryFunction_complex_complex, arg2 ArithUnaryFunction_double_double) (_swig_ret ArithUnaryFunction_double_complex) { + return _swig_wrap_make_Multiplies_complex_complex_double_double(arg1.Swigcptr(), arg2.Swigcptr()) +} + +var _wrap_my_func_r unsafe.Pointer + +func _swig_wrap_my_func_r(base uintptr) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_my_func_r, _swig_p) + return +} + +func My_func_r(arg1 ArithUnaryFunction_double_double) (_swig_ret int) { + return _swig_wrap_my_func_r(arg1.Swigcptr()) +} + +var _wrap_my_func_c unsafe.Pointer + +func _swig_wrap_my_func_c(base uintptr) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_my_func_c, _swig_p) + return +} + +func My_func_c(arg1 ArithUnaryFunction_complex_complex) (_swig_ret int) { + return _swig_wrap_my_func_c(arg1.Swigcptr()) +} + +type SwigcptrSin uintptr + +func (p SwigcptrSin) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrSin) SwigIsSin() { +} + +var _wrap_new_Sin unsafe.Pointer + +func _swig_wrap_new_Sin() (base SwigcptrSin) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Sin, _swig_p) + return +} + +func NewSin() (_swig_ret Sin) { + return _swig_wrap_new_Sin() +} + +var _wrap_delete_Sin unsafe.Pointer + +func _swig_wrap_delete_Sin(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Sin, _swig_p) + return +} + +func DeleteSin(arg1 Sin) { + _swig_wrap_delete_Sin(arg1.Swigcptr()) +} + +var _wrap_Sin_get_arith_value unsafe.Pointer + +func _swig_wrap_Sin_get_arith_value(base SwigcptrSin) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Sin_get_arith_value, _swig_p) + return +} + +func (_swig_base SwigcptrSin) Get_arith_value() (_swig_ret int) { + return _swig_wrap_Sin_get_arith_value(_swig_base) +} + +var _wrap_Sin_get_value unsafe.Pointer + +func _swig_wrap_Sin_get_value(base SwigcptrSin) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Sin_get_value, _swig_p) + return +} + +func (_swig_base SwigcptrSin) Get_value() (_swig_ret int) { + return _swig_wrap_Sin_get_value(_swig_base) +} + +var _wrap_Sin_get_base_value unsafe.Pointer + +func _swig_wrap_Sin_get_base_value(base SwigcptrSin) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Sin_get_base_value, _swig_p) + return +} + +func (_swig_base SwigcptrSin) Get_base_value() (_swig_ret int) { + return _swig_wrap_Sin_get_base_value(_swig_base) +} + +func (p SwigcptrSin) SwigIsArithUnaryFunction_double_double() { +} + +func (p SwigcptrSin) SwigGetArithUnaryFunction_double_double() ArithUnaryFunction_double_double { + return SwigcptrArithUnaryFunction_double_double(p.Swigcptr()) +} + +func (p SwigcptrSin) SwigIsUnaryFunction_double_double() { +} + +func (p SwigcptrSin) SwigGetUnaryFunction_double_double() UnaryFunction_double_double { + return SwigcptrUnaryFunction_double_double(p.Swigcptr()) +} + +func (p SwigcptrSin) SwigIsUnaryFunctionBase() { +} + +func (p SwigcptrSin) SwigGetUnaryFunctionBase() UnaryFunctionBase { + return SwigcptrUnaryFunctionBase(p.Swigcptr()) +} + +type Sin interface { + Swigcptr() uintptr + SwigIsSin() + Get_arith_value() (_swig_ret int) + Get_value() (_swig_ret int) + Get_base_value() (_swig_ret int) + SwigIsArithUnaryFunction_double_double() + SwigGetArithUnaryFunction_double_double() ArithUnaryFunction_double_double + SwigIsUnaryFunction_double_double() + SwigGetUnaryFunction_double_double() UnaryFunction_double_double + SwigIsUnaryFunctionBase() + SwigGetUnaryFunctionBase() UnaryFunctionBase +} + +type SwigcptrCSin uintptr + +func (p SwigcptrCSin) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrCSin) SwigIsCSin() { +} + +var _wrap_new_CSin unsafe.Pointer + +func _swig_wrap_new_CSin() (base SwigcptrCSin) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_CSin, _swig_p) + return +} + +func NewCSin() (_swig_ret CSin) { + return _swig_wrap_new_CSin() +} + +var _wrap_delete_CSin unsafe.Pointer + +func _swig_wrap_delete_CSin(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_CSin, _swig_p) + return +} + +func DeleteCSin(arg1 CSin) { + _swig_wrap_delete_CSin(arg1.Swigcptr()) +} + +var _wrap_CSin_get_arith_value unsafe.Pointer + +func _swig_wrap_CSin_get_arith_value(base SwigcptrCSin) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_CSin_get_arith_value, _swig_p) + return +} + +func (_swig_base SwigcptrCSin) Get_arith_value() (_swig_ret int) { + return _swig_wrap_CSin_get_arith_value(_swig_base) +} + +var _wrap_CSin_get_value unsafe.Pointer + +func _swig_wrap_CSin_get_value(base SwigcptrCSin) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_CSin_get_value, _swig_p) + return +} + +func (_swig_base SwigcptrCSin) Get_value() (_swig_ret int) { + return _swig_wrap_CSin_get_value(_swig_base) +} + +var _wrap_CSin_get_base_value unsafe.Pointer + +func _swig_wrap_CSin_get_base_value(base SwigcptrCSin) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_CSin_get_base_value, _swig_p) + return +} + +func (_swig_base SwigcptrCSin) Get_base_value() (_swig_ret int) { + return _swig_wrap_CSin_get_base_value(_swig_base) +} + +func (p SwigcptrCSin) SwigIsArithUnaryFunction_complex_complex() { +} + +func (p SwigcptrCSin) SwigGetArithUnaryFunction_complex_complex() ArithUnaryFunction_complex_complex { + return SwigcptrArithUnaryFunction_complex_complex(p.Swigcptr()) +} + +func (p SwigcptrCSin) SwigIsUnaryFunction_complex_complex() { +} + +func (p SwigcptrCSin) SwigGetUnaryFunction_complex_complex() UnaryFunction_complex_complex { + return SwigcptrUnaryFunction_complex_complex(p.Swigcptr()) +} + +func (p SwigcptrCSin) SwigIsUnaryFunctionBase() { +} + +func (p SwigcptrCSin) SwigGetUnaryFunctionBase() UnaryFunctionBase { + return SwigcptrUnaryFunctionBase(p.Swigcptr()) +} + +type CSin interface { + Swigcptr() uintptr + SwigIsCSin() + Get_arith_value() (_swig_ret int) + Get_value() (_swig_ret int) + Get_base_value() (_swig_ret int) + SwigIsArithUnaryFunction_complex_complex() + SwigGetArithUnaryFunction_complex_complex() ArithUnaryFunction_complex_complex + SwigIsUnaryFunction_complex_complex() + SwigGetUnaryFunction_complex_complex() UnaryFunction_complex_complex + SwigIsUnaryFunctionBase() + SwigGetUnaryFunctionBase() UnaryFunctionBase +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/template_typedef_cplx3_runme b/Examples/test-suite/go/template_typedef_cplx3_runme new file mode 100755 index 000000000..7d3192c65 Binary files /dev/null and b/Examples/test-suite/go/template_typedef_cplx3_runme differ diff --git a/Examples/test-suite/go/template_typedef_cplx4.go b/Examples/test-suite/go/template_typedef_cplx4.go new file mode 100644 index 000000000..9c49f6f41 --- /dev/null +++ b/Examples/test-suite/go/template_typedef_cplx4.go @@ -0,0 +1,896 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../template_typedef_cplx4.i + +package template_typedef_cplx4 + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrUnaryFunctionBase uintptr + +func (p SwigcptrUnaryFunctionBase) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrUnaryFunctionBase) SwigIsUnaryFunctionBase() { +} + +var _wrap_UnaryFunctionBase_get_base_value unsafe.Pointer + +func _swig_wrap_UnaryFunctionBase_get_base_value(base SwigcptrUnaryFunctionBase) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_UnaryFunctionBase_get_base_value, _swig_p) + return +} + +func (arg1 SwigcptrUnaryFunctionBase) Get_base_value() (_swig_ret int) { + return _swig_wrap_UnaryFunctionBase_get_base_value(arg1) +} + +var _wrap_new_UnaryFunctionBase unsafe.Pointer + +func _swig_wrap_new_UnaryFunctionBase() (base SwigcptrUnaryFunctionBase) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_UnaryFunctionBase, _swig_p) + return +} + +func NewUnaryFunctionBase() (_swig_ret UnaryFunctionBase) { + return _swig_wrap_new_UnaryFunctionBase() +} + +var _wrap_delete_UnaryFunctionBase unsafe.Pointer + +func _swig_wrap_delete_UnaryFunctionBase(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_UnaryFunctionBase, _swig_p) + return +} + +func DeleteUnaryFunctionBase(arg1 UnaryFunctionBase) { + _swig_wrap_delete_UnaryFunctionBase(arg1.Swigcptr()) +} + +type UnaryFunctionBase interface { + Swigcptr() uintptr + SwigIsUnaryFunctionBase() + Get_base_value() (_swig_ret int) +} + +type SwigcptrUnaryFunction_double_double uintptr + +func (p SwigcptrUnaryFunction_double_double) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrUnaryFunction_double_double) SwigIsUnaryFunction_double_double() { +} + +var _wrap_UnaryFunction_double_double_get_value unsafe.Pointer + +func _swig_wrap_UnaryFunction_double_double_get_value(base SwigcptrUnaryFunction_double_double) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_UnaryFunction_double_double_get_value, _swig_p) + return +} + +func (arg1 SwigcptrUnaryFunction_double_double) Get_value() (_swig_ret int) { + return _swig_wrap_UnaryFunction_double_double_get_value(arg1) +} + +var _wrap_new_UnaryFunction_double_double unsafe.Pointer + +func _swig_wrap_new_UnaryFunction_double_double() (base SwigcptrUnaryFunction_double_double) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_UnaryFunction_double_double, _swig_p) + return +} + +func NewUnaryFunction_double_double() (_swig_ret UnaryFunction_double_double) { + return _swig_wrap_new_UnaryFunction_double_double() +} + +var _wrap_delete_UnaryFunction_double_double unsafe.Pointer + +func _swig_wrap_delete_UnaryFunction_double_double(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_UnaryFunction_double_double, _swig_p) + return +} + +func DeleteUnaryFunction_double_double(arg1 UnaryFunction_double_double) { + _swig_wrap_delete_UnaryFunction_double_double(arg1.Swigcptr()) +} + +var _wrap_UnaryFunction_double_double_get_base_value unsafe.Pointer + +func _swig_wrap_UnaryFunction_double_double_get_base_value(base SwigcptrUnaryFunction_double_double) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_UnaryFunction_double_double_get_base_value, _swig_p) + return +} + +func (_swig_base SwigcptrUnaryFunction_double_double) Get_base_value() (_swig_ret int) { + return _swig_wrap_UnaryFunction_double_double_get_base_value(_swig_base) +} + +func (p SwigcptrUnaryFunction_double_double) SwigIsUnaryFunctionBase() { +} + +func (p SwigcptrUnaryFunction_double_double) SwigGetUnaryFunctionBase() UnaryFunctionBase { + return SwigcptrUnaryFunctionBase(p.Swigcptr()) +} + +type UnaryFunction_double_double interface { + Swigcptr() uintptr + SwigIsUnaryFunction_double_double() + Get_value() (_swig_ret int) + Get_base_value() (_swig_ret int) + SwigIsUnaryFunctionBase() + SwigGetUnaryFunctionBase() UnaryFunctionBase +} + +type SwigcptrArithUnaryFunction_double_double uintptr + +func (p SwigcptrArithUnaryFunction_double_double) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrArithUnaryFunction_double_double) SwigIsArithUnaryFunction_double_double() { +} + +var _wrap_ArithUnaryFunction_double_double_get_arith_value unsafe.Pointer + +func _swig_wrap_ArithUnaryFunction_double_double_get_arith_value(base SwigcptrArithUnaryFunction_double_double) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_ArithUnaryFunction_double_double_get_arith_value, _swig_p) + return +} + +func (arg1 SwigcptrArithUnaryFunction_double_double) Get_arith_value() (_swig_ret int) { + return _swig_wrap_ArithUnaryFunction_double_double_get_arith_value(arg1) +} + +var _wrap_new_ArithUnaryFunction_double_double unsafe.Pointer + +func _swig_wrap_new_ArithUnaryFunction_double_double() (base SwigcptrArithUnaryFunction_double_double) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_ArithUnaryFunction_double_double, _swig_p) + return +} + +func NewArithUnaryFunction_double_double() (_swig_ret ArithUnaryFunction_double_double) { + return _swig_wrap_new_ArithUnaryFunction_double_double() +} + +var _wrap_delete_ArithUnaryFunction_double_double unsafe.Pointer + +func _swig_wrap_delete_ArithUnaryFunction_double_double(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_ArithUnaryFunction_double_double, _swig_p) + return +} + +func DeleteArithUnaryFunction_double_double(arg1 ArithUnaryFunction_double_double) { + _swig_wrap_delete_ArithUnaryFunction_double_double(arg1.Swigcptr()) +} + +var _wrap_ArithUnaryFunction_double_double_get_value unsafe.Pointer + +func _swig_wrap_ArithUnaryFunction_double_double_get_value(base SwigcptrArithUnaryFunction_double_double) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_ArithUnaryFunction_double_double_get_value, _swig_p) + return +} + +func (_swig_base SwigcptrArithUnaryFunction_double_double) Get_value() (_swig_ret int) { + return _swig_wrap_ArithUnaryFunction_double_double_get_value(_swig_base) +} + +var _wrap_ArithUnaryFunction_double_double_get_base_value unsafe.Pointer + +func _swig_wrap_ArithUnaryFunction_double_double_get_base_value(base SwigcptrArithUnaryFunction_double_double) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_ArithUnaryFunction_double_double_get_base_value, _swig_p) + return +} + +func (_swig_base SwigcptrArithUnaryFunction_double_double) Get_base_value() (_swig_ret int) { + return _swig_wrap_ArithUnaryFunction_double_double_get_base_value(_swig_base) +} + +func (p SwigcptrArithUnaryFunction_double_double) SwigIsUnaryFunction_double_double() { +} + +func (p SwigcptrArithUnaryFunction_double_double) SwigGetUnaryFunction_double_double() UnaryFunction_double_double { + return SwigcptrUnaryFunction_double_double(p.Swigcptr()) +} + +func (p SwigcptrArithUnaryFunction_double_double) SwigIsUnaryFunctionBase() { +} + +func (p SwigcptrArithUnaryFunction_double_double) SwigGetUnaryFunctionBase() UnaryFunctionBase { + return SwigcptrUnaryFunctionBase(p.Swigcptr()) +} + +type ArithUnaryFunction_double_double interface { + Swigcptr() uintptr + SwigIsArithUnaryFunction_double_double() + Get_arith_value() (_swig_ret int) + Get_value() (_swig_ret int) + Get_base_value() (_swig_ret int) + SwigIsUnaryFunction_double_double() + SwigGetUnaryFunction_double_double() UnaryFunction_double_double + SwigIsUnaryFunctionBase() + SwigGetUnaryFunctionBase() UnaryFunctionBase +} + +var _wrap_make_Identity_double unsafe.Pointer + +func _swig_wrap_make_Identity_double() (base SwigcptrArithUnaryFunction_double_double) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_make_Identity_double, _swig_p) + return +} + +func Make_Identity_double() (_swig_ret ArithUnaryFunction_double_double) { + return _swig_wrap_make_Identity_double() +} + +type SwigcptrUnaryFunction_complex_complex uintptr + +func (p SwigcptrUnaryFunction_complex_complex) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrUnaryFunction_complex_complex) SwigIsUnaryFunction_complex_complex() { +} + +var _wrap_UnaryFunction_complex_complex_get_value unsafe.Pointer + +func _swig_wrap_UnaryFunction_complex_complex_get_value(base SwigcptrUnaryFunction_complex_complex) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_UnaryFunction_complex_complex_get_value, _swig_p) + return +} + +func (arg1 SwigcptrUnaryFunction_complex_complex) Get_value() (_swig_ret int) { + return _swig_wrap_UnaryFunction_complex_complex_get_value(arg1) +} + +var _wrap_new_UnaryFunction_complex_complex unsafe.Pointer + +func _swig_wrap_new_UnaryFunction_complex_complex() (base SwigcptrUnaryFunction_complex_complex) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_UnaryFunction_complex_complex, _swig_p) + return +} + +func NewUnaryFunction_complex_complex() (_swig_ret UnaryFunction_complex_complex) { + return _swig_wrap_new_UnaryFunction_complex_complex() +} + +var _wrap_delete_UnaryFunction_complex_complex unsafe.Pointer + +func _swig_wrap_delete_UnaryFunction_complex_complex(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_UnaryFunction_complex_complex, _swig_p) + return +} + +func DeleteUnaryFunction_complex_complex(arg1 UnaryFunction_complex_complex) { + _swig_wrap_delete_UnaryFunction_complex_complex(arg1.Swigcptr()) +} + +var _wrap_UnaryFunction_complex_complex_get_base_value unsafe.Pointer + +func _swig_wrap_UnaryFunction_complex_complex_get_base_value(base SwigcptrUnaryFunction_complex_complex) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_UnaryFunction_complex_complex_get_base_value, _swig_p) + return +} + +func (_swig_base SwigcptrUnaryFunction_complex_complex) Get_base_value() (_swig_ret int) { + return _swig_wrap_UnaryFunction_complex_complex_get_base_value(_swig_base) +} + +func (p SwigcptrUnaryFunction_complex_complex) SwigIsUnaryFunctionBase() { +} + +func (p SwigcptrUnaryFunction_complex_complex) SwigGetUnaryFunctionBase() UnaryFunctionBase { + return SwigcptrUnaryFunctionBase(p.Swigcptr()) +} + +type UnaryFunction_complex_complex interface { + Swigcptr() uintptr + SwigIsUnaryFunction_complex_complex() + Get_value() (_swig_ret int) + Get_base_value() (_swig_ret int) + SwigIsUnaryFunctionBase() + SwigGetUnaryFunctionBase() UnaryFunctionBase +} + +type SwigcptrArithUnaryFunction_complex_complex uintptr + +func (p SwigcptrArithUnaryFunction_complex_complex) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrArithUnaryFunction_complex_complex) SwigIsArithUnaryFunction_complex_complex() { +} + +var _wrap_ArithUnaryFunction_complex_complex_get_arith_value unsafe.Pointer + +func _swig_wrap_ArithUnaryFunction_complex_complex_get_arith_value(base SwigcptrArithUnaryFunction_complex_complex) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_ArithUnaryFunction_complex_complex_get_arith_value, _swig_p) + return +} + +func (arg1 SwigcptrArithUnaryFunction_complex_complex) Get_arith_value() (_swig_ret int) { + return _swig_wrap_ArithUnaryFunction_complex_complex_get_arith_value(arg1) +} + +var _wrap_new_ArithUnaryFunction_complex_complex unsafe.Pointer + +func _swig_wrap_new_ArithUnaryFunction_complex_complex() (base SwigcptrArithUnaryFunction_complex_complex) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_ArithUnaryFunction_complex_complex, _swig_p) + return +} + +func NewArithUnaryFunction_complex_complex() (_swig_ret ArithUnaryFunction_complex_complex) { + return _swig_wrap_new_ArithUnaryFunction_complex_complex() +} + +var _wrap_delete_ArithUnaryFunction_complex_complex unsafe.Pointer + +func _swig_wrap_delete_ArithUnaryFunction_complex_complex(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_ArithUnaryFunction_complex_complex, _swig_p) + return +} + +func DeleteArithUnaryFunction_complex_complex(arg1 ArithUnaryFunction_complex_complex) { + _swig_wrap_delete_ArithUnaryFunction_complex_complex(arg1.Swigcptr()) +} + +var _wrap_ArithUnaryFunction_complex_complex_get_value unsafe.Pointer + +func _swig_wrap_ArithUnaryFunction_complex_complex_get_value(base SwigcptrArithUnaryFunction_complex_complex) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_ArithUnaryFunction_complex_complex_get_value, _swig_p) + return +} + +func (_swig_base SwigcptrArithUnaryFunction_complex_complex) Get_value() (_swig_ret int) { + return _swig_wrap_ArithUnaryFunction_complex_complex_get_value(_swig_base) +} + +var _wrap_ArithUnaryFunction_complex_complex_get_base_value unsafe.Pointer + +func _swig_wrap_ArithUnaryFunction_complex_complex_get_base_value(base SwigcptrArithUnaryFunction_complex_complex) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_ArithUnaryFunction_complex_complex_get_base_value, _swig_p) + return +} + +func (_swig_base SwigcptrArithUnaryFunction_complex_complex) Get_base_value() (_swig_ret int) { + return _swig_wrap_ArithUnaryFunction_complex_complex_get_base_value(_swig_base) +} + +func (p SwigcptrArithUnaryFunction_complex_complex) SwigIsUnaryFunction_complex_complex() { +} + +func (p SwigcptrArithUnaryFunction_complex_complex) SwigGetUnaryFunction_complex_complex() UnaryFunction_complex_complex { + return SwigcptrUnaryFunction_complex_complex(p.Swigcptr()) +} + +func (p SwigcptrArithUnaryFunction_complex_complex) SwigIsUnaryFunctionBase() { +} + +func (p SwigcptrArithUnaryFunction_complex_complex) SwigGetUnaryFunctionBase() UnaryFunctionBase { + return SwigcptrUnaryFunctionBase(p.Swigcptr()) +} + +type ArithUnaryFunction_complex_complex interface { + Swigcptr() uintptr + SwigIsArithUnaryFunction_complex_complex() + Get_arith_value() (_swig_ret int) + Get_value() (_swig_ret int) + Get_base_value() (_swig_ret int) + SwigIsUnaryFunction_complex_complex() + SwigGetUnaryFunction_complex_complex() UnaryFunction_complex_complex + SwigIsUnaryFunctionBase() + SwigGetUnaryFunctionBase() UnaryFunctionBase +} + +var _wrap_make_Identity_complex unsafe.Pointer + +func _swig_wrap_make_Identity_complex() (base SwigcptrArithUnaryFunction_complex_complex) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_make_Identity_complex, _swig_p) + return +} + +func Make_Identity_complex() (_swig_ret ArithUnaryFunction_complex_complex) { + return _swig_wrap_make_Identity_complex() +} + +type SwigcptrUnaryFunction_double_complex uintptr + +func (p SwigcptrUnaryFunction_double_complex) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrUnaryFunction_double_complex) SwigIsUnaryFunction_double_complex() { +} + +var _wrap_UnaryFunction_double_complex_get_value unsafe.Pointer + +func _swig_wrap_UnaryFunction_double_complex_get_value(base SwigcptrUnaryFunction_double_complex) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_UnaryFunction_double_complex_get_value, _swig_p) + return +} + +func (arg1 SwigcptrUnaryFunction_double_complex) Get_value() (_swig_ret int) { + return _swig_wrap_UnaryFunction_double_complex_get_value(arg1) +} + +var _wrap_new_UnaryFunction_double_complex unsafe.Pointer + +func _swig_wrap_new_UnaryFunction_double_complex() (base SwigcptrUnaryFunction_double_complex) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_UnaryFunction_double_complex, _swig_p) + return +} + +func NewUnaryFunction_double_complex() (_swig_ret UnaryFunction_double_complex) { + return _swig_wrap_new_UnaryFunction_double_complex() +} + +var _wrap_delete_UnaryFunction_double_complex unsafe.Pointer + +func _swig_wrap_delete_UnaryFunction_double_complex(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_UnaryFunction_double_complex, _swig_p) + return +} + +func DeleteUnaryFunction_double_complex(arg1 UnaryFunction_double_complex) { + _swig_wrap_delete_UnaryFunction_double_complex(arg1.Swigcptr()) +} + +var _wrap_UnaryFunction_double_complex_get_base_value unsafe.Pointer + +func _swig_wrap_UnaryFunction_double_complex_get_base_value(base SwigcptrUnaryFunction_double_complex) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_UnaryFunction_double_complex_get_base_value, _swig_p) + return +} + +func (_swig_base SwigcptrUnaryFunction_double_complex) Get_base_value() (_swig_ret int) { + return _swig_wrap_UnaryFunction_double_complex_get_base_value(_swig_base) +} + +func (p SwigcptrUnaryFunction_double_complex) SwigIsUnaryFunctionBase() { +} + +func (p SwigcptrUnaryFunction_double_complex) SwigGetUnaryFunctionBase() UnaryFunctionBase { + return SwigcptrUnaryFunctionBase(p.Swigcptr()) +} + +type UnaryFunction_double_complex interface { + Swigcptr() uintptr + SwigIsUnaryFunction_double_complex() + Get_value() (_swig_ret int) + Get_base_value() (_swig_ret int) + SwigIsUnaryFunctionBase() + SwigGetUnaryFunctionBase() UnaryFunctionBase +} + +type SwigcptrArithUnaryFunction_double_complex uintptr + +func (p SwigcptrArithUnaryFunction_double_complex) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrArithUnaryFunction_double_complex) SwigIsArithUnaryFunction_double_complex() { +} + +var _wrap_ArithUnaryFunction_double_complex_get_arith_value unsafe.Pointer + +func _swig_wrap_ArithUnaryFunction_double_complex_get_arith_value(base SwigcptrArithUnaryFunction_double_complex) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_ArithUnaryFunction_double_complex_get_arith_value, _swig_p) + return +} + +func (arg1 SwigcptrArithUnaryFunction_double_complex) Get_arith_value() (_swig_ret int) { + return _swig_wrap_ArithUnaryFunction_double_complex_get_arith_value(arg1) +} + +var _wrap_new_ArithUnaryFunction_double_complex unsafe.Pointer + +func _swig_wrap_new_ArithUnaryFunction_double_complex() (base SwigcptrArithUnaryFunction_double_complex) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_ArithUnaryFunction_double_complex, _swig_p) + return +} + +func NewArithUnaryFunction_double_complex() (_swig_ret ArithUnaryFunction_double_complex) { + return _swig_wrap_new_ArithUnaryFunction_double_complex() +} + +var _wrap_delete_ArithUnaryFunction_double_complex unsafe.Pointer + +func _swig_wrap_delete_ArithUnaryFunction_double_complex(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_ArithUnaryFunction_double_complex, _swig_p) + return +} + +func DeleteArithUnaryFunction_double_complex(arg1 ArithUnaryFunction_double_complex) { + _swig_wrap_delete_ArithUnaryFunction_double_complex(arg1.Swigcptr()) +} + +var _wrap_ArithUnaryFunction_double_complex_get_value unsafe.Pointer + +func _swig_wrap_ArithUnaryFunction_double_complex_get_value(base SwigcptrArithUnaryFunction_double_complex) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_ArithUnaryFunction_double_complex_get_value, _swig_p) + return +} + +func (_swig_base SwigcptrArithUnaryFunction_double_complex) Get_value() (_swig_ret int) { + return _swig_wrap_ArithUnaryFunction_double_complex_get_value(_swig_base) +} + +var _wrap_ArithUnaryFunction_double_complex_get_base_value unsafe.Pointer + +func _swig_wrap_ArithUnaryFunction_double_complex_get_base_value(base SwigcptrArithUnaryFunction_double_complex) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_ArithUnaryFunction_double_complex_get_base_value, _swig_p) + return +} + +func (_swig_base SwigcptrArithUnaryFunction_double_complex) Get_base_value() (_swig_ret int) { + return _swig_wrap_ArithUnaryFunction_double_complex_get_base_value(_swig_base) +} + +func (p SwigcptrArithUnaryFunction_double_complex) SwigIsUnaryFunction_double_complex() { +} + +func (p SwigcptrArithUnaryFunction_double_complex) SwigGetUnaryFunction_double_complex() UnaryFunction_double_complex { + return SwigcptrUnaryFunction_double_complex(p.Swigcptr()) +} + +func (p SwigcptrArithUnaryFunction_double_complex) SwigIsUnaryFunctionBase() { +} + +func (p SwigcptrArithUnaryFunction_double_complex) SwigGetUnaryFunctionBase() UnaryFunctionBase { + return SwigcptrUnaryFunctionBase(p.Swigcptr()) +} + +type ArithUnaryFunction_double_complex interface { + Swigcptr() uintptr + SwigIsArithUnaryFunction_double_complex() + Get_arith_value() (_swig_ret int) + Get_value() (_swig_ret int) + Get_base_value() (_swig_ret int) + SwigIsUnaryFunction_double_complex() + SwigGetUnaryFunction_double_complex() UnaryFunction_double_complex + SwigIsUnaryFunctionBase() + SwigGetUnaryFunctionBase() UnaryFunctionBase +} + +var _wrap_make_Multiplies_double_double_complex_complex unsafe.Pointer + +func _swig_wrap_make_Multiplies_double_double_complex_complex(base uintptr, _ uintptr) (_ SwigcptrArithUnaryFunction_double_complex) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_make_Multiplies_double_double_complex_complex, _swig_p) + return +} + +func Make_Multiplies_double_double_complex_complex(arg1 ArithUnaryFunction_double_double, arg2 ArithUnaryFunction_complex_complex) (_swig_ret ArithUnaryFunction_double_complex) { + return _swig_wrap_make_Multiplies_double_double_complex_complex(arg1.Swigcptr(), arg2.Swigcptr()) +} + +var _wrap_make_Multiplies_double_double_double_double unsafe.Pointer + +func _swig_wrap_make_Multiplies_double_double_double_double(base uintptr, _ uintptr) (_ SwigcptrArithUnaryFunction_double_double) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_make_Multiplies_double_double_double_double, _swig_p) + return +} + +func Make_Multiplies_double_double_double_double(arg1 ArithUnaryFunction_double_double, arg2 ArithUnaryFunction_double_double) (_swig_ret ArithUnaryFunction_double_double) { + return _swig_wrap_make_Multiplies_double_double_double_double(arg1.Swigcptr(), arg2.Swigcptr()) +} + +var _wrap_make_Multiplies_complex_complex_complex_complex unsafe.Pointer + +func _swig_wrap_make_Multiplies_complex_complex_complex_complex(base uintptr, _ uintptr) (_ SwigcptrArithUnaryFunction_complex_complex) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_make_Multiplies_complex_complex_complex_complex, _swig_p) + return +} + +func Make_Multiplies_complex_complex_complex_complex(arg1 ArithUnaryFunction_complex_complex, arg2 ArithUnaryFunction_complex_complex) (_swig_ret ArithUnaryFunction_complex_complex) { + return _swig_wrap_make_Multiplies_complex_complex_complex_complex(arg1.Swigcptr(), arg2.Swigcptr()) +} + +var _wrap_make_Multiplies_complex_complex_double_double unsafe.Pointer + +func _swig_wrap_make_Multiplies_complex_complex_double_double(base uintptr, _ uintptr) (_ SwigcptrArithUnaryFunction_double_complex) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_make_Multiplies_complex_complex_double_double, _swig_p) + return +} + +func Make_Multiplies_complex_complex_double_double(arg1 ArithUnaryFunction_complex_complex, arg2 ArithUnaryFunction_double_double) (_swig_ret ArithUnaryFunction_double_complex) { + return _swig_wrap_make_Multiplies_complex_complex_double_double(arg1.Swigcptr(), arg2.Swigcptr()) +} + +var _wrap_my_func_r unsafe.Pointer + +func _swig_wrap_my_func_r(base uintptr) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_my_func_r, _swig_p) + return +} + +func My_func_r(arg1 ArithUnaryFunction_double_double) (_swig_ret int) { + return _swig_wrap_my_func_r(arg1.Swigcptr()) +} + +var _wrap_my_func_c unsafe.Pointer + +func _swig_wrap_my_func_c(base uintptr) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_my_func_c, _swig_p) + return +} + +func My_func_c(arg1 ArithUnaryFunction_complex_complex) (_swig_ret int) { + return _swig_wrap_my_func_c(arg1.Swigcptr()) +} + +type SwigcptrSin uintptr + +func (p SwigcptrSin) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrSin) SwigIsSin() { +} + +var _wrap_new_Sin unsafe.Pointer + +func _swig_wrap_new_Sin() (base SwigcptrSin) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Sin, _swig_p) + return +} + +func NewSin() (_swig_ret Sin) { + return _swig_wrap_new_Sin() +} + +var _wrap_delete_Sin unsafe.Pointer + +func _swig_wrap_delete_Sin(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Sin, _swig_p) + return +} + +func DeleteSin(arg1 Sin) { + _swig_wrap_delete_Sin(arg1.Swigcptr()) +} + +var _wrap_Sin_get_arith_value unsafe.Pointer + +func _swig_wrap_Sin_get_arith_value(base SwigcptrSin) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Sin_get_arith_value, _swig_p) + return +} + +func (_swig_base SwigcptrSin) Get_arith_value() (_swig_ret int) { + return _swig_wrap_Sin_get_arith_value(_swig_base) +} + +var _wrap_Sin_get_value unsafe.Pointer + +func _swig_wrap_Sin_get_value(base SwigcptrSin) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Sin_get_value, _swig_p) + return +} + +func (_swig_base SwigcptrSin) Get_value() (_swig_ret int) { + return _swig_wrap_Sin_get_value(_swig_base) +} + +var _wrap_Sin_get_base_value unsafe.Pointer + +func _swig_wrap_Sin_get_base_value(base SwigcptrSin) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Sin_get_base_value, _swig_p) + return +} + +func (_swig_base SwigcptrSin) Get_base_value() (_swig_ret int) { + return _swig_wrap_Sin_get_base_value(_swig_base) +} + +func (p SwigcptrSin) SwigIsArithUnaryFunction_double_double() { +} + +func (p SwigcptrSin) SwigGetArithUnaryFunction_double_double() ArithUnaryFunction_double_double { + return SwigcptrArithUnaryFunction_double_double(p.Swigcptr()) +} + +func (p SwigcptrSin) SwigIsUnaryFunction_double_double() { +} + +func (p SwigcptrSin) SwigGetUnaryFunction_double_double() UnaryFunction_double_double { + return SwigcptrUnaryFunction_double_double(p.Swigcptr()) +} + +func (p SwigcptrSin) SwigIsUnaryFunctionBase() { +} + +func (p SwigcptrSin) SwigGetUnaryFunctionBase() UnaryFunctionBase { + return SwigcptrUnaryFunctionBase(p.Swigcptr()) +} + +type Sin interface { + Swigcptr() uintptr + SwigIsSin() + Get_arith_value() (_swig_ret int) + Get_value() (_swig_ret int) + Get_base_value() (_swig_ret int) + SwigIsArithUnaryFunction_double_double() + SwigGetArithUnaryFunction_double_double() ArithUnaryFunction_double_double + SwigIsUnaryFunction_double_double() + SwigGetUnaryFunction_double_double() UnaryFunction_double_double + SwigIsUnaryFunctionBase() + SwigGetUnaryFunctionBase() UnaryFunctionBase +} + +type SwigcptrCSin uintptr + +func (p SwigcptrCSin) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrCSin) SwigIsCSin() { +} + +var _wrap_new_CSin unsafe.Pointer + +func _swig_wrap_new_CSin() (base SwigcptrCSin) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_CSin, _swig_p) + return +} + +func NewCSin() (_swig_ret CSin) { + return _swig_wrap_new_CSin() +} + +var _wrap_delete_CSin unsafe.Pointer + +func _swig_wrap_delete_CSin(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_CSin, _swig_p) + return +} + +func DeleteCSin(arg1 CSin) { + _swig_wrap_delete_CSin(arg1.Swigcptr()) +} + +var _wrap_CSin_get_arith_value unsafe.Pointer + +func _swig_wrap_CSin_get_arith_value(base SwigcptrCSin) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_CSin_get_arith_value, _swig_p) + return +} + +func (_swig_base SwigcptrCSin) Get_arith_value() (_swig_ret int) { + return _swig_wrap_CSin_get_arith_value(_swig_base) +} + +var _wrap_CSin_get_value unsafe.Pointer + +func _swig_wrap_CSin_get_value(base SwigcptrCSin) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_CSin_get_value, _swig_p) + return +} + +func (_swig_base SwigcptrCSin) Get_value() (_swig_ret int) { + return _swig_wrap_CSin_get_value(_swig_base) +} + +var _wrap_CSin_get_base_value unsafe.Pointer + +func _swig_wrap_CSin_get_base_value(base SwigcptrCSin) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_CSin_get_base_value, _swig_p) + return +} + +func (_swig_base SwigcptrCSin) Get_base_value() (_swig_ret int) { + return _swig_wrap_CSin_get_base_value(_swig_base) +} + +func (p SwigcptrCSin) SwigIsArithUnaryFunction_complex_complex() { +} + +func (p SwigcptrCSin) SwigGetArithUnaryFunction_complex_complex() ArithUnaryFunction_complex_complex { + return SwigcptrArithUnaryFunction_complex_complex(p.Swigcptr()) +} + +func (p SwigcptrCSin) SwigIsUnaryFunction_complex_complex() { +} + +func (p SwigcptrCSin) SwigGetUnaryFunction_complex_complex() UnaryFunction_complex_complex { + return SwigcptrUnaryFunction_complex_complex(p.Swigcptr()) +} + +func (p SwigcptrCSin) SwigIsUnaryFunctionBase() { +} + +func (p SwigcptrCSin) SwigGetUnaryFunctionBase() UnaryFunctionBase { + return SwigcptrUnaryFunctionBase(p.Swigcptr()) +} + +type CSin interface { + Swigcptr() uintptr + SwigIsCSin() + Get_arith_value() (_swig_ret int) + Get_value() (_swig_ret int) + Get_base_value() (_swig_ret int) + SwigIsArithUnaryFunction_complex_complex() + SwigGetArithUnaryFunction_complex_complex() ArithUnaryFunction_complex_complex + SwigIsUnaryFunction_complex_complex() + SwigGetUnaryFunction_complex_complex() UnaryFunction_complex_complex + SwigIsUnaryFunctionBase() + SwigGetUnaryFunctionBase() UnaryFunctionBase +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/template_typedef_cplx4_runme b/Examples/test-suite/go/template_typedef_cplx4_runme new file mode 100755 index 000000000..44d4073f4 Binary files /dev/null and b/Examples/test-suite/go/template_typedef_cplx4_runme differ diff --git a/Examples/test-suite/go/template_typedef_cplx5.go b/Examples/test-suite/go/template_typedef_cplx5.go new file mode 100644 index 000000000..2a3bb1f71 --- /dev/null +++ b/Examples/test-suite/go/template_typedef_cplx5.go @@ -0,0 +1,109 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../template_typedef_cplx5.i + +package template_typedef_cplx5 + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrA uintptr + +func (p SwigcptrA) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrA) SwigIsA() { +} + +var _wrap_A_test1 unsafe.Pointer + +func _swig_wrap_A_test1(base SwigcptrA) (_ SwigcptrStd_complex_Sl_double_Sg_) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_A_test1, _swig_p) + return +} + +func (arg1 SwigcptrA) Test1() (_swig_ret Std_complex_Sl_double_Sg_) { + return _swig_wrap_A_test1(arg1) +} + +var _wrap_A_test2 unsafe.Pointer + +func _swig_wrap_A_test2(base SwigcptrA) (_ SwigcptrStd_complex_Sl_double_Sg_) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_A_test2, _swig_p) + return +} + +func (arg1 SwigcptrA) Test2() (_swig_ret Std_complex_Sl_double_Sg_) { + return _swig_wrap_A_test2(arg1) +} + +var _wrap_new_A unsafe.Pointer + +func _swig_wrap_new_A() (base SwigcptrA) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_A, _swig_p) + return +} + +func NewA() (_swig_ret A) { + return _swig_wrap_new_A() +} + +var _wrap_delete_A unsafe.Pointer + +func _swig_wrap_delete_A(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_A, _swig_p) + return +} + +func DeleteA(arg1 A) { + _swig_wrap_delete_A(arg1.Swigcptr()) +} + +type A interface { + Swigcptr() uintptr + SwigIsA() + Test1() (_swig_ret Std_complex_Sl_double_Sg_) + Test2() (_swig_ret Std_complex_Sl_double_Sg_) +} + + +type SwigcptrStd_complex_Sl_double_Sg_ uintptr +type Std_complex_Sl_double_Sg_ interface { + Swigcptr() uintptr; +} +func (p SwigcptrStd_complex_Sl_double_Sg_) Swigcptr() uintptr { + return uintptr(p) +} + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/template_typedef_fnc.go b/Examples/test-suite/go/template_typedef_fnc.go new file mode 100644 index 000000000..ff34cd1f2 --- /dev/null +++ b/Examples/test-suite/go/template_typedef_fnc.go @@ -0,0 +1,214 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../template_typedef_fnc.i + +package template_typedef_fnc + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrIntVector uintptr + +func (p SwigcptrIntVector) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrIntVector) SwigIsIntVector() { +} + +var _wrap_new_IntVector__SWIG_0 unsafe.Pointer + +func _swig_wrap_new_IntVector__SWIG_0() (base SwigcptrIntVector) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_IntVector__SWIG_0, _swig_p) + return +} + +func NewIntVector__SWIG_0() (_swig_ret IntVector) { + return _swig_wrap_new_IntVector__SWIG_0() +} + +var _wrap_new_IntVector__SWIG_1 unsafe.Pointer + +func _swig_wrap_new_IntVector__SWIG_1(base int64) (_ SwigcptrIntVector) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_IntVector__SWIG_1, _swig_p) + return +} + +func NewIntVector__SWIG_1(arg1 int64) (_swig_ret IntVector) { + return _swig_wrap_new_IntVector__SWIG_1(arg1) +} + +func NewIntVector(a ...interface{}) IntVector { + argc := len(a) + if argc == 0 { + return NewIntVector__SWIG_0() + } + if argc == 1 { + return NewIntVector__SWIG_1(a[0].(int64)) + } + panic("No match for overloaded function call") +} + +var _wrap_IntVector_size unsafe.Pointer + +func _swig_wrap_IntVector_size(base SwigcptrIntVector) (_ int64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_IntVector_size, _swig_p) + return +} + +func (arg1 SwigcptrIntVector) Size() (_swig_ret int64) { + return _swig_wrap_IntVector_size(arg1) +} + +var _wrap_IntVector_capacity unsafe.Pointer + +func _swig_wrap_IntVector_capacity(base SwigcptrIntVector) (_ int64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_IntVector_capacity, _swig_p) + return +} + +func (arg1 SwigcptrIntVector) Capacity() (_swig_ret int64) { + return _swig_wrap_IntVector_capacity(arg1) +} + +var _wrap_IntVector_reserve unsafe.Pointer + +func _swig_wrap_IntVector_reserve(base SwigcptrIntVector, _ int64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_IntVector_reserve, _swig_p) + return +} + +func (arg1 SwigcptrIntVector) Reserve(arg2 int64) { + _swig_wrap_IntVector_reserve(arg1, arg2) +} + +var _wrap_IntVector_isEmpty unsafe.Pointer + +func _swig_wrap_IntVector_isEmpty(base SwigcptrIntVector) (_ bool) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_IntVector_isEmpty, _swig_p) + return +} + +func (arg1 SwigcptrIntVector) IsEmpty() (_swig_ret bool) { + return _swig_wrap_IntVector_isEmpty(arg1) +} + +var _wrap_IntVector_clear unsafe.Pointer + +func _swig_wrap_IntVector_clear(base SwigcptrIntVector) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_IntVector_clear, _swig_p) + return +} + +func (arg1 SwigcptrIntVector) Clear() { + _swig_wrap_IntVector_clear(arg1) +} + +var _wrap_IntVector_add unsafe.Pointer + +func _swig_wrap_IntVector_add(base SwigcptrIntVector, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_IntVector_add, _swig_p) + return +} + +func (arg1 SwigcptrIntVector) Add(arg2 int) { + _swig_wrap_IntVector_add(arg1, arg2) +} + +var _wrap_IntVector_get unsafe.Pointer + +func _swig_wrap_IntVector_get(base SwigcptrIntVector, _ int) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_IntVector_get, _swig_p) + return +} + +func (arg1 SwigcptrIntVector) Get(arg2 int) (_swig_ret int) { + return _swig_wrap_IntVector_get(arg1, arg2) +} + +var _wrap_IntVector_set unsafe.Pointer + +func _swig_wrap_IntVector_set(base SwigcptrIntVector, _ int, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_IntVector_set, _swig_p) + return +} + +func (arg1 SwigcptrIntVector) Set(arg2 int, arg3 int) { + _swig_wrap_IntVector_set(arg1, arg2, arg3) +} + +var _wrap_delete_IntVector unsafe.Pointer + +func _swig_wrap_delete_IntVector(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_IntVector, _swig_p) + return +} + +func DeleteIntVector(arg1 IntVector) { + _swig_wrap_delete_IntVector(arg1.Swigcptr()) +} + +type IntVector interface { + Swigcptr() uintptr + SwigIsIntVector() + Size() (_swig_ret int64) + Capacity() (_swig_ret int64) + Reserve(arg2 int64) + IsEmpty() (_swig_ret bool) + Clear() + Add(arg2 int) + Get(arg2 int) (_swig_ret int) + Set(arg2 int, arg3 int) +} + +var _wrap_setCallback unsafe.Pointer + +func _swig_wrap_setCallback(base *_swig_fnptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_setCallback, _swig_p) + return +} + +func SetCallback(arg1 *_swig_fnptr) { + _swig_wrap_setCallback(arg1) +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/template_typedef_funcptr.go b/Examples/test-suite/go/template_typedef_funcptr.go new file mode 100644 index 000000000..30ad526c3 --- /dev/null +++ b/Examples/test-suite/go/template_typedef_funcptr.go @@ -0,0 +1,175 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../template_typedef_funcptr.i + +package template_typedef_funcptr + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrMCContract uintptr + +func (p SwigcptrMCContract) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrMCContract) SwigIsMCContract() { +} + +var _wrap_new_MCContract unsafe.Pointer + +func _swig_wrap_new_MCContract() (base SwigcptrMCContract) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_MCContract, _swig_p) + return +} + +func NewMCContract() (_swig_ret MCContract) { + return _swig_wrap_new_MCContract() +} + +var _wrap_delete_MCContract unsafe.Pointer + +func _swig_wrap_delete_MCContract(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_MCContract, _swig_p) + return +} + +func DeleteMCContract(arg1 MCContract) { + _swig_wrap_delete_MCContract(arg1.Swigcptr()) +} + +type MCContract interface { + Swigcptr() uintptr + SwigIsMCContract() +} + +type SwigcptrMCContractFactory uintptr + +func (p SwigcptrMCContractFactory) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrMCContractFactory) SwigIsMCContractFactory() { +} + +var _wrap_MCContractFactory_getInstance unsafe.Pointer + +func _swig_wrap_MCContractFactory_getInstance() (base SwigcptrMCContractFactory) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_MCContractFactory_getInstance, _swig_p) + return +} + +func MCContractFactoryGetInstance() (_swig_ret MCContractFactory) { + return _swig_wrap_MCContractFactory_getInstance() +} + +var _wrap_new_MCContractFactory unsafe.Pointer + +func _swig_wrap_new_MCContractFactory() (base SwigcptrMCContractFactory) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_MCContractFactory, _swig_p) + return +} + +func NewMCContractFactory() (_swig_ret MCContractFactory) { + return _swig_wrap_new_MCContractFactory() +} + +var _wrap_delete_MCContractFactory unsafe.Pointer + +func _swig_wrap_delete_MCContractFactory(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_MCContractFactory, _swig_p) + return +} + +func DeleteMCContractFactory(arg1 MCContractFactory) { + _swig_wrap_delete_MCContractFactory(arg1.Swigcptr()) +} + +type MCContractFactory interface { + Swigcptr() uintptr + SwigIsMCContractFactory() +} + +type SwigcptrMCContractFactory2 uintptr + +func (p SwigcptrMCContractFactory2) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrMCContractFactory2) SwigIsMCContractFactory2() { +} + +var _wrap_MCContractFactory2_getInstance unsafe.Pointer + +func _swig_wrap_MCContractFactory2_getInstance() (base SwigcptrMCContractFactory2) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_MCContractFactory2_getInstance, _swig_p) + return +} + +func MCContractFactory2GetInstance() (_swig_ret MCContractFactory2) { + return _swig_wrap_MCContractFactory2_getInstance() +} + +var _wrap_new_MCContractFactory2 unsafe.Pointer + +func _swig_wrap_new_MCContractFactory2() (base SwigcptrMCContractFactory2) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_MCContractFactory2, _swig_p) + return +} + +func NewMCContractFactory2() (_swig_ret MCContractFactory2) { + return _swig_wrap_new_MCContractFactory2() +} + +var _wrap_delete_MCContractFactory2 unsafe.Pointer + +func _swig_wrap_delete_MCContractFactory2(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_MCContractFactory2, _swig_p) + return +} + +func DeleteMCContractFactory2(arg1 MCContractFactory2) { + _swig_wrap_delete_MCContractFactory2(arg1.Swigcptr()) +} + +type MCContractFactory2 interface { + Swigcptr() uintptr + SwigIsMCContractFactory2() +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/template_typedef_import.go b/Examples/test-suite/go/template_typedef_import.go new file mode 100644 index 000000000..c0cbb2e8b --- /dev/null +++ b/Examples/test-suite/go/template_typedef_import.go @@ -0,0 +1,270 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../template_typedef_import.i + +package template_typedef_import + +import "unsafe" +import _ "runtime/cgo" +import "template_typedef_cplx2" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +var _wrap_my_func_r unsafe.Pointer + +func _swig_wrap_my_func_r(base uintptr) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_my_func_r, _swig_p) + return +} + +func My_func_r(arg1 template_typedef_cplx2.ArithUnaryFunction_double_double) (_swig_ret int) { + return _swig_wrap_my_func_r(arg1.Swigcptr()) +} + +var _wrap_my_func_c unsafe.Pointer + +func _swig_wrap_my_func_c(base uintptr) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_my_func_c, _swig_p) + return +} + +func My_func_c(arg1 template_typedef_cplx2.ArithUnaryFunction_complex_complex) (_swig_ret int) { + return _swig_wrap_my_func_c(arg1.Swigcptr()) +} + +type SwigcptrSin uintptr + +func (p SwigcptrSin) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrSin) SwigIsSin() { +} + +var _wrap_new_Sin unsafe.Pointer + +func _swig_wrap_new_Sin() (base SwigcptrSin) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Sin, _swig_p) + return +} + +func NewSin() (_swig_ret Sin) { + return _swig_wrap_new_Sin() +} + +var _wrap_delete_Sin unsafe.Pointer + +func _swig_wrap_delete_Sin(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Sin, _swig_p) + return +} + +func DeleteSin(arg1 Sin) { + _swig_wrap_delete_Sin(arg1.Swigcptr()) +} + +var _wrap_Sin_get_arith_value unsafe.Pointer + +func _swig_wrap_Sin_get_arith_value(base SwigcptrSin) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Sin_get_arith_value, _swig_p) + return +} + +func (_swig_base SwigcptrSin) Get_arith_value() (_swig_ret int) { + return _swig_wrap_Sin_get_arith_value(_swig_base) +} + +var _wrap_Sin_get_value unsafe.Pointer + +func _swig_wrap_Sin_get_value(base SwigcptrSin) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Sin_get_value, _swig_p) + return +} + +func (_swig_base SwigcptrSin) Get_value() (_swig_ret int) { + return _swig_wrap_Sin_get_value(_swig_base) +} + +var _wrap_Sin_get_base_value unsafe.Pointer + +func _swig_wrap_Sin_get_base_value(base SwigcptrSin) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Sin_get_base_value, _swig_p) + return +} + +func (_swig_base SwigcptrSin) Get_base_value() (_swig_ret int) { + return _swig_wrap_Sin_get_base_value(_swig_base) +} + +func (p SwigcptrSin) SwigIsArithUnaryFunction_double_double() { +} + +func (p SwigcptrSin) SwigGetArithUnaryFunction_double_double() template_typedef_cplx2.ArithUnaryFunction_double_double { + return template_typedef_cplx2.SwigcptrArithUnaryFunction_double_double(p.Swigcptr()) +} + +func (p SwigcptrSin) SwigIsUnaryFunction_double_double() { +} + +func (p SwigcptrSin) SwigGetUnaryFunction_double_double() template_typedef_cplx2.UnaryFunction_double_double { + return template_typedef_cplx2.SwigcptrUnaryFunction_double_double(p.Swigcptr()) +} + +func (p SwigcptrSin) SwigIsUnaryFunctionBase() { +} + +func (p SwigcptrSin) SwigGetUnaryFunctionBase() template_typedef_cplx2.UnaryFunctionBase { + return template_typedef_cplx2.SwigcptrUnaryFunctionBase(p.Swigcptr()) +} + +type Sin interface { + Swigcptr() uintptr + SwigIsSin() + Get_arith_value() (_swig_ret int) + Get_value() (_swig_ret int) + Get_base_value() (_swig_ret int) + SwigIsArithUnaryFunction_double_double() + SwigGetArithUnaryFunction_double_double() template_typedef_cplx2.ArithUnaryFunction_double_double + SwigIsUnaryFunction_double_double() + SwigGetUnaryFunction_double_double() template_typedef_cplx2.UnaryFunction_double_double + SwigIsUnaryFunctionBase() + SwigGetUnaryFunctionBase() template_typedef_cplx2.UnaryFunctionBase +} + +type SwigcptrCSin uintptr + +func (p SwigcptrCSin) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrCSin) SwigIsCSin() { +} + +var _wrap_new_CSin unsafe.Pointer + +func _swig_wrap_new_CSin() (base SwigcptrCSin) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_CSin, _swig_p) + return +} + +func NewCSin() (_swig_ret CSin) { + return _swig_wrap_new_CSin() +} + +var _wrap_delete_CSin unsafe.Pointer + +func _swig_wrap_delete_CSin(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_CSin, _swig_p) + return +} + +func DeleteCSin(arg1 CSin) { + _swig_wrap_delete_CSin(arg1.Swigcptr()) +} + +var _wrap_CSin_get_arith_value unsafe.Pointer + +func _swig_wrap_CSin_get_arith_value(base SwigcptrCSin) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_CSin_get_arith_value, _swig_p) + return +} + +func (_swig_base SwigcptrCSin) Get_arith_value() (_swig_ret int) { + return _swig_wrap_CSin_get_arith_value(_swig_base) +} + +var _wrap_CSin_get_value unsafe.Pointer + +func _swig_wrap_CSin_get_value(base SwigcptrCSin) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_CSin_get_value, _swig_p) + return +} + +func (_swig_base SwigcptrCSin) Get_value() (_swig_ret int) { + return _swig_wrap_CSin_get_value(_swig_base) +} + +var _wrap_CSin_get_base_value unsafe.Pointer + +func _swig_wrap_CSin_get_base_value(base SwigcptrCSin) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_CSin_get_base_value, _swig_p) + return +} + +func (_swig_base SwigcptrCSin) Get_base_value() (_swig_ret int) { + return _swig_wrap_CSin_get_base_value(_swig_base) +} + +func (p SwigcptrCSin) SwigIsArithUnaryFunction_complex_complex() { +} + +func (p SwigcptrCSin) SwigGetArithUnaryFunction_complex_complex() template_typedef_cplx2.ArithUnaryFunction_complex_complex { + return template_typedef_cplx2.SwigcptrArithUnaryFunction_complex_complex(p.Swigcptr()) +} + +func (p SwigcptrCSin) SwigIsUnaryFunction_complex_complex() { +} + +func (p SwigcptrCSin) SwigGetUnaryFunction_complex_complex() template_typedef_cplx2.UnaryFunction_complex_complex { + return template_typedef_cplx2.SwigcptrUnaryFunction_complex_complex(p.Swigcptr()) +} + +func (p SwigcptrCSin) SwigIsUnaryFunctionBase() { +} + +func (p SwigcptrCSin) SwigGetUnaryFunctionBase() template_typedef_cplx2.UnaryFunctionBase { + return template_typedef_cplx2.SwigcptrUnaryFunctionBase(p.Swigcptr()) +} + +type CSin interface { + Swigcptr() uintptr + SwigIsCSin() + Get_arith_value() (_swig_ret int) + Get_value() (_swig_ret int) + Get_base_value() (_swig_ret int) + SwigIsArithUnaryFunction_complex_complex() + SwigGetArithUnaryFunction_complex_complex() template_typedef_cplx2.ArithUnaryFunction_complex_complex + SwigIsUnaryFunction_complex_complex() + SwigGetUnaryFunction_complex_complex() template_typedef_cplx2.UnaryFunction_complex_complex + SwigIsUnaryFunctionBase() + SwigGetUnaryFunctionBase() template_typedef_cplx2.UnaryFunctionBase +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/template_typedef_inherit.go b/Examples/test-suite/go/template_typedef_inherit.go new file mode 100644 index 000000000..1df005644 --- /dev/null +++ b/Examples/test-suite/go/template_typedef_inherit.go @@ -0,0 +1,246 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../template_typedef_inherit.i + +package template_typedef_inherit + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrStringPersistentCollection uintptr + +func (p SwigcptrStringPersistentCollection) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrStringPersistentCollection) SwigIsStringPersistentCollection() { +} + +var _wrap_StringPersistentCollection_add unsafe.Pointer + +func _swig_wrap_StringPersistentCollection_add(base SwigcptrStringPersistentCollection, _ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_StringPersistentCollection_add, _swig_p) + return +} + +func (arg1 SwigcptrStringPersistentCollection) Add(arg2 string) { + _swig_wrap_StringPersistentCollection_add(arg1, arg2) +} + +var _wrap_new_StringPersistentCollection unsafe.Pointer + +func _swig_wrap_new_StringPersistentCollection() (base SwigcptrStringPersistentCollection) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_StringPersistentCollection, _swig_p) + return +} + +func NewStringPersistentCollection() (_swig_ret StringPersistentCollection) { + return _swig_wrap_new_StringPersistentCollection() +} + +var _wrap_delete_StringPersistentCollection unsafe.Pointer + +func _swig_wrap_delete_StringPersistentCollection(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_StringPersistentCollection, _swig_p) + return +} + +func DeleteStringPersistentCollection(arg1 StringPersistentCollection) { + _swig_wrap_delete_StringPersistentCollection(arg1.Swigcptr()) +} + +type StringPersistentCollection interface { + Swigcptr() uintptr + SwigIsStringPersistentCollection() + Add(arg2 string) +} + +type SwigcptrDescriptionImplementation uintptr + +func (p SwigcptrDescriptionImplementation) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrDescriptionImplementation) SwigIsDescriptionImplementation() { +} + +var _wrap_new_DescriptionImplementation unsafe.Pointer + +func _swig_wrap_new_DescriptionImplementation() (base SwigcptrDescriptionImplementation) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_DescriptionImplementation, _swig_p) + return +} + +func NewDescriptionImplementation() (_swig_ret DescriptionImplementation) { + return _swig_wrap_new_DescriptionImplementation() +} + +var _wrap_delete_DescriptionImplementation unsafe.Pointer + +func _swig_wrap_delete_DescriptionImplementation(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_DescriptionImplementation, _swig_p) + return +} + +func DeleteDescriptionImplementation(arg1 DescriptionImplementation) { + _swig_wrap_delete_DescriptionImplementation(arg1.Swigcptr()) +} + +var _wrap_DescriptionImplementation_add unsafe.Pointer + +func _swig_wrap_DescriptionImplementation_add(base SwigcptrDescriptionImplementation, _ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_DescriptionImplementation_add, _swig_p) + return +} + +func (_swig_base SwigcptrDescriptionImplementation) Add(arg1 string) { + _swig_wrap_DescriptionImplementation_add(_swig_base, arg1) +} + +func (p SwigcptrDescriptionImplementation) SwigIsStringPersistentCollection() { +} + +func (p SwigcptrDescriptionImplementation) SwigGetStringPersistentCollection() StringPersistentCollection { + return SwigcptrStringPersistentCollection(p.Swigcptr()) +} + +type DescriptionImplementation interface { + Swigcptr() uintptr + SwigIsDescriptionImplementation() + Add(arg1 string) + SwigIsStringPersistentCollection() + SwigGetStringPersistentCollection() StringPersistentCollection +} + +type SwigcptrDescriptionImplementationTypedInterfaceObject uintptr + +func (p SwigcptrDescriptionImplementationTypedInterfaceObject) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrDescriptionImplementationTypedInterfaceObject) SwigIsDescriptionImplementationTypedInterfaceObject() { +} + +var _wrap_new_DescriptionImplementationTypedInterfaceObject unsafe.Pointer + +func _swig_wrap_new_DescriptionImplementationTypedInterfaceObject() (base SwigcptrDescriptionImplementationTypedInterfaceObject) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_DescriptionImplementationTypedInterfaceObject, _swig_p) + return +} + +func NewDescriptionImplementationTypedInterfaceObject() (_swig_ret DescriptionImplementationTypedInterfaceObject) { + return _swig_wrap_new_DescriptionImplementationTypedInterfaceObject() +} + +var _wrap_delete_DescriptionImplementationTypedInterfaceObject unsafe.Pointer + +func _swig_wrap_delete_DescriptionImplementationTypedInterfaceObject(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_DescriptionImplementationTypedInterfaceObject, _swig_p) + return +} + +func DeleteDescriptionImplementationTypedInterfaceObject(arg1 DescriptionImplementationTypedInterfaceObject) { + _swig_wrap_delete_DescriptionImplementationTypedInterfaceObject(arg1.Swigcptr()) +} + +type DescriptionImplementationTypedInterfaceObject interface { + Swigcptr() uintptr + SwigIsDescriptionImplementationTypedInterfaceObject() +} + +type SwigcptrDescriptionImplementationTypedCollectionInterfaceObject uintptr + +func (p SwigcptrDescriptionImplementationTypedCollectionInterfaceObject) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrDescriptionImplementationTypedCollectionInterfaceObject) SwigIsDescriptionImplementationTypedCollectionInterfaceObject() { +} + +var _wrap_DescriptionImplementationTypedCollectionInterfaceObject_add unsafe.Pointer + +func _swig_wrap_DescriptionImplementationTypedCollectionInterfaceObject_add(base SwigcptrDescriptionImplementationTypedCollectionInterfaceObject, _ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_DescriptionImplementationTypedCollectionInterfaceObject_add, _swig_p) + return +} + +func (arg1 SwigcptrDescriptionImplementationTypedCollectionInterfaceObject) Add(arg2 string) { + _swig_wrap_DescriptionImplementationTypedCollectionInterfaceObject_add(arg1, arg2) +} + +var _wrap_new_DescriptionImplementationTypedCollectionInterfaceObject unsafe.Pointer + +func _swig_wrap_new_DescriptionImplementationTypedCollectionInterfaceObject() (base SwigcptrDescriptionImplementationTypedCollectionInterfaceObject) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_DescriptionImplementationTypedCollectionInterfaceObject, _swig_p) + return +} + +func NewDescriptionImplementationTypedCollectionInterfaceObject() (_swig_ret DescriptionImplementationTypedCollectionInterfaceObject) { + return _swig_wrap_new_DescriptionImplementationTypedCollectionInterfaceObject() +} + +var _wrap_delete_DescriptionImplementationTypedCollectionInterfaceObject unsafe.Pointer + +func _swig_wrap_delete_DescriptionImplementationTypedCollectionInterfaceObject(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_DescriptionImplementationTypedCollectionInterfaceObject, _swig_p) + return +} + +func DeleteDescriptionImplementationTypedCollectionInterfaceObject(arg1 DescriptionImplementationTypedCollectionInterfaceObject) { + _swig_wrap_delete_DescriptionImplementationTypedCollectionInterfaceObject(arg1.Swigcptr()) +} + +func (p SwigcptrDescriptionImplementationTypedCollectionInterfaceObject) SwigIsDescriptionImplementationTypedInterfaceObject() { +} + +func (p SwigcptrDescriptionImplementationTypedCollectionInterfaceObject) SwigGetDescriptionImplementationTypedInterfaceObject() DescriptionImplementationTypedInterfaceObject { + return SwigcptrDescriptionImplementationTypedInterfaceObject(p.Swigcptr()) +} + +type DescriptionImplementationTypedCollectionInterfaceObject interface { + Swigcptr() uintptr + SwigIsDescriptionImplementationTypedCollectionInterfaceObject() + Add(arg2 string) + SwigIsDescriptionImplementationTypedInterfaceObject() + SwigGetDescriptionImplementationTypedInterfaceObject() DescriptionImplementationTypedInterfaceObject +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/template_typedef_ns.go b/Examples/test-suite/go/template_typedef_ns.go new file mode 100644 index 000000000..bda2f9e60 --- /dev/null +++ b/Examples/test-suite/go/template_typedef_ns.go @@ -0,0 +1,101 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../template_typedef_ns.i + +package template_typedef_ns + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrAlphaInt uintptr + +func (p SwigcptrAlphaInt) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrAlphaInt) SwigIsAlphaInt() { +} + +var _wrap_AlphaInt_x_set unsafe.Pointer + +func _swig_wrap_AlphaInt_x_set(base SwigcptrAlphaInt, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_AlphaInt_x_set, _swig_p) + return +} + +func (arg1 SwigcptrAlphaInt) SetX(arg2 int) { + _swig_wrap_AlphaInt_x_set(arg1, arg2) +} + +var _wrap_AlphaInt_x_get unsafe.Pointer + +func _swig_wrap_AlphaInt_x_get(base SwigcptrAlphaInt) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_AlphaInt_x_get, _swig_p) + return +} + +func (arg1 SwigcptrAlphaInt) GetX() (_swig_ret int) { + return _swig_wrap_AlphaInt_x_get(arg1) +} + +var _wrap_new_AlphaInt unsafe.Pointer + +func _swig_wrap_new_AlphaInt() (base SwigcptrAlphaInt) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_AlphaInt, _swig_p) + return +} + +func NewAlphaInt() (_swig_ret AlphaInt) { + return _swig_wrap_new_AlphaInt() +} + +var _wrap_delete_AlphaInt unsafe.Pointer + +func _swig_wrap_delete_AlphaInt(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_AlphaInt, _swig_p) + return +} + +func DeleteAlphaInt(arg1 AlphaInt) { + _swig_wrap_delete_AlphaInt(arg1.Swigcptr()) +} + +type AlphaInt interface { + Swigcptr() uintptr + SwigIsAlphaInt() + SetX(arg2 int) + GetX() (_swig_ret int) +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/template_typedef_ptr.go b/Examples/test-suite/go/template_typedef_ptr.go new file mode 100644 index 000000000..219d0fea6 --- /dev/null +++ b/Examples/test-suite/go/template_typedef_ptr.go @@ -0,0 +1,113 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../template_typedef_ptr.i + +package template_typedef_ptr + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrC uintptr + +func (p SwigcptrC) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrC) SwigIsC() { +} + +var _wrap_new_C unsafe.Pointer + +func _swig_wrap_new_C() (base SwigcptrC) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_C, _swig_p) + return +} + +func NewC() (_swig_ret C) { + return _swig_wrap_new_C() +} + +var _wrap_delete_C unsafe.Pointer + +func _swig_wrap_delete_C(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_C, _swig_p) + return +} + +func DeleteC(arg1 C) { + _swig_wrap_delete_C(arg1.Swigcptr()) +} + +type C interface { + Swigcptr() uintptr + SwigIsC() +} + +type SwigcptrTest_pC uintptr + +func (p SwigcptrTest_pC) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrTest_pC) SwigIsTest_pC() { +} + +var _wrap_new_test_pC unsafe.Pointer + +func _swig_wrap_new_test_pC(base uintptr) (_ SwigcptrTest_pC) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_test_pC, _swig_p) + return +} + +func NewTest_pC(arg1 C) (_swig_ret Test_pC) { + return _swig_wrap_new_test_pC(arg1.Swigcptr()) +} + +var _wrap_delete_test_pC unsafe.Pointer + +func _swig_wrap_delete_test_pC(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_test_pC, _swig_p) + return +} + +func DeleteTest_pC(arg1 Test_pC) { + _swig_wrap_delete_test_pC(arg1.Swigcptr()) +} + +type Test_pC interface { + Swigcptr() uintptr + SwigIsTest_pC() +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/template_typedef_rec.go b/Examples/test-suite/go/template_typedef_rec.go new file mode 100644 index 000000000..66afd4dc2 --- /dev/null +++ b/Examples/test-suite/go/template_typedef_rec.go @@ -0,0 +1,189 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../template_typedef_rec.i + +package template_typedef_rec + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrTest_Array uintptr + +func (p SwigcptrTest_Array) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrTest_Array) SwigIsTest_Array() { +} + +var _wrap_new_test_Array unsafe.Pointer + +func _swig_wrap_new_test_Array() (base SwigcptrTest_Array) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_test_Array, _swig_p) + return +} + +func NewTest_Array() (_swig_ret Test_Array) { + return _swig_wrap_new_test_Array() +} + +var _wrap_delete_test_Array unsafe.Pointer + +func _swig_wrap_delete_test_Array(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_test_Array, _swig_p) + return +} + +func DeleteTest_Array(arg1 Test_Array) { + _swig_wrap_delete_test_Array(arg1.Swigcptr()) +} + +type Test_Array interface { + Swigcptr() uintptr + SwigIsTest_Array() +} + +type SwigcptrModelNode uintptr + +func (p SwigcptrModelNode) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrModelNode) SwigIsModelNode() { +} + +var _wrap_new_ModelNode unsafe.Pointer + +func _swig_wrap_new_ModelNode() (base SwigcptrModelNode) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_ModelNode, _swig_p) + return +} + +func NewModelNode() (_swig_ret ModelNode) { + return _swig_wrap_new_ModelNode() +} + +var _wrap_delete_ModelNode unsafe.Pointer + +func _swig_wrap_delete_ModelNode(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_ModelNode, _swig_p) + return +} + +func DeleteModelNode(arg1 ModelNode) { + _swig_wrap_delete_ModelNode(arg1.Swigcptr()) +} + +type ModelNode interface { + Swigcptr() uintptr + SwigIsModelNode() +} + +type SwigcptrModel uintptr + +func (p SwigcptrModel) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrModel) SwigIsModel() { +} + +var _wrap_new_Model unsafe.Pointer + +func _swig_wrap_new_Model() (base SwigcptrModel) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Model, _swig_p) + return +} + +func NewModel() (_swig_ret Model) { + return _swig_wrap_new_Model() +} + +var _wrap_delete_Model unsafe.Pointer + +func _swig_wrap_delete_Model(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Model, _swig_p) + return +} + +func DeleteModel(arg1 Model) { + _swig_wrap_delete_Model(arg1.Swigcptr()) +} + +type Model interface { + Swigcptr() uintptr + SwigIsModel() +} + +type SwigcptrModelTree uintptr + +func (p SwigcptrModelTree) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrModelTree) SwigIsModelTree() { +} + +var _wrap_new_ModelTree unsafe.Pointer + +func _swig_wrap_new_ModelTree() (base SwigcptrModelTree) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_ModelTree, _swig_p) + return +} + +func NewModelTree() (_swig_ret ModelTree) { + return _swig_wrap_new_ModelTree() +} + +var _wrap_delete_ModelTree unsafe.Pointer + +func _swig_wrap_delete_ModelTree(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_ModelTree, _swig_p) + return +} + +func DeleteModelTree(arg1 ModelTree) { + _swig_wrap_delete_ModelTree(arg1.Swigcptr()) +} + +type ModelTree interface { + Swigcptr() uintptr + SwigIsModelTree() +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/template_typedef_typedef.go b/Examples/test-suite/go/template_typedef_typedef.go new file mode 100644 index 000000000..6fcba05a6 --- /dev/null +++ b/Examples/test-suite/go/template_typedef_typedef.go @@ -0,0 +1,259 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../template_typedef_typedef.i + +package template_typedef_typedef + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrBase uintptr + +func (p SwigcptrBase) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrBase) SwigIsBase() { +} + +var _wrap_new_Base unsafe.Pointer + +func _swig_wrap_new_Base() (base SwigcptrBase) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Base, _swig_p) + return +} + +func NewBase() (_swig_ret Base) { + return _swig_wrap_new_Base() +} + +var _wrap_delete_Base unsafe.Pointer + +func _swig_wrap_delete_Base(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Base, _swig_p) + return +} + +func DeleteBase(arg1 Base) { + _swig_wrap_delete_Base(arg1.Swigcptr()) +} + +type Base interface { + Swigcptr() uintptr + SwigIsBase() +} + +type SwigcptrFactory uintptr + +func (p SwigcptrFactory) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrFactory) SwigIsFactory() { +} + +var _wrap_Factory_getBlabla4 unsafe.Pointer + +func _swig_wrap_Factory_getBlabla4(base SwigcptrFactory, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Factory_getBlabla4, _swig_p) + return +} + +func (arg1 SwigcptrFactory) GetBlabla4(arg2 Object2Base) { + _swig_wrap_Factory_getBlabla4(arg1, arg2.Swigcptr()) +} + +var _wrap_Factory_getBlabla3 unsafe.Pointer + +func _swig_wrap_Factory_getBlabla3(base SwigcptrFactory, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Factory_getBlabla3, _swig_p) + return +} + +func (arg1 SwigcptrFactory) GetBlabla3(arg2 ObjectBase) { + _swig_wrap_Factory_getBlabla3(arg1, arg2.Swigcptr()) +} + +var _wrap_new_Factory unsafe.Pointer + +func _swig_wrap_new_Factory() (base SwigcptrFactory) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Factory, _swig_p) + return +} + +func NewFactory() (_swig_ret Factory) { + return _swig_wrap_new_Factory() +} + +var _wrap_delete_Factory unsafe.Pointer + +func _swig_wrap_delete_Factory(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Factory, _swig_p) + return +} + +func DeleteFactory(arg1 Factory) { + _swig_wrap_delete_Factory(arg1.Swigcptr()) +} + +type Factory interface { + Swigcptr() uintptr + SwigIsFactory() + GetBlabla4(arg2 Object2Base) + GetBlabla3(arg2 ObjectBase) +} + +type SwigcptrObjectBase uintptr + +func (p SwigcptrObjectBase) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrObjectBase) SwigIsObjectBase() { +} + +var _wrap_ObjectBase_getBlabla1 unsafe.Pointer + +func _swig_wrap_ObjectBase_getBlabla1(base SwigcptrObjectBase, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_ObjectBase_getBlabla1, _swig_p) + return +} + +func (arg1 SwigcptrObjectBase) GetBlabla1(arg2 ObjectBase) { + _swig_wrap_ObjectBase_getBlabla1(arg1, arg2.Swigcptr()) +} + +var _wrap_new_ObjectBase unsafe.Pointer + +func _swig_wrap_new_ObjectBase() (base SwigcptrObjectBase) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_ObjectBase, _swig_p) + return +} + +func NewObjectBase() (_swig_ret ObjectBase) { + return _swig_wrap_new_ObjectBase() +} + +var _wrap_delete_ObjectBase unsafe.Pointer + +func _swig_wrap_delete_ObjectBase(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_ObjectBase, _swig_p) + return +} + +func DeleteObjectBase(arg1 ObjectBase) { + _swig_wrap_delete_ObjectBase(arg1.Swigcptr()) +} + +func (p SwigcptrObjectBase) SwigIsBase() { +} + +func (p SwigcptrObjectBase) SwigGetBase() Base { + return SwigcptrBase(p.Swigcptr()) +} + +type ObjectBase interface { + Swigcptr() uintptr + SwigIsObjectBase() + GetBlabla1(arg2 ObjectBase) + SwigIsBase() + SwigGetBase() Base +} + +type SwigcptrObject2Base uintptr + +func (p SwigcptrObject2Base) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrObject2Base) SwigIsObject2Base() { +} + +var _wrap_Object2Base_getBlabla2 unsafe.Pointer + +func _swig_wrap_Object2Base_getBlabla2(base SwigcptrObject2Base, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Object2Base_getBlabla2, _swig_p) + return +} + +func (arg1 SwigcptrObject2Base) GetBlabla2(arg2 Object2Base) { + _swig_wrap_Object2Base_getBlabla2(arg1, arg2.Swigcptr()) +} + +var _wrap_new_Object2Base unsafe.Pointer + +func _swig_wrap_new_Object2Base() (base SwigcptrObject2Base) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Object2Base, _swig_p) + return +} + +func NewObject2Base() (_swig_ret Object2Base) { + return _swig_wrap_new_Object2Base() +} + +var _wrap_delete_Object2Base unsafe.Pointer + +func _swig_wrap_delete_Object2Base(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Object2Base, _swig_p) + return +} + +func DeleteObject2Base(arg1 Object2Base) { + _swig_wrap_delete_Object2Base(arg1.Swigcptr()) +} + +func (p SwigcptrObject2Base) SwigIsBase() { +} + +func (p SwigcptrObject2Base) SwigGetBase() Base { + return SwigcptrBase(p.Swigcptr()) +} + +type Object2Base interface { + Swigcptr() uintptr + SwigIsObject2Base() + GetBlabla2(arg2 Object2Base) + SwigIsBase() + SwigGetBase() Base +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/template_typemaps.go b/Examples/test-suite/go/template_typemaps.go new file mode 100644 index 000000000..543b05e25 --- /dev/null +++ b/Examples/test-suite/go/template_typemaps.go @@ -0,0 +1,237 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../template_typemaps.i + +package template_typemaps + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrFoo_I1 uintptr + +func (p SwigcptrFoo_I1) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrFoo_I1) SwigIsFoo_I1() { +} + +var _wrap_Foo_I1_val_set unsafe.Pointer + +func _swig_wrap_Foo_I1_val_set(base SwigcptrFoo_I1, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_I1_val_set, _swig_p) + return +} + +func (arg1 SwigcptrFoo_I1) SetVal(arg2 Integer1) { + _swig_wrap_Foo_I1_val_set(arg1, arg2.Swigcptr()) +} + +var _wrap_Foo_I1_val_get unsafe.Pointer + +func _swig_wrap_Foo_I1_val_get(base SwigcptrFoo_I1) (_ SwigcptrInteger1) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_I1_val_get, _swig_p) + return +} + +func (arg1 SwigcptrFoo_I1) GetVal() (_swig_ret Integer1) { + return _swig_wrap_Foo_I1_val_get(arg1) +} + +var _wrap_Foo_I1_get_value unsafe.Pointer + +func _swig_wrap_Foo_I1_get_value(base SwigcptrFoo_I1) (_ SwigcptrInteger1) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_I1_get_value, _swig_p) + return +} + +func (arg1 SwigcptrFoo_I1) Get_value() (_swig_ret Integer1) { + return _swig_wrap_Foo_I1_get_value(arg1) +} + +var _wrap_Foo_I1_set_value unsafe.Pointer + +func _swig_wrap_Foo_I1_set_value(base SwigcptrFoo_I1, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_I1_set_value, _swig_p) + return +} + +func (arg1 SwigcptrFoo_I1) Set_value(arg2 Integer1) { + _swig_wrap_Foo_I1_set_value(arg1, arg2.Swigcptr()) +} + +var _wrap_new_Foo_I1 unsafe.Pointer + +func _swig_wrap_new_Foo_I1() (base SwigcptrFoo_I1) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Foo_I1, _swig_p) + return +} + +func NewFoo_I1() (_swig_ret Foo_I1) { + return _swig_wrap_new_Foo_I1() +} + +var _wrap_delete_Foo_I1 unsafe.Pointer + +func _swig_wrap_delete_Foo_I1(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Foo_I1, _swig_p) + return +} + +func DeleteFoo_I1(arg1 Foo_I1) { + _swig_wrap_delete_Foo_I1(arg1.Swigcptr()) +} + +type Foo_I1 interface { + Swigcptr() uintptr + SwigIsFoo_I1() + SetVal(arg2 Integer1) + GetVal() (_swig_ret Integer1) + Get_value() (_swig_ret Integer1) + Set_value(arg2 Integer1) +} + +type SwigcptrFoo_I2 uintptr + +func (p SwigcptrFoo_I2) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrFoo_I2) SwigIsFoo_I2() { +} + +var _wrap_Foo_I2_val_set unsafe.Pointer + +func _swig_wrap_Foo_I2_val_set(base SwigcptrFoo_I2, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_I2_val_set, _swig_p) + return +} + +func (arg1 SwigcptrFoo_I2) SetVal(arg2 int) { + _swig_wrap_Foo_I2_val_set(arg1, arg2) +} + +var _wrap_Foo_I2_val_get unsafe.Pointer + +func _swig_wrap_Foo_I2_val_get(base SwigcptrFoo_I2) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_I2_val_get, _swig_p) + return +} + +func (arg1 SwigcptrFoo_I2) GetVal() (_swig_ret int) { + return _swig_wrap_Foo_I2_val_get(arg1) +} + +var _wrap_Foo_I2_get_value unsafe.Pointer + +func _swig_wrap_Foo_I2_get_value(base SwigcptrFoo_I2) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_I2_get_value, _swig_p) + return +} + +func (arg1 SwigcptrFoo_I2) Get_value() (_swig_ret int) { + return _swig_wrap_Foo_I2_get_value(arg1) +} + +var _wrap_Foo_I2_set_value unsafe.Pointer + +func _swig_wrap_Foo_I2_set_value(base SwigcptrFoo_I2, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_I2_set_value, _swig_p) + return +} + +func (arg1 SwigcptrFoo_I2) Set_value(arg2 int) { + _swig_wrap_Foo_I2_set_value(arg1, arg2) +} + +var _wrap_new_Foo_I2 unsafe.Pointer + +func _swig_wrap_new_Foo_I2() (base SwigcptrFoo_I2) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Foo_I2, _swig_p) + return +} + +func NewFoo_I2() (_swig_ret Foo_I2) { + return _swig_wrap_new_Foo_I2() +} + +var _wrap_delete_Foo_I2 unsafe.Pointer + +func _swig_wrap_delete_Foo_I2(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Foo_I2, _swig_p) + return +} + +func DeleteFoo_I2(arg1 Foo_I2) { + _swig_wrap_delete_Foo_I2(arg1.Swigcptr()) +} + +type Foo_I2 interface { + Swigcptr() uintptr + SwigIsFoo_I2() + SetVal(arg2 int) + GetVal() (_swig_ret int) + Get_value() (_swig_ret int) + Set_value(arg2 int) +} + +var _wrap_bar unsafe.Pointer + +func _swig_wrap_bar(base uintptr) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_bar, _swig_p) + return +} + +func Bar(arg1 Foo_I1) (_swig_ret int) { + return _swig_wrap_bar(arg1.Swigcptr()) +} + + +type SwigcptrInteger1 uintptr +type Integer1 interface { + Swigcptr() uintptr; +} +func (p SwigcptrInteger1) Swigcptr() uintptr { + return uintptr(p) +} + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/template_typemaps_typedef.go b/Examples/test-suite/go/template_typemaps_typedef.go new file mode 100644 index 000000000..ae232e744 --- /dev/null +++ b/Examples/test-suite/go/template_typemaps_typedef.go @@ -0,0 +1,520 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../template_typemaps_typedef.i + +package template_typemaps_typedef + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrA uintptr + +func (p SwigcptrA) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrA) SwigIsA() { +} + +var _wrap_A_val_set unsafe.Pointer + +func _swig_wrap_A_val_set(base SwigcptrA, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_A_val_set, _swig_p) + return +} + +func (arg1 SwigcptrA) SetVal(arg2 int) { + _swig_wrap_A_val_set(arg1, arg2) +} + +var _wrap_A_val_get unsafe.Pointer + +func _swig_wrap_A_val_get(base SwigcptrA) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_A_val_get, _swig_p) + return +} + +func (arg1 SwigcptrA) GetVal() (_swig_ret int) { + return _swig_wrap_A_val_get(arg1) +} + +var _wrap_new_A__SWIG_0 unsafe.Pointer + +func _swig_wrap_new_A__SWIG_0(base int) (_ SwigcptrA) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_A__SWIG_0, _swig_p) + return +} + +func NewA__SWIG_0(arg1 int) (_swig_ret A) { + return _swig_wrap_new_A__SWIG_0(arg1) +} + +var _wrap_new_A__SWIG_1 unsafe.Pointer + +func _swig_wrap_new_A__SWIG_1() (base SwigcptrA) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_A__SWIG_1, _swig_p) + return +} + +func NewA__SWIG_1() (_swig_ret A) { + return _swig_wrap_new_A__SWIG_1() +} + +func NewA(a ...interface{}) A { + argc := len(a) + if argc == 0 { + return NewA__SWIG_1() + } + if argc == 1 { + return NewA__SWIG_0(a[0].(int)) + } + panic("No match for overloaded function call") +} + +var _wrap_delete_A unsafe.Pointer + +func _swig_wrap_delete_A(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_A, _swig_p) + return +} + +func DeleteA(arg1 A) { + _swig_wrap_delete_A(arg1.Swigcptr()) +} + +type A interface { + Swigcptr() uintptr + SwigIsA() + SetVal(arg2 int) + GetVal() (_swig_ret int) +} + +type SwigcptrPairIntA uintptr + +func (p SwigcptrPairIntA) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrPairIntA) SwigIsPairIntA() { +} + +var _wrap_PairIntA_first_set unsafe.Pointer + +func _swig_wrap_PairIntA_first_set(base SwigcptrPairIntA, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_PairIntA_first_set, _swig_p) + return +} + +func (arg1 SwigcptrPairIntA) SetFirst(arg2 int) { + _swig_wrap_PairIntA_first_set(arg1, arg2) +} + +var _wrap_PairIntA_first_get unsafe.Pointer + +func _swig_wrap_PairIntA_first_get(base SwigcptrPairIntA) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_PairIntA_first_get, _swig_p) + return +} + +func (arg1 SwigcptrPairIntA) GetFirst() (_swig_ret int) { + return _swig_wrap_PairIntA_first_get(arg1) +} + +var _wrap_PairIntA_second_set unsafe.Pointer + +func _swig_wrap_PairIntA_second_set(base SwigcptrPairIntA, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_PairIntA_second_set, _swig_p) + return +} + +func (arg1 SwigcptrPairIntA) SetSecond(arg2 A) { + _swig_wrap_PairIntA_second_set(arg1, arg2.Swigcptr()) +} + +var _wrap_PairIntA_second_get unsafe.Pointer + +func _swig_wrap_PairIntA_second_get(base SwigcptrPairIntA) (_ SwigcptrA) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_PairIntA_second_get, _swig_p) + return +} + +func (arg1 SwigcptrPairIntA) GetSecond() (_swig_ret A) { + return _swig_wrap_PairIntA_second_get(arg1) +} + +var _wrap_new_PairIntA unsafe.Pointer + +func _swig_wrap_new_PairIntA() (base SwigcptrPairIntA) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_PairIntA, _swig_p) + return +} + +func NewPairIntA() (_swig_ret PairIntA) { + return _swig_wrap_new_PairIntA() +} + +var _wrap_delete_PairIntA unsafe.Pointer + +func _swig_wrap_delete_PairIntA(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_PairIntA, _swig_p) + return +} + +func DeletePairIntA(arg1 PairIntA) { + _swig_wrap_delete_PairIntA(arg1.Swigcptr()) +} + +type PairIntA interface { + Swigcptr() uintptr + SwigIsPairIntA() + SetFirst(arg2 int) + GetFirst() (_swig_ret int) + SetSecond(arg2 A) + GetSecond() (_swig_ret A) +} + +type SwigcptrMultimapIntA uintptr + +func (p SwigcptrMultimapIntA) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrMultimapIntA) SwigIsMultimapIntA() { +} + +var _wrap_MultimapIntA_typemap_test unsafe.Pointer + +func _swig_wrap_MultimapIntA_typemap_test(base SwigcptrMultimapIntA, _ uintptr) (_ SwigcptrA) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_MultimapIntA_typemap_test, _swig_p) + return +} + +func (arg1 SwigcptrMultimapIntA) Typemap_test(arg2 Standard_Pair_Sl_Standard_Multimap_Sl_int_Sc_A_Sg__iterator_Sc_Standard_Multimap_Sl_int_Sc_A_Sg__iterator_Sg_) (_swig_ret A) { + return _swig_wrap_MultimapIntA_typemap_test(arg1, arg2.Swigcptr()) +} + +var _wrap_MultimapIntA_make_dummy_pair unsafe.Pointer + +func _swig_wrap_MultimapIntA_make_dummy_pair(base SwigcptrMultimapIntA) (_ SwigcptrStandard_Pair_Sl_Standard_Multimap_Sl_int_Sc_A_Sg__iterator_Sc_Standard_Multimap_Sl_int_Sc_A_Sg__iterator_Sg_) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_MultimapIntA_make_dummy_pair, _swig_p) + return +} + +func (arg1 SwigcptrMultimapIntA) Make_dummy_pair() (_swig_ret Standard_Pair_Sl_Standard_Multimap_Sl_int_Sc_A_Sg__iterator_Sc_Standard_Multimap_Sl_int_Sc_A_Sg__iterator_Sg_) { + return _swig_wrap_MultimapIntA_make_dummy_pair(arg1) +} + +var _wrap_new_MultimapIntA unsafe.Pointer + +func _swig_wrap_new_MultimapIntA() (base SwigcptrMultimapIntA) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_MultimapIntA, _swig_p) + return +} + +func NewMultimapIntA() (_swig_ret MultimapIntA) { + return _swig_wrap_new_MultimapIntA() +} + +var _wrap_delete_MultimapIntA unsafe.Pointer + +func _swig_wrap_delete_MultimapIntA(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_MultimapIntA, _swig_p) + return +} + +func DeleteMultimapIntA(arg1 MultimapIntA) { + _swig_wrap_delete_MultimapIntA(arg1.Swigcptr()) +} + +type MultimapIntA interface { + Swigcptr() uintptr + SwigIsMultimapIntA() + Typemap_test(arg2 Standard_Pair_Sl_Standard_Multimap_Sl_int_Sc_A_Sg__iterator_Sc_Standard_Multimap_Sl_int_Sc_A_Sg__iterator_Sg_) (_swig_ret A) + Make_dummy_pair() (_swig_ret Standard_Pair_Sl_Standard_Multimap_Sl_int_Sc_A_Sg__iterator_Sc_Standard_Multimap_Sl_int_Sc_A_Sg__iterator_Sg_) +} + +type SwigcptrPairAInt uintptr + +func (p SwigcptrPairAInt) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrPairAInt) SwigIsPairAInt() { +} + +var _wrap_PairAInt_first_set unsafe.Pointer + +func _swig_wrap_PairAInt_first_set(base SwigcptrPairAInt, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_PairAInt_first_set, _swig_p) + return +} + +func (arg1 SwigcptrPairAInt) SetFirst(arg2 A) { + _swig_wrap_PairAInt_first_set(arg1, arg2.Swigcptr()) +} + +var _wrap_PairAInt_first_get unsafe.Pointer + +func _swig_wrap_PairAInt_first_get(base SwigcptrPairAInt) (_ SwigcptrA) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_PairAInt_first_get, _swig_p) + return +} + +func (arg1 SwigcptrPairAInt) GetFirst() (_swig_ret A) { + return _swig_wrap_PairAInt_first_get(arg1) +} + +var _wrap_PairAInt_second_set unsafe.Pointer + +func _swig_wrap_PairAInt_second_set(base SwigcptrPairAInt, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_PairAInt_second_set, _swig_p) + return +} + +func (arg1 SwigcptrPairAInt) SetSecond(arg2 int) { + _swig_wrap_PairAInt_second_set(arg1, arg2) +} + +var _wrap_PairAInt_second_get unsafe.Pointer + +func _swig_wrap_PairAInt_second_get(base SwigcptrPairAInt) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_PairAInt_second_get, _swig_p) + return +} + +func (arg1 SwigcptrPairAInt) GetSecond() (_swig_ret int) { + return _swig_wrap_PairAInt_second_get(arg1) +} + +var _wrap_new_PairAInt unsafe.Pointer + +func _swig_wrap_new_PairAInt() (base SwigcptrPairAInt) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_PairAInt, _swig_p) + return +} + +func NewPairAInt() (_swig_ret PairAInt) { + return _swig_wrap_new_PairAInt() +} + +var _wrap_delete_PairAInt unsafe.Pointer + +func _swig_wrap_delete_PairAInt(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_PairAInt, _swig_p) + return +} + +func DeletePairAInt(arg1 PairAInt) { + _swig_wrap_delete_PairAInt(arg1.Swigcptr()) +} + +type PairAInt interface { + Swigcptr() uintptr + SwigIsPairAInt() + SetFirst(arg2 A) + GetFirst() (_swig_ret A) + SetSecond(arg2 int) + GetSecond() (_swig_ret int) +} + +type SwigcptrMultimapAInt uintptr + +func (p SwigcptrMultimapAInt) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrMultimapAInt) SwigIsMultimapAInt() { +} + +var _wrap_MultimapAInt_typemap_test unsafe.Pointer + +func _swig_wrap_MultimapAInt_typemap_test(base SwigcptrMultimapAInt, _ uintptr) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_MultimapAInt_typemap_test, _swig_p) + return +} + +func (arg1 SwigcptrMultimapAInt) Typemap_test(arg2 Standard_Pair_Sl_Standard_Multimap_Sl_A_Sc_int_Sg__iterator_Sc_Standard_Multimap_Sl_A_Sc_int_Sg__iterator_Sg_) (_swig_ret int) { + return _swig_wrap_MultimapAInt_typemap_test(arg1, arg2.Swigcptr()) +} + +var _wrap_MultimapAInt_make_dummy_pair unsafe.Pointer + +func _swig_wrap_MultimapAInt_make_dummy_pair(base SwigcptrMultimapAInt) (_ SwigcptrStandard_Pair_Sl_Standard_Multimap_Sl_A_Sc_int_Sg__iterator_Sc_Standard_Multimap_Sl_A_Sc_int_Sg__iterator_Sg_) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_MultimapAInt_make_dummy_pair, _swig_p) + return +} + +func (arg1 SwigcptrMultimapAInt) Make_dummy_pair() (_swig_ret Standard_Pair_Sl_Standard_Multimap_Sl_A_Sc_int_Sg__iterator_Sc_Standard_Multimap_Sl_A_Sc_int_Sg__iterator_Sg_) { + return _swig_wrap_MultimapAInt_make_dummy_pair(arg1) +} + +var _wrap_new_MultimapAInt unsafe.Pointer + +func _swig_wrap_new_MultimapAInt() (base SwigcptrMultimapAInt) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_MultimapAInt, _swig_p) + return +} + +func NewMultimapAInt() (_swig_ret MultimapAInt) { + return _swig_wrap_new_MultimapAInt() +} + +var _wrap_delete_MultimapAInt unsafe.Pointer + +func _swig_wrap_delete_MultimapAInt(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_MultimapAInt, _swig_p) + return +} + +func DeleteMultimapAInt(arg1 MultimapAInt) { + _swig_wrap_delete_MultimapAInt(arg1.Swigcptr()) +} + +type MultimapAInt interface { + Swigcptr() uintptr + SwigIsMultimapAInt() + Typemap_test(arg2 Standard_Pair_Sl_Standard_Multimap_Sl_A_Sc_int_Sg__iterator_Sc_Standard_Multimap_Sl_A_Sc_int_Sg__iterator_Sg_) (_swig_ret int) + Make_dummy_pair() (_swig_ret Standard_Pair_Sl_Standard_Multimap_Sl_A_Sc_int_Sg__iterator_Sc_Standard_Multimap_Sl_A_Sc_int_Sg__iterator_Sg_) +} + +var _wrap_typedef_test1 unsafe.Pointer + +func _swig_wrap_typedef_test1(base uintptr) (_ SwigcptrA) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_typedef_test1, _swig_p) + return +} + +func Typedef_test1(arg1 Standard_Pair_Sl_Standard_Multimap_Sl_int_Sc_A_Sg__iterator_Sc_Standard_Multimap_Sl_int_Sc_A_Sg__iterator_Sg_) (_swig_ret A) { + return _swig_wrap_typedef_test1(arg1.Swigcptr()) +} + +var _wrap_typedef_test2 unsafe.Pointer + +func _swig_wrap_typedef_test2(base uintptr) (_ SwigcptrA) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_typedef_test2, _swig_p) + return +} + +func Typedef_test2(arg1 Standard_Pair_Sl_Standard_Multimap_Sl_int_Sc_A_Sg__iterator_Sc_Standard_Multimap_Sl_int_Sc_A_Sg__iterator_Sg_) (_swig_ret A) { + return _swig_wrap_typedef_test2(arg1.Swigcptr()) +} + +var _wrap_typedef_test3 unsafe.Pointer + +func _swig_wrap_typedef_test3(base uintptr) (_ SwigcptrA) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_typedef_test3, _swig_p) + return +} + +func Typedef_test3(arg1 Standard_Pair_Sl_Standard_Multimap_Sl_int_Sc_A_Sg__iterator_Sc_Standard_Multimap_Sl_int_Sc_A_Sg__iterator_Sg_) (_swig_ret A) { + return _swig_wrap_typedef_test3(arg1.Swigcptr()) +} + +var _wrap_typedef_test4 unsafe.Pointer + +func _swig_wrap_typedef_test4(base uintptr) (_ SwigcptrA) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_typedef_test4, _swig_p) + return +} + +func Typedef_test4(arg1 Standard_Pair_Sl_Standard_Multimap_Sl_int_Sc_A_Sg__iterator_Sc_Standard_Multimap_Sl_int_Sc_A_Sg__iterator_Sg_) (_swig_ret A) { + return _swig_wrap_typedef_test4(arg1.Swigcptr()) +} + +var _wrap_typedef_test5 unsafe.Pointer + +func _swig_wrap_typedef_test5(base uintptr) (_ SwigcptrA) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_typedef_test5, _swig_p) + return +} + +func Typedef_test5(arg1 Standard_Pair_Sl_Standard_Multimap_Sl_int_Sc_A_Sg__iterator_Sc_Standard_Multimap_Sl_int_Sc_A_Sg__iterator_Sg_) (_swig_ret A) { + return _swig_wrap_typedef_test5(arg1.Swigcptr()) +} + +var _wrap_typedef_test6 unsafe.Pointer + +func _swig_wrap_typedef_test6(base uintptr) (_ SwigcptrA) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_typedef_test6, _swig_p) + return +} + +func Typedef_test6(arg1 Standard_Pair_Sl_Standard_Multimap_Sl_int_Sc_A_Sg__iterator_Sc_Standard_Multimap_Sl_int_Sc_A_Sg__iterator_Sg_) (_swig_ret A) { + return _swig_wrap_typedef_test6(arg1.Swigcptr()) +} + + +type SwigcptrStandard_Pair_Sl_Standard_Multimap_Sl_int_Sc_A_Sg__iterator_Sc_Standard_Multimap_Sl_int_Sc_A_Sg__iterator_Sg_ uintptr +type Standard_Pair_Sl_Standard_Multimap_Sl_int_Sc_A_Sg__iterator_Sc_Standard_Multimap_Sl_int_Sc_A_Sg__iterator_Sg_ interface { + Swigcptr() uintptr; +} +func (p SwigcptrStandard_Pair_Sl_Standard_Multimap_Sl_int_Sc_A_Sg__iterator_Sc_Standard_Multimap_Sl_int_Sc_A_Sg__iterator_Sg_) Swigcptr() uintptr { + return uintptr(p) +} + +type SwigcptrStandard_Pair_Sl_Standard_Multimap_Sl_A_Sc_int_Sg__iterator_Sc_Standard_Multimap_Sl_A_Sc_int_Sg__iterator_Sg_ uintptr +type Standard_Pair_Sl_Standard_Multimap_Sl_A_Sc_int_Sg__iterator_Sc_Standard_Multimap_Sl_A_Sc_int_Sg__iterator_Sg_ interface { + Swigcptr() uintptr; +} +func (p SwigcptrStandard_Pair_Sl_Standard_Multimap_Sl_A_Sc_int_Sg__iterator_Sc_Standard_Multimap_Sl_A_Sc_int_Sg__iterator_Sg_) Swigcptr() uintptr { + return uintptr(p) +} + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/template_typemaps_typedef2.go b/Examples/test-suite/go/template_typemaps_typedef2.go new file mode 100644 index 000000000..20f60198c --- /dev/null +++ b/Examples/test-suite/go/template_typemaps_typedef2.go @@ -0,0 +1,520 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../template_typemaps_typedef2.i + +package template_typemaps_typedef2 + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrA uintptr + +func (p SwigcptrA) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrA) SwigIsA() { +} + +var _wrap_A_val_set unsafe.Pointer + +func _swig_wrap_A_val_set(base SwigcptrA, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_A_val_set, _swig_p) + return +} + +func (arg1 SwigcptrA) SetVal(arg2 int) { + _swig_wrap_A_val_set(arg1, arg2) +} + +var _wrap_A_val_get unsafe.Pointer + +func _swig_wrap_A_val_get(base SwigcptrA) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_A_val_get, _swig_p) + return +} + +func (arg1 SwigcptrA) GetVal() (_swig_ret int) { + return _swig_wrap_A_val_get(arg1) +} + +var _wrap_new_A__SWIG_0 unsafe.Pointer + +func _swig_wrap_new_A__SWIG_0(base int) (_ SwigcptrA) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_A__SWIG_0, _swig_p) + return +} + +func NewA__SWIG_0(arg1 int) (_swig_ret A) { + return _swig_wrap_new_A__SWIG_0(arg1) +} + +var _wrap_new_A__SWIG_1 unsafe.Pointer + +func _swig_wrap_new_A__SWIG_1() (base SwigcptrA) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_A__SWIG_1, _swig_p) + return +} + +func NewA__SWIG_1() (_swig_ret A) { + return _swig_wrap_new_A__SWIG_1() +} + +func NewA(a ...interface{}) A { + argc := len(a) + if argc == 0 { + return NewA__SWIG_1() + } + if argc == 1 { + return NewA__SWIG_0(a[0].(int)) + } + panic("No match for overloaded function call") +} + +var _wrap_delete_A unsafe.Pointer + +func _swig_wrap_delete_A(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_A, _swig_p) + return +} + +func DeleteA(arg1 A) { + _swig_wrap_delete_A(arg1.Swigcptr()) +} + +type A interface { + Swigcptr() uintptr + SwigIsA() + SetVal(arg2 int) + GetVal() (_swig_ret int) +} + +type SwigcptrPairIntA uintptr + +func (p SwigcptrPairIntA) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrPairIntA) SwigIsPairIntA() { +} + +var _wrap_PairIntA_first_set unsafe.Pointer + +func _swig_wrap_PairIntA_first_set(base SwigcptrPairIntA, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_PairIntA_first_set, _swig_p) + return +} + +func (arg1 SwigcptrPairIntA) SetFirst(arg2 int) { + _swig_wrap_PairIntA_first_set(arg1, arg2) +} + +var _wrap_PairIntA_first_get unsafe.Pointer + +func _swig_wrap_PairIntA_first_get(base SwigcptrPairIntA) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_PairIntA_first_get, _swig_p) + return +} + +func (arg1 SwigcptrPairIntA) GetFirst() (_swig_ret int) { + return _swig_wrap_PairIntA_first_get(arg1) +} + +var _wrap_PairIntA_second_set unsafe.Pointer + +func _swig_wrap_PairIntA_second_set(base SwigcptrPairIntA, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_PairIntA_second_set, _swig_p) + return +} + +func (arg1 SwigcptrPairIntA) SetSecond(arg2 A) { + _swig_wrap_PairIntA_second_set(arg1, arg2.Swigcptr()) +} + +var _wrap_PairIntA_second_get unsafe.Pointer + +func _swig_wrap_PairIntA_second_get(base SwigcptrPairIntA) (_ SwigcptrA) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_PairIntA_second_get, _swig_p) + return +} + +func (arg1 SwigcptrPairIntA) GetSecond() (_swig_ret A) { + return _swig_wrap_PairIntA_second_get(arg1) +} + +var _wrap_new_PairIntA unsafe.Pointer + +func _swig_wrap_new_PairIntA() (base SwigcptrPairIntA) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_PairIntA, _swig_p) + return +} + +func NewPairIntA() (_swig_ret PairIntA) { + return _swig_wrap_new_PairIntA() +} + +var _wrap_delete_PairIntA unsafe.Pointer + +func _swig_wrap_delete_PairIntA(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_PairIntA, _swig_p) + return +} + +func DeletePairIntA(arg1 PairIntA) { + _swig_wrap_delete_PairIntA(arg1.Swigcptr()) +} + +type PairIntA interface { + Swigcptr() uintptr + SwigIsPairIntA() + SetFirst(arg2 int) + GetFirst() (_swig_ret int) + SetSecond(arg2 A) + GetSecond() (_swig_ret A) +} + +type SwigcptrMultimapIntA uintptr + +func (p SwigcptrMultimapIntA) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrMultimapIntA) SwigIsMultimapIntA() { +} + +var _wrap_MultimapIntA_typemap_test unsafe.Pointer + +func _swig_wrap_MultimapIntA_typemap_test(base SwigcptrMultimapIntA, _ uintptr) (_ SwigcptrA) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_MultimapIntA_typemap_test, _swig_p) + return +} + +func (arg1 SwigcptrMultimapIntA) Typemap_test(arg2 Standard_Pair_Sl_Standard_Multimap_Sl_int_Sc_Space_AB_Sg__iterator_Sc_Standard_Multimap_Sl_int_Sc_Space_AB_Sg__iterator_Sg_) (_swig_ret A) { + return _swig_wrap_MultimapIntA_typemap_test(arg1, arg2.Swigcptr()) +} + +var _wrap_MultimapIntA_make_dummy_pair unsafe.Pointer + +func _swig_wrap_MultimapIntA_make_dummy_pair(base SwigcptrMultimapIntA) (_ SwigcptrStandard_Pair_Sl_Standard_Multimap_Sl_int_Sc_Space_AB_Sg__iterator_Sc_Standard_Multimap_Sl_int_Sc_Space_AB_Sg__iterator_Sg_) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_MultimapIntA_make_dummy_pair, _swig_p) + return +} + +func (arg1 SwigcptrMultimapIntA) Make_dummy_pair() (_swig_ret Standard_Pair_Sl_Standard_Multimap_Sl_int_Sc_Space_AB_Sg__iterator_Sc_Standard_Multimap_Sl_int_Sc_Space_AB_Sg__iterator_Sg_) { + return _swig_wrap_MultimapIntA_make_dummy_pair(arg1) +} + +var _wrap_new_MultimapIntA unsafe.Pointer + +func _swig_wrap_new_MultimapIntA() (base SwigcptrMultimapIntA) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_MultimapIntA, _swig_p) + return +} + +func NewMultimapIntA() (_swig_ret MultimapIntA) { + return _swig_wrap_new_MultimapIntA() +} + +var _wrap_delete_MultimapIntA unsafe.Pointer + +func _swig_wrap_delete_MultimapIntA(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_MultimapIntA, _swig_p) + return +} + +func DeleteMultimapIntA(arg1 MultimapIntA) { + _swig_wrap_delete_MultimapIntA(arg1.Swigcptr()) +} + +type MultimapIntA interface { + Swigcptr() uintptr + SwigIsMultimapIntA() + Typemap_test(arg2 Standard_Pair_Sl_Standard_Multimap_Sl_int_Sc_Space_AB_Sg__iterator_Sc_Standard_Multimap_Sl_int_Sc_Space_AB_Sg__iterator_Sg_) (_swig_ret A) + Make_dummy_pair() (_swig_ret Standard_Pair_Sl_Standard_Multimap_Sl_int_Sc_Space_AB_Sg__iterator_Sc_Standard_Multimap_Sl_int_Sc_Space_AB_Sg__iterator_Sg_) +} + +type SwigcptrPairAInt uintptr + +func (p SwigcptrPairAInt) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrPairAInt) SwigIsPairAInt() { +} + +var _wrap_PairAInt_first_set unsafe.Pointer + +func _swig_wrap_PairAInt_first_set(base SwigcptrPairAInt, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_PairAInt_first_set, _swig_p) + return +} + +func (arg1 SwigcptrPairAInt) SetFirst(arg2 A) { + _swig_wrap_PairAInt_first_set(arg1, arg2.Swigcptr()) +} + +var _wrap_PairAInt_first_get unsafe.Pointer + +func _swig_wrap_PairAInt_first_get(base SwigcptrPairAInt) (_ SwigcptrA) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_PairAInt_first_get, _swig_p) + return +} + +func (arg1 SwigcptrPairAInt) GetFirst() (_swig_ret A) { + return _swig_wrap_PairAInt_first_get(arg1) +} + +var _wrap_PairAInt_second_set unsafe.Pointer + +func _swig_wrap_PairAInt_second_set(base SwigcptrPairAInt, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_PairAInt_second_set, _swig_p) + return +} + +func (arg1 SwigcptrPairAInt) SetSecond(arg2 int) { + _swig_wrap_PairAInt_second_set(arg1, arg2) +} + +var _wrap_PairAInt_second_get unsafe.Pointer + +func _swig_wrap_PairAInt_second_get(base SwigcptrPairAInt) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_PairAInt_second_get, _swig_p) + return +} + +func (arg1 SwigcptrPairAInt) GetSecond() (_swig_ret int) { + return _swig_wrap_PairAInt_second_get(arg1) +} + +var _wrap_new_PairAInt unsafe.Pointer + +func _swig_wrap_new_PairAInt() (base SwigcptrPairAInt) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_PairAInt, _swig_p) + return +} + +func NewPairAInt() (_swig_ret PairAInt) { + return _swig_wrap_new_PairAInt() +} + +var _wrap_delete_PairAInt unsafe.Pointer + +func _swig_wrap_delete_PairAInt(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_PairAInt, _swig_p) + return +} + +func DeletePairAInt(arg1 PairAInt) { + _swig_wrap_delete_PairAInt(arg1.Swigcptr()) +} + +type PairAInt interface { + Swigcptr() uintptr + SwigIsPairAInt() + SetFirst(arg2 A) + GetFirst() (_swig_ret A) + SetSecond(arg2 int) + GetSecond() (_swig_ret int) +} + +type SwigcptrMultimapAInt uintptr + +func (p SwigcptrMultimapAInt) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrMultimapAInt) SwigIsMultimapAInt() { +} + +var _wrap_MultimapAInt_typemap_test unsafe.Pointer + +func _swig_wrap_MultimapAInt_typemap_test(base SwigcptrMultimapAInt, _ uintptr) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_MultimapAInt_typemap_test, _swig_p) + return +} + +func (arg1 SwigcptrMultimapAInt) Typemap_test(arg2 Standard_Pair_Sl_Standard_Multimap_Sl_Space_AB_Sc_int_Sg__iterator_Sc_Standard_Multimap_Sl_Space_AB_Sc_int_Sg__iterator_Sg_) (_swig_ret int) { + return _swig_wrap_MultimapAInt_typemap_test(arg1, arg2.Swigcptr()) +} + +var _wrap_MultimapAInt_make_dummy_pair unsafe.Pointer + +func _swig_wrap_MultimapAInt_make_dummy_pair(base SwigcptrMultimapAInt) (_ SwigcptrStandard_Pair_Sl_Standard_Multimap_Sl_Space_AB_Sc_int_Sg__iterator_Sc_Standard_Multimap_Sl_Space_AB_Sc_int_Sg__iterator_Sg_) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_MultimapAInt_make_dummy_pair, _swig_p) + return +} + +func (arg1 SwigcptrMultimapAInt) Make_dummy_pair() (_swig_ret Standard_Pair_Sl_Standard_Multimap_Sl_Space_AB_Sc_int_Sg__iterator_Sc_Standard_Multimap_Sl_Space_AB_Sc_int_Sg__iterator_Sg_) { + return _swig_wrap_MultimapAInt_make_dummy_pair(arg1) +} + +var _wrap_new_MultimapAInt unsafe.Pointer + +func _swig_wrap_new_MultimapAInt() (base SwigcptrMultimapAInt) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_MultimapAInt, _swig_p) + return +} + +func NewMultimapAInt() (_swig_ret MultimapAInt) { + return _swig_wrap_new_MultimapAInt() +} + +var _wrap_delete_MultimapAInt unsafe.Pointer + +func _swig_wrap_delete_MultimapAInt(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_MultimapAInt, _swig_p) + return +} + +func DeleteMultimapAInt(arg1 MultimapAInt) { + _swig_wrap_delete_MultimapAInt(arg1.Swigcptr()) +} + +type MultimapAInt interface { + Swigcptr() uintptr + SwigIsMultimapAInt() + Typemap_test(arg2 Standard_Pair_Sl_Standard_Multimap_Sl_Space_AB_Sc_int_Sg__iterator_Sc_Standard_Multimap_Sl_Space_AB_Sc_int_Sg__iterator_Sg_) (_swig_ret int) + Make_dummy_pair() (_swig_ret Standard_Pair_Sl_Standard_Multimap_Sl_Space_AB_Sc_int_Sg__iterator_Sc_Standard_Multimap_Sl_Space_AB_Sc_int_Sg__iterator_Sg_) +} + +var _wrap_typedef_test1 unsafe.Pointer + +func _swig_wrap_typedef_test1(base uintptr) (_ SwigcptrA) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_typedef_test1, _swig_p) + return +} + +func Typedef_test1(arg1 Standard_Pair_Sl_Standard_Multimap_Sl_int_Sc_Space_AB_Sg__iterator_Sc_Standard_Multimap_Sl_int_Sc_Space_AB_Sg__iterator_Sg_) (_swig_ret A) { + return _swig_wrap_typedef_test1(arg1.Swigcptr()) +} + +var _wrap_typedef_test2 unsafe.Pointer + +func _swig_wrap_typedef_test2(base uintptr) (_ SwigcptrA) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_typedef_test2, _swig_p) + return +} + +func Typedef_test2(arg1 Standard_Pair_Sl_Standard_Multimap_Sl_int_Sc_Space_AB_Sg__iterator_Sc_Standard_Multimap_Sl_int_Sc_Space_AB_Sg__iterator_Sg_) (_swig_ret A) { + return _swig_wrap_typedef_test2(arg1.Swigcptr()) +} + +var _wrap_typedef_test3 unsafe.Pointer + +func _swig_wrap_typedef_test3(base uintptr) (_ SwigcptrA) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_typedef_test3, _swig_p) + return +} + +func Typedef_test3(arg1 Standard_Pair_Sl_Standard_Multimap_Sl_int_Sc_Space_AB_Sg__iterator_Sc_Standard_Multimap_Sl_int_Sc_Space_AB_Sg__iterator_Sg_) (_swig_ret A) { + return _swig_wrap_typedef_test3(arg1.Swigcptr()) +} + +var _wrap_typedef_test4 unsafe.Pointer + +func _swig_wrap_typedef_test4(base uintptr) (_ SwigcptrA) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_typedef_test4, _swig_p) + return +} + +func Typedef_test4(arg1 Standard_Pair_Sl_Standard_Multimap_Sl_int_Sc_Space_AB_Sg__iterator_Sc_Standard_Multimap_Sl_int_Sc_Space_AB_Sg__iterator_Sg_) (_swig_ret A) { + return _swig_wrap_typedef_test4(arg1.Swigcptr()) +} + +var _wrap_typedef_test5 unsafe.Pointer + +func _swig_wrap_typedef_test5(base uintptr) (_ SwigcptrA) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_typedef_test5, _swig_p) + return +} + +func Typedef_test5(arg1 Standard_Pair_Sl_Standard_Multimap_Sl_int_Sc_Space_AB_Sg__iterator_Sc_Standard_Multimap_Sl_int_Sc_Space_AB_Sg__iterator_Sg_) (_swig_ret A) { + return _swig_wrap_typedef_test5(arg1.Swigcptr()) +} + +var _wrap_typedef_test6 unsafe.Pointer + +func _swig_wrap_typedef_test6(base uintptr) (_ SwigcptrA) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_typedef_test6, _swig_p) + return +} + +func Typedef_test6(arg1 Standard_Pair_Sl_Standard_Multimap_Sl_int_Sc_Space_AB_Sg__iterator_Sc_Standard_Multimap_Sl_int_Sc_Space_AB_Sg__iterator_Sg_) (_swig_ret A) { + return _swig_wrap_typedef_test6(arg1.Swigcptr()) +} + + +type SwigcptrStandard_Pair_Sl_Standard_Multimap_Sl_int_Sc_Space_AB_Sg__iterator_Sc_Standard_Multimap_Sl_int_Sc_Space_AB_Sg__iterator_Sg_ uintptr +type Standard_Pair_Sl_Standard_Multimap_Sl_int_Sc_Space_AB_Sg__iterator_Sc_Standard_Multimap_Sl_int_Sc_Space_AB_Sg__iterator_Sg_ interface { + Swigcptr() uintptr; +} +func (p SwigcptrStandard_Pair_Sl_Standard_Multimap_Sl_int_Sc_Space_AB_Sg__iterator_Sc_Standard_Multimap_Sl_int_Sc_Space_AB_Sg__iterator_Sg_) Swigcptr() uintptr { + return uintptr(p) +} + +type SwigcptrStandard_Pair_Sl_Standard_Multimap_Sl_Space_AB_Sc_int_Sg__iterator_Sc_Standard_Multimap_Sl_Space_AB_Sc_int_Sg__iterator_Sg_ uintptr +type Standard_Pair_Sl_Standard_Multimap_Sl_Space_AB_Sc_int_Sg__iterator_Sc_Standard_Multimap_Sl_Space_AB_Sc_int_Sg__iterator_Sg_ interface { + Swigcptr() uintptr; +} +func (p SwigcptrStandard_Pair_Sl_Standard_Multimap_Sl_Space_AB_Sc_int_Sg__iterator_Sc_Standard_Multimap_Sl_Space_AB_Sc_int_Sg__iterator_Sg_) Swigcptr() uintptr { + return uintptr(p) +} + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/template_using.go b/Examples/test-suite/go/template_using.go new file mode 100644 index 000000000..053ab6900 --- /dev/null +++ b/Examples/test-suite/go/template_using.go @@ -0,0 +1,89 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../template_using.i + +package template_using + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +var _wrap_maxint unsafe.Pointer + +func Maxint(arg1 int, arg2 int) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_maxint, _swig_p) + return +} +type SwigcptrFoofloat uintptr + +func (p SwigcptrFoofloat) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrFoofloat) SwigIsFoofloat() { +} + +var _wrap_new_Foofloat unsafe.Pointer + +func _swig_wrap_new_Foofloat() (base SwigcptrFoofloat) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Foofloat, _swig_p) + return +} + +func NewFoofloat() (_swig_ret Foofloat) { + return _swig_wrap_new_Foofloat() +} + +var _wrap_delete_Foofloat unsafe.Pointer + +func _swig_wrap_delete_Foofloat(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Foofloat, _swig_p) + return +} + +func DeleteFoofloat(arg1 Foofloat) { + _swig_wrap_delete_Foofloat(arg1.Swigcptr()) +} + +type Foofloat interface { + Swigcptr() uintptr + SwigIsFoofloat() +} + +var _wrap_maxfloat unsafe.Pointer + +func Maxfloat(arg1 float32, arg2 float32) (_swig_ret float32) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_maxfloat, _swig_p) + return +} + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/template_using_directive_and_declaration_forward.go b/Examples/test-suite/go/template_using_directive_and_declaration_forward.go new file mode 100644 index 000000000..aab450d14 --- /dev/null +++ b/Examples/test-suite/go/template_using_directive_and_declaration_forward.go @@ -0,0 +1,653 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../template_using_directive_and_declaration_forward.i + +package template_using_directive_and_declaration_forward + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +var _wrap_useit1 unsafe.Pointer + +func _swig_wrap_useit1(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_useit1, _swig_p) + return +} + +func Useit1(arg1 Thing1Int) { + _swig_wrap_useit1(arg1.Swigcptr()) +} + +var _wrap_useit1a unsafe.Pointer + +func _swig_wrap_useit1a(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_useit1a, _swig_p) + return +} + +func Useit1a(arg1 Thing1Int) { + _swig_wrap_useit1a(arg1.Swigcptr()) +} + +var _wrap_useit1b unsafe.Pointer + +func _swig_wrap_useit1b(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_useit1b, _swig_p) + return +} + +func Useit1b(arg1 Thing1Int) { + _swig_wrap_useit1b(arg1.Swigcptr()) +} + +var _wrap_useit1c unsafe.Pointer + +func _swig_wrap_useit1c(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_useit1c, _swig_p) + return +} + +func Useit1c(arg1 Thing1Int) { + _swig_wrap_useit1c(arg1.Swigcptr()) +} + +var _wrap_useit2 unsafe.Pointer + +func _swig_wrap_useit2(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_useit2, _swig_p) + return +} + +func Useit2(arg1 Outer2_Space2_Thing2_Sl_int_Sg_) { + _swig_wrap_useit2(arg1.Swigcptr()) +} + +var _wrap_useit2a unsafe.Pointer + +func _swig_wrap_useit2a(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_useit2a, _swig_p) + return +} + +func Useit2a(arg1 Thing2Int) { + _swig_wrap_useit2a(arg1.Swigcptr()) +} + +var _wrap_useit2b unsafe.Pointer + +func _swig_wrap_useit2b(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_useit2b, _swig_p) + return +} + +func Useit2b(arg1 Thing2Int) { + _swig_wrap_useit2b(arg1.Swigcptr()) +} + +var _wrap_useit2c unsafe.Pointer + +func _swig_wrap_useit2c(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_useit2c, _swig_p) + return +} + +func Useit2c(arg1 Thing2Int) { + _swig_wrap_useit2c(arg1.Swigcptr()) +} + +var _wrap_useit2d unsafe.Pointer + +func _swig_wrap_useit2d(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_useit2d, _swig_p) + return +} + +func Useit2d(arg1 Thing2Int) { + _swig_wrap_useit2d(arg1.Swigcptr()) +} + +var _wrap_useit3 unsafe.Pointer + +func _swig_wrap_useit3(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_useit3, _swig_p) + return +} + +func Useit3(arg1 Outer3_Space3_Middle3_Thing3_Sl_int_Sg_) { + _swig_wrap_useit3(arg1.Swigcptr()) +} + +var _wrap_useit3a unsafe.Pointer + +func _swig_wrap_useit3a(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_useit3a, _swig_p) + return +} + +func Useit3a(arg1 Thing3Int) { + _swig_wrap_useit3a(arg1.Swigcptr()) +} + +var _wrap_useit3b unsafe.Pointer + +func _swig_wrap_useit3b(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_useit3b, _swig_p) + return +} + +func Useit3b(arg1 Thing3Int) { + _swig_wrap_useit3b(arg1.Swigcptr()) +} + +var _wrap_useit3c unsafe.Pointer + +func _swig_wrap_useit3c(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_useit3c, _swig_p) + return +} + +func Useit3c(arg1 Thing3Int) { + _swig_wrap_useit3c(arg1.Swigcptr()) +} + +var _wrap_useit3d unsafe.Pointer + +func _swig_wrap_useit3d(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_useit3d, _swig_p) + return +} + +func Useit3d(arg1 Thing3Int) { + _swig_wrap_useit3d(arg1.Swigcptr()) +} + +var _wrap_useit4 unsafe.Pointer + +func _swig_wrap_useit4(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_useit4, _swig_p) + return +} + +func Useit4(arg1 Outer4_Space4_Middle4_Thing4_Sl_int_Sg_) { + _swig_wrap_useit4(arg1.Swigcptr()) +} + +var _wrap_useit4a unsafe.Pointer + +func _swig_wrap_useit4a(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_useit4a, _swig_p) + return +} + +func Useit4a(arg1 Thing4Int) { + _swig_wrap_useit4a(arg1.Swigcptr()) +} + +var _wrap_useit4b unsafe.Pointer + +func _swig_wrap_useit4b(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_useit4b, _swig_p) + return +} + +func Useit4b(arg1 Thing4Int) { + _swig_wrap_useit4b(arg1.Swigcptr()) +} + +var _wrap_useit4c unsafe.Pointer + +func _swig_wrap_useit4c(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_useit4c, _swig_p) + return +} + +func Useit4c(arg1 Thing4Int) { + _swig_wrap_useit4c(arg1.Swigcptr()) +} + +var _wrap_useit4d unsafe.Pointer + +func _swig_wrap_useit4d(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_useit4d, _swig_p) + return +} + +func Useit4d(arg1 Thing4Int) { + _swig_wrap_useit4d(arg1.Swigcptr()) +} + +var _wrap_useit5 unsafe.Pointer + +func _swig_wrap_useit5(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_useit5, _swig_p) + return +} + +func Useit5(arg1 Outer5_Space5_Middle5_More5_Thing5_Sl_int_Sg_) { + _swig_wrap_useit5(arg1.Swigcptr()) +} + +var _wrap_useit5a unsafe.Pointer + +func _swig_wrap_useit5a(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_useit5a, _swig_p) + return +} + +func Useit5a(arg1 Thing5Int) { + _swig_wrap_useit5a(arg1.Swigcptr()) +} + +var _wrap_useit5b unsafe.Pointer + +func _swig_wrap_useit5b(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_useit5b, _swig_p) + return +} + +func Useit5b(arg1 Thing5Int) { + _swig_wrap_useit5b(arg1.Swigcptr()) +} + +var _wrap_useit5c unsafe.Pointer + +func _swig_wrap_useit5c(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_useit5c, _swig_p) + return +} + +func Useit5c(arg1 Thing5Int) { + _swig_wrap_useit5c(arg1.Swigcptr()) +} + +var _wrap_useit5d unsafe.Pointer + +func _swig_wrap_useit5d(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_useit5d, _swig_p) + return +} + +func Useit5d(arg1 Thing5Int) { + _swig_wrap_useit5d(arg1.Swigcptr()) +} + +var _wrap_useit7 unsafe.Pointer + +func _swig_wrap_useit7(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_useit7, _swig_p) + return +} + +func Useit7(arg1 Outer7_Space7_Middle7_Thing7_Sl_int_Sg_) { + _swig_wrap_useit7(arg1.Swigcptr()) +} + +var _wrap_useit7a unsafe.Pointer + +func _swig_wrap_useit7a(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_useit7a, _swig_p) + return +} + +func Useit7a(arg1 Thing7Int) { + _swig_wrap_useit7a(arg1.Swigcptr()) +} + +var _wrap_useit7b unsafe.Pointer + +func _swig_wrap_useit7b(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_useit7b, _swig_p) + return +} + +func Useit7b(arg1 Thing7Int) { + _swig_wrap_useit7b(arg1.Swigcptr()) +} + +var _wrap_useit7c unsafe.Pointer + +func _swig_wrap_useit7c(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_useit7c, _swig_p) + return +} + +func Useit7c(arg1 Thing7Int) { + _swig_wrap_useit7c(arg1.Swigcptr()) +} + +var _wrap_useit7d unsafe.Pointer + +func _swig_wrap_useit7d(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_useit7d, _swig_p) + return +} + +func Useit7d(arg1 Thing7Int) { + _swig_wrap_useit7d(arg1.Swigcptr()) +} + +type SwigcptrThing1Int uintptr + +func (p SwigcptrThing1Int) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrThing1Int) SwigIsThing1Int() { +} + +var _wrap_new_Thing1Int unsafe.Pointer + +func _swig_wrap_new_Thing1Int() (base SwigcptrThing1Int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Thing1Int, _swig_p) + return +} + +func NewThing1Int() (_swig_ret Thing1Int) { + return _swig_wrap_new_Thing1Int() +} + +var _wrap_delete_Thing1Int unsafe.Pointer + +func _swig_wrap_delete_Thing1Int(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Thing1Int, _swig_p) + return +} + +func DeleteThing1Int(arg1 Thing1Int) { + _swig_wrap_delete_Thing1Int(arg1.Swigcptr()) +} + +type Thing1Int interface { + Swigcptr() uintptr + SwigIsThing1Int() +} + +type SwigcptrThing2Int uintptr + +func (p SwigcptrThing2Int) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrThing2Int) SwigIsThing2Int() { +} + +var _wrap_new_Thing2Int unsafe.Pointer + +func _swig_wrap_new_Thing2Int() (base SwigcptrThing2Int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Thing2Int, _swig_p) + return +} + +func NewThing2Int() (_swig_ret Thing2Int) { + return _swig_wrap_new_Thing2Int() +} + +var _wrap_delete_Thing2Int unsafe.Pointer + +func _swig_wrap_delete_Thing2Int(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Thing2Int, _swig_p) + return +} + +func DeleteThing2Int(arg1 Thing2Int) { + _swig_wrap_delete_Thing2Int(arg1.Swigcptr()) +} + +type Thing2Int interface { + Swigcptr() uintptr + SwigIsThing2Int() +} + +type SwigcptrThing3Int uintptr + +func (p SwigcptrThing3Int) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrThing3Int) SwigIsThing3Int() { +} + +var _wrap_new_Thing3Int unsafe.Pointer + +func _swig_wrap_new_Thing3Int() (base SwigcptrThing3Int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Thing3Int, _swig_p) + return +} + +func NewThing3Int() (_swig_ret Thing3Int) { + return _swig_wrap_new_Thing3Int() +} + +var _wrap_delete_Thing3Int unsafe.Pointer + +func _swig_wrap_delete_Thing3Int(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Thing3Int, _swig_p) + return +} + +func DeleteThing3Int(arg1 Thing3Int) { + _swig_wrap_delete_Thing3Int(arg1.Swigcptr()) +} + +type Thing3Int interface { + Swigcptr() uintptr + SwigIsThing3Int() +} + +type SwigcptrThing4Int uintptr + +func (p SwigcptrThing4Int) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrThing4Int) SwigIsThing4Int() { +} + +var _wrap_new_Thing4Int unsafe.Pointer + +func _swig_wrap_new_Thing4Int() (base SwigcptrThing4Int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Thing4Int, _swig_p) + return +} + +func NewThing4Int() (_swig_ret Thing4Int) { + return _swig_wrap_new_Thing4Int() +} + +var _wrap_delete_Thing4Int unsafe.Pointer + +func _swig_wrap_delete_Thing4Int(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Thing4Int, _swig_p) + return +} + +func DeleteThing4Int(arg1 Thing4Int) { + _swig_wrap_delete_Thing4Int(arg1.Swigcptr()) +} + +type Thing4Int interface { + Swigcptr() uintptr + SwigIsThing4Int() +} + +type SwigcptrThing5Int uintptr + +func (p SwigcptrThing5Int) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrThing5Int) SwigIsThing5Int() { +} + +var _wrap_new_Thing5Int unsafe.Pointer + +func _swig_wrap_new_Thing5Int() (base SwigcptrThing5Int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Thing5Int, _swig_p) + return +} + +func NewThing5Int() (_swig_ret Thing5Int) { + return _swig_wrap_new_Thing5Int() +} + +var _wrap_delete_Thing5Int unsafe.Pointer + +func _swig_wrap_delete_Thing5Int(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Thing5Int, _swig_p) + return +} + +func DeleteThing5Int(arg1 Thing5Int) { + _swig_wrap_delete_Thing5Int(arg1.Swigcptr()) +} + +type Thing5Int interface { + Swigcptr() uintptr + SwigIsThing5Int() +} + +type SwigcptrThing7Int uintptr + +func (p SwigcptrThing7Int) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrThing7Int) SwigIsThing7Int() { +} + +var _wrap_new_Thing7Int unsafe.Pointer + +func _swig_wrap_new_Thing7Int() (base SwigcptrThing7Int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Thing7Int, _swig_p) + return +} + +func NewThing7Int() (_swig_ret Thing7Int) { + return _swig_wrap_new_Thing7Int() +} + +var _wrap_delete_Thing7Int unsafe.Pointer + +func _swig_wrap_delete_Thing7Int(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Thing7Int, _swig_p) + return +} + +func DeleteThing7Int(arg1 Thing7Int) { + _swig_wrap_delete_Thing7Int(arg1.Swigcptr()) +} + +type Thing7Int interface { + Swigcptr() uintptr + SwigIsThing7Int() +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + +type SwigcptrOuter5_Space5_Middle5_More5_Thing5_Sl_int_Sg_ uintptr +type Outer5_Space5_Middle5_More5_Thing5_Sl_int_Sg_ interface { + Swigcptr() uintptr; +} +func (p SwigcptrOuter5_Space5_Middle5_More5_Thing5_Sl_int_Sg_) Swigcptr() uintptr { + return uintptr(p) +} + +type SwigcptrOuter4_Space4_Middle4_Thing4_Sl_int_Sg_ uintptr +type Outer4_Space4_Middle4_Thing4_Sl_int_Sg_ interface { + Swigcptr() uintptr; +} +func (p SwigcptrOuter4_Space4_Middle4_Thing4_Sl_int_Sg_) Swigcptr() uintptr { + return uintptr(p) +} + +type SwigcptrOuter3_Space3_Middle3_Thing3_Sl_int_Sg_ uintptr +type Outer3_Space3_Middle3_Thing3_Sl_int_Sg_ interface { + Swigcptr() uintptr; +} +func (p SwigcptrOuter3_Space3_Middle3_Thing3_Sl_int_Sg_) Swigcptr() uintptr { + return uintptr(p) +} + +type SwigcptrOuter2_Space2_Thing2_Sl_int_Sg_ uintptr +type Outer2_Space2_Thing2_Sl_int_Sg_ interface { + Swigcptr() uintptr; +} +func (p SwigcptrOuter2_Space2_Thing2_Sl_int_Sg_) Swigcptr() uintptr { + return uintptr(p) +} + +type SwigcptrOuter7_Space7_Middle7_Thing7_Sl_int_Sg_ uintptr +type Outer7_Space7_Middle7_Thing7_Sl_int_Sg_ interface { + Swigcptr() uintptr; +} +func (p SwigcptrOuter7_Space7_Middle7_Thing7_Sl_int_Sg_) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/template_virtual.go b/Examples/test-suite/go/template_virtual.go new file mode 100644 index 000000000..02dc94f77 --- /dev/null +++ b/Examples/test-suite/go/template_virtual.go @@ -0,0 +1,150 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../template_virtual.i + +package template_virtual + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrA_int uintptr + +func (p SwigcptrA_int) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrA_int) SwigIsA_int() { +} + +var _wrap_delete_A_int unsafe.Pointer + +func _swig_wrap_delete_A_int(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_A_int, _swig_p) + return +} + +func DeleteA_int(arg1 A_int) { + _swig_wrap_delete_A_int(arg1.Swigcptr()) +} + +var _wrap_A_int_say_hi unsafe.Pointer + +func _swig_wrap_A_int_say_hi(base SwigcptrA_int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_A_int_say_hi, _swig_p) + return +} + +func (arg1 SwigcptrA_int) Say_hi() { + _swig_wrap_A_int_say_hi(arg1) +} + +var _wrap_A_int_say_hello unsafe.Pointer + +func _swig_wrap_A_int_say_hello(base SwigcptrA_int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_A_int_say_hello, _swig_p) + return +} + +func (arg1 SwigcptrA_int) Say_hello() { + _swig_wrap_A_int_say_hello(arg1) +} + +type A_int interface { + Swigcptr() uintptr + SwigIsA_int() + Say_hi() + Say_hello() +} + +type SwigcptrB_int uintptr + +func (p SwigcptrB_int) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrB_int) SwigIsB_int() { +} + +var _wrap_delete_B_int unsafe.Pointer + +func _swig_wrap_delete_B_int(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_B_int, _swig_p) + return +} + +func DeleteB_int(arg1 B_int) { + _swig_wrap_delete_B_int(arg1.Swigcptr()) +} + +var _wrap_B_int_say_hi unsafe.Pointer + +func _swig_wrap_B_int_say_hi(base SwigcptrB_int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_B_int_say_hi, _swig_p) + return +} + +func (_swig_base SwigcptrB_int) Say_hi() { + _swig_wrap_B_int_say_hi(_swig_base) +} + +var _wrap_B_int_say_hello unsafe.Pointer + +func _swig_wrap_B_int_say_hello(base SwigcptrB_int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_B_int_say_hello, _swig_p) + return +} + +func (_swig_base SwigcptrB_int) Say_hello() { + _swig_wrap_B_int_say_hello(_swig_base) +} + +func (p SwigcptrB_int) SwigIsA_int() { +} + +func (p SwigcptrB_int) SwigGetA_int() A_int { + return SwigcptrA_int(p.Swigcptr()) +} + +type B_int interface { + Swigcptr() uintptr + SwigIsB_int() + Say_hi() + Say_hello() + SwigIsA_int() + SwigGetA_int() A_int +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/template_whitespace.go b/Examples/test-suite/go/template_whitespace.go new file mode 100644 index 000000000..b8d486e82 --- /dev/null +++ b/Examples/test-suite/go/template_whitespace.go @@ -0,0 +1,97 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../template_whitespace.i + +package template_whitespace + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +var _wrap_foo unsafe.Pointer + +func _swig_wrap_foo(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_foo, _swig_p) + return +} + +func Foo(arg1 Vector_Sl_int_Sg_) { + _swig_wrap_foo(arg1.Swigcptr()) +} + +var _wrap_bar unsafe.Pointer + +func _swig_wrap_bar(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_bar, _swig_p) + return +} + +func Bar(arg1 Vector_Sl_unsigned_SS_int_Sg_) { + _swig_wrap_bar(arg1.Swigcptr()) +} + +var _wrap_baz unsafe.Pointer + +func _swig_wrap_baz(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_baz, _swig_p) + return +} + +func Baz(arg1 Map_Sl_int_Sc_int_Sg_) { + _swig_wrap_baz(arg1.Swigcptr()) +} + + +type SwigcptrVector_Sl_unsigned_SS_int_Sg_ uintptr +type Vector_Sl_unsigned_SS_int_Sg_ interface { + Swigcptr() uintptr; +} +func (p SwigcptrVector_Sl_unsigned_SS_int_Sg_) Swigcptr() uintptr { + return uintptr(p) +} + +type SwigcptrVector_Sl_int_Sg_ uintptr +type Vector_Sl_int_Sg_ interface { + Swigcptr() uintptr; +} +func (p SwigcptrVector_Sl_int_Sg_) Swigcptr() uintptr { + return uintptr(p) +} + +type SwigcptrMap_Sl_int_Sc_int_Sg_ uintptr +type Map_Sl_int_Sc_int_Sg_ interface { + Swigcptr() uintptr; +} +func (p SwigcptrMap_Sl_int_Sc_int_Sg_) Swigcptr() uintptr { + return uintptr(p) +} + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/threads.go b/Examples/test-suite/go/threads.go new file mode 100644 index 000000000..4770bd401 --- /dev/null +++ b/Examples/test-suite/go/threads.go @@ -0,0 +1,101 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../threads.i + +package threads + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrKerfuffle uintptr + +func (p SwigcptrKerfuffle) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrKerfuffle) SwigIsKerfuffle() { +} + +var _wrap_Kerfuffle_StdString unsafe.Pointer + +func _swig_wrap_Kerfuffle_StdString(base SwigcptrKerfuffle, _ string) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Kerfuffle_StdString, _swig_p) + return +} + +func (arg1 SwigcptrKerfuffle) StdString(arg2 string) (_swig_ret string) { + return _swig_wrap_Kerfuffle_StdString(arg1, arg2) +} + +var _wrap_Kerfuffle_CharString unsafe.Pointer + +func _swig_wrap_Kerfuffle_CharString(base SwigcptrKerfuffle, _ string) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Kerfuffle_CharString, _swig_p) + return +} + +func (arg1 SwigcptrKerfuffle) CharString(arg2 string) (_swig_ret string) { + return _swig_wrap_Kerfuffle_CharString(arg1, arg2) +} + +var _wrap_new_Kerfuffle unsafe.Pointer + +func _swig_wrap_new_Kerfuffle() (base SwigcptrKerfuffle) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Kerfuffle, _swig_p) + return +} + +func NewKerfuffle() (_swig_ret Kerfuffle) { + return _swig_wrap_new_Kerfuffle() +} + +var _wrap_delete_Kerfuffle unsafe.Pointer + +func _swig_wrap_delete_Kerfuffle(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Kerfuffle, _swig_p) + return +} + +func DeleteKerfuffle(arg1 Kerfuffle) { + _swig_wrap_delete_Kerfuffle(arg1.Swigcptr()) +} + +type Kerfuffle interface { + Swigcptr() uintptr + SwigIsKerfuffle() + StdString(arg2 string) (_swig_ret string) + CharString(arg2 string) (_swig_ret string) +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/threads_exception.go b/Examples/test-suite/go/threads_exception.go new file mode 100644 index 000000000..6fb40deea --- /dev/null +++ b/Examples/test-suite/go/threads_exception.go @@ -0,0 +1,230 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../threads_exception.i + +package threads_exception + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrExc uintptr + +func (p SwigcptrExc) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrExc) SwigIsExc() { +} + +var _wrap_new_Exc unsafe.Pointer + +func _swig_wrap_new_Exc(base int, _ string) (_ SwigcptrExc) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Exc, _swig_p) + return +} + +func NewExc(arg1 int, arg2 string) (_swig_ret Exc) { + return _swig_wrap_new_Exc(arg1, arg2) +} + +var _wrap_Exc_code_set unsafe.Pointer + +func _swig_wrap_Exc_code_set(base SwigcptrExc, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Exc_code_set, _swig_p) + return +} + +func (arg1 SwigcptrExc) SetCode(arg2 int) { + _swig_wrap_Exc_code_set(arg1, arg2) +} + +var _wrap_Exc_code_get unsafe.Pointer + +func _swig_wrap_Exc_code_get(base SwigcptrExc) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Exc_code_get, _swig_p) + return +} + +func (arg1 SwigcptrExc) GetCode() (_swig_ret int) { + return _swig_wrap_Exc_code_get(arg1) +} + +var _wrap_Exc_msg_set unsafe.Pointer + +func _swig_wrap_Exc_msg_set(base SwigcptrExc, _ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Exc_msg_set, _swig_p) + return +} + +func (arg1 SwigcptrExc) SetMsg(arg2 string) { + _swig_wrap_Exc_msg_set(arg1, arg2) +} + +var _wrap_Exc_msg_get unsafe.Pointer + +func _swig_wrap_Exc_msg_get(base SwigcptrExc) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Exc_msg_get, _swig_p) + return +} + +func (arg1 SwigcptrExc) GetMsg() (_swig_ret string) { + return _swig_wrap_Exc_msg_get(arg1) +} + +var _wrap_delete_Exc unsafe.Pointer + +func _swig_wrap_delete_Exc(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Exc, _swig_p) + return +} + +func DeleteExc(arg1 Exc) { + _swig_wrap_delete_Exc(arg1.Swigcptr()) +} + +type Exc interface { + Swigcptr() uintptr + SwigIsExc() + SetCode(arg2 int) + GetCode() (_swig_ret int) + SetMsg(arg2 string) + GetMsg() (_swig_ret string) +} + +type SwigcptrTest uintptr + +func (p SwigcptrTest) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrTest) SwigIsTest() { +} + +var _wrap_Test_simple unsafe.Pointer + +func _swig_wrap_Test_simple(base SwigcptrTest) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Test_simple, _swig_p) + return +} + +func (arg1 SwigcptrTest) Simple() (_swig_ret int) { + return _swig_wrap_Test_simple(arg1) +} + +var _wrap_Test_message unsafe.Pointer + +func _swig_wrap_Test_message(base SwigcptrTest) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Test_message, _swig_p) + return +} + +func (arg1 SwigcptrTest) Message() (_swig_ret int) { + return _swig_wrap_Test_message(arg1) +} + +var _wrap_Test_hosed unsafe.Pointer + +func _swig_wrap_Test_hosed(base SwigcptrTest) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Test_hosed, _swig_p) + return +} + +func (arg1 SwigcptrTest) Hosed() (_swig_ret int) { + return _swig_wrap_Test_hosed(arg1) +} + +var _wrap_Test_unknown unsafe.Pointer + +func _swig_wrap_Test_unknown(base SwigcptrTest) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Test_unknown, _swig_p) + return +} + +func (arg1 SwigcptrTest) Unknown() (_swig_ret int) { + return _swig_wrap_Test_unknown(arg1) +} + +var _wrap_Test_multi unsafe.Pointer + +func _swig_wrap_Test_multi(base SwigcptrTest, _ int) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Test_multi, _swig_p) + return +} + +func (arg1 SwigcptrTest) Multi(arg2 int) (_swig_ret int) { + return _swig_wrap_Test_multi(arg1, arg2) +} + +var _wrap_new_Test unsafe.Pointer + +func _swig_wrap_new_Test() (base SwigcptrTest) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Test, _swig_p) + return +} + +func NewTest() (_swig_ret Test) { + return _swig_wrap_new_Test() +} + +var _wrap_delete_Test unsafe.Pointer + +func _swig_wrap_delete_Test(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Test, _swig_p) + return +} + +func DeleteTest(arg1 Test) { + _swig_wrap_delete_Test(arg1.Swigcptr()) +} + +type Test interface { + Swigcptr() uintptr + SwigIsTest() + Simple() (_swig_ret int) + Message() (_swig_ret int) + Hosed() (_swig_ret int) + Unknown() (_swig_ret int) + Multi(arg2 int) (_swig_ret int) +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/threads_exception_runme b/Examples/test-suite/go/threads_exception_runme new file mode 100755 index 000000000..ce2bde645 Binary files /dev/null and b/Examples/test-suite/go/threads_exception_runme differ diff --git a/Examples/test-suite/go/throw_exception.go b/Examples/test-suite/go/throw_exception.go new file mode 100644 index 000000000..c658255e4 --- /dev/null +++ b/Examples/test-suite/go/throw_exception.go @@ -0,0 +1,285 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../throw_exception.i + +package throw_exception + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrError uintptr + +func (p SwigcptrError) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrError) SwigIsError() { +} + +var _wrap_new_Error unsafe.Pointer + +func _swig_wrap_new_Error() (base SwigcptrError) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Error, _swig_p) + return +} + +func NewError() (_swig_ret Error) { + return _swig_wrap_new_Error() +} + +var _wrap_delete_Error unsafe.Pointer + +func _swig_wrap_delete_Error(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Error, _swig_p) + return +} + +func DeleteError(arg1 Error) { + _swig_wrap_delete_Error(arg1.Swigcptr()) +} + +type Error interface { + Swigcptr() uintptr + SwigIsError() +} + +var _wrap_test_is_Error unsafe.Pointer + +func _swig_wrap_test_is_Error(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_test_is_Error, _swig_p) + return +} + +func Test_is_Error(arg1 Error) { + _swig_wrap_test_is_Error(arg1.Swigcptr()) +} + +type NamespaceEnumTest int +var _wrap_enum1 unsafe.Pointer + +func _swig_getenum1() (_swig_ret NamespaceEnumTest) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_enum1, _swig_p) + return +} +var Enum1 NamespaceEnumTest = _swig_getenum1() +var _wrap_enum2 unsafe.Pointer + +func _swig_getenum2() (_swig_ret NamespaceEnumTest) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_enum2, _swig_p) + return +} +var Enum2 NamespaceEnumTest = _swig_getenum2() +type SwigcptrFoo uintptr + +func (p SwigcptrFoo) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrFoo) SwigIsFoo() { +} + +var _wrap_Foo_test_int unsafe.Pointer + +func _swig_wrap_Foo_test_int(base SwigcptrFoo) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_test_int, _swig_p) + return +} + +func (arg1 SwigcptrFoo) Test_int() { + _swig_wrap_Foo_test_int(arg1) +} + +var _wrap_Foo_test_msg unsafe.Pointer + +func _swig_wrap_Foo_test_msg(base SwigcptrFoo) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_test_msg, _swig_p) + return +} + +func (arg1 SwigcptrFoo) Test_msg() { + _swig_wrap_Foo_test_msg(arg1) +} + +var _wrap_Foo_test_cls unsafe.Pointer + +func _swig_wrap_Foo_test_cls(base SwigcptrFoo) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_test_cls, _swig_p) + return +} + +func (arg1 SwigcptrFoo) Test_cls() { + _swig_wrap_Foo_test_cls(arg1) +} + +var _wrap_Foo_test_cls_ptr unsafe.Pointer + +func _swig_wrap_Foo_test_cls_ptr(base SwigcptrFoo) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_test_cls_ptr, _swig_p) + return +} + +func (arg1 SwigcptrFoo) Test_cls_ptr() { + _swig_wrap_Foo_test_cls_ptr(arg1) +} + +var _wrap_Foo_test_cls_ref unsafe.Pointer + +func _swig_wrap_Foo_test_cls_ref(base SwigcptrFoo) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_test_cls_ref, _swig_p) + return +} + +func (arg1 SwigcptrFoo) Test_cls_ref() { + _swig_wrap_Foo_test_cls_ref(arg1) +} + +var _wrap_Foo_test_cls_td unsafe.Pointer + +func _swig_wrap_Foo_test_cls_td(base SwigcptrFoo) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_test_cls_td, _swig_p) + return +} + +func (arg1 SwigcptrFoo) Test_cls_td() { + _swig_wrap_Foo_test_cls_td(arg1) +} + +var _wrap_Foo_test_cls_ptr_td unsafe.Pointer + +func _swig_wrap_Foo_test_cls_ptr_td(base SwigcptrFoo) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_test_cls_ptr_td, _swig_p) + return +} + +func (arg1 SwigcptrFoo) Test_cls_ptr_td() { + _swig_wrap_Foo_test_cls_ptr_td(arg1) +} + +var _wrap_Foo_test_cls_ref_td unsafe.Pointer + +func _swig_wrap_Foo_test_cls_ref_td(base SwigcptrFoo) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_test_cls_ref_td, _swig_p) + return +} + +func (arg1 SwigcptrFoo) Test_cls_ref_td() { + _swig_wrap_Foo_test_cls_ref_td(arg1) +} + +var _wrap_Foo_test_array unsafe.Pointer + +func _swig_wrap_Foo_test_array(base SwigcptrFoo) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_test_array, _swig_p) + return +} + +func (arg1 SwigcptrFoo) Test_array() { + _swig_wrap_Foo_test_array(arg1) +} + +var _wrap_Foo_test_enum unsafe.Pointer + +func _swig_wrap_Foo_test_enum(base SwigcptrFoo) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_test_enum, _swig_p) + return +} + +func (arg1 SwigcptrFoo) Test_enum() { + _swig_wrap_Foo_test_enum(arg1) +} + +var _wrap_Foo_test_multi unsafe.Pointer + +func _swig_wrap_Foo_test_multi(base SwigcptrFoo, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_test_multi, _swig_p) + return +} + +func (arg1 SwigcptrFoo) Test_multi(arg2 int) { + _swig_wrap_Foo_test_multi(arg1, arg2) +} + +var _wrap_new_Foo unsafe.Pointer + +func _swig_wrap_new_Foo() (base SwigcptrFoo) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Foo, _swig_p) + return +} + +func NewFoo() (_swig_ret Foo) { + return _swig_wrap_new_Foo() +} + +var _wrap_delete_Foo unsafe.Pointer + +func _swig_wrap_delete_Foo(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Foo, _swig_p) + return +} + +func DeleteFoo(arg1 Foo) { + _swig_wrap_delete_Foo(arg1.Swigcptr()) +} + +type Foo interface { + Swigcptr() uintptr + SwigIsFoo() + Test_int() + Test_msg() + Test_cls() + Test_cls_ptr() + Test_cls_ref() + Test_cls_td() + Test_cls_ptr_td() + Test_cls_ref_td() + Test_array() + Test_enum() + Test_multi(arg2 int) +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/typedef_array_member.go b/Examples/test-suite/go/typedef_array_member.go new file mode 100644 index 000000000..69e3a93e5 --- /dev/null +++ b/Examples/test-suite/go/typedef_array_member.go @@ -0,0 +1,173 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../typedef_array_member.i + +package typedef_array_member + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrFoo uintptr + +func (p SwigcptrFoo) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrFoo) SwigIsFoo() { +} + +var _wrap_Foo_x_set unsafe.Pointer + +func _swig_wrap_Foo_x_set(base SwigcptrFoo, _ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_x_set, _swig_p) + return +} + +func (arg1 SwigcptrFoo) SetX(arg2 string) { + _swig_wrap_Foo_x_set(arg1, arg2) +} + +var _wrap_Foo_x_get unsafe.Pointer + +func _swig_wrap_Foo_x_get(base SwigcptrFoo) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_x_get, _swig_p) + return +} + +func (arg1 SwigcptrFoo) GetX() (_swig_ret string) { + return _swig_wrap_Foo_x_get(arg1) +} + +var _wrap_new_Foo unsafe.Pointer + +func _swig_wrap_new_Foo() (base SwigcptrFoo) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Foo, _swig_p) + return +} + +func NewFoo() (_swig_ret Foo) { + return _swig_wrap_new_Foo() +} + +var _wrap_delete_Foo unsafe.Pointer + +func _swig_wrap_delete_Foo(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Foo, _swig_p) + return +} + +func DeleteFoo(arg1 Foo) { + _swig_wrap_delete_Foo(arg1.Swigcptr()) +} + +type Foo interface { + Swigcptr() uintptr + SwigIsFoo() + SetX(arg2 string) + GetX() (_swig_ret string) +} + +type SwigcptrAst_channel uintptr + +func (p SwigcptrAst_channel) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrAst_channel) SwigIsAst_channel() { +} + +var _wrap_Ast_channel_jmp_set unsafe.Pointer + +func _swig_wrap_Ast_channel_jmp_set(base SwigcptrAst_channel, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Ast_channel_jmp_set, _swig_p) + return +} + +func (arg1 SwigcptrAst_channel) SetJmp(arg2 Jbuf_tag) { + _swig_wrap_Ast_channel_jmp_set(arg1, arg2.Swigcptr()) +} + +var _wrap_Ast_channel_jmp_get unsafe.Pointer + +func _swig_wrap_Ast_channel_jmp_get(base SwigcptrAst_channel) (_ SwigcptrJbuf_tag) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Ast_channel_jmp_get, _swig_p) + return +} + +func (arg1 SwigcptrAst_channel) GetJmp() (_swig_ret Jbuf_tag) { + return _swig_wrap_Ast_channel_jmp_get(arg1) +} + +var _wrap_new_Ast_channel unsafe.Pointer + +func _swig_wrap_new_Ast_channel() (base SwigcptrAst_channel) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Ast_channel, _swig_p) + return +} + +func NewAst_channel() (_swig_ret Ast_channel) { + return _swig_wrap_new_Ast_channel() +} + +var _wrap_delete_Ast_channel unsafe.Pointer + +func _swig_wrap_delete_Ast_channel(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Ast_channel, _swig_p) + return +} + +func DeleteAst_channel(arg1 Ast_channel) { + _swig_wrap_delete_Ast_channel(arg1.Swigcptr()) +} + +type Ast_channel interface { + Swigcptr() uintptr + SwigIsAst_channel() + SetJmp(arg2 Jbuf_tag) + GetJmp() (_swig_ret Jbuf_tag) +} + + +type SwigcptrJbuf_tag uintptr +type Jbuf_tag interface { + Swigcptr() uintptr; +} +func (p SwigcptrJbuf_tag) Swigcptr() uintptr { + return uintptr(p) +} + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/typedef_class.go b/Examples/test-suite/go/typedef_class.go new file mode 100644 index 000000000..cb02079bf --- /dev/null +++ b/Examples/test-suite/go/typedef_class.go @@ -0,0 +1,297 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../typedef_class.i + +package typedef_class + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrRealA uintptr + +func (p SwigcptrRealA) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrRealA) SwigIsRealA() { +} + +var _wrap_RealA_a_set unsafe.Pointer + +func _swig_wrap_RealA_a_set(base SwigcptrRealA, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_RealA_a_set, _swig_p) + return +} + +func (arg1 SwigcptrRealA) SetA(arg2 int) { + _swig_wrap_RealA_a_set(arg1, arg2) +} + +var _wrap_RealA_a_get unsafe.Pointer + +func _swig_wrap_RealA_a_get(base SwigcptrRealA) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_RealA_a_get, _swig_p) + return +} + +func (arg1 SwigcptrRealA) GetA() (_swig_ret int) { + return _swig_wrap_RealA_a_get(arg1) +} + +var _wrap_new_RealA unsafe.Pointer + +func _swig_wrap_new_RealA() (base SwigcptrRealA) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_RealA, _swig_p) + return +} + +func NewRealA() (_swig_ret RealA) { + return _swig_wrap_new_RealA() +} + +var _wrap_delete_RealA unsafe.Pointer + +func _swig_wrap_delete_RealA(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_RealA, _swig_p) + return +} + +func DeleteRealA(arg1 RealA) { + _swig_wrap_delete_RealA(arg1.Swigcptr()) +} + +type RealA interface { + Swigcptr() uintptr + SwigIsRealA() + SetA(arg2 int) + GetA() (_swig_ret int) +} + +type SwigcptrB uintptr + +func (p SwigcptrB) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrB) SwigIsB() { +} + +var _wrap_B_testA unsafe.Pointer + +func _swig_wrap_B_testA(base SwigcptrB, _ uintptr) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_B_testA, _swig_p) + return +} + +func (arg1 SwigcptrB) TestA(arg2 RealA) (_swig_ret int) { + return _swig_wrap_B_testA(arg1, arg2.Swigcptr()) +} + +var _wrap_new_B unsafe.Pointer + +func _swig_wrap_new_B() (base SwigcptrB) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_B, _swig_p) + return +} + +func NewB() (_swig_ret B) { + return _swig_wrap_new_B() +} + +var _wrap_delete_B unsafe.Pointer + +func _swig_wrap_delete_B(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_B, _swig_p) + return +} + +func DeleteB(arg1 B) { + _swig_wrap_delete_B(arg1.Swigcptr()) +} + +type B interface { + Swigcptr() uintptr + SwigIsB() + TestA(arg2 RealA) (_swig_ret int) +} + +type SwigcptrBBB uintptr + +func (p SwigcptrBBB) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrBBB) SwigIsBBB() { +} + +var _wrap_new_BBB unsafe.Pointer + +func _swig_wrap_new_BBB() (base SwigcptrBBB) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_BBB, _swig_p) + return +} + +func NewBBB() (_swig_ret BBB) { + return _swig_wrap_new_BBB() +} + +var _wrap_delete_BBB unsafe.Pointer + +func _swig_wrap_delete_BBB(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_BBB, _swig_p) + return +} + +func DeleteBBB(arg1 BBB) { + _swig_wrap_delete_BBB(arg1.Swigcptr()) +} + +type BBB interface { + Swigcptr() uintptr + SwigIsBBB() +} + +type SwigcptrBB uintptr + +func (p SwigcptrBB) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrBB) SwigIsBB() { +} + +var _wrap_new_BB__SWIG_0 unsafe.Pointer + +func _swig_wrap_new_BB__SWIG_0() (base SwigcptrBB) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_BB__SWIG_0, _swig_p) + return +} + +func NewBB__SWIG_0() (_swig_ret BB) { + return _swig_wrap_new_BB__SWIG_0() +} + +var _wrap_new_BB__SWIG_1 unsafe.Pointer + +func _swig_wrap_new_BB__SWIG_1(base int) (_ SwigcptrBB) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_BB__SWIG_1, _swig_p) + return +} + +func NewBB__SWIG_1(arg1 int) (_swig_ret BB) { + return _swig_wrap_new_BB__SWIG_1(arg1) +} + +func NewBB(a ...interface{}) BB { + argc := len(a) + if argc == 0 { + return NewBB__SWIG_0() + } + if argc == 1 { + return NewBB__SWIG_1(a[0].(int)) + } + panic("No match for overloaded function call") +} + +var _wrap_BB_aa_var_set unsafe.Pointer + +func _swig_wrap_BB_aa_var_set(base SwigcptrBB, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_BB_aa_var_set, _swig_p) + return +} + +func (arg1 SwigcptrBB) SetAa_var(arg2 int) { + _swig_wrap_BB_aa_var_set(arg1, arg2) +} + +var _wrap_BB_aa_var_get unsafe.Pointer + +func _swig_wrap_BB_aa_var_get(base SwigcptrBB) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_BB_aa_var_get, _swig_p) + return +} + +func (arg1 SwigcptrBB) GetAa_var() (_swig_ret int) { + return _swig_wrap_BB_aa_var_get(arg1) +} + +var _wrap_BB_aa_method unsafe.Pointer + +func _swig_wrap_BB_aa_method(base SwigcptrBB, _ float64) (_ *int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_BB_aa_method, _swig_p) + return +} + +func (arg1 SwigcptrBB) Aa_method(arg2 float64) (_swig_ret *int) { + return _swig_wrap_BB_aa_method(arg1, arg2) +} + +var _wrap_BB_aa_static_method unsafe.Pointer + +func BBAa_static_method(arg1 bool) (_swig_ret *int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_BB_aa_static_method, _swig_p) + return +} +var _wrap_delete_BB unsafe.Pointer + +func _swig_wrap_delete_BB(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_BB, _swig_p) + return +} + +func DeleteBB(arg1 BB) { + _swig_wrap_delete_BB(arg1.Swigcptr()) +} + +type BB interface { + Swigcptr() uintptr + SwigIsBB() + SetAa_var(arg2 int) + GetAa_var() (_swig_ret int) + Aa_method(arg2 float64) (_swig_ret *int) +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/typedef_class_runme b/Examples/test-suite/go/typedef_class_runme new file mode 100755 index 000000000..1affbf7ce Binary files /dev/null and b/Examples/test-suite/go/typedef_class_runme differ diff --git a/Examples/test-suite/go/typedef_funcptr.go b/Examples/test-suite/go/typedef_funcptr.go new file mode 100644 index 000000000..b26a46782 --- /dev/null +++ b/Examples/test-suite/go/typedef_funcptr.go @@ -0,0 +1,52 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../typedef_funcptr.i + +package typedef_funcptr + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +var _wrap_do_op unsafe.Pointer + +func Do_op(arg1 int, arg2 int, arg3 _swig_fnptr) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_do_op, _swig_p) + return +} +var _wrap_addf unsafe.Pointer + +func _swig_getaddf() (_swig_ret _swig_fnptr) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_addf, _swig_p) + return +} +var Addf _swig_fnptr = _swig_getaddf() +var _wrap_subf unsafe.Pointer + +func _swig_getsubf() (_swig_ret _swig_fnptr) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_subf, _swig_p) + return +} +var Subf _swig_fnptr = _swig_getsubf() + diff --git a/Examples/test-suite/go/typedef_inherit.go b/Examples/test-suite/go/typedef_inherit.go new file mode 100644 index 000000000..39cf9102f --- /dev/null +++ b/Examples/test-suite/go/typedef_inherit.go @@ -0,0 +1,283 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../typedef_inherit.i + +package typedef_inherit + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrFoo uintptr + +func (p SwigcptrFoo) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrFoo) SwigIsFoo() { +} + +var _wrap_delete_Foo unsafe.Pointer + +func _swig_wrap_delete_Foo(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Foo, _swig_p) + return +} + +func DeleteFoo(arg1 Foo) { + _swig_wrap_delete_Foo(arg1.Swigcptr()) +} + +var _wrap_Foo_blah unsafe.Pointer + +func _swig_wrap_Foo_blah(base SwigcptrFoo) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_blah, _swig_p) + return +} + +func (arg1 SwigcptrFoo) Blah() (_swig_ret string) { + return _swig_wrap_Foo_blah(arg1) +} + +var _wrap_new_Foo unsafe.Pointer + +func _swig_wrap_new_Foo() (base SwigcptrFoo) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Foo, _swig_p) + return +} + +func NewFoo() (_swig_ret Foo) { + return _swig_wrap_new_Foo() +} + +type Foo interface { + Swigcptr() uintptr + SwigIsFoo() + Blah() (_swig_ret string) +} + +type SwigcptrBar uintptr + +func (p SwigcptrBar) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrBar) SwigIsBar() { +} + +var _wrap_Bar_blah unsafe.Pointer + +func _swig_wrap_Bar_blah(base SwigcptrBar) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Bar_blah, _swig_p) + return +} + +func (arg1 SwigcptrBar) Blah() (_swig_ret string) { + return _swig_wrap_Bar_blah(arg1) +} + +var _wrap_new_Bar unsafe.Pointer + +func _swig_wrap_new_Bar() (base SwigcptrBar) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Bar, _swig_p) + return +} + +func NewBar() (_swig_ret Bar) { + return _swig_wrap_new_Bar() +} + +var _wrap_delete_Bar unsafe.Pointer + +func _swig_wrap_delete_Bar(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Bar, _swig_p) + return +} + +func DeleteBar(arg1 Bar) { + _swig_wrap_delete_Bar(arg1.Swigcptr()) +} + +func (p SwigcptrBar) SwigIsFoo() { +} + +func (p SwigcptrBar) SwigGetFoo() Foo { + return SwigcptrFoo(p.Swigcptr()) +} + +type Bar interface { + Swigcptr() uintptr + SwigIsBar() + Blah() (_swig_ret string) + SwigIsFoo() + SwigGetFoo() Foo +} + +var _wrap_do_blah unsafe.Pointer + +func _swig_wrap_do_blah(base uintptr) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_do_blah, _swig_p) + return +} + +func Do_blah(arg1 Foo) (_swig_ret string) { + return _swig_wrap_do_blah(arg1.Swigcptr()) +} + +type SwigcptrSpam uintptr + +func (p SwigcptrSpam) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrSpam) SwigIsSpam() { +} + +var _wrap_delete_Spam unsafe.Pointer + +func _swig_wrap_delete_Spam(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Spam, _swig_p) + return +} + +func DeleteSpam(arg1 Spam) { + _swig_wrap_delete_Spam(arg1.Swigcptr()) +} + +var _wrap_Spam_blah unsafe.Pointer + +func _swig_wrap_Spam_blah(base SwigcptrSpam) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Spam_blah, _swig_p) + return +} + +func (arg1 SwigcptrSpam) Blah() (_swig_ret string) { + return _swig_wrap_Spam_blah(arg1) +} + +var _wrap_new_Spam unsafe.Pointer + +func _swig_wrap_new_Spam() (base SwigcptrSpam) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Spam, _swig_p) + return +} + +func NewSpam() (_swig_ret Spam) { + return _swig_wrap_new_Spam() +} + +type Spam interface { + Swigcptr() uintptr + SwigIsSpam() + Blah() (_swig_ret string) +} + +type SwigcptrGrok uintptr + +func (p SwigcptrGrok) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrGrok) SwigIsGrok() { +} + +var _wrap_delete_Grok unsafe.Pointer + +func _swig_wrap_delete_Grok(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Grok, _swig_p) + return +} + +func DeleteGrok(arg1 Grok) { + _swig_wrap_delete_Grok(arg1.Swigcptr()) +} + +var _wrap_Grok_blah unsafe.Pointer + +func _swig_wrap_Grok_blah(base SwigcptrGrok) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Grok_blah, _swig_p) + return +} + +func (arg1 SwigcptrGrok) Blah() (_swig_ret string) { + return _swig_wrap_Grok_blah(arg1) +} + +var _wrap_new_Grok unsafe.Pointer + +func _swig_wrap_new_Grok() (base SwigcptrGrok) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Grok, _swig_p) + return +} + +func NewGrok() (_swig_ret Grok) { + return _swig_wrap_new_Grok() +} + +func (p SwigcptrGrok) SwigIsSpam() { +} + +func (p SwigcptrGrok) SwigGetSpam() Spam { + return SwigcptrSpam(p.Swigcptr()) +} + +type Grok interface { + Swigcptr() uintptr + SwigIsGrok() + Blah() (_swig_ret string) + SwigIsSpam() + SwigGetSpam() Spam +} + +var _wrap_do_blah2 unsafe.Pointer + +func _swig_wrap_do_blah2(base uintptr) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_do_blah2, _swig_p) + return +} + +func Do_blah2(arg1 Spam) (_swig_ret string) { + return _swig_wrap_do_blah2(arg1.Swigcptr()) +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/typedef_inherit_runme b/Examples/test-suite/go/typedef_inherit_runme new file mode 100755 index 000000000..3c24d9ebe Binary files /dev/null and b/Examples/test-suite/go/typedef_inherit_runme differ diff --git a/Examples/test-suite/go/typedef_mptr.go b/Examples/test-suite/go/typedef_mptr.go new file mode 100644 index 000000000..67f731ec0 --- /dev/null +++ b/Examples/test-suite/go/typedef_mptr.go @@ -0,0 +1,29 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../typedef_mptr.i + +package typedef_mptr + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + + diff --git a/Examples/test-suite/go/typedef_reference.go b/Examples/test-suite/go/typedef_reference.go new file mode 100644 index 000000000..64d09f58e --- /dev/null +++ b/Examples/test-suite/go/typedef_reference.go @@ -0,0 +1,96 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../typedef_reference.i + +package typedef_reference + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +var _wrap_new_intp unsafe.Pointer + +func New_intp() (_swig_ret *int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_new_intp, _swig_p) + return +} +var _wrap_copy_intp unsafe.Pointer + +func Copy_intp(arg1 int) (_swig_ret *int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_copy_intp, _swig_p) + return +} +var _wrap_delete_intp unsafe.Pointer + +func _swig_wrap_delete_intp(base *int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_intp, _swig_p) + return +} + +func Delete_intp(arg1 *int) { + _swig_wrap_delete_intp(arg1) +} + +var _wrap_intp_assign unsafe.Pointer + +func _swig_wrap_intp_assign(base *int, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_intp_assign, _swig_p) + return +} + +func Intp_assign(arg1 *int, arg2 int) { + _swig_wrap_intp_assign(arg1, arg2) +} + +var _wrap_intp_value unsafe.Pointer + +func Intp_value(arg1 *int) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_intp_value, _swig_p) + return +} +var _wrap_somefunc unsafe.Pointer + +func Somefunc(arg1 *int) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_somefunc, _swig_p) + return +} +var _wrap_otherfunc unsafe.Pointer + +func Otherfunc(arg1 *int) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_otherfunc, _swig_p) + return +} + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/typedef_scope.go b/Examples/test-suite/go/typedef_scope.go new file mode 100644 index 000000000..1f00a8813 --- /dev/null +++ b/Examples/test-suite/go/typedef_scope.go @@ -0,0 +1,177 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../typedef_scope.i + +package typedef_scope + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrBar uintptr + +func (p SwigcptrBar) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrBar) SwigIsBar() { +} + +var _wrap_Bar_test1 unsafe.Pointer + +func _swig_wrap_Bar_test1(base SwigcptrBar, _ int, _ string) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Bar_test1, _swig_p) + return +} + +func (arg1 SwigcptrBar) Test1(arg2 int, arg3 string) (_swig_ret int) { + return _swig_wrap_Bar_test1(arg1, arg2, arg3) +} + +var _wrap_Bar_test2 unsafe.Pointer + +func _swig_wrap_Bar_test2(base SwigcptrBar, _ int, _ string) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Bar_test2, _swig_p) + return +} + +func (arg1 SwigcptrBar) Test2(arg2 int, arg3 string) (_swig_ret string) { + return _swig_wrap_Bar_test2(arg1, arg2, arg3) +} + +var _wrap_new_Bar unsafe.Pointer + +func _swig_wrap_new_Bar() (base SwigcptrBar) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Bar, _swig_p) + return +} + +func NewBar() (_swig_ret Bar) { + return _swig_wrap_new_Bar() +} + +var _wrap_delete_Bar unsafe.Pointer + +func _swig_wrap_delete_Bar(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Bar, _swig_p) + return +} + +func DeleteBar(arg1 Bar) { + _swig_wrap_delete_Bar(arg1.Swigcptr()) +} + +type Bar interface { + Swigcptr() uintptr + SwigIsBar() + Test1(arg2 int, arg3 string) (_swig_ret int) + Test2(arg2 int, arg3 string) (_swig_ret string) +} + +type SwigcptrFoo uintptr + +func (p SwigcptrFoo) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrFoo) SwigIsFoo() { +} + +var _wrap_new_Foo unsafe.Pointer + +func _swig_wrap_new_Foo() (base SwigcptrFoo) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Foo, _swig_p) + return +} + +func NewFoo() (_swig_ret Foo) { + return _swig_wrap_new_Foo() +} + +var _wrap_delete_Foo unsafe.Pointer + +func _swig_wrap_delete_Foo(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Foo, _swig_p) + return +} + +func DeleteFoo(arg1 Foo) { + _swig_wrap_delete_Foo(arg1.Swigcptr()) +} + +type Foo interface { + Swigcptr() uintptr + SwigIsFoo() +} + +type SwigcptrCBaz uintptr + +func (p SwigcptrCBaz) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrCBaz) SwigIsCBaz() { +} + +var _wrap_new_CBaz unsafe.Pointer + +func _swig_wrap_new_CBaz() (base SwigcptrCBaz) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_CBaz, _swig_p) + return +} + +func NewCBaz() (_swig_ret CBaz) { + return _swig_wrap_new_CBaz() +} + +var _wrap_delete_CBaz unsafe.Pointer + +func _swig_wrap_delete_CBaz(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_CBaz, _swig_p) + return +} + +func DeleteCBaz(arg1 CBaz) { + _swig_wrap_delete_CBaz(arg1.Swigcptr()) +} + +type CBaz interface { + Swigcptr() uintptr + SwigIsCBaz() +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/typedef_scope_runme b/Examples/test-suite/go/typedef_scope_runme new file mode 100755 index 000000000..444963d4c Binary files /dev/null and b/Examples/test-suite/go/typedef_scope_runme differ diff --git a/Examples/test-suite/go/typedef_sizet.go b/Examples/test-suite/go/typedef_sizet.go new file mode 100644 index 000000000..1c3772709 --- /dev/null +++ b/Examples/test-suite/go/typedef_sizet.go @@ -0,0 +1,36 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../typedef_sizet.i + +package typedef_sizet + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +var _wrap_size unsafe.Pointer + +func Size(arg1 int64) (_swig_ret int64) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_size, _swig_p) + return +} + diff --git a/Examples/test-suite/go/typedef_struct.go b/Examples/test-suite/go/typedef_struct.go new file mode 100644 index 000000000..837b51ad4 --- /dev/null +++ b/Examples/test-suite/go/typedef_struct.go @@ -0,0 +1,438 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../typedef_struct.i + +package typedef_struct + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrLineObj uintptr + +func (p SwigcptrLineObj) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrLineObj) SwigIsLineObj() { +} + +var _wrap_LineObj_numpoints_set unsafe.Pointer + +func _swig_wrap_LineObj_numpoints_set(base SwigcptrLineObj, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_LineObj_numpoints_set, _swig_p) + return +} + +func (arg1 SwigcptrLineObj) SetNumpoints(arg2 int) { + _swig_wrap_LineObj_numpoints_set(arg1, arg2) +} + +var _wrap_LineObj_numpoints_get unsafe.Pointer + +func _swig_wrap_LineObj_numpoints_get(base SwigcptrLineObj) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_LineObj_numpoints_get, _swig_p) + return +} + +func (arg1 SwigcptrLineObj) GetNumpoints() (_swig_ret int) { + return _swig_wrap_LineObj_numpoints_get(arg1) +} + +var _wrap_new_LineObj unsafe.Pointer + +func _swig_wrap_new_LineObj() (base SwigcptrLineObj) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_LineObj, _swig_p) + return +} + +func NewLineObj() (_swig_ret LineObj) { + return _swig_wrap_new_LineObj() +} + +var _wrap_delete_LineObj unsafe.Pointer + +func _swig_wrap_delete_LineObj(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_LineObj, _swig_p) + return +} + +func DeleteLineObj(arg1 LineObj) { + _swig_wrap_delete_LineObj(arg1.Swigcptr()) +} + +type LineObj interface { + Swigcptr() uintptr + SwigIsLineObj() + SetNumpoints(arg2 int) + GetNumpoints() (_swig_ret int) +} + +type SwigcptrFontSetObj uintptr + +func (p SwigcptrFontSetObj) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrFontSetObj) SwigIsFontSetObj() { +} + +var _wrap_FontSetObj_filename_get unsafe.Pointer + +func _swig_wrap_FontSetObj_filename_get(base SwigcptrFontSetObj) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_FontSetObj_filename_get, _swig_p) + return +} + +func (arg1 SwigcptrFontSetObj) GetFilename() (_swig_ret string) { + return _swig_wrap_FontSetObj_filename_get(arg1) +} + +var _wrap_FontSetObj_numfonts_get unsafe.Pointer + +func _swig_wrap_FontSetObj_numfonts_get(base SwigcptrFontSetObj) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_FontSetObj_numfonts_get, _swig_p) + return +} + +func (arg1 SwigcptrFontSetObj) GetNumfonts() (_swig_ret int) { + return _swig_wrap_FontSetObj_numfonts_get(arg1) +} + +var _wrap_FontSetObj_fonts_set unsafe.Pointer + +func _swig_wrap_FontSetObj_fonts_set(base SwigcptrFontSetObj, _ *int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_FontSetObj_fonts_set, _swig_p) + return +} + +func (arg1 SwigcptrFontSetObj) SetFonts(arg2 *int) { + _swig_wrap_FontSetObj_fonts_set(arg1, arg2) +} + +var _wrap_FontSetObj_fonts_get unsafe.Pointer + +func _swig_wrap_FontSetObj_fonts_get(base SwigcptrFontSetObj) (_ *int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_FontSetObj_fonts_get, _swig_p) + return +} + +func (arg1 SwigcptrFontSetObj) GetFonts() (_swig_ret *int) { + return _swig_wrap_FontSetObj_fonts_get(arg1) +} + +var _wrap_new_FontSetObj unsafe.Pointer + +func _swig_wrap_new_FontSetObj() (base SwigcptrFontSetObj) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_FontSetObj, _swig_p) + return +} + +func NewFontSetObj() (_swig_ret FontSetObj) { + return _swig_wrap_new_FontSetObj() +} + +var _wrap_delete_FontSetObj unsafe.Pointer + +func _swig_wrap_delete_FontSetObj(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_FontSetObj, _swig_p) + return +} + +func DeleteFontSetObj(arg1 FontSetObj) { + _swig_wrap_delete_FontSetObj(arg1.Swigcptr()) +} + +type FontSetObj interface { + Swigcptr() uintptr + SwigIsFontSetObj() + GetFilename() (_swig_ret string) + GetNumfonts() (_swig_ret int) + SetFonts(arg2 *int) + GetFonts() (_swig_ret *int) +} + +const MS_NOOVERRIDE int = -1111 +type SwigcptrA_t uintptr + +func (p SwigcptrA_t) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrA_t) SwigIsA_t() { +} + +var _wrap_A_t_a_set unsafe.Pointer + +func _swig_wrap_A_t_a_set(base SwigcptrA_t, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_A_t_a_set, _swig_p) + return +} + +func (arg1 SwigcptrA_t) SetA(arg2 int) { + _swig_wrap_A_t_a_set(arg1, arg2) +} + +var _wrap_A_t_a_get unsafe.Pointer + +func _swig_wrap_A_t_a_get(base SwigcptrA_t) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_A_t_a_get, _swig_p) + return +} + +func (arg1 SwigcptrA_t) GetA() (_swig_ret int) { + return _swig_wrap_A_t_a_get(arg1) +} + +var _wrap_A_t_b_set unsafe.Pointer + +func _swig_wrap_A_t_b_set(base SwigcptrA_t, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_A_t_b_set, _swig_p) + return +} + +func (arg1 SwigcptrA_t) SetB(arg2 int) { + _swig_wrap_A_t_b_set(arg1, arg2) +} + +var _wrap_A_t_b_get unsafe.Pointer + +func _swig_wrap_A_t_b_get(base SwigcptrA_t) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_A_t_b_get, _swig_p) + return +} + +func (arg1 SwigcptrA_t) GetB() (_swig_ret int) { + return _swig_wrap_A_t_b_get(arg1) +} + +var _wrap_new_A_t unsafe.Pointer + +func _swig_wrap_new_A_t() (base SwigcptrA_t) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_A_t, _swig_p) + return +} + +func NewA_t() (_swig_ret A_t) { + return _swig_wrap_new_A_t() +} + +var _wrap_delete_A_t unsafe.Pointer + +func _swig_wrap_delete_A_t(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_A_t, _swig_p) + return +} + +func DeleteA_t(arg1 A_t) { + _swig_wrap_delete_A_t(arg1.Swigcptr()) +} + +type A_t interface { + Swigcptr() uintptr + SwigIsA_t() + SetA(arg2 int) + GetA() (_swig_ret int) + SetB(arg2 int) + GetB() (_swig_ret int) +} + +var _wrap_make_a unsafe.Pointer + +func _swig_wrap_make_a() (base SwigcptrA_t) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_make_a, _swig_p) + return +} + +func Make_a() (_swig_ret A_t) { + return _swig_wrap_make_a() +} + +var _wrap_make_b unsafe.Pointer + +func _swig_wrap_make_b() (base SwigcptrA_t) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_make_b, _swig_p) + return +} + +func Make_b() (_swig_ret A_t) { + return _swig_wrap_make_b() +} + +type SwigcptrFoo uintptr + +func (p SwigcptrFoo) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrFoo) SwigIsFoo() { +} + +var _wrap_NONAME1_Foo unsafe.Pointer + +func _swig_getFoo_NONAME1_Foo() (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_NONAME1_Foo, _swig_p) + return +} +var FooNONAME1 int = _swig_getFoo_NONAME1_Foo() +var _wrap_NONAME2_Foo unsafe.Pointer + +func _swig_getFoo_NONAME2_Foo() (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_NONAME2_Foo, _swig_p) + return +} +var FooNONAME2 int = _swig_getFoo_NONAME2_Foo() +var _wrap_Foo_enumvar_set unsafe.Pointer + +func _swig_wrap_Foo_enumvar_set(base SwigcptrFoo, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_enumvar_set, _swig_p) + return +} + +func (arg1 SwigcptrFoo) SetEnumvar(arg2 int) { + _swig_wrap_Foo_enumvar_set(arg1, arg2) +} + +var _wrap_Foo_enumvar_get unsafe.Pointer + +func _swig_wrap_Foo_enumvar_get(base SwigcptrFoo) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_enumvar_get, _swig_p) + return +} + +func (arg1 SwigcptrFoo) GetEnumvar() (_swig_ret int) { + return _swig_wrap_Foo_enumvar_get(arg1) +} + +var _wrap_Foo_foovar_set unsafe.Pointer + +func _swig_wrap_Foo_foovar_set(base SwigcptrFoo, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_foovar_set, _swig_p) + return +} + +func (arg1 SwigcptrFoo) SetFoovar(arg2 int) { + _swig_wrap_Foo_foovar_set(arg1, arg2) +} + +var _wrap_Foo_foovar_get unsafe.Pointer + +func _swig_wrap_Foo_foovar_get(base SwigcptrFoo) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_foovar_get, _swig_p) + return +} + +func (arg1 SwigcptrFoo) GetFoovar() (_swig_ret int) { + return _swig_wrap_Foo_foovar_get(arg1) +} + +var _wrap_Foo_fptr_set unsafe.Pointer + +func _swig_wrap_Foo_fptr_set(base SwigcptrFoo, _ _swig_fnptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_fptr_set, _swig_p) + return +} + +func (arg1 SwigcptrFoo) SetFptr(arg2 _swig_fnptr) { + _swig_wrap_Foo_fptr_set(arg1, arg2) +} + +var _wrap_Foo_fptr_get unsafe.Pointer + +func _swig_wrap_Foo_fptr_get(base SwigcptrFoo) (_ _swig_fnptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_fptr_get, _swig_p) + return +} + +func (arg1 SwigcptrFoo) GetFptr() (_swig_ret _swig_fnptr) { + return _swig_wrap_Foo_fptr_get(arg1) +} + +var _wrap_new_Foo unsafe.Pointer + +func _swig_wrap_new_Foo() (base SwigcptrFoo) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Foo, _swig_p) + return +} + +func NewFoo() (_swig_ret Foo) { + return _swig_wrap_new_Foo() +} + +var _wrap_delete_Foo unsafe.Pointer + +func _swig_wrap_delete_Foo(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Foo, _swig_p) + return +} + +func DeleteFoo(arg1 Foo) { + _swig_wrap_delete_Foo(arg1.Swigcptr()) +} + +type Foo interface { + Swigcptr() uintptr + SwigIsFoo() + SetEnumvar(arg2 int) + GetEnumvar() (_swig_ret int) + SetFoovar(arg2 int) + GetFoovar() (_swig_ret int) + SetFptr(arg2 _swig_fnptr) + GetFptr() (_swig_ret _swig_fnptr) +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/typedef_typedef.go b/Examples/test-suite/go/typedef_typedef.go new file mode 100644 index 000000000..785751e09 --- /dev/null +++ b/Examples/test-suite/go/typedef_typedef.go @@ -0,0 +1,164 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../typedef_typedef.i + +package typedef_typedef + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrA uintptr + +func (p SwigcptrA) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrA) SwigIsA() { +} + +var _wrap_new_A unsafe.Pointer + +func _swig_wrap_new_A() (base SwigcptrA) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_A, _swig_p) + return +} + +func NewA() (_swig_ret A) { + return _swig_wrap_new_A() +} + +var _wrap_delete_A unsafe.Pointer + +func _swig_wrap_delete_A(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_A, _swig_p) + return +} + +func DeleteA(arg1 A) { + _swig_wrap_delete_A(arg1.Swigcptr()) +} + +type A interface { + Swigcptr() uintptr + SwigIsA() +} + +type SwigcptrC uintptr + +func (p SwigcptrC) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrC) SwigIsC() { +} + +var _wrap_new_C unsafe.Pointer + +func _swig_wrap_new_C() (base SwigcptrC) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_C, _swig_p) + return +} + +func NewC() (_swig_ret C) { + return _swig_wrap_new_C() +} + +var _wrap_delete_C unsafe.Pointer + +func _swig_wrap_delete_C(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_C, _swig_p) + return +} + +func DeleteC(arg1 C) { + _swig_wrap_delete_C(arg1.Swigcptr()) +} + +type C interface { + Swigcptr() uintptr + SwigIsC() +} + +type SwigcptrB uintptr + +func (p SwigcptrB) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrB) SwigIsB() { +} + +var _wrap_B_getValue unsafe.Pointer + +func _swig_wrap_B_getValue(base SwigcptrB, _ int) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_B_getValue, _swig_p) + return +} + +func (arg1 SwigcptrB) GetValue(arg2 int) (_swig_ret int) { + return _swig_wrap_B_getValue(arg1, arg2) +} + +var _wrap_new_B unsafe.Pointer + +func _swig_wrap_new_B() (base SwigcptrB) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_B, _swig_p) + return +} + +func NewB() (_swig_ret B) { + return _swig_wrap_new_B() +} + +var _wrap_delete_B unsafe.Pointer + +func _swig_wrap_delete_B(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_B, _swig_p) + return +} + +func DeleteB(arg1 B) { + _swig_wrap_delete_B(arg1.Swigcptr()) +} + +type B interface { + Swigcptr() uintptr + SwigIsB() + GetValue(arg2 int) (_swig_ret int) +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/typemap_array_qualifiers.go b/Examples/test-suite/go/typemap_array_qualifiers.go new file mode 100644 index 000000000..f73b4fb00 --- /dev/null +++ b/Examples/test-suite/go/typemap_array_qualifiers.go @@ -0,0 +1,185 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../typemap_array_qualifiers.i + +package typemap_array_qualifiers + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrSomeType uintptr + +func (p SwigcptrSomeType) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrSomeType) SwigIsSomeType() { +} + +var _wrap_SomeType_a_set unsafe.Pointer + +func _swig_wrap_SomeType_a_set(base SwigcptrSomeType, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_SomeType_a_set, _swig_p) + return +} + +func (arg1 SwigcptrSomeType) SetA(arg2 int) { + _swig_wrap_SomeType_a_set(arg1, arg2) +} + +var _wrap_SomeType_a_get unsafe.Pointer + +func _swig_wrap_SomeType_a_get(base SwigcptrSomeType) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_SomeType_a_get, _swig_p) + return +} + +func (arg1 SwigcptrSomeType) GetA() (_swig_ret int) { + return _swig_wrap_SomeType_a_get(arg1) +} + +var _wrap_new_SomeType unsafe.Pointer + +func _swig_wrap_new_SomeType() (base SwigcptrSomeType) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_SomeType, _swig_p) + return +} + +func NewSomeType() (_swig_ret SomeType) { + return _swig_wrap_new_SomeType() +} + +var _wrap_delete_SomeType unsafe.Pointer + +func _swig_wrap_delete_SomeType(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_SomeType, _swig_p) + return +} + +func DeleteSomeType(arg1 SomeType) { + _swig_wrap_delete_SomeType(arg1.Swigcptr()) +} + +type SomeType interface { + Swigcptr() uintptr + SwigIsSomeType() + SetA(arg2 int) + GetA() (_swig_ret int) +} + +var _wrap_func1a unsafe.Pointer + +func _swig_wrap_func1a(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_func1a, _swig_p) + return +} + +func Func1a(arg1 SomeType) { + _swig_wrap_func1a(arg1.Swigcptr()) +} + +var _wrap_func1b unsafe.Pointer + +func _swig_wrap_func1b(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_func1b, _swig_p) + return +} + +func Func1b(arg1 SomeType) { + _swig_wrap_func1b(arg1.Swigcptr()) +} + +var _wrap_func2a unsafe.Pointer + +func _swig_wrap_func2a(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_func2a, _swig_p) + return +} + +func Func2a(arg1 SomeType) { + _swig_wrap_func2a(arg1.Swigcptr()) +} + +var _wrap_func2b unsafe.Pointer + +func _swig_wrap_func2b(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_func2b, _swig_p) + return +} + +func Func2b(arg1 SomeType) { + _swig_wrap_func2b(arg1.Swigcptr()) +} + +var _wrap_func2c unsafe.Pointer + +func _swig_wrap_func2c(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_func2c, _swig_p) + return +} + +func Func2c(arg1 SomeType) { + _swig_wrap_func2c(arg1.Swigcptr()) +} + +var _wrap_func3a unsafe.Pointer + +func _swig_wrap_func3a(base uintptr, _ *uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_func3a, _swig_p) + return +} + +func Func3a(arg1 uintptr, arg2 *uintptr) { + _swig_wrap_func3a(arg1, arg2) +} + +var _wrap_func4a unsafe.Pointer + +func _swig_wrap_func4a(base *_swig_fnptr, _ *_swig_fnptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_func4a, _swig_p) + return +} + +func Func4a(arg1 *_swig_fnptr, arg2 *_swig_fnptr) { + _swig_wrap_func4a(arg1, arg2) +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/typemap_arrays.go b/Examples/test-suite/go/typemap_arrays.go new file mode 100644 index 000000000..65162cff7 --- /dev/null +++ b/Examples/test-suite/go/typemap_arrays.go @@ -0,0 +1,36 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../typemap_arrays.i + +package typemap_arrays + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +var _wrap_sumA unsafe.Pointer + +func SumA(arg1 **int) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_sumA, _swig_p) + return +} + diff --git a/Examples/test-suite/go/typemap_delete.go b/Examples/test-suite/go/typemap_delete.go new file mode 100644 index 000000000..a85164280 --- /dev/null +++ b/Examples/test-suite/go/typemap_delete.go @@ -0,0 +1,101 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../typemap_delete.i + +package typemap_delete + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrRect uintptr + +func (p SwigcptrRect) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrRect) SwigIsRect() { +} + +var _wrap_Rect_val_set unsafe.Pointer + +func _swig_wrap_Rect_val_set(base SwigcptrRect, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Rect_val_set, _swig_p) + return +} + +func (arg1 SwigcptrRect) SetVal(arg2 int) { + _swig_wrap_Rect_val_set(arg1, arg2) +} + +var _wrap_Rect_val_get unsafe.Pointer + +func _swig_wrap_Rect_val_get(base SwigcptrRect) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Rect_val_get, _swig_p) + return +} + +func (arg1 SwigcptrRect) GetVal() (_swig_ret int) { + return _swig_wrap_Rect_val_get(arg1) +} + +var _wrap_new_Rect unsafe.Pointer + +func _swig_wrap_new_Rect(base int) (_ SwigcptrRect) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Rect, _swig_p) + return +} + +func NewRect(arg1 int) (_swig_ret Rect) { + return _swig_wrap_new_Rect(arg1) +} + +var _wrap_delete_Rect unsafe.Pointer + +func _swig_wrap_delete_Rect(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Rect, _swig_p) + return +} + +func DeleteRect(arg1 Rect) { + _swig_wrap_delete_Rect(arg1.Swigcptr()) +} + +type Rect interface { + Swigcptr() uintptr + SwigIsRect() + SetVal(arg2 int) + GetVal() (_swig_ret int) +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/typemap_directorout.go b/Examples/test-suite/go/typemap_directorout.go new file mode 100644 index 000000000..fab73f127 --- /dev/null +++ b/Examples/test-suite/go/typemap_directorout.go @@ -0,0 +1,304 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../typemap_directorout.i + +package typemap_directorout + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type _swig_DirectorClass1 struct { + SwigcptrClass1 + v interface{} +} + +func (p *_swig_DirectorClass1) Swigcptr() uintptr { + return p.SwigcptrClass1.Swigcptr() +} + +func (p *_swig_DirectorClass1) SwigIsClass1() { +} + +func (p *_swig_DirectorClass1) DirectorInterface() interface{} { + return p.v +} + +var _wrap__swig_NewDirectorClass1Class1 unsafe.Pointer + +func _swig_NewDirectorClass1Class1(_swig_director *_swig_DirectorClass1) (_swig_ret SwigcptrClass1) { + _swig_p := uintptr(unsafe.Pointer(&_swig_director)) + _cgo_runtime_cgocall(_wrap__swig_NewDirectorClass1Class1, _swig_p) + return +} + +func NewDirectorClass1(v interface{}) Class1 { + p := &_swig_DirectorClass1{0, v} + p.SwigcptrClass1 = _swig_NewDirectorClass1Class1(p) + return p +} + +type _swig_DirectorInterfaceClass1Foo1 interface { + Foo1() *int +} + +var _wrap__swig_DirectorClass1_upcall_Foo1 unsafe.Pointer + +func _swig_wrap__swig_DirectorClass1_upcall_Foo1(_swig_ptr SwigcptrClass1) (_swig_ret *int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) + _cgo_runtime_cgocall(_wrap__swig_DirectorClass1_upcall_Foo1, _swig_p) + return +} + +func (swig_p *_swig_DirectorClass1) Foo1() *int { + if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceClass1Foo1); swig_ok { + return swig_g.Foo1() + } + var swig_r *int + swig_r = _swig_wrap__swig_DirectorClass1_upcall_Foo1(swig_p.SwigcptrClass1) + return swig_r +} + +func DirectorClass1Foo1(p Class1) *int { + var swig_r *int + swig_r = _swig_wrap__swig_DirectorClass1_upcall_Foo1(p.(*_swig_DirectorClass1).SwigcptrClass1) + return swig_r +} + +func Swig_DirectorClass1_callback_foo1(p *_swig_DirectorClass1) (swig_result *int) { + var swig_r *int + swig_r = p.Foo1() + return swig_r +} + +type _swig_DirectorInterfaceClass1Foo2__SWIG_0 interface { + Foo2__SWIG_0(int) *int +} + +var _wrap__swig_DirectorClass1_upcall_Foo2__SWIG_0 unsafe.Pointer + +func _swig_wrap__swig_DirectorClass1_upcall_Foo2__SWIG_0(_swig_ptr SwigcptrClass1, _ int) (_swig_ret *int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) + _cgo_runtime_cgocall(_wrap__swig_DirectorClass1_upcall_Foo2__SWIG_0, _swig_p) + return +} + +func (swig_p *_swig_DirectorClass1) Foo2__SWIG_0(parm1 int) *int { + if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceClass1Foo2__SWIG_0); swig_ok { + return swig_g.Foo2__SWIG_0(parm1) + } + var swig_r *int + swig_r = _swig_wrap__swig_DirectorClass1_upcall_Foo2__SWIG_0(swig_p.SwigcptrClass1, parm1) + return swig_r +} + +func DirectorClass1Foo2__SWIG_0(p Class1, arg2 int) *int { + var swig_r *int + swig_r = _swig_wrap__swig_DirectorClass1_upcall_Foo2__SWIG_0(p.(*_swig_DirectorClass1).SwigcptrClass1, arg2) + return swig_r +} + +func Swig_DirectorClass1_callback_foo2__SWIG_0(p *_swig_DirectorClass1, arg2 int) (swig_result *int) { + var swig_r *int + swig_r = p.Foo2__SWIG_0(arg2) + return swig_r +} + +type _swig_DirectorInterfaceClass1Foo2__SWIG_1 interface { + Foo2__SWIG_1() *int +} + +var _wrap__swig_DirectorClass1_upcall_Foo2__SWIG_1 unsafe.Pointer + +func _swig_wrap__swig_DirectorClass1_upcall_Foo2__SWIG_1(_swig_ptr SwigcptrClass1) (_swig_ret *int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) + _cgo_runtime_cgocall(_wrap__swig_DirectorClass1_upcall_Foo2__SWIG_1, _swig_p) + return +} + +func (swig_p *_swig_DirectorClass1) Foo2__SWIG_1() *int { + if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceClass1Foo2__SWIG_1); swig_ok { + return swig_g.Foo2__SWIG_1() + } + var swig_r *int + swig_r = _swig_wrap__swig_DirectorClass1_upcall_Foo2__SWIG_1(swig_p.SwigcptrClass1) + return swig_r +} + +func DirectorClass1Foo2__SWIG_1(p Class1) *int { + var swig_r *int + swig_r = _swig_wrap__swig_DirectorClass1_upcall_Foo2__SWIG_1(p.(*_swig_DirectorClass1).SwigcptrClass1) + return swig_r +} + +func Swig_DirectorClass1_callback_foo2__SWIG_1(p *_swig_DirectorClass1) (swig_result *int) { + var swig_r *int + swig_r = p.Foo2__SWIG_1() + return swig_r +} + +func (p _swig_DirectorClass1) Foo2(a ...interface{}) *int { + argc := len(a) + if argc == 0 { + return p.Foo2__SWIG_1() + } + if argc == 1 { + return p.Foo2__SWIG_0(a[0].(int)) + } + panic("No match for overloaded function call") +} + +func DirectorClass1Foo2(p *_swig_DirectorClass1, a ...interface{}) *int { + argc := len(a) + if argc == 0 { + return DirectorClass1Foo2__SWIG_1(p) + } + if argc == 1 { + return DirectorClass1Foo2__SWIG_0(p, a[0].(int)) + } + panic("No match for overloaded function call") +} + +var _wrap_DeleteDirectorClass1 unsafe.Pointer + +func _swig_wrap_DeleteDirectorClass1(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_DeleteDirectorClass1, _swig_p) + return +} + +func DeleteDirectorClass1(arg1 Class1) { + _swig_wrap_DeleteDirectorClass1(arg1.Swigcptr()) +} + +func Swiggo_DeleteDirector_Class1(p *_swig_DirectorClass1) { + p.SwigcptrClass1 = 0 +} + +type SwigcptrClass1 uintptr + +func (p SwigcptrClass1) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrClass1) SwigIsClass1() { +} + +func (p SwigcptrClass1) DirectorInterface() interface{} { + return nil +} + +var _wrap_new_Class1 unsafe.Pointer + +func _swig_wrap_new_Class1() (base SwigcptrClass1) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Class1, _swig_p) + return +} + +func NewClass1() (_swig_ret Class1) { + return _swig_wrap_new_Class1() +} + +var _wrap_Class1_foo1 unsafe.Pointer + +func _swig_wrap_Class1_foo1(base SwigcptrClass1) (_ *int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Class1_foo1, _swig_p) + return +} + +func (arg1 SwigcptrClass1) Foo1() (_swig_ret *int) { + return _swig_wrap_Class1_foo1(arg1) +} + +var _wrap_Class1_foo2__SWIG_0 unsafe.Pointer + +func _swig_wrap_Class1_foo2__SWIG_0(base SwigcptrClass1, _ int) (_ *int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Class1_foo2__SWIG_0, _swig_p) + return +} + +func (arg1 SwigcptrClass1) Foo2__SWIG_0(arg2 int) (_swig_ret *int) { + return _swig_wrap_Class1_foo2__SWIG_0(arg1, arg2) +} + +var _wrap_Class1_foo2__SWIG_1 unsafe.Pointer + +func _swig_wrap_Class1_foo2__SWIG_1(base SwigcptrClass1) (_ *int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Class1_foo2__SWIG_1, _swig_p) + return +} + +func (arg1 SwigcptrClass1) Foo2__SWIG_1() (_swig_ret *int) { + return _swig_wrap_Class1_foo2__SWIG_1(arg1) +} + +func (p SwigcptrClass1) Foo2(a ...interface{}) *int { + argc := len(a) + if argc == 0 { + return p.Foo2__SWIG_1() + } + if argc == 1 { + return p.Foo2__SWIG_0(a[0].(int)) + } + panic("No match for overloaded function call") +} + +var _wrap_delete_Class1 unsafe.Pointer + +func _swig_wrap_delete_Class1(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Class1, _swig_p) + return +} + +func DeleteClass1(arg1 Class1) { + _swig_wrap_delete_Class1(arg1.Swigcptr()) +} + +type Class1 interface { + Swigcptr() uintptr + SwigIsClass1() + DirectorInterface() interface{} + Foo1() (_swig_ret *int) + Foo2(a ...interface{}) *int +} + + +type SwigcptrSwigDirector_Class1 uintptr +type SwigDirector_Class1 interface { + Swigcptr() uintptr; +} +func (p SwigcptrSwigDirector_Class1) Swigcptr() uintptr { + return uintptr(p) +} + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/typemap_directorout_wrap.h b/Examples/test-suite/go/typemap_directorout_wrap.h new file mode 100644 index 000000000..52a0d06c1 --- /dev/null +++ b/Examples/test-suite/go/typemap_directorout_wrap.h @@ -0,0 +1,37 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../typemap_directorout.i + +#ifndef SWIG_typemap_directorout_WRAP_H_ +#define SWIG_typemap_directorout_WRAP_H_ + +class SwigDirector_Class1 : public Class1 +{ + public: + SwigDirector_Class1(void *swig_p); + MyType &_swig_upcall_foo1() { + return Class1::foo1(); + } + virtual MyType &foo1(); + MyType &_swig_upcall_foo2__SWIG_0(int parm1) { + return Class1::foo2(parm1); + } + virtual MyType &foo2(int parm1); + MyType &_swig_upcall_foo2__SWIG_1() { + return Class1::foo2(); + } + virtual MyType &foo2(); + virtual ~SwigDirector_Class1(); + private: + void *go_val; +}; + +#endif diff --git a/Examples/test-suite/go/typemap_global_scope.go b/Examples/test-suite/go/typemap_global_scope.go new file mode 100644 index 000000000..07d124697 --- /dev/null +++ b/Examples/test-suite/go/typemap_global_scope.go @@ -0,0 +1,1023 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../typemap_global_scope.i + +package typemap_global_scope + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrTest1 uintptr + +func (p SwigcptrTest1) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrTest1) SwigIsTest1() { +} + +var _wrap_new_Test1 unsafe.Pointer + +func _swig_wrap_new_Test1() (base SwigcptrTest1) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Test1, _swig_p) + return +} + +func NewTest1() (_swig_ret Test1) { + return _swig_wrap_new_Test1() +} + +var _wrap_delete_Test1 unsafe.Pointer + +func _swig_wrap_delete_Test1(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Test1, _swig_p) + return +} + +func DeleteTest1(arg1 Test1) { + _swig_wrap_delete_Test1(arg1.Swigcptr()) +} + +type Test1 interface { + Swigcptr() uintptr + SwigIsTest1() +} + +type SwigcptrTest2 uintptr + +func (p SwigcptrTest2) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrTest2) SwigIsTest2() { +} + +var _wrap_new_Test2 unsafe.Pointer + +func _swig_wrap_new_Test2() (base SwigcptrTest2) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Test2, _swig_p) + return +} + +func NewTest2() (_swig_ret Test2) { + return _swig_wrap_new_Test2() +} + +var _wrap_delete_Test2 unsafe.Pointer + +func _swig_wrap_delete_Test2(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Test2, _swig_p) + return +} + +func DeleteTest2(arg1 Test2) { + _swig_wrap_delete_Test2(arg1.Swigcptr()) +} + +type Test2 interface { + Swigcptr() uintptr + SwigIsTest2() +} + +type SwigcptrTest3 uintptr + +func (p SwigcptrTest3) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrTest3) SwigIsTest3() { +} + +var _wrap_new_Test3 unsafe.Pointer + +func _swig_wrap_new_Test3() (base SwigcptrTest3) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Test3, _swig_p) + return +} + +func NewTest3() (_swig_ret Test3) { + return _swig_wrap_new_Test3() +} + +var _wrap_delete_Test3 unsafe.Pointer + +func _swig_wrap_delete_Test3(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Test3, _swig_p) + return +} + +func DeleteTest3(arg1 Test3) { + _swig_wrap_delete_Test3(arg1.Swigcptr()) +} + +type Test3 interface { + Swigcptr() uintptr + SwigIsTest3() +} + +type SwigcptrTest4 uintptr + +func (p SwigcptrTest4) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrTest4) SwigIsTest4() { +} + +var _wrap_new_Test4 unsafe.Pointer + +func _swig_wrap_new_Test4() (base SwigcptrTest4) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Test4, _swig_p) + return +} + +func NewTest4() (_swig_ret Test4) { + return _swig_wrap_new_Test4() +} + +var _wrap_delete_Test4 unsafe.Pointer + +func _swig_wrap_delete_Test4(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Test4, _swig_p) + return +} + +func DeleteTest4(arg1 Test4) { + _swig_wrap_delete_Test4(arg1.Swigcptr()) +} + +type Test4 interface { + Swigcptr() uintptr + SwigIsTest4() +} + +var _wrap_test1a unsafe.Pointer + +func _swig_wrap_test1a(base uintptr, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_test1a, _swig_p) + return +} + +func Test1a(arg1 Test1, arg2 Test1) { + _swig_wrap_test1a(arg1.Swigcptr(), arg2.Swigcptr()) +} + +var _wrap_test1b unsafe.Pointer + +func _swig_wrap_test1b(base uintptr, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_test1b, _swig_p) + return +} + +func Test1b(arg1 Test1, arg2 Test1) { + _swig_wrap_test1b(arg1.Swigcptr(), arg2.Swigcptr()) +} + +var _wrap_test2a unsafe.Pointer + +func _swig_wrap_test2a(base uintptr, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_test2a, _swig_p) + return +} + +func Test2a(arg1 Test2, arg2 Test2) { + _swig_wrap_test2a(arg1.Swigcptr(), arg2.Swigcptr()) +} + +var _wrap_test2b unsafe.Pointer + +func _swig_wrap_test2b(base uintptr, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_test2b, _swig_p) + return +} + +func Test2b(arg1 Test2, arg2 Test2) { + _swig_wrap_test2b(arg1.Swigcptr(), arg2.Swigcptr()) +} + +var _wrap_test3a unsafe.Pointer + +func _swig_wrap_test3a(base uintptr, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_test3a, _swig_p) + return +} + +func Test3a(arg1 Test3, arg2 Test3) { + _swig_wrap_test3a(arg1.Swigcptr(), arg2.Swigcptr()) +} + +var _wrap_test3b unsafe.Pointer + +func _swig_wrap_test3b(base uintptr, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_test3b, _swig_p) + return +} + +func Test3b(arg1 Test3, arg2 Test3) { + _swig_wrap_test3b(arg1.Swigcptr(), arg2.Swigcptr()) +} + +var _wrap_test3c unsafe.Pointer + +func _swig_wrap_test3c(base uintptr, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_test3c, _swig_p) + return +} + +func Test3c(arg1 Test3, arg2 Test3) { + _swig_wrap_test3c(arg1.Swigcptr(), arg2.Swigcptr()) +} + +var _wrap_test3d unsafe.Pointer + +func _swig_wrap_test3d(base uintptr, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_test3d, _swig_p) + return +} + +func Test3d(arg1 Test3, arg2 Test3) { + _swig_wrap_test3d(arg1.Swigcptr(), arg2.Swigcptr()) +} + +var _wrap_test3e unsafe.Pointer + +func _swig_wrap_test3e(base uintptr, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_test3e, _swig_p) + return +} + +func Test3e(arg1 Test3, arg2 Test3) { + _swig_wrap_test3e(arg1.Swigcptr(), arg2.Swigcptr()) +} + +var _wrap_test4a unsafe.Pointer + +func _swig_wrap_test4a(base uintptr, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_test4a, _swig_p) + return +} + +func Test4a(arg1 Test4, arg2 Test4) { + _swig_wrap_test4a(arg1.Swigcptr(), arg2.Swigcptr()) +} + +var _wrap_test4b unsafe.Pointer + +func _swig_wrap_test4b(base uintptr, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_test4b, _swig_p) + return +} + +func Test4b(arg1 Test4, arg2 Test4) { + _swig_wrap_test4b(arg1.Swigcptr(), arg2.Swigcptr()) +} + +var _wrap_test4c unsafe.Pointer + +func _swig_wrap_test4c(base uintptr, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_test4c, _swig_p) + return +} + +func Test4c(arg1 Test4, arg2 Test4) { + _swig_wrap_test4c(arg1.Swigcptr(), arg2.Swigcptr()) +} + +var _wrap_test4d unsafe.Pointer + +func _swig_wrap_test4d(base uintptr, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_test4d, _swig_p) + return +} + +func Test4d(arg1 Test4, arg2 Test4) { + _swig_wrap_test4d(arg1.Swigcptr(), arg2.Swigcptr()) +} + +var _wrap_test4e unsafe.Pointer + +func _swig_wrap_test4e(base uintptr, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_test4e, _swig_p) + return +} + +func Test4e(arg1 Test4, arg2 Test4) { + _swig_wrap_test4e(arg1.Swigcptr(), arg2.Swigcptr()) +} + +type SwigcptrXX uintptr + +func (p SwigcptrXX) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrXX) SwigIsXX() { +} + +var _wrap_new_XX unsafe.Pointer + +func _swig_wrap_new_XX() (base SwigcptrXX) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_XX, _swig_p) + return +} + +func NewXX() (_swig_ret XX) { + return _swig_wrap_new_XX() +} + +var _wrap_delete_XX unsafe.Pointer + +func _swig_wrap_delete_XX(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_XX, _swig_p) + return +} + +func DeleteXX(arg1 XX) { + _swig_wrap_delete_XX(arg1.Swigcptr()) +} + +type XX interface { + Swigcptr() uintptr + SwigIsXX() +} + +type SwigcptrTemplateTest1XX uintptr + +func (p SwigcptrTemplateTest1XX) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrTemplateTest1XX) SwigIsTemplateTest1XX() { +} + +var _wrap_TemplateTest1XX_m_t_set unsafe.Pointer + +func _swig_wrap_TemplateTest1XX_m_t_set(base SwigcptrTemplateTest1XX, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_TemplateTest1XX_m_t_set, _swig_p) + return +} + +func (arg1 SwigcptrTemplateTest1XX) SetM_t(arg2 XX) { + _swig_wrap_TemplateTest1XX_m_t_set(arg1, arg2.Swigcptr()) +} + +var _wrap_TemplateTest1XX_m_t_get unsafe.Pointer + +func _swig_wrap_TemplateTest1XX_m_t_get(base SwigcptrTemplateTest1XX) (_ SwigcptrXX) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_TemplateTest1XX_m_t_get, _swig_p) + return +} + +func (arg1 SwigcptrTemplateTest1XX) GetM_t() (_swig_ret XX) { + return _swig_wrap_TemplateTest1XX_m_t_get(arg1) +} + +var _wrap_new_TemplateTest1XX unsafe.Pointer + +func _swig_wrap_new_TemplateTest1XX() (base SwigcptrTemplateTest1XX) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_TemplateTest1XX, _swig_p) + return +} + +func NewTemplateTest1XX() (_swig_ret TemplateTest1XX) { + return _swig_wrap_new_TemplateTest1XX() +} + +var _wrap_delete_TemplateTest1XX unsafe.Pointer + +func _swig_wrap_delete_TemplateTest1XX(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_TemplateTest1XX, _swig_p) + return +} + +func DeleteTemplateTest1XX(arg1 TemplateTest1XX) { + _swig_wrap_delete_TemplateTest1XX(arg1.Swigcptr()) +} + +type TemplateTest1XX interface { + Swigcptr() uintptr + SwigIsTemplateTest1XX() + SetM_t(arg2 XX) + GetM_t() (_swig_ret XX) +} + +type SwigcptrTemplateTest2XX uintptr + +func (p SwigcptrTemplateTest2XX) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrTemplateTest2XX) SwigIsTemplateTest2XX() { +} + +var _wrap_TemplateTest2XX_m_t_set unsafe.Pointer + +func _swig_wrap_TemplateTest2XX_m_t_set(base SwigcptrTemplateTest2XX, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_TemplateTest2XX_m_t_set, _swig_p) + return +} + +func (arg1 SwigcptrTemplateTest2XX) SetM_t(arg2 XX) { + _swig_wrap_TemplateTest2XX_m_t_set(arg1, arg2.Swigcptr()) +} + +var _wrap_TemplateTest2XX_m_t_get unsafe.Pointer + +func _swig_wrap_TemplateTest2XX_m_t_get(base SwigcptrTemplateTest2XX) (_ SwigcptrXX) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_TemplateTest2XX_m_t_get, _swig_p) + return +} + +func (arg1 SwigcptrTemplateTest2XX) GetM_t() (_swig_ret XX) { + return _swig_wrap_TemplateTest2XX_m_t_get(arg1) +} + +var _wrap_new_TemplateTest2XX unsafe.Pointer + +func _swig_wrap_new_TemplateTest2XX() (base SwigcptrTemplateTest2XX) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_TemplateTest2XX, _swig_p) + return +} + +func NewTemplateTest2XX() (_swig_ret TemplateTest2XX) { + return _swig_wrap_new_TemplateTest2XX() +} + +var _wrap_delete_TemplateTest2XX unsafe.Pointer + +func _swig_wrap_delete_TemplateTest2XX(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_TemplateTest2XX, _swig_p) + return +} + +func DeleteTemplateTest2XX(arg1 TemplateTest2XX) { + _swig_wrap_delete_TemplateTest2XX(arg1.Swigcptr()) +} + +type TemplateTest2XX interface { + Swigcptr() uintptr + SwigIsTemplateTest2XX() + SetM_t(arg2 XX) + GetM_t() (_swig_ret XX) +} + +type SwigcptrTemplateTest3XX uintptr + +func (p SwigcptrTemplateTest3XX) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrTemplateTest3XX) SwigIsTemplateTest3XX() { +} + +var _wrap_TemplateTest3XX_m_t_set unsafe.Pointer + +func _swig_wrap_TemplateTest3XX_m_t_set(base SwigcptrTemplateTest3XX, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_TemplateTest3XX_m_t_set, _swig_p) + return +} + +func (arg1 SwigcptrTemplateTest3XX) SetM_t(arg2 XX) { + _swig_wrap_TemplateTest3XX_m_t_set(arg1, arg2.Swigcptr()) +} + +var _wrap_TemplateTest3XX_m_t_get unsafe.Pointer + +func _swig_wrap_TemplateTest3XX_m_t_get(base SwigcptrTemplateTest3XX) (_ SwigcptrXX) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_TemplateTest3XX_m_t_get, _swig_p) + return +} + +func (arg1 SwigcptrTemplateTest3XX) GetM_t() (_swig_ret XX) { + return _swig_wrap_TemplateTest3XX_m_t_get(arg1) +} + +var _wrap_new_TemplateTest3XX unsafe.Pointer + +func _swig_wrap_new_TemplateTest3XX() (base SwigcptrTemplateTest3XX) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_TemplateTest3XX, _swig_p) + return +} + +func NewTemplateTest3XX() (_swig_ret TemplateTest3XX) { + return _swig_wrap_new_TemplateTest3XX() +} + +var _wrap_delete_TemplateTest3XX unsafe.Pointer + +func _swig_wrap_delete_TemplateTest3XX(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_TemplateTest3XX, _swig_p) + return +} + +func DeleteTemplateTest3XX(arg1 TemplateTest3XX) { + _swig_wrap_delete_TemplateTest3XX(arg1.Swigcptr()) +} + +type TemplateTest3XX interface { + Swigcptr() uintptr + SwigIsTemplateTest3XX() + SetM_t(arg2 XX) + GetM_t() (_swig_ret XX) +} + +type SwigcptrTemplateTest4XX uintptr + +func (p SwigcptrTemplateTest4XX) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrTemplateTest4XX) SwigIsTemplateTest4XX() { +} + +var _wrap_TemplateTest4XX_m_t_set unsafe.Pointer + +func _swig_wrap_TemplateTest4XX_m_t_set(base SwigcptrTemplateTest4XX, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_TemplateTest4XX_m_t_set, _swig_p) + return +} + +func (arg1 SwigcptrTemplateTest4XX) SetM_t(arg2 XX) { + _swig_wrap_TemplateTest4XX_m_t_set(arg1, arg2.Swigcptr()) +} + +var _wrap_TemplateTest4XX_m_t_get unsafe.Pointer + +func _swig_wrap_TemplateTest4XX_m_t_get(base SwigcptrTemplateTest4XX) (_ SwigcptrXX) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_TemplateTest4XX_m_t_get, _swig_p) + return +} + +func (arg1 SwigcptrTemplateTest4XX) GetM_t() (_swig_ret XX) { + return _swig_wrap_TemplateTest4XX_m_t_get(arg1) +} + +var _wrap_new_TemplateTest4XX unsafe.Pointer + +func _swig_wrap_new_TemplateTest4XX() (base SwigcptrTemplateTest4XX) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_TemplateTest4XX, _swig_p) + return +} + +func NewTemplateTest4XX() (_swig_ret TemplateTest4XX) { + return _swig_wrap_new_TemplateTest4XX() +} + +var _wrap_delete_TemplateTest4XX unsafe.Pointer + +func _swig_wrap_delete_TemplateTest4XX(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_TemplateTest4XX, _swig_p) + return +} + +func DeleteTemplateTest4XX(arg1 TemplateTest4XX) { + _swig_wrap_delete_TemplateTest4XX(arg1.Swigcptr()) +} + +type TemplateTest4XX interface { + Swigcptr() uintptr + SwigIsTemplateTest4XX() + SetM_t(arg2 XX) + GetM_t() (_swig_ret XX) +} + +var _wrap_test_template_1a unsafe.Pointer + +func _swig_wrap_test_template_1a(base uintptr, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_test_template_1a, _swig_p) + return +} + +func Test_template_1a(arg1 TemplateTest1XX, arg2 TemplateTest1XX) { + _swig_wrap_test_template_1a(arg1.Swigcptr(), arg2.Swigcptr()) +} + +var _wrap_test_template_1b unsafe.Pointer + +func _swig_wrap_test_template_1b(base uintptr, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_test_template_1b, _swig_p) + return +} + +func Test_template_1b(arg1 TemplateTest1XX, arg2 TemplateTest1XX) { + _swig_wrap_test_template_1b(arg1.Swigcptr(), arg2.Swigcptr()) +} + +var _wrap_test_template_2a unsafe.Pointer + +func _swig_wrap_test_template_2a(base uintptr, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_test_template_2a, _swig_p) + return +} + +func Test_template_2a(arg1 TemplateTest2XX, arg2 TemplateTest2XX) { + _swig_wrap_test_template_2a(arg1.Swigcptr(), arg2.Swigcptr()) +} + +var _wrap_test_template_2b unsafe.Pointer + +func _swig_wrap_test_template_2b(base uintptr, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_test_template_2b, _swig_p) + return +} + +func Test_template_2b(arg1 TemplateTest2XX, arg2 TemplateTest2XX) { + _swig_wrap_test_template_2b(arg1.Swigcptr(), arg2.Swigcptr()) +} + +var _wrap_test_template_3a unsafe.Pointer + +func _swig_wrap_test_template_3a(base uintptr, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_test_template_3a, _swig_p) + return +} + +func Test_template_3a(arg1 TemplateTest3XX, arg2 TemplateTest3XX) { + _swig_wrap_test_template_3a(arg1.Swigcptr(), arg2.Swigcptr()) +} + +var _wrap_test_template_3b unsafe.Pointer + +func _swig_wrap_test_template_3b(base uintptr, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_test_template_3b, _swig_p) + return +} + +func Test_template_3b(arg1 TemplateTest3XX, arg2 TemplateTest3XX) { + _swig_wrap_test_template_3b(arg1.Swigcptr(), arg2.Swigcptr()) +} + +var _wrap_test_template_3c unsafe.Pointer + +func _swig_wrap_test_template_3c(base uintptr, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_test_template_3c, _swig_p) + return +} + +func Test_template_3c(arg1 TemplateTest3XX, arg2 TemplateTest3XX) { + _swig_wrap_test_template_3c(arg1.Swigcptr(), arg2.Swigcptr()) +} + +var _wrap_test_template_3d unsafe.Pointer + +func _swig_wrap_test_template_3d(base uintptr, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_test_template_3d, _swig_p) + return +} + +func Test_template_3d(arg1 TemplateTest3XX, arg2 TemplateTest3XX) { + _swig_wrap_test_template_3d(arg1.Swigcptr(), arg2.Swigcptr()) +} + +var _wrap_test_template_3e unsafe.Pointer + +func _swig_wrap_test_template_3e(base uintptr, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_test_template_3e, _swig_p) + return +} + +func Test_template_3e(arg1 TemplateTest3XX, arg2 TemplateTest3XX) { + _swig_wrap_test_template_3e(arg1.Swigcptr(), arg2.Swigcptr()) +} + +var _wrap_test_template_4a unsafe.Pointer + +func _swig_wrap_test_template_4a(base uintptr, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_test_template_4a, _swig_p) + return +} + +func Test_template_4a(arg1 TemplateTest4XX, arg2 TemplateTest4XX) { + _swig_wrap_test_template_4a(arg1.Swigcptr(), arg2.Swigcptr()) +} + +var _wrap_test_template_4b unsafe.Pointer + +func _swig_wrap_test_template_4b(base uintptr, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_test_template_4b, _swig_p) + return +} + +func Test_template_4b(arg1 TemplateTest4XX, arg2 TemplateTest4XX) { + _swig_wrap_test_template_4b(arg1.Swigcptr(), arg2.Swigcptr()) +} + +var _wrap_test_template_4c unsafe.Pointer + +func _swig_wrap_test_template_4c(base uintptr, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_test_template_4c, _swig_p) + return +} + +func Test_template_4c(arg1 TemplateTest4XX, arg2 TemplateTest4XX) { + _swig_wrap_test_template_4c(arg1.Swigcptr(), arg2.Swigcptr()) +} + +var _wrap_test_template_4d unsafe.Pointer + +func _swig_wrap_test_template_4d(base uintptr, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_test_template_4d, _swig_p) + return +} + +func Test_template_4d(arg1 TemplateTest4XX, arg2 TemplateTest4XX) { + _swig_wrap_test_template_4d(arg1.Swigcptr(), arg2.Swigcptr()) +} + +var _wrap_test_template_4e unsafe.Pointer + +func _swig_wrap_test_template_4e(base uintptr, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_test_template_4e, _swig_p) + return +} + +func Test_template_4e(arg1 TemplateTest4XX, arg2 TemplateTest4XX) { + _swig_wrap_test_template_4e(arg1.Swigcptr(), arg2.Swigcptr()) +} + +type Enum1 int +var _wrap_enum_1 unsafe.Pointer + +func _swig_getenum_1() (_swig_ret Enum1) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_enum_1, _swig_p) + return +} +var Enum_1 Enum1 = _swig_getenum_1() +type Enum2 int +var _wrap_enum_2 unsafe.Pointer + +func _swig_getenum_2() (_swig_ret Enum2) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_enum_2, _swig_p) + return +} +var Enum_2 Enum2 = _swig_getenum_2() +type SpaceEnum3 int +var _wrap_enum_3 unsafe.Pointer + +func _swig_getenum_3() (_swig_ret SpaceEnum3) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_enum_3, _swig_p) + return +} +var Enum_3 SpaceEnum3 = _swig_getenum_3() +type SpaceEnum4 int +var _wrap_enum_4 unsafe.Pointer + +func _swig_getenum_4() (_swig_ret SpaceEnum4) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_enum_4, _swig_p) + return +} +var Enum_4 SpaceEnum4 = _swig_getenum_4() +var _wrap_test_enum_1a unsafe.Pointer + +func _swig_wrap_test_enum_1a(base Enum1, _ *Enum1) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_test_enum_1a, _swig_p) + return +} + +func Test_enum_1a(arg1 Enum1, arg2 *Enum1) { + _swig_wrap_test_enum_1a(arg1, arg2) +} + +var _wrap_test_enum_1b unsafe.Pointer + +func _swig_wrap_test_enum_1b(base Enum1, _ *Enum1) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_test_enum_1b, _swig_p) + return +} + +func Test_enum_1b(arg1 Enum1, arg2 *Enum1) { + _swig_wrap_test_enum_1b(arg1, arg2) +} + +var _wrap_test_enum_2a unsafe.Pointer + +func _swig_wrap_test_enum_2a(base Enum2, _ *Enum2) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_test_enum_2a, _swig_p) + return +} + +func Test_enum_2a(arg1 Enum2, arg2 *Enum2) { + _swig_wrap_test_enum_2a(arg1, arg2) +} + +var _wrap_test_enum_2b unsafe.Pointer + +func _swig_wrap_test_enum_2b(base Enum2, _ *Enum2) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_test_enum_2b, _swig_p) + return +} + +func Test_enum_2b(arg1 Enum2, arg2 *Enum2) { + _swig_wrap_test_enum_2b(arg1, arg2) +} + +var _wrap_test_enum_3a unsafe.Pointer + +func _swig_wrap_test_enum_3a(base SpaceEnum3, _ *SpaceEnum3) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_test_enum_3a, _swig_p) + return +} + +func Test_enum_3a(arg1 SpaceEnum3, arg2 *SpaceEnum3) { + _swig_wrap_test_enum_3a(arg1, arg2) +} + +var _wrap_test_enum_3b unsafe.Pointer + +func _swig_wrap_test_enum_3b(base SpaceEnum3, _ *SpaceEnum3) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_test_enum_3b, _swig_p) + return +} + +func Test_enum_3b(arg1 SpaceEnum3, arg2 *SpaceEnum3) { + _swig_wrap_test_enum_3b(arg1, arg2) +} + +var _wrap_test_enum_3c unsafe.Pointer + +func _swig_wrap_test_enum_3c(base SpaceEnum3, _ *SpaceEnum3) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_test_enum_3c, _swig_p) + return +} + +func Test_enum_3c(arg1 SpaceEnum3, arg2 *SpaceEnum3) { + _swig_wrap_test_enum_3c(arg1, arg2) +} + +var _wrap_test_enum_3d unsafe.Pointer + +func _swig_wrap_test_enum_3d(base SpaceEnum3, _ *SpaceEnum3) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_test_enum_3d, _swig_p) + return +} + +func Test_enum_3d(arg1 SpaceEnum3, arg2 *SpaceEnum3) { + _swig_wrap_test_enum_3d(arg1, arg2) +} + +var _wrap_test_enum_3e unsafe.Pointer + +func _swig_wrap_test_enum_3e(base SpaceEnum3, _ *SpaceEnum3) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_test_enum_3e, _swig_p) + return +} + +func Test_enum_3e(arg1 SpaceEnum3, arg2 *SpaceEnum3) { + _swig_wrap_test_enum_3e(arg1, arg2) +} + +var _wrap_test_enum_4a unsafe.Pointer + +func _swig_wrap_test_enum_4a(base SpaceEnum4, _ *SpaceEnum4) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_test_enum_4a, _swig_p) + return +} + +func Test_enum_4a(arg1 SpaceEnum4, arg2 *SpaceEnum4) { + _swig_wrap_test_enum_4a(arg1, arg2) +} + +var _wrap_test_enum_4b unsafe.Pointer + +func _swig_wrap_test_enum_4b(base SpaceEnum4, _ *SpaceEnum4) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_test_enum_4b, _swig_p) + return +} + +func Test_enum_4b(arg1 SpaceEnum4, arg2 *SpaceEnum4) { + _swig_wrap_test_enum_4b(arg1, arg2) +} + +var _wrap_test_enum_4c unsafe.Pointer + +func _swig_wrap_test_enum_4c(base SpaceEnum4, _ *SpaceEnum4) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_test_enum_4c, _swig_p) + return +} + +func Test_enum_4c(arg1 SpaceEnum4, arg2 *SpaceEnum4) { + _swig_wrap_test_enum_4c(arg1, arg2) +} + +var _wrap_test_enum_4d unsafe.Pointer + +func _swig_wrap_test_enum_4d(base SpaceEnum4, _ *SpaceEnum4) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_test_enum_4d, _swig_p) + return +} + +func Test_enum_4d(arg1 SpaceEnum4, arg2 *SpaceEnum4) { + _swig_wrap_test_enum_4d(arg1, arg2) +} + +var _wrap_test_enum_4e unsafe.Pointer + +func _swig_wrap_test_enum_4e(base SpaceEnum4, _ *SpaceEnum4) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_test_enum_4e, _swig_p) + return +} + +func Test_enum_4e(arg1 SpaceEnum4, arg2 *SpaceEnum4) { + _swig_wrap_test_enum_4e(arg1, arg2) +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/typemap_manyargs.go b/Examples/test-suite/go/typemap_manyargs.go new file mode 100644 index 000000000..8bae3e56e --- /dev/null +++ b/Examples/test-suite/go/typemap_manyargs.go @@ -0,0 +1,49 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../typemap_manyargs.i + +package typemap_manyargs + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +var _wrap_my_c_function unsafe.Pointer + +func _swig_wrap_my_c_function(base string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_my_c_function, _swig_p) + return +} + +func My_c_function(arg1 string) { + _swig_wrap_my_c_function(arg1) +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/typemap_namespace.go b/Examples/test-suite/go/typemap_namespace.go new file mode 100644 index 000000000..caec22758 --- /dev/null +++ b/Examples/test-suite/go/typemap_namespace.go @@ -0,0 +1,43 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../typemap_namespace.i + +package typemap_namespace + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +var _wrap_test1 unsafe.Pointer + +func Test1(arg1 string) (_swig_ret string) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_test1, _swig_p) + return +} +var _wrap_test2 unsafe.Pointer + +func Test2(arg1 string) (_swig_ret string) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_test2, _swig_p) + return +} + diff --git a/Examples/test-suite/go/typemap_namespace_runme b/Examples/test-suite/go/typemap_namespace_runme new file mode 100755 index 000000000..b4bed3d2b Binary files /dev/null and b/Examples/test-suite/go/typemap_namespace_runme differ diff --git a/Examples/test-suite/go/typemap_ns_using.go b/Examples/test-suite/go/typemap_ns_using.go new file mode 100644 index 000000000..851582b32 --- /dev/null +++ b/Examples/test-suite/go/typemap_ns_using.go @@ -0,0 +1,82 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../typemap_ns_using.i + +package typemap_ns_using + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrX_FooImpl uintptr + +func (p SwigcptrX_FooImpl) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrX_FooImpl) SwigIsX_FooImpl() { +} + +var _wrap_new__FooImpl unsafe.Pointer + +func _swig_wrap_new__FooImpl() (base SwigcptrX_FooImpl) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new__FooImpl, _swig_p) + return +} + +func NewX_FooImpl() (_swig_ret X_FooImpl) { + return _swig_wrap_new__FooImpl() +} + +var _wrap_delete__FooImpl unsafe.Pointer + +func _swig_wrap_delete__FooImpl(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete__FooImpl, _swig_p) + return +} + +func DeleteX_FooImpl(arg1 X_FooImpl) { + _swig_wrap_delete__FooImpl(arg1.Swigcptr()) +} + +type X_FooImpl interface { + Swigcptr() uintptr + SwigIsX_FooImpl() +} + +var _wrap_spam unsafe.Pointer + +func Spam(arg1 int) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_spam, _swig_p) + return +} + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/typemap_ns_using_runme b/Examples/test-suite/go/typemap_ns_using_runme new file mode 100755 index 000000000..7bc202cbe Binary files /dev/null and b/Examples/test-suite/go/typemap_ns_using_runme differ diff --git a/Examples/test-suite/go/typemap_numinputs.go b/Examples/test-suite/go/typemap_numinputs.go new file mode 100644 index 000000000..a5314ccfa --- /dev/null +++ b/Examples/test-suite/go/typemap_numinputs.go @@ -0,0 +1,36 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../typemap_numinputs.i + +package typemap_numinputs + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +var _wrap_this_breaks unsafe.Pointer + +func This_breaks(arg1 int, arg2 string, arg3 *int) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_this_breaks, _swig_p) + return +} + diff --git a/Examples/test-suite/go/typemap_out_optimal.go b/Examples/test-suite/go/typemap_out_optimal.go new file mode 100644 index 000000000..361ee0462 --- /dev/null +++ b/Examples/test-suite/go/typemap_out_optimal.go @@ -0,0 +1,148 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../typemap_out_optimal.i + +package typemap_out_optimal + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrXX uintptr + +func (p SwigcptrXX) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrXX) SwigIsXX() { +} + +var _wrap_new_XX__SWIG_0 unsafe.Pointer + +func _swig_wrap_new_XX__SWIG_0() (base SwigcptrXX) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_XX__SWIG_0, _swig_p) + return +} + +func NewXX__SWIG_0() (_swig_ret XX) { + return _swig_wrap_new_XX__SWIG_0() +} + +var _wrap_new_XX__SWIG_1 unsafe.Pointer + +func _swig_wrap_new_XX__SWIG_1(base int) (_ SwigcptrXX) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_XX__SWIG_1, _swig_p) + return +} + +func NewXX__SWIG_1(arg1 int) (_swig_ret XX) { + return _swig_wrap_new_XX__SWIG_1(arg1) +} + +var _wrap_new_XX__SWIG_2 unsafe.Pointer + +func _swig_wrap_new_XX__SWIG_2(base uintptr) (_ SwigcptrXX) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_XX__SWIG_2, _swig_p) + return +} + +func NewXX__SWIG_2(arg1 XX) (_swig_ret XX) { + return _swig_wrap_new_XX__SWIG_2(arg1.Swigcptr()) +} + +func NewXX(a ...interface{}) XX { + argc := len(a) + if argc == 0 { + return NewXX__SWIG_0() + } + if argc == 1 { + if _, ok := a[0].(XX); !ok { + goto check_2 + } + return NewXX__SWIG_2(a[0].(XX)) + } +check_2: + if argc == 1 { + return NewXX__SWIG_1(a[0].(int)) + } + panic("No match for overloaded function call") +} + +var _wrap_delete_XX unsafe.Pointer + +func _swig_wrap_delete_XX(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_XX, _swig_p) + return +} + +func DeleteXX(arg1 XX) { + _swig_wrap_delete_XX(arg1.Swigcptr()) +} + +var _wrap_XX_create unsafe.Pointer + +func _swig_wrap_XX_create() (base SwigcptrXX) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_XX_create, _swig_p) + return +} + +func XXCreate() (_swig_ret XX) { + return _swig_wrap_XX_create() +} + +var _wrap_XX_debug_set unsafe.Pointer + +func _swig_wrap_XX_debug_set(base bool) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_XX_debug_set, _swig_p) + return +} + +func SetXXDebug(arg1 bool) { + _swig_wrap_XX_debug_set(arg1) +} + +var _wrap_XX_debug_get unsafe.Pointer + +func GetXXDebug() (_swig_ret bool) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_XX_debug_get, _swig_p) + return +} +type XX interface { + Swigcptr() uintptr + SwigIsXX() +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/typemap_out_optimal_runme b/Examples/test-suite/go/typemap_out_optimal_runme new file mode 100755 index 000000000..b452264c7 Binary files /dev/null and b/Examples/test-suite/go/typemap_out_optimal_runme differ diff --git a/Examples/test-suite/go/typemap_qualifier_strip.go b/Examples/test-suite/go/typemap_qualifier_strip.go new file mode 100644 index 000000000..ef57b4d3b --- /dev/null +++ b/Examples/test-suite/go/typemap_qualifier_strip.go @@ -0,0 +1,148 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../typemap_qualifier_strip.i + +package typemap_qualifier_strip + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +var _wrap_create_int unsafe.Pointer + +func Create_int(arg1 int) (_swig_ret *int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_create_int, _swig_p) + return +} +var _wrap_testA1 unsafe.Pointer + +func TestA1(arg1 *int) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_testA1, _swig_p) + return +} +var _wrap_testA2 unsafe.Pointer + +func TestA2(arg1 *int) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_testA2, _swig_p) + return +} +var _wrap_testA3 unsafe.Pointer + +func TestA3(arg1 *int) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_testA3, _swig_p) + return +} +var _wrap_testA4 unsafe.Pointer + +func TestA4(arg1 *int) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_testA4, _swig_p) + return +} +var _wrap_testB1 unsafe.Pointer + +func TestB1(arg1 *int) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_testB1, _swig_p) + return +} +var _wrap_testB2 unsafe.Pointer + +func TestB2(arg1 *int) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_testB2, _swig_p) + return +} +var _wrap_testB3 unsafe.Pointer + +func TestB3(arg1 *int) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_testB3, _swig_p) + return +} +var _wrap_testB4 unsafe.Pointer + +func TestB4(arg1 *int) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_testB4, _swig_p) + return +} +var _wrap_testC1 unsafe.Pointer + +func TestC1(arg1 *int) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_testC1, _swig_p) + return +} +var _wrap_testC2 unsafe.Pointer + +func TestC2(arg1 *int) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_testC2, _swig_p) + return +} +var _wrap_testC3 unsafe.Pointer + +func TestC3(arg1 *int) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_testC3, _swig_p) + return +} +var _wrap_testC4 unsafe.Pointer + +func TestC4(arg1 *int) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_testC4, _swig_p) + return +} +var _wrap_testD1 unsafe.Pointer + +func TestD1(arg1 *int) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_testD1, _swig_p) + return +} +var _wrap_testD2 unsafe.Pointer + +func TestD2(arg1 *int) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_testD2, _swig_p) + return +} +var _wrap_testD3 unsafe.Pointer + +func TestD3(arg1 *int) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_testD3, _swig_p) + return +} +var _wrap_testD4 unsafe.Pointer + +func TestD4(arg1 *int) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_testD4, _swig_p) + return +} + diff --git a/Examples/test-suite/go/typemap_subst.go b/Examples/test-suite/go/typemap_subst.go new file mode 100644 index 000000000..3f6a6d65a --- /dev/null +++ b/Examples/test-suite/go/typemap_subst.go @@ -0,0 +1,101 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../typemap_subst.i + +package typemap_subst + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrXyzzy uintptr + +func (p SwigcptrXyzzy) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrXyzzy) SwigIsXyzzy() { +} + +var _wrap_xyzzy_member_set unsafe.Pointer + +func _swig_wrap_xyzzy_member_set(base SwigcptrXyzzy, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_xyzzy_member_set, _swig_p) + return +} + +func (arg1 SwigcptrXyzzy) SetMember(arg2 int) { + _swig_wrap_xyzzy_member_set(arg1, arg2) +} + +var _wrap_xyzzy_member_get unsafe.Pointer + +func _swig_wrap_xyzzy_member_get(base SwigcptrXyzzy) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_xyzzy_member_get, _swig_p) + return +} + +func (arg1 SwigcptrXyzzy) GetMember() (_swig_ret int) { + return _swig_wrap_xyzzy_member_get(arg1) +} + +var _wrap_new_xyzzy unsafe.Pointer + +func _swig_wrap_new_xyzzy() (base SwigcptrXyzzy) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_xyzzy, _swig_p) + return +} + +func NewXyzzy() (_swig_ret Xyzzy) { + return _swig_wrap_new_xyzzy() +} + +var _wrap_delete_xyzzy unsafe.Pointer + +func _swig_wrap_delete_xyzzy(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_xyzzy, _swig_p) + return +} + +func DeleteXyzzy(arg1 Xyzzy) { + _swig_wrap_delete_xyzzy(arg1.Swigcptr()) +} + +type Xyzzy interface { + Swigcptr() uintptr + SwigIsXyzzy() + SetMember(arg2 int) + GetMember() (_swig_ret int) +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/typemap_template.go b/Examples/test-suite/go/typemap_template.go new file mode 100644 index 000000000..ac35894b3 --- /dev/null +++ b/Examples/test-suite/go/typemap_template.go @@ -0,0 +1,290 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../typemap_template.i + +package typemap_template + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrYY uintptr + +func (p SwigcptrYY) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrYY) SwigIsYY() { +} + +var _wrap_new_YY unsafe.Pointer + +func _swig_wrap_new_YY() (base SwigcptrYY) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_YY, _swig_p) + return +} + +func NewYY() (_swig_ret YY) { + return _swig_wrap_new_YY() +} + +var _wrap_delete_YY unsafe.Pointer + +func _swig_wrap_delete_YY(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_YY, _swig_p) + return +} + +func DeleteYY(arg1 YY) { + _swig_wrap_delete_YY(arg1.Swigcptr()) +} + +type YY interface { + Swigcptr() uintptr + SwigIsYY() +} + +type SwigcptrZZ uintptr + +func (p SwigcptrZZ) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrZZ) SwigIsZZ() { +} + +var _wrap_new_ZZ unsafe.Pointer + +func _swig_wrap_new_ZZ() (base SwigcptrZZ) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_ZZ, _swig_p) + return +} + +func NewZZ() (_swig_ret ZZ) { + return _swig_wrap_new_ZZ() +} + +var _wrap_delete_ZZ unsafe.Pointer + +func _swig_wrap_delete_ZZ(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_ZZ, _swig_p) + return +} + +func DeleteZZ(arg1 ZZ) { + _swig_wrap_delete_ZZ(arg1.Swigcptr()) +} + +type ZZ interface { + Swigcptr() uintptr + SwigIsZZ() +} + +type SwigcptrTTYY uintptr + +func (p SwigcptrTTYY) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrTTYY) SwigIsTTYY() { +} + +var _wrap_TTYY_setT unsafe.Pointer + +func _swig_wrap_TTYY_setT(base SwigcptrTTYY, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_TTYY_setT, _swig_p) + return +} + +func (arg1 SwigcptrTTYY) SetT(arg2 TTYY) { + _swig_wrap_TTYY_setT(arg1, arg2.Swigcptr()) +} + +var _wrap_new_TTYY unsafe.Pointer + +func _swig_wrap_new_TTYY() (base SwigcptrTTYY) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_TTYY, _swig_p) + return +} + +func NewTTYY() (_swig_ret TTYY) { + return _swig_wrap_new_TTYY() +} + +var _wrap_delete_TTYY unsafe.Pointer + +func _swig_wrap_delete_TTYY(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_TTYY, _swig_p) + return +} + +func DeleteTTYY(arg1 TTYY) { + _swig_wrap_delete_TTYY(arg1.Swigcptr()) +} + +type TTYY interface { + Swigcptr() uintptr + SwigIsTTYY() + SetT(arg2 TTYY) +} + +type SwigcptrTTZZ uintptr + +func (p SwigcptrTTZZ) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrTTZZ) SwigIsTTZZ() { +} + +var _wrap_TTZZ_setT unsafe.Pointer + +func _swig_wrap_TTZZ_setT(base SwigcptrTTZZ, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_TTZZ_setT, _swig_p) + return +} + +func (arg1 SwigcptrTTZZ) SetT(arg2 TTZZ) { + _swig_wrap_TTZZ_setT(arg1, arg2.Swigcptr()) +} + +var _wrap_new_TTZZ unsafe.Pointer + +func _swig_wrap_new_TTZZ() (base SwigcptrTTZZ) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_TTZZ, _swig_p) + return +} + +func NewTTZZ() (_swig_ret TTZZ) { + return _swig_wrap_new_TTZZ() +} + +var _wrap_delete_TTZZ unsafe.Pointer + +func _swig_wrap_delete_TTZZ(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_TTZZ, _swig_p) + return +} + +func DeleteTTZZ(arg1 TTZZ) { + _swig_wrap_delete_TTZZ(arg1.Swigcptr()) +} + +type TTZZ interface { + Swigcptr() uintptr + SwigIsTTZZ() + SetT(arg2 TTZZ) +} + +type SwigcptrTTint uintptr + +func (p SwigcptrTTint) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrTTint) SwigIsTTint() { +} + +var _wrap_TTint_setT unsafe.Pointer + +func _swig_wrap_TTint_setT(base SwigcptrTTint, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_TTint_setT, _swig_p) + return +} + +func (arg1 SwigcptrTTint) SetT(arg2 TTint) { + _swig_wrap_TTint_setT(arg1, arg2.Swigcptr()) +} + +var _wrap_new_TTint unsafe.Pointer + +func _swig_wrap_new_TTint() (base SwigcptrTTint) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_TTint, _swig_p) + return +} + +func NewTTint() (_swig_ret TTint) { + return _swig_wrap_new_TTint() +} + +var _wrap_delete_TTint unsafe.Pointer + +func _swig_wrap_delete_TTint(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_TTint, _swig_p) + return +} + +func DeleteTTint(arg1 TTint) { + _swig_wrap_delete_TTint(arg1.Swigcptr()) +} + +type TTint interface { + Swigcptr() uintptr + SwigIsTTint() + SetT(arg2 TTint) +} + +var _wrap_extratest unsafe.Pointer + +func _swig_wrap_extratest(base uintptr, _ uintptr, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_extratest, _swig_p) + return +} + +func Extratest(arg1 TTYY, arg2 TTZZ, arg3 TTint) { + _swig_wrap_extratest(arg1.Swigcptr(), arg2.Swigcptr(), arg3.Swigcptr()) +} + +var _wrap_wasbug unsafe.Pointer + +func _swig_wrap_wasbug(base float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_wasbug, _swig_p) + return +} + +func Wasbug(arg1 float64) { + _swig_wrap_wasbug(arg1) +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/typemap_template_parm_typedef.go b/Examples/test-suite/go/typemap_template_parm_typedef.go new file mode 100644 index 000000000..4e374d2f1 --- /dev/null +++ b/Examples/test-suite/go/typemap_template_parm_typedef.go @@ -0,0 +1,97 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../typemap_template_parm_typedef.i + +package typemap_template_parm_typedef + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +var _wrap_test_no_typedef unsafe.Pointer + +func _swig_wrap_test_no_typedef(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_test_no_typedef, _swig_p) + return +} + +func Test_no_typedef(arg1 Std_list_Sl_unsigned_SS_int_Sg_) { + _swig_wrap_test_no_typedef(arg1.Swigcptr()) +} + +var _wrap_test_typedef unsafe.Pointer + +func _swig_wrap_test_typedef(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_test_typedef, _swig_p) + return +} + +func Test_typedef(arg1 Std_vector_Sl_unsigned_SS_int_Sg_) { + _swig_wrap_test_typedef(arg1.Swigcptr()) +} + +var _wrap_no_typedef_out unsafe.Pointer + +func _swig_wrap_no_typedef_out() (base SwigcptrStd_deque_Sl_unsigned_SS_int_Sg_) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_no_typedef_out, _swig_p) + return +} + +func No_typedef_out() (_swig_ret Std_deque_Sl_unsigned_SS_int_Sg_) { + return _swig_wrap_no_typedef_out() +} + + +type SwigcptrStd_list_Sl_unsigned_SS_int_Sg_ uintptr +type Std_list_Sl_unsigned_SS_int_Sg_ interface { + Swigcptr() uintptr; +} +func (p SwigcptrStd_list_Sl_unsigned_SS_int_Sg_) Swigcptr() uintptr { + return uintptr(p) +} + +type SwigcptrStd_vector_Sl_unsigned_SS_int_Sg_ uintptr +type Std_vector_Sl_unsigned_SS_int_Sg_ interface { + Swigcptr() uintptr; +} +func (p SwigcptrStd_vector_Sl_unsigned_SS_int_Sg_) Swigcptr() uintptr { + return uintptr(p) +} + +type SwigcptrStd_deque_Sl_unsigned_SS_int_Sg_ uintptr +type Std_deque_Sl_unsigned_SS_int_Sg_ interface { + Swigcptr() uintptr; +} +func (p SwigcptrStd_deque_Sl_unsigned_SS_int_Sg_) Swigcptr() uintptr { + return uintptr(p) +} + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/typemap_variables.go b/Examples/test-suite/go/typemap_variables.go new file mode 100644 index 000000000..6fa825c75 --- /dev/null +++ b/Examples/test-suite/go/typemap_variables.go @@ -0,0 +1,158 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../typemap_variables.i + +package typemap_variables + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +var _wrap_globul_set unsafe.Pointer + +func _swig_wrap_globul_set(base int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_globul_set, _swig_p) + return +} + +func SetGlobul(arg1 int) { + _swig_wrap_globul_set(arg1) +} + +var _wrap_globul_get unsafe.Pointer + +func GetGlobul() (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_globul_get, _swig_p) + return +} +var _wrap_nspace_set unsafe.Pointer + +func _swig_wrap_nspace_set(base int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_nspace_set, _swig_p) + return +} + +func SetNspace(arg1 int) { + _swig_wrap_nspace_set(arg1) +} + +var _wrap_nspace_get unsafe.Pointer + +func GetNspace() (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_nspace_get, _swig_p) + return +} +type SwigcptrStruct uintptr + +func (p SwigcptrStruct) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrStruct) SwigIsStruct() { +} + +var _wrap_Struct_member_set unsafe.Pointer + +func _swig_wrap_Struct_member_set(base SwigcptrStruct, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Struct_member_set, _swig_p) + return +} + +func (arg1 SwigcptrStruct) SetMember(arg2 int) { + _swig_wrap_Struct_member_set(arg1, arg2) +} + +var _wrap_Struct_member_get unsafe.Pointer + +func _swig_wrap_Struct_member_get(base SwigcptrStruct) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Struct_member_get, _swig_p) + return +} + +func (arg1 SwigcptrStruct) GetMember() (_swig_ret int) { + return _swig_wrap_Struct_member_get(arg1) +} + +var _wrap_Struct_smember_set unsafe.Pointer + +func _swig_wrap_Struct_smember_set(base int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Struct_smember_set, _swig_p) + return +} + +func SetStructSmember(arg1 int) { + _swig_wrap_Struct_smember_set(arg1) +} + +var _wrap_Struct_smember_get unsafe.Pointer + +func GetStructSmember() (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_Struct_smember_get, _swig_p) + return +} +var _wrap_new_Struct unsafe.Pointer + +func _swig_wrap_new_Struct() (base SwigcptrStruct) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Struct, _swig_p) + return +} + +func NewStruct() (_swig_ret Struct) { + return _swig_wrap_new_Struct() +} + +var _wrap_delete_Struct unsafe.Pointer + +func _swig_wrap_delete_Struct(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Struct, _swig_p) + return +} + +func DeleteStruct(arg1 Struct) { + _swig_wrap_delete_Struct(arg1.Swigcptr()) +} + +type Struct interface { + Swigcptr() uintptr + SwigIsStruct() + SetMember(arg2 int) + GetMember() (_swig_ret int) +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/typemap_various.go b/Examples/test-suite/go/typemap_various.go new file mode 100644 index 000000000..521380b80 --- /dev/null +++ b/Examples/test-suite/go/typemap_various.go @@ -0,0 +1,363 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../typemap_various.i + +package typemap_various + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrFooInt uintptr + +func (p SwigcptrFooInt) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrFooInt) SwigIsFooInt() { +} + +var _wrap_new_FooInt unsafe.Pointer + +func _swig_wrap_new_FooInt() (base SwigcptrFooInt) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_FooInt, _swig_p) + return +} + +func NewFooInt() (_swig_ret FooInt) { + return _swig_wrap_new_FooInt() +} + +var _wrap_delete_FooInt unsafe.Pointer + +func _swig_wrap_delete_FooInt(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_FooInt, _swig_p) + return +} + +func DeleteFooInt(arg1 FooInt) { + _swig_wrap_delete_FooInt(arg1.Swigcptr()) +} + +type FooInt interface { + Swigcptr() uintptr + SwigIsFooInt() +} + +var _wrap_foo1 unsafe.Pointer + +func _swig_wrap_foo1(base uintptr, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_foo1, _swig_p) + return +} + +func Foo1(arg1 FooInt, arg2 FooInt) { + _swig_wrap_foo1(arg1.Swigcptr(), arg2.Swigcptr()) +} + +var _wrap_foo2 unsafe.Pointer + +func _swig_wrap_foo2(base uintptr, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_foo2, _swig_p) + return +} + +func Foo2(arg1 Foo_Sl_short_Sg_, arg2 Foo_Sl_short_Sg_) { + _swig_wrap_foo2(arg1.Swigcptr(), arg2.Swigcptr()) +} + +type SwigcptrBar1 uintptr + +func (p SwigcptrBar1) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrBar1) SwigIsBar1() { +} + +var _wrap_Bar1_foo unsafe.Pointer + +func _swig_wrap_Bar1_foo(base SwigcptrBar1) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Bar1_foo, _swig_p) + return +} + +func (arg1 SwigcptrBar1) Foo() (_swig_ret int) { + return _swig_wrap_Bar1_foo(arg1) +} + +var _wrap_new_Bar1 unsafe.Pointer + +func _swig_wrap_new_Bar1() (base SwigcptrBar1) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Bar1, _swig_p) + return +} + +func NewBar1() (_swig_ret Bar1) { + return _swig_wrap_new_Bar1() +} + +var _wrap_delete_Bar1 unsafe.Pointer + +func _swig_wrap_delete_Bar1(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Bar1, _swig_p) + return +} + +func DeleteBar1(arg1 Bar1) { + _swig_wrap_delete_Bar1(arg1.Swigcptr()) +} + +type Bar1 interface { + Swigcptr() uintptr + SwigIsBar1() + Foo() (_swig_ret int) +} + +type SwigcptrBar2 uintptr + +func (p SwigcptrBar2) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrBar2) SwigIsBar2() { +} + +var _wrap_Bar2_foo unsafe.Pointer + +func _swig_wrap_Bar2_foo(base SwigcptrBar2) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Bar2_foo, _swig_p) + return +} + +func (arg1 SwigcptrBar2) Foo() (_swig_ret int) { + return _swig_wrap_Bar2_foo(arg1) +} + +var _wrap_new_Bar2 unsafe.Pointer + +func _swig_wrap_new_Bar2() (base SwigcptrBar2) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Bar2, _swig_p) + return +} + +func NewBar2() (_swig_ret Bar2) { + return _swig_wrap_new_Bar2() +} + +var _wrap_delete_Bar2 unsafe.Pointer + +func _swig_wrap_delete_Bar2(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Bar2, _swig_p) + return +} + +func DeleteBar2(arg1 Bar2) { + _swig_wrap_delete_Bar2(arg1.Swigcptr()) +} + +type Bar2 interface { + Swigcptr() uintptr + SwigIsBar2() + Foo() (_swig_ret int) +} + +type SwigcptrFFoo uintptr + +func (p SwigcptrFFoo) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrFFoo) SwigIsFFoo() { +} + +var _wrap_FFoo_Bar unsafe.Pointer + +func _swig_wrap_FFoo_Bar(base SwigcptrFFoo, _ bool) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_FFoo_Bar, _swig_p) + return +} + +func (arg1 SwigcptrFFoo) Bar(arg2 bool) (_swig_ret string) { + return _swig_wrap_FFoo_Bar(arg1, arg2) +} + +var _wrap_new_FFoo unsafe.Pointer + +func _swig_wrap_new_FFoo() (base SwigcptrFFoo) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_FFoo, _swig_p) + return +} + +func NewFFoo() (_swig_ret FFoo) { + return _swig_wrap_new_FFoo() +} + +var _wrap_delete_FFoo unsafe.Pointer + +func _swig_wrap_delete_FFoo(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_FFoo, _swig_p) + return +} + +func DeleteFFoo(arg1 FFoo) { + _swig_wrap_delete_FFoo(arg1.Swigcptr()) +} + +type FFoo interface { + Swigcptr() uintptr + SwigIsFFoo() + Bar(arg2 bool) (_swig_ret string) +} + +type SwigcptrABCD uintptr + +func (p SwigcptrABCD) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrABCD) SwigIsABCD() { +} + +var _wrap_ABCD_meth unsafe.Pointer + +func _swig_wrap_ABCD_meth(base SwigcptrABCD) (_ float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_ABCD_meth, _swig_p) + return +} + +func (arg1 SwigcptrABCD) Meth() (_swig_ret float64) { + return _swig_wrap_ABCD_meth(arg1) +} + +var _wrap_ABCD_m1 unsafe.Pointer + +func _swig_wrap_ABCD_m1(base SwigcptrABCD) (_ float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_ABCD_m1, _swig_p) + return +} + +func (arg1 SwigcptrABCD) M1() (_swig_ret float64) { + return _swig_wrap_ABCD_m1(arg1) +} + +var _wrap_ABCD__x2 unsafe.Pointer + +func _swig_wrap_ABCD__x2(base SwigcptrABCD) (_ float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_ABCD__x2, _swig_p) + return +} + +func (arg1 SwigcptrABCD) X_x2() (_swig_ret float64) { + return _swig_wrap_ABCD__x2(arg1) +} + +var _wrap_ABCD_y_ unsafe.Pointer + +func _swig_wrap_ABCD_y_(base SwigcptrABCD) (_ float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_ABCD_y_, _swig_p) + return +} + +func (arg1 SwigcptrABCD) Y_() (_swig_ret float64) { + return _swig_wrap_ABCD_y_(arg1) +} + +var _wrap_ABCD__3 unsafe.Pointer + +func _swig_wrap_ABCD__3(base SwigcptrABCD) (_ float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_ABCD__3, _swig_p) + return +} + +func (arg1 SwigcptrABCD) X_3() (_swig_ret float64) { + return _swig_wrap_ABCD__3(arg1) +} + +var _wrap_new_ABCD unsafe.Pointer + +func _swig_wrap_new_ABCD() (base SwigcptrABCD) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_ABCD, _swig_p) + return +} + +func NewABCD() (_swig_ret ABCD) { + return _swig_wrap_new_ABCD() +} + +var _wrap_delete_ABCD unsafe.Pointer + +func _swig_wrap_delete_ABCD(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_ABCD, _swig_p) + return +} + +func DeleteABCD(arg1 ABCD) { + _swig_wrap_delete_ABCD(arg1.Swigcptr()) +} + +type ABCD interface { + Swigcptr() uintptr + SwigIsABCD() + Meth() (_swig_ret float64) + M1() (_swig_ret float64) + X_x2() (_swig_ret float64) + Y_() (_swig_ret float64) + X_3() (_swig_ret float64) +} + + +type SwigcptrFoo_Sl_short_Sg_ uintptr +type Foo_Sl_short_Sg_ interface { + Swigcptr() uintptr; +} +func (p SwigcptrFoo_Sl_short_Sg_) Swigcptr() uintptr { + return uintptr(p) +} + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/typename.go b/Examples/test-suite/go/typename.go new file mode 100644 index 000000000..d87e19b11 --- /dev/null +++ b/Examples/test-suite/go/typename.go @@ -0,0 +1,170 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../typename.i + +package typename + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrFoo uintptr + +func (p SwigcptrFoo) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrFoo) SwigIsFoo() { +} + +var _wrap_Foo_blah unsafe.Pointer + +func _swig_wrap_Foo_blah(base SwigcptrFoo) (_ float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_blah, _swig_p) + return +} + +func (arg1 SwigcptrFoo) Blah() (_swig_ret float64) { + return _swig_wrap_Foo_blah(arg1) +} + +var _wrap_new_Foo unsafe.Pointer + +func _swig_wrap_new_Foo() (base SwigcptrFoo) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Foo, _swig_p) + return +} + +func NewFoo() (_swig_ret Foo) { + return _swig_wrap_new_Foo() +} + +var _wrap_delete_Foo unsafe.Pointer + +func _swig_wrap_delete_Foo(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Foo, _swig_p) + return +} + +func DeleteFoo(arg1 Foo) { + _swig_wrap_delete_Foo(arg1.Swigcptr()) +} + +type Foo interface { + Swigcptr() uintptr + SwigIsFoo() + Blah() (_swig_ret float64) +} + +type SwigcptrBar uintptr + +func (p SwigcptrBar) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrBar) SwigIsBar() { +} + +var _wrap_Bar_blah unsafe.Pointer + +func _swig_wrap_Bar_blah(base SwigcptrBar) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Bar_blah, _swig_p) + return +} + +func (arg1 SwigcptrBar) Blah() (_swig_ret int) { + return _swig_wrap_Bar_blah(arg1) +} + +var _wrap_new_Bar unsafe.Pointer + +func _swig_wrap_new_Bar() (base SwigcptrBar) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Bar, _swig_p) + return +} + +func NewBar() (_swig_ret Bar) { + return _swig_wrap_new_Bar() +} + +var _wrap_delete_Bar unsafe.Pointer + +func _swig_wrap_delete_Bar(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Bar, _swig_p) + return +} + +func DeleteBar(arg1 Bar) { + _swig_wrap_delete_Bar(arg1.Swigcptr()) +} + +type Bar interface { + Swigcptr() uintptr + SwigIsBar() + Blah() (_swig_ret int) +} + +var _wrap_spam unsafe.Pointer + +func Spam() (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_spam, _swig_p) + return +} +var _wrap_twoFoo unsafe.Pointer + +func _swig_wrap_twoFoo(base uintptr) (_ float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_twoFoo, _swig_p) + return +} + +func TwoFoo(arg1 Foo) (_swig_ret float64) { + return _swig_wrap_twoFoo(arg1.Swigcptr()) +} + +var _wrap_twoBar unsafe.Pointer + +func _swig_wrap_twoBar(base uintptr) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_twoBar, _swig_p) + return +} + +func TwoBar(arg1 Bar) (_swig_ret int) { + return _swig_wrap_twoBar(arg1.Swigcptr()) +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/typename_runme b/Examples/test-suite/go/typename_runme new file mode 100755 index 000000000..43fc030ca Binary files /dev/null and b/Examples/test-suite/go/typename_runme differ diff --git a/Examples/test-suite/go/types_directive.go b/Examples/test-suite/go/types_directive.go new file mode 100644 index 000000000..114698176 --- /dev/null +++ b/Examples/test-suite/go/types_directive.go @@ -0,0 +1,358 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../types_directive.i + +package types_directive + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrDate uintptr + +func (p SwigcptrDate) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrDate) SwigIsDate() { +} + +var _wrap_new_Date unsafe.Pointer + +func _swig_wrap_new_Date(base uint, _ uint, _ uint) (_ SwigcptrDate) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Date, _swig_p) + return +} + +func NewDate(arg1 uint, arg2 uint, arg3 uint) (_swig_ret Date) { + return _swig_wrap_new_Date(arg1, arg2, arg3) +} + +var _wrap_Date_year_set unsafe.Pointer + +func _swig_wrap_Date_year_set(base SwigcptrDate, _ uint) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Date_year_set, _swig_p) + return +} + +func (arg1 SwigcptrDate) SetYear(arg2 uint) { + _swig_wrap_Date_year_set(arg1, arg2) +} + +var _wrap_Date_year_get unsafe.Pointer + +func _swig_wrap_Date_year_get(base SwigcptrDate) (_ uint) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Date_year_get, _swig_p) + return +} + +func (arg1 SwigcptrDate) GetYear() (_swig_ret uint) { + return _swig_wrap_Date_year_get(arg1) +} + +var _wrap_Date_month_set unsafe.Pointer + +func _swig_wrap_Date_month_set(base SwigcptrDate, _ uint) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Date_month_set, _swig_p) + return +} + +func (arg1 SwigcptrDate) SetMonth(arg2 uint) { + _swig_wrap_Date_month_set(arg1, arg2) +} + +var _wrap_Date_month_get unsafe.Pointer + +func _swig_wrap_Date_month_get(base SwigcptrDate) (_ uint) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Date_month_get, _swig_p) + return +} + +func (arg1 SwigcptrDate) GetMonth() (_swig_ret uint) { + return _swig_wrap_Date_month_get(arg1) +} + +var _wrap_Date_day_set unsafe.Pointer + +func _swig_wrap_Date_day_set(base SwigcptrDate, _ uint) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Date_day_set, _swig_p) + return +} + +func (arg1 SwigcptrDate) SetDay(arg2 uint) { + _swig_wrap_Date_day_set(arg1, arg2) +} + +var _wrap_Date_day_get unsafe.Pointer + +func _swig_wrap_Date_day_get(base SwigcptrDate) (_ uint) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Date_day_get, _swig_p) + return +} + +func (arg1 SwigcptrDate) GetDay() (_swig_ret uint) { + return _swig_wrap_Date_day_get(arg1) +} + +var _wrap_delete_Date unsafe.Pointer + +func _swig_wrap_delete_Date(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Date, _swig_p) + return +} + +func DeleteDate(arg1 Date) { + _swig_wrap_delete_Date(arg1.Swigcptr()) +} + +type Date interface { + Swigcptr() uintptr + SwigIsDate() + SetYear(arg2 uint) + GetYear() (_swig_ret uint) + SetMonth(arg2 uint) + GetMonth() (_swig_ret uint) + SetDay(arg2 uint) + GetDay() (_swig_ret uint) +} + +type SwigcptrTime1 uintptr + +func (p SwigcptrTime1) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrTime1) SwigIsTime1() { +} + +var _wrap_new_Time1 unsafe.Pointer + +func _swig_wrap_new_Time1(base uint, _ uint, _ uint, _ uint) (_ SwigcptrTime1) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Time1, _swig_p) + return +} + +func NewTime1(arg1 uint, arg2 uint, arg3 uint, arg4 uint) (_swig_ret Time1) { + return _swig_wrap_new_Time1(arg1, arg2, arg3, arg4) +} + +var _wrap_Time1_dateFromTime unsafe.Pointer + +func _swig_wrap_Time1_dateFromTime(base SwigcptrTime1) (_ SwigcptrDate) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Time1_dateFromTime, _swig_p) + return +} + +func (arg1 SwigcptrTime1) DateFromTime() (_swig_ret Date) { + return _swig_wrap_Time1_dateFromTime(arg1) +} + +var _wrap_Time1_date_set unsafe.Pointer + +func _swig_wrap_Time1_date_set(base SwigcptrTime1, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Time1_date_set, _swig_p) + return +} + +func (arg1 SwigcptrTime1) SetDate(arg2 Date) { + _swig_wrap_Time1_date_set(arg1, arg2.Swigcptr()) +} + +var _wrap_Time1_date_get unsafe.Pointer + +func _swig_wrap_Time1_date_get(base SwigcptrTime1) (_ SwigcptrDate) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Time1_date_get, _swig_p) + return +} + +func (arg1 SwigcptrTime1) GetDate() (_swig_ret Date) { + return _swig_wrap_Time1_date_get(arg1) +} + +var _wrap_Time1_seconds_set unsafe.Pointer + +func _swig_wrap_Time1_seconds_set(base SwigcptrTime1, _ uint) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Time1_seconds_set, _swig_p) + return +} + +func (arg1 SwigcptrTime1) SetSeconds(arg2 uint) { + _swig_wrap_Time1_seconds_set(arg1, arg2) +} + +var _wrap_Time1_seconds_get unsafe.Pointer + +func _swig_wrap_Time1_seconds_get(base SwigcptrTime1) (_ uint) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Time1_seconds_get, _swig_p) + return +} + +func (arg1 SwigcptrTime1) GetSeconds() (_swig_ret uint) { + return _swig_wrap_Time1_seconds_get(arg1) +} + +var _wrap_delete_Time1 unsafe.Pointer + +func _swig_wrap_delete_Time1(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Time1, _swig_p) + return +} + +func DeleteTime1(arg1 Time1) { + _swig_wrap_delete_Time1(arg1.Swigcptr()) +} + +type Time1 interface { + Swigcptr() uintptr + SwigIsTime1() + DateFromTime() (_swig_ret Date) + SetDate(arg2 Date) + GetDate() (_swig_ret Date) + SetSeconds(arg2 uint) + GetSeconds() (_swig_ret uint) +} + +type SwigcptrTime2 uintptr + +func (p SwigcptrTime2) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrTime2) SwigIsTime2() { +} + +var _wrap_new_Time2 unsafe.Pointer + +func _swig_wrap_new_Time2(base uint, _ uint, _ uint, _ uint) (_ SwigcptrTime2) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Time2, _swig_p) + return +} + +func NewTime2(arg1 uint, arg2 uint, arg3 uint, arg4 uint) (_swig_ret Time2) { + return _swig_wrap_new_Time2(arg1, arg2, arg3, arg4) +} + +var _wrap_Time2_date_set unsafe.Pointer + +func _swig_wrap_Time2_date_set(base SwigcptrTime2, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Time2_date_set, _swig_p) + return +} + +func (arg1 SwigcptrTime2) SetDate(arg2 Date) { + _swig_wrap_Time2_date_set(arg1, arg2.Swigcptr()) +} + +var _wrap_Time2_date_get unsafe.Pointer + +func _swig_wrap_Time2_date_get(base SwigcptrTime2) (_ SwigcptrDate) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Time2_date_get, _swig_p) + return +} + +func (arg1 SwigcptrTime2) GetDate() (_swig_ret Date) { + return _swig_wrap_Time2_date_get(arg1) +} + +var _wrap_Time2_seconds_set unsafe.Pointer + +func _swig_wrap_Time2_seconds_set(base SwigcptrTime2, _ uint) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Time2_seconds_set, _swig_p) + return +} + +func (arg1 SwigcptrTime2) SetSeconds(arg2 uint) { + _swig_wrap_Time2_seconds_set(arg1, arg2) +} + +var _wrap_Time2_seconds_get unsafe.Pointer + +func _swig_wrap_Time2_seconds_get(base SwigcptrTime2) (_ uint) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Time2_seconds_get, _swig_p) + return +} + +func (arg1 SwigcptrTime2) GetSeconds() (_swig_ret uint) { + return _swig_wrap_Time2_seconds_get(arg1) +} + +var _wrap_delete_Time2 unsafe.Pointer + +func _swig_wrap_delete_Time2(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Time2, _swig_p) + return +} + +func DeleteTime2(arg1 Time2) { + _swig_wrap_delete_Time2(arg1.Swigcptr()) +} + +type Time2 interface { + Swigcptr() uintptr + SwigIsTime2() + SetDate(arg2 Date) + GetDate() (_swig_ret Date) + SetSeconds(arg2 uint) + GetSeconds() (_swig_ret uint) +} + +var _wrap_add unsafe.Pointer + +func _swig_wrap_add(base uintptr, _ uint) (_ SwigcptrDate) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_add, _swig_p) + return +} + +func Add(arg1 Date, arg2 uint) (_swig_ret Date) { + return _swig_wrap_add(arg1.Swigcptr(), arg2) +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/unicode_strings.go b/Examples/test-suite/go/unicode_strings.go new file mode 100644 index 000000000..2735b4a3a --- /dev/null +++ b/Examples/test-suite/go/unicode_strings.go @@ -0,0 +1,43 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../unicode_strings.i + +package unicode_strings + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +var _wrap_non_utf8_c_str unsafe.Pointer + +func Non_utf8_c_str() (_swig_ret string) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_non_utf8_c_str, _swig_p) + return +} +var _wrap_non_utf8_std_string unsafe.Pointer + +func Non_utf8_std_string() (_swig_ret string) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_non_utf8_std_string, _swig_p) + return +} + diff --git a/Examples/test-suite/go/union_parameter.go b/Examples/test-suite/go/union_parameter.go new file mode 100644 index 000000000..3f0cc34ac --- /dev/null +++ b/Examples/test-suite/go/union_parameter.go @@ -0,0 +1,397 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../union_parameter.i + +package union_parameter + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrSDL_ActiveEvent uintptr + +func (p SwigcptrSDL_ActiveEvent) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrSDL_ActiveEvent) SwigIsSDL_ActiveEvent() { +} + +var _wrap_SDL_ActiveEvent_Xtype_set unsafe.Pointer + +func _swig_wrap_SDL_ActiveEvent_Xtype_set(base SwigcptrSDL_ActiveEvent, _ byte) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_SDL_ActiveEvent_Xtype_set, _swig_p) + return +} + +func (arg1 SwigcptrSDL_ActiveEvent) SetXtype(arg2 byte) { + _swig_wrap_SDL_ActiveEvent_Xtype_set(arg1, arg2) +} + +var _wrap_SDL_ActiveEvent_Xtype_get unsafe.Pointer + +func _swig_wrap_SDL_ActiveEvent_Xtype_get(base SwigcptrSDL_ActiveEvent) (_ byte) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_SDL_ActiveEvent_Xtype_get, _swig_p) + return +} + +func (arg1 SwigcptrSDL_ActiveEvent) GetXtype() (_swig_ret byte) { + return _swig_wrap_SDL_ActiveEvent_Xtype_get(arg1) +} + +var _wrap_SDL_ActiveEvent_gain_set unsafe.Pointer + +func _swig_wrap_SDL_ActiveEvent_gain_set(base SwigcptrSDL_ActiveEvent, _ byte) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_SDL_ActiveEvent_gain_set, _swig_p) + return +} + +func (arg1 SwigcptrSDL_ActiveEvent) SetGain(arg2 byte) { + _swig_wrap_SDL_ActiveEvent_gain_set(arg1, arg2) +} + +var _wrap_SDL_ActiveEvent_gain_get unsafe.Pointer + +func _swig_wrap_SDL_ActiveEvent_gain_get(base SwigcptrSDL_ActiveEvent) (_ byte) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_SDL_ActiveEvent_gain_get, _swig_p) + return +} + +func (arg1 SwigcptrSDL_ActiveEvent) GetGain() (_swig_ret byte) { + return _swig_wrap_SDL_ActiveEvent_gain_get(arg1) +} + +var _wrap_SDL_ActiveEvent_state_set unsafe.Pointer + +func _swig_wrap_SDL_ActiveEvent_state_set(base SwigcptrSDL_ActiveEvent, _ byte) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_SDL_ActiveEvent_state_set, _swig_p) + return +} + +func (arg1 SwigcptrSDL_ActiveEvent) SetState(arg2 byte) { + _swig_wrap_SDL_ActiveEvent_state_set(arg1, arg2) +} + +var _wrap_SDL_ActiveEvent_state_get unsafe.Pointer + +func _swig_wrap_SDL_ActiveEvent_state_get(base SwigcptrSDL_ActiveEvent) (_ byte) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_SDL_ActiveEvent_state_get, _swig_p) + return +} + +func (arg1 SwigcptrSDL_ActiveEvent) GetState() (_swig_ret byte) { + return _swig_wrap_SDL_ActiveEvent_state_get(arg1) +} + +var _wrap_new_SDL_ActiveEvent unsafe.Pointer + +func _swig_wrap_new_SDL_ActiveEvent() (base SwigcptrSDL_ActiveEvent) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_SDL_ActiveEvent, _swig_p) + return +} + +func NewSDL_ActiveEvent() (_swig_ret SDL_ActiveEvent) { + return _swig_wrap_new_SDL_ActiveEvent() +} + +var _wrap_delete_SDL_ActiveEvent unsafe.Pointer + +func _swig_wrap_delete_SDL_ActiveEvent(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_SDL_ActiveEvent, _swig_p) + return +} + +func DeleteSDL_ActiveEvent(arg1 SDL_ActiveEvent) { + _swig_wrap_delete_SDL_ActiveEvent(arg1.Swigcptr()) +} + +type SDL_ActiveEvent interface { + Swigcptr() uintptr + SwigIsSDL_ActiveEvent() + SetXtype(arg2 byte) + GetXtype() (_swig_ret byte) + SetGain(arg2 byte) + GetGain() (_swig_ret byte) + SetState(arg2 byte) + GetState() (_swig_ret byte) +} + +type SwigcptrSDL_KeyboardEvent uintptr + +func (p SwigcptrSDL_KeyboardEvent) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrSDL_KeyboardEvent) SwigIsSDL_KeyboardEvent() { +} + +var _wrap_SDL_KeyboardEvent_Xtype_set unsafe.Pointer + +func _swig_wrap_SDL_KeyboardEvent_Xtype_set(base SwigcptrSDL_KeyboardEvent, _ byte) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_SDL_KeyboardEvent_Xtype_set, _swig_p) + return +} + +func (arg1 SwigcptrSDL_KeyboardEvent) SetXtype(arg2 byte) { + _swig_wrap_SDL_KeyboardEvent_Xtype_set(arg1, arg2) +} + +var _wrap_SDL_KeyboardEvent_Xtype_get unsafe.Pointer + +func _swig_wrap_SDL_KeyboardEvent_Xtype_get(base SwigcptrSDL_KeyboardEvent) (_ byte) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_SDL_KeyboardEvent_Xtype_get, _swig_p) + return +} + +func (arg1 SwigcptrSDL_KeyboardEvent) GetXtype() (_swig_ret byte) { + return _swig_wrap_SDL_KeyboardEvent_Xtype_get(arg1) +} + +var _wrap_SDL_KeyboardEvent_which_set unsafe.Pointer + +func _swig_wrap_SDL_KeyboardEvent_which_set(base SwigcptrSDL_KeyboardEvent, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_SDL_KeyboardEvent_which_set, _swig_p) + return +} + +func (arg1 SwigcptrSDL_KeyboardEvent) SetWhich(arg2 int) { + _swig_wrap_SDL_KeyboardEvent_which_set(arg1, arg2) +} + +var _wrap_SDL_KeyboardEvent_which_get unsafe.Pointer + +func _swig_wrap_SDL_KeyboardEvent_which_get(base SwigcptrSDL_KeyboardEvent) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_SDL_KeyboardEvent_which_get, _swig_p) + return +} + +func (arg1 SwigcptrSDL_KeyboardEvent) GetWhich() (_swig_ret int) { + return _swig_wrap_SDL_KeyboardEvent_which_get(arg1) +} + +var _wrap_SDL_KeyboardEvent_state_set unsafe.Pointer + +func _swig_wrap_SDL_KeyboardEvent_state_set(base SwigcptrSDL_KeyboardEvent, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_SDL_KeyboardEvent_state_set, _swig_p) + return +} + +func (arg1 SwigcptrSDL_KeyboardEvent) SetState(arg2 int) { + _swig_wrap_SDL_KeyboardEvent_state_set(arg1, arg2) +} + +var _wrap_SDL_KeyboardEvent_state_get unsafe.Pointer + +func _swig_wrap_SDL_KeyboardEvent_state_get(base SwigcptrSDL_KeyboardEvent) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_SDL_KeyboardEvent_state_get, _swig_p) + return +} + +func (arg1 SwigcptrSDL_KeyboardEvent) GetState() (_swig_ret int) { + return _swig_wrap_SDL_KeyboardEvent_state_get(arg1) +} + +var _wrap_new_SDL_KeyboardEvent unsafe.Pointer + +func _swig_wrap_new_SDL_KeyboardEvent() (base SwigcptrSDL_KeyboardEvent) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_SDL_KeyboardEvent, _swig_p) + return +} + +func NewSDL_KeyboardEvent() (_swig_ret SDL_KeyboardEvent) { + return _swig_wrap_new_SDL_KeyboardEvent() +} + +var _wrap_delete_SDL_KeyboardEvent unsafe.Pointer + +func _swig_wrap_delete_SDL_KeyboardEvent(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_SDL_KeyboardEvent, _swig_p) + return +} + +func DeleteSDL_KeyboardEvent(arg1 SDL_KeyboardEvent) { + _swig_wrap_delete_SDL_KeyboardEvent(arg1.Swigcptr()) +} + +type SDL_KeyboardEvent interface { + Swigcptr() uintptr + SwigIsSDL_KeyboardEvent() + SetXtype(arg2 byte) + GetXtype() (_swig_ret byte) + SetWhich(arg2 int) + GetWhich() (_swig_ret int) + SetState(arg2 int) + GetState() (_swig_ret int) +} + +type SwigcptrSDL_Event uintptr + +func (p SwigcptrSDL_Event) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrSDL_Event) SwigIsSDL_Event() { +} + +var _wrap_SDL_Event_Xtype_set unsafe.Pointer + +func _swig_wrap_SDL_Event_Xtype_set(base SwigcptrSDL_Event, _ byte) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_SDL_Event_Xtype_set, _swig_p) + return +} + +func (arg1 SwigcptrSDL_Event) SetXtype(arg2 byte) { + _swig_wrap_SDL_Event_Xtype_set(arg1, arg2) +} + +var _wrap_SDL_Event_Xtype_get unsafe.Pointer + +func _swig_wrap_SDL_Event_Xtype_get(base SwigcptrSDL_Event) (_ byte) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_SDL_Event_Xtype_get, _swig_p) + return +} + +func (arg1 SwigcptrSDL_Event) GetXtype() (_swig_ret byte) { + return _swig_wrap_SDL_Event_Xtype_get(arg1) +} + +var _wrap_SDL_Event_active_set unsafe.Pointer + +func _swig_wrap_SDL_Event_active_set(base SwigcptrSDL_Event, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_SDL_Event_active_set, _swig_p) + return +} + +func (arg1 SwigcptrSDL_Event) SetActive(arg2 SDL_ActiveEvent) { + _swig_wrap_SDL_Event_active_set(arg1, arg2.Swigcptr()) +} + +var _wrap_SDL_Event_active_get unsafe.Pointer + +func _swig_wrap_SDL_Event_active_get(base SwigcptrSDL_Event) (_ SwigcptrSDL_ActiveEvent) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_SDL_Event_active_get, _swig_p) + return +} + +func (arg1 SwigcptrSDL_Event) GetActive() (_swig_ret SDL_ActiveEvent) { + return _swig_wrap_SDL_Event_active_get(arg1) +} + +var _wrap_SDL_Event_key_set unsafe.Pointer + +func _swig_wrap_SDL_Event_key_set(base SwigcptrSDL_Event, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_SDL_Event_key_set, _swig_p) + return +} + +func (arg1 SwigcptrSDL_Event) SetKey(arg2 SDL_KeyboardEvent) { + _swig_wrap_SDL_Event_key_set(arg1, arg2.Swigcptr()) +} + +var _wrap_SDL_Event_key_get unsafe.Pointer + +func _swig_wrap_SDL_Event_key_get(base SwigcptrSDL_Event) (_ SwigcptrSDL_KeyboardEvent) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_SDL_Event_key_get, _swig_p) + return +} + +func (arg1 SwigcptrSDL_Event) GetKey() (_swig_ret SDL_KeyboardEvent) { + return _swig_wrap_SDL_Event_key_get(arg1) +} + +var _wrap_new_SDL_Event unsafe.Pointer + +func _swig_wrap_new_SDL_Event() (base SwigcptrSDL_Event) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_SDL_Event, _swig_p) + return +} + +func NewSDL_Event() (_swig_ret SDL_Event) { + return _swig_wrap_new_SDL_Event() +} + +var _wrap_delete_SDL_Event unsafe.Pointer + +func _swig_wrap_delete_SDL_Event(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_SDL_Event, _swig_p) + return +} + +func DeleteSDL_Event(arg1 SDL_Event) { + _swig_wrap_delete_SDL_Event(arg1.Swigcptr()) +} + +type SDL_Event interface { + Swigcptr() uintptr + SwigIsSDL_Event() + SetXtype(arg2 byte) + GetXtype() (_swig_ret byte) + SetActive(arg2 SDL_ActiveEvent) + GetActive() (_swig_ret SDL_ActiveEvent) + SetKey(arg2 SDL_KeyboardEvent) + GetKey() (_swig_ret SDL_KeyboardEvent) +} + +var _wrap_SDL_PollEvent unsafe.Pointer + +func _swig_wrap_SDL_PollEvent(base uintptr) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_SDL_PollEvent, _swig_p) + return +} + +func SDL_PollEvent(arg1 SDL_Event) (_swig_ret int) { + return _swig_wrap_SDL_PollEvent(arg1.Swigcptr()) +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/union_scope.go b/Examples/test-suite/go/union_scope.go new file mode 100644 index 000000000..01f506064 --- /dev/null +++ b/Examples/test-suite/go/union_scope.go @@ -0,0 +1,75 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../union_scope.i + +package union_scope + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrNRState uintptr + +func (p SwigcptrNRState) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrNRState) SwigIsNRState() { +} + +var _wrap_new_nRState unsafe.Pointer + +func _swig_wrap_new_nRState() (base SwigcptrNRState) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_nRState, _swig_p) + return +} + +func NewNRState() (_swig_ret NRState) { + return _swig_wrap_new_nRState() +} + +var _wrap_delete_nRState unsafe.Pointer + +func _swig_wrap_delete_nRState(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_nRState, _swig_p) + return +} + +func DeleteNRState(arg1 NRState) { + _swig_wrap_delete_nRState(arg1.Swigcptr()) +} + +type NRState interface { + Swigcptr() uintptr + SwigIsNRState() +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/unions.go b/Examples/test-suite/go/unions.go new file mode 100644 index 000000000..5b2b27d23 --- /dev/null +++ b/Examples/test-suite/go/unions.go @@ -0,0 +1,448 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../unions.i + +package unions + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrSmallStruct uintptr + +func (p SwigcptrSmallStruct) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrSmallStruct) SwigIsSmallStruct() { +} + +var _wrap_SmallStruct_jill_set unsafe.Pointer + +func _swig_wrap_SmallStruct_jill_set(base SwigcptrSmallStruct, _ int16) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_SmallStruct_jill_set, _swig_p) + return +} + +func (arg1 SwigcptrSmallStruct) SetJill(arg2 int16) { + _swig_wrap_SmallStruct_jill_set(arg1, arg2) +} + +var _wrap_SmallStruct_jill_get unsafe.Pointer + +func _swig_wrap_SmallStruct_jill_get(base SwigcptrSmallStruct) (_ int16) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_SmallStruct_jill_get, _swig_p) + return +} + +func (arg1 SwigcptrSmallStruct) GetJill() (_swig_ret int16) { + return _swig_wrap_SmallStruct_jill_get(arg1) +} + +var _wrap_new_SmallStruct unsafe.Pointer + +func _swig_wrap_new_SmallStruct() (base SwigcptrSmallStruct) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_SmallStruct, _swig_p) + return +} + +func NewSmallStruct() (_swig_ret SmallStruct) { + return _swig_wrap_new_SmallStruct() +} + +var _wrap_delete_SmallStruct unsafe.Pointer + +func _swig_wrap_delete_SmallStruct(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_SmallStruct, _swig_p) + return +} + +func DeleteSmallStruct(arg1 SmallStruct) { + _swig_wrap_delete_SmallStruct(arg1.Swigcptr()) +} + +type SmallStruct interface { + Swigcptr() uintptr + SwigIsSmallStruct() + SetJill(arg2 int16) + GetJill() (_swig_ret int16) +} + +type SwigcptrBigStruct uintptr + +func (p SwigcptrBigStruct) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrBigStruct) SwigIsBigStruct() { +} + +var _wrap_BigStruct_jack_set unsafe.Pointer + +func _swig_wrap_BigStruct_jack_set(base SwigcptrBigStruct, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_BigStruct_jack_set, _swig_p) + return +} + +func (arg1 SwigcptrBigStruct) SetJack(arg2 int) { + _swig_wrap_BigStruct_jack_set(arg1, arg2) +} + +var _wrap_BigStruct_jack_get unsafe.Pointer + +func _swig_wrap_BigStruct_jack_get(base SwigcptrBigStruct) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_BigStruct_jack_get, _swig_p) + return +} + +func (arg1 SwigcptrBigStruct) GetJack() (_swig_ret int) { + return _swig_wrap_BigStruct_jack_get(arg1) +} + +var _wrap_BigStruct_smallstruct_set unsafe.Pointer + +func _swig_wrap_BigStruct_smallstruct_set(base SwigcptrBigStruct, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_BigStruct_smallstruct_set, _swig_p) + return +} + +func (arg1 SwigcptrBigStruct) SetSmallstruct(arg2 SmallStruct) { + _swig_wrap_BigStruct_smallstruct_set(arg1, arg2.Swigcptr()) +} + +var _wrap_BigStruct_smallstruct_get unsafe.Pointer + +func _swig_wrap_BigStruct_smallstruct_get(base SwigcptrBigStruct) (_ SwigcptrSmallStruct) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_BigStruct_smallstruct_get, _swig_p) + return +} + +func (arg1 SwigcptrBigStruct) GetSmallstruct() (_swig_ret SmallStruct) { + return _swig_wrap_BigStruct_smallstruct_get(arg1) +} + +var _wrap_new_BigStruct unsafe.Pointer + +func _swig_wrap_new_BigStruct() (base SwigcptrBigStruct) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_BigStruct, _swig_p) + return +} + +func NewBigStruct() (_swig_ret BigStruct) { + return _swig_wrap_new_BigStruct() +} + +var _wrap_delete_BigStruct unsafe.Pointer + +func _swig_wrap_delete_BigStruct(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_BigStruct, _swig_p) + return +} + +func DeleteBigStruct(arg1 BigStruct) { + _swig_wrap_delete_BigStruct(arg1.Swigcptr()) +} + +type BigStruct interface { + Swigcptr() uintptr + SwigIsBigStruct() + SetJack(arg2 int) + GetJack() (_swig_ret int) + SetSmallstruct(arg2 SmallStruct) + GetSmallstruct() (_swig_ret SmallStruct) +} + +type SwigcptrUnionTest uintptr + +func (p SwigcptrUnionTest) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrUnionTest) SwigIsUnionTest() { +} + +var _wrap_UnionTest_bs_set unsafe.Pointer + +func _swig_wrap_UnionTest_bs_set(base SwigcptrUnionTest, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_UnionTest_bs_set, _swig_p) + return +} + +func (arg1 SwigcptrUnionTest) SetBs(arg2 BigStruct) { + _swig_wrap_UnionTest_bs_set(arg1, arg2.Swigcptr()) +} + +var _wrap_UnionTest_bs_get unsafe.Pointer + +func _swig_wrap_UnionTest_bs_get(base SwigcptrUnionTest) (_ SwigcptrBigStruct) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_UnionTest_bs_get, _swig_p) + return +} + +func (arg1 SwigcptrUnionTest) GetBs() (_swig_ret BigStruct) { + return _swig_wrap_UnionTest_bs_get(arg1) +} + +var _wrap_UnionTest_ss_set unsafe.Pointer + +func _swig_wrap_UnionTest_ss_set(base SwigcptrUnionTest, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_UnionTest_ss_set, _swig_p) + return +} + +func (arg1 SwigcptrUnionTest) SetSs(arg2 SmallStruct) { + _swig_wrap_UnionTest_ss_set(arg1, arg2.Swigcptr()) +} + +var _wrap_UnionTest_ss_get unsafe.Pointer + +func _swig_wrap_UnionTest_ss_get(base SwigcptrUnionTest) (_ SwigcptrSmallStruct) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_UnionTest_ss_get, _swig_p) + return +} + +func (arg1 SwigcptrUnionTest) GetSs() (_swig_ret SmallStruct) { + return _swig_wrap_UnionTest_ss_get(arg1) +} + +var _wrap_new_UnionTest unsafe.Pointer + +func _swig_wrap_new_UnionTest() (base SwigcptrUnionTest) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_UnionTest, _swig_p) + return +} + +func NewUnionTest() (_swig_ret UnionTest) { + return _swig_wrap_new_UnionTest() +} + +var _wrap_delete_UnionTest unsafe.Pointer + +func _swig_wrap_delete_UnionTest(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_UnionTest, _swig_p) + return +} + +func DeleteUnionTest(arg1 UnionTest) { + _swig_wrap_delete_UnionTest(arg1.Swigcptr()) +} + +type UnionTest interface { + Swigcptr() uintptr + SwigIsUnionTest() + SetBs(arg2 BigStruct) + GetBs() (_swig_ret BigStruct) + SetSs(arg2 SmallStruct) + GetSs() (_swig_ret SmallStruct) +} + +type SwigcptrEmbeddedUnionTest uintptr + +func (p SwigcptrEmbeddedUnionTest) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrEmbeddedUnionTest) SwigIsEmbeddedUnionTest() { +} + +var _wrap_EmbeddedUnionTest_uni_get unsafe.Pointer + +func _swig_wrap_EmbeddedUnionTest_uni_get(base SwigcptrEmbeddedUnionTest) (_ SwigcptrEmbeddedUnionTest_uni) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_EmbeddedUnionTest_uni_get, _swig_p) + return +} + +func (arg1 SwigcptrEmbeddedUnionTest) GetUni() (_swig_ret EmbeddedUnionTest_uni) { + return _swig_wrap_EmbeddedUnionTest_uni_get(arg1) +} + +var _wrap_EmbeddedUnionTest_number_set unsafe.Pointer + +func _swig_wrap_EmbeddedUnionTest_number_set(base SwigcptrEmbeddedUnionTest, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_EmbeddedUnionTest_number_set, _swig_p) + return +} + +func (arg1 SwigcptrEmbeddedUnionTest) SetNumber(arg2 int) { + _swig_wrap_EmbeddedUnionTest_number_set(arg1, arg2) +} + +var _wrap_EmbeddedUnionTest_number_get unsafe.Pointer + +func _swig_wrap_EmbeddedUnionTest_number_get(base SwigcptrEmbeddedUnionTest) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_EmbeddedUnionTest_number_get, _swig_p) + return +} + +func (arg1 SwigcptrEmbeddedUnionTest) GetNumber() (_swig_ret int) { + return _swig_wrap_EmbeddedUnionTest_number_get(arg1) +} + +var _wrap_new_EmbeddedUnionTest unsafe.Pointer + +func _swig_wrap_new_EmbeddedUnionTest() (base SwigcptrEmbeddedUnionTest) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_EmbeddedUnionTest, _swig_p) + return +} + +func NewEmbeddedUnionTest() (_swig_ret EmbeddedUnionTest) { + return _swig_wrap_new_EmbeddedUnionTest() +} + +var _wrap_delete_EmbeddedUnionTest unsafe.Pointer + +func _swig_wrap_delete_EmbeddedUnionTest(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_EmbeddedUnionTest, _swig_p) + return +} + +func DeleteEmbeddedUnionTest(arg1 EmbeddedUnionTest) { + _swig_wrap_delete_EmbeddedUnionTest(arg1.Swigcptr()) +} + +type EmbeddedUnionTest interface { + Swigcptr() uintptr + SwigIsEmbeddedUnionTest() + GetUni() (_swig_ret EmbeddedUnionTest_uni) + SetNumber(arg2 int) + GetNumber() (_swig_ret int) +} + +type SwigcptrEmbeddedUnionTest_uni uintptr + +func (p SwigcptrEmbeddedUnionTest_uni) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrEmbeddedUnionTest_uni) SwigIsEmbeddedUnionTest_uni() { +} + +var _wrap_EmbeddedUnionTest_uni_big_set unsafe.Pointer + +func _swig_wrap_EmbeddedUnionTest_uni_big_set(base SwigcptrEmbeddedUnionTest_uni, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_EmbeddedUnionTest_uni_big_set, _swig_p) + return +} + +func (arg1 SwigcptrEmbeddedUnionTest_uni) SetBig(arg2 BigStruct) { + _swig_wrap_EmbeddedUnionTest_uni_big_set(arg1, arg2.Swigcptr()) +} + +var _wrap_EmbeddedUnionTest_uni_big_get unsafe.Pointer + +func _swig_wrap_EmbeddedUnionTest_uni_big_get(base SwigcptrEmbeddedUnionTest_uni) (_ SwigcptrBigStruct) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_EmbeddedUnionTest_uni_big_get, _swig_p) + return +} + +func (arg1 SwigcptrEmbeddedUnionTest_uni) GetBig() (_swig_ret BigStruct) { + return _swig_wrap_EmbeddedUnionTest_uni_big_get(arg1) +} + +var _wrap_EmbeddedUnionTest_uni_small_set unsafe.Pointer + +func _swig_wrap_EmbeddedUnionTest_uni_small_set(base SwigcptrEmbeddedUnionTest_uni, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_EmbeddedUnionTest_uni_small_set, _swig_p) + return +} + +func (arg1 SwigcptrEmbeddedUnionTest_uni) SetSmall(arg2 SmallStruct) { + _swig_wrap_EmbeddedUnionTest_uni_small_set(arg1, arg2.Swigcptr()) +} + +var _wrap_EmbeddedUnionTest_uni_small_get unsafe.Pointer + +func _swig_wrap_EmbeddedUnionTest_uni_small_get(base SwigcptrEmbeddedUnionTest_uni) (_ SwigcptrSmallStruct) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_EmbeddedUnionTest_uni_small_get, _swig_p) + return +} + +func (arg1 SwigcptrEmbeddedUnionTest_uni) GetSmall() (_swig_ret SmallStruct) { + return _swig_wrap_EmbeddedUnionTest_uni_small_get(arg1) +} + +var _wrap_new_EmbeddedUnionTest_uni unsafe.Pointer + +func _swig_wrap_new_EmbeddedUnionTest_uni() (base SwigcptrEmbeddedUnionTest_uni) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_EmbeddedUnionTest_uni, _swig_p) + return +} + +func NewEmbeddedUnionTest_uni() (_swig_ret EmbeddedUnionTest_uni) { + return _swig_wrap_new_EmbeddedUnionTest_uni() +} + +var _wrap_delete_EmbeddedUnionTest_uni unsafe.Pointer + +func _swig_wrap_delete_EmbeddedUnionTest_uni(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_EmbeddedUnionTest_uni, _swig_p) + return +} + +func DeleteEmbeddedUnionTest_uni(arg1 EmbeddedUnionTest_uni) { + _swig_wrap_delete_EmbeddedUnionTest_uni(arg1.Swigcptr()) +} + +type EmbeddedUnionTest_uni interface { + Swigcptr() uintptr + SwigIsEmbeddedUnionTest_uni() + SetBig(arg2 BigStruct) + GetBig() (_swig_ret BigStruct) + SetSmall(arg2 SmallStruct) + GetSmall() (_swig_ret SmallStruct) +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/unions_runme b/Examples/test-suite/go/unions_runme new file mode 100755 index 000000000..2008d69a2 Binary files /dev/null and b/Examples/test-suite/go/unions_runme differ diff --git a/Examples/test-suite/go/using1.go b/Examples/test-suite/go/using1.go new file mode 100644 index 000000000..11a8d57d5 --- /dev/null +++ b/Examples/test-suite/go/using1.go @@ -0,0 +1,82 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../using1.i + +package using1 + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrX_FooImpl uintptr + +func (p SwigcptrX_FooImpl) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrX_FooImpl) SwigIsX_FooImpl() { +} + +var _wrap_new__FooImpl unsafe.Pointer + +func _swig_wrap_new__FooImpl() (base SwigcptrX_FooImpl) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new__FooImpl, _swig_p) + return +} + +func NewX_FooImpl() (_swig_ret X_FooImpl) { + return _swig_wrap_new__FooImpl() +} + +var _wrap_delete__FooImpl unsafe.Pointer + +func _swig_wrap_delete__FooImpl(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete__FooImpl, _swig_p) + return +} + +func DeleteX_FooImpl(arg1 X_FooImpl) { + _swig_wrap_delete__FooImpl(arg1.Swigcptr()) +} + +type X_FooImpl interface { + Swigcptr() uintptr + SwigIsX_FooImpl() +} + +var _wrap_spam unsafe.Pointer + +func Spam(arg1 int) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_spam, _swig_p) + return +} + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/using1_runme b/Examples/test-suite/go/using1_runme new file mode 100755 index 000000000..87d42fc7d Binary files /dev/null and b/Examples/test-suite/go/using1_runme differ diff --git a/Examples/test-suite/go/using2.go b/Examples/test-suite/go/using2.go new file mode 100644 index 000000000..24a330282 --- /dev/null +++ b/Examples/test-suite/go/using2.go @@ -0,0 +1,82 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../using2.i + +package using2 + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrX_FooImpl uintptr + +func (p SwigcptrX_FooImpl) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrX_FooImpl) SwigIsX_FooImpl() { +} + +var _wrap_new__FooImpl unsafe.Pointer + +func _swig_wrap_new__FooImpl() (base SwigcptrX_FooImpl) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new__FooImpl, _swig_p) + return +} + +func NewX_FooImpl() (_swig_ret X_FooImpl) { + return _swig_wrap_new__FooImpl() +} + +var _wrap_delete__FooImpl unsafe.Pointer + +func _swig_wrap_delete__FooImpl(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete__FooImpl, _swig_p) + return +} + +func DeleteX_FooImpl(arg1 X_FooImpl) { + _swig_wrap_delete__FooImpl(arg1.Swigcptr()) +} + +type X_FooImpl interface { + Swigcptr() uintptr + SwigIsX_FooImpl() +} + +var _wrap_spam unsafe.Pointer + +func Spam(arg1 int) (_swig_ret int) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_spam, _swig_p) + return +} + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/using2_runme b/Examples/test-suite/go/using2_runme new file mode 100755 index 000000000..316c43684 Binary files /dev/null and b/Examples/test-suite/go/using2_runme differ diff --git a/Examples/test-suite/go/using_composition.go b/Examples/test-suite/go/using_composition.go new file mode 100644 index 000000000..d96ff1a50 --- /dev/null +++ b/Examples/test-suite/go/using_composition.go @@ -0,0 +1,523 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../using_composition.i + +package using_composition + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrFoo uintptr + +func (p SwigcptrFoo) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrFoo) SwigIsFoo() { +} + +var _wrap_Foo_blah__SWIG_0 unsafe.Pointer + +func _swig_wrap_Foo_blah__SWIG_0(base SwigcptrFoo, _ int) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_blah__SWIG_0, _swig_p) + return +} + +func (arg1 SwigcptrFoo) Blah__SWIG_0(arg2 int) (_swig_ret int) { + return _swig_wrap_Foo_blah__SWIG_0(arg1, arg2) +} + +var _wrap_Foo_blah__SWIG_1 unsafe.Pointer + +func _swig_wrap_Foo_blah__SWIG_1(base SwigcptrFoo, _ string) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_blah__SWIG_1, _swig_p) + return +} + +func (arg1 SwigcptrFoo) Blah__SWIG_1(arg2 string) (_swig_ret string) { + return _swig_wrap_Foo_blah__SWIG_1(arg1, arg2) +} + +func (p SwigcptrFoo) Blah(a ...interface{}) interface{} { + argc := len(a) + if argc == 1 { + if _, ok := a[0].(int); !ok { + goto check_1 + } + return p.Blah__SWIG_0(a[0].(int)) + } +check_1: + if argc == 1 { + return p.Blah__SWIG_1(a[0].(string)) + } + panic("No match for overloaded function call") +} + +var _wrap_new_Foo unsafe.Pointer + +func _swig_wrap_new_Foo() (base SwigcptrFoo) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Foo, _swig_p) + return +} + +func NewFoo() (_swig_ret Foo) { + return _swig_wrap_new_Foo() +} + +var _wrap_delete_Foo unsafe.Pointer + +func _swig_wrap_delete_Foo(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Foo, _swig_p) + return +} + +func DeleteFoo(arg1 Foo) { + _swig_wrap_delete_Foo(arg1.Swigcptr()) +} + +type Foo interface { + Swigcptr() uintptr + SwigIsFoo() + Blah(a ...interface{}) interface{} +} + +type SwigcptrBar uintptr + +func (p SwigcptrBar) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrBar) SwigIsBar() { +} + +var _wrap_Bar_blah unsafe.Pointer + +func _swig_wrap_Bar_blah(base SwigcptrBar, _ float64) (_ float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Bar_blah, _swig_p) + return +} + +func (arg1 SwigcptrBar) Blah(arg2 float64) (_swig_ret float64) { + return _swig_wrap_Bar_blah(arg1, arg2) +} + +var _wrap_new_Bar unsafe.Pointer + +func _swig_wrap_new_Bar() (base SwigcptrBar) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Bar, _swig_p) + return +} + +func NewBar() (_swig_ret Bar) { + return _swig_wrap_new_Bar() +} + +var _wrap_delete_Bar unsafe.Pointer + +func _swig_wrap_delete_Bar(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Bar, _swig_p) + return +} + +func DeleteBar(arg1 Bar) { + _swig_wrap_delete_Bar(arg1.Swigcptr()) +} + +type Bar interface { + Swigcptr() uintptr + SwigIsBar() + Blah(arg2 float64) (_swig_ret float64) +} + +type SwigcptrFooBar uintptr + +func (p SwigcptrFooBar) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrFooBar) SwigIsFooBar() { +} + +var _wrap_FooBar_blah__SWIG_0_0 unsafe.Pointer + +func _swig_wrap_FooBar_blah__SWIG_0_0(base SwigcptrFooBar, _ int) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_FooBar_blah__SWIG_0_0, _swig_p) + return +} + +func (arg1 SwigcptrFooBar) Blah__SWIG_0_0(arg2 int) (_swig_ret int) { + return _swig_wrap_FooBar_blah__SWIG_0_0(arg1, arg2) +} + +var _wrap_FooBar_blah__SWIG_1_0 unsafe.Pointer + +func _swig_wrap_FooBar_blah__SWIG_1_0(base SwigcptrFooBar, _ float64) (_ float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_FooBar_blah__SWIG_1_0, _swig_p) + return +} + +func (arg1 SwigcptrFooBar) Blah__SWIG_1_0(arg2 float64) (_swig_ret float64) { + return _swig_wrap_FooBar_blah__SWIG_1_0(arg1, arg2) +} + +var _wrap_FooBar_blah__SWIG_2 unsafe.Pointer + +func _swig_wrap_FooBar_blah__SWIG_2(base SwigcptrFooBar, _ string) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_FooBar_blah__SWIG_2, _swig_p) + return +} + +func (arg1 SwigcptrFooBar) Blah__SWIG_2(arg2 string) (_swig_ret string) { + return _swig_wrap_FooBar_blah__SWIG_2(arg1, arg2) +} + +func (p SwigcptrFooBar) Blah(a ...interface{}) interface{} { + argc := len(a) + if argc == 1 { + if _, ok := a[0].(int); !ok { + goto check_1 + } + return p.Blah__SWIG_0_0(a[0].(int)) + } +check_1: + if argc == 1 { + if _, ok := a[0].(float64); !ok { + goto check_2 + } + return p.Blah__SWIG_1_0(a[0].(float64)) + } +check_2: + if argc == 1 { + return p.Blah__SWIG_2(a[0].(string)) + } + panic("No match for overloaded function call") +} + +var _wrap_new_FooBar unsafe.Pointer + +func _swig_wrap_new_FooBar() (base SwigcptrFooBar) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_FooBar, _swig_p) + return +} + +func NewFooBar() (_swig_ret FooBar) { + return _swig_wrap_new_FooBar() +} + +var _wrap_delete_FooBar unsafe.Pointer + +func _swig_wrap_delete_FooBar(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_FooBar, _swig_p) + return +} + +func DeleteFooBar(arg1 FooBar) { + _swig_wrap_delete_FooBar(arg1.Swigcptr()) +} + +func (p SwigcptrFooBar) SwigIsFoo() { +} + +func (p SwigcptrFooBar) SwigGetFoo() Foo { + return SwigcptrFoo(p.Swigcptr()) +} + +var _wrap_FooBar_SwigGetBar unsafe.Pointer + +func _swig_wrap_FooBar_SwigGetBar(base SwigcptrFooBar) (_ SwigcptrBar) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_FooBar_SwigGetBar, _swig_p) + return +} + +func (arg1 SwigcptrFooBar) SwigGetBar() (_swig_ret Bar) { + return _swig_wrap_FooBar_SwigGetBar(arg1) +} + +type FooBar interface { + Swigcptr() uintptr + SwigIsFooBar() + Blah(a ...interface{}) interface{} + SwigIsFoo() + SwigGetFoo() Foo + SwigGetBar() (_swig_ret Bar) +} + +type SwigcptrFooBar2 uintptr + +func (p SwigcptrFooBar2) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrFooBar2) SwigIsFooBar2() { +} + +var _wrap_FooBar2_blah__SWIG_0 unsafe.Pointer + +func _swig_wrap_FooBar2_blah__SWIG_0(base SwigcptrFooBar2, _ string) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_FooBar2_blah__SWIG_0, _swig_p) + return +} + +func (arg1 SwigcptrFooBar2) Blah__SWIG_0(arg2 string) (_swig_ret string) { + return _swig_wrap_FooBar2_blah__SWIG_0(arg1, arg2) +} + +var _wrap_FooBar2_blah__SWIG_1_0 unsafe.Pointer + +func _swig_wrap_FooBar2_blah__SWIG_1_0(base SwigcptrFooBar2, _ int) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_FooBar2_blah__SWIG_1_0, _swig_p) + return +} + +func (arg1 SwigcptrFooBar2) Blah__SWIG_1_0(arg2 int) (_swig_ret int) { + return _swig_wrap_FooBar2_blah__SWIG_1_0(arg1, arg2) +} + +var _wrap_FooBar2_blah__SWIG_2_0 unsafe.Pointer + +func _swig_wrap_FooBar2_blah__SWIG_2_0(base SwigcptrFooBar2, _ float64) (_ float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_FooBar2_blah__SWIG_2_0, _swig_p) + return +} + +func (arg1 SwigcptrFooBar2) Blah__SWIG_2_0(arg2 float64) (_swig_ret float64) { + return _swig_wrap_FooBar2_blah__SWIG_2_0(arg1, arg2) +} + +func (p SwigcptrFooBar2) Blah(a ...interface{}) interface{} { + argc := len(a) + if argc == 1 { + if _, ok := a[0].(int); !ok { + goto check_1 + } + return p.Blah__SWIG_1_0(a[0].(int)) + } +check_1: + if argc == 1 { + if _, ok := a[0].(float64); !ok { + goto check_2 + } + return p.Blah__SWIG_2_0(a[0].(float64)) + } +check_2: + if argc == 1 { + return p.Blah__SWIG_0(a[0].(string)) + } + panic("No match for overloaded function call") +} + +var _wrap_new_FooBar2 unsafe.Pointer + +func _swig_wrap_new_FooBar2() (base SwigcptrFooBar2) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_FooBar2, _swig_p) + return +} + +func NewFooBar2() (_swig_ret FooBar2) { + return _swig_wrap_new_FooBar2() +} + +var _wrap_delete_FooBar2 unsafe.Pointer + +func _swig_wrap_delete_FooBar2(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_FooBar2, _swig_p) + return +} + +func DeleteFooBar2(arg1 FooBar2) { + _swig_wrap_delete_FooBar2(arg1.Swigcptr()) +} + +func (p SwigcptrFooBar2) SwigIsFoo() { +} + +func (p SwigcptrFooBar2) SwigGetFoo() Foo { + return SwigcptrFoo(p.Swigcptr()) +} + +var _wrap_FooBar2_SwigGetBar unsafe.Pointer + +func _swig_wrap_FooBar2_SwigGetBar(base SwigcptrFooBar2) (_ SwigcptrBar) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_FooBar2_SwigGetBar, _swig_p) + return +} + +func (arg1 SwigcptrFooBar2) SwigGetBar() (_swig_ret Bar) { + return _swig_wrap_FooBar2_SwigGetBar(arg1) +} + +type FooBar2 interface { + Swigcptr() uintptr + SwigIsFooBar2() + Blah(a ...interface{}) interface{} + SwigIsFoo() + SwigGetFoo() Foo + SwigGetBar() (_swig_ret Bar) +} + +type SwigcptrFooBar3 uintptr + +func (p SwigcptrFooBar3) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrFooBar3) SwigIsFooBar3() { +} + +var _wrap_FooBar3_blah__SWIG_0_0 unsafe.Pointer + +func _swig_wrap_FooBar3_blah__SWIG_0_0(base SwigcptrFooBar3, _ int) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_FooBar3_blah__SWIG_0_0, _swig_p) + return +} + +func (arg1 SwigcptrFooBar3) Blah__SWIG_0_0(arg2 int) (_swig_ret int) { + return _swig_wrap_FooBar3_blah__SWIG_0_0(arg1, arg2) +} + +var _wrap_FooBar3_blah__SWIG_1 unsafe.Pointer + +func _swig_wrap_FooBar3_blah__SWIG_1(base SwigcptrFooBar3, _ string) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_FooBar3_blah__SWIG_1, _swig_p) + return +} + +func (arg1 SwigcptrFooBar3) Blah__SWIG_1(arg2 string) (_swig_ret string) { + return _swig_wrap_FooBar3_blah__SWIG_1(arg1, arg2) +} + +var _wrap_FooBar3_blah__SWIG_2_0 unsafe.Pointer + +func _swig_wrap_FooBar3_blah__SWIG_2_0(base SwigcptrFooBar3, _ float64) (_ float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_FooBar3_blah__SWIG_2_0, _swig_p) + return +} + +func (arg1 SwigcptrFooBar3) Blah__SWIG_2_0(arg2 float64) (_swig_ret float64) { + return _swig_wrap_FooBar3_blah__SWIG_2_0(arg1, arg2) +} + +func (p SwigcptrFooBar3) Blah(a ...interface{}) interface{} { + argc := len(a) + if argc == 1 { + if _, ok := a[0].(int); !ok { + goto check_1 + } + return p.Blah__SWIG_0_0(a[0].(int)) + } +check_1: + if argc == 1 { + if _, ok := a[0].(float64); !ok { + goto check_2 + } + return p.Blah__SWIG_2_0(a[0].(float64)) + } +check_2: + if argc == 1 { + return p.Blah__SWIG_1(a[0].(string)) + } + panic("No match for overloaded function call") +} + +var _wrap_new_FooBar3 unsafe.Pointer + +func _swig_wrap_new_FooBar3() (base SwigcptrFooBar3) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_FooBar3, _swig_p) + return +} + +func NewFooBar3() (_swig_ret FooBar3) { + return _swig_wrap_new_FooBar3() +} + +var _wrap_delete_FooBar3 unsafe.Pointer + +func _swig_wrap_delete_FooBar3(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_FooBar3, _swig_p) + return +} + +func DeleteFooBar3(arg1 FooBar3) { + _swig_wrap_delete_FooBar3(arg1.Swigcptr()) +} + +func (p SwigcptrFooBar3) SwigIsFoo() { +} + +func (p SwigcptrFooBar3) SwigGetFoo() Foo { + return SwigcptrFoo(p.Swigcptr()) +} + +var _wrap_FooBar3_SwigGetBar unsafe.Pointer + +func _swig_wrap_FooBar3_SwigGetBar(base SwigcptrFooBar3) (_ SwigcptrBar) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_FooBar3_SwigGetBar, _swig_p) + return +} + +func (arg1 SwigcptrFooBar3) SwigGetBar() (_swig_ret Bar) { + return _swig_wrap_FooBar3_SwigGetBar(arg1) +} + +type FooBar3 interface { + Swigcptr() uintptr + SwigIsFooBar3() + Blah(a ...interface{}) interface{} + SwigIsFoo() + SwigGetFoo() Foo + SwigGetBar() (_swig_ret Bar) +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/using_composition_runme b/Examples/test-suite/go/using_composition_runme new file mode 100755 index 000000000..c8a0dc3cf Binary files /dev/null and b/Examples/test-suite/go/using_composition_runme differ diff --git a/Examples/test-suite/go/using_directive_and_declaration.go b/Examples/test-suite/go/using_directive_and_declaration.go new file mode 100644 index 000000000..13e2a6825 --- /dev/null +++ b/Examples/test-suite/go/using_directive_and_declaration.go @@ -0,0 +1,499 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../using_directive_and_declaration.i + +package using_directive_and_declaration + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrThing1 uintptr + +func (p SwigcptrThing1) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrThing1) SwigIsThing1() { +} + +var _wrap_new_Thing1 unsafe.Pointer + +func _swig_wrap_new_Thing1() (base SwigcptrThing1) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Thing1, _swig_p) + return +} + +func NewThing1() (_swig_ret Thing1) { + return _swig_wrap_new_Thing1() +} + +var _wrap_delete_Thing1 unsafe.Pointer + +func _swig_wrap_delete_Thing1(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Thing1, _swig_p) + return +} + +func DeleteThing1(arg1 Thing1) { + _swig_wrap_delete_Thing1(arg1.Swigcptr()) +} + +type Thing1 interface { + Swigcptr() uintptr + SwigIsThing1() +} + +var _wrap_useit1 unsafe.Pointer + +func _swig_wrap_useit1(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_useit1, _swig_p) + return +} + +func Useit1(arg1 Thing1) { + _swig_wrap_useit1(arg1.Swigcptr()) +} + +type SwigcptrThing2 uintptr + +func (p SwigcptrThing2) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrThing2) SwigIsThing2() { +} + +var _wrap_new_Thing2 unsafe.Pointer + +func _swig_wrap_new_Thing2() (base SwigcptrThing2) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Thing2, _swig_p) + return +} + +func NewThing2() (_swig_ret Thing2) { + return _swig_wrap_new_Thing2() +} + +var _wrap_delete_Thing2 unsafe.Pointer + +func _swig_wrap_delete_Thing2(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Thing2, _swig_p) + return +} + +func DeleteThing2(arg1 Thing2) { + _swig_wrap_delete_Thing2(arg1.Swigcptr()) +} + +type Thing2 interface { + Swigcptr() uintptr + SwigIsThing2() +} + +var _wrap_useit2 unsafe.Pointer + +func _swig_wrap_useit2(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_useit2, _swig_p) + return +} + +func Useit2(arg1 Thing2) { + _swig_wrap_useit2(arg1.Swigcptr()) +} + +type SwigcptrThing3 uintptr + +func (p SwigcptrThing3) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrThing3) SwigIsThing3() { +} + +var _wrap_new_Thing3 unsafe.Pointer + +func _swig_wrap_new_Thing3() (base SwigcptrThing3) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Thing3, _swig_p) + return +} + +func NewThing3() (_swig_ret Thing3) { + return _swig_wrap_new_Thing3() +} + +var _wrap_delete_Thing3 unsafe.Pointer + +func _swig_wrap_delete_Thing3(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Thing3, _swig_p) + return +} + +func DeleteThing3(arg1 Thing3) { + _swig_wrap_delete_Thing3(arg1.Swigcptr()) +} + +type Thing3 interface { + Swigcptr() uintptr + SwigIsThing3() +} + +var _wrap_useit3 unsafe.Pointer + +func _swig_wrap_useit3(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_useit3, _swig_p) + return +} + +func Useit3(arg1 Thing3) { + _swig_wrap_useit3(arg1.Swigcptr()) +} + +type SwigcptrThing4 uintptr + +func (p SwigcptrThing4) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrThing4) SwigIsThing4() { +} + +var _wrap_new_Thing4 unsafe.Pointer + +func _swig_wrap_new_Thing4() (base SwigcptrThing4) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Thing4, _swig_p) + return +} + +func NewThing4() (_swig_ret Thing4) { + return _swig_wrap_new_Thing4() +} + +var _wrap_delete_Thing4 unsafe.Pointer + +func _swig_wrap_delete_Thing4(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Thing4, _swig_p) + return +} + +func DeleteThing4(arg1 Thing4) { + _swig_wrap_delete_Thing4(arg1.Swigcptr()) +} + +type Thing4 interface { + Swigcptr() uintptr + SwigIsThing4() +} + +var _wrap_useit4 unsafe.Pointer + +func _swig_wrap_useit4(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_useit4, _swig_p) + return +} + +func Useit4(arg1 Thing4) { + _swig_wrap_useit4(arg1.Swigcptr()) +} + +type SwigcptrThing5 uintptr + +func (p SwigcptrThing5) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrThing5) SwigIsThing5() { +} + +var _wrap_new_Thing5 unsafe.Pointer + +func _swig_wrap_new_Thing5() (base SwigcptrThing5) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Thing5, _swig_p) + return +} + +func NewThing5() (_swig_ret Thing5) { + return _swig_wrap_new_Thing5() +} + +var _wrap_delete_Thing5 unsafe.Pointer + +func _swig_wrap_delete_Thing5(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Thing5, _swig_p) + return +} + +func DeleteThing5(arg1 Thing5) { + _swig_wrap_delete_Thing5(arg1.Swigcptr()) +} + +type Thing5 interface { + Swigcptr() uintptr + SwigIsThing5() +} + +var _wrap_useit5 unsafe.Pointer + +func _swig_wrap_useit5(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_useit5, _swig_p) + return +} + +func Useit5(arg1 Thing5) { + _swig_wrap_useit5(arg1.Swigcptr()) +} + +type SwigcptrThing6a uintptr + +func (p SwigcptrThing6a) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrThing6a) SwigIsThing6a() { +} + +var _wrap_Thing6a_a unsafe.Pointer + +func _swig_wrap_Thing6a_a(base SwigcptrThing6a) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Thing6a_a, _swig_p) + return +} + +func (arg1 SwigcptrThing6a) A() { + _swig_wrap_Thing6a_a(arg1) +} + +var _wrap_new_Thing6a unsafe.Pointer + +func _swig_wrap_new_Thing6a() (base SwigcptrThing6a) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Thing6a, _swig_p) + return +} + +func NewThing6a() (_swig_ret Thing6a) { + return _swig_wrap_new_Thing6a() +} + +var _wrap_delete_Thing6a unsafe.Pointer + +func _swig_wrap_delete_Thing6a(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Thing6a, _swig_p) + return +} + +func DeleteThing6a(arg1 Thing6a) { + _swig_wrap_delete_Thing6a(arg1.Swigcptr()) +} + +type Thing6a interface { + Swigcptr() uintptr + SwigIsThing6a() + A() +} + +type SwigcptrThing6 uintptr + +func (p SwigcptrThing6) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrThing6) SwigIsThing6() { +} + +var _wrap_Thing6_b unsafe.Pointer + +func _swig_wrap_Thing6_b(base SwigcptrThing6) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Thing6_b, _swig_p) + return +} + +func (arg1 SwigcptrThing6) B() { + _swig_wrap_Thing6_b(arg1) +} + +var _wrap_new_Thing6 unsafe.Pointer + +func _swig_wrap_new_Thing6() (base SwigcptrThing6) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Thing6, _swig_p) + return +} + +func NewThing6() (_swig_ret Thing6) { + return _swig_wrap_new_Thing6() +} + +var _wrap_delete_Thing6 unsafe.Pointer + +func _swig_wrap_delete_Thing6(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Thing6, _swig_p) + return +} + +func DeleteThing6(arg1 Thing6) { + _swig_wrap_delete_Thing6(arg1.Swigcptr()) +} + +type Thing6 interface { + Swigcptr() uintptr + SwigIsThing6() + B() +} + +var _wrap_useit6 unsafe.Pointer + +func _swig_wrap_useit6(base uintptr, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_useit6, _swig_p) + return +} + +func Useit6(arg1 Thing6a, arg2 Thing6) { + _swig_wrap_useit6(arg1.Swigcptr(), arg2.Swigcptr()) +} + +type SwigcptrThing7 uintptr + +func (p SwigcptrThing7) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrThing7) SwigIsThing7() { +} + +var _wrap_new_Thing7 unsafe.Pointer + +func _swig_wrap_new_Thing7() (base SwigcptrThing7) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Thing7, _swig_p) + return +} + +func NewThing7() (_swig_ret Thing7) { + return _swig_wrap_new_Thing7() +} + +var _wrap_delete_Thing7 unsafe.Pointer + +func _swig_wrap_delete_Thing7(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Thing7, _swig_p) + return +} + +func DeleteThing7(arg1 Thing7) { + _swig_wrap_delete_Thing7(arg1.Swigcptr()) +} + +type Thing7 interface { + Swigcptr() uintptr + SwigIsThing7() +} + +var _wrap_useit7 unsafe.Pointer + +func _swig_wrap_useit7(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_useit7, _swig_p) + return +} + +func Useit7(arg1 Thing7) { + _swig_wrap_useit7(arg1.Swigcptr()) +} + +var _wrap_useit7a unsafe.Pointer + +func _swig_wrap_useit7a(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_useit7a, _swig_p) + return +} + +func Useit7a(arg1 Thing7) { + _swig_wrap_useit7a(arg1.Swigcptr()) +} + +var _wrap_useit7b unsafe.Pointer + +func _swig_wrap_useit7b(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_useit7b, _swig_p) + return +} + +func Useit7b(arg1 Thing7) { + _swig_wrap_useit7b(arg1.Swigcptr()) +} + +var _wrap_useit7c unsafe.Pointer + +func _swig_wrap_useit7c(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_useit7c, _swig_p) + return +} + +func Useit7c(arg1 Thing7) { + _swig_wrap_useit7c(arg1.Swigcptr()) +} + +var _wrap_useit7d unsafe.Pointer + +func _swig_wrap_useit7d(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_useit7d, _swig_p) + return +} + +func Useit7d(arg1 Thing7) { + _swig_wrap_useit7d(arg1.Swigcptr()) +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/using_directive_and_declaration_forward.go b/Examples/test-suite/go/using_directive_and_declaration_forward.go new file mode 100644 index 000000000..8d8fe2893 --- /dev/null +++ b/Examples/test-suite/go/using_directive_and_declaration_forward.go @@ -0,0 +1,613 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../using_directive_and_declaration_forward.i + +package using_directive_and_declaration_forward + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrThing1 uintptr + +func (p SwigcptrThing1) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrThing1) SwigIsThing1() { +} + +var _wrap_new_Thing1 unsafe.Pointer + +func _swig_wrap_new_Thing1() (base SwigcptrThing1) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Thing1, _swig_p) + return +} + +func NewThing1() (_swig_ret Thing1) { + return _swig_wrap_new_Thing1() +} + +var _wrap_delete_Thing1 unsafe.Pointer + +func _swig_wrap_delete_Thing1(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Thing1, _swig_p) + return +} + +func DeleteThing1(arg1 Thing1) { + _swig_wrap_delete_Thing1(arg1.Swigcptr()) +} + +type Thing1 interface { + Swigcptr() uintptr + SwigIsThing1() +} + +var _wrap_useit1 unsafe.Pointer + +func _swig_wrap_useit1(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_useit1, _swig_p) + return +} + +func Useit1(arg1 Thing1) { + _swig_wrap_useit1(arg1.Swigcptr()) +} + +var _wrap_useit1a unsafe.Pointer + +func _swig_wrap_useit1a(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_useit1a, _swig_p) + return +} + +func Useit1a(arg1 Thing1) { + _swig_wrap_useit1a(arg1.Swigcptr()) +} + +var _wrap_useit1b unsafe.Pointer + +func _swig_wrap_useit1b(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_useit1b, _swig_p) + return +} + +func Useit1b(arg1 Thing1) { + _swig_wrap_useit1b(arg1.Swigcptr()) +} + +var _wrap_useit1c unsafe.Pointer + +func _swig_wrap_useit1c(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_useit1c, _swig_p) + return +} + +func Useit1c(arg1 Thing1) { + _swig_wrap_useit1c(arg1.Swigcptr()) +} + +type SwigcptrThing2 uintptr + +func (p SwigcptrThing2) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrThing2) SwigIsThing2() { +} + +var _wrap_new_Thing2 unsafe.Pointer + +func _swig_wrap_new_Thing2() (base SwigcptrThing2) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Thing2, _swig_p) + return +} + +func NewThing2() (_swig_ret Thing2) { + return _swig_wrap_new_Thing2() +} + +var _wrap_delete_Thing2 unsafe.Pointer + +func _swig_wrap_delete_Thing2(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Thing2, _swig_p) + return +} + +func DeleteThing2(arg1 Thing2) { + _swig_wrap_delete_Thing2(arg1.Swigcptr()) +} + +type Thing2 interface { + Swigcptr() uintptr + SwigIsThing2() +} + +var _wrap_useit2 unsafe.Pointer + +func _swig_wrap_useit2(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_useit2, _swig_p) + return +} + +func Useit2(arg1 Thing2) { + _swig_wrap_useit2(arg1.Swigcptr()) +} + +var _wrap_useit2a unsafe.Pointer + +func _swig_wrap_useit2a(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_useit2a, _swig_p) + return +} + +func Useit2a(arg1 Thing2) { + _swig_wrap_useit2a(arg1.Swigcptr()) +} + +var _wrap_useit2b unsafe.Pointer + +func _swig_wrap_useit2b(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_useit2b, _swig_p) + return +} + +func Useit2b(arg1 Thing2) { + _swig_wrap_useit2b(arg1.Swigcptr()) +} + +var _wrap_useit2c unsafe.Pointer + +func _swig_wrap_useit2c(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_useit2c, _swig_p) + return +} + +func Useit2c(arg1 Thing2) { + _swig_wrap_useit2c(arg1.Swigcptr()) +} + +var _wrap_useit2d unsafe.Pointer + +func _swig_wrap_useit2d(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_useit2d, _swig_p) + return +} + +func Useit2d(arg1 Thing2) { + _swig_wrap_useit2d(arg1.Swigcptr()) +} + +type SwigcptrThing3 uintptr + +func (p SwigcptrThing3) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrThing3) SwigIsThing3() { +} + +var _wrap_new_Thing3 unsafe.Pointer + +func _swig_wrap_new_Thing3() (base SwigcptrThing3) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Thing3, _swig_p) + return +} + +func NewThing3() (_swig_ret Thing3) { + return _swig_wrap_new_Thing3() +} + +var _wrap_delete_Thing3 unsafe.Pointer + +func _swig_wrap_delete_Thing3(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Thing3, _swig_p) + return +} + +func DeleteThing3(arg1 Thing3) { + _swig_wrap_delete_Thing3(arg1.Swigcptr()) +} + +type Thing3 interface { + Swigcptr() uintptr + SwigIsThing3() +} + +var _wrap_useit3 unsafe.Pointer + +func _swig_wrap_useit3(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_useit3, _swig_p) + return +} + +func Useit3(arg1 Thing3) { + _swig_wrap_useit3(arg1.Swigcptr()) +} + +var _wrap_useit3a unsafe.Pointer + +func _swig_wrap_useit3a(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_useit3a, _swig_p) + return +} + +func Useit3a(arg1 Thing3) { + _swig_wrap_useit3a(arg1.Swigcptr()) +} + +var _wrap_useit3b unsafe.Pointer + +func _swig_wrap_useit3b(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_useit3b, _swig_p) + return +} + +func Useit3b(arg1 Thing3) { + _swig_wrap_useit3b(arg1.Swigcptr()) +} + +var _wrap_useit3c unsafe.Pointer + +func _swig_wrap_useit3c(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_useit3c, _swig_p) + return +} + +func Useit3c(arg1 Thing3) { + _swig_wrap_useit3c(arg1.Swigcptr()) +} + +var _wrap_useit3d unsafe.Pointer + +func _swig_wrap_useit3d(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_useit3d, _swig_p) + return +} + +func Useit3d(arg1 Thing3) { + _swig_wrap_useit3d(arg1.Swigcptr()) +} + +type SwigcptrThing4 uintptr + +func (p SwigcptrThing4) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrThing4) SwigIsThing4() { +} + +var _wrap_new_Thing4 unsafe.Pointer + +func _swig_wrap_new_Thing4() (base SwigcptrThing4) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Thing4, _swig_p) + return +} + +func NewThing4() (_swig_ret Thing4) { + return _swig_wrap_new_Thing4() +} + +var _wrap_delete_Thing4 unsafe.Pointer + +func _swig_wrap_delete_Thing4(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Thing4, _swig_p) + return +} + +func DeleteThing4(arg1 Thing4) { + _swig_wrap_delete_Thing4(arg1.Swigcptr()) +} + +type Thing4 interface { + Swigcptr() uintptr + SwigIsThing4() +} + +var _wrap_useit4 unsafe.Pointer + +func _swig_wrap_useit4(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_useit4, _swig_p) + return +} + +func Useit4(arg1 Thing4) { + _swig_wrap_useit4(arg1.Swigcptr()) +} + +var _wrap_useit4a unsafe.Pointer + +func _swig_wrap_useit4a(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_useit4a, _swig_p) + return +} + +func Useit4a(arg1 Thing4) { + _swig_wrap_useit4a(arg1.Swigcptr()) +} + +var _wrap_useit4b unsafe.Pointer + +func _swig_wrap_useit4b(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_useit4b, _swig_p) + return +} + +func Useit4b(arg1 Thing4) { + _swig_wrap_useit4b(arg1.Swigcptr()) +} + +var _wrap_useit4c unsafe.Pointer + +func _swig_wrap_useit4c(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_useit4c, _swig_p) + return +} + +func Useit4c(arg1 Thing4) { + _swig_wrap_useit4c(arg1.Swigcptr()) +} + +var _wrap_useit4d unsafe.Pointer + +func _swig_wrap_useit4d(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_useit4d, _swig_p) + return +} + +func Useit4d(arg1 Thing4) { + _swig_wrap_useit4d(arg1.Swigcptr()) +} + +type SwigcptrThing5 uintptr + +func (p SwigcptrThing5) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrThing5) SwigIsThing5() { +} + +var _wrap_new_Thing5 unsafe.Pointer + +func _swig_wrap_new_Thing5() (base SwigcptrThing5) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Thing5, _swig_p) + return +} + +func NewThing5() (_swig_ret Thing5) { + return _swig_wrap_new_Thing5() +} + +var _wrap_delete_Thing5 unsafe.Pointer + +func _swig_wrap_delete_Thing5(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Thing5, _swig_p) + return +} + +func DeleteThing5(arg1 Thing5) { + _swig_wrap_delete_Thing5(arg1.Swigcptr()) +} + +type Thing5 interface { + Swigcptr() uintptr + SwigIsThing5() +} + +var _wrap_useit5 unsafe.Pointer + +func _swig_wrap_useit5(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_useit5, _swig_p) + return +} + +func Useit5(arg1 Thing5) { + _swig_wrap_useit5(arg1.Swigcptr()) +} + +var _wrap_useit5a unsafe.Pointer + +func _swig_wrap_useit5a(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_useit5a, _swig_p) + return +} + +func Useit5a(arg1 Thing5) { + _swig_wrap_useit5a(arg1.Swigcptr()) +} + +var _wrap_useit5b unsafe.Pointer + +func _swig_wrap_useit5b(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_useit5b, _swig_p) + return +} + +func Useit5b(arg1 Thing5) { + _swig_wrap_useit5b(arg1.Swigcptr()) +} + +var _wrap_useit5c unsafe.Pointer + +func _swig_wrap_useit5c(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_useit5c, _swig_p) + return +} + +func Useit5c(arg1 Thing5) { + _swig_wrap_useit5c(arg1.Swigcptr()) +} + +var _wrap_useit5d unsafe.Pointer + +func _swig_wrap_useit5d(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_useit5d, _swig_p) + return +} + +func Useit5d(arg1 Thing5) { + _swig_wrap_useit5d(arg1.Swigcptr()) +} + +type SwigcptrThing7 uintptr + +func (p SwigcptrThing7) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrThing7) SwigIsThing7() { +} + +var _wrap_new_Thing7 unsafe.Pointer + +func _swig_wrap_new_Thing7() (base SwigcptrThing7) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Thing7, _swig_p) + return +} + +func NewThing7() (_swig_ret Thing7) { + return _swig_wrap_new_Thing7() +} + +var _wrap_delete_Thing7 unsafe.Pointer + +func _swig_wrap_delete_Thing7(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Thing7, _swig_p) + return +} + +func DeleteThing7(arg1 Thing7) { + _swig_wrap_delete_Thing7(arg1.Swigcptr()) +} + +type Thing7 interface { + Swigcptr() uintptr + SwigIsThing7() +} + +var _wrap_useit7 unsafe.Pointer + +func _swig_wrap_useit7(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_useit7, _swig_p) + return +} + +func Useit7(arg1 Thing7) { + _swig_wrap_useit7(arg1.Swigcptr()) +} + +var _wrap_useit7a unsafe.Pointer + +func _swig_wrap_useit7a(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_useit7a, _swig_p) + return +} + +func Useit7a(arg1 Thing7) { + _swig_wrap_useit7a(arg1.Swigcptr()) +} + +var _wrap_useit7b unsafe.Pointer + +func _swig_wrap_useit7b(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_useit7b, _swig_p) + return +} + +func Useit7b(arg1 Thing7) { + _swig_wrap_useit7b(arg1.Swigcptr()) +} + +var _wrap_useit7c unsafe.Pointer + +func _swig_wrap_useit7c(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_useit7c, _swig_p) + return +} + +func Useit7c(arg1 Thing7) { + _swig_wrap_useit7c(arg1.Swigcptr()) +} + +var _wrap_useit7d unsafe.Pointer + +func _swig_wrap_useit7d(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_useit7d, _swig_p) + return +} + +func Useit7d(arg1 Thing7) { + _swig_wrap_useit7d(arg1.Swigcptr()) +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/using_extend.go b/Examples/test-suite/go/using_extend.go new file mode 100644 index 000000000..4f9a30c1e --- /dev/null +++ b/Examples/test-suite/go/using_extend.go @@ -0,0 +1,412 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../using_extend.i + +package using_extend + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrFoo uintptr + +func (p SwigcptrFoo) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrFoo) SwigIsFoo() { +} + +var _wrap_Foo_blah__SWIG_0 unsafe.Pointer + +func _swig_wrap_Foo_blah__SWIG_0(base SwigcptrFoo, _ int) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_blah__SWIG_0, _swig_p) + return +} + +func (arg1 SwigcptrFoo) Blah__SWIG_0(arg2 int) (_swig_ret int) { + return _swig_wrap_Foo_blah__SWIG_0(arg1, arg2) +} + +var _wrap_Foo_blah__SWIG_1 unsafe.Pointer + +func _swig_wrap_Foo_blah__SWIG_1(base SwigcptrFoo, _ string) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_blah__SWIG_1, _swig_p) + return +} + +func (arg1 SwigcptrFoo) Blah__SWIG_1(arg2 string) (_swig_ret string) { + return _swig_wrap_Foo_blah__SWIG_1(arg1, arg2) +} + +var _wrap_Foo_blah__SWIG_2 unsafe.Pointer + +func _swig_wrap_Foo_blah__SWIG_2(base SwigcptrFoo, _ int, _ int) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_blah__SWIG_2, _swig_p) + return +} + +func (arg1 SwigcptrFoo) Blah__SWIG_2(arg2 int, arg3 int) (_swig_ret int) { + return _swig_wrap_Foo_blah__SWIG_2(arg1, arg2, arg3) +} + +func (p SwigcptrFoo) Blah(a ...interface{}) interface{} { + argc := len(a) + if argc == 1 { + if _, ok := a[0].(int); !ok { + goto check_1 + } + return p.Blah__SWIG_0(a[0].(int)) + } +check_1: + if argc == 1 { + return p.Blah__SWIG_1(a[0].(string)) + } + if argc == 2 { + return p.Blah__SWIG_2(a[0].(int), a[1].(int)) + } + panic("No match for overloaded function call") +} + +var _wrap_new_Foo unsafe.Pointer + +func _swig_wrap_new_Foo() (base SwigcptrFoo) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Foo, _swig_p) + return +} + +func NewFoo() (_swig_ret Foo) { + return _swig_wrap_new_Foo() +} + +var _wrap_delete_Foo unsafe.Pointer + +func _swig_wrap_delete_Foo(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Foo, _swig_p) + return +} + +func DeleteFoo(arg1 Foo) { + _swig_wrap_delete_Foo(arg1.Swigcptr()) +} + +type Foo interface { + Swigcptr() uintptr + SwigIsFoo() + Blah(a ...interface{}) interface{} +} + +type SwigcptrBar uintptr + +func (p SwigcptrBar) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrBar) SwigIsBar() { +} + +var _wrap_Bar_duh1 unsafe.Pointer + +func _swig_wrap_Bar_duh1(base SwigcptrBar) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Bar_duh1, _swig_p) + return +} + +func (arg1 SwigcptrBar) Duh1() (_swig_ret int) { + return _swig_wrap_Bar_duh1(arg1) +} + +var _wrap_Bar_duh unsafe.Pointer + +func _swig_wrap_Bar_duh(base SwigcptrBar, _ int) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Bar_duh, _swig_p) + return +} + +func (arg1 SwigcptrBar) Duh(arg2 int) (_swig_ret int) { + return _swig_wrap_Bar_duh(arg1, arg2) +} + +var _wrap_Bar_blah__SWIG_0 unsafe.Pointer + +func _swig_wrap_Bar_blah__SWIG_0(base SwigcptrBar, _ float64) (_ float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Bar_blah__SWIG_0, _swig_p) + return +} + +func (arg1 SwigcptrBar) Blah__SWIG_0(arg2 float64) (_swig_ret float64) { + return _swig_wrap_Bar_blah__SWIG_0(arg1, arg2) +} + +var _wrap_Bar_blah__SWIG_1 unsafe.Pointer + +func _swig_wrap_Bar_blah__SWIG_1(base SwigcptrBar, _ float64, _ float64) (_ float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Bar_blah__SWIG_1, _swig_p) + return +} + +func (arg1 SwigcptrBar) Blah__SWIG_1(arg2 float64, arg3 float64) (_swig_ret float64) { + return _swig_wrap_Bar_blah__SWIG_1(arg1, arg2, arg3) +} + +func (p SwigcptrBar) Blah(a ...interface{}) float64 { + argc := len(a) + if argc == 1 { + return p.Blah__SWIG_0(a[0].(float64)) + } + if argc == 2 { + return p.Blah__SWIG_1(a[0].(float64), a[1].(float64)) + } + panic("No match for overloaded function call") +} + +var _wrap_new_Bar unsafe.Pointer + +func _swig_wrap_new_Bar() (base SwigcptrBar) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Bar, _swig_p) + return +} + +func NewBar() (_swig_ret Bar) { + return _swig_wrap_new_Bar() +} + +var _wrap_delete_Bar unsafe.Pointer + +func _swig_wrap_delete_Bar(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Bar, _swig_p) + return +} + +func DeleteBar(arg1 Bar) { + _swig_wrap_delete_Bar(arg1.Swigcptr()) +} + +type Bar interface { + Swigcptr() uintptr + SwigIsBar() + Duh1() (_swig_ret int) + Duh(arg2 int) (_swig_ret int) + Blah(a ...interface{}) float64 +} + +type SwigcptrFooBar uintptr + +func (p SwigcptrFooBar) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrFooBar) SwigIsFooBar() { +} + +var _wrap_FooBar_blah__SWIG_0_0 unsafe.Pointer + +func _swig_wrap_FooBar_blah__SWIG_0_0(base SwigcptrFooBar, _ int) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_FooBar_blah__SWIG_0_0, _swig_p) + return +} + +func (arg1 SwigcptrFooBar) Blah__SWIG_0_0(arg2 int) (_swig_ret int) { + return _swig_wrap_FooBar_blah__SWIG_0_0(arg1, arg2) +} + +var _wrap_FooBar_blah__SWIG_0_1 unsafe.Pointer + +func _swig_wrap_FooBar_blah__SWIG_0_1(base SwigcptrFooBar, _ int, _ int) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_FooBar_blah__SWIG_0_1, _swig_p) + return +} + +func (arg1 SwigcptrFooBar) Blah__SWIG_0_1(arg2 int, arg3 int) (_swig_ret int) { + return _swig_wrap_FooBar_blah__SWIG_0_1(arg1, arg2, arg3) +} + +var _wrap_FooBar_blah__SWIG_1_0 unsafe.Pointer + +func _swig_wrap_FooBar_blah__SWIG_1_0(base SwigcptrFooBar, _ float64) (_ float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_FooBar_blah__SWIG_1_0, _swig_p) + return +} + +func (arg1 SwigcptrFooBar) Blah__SWIG_1_0(arg2 float64) (_swig_ret float64) { + return _swig_wrap_FooBar_blah__SWIG_1_0(arg1, arg2) +} + +var _wrap_FooBar_blah__SWIG_1_1 unsafe.Pointer + +func _swig_wrap_FooBar_blah__SWIG_1_1(base SwigcptrFooBar, _ float64, _ float64) (_ float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_FooBar_blah__SWIG_1_1, _swig_p) + return +} + +func (arg1 SwigcptrFooBar) Blah__SWIG_1_1(arg2 float64, arg3 float64) (_swig_ret float64) { + return _swig_wrap_FooBar_blah__SWIG_1_1(arg1, arg2, arg3) +} + +var _wrap_FooBar_blah__SWIG_2 unsafe.Pointer + +func _swig_wrap_FooBar_blah__SWIG_2(base SwigcptrFooBar, _ string) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_FooBar_blah__SWIG_2, _swig_p) + return +} + +func (arg1 SwigcptrFooBar) Blah__SWIG_2(arg2 string) (_swig_ret string) { + return _swig_wrap_FooBar_blah__SWIG_2(arg1, arg2) +} + +func (p SwigcptrFooBar) Blah(a ...interface{}) interface{} { + argc := len(a) + if argc == 1 { + if _, ok := a[0].(int); !ok { + goto check_1 + } + return p.Blah__SWIG_0_0(a[0].(int)) + } +check_1: + if argc == 1 { + if _, ok := a[0].(float64); !ok { + goto check_2 + } + return p.Blah__SWIG_1_0(a[0].(float64)) + } +check_2: + if argc == 1 { + return p.Blah__SWIG_2(a[0].(string)) + } + if argc == 2 { + if _, ok := a[0].(int); !ok { + goto check_4 + } + if _, ok := a[1].(int); !ok { + goto check_4 + } + return p.Blah__SWIG_0_1(a[0].(int), a[1].(int)) + } +check_4: + if argc == 2 { + return p.Blah__SWIG_1_1(a[0].(float64), a[1].(float64)) + } + panic("No match for overloaded function call") +} + +var _wrap_FooBar_duh1 unsafe.Pointer + +func _swig_wrap_FooBar_duh1(base SwigcptrFooBar) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_FooBar_duh1, _swig_p) + return +} + +func (arg1 SwigcptrFooBar) Duh1() (_swig_ret int) { + return _swig_wrap_FooBar_duh1(arg1) +} + +var _wrap_FooBar_duh unsafe.Pointer + +func _swig_wrap_FooBar_duh(base SwigcptrFooBar, _ int) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_FooBar_duh, _swig_p) + return +} + +func (arg1 SwigcptrFooBar) Duh(arg2 int) (_swig_ret int) { + return _swig_wrap_FooBar_duh(arg1, arg2) +} + +var _wrap_new_FooBar unsafe.Pointer + +func _swig_wrap_new_FooBar() (base SwigcptrFooBar) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_FooBar, _swig_p) + return +} + +func NewFooBar() (_swig_ret FooBar) { + return _swig_wrap_new_FooBar() +} + +var _wrap_delete_FooBar unsafe.Pointer + +func _swig_wrap_delete_FooBar(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_FooBar, _swig_p) + return +} + +func DeleteFooBar(arg1 FooBar) { + _swig_wrap_delete_FooBar(arg1.Swigcptr()) +} + +func (p SwigcptrFooBar) SwigIsFoo() { +} + +func (p SwigcptrFooBar) SwigGetFoo() Foo { + return SwigcptrFoo(p.Swigcptr()) +} + +var _wrap_FooBar_SwigGetBar unsafe.Pointer + +func _swig_wrap_FooBar_SwigGetBar(base SwigcptrFooBar) (_ SwigcptrBar) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_FooBar_SwigGetBar, _swig_p) + return +} + +func (arg1 SwigcptrFooBar) SwigGetBar() (_swig_ret Bar) { + return _swig_wrap_FooBar_SwigGetBar(arg1) +} + +type FooBar interface { + Swigcptr() uintptr + SwigIsFooBar() + Blah(a ...interface{}) interface{} + Duh1() (_swig_ret int) + Duh(arg2 int) (_swig_ret int) + SwigIsFoo() + SwigGetFoo() Foo + SwigGetBar() (_swig_ret Bar) +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/using_extend_runme b/Examples/test-suite/go/using_extend_runme new file mode 100755 index 000000000..79975e044 Binary files /dev/null and b/Examples/test-suite/go/using_extend_runme differ diff --git a/Examples/test-suite/go/using_inherit.go b/Examples/test-suite/go/using_inherit.go new file mode 100644 index 000000000..297cf1482 --- /dev/null +++ b/Examples/test-suite/go/using_inherit.go @@ -0,0 +1,637 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../using_inherit.i + +package using_inherit + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrFoo uintptr + +func (p SwigcptrFoo) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrFoo) SwigIsFoo() { +} + +var _wrap_Foo_test__SWIG_0 unsafe.Pointer + +func _swig_wrap_Foo_test__SWIG_0(base SwigcptrFoo, _ int) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_test__SWIG_0, _swig_p) + return +} + +func (arg1 SwigcptrFoo) Test__SWIG_0(arg2 int) (_swig_ret int) { + return _swig_wrap_Foo_test__SWIG_0(arg1, arg2) +} + +var _wrap_Foo_test__SWIG_1 unsafe.Pointer + +func _swig_wrap_Foo_test__SWIG_1(base SwigcptrFoo, _ float64) (_ float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_test__SWIG_1, _swig_p) + return +} + +func (arg1 SwigcptrFoo) Test__SWIG_1(arg2 float64) (_swig_ret float64) { + return _swig_wrap_Foo_test__SWIG_1(arg1, arg2) +} + +func (p SwigcptrFoo) Test(a ...interface{}) interface{} { + argc := len(a) + if argc == 1 { + if _, ok := a[0].(int); !ok { + goto check_1 + } + return p.Test__SWIG_0(a[0].(int)) + } +check_1: + if argc == 1 { + return p.Test__SWIG_1(a[0].(float64)) + } + panic("No match for overloaded function call") +} + +var _wrap_new_Foo unsafe.Pointer + +func _swig_wrap_new_Foo() (base SwigcptrFoo) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Foo, _swig_p) + return +} + +func NewFoo() (_swig_ret Foo) { + return _swig_wrap_new_Foo() +} + +var _wrap_delete_Foo unsafe.Pointer + +func _swig_wrap_delete_Foo(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Foo, _swig_p) + return +} + +func DeleteFoo(arg1 Foo) { + _swig_wrap_delete_Foo(arg1.Swigcptr()) +} + +type Foo interface { + Swigcptr() uintptr + SwigIsFoo() + Test(a ...interface{}) interface{} +} + +type SwigcptrBar uintptr + +func (p SwigcptrBar) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrBar) SwigIsBar() { +} + +var _wrap_Bar_test_SWIG_0_0 unsafe.Pointer + +func _swig_wrap_Bar_test_SWIG_0_0(base SwigcptrBar, _ int) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Bar_test_SWIG_0_0, _swig_p) + return +} + +func (arg1 SwigcptrBar) Test_SWIG_0_0(arg2 int) (_swig_ret int) { + return _swig_wrap_Bar_test_SWIG_0_0(arg1, arg2) +} + +var _wrap_Bar_test_SWIG_0_1 unsafe.Pointer + +func _swig_wrap_Bar_test_SWIG_0_1(base SwigcptrBar, _ float64) (_ float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Bar_test_SWIG_0_1, _swig_p) + return +} + +func (arg1 SwigcptrBar) Test_SWIG_0_1(arg2 float64) (_swig_ret float64) { + return _swig_wrap_Bar_test_SWIG_0_1(arg1, arg2) +} + +func (p SwigcptrBar) Test(a ...interface{}) interface{} { + argc := len(a) + if argc == 1 { + if _, ok := a[0].(int); !ok { + goto check_1 + } + return p.Test_SWIG_0_0(a[0].(int)) + } +check_1: + if argc == 1 { + return p.Test_SWIG_0_1(a[0].(float64)) + } + panic("No match for overloaded function call") +} + +var _wrap_new_Bar unsafe.Pointer + +func _swig_wrap_new_Bar() (base SwigcptrBar) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Bar, _swig_p) + return +} + +func NewBar() (_swig_ret Bar) { + return _swig_wrap_new_Bar() +} + +var _wrap_delete_Bar unsafe.Pointer + +func _swig_wrap_delete_Bar(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Bar, _swig_p) + return +} + +func DeleteBar(arg1 Bar) { + _swig_wrap_delete_Bar(arg1.Swigcptr()) +} + +func (p SwigcptrBar) SwigIsFoo() { +} + +func (p SwigcptrBar) SwigGetFoo() Foo { + return SwigcptrFoo(p.Swigcptr()) +} + +type Bar interface { + Swigcptr() uintptr + SwigIsBar() + Test(a ...interface{}) interface{} + SwigIsFoo() + SwigGetFoo() Foo +} + +type SwigcptrBar2 uintptr + +func (p SwigcptrBar2) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrBar2) SwigIsBar2() { +} + +var _wrap_Bar2_test__SWIG_0 unsafe.Pointer + +func _swig_wrap_Bar2_test__SWIG_0(base SwigcptrBar2, _ int) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Bar2_test__SWIG_0, _swig_p) + return +} + +func (arg1 SwigcptrBar2) Test__SWIG_0(arg2 int) (_swig_ret int) { + return _swig_wrap_Bar2_test__SWIG_0(arg1, arg2) +} + +var _wrap_Bar2_test__SWIG_1 unsafe.Pointer + +func _swig_wrap_Bar2_test__SWIG_1(base SwigcptrBar2, _ float64) (_ float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Bar2_test__SWIG_1, _swig_p) + return +} + +func (arg1 SwigcptrBar2) Test__SWIG_1(arg2 float64) (_swig_ret float64) { + return _swig_wrap_Bar2_test__SWIG_1(arg1, arg2) +} + +func (p SwigcptrBar2) Test(a ...interface{}) interface{} { + argc := len(a) + if argc == 1 { + if _, ok := a[0].(int); !ok { + goto check_1 + } + return p.Test__SWIG_0(a[0].(int)) + } +check_1: + if argc == 1 { + return p.Test__SWIG_1(a[0].(float64)) + } + panic("No match for overloaded function call") +} + +var _wrap_new_Bar2 unsafe.Pointer + +func _swig_wrap_new_Bar2() (base SwigcptrBar2) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Bar2, _swig_p) + return +} + +func NewBar2() (_swig_ret Bar2) { + return _swig_wrap_new_Bar2() +} + +var _wrap_delete_Bar2 unsafe.Pointer + +func _swig_wrap_delete_Bar2(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Bar2, _swig_p) + return +} + +func DeleteBar2(arg1 Bar2) { + _swig_wrap_delete_Bar2(arg1.Swigcptr()) +} + +func (p SwigcptrBar2) SwigIsFoo() { +} + +func (p SwigcptrBar2) SwigGetFoo() Foo { + return SwigcptrFoo(p.Swigcptr()) +} + +type Bar2 interface { + Swigcptr() uintptr + SwigIsBar2() + Test(a ...interface{}) interface{} + SwigIsFoo() + SwigGetFoo() Foo +} + +type SwigcptrBar3 uintptr + +func (p SwigcptrBar3) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrBar3) SwigIsBar3() { +} + +var _wrap_Bar3_test__SWIG_0 unsafe.Pointer + +func _swig_wrap_Bar3_test__SWIG_0(base SwigcptrBar3, _ int) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Bar3_test__SWIG_0, _swig_p) + return +} + +func (arg1 SwigcptrBar3) Test__SWIG_0(arg2 int) (_swig_ret int) { + return _swig_wrap_Bar3_test__SWIG_0(arg1, arg2) +} + +var _wrap_Bar3_test__SWIG_1 unsafe.Pointer + +func _swig_wrap_Bar3_test__SWIG_1(base SwigcptrBar3, _ float64) (_ float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Bar3_test__SWIG_1, _swig_p) + return +} + +func (arg1 SwigcptrBar3) Test__SWIG_1(arg2 float64) (_swig_ret float64) { + return _swig_wrap_Bar3_test__SWIG_1(arg1, arg2) +} + +func (p SwigcptrBar3) Test(a ...interface{}) interface{} { + argc := len(a) + if argc == 1 { + if _, ok := a[0].(int); !ok { + goto check_1 + } + return p.Test__SWIG_0(a[0].(int)) + } +check_1: + if argc == 1 { + return p.Test__SWIG_1(a[0].(float64)) + } + panic("No match for overloaded function call") +} + +var _wrap_new_Bar3 unsafe.Pointer + +func _swig_wrap_new_Bar3() (base SwigcptrBar3) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Bar3, _swig_p) + return +} + +func NewBar3() (_swig_ret Bar3) { + return _swig_wrap_new_Bar3() +} + +var _wrap_delete_Bar3 unsafe.Pointer + +func _swig_wrap_delete_Bar3(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Bar3, _swig_p) + return +} + +func DeleteBar3(arg1 Bar3) { + _swig_wrap_delete_Bar3(arg1.Swigcptr()) +} + +func (p SwigcptrBar3) SwigIsFoo() { +} + +func (p SwigcptrBar3) SwigGetFoo() Foo { + return SwigcptrFoo(p.Swigcptr()) +} + +type Bar3 interface { + Swigcptr() uintptr + SwigIsBar3() + Test(a ...interface{}) interface{} + SwigIsFoo() + SwigGetFoo() Foo +} + +type SwigcptrBar4 uintptr + +func (p SwigcptrBar4) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrBar4) SwigIsBar4() { +} + +var _wrap_Bar4_test__SWIG_0 unsafe.Pointer + +func _swig_wrap_Bar4_test__SWIG_0(base SwigcptrBar4, _ int) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Bar4_test__SWIG_0, _swig_p) + return +} + +func (arg1 SwigcptrBar4) Test__SWIG_0(arg2 int) (_swig_ret int) { + return _swig_wrap_Bar4_test__SWIG_0(arg1, arg2) +} + +var _wrap_Bar4_test__SWIG_2 unsafe.Pointer + +func _swig_wrap_Bar4_test__SWIG_2(base SwigcptrBar4, _ float64) (_ float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Bar4_test__SWIG_2, _swig_p) + return +} + +func (arg1 SwigcptrBar4) Test__SWIG_2(arg2 float64) (_swig_ret float64) { + return _swig_wrap_Bar4_test__SWIG_2(arg1, arg2) +} + +func (p SwigcptrBar4) Test(a ...interface{}) interface{} { + argc := len(a) + if argc == 1 { + if _, ok := a[0].(int); !ok { + goto check_1 + } + return p.Test__SWIG_0(a[0].(int)) + } +check_1: + if argc == 1 { + return p.Test__SWIG_2(a[0].(float64)) + } + panic("No match for overloaded function call") +} + +var _wrap_new_Bar4 unsafe.Pointer + +func _swig_wrap_new_Bar4() (base SwigcptrBar4) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Bar4, _swig_p) + return +} + +func NewBar4() (_swig_ret Bar4) { + return _swig_wrap_new_Bar4() +} + +var _wrap_delete_Bar4 unsafe.Pointer + +func _swig_wrap_delete_Bar4(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Bar4, _swig_p) + return +} + +func DeleteBar4(arg1 Bar4) { + _swig_wrap_delete_Bar4(arg1.Swigcptr()) +} + +func (p SwigcptrBar4) SwigIsFoo() { +} + +func (p SwigcptrBar4) SwigGetFoo() Foo { + return SwigcptrFoo(p.Swigcptr()) +} + +type Bar4 interface { + Swigcptr() uintptr + SwigIsBar4() + Test(a ...interface{}) interface{} + SwigIsFoo() + SwigGetFoo() Foo +} + +type SwigcptrFred1 uintptr + +func (p SwigcptrFred1) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrFred1) SwigIsFred1() { +} + +var _wrap_Fred1_test__SWIG_0_0 unsafe.Pointer + +func _swig_wrap_Fred1_test__SWIG_0_0(base SwigcptrFred1, _ int) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Fred1_test__SWIG_0_0, _swig_p) + return +} + +func (arg1 SwigcptrFred1) Test__SWIG_0_0(arg2 int) (_swig_ret int) { + return _swig_wrap_Fred1_test__SWIG_0_0(arg1, arg2) +} + +var _wrap_Fred1_test__SWIG_1 unsafe.Pointer + +func _swig_wrap_Fred1_test__SWIG_1(base SwigcptrFred1, _ float64) (_ float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Fred1_test__SWIG_1, _swig_p) + return +} + +func (arg1 SwigcptrFred1) Test__SWIG_1(arg2 float64) (_swig_ret float64) { + return _swig_wrap_Fred1_test__SWIG_1(arg1, arg2) +} + +func (p SwigcptrFred1) Test(a ...interface{}) interface{} { + argc := len(a) + if argc == 1 { + if _, ok := a[0].(int); !ok { + goto check_1 + } + return p.Test__SWIG_0_0(a[0].(int)) + } +check_1: + if argc == 1 { + return p.Test__SWIG_1(a[0].(float64)) + } + panic("No match for overloaded function call") +} + +var _wrap_new_Fred1 unsafe.Pointer + +func _swig_wrap_new_Fred1() (base SwigcptrFred1) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Fred1, _swig_p) + return +} + +func NewFred1() (_swig_ret Fred1) { + return _swig_wrap_new_Fred1() +} + +var _wrap_delete_Fred1 unsafe.Pointer + +func _swig_wrap_delete_Fred1(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Fred1, _swig_p) + return +} + +func DeleteFred1(arg1 Fred1) { + _swig_wrap_delete_Fred1(arg1.Swigcptr()) +} + +func (p SwigcptrFred1) SwigIsFoo() { +} + +func (p SwigcptrFred1) SwigGetFoo() Foo { + return SwigcptrFoo(p.Swigcptr()) +} + +type Fred1 interface { + Swigcptr() uintptr + SwigIsFred1() + Test(a ...interface{}) interface{} + SwigIsFoo() + SwigGetFoo() Foo +} + +type SwigcptrFred2 uintptr + +func (p SwigcptrFred2) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrFred2) SwigIsFred2() { +} + +var _wrap_Fred2_test__SWIG_0 unsafe.Pointer + +func _swig_wrap_Fred2_test__SWIG_0(base SwigcptrFred2, _ float64) (_ float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Fred2_test__SWIG_0, _swig_p) + return +} + +func (arg1 SwigcptrFred2) Test__SWIG_0(arg2 float64) (_swig_ret float64) { + return _swig_wrap_Fred2_test__SWIG_0(arg1, arg2) +} + +var _wrap_Fred2_test__SWIG_1_0 unsafe.Pointer + +func _swig_wrap_Fred2_test__SWIG_1_0(base SwigcptrFred2, _ int) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Fred2_test__SWIG_1_0, _swig_p) + return +} + +func (arg1 SwigcptrFred2) Test__SWIG_1_0(arg2 int) (_swig_ret int) { + return _swig_wrap_Fred2_test__SWIG_1_0(arg1, arg2) +} + +func (p SwigcptrFred2) Test(a ...interface{}) interface{} { + argc := len(a) + if argc == 1 { + if _, ok := a[0].(int); !ok { + goto check_1 + } + return p.Test__SWIG_1_0(a[0].(int)) + } +check_1: + if argc == 1 { + return p.Test__SWIG_0(a[0].(float64)) + } + panic("No match for overloaded function call") +} + +var _wrap_new_Fred2 unsafe.Pointer + +func _swig_wrap_new_Fred2() (base SwigcptrFred2) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Fred2, _swig_p) + return +} + +func NewFred2() (_swig_ret Fred2) { + return _swig_wrap_new_Fred2() +} + +var _wrap_delete_Fred2 unsafe.Pointer + +func _swig_wrap_delete_Fred2(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Fred2, _swig_p) + return +} + +func DeleteFred2(arg1 Fred2) { + _swig_wrap_delete_Fred2(arg1.Swigcptr()) +} + +func (p SwigcptrFred2) SwigIsFoo() { +} + +func (p SwigcptrFred2) SwigGetFoo() Foo { + return SwigcptrFoo(p.Swigcptr()) +} + +type Fred2 interface { + Swigcptr() uintptr + SwigIsFred2() + Test(a ...interface{}) interface{} + SwigIsFoo() + SwigGetFoo() Foo +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/using_inherit_runme b/Examples/test-suite/go/using_inherit_runme new file mode 100755 index 000000000..cdf7bf325 Binary files /dev/null and b/Examples/test-suite/go/using_inherit_runme differ diff --git a/Examples/test-suite/go/using_namespace.go b/Examples/test-suite/go/using_namespace.go new file mode 100644 index 000000000..96e735806 --- /dev/null +++ b/Examples/test-suite/go/using_namespace.go @@ -0,0 +1,334 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../using_namespace.i + +package using_namespace + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrHello uintptr + +func (p SwigcptrHello) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrHello) SwigIsHello() { +} + +var _wrap_new_Hello unsafe.Pointer + +func _swig_wrap_new_Hello() (base SwigcptrHello) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Hello, _swig_p) + return +} + +func NewHello() (_swig_ret Hello) { + return _swig_wrap_new_Hello() +} + +var _wrap_delete_Hello unsafe.Pointer + +func _swig_wrap_delete_Hello(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Hello, _swig_p) + return +} + +func DeleteHello(arg1 Hello) { + _swig_wrap_delete_Hello(arg1.Swigcptr()) +} + +type Hello interface { + Swigcptr() uintptr + SwigIsHello() +} + +type SwigcptrHi0 uintptr + +func (p SwigcptrHi0) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrHi0) SwigIsHi0() { +} + +var _wrap_new_hi0 unsafe.Pointer + +func _swig_wrap_new_hi0() (base SwigcptrHi0) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_hi0, _swig_p) + return +} + +func NewHi0() (_swig_ret Hi0) { + return _swig_wrap_new_hi0() +} + +var _wrap_delete_hi0 unsafe.Pointer + +func _swig_wrap_delete_hi0(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_hi0, _swig_p) + return +} + +func DeleteHi0(arg1 Hi0) { + _swig_wrap_delete_hi0(arg1.Swigcptr()) +} + +type Hi0 interface { + Swigcptr() uintptr + SwigIsHi0() +} + +type SwigcptrHi_hi0 uintptr + +func (p SwigcptrHi_hi0) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrHi_hi0) SwigIsHi_hi0() { +} + +var _wrap_Hi_hi0_value1 unsafe.Pointer + +func _swig_wrap_Hi_hi0_value1(base SwigcptrHi_hi0) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Hi_hi0_value1, _swig_p) + return +} + +func (arg1 SwigcptrHi_hi0) Value1() (_swig_ret int) { + return _swig_wrap_Hi_hi0_value1(arg1) +} + +var _wrap_Hi_hi0_value2 unsafe.Pointer + +func _swig_wrap_Hi_hi0_value2(base SwigcptrHi_hi0) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Hi_hi0_value2, _swig_p) + return +} + +func (arg1 SwigcptrHi_hi0) Value2() (_swig_ret int) { + return _swig_wrap_Hi_hi0_value2(arg1) +} + +var _wrap_new_Hi_hi0 unsafe.Pointer + +func _swig_wrap_new_Hi_hi0() (base SwigcptrHi_hi0) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Hi_hi0, _swig_p) + return +} + +func NewHi_hi0() (_swig_ret Hi_hi0) { + return _swig_wrap_new_Hi_hi0() +} + +var _wrap_delete_Hi_hi0 unsafe.Pointer + +func _swig_wrap_delete_Hi_hi0(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Hi_hi0, _swig_p) + return +} + +func DeleteHi_hi0(arg1 Hi_hi0) { + _swig_wrap_delete_Hi_hi0(arg1.Swigcptr()) +} + +func (p SwigcptrHi_hi0) SwigIsHello() { +} + +func (p SwigcptrHi_hi0) SwigGetHello() Hello { + return SwigcptrHello(p.Swigcptr()) +} + +var _wrap_Hi_hi0_SwigGetHi0 unsafe.Pointer + +func _swig_wrap_Hi_hi0_SwigGetHi0(base SwigcptrHi_hi0) (_ SwigcptrHi0) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Hi_hi0_SwigGetHi0, _swig_p) + return +} + +func (arg1 SwigcptrHi_hi0) SwigGetHi0() (_swig_ret Hi0) { + return _swig_wrap_Hi_hi0_SwigGetHi0(arg1) +} + +type Hi_hi0 interface { + Swigcptr() uintptr + SwigIsHi_hi0() + Value1() (_swig_ret int) + Value2() (_swig_ret int) + SwigIsHello() + SwigGetHello() Hello + SwigGetHi0() (_swig_ret Hi0) +} + +type SwigcptrHi1 uintptr + +func (p SwigcptrHi1) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrHi1) SwigIsHi1() { +} + +var _wrap_hi1_value1 unsafe.Pointer + +func _swig_wrap_hi1_value1(base SwigcptrHi1) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_hi1_value1, _swig_p) + return +} + +func (arg1 SwigcptrHi1) Value1() (_swig_ret int) { + return _swig_wrap_hi1_value1(arg1) +} + +var _wrap_hi1_value2 unsafe.Pointer + +func _swig_wrap_hi1_value2(base SwigcptrHi1) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_hi1_value2, _swig_p) + return +} + +func (arg1 SwigcptrHi1) Value2() (_swig_ret int) { + return _swig_wrap_hi1_value2(arg1) +} + +var _wrap_new_hi1 unsafe.Pointer + +func _swig_wrap_new_hi1() (base SwigcptrHi1) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_hi1, _swig_p) + return +} + +func NewHi1() (_swig_ret Hi1) { + return _swig_wrap_new_hi1() +} + +var _wrap_delete_hi1 unsafe.Pointer + +func _swig_wrap_delete_hi1(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_hi1, _swig_p) + return +} + +func DeleteHi1(arg1 Hi1) { + _swig_wrap_delete_hi1(arg1.Swigcptr()) +} + +type Hi1 interface { + Swigcptr() uintptr + SwigIsHi1() + Value1() (_swig_ret int) + Value2() (_swig_ret int) +} + +type SwigcptrX uintptr + +func (p SwigcptrX) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrX) SwigIsX() { +} + +var _wrap_X_d_set unsafe.Pointer + +func _swig_wrap_X_d_set(base SwigcptrX, _ float32) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_X_d_set, _swig_p) + return +} + +func (arg1 SwigcptrX) SetD(arg2 float32) { + _swig_wrap_X_d_set(arg1, arg2) +} + +var _wrap_X_d_get unsafe.Pointer + +func _swig_wrap_X_d_get(base SwigcptrX) (_ float32) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_X_d_get, _swig_p) + return +} + +func (arg1 SwigcptrX) GetD() (_swig_ret float32) { + return _swig_wrap_X_d_get(arg1) +} + +var _wrap_new_X unsafe.Pointer + +func _swig_wrap_new_X() (base SwigcptrX) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_X, _swig_p) + return +} + +func NewX() (_swig_ret X) { + return _swig_wrap_new_X() +} + +var _wrap_delete_X unsafe.Pointer + +func _swig_wrap_delete_X(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_X, _swig_p) + return +} + +func DeleteX(arg1 X) { + _swig_wrap_delete_X(arg1.Swigcptr()) +} + +type X interface { + Swigcptr() uintptr + SwigIsX() + SetD(arg2 float32) + GetD() (_swig_ret float32) +} + +var _wrap_useSpaceMan unsafe.Pointer + +func UseSpaceMan(arg1 float64) (_swig_ret float64) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_useSpaceMan, _swig_p) + return +} + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/using_namespace_loop.go b/Examples/test-suite/go/using_namespace_loop.go new file mode 100644 index 000000000..1a9e5b894 --- /dev/null +++ b/Examples/test-suite/go/using_namespace_loop.go @@ -0,0 +1,29 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../using_namespace_loop.i + +package using_namespace_loop + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + + diff --git a/Examples/test-suite/go/using_pointers.go b/Examples/test-suite/go/using_pointers.go new file mode 100644 index 000000000..af3a15c43 --- /dev/null +++ b/Examples/test-suite/go/using_pointers.go @@ -0,0 +1,226 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../using_pointers.i + +package using_pointers + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrFoo uintptr + +func (p SwigcptrFoo) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrFoo) SwigIsFoo() { +} + +var _wrap_Foo_x_set unsafe.Pointer + +func _swig_wrap_Foo_x_set(base SwigcptrFoo, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_x_set, _swig_p) + return +} + +func (arg1 SwigcptrFoo) SetX(arg2 int) { + _swig_wrap_Foo_x_set(arg1, arg2) +} + +var _wrap_Foo_x_get unsafe.Pointer + +func _swig_wrap_Foo_x_get(base SwigcptrFoo) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_x_get, _swig_p) + return +} + +func (arg1 SwigcptrFoo) GetX() (_swig_ret int) { + return _swig_wrap_Foo_x_get(arg1) +} + +var _wrap_delete_Foo unsafe.Pointer + +func _swig_wrap_delete_Foo(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Foo, _swig_p) + return +} + +func DeleteFoo(arg1 Foo) { + _swig_wrap_delete_Foo(arg1.Swigcptr()) +} + +var _wrap_Foo_blah unsafe.Pointer + +func _swig_wrap_Foo_blah(base SwigcptrFoo) (_ SwigcptrFoo) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_blah, _swig_p) + return +} + +func (arg1 SwigcptrFoo) Blah() (_swig_ret Foo) { + return _swig_wrap_Foo_blah(arg1) +} + +var _wrap_Foo_exception_spec unsafe.Pointer + +func _swig_wrap_Foo_exception_spec(base SwigcptrFoo, _ int) (_ SwigcptrFoo) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_exception_spec, _swig_p) + return +} + +func (arg1 SwigcptrFoo) Exception_spec(arg2 int) (_swig_ret Foo) { + return _swig_wrap_Foo_exception_spec(arg1, arg2) +} + +var _wrap_new_Foo unsafe.Pointer + +func _swig_wrap_new_Foo() (base SwigcptrFoo) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Foo, _swig_p) + return +} + +func NewFoo() (_swig_ret Foo) { + return _swig_wrap_new_Foo() +} + +type Foo interface { + Swigcptr() uintptr + SwigIsFoo() + SetX(arg2 int) + GetX() (_swig_ret int) + Blah() (_swig_ret Foo) + Exception_spec(arg2 int) (_swig_ret Foo) +} + +type SwigcptrFooBar uintptr + +func (p SwigcptrFooBar) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrFooBar) SwigIsFooBar() { +} + +var _wrap_FooBar_blah unsafe.Pointer + +func _swig_wrap_FooBar_blah(base SwigcptrFooBar) (_ SwigcptrFoo) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_FooBar_blah, _swig_p) + return +} + +func (arg1 SwigcptrFooBar) Blah() (_swig_ret Foo) { + return _swig_wrap_FooBar_blah(arg1) +} + +var _wrap_FooBar_x_set unsafe.Pointer + +func _swig_wrap_FooBar_x_set(base SwigcptrFooBar, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_FooBar_x_set, _swig_p) + return +} + +func (arg1 SwigcptrFooBar) SetX(arg2 int) { + _swig_wrap_FooBar_x_set(arg1, arg2) +} + +var _wrap_FooBar_x_get unsafe.Pointer + +func _swig_wrap_FooBar_x_get(base SwigcptrFooBar) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_FooBar_x_get, _swig_p) + return +} + +func (arg1 SwigcptrFooBar) GetX() (_swig_ret int) { + return _swig_wrap_FooBar_x_get(arg1) +} + +var _wrap_FooBar_exception_spec unsafe.Pointer + +func _swig_wrap_FooBar_exception_spec(base SwigcptrFooBar, _ int) (_ SwigcptrFoo) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_FooBar_exception_spec, _swig_p) + return +} + +func (arg1 SwigcptrFooBar) Exception_spec(arg2 int) (_swig_ret Foo) { + return _swig_wrap_FooBar_exception_spec(arg1, arg2) +} + +var _wrap_new_FooBar unsafe.Pointer + +func _swig_wrap_new_FooBar() (base SwigcptrFooBar) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_FooBar, _swig_p) + return +} + +func NewFooBar() (_swig_ret FooBar) { + return _swig_wrap_new_FooBar() +} + +var _wrap_delete_FooBar unsafe.Pointer + +func _swig_wrap_delete_FooBar(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_FooBar, _swig_p) + return +} + +func DeleteFooBar(arg1 FooBar) { + _swig_wrap_delete_FooBar(arg1.Swigcptr()) +} + +func (p SwigcptrFooBar) SwigIsFoo() { +} + +func (p SwigcptrFooBar) SwigGetFoo() Foo { + return SwigcptrFoo(p.Swigcptr()) +} + +type FooBar interface { + Swigcptr() uintptr + SwigIsFooBar() + Blah() (_swig_ret Foo) + SetX(arg2 int) + GetX() (_swig_ret int) + Exception_spec(arg2 int) (_swig_ret Foo) + SwigIsFoo() + SwigGetFoo() Foo +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/using_private.go b/Examples/test-suite/go/using_private.go new file mode 100644 index 000000000..3150b2e81 --- /dev/null +++ b/Examples/test-suite/go/using_private.go @@ -0,0 +1,315 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../using_private.i + +package using_private + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrFoo uintptr + +func (p SwigcptrFoo) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrFoo) SwigIsFoo() { +} + +var _wrap_delete_Foo unsafe.Pointer + +func _swig_wrap_delete_Foo(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Foo, _swig_p) + return +} + +func DeleteFoo(arg1 Foo) { + _swig_wrap_delete_Foo(arg1.Swigcptr()) +} + +var _wrap_Foo_x_set unsafe.Pointer + +func _swig_wrap_Foo_x_set(base SwigcptrFoo, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_x_set, _swig_p) + return +} + +func (arg1 SwigcptrFoo) SetX(arg2 int) { + _swig_wrap_Foo_x_set(arg1, arg2) +} + +var _wrap_Foo_x_get unsafe.Pointer + +func _swig_wrap_Foo_x_get(base SwigcptrFoo) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_x_get, _swig_p) + return +} + +func (arg1 SwigcptrFoo) GetX() (_swig_ret int) { + return _swig_wrap_Foo_x_get(arg1) +} + +var _wrap_Foo_blah unsafe.Pointer + +func _swig_wrap_Foo_blah(base SwigcptrFoo, _ int) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_blah, _swig_p) + return +} + +func (arg1 SwigcptrFoo) Blah(arg2 int) (_swig_ret int) { + return _swig_wrap_Foo_blah(arg1, arg2) +} + +var _wrap_Foo_defaulted__SWIG_0 unsafe.Pointer + +func _swig_wrap_Foo_defaulted__SWIG_0(base SwigcptrFoo, _ int) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_defaulted__SWIG_0, _swig_p) + return +} + +func (arg1 SwigcptrFoo) Defaulted__SWIG_0(arg2 int) (_swig_ret int) { + return _swig_wrap_Foo_defaulted__SWIG_0(arg1, arg2) +} + +var _wrap_Foo_defaulted__SWIG_1 unsafe.Pointer + +func _swig_wrap_Foo_defaulted__SWIG_1(base SwigcptrFoo) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_defaulted__SWIG_1, _swig_p) + return +} + +func (arg1 SwigcptrFoo) Defaulted__SWIG_1() (_swig_ret int) { + return _swig_wrap_Foo_defaulted__SWIG_1(arg1) +} + +func (p SwigcptrFoo) Defaulted(a ...interface{}) int { + argc := len(a) + if argc == 0 { + return p.Defaulted__SWIG_1() + } + if argc == 1 { + return p.Defaulted__SWIG_0(a[0].(int)) + } + panic("No match for overloaded function call") +} + +var _wrap_Foo_virtualmethod unsafe.Pointer + +func _swig_wrap_Foo_virtualmethod(base SwigcptrFoo) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_virtualmethod, _swig_p) + return +} + +func (arg1 SwigcptrFoo) Virtualmethod() { + _swig_wrap_Foo_virtualmethod(arg1) +} + +var _wrap_Foo_anothervirtual unsafe.Pointer + +func _swig_wrap_Foo_anothervirtual(base SwigcptrFoo) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_anothervirtual, _swig_p) + return +} + +func (arg1 SwigcptrFoo) Anothervirtual() { + _swig_wrap_Foo_anothervirtual(arg1) +} + +var _wrap_new_Foo unsafe.Pointer + +func _swig_wrap_new_Foo() (base SwigcptrFoo) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Foo, _swig_p) + return +} + +func NewFoo() (_swig_ret Foo) { + return _swig_wrap_new_Foo() +} + +type Foo interface { + Swigcptr() uintptr + SwigIsFoo() + SetX(arg2 int) + GetX() (_swig_ret int) + Blah(arg2 int) (_swig_ret int) + Defaulted(a ...interface{}) int + Virtualmethod() + Anothervirtual() +} + +type SwigcptrFooBar uintptr + +func (p SwigcptrFooBar) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrFooBar) SwigIsFooBar() { +} + +var _wrap_FooBar_blah unsafe.Pointer + +func _swig_wrap_FooBar_blah(base SwigcptrFooBar, _ int) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_FooBar_blah, _swig_p) + return +} + +func (arg1 SwigcptrFooBar) Blah(arg2 int) (_swig_ret int) { + return _swig_wrap_FooBar_blah(arg1, arg2) +} + +var _wrap_FooBar_x_set unsafe.Pointer + +func _swig_wrap_FooBar_x_set(base SwigcptrFooBar, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_FooBar_x_set, _swig_p) + return +} + +func (arg1 SwigcptrFooBar) SetX(arg2 int) { + _swig_wrap_FooBar_x_set(arg1, arg2) +} + +var _wrap_FooBar_x_get unsafe.Pointer + +func _swig_wrap_FooBar_x_get(base SwigcptrFooBar) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_FooBar_x_get, _swig_p) + return +} + +func (arg1 SwigcptrFooBar) GetX() (_swig_ret int) { + return _swig_wrap_FooBar_x_get(arg1) +} + +var _wrap_FooBar_defaulted_SWIG_0_0 unsafe.Pointer + +func _swig_wrap_FooBar_defaulted_SWIG_0_0(base SwigcptrFooBar, _ int) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_FooBar_defaulted_SWIG_0_0, _swig_p) + return +} + +func (arg1 SwigcptrFooBar) Defaulted_SWIG_0_0(arg2 int) (_swig_ret int) { + return _swig_wrap_FooBar_defaulted_SWIG_0_0(arg1, arg2) +} + +var _wrap_FooBar_defaulted_SWIG_0_1 unsafe.Pointer + +func _swig_wrap_FooBar_defaulted_SWIG_0_1(base SwigcptrFooBar) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_FooBar_defaulted_SWIG_0_1, _swig_p) + return +} + +func (arg1 SwigcptrFooBar) Defaulted_SWIG_0_1() (_swig_ret int) { + return _swig_wrap_FooBar_defaulted_SWIG_0_1(arg1) +} + +func (p SwigcptrFooBar) Defaulted(a ...interface{}) int { + argc := len(a) + if argc == 0 { + return p.Defaulted_SWIG_0_1() + } + if argc == 1 { + return p.Defaulted_SWIG_0_0(a[0].(int)) + } + panic("No match for overloaded function call") +} + +var _wrap_FooBar_virtualmethod unsafe.Pointer + +func _swig_wrap_FooBar_virtualmethod(base SwigcptrFooBar) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_FooBar_virtualmethod, _swig_p) + return +} + +func (arg1 SwigcptrFooBar) Virtualmethod() { + _swig_wrap_FooBar_virtualmethod(arg1) +} + +var _wrap_FooBar_anothervirtual unsafe.Pointer + +func _swig_wrap_FooBar_anothervirtual(base SwigcptrFooBar) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_FooBar_anothervirtual, _swig_p) + return +} + +func (arg1 SwigcptrFooBar) Anothervirtual() { + _swig_wrap_FooBar_anothervirtual(arg1) +} + +var _wrap_delete_FooBar unsafe.Pointer + +func _swig_wrap_delete_FooBar(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_FooBar, _swig_p) + return +} + +func DeleteFooBar(arg1 FooBar) { + _swig_wrap_delete_FooBar(arg1.Swigcptr()) +} + +var _wrap_new_FooBar unsafe.Pointer + +func _swig_wrap_new_FooBar() (base SwigcptrFooBar) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_FooBar, _swig_p) + return +} + +func NewFooBar() (_swig_ret FooBar) { + return _swig_wrap_new_FooBar() +} + +type FooBar interface { + Swigcptr() uintptr + SwigIsFooBar() + Blah(arg2 int) (_swig_ret int) + SetX(arg2 int) + GetX() (_swig_ret int) + Defaulted(a ...interface{}) int + Virtualmethod() + Anothervirtual() +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/using_private_runme b/Examples/test-suite/go/using_private_runme new file mode 100755 index 000000000..cc47122be Binary files /dev/null and b/Examples/test-suite/go/using_private_runme differ diff --git a/Examples/test-suite/go/using_protected.go b/Examples/test-suite/go/using_protected.go new file mode 100644 index 000000000..abe38d4ce --- /dev/null +++ b/Examples/test-suite/go/using_protected.go @@ -0,0 +1,221 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../using_protected.i + +package using_protected + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrFoo uintptr + +func (p SwigcptrFoo) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrFoo) SwigIsFoo() { +} + +var _wrap_new_Foo unsafe.Pointer + +func _swig_wrap_new_Foo() (base SwigcptrFoo) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Foo, _swig_p) + return +} + +func NewFoo() (_swig_ret Foo) { + return _swig_wrap_new_Foo() +} + +var _wrap_delete_Foo unsafe.Pointer + +func _swig_wrap_delete_Foo(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Foo, _swig_p) + return +} + +func DeleteFoo(arg1 Foo) { + _swig_wrap_delete_Foo(arg1.Swigcptr()) +} + +type Foo interface { + Swigcptr() uintptr + SwigIsFoo() +} + +type SwigcptrFooBar uintptr + +func (p SwigcptrFooBar) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrFooBar) SwigIsFooBar() { +} + +var _wrap_FooBar_blah unsafe.Pointer + +func _swig_wrap_FooBar_blah(base SwigcptrFooBar, _ int) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_FooBar_blah, _swig_p) + return +} + +func (arg1 SwigcptrFooBar) Blah(arg2 int) (_swig_ret int) { + return _swig_wrap_FooBar_blah(arg1, arg2) +} + +var _wrap_FooBar_x_set unsafe.Pointer + +func _swig_wrap_FooBar_x_set(base SwigcptrFooBar, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_FooBar_x_set, _swig_p) + return +} + +func (arg1 SwigcptrFooBar) SetX(arg2 int) { + _swig_wrap_FooBar_x_set(arg1, arg2) +} + +var _wrap_FooBar_x_get unsafe.Pointer + +func _swig_wrap_FooBar_x_get(base SwigcptrFooBar) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_FooBar_x_get, _swig_p) + return +} + +func (arg1 SwigcptrFooBar) GetX() (_swig_ret int) { + return _swig_wrap_FooBar_x_get(arg1) +} + +var _wrap_FooBar_vmethod unsafe.Pointer + +func _swig_wrap_FooBar_vmethod(base SwigcptrFooBar, _ int) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_FooBar_vmethod, _swig_p) + return +} + +func (arg1 SwigcptrFooBar) Vmethod(arg2 int) (_swig_ret int) { + return _swig_wrap_FooBar_vmethod(arg1, arg2) +} + +var _wrap_new_FooBar unsafe.Pointer + +func _swig_wrap_new_FooBar() (base SwigcptrFooBar) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_FooBar, _swig_p) + return +} + +func NewFooBar() (_swig_ret FooBar) { + return _swig_wrap_new_FooBar() +} + +var _wrap_delete_FooBar unsafe.Pointer + +func _swig_wrap_delete_FooBar(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_FooBar, _swig_p) + return +} + +func DeleteFooBar(arg1 FooBar) { + _swig_wrap_delete_FooBar(arg1.Swigcptr()) +} + +func (p SwigcptrFooBar) SwigIsFoo() { +} + +func (p SwigcptrFooBar) SwigGetFoo() Foo { + return SwigcptrFoo(p.Swigcptr()) +} + +type FooBar interface { + Swigcptr() uintptr + SwigIsFooBar() + Blah(arg2 int) (_swig_ret int) + SetX(arg2 int) + GetX() (_swig_ret int) + Vmethod(arg2 int) (_swig_ret int) + SwigIsFoo() + SwigGetFoo() Foo +} + +type SwigcptrFooBaz uintptr + +func (p SwigcptrFooBaz) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrFooBaz) SwigIsFooBaz() { +} + +var _wrap_new_FooBaz unsafe.Pointer + +func _swig_wrap_new_FooBaz() (base SwigcptrFooBaz) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_FooBaz, _swig_p) + return +} + +func NewFooBaz() (_swig_ret FooBaz) { + return _swig_wrap_new_FooBaz() +} + +var _wrap_delete_FooBaz unsafe.Pointer + +func _swig_wrap_delete_FooBaz(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_FooBaz, _swig_p) + return +} + +func DeleteFooBaz(arg1 FooBaz) { + _swig_wrap_delete_FooBaz(arg1.Swigcptr()) +} + +func (p SwigcptrFooBaz) SwigIsFoo() { +} + +func (p SwigcptrFooBaz) SwigGetFoo() Foo { + return SwigcptrFoo(p.Swigcptr()) +} + +type FooBaz interface { + Swigcptr() uintptr + SwigIsFooBaz() + SwigIsFoo() + SwigGetFoo() Foo +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/using_protected_runme b/Examples/test-suite/go/using_protected_runme new file mode 100755 index 000000000..40ad401bd Binary files /dev/null and b/Examples/test-suite/go/using_protected_runme differ diff --git a/Examples/test-suite/go/valuewrapper.go b/Examples/test-suite/go/valuewrapper.go new file mode 100644 index 000000000..34a074431 --- /dev/null +++ b/Examples/test-suite/go/valuewrapper.go @@ -0,0 +1,149 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../valuewrapper.i + +package valuewrapper + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrXi uintptr + +func (p SwigcptrXi) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrXi) SwigIsXi() { +} + +var _wrap_new_Xi unsafe.Pointer + +func _swig_wrap_new_Xi(base int) (_ SwigcptrXi) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Xi, _swig_p) + return +} + +func NewXi(arg1 int) (_swig_ret Xi) { + return _swig_wrap_new_Xi(arg1) +} + +var _wrap_delete_Xi unsafe.Pointer + +func _swig_wrap_delete_Xi(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Xi, _swig_p) + return +} + +func DeleteXi(arg1 Xi) { + _swig_wrap_delete_Xi(arg1.Swigcptr()) +} + +type Xi interface { + Swigcptr() uintptr + SwigIsXi() +} + +type SwigcptrYXi uintptr + +func (p SwigcptrYXi) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrYXi) SwigIsYXi() { +} + +var _wrap_new_YXi unsafe.Pointer + +func _swig_wrap_new_YXi() (base SwigcptrYXi) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_YXi, _swig_p) + return +} + +func NewYXi() (_swig_ret YXi) { + return _swig_wrap_new_YXi() +} + +var _wrap_YXi_spam__SWIG_0 unsafe.Pointer + +func _swig_wrap_YXi_spam__SWIG_0(base SwigcptrYXi, _ uintptr) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_YXi_spam__SWIG_0, _swig_p) + return +} + +func (arg1 SwigcptrYXi) Spam__SWIG_0(arg2 Xi) (_swig_ret int) { + return _swig_wrap_YXi_spam__SWIG_0(arg1, arg2.Swigcptr()) +} + +var _wrap_YXi_spam__SWIG_1 unsafe.Pointer + +func _swig_wrap_YXi_spam__SWIG_1(base SwigcptrYXi) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_YXi_spam__SWIG_1, _swig_p) + return +} + +func (arg1 SwigcptrYXi) Spam__SWIG_1() (_swig_ret int) { + return _swig_wrap_YXi_spam__SWIG_1(arg1) +} + +func (p SwigcptrYXi) Spam(a ...interface{}) int { + argc := len(a) + if argc == 0 { + return p.Spam__SWIG_1() + } + if argc == 1 { + return p.Spam__SWIG_0(a[0].(Xi)) + } + panic("No match for overloaded function call") +} + +var _wrap_delete_YXi unsafe.Pointer + +func _swig_wrap_delete_YXi(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_YXi, _swig_p) + return +} + +func DeleteYXi(arg1 YXi) { + _swig_wrap_delete_YXi(arg1.Swigcptr()) +} + +type YXi interface { + Swigcptr() uintptr + SwigIsYXi() + Spam(a ...interface{}) int +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/valuewrapper_base.go b/Examples/test-suite/go/valuewrapper_base.go new file mode 100644 index 000000000..c6022a642 --- /dev/null +++ b/Examples/test-suite/go/valuewrapper_base.go @@ -0,0 +1,151 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../valuewrapper_base.i + +package valuewrapper_base + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type OssPolarization int +var _wrap_UnaryPolarization unsafe.Pointer + +func _swig_getUnaryPolarization() (_swig_ret OssPolarization) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_UnaryPolarization, _swig_p) + return +} +var UnaryPolarization OssPolarization = _swig_getUnaryPolarization() +var _wrap_BinaryPolarization unsafe.Pointer + +func _swig_getBinaryPolarization() (_swig_ret OssPolarization) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_BinaryPolarization, _swig_p) + return +} +var BinaryPolarization OssPolarization = _swig_getBinaryPolarization() +type SwigcptrBase uintptr + +func (p SwigcptrBase) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrBase) SwigIsBase() { +} + +var _wrap_new_Base unsafe.Pointer + +func _swig_wrap_new_Base() (base SwigcptrBase) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Base, _swig_p) + return +} + +func NewBase() (_swig_ret Base) { + return _swig_wrap_new_Base() +} + +var _wrap_delete_Base unsafe.Pointer + +func _swig_wrap_delete_Base(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Base, _swig_p) + return +} + +func DeleteBase(arg1 Base) { + _swig_wrap_delete_Base(arg1.Swigcptr()) +} + +type Base interface { + Swigcptr() uintptr + SwigIsBase() +} + +type SwigcptrInterface_BP uintptr + +func (p SwigcptrInterface_BP) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrInterface_BP) SwigIsInterface_BP() { +} + +var _wrap_new_Interface_BP unsafe.Pointer + +func _swig_wrap_new_Interface_BP(base uintptr) (_ SwigcptrInterface_BP) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Interface_BP, _swig_p) + return +} + +func NewInterface_BP(arg1 Base) (_swig_ret Interface_BP) { + return _swig_wrap_new_Interface_BP(arg1.Swigcptr()) +} + +var _wrap_delete_Interface_BP unsafe.Pointer + +func _swig_wrap_delete_Interface_BP(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Interface_BP, _swig_p) + return +} + +func DeleteInterface_BP(arg1 Interface_BP) { + _swig_wrap_delete_Interface_BP(arg1.Swigcptr()) +} + +func (p SwigcptrInterface_BP) SwigIsBase() { +} + +func (p SwigcptrInterface_BP) SwigGetBase() Base { + return SwigcptrBase(p.Swigcptr()) +} + +type Interface_BP interface { + Swigcptr() uintptr + SwigIsInterface_BP() + SwigIsBase() + SwigGetBase() Base +} + +var _wrap_make_Interface_BP unsafe.Pointer + +func _swig_wrap_make_Interface_BP() (base SwigcptrInterface_BP) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_make_Interface_BP, _swig_p) + return +} + +func Make_Interface_BP() (_swig_ret Interface_BP) { + return _swig_wrap_make_Interface_BP() +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/valuewrapper_const.go b/Examples/test-suite/go/valuewrapper_const.go new file mode 100644 index 000000000..2b9962f12 --- /dev/null +++ b/Examples/test-suite/go/valuewrapper_const.go @@ -0,0 +1,165 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../valuewrapper_const.i + +package valuewrapper_const + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrB uintptr + +func (p SwigcptrB) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrB) SwigIsB() { +} + +var _wrap_new_B unsafe.Pointer + +func _swig_wrap_new_B(base uintptr) (_ SwigcptrB) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_B, _swig_p) + return +} + +func NewB(arg1 B) (_swig_ret B) { + return _swig_wrap_new_B(arg1.Swigcptr()) +} + +var _wrap_delete_B unsafe.Pointer + +func _swig_wrap_delete_B(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_B, _swig_p) + return +} + +func DeleteB(arg1 B) { + _swig_wrap_delete_B(arg1.Swigcptr()) +} + +type B interface { + Swigcptr() uintptr + SwigIsB() +} + +type SwigcptrA uintptr + +func (p SwigcptrA) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrA) SwigIsA() { +} + +var _wrap_new_A unsafe.Pointer + +func _swig_wrap_new_A(base uintptr) (_ SwigcptrA) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_A, _swig_p) + return +} + +func NewA(arg1 B) (_swig_ret A) { + return _swig_wrap_new_A(arg1.Swigcptr()) +} + +var _wrap_A_GetB unsafe.Pointer + +func _swig_wrap_A_GetB(base SwigcptrA) (_ SwigcptrB) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_A_GetB, _swig_p) + return +} + +func (arg1 SwigcptrA) GetB() (_swig_ret B) { + return _swig_wrap_A_GetB(arg1) +} + +var _wrap_A_GetBconst unsafe.Pointer + +func _swig_wrap_A_GetBconst(base SwigcptrA) (_ SwigcptrB) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_A_GetBconst, _swig_p) + return +} + +func (arg1 SwigcptrA) GetBconst() (_swig_ret B) { + return _swig_wrap_A_GetBconst(arg1) +} + +var _wrap_A_GetBGlobalQualifier unsafe.Pointer + +func _swig_wrap_A_GetBGlobalQualifier(base SwigcptrA) (_ SwigcptrB) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_A_GetBGlobalQualifier, _swig_p) + return +} + +func (arg1 SwigcptrA) GetBGlobalQualifier() (_swig_ret B) { + return _swig_wrap_A_GetBGlobalQualifier(arg1) +} + +var _wrap_A_GetBconstGlobalGlobalQualifier unsafe.Pointer + +func _swig_wrap_A_GetBconstGlobalGlobalQualifier(base SwigcptrA) (_ SwigcptrB) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_A_GetBconstGlobalGlobalQualifier, _swig_p) + return +} + +func (arg1 SwigcptrA) GetBconstGlobalGlobalQualifier() (_swig_ret B) { + return _swig_wrap_A_GetBconstGlobalGlobalQualifier(arg1) +} + +var _wrap_delete_A unsafe.Pointer + +func _swig_wrap_delete_A(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_A, _swig_p) + return +} + +func DeleteA(arg1 A) { + _swig_wrap_delete_A(arg1.Swigcptr()) +} + +type A interface { + Swigcptr() uintptr + SwigIsA() + GetB() (_swig_ret B) + GetBconst() (_swig_ret B) + GetBGlobalQualifier() (_swig_ret B) + GetBconstGlobalGlobalQualifier() (_swig_ret B) +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/valuewrapper_opaque.go b/Examples/test-suite/go/valuewrapper_opaque.go new file mode 100644 index 000000000..43375ef7f --- /dev/null +++ b/Examples/test-suite/go/valuewrapper_opaque.go @@ -0,0 +1,481 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../valuewrapper_opaque.i + +package valuewrapper_opaque + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrA uintptr + +func (p SwigcptrA) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrA) SwigIsA() { +} + +var _wrap_new_A unsafe.Pointer + +func _swig_wrap_new_A(base int) (_ SwigcptrA) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_A, _swig_p) + return +} + +func NewA(arg1 int) (_swig_ret A) { + return _swig_wrap_new_A(arg1) +} + +var _wrap_delete_A unsafe.Pointer + +func _swig_wrap_delete_A(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_A, _swig_p) + return +} + +func DeleteA(arg1 A) { + _swig_wrap_delete_A(arg1.Swigcptr()) +} + +type A interface { + Swigcptr() uintptr + SwigIsA() +} + +type SwigcptrD uintptr + +func (p SwigcptrD) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrD) SwigIsD() { +} + +var _wrap_new_D unsafe.Pointer + +func _swig_wrap_new_D() (base SwigcptrD) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_D, _swig_p) + return +} + +func NewD() (_swig_ret D) { + return _swig_wrap_new_D() +} + +var _wrap_delete_D unsafe.Pointer + +func _swig_wrap_delete_D(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_D, _swig_p) + return +} + +func DeleteD(arg1 D) { + _swig_wrap_delete_D(arg1.Swigcptr()) +} + +type D interface { + Swigcptr() uintptr + SwigIsD() +} + +type SwigcptrKlass uintptr + +func (p SwigcptrKlass) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrKlass) SwigIsKlass() { +} + +var _wrap_new_Klass unsafe.Pointer + +func _swig_wrap_new_Klass() (base SwigcptrKlass) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Klass, _swig_p) + return +} + +func NewKlass() (_swig_ret Klass) { + return _swig_wrap_new_Klass() +} + +var _wrap_delete_Klass unsafe.Pointer + +func _swig_wrap_delete_Klass(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Klass, _swig_p) + return +} + +func DeleteKlass(arg1 Klass) { + _swig_wrap_delete_Klass(arg1.Swigcptr()) +} + +type Klass interface { + Swigcptr() uintptr + SwigIsKlass() +} + +var _wrap_getKlass unsafe.Pointer + +func _swig_wrap_getKlass(base uintptr) (_ SwigcptrTemplateClass_Sl_Klass_Sg_) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_getKlass, _swig_p) + return +} + +func GetKlass(arg1 Klass) (_swig_ret TemplateClass_Sl_Klass_Sg_) { + return _swig_wrap_getKlass(arg1.Swigcptr()) +} + +var _wrap_getA__SWIG_0 unsafe.Pointer + +func _swig_wrap_getA__SWIG_0(base uintptr) (_ SwigcptrTemplateClass_Sl_A_Sg_) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_getA__SWIG_0, _swig_p) + return +} + +func GetA__SWIG_0(arg1 A) (_swig_ret TemplateClass_Sl_A_Sg_) { + return _swig_wrap_getA__SWIG_0(arg1.Swigcptr()) +} + +var _wrap_getA__SWIG_1 unsafe.Pointer + +func _swig_wrap_getA__SWIG_1(base uintptr) (_ SwigcptrTemplateClass_Sl_B_Sg_) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_getA__SWIG_1, _swig_p) + return +} + +func GetA__SWIG_1(arg1 B) (_swig_ret TemplateClass_Sl_B_Sg_) { + return _swig_wrap_getA__SWIG_1(arg1.Swigcptr()) +} + +func GetA(a ...interface{}) interface{} { + argc := len(a) + if argc == 1 { + if _, ok := a[0].(A); !ok { + goto check_1 + } + return GetA__SWIG_0(a[0].(A)) + } +check_1: + if argc == 1 { + return GetA__SWIG_1(a[0].(B)) + } + panic("No match for overloaded function call") +} + +var _wrap_getC unsafe.Pointer + +func _swig_wrap_getC(base uintptr) (_ SwigcptrTemplateClass_Sl_C_Sg_) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_getC, _swig_p) + return +} + +func GetC(arg1 C) (_swig_ret TemplateClass_Sl_C_Sg_) { + return _swig_wrap_getC(arg1.Swigcptr()) +} + +var _wrap_getInt unsafe.Pointer + +func _swig_wrap_getInt(base int) (_ SwigcptrTemplateClass_Sl_int_Sg_) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_getInt, _swig_p) + return +} + +func GetInt(arg1 int) (_swig_ret TemplateClass_Sl_int_Sg_) { + return _swig_wrap_getInt(arg1) +} + +var _wrap_sgetA unsafe.Pointer + +func _swig_wrap_sgetA(base uintptr) (_ SwigcptrA) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_sgetA, _swig_p) + return +} + +func SgetA(arg1 A) (_swig_ret A) { + return _swig_wrap_sgetA(arg1.Swigcptr()) +} + +var _wrap_sgetKlass unsafe.Pointer + +func _swig_wrap_sgetKlass(base uintptr) (_ SwigcptrKlass) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_sgetKlass, _swig_p) + return +} + +func SgetKlass(arg1 Klass) (_swig_ret Klass) { + return _swig_wrap_sgetKlass(arg1.Swigcptr()) +} + +var _wrap_getPtrA unsafe.Pointer + +func _swig_wrap_getPtrA(base uintptr) (_ SwigcptrAuto_ptr_Sl_A_Sg_) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_getPtrA, _swig_p) + return +} + +func GetPtrA(arg1 Auto_ptr_Sl_A_Sg_) (_swig_ret Auto_ptr_Sl_A_Sg_) { + return _swig_wrap_getPtrA(arg1.Swigcptr()) +} + +var _wrap_getB unsafe.Pointer + +func _swig_wrap_getB(base uintptr) (_ SwigcptrB) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_getB, _swig_p) + return +} + +func GetB(arg1 B) (_swig_ret B) { + return _swig_wrap_getB(arg1.Swigcptr()) +} + +var _wrap_getD unsafe.Pointer + +func _swig_wrap_getD(base uintptr) (_ SwigcptrD) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_getD, _swig_p) + return +} + +func GetD(arg1 D) (_swig_ret D) { + return _swig_wrap_getD(arg1.Swigcptr()) +} + +type SwigcptrAA uintptr + +func (p SwigcptrAA) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrAA) SwigIsAA() { +} + +var _wrap_new_AA unsafe.Pointer + +func _swig_wrap_new_AA() (base SwigcptrAA) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_AA, _swig_p) + return +} + +func NewAA() (_swig_ret AA) { + return _swig_wrap_new_AA() +} + +var _wrap_AA_innerObj_set unsafe.Pointer + +func _swig_wrap_AA_innerObj_set(base SwigcptrAA, _ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_AA_innerObj_set, _swig_p) + return +} + +func (arg1 SwigcptrAA) SetInnerObj(arg2 BB) { + _swig_wrap_AA_innerObj_set(arg1, arg2.Swigcptr()) +} + +var _wrap_AA_innerObj_get unsafe.Pointer + +func _swig_wrap_AA_innerObj_get(base SwigcptrAA) (_ SwigcptrBB) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_AA_innerObj_get, _swig_p) + return +} + +func (arg1 SwigcptrAA) GetInnerObj() (_swig_ret BB) { + return _swig_wrap_AA_innerObj_get(arg1) +} + +var _wrap_delete_AA unsafe.Pointer + +func _swig_wrap_delete_AA(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_AA, _swig_p) + return +} + +func DeleteAA(arg1 AA) { + _swig_wrap_delete_AA(arg1.Swigcptr()) +} + +type AA interface { + Swigcptr() uintptr + SwigIsAA() + SetInnerObj(arg2 BB) + GetInnerObj() (_swig_ret BB) +} + +type SwigcptrQuux uintptr + +func (p SwigcptrQuux) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrQuux) SwigIsQuux() { +} + +var _wrap_new_Quux unsafe.Pointer + +func _swig_wrap_new_Quux() (base SwigcptrQuux) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Quux, _swig_p) + return +} + +func NewQuux() (_swig_ret Quux) { + return _swig_wrap_new_Quux() +} + +var _wrap_Quux_method unsafe.Pointer + +func _swig_wrap_Quux_method(base SwigcptrQuux) (_ SwigcptrFoobar) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Quux_method, _swig_p) + return +} + +func (arg1 SwigcptrQuux) Method() (_swig_ret Foobar) { + return _swig_wrap_Quux_method(arg1) +} + +var _wrap_delete_Quux unsafe.Pointer + +func _swig_wrap_delete_Quux(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Quux, _swig_p) + return +} + +func DeleteQuux(arg1 Quux) { + _swig_wrap_delete_Quux(arg1.Swigcptr()) +} + +type Quux interface { + Swigcptr() uintptr + SwigIsQuux() + Method() (_swig_ret Foobar) +} + + +type SwigcptrTemplateClass_Sl_A_Sg_ uintptr +type TemplateClass_Sl_A_Sg_ interface { + Swigcptr() uintptr; +} +func (p SwigcptrTemplateClass_Sl_A_Sg_) Swigcptr() uintptr { + return uintptr(p) +} + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + +type SwigcptrBB uintptr +type BB interface { + Swigcptr() uintptr; +} +func (p SwigcptrBB) Swigcptr() uintptr { + return uintptr(p) +} + +type SwigcptrTemplateClass_Sl_B_Sg_ uintptr +type TemplateClass_Sl_B_Sg_ interface { + Swigcptr() uintptr; +} +func (p SwigcptrTemplateClass_Sl_B_Sg_) Swigcptr() uintptr { + return uintptr(p) +} + +type SwigcptrFoobar uintptr +type Foobar interface { + Swigcptr() uintptr; +} +func (p SwigcptrFoobar) Swigcptr() uintptr { + return uintptr(p) +} + +type SwigcptrTemplateClass_Sl_C_Sg_ uintptr +type TemplateClass_Sl_C_Sg_ interface { + Swigcptr() uintptr; +} +func (p SwigcptrTemplateClass_Sl_C_Sg_) Swigcptr() uintptr { + return uintptr(p) +} + +type SwigcptrTemplateClass_Sl_Klass_Sg_ uintptr +type TemplateClass_Sl_Klass_Sg_ interface { + Swigcptr() uintptr; +} +func (p SwigcptrTemplateClass_Sl_Klass_Sg_) Swigcptr() uintptr { + return uintptr(p) +} + +type SwigcptrAuto_ptr_Sl_A_Sg_ uintptr +type Auto_ptr_Sl_A_Sg_ interface { + Swigcptr() uintptr; +} +func (p SwigcptrAuto_ptr_Sl_A_Sg_) Swigcptr() uintptr { + return uintptr(p) +} + +type SwigcptrTemplateClass_Sl_int_Sg_ uintptr +type TemplateClass_Sl_int_Sg_ interface { + Swigcptr() uintptr; +} +func (p SwigcptrTemplateClass_Sl_int_Sg_) Swigcptr() uintptr { + return uintptr(p) +} + +type SwigcptrB uintptr +type B interface { + Swigcptr() uintptr; +} +func (p SwigcptrB) Swigcptr() uintptr { + return uintptr(p) +} + +type SwigcptrC uintptr +type C interface { + Swigcptr() uintptr; +} +func (p SwigcptrC) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/varargs.go b/Examples/test-suite/go/varargs.go new file mode 100644 index 000000000..58335f802 --- /dev/null +++ b/Examples/test-suite/go/varargs.go @@ -0,0 +1,244 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../varargs.i + +package varargs + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +var _wrap_test unsafe.Pointer + +func Test(arg1 string) (_swig_ret string) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_test, _swig_p) + return +} +var _wrap_test_def__SWIG_0 unsafe.Pointer + +func Test_def__SWIG_0(arg1 string, arg2 int) (_swig_ret string) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_test_def__SWIG_0, _swig_p) + return +} +var _wrap_test_def__SWIG_1 unsafe.Pointer + +func Test_def__SWIG_1(arg1 string) (_swig_ret string) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_test_def__SWIG_1, _swig_p) + return +} +func Test_def(a ...interface{}) string { + argc := len(a) + if argc == 1 { + return Test_def__SWIG_1(a[0].(string)) + } + if argc == 2 { + return Test_def__SWIG_0(a[0].(string), a[1].(int)) + } + panic("No match for overloaded function call") +} + +type SwigcptrFoo uintptr + +func (p SwigcptrFoo) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrFoo) SwigIsFoo() { +} + +var _wrap_Foo_str_set unsafe.Pointer + +func _swig_wrap_Foo_str_set(base SwigcptrFoo, _ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_str_set, _swig_p) + return +} + +func (arg1 SwigcptrFoo) SetStr(arg2 string) { + _swig_wrap_Foo_str_set(arg1, arg2) +} + +var _wrap_Foo_str_get unsafe.Pointer + +func _swig_wrap_Foo_str_get(base SwigcptrFoo) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_str_get, _swig_p) + return +} + +func (arg1 SwigcptrFoo) GetStr() (_swig_ret string) { + return _swig_wrap_Foo_str_get(arg1) +} + +var _wrap_new_Foo__SWIG_0 unsafe.Pointer + +func _swig_wrap_new_Foo__SWIG_0() (base SwigcptrFoo) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Foo__SWIG_0, _swig_p) + return +} + +func NewFoo__SWIG_0() (_swig_ret Foo) { + return _swig_wrap_new_Foo__SWIG_0() +} + +var _wrap_new_Foo__SWIG_1 unsafe.Pointer + +func _swig_wrap_new_Foo__SWIG_1(base string, _ int) (_ SwigcptrFoo) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Foo__SWIG_1, _swig_p) + return +} + +func NewFoo__SWIG_1(arg1 string, arg2 int) (_swig_ret Foo) { + return _swig_wrap_new_Foo__SWIG_1(arg1, arg2) +} + +var _wrap_new_Foo__SWIG_2 unsafe.Pointer + +func _swig_wrap_new_Foo__SWIG_2(base string) (_ SwigcptrFoo) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Foo__SWIG_2, _swig_p) + return +} + +func NewFoo__SWIG_2(arg1 string) (_swig_ret Foo) { + return _swig_wrap_new_Foo__SWIG_2(arg1) +} + +func NewFoo(a ...interface{}) Foo { + argc := len(a) + if argc == 0 { + return NewFoo__SWIG_0() + } + if argc == 1 { + return NewFoo__SWIG_2(a[0].(string)) + } + if argc == 2 { + return NewFoo__SWIG_1(a[0].(string), a[1].(int)) + } + panic("No match for overloaded function call") +} + +var _wrap_delete_Foo unsafe.Pointer + +func _swig_wrap_delete_Foo(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Foo, _swig_p) + return +} + +func DeleteFoo(arg1 Foo) { + _swig_wrap_delete_Foo(arg1.Swigcptr()) +} + +var _wrap_Foo_test unsafe.Pointer + +func _swig_wrap_Foo_test(base SwigcptrFoo, _ string) (_ string) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_test, _swig_p) + return +} + +func (arg1 SwigcptrFoo) Test(arg2 string) (_swig_ret string) { + return _swig_wrap_Foo_test(arg1, arg2) +} + +var _wrap_Foo_statictest__SWIG_0 unsafe.Pointer + +func FooStatictest__SWIG_0(arg1 string, arg2 int) (_swig_ret string) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_Foo_statictest__SWIG_0, _swig_p) + return +} +var _wrap_Foo_statictest__SWIG_1 unsafe.Pointer + +func FooStatictest__SWIG_1(arg1 string) (_swig_ret string) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_Foo_statictest__SWIG_1, _swig_p) + return +} +func FooStatictest(a ...interface{}) string { + argc := len(a) + if argc == 1 { + return FooStatictest__SWIG_1(a[0].(string)) + } + if argc == 2 { + return FooStatictest__SWIG_0(a[0].(string), a[1].(int)) + } + panic("No match for overloaded function call") +} + +type Foo interface { + Swigcptr() uintptr + SwigIsFoo() + SetStr(arg2 string) + GetStr() (_swig_ret string) + Test(arg2 string) (_swig_ret string) +} + +var _wrap_test_plenty__SWIG_0 unsafe.Pointer + +func Test_plenty__SWIG_0(arg1 string, arg2 int, arg3 int) (_swig_ret string) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_test_plenty__SWIG_0, _swig_p) + return +} +var _wrap_test_plenty__SWIG_1 unsafe.Pointer + +func Test_plenty__SWIG_1(arg1 string, arg2 int) (_swig_ret string) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_test_plenty__SWIG_1, _swig_p) + return +} +var _wrap_test_plenty__SWIG_2 unsafe.Pointer + +func Test_plenty__SWIG_2(arg1 string) (_swig_ret string) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_test_plenty__SWIG_2, _swig_p) + return +} +func Test_plenty(a ...interface{}) string { + argc := len(a) + if argc == 1 { + return Test_plenty__SWIG_2(a[0].(string)) + } + if argc == 2 { + return Test_plenty__SWIG_1(a[0].(string), a[1].(int)) + } + if argc == 3 { + return Test_plenty__SWIG_0(a[0].(string), a[1].(int), a[2].(int)) + } + panic("No match for overloaded function call") +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/varargs_overload.go b/Examples/test-suite/go/varargs_overload.go new file mode 100644 index 000000000..92f294fbe --- /dev/null +++ b/Examples/test-suite/go/varargs_overload.go @@ -0,0 +1,165 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../varargs_overload.i + +package varargs_overload + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +var _wrap_vararg_over1__SWIG_0 unsafe.Pointer + +func Vararg_over1__SWIG_0(arg1 string) (_swig_ret string) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_vararg_over1__SWIG_0, _swig_p) + return +} +var _wrap_vararg_over1__SWIG_1 unsafe.Pointer + +func Vararg_over1__SWIG_1(arg1 int) (_swig_ret string) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_vararg_over1__SWIG_1, _swig_p) + return +} +func Vararg_over1(a ...interface{}) string { + argc := len(a) + if argc == 1 { + if _, ok := a[0].(int); !ok { + goto check_1 + } + return Vararg_over1__SWIG_1(a[0].(int)) + } +check_1: + if argc >= 1 { + return Vararg_over1__SWIG_0(a[0].(string)) + } + panic("No match for overloaded function call") +} + +var _wrap_vararg_over2__SWIG_0 unsafe.Pointer + +func Vararg_over2__SWIG_0(arg1 string) (_swig_ret string) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_vararg_over2__SWIG_0, _swig_p) + return +} +var _wrap_vararg_over2__SWIG_1 unsafe.Pointer + +func Vararg_over2__SWIG_1(arg1 int, arg2 float64) (_swig_ret string) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_vararg_over2__SWIG_1, _swig_p) + return +} +func Vararg_over2(a ...interface{}) string { + argc := len(a) + if argc >= 1 { + if _, ok := a[0].(string); !ok { + goto check_1 + } + if argc > 1 { + if _, ok := a[1].([]interface{}); !ok { + goto check_1 + } + } + return Vararg_over2__SWIG_0(a[0].(string)) + } +check_1: + if argc == 2 { + return Vararg_over2__SWIG_1(a[0].(int), a[1].(float64)) + } + panic("No match for overloaded function call") +} + +var _wrap_vararg_over3__SWIG_0 unsafe.Pointer + +func Vararg_over3__SWIG_0(arg1 string) (_swig_ret string) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_vararg_over3__SWIG_0, _swig_p) + return +} +var _wrap_vararg_over3__SWIG_1 unsafe.Pointer + +func Vararg_over3__SWIG_1(arg1 int, arg2 float64, arg3 string) (_swig_ret string) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_vararg_over3__SWIG_1, _swig_p) + return +} +func Vararg_over3(a ...interface{}) string { + argc := len(a) + if argc >= 1 { + if _, ok := a[0].(string); !ok { + goto check_1 + } + if argc > 1 { + if _, ok := a[1].([]interface{}); !ok { + goto check_1 + } + } + return Vararg_over3__SWIG_0(a[0].(string)) + } +check_1: + if argc == 3 { + return Vararg_over3__SWIG_1(a[0].(int), a[1].(float64), a[2].(string)) + } + panic("No match for overloaded function call") +} + +var _wrap_vararg_over4__SWIG_0 unsafe.Pointer + +func Vararg_over4__SWIG_0(arg1 string, arg2 int) (_swig_ret string) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_vararg_over4__SWIG_0, _swig_p) + return +} +var _wrap_vararg_over4__SWIG_1 unsafe.Pointer + +func Vararg_over4__SWIG_1(arg1 string) (_swig_ret string) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_vararg_over4__SWIG_1, _swig_p) + return +} +var _wrap_vararg_over4__SWIG_2 unsafe.Pointer + +func Vararg_over4__SWIG_2(arg1 int) (_swig_ret string) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_vararg_over4__SWIG_2, _swig_p) + return +} +func Vararg_over4(a ...interface{}) string { + argc := len(a) + if argc == 1 { + if _, ok := a[0].(int); !ok { + goto check_1 + } + return Vararg_over4__SWIG_2(a[0].(int)) + } +check_1: + if argc == 1 { + return Vararg_over4__SWIG_1(a[0].(string)) + } + if argc == 2 { + return Vararg_over4__SWIG_0(a[0].(string), a[1].(int)) + } + panic("No match for overloaded function call") +} + + diff --git a/Examples/test-suite/go/varargs_overload_runme b/Examples/test-suite/go/varargs_overload_runme new file mode 100755 index 000000000..69a5570d6 Binary files /dev/null and b/Examples/test-suite/go/varargs_overload_runme differ diff --git a/Examples/test-suite/go/varargs_runme b/Examples/test-suite/go/varargs_runme new file mode 100755 index 000000000..971aa81ad Binary files /dev/null and b/Examples/test-suite/go/varargs_runme differ diff --git a/Examples/test-suite/go/virtual_destructor.go b/Examples/test-suite/go/virtual_destructor.go new file mode 100644 index 000000000..fac7c0c52 --- /dev/null +++ b/Examples/test-suite/go/virtual_destructor.go @@ -0,0 +1,110 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../virtual_destructor.i + +package virtual_destructor + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrVirtualVoidDestructor uintptr + +func (p SwigcptrVirtualVoidDestructor) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrVirtualVoidDestructor) SwigIsVirtualVoidDestructor() { +} + +var _wrap_new_VirtualVoidDestructor unsafe.Pointer + +func _swig_wrap_new_VirtualVoidDestructor() (base SwigcptrVirtualVoidDestructor) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_VirtualVoidDestructor, _swig_p) + return +} + +func NewVirtualVoidDestructor() (_swig_ret VirtualVoidDestructor) { + return _swig_wrap_new_VirtualVoidDestructor() +} + +var _wrap_delete_VirtualVoidDestructor unsafe.Pointer + +func _swig_wrap_delete_VirtualVoidDestructor(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_VirtualVoidDestructor, _swig_p) + return +} + +func DeleteVirtualVoidDestructor(arg1 VirtualVoidDestructor) { + _swig_wrap_delete_VirtualVoidDestructor(arg1.Swigcptr()) +} + +type VirtualVoidDestructor interface { + Swigcptr() uintptr + SwigIsVirtualVoidDestructor() +} + +type SwigcptrDerived uintptr + +func (p SwigcptrDerived) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrDerived) SwigIsDerived() { +} + +var _wrap_new_Derived unsafe.Pointer + +func _swig_wrap_new_Derived() (base SwigcptrDerived) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Derived, _swig_p) + return +} + +func NewDerived() (_swig_ret Derived) { + return _swig_wrap_new_Derived() +} + +func (p SwigcptrDerived) SwigIsVirtualVoidDestructor() { +} + +func (p SwigcptrDerived) SwigGetVirtualVoidDestructor() VirtualVoidDestructor { + return SwigcptrVirtualVoidDestructor(p.Swigcptr()) +} + +type Derived interface { + Swigcptr() uintptr + SwigIsDerived() + SwigIsVirtualVoidDestructor() + SwigGetVirtualVoidDestructor() VirtualVoidDestructor +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/virtual_poly.go b/Examples/test-suite/go/virtual_poly.go new file mode 100644 index 000000000..f90e59be4 --- /dev/null +++ b/Examples/test-suite/go/virtual_poly.go @@ -0,0 +1,1317 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../virtual_poly.i + +package virtual_poly + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrNNumber uintptr + +func (p SwigcptrNNumber) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrNNumber) SwigIsNNumber() { +} + +var _wrap_delete_NNumber unsafe.Pointer + +func _swig_wrap_delete_NNumber(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_NNumber, _swig_p) + return +} + +func DeleteNNumber(arg1 NNumber) { + _swig_wrap_delete_NNumber(arg1.Swigcptr()) +} + +var _wrap_NNumber_copy unsafe.Pointer + +func _swig_wrap_NNumber_copy(base SwigcptrNNumber) (_ SwigcptrNNumber) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_NNumber_copy, _swig_p) + return +} + +func (arg1 SwigcptrNNumber) Copy() (_swig_ret NNumber) { + return _swig_wrap_NNumber_copy(arg1) +} + +var _wrap_NNumber_ref_this unsafe.Pointer + +func _swig_wrap_NNumber_ref_this(base SwigcptrNNumber) (_ SwigcptrNNumber) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_NNumber_ref_this, _swig_p) + return +} + +func (arg1 SwigcptrNNumber) Ref_this() (_swig_ret NNumber) { + return _swig_wrap_NNumber_ref_this(arg1) +} + +var _wrap_NNumber_nnumber unsafe.Pointer + +func _swig_wrap_NNumber_nnumber(base SwigcptrNNumber) (_ SwigcptrNNumber) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_NNumber_nnumber, _swig_p) + return +} + +func (arg1 SwigcptrNNumber) Nnumber() (_swig_ret NNumber) { + return _swig_wrap_NNumber_nnumber(arg1) +} + +type NNumber interface { + Swigcptr() uintptr + SwigIsNNumber() + Copy() (_swig_ret NNumber) + Ref_this() (_swig_ret NNumber) + Nnumber() (_swig_ret NNumber) +} + +type SwigcptrNInt uintptr + +func (p SwigcptrNInt) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrNInt) SwigIsNInt() { +} + +var _wrap_new_NInt unsafe.Pointer + +func _swig_wrap_new_NInt(base int) (_ SwigcptrNInt) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_NInt, _swig_p) + return +} + +func NewNInt(arg1 int) (_swig_ret NInt) { + return _swig_wrap_new_NInt(arg1) +} + +var _wrap_NInt_get unsafe.Pointer + +func _swig_wrap_NInt_get(base SwigcptrNInt) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_NInt_get, _swig_p) + return +} + +func (arg1 SwigcptrNInt) Get() (_swig_ret int) { + return _swig_wrap_NInt_get(arg1) +} + +var _wrap_NInt_copy unsafe.Pointer + +func _swig_wrap_NInt_copy(base SwigcptrNInt) (_ SwigcptrNInt) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_NInt_copy, _swig_p) + return +} + +func (arg1 SwigcptrNInt) Copy() (_swig_ret NInt) { + return _swig_wrap_NInt_copy(arg1) +} + +var _wrap_NInt_ref_this unsafe.Pointer + +func _swig_wrap_NInt_ref_this(base SwigcptrNInt) (_ SwigcptrNInt) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_NInt_ref_this, _swig_p) + return +} + +func (arg1 SwigcptrNInt) Ref_this() (_swig_ret NInt) { + return _swig_wrap_NInt_ref_this(arg1) +} + +var _wrap_NInt_narrow unsafe.Pointer + +func _swig_wrap_NInt_narrow(base uintptr) (_ SwigcptrNInt) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_NInt_narrow, _swig_p) + return +} + +func NIntNarrow(arg1 NNumber) (_swig_ret NInt) { + return _swig_wrap_NInt_narrow(arg1.Swigcptr()) +} + +var _wrap_delete_NInt unsafe.Pointer + +func _swig_wrap_delete_NInt(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_NInt, _swig_p) + return +} + +func DeleteNInt(arg1 NInt) { + _swig_wrap_delete_NInt(arg1.Swigcptr()) +} + +var _wrap_NInt_nnumber unsafe.Pointer + +func _swig_wrap_NInt_nnumber(base SwigcptrNInt) (_ SwigcptrNNumber) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_NInt_nnumber, _swig_p) + return +} + +func (_swig_base SwigcptrNInt) Nnumber() (_swig_ret NNumber) { + return _swig_wrap_NInt_nnumber(_swig_base) +} + +func (p SwigcptrNInt) SwigIsNNumber() { +} + +func (p SwigcptrNInt) SwigGetNNumber() NNumber { + return SwigcptrNNumber(p.Swigcptr()) +} + +type NInt interface { + Swigcptr() uintptr + SwigIsNInt() + Get() (_swig_ret int) + Copy() (_swig_ret NInt) + Ref_this() (_swig_ret NInt) + Nnumber() (_swig_ret NNumber) + SwigIsNNumber() + SwigGetNNumber() NNumber +} + +var _wrap_incr unsafe.Pointer + +func _swig_wrap_incr(base uintptr) (_ SwigcptrNInt) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_incr, _swig_p) + return +} + +func Incr(arg1 NInt) (_swig_ret NInt) { + return _swig_wrap_incr(arg1.Swigcptr()) +} + +type SwigcptrNDouble uintptr + +func (p SwigcptrNDouble) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrNDouble) SwigIsNDouble() { +} + +var _wrap_new_NDouble unsafe.Pointer + +func _swig_wrap_new_NDouble(base float64) (_ SwigcptrNDouble) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_NDouble, _swig_p) + return +} + +func NewNDouble(arg1 float64) (_swig_ret NDouble) { + return _swig_wrap_new_NDouble(arg1) +} + +var _wrap_NDouble_get unsafe.Pointer + +func _swig_wrap_NDouble_get(base SwigcptrNDouble) (_ float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_NDouble_get, _swig_p) + return +} + +func (arg1 SwigcptrNDouble) Get() (_swig_ret float64) { + return _swig_wrap_NDouble_get(arg1) +} + +var _wrap_NDouble_copy unsafe.Pointer + +func _swig_wrap_NDouble_copy(base SwigcptrNDouble) (_ SwigcptrNDouble) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_NDouble_copy, _swig_p) + return +} + +func (arg1 SwigcptrNDouble) Copy() (_swig_ret NDouble) { + return _swig_wrap_NDouble_copy(arg1) +} + +var _wrap_NDouble_ref_this unsafe.Pointer + +func _swig_wrap_NDouble_ref_this(base SwigcptrNDouble) (_ SwigcptrNDouble) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_NDouble_ref_this, _swig_p) + return +} + +func (arg1 SwigcptrNDouble) Ref_this() (_swig_ret NDouble) { + return _swig_wrap_NDouble_ref_this(arg1) +} + +var _wrap_NDouble_narrow unsafe.Pointer + +func _swig_wrap_NDouble_narrow(base uintptr) (_ SwigcptrNDouble) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_NDouble_narrow, _swig_p) + return +} + +func NDoubleNarrow(arg1 NNumber) (_swig_ret NDouble) { + return _swig_wrap_NDouble_narrow(arg1.Swigcptr()) +} + +var _wrap_delete_NDouble unsafe.Pointer + +func _swig_wrap_delete_NDouble(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_NDouble, _swig_p) + return +} + +func DeleteNDouble(arg1 NDouble) { + _swig_wrap_delete_NDouble(arg1.Swigcptr()) +} + +var _wrap_NDouble_nnumber unsafe.Pointer + +func _swig_wrap_NDouble_nnumber(base SwigcptrNDouble) (_ SwigcptrNNumber) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_NDouble_nnumber, _swig_p) + return +} + +func (_swig_base SwigcptrNDouble) Nnumber() (_swig_ret NNumber) { + return _swig_wrap_NDouble_nnumber(_swig_base) +} + +func (p SwigcptrNDouble) SwigIsNNumber() { +} + +func (p SwigcptrNDouble) SwigGetNNumber() NNumber { + return SwigcptrNNumber(p.Swigcptr()) +} + +type NDouble interface { + Swigcptr() uintptr + SwigIsNDouble() + Get() (_swig_ret float64) + Copy() (_swig_ret NDouble) + Ref_this() (_swig_ret NDouble) + Nnumber() (_swig_ret NNumber) + SwigIsNNumber() + SwigGetNNumber() NNumber +} + +type SwigcptrBaseInt uintptr + +func (p SwigcptrBaseInt) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrBaseInt) SwigIsBaseInt() { +} + +var _wrap_BaseInt_t_set unsafe.Pointer + +func _swig_wrap_BaseInt_t_set(base SwigcptrBaseInt, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_BaseInt_t_set, _swig_p) + return +} + +func (arg1 SwigcptrBaseInt) SetT(arg2 int) { + _swig_wrap_BaseInt_t_set(arg1, arg2) +} + +var _wrap_BaseInt_t_get unsafe.Pointer + +func _swig_wrap_BaseInt_t_get(base SwigcptrBaseInt) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_BaseInt_t_get, _swig_p) + return +} + +func (arg1 SwigcptrBaseInt) GetT() (_swig_ret int) { + return _swig_wrap_BaseInt_t_get(arg1) +} + +var _wrap_BaseInt_method unsafe.Pointer + +func _swig_wrap_BaseInt_method(base SwigcptrBaseInt) (_ *int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_BaseInt_method, _swig_p) + return +} + +func (arg1 SwigcptrBaseInt) Method() (_swig_ret *int) { + return _swig_wrap_BaseInt_method(arg1) +} + +var _wrap_BaseInt_foxy__SWIG_0 unsafe.Pointer + +func _swig_wrap_BaseInt_foxy__SWIG_0(base SwigcptrBaseInt) (_ *int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_BaseInt_foxy__SWIG_0, _swig_p) + return +} + +func (arg1 SwigcptrBaseInt) Foxy__SWIG_0() (_swig_ret *int) { + return _swig_wrap_BaseInt_foxy__SWIG_0(arg1) +} + +var _wrap_BaseInt_foxy__SWIG_1 unsafe.Pointer + +func _swig_wrap_BaseInt_foxy__SWIG_1(base SwigcptrBaseInt, _ int) (_ *int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_BaseInt_foxy__SWIG_1, _swig_p) + return +} + +func (arg1 SwigcptrBaseInt) Foxy__SWIG_1(arg2 int) (_swig_ret *int) { + return _swig_wrap_BaseInt_foxy__SWIG_1(arg1, arg2) +} + +var _wrap_BaseInt_foxy__SWIG_2 unsafe.Pointer + +func _swig_wrap_BaseInt_foxy__SWIG_2(base SwigcptrBaseInt, _ **int) (_ *int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_BaseInt_foxy__SWIG_2, _swig_p) + return +} + +func (arg1 SwigcptrBaseInt) Foxy__SWIG_2(arg2 **int) (_swig_ret *int) { + return _swig_wrap_BaseInt_foxy__SWIG_2(arg1, arg2) +} + +func (p SwigcptrBaseInt) Foxy(a ...interface{}) interface{} { + argc := len(a) + if argc == 0 { + return p.Foxy__SWIG_0() + } + if argc == 1 { + if _, ok := a[0].(**int); !ok { + goto check_2 + } + return p.Foxy__SWIG_2(a[0].(**int)) + } +check_2: + if argc == 1 { + return p.Foxy__SWIG_1(a[0].(int)) + } + panic("No match for overloaded function call") +} + +var _wrap_BaseInt_afunction unsafe.Pointer + +func _swig_wrap_BaseInt_afunction(base SwigcptrBaseInt) (_ float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_BaseInt_afunction, _swig_p) + return +} + +func (arg1 SwigcptrBaseInt) Afunction() (_swig_ret float64) { + return _swig_wrap_BaseInt_afunction(arg1) +} + +var _wrap_BaseInt_defaultargs__SWIG_0 unsafe.Pointer + +func _swig_wrap_BaseInt_defaultargs__SWIG_0(base SwigcptrBaseInt, _ float64, _ *int) (_ *int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_BaseInt_defaultargs__SWIG_0, _swig_p) + return +} + +func (arg1 SwigcptrBaseInt) Defaultargs__SWIG_0(arg2 float64, arg3 *int) (_swig_ret *int) { + return _swig_wrap_BaseInt_defaultargs__SWIG_0(arg1, arg2, arg3) +} + +var _wrap_BaseInt_defaultargs__SWIG_1 unsafe.Pointer + +func _swig_wrap_BaseInt_defaultargs__SWIG_1(base SwigcptrBaseInt, _ float64) (_ *int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_BaseInt_defaultargs__SWIG_1, _swig_p) + return +} + +func (arg1 SwigcptrBaseInt) Defaultargs__SWIG_1(arg2 float64) (_swig_ret *int) { + return _swig_wrap_BaseInt_defaultargs__SWIG_1(arg1, arg2) +} + +func (p SwigcptrBaseInt) Defaultargs(a ...interface{}) *int { + argc := len(a) + if argc == 1 { + return p.Defaultargs__SWIG_1(a[0].(float64)) + } + if argc == 2 { + return p.Defaultargs__SWIG_0(a[0].(float64), a[1].(*int)) + } + panic("No match for overloaded function call") +} + +var _wrap_BaseInt_StaticHidden unsafe.Pointer + +func _swig_wrap_BaseInt_StaticHidden() { + var _swig_p uintptr + _cgo_runtime_cgocall(_wrap_BaseInt_StaticHidden, _swig_p) + return +} + +func BaseIntStaticHidden() { + _swig_wrap_BaseInt_StaticHidden() +} + +var _wrap_BaseInt_AmIAmINotVirtual unsafe.Pointer + +func _swig_wrap_BaseInt_AmIAmINotVirtual(base SwigcptrBaseInt) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_BaseInt_AmIAmINotVirtual, _swig_p) + return +} + +func (arg1 SwigcptrBaseInt) AmIAmINotVirtual() { + _swig_wrap_BaseInt_AmIAmINotVirtual(arg1) +} + +var _wrap_BaseInt_NotVirtual unsafe.Pointer + +func _swig_wrap_BaseInt_NotVirtual(base SwigcptrBaseInt, _ *int) (_ *int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_BaseInt_NotVirtual, _swig_p) + return +} + +func (arg1 SwigcptrBaseInt) NotVirtual(arg2 *int) (_swig_ret *int) { + return _swig_wrap_BaseInt_NotVirtual(arg1, arg2) +} + +var _wrap_BaseInt_covariant__SWIG_0 unsafe.Pointer + +func _swig_wrap_BaseInt_covariant__SWIG_0(base SwigcptrBaseInt, _ int, _ *int) (_ SwigcptrBaseInt) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_BaseInt_covariant__SWIG_0, _swig_p) + return +} + +func (arg1 SwigcptrBaseInt) Covariant__SWIG_0(arg2 int, arg3 *int) (_swig_ret BaseInt) { + return _swig_wrap_BaseInt_covariant__SWIG_0(arg1, arg2, arg3) +} + +var _wrap_BaseInt_covariant__SWIG_1 unsafe.Pointer + +func _swig_wrap_BaseInt_covariant__SWIG_1(base SwigcptrBaseInt, _ int) (_ SwigcptrBaseInt) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_BaseInt_covariant__SWIG_1, _swig_p) + return +} + +func (arg1 SwigcptrBaseInt) Covariant__SWIG_1(arg2 int) (_swig_ret BaseInt) { + return _swig_wrap_BaseInt_covariant__SWIG_1(arg1, arg2) +} + +var _wrap_BaseInt_covariant__SWIG_2 unsafe.Pointer + +func _swig_wrap_BaseInt_covariant__SWIG_2(base SwigcptrBaseInt) (_ SwigcptrBaseInt) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_BaseInt_covariant__SWIG_2, _swig_p) + return +} + +func (arg1 SwigcptrBaseInt) Covariant__SWIG_2() (_swig_ret BaseInt) { + return _swig_wrap_BaseInt_covariant__SWIG_2(arg1) +} + +func (p SwigcptrBaseInt) Covariant(a ...interface{}) BaseInt { + argc := len(a) + if argc == 0 { + return p.Covariant__SWIG_2() + } + if argc == 1 { + return p.Covariant__SWIG_1(a[0].(int)) + } + if argc == 2 { + return p.Covariant__SWIG_0(a[0].(int), a[1].(*int)) + } + panic("No match for overloaded function call") +} + +var _wrap_BaseInt_covariant2 unsafe.Pointer + +func _swig_wrap_BaseInt_covariant2(base SwigcptrBaseInt) (_ SwigcptrBaseInt) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_BaseInt_covariant2, _swig_p) + return +} + +func (arg1 SwigcptrBaseInt) Covariant2() (_swig_ret BaseInt) { + return _swig_wrap_BaseInt_covariant2(arg1) +} + +var _wrap_BaseInt_covariant3 unsafe.Pointer + +func _swig_wrap_BaseInt_covariant3(base SwigcptrBaseInt) (_ SwigcptrBaseInt) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_BaseInt_covariant3, _swig_p) + return +} + +func (arg1 SwigcptrBaseInt) Covariant3() (_swig_ret BaseInt) { + return _swig_wrap_BaseInt_covariant3(arg1) +} + +var _wrap_delete_BaseInt unsafe.Pointer + +func _swig_wrap_delete_BaseInt(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_BaseInt, _swig_p) + return +} + +func DeleteBaseInt(arg1 BaseInt) { + _swig_wrap_delete_BaseInt(arg1.Swigcptr()) +} + +type BaseInt interface { + Swigcptr() uintptr + SwigIsBaseInt() + SetT(arg2 int) + GetT() (_swig_ret int) + Method() (_swig_ret *int) + Foxy(a ...interface{}) interface{} + Afunction() (_swig_ret float64) + Defaultargs(a ...interface{}) *int + AmIAmINotVirtual() + NotVirtual(arg2 *int) (_swig_ret *int) + Covariant(a ...interface{}) BaseInt + Covariant2() (_swig_ret BaseInt) + Covariant3() (_swig_ret BaseInt) +} + +type SwigcptrDerivedInt uintptr + +func (p SwigcptrDerivedInt) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrDerivedInt) SwigIsDerivedInt() { +} + +var _wrap_DerivedInt_method unsafe.Pointer + +func _swig_wrap_DerivedInt_method(base SwigcptrDerivedInt) (_ *int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_DerivedInt_method, _swig_p) + return +} + +func (arg1 SwigcptrDerivedInt) Method() (_swig_ret *int) { + return _swig_wrap_DerivedInt_method(arg1) +} + +var _wrap_DerivedInt_foxy__SWIG_0 unsafe.Pointer + +func _swig_wrap_DerivedInt_foxy__SWIG_0(base SwigcptrDerivedInt) (_ *int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_DerivedInt_foxy__SWIG_0, _swig_p) + return +} + +func (arg1 SwigcptrDerivedInt) Foxy__SWIG_0() (_swig_ret *int) { + return _swig_wrap_DerivedInt_foxy__SWIG_0(arg1) +} + +var _wrap_DerivedInt_foxy__SWIG_1 unsafe.Pointer + +func _swig_wrap_DerivedInt_foxy__SWIG_1(base SwigcptrDerivedInt, _ int) (_ *int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_DerivedInt_foxy__SWIG_1, _swig_p) + return +} + +func (arg1 SwigcptrDerivedInt) Foxy__SWIG_1(arg2 int) (_swig_ret *int) { + return _swig_wrap_DerivedInt_foxy__SWIG_1(arg1, arg2) +} + +var _wrap_DerivedInt_foxy__SWIG_2 unsafe.Pointer + +func _swig_wrap_DerivedInt_foxy__SWIG_2(base SwigcptrDerivedInt, _ **int) (_ *int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_DerivedInt_foxy__SWIG_2, _swig_p) + return +} + +func (arg1 SwigcptrDerivedInt) Foxy__SWIG_2(arg2 **int) (_swig_ret *int) { + return _swig_wrap_DerivedInt_foxy__SWIG_2(arg1, arg2) +} + +func (p SwigcptrDerivedInt) Foxy(a ...interface{}) interface{} { + argc := len(a) + if argc == 0 { + return p.Foxy__SWIG_0() + } + if argc == 1 { + if _, ok := a[0].(**int); !ok { + goto check_2 + } + return p.Foxy__SWIG_2(a[0].(**int)) + } +check_2: + if argc == 1 { + return p.Foxy__SWIG_1(a[0].(int)) + } + panic("No match for overloaded function call") +} + +var _wrap_DerivedInt_afunction unsafe.Pointer + +func _swig_wrap_DerivedInt_afunction(base SwigcptrDerivedInt) (_ float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_DerivedInt_afunction, _swig_p) + return +} + +func (arg1 SwigcptrDerivedInt) Afunction() (_swig_ret float64) { + return _swig_wrap_DerivedInt_afunction(arg1) +} + +var _wrap_DerivedInt_defaultargs__SWIG_0 unsafe.Pointer + +func _swig_wrap_DerivedInt_defaultargs__SWIG_0(base SwigcptrDerivedInt, _ float64, _ *int) (_ *int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_DerivedInt_defaultargs__SWIG_0, _swig_p) + return +} + +func (arg1 SwigcptrDerivedInt) Defaultargs__SWIG_0(arg2 float64, arg3 *int) (_swig_ret *int) { + return _swig_wrap_DerivedInt_defaultargs__SWIG_0(arg1, arg2, arg3) +} + +var _wrap_DerivedInt_defaultargs__SWIG_1 unsafe.Pointer + +func _swig_wrap_DerivedInt_defaultargs__SWIG_1(base SwigcptrDerivedInt, _ float64) (_ *int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_DerivedInt_defaultargs__SWIG_1, _swig_p) + return +} + +func (arg1 SwigcptrDerivedInt) Defaultargs__SWIG_1(arg2 float64) (_swig_ret *int) { + return _swig_wrap_DerivedInt_defaultargs__SWIG_1(arg1, arg2) +} + +func (p SwigcptrDerivedInt) Defaultargs(a ...interface{}) *int { + argc := len(a) + if argc == 1 { + return p.Defaultargs__SWIG_1(a[0].(float64)) + } + if argc == 2 { + return p.Defaultargs__SWIG_0(a[0].(float64), a[1].(*int)) + } + panic("No match for overloaded function call") +} + +var _wrap_DerivedInt_AmIAmINotVirtual unsafe.Pointer + +func _swig_wrap_DerivedInt_AmIAmINotVirtual(base SwigcptrDerivedInt) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_DerivedInt_AmIAmINotVirtual, _swig_p) + return +} + +func (arg1 SwigcptrDerivedInt) AmIAmINotVirtual() { + _swig_wrap_DerivedInt_AmIAmINotVirtual(arg1) +} + +var _wrap_DerivedInt_NotVirtual unsafe.Pointer + +func _swig_wrap_DerivedInt_NotVirtual(base SwigcptrDerivedInt, _ *int) (_ *int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_DerivedInt_NotVirtual, _swig_p) + return +} + +func (arg1 SwigcptrDerivedInt) NotVirtual(arg2 *int) (_swig_ret *int) { + return _swig_wrap_DerivedInt_NotVirtual(arg1, arg2) +} + +var _wrap_DerivedInt_covariant__SWIG_0 unsafe.Pointer + +func _swig_wrap_DerivedInt_covariant__SWIG_0(base SwigcptrDerivedInt, _ int, _ *int) (_ SwigcptrDerivedInt) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_DerivedInt_covariant__SWIG_0, _swig_p) + return +} + +func (arg1 SwigcptrDerivedInt) Covariant__SWIG_0(arg2 int, arg3 *int) (_swig_ret DerivedInt) { + return _swig_wrap_DerivedInt_covariant__SWIG_0(arg1, arg2, arg3) +} + +var _wrap_DerivedInt_covariant__SWIG_1 unsafe.Pointer + +func _swig_wrap_DerivedInt_covariant__SWIG_1(base SwigcptrDerivedInt, _ int) (_ SwigcptrDerivedInt) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_DerivedInt_covariant__SWIG_1, _swig_p) + return +} + +func (arg1 SwigcptrDerivedInt) Covariant__SWIG_1(arg2 int) (_swig_ret DerivedInt) { + return _swig_wrap_DerivedInt_covariant__SWIG_1(arg1, arg2) +} + +var _wrap_DerivedInt_covariant__SWIG_2 unsafe.Pointer + +func _swig_wrap_DerivedInt_covariant__SWIG_2(base SwigcptrDerivedInt) (_ SwigcptrDerivedInt) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_DerivedInt_covariant__SWIG_2, _swig_p) + return +} + +func (arg1 SwigcptrDerivedInt) Covariant__SWIG_2() (_swig_ret DerivedInt) { + return _swig_wrap_DerivedInt_covariant__SWIG_2(arg1) +} + +func (p SwigcptrDerivedInt) Covariant(a ...interface{}) DerivedInt { + argc := len(a) + if argc == 0 { + return p.Covariant__SWIG_2() + } + if argc == 1 { + return p.Covariant__SWIG_1(a[0].(int)) + } + if argc == 2 { + return p.Covariant__SWIG_0(a[0].(int), a[1].(*int)) + } + panic("No match for overloaded function call") +} + +var _wrap_DerivedInt_covariant2 unsafe.Pointer + +func _swig_wrap_DerivedInt_covariant2(base SwigcptrDerivedInt) (_ SwigcptrDerivedInt) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_DerivedInt_covariant2, _swig_p) + return +} + +func (arg1 SwigcptrDerivedInt) Covariant2() (_swig_ret DerivedInt) { + return _swig_wrap_DerivedInt_covariant2(arg1) +} + +var _wrap_DerivedInt_covariant3 unsafe.Pointer + +func _swig_wrap_DerivedInt_covariant3(base SwigcptrDerivedInt) (_ SwigcptrDerivedInt) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_DerivedInt_covariant3, _swig_p) + return +} + +func (arg1 SwigcptrDerivedInt) Covariant3() (_swig_ret DerivedInt) { + return _swig_wrap_DerivedInt_covariant3(arg1) +} + +var _wrap_DerivedInt_covariant4 unsafe.Pointer + +func _swig_wrap_DerivedInt_covariant4(base SwigcptrDerivedInt, _ float64) (_ SwigcptrDerivedInt) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_DerivedInt_covariant4, _swig_p) + return +} + +func (arg1 SwigcptrDerivedInt) Covariant4(arg2 float64) (_swig_ret DerivedInt) { + return _swig_wrap_DerivedInt_covariant4(arg1, arg2) +} + +var _wrap_DerivedInt_IsVirtual unsafe.Pointer + +func _swig_wrap_DerivedInt_IsVirtual(base SwigcptrDerivedInt) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_DerivedInt_IsVirtual, _swig_p) + return +} + +func (arg1 SwigcptrDerivedInt) IsVirtual() (_swig_ret int) { + return _swig_wrap_DerivedInt_IsVirtual(arg1) +} + +var _wrap_new_DerivedInt unsafe.Pointer + +func _swig_wrap_new_DerivedInt() (base SwigcptrDerivedInt) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_DerivedInt, _swig_p) + return +} + +func NewDerivedInt() (_swig_ret DerivedInt) { + return _swig_wrap_new_DerivedInt() +} + +var _wrap_delete_DerivedInt unsafe.Pointer + +func _swig_wrap_delete_DerivedInt(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_DerivedInt, _swig_p) + return +} + +func DeleteDerivedInt(arg1 DerivedInt) { + _swig_wrap_delete_DerivedInt(arg1.Swigcptr()) +} + +var _wrap_SetDerivedInt_T unsafe.Pointer + +func _swig_wrap_SetDerivedInt_T(base SwigcptrDerivedInt, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_SetDerivedInt_T, _swig_p) + return +} + +func (_swig_base SwigcptrDerivedInt) SetT(arg1 int) { + _swig_wrap_SetDerivedInt_T(_swig_base, arg1) +} + +var _wrap_GetDerivedInt_T unsafe.Pointer + +func _swig_wrap_GetDerivedInt_T(base SwigcptrDerivedInt) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_GetDerivedInt_T, _swig_p) + return +} + +func (_swig_base SwigcptrDerivedInt) GetT() (_swig_ret int) { + return _swig_wrap_GetDerivedInt_T(_swig_base) +} + +var _wrap_DerivedInt_StaticHidden unsafe.Pointer + +func _swig_wrap_DerivedInt_StaticHidden() { + var _swig_p uintptr + _cgo_runtime_cgocall(_wrap_DerivedInt_StaticHidden, _swig_p) + return +} + +func DerivedIntStaticHidden() { + _swig_wrap_DerivedInt_StaticHidden() +} + +func (p SwigcptrDerivedInt) SwigIsBaseInt() { +} + +func (p SwigcptrDerivedInt) SwigGetBaseInt() BaseInt { + return SwigcptrBaseInt(p.Swigcptr()) +} + +type DerivedInt interface { + Swigcptr() uintptr + SwigIsDerivedInt() + Method() (_swig_ret *int) + Foxy(a ...interface{}) interface{} + Afunction() (_swig_ret float64) + Defaultargs(a ...interface{}) *int + AmIAmINotVirtual() + NotVirtual(arg2 *int) (_swig_ret *int) + Covariant(a ...interface{}) DerivedInt + Covariant2() (_swig_ret DerivedInt) + Covariant3() (_swig_ret DerivedInt) + Covariant4(arg2 float64) (_swig_ret DerivedInt) + IsVirtual() (_swig_ret int) + SetT(arg1 int) + GetT() (_swig_ret int) + SwigIsBaseInt() + SwigGetBaseInt() BaseInt +} + +type SwigcptrBottomInt uintptr + +func (p SwigcptrBottomInt) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrBottomInt) SwigIsBottomInt() { +} + +var _wrap_BottomInt_method unsafe.Pointer + +func _swig_wrap_BottomInt_method(base SwigcptrBottomInt) (_ *int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_BottomInt_method, _swig_p) + return +} + +func (arg1 SwigcptrBottomInt) Method() (_swig_ret *int) { + return _swig_wrap_BottomInt_method(arg1) +} + +var _wrap_BottomInt_StaticHidden unsafe.Pointer + +func _swig_wrap_BottomInt_StaticHidden() { + var _swig_p uintptr + _cgo_runtime_cgocall(_wrap_BottomInt_StaticHidden, _swig_p) + return +} + +func BottomIntStaticHidden() { + _swig_wrap_BottomInt_StaticHidden() +} + +var _wrap_BottomInt_AmIAmINotVirtual unsafe.Pointer + +func _swig_wrap_BottomInt_AmIAmINotVirtual(base SwigcptrBottomInt) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_BottomInt_AmIAmINotVirtual, _swig_p) + return +} + +func (arg1 SwigcptrBottomInt) AmIAmINotVirtual() { + _swig_wrap_BottomInt_AmIAmINotVirtual(arg1) +} + +var _wrap_BottomInt_NotVirtual unsafe.Pointer + +func _swig_wrap_BottomInt_NotVirtual(base SwigcptrBottomInt, _ *int) (_ *int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_BottomInt_NotVirtual, _swig_p) + return +} + +func (arg1 SwigcptrBottomInt) NotVirtual(arg2 *int) (_swig_ret *int) { + return _swig_wrap_BottomInt_NotVirtual(arg1, arg2) +} + +var _wrap_BottomInt_funcptr_set unsafe.Pointer + +func _swig_wrap_BottomInt_funcptr_set(base SwigcptrBottomInt, _ _swig_fnptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_BottomInt_funcptr_set, _swig_p) + return +} + +func (arg1 SwigcptrBottomInt) SetFuncptr(arg2 _swig_fnptr) { + _swig_wrap_BottomInt_funcptr_set(arg1, arg2) +} + +var _wrap_BottomInt_funcptr_get unsafe.Pointer + +func _swig_wrap_BottomInt_funcptr_get(base SwigcptrBottomInt) (_ _swig_fnptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_BottomInt_funcptr_get, _swig_p) + return +} + +func (arg1 SwigcptrBottomInt) GetFuncptr() (_swig_ret _swig_fnptr) { + return _swig_wrap_BottomInt_funcptr_get(arg1) +} + +var _wrap_BottomInt_covariant__SWIG_0 unsafe.Pointer + +func _swig_wrap_BottomInt_covariant__SWIG_0(base SwigcptrBottomInt, _ int, _ *int) (_ SwigcptrBottomInt) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_BottomInt_covariant__SWIG_0, _swig_p) + return +} + +func (arg1 SwigcptrBottomInt) Covariant__SWIG_0(arg2 int, arg3 *int) (_swig_ret BottomInt) { + return _swig_wrap_BottomInt_covariant__SWIG_0(arg1, arg2, arg3) +} + +var _wrap_BottomInt_covariant__SWIG_1 unsafe.Pointer + +func _swig_wrap_BottomInt_covariant__SWIG_1(base SwigcptrBottomInt, _ int) (_ SwigcptrBottomInt) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_BottomInt_covariant__SWIG_1, _swig_p) + return +} + +func (arg1 SwigcptrBottomInt) Covariant__SWIG_1(arg2 int) (_swig_ret BottomInt) { + return _swig_wrap_BottomInt_covariant__SWIG_1(arg1, arg2) +} + +var _wrap_BottomInt_covariant__SWIG_2 unsafe.Pointer + +func _swig_wrap_BottomInt_covariant__SWIG_2(base SwigcptrBottomInt) (_ SwigcptrBottomInt) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_BottomInt_covariant__SWIG_2, _swig_p) + return +} + +func (arg1 SwigcptrBottomInt) Covariant__SWIG_2() (_swig_ret BottomInt) { + return _swig_wrap_BottomInt_covariant__SWIG_2(arg1) +} + +func (p SwigcptrBottomInt) Covariant(a ...interface{}) BottomInt { + argc := len(a) + if argc == 0 { + return p.Covariant__SWIG_2() + } + if argc == 1 { + return p.Covariant__SWIG_1(a[0].(int)) + } + if argc == 2 { + return p.Covariant__SWIG_0(a[0].(int), a[1].(*int)) + } + panic("No match for overloaded function call") +} + +var _wrap_BottomInt_covariant2 unsafe.Pointer + +func _swig_wrap_BottomInt_covariant2(base SwigcptrBottomInt) (_ SwigcptrDerivedInt) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_BottomInt_covariant2, _swig_p) + return +} + +func (arg1 SwigcptrBottomInt) Covariant2() (_swig_ret DerivedInt) { + return _swig_wrap_BottomInt_covariant2(arg1) +} + +var _wrap_BottomInt_covariant3 unsafe.Pointer + +func _swig_wrap_BottomInt_covariant3(base SwigcptrBottomInt) (_ SwigcptrBottomInt) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_BottomInt_covariant3, _swig_p) + return +} + +func (arg1 SwigcptrBottomInt) Covariant3() (_swig_ret BottomInt) { + return _swig_wrap_BottomInt_covariant3(arg1) +} + +var _wrap_BottomInt_covariant4 unsafe.Pointer + +func _swig_wrap_BottomInt_covariant4(base SwigcptrBottomInt, _ float64) (_ SwigcptrBottomInt) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_BottomInt_covariant4, _swig_p) + return +} + +func (arg1 SwigcptrBottomInt) Covariant4(arg2 float64) (_swig_ret BottomInt) { + return _swig_wrap_BottomInt_covariant4(arg1, arg2) +} + +var _wrap_BottomInt_IsVirtual unsafe.Pointer + +func _swig_wrap_BottomInt_IsVirtual(base SwigcptrBottomInt) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_BottomInt_IsVirtual, _swig_p) + return +} + +func (arg1 SwigcptrBottomInt) IsVirtual() (_swig_ret int) { + return _swig_wrap_BottomInt_IsVirtual(arg1) +} + +var _wrap_new_BottomInt unsafe.Pointer + +func _swig_wrap_new_BottomInt() (base SwigcptrBottomInt) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_BottomInt, _swig_p) + return +} + +func NewBottomInt() (_swig_ret BottomInt) { + return _swig_wrap_new_BottomInt() +} + +var _wrap_delete_BottomInt unsafe.Pointer + +func _swig_wrap_delete_BottomInt(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_BottomInt, _swig_p) + return +} + +func DeleteBottomInt(arg1 BottomInt) { + _swig_wrap_delete_BottomInt(arg1.Swigcptr()) +} + +var _wrap_BottomInt_foxy__SWIG_0 unsafe.Pointer + +func _swig_wrap_BottomInt_foxy__SWIG_0(base SwigcptrBottomInt) (_ *int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_BottomInt_foxy__SWIG_0, _swig_p) + return +} + +func (_swig_base SwigcptrBottomInt) Foxy__SWIG_0() (_swig_ret *int) { + return _swig_wrap_BottomInt_foxy__SWIG_0(_swig_base) +} + +var _wrap_BottomInt_foxy__SWIG_1 unsafe.Pointer + +func _swig_wrap_BottomInt_foxy__SWIG_1(base SwigcptrBottomInt, _ int) (_ *int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_BottomInt_foxy__SWIG_1, _swig_p) + return +} + +func (_swig_base SwigcptrBottomInt) Foxy__SWIG_1(arg1 int) (_swig_ret *int) { + return _swig_wrap_BottomInt_foxy__SWIG_1(_swig_base, arg1) +} + +var _wrap_BottomInt_foxy__SWIG_2 unsafe.Pointer + +func _swig_wrap_BottomInt_foxy__SWIG_2(base SwigcptrBottomInt, _ **int) (_ *int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_BottomInt_foxy__SWIG_2, _swig_p) + return +} + +func (_swig_base SwigcptrBottomInt) Foxy__SWIG_2(arg1 **int) (_swig_ret *int) { + return _swig_wrap_BottomInt_foxy__SWIG_2(_swig_base, arg1) +} + +func (p SwigcptrBottomInt) Foxy(a ...interface{}) interface{} { + argc := len(a) + if argc == 0 { + return p.Foxy__SWIG_0() + } + if argc == 1 { + if _, ok := a[0].(**int); !ok { + goto check_2 + } + return p.Foxy__SWIG_2(a[0].(**int)) + } +check_2: + if argc == 1 { + return p.Foxy__SWIG_1(a[0].(int)) + } + panic("No match for overloaded function call") +} + +var _wrap_BottomInt_afunction unsafe.Pointer + +func _swig_wrap_BottomInt_afunction(base SwigcptrBottomInt) (_ float64) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_BottomInt_afunction, _swig_p) + return +} + +func (_swig_base SwigcptrBottomInt) Afunction() (_swig_ret float64) { + return _swig_wrap_BottomInt_afunction(_swig_base) +} + +var _wrap_BottomInt_defaultargs__SWIG_0 unsafe.Pointer + +func _swig_wrap_BottomInt_defaultargs__SWIG_0(base SwigcptrBottomInt, _ float64, _ *int) (_ *int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_BottomInt_defaultargs__SWIG_0, _swig_p) + return +} + +func (_swig_base SwigcptrBottomInt) Defaultargs__SWIG_0(arg1 float64, arg2 *int) (_swig_ret *int) { + return _swig_wrap_BottomInt_defaultargs__SWIG_0(_swig_base, arg1, arg2) +} + +var _wrap_BottomInt_defaultargs__SWIG_1 unsafe.Pointer + +func _swig_wrap_BottomInt_defaultargs__SWIG_1(base SwigcptrBottomInt, _ float64) (_ *int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_BottomInt_defaultargs__SWIG_1, _swig_p) + return +} + +func (_swig_base SwigcptrBottomInt) Defaultargs__SWIG_1(arg1 float64) (_swig_ret *int) { + return _swig_wrap_BottomInt_defaultargs__SWIG_1(_swig_base, arg1) +} + +func (p SwigcptrBottomInt) Defaultargs(a ...interface{}) *int { + argc := len(a) + if argc == 1 { + return p.Defaultargs__SWIG_1(a[0].(float64)) + } + if argc == 2 { + return p.Defaultargs__SWIG_0(a[0].(float64), a[1].(*int)) + } + panic("No match for overloaded function call") +} + +var _wrap_SetBottomInt_T unsafe.Pointer + +func _swig_wrap_SetBottomInt_T(base SwigcptrBottomInt, _ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_SetBottomInt_T, _swig_p) + return +} + +func (_swig_base SwigcptrBottomInt) SetT(arg1 int) { + _swig_wrap_SetBottomInt_T(_swig_base, arg1) +} + +var _wrap_GetBottomInt_T unsafe.Pointer + +func _swig_wrap_GetBottomInt_T(base SwigcptrBottomInt) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_GetBottomInt_T, _swig_p) + return +} + +func (_swig_base SwigcptrBottomInt) GetT() (_swig_ret int) { + return _swig_wrap_GetBottomInt_T(_swig_base) +} + +func (p SwigcptrBottomInt) SwigIsDerivedInt() { +} + +func (p SwigcptrBottomInt) SwigGetDerivedInt() DerivedInt { + return SwigcptrDerivedInt(p.Swigcptr()) +} + +func (p SwigcptrBottomInt) SwigIsBaseInt() { +} + +func (p SwigcptrBottomInt) SwigGetBaseInt() BaseInt { + return SwigcptrBaseInt(p.Swigcptr()) +} + +type BottomInt interface { + Swigcptr() uintptr + SwigIsBottomInt() + Method() (_swig_ret *int) + AmIAmINotVirtual() + NotVirtual(arg2 *int) (_swig_ret *int) + SetFuncptr(arg2 _swig_fnptr) + GetFuncptr() (_swig_ret _swig_fnptr) + Covariant(a ...interface{}) BottomInt + Covariant2() (_swig_ret DerivedInt) + Covariant3() (_swig_ret BottomInt) + Covariant4(arg2 float64) (_swig_ret BottomInt) + IsVirtual() (_swig_ret int) + Foxy(a ...interface{}) interface{} + Afunction() (_swig_ret float64) + Defaultargs(a ...interface{}) *int + SetT(arg1 int) + GetT() (_swig_ret int) + SwigIsDerivedInt() + SwigGetDerivedInt() DerivedInt + SwigIsBaseInt() + SwigGetBaseInt() BaseInt +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/virtual_poly_runme b/Examples/test-suite/go/virtual_poly_runme new file mode 100755 index 000000000..670688de5 Binary files /dev/null and b/Examples/test-suite/go/virtual_poly_runme differ diff --git a/Examples/test-suite/go/virtual_poly_wrap.h b/Examples/test-suite/go/virtual_poly_wrap.h new file mode 100644 index 000000000..6c64bf2bb --- /dev/null +++ b/Examples/test-suite/go/virtual_poly_wrap.h @@ -0,0 +1,16 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../virtual_poly.i + +#ifndef SWIG_virtual_poly_WRAP_H_ +#define SWIG_virtual_poly_WRAP_H_ + +#endif diff --git a/Examples/test-suite/go/virtual_vs_nonvirtual_base.go b/Examples/test-suite/go/virtual_vs_nonvirtual_base.go new file mode 100644 index 000000000..f2355fb7e --- /dev/null +++ b/Examples/test-suite/go/virtual_vs_nonvirtual_base.go @@ -0,0 +1,337 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../virtual_vs_nonvirtual_base.i + +package virtual_vs_nonvirtual_base + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +type SwigcptrSimpleVirtual uintptr + +func (p SwigcptrSimpleVirtual) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrSimpleVirtual) SwigIsSimpleVirtual() { +} + +var _wrap_SimpleVirtual_implementMe unsafe.Pointer + +func _swig_wrap_SimpleVirtual_implementMe(base SwigcptrSimpleVirtual) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_SimpleVirtual_implementMe, _swig_p) + return +} + +func (arg1 SwigcptrSimpleVirtual) ImplementMe() (_swig_ret int) { + return _swig_wrap_SimpleVirtual_implementMe(arg1) +} + +var _wrap_delete_SimpleVirtual unsafe.Pointer + +func _swig_wrap_delete_SimpleVirtual(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_SimpleVirtual, _swig_p) + return +} + +func DeleteSimpleVirtual(arg1 SimpleVirtual) { + _swig_wrap_delete_SimpleVirtual(arg1.Swigcptr()) +} + +type SimpleVirtual interface { + Swigcptr() uintptr + SwigIsSimpleVirtual() + ImplementMe() (_swig_ret int) +} + +type SwigcptrSimpleNonVirtual uintptr + +func (p SwigcptrSimpleNonVirtual) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrSimpleNonVirtual) SwigIsSimpleNonVirtual() { +} + +var _wrap_SimpleNonVirtual_dummy unsafe.Pointer + +func _swig_wrap_SimpleNonVirtual_dummy(base SwigcptrSimpleNonVirtual) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_SimpleNonVirtual_dummy, _swig_p) + return +} + +func (arg1 SwigcptrSimpleNonVirtual) Dummy() (_swig_ret int) { + return _swig_wrap_SimpleNonVirtual_dummy(arg1) +} + +var _wrap_new_SimpleNonVirtual unsafe.Pointer + +func _swig_wrap_new_SimpleNonVirtual() (base SwigcptrSimpleNonVirtual) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_SimpleNonVirtual, _swig_p) + return +} + +func NewSimpleNonVirtual() (_swig_ret SimpleNonVirtual) { + return _swig_wrap_new_SimpleNonVirtual() +} + +var _wrap_delete_SimpleNonVirtual unsafe.Pointer + +func _swig_wrap_delete_SimpleNonVirtual(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_SimpleNonVirtual, _swig_p) + return +} + +func DeleteSimpleNonVirtual(arg1 SimpleNonVirtual) { + _swig_wrap_delete_SimpleNonVirtual(arg1.Swigcptr()) +} + +type SimpleNonVirtual interface { + Swigcptr() uintptr + SwigIsSimpleNonVirtual() + Dummy() (_swig_ret int) +} + +type SwigcptrSimpleReturnClass uintptr + +func (p SwigcptrSimpleReturnClass) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrSimpleReturnClass) SwigIsSimpleReturnClass() { +} + +var _wrap_new_SimpleReturnClass unsafe.Pointer + +func _swig_wrap_new_SimpleReturnClass(base int) (_ SwigcptrSimpleReturnClass) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_SimpleReturnClass, _swig_p) + return +} + +func NewSimpleReturnClass(arg1 int) (_swig_ret SimpleReturnClass) { + return _swig_wrap_new_SimpleReturnClass(arg1) +} + +var _wrap_SimpleReturnClass_get unsafe.Pointer + +func _swig_wrap_SimpleReturnClass_get(base SwigcptrSimpleReturnClass) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_SimpleReturnClass_get, _swig_p) + return +} + +func (arg1 SwigcptrSimpleReturnClass) Get() (_swig_ret int) { + return _swig_wrap_SimpleReturnClass_get(arg1) +} + +var _wrap_delete_SimpleReturnClass unsafe.Pointer + +func _swig_wrap_delete_SimpleReturnClass(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_SimpleReturnClass, _swig_p) + return +} + +func DeleteSimpleReturnClass(arg1 SimpleReturnClass) { + _swig_wrap_delete_SimpleReturnClass(arg1.Swigcptr()) +} + +type SimpleReturnClass interface { + Swigcptr() uintptr + SwigIsSimpleReturnClass() + Get() (_swig_ret int) +} + +type SwigcptrSimpleClassFail uintptr + +func (p SwigcptrSimpleClassFail) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrSimpleClassFail) SwigIsSimpleClassFail() { +} + +var _wrap_new_SimpleClassFail unsafe.Pointer + +func _swig_wrap_new_SimpleClassFail() (base SwigcptrSimpleClassFail) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_SimpleClassFail, _swig_p) + return +} + +func NewSimpleClassFail() (_swig_ret SimpleClassFail) { + return _swig_wrap_new_SimpleClassFail() +} + +var _wrap_SimpleClassFail_getInner unsafe.Pointer + +func _swig_wrap_SimpleClassFail_getInner(base SwigcptrSimpleClassFail) (_ SwigcptrSimpleReturnClass) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_SimpleClassFail_getInner, _swig_p) + return +} + +func (arg1 SwigcptrSimpleClassFail) GetInner() (_swig_ret SimpleReturnClass) { + return _swig_wrap_SimpleClassFail_getInner(arg1) +} + +var _wrap_SimpleClassFail_implementMe unsafe.Pointer + +func _swig_wrap_SimpleClassFail_implementMe(base SwigcptrSimpleClassFail) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_SimpleClassFail_implementMe, _swig_p) + return +} + +func (arg1 SwigcptrSimpleClassFail) ImplementMe() (_swig_ret int) { + return _swig_wrap_SimpleClassFail_implementMe(arg1) +} + +var _wrap_delete_SimpleClassFail unsafe.Pointer + +func _swig_wrap_delete_SimpleClassFail(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_SimpleClassFail, _swig_p) + return +} + +func DeleteSimpleClassFail(arg1 SimpleClassFail) { + _swig_wrap_delete_SimpleClassFail(arg1.Swigcptr()) +} + +func (p SwigcptrSimpleClassFail) SwigIsSimpleVirtual() { +} + +func (p SwigcptrSimpleClassFail) SwigGetSimpleVirtual() SimpleVirtual { + return SwigcptrSimpleVirtual(p.Swigcptr()) +} + +type SimpleClassFail interface { + Swigcptr() uintptr + SwigIsSimpleClassFail() + GetInner() (_swig_ret SimpleReturnClass) + ImplementMe() (_swig_ret int) + SwigIsSimpleVirtual() + SwigGetSimpleVirtual() SimpleVirtual +} + +type SwigcptrSimpleClassWork uintptr + +func (p SwigcptrSimpleClassWork) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrSimpleClassWork) SwigIsSimpleClassWork() { +} + +var _wrap_new_SimpleClassWork unsafe.Pointer + +func _swig_wrap_new_SimpleClassWork() (base SwigcptrSimpleClassWork) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_SimpleClassWork, _swig_p) + return +} + +func NewSimpleClassWork() (_swig_ret SimpleClassWork) { + return _swig_wrap_new_SimpleClassWork() +} + +var _wrap_SimpleClassWork_getInner unsafe.Pointer + +func _swig_wrap_SimpleClassWork_getInner(base SwigcptrSimpleClassWork) (_ SwigcptrSimpleReturnClass) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_SimpleClassWork_getInner, _swig_p) + return +} + +func (arg1 SwigcptrSimpleClassWork) GetInner() (_swig_ret SimpleReturnClass) { + return _swig_wrap_SimpleClassWork_getInner(arg1) +} + +var _wrap_SimpleClassWork_implementMe unsafe.Pointer + +func _swig_wrap_SimpleClassWork_implementMe(base SwigcptrSimpleClassWork) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_SimpleClassWork_implementMe, _swig_p) + return +} + +func (arg1 SwigcptrSimpleClassWork) ImplementMe() (_swig_ret int) { + return _swig_wrap_SimpleClassWork_implementMe(arg1) +} + +var _wrap_delete_SimpleClassWork unsafe.Pointer + +func _swig_wrap_delete_SimpleClassWork(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_SimpleClassWork, _swig_p) + return +} + +func DeleteSimpleClassWork(arg1 SimpleClassWork) { + _swig_wrap_delete_SimpleClassWork(arg1.Swigcptr()) +} + +var _wrap_SimpleClassWork_dummy unsafe.Pointer + +func _swig_wrap_SimpleClassWork_dummy(base SwigcptrSimpleClassWork) (_ int) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_SimpleClassWork_dummy, _swig_p) + return +} + +func (_swig_base SwigcptrSimpleClassWork) Dummy() (_swig_ret int) { + return _swig_wrap_SimpleClassWork_dummy(_swig_base) +} + +func (p SwigcptrSimpleClassWork) SwigIsSimpleNonVirtual() { +} + +func (p SwigcptrSimpleClassWork) SwigGetSimpleNonVirtual() SimpleNonVirtual { + return SwigcptrSimpleNonVirtual(p.Swigcptr()) +} + +type SimpleClassWork interface { + Swigcptr() uintptr + SwigIsSimpleClassWork() + GetInner() (_swig_ret SimpleReturnClass) + ImplementMe() (_swig_ret int) + Dummy() (_swig_ret int) + SwigIsSimpleNonVirtual() + SwigGetSimpleNonVirtual() SimpleNonVirtual +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/voidtest.go b/Examples/test-suite/go/voidtest.go new file mode 100644 index 000000000..abc392d45 --- /dev/null +++ b/Examples/test-suite/go/voidtest.go @@ -0,0 +1,155 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../voidtest.i + +package voidtest + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +var _wrap_globalfunc unsafe.Pointer + +func _swig_wrap_globalfunc() { + var _swig_p uintptr + _cgo_runtime_cgocall(_wrap_globalfunc, _swig_p) + return +} + +func Globalfunc() { + _swig_wrap_globalfunc() +} + +type SwigcptrFoo uintptr + +func (p SwigcptrFoo) Swigcptr() uintptr { + return (uintptr)(p) +} + +func (p SwigcptrFoo) SwigIsFoo() { +} + +var _wrap_new_Foo unsafe.Pointer + +func _swig_wrap_new_Foo() (base SwigcptrFoo) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_new_Foo, _swig_p) + return +} + +func NewFoo() (_swig_ret Foo) { + return _swig_wrap_new_Foo() +} + +var _wrap_Foo_memberfunc unsafe.Pointer + +func _swig_wrap_Foo_memberfunc(base SwigcptrFoo) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_Foo_memberfunc, _swig_p) + return +} + +func (arg1 SwigcptrFoo) Memberfunc() { + _swig_wrap_Foo_memberfunc(arg1) +} + +var _wrap_Foo_staticmemberfunc unsafe.Pointer + +func _swig_wrap_Foo_staticmemberfunc() { + var _swig_p uintptr + _cgo_runtime_cgocall(_wrap_Foo_staticmemberfunc, _swig_p) + return +} + +func FooStaticmemberfunc() { + _swig_wrap_Foo_staticmemberfunc() +} + +var _wrap_delete_Foo unsafe.Pointer + +func _swig_wrap_delete_Foo(base uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_delete_Foo, _swig_p) + return +} + +func DeleteFoo(arg1 Foo) { + _swig_wrap_delete_Foo(arg1.Swigcptr()) +} + +type Foo interface { + Swigcptr() uintptr + SwigIsFoo() + Memberfunc() +} + +var _wrap_vfunc1 unsafe.Pointer + +func Vfunc1(arg1 uintptr) (_swig_ret uintptr) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_vfunc1, _swig_p) + return +} +var _wrap_vfunc2 unsafe.Pointer + +func _swig_wrap_vfunc2(base uintptr) (_ uintptr) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_vfunc2, _swig_p) + return +} + +func Vfunc2(arg1 Foo) (_swig_ret uintptr) { + return _swig_wrap_vfunc2(arg1.Swigcptr()) +} + +var _wrap_vfunc3 unsafe.Pointer + +func _swig_wrap_vfunc3(base uintptr) (_ SwigcptrFoo) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_vfunc3, _swig_p) + return +} + +func Vfunc3(arg1 uintptr) (_swig_ret Foo) { + return _swig_wrap_vfunc3(arg1) +} + +var _wrap_vfunc4 unsafe.Pointer + +func _swig_wrap_vfunc4(base uintptr) (_ SwigcptrFoo) { + _swig_p := uintptr(unsafe.Pointer(&base)) + _cgo_runtime_cgocall(_wrap_vfunc4, _swig_p) + return +} + +func Vfunc4(arg1 Foo) (_swig_ret Foo) { + return _swig_wrap_vfunc4(arg1.Swigcptr()) +} + + +type SwigcptrVoid uintptr +type Void interface { + Swigcptr() uintptr; +} +func (p SwigcptrVoid) Swigcptr() uintptr { + return uintptr(p) +} + diff --git a/Examples/test-suite/go/voidtest_runme b/Examples/test-suite/go/voidtest_runme new file mode 100755 index 000000000..6b00a71c3 Binary files /dev/null and b/Examples/test-suite/go/voidtest_runme differ diff --git a/Examples/test-suite/go/wallkw.go b/Examples/test-suite/go/wallkw.go new file mode 100644 index 000000000..37fcd8e98 --- /dev/null +++ b/Examples/test-suite/go/wallkw.go @@ -0,0 +1,64 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../wallkw.i + +package wallkw + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +var _wrap_c_clone unsafe.Pointer + +func C_clone() (_swig_ret string) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_c_clone, _swig_p) + return +} +var _wrap__delegate unsafe.Pointer + +func X_delegate() (_swig_ret string) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap__delegate, _swig_p) + return +} +var _wrap__pass unsafe.Pointer + +func X_pass() (_swig_ret string) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap__pass, _swig_p) + return +} +var _wrap__alias unsafe.Pointer + +func X_alias() (_swig_ret string) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap__alias, _swig_p) + return +} +var _wrap_C_rescue unsafe.Pointer + +func C_rescue() (_swig_ret string) { + _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) + _cgo_runtime_cgocall(_wrap_C_rescue, _swig_p) + return +} + diff --git a/Examples/test-suite/go/wrapmacro.go b/Examples/test-suite/go/wrapmacro.go new file mode 100644 index 000000000..dd3b03f95 --- /dev/null +++ b/Examples/test-suite/go/wrapmacro.go @@ -0,0 +1,68 @@ +/* ---------------------------------------------------------------------------- + * This file was automatically generated by SWIG (http://www.swig.org). + * Version 3.0.3 + * + * This file is not intended to be easily readable and contains a number of + * coding conventions designed to improve portability and efficiency. Do not make + * changes to this file unless you know what you are doing--modify the SWIG + * interface file instead. + * ----------------------------------------------------------------------------- */ + +// source: ./../wrapmacro.i + +package wrapmacro + +import "unsafe" +import _ "runtime/cgo" + +var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) + + + +type _ unsafe.Pointer + + + +type _swig_fnptr *byte +type _swig_memberptr *byte + +var _wrap_GUINT16_SWAP_LE_BE_CONSTANT unsafe.Pointer + +func GUINT16_SWAP_LE_BE_CONSTANT(arg1 uint16) (_swig_ret uint16) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_GUINT16_SWAP_LE_BE_CONSTANT, _swig_p) + return +} +var _wrap_maximum__SWIG_0 unsafe.Pointer + +func Maximum__SWIG_0(arg1 int64, arg2 int64) (_swig_ret int64) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_maximum__SWIG_0, _swig_p) + return +} +var _wrap_maximum__SWIG_1 unsafe.Pointer + +func Maximum__SWIG_1(arg1 float64, arg2 float64) (_swig_ret float64) { + _swig_p := uintptr(unsafe.Pointer(&arg1)) + _cgo_runtime_cgocall(_wrap_maximum__SWIG_1, _swig_p) + return +} +func Maximum(a ...interface{}) interface{} { + argc := len(a) + if argc == 2 { + if _, ok := a[0].(int64); !ok { + goto check_1 + } + if _, ok := a[1].(int64); !ok { + goto check_1 + } + return Maximum__SWIG_0(a[0].(int64), a[1].(int64)) + } +check_1: + if argc == 2 { + return Maximum__SWIG_1(a[0].(float64), a[1].(float64)) + } + panic("No match for overloaded function call") +} + + diff --git a/Examples/test-suite/go/wrapmacro_runme b/Examples/test-suite/go/wrapmacro_runme new file mode 100755 index 000000000..c6499ab30 Binary files /dev/null and b/Examples/test-suite/go/wrapmacro_runme differ diff --git a/Examples/test-suite/overload_polymorphic.i b/Examples/test-suite/overload_polymorphic.i new file mode 100644 index 000000000..83e3cc257 --- /dev/null +++ b/Examples/test-suite/overload_polymorphic.i @@ -0,0 +1,25 @@ +%module overload_polymorphic + +#ifndef SWIG_NO_OVERLOAD + +%inline %{ + +class Base { +public: + Base(){} + virtual ~Base(){} +}; + +class Derived : public Base { +public: + Derived(){} + virtual ~Derived(){} +}; + + + +int test(Base* base){ return 0;} +int test(int hello){ return 1; } + +%} +#endif diff --git a/Examples/test-suite/overload_polymorphic.i~ b/Examples/test-suite/overload_polymorphic.i~ new file mode 100644 index 000000000..5581e2e47 --- /dev/null +++ b/Examples/test-suite/overload_polymorphic.i~ @@ -0,0 +1,25 @@ +%module overload_polymorphic + +#ifndef SWIG_NO_OVERLOAD + +%inline %{ + +class Base { +public: + Base(){} + virtual ~Base(){} +}; + +class Derived : public Base { +public: + Derived(){} + virtual ~Derived(){} +}; + + + +void test(Base* base){} +void test(int hello){} + +%} +#endif diff --git a/Examples/test-suite/overload_rename.i~ b/Examples/test-suite/overload_rename.i~ new file mode 100644 index 000000000..6568c7681 --- /dev/null +++ b/Examples/test-suite/overload_rename.i~ @@ -0,0 +1,30 @@ +%module overload_rename + + +%inline %{ + +class Base { +public: + Base(){} + virtual void Print(){printf("I'm Base.\n");} + virtual ~Base(){} +}; + +class Derived : public Base { +public: + Derived(){} + void Print(){printf("I'm Derived.\n");} + virtual ~Derived(){} +}; + + + +void test(Base* base){ + base->Print(); +} +void test(int hello){ + printf("%d\n", hello); +} + +%} + diff --git a/Source/Modules/go.cxx b/Source/Modules/go.cxx index c9910ab05..26cf015f7 100644 --- a/Source/Modules/go.cxx +++ b/Source/Modules/go.cxx @@ -4363,7 +4363,7 @@ private: } fn = i + 1; - Printf(f_go_wrappers, "\t\tif _, ok := a[%d].(%s); !ok {\n", j, tm); + Printf(f_go_wrappers, "\t\tif _, ok := a[%d].(%s); !ok {\n", j, goType(pj, Getattr(pj, "type"))); Printf(f_go_wrappers, "\t\t\tgoto check_%d\n", fn); Printv(f_go_wrappers, "\t\t}\n", NULL); } diff --git a/Source/Modules/go.cxx~ b/Source/Modules/go.cxx~ new file mode 100644 index 000000000..c9910ab05 --- /dev/null +++ b/Source/Modules/go.cxx~ @@ -0,0 +1,5385 @@ +/* ----------------------------------------------------------------------------- + * See the LICENSE file for information on copyright, usage and redistribution + * of SWIG, and the README file for authors - http://www.swig.org/release.html. + * + * go.cxx + * + * Go language module for SWIG. + * ----------------------------------------------------------------------------- */ + +#include "swigmod.h" +#include "cparse.h" +#include + +class GO:public Language { + static const char *const usage; + + // Go package name. + String *package; + // SWIG module name. + String *module; + // Flag for generating gccgo output. + bool gccgo_flag; + // Prefix to use with gccgo. + String *go_prefix; + // -fgo-prefix option. + String *prefix_option; + // -fgo-pkgpath option. + String *pkgpath_option; + // Whether to use a shared library. + bool use_shlib; + // Name of shared library to import. + String *soname; + // Size in bits of the Go type "int". 0 if not specified. + int intgo_type_size; + + /* Output files */ + File *f_c_begin; + File *f_go_begin; + File *f_gc_begin; + + /* Output fragments */ + File *f_c_runtime; + File *f_c_header; + File *f_c_wrappers; + File *f_c_init; + File *f_c_directors; + File *f_c_directors_h; + File *f_go_imports; + File *f_go_runtime; + File *f_go_header; + File *f_go_wrappers; + File *f_gc_runtime; + File *f_gc_header; + File *f_gc_wrappers; + + // True if we imported a module. + bool saw_import; + // If not NULL, name of import package being processed. + String *imported_package; + // Build interface methods while handling a class. This is only + // non-NULL when we are handling methods. + String *interfaces; + // The class node while handling a class. This is only non-NULL + // when we are handling methods. + Node *class_node; + // The class name while handling a class. This is only non-NULL + // when we are handling methods. This is the name of the class as + // SWIG sees it. + String *class_name; + // The receiver name while handling a class. This is only non-NULL + // when we are handling methods. This is the name of the class + // as run through goCPointerType. + String *class_receiver; + // A hash table of method names that we have seen when processing a + // class. This lets us detect base class methods that we don't want + // to use. + Hash *class_methods; + // True when we are generating the wrapper functions for a variable. + bool making_variable_wrappers; + // True when working with a static member function. + bool is_static_member_function; + // A hash table of enum types that we have seen but which may not have + // been defined. The index is a SwigType. + Hash *undefined_enum_types; + // A hash table of types that we have seen but which may not have + // been defined. The index is a SwigType. + Hash *undefined_types; + // A hash table of classes which were defined. The index is a Go + // type name. + Hash *defined_types; + // A hash table of all the go_imports already imported. The index is a full + // import name e.g. '"runtime"' or '_ "runtime/cgo"' or 'sc "syscall"'. + Hash *go_imports; + +public: + GO():package(NULL), + module(NULL), + gccgo_flag(false), + go_prefix(NULL), + prefix_option(NULL), + pkgpath_option(NULL), + use_shlib(false), + soname(NULL), + intgo_type_size(0), + f_c_begin(NULL), + f_go_begin(NULL), + f_gc_begin(NULL), + f_c_runtime(NULL), + f_c_header(NULL), + f_c_wrappers(NULL), + f_c_init(NULL), + f_c_directors(NULL), + f_c_directors_h(NULL), + f_go_imports(NULL), + f_go_runtime(NULL), + f_go_header(NULL), + f_go_wrappers(NULL), + f_gc_runtime(NULL), + f_gc_header(NULL), + f_gc_wrappers(NULL), + saw_import(false), + imported_package(NULL), + interfaces(NULL), + class_node(NULL), + class_name(NULL), + class_receiver(NULL), + class_methods(NULL), + making_variable_wrappers(false), + is_static_member_function(false), + undefined_enum_types(NULL), + undefined_types(NULL), + defined_types(NULL), + go_imports(NULL) { + director_multiple_inheritance = 1; + director_language = 1; + director_prot_ctor_code = NewString("_swig_gopanic(\"accessing abstract class or protected constructor\");"); + } + +private: + /* ------------------------------------------------------------ + * main() + * ------------------------------------------------------------ */ + virtual void main(int argc, char *argv[]) { + + SWIG_library_directory("go"); + bool display_help = false; + + // Process command line options. + for (int i = 1; i < argc; i++) { + if (argv[i]) { + if (strcmp(argv[i], "-package") == 0) { + if (argv[i + 1]) { + package = NewString(argv[i + 1]); + Swig_mark_arg(i); + Swig_mark_arg(i + 1); + i++; + } else { + Swig_arg_error(); + } + } else if (strcmp(argv[i], "-gccgo") == 0) { + Swig_mark_arg(i); + gccgo_flag = true; + } else if (strcmp(argv[i], "-go-prefix") == 0) { + if (argv[i + 1]) { + prefix_option = NewString(argv[i + 1]); + Swig_mark_arg(i); + Swig_mark_arg(i + 1); + i++; + } else { + Swig_arg_error(); + } + } else if (strcmp(argv[i], "-go-pkgpath") == 0) { + if (argv[i + 1]) { + pkgpath_option = NewString(argv[i + 1]); + Swig_mark_arg(i); + Swig_mark_arg(i + 1); + i++; + } else { + Swig_arg_error(); + } + } else if (strcmp(argv[i], "-use-shlib") == 0) { + Swig_mark_arg(i); + use_shlib = true; + } else if (strcmp(argv[i], "-soname") == 0) { + if (argv[i + 1]) { + soname = NewString(argv[i + 1]); + Swig_mark_arg(i); + Swig_mark_arg(i + 1); + i++; + } else { + Swig_arg_error(); + } + } else if (strcmp(argv[i], "-longsize") == 0) { + // Ignore for backward compatibility. + if (argv[i + 1]) { + Swig_mark_arg(i); + Swig_mark_arg(i + 1); + ++i; + } else { + Swig_arg_error(); + } + } else if (strcmp(argv[i], "-intgosize") == 0) { + if (argv[i + 1]) { + intgo_type_size = atoi(argv[i + 1]); + if (intgo_type_size != 32 && intgo_type_size != 64) { + Printf(stderr, "-intgosize not 32 or 64\n"); + Swig_arg_error(); + } + Swig_mark_arg(i); + Swig_mark_arg(i + 1); + ++i; + } else { + Swig_arg_error(); + } + } else if (strcmp(argv[i], "-help") == 0) { + display_help = true; + Printf(stdout, "%s\n", usage); + } + } + } + + if (gccgo_flag && !pkgpath_option && !prefix_option) { + prefix_option = NewString("go"); + } + + // Add preprocessor symbol to parser. + Preprocessor_define("SWIGGO 1", 0); + + if (gccgo_flag) { + Preprocessor_define("SWIGGO_GCCGO 1", 0); + } + + // This test may be removed in the future, when we can assume that + // everybody has upgraded to Go 1.1. The code below is prepared + // for this test to simply be taken out. + if (intgo_type_size == 0 && !display_help) { + Printf(stderr, "SWIG -go: -intgosize option required but not specified\n"); + SWIG_exit(EXIT_FAILURE); + } + + if (intgo_type_size == 32) { + Preprocessor_define("SWIGGO_INTGO_SIZE 32", 0); + } else if (intgo_type_size == 64) { + Preprocessor_define("SWIGGO_INTGO_SIZE 64", 0); + } else { + Preprocessor_define("SWIGGO_INTGO_SIZE 0", 0); + } + + // Add typemap definitions. + SWIG_typemap_lang("go"); + SWIG_config_file("go.swg"); + + allow_overloading(); + } + + /* --------------------------------------------------------------------- + * top() + * + * For 6g/8g, we are going to create the following files: + * + * 1) A .c or .cxx file compiled with gcc. This file will contain + * function wrappers. Each wrapper will take a pointer to a + * struct holding the arguments, unpack them, and call the real + * function. + * + * 2) A .go file which defines the Go form of all types, and which + * defines Go function wrappers. Each wrapper will call the C + * function wrapper in the second file. + * + * 3) A .c file compiled with 6c/8c. This file will define + * Go-callable C function wrappers. Each wrapper will use + * cgocall to call the function wrappers in the first file. + * + * When generating code for gccgo, we don't need the third file, and + * the function wrappers in the first file have a different form. + * + * --------------------------------------------------------------------- */ + + virtual int top(Node *n) { + Node *optionsnode = Getattr(Getattr(n, "module"), "options"); + if (optionsnode) { + if (Getattr(optionsnode, "directors")) { + allow_directors(); + } + if (Getattr(optionsnode, "dirprot")) { + allow_dirprot(); + } + allow_allprotected(GetFlag(optionsnode, "allprotected")); + } + + module = Getattr(n, "name"); + if (!package) { + package = Copy(module); + } + if (!soname && use_shlib) { + soname = Copy(package); + Append(soname, ".so"); + } + + if (gccgo_flag) { + String *pref; + if (pkgpath_option) { + pref = pkgpath_option; + } else { + pref = prefix_option; + } + go_prefix = NewString(""); + for (char *p = Char(pref); *p != '\0'; p++) { + if ((*p >= 'A' && *p <= 'Z') || (*p >= 'a' && *p <= 'z') || (*p >= '0' && *p <= '9') || *p == '.' || *p == '$') { + Putc(*p, go_prefix); + } else { + Putc('_', go_prefix); + } + } + if (!pkgpath_option) { + Append(go_prefix, "."); + Append(go_prefix, package); + } + } + + // Get filenames. + + String *swig_filename = Getattr(n, "infile"); + String *c_filename = Getattr(n, "outfile"); + String *c_filename_h = Getattr(n, "outfile_h"); + + String *go_filename = NewString(""); + Printf(go_filename, "%s%s.go", SWIG_output_directory(), module); + + String *gc_filename = NULL; + if (!gccgo_flag) { + gc_filename = NewString(""); + Printf(gc_filename, "%s%s_gc.c", SWIG_output_directory(), module); + } + + // Open files. + + f_c_begin = NewFile(c_filename, "w", SWIG_output_files()); + if (!f_c_begin) { + FileErrorDisplay(c_filename); + SWIG_exit(EXIT_FAILURE); + } + + if (directorsEnabled()) { + if (!c_filename_h) { + Printf(stderr, "Unable to determine outfile_h\n"); + SWIG_exit(EXIT_FAILURE); + } + f_c_directors_h = NewFile(c_filename_h, "w", SWIG_output_files()); + if (!f_c_directors_h) { + FileErrorDisplay(c_filename_h); + SWIG_exit(EXIT_FAILURE); + } + } + + f_go_begin = NewFile(go_filename, "w", SWIG_output_files()); + if (!f_go_begin) { + FileErrorDisplay(go_filename); + SWIG_exit(EXIT_FAILURE); + } + + if (!gccgo_flag) { + f_gc_begin = NewFile(gc_filename, "w", SWIG_output_files()); + if (!f_gc_begin) { + FileErrorDisplay(gc_filename); + SWIG_exit(EXIT_FAILURE); + } + } + + f_c_runtime = NewString(""); + f_c_header = NewString(""); + f_c_wrappers = NewString(""); + f_c_init = NewString(""); + f_c_directors = NewString(""); + f_go_imports = NewString(""); + f_go_runtime = NewString(""); + f_go_header = NewString(""); + f_go_wrappers = NewString(""); + if (!gccgo_flag) { + f_gc_runtime = NewString(""); + f_gc_header = NewString(""); + f_gc_wrappers = NewString(""); + } + + Swig_register_filebyname("begin", f_c_begin); + Swig_register_filebyname("runtime", f_c_runtime); + Swig_register_filebyname("header", f_c_header); + Swig_register_filebyname("wrapper", f_c_wrappers); + Swig_register_filebyname("init", f_c_init); + Swig_register_filebyname("director", f_c_directors); + Swig_register_filebyname("director_h", f_c_directors_h); + Swig_register_filebyname("go_begin", f_go_begin); + Swig_register_filebyname("go_imports", f_go_imports); + Swig_register_filebyname("go_runtime", f_go_runtime); + Swig_register_filebyname("go_header", f_go_header); + Swig_register_filebyname("go_wrapper", f_go_wrappers); + if (!gccgo_flag) { + Swig_register_filebyname("gc_begin", f_gc_begin); + Swig_register_filebyname("gc_runtime", f_gc_runtime); + Swig_register_filebyname("gc_header", f_gc_header); + Swig_register_filebyname("gc_wrapper", f_gc_wrappers); + } + + Swig_banner(f_c_begin); + if (CPlusPlus) { + Printf(f_c_begin, "\n// source: %s\n\n", swig_filename); + } else { + Printf(f_c_begin, "\n/* source: %s */\n\n", swig_filename); + } + + Printf(f_c_runtime, "#define SWIGMODULE %s\n", module); + if (gccgo_flag) { + Printf(f_c_runtime, "#define SWIGGO_PREFIX %s\n", go_prefix); + } + + if (directorsEnabled()) { + Printf(f_c_runtime, "#define SWIG_DIRECTORS\n"); + + Swig_banner(f_c_directors_h); + Printf(f_c_directors_h, "\n// source: %s\n\n", swig_filename); + + Printf(f_c_directors_h, "#ifndef SWIG_%s_WRAP_H_\n", module); + Printf(f_c_directors_h, "#define SWIG_%s_WRAP_H_\n\n", module); + + Printf(f_c_directors, "\n// C++ director class methods.\n"); + String *filename = Swig_file_filename(c_filename_h); + Printf(f_c_directors, "#include \"%s\"\n\n", filename); + Delete(filename); + } + + Swig_banner(f_go_begin); + Printf(f_go_begin, "\n// source: %s\n", swig_filename); + + if (!gccgo_flag && soname) { + Swig_banner(f_gc_begin); + Printf(f_gc_begin, "\n/* source: %s */\n\n", swig_filename); + Printf(f_gc_begin, "\n/* This file should be compiled with 6c/8c. */\n"); + Printf(f_gc_begin, "#pragma dynimport _ _ \"%s\"\n", soname); + } + + // Output module initialization code. + + Printf(f_go_begin, "\npackage %s\n\n", package); + + if (gccgo_flag) { + Printf(f_go_runtime, "func SwigCgocall()\n"); + Printf(f_go_runtime, "func SwigCgocallDone()\n"); + Printf(f_go_runtime, "func SwigCgocallBack()\n"); + Printf(f_go_runtime, "func SwigCgocallBackDone()\n\n"); + } + + // All the C++ wrappers should be extern "C". + + Printv(f_c_wrappers, "#ifdef __cplusplus\n", "extern \"C\" {\n", "#endif\n\n", NULL); + + // Set up the hash table for types not defined by SWIG. + + undefined_enum_types = NewHash(); + undefined_types = NewHash(); + defined_types = NewHash(); + go_imports = NewHash(); + + // Emit code. + + Language::top(n); + + Delete(go_imports); + + // Write out definitions for the types not defined by SWIG. + + if (Len(undefined_enum_types) > 0) + Printv(f_go_wrappers, "\n", NULL); + for (Iterator p = First(undefined_enum_types); p.key; p = Next(p)) { + String *name = p.item; + Printv(f_go_wrappers, "type ", name, " int\n", NULL); + } + + Printv(f_go_wrappers, "\n", NULL); + for (Iterator p = First(undefined_types); p.key; p = Next(p)) { + String *ty = goType(NULL, p.key); + if (!Getattr(defined_types, ty)) { + String *cp = goCPointerType(p.key, false); + if (!Getattr(defined_types, cp)) { + Printv(f_go_wrappers, "type ", cp, " uintptr\n", NULL); + Printv(f_go_wrappers, "type ", ty, " interface {\n", NULL); + Printv(f_go_wrappers, "\tSwigcptr() uintptr;\n", NULL); + Printv(f_go_wrappers, "}\n", NULL); + Printv(f_go_wrappers, "func (p ", cp, ") Swigcptr() uintptr {\n", NULL); + Printv(f_go_wrappers, "\treturn uintptr(p)\n", NULL); + Printv(f_go_wrappers, "}\n\n", NULL); + } + Delete(cp); + } + Delete(ty); + } + Delete(undefined_enum_types); + Delete(undefined_types); + Delete(defined_types); + + /* Write and cleanup */ + + Dump(f_c_header, f_c_runtime); + + if (directorsEnabled()) { + Printf(f_c_directors_h, "#endif\n"); + Delete(f_c_directors_h); + f_c_directors_h = NULL; + + Dump(f_c_directors, f_c_runtime); + Delete(f_c_directors); + f_c_directors = NULL; + } + + // End the extern "C". + Printv(f_c_wrappers, "#ifdef __cplusplus\n", "}\n", "#endif\n\n", NULL); + + Dump(f_c_runtime, f_c_begin); + Dump(f_c_wrappers, f_c_begin); + Dump(f_c_init, f_c_begin); + Dump(f_go_imports, f_go_begin); + Dump(f_go_header, f_go_begin); + Dump(f_go_runtime, f_go_begin); + Dump(f_go_wrappers, f_go_begin); + if (!gccgo_flag) { + Dump(f_gc_header, f_gc_begin); + Dump(f_gc_runtime, f_gc_begin); + Dump(f_gc_wrappers, f_gc_begin); + } + + Delete(f_c_runtime); + Delete(f_c_header); + Delete(f_c_wrappers); + Delete(f_c_init); + Delete(f_go_imports); + Delete(f_go_runtime); + Delete(f_go_header); + Delete(f_go_wrappers); + if (!gccgo_flag) { + Delete(f_gc_runtime); + Delete(f_gc_header); + Delete(f_gc_wrappers); + } + + Delete(f_c_begin); + Delete(f_go_begin); + if (!gccgo_flag) { + Delete(f_gc_begin); + } + + return SWIG_OK; + } + + /* ------------------------------------------------------------ + * importDirective() + * + * Handle a SWIG import statement by generating a Go import + * statement. + * ------------------------------------------------------------ */ + + virtual int importDirective(Node *n) { + String *hold_import = imported_package; + String *modname = Getattr(n, "module"); + if (modname) { + if (!Getattr(go_imports, modname)) { + Setattr(go_imports, modname, modname); + Printv(f_go_imports, "import \"", modname, "\"\n", NULL); + } + imported_package = modname; + saw_import = true; + } + int r = Language::importDirective(n); + imported_package = hold_import; + return r; + } + + /* ---------------------------------------------------------------------- + * Language::insertDirective() + * + * If the section is go_imports, store them for later. + * ---------------------------------------------------------------------- */ + virtual int insertDirective(Node *n) { + char *section = Char(Getattr(n, "section")); + if ((ImportMode && !Getattr(n, "generated")) || + !section || (strcmp(section, "go_imports") != 0)) { + return Language::insertDirective(n); + } + + char *code = Char(Getattr(n, "code")); + char *pch = strtok(code, ","); + while (pch != NULL) { + // Do not import same thing more than once. + if (!Getattr(go_imports, pch)) { + Setattr(go_imports, pch, pch); + Printv(f_go_imports, "import ", pch, "\n", NULL); + } + pch = strtok(NULL, ","); + } + return SWIG_OK; + } + + /* ---------------------------------------------------------------------- + * functionWrapper() + * + * Implement a function. + * ---------------------------------------------------------------------- */ + + virtual int functionWrapper(Node *n) { + if (GetFlag(n, "feature:ignore")) { + return SWIG_OK; + } + + // We don't need explicit calls. + if (GetFlag(n, "explicitcall")) { + return SWIG_OK; + } + + String *name = Getattr(n, "sym:name"); + String *nodetype = Getattr(n, "nodeType"); + bool is_static = is_static_member_function || isStatic(n); + bool is_friend = isFriend(n); + bool is_ctor_dtor = false; + + SwigType *result = Getattr(n, "type"); + + // For some reason SWIG changs the "type" value during the call to + // functionWrapper. We need to remember the type for possible + // overload processing. + Setattr(n, "go:type", Copy(result)); + + String *go_name; + + String *r1 = NULL; + if (making_variable_wrappers) { + // Change the name of the variable setter and getter functions + // to be more Go like. + + bool is_set = Strcmp(Char(name) + Len(name) - 4, "_set") == 0; + assert(is_set || Strcmp(Char(name) + Len(name) - 4, "_get") == 0); + + // Start with Set or Get. + go_name = NewString(is_set ? "Set" : "Get"); + + // If this is a static variable, put in the class name, + // capitalized. + if (is_static && class_name) { + String *ccn = exportedName(class_name); + Append(go_name, ccn); + Delete(ccn); + } + + // Add the rest of the name, capitalized, dropping the _set or + // _get. + String *c1 = removeClassname(name); + String *c2 = exportedName(c1); + char *p = Char(c2); + int len = Len(p); + for (int i = 0; i < len - 4; ++i) { + Putc(p[i], go_name); + } + Delete(c2); + Delete(c1); + + if (!checkIgnoredParameters(n, go_name)) { + Delete(go_name); + return SWIG_NOWRAP; + } + } else if (Cmp(nodetype, "constructor") == 0) { + is_ctor_dtor = true; + + // Change the name of a constructor to be more Go like. Change + // new_ to New, and capitalize the class name. + assert(Strncmp(name, "new_", 4) == 0); + String *c1 = NewString(Char(name) + 4); + String *c2 = exportedName(c1); + go_name = NewString("New"); + Append(go_name, c2); + Delete(c2); + Delete(c1); + + if (Swig_methodclass(n) && Swig_directorclass(n) + && Strcmp(Char(Getattr(n, "wrap:action")), director_prot_ctor_code) != 0) { + // The core SWIG code skips the first parameter when + // generating the $nondirector_new string. Recreate the + // action in this case. But don't it if we are using the + // special code for an abstract class. + String *call = Swig_cppconstructor_call(getClassType(), + Getattr(n, "parms")); + SwigType *type = Copy(getClassType()); + SwigType_add_pointer(type); + String *cres = Swig_cresult(type, Swig_cresult_name(), call); + Setattr(n, "wrap:action", cres); + } + } else if (Cmp(nodetype, "destructor") == 0) { + // No need to emit protected destructors. + if (!is_public(n)) { + return SWIG_OK; + } + + is_ctor_dtor = true; + + // Change the name of a destructor to be more Go like. Change + // delete_ to Delete and capitalize the class name. + assert(Strncmp(name, "delete_", 7) == 0); + String *c1 = NewString(Char(name) + 7); + String *c2 = exportedName(c1); + go_name = NewString("Delete"); + Append(go_name, c2); + Delete(c2); + Delete(c1); + + result = NewString("void"); + r1 = result; + } else { + if (!checkFunctionVisibility(n, NULL)) { + return SWIG_OK; + } + + go_name = buildGoName(name, is_static, is_friend); + + if (!checkIgnoredParameters(n, go_name)) { + Delete(go_name); + return SWIG_NOWRAP; + } + } + + String *overname = NULL; + if (Getattr(n, "sym:overloaded")) { + overname = Getattr(n, "sym:overname"); + } else { + String *scope; + if (!class_name || is_static || is_ctor_dtor) { + scope = NULL; + } else { + scope = NewString("swiggoscope."); + Append(scope, class_name); + } + if (!checkNameConflict(go_name, n, scope)) { + Delete(go_name); + return SWIG_NOWRAP; + } + } + + String *wname = Swig_name_wrapper(name); + if (overname) { + Append(wname, overname); + } + Setattr(n, "wrap:name", wname); + + ParmList *parms = Getattr(n, "parms"); + Setattr(n, "wrap:parms", parms); + + int r = makeWrappers(n, name, go_name, overname, wname, NULL, parms, result, is_static); + if (r != SWIG_OK) { + return r; + } + + if (Getattr(n, "sym:overloaded") && !Getattr(n, "sym:nextSibling")) { + String *scope ; + if (!class_name || is_static || is_ctor_dtor) { + scope = NULL; + } else { + scope = NewString("swiggoscope."); + Append(scope, class_name); + } + if (!checkNameConflict(go_name, n, scope)) { + Delete(go_name); + return SWIG_NOWRAP; + } + + String *receiver = class_receiver; + if (is_static || is_ctor_dtor) { + receiver = NULL; + } + r = makeDispatchFunction(n, go_name, receiver, is_static, NULL, false); + if (r != SWIG_OK) { + return r; + } + } + + Delete(wname); + Delete(go_name); + Delete(r1); + + return SWIG_OK; + } + + /* ---------------------------------------------------------------------- + * staticmemberfunctionHandler() + * + * For some reason the language code removes the "storage" attribute + * for a static function before calling functionWrapper, which means + * that we have no way of knowing whether a function is static or + * not. That makes no sense in the Go context. Here we note that a + * function is static. + * ---------------------------------------------------------------------- */ + + int staticmemberfunctionHandler(Node *n) { + assert(!is_static_member_function); + is_static_member_function = true; + int r = Language::staticmemberfunctionHandler(n); + is_static_member_function = false; + return r; + } + + /* ---------------------------------------------------------------------- + * makeWrappers() + * + * Write out the various function wrappers. + * n: The function we are emitting. + * name: The function name. + * go_name: The name of the function in Go. + * overname: The overload string for overloaded function. + * wname: The SWIG wrapped name--the name of the C function. + * base: A list of the names of base classes, in the case where this + * is is a vritual method not defined in the current class. + * parms: The parameters. + * result: The result type. + * is_static: Whether this is a static method or member. + * ---------------------------------------------------------------------- */ + + int makeWrappers(Node *n, String *name, String *go_name, String *overname, String *wname, List *base, ParmList *parms, SwigType *result, bool is_static) { + + assert(result); + + int r = goFunctionWrapper(n, name, go_name, overname, wname, base, parms, result, is_static); + if (r != SWIG_OK) { + return r; + } + + if (!gccgo_flag) { + r = gcFunctionWrapper(wname); + if (r != SWIG_OK) { + return r; + } + r = gccFunctionWrapper(n, base, wname, parms, result); + if (r != SWIG_OK) { + return r; + } + } else { + r = gccgoFunctionWrapper(n, base, wname, parms, result); + if (r != SWIG_OK) { + return r; + } + } + + if (class_methods) { + Setattr(class_methods, Getattr(n, "name"), NewString("")); + } + + return SWIG_OK; + } + + /* ---------------------------------------------------------------------- + * goFunctionWrapper() + * + * Write out a function wrapper in Go. When not implementing a + * method, the actual code is all in C; here we just declare the C + * function. When implementing a method, we have to call the C + * function, because it will have a different name. If base is not + * NULL, then we are being called to forward a virtual method to a + * base class. + * ---------------------------------------------------------------------- */ + + int goFunctionWrapper(Node *n, String *name, String *go_name, String *overname, String *wname, List *base, ParmList *parms, SwigType *result, bool is_static) { + Wrapper *dummy = NewWrapper(); + emit_attach_parmmaps(parms, dummy); + + Parm *p = parms; + int parm_count = emit_num_arguments(parms); + for (int i = 0; i < parm_count; ++i) { + p = getParm(p); + Swig_cparm_name(p, i); + p = nextParm(p); + } + + Swig_typemap_attach_parms("default", parms, dummy); + Swig_typemap_attach_parms("gotype", parms, dummy); + Swig_typemap_attach_parms("goin", parms, dummy); + Swig_typemap_attach_parms("goargout", parms, dummy); + Swig_typemap_attach_parms("imtype", parms, dummy); + + int required_count = emit_num_required(parms); + + String *receiver = class_receiver; + if (receiver && is_static) { + receiver = NULL; + } + + String *nodetype = Getattr(n, "nodeType"); + bool is_constructor = Cmp(nodetype, "constructor") == 0; + bool is_destructor = Cmp(nodetype, "destructor") == 0; + if (is_constructor || is_destructor) { + assert(class_receiver); + assert(!base); + receiver = NULL; + } + + String *goout = Swig_typemap_lookup("goout", n, "swig_r", NULL); + + bool add_to_interface = (interfaces && !is_constructor && !is_destructor && !is_static && !overname && checkFunctionVisibility(n, NULL)); + + bool needs_wrapper = (gccgo_flag || receiver || is_constructor || is_destructor || parm_count > required_count); + + bool has_goout = false; + if (goout) { + has_goout = true; + } + + // See whether any of the function parameters are represented by + // interface values. When calling the C++ code, we need to convert + // back to a uintptr. + p = parms; + for (int i = 0; i < parm_count; ++i) { + p = getParm(p); + String *ty = Getattr(p, "type"); + if (Getattr(p, "tmap:goargout")) { + has_goout = true; + needs_wrapper = true; + } else if (goTypeIsInterface(p, ty) || Getattr(p, "tmap:goin")) { + needs_wrapper = true; + } + p = nextParm(p); + } + if (goTypeIsInterface(n, result) || goout != NULL) { + needs_wrapper = true; + } + + if (!gccgo_flag) { + Printv(f_go_wrappers, "var ", wname, " unsafe.Pointer\n\n", NULL); + } + + // If this is a method, first declare the C function we will call. + // If we do not need a wrapper, then we will only be writing a + // declaration. + String *wrapper_name = NULL; + if (needs_wrapper) { + wrapper_name = buildGoWrapperName(name, overname); + + if (gccgo_flag) { + Printv(f_go_wrappers, "//extern ", go_prefix, "_", wname, "\n", NULL); + } + + bool arg = false; + Printv(f_go_wrappers, "func ", wrapper_name, "(", NULL); + if (parm_count > required_count) { + Printv(f_go_wrappers, argName(&arg), " int", NULL); + } + Parm *p = getParm(parms); + int i = 0; + if (is_destructor) { + if (parm_count > required_count) { + Printv(f_go_wrappers, ", ", NULL); + } + Printv(f_go_wrappers, argName(&arg), " uintptr", NULL); + ++i; + p = nextParm(p); + } else if (receiver && (base || !is_constructor)) { + if (parm_count > required_count) { + Printv(f_go_wrappers, ", ", NULL); + } + Printv(f_go_wrappers, argName(&arg), " ", receiver, NULL); + if (!base) { + ++i; + p = nextParm(p); + } + } + for (; i < parm_count; ++i) { + p = getParm(p); + if (i > 0 || (base && receiver) || parm_count > required_count) { + Printv(f_go_wrappers, ", ", NULL); + } + String *tm = goWrapperType(p, Getattr(p, "type"), false); + Printv(f_go_wrappers, argName(&arg), " ", tm, NULL); + Delete(tm); + p = nextParm(p); + } + Printv(f_go_wrappers, ")", NULL); + if (is_constructor) { + Printv(f_go_wrappers, " (", argName(&arg), " ", class_receiver, ")", NULL); + } else { + if (SwigType_type(result) != T_VOID) { + String *tm = goWrapperType(n, result, true); + Printv(f_go_wrappers, " (", argName(&arg), " ", tm, ")", NULL); + Delete(tm); + } + } + + if (!gccgo_flag) { + Printv(f_go_wrappers, " {\n", NULL); + if (arg) { + Printv(f_go_wrappers, "\t_swig_p := uintptr(unsafe.Pointer(&base))\n", NULL); + } else { + Printv(f_go_wrappers, "\tvar _swig_p uintptr\n", NULL); + } + Printv(f_go_wrappers, "\t_cgo_runtime_cgocall(", wname, ", _swig_p)\n", NULL); + Printv(f_go_wrappers, "\treturn\n", NULL); + Printv(f_go_wrappers, "}", NULL); + } + + Printv(f_go_wrappers, "\n\n", NULL); + } + + // Start defining the Go function. + + if (!needs_wrapper && gccgo_flag) { + Printv(f_go_wrappers, "//extern ", go_prefix, "_", wname, "\n", NULL); + } + + Printv(f_go_wrappers, "func ", NULL); + + p = parms; + int pi = 0; + + // Add the receiver if this is a method. + String *first = NULL; + if (receiver) { + Printv(f_go_wrappers, "(", NULL); + if (base && receiver) { + Printv(f_go_wrappers, "_swig_base", NULL); + if (first == NULL) { + first = NewString("_swig_base"); + } + } else { + Printv(f_go_wrappers, Getattr(p, "lname"), NULL); + if (first == NULL) { + first = Copy(Getattr(p, "lname")); + } + p = nextParm(p); + ++pi; + } + Printv(f_go_wrappers, " ", receiver, ") ", NULL); + } + + Printv(f_go_wrappers, go_name, NULL); + if (overname) { + Printv(f_go_wrappers, overname, NULL); + } + Printv(f_go_wrappers, "(", NULL); + + // If we are doing methods, add this function to the interface. + if (add_to_interface) { + Printv(interfaces, "\t", go_name, "(", NULL); + } + + // Write out the parameters to both the function definition and + // the interface. + + String *parm_print = NewString(""); + + for (; pi < parm_count; ++pi) { + p = getParm(p); + if (pi == 0 && is_destructor) { + String *cl = exportedName(class_name); + Printv(parm_print, Getattr(p, "lname"), " ", cl, NULL); + if (first == NULL) { + first = Copy(Getattr(p, "lname")); + } + Delete(cl); + } else { + if (pi > (receiver && !base ? 1 : 0)) { + Printv(parm_print, ", ", NULL); + } + if (pi >= required_count) { + Printv(parm_print, "_swig_args ...interface{}", NULL); + if (first == NULL) { + first = NewString("_swig_args"); + } + break; + } + Printv(parm_print, Getattr(p, "lname"), " ", NULL); + if (first == NULL) { + first = Copy(Getattr(p, "lname")); + } + String *tm = goType(p, Getattr(p, "type")); + Printv(parm_print, tm, NULL); + Delete(tm); + } + p = nextParm(p); + } + + Printv(parm_print, ")", NULL); + + // Write out the result type. + if (is_constructor) { + String *cl = exportedName(class_name); + Printv(parm_print, " (_swig_ret ", cl, ")", NULL); + if (first == NULL) { + first = NewString("_swig_ret"); + } + Delete(cl); + } else { + if (SwigType_type(result) != T_VOID) { + String *tm = goType(n, result); + Printv(parm_print, " (_swig_ret ", tm, ")", NULL); + if (first == NULL) { + first = NewString("_swig_ret"); + } + Delete(tm); + } + } + + Printv(f_go_wrappers, parm_print, NULL); + if (add_to_interface) { + Printv(interfaces, parm_print, "\n", NULL); + } + + // If this is a wrapper, we need to actually call the C function. + if (needs_wrapper) { + Printv(f_go_wrappers, " {\n", NULL); + + if (parm_count > required_count) { + Parm *p = parms; + int i; + for (i = 0; i < required_count; ++i) { + p = getParm(p); + p = nextParm(p); + } + for (; i < parm_count; ++i) { + p = getParm(p); + String *tm = goType(p, Getattr(p, "type")); + Printv(f_go_wrappers, "\tvar ", Getattr(p, "lname"), " ", tm, "\n", NULL); + Printf(f_go_wrappers, "\tif len(_swig_args) > %d {\n", i - required_count); + Printf(f_go_wrappers, "\t\t%s = _swig_args[%d].(%s)\n", Getattr(p, "lname"), i - required_count, tm); + Printv(f_go_wrappers, "\t}\n", NULL); + Delete(tm); + p = nextParm(p); + } + } + + String *call = NewString(""); + + bool need_return_var = SwigType_type(result) != T_VOID && ((gccgo_flag && is_constructor) || has_goout); + if (need_return_var) { + Printv(f_go_wrappers, "\tvar swig_r ", NULL); + if (is_constructor) { + String *cl = exportedName(class_name); + Printv(f_go_wrappers, cl, NULL); + Delete(cl); + } else { + Printv(f_go_wrappers, goImType(n, result), NULL); + } + Printv(f_go_wrappers, "\n", NULL); + } + + if (gccgo_flag) { + if (has_goout || is_constructor) { + Printv(call, "\tfunc() {\n", NULL); + } + Printv(call, "\tdefer SwigCgocallDone()\n", NULL); + Printv(call, "\tSwigCgocall()\n", NULL); + } + + Printv(call, "\t", NULL); + if (SwigType_type(result) != T_VOID) { + if (need_return_var) { + Printv(call, "swig_r = ", NULL); + } else { + Printv(call, "return ", NULL); + } + } + + Printv(call, wrapper_name, "(", NULL); + + if (parm_count > required_count) { + Printv(call, "len(_swig_args)", NULL); + } + + if (base && receiver) { + if (parm_count > required_count) { + Printv(call, ", ", NULL); + } + Printv(call, "_swig_base", NULL); + } + + Parm *p = parms; + for (int i = 0; i < parm_count; ++i) { + p = getParm(p); + if (i > 0 || (base && receiver) + || parm_count > required_count) { + Printv(call, ", ", NULL); + } + + SwigType *pt = Getattr(p, "type"); + String *ln = Getattr(p, "lname"); + + String *goin = Getattr(p, "tmap:goin"); + if (goin == NULL) { + Printv(call, ln, NULL); + if ((i == 0 && is_destructor) || ((i > 0 || !receiver || base || is_constructor) && goTypeIsInterface(p, pt))) { + Printv(call, ".Swigcptr()", NULL); + } + Setattr(p, "emit:goinput", ln); + } else { + String *ivar = NewString(""); + Printf(ivar, "_swig_i_%d", i); + String *itm = goImType(p, pt); + Printv(f_go_wrappers, "\tvar ", ivar, " ", itm, NULL); + goin = Copy(goin); + Replaceall(goin, "$input", ln); + Replaceall(goin, "$result", ivar); + Printv(f_go_wrappers, goin, NULL); + Delete(goin); + Printv(call, ivar, NULL); + Setattr(p, "emit:goinput", ivar); + } + + p = nextParm(p); + } + Printv(call, ")\n", NULL); + + if (gccgo_flag && (has_goout || is_constructor)) { + Printv(call, "\t}()\n", NULL); + } + + Printv(f_go_wrappers, call, NULL); + Delete(call); + + goargout(parms, parm_count); + + if (need_return_var) { + if (goout == NULL) { + Printv(f_go_wrappers, "\treturn swig_r\n", NULL); + } else { + String *tm = goType(n, result); + Printv(f_go_wrappers, "\tvar swig_r_1 ", tm, "\n", NULL); + Replaceall(goout, "$input", "swig_r"); + Replaceall(goout, "$result", "swig_r_1"); + Printv(f_go_wrappers, goout, NULL); + Printv(f_go_wrappers, "\treturn swig_r_1\n", NULL); + } + } + + Printv(f_go_wrappers, "}\n", NULL); + } else if (!gccgo_flag) { + // We don't need a wrapper. If we're using gccgo, the function + // declaration is all we need--it has a //extern comment to + // GCC-compiled wrapper. If we're not using gccgo, we need to + // call the GCC-compiled wrapper here. + Printv(f_go_wrappers, " {\n", NULL); + if (first == NULL) { + Printv(f_go_wrappers, "\tvar _swig_p uintptr\n", NULL); + } else { + Printv(f_go_wrappers, "\t_swig_p := uintptr(unsafe.Pointer(&", first, "))\n", NULL); + } + Printv(f_go_wrappers, "\t_cgo_runtime_cgocall(", wname, ", _swig_p)\n", NULL); + Printv(f_go_wrappers, "\treturn\n", NULL); + Printv(f_go_wrappers, "}", NULL); + } + + Printv(f_go_wrappers, "\n", NULL); + + Delete(wrapper_name); + DelWrapper(dummy); + + return SWIG_OK; + } + + /* ---------------------------------------------------------------------- + * argName() + * + * A helper for goFunctionWrapper to output the first argument name + * as "base" and all others as "_". + * ---------------------------------------------------------------------- */ + + const char *argName(bool *arg) { + if (*arg) { + return "_"; + } + *arg = true; + return "base"; + } + + /* ---------------------------------------------------------------------- + * gcFunctionWrapper() + * + * This is used for 6g/8g, not for gccgo. Write out the function + * redirector that will be compiled with 6c/8c. This used to write + * out a real function wrapper, but that has moved into Go code. + * ---------------------------------------------------------------------- */ + + int gcFunctionWrapper(String *wname) { + Wrapper *f = NewWrapper(); + + Printv(f->def, "#pragma dynimport ", wname, " ", wname, " \"\"\n", NULL); + Printv(f->def, "#pragma cgo_import_static ", wname, "\n", NULL); + Printv(f->def, "extern void ", wname, "(void*);\n", NULL); + // Declare this as a uintptr, since it is not a pointer into the + // Go heap. + // \xc2\xb7 is UTF-8 for U+00B7 which is Unicode 'Middle Dot' + Printv(f->def, "uintptr \xc2\xb7", wname, " = (uintptr)", wname, ";\n", NULL); + + Wrapper_print(f, f_gc_wrappers); + + DelWrapper(f); + + return SWIG_OK; + } + + /* ---------------------------------------------------------------------- + * gccFunctionWrapper() + * + * This is used for 6g/8g, not for gccgo. Write out the function + * wrapper which will be compiled with gcc. If the base parameter + * is not NULL, this is calls the base class method rather than + * executing the SWIG wrapper code. + * ---------------------------------------------------------------------- */ + + int gccFunctionWrapper(Node *n, List *base, String *wname, ParmList *parms, SwigType *result) { + Wrapper *f = NewWrapper(); + + Swig_save("gccFunctionWrapper", n, "parms", NULL); + + Parm *base_parm = NULL; + if (base && !isStatic(n)) { + SwigType *base_type = Copy(getClassType()); + SwigType_add_pointer(base_type); + base_parm = NewParm(base_type, NewString("arg1"), n); + set_nextSibling(base_parm, parms); + parms = base_parm; + } + + emit_parameter_variables(parms, f); + emit_attach_parmmaps(parms, f); + int parm_count = emit_num_arguments(parms); + int required_count = emit_num_required(parms); + + emit_return_variable(n, result, f); + + // Start the function definition. + + Printv(f->def, "void\n", wname, "(void *swig_v)\n", "{\n", NULL); + + // The single function parameter is a pointer to the real argument + // values. Define the structure that it points to. + + Printv(f->code, "\tstruct swigargs {\n", NULL); + + if (parm_count > required_count) { + Printv(f->code, "\t\tintgo _swig_optargc;\n", NULL); + } + + Parm *p = parms; + for (int i = 0; i < parm_count; ++i) { + p = getParm(p); + String *ln = Getattr(p, "lname"); + SwigType *pt = Getattr(p, "type"); + String *ct = gcCTypeForGoValue(p, pt, ln); + Printv(f->code, "\t\t\t", ct, ";\n", NULL); + Delete(ct); + p = nextParm(p); + } + if (SwigType_type(result) != T_VOID) { + Printv(f->code, "\t\tlong : 0;\n", NULL); + String *ln = NewString(Swig_cresult_name()); + String *ct = gcCTypeForGoValue(n, result, ln); + Delete(ln); + Printv(f->code, "\t\t", ct, ";\n", NULL); + Delete(ct); + + ln = NewString("_swig_go_result"); + ct = gcCTypeForGoValue(n, result, ln); + Wrapper_add_local(f, "_swig_go_result", ct); + Delete(ct); + Delete(ln); + } + Printv(f->code, "\t} *swig_a = (struct swigargs *) swig_v;\n", NULL); + + Printv(f->code, "\n", NULL); + + // Copy the input arguments out of the structure into the + // parameter variables. + + p = parms; + for (int i = 0; i < parm_count; ++i) { + p = getParm(p); + + String *tm = Getattr(p, "tmap:in"); + if (!tm) { + Swig_warning(WARN_TYPEMAP_IN_UNDEF, input_file, line_number, "Unable to use type %s as a function argument\n", SwigType_str(Getattr(p, "type"), 0)); + } else { + String *ln = Getattr(p, "lname"); + String *input = NewString(""); + Printv(input, "swig_a->", ln, NULL); + tm = Copy(tm); + Replaceall(tm, "$input", input); + Setattr(p, "emit:input", input); + if (i < required_count) { + Printv(f->code, "\t", tm, "\n", NULL); + } else { + Printf(f->code, "\tif (swig_a->_swig_optargc > %d) {\n", i - required_count); + Printv(f->code, "\t\t", tm, "\n", NULL); + Printv(f->code, "\t}\n", NULL); + } + Delete(tm); + } + p = nextParm(p); + } + + Printv(f->code, "\n", NULL); + + // Do the real work of the function. + + checkConstraints(parms, f); + + emitGoAction(n, base, parms, result, f); + + argout(parms, f); + + cleanupFunction(n, f, parms); + + Printv(f->code, "}\n", NULL); + + Wrapper_print(f, f_c_wrappers); + + Swig_restore(n); + + DelWrapper(f); + Delete(base_parm); + + return SWIG_OK; + } + + /* ---------------------------------------------------------------------- + * gccgoFunctionWrapper() + * + * This is used for gccgo, not 6g/8g. Write out the function + * wrapper which will be compiled with gcc. If the base parameter + * is not NULL, this is calls the base class method rather than + * executing the SWIG wrapper code. + * ---------------------------------------------------------------------- */ + + int gccgoFunctionWrapper(Node *n, List *base, String *wname, ParmList *parms, SwigType *result) { + Wrapper *f = NewWrapper(); + + Swig_save("gccgoFunctionWrapper", n, "parms", NULL); + + Parm *base_parm = NULL; + if (base && !isStatic(n)) { + SwigType *base_type = Copy(getClassType()); + SwigType_add_pointer(base_type); + base_parm = NewParm(base_type, NewString("arg1"), n); + set_nextSibling(base_parm, parms); + parms = base_parm; + } + + emit_parameter_variables(parms, f); + emit_attach_parmmaps(parms, f); + int parm_count = emit_num_arguments(parms); + int required_count = emit_num_required(parms); + + emit_return_variable(n, result, f); + + // Start the function definition. + + String *fnname = NewString(""); + Printv(fnname, "go_", wname, "(", NULL); + + if (parm_count > required_count) { + Printv(fnname, "intgo _swig_optargc", NULL); + } + + Parm *p = parms; + for (int i = 0; i < parm_count; ++i) { + p = getParm(p); + SwigType *pt = Copy(Getattr(p, "type")); + if (SwigType_isarray(pt)) { + SwigType_del_array(pt); + SwigType_add_pointer(pt); + } + String *pn = NewString("g"); + Append(pn, Getattr(p, "lname")); + String *ct = gccgoCTypeForGoValue(p, pt, pn); + if (i > 0 || parm_count > required_count) { + Printv(fnname, ", ", NULL); + } + Printv(fnname, ct, NULL); + Delete(ct); + Delete(pn); + Delete(pt); + p = nextParm(p); + } + + Printv(fnname, ")", NULL); + + String *fndef = NewString(""); + if (SwigType_type(result) == T_VOID) { + Printv(fndef, "void ", fnname, NULL); + } else { + String *ct = gccgoCTypeForGoValue(n, result, fnname); + Printv(fndef, ct, NULL); + Delete(ct); + } + + Printv(f->def, fndef, " __asm__(\"", go_prefix, "_", wname, "\");\n", NULL); + + Printv(f->def, fndef, " {\n", NULL); + + Delete(fnname); + Delete(fndef); + + if (SwigType_type(result) != T_VOID) { + String *ln = NewString("_swig_go_result"); + String *ct = gccgoCTypeForGoValue(n, result, ln); + Wrapper_add_local(f, "_swig_go_result", ct); + Delete(ct); + Delete(ln); + } + + // Copy the parameters into the variables which hold their values, + // applying appropriate transformations. + + p = parms; + for (int i = 0; i < parm_count; ++i) { + p = getParm(p); + + String *tm = Getattr(p, "tmap:in"); + if (!tm) { + Swig_warning(WARN_TYPEMAP_IN_UNDEF, input_file, line_number, + "Unable to use type %s as a function argument\n", SwigType_str(Getattr(p, "type"), 0)); + } else { + String *ln = Getattr(p, "lname"); + String *pn = NewString("g"); + Append(pn, ln); + tm = Copy(tm); + Replaceall(tm, "$input", pn); + Setattr(p, "emit:input", pn); + if (i < required_count) { + Printv(f->code, " ", tm, "\n", NULL); + } else { + Printf(f->code, " if (_swig_optargc > %d) {\n", i - required_count); + Printv(f->code, " ", tm, "\n", NULL); + Printv(f->code, " }\n", NULL); + } + Delete(tm); + } + + p = nextParm(p); + } + + Printv(f->code, "\n", NULL); + + // Do the real work of the function. + + checkConstraints(parms, f); + + emitGoAction(n, base, parms, result, f); + + argout(parms, f); + + cleanupFunction(n, f, parms); + + if (SwigType_type(result) != T_VOID) { + Printv(f->code, " return _swig_go_result;\n", NULL); + } + + Printv(f->code, "}\n", NULL); + + Wrapper_print(f, f_c_wrappers); + + Swig_restore(n); + + DelWrapper(f); + Delete(base_parm); + + return SWIG_OK; + } + + /* ----------------------------------------------------------------------- + * checkConstraints() + * + * Check parameter constraints if any. This is used for the C/C++ + * function. This assumes that each parameter has an "emit:input" + * property with the name to use to refer to that parameter. + * ----------------------------------------------------------------------- */ + + void checkConstraints(ParmList *parms, Wrapper *f) { + Parm *p = parms; + while (p) { + String *tm = Getattr(p, "tmap:check"); + if (!tm) { + p = nextSibling(p); + } else { + tm = Copy(tm); + Replaceall(tm, "$input", Getattr(p, "emit:input")); + Printv(f->code, tm, "\n\n", NULL); + Delete(tm); + p = Getattr(p, "tmap:check:next"); + } + } + } + + /* ----------------------------------------------------------------------- + * emitGoAction() + * + * Emit the action of the function. This is used for the C/C++ function. + * ----------------------------------------------------------------------- */ + + void emitGoAction(Node *n, List *base, ParmList *parms, SwigType *result, Wrapper *f) { + if (!gccgo_flag && SwigType_type(result) != T_VOID) { + Wrapper_add_local(f, "swig_stktop", "char *swig_stktop"); + Printv(f->code, "\tswig_stktop = _swig_topofstack();\n", NULL); + } + String *actioncode; + if (!base || isStatic(n)) { + Swig_director_emit_dynamic_cast(n, f); + actioncode = emit_action(n); + } else { + // Call the base class method. + actioncode = NewString(""); + + String *current = NewString(""); + if (!gccgo_flag) { + Printv(current, "swig_a->", NULL); + } + Printv(current, Getattr(parms, "lname"), NULL); + + int vc = 0; + for (Iterator bi = First(base); bi.item; bi = Next(bi)) { + Printf(actioncode, " %s *swig_b%d = (%s *)%s;\n", bi.item, vc, bi.item, current); + Delete(current); + current = NewString(""); + Printf(current, "swig_b%d", vc); + ++vc; + } + + String *code = Copy(Getattr(n, "wrap:action")); + Replaceall(code, Getattr(parms, "lname"), current); + Printv(actioncode, code, "\n", NULL); + } + + Swig_save("emitGoAction", n, "type", "tmap:out", NULL); + + Setattr(n, "type", result); + + String *tm = Swig_typemap_lookup_out("out", n, Swig_cresult_name(), f, actioncode); + if (!tm) { + Swig_warning(WARN_TYPEMAP_OUT_UNDEF, input_file, line_number, "Unable to use return type %s\n", SwigType_str(result, 0)); + } else { + Replaceall(tm, "$result", "_swig_go_result"); + if (GetFlag(n, "feature:new")) { + Replaceall(tm, "$owner", "1"); + } else { + Replaceall(tm, "$owner", "0"); + } + Printv(f->code, tm, "\n", NULL); + Delete(tm); + } + + if (!gccgo_flag && SwigType_type(result) != T_VOID) { + // If the function called back into the Go code, the stack might + // have been copied. We need to adjust swig_a accordingly here. + // This is what cgo does. + Printv(f->code, "\tswig_a = (struct swigargs*)((char*)swig_a + (_swig_topofstack() - swig_stktop));\n", NULL); + Printv(f->code, "\tswig_a->", Swig_cresult_name(), " = ", "_swig_go_result;\n", NULL); + } + + Swig_restore(n); + } + + /* ----------------------------------------------------------------------- + * argout() + * + * Handle argument output code if any. This is used for the C/C++ + * function. This assumes that each parameter has an "emit:input" + * property with the name to use to refer to that parameter. + * ----------------------------------------------------------------------- */ + + void argout(ParmList *parms, Wrapper *f) { + Parm *p = parms; + while (p) { + String *tm = Getattr(p, "tmap:argout"); + if (!tm) { + p = nextSibling(p); + } else { + tm = Copy(tm); + Replaceall(tm, "$result", Swig_cresult_name()); + Replaceall(tm, "$input", Getattr(p, "emit:input")); + Printv(f->code, tm, "\n", NULL); + Delete(tm); + p = Getattr(p, "tmap:argout:next"); + } + } + } + + /* ----------------------------------------------------------------------- + * goargout() + * + * Handle Go argument output code if any. This is used for the Go + * function. This assumes that each parameter has an "emit:goinput" + * property with the name to use to refer to that parameter. + * ----------------------------------------------------------------------- */ + + void goargout(ParmList *parms, int parm_count) { + Parm *p = parms; + for (int i = 0; i < parm_count; ++i) { + p = getParm(p); + String *tm = Getattr(p, "tmap:goargout"); + if (!tm) { + p = nextSibling(p); + } else { + tm = Copy(tm); + Replaceall(tm, "$result", "swig_r"); + Replaceall(tm, "$input", Getattr(p, "emit:goinput")); + Printv(f_go_wrappers, tm, NULL); + Delete(tm); + p = Getattr(p, "tmap:goargout:next"); + } + } + } + + /* ----------------------------------------------------------------------- + * freearg() + * + * Handle argument cleanup code if any. This is used for the C/C++ + * function. This assumes that each parameter has an "emit:input" + * property with the name to use to refer to that parameter. + * ----------------------------------------------------------------------- */ + + String *freearg(ParmList *parms) { + String *ret = NewString(""); + Parm *p = parms; + while (p) { + String *tm = Getattr(p, "tmap:freearg"); + if (!tm) { + p = nextSibling(p); + } else { + tm = Copy(tm); + Replaceall(tm, "$input", Getattr(p, "emit:input")); + Printv(ret, tm, "\n", NULL); + Delete(tm); + p = Getattr(p, "tmap:freearg:next"); + } + } + return ret; + } + + /* ----------------------------------------------------------------------- + * cleanupFunction() + * + * Final function cleanup code. + * ----------------------------------------------------------------------- */ + + void cleanupFunction(Node *n, Wrapper *f, ParmList *parms) { + String *cleanup = freearg(parms); + Printv(f->code, cleanup, NULL); + + if (GetFlag(n, "feature:new")) { + String *tm = Swig_typemap_lookup("newfree", n, Swig_cresult_name(), 0); + if (tm) { + Replaceall(tm, "$source", Swig_cresult_name()); + Printv(f->code, tm, "\n", NULL); + Delete(tm); + } + } + + Replaceall(f->code, "$cleanup", cleanup); + Delete(cleanup); + + Replaceall(f->code, "$symname", Getattr(n, "sym:name")); + } + + /* ----------------------------------------------------------------------- + * variableHandler() + * + * This exists just to set the making_variable_wrappers flag. + * ----------------------------------------------------------------------- */ + + virtual int variableHandler(Node *n) { + assert(!making_variable_wrappers); + making_variable_wrappers = true; + int r = Language::variableHandler(n); + making_variable_wrappers = false; + return r; + } + + /* ----------------------------------------------------------------------- + * constantWrapper() + * + * Product a const declaration. + * ------------------------------------------------------------------------ */ + + virtual int constantWrapper(Node *n) { + SwigType *type = Getattr(n, "type"); + + if (!SwigType_issimple(type) && SwigType_type(type) != T_STRING) { + return goComplexConstant(n, type); + } + + if (Swig_storage_isstatic(n)) { + return goComplexConstant(n, type); + } + + String *go_name = buildGoName(Getattr(n, "sym:name"), false, false); + + String *tm = goType(n, type); + String *value = Getattr(n, "value"); + + String *copy = NULL; + if (SwigType_type(type) == T_BOOL) { + if (Cmp(value, "true") != 0 && Cmp(value, "false") != 0) { + return goComplexConstant(n, type); + } + } else if (SwigType_type(type) == T_STRING || SwigType_type(type) == T_CHAR) { + // Backslash sequences are somewhat different in Go and C/C++. + if (Strchr(value, '\\') != 0) { + return goComplexConstant(n, type); + } + } else { + // Accept a 0x prefix, and strip combinations of u and l + // suffixes. Otherwise accept digits, decimal point, and + // exponentiation. Treat anything else as too complicated to + // handle as a Go constant. + char *p = Char(value); + int len = strlen(p); + bool need_copy = false; + while (len > 0) { + char c = p[len - 1]; + if (c != 'l' && c != 'L' && c != 'u' && c != 'U') { + break; + } + --len; + need_copy = true; + } + bool is_hex = false; + int i = 0; + if (p[0] == '0' && (p[1] == 'x' || p[1] == 'X')) { + i = 2; + is_hex = true; + } + for (; i < len; ++i) { + switch (p[i]) { + case '0': case '1': case '2': case '3': case '4': case '5': case '6': case '7': case '8': case '9': + break; + case 'a': case 'b': case 'c': case 'd': case 'f': case 'A': case 'B': case 'C': case 'D': case 'F': + if (!is_hex) { + return goComplexConstant(n, type); + } + break; + case '.': case 'e': case 'E': case '+': case '-': + break; + default: + return goComplexConstant(n, type); + } + } + if (need_copy) { + copy = Copy(value); + Replaceall(copy, p + len, ""); + value = copy; + } + } + + if (!checkNameConflict(go_name, n, NULL)) { + Delete(tm); + Delete(go_name); + Delete(copy); + return SWIG_NOWRAP; + } + + Printv(f_go_wrappers, "const ", go_name, " ", tm, " = ", NULL); + if (SwigType_type(type) == T_STRING) { + Printv(f_go_wrappers, "\"", value, "\"", NULL); + } else if (SwigType_type(type) == T_CHAR) { + Printv(f_go_wrappers, "'", value, "'", NULL); + } else { + Printv(f_go_wrappers, value, NULL); + } + + Printv(f_go_wrappers, "\n", NULL); + + Delete(tm); + Delete(go_name); + Delete(copy); + + return SWIG_OK; + } + + /* ---------------------------------------------------------------------- + * enumDeclaration() + * + * A C++ enum type turns into a Named go int type. + * ---------------------------------------------------------------------- */ + + virtual int enumDeclaration(Node *n) { + String *name = goEnumName(n); + if (Strcmp(name, "int") != 0) { + if (!ImportMode || !imported_package) { + if (!checkNameConflict(name, n, NULL)) { + Delete(name); + return SWIG_NOWRAP; + } + Printv(f_go_wrappers, "type ", name, " int\n", NULL); + } else { + String *nw = NewString(""); + Printv(nw, imported_package, ".", name, NULL); + Setattr(n, "go:enumname", nw); + } + } + Delete(name); + + return Language::enumDeclaration(n); + } + + /* ----------------------------------------------------------------------- + * enumvalueDeclaration() + * + * Declare a single value of an enum type. We fetch the value by + * calling a C/C++ function. + * ------------------------------------------------------------------------ */ + + virtual int enumvalueDeclaration(Node *n) { + if (!is_public(n)) { + return SWIG_OK; + } + if (Getattr(parentNode(n), "unnamed")) { + Setattr(n, "type", NewString("int")); + } else { + Setattr(n, "type", Getattr(parentNode(n), "enumtype")); + } + return goComplexConstant(n, Getattr(n, "type")); + } + + /* ----------------------------------------------------------------------- + * goComplexConstant() + * + * Handle a const declaration for something which is not a Go constant. + * ------------------------------------------------------------------------ */ + + int goComplexConstant(Node *n, SwigType *type) { + String *symname = Getattr(n, "sym:name"); + if (!symname) { + symname = Getattr(n, "name"); + } + + String *varname = buildGoName(symname, true, false); + + if (!checkNameConflict(varname, n, NULL)) { + Delete(varname); + return SWIG_NOWRAP; + } + + String *get = NewString(""); + Printv(get, Swig_cresult_name(), " = ", NULL); + + char quote; + if (Getattr(n, "wrappedasconstant")) { + quote = '\0'; + } else if (SwigType_type(type) == T_CHAR) { + quote = '\''; + } else if (SwigType_type(type) == T_STRING) { + quote = '"'; + } else { + quote = '\0'; + } + + if (quote != '\0') { + Printf(get, "%c", quote); + } + + Printv(get, Getattr(n, "value"), NULL); + + if (quote != '\0') { + Printf(get, "%c", quote); + } + + Printv(get, ";\n", NULL); + Setattr(n, "wrap:action", get); + + String *sname = Copy(symname); + if (class_name) { + Append(sname, "_"); + Append(sname, class_name); + } + + String *go_name = NewString("_swig_get"); + if (class_name) { + Append(go_name, class_name); + Append(go_name, "_"); + } + Append(go_name, sname); + + String *wname = Swig_name_wrapper(sname); + Setattr(n, "wrap:name", wname); + + int r = makeWrappers(n, sname, go_name, NULL, wname, NULL, NULL, type, true); + + if (r != SWIG_OK) { + return r; + } + + String *t = goType(n, type); + Printv(f_go_wrappers, "var ", varname, " ", t, " = ", go_name, "()\n", NULL); + + Delete(varname); + Delete(t); + Delete(go_name); + Delete(sname); + + return SWIG_OK; + } + + /* ------------------------------------------------------------ + * classHandler() + * + * For a C++ class, in Go we generate both a struct and an + * interface. The interface will declare all the class public + * methods. We will define all the methods on the struct, so that + * the struct meets the interface. We then expect users of the + * class to use the interface. + * ------------------------------------------------------------ */ + + virtual int classHandler(Node *n) { + class_node = n; + + List *baselist = Getattr(n, "bases"); + bool has_base_classes = baselist && Len(baselist) > 0; + + String *name = Getattr(n, "sym:name"); + + String *go_name = exportedName(name); + + if (!checkNameConflict(go_name, n, NULL)) { + Delete(go_name); + SetFlag(n, "go:conflict"); + return SWIG_NOWRAP; + } + + String *go_type_name = goCPointerType(Getattr(n, "classtypeobj"), true); + + class_name = name; + class_receiver = go_type_name; + class_methods = NewHash(); + + int isdir = GetFlag(n, "feature:director"); + int isnodir = GetFlag(n, "feature:nodirector"); + bool is_director = isdir && !isnodir; + + Printv(f_go_wrappers, "type ", go_type_name, " uintptr\n\n", NULL); + + // A method to return the pointer to the C++ class. This is used + // by generated code to convert between the interface and the C++ + // value. + Printv(f_go_wrappers, "func (p ", go_type_name, ") Swigcptr() uintptr {\n", NULL); + Printv(f_go_wrappers, "\treturn (uintptr)(p)\n", NULL); + Printv(f_go_wrappers, "}\n\n", NULL); + + // A method used as a marker for the class, to avoid invalid + // interface conversions when using multiple inheritance. + Printv(f_go_wrappers, "func (p ", go_type_name, ") SwigIs", go_name, "() {\n", NULL); + Printv(f_go_wrappers, "}\n\n", NULL); + + if (is_director) { + // Return the interface passed to the NewDirector function. + Printv(f_go_wrappers, "func (p ", go_type_name, ") DirectorInterface() interface{} {\n", NULL); + Printv(f_go_wrappers, "\treturn nil\n", NULL); + Printv(f_go_wrappers, "}\n\n", NULL); + } + + // We have seen a definition for this type. + Setattr(defined_types, go_name, go_name); + Setattr(defined_types, go_type_name, go_type_name); + + interfaces = NewString(""); + + int r = Language::classHandler(n); + if (r != SWIG_OK) { + return r; + } + + if (has_base_classes) { + // For each method defined in a base class but not defined in + // this class, we need to define the method in this class. We + // can't use anonymous field inheritance because it works + // differently in Go and in C++. + + Hash *local = NewHash(); + for (Node *ni = Getattr(n, "firstChild"); ni; ni = nextSibling(ni)) { + + if (!is_public(ni)) { + continue; + } + + String *type = Getattr(ni, "nodeType"); + if (Cmp(type, "constructor") == 0 || Cmp(type, "destructor") == 0) { + continue; + } + + String *cname = Getattr(ni, "sym:name"); + if (!cname) { + cname = Getattr(ni, "name"); + } + if (cname) { + Setattr(local, cname, NewString("")); + } + } + + for (Iterator b = First(baselist); b.item; b = Next(b)) { + List *bases = NewList(); + Append(bases, Getattr(b.item, "classtype")); + int r = addBase(n, b.item, bases, local); + if (r != SWIG_OK) { + return r; + } + Delete(bases); + } + + Delete(local); + + Hash *parents = NewHash(); + addFirstBaseInterface(n, parents, baselist); + int r = addExtraBaseInterfaces(n, parents, baselist); + Delete(parents); + if (r != SWIG_OK) { + return r; + } + } + + Printv(f_go_wrappers, "type ", go_name, " interface {\n", NULL); + Printv(f_go_wrappers, "\tSwigcptr() uintptr\n", NULL); + Printv(f_go_wrappers, "\tSwigIs", go_name, "()\n", NULL); + + if (is_director) { + Printv(f_go_wrappers, "\tDirectorInterface() interface{}\n", NULL); + } + + Append(f_go_wrappers, interfaces); + Printv(f_go_wrappers, "}\n\n", NULL); + Delete(interfaces); + + interfaces = NULL; + class_name = NULL; + class_receiver = NULL; + class_node = NULL; + Delete(class_methods); + class_methods = NULL; + + Delete(go_type_name); + + return SWIG_OK; + } + + /* ------------------------------------------------------------ + * addBase() + * + * Implement methods and members defined in a parent class for a + * child class. + * ------------------------------------------------------------ */ + + int addBase(Node *n, Node *base, List *bases, Hash *local) { + if (GetFlag(base, "feature:ignore")) { + return SWIG_OK; + } + + for (Node *ni = Getattr(base, "firstChild"); ni; ni = nextSibling(ni)) { + + if (GetFlag(ni, "feature:ignore")) { + continue; + } + + if (!is_public(ni)) { + continue; + } + + String *type = Getattr(ni, "nodeType"); + if (Strcmp(type, "constructor") == 0 || Strcmp(type, "destructor") == 0 || Strcmp(type, "enum") == 0 || Strcmp(type, "using") == 0 || Strcmp(type, "classforward") == 0 || Strcmp(type, "template") == 0) { + continue; + } + String *storage = Getattr(ni, "storage"); + if (storage && (Strcmp(storage, "typedef") == 0 || Strcmp(storage, "friend") == 0)) { + continue; + } + + String *mname = Getattr(ni, "sym:name"); + if (!mname) { + continue; + } + + String *lname = Getattr(ni, "name"); + if (Getattr(class_methods, lname)) { + continue; + } + if (Getattr(local, lname)) { + continue; + } + Setattr(local, lname, NewString("")); + + String *ty = NewString(Getattr(ni, "type")); + SwigType_push(ty, Getattr(ni, "decl")); + String *fullty = SwigType_typedef_resolve_all(ty); + bool is_function = SwigType_isfunction(fullty) ? true : false; + Delete(ty); + Delete(fullty); + + if (is_function) { + int r = goBaseMethod(n, bases, ni); + if (r != SWIG_OK) { + return r; + } + + if (Getattr(ni, "sym:overloaded")) { + for (Node *on = Getattr(ni, "sym:nextSibling"); on; on = Getattr(on, "sym:nextSibling")) { + r = goBaseMethod(n, bases, on); + if (r != SWIG_OK) { + return r; + } + } + + String *receiver = class_receiver; + bool is_static = isStatic(ni); + if (is_static) { + receiver = NULL; + } + String *go_name = buildGoName(Getattr(ni, "sym:name"), is_static, false); + r = makeDispatchFunction(ni, go_name, receiver, is_static, NULL, false); + Delete(go_name); + if (r != SWIG_OK) { + return r; + } + } + } else { + int r = goBaseVariable(n, bases, ni); + if (r != SWIG_OK) { + return r; + } + } + } + + List *baselist = Getattr(base, "bases"); + if (baselist && Len(baselist) > 0) { + for (Iterator b = First(baselist); b.item; b = Next(b)) { + List *nb = Copy(bases); + Append(nb, Getattr(b.item, "classtype")); + int r = addBase(n, b.item, nb, local); + Delete(nb); + if (r != SWIG_OK) { + return r; + } + } + } + + return SWIG_OK; + } + + /* ------------------------------------------------------------ + * goBaseMethod() + * + * Implement a method defined in a parent class for a child class. + * ------------------------------------------------------------ */ + + int goBaseMethod(Node *method_class, List *bases, Node *method) { + String *symname = Getattr(method, "sym:name"); + if (!validIdentifier(symname)) { + return SWIG_OK; + } + + String *name = NewString(""); + Printv(name, Getattr(method_class, "sym:name"), "_", symname, NULL); + + bool is_static = isStatic(method); + + String *go_name = buildGoName(name, is_static, false); + + String *overname = NULL; + if (Getattr(method, "sym:overloaded")) { + overname = Getattr(method, "sym:overname"); + } + String *wname = Swig_name_wrapper(name); + if (overname) { + Append(wname, overname); + } + + String *result = NewString(Getattr(method, "type")); + SwigType_push(result, Getattr(method, "decl")); + if (SwigType_isqualifier(result)) { + Delete(SwigType_pop(result)); + } + Delete(SwigType_pop_function(result)); + + // If the base method is imported, wrap:action may not be set. + Swig_save("goBaseMethod", method, "wrap:name", "wrap:action", "parms", NULL); + Setattr(method, "wrap:name", wname); + if (!Getattr(method, "wrap:action")) { + if (!is_static) { + Swig_MethodToFunction(method, getNSpace(), getClassType(), (Getattr(method, "template") ? SmartPointer : Extend | SmartPointer), NULL, false); + // Remove any self parameter that was just added. + ParmList *parms = Getattr(method, "parms"); + if (parms && Getattr(parms, "self")) { + parms = CopyParmList(nextSibling(parms)); + Setattr(method, "parms", parms); + } + } else { + String *call = Swig_cfunction_call(Getattr(method, "name"), Getattr(method, "parms")); + Setattr(method, "wrap:action", Swig_cresult(Getattr(method, "type"), Swig_cresult_name(), call)); + } + } + + int r = makeWrappers(method, name, go_name, overname, wname, bases, Getattr(method, "parms"), result, is_static); + + Swig_restore(method); + + Delete(result); + Delete(go_name); + Delete(name); + + return r; + } + + /* ------------------------------------------------------------ + * goBaseVariable() + * + * Add accessors for a member variable defined in a parent class for + * a child class. + * ------------------------------------------------------------ */ + + int goBaseVariable(Node *var_class, List *bases, Node *var) { + if (isStatic(var)) { + return SWIG_OK; + } + + String *var_name = buildGoName(Getattr(var, "sym:name"), false, false); + + Swig_save("goBaseVariable", var, "type", "wrap:action", NULL); + + // For a pointer type we apparently have to wrap in the decl. + SwigType *var_type = NewString(Getattr(var, "type")); + SwigType_push(var_type, Getattr(var, "decl")); + Setattr(var, "type", var_type); + + SwigType *vt = Copy(var_type); + if (SwigType_isclass(vt)) { + SwigType_add_pointer(vt); + } + + int flags = Extend | SmartPointer | use_naturalvar_mode(var); + if (isNonVirtualProtectedAccess(var)) { + flags |= CWRAP_ALL_PROTECTED_ACCESS; + } + + String *mname = Swig_name_member(getNSpace(), Getattr(var_class, "sym:name"), var_name); + + if (is_assignable(var)) { + for (Iterator ki = First(var); ki.key; ki = Next(ki)) { + if (Strncmp(ki.key, "tmap:", 5) == 0) { + Delattr(var, ki.key); + } + } + Swig_save("goBaseVariableSet", var, "name", "sym:name", "type", NULL); + + String *mname_set = NewString("Set"); + Append(mname_set, mname); + + String *go_name = NewString("Set"); + Append(go_name, var_name); + + Swig_MembersetToFunction(var, class_name, flags); + + String *wname = Swig_name_wrapper(mname_set); + ParmList *parms = NewParm(vt, var_name, var); + String *result = NewString("void"); + int r = makeWrappers(var, mname_set, go_name, NULL, wname, bases, parms, result, false); + if (r != SWIG_OK) { + return r; + } + Delete(wname); + Delete(parms); + Delete(result); + Delete(go_name); + Delete(mname_set); + + Swig_restore(var); + for (Iterator ki = First(var); ki.key; ki = Next(ki)) { + if (Strncmp(ki.key, "tmap:", 5) == 0) { + Delattr(var, ki.key); + } + } + } + + Swig_MembergetToFunction(var, class_name, flags); + + String *mname_get = NewString("Get"); + Append(mname_get, mname); + + String *go_name = NewString("Get"); + Append(go_name, var_name); + + String *wname = Swig_name_wrapper(mname_get); + + int r = makeWrappers(var, mname_get, go_name, NULL, wname, bases, NULL, vt, false); + if (r != SWIG_OK) { + return r; + } + + Delete(wname); + Delete(mname_get); + Delete(go_name); + Delete(mname); + Delete(var_name); + Delete(var_type); + Delete(vt); + + Swig_restore(var); + + return SWIG_OK; + } + + /* ------------------------------------------------------------ + * addFirstBaseInterface() + * + * When a C++ class uses multiple inheritance, we can use the C++ + * pointer for the first base class but not for any subsequent base + * classes. However, the Go interface will match the interface for + * all the base classes. To avoid accidentally treating a class as + * a pointer to a base class other than the first one, we use an + * isClassname method. This function adds those methods as + * required. + * + * For convenience when using multiple inheritance, we also add + * functions to retrieve the base class pointers. + * ------------------------------------------------------------ */ + + void addFirstBaseInterface(Node *n, Hash *parents, List *bases) { + if (!bases || Len(bases) == 0) { + return; + } + Iterator b = First(bases); + if (!GetFlag(b.item, "feature:ignore")) { + String *go_name = buildGoName(Getattr(n, "sym:name"), false, false); + String *go_type_name = goCPointerType(Getattr(n, "classtypeobj"), true); + String *go_base_name = exportedName(Getattr(b.item, "sym:name")); + String *go_base_type = goType(n, Getattr(b.item, "classtypeobj")); + String *go_base_type_name = goCPointerType(Getattr(b.item, "classtypeobj"), true); + + Printv(f_go_wrappers, "func (p ", go_type_name, ") SwigIs", go_base_name, "() {\n", NULL); + Printv(f_go_wrappers, "}\n\n", NULL); + + Printv(interfaces, "\tSwigIs", go_base_name, "()\n", NULL); + + Printv(f_go_wrappers, "func (p ", go_type_name, ") SwigGet", go_base_name, "() ", go_base_type, " {\n", NULL); + Printv(f_go_wrappers, "\treturn ", go_base_type_name, "(p.Swigcptr())\n", NULL); + Printv(f_go_wrappers, "}\n\n", NULL); + + Printv(interfaces, "\tSwigGet", go_base_name, "() ", go_base_type, "\n", NULL); + + Setattr(parents, go_base_name, NewString("")); + + Delete(go_name); + Delete(go_type_name); + Delete(go_base_type); + Delete(go_base_type_name); + } + + addFirstBaseInterface(n, parents, Getattr(b.item, "bases")); + } + + /* ------------------------------------------------------------ + * addExtraBaseInterfaces() + * + * Add functions to retrieve the base class pointers for all base + * classes other than the first. + * ------------------------------------------------------------ */ + + int addExtraBaseInterfaces(Node *n, Hash *parents, List *bases) { + Iterator b = First(bases); + + Node *fb = b.item; + + for (b = Next(b); b.item; b = Next(b)) { + if (GetFlag(b.item, "feature:ignore")) { + continue; + } + + String *go_base_name = exportedName(Getattr(b.item, "sym:name")); + + Swig_save("addExtraBaseInterface", n, "wrap:action", "wrap:name", "wrap:parms", NULL); + + SwigType *type = Copy(Getattr(n, "classtypeobj")); + SwigType_add_pointer(type); + Parm *parm = NewParm(type, "self", n); + Setattr(n, "wrap:parms", parm); + + String *pn = Swig_cparm_name(parm, 0); + String *action = NewString(""); + Printv(action, Swig_cresult_name(), " = (", Getattr(b.item, "classtype"), "*)", pn, ";", NULL); + Delete(pn); + + Setattr(n, "wrap:action", action); + + String *name = Copy(class_name); + Append(name, "_SwigGet"); + Append(name, go_base_name); + + String *go_name = NewString("SwigGet"); + String *c1 = exportedName(go_base_name); + Append(go_name, c1); + Delete(c1); + + String *wname = Swig_name_wrapper(name); + Setattr(n, "wrap:name", wname); + + SwigType *result = Copy(Getattr(b.item, "classtypeobj")); + SwigType_add_pointer(result); + + int r = makeWrappers(n, name, go_name, NULL, wname, NULL, parm, result, + false); + if (r != SWIG_OK) { + return r; + } + + Swig_restore(n); + + Setattr(parents, go_base_name, NewString("")); + + Delete(go_name); + Delete(type); + Delete(parm); + Delete(action); + Delete(result); + + String *ns = NewString(""); + addParentExtraBaseInterfaces(n, parents, b.item, false, ns); + Delete(ns); + } + + if (!GetFlag(fb, "feature:ignore")) { + String *ns = NewString(""); + addParentExtraBaseInterfaces(n, parents, fb, true, ns); + Delete(ns); + } + + return SWIG_OK; + } + + /* ------------------------------------------------------------ + * addParentExtraBaseInterfaces() + * + * Add functions to retrieve the base class pointers for all base + * classes of parents other than the first base class at each level. + * ------------------------------------------------------------ */ + + void addParentExtraBaseInterfaces(Node *n, Hash *parents, Node *base, bool is_base_first, String *sofar) { + List *baselist = Getattr(base, "bases"); + if (!baselist || Len(baselist) == 0) { + return; + } + + String *go_this_base_name = exportedName(Getattr(base, "sym:name")); + + String *sf = NewString(""); + Printv(sf, sofar, ".SwigGet", go_this_base_name, "()", NULL); + + Iterator b = First(baselist); + + if (is_base_first) { + if (!b.item) { + return; + } + if (!GetFlag(b.item, "feature:ignore")) { + addParentExtraBaseInterfaces(n, parents, b.item, true, sf); + } + + b = Next(b); + } + + String *go_name = buildGoName(Getattr(n, "sym:name"), false, false); + String *go_type_name = goCPointerType(Getattr(n, "classtypeobj"), true); + + for (; b.item; b = Next(b)) { + if (GetFlag(b.item, "feature:ignore")) { + continue; + } + + String *go_base_name = exportedName(Getattr(b.item, "sym:name")); + + if (!Getattr(parents, go_base_name)) { + Printv(f_go_wrappers, "func (p ", go_type_name, ") SwigGet", go_base_name, "() ", go_base_name, " {\n", NULL); + Printv(f_go_wrappers, "\treturn p", sf, ".SwigGet", go_base_name, "()\n", NULL); + Printv(f_go_wrappers, "}\n\n", NULL); + + Printv(interfaces, "\tSwigGet", go_base_name, "() ", go_base_name, "\n", NULL); + + addParentExtraBaseInterfaces(n, parents, b.item, false, sf); + + Setattr(parents, go_base_name, NewString("")); + } + } + + Delete(go_name); + Delete(go_type_name); + Delete(go_this_base_name); + Delete(sf); + } + + /* ------------------------------------------------------------ + * classDirectorInit + * + * Add support for a director class. + * + * Virtual inheritance is different in Go and C++. We implement + * director classes by defining a new function in Go, + * NewDirectorClassname, which takes a empty interface value and + * creates an instance of a new child class. The new child class + * refers all methods back to Go. The Go code checks whether the + * value passed to NewDirectorClassname implements that method; if + * it does, it calls it, otherwise it calls back into C++. + * ------------------------------------------------------------ */ + + int classDirectorInit(Node *n) { + // Because we use a different function to handle inheritance in + // Go, ordinary creations of the object should not create a + // director object. + Delete(director_ctor_code); + director_ctor_code = NewString("$nondirector_new"); + + class_node = n; + + String *name = Getattr(n, "sym:name"); + + assert(!class_name); + class_name = name; + + String *go_name = exportedName(name); + + String *go_type_name = goCPointerType(Getattr(n, "classtypeobj"), true); + + assert(!class_receiver); + class_receiver = go_type_name; + + String *director_struct_name = NewString("_swig_Director"); + Append(director_struct_name, go_name); + + String *cxx_director_name = NewString("SwigDirector_"); + Append(cxx_director_name, name); + + // The Go type of the director class. + Printv(f_go_wrappers, "type ", director_struct_name, " struct {\n", NULL); + Printv(f_go_wrappers, "\t", go_type_name, "\n", NULL); + Printv(f_go_wrappers, "\tv interface{}\n", NULL); + Printv(f_go_wrappers, "}\n\n", NULL); + + Printv(f_go_wrappers, "func (p *", director_struct_name, ") Swigcptr() uintptr {\n", NULL); + Printv(f_go_wrappers, "\treturn p.", go_type_name, ".Swigcptr()\n", NULL); + Printv(f_go_wrappers, "}\n\n", NULL); + + Printv(f_go_wrappers, "func (p *", director_struct_name, ") SwigIs", go_name, "() {\n", NULL); + Printv(f_go_wrappers, "}\n\n", NULL); + + Printv(f_go_wrappers, "func (p *", director_struct_name, ") DirectorInterface() interface{} {\n", NULL); + Printv(f_go_wrappers, "\treturn p.v\n", NULL); + Printv(f_go_wrappers, "}\n\n", NULL); + + // Start defining the director class. + Printv(f_c_directors_h, "class ", cxx_director_name, " : public ", Getattr(n, "classtype"), "\n", NULL); + Printv(f_c_directors_h, "{\n", NULL); + Printv(f_c_directors_h, " public:\n", NULL); + + Delete(director_struct_name); + Delete(cxx_director_name); + + class_methods = NewHash(); + + return SWIG_OK; + } + + /* ------------------------------------------------------------ + * classDirectorConstructor + * + * Emit a constructor for a director class. + * ------------------------------------------------------------ */ + + int classDirectorConstructor(Node *n) { + bool is_ignored = GetFlag(n, "feature:ignore") ? true : false; + + String *name = Getattr(n, "sym:name"); + if (!name) { + assert(is_ignored); + name = Getattr(n, "name"); + } + + String *overname = NULL; + if (Getattr(n, "sym:overloaded")) { + overname = Getattr(n, "sym:overname"); + } + + String *go_name = exportedName(name); + + ParmList *parms = Getattr(n, "parms"); + Setattr(n, "wrap:parms", parms); + + String *cn = exportedName(Getattr(parentNode(n), "sym:name")); + + String *go_type_name = goCPointerType(Getattr(parentNode(n), "classtypeobj"), true); + + String *director_struct_name = NewString("_swig_Director"); + Append(director_struct_name, cn); + + String *fn_name = NewString("_swig_NewDirector"); + Append(fn_name, cn); + Append(fn_name, go_name); + + if (!overname && !is_ignored) { + if (!checkNameConflict(fn_name, n, NULL)) { + return SWIG_NOWRAP; + } + } + + String *wname = Swig_name_wrapper(fn_name); + + if (overname) { + Append(wname, overname); + } + Setattr(n, "wrap:name", wname); + + bool is_static = isStatic(n); + + Wrapper *dummy = NewWrapper(); + emit_attach_parmmaps(parms, dummy); + DelWrapper(dummy); + + Swig_typemap_attach_parms("gotype", parms, NULL); + Swig_typemap_attach_parms("imtype", parms, NULL); + int parm_count = emit_num_arguments(parms); + + String *func_name = NewString("NewDirector"); + Append(func_name, go_name); + + String *func_with_over_name = Copy(func_name); + if (overname) { + Append(func_with_over_name, overname); + } + + SwigType *first_type = NewString("void"); + SwigType_add_pointer(first_type); + Parm *first_parm = NewParm(first_type, "swig_p", n); + set_nextSibling(first_parm, parms); + Setattr(first_parm, "lname", "p"); + + Parm *p = parms; + for (int i = 0; i < parm_count; ++i) { + p = getParm(p); + Swig_cparm_name(p, i); + p = nextParm(p); + } + + if (!is_ignored) { + // Declare the C++ wrapper. + + if (!gccgo_flag) { + Printv(f_go_wrappers, "var ", wname, " unsafe.Pointer\n\n", NULL); + } else { + Printv(f_go_wrappers, "//extern ", go_prefix, "_", wname, "\n", NULL); + } + + Printv(f_go_wrappers, "func ", fn_name, NULL); + if (overname) { + Printv(f_go_wrappers, overname, NULL); + } + Printv(f_go_wrappers, "(_swig_director *", director_struct_name, NULL); + + p = parms; + for (int i = 0; i < parm_count; ++i) { + p = getParm(p); + String *tm = goType(p, Getattr(p, "type")); + Printv(f_go_wrappers, ", _ ", tm, NULL); + Delete(tm); + p = nextParm(p); + } + + Printv(f_go_wrappers, ") (_swig_ret ", go_type_name, ")", NULL); + + if (!gccgo_flag) { + Printv(f_go_wrappers, " {\n", NULL); + Printv(f_go_wrappers, "\t_swig_p := uintptr(unsafe.Pointer(&_swig_director))\n", NULL); + Printv(f_go_wrappers, "\t_cgo_runtime_cgocall(", wname, ", _swig_p)\n", NULL); + Printv(f_go_wrappers, "\treturn\n", NULL); + Printv(f_go_wrappers, "}", NULL); + } + + Printv(f_go_wrappers, "\n\n", NULL); + + Printv(f_go_wrappers, "func ", func_with_over_name, "(v interface{}", NULL); + + p = parms; + for (int i = 0; i < parm_count; ++i) { + p = getParm(p); + // Set the lname parameter. + Printv(f_go_wrappers, ", ", Getattr(p, "lname"), " ", NULL); + String *tm = goType(p, Getattr(p, "type")); + Printv(f_go_wrappers, tm, NULL); + Delete(tm); + p = nextParm(p); + } + + Printv(f_go_wrappers, ") ", cn, " {\n", NULL); + + Printv(f_go_wrappers, "\tp := &", director_struct_name, "{0, v}\n", NULL); + + if (gccgo_flag) { + Printv(f_go_wrappers, "\tdefer SwigCgocallDone()\n", NULL); + Printv(f_go_wrappers, "\tSwigCgocall()\n", NULL); + } + + Printv(f_go_wrappers, "\tp.", class_receiver, " = ", fn_name, NULL); + if (overname) { + Printv(f_go_wrappers, overname, NULL); + } + Printv(f_go_wrappers, "(p", NULL); + + p = parms; + for (int i = 0; i < parm_count; ++i) { + p = getParm(p); + Printv(f_go_wrappers, ", ", Getattr(p, "lname"), NULL); + p = nextParm(p); + } + + Printv(f_go_wrappers, ")\n", NULL); + Printv(f_go_wrappers, "\treturn p\n", NULL); + Printv(f_go_wrappers, "}\n\n", NULL); + + SwigType *result = Copy(Getattr(parentNode(n), "classtypeobj")); + SwigType_add_pointer(result); + + Swig_save("classDirectorConstructor", n, "wrap:name", "wrap:action", NULL); + + Setattr(n, "wrap:name", Swig_name_wrapper(name)); + + String *action = NewString(""); + Printv(action, Swig_cresult_name(), " = new SwigDirector_", class_name, "(", NULL); + String *pname = Swig_cparm_name(NULL, 0); + Printv(action, pname, NULL); + Delete(pname); + p = parms; + for (int i = 0; i < parm_count; ++i) { + p = getParm(p); + String *pname = Swig_cparm_name(NULL, i + 1); + Printv(action, ", ", NULL); + if (SwigType_isreference(Getattr(p, "type"))) { + Printv(action, "*", NULL); + } + Printv(action, pname, NULL); + Delete(pname); + p = nextParm(p); + } + Printv(action, ");", NULL); + Setattr(n, "wrap:action", action); + + if (!gccgo_flag) { + int r = gcFunctionWrapper(wname); + if (r != SWIG_OK) { + return r; + } + r = gccFunctionWrapper(n, NULL, wname, first_parm, result); + if (r != SWIG_OK) { + return r; + } + } else { + int r = gccgoFunctionWrapper(n, NULL, wname, first_parm, result); + if (r != SWIG_OK) { + return r; + } + } + + Swig_restore(n); + + Delete(result); + } + + String *cxx_director_name = NewString("SwigDirector_"); + Append(cxx_director_name, class_name); + + String *decl = Swig_method_decl(NULL, Getattr(n, "decl"), + cxx_director_name, first_parm, 0, 0); + Printv(f_c_directors_h, " ", decl, ";\n", NULL); + Delete(decl); + + decl = Swig_method_decl(NULL, Getattr(n, "decl"), cxx_director_name, first_parm, 0, 0); + Printv(f_c_directors, cxx_director_name, "::", decl, "\n", NULL); + Delete(decl); + + Printv(f_c_directors, " : ", Getattr(parentNode(n), "classtype"), "(", NULL); + + p = parms; + for (int i = 0; i < parm_count; ++i) { + p = getParm(p); + if (i > 0) { + Printv(f_c_directors, ", ", NULL); + } + String *pn = Getattr(p, "name"); + assert(pn); + Printv(f_c_directors, pn, NULL); + p = nextParm(p); + } + Printv(f_c_directors, "),\n", NULL); + Printv(f_c_directors, " go_val(swig_p)\n", NULL); + Printv(f_c_directors, "{ }\n\n", NULL); + + if (Getattr(n, "sym:overloaded") && !Getattr(n, "sym:nextSibling")) { + int r = makeDispatchFunction(n, func_name, cn, is_static, Getattr(parentNode(n), "classtypeobj"), false); + if (r != SWIG_OK) { + return r; + } + } + + Delete(cxx_director_name); + Delete(go_name); + Delete(cn); + Delete(go_type_name); + Delete(director_struct_name); + Delete(fn_name); + Delete(func_name); + Delete(func_with_over_name); + Delete(wname); + Delete(first_type); + Delete(first_parm); + + return SWIG_OK; + } + + /* ------------------------------------------------------------ + * classDirectorDestructor + * + * Emit a destructor for a director class. + * ------------------------------------------------------------ */ + + int classDirectorDestructor(Node *n) { + if (!is_public(n)) { + return SWIG_OK; + } + + bool is_ignored = GetFlag(n, "feature:ignore") ? true : false; + + if (!is_ignored) { + String *fnname = NewString("DeleteDirector"); + String *c1 = exportedName(class_name); + Append(fnname, c1); + Delete(c1); + + String *wname = Swig_name_wrapper(fnname); + + Setattr(n, "wrap:name", fnname); + + Swig_DestructorToFunction(n, getNSpace(), getClassType(), CPlusPlus, Extend); + + ParmList *parms = Getattr(n, "parms"); + Setattr(n, "wrap:parms", parms); + + String *result = NewString("void"); + int r = makeWrappers(n, fnname, fnname, NULL, wname, NULL, parms, result, isStatic(n)); + if (r != SWIG_OK) { + return r; + } + + Delete(result); + Delete(fnname); + Delete(wname); + } + + // Generate the destructor for the C++ director class. Since the + // Go code is keeping a pointer to the C++ object, we need to call + // back to the Go code to let it know that the C++ object is gone. + + String *wname = NewString("_swiggo_wrap_DeleteDirector_"); + Append(wname, class_name); + + String *go_name = NewString("Swiggo_DeleteDirector_"); + Append(go_name, class_name); + + String *cn = exportedName(class_name); + + String *director_struct_name = NewString("_swig_Director"); + Append(director_struct_name, cn); + + Printv(f_c_directors_h, " virtual ~SwigDirector_", class_name, "()", NULL); + + String *throws = buildThrow(n); + if (throws) { + Printv(f_c_directors_h, " ", throws, NULL); + } + + Printv(f_c_directors_h, ";\n", NULL); + + if (!is_ignored) { + if (!gccgo_flag) { + Printv(f_c_directors, "extern \"C\" void ", wname, "(void*, int);\n", NULL); + } else { + Printv(f_c_directors, "extern \"C\" void ", wname, "(void*) __asm__(\"", go_prefix, ".", go_name, "\");\n", NULL); + } + } + + Printv(f_c_directors, "SwigDirector_", class_name, "::~SwigDirector_", class_name, "()", NULL); + + if (throws) { + Printv(f_c_directors, " ", throws, NULL); + Delete(throws); + } + + Printv(f_c_directors, "\n", NULL); + Printv(f_c_directors, "{\n", NULL); + + if (!is_ignored) { + if (!gccgo_flag) { + Printv(f_c_directors, " struct { void *p; } a;\n", NULL); + Printv(f_c_directors, " a.p = go_val;\n", NULL); + Printv(f_c_directors, " crosscall2(", wname, ", &a, (int) sizeof a);\n", NULL); + + Printv(f_gc_wrappers, "#pragma dynexport ", wname, " ", wname, "\n", NULL); + Printv(f_gc_wrappers, "#pragma cgo_export_static ", wname, " ", wname, "\n", NULL); + Printv(f_gc_wrappers, "#pragma textflag 7\n", NULL); + Printv(f_gc_wrappers, "extern void \xc2\xb7", go_name, "();\n", NULL); + Printv(f_gc_wrappers, "void\n", NULL); + Printv(f_gc_wrappers, wname, "(void *a, int32 n)\n", NULL); + Printv(f_gc_wrappers, "{\n", NULL); + Printv(f_gc_wrappers, "\truntime\xc2\xb7" "cgocallback(\xc2\xb7", go_name, ", a, n);\n", NULL); + Printv(f_gc_wrappers, "}\n\n", NULL); + } else { + Printv(f_c_directors, " ", wname, "(go_val);\n", NULL); + } + } + + Printv(f_c_directors, "}\n\n", NULL); + + if (!is_ignored) { + Printv(f_go_wrappers, "func ", go_name, "(p *", director_struct_name, ") {\n", NULL); + Printv(f_go_wrappers, "\tp.", class_receiver, " = 0\n", NULL); + Printv(f_go_wrappers, "}\n\n", NULL); + } + + Delete(wname); + Delete(go_name); + Delete(cn); + Delete(director_struct_name); + + return SWIG_OK; + } + + /* ------------------------------------------------------------ + * classDirectorMethod + * + * Emit a method for a director class, plus its overloads. + * ------------------------------------------------------------ */ + + int classDirectorMethod(Node *n, Node *parent, String *super) { + bool is_ignored = GetFlag(n, "feature:ignore") ? true : false; + + // We don't need explicit calls. + if (GetFlag(n, "explicitcall")) { + return SWIG_OK; + } + + String *name = Getattr(n, "sym:name"); + if (!name) { + assert(is_ignored); + name = Getattr(n, "name"); + } + + bool overloaded = Getattr(n, "sym:overloaded") && !Getattr(n, "explicitcallnode"); + if (!overloaded) { + int r = oneClassDirectorMethod(n, parent, super); + if (r != SWIG_OK) { + return r; + } + } else { + // Handle overloaded methods here, because otherwise we will + // reject them in the class_methods hash table. We need to use + // class_methods so that we correctly handle cases where a + // function in one class hides a function of the same name in a + // parent class. + if (!Getattr(class_methods, name)) { + for (Node *on = Getattr(n, "sym:overloaded"); on; on = Getattr(on, "sym:nextSibling")) { + // Swig_overload_rank expects wrap:name and wrap:parms to be + // set. + String *wn = Swig_name_wrapper(Getattr(on, "sym:name")); + Append(wn, Getattr(on, "sym:overname")); + Setattr(on, "wrap:name", wn); + Delete(wn); + Setattr(on, "wrap:parms", Getattr(on, "parms")); + } + } + + int r = oneClassDirectorMethod(n, parent, super); + if (r != SWIG_OK) { + return r; + } + + if (!Getattr(n, "sym:nextSibling")) + { + // Last overloaded function + Node *on = Getattr(n, "sym:overloaded"); + bool is_static = isStatic(on); + + String *cn = exportedName(Getattr(parent, "sym:name")); + String *go_name = buildGoName(name, is_static, false); + + String *director_struct_name = NewString("_swig_Director"); + Append(director_struct_name, cn); + + int r = makeDispatchFunction(on, go_name, director_struct_name, is_static, director_struct_name, false); + if (r != SWIG_OK) { + return r; + } + + if (!GetFlag(n, "abstract")) { + String *go_upcall = NewString("Director"); + Append(go_upcall, cn); + Append(go_upcall, go_name); + r = makeDispatchFunction(on, go_upcall, director_struct_name, is_static, director_struct_name, true); + if (r != SWIG_OK) { + return r; + } + Delete(go_upcall); + } + + Delete(director_struct_name); + Delete(go_name); + Delete(cn); + } + } + Setattr(class_methods, name, NewString("")); + + return SWIG_OK; + } + + /* ------------------------------------------------------------ + * oneClassDirectorMethod + * + * Emit a method for a director class. + * ------------------------------------------------------------ */ + + int oneClassDirectorMethod(Node *n, Node *parent, String *super) { + String *symname = Getattr(n, "sym:name"); + if (!checkFunctionVisibility(n, parent)) { + return SWIG_OK; + } + + bool is_ignored = GetFlag(n, "feature:ignore") ? true : false; + bool is_pure_virtual = (Cmp(Getattr(n, "storage"), "virtual") == 0 && Cmp(Getattr(n, "value"), "0") == 0); + + String *name = Getattr(n, "sym:name"); + if (!name) { + assert(is_ignored); + name = Getattr(n, "name"); + } + + String *overname = NULL; + if (Getattr(n, "sym:overloaded")) { + overname = Getattr(n, "sym:overname"); + } + + String *cn = exportedName(Getattr(parent, "sym:name")); + + String *go_type_name = goCPointerType(Getattr(parent, "classtypeobj"), true); + + String *director_struct_name = NewString("_swig_Director"); + Append(director_struct_name, cn); + + bool is_static = isStatic(n); + + String *go_name = buildGoName(name, is_static, false); + + ParmList *parms = Getattr(n, "parms"); + Setattr(n, "wrap:parms", parms); + + Wrapper *dummy = NewWrapper(); + emit_attach_parmmaps(parms, dummy); + DelWrapper(dummy); + + Swig_typemap_attach_parms("gotype", parms, NULL); + Swig_typemap_attach_parms("imtype", parms, NULL); + int parm_count = emit_num_arguments(parms); + + SwigType *result = Getattr(n, "type"); + + // Save the type for overload processing. + Setattr(n, "go:type", result); + + String *interface_name = NewString("_swig_DirectorInterface"); + Append(interface_name, cn); + Append(interface_name, go_name); + if (overname) { + Append(interface_name, overname); + } + + String *callback_name = Copy(director_struct_name); + Append(callback_name, "_callback_"); + Append(callback_name, name); + Replace(callback_name, "_swig", "Swig", DOH_REPLACE_FIRST); + if (overname) { + Append(callback_name, overname); + } + + String *callback_wname = Swig_name_wrapper(callback_name); + + String *upcall_name = Copy(director_struct_name); + Append(upcall_name, "_upcall_"); + Append(upcall_name, go_name); + + String *upcall_wname = Swig_name_wrapper(upcall_name); + if (overname) { + Append(upcall_wname, overname); + } + + String *upcall_gc_name = buildGoWrapperName(upcall_name, overname); + + String *go_with_over_name = Copy(go_name); + if (overname) { + Append(go_with_over_name, overname); + } + + Parm *p = 0; + Wrapper *w = NewWrapper(); + + Swig_director_parms_fixup(parms); + + Swig_typemap_attach_parms("directorin", parms, w); + Swig_typemap_attach_parms("directorargout", parms, w); + Swig_typemap_attach_parms("godirectorin", parms, w); + Swig_typemap_attach_parms("goin", parms, dummy); + Swig_typemap_attach_parms("goargout", parms, dummy); + + if (!is_ignored) { + // We use an interface to see if this method is defined in Go. + Printv(f_go_wrappers, "type ", interface_name, " interface {\n", NULL); + Printv(f_go_wrappers, "\t", go_with_over_name, "(", NULL); + + p = parms; + for (int i = 0; i < parm_count; ++i) { + p = getParm(p); + if (i > 0) { + Printv(f_go_wrappers, ", ", NULL); + } + String *tm = goType(p, Getattr(p, "type")); + Printv(f_go_wrappers, tm, NULL); + Delete(tm); + p = nextParm(p); + } + + Printv(f_go_wrappers, ")", NULL); + + if (SwigType_type(result) != T_VOID) { + String *tm = goType(n, result); + Printv(f_go_wrappers, " ", tm, NULL); + Delete(tm); + } + + Printv(f_go_wrappers, "\n", NULL); + Printv(f_go_wrappers, "}\n\n", NULL); + + if (!GetFlag(n, "abstract")) { + // Declare the upcall function, which calls the method on the + // parent class. + + if (!gccgo_flag) { + Printv(f_go_wrappers, "var ", upcall_wname, " unsafe.Pointer\n\n", NULL); + } else { + Printv(f_go_wrappers, "//extern ", go_prefix, "_", upcall_wname, "\n", NULL); + } + + Printv(f_go_wrappers, "func ", upcall_gc_name, "(_swig_ptr ", go_type_name, NULL); + + p = parms; + for (int i = 0; i < parm_count; ++i) { + p = getParm(p); + String *tm = goWrapperType(p, Getattr(p, "type"), false); + Printv(f_go_wrappers, ", _ ", tm, NULL); + Delete(tm); + p = nextParm(p); + } + + Printv(f_go_wrappers, ")", NULL); + + if (SwigType_type(result) != T_VOID) { + String *tm = goWrapperType(n, result, true); + Printv(f_go_wrappers, " (_swig_ret ", tm, ")", NULL); + Delete(tm); + } + + if (!gccgo_flag) { + Printv(f_go_wrappers, " {\n", NULL); + Printv(f_go_wrappers, "\t_swig_p := uintptr(unsafe.Pointer(&_swig_ptr))\n", NULL); + Printv(f_go_wrappers, "\t_cgo_runtime_cgocall(", upcall_wname, ", _swig_p)\n", NULL); + Printv(f_go_wrappers, "\treturn\n", NULL); + Printv(f_go_wrappers, "}", NULL); + } + + Printv(f_go_wrappers, "\n\n", NULL); + } + + // Define the method on the director class in Go. + + Printv(f_go_wrappers, "func (swig_p *", director_struct_name, ") ", go_with_over_name, "(", NULL); + + p = parms; + for (int i = 0; i < parm_count; ++i) { + p = getParm(p); + if (i > 0) { + Printv(f_go_wrappers, ", ", NULL); + } + Printv(f_go_wrappers, Getattr(p, "lname"), " ", NULL); + String *tm = goType(p, Getattr(p, "type")); + Printv(f_go_wrappers, tm, NULL); + Delete(tm); + p = nextParm(p); + } + + Printv(f_go_wrappers, ")", NULL); + + if (SwigType_type(result) != T_VOID) { + String *tm = goType(n, result); + Printv(f_go_wrappers, " ", tm, NULL); + Delete(tm); + } + + Printv(f_go_wrappers, " {\n", NULL); + + Printv(f_go_wrappers, "\tif swig_g, swig_ok := swig_p.v.(", interface_name, "); swig_ok {\n", NULL); + Printv(f_go_wrappers, "\t\t", NULL); + if (SwigType_type(result) != T_VOID) { + Printv(f_go_wrappers, "return ", NULL); + } + Printv(f_go_wrappers, "swig_g.", go_with_over_name, "(", NULL); + + p = parms; + for (int i = 0; i < parm_count; ++i) { + p = getParm(p); + if (i > 0) { + Printv(f_go_wrappers, ", ", NULL); + } + Printv(f_go_wrappers, Getattr(p, "lname"), NULL); + p = nextParm(p); + } + + Printv(f_go_wrappers, ")\n", NULL); + if (SwigType_type(result) == T_VOID) { + Printv(f_go_wrappers, "\t\treturn\n", NULL); + } + Printv(f_go_wrappers, "\t}\n", NULL); + + if (GetFlag(n, "abstract")) { + Printv(f_go_wrappers, "\tpanic(\"call to pure virtual method\")\n", NULL); + } else { + bool has_goout = false; + String *goout = NULL; + if (SwigType_type(result) != T_VOID) { + Printv(f_go_wrappers, "\tvar swig_r ", goImType(n, result), "\n", NULL); + goout = Swig_typemap_lookup("goout", n, "swig_r", NULL); + if (goout) { + has_goout = true; + } + } + + p = parms; + for (int i = 0; i < parm_count; ++i) { + p = getParm(p); + if (Getattr(p, "tmap:goargout")) { + has_goout = true; + } + p = nextParm(p); + } + + String *call = NewString(""); + + if (gccgo_flag) { + if (has_goout) { + Printv(call, "\tfunc() {\n", NULL); + } + Printv(call, "\tdefer SwigCgocallDone()\n", NULL); + Printv(call, "\tSwigCgocall()\n", NULL); + } + + Printv(call, "\t", NULL); + if (SwigType_type(result) != T_VOID) { + Printv(call, "swig_r = ", NULL); + } + Printv(call, upcall_gc_name, "(swig_p.", go_type_name, NULL); + + p = parms; + for (int i = 0; i < parm_count; ++i) { + Printv(call, ", ", NULL); + p = getParm(p); + SwigType *pt = Getattr(p, "type"); + + String *ln = Getattr(p, "lname"); + + // This is an ordinary call from Go to C++, so adjust using + // the goin typemap. + String *goin = Getattr(p, "tmap:goin"); + if (goin == NULL) { + Printv(call, ln, NULL); + if (goTypeIsInterface(p, pt)) { + Printv(call, ".Swigcptr()", NULL); + } + Setattr(p, "emit:goinput", ln); + } else { + String *ivar = NewString(""); + Printf(ivar, "_swig_i_%d", i); + String *itm = goImType(p, pt); + Printv(f_go_wrappers, "\tvar ", ivar, " ", itm, NULL); + goin = Copy(goin); + Replaceall(goin, "$input", ln); + Replaceall(goin, "$result", ivar); + Printv(f_go_wrappers, goin, NULL); + Delete(goin); + Printv(call, ivar, NULL); + Setattr(p, "emit:goinput", ivar); + } + + p = nextParm(p); + } + + Printv(call, ")\n", NULL); + + if (gccgo_flag && has_goout) { + Printv(call, "\t}()\n", NULL); + } + + Printv(f_go_wrappers, call, NULL); + Delete(call); + + goargout(parms, parm_count); + + if (SwigType_type(result) != T_VOID) { + if (goout == NULL) { + Printv(f_go_wrappers, "\treturn swig_r\n", NULL); + } else { + String *tm = goType(n, result); + Printv(f_go_wrappers, "\tvar swig_r_1 ", tm, "\n", NULL); + Replaceall(goout, "$input", "swig_r"); + Replaceall(goout, "$result", "swig_r_1"); + Printv(f_go_wrappers, goout, NULL); + Printv(f_go_wrappers, "\treturn swig_r_1\n", NULL); + } + } + } + + Printv(f_go_wrappers, "}\n\n", NULL); + + // Define a method in the C++ director class that the C++ upcall + // function can call. This permits an upcall to a protected + // method. + + if (!GetFlag(n, "abstract")) { + String *upcall_method_name = NewString("_swig_upcall_"); + Append(upcall_method_name, name); + if (overname) { + Append(upcall_method_name, overname); + } + SwigType *rtype = Getattr(n, "classDirectorMethods:type"); + String *upcall_decl = Swig_method_decl(rtype, Getattr(n, "decl"), upcall_method_name, parms, 0, 0); + Printv(f_c_directors_h, " ", upcall_decl, " {\n", NULL); + Delete(upcall_decl); + + Printv(f_c_directors_h, " ", NULL); + if (SwigType_type(result) != T_VOID) { + Printv(f_c_directors_h, "return ", NULL); + } + + String *super_call = Swig_method_call(super, parms); + Printv(f_c_directors_h, super_call, ";\n", NULL); + Delete(super_call); + + Printv(f_c_directors_h, " }\n", NULL); + + // Define the C++ function that the Go function calls. + + SwigType *first_type = NULL; + Parm *first_parm = parms; + if (!is_static) { + first_type = NewString("SwigDirector_"); + Append(first_type, class_name); + SwigType_add_pointer(first_type); + first_parm = NewParm(first_type, "p", n); + set_nextSibling(first_parm, parms); + } + + Swig_save("classDirectorMethod", n, "wrap:name", "wrap:action", NULL); + + Setattr(n, "wrap:name", upcall_wname); + + String *action = NewString(""); + if (SwigType_type(result) != T_VOID) { + Printv(action, Swig_cresult_name(), " = (", SwigType_lstr(result, 0), ")", NULL); + if (SwigType_isreference(result)) { + Printv(action, "&", NULL); + } + } + Printv(action, Swig_cparm_name(NULL, 0), "->", upcall_method_name, "(", NULL); + + p = parms; + int i = 0; + while (p != NULL) { + if (SwigType_type(Getattr(p, "type")) != T_VOID) { + String *pname = Swig_cparm_name(NULL, i + 1); + if (i > 0) { + Printv(action, ", ", NULL); + } + + // A parameter whose type is a reference is converted into a + // pointer type by gcCTypeForGoValue. We are calling a + // function which expects a reference so we need to convert + // back. + if (SwigType_isreference(Getattr(p, "type"))) { + Printv(action, "*", NULL); + } + + Printv(action, pname, NULL); + Delete(pname); + i++; + } + p = nextSibling(p); + } + Printv(action, ");", NULL); + Setattr(n, "wrap:action", action); + + if (!gccgo_flag) { + // Write the upcall wrapper function. This is compiled by gc + // and calls the C++ function. + int r = gcFunctionWrapper(upcall_wname); + if (r != SWIG_OK) { + return r; + } + r = gccFunctionWrapper(n, NULL, upcall_wname, first_parm, result); + if (r != SWIG_OK) { + return r; + } + } else { + int r = gccgoFunctionWrapper(n, NULL, upcall_wname, first_parm, result); + if (r != SWIG_OK) { + return r; + } + } + + Delete(first_type); + if (first_parm != parms) { + Delete(first_parm); + } + + Swig_restore(n); + Delete(upcall_method_name); + + // Define a function that uses the Go director type that other + // methods in the Go type can call to get parent methods. + + Printv(f_go_wrappers, "func Director", cn, go_with_over_name, "(p ", cn, NULL); + + p = parms; + for (int i = 0; i < parm_count; ++i) { + p = getParm(p); + Printv(f_go_wrappers, ", ", Getattr(p, "lname"), " ", NULL); + String *tm = goType(p, Getattr(p, "type")); + Printv(f_go_wrappers, tm, NULL); + Delete(tm); + p = nextParm(p); + } + + Printv(f_go_wrappers, ")", NULL); + + if (SwigType_type(result) != T_VOID) { + String *tm = goType(n, result); + Printv(f_go_wrappers, " ", tm, NULL); + Delete(tm); + } + + Printv(f_go_wrappers, " {\n", NULL); + + String *goout = NULL; + if (SwigType_type(result) != T_VOID) { + Printv(f_go_wrappers, "\tvar swig_r ", goImType(n, result), "\n", NULL); + goout = Swig_typemap_lookup("goout", n, "swig_r", NULL); + } + + String *call = NewString(""); + + if (gccgo_flag) { + if (goout != NULL) { + Printv(call, "\tfunc() {\n", NULL); + } + Printv(call, "\tdefer SwigCgocallDone()\n", NULL); + Printv(call, "\tSwigCgocall()\n", NULL); + } + + Printv(call, "\t", NULL); + if (SwigType_type(result) != T_VOID) { + Printv(call, "swig_r = ", NULL); + } + Printv(call, upcall_gc_name, "(p.(*", director_struct_name, ").", go_type_name, NULL); + + p = parms; + for (int i = 0; i < parm_count; ++i) { + Printv(call, ", ", NULL); + p = getParm(p); + SwigType *pt = Getattr(p, "type"); + + String *ln = Copy(Getattr(p, "lname")); + if (goTypeIsInterface(p, pt)) { + Printv(ln, ".Swigcptr()", NULL); + } + + String *goin = Getattr(p, "tmap:goin"); + if (goin == NULL) { + Printv(call, ln, NULL); + Setattr(p, "emit:goinput", ln); + } else { + String *ivar = NewString(""); + Printf(ivar, "_swig_i_%d", i); + String *itm = goImType(p, pt); + Printv(f_go_wrappers, "\tvar ", ivar, " ", itm, NULL); + goin = Copy(goin); + Replaceall(goin, "$input", ln); + Replaceall(goin, "$result", ivar); + Printv(f_go_wrappers, goin, NULL); + Delete(goin); + Printv(call, ivar, NULL); + Setattr(p, "emit:goinput", ivar); + } + + Delete(ln); + + p = nextParm(p); + } + + Printv(call, ")\n", NULL); + + if (gccgo_flag && goout != NULL) { + Printv(call, "\t}()\n", NULL); + } + + Printv(f_go_wrappers, call, NULL); + Delete(call); + + goargout(parms, parm_count); + + if (SwigType_type(result) != T_VOID) { + if (goout == NULL) { + Printv(f_go_wrappers, "\treturn swig_r\n", NULL); + } else { + String *tm = goType(n, result); + Printv(f_go_wrappers, "\tvar swig_r_1 ", tm, "\n", NULL); + Replaceall(goout, "$input", "swig_r"); + Replaceall(goout, "$result", "swig_r_1"); + Printv(f_go_wrappers, goout, NULL); + Printv(f_go_wrappers, "\treturn swig_r_1\n", NULL); + } + } + + Printv(f_go_wrappers, "}\n\n", NULL); + } + + // The Go function which invokes the method. This is called + // from by the C++ method on the director class. + + Printv(f_go_wrappers, "func ", callback_name, "(p *", director_struct_name, NULL); + + p = parms; + for (int i = 0; i < parm_count; ++i) { + p = getParm(p); + String *tm = goWrapperType(p, Getattr(p, "type"), false); + Printv(f_go_wrappers, ", ", Getattr(p, "lname"), " ", tm, NULL); + Delete(tm); + p = nextParm(p); + } + + Printv(f_go_wrappers, ") ", NULL); + String *result_wrapper = NULL; + if (SwigType_type(result) != T_VOID) { + result_wrapper = goWrapperType(n, result, true); + Printv(f_go_wrappers, "(swig_result ", result_wrapper, ") ", NULL); + } + Printv(f_go_wrappers, "{\n", NULL); + + if (is_ignored) { + Printv(f_go_wrappers, "\treturn\n", NULL); + } else { + bool result_is_interface = false; + String *goout = NULL; + if (SwigType_type(result) != T_VOID) { + result_is_interface = goTypeIsInterface(NULL, result); + Printv(f_go_wrappers, "\tvar swig_r ", NULL); + if (!result_is_interface) { + Printv(f_go_wrappers, goType(n, result), NULL); + } else { + Printv(f_go_wrappers, result_wrapper, NULL); + } + Printv(f_go_wrappers, "\n", NULL); + goout = Swig_typemap_lookup("godirectorout", n, "swig_r", NULL); + } + + String *call = NewString(""); + + if (gccgo_flag) { + if (goout != NULL) { + Printv(call, "\tfunc() {\n", NULL); + } + Printv(call, "\tSwigCgocallBack()\n", NULL); + Printv(call, "\tdefer SwigCgocallBackDone()\n", NULL); + } + + Printv(call, "\t", NULL); + + if (SwigType_type(result) != T_VOID) { + Printv(call, "swig_r = ", NULL); + if (result_is_interface) { + Printv(call, result_wrapper, "(", NULL); + } + } + Printv(call, "p.", go_with_over_name, "(", NULL); + + p = parms; + for (int i = 0; i < parm_count; ++i) { + p = getParm(p); + if (i > 0) { + Printv(call, ", ", NULL); + } + SwigType *pt = Getattr(p, "type"); + + String *ln = NewString(""); + + // If the Go representation is an interface type class, then + // we are receiving a uintptr, and must convert to the + // interface. + bool is_interface = goTypeIsInterface(p, pt); + if (is_interface) { + // Passing is_result as true to goWrapperType gives us the + // name of the Go type we need to convert to an interface. + String *wt = goWrapperType(p, pt, true); + Printv(ln, wt, "(", NULL); + Delete(wt); + } + + Printv(ln, Getattr(p, "lname"), NULL); + + if (is_interface) { + Printv(ln, ")", NULL); + } + + String *goin = Getattr(p, "tmap:godirectorin"); + if (goin == NULL) { + Printv(call, ln, NULL); + } else { + String *ivar = NewString(""); + Printf(ivar, "_swig_i_%d", i); + String *itm = goType(p, pt); + Printv(f_go_wrappers, "\tvar ", ivar, " ", itm, NULL); + goin = Copy(goin); + Replaceall(goin, "$input", ln); + Replaceall(goin, "$result", ivar); + Printv(f_go_wrappers, goin, NULL); + Delete(goin); + Printv(call, ivar, NULL); + Delete(ivar); + } + + Delete(ln); + + p = nextParm(p); + } + + Printv(call, ")", NULL); + + if (result_is_interface) { + Printv(call, ".Swigcptr())", NULL); + } + Printv(call, "\n", NULL); + + if (gccgo_flag && goout != NULL) { + Printv(call, "\t}()\n", NULL); + } + + Printv(f_go_wrappers, call, NULL); + Delete(call); + + if (SwigType_type(result) != T_VOID) { + if (goout == NULL) { + Printv(f_go_wrappers, "\treturn swig_r\n", NULL); + } else { + String *tm = goImType(n, result); + Printv(f_go_wrappers, "\tvar swig_r_1 ", tm, "\n", NULL); + Replaceall(goout, "$input", "swig_r"); + Replaceall(goout, "$result", "swig_r_1"); + Printv(f_go_wrappers, goout, NULL); + Printv(f_go_wrappers, "\treturn swig_r_1\n", NULL); + } + } + } + + Printv(f_go_wrappers, "}\n\n", NULL); + + Delete(result_wrapper); + + Delete(upcall_wname); + Delete(upcall_gc_name); + + // Build the C++ functions. + + if (!gccgo_flag) { + Printv(f_c_directors, "extern \"C\" void ", callback_wname, "(void*, int);\n", NULL); + } else { + Printv(f_c_directors, "extern \"C\" ", NULL); + + String *fnname = NewString(""); + Printv(fnname, callback_wname, "(void*", NULL); + + p = parms; + while (p) { + while (checkAttribute(p, "tmap:directorin:numinputs", "0")) { + p = Getattr(p, "tmap:directorin:next"); + } + String *cg = gccgoCTypeForGoValue(p, Getattr(p, "type"), + Getattr(p, "lname")); + Printv(fnname, ", ", cg, NULL); + Delete(cg); + p = Getattr(p, "tmap:directorin:next"); + } + + Printv(fnname, ")", NULL); + + if (SwigType_type(result) == T_VOID) { + Printv(f_c_directors, "void ", fnname, NULL); + } else { + String *tm = gccgoCTypeForGoValue(n, result, fnname); + Printv(f_c_directors, tm, NULL); + Delete(tm); + } + + Delete(fnname); + + Printv(f_c_directors, " __asm__(\"", go_prefix, ".", callback_name, "\");\n", NULL); + } + + Delete(go_with_over_name); + } + + if (!is_ignored || is_pure_virtual) { + // Declare the method for the director class. + + SwigType *rtype = Getattr(n, "conversion_operator") ? 0 : Getattr(n, "classDirectorMethods:type"); + String *decl = Swig_method_decl(rtype, Getattr(n, "decl"), Getattr(n, "name"), parms, 0, 0); + Printv(f_c_directors_h, " virtual ", decl, NULL); + Delete(decl); + + String *qname = NewString(""); + Printv(qname, "SwigDirector_", class_name, "::", Getattr(n, "name"), NULL); + decl = Swig_method_decl(rtype, Getattr(n, "decl"), qname, parms, 0, 0); + Printv(w->def, decl, NULL); + Delete(decl); + Delete(qname); + + String *throws = buildThrow(n); + if (throws) { + Printv(f_c_directors_h, " ", throws, NULL); + Printv(w->def, " ", throws, NULL); + Delete(throws); + } + + Printv(f_c_directors_h, ";\n", NULL); + + Printv(w->def, " {\n", NULL); + + if (SwigType_type(result) != T_VOID) { + Wrapper_add_local(w, "c_result", SwigType_lstr(result, "c_result")); + } + + if (!is_ignored) { + if (!gccgo_flag) { + Printv(w->code, " struct {\n", NULL); + Printv(w->code, " void *go_val;\n", NULL); + + p = parms; + while (p) { + while (checkAttribute(p, "tmap:directorin:numinputs", "0")) { + p = Getattr(p, "tmap:directorin:next"); + } + String *ln = Getattr(p, "lname"); + String *cg = gcCTypeForGoValue(p, Getattr(p, "type"), ln); + Printv(w->code, " ", cg, ";\n", NULL); + Delete(cg); + p = Getattr(p, "tmap:directorin:next"); + } + if (SwigType_type(result) != T_VOID) { + Printv(w->code, " long : 0;\n", NULL); + String *rname = NewString(Swig_cresult_name()); + String *cg = gcCTypeForGoValue(n, result, rname); + Printv(w->code, " ", cg, ";\n", NULL); + Delete(cg); + Delete(rname); + } + + Printv(w->code, " } swig_a;\n", NULL); + Printv(w->code, " swig_a.go_val = go_val;\n", NULL); + + p = parms; + while (p) { + while (checkAttribute(p, "tmap:directorin:numinputs", "0")) { + p = Getattr(p, "tmap:directorin:next"); + } + String *tm = Getattr(p, "tmap:directorin"); + if (!tm) { + Swig_warning(WARN_TYPEMAP_DIRECTORIN_UNDEF, input_file, + line_number, "Unable to use type %s as director method argument\n", SwigType_str(Getattr(p, "type"), 0)); + } else { + tm = Copy(tm); + String *ln = Getattr(p, "lname"); + String *input = NewString(""); + Printv(input, "swig_a.", ln, NULL); + Setattr(p, "emit:directorinput", input); + Replaceall(tm, "$input", input); + Replaceall(tm, "$owner", "0"); + Delete(input); + Printv(w->code, "\t", tm, "\n", NULL); + Delete(tm); + } + p = Getattr(p, "tmap:directorin:next"); + } + + Printv(w->code, " crosscall2(", callback_wname, ", &swig_a, (int) sizeof swig_a);\n", NULL); + + /* Marshal outputs */ + for (p = parms; p;) { + String *tm; + if ((tm = Getattr(p, "tmap:directorargout"))) { + tm = Copy(tm); + Replaceall(tm, "$result", "jresult"); + Replaceall(tm, "$input", Getattr(p, "emit:directorinput")); + Printv(w->code, tm, "\n", NIL); + Delete(tm); + p = Getattr(p, "tmap:directorargout:next"); + } else { + p = nextSibling(p); + } + } + + if (SwigType_type(result) != T_VOID) { + String *result_str = NewString("c_result"); + String *tm = Swig_typemap_lookup("directorout", n, result_str, NULL); + if (!tm) { + Swig_warning(WARN_TYPEMAP_DIRECTOROUT_UNDEF, input_file, line_number, + "Unable to use type %s as director method result\n", SwigType_str(result, 0)); + } else { + static const String *swig_a_result = NewStringf("swig_a.%s", Swig_cresult_name()); + Replaceall(tm, "$input", swig_a_result); + Replaceall(tm, "$result", "c_result"); + Printv(w->code, " ", tm, "\n", NULL); + String *retstr = SwigType_rcaststr(result, "c_result"); + Printv(w->code, " return ", retstr, ";\n", NULL); + Delete(retstr); + Delete(tm); + } + Delete(result_str); + } + + // The C wrapper code which calls the Go function. + Printv(f_gc_wrappers, "#pragma dynexport ", callback_wname, " ", callback_wname, "\n", NULL); + Printv(f_gc_wrappers, "#pragma cgo_export_static ", callback_wname, " ", callback_wname, "\n", NULL); + Printv(f_gc_wrappers, "#pragma textflag 7\n", NULL); + Printv(f_gc_wrappers, "extern void \xc2\xb7", callback_name, "();\n", NULL); + Printv(f_gc_wrappers, "void\n", NULL); + Printv(f_gc_wrappers, callback_wname, "(void *a, int32 n)\n", NULL); + Printv(f_gc_wrappers, "{\n", NULL); + Printv(f_gc_wrappers, "\truntime\xc2\xb7" "cgocallback(\xc2\xb7", callback_name, ", a, n);\n", NULL); + Printv(f_gc_wrappers, "}\n\n", NULL); + } else { + if (SwigType_type(result) != T_VOID) { + String *r = NewString(Swig_cresult_name()); + String *tm = gccgoCTypeForGoValue(n, result, r); + Wrapper_add_local(w, r, tm); + Delete(tm); + Delete(r); + } + + String *args = NewString(""); + + p = parms; + while (p) { + while (checkAttribute(p, "tmap:directorin:numinputs", "0")) { + p = Getattr(p, "tmap:directorin:next"); + } + + String *pn = NewString("g"); + Append(pn, Getattr(p, "lname")); + Setattr(p, "emit:directorinput", pn); + + String *tm = gccgoCTypeForGoValue(n, Getattr(p, "type"), pn); + Wrapper_add_local(w, pn, tm); + Delete(tm); + + tm = Getattr(p, "tmap:directorin"); + if (!tm) { + Swig_warning(WARN_TYPEMAP_DIRECTORIN_UNDEF, input_file, + line_number, "Unable to use type %s as director method argument\n", SwigType_str(Getattr(p, "type"), 0)); + } else { + tm = Copy(tm); + Replaceall(tm, "$input", pn); + Replaceall(tm, "$owner", 0); + Printv(w->code, " ", tm, "\n", NULL); + Delete(tm); + + Printv(args, ", ", pn, NULL); + } + + p = Getattr(p, "tmap:directorin:next"); + } + + Printv(w->code, " ", NULL); + if (SwigType_type(result) != T_VOID) { + Printv(w->code, Swig_cresult_name(), " = ", NULL); + } + Printv(w->code, callback_wname, "(go_val", args, ");\n", NULL); + + /* Marshal outputs */ + for (p = parms; p;) { + String *tm; + if ((tm = Getattr(p, "tmap:directorargout"))) { + tm = Copy(tm); + Replaceall(tm, "$result", "jresult"); + Replaceall(tm, "$input", Getattr(p, "emit:directorinput")); + Printv(w->code, tm, "\n", NIL); + Delete(tm); + p = Getattr(p, "tmap:directorargout:next"); + } else { + p = nextSibling(p); + } + } + + if (SwigType_type(result) != T_VOID) { + String *result_str = NewString("c_result"); + String *tm = Swig_typemap_lookup("directorout", n, result_str, NULL); + if (!tm) { + Swig_warning(WARN_TYPEMAP_DIRECTOROUT_UNDEF, input_file, line_number, + "Unable to use type %s as director method result\n", SwigType_str(result, 0)); + } else { + Replaceall(tm, "$input", Swig_cresult_name()); + Replaceall(tm, "$result", "c_result"); + Printv(w->code, " ", tm, "\n", NULL); + String *retstr = SwigType_rcaststr(result, "c_result"); + Printv(w->code, " return ", retstr, ";\n", NULL); + Delete(retstr); + Delete(tm); + } + Delete(result_str); + } + } + } else { + assert(is_pure_virtual); + Printv(w->code, " _swig_gopanic(\"call to pure virtual function ", Getattr(parent, "sym:name"), name, "\");\n", NULL); + if (SwigType_type(result) != T_VOID) { + String *retstr = SwigType_rcaststr(result, "c_result"); + Printv(w->code, " return ", retstr, ";\n", NULL); + Delete(retstr); + } + } + + Printv(w->code, "}", NULL); + + Replaceall(w->code, "$symname", symname); + Wrapper_print(w, f_c_directors); + } + + Delete(cn); + Delete(go_type_name); + Delete(director_struct_name); + Delete(interface_name); + Delete(upcall_name); + Delete(callback_wname); + Delete(go_name); + DelWrapper(w); + + return SWIG_OK; + } + + /* ------------------------------------------------------------ + * classDirectorEnd + * + * Complete support for a director class. + * ------------------------------------------------------------ */ + + int classDirectorEnd(Node *n) { + (void) n; + + Printv(f_c_directors_h, " private:\n", NULL); + Printv(f_c_directors_h, " void *go_val;\n", NULL); + Printv(f_c_directors_h, "};\n\n", NULL); + + class_name = NULL; + class_node = NULL; + + Delete(class_receiver); + class_receiver = NULL; + + Delete(class_methods); + class_methods = NULL; + + return SWIG_OK; + } + + /* ------------------------------------------------------------ + * classDirectorDisown + * + * I think Go does not require a disown method. + * ------------------------------------------------------------ */ + + int classDirectorDisown(Node *n) { + (void) n; + return SWIG_OK; + } + + /*---------------------------------------------------------------------- + * buildThrow() + * + * Build and return a throw clause if needed. + *--------------------------------------------------------------------*/ + + String *buildThrow(Node *n) { + ParmList *throw_parm_list = Getattr(n, "throws"); + if (!throw_parm_list && !Getattr(n, "throw")) + return NULL; + String *ret = NewString("throw("); + if (throw_parm_list) { + Swig_typemap_attach_parms("throws", throw_parm_list, NULL); + } + bool first = true; + for (Parm *p = throw_parm_list; p; p = nextSibling(p)) { + if (Getattr(p, "tmap:throws")) { + if (first) { + first = false; + } else { + Printv(ret, ", ", NULL); + } + String *s = SwigType_str(Getattr(p, "type"), 0); + Printv(ret, s, NULL); + Delete(s); + } + } + Printv(ret, ")", NULL); + return ret; + } + + /*---------------------------------------------------------------------- + * extraDirectorProtectedCPPMethodsRequired() + * + * We don't need to check upcall when calling methods. + *--------------------------------------------------------------------*/ + + bool extraDirectorProtectedCPPMethodsRequired() const { + return false; + } + + /*---------------------------------------------------------------------- + * makeDispatchFunction + * + * Make a dispatch function for an overloaded C++ function. The + * receiver parameter is the receiver for a method, unless is_upcall + * is true. If is_upcall is true, then the receiver parameter is + * the type of the first argument to the function. + *--------------------------------------------------------------------*/ + + int makeDispatchFunction(Node *n, String *go_name, String *receiver, bool is_static, SwigType *director_struct, bool is_upcall) { + bool is_director = director_struct ? true : false; + + String *nodetype = Getattr(n, "nodeType"); + bool is_constructor = Cmp(nodetype, "constructor") == 0; + bool is_destructor = Cmp(nodetype, "destructor") == 0; + + bool can_use_receiver = (!is_constructor && !is_destructor && !is_upcall); + + bool use_receiver = (!is_static && can_use_receiver); + + bool add_to_interface = (interfaces && !is_constructor && !is_destructor && !is_static && !is_upcall); + + List *dispatch = Swig_overload_rank(n, false); + int nfunc = Len(dispatch); + + SwigType *all_result; + bool mismatch; + if (is_constructor) { + assert(!is_upcall); + if (!is_director) { + all_result = Copy(Getattr(class_node, "classtypeobj")); + } else { + all_result = Copy(director_struct); + } + mismatch = false; + } else { + all_result = NULL; + mismatch = false; + bool any_void = false; + for (int i = 0; i < nfunc; ++i) { + Node *nn = Getitem(dispatch, i); + Node *ni = Getattr(nn, "directorNode") ? Getattr(nn, "directorNode") : nn; + SwigType *result = Getattr(ni, "go:type"); + assert(result); + + if (SwigType_type(result) == T_VOID) { + if (all_result) { + mismatch = true; + } + any_void = true; + } else { + if (any_void) { + mismatch = true; + } else if (!all_result) { + all_result = Copy(result); + } else if (Cmp(result, all_result) != 0) { + mismatch = true; + } + } + } + if (mismatch) { + Delete(all_result); + all_result = NULL; + } else if (all_result) { + ; + } else { + all_result = NewString("void"); + } + } + + Printv(f_go_wrappers, "func ", NULL); + + if (receiver && use_receiver) { + Printv(f_go_wrappers, "(p ", receiver, ") ", NULL); + } + + Printv(f_go_wrappers, go_name, "(", NULL); + if (is_director && is_constructor) { + Printv(f_go_wrappers, "abi interface{}, ", NULL); + assert(!add_to_interface); + } + if (is_upcall) { + Printv(f_go_wrappers, "p *", receiver, ", ", NULL); + assert(!add_to_interface); + } + Printv(f_go_wrappers, "a ...interface{})", NULL); + + if (add_to_interface) { + Printv(interfaces, "\t", go_name, "(a ...interface{})", NULL); + } + + if (mismatch) { + Printv(f_go_wrappers, " interface{}", NULL); + if (add_to_interface) { + Printv(interfaces, " interface{}", NULL); + } + } else if (all_result && SwigType_type(all_result) != T_VOID) { + if (is_director && is_constructor) { + Printv(f_go_wrappers, " ", receiver, NULL); + if (add_to_interface) { + Printv(interfaces, " ", receiver, NULL); + } + } else { + String *tm = goType(n, all_result); + Printv(f_go_wrappers, " ", tm, NULL); + if (add_to_interface) { + Printv(interfaces, " ", tm, NULL); + } + Delete(tm); + } + } + Printv(f_go_wrappers, " {\n", NULL); + if (add_to_interface) { + Printv(interfaces, "\n", NULL); + } + + Printv(f_go_wrappers, "\targc := len(a)\n", NULL); + + for (int i = 0; i < nfunc; ++i) { + int fn = 0; + Node *nn = Getitem(dispatch, i); + Node *ni = Getattr(nn, "directorNode") ? Getattr(nn, "directorNode") : nn; + Parm *pi = Getattr(ni, "wrap:parms"); + + // If we are using a receiver, we want to ignore a leading self + // parameter. Because of the way this is called, there may or + // may not be a self parameter at this point. + if (use_receiver && pi && Getattr(pi, "self")) { + pi = getParm(pi); + if (pi) { + pi = nextParm(pi); + } + } + + int num_required = emit_num_required(pi); + int num_arguments = emit_num_arguments(pi); + bool varargs = emit_isvarargs(pi) ? true : false; + + if (varargs) { + Printf(f_go_wrappers, "\tif argc >= %d {\n", num_required); + } else { + if (num_required == num_arguments) { + Printf(f_go_wrappers, "\tif argc == %d {\n", num_required); + } else { + Printf(f_go_wrappers, "\tif argc >= %d && argc <= %d {\n", num_required, num_arguments); + } + } + + // Build list of collisions with the same number of arguments. + List *coll = NewList(); + for (int k = i + 1; k < nfunc; ++k) { + Node *nnk = Getitem(dispatch, k); + Node *nk = Getattr(nnk, "directorNode") ? Getattr(nnk, "directorNode") : nnk; + Parm *pk = Getattr(nk, "wrap:parms"); + if (use_receiver && pk && Getattr(pk, "self")) { + pk = getParm(pk); + if (pk) { + pk = nextParm(pk); + } + } + int nrk = emit_num_required(pk); + int nak = emit_num_arguments(pk); + if ((nrk >= num_required && nrk <= num_arguments) + || (nak >= num_required && nak <= num_arguments) + || (nrk <= num_required && nak >= num_arguments) + || (varargs && nrk >= num_required)) { + Append(coll, nk); + } + } + + int num_braces = 0; + if (Len(coll) > 0 && num_arguments > 0) { + int j = 0; + Parm *pj = pi; + while (pj) { + pj = getParm(pj); + if (!pj) { + break; + } + + // If all the wrappers have the same type in this position, + // we can omit the check. + SwigType *tm = goWrapperType(pj, Getattr(pj, "type"), true); + bool emitcheck = false; + for (int k = 0; k < Len(coll) && !emitcheck; ++k) { + Node *nk = Getitem(coll, k); + Parm *pk = Getattr(nk, "wrap:parms"); + if (use_receiver && pk && Getattr(pk, "self")) { + pk = getParm(pk); + if (pk) { + pk = nextParm(pk); + } + } + int nak = emit_num_arguments(pk); + if (nak <= j) + continue; + int l = 0; + Parm *pl = pk; + while (pl && l <= j) { + pl = getParm(pl); + if (!pl) { + break; + } + if (l == j) { + SwigType *tml = goWrapperType(pl, Getattr(pl, "type"), true); + if (Cmp(tm, tml) != 0) { + emitcheck = true; + } + Delete(tml); + } + pl = nextParm(pl); + ++l; + } + } + + if (emitcheck) { + if (j >= num_required) { + Printf(f_go_wrappers, "\t\tif argc > %d {\n", j); + ++num_braces; + } + + fn = i + 1; + Printf(f_go_wrappers, "\t\tif _, ok := a[%d].(%s); !ok {\n", j, tm); + Printf(f_go_wrappers, "\t\t\tgoto check_%d\n", fn); + Printv(f_go_wrappers, "\t\t}\n", NULL); + } + + Delete(tm); + + pj = nextParm(pj); + + ++j; + } + } + + for (; num_braces > 0; --num_braces) { + Printv(f_go_wrappers, "\t\t}\n", NULL); + } + + // We may need to generate multiple calls if there are variable + // argument lists involved. Build the start of the call. + + String *start = NewString(""); + + SwigType *result = Getattr(ni, "go:type"); + + if (is_constructor) { + result = all_result; + } else if (is_destructor) { + result = NULL; + } + + if (result && SwigType_type(result) != T_VOID && (!all_result || SwigType_type(all_result) != T_VOID)) { + Printv(start, "return ", NULL); + } + + bool advance_parm = false; + + if (receiver && use_receiver) { + Printv(start, "p.", go_name, NULL); + } else if (can_use_receiver && !isStatic(ni) && pi && Getattr(pi, "self")) { + // This is an overload of a static function and a non-static + // function. + assert(num_required > 0); + SwigType *tm = goWrapperType(pi, Getattr(pi, "type"), true); + String *nm = buildGoName(Getattr(ni, "sym:name"), false, isFriend(ni)); + Printv(start, "a[0].(", tm, ").", nm, NULL); + Delete(nm); + Delete(tm); + advance_parm = true; + } else { + Printv(start, go_name, NULL); + } + + Printv(start, Getattr(ni, "sym:overname"), "(", NULL); + + bool need_comma = false; + + if (is_director && is_constructor) { + Printv(start, "abi", NULL); + need_comma = true; + } + if (is_upcall) { + Printv(start, "p", NULL); + need_comma = true; + } + Parm *p = pi; + int pn = 0; + if (advance_parm) { + p = getParm(p); + if (p) { + p = nextParm(p); + } + ++pn; + } + while (pn < num_required) { + p = getParm(p); + + if (need_comma) { + Printv(start, ", ", NULL); + } + + SwigType *tm = goType(p, Getattr(p, "type")); + Printf(start, "a[%d].(%s)", pn, tm); + Delete(tm); + + need_comma = true; + ++pn; + p = nextParm(p); + } + + String *end = NULL; + if (!result || SwigType_type(result) == T_VOID || (all_result && SwigType_type(all_result) == T_VOID)) { + end = NewString(""); + Printv(end, "return", NULL); + if (!all_result || SwigType_type(all_result) != T_VOID) { + Printv(end, " 0", NULL); + } + } + + if (num_required == num_arguments) { + Printv(f_go_wrappers, "\t\t", start, ")\n", NULL); + if (end) { + Printv(f_go_wrappers, "\t\t", end, "\n", NULL); + } + } else { + Printv(f_go_wrappers, "\t\tswitch argc {\n", NULL); + for (int j = num_required; j <= num_arguments; ++j) { + Printf(f_go_wrappers, "\t\tcase %d:\n", j); + Printv(f_go_wrappers, "\t\t\t", start, NULL); + bool nc = need_comma; + for (int k = num_required; k < j; ++k) { + if (nc) { + Printv(f_go_wrappers, ", ", NULL); + } + Printf(f_go_wrappers, "a[%d]", k); + nc = true; + } + Printv(f_go_wrappers, ")\n", NULL); + if (end) { + Printv(f_go_wrappers, "\t\t\t", end, "\n", NULL); + } + } + Printv(f_go_wrappers, "\t\t}\n", NULL); + } + + Printv(f_go_wrappers, "\t}\n", NULL); + + if (fn != 0) { + Printf(f_go_wrappers, "check_%d:\n", fn); + } + + Delete(coll); + } + + Printv(f_go_wrappers, "\tpanic(\"No match for overloaded function call\")\n", NULL); + Printv(f_go_wrappers, "}\n\n", NULL); + + Delete(all_result); + Delete(dispatch); + + return SWIG_OK; + } + + /* ---------------------------------------------------------------------- + * checkFunctionVisibility() + * + * Return true if we should write out a function based on its + * visibility, false otherwise. + * ---------------------------------------------------------------------- */ + + bool checkFunctionVisibility(Node *n, Node *parent) { + // Write out a public function. + if (is_public(n)) + return true; + // Don't write out a private function. + if (is_private(n)) + return false; + // Write a protected function for a director class in + // dirprot_mode. + if (parent == NULL) { + return false; + } + if (dirprot_mode() && Swig_directorclass(parent)) + return true; + // Otherwise don't write out a protected function. + return false; + } + + + /* ---------------------------------------------------------------------- + * exportedName() + * + * Given a C/C++ name, return a name in Go which will be exported. + * If the first character is an upper case letter, this returns a + * copy of its argment. If the first character is a lower case + * letter, this forces it to upper case. Otherwise, this prepends + * 'X'. + * ---------------------------------------------------------------------- */ + + String *exportedName(String *name) { + String *copy = Copy(name); + char c = *Char(copy); + if (islower(c)) { + char l[2]; + char u[2]; + l[0] = c; + l[1] = '\0'; + u[0] = toupper(c); + u[1] = '\0'; + Replace(copy, l, u, DOH_REPLACE_FIRST); + } else if (!isalpha(c)) { + char l[2]; + char u[3]; + l[0] = c; + l[1] = '\0'; + u[0] = 'X'; + u[1] = c; + u[2] = '\0'; + Replace(copy, l, u, DOH_REPLACE_FIRST); + } + String *ret = Swig_name_mangle(copy); + Delete(copy); + return ret; + } + + /* ---------------------------------------------------------------------- + * removeClassname() + * + * If the name starts with the current class name, followed by an + * underscore, remove it. If there is no current class name, this + * simply returns a copy of the name. This undoes Swig's way of + * recording the class name in a member name. + * ---------------------------------------------------------------------- */ + + String *removeClassname(String *name) { + String *copy = Copy(name); + if (class_name) { + char *p = Char(name); + if (Strncmp(name, class_name, Len(class_name)) == 0 && p[Len(class_name)] == '_') { + Replace(copy, class_name, "", DOH_REPLACE_FIRST); + Replace(copy, "_", "", DOH_REPLACE_FIRST); + } + } + return copy; + } + + /* ---------------------------------------------------------------------- + * buildGoName() + * + * Build the name to use for an ordinary function, variable, or + * whatever in Go. The name argument is something like the sym:name + * attribute of the node. If is_static is false, this could be a + * method, and the returned name will be the name of the + * method--i.e., it will not include the class name. + * ---------------------------------------------------------------------- */ + + String *buildGoName(String *name, bool is_static, bool is_friend) { + String *nw = NewString(""); + if (is_static && !is_friend && class_name) { + String *c1 = exportedName(class_name); + Append(nw, c1); + Delete(c1); + } + String *c2 = removeClassname(name); + String *c3 = exportedName(c2); + Append(nw, c3); + Delete(c2); + Delete(c3); + String *ret = Swig_name_mangle(nw); + Delete(nw); + return ret; + } + + /* ---------------------------------------------------------------------- + * buildGoWrapperName() + * + * Build the name to use for a Go wrapper function. This is a + * function called by the real Go function in order to convert C++ + * classes from interfaces to pointers, and other such conversions + * between the Go type and the C++ type. + * ---------------------------------------------------------------------- */ + + String *buildGoWrapperName(String *name, String *overname) { + String *s1 = NewString("_swig_wrap_"); + Append(s1, name); + String *s2 = Swig_name_mangle(s1); + Delete(s1); + if (overname) { + Append(s2, overname); + } + return s2; + } + + /* ---------------------------------------------------------------------- + * checkNameConflict() + * + * Check for a name conflict on the name we are going to use in Go. + * These conflicts are likely because of the enforced + * capitalization. When we find one, issue a warning and return + * false. If the name is OK, return true. + * ---------------------------------------------------------------------- */ + + bool checkNameConflict(String* name, Node* n, const_String_or_char_ptr scope) { + Node *lk = symbolLookup(name, scope); + if (lk) { + String *n1 = Getattr(n, "sym:name"); + if (!n1) { + n1 = Getattr(n, "name"); + } + String *n2 = Getattr(lk, "sym:name"); + if (!n2) { + n2 = Getattr(lk, "name"); + } + Swig_warning(WARN_GO_NAME_CONFLICT, input_file, line_number, + "Ignoring '%s' due to Go name ('%s') conflict with '%s'\n", + n1, name, n2); + return false; + } + bool r = addSymbol(name, n, scope) ? true : false; + assert(r); + return true; + } + + /* ---------------------------------------------------------------------- + * checkIgnoredParameters() + * + * If any of the parameters of this function, or the return type, + * are ignored due to a name conflict, give a warning and return + * false. + * ---------------------------------------------------------------------- */ + + bool checkIgnoredParameters(Node *n, String *go_name) { + ParmList *parms = Getattr(n, "parms"); + if (parms) { + Wrapper *dummy = NewWrapper(); + emit_attach_parmmaps(parms, dummy); + int parm_count = emit_num_arguments(parms); + Parm *p = parms; + + for (int i = 0; i < parm_count; ++i) { + p = getParm(p); + if (!checkIgnoredType(n, go_name, Getattr(p, "type"))) { + DelWrapper(dummy); + return false; + } + p = nextParm(p); + } + + DelWrapper(dummy); + } + + if (!checkIgnoredType(n, go_name, Getattr(n, "type"))) { + return false; + } + + return true; + } + + /* ---------------------------------------------------------------------- + * checkIgnoredType() + * + * If this type is being ignored due to a name conflict, give a + * warning and return false. + * ---------------------------------------------------------------------- */ + + bool checkIgnoredType(Node *n, String *go_name, SwigType *type) { + if (hasGoTypemap(n, type)) { + return true; + } + + SwigType *t = SwigType_typedef_resolve_all(type); + + bool ret = true; + bool is_conflict = false; + Node *e = Language::enumLookup(t); + if (e) { + if (GetFlag(e, "go:conflict")) { + is_conflict = true; + } + } else if (SwigType_issimple(t)) { + Node *cn = classLookup(t); + if (cn) { + if (GetFlag(cn, "go:conflict")) { + is_conflict = true; + } + } + } else if (SwigType_ispointer(t) || SwigType_isarray(t) || SwigType_isqualifier(t) || SwigType_isreference(t)) { + SwigType *r = Copy(t); + if (SwigType_ispointer(r)) { + SwigType_del_pointer(r); + } else if (SwigType_isarray(r)) { + SwigType_del_array(r); + } else if (SwigType_isqualifier(r)) { + SwigType_del_qualifier(r); + } else { + SwigType_del_reference(r); + } + + if (!checkIgnoredType(n, go_name, r)) { + ret = false; + } + + Delete(r); + } + + if (is_conflict) { + String *s = SwigType_str(t, NULL); + Swig_warning(WARN_GO_NAME_CONFLICT, input_file, line_number, + "Ignoring '%s' (Go name '%s') due to Go name conflict for parameter or result type '%s'\n", + Getattr(n, "name"), go_name, s); + Delete(s); + ret = false; + } + + Delete(t); + + return ret; + } + + /* ---------------------------------------------------------------------- + * goType() + * + * Given a SWIG type, return a string for the type in Go. + * ---------------------------------------------------------------------- */ + + String *goType(Node *n, SwigType *type) { + return goTypeWithInfo(n, type, false, NULL); + } + + /* ---------------------------------------------------------------------- + * goImType() + * + * Given a SWIG type, return a string for the intermediate Go type + * to pass to C/C++. This is like goType except that it looks for + * an imtype typemap entry first. + * ---------------------------------------------------------------------- */ + + String *goImType(Node *n, SwigType *type) { + return goTypeWithInfo(n, type, true, NULL); + } + + /* ---------------------------------------------------------------------- + * goTypeWithInfo() + * + * Like goType, but return some more information. + * + * If use_imtype is true, this look for a imtype typemap entry. + * + * If the p_is_interface parameter is not NULL, this sets + * *p_is_interface to indicate whether this type is going to be + * represented by a Go interface type. These are cases where the Go + * code needs to make some adjustments when passing values back and + * forth with C/C++. + * ---------------------------------------------------------------------- */ + + String *goTypeWithInfo(Node *n, SwigType *type, bool use_imtype, bool *p_is_interface) { + if (p_is_interface) { + *p_is_interface = false; + } + + String *ret = NULL; + if (use_imtype) { + if (n && Cmp(type, Getattr(n, "type")) == 0) { + if (Strcmp(Getattr(n, "nodeType"), "parm") == 0) { + ret = Getattr(n, "tmap:imtype"); + } + if (!ret) { + ret = Swig_typemap_lookup("imtype", n, "", NULL); + } + } else { + Parm *p = NewParm(type, "goImType", n); + ret = Swig_typemap_lookup("imtype", p, "", NULL); + Delete(p); + } + } + if (!ret) { + if (n && Cmp(type, Getattr(n, "type")) == 0) { + if (Strcmp(Getattr(n, "nodeType"), "parm") == 0) { + ret = Getattr(n, "tmap:gotype"); + } + if (!ret) { + ret = Swig_typemap_lookup("gotype", n, "", NULL); + } + } else { + Parm *p = NewParm(type, "goType", n); + ret = Swig_typemap_lookup("gotype", p, "", NULL); + Delete(p); + } + } + + if (ret && Strstr(ret, "$gotypename") != 0) { + ret = NULL; + } + + if (ret) { + return Copy(ret); + } + + SwigType *t = SwigType_typedef_resolve_all(type); + + if (SwigType_isenum(t)) { + Node *e = Language::enumLookup(t); + if (e) { + ret = goEnumName(e); + } else if (Strcmp(t, "enum ") == 0) { + ret = NewString("int"); + } else { + // An unknown enum - one that has not been parsed (neither a C enum forward reference nor a definition) or an ignored enum + String *tt = Copy(t); + Replace(tt, "enum ", "", DOH_REPLACE_ANY); + ret = exportedName(tt); + Setattr(undefined_enum_types, t, ret); + Delete(tt); + } + } else if (SwigType_isfunctionpointer(type) || SwigType_isfunction(type)) { + ret = NewString("_swig_fnptr"); + } else if (SwigType_ismemberpointer(type)) { + ret = NewString("_swig_memberptr"); + } else if (SwigType_issimple(t)) { + Node *cn = classLookup(t); + if (cn) { + ret = Getattr(cn, "sym:name"); + if (!ret) { + ret = Getattr(cn, "name"); + } + ret = exportedName(ret); + + Node *cnmod = Getattr(cn, "module"); + if (!cnmod || Strcmp(Getattr(cnmod, "name"), module) == 0) { + Setattr(undefined_types, t, t); + } else { + String *nw = NewString(""); + Printv(nw, Getattr(cnmod, "name"), ".", ret, NULL); + Delete(ret); + ret = nw; + } + } else { + // SWIG does not know about this type. + ret = exportedName(t); + Setattr(undefined_types, t, t); + } + if (p_is_interface) { + *p_is_interface = true; + } + } else if (SwigType_ispointer(t) || SwigType_isarray(t)) { + SwigType *r = Copy(t); + if (SwigType_ispointer(r)) { + SwigType_del_pointer(r); + } else { + SwigType_del_array(r); + } + + if (SwigType_type(r) == T_VOID) { + ret = NewString("uintptr"); + } else { + bool is_interface; + String *base = goTypeWithInfo(n, r, false, &is_interface); + + // At the Go level, an unknown or class type is handled as an + // interface wrapping a pointer. This means that if a + // function returns the C type X, we will be wrapping the C + // type X*. In Go we will call that type X. That means that + // if a C function expects X*, we can pass the Go type X. And + // that means that when we see the C type X*, we should use + // the Go type X. + + // The is_interface variable tells us this. However, it will + // be true both for the case of X and for the case of X*. If + // r is a pointer here, then we are looking at X**. There is + // really no good way for us to handle that. + bool is_pointer_to_pointer = false; + if (is_interface) { + SwigType *c = Copy(r); + if (SwigType_isqualifier(c)) { + SwigType_del_qualifier(c); + if (SwigType_ispointer(c) || SwigType_isarray(c)) { + is_pointer_to_pointer = true; + } + } + Delete(c); + } + + if (is_interface) { + if (!is_pointer_to_pointer) { + ret = base; + if (p_is_interface) { + *p_is_interface = true; + } + } else { + ret = NewString("uintptr"); + } + } else { + ret = NewString("*"); + Append(ret, base); + Delete(base); + } + } + + Delete(r); + } else if (SwigType_isreference(t)) { + SwigType *r = Copy(t); + SwigType_del_reference(r); + + // If this is a const reference, and we are looking at a pointer + // to it, then we just use the pointer we already have. + bool add_pointer = true; + if (SwigType_isqualifier(r)) { + String *q = SwigType_parm(r); + if (Strcmp(q, "const") == 0) { + SwigType *c = Copy(r); + SwigType_del_qualifier(c); + if (SwigType_ispointer(c)) { + add_pointer = false; + } + Delete(c); + } + } + if (add_pointer) { + SwigType_add_pointer(r); + } + ret = goTypeWithInfo(n, r, false, p_is_interface); + Delete(r); + } else if (SwigType_isqualifier(t)) { + SwigType *r = Copy(t); + SwigType_del_qualifier(r); + ret = goTypeWithInfo(n, r, false, p_is_interface); + Delete(r); + } else if (SwigType_isvarargs(t)) { + ret = NewString("[]interface{}"); + } + + Delete(t); + + if (!ret) { + Swig_warning(WARN_LANG_NATIVE_UNIMPL, input_file, line_number, "No Go typemap defined for %s\n", SwigType_str(type, 0)); + ret = NewString("uintptr"); + } + + return ret; + } + + /* ---------------------------------------------------------------------- + * goWrapperType() + * + * Given a type, return a string for the type to use for the wrapped + * Go function. This function exists because for a C++ class we + * need to convert interface and reference types. + * ---------------------------------------------------------------------- */ + + String *goWrapperType(Node *n, SwigType *type, bool is_result) { + bool is_interface; + String *ret = goTypeWithInfo(n, type, true, &is_interface); + + // If this is an interface, we want to pass the real type. + if (is_interface) { + Delete(ret); + if (!is_result) { + ret = NewString("uintptr"); + } else { + SwigType *ty = SwigType_typedef_resolve_all(type); + while (true) { + if (SwigType_ispointer(ty)) { + SwigType_del_pointer(ty); + } else if (SwigType_isarray(ty)) { + SwigType_del_array(ty); + } else if (SwigType_isreference(ty)) { + SwigType_del_reference(ty); + } else if (SwigType_isqualifier(ty)) { + SwigType_del_qualifier(ty); + } else { + break; + } + } + assert(SwigType_issimple(ty)); + String *p = goCPointerType(ty, true); + Delete(ty); + ret = p; + } + } + + return ret; + } + + /* ---------------------------------------------------------------------- + * goCPointerType() + * + * Return the name of the Go type to use for the C pointer value. + * The regular C type is the name of an interface type which wraps a + * pointer whose name is returned by this function. + * ---------------------------------------------------------------------- */ + + String *goCPointerType(SwigType *type, bool add_to_hash) { + SwigType *ty = SwigType_typedef_resolve_all(type); + Node *cn = classLookup(ty); + String *ex; + String *ret; + if (!cn) { + if (add_to_hash) { + Setattr(undefined_types, ty, ty); + } + ret = NewString("Swigcptr"); + ex = exportedName(ty); + Append(ret, ex); + } else { + String *cname = Getattr(cn, "sym:name"); + if (!cname) { + cname = Getattr(cn, "name"); + } + ex = exportedName(cname); + Node *cnmod = Getattr(cn, "module"); + if (!cnmod || Strcmp(Getattr(cnmod, "name"), module) == 0) { + if (add_to_hash) { + Setattr(undefined_types, ty, ty); + } + ret = NewString("Swigcptr"); + Append(ret, ex); + } else { + ret = NewString(""); + Printv(ret, Getattr(cnmod, "name"), ".Swigcptr", ex, NULL); + } + } + Delete(ty); + Delete(ex); + return ret; + } + + /* ---------------------------------------------------------------------- + * gcCTypeForGoValue() + * + * Given a type, return the C/C++ type which will be used to catch + * the value in Go. This is the 6g/8g version. + * ---------------------------------------------------------------------- */ + + String *gcCTypeForGoValue(Node *n, SwigType *type, String *name) { + bool is_interface; + String *gt = goTypeWithInfo(n, type, true, &is_interface); + + String *tail = NewString(""); + SwigType *t = SwigType_typedef_resolve_all(type); + if (!SwigType_isreference(t)) { + while (Strncmp(gt, "*", 1) == 0) { + Replace(gt, "*", "", DOH_REPLACE_FIRST); + Printv(tail, "*", NULL); + } + } + Delete(t); + + bool is_string = Strcmp(gt, "string") == 0; + bool is_slice = Strncmp(gt, "[]", 2) == 0; + bool is_function = Strcmp(gt, "_swig_fnptr") == 0; + bool is_member = Strcmp(gt, "_swig_memberptr") == 0; + bool is_complex64 = Strcmp(gt, "complex64") == 0; + bool is_complex128 = Strcmp(gt, "complex128") == 0; + bool is_int8 = false; + bool is_int16 = false; + bool is_int = Strcmp(gt, "int") == 0 || Strcmp(gt, "uint") == 0; + bool is_int32 = false; + bool is_int64 = false; + bool is_float32 = false; + bool is_float64 = false; + if ((n != NULL && Getattr(n, "tmap:gotype") != NULL) || hasGoTypemap(n, type)) { + is_int8 = Strcmp(gt, "int8") == 0 || Strcmp(gt, "uint8") == 0 || Strcmp(gt, "byte") == 0; + is_int16 = Strcmp(gt, "int16") == 0 || Strcmp(gt, "uint16") == 0; + is_int32 = Strcmp(gt, "int32") == 0 || Strcmp(gt, "uint32") == 0; + is_int64 = Strcmp(gt, "int64") == 0 || Strcmp(gt, "uint64") == 0; + is_float32 = Strcmp(gt, "float32") == 0; + is_float64 = Strcmp(gt, "float64") == 0; + } + Delete(gt); + + String *ret; + if (is_string) { + // Note that we don't turn a reference to a string into a + // pointer to a string. Strings are immutable anyhow. + ret = NewString(""); + Printv(ret, "_gostring_", tail, " ", name, NULL); + Delete(tail); + return ret; + } else if (is_slice) { + // Slices are always passed as a _goslice_, whether or not references + // are involved. + ret = NewString(""); + Printv(ret, "_goslice_", tail, " ", name, NULL); + Delete(tail); + return ret; + } else if (is_function || is_member) { + ret = NewString(""); + Printv(ret, "void*", tail, " ", name, NULL); + Delete(tail); + return ret; + } else if (is_complex64) { + ret = NewString("_Complex float "); + } else if (is_complex128) { + ret = NewString("_Complex double "); + } else if (is_interface) { + SwigType *t = SwigType_typedef_resolve_all(type); + if (SwigType_ispointer(t)) { + SwigType_del_pointer(t); + } + if (SwigType_isreference(t)) { + SwigType_del_reference(t); + } + SwigType_add_pointer(t); + ret = SwigType_lstr(t, name); + Delete(t); + Delete(tail); + return ret; + } else { + SwigType *t = SwigType_typedef_resolve_all(type); + if (SwigType_isreference(t)) { + // A const reference to a known type, or to a pointer, is not + // mapped to a pointer. + SwigType_del_reference(t); + if (SwigType_isqualifier(t)) { + String *q = SwigType_parm(t); + if (Strcmp(q, "const") == 0) { + SwigType_del_qualifier(t); + if (hasGoTypemap(n, t) || SwigType_ispointer(t)) { + if (is_int) { + ret = NewString("intgo "); + Append(ret, name); + } else if (is_int64) { + ret = NewString("long long "); + Append(ret, name); + } else { + ret = SwigType_lstr(t, name); + } + Delete(q); + Delete(t); + Delete(tail); + return ret; + } + } + Delete(q); + } + } + + if (Language::enumLookup(t) != NULL) { + is_int = true; + } else { + SwigType *tstripped = SwigType_strip_qualifiers(t); + if (SwigType_isenum(tstripped)) + is_int = true; + Delete(tstripped); + } + + Delete(t); + if (is_int8) { + ret = NewString("char "); + } else if (is_int16) { + ret = NewString("short "); + } else if (is_int) { + ret = NewString("intgo "); + } else if (is_int32) { + ret = NewString("int "); + } else if (is_int64) { + ret = NewString("long long "); + } else if (is_float32) { + ret = NewString("float "); + } else if (is_float64) { + ret = NewString("double "); + } else { + Delete(tail); + return SwigType_lstr(type, name); + } + } + + Append(ret, tail); + if (SwigType_isreference(type)) { + Append(ret, "* "); + } + Append(ret, name); + Delete(tail); + return ret; + } + + /* ---------------------------------------------------------------------- + * gccgoCTypeForGoValue() + * + * Given a type, return the C/C++ type which will be used to catch + * the value in Go. This is the gccgo version. + * ---------------------------------------------------------------------- */ + + String *gccgoCTypeForGoValue(Node *n, SwigType *type, String *name) { + return gcCTypeForGoValue(n, type, name); + } + + /* ---------------------------------------------------------------------- + * goTypeIsInterface + * + * Return whether this C++ type is represented as an interface type + * in Go. These types require adjustments in the Go code when + * passing them back and forth between Go and C++. + * ---------------------------------------------------------------------- */ + + bool goTypeIsInterface(Node *n, SwigType *type) { + bool is_interface; + Delete(goTypeWithInfo(n, type, false, &is_interface)); + return is_interface; + } + + /* ---------------------------------------------------------------------- + * hasGoTypemap + * + * Return whether a type has a "gotype" typemap entry. + * ---------------------------------------------------------------------- */ + + bool hasGoTypemap(Node *n, SwigType *type) { + Parm *p = NewParm(type, "test", n); + SwigType *tm = Swig_typemap_lookup("gotype", p, "", NULL); + Delete(p); + if (tm && Strstr(tm, "$gotypename") == 0) { + Delete(tm); + return true; + } + Delete(tm); + return false; + } + + /* ---------------------------------------------------------------------- + * goEnumName() + * + * Given an enum node, return a string to use for the enum type in Go. + * ---------------------------------------------------------------------- */ + + String *goEnumName(Node *n) { + String *ret = Getattr(n, "go:enumname"); + if (ret) { + return Copy(ret); + } + + if (Equal(Getattr(n, "type"), "enum ")) { + return NewString("int"); + } + + String *type = Getattr(n, "enumtype"); + assert(type); + char *p = Char(type); + int len = Len(type); + String *s = NewString(""); + bool capitalize = true; + for (int i = 0; i < len; ++i, ++p) { + if (*p == ':') { + ++i; + ++p; + assert(*p == ':'); + capitalize = true; + } else if (capitalize) { + Putc(toupper(*p), s); + capitalize = false; + } else { + Putc(*p, s); + } + } + + ret = Swig_name_mangle(s); + Delete(s); + return ret; + } + + + /* ---------------------------------------------------------------------- + * getParm() + * + * Get the real parameter to use. + * ---------------------------------------------------------------------- */ + + Parm *getParm(Parm *p) { + while (p && checkAttribute(p, "tmap:in:numinputs", "0")) { + p = Getattr(p, "tmap:in:next"); + } + return p; + } + + /* ---------------------------------------------------------------------- + * nextParm() + * + * Return the next parameter. + * ---------------------------------------------------------------------- */ + + Parm *nextParm(Parm *p) { + if (!p) { + return NULL; + } else if (Getattr(p, "tmap:in")) { + return Getattr(p, "tmap:in:next"); + } else { + return nextSibling(p); + } + } + + /* ---------------------------------------------------------------------- + * isStatic + * + * Return whether a node should be considered as static rather than + * as a member. + * ---------------------------------------------------------------------- */ + + bool isStatic(Node *n) { + String *storage = Getattr(n, "storage"); + return (storage && (Swig_storage_isstatic(n) || Strcmp(storage, "friend") == 0) && (!SmartPointer || !Getattr(n, "allocate:smartpointeraccess"))); + } + + /* ---------------------------------------------------------------------- + * isFriend + * + * Return whether a node is a friend. + * ---------------------------------------------------------------------- */ + + bool isFriend(Node *n) { + String *storage = Getattr(n, "storage"); + return storage && Strcmp(storage, "friend") == 0; + } + +}; /* class GO */ + +/* ----------------------------------------------------------------------------- + * swig_go() - Instantiate module + * ----------------------------------------------------------------------------- */ + +static Language *new_swig_go() { + return new GO(); +} +extern "C" Language *swig_go(void) { + return new_swig_go(); +} + +/* ----------------------------------------------------------------------------- + * Static member variables + * ----------------------------------------------------------------------------- */ + +// Usage message. +const char * const GO::usage = "\ +Go Options (available with -go)\n\ + -gccgo - Generate code for gccgo rather than 6g/8g\n\ + -go-pkgpath

    - Like gccgo -fgo-pkgpath option\n\ + -go-prefix

    - Like gccgo -fgo-prefix option\n\ + -intgosize - Set size of Go int type--32 or 64 bits\n\ + -package - Set name of the Go package to \n\ + -use-shlib - Force use of a shared library\n\ + -soname - Set shared library holding C/C++ code to \n\ +\n"; -- cgit v1.2.1 From d0b6a4bfc59f95908b1c303b19981f3f924b3986 Mon Sep 17 00:00:00 2001 From: Anthony Li Date: Mon, 6 Oct 2014 19:35:33 +0800 Subject: del tmp files --- .../import_packages/relativeimport2/runme3.py | 9 - Examples/test-suite/common.mk~ | 746 --- Examples/test-suite/go/abstract_access.go | 311 -- Examples/test-suite/go/abstract_access_runme | Bin 588366 -> 0 bytes Examples/test-suite/go/abstract_inherit.go | 285 -- Examples/test-suite/go/abstract_inherit_ok.go | 136 - Examples/test-suite/go/abstract_signature.go | 147 - Examples/test-suite/go/abstract_typedef.go | 174 - Examples/test-suite/go/abstract_typedef2.go | 184 - Examples/test-suite/go/abstract_typedef2_runme | Bin 548637 -> 0 bytes Examples/test-suite/go/abstract_typedef_runme | Bin 541892 -> 0 bytes Examples/test-suite/go/abstract_virtual.go | 348 -- Examples/test-suite/go/abstract_virtual_runme | Bin 600891 -> 0 bytes Examples/test-suite/go/access_change.go | 438 -- Examples/test-suite/go/add_link.go | 88 - Examples/test-suite/go/aggregate.go | 40 - Examples/test-suite/go/allowexcept.go | 241 - Examples/test-suite/go/allprotected.go | 681 --- Examples/test-suite/go/allprotected_not.go | 88 - Examples/test-suite/go/allprotected_not_wrap.h | 16 - Examples/test-suite/go/allprotected_wrap.h | 51 - Examples/test-suite/go/anonymous_bitfield.go | 205 - Examples/test-suite/go/apply_signed_char.go | 358 -- Examples/test-suite/go/apply_signed_char_wrap.h | 37 - Examples/test-suite/go/apply_strings.go | 587 --- Examples/test-suite/go/apply_strings_wrap.h | 49 - Examples/test-suite/go/argout.go | 122 - Examples/test-suite/go/argout_runme | Bin 509880 -> 0 bytes Examples/test-suite/go/array_member.go | 586 --- Examples/test-suite/go/array_member_runme | Bin 550490 -> 0 bytes Examples/test-suite/go/array_typedef_memberin.go | 328 -- Examples/test-suite/go/arrayref.go | 61 - Examples/test-suite/go/arrays.go | 750 --- Examples/test-suite/go/arrays_dimensionless.go | 292 -- Examples/test-suite/go/arrays_global.go | 729 --- Examples/test-suite/go/arrays_global_runme | Bin 567485 -> 0 bytes Examples/test-suite/go/arrays_global_twodim.go | 621 --- Examples/test-suite/go/arrays_scope.go | 190 - Examples/test-suite/go/autodoc.go | 933 ---- Examples/test-suite/go/bloody_hell.go | 102 - Examples/test-suite/go/bom_utf8.go | 101 - Examples/test-suite/go/bools.go | 370 -- Examples/test-suite/go/c_delete.go | 120 - Examples/test-suite/go/c_delete_function.go | 36 - Examples/test-suite/go/cast_operator.go | 88 - Examples/test-suite/go/casts.go | 148 - Examples/test-suite/go/catches.go | 111 - Examples/test-suite/go/char_binary.go | 164 - Examples/test-suite/go/char_binary_runme | Bin 522506 -> 0 bytes Examples/test-suite/go/char_constant.go | 69 - Examples/test-suite/go/char_strings.go | 302 -- Examples/test-suite/go/class_forward.go | 122 - Examples/test-suite/go/class_ignore.go | 262 - Examples/test-suite/go/class_ignore_runme | Bin 527776 -> 0 bytes Examples/test-suite/go/class_scope_weird.go | 218 - Examples/test-suite/go/class_scope_weird_runme | Bin 524253 -> 0 bytes Examples/test-suite/go/clientdata_prop_a.go | 124 - Examples/test-suite/go/clientdata_prop_b.go | 389 -- Examples/test-suite/go/compactdefaultargs.go | 226 - Examples/test-suite/go/compactdefaultargs_runme | Bin 551975 -> 0 bytes Examples/test-suite/go/const_const.go | 49 - Examples/test-suite/go/const_const_2.go | 126 - Examples/test-suite/go/constant_expr.go | 71 - Examples/test-suite/go/constant_pointers.go | 1327 ----- Examples/test-suite/go/constover.go | 141 - Examples/test-suite/go/constover_runme | Bin 1879569 -> 0 bytes Examples/test-suite/go/constructor_copy.go | 1012 ---- Examples/test-suite/go/constructor_copy_runme | Bin 598598 -> 0 bytes Examples/test-suite/go/constructor_exception.go | 151 - Examples/test-suite/go/constructor_explicit.go | 110 - Examples/test-suite/go/constructor_ignore.go | 205 - Examples/test-suite/go/constructor_rename.go | 75 - Examples/test-suite/go/constructor_value.go | 113 - Examples/test-suite/go/contract.go | 625 --- Examples/test-suite/go/contract_runme | Bin 684277 -> 0 bytes Examples/test-suite/go/conversion.go | 126 - Examples/test-suite/go/conversion_namespace.go | 126 - Examples/test-suite/go/conversion_ns_template.go | 194 - Examples/test-suite/go/cplusplus_throw.go | 128 - Examples/test-suite/go/cpp_basic.go | 804 --- Examples/test-suite/go/cpp_enum.go | 354 -- Examples/test-suite/go/cpp_enum_runme | Bin 545574 -> 0 bytes Examples/test-suite/go/cpp_namespace.go | 418 -- Examples/test-suite/go/cpp_namespace_runme | Bin 616236 -> 0 bytes Examples/test-suite/go/cpp_nodefault.go | 213 - Examples/test-suite/go/cpp_static.go | 168 - Examples/test-suite/go/cpp_static_runme | Bin 510223 -> 0 bytes Examples/test-suite/go/cpp_typedef.go | 352 -- .../go/curiously_recurring_template_pattern.go | 278 - Examples/test-suite/go/default_arg_values.go | 154 - Examples/test-suite/go/default_args.go | 1719 ------- Examples/test-suite/go/default_args_runme | Bin 669530 -> 0 bytes Examples/test-suite/go/default_constructor.go | 902 ---- Examples/test-suite/go/default_constructor_runme | Bin 669024 -> 0 bytes Examples/test-suite/go/defvalue_constructor.go | 136 - Examples/test-suite/go/derived_byvalue.go | 316 -- Examples/test-suite/go/derived_nested.go | 232 - Examples/test-suite/go/destructor_reprotected.go | 154 - Examples/test-suite/go/director_abstract.go | 1331 ----- Examples/test-suite/go/director_abstract_wrap.h | 99 - Examples/test-suite/go/director_alternating.go | 328 -- Examples/test-suite/go/director_alternating_runme | Bin 557938 -> 0 bytes Examples/test-suite/go/director_alternating_wrap.h | 29 - Examples/test-suite/go/director_basic.go | 1420 ------ Examples/test-suite/go/director_basic_runme | Bin 836295 -> 0 bytes Examples/test-suite/go/director_basic_wrap.h | 83 - Examples/test-suite/go/director_binary_string.go | 267 - .../test-suite/go/director_binary_string_wrap.h | 29 - Examples/test-suite/go/director_classes.go | 1871 ------- Examples/test-suite/go/director_classes_wrap.h | 132 - Examples/test-suite/go/director_classic.go | 1102 ---- Examples/test-suite/go/director_classic_runme | Bin 2257665 -> 0 bytes Examples/test-suite/go/director_classic_wrap.h | 94 - Examples/test-suite/go/director_constructor.go | 290 -- Examples/test-suite/go/director_constructor_wrap.h | 34 - Examples/test-suite/go/director_default.go | 875 ---- Examples/test-suite/go/director_default_runme | Bin 750890 -> 0 bytes Examples/test-suite/go/director_default_wrap.h | 62 - Examples/test-suite/go/director_detect.go | 581 --- Examples/test-suite/go/director_detect_runme | Bin 661368 -> 0 bytes Examples/test-suite/go/director_detect_wrap.h | 54 - Examples/test-suite/go/director_enum.go | 1436 ------ Examples/test-suite/go/director_enum_runme | Bin 848743 -> 0 bytes Examples/test-suite/go/director_enum_wrap.h | 114 - Examples/test-suite/go/director_exception.go | 1066 ---- Examples/test-suite/go/director_exception_runme | Bin 822448 -> 0 bytes Examples/test-suite/go/director_exception_wrap.h | 87 - Examples/test-suite/go/director_extend.go | 101 - Examples/test-suite/go/director_extend_runme | Bin 517522 -> 0 bytes Examples/test-suite/go/director_extend_wrap.h | 16 - Examples/test-suite/go/director_finalizer.go | 206 - Examples/test-suite/go/director_finalizer_runme | Bin 547717 -> 0 bytes Examples/test-suite/go/director_finalizer_wrap.h | 29 - Examples/test-suite/go/director_frob.go | 1493 ------ Examples/test-suite/go/director_frob_runme | Bin 911559 -> 0 bytes Examples/test-suite/go/director_frob_wrap.h | 120 - Examples/test-suite/go/director_ignore.go | 810 --- Examples/test-suite/go/director_ignore_wrap.h | 101 - Examples/test-suite/go/director_keywords.go | 175 - Examples/test-suite/go/director_keywords_wrap.h | 29 - Examples/test-suite/go/director_namespace_clash.go | 313 -- .../test-suite/go/director_namespace_clash_wrap.h | 42 - Examples/test-suite/go/director_nested.go | 662 --- Examples/test-suite/go/director_nested_runme | Bin 728500 -> 0 bytes Examples/test-suite/go/director_nested_wrap.h | 65 - Examples/test-suite/go/director_nspace.go | 450 -- .../go/director_nspace_director_name_collision.go | 180 - .../director_nspace_director_name_collision_wrap.h | 29 - Examples/test-suite/go/director_nspace_wrap.h | 45 - Examples/test-suite/go/director_overload.go | 862 ---- Examples/test-suite/go/director_overload2.go | 727 --- Examples/test-suite/go/director_overload2_wrap.h | 79 - Examples/test-suite/go/director_overload_wrap.h | 78 - Examples/test-suite/go/director_primitives.go | 1368 ----- Examples/test-suite/go/director_primitives_wrap.h | 114 - Examples/test-suite/go/director_protected.go | 1081 ---- .../test-suite/go/director_protected_overloaded.go | 386 -- .../go/director_protected_overloaded_wrap.h | 42 - Examples/test-suite/go/director_protected_runme | Bin 793371 -> 0 bytes Examples/test-suite/go/director_protected_wrap.h | 97 - Examples/test-suite/go/director_redefined.go | 312 -- Examples/test-suite/go/director_redefined_wrap.h | 33 - Examples/test-suite/go/director_smartptr.go | 29 - Examples/test-suite/go/director_smartptr_wrap.h | 16 - Examples/test-suite/go/director_string.go | 609 --- Examples/test-suite/go/director_string_runme | Bin 761946 -> 0 bytes Examples/test-suite/go/director_string_wrap.h | 49 - Examples/test-suite/go/director_thread.go | 239 - Examples/test-suite/go/director_thread_wrap.h | 29 - Examples/test-suite/go/director_unroll.go | 290 -- Examples/test-suite/go/director_unroll_runme | Bin 589423 -> 0 bytes Examples/test-suite/go/director_unroll_wrap.h | 33 - Examples/test-suite/go/director_using.go | 969 ---- Examples/test-suite/go/director_using_wrap.h | 90 - Examples/test-suite/go/director_wombat.go | 528 -- Examples/test-suite/go/director_wombat_wrap.h | 62 - Examples/test-suite/go/disown.go | 139 - Examples/test-suite/go/disown_runme | Bin 533821 -> 0 bytes Examples/test-suite/go/dynamic_cast.go | 178 - Examples/test-suite/go/dynamic_cast_runme | Bin 540102 -> 0 bytes Examples/test-suite/go/empty.go | 29 - Examples/test-suite/go/empty_runme | Bin 492692 -> 0 bytes Examples/test-suite/go/enum_forward.go | 90 - Examples/test-suite/go/enum_ignore.go | 129 - Examples/test-suite/go/enum_macro.go | 226 - Examples/test-suite/go/enum_missing.go | 196 - Examples/test-suite/go/enum_plus.go | 83 - Examples/test-suite/go/enum_rename.go | 71 - Examples/test-suite/go/enum_scope_template.go | 120 - Examples/test-suite/go/enum_template.go | 119 - Examples/test-suite/go/enum_template_runme | Bin 508847 -> 0 bytes Examples/test-suite/go/enum_thorough.go | 4294 ---------------- Examples/test-suite/go/enum_var.go | 73 - Examples/test-suite/go/enums.go | 507 -- Examples/test-suite/go/enums_runme | Bin 557870 -> 0 bytes Examples/test-suite/go/equality.go | 336 -- Examples/test-suite/go/evil_diamond.go | 250 - Examples/test-suite/go/evil_diamond_ns.go | 250 - Examples/test-suite/go/evil_diamond_prop.go | 484 -- Examples/test-suite/go/exception_order.go | 441 -- Examples/test-suite/go/exception_order_runme | Bin 794098 -> 0 bytes Examples/test-suite/go/expressions.go | 124 - Examples/test-suite/go/extend.go | 308 -- .../test-suite/go/extend_constructor_destructor.go | 504 -- Examples/test-suite/go/extend_default.go | 1696 ------ Examples/test-suite/go/extend_placement.go | 815 --- Examples/test-suite/go/extend_placement_runme | Bin 719478 -> 0 bytes Examples/test-suite/go/extend_special_variables.go | 162 - Examples/test-suite/go/extend_template.go | 101 - Examples/test-suite/go/extend_template_ns.go | 118 - Examples/test-suite/go/extend_template_ns_runme | Bin 520955 -> 0 bytes Examples/test-suite/go/extend_template_runme | Bin 514820 -> 0 bytes Examples/test-suite/go/extend_typedef_class.go | 653 --- Examples/test-suite/go/extern_c.go | 49 - Examples/test-suite/go/extern_c_runme | Bin 497595 -> 0 bytes Examples/test-suite/go/extern_declaration.go | 50 - Examples/test-suite/go/extern_namespace.go | 61 - Examples/test-suite/go/extern_throws.go | 36 - Examples/test-suite/go/features.go | 834 --- Examples/test-suite/go/fragments.go | 43 - Examples/test-suite/go/friends.go | 451 -- Examples/test-suite/go/friends_runme | Bin 584905 -> 0 bytes Examples/test-suite/go/funcptr.go | 338 -- Examples/test-suite/go/funcptr_cpp.go | 116 - Examples/test-suite/go/function_typedef.go | 50 - Examples/test-suite/go/fvirtual.go | 171 - Examples/test-suite/go/fvirtual_runme | Bin 546754 -> 0 bytes Examples/test-suite/go/global_functions.go | 63 - Examples/test-suite/go/global_namespace.go | 1039 ---- Examples/test-suite/go/global_ns_arg.go | 43 - Examples/test-suite/go/global_ns_arg_runme | Bin 498924 -> 0 bytes Examples/test-suite/go/global_scope_types.go | 194 - Examples/test-suite/go/global_vars.go | 378 -- Examples/test-suite/go/go_director_inout.go | 360 -- Examples/test-suite/go/go_director_inout_runme | Bin 2471045 -> 0 bytes Examples/test-suite/go/go_director_inout_wrap.h | 29 - Examples/test-suite/go/go_inout.go | 355 -- Examples/test-suite/go/go_inout_runme | Bin 2567812 -> 0 bytes Examples/test-suite/go/grouping.go | 92 - Examples/test-suite/go/grouping_runme | Bin 508721 -> 0 bytes Examples/test-suite/go/ignore_parameter.go | 307 -- .../test-suite/go/ignore_template_constructor.go | 275 - Examples/test-suite/go/immutable_values.go | 81 - Examples/test-suite/go/import_nomodule.go | 128 - Examples/test-suite/go/import_nomodule_runme | Bin 523381 -> 0 bytes Examples/test-suite/go/import_stl_a.go | 202 - Examples/test-suite/go/import_stl_b.go | 42 - Examples/test-suite/go/imports_a.go | 155 - Examples/test-suite/go/imports_b.go | 264 - Examples/test-suite/go/imports_runme | Bin 576059 -> 0 bytes Examples/test-suite/go/inctest.go | 307 -- Examples/test-suite/go/inctest_runme | Bin 538591 -> 0 bytes Examples/test-suite/go/infinity.go | 63 - Examples/test-suite/go/inherit.go | 155 - Examples/test-suite/go/inherit_missing.go | 192 - Examples/test-suite/go/inherit_missing_runme | Bin 548217 -> 0 bytes Examples/test-suite/go/inherit_same_name.go | 204 - Examples/test-suite/go/inherit_target_language.go | 714 --- Examples/test-suite/go/inherit_void_arg.go | 136 - Examples/test-suite/go/inline_initializer.go | 75 - Examples/test-suite/go/insert_directive.go | 29 - Examples/test-suite/go/integers.go | 169 - Examples/test-suite/go/keyword_rename.go | 185 - Examples/test-suite/go/keyword_rename_runme | Bin 506488 -> 0 bytes Examples/test-suite/go/kind.go | 392 -- Examples/test-suite/go/langobj.go | 36 - Examples/test-suite/go/lextype.go | 70 - Examples/test-suite/go/li_attribute.go | 576 --- Examples/test-suite/go/li_attribute_runme | Bin 676775 -> 0 bytes Examples/test-suite/go/li_attribute_template.go | 411 -- Examples/test-suite/go/li_boost_shared_ptr.go | 1856 ------- .../test-suite/go/li_boost_shared_ptr_attribute.go | 29 - Examples/test-suite/go/li_boost_shared_ptr_bits.go | 417 -- .../test-suite/go/li_boost_shared_ptr_template.go | 343 -- Examples/test-suite/go/li_carrays.go | 529 -- Examples/test-suite/go/li_carrays_runme | Bin 538624 -> 0 bytes Examples/test-suite/go/li_cdata.go | 104 - Examples/test-suite/go/li_cdata_runme | Bin 508616 -> 0 bytes Examples/test-suite/go/li_cmalloc.go | 272 - Examples/test-suite/go/li_cmalloc_runme | Bin 524326 -> 0 bytes Examples/test-suite/go/li_constraints.go | 109 - Examples/test-suite/go/li_cpointer.go | 178 - Examples/test-suite/go/li_cpointer_runme | Bin 508241 -> 0 bytes Examples/test-suite/go/li_math.go | 175 - Examples/test-suite/go/li_std_auto_ptr.go | 29 - Examples/test-suite/go/li_std_combinations.go | 1374 ----- Examples/test-suite/go/li_std_deque.go | 1174 ----- Examples/test-suite/go/li_std_except.go | 346 -- Examples/test-suite/go/li_std_except_as_class.go | 49 - Examples/test-suite/go/li_std_map.go | 2700 ---------- Examples/test-suite/go/li_std_map_runme | Bin 1525723 -> 0 bytes Examples/test-suite/go/li_std_pair.go | 249 - Examples/test-suite/go/li_std_pair_using.go | 305 -- Examples/test-suite/go/li_std_string.go | 487 -- Examples/test-suite/go/li_std_vector.go | 3412 ------------- Examples/test-suite/go/li_std_vector_enum.go | 304 -- Examples/test-suite/go/li_std_vector_member_var.go | 459 -- Examples/test-suite/go/li_stdint.go | 943 ---- Examples/test-suite/go/li_swigtype_inout.go | 218 - Examples/test-suite/go/li_typemaps.go | 931 ---- Examples/test-suite/go/li_typemaps_apply.go | 575 --- Examples/test-suite/go/li_windows.go | 624 --- Examples/test-suite/go/long_long.go | 195 - Examples/test-suite/go/long_long_apply.go | 241 - Examples/test-suite/go/member_funcptr_galore.go | 432 -- Examples/test-suite/go/member_pointer.go | 737 --- Examples/test-suite/go/member_pointer_runme | Bin 1981129 -> 0 bytes Examples/test-suite/go/member_template.go | 165 - Examples/test-suite/go/memberin_extend.go | 101 - Examples/test-suite/go/memberin_extend_c.go | 101 - Examples/test-suite/go/memberin_extend_c_runme | Bin 516040 -> 0 bytes Examples/test-suite/go/minherit.go | 612 --- Examples/test-suite/go/minherit2.go | 201 - Examples/test-suite/go/minherit_runme | Bin 2037550 -> 0 bytes Examples/test-suite/go/mixed_types.go | 839 --- Examples/test-suite/go/mod_a.go | 182 - Examples/test-suite/go/mod_b.go | 211 - Examples/test-suite/go/mod_runme | Bin 564071 -> 0 bytes Examples/test-suite/go/multi_import_a.go | 111 - Examples/test-suite/go/multi_import_b.go | 161 - Examples/test-suite/go/multi_import_runme | Bin 540010 -> 0 bytes Examples/test-suite/go/multiple_inheritance.go | 718 --- Examples/test-suite/go/name.go | 69 - Examples/test-suite/go/name_cxx.go | 146 - Examples/test-suite/go/name_warnings.go | 169 - Examples/test-suite/go/namespace_class.go | 1280 ----- Examples/test-suite/go/namespace_class_runme | Bin 604515 -> 0 bytes Examples/test-suite/go/namespace_enum.go | 117 - Examples/test-suite/go/namespace_extend.go | 88 - .../test-suite/go/namespace_forward_declaration.go | 211 - Examples/test-suite/go/namespace_nested.go | 339 -- Examples/test-suite/go/namespace_spaces.go | 140 - Examples/test-suite/go/namespace_template.go | 269 - Examples/test-suite/go/namespace_typedef_class.go | 165 - Examples/test-suite/go/namespace_typemap.go | 204 - Examples/test-suite/go/namespace_typemap_runme | Bin 558723 -> 0 bytes Examples/test-suite/go/namespace_union.go | 101 - Examples/test-suite/go/namespace_virtual_method.go | 144 - .../test-suite/go/namespace_virtual_method_runme | Bin 533161 -> 0 bytes Examples/test-suite/go/naturalvar.go | 234 - Examples/test-suite/go/naturalvar_more.go | 506 -- Examples/test-suite/go/naturalvar_onoff.go | 383 -- Examples/test-suite/go/naturalvar_runme | Bin 566774 -> 0 bytes Examples/test-suite/go/nested.go | 910 ---- Examples/test-suite/go/nested_class.go | 850 --- Examples/test-suite/go/nested_comment.go | 113 - Examples/test-suite/go/nested_directors.go | 299 -- Examples/test-suite/go/nested_directors_wrap.h | 41 - Examples/test-suite/go/nested_extend_c.go | 875 ---- Examples/test-suite/go/nested_scope.go | 203 - Examples/test-suite/go/nested_structs.go | 470 -- Examples/test-suite/go/nested_workaround.go | 201 - Examples/test-suite/go/nested_workaround_runme | Bin 549486 -> 0 bytes Examples/test-suite/go/newobject1.go | 95 - Examples/test-suite/go/newobject2.go | 132 - Examples/test-suite/go/nspace.go | 29 - Examples/test-suite/go/nspace_extend.go | 29 - Examples/test-suite/go/null_pointer.go | 99 - Examples/test-suite/go/operator_overload.go | 1152 ----- Examples/test-suite/go/operator_overload_break.go | 287 -- Examples/test-suite/go/operator_pointer_ref.go | 111 - Examples/test-suite/go/operbool.go | 88 - Examples/test-suite/go/ordering.go | 101 - Examples/test-suite/go/overload_bool.go | 143 - Examples/test-suite/go/overload_copy.go | 98 - Examples/test-suite/go/overload_copy_runme | Bin 515303 -> 0 bytes Examples/test-suite/go/overload_extend.go | 248 - Examples/test-suite/go/overload_extend_runme | Bin 546049 -> 0 bytes Examples/test-suite/go/overload_extendc.go | 226 - Examples/test-suite/go/overload_extendc_runme | Bin 556881 -> 0 bytes Examples/test-suite/go/overload_method.go | 125 - Examples/test-suite/go/overload_numeric.go | 340 -- Examples/test-suite/go/overload_polymorphic.go | 156 - Examples/test-suite/go/overload_polymorphic_runme | Bin 535619 -> 0 bytes .../test-suite/go/overload_polymorphic_runme.go~ | 11 - Examples/test-suite/go/overload_rename.go | 133 - Examples/test-suite/go/overload_rename_runme | Bin 528035 -> 0 bytes Examples/test-suite/go/overload_return_type.go | 215 - Examples/test-suite/go/overload_simple.go | 1060 ---- Examples/test-suite/go/overload_simple_runme | Bin 693717 -> 0 bytes Examples/test-suite/go/overload_subtype.go | 161 - Examples/test-suite/go/overload_subtype_runme | Bin 531236 -> 0 bytes Examples/test-suite/go/overload_template.go | 1185 ----- Examples/test-suite/go/overload_template_fast.go | 1185 ----- .../test-suite/go/overload_template_fast_runme | Bin 704179 -> 0 bytes Examples/test-suite/go/overload_template_runme | Bin 700912 -> 0 bytes Examples/test-suite/go/packageoption_a.go | 152 - Examples/test-suite/go/packageoption_b.go | 88 - Examples/test-suite/go/packageoption_c.go | 111 - Examples/test-suite/go/pointer_reference.go | 219 - Examples/test-suite/go/preproc.go | 403 -- Examples/test-suite/go/preproc_constants.go | 246 - Examples/test-suite/go/preproc_constants_c.go | 246 - Examples/test-suite/go/preproc_defined.go | 144 - Examples/test-suite/go/preproc_include.go | 84 - Examples/test-suite/go/preproc_line_file.go | 316 -- Examples/test-suite/go/preproc_runme | Bin 543428 -> 0 bytes Examples/test-suite/go/primitive_ref.go | 233 - Examples/test-suite/go/primitive_ref_runme | Bin 539354 -> 0 bytes Examples/test-suite/go/private_assign.go | 190 - Examples/test-suite/go/protected_rename.go | 88 - Examples/test-suite/go/pure_virtual.go | 537 -- Examples/test-suite/go/redefined.go | 134 - Examples/test-suite/go/redefined_not.go | 29 - Examples/test-suite/go/refcount.go | 797 --- Examples/test-suite/go/refcount_runme | Bin 719525 -> 0 bytes Examples/test-suite/go/reference_global_vars.go | 756 --- Examples/test-suite/go/reference_global_vars_runme | Bin 667836 -> 0 bytes Examples/test-suite/go/register_par.go | 57 - Examples/test-suite/go/rename1.go | 1023 ---- Examples/test-suite/go/rename2.go | 1023 ---- Examples/test-suite/go/rename3.go | 1023 ---- Examples/test-suite/go/rename4.go | 1023 ---- Examples/test-suite/go/rename_pcre_encoder.go | 274 - Examples/test-suite/go/rename_pcre_enum.go | 96 - Examples/test-suite/go/rename_predicates.go | 424 -- Examples/test-suite/go/rename_scope.go | 300 -- Examples/test-suite/go/rename_scope_runme | Bin 558236 -> 0 bytes Examples/test-suite/go/rename_simple.go | 190 - Examples/test-suite/go/rename_simple_runme | Bin 1888165 -> 0 bytes Examples/test-suite/go/rename_strip_encoder.go | 126 - Examples/test-suite/go/rename_strip_encoder_runme | Bin 522623 -> 0 bytes Examples/test-suite/go/restrict_cplusplus.go | 101 - Examples/test-suite/go/ret_by_value.go | 139 - Examples/test-suite/go/ret_by_value_runme | Bin 523079 -> 0 bytes Examples/test-suite/go/return_const_value.go | 257 - Examples/test-suite/go/return_const_value_runme | Bin 551501 -> 0 bytes Examples/test-suite/go/return_value_scope.go | 164 - Examples/test-suite/go/rname.go | 292 -- Examples/test-suite/go/samename.go | 88 - Examples/test-suite/go/simple_array.go | 201 - Examples/test-suite/go/sizeof_pointer.go | 153 - Examples/test-suite/go/sizet.go | 57 - Examples/test-suite/go/smart_pointer_const.go | 204 - Examples/test-suite/go/smart_pointer_const2.go | 204 - .../test-suite/go/smart_pointer_const_overload.go | 805 --- Examples/test-suite/go/smart_pointer_extend.go | 1107 ---- Examples/test-suite/go/smart_pointer_extend_runme | Bin 737603 -> 0 bytes Examples/test-suite/go/smart_pointer_inherit.go | 1007 ---- Examples/test-suite/go/smart_pointer_member.go | 483 -- Examples/test-suite/go/smart_pointer_member_runme | Bin 1934344 -> 0 bytes Examples/test-suite/go/smart_pointer_multi.go | 384 -- Examples/test-suite/go/smart_pointer_multi_runme | Bin 601734 -> 0 bytes .../test-suite/go/smart_pointer_multi_typedef.go | 384 -- .../go/smart_pointer_multi_typedef_runme | Bin 605838 -> 0 bytes Examples/test-suite/go/smart_pointer_namespace.go | 267 - Examples/test-suite/go/smart_pointer_namespace2.go | 267 - Examples/test-suite/go/smart_pointer_not.go | 267 - Examples/test-suite/go/smart_pointer_overload.go | 296 -- .../test-suite/go/smart_pointer_overload_runme | Bin 578126 -> 0 bytes Examples/test-suite/go/smart_pointer_protected.go | 265 - Examples/test-suite/go/smart_pointer_rename.go | 191 - Examples/test-suite/go/smart_pointer_rename_runme | Bin 545731 -> 0 bytes Examples/test-suite/go/smart_pointer_simple.go | 204 - Examples/test-suite/go/smart_pointer_simple_runme | Bin 546795 -> 0 bytes Examples/test-suite/go/smart_pointer_static.go | 196 - .../go/smart_pointer_template_const_overload.go | 373 -- .../go/smart_pointer_template_defaults_overload.go | 748 --- .../test-suite/go/smart_pointer_templatemethods.go | 431 -- .../go/smart_pointer_templatevariables.go | 277 - .../go/smart_pointer_templatevariables_runme | Bin 557475 -> 0 bytes Examples/test-suite/go/smart_pointer_typedef.go | 204 - Examples/test-suite/go/smart_pointer_typedef_runme | Bin 546956 -> 0 bytes Examples/test-suite/go/sneaky1.go | 57 - Examples/test-suite/go/sneaky1_runme | Bin 502229 -> 0 bytes Examples/test-suite/go/special_variable_macros.go | 414 -- .../test-suite/go/special_variable_macros_runme | Bin 591344 -> 0 bytes Examples/test-suite/go/special_variables.go | 621 --- Examples/test-suite/go/special_variables_wrap.h | 29 - Examples/test-suite/go/static_array_member.go | 75 - Examples/test-suite/go/static_const_member.go | 107 - Examples/test-suite/go/static_const_member_2.go | 283 - Examples/test-suite/go/static_const_member_2_runme | Bin 558214 -> 0 bytes Examples/test-suite/go/string_simple.go | 36 - Examples/test-suite/go/struct_initialization.go | 709 --- .../test-suite/go/struct_initialization_cpp.go | 709 --- Examples/test-suite/go/struct_initialization_runme | Bin 586981 -> 0 bytes Examples/test-suite/go/struct_rename.go | 101 - Examples/test-suite/go/struct_rename_runme | Bin 513788 -> 0 bytes Examples/test-suite/go/struct_value.go | 191 - Examples/test-suite/go/struct_value_runme | Bin 537159 -> 0 bytes Examples/test-suite/go/symbol_clash.go | 29 - Examples/test-suite/go/template_arg_replace.go | 88 - Examples/test-suite/go/template_arg_scope.go | 96 - Examples/test-suite/go/template_arg_typename.go | 122 - Examples/test-suite/go/template_array_numeric.go | 110 - Examples/test-suite/go/template_base_template.go | 160 - Examples/test-suite/go/template_basic.go | 289 -- Examples/test-suite/go/template_classes.go | 152 - Examples/test-suite/go/template_const_ref.go | 177 - Examples/test-suite/go/template_construct.go | 75 - Examples/test-suite/go/template_default.go | 793 --- Examples/test-suite/go/template_default2.go | 279 - Examples/test-suite/go/template_default_arg.go | 2105 -------- Examples/test-suite/go/template_default_arg_runme | Bin 894243 -> 0 bytes .../go/template_default_arg_virtual_destructor.go | 151 - .../test-suite/go/template_default_class_parms.go | 525 -- .../go/template_default_class_parms_typedef.go | 983 ---- Examples/test-suite/go/template_default_inherit.go | 168 - Examples/test-suite/go/template_default_qualify.go | 241 - Examples/test-suite/go/template_default_vw.go | 159 - Examples/test-suite/go/template_enum.go | 263 - Examples/test-suite/go/template_enum_ns_inherit.go | 271 - Examples/test-suite/go/template_enum_typedef.go | 197 - Examples/test-suite/go/template_explicit.go | 289 -- Examples/test-suite/go/template_extend1.go | 139 - Examples/test-suite/go/template_extend1_runme | Bin 524960 -> 0 bytes Examples/test-suite/go/template_extend2.go | 139 - Examples/test-suite/go/template_extend2_runme | Bin 524960 -> 0 bytes Examples/test-suite/go/template_extend_overload.go | 400 -- .../test-suite/go/template_extend_overload_2.go | 385 -- Examples/test-suite/go/template_forward.go | 378 -- Examples/test-suite/go/template_inherit.go | 484 -- .../test-suite/go/template_inherit_abstract.go | 358 -- Examples/test-suite/go/template_inherit_runme | Bin 641216 -> 0 bytes Examples/test-suite/go/template_int_const.go | 410 -- Examples/test-suite/go/template_methods.go | 322 -- .../go/template_namespace_forward_declaration.go | 211 - Examples/test-suite/go/template_nested.go | 919 ---- Examples/test-suite/go/template_nested_typemaps.go | 182 - Examples/test-suite/go/template_ns.go | 263 - Examples/test-suite/go/template_ns2.go | 69 - Examples/test-suite/go/template_ns3.go | 88 - Examples/test-suite/go/template_ns4.go | 267 - Examples/test-suite/go/template_ns4_runme | Bin 531923 -> 0 bytes Examples/test-suite/go/template_ns_enum.go | 66 - Examples/test-suite/go/template_ns_enum2.go | 113 - Examples/test-suite/go/template_ns_inherit.go | 122 - Examples/test-suite/go/template_ns_runme | Bin 564885 -> 0 bytes Examples/test-suite/go/template_ns_scope.go | 152 - Examples/test-suite/go/template_opaque.go | 259 - Examples/test-suite/go/template_opaque_runme | Bin 637791 -> 0 bytes Examples/test-suite/go/template_partial_arg.go | 203 - .../go/template_partial_specialization.go | 1962 ------- .../go/template_partial_specialization_typedef.go | 1809 ------- Examples/test-suite/go/template_qualifier.go | 88 - Examples/test-suite/go/template_ref_type.go | 203 - Examples/test-suite/go/template_ref_type_runme | Bin 529248 -> 0 bytes Examples/test-suite/go/template_rename.go | 267 - Examples/test-suite/go/template_rename_runme | Bin 543297 -> 0 bytes Examples/test-suite/go/template_retvalue.go | 202 - Examples/test-suite/go/template_specialization.go | 152 - .../go/template_specialization_defarg.go | 368 -- .../test-suite/go/template_specialization_enum.go | 218 - Examples/test-suite/go/template_static.go | 196 - Examples/test-suite/go/template_static_runme | Bin 502583 -> 0 bytes Examples/test-suite/go/template_tbase_template.go | 198 - .../test-suite/go/template_tbase_template_runme | Bin 515637 -> 0 bytes .../test-suite/go/template_template_parameters.go | 297 -- Examples/test-suite/go/template_type_namespace.go | 214 - .../test-suite/go/template_type_namespace_runme | Bin 639894 -> 0 bytes Examples/test-suite/go/template_typedef.go | 444 -- .../go/template_typedef_class_template.go | 294 -- Examples/test-suite/go/template_typedef_cplx.go | 456 -- Examples/test-suite/go/template_typedef_cplx2.go | 664 --- Examples/test-suite/go/template_typedef_cplx3.go | 896 ---- .../test-suite/go/template_typedef_cplx3_runme | Bin 739574 -> 0 bytes Examples/test-suite/go/template_typedef_cplx4.go | 896 ---- .../test-suite/go/template_typedef_cplx4_runme | Bin 739574 -> 0 bytes Examples/test-suite/go/template_typedef_cplx5.go | 109 - Examples/test-suite/go/template_typedef_fnc.go | 214 - Examples/test-suite/go/template_typedef_funcptr.go | 175 - Examples/test-suite/go/template_typedef_import.go | 270 - Examples/test-suite/go/template_typedef_inherit.go | 246 - Examples/test-suite/go/template_typedef_ns.go | 101 - Examples/test-suite/go/template_typedef_ptr.go | 113 - Examples/test-suite/go/template_typedef_rec.go | 189 - Examples/test-suite/go/template_typedef_typedef.go | 259 - Examples/test-suite/go/template_typemaps.go | 237 - .../test-suite/go/template_typemaps_typedef.go | 520 -- .../test-suite/go/template_typemaps_typedef2.go | 520 -- Examples/test-suite/go/template_using.go | 89 - ...late_using_directive_and_declaration_forward.go | 653 --- Examples/test-suite/go/template_virtual.go | 150 - Examples/test-suite/go/template_whitespace.go | 97 - Examples/test-suite/go/threads.go | 101 - Examples/test-suite/go/threads_exception.go | 230 - Examples/test-suite/go/threads_exception_runme | Bin 782278 -> 0 bytes Examples/test-suite/go/throw_exception.go | 285 -- Examples/test-suite/go/typedef_array_member.go | 173 - Examples/test-suite/go/typedef_class.go | 297 -- Examples/test-suite/go/typedef_class_runme | Bin 534500 -> 0 bytes Examples/test-suite/go/typedef_funcptr.go | 52 - Examples/test-suite/go/typedef_inherit.go | 283 - Examples/test-suite/go/typedef_inherit_runme | Bin 574627 -> 0 bytes Examples/test-suite/go/typedef_mptr.go | 29 - Examples/test-suite/go/typedef_reference.go | 96 - Examples/test-suite/go/typedef_scope.go | 177 - Examples/test-suite/go/typedef_scope_runme | Bin 519858 -> 0 bytes Examples/test-suite/go/typedef_sizet.go | 36 - Examples/test-suite/go/typedef_struct.go | 438 -- Examples/test-suite/go/typedef_typedef.go | 164 - Examples/test-suite/go/typemap_array_qualifiers.go | 185 - Examples/test-suite/go/typemap_arrays.go | 36 - Examples/test-suite/go/typemap_delete.go | 101 - Examples/test-suite/go/typemap_directorout.go | 304 -- Examples/test-suite/go/typemap_directorout_wrap.h | 37 - Examples/test-suite/go/typemap_global_scope.go | 1023 ---- Examples/test-suite/go/typemap_manyargs.go | 49 - Examples/test-suite/go/typemap_namespace.go | 43 - Examples/test-suite/go/typemap_namespace_runme | Bin 499834 -> 0 bytes Examples/test-suite/go/typemap_ns_using.go | 82 - Examples/test-suite/go/typemap_ns_using_runme | Bin 498488 -> 0 bytes Examples/test-suite/go/typemap_numinputs.go | 36 - Examples/test-suite/go/typemap_out_optimal.go | 148 - Examples/test-suite/go/typemap_out_optimal_runme | Bin 526166 -> 0 bytes Examples/test-suite/go/typemap_qualifier_strip.go | 148 - Examples/test-suite/go/typemap_subst.go | 101 - Examples/test-suite/go/typemap_template.go | 290 -- .../test-suite/go/typemap_template_parm_typedef.go | 97 - Examples/test-suite/go/typemap_variables.go | 158 - Examples/test-suite/go/typemap_various.go | 363 -- Examples/test-suite/go/typename.go | 170 - Examples/test-suite/go/typename_runme | Bin 530446 -> 0 bytes Examples/test-suite/go/types_directive.go | 358 -- Examples/test-suite/go/unicode_strings.go | 43 - Examples/test-suite/go/union_parameter.go | 397 -- Examples/test-suite/go/union_scope.go | 75 - Examples/test-suite/go/unions.go | 448 -- Examples/test-suite/go/unions_runme | Bin 592772 -> 0 bytes Examples/test-suite/go/using1.go | 82 - Examples/test-suite/go/using1_runme | Bin 498320 -> 0 bytes Examples/test-suite/go/using2.go | 82 - Examples/test-suite/go/using2_runme | Bin 498344 -> 0 bytes Examples/test-suite/go/using_composition.go | 523 -- Examples/test-suite/go/using_composition_runme | Bin 643361 -> 0 bytes .../go/using_directive_and_declaration.go | 499 -- .../go/using_directive_and_declaration_forward.go | 613 --- Examples/test-suite/go/using_extend.go | 412 -- Examples/test-suite/go/using_extend_runme | Bin 611645 -> 0 bytes Examples/test-suite/go/using_inherit.go | 637 --- Examples/test-suite/go/using_inherit_runme | Bin 676090 -> 0 bytes Examples/test-suite/go/using_namespace.go | 334 -- Examples/test-suite/go/using_namespace_loop.go | 29 - Examples/test-suite/go/using_pointers.go | 226 - Examples/test-suite/go/using_private.go | 315 -- Examples/test-suite/go/using_private_runme | Bin 549711 -> 0 bytes Examples/test-suite/go/using_protected.go | 221 - Examples/test-suite/go/using_protected_runme | Bin 539085 -> 0 bytes Examples/test-suite/go/valuewrapper.go | 149 - Examples/test-suite/go/valuewrapper_base.go | 151 - Examples/test-suite/go/valuewrapper_const.go | 165 - Examples/test-suite/go/valuewrapper_opaque.go | 481 -- Examples/test-suite/go/varargs.go | 244 - Examples/test-suite/go/varargs_overload.go | 165 - Examples/test-suite/go/varargs_overload_runme | Bin 534491 -> 0 bytes Examples/test-suite/go/varargs_runme | Bin 546950 -> 0 bytes Examples/test-suite/go/virtual_destructor.go | 110 - Examples/test-suite/go/virtual_poly.go | 1317 ----- Examples/test-suite/go/virtual_poly_runme | Bin 640275 -> 0 bytes Examples/test-suite/go/virtual_poly_wrap.h | 16 - .../test-suite/go/virtual_vs_nonvirtual_base.go | 337 -- Examples/test-suite/go/voidtest.go | 155 - Examples/test-suite/go/voidtest_runme | Bin 523754 -> 0 bytes Examples/test-suite/go/wallkw.go | 64 - Examples/test-suite/go/wrapmacro.go | 68 - Examples/test-suite/go/wrapmacro_runme | Bin 509094 -> 0 bytes Examples/test-suite/overload_polymorphic.i~ | 25 - Examples/test-suite/overload_rename.i~ | 30 - Source/Modules/go.cxx~ | 5385 -------------------- 660 files changed, 180469 deletions(-) delete mode 100644 Examples/python/import_packages/relativeimport2/runme3.py delete mode 100644 Examples/test-suite/common.mk~ delete mode 100644 Examples/test-suite/go/abstract_access.go delete mode 100755 Examples/test-suite/go/abstract_access_runme delete mode 100644 Examples/test-suite/go/abstract_inherit.go delete mode 100644 Examples/test-suite/go/abstract_inherit_ok.go delete mode 100644 Examples/test-suite/go/abstract_signature.go delete mode 100644 Examples/test-suite/go/abstract_typedef.go delete mode 100644 Examples/test-suite/go/abstract_typedef2.go delete mode 100755 Examples/test-suite/go/abstract_typedef2_runme delete mode 100755 Examples/test-suite/go/abstract_typedef_runme delete mode 100644 Examples/test-suite/go/abstract_virtual.go delete mode 100755 Examples/test-suite/go/abstract_virtual_runme delete mode 100644 Examples/test-suite/go/access_change.go delete mode 100644 Examples/test-suite/go/add_link.go delete mode 100644 Examples/test-suite/go/aggregate.go delete mode 100644 Examples/test-suite/go/allowexcept.go delete mode 100644 Examples/test-suite/go/allprotected.go delete mode 100644 Examples/test-suite/go/allprotected_not.go delete mode 100644 Examples/test-suite/go/allprotected_not_wrap.h delete mode 100644 Examples/test-suite/go/allprotected_wrap.h delete mode 100644 Examples/test-suite/go/anonymous_bitfield.go delete mode 100644 Examples/test-suite/go/apply_signed_char.go delete mode 100644 Examples/test-suite/go/apply_signed_char_wrap.h delete mode 100644 Examples/test-suite/go/apply_strings.go delete mode 100644 Examples/test-suite/go/apply_strings_wrap.h delete mode 100644 Examples/test-suite/go/argout.go delete mode 100755 Examples/test-suite/go/argout_runme delete mode 100644 Examples/test-suite/go/array_member.go delete mode 100755 Examples/test-suite/go/array_member_runme delete mode 100644 Examples/test-suite/go/array_typedef_memberin.go delete mode 100644 Examples/test-suite/go/arrayref.go delete mode 100644 Examples/test-suite/go/arrays.go delete mode 100644 Examples/test-suite/go/arrays_dimensionless.go delete mode 100644 Examples/test-suite/go/arrays_global.go delete mode 100755 Examples/test-suite/go/arrays_global_runme delete mode 100644 Examples/test-suite/go/arrays_global_twodim.go delete mode 100644 Examples/test-suite/go/arrays_scope.go delete mode 100644 Examples/test-suite/go/autodoc.go delete mode 100644 Examples/test-suite/go/bloody_hell.go delete mode 100644 Examples/test-suite/go/bom_utf8.go delete mode 100644 Examples/test-suite/go/bools.go delete mode 100644 Examples/test-suite/go/c_delete.go delete mode 100644 Examples/test-suite/go/c_delete_function.go delete mode 100644 Examples/test-suite/go/cast_operator.go delete mode 100644 Examples/test-suite/go/casts.go delete mode 100644 Examples/test-suite/go/catches.go delete mode 100644 Examples/test-suite/go/char_binary.go delete mode 100755 Examples/test-suite/go/char_binary_runme delete mode 100644 Examples/test-suite/go/char_constant.go delete mode 100644 Examples/test-suite/go/char_strings.go delete mode 100644 Examples/test-suite/go/class_forward.go delete mode 100644 Examples/test-suite/go/class_ignore.go delete mode 100755 Examples/test-suite/go/class_ignore_runme delete mode 100644 Examples/test-suite/go/class_scope_weird.go delete mode 100755 Examples/test-suite/go/class_scope_weird_runme delete mode 100644 Examples/test-suite/go/clientdata_prop_a.go delete mode 100644 Examples/test-suite/go/clientdata_prop_b.go delete mode 100644 Examples/test-suite/go/compactdefaultargs.go delete mode 100755 Examples/test-suite/go/compactdefaultargs_runme delete mode 100644 Examples/test-suite/go/const_const.go delete mode 100644 Examples/test-suite/go/const_const_2.go delete mode 100644 Examples/test-suite/go/constant_expr.go delete mode 100644 Examples/test-suite/go/constant_pointers.go delete mode 100644 Examples/test-suite/go/constover.go delete mode 100755 Examples/test-suite/go/constover_runme delete mode 100644 Examples/test-suite/go/constructor_copy.go delete mode 100755 Examples/test-suite/go/constructor_copy_runme delete mode 100644 Examples/test-suite/go/constructor_exception.go delete mode 100644 Examples/test-suite/go/constructor_explicit.go delete mode 100644 Examples/test-suite/go/constructor_ignore.go delete mode 100644 Examples/test-suite/go/constructor_rename.go delete mode 100644 Examples/test-suite/go/constructor_value.go delete mode 100644 Examples/test-suite/go/contract.go delete mode 100755 Examples/test-suite/go/contract_runme delete mode 100644 Examples/test-suite/go/conversion.go delete mode 100644 Examples/test-suite/go/conversion_namespace.go delete mode 100644 Examples/test-suite/go/conversion_ns_template.go delete mode 100644 Examples/test-suite/go/cplusplus_throw.go delete mode 100644 Examples/test-suite/go/cpp_basic.go delete mode 100644 Examples/test-suite/go/cpp_enum.go delete mode 100755 Examples/test-suite/go/cpp_enum_runme delete mode 100644 Examples/test-suite/go/cpp_namespace.go delete mode 100755 Examples/test-suite/go/cpp_namespace_runme delete mode 100644 Examples/test-suite/go/cpp_nodefault.go delete mode 100644 Examples/test-suite/go/cpp_static.go delete mode 100755 Examples/test-suite/go/cpp_static_runme delete mode 100644 Examples/test-suite/go/cpp_typedef.go delete mode 100644 Examples/test-suite/go/curiously_recurring_template_pattern.go delete mode 100644 Examples/test-suite/go/default_arg_values.go delete mode 100644 Examples/test-suite/go/default_args.go delete mode 100755 Examples/test-suite/go/default_args_runme delete mode 100644 Examples/test-suite/go/default_constructor.go delete mode 100755 Examples/test-suite/go/default_constructor_runme delete mode 100644 Examples/test-suite/go/defvalue_constructor.go delete mode 100644 Examples/test-suite/go/derived_byvalue.go delete mode 100644 Examples/test-suite/go/derived_nested.go delete mode 100644 Examples/test-suite/go/destructor_reprotected.go delete mode 100644 Examples/test-suite/go/director_abstract.go delete mode 100644 Examples/test-suite/go/director_abstract_wrap.h delete mode 100644 Examples/test-suite/go/director_alternating.go delete mode 100755 Examples/test-suite/go/director_alternating_runme delete mode 100644 Examples/test-suite/go/director_alternating_wrap.h delete mode 100644 Examples/test-suite/go/director_basic.go delete mode 100755 Examples/test-suite/go/director_basic_runme delete mode 100644 Examples/test-suite/go/director_basic_wrap.h delete mode 100644 Examples/test-suite/go/director_binary_string.go delete mode 100644 Examples/test-suite/go/director_binary_string_wrap.h delete mode 100644 Examples/test-suite/go/director_classes.go delete mode 100644 Examples/test-suite/go/director_classes_wrap.h delete mode 100644 Examples/test-suite/go/director_classic.go delete mode 100755 Examples/test-suite/go/director_classic_runme delete mode 100644 Examples/test-suite/go/director_classic_wrap.h delete mode 100644 Examples/test-suite/go/director_constructor.go delete mode 100644 Examples/test-suite/go/director_constructor_wrap.h delete mode 100644 Examples/test-suite/go/director_default.go delete mode 100755 Examples/test-suite/go/director_default_runme delete mode 100644 Examples/test-suite/go/director_default_wrap.h delete mode 100644 Examples/test-suite/go/director_detect.go delete mode 100755 Examples/test-suite/go/director_detect_runme delete mode 100644 Examples/test-suite/go/director_detect_wrap.h delete mode 100644 Examples/test-suite/go/director_enum.go delete mode 100755 Examples/test-suite/go/director_enum_runme delete mode 100644 Examples/test-suite/go/director_enum_wrap.h delete mode 100644 Examples/test-suite/go/director_exception.go delete mode 100755 Examples/test-suite/go/director_exception_runme delete mode 100644 Examples/test-suite/go/director_exception_wrap.h delete mode 100644 Examples/test-suite/go/director_extend.go delete mode 100755 Examples/test-suite/go/director_extend_runme delete mode 100644 Examples/test-suite/go/director_extend_wrap.h delete mode 100644 Examples/test-suite/go/director_finalizer.go delete mode 100755 Examples/test-suite/go/director_finalizer_runme delete mode 100644 Examples/test-suite/go/director_finalizer_wrap.h delete mode 100644 Examples/test-suite/go/director_frob.go delete mode 100755 Examples/test-suite/go/director_frob_runme delete mode 100644 Examples/test-suite/go/director_frob_wrap.h delete mode 100644 Examples/test-suite/go/director_ignore.go delete mode 100644 Examples/test-suite/go/director_ignore_wrap.h delete mode 100644 Examples/test-suite/go/director_keywords.go delete mode 100644 Examples/test-suite/go/director_keywords_wrap.h delete mode 100644 Examples/test-suite/go/director_namespace_clash.go delete mode 100644 Examples/test-suite/go/director_namespace_clash_wrap.h delete mode 100644 Examples/test-suite/go/director_nested.go delete mode 100755 Examples/test-suite/go/director_nested_runme delete mode 100644 Examples/test-suite/go/director_nested_wrap.h delete mode 100644 Examples/test-suite/go/director_nspace.go delete mode 100644 Examples/test-suite/go/director_nspace_director_name_collision.go delete mode 100644 Examples/test-suite/go/director_nspace_director_name_collision_wrap.h delete mode 100644 Examples/test-suite/go/director_nspace_wrap.h delete mode 100644 Examples/test-suite/go/director_overload.go delete mode 100644 Examples/test-suite/go/director_overload2.go delete mode 100644 Examples/test-suite/go/director_overload2_wrap.h delete mode 100644 Examples/test-suite/go/director_overload_wrap.h delete mode 100644 Examples/test-suite/go/director_primitives.go delete mode 100644 Examples/test-suite/go/director_primitives_wrap.h delete mode 100644 Examples/test-suite/go/director_protected.go delete mode 100644 Examples/test-suite/go/director_protected_overloaded.go delete mode 100644 Examples/test-suite/go/director_protected_overloaded_wrap.h delete mode 100755 Examples/test-suite/go/director_protected_runme delete mode 100644 Examples/test-suite/go/director_protected_wrap.h delete mode 100644 Examples/test-suite/go/director_redefined.go delete mode 100644 Examples/test-suite/go/director_redefined_wrap.h delete mode 100644 Examples/test-suite/go/director_smartptr.go delete mode 100644 Examples/test-suite/go/director_smartptr_wrap.h delete mode 100644 Examples/test-suite/go/director_string.go delete mode 100755 Examples/test-suite/go/director_string_runme delete mode 100644 Examples/test-suite/go/director_string_wrap.h delete mode 100644 Examples/test-suite/go/director_thread.go delete mode 100644 Examples/test-suite/go/director_thread_wrap.h delete mode 100644 Examples/test-suite/go/director_unroll.go delete mode 100755 Examples/test-suite/go/director_unroll_runme delete mode 100644 Examples/test-suite/go/director_unroll_wrap.h delete mode 100644 Examples/test-suite/go/director_using.go delete mode 100644 Examples/test-suite/go/director_using_wrap.h delete mode 100644 Examples/test-suite/go/director_wombat.go delete mode 100644 Examples/test-suite/go/director_wombat_wrap.h delete mode 100644 Examples/test-suite/go/disown.go delete mode 100755 Examples/test-suite/go/disown_runme delete mode 100644 Examples/test-suite/go/dynamic_cast.go delete mode 100755 Examples/test-suite/go/dynamic_cast_runme delete mode 100644 Examples/test-suite/go/empty.go delete mode 100755 Examples/test-suite/go/empty_runme delete mode 100644 Examples/test-suite/go/enum_forward.go delete mode 100644 Examples/test-suite/go/enum_ignore.go delete mode 100644 Examples/test-suite/go/enum_macro.go delete mode 100644 Examples/test-suite/go/enum_missing.go delete mode 100644 Examples/test-suite/go/enum_plus.go delete mode 100644 Examples/test-suite/go/enum_rename.go delete mode 100644 Examples/test-suite/go/enum_scope_template.go delete mode 100644 Examples/test-suite/go/enum_template.go delete mode 100755 Examples/test-suite/go/enum_template_runme delete mode 100644 Examples/test-suite/go/enum_thorough.go delete mode 100644 Examples/test-suite/go/enum_var.go delete mode 100644 Examples/test-suite/go/enums.go delete mode 100755 Examples/test-suite/go/enums_runme delete mode 100644 Examples/test-suite/go/equality.go delete mode 100644 Examples/test-suite/go/evil_diamond.go delete mode 100644 Examples/test-suite/go/evil_diamond_ns.go delete mode 100644 Examples/test-suite/go/evil_diamond_prop.go delete mode 100644 Examples/test-suite/go/exception_order.go delete mode 100755 Examples/test-suite/go/exception_order_runme delete mode 100644 Examples/test-suite/go/expressions.go delete mode 100644 Examples/test-suite/go/extend.go delete mode 100644 Examples/test-suite/go/extend_constructor_destructor.go delete mode 100644 Examples/test-suite/go/extend_default.go delete mode 100644 Examples/test-suite/go/extend_placement.go delete mode 100755 Examples/test-suite/go/extend_placement_runme delete mode 100644 Examples/test-suite/go/extend_special_variables.go delete mode 100644 Examples/test-suite/go/extend_template.go delete mode 100644 Examples/test-suite/go/extend_template_ns.go delete mode 100755 Examples/test-suite/go/extend_template_ns_runme delete mode 100755 Examples/test-suite/go/extend_template_runme delete mode 100644 Examples/test-suite/go/extend_typedef_class.go delete mode 100644 Examples/test-suite/go/extern_c.go delete mode 100755 Examples/test-suite/go/extern_c_runme delete mode 100644 Examples/test-suite/go/extern_declaration.go delete mode 100644 Examples/test-suite/go/extern_namespace.go delete mode 100644 Examples/test-suite/go/extern_throws.go delete mode 100644 Examples/test-suite/go/features.go delete mode 100644 Examples/test-suite/go/fragments.go delete mode 100644 Examples/test-suite/go/friends.go delete mode 100755 Examples/test-suite/go/friends_runme delete mode 100644 Examples/test-suite/go/funcptr.go delete mode 100644 Examples/test-suite/go/funcptr_cpp.go delete mode 100644 Examples/test-suite/go/function_typedef.go delete mode 100644 Examples/test-suite/go/fvirtual.go delete mode 100755 Examples/test-suite/go/fvirtual_runme delete mode 100644 Examples/test-suite/go/global_functions.go delete mode 100644 Examples/test-suite/go/global_namespace.go delete mode 100644 Examples/test-suite/go/global_ns_arg.go delete mode 100755 Examples/test-suite/go/global_ns_arg_runme delete mode 100644 Examples/test-suite/go/global_scope_types.go delete mode 100644 Examples/test-suite/go/global_vars.go delete mode 100644 Examples/test-suite/go/go_director_inout.go delete mode 100755 Examples/test-suite/go/go_director_inout_runme delete mode 100644 Examples/test-suite/go/go_director_inout_wrap.h delete mode 100644 Examples/test-suite/go/go_inout.go delete mode 100755 Examples/test-suite/go/go_inout_runme delete mode 100644 Examples/test-suite/go/grouping.go delete mode 100755 Examples/test-suite/go/grouping_runme delete mode 100644 Examples/test-suite/go/ignore_parameter.go delete mode 100644 Examples/test-suite/go/ignore_template_constructor.go delete mode 100644 Examples/test-suite/go/immutable_values.go delete mode 100644 Examples/test-suite/go/import_nomodule.go delete mode 100755 Examples/test-suite/go/import_nomodule_runme delete mode 100644 Examples/test-suite/go/import_stl_a.go delete mode 100644 Examples/test-suite/go/import_stl_b.go delete mode 100644 Examples/test-suite/go/imports_a.go delete mode 100644 Examples/test-suite/go/imports_b.go delete mode 100755 Examples/test-suite/go/imports_runme delete mode 100644 Examples/test-suite/go/inctest.go delete mode 100755 Examples/test-suite/go/inctest_runme delete mode 100644 Examples/test-suite/go/infinity.go delete mode 100644 Examples/test-suite/go/inherit.go delete mode 100644 Examples/test-suite/go/inherit_missing.go delete mode 100755 Examples/test-suite/go/inherit_missing_runme delete mode 100644 Examples/test-suite/go/inherit_same_name.go delete mode 100644 Examples/test-suite/go/inherit_target_language.go delete mode 100644 Examples/test-suite/go/inherit_void_arg.go delete mode 100644 Examples/test-suite/go/inline_initializer.go delete mode 100644 Examples/test-suite/go/insert_directive.go delete mode 100644 Examples/test-suite/go/integers.go delete mode 100644 Examples/test-suite/go/keyword_rename.go delete mode 100755 Examples/test-suite/go/keyword_rename_runme delete mode 100644 Examples/test-suite/go/kind.go delete mode 100644 Examples/test-suite/go/langobj.go delete mode 100644 Examples/test-suite/go/lextype.go delete mode 100644 Examples/test-suite/go/li_attribute.go delete mode 100755 Examples/test-suite/go/li_attribute_runme delete mode 100644 Examples/test-suite/go/li_attribute_template.go delete mode 100644 Examples/test-suite/go/li_boost_shared_ptr.go delete mode 100644 Examples/test-suite/go/li_boost_shared_ptr_attribute.go delete mode 100644 Examples/test-suite/go/li_boost_shared_ptr_bits.go delete mode 100644 Examples/test-suite/go/li_boost_shared_ptr_template.go delete mode 100644 Examples/test-suite/go/li_carrays.go delete mode 100755 Examples/test-suite/go/li_carrays_runme delete mode 100644 Examples/test-suite/go/li_cdata.go delete mode 100755 Examples/test-suite/go/li_cdata_runme delete mode 100644 Examples/test-suite/go/li_cmalloc.go delete mode 100755 Examples/test-suite/go/li_cmalloc_runme delete mode 100644 Examples/test-suite/go/li_constraints.go delete mode 100644 Examples/test-suite/go/li_cpointer.go delete mode 100755 Examples/test-suite/go/li_cpointer_runme delete mode 100644 Examples/test-suite/go/li_math.go delete mode 100644 Examples/test-suite/go/li_std_auto_ptr.go delete mode 100644 Examples/test-suite/go/li_std_combinations.go delete mode 100644 Examples/test-suite/go/li_std_deque.go delete mode 100644 Examples/test-suite/go/li_std_except.go delete mode 100644 Examples/test-suite/go/li_std_except_as_class.go delete mode 100644 Examples/test-suite/go/li_std_map.go delete mode 100755 Examples/test-suite/go/li_std_map_runme delete mode 100644 Examples/test-suite/go/li_std_pair.go delete mode 100644 Examples/test-suite/go/li_std_pair_using.go delete mode 100644 Examples/test-suite/go/li_std_string.go delete mode 100644 Examples/test-suite/go/li_std_vector.go delete mode 100644 Examples/test-suite/go/li_std_vector_enum.go delete mode 100644 Examples/test-suite/go/li_std_vector_member_var.go delete mode 100644 Examples/test-suite/go/li_stdint.go delete mode 100644 Examples/test-suite/go/li_swigtype_inout.go delete mode 100644 Examples/test-suite/go/li_typemaps.go delete mode 100644 Examples/test-suite/go/li_typemaps_apply.go delete mode 100644 Examples/test-suite/go/li_windows.go delete mode 100644 Examples/test-suite/go/long_long.go delete mode 100644 Examples/test-suite/go/long_long_apply.go delete mode 100644 Examples/test-suite/go/member_funcptr_galore.go delete mode 100644 Examples/test-suite/go/member_pointer.go delete mode 100755 Examples/test-suite/go/member_pointer_runme delete mode 100644 Examples/test-suite/go/member_template.go delete mode 100644 Examples/test-suite/go/memberin_extend.go delete mode 100644 Examples/test-suite/go/memberin_extend_c.go delete mode 100755 Examples/test-suite/go/memberin_extend_c_runme delete mode 100644 Examples/test-suite/go/minherit.go delete mode 100644 Examples/test-suite/go/minherit2.go delete mode 100755 Examples/test-suite/go/minherit_runme delete mode 100644 Examples/test-suite/go/mixed_types.go delete mode 100644 Examples/test-suite/go/mod_a.go delete mode 100644 Examples/test-suite/go/mod_b.go delete mode 100755 Examples/test-suite/go/mod_runme delete mode 100644 Examples/test-suite/go/multi_import_a.go delete mode 100644 Examples/test-suite/go/multi_import_b.go delete mode 100755 Examples/test-suite/go/multi_import_runme delete mode 100644 Examples/test-suite/go/multiple_inheritance.go delete mode 100644 Examples/test-suite/go/name.go delete mode 100644 Examples/test-suite/go/name_cxx.go delete mode 100644 Examples/test-suite/go/name_warnings.go delete mode 100644 Examples/test-suite/go/namespace_class.go delete mode 100755 Examples/test-suite/go/namespace_class_runme delete mode 100644 Examples/test-suite/go/namespace_enum.go delete mode 100644 Examples/test-suite/go/namespace_extend.go delete mode 100644 Examples/test-suite/go/namespace_forward_declaration.go delete mode 100644 Examples/test-suite/go/namespace_nested.go delete mode 100644 Examples/test-suite/go/namespace_spaces.go delete mode 100644 Examples/test-suite/go/namespace_template.go delete mode 100644 Examples/test-suite/go/namespace_typedef_class.go delete mode 100644 Examples/test-suite/go/namespace_typemap.go delete mode 100755 Examples/test-suite/go/namespace_typemap_runme delete mode 100644 Examples/test-suite/go/namespace_union.go delete mode 100644 Examples/test-suite/go/namespace_virtual_method.go delete mode 100755 Examples/test-suite/go/namespace_virtual_method_runme delete mode 100644 Examples/test-suite/go/naturalvar.go delete mode 100644 Examples/test-suite/go/naturalvar_more.go delete mode 100644 Examples/test-suite/go/naturalvar_onoff.go delete mode 100755 Examples/test-suite/go/naturalvar_runme delete mode 100644 Examples/test-suite/go/nested.go delete mode 100644 Examples/test-suite/go/nested_class.go delete mode 100644 Examples/test-suite/go/nested_comment.go delete mode 100644 Examples/test-suite/go/nested_directors.go delete mode 100644 Examples/test-suite/go/nested_directors_wrap.h delete mode 100644 Examples/test-suite/go/nested_extend_c.go delete mode 100644 Examples/test-suite/go/nested_scope.go delete mode 100644 Examples/test-suite/go/nested_structs.go delete mode 100644 Examples/test-suite/go/nested_workaround.go delete mode 100755 Examples/test-suite/go/nested_workaround_runme delete mode 100644 Examples/test-suite/go/newobject1.go delete mode 100644 Examples/test-suite/go/newobject2.go delete mode 100644 Examples/test-suite/go/nspace.go delete mode 100644 Examples/test-suite/go/nspace_extend.go delete mode 100644 Examples/test-suite/go/null_pointer.go delete mode 100644 Examples/test-suite/go/operator_overload.go delete mode 100644 Examples/test-suite/go/operator_overload_break.go delete mode 100644 Examples/test-suite/go/operator_pointer_ref.go delete mode 100644 Examples/test-suite/go/operbool.go delete mode 100644 Examples/test-suite/go/ordering.go delete mode 100644 Examples/test-suite/go/overload_bool.go delete mode 100644 Examples/test-suite/go/overload_copy.go delete mode 100755 Examples/test-suite/go/overload_copy_runme delete mode 100644 Examples/test-suite/go/overload_extend.go delete mode 100755 Examples/test-suite/go/overload_extend_runme delete mode 100644 Examples/test-suite/go/overload_extendc.go delete mode 100755 Examples/test-suite/go/overload_extendc_runme delete mode 100644 Examples/test-suite/go/overload_method.go delete mode 100644 Examples/test-suite/go/overload_numeric.go delete mode 100644 Examples/test-suite/go/overload_polymorphic.go delete mode 100755 Examples/test-suite/go/overload_polymorphic_runme delete mode 100644 Examples/test-suite/go/overload_polymorphic_runme.go~ delete mode 100644 Examples/test-suite/go/overload_rename.go delete mode 100755 Examples/test-suite/go/overload_rename_runme delete mode 100644 Examples/test-suite/go/overload_return_type.go delete mode 100644 Examples/test-suite/go/overload_simple.go delete mode 100755 Examples/test-suite/go/overload_simple_runme delete mode 100644 Examples/test-suite/go/overload_subtype.go delete mode 100755 Examples/test-suite/go/overload_subtype_runme delete mode 100644 Examples/test-suite/go/overload_template.go delete mode 100644 Examples/test-suite/go/overload_template_fast.go delete mode 100755 Examples/test-suite/go/overload_template_fast_runme delete mode 100755 Examples/test-suite/go/overload_template_runme delete mode 100644 Examples/test-suite/go/packageoption_a.go delete mode 100644 Examples/test-suite/go/packageoption_b.go delete mode 100644 Examples/test-suite/go/packageoption_c.go delete mode 100644 Examples/test-suite/go/pointer_reference.go delete mode 100644 Examples/test-suite/go/preproc.go delete mode 100644 Examples/test-suite/go/preproc_constants.go delete mode 100644 Examples/test-suite/go/preproc_constants_c.go delete mode 100644 Examples/test-suite/go/preproc_defined.go delete mode 100644 Examples/test-suite/go/preproc_include.go delete mode 100644 Examples/test-suite/go/preproc_line_file.go delete mode 100755 Examples/test-suite/go/preproc_runme delete mode 100644 Examples/test-suite/go/primitive_ref.go delete mode 100755 Examples/test-suite/go/primitive_ref_runme delete mode 100644 Examples/test-suite/go/private_assign.go delete mode 100644 Examples/test-suite/go/protected_rename.go delete mode 100644 Examples/test-suite/go/pure_virtual.go delete mode 100644 Examples/test-suite/go/redefined.go delete mode 100644 Examples/test-suite/go/redefined_not.go delete mode 100644 Examples/test-suite/go/refcount.go delete mode 100755 Examples/test-suite/go/refcount_runme delete mode 100644 Examples/test-suite/go/reference_global_vars.go delete mode 100755 Examples/test-suite/go/reference_global_vars_runme delete mode 100644 Examples/test-suite/go/register_par.go delete mode 100644 Examples/test-suite/go/rename1.go delete mode 100644 Examples/test-suite/go/rename2.go delete mode 100644 Examples/test-suite/go/rename3.go delete mode 100644 Examples/test-suite/go/rename4.go delete mode 100644 Examples/test-suite/go/rename_pcre_encoder.go delete mode 100644 Examples/test-suite/go/rename_pcre_enum.go delete mode 100644 Examples/test-suite/go/rename_predicates.go delete mode 100644 Examples/test-suite/go/rename_scope.go delete mode 100755 Examples/test-suite/go/rename_scope_runme delete mode 100644 Examples/test-suite/go/rename_simple.go delete mode 100755 Examples/test-suite/go/rename_simple_runme delete mode 100644 Examples/test-suite/go/rename_strip_encoder.go delete mode 100755 Examples/test-suite/go/rename_strip_encoder_runme delete mode 100644 Examples/test-suite/go/restrict_cplusplus.go delete mode 100644 Examples/test-suite/go/ret_by_value.go delete mode 100755 Examples/test-suite/go/ret_by_value_runme delete mode 100644 Examples/test-suite/go/return_const_value.go delete mode 100755 Examples/test-suite/go/return_const_value_runme delete mode 100644 Examples/test-suite/go/return_value_scope.go delete mode 100644 Examples/test-suite/go/rname.go delete mode 100644 Examples/test-suite/go/samename.go delete mode 100644 Examples/test-suite/go/simple_array.go delete mode 100644 Examples/test-suite/go/sizeof_pointer.go delete mode 100644 Examples/test-suite/go/sizet.go delete mode 100644 Examples/test-suite/go/smart_pointer_const.go delete mode 100644 Examples/test-suite/go/smart_pointer_const2.go delete mode 100644 Examples/test-suite/go/smart_pointer_const_overload.go delete mode 100644 Examples/test-suite/go/smart_pointer_extend.go delete mode 100755 Examples/test-suite/go/smart_pointer_extend_runme delete mode 100644 Examples/test-suite/go/smart_pointer_inherit.go delete mode 100644 Examples/test-suite/go/smart_pointer_member.go delete mode 100755 Examples/test-suite/go/smart_pointer_member_runme delete mode 100644 Examples/test-suite/go/smart_pointer_multi.go delete mode 100755 Examples/test-suite/go/smart_pointer_multi_runme delete mode 100644 Examples/test-suite/go/smart_pointer_multi_typedef.go delete mode 100755 Examples/test-suite/go/smart_pointer_multi_typedef_runme delete mode 100644 Examples/test-suite/go/smart_pointer_namespace.go delete mode 100644 Examples/test-suite/go/smart_pointer_namespace2.go delete mode 100644 Examples/test-suite/go/smart_pointer_not.go delete mode 100644 Examples/test-suite/go/smart_pointer_overload.go delete mode 100755 Examples/test-suite/go/smart_pointer_overload_runme delete mode 100644 Examples/test-suite/go/smart_pointer_protected.go delete mode 100644 Examples/test-suite/go/smart_pointer_rename.go delete mode 100755 Examples/test-suite/go/smart_pointer_rename_runme delete mode 100644 Examples/test-suite/go/smart_pointer_simple.go delete mode 100755 Examples/test-suite/go/smart_pointer_simple_runme delete mode 100644 Examples/test-suite/go/smart_pointer_static.go delete mode 100644 Examples/test-suite/go/smart_pointer_template_const_overload.go delete mode 100644 Examples/test-suite/go/smart_pointer_template_defaults_overload.go delete mode 100644 Examples/test-suite/go/smart_pointer_templatemethods.go delete mode 100644 Examples/test-suite/go/smart_pointer_templatevariables.go delete mode 100755 Examples/test-suite/go/smart_pointer_templatevariables_runme delete mode 100644 Examples/test-suite/go/smart_pointer_typedef.go delete mode 100755 Examples/test-suite/go/smart_pointer_typedef_runme delete mode 100644 Examples/test-suite/go/sneaky1.go delete mode 100755 Examples/test-suite/go/sneaky1_runme delete mode 100644 Examples/test-suite/go/special_variable_macros.go delete mode 100755 Examples/test-suite/go/special_variable_macros_runme delete mode 100644 Examples/test-suite/go/special_variables.go delete mode 100644 Examples/test-suite/go/special_variables_wrap.h delete mode 100644 Examples/test-suite/go/static_array_member.go delete mode 100644 Examples/test-suite/go/static_const_member.go delete mode 100644 Examples/test-suite/go/static_const_member_2.go delete mode 100755 Examples/test-suite/go/static_const_member_2_runme delete mode 100644 Examples/test-suite/go/string_simple.go delete mode 100644 Examples/test-suite/go/struct_initialization.go delete mode 100644 Examples/test-suite/go/struct_initialization_cpp.go delete mode 100755 Examples/test-suite/go/struct_initialization_runme delete mode 100644 Examples/test-suite/go/struct_rename.go delete mode 100755 Examples/test-suite/go/struct_rename_runme delete mode 100644 Examples/test-suite/go/struct_value.go delete mode 100755 Examples/test-suite/go/struct_value_runme delete mode 100644 Examples/test-suite/go/symbol_clash.go delete mode 100644 Examples/test-suite/go/template_arg_replace.go delete mode 100644 Examples/test-suite/go/template_arg_scope.go delete mode 100644 Examples/test-suite/go/template_arg_typename.go delete mode 100644 Examples/test-suite/go/template_array_numeric.go delete mode 100644 Examples/test-suite/go/template_base_template.go delete mode 100644 Examples/test-suite/go/template_basic.go delete mode 100644 Examples/test-suite/go/template_classes.go delete mode 100644 Examples/test-suite/go/template_const_ref.go delete mode 100644 Examples/test-suite/go/template_construct.go delete mode 100644 Examples/test-suite/go/template_default.go delete mode 100644 Examples/test-suite/go/template_default2.go delete mode 100644 Examples/test-suite/go/template_default_arg.go delete mode 100755 Examples/test-suite/go/template_default_arg_runme delete mode 100644 Examples/test-suite/go/template_default_arg_virtual_destructor.go delete mode 100644 Examples/test-suite/go/template_default_class_parms.go delete mode 100644 Examples/test-suite/go/template_default_class_parms_typedef.go delete mode 100644 Examples/test-suite/go/template_default_inherit.go delete mode 100644 Examples/test-suite/go/template_default_qualify.go delete mode 100644 Examples/test-suite/go/template_default_vw.go delete mode 100644 Examples/test-suite/go/template_enum.go delete mode 100644 Examples/test-suite/go/template_enum_ns_inherit.go delete mode 100644 Examples/test-suite/go/template_enum_typedef.go delete mode 100644 Examples/test-suite/go/template_explicit.go delete mode 100644 Examples/test-suite/go/template_extend1.go delete mode 100755 Examples/test-suite/go/template_extend1_runme delete mode 100644 Examples/test-suite/go/template_extend2.go delete mode 100755 Examples/test-suite/go/template_extend2_runme delete mode 100644 Examples/test-suite/go/template_extend_overload.go delete mode 100644 Examples/test-suite/go/template_extend_overload_2.go delete mode 100644 Examples/test-suite/go/template_forward.go delete mode 100644 Examples/test-suite/go/template_inherit.go delete mode 100644 Examples/test-suite/go/template_inherit_abstract.go delete mode 100755 Examples/test-suite/go/template_inherit_runme delete mode 100644 Examples/test-suite/go/template_int_const.go delete mode 100644 Examples/test-suite/go/template_methods.go delete mode 100644 Examples/test-suite/go/template_namespace_forward_declaration.go delete mode 100644 Examples/test-suite/go/template_nested.go delete mode 100644 Examples/test-suite/go/template_nested_typemaps.go delete mode 100644 Examples/test-suite/go/template_ns.go delete mode 100644 Examples/test-suite/go/template_ns2.go delete mode 100644 Examples/test-suite/go/template_ns3.go delete mode 100644 Examples/test-suite/go/template_ns4.go delete mode 100755 Examples/test-suite/go/template_ns4_runme delete mode 100644 Examples/test-suite/go/template_ns_enum.go delete mode 100644 Examples/test-suite/go/template_ns_enum2.go delete mode 100644 Examples/test-suite/go/template_ns_inherit.go delete mode 100755 Examples/test-suite/go/template_ns_runme delete mode 100644 Examples/test-suite/go/template_ns_scope.go delete mode 100644 Examples/test-suite/go/template_opaque.go delete mode 100755 Examples/test-suite/go/template_opaque_runme delete mode 100644 Examples/test-suite/go/template_partial_arg.go delete mode 100644 Examples/test-suite/go/template_partial_specialization.go delete mode 100644 Examples/test-suite/go/template_partial_specialization_typedef.go delete mode 100644 Examples/test-suite/go/template_qualifier.go delete mode 100644 Examples/test-suite/go/template_ref_type.go delete mode 100755 Examples/test-suite/go/template_ref_type_runme delete mode 100644 Examples/test-suite/go/template_rename.go delete mode 100755 Examples/test-suite/go/template_rename_runme delete mode 100644 Examples/test-suite/go/template_retvalue.go delete mode 100644 Examples/test-suite/go/template_specialization.go delete mode 100644 Examples/test-suite/go/template_specialization_defarg.go delete mode 100644 Examples/test-suite/go/template_specialization_enum.go delete mode 100644 Examples/test-suite/go/template_static.go delete mode 100755 Examples/test-suite/go/template_static_runme delete mode 100644 Examples/test-suite/go/template_tbase_template.go delete mode 100755 Examples/test-suite/go/template_tbase_template_runme delete mode 100644 Examples/test-suite/go/template_template_parameters.go delete mode 100644 Examples/test-suite/go/template_type_namespace.go delete mode 100755 Examples/test-suite/go/template_type_namespace_runme delete mode 100644 Examples/test-suite/go/template_typedef.go delete mode 100644 Examples/test-suite/go/template_typedef_class_template.go delete mode 100644 Examples/test-suite/go/template_typedef_cplx.go delete mode 100644 Examples/test-suite/go/template_typedef_cplx2.go delete mode 100644 Examples/test-suite/go/template_typedef_cplx3.go delete mode 100755 Examples/test-suite/go/template_typedef_cplx3_runme delete mode 100644 Examples/test-suite/go/template_typedef_cplx4.go delete mode 100755 Examples/test-suite/go/template_typedef_cplx4_runme delete mode 100644 Examples/test-suite/go/template_typedef_cplx5.go delete mode 100644 Examples/test-suite/go/template_typedef_fnc.go delete mode 100644 Examples/test-suite/go/template_typedef_funcptr.go delete mode 100644 Examples/test-suite/go/template_typedef_import.go delete mode 100644 Examples/test-suite/go/template_typedef_inherit.go delete mode 100644 Examples/test-suite/go/template_typedef_ns.go delete mode 100644 Examples/test-suite/go/template_typedef_ptr.go delete mode 100644 Examples/test-suite/go/template_typedef_rec.go delete mode 100644 Examples/test-suite/go/template_typedef_typedef.go delete mode 100644 Examples/test-suite/go/template_typemaps.go delete mode 100644 Examples/test-suite/go/template_typemaps_typedef.go delete mode 100644 Examples/test-suite/go/template_typemaps_typedef2.go delete mode 100644 Examples/test-suite/go/template_using.go delete mode 100644 Examples/test-suite/go/template_using_directive_and_declaration_forward.go delete mode 100644 Examples/test-suite/go/template_virtual.go delete mode 100644 Examples/test-suite/go/template_whitespace.go delete mode 100644 Examples/test-suite/go/threads.go delete mode 100644 Examples/test-suite/go/threads_exception.go delete mode 100755 Examples/test-suite/go/threads_exception_runme delete mode 100644 Examples/test-suite/go/throw_exception.go delete mode 100644 Examples/test-suite/go/typedef_array_member.go delete mode 100644 Examples/test-suite/go/typedef_class.go delete mode 100755 Examples/test-suite/go/typedef_class_runme delete mode 100644 Examples/test-suite/go/typedef_funcptr.go delete mode 100644 Examples/test-suite/go/typedef_inherit.go delete mode 100755 Examples/test-suite/go/typedef_inherit_runme delete mode 100644 Examples/test-suite/go/typedef_mptr.go delete mode 100644 Examples/test-suite/go/typedef_reference.go delete mode 100644 Examples/test-suite/go/typedef_scope.go delete mode 100755 Examples/test-suite/go/typedef_scope_runme delete mode 100644 Examples/test-suite/go/typedef_sizet.go delete mode 100644 Examples/test-suite/go/typedef_struct.go delete mode 100644 Examples/test-suite/go/typedef_typedef.go delete mode 100644 Examples/test-suite/go/typemap_array_qualifiers.go delete mode 100644 Examples/test-suite/go/typemap_arrays.go delete mode 100644 Examples/test-suite/go/typemap_delete.go delete mode 100644 Examples/test-suite/go/typemap_directorout.go delete mode 100644 Examples/test-suite/go/typemap_directorout_wrap.h delete mode 100644 Examples/test-suite/go/typemap_global_scope.go delete mode 100644 Examples/test-suite/go/typemap_manyargs.go delete mode 100644 Examples/test-suite/go/typemap_namespace.go delete mode 100755 Examples/test-suite/go/typemap_namespace_runme delete mode 100644 Examples/test-suite/go/typemap_ns_using.go delete mode 100755 Examples/test-suite/go/typemap_ns_using_runme delete mode 100644 Examples/test-suite/go/typemap_numinputs.go delete mode 100644 Examples/test-suite/go/typemap_out_optimal.go delete mode 100755 Examples/test-suite/go/typemap_out_optimal_runme delete mode 100644 Examples/test-suite/go/typemap_qualifier_strip.go delete mode 100644 Examples/test-suite/go/typemap_subst.go delete mode 100644 Examples/test-suite/go/typemap_template.go delete mode 100644 Examples/test-suite/go/typemap_template_parm_typedef.go delete mode 100644 Examples/test-suite/go/typemap_variables.go delete mode 100644 Examples/test-suite/go/typemap_various.go delete mode 100644 Examples/test-suite/go/typename.go delete mode 100755 Examples/test-suite/go/typename_runme delete mode 100644 Examples/test-suite/go/types_directive.go delete mode 100644 Examples/test-suite/go/unicode_strings.go delete mode 100644 Examples/test-suite/go/union_parameter.go delete mode 100644 Examples/test-suite/go/union_scope.go delete mode 100644 Examples/test-suite/go/unions.go delete mode 100755 Examples/test-suite/go/unions_runme delete mode 100644 Examples/test-suite/go/using1.go delete mode 100755 Examples/test-suite/go/using1_runme delete mode 100644 Examples/test-suite/go/using2.go delete mode 100755 Examples/test-suite/go/using2_runme delete mode 100644 Examples/test-suite/go/using_composition.go delete mode 100755 Examples/test-suite/go/using_composition_runme delete mode 100644 Examples/test-suite/go/using_directive_and_declaration.go delete mode 100644 Examples/test-suite/go/using_directive_and_declaration_forward.go delete mode 100644 Examples/test-suite/go/using_extend.go delete mode 100755 Examples/test-suite/go/using_extend_runme delete mode 100644 Examples/test-suite/go/using_inherit.go delete mode 100755 Examples/test-suite/go/using_inherit_runme delete mode 100644 Examples/test-suite/go/using_namespace.go delete mode 100644 Examples/test-suite/go/using_namespace_loop.go delete mode 100644 Examples/test-suite/go/using_pointers.go delete mode 100644 Examples/test-suite/go/using_private.go delete mode 100755 Examples/test-suite/go/using_private_runme delete mode 100644 Examples/test-suite/go/using_protected.go delete mode 100755 Examples/test-suite/go/using_protected_runme delete mode 100644 Examples/test-suite/go/valuewrapper.go delete mode 100644 Examples/test-suite/go/valuewrapper_base.go delete mode 100644 Examples/test-suite/go/valuewrapper_const.go delete mode 100644 Examples/test-suite/go/valuewrapper_opaque.go delete mode 100644 Examples/test-suite/go/varargs.go delete mode 100644 Examples/test-suite/go/varargs_overload.go delete mode 100755 Examples/test-suite/go/varargs_overload_runme delete mode 100755 Examples/test-suite/go/varargs_runme delete mode 100644 Examples/test-suite/go/virtual_destructor.go delete mode 100644 Examples/test-suite/go/virtual_poly.go delete mode 100755 Examples/test-suite/go/virtual_poly_runme delete mode 100644 Examples/test-suite/go/virtual_poly_wrap.h delete mode 100644 Examples/test-suite/go/virtual_vs_nonvirtual_base.go delete mode 100644 Examples/test-suite/go/voidtest.go delete mode 100755 Examples/test-suite/go/voidtest_runme delete mode 100644 Examples/test-suite/go/wallkw.go delete mode 100644 Examples/test-suite/go/wrapmacro.go delete mode 100755 Examples/test-suite/go/wrapmacro_runme delete mode 100644 Examples/test-suite/overload_polymorphic.i~ delete mode 100644 Examples/test-suite/overload_rename.i~ delete mode 100644 Source/Modules/go.cxx~ diff --git a/Examples/python/import_packages/relativeimport2/runme3.py b/Examples/python/import_packages/relativeimport2/runme3.py deleted file mode 100644 index 4b0d112cf..000000000 --- a/Examples/python/import_packages/relativeimport2/runme3.py +++ /dev/null @@ -1,9 +0,0 @@ -# Test import of modules content from within __init__.py -print("Testing %module(package=...) + python 'import' in __init__.py") -import sys -if sys.version_info < (3, 0): - import py2.pkg2.bar - print(" Finished importing py2.pkg2.bar") -else: - import py3.pkg2.bar - print(" Finished importing py3.pkg2.bar") diff --git a/Examples/test-suite/common.mk~ b/Examples/test-suite/common.mk~ deleted file mode 100644 index 485453b5a..000000000 --- a/Examples/test-suite/common.mk~ +++ /dev/null @@ -1,746 +0,0 @@ -####################################################################### -# SWIG test suite makefile. -# The test suite comprises many different test cases, which have -# typically produced bugs in the past. The aim is to have the test -# cases compiling for every language modules. Some testcase have -# a runtime test which is written in each of the module's language. -# -# This makefile runs SWIG on the testcases, compiles the c/c++ code -# then builds the object code for use by the language. -# To complete a test in a language follow these guidelines: -# 1) Add testcases to CPP_TEST_CASES (c++) or C_TEST_CASES (c) or -# MULTI_CPP_TEST_CASES (multi-module c++ tests) -# 2) If not already done, create a makefile which: -# a) Defines LANGUAGE matching a language rule in Examples/Makefile, -# for example LANGUAGE = java -# b) Define rules for %.ctest, %.cpptest, %.multicpptest and %.clean. -# c) Define srcdir, top_srcdir and top_builddir (these are the -# equivalent to configure's variables of the same name). -# 3) One off special commandline options for a testcase can be added. -# See custom tests below. -# -# The 'check' target runs the testcases including SWIG invocation, -# C/C++ compilation, target language compilation (if any) and runtime -# test (if there is an associated 'runme' test). -# The 'partialcheck' target only invokes SWIG. -# The 'all' target is the same as the 'check' target but also includes -# known broken testcases. -# The 'clean' target cleans up. -# -# Note that the RUNTOOL, COMPILETOOL and SWIGTOOL variables can be used -# for invoking tools for the runtime tests and target language -# compiler (eg javac), and on SWIG respectively. For example, valgrind -# can be used for memory checking of the runtime tests using: -# make RUNTOOL="valgrind --leak-check=full" -# and valgrind can be used when invoking SWIG using: -# make SWIGTOOL="valgrind --tool=memcheck --trace-children=yes" -# Note: trace-children needed because of preinst-swig shell wrapper -# to the swig executable. -# -# An individual test run can be debugged easily: -# make director_string.cpptest RUNTOOL="gdb --args" -# -# The variables below can be overridden after including this makefile -####################################################################### - -####################################################################### -# Variables -####################################################################### - -ifneq (,$(USE_VALGRIND)) -VALGRIND_OPT = --leak-check=full -RUNTOOL = valgrind $(VALGRIND_OPT) -else -RUNTOOL = -endif -COMPILETOOL= -SWIGTOOL = - -SWIG = $(SWIGTOOL) $(top_builddir)/preinst-swig -SWIG_LIB = $(top_srcdir)/Lib -TEST_SUITE = test-suite -EXAMPLES = Examples -CXXSRCS = -CSRCS = -TARGETPREFIX = -TARGETSUFFIX = -SWIGOPT = -outcurrentdir -I$(top_srcdir)/$(EXAMPLES)/$(TEST_SUITE) -INCLUDES = -I$(top_srcdir)/$(EXAMPLES)/$(TEST_SUITE) -LIBS = -L. -LIBPREFIX = lib -ACTION = check -INTERFACEDIR = ../ -SRCDIR = $(srcdir)/ -SCRIPTDIR = $(srcdir) - -# Regenerate Makefile if Makefile.in or config.status have changed. -Makefile: $(srcdir)/Makefile.in ../../../config.status - cd ../../../ && $(SHELL) ./config.status $(EXAMPLES)/$(TEST_SUITE)/$(LANGUAGE)/Makefile - -# -# Please keep test cases in alphabetical order. -# Note that any whitespace after the last entry in each list will break make -# - -# Broken C++ test cases. (Can be run individually using: make testcase.cpptest) -CPP_TEST_BROKEN += \ - constants \ - cpp_broken \ - exception_partial_info \ - extend_variable \ - li_std_vector_ptr \ - li_boost_shared_ptr_template \ - nested_private \ - overload_complicated \ - rename_camel \ - template_default_pointer \ - template_private_assignment \ - template_expr \ - $(CPP11_TEST_BROKEN) - - -# Broken C test cases. (Can be run individually using: make testcase.ctest) -C_TEST_BROKEN += \ - tag_no_clash_with_variable - -# C++ test cases. (Can be run individually using: make testcase.cpptest) -CPP_TEST_CASES += \ - abstract_access \ - abstract_inherit \ - abstract_inherit_ok \ - abstract_signature \ - abstract_typedef \ - abstract_typedef2 \ - abstract_virtual \ - access_change \ - add_link \ - aggregate \ - allowexcept \ - allprotected \ - allprotected_not \ - anonymous_bitfield \ - apply_signed_char \ - apply_strings \ - argout \ - array_member \ - array_typedef_memberin \ - arrayref \ - arrays_dimensionless \ - arrays_global \ - arrays_global_twodim \ - arrays_scope \ - autodoc \ - bloody_hell \ - bools \ - catches \ - cast_operator \ - casts \ - char_binary \ - char_strings \ - class_forward \ - class_ignore \ - class_scope_weird \ - compactdefaultargs \ - const_const_2 \ - constant_pointers \ - constover \ - constructor_copy \ - constructor_exception \ - constructor_explicit \ - constructor_ignore \ - constructor_rename \ - constructor_value \ - contract \ - conversion \ - conversion_namespace \ - conversion_ns_template \ - cplusplus_throw \ - cpp_basic \ - cpp_enum \ - cpp_namespace \ - cpp_nodefault \ - cpp_static \ - cpp_typedef \ - curiously_recurring_template_pattern \ - default_args \ - default_arg_values \ - default_constructor \ - defvalue_constructor \ - derived_byvalue \ - derived_nested \ - destructor_reprotected \ - director_abstract \ - director_alternating \ - director_basic \ - director_binary_string \ - director_classes \ - director_classic \ - director_constructor \ - director_default \ - director_detect \ - director_enum \ - director_exception \ - director_extend \ - director_finalizer \ - director_frob \ - director_ignore \ - director_keywords \ - director_namespace_clash \ - director_nspace \ - director_nspace_director_name_collision \ - director_nested \ - director_overload \ - director_overload2 \ - director_primitives \ - director_protected \ - director_protected_overloaded \ - director_redefined \ - director_smartptr \ - director_thread \ - director_unroll \ - director_using \ - director_wombat \ - disown \ - dynamic_cast \ - empty \ - enum_ignore \ - enum_plus \ - enum_rename \ - enum_scope_template \ - enum_template \ - enum_thorough \ - enum_var \ - equality \ - evil_diamond \ - evil_diamond_ns \ - evil_diamond_prop \ - exception_order \ - extend \ - extend_constructor_destructor \ - extend_default \ - extend_placement \ - extend_special_variables \ - extend_template \ - extend_template_ns \ - extend_typedef_class \ - extern_c \ - extern_namespace \ - extern_throws \ - expressions \ - features \ - fragments \ - friends \ - funcptr_cpp \ - fvirtual \ - global_namespace \ - global_ns_arg \ - global_scope_types \ - global_vars \ - grouping \ - ignore_parameter \ - import_nomodule \ - inherit \ - inherit_missing \ - inherit_same_name \ - inherit_target_language \ - inherit_void_arg \ - inline_initializer \ - insert_directive \ - keyword_rename \ - kind \ - langobj \ - li_attribute \ - li_attribute_template \ - li_boost_shared_ptr \ - li_boost_shared_ptr_bits \ - li_boost_shared_ptr_template \ - li_boost_shared_ptr_attribute \ - li_carrays \ - li_cdata \ - li_cpointer \ - li_std_auto_ptr \ - li_stdint \ - li_swigtype_inout \ - li_typemaps \ - li_typemaps_apply \ - li_windows \ - long_long_apply \ - memberin_extend \ - member_funcptr_galore \ - member_pointer \ - member_template \ - minherit \ - minherit2 \ - mixed_types \ - multiple_inheritance \ - name_cxx \ - name_warnings \ - namespace_class \ - namespace_enum \ - namespace_extend \ - namespace_forward_declaration \ - namespace_nested \ - namespace_spaces \ - namespace_template \ - namespace_typedef_class \ - namespace_typemap \ - namespace_union \ - namespace_virtual_method \ - nspace \ - nspace_extend \ - naturalvar \ - naturalvar_more \ - naturalvar_onoff \ - nested_class \ - nested_directors \ - nested_comment \ - nested_scope \ - nested_workaround \ - newobject1 \ - null_pointer \ - operator_overload \ - operator_overload_break \ - operator_pointer_ref \ - operbool \ - ordering \ - overload_bool \ - overload_copy \ - overload_extend \ - overload_method \ - overload_numeric \ - overload_rename \ - overload_return_type \ - overload_simple \ - overload_subtype \ - overload_template \ - overload_template_fast \ - pointer_reference \ - preproc_constants \ - primitive_ref \ - private_assign \ - protected_rename \ - pure_virtual \ - redefined \ - redefined_not \ - refcount \ - reference_global_vars \ - register_par \ - rename1 \ - rename2 \ - rename3 \ - rename4 \ - rename_scope \ - rename_simple \ - rename_strip_encoder \ - rename_pcre_encoder \ - rename_pcre_enum \ - rename_predicates \ - restrict_cplusplus \ - return_const_value \ - return_value_scope \ - rname \ - samename \ - sizet \ - smart_pointer_const \ - smart_pointer_const2 \ - smart_pointer_const_overload \ - smart_pointer_extend \ - smart_pointer_member \ - smart_pointer_multi \ - smart_pointer_multi_typedef \ - smart_pointer_namespace \ - smart_pointer_namespace2 \ - smart_pointer_not \ - smart_pointer_overload \ - smart_pointer_protected \ - smart_pointer_rename \ - smart_pointer_simple \ - smart_pointer_static \ - smart_pointer_template_const_overload \ - smart_pointer_template_defaults_overload \ - smart_pointer_templatemethods \ - smart_pointer_templatevariables \ - smart_pointer_typedef \ - special_variables \ - special_variable_macros \ - static_array_member \ - static_const_member \ - static_const_member_2 \ - struct_initialization_cpp \ - struct_value \ - symbol_clash \ - template_arg_replace \ - template_arg_scope \ - template_arg_typename \ - template_array_numeric \ - template_basic \ - template_base_template \ - template_classes \ - template_const_ref \ - template_construct \ - template_default \ - template_default2 \ - template_default_arg \ - template_default_arg_virtual_destructor \ - template_default_class_parms \ - template_default_class_parms_typedef \ - template_default_inherit \ - template_default_qualify \ - template_default_vw \ - template_enum \ - template_enum_ns_inherit \ - template_enum_typedef \ - template_explicit \ - template_extend1 \ - template_extend2 \ - template_extend_overload \ - template_extend_overload_2 \ - template_forward \ - template_inherit \ - template_inherit_abstract \ - template_int_const \ - template_methods \ - template_namespace_forward_declaration \ - template_using_directive_and_declaration_forward \ - template_nested \ - template_nested_typemaps \ - template_ns \ - template_ns2 \ - template_ns3 \ - template_ns4 \ - template_ns_enum \ - template_ns_enum2 \ - template_ns_inherit \ - template_ns_scope \ - template_partial_arg \ - template_partial_specialization \ - template_partial_specialization_typedef \ - template_qualifier \ - template_ref_type \ - template_rename \ - template_retvalue \ - template_specialization \ - template_specialization_defarg \ - template_specialization_enum \ - template_static \ - template_tbase_template \ - template_template_parameters \ - template_typedef \ - template_typedef_class_template \ - template_typedef_cplx \ - template_typedef_cplx2 \ - template_typedef_cplx3 \ - template_typedef_cplx4 \ - template_typedef_cplx5 \ - template_typedef_funcptr \ - template_typedef_inherit \ - template_typedef_ns \ - template_typedef_ptr \ - template_typedef_rec \ - template_typedef_typedef \ - template_typemaps \ - template_typemaps_typedef \ - template_typemaps_typedef2 \ - template_using \ - template_virtual \ - template_whitespace \ - threads \ - threads_exception \ - throw_exception \ - typedef_array_member \ - typedef_class \ - typedef_funcptr \ - typedef_inherit \ - typedef_mptr \ - typedef_reference \ - typedef_scope \ - typedef_sizet \ - typedef_struct \ - typedef_typedef \ - typemap_arrays \ - typemap_array_qualifiers \ - typemap_delete \ - typemap_directorout \ - typemap_global_scope \ - typemap_manyargs \ - typemap_namespace \ - typemap_ns_using \ - typemap_numinputs \ - typemap_template \ - typemap_template_parm_typedef \ - typemap_out_optimal \ - typemap_qualifier_strip \ - typemap_variables \ - typemap_various \ - typename \ - types_directive \ - unicode_strings \ - union_scope \ - using1 \ - using2 \ - using_composition \ - using_directive_and_declaration \ - using_directive_and_declaration_forward \ - using_extend \ - using_inherit \ - using_namespace \ - using_namespace_loop \ - using_pointers \ - using_private \ - using_protected \ - valuewrapper \ - valuewrapper_base \ - valuewrapper_const \ - valuewrapper_opaque \ - varargs \ - varargs_overload \ - virtual_destructor \ - virtual_poly \ - virtual_vs_nonvirtual_base \ - voidtest \ - wallkw \ - wrapmacro - -# C++11 test cases. -CPP11_TEST_CASES = \ - cpp11_alignment \ - cpp11_alternate_function_syntax \ - cpp11_constexpr \ - cpp11_decltype \ - cpp11_default_delete \ - cpp11_delegating_constructors \ - cpp11_explicit_conversion_operators \ - cpp11_final_override \ - cpp11_function_objects \ - cpp11_inheriting_constructors \ - cpp11_initializer_list \ - cpp11_initializer_list_extend \ - cpp11_lambda_functions \ - cpp11_noexcept \ - cpp11_null_pointer_constant \ - cpp11_raw_string_literals \ - cpp11_result_of \ - cpp11_rvalue_reference \ - cpp11_rvalue_reference2 \ - cpp11_rvalue_reference3 \ - cpp11_sizeof_object \ - cpp11_static_assert \ - cpp11_thread_local \ - cpp11_template_double_brackets \ - cpp11_template_explicit \ - cpp11_template_typedefs \ - cpp11_type_traits \ - cpp11_uniform_initialization \ - cpp11_unrestricted_unions \ - cpp11_userdefined_literals \ - -# Broken C++11 test cases. -CPP11_TEST_BROKEN = \ -# cpp11_hash_tables \ # not fully implemented yet -# cpp11_strongly_typed_enumerations \ # SWIG not quite getting this right yet in all langs -# cpp11_variadic_templates \ # Broken for some languages (such as Java) -# cpp11_reference_wrapper \ # No typemaps - - -# -# Put all the heavy STD/STL cases here, where they can be skipped if needed -# -CPP_STD_TEST_CASES += \ - director_string \ - ignore_template_constructor \ - li_std_combinations \ - li_std_deque \ - li_std_except \ - li_std_except_as_class \ - li_std_map \ - li_std_pair \ - li_std_pair_using \ - li_std_string \ - li_std_vector \ - li_std_vector_enum \ - li_std_vector_member_var\ - naturalvar \ - smart_pointer_inherit \ - template_typedef_fnc \ - template_type_namespace \ - template_opaque -# li_std_list - - -ifndef SKIP_CPP_STD_CASES -CPP_TEST_CASES += ${CPP_STD_TEST_CASES} -endif - -ifneq (,$(HAVE_CXX11_COMPILER)) -CPP_TEST_CASES += $(CPP11_TEST_CASES) -endif - -# C test cases. (Can be run individually using: make testcase.ctest) -C_TEST_CASES += \ - arrays \ - bom_utf8 \ - c_delete \ - c_delete_function \ - char_constant \ - const_const \ - constant_expr \ - empty \ - enums \ - enum_forward \ - enum_macro \ - enum_missing \ - extern_declaration \ - funcptr \ - function_typedef \ - global_functions \ - immutable_values \ - inctest \ - infinity \ - integers \ - keyword_rename \ - lextype \ - li_carrays \ - li_cdata \ - li_cmalloc \ - li_constraints \ - li_cpointer \ - li_math \ - long_long \ - memberin_extend_c \ - name \ - nested \ - nested_extend_c \ - nested_structs \ - newobject2 \ - overload_extend \ - overload_extendc \ - preproc \ - preproc_constants_c \ - preproc_defined \ - preproc_include \ - preproc_line_file \ - ret_by_value \ - simple_array \ - sizeof_pointer \ - sneaky1 \ - string_simple \ - struct_rename \ - struct_initialization \ - typedef_struct \ - typemap_subst \ - union_parameter \ - unions - - -# Multi-module C++ test cases . (Can be run individually using make testcase.multicpptest) -MULTI_CPP_TEST_CASES += \ - clientdata_prop \ - imports \ - import_stl \ - packageoption \ - mod \ - template_typedef_import \ - multi_import - -# Custom tests - tests with additional commandline options -wallkw.cpptest: SWIGOPT += -Wallkw -preproc_include.ctest: SWIGOPT += -includeall - - -NOT_BROKEN_TEST_CASES = $(CPP_TEST_CASES:=.cpptest) \ - $(C_TEST_CASES:=.ctest) \ - $(MULTI_CPP_TEST_CASES:=.multicpptest) \ - $(EXTRA_TEST_CASES) - -BROKEN_TEST_CASES = $(CPP_TEST_BROKEN:=.cpptest) \ - $(C_TEST_BROKEN:=.ctest) - -ALL_CLEAN = $(CPP_TEST_CASES:=.clean) \ - $(C_TEST_CASES:=.clean) \ - $(MULTI_CPP_TEST_CASES:=.clean) \ - $(CPP_TEST_BROKEN:=.clean) \ - $(C_TEST_BROKEN:=.clean) - -####################################################################### -# Error test suite has its own set of test cases -####################################################################### -ifneq (,$(ERROR_TEST_CASES)) -check: $(ERROR_TEST_CASES) -else - -####################################################################### -# The following applies for all module languages -####################################################################### -all: $(NOT_BROKEN_TEST_CASES) $(BROKEN_TEST_CASES) - -broken: $(BROKEN_TEST_CASES) - -check: $(NOT_BROKEN_TEST_CASES) - -check-c: $(C_TEST_CASES:=.ctest) - -check-cpp: $(CPP_TEST_CASES:=.cpptest) - -check-cpp11: $(CPP11_TEST_CASES:=.cpptest) - -endif - -# partialcheck target runs SWIG only, ie no compilation or running of tests (for a subset of languages) -partialcheck: - $(MAKE) check CC=true CXX=true LDSHARED=true CXXSHARED=true RUNTOOL=true COMPILETOOL=true - -swig_and_compile_cpp = \ - $(MAKE) -f $(top_builddir)/$(EXAMPLES)/Makefile SRCDIR="$(SRCDIR)" CXXSRCS="$(CXXSRCS)" \ - SWIG_LIB="$(SWIG_LIB)" SWIG="$(SWIG)" \ - INCLUDES="$(INCLUDES)" SWIGOPT="$(SWIGOPT)" NOLINK=true \ - TARGET="$(TARGETPREFIX)$*$(TARGETSUFFIX)" INTERFACEDIR="$(INTERFACEDIR)" INTERFACE="$*.i" \ - $(LANGUAGE)$(VARIANT)_cpp - -swig_and_compile_c = \ - $(MAKE) -f $(top_builddir)/$(EXAMPLES)/Makefile SRCDIR="$(SRCDIR)" CSRCS="$(CSRCS)" \ - SWIG_LIB="$(SWIG_LIB)" SWIG="$(SWIG)" \ - INCLUDES="$(INCLUDES)" SWIGOPT="$(SWIGOPT)" NOLINK=true \ - TARGET="$(TARGETPREFIX)$*$(TARGETSUFFIX)" INTERFACEDIR="$(INTERFACEDIR)" INTERFACE="$*.i" \ - $(LANGUAGE)$(VARIANT) - -swig_and_compile_multi_cpp = \ - for f in `cat $(top_srcdir)/$(EXAMPLES)/$(TEST_SUITE)/$*.list` ; do \ - $(MAKE) -f $(top_builddir)/$(EXAMPLES)/Makefile SRCDIR="$(SRCDIR)" CXXSRCS="$(CXXSRCS)" \ - SWIG_LIB="$(SWIG_LIB)" SWIG="$(SWIG)" LIBS='$(LIBS)' \ - INCLUDES="$(INCLUDES)" SWIGOPT="$(SWIGOPT)" NOLINK=true \ - TARGET="$(TARGETPREFIX)$${f}$(TARGETSUFFIX)" INTERFACEDIR="$(INTERFACEDIR)" INTERFACE="$$f.i" \ - $(LANGUAGE)$(VARIANT)_cpp; \ - done - -swig_and_compile_external = \ - $(MAKE) -f $(top_builddir)/$(EXAMPLES)/Makefile SRCDIR="$(SRCDIR)" \ - SWIG_LIB="$(SWIG_LIB)" SWIG="$(SWIG)" \ - TARGET="$*_wrap_hdr.h" \ - $(LANGUAGE)$(VARIANT)_externalhdr; \ - $(MAKE) -f $(top_builddir)/$(EXAMPLES)/Makefile SRCDIR="$(SRCDIR)" CXXSRCS="$(CXXSRCS) $*_external.cxx" \ - SWIG_LIB="$(SWIG_LIB)" SWIG="$(SWIG)" \ - INCLUDES="$(INCLUDES)" SWIGOPT="$(SWIGOPT)" NOLINK=true \ - TARGET="$(TARGETPREFIX)$*$(TARGETSUFFIX)" INTERFACEDIR="$(INTERFACEDIR)" INTERFACE="$*.i" \ - $(LANGUAGE)$(VARIANT)_cpp - -swig_and_compile_runtime = \ - -setup = \ - if [ -f $(SCRIPTDIR)/$(SCRIPTPREFIX)$*$(SCRIPTSUFFIX) ]; then \ - echo "$(ACTION)ing $(LANGUAGE) testcase $* (with run test)" ; \ - else \ - echo "$(ACTION)ing $(LANGUAGE) testcase $*" ; \ - fi; - - - -####################################################################### -# Clean -####################################################################### -clean: $(ALL_CLEAN) - -distclean: clean - @rm -f Makefile - -.PHONY: all check partialcheck broken clean distclean - diff --git a/Examples/test-suite/go/abstract_access.go b/Examples/test-suite/go/abstract_access.go deleted file mode 100644 index c2bc76f18..000000000 --- a/Examples/test-suite/go/abstract_access.go +++ /dev/null @@ -1,311 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../abstract_access.i - -package abstract_access - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrA uintptr - -func (p SwigcptrA) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrA) SwigIsA() { -} - -var _wrap_delete_A unsafe.Pointer - -func _swig_wrap_delete_A(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_A, _swig_p) - return -} - -func DeleteA(arg1 A) { - _swig_wrap_delete_A(arg1.Swigcptr()) -} - -var _wrap_A_z unsafe.Pointer - -func _swig_wrap_A_z(base SwigcptrA) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_A_z, _swig_p) - return -} - -func (arg1 SwigcptrA) Z() (_swig_ret int) { - return _swig_wrap_A_z(arg1) -} - -var _wrap_A_do_x unsafe.Pointer - -func _swig_wrap_A_do_x(base SwigcptrA) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_A_do_x, _swig_p) - return -} - -func (arg1 SwigcptrA) Do_x() (_swig_ret int) { - return _swig_wrap_A_do_x(arg1) -} - -type A interface { - Swigcptr() uintptr - SwigIsA() - Z() (_swig_ret int) - Do_x() (_swig_ret int) -} - -type SwigcptrB uintptr - -func (p SwigcptrB) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrB) SwigIsB() { -} - -var _wrap_delete_B unsafe.Pointer - -func _swig_wrap_delete_B(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_B, _swig_p) - return -} - -func DeleteB(arg1 B) { - _swig_wrap_delete_B(arg1.Swigcptr()) -} - -var _wrap_B_z unsafe.Pointer - -func _swig_wrap_B_z(base SwigcptrB) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_B_z, _swig_p) - return -} - -func (_swig_base SwigcptrB) Z() (_swig_ret int) { - return _swig_wrap_B_z(_swig_base) -} - -var _wrap_B_do_x unsafe.Pointer - -func _swig_wrap_B_do_x(base SwigcptrB) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_B_do_x, _swig_p) - return -} - -func (_swig_base SwigcptrB) Do_x() (_swig_ret int) { - return _swig_wrap_B_do_x(_swig_base) -} - -func (p SwigcptrB) SwigIsA() { -} - -func (p SwigcptrB) SwigGetA() A { - return SwigcptrA(p.Swigcptr()) -} - -type B interface { - Swigcptr() uintptr - SwigIsB() - Z() (_swig_ret int) - Do_x() (_swig_ret int) - SwigIsA() - SwigGetA() A -} - -type SwigcptrC uintptr - -func (p SwigcptrC) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrC) SwigIsC() { -} - -var _wrap_delete_C unsafe.Pointer - -func _swig_wrap_delete_C(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_C, _swig_p) - return -} - -func DeleteC(arg1 C) { - _swig_wrap_delete_C(arg1.Swigcptr()) -} - -var _wrap_C_z unsafe.Pointer - -func _swig_wrap_C_z(base SwigcptrC) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_C_z, _swig_p) - return -} - -func (_swig_base SwigcptrC) Z() (_swig_ret int) { - return _swig_wrap_C_z(_swig_base) -} - -var _wrap_C_do_x unsafe.Pointer - -func _swig_wrap_C_do_x(base SwigcptrC) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_C_do_x, _swig_p) - return -} - -func (_swig_base SwigcptrC) Do_x() (_swig_ret int) { - return _swig_wrap_C_do_x(_swig_base) -} - -func (p SwigcptrC) SwigIsB() { -} - -func (p SwigcptrC) SwigGetB() B { - return SwigcptrB(p.Swigcptr()) -} - -func (p SwigcptrC) SwigIsA() { -} - -func (p SwigcptrC) SwigGetA() A { - return SwigcptrA(p.Swigcptr()) -} - -type C interface { - Swigcptr() uintptr - SwigIsC() - Z() (_swig_ret int) - Do_x() (_swig_ret int) - SwigIsB() - SwigGetB() B - SwigIsA() - SwigGetA() A -} - -type SwigcptrD uintptr - -func (p SwigcptrD) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrD) SwigIsD() { -} - -var _wrap_new_D unsafe.Pointer - -func _swig_wrap_new_D() (base SwigcptrD) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_D, _swig_p) - return -} - -func NewD() (_swig_ret D) { - return _swig_wrap_new_D() -} - -var _wrap_delete_D unsafe.Pointer - -func _swig_wrap_delete_D(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_D, _swig_p) - return -} - -func DeleteD(arg1 D) { - _swig_wrap_delete_D(arg1.Swigcptr()) -} - -var _wrap_D_z unsafe.Pointer - -func _swig_wrap_D_z(base SwigcptrD) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_D_z, _swig_p) - return -} - -func (_swig_base SwigcptrD) Z() (_swig_ret int) { - return _swig_wrap_D_z(_swig_base) -} - -var _wrap_D_do_x unsafe.Pointer - -func _swig_wrap_D_do_x(base SwigcptrD) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_D_do_x, _swig_p) - return -} - -func (_swig_base SwigcptrD) Do_x() (_swig_ret int) { - return _swig_wrap_D_do_x(_swig_base) -} - -func (p SwigcptrD) SwigIsC() { -} - -func (p SwigcptrD) SwigGetC() C { - return SwigcptrC(p.Swigcptr()) -} - -func (p SwigcptrD) SwigIsB() { -} - -func (p SwigcptrD) SwigGetB() B { - return SwigcptrB(p.Swigcptr()) -} - -func (p SwigcptrD) SwigIsA() { -} - -func (p SwigcptrD) SwigGetA() A { - return SwigcptrA(p.Swigcptr()) -} - -type D interface { - Swigcptr() uintptr - SwigIsD() - Z() (_swig_ret int) - Do_x() (_swig_ret int) - SwigIsC() - SwigGetC() C - SwigIsB() - SwigGetB() B - SwigIsA() - SwigGetA() A -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/abstract_access_runme b/Examples/test-suite/go/abstract_access_runme deleted file mode 100755 index 50e545dac..000000000 Binary files a/Examples/test-suite/go/abstract_access_runme and /dev/null differ diff --git a/Examples/test-suite/go/abstract_inherit.go b/Examples/test-suite/go/abstract_inherit.go deleted file mode 100644 index a33f3826f..000000000 --- a/Examples/test-suite/go/abstract_inherit.go +++ /dev/null @@ -1,285 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../abstract_inherit.i - -package abstract_inherit - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrFoo uintptr - -func (p SwigcptrFoo) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrFoo) SwigIsFoo() { -} - -var _wrap_delete_Foo unsafe.Pointer - -func _swig_wrap_delete_Foo(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Foo, _swig_p) - return -} - -func DeleteFoo(arg1 Foo) { - _swig_wrap_delete_Foo(arg1.Swigcptr()) -} - -var _wrap_Foo_blah unsafe.Pointer - -func _swig_wrap_Foo_blah(base SwigcptrFoo) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_blah, _swig_p) - return -} - -func (arg1 SwigcptrFoo) Blah() (_swig_ret int) { - return _swig_wrap_Foo_blah(arg1) -} - -type Foo interface { - Swigcptr() uintptr - SwigIsFoo() - Blah() (_swig_ret int) -} - -type SwigcptrBar uintptr - -func (p SwigcptrBar) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrBar) SwigIsBar() { -} - -var _wrap_delete_Bar unsafe.Pointer - -func _swig_wrap_delete_Bar(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Bar, _swig_p) - return -} - -func DeleteBar(arg1 Bar) { - _swig_wrap_delete_Bar(arg1.Swigcptr()) -} - -var _wrap_Bar_blah unsafe.Pointer - -func _swig_wrap_Bar_blah(base SwigcptrBar) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Bar_blah, _swig_p) - return -} - -func (_swig_base SwigcptrBar) Blah() (_swig_ret int) { - return _swig_wrap_Bar_blah(_swig_base) -} - -func (p SwigcptrBar) SwigIsFoo() { -} - -func (p SwigcptrBar) SwigGetFoo() Foo { - return SwigcptrFoo(p.Swigcptr()) -} - -type Bar interface { - Swigcptr() uintptr - SwigIsBar() - Blah() (_swig_ret int) - SwigIsFoo() - SwigGetFoo() Foo -} - -type SwigcptrSpam uintptr - -func (p SwigcptrSpam) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrSpam) SwigIsSpam() { -} - -var _wrap_delete_Spam unsafe.Pointer - -func _swig_wrap_delete_Spam(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Spam, _swig_p) - return -} - -func DeleteSpam(arg1 Spam) { - _swig_wrap_delete_Spam(arg1.Swigcptr()) -} - -var _wrap_Spam_blah unsafe.Pointer - -func _swig_wrap_Spam_blah(base SwigcptrSpam) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Spam_blah, _swig_p) - return -} - -func (_swig_base SwigcptrSpam) Blah() (_swig_ret int) { - return _swig_wrap_Spam_blah(_swig_base) -} - -func (p SwigcptrSpam) SwigIsFoo() { -} - -func (p SwigcptrSpam) SwigGetFoo() Foo { - return SwigcptrFoo(p.Swigcptr()) -} - -type Spam interface { - Swigcptr() uintptr - SwigIsSpam() - Blah() (_swig_ret int) - SwigIsFoo() - SwigGetFoo() Foo -} - -type SwigcptrNRFilter_i uintptr - -func (p SwigcptrNRFilter_i) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrNRFilter_i) SwigIsNRFilter_i() { -} - -var _wrap_delete_NRFilter_i unsafe.Pointer - -func _swig_wrap_delete_NRFilter_i(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_NRFilter_i, _swig_p) - return -} - -func DeleteNRFilter_i(arg1 NRFilter_i) { - _swig_wrap_delete_NRFilter_i(arg1.Swigcptr()) -} - -type NRFilter_i interface { - Swigcptr() uintptr - SwigIsNRFilter_i() -} - -type SwigcptrNRRCFilter_i uintptr - -func (p SwigcptrNRRCFilter_i) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrNRRCFilter_i) SwigIsNRRCFilter_i() { -} - -var _wrap_delete_NRRCFilter_i unsafe.Pointer - -func _swig_wrap_delete_NRRCFilter_i(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_NRRCFilter_i, _swig_p) - return -} - -func DeleteNRRCFilter_i(arg1 NRRCFilter_i) { - _swig_wrap_delete_NRRCFilter_i(arg1.Swigcptr()) -} - -func (p SwigcptrNRRCFilter_i) SwigIsNRFilter_i() { -} - -func (p SwigcptrNRRCFilter_i) SwigGetNRFilter_i() NRFilter_i { - return SwigcptrNRFilter_i(p.Swigcptr()) -} - -type NRRCFilter_i interface { - Swigcptr() uintptr - SwigIsNRRCFilter_i() - SwigIsNRFilter_i() - SwigGetNRFilter_i() NRFilter_i -} - -type SwigcptrNRRCFilterpro_i uintptr - -func (p SwigcptrNRRCFilterpro_i) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrNRRCFilterpro_i) SwigIsNRRCFilterpro_i() { -} - -var _wrap_delete_NRRCFilterpro_i unsafe.Pointer - -func _swig_wrap_delete_NRRCFilterpro_i(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_NRRCFilterpro_i, _swig_p) - return -} - -func DeleteNRRCFilterpro_i(arg1 NRRCFilterpro_i) { - _swig_wrap_delete_NRRCFilterpro_i(arg1.Swigcptr()) -} - -type NRRCFilterpro_i interface { - Swigcptr() uintptr - SwigIsNRRCFilterpro_i() -} - -type SwigcptrNRRCFilterpri_i uintptr - -func (p SwigcptrNRRCFilterpri_i) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrNRRCFilterpri_i) SwigIsNRRCFilterpri_i() { -} - -var _wrap_delete_NRRCFilterpri_i unsafe.Pointer - -func _swig_wrap_delete_NRRCFilterpri_i(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_NRRCFilterpri_i, _swig_p) - return -} - -func DeleteNRRCFilterpri_i(arg1 NRRCFilterpri_i) { - _swig_wrap_delete_NRRCFilterpri_i(arg1.Swigcptr()) -} - -type NRRCFilterpri_i interface { - Swigcptr() uintptr - SwigIsNRRCFilterpri_i() -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/abstract_inherit_ok.go b/Examples/test-suite/go/abstract_inherit_ok.go deleted file mode 100644 index ba6812af7..000000000 --- a/Examples/test-suite/go/abstract_inherit_ok.go +++ /dev/null @@ -1,136 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../abstract_inherit_ok.i - -package abstract_inherit_ok - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrFoo uintptr - -func (p SwigcptrFoo) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrFoo) SwigIsFoo() { -} - -var _wrap_delete_Foo unsafe.Pointer - -func _swig_wrap_delete_Foo(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Foo, _swig_p) - return -} - -func DeleteFoo(arg1 Foo) { - _swig_wrap_delete_Foo(arg1.Swigcptr()) -} - -var _wrap_Foo_blah unsafe.Pointer - -func _swig_wrap_Foo_blah(base SwigcptrFoo) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_blah, _swig_p) - return -} - -func (arg1 SwigcptrFoo) Blah() (_swig_ret int) { - return _swig_wrap_Foo_blah(arg1) -} - -type Foo interface { - Swigcptr() uintptr - SwigIsFoo() - Blah() (_swig_ret int) -} - -type SwigcptrSpam uintptr - -func (p SwigcptrSpam) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrSpam) SwigIsSpam() { -} - -var _wrap_new_Spam unsafe.Pointer - -func _swig_wrap_new_Spam() (base SwigcptrSpam) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Spam, _swig_p) - return -} - -func NewSpam() (_swig_ret Spam) { - return _swig_wrap_new_Spam() -} - -var _wrap_delete_Spam unsafe.Pointer - -func _swig_wrap_delete_Spam(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Spam, _swig_p) - return -} - -func DeleteSpam(arg1 Spam) { - _swig_wrap_delete_Spam(arg1.Swigcptr()) -} - -var _wrap_Spam_blah unsafe.Pointer - -func _swig_wrap_Spam_blah(base SwigcptrSpam) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Spam_blah, _swig_p) - return -} - -func (_swig_base SwigcptrSpam) Blah() (_swig_ret int) { - return _swig_wrap_Spam_blah(_swig_base) -} - -func (p SwigcptrSpam) SwigIsFoo() { -} - -func (p SwigcptrSpam) SwigGetFoo() Foo { - return SwigcptrFoo(p.Swigcptr()) -} - -type Spam interface { - Swigcptr() uintptr - SwigIsSpam() - Blah() (_swig_ret int) - SwigIsFoo() - SwigGetFoo() Foo -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/abstract_signature.go b/Examples/test-suite/go/abstract_signature.go deleted file mode 100644 index d2917d233..000000000 --- a/Examples/test-suite/go/abstract_signature.go +++ /dev/null @@ -1,147 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../abstract_signature.i - -package abstract_signature - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrAbstract_foo uintptr - -func (p SwigcptrAbstract_foo) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrAbstract_foo) SwigIsAbstract_foo() { -} - -var _wrap_delete_abstract_foo unsafe.Pointer - -func _swig_wrap_delete_abstract_foo(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_abstract_foo, _swig_p) - return -} - -func DeleteAbstract_foo(arg1 Abstract_foo) { - _swig_wrap_delete_abstract_foo(arg1.Swigcptr()) -} - -var _wrap_abstract_foo_meth unsafe.Pointer - -func _swig_wrap_abstract_foo_meth(base SwigcptrAbstract_foo, _ int) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_abstract_foo_meth, _swig_p) - return -} - -func (arg1 SwigcptrAbstract_foo) Meth(arg2 int) (_swig_ret int) { - return _swig_wrap_abstract_foo_meth(arg1, arg2) -} - -type Abstract_foo interface { - Swigcptr() uintptr - SwigIsAbstract_foo() - Meth(arg2 int) (_swig_ret int) -} - -type SwigcptrAbstract_bar uintptr - -func (p SwigcptrAbstract_bar) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrAbstract_bar) SwigIsAbstract_bar() { -} - -var _wrap_delete_abstract_bar unsafe.Pointer - -func _swig_wrap_delete_abstract_bar(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_abstract_bar, _swig_p) - return -} - -func DeleteAbstract_bar(arg1 Abstract_bar) { - _swig_wrap_delete_abstract_bar(arg1.Swigcptr()) -} - -var _wrap_abstract_bar_meth__SWIG_0 unsafe.Pointer - -func _swig_wrap_abstract_bar_meth__SWIG_0(base SwigcptrAbstract_bar, _ int) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_abstract_bar_meth__SWIG_0, _swig_p) - return -} - -func (arg1 SwigcptrAbstract_bar) Meth__SWIG_0(arg2 int) (_swig_ret int) { - return _swig_wrap_abstract_bar_meth__SWIG_0(arg1, arg2) -} - -var _wrap_abstract_bar_meth__SWIG_1 unsafe.Pointer - -func _swig_wrap_abstract_bar_meth__SWIG_1(base SwigcptrAbstract_bar, _ int, _ int) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_abstract_bar_meth__SWIG_1, _swig_p) - return -} - -func (arg1 SwigcptrAbstract_bar) Meth__SWIG_1(arg2 int, arg3 int) (_swig_ret int) { - return _swig_wrap_abstract_bar_meth__SWIG_1(arg1, arg2, arg3) -} - -func (p SwigcptrAbstract_bar) Meth(a ...interface{}) int { - argc := len(a) - if argc == 1 { - return p.Meth__SWIG_0(a[0].(int)) - } - if argc == 2 { - return p.Meth__SWIG_1(a[0].(int), a[1].(int)) - } - panic("No match for overloaded function call") -} - -func (p SwigcptrAbstract_bar) SwigIsAbstract_foo() { -} - -func (p SwigcptrAbstract_bar) SwigGetAbstract_foo() Abstract_foo { - return SwigcptrAbstract_foo(p.Swigcptr()) -} - -type Abstract_bar interface { - Swigcptr() uintptr - SwigIsAbstract_bar() - Meth(a ...interface{}) int - SwigIsAbstract_foo() - SwigGetAbstract_foo() Abstract_foo -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/abstract_typedef.go b/Examples/test-suite/go/abstract_typedef.go deleted file mode 100644 index c1d86f209..000000000 --- a/Examples/test-suite/go/abstract_typedef.go +++ /dev/null @@ -1,174 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../abstract_typedef.i - -package abstract_typedef - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrEngine uintptr - -func (p SwigcptrEngine) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrEngine) SwigIsEngine() { -} - -var _wrap_new_Engine unsafe.Pointer - -func _swig_wrap_new_Engine() (base SwigcptrEngine) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Engine, _swig_p) - return -} - -func NewEngine() (_swig_ret Engine) { - return _swig_wrap_new_Engine() -} - -var _wrap_delete_Engine unsafe.Pointer - -func _swig_wrap_delete_Engine(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Engine, _swig_p) - return -} - -func DeleteEngine(arg1 Engine) { - _swig_wrap_delete_Engine(arg1.Swigcptr()) -} - -type Engine interface { - Swigcptr() uintptr - SwigIsEngine() -} - -type SwigcptrAbstractBaseClass uintptr - -func (p SwigcptrAbstractBaseClass) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrAbstractBaseClass) SwigIsAbstractBaseClass() { -} - -var _wrap_delete_AbstractBaseClass unsafe.Pointer - -func _swig_wrap_delete_AbstractBaseClass(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_AbstractBaseClass, _swig_p) - return -} - -func DeleteAbstractBaseClass(arg1 AbstractBaseClass) { - _swig_wrap_delete_AbstractBaseClass(arg1.Swigcptr()) -} - -var _wrap_AbstractBaseClass_write unsafe.Pointer - -func _swig_wrap_AbstractBaseClass_write(base SwigcptrAbstractBaseClass, _ uintptr) (_ bool) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_AbstractBaseClass_write, _swig_p) - return -} - -func (arg1 SwigcptrAbstractBaseClass) Write(arg2 Engine) (_swig_ret bool) { - return _swig_wrap_AbstractBaseClass_write(arg1, arg2.Swigcptr()) -} - -type AbstractBaseClass interface { - Swigcptr() uintptr - SwigIsAbstractBaseClass() - Write(arg2 Engine) (_swig_ret bool) -} - -type SwigcptrA uintptr - -func (p SwigcptrA) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrA) SwigIsA() { -} - -var _wrap_new_A unsafe.Pointer - -func _swig_wrap_new_A() (base SwigcptrA) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_A, _swig_p) - return -} - -func NewA() (_swig_ret A) { - return _swig_wrap_new_A() -} - -var _wrap_delete_A unsafe.Pointer - -func _swig_wrap_delete_A(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_A, _swig_p) - return -} - -func DeleteA(arg1 A) { - _swig_wrap_delete_A(arg1.Swigcptr()) -} - -var _wrap_A_write unsafe.Pointer - -func _swig_wrap_A_write(base SwigcptrA, _ uintptr) (_ bool) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_A_write, _swig_p) - return -} - -func (_swig_base SwigcptrA) Write(arg1 Engine) (_swig_ret bool) { - return _swig_wrap_A_write(_swig_base, arg1.Swigcptr()) -} - -func (p SwigcptrA) SwigIsAbstractBaseClass() { -} - -func (p SwigcptrA) SwigGetAbstractBaseClass() AbstractBaseClass { - return SwigcptrAbstractBaseClass(p.Swigcptr()) -} - -type A interface { - Swigcptr() uintptr - SwigIsA() - Write(arg1 Engine) (_swig_ret bool) - SwigIsAbstractBaseClass() - SwigGetAbstractBaseClass() AbstractBaseClass -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/abstract_typedef2.go b/Examples/test-suite/go/abstract_typedef2.go deleted file mode 100644 index 24cc29b62..000000000 --- a/Examples/test-suite/go/abstract_typedef2.go +++ /dev/null @@ -1,184 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../abstract_typedef2.i - -package abstract_typedef2 - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type FieldDim int -var _wrap_UnaryField unsafe.Pointer - -func _swig_getUnaryField() (_swig_ret FieldDim) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_UnaryField, _swig_p) - return -} -var UnaryField FieldDim = _swig_getUnaryField() -var _wrap_BinaryField unsafe.Pointer - -func _swig_getBinaryField() (_swig_ret FieldDim) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_BinaryField, _swig_p) - return -} -var BinaryField FieldDim = _swig_getBinaryField() -type SwigcptrBase_UF uintptr - -func (p SwigcptrBase_UF) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrBase_UF) SwigIsBase_UF() { -} - -var _wrap_delete_Base_UF unsafe.Pointer - -func _swig_wrap_delete_Base_UF(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Base_UF, _swig_p) - return -} - -func DeleteBase_UF(arg1 Base_UF) { - _swig_wrap_delete_Base_UF(arg1.Swigcptr()) -} - -var _wrap_Base_UF_set unsafe.Pointer - -func _swig_wrap_Base_UF_set(base SwigcptrBase_UF, _ uint) (_ SwigcptrFacet_Sl_UnaryField_Sg_) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Base_UF_set, _swig_p) - return -} - -func (arg1 SwigcptrBase_UF) Set(arg2 uint) (_swig_ret Facet_Sl_UnaryField_Sg_) { - return _swig_wrap_Base_UF_set(arg1, arg2) -} - -type Base_UF interface { - Swigcptr() uintptr - SwigIsBase_UF() - Set(arg2 uint) (_swig_ret Facet_Sl_UnaryField_Sg_) -} - -type SwigcptrA_UF uintptr - -func (p SwigcptrA_UF) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrA_UF) SwigIsA_UF() { -} - -var _wrap_new_A_UF__SWIG_0 unsafe.Pointer - -func _swig_wrap_new_A_UF__SWIG_0(base int) (_ SwigcptrA_UF) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_A_UF__SWIG_0, _swig_p) - return -} - -func NewA_UF__SWIG_0(arg1 int) (_swig_ret A_UF) { - return _swig_wrap_new_A_UF__SWIG_0(arg1) -} - -var _wrap_new_A_UF__SWIG_1 unsafe.Pointer - -func _swig_wrap_new_A_UF__SWIG_1() (base SwigcptrA_UF) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_A_UF__SWIG_1, _swig_p) - return -} - -func NewA_UF__SWIG_1() (_swig_ret A_UF) { - return _swig_wrap_new_A_UF__SWIG_1() -} - -func NewA_UF(a ...interface{}) A_UF { - argc := len(a) - if argc == 0 { - return NewA_UF__SWIG_1() - } - if argc == 1 { - return NewA_UF__SWIG_0(a[0].(int)) - } - panic("No match for overloaded function call") -} - -var _wrap_A_UF_set unsafe.Pointer - -func _swig_wrap_A_UF_set(base SwigcptrA_UF, _ uint) (_ SwigcptrFacet_Sl_UnaryField_Sg_) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_A_UF_set, _swig_p) - return -} - -func (arg1 SwigcptrA_UF) Set(arg2 uint) (_swig_ret Facet_Sl_UnaryField_Sg_) { - return _swig_wrap_A_UF_set(arg1, arg2) -} - -var _wrap_delete_A_UF unsafe.Pointer - -func _swig_wrap_delete_A_UF(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_A_UF, _swig_p) - return -} - -func DeleteA_UF(arg1 A_UF) { - _swig_wrap_delete_A_UF(arg1.Swigcptr()) -} - -func (p SwigcptrA_UF) SwigIsBase_UF() { -} - -func (p SwigcptrA_UF) SwigGetBase_UF() Base_UF { - return SwigcptrBase_UF(p.Swigcptr()) -} - -type A_UF interface { - Swigcptr() uintptr - SwigIsA_UF() - Set(arg2 uint) (_swig_ret Facet_Sl_UnaryField_Sg_) - SwigIsBase_UF() - SwigGetBase_UF() Base_UF -} - - -type SwigcptrFacet_Sl_UnaryField_Sg_ uintptr -type Facet_Sl_UnaryField_Sg_ interface { - Swigcptr() uintptr; -} -func (p SwigcptrFacet_Sl_UnaryField_Sg_) Swigcptr() uintptr { - return uintptr(p) -} - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/abstract_typedef2_runme b/Examples/test-suite/go/abstract_typedef2_runme deleted file mode 100755 index 94e754462..000000000 Binary files a/Examples/test-suite/go/abstract_typedef2_runme and /dev/null differ diff --git a/Examples/test-suite/go/abstract_typedef_runme b/Examples/test-suite/go/abstract_typedef_runme deleted file mode 100755 index ebdd3be45..000000000 Binary files a/Examples/test-suite/go/abstract_typedef_runme and /dev/null differ diff --git a/Examples/test-suite/go/abstract_virtual.go b/Examples/test-suite/go/abstract_virtual.go deleted file mode 100644 index b958ab1ea..000000000 --- a/Examples/test-suite/go/abstract_virtual.go +++ /dev/null @@ -1,348 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../abstract_virtual.i - -package abstract_virtual - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrA uintptr - -func (p SwigcptrA) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrA) SwigIsA() { -} - -var _wrap_delete_A unsafe.Pointer - -func _swig_wrap_delete_A(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_A, _swig_p) - return -} - -func DeleteA(arg1 A) { - _swig_wrap_delete_A(arg1.Swigcptr()) -} - -var _wrap_A_foo unsafe.Pointer - -func _swig_wrap_A_foo(base SwigcptrA) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_A_foo, _swig_p) - return -} - -func (arg1 SwigcptrA) Foo() (_swig_ret int) { - return _swig_wrap_A_foo(arg1) -} - -type A interface { - Swigcptr() uintptr - SwigIsA() - Foo() (_swig_ret int) -} - -type SwigcptrB uintptr - -func (p SwigcptrB) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrB) SwigIsB() { -} - -var _wrap_B_foo unsafe.Pointer - -func _swig_wrap_B_foo(base SwigcptrB) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_B_foo, _swig_p) - return -} - -func (arg1 SwigcptrB) Foo() (_swig_ret int) { - return _swig_wrap_B_foo(arg1) -} - -var _wrap_new_B unsafe.Pointer - -func _swig_wrap_new_B() (base SwigcptrB) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_B, _swig_p) - return -} - -func NewB() (_swig_ret B) { - return _swig_wrap_new_B() -} - -var _wrap_delete_B unsafe.Pointer - -func _swig_wrap_delete_B(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_B, _swig_p) - return -} - -func DeleteB(arg1 B) { - _swig_wrap_delete_B(arg1.Swigcptr()) -} - -func (p SwigcptrB) SwigIsA() { -} - -func (p SwigcptrB) SwigGetA() A { - return SwigcptrA(p.Swigcptr()) -} - -type B interface { - Swigcptr() uintptr - SwigIsB() - Foo() (_swig_ret int) - SwigIsA() - SwigGetA() A -} - -type SwigcptrC uintptr - -func (p SwigcptrC) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrC) SwigIsC() { -} - -var _wrap_delete_C unsafe.Pointer - -func _swig_wrap_delete_C(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_C, _swig_p) - return -} - -func DeleteC(arg1 C) { - _swig_wrap_delete_C(arg1.Swigcptr()) -} - -var _wrap_C_foo unsafe.Pointer - -func _swig_wrap_C_foo(base SwigcptrC) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_C_foo, _swig_p) - return -} - -func (_swig_base SwigcptrC) Foo() (_swig_ret int) { - return _swig_wrap_C_foo(_swig_base) -} - -func (p SwigcptrC) SwigIsA() { -} - -func (p SwigcptrC) SwigGetA() A { - return SwigcptrA(p.Swigcptr()) -} - -type C interface { - Swigcptr() uintptr - SwigIsC() - Foo() (_swig_ret int) - SwigIsA() - SwigGetA() A -} - -type SwigcptrD uintptr - -func (p SwigcptrD) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrD) SwigIsD() { -} - -var _wrap_new_D unsafe.Pointer - -func _swig_wrap_new_D() (base SwigcptrD) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_D, _swig_p) - return -} - -func NewD() (_swig_ret D) { - return _swig_wrap_new_D() -} - -var _wrap_delete_D unsafe.Pointer - -func _swig_wrap_delete_D(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_D, _swig_p) - return -} - -func DeleteD(arg1 D) { - _swig_wrap_delete_D(arg1.Swigcptr()) -} - -var _wrap_D_foo unsafe.Pointer - -func _swig_wrap_D_foo(base SwigcptrD) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_D_foo, _swig_p) - return -} - -func (_swig_base SwigcptrD) Foo() (_swig_ret int) { - return _swig_wrap_D_foo(_swig_base) -} - -func (p SwigcptrD) SwigIsB() { -} - -func (p SwigcptrD) SwigGetB() B { - return SwigcptrB(p.Swigcptr()) -} - -func (p SwigcptrD) SwigIsA() { -} - -func (p SwigcptrD) SwigGetA() A { - return SwigcptrA(p.Swigcptr()) -} - -var _wrap_D_SwigGetC unsafe.Pointer - -func _swig_wrap_D_SwigGetC(base SwigcptrD) (_ SwigcptrC) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_D_SwigGetC, _swig_p) - return -} - -func (arg1 SwigcptrD) SwigGetC() (_swig_ret C) { - return _swig_wrap_D_SwigGetC(arg1) -} - -type D interface { - Swigcptr() uintptr - SwigIsD() - Foo() (_swig_ret int) - SwigIsB() - SwigGetB() B - SwigIsA() - SwigGetA() A - SwigGetC() (_swig_ret C) -} - -type SwigcptrE uintptr - -func (p SwigcptrE) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrE) SwigIsE() { -} - -var _wrap_new_E unsafe.Pointer - -func _swig_wrap_new_E() (base SwigcptrE) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_E, _swig_p) - return -} - -func NewE() (_swig_ret E) { - return _swig_wrap_new_E() -} - -var _wrap_delete_E unsafe.Pointer - -func _swig_wrap_delete_E(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_E, _swig_p) - return -} - -func DeleteE(arg1 E) { - _swig_wrap_delete_E(arg1.Swigcptr()) -} - -var _wrap_E_foo unsafe.Pointer - -func _swig_wrap_E_foo(base SwigcptrE) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_E_foo, _swig_p) - return -} - -func (_swig_base SwigcptrE) Foo() (_swig_ret int) { - return _swig_wrap_E_foo(_swig_base) -} - -func (p SwigcptrE) SwigIsC() { -} - -func (p SwigcptrE) SwigGetC() C { - return SwigcptrC(p.Swigcptr()) -} - -func (p SwigcptrE) SwigIsA() { -} - -func (p SwigcptrE) SwigGetA() A { - return SwigcptrA(p.Swigcptr()) -} - -var _wrap_E_SwigGetB unsafe.Pointer - -func _swig_wrap_E_SwigGetB(base SwigcptrE) (_ SwigcptrB) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_E_SwigGetB, _swig_p) - return -} - -func (arg1 SwigcptrE) SwigGetB() (_swig_ret B) { - return _swig_wrap_E_SwigGetB(arg1) -} - -type E interface { - Swigcptr() uintptr - SwigIsE() - Foo() (_swig_ret int) - SwigIsC() - SwigGetC() C - SwigIsA() - SwigGetA() A - SwigGetB() (_swig_ret B) -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/abstract_virtual_runme b/Examples/test-suite/go/abstract_virtual_runme deleted file mode 100755 index 1fbda7f02..000000000 Binary files a/Examples/test-suite/go/abstract_virtual_runme and /dev/null differ diff --git a/Examples/test-suite/go/access_change.go b/Examples/test-suite/go/access_change.go deleted file mode 100644 index e0429b74a..000000000 --- a/Examples/test-suite/go/access_change.go +++ /dev/null @@ -1,438 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../access_change.i - -package access_change - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrBaseInt uintptr - -func (p SwigcptrBaseInt) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrBaseInt) SwigIsBaseInt() { -} - -var _wrap_delete_BaseInt unsafe.Pointer - -func _swig_wrap_delete_BaseInt(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_BaseInt, _swig_p) - return -} - -func DeleteBaseInt(arg1 BaseInt) { - _swig_wrap_delete_BaseInt(arg1.Swigcptr()) -} - -var _wrap_BaseInt_PublicProtectedPublic1 unsafe.Pointer - -func _swig_wrap_BaseInt_PublicProtectedPublic1(base SwigcptrBaseInt) (_ *int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_BaseInt_PublicProtectedPublic1, _swig_p) - return -} - -func (arg1 SwigcptrBaseInt) PublicProtectedPublic1() (_swig_ret *int) { - return _swig_wrap_BaseInt_PublicProtectedPublic1(arg1) -} - -var _wrap_BaseInt_PublicProtectedPublic2 unsafe.Pointer - -func _swig_wrap_BaseInt_PublicProtectedPublic2(base SwigcptrBaseInt) (_ *int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_BaseInt_PublicProtectedPublic2, _swig_p) - return -} - -func (arg1 SwigcptrBaseInt) PublicProtectedPublic2() (_swig_ret *int) { - return _swig_wrap_BaseInt_PublicProtectedPublic2(arg1) -} - -var _wrap_BaseInt_PublicProtectedPublic3 unsafe.Pointer - -func _swig_wrap_BaseInt_PublicProtectedPublic3(base SwigcptrBaseInt) (_ *int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_BaseInt_PublicProtectedPublic3, _swig_p) - return -} - -func (arg1 SwigcptrBaseInt) PublicProtectedPublic3() (_swig_ret *int) { - return _swig_wrap_BaseInt_PublicProtectedPublic3(arg1) -} - -var _wrap_BaseInt_PublicProtectedPublic4 unsafe.Pointer - -func _swig_wrap_BaseInt_PublicProtectedPublic4(base SwigcptrBaseInt) (_ *int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_BaseInt_PublicProtectedPublic4, _swig_p) - return -} - -func (arg1 SwigcptrBaseInt) PublicProtectedPublic4() (_swig_ret *int) { - return _swig_wrap_BaseInt_PublicProtectedPublic4(arg1) -} - -var _wrap_new_BaseInt unsafe.Pointer - -func _swig_wrap_new_BaseInt() (base SwigcptrBaseInt) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_BaseInt, _swig_p) - return -} - -func NewBaseInt() (_swig_ret BaseInt) { - return _swig_wrap_new_BaseInt() -} - -type BaseInt interface { - Swigcptr() uintptr - SwigIsBaseInt() - PublicProtectedPublic1() (_swig_ret *int) - PublicProtectedPublic2() (_swig_ret *int) - PublicProtectedPublic3() (_swig_ret *int) - PublicProtectedPublic4() (_swig_ret *int) -} - -type SwigcptrDerivedInt uintptr - -func (p SwigcptrDerivedInt) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrDerivedInt) SwigIsDerivedInt() { -} - -var _wrap_DerivedInt_WasProtected1 unsafe.Pointer - -func _swig_wrap_DerivedInt_WasProtected1(base SwigcptrDerivedInt) (_ *int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_DerivedInt_WasProtected1, _swig_p) - return -} - -func (arg1 SwigcptrDerivedInt) WasProtected1() (_swig_ret *int) { - return _swig_wrap_DerivedInt_WasProtected1(arg1) -} - -var _wrap_DerivedInt_WasProtected2 unsafe.Pointer - -func _swig_wrap_DerivedInt_WasProtected2(base SwigcptrDerivedInt) (_ *int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_DerivedInt_WasProtected2, _swig_p) - return -} - -func (arg1 SwigcptrDerivedInt) WasProtected2() (_swig_ret *int) { - return _swig_wrap_DerivedInt_WasProtected2(arg1) -} - -var _wrap_DerivedInt_WasProtected3 unsafe.Pointer - -func _swig_wrap_DerivedInt_WasProtected3(base SwigcptrDerivedInt) (_ *int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_DerivedInt_WasProtected3, _swig_p) - return -} - -func (arg1 SwigcptrDerivedInt) WasProtected3() (_swig_ret *int) { - return _swig_wrap_DerivedInt_WasProtected3(arg1) -} - -var _wrap_DerivedInt_WasProtected4 unsafe.Pointer - -func _swig_wrap_DerivedInt_WasProtected4(base SwigcptrDerivedInt) (_ *int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_DerivedInt_WasProtected4, _swig_p) - return -} - -func (arg1 SwigcptrDerivedInt) WasProtected4() (_swig_ret *int) { - return _swig_wrap_DerivedInt_WasProtected4(arg1) -} - -var _wrap_new_DerivedInt unsafe.Pointer - -func _swig_wrap_new_DerivedInt() (base SwigcptrDerivedInt) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_DerivedInt, _swig_p) - return -} - -func NewDerivedInt() (_swig_ret DerivedInt) { - return _swig_wrap_new_DerivedInt() -} - -var _wrap_delete_DerivedInt unsafe.Pointer - -func _swig_wrap_delete_DerivedInt(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_DerivedInt, _swig_p) - return -} - -func DeleteDerivedInt(arg1 DerivedInt) { - _swig_wrap_delete_DerivedInt(arg1.Swigcptr()) -} - -var _wrap_DerivedInt_PublicProtectedPublic1 unsafe.Pointer - -func _swig_wrap_DerivedInt_PublicProtectedPublic1(base SwigcptrDerivedInt) (_ *int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_DerivedInt_PublicProtectedPublic1, _swig_p) - return -} - -func (_swig_base SwigcptrDerivedInt) PublicProtectedPublic1() (_swig_ret *int) { - return _swig_wrap_DerivedInt_PublicProtectedPublic1(_swig_base) -} - -var _wrap_DerivedInt_PublicProtectedPublic2 unsafe.Pointer - -func _swig_wrap_DerivedInt_PublicProtectedPublic2(base SwigcptrDerivedInt) (_ *int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_DerivedInt_PublicProtectedPublic2, _swig_p) - return -} - -func (_swig_base SwigcptrDerivedInt) PublicProtectedPublic2() (_swig_ret *int) { - return _swig_wrap_DerivedInt_PublicProtectedPublic2(_swig_base) -} - -var _wrap_DerivedInt_PublicProtectedPublic3 unsafe.Pointer - -func _swig_wrap_DerivedInt_PublicProtectedPublic3(base SwigcptrDerivedInt) (_ *int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_DerivedInt_PublicProtectedPublic3, _swig_p) - return -} - -func (_swig_base SwigcptrDerivedInt) PublicProtectedPublic3() (_swig_ret *int) { - return _swig_wrap_DerivedInt_PublicProtectedPublic3(_swig_base) -} - -var _wrap_DerivedInt_PublicProtectedPublic4 unsafe.Pointer - -func _swig_wrap_DerivedInt_PublicProtectedPublic4(base SwigcptrDerivedInt) (_ *int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_DerivedInt_PublicProtectedPublic4, _swig_p) - return -} - -func (_swig_base SwigcptrDerivedInt) PublicProtectedPublic4() (_swig_ret *int) { - return _swig_wrap_DerivedInt_PublicProtectedPublic4(_swig_base) -} - -func (p SwigcptrDerivedInt) SwigIsBaseInt() { -} - -func (p SwigcptrDerivedInt) SwigGetBaseInt() BaseInt { - return SwigcptrBaseInt(p.Swigcptr()) -} - -type DerivedInt interface { - Swigcptr() uintptr - SwigIsDerivedInt() - WasProtected1() (_swig_ret *int) - WasProtected2() (_swig_ret *int) - WasProtected3() (_swig_ret *int) - WasProtected4() (_swig_ret *int) - PublicProtectedPublic1() (_swig_ret *int) - PublicProtectedPublic2() (_swig_ret *int) - PublicProtectedPublic3() (_swig_ret *int) - PublicProtectedPublic4() (_swig_ret *int) - SwigIsBaseInt() - SwigGetBaseInt() BaseInt -} - -type SwigcptrBottomInt uintptr - -func (p SwigcptrBottomInt) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrBottomInt) SwigIsBottomInt() { -} - -var _wrap_BottomInt_WasProtected1 unsafe.Pointer - -func _swig_wrap_BottomInt_WasProtected1(base SwigcptrBottomInt) (_ *int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_BottomInt_WasProtected1, _swig_p) - return -} - -func (arg1 SwigcptrBottomInt) WasProtected1() (_swig_ret *int) { - return _swig_wrap_BottomInt_WasProtected1(arg1) -} - -var _wrap_BottomInt_WasProtected2 unsafe.Pointer - -func _swig_wrap_BottomInt_WasProtected2(base SwigcptrBottomInt) (_ *int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_BottomInt_WasProtected2, _swig_p) - return -} - -func (arg1 SwigcptrBottomInt) WasProtected2() (_swig_ret *int) { - return _swig_wrap_BottomInt_WasProtected2(arg1) -} - -var _wrap_BottomInt_WasProtected3 unsafe.Pointer - -func _swig_wrap_BottomInt_WasProtected3(base SwigcptrBottomInt) (_ *int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_BottomInt_WasProtected3, _swig_p) - return -} - -func (arg1 SwigcptrBottomInt) WasProtected3() (_swig_ret *int) { - return _swig_wrap_BottomInt_WasProtected3(arg1) -} - -var _wrap_BottomInt_WasProtected4 unsafe.Pointer - -func _swig_wrap_BottomInt_WasProtected4(base SwigcptrBottomInt) (_ *int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_BottomInt_WasProtected4, _swig_p) - return -} - -func (arg1 SwigcptrBottomInt) WasProtected4() (_swig_ret *int) { - return _swig_wrap_BottomInt_WasProtected4(arg1) -} - -var _wrap_BottomInt_PublicProtectedPublic1 unsafe.Pointer - -func _swig_wrap_BottomInt_PublicProtectedPublic1(base SwigcptrBottomInt) (_ *int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_BottomInt_PublicProtectedPublic1, _swig_p) - return -} - -func (arg1 SwigcptrBottomInt) PublicProtectedPublic1() (_swig_ret *int) { - return _swig_wrap_BottomInt_PublicProtectedPublic1(arg1) -} - -var _wrap_BottomInt_PublicProtectedPublic2 unsafe.Pointer - -func _swig_wrap_BottomInt_PublicProtectedPublic2(base SwigcptrBottomInt) (_ *int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_BottomInt_PublicProtectedPublic2, _swig_p) - return -} - -func (arg1 SwigcptrBottomInt) PublicProtectedPublic2() (_swig_ret *int) { - return _swig_wrap_BottomInt_PublicProtectedPublic2(arg1) -} - -var _wrap_BottomInt_PublicProtectedPublic3 unsafe.Pointer - -func _swig_wrap_BottomInt_PublicProtectedPublic3(base SwigcptrBottomInt) (_ *int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_BottomInt_PublicProtectedPublic3, _swig_p) - return -} - -func (arg1 SwigcptrBottomInt) PublicProtectedPublic3() (_swig_ret *int) { - return _swig_wrap_BottomInt_PublicProtectedPublic3(arg1) -} - -var _wrap_BottomInt_PublicProtectedPublic4 unsafe.Pointer - -func _swig_wrap_BottomInt_PublicProtectedPublic4(base SwigcptrBottomInt) (_ *int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_BottomInt_PublicProtectedPublic4, _swig_p) - return -} - -func (arg1 SwigcptrBottomInt) PublicProtectedPublic4() (_swig_ret *int) { - return _swig_wrap_BottomInt_PublicProtectedPublic4(arg1) -} - -var _wrap_new_BottomInt unsafe.Pointer - -func _swig_wrap_new_BottomInt() (base SwigcptrBottomInt) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_BottomInt, _swig_p) - return -} - -func NewBottomInt() (_swig_ret BottomInt) { - return _swig_wrap_new_BottomInt() -} - -var _wrap_delete_BottomInt unsafe.Pointer - -func _swig_wrap_delete_BottomInt(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_BottomInt, _swig_p) - return -} - -func DeleteBottomInt(arg1 BottomInt) { - _swig_wrap_delete_BottomInt(arg1.Swigcptr()) -} - -func (p SwigcptrBottomInt) SwigIsDerivedInt() { -} - -func (p SwigcptrBottomInt) SwigGetDerivedInt() DerivedInt { - return SwigcptrDerivedInt(p.Swigcptr()) -} - -func (p SwigcptrBottomInt) SwigIsBaseInt() { -} - -func (p SwigcptrBottomInt) SwigGetBaseInt() BaseInt { - return SwigcptrBaseInt(p.Swigcptr()) -} - -type BottomInt interface { - Swigcptr() uintptr - SwigIsBottomInt() - WasProtected1() (_swig_ret *int) - WasProtected2() (_swig_ret *int) - WasProtected3() (_swig_ret *int) - WasProtected4() (_swig_ret *int) - PublicProtectedPublic1() (_swig_ret *int) - PublicProtectedPublic2() (_swig_ret *int) - PublicProtectedPublic3() (_swig_ret *int) - PublicProtectedPublic4() (_swig_ret *int) - SwigIsDerivedInt() - SwigGetDerivedInt() DerivedInt - SwigIsBaseInt() - SwigGetBaseInt() BaseInt -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/add_link.go b/Examples/test-suite/go/add_link.go deleted file mode 100644 index 987a30cbd..000000000 --- a/Examples/test-suite/go/add_link.go +++ /dev/null @@ -1,88 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../add_link.i - -package add_link - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrFoo uintptr - -func (p SwigcptrFoo) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrFoo) SwigIsFoo() { -} - -var _wrap_new_Foo unsafe.Pointer - -func _swig_wrap_new_Foo() (base SwigcptrFoo) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Foo, _swig_p) - return -} - -func NewFoo() (_swig_ret Foo) { - return _swig_wrap_new_Foo() -} - -var _wrap_Foo_blah unsafe.Pointer - -func _swig_wrap_Foo_blah(base SwigcptrFoo) (_ SwigcptrFoo) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_blah, _swig_p) - return -} - -func (arg1 SwigcptrFoo) Blah() (_swig_ret Foo) { - return _swig_wrap_Foo_blah(arg1) -} - -var _wrap_delete_Foo unsafe.Pointer - -func _swig_wrap_delete_Foo(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Foo, _swig_p) - return -} - -func DeleteFoo(arg1 Foo) { - _swig_wrap_delete_Foo(arg1.Swigcptr()) -} - -type Foo interface { - Swigcptr() uintptr - SwigIsFoo() - Blah() (_swig_ret Foo) -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/aggregate.go b/Examples/test-suite/go/aggregate.go deleted file mode 100644 index a4bd498f8..000000000 --- a/Examples/test-suite/go/aggregate.go +++ /dev/null @@ -1,40 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../aggregate.i - -package aggregate - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -const UP int = 1 -const DOWN int = 2 -const LEFT int = 3 -const RIGHT int = 4 -var _wrap_move unsafe.Pointer - -func Move(arg1 int) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_move, _swig_p) - return -} - diff --git a/Examples/test-suite/go/allowexcept.go b/Examples/test-suite/go/allowexcept.go deleted file mode 100644 index 13cadbaa9..000000000 --- a/Examples/test-suite/go/allowexcept.go +++ /dev/null @@ -1,241 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../allowexcept.i - -package allowexcept - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrUVW uintptr - -func (p SwigcptrUVW) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrUVW) SwigIsUVW() { -} - -type UVW interface { - Swigcptr() uintptr - SwigIsUVW() -} - -var _wrap_uvw_global_variable_set unsafe.Pointer - -func _swig_wrap_uvw_global_variable_set(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_uvw_global_variable_set, _swig_p) - return -} - -func SetUvw_global_variable(arg1 UVW) { - _swig_wrap_uvw_global_variable_set(arg1.Swigcptr()) -} - -var _wrap_uvw_global_variable_get unsafe.Pointer - -func _swig_wrap_uvw_global_variable_get() (base SwigcptrUVW) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_uvw_global_variable_get, _swig_p) - return -} - -func GetUvw_global_variable() (_swig_ret UVW) { - return _swig_wrap_uvw_global_variable_get() -} - -type SwigcptrBar uintptr - -func (p SwigcptrBar) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrBar) SwigIsBar() { -} - -var _wrap_Bar_member_variable_set unsafe.Pointer - -func _swig_wrap_Bar_member_variable_set(base SwigcptrBar, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Bar_member_variable_set, _swig_p) - return -} - -func (arg1 SwigcptrBar) SetMember_variable(arg2 UVW) { - _swig_wrap_Bar_member_variable_set(arg1, arg2.Swigcptr()) -} - -var _wrap_Bar_member_variable_get unsafe.Pointer - -func _swig_wrap_Bar_member_variable_get(base SwigcptrBar) (_ SwigcptrUVW) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Bar_member_variable_get, _swig_p) - return -} - -func (arg1 SwigcptrBar) GetMember_variable() (_swig_ret UVW) { - return _swig_wrap_Bar_member_variable_get(arg1) -} - -var _wrap_Bar_static_member_variable_set unsafe.Pointer - -func _swig_wrap_Bar_static_member_variable_set(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Bar_static_member_variable_set, _swig_p) - return -} - -func SetBarStatic_member_variable(arg1 UVW) { - _swig_wrap_Bar_static_member_variable_set(arg1.Swigcptr()) -} - -var _wrap_Bar_static_member_variable_get unsafe.Pointer - -func _swig_wrap_Bar_static_member_variable_get() (base SwigcptrUVW) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Bar_static_member_variable_get, _swig_p) - return -} - -func GetBarStatic_member_variable() (_swig_ret UVW) { - return _swig_wrap_Bar_static_member_variable_get() -} - -type Bar interface { - Swigcptr() uintptr - SwigIsBar() - SetMember_variable(arg2 UVW) - GetMember_variable() (_swig_ret UVW) -} - -type SwigcptrXYZ uintptr - -func (p SwigcptrXYZ) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrXYZ) SwigIsXYZ() { -} - -type XYZ interface { - Swigcptr() uintptr - SwigIsXYZ() -} - -var _wrap_global_variable_set unsafe.Pointer - -func _swig_wrap_global_variable_set(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_global_variable_set, _swig_p) - return -} - -func SetGlobal_variable(arg1 XYZ) { - _swig_wrap_global_variable_set(arg1.Swigcptr()) -} - -var _wrap_global_variable_get unsafe.Pointer - -func _swig_wrap_global_variable_get() (base SwigcptrXYZ) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_global_variable_get, _swig_p) - return -} - -func GetGlobal_variable() (_swig_ret XYZ) { - return _swig_wrap_global_variable_get() -} - -type SwigcptrFoo uintptr - -func (p SwigcptrFoo) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrFoo) SwigIsFoo() { -} - -var _wrap_Foo_member_variable_set unsafe.Pointer - -func _swig_wrap_Foo_member_variable_set(base SwigcptrFoo, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_member_variable_set, _swig_p) - return -} - -func (arg1 SwigcptrFoo) SetMember_variable(arg2 XYZ) { - _swig_wrap_Foo_member_variable_set(arg1, arg2.Swigcptr()) -} - -var _wrap_Foo_member_variable_get unsafe.Pointer - -func _swig_wrap_Foo_member_variable_get(base SwigcptrFoo) (_ SwigcptrXYZ) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_member_variable_get, _swig_p) - return -} - -func (arg1 SwigcptrFoo) GetMember_variable() (_swig_ret XYZ) { - return _swig_wrap_Foo_member_variable_get(arg1) -} - -var _wrap_Foo_static_member_variable_set unsafe.Pointer - -func _swig_wrap_Foo_static_member_variable_set(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_static_member_variable_set, _swig_p) - return -} - -func SetFooStatic_member_variable(arg1 XYZ) { - _swig_wrap_Foo_static_member_variable_set(arg1.Swigcptr()) -} - -var _wrap_Foo_static_member_variable_get unsafe.Pointer - -func _swig_wrap_Foo_static_member_variable_get() (base SwigcptrXYZ) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_static_member_variable_get, _swig_p) - return -} - -func GetFooStatic_member_variable() (_swig_ret XYZ) { - return _swig_wrap_Foo_static_member_variable_get() -} - -type Foo interface { - Swigcptr() uintptr - SwigIsFoo() - SetMember_variable(arg2 XYZ) - GetMember_variable() (_swig_ret XYZ) -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/allprotected.go b/Examples/test-suite/go/allprotected.go deleted file mode 100644 index 223d32f4f..000000000 --- a/Examples/test-suite/go/allprotected.go +++ /dev/null @@ -1,681 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../allprotected.i - -package allprotected - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrKlass uintptr - -func (p SwigcptrKlass) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrKlass) SwigIsKlass() { -} - -var _wrap_new_Klass unsafe.Pointer - -func _swig_wrap_new_Klass(base string) (_ SwigcptrKlass) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Klass, _swig_p) - return -} - -func NewKlass(arg1 string) (_swig_ret Klass) { - return _swig_wrap_new_Klass(arg1) -} - -var _wrap_Klass_getName unsafe.Pointer - -func _swig_wrap_Klass_getName(base SwigcptrKlass) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Klass_getName, _swig_p) - return -} - -func (arg1 SwigcptrKlass) GetName() (_swig_ret string) { - return _swig_wrap_Klass_getName(arg1) -} - -var _wrap_delete_Klass unsafe.Pointer - -func _swig_wrap_delete_Klass(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Klass, _swig_p) - return -} - -func DeleteKlass(arg1 Klass) { - _swig_wrap_delete_Klass(arg1.Swigcptr()) -} - -type Klass interface { - Swigcptr() uintptr - SwigIsKlass() - GetName() (_swig_ret string) -} - -type _swig_DirectorPublicBase struct { - SwigcptrPublicBase - v interface{} -} - -func (p *_swig_DirectorPublicBase) Swigcptr() uintptr { - return p.SwigcptrPublicBase.Swigcptr() -} - -func (p *_swig_DirectorPublicBase) SwigIsPublicBase() { -} - -func (p *_swig_DirectorPublicBase) DirectorInterface() interface{} { - return p.v -} - -var _wrap__swig_NewDirectorPublicBasePublicBase unsafe.Pointer - -func _swig_NewDirectorPublicBasePublicBase(_swig_director *_swig_DirectorPublicBase, _ string) (_swig_ret SwigcptrPublicBase) { - _swig_p := uintptr(unsafe.Pointer(&_swig_director)) - _cgo_runtime_cgocall(_wrap__swig_NewDirectorPublicBasePublicBase, _swig_p) - return -} - -func NewDirectorPublicBase(v interface{}, arg1 string) PublicBase { - p := &_swig_DirectorPublicBase{0, v} - p.SwigcptrPublicBase = _swig_NewDirectorPublicBasePublicBase(p, arg1) - return p -} - -var _wrap_DeleteDirectorPublicBase unsafe.Pointer - -func _swig_wrap_DeleteDirectorPublicBase(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_DeleteDirectorPublicBase, _swig_p) - return -} - -func DeleteDirectorPublicBase(arg1 PublicBase) { - _swig_wrap_DeleteDirectorPublicBase(arg1.Swigcptr()) -} - -func Swiggo_DeleteDirector_PublicBase(p *_swig_DirectorPublicBase) { - p.SwigcptrPublicBase = 0 -} - -type _swig_DirectorInterfacePublicBaseVirtualMethod interface { - VirtualMethod() string -} - -var _wrap__swig_DirectorPublicBase_upcall_VirtualMethod unsafe.Pointer - -func _swig_wrap__swig_DirectorPublicBase_upcall_VirtualMethod(_swig_ptr SwigcptrPublicBase) (_swig_ret string) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) - _cgo_runtime_cgocall(_wrap__swig_DirectorPublicBase_upcall_VirtualMethod, _swig_p) - return -} - -func (swig_p *_swig_DirectorPublicBase) VirtualMethod() string { - if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfacePublicBaseVirtualMethod); swig_ok { - return swig_g.VirtualMethod() - } - var swig_r string - swig_r = _swig_wrap__swig_DirectorPublicBase_upcall_VirtualMethod(swig_p.SwigcptrPublicBase) - return swig_r -} - -func DirectorPublicBaseVirtualMethod(p PublicBase) string { - var swig_r string - swig_r = _swig_wrap__swig_DirectorPublicBase_upcall_VirtualMethod(p.(*_swig_DirectorPublicBase).SwigcptrPublicBase) - return swig_r -} - -func Swig_DirectorPublicBase_callback_virtualMethod(p *_swig_DirectorPublicBase) (swig_result string) { - var swig_r string - swig_r = p.VirtualMethod() - return swig_r -} - -type SwigcptrPublicBase uintptr - -func (p SwigcptrPublicBase) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrPublicBase) SwigIsPublicBase() { -} - -func (p SwigcptrPublicBase) DirectorInterface() interface{} { - return nil -} - -type PublicBaseAnEnum int -var _wrap_EnumVal1_PublicBase unsafe.Pointer - -func _swig_getPublicBase_EnumVal1_PublicBase() (_swig_ret PublicBaseAnEnum) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_EnumVal1_PublicBase, _swig_p) - return -} -var PublicBaseEnumVal1 PublicBaseAnEnum = _swig_getPublicBase_EnumVal1_PublicBase() -var _wrap_EnumVal2_PublicBase unsafe.Pointer - -func _swig_getPublicBase_EnumVal2_PublicBase() (_swig_ret PublicBaseAnEnum) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_EnumVal2_PublicBase, _swig_p) - return -} -var PublicBaseEnumVal2 PublicBaseAnEnum = _swig_getPublicBase_EnumVal2_PublicBase() -var _wrap_new_PublicBase unsafe.Pointer - -func _swig_wrap_new_PublicBase(base string) (_ SwigcptrPublicBase) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_PublicBase, _swig_p) - return -} - -func NewPublicBase(arg1 string) (_swig_ret PublicBase) { - return _swig_wrap_new_PublicBase(arg1) -} - -var _wrap_delete_PublicBase unsafe.Pointer - -func _swig_wrap_delete_PublicBase(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_PublicBase, _swig_p) - return -} - -func DeletePublicBase(arg1 PublicBase) { - _swig_wrap_delete_PublicBase(arg1.Swigcptr()) -} - -var _wrap_PublicBase_virtualMethod unsafe.Pointer - -func _swig_wrap_PublicBase_virtualMethod(base SwigcptrPublicBase) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_PublicBase_virtualMethod, _swig_p) - return -} - -func (arg1 SwigcptrPublicBase) VirtualMethod() (_swig_ret string) { - return _swig_wrap_PublicBase_virtualMethod(arg1) -} - -var _wrap_PublicBase_instanceMethod unsafe.Pointer - -func _swig_wrap_PublicBase_instanceMethod(base SwigcptrPublicBase, _ uintptr) (_ SwigcptrKlass) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_PublicBase_instanceMethod, _swig_p) - return -} - -func (arg1 SwigcptrPublicBase) InstanceMethod(arg2 Klass) (_swig_ret Klass) { - return _swig_wrap_PublicBase_instanceMethod(arg1, arg2.Swigcptr()) -} - -var _wrap_PublicBase_instanceOverloaded__SWIG_0 unsafe.Pointer - -func _swig_wrap_PublicBase_instanceOverloaded__SWIG_0(base SwigcptrPublicBase, _ uintptr) (_ SwigcptrKlass) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_PublicBase_instanceOverloaded__SWIG_0, _swig_p) - return -} - -func (arg1 SwigcptrPublicBase) InstanceOverloaded__SWIG_0(arg2 Klass) (_swig_ret Klass) { - return _swig_wrap_PublicBase_instanceOverloaded__SWIG_0(arg1, arg2.Swigcptr()) -} - -var _wrap_PublicBase_instanceOverloaded__SWIG_1 unsafe.Pointer - -func _swig_wrap_PublicBase_instanceOverloaded__SWIG_1(base SwigcptrPublicBase, _ uintptr, _ string) (_ SwigcptrKlass) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_PublicBase_instanceOverloaded__SWIG_1, _swig_p) - return -} - -func (arg1 SwigcptrPublicBase) InstanceOverloaded__SWIG_1(arg2 Klass, arg3 string) (_swig_ret Klass) { - return _swig_wrap_PublicBase_instanceOverloaded__SWIG_1(arg1, arg2.Swigcptr(), arg3) -} - -func (p SwigcptrPublicBase) InstanceOverloaded(a ...interface{}) Klass { - argc := len(a) - if argc == 1 { - return p.InstanceOverloaded__SWIG_0(a[0].(Klass)) - } - if argc == 2 { - return p.InstanceOverloaded__SWIG_1(a[0].(Klass), a[1].(string)) - } - panic("No match for overloaded function call") -} - -var _wrap_PublicBase_staticMethod unsafe.Pointer - -func _swig_wrap_PublicBase_staticMethod(base uintptr) (_ SwigcptrKlass) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_PublicBase_staticMethod, _swig_p) - return -} - -func PublicBaseStaticMethod(arg1 Klass) (_swig_ret Klass) { - return _swig_wrap_PublicBase_staticMethod(arg1.Swigcptr()) -} - -var _wrap_PublicBase_staticOverloaded__SWIG_0 unsafe.Pointer - -func _swig_wrap_PublicBase_staticOverloaded__SWIG_0(base uintptr) (_ SwigcptrKlass) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_PublicBase_staticOverloaded__SWIG_0, _swig_p) - return -} - -func PublicBaseStaticOverloaded__SWIG_0(arg1 Klass) (_swig_ret Klass) { - return _swig_wrap_PublicBase_staticOverloaded__SWIG_0(arg1.Swigcptr()) -} - -var _wrap_PublicBase_staticOverloaded__SWIG_1 unsafe.Pointer - -func _swig_wrap_PublicBase_staticOverloaded__SWIG_1(base uintptr, _ string) (_ SwigcptrKlass) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_PublicBase_staticOverloaded__SWIG_1, _swig_p) - return -} - -func PublicBaseStaticOverloaded__SWIG_1(arg1 Klass, arg2 string) (_swig_ret Klass) { - return _swig_wrap_PublicBase_staticOverloaded__SWIG_1(arg1.Swigcptr(), arg2) -} - -func PublicBaseStaticOverloaded(a ...interface{}) Klass { - argc := len(a) - if argc == 1 { - return PublicBaseStaticOverloaded__SWIG_0(a[0].(Klass)) - } - if argc == 2 { - return PublicBaseStaticOverloaded__SWIG_1(a[0].(Klass), a[1].(string)) - } - panic("No match for overloaded function call") -} - -var _wrap_PublicBase_instanceMemberVariable_set unsafe.Pointer - -func _swig_wrap_PublicBase_instanceMemberVariable_set(base SwigcptrPublicBase, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_PublicBase_instanceMemberVariable_set, _swig_p) - return -} - -func (arg1 SwigcptrPublicBase) SetInstanceMemberVariable(arg2 int) { - _swig_wrap_PublicBase_instanceMemberVariable_set(arg1, arg2) -} - -var _wrap_PublicBase_instanceMemberVariable_get unsafe.Pointer - -func _swig_wrap_PublicBase_instanceMemberVariable_get(base SwigcptrPublicBase) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_PublicBase_instanceMemberVariable_get, _swig_p) - return -} - -func (arg1 SwigcptrPublicBase) GetInstanceMemberVariable() (_swig_ret int) { - return _swig_wrap_PublicBase_instanceMemberVariable_get(arg1) -} - -var _wrap_PublicBase_staticMemberVariable_set unsafe.Pointer - -func _swig_wrap_PublicBase_staticMemberVariable_set(base int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_PublicBase_staticMemberVariable_set, _swig_p) - return -} - -func SetPublicBaseStaticMemberVariable(arg1 int) { - _swig_wrap_PublicBase_staticMemberVariable_set(arg1) -} - -var _wrap_PublicBase_staticMemberVariable_get unsafe.Pointer - -func GetPublicBaseStaticMemberVariable() (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_PublicBase_staticMemberVariable_get, _swig_p) - return -} -var _wrap_PublicBase_staticConstMemberVariable_PublicBase unsafe.Pointer - -func _swig_getPublicBase_PublicBase_staticConstMemberVariable_PublicBase() (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_PublicBase_staticConstMemberVariable_PublicBase, _swig_p) - return -} -var PublicBaseStaticConstMemberVariable int = _swig_getPublicBase_PublicBase_staticConstMemberVariable_PublicBase() -var _wrap_PublicBase_anEnum_set unsafe.Pointer - -func _swig_wrap_PublicBase_anEnum_set(base SwigcptrPublicBase, _ PublicBaseAnEnum) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_PublicBase_anEnum_set, _swig_p) - return -} - -func (arg1 SwigcptrPublicBase) SetAnEnum(arg2 PublicBaseAnEnum) { - _swig_wrap_PublicBase_anEnum_set(arg1, arg2) -} - -var _wrap_PublicBase_anEnum_get unsafe.Pointer - -func _swig_wrap_PublicBase_anEnum_get(base SwigcptrPublicBase) (_ PublicBaseAnEnum) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_PublicBase_anEnum_get, _swig_p) - return -} - -func (arg1 SwigcptrPublicBase) GetAnEnum() (_swig_ret PublicBaseAnEnum) { - return _swig_wrap_PublicBase_anEnum_get(arg1) -} - -var _wrap_PublicBase_stringMember_set unsafe.Pointer - -func _swig_wrap_PublicBase_stringMember_set(base SwigcptrPublicBase, _ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_PublicBase_stringMember_set, _swig_p) - return -} - -func (arg1 SwigcptrPublicBase) SetStringMember(arg2 string) { - _swig_wrap_PublicBase_stringMember_set(arg1, arg2) -} - -var _wrap_PublicBase_stringMember_get unsafe.Pointer - -func _swig_wrap_PublicBase_stringMember_get(base SwigcptrPublicBase) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_PublicBase_stringMember_get, _swig_p) - return -} - -func (arg1 SwigcptrPublicBase) GetStringMember() (_swig_ret string) { - return _swig_wrap_PublicBase_stringMember_get(arg1) -} - -type PublicBase interface { - Swigcptr() uintptr - SwigIsPublicBase() - DirectorInterface() interface{} - VirtualMethod() (_swig_ret string) - InstanceMethod(arg2 Klass) (_swig_ret Klass) - InstanceOverloaded(a ...interface{}) Klass - SetInstanceMemberVariable(arg2 int) - GetInstanceMemberVariable() (_swig_ret int) - SetAnEnum(arg2 PublicBaseAnEnum) - GetAnEnum() (_swig_ret PublicBaseAnEnum) - SetStringMember(arg2 string) - GetStringMember() (_swig_ret string) -} - -type _swig_DirectorProtectedBase struct { - SwigcptrProtectedBase - v interface{} -} - -func (p *_swig_DirectorProtectedBase) Swigcptr() uintptr { - return p.SwigcptrProtectedBase.Swigcptr() -} - -func (p *_swig_DirectorProtectedBase) SwigIsProtectedBase() { -} - -func (p *_swig_DirectorProtectedBase) DirectorInterface() interface{} { - return p.v -} - -var _wrap__swig_NewDirectorProtectedBaseProtectedBase unsafe.Pointer - -func _swig_NewDirectorProtectedBaseProtectedBase(_swig_director *_swig_DirectorProtectedBase, _ string) (_swig_ret SwigcptrProtectedBase) { - _swig_p := uintptr(unsafe.Pointer(&_swig_director)) - _cgo_runtime_cgocall(_wrap__swig_NewDirectorProtectedBaseProtectedBase, _swig_p) - return -} - -func NewDirectorProtectedBase(v interface{}, arg1 string) ProtectedBase { - p := &_swig_DirectorProtectedBase{0, v} - p.SwigcptrProtectedBase = _swig_NewDirectorProtectedBaseProtectedBase(p, arg1) - return p -} - -type _swig_DirectorInterfaceProtectedBaseVirtualMethod interface { - VirtualMethod() string -} - -var _wrap__swig_DirectorProtectedBase_upcall_VirtualMethod unsafe.Pointer - -func _swig_wrap__swig_DirectorProtectedBase_upcall_VirtualMethod(_swig_ptr SwigcptrProtectedBase) (_swig_ret string) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) - _cgo_runtime_cgocall(_wrap__swig_DirectorProtectedBase_upcall_VirtualMethod, _swig_p) - return -} - -func (swig_p *_swig_DirectorProtectedBase) VirtualMethod() string { - if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceProtectedBaseVirtualMethod); swig_ok { - return swig_g.VirtualMethod() - } - var swig_r string - swig_r = _swig_wrap__swig_DirectorProtectedBase_upcall_VirtualMethod(swig_p.SwigcptrProtectedBase) - return swig_r -} - -func DirectorProtectedBaseVirtualMethod(p ProtectedBase) string { - var swig_r string - swig_r = _swig_wrap__swig_DirectorProtectedBase_upcall_VirtualMethod(p.(*_swig_DirectorProtectedBase).SwigcptrProtectedBase) - return swig_r -} - -func Swig_DirectorProtectedBase_callback_virtualMethod(p *_swig_DirectorProtectedBase) (swig_result string) { - var swig_r string - swig_r = p.VirtualMethod() - return swig_r -} - -type SwigcptrProtectedBase uintptr - -func (p SwigcptrProtectedBase) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrProtectedBase) SwigIsProtectedBase() { -} - -func (p SwigcptrProtectedBase) DirectorInterface() interface{} { - return nil -} - -type ProtectedBaseAnEnum int -var _wrap_EnumVal1_ProtectedBase unsafe.Pointer - -func _swig_getProtectedBase_EnumVal1_ProtectedBase() (_swig_ret ProtectedBaseAnEnum) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_EnumVal1_ProtectedBase, _swig_p) - return -} -var ProtectedBaseEnumVal1 ProtectedBaseAnEnum = _swig_getProtectedBase_EnumVal1_ProtectedBase() -var _wrap_EnumVal2_ProtectedBase unsafe.Pointer - -func _swig_getProtectedBase_EnumVal2_ProtectedBase() (_swig_ret ProtectedBaseAnEnum) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_EnumVal2_ProtectedBase, _swig_p) - return -} -var ProtectedBaseEnumVal2 ProtectedBaseAnEnum = _swig_getProtectedBase_EnumVal2_ProtectedBase() -var _wrap_ProtectedBase_getName unsafe.Pointer - -func _swig_wrap_ProtectedBase_getName(base SwigcptrProtectedBase) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_ProtectedBase_getName, _swig_p) - return -} - -func (arg1 SwigcptrProtectedBase) GetName() (_swig_ret string) { - return _swig_wrap_ProtectedBase_getName(arg1) -} - -var _wrap_new_ProtectedBase unsafe.Pointer - -func _swig_wrap_new_ProtectedBase(base string) (_ SwigcptrProtectedBase) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_ProtectedBase, _swig_p) - return -} - -func NewProtectedBase(arg1 string) (_swig_ret ProtectedBase) { - return _swig_wrap_new_ProtectedBase(arg1) -} - -var _wrap_ProtectedBase_instanceMemberVariable_set unsafe.Pointer - -func _swig_wrap_ProtectedBase_instanceMemberVariable_set(base SwigcptrProtectedBase, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_ProtectedBase_instanceMemberVariable_set, _swig_p) - return -} - -func (arg1 SwigcptrProtectedBase) SetInstanceMemberVariable(arg2 int) { - _swig_wrap_ProtectedBase_instanceMemberVariable_set(arg1, arg2) -} - -var _wrap_ProtectedBase_instanceMemberVariable_get unsafe.Pointer - -func _swig_wrap_ProtectedBase_instanceMemberVariable_get(base SwigcptrProtectedBase) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_ProtectedBase_instanceMemberVariable_get, _swig_p) - return -} - -func (arg1 SwigcptrProtectedBase) GetInstanceMemberVariable() (_swig_ret int) { - return _swig_wrap_ProtectedBase_instanceMemberVariable_get(arg1) -} - -var _wrap_ProtectedBase_staticMemberVariable_set unsafe.Pointer - -func _swig_wrap_ProtectedBase_staticMemberVariable_set(base int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_ProtectedBase_staticMemberVariable_set, _swig_p) - return -} - -func SetProtectedBaseStaticMemberVariable(arg1 int) { - _swig_wrap_ProtectedBase_staticMemberVariable_set(arg1) -} - -var _wrap_ProtectedBase_staticMemberVariable_get unsafe.Pointer - -func GetProtectedBaseStaticMemberVariable() (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_ProtectedBase_staticMemberVariable_get, _swig_p) - return -} -var _wrap_ProtectedBase_staticConstMemberVariable_ProtectedBase unsafe.Pointer - -func _swig_getProtectedBase_ProtectedBase_staticConstMemberVariable_ProtectedBase() (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_ProtectedBase_staticConstMemberVariable_ProtectedBase, _swig_p) - return -} -var ProtectedBaseStaticConstMemberVariable int = _swig_getProtectedBase_ProtectedBase_staticConstMemberVariable_ProtectedBase() -var _wrap_ProtectedBase_anEnum_set unsafe.Pointer - -func _swig_wrap_ProtectedBase_anEnum_set(base SwigcptrProtectedBase, _ ProtectedBaseAnEnum) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_ProtectedBase_anEnum_set, _swig_p) - return -} - -func (arg1 SwigcptrProtectedBase) SetAnEnum(arg2 ProtectedBaseAnEnum) { - _swig_wrap_ProtectedBase_anEnum_set(arg1, arg2) -} - -var _wrap_ProtectedBase_anEnum_get unsafe.Pointer - -func _swig_wrap_ProtectedBase_anEnum_get(base SwigcptrProtectedBase) (_ ProtectedBaseAnEnum) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_ProtectedBase_anEnum_get, _swig_p) - return -} - -func (arg1 SwigcptrProtectedBase) GetAnEnum() (_swig_ret ProtectedBaseAnEnum) { - return _swig_wrap_ProtectedBase_anEnum_get(arg1) -} - -var _wrap_ProtectedBase_stringMember_set unsafe.Pointer - -func _swig_wrap_ProtectedBase_stringMember_set(base SwigcptrProtectedBase, _ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_ProtectedBase_stringMember_set, _swig_p) - return -} - -func (arg1 SwigcptrProtectedBase) SetStringMember(arg2 string) { - _swig_wrap_ProtectedBase_stringMember_set(arg1, arg2) -} - -var _wrap_ProtectedBase_stringMember_get unsafe.Pointer - -func _swig_wrap_ProtectedBase_stringMember_get(base SwigcptrProtectedBase) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_ProtectedBase_stringMember_get, _swig_p) - return -} - -func (arg1 SwigcptrProtectedBase) GetStringMember() (_swig_ret string) { - return _swig_wrap_ProtectedBase_stringMember_get(arg1) -} - -type ProtectedBaseProtectedEnum int -type ProtectedBase interface { - Swigcptr() uintptr - SwigIsProtectedBase() - DirectorInterface() interface{} - GetName() (_swig_ret string) -} - - -type SwigcptrSwigDirector_ProtectedBase uintptr -type SwigDirector_ProtectedBase interface { - Swigcptr() uintptr; -} -func (p SwigcptrSwigDirector_ProtectedBase) Swigcptr() uintptr { - return uintptr(p) -} - -type SwigcptrSwigDirector_PublicBase uintptr -type SwigDirector_PublicBase interface { - Swigcptr() uintptr; -} -func (p SwigcptrSwigDirector_PublicBase) Swigcptr() uintptr { - return uintptr(p) -} - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/allprotected_not.go b/Examples/test-suite/go/allprotected_not.go deleted file mode 100644 index f393222ba..000000000 --- a/Examples/test-suite/go/allprotected_not.go +++ /dev/null @@ -1,88 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../allprotected_not.i - -package allprotected_not - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrAllProtectedNot uintptr - -func (p SwigcptrAllProtectedNot) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrAllProtectedNot) SwigIsAllProtectedNot() { -} - -var _wrap_delete_AllProtectedNot unsafe.Pointer - -func _swig_wrap_delete_AllProtectedNot(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_AllProtectedNot, _swig_p) - return -} - -func DeleteAllProtectedNot(arg1 AllProtectedNot) { - _swig_wrap_delete_AllProtectedNot(arg1.Swigcptr()) -} - -var _wrap_AllProtectedNot_PublicMethod unsafe.Pointer - -func _swig_wrap_AllProtectedNot_PublicMethod(base SwigcptrAllProtectedNot) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_AllProtectedNot_PublicMethod, _swig_p) - return -} - -func (arg1 SwigcptrAllProtectedNot) PublicMethod() { - _swig_wrap_AllProtectedNot_PublicMethod(arg1) -} - -var _wrap_new_AllProtectedNot unsafe.Pointer - -func _swig_wrap_new_AllProtectedNot() (base SwigcptrAllProtectedNot) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_AllProtectedNot, _swig_p) - return -} - -func NewAllProtectedNot() (_swig_ret AllProtectedNot) { - return _swig_wrap_new_AllProtectedNot() -} - -type AllProtectedNot interface { - Swigcptr() uintptr - SwigIsAllProtectedNot() - PublicMethod() -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/allprotected_not_wrap.h b/Examples/test-suite/go/allprotected_not_wrap.h deleted file mode 100644 index 940424b89..000000000 --- a/Examples/test-suite/go/allprotected_not_wrap.h +++ /dev/null @@ -1,16 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../allprotected_not.i - -#ifndef SWIG_allprotected_not_WRAP_H_ -#define SWIG_allprotected_not_WRAP_H_ - -#endif diff --git a/Examples/test-suite/go/allprotected_wrap.h b/Examples/test-suite/go/allprotected_wrap.h deleted file mode 100644 index 6a7fd8caf..000000000 --- a/Examples/test-suite/go/allprotected_wrap.h +++ /dev/null @@ -1,51 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../allprotected.i - -#ifndef SWIG_allprotected_WRAP_H_ -#define SWIG_allprotected_WRAP_H_ - -class SwigDirector_PublicBase : public PublicBase -{ - public: - SwigDirector_PublicBase(void *swig_p, char const *s); - virtual ~SwigDirector_PublicBase(); - std::string _swig_upcall_virtualMethod() const { - return PublicBase::virtualMethod(); - } - virtual std::string virtualMethod() const; - private: - void *go_val; -}; - -class SwigDirector_ProtectedBase : public ProtectedBase -{ - public: - SwigDirector_ProtectedBase(void *swig_p, char const *s); - std::string _swig_upcall_virtualMethod() const { - return ProtectedBase::virtualMethod(); - } - virtual std::string virtualMethod() const; - using ProtectedBase::instanceMethod; - using ProtectedBase::instanceOverloaded; - using ProtectedBase::staticMethod; - using ProtectedBase::staticOverloaded; - using ProtectedBase::instanceMemberVariable; - using ProtectedBase::staticMemberVariable; - using ProtectedBase::staticConstMemberVariable; - using ProtectedBase::anEnum; - using ProtectedBase::stringMember; - using ProtectedBase::IntegerType; - private: - void *go_val; -}; - -#endif diff --git a/Examples/test-suite/go/anonymous_bitfield.go b/Examples/test-suite/go/anonymous_bitfield.go deleted file mode 100644 index 6dd8c7fd3..000000000 --- a/Examples/test-suite/go/anonymous_bitfield.go +++ /dev/null @@ -1,205 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../anonymous_bitfield.i - -package anonymous_bitfield - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrFoo uintptr - -func (p SwigcptrFoo) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrFoo) SwigIsFoo() { -} - -var _wrap_Foo_x_set unsafe.Pointer - -func _swig_wrap_Foo_x_set(base SwigcptrFoo, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_x_set, _swig_p) - return -} - -func (arg1 SwigcptrFoo) SetX(arg2 int) { - _swig_wrap_Foo_x_set(arg1, arg2) -} - -var _wrap_Foo_x_get unsafe.Pointer - -func _swig_wrap_Foo_x_get(base SwigcptrFoo) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_x_get, _swig_p) - return -} - -func (arg1 SwigcptrFoo) GetX() (_swig_ret int) { - return _swig_wrap_Foo_x_get(arg1) -} - -var _wrap_Foo_y_set unsafe.Pointer - -func _swig_wrap_Foo_y_set(base SwigcptrFoo, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_y_set, _swig_p) - return -} - -func (arg1 SwigcptrFoo) SetY(arg2 int) { - _swig_wrap_Foo_y_set(arg1, arg2) -} - -var _wrap_Foo_y_get unsafe.Pointer - -func _swig_wrap_Foo_y_get(base SwigcptrFoo) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_y_get, _swig_p) - return -} - -func (arg1 SwigcptrFoo) GetY() (_swig_ret int) { - return _swig_wrap_Foo_y_get(arg1) -} - -var _wrap_Foo_f_set unsafe.Pointer - -func _swig_wrap_Foo_f_set(base SwigcptrFoo, _ uint) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_f_set, _swig_p) - return -} - -func (arg1 SwigcptrFoo) SetF(arg2 uint) { - _swig_wrap_Foo_f_set(arg1, arg2) -} - -var _wrap_Foo_f_get unsafe.Pointer - -func _swig_wrap_Foo_f_get(base SwigcptrFoo) (_ uint) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_f_get, _swig_p) - return -} - -func (arg1 SwigcptrFoo) GetF() (_swig_ret uint) { - return _swig_wrap_Foo_f_get(arg1) -} - -var _wrap_Foo_z_set unsafe.Pointer - -func _swig_wrap_Foo_z_set(base SwigcptrFoo, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_z_set, _swig_p) - return -} - -func (arg1 SwigcptrFoo) SetZ(arg2 int) { - _swig_wrap_Foo_z_set(arg1, arg2) -} - -var _wrap_Foo_z_get unsafe.Pointer - -func _swig_wrap_Foo_z_get(base SwigcptrFoo) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_z_get, _swig_p) - return -} - -func (arg1 SwigcptrFoo) GetZ() (_swig_ret int) { - return _swig_wrap_Foo_z_get(arg1) -} - -var _wrap_Foo_seq_set unsafe.Pointer - -func _swig_wrap_Foo_seq_set(base SwigcptrFoo, _ uint) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_seq_set, _swig_p) - return -} - -func (arg1 SwigcptrFoo) SetSeq(arg2 uint) { - _swig_wrap_Foo_seq_set(arg1, arg2) -} - -var _wrap_Foo_seq_get unsafe.Pointer - -func _swig_wrap_Foo_seq_get(base SwigcptrFoo) (_ uint) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_seq_get, _swig_p) - return -} - -func (arg1 SwigcptrFoo) GetSeq() (_swig_ret uint) { - return _swig_wrap_Foo_seq_get(arg1) -} - -var _wrap_new_Foo unsafe.Pointer - -func _swig_wrap_new_Foo() (base SwigcptrFoo) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Foo, _swig_p) - return -} - -func NewFoo() (_swig_ret Foo) { - return _swig_wrap_new_Foo() -} - -var _wrap_delete_Foo unsafe.Pointer - -func _swig_wrap_delete_Foo(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Foo, _swig_p) - return -} - -func DeleteFoo(arg1 Foo) { - _swig_wrap_delete_Foo(arg1.Swigcptr()) -} - -type Foo interface { - Swigcptr() uintptr - SwigIsFoo() - SetX(arg2 int) - GetX() (_swig_ret int) - SetY(arg2 int) - GetY() (_swig_ret int) - SetF(arg2 uint) - GetF() (_swig_ret uint) - SetZ(arg2 int) - GetZ() (_swig_ret int) - SetSeq(arg2 uint) - GetSeq() (_swig_ret uint) -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/apply_signed_char.go b/Examples/test-suite/go/apply_signed_char.go deleted file mode 100644 index 9d95e07fe..000000000 --- a/Examples/test-suite/go/apply_signed_char.go +++ /dev/null @@ -1,358 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../apply_signed_char.i - -package apply_signed_char - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -var _wrap_CharValFunction unsafe.Pointer - -func CharValFunction(arg1 int8) (_swig_ret int8) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_CharValFunction, _swig_p) - return -} -var _wrap_CCharValFunction unsafe.Pointer - -func CCharValFunction(arg1 int8) (_swig_ret int8) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_CCharValFunction, _swig_p) - return -} -var _wrap_CCharRefFunction unsafe.Pointer - -func CCharRefFunction(arg1 int8) (_swig_ret int8) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_CCharRefFunction, _swig_p) - return -} -var _wrap_globalchar_set unsafe.Pointer - -func _swig_wrap_globalchar_set(base int8) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_globalchar_set, _swig_p) - return -} - -func SetGlobalchar(arg1 int8) { - _swig_wrap_globalchar_set(arg1) -} - -var _wrap_globalchar_get unsafe.Pointer - -func GetGlobalchar() (_swig_ret int8) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_globalchar_get, _swig_p) - return -} -var _wrap_globalconstchar_get unsafe.Pointer - -func GetGlobalconstchar() (_swig_ret int8) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_globalconstchar_get, _swig_p) - return -} -type _swig_DirectorDirectorTest struct { - SwigcptrDirectorTest - v interface{} -} - -func (p *_swig_DirectorDirectorTest) Swigcptr() uintptr { - return p.SwigcptrDirectorTest.Swigcptr() -} - -func (p *_swig_DirectorDirectorTest) SwigIsDirectorTest() { -} - -func (p *_swig_DirectorDirectorTest) DirectorInterface() interface{} { - return p.v -} - -var _wrap__swig_NewDirectorDirectorTestDirectorTest unsafe.Pointer - -func _swig_NewDirectorDirectorTestDirectorTest(_swig_director *_swig_DirectorDirectorTest) (_swig_ret SwigcptrDirectorTest) { - _swig_p := uintptr(unsafe.Pointer(&_swig_director)) - _cgo_runtime_cgocall(_wrap__swig_NewDirectorDirectorTestDirectorTest, _swig_p) - return -} - -func NewDirectorDirectorTest(v interface{}) DirectorTest { - p := &_swig_DirectorDirectorTest{0, v} - p.SwigcptrDirectorTest = _swig_NewDirectorDirectorTestDirectorTest(p) - return p -} - -type _swig_DirectorInterfaceDirectorTestCharValFunction interface { - CharValFunction(int8) int8 -} - -var _wrap__swig_DirectorDirectorTest_upcall_CharValFunction unsafe.Pointer - -func _swig_wrap__swig_DirectorDirectorTest_upcall_CharValFunction(_swig_ptr SwigcptrDirectorTest, _ int8) (_swig_ret int8) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) - _cgo_runtime_cgocall(_wrap__swig_DirectorDirectorTest_upcall_CharValFunction, _swig_p) - return -} - -func (swig_p *_swig_DirectorDirectorTest) CharValFunction(number int8) int8 { - if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceDirectorTestCharValFunction); swig_ok { - return swig_g.CharValFunction(number) - } - var swig_r int8 - swig_r = _swig_wrap__swig_DirectorDirectorTest_upcall_CharValFunction(swig_p.SwigcptrDirectorTest, number) - return swig_r -} - -func DirectorDirectorTestCharValFunction(p DirectorTest, arg2 int8) int8 { - var swig_r int8 - swig_r = _swig_wrap__swig_DirectorDirectorTest_upcall_CharValFunction(p.(*_swig_DirectorDirectorTest).SwigcptrDirectorTest, arg2) - return swig_r -} - -func Swig_DirectorDirectorTest_callback_CharValFunction(p *_swig_DirectorDirectorTest, arg2 int8) (swig_result int8) { - var swig_r int8 - swig_r = p.CharValFunction(arg2) - return swig_r -} - -type _swig_DirectorInterfaceDirectorTestCCharValFunction interface { - CCharValFunction(int8) int8 -} - -var _wrap__swig_DirectorDirectorTest_upcall_CCharValFunction unsafe.Pointer - -func _swig_wrap__swig_DirectorDirectorTest_upcall_CCharValFunction(_swig_ptr SwigcptrDirectorTest, _ int8) (_swig_ret int8) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) - _cgo_runtime_cgocall(_wrap__swig_DirectorDirectorTest_upcall_CCharValFunction, _swig_p) - return -} - -func (swig_p *_swig_DirectorDirectorTest) CCharValFunction(number int8) int8 { - if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceDirectorTestCCharValFunction); swig_ok { - return swig_g.CCharValFunction(number) - } - var swig_r int8 - swig_r = _swig_wrap__swig_DirectorDirectorTest_upcall_CCharValFunction(swig_p.SwigcptrDirectorTest, number) - return swig_r -} - -func DirectorDirectorTestCCharValFunction(p DirectorTest, arg2 int8) int8 { - var swig_r int8 - swig_r = _swig_wrap__swig_DirectorDirectorTest_upcall_CCharValFunction(p.(*_swig_DirectorDirectorTest).SwigcptrDirectorTest, arg2) - return swig_r -} - -func Swig_DirectorDirectorTest_callback_CCharValFunction(p *_swig_DirectorDirectorTest, arg2 int8) (swig_result int8) { - var swig_r int8 - swig_r = p.CCharValFunction(arg2) - return swig_r -} - -type _swig_DirectorInterfaceDirectorTestCCharRefFunction interface { - CCharRefFunction(int8) int8 -} - -var _wrap__swig_DirectorDirectorTest_upcall_CCharRefFunction unsafe.Pointer - -func _swig_wrap__swig_DirectorDirectorTest_upcall_CCharRefFunction(_swig_ptr SwigcptrDirectorTest, _ int8) (_swig_ret int8) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) - _cgo_runtime_cgocall(_wrap__swig_DirectorDirectorTest_upcall_CCharRefFunction, _swig_p) - return -} - -func (swig_p *_swig_DirectorDirectorTest) CCharRefFunction(number int8) int8 { - if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceDirectorTestCCharRefFunction); swig_ok { - return swig_g.CCharRefFunction(number) - } - var swig_r int8 - swig_r = _swig_wrap__swig_DirectorDirectorTest_upcall_CCharRefFunction(swig_p.SwigcptrDirectorTest, number) - return swig_r -} - -func DirectorDirectorTestCCharRefFunction(p DirectorTest, arg2 int8) int8 { - var swig_r int8 - swig_r = _swig_wrap__swig_DirectorDirectorTest_upcall_CCharRefFunction(p.(*_swig_DirectorDirectorTest).SwigcptrDirectorTest, arg2) - return swig_r -} - -func Swig_DirectorDirectorTest_callback_CCharRefFunction(p *_swig_DirectorDirectorTest, arg2 int8) (swig_result int8) { - var swig_r int8 - swig_r = p.CCharRefFunction(arg2) - return swig_r -} - -var _wrap_DeleteDirectorDirectorTest unsafe.Pointer - -func _swig_wrap_DeleteDirectorDirectorTest(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_DeleteDirectorDirectorTest, _swig_p) - return -} - -func DeleteDirectorDirectorTest(arg1 DirectorTest) { - _swig_wrap_DeleteDirectorDirectorTest(arg1.Swigcptr()) -} - -func Swiggo_DeleteDirector_DirectorTest(p *_swig_DirectorDirectorTest) { - p.SwigcptrDirectorTest = 0 -} - -type SwigcptrDirectorTest uintptr - -func (p SwigcptrDirectorTest) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrDirectorTest) SwigIsDirectorTest() { -} - -func (p SwigcptrDirectorTest) DirectorInterface() interface{} { - return nil -} - -var _wrap_new_DirectorTest unsafe.Pointer - -func _swig_wrap_new_DirectorTest() (base SwigcptrDirectorTest) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_DirectorTest, _swig_p) - return -} - -func NewDirectorTest() (_swig_ret DirectorTest) { - return _swig_wrap_new_DirectorTest() -} - -var _wrap_DirectorTest_CharValFunction unsafe.Pointer - -func _swig_wrap_DirectorTest_CharValFunction(base SwigcptrDirectorTest, _ int8) (_ int8) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_DirectorTest_CharValFunction, _swig_p) - return -} - -func (arg1 SwigcptrDirectorTest) CharValFunction(arg2 int8) (_swig_ret int8) { - return _swig_wrap_DirectorTest_CharValFunction(arg1, arg2) -} - -var _wrap_DirectorTest_CCharValFunction unsafe.Pointer - -func _swig_wrap_DirectorTest_CCharValFunction(base SwigcptrDirectorTest, _ int8) (_ int8) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_DirectorTest_CCharValFunction, _swig_p) - return -} - -func (arg1 SwigcptrDirectorTest) CCharValFunction(arg2 int8) (_swig_ret int8) { - return _swig_wrap_DirectorTest_CCharValFunction(arg1, arg2) -} - -var _wrap_DirectorTest_CCharRefFunction unsafe.Pointer - -func _swig_wrap_DirectorTest_CCharRefFunction(base SwigcptrDirectorTest, _ int8) (_ int8) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_DirectorTest_CCharRefFunction, _swig_p) - return -} - -func (arg1 SwigcptrDirectorTest) CCharRefFunction(arg2 int8) (_swig_ret int8) { - return _swig_wrap_DirectorTest_CCharRefFunction(arg1, arg2) -} - -var _wrap_DirectorTest_memberchar_set unsafe.Pointer - -func _swig_wrap_DirectorTest_memberchar_set(base SwigcptrDirectorTest, _ int8) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_DirectorTest_memberchar_set, _swig_p) - return -} - -func (arg1 SwigcptrDirectorTest) SetMemberchar(arg2 int8) { - _swig_wrap_DirectorTest_memberchar_set(arg1, arg2) -} - -var _wrap_DirectorTest_memberchar_get unsafe.Pointer - -func _swig_wrap_DirectorTest_memberchar_get(base SwigcptrDirectorTest) (_ int8) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_DirectorTest_memberchar_get, _swig_p) - return -} - -func (arg1 SwigcptrDirectorTest) GetMemberchar() (_swig_ret int8) { - return _swig_wrap_DirectorTest_memberchar_get(arg1) -} - -var _wrap_DirectorTest_memberconstchar_get unsafe.Pointer - -func _swig_wrap_DirectorTest_memberconstchar_get(base SwigcptrDirectorTest) (_ int8) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_DirectorTest_memberconstchar_get, _swig_p) - return -} - -func (arg1 SwigcptrDirectorTest) GetMemberconstchar() (_swig_ret int8) { - return _swig_wrap_DirectorTest_memberconstchar_get(arg1) -} - -var _wrap_delete_DirectorTest unsafe.Pointer - -func _swig_wrap_delete_DirectorTest(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_DirectorTest, _swig_p) - return -} - -func DeleteDirectorTest(arg1 DirectorTest) { - _swig_wrap_delete_DirectorTest(arg1.Swigcptr()) -} - -type DirectorTest interface { - Swigcptr() uintptr - SwigIsDirectorTest() - DirectorInterface() interface{} - CharValFunction(arg2 int8) (_swig_ret int8) - CCharValFunction(arg2 int8) (_swig_ret int8) - CCharRefFunction(arg2 int8) (_swig_ret int8) - SetMemberchar(arg2 int8) - GetMemberchar() (_swig_ret int8) - GetMemberconstchar() (_swig_ret int8) -} - - -type SwigcptrSwigDirector_DirectorTest uintptr -type SwigDirector_DirectorTest interface { - Swigcptr() uintptr; -} -func (p SwigcptrSwigDirector_DirectorTest) Swigcptr() uintptr { - return uintptr(p) -} - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/apply_signed_char_wrap.h b/Examples/test-suite/go/apply_signed_char_wrap.h deleted file mode 100644 index 65a2e09e7..000000000 --- a/Examples/test-suite/go/apply_signed_char_wrap.h +++ /dev/null @@ -1,37 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../apply_signed_char.i - -#ifndef SWIG_apply_signed_char_WRAP_H_ -#define SWIG_apply_signed_char_WRAP_H_ - -class SwigDirector_DirectorTest : public DirectorTest -{ - public: - SwigDirector_DirectorTest(void *swig_p); - char _swig_upcall_CharValFunction(char number) { - return DirectorTest::CharValFunction(number); - } - virtual char CharValFunction(char number); - char const _swig_upcall_CCharValFunction(char const number) { - return DirectorTest::CCharValFunction(number); - } - virtual char const CCharValFunction(char const number); - char const &_swig_upcall_CCharRefFunction(char const &number) { - return DirectorTest::CCharRefFunction(number); - } - virtual char const &CCharRefFunction(char const &number); - virtual ~SwigDirector_DirectorTest(); - private: - void *go_val; -}; - -#endif diff --git a/Examples/test-suite/go/apply_strings.go b/Examples/test-suite/go/apply_strings.go deleted file mode 100644 index 009e191b9..000000000 --- a/Examples/test-suite/go/apply_strings.go +++ /dev/null @@ -1,587 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../apply_strings.i - -package apply_strings - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -var _wrap_UCharFunction unsafe.Pointer - -func UCharFunction(arg1 string) (_swig_ret string) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_UCharFunction, _swig_p) - return -} -var _wrap_SCharFunction unsafe.Pointer - -func SCharFunction(arg1 string) (_swig_ret string) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_SCharFunction, _swig_p) - return -} -var _wrap_CUCharFunction unsafe.Pointer - -func CUCharFunction(arg1 string) (_swig_ret string) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_CUCharFunction, _swig_p) - return -} -var _wrap_CSCharFunction unsafe.Pointer - -func CSCharFunction(arg1 string) (_swig_ret string) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_CSCharFunction, _swig_p) - return -} -var _wrap_CharFunction unsafe.Pointer - -func CharFunction(arg1 *byte) (_swig_ret *byte) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_CharFunction, _swig_p) - return -} -var _wrap_CCharFunction unsafe.Pointer - -func CCharFunction(arg1 *byte) (_swig_ret *byte) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_CCharFunction, _swig_p) - return -} -type SwigcptrTNumber uintptr - -func (p SwigcptrTNumber) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrTNumber) SwigIsTNumber() { -} - -var _wrap_TNumber_DigitsMemberA_set unsafe.Pointer - -func _swig_wrap_TNumber_DigitsMemberA_set(base SwigcptrTNumber, _ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_TNumber_DigitsMemberA_set, _swig_p) - return -} - -func (arg1 SwigcptrTNumber) SetDigitsMemberA(arg2 string) { - _swig_wrap_TNumber_DigitsMemberA_set(arg1, arg2) -} - -var _wrap_TNumber_DigitsMemberA_get unsafe.Pointer - -func _swig_wrap_TNumber_DigitsMemberA_get(base SwigcptrTNumber) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_TNumber_DigitsMemberA_get, _swig_p) - return -} - -func (arg1 SwigcptrTNumber) GetDigitsMemberA() (_swig_ret string) { - return _swig_wrap_TNumber_DigitsMemberA_get(arg1) -} - -var _wrap_TNumber_DigitsMemberB_set unsafe.Pointer - -func _swig_wrap_TNumber_DigitsMemberB_set(base SwigcptrTNumber, _ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_TNumber_DigitsMemberB_set, _swig_p) - return -} - -func (arg1 SwigcptrTNumber) SetDigitsMemberB(arg2 string) { - _swig_wrap_TNumber_DigitsMemberB_set(arg1, arg2) -} - -var _wrap_TNumber_DigitsMemberB_get unsafe.Pointer - -func _swig_wrap_TNumber_DigitsMemberB_get(base SwigcptrTNumber) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_TNumber_DigitsMemberB_get, _swig_p) - return -} - -func (arg1 SwigcptrTNumber) GetDigitsMemberB() (_swig_ret string) { - return _swig_wrap_TNumber_DigitsMemberB_get(arg1) -} - -var _wrap_new_TNumber unsafe.Pointer - -func _swig_wrap_new_TNumber() (base SwigcptrTNumber) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_TNumber, _swig_p) - return -} - -func NewTNumber() (_swig_ret TNumber) { - return _swig_wrap_new_TNumber() -} - -var _wrap_delete_TNumber unsafe.Pointer - -func _swig_wrap_delete_TNumber(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_TNumber, _swig_p) - return -} - -func DeleteTNumber(arg1 TNumber) { - _swig_wrap_delete_TNumber(arg1.Swigcptr()) -} - -type TNumber interface { - Swigcptr() uintptr - SwigIsTNumber() - SetDigitsMemberA(arg2 string) - GetDigitsMemberA() (_swig_ret string) - SetDigitsMemberB(arg2 string) - GetDigitsMemberB() (_swig_ret string) -} - -var _wrap_DigitsGlobalA_set unsafe.Pointer - -func _swig_wrap_DigitsGlobalA_set(base string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_DigitsGlobalA_set, _swig_p) - return -} - -func SetDigitsGlobalA(arg1 string) { - _swig_wrap_DigitsGlobalA_set(arg1) -} - -var _wrap_DigitsGlobalA_get unsafe.Pointer - -func GetDigitsGlobalA() (_swig_ret string) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_DigitsGlobalA_get, _swig_p) - return -} -var _wrap_DigitsGlobalB_get unsafe.Pointer - -func GetDigitsGlobalB() (_swig_ret string) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_DigitsGlobalB_get, _swig_p) - return -} -var _wrap_DigitsGlobalC_set unsafe.Pointer - -func _swig_wrap_DigitsGlobalC_set(base string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_DigitsGlobalC_set, _swig_p) - return -} - -func SetDigitsGlobalC(arg1 string) { - _swig_wrap_DigitsGlobalC_set(arg1) -} - -var _wrap_DigitsGlobalC_get unsafe.Pointer - -func GetDigitsGlobalC() (_swig_ret string) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_DigitsGlobalC_get, _swig_p) - return -} -type _swig_DirectorDirectorTest struct { - SwigcptrDirectorTest - v interface{} -} - -func (p *_swig_DirectorDirectorTest) Swigcptr() uintptr { - return p.SwigcptrDirectorTest.Swigcptr() -} - -func (p *_swig_DirectorDirectorTest) SwigIsDirectorTest() { -} - -func (p *_swig_DirectorDirectorTest) DirectorInterface() interface{} { - return p.v -} - -var _wrap__swig_NewDirectorDirectorTestDirectorTest unsafe.Pointer - -func _swig_NewDirectorDirectorTestDirectorTest(_swig_director *_swig_DirectorDirectorTest) (_swig_ret SwigcptrDirectorTest) { - _swig_p := uintptr(unsafe.Pointer(&_swig_director)) - _cgo_runtime_cgocall(_wrap__swig_NewDirectorDirectorTestDirectorTest, _swig_p) - return -} - -func NewDirectorDirectorTest(v interface{}) DirectorTest { - p := &_swig_DirectorDirectorTest{0, v} - p.SwigcptrDirectorTest = _swig_NewDirectorDirectorTestDirectorTest(p) - return p -} - -type _swig_DirectorInterfaceDirectorTestUCharFunction interface { - UCharFunction(string) string -} - -var _wrap__swig_DirectorDirectorTest_upcall_UCharFunction unsafe.Pointer - -func _swig_wrap__swig_DirectorDirectorTest_upcall_UCharFunction(_swig_ptr SwigcptrDirectorTest, _ string) (_swig_ret string) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) - _cgo_runtime_cgocall(_wrap__swig_DirectorDirectorTest_upcall_UCharFunction, _swig_p) - return -} - -func (swig_p *_swig_DirectorDirectorTest) UCharFunction(str string) string { - if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceDirectorTestUCharFunction); swig_ok { - return swig_g.UCharFunction(str) - } - var swig_r string - swig_r = _swig_wrap__swig_DirectorDirectorTest_upcall_UCharFunction(swig_p.SwigcptrDirectorTest, str) - return swig_r -} - -func DirectorDirectorTestUCharFunction(p DirectorTest, arg2 string) string { - var swig_r string - swig_r = _swig_wrap__swig_DirectorDirectorTest_upcall_UCharFunction(p.(*_swig_DirectorDirectorTest).SwigcptrDirectorTest, arg2) - return swig_r -} - -func Swig_DirectorDirectorTest_callback_UCharFunction(p *_swig_DirectorDirectorTest, arg2 string) (swig_result string) { - var swig_r string - swig_r = p.UCharFunction(arg2) - return swig_r -} - -type _swig_DirectorInterfaceDirectorTestSCharFunction interface { - SCharFunction(string) string -} - -var _wrap__swig_DirectorDirectorTest_upcall_SCharFunction unsafe.Pointer - -func _swig_wrap__swig_DirectorDirectorTest_upcall_SCharFunction(_swig_ptr SwigcptrDirectorTest, _ string) (_swig_ret string) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) - _cgo_runtime_cgocall(_wrap__swig_DirectorDirectorTest_upcall_SCharFunction, _swig_p) - return -} - -func (swig_p *_swig_DirectorDirectorTest) SCharFunction(str string) string { - if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceDirectorTestSCharFunction); swig_ok { - return swig_g.SCharFunction(str) - } - var swig_r string - swig_r = _swig_wrap__swig_DirectorDirectorTest_upcall_SCharFunction(swig_p.SwigcptrDirectorTest, str) - return swig_r -} - -func DirectorDirectorTestSCharFunction(p DirectorTest, arg2 string) string { - var swig_r string - swig_r = _swig_wrap__swig_DirectorDirectorTest_upcall_SCharFunction(p.(*_swig_DirectorDirectorTest).SwigcptrDirectorTest, arg2) - return swig_r -} - -func Swig_DirectorDirectorTest_callback_SCharFunction(p *_swig_DirectorDirectorTest, arg2 string) (swig_result string) { - var swig_r string - swig_r = p.SCharFunction(arg2) - return swig_r -} - -type _swig_DirectorInterfaceDirectorTestCUCharFunction interface { - CUCharFunction(string) string -} - -var _wrap__swig_DirectorDirectorTest_upcall_CUCharFunction unsafe.Pointer - -func _swig_wrap__swig_DirectorDirectorTest_upcall_CUCharFunction(_swig_ptr SwigcptrDirectorTest, _ string) (_swig_ret string) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) - _cgo_runtime_cgocall(_wrap__swig_DirectorDirectorTest_upcall_CUCharFunction, _swig_p) - return -} - -func (swig_p *_swig_DirectorDirectorTest) CUCharFunction(str string) string { - if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceDirectorTestCUCharFunction); swig_ok { - return swig_g.CUCharFunction(str) - } - var swig_r string - swig_r = _swig_wrap__swig_DirectorDirectorTest_upcall_CUCharFunction(swig_p.SwigcptrDirectorTest, str) - return swig_r -} - -func DirectorDirectorTestCUCharFunction(p DirectorTest, arg2 string) string { - var swig_r string - swig_r = _swig_wrap__swig_DirectorDirectorTest_upcall_CUCharFunction(p.(*_swig_DirectorDirectorTest).SwigcptrDirectorTest, arg2) - return swig_r -} - -func Swig_DirectorDirectorTest_callback_CUCharFunction(p *_swig_DirectorDirectorTest, arg2 string) (swig_result string) { - var swig_r string - swig_r = p.CUCharFunction(arg2) - return swig_r -} - -type _swig_DirectorInterfaceDirectorTestCSCharFunction interface { - CSCharFunction(string) string -} - -var _wrap__swig_DirectorDirectorTest_upcall_CSCharFunction unsafe.Pointer - -func _swig_wrap__swig_DirectorDirectorTest_upcall_CSCharFunction(_swig_ptr SwigcptrDirectorTest, _ string) (_swig_ret string) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) - _cgo_runtime_cgocall(_wrap__swig_DirectorDirectorTest_upcall_CSCharFunction, _swig_p) - return -} - -func (swig_p *_swig_DirectorDirectorTest) CSCharFunction(str string) string { - if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceDirectorTestCSCharFunction); swig_ok { - return swig_g.CSCharFunction(str) - } - var swig_r string - swig_r = _swig_wrap__swig_DirectorDirectorTest_upcall_CSCharFunction(swig_p.SwigcptrDirectorTest, str) - return swig_r -} - -func DirectorDirectorTestCSCharFunction(p DirectorTest, arg2 string) string { - var swig_r string - swig_r = _swig_wrap__swig_DirectorDirectorTest_upcall_CSCharFunction(p.(*_swig_DirectorDirectorTest).SwigcptrDirectorTest, arg2) - return swig_r -} - -func Swig_DirectorDirectorTest_callback_CSCharFunction(p *_swig_DirectorDirectorTest, arg2 string) (swig_result string) { - var swig_r string - swig_r = p.CSCharFunction(arg2) - return swig_r -} - -type _swig_DirectorInterfaceDirectorTestCharFunction interface { - CharFunction(*byte) *byte -} - -var _wrap__swig_DirectorDirectorTest_upcall_CharFunction unsafe.Pointer - -func _swig_wrap__swig_DirectorDirectorTest_upcall_CharFunction(_swig_ptr SwigcptrDirectorTest, _ *byte) (_swig_ret *byte) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) - _cgo_runtime_cgocall(_wrap__swig_DirectorDirectorTest_upcall_CharFunction, _swig_p) - return -} - -func (swig_p *_swig_DirectorDirectorTest) CharFunction(buffer *byte) *byte { - if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceDirectorTestCharFunction); swig_ok { - return swig_g.CharFunction(buffer) - } - var swig_r *byte - swig_r = _swig_wrap__swig_DirectorDirectorTest_upcall_CharFunction(swig_p.SwigcptrDirectorTest, buffer) - return swig_r -} - -func DirectorDirectorTestCharFunction(p DirectorTest, arg2 *byte) *byte { - var swig_r *byte - swig_r = _swig_wrap__swig_DirectorDirectorTest_upcall_CharFunction(p.(*_swig_DirectorDirectorTest).SwigcptrDirectorTest, arg2) - return swig_r -} - -func Swig_DirectorDirectorTest_callback_CharFunction(p *_swig_DirectorDirectorTest, arg2 *byte) (swig_result *byte) { - var swig_r *byte - swig_r = p.CharFunction(arg2) - return swig_r -} - -type _swig_DirectorInterfaceDirectorTestCCharFunction interface { - CCharFunction(*byte) *byte -} - -var _wrap__swig_DirectorDirectorTest_upcall_CCharFunction unsafe.Pointer - -func _swig_wrap__swig_DirectorDirectorTest_upcall_CCharFunction(_swig_ptr SwigcptrDirectorTest, _ *byte) (_swig_ret *byte) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) - _cgo_runtime_cgocall(_wrap__swig_DirectorDirectorTest_upcall_CCharFunction, _swig_p) - return -} - -func (swig_p *_swig_DirectorDirectorTest) CCharFunction(buffer *byte) *byte { - if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceDirectorTestCCharFunction); swig_ok { - return swig_g.CCharFunction(buffer) - } - var swig_r *byte - swig_r = _swig_wrap__swig_DirectorDirectorTest_upcall_CCharFunction(swig_p.SwigcptrDirectorTest, buffer) - return swig_r -} - -func DirectorDirectorTestCCharFunction(p DirectorTest, arg2 *byte) *byte { - var swig_r *byte - swig_r = _swig_wrap__swig_DirectorDirectorTest_upcall_CCharFunction(p.(*_swig_DirectorDirectorTest).SwigcptrDirectorTest, arg2) - return swig_r -} - -func Swig_DirectorDirectorTest_callback_CCharFunction(p *_swig_DirectorDirectorTest, arg2 *byte) (swig_result *byte) { - var swig_r *byte - swig_r = p.CCharFunction(arg2) - return swig_r -} - -var _wrap_DeleteDirectorDirectorTest unsafe.Pointer - -func _swig_wrap_DeleteDirectorDirectorTest(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_DeleteDirectorDirectorTest, _swig_p) - return -} - -func DeleteDirectorDirectorTest(arg1 DirectorTest) { - _swig_wrap_DeleteDirectorDirectorTest(arg1.Swigcptr()) -} - -func Swiggo_DeleteDirector_DirectorTest(p *_swig_DirectorDirectorTest) { - p.SwigcptrDirectorTest = 0 -} - -type SwigcptrDirectorTest uintptr - -func (p SwigcptrDirectorTest) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrDirectorTest) SwigIsDirectorTest() { -} - -func (p SwigcptrDirectorTest) DirectorInterface() interface{} { - return nil -} - -var _wrap_DirectorTest_UCharFunction unsafe.Pointer - -func _swig_wrap_DirectorTest_UCharFunction(base SwigcptrDirectorTest, _ string) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_DirectorTest_UCharFunction, _swig_p) - return -} - -func (arg1 SwigcptrDirectorTest) UCharFunction(arg2 string) (_swig_ret string) { - return _swig_wrap_DirectorTest_UCharFunction(arg1, arg2) -} - -var _wrap_DirectorTest_SCharFunction unsafe.Pointer - -func _swig_wrap_DirectorTest_SCharFunction(base SwigcptrDirectorTest, _ string) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_DirectorTest_SCharFunction, _swig_p) - return -} - -func (arg1 SwigcptrDirectorTest) SCharFunction(arg2 string) (_swig_ret string) { - return _swig_wrap_DirectorTest_SCharFunction(arg1, arg2) -} - -var _wrap_DirectorTest_CUCharFunction unsafe.Pointer - -func _swig_wrap_DirectorTest_CUCharFunction(base SwigcptrDirectorTest, _ string) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_DirectorTest_CUCharFunction, _swig_p) - return -} - -func (arg1 SwigcptrDirectorTest) CUCharFunction(arg2 string) (_swig_ret string) { - return _swig_wrap_DirectorTest_CUCharFunction(arg1, arg2) -} - -var _wrap_DirectorTest_CSCharFunction unsafe.Pointer - -func _swig_wrap_DirectorTest_CSCharFunction(base SwigcptrDirectorTest, _ string) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_DirectorTest_CSCharFunction, _swig_p) - return -} - -func (arg1 SwigcptrDirectorTest) CSCharFunction(arg2 string) (_swig_ret string) { - return _swig_wrap_DirectorTest_CSCharFunction(arg1, arg2) -} - -var _wrap_DirectorTest_CharFunction unsafe.Pointer - -func _swig_wrap_DirectorTest_CharFunction(base SwigcptrDirectorTest, _ *byte) (_ *byte) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_DirectorTest_CharFunction, _swig_p) - return -} - -func (arg1 SwigcptrDirectorTest) CharFunction(arg2 *byte) (_swig_ret *byte) { - return _swig_wrap_DirectorTest_CharFunction(arg1, arg2) -} - -var _wrap_DirectorTest_CCharFunction unsafe.Pointer - -func _swig_wrap_DirectorTest_CCharFunction(base SwigcptrDirectorTest, _ *byte) (_ *byte) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_DirectorTest_CCharFunction, _swig_p) - return -} - -func (arg1 SwigcptrDirectorTest) CCharFunction(arg2 *byte) (_swig_ret *byte) { - return _swig_wrap_DirectorTest_CCharFunction(arg1, arg2) -} - -var _wrap_delete_DirectorTest unsafe.Pointer - -func _swig_wrap_delete_DirectorTest(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_DirectorTest, _swig_p) - return -} - -func DeleteDirectorTest(arg1 DirectorTest) { - _swig_wrap_delete_DirectorTest(arg1.Swigcptr()) -} - -var _wrap_new_DirectorTest unsafe.Pointer - -func _swig_wrap_new_DirectorTest() (base SwigcptrDirectorTest) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_DirectorTest, _swig_p) - return -} - -func NewDirectorTest() (_swig_ret DirectorTest) { - return _swig_wrap_new_DirectorTest() -} - -type DirectorTest interface { - Swigcptr() uintptr - SwigIsDirectorTest() - DirectorInterface() interface{} - UCharFunction(arg2 string) (_swig_ret string) - SCharFunction(arg2 string) (_swig_ret string) - CUCharFunction(arg2 string) (_swig_ret string) - CSCharFunction(arg2 string) (_swig_ret string) - CharFunction(arg2 *byte) (_swig_ret *byte) - CCharFunction(arg2 *byte) (_swig_ret *byte) -} - - -type SwigcptrSwigDirector_DirectorTest uintptr -type SwigDirector_DirectorTest interface { - Swigcptr() uintptr; -} -func (p SwigcptrSwigDirector_DirectorTest) Swigcptr() uintptr { - return uintptr(p) -} - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/apply_strings_wrap.h b/Examples/test-suite/go/apply_strings_wrap.h deleted file mode 100644 index 5dfaea869..000000000 --- a/Examples/test-suite/go/apply_strings_wrap.h +++ /dev/null @@ -1,49 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../apply_strings.i - -#ifndef SWIG_apply_strings_WRAP_H_ -#define SWIG_apply_strings_WRAP_H_ - -class SwigDirector_DirectorTest : public DirectorTest -{ - public: - SwigDirector_DirectorTest(void *swig_p); - UCharPtr _swig_upcall_UCharFunction(UCharPtr str) { - return DirectorTest::UCharFunction(str); - } - virtual UCharPtr UCharFunction(UCharPtr str); - SCharPtr _swig_upcall_SCharFunction(SCharPtr str) { - return DirectorTest::SCharFunction(str); - } - virtual SCharPtr SCharFunction(SCharPtr str); - CUCharPtr _swig_upcall_CUCharFunction(CUCharPtr str) { - return DirectorTest::CUCharFunction(str); - } - virtual CUCharPtr CUCharFunction(CUCharPtr str); - CSCharPtr _swig_upcall_CSCharFunction(CSCharPtr str) { - return DirectorTest::CSCharFunction(str); - } - virtual CSCharPtr CSCharFunction(CSCharPtr str); - CharPtr _swig_upcall_CharFunction(CharPtr buffer) { - return DirectorTest::CharFunction(buffer); - } - virtual CharPtr CharFunction(CharPtr buffer); - CCharPtr _swig_upcall_CCharFunction(CCharPtr buffer) { - return DirectorTest::CCharFunction(buffer); - } - virtual CCharPtr CCharFunction(CCharPtr buffer); - virtual ~SwigDirector_DirectorTest(); - private: - void *go_val; -}; - -#endif diff --git a/Examples/test-suite/go/argout.go b/Examples/test-suite/go/argout.go deleted file mode 100644 index 122cf57c4..000000000 --- a/Examples/test-suite/go/argout.go +++ /dev/null @@ -1,122 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../argout.i - -package argout - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -var _wrap_new_intp unsafe.Pointer - -func New_intp() (_swig_ret *int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_new_intp, _swig_p) - return -} -var _wrap_copy_intp unsafe.Pointer - -func Copy_intp(arg1 int) (_swig_ret *int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_copy_intp, _swig_p) - return -} -var _wrap_delete_intp unsafe.Pointer - -func _swig_wrap_delete_intp(base *int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_intp, _swig_p) - return -} - -func Delete_intp(arg1 *int) { - _swig_wrap_delete_intp(arg1) -} - -var _wrap_intp_assign unsafe.Pointer - -func _swig_wrap_intp_assign(base *int, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_intp_assign, _swig_p) - return -} - -func Intp_assign(arg1 *int, arg2 int) { - _swig_wrap_intp_assign(arg1, arg2) -} - -var _wrap_intp_value unsafe.Pointer - -func Intp_value(arg1 *int) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_intp_value, _swig_p) - return -} -var _wrap_incp unsafe.Pointer - -func Incp(arg1 *int) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_incp, _swig_p) - return -} -var _wrap_incr unsafe.Pointer - -func Incr(arg1 *int) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_incr, _swig_p) - return -} -var _wrap_inctr unsafe.Pointer - -func Inctr(arg1 *int) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_inctr, _swig_p) - return -} -var _wrap_voidhandle unsafe.Pointer - -func _swig_wrap_voidhandle(base *uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_voidhandle, _swig_p) - return -} - -func Voidhandle(arg1 *uintptr) { - _swig_wrap_voidhandle(arg1) -} - -var _wrap_handle unsafe.Pointer - -func Handle(arg1 uintptr) (_swig_ret string) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_handle, _swig_p) - return -} - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/argout_runme b/Examples/test-suite/go/argout_runme deleted file mode 100755 index fa4ac2d74..000000000 Binary files a/Examples/test-suite/go/argout_runme and /dev/null differ diff --git a/Examples/test-suite/go/array_member.go b/Examples/test-suite/go/array_member.go deleted file mode 100644 index 3d284e341..000000000 --- a/Examples/test-suite/go/array_member.go +++ /dev/null @@ -1,586 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../array_member.i - -package array_member - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrFoo uintptr - -func (p SwigcptrFoo) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrFoo) SwigIsFoo() { -} - -var _wrap_Foo_text_set unsafe.Pointer - -func _swig_wrap_Foo_text_set(base SwigcptrFoo, _ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_text_set, _swig_p) - return -} - -func (arg1 SwigcptrFoo) SetText(arg2 string) { - _swig_wrap_Foo_text_set(arg1, arg2) -} - -var _wrap_Foo_text_get unsafe.Pointer - -func _swig_wrap_Foo_text_get(base SwigcptrFoo) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_text_get, _swig_p) - return -} - -func (arg1 SwigcptrFoo) GetText() (_swig_ret string) { - return _swig_wrap_Foo_text_get(arg1) -} - -var _wrap_Foo_data_set unsafe.Pointer - -func _swig_wrap_Foo_data_set(base SwigcptrFoo, _ *int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_data_set, _swig_p) - return -} - -func (arg1 SwigcptrFoo) SetData(arg2 *int) { - _swig_wrap_Foo_data_set(arg1, arg2) -} - -var _wrap_Foo_data_get unsafe.Pointer - -func _swig_wrap_Foo_data_get(base SwigcptrFoo) (_ *int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_data_get, _swig_p) - return -} - -func (arg1 SwigcptrFoo) GetData() (_swig_ret *int) { - return _swig_wrap_Foo_data_get(arg1) -} - -var _wrap_new_Foo unsafe.Pointer - -func _swig_wrap_new_Foo() (base SwigcptrFoo) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Foo, _swig_p) - return -} - -func NewFoo() (_swig_ret Foo) { - return _swig_wrap_new_Foo() -} - -var _wrap_delete_Foo unsafe.Pointer - -func _swig_wrap_delete_Foo(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Foo, _swig_p) - return -} - -func DeleteFoo(arg1 Foo) { - _swig_wrap_delete_Foo(arg1.Swigcptr()) -} - -type Foo interface { - Swigcptr() uintptr - SwigIsFoo() - SetText(arg2 string) - GetText() (_swig_ret string) - SetData(arg2 *int) - GetData() (_swig_ret *int) -} - -var _wrap_global_data_set unsafe.Pointer - -func _swig_wrap_global_data_set(base *int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_global_data_set, _swig_p) - return -} - -func SetGlobal_data(arg1 *int) { - _swig_wrap_global_data_set(arg1) -} - -var _wrap_global_data_get unsafe.Pointer - -func GetGlobal_data() (_swig_ret *int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_global_data_get, _swig_p) - return -} -var _wrap_set_value unsafe.Pointer - -func _swig_wrap_set_value(base *int, _ int, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_set_value, _swig_p) - return -} - -func Set_value(arg1 *int, arg2 int, arg3 int) { - _swig_wrap_set_value(arg1, arg2, arg3) -} - -var _wrap_get_value unsafe.Pointer - -func Get_value(arg1 *int, arg2 int) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_get_value, _swig_p) - return -} -type SwigcptrMaterial uintptr - -func (p SwigcptrMaterial) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrMaterial) SwigIsMaterial() { -} - -var _wrap_new_Material unsafe.Pointer - -func _swig_wrap_new_Material() (base SwigcptrMaterial) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Material, _swig_p) - return -} - -func NewMaterial() (_swig_ret Material) { - return _swig_wrap_new_Material() -} - -var _wrap_delete_Material unsafe.Pointer - -func _swig_wrap_delete_Material(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Material, _swig_p) - return -} - -func DeleteMaterial(arg1 Material) { - _swig_wrap_delete_Material(arg1.Swigcptr()) -} - -type Material interface { - Swigcptr() uintptr - SwigIsMaterial() -} - -type SwigcptrRayPacketData uintptr - -func (p SwigcptrRayPacketData) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrRayPacketData) SwigIsRayPacketData() { -} - -var _wrap_Size_RayPacketData unsafe.Pointer - -func _swig_getRayPacketData_Size_RayPacketData() (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_Size_RayPacketData, _swig_p) - return -} -var RayPacketDataSize int = _swig_getRayPacketData_Size_RayPacketData() -var _wrap_RayPacketData_chitMat_set unsafe.Pointer - -func _swig_wrap_RayPacketData_chitMat_set(base SwigcptrRayPacketData, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_RayPacketData_chitMat_set, _swig_p) - return -} - -func (arg1 SwigcptrRayPacketData) SetChitMat(arg2 Material) { - _swig_wrap_RayPacketData_chitMat_set(arg1, arg2.Swigcptr()) -} - -var _wrap_RayPacketData_chitMat_get unsafe.Pointer - -func _swig_wrap_RayPacketData_chitMat_get(base SwigcptrRayPacketData) (_ SwigcptrMaterial) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_RayPacketData_chitMat_get, _swig_p) - return -} - -func (arg1 SwigcptrRayPacketData) GetChitMat() (_swig_ret Material) { - return _swig_wrap_RayPacketData_chitMat_get(arg1) -} - -var _wrap_RayPacketData_hitMat_val_set unsafe.Pointer - -func _swig_wrap_RayPacketData_hitMat_val_set(base SwigcptrRayPacketData, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_RayPacketData_hitMat_val_set, _swig_p) - return -} - -func (arg1 SwigcptrRayPacketData) SetHitMat_val(arg2 Material) { - _swig_wrap_RayPacketData_hitMat_val_set(arg1, arg2.Swigcptr()) -} - -var _wrap_RayPacketData_hitMat_val_get unsafe.Pointer - -func _swig_wrap_RayPacketData_hitMat_val_get(base SwigcptrRayPacketData) (_ SwigcptrMaterial) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_RayPacketData_hitMat_val_get, _swig_p) - return -} - -func (arg1 SwigcptrRayPacketData) GetHitMat_val() (_swig_ret Material) { - return _swig_wrap_RayPacketData_hitMat_val_get(arg1) -} - -var _wrap_RayPacketData_hitMat_set unsafe.Pointer - -func _swig_wrap_RayPacketData_hitMat_set(base SwigcptrRayPacketData, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_RayPacketData_hitMat_set, _swig_p) - return -} - -func (arg1 SwigcptrRayPacketData) SetHitMat(arg2 Material) { - _swig_wrap_RayPacketData_hitMat_set(arg1, arg2.Swigcptr()) -} - -var _wrap_RayPacketData_hitMat_get unsafe.Pointer - -func _swig_wrap_RayPacketData_hitMat_get(base SwigcptrRayPacketData) (_ SwigcptrMaterial) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_RayPacketData_hitMat_get, _swig_p) - return -} - -func (arg1 SwigcptrRayPacketData) GetHitMat() (_swig_ret Material) { - return _swig_wrap_RayPacketData_hitMat_get(arg1) -} - -var _wrap_RayPacketData_chitMat2_set unsafe.Pointer - -func _swig_wrap_RayPacketData_chitMat2_set(base SwigcptrRayPacketData, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_RayPacketData_chitMat2_set, _swig_p) - return -} - -func (arg1 SwigcptrRayPacketData) SetChitMat2(arg2 Material) { - _swig_wrap_RayPacketData_chitMat2_set(arg1, arg2.Swigcptr()) -} - -var _wrap_RayPacketData_chitMat2_get unsafe.Pointer - -func _swig_wrap_RayPacketData_chitMat2_get(base SwigcptrRayPacketData) (_ SwigcptrMaterial) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_RayPacketData_chitMat2_get, _swig_p) - return -} - -func (arg1 SwigcptrRayPacketData) GetChitMat2() (_swig_ret Material) { - return _swig_wrap_RayPacketData_chitMat2_get(arg1) -} - -var _wrap_RayPacketData_hitMat_val2_set unsafe.Pointer - -func _swig_wrap_RayPacketData_hitMat_val2_set(base SwigcptrRayPacketData, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_RayPacketData_hitMat_val2_set, _swig_p) - return -} - -func (arg1 SwigcptrRayPacketData) SetHitMat_val2(arg2 Material) { - _swig_wrap_RayPacketData_hitMat_val2_set(arg1, arg2.Swigcptr()) -} - -var _wrap_RayPacketData_hitMat_val2_get unsafe.Pointer - -func _swig_wrap_RayPacketData_hitMat_val2_get(base SwigcptrRayPacketData) (_ SwigcptrMaterial) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_RayPacketData_hitMat_val2_get, _swig_p) - return -} - -func (arg1 SwigcptrRayPacketData) GetHitMat_val2() (_swig_ret Material) { - return _swig_wrap_RayPacketData_hitMat_val2_get(arg1) -} - -var _wrap_RayPacketData_hitMat2_set unsafe.Pointer - -func _swig_wrap_RayPacketData_hitMat2_set(base SwigcptrRayPacketData, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_RayPacketData_hitMat2_set, _swig_p) - return -} - -func (arg1 SwigcptrRayPacketData) SetHitMat2(arg2 Material) { - _swig_wrap_RayPacketData_hitMat2_set(arg1, arg2.Swigcptr()) -} - -var _wrap_RayPacketData_hitMat2_get unsafe.Pointer - -func _swig_wrap_RayPacketData_hitMat2_get(base SwigcptrRayPacketData) (_ SwigcptrMaterial) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_RayPacketData_hitMat2_get, _swig_p) - return -} - -func (arg1 SwigcptrRayPacketData) GetHitMat2() (_swig_ret Material) { - return _swig_wrap_RayPacketData_hitMat2_get(arg1) -} - -var _wrap_new_RayPacketData unsafe.Pointer - -func _swig_wrap_new_RayPacketData() (base SwigcptrRayPacketData) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_RayPacketData, _swig_p) - return -} - -func NewRayPacketData() (_swig_ret RayPacketData) { - return _swig_wrap_new_RayPacketData() -} - -var _wrap_delete_RayPacketData unsafe.Pointer - -func _swig_wrap_delete_RayPacketData(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_RayPacketData, _swig_p) - return -} - -func DeleteRayPacketData(arg1 RayPacketData) { - _swig_wrap_delete_RayPacketData(arg1.Swigcptr()) -} - -type RayPacketData interface { - Swigcptr() uintptr - SwigIsRayPacketData() - SetChitMat(arg2 Material) - GetChitMat() (_swig_ret Material) - SetHitMat_val(arg2 Material) - GetHitMat_val() (_swig_ret Material) - SetHitMat(arg2 Material) - GetHitMat() (_swig_ret Material) - SetChitMat2(arg2 Material) - GetChitMat2() (_swig_ret Material) - SetHitMat_val2(arg2 Material) - GetHitMat_val2() (_swig_ret Material) - SetHitMat2(arg2 Material) - GetHitMat2() (_swig_ret Material) -} - -const BUFF_LEN int = 12 -type SwigcptrMyBuff uintptr - -func (p SwigcptrMyBuff) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrMyBuff) SwigIsMyBuff() { -} - -var _wrap_MyBuff_i_set unsafe.Pointer - -func _swig_wrap_MyBuff_i_set(base SwigcptrMyBuff, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_MyBuff_i_set, _swig_p) - return -} - -func (arg1 SwigcptrMyBuff) SetI(arg2 int) { - _swig_wrap_MyBuff_i_set(arg1, arg2) -} - -var _wrap_MyBuff_i_get unsafe.Pointer - -func _swig_wrap_MyBuff_i_get(base SwigcptrMyBuff) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_MyBuff_i_get, _swig_p) - return -} - -func (arg1 SwigcptrMyBuff) GetI() (_swig_ret int) { - return _swig_wrap_MyBuff_i_get(arg1) -} - -var _wrap_MyBuff_x_set unsafe.Pointer - -func _swig_wrap_MyBuff_x_set(base SwigcptrMyBuff, _ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_MyBuff_x_set, _swig_p) - return -} - -func (arg1 SwigcptrMyBuff) SetX(arg2 string) { - _swig_wrap_MyBuff_x_set(arg1, arg2) -} - -var _wrap_MyBuff_x_get unsafe.Pointer - -func _swig_wrap_MyBuff_x_get(base SwigcptrMyBuff) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_MyBuff_x_get, _swig_p) - return -} - -func (arg1 SwigcptrMyBuff) GetX() (_swig_ret string) { - return _swig_wrap_MyBuff_x_get(arg1) -} - -var _wrap_new_MyBuff unsafe.Pointer - -func _swig_wrap_new_MyBuff() (base SwigcptrMyBuff) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_MyBuff, _swig_p) - return -} - -func NewMyBuff() (_swig_ret MyBuff) { - return _swig_wrap_new_MyBuff() -} - -var _wrap_delete_MyBuff unsafe.Pointer - -func _swig_wrap_delete_MyBuff(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_MyBuff, _swig_p) - return -} - -func DeleteMyBuff(arg1 MyBuff) { - _swig_wrap_delete_MyBuff(arg1.Swigcptr()) -} - -type MyBuff interface { - Swigcptr() uintptr - SwigIsMyBuff() - SetI(arg2 int) - GetI() (_swig_ret int) - SetX(arg2 string) - GetX() (_swig_ret string) -} - -type SwigcptrMySBuff uintptr - -func (p SwigcptrMySBuff) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrMySBuff) SwigIsMySBuff() { -} - -var _wrap_MySBuff_i_set unsafe.Pointer - -func _swig_wrap_MySBuff_i_set(base SwigcptrMySBuff, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_MySBuff_i_set, _swig_p) - return -} - -func (arg1 SwigcptrMySBuff) SetI(arg2 int) { - _swig_wrap_MySBuff_i_set(arg1, arg2) -} - -var _wrap_MySBuff_i_get unsafe.Pointer - -func _swig_wrap_MySBuff_i_get(base SwigcptrMySBuff) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_MySBuff_i_get, _swig_p) - return -} - -func (arg1 SwigcptrMySBuff) GetI() (_swig_ret int) { - return _swig_wrap_MySBuff_i_get(arg1) -} - -var _wrap_MySBuff_x_set unsafe.Pointer - -func _swig_wrap_MySBuff_x_set(base SwigcptrMySBuff, _ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_MySBuff_x_set, _swig_p) - return -} - -func (arg1 SwigcptrMySBuff) SetX(arg2 string) { - _swig_wrap_MySBuff_x_set(arg1, arg2) -} - -var _wrap_MySBuff_x_get unsafe.Pointer - -func _swig_wrap_MySBuff_x_get(base SwigcptrMySBuff) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_MySBuff_x_get, _swig_p) - return -} - -func (arg1 SwigcptrMySBuff) GetX() (_swig_ret string) { - return _swig_wrap_MySBuff_x_get(arg1) -} - -var _wrap_new_MySBuff unsafe.Pointer - -func _swig_wrap_new_MySBuff() (base SwigcptrMySBuff) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_MySBuff, _swig_p) - return -} - -func NewMySBuff() (_swig_ret MySBuff) { - return _swig_wrap_new_MySBuff() -} - -var _wrap_delete_MySBuff unsafe.Pointer - -func _swig_wrap_delete_MySBuff(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_MySBuff, _swig_p) - return -} - -func DeleteMySBuff(arg1 MySBuff) { - _swig_wrap_delete_MySBuff(arg1.Swigcptr()) -} - -type MySBuff interface { - Swigcptr() uintptr - SwigIsMySBuff() - SetI(arg2 int) - GetI() (_swig_ret int) - SetX(arg2 string) - GetX() (_swig_ret string) -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/array_member_runme b/Examples/test-suite/go/array_member_runme deleted file mode 100755 index f97cc4f55..000000000 Binary files a/Examples/test-suite/go/array_member_runme and /dev/null differ diff --git a/Examples/test-suite/go/array_typedef_memberin.go b/Examples/test-suite/go/array_typedef_memberin.go deleted file mode 100644 index bc1c3bf7a..000000000 --- a/Examples/test-suite/go/array_typedef_memberin.go +++ /dev/null @@ -1,328 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../array_typedef_memberin.i - -package array_typedef_memberin - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrExampleDetail uintptr - -func (p SwigcptrExampleDetail) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrExampleDetail) SwigIsExampleDetail() { -} - -var _wrap_ExampleDetail_node_list_set unsafe.Pointer - -func _swig_wrap_ExampleDetail_node_list_set(base SwigcptrExampleDetail, _ *int16) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_ExampleDetail_node_list_set, _swig_p) - return -} - -func (arg1 SwigcptrExampleDetail) SetNode_list(arg2 *int16) { - _swig_wrap_ExampleDetail_node_list_set(arg1, arg2) -} - -var _wrap_ExampleDetail_node_list_get unsafe.Pointer - -func _swig_wrap_ExampleDetail_node_list_get(base SwigcptrExampleDetail) (_ *int16) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_ExampleDetail_node_list_get, _swig_p) - return -} - -func (arg1 SwigcptrExampleDetail) GetNode_list() (_swig_ret *int16) { - return _swig_wrap_ExampleDetail_node_list_get(arg1) -} - -var _wrap_ExampleDetail_node_list2_get unsafe.Pointer - -func _swig_wrap_ExampleDetail_node_list2_get(base SwigcptrExampleDetail) (_ *int16) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_ExampleDetail_node_list2_get, _swig_p) - return -} - -func (arg1 SwigcptrExampleDetail) GetNode_list2() (_swig_ret *int16) { - return _swig_wrap_ExampleDetail_node_list2_get(arg1) -} - -var _wrap_ExampleDetail_node_list3_get unsafe.Pointer - -func _swig_wrap_ExampleDetail_node_list3_get(base SwigcptrExampleDetail) (_ *int16) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_ExampleDetail_node_list3_get, _swig_p) - return -} - -func (arg1 SwigcptrExampleDetail) GetNode_list3() (_swig_ret *int16) { - return _swig_wrap_ExampleDetail_node_list3_get(arg1) -} - -var _wrap_ExampleDetail_fn1 unsafe.Pointer - -func _swig_wrap_ExampleDetail_fn1(base SwigcptrExampleDetail, _ *int16) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_ExampleDetail_fn1, _swig_p) - return -} - -func (arg1 SwigcptrExampleDetail) Fn1(arg2 *int16) { - _swig_wrap_ExampleDetail_fn1(arg1, arg2) -} - -var _wrap_ExampleDetail_fn2 unsafe.Pointer - -func _swig_wrap_ExampleDetail_fn2(base SwigcptrExampleDetail, _ *int16) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_ExampleDetail_fn2, _swig_p) - return -} - -func (arg1 SwigcptrExampleDetail) Fn2(arg2 *int16) { - _swig_wrap_ExampleDetail_fn2(arg1, arg2) -} - -var _wrap_ExampleDetail_fn3 unsafe.Pointer - -func _swig_wrap_ExampleDetail_fn3(base SwigcptrExampleDetail, _ *int16) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_ExampleDetail_fn3, _swig_p) - return -} - -func (arg1 SwigcptrExampleDetail) Fn3(arg2 *int16) { - _swig_wrap_ExampleDetail_fn3(arg1, arg2) -} - -var _wrap_ExampleDetail_fn4 unsafe.Pointer - -func _swig_wrap_ExampleDetail_fn4(base SwigcptrExampleDetail, _ **int16) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_ExampleDetail_fn4, _swig_p) - return -} - -func (arg1 SwigcptrExampleDetail) Fn4(arg2 **int16) { - _swig_wrap_ExampleDetail_fn4(arg1, arg2) -} - -var _wrap_ExampleDetail_fn5 unsafe.Pointer - -func _swig_wrap_ExampleDetail_fn5(base SwigcptrExampleDetail, _ **int16) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_ExampleDetail_fn5, _swig_p) - return -} - -func (arg1 SwigcptrExampleDetail) Fn5(arg2 **int16) { - _swig_wrap_ExampleDetail_fn5(arg1, arg2) -} - -var _wrap_ExampleDetail_fn6 unsafe.Pointer - -func _swig_wrap_ExampleDetail_fn6(base SwigcptrExampleDetail, _ **int16) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_ExampleDetail_fn6, _swig_p) - return -} - -func (arg1 SwigcptrExampleDetail) Fn6(arg2 **int16) { - _swig_wrap_ExampleDetail_fn6(arg1, arg2) -} - -var _wrap_ExampleDetail_fn7 unsafe.Pointer - -func _swig_wrap_ExampleDetail_fn7(base SwigcptrExampleDetail, _ ***int16) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_ExampleDetail_fn7, _swig_p) - return -} - -func (arg1 SwigcptrExampleDetail) Fn7(arg2 ***int16) { - _swig_wrap_ExampleDetail_fn7(arg1, arg2) -} - -var _wrap_ExampleDetail_fn8 unsafe.Pointer - -func _swig_wrap_ExampleDetail_fn8(base SwigcptrExampleDetail, _ ***int16) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_ExampleDetail_fn8, _swig_p) - return -} - -func (arg1 SwigcptrExampleDetail) Fn8(arg2 ***int16) { - _swig_wrap_ExampleDetail_fn8(arg1, arg2) -} - -var _wrap_ExampleDetail_fn9 unsafe.Pointer - -func _swig_wrap_ExampleDetail_fn9(base SwigcptrExampleDetail, _ ***int16) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_ExampleDetail_fn9, _swig_p) - return -} - -func (arg1 SwigcptrExampleDetail) Fn9(arg2 ***int16) { - _swig_wrap_ExampleDetail_fn9(arg1, arg2) -} - -var _wrap_new_ExampleDetail unsafe.Pointer - -func _swig_wrap_new_ExampleDetail() (base SwigcptrExampleDetail) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_ExampleDetail, _swig_p) - return -} - -func NewExampleDetail() (_swig_ret ExampleDetail) { - return _swig_wrap_new_ExampleDetail() -} - -var _wrap_delete_ExampleDetail unsafe.Pointer - -func _swig_wrap_delete_ExampleDetail(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_ExampleDetail, _swig_p) - return -} - -func DeleteExampleDetail(arg1 ExampleDetail) { - _swig_wrap_delete_ExampleDetail(arg1.Swigcptr()) -} - -type ExampleDetail interface { - Swigcptr() uintptr - SwigIsExampleDetail() - SetNode_list(arg2 *int16) - GetNode_list() (_swig_ret *int16) - GetNode_list2() (_swig_ret *int16) - GetNode_list3() (_swig_ret *int16) - Fn1(arg2 *int16) - Fn2(arg2 *int16) - Fn3(arg2 *int16) - Fn4(arg2 **int16) - Fn5(arg2 **int16) - Fn6(arg2 **int16) - Fn7(arg2 ***int16) - Fn8(arg2 ***int16) - Fn9(arg2 ***int16) -} - -var _wrap_test_1 unsafe.Pointer - -func _swig_wrap_test_1(base **int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_test_1, _swig_p) - return -} - -func Test_1(arg1 **int) { - _swig_wrap_test_1(arg1) -} - -var _wrap_test_2 unsafe.Pointer - -func _swig_wrap_test_2(base **int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_test_2, _swig_p) - return -} - -func Test_2(arg1 **int) { - _swig_wrap_test_2(arg1) -} - -var _wrap_test_3 unsafe.Pointer - -func _swig_wrap_test_3(base **int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_test_3, _swig_p) - return -} - -func Test_3(arg1 **int) { - _swig_wrap_test_3(arg1) -} - -var _wrap_test_4 unsafe.Pointer - -func _swig_wrap_test_4(base **int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_test_4, _swig_p) - return -} - -func Test_4(arg1 **int) { - _swig_wrap_test_4(arg1) -} - -var _wrap_test_5 unsafe.Pointer - -func _swig_wrap_test_5(base **int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_test_5, _swig_p) - return -} - -func Test_5(arg1 **int) { - _swig_wrap_test_5(arg1) -} - -var _wrap_test_3r unsafe.Pointer - -func _swig_wrap_test_3r(base ***int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_test_3r, _swig_p) - return -} - -func Test_3r(arg1 ***int) { - _swig_wrap_test_3r(arg1) -} - -var _wrap_test_4r unsafe.Pointer - -func _swig_wrap_test_4r(base ***int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_test_4r, _swig_p) - return -} - -func Test_4r(arg1 ***int) { - _swig_wrap_test_4r(arg1) -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/arrayref.go b/Examples/test-suite/go/arrayref.go deleted file mode 100644 index 1027233bf..000000000 --- a/Examples/test-suite/go/arrayref.go +++ /dev/null @@ -1,61 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../arrayref.i - -package arrayref - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -var _wrap_foo unsafe.Pointer - -func _swig_wrap_foo(base **int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_foo, _swig_p) - return -} - -func Foo(arg1 **int) { - _swig_wrap_foo(arg1) -} - -var _wrap_bar unsafe.Pointer - -func _swig_wrap_bar(base **int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_bar, _swig_p) - return -} - -func Bar(arg1 **int) { - _swig_wrap_bar(arg1) -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/arrays.go b/Examples/test-suite/go/arrays.go deleted file mode 100644 index 5e3bcb55e..000000000 --- a/Examples/test-suite/go/arrays.go +++ /dev/null @@ -1,750 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../arrays.i - -package arrays - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -const ARRAY_LEN int = 2 -type Finger int -var _wrap_One unsafe.Pointer - -func _swig_getOne() (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_One, _swig_p) - return -} -var One int = _swig_getOne() -var _wrap_Two unsafe.Pointer - -func _swig_getTwo() (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_Two, _swig_p) - return -} -var Two int = _swig_getTwo() -var _wrap_Three unsafe.Pointer - -func _swig_getThree() (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_Three, _swig_p) - return -} -var Three int = _swig_getThree() -var _wrap_Four unsafe.Pointer - -func _swig_getFour() (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_Four, _swig_p) - return -} -var Four int = _swig_getFour() -var _wrap_Five unsafe.Pointer - -func _swig_getFive() (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_Five, _swig_p) - return -} -var Five int = _swig_getFive() -type SwigcptrSimpleStruct uintptr - -func (p SwigcptrSimpleStruct) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrSimpleStruct) SwigIsSimpleStruct() { -} - -var _wrap_SimpleStruct_double_field_set unsafe.Pointer - -func _swig_wrap_SimpleStruct_double_field_set(base SwigcptrSimpleStruct, _ float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_SimpleStruct_double_field_set, _swig_p) - return -} - -func (arg1 SwigcptrSimpleStruct) SetDouble_field(arg2 float64) { - _swig_wrap_SimpleStruct_double_field_set(arg1, arg2) -} - -var _wrap_SimpleStruct_double_field_get unsafe.Pointer - -func _swig_wrap_SimpleStruct_double_field_get(base SwigcptrSimpleStruct) (_ float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_SimpleStruct_double_field_get, _swig_p) - return -} - -func (arg1 SwigcptrSimpleStruct) GetDouble_field() (_swig_ret float64) { - return _swig_wrap_SimpleStruct_double_field_get(arg1) -} - -var _wrap_new_SimpleStruct unsafe.Pointer - -func _swig_wrap_new_SimpleStruct() (base SwigcptrSimpleStruct) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_SimpleStruct, _swig_p) - return -} - -func NewSimpleStruct() (_swig_ret SimpleStruct) { - return _swig_wrap_new_SimpleStruct() -} - -var _wrap_delete_SimpleStruct unsafe.Pointer - -func _swig_wrap_delete_SimpleStruct(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_SimpleStruct, _swig_p) - return -} - -func DeleteSimpleStruct(arg1 SimpleStruct) { - _swig_wrap_delete_SimpleStruct(arg1.Swigcptr()) -} - -type SimpleStruct interface { - Swigcptr() uintptr - SwigIsSimpleStruct() - SetDouble_field(arg2 float64) - GetDouble_field() (_swig_ret float64) -} - -type SwigcptrArrayStruct uintptr - -func (p SwigcptrArrayStruct) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrArrayStruct) SwigIsArrayStruct() { -} - -var _wrap_ArrayStruct_array_c_set unsafe.Pointer - -func _swig_wrap_ArrayStruct_array_c_set(base SwigcptrArrayStruct, _ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_ArrayStruct_array_c_set, _swig_p) - return -} - -func (arg1 SwigcptrArrayStruct) SetArray_c(arg2 string) { - _swig_wrap_ArrayStruct_array_c_set(arg1, arg2) -} - -var _wrap_ArrayStruct_array_c_get unsafe.Pointer - -func _swig_wrap_ArrayStruct_array_c_get(base SwigcptrArrayStruct) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_ArrayStruct_array_c_get, _swig_p) - return -} - -func (arg1 SwigcptrArrayStruct) GetArray_c() (_swig_ret string) { - return _swig_wrap_ArrayStruct_array_c_get(arg1) -} - -var _wrap_ArrayStruct_array_sc_set unsafe.Pointer - -func _swig_wrap_ArrayStruct_array_sc_set(base SwigcptrArrayStruct, _ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_ArrayStruct_array_sc_set, _swig_p) - return -} - -func (arg1 SwigcptrArrayStruct) SetArray_sc(arg2 string) { - _swig_wrap_ArrayStruct_array_sc_set(arg1, arg2) -} - -var _wrap_ArrayStruct_array_sc_get unsafe.Pointer - -func _swig_wrap_ArrayStruct_array_sc_get(base SwigcptrArrayStruct) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_ArrayStruct_array_sc_get, _swig_p) - return -} - -func (arg1 SwigcptrArrayStruct) GetArray_sc() (_swig_ret string) { - return _swig_wrap_ArrayStruct_array_sc_get(arg1) -} - -var _wrap_ArrayStruct_array_uc_set unsafe.Pointer - -func _swig_wrap_ArrayStruct_array_uc_set(base SwigcptrArrayStruct, _ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_ArrayStruct_array_uc_set, _swig_p) - return -} - -func (arg1 SwigcptrArrayStruct) SetArray_uc(arg2 string) { - _swig_wrap_ArrayStruct_array_uc_set(arg1, arg2) -} - -var _wrap_ArrayStruct_array_uc_get unsafe.Pointer - -func _swig_wrap_ArrayStruct_array_uc_get(base SwigcptrArrayStruct) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_ArrayStruct_array_uc_get, _swig_p) - return -} - -func (arg1 SwigcptrArrayStruct) GetArray_uc() (_swig_ret string) { - return _swig_wrap_ArrayStruct_array_uc_get(arg1) -} - -var _wrap_ArrayStruct_array_s_set unsafe.Pointer - -func _swig_wrap_ArrayStruct_array_s_set(base SwigcptrArrayStruct, _ *int16) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_ArrayStruct_array_s_set, _swig_p) - return -} - -func (arg1 SwigcptrArrayStruct) SetArray_s(arg2 *int16) { - _swig_wrap_ArrayStruct_array_s_set(arg1, arg2) -} - -var _wrap_ArrayStruct_array_s_get unsafe.Pointer - -func _swig_wrap_ArrayStruct_array_s_get(base SwigcptrArrayStruct) (_ *int16) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_ArrayStruct_array_s_get, _swig_p) - return -} - -func (arg1 SwigcptrArrayStruct) GetArray_s() (_swig_ret *int16) { - return _swig_wrap_ArrayStruct_array_s_get(arg1) -} - -var _wrap_ArrayStruct_array_us_set unsafe.Pointer - -func _swig_wrap_ArrayStruct_array_us_set(base SwigcptrArrayStruct, _ *uint16) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_ArrayStruct_array_us_set, _swig_p) - return -} - -func (arg1 SwigcptrArrayStruct) SetArray_us(arg2 *uint16) { - _swig_wrap_ArrayStruct_array_us_set(arg1, arg2) -} - -var _wrap_ArrayStruct_array_us_get unsafe.Pointer - -func _swig_wrap_ArrayStruct_array_us_get(base SwigcptrArrayStruct) (_ *uint16) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_ArrayStruct_array_us_get, _swig_p) - return -} - -func (arg1 SwigcptrArrayStruct) GetArray_us() (_swig_ret *uint16) { - return _swig_wrap_ArrayStruct_array_us_get(arg1) -} - -var _wrap_ArrayStruct_array_i_set unsafe.Pointer - -func _swig_wrap_ArrayStruct_array_i_set(base SwigcptrArrayStruct, _ *int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_ArrayStruct_array_i_set, _swig_p) - return -} - -func (arg1 SwigcptrArrayStruct) SetArray_i(arg2 *int) { - _swig_wrap_ArrayStruct_array_i_set(arg1, arg2) -} - -var _wrap_ArrayStruct_array_i_get unsafe.Pointer - -func _swig_wrap_ArrayStruct_array_i_get(base SwigcptrArrayStruct) (_ *int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_ArrayStruct_array_i_get, _swig_p) - return -} - -func (arg1 SwigcptrArrayStruct) GetArray_i() (_swig_ret *int) { - return _swig_wrap_ArrayStruct_array_i_get(arg1) -} - -var _wrap_ArrayStruct_array_ui_set unsafe.Pointer - -func _swig_wrap_ArrayStruct_array_ui_set(base SwigcptrArrayStruct, _ *uint) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_ArrayStruct_array_ui_set, _swig_p) - return -} - -func (arg1 SwigcptrArrayStruct) SetArray_ui(arg2 *uint) { - _swig_wrap_ArrayStruct_array_ui_set(arg1, arg2) -} - -var _wrap_ArrayStruct_array_ui_get unsafe.Pointer - -func _swig_wrap_ArrayStruct_array_ui_get(base SwigcptrArrayStruct) (_ *uint) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_ArrayStruct_array_ui_get, _swig_p) - return -} - -func (arg1 SwigcptrArrayStruct) GetArray_ui() (_swig_ret *uint) { - return _swig_wrap_ArrayStruct_array_ui_get(arg1) -} - -var _wrap_ArrayStruct_array_l_set unsafe.Pointer - -func _swig_wrap_ArrayStruct_array_l_set(base SwigcptrArrayStruct, _ *int64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_ArrayStruct_array_l_set, _swig_p) - return -} - -func (arg1 SwigcptrArrayStruct) SetArray_l(arg2 *int64) { - _swig_wrap_ArrayStruct_array_l_set(arg1, arg2) -} - -var _wrap_ArrayStruct_array_l_get unsafe.Pointer - -func _swig_wrap_ArrayStruct_array_l_get(base SwigcptrArrayStruct) (_ *int64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_ArrayStruct_array_l_get, _swig_p) - return -} - -func (arg1 SwigcptrArrayStruct) GetArray_l() (_swig_ret *int64) { - return _swig_wrap_ArrayStruct_array_l_get(arg1) -} - -var _wrap_ArrayStruct_array_ul_set unsafe.Pointer - -func _swig_wrap_ArrayStruct_array_ul_set(base SwigcptrArrayStruct, _ *uint64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_ArrayStruct_array_ul_set, _swig_p) - return -} - -func (arg1 SwigcptrArrayStruct) SetArray_ul(arg2 *uint64) { - _swig_wrap_ArrayStruct_array_ul_set(arg1, arg2) -} - -var _wrap_ArrayStruct_array_ul_get unsafe.Pointer - -func _swig_wrap_ArrayStruct_array_ul_get(base SwigcptrArrayStruct) (_ *uint64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_ArrayStruct_array_ul_get, _swig_p) - return -} - -func (arg1 SwigcptrArrayStruct) GetArray_ul() (_swig_ret *uint64) { - return _swig_wrap_ArrayStruct_array_ul_get(arg1) -} - -var _wrap_ArrayStruct_array_ll_set unsafe.Pointer - -func _swig_wrap_ArrayStruct_array_ll_set(base SwigcptrArrayStruct, _ *int64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_ArrayStruct_array_ll_set, _swig_p) - return -} - -func (arg1 SwigcptrArrayStruct) SetArray_ll(arg2 *int64) { - _swig_wrap_ArrayStruct_array_ll_set(arg1, arg2) -} - -var _wrap_ArrayStruct_array_ll_get unsafe.Pointer - -func _swig_wrap_ArrayStruct_array_ll_get(base SwigcptrArrayStruct) (_ *int64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_ArrayStruct_array_ll_get, _swig_p) - return -} - -func (arg1 SwigcptrArrayStruct) GetArray_ll() (_swig_ret *int64) { - return _swig_wrap_ArrayStruct_array_ll_get(arg1) -} - -var _wrap_ArrayStruct_array_f_set unsafe.Pointer - -func _swig_wrap_ArrayStruct_array_f_set(base SwigcptrArrayStruct, _ *float32) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_ArrayStruct_array_f_set, _swig_p) - return -} - -func (arg1 SwigcptrArrayStruct) SetArray_f(arg2 *float32) { - _swig_wrap_ArrayStruct_array_f_set(arg1, arg2) -} - -var _wrap_ArrayStruct_array_f_get unsafe.Pointer - -func _swig_wrap_ArrayStruct_array_f_get(base SwigcptrArrayStruct) (_ *float32) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_ArrayStruct_array_f_get, _swig_p) - return -} - -func (arg1 SwigcptrArrayStruct) GetArray_f() (_swig_ret *float32) { - return _swig_wrap_ArrayStruct_array_f_get(arg1) -} - -var _wrap_ArrayStruct_array_d_set unsafe.Pointer - -func _swig_wrap_ArrayStruct_array_d_set(base SwigcptrArrayStruct, _ *float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_ArrayStruct_array_d_set, _swig_p) - return -} - -func (arg1 SwigcptrArrayStruct) SetArray_d(arg2 *float64) { - _swig_wrap_ArrayStruct_array_d_set(arg1, arg2) -} - -var _wrap_ArrayStruct_array_d_get unsafe.Pointer - -func _swig_wrap_ArrayStruct_array_d_get(base SwigcptrArrayStruct) (_ *float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_ArrayStruct_array_d_get, _swig_p) - return -} - -func (arg1 SwigcptrArrayStruct) GetArray_d() (_swig_ret *float64) { - return _swig_wrap_ArrayStruct_array_d_get(arg1) -} - -var _wrap_ArrayStruct_array_struct_set unsafe.Pointer - -func _swig_wrap_ArrayStruct_array_struct_set(base SwigcptrArrayStruct, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_ArrayStruct_array_struct_set, _swig_p) - return -} - -func (arg1 SwigcptrArrayStruct) SetArray_struct(arg2 SimpleStruct) { - _swig_wrap_ArrayStruct_array_struct_set(arg1, arg2.Swigcptr()) -} - -var _wrap_ArrayStruct_array_struct_get unsafe.Pointer - -func _swig_wrap_ArrayStruct_array_struct_get(base SwigcptrArrayStruct) (_ SwigcptrSimpleStruct) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_ArrayStruct_array_struct_get, _swig_p) - return -} - -func (arg1 SwigcptrArrayStruct) GetArray_struct() (_swig_ret SimpleStruct) { - return _swig_wrap_ArrayStruct_array_struct_get(arg1) -} - -var _wrap_ArrayStruct_array_structpointers_set unsafe.Pointer - -func _swig_wrap_ArrayStruct_array_structpointers_set(base SwigcptrArrayStruct, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_ArrayStruct_array_structpointers_set, _swig_p) - return -} - -func (arg1 SwigcptrArrayStruct) SetArray_structpointers(arg2 SimpleStruct) { - _swig_wrap_ArrayStruct_array_structpointers_set(arg1, arg2.Swigcptr()) -} - -var _wrap_ArrayStruct_array_structpointers_get unsafe.Pointer - -func _swig_wrap_ArrayStruct_array_structpointers_get(base SwigcptrArrayStruct) (_ SwigcptrSimpleStruct) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_ArrayStruct_array_structpointers_get, _swig_p) - return -} - -func (arg1 SwigcptrArrayStruct) GetArray_structpointers() (_swig_ret SimpleStruct) { - return _swig_wrap_ArrayStruct_array_structpointers_get(arg1) -} - -var _wrap_ArrayStruct_array_ipointers_set unsafe.Pointer - -func _swig_wrap_ArrayStruct_array_ipointers_set(base SwigcptrArrayStruct, _ **int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_ArrayStruct_array_ipointers_set, _swig_p) - return -} - -func (arg1 SwigcptrArrayStruct) SetArray_ipointers(arg2 **int) { - _swig_wrap_ArrayStruct_array_ipointers_set(arg1, arg2) -} - -var _wrap_ArrayStruct_array_ipointers_get unsafe.Pointer - -func _swig_wrap_ArrayStruct_array_ipointers_get(base SwigcptrArrayStruct) (_ **int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_ArrayStruct_array_ipointers_get, _swig_p) - return -} - -func (arg1 SwigcptrArrayStruct) GetArray_ipointers() (_swig_ret **int) { - return _swig_wrap_ArrayStruct_array_ipointers_get(arg1) -} - -var _wrap_ArrayStruct_array_enum_set unsafe.Pointer - -func _swig_wrap_ArrayStruct_array_enum_set(base SwigcptrArrayStruct, _ *Finger) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_ArrayStruct_array_enum_set, _swig_p) - return -} - -func (arg1 SwigcptrArrayStruct) SetArray_enum(arg2 *Finger) { - _swig_wrap_ArrayStruct_array_enum_set(arg1, arg2) -} - -var _wrap_ArrayStruct_array_enum_get unsafe.Pointer - -func _swig_wrap_ArrayStruct_array_enum_get(base SwigcptrArrayStruct) (_ *Finger) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_ArrayStruct_array_enum_get, _swig_p) - return -} - -func (arg1 SwigcptrArrayStruct) GetArray_enum() (_swig_ret *Finger) { - return _swig_wrap_ArrayStruct_array_enum_get(arg1) -} - -var _wrap_ArrayStruct_array_enumpointers_set unsafe.Pointer - -func _swig_wrap_ArrayStruct_array_enumpointers_set(base SwigcptrArrayStruct, _ **Finger) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_ArrayStruct_array_enumpointers_set, _swig_p) - return -} - -func (arg1 SwigcptrArrayStruct) SetArray_enumpointers(arg2 **Finger) { - _swig_wrap_ArrayStruct_array_enumpointers_set(arg1, arg2) -} - -var _wrap_ArrayStruct_array_enumpointers_get unsafe.Pointer - -func _swig_wrap_ArrayStruct_array_enumpointers_get(base SwigcptrArrayStruct) (_ **Finger) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_ArrayStruct_array_enumpointers_get, _swig_p) - return -} - -func (arg1 SwigcptrArrayStruct) GetArray_enumpointers() (_swig_ret **Finger) { - return _swig_wrap_ArrayStruct_array_enumpointers_get(arg1) -} - -var _wrap_ArrayStruct_array_const_i_get unsafe.Pointer - -func _swig_wrap_ArrayStruct_array_const_i_get(base SwigcptrArrayStruct) (_ *int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_ArrayStruct_array_const_i_get, _swig_p) - return -} - -func (arg1 SwigcptrArrayStruct) GetArray_const_i() (_swig_ret *int) { - return _swig_wrap_ArrayStruct_array_const_i_get(arg1) -} - -var _wrap_new_ArrayStruct unsafe.Pointer - -func _swig_wrap_new_ArrayStruct() (base SwigcptrArrayStruct) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_ArrayStruct, _swig_p) - return -} - -func NewArrayStruct() (_swig_ret ArrayStruct) { - return _swig_wrap_new_ArrayStruct() -} - -var _wrap_delete_ArrayStruct unsafe.Pointer - -func _swig_wrap_delete_ArrayStruct(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_ArrayStruct, _swig_p) - return -} - -func DeleteArrayStruct(arg1 ArrayStruct) { - _swig_wrap_delete_ArrayStruct(arg1.Swigcptr()) -} - -type ArrayStruct interface { - Swigcptr() uintptr - SwigIsArrayStruct() - SetArray_c(arg2 string) - GetArray_c() (_swig_ret string) - SetArray_sc(arg2 string) - GetArray_sc() (_swig_ret string) - SetArray_uc(arg2 string) - GetArray_uc() (_swig_ret string) - SetArray_s(arg2 *int16) - GetArray_s() (_swig_ret *int16) - SetArray_us(arg2 *uint16) - GetArray_us() (_swig_ret *uint16) - SetArray_i(arg2 *int) - GetArray_i() (_swig_ret *int) - SetArray_ui(arg2 *uint) - GetArray_ui() (_swig_ret *uint) - SetArray_l(arg2 *int64) - GetArray_l() (_swig_ret *int64) - SetArray_ul(arg2 *uint64) - GetArray_ul() (_swig_ret *uint64) - SetArray_ll(arg2 *int64) - GetArray_ll() (_swig_ret *int64) - SetArray_f(arg2 *float32) - GetArray_f() (_swig_ret *float32) - SetArray_d(arg2 *float64) - GetArray_d() (_swig_ret *float64) - SetArray_struct(arg2 SimpleStruct) - GetArray_struct() (_swig_ret SimpleStruct) - SetArray_structpointers(arg2 SimpleStruct) - GetArray_structpointers() (_swig_ret SimpleStruct) - SetArray_ipointers(arg2 **int) - GetArray_ipointers() (_swig_ret **int) - SetArray_enum(arg2 *Finger) - GetArray_enum() (_swig_ret *Finger) - SetArray_enumpointers(arg2 **Finger) - GetArray_enumpointers() (_swig_ret **Finger) - GetArray_const_i() (_swig_ret *int) -} - -var _wrap_fn_taking_arrays unsafe.Pointer - -func _swig_wrap_fn_taking_arrays(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_fn_taking_arrays, _swig_p) - return -} - -func Fn_taking_arrays(arg1 SimpleStruct) { - _swig_wrap_fn_taking_arrays(arg1.Swigcptr()) -} - -var _wrap_newintpointer unsafe.Pointer - -func Newintpointer() (_swig_ret *int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_newintpointer, _swig_p) - return -} -var _wrap_setintfrompointer unsafe.Pointer - -func _swig_wrap_setintfrompointer(base *int, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_setintfrompointer, _swig_p) - return -} - -func Setintfrompointer(arg1 *int, arg2 int) { - _swig_wrap_setintfrompointer(arg1, arg2) -} - -var _wrap_getintfrompointer unsafe.Pointer - -func Getintfrompointer(arg1 *int) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_getintfrompointer, _swig_p) - return -} -var _wrap_array_pointer_func unsafe.Pointer - -func _swig_wrap_array_pointer_func(base **int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_array_pointer_func, _swig_p) - return -} - -func Array_pointer_func(arg1 **int) { - _swig_wrap_array_pointer_func(arg1) -} - -type SwigcptrCartPoseData_t uintptr - -func (p SwigcptrCartPoseData_t) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrCartPoseData_t) SwigIsCartPoseData_t() { -} - -var _wrap_CartPoseData_t_p_set unsafe.Pointer - -func _swig_wrap_CartPoseData_t_p_set(base SwigcptrCartPoseData_t, _ *float32) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_CartPoseData_t_p_set, _swig_p) - return -} - -func (arg1 SwigcptrCartPoseData_t) SetP(arg2 *float32) { - _swig_wrap_CartPoseData_t_p_set(arg1, arg2) -} - -var _wrap_CartPoseData_t_p_get unsafe.Pointer - -func _swig_wrap_CartPoseData_t_p_get(base SwigcptrCartPoseData_t) (_ *float32) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_CartPoseData_t_p_get, _swig_p) - return -} - -func (arg1 SwigcptrCartPoseData_t) GetP() (_swig_ret *float32) { - return _swig_wrap_CartPoseData_t_p_get(arg1) -} - -var _wrap_new_CartPoseData_t unsafe.Pointer - -func _swig_wrap_new_CartPoseData_t() (base SwigcptrCartPoseData_t) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_CartPoseData_t, _swig_p) - return -} - -func NewCartPoseData_t() (_swig_ret CartPoseData_t) { - return _swig_wrap_new_CartPoseData_t() -} - -var _wrap_delete_CartPoseData_t unsafe.Pointer - -func _swig_wrap_delete_CartPoseData_t(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_CartPoseData_t, _swig_p) - return -} - -func DeleteCartPoseData_t(arg1 CartPoseData_t) { - _swig_wrap_delete_CartPoseData_t(arg1.Swigcptr()) -} - -type CartPoseData_t interface { - Swigcptr() uintptr - SwigIsCartPoseData_t() - SetP(arg2 *float32) - GetP() (_swig_ret *float32) -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/arrays_dimensionless.go b/Examples/test-suite/go/arrays_dimensionless.go deleted file mode 100644 index afaebec48..000000000 --- a/Examples/test-suite/go/arrays_dimensionless.go +++ /dev/null @@ -1,292 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../arrays_dimensionless.i - -package arrays_dimensionless - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -var _wrap_globalints_get unsafe.Pointer - -func GetGlobalints() (_swig_ret *int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_globalints_get, _swig_p) - return -} -var _wrap_constglobalints_get unsafe.Pointer - -func GetConstglobalints() (_swig_ret *int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_constglobalints_get, _swig_p) - return -} -type SwigcptrBar uintptr - -func (p SwigcptrBar) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrBar) SwigIsBar() { -} - -var _wrap_Bar_ints_get unsafe.Pointer - -func GetBarInts() (_swig_ret *int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_Bar_ints_get, _swig_p) - return -} -var _wrap_new_Bar unsafe.Pointer - -func _swig_wrap_new_Bar() (base SwigcptrBar) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Bar, _swig_p) - return -} - -func NewBar() (_swig_ret Bar) { - return _swig_wrap_new_Bar() -} - -var _wrap_delete_Bar unsafe.Pointer - -func _swig_wrap_delete_Bar(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Bar, _swig_p) - return -} - -func DeleteBar(arg1 Bar) { - _swig_wrap_delete_Bar(arg1.Swigcptr()) -} - -type Bar interface { - Swigcptr() uintptr - SwigIsBar() -} - -var _wrap_arr_bool unsafe.Pointer - -func Arr_bool(arg1 *bool, arg2 int) (_swig_ret float64) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_arr_bool, _swig_p) - return -} -var _wrap_arr_char unsafe.Pointer - -func Arr_char(arg1 string, arg2 int) (_swig_ret float64) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_arr_char, _swig_p) - return -} -var _wrap_arr_schar unsafe.Pointer - -func Arr_schar(arg1 string, arg2 int) (_swig_ret float64) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_arr_schar, _swig_p) - return -} -var _wrap_arr_uchar unsafe.Pointer - -func Arr_uchar(arg1 string, arg2 int) (_swig_ret float64) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_arr_uchar, _swig_p) - return -} -var _wrap_arr_short unsafe.Pointer - -func Arr_short(arg1 *int16, arg2 int) (_swig_ret float64) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_arr_short, _swig_p) - return -} -var _wrap_arr_ushort unsafe.Pointer - -func Arr_ushort(arg1 *uint16, arg2 int) (_swig_ret float64) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_arr_ushort, _swig_p) - return -} -var _wrap_arr_int unsafe.Pointer - -func Arr_int(arg1 *int, arg2 int) (_swig_ret float64) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_arr_int, _swig_p) - return -} -var _wrap_arr_uint unsafe.Pointer - -func Arr_uint(arg1 *uint, arg2 int) (_swig_ret float64) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_arr_uint, _swig_p) - return -} -var _wrap_arr_long unsafe.Pointer - -func Arr_long(arg1 *int64, arg2 int) (_swig_ret float64) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_arr_long, _swig_p) - return -} -var _wrap_arr_ulong unsafe.Pointer - -func Arr_ulong(arg1 *uint64, arg2 int) (_swig_ret float64) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_arr_ulong, _swig_p) - return -} -var _wrap_arr_ll unsafe.Pointer - -func Arr_ll(arg1 *int64, arg2 int) (_swig_ret float64) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_arr_ll, _swig_p) - return -} -var _wrap_arr_ull unsafe.Pointer - -func Arr_ull(arg1 *uint64, arg2 int) (_swig_ret float64) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_arr_ull, _swig_p) - return -} -var _wrap_arr_float unsafe.Pointer - -func Arr_float(arg1 *float32, arg2 int) (_swig_ret float64) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_arr_float, _swig_p) - return -} -var _wrap_arr_double unsafe.Pointer - -func Arr_double(arg1 *float64, arg2 int) (_swig_ret float64) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_arr_double, _swig_p) - return -} -var _wrap_ptr_bool unsafe.Pointer - -func Ptr_bool(arg1 *bool, arg2 int) (_swig_ret float64) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_ptr_bool, _swig_p) - return -} -var _wrap_ptr_char unsafe.Pointer - -func Ptr_char(arg1 *byte, arg2 int) (_swig_ret float64) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_ptr_char, _swig_p) - return -} -var _wrap_ptr_schar unsafe.Pointer - -func Ptr_schar(arg1 *int8, arg2 int) (_swig_ret float64) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_ptr_schar, _swig_p) - return -} -var _wrap_ptr_uchar unsafe.Pointer - -func Ptr_uchar(arg1 *byte, arg2 int) (_swig_ret float64) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_ptr_uchar, _swig_p) - return -} -var _wrap_ptr_short unsafe.Pointer - -func Ptr_short(arg1 *int16, arg2 int) (_swig_ret float64) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_ptr_short, _swig_p) - return -} -var _wrap_ptr_ushort unsafe.Pointer - -func Ptr_ushort(arg1 *uint16, arg2 int) (_swig_ret float64) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_ptr_ushort, _swig_p) - return -} -var _wrap_ptr_int unsafe.Pointer - -func Ptr_int(arg1 *int, arg2 int) (_swig_ret float64) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_ptr_int, _swig_p) - return -} -var _wrap_ptr_uint unsafe.Pointer - -func Ptr_uint(arg1 *uint, arg2 int) (_swig_ret float64) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_ptr_uint, _swig_p) - return -} -var _wrap_ptr_long unsafe.Pointer - -func Ptr_long(arg1 *int64, arg2 int) (_swig_ret float64) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_ptr_long, _swig_p) - return -} -var _wrap_ptr_ulong unsafe.Pointer - -func Ptr_ulong(arg1 *uint64, arg2 int) (_swig_ret float64) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_ptr_ulong, _swig_p) - return -} -var _wrap_ptr_ll unsafe.Pointer - -func Ptr_ll(arg1 *int64, arg2 int) (_swig_ret float64) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_ptr_ll, _swig_p) - return -} -var _wrap_ptr_ull unsafe.Pointer - -func Ptr_ull(arg1 *uint64, arg2 int) (_swig_ret float64) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_ptr_ull, _swig_p) - return -} -var _wrap_ptr_float unsafe.Pointer - -func Ptr_float(arg1 *float32, arg2 int) (_swig_ret float64) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_ptr_float, _swig_p) - return -} -var _wrap_ptr_double unsafe.Pointer - -func Ptr_double(arg1 *float64, arg2 int) (_swig_ret float64) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_ptr_double, _swig_p) - return -} - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/arrays_global.go b/Examples/test-suite/go/arrays_global.go deleted file mode 100644 index 08b583b8f..000000000 --- a/Examples/test-suite/go/arrays_global.go +++ /dev/null @@ -1,729 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../arrays_global.i - -package arrays_global - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -const ARRAY_LEN int = 2 -type Finger int -var _wrap_One unsafe.Pointer - -func _swig_getOne() (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_One, _swig_p) - return -} -var One int = _swig_getOne() -var _wrap_Two unsafe.Pointer - -func _swig_getTwo() (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_Two, _swig_p) - return -} -var Two int = _swig_getTwo() -var _wrap_Three unsafe.Pointer - -func _swig_getThree() (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_Three, _swig_p) - return -} -var Three int = _swig_getThree() -var _wrap_Four unsafe.Pointer - -func _swig_getFour() (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_Four, _swig_p) - return -} -var Four int = _swig_getFour() -var _wrap_Five unsafe.Pointer - -func _swig_getFive() (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_Five, _swig_p) - return -} -var Five int = _swig_getFive() -type SwigcptrSimpleStruct uintptr - -func (p SwigcptrSimpleStruct) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrSimpleStruct) SwigIsSimpleStruct() { -} - -var _wrap_SimpleStruct_double_field_set unsafe.Pointer - -func _swig_wrap_SimpleStruct_double_field_set(base SwigcptrSimpleStruct, _ float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_SimpleStruct_double_field_set, _swig_p) - return -} - -func (arg1 SwigcptrSimpleStruct) SetDouble_field(arg2 float64) { - _swig_wrap_SimpleStruct_double_field_set(arg1, arg2) -} - -var _wrap_SimpleStruct_double_field_get unsafe.Pointer - -func _swig_wrap_SimpleStruct_double_field_get(base SwigcptrSimpleStruct) (_ float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_SimpleStruct_double_field_get, _swig_p) - return -} - -func (arg1 SwigcptrSimpleStruct) GetDouble_field() (_swig_ret float64) { - return _swig_wrap_SimpleStruct_double_field_get(arg1) -} - -var _wrap_new_SimpleStruct unsafe.Pointer - -func _swig_wrap_new_SimpleStruct() (base SwigcptrSimpleStruct) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_SimpleStruct, _swig_p) - return -} - -func NewSimpleStruct() (_swig_ret SimpleStruct) { - return _swig_wrap_new_SimpleStruct() -} - -var _wrap_delete_SimpleStruct unsafe.Pointer - -func _swig_wrap_delete_SimpleStruct(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_SimpleStruct, _swig_p) - return -} - -func DeleteSimpleStruct(arg1 SimpleStruct) { - _swig_wrap_delete_SimpleStruct(arg1.Swigcptr()) -} - -type SimpleStruct interface { - Swigcptr() uintptr - SwigIsSimpleStruct() - SetDouble_field(arg2 float64) - GetDouble_field() (_swig_ret float64) -} - -var _wrap_array_c_set unsafe.Pointer - -func _swig_wrap_array_c_set(base string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_array_c_set, _swig_p) - return -} - -func SetArray_c(arg1 string) { - _swig_wrap_array_c_set(arg1) -} - -var _wrap_array_c_get unsafe.Pointer - -func GetArray_c() (_swig_ret string) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_array_c_get, _swig_p) - return -} -var _wrap_array_sc_set unsafe.Pointer - -func _swig_wrap_array_sc_set(base string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_array_sc_set, _swig_p) - return -} - -func SetArray_sc(arg1 string) { - _swig_wrap_array_sc_set(arg1) -} - -var _wrap_array_sc_get unsafe.Pointer - -func GetArray_sc() (_swig_ret string) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_array_sc_get, _swig_p) - return -} -var _wrap_array_uc_set unsafe.Pointer - -func _swig_wrap_array_uc_set(base string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_array_uc_set, _swig_p) - return -} - -func SetArray_uc(arg1 string) { - _swig_wrap_array_uc_set(arg1) -} - -var _wrap_array_uc_get unsafe.Pointer - -func GetArray_uc() (_swig_ret string) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_array_uc_get, _swig_p) - return -} -var _wrap_array_s_set unsafe.Pointer - -func _swig_wrap_array_s_set(base *int16) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_array_s_set, _swig_p) - return -} - -func SetArray_s(arg1 *int16) { - _swig_wrap_array_s_set(arg1) -} - -var _wrap_array_s_get unsafe.Pointer - -func GetArray_s() (_swig_ret *int16) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_array_s_get, _swig_p) - return -} -var _wrap_array_us_set unsafe.Pointer - -func _swig_wrap_array_us_set(base *uint16) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_array_us_set, _swig_p) - return -} - -func SetArray_us(arg1 *uint16) { - _swig_wrap_array_us_set(arg1) -} - -var _wrap_array_us_get unsafe.Pointer - -func GetArray_us() (_swig_ret *uint16) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_array_us_get, _swig_p) - return -} -var _wrap_array_i_set unsafe.Pointer - -func _swig_wrap_array_i_set(base *int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_array_i_set, _swig_p) - return -} - -func SetArray_i(arg1 *int) { - _swig_wrap_array_i_set(arg1) -} - -var _wrap_array_i_get unsafe.Pointer - -func GetArray_i() (_swig_ret *int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_array_i_get, _swig_p) - return -} -var _wrap_array_ui_set unsafe.Pointer - -func _swig_wrap_array_ui_set(base *uint) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_array_ui_set, _swig_p) - return -} - -func SetArray_ui(arg1 *uint) { - _swig_wrap_array_ui_set(arg1) -} - -var _wrap_array_ui_get unsafe.Pointer - -func GetArray_ui() (_swig_ret *uint) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_array_ui_get, _swig_p) - return -} -var _wrap_array_l_set unsafe.Pointer - -func _swig_wrap_array_l_set(base *int64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_array_l_set, _swig_p) - return -} - -func SetArray_l(arg1 *int64) { - _swig_wrap_array_l_set(arg1) -} - -var _wrap_array_l_get unsafe.Pointer - -func GetArray_l() (_swig_ret *int64) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_array_l_get, _swig_p) - return -} -var _wrap_array_ul_set unsafe.Pointer - -func _swig_wrap_array_ul_set(base *uint64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_array_ul_set, _swig_p) - return -} - -func SetArray_ul(arg1 *uint64) { - _swig_wrap_array_ul_set(arg1) -} - -var _wrap_array_ul_get unsafe.Pointer - -func GetArray_ul() (_swig_ret *uint64) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_array_ul_get, _swig_p) - return -} -var _wrap_array_ll_set unsafe.Pointer - -func _swig_wrap_array_ll_set(base *int64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_array_ll_set, _swig_p) - return -} - -func SetArray_ll(arg1 *int64) { - _swig_wrap_array_ll_set(arg1) -} - -var _wrap_array_ll_get unsafe.Pointer - -func GetArray_ll() (_swig_ret *int64) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_array_ll_get, _swig_p) - return -} -var _wrap_array_f_set unsafe.Pointer - -func _swig_wrap_array_f_set(base *float32) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_array_f_set, _swig_p) - return -} - -func SetArray_f(arg1 *float32) { - _swig_wrap_array_f_set(arg1) -} - -var _wrap_array_f_get unsafe.Pointer - -func GetArray_f() (_swig_ret *float32) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_array_f_get, _swig_p) - return -} -var _wrap_array_d_set unsafe.Pointer - -func _swig_wrap_array_d_set(base *float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_array_d_set, _swig_p) - return -} - -func SetArray_d(arg1 *float64) { - _swig_wrap_array_d_set(arg1) -} - -var _wrap_array_d_get unsafe.Pointer - -func GetArray_d() (_swig_ret *float64) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_array_d_get, _swig_p) - return -} -var _wrap_array_struct_set unsafe.Pointer - -func _swig_wrap_array_struct_set(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_array_struct_set, _swig_p) - return -} - -func SetArray_struct(arg1 SimpleStruct) { - _swig_wrap_array_struct_set(arg1.Swigcptr()) -} - -var _wrap_array_struct_get unsafe.Pointer - -func _swig_wrap_array_struct_get() (base SwigcptrSimpleStruct) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_array_struct_get, _swig_p) - return -} - -func GetArray_struct() (_swig_ret SimpleStruct) { - return _swig_wrap_array_struct_get() -} - -var _wrap_array_structpointers_set unsafe.Pointer - -func _swig_wrap_array_structpointers_set(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_array_structpointers_set, _swig_p) - return -} - -func SetArray_structpointers(arg1 SimpleStruct) { - _swig_wrap_array_structpointers_set(arg1.Swigcptr()) -} - -var _wrap_array_structpointers_get unsafe.Pointer - -func _swig_wrap_array_structpointers_get() (base SwigcptrSimpleStruct) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_array_structpointers_get, _swig_p) - return -} - -func GetArray_structpointers() (_swig_ret SimpleStruct) { - return _swig_wrap_array_structpointers_get() -} - -var _wrap_array_ipointers_set unsafe.Pointer - -func _swig_wrap_array_ipointers_set(base **int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_array_ipointers_set, _swig_p) - return -} - -func SetArray_ipointers(arg1 **int) { - _swig_wrap_array_ipointers_set(arg1) -} - -var _wrap_array_ipointers_get unsafe.Pointer - -func GetArray_ipointers() (_swig_ret **int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_array_ipointers_get, _swig_p) - return -} -var _wrap_array_enum_set unsafe.Pointer - -func _swig_wrap_array_enum_set(base *Finger) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_array_enum_set, _swig_p) - return -} - -func SetArray_enum(arg1 *Finger) { - _swig_wrap_array_enum_set(arg1) -} - -var _wrap_array_enum_get unsafe.Pointer - -func GetArray_enum() (_swig_ret *Finger) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_array_enum_get, _swig_p) - return -} -var _wrap_array_enumpointers_set unsafe.Pointer - -func _swig_wrap_array_enumpointers_set(base **Finger) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_array_enumpointers_set, _swig_p) - return -} - -func SetArray_enumpointers(arg1 **Finger) { - _swig_wrap_array_enumpointers_set(arg1) -} - -var _wrap_array_enumpointers_get unsafe.Pointer - -func GetArray_enumpointers() (_swig_ret **Finger) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_array_enumpointers_get, _swig_p) - return -} -var _wrap_array_const_i_get unsafe.Pointer - -func GetArray_const_i() (_swig_ret *int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_array_const_i_get, _swig_p) - return -} -var _wrap_BeginString_FIX44a_get unsafe.Pointer - -func GetBeginString_FIX44a() (_swig_ret string) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_BeginString_FIX44a_get, _swig_p) - return -} -var _wrap_BeginString_FIX44b_set unsafe.Pointer - -func _swig_wrap_BeginString_FIX44b_set(base string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_BeginString_FIX44b_set, _swig_p) - return -} - -func SetBeginString_FIX44b(arg1 string) { - _swig_wrap_BeginString_FIX44b_set(arg1) -} - -var _wrap_BeginString_FIX44b_get unsafe.Pointer - -func GetBeginString_FIX44b() (_swig_ret string) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_BeginString_FIX44b_get, _swig_p) - return -} -var _wrap_BeginString_FIX44c_get unsafe.Pointer - -func GetBeginString_FIX44c() (_swig_ret string) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_BeginString_FIX44c_get, _swig_p) - return -} -var _wrap_BeginString_FIX44d_set unsafe.Pointer - -func _swig_wrap_BeginString_FIX44d_set(base string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_BeginString_FIX44d_set, _swig_p) - return -} - -func SetBeginString_FIX44d(arg1 string) { - _swig_wrap_BeginString_FIX44d_set(arg1) -} - -var _wrap_BeginString_FIX44d_get unsafe.Pointer - -func GetBeginString_FIX44d() (_swig_ret string) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_BeginString_FIX44d_get, _swig_p) - return -} -var _wrap_BeginString_FIX44e_set unsafe.Pointer - -func _swig_wrap_BeginString_FIX44e_set(base string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_BeginString_FIX44e_set, _swig_p) - return -} - -func SetBeginString_FIX44e(arg1 string) { - _swig_wrap_BeginString_FIX44e_set(arg1) -} - -var _wrap_BeginString_FIX44e_get unsafe.Pointer - -func GetBeginString_FIX44e() (_swig_ret string) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_BeginString_FIX44e_get, _swig_p) - return -} -var _wrap_BeginString_FIX44f_get unsafe.Pointer - -func GetBeginString_FIX44f() (_swig_ret string) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_BeginString_FIX44f_get, _swig_p) - return -} -var _wrap_test_a__SWIG_0 unsafe.Pointer - -func Test_a__SWIG_0(arg1 string, arg2 string, arg3 string, arg4 string) (_swig_ret string) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_test_a__SWIG_0, _swig_p) - return -} -var _wrap_test_b__SWIG_0 unsafe.Pointer - -func Test_b__SWIG_0(arg1 string, arg2 string) (_swig_ret string) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_test_b__SWIG_0, _swig_p) - return -} -var _wrap_test_a__SWIG_1 unsafe.Pointer - -func Test_a__SWIG_1(arg1 int) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_test_a__SWIG_1, _swig_p) - return -} -func Test_a(a ...interface{}) interface{} { - argc := len(a) - if argc == 1 { - return Test_a__SWIG_1(a[0].(int)) - } - if argc == 4 { - return Test_a__SWIG_0(a[0].(string), a[1].(string), a[2].(string), a[3].(string)) - } - panic("No match for overloaded function call") -} - -var _wrap_test_b__SWIG_1 unsafe.Pointer - -func Test_b__SWIG_1(arg1 int) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_test_b__SWIG_1, _swig_p) - return -} -func Test_b(a ...interface{}) interface{} { - argc := len(a) - if argc == 1 { - return Test_b__SWIG_1(a[0].(int)) - } - if argc == 2 { - return Test_b__SWIG_0(a[0].(string), a[1].(string)) - } - panic("No match for overloaded function call") -} - -type SwigcptrMaterial uintptr - -func (p SwigcptrMaterial) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrMaterial) SwigIsMaterial() { -} - -var _wrap_new_Material unsafe.Pointer - -func _swig_wrap_new_Material() (base SwigcptrMaterial) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Material, _swig_p) - return -} - -func NewMaterial() (_swig_ret Material) { - return _swig_wrap_new_Material() -} - -var _wrap_delete_Material unsafe.Pointer - -func _swig_wrap_delete_Material(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Material, _swig_p) - return -} - -func DeleteMaterial(arg1 Material) { - _swig_wrap_delete_Material(arg1.Swigcptr()) -} - -type Material interface { - Swigcptr() uintptr - SwigIsMaterial() -} - -var _wrap_Size unsafe.Pointer - -func _swig_getSize() (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_Size, _swig_p) - return -} -var Size int = _swig_getSize() -var _wrap_chitMat_set unsafe.Pointer - -func _swig_wrap_chitMat_set(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_chitMat_set, _swig_p) - return -} - -func SetChitMat(arg1 Material) { - _swig_wrap_chitMat_set(arg1.Swigcptr()) -} - -var _wrap_chitMat_get unsafe.Pointer - -func _swig_wrap_chitMat_get() (base SwigcptrMaterial) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_chitMat_get, _swig_p) - return -} - -func GetChitMat() (_swig_ret Material) { - return _swig_wrap_chitMat_get() -} - -var _wrap_hitMat_val_set unsafe.Pointer - -func _swig_wrap_hitMat_val_set(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_hitMat_val_set, _swig_p) - return -} - -func SetHitMat_val(arg1 Material) { - _swig_wrap_hitMat_val_set(arg1.Swigcptr()) -} - -var _wrap_hitMat_val_get unsafe.Pointer - -func _swig_wrap_hitMat_val_get() (base SwigcptrMaterial) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_hitMat_val_get, _swig_p) - return -} - -func GetHitMat_val() (_swig_ret Material) { - return _swig_wrap_hitMat_val_get() -} - -var _wrap_hitMat_set unsafe.Pointer - -func _swig_wrap_hitMat_set(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_hitMat_set, _swig_p) - return -} - -func SetHitMat(arg1 Material) { - _swig_wrap_hitMat_set(arg1.Swigcptr()) -} - -var _wrap_hitMat_get unsafe.Pointer - -func _swig_wrap_hitMat_get() (base SwigcptrMaterial) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_hitMat_get, _swig_p) - return -} - -func GetHitMat() (_swig_ret Material) { - return _swig_wrap_hitMat_get() -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/arrays_global_runme b/Examples/test-suite/go/arrays_global_runme deleted file mode 100755 index d9d05d80a..000000000 Binary files a/Examples/test-suite/go/arrays_global_runme and /dev/null differ diff --git a/Examples/test-suite/go/arrays_global_twodim.go b/Examples/test-suite/go/arrays_global_twodim.go deleted file mode 100644 index 858d2d43e..000000000 --- a/Examples/test-suite/go/arrays_global_twodim.go +++ /dev/null @@ -1,621 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../arrays_global_twodim.i - -package arrays_global_twodim - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -const ARRAY_LEN_X int = 2 -const ARRAY_LEN_Y int = 4 -type Finger int -var _wrap_One unsafe.Pointer - -func _swig_getOne() (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_One, _swig_p) - return -} -var One int = _swig_getOne() -var _wrap_Two unsafe.Pointer - -func _swig_getTwo() (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_Two, _swig_p) - return -} -var Two int = _swig_getTwo() -var _wrap_Three unsafe.Pointer - -func _swig_getThree() (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_Three, _swig_p) - return -} -var Three int = _swig_getThree() -var _wrap_Four unsafe.Pointer - -func _swig_getFour() (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_Four, _swig_p) - return -} -var Four int = _swig_getFour() -var _wrap_Five unsafe.Pointer - -func _swig_getFive() (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_Five, _swig_p) - return -} -var Five int = _swig_getFive() -type SwigcptrSimpleStruct uintptr - -func (p SwigcptrSimpleStruct) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrSimpleStruct) SwigIsSimpleStruct() { -} - -var _wrap_SimpleStruct_double_field_set unsafe.Pointer - -func _swig_wrap_SimpleStruct_double_field_set(base SwigcptrSimpleStruct, _ float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_SimpleStruct_double_field_set, _swig_p) - return -} - -func (arg1 SwigcptrSimpleStruct) SetDouble_field(arg2 float64) { - _swig_wrap_SimpleStruct_double_field_set(arg1, arg2) -} - -var _wrap_SimpleStruct_double_field_get unsafe.Pointer - -func _swig_wrap_SimpleStruct_double_field_get(base SwigcptrSimpleStruct) (_ float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_SimpleStruct_double_field_get, _swig_p) - return -} - -func (arg1 SwigcptrSimpleStruct) GetDouble_field() (_swig_ret float64) { - return _swig_wrap_SimpleStruct_double_field_get(arg1) -} - -var _wrap_new_SimpleStruct unsafe.Pointer - -func _swig_wrap_new_SimpleStruct() (base SwigcptrSimpleStruct) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_SimpleStruct, _swig_p) - return -} - -func NewSimpleStruct() (_swig_ret SimpleStruct) { - return _swig_wrap_new_SimpleStruct() -} - -var _wrap_delete_SimpleStruct unsafe.Pointer - -func _swig_wrap_delete_SimpleStruct(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_SimpleStruct, _swig_p) - return -} - -func DeleteSimpleStruct(arg1 SimpleStruct) { - _swig_wrap_delete_SimpleStruct(arg1.Swigcptr()) -} - -type SimpleStruct interface { - Swigcptr() uintptr - SwigIsSimpleStruct() - SetDouble_field(arg2 float64) - GetDouble_field() (_swig_ret float64) -} - -var _wrap_array_c_set unsafe.Pointer - -func _swig_wrap_array_c_set(base *string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_array_c_set, _swig_p) - return -} - -func SetArray_c(arg1 *string) { - _swig_wrap_array_c_set(arg1) -} - -var _wrap_array_c_get unsafe.Pointer - -func GetArray_c() (_swig_ret *string) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_array_c_get, _swig_p) - return -} -var _wrap_array_sc_set unsafe.Pointer - -func _swig_wrap_array_sc_set(base *string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_array_sc_set, _swig_p) - return -} - -func SetArray_sc(arg1 *string) { - _swig_wrap_array_sc_set(arg1) -} - -var _wrap_array_sc_get unsafe.Pointer - -func GetArray_sc() (_swig_ret *string) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_array_sc_get, _swig_p) - return -} -var _wrap_array_uc_set unsafe.Pointer - -func _swig_wrap_array_uc_set(base *string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_array_uc_set, _swig_p) - return -} - -func SetArray_uc(arg1 *string) { - _swig_wrap_array_uc_set(arg1) -} - -var _wrap_array_uc_get unsafe.Pointer - -func GetArray_uc() (_swig_ret *string) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_array_uc_get, _swig_p) - return -} -var _wrap_array_s_set unsafe.Pointer - -func _swig_wrap_array_s_set(base **int16) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_array_s_set, _swig_p) - return -} - -func SetArray_s(arg1 **int16) { - _swig_wrap_array_s_set(arg1) -} - -var _wrap_array_s_get unsafe.Pointer - -func GetArray_s() (_swig_ret **int16) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_array_s_get, _swig_p) - return -} -var _wrap_array_us_set unsafe.Pointer - -func _swig_wrap_array_us_set(base **uint16) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_array_us_set, _swig_p) - return -} - -func SetArray_us(arg1 **uint16) { - _swig_wrap_array_us_set(arg1) -} - -var _wrap_array_us_get unsafe.Pointer - -func GetArray_us() (_swig_ret **uint16) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_array_us_get, _swig_p) - return -} -var _wrap_array_i_set unsafe.Pointer - -func _swig_wrap_array_i_set(base **int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_array_i_set, _swig_p) - return -} - -func SetArray_i(arg1 **int) { - _swig_wrap_array_i_set(arg1) -} - -var _wrap_array_i_get unsafe.Pointer - -func GetArray_i() (_swig_ret **int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_array_i_get, _swig_p) - return -} -var _wrap_array_ui_set unsafe.Pointer - -func _swig_wrap_array_ui_set(base **uint) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_array_ui_set, _swig_p) - return -} - -func SetArray_ui(arg1 **uint) { - _swig_wrap_array_ui_set(arg1) -} - -var _wrap_array_ui_get unsafe.Pointer - -func GetArray_ui() (_swig_ret **uint) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_array_ui_get, _swig_p) - return -} -var _wrap_array_l_set unsafe.Pointer - -func _swig_wrap_array_l_set(base **int64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_array_l_set, _swig_p) - return -} - -func SetArray_l(arg1 **int64) { - _swig_wrap_array_l_set(arg1) -} - -var _wrap_array_l_get unsafe.Pointer - -func GetArray_l() (_swig_ret **int64) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_array_l_get, _swig_p) - return -} -var _wrap_array_ul_set unsafe.Pointer - -func _swig_wrap_array_ul_set(base **uint64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_array_ul_set, _swig_p) - return -} - -func SetArray_ul(arg1 **uint64) { - _swig_wrap_array_ul_set(arg1) -} - -var _wrap_array_ul_get unsafe.Pointer - -func GetArray_ul() (_swig_ret **uint64) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_array_ul_get, _swig_p) - return -} -var _wrap_array_ll_set unsafe.Pointer - -func _swig_wrap_array_ll_set(base **int64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_array_ll_set, _swig_p) - return -} - -func SetArray_ll(arg1 **int64) { - _swig_wrap_array_ll_set(arg1) -} - -var _wrap_array_ll_get unsafe.Pointer - -func GetArray_ll() (_swig_ret **int64) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_array_ll_get, _swig_p) - return -} -var _wrap_array_f_set unsafe.Pointer - -func _swig_wrap_array_f_set(base **float32) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_array_f_set, _swig_p) - return -} - -func SetArray_f(arg1 **float32) { - _swig_wrap_array_f_set(arg1) -} - -var _wrap_array_f_get unsafe.Pointer - -func GetArray_f() (_swig_ret **float32) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_array_f_get, _swig_p) - return -} -var _wrap_array_d_set unsafe.Pointer - -func _swig_wrap_array_d_set(base **float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_array_d_set, _swig_p) - return -} - -func SetArray_d(arg1 **float64) { - _swig_wrap_array_d_set(arg1) -} - -var _wrap_array_d_get unsafe.Pointer - -func GetArray_d() (_swig_ret **float64) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_array_d_get, _swig_p) - return -} -var _wrap_array_struct_set unsafe.Pointer - -func _swig_wrap_array_struct_set(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_array_struct_set, _swig_p) - return -} - -func SetArray_struct(arg1 SimpleStruct) { - _swig_wrap_array_struct_set(arg1.Swigcptr()) -} - -var _wrap_array_struct_get unsafe.Pointer - -func _swig_wrap_array_struct_get() (base SwigcptrSimpleStruct) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_array_struct_get, _swig_p) - return -} - -func GetArray_struct() (_swig_ret SimpleStruct) { - return _swig_wrap_array_struct_get() -} - -var _wrap_array_structpointers_set unsafe.Pointer - -func _swig_wrap_array_structpointers_set(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_array_structpointers_set, _swig_p) - return -} - -func SetArray_structpointers(arg1 SimpleStruct) { - _swig_wrap_array_structpointers_set(arg1.Swigcptr()) -} - -var _wrap_array_structpointers_get unsafe.Pointer - -func _swig_wrap_array_structpointers_get() (base SwigcptrSimpleStruct) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_array_structpointers_get, _swig_p) - return -} - -func GetArray_structpointers() (_swig_ret SimpleStruct) { - return _swig_wrap_array_structpointers_get() -} - -var _wrap_array_ipointers_set unsafe.Pointer - -func _swig_wrap_array_ipointers_set(base ***int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_array_ipointers_set, _swig_p) - return -} - -func SetArray_ipointers(arg1 ***int) { - _swig_wrap_array_ipointers_set(arg1) -} - -var _wrap_array_ipointers_get unsafe.Pointer - -func GetArray_ipointers() (_swig_ret ***int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_array_ipointers_get, _swig_p) - return -} -var _wrap_array_enum_set unsafe.Pointer - -func _swig_wrap_array_enum_set(base **Finger) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_array_enum_set, _swig_p) - return -} - -func SetArray_enum(arg1 **Finger) { - _swig_wrap_array_enum_set(arg1) -} - -var _wrap_array_enum_get unsafe.Pointer - -func GetArray_enum() (_swig_ret **Finger) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_array_enum_get, _swig_p) - return -} -var _wrap_array_enumpointers_set unsafe.Pointer - -func _swig_wrap_array_enumpointers_set(base ***Finger) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_array_enumpointers_set, _swig_p) - return -} - -func SetArray_enumpointers(arg1 ***Finger) { - _swig_wrap_array_enumpointers_set(arg1) -} - -var _wrap_array_enumpointers_get unsafe.Pointer - -func GetArray_enumpointers() (_swig_ret ***Finger) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_array_enumpointers_get, _swig_p) - return -} -var _wrap_array_const_i_get unsafe.Pointer - -func GetArray_const_i() (_swig_ret **int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_array_const_i_get, _swig_p) - return -} -var _wrap_fn_taking_arrays unsafe.Pointer - -func _swig_wrap_fn_taking_arrays(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_fn_taking_arrays, _swig_p) - return -} - -func Fn_taking_arrays(arg1 SimpleStruct) { - _swig_wrap_fn_taking_arrays(arg1.Swigcptr()) -} - -var _wrap_get_2d_array unsafe.Pointer - -func Get_2d_array(arg1 **int, arg2 int, arg3 int) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_get_2d_array, _swig_p) - return -} -type SwigcptrMaterial uintptr - -func (p SwigcptrMaterial) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrMaterial) SwigIsMaterial() { -} - -var _wrap_new_Material unsafe.Pointer - -func _swig_wrap_new_Material() (base SwigcptrMaterial) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Material, _swig_p) - return -} - -func NewMaterial() (_swig_ret Material) { - return _swig_wrap_new_Material() -} - -var _wrap_delete_Material unsafe.Pointer - -func _swig_wrap_delete_Material(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Material, _swig_p) - return -} - -func DeleteMaterial(arg1 Material) { - _swig_wrap_delete_Material(arg1.Swigcptr()) -} - -type Material interface { - Swigcptr() uintptr - SwigIsMaterial() -} - -var _wrap_Size unsafe.Pointer - -func _swig_getSize() (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_Size, _swig_p) - return -} -var Size int = _swig_getSize() -var _wrap_chitMat_set unsafe.Pointer - -func _swig_wrap_chitMat_set(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_chitMat_set, _swig_p) - return -} - -func SetChitMat(arg1 Material) { - _swig_wrap_chitMat_set(arg1.Swigcptr()) -} - -var _wrap_chitMat_get unsafe.Pointer - -func _swig_wrap_chitMat_get() (base SwigcptrMaterial) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_chitMat_get, _swig_p) - return -} - -func GetChitMat() (_swig_ret Material) { - return _swig_wrap_chitMat_get() -} - -var _wrap_hitMat_val_set unsafe.Pointer - -func _swig_wrap_hitMat_val_set(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_hitMat_val_set, _swig_p) - return -} - -func SetHitMat_val(arg1 Material) { - _swig_wrap_hitMat_val_set(arg1.Swigcptr()) -} - -var _wrap_hitMat_val_get unsafe.Pointer - -func _swig_wrap_hitMat_val_get() (base SwigcptrMaterial) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_hitMat_val_get, _swig_p) - return -} - -func GetHitMat_val() (_swig_ret Material) { - return _swig_wrap_hitMat_val_get() -} - -var _wrap_hitMat_set unsafe.Pointer - -func _swig_wrap_hitMat_set(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_hitMat_set, _swig_p) - return -} - -func SetHitMat(arg1 Material) { - _swig_wrap_hitMat_set(arg1.Swigcptr()) -} - -var _wrap_hitMat_get unsafe.Pointer - -func _swig_wrap_hitMat_get() (base SwigcptrMaterial) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_hitMat_get, _swig_p) - return -} - -func GetHitMat() (_swig_ret Material) { - return _swig_wrap_hitMat_get() -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/arrays_scope.go b/Examples/test-suite/go/arrays_scope.go deleted file mode 100644 index 8c049f286..000000000 --- a/Examples/test-suite/go/arrays_scope.go +++ /dev/null @@ -1,190 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../arrays_scope.i - -package arrays_scope - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -var _wrap_ASIZE unsafe.Pointer - -func _swig_getASIZE() (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_ASIZE, _swig_p) - return -} -var ASIZE int = _swig_getASIZE() -var _wrap_BBSIZE unsafe.Pointer - -func _swig_getBBSIZE() (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_BBSIZE, _swig_p) - return -} -var BBSIZE int = _swig_getBBSIZE() -type SwigcptrBar uintptr - -func (p SwigcptrBar) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrBar) SwigIsBar() { -} - -var _wrap_CCSIZE_Bar unsafe.Pointer - -func _swig_getBar_CCSIZE_Bar() (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_CCSIZE_Bar, _swig_p) - return -} -var BarCCSIZE int = _swig_getBar_CCSIZE_Bar() -var _wrap_Bar_adata_set unsafe.Pointer - -func _swig_wrap_Bar_adata_set(base SwigcptrBar, _ *int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Bar_adata_set, _swig_p) - return -} - -func (arg1 SwigcptrBar) SetAdata(arg2 *int) { - _swig_wrap_Bar_adata_set(arg1, arg2) -} - -var _wrap_Bar_adata_get unsafe.Pointer - -func _swig_wrap_Bar_adata_get(base SwigcptrBar) (_ *int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Bar_adata_get, _swig_p) - return -} - -func (arg1 SwigcptrBar) GetAdata() (_swig_ret *int) { - return _swig_wrap_Bar_adata_get(arg1) -} - -var _wrap_Bar_bdata_set unsafe.Pointer - -func _swig_wrap_Bar_bdata_set(base SwigcptrBar, _ *int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Bar_bdata_set, _swig_p) - return -} - -func (arg1 SwigcptrBar) SetBdata(arg2 *int) { - _swig_wrap_Bar_bdata_set(arg1, arg2) -} - -var _wrap_Bar_bdata_get unsafe.Pointer - -func _swig_wrap_Bar_bdata_get(base SwigcptrBar) (_ *int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Bar_bdata_get, _swig_p) - return -} - -func (arg1 SwigcptrBar) GetBdata() (_swig_ret *int) { - return _swig_wrap_Bar_bdata_get(arg1) -} - -var _wrap_Bar_cdata_set unsafe.Pointer - -func _swig_wrap_Bar_cdata_set(base SwigcptrBar, _ *int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Bar_cdata_set, _swig_p) - return -} - -func (arg1 SwigcptrBar) SetCdata(arg2 *int) { - _swig_wrap_Bar_cdata_set(arg1, arg2) -} - -var _wrap_Bar_cdata_get unsafe.Pointer - -func _swig_wrap_Bar_cdata_get(base SwigcptrBar) (_ *int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Bar_cdata_get, _swig_p) - return -} - -func (arg1 SwigcptrBar) GetCdata() (_swig_ret *int) { - return _swig_wrap_Bar_cdata_get(arg1) -} - -var _wrap_Bar_blah unsafe.Pointer - -func _swig_wrap_Bar_blah(base SwigcptrBar, _ *int, _ *int, _ *int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Bar_blah, _swig_p) - return -} - -func (arg1 SwigcptrBar) Blah(arg2 *int, arg3 *int, arg4 *int) { - _swig_wrap_Bar_blah(arg1, arg2, arg3, arg4) -} - -var _wrap_new_Bar unsafe.Pointer - -func _swig_wrap_new_Bar() (base SwigcptrBar) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Bar, _swig_p) - return -} - -func NewBar() (_swig_ret Bar) { - return _swig_wrap_new_Bar() -} - -var _wrap_delete_Bar unsafe.Pointer - -func _swig_wrap_delete_Bar(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Bar, _swig_p) - return -} - -func DeleteBar(arg1 Bar) { - _swig_wrap_delete_Bar(arg1.Swigcptr()) -} - -type Bar interface { - Swigcptr() uintptr - SwigIsBar() - SetAdata(arg2 *int) - GetAdata() (_swig_ret *int) - SetBdata(arg2 *int) - GetBdata() (_swig_ret *int) - SetCdata(arg2 *int) - GetCdata() (_swig_ret *int) - Blah(arg2 *int, arg3 *int, arg4 *int) -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/autodoc.go b/Examples/test-suite/go/autodoc.go deleted file mode 100644 index 783dc59b1..000000000 --- a/Examples/test-suite/go/autodoc.go +++ /dev/null @@ -1,933 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../autodoc.i - -package autodoc - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type Hola int -var _wrap_hi unsafe.Pointer - -func _swig_gethi() (_swig_ret Hola) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_hi, _swig_p) - return -} -var Hi Hola = _swig_gethi() -var _wrap_hello unsafe.Pointer - -func _swig_gethello() (_swig_ret Hola) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_hello, _swig_p) - return -} -var Hello Hola = _swig_gethello() -type SwigcptrA uintptr - -func (p SwigcptrA) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrA) SwigIsA() { -} - -var _wrap_new_A unsafe.Pointer - -func _swig_wrap_new_A(base int, _ int16, _ Hola) (_ SwigcptrA) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_A, _swig_p) - return -} - -func NewA(arg1 int, arg2 int16, arg3 Hola) (_swig_ret A) { - return _swig_wrap_new_A(arg1, arg2, arg3) -} - -var _wrap_A_funk unsafe.Pointer - -func _swig_wrap_A_funk(base SwigcptrA, _ int) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_A_funk, _swig_p) - return -} - -func (arg1 SwigcptrA) Funk(arg2 int) (_swig_ret int) { - return _swig_wrap_A_funk(arg1, arg2) -} - -var _wrap_A_func0 unsafe.Pointer - -func _swig_wrap_A_func0(base SwigcptrA, _ int16, _ int) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_A_func0, _swig_p) - return -} - -func (arg1 SwigcptrA) Func0(arg2 int16, arg3 int) (_swig_ret int) { - return _swig_wrap_A_func0(arg1, arg2, arg3) -} - -var _wrap_A_func1 unsafe.Pointer - -func _swig_wrap_A_func1(base SwigcptrA, _ int16, _ int) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_A_func1, _swig_p) - return -} - -func (arg1 SwigcptrA) Func1(arg2 int16, arg3 int) (_swig_ret int) { - return _swig_wrap_A_func1(arg1, arg2, arg3) -} - -var _wrap_A_func2 unsafe.Pointer - -func _swig_wrap_A_func2(base SwigcptrA, _ int16, _ int) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_A_func2, _swig_p) - return -} - -func (arg1 SwigcptrA) Func2(arg2 int16, arg3 int) (_swig_ret int) { - return _swig_wrap_A_func2(arg1, arg2, arg3) -} - -var _wrap_A_func3 unsafe.Pointer - -func _swig_wrap_A_func3(base SwigcptrA, _ int16, _ int) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_A_func3, _swig_p) - return -} - -func (arg1 SwigcptrA) Func3(arg2 int16, arg3 int) (_swig_ret int) { - return _swig_wrap_A_func3(arg1, arg2, arg3) -} - -var _wrap_A_func0default__SWIG_0 unsafe.Pointer - -func _swig_wrap_A_func0default__SWIG_0(base SwigcptrA, _ uintptr, _ int16, _ int, _ float64) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_A_func0default__SWIG_0, _swig_p) - return -} - -func (arg1 SwigcptrA) Func0default__SWIG_0(arg2 A, arg3 int16, arg4 int, arg5 float64) (_swig_ret int) { - return _swig_wrap_A_func0default__SWIG_0(arg1, arg2.Swigcptr(), arg3, arg4, arg5) -} - -var _wrap_A_func0default__SWIG_1 unsafe.Pointer - -func _swig_wrap_A_func0default__SWIG_1(base SwigcptrA, _ uintptr, _ int16, _ int) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_A_func0default__SWIG_1, _swig_p) - return -} - -func (arg1 SwigcptrA) Func0default__SWIG_1(arg2 A, arg3 int16, arg4 int) (_swig_ret int) { - return _swig_wrap_A_func0default__SWIG_1(arg1, arg2.Swigcptr(), arg3, arg4) -} - -func (p SwigcptrA) Func0default(a ...interface{}) int { - argc := len(a) - if argc == 3 { - return p.Func0default__SWIG_1(a[0].(A), a[1].(int16), a[2].(int)) - } - if argc == 4 { - return p.Func0default__SWIG_0(a[0].(A), a[1].(int16), a[2].(int), a[3].(float64)) - } - panic("No match for overloaded function call") -} - -var _wrap_A_func1default__SWIG_0 unsafe.Pointer - -func _swig_wrap_A_func1default__SWIG_0(base SwigcptrA, _ uintptr, _ int16, _ int, _ float64) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_A_func1default__SWIG_0, _swig_p) - return -} - -func (arg1 SwigcptrA) Func1default__SWIG_0(arg2 A, arg3 int16, arg4 int, arg5 float64) (_swig_ret int) { - return _swig_wrap_A_func1default__SWIG_0(arg1, arg2.Swigcptr(), arg3, arg4, arg5) -} - -var _wrap_A_func1default__SWIG_1 unsafe.Pointer - -func _swig_wrap_A_func1default__SWIG_1(base SwigcptrA, _ uintptr, _ int16, _ int) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_A_func1default__SWIG_1, _swig_p) - return -} - -func (arg1 SwigcptrA) Func1default__SWIG_1(arg2 A, arg3 int16, arg4 int) (_swig_ret int) { - return _swig_wrap_A_func1default__SWIG_1(arg1, arg2.Swigcptr(), arg3, arg4) -} - -func (p SwigcptrA) Func1default(a ...interface{}) int { - argc := len(a) - if argc == 3 { - return p.Func1default__SWIG_1(a[0].(A), a[1].(int16), a[2].(int)) - } - if argc == 4 { - return p.Func1default__SWIG_0(a[0].(A), a[1].(int16), a[2].(int), a[3].(float64)) - } - panic("No match for overloaded function call") -} - -var _wrap_A_func2default__SWIG_0 unsafe.Pointer - -func _swig_wrap_A_func2default__SWIG_0(base SwigcptrA, _ uintptr, _ int16, _ int, _ float64) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_A_func2default__SWIG_0, _swig_p) - return -} - -func (arg1 SwigcptrA) Func2default__SWIG_0(arg2 A, arg3 int16, arg4 int, arg5 float64) (_swig_ret int) { - return _swig_wrap_A_func2default__SWIG_0(arg1, arg2.Swigcptr(), arg3, arg4, arg5) -} - -var _wrap_A_func2default__SWIG_1 unsafe.Pointer - -func _swig_wrap_A_func2default__SWIG_1(base SwigcptrA, _ uintptr, _ int16, _ int) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_A_func2default__SWIG_1, _swig_p) - return -} - -func (arg1 SwigcptrA) Func2default__SWIG_1(arg2 A, arg3 int16, arg4 int) (_swig_ret int) { - return _swig_wrap_A_func2default__SWIG_1(arg1, arg2.Swigcptr(), arg3, arg4) -} - -func (p SwigcptrA) Func2default(a ...interface{}) int { - argc := len(a) - if argc == 3 { - return p.Func2default__SWIG_1(a[0].(A), a[1].(int16), a[2].(int)) - } - if argc == 4 { - return p.Func2default__SWIG_0(a[0].(A), a[1].(int16), a[2].(int), a[3].(float64)) - } - panic("No match for overloaded function call") -} - -var _wrap_A_func3default__SWIG_0 unsafe.Pointer - -func _swig_wrap_A_func3default__SWIG_0(base SwigcptrA, _ uintptr, _ int16, _ int, _ float64) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_A_func3default__SWIG_0, _swig_p) - return -} - -func (arg1 SwigcptrA) Func3default__SWIG_0(arg2 A, arg3 int16, arg4 int, arg5 float64) (_swig_ret int) { - return _swig_wrap_A_func3default__SWIG_0(arg1, arg2.Swigcptr(), arg3, arg4, arg5) -} - -var _wrap_A_func3default__SWIG_1 unsafe.Pointer - -func _swig_wrap_A_func3default__SWIG_1(base SwigcptrA, _ uintptr, _ int16, _ int) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_A_func3default__SWIG_1, _swig_p) - return -} - -func (arg1 SwigcptrA) Func3default__SWIG_1(arg2 A, arg3 int16, arg4 int) (_swig_ret int) { - return _swig_wrap_A_func3default__SWIG_1(arg1, arg2.Swigcptr(), arg3, arg4) -} - -func (p SwigcptrA) Func3default(a ...interface{}) int { - argc := len(a) - if argc == 3 { - return p.Func3default__SWIG_1(a[0].(A), a[1].(int16), a[2].(int)) - } - if argc == 4 { - return p.Func3default__SWIG_0(a[0].(A), a[1].(int16), a[2].(int), a[3].(float64)) - } - panic("No match for overloaded function call") -} - -var _wrap_A_func0static__SWIG_0 unsafe.Pointer - -func _swig_wrap_A_func0static__SWIG_0(base uintptr, _ int16, _ int, _ float64) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_A_func0static__SWIG_0, _swig_p) - return -} - -func AFunc0static__SWIG_0(arg1 A, arg2 int16, arg3 int, arg4 float64) (_swig_ret int) { - return _swig_wrap_A_func0static__SWIG_0(arg1.Swigcptr(), arg2, arg3, arg4) -} - -var _wrap_A_func0static__SWIG_1 unsafe.Pointer - -func _swig_wrap_A_func0static__SWIG_1(base uintptr, _ int16, _ int) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_A_func0static__SWIG_1, _swig_p) - return -} - -func AFunc0static__SWIG_1(arg1 A, arg2 int16, arg3 int) (_swig_ret int) { - return _swig_wrap_A_func0static__SWIG_1(arg1.Swigcptr(), arg2, arg3) -} - -func AFunc0static(a ...interface{}) int { - argc := len(a) - if argc == 3 { - return AFunc0static__SWIG_1(a[0].(A), a[1].(int16), a[2].(int)) - } - if argc == 4 { - return AFunc0static__SWIG_0(a[0].(A), a[1].(int16), a[2].(int), a[3].(float64)) - } - panic("No match for overloaded function call") -} - -var _wrap_A_func1static__SWIG_0 unsafe.Pointer - -func _swig_wrap_A_func1static__SWIG_0(base uintptr, _ int16, _ int, _ float64) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_A_func1static__SWIG_0, _swig_p) - return -} - -func AFunc1static__SWIG_0(arg1 A, arg2 int16, arg3 int, arg4 float64) (_swig_ret int) { - return _swig_wrap_A_func1static__SWIG_0(arg1.Swigcptr(), arg2, arg3, arg4) -} - -var _wrap_A_func1static__SWIG_1 unsafe.Pointer - -func _swig_wrap_A_func1static__SWIG_1(base uintptr, _ int16, _ int) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_A_func1static__SWIG_1, _swig_p) - return -} - -func AFunc1static__SWIG_1(arg1 A, arg2 int16, arg3 int) (_swig_ret int) { - return _swig_wrap_A_func1static__SWIG_1(arg1.Swigcptr(), arg2, arg3) -} - -func AFunc1static(a ...interface{}) int { - argc := len(a) - if argc == 3 { - return AFunc1static__SWIG_1(a[0].(A), a[1].(int16), a[2].(int)) - } - if argc == 4 { - return AFunc1static__SWIG_0(a[0].(A), a[1].(int16), a[2].(int), a[3].(float64)) - } - panic("No match for overloaded function call") -} - -var _wrap_A_func2static__SWIG_0 unsafe.Pointer - -func _swig_wrap_A_func2static__SWIG_0(base uintptr, _ int16, _ int, _ float64) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_A_func2static__SWIG_0, _swig_p) - return -} - -func AFunc2static__SWIG_0(arg1 A, arg2 int16, arg3 int, arg4 float64) (_swig_ret int) { - return _swig_wrap_A_func2static__SWIG_0(arg1.Swigcptr(), arg2, arg3, arg4) -} - -var _wrap_A_func2static__SWIG_1 unsafe.Pointer - -func _swig_wrap_A_func2static__SWIG_1(base uintptr, _ int16, _ int) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_A_func2static__SWIG_1, _swig_p) - return -} - -func AFunc2static__SWIG_1(arg1 A, arg2 int16, arg3 int) (_swig_ret int) { - return _swig_wrap_A_func2static__SWIG_1(arg1.Swigcptr(), arg2, arg3) -} - -func AFunc2static(a ...interface{}) int { - argc := len(a) - if argc == 3 { - return AFunc2static__SWIG_1(a[0].(A), a[1].(int16), a[2].(int)) - } - if argc == 4 { - return AFunc2static__SWIG_0(a[0].(A), a[1].(int16), a[2].(int), a[3].(float64)) - } - panic("No match for overloaded function call") -} - -var _wrap_A_func3static__SWIG_0 unsafe.Pointer - -func _swig_wrap_A_func3static__SWIG_0(base uintptr, _ int16, _ int, _ float64) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_A_func3static__SWIG_0, _swig_p) - return -} - -func AFunc3static__SWIG_0(arg1 A, arg2 int16, arg3 int, arg4 float64) (_swig_ret int) { - return _swig_wrap_A_func3static__SWIG_0(arg1.Swigcptr(), arg2, arg3, arg4) -} - -var _wrap_A_func3static__SWIG_1 unsafe.Pointer - -func _swig_wrap_A_func3static__SWIG_1(base uintptr, _ int16, _ int) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_A_func3static__SWIG_1, _swig_p) - return -} - -func AFunc3static__SWIG_1(arg1 A, arg2 int16, arg3 int) (_swig_ret int) { - return _swig_wrap_A_func3static__SWIG_1(arg1.Swigcptr(), arg2, arg3) -} - -func AFunc3static(a ...interface{}) int { - argc := len(a) - if argc == 3 { - return AFunc3static__SWIG_1(a[0].(A), a[1].(int16), a[2].(int)) - } - if argc == 4 { - return AFunc3static__SWIG_0(a[0].(A), a[1].(int16), a[2].(int), a[3].(float64)) - } - panic("No match for overloaded function call") -} - -var _wrap_A_variable_a_set unsafe.Pointer - -func _swig_wrap_A_variable_a_set(base SwigcptrA, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_A_variable_a_set, _swig_p) - return -} - -func (arg1 SwigcptrA) SetVariable_a(arg2 int) { - _swig_wrap_A_variable_a_set(arg1, arg2) -} - -var _wrap_A_variable_a_get unsafe.Pointer - -func _swig_wrap_A_variable_a_get(base SwigcptrA) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_A_variable_a_get, _swig_p) - return -} - -func (arg1 SwigcptrA) GetVariable_a() (_swig_ret int) { - return _swig_wrap_A_variable_a_get(arg1) -} - -var _wrap_A_variable_b_set unsafe.Pointer - -func _swig_wrap_A_variable_b_set(base SwigcptrA, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_A_variable_b_set, _swig_p) - return -} - -func (arg1 SwigcptrA) SetVariable_b(arg2 int) { - _swig_wrap_A_variable_b_set(arg1, arg2) -} - -var _wrap_A_variable_b_get unsafe.Pointer - -func _swig_wrap_A_variable_b_get(base SwigcptrA) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_A_variable_b_get, _swig_p) - return -} - -func (arg1 SwigcptrA) GetVariable_b() (_swig_ret int) { - return _swig_wrap_A_variable_b_get(arg1) -} - -var _wrap_A_variable_c_set unsafe.Pointer - -func _swig_wrap_A_variable_c_set(base SwigcptrA, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_A_variable_c_set, _swig_p) - return -} - -func (arg1 SwigcptrA) SetVariable_c(arg2 int) { - _swig_wrap_A_variable_c_set(arg1, arg2) -} - -var _wrap_A_variable_c_get unsafe.Pointer - -func _swig_wrap_A_variable_c_get(base SwigcptrA) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_A_variable_c_get, _swig_p) - return -} - -func (arg1 SwigcptrA) GetVariable_c() (_swig_ret int) { - return _swig_wrap_A_variable_c_get(arg1) -} - -var _wrap_A_variable_d_set unsafe.Pointer - -func _swig_wrap_A_variable_d_set(base SwigcptrA, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_A_variable_d_set, _swig_p) - return -} - -func (arg1 SwigcptrA) SetVariable_d(arg2 int) { - _swig_wrap_A_variable_d_set(arg1, arg2) -} - -var _wrap_A_variable_d_get unsafe.Pointer - -func _swig_wrap_A_variable_d_get(base SwigcptrA) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_A_variable_d_get, _swig_p) - return -} - -func (arg1 SwigcptrA) GetVariable_d() (_swig_ret int) { - return _swig_wrap_A_variable_d_get(arg1) -} - -var _wrap_delete_A unsafe.Pointer - -func _swig_wrap_delete_A(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_A, _swig_p) - return -} - -func DeleteA(arg1 A) { - _swig_wrap_delete_A(arg1.Swigcptr()) -} - -type A interface { - Swigcptr() uintptr - SwigIsA() - Funk(arg2 int) (_swig_ret int) - Func0(arg2 int16, arg3 int) (_swig_ret int) - Func1(arg2 int16, arg3 int) (_swig_ret int) - Func2(arg2 int16, arg3 int) (_swig_ret int) - Func3(arg2 int16, arg3 int) (_swig_ret int) - Func0default(a ...interface{}) int - Func1default(a ...interface{}) int - Func2default(a ...interface{}) int - Func3default(a ...interface{}) int - SetVariable_a(arg2 int) - GetVariable_a() (_swig_ret int) - SetVariable_b(arg2 int) - GetVariable_b() (_swig_ret int) - SetVariable_c(arg2 int) - GetVariable_c() (_swig_ret int) - SetVariable_d(arg2 int) - GetVariable_d() (_swig_ret int) -} - -type SwigcptrB uintptr - -func (p SwigcptrB) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrB) SwigIsB() { -} - -var _wrap_new_B unsafe.Pointer - -func _swig_wrap_new_B(base int, _ int, _ Hola) (_ SwigcptrB) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_B, _swig_p) - return -} - -func NewB(arg1 int, arg2 int, arg3 Hola) (_swig_ret B) { - return _swig_wrap_new_B(arg1, arg2, arg3) -} - -var _wrap_B_funk unsafe.Pointer - -func _swig_wrap_B_funk(base SwigcptrB, _ int, _ int) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_B_funk, _swig_p) - return -} - -func (arg1 SwigcptrB) Funk(arg2 int, arg3 int) (_swig_ret int) { - return _swig_wrap_B_funk(arg1, arg2, arg3) -} - -var _wrap_delete_B unsafe.Pointer - -func _swig_wrap_delete_B(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_B, _swig_p) - return -} - -func DeleteB(arg1 B) { - _swig_wrap_delete_B(arg1.Swigcptr()) -} - -type B interface { - Swigcptr() uintptr - SwigIsB() - Funk(arg2 int, arg3 int) (_swig_ret int) -} - -type SwigcptrC uintptr - -func (p SwigcptrC) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrC) SwigIsC() { -} - -var _wrap_new_C unsafe.Pointer - -func _swig_wrap_new_C(base int, _ int, _ Hola) (_ SwigcptrC) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_C, _swig_p) - return -} - -func NewC(arg1 int, arg2 int, arg3 Hola) (_swig_ret C) { - return _swig_wrap_new_C(arg1, arg2, arg3) -} - -var _wrap_delete_C unsafe.Pointer - -func _swig_wrap_delete_C(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_C, _swig_p) - return -} - -func DeleteC(arg1 C) { - _swig_wrap_delete_C(arg1.Swigcptr()) -} - -type C interface { - Swigcptr() uintptr - SwigIsC() -} - -type SwigcptrD uintptr - -func (p SwigcptrD) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrD) SwigIsD() { -} - -var _wrap_new_D unsafe.Pointer - -func _swig_wrap_new_D(base int, _ int, _ Hola) (_ SwigcptrD) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_D, _swig_p) - return -} - -func NewD(arg1 int, arg2 int, arg3 Hola) (_swig_ret D) { - return _swig_wrap_new_D(arg1, arg2, arg3) -} - -var _wrap_delete_D unsafe.Pointer - -func _swig_wrap_delete_D(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_D, _swig_p) - return -} - -func DeleteD(arg1 D) { - _swig_wrap_delete_D(arg1.Swigcptr()) -} - -type D interface { - Swigcptr() uintptr - SwigIsD() -} - -type SwigcptrE uintptr - -func (p SwigcptrE) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrE) SwigIsE() { -} - -var _wrap_new_E unsafe.Pointer - -func _swig_wrap_new_E(base int, _ int, _ Hola) (_ SwigcptrE) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_E, _swig_p) - return -} - -func NewE(arg1 int, arg2 int, arg3 Hola) (_swig_ret E) { - return _swig_wrap_new_E(arg1, arg2, arg3) -} - -var _wrap_delete_E unsafe.Pointer - -func _swig_wrap_delete_E(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_E, _swig_p) - return -} - -func DeleteE(arg1 E) { - _swig_wrap_delete_E(arg1.Swigcptr()) -} - -type E interface { - Swigcptr() uintptr - SwigIsE() -} - -type SwigcptrF uintptr - -func (p SwigcptrF) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrF) SwigIsF() { -} - -var _wrap_new_F unsafe.Pointer - -func _swig_wrap_new_F(base int, _ int, _ Hola) (_ SwigcptrF) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_F, _swig_p) - return -} - -func NewF(arg1 int, arg2 int, arg3 Hola) (_swig_ret F) { - return _swig_wrap_new_F(arg1, arg2, arg3) -} - -var _wrap_delete_F unsafe.Pointer - -func _swig_wrap_delete_F(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_F, _swig_p) - return -} - -func DeleteF(arg1 F) { - _swig_wrap_delete_F(arg1.Swigcptr()) -} - -type F interface { - Swigcptr() uintptr - SwigIsF() -} - -var _wrap_funk unsafe.Pointer - -func _swig_wrap_funk(base uintptr, _ int16, _ int, _ int) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_funk, _swig_p) - return -} - -func Funk(arg1 A, arg2 int16, arg3 int, arg4 int) (_swig_ret int) { - return _swig_wrap_funk(arg1.Swigcptr(), arg2, arg3, arg4) -} - -var _wrap_funkdefaults__SWIG_0 unsafe.Pointer - -func _swig_wrap_funkdefaults__SWIG_0(base uintptr, _ int16, _ int, _ int, _ float64) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_funkdefaults__SWIG_0, _swig_p) - return -} - -func Funkdefaults__SWIG_0(arg1 A, arg2 int16, arg3 int, arg4 int, arg5 float64) (_swig_ret int) { - return _swig_wrap_funkdefaults__SWIG_0(arg1.Swigcptr(), arg2, arg3, arg4, arg5) -} - -var _wrap_funkdefaults__SWIG_1 unsafe.Pointer - -func _swig_wrap_funkdefaults__SWIG_1(base uintptr, _ int16, _ int, _ int) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_funkdefaults__SWIG_1, _swig_p) - return -} - -func Funkdefaults__SWIG_1(arg1 A, arg2 int16, arg3 int, arg4 int) (_swig_ret int) { - return _swig_wrap_funkdefaults__SWIG_1(arg1.Swigcptr(), arg2, arg3, arg4) -} - -func Funkdefaults(a ...interface{}) int { - argc := len(a) - if argc == 4 { - return Funkdefaults__SWIG_1(a[0].(A), a[1].(int16), a[2].(int), a[3].(int)) - } - if argc == 5 { - return Funkdefaults__SWIG_0(a[0].(A), a[1].(int16), a[2].(int), a[3].(int), a[4].(float64)) - } - panic("No match for overloaded function call") -} - -var _wrap_func_input unsafe.Pointer - -func Func_input(arg1 int) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_func_input, _swig_p) - return -} -var _wrap_func_output unsafe.Pointer - -func Func_output(arg1 []int) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_func_output, _swig_p) - return -} -var _wrap_func_inout unsafe.Pointer - -func Func_inout(arg1 []int) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_func_inout, _swig_p) - return -} -var _wrap_FUNC_CB_CALLBACK unsafe.Pointer - -func _swig_getFUNC_CB_CALLBACK() (_swig_ret _swig_fnptr) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_FUNC_CB_CALLBACK, _swig_p) - return -} -var FUNC_CB_CALLBACK _swig_fnptr = _swig_getFUNC_CB_CALLBACK() -var _wrap_func_cb unsafe.Pointer - -func Func_cb(arg1 int, arg2 int) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_func_cb, _swig_p) - return -} -type SwigcptrS uintptr - -func (p SwigcptrS) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrS) SwigIsS() { -} - -var _wrap_S_a_set unsafe.Pointer - -func _swig_wrap_S_a_set(base SwigcptrS, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_S_a_set, _swig_p) - return -} - -func (arg1 SwigcptrS) SetA(arg2 int) { - _swig_wrap_S_a_set(arg1, arg2) -} - -var _wrap_S_a_get unsafe.Pointer - -func _swig_wrap_S_a_get(base SwigcptrS) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_S_a_get, _swig_p) - return -} - -func (arg1 SwigcptrS) GetA() (_swig_ret int) { - return _swig_wrap_S_a_get(arg1) -} - -var _wrap_S_b_set unsafe.Pointer - -func _swig_wrap_S_b_set(base SwigcptrS, _ byte) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_S_b_set, _swig_p) - return -} - -func (arg1 SwigcptrS) SetB(arg2 byte) { - _swig_wrap_S_b_set(arg1, arg2) -} - -var _wrap_S_b_get unsafe.Pointer - -func _swig_wrap_S_b_get(base SwigcptrS) (_ byte) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_S_b_get, _swig_p) - return -} - -func (arg1 SwigcptrS) GetB() (_swig_ret byte) { - return _swig_wrap_S_b_get(arg1) -} - -var _wrap_new_S unsafe.Pointer - -func _swig_wrap_new_S() (base SwigcptrS) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_S, _swig_p) - return -} - -func NewS() (_swig_ret S) { - return _swig_wrap_new_S() -} - -var _wrap_delete_S unsafe.Pointer - -func _swig_wrap_delete_S(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_S, _swig_p) - return -} - -func DeleteS(arg1 S) { - _swig_wrap_delete_S(arg1.Swigcptr()) -} - -type S interface { - Swigcptr() uintptr - SwigIsS() - SetA(arg2 int) - GetA() (_swig_ret int) - SetB(arg2 byte) - GetB() (_swig_ret byte) -} - -var _wrap_banana unsafe.Pointer - -func _swig_wrap_banana(base uintptr, _ uintptr, _ int, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_banana, _swig_p) - return -} - -func Banana(arg1 S, arg2 S, arg3 int, arg4 int) { - _swig_wrap_banana(arg1.Swigcptr(), arg2.Swigcptr(), arg3, arg4) -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/bloody_hell.go b/Examples/test-suite/go/bloody_hell.go deleted file mode 100644 index 563fbe094..000000000 --- a/Examples/test-suite/go/bloody_hell.go +++ /dev/null @@ -1,102 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../bloody_hell.i - -package bloody_hell - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -const KMaxIOCTLSpaceParmsSize int = 128 -type SwigcptrSM_CHANNEL_IX_DUMP_PARMS uintptr - -func (p SwigcptrSM_CHANNEL_IX_DUMP_PARMS) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrSM_CHANNEL_IX_DUMP_PARMS) SwigIsSM_CHANNEL_IX_DUMP_PARMS() { -} - -var _wrap_SM_CHANNEL_IX_DUMP_PARMS_data_set unsafe.Pointer - -func _swig_wrap_SM_CHANNEL_IX_DUMP_PARMS_data_set(base SwigcptrSM_CHANNEL_IX_DUMP_PARMS, _ *uint) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_SM_CHANNEL_IX_DUMP_PARMS_data_set, _swig_p) - return -} - -func (arg1 SwigcptrSM_CHANNEL_IX_DUMP_PARMS) SetData(arg2 *uint) { - _swig_wrap_SM_CHANNEL_IX_DUMP_PARMS_data_set(arg1, arg2) -} - -var _wrap_SM_CHANNEL_IX_DUMP_PARMS_data_get unsafe.Pointer - -func _swig_wrap_SM_CHANNEL_IX_DUMP_PARMS_data_get(base SwigcptrSM_CHANNEL_IX_DUMP_PARMS) (_ *uint) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_SM_CHANNEL_IX_DUMP_PARMS_data_get, _swig_p) - return -} - -func (arg1 SwigcptrSM_CHANNEL_IX_DUMP_PARMS) GetData() (_swig_ret *uint) { - return _swig_wrap_SM_CHANNEL_IX_DUMP_PARMS_data_get(arg1) -} - -var _wrap_new_SM_CHANNEL_IX_DUMP_PARMS unsafe.Pointer - -func _swig_wrap_new_SM_CHANNEL_IX_DUMP_PARMS() (base SwigcptrSM_CHANNEL_IX_DUMP_PARMS) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_SM_CHANNEL_IX_DUMP_PARMS, _swig_p) - return -} - -func NewSM_CHANNEL_IX_DUMP_PARMS() (_swig_ret SM_CHANNEL_IX_DUMP_PARMS) { - return _swig_wrap_new_SM_CHANNEL_IX_DUMP_PARMS() -} - -var _wrap_delete_SM_CHANNEL_IX_DUMP_PARMS unsafe.Pointer - -func _swig_wrap_delete_SM_CHANNEL_IX_DUMP_PARMS(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_SM_CHANNEL_IX_DUMP_PARMS, _swig_p) - return -} - -func DeleteSM_CHANNEL_IX_DUMP_PARMS(arg1 SM_CHANNEL_IX_DUMP_PARMS) { - _swig_wrap_delete_SM_CHANNEL_IX_DUMP_PARMS(arg1.Swigcptr()) -} - -type SM_CHANNEL_IX_DUMP_PARMS interface { - Swigcptr() uintptr - SwigIsSM_CHANNEL_IX_DUMP_PARMS() - SetData(arg2 *uint) - GetData() (_swig_ret *uint) -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/bom_utf8.go b/Examples/test-suite/go/bom_utf8.go deleted file mode 100644 index 9922ea112..000000000 --- a/Examples/test-suite/go/bom_utf8.go +++ /dev/null @@ -1,101 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../bom_utf8.i - -package bom_utf8 - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrNotALotHere uintptr - -func (p SwigcptrNotALotHere) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrNotALotHere) SwigIsNotALotHere() { -} - -var _wrap_NotALotHere_n_set unsafe.Pointer - -func _swig_wrap_NotALotHere_n_set(base SwigcptrNotALotHere, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_NotALotHere_n_set, _swig_p) - return -} - -func (arg1 SwigcptrNotALotHere) SetN(arg2 int) { - _swig_wrap_NotALotHere_n_set(arg1, arg2) -} - -var _wrap_NotALotHere_n_get unsafe.Pointer - -func _swig_wrap_NotALotHere_n_get(base SwigcptrNotALotHere) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_NotALotHere_n_get, _swig_p) - return -} - -func (arg1 SwigcptrNotALotHere) GetN() (_swig_ret int) { - return _swig_wrap_NotALotHere_n_get(arg1) -} - -var _wrap_new_NotALotHere unsafe.Pointer - -func _swig_wrap_new_NotALotHere() (base SwigcptrNotALotHere) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_NotALotHere, _swig_p) - return -} - -func NewNotALotHere() (_swig_ret NotALotHere) { - return _swig_wrap_new_NotALotHere() -} - -var _wrap_delete_NotALotHere unsafe.Pointer - -func _swig_wrap_delete_NotALotHere(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_NotALotHere, _swig_p) - return -} - -func DeleteNotALotHere(arg1 NotALotHere) { - _swig_wrap_delete_NotALotHere(arg1.Swigcptr()) -} - -type NotALotHere interface { - Swigcptr() uintptr - SwigIsNotALotHere() - SetN(arg2 int) - GetN() (_swig_ret int) -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/bools.go b/Examples/test-suite/go/bools.go deleted file mode 100644 index b5a5caef3..000000000 --- a/Examples/test-suite/go/bools.go +++ /dev/null @@ -1,370 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../bools.i - -package bools - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -const Constbool bool = false -var _wrap_bool1_set unsafe.Pointer - -func _swig_wrap_bool1_set(base bool) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_bool1_set, _swig_p) - return -} - -func SetBool1(arg1 bool) { - _swig_wrap_bool1_set(arg1) -} - -var _wrap_bool1_get unsafe.Pointer - -func GetBool1() (_swig_ret bool) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_bool1_get, _swig_p) - return -} -var _wrap_bool2_set unsafe.Pointer - -func _swig_wrap_bool2_set(base bool) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_bool2_set, _swig_p) - return -} - -func SetBool2(arg1 bool) { - _swig_wrap_bool2_set(arg1) -} - -var _wrap_bool2_get unsafe.Pointer - -func GetBool2() (_swig_ret bool) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_bool2_get, _swig_p) - return -} -var _wrap_pbool_set unsafe.Pointer - -func _swig_wrap_pbool_set(base *bool) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_pbool_set, _swig_p) - return -} - -func SetPbool(arg1 *bool) { - _swig_wrap_pbool_set(arg1) -} - -var _wrap_pbool_get unsafe.Pointer - -func GetPbool() (_swig_ret *bool) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_pbool_get, _swig_p) - return -} -var _wrap_rbool_set unsafe.Pointer - -func _swig_wrap_rbool_set(base *bool) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_rbool_set, _swig_p) - return -} - -func SetRbool(arg1 *bool) { - _swig_wrap_rbool_set(arg1) -} - -var _wrap_rbool_get unsafe.Pointer - -func GetRbool() (_swig_ret *bool) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_rbool_get, _swig_p) - return -} -var _wrap_const_pbool_set unsafe.Pointer - -func _swig_wrap_const_pbool_set(base *bool) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_const_pbool_set, _swig_p) - return -} - -func SetConst_pbool(arg1 *bool) { - _swig_wrap_const_pbool_set(arg1) -} - -var _wrap_const_pbool_get unsafe.Pointer - -func GetConst_pbool() (_swig_ret *bool) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_const_pbool_get, _swig_p) - return -} -var _wrap_const_rbool_get unsafe.Pointer - -func GetConst_rbool() (_swig_ret bool) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_const_rbool_get, _swig_p) - return -} -var _wrap_eax unsafe.Pointer - -func Eax() (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_eax, _swig_p) - return -} -var _wrap_bo unsafe.Pointer - -func Bo(arg1 bool) (_swig_ret bool) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_bo, _swig_p) - return -} -var _wrap_rbo unsafe.Pointer - -func Rbo(arg1 *bool) (_swig_ret *bool) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_rbo, _swig_p) - return -} -var _wrap_pbo unsafe.Pointer - -func Pbo(arg1 *bool) (_swig_ret *bool) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_pbo, _swig_p) - return -} -var _wrap_const_rbo unsafe.Pointer - -func Const_rbo(arg1 bool) (_swig_ret bool) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_const_rbo, _swig_p) - return -} -var _wrap_const_pbo unsafe.Pointer - -func Const_pbo(arg1 *bool) (_swig_ret *bool) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_const_pbo, _swig_p) - return -} -var _wrap_value unsafe.Pointer - -func Value(arg1 *bool) (_swig_ret bool) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_value, _swig_p) - return -} -type SwigcptrBoolStructure uintptr - -func (p SwigcptrBoolStructure) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrBoolStructure) SwigIsBoolStructure() { -} - -var _wrap_BoolStructure_m_bool1_set unsafe.Pointer - -func _swig_wrap_BoolStructure_m_bool1_set(base SwigcptrBoolStructure, _ bool) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_BoolStructure_m_bool1_set, _swig_p) - return -} - -func (arg1 SwigcptrBoolStructure) SetM_bool1(arg2 bool) { - _swig_wrap_BoolStructure_m_bool1_set(arg1, arg2) -} - -var _wrap_BoolStructure_m_bool1_get unsafe.Pointer - -func _swig_wrap_BoolStructure_m_bool1_get(base SwigcptrBoolStructure) (_ bool) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_BoolStructure_m_bool1_get, _swig_p) - return -} - -func (arg1 SwigcptrBoolStructure) GetM_bool1() (_swig_ret bool) { - return _swig_wrap_BoolStructure_m_bool1_get(arg1) -} - -var _wrap_BoolStructure_m_bool2_set unsafe.Pointer - -func _swig_wrap_BoolStructure_m_bool2_set(base SwigcptrBoolStructure, _ bool) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_BoolStructure_m_bool2_set, _swig_p) - return -} - -func (arg1 SwigcptrBoolStructure) SetM_bool2(arg2 bool) { - _swig_wrap_BoolStructure_m_bool2_set(arg1, arg2) -} - -var _wrap_BoolStructure_m_bool2_get unsafe.Pointer - -func _swig_wrap_BoolStructure_m_bool2_get(base SwigcptrBoolStructure) (_ bool) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_BoolStructure_m_bool2_get, _swig_p) - return -} - -func (arg1 SwigcptrBoolStructure) GetM_bool2() (_swig_ret bool) { - return _swig_wrap_BoolStructure_m_bool2_get(arg1) -} - -var _wrap_BoolStructure_m_pbool_set unsafe.Pointer - -func _swig_wrap_BoolStructure_m_pbool_set(base SwigcptrBoolStructure, _ *bool) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_BoolStructure_m_pbool_set, _swig_p) - return -} - -func (arg1 SwigcptrBoolStructure) SetM_pbool(arg2 *bool) { - _swig_wrap_BoolStructure_m_pbool_set(arg1, arg2) -} - -var _wrap_BoolStructure_m_pbool_get unsafe.Pointer - -func _swig_wrap_BoolStructure_m_pbool_get(base SwigcptrBoolStructure) (_ *bool) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_BoolStructure_m_pbool_get, _swig_p) - return -} - -func (arg1 SwigcptrBoolStructure) GetM_pbool() (_swig_ret *bool) { - return _swig_wrap_BoolStructure_m_pbool_get(arg1) -} - -var _wrap_BoolStructure_m_rbool_set unsafe.Pointer - -func _swig_wrap_BoolStructure_m_rbool_set(base SwigcptrBoolStructure, _ *bool) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_BoolStructure_m_rbool_set, _swig_p) - return -} - -func (arg1 SwigcptrBoolStructure) SetM_rbool(arg2 *bool) { - _swig_wrap_BoolStructure_m_rbool_set(arg1, arg2) -} - -var _wrap_BoolStructure_m_rbool_get unsafe.Pointer - -func _swig_wrap_BoolStructure_m_rbool_get(base SwigcptrBoolStructure) (_ *bool) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_BoolStructure_m_rbool_get, _swig_p) - return -} - -func (arg1 SwigcptrBoolStructure) GetM_rbool() (_swig_ret *bool) { - return _swig_wrap_BoolStructure_m_rbool_get(arg1) -} - -var _wrap_BoolStructure_m_const_pbool_set unsafe.Pointer - -func _swig_wrap_BoolStructure_m_const_pbool_set(base SwigcptrBoolStructure, _ *bool) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_BoolStructure_m_const_pbool_set, _swig_p) - return -} - -func (arg1 SwigcptrBoolStructure) SetM_const_pbool(arg2 *bool) { - _swig_wrap_BoolStructure_m_const_pbool_set(arg1, arg2) -} - -var _wrap_BoolStructure_m_const_pbool_get unsafe.Pointer - -func _swig_wrap_BoolStructure_m_const_pbool_get(base SwigcptrBoolStructure) (_ *bool) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_BoolStructure_m_const_pbool_get, _swig_p) - return -} - -func (arg1 SwigcptrBoolStructure) GetM_const_pbool() (_swig_ret *bool) { - return _swig_wrap_BoolStructure_m_const_pbool_get(arg1) -} - -var _wrap_BoolStructure_m_const_rbool_get unsafe.Pointer - -func _swig_wrap_BoolStructure_m_const_rbool_get(base SwigcptrBoolStructure) (_ bool) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_BoolStructure_m_const_rbool_get, _swig_p) - return -} - -func (arg1 SwigcptrBoolStructure) GetM_const_rbool() (_swig_ret bool) { - return _swig_wrap_BoolStructure_m_const_rbool_get(arg1) -} - -var _wrap_new_BoolStructure unsafe.Pointer - -func _swig_wrap_new_BoolStructure() (base SwigcptrBoolStructure) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_BoolStructure, _swig_p) - return -} - -func NewBoolStructure() (_swig_ret BoolStructure) { - return _swig_wrap_new_BoolStructure() -} - -var _wrap_delete_BoolStructure unsafe.Pointer - -func _swig_wrap_delete_BoolStructure(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_BoolStructure, _swig_p) - return -} - -func DeleteBoolStructure(arg1 BoolStructure) { - _swig_wrap_delete_BoolStructure(arg1.Swigcptr()) -} - -type BoolStructure interface { - Swigcptr() uintptr - SwigIsBoolStructure() - SetM_bool1(arg2 bool) - GetM_bool1() (_swig_ret bool) - SetM_bool2(arg2 bool) - GetM_bool2() (_swig_ret bool) - SetM_pbool(arg2 *bool) - GetM_pbool() (_swig_ret *bool) - SetM_rbool(arg2 *bool) - GetM_rbool() (_swig_ret *bool) - SetM_const_pbool(arg2 *bool) - GetM_const_pbool() (_swig_ret *bool) - GetM_const_rbool() (_swig_ret bool) -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/c_delete.go b/Examples/test-suite/go/c_delete.go deleted file mode 100644 index 5e98d64a5..000000000 --- a/Examples/test-suite/go/c_delete.go +++ /dev/null @@ -1,120 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../c_delete.i - -package c_delete - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrDelete uintptr - -func (p SwigcptrDelete) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrDelete) SwigIsDelete() { -} - -var _wrap_delete_delete_set unsafe.Pointer - -func _swig_wrap_delete_delete_set(base SwigcptrDelete, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_delete_set, _swig_p) - return -} - -func (arg1 SwigcptrDelete) SetDelete(arg2 int) { - _swig_wrap_delete_delete_set(arg1, arg2) -} - -var _wrap_delete_delete_get unsafe.Pointer - -func _swig_wrap_delete_delete_get(base SwigcptrDelete) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_delete_get, _swig_p) - return -} - -func (arg1 SwigcptrDelete) GetDelete() (_swig_ret int) { - return _swig_wrap_delete_delete_get(arg1) -} - -var _wrap_new_DeleteGlobalVariable unsafe.Pointer - -func _swig_wrap_new_DeleteGlobalVariable() (base SwigcptrDelete) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_DeleteGlobalVariable, _swig_p) - return -} - -func NewDeleteGlobalVariable() (_swig_ret Delete) { - return _swig_wrap_new_DeleteGlobalVariable() -} - -var _wrap_delete_delete unsafe.Pointer - -func _swig_wrap_delete_delete(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_delete, _swig_p) - return -} - -func DeleteDelete(arg1 Delete) { - _swig_wrap_delete_delete(arg1.Swigcptr()) -} - -type Delete interface { - Swigcptr() uintptr - SwigIsDelete() - SetDelete(arg2 int) - GetDelete() (_swig_ret int) -} - -var _wrap_DeleteGlobalVariable_set unsafe.Pointer - -func _swig_wrap_DeleteGlobalVariable_set(base int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_DeleteGlobalVariable_set, _swig_p) - return -} - -func SetDeleteGlobalVariable(arg1 int) { - _swig_wrap_DeleteGlobalVariable_set(arg1) -} - -var _wrap_DeleteGlobalVariable_get unsafe.Pointer - -func GetDeleteGlobalVariable() (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_DeleteGlobalVariable_get, _swig_p) - return -} - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/c_delete_function.go b/Examples/test-suite/go/c_delete_function.go deleted file mode 100644 index 644a6f740..000000000 --- a/Examples/test-suite/go/c_delete_function.go +++ /dev/null @@ -1,36 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../c_delete_function.i - -package c_delete_function - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -var _wrap_delete unsafe.Pointer - -func Delete(arg1 float64) (_swig_ret float64) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_delete, _swig_p) - return -} - diff --git a/Examples/test-suite/go/cast_operator.go b/Examples/test-suite/go/cast_operator.go deleted file mode 100644 index af3cae475..000000000 --- a/Examples/test-suite/go/cast_operator.go +++ /dev/null @@ -1,88 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../cast_operator.i - -package cast_operator - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrA uintptr - -func (p SwigcptrA) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrA) SwigIsA() { -} - -var _wrap_A_tochar unsafe.Pointer - -func _swig_wrap_A_tochar(base SwigcptrA) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_A_tochar, _swig_p) - return -} - -func (arg1 SwigcptrA) Tochar() (_swig_ret string) { - return _swig_wrap_A_tochar(arg1) -} - -var _wrap_new_A unsafe.Pointer - -func _swig_wrap_new_A() (base SwigcptrA) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_A, _swig_p) - return -} - -func NewA() (_swig_ret A) { - return _swig_wrap_new_A() -} - -var _wrap_delete_A unsafe.Pointer - -func _swig_wrap_delete_A(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_A, _swig_p) - return -} - -func DeleteA(arg1 A) { - _swig_wrap_delete_A(arg1.Swigcptr()) -} - -type A interface { - Swigcptr() uintptr - SwigIsA() - Tochar() (_swig_ret string) -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/casts.go b/Examples/test-suite/go/casts.go deleted file mode 100644 index deecb8ce7..000000000 --- a/Examples/test-suite/go/casts.go +++ /dev/null @@ -1,148 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../casts.i - -package casts - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrA uintptr - -func (p SwigcptrA) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrA) SwigIsA() { -} - -var _wrap_new_A unsafe.Pointer - -func _swig_wrap_new_A() (base SwigcptrA) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_A, _swig_p) - return -} - -func NewA() (_swig_ret A) { - return _swig_wrap_new_A() -} - -var _wrap_A_hello unsafe.Pointer - -func _swig_wrap_A_hello(base SwigcptrA) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_A_hello, _swig_p) - return -} - -func (arg1 SwigcptrA) Hello() { - _swig_wrap_A_hello(arg1) -} - -var _wrap_delete_A unsafe.Pointer - -func _swig_wrap_delete_A(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_A, _swig_p) - return -} - -func DeleteA(arg1 A) { - _swig_wrap_delete_A(arg1.Swigcptr()) -} - -type A interface { - Swigcptr() uintptr - SwigIsA() - Hello() -} - -type SwigcptrB uintptr - -func (p SwigcptrB) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrB) SwigIsB() { -} - -var _wrap_new_B unsafe.Pointer - -func _swig_wrap_new_B() (base SwigcptrB) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_B, _swig_p) - return -} - -func NewB() (_swig_ret B) { - return _swig_wrap_new_B() -} - -var _wrap_delete_B unsafe.Pointer - -func _swig_wrap_delete_B(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_B, _swig_p) - return -} - -func DeleteB(arg1 B) { - _swig_wrap_delete_B(arg1.Swigcptr()) -} - -var _wrap_B_hello unsafe.Pointer - -func _swig_wrap_B_hello(base SwigcptrB) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_B_hello, _swig_p) - return -} - -func (_swig_base SwigcptrB) Hello() { - _swig_wrap_B_hello(_swig_base) -} - -func (p SwigcptrB) SwigIsA() { -} - -func (p SwigcptrB) SwigGetA() A { - return SwigcptrA(p.Swigcptr()) -} - -type B interface { - Swigcptr() uintptr - SwigIsB() - Hello() - SwigIsA() - SwigGetA() A -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/catches.go b/Examples/test-suite/go/catches.go deleted file mode 100644 index 259ee5063..000000000 --- a/Examples/test-suite/go/catches.go +++ /dev/null @@ -1,111 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../catches.i - -package catches - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrThreeException uintptr - -func (p SwigcptrThreeException) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrThreeException) SwigIsThreeException() { -} - -var _wrap_new_ThreeException unsafe.Pointer - -func _swig_wrap_new_ThreeException() (base SwigcptrThreeException) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_ThreeException, _swig_p) - return -} - -func NewThreeException() (_swig_ret ThreeException) { - return _swig_wrap_new_ThreeException() -} - -var _wrap_delete_ThreeException unsafe.Pointer - -func _swig_wrap_delete_ThreeException(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_ThreeException, _swig_p) - return -} - -func DeleteThreeException(arg1 ThreeException) { - _swig_wrap_delete_ThreeException(arg1.Swigcptr()) -} - -type ThreeException interface { - Swigcptr() uintptr - SwigIsThreeException() -} - -var _wrap_test_catches unsafe.Pointer - -func _swig_wrap_test_catches(base int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_test_catches, _swig_p) - return -} - -func Test_catches(arg1 int) { - _swig_wrap_test_catches(arg1) -} - -var _wrap_test_exception_specification unsafe.Pointer - -func _swig_wrap_test_exception_specification(base int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_test_exception_specification, _swig_p) - return -} - -func Test_exception_specification(arg1 int) { - _swig_wrap_test_exception_specification(arg1) -} - -var _wrap_test_catches_all unsafe.Pointer - -func _swig_wrap_test_catches_all(base int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_test_catches_all, _swig_p) - return -} - -func Test_catches_all(arg1 int) { - _swig_wrap_test_catches_all(arg1) -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/char_binary.go b/Examples/test-suite/go/char_binary.go deleted file mode 100644 index cd7b82e5e..000000000 --- a/Examples/test-suite/go/char_binary.go +++ /dev/null @@ -1,164 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../char_binary.i - -package char_binary - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrTest uintptr - -func (p SwigcptrTest) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrTest) SwigIsTest() { -} - -var _wrap_Test_strlen unsafe.Pointer - -func _swig_wrap_Test_strlen(base SwigcptrTest, _ string) (_ int64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Test_strlen, _swig_p) - return -} - -func (arg1 SwigcptrTest) Strlen(arg2 string) (_swig_ret int64) { - return _swig_wrap_Test_strlen(arg1, arg2) -} - -var _wrap_new_Test unsafe.Pointer - -func _swig_wrap_new_Test() (base SwigcptrTest) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Test, _swig_p) - return -} - -func NewTest() (_swig_ret Test) { - return _swig_wrap_new_Test() -} - -var _wrap_delete_Test unsafe.Pointer - -func _swig_wrap_delete_Test(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Test, _swig_p) - return -} - -func DeleteTest(arg1 Test) { - _swig_wrap_delete_Test(arg1.Swigcptr()) -} - -type Test interface { - Swigcptr() uintptr - SwigIsTest() - Strlen(arg2 string) (_swig_ret int64) -} - -var _wrap_var_namet_set unsafe.Pointer - -func _swig_wrap_var_namet_set(base string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_var_namet_set, _swig_p) - return -} - -func SetVar_namet(arg1 string) { - _swig_wrap_var_namet_set(arg1) -} - -var _wrap_var_namet_get unsafe.Pointer - -func GetVar_namet() (_swig_ret string) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_var_namet_get, _swig_p) - return -} -var _wrap_var_pchar_set unsafe.Pointer - -func _swig_wrap_var_pchar_set(base string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_var_pchar_set, _swig_p) - return -} - -func SetVar_pchar(arg1 string) { - _swig_wrap_var_pchar_set(arg1) -} - -var _wrap_var_pchar_get unsafe.Pointer - -func GetVar_pchar() (_swig_ret string) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_var_pchar_get, _swig_p) - return -} -var _wrap_new_pchar unsafe.Pointer - -func New_pchar(arg1 int) (_swig_ret *byte) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_new_pchar, _swig_p) - return -} -var _wrap_delete_pchar unsafe.Pointer - -func _swig_wrap_delete_pchar(base *byte) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_pchar, _swig_p) - return -} - -func Delete_pchar(arg1 *byte) { - _swig_wrap_delete_pchar(arg1) -} - -var _wrap_pchar_getitem unsafe.Pointer - -func Pchar_getitem(arg1 *byte, arg2 int) (_swig_ret byte) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_pchar_getitem, _swig_p) - return -} -var _wrap_pchar_setitem unsafe.Pointer - -func _swig_wrap_pchar_setitem(base *byte, _ int, _ byte) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_pchar_setitem, _swig_p) - return -} - -func Pchar_setitem(arg1 *byte, arg2 int, arg3 byte) { - _swig_wrap_pchar_setitem(arg1, arg2, arg3) -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/char_binary_runme b/Examples/test-suite/go/char_binary_runme deleted file mode 100755 index b07ebe5de..000000000 Binary files a/Examples/test-suite/go/char_binary_runme and /dev/null differ diff --git a/Examples/test-suite/go/char_constant.go b/Examples/test-suite/go/char_constant.go deleted file mode 100644 index 0b25d5230..000000000 --- a/Examples/test-suite/go/char_constant.go +++ /dev/null @@ -1,69 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../char_constant.i - -package char_constant - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -const CHAR_CONSTANT byte = 'x' -const STRING_CONSTANT string = "xyzzy" -var _wrap_ESC_CONST unsafe.Pointer - -func _swig_getESC_CONST() (_swig_ret byte) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_ESC_CONST, _swig_p) - return -} -var ESC_CONST byte = _swig_getESC_CONST() -var _wrap_NULL_CONST unsafe.Pointer - -func _swig_getNULL_CONST() (_swig_ret byte) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_NULL_CONST, _swig_p) - return -} -var NULL_CONST byte = _swig_getNULL_CONST() -var _wrap_SPECIALCHAR unsafe.Pointer - -func _swig_getSPECIALCHAR() (_swig_ret byte) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_SPECIALCHAR, _swig_p) - return -} -var SPECIALCHAR byte = _swig_getSPECIALCHAR() -var _wrap_ia_get unsafe.Pointer - -func GetIa() (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_ia_get, _swig_p) - return -} -var _wrap_ib_get unsafe.Pointer - -func GetIb() (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_ib_get, _swig_p) - return -} - diff --git a/Examples/test-suite/go/char_strings.go b/Examples/test-suite/go/char_strings.go deleted file mode 100644 index 42a26c8b2..000000000 --- a/Examples/test-suite/go/char_strings.go +++ /dev/null @@ -1,302 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../char_strings.i - -package char_strings - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -var _wrap_GetCharHeapString unsafe.Pointer - -func GetCharHeapString() (_swig_ret string) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_GetCharHeapString, _swig_p) - return -} -var _wrap_GetConstCharProgramCodeString unsafe.Pointer - -func GetConstCharProgramCodeString() (_swig_ret string) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_GetConstCharProgramCodeString, _swig_p) - return -} -var _wrap_DeleteCharHeapString unsafe.Pointer - -func _swig_wrap_DeleteCharHeapString() { - var _swig_p uintptr - _cgo_runtime_cgocall(_wrap_DeleteCharHeapString, _swig_p) - return -} - -func DeleteCharHeapString() { - _swig_wrap_DeleteCharHeapString() -} - -var _wrap_GetCharStaticString unsafe.Pointer - -func GetCharStaticString() (_swig_ret string) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_GetCharStaticString, _swig_p) - return -} -var _wrap_GetCharStaticStringFixed unsafe.Pointer - -func GetCharStaticStringFixed() (_swig_ret string) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_GetCharStaticStringFixed, _swig_p) - return -} -var _wrap_GetConstCharStaticStringFixed unsafe.Pointer - -func GetConstCharStaticStringFixed() (_swig_ret string) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_GetConstCharStaticStringFixed, _swig_p) - return -} -var _wrap_SetCharHeapString unsafe.Pointer - -func SetCharHeapString(arg1 string, arg2 uint) (_swig_ret bool) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_SetCharHeapString, _swig_p) - return -} -var _wrap_SetCharStaticString unsafe.Pointer - -func SetCharStaticString(arg1 string, arg2 uint) (_swig_ret bool) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_SetCharStaticString, _swig_p) - return -} -var _wrap_SetCharArrayStaticString unsafe.Pointer - -func SetCharArrayStaticString(arg1 string, arg2 uint) (_swig_ret bool) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_SetCharArrayStaticString, _swig_p) - return -} -var _wrap_SetConstCharHeapString unsafe.Pointer - -func SetConstCharHeapString(arg1 string, arg2 uint) (_swig_ret bool) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_SetConstCharHeapString, _swig_p) - return -} -var _wrap_SetConstCharStaticString unsafe.Pointer - -func SetConstCharStaticString(arg1 string, arg2 uint) (_swig_ret bool) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_SetConstCharStaticString, _swig_p) - return -} -var _wrap_SetConstCharArrayStaticString unsafe.Pointer - -func SetConstCharArrayStaticString(arg1 string, arg2 uint) (_swig_ret bool) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_SetConstCharArrayStaticString, _swig_p) - return -} -var _wrap_SetCharConstStaticString unsafe.Pointer - -func SetCharConstStaticString(arg1 string, arg2 uint) (_swig_ret bool) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_SetCharConstStaticString, _swig_p) - return -} -var _wrap_SetConstCharConstStaticString unsafe.Pointer - -func SetConstCharConstStaticString(arg1 string, arg2 uint) (_swig_ret bool) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_SetConstCharConstStaticString, _swig_p) - return -} -var _wrap_CharPingPong unsafe.Pointer - -func CharPingPong(arg1 string) (_swig_ret string) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_CharPingPong, _swig_p) - return -} -var _wrap_CharArrayPingPong unsafe.Pointer - -func CharArrayPingPong(arg1 string) (_swig_ret string) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_CharArrayPingPong, _swig_p) - return -} -var _wrap_CharArrayDimsPingPong unsafe.Pointer - -func CharArrayDimsPingPong(arg1 string) (_swig_ret string) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_CharArrayDimsPingPong, _swig_p) - return -} -var _wrap_global_char_set unsafe.Pointer - -func _swig_wrap_global_char_set(base string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_global_char_set, _swig_p) - return -} - -func SetGlobal_char(arg1 string) { - _swig_wrap_global_char_set(arg1) -} - -var _wrap_global_char_get unsafe.Pointer - -func GetGlobal_char() (_swig_ret string) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_global_char_get, _swig_p) - return -} -var _wrap_global_char_array1_set unsafe.Pointer - -func _swig_wrap_global_char_array1_set(base string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_global_char_array1_set, _swig_p) - return -} - -func SetGlobal_char_array1(arg1 string) { - _swig_wrap_global_char_array1_set(arg1) -} - -var _wrap_global_char_array1_get unsafe.Pointer - -func GetGlobal_char_array1() (_swig_ret string) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_global_char_array1_get, _swig_p) - return -} -var _wrap_global_char_array2_set unsafe.Pointer - -func _swig_wrap_global_char_array2_set(base string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_global_char_array2_set, _swig_p) - return -} - -func SetGlobal_char_array2(arg1 string) { - _swig_wrap_global_char_array2_set(arg1) -} - -var _wrap_global_char_array2_get unsafe.Pointer - -func GetGlobal_char_array2() (_swig_ret string) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_global_char_array2_get, _swig_p) - return -} -var _wrap_global_const_char_get unsafe.Pointer - -func GetGlobal_const_char() (_swig_ret string) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_global_const_char_get, _swig_p) - return -} -var _wrap_global_const_char_array1_get unsafe.Pointer - -func GetGlobal_const_char_array1() (_swig_ret string) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_global_const_char_array1_get, _swig_p) - return -} -var _wrap_global_const_char_array2_get unsafe.Pointer - -func GetGlobal_const_char_array2() (_swig_ret string) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_global_const_char_array2_get, _swig_p) - return -} -var _wrap_GetNewCharString unsafe.Pointer - -func GetNewCharString() (_swig_ret string) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_GetNewCharString, _swig_p) - return -} -var _wrap_GetNextFormat unsafe.Pointer - -func _swig_wrap_GetNextFormat(base uintptr, _ string, _ uintptr) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_GetNextFormat, _swig_p) - return -} - -func GetNextFormat(arg1 Formatpos, arg2 string, arg3 OBFormat) (_swig_ret int) { - return _swig_wrap_GetNextFormat(arg1.Swigcptr(), arg2, arg3.Swigcptr()) -} - -var _wrap_GetCharPointerRef unsafe.Pointer - -func GetCharPointerRef() (_swig_ret string) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_GetCharPointerRef, _swig_p) - return -} -var _wrap_SetCharPointerRef unsafe.Pointer - -func SetCharPointerRef(arg1 string, arg2 uint) (_swig_ret bool) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_SetCharPointerRef, _swig_p) - return -} -var _wrap_GetConstCharPointerRef unsafe.Pointer - -func GetConstCharPointerRef() (_swig_ret string) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_GetConstCharPointerRef, _swig_p) - return -} -var _wrap_SetConstCharPointerRef unsafe.Pointer - -func SetConstCharPointerRef(arg1 string, arg2 uint) (_swig_ret bool) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_SetConstCharPointerRef, _swig_p) - return -} - -type SwigcptrOBFormat uintptr -type OBFormat interface { - Swigcptr() uintptr; -} -func (p SwigcptrOBFormat) Swigcptr() uintptr { - return uintptr(p) -} - -type SwigcptrFormatpos uintptr -type Formatpos interface { - Swigcptr() uintptr; -} -func (p SwigcptrFormatpos) Swigcptr() uintptr { - return uintptr(p) -} - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/class_forward.go b/Examples/test-suite/go/class_forward.go deleted file mode 100644 index d4dd444be..000000000 --- a/Examples/test-suite/go/class_forward.go +++ /dev/null @@ -1,122 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../class_forward.i - -package class_forward - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrA uintptr - -func (p SwigcptrA) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrA) SwigIsA() { -} - -var _wrap_new_A unsafe.Pointer - -func _swig_wrap_new_A() (base SwigcptrA) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_A, _swig_p) - return -} - -func NewA() (_swig_ret A) { - return _swig_wrap_new_A() -} - -var _wrap_delete_A unsafe.Pointer - -func _swig_wrap_delete_A(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_A, _swig_p) - return -} - -func DeleteA(arg1 A) { - _swig_wrap_delete_A(arg1.Swigcptr()) -} - -type A interface { - Swigcptr() uintptr - SwigIsA() -} - -type SwigcptrC uintptr - -func (p SwigcptrC) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrC) SwigIsC() { -} - -var _wrap_new_C unsafe.Pointer - -func _swig_wrap_new_C() (base SwigcptrC) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_C, _swig_p) - return -} - -func NewC() (_swig_ret C) { - return _swig_wrap_new_C() -} - -var _wrap_delete_C unsafe.Pointer - -func _swig_wrap_delete_C(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_C, _swig_p) - return -} - -func DeleteC(arg1 C) { - _swig_wrap_delete_C(arg1.Swigcptr()) -} - -func (p SwigcptrC) SwigIsA() { -} - -func (p SwigcptrC) SwigGetA() A { - return SwigcptrA(p.Swigcptr()) -} - -type C interface { - Swigcptr() uintptr - SwigIsC() - SwigIsA() - SwigGetA() A -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/class_ignore.go b/Examples/test-suite/go/class_ignore.go deleted file mode 100644 index 49e7d04e5..000000000 --- a/Examples/test-suite/go/class_ignore.go +++ /dev/null @@ -1,262 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../class_ignore.i - -package class_ignore - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrBar uintptr - -func (p SwigcptrBar) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrBar) SwigIsBar() { -} - -var _wrap_Bar_blah unsafe.Pointer - -func _swig_wrap_Bar_blah(base SwigcptrBar) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Bar_blah, _swig_p) - return -} - -func (arg1 SwigcptrBar) Blah() (_swig_ret string) { - return _swig_wrap_Bar_blah(arg1) -} - -var _wrap_new_Bar unsafe.Pointer - -func _swig_wrap_new_Bar() (base SwigcptrBar) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Bar, _swig_p) - return -} - -func NewBar() (_swig_ret Bar) { - return _swig_wrap_new_Bar() -} - -var _wrap_delete_Bar unsafe.Pointer - -func _swig_wrap_delete_Bar(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Bar, _swig_p) - return -} - -func DeleteBar(arg1 Bar) { - _swig_wrap_delete_Bar(arg1.Swigcptr()) -} - -type Bar interface { - Swigcptr() uintptr - SwigIsBar() - Blah() (_swig_ret string) -} - -type SwigcptrBoo uintptr - -func (p SwigcptrBoo) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrBoo) SwigIsBoo() { -} - -var _wrap_delete_Boo unsafe.Pointer - -func _swig_wrap_delete_Boo(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Boo, _swig_p) - return -} - -func DeleteBoo(arg1 Boo) { - _swig_wrap_delete_Boo(arg1.Swigcptr()) -} - -var _wrap_Boo_away unsafe.Pointer - -func _swig_wrap_Boo_away(base SwigcptrBoo) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Boo_away, _swig_p) - return -} - -func (arg1 SwigcptrBoo) Away() { - _swig_wrap_Boo_away(arg1) -} - -var _wrap_new_Boo unsafe.Pointer - -func _swig_wrap_new_Boo() (base SwigcptrBoo) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Boo, _swig_p) - return -} - -func NewBoo() (_swig_ret Boo) { - return _swig_wrap_new_Boo() -} - -type Boo interface { - Swigcptr() uintptr - SwigIsBoo() - Away() -} - -type SwigcptrFar uintptr - -func (p SwigcptrFar) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrFar) SwigIsFar() { -} - -var _wrap_new_Far unsafe.Pointer - -func _swig_wrap_new_Far() (base SwigcptrFar) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Far, _swig_p) - return -} - -func NewFar() (_swig_ret Far) { - return _swig_wrap_new_Far() -} - -var _wrap_delete_Far unsafe.Pointer - -func _swig_wrap_delete_Far(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Far, _swig_p) - return -} - -func DeleteFar(arg1 Far) { - _swig_wrap_delete_Far(arg1.Swigcptr()) -} - -func (p SwigcptrFar) SwigIsBoo() { -} - -func (p SwigcptrFar) SwigGetBoo() Boo { - return SwigcptrBoo(p.Swigcptr()) -} - -type Far interface { - Swigcptr() uintptr - SwigIsFar() - SwigIsBoo() - SwigGetBoo() Boo -} - -type SwigcptrHoo uintptr - -func (p SwigcptrHoo) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrHoo) SwigIsHoo() { -} - -var _wrap_new_Hoo unsafe.Pointer - -func _swig_wrap_new_Hoo() (base SwigcptrHoo) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Hoo, _swig_p) - return -} - -func NewHoo() (_swig_ret Hoo) { - return _swig_wrap_new_Hoo() -} - -var _wrap_delete_Hoo unsafe.Pointer - -func _swig_wrap_delete_Hoo(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Hoo, _swig_p) - return -} - -func DeleteHoo(arg1 Hoo) { - _swig_wrap_delete_Hoo(arg1.Swigcptr()) -} - -func (p SwigcptrHoo) SwigIsFar() { -} - -func (p SwigcptrHoo) SwigGetFar() Far { - return SwigcptrFar(p.Swigcptr()) -} - -func (p SwigcptrHoo) SwigIsBoo() { -} - -func (p SwigcptrHoo) SwigGetBoo() Boo { - return SwigcptrBoo(p.Swigcptr()) -} - -type Hoo interface { - Swigcptr() uintptr - SwigIsHoo() - SwigIsFar() - SwigGetFar() Far - SwigIsBoo() - SwigGetBoo() Boo -} - -var _wrap_do_blah unsafe.Pointer - -func _swig_wrap_do_blah(base uintptr) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_do_blah, _swig_p) - return -} - -func Do_blah(arg1 Foo) (_swig_ret string) { - return _swig_wrap_do_blah(arg1.Swigcptr()) -} - - -type SwigcptrFoo uintptr -type Foo interface { - Swigcptr() uintptr; -} -func (p SwigcptrFoo) Swigcptr() uintptr { - return uintptr(p) -} - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/class_ignore_runme b/Examples/test-suite/go/class_ignore_runme deleted file mode 100755 index 7fce83f6f..000000000 Binary files a/Examples/test-suite/go/class_ignore_runme and /dev/null differ diff --git a/Examples/test-suite/go/class_scope_weird.go b/Examples/test-suite/go/class_scope_weird.go deleted file mode 100644 index 93f4295ca..000000000 --- a/Examples/test-suite/go/class_scope_weird.go +++ /dev/null @@ -1,218 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../class_scope_weird.i - -package class_scope_weird - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrFoo uintptr - -func (p SwigcptrFoo) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrFoo) SwigIsFoo() { -} - -var _wrap_new_Foo__SWIG_0 unsafe.Pointer - -func _swig_wrap_new_Foo__SWIG_0() (base SwigcptrFoo) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Foo__SWIG_0, _swig_p) - return -} - -func NewFoo__SWIG_0() (_swig_ret Foo) { - return _swig_wrap_new_Foo__SWIG_0() -} - -var _wrap_new_Foo__SWIG_1 unsafe.Pointer - -func _swig_wrap_new_Foo__SWIG_1(base int) (_ SwigcptrFoo) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Foo__SWIG_1, _swig_p) - return -} - -func NewFoo__SWIG_1(arg1 int) (_swig_ret Foo) { - return _swig_wrap_new_Foo__SWIG_1(arg1) -} - -func NewFoo(a ...interface{}) Foo { - argc := len(a) - if argc == 0 { - return NewFoo__SWIG_0() - } - if argc == 1 { - return NewFoo__SWIG_1(a[0].(int)) - } - panic("No match for overloaded function call") -} - -var _wrap_Foo_bar unsafe.Pointer - -func _swig_wrap_Foo_bar(base SwigcptrFoo, _ int) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_bar, _swig_p) - return -} - -func (arg1 SwigcptrFoo) Bar(arg2 int) (_swig_ret int) { - return _swig_wrap_Foo_bar(arg1, arg2) -} - -var _wrap_delete_Foo unsafe.Pointer - -func _swig_wrap_delete_Foo(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Foo, _swig_p) - return -} - -func DeleteFoo(arg1 Foo) { - _swig_wrap_delete_Foo(arg1.Swigcptr()) -} - -type Foo interface { - Swigcptr() uintptr - SwigIsFoo() - Bar(arg2 int) (_swig_ret int) -} - -type SwigcptrQuat uintptr - -func (p SwigcptrQuat) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrQuat) SwigIsQuat() { -} - -var _wrap_new_Quat__SWIG_0 unsafe.Pointer - -func _swig_wrap_new_Quat__SWIG_0() (base SwigcptrQuat) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Quat__SWIG_0, _swig_p) - return -} - -func NewQuat__SWIG_0() (_swig_ret Quat) { - return _swig_wrap_new_Quat__SWIG_0() -} - -var _wrap_new_Quat__SWIG_1 unsafe.Pointer - -func _swig_wrap_new_Quat__SWIG_1(base float32, _ float32, _ float32, _ float32) (_ SwigcptrQuat) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Quat__SWIG_1, _swig_p) - return -} - -func NewQuat__SWIG_1(arg1 float32, arg2 float32, arg3 float32, arg4 float32) (_swig_ret Quat) { - return _swig_wrap_new_Quat__SWIG_1(arg1, arg2, arg3, arg4) -} - -var _wrap_new_Quat__SWIG_2 unsafe.Pointer - -func _swig_wrap_new_Quat__SWIG_2(base uintptr, _ float32) (_ SwigcptrQuat) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Quat__SWIG_2, _swig_p) - return -} - -func NewQuat__SWIG_2(arg1 Tacka3, arg2 float32) (_swig_ret Quat) { - return _swig_wrap_new_Quat__SWIG_2(arg1.Swigcptr(), arg2) -} - -var _wrap_new_Quat__SWIG_3 unsafe.Pointer - -func _swig_wrap_new_Quat__SWIG_3(base uintptr) (_ SwigcptrQuat) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Quat__SWIG_3, _swig_p) - return -} - -func NewQuat__SWIG_3(arg1 Matrix4) (_swig_ret Quat) { - return _swig_wrap_new_Quat__SWIG_3(arg1.Swigcptr()) -} - -func NewQuat(a ...interface{}) Quat { - argc := len(a) - if argc == 0 { - return NewQuat__SWIG_0() - } - if argc == 1 { - return NewQuat__SWIG_3(a[0].(Matrix4)) - } - if argc == 2 { - return NewQuat__SWIG_2(a[0].(Tacka3), a[1].(float32)) - } - if argc == 4 { - return NewQuat__SWIG_1(a[0].(float32), a[1].(float32), a[2].(float32), a[3].(float32)) - } - panic("No match for overloaded function call") -} - -var _wrap_delete_Quat unsafe.Pointer - -func _swig_wrap_delete_Quat(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Quat, _swig_p) - return -} - -func DeleteQuat(arg1 Quat) { - _swig_wrap_delete_Quat(arg1.Swigcptr()) -} - -type Quat interface { - Swigcptr() uintptr - SwigIsQuat() -} - - -type SwigcptrTacka3 uintptr -type Tacka3 interface { - Swigcptr() uintptr; -} -func (p SwigcptrTacka3) Swigcptr() uintptr { - return uintptr(p) -} - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - -type SwigcptrMatrix4 uintptr -type Matrix4 interface { - Swigcptr() uintptr; -} -func (p SwigcptrMatrix4) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/class_scope_weird_runme b/Examples/test-suite/go/class_scope_weird_runme deleted file mode 100755 index d41c53752..000000000 Binary files a/Examples/test-suite/go/class_scope_weird_runme and /dev/null differ diff --git a/Examples/test-suite/go/clientdata_prop_a.go b/Examples/test-suite/go/clientdata_prop_a.go deleted file mode 100644 index fe029f74f..000000000 --- a/Examples/test-suite/go/clientdata_prop_a.go +++ /dev/null @@ -1,124 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../clientdata_prop_a.i - -package clientdata_prop_a - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrA uintptr - -func (p SwigcptrA) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrA) SwigIsA() { -} - -var _wrap_A_fA unsafe.Pointer - -func _swig_wrap_A_fA(base SwigcptrA) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_A_fA, _swig_p) - return -} - -func (arg1 SwigcptrA) FA() { - _swig_wrap_A_fA(arg1) -} - -var _wrap_new_A unsafe.Pointer - -func _swig_wrap_new_A() (base SwigcptrA) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_A, _swig_p) - return -} - -func NewA() (_swig_ret A) { - return _swig_wrap_new_A() -} - -var _wrap_delete_A unsafe.Pointer - -func _swig_wrap_delete_A(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_A, _swig_p) - return -} - -func DeleteA(arg1 A) { - _swig_wrap_delete_A(arg1.Swigcptr()) -} - -type A interface { - Swigcptr() uintptr - SwigIsA() - FA() -} - -var _wrap_test_A unsafe.Pointer - -func _swig_wrap_test_A(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_test_A, _swig_p) - return -} - -func Test_A(arg1 A) { - _swig_wrap_test_A(arg1.Swigcptr()) -} - -var _wrap_test_tA unsafe.Pointer - -func _swig_wrap_test_tA(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_test_tA, _swig_p) - return -} - -func Test_tA(arg1 A) { - _swig_wrap_test_tA(arg1.Swigcptr()) -} - -var _wrap_new_tA unsafe.Pointer - -func _swig_wrap_new_tA() (base SwigcptrA) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_tA, _swig_p) - return -} - -func New_tA() (_swig_ret A) { - return _swig_wrap_new_tA() -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/clientdata_prop_b.go b/Examples/test-suite/go/clientdata_prop_b.go deleted file mode 100644 index 1d8aa4c73..000000000 --- a/Examples/test-suite/go/clientdata_prop_b.go +++ /dev/null @@ -1,389 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../clientdata_prop_b.i - -package clientdata_prop_b - -import "unsafe" -import _ "runtime/cgo" -import "clientdata_prop_a" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrB uintptr - -func (p SwigcptrB) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrB) SwigIsB() { -} - -var _wrap_B_fB unsafe.Pointer - -func _swig_wrap_B_fB(base SwigcptrB) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_B_fB, _swig_p) - return -} - -func (arg1 SwigcptrB) FB() { - _swig_wrap_B_fB(arg1) -} - -var _wrap_new_B unsafe.Pointer - -func _swig_wrap_new_B() (base SwigcptrB) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_B, _swig_p) - return -} - -func NewB() (_swig_ret B) { - return _swig_wrap_new_B() -} - -var _wrap_delete_B unsafe.Pointer - -func _swig_wrap_delete_B(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_B, _swig_p) - return -} - -func DeleteB(arg1 B) { - _swig_wrap_delete_B(arg1.Swigcptr()) -} - -var _wrap_B_fA unsafe.Pointer - -func _swig_wrap_B_fA(base SwigcptrB) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_B_fA, _swig_p) - return -} - -func (_swig_base SwigcptrB) FA() { - _swig_wrap_B_fA(_swig_base) -} - -func (p SwigcptrB) SwigIsA() { -} - -func (p SwigcptrB) SwigGetA() clientdata_prop_a.A { - return clientdata_prop_a.SwigcptrA(p.Swigcptr()) -} - -type B interface { - Swigcptr() uintptr - SwigIsB() - FB() - FA() - SwigIsA() - SwigGetA() clientdata_prop_a.A -} - -type SwigcptrC uintptr - -func (p SwigcptrC) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrC) SwigIsC() { -} - -var _wrap_C_fC unsafe.Pointer - -func _swig_wrap_C_fC(base SwigcptrC) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_C_fC, _swig_p) - return -} - -func (arg1 SwigcptrC) FC() { - _swig_wrap_C_fC(arg1) -} - -var _wrap_new_C unsafe.Pointer - -func _swig_wrap_new_C() (base SwigcptrC) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_C, _swig_p) - return -} - -func NewC() (_swig_ret C) { - return _swig_wrap_new_C() -} - -var _wrap_delete_C unsafe.Pointer - -func _swig_wrap_delete_C(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_C, _swig_p) - return -} - -func DeleteC(arg1 C) { - _swig_wrap_delete_C(arg1.Swigcptr()) -} - -var _wrap_C_fA unsafe.Pointer - -func _swig_wrap_C_fA(base SwigcptrC) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_C_fA, _swig_p) - return -} - -func (_swig_base SwigcptrC) FA() { - _swig_wrap_C_fA(_swig_base) -} - -func (p SwigcptrC) SwigIsA() { -} - -func (p SwigcptrC) SwigGetA() clientdata_prop_a.A { - return clientdata_prop_a.SwigcptrA(p.Swigcptr()) -} - -type C interface { - Swigcptr() uintptr - SwigIsC() - FC() - FA() - SwigIsA() - SwigGetA() clientdata_prop_a.A -} - -type SwigcptrD uintptr - -func (p SwigcptrD) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrD) SwigIsD() { -} - -var _wrap_D_fD unsafe.Pointer - -func _swig_wrap_D_fD(base SwigcptrD) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_D_fD, _swig_p) - return -} - -func (arg1 SwigcptrD) FD() { - _swig_wrap_D_fD(arg1) -} - -var _wrap_new_D unsafe.Pointer - -func _swig_wrap_new_D() (base SwigcptrD) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_D, _swig_p) - return -} - -func NewD() (_swig_ret D) { - return _swig_wrap_new_D() -} - -var _wrap_delete_D unsafe.Pointer - -func _swig_wrap_delete_D(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_D, _swig_p) - return -} - -func DeleteD(arg1 D) { - _swig_wrap_delete_D(arg1.Swigcptr()) -} - -var _wrap_D_fA unsafe.Pointer - -func _swig_wrap_D_fA(base SwigcptrD) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_D_fA, _swig_p) - return -} - -func (_swig_base SwigcptrD) FA() { - _swig_wrap_D_fA(_swig_base) -} - -func (p SwigcptrD) SwigIsA() { -} - -func (p SwigcptrD) SwigGetA() clientdata_prop_a.A { - return clientdata_prop_a.SwigcptrA(p.Swigcptr()) -} - -type D interface { - Swigcptr() uintptr - SwigIsD() - FD() - FA() - SwigIsA() - SwigGetA() clientdata_prop_a.A -} - -var _wrap_test_t2A unsafe.Pointer - -func _swig_wrap_test_t2A(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_test_t2A, _swig_p) - return -} - -func Test_t2A(arg1 clientdata_prop_a.A) { - _swig_wrap_test_t2A(arg1.Swigcptr()) -} - -var _wrap_test_t3A unsafe.Pointer - -func _swig_wrap_test_t3A(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_test_t3A, _swig_p) - return -} - -func Test_t3A(arg1 clientdata_prop_a.A) { - _swig_wrap_test_t3A(arg1.Swigcptr()) -} - -var _wrap_test_B unsafe.Pointer - -func _swig_wrap_test_B(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_test_B, _swig_p) - return -} - -func Test_B(arg1 B) { - _swig_wrap_test_B(arg1.Swigcptr()) -} - -var _wrap_test_C unsafe.Pointer - -func _swig_wrap_test_C(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_test_C, _swig_p) - return -} - -func Test_C(arg1 C) { - _swig_wrap_test_C(arg1.Swigcptr()) -} - -var _wrap_test_D unsafe.Pointer - -func _swig_wrap_test_D(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_test_D, _swig_p) - return -} - -func Test_D(arg1 D) { - _swig_wrap_test_D(arg1.Swigcptr()) -} - -var _wrap_test_tD unsafe.Pointer - -func _swig_wrap_test_tD(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_test_tD, _swig_p) - return -} - -func Test_tD(arg1 D) { - _swig_wrap_test_tD(arg1.Swigcptr()) -} - -var _wrap_test_t2D unsafe.Pointer - -func _swig_wrap_test_t2D(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_test_t2D, _swig_p) - return -} - -func Test_t2D(arg1 D) { - _swig_wrap_test_t2D(arg1.Swigcptr()) -} - -var _wrap_new_t2A unsafe.Pointer - -func _swig_wrap_new_t2A() (base clientdata_prop_a.SwigcptrA) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_t2A, _swig_p) - return -} - -func New_t2A() (_swig_ret clientdata_prop_a.A) { - return _swig_wrap_new_t2A() -} - -var _wrap_new_t3A unsafe.Pointer - -func _swig_wrap_new_t3A() (base clientdata_prop_a.SwigcptrA) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_t3A, _swig_p) - return -} - -func New_t3A() (_swig_ret clientdata_prop_a.A) { - return _swig_wrap_new_t3A() -} - -var _wrap_new_tD unsafe.Pointer - -func _swig_wrap_new_tD() (base SwigcptrD) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_tD, _swig_p) - return -} - -func New_tD() (_swig_ret D) { - return _swig_wrap_new_tD() -} - -var _wrap_new_t2D unsafe.Pointer - -func _swig_wrap_new_t2D() (base SwigcptrD) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_t2D, _swig_p) - return -} - -func New_t2D() (_swig_ret D) { - return _swig_wrap_new_t2D() -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/compactdefaultargs.go b/Examples/test-suite/go/compactdefaultargs.go deleted file mode 100644 index 097295db9..000000000 --- a/Examples/test-suite/go/compactdefaultargs.go +++ /dev/null @@ -1,226 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../compactdefaultargs.i - -package compactdefaultargs - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrDefaults1 uintptr - -func (p SwigcptrDefaults1) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrDefaults1) SwigIsDefaults1() { -} - -var _wrap_Defaults1_PUBLIC_DEFAULT_get unsafe.Pointer - -func GetDefaults1PUBLIC_DEFAULT() (_swig_ret float64) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_Defaults1_PUBLIC_DEFAULT_get, _swig_p) - return -} -var _wrap_new_Defaults1__SWIG_0 unsafe.Pointer - -func _swig_wrap_new_Defaults1__SWIG_0(base int) (_ SwigcptrDefaults1) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Defaults1__SWIG_0, _swig_p) - return -} - -func NewDefaults1__SWIG_0(arg1 int) (_swig_ret Defaults1) { - return _swig_wrap_new_Defaults1__SWIG_0(arg1) -} - -var _wrap_new_Defaults1__SWIG_1 unsafe.Pointer - -func _swig_wrap_new_Defaults1__SWIG_1() (base SwigcptrDefaults1) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Defaults1__SWIG_1, _swig_p) - return -} - -func NewDefaults1__SWIG_1() (_swig_ret Defaults1) { - return _swig_wrap_new_Defaults1__SWIG_1() -} - -func NewDefaults1(a ...interface{}) Defaults1 { - argc := len(a) - if argc == 0 { - return NewDefaults1__SWIG_1() - } - if argc == 1 { - return NewDefaults1__SWIG_0(a[0].(int)) - } - panic("No match for overloaded function call") -} - -var _wrap_Defaults1_ret__SWIG_0 unsafe.Pointer - -func _swig_wrap_Defaults1_ret__SWIG_0(base SwigcptrDefaults1, _ float64) (_ float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Defaults1_ret__SWIG_0, _swig_p) - return -} - -func (arg1 SwigcptrDefaults1) Ret__SWIG_0(arg2 float64) (_swig_ret float64) { - return _swig_wrap_Defaults1_ret__SWIG_0(arg1, arg2) -} - -var _wrap_Defaults1_ret__SWIG_1 unsafe.Pointer - -func _swig_wrap_Defaults1_ret__SWIG_1(base SwigcptrDefaults1) (_ float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Defaults1_ret__SWIG_1, _swig_p) - return -} - -func (arg1 SwigcptrDefaults1) Ret__SWIG_1() (_swig_ret float64) { - return _swig_wrap_Defaults1_ret__SWIG_1(arg1) -} - -func (p SwigcptrDefaults1) Ret(a ...interface{}) float64 { - argc := len(a) - if argc == 0 { - return p.Ret__SWIG_1() - } - if argc == 1 { - return p.Ret__SWIG_0(a[0].(float64)) - } - panic("No match for overloaded function call") -} - -var _wrap_delete_Defaults1 unsafe.Pointer - -func _swig_wrap_delete_Defaults1(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Defaults1, _swig_p) - return -} - -func DeleteDefaults1(arg1 Defaults1) { - _swig_wrap_delete_Defaults1(arg1.Swigcptr()) -} - -type Defaults1 interface { - Swigcptr() uintptr - SwigIsDefaults1() - Ret(a ...interface{}) float64 -} - -type SwigcptrDefaults2 uintptr - -func (p SwigcptrDefaults2) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrDefaults2) SwigIsDefaults2() { -} - -var _wrap_Defaults2_PUBLIC_DEFAULT_get unsafe.Pointer - -func GetDefaults2PUBLIC_DEFAULT() (_swig_ret float64) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_Defaults2_PUBLIC_DEFAULT_get, _swig_p) - return -} -var _wrap_new_Defaults2__SWIG_0 unsafe.Pointer - -func _swig_wrap_new_Defaults2__SWIG_0(base int) (_ SwigcptrDefaults2) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Defaults2__SWIG_0, _swig_p) - return -} - -func NewDefaults2__SWIG_0(arg1 int) (_swig_ret Defaults2) { - return _swig_wrap_new_Defaults2__SWIG_0(arg1) -} - -var _wrap_new_Defaults2__SWIG_1 unsafe.Pointer - -func _swig_wrap_new_Defaults2__SWIG_1() (base SwigcptrDefaults2) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Defaults2__SWIG_1, _swig_p) - return -} - -func NewDefaults2__SWIG_1() (_swig_ret Defaults2) { - return _swig_wrap_new_Defaults2__SWIG_1() -} - -func NewDefaults2(a ...interface{}) Defaults2 { - argc := len(a) - if argc == 0 { - return NewDefaults2__SWIG_1() - } - if argc == 1 { - return NewDefaults2__SWIG_0(a[0].(int)) - } - panic("No match for overloaded function call") -} - -var _wrap_Defaults2_ret unsafe.Pointer - -func _swig_wrap_Defaults2_ret(base int, _ SwigcptrDefaults2, _ float64) (_ float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Defaults2_ret, _swig_p) - return -} - -func (arg1 SwigcptrDefaults2) Ret(_swig_args ...interface{}) (_swig_ret float64) { - var arg2 float64 - if len(_swig_args) > 0 { - arg2 = _swig_args[0].(float64) - } - return _swig_wrap_Defaults2_ret(len(_swig_args), arg1, arg2) -} - -var _wrap_delete_Defaults2 unsafe.Pointer - -func _swig_wrap_delete_Defaults2(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Defaults2, _swig_p) - return -} - -func DeleteDefaults2(arg1 Defaults2) { - _swig_wrap_delete_Defaults2(arg1.Swigcptr()) -} - -type Defaults2 interface { - Swigcptr() uintptr - SwigIsDefaults2() - Ret(_swig_args ...interface{}) (_swig_ret float64) -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/compactdefaultargs_runme b/Examples/test-suite/go/compactdefaultargs_runme deleted file mode 100755 index 2f4b8c591..000000000 Binary files a/Examples/test-suite/go/compactdefaultargs_runme and /dev/null differ diff --git a/Examples/test-suite/go/const_const.go b/Examples/test-suite/go/const_const.go deleted file mode 100644 index 2aa8ce702..000000000 --- a/Examples/test-suite/go/const_const.go +++ /dev/null @@ -1,49 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../const_const.i - -package const_const - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -var _wrap_foo unsafe.Pointer - -func _swig_wrap_foo(base *int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_foo, _swig_p) - return -} - -func Foo(arg1 *int) { - _swig_wrap_foo(arg1) -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/const_const_2.go b/Examples/test-suite/go/const_const_2.go deleted file mode 100644 index 4e87068e7..000000000 --- a/Examples/test-suite/go/const_const_2.go +++ /dev/null @@ -1,126 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../const_const_2.i - -package const_const_2 - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrSpam uintptr - -func (p SwigcptrSpam) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrSpam) SwigIsSpam() { -} - -var _wrap_new_Spam unsafe.Pointer - -func _swig_wrap_new_Spam() (base SwigcptrSpam) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Spam, _swig_p) - return -} - -func NewSpam() (_swig_ret Spam) { - return _swig_wrap_new_Spam() -} - -var _wrap_delete_Spam unsafe.Pointer - -func _swig_wrap_delete_Spam(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Spam, _swig_p) - return -} - -func DeleteSpam(arg1 Spam) { - _swig_wrap_delete_Spam(arg1.Swigcptr()) -} - -type Spam interface { - Swigcptr() uintptr - SwigIsSpam() -} - -type SwigcptrEggs uintptr - -func (p SwigcptrEggs) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrEggs) SwigIsEggs() { -} - -var _wrap_new_Eggs unsafe.Pointer - -func _swig_wrap_new_Eggs() (base SwigcptrEggs) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Eggs, _swig_p) - return -} - -func NewEggs() (_swig_ret Eggs) { - return _swig_wrap_new_Eggs() -} - -var _wrap_Eggs_spam unsafe.Pointer - -func _swig_wrap_Eggs_spam(base SwigcptrEggs) (_ SwigcptrSpam) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Eggs_spam, _swig_p) - return -} - -func (arg1 SwigcptrEggs) Spam() (_swig_ret Spam) { - return _swig_wrap_Eggs_spam(arg1) -} - -var _wrap_delete_Eggs unsafe.Pointer - -func _swig_wrap_delete_Eggs(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Eggs, _swig_p) - return -} - -func DeleteEggs(arg1 Eggs) { - _swig_wrap_delete_Eggs(arg1.Swigcptr()) -} - -type Eggs interface { - Swigcptr() uintptr - SwigIsEggs() - Spam() (_swig_ret Spam) -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/constant_expr.go b/Examples/test-suite/go/constant_expr.go deleted file mode 100644 index 2a2cf24b8..000000000 --- a/Examples/test-suite/go/constant_expr.go +++ /dev/null @@ -1,71 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../constant_expr.i - -package constant_expr - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -var _wrap_X_get unsafe.Pointer - -func GetX() (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_X_get, _swig_p) - return -} -var _wrap_FOO unsafe.Pointer - -func _swig_getFOO() (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_FOO, _swig_p) - return -} -var FOO int = _swig_getFOO() -var _wrap_d_array_set unsafe.Pointer - -func _swig_wrap_d_array_set(base *float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_d_array_set, _swig_p) - return -} - -func SetD_array(arg1 *float64) { - _swig_wrap_d_array_set(arg1) -} - -var _wrap_d_array_get unsafe.Pointer - -func GetD_array() (_swig_ret *float64) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_d_array_get, _swig_p) - return -} - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/constant_pointers.go b/Examples/test-suite/go/constant_pointers.go deleted file mode 100644 index c92c3b1ff..000000000 --- a/Examples/test-suite/go/constant_pointers.go +++ /dev/null @@ -1,1327 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../constant_pointers.i - -package constant_pointers - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -var _wrap_GlobalInt_set unsafe.Pointer - -func _swig_wrap_GlobalInt_set(base int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_GlobalInt_set, _swig_p) - return -} - -func SetGlobalInt(arg1 int) { - _swig_wrap_GlobalInt_set(arg1) -} - -var _wrap_GlobalInt_get unsafe.Pointer - -func GetGlobalInt() (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_GlobalInt_get, _swig_p) - return -} -var _wrap_ConstInt_get unsafe.Pointer - -func GetConstInt() (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_ConstInt_get, _swig_p) - return -} -var _wrap_GlobalIntPtr_set unsafe.Pointer - -func _swig_wrap_GlobalIntPtr_set(base *int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_GlobalIntPtr_set, _swig_p) - return -} - -func SetGlobalIntPtr(arg1 *int) { - _swig_wrap_GlobalIntPtr_set(arg1) -} - -var _wrap_GlobalIntPtr_get unsafe.Pointer - -func GetGlobalIntPtr() (_swig_ret *int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_GlobalIntPtr_get, _swig_p) - return -} -var _wrap_GlobalConstIntPtr_get unsafe.Pointer - -func GetGlobalConstIntPtr() (_swig_ret *int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_GlobalConstIntPtr_get, _swig_p) - return -} -const ARRAY_SIZE int = 2 -type SwigcptrParametersTest uintptr - -func (p SwigcptrParametersTest) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrParametersTest) SwigIsParametersTest() { -} - -var _wrap_ParametersTest_param1 unsafe.Pointer - -func _swig_wrap_ParametersTest_param1(base SwigcptrParametersTest, _ *int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_ParametersTest_param1, _swig_p) - return -} - -func (arg1 SwigcptrParametersTest) Param1(arg2 *int) { - _swig_wrap_ParametersTest_param1(arg1, arg2) -} - -var _wrap_ParametersTest_param2 unsafe.Pointer - -func _swig_wrap_ParametersTest_param2(base SwigcptrParametersTest, _ *int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_ParametersTest_param2, _swig_p) - return -} - -func (arg1 SwigcptrParametersTest) Param2(arg2 *int) { - _swig_wrap_ParametersTest_param2(arg1, arg2) -} - -var _wrap_ParametersTest_param3 unsafe.Pointer - -func _swig_wrap_ParametersTest_param3(base SwigcptrParametersTest, _ *int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_ParametersTest_param3, _swig_p) - return -} - -func (arg1 SwigcptrParametersTest) Param3(arg2 *int) { - _swig_wrap_ParametersTest_param3(arg1, arg2) -} - -var _wrap_ParametersTest_param4 unsafe.Pointer - -func _swig_wrap_ParametersTest_param4(base SwigcptrParametersTest, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_ParametersTest_param4, _swig_p) - return -} - -func (arg1 SwigcptrParametersTest) Param4(arg2 int) { - _swig_wrap_ParametersTest_param4(arg1, arg2) -} - -var _wrap_ParametersTest_param5 unsafe.Pointer - -func _swig_wrap_ParametersTest_param5(base SwigcptrParametersTest, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_ParametersTest_param5, _swig_p) - return -} - -func (arg1 SwigcptrParametersTest) Param5(arg2 int) { - _swig_wrap_ParametersTest_param5(arg1, arg2) -} - -var _wrap_ParametersTest_param6 unsafe.Pointer - -func _swig_wrap_ParametersTest_param6(base SwigcptrParametersTest, _ *int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_ParametersTest_param6, _swig_p) - return -} - -func (arg1 SwigcptrParametersTest) Param6(arg2 *int) { - _swig_wrap_ParametersTest_param6(arg1, arg2) -} - -var _wrap_ParametersTest_param7 unsafe.Pointer - -func _swig_wrap_ParametersTest_param7(base SwigcptrParametersTest, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_ParametersTest_param7, _swig_p) - return -} - -func (arg1 SwigcptrParametersTest) Param7(arg2 int) { - _swig_wrap_ParametersTest_param7(arg1, arg2) -} - -var _wrap_ParametersTest_param8 unsafe.Pointer - -func _swig_wrap_ParametersTest_param8(base SwigcptrParametersTest, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_ParametersTest_param8, _swig_p) - return -} - -func (arg1 SwigcptrParametersTest) Param8(arg2 int) { - _swig_wrap_ParametersTest_param8(arg1, arg2) -} - -var _wrap_ParametersTest_param9 unsafe.Pointer - -func _swig_wrap_ParametersTest_param9(base SwigcptrParametersTest, _ **int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_ParametersTest_param9, _swig_p) - return -} - -func (arg1 SwigcptrParametersTest) Param9(arg2 **int) { - _swig_wrap_ParametersTest_param9(arg1, arg2) -} - -var _wrap_ParametersTest_param10 unsafe.Pointer - -func _swig_wrap_ParametersTest_param10(base SwigcptrParametersTest, _ *int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_ParametersTest_param10, _swig_p) - return -} - -func (arg1 SwigcptrParametersTest) Param10(arg2 *int) { - _swig_wrap_ParametersTest_param10(arg1, arg2) -} - -var _wrap_ParametersTest_param11 unsafe.Pointer - -func _swig_wrap_ParametersTest_param11(base SwigcptrParametersTest, _ *int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_ParametersTest_param11, _swig_p) - return -} - -func (arg1 SwigcptrParametersTest) Param11(arg2 *int) { - _swig_wrap_ParametersTest_param11(arg1, arg2) -} - -var _wrap_ParametersTest_param_array1 unsafe.Pointer - -func _swig_wrap_ParametersTest_param_array1(base SwigcptrParametersTest, _ **int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_ParametersTest_param_array1, _swig_p) - return -} - -func (arg1 SwigcptrParametersTest) Param_array1(arg2 **int) { - _swig_wrap_ParametersTest_param_array1(arg1, arg2) -} - -var _wrap_ParametersTest_param_array2 unsafe.Pointer - -func _swig_wrap_ParametersTest_param_array2(base SwigcptrParametersTest, _ **int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_ParametersTest_param_array2, _swig_p) - return -} - -func (arg1 SwigcptrParametersTest) Param_array2(arg2 **int) { - _swig_wrap_ParametersTest_param_array2(arg1, arg2) -} - -var _wrap_ParametersTest_param_array3 unsafe.Pointer - -func _swig_wrap_ParametersTest_param_array3(base SwigcptrParametersTest, _ **int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_ParametersTest_param_array3, _swig_p) - return -} - -func (arg1 SwigcptrParametersTest) Param_array3(arg2 **int) { - _swig_wrap_ParametersTest_param_array3(arg1, arg2) -} - -var _wrap_ParametersTest_param_array4 unsafe.Pointer - -func _swig_wrap_ParametersTest_param_array4(base SwigcptrParametersTest, _ *int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_ParametersTest_param_array4, _swig_p) - return -} - -func (arg1 SwigcptrParametersTest) Param_array4(arg2 *int) { - _swig_wrap_ParametersTest_param_array4(arg1, arg2) -} - -var _wrap_ParametersTest_param_array5 unsafe.Pointer - -func _swig_wrap_ParametersTest_param_array5(base SwigcptrParametersTest, _ *int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_ParametersTest_param_array5, _swig_p) - return -} - -func (arg1 SwigcptrParametersTest) Param_array5(arg2 *int) { - _swig_wrap_ParametersTest_param_array5(arg1, arg2) -} - -var _wrap_ParametersTest_param_array6 unsafe.Pointer - -func _swig_wrap_ParametersTest_param_array6(base SwigcptrParametersTest, _ **int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_ParametersTest_param_array6, _swig_p) - return -} - -func (arg1 SwigcptrParametersTest) Param_array6(arg2 **int) { - _swig_wrap_ParametersTest_param_array6(arg1, arg2) -} - -var _wrap_new_ParametersTest unsafe.Pointer - -func _swig_wrap_new_ParametersTest() (base SwigcptrParametersTest) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_ParametersTest, _swig_p) - return -} - -func NewParametersTest() (_swig_ret ParametersTest) { - return _swig_wrap_new_ParametersTest() -} - -var _wrap_delete_ParametersTest unsafe.Pointer - -func _swig_wrap_delete_ParametersTest(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_ParametersTest, _swig_p) - return -} - -func DeleteParametersTest(arg1 ParametersTest) { - _swig_wrap_delete_ParametersTest(arg1.Swigcptr()) -} - -type ParametersTest interface { - Swigcptr() uintptr - SwigIsParametersTest() - Param1(arg2 *int) - Param2(arg2 *int) - Param3(arg2 *int) - Param4(arg2 int) - Param5(arg2 int) - Param6(arg2 *int) - Param7(arg2 int) - Param8(arg2 int) - Param9(arg2 **int) - Param10(arg2 *int) - Param11(arg2 *int) - Param_array1(arg2 **int) - Param_array2(arg2 **int) - Param_array3(arg2 **int) - Param_array4(arg2 *int) - Param_array5(arg2 *int) - Param_array6(arg2 **int) -} - -type SwigcptrMemberVariablesTest uintptr - -func (p SwigcptrMemberVariablesTest) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrMemberVariablesTest) SwigIsMemberVariablesTest() { -} - -var _wrap_MemberVariablesTest_member1_set unsafe.Pointer - -func _swig_wrap_MemberVariablesTest_member1_set(base SwigcptrMemberVariablesTest, _ *int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_MemberVariablesTest_member1_set, _swig_p) - return -} - -func (arg1 SwigcptrMemberVariablesTest) SetMember1(arg2 *int) { - _swig_wrap_MemberVariablesTest_member1_set(arg1, arg2) -} - -var _wrap_MemberVariablesTest_member1_get unsafe.Pointer - -func _swig_wrap_MemberVariablesTest_member1_get(base SwigcptrMemberVariablesTest) (_ *int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_MemberVariablesTest_member1_get, _swig_p) - return -} - -func (arg1 SwigcptrMemberVariablesTest) GetMember1() (_swig_ret *int) { - return _swig_wrap_MemberVariablesTest_member1_get(arg1) -} - -var _wrap_MemberVariablesTest_member2_set unsafe.Pointer - -func _swig_wrap_MemberVariablesTest_member2_set(base SwigcptrMemberVariablesTest, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_MemberVariablesTest_member2_set, _swig_p) - return -} - -func (arg1 SwigcptrMemberVariablesTest) SetMember2(arg2 ParametersTest) { - _swig_wrap_MemberVariablesTest_member2_set(arg1, arg2.Swigcptr()) -} - -var _wrap_MemberVariablesTest_member2_get unsafe.Pointer - -func _swig_wrap_MemberVariablesTest_member2_get(base SwigcptrMemberVariablesTest) (_ SwigcptrParametersTest) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_MemberVariablesTest_member2_get, _swig_p) - return -} - -func (arg1 SwigcptrMemberVariablesTest) GetMember2() (_swig_ret ParametersTest) { - return _swig_wrap_MemberVariablesTest_member2_get(arg1) -} - -var _wrap_MemberVariablesTest_member3_get unsafe.Pointer - -func _swig_wrap_MemberVariablesTest_member3_get(base SwigcptrMemberVariablesTest) (_ *int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_MemberVariablesTest_member3_get, _swig_p) - return -} - -func (arg1 SwigcptrMemberVariablesTest) GetMember3() (_swig_ret *int) { - return _swig_wrap_MemberVariablesTest_member3_get(arg1) -} - -var _wrap_MemberVariablesTest_member4_get unsafe.Pointer - -func _swig_wrap_MemberVariablesTest_member4_get(base SwigcptrMemberVariablesTest) (_ SwigcptrParametersTest) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_MemberVariablesTest_member4_get, _swig_p) - return -} - -func (arg1 SwigcptrMemberVariablesTest) GetMember4() (_swig_ret ParametersTest) { - return _swig_wrap_MemberVariablesTest_member4_get(arg1) -} - -var _wrap_MemberVariablesTest_array_member1_set unsafe.Pointer - -func _swig_wrap_MemberVariablesTest_array_member1_set(base SwigcptrMemberVariablesTest, _ **int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_MemberVariablesTest_array_member1_set, _swig_p) - return -} - -func (arg1 SwigcptrMemberVariablesTest) SetArray_member1(arg2 **int) { - _swig_wrap_MemberVariablesTest_array_member1_set(arg1, arg2) -} - -var _wrap_MemberVariablesTest_array_member1_get unsafe.Pointer - -func _swig_wrap_MemberVariablesTest_array_member1_get(base SwigcptrMemberVariablesTest) (_ **int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_MemberVariablesTest_array_member1_get, _swig_p) - return -} - -func (arg1 SwigcptrMemberVariablesTest) GetArray_member1() (_swig_ret **int) { - return _swig_wrap_MemberVariablesTest_array_member1_get(arg1) -} - -var _wrap_MemberVariablesTest_array_member2_set unsafe.Pointer - -func _swig_wrap_MemberVariablesTest_array_member2_set(base SwigcptrMemberVariablesTest, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_MemberVariablesTest_array_member2_set, _swig_p) - return -} - -func (arg1 SwigcptrMemberVariablesTest) SetArray_member2(arg2 ParametersTest) { - _swig_wrap_MemberVariablesTest_array_member2_set(arg1, arg2.Swigcptr()) -} - -var _wrap_MemberVariablesTest_array_member2_get unsafe.Pointer - -func _swig_wrap_MemberVariablesTest_array_member2_get(base SwigcptrMemberVariablesTest) (_ SwigcptrParametersTest) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_MemberVariablesTest_array_member2_get, _swig_p) - return -} - -func (arg1 SwigcptrMemberVariablesTest) GetArray_member2() (_swig_ret ParametersTest) { - return _swig_wrap_MemberVariablesTest_array_member2_get(arg1) -} - -var _wrap_new_MemberVariablesTest unsafe.Pointer - -func _swig_wrap_new_MemberVariablesTest() (base SwigcptrMemberVariablesTest) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_MemberVariablesTest, _swig_p) - return -} - -func NewMemberVariablesTest() (_swig_ret MemberVariablesTest) { - return _swig_wrap_new_MemberVariablesTest() -} - -var _wrap_delete_MemberVariablesTest unsafe.Pointer - -func _swig_wrap_delete_MemberVariablesTest(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_MemberVariablesTest, _swig_p) - return -} - -func DeleteMemberVariablesTest(arg1 MemberVariablesTest) { - _swig_wrap_delete_MemberVariablesTest(arg1.Swigcptr()) -} - -type MemberVariablesTest interface { - Swigcptr() uintptr - SwigIsMemberVariablesTest() - SetMember1(arg2 *int) - GetMember1() (_swig_ret *int) - SetMember2(arg2 ParametersTest) - GetMember2() (_swig_ret ParametersTest) - GetMember3() (_swig_ret *int) - GetMember4() (_swig_ret ParametersTest) - SetArray_member1(arg2 **int) - GetArray_member1() (_swig_ret **int) - SetArray_member2(arg2 ParametersTest) - GetArray_member2() (_swig_ret ParametersTest) -} - -var _wrap_foofunction unsafe.Pointer - -func _swig_wrap_foofunction(base *int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_foofunction, _swig_p) - return -} - -func Foofunction(arg1 *int) { - _swig_wrap_foofunction(arg1) -} - -var _wrap_int1_set unsafe.Pointer - -func _swig_wrap_int1_set(base int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_int1_set, _swig_p) - return -} - -func SetInt1(arg1 int) { - _swig_wrap_int1_set(arg1) -} - -var _wrap_int1_get unsafe.Pointer - -func GetInt1() (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_int1_get, _swig_p) - return -} -var _wrap_int2_set unsafe.Pointer - -func _swig_wrap_int2_set(base int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_int2_set, _swig_p) - return -} - -func SetInt2(arg1 int) { - _swig_wrap_int2_set(arg1) -} - -var _wrap_int2_get unsafe.Pointer - -func GetInt2() (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_int2_get, _swig_p) - return -} -var _wrap_int3_set unsafe.Pointer - -func _swig_wrap_int3_set(base *int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_int3_set, _swig_p) - return -} - -func SetInt3(arg1 *int) { - _swig_wrap_int3_set(arg1) -} - -var _wrap_int3_get unsafe.Pointer - -func GetInt3() (_swig_ret *int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_int3_get, _swig_p) - return -} -var _wrap_int4_get unsafe.Pointer - -func GetInt4() (_swig_ret *int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_int4_get, _swig_p) - return -} -var _wrap_global_const_int_ptr_array_get unsafe.Pointer - -func GetGlobal_const_int_ptr_array() (_swig_ret **int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_global_const_int_ptr_array_get, _swig_p) - return -} -var _wrap_array_member4_get unsafe.Pointer - -func GetArray_member4() (_swig_ret uintptr) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_array_member4_get, _swig_p) - return -} -type SwigcptrReturnValuesTest uintptr - -func (p SwigcptrReturnValuesTest) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrReturnValuesTest) SwigIsReturnValuesTest() { -} - -var _wrap_ReturnValuesTest_td1_set unsafe.Pointer - -func _swig_wrap_ReturnValuesTest_td1_set(base SwigcptrReturnValuesTest, _ *int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_ReturnValuesTest_td1_set, _swig_p) - return -} - -func (arg1 SwigcptrReturnValuesTest) SetTd1(arg2 *int) { - _swig_wrap_ReturnValuesTest_td1_set(arg1, arg2) -} - -var _wrap_ReturnValuesTest_td1_get unsafe.Pointer - -func _swig_wrap_ReturnValuesTest_td1_get(base SwigcptrReturnValuesTest) (_ *int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_ReturnValuesTest_td1_get, _swig_p) - return -} - -func (arg1 SwigcptrReturnValuesTest) GetTd1() (_swig_ret *int) { - return _swig_wrap_ReturnValuesTest_td1_get(arg1) -} - -var _wrap_ReturnValuesTest_td2_set unsafe.Pointer - -func _swig_wrap_ReturnValuesTest_td2_set(base SwigcptrReturnValuesTest, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_ReturnValuesTest_td2_set, _swig_p) - return -} - -func (arg1 SwigcptrReturnValuesTest) SetTd2(arg2 int) { - _swig_wrap_ReturnValuesTest_td2_set(arg1, arg2) -} - -var _wrap_ReturnValuesTest_td2_get unsafe.Pointer - -func _swig_wrap_ReturnValuesTest_td2_get(base SwigcptrReturnValuesTest) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_ReturnValuesTest_td2_get, _swig_p) - return -} - -func (arg1 SwigcptrReturnValuesTest) GetTd2() (_swig_ret int) { - return _swig_wrap_ReturnValuesTest_td2_get(arg1) -} - -var _wrap_ReturnValuesTest_int1_set unsafe.Pointer - -func _swig_wrap_ReturnValuesTest_int1_set(base SwigcptrReturnValuesTest, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_ReturnValuesTest_int1_set, _swig_p) - return -} - -func (arg1 SwigcptrReturnValuesTest) SetInt1(arg2 int) { - _swig_wrap_ReturnValuesTest_int1_set(arg1, arg2) -} - -var _wrap_ReturnValuesTest_int1_get unsafe.Pointer - -func _swig_wrap_ReturnValuesTest_int1_get(base SwigcptrReturnValuesTest) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_ReturnValuesTest_int1_get, _swig_p) - return -} - -func (arg1 SwigcptrReturnValuesTest) GetInt1() (_swig_ret int) { - return _swig_wrap_ReturnValuesTest_int1_get(arg1) -} - -var _wrap_ReturnValuesTest_int2_set unsafe.Pointer - -func _swig_wrap_ReturnValuesTest_int2_set(base SwigcptrReturnValuesTest, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_ReturnValuesTest_int2_set, _swig_p) - return -} - -func (arg1 SwigcptrReturnValuesTest) SetInt2(arg2 int) { - _swig_wrap_ReturnValuesTest_int2_set(arg1, arg2) -} - -var _wrap_ReturnValuesTest_int2_get unsafe.Pointer - -func _swig_wrap_ReturnValuesTest_int2_get(base SwigcptrReturnValuesTest) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_ReturnValuesTest_int2_get, _swig_p) - return -} - -func (arg1 SwigcptrReturnValuesTest) GetInt2() (_swig_ret int) { - return _swig_wrap_ReturnValuesTest_int2_get(arg1) -} - -var _wrap_ReturnValuesTest_int3_get unsafe.Pointer - -func _swig_wrap_ReturnValuesTest_int3_get(base SwigcptrReturnValuesTest) (_ *int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_ReturnValuesTest_int3_get, _swig_p) - return -} - -func (arg1 SwigcptrReturnValuesTest) GetInt3() (_swig_ret *int) { - return _swig_wrap_ReturnValuesTest_int3_get(arg1) -} - -var _wrap_ReturnValuesTest_int4_set unsafe.Pointer - -func _swig_wrap_ReturnValuesTest_int4_set(base SwigcptrReturnValuesTest, _ *int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_ReturnValuesTest_int4_set, _swig_p) - return -} - -func (arg1 SwigcptrReturnValuesTest) SetInt4(arg2 *int) { - _swig_wrap_ReturnValuesTest_int4_set(arg1, arg2) -} - -var _wrap_ReturnValuesTest_int4_get unsafe.Pointer - -func _swig_wrap_ReturnValuesTest_int4_get(base SwigcptrReturnValuesTest) (_ *int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_ReturnValuesTest_int4_get, _swig_p) - return -} - -func (arg1 SwigcptrReturnValuesTest) GetInt4() (_swig_ret *int) { - return _swig_wrap_ReturnValuesTest_int4_get(arg1) -} - -var _wrap_ReturnValuesTest_array1_set unsafe.Pointer - -func _swig_wrap_ReturnValuesTest_array1_set(base SwigcptrReturnValuesTest, _ *int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_ReturnValuesTest_array1_set, _swig_p) - return -} - -func (arg1 SwigcptrReturnValuesTest) SetArray1(arg2 *int) { - _swig_wrap_ReturnValuesTest_array1_set(arg1, arg2) -} - -var _wrap_ReturnValuesTest_array1_get unsafe.Pointer - -func _swig_wrap_ReturnValuesTest_array1_get(base SwigcptrReturnValuesTest) (_ *int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_ReturnValuesTest_array1_get, _swig_p) - return -} - -func (arg1 SwigcptrReturnValuesTest) GetArray1() (_swig_ret *int) { - return _swig_wrap_ReturnValuesTest_array1_get(arg1) -} - -var _wrap_ReturnValuesTest_ret1 unsafe.Pointer - -func _swig_wrap_ReturnValuesTest_ret1(base SwigcptrReturnValuesTest) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_ReturnValuesTest_ret1, _swig_p) - return -} - -func (arg1 SwigcptrReturnValuesTest) Ret1() (_swig_ret int) { - return _swig_wrap_ReturnValuesTest_ret1(arg1) -} - -var _wrap_ReturnValuesTest_ret2 unsafe.Pointer - -func _swig_wrap_ReturnValuesTest_ret2(base SwigcptrReturnValuesTest) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_ReturnValuesTest_ret2, _swig_p) - return -} - -func (arg1 SwigcptrReturnValuesTest) Ret2() (_swig_ret int) { - return _swig_wrap_ReturnValuesTest_ret2(arg1) -} - -var _wrap_ReturnValuesTest_ret3 unsafe.Pointer - -func _swig_wrap_ReturnValuesTest_ret3(base SwigcptrReturnValuesTest) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_ReturnValuesTest_ret3, _swig_p) - return -} - -func (arg1 SwigcptrReturnValuesTest) Ret3() (_swig_ret int) { - return _swig_wrap_ReturnValuesTest_ret3(arg1) -} - -var _wrap_ReturnValuesTest_ret4 unsafe.Pointer - -func _swig_wrap_ReturnValuesTest_ret4(base SwigcptrReturnValuesTest) (_ *int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_ReturnValuesTest_ret4, _swig_p) - return -} - -func (arg1 SwigcptrReturnValuesTest) Ret4() (_swig_ret *int) { - return _swig_wrap_ReturnValuesTest_ret4(arg1) -} - -var _wrap_ReturnValuesTest_ret5 unsafe.Pointer - -func _swig_wrap_ReturnValuesTest_ret5(base SwigcptrReturnValuesTest) (_ *int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_ReturnValuesTest_ret5, _swig_p) - return -} - -func (arg1 SwigcptrReturnValuesTest) Ret5() (_swig_ret *int) { - return _swig_wrap_ReturnValuesTest_ret5(arg1) -} - -var _wrap_ReturnValuesTest_ret6 unsafe.Pointer - -func _swig_wrap_ReturnValuesTest_ret6(base SwigcptrReturnValuesTest, _ **int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_ReturnValuesTest_ret6, _swig_p) - return -} - -func (arg1 SwigcptrReturnValuesTest) Ret6(arg2 **int) { - _swig_wrap_ReturnValuesTest_ret6(arg1, arg2) -} - -var _wrap_ReturnValuesTest_ret7 unsafe.Pointer - -func _swig_wrap_ReturnValuesTest_ret7(base SwigcptrReturnValuesTest) (_ **int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_ReturnValuesTest_ret7, _swig_p) - return -} - -func (arg1 SwigcptrReturnValuesTest) Ret7() (_swig_ret **int) { - return _swig_wrap_ReturnValuesTest_ret7(arg1) -} - -var _wrap_ReturnValuesTest_ret8 unsafe.Pointer - -func _swig_wrap_ReturnValuesTest_ret8(base SwigcptrReturnValuesTest, _ *int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_ReturnValuesTest_ret8, _swig_p) - return -} - -func (arg1 SwigcptrReturnValuesTest) Ret8(arg2 *int) { - _swig_wrap_ReturnValuesTest_ret8(arg1, arg2) -} - -var _wrap_ReturnValuesTest_ret9 unsafe.Pointer - -func _swig_wrap_ReturnValuesTest_ret9(base SwigcptrReturnValuesTest) (_ *int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_ReturnValuesTest_ret9, _swig_p) - return -} - -func (arg1 SwigcptrReturnValuesTest) Ret9() (_swig_ret *int) { - return _swig_wrap_ReturnValuesTest_ret9(arg1) -} - -var _wrap_new_ReturnValuesTest unsafe.Pointer - -func _swig_wrap_new_ReturnValuesTest() (base SwigcptrReturnValuesTest) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_ReturnValuesTest, _swig_p) - return -} - -func NewReturnValuesTest() (_swig_ret ReturnValuesTest) { - return _swig_wrap_new_ReturnValuesTest() -} - -var _wrap_delete_ReturnValuesTest unsafe.Pointer - -func _swig_wrap_delete_ReturnValuesTest(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_ReturnValuesTest, _swig_p) - return -} - -func DeleteReturnValuesTest(arg1 ReturnValuesTest) { - _swig_wrap_delete_ReturnValuesTest(arg1.Swigcptr()) -} - -type ReturnValuesTest interface { - Swigcptr() uintptr - SwigIsReturnValuesTest() - SetTd1(arg2 *int) - GetTd1() (_swig_ret *int) - SetTd2(arg2 int) - GetTd2() (_swig_ret int) - SetInt1(arg2 int) - GetInt1() (_swig_ret int) - SetInt2(arg2 int) - GetInt2() (_swig_ret int) - GetInt3() (_swig_ret *int) - SetInt4(arg2 *int) - GetInt4() (_swig_ret *int) - SetArray1(arg2 *int) - GetArray1() (_swig_ret *int) - Ret1() (_swig_ret int) - Ret2() (_swig_ret int) - Ret3() (_swig_ret int) - Ret4() (_swig_ret *int) - Ret5() (_swig_ret *int) - Ret6(arg2 **int) - Ret7() (_swig_ret **int) - Ret8(arg2 *int) - Ret9() (_swig_ret *int) -} - -var _wrap_globalRet1 unsafe.Pointer - -func GlobalRet1() (_swig_ret *int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_globalRet1, _swig_p) - return -} -var _wrap_globalRet2 unsafe.Pointer - -func GlobalRet2() (_swig_ret *int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_globalRet2, _swig_p) - return -} -var _wrap_opaque unsafe.Pointer - -func _swig_wrap_opaque(base uintptr) (_ SwigcptrA) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_opaque, _swig_p) - return -} - -func Opaque(arg1 A) (_swig_ret A) { - return _swig_wrap_opaque(arg1.Swigcptr()) -} - -type SwigcptrB uintptr - -func (p SwigcptrB) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrB) SwigIsB() { -} - -var _wrap_new_B unsafe.Pointer - -func _swig_wrap_new_B() (base SwigcptrB) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_B, _swig_p) - return -} - -func NewB() (_swig_ret B) { - return _swig_wrap_new_B() -} - -var _wrap_B_ca_get unsafe.Pointer - -func _swig_wrap_B_ca_get(base SwigcptrB) (_ SwigcptrA) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_B_ca_get, _swig_p) - return -} - -func (arg1 SwigcptrB) GetCa() (_swig_ret A) { - return _swig_wrap_B_ca_get(arg1) -} - -var _wrap_B_a_set unsafe.Pointer - -func _swig_wrap_B_a_set(base SwigcptrB, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_B_a_set, _swig_p) - return -} - -func (arg1 SwigcptrB) SetA(arg2 A) { - _swig_wrap_B_a_set(arg1, arg2.Swigcptr()) -} - -var _wrap_B_a_get unsafe.Pointer - -func _swig_wrap_B_a_get(base SwigcptrB) (_ SwigcptrA) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_B_a_get, _swig_p) - return -} - -func (arg1 SwigcptrB) GetA() (_swig_ret A) { - return _swig_wrap_B_a_get(arg1) -} - -var _wrap_B_ap_set unsafe.Pointer - -func _swig_wrap_B_ap_set(base SwigcptrB, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_B_ap_set, _swig_p) - return -} - -func (arg1 SwigcptrB) SetAp(arg2 A) { - _swig_wrap_B_ap_set(arg1, arg2.Swigcptr()) -} - -var _wrap_B_ap_get unsafe.Pointer - -func _swig_wrap_B_ap_get(base SwigcptrB) (_ SwigcptrA) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_B_ap_get, _swig_p) - return -} - -func (arg1 SwigcptrB) GetAp() (_swig_ret A) { - return _swig_wrap_B_ap_get(arg1) -} - -var _wrap_B_cap_set unsafe.Pointer - -func _swig_wrap_B_cap_set(base SwigcptrB, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_B_cap_set, _swig_p) - return -} - -func (arg1 SwigcptrB) SetCap(arg2 A) { - _swig_wrap_B_cap_set(arg1, arg2.Swigcptr()) -} - -var _wrap_B_cap_get unsafe.Pointer - -func _swig_wrap_B_cap_get(base SwigcptrB) (_ SwigcptrA) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_B_cap_get, _swig_p) - return -} - -func (arg1 SwigcptrB) GetCap() (_swig_ret A) { - return _swig_wrap_B_cap_get(arg1) -} - -var _wrap_B_acptr_set unsafe.Pointer - -func _swig_wrap_B_acptr_set(base SwigcptrB, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_B_acptr_set, _swig_p) - return -} - -func (arg1 SwigcptrB) SetAcptr(arg2 A) { - _swig_wrap_B_acptr_set(arg1, arg2.Swigcptr()) -} - -var _wrap_B_acptr_get unsafe.Pointer - -func _swig_wrap_B_acptr_get(base SwigcptrB) (_ SwigcptrA) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_B_acptr_get, _swig_p) - return -} - -func (arg1 SwigcptrB) GetAcptr() (_swig_ret A) { - return _swig_wrap_B_acptr_get(arg1) -} - -var _wrap_delete_B unsafe.Pointer - -func _swig_wrap_delete_B(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_B, _swig_p) - return -} - -func DeleteB(arg1 B) { - _swig_wrap_delete_B(arg1.Swigcptr()) -} - -type B interface { - Swigcptr() uintptr - SwigIsB() - GetCa() (_swig_ret A) - SetA(arg2 A) - GetA() (_swig_ret A) - SetAp(arg2 A) - GetAp() (_swig_ret A) - SetCap(arg2 A) - GetCap() (_swig_ret A) - SetAcptr(arg2 A) - GetAcptr() (_swig_ret A) -} - -var _wrap_bar unsafe.Pointer - -func _swig_wrap_bar(base uintptr) (_ SwigcptrB) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_bar, _swig_p) - return -} - -func Bar(arg1 B) (_swig_ret B) { - return _swig_wrap_bar(arg1.Swigcptr()) -} - -var _wrap_cbar unsafe.Pointer - -func _swig_wrap_cbar(base uintptr) (_ SwigcptrB) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_cbar, _swig_p) - return -} - -func Cbar(arg1 B) (_swig_ret B) { - return _swig_wrap_cbar(arg1.Swigcptr()) -} - -var _wrap_wxEVENT_COMMAND_BUTTON_CLICKEDr_set unsafe.Pointer - -func _swig_wrap_wxEVENT_COMMAND_BUTTON_CLICKEDr_set(base *int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_wxEVENT_COMMAND_BUTTON_CLICKEDr_set, _swig_p) - return -} - -func SetWxEVENT_COMMAND_BUTTON_CLICKEDr(arg1 *int) { - _swig_wrap_wxEVENT_COMMAND_BUTTON_CLICKEDr_set(arg1) -} - -var _wrap_wxEVENT_COMMAND_BUTTON_CLICKEDr_get unsafe.Pointer - -func GetWxEVENT_COMMAND_BUTTON_CLICKEDr() (_swig_ret *int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_wxEVENT_COMMAND_BUTTON_CLICKEDr_get, _swig_p) - return -} -var _wrap_wxEVENT_COMMAND_BUTTON_CLICKEDp_set unsafe.Pointer - -func _swig_wrap_wxEVENT_COMMAND_BUTTON_CLICKEDp_set(base *int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_wxEVENT_COMMAND_BUTTON_CLICKEDp_set, _swig_p) - return -} - -func SetWxEVENT_COMMAND_BUTTON_CLICKEDp(arg1 *int) { - _swig_wrap_wxEVENT_COMMAND_BUTTON_CLICKEDp_set(arg1) -} - -var _wrap_wxEVENT_COMMAND_BUTTON_CLICKEDp_get unsafe.Pointer - -func GetWxEVENT_COMMAND_BUTTON_CLICKEDp() (_swig_ret *int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_wxEVENT_COMMAND_BUTTON_CLICKEDp_get, _swig_p) - return -} -var _wrap_languages1_set unsafe.Pointer - -func _swig_wrap_languages1_set(base *string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_languages1_set, _swig_p) - return -} - -func SetLanguages1(arg1 *string) { - _swig_wrap_languages1_set(arg1) -} - -var _wrap_languages1_get unsafe.Pointer - -func GetLanguages1() (_swig_ret *string) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_languages1_get, _swig_p) - return -} -var _wrap_languages2_set unsafe.Pointer - -func _swig_wrap_languages2_set(base *string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_languages2_set, _swig_p) - return -} - -func SetLanguages2(arg1 *string) { - _swig_wrap_languages2_set(arg1) -} - -var _wrap_languages2_get unsafe.Pointer - -func GetLanguages2() (_swig_ret *string) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_languages2_get, _swig_p) - return -} -type SwigcptrFoo uintptr - -func (p SwigcptrFoo) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrFoo) SwigIsFoo() { -} - -var _wrap_Foo_icap_set unsafe.Pointer - -func _swig_wrap_Foo_icap_set(base SwigcptrFoo, _ *int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_icap_set, _swig_p) - return -} - -func (arg1 SwigcptrFoo) SetIcap(arg2 *int) { - _swig_wrap_Foo_icap_set(arg1, arg2) -} - -var _wrap_Foo_icap_get unsafe.Pointer - -func _swig_wrap_Foo_icap_get(base SwigcptrFoo) (_ *int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_icap_get, _swig_p) - return -} - -func (arg1 SwigcptrFoo) GetIcap() (_swig_ret *int) { - return _swig_wrap_Foo_icap_get(arg1) -} - -var _wrap_new_Foo unsafe.Pointer - -func _swig_wrap_new_Foo() (base SwigcptrFoo) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Foo, _swig_p) - return -} - -func NewFoo() (_swig_ret Foo) { - return _swig_wrap_new_Foo() -} - -var _wrap_delete_Foo unsafe.Pointer - -func _swig_wrap_delete_Foo(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Foo, _swig_p) - return -} - -func DeleteFoo(arg1 Foo) { - _swig_wrap_delete_Foo(arg1.Swigcptr()) -} - -type Foo interface { - Swigcptr() uintptr - SwigIsFoo() - SetIcap(arg2 *int) - GetIcap() (_swig_ret *int) -} - -var _wrap_icap_set unsafe.Pointer - -func _swig_wrap_icap_set(base *int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_icap_set, _swig_p) - return -} - -func SetIcap(arg1 *int) { - _swig_wrap_icap_set(arg1) -} - -var _wrap_icap_get unsafe.Pointer - -func GetIcap() (_swig_ret *int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_icap_get, _swig_p) - return -} -var _wrap_cap_set unsafe.Pointer - -func _swig_wrap_cap_set(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_cap_set, _swig_p) - return -} - -func SetCap(arg1 Foo) { - _swig_wrap_cap_set(arg1.Swigcptr()) -} - -var _wrap_cap_get unsafe.Pointer - -func _swig_wrap_cap_get() (base SwigcptrFoo) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_cap_get, _swig_p) - return -} - -func GetCap() (_swig_ret Foo) { - return _swig_wrap_cap_get() -} - - -type SwigcptrA uintptr -type A interface { - Swigcptr() uintptr; -} -func (p SwigcptrA) Swigcptr() uintptr { - return uintptr(p) -} - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/constover.go b/Examples/test-suite/go/constover.go deleted file mode 100644 index 7f46c8619..000000000 --- a/Examples/test-suite/go/constover.go +++ /dev/null @@ -1,141 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../constover.i - -package constover - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -var _wrap_test unsafe.Pointer - -func Test(arg1 string) (_swig_ret string) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_test, _swig_p) - return -} -var _wrap_test_pconst unsafe.Pointer - -func Test_pconst(arg1 string) (_swig_ret string) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_test_pconst, _swig_p) - return -} -type SwigcptrFoo uintptr - -func (p SwigcptrFoo) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrFoo) SwigIsFoo() { -} - -var _wrap_new_Foo unsafe.Pointer - -func _swig_wrap_new_Foo() (base SwigcptrFoo) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Foo, _swig_p) - return -} - -func NewFoo() (_swig_ret Foo) { - return _swig_wrap_new_Foo() -} - -var _wrap_Foo_test unsafe.Pointer - -func _swig_wrap_Foo_test(base SwigcptrFoo, _ string) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_test, _swig_p) - return -} - -func (arg1 SwigcptrFoo) Test(arg2 string) (_swig_ret string) { - return _swig_wrap_Foo_test(arg1, arg2) -} - -var _wrap_Foo_test_pconst unsafe.Pointer - -func _swig_wrap_Foo_test_pconst(base SwigcptrFoo, _ string) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_test_pconst, _swig_p) - return -} - -func (arg1 SwigcptrFoo) Test_pconst(arg2 string) (_swig_ret string) { - return _swig_wrap_Foo_test_pconst(arg1, arg2) -} - -var _wrap_Foo_test_constm unsafe.Pointer - -func _swig_wrap_Foo_test_constm(base SwigcptrFoo, _ string) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_test_constm, _swig_p) - return -} - -func (arg1 SwigcptrFoo) Test_constm(arg2 string) (_swig_ret string) { - return _swig_wrap_Foo_test_constm(arg1, arg2) -} - -var _wrap_Foo_test_pconstm unsafe.Pointer - -func _swig_wrap_Foo_test_pconstm(base SwigcptrFoo, _ string) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_test_pconstm, _swig_p) - return -} - -func (arg1 SwigcptrFoo) Test_pconstm(arg2 string) (_swig_ret string) { - return _swig_wrap_Foo_test_pconstm(arg1, arg2) -} - -var _wrap_delete_Foo unsafe.Pointer - -func _swig_wrap_delete_Foo(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Foo, _swig_p) - return -} - -func DeleteFoo(arg1 Foo) { - _swig_wrap_delete_Foo(arg1.Swigcptr()) -} - -type Foo interface { - Swigcptr() uintptr - SwigIsFoo() - Test(arg2 string) (_swig_ret string) - Test_pconst(arg2 string) (_swig_ret string) - Test_constm(arg2 string) (_swig_ret string) - Test_pconstm(arg2 string) (_swig_ret string) -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/constover_runme b/Examples/test-suite/go/constover_runme deleted file mode 100755 index 5e39bbb3b..000000000 Binary files a/Examples/test-suite/go/constover_runme and /dev/null differ diff --git a/Examples/test-suite/go/constructor_copy.go b/Examples/test-suite/go/constructor_copy.go deleted file mode 100644 index 8ee7fc93d..000000000 --- a/Examples/test-suite/go/constructor_copy.go +++ /dev/null @@ -1,1012 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../constructor_copy.i - -package constructor_copy - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrFoo1 uintptr - -func (p SwigcptrFoo1) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrFoo1) SwigIsFoo1() { -} - -var _wrap_Foo1_x_set unsafe.Pointer - -func _swig_wrap_Foo1_x_set(base SwigcptrFoo1, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo1_x_set, _swig_p) - return -} - -func (arg1 SwigcptrFoo1) SetX(arg2 int) { - _swig_wrap_Foo1_x_set(arg1, arg2) -} - -var _wrap_Foo1_x_get unsafe.Pointer - -func _swig_wrap_Foo1_x_get(base SwigcptrFoo1) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo1_x_get, _swig_p) - return -} - -func (arg1 SwigcptrFoo1) GetX() (_swig_ret int) { - return _swig_wrap_Foo1_x_get(arg1) -} - -var _wrap_new_Foo1__SWIG_0 unsafe.Pointer - -func _swig_wrap_new_Foo1__SWIG_0(base int) (_ SwigcptrFoo1) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Foo1__SWIG_0, _swig_p) - return -} - -func NewFoo1__SWIG_0(arg1 int) (_swig_ret Foo1) { - return _swig_wrap_new_Foo1__SWIG_0(arg1) -} - -var _wrap_new_Foo1__SWIG_1 unsafe.Pointer - -func _swig_wrap_new_Foo1__SWIG_1() (base SwigcptrFoo1) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Foo1__SWIG_1, _swig_p) - return -} - -func NewFoo1__SWIG_1() (_swig_ret Foo1) { - return _swig_wrap_new_Foo1__SWIG_1() -} - -var _wrap_new_Foo1__SWIG_2 unsafe.Pointer - -func _swig_wrap_new_Foo1__SWIG_2(base uintptr) (_ SwigcptrFoo1) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Foo1__SWIG_2, _swig_p) - return -} - -func NewFoo1__SWIG_2(arg1 Foo1) (_swig_ret Foo1) { - return _swig_wrap_new_Foo1__SWIG_2(arg1.Swigcptr()) -} - -func NewFoo1(a ...interface{}) Foo1 { - argc := len(a) - if argc == 0 { - return NewFoo1__SWIG_1() - } - if argc == 1 { - if _, ok := a[0].(Foo1); !ok { - goto check_2 - } - return NewFoo1__SWIG_2(a[0].(Foo1)) - } -check_2: - if argc == 1 { - return NewFoo1__SWIG_0(a[0].(int)) - } - panic("No match for overloaded function call") -} - -var _wrap_delete_Foo1 unsafe.Pointer - -func _swig_wrap_delete_Foo1(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Foo1, _swig_p) - return -} - -func DeleteFoo1(arg1 Foo1) { - _swig_wrap_delete_Foo1(arg1.Swigcptr()) -} - -type Foo1 interface { - Swigcptr() uintptr - SwigIsFoo1() - SetX(arg2 int) - GetX() (_swig_ret int) -} - -type SwigcptrFoo2 uintptr - -func (p SwigcptrFoo2) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrFoo2) SwigIsFoo2() { -} - -var _wrap_new_Foo2__SWIG_0 unsafe.Pointer - -func _swig_wrap_new_Foo2__SWIG_0() (base SwigcptrFoo2) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Foo2__SWIG_0, _swig_p) - return -} - -func NewFoo2__SWIG_0() (_swig_ret Foo2) { - return _swig_wrap_new_Foo2__SWIG_0() -} - -var _wrap_new_Foo2__SWIG_1 unsafe.Pointer - -func _swig_wrap_new_Foo2__SWIG_1(base uintptr) (_ SwigcptrFoo2) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Foo2__SWIG_1, _swig_p) - return -} - -func NewFoo2__SWIG_1(arg1 Foo2) (_swig_ret Foo2) { - return _swig_wrap_new_Foo2__SWIG_1(arg1.Swigcptr()) -} - -func NewFoo2(a ...interface{}) Foo2 { - argc := len(a) - if argc == 0 { - return NewFoo2__SWIG_0() - } - if argc == 1 { - return NewFoo2__SWIG_1(a[0].(Foo2)) - } - panic("No match for overloaded function call") -} - -var _wrap_delete_Foo2 unsafe.Pointer - -func _swig_wrap_delete_Foo2(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Foo2, _swig_p) - return -} - -func DeleteFoo2(arg1 Foo2) { - _swig_wrap_delete_Foo2(arg1.Swigcptr()) -} - -type Foo2 interface { - Swigcptr() uintptr - SwigIsFoo2() -} - -type SwigcptrFoo3 uintptr - -func (p SwigcptrFoo3) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrFoo3) SwigIsFoo3() { -} - -var _wrap_new_Foo3__SWIG_0 unsafe.Pointer - -func _swig_wrap_new_Foo3__SWIG_0() (base SwigcptrFoo3) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Foo3__SWIG_0, _swig_p) - return -} - -func NewFoo3__SWIG_0() (_swig_ret Foo3) { - return _swig_wrap_new_Foo3__SWIG_0() -} - -var _wrap_new_Foo3__SWIG_1 unsafe.Pointer - -func _swig_wrap_new_Foo3__SWIG_1(base uintptr) (_ SwigcptrFoo3) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Foo3__SWIG_1, _swig_p) - return -} - -func NewFoo3__SWIG_1(arg1 Foo3) (_swig_ret Foo3) { - return _swig_wrap_new_Foo3__SWIG_1(arg1.Swigcptr()) -} - -func NewFoo3(a ...interface{}) Foo3 { - argc := len(a) - if argc == 0 { - return NewFoo3__SWIG_0() - } - if argc == 1 { - return NewFoo3__SWIG_1(a[0].(Foo3)) - } - panic("No match for overloaded function call") -} - -var _wrap_delete_Foo3 unsafe.Pointer - -func _swig_wrap_delete_Foo3(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Foo3, _swig_p) - return -} - -func DeleteFoo3(arg1 Foo3) { - _swig_wrap_delete_Foo3(arg1.Swigcptr()) -} - -type Foo3 interface { - Swigcptr() uintptr - SwigIsFoo3() -} - -type SwigcptrFoo4 uintptr - -func (p SwigcptrFoo4) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrFoo4) SwigIsFoo4() { -} - -var _wrap_new_Foo4 unsafe.Pointer - -func _swig_wrap_new_Foo4() (base SwigcptrFoo4) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Foo4, _swig_p) - return -} - -func NewFoo4() (_swig_ret Foo4) { - return _swig_wrap_new_Foo4() -} - -var _wrap_delete_Foo4 unsafe.Pointer - -func _swig_wrap_delete_Foo4(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Foo4, _swig_p) - return -} - -func DeleteFoo4(arg1 Foo4) { - _swig_wrap_delete_Foo4(arg1.Swigcptr()) -} - -type Foo4 interface { - Swigcptr() uintptr - SwigIsFoo4() -} - -type SwigcptrFoo4a uintptr - -func (p SwigcptrFoo4a) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrFoo4a) SwigIsFoo4a() { -} - -var _wrap_new_Foo4a unsafe.Pointer - -func _swig_wrap_new_Foo4a() (base SwigcptrFoo4a) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Foo4a, _swig_p) - return -} - -func NewFoo4a() (_swig_ret Foo4a) { - return _swig_wrap_new_Foo4a() -} - -var _wrap_delete_Foo4a unsafe.Pointer - -func _swig_wrap_delete_Foo4a(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Foo4a, _swig_p) - return -} - -func DeleteFoo4a(arg1 Foo4a) { - _swig_wrap_delete_Foo4a(arg1.Swigcptr()) -} - -type Foo4a interface { - Swigcptr() uintptr - SwigIsFoo4a() -} - -type SwigcptrFoo5 uintptr - -func (p SwigcptrFoo5) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrFoo5) SwigIsFoo5() { -} - -var _wrap_new_Foo5__SWIG_0 unsafe.Pointer - -func _swig_wrap_new_Foo5__SWIG_0() (base SwigcptrFoo5) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Foo5__SWIG_0, _swig_p) - return -} - -func NewFoo5__SWIG_0() (_swig_ret Foo5) { - return _swig_wrap_new_Foo5__SWIG_0() -} - -var _wrap_new_Foo5__SWIG_1 unsafe.Pointer - -func _swig_wrap_new_Foo5__SWIG_1(base uintptr) (_ SwigcptrFoo5) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Foo5__SWIG_1, _swig_p) - return -} - -func NewFoo5__SWIG_1(arg1 Foo5) (_swig_ret Foo5) { - return _swig_wrap_new_Foo5__SWIG_1(arg1.Swigcptr()) -} - -func NewFoo5(a ...interface{}) Foo5 { - argc := len(a) - if argc == 0 { - return NewFoo5__SWIG_0() - } - if argc == 1 { - return NewFoo5__SWIG_1(a[0].(Foo5)) - } - panic("No match for overloaded function call") -} - -var _wrap_delete_Foo5 unsafe.Pointer - -func _swig_wrap_delete_Foo5(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Foo5, _swig_p) - return -} - -func DeleteFoo5(arg1 Foo5) { - _swig_wrap_delete_Foo5(arg1.Swigcptr()) -} - -func (p SwigcptrFoo5) SwigIsFoo4() { -} - -func (p SwigcptrFoo5) SwigGetFoo4() Foo4 { - return SwigcptrFoo4(p.Swigcptr()) -} - -type Foo5 interface { - Swigcptr() uintptr - SwigIsFoo5() - SwigIsFoo4() - SwigGetFoo4() Foo4 -} - -type SwigcptrFoo6 uintptr - -func (p SwigcptrFoo6) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrFoo6) SwigIsFoo6() { -} - -var _wrap_new_Foo6 unsafe.Pointer - -func _swig_wrap_new_Foo6(base uintptr) (_ SwigcptrFoo6) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Foo6, _swig_p) - return -} - -func NewFoo6(arg1 Foo6) (_swig_ret Foo6) { - return _swig_wrap_new_Foo6(arg1.Swigcptr()) -} - -var _wrap_delete_Foo6 unsafe.Pointer - -func _swig_wrap_delete_Foo6(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Foo6, _swig_p) - return -} - -func DeleteFoo6(arg1 Foo6) { - _swig_wrap_delete_Foo6(arg1.Swigcptr()) -} - -func (p SwigcptrFoo6) SwigIsFoo4() { -} - -func (p SwigcptrFoo6) SwigGetFoo4() Foo4 { - return SwigcptrFoo4(p.Swigcptr()) -} - -type Foo6 interface { - Swigcptr() uintptr - SwigIsFoo6() - SwigIsFoo4() - SwigGetFoo4() Foo4 -} - -type SwigcptrFoo7 uintptr - -func (p SwigcptrFoo7) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrFoo7) SwigIsFoo7() { -} - -var _wrap_new_Foo7__SWIG_0 unsafe.Pointer - -func _swig_wrap_new_Foo7__SWIG_0() (base SwigcptrFoo7) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Foo7__SWIG_0, _swig_p) - return -} - -func NewFoo7__SWIG_0() (_swig_ret Foo7) { - return _swig_wrap_new_Foo7__SWIG_0() -} - -var _wrap_new_Foo7__SWIG_1 unsafe.Pointer - -func _swig_wrap_new_Foo7__SWIG_1(base uintptr) (_ SwigcptrFoo7) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Foo7__SWIG_1, _swig_p) - return -} - -func NewFoo7__SWIG_1(arg1 Foo7) (_swig_ret Foo7) { - return _swig_wrap_new_Foo7__SWIG_1(arg1.Swigcptr()) -} - -func NewFoo7(a ...interface{}) Foo7 { - argc := len(a) - if argc == 0 { - return NewFoo7__SWIG_0() - } - if argc == 1 { - return NewFoo7__SWIG_1(a[0].(Foo7)) - } - panic("No match for overloaded function call") -} - -var _wrap_delete_Foo7 unsafe.Pointer - -func _swig_wrap_delete_Foo7(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Foo7, _swig_p) - return -} - -func DeleteFoo7(arg1 Foo7) { - _swig_wrap_delete_Foo7(arg1.Swigcptr()) -} - -func (p SwigcptrFoo7) SwigIsFoo5() { -} - -func (p SwigcptrFoo7) SwigGetFoo5() Foo5 { - return SwigcptrFoo5(p.Swigcptr()) -} - -func (p SwigcptrFoo7) SwigIsFoo4() { -} - -func (p SwigcptrFoo7) SwigGetFoo4() Foo4 { - return SwigcptrFoo4(p.Swigcptr()) -} - -type Foo7 interface { - Swigcptr() uintptr - SwigIsFoo7() - SwigIsFoo5() - SwigGetFoo5() Foo5 - SwigIsFoo4() - SwigGetFoo4() Foo4 -} - -type SwigcptrFoo8 uintptr - -func (p SwigcptrFoo8) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrFoo8) SwigIsFoo8() { -} - -var _wrap_new_Foo8 unsafe.Pointer - -func _swig_wrap_new_Foo8() (base SwigcptrFoo8) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Foo8, _swig_p) - return -} - -func NewFoo8() (_swig_ret Foo8) { - return _swig_wrap_new_Foo8() -} - -var _wrap_delete_Foo8 unsafe.Pointer - -func _swig_wrap_delete_Foo8(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Foo8, _swig_p) - return -} - -func DeleteFoo8(arg1 Foo8) { - _swig_wrap_delete_Foo8(arg1.Swigcptr()) -} - -type Foo8 interface { - Swigcptr() uintptr - SwigIsFoo8() -} - -type SwigcptrBari uintptr - -func (p SwigcptrBari) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrBari) SwigIsBari() { -} - -var _wrap_Bari_x_set unsafe.Pointer - -func _swig_wrap_Bari_x_set(base SwigcptrBari, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Bari_x_set, _swig_p) - return -} - -func (arg1 SwigcptrBari) SetX(arg2 int) { - _swig_wrap_Bari_x_set(arg1, arg2) -} - -var _wrap_Bari_x_get unsafe.Pointer - -func _swig_wrap_Bari_x_get(base SwigcptrBari) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Bari_x_get, _swig_p) - return -} - -func (arg1 SwigcptrBari) GetX() (_swig_ret int) { - return _swig_wrap_Bari_x_get(arg1) -} - -var _wrap_new_Bari__SWIG_0 unsafe.Pointer - -func _swig_wrap_new_Bari__SWIG_0(base int) (_ SwigcptrBari) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Bari__SWIG_0, _swig_p) - return -} - -func NewBari__SWIG_0(arg1 int) (_swig_ret Bari) { - return _swig_wrap_new_Bari__SWIG_0(arg1) -} - -var _wrap_new_Bari__SWIG_1 unsafe.Pointer - -func _swig_wrap_new_Bari__SWIG_1() (base SwigcptrBari) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Bari__SWIG_1, _swig_p) - return -} - -func NewBari__SWIG_1() (_swig_ret Bari) { - return _swig_wrap_new_Bari__SWIG_1() -} - -var _wrap_new_Bari__SWIG_2 unsafe.Pointer - -func _swig_wrap_new_Bari__SWIG_2(base uintptr) (_ SwigcptrBari) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Bari__SWIG_2, _swig_p) - return -} - -func NewBari__SWIG_2(arg1 Bari) (_swig_ret Bari) { - return _swig_wrap_new_Bari__SWIG_2(arg1.Swigcptr()) -} - -func NewBari(a ...interface{}) Bari { - argc := len(a) - if argc == 0 { - return NewBari__SWIG_1() - } - if argc == 1 { - if _, ok := a[0].(Bari); !ok { - goto check_2 - } - return NewBari__SWIG_2(a[0].(Bari)) - } -check_2: - if argc == 1 { - return NewBari__SWIG_0(a[0].(int)) - } - panic("No match for overloaded function call") -} - -var _wrap_delete_Bari unsafe.Pointer - -func _swig_wrap_delete_Bari(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Bari, _swig_p) - return -} - -func DeleteBari(arg1 Bari) { - _swig_wrap_delete_Bari(arg1.Swigcptr()) -} - -type Bari interface { - Swigcptr() uintptr - SwigIsBari() - SetX(arg2 int) - GetX() (_swig_ret int) -} - -type SwigcptrBard uintptr - -func (p SwigcptrBard) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrBard) SwigIsBard() { -} - -var _wrap_Bard_x_set unsafe.Pointer - -func _swig_wrap_Bard_x_set(base SwigcptrBard, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Bard_x_set, _swig_p) - return -} - -func (arg1 SwigcptrBard) SetX(arg2 int) { - _swig_wrap_Bard_x_set(arg1, arg2) -} - -var _wrap_Bard_x_get unsafe.Pointer - -func _swig_wrap_Bard_x_get(base SwigcptrBard) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Bard_x_get, _swig_p) - return -} - -func (arg1 SwigcptrBard) GetX() (_swig_ret int) { - return _swig_wrap_Bard_x_get(arg1) -} - -var _wrap_new_Bard__SWIG_0 unsafe.Pointer - -func _swig_wrap_new_Bard__SWIG_0(base int) (_ SwigcptrBard) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Bard__SWIG_0, _swig_p) - return -} - -func NewBard__SWIG_0(arg1 int) (_swig_ret Bard) { - return _swig_wrap_new_Bard__SWIG_0(arg1) -} - -var _wrap_new_Bard__SWIG_1 unsafe.Pointer - -func _swig_wrap_new_Bard__SWIG_1() (base SwigcptrBard) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Bard__SWIG_1, _swig_p) - return -} - -func NewBard__SWIG_1() (_swig_ret Bard) { - return _swig_wrap_new_Bard__SWIG_1() -} - -func NewBard(a ...interface{}) Bard { - argc := len(a) - if argc == 0 { - return NewBard__SWIG_1() - } - if argc == 1 { - return NewBard__SWIG_0(a[0].(int)) - } - panic("No match for overloaded function call") -} - -var _wrap_delete_Bard unsafe.Pointer - -func _swig_wrap_delete_Bard(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Bard, _swig_p) - return -} - -func DeleteBard(arg1 Bard) { - _swig_wrap_delete_Bard(arg1.Swigcptr()) -} - -type Bard interface { - Swigcptr() uintptr - SwigIsBard() - SetX(arg2 int) - GetX() (_swig_ret int) -} - -type SwigcptrABC_Libor_ModelUtils uintptr - -func (p SwigcptrABC_Libor_ModelUtils) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrABC_Libor_ModelUtils) SwigIsABC_Libor_ModelUtils() { -} - -var _wrap_new_ABC_Libor_ModelUtils__SWIG_0 unsafe.Pointer - -func _swig_wrap_new_ABC_Libor_ModelUtils__SWIG_0() (base SwigcptrABC_Libor_ModelUtils) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_ABC_Libor_ModelUtils__SWIG_0, _swig_p) - return -} - -func NewABC_Libor_ModelUtils__SWIG_0() (_swig_ret ABC_Libor_ModelUtils) { - return _swig_wrap_new_ABC_Libor_ModelUtils__SWIG_0() -} - -var _wrap_new_ABC_Libor_ModelUtils__SWIG_1 unsafe.Pointer - -func _swig_wrap_new_ABC_Libor_ModelUtils__SWIG_1(base uintptr) (_ SwigcptrABC_Libor_ModelUtils) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_ABC_Libor_ModelUtils__SWIG_1, _swig_p) - return -} - -func NewABC_Libor_ModelUtils__SWIG_1(arg1 ABC_Libor_ModelUtils) (_swig_ret ABC_Libor_ModelUtils) { - return _swig_wrap_new_ABC_Libor_ModelUtils__SWIG_1(arg1.Swigcptr()) -} - -func NewABC_Libor_ModelUtils(a ...interface{}) ABC_Libor_ModelUtils { - argc := len(a) - if argc == 0 { - return NewABC_Libor_ModelUtils__SWIG_0() - } - if argc == 1 { - return NewABC_Libor_ModelUtils__SWIG_1(a[0].(ABC_Libor_ModelUtils)) - } - panic("No match for overloaded function call") -} - -var _wrap_delete_ABC_Libor_ModelUtils unsafe.Pointer - -func _swig_wrap_delete_ABC_Libor_ModelUtils(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_ABC_Libor_ModelUtils, _swig_p) - return -} - -func DeleteABC_Libor_ModelUtils(arg1 ABC_Libor_ModelUtils) { - _swig_wrap_delete_ABC_Libor_ModelUtils(arg1.Swigcptr()) -} - -type ABC_Libor_ModelUtils interface { - Swigcptr() uintptr - SwigIsABC_Libor_ModelUtils() -} - -type SwigcptrModelUtils_i uintptr - -func (p SwigcptrModelUtils_i) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrModelUtils_i) SwigIsModelUtils_i() { -} - -var _wrap_new_ModelUtils_i__SWIG_0 unsafe.Pointer - -func _swig_wrap_new_ModelUtils_i__SWIG_0() (base SwigcptrModelUtils_i) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_ModelUtils_i__SWIG_0, _swig_p) - return -} - -func NewModelUtils_i__SWIG_0() (_swig_ret ModelUtils_i) { - return _swig_wrap_new_ModelUtils_i__SWIG_0() -} - -var _wrap_new_ModelUtils_i__SWIG_1 unsafe.Pointer - -func _swig_wrap_new_ModelUtils_i__SWIG_1(base uintptr) (_ SwigcptrModelUtils_i) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_ModelUtils_i__SWIG_1, _swig_p) - return -} - -func NewModelUtils_i__SWIG_1(arg1 ModelUtils_i) (_swig_ret ModelUtils_i) { - return _swig_wrap_new_ModelUtils_i__SWIG_1(arg1.Swigcptr()) -} - -func NewModelUtils_i(a ...interface{}) ModelUtils_i { - argc := len(a) - if argc == 0 { - return NewModelUtils_i__SWIG_0() - } - if argc == 1 { - return NewModelUtils_i__SWIG_1(a[0].(ModelUtils_i)) - } - panic("No match for overloaded function call") -} - -var _wrap_delete_ModelUtils_i unsafe.Pointer - -func _swig_wrap_delete_ModelUtils_i(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_ModelUtils_i, _swig_p) - return -} - -func DeleteModelUtils_i(arg1 ModelUtils_i) { - _swig_wrap_delete_ModelUtils_i(arg1.Swigcptr()) -} - -type ModelUtils_i interface { - Swigcptr() uintptr - SwigIsModelUtils_i() -} - -type SwigcptrSpace1Space2_TotalReturnSwap uintptr - -func (p SwigcptrSpace1Space2_TotalReturnSwap) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrSpace1Space2_TotalReturnSwap) SwigIsSpace1Space2_TotalReturnSwap() { -} - -var _wrap_new_Space1Space2_TotalReturnSwap__SWIG_0 unsafe.Pointer - -func _swig_wrap_new_Space1Space2_TotalReturnSwap__SWIG_0() (base SwigcptrSpace1Space2_TotalReturnSwap) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Space1Space2_TotalReturnSwap__SWIG_0, _swig_p) - return -} - -func NewSpace1Space2_TotalReturnSwap__SWIG_0() (_swig_ret Space1Space2_TotalReturnSwap) { - return _swig_wrap_new_Space1Space2_TotalReturnSwap__SWIG_0() -} - -var _wrap_new_Space1Space2_TotalReturnSwap__SWIG_1 unsafe.Pointer - -func _swig_wrap_new_Space1Space2_TotalReturnSwap__SWIG_1(base uintptr) (_ SwigcptrSpace1Space2_TotalReturnSwap) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Space1Space2_TotalReturnSwap__SWIG_1, _swig_p) - return -} - -func NewSpace1Space2_TotalReturnSwap__SWIG_1(arg1 Space1Space2_TotalReturnSwap) (_swig_ret Space1Space2_TotalReturnSwap) { - return _swig_wrap_new_Space1Space2_TotalReturnSwap__SWIG_1(arg1.Swigcptr()) -} - -func NewSpace1Space2_TotalReturnSwap(a ...interface{}) Space1Space2_TotalReturnSwap { - argc := len(a) - if argc == 0 { - return NewSpace1Space2_TotalReturnSwap__SWIG_0() - } - if argc == 1 { - return NewSpace1Space2_TotalReturnSwap__SWIG_1(a[0].(Space1Space2_TotalReturnSwap)) - } - panic("No match for overloaded function call") -} - -var _wrap_delete_Space1Space2_TotalReturnSwap unsafe.Pointer - -func _swig_wrap_delete_Space1Space2_TotalReturnSwap(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Space1Space2_TotalReturnSwap, _swig_p) - return -} - -func DeleteSpace1Space2_TotalReturnSwap(arg1 Space1Space2_TotalReturnSwap) { - _swig_wrap_delete_Space1Space2_TotalReturnSwap(arg1.Swigcptr()) -} - -type Space1Space2_TotalReturnSwap interface { - Swigcptr() uintptr - SwigIsSpace1Space2_TotalReturnSwap() -} - -type SwigcptrTotal_i uintptr - -func (p SwigcptrTotal_i) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrTotal_i) SwigIsTotal_i() { -} - -var _wrap_new_Total_i__SWIG_0 unsafe.Pointer - -func _swig_wrap_new_Total_i__SWIG_0() (base SwigcptrTotal_i) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Total_i__SWIG_0, _swig_p) - return -} - -func NewTotal_i__SWIG_0() (_swig_ret Total_i) { - return _swig_wrap_new_Total_i__SWIG_0() -} - -var _wrap_new_Total_i__SWIG_1 unsafe.Pointer - -func _swig_wrap_new_Total_i__SWIG_1(base uintptr) (_ SwigcptrTotal_i) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Total_i__SWIG_1, _swig_p) - return -} - -func NewTotal_i__SWIG_1(arg1 Total_i) (_swig_ret Total_i) { - return _swig_wrap_new_Total_i__SWIG_1(arg1.Swigcptr()) -} - -func NewTotal_i(a ...interface{}) Total_i { - argc := len(a) - if argc == 0 { - return NewTotal_i__SWIG_0() - } - if argc == 1 { - return NewTotal_i__SWIG_1(a[0].(Total_i)) - } - panic("No match for overloaded function call") -} - -var _wrap_delete_Total_i unsafe.Pointer - -func _swig_wrap_delete_Total_i(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Total_i, _swig_p) - return -} - -func DeleteTotal_i(arg1 Total_i) { - _swig_wrap_delete_Total_i(arg1.Swigcptr()) -} - -type Total_i interface { - Swigcptr() uintptr - SwigIsTotal_i() -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/constructor_copy_runme b/Examples/test-suite/go/constructor_copy_runme deleted file mode 100755 index 5cf9a96e4..000000000 Binary files a/Examples/test-suite/go/constructor_copy_runme and /dev/null differ diff --git a/Examples/test-suite/go/constructor_exception.go b/Examples/test-suite/go/constructor_exception.go deleted file mode 100644 index 1153a9b12..000000000 --- a/Examples/test-suite/go/constructor_exception.go +++ /dev/null @@ -1,151 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../constructor_exception.i - -package constructor_exception - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrError uintptr - -func (p SwigcptrError) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrError) SwigIsError() { -} - -var _wrap_new_Error unsafe.Pointer - -func _swig_wrap_new_Error() (base SwigcptrError) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Error, _swig_p) - return -} - -func NewError() (_swig_ret Error) { - return _swig_wrap_new_Error() -} - -var _wrap_delete_Error unsafe.Pointer - -func _swig_wrap_delete_Error(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Error, _swig_p) - return -} - -func DeleteError(arg1 Error) { - _swig_wrap_delete_Error(arg1.Swigcptr()) -} - -type Error interface { - Swigcptr() uintptr - SwigIsError() -} - -type SwigcptrSomeClass uintptr - -func (p SwigcptrSomeClass) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrSomeClass) SwigIsSomeClass() { -} - -var _wrap_new_SomeClass unsafe.Pointer - -func _swig_wrap_new_SomeClass(base int) (_ SwigcptrSomeClass) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_SomeClass, _swig_p) - return -} - -func NewSomeClass(arg1 int) (_swig_ret SomeClass) { - return _swig_wrap_new_SomeClass(arg1) -} - -var _wrap_delete_SomeClass unsafe.Pointer - -func _swig_wrap_delete_SomeClass(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_SomeClass, _swig_p) - return -} - -func DeleteSomeClass(arg1 SomeClass) { - _swig_wrap_delete_SomeClass(arg1.Swigcptr()) -} - -type SomeClass interface { - Swigcptr() uintptr - SwigIsSomeClass() -} - -type SwigcptrTest uintptr - -func (p SwigcptrTest) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrTest) SwigIsTest() { -} - -var _wrap_new_Test unsafe.Pointer - -func _swig_wrap_new_Test(base int) (_ SwigcptrTest) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Test, _swig_p) - return -} - -func NewTest(arg1 int) (_swig_ret Test) { - return _swig_wrap_new_Test(arg1) -} - -var _wrap_delete_Test unsafe.Pointer - -func _swig_wrap_delete_Test(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Test, _swig_p) - return -} - -func DeleteTest(arg1 Test) { - _swig_wrap_delete_Test(arg1.Swigcptr()) -} - -type Test interface { - Swigcptr() uintptr - SwigIsTest() -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/constructor_explicit.go b/Examples/test-suite/go/constructor_explicit.go deleted file mode 100644 index eeb797530..000000000 --- a/Examples/test-suite/go/constructor_explicit.go +++ /dev/null @@ -1,110 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../constructor_explicit.i - -package constructor_explicit - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrFoo uintptr - -func (p SwigcptrFoo) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrFoo) SwigIsFoo() { -} - -var _wrap_new_Foo__SWIG_0 unsafe.Pointer - -func _swig_wrap_new_Foo__SWIG_0() (base SwigcptrFoo) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Foo__SWIG_0, _swig_p) - return -} - -func NewFoo__SWIG_0() (_swig_ret Foo) { - return _swig_wrap_new_Foo__SWIG_0() -} - -var _wrap_new_Foo__SWIG_1 unsafe.Pointer - -func _swig_wrap_new_Foo__SWIG_1(base int) (_ SwigcptrFoo) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Foo__SWIG_1, _swig_p) - return -} - -func NewFoo__SWIG_1(arg1 int) (_swig_ret Foo) { - return _swig_wrap_new_Foo__SWIG_1(arg1) -} - -func NewFoo(a ...interface{}) Foo { - argc := len(a) - if argc == 0 { - return NewFoo__SWIG_0() - } - if argc == 1 { - return NewFoo__SWIG_1(a[0].(int)) - } - panic("No match for overloaded function call") -} - -var _wrap_delete_Foo unsafe.Pointer - -func _swig_wrap_delete_Foo(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Foo, _swig_p) - return -} - -func DeleteFoo(arg1 Foo) { - _swig_wrap_delete_Foo(arg1.Swigcptr()) -} - -type Foo interface { - Swigcptr() uintptr - SwigIsFoo() -} - -var _wrap_test unsafe.Pointer - -func _swig_wrap_test(base uintptr) (_ SwigcptrFoo) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_test, _swig_p) - return -} - -func Test(arg1 Foo) (_swig_ret Foo) { - return _swig_wrap_test(arg1.Swigcptr()) -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/constructor_ignore.go b/Examples/test-suite/go/constructor_ignore.go deleted file mode 100644 index 2e0a3ba19..000000000 --- a/Examples/test-suite/go/constructor_ignore.go +++ /dev/null @@ -1,205 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../constructor_ignore.i - -package constructor_ignore - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrDelta1 uintptr - -func (p SwigcptrDelta1) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrDelta1) SwigIsDelta1() { -} - -var _wrap_delete_Delta1 unsafe.Pointer - -func _swig_wrap_delete_Delta1(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Delta1, _swig_p) - return -} - -func DeleteDelta1(arg1 Delta1) { - _swig_wrap_delete_Delta1(arg1.Swigcptr()) -} - -type Delta1 interface { - Swigcptr() uintptr - SwigIsDelta1() -} - -type SwigcptrDelta2 uintptr - -func (p SwigcptrDelta2) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrDelta2) SwigIsDelta2() { -} - -var _wrap_delete_Delta2 unsafe.Pointer - -func _swig_wrap_delete_Delta2(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Delta2, _swig_p) - return -} - -func DeleteDelta2(arg1 Delta2) { - _swig_wrap_delete_Delta2(arg1.Swigcptr()) -} - -type Delta2 interface { - Swigcptr() uintptr - SwigIsDelta2() -} - -type SwigcptrDelta3 uintptr - -func (p SwigcptrDelta3) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrDelta3) SwigIsDelta3() { -} - -var _wrap_delete_Delta3 unsafe.Pointer - -func _swig_wrap_delete_Delta3(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Delta3, _swig_p) - return -} - -func DeleteDelta3(arg1 Delta3) { - _swig_wrap_delete_Delta3(arg1.Swigcptr()) -} - -type Delta3 interface { - Swigcptr() uintptr - SwigIsDelta3() -} - -type SwigcptrDelta4 uintptr - -func (p SwigcptrDelta4) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrDelta4) SwigIsDelta4() { -} - -var _wrap_delete_Delta4 unsafe.Pointer - -func _swig_wrap_delete_Delta4(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Delta4, _swig_p) - return -} - -func DeleteDelta4(arg1 Delta4) { - _swig_wrap_delete_Delta4(arg1.Swigcptr()) -} - -type Delta4 interface { - Swigcptr() uintptr - SwigIsDelta4() -} - -type SwigcptrDelta5 uintptr - -func (p SwigcptrDelta5) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrDelta5) SwigIsDelta5() { -} - -var _wrap_delete_Delta5 unsafe.Pointer - -func _swig_wrap_delete_Delta5(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Delta5, _swig_p) - return -} - -func DeleteDelta5(arg1 Delta5) { - _swig_wrap_delete_Delta5(arg1.Swigcptr()) -} - -type Delta5 interface { - Swigcptr() uintptr - SwigIsDelta5() -} - -type SwigcptrDelta6 uintptr - -func (p SwigcptrDelta6) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrDelta6) SwigIsDelta6() { -} - -var _wrap_new_Delta6 unsafe.Pointer - -func _swig_wrap_new_Delta6() (base SwigcptrDelta6) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Delta6, _swig_p) - return -} - -func NewDelta6() (_swig_ret Delta6) { - return _swig_wrap_new_Delta6() -} - -var _wrap_delete_Delta6 unsafe.Pointer - -func _swig_wrap_delete_Delta6(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Delta6, _swig_p) - return -} - -func DeleteDelta6(arg1 Delta6) { - _swig_wrap_delete_Delta6(arg1.Swigcptr()) -} - -type Delta6 interface { - Swigcptr() uintptr - SwigIsDelta6() -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/constructor_rename.go b/Examples/test-suite/go/constructor_rename.go deleted file mode 100644 index 986e9c825..000000000 --- a/Examples/test-suite/go/constructor_rename.go +++ /dev/null @@ -1,75 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../constructor_rename.i - -package constructor_rename - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrFoo uintptr - -func (p SwigcptrFoo) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrFoo) SwigIsFoo() { -} - -var _wrap_new_RenamedConstructor unsafe.Pointer - -func _swig_wrap_new_RenamedConstructor() (base SwigcptrFoo) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_RenamedConstructor, _swig_p) - return -} - -func NewRenamedConstructor() (_swig_ret Foo) { - return _swig_wrap_new_RenamedConstructor() -} - -var _wrap_delete_Foo unsafe.Pointer - -func _swig_wrap_delete_Foo(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Foo, _swig_p) - return -} - -func DeleteFoo(arg1 Foo) { - _swig_wrap_delete_Foo(arg1.Swigcptr()) -} - -type Foo interface { - Swigcptr() uintptr - SwigIsFoo() -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/constructor_value.go b/Examples/test-suite/go/constructor_value.go deleted file mode 100644 index 98d7802ce..000000000 --- a/Examples/test-suite/go/constructor_value.go +++ /dev/null @@ -1,113 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../constructor_value.i - -package constructor_value - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrFoo uintptr - -func (p SwigcptrFoo) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrFoo) SwigIsFoo() { -} - -var _wrap_new_Foo unsafe.Pointer - -func _swig_wrap_new_Foo(base int) (_ SwigcptrFoo) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Foo, _swig_p) - return -} - -func NewFoo(arg1 int) (_swig_ret Foo) { - return _swig_wrap_new_Foo(arg1) -} - -var _wrap_delete_Foo unsafe.Pointer - -func _swig_wrap_delete_Foo(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Foo, _swig_p) - return -} - -func DeleteFoo(arg1 Foo) { - _swig_wrap_delete_Foo(arg1.Swigcptr()) -} - -type Foo interface { - Swigcptr() uintptr - SwigIsFoo() -} - -type SwigcptrBar uintptr - -func (p SwigcptrBar) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrBar) SwigIsBar() { -} - -var _wrap_new_Bar unsafe.Pointer - -func _swig_wrap_new_Bar(base uintptr) (_ SwigcptrBar) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Bar, _swig_p) - return -} - -func NewBar(arg1 Foo) (_swig_ret Bar) { - return _swig_wrap_new_Bar(arg1.Swigcptr()) -} - -var _wrap_delete_Bar unsafe.Pointer - -func _swig_wrap_delete_Bar(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Bar, _swig_p) - return -} - -func DeleteBar(arg1 Bar) { - _swig_wrap_delete_Bar(arg1.Swigcptr()) -} - -type Bar interface { - Swigcptr() uintptr - SwigIsBar() -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/contract.go b/Examples/test-suite/go/contract.go deleted file mode 100644 index 5c4626ea1..000000000 --- a/Examples/test-suite/go/contract.go +++ /dev/null @@ -1,625 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../contract.i - -package contract - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -var _wrap_test_preassert unsafe.Pointer - -func Test_preassert(arg1 int, arg2 int) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_test_preassert, _swig_p) - return -} -var _wrap_test_postassert unsafe.Pointer - -func Test_postassert(arg1 int) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_test_postassert, _swig_p) - return -} -var _wrap_test_prepost unsafe.Pointer - -func Test_prepost(arg1 int, arg2 int) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_test_prepost, _swig_p) - return -} -type SwigcptrFoo uintptr - -func (p SwigcptrFoo) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrFoo) SwigIsFoo() { -} - -var _wrap_delete_Foo unsafe.Pointer - -func _swig_wrap_delete_Foo(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Foo, _swig_p) - return -} - -func DeleteFoo(arg1 Foo) { - _swig_wrap_delete_Foo(arg1.Swigcptr()) -} - -var _wrap_Foo_test_preassert unsafe.Pointer - -func _swig_wrap_Foo_test_preassert(base SwigcptrFoo, _ int, _ int) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_test_preassert, _swig_p) - return -} - -func (arg1 SwigcptrFoo) Test_preassert(arg2 int, arg3 int) (_swig_ret int) { - return _swig_wrap_Foo_test_preassert(arg1, arg2, arg3) -} - -var _wrap_Foo_test_postassert unsafe.Pointer - -func _swig_wrap_Foo_test_postassert(base SwigcptrFoo, _ int) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_test_postassert, _swig_p) - return -} - -func (arg1 SwigcptrFoo) Test_postassert(arg2 int) (_swig_ret int) { - return _swig_wrap_Foo_test_postassert(arg1, arg2) -} - -var _wrap_Foo_test_prepost unsafe.Pointer - -func _swig_wrap_Foo_test_prepost(base SwigcptrFoo, _ int, _ int) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_test_prepost, _swig_p) - return -} - -func (arg1 SwigcptrFoo) Test_prepost(arg2 int, arg3 int) (_swig_ret int) { - return _swig_wrap_Foo_test_prepost(arg1, arg2, arg3) -} - -var _wrap_Foo_stest_prepost unsafe.Pointer - -func FooStest_prepost(arg1 int, arg2 int) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_Foo_stest_prepost, _swig_p) - return -} -var _wrap_new_Foo unsafe.Pointer - -func _swig_wrap_new_Foo() (base SwigcptrFoo) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Foo, _swig_p) - return -} - -func NewFoo() (_swig_ret Foo) { - return _swig_wrap_new_Foo() -} - -type Foo interface { - Swigcptr() uintptr - SwigIsFoo() - Test_preassert(arg2 int, arg3 int) (_swig_ret int) - Test_postassert(arg2 int) (_swig_ret int) - Test_prepost(arg2 int, arg3 int) (_swig_ret int) -} - -type SwigcptrBar uintptr - -func (p SwigcptrBar) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrBar) SwigIsBar() { -} - -var _wrap_Bar_test_prepost unsafe.Pointer - -func _swig_wrap_Bar_test_prepost(base SwigcptrBar, _ int, _ int) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Bar_test_prepost, _swig_p) - return -} - -func (arg1 SwigcptrBar) Test_prepost(arg2 int, arg3 int) (_swig_ret int) { - return _swig_wrap_Bar_test_prepost(arg1, arg2, arg3) -} - -var _wrap_new_Bar unsafe.Pointer - -func _swig_wrap_new_Bar() (base SwigcptrBar) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Bar, _swig_p) - return -} - -func NewBar() (_swig_ret Bar) { - return _swig_wrap_new_Bar() -} - -var _wrap_delete_Bar unsafe.Pointer - -func _swig_wrap_delete_Bar(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Bar, _swig_p) - return -} - -func DeleteBar(arg1 Bar) { - _swig_wrap_delete_Bar(arg1.Swigcptr()) -} - -var _wrap_Bar_test_preassert unsafe.Pointer - -func _swig_wrap_Bar_test_preassert(base SwigcptrBar, _ int, _ int) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Bar_test_preassert, _swig_p) - return -} - -func (_swig_base SwigcptrBar) Test_preassert(arg1 int, arg2 int) (_swig_ret int) { - return _swig_wrap_Bar_test_preassert(_swig_base, arg1, arg2) -} - -var _wrap_Bar_test_postassert unsafe.Pointer - -func _swig_wrap_Bar_test_postassert(base SwigcptrBar, _ int) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Bar_test_postassert, _swig_p) - return -} - -func (_swig_base SwigcptrBar) Test_postassert(arg1 int) (_swig_ret int) { - return _swig_wrap_Bar_test_postassert(_swig_base, arg1) -} - -var _wrap_Bar_stest_prepost unsafe.Pointer - -func BarStest_prepost(arg1 int, arg2 int) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_Bar_stest_prepost, _swig_p) - return -} -func (p SwigcptrBar) SwigIsFoo() { -} - -func (p SwigcptrBar) SwigGetFoo() Foo { - return SwigcptrFoo(p.Swigcptr()) -} - -type Bar interface { - Swigcptr() uintptr - SwigIsBar() - Test_prepost(arg2 int, arg3 int) (_swig_ret int) - Test_preassert(arg1 int, arg2 int) (_swig_ret int) - Test_postassert(arg1 int) (_swig_ret int) - SwigIsFoo() - SwigGetFoo() Foo -} - -type SwigcptrA uintptr - -func (p SwigcptrA) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrA) SwigIsA() { -} - -var _wrap_delete_A unsafe.Pointer - -func _swig_wrap_delete_A(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_A, _swig_p) - return -} - -func DeleteA(arg1 A) { - _swig_wrap_delete_A(arg1.Swigcptr()) -} - -var _wrap_A_foo unsafe.Pointer - -func _swig_wrap_A_foo(base SwigcptrA, _ int, _ int, _ int, _ int, _ int) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_A_foo, _swig_p) - return -} - -func (arg1 SwigcptrA) Foo(arg2 int, arg3 int, arg4 int, arg5 int, arg6 int) (_swig_ret int) { - return _swig_wrap_A_foo(arg1, arg2, arg3, arg4, arg5, arg6) -} - -var _wrap_new_A unsafe.Pointer - -func _swig_wrap_new_A() (base SwigcptrA) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_A, _swig_p) - return -} - -func NewA() (_swig_ret A) { - return _swig_wrap_new_A() -} - -type A interface { - Swigcptr() uintptr - SwigIsA() - Foo(arg2 int, arg3 int, arg4 int, arg5 int, arg6 int) (_swig_ret int) -} - -type SwigcptrB uintptr - -func (p SwigcptrB) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrB) SwigIsB() { -} - -var _wrap_delete_B unsafe.Pointer - -func _swig_wrap_delete_B(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_B, _swig_p) - return -} - -func DeleteB(arg1 B) { - _swig_wrap_delete_B(arg1.Swigcptr()) -} - -var _wrap_B_bar unsafe.Pointer - -func _swig_wrap_B_bar(base SwigcptrB, _ int, _ int, _ int, _ int, _ int) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_B_bar, _swig_p) - return -} - -func (arg1 SwigcptrB) Bar(arg2 int, arg3 int, arg4 int, arg5 int, arg6 int) (_swig_ret int) { - return _swig_wrap_B_bar(arg1, arg2, arg3, arg4, arg5, arg6) -} - -var _wrap_new_B unsafe.Pointer - -func _swig_wrap_new_B() (base SwigcptrB) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_B, _swig_p) - return -} - -func NewB() (_swig_ret B) { - return _swig_wrap_new_B() -} - -type B interface { - Swigcptr() uintptr - SwigIsB() - Bar(arg2 int, arg3 int, arg4 int, arg5 int, arg6 int) (_swig_ret int) -} - -type SwigcptrC uintptr - -func (p SwigcptrC) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrC) SwigIsC() { -} - -var _wrap_C_foo unsafe.Pointer - -func _swig_wrap_C_foo(base SwigcptrC, _ int, _ int, _ int, _ int, _ int) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_C_foo, _swig_p) - return -} - -func (arg1 SwigcptrC) Foo(arg2 int, arg3 int, arg4 int, arg5 int, arg6 int) (_swig_ret int) { - return _swig_wrap_C_foo(arg1, arg2, arg3, arg4, arg5, arg6) -} - -var _wrap_C_bar unsafe.Pointer - -func _swig_wrap_C_bar(base SwigcptrC, _ int, _ int, _ int, _ int, _ int) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_C_bar, _swig_p) - return -} - -func (arg1 SwigcptrC) Bar(arg2 int, arg3 int, arg4 int, arg5 int, arg6 int) (_swig_ret int) { - return _swig_wrap_C_bar(arg1, arg2, arg3, arg4, arg5, arg6) -} - -var _wrap_new_C unsafe.Pointer - -func _swig_wrap_new_C() (base SwigcptrC) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_C, _swig_p) - return -} - -func NewC() (_swig_ret C) { - return _swig_wrap_new_C() -} - -var _wrap_delete_C unsafe.Pointer - -func _swig_wrap_delete_C(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_C, _swig_p) - return -} - -func DeleteC(arg1 C) { - _swig_wrap_delete_C(arg1.Swigcptr()) -} - -func (p SwigcptrC) SwigIsA() { -} - -func (p SwigcptrC) SwigGetA() A { - return SwigcptrA(p.Swigcptr()) -} - -var _wrap_C_SwigGetB unsafe.Pointer - -func _swig_wrap_C_SwigGetB(base SwigcptrC) (_ SwigcptrB) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_C_SwigGetB, _swig_p) - return -} - -func (arg1 SwigcptrC) SwigGetB() (_swig_ret B) { - return _swig_wrap_C_SwigGetB(arg1) -} - -type C interface { - Swigcptr() uintptr - SwigIsC() - Foo(arg2 int, arg3 int, arg4 int, arg5 int, arg6 int) (_swig_ret int) - Bar(arg2 int, arg3 int, arg4 int, arg5 int, arg6 int) (_swig_ret int) - SwigIsA() - SwigGetA() A - SwigGetB() (_swig_ret B) -} - -type SwigcptrD uintptr - -func (p SwigcptrD) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrD) SwigIsD() { -} - -var _wrap_D_foo unsafe.Pointer - -func _swig_wrap_D_foo(base SwigcptrD, _ int, _ int, _ int, _ int, _ int) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_D_foo, _swig_p) - return -} - -func (arg1 SwigcptrD) Foo(arg2 int, arg3 int, arg4 int, arg5 int, arg6 int) (_swig_ret int) { - return _swig_wrap_D_foo(arg1, arg2, arg3, arg4, arg5, arg6) -} - -var _wrap_D_bar unsafe.Pointer - -func _swig_wrap_D_bar(base SwigcptrD, _ int, _ int, _ int, _ int, _ int) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_D_bar, _swig_p) - return -} - -func (arg1 SwigcptrD) Bar(arg2 int, arg3 int, arg4 int, arg5 int, arg6 int) (_swig_ret int) { - return _swig_wrap_D_bar(arg1, arg2, arg3, arg4, arg5, arg6) -} - -var _wrap_new_D unsafe.Pointer - -func _swig_wrap_new_D() (base SwigcptrD) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_D, _swig_p) - return -} - -func NewD() (_swig_ret D) { - return _swig_wrap_new_D() -} - -var _wrap_delete_D unsafe.Pointer - -func _swig_wrap_delete_D(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_D, _swig_p) - return -} - -func DeleteD(arg1 D) { - _swig_wrap_delete_D(arg1.Swigcptr()) -} - -func (p SwigcptrD) SwigIsC() { -} - -func (p SwigcptrD) SwigGetC() C { - return SwigcptrC(p.Swigcptr()) -} - -func (p SwigcptrD) SwigIsA() { -} - -func (p SwigcptrD) SwigGetA() A { - return SwigcptrA(p.Swigcptr()) -} - -func (p SwigcptrD) SwigGetB() B { - return p.SwigGetC().SwigGetB() -} - -type D interface { - Swigcptr() uintptr - SwigIsD() - Foo(arg2 int, arg3 int, arg4 int, arg5 int, arg6 int) (_swig_ret int) - Bar(arg2 int, arg3 int, arg4 int, arg5 int, arg6 int) (_swig_ret int) - SwigIsC() - SwigGetC() C - SwigIsA() - SwigGetA() A - SwigGetB() B -} - -type SwigcptrE uintptr - -func (p SwigcptrE) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrE) SwigIsE() { -} - -var _wrap_E_m_i_set unsafe.Pointer - -func _swig_wrap_E_m_i_set(base SwigcptrE, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_E_m_i_set, _swig_p) - return -} - -func (arg1 SwigcptrE) SetM_i(arg2 int) { - _swig_wrap_E_m_i_set(arg1, arg2) -} - -var _wrap_E_m_i_get unsafe.Pointer - -func _swig_wrap_E_m_i_get(base SwigcptrE) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_E_m_i_get, _swig_p) - return -} - -func (arg1 SwigcptrE) GetM_i() (_swig_ret int) { - return _swig_wrap_E_m_i_get(arg1) -} - -var _wrap_E_manipulate_i unsafe.Pointer - -func _swig_wrap_E_manipulate_i(base SwigcptrE, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_E_manipulate_i, _swig_p) - return -} - -func (arg1 SwigcptrE) Manipulate_i(arg2 int) { - _swig_wrap_E_manipulate_i(arg1, arg2) -} - -var _wrap_new_E unsafe.Pointer - -func _swig_wrap_new_E() (base SwigcptrE) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_E, _swig_p) - return -} - -func NewE() (_swig_ret E) { - return _swig_wrap_new_E() -} - -var _wrap_delete_E unsafe.Pointer - -func _swig_wrap_delete_E(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_E, _swig_p) - return -} - -func DeleteE(arg1 E) { - _swig_wrap_delete_E(arg1.Swigcptr()) -} - -type E interface { - Swigcptr() uintptr - SwigIsE() - SetM_i(arg2 int) - GetM_i() (_swig_ret int) - Manipulate_i(arg2 int) -} - -type SwigcptrMyClass uintptr - -func (p SwigcptrMyClass) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrMyClass) SwigIsMyClass() { -} - -var _wrap_new_myClass unsafe.Pointer - -func _swig_wrap_new_myClass(base int) (_ SwigcptrMyClass) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_myClass, _swig_p) - return -} - -func NewMyClass(arg1 int) (_swig_ret MyClass) { - return _swig_wrap_new_myClass(arg1) -} - -var _wrap_delete_myClass unsafe.Pointer - -func _swig_wrap_delete_myClass(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_myClass, _swig_p) - return -} - -func DeleteMyClass(arg1 MyClass) { - _swig_wrap_delete_myClass(arg1.Swigcptr()) -} - -type MyClass interface { - Swigcptr() uintptr - SwigIsMyClass() -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/contract_runme b/Examples/test-suite/go/contract_runme deleted file mode 100755 index 2da080166..000000000 Binary files a/Examples/test-suite/go/contract_runme and /dev/null differ diff --git a/Examples/test-suite/go/conversion.go b/Examples/test-suite/go/conversion.go deleted file mode 100644 index 3f7460afe..000000000 --- a/Examples/test-suite/go/conversion.go +++ /dev/null @@ -1,126 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../conversion.i - -package conversion - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrFoo uintptr - -func (p SwigcptrFoo) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrFoo) SwigIsFoo() { -} - -var _wrap_new_Foo unsafe.Pointer - -func _swig_wrap_new_Foo() (base SwigcptrFoo) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Foo, _swig_p) - return -} - -func NewFoo() (_swig_ret Foo) { - return _swig_wrap_new_Foo() -} - -var _wrap_delete_Foo unsafe.Pointer - -func _swig_wrap_delete_Foo(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Foo, _swig_p) - return -} - -func DeleteFoo(arg1 Foo) { - _swig_wrap_delete_Foo(arg1.Swigcptr()) -} - -type Foo interface { - Swigcptr() uintptr - SwigIsFoo() -} - -type SwigcptrBar uintptr - -func (p SwigcptrBar) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrBar) SwigIsBar() { -} - -var _wrap_Bar_toFoo unsafe.Pointer - -func _swig_wrap_Bar_toFoo(base SwigcptrBar) (_ SwigcptrFoo) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Bar_toFoo, _swig_p) - return -} - -func (arg1 SwigcptrBar) ToFoo() (_swig_ret Foo) { - return _swig_wrap_Bar_toFoo(arg1) -} - -var _wrap_new_Bar unsafe.Pointer - -func _swig_wrap_new_Bar() (base SwigcptrBar) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Bar, _swig_p) - return -} - -func NewBar() (_swig_ret Bar) { - return _swig_wrap_new_Bar() -} - -var _wrap_delete_Bar unsafe.Pointer - -func _swig_wrap_delete_Bar(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Bar, _swig_p) - return -} - -func DeleteBar(arg1 Bar) { - _swig_wrap_delete_Bar(arg1.Swigcptr()) -} - -type Bar interface { - Swigcptr() uintptr - SwigIsBar() - ToFoo() (_swig_ret Foo) -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/conversion_namespace.go b/Examples/test-suite/go/conversion_namespace.go deleted file mode 100644 index d9bf1f10f..000000000 --- a/Examples/test-suite/go/conversion_namespace.go +++ /dev/null @@ -1,126 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../conversion_namespace.i - -package conversion_namespace - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrFoo uintptr - -func (p SwigcptrFoo) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrFoo) SwigIsFoo() { -} - -var _wrap_new_Foo unsafe.Pointer - -func _swig_wrap_new_Foo() (base SwigcptrFoo) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Foo, _swig_p) - return -} - -func NewFoo() (_swig_ret Foo) { - return _swig_wrap_new_Foo() -} - -var _wrap_delete_Foo unsafe.Pointer - -func _swig_wrap_delete_Foo(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Foo, _swig_p) - return -} - -func DeleteFoo(arg1 Foo) { - _swig_wrap_delete_Foo(arg1.Swigcptr()) -} - -type Foo interface { - Swigcptr() uintptr - SwigIsFoo() -} - -type SwigcptrBar uintptr - -func (p SwigcptrBar) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrBar) SwigIsBar() { -} - -var _wrap_Bar_toFoo unsafe.Pointer - -func _swig_wrap_Bar_toFoo(base SwigcptrBar) (_ SwigcptrFoo) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Bar_toFoo, _swig_p) - return -} - -func (arg1 SwigcptrBar) ToFoo() (_swig_ret Foo) { - return _swig_wrap_Bar_toFoo(arg1) -} - -var _wrap_new_Bar unsafe.Pointer - -func _swig_wrap_new_Bar() (base SwigcptrBar) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Bar, _swig_p) - return -} - -func NewBar() (_swig_ret Bar) { - return _swig_wrap_new_Bar() -} - -var _wrap_delete_Bar unsafe.Pointer - -func _swig_wrap_delete_Bar(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Bar, _swig_p) - return -} - -func DeleteBar(arg1 Bar) { - _swig_wrap_delete_Bar(arg1.Swigcptr()) -} - -type Bar interface { - Swigcptr() uintptr - SwigIsBar() - ToFoo() (_swig_ret Foo) -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/conversion_ns_template.go b/Examples/test-suite/go/conversion_ns_template.go deleted file mode 100644 index 0c0f61959..000000000 --- a/Examples/test-suite/go/conversion_ns_template.go +++ /dev/null @@ -1,194 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../conversion_ns_template.i - -package conversion_ns_template - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type OssTest int -var _wrap_One unsafe.Pointer - -func _swig_getOne() (_swig_ret OssTest) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_One, _swig_p) - return -} -var One OssTest = _swig_getOne() -var _wrap_Two unsafe.Pointer - -func _swig_getTwo() (_swig_ret OssTest) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_Two, _swig_p) - return -} -var Two OssTest = _swig_getTwo() -type SwigcptrHi uintptr - -func (p SwigcptrHi) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrHi) SwigIsHi() { -} - -var _wrap_new_create unsafe.Pointer - -func _swig_wrap_new_create(base int) (_ SwigcptrHi) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_create, _swig_p) - return -} - -func NewCreate(arg1 int) (_swig_ret Hi) { - return _swig_wrap_new_create(arg1) -} - -var _wrap_delete_Hi unsafe.Pointer - -func _swig_wrap_delete_Hi(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Hi, _swig_p) - return -} - -func DeleteHi(arg1 Hi) { - _swig_wrap_delete_Hi(arg1.Swigcptr()) -} - -type Hi interface { - Swigcptr() uintptr - SwigIsHi() -} - -type SwigcptrFoo_One uintptr - -func (p SwigcptrFoo_One) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrFoo_One) SwigIsFoo_One() { -} - -var _wrap_new_Foo_One unsafe.Pointer - -func _swig_wrap_new_Foo_One() (base SwigcptrFoo_One) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Foo_One, _swig_p) - return -} - -func NewFoo_One() (_swig_ret Foo_One) { - return _swig_wrap_new_Foo_One() -} - -var _wrap_delete_Foo_One unsafe.Pointer - -func _swig_wrap_delete_Foo_One(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Foo_One, _swig_p) - return -} - -func DeleteFoo_One(arg1 Foo_One) { - _swig_wrap_delete_Foo_One(arg1.Swigcptr()) -} - -type Foo_One interface { - Swigcptr() uintptr - SwigIsFoo_One() -} - -type SwigcptrBar_One uintptr - -func (p SwigcptrBar_One) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrBar_One) SwigIsBar_One() { -} - -var _wrap_new_Bar_create unsafe.Pointer - -func _swig_wrap_new_Bar_create(base int) (_ SwigcptrBar_One) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Bar_create, _swig_p) - return -} - -func NewBar_create(arg1 int) (_swig_ret Bar_One) { - return _swig_wrap_new_Bar_create(arg1) -} - -var _wrap_Bar_One_hello1 unsafe.Pointer - -func _swig_wrap_Bar_One_hello1(base SwigcptrBar_One) (_ *int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Bar_One_hello1, _swig_p) - return -} - -func (arg1 SwigcptrBar_One) Hello1() (_swig_ret *int) { - return _swig_wrap_Bar_One_hello1(arg1) -} - -var _wrap_Bar_One_hello2 unsafe.Pointer - -func _swig_wrap_Bar_One_hello2(base SwigcptrBar_One) (_ SwigcptrFoo_One) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Bar_One_hello2, _swig_p) - return -} - -func (arg1 SwigcptrBar_One) Hello2() (_swig_ret Foo_One) { - return _swig_wrap_Bar_One_hello2(arg1) -} - -var _wrap_delete_Bar_One unsafe.Pointer - -func _swig_wrap_delete_Bar_One(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Bar_One, _swig_p) - return -} - -func DeleteBar_One(arg1 Bar_One) { - _swig_wrap_delete_Bar_One(arg1.Swigcptr()) -} - -type Bar_One interface { - Swigcptr() uintptr - SwigIsBar_One() - Hello1() (_swig_ret *int) - Hello2() (_swig_ret Foo_One) -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/cplusplus_throw.go b/Examples/test-suite/go/cplusplus_throw.go deleted file mode 100644 index 1f1860797..000000000 --- a/Examples/test-suite/go/cplusplus_throw.go +++ /dev/null @@ -1,128 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../cplusplus_throw.i - -package cplusplus_throw - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrFoo uintptr - -func (p SwigcptrFoo) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrFoo) SwigIsFoo() { -} - -var _wrap_delete_Foo unsafe.Pointer - -func _swig_wrap_delete_Foo(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Foo, _swig_p) - return -} - -func DeleteFoo(arg1 Foo) { - _swig_wrap_delete_Foo(arg1.Swigcptr()) -} - -type Foo interface { - Swigcptr() uintptr - SwigIsFoo() -} - -type SwigcptrBar uintptr - -func (p SwigcptrBar) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrBar) SwigIsBar() { -} - -var _wrap_Bar_baz unsafe.Pointer - -func _swig_wrap_Bar_baz(base SwigcptrBar) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Bar_baz, _swig_p) - return -} - -func (arg1 SwigcptrBar) Baz() { - _swig_wrap_Bar_baz(arg1) -} - -var _wrap_Bar_foo unsafe.Pointer - -func _swig_wrap_Bar_foo(base SwigcptrBar) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Bar_foo, _swig_p) - return -} - -func (arg1 SwigcptrBar) Foo() { - _swig_wrap_Bar_foo(arg1) -} - -var _wrap_Bar_bazfoo unsafe.Pointer - -func _swig_wrap_Bar_bazfoo(base SwigcptrBar) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Bar_bazfoo, _swig_p) - return -} - -func (arg1 SwigcptrBar) Bazfoo() { - _swig_wrap_Bar_bazfoo(arg1) -} - -var _wrap_delete_Bar unsafe.Pointer - -func _swig_wrap_delete_Bar(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Bar, _swig_p) - return -} - -func DeleteBar(arg1 Bar) { - _swig_wrap_delete_Bar(arg1.Swigcptr()) -} - -type Bar interface { - Swigcptr() uintptr - SwigIsBar() - Baz() - Foo() - Bazfoo() -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/cpp_basic.go b/Examples/test-suite/go/cpp_basic.go deleted file mode 100644 index 516923a92..000000000 --- a/Examples/test-suite/go/cpp_basic.go +++ /dev/null @@ -1,804 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../cpp_basic.i - -package cpp_basic - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrFoo uintptr - -func (p SwigcptrFoo) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrFoo) SwigIsFoo() { -} - -var _wrap_new_Foo unsafe.Pointer - -func _swig_wrap_new_Foo(base int) (_ SwigcptrFoo) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Foo, _swig_p) - return -} - -func NewFoo(arg1 int) (_swig_ret Foo) { - return _swig_wrap_new_Foo(arg1) -} - -var _wrap_Foo_num_set unsafe.Pointer - -func _swig_wrap_Foo_num_set(base SwigcptrFoo, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_num_set, _swig_p) - return -} - -func (arg1 SwigcptrFoo) SetNum(arg2 int) { - _swig_wrap_Foo_num_set(arg1, arg2) -} - -var _wrap_Foo_num_get unsafe.Pointer - -func _swig_wrap_Foo_num_get(base SwigcptrFoo) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_num_get, _swig_p) - return -} - -func (arg1 SwigcptrFoo) GetNum() (_swig_ret int) { - return _swig_wrap_Foo_num_get(arg1) -} - -var _wrap_Foo_func1 unsafe.Pointer - -func _swig_wrap_Foo_func1(base SwigcptrFoo, _ int) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_func1, _swig_p) - return -} - -func (arg1 SwigcptrFoo) Func1(arg2 int) (_swig_ret int) { - return _swig_wrap_Foo_func1(arg1, arg2) -} - -var _wrap_Foo_func2 unsafe.Pointer - -func _swig_wrap_Foo_func2(base SwigcptrFoo, _ int) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_func2, _swig_p) - return -} - -func (arg1 SwigcptrFoo) Func2(arg2 int) (_swig_ret int) { - return _swig_wrap_Foo_func2(arg1, arg2) -} - -var _wrap_Foo_func_ptr_set unsafe.Pointer - -func _swig_wrap_Foo_func_ptr_set(base SwigcptrFoo, _ _swig_memberptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_func_ptr_set, _swig_p) - return -} - -func (arg1 SwigcptrFoo) SetFunc_ptr(arg2 _swig_memberptr) { - _swig_wrap_Foo_func_ptr_set(arg1, arg2) -} - -var _wrap_Foo_func_ptr_get unsafe.Pointer - -func _swig_wrap_Foo_func_ptr_get(base SwigcptrFoo) (_ _swig_memberptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_func_ptr_get, _swig_p) - return -} - -func (arg1 SwigcptrFoo) GetFunc_ptr() (_swig_ret _swig_memberptr) { - return _swig_wrap_Foo_func_ptr_get(arg1) -} - -var _wrap_Foo___str__ unsafe.Pointer - -func _swig_wrap_Foo___str__(base SwigcptrFoo) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo___str__, _swig_p) - return -} - -func (arg1 SwigcptrFoo) X__str__() (_swig_ret string) { - return _swig_wrap_Foo___str__(arg1) -} - -var _wrap_delete_Foo unsafe.Pointer - -func _swig_wrap_delete_Foo(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Foo, _swig_p) - return -} - -func DeleteFoo(arg1 Foo) { - _swig_wrap_delete_Foo(arg1.Swigcptr()) -} - -type Foo interface { - Swigcptr() uintptr - SwigIsFoo() - SetNum(arg2 int) - GetNum() (_swig_ret int) - Func1(arg2 int) (_swig_ret int) - Func2(arg2 int) (_swig_ret int) - SetFunc_ptr(arg2 _swig_memberptr) - GetFunc_ptr() (_swig_ret _swig_memberptr) - X__str__() (_swig_ret string) -} - -type SwigcptrFooSub uintptr - -func (p SwigcptrFooSub) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrFooSub) SwigIsFooSub() { -} - -var _wrap_new_FooSub unsafe.Pointer - -func _swig_wrap_new_FooSub() (base SwigcptrFooSub) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_FooSub, _swig_p) - return -} - -func NewFooSub() (_swig_ret FooSub) { - return _swig_wrap_new_FooSub() -} - -var _wrap_delete_FooSub unsafe.Pointer - -func _swig_wrap_delete_FooSub(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_FooSub, _swig_p) - return -} - -func DeleteFooSub(arg1 FooSub) { - _swig_wrap_delete_FooSub(arg1.Swigcptr()) -} - -var _wrap_SetFooSub_Num unsafe.Pointer - -func _swig_wrap_SetFooSub_Num(base SwigcptrFooSub, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_SetFooSub_Num, _swig_p) - return -} - -func (_swig_base SwigcptrFooSub) SetNum(arg1 int) { - _swig_wrap_SetFooSub_Num(_swig_base, arg1) -} - -var _wrap_GetFooSub_Num unsafe.Pointer - -func _swig_wrap_GetFooSub_Num(base SwigcptrFooSub) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_GetFooSub_Num, _swig_p) - return -} - -func (_swig_base SwigcptrFooSub) GetNum() (_swig_ret int) { - return _swig_wrap_GetFooSub_Num(_swig_base) -} - -var _wrap_FooSub_func1 unsafe.Pointer - -func _swig_wrap_FooSub_func1(base SwigcptrFooSub, _ int) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_FooSub_func1, _swig_p) - return -} - -func (_swig_base SwigcptrFooSub) Func1(arg1 int) (_swig_ret int) { - return _swig_wrap_FooSub_func1(_swig_base, arg1) -} - -var _wrap_FooSub_func2 unsafe.Pointer - -func _swig_wrap_FooSub_func2(base SwigcptrFooSub, _ int) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_FooSub_func2, _swig_p) - return -} - -func (_swig_base SwigcptrFooSub) Func2(arg1 int) (_swig_ret int) { - return _swig_wrap_FooSub_func2(_swig_base, arg1) -} - -var _wrap_SetFooSub_Func_ptr unsafe.Pointer - -func _swig_wrap_SetFooSub_Func_ptr(base SwigcptrFooSub, _ _swig_memberptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_SetFooSub_Func_ptr, _swig_p) - return -} - -func (_swig_base SwigcptrFooSub) SetFunc_ptr(arg1 _swig_memberptr) { - _swig_wrap_SetFooSub_Func_ptr(_swig_base, arg1) -} - -var _wrap_GetFooSub_Func_ptr unsafe.Pointer - -func _swig_wrap_GetFooSub_Func_ptr(base SwigcptrFooSub) (_ _swig_memberptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_GetFooSub_Func_ptr, _swig_p) - return -} - -func (_swig_base SwigcptrFooSub) GetFunc_ptr() (_swig_ret _swig_memberptr) { - return _swig_wrap_GetFooSub_Func_ptr(_swig_base) -} - -var _wrap_FooSub___str__ unsafe.Pointer - -func _swig_wrap_FooSub___str__(base SwigcptrFooSub) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_FooSub___str__, _swig_p) - return -} - -func (_swig_base SwigcptrFooSub) X__str__() (_swig_ret string) { - return _swig_wrap_FooSub___str__(_swig_base) -} - -func (p SwigcptrFooSub) SwigIsFoo() { -} - -func (p SwigcptrFooSub) SwigGetFoo() Foo { - return SwigcptrFoo(p.Swigcptr()) -} - -type FooSub interface { - Swigcptr() uintptr - SwigIsFooSub() - SetNum(arg1 int) - GetNum() (_swig_ret int) - Func1(arg1 int) (_swig_ret int) - Func2(arg1 int) (_swig_ret int) - SetFunc_ptr(arg1 _swig_memberptr) - GetFunc_ptr() (_swig_ret _swig_memberptr) - X__str__() (_swig_ret string) - SwigIsFoo() - SwigGetFoo() Foo -} - -type SwigcptrFooSubSub uintptr - -func (p SwigcptrFooSubSub) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrFooSubSub) SwigIsFooSubSub() { -} - -var _wrap_new_FooSubSub unsafe.Pointer - -func _swig_wrap_new_FooSubSub() (base SwigcptrFooSubSub) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_FooSubSub, _swig_p) - return -} - -func NewFooSubSub() (_swig_ret FooSubSub) { - return _swig_wrap_new_FooSubSub() -} - -var _wrap_FooSubSub___str__ unsafe.Pointer - -func _swig_wrap_FooSubSub___str__(base SwigcptrFooSubSub) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_FooSubSub___str__, _swig_p) - return -} - -func (arg1 SwigcptrFooSubSub) X__str__() (_swig_ret string) { - return _swig_wrap_FooSubSub___str__(arg1) -} - -var _wrap_delete_FooSubSub unsafe.Pointer - -func _swig_wrap_delete_FooSubSub(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_FooSubSub, _swig_p) - return -} - -func DeleteFooSubSub(arg1 FooSubSub) { - _swig_wrap_delete_FooSubSub(arg1.Swigcptr()) -} - -var _wrap_SetFooSubSub_Num unsafe.Pointer - -func _swig_wrap_SetFooSubSub_Num(base SwigcptrFooSubSub, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_SetFooSubSub_Num, _swig_p) - return -} - -func (_swig_base SwigcptrFooSubSub) SetNum(arg1 int) { - _swig_wrap_SetFooSubSub_Num(_swig_base, arg1) -} - -var _wrap_GetFooSubSub_Num unsafe.Pointer - -func _swig_wrap_GetFooSubSub_Num(base SwigcptrFooSubSub) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_GetFooSubSub_Num, _swig_p) - return -} - -func (_swig_base SwigcptrFooSubSub) GetNum() (_swig_ret int) { - return _swig_wrap_GetFooSubSub_Num(_swig_base) -} - -var _wrap_FooSubSub_func1 unsafe.Pointer - -func _swig_wrap_FooSubSub_func1(base SwigcptrFooSubSub, _ int) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_FooSubSub_func1, _swig_p) - return -} - -func (_swig_base SwigcptrFooSubSub) Func1(arg1 int) (_swig_ret int) { - return _swig_wrap_FooSubSub_func1(_swig_base, arg1) -} - -var _wrap_FooSubSub_func2 unsafe.Pointer - -func _swig_wrap_FooSubSub_func2(base SwigcptrFooSubSub, _ int) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_FooSubSub_func2, _swig_p) - return -} - -func (_swig_base SwigcptrFooSubSub) Func2(arg1 int) (_swig_ret int) { - return _swig_wrap_FooSubSub_func2(_swig_base, arg1) -} - -var _wrap_SetFooSubSub_Func_ptr unsafe.Pointer - -func _swig_wrap_SetFooSubSub_Func_ptr(base SwigcptrFooSubSub, _ _swig_memberptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_SetFooSubSub_Func_ptr, _swig_p) - return -} - -func (_swig_base SwigcptrFooSubSub) SetFunc_ptr(arg1 _swig_memberptr) { - _swig_wrap_SetFooSubSub_Func_ptr(_swig_base, arg1) -} - -var _wrap_GetFooSubSub_Func_ptr unsafe.Pointer - -func _swig_wrap_GetFooSubSub_Func_ptr(base SwigcptrFooSubSub) (_ _swig_memberptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_GetFooSubSub_Func_ptr, _swig_p) - return -} - -func (_swig_base SwigcptrFooSubSub) GetFunc_ptr() (_swig_ret _swig_memberptr) { - return _swig_wrap_GetFooSubSub_Func_ptr(_swig_base) -} - -func (p SwigcptrFooSubSub) SwigIsFooSub() { -} - -func (p SwigcptrFooSubSub) SwigGetFooSub() FooSub { - return SwigcptrFooSub(p.Swigcptr()) -} - -func (p SwigcptrFooSubSub) SwigIsFoo() { -} - -func (p SwigcptrFooSubSub) SwigGetFoo() Foo { - return SwigcptrFoo(p.Swigcptr()) -} - -type FooSubSub interface { - Swigcptr() uintptr - SwigIsFooSubSub() - X__str__() (_swig_ret string) - SetNum(arg1 int) - GetNum() (_swig_ret int) - Func1(arg1 int) (_swig_ret int) - Func2(arg1 int) (_swig_ret int) - SetFunc_ptr(arg1 _swig_memberptr) - GetFunc_ptr() (_swig_ret _swig_memberptr) - SwigIsFooSub() - SwigGetFooSub() FooSub - SwigIsFoo() - SwigGetFoo() Foo -} - -type SwigcptrBar uintptr - -func (p SwigcptrBar) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrBar) SwigIsBar() { -} - -var _wrap_new_Bar unsafe.Pointer - -func _swig_wrap_new_Bar() (base SwigcptrBar) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Bar, _swig_p) - return -} - -func NewBar() (_swig_ret Bar) { - return _swig_wrap_new_Bar() -} - -var _wrap_Bar_fptr_set unsafe.Pointer - -func _swig_wrap_Bar_fptr_set(base SwigcptrBar, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Bar_fptr_set, _swig_p) - return -} - -func (arg1 SwigcptrBar) SetFptr(arg2 Foo) { - _swig_wrap_Bar_fptr_set(arg1, arg2.Swigcptr()) -} - -var _wrap_Bar_fptr_get unsafe.Pointer - -func _swig_wrap_Bar_fptr_get(base SwigcptrBar) (_ SwigcptrFoo) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Bar_fptr_get, _swig_p) - return -} - -func (arg1 SwigcptrBar) GetFptr() (_swig_ret Foo) { - return _swig_wrap_Bar_fptr_get(arg1) -} - -var _wrap_Bar_fref_set unsafe.Pointer - -func _swig_wrap_Bar_fref_set(base SwigcptrBar, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Bar_fref_set, _swig_p) - return -} - -func (arg1 SwigcptrBar) SetFref(arg2 Foo) { - _swig_wrap_Bar_fref_set(arg1, arg2.Swigcptr()) -} - -var _wrap_Bar_fref_get unsafe.Pointer - -func _swig_wrap_Bar_fref_get(base SwigcptrBar) (_ SwigcptrFoo) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Bar_fref_get, _swig_p) - return -} - -func (arg1 SwigcptrBar) GetFref() (_swig_ret Foo) { - return _swig_wrap_Bar_fref_get(arg1) -} - -var _wrap_Bar_fval_set unsafe.Pointer - -func _swig_wrap_Bar_fval_set(base SwigcptrBar, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Bar_fval_set, _swig_p) - return -} - -func (arg1 SwigcptrBar) SetFval(arg2 Foo) { - _swig_wrap_Bar_fval_set(arg1, arg2.Swigcptr()) -} - -var _wrap_Bar_fval_get unsafe.Pointer - -func _swig_wrap_Bar_fval_get(base SwigcptrBar) (_ SwigcptrFoo) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Bar_fval_get, _swig_p) - return -} - -func (arg1 SwigcptrBar) GetFval() (_swig_ret Foo) { - return _swig_wrap_Bar_fval_get(arg1) -} - -var _wrap_Bar_cint_get unsafe.Pointer - -func _swig_wrap_Bar_cint_get(base SwigcptrBar) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Bar_cint_get, _swig_p) - return -} - -func (arg1 SwigcptrBar) GetCint() (_swig_ret int) { - return _swig_wrap_Bar_cint_get(arg1) -} - -var _wrap_Bar_global_cint_Bar unsafe.Pointer - -func _swig_getBar_Bar_global_cint_Bar() (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_Bar_global_cint_Bar, _swig_p) - return -} -var BarGlobal_cint int = _swig_getBar_Bar_global_cint_Bar() -var _wrap_Bar_global_fptr_set unsafe.Pointer - -func _swig_wrap_Bar_global_fptr_set(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Bar_global_fptr_set, _swig_p) - return -} - -func SetBarGlobal_fptr(arg1 Foo) { - _swig_wrap_Bar_global_fptr_set(arg1.Swigcptr()) -} - -var _wrap_Bar_global_fptr_get unsafe.Pointer - -func _swig_wrap_Bar_global_fptr_get() (base SwigcptrFoo) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Bar_global_fptr_get, _swig_p) - return -} - -func GetBarGlobal_fptr() (_swig_ret Foo) { - return _swig_wrap_Bar_global_fptr_get() -} - -var _wrap_Bar_global_fref_set unsafe.Pointer - -func _swig_wrap_Bar_global_fref_set(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Bar_global_fref_set, _swig_p) - return -} - -func SetBarGlobal_fref(arg1 Foo) { - _swig_wrap_Bar_global_fref_set(arg1.Swigcptr()) -} - -var _wrap_Bar_global_fref_get unsafe.Pointer - -func _swig_wrap_Bar_global_fref_get() (base SwigcptrFoo) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Bar_global_fref_get, _swig_p) - return -} - -func GetBarGlobal_fref() (_swig_ret Foo) { - return _swig_wrap_Bar_global_fref_get() -} - -var _wrap_Bar_global_fval_set unsafe.Pointer - -func _swig_wrap_Bar_global_fval_set(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Bar_global_fval_set, _swig_p) - return -} - -func SetBarGlobal_fval(arg1 Foo) { - _swig_wrap_Bar_global_fval_set(arg1.Swigcptr()) -} - -var _wrap_Bar_global_fval_get unsafe.Pointer - -func _swig_wrap_Bar_global_fval_get() (base SwigcptrFoo) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Bar_global_fval_get, _swig_p) - return -} - -func GetBarGlobal_fval() (_swig_ret Foo) { - return _swig_wrap_Bar_global_fval_get() -} - -var _wrap_Bar_test unsafe.Pointer - -func _swig_wrap_Bar_test(base SwigcptrBar, _ int, _ uintptr) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Bar_test, _swig_p) - return -} - -func (arg1 SwigcptrBar) Test(arg2 int, arg3 Foo) (_swig_ret int) { - return _swig_wrap_Bar_test(arg1, arg2, arg3.Swigcptr()) -} - -var _wrap_Bar_testFoo unsafe.Pointer - -func _swig_wrap_Bar_testFoo(base SwigcptrBar, _ int, _ uintptr) (_ SwigcptrFoo) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Bar_testFoo, _swig_p) - return -} - -func (arg1 SwigcptrBar) TestFoo(arg2 int, arg3 Foo) (_swig_ret Foo) { - return _swig_wrap_Bar_testFoo(arg1, arg2, arg3.Swigcptr()) -} - -var _wrap_delete_Bar unsafe.Pointer - -func _swig_wrap_delete_Bar(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Bar, _swig_p) - return -} - -func DeleteBar(arg1 Bar) { - _swig_wrap_delete_Bar(arg1.Swigcptr()) -} - -type Bar interface { - Swigcptr() uintptr - SwigIsBar() - SetFptr(arg2 Foo) - GetFptr() (_swig_ret Foo) - SetFref(arg2 Foo) - GetFref() (_swig_ret Foo) - SetFval(arg2 Foo) - GetFval() (_swig_ret Foo) - GetCint() (_swig_ret int) - Test(arg2 int, arg3 Foo) (_swig_ret int) - TestFoo(arg2 int, arg3 Foo) (_swig_ret Foo) -} - -var _wrap_get_func1_ptr unsafe.Pointer - -func Get_func1_ptr() (_swig_ret _swig_memberptr) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_get_func1_ptr, _swig_p) - return -} -var _wrap_get_func2_ptr unsafe.Pointer - -func Get_func2_ptr() (_swig_ret _swig_memberptr) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_get_func2_ptr, _swig_p) - return -} -var _wrap_test_func_ptr unsafe.Pointer - -func _swig_wrap_test_func_ptr(base uintptr, _ int) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_test_func_ptr, _swig_p) - return -} - -func Test_func_ptr(arg1 Foo, arg2 int) (_swig_ret int) { - return _swig_wrap_test_func_ptr(arg1.Swigcptr(), arg2) -} - -type SwigcptrFl_Window uintptr - -func (p SwigcptrFl_Window) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrFl_Window) SwigIsFl_Window() { -} - -var _wrap_new_Fl_Window unsafe.Pointer - -func _swig_wrap_new_Fl_Window() (base SwigcptrFl_Window) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Fl_Window, _swig_p) - return -} - -func NewFl_Window() (_swig_ret Fl_Window) { - return _swig_wrap_new_Fl_Window() -} - -var _wrap_delete_Fl_Window unsafe.Pointer - -func _swig_wrap_delete_Fl_Window(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Fl_Window, _swig_p) - return -} - -func DeleteFl_Window(arg1 Fl_Window) { - _swig_wrap_delete_Fl_Window(arg1.Swigcptr()) -} - -var _wrap_Fl_Window_show__SWIG_0 unsafe.Pointer - -func _swig_wrap_Fl_Window_show__SWIG_0(base SwigcptrFl_Window, _ uintptr, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Fl_Window_show__SWIG_0, _swig_p) - return -} - -func (arg1 SwigcptrFl_Window) Show__SWIG_0(arg2 uintptr, arg3 uintptr) { - _swig_wrap_Fl_Window_show__SWIG_0(arg1, arg2, arg3) -} - -var _wrap_Fl_Window_show__SWIG_1 unsafe.Pointer - -func _swig_wrap_Fl_Window_show__SWIG_1(base SwigcptrFl_Window, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Fl_Window_show__SWIG_1, _swig_p) - return -} - -func (arg1 SwigcptrFl_Window) Show__SWIG_1(arg2 uintptr) { - _swig_wrap_Fl_Window_show__SWIG_1(arg1, arg2) -} - -var _wrap_Fl_Window_show__SWIG_2 unsafe.Pointer - -func _swig_wrap_Fl_Window_show__SWIG_2(base SwigcptrFl_Window) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Fl_Window_show__SWIG_2, _swig_p) - return -} - -func (arg1 SwigcptrFl_Window) Show__SWIG_2() { - _swig_wrap_Fl_Window_show__SWIG_2(arg1) -} - -func (p SwigcptrFl_Window) Show(a ...interface{}) { - argc := len(a) - if argc == 0 { - p.Show__SWIG_2() - return - } - if argc == 1 { - p.Show__SWIG_1(a[0].(uintptr)) - return - } - if argc == 2 { - p.Show__SWIG_0(a[0].(uintptr), a[1].(uintptr)) - return - } - panic("No match for overloaded function call") -} - -type Fl_Window interface { - Swigcptr() uintptr - SwigIsFl_Window() - Show(a ...interface{}) -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/cpp_enum.go b/Examples/test-suite/go/cpp_enum.go deleted file mode 100644 index 4b9bec1a3..000000000 --- a/Examples/test-suite/go/cpp_enum.go +++ /dev/null @@ -1,354 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../cpp_enum.i - -package cpp_enum - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SOME_ENUM int -var _wrap_ENUM_ONE unsafe.Pointer - -func _swig_getENUM_ONE() (_swig_ret SOME_ENUM) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_ENUM_ONE, _swig_p) - return -} -var ENUM_ONE SOME_ENUM = _swig_getENUM_ONE() -var _wrap_ENUM_TWO unsafe.Pointer - -func _swig_getENUM_TWO() (_swig_ret SOME_ENUM) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_ENUM_TWO, _swig_p) - return -} -var ENUM_TWO SOME_ENUM = _swig_getENUM_TWO() -type SwigcptrStructWithEnums uintptr - -func (p SwigcptrStructWithEnums) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrStructWithEnums) SwigIsStructWithEnums() { -} - -var _wrap_new_StructWithEnums unsafe.Pointer - -func _swig_wrap_new_StructWithEnums() (base SwigcptrStructWithEnums) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_StructWithEnums, _swig_p) - return -} - -func NewStructWithEnums() (_swig_ret StructWithEnums) { - return _swig_wrap_new_StructWithEnums() -} - -var _wrap_StructWithEnums_some_enum_set unsafe.Pointer - -func _swig_wrap_StructWithEnums_some_enum_set(base SwigcptrStructWithEnums, _ SOME_ENUM) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_StructWithEnums_some_enum_set, _swig_p) - return -} - -func (arg1 SwigcptrStructWithEnums) SetSome_enum(arg2 SOME_ENUM) { - _swig_wrap_StructWithEnums_some_enum_set(arg1, arg2) -} - -var _wrap_StructWithEnums_some_enum_get unsafe.Pointer - -func _swig_wrap_StructWithEnums_some_enum_get(base SwigcptrStructWithEnums) (_ SOME_ENUM) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_StructWithEnums_some_enum_get, _swig_p) - return -} - -func (arg1 SwigcptrStructWithEnums) GetSome_enum() (_swig_ret SOME_ENUM) { - return _swig_wrap_StructWithEnums_some_enum_get(arg1) -} - -var _wrap_StructWithEnums_enum_test1 unsafe.Pointer - -func _swig_wrap_StructWithEnums_enum_test1(base SwigcptrStructWithEnums, _ SOME_ENUM, _ *SOME_ENUM, _ *SOME_ENUM) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_StructWithEnums_enum_test1, _swig_p) - return -} - -func (arg1 SwigcptrStructWithEnums) Enum_test1(arg2 SOME_ENUM, arg3 *SOME_ENUM, arg4 *SOME_ENUM) { - _swig_wrap_StructWithEnums_enum_test1(arg1, arg2, arg3, arg4) -} - -var _wrap_StructWithEnums_enum_test2 unsafe.Pointer - -func _swig_wrap_StructWithEnums_enum_test2(base SwigcptrStructWithEnums, _ SOME_ENUM, _ *SOME_ENUM, _ *SOME_ENUM) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_StructWithEnums_enum_test2, _swig_p) - return -} - -func (arg1 SwigcptrStructWithEnums) Enum_test2(arg2 SOME_ENUM, arg3 *SOME_ENUM, arg4 *SOME_ENUM) { - _swig_wrap_StructWithEnums_enum_test2(arg1, arg2, arg3, arg4) -} - -var _wrap_StructWithEnums_enum_test3 unsafe.Pointer - -func _swig_wrap_StructWithEnums_enum_test3(base SwigcptrStructWithEnums) (_ SOME_ENUM) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_StructWithEnums_enum_test3, _swig_p) - return -} - -func (arg1 SwigcptrStructWithEnums) Enum_test3() (_swig_ret SOME_ENUM) { - return _swig_wrap_StructWithEnums_enum_test3(arg1) -} - -var _wrap_StructWithEnums_enum_test4 unsafe.Pointer - -func _swig_wrap_StructWithEnums_enum_test4(base SwigcptrStructWithEnums) (_ SOME_ENUM) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_StructWithEnums_enum_test4, _swig_p) - return -} - -func (arg1 SwigcptrStructWithEnums) Enum_test4() (_swig_ret SOME_ENUM) { - return _swig_wrap_StructWithEnums_enum_test4(arg1) -} - -var _wrap_StructWithEnums_enum_test5 unsafe.Pointer - -func _swig_wrap_StructWithEnums_enum_test5(base SwigcptrStructWithEnums) (_ *SOME_ENUM) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_StructWithEnums_enum_test5, _swig_p) - return -} - -func (arg1 SwigcptrStructWithEnums) Enum_test5() (_swig_ret *SOME_ENUM) { - return _swig_wrap_StructWithEnums_enum_test5(arg1) -} - -var _wrap_StructWithEnums_enum_test6 unsafe.Pointer - -func _swig_wrap_StructWithEnums_enum_test6(base SwigcptrStructWithEnums) (_ *SOME_ENUM) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_StructWithEnums_enum_test6, _swig_p) - return -} - -func (arg1 SwigcptrStructWithEnums) Enum_test6() (_swig_ret *SOME_ENUM) { - return _swig_wrap_StructWithEnums_enum_test6(arg1) -} - -var _wrap_StructWithEnums_enum_test7 unsafe.Pointer - -func _swig_wrap_StructWithEnums_enum_test7(base SwigcptrStructWithEnums) (_ *SOME_ENUM) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_StructWithEnums_enum_test7, _swig_p) - return -} - -func (arg1 SwigcptrStructWithEnums) Enum_test7() (_swig_ret *SOME_ENUM) { - return _swig_wrap_StructWithEnums_enum_test7(arg1) -} - -var _wrap_StructWithEnums_enum_test8 unsafe.Pointer - -func _swig_wrap_StructWithEnums_enum_test8(base SwigcptrStructWithEnums) (_ *SOME_ENUM) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_StructWithEnums_enum_test8, _swig_p) - return -} - -func (arg1 SwigcptrStructWithEnums) Enum_test8() (_swig_ret *SOME_ENUM) { - return _swig_wrap_StructWithEnums_enum_test8(arg1) -} - -var _wrap_delete_StructWithEnums unsafe.Pointer - -func _swig_wrap_delete_StructWithEnums(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_StructWithEnums, _swig_p) - return -} - -func DeleteStructWithEnums(arg1 StructWithEnums) { - _swig_wrap_delete_StructWithEnums(arg1.Swigcptr()) -} - -type StructWithEnums interface { - Swigcptr() uintptr - SwigIsStructWithEnums() - SetSome_enum(arg2 SOME_ENUM) - GetSome_enum() (_swig_ret SOME_ENUM) - Enum_test1(arg2 SOME_ENUM, arg3 *SOME_ENUM, arg4 *SOME_ENUM) - Enum_test2(arg2 SOME_ENUM, arg3 *SOME_ENUM, arg4 *SOME_ENUM) - Enum_test3() (_swig_ret SOME_ENUM) - Enum_test4() (_swig_ret SOME_ENUM) - Enum_test5() (_swig_ret *SOME_ENUM) - Enum_test6() (_swig_ret *SOME_ENUM) - Enum_test7() (_swig_ret *SOME_ENUM) - Enum_test8() (_swig_ret *SOME_ENUM) -} - -type SwigcptrFoo uintptr - -func (p SwigcptrFoo) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrFoo) SwigIsFoo() { -} - -var _wrap_Hi_Foo unsafe.Pointer - -func _swig_getFoo_Hi_Foo() (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_Hi_Foo, _swig_p) - return -} -var FooHi int = _swig_getFoo_Hi_Foo() -var _wrap_Hello_Foo unsafe.Pointer - -func _swig_getFoo_Hello_Foo() (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_Hello_Foo, _swig_p) - return -} -var FooHello int = _swig_getFoo_Hello_Foo() -var _wrap_Foo_hola_set unsafe.Pointer - -func _swig_wrap_Foo_hola_set(base SwigcptrFoo, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_hola_set, _swig_p) - return -} - -func (arg1 SwigcptrFoo) SetHola(arg2 int) { - _swig_wrap_Foo_hola_set(arg1, arg2) -} - -var _wrap_Foo_hola_get unsafe.Pointer - -func _swig_wrap_Foo_hola_get(base SwigcptrFoo) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_hola_get, _swig_p) - return -} - -func (arg1 SwigcptrFoo) GetHola() (_swig_ret int) { - return _swig_wrap_Foo_hola_get(arg1) -} - -var _wrap_new_Foo unsafe.Pointer - -func _swig_wrap_new_Foo() (base SwigcptrFoo) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Foo, _swig_p) - return -} - -func NewFoo() (_swig_ret Foo) { - return _swig_wrap_new_Foo() -} - -var _wrap_delete_Foo unsafe.Pointer - -func _swig_wrap_delete_Foo(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Foo, _swig_p) - return -} - -func DeleteFoo(arg1 Foo) { - _swig_wrap_delete_Foo(arg1.Swigcptr()) -} - -type Foo interface { - Swigcptr() uintptr - SwigIsFoo() - SetHola(arg2 int) - GetHola() (_swig_ret int) -} - -var _wrap_Hi unsafe.Pointer - -func _swig_getHi() (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_Hi, _swig_p) - return -} -var Hi int = _swig_getHi() -var _wrap_Hello unsafe.Pointer - -func _swig_getHello() (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_Hello, _swig_p) - return -} -var Hello int = _swig_getHello() -var _wrap_hi_set unsafe.Pointer - -func _swig_wrap_hi_set(base int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_hi_set, _swig_p) - return -} - -func SetHi(arg1 int) { - _swig_wrap_hi_set(arg1) -} - -var _wrap_hi_get unsafe.Pointer - -func GetHi() (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_hi_get, _swig_p) - return -} -type Play_state int -var _wrap_PLAY unsafe.Pointer - -func _swig_getPLAY() (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_PLAY, _swig_p) - return -} -var PLAY int = _swig_getPLAY() -var _wrap_STOP unsafe.Pointer - -func _swig_getSTOP() (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_STOP, _swig_p) - return -} -var STOP int = _swig_getSTOP() - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/cpp_enum_runme b/Examples/test-suite/go/cpp_enum_runme deleted file mode 100755 index 164b08eba..000000000 Binary files a/Examples/test-suite/go/cpp_enum_runme and /dev/null differ diff --git a/Examples/test-suite/go/cpp_namespace.go b/Examples/test-suite/go/cpp_namespace.go deleted file mode 100644 index fdab5cbbf..000000000 --- a/Examples/test-suite/go/cpp_namespace.go +++ /dev/null @@ -1,418 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../cpp_namespace.i - -package cpp_namespace - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -var _wrap_fact unsafe.Pointer - -func Fact(arg1 int) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_fact, _swig_p) - return -} -var _wrap_Foo_set unsafe.Pointer - -func _swig_wrap_Foo_set(base int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_set, _swig_p) - return -} - -func SetFoo(arg1 int) { - _swig_wrap_Foo_set(arg1) -} - -var _wrap_Foo_get unsafe.Pointer - -func GetFoo() (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_Foo_get, _swig_p) - return -} -type SwigcptrTest uintptr - -func (p SwigcptrTest) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrTest) SwigIsTest() { -} - -var _wrap_new_Test unsafe.Pointer - -func _swig_wrap_new_Test() (base SwigcptrTest) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Test, _swig_p) - return -} - -func NewTest() (_swig_ret Test) { - return _swig_wrap_new_Test() -} - -var _wrap_delete_Test unsafe.Pointer - -func _swig_wrap_delete_Test(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Test, _swig_p) - return -} - -func DeleteTest(arg1 Test) { - _swig_wrap_delete_Test(arg1.Swigcptr()) -} - -var _wrap_Test_method unsafe.Pointer - -func _swig_wrap_Test_method(base SwigcptrTest) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Test_method, _swig_p) - return -} - -func (arg1 SwigcptrTest) Method() (_swig_ret string) { - return _swig_wrap_Test_method(arg1) -} - -type Test interface { - Swigcptr() uintptr - SwigIsTest() - Method() (_swig_ret string) -} - -var _wrap_weird unsafe.Pointer - -func _swig_wrap_weird(base string, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_weird, _swig_p) - return -} - -func Weird(arg1 string, arg2 int) { - _swig_wrap_weird(arg1, arg2) -} - -var _wrap_do_method unsafe.Pointer - -func _swig_wrap_do_method(base uintptr) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_do_method, _swig_p) - return -} - -func Do_method(arg1 Test) (_swig_ret string) { - return _swig_wrap_do_method(arg1.Swigcptr()) -} - -var _wrap_do_method2 unsafe.Pointer - -func _swig_wrap_do_method2(base uintptr) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_do_method2, _swig_p) - return -} - -func Do_method2(arg1 Test) (_swig_ret string) { - return _swig_wrap_do_method2(arg1.Swigcptr()) -} - -type SwigcptrTest2 uintptr - -func (p SwigcptrTest2) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrTest2) SwigIsTest2() { -} - -var _wrap_delete_Test2 unsafe.Pointer - -func _swig_wrap_delete_Test2(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Test2, _swig_p) - return -} - -func DeleteTest2(arg1 Test2) { - _swig_wrap_delete_Test2(arg1.Swigcptr()) -} - -var _wrap_Test2_method unsafe.Pointer - -func _swig_wrap_Test2_method(base SwigcptrTest2) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Test2_method, _swig_p) - return -} - -func (arg1 SwigcptrTest2) Method() (_swig_ret string) { - return _swig_wrap_Test2_method(arg1) -} - -var _wrap_new_Test2 unsafe.Pointer - -func _swig_wrap_new_Test2() (base SwigcptrTest2) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Test2, _swig_p) - return -} - -func NewTest2() (_swig_ret Test2) { - return _swig_wrap_new_Test2() -} - -type Test2 interface { - Swigcptr() uintptr - SwigIsTest2() - Method() (_swig_ret string) -} - -type SwigcptrTest3 uintptr - -func (p SwigcptrTest3) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrTest3) SwigIsTest3() { -} - -var _wrap_Test3_method unsafe.Pointer - -func _swig_wrap_Test3_method(base SwigcptrTest3) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Test3_method, _swig_p) - return -} - -func (arg1 SwigcptrTest3) Method() (_swig_ret string) { - return _swig_wrap_Test3_method(arg1) -} - -var _wrap_new_Test3 unsafe.Pointer - -func _swig_wrap_new_Test3() (base SwigcptrTest3) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Test3, _swig_p) - return -} - -func NewTest3() (_swig_ret Test3) { - return _swig_wrap_new_Test3() -} - -var _wrap_delete_Test3 unsafe.Pointer - -func _swig_wrap_delete_Test3(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Test3, _swig_p) - return -} - -func DeleteTest3(arg1 Test3) { - _swig_wrap_delete_Test3(arg1.Swigcptr()) -} - -func (p SwigcptrTest3) SwigIsTest2() { -} - -func (p SwigcptrTest3) SwigGetTest2() Test2 { - return SwigcptrTest2(p.Swigcptr()) -} - -type Test3 interface { - Swigcptr() uintptr - SwigIsTest3() - Method() (_swig_ret string) - SwigIsTest2() - SwigGetTest2() Test2 -} - -type SwigcptrTest4 uintptr - -func (p SwigcptrTest4) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrTest4) SwigIsTest4() { -} - -var _wrap_Test4_method unsafe.Pointer - -func _swig_wrap_Test4_method(base SwigcptrTest4) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Test4_method, _swig_p) - return -} - -func (arg1 SwigcptrTest4) Method() (_swig_ret string) { - return _swig_wrap_Test4_method(arg1) -} - -var _wrap_new_Test4 unsafe.Pointer - -func _swig_wrap_new_Test4() (base SwigcptrTest4) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Test4, _swig_p) - return -} - -func NewTest4() (_swig_ret Test4) { - return _swig_wrap_new_Test4() -} - -var _wrap_delete_Test4 unsafe.Pointer - -func _swig_wrap_delete_Test4(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Test4, _swig_p) - return -} - -func DeleteTest4(arg1 Test4) { - _swig_wrap_delete_Test4(arg1.Swigcptr()) -} - -func (p SwigcptrTest4) SwigIsTest3() { -} - -func (p SwigcptrTest4) SwigGetTest3() Test3 { - return SwigcptrTest3(p.Swigcptr()) -} - -func (p SwigcptrTest4) SwigIsTest2() { -} - -func (p SwigcptrTest4) SwigGetTest2() Test2 { - return SwigcptrTest2(p.Swigcptr()) -} - -type Test4 interface { - Swigcptr() uintptr - SwigIsTest4() - Method() (_swig_ret string) - SwigIsTest3() - SwigGetTest3() Test3 - SwigIsTest2() - SwigGetTest2() Test2 -} - -var _wrap_foo3 unsafe.Pointer - -func Foo3(arg1 int) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_foo3, _swig_p) - return -} -type SwigcptrTest5 uintptr - -func (p SwigcptrTest5) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrTest5) SwigIsTest5() { -} - -var _wrap_Test5_method unsafe.Pointer - -func _swig_wrap_Test5_method(base SwigcptrTest5) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Test5_method, _swig_p) - return -} - -func (arg1 SwigcptrTest5) Method() (_swig_ret string) { - return _swig_wrap_Test5_method(arg1) -} - -var _wrap_new_Test5 unsafe.Pointer - -func _swig_wrap_new_Test5() (base SwigcptrTest5) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Test5, _swig_p) - return -} - -func NewTest5() (_swig_ret Test5) { - return _swig_wrap_new_Test5() -} - -var _wrap_delete_Test5 unsafe.Pointer - -func _swig_wrap_delete_Test5(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Test5, _swig_p) - return -} - -func DeleteTest5(arg1 Test5) { - _swig_wrap_delete_Test5(arg1.Swigcptr()) -} - -func (p SwigcptrTest5) SwigIsTest3() { -} - -func (p SwigcptrTest5) SwigGetTest3() Test3 { - return SwigcptrTest3(p.Swigcptr()) -} - -func (p SwigcptrTest5) SwigIsTest2() { -} - -func (p SwigcptrTest5) SwigGetTest2() Test2 { - return SwigcptrTest2(p.Swigcptr()) -} - -type Test5 interface { - Swigcptr() uintptr - SwigIsTest5() - Method() (_swig_ret string) - SwigIsTest3() - SwigGetTest3() Test3 - SwigIsTest2() - SwigGetTest2() Test2 -} - -var _wrap_do_method3 unsafe.Pointer - -func _swig_wrap_do_method3(base uintptr, _ int) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_do_method3, _swig_p) - return -} - -func Do_method3(arg1 Test2, arg2 int) (_swig_ret string) { - return _swig_wrap_do_method3(arg1.Swigcptr(), arg2) -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/cpp_namespace_runme b/Examples/test-suite/go/cpp_namespace_runme deleted file mode 100755 index e5937721e..000000000 Binary files a/Examples/test-suite/go/cpp_namespace_runme and /dev/null differ diff --git a/Examples/test-suite/go/cpp_nodefault.go b/Examples/test-suite/go/cpp_nodefault.go deleted file mode 100644 index 512492b01..000000000 --- a/Examples/test-suite/go/cpp_nodefault.go +++ /dev/null @@ -1,213 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../cpp_nodefault.i - -package cpp_nodefault - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrFoo uintptr - -func (p SwigcptrFoo) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrFoo) SwigIsFoo() { -} - -var _wrap_Foo_a_set unsafe.Pointer - -func _swig_wrap_Foo_a_set(base SwigcptrFoo, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_a_set, _swig_p) - return -} - -func (arg1 SwigcptrFoo) SetA(arg2 int) { - _swig_wrap_Foo_a_set(arg1, arg2) -} - -var _wrap_Foo_a_get unsafe.Pointer - -func _swig_wrap_Foo_a_get(base SwigcptrFoo) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_a_get, _swig_p) - return -} - -func (arg1 SwigcptrFoo) GetA() (_swig_ret int) { - return _swig_wrap_Foo_a_get(arg1) -} - -var _wrap_new_Foo unsafe.Pointer - -func _swig_wrap_new_Foo(base int, _ int) (_ SwigcptrFoo) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Foo, _swig_p) - return -} - -func NewFoo(arg1 int, arg2 int) (_swig_ret Foo) { - return _swig_wrap_new_Foo(arg1, arg2) -} - -var _wrap_delete_Foo unsafe.Pointer - -func _swig_wrap_delete_Foo(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Foo, _swig_p) - return -} - -func DeleteFoo(arg1 Foo) { - _swig_wrap_delete_Foo(arg1.Swigcptr()) -} - -type Foo interface { - Swigcptr() uintptr - SwigIsFoo() - SetA(arg2 int) - GetA() (_swig_ret int) -} - -var _wrap_create unsafe.Pointer - -func _swig_wrap_create(base int, _ int) (_ SwigcptrFoo) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_create, _swig_p) - return -} - -func Create(arg1 int, arg2 int) (_swig_ret Foo) { - return _swig_wrap_create(arg1, arg2) -} - -var _wrap_consume unsafe.Pointer - -func _swig_wrap_consume(base uintptr, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_consume, _swig_p) - return -} - -func Consume(arg1 Foo, arg2 Foo) { - _swig_wrap_consume(arg1.Swigcptr(), arg2.Swigcptr()) -} - -type SwigcptrBar uintptr - -func (p SwigcptrBar) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrBar) SwigIsBar() { -} - -var _wrap_Bar_consume unsafe.Pointer - -func _swig_wrap_Bar_consume(base SwigcptrBar, _ uintptr, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Bar_consume, _swig_p) - return -} - -func (arg1 SwigcptrBar) Consume(arg2 Foo, arg3 Foo) { - _swig_wrap_Bar_consume(arg1, arg2.Swigcptr(), arg3.Swigcptr()) -} - -var _wrap_Bar_create unsafe.Pointer - -func _swig_wrap_Bar_create(base SwigcptrBar, _ int, _ int) (_ SwigcptrFoo) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Bar_create, _swig_p) - return -} - -func (arg1 SwigcptrBar) Create(arg2 int, arg3 int) (_swig_ret Foo) { - return _swig_wrap_Bar_create(arg1, arg2, arg3) -} - -var _wrap_new_Bar unsafe.Pointer - -func _swig_wrap_new_Bar() (base SwigcptrBar) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Bar, _swig_p) - return -} - -func NewBar() (_swig_ret Bar) { - return _swig_wrap_new_Bar() -} - -var _wrap_delete_Bar unsafe.Pointer - -func _swig_wrap_delete_Bar(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Bar, _swig_p) - return -} - -func DeleteBar(arg1 Bar) { - _swig_wrap_delete_Bar(arg1.Swigcptr()) -} - -type Bar interface { - Swigcptr() uintptr - SwigIsBar() - Consume(arg2 Foo, arg3 Foo) - Create(arg2 int, arg3 int) (_swig_ret Foo) -} - -var _wrap_gvar_set unsafe.Pointer - -func _swig_wrap_gvar_set(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_gvar_set, _swig_p) - return -} - -func SetGvar(arg1 Foo) { - _swig_wrap_gvar_set(arg1.Swigcptr()) -} - -var _wrap_gvar_get unsafe.Pointer - -func _swig_wrap_gvar_get() (base SwigcptrFoo) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_gvar_get, _swig_p) - return -} - -func GetGvar() (_swig_ret Foo) { - return _swig_wrap_gvar_get() -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/cpp_static.go b/Examples/test-suite/go/cpp_static.go deleted file mode 100644 index 77b9aec1a..000000000 --- a/Examples/test-suite/go/cpp_static.go +++ /dev/null @@ -1,168 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../cpp_static.i - -package cpp_static - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrStaticMemberTest uintptr - -func (p SwigcptrStaticMemberTest) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrStaticMemberTest) SwigIsStaticMemberTest() { -} - -var _wrap_StaticMemberTest_static_int_set unsafe.Pointer - -func _swig_wrap_StaticMemberTest_static_int_set(base int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_StaticMemberTest_static_int_set, _swig_p) - return -} - -func SetStaticMemberTestStatic_int(arg1 int) { - _swig_wrap_StaticMemberTest_static_int_set(arg1) -} - -var _wrap_StaticMemberTest_static_int_get unsafe.Pointer - -func GetStaticMemberTestStatic_int() (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_StaticMemberTest_static_int_get, _swig_p) - return -} -var _wrap_new_StaticMemberTest unsafe.Pointer - -func _swig_wrap_new_StaticMemberTest() (base SwigcptrStaticMemberTest) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_StaticMemberTest, _swig_p) - return -} - -func NewStaticMemberTest() (_swig_ret StaticMemberTest) { - return _swig_wrap_new_StaticMemberTest() -} - -var _wrap_delete_StaticMemberTest unsafe.Pointer - -func _swig_wrap_delete_StaticMemberTest(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_StaticMemberTest, _swig_p) - return -} - -func DeleteStaticMemberTest(arg1 StaticMemberTest) { - _swig_wrap_delete_StaticMemberTest(arg1.Swigcptr()) -} - -type StaticMemberTest interface { - Swigcptr() uintptr - SwigIsStaticMemberTest() -} - -type SwigcptrStaticFunctionTest uintptr - -func (p SwigcptrStaticFunctionTest) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrStaticFunctionTest) SwigIsStaticFunctionTest() { -} - -var _wrap_StaticFunctionTest_static_func unsafe.Pointer - -func _swig_wrap_StaticFunctionTest_static_func() { - var _swig_p uintptr - _cgo_runtime_cgocall(_wrap_StaticFunctionTest_static_func, _swig_p) - return -} - -func StaticFunctionTestStatic_func() { - _swig_wrap_StaticFunctionTest_static_func() -} - -var _wrap_StaticFunctionTest_static_func_2 unsafe.Pointer - -func _swig_wrap_StaticFunctionTest_static_func_2(base int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_StaticFunctionTest_static_func_2, _swig_p) - return -} - -func StaticFunctionTestStatic_func_2(arg1 int) { - _swig_wrap_StaticFunctionTest_static_func_2(arg1) -} - -var _wrap_StaticFunctionTest_static_func_3 unsafe.Pointer - -func _swig_wrap_StaticFunctionTest_static_func_3(base int, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_StaticFunctionTest_static_func_3, _swig_p) - return -} - -func StaticFunctionTestStatic_func_3(arg1 int, arg2 int) { - _swig_wrap_StaticFunctionTest_static_func_3(arg1, arg2) -} - -var _wrap_new_StaticFunctionTest unsafe.Pointer - -func _swig_wrap_new_StaticFunctionTest() (base SwigcptrStaticFunctionTest) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_StaticFunctionTest, _swig_p) - return -} - -func NewStaticFunctionTest() (_swig_ret StaticFunctionTest) { - return _swig_wrap_new_StaticFunctionTest() -} - -var _wrap_delete_StaticFunctionTest unsafe.Pointer - -func _swig_wrap_delete_StaticFunctionTest(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_StaticFunctionTest, _swig_p) - return -} - -func DeleteStaticFunctionTest(arg1 StaticFunctionTest) { - _swig_wrap_delete_StaticFunctionTest(arg1.Swigcptr()) -} - -type StaticFunctionTest interface { - Swigcptr() uintptr - SwigIsStaticFunctionTest() -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/cpp_static_runme b/Examples/test-suite/go/cpp_static_runme deleted file mode 100755 index 47143aee9..000000000 Binary files a/Examples/test-suite/go/cpp_static_runme and /dev/null differ diff --git a/Examples/test-suite/go/cpp_typedef.go b/Examples/test-suite/go/cpp_typedef.go deleted file mode 100644 index eaa2bf1c5..000000000 --- a/Examples/test-suite/go/cpp_typedef.go +++ /dev/null @@ -1,352 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../cpp_typedef.i - -package cpp_typedef - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrFoo uintptr - -func (p SwigcptrFoo) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrFoo) SwigIsFoo() { -} - -var _wrap_Foo_bar unsafe.Pointer - -func _swig_wrap_Foo_bar(base SwigcptrFoo) (_ SwigcptrBar) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_bar, _swig_p) - return -} - -func (arg1 SwigcptrFoo) Bar() (_swig_ret Bar) { - return _swig_wrap_Foo_bar(arg1) -} - -var _wrap_Foo_sbar unsafe.Pointer - -func _swig_wrap_Foo_sbar() (base SwigcptrBar) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_sbar, _swig_p) - return -} - -func FooSbar() (_swig_ret Bar) { - return _swig_wrap_Foo_sbar() -} - -var _wrap_new_Foo unsafe.Pointer - -func _swig_wrap_new_Foo() (base SwigcptrFoo) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Foo, _swig_p) - return -} - -func NewFoo() (_swig_ret Foo) { - return _swig_wrap_new_Foo() -} - -var _wrap_delete_Foo unsafe.Pointer - -func _swig_wrap_delete_Foo(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Foo, _swig_p) - return -} - -func DeleteFoo(arg1 Foo) { - _swig_wrap_delete_Foo(arg1.Swigcptr()) -} - -type Foo interface { - Swigcptr() uintptr - SwigIsFoo() - Bar() (_swig_ret Bar) -} - -type SwigcptrUnnamedStruct uintptr - -func (p SwigcptrUnnamedStruct) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrUnnamedStruct) SwigIsUnnamedStruct() { -} - -var _wrap_UnnamedStruct_something_set unsafe.Pointer - -func _swig_wrap_UnnamedStruct_something_set(base SwigcptrUnnamedStruct, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_UnnamedStruct_something_set, _swig_p) - return -} - -func (arg1 SwigcptrUnnamedStruct) SetSomething(arg2 int) { - _swig_wrap_UnnamedStruct_something_set(arg1, arg2) -} - -var _wrap_UnnamedStruct_something_get unsafe.Pointer - -func _swig_wrap_UnnamedStruct_something_get(base SwigcptrUnnamedStruct) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_UnnamedStruct_something_get, _swig_p) - return -} - -func (arg1 SwigcptrUnnamedStruct) GetSomething() (_swig_ret int) { - return _swig_wrap_UnnamedStruct_something_get(arg1) -} - -var _wrap_UnnamedStruct_m unsafe.Pointer - -func _swig_wrap_UnnamedStruct_m(base SwigcptrUnnamedStruct) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_UnnamedStruct_m, _swig_p) - return -} - -func (arg1 SwigcptrUnnamedStruct) M() { - _swig_wrap_UnnamedStruct_m(arg1) -} - -var _wrap_new_UnnamedStruct unsafe.Pointer - -func _swig_wrap_new_UnnamedStruct() (base SwigcptrUnnamedStruct) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_UnnamedStruct, _swig_p) - return -} - -func NewUnnamedStruct() (_swig_ret UnnamedStruct) { - return _swig_wrap_new_UnnamedStruct() -} - -var _wrap_delete_UnnamedStruct unsafe.Pointer - -func _swig_wrap_delete_UnnamedStruct(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_UnnamedStruct, _swig_p) - return -} - -func DeleteUnnamedStruct(arg1 UnnamedStruct) { - _swig_wrap_delete_UnnamedStruct(arg1.Swigcptr()) -} - -type UnnamedStruct interface { - Swigcptr() uintptr - SwigIsUnnamedStruct() - SetSomething(arg2 int) - GetSomething() (_swig_ret int) - M() -} - -type SwigcptrTypedefNamedStruct uintptr - -func (p SwigcptrTypedefNamedStruct) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrTypedefNamedStruct) SwigIsTypedefNamedStruct() { -} - -var _wrap_TypedefNamedStruct_something_set unsafe.Pointer - -func _swig_wrap_TypedefNamedStruct_something_set(base SwigcptrTypedefNamedStruct, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_TypedefNamedStruct_something_set, _swig_p) - return -} - -func (arg1 SwigcptrTypedefNamedStruct) SetSomething(arg2 int) { - _swig_wrap_TypedefNamedStruct_something_set(arg1, arg2) -} - -var _wrap_TypedefNamedStruct_something_get unsafe.Pointer - -func _swig_wrap_TypedefNamedStruct_something_get(base SwigcptrTypedefNamedStruct) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_TypedefNamedStruct_something_get, _swig_p) - return -} - -func (arg1 SwigcptrTypedefNamedStruct) GetSomething() (_swig_ret int) { - return _swig_wrap_TypedefNamedStruct_something_get(arg1) -} - -var _wrap_TypedefNamedStruct_m unsafe.Pointer - -func _swig_wrap_TypedefNamedStruct_m(base SwigcptrTypedefNamedStruct) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_TypedefNamedStruct_m, _swig_p) - return -} - -func (arg1 SwigcptrTypedefNamedStruct) M() { - _swig_wrap_TypedefNamedStruct_m(arg1) -} - -var _wrap_new_TypedefNamedStruct unsafe.Pointer - -func _swig_wrap_new_TypedefNamedStruct() (base SwigcptrTypedefNamedStruct) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_TypedefNamedStruct, _swig_p) - return -} - -func NewTypedefNamedStruct() (_swig_ret TypedefNamedStruct) { - return _swig_wrap_new_TypedefNamedStruct() -} - -var _wrap_delete_TypedefNamedStruct unsafe.Pointer - -func _swig_wrap_delete_TypedefNamedStruct(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_TypedefNamedStruct, _swig_p) - return -} - -func DeleteTypedefNamedStruct(arg1 TypedefNamedStruct) { - _swig_wrap_delete_TypedefNamedStruct(arg1.Swigcptr()) -} - -type TypedefNamedStruct interface { - Swigcptr() uintptr - SwigIsTypedefNamedStruct() - SetSomething(arg2 int) - GetSomething() (_swig_ret int) - M() -} - -type SwigcptrTest uintptr - -func (p SwigcptrTest) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrTest) SwigIsTest() { -} - -var _wrap_Test_test1 unsafe.Pointer - -func _swig_wrap_Test_test1(base SwigcptrTest, _ uintptr) (_ SwigcptrUnnamedStruct) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Test_test1, _swig_p) - return -} - -func (arg1 SwigcptrTest) Test1(arg2 UnnamedStruct) (_swig_ret UnnamedStruct) { - return _swig_wrap_Test_test1(arg1, arg2.Swigcptr()) -} - -var _wrap_Test_test2 unsafe.Pointer - -func _swig_wrap_Test_test2(base SwigcptrTest, _ uintptr) (_ SwigcptrTypedefNamedStruct) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Test_test2, _swig_p) - return -} - -func (arg1 SwigcptrTest) Test2(arg2 TypedefNamedStruct) (_swig_ret TypedefNamedStruct) { - return _swig_wrap_Test_test2(arg1, arg2.Swigcptr()) -} - -var _wrap_Test_test3 unsafe.Pointer - -func _swig_wrap_Test_test3(base SwigcptrTest, _ uintptr) (_ SwigcptrTypedefNamedStruct) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Test_test3, _swig_p) - return -} - -func (arg1 SwigcptrTest) Test3(arg2 TypedefNamedStruct) (_swig_ret TypedefNamedStruct) { - return _swig_wrap_Test_test3(arg1, arg2.Swigcptr()) -} - -var _wrap_Test_test4 unsafe.Pointer - -func _swig_wrap_Test_test4(base SwigcptrTest, _ uintptr) (_ SwigcptrTypedefNamedStruct) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Test_test4, _swig_p) - return -} - -func (arg1 SwigcptrTest) Test4(arg2 TypedefNamedStruct) (_swig_ret TypedefNamedStruct) { - return _swig_wrap_Test_test4(arg1, arg2.Swigcptr()) -} - -var _wrap_new_Test unsafe.Pointer - -func _swig_wrap_new_Test() (base SwigcptrTest) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Test, _swig_p) - return -} - -func NewTest() (_swig_ret Test) { - return _swig_wrap_new_Test() -} - -var _wrap_delete_Test unsafe.Pointer - -func _swig_wrap_delete_Test(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Test, _swig_p) - return -} - -func DeleteTest(arg1 Test) { - _swig_wrap_delete_Test(arg1.Swigcptr()) -} - -type Test interface { - Swigcptr() uintptr - SwigIsTest() - Test1(arg2 UnnamedStruct) (_swig_ret UnnamedStruct) - Test2(arg2 TypedefNamedStruct) (_swig_ret TypedefNamedStruct) - Test3(arg2 TypedefNamedStruct) (_swig_ret TypedefNamedStruct) - Test4(arg2 TypedefNamedStruct) (_swig_ret TypedefNamedStruct) -} - - -type SwigcptrBar uintptr -type Bar interface { - Swigcptr() uintptr; -} -func (p SwigcptrBar) Swigcptr() uintptr { - return uintptr(p) -} - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/curiously_recurring_template_pattern.go b/Examples/test-suite/go/curiously_recurring_template_pattern.go deleted file mode 100644 index b2e4e8066..000000000 --- a/Examples/test-suite/go/curiously_recurring_template_pattern.go +++ /dev/null @@ -1,278 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../curiously_recurring_template_pattern.i - -package curiously_recurring_template_pattern - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrBasederived uintptr - -func (p SwigcptrBasederived) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrBasederived) SwigIsBasederived() { -} - -var _wrap_new_basederived unsafe.Pointer - -func _swig_wrap_new_basederived() (base SwigcptrBasederived) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_basederived, _swig_p) - return -} - -func NewBasederived() (_swig_ret Basederived) { - return _swig_wrap_new_basederived() -} - -var _wrap_basederived_getBase1Param unsafe.Pointer - -func _swig_wrap_basederived_getBase1Param(base SwigcptrBasederived) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_basederived_getBase1Param, _swig_p) - return -} - -func (arg1 SwigcptrBasederived) GetBase1Param() (_swig_ret int) { - return _swig_wrap_basederived_getBase1Param(arg1) -} - -var _wrap_basederived_setBase1Param unsafe.Pointer - -func _swig_wrap_basederived_setBase1Param(base SwigcptrBasederived, _ int) (_ SwigcptrDerived) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_basederived_setBase1Param, _swig_p) - return -} - -func (arg1 SwigcptrBasederived) SetBase1Param(arg2 int) (_swig_ret Derived) { - return _swig_wrap_basederived_setBase1Param(arg1, arg2) -} - -var _wrap_basederived_getBase2Param unsafe.Pointer - -func _swig_wrap_basederived_getBase2Param(base SwigcptrBasederived) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_basederived_getBase2Param, _swig_p) - return -} - -func (arg1 SwigcptrBasederived) GetBase2Param() (_swig_ret int) { - return _swig_wrap_basederived_getBase2Param(arg1) -} - -var _wrap_basederived_setBase2Param unsafe.Pointer - -func _swig_wrap_basederived_setBase2Param(base SwigcptrBasederived, _ int) (_ SwigcptrDerived) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_basederived_setBase2Param, _swig_p) - return -} - -func (arg1 SwigcptrBasederived) SetBase2Param(arg2 int) (_swig_ret Derived) { - return _swig_wrap_basederived_setBase2Param(arg1, arg2) -} - -var _wrap_delete_basederived unsafe.Pointer - -func _swig_wrap_delete_basederived(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_basederived, _swig_p) - return -} - -func DeleteBasederived(arg1 Basederived) { - _swig_wrap_delete_basederived(arg1.Swigcptr()) -} - -type Basederived interface { - Swigcptr() uintptr - SwigIsBasederived() - GetBase1Param() (_swig_ret int) - SetBase1Param(arg2 int) (_swig_ret Derived) - GetBase2Param() (_swig_ret int) - SetBase2Param(arg2 int) (_swig_ret Derived) -} - -type SwigcptrDerived uintptr - -func (p SwigcptrDerived) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrDerived) SwigIsDerived() { -} - -var _wrap_new_Derived unsafe.Pointer - -func _swig_wrap_new_Derived() (base SwigcptrDerived) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Derived, _swig_p) - return -} - -func NewDerived() (_swig_ret Derived) { - return _swig_wrap_new_Derived() -} - -var _wrap_Derived_getDerived1Param unsafe.Pointer - -func _swig_wrap_Derived_getDerived1Param(base SwigcptrDerived) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Derived_getDerived1Param, _swig_p) - return -} - -func (arg1 SwigcptrDerived) GetDerived1Param() (_swig_ret int) { - return _swig_wrap_Derived_getDerived1Param(arg1) -} - -var _wrap_Derived_setDerived1Param unsafe.Pointer - -func _swig_wrap_Derived_setDerived1Param(base SwigcptrDerived, _ int) (_ SwigcptrDerived) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Derived_setDerived1Param, _swig_p) - return -} - -func (arg1 SwigcptrDerived) SetDerived1Param(arg2 int) (_swig_ret Derived) { - return _swig_wrap_Derived_setDerived1Param(arg1, arg2) -} - -var _wrap_Derived_getDerived2Param unsafe.Pointer - -func _swig_wrap_Derived_getDerived2Param(base SwigcptrDerived) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Derived_getDerived2Param, _swig_p) - return -} - -func (arg1 SwigcptrDerived) GetDerived2Param() (_swig_ret int) { - return _swig_wrap_Derived_getDerived2Param(arg1) -} - -var _wrap_Derived_setDerived2Param unsafe.Pointer - -func _swig_wrap_Derived_setDerived2Param(base SwigcptrDerived, _ int) (_ SwigcptrDerived) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Derived_setDerived2Param, _swig_p) - return -} - -func (arg1 SwigcptrDerived) SetDerived2Param(arg2 int) (_swig_ret Derived) { - return _swig_wrap_Derived_setDerived2Param(arg1, arg2) -} - -var _wrap_delete_Derived unsafe.Pointer - -func _swig_wrap_delete_Derived(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Derived, _swig_p) - return -} - -func DeleteDerived(arg1 Derived) { - _swig_wrap_delete_Derived(arg1.Swigcptr()) -} - -var _wrap_Derived_getBase1Param unsafe.Pointer - -func _swig_wrap_Derived_getBase1Param(base SwigcptrDerived) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Derived_getBase1Param, _swig_p) - return -} - -func (_swig_base SwigcptrDerived) GetBase1Param() (_swig_ret int) { - return _swig_wrap_Derived_getBase1Param(_swig_base) -} - -var _wrap_Derived_setBase1Param unsafe.Pointer - -func _swig_wrap_Derived_setBase1Param(base SwigcptrDerived, _ int) (_ SwigcptrDerived) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Derived_setBase1Param, _swig_p) - return -} - -func (_swig_base SwigcptrDerived) SetBase1Param(arg1 int) (_swig_ret Derived) { - return _swig_wrap_Derived_setBase1Param(_swig_base, arg1) -} - -var _wrap_Derived_getBase2Param unsafe.Pointer - -func _swig_wrap_Derived_getBase2Param(base SwigcptrDerived) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Derived_getBase2Param, _swig_p) - return -} - -func (_swig_base SwigcptrDerived) GetBase2Param() (_swig_ret int) { - return _swig_wrap_Derived_getBase2Param(_swig_base) -} - -var _wrap_Derived_setBase2Param unsafe.Pointer - -func _swig_wrap_Derived_setBase2Param(base SwigcptrDerived, _ int) (_ SwigcptrDerived) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Derived_setBase2Param, _swig_p) - return -} - -func (_swig_base SwigcptrDerived) SetBase2Param(arg1 int) (_swig_ret Derived) { - return _swig_wrap_Derived_setBase2Param(_swig_base, arg1) -} - -func (p SwigcptrDerived) SwigIsBasederived() { -} - -func (p SwigcptrDerived) SwigGetBasederived() Basederived { - return SwigcptrBasederived(p.Swigcptr()) -} - -type Derived interface { - Swigcptr() uintptr - SwigIsDerived() - GetDerived1Param() (_swig_ret int) - SetDerived1Param(arg2 int) (_swig_ret Derived) - GetDerived2Param() (_swig_ret int) - SetDerived2Param(arg2 int) (_swig_ret Derived) - GetBase1Param() (_swig_ret int) - SetBase1Param(arg1 int) (_swig_ret Derived) - GetBase2Param() (_swig_ret int) - SetBase2Param(arg1 int) (_swig_ret Derived) - SwigIsBasederived() - SwigGetBasederived() Basederived -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/default_arg_values.go b/Examples/test-suite/go/default_arg_values.go deleted file mode 100644 index a87e1f055..000000000 --- a/Examples/test-suite/go/default_arg_values.go +++ /dev/null @@ -1,154 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../default_arg_values.i - -package default_arg_values - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrDisplay uintptr - -func (p SwigcptrDisplay) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrDisplay) SwigIsDisplay() { -} - -var _wrap_Display_draw1__SWIG_0 unsafe.Pointer - -func _swig_wrap_Display_draw1__SWIG_0(base SwigcptrDisplay, _ float32) (_ float32) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Display_draw1__SWIG_0, _swig_p) - return -} - -func (arg1 SwigcptrDisplay) Draw1__SWIG_0(arg2 float32) (_swig_ret float32) { - return _swig_wrap_Display_draw1__SWIG_0(arg1, arg2) -} - -var _wrap_Display_draw1__SWIG_1 unsafe.Pointer - -func _swig_wrap_Display_draw1__SWIG_1(base SwigcptrDisplay) (_ float32) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Display_draw1__SWIG_1, _swig_p) - return -} - -func (arg1 SwigcptrDisplay) Draw1__SWIG_1() (_swig_ret float32) { - return _swig_wrap_Display_draw1__SWIG_1(arg1) -} - -func (p SwigcptrDisplay) Draw1(a ...interface{}) float32 { - argc := len(a) - if argc == 0 { - return p.Draw1__SWIG_1() - } - if argc == 1 { - return p.Draw1__SWIG_0(a[0].(float32)) - } - panic("No match for overloaded function call") -} - -var _wrap_Display_draw2__SWIG_0 unsafe.Pointer - -func _swig_wrap_Display_draw2__SWIG_0(base SwigcptrDisplay, _ *float32) (_ float32) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Display_draw2__SWIG_0, _swig_p) - return -} - -func (arg1 SwigcptrDisplay) Draw2__SWIG_0(arg2 *float32) (_swig_ret float32) { - return _swig_wrap_Display_draw2__SWIG_0(arg1, arg2) -} - -var _wrap_Display_draw2__SWIG_1 unsafe.Pointer - -func _swig_wrap_Display_draw2__SWIG_1(base SwigcptrDisplay) (_ float32) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Display_draw2__SWIG_1, _swig_p) - return -} - -func (arg1 SwigcptrDisplay) Draw2__SWIG_1() (_swig_ret float32) { - return _swig_wrap_Display_draw2__SWIG_1(arg1) -} - -func (p SwigcptrDisplay) Draw2(a ...interface{}) float32 { - argc := len(a) - if argc == 0 { - return p.Draw2__SWIG_1() - } - if argc == 1 { - return p.Draw2__SWIG_0(a[0].(*float32)) - } - panic("No match for overloaded function call") -} - -var _wrap_new_Display unsafe.Pointer - -func _swig_wrap_new_Display() (base SwigcptrDisplay) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Display, _swig_p) - return -} - -func NewDisplay() (_swig_ret Display) { - return _swig_wrap_new_Display() -} - -var _wrap_delete_Display unsafe.Pointer - -func _swig_wrap_delete_Display(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Display, _swig_p) - return -} - -func DeleteDisplay(arg1 Display) { - _swig_wrap_delete_Display(arg1.Swigcptr()) -} - -type Display interface { - Swigcptr() uintptr - SwigIsDisplay() - Draw1(a ...interface{}) float32 - Draw2(a ...interface{}) float32 -} - -var _wrap_createPtr unsafe.Pointer - -func CreatePtr(arg1 float32) (_swig_ret *float32) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_createPtr, _swig_p) - return -} - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/default_args.go b/Examples/test-suite/go/default_args.go deleted file mode 100644 index 8933b5b42..000000000 --- a/Examples/test-suite/go/default_args.go +++ /dev/null @@ -1,1719 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../default_args.i - -package default_args - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -var _wrap_anonymous__SWIG_0 unsafe.Pointer - -func Anonymous__SWIG_0(arg1 int) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_anonymous__SWIG_0, _swig_p) - return -} -var _wrap_anonymous__SWIG_1 unsafe.Pointer - -func Anonymous__SWIG_1() (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_anonymous__SWIG_1, _swig_p) - return -} -func Anonymous(a ...interface{}) int { - argc := len(a) - if argc == 0 { - return Anonymous__SWIG_1() - } - if argc == 1 { - return Anonymous__SWIG_0(a[0].(int)) - } - panic("No match for overloaded function call") -} - -var _wrap_booltest__SWIG_0 unsafe.Pointer - -func Booltest__SWIG_0(arg1 bool) (_swig_ret bool) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_booltest__SWIG_0, _swig_p) - return -} -var _wrap_booltest__SWIG_1 unsafe.Pointer - -func Booltest__SWIG_1() (_swig_ret bool) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_booltest__SWIG_1, _swig_p) - return -} -func Booltest(a ...interface{}) bool { - argc := len(a) - if argc == 0 { - return Booltest__SWIG_1() - } - if argc == 1 { - return Booltest__SWIG_0(a[0].(bool)) - } - panic("No match for overloaded function call") -} - -type Flavor int -var _wrap_BITTER unsafe.Pointer - -func _swig_getBITTER() (_swig_ret Flavor) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_BITTER, _swig_p) - return -} -var BITTER Flavor = _swig_getBITTER() -var _wrap_SWEET unsafe.Pointer - -func _swig_getSWEET() (_swig_ret Flavor) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_SWEET, _swig_p) - return -} -var SWEET Flavor = _swig_getSWEET() -type SwigcptrEnumClass uintptr - -func (p SwigcptrEnumClass) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrEnumClass) SwigIsEnumClass() { -} - -type EnumClassSpeed int -var _wrap_FAST_EnumClass unsafe.Pointer - -func _swig_getEnumClass_FAST_EnumClass() (_swig_ret EnumClassSpeed) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_FAST_EnumClass, _swig_p) - return -} -var EnumClassFAST EnumClassSpeed = _swig_getEnumClass_FAST_EnumClass() -var _wrap_SLOW_EnumClass unsafe.Pointer - -func _swig_getEnumClass_SLOW_EnumClass() (_swig_ret EnumClassSpeed) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_SLOW_EnumClass, _swig_p) - return -} -var EnumClassSLOW EnumClassSpeed = _swig_getEnumClass_SLOW_EnumClass() -var _wrap_EnumClass_blah__SWIG_0 unsafe.Pointer - -func _swig_wrap_EnumClass_blah__SWIG_0(base SwigcptrEnumClass, _ EnumClassSpeed, _ Flavor) (_ bool) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_EnumClass_blah__SWIG_0, _swig_p) - return -} - -func (arg1 SwigcptrEnumClass) Blah__SWIG_0(arg2 EnumClassSpeed, arg3 Flavor) (_swig_ret bool) { - return _swig_wrap_EnumClass_blah__SWIG_0(arg1, arg2, arg3) -} - -var _wrap_EnumClass_blah__SWIG_1 unsafe.Pointer - -func _swig_wrap_EnumClass_blah__SWIG_1(base SwigcptrEnumClass, _ EnumClassSpeed) (_ bool) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_EnumClass_blah__SWIG_1, _swig_p) - return -} - -func (arg1 SwigcptrEnumClass) Blah__SWIG_1(arg2 EnumClassSpeed) (_swig_ret bool) { - return _swig_wrap_EnumClass_blah__SWIG_1(arg1, arg2) -} - -var _wrap_EnumClass_blah__SWIG_2 unsafe.Pointer - -func _swig_wrap_EnumClass_blah__SWIG_2(base SwigcptrEnumClass) (_ bool) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_EnumClass_blah__SWIG_2, _swig_p) - return -} - -func (arg1 SwigcptrEnumClass) Blah__SWIG_2() (_swig_ret bool) { - return _swig_wrap_EnumClass_blah__SWIG_2(arg1) -} - -func (p SwigcptrEnumClass) Blah(a ...interface{}) bool { - argc := len(a) - if argc == 0 { - return p.Blah__SWIG_2() - } - if argc == 1 { - return p.Blah__SWIG_1(a[0].(EnumClassSpeed)) - } - if argc == 2 { - return p.Blah__SWIG_0(a[0].(EnumClassSpeed), a[1].(Flavor)) - } - panic("No match for overloaded function call") -} - -var _wrap_new_EnumClass unsafe.Pointer - -func _swig_wrap_new_EnumClass() (base SwigcptrEnumClass) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_EnumClass, _swig_p) - return -} - -func NewEnumClass() (_swig_ret EnumClass) { - return _swig_wrap_new_EnumClass() -} - -var _wrap_delete_EnumClass unsafe.Pointer - -func _swig_wrap_delete_EnumClass(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_EnumClass, _swig_p) - return -} - -func DeleteEnumClass(arg1 EnumClass) { - _swig_wrap_delete_EnumClass(arg1.Swigcptr()) -} - -type EnumClass interface { - Swigcptr() uintptr - SwigIsEnumClass() - Blah(a ...interface{}) bool -} - -var _wrap_casts1__SWIG_0 unsafe.Pointer - -func Casts1__SWIG_0(arg1 string) (_swig_ret string) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_casts1__SWIG_0, _swig_p) - return -} -var _wrap_casts1__SWIG_1 unsafe.Pointer - -func Casts1__SWIG_1() (_swig_ret string) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_casts1__SWIG_1, _swig_p) - return -} -func Casts1(a ...interface{}) string { - argc := len(a) - if argc == 0 { - return Casts1__SWIG_1() - } - if argc == 1 { - return Casts1__SWIG_0(a[0].(string)) - } - panic("No match for overloaded function call") -} - -var _wrap_casts2__SWIG_0 unsafe.Pointer - -func Casts2__SWIG_0(arg1 string) (_swig_ret string) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_casts2__SWIG_0, _swig_p) - return -} -var _wrap_casts2__SWIG_1 unsafe.Pointer - -func Casts2__SWIG_1() (_swig_ret string) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_casts2__SWIG_1, _swig_p) - return -} -func Casts2(a ...interface{}) string { - argc := len(a) - if argc == 0 { - return Casts2__SWIG_1() - } - if argc == 1 { - return Casts2__SWIG_0(a[0].(string)) - } - panic("No match for overloaded function call") -} - -var _wrap_chartest1__SWIG_0 unsafe.Pointer - -func Chartest1__SWIG_0(arg1 byte) (_swig_ret byte) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_chartest1__SWIG_0, _swig_p) - return -} -var _wrap_chartest1__SWIG_1 unsafe.Pointer - -func Chartest1__SWIG_1() (_swig_ret byte) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_chartest1__SWIG_1, _swig_p) - return -} -func Chartest1(a ...interface{}) byte { - argc := len(a) - if argc == 0 { - return Chartest1__SWIG_1() - } - if argc == 1 { - return Chartest1__SWIG_0(a[0].(byte)) - } - panic("No match for overloaded function call") -} - -var _wrap_chartest2__SWIG_0 unsafe.Pointer - -func Chartest2__SWIG_0(arg1 byte) (_swig_ret byte) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_chartest2__SWIG_0, _swig_p) - return -} -var _wrap_chartest2__SWIG_1 unsafe.Pointer - -func Chartest2__SWIG_1() (_swig_ret byte) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_chartest2__SWIG_1, _swig_p) - return -} -func Chartest2(a ...interface{}) byte { - argc := len(a) - if argc == 0 { - return Chartest2__SWIG_1() - } - if argc == 1 { - return Chartest2__SWIG_0(a[0].(byte)) - } - panic("No match for overloaded function call") -} - -type ATypeAType int -var _wrap_NoType unsafe.Pointer - -func _swig_getNoType() (_swig_ret ATypeAType) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_NoType, _swig_p) - return -} -var NoType ATypeAType = _swig_getNoType() -var _wrap_dummy__SWIG_0 unsafe.Pointer - -func _swig_wrap_dummy__SWIG_0(base ATypeAType) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_dummy__SWIG_0, _swig_p) - return -} - -func Dummy__SWIG_0(arg1 ATypeAType) { - _swig_wrap_dummy__SWIG_0(arg1) -} - -var _wrap_dummy__SWIG_1 unsafe.Pointer - -func _swig_wrap_dummy__SWIG_1() { - var _swig_p uintptr - _cgo_runtime_cgocall(_wrap_dummy__SWIG_1, _swig_p) - return -} - -func Dummy__SWIG_1() { - _swig_wrap_dummy__SWIG_1() -} - -func Dummy(a ...interface{}) { - argc := len(a) - if argc == 0 { - Dummy__SWIG_1() - return - } - if argc == 1 { - Dummy__SWIG_0(a[0].(ATypeAType)) - return - } - panic("No match for overloaded function call") -} - -var _wrap_CONST_NUM_set unsafe.Pointer - -func _swig_wrap_CONST_NUM_set(base int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_CONST_NUM_set, _swig_p) - return -} - -func SetCONST_NUM(arg1 int) { - _swig_wrap_CONST_NUM_set(arg1) -} - -var _wrap_CONST_NUM_get unsafe.Pointer - -func GetCONST_NUM() (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_CONST_NUM_get, _swig_p) - return -} -var _wrap_afunction__SWIG_0 unsafe.Pointer - -func Afunction__SWIG_0(arg1 int) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_afunction__SWIG_0, _swig_p) - return -} -var _wrap_afunction__SWIG_1 unsafe.Pointer - -func Afunction__SWIG_1() (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_afunction__SWIG_1, _swig_p) - return -} -func Afunction(a ...interface{}) int { - argc := len(a) - if argc == 0 { - return Afunction__SWIG_1() - } - if argc == 1 { - return Afunction__SWIG_0(a[0].(int)) - } - panic("No match for overloaded function call") -} - -var _wrap_reftest1__SWIG_0 unsafe.Pointer - -func Reftest1__SWIG_0(arg1 int) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_reftest1__SWIG_0, _swig_p) - return -} -var _wrap_reftest1__SWIG_1 unsafe.Pointer - -func Reftest1__SWIG_1() (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_reftest1__SWIG_1, _swig_p) - return -} -func Reftest1(a ...interface{}) int { - argc := len(a) - if argc == 0 { - return Reftest1__SWIG_1() - } - if argc == 1 { - return Reftest1__SWIG_0(a[0].(int)) - } - panic("No match for overloaded function call") -} - -var _wrap_reftest2__SWIG_0 unsafe.Pointer - -func Reftest2__SWIG_0(arg1 string) (_swig_ret string) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_reftest2__SWIG_0, _swig_p) - return -} -var _wrap_reftest2__SWIG_1 unsafe.Pointer - -func Reftest2__SWIG_1() (_swig_ret string) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_reftest2__SWIG_1, _swig_p) - return -} -func Reftest2(a ...interface{}) string { - argc := len(a) - if argc == 0 { - return Reftest2__SWIG_1() - } - if argc == 1 { - return Reftest2__SWIG_0(a[0].(string)) - } - panic("No match for overloaded function call") -} - -type SwigcptrTree uintptr - -func (p SwigcptrTree) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrTree) SwigIsTree() { -} - -type TreeTypes int -var _wrap_Oak_Tree unsafe.Pointer - -func _swig_getTree_Oak_Tree() (_swig_ret TreeTypes) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_Oak_Tree, _swig_p) - return -} -var TreeOak TreeTypes = _swig_getTree_Oak_Tree() -var _wrap_Fir_Tree unsafe.Pointer - -func _swig_getTree_Fir_Tree() (_swig_ret TreeTypes) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_Fir_Tree, _swig_p) - return -} -var TreeFir TreeTypes = _swig_getTree_Fir_Tree() -var _wrap_Cedar_Tree unsafe.Pointer - -func _swig_getTree_Cedar_Tree() (_swig_ret TreeTypes) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_Cedar_Tree, _swig_p) - return -} -var TreeCedar TreeTypes = _swig_getTree_Cedar_Tree() -var _wrap_Tree_chops unsafe.Pointer - -func _swig_wrap_Tree_chops(base SwigcptrTree, _ TreeTypes) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Tree_chops, _swig_p) - return -} - -func (arg1 SwigcptrTree) Chops(arg2 TreeTypes) { - _swig_wrap_Tree_chops(arg1, arg2) -} - -var _wrap_Tree_test__SWIG_0 unsafe.Pointer - -func _swig_wrap_Tree_test__SWIG_0(base SwigcptrTree, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Tree_test__SWIG_0, _swig_p) - return -} - -func (arg1 SwigcptrTree) Test__SWIG_0(arg2 int) { - _swig_wrap_Tree_test__SWIG_0(arg1, arg2) -} - -var _wrap_Tree_test__SWIG_1 unsafe.Pointer - -func _swig_wrap_Tree_test__SWIG_1(base SwigcptrTree) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Tree_test__SWIG_1, _swig_p) - return -} - -func (arg1 SwigcptrTree) Test__SWIG_1() { - _swig_wrap_Tree_test__SWIG_1(arg1) -} - -func (p SwigcptrTree) Test(a ...interface{}) { - argc := len(a) - if argc == 0 { - p.Test__SWIG_1() - return - } - if argc == 1 { - p.Test__SWIG_0(a[0].(int)) - return - } - panic("No match for overloaded function call") -} - -var _wrap_new_Tree unsafe.Pointer - -func _swig_wrap_new_Tree() (base SwigcptrTree) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Tree, _swig_p) - return -} - -func NewTree() (_swig_ret Tree) { - return _swig_wrap_new_Tree() -} - -var _wrap_delete_Tree unsafe.Pointer - -func _swig_wrap_delete_Tree(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Tree, _swig_p) - return -} - -func DeleteTree(arg1 Tree) { - _swig_wrap_delete_Tree(arg1.Swigcptr()) -} - -type Tree interface { - Swigcptr() uintptr - SwigIsTree() - Chops(arg2 TreeTypes) - Test(a ...interface{}) -} - -var _wrap_chops unsafe.Pointer - -func Chops(arg1 TreeTypes) (_swig_ret TreeTypes) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_chops, _swig_p) - return -} -type SwigcptrFoo uintptr - -func (p SwigcptrFoo) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrFoo) SwigIsFoo() { -} - -var _wrap_Foo_bar2_set unsafe.Pointer - -func _swig_wrap_Foo_bar2_set(base int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_bar2_set, _swig_p) - return -} - -func SetFooBar2(arg1 int) { - _swig_wrap_Foo_bar2_set(arg1) -} - -var _wrap_Foo_bar2_get unsafe.Pointer - -func GetFooBar2() (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_Foo_bar2_get, _swig_p) - return -} -var _wrap_Foo_spam_set unsafe.Pointer - -func _swig_wrap_Foo_spam_set(base int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_spam_set, _swig_p) - return -} - -func SetFooSpam(arg1 int) { - _swig_wrap_Foo_spam_set(arg1) -} - -var _wrap_Foo_spam_get unsafe.Pointer - -func GetFooSpam() (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_Foo_spam_get, _swig_p) - return -} -var _wrap_new_Foo unsafe.Pointer - -func _swig_wrap_new_Foo() (base SwigcptrFoo) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Foo, _swig_p) - return -} - -func NewFoo() (_swig_ret Foo) { - return _swig_wrap_new_Foo() -} - -var _wrap_Foo_method1__SWIG_0 unsafe.Pointer - -func _swig_wrap_Foo_method1__SWIG_0(base SwigcptrFoo, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_method1__SWIG_0, _swig_p) - return -} - -func (arg1 SwigcptrFoo) Method1__SWIG_0(arg2 int) { - _swig_wrap_Foo_method1__SWIG_0(arg1, arg2) -} - -var _wrap_Foo_method1__SWIG_1 unsafe.Pointer - -func _swig_wrap_Foo_method1__SWIG_1(base SwigcptrFoo) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_method1__SWIG_1, _swig_p) - return -} - -func (arg1 SwigcptrFoo) Method1__SWIG_1() { - _swig_wrap_Foo_method1__SWIG_1(arg1) -} - -func (p SwigcptrFoo) Method1(a ...interface{}) { - argc := len(a) - if argc == 0 { - p.Method1__SWIG_1() - return - } - if argc == 1 { - p.Method1__SWIG_0(a[0].(int)) - return - } - panic("No match for overloaded function call") -} - -var _wrap_Foo_method2__SWIG_0 unsafe.Pointer - -func _swig_wrap_Foo_method2__SWIG_0(base SwigcptrFoo, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_method2__SWIG_0, _swig_p) - return -} - -func (arg1 SwigcptrFoo) Method2__SWIG_0(arg2 int) { - _swig_wrap_Foo_method2__SWIG_0(arg1, arg2) -} - -var _wrap_Foo_method2__SWIG_1 unsafe.Pointer - -func _swig_wrap_Foo_method2__SWIG_1(base SwigcptrFoo) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_method2__SWIG_1, _swig_p) - return -} - -func (arg1 SwigcptrFoo) Method2__SWIG_1() { - _swig_wrap_Foo_method2__SWIG_1(arg1) -} - -func (p SwigcptrFoo) Method2(a ...interface{}) { - argc := len(a) - if argc == 0 { - p.Method2__SWIG_1() - return - } - if argc == 1 { - p.Method2__SWIG_0(a[0].(int)) - return - } - panic("No match for overloaded function call") -} - -var _wrap_Foo_newname__SWIG_0 unsafe.Pointer - -func _swig_wrap_Foo_newname__SWIG_0(base SwigcptrFoo, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_newname__SWIG_0, _swig_p) - return -} - -func (arg1 SwigcptrFoo) Newname__SWIG_0(arg2 int) { - _swig_wrap_Foo_newname__SWIG_0(arg1, arg2) -} - -var _wrap_Foo_newname__SWIG_1 unsafe.Pointer - -func _swig_wrap_Foo_newname__SWIG_1(base SwigcptrFoo) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_newname__SWIG_1, _swig_p) - return -} - -func (arg1 SwigcptrFoo) Newname__SWIG_1() { - _swig_wrap_Foo_newname__SWIG_1(arg1) -} - -func (p SwigcptrFoo) Newname(a ...interface{}) { - argc := len(a) - if argc == 0 { - p.Newname__SWIG_1() - return - } - if argc == 1 { - p.Newname__SWIG_0(a[0].(int)) - return - } - panic("No match for overloaded function call") -} - -var _wrap_Foo_renamed3arg unsafe.Pointer - -func _swig_wrap_Foo_renamed3arg(base SwigcptrFoo, _ int, _ float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_renamed3arg, _swig_p) - return -} - -func (arg1 SwigcptrFoo) Renamed3arg(arg2 int, arg3 float64) { - _swig_wrap_Foo_renamed3arg(arg1, arg2, arg3) -} - -var _wrap_Foo_renamed2arg unsafe.Pointer - -func _swig_wrap_Foo_renamed2arg(base SwigcptrFoo, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_renamed2arg, _swig_p) - return -} - -func (arg1 SwigcptrFoo) Renamed2arg(arg2 int) { - _swig_wrap_Foo_renamed2arg(arg1, arg2) -} - -var _wrap_Foo_renamed1arg unsafe.Pointer - -func _swig_wrap_Foo_renamed1arg(base SwigcptrFoo) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_renamed1arg, _swig_p) - return -} - -func (arg1 SwigcptrFoo) Renamed1arg() { - _swig_wrap_Foo_renamed1arg(arg1) -} - -var _wrap_delete_Foo unsafe.Pointer - -func _swig_wrap_delete_Foo(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Foo, _swig_p) - return -} - -func DeleteFoo(arg1 Foo) { - _swig_wrap_delete_Foo(arg1.Swigcptr()) -} - -type Foo interface { - Swigcptr() uintptr - SwigIsFoo() - Method1(a ...interface{}) - Method2(a ...interface{}) - Newname(a ...interface{}) - Renamed3arg(arg2 int, arg3 float64) - Renamed2arg(arg2 int) - Renamed1arg() -} - -type MyType int -var _wrap_Val1 unsafe.Pointer - -func _swig_getVal1() (_swig_ret MyType) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_Val1, _swig_p) - return -} -var Val1 MyType = _swig_getVal1() -var _wrap_Val2 unsafe.Pointer - -func _swig_getVal2() (_swig_ret MyType) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_Val2, _swig_p) - return -} -var Val2 MyType = _swig_getVal2() -type SwigcptrMyClass1 uintptr - -func (p SwigcptrMyClass1) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrMyClass1) SwigIsMyClass1() { -} - -var _wrap_new_MyClass1 unsafe.Pointer - -func _swig_wrap_new_MyClass1(base MyType) (_ SwigcptrMyClass1) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_MyClass1, _swig_p) - return -} - -func NewMyClass1(arg1 MyType) (_swig_ret MyClass1) { - return _swig_wrap_new_MyClass1(arg1) -} - -var _wrap_delete_MyClass1 unsafe.Pointer - -func _swig_wrap_delete_MyClass1(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_MyClass1, _swig_p) - return -} - -func DeleteMyClass1(arg1 MyClass1) { - _swig_wrap_delete_MyClass1(arg1.Swigcptr()) -} - -type MyClass1 interface { - Swigcptr() uintptr - SwigIsMyClass1() -} - -type SwigcptrMyClass2 uintptr - -func (p SwigcptrMyClass2) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrMyClass2) SwigIsMyClass2() { -} - -var _wrap_MyClass2_set unsafe.Pointer - -func _swig_wrap_MyClass2_set(base int, _ SwigcptrMyClass2, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_MyClass2_set, _swig_p) - return -} - -func (arg1 SwigcptrMyClass2) Set(_swig_args ...interface{}) { - var arg2 MyClass1 - if len(_swig_args) > 0 { - arg2 = _swig_args[0].(MyClass1) - } - _swig_wrap_MyClass2_set(len(_swig_args), arg1, arg2.Swigcptr()) -} - -var _wrap_MyClass2_set2__SWIG_0 unsafe.Pointer - -func _swig_wrap_MyClass2_set2__SWIG_0(base SwigcptrMyClass2, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_MyClass2_set2__SWIG_0, _swig_p) - return -} - -func (arg1 SwigcptrMyClass2) Set2__SWIG_0(arg2 MyClass1) { - _swig_wrap_MyClass2_set2__SWIG_0(arg1, arg2.Swigcptr()) -} - -var _wrap_MyClass2_set2__SWIG_1 unsafe.Pointer - -func _swig_wrap_MyClass2_set2__SWIG_1(base SwigcptrMyClass2) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_MyClass2_set2__SWIG_1, _swig_p) - return -} - -func (arg1 SwigcptrMyClass2) Set2__SWIG_1() { - _swig_wrap_MyClass2_set2__SWIG_1(arg1) -} - -func (p SwigcptrMyClass2) Set2(a ...interface{}) { - argc := len(a) - if argc == 0 { - p.Set2__SWIG_1() - return - } - if argc == 1 { - p.Set2__SWIG_0(a[0].(MyClass1)) - return - } - panic("No match for overloaded function call") -} - -var _wrap_new_MyClass2 unsafe.Pointer - -func _swig_wrap_new_MyClass2() (base SwigcptrMyClass2) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_MyClass2, _swig_p) - return -} - -func NewMyClass2() (_swig_ret MyClass2) { - return _swig_wrap_new_MyClass2() -} - -var _wrap_delete_MyClass2 unsafe.Pointer - -func _swig_wrap_delete_MyClass2(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_MyClass2, _swig_p) - return -} - -func DeleteMyClass2(arg1 MyClass2) { - _swig_wrap_delete_MyClass2(arg1.Swigcptr()) -} - -type MyClass2 interface { - Swigcptr() uintptr - SwigIsMyClass2() - Set(_swig_args ...interface{}) - Set2(a ...interface{}) -} - -var _wrap_exceptionspec__SWIG_0 unsafe.Pointer - -func _swig_wrap_exceptionspec__SWIG_0(base int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_exceptionspec__SWIG_0, _swig_p) - return -} - -func Exceptionspec__SWIG_0(arg1 int) { - _swig_wrap_exceptionspec__SWIG_0(arg1) -} - -var _wrap_exceptionspec__SWIG_1 unsafe.Pointer - -func _swig_wrap_exceptionspec__SWIG_1() { - var _swig_p uintptr - _cgo_runtime_cgocall(_wrap_exceptionspec__SWIG_1, _swig_p) - return -} - -func Exceptionspec__SWIG_1() { - _swig_wrap_exceptionspec__SWIG_1() -} - -func Exceptionspec(a ...interface{}) { - argc := len(a) - if argc == 0 { - Exceptionspec__SWIG_1() - return - } - if argc == 1 { - Exceptionspec__SWIG_0(a[0].(int)) - return - } - panic("No match for overloaded function call") -} - -type SwigcptrExcept uintptr - -func (p SwigcptrExcept) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrExcept) SwigIsExcept() { -} - -var _wrap_new_Except__SWIG_0 unsafe.Pointer - -func _swig_wrap_new_Except__SWIG_0(base bool, _ int) (_ SwigcptrExcept) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Except__SWIG_0, _swig_p) - return -} - -func NewExcept__SWIG_0(arg1 bool, arg2 int) (_swig_ret Except) { - return _swig_wrap_new_Except__SWIG_0(arg1, arg2) -} - -var _wrap_new_Except__SWIG_1 unsafe.Pointer - -func _swig_wrap_new_Except__SWIG_1(base bool) (_ SwigcptrExcept) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Except__SWIG_1, _swig_p) - return -} - -func NewExcept__SWIG_1(arg1 bool) (_swig_ret Except) { - return _swig_wrap_new_Except__SWIG_1(arg1) -} - -func NewExcept(a ...interface{}) Except { - argc := len(a) - if argc == 1 { - return NewExcept__SWIG_1(a[0].(bool)) - } - if argc == 2 { - return NewExcept__SWIG_0(a[0].(bool), a[1].(int)) - } - panic("No match for overloaded function call") -} - -var _wrap_Except_exspec__SWIG_0 unsafe.Pointer - -func _swig_wrap_Except_exspec__SWIG_0(base SwigcptrExcept, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Except_exspec__SWIG_0, _swig_p) - return -} - -func (arg1 SwigcptrExcept) Exspec__SWIG_0(arg2 int) { - _swig_wrap_Except_exspec__SWIG_0(arg1, arg2) -} - -var _wrap_Except_exspec__SWIG_1 unsafe.Pointer - -func _swig_wrap_Except_exspec__SWIG_1(base SwigcptrExcept) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Except_exspec__SWIG_1, _swig_p) - return -} - -func (arg1 SwigcptrExcept) Exspec__SWIG_1() { - _swig_wrap_Except_exspec__SWIG_1(arg1) -} - -func (p SwigcptrExcept) Exspec(a ...interface{}) { - argc := len(a) - if argc == 0 { - p.Exspec__SWIG_1() - return - } - if argc == 1 { - p.Exspec__SWIG_0(a[0].(int)) - return - } - panic("No match for overloaded function call") -} - -var _wrap_delete_Except unsafe.Pointer - -func _swig_wrap_delete_Except(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Except, _swig_p) - return -} - -func DeleteExcept(arg1 Except) { - _swig_wrap_delete_Except(arg1.Swigcptr()) -} - -type Except interface { - Swigcptr() uintptr - SwigIsExcept() - Exspec(a ...interface{}) -} - -type SwigcptrStatics uintptr - -func (p SwigcptrStatics) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrStatics) SwigIsStatics() { -} - -var _wrap_Statics_staticmethod__SWIG_0 unsafe.Pointer - -func StaticsStaticmethod__SWIG_0(arg1 int, arg2 int, arg3 int) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_Statics_staticmethod__SWIG_0, _swig_p) - return -} -var _wrap_Statics_staticmethod__SWIG_1 unsafe.Pointer - -func StaticsStaticmethod__SWIG_1(arg1 int, arg2 int) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_Statics_staticmethod__SWIG_1, _swig_p) - return -} -var _wrap_Statics_staticmethod__SWIG_2 unsafe.Pointer - -func StaticsStaticmethod__SWIG_2(arg1 int) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_Statics_staticmethod__SWIG_2, _swig_p) - return -} -var _wrap_Statics_staticmethod__SWIG_3 unsafe.Pointer - -func StaticsStaticmethod__SWIG_3() (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_Statics_staticmethod__SWIG_3, _swig_p) - return -} -func StaticsStaticmethod(a ...interface{}) int { - argc := len(a) - if argc == 0 { - return StaticsStaticmethod__SWIG_3() - } - if argc == 1 { - return StaticsStaticmethod__SWIG_2(a[0].(int)) - } - if argc == 2 { - return StaticsStaticmethod__SWIG_1(a[0].(int), a[1].(int)) - } - if argc == 3 { - return StaticsStaticmethod__SWIG_0(a[0].(int), a[1].(int), a[2].(int)) - } - panic("No match for overloaded function call") -} - -var _wrap_new_Statics unsafe.Pointer - -func _swig_wrap_new_Statics() (base SwigcptrStatics) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Statics, _swig_p) - return -} - -func NewStatics() (_swig_ret Statics) { - return _swig_wrap_new_Statics() -} - -var _wrap_delete_Statics unsafe.Pointer - -func _swig_wrap_delete_Statics(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Statics, _swig_p) - return -} - -func DeleteStatics(arg1 Statics) { - _swig_wrap_delete_Statics(arg1.Swigcptr()) -} - -type Statics interface { - Swigcptr() uintptr - SwigIsStatics() -} - -type SwigcptrTricky uintptr - -func (p SwigcptrTricky) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrTricky) SwigIsTricky() { -} - -var _wrap_Tricky_privatedefault__SWIG_0 unsafe.Pointer - -func _swig_wrap_Tricky_privatedefault__SWIG_0(base SwigcptrTricky, _ int) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Tricky_privatedefault__SWIG_0, _swig_p) - return -} - -func (arg1 SwigcptrTricky) Privatedefault__SWIG_0(arg2 int) (_swig_ret int) { - return _swig_wrap_Tricky_privatedefault__SWIG_0(arg1, arg2) -} - -var _wrap_Tricky_privatedefault__SWIG_1 unsafe.Pointer - -func _swig_wrap_Tricky_privatedefault__SWIG_1(base SwigcptrTricky) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Tricky_privatedefault__SWIG_1, _swig_p) - return -} - -func (arg1 SwigcptrTricky) Privatedefault__SWIG_1() (_swig_ret int) { - return _swig_wrap_Tricky_privatedefault__SWIG_1(arg1) -} - -func (p SwigcptrTricky) Privatedefault(a ...interface{}) int { - argc := len(a) - if argc == 0 { - return p.Privatedefault__SWIG_1() - } - if argc == 1 { - return p.Privatedefault__SWIG_0(a[0].(int)) - } - panic("No match for overloaded function call") -} - -var _wrap_Tricky_protectedint__SWIG_0 unsafe.Pointer - -func _swig_wrap_Tricky_protectedint__SWIG_0(base SwigcptrTricky, _ int) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Tricky_protectedint__SWIG_0, _swig_p) - return -} - -func (arg1 SwigcptrTricky) Protectedint__SWIG_0(arg2 int) (_swig_ret int) { - return _swig_wrap_Tricky_protectedint__SWIG_0(arg1, arg2) -} - -var _wrap_Tricky_protectedint__SWIG_1 unsafe.Pointer - -func _swig_wrap_Tricky_protectedint__SWIG_1(base SwigcptrTricky) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Tricky_protectedint__SWIG_1, _swig_p) - return -} - -func (arg1 SwigcptrTricky) Protectedint__SWIG_1() (_swig_ret int) { - return _swig_wrap_Tricky_protectedint__SWIG_1(arg1) -} - -func (p SwigcptrTricky) Protectedint(a ...interface{}) int { - argc := len(a) - if argc == 0 { - return p.Protectedint__SWIG_1() - } - if argc == 1 { - return p.Protectedint__SWIG_0(a[0].(int)) - } - panic("No match for overloaded function call") -} - -var _wrap_Tricky_protecteddouble__SWIG_0 unsafe.Pointer - -func _swig_wrap_Tricky_protecteddouble__SWIG_0(base SwigcptrTricky, _ float64) (_ float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Tricky_protecteddouble__SWIG_0, _swig_p) - return -} - -func (arg1 SwigcptrTricky) Protecteddouble__SWIG_0(arg2 float64) (_swig_ret float64) { - return _swig_wrap_Tricky_protecteddouble__SWIG_0(arg1, arg2) -} - -var _wrap_Tricky_protecteddouble__SWIG_1 unsafe.Pointer - -func _swig_wrap_Tricky_protecteddouble__SWIG_1(base SwigcptrTricky) (_ float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Tricky_protecteddouble__SWIG_1, _swig_p) - return -} - -func (arg1 SwigcptrTricky) Protecteddouble__SWIG_1() (_swig_ret float64) { - return _swig_wrap_Tricky_protecteddouble__SWIG_1(arg1) -} - -func (p SwigcptrTricky) Protecteddouble(a ...interface{}) float64 { - argc := len(a) - if argc == 0 { - return p.Protecteddouble__SWIG_1() - } - if argc == 1 { - return p.Protecteddouble__SWIG_0(a[0].(float64)) - } - panic("No match for overloaded function call") -} - -var _wrap_Tricky_functiondefault__SWIG_0 unsafe.Pointer - -func _swig_wrap_Tricky_functiondefault__SWIG_0(base SwigcptrTricky, _ int) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Tricky_functiondefault__SWIG_0, _swig_p) - return -} - -func (arg1 SwigcptrTricky) Functiondefault__SWIG_0(arg2 int) (_swig_ret int) { - return _swig_wrap_Tricky_functiondefault__SWIG_0(arg1, arg2) -} - -var _wrap_Tricky_functiondefault__SWIG_1 unsafe.Pointer - -func _swig_wrap_Tricky_functiondefault__SWIG_1(base SwigcptrTricky) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Tricky_functiondefault__SWIG_1, _swig_p) - return -} - -func (arg1 SwigcptrTricky) Functiondefault__SWIG_1() (_swig_ret int) { - return _swig_wrap_Tricky_functiondefault__SWIG_1(arg1) -} - -func (p SwigcptrTricky) Functiondefault(a ...interface{}) int { - argc := len(a) - if argc == 0 { - return p.Functiondefault__SWIG_1() - } - if argc == 1 { - return p.Functiondefault__SWIG_0(a[0].(int)) - } - panic("No match for overloaded function call") -} - -var _wrap_Tricky_contrived__SWIG_0 unsafe.Pointer - -func _swig_wrap_Tricky_contrived__SWIG_0(base SwigcptrTricky, _ string) (_ byte) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Tricky_contrived__SWIG_0, _swig_p) - return -} - -func (arg1 SwigcptrTricky) Contrived__SWIG_0(arg2 string) (_swig_ret byte) { - return _swig_wrap_Tricky_contrived__SWIG_0(arg1, arg2) -} - -var _wrap_Tricky_contrived__SWIG_1 unsafe.Pointer - -func _swig_wrap_Tricky_contrived__SWIG_1(base SwigcptrTricky) (_ byte) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Tricky_contrived__SWIG_1, _swig_p) - return -} - -func (arg1 SwigcptrTricky) Contrived__SWIG_1() (_swig_ret byte) { - return _swig_wrap_Tricky_contrived__SWIG_1(arg1) -} - -func (p SwigcptrTricky) Contrived(a ...interface{}) byte { - argc := len(a) - if argc == 0 { - return p.Contrived__SWIG_1() - } - if argc == 1 { - return p.Contrived__SWIG_0(a[0].(string)) - } - panic("No match for overloaded function call") -} - -var _wrap_new_Tricky unsafe.Pointer - -func _swig_wrap_new_Tricky() (base SwigcptrTricky) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Tricky, _swig_p) - return -} - -func NewTricky() (_swig_ret Tricky) { - return _swig_wrap_new_Tricky() -} - -var _wrap_delete_Tricky unsafe.Pointer - -func _swig_wrap_delete_Tricky(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Tricky, _swig_p) - return -} - -func DeleteTricky(arg1 Tricky) { - _swig_wrap_delete_Tricky(arg1.Swigcptr()) -} - -type Tricky interface { - Swigcptr() uintptr - SwigIsTricky() - Privatedefault(a ...interface{}) int - Protectedint(a ...interface{}) int - Protecteddouble(a ...interface{}) float64 - Functiondefault(a ...interface{}) int - Contrived(a ...interface{}) byte -} - -type SwigcptrKlass uintptr - -func (p SwigcptrKlass) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrKlass) SwigIsKlass() { -} - -var _wrap_Klass_val_set unsafe.Pointer - -func _swig_wrap_Klass_val_set(base SwigcptrKlass, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Klass_val_set, _swig_p) - return -} - -func (arg1 SwigcptrKlass) SetVal(arg2 int) { - _swig_wrap_Klass_val_set(arg1, arg2) -} - -var _wrap_Klass_val_get unsafe.Pointer - -func _swig_wrap_Klass_val_get(base SwigcptrKlass) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Klass_val_get, _swig_p) - return -} - -func (arg1 SwigcptrKlass) GetVal() (_swig_ret int) { - return _swig_wrap_Klass_val_get(arg1) -} - -var _wrap_new_Klass__SWIG_0 unsafe.Pointer - -func _swig_wrap_new_Klass__SWIG_0(base int) (_ SwigcptrKlass) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Klass__SWIG_0, _swig_p) - return -} - -func NewKlass__SWIG_0(arg1 int) (_swig_ret Klass) { - return _swig_wrap_new_Klass__SWIG_0(arg1) -} - -var _wrap_new_Klass__SWIG_1 unsafe.Pointer - -func _swig_wrap_new_Klass__SWIG_1() (base SwigcptrKlass) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Klass__SWIG_1, _swig_p) - return -} - -func NewKlass__SWIG_1() (_swig_ret Klass) { - return _swig_wrap_new_Klass__SWIG_1() -} - -func NewKlass(a ...interface{}) Klass { - argc := len(a) - if argc == 0 { - return NewKlass__SWIG_1() - } - if argc == 1 { - return NewKlass__SWIG_0(a[0].(int)) - } - panic("No match for overloaded function call") -} - -var _wrap_delete_Klass unsafe.Pointer - -func _swig_wrap_delete_Klass(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Klass, _swig_p) - return -} - -func DeleteKlass(arg1 Klass) { - _swig_wrap_delete_Klass(arg1.Swigcptr()) -} - -type Klass interface { - Swigcptr() uintptr - SwigIsKlass() - SetVal(arg2 int) - GetVal() (_swig_ret int) -} - -var _wrap_constructorcall__SWIG_0 unsafe.Pointer - -func _swig_wrap_constructorcall__SWIG_0(base uintptr) (_ SwigcptrKlass) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_constructorcall__SWIG_0, _swig_p) - return -} - -func Constructorcall__SWIG_0(arg1 Klass) (_swig_ret Klass) { - return _swig_wrap_constructorcall__SWIG_0(arg1.Swigcptr()) -} - -var _wrap_constructorcall__SWIG_1 unsafe.Pointer - -func _swig_wrap_constructorcall__SWIG_1() (base SwigcptrKlass) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_constructorcall__SWIG_1, _swig_p) - return -} - -func Constructorcall__SWIG_1() (_swig_ret Klass) { - return _swig_wrap_constructorcall__SWIG_1() -} - -func Constructorcall(a ...interface{}) Klass { - argc := len(a) - if argc == 0 { - return Constructorcall__SWIG_1() - } - if argc == 1 { - return Constructorcall__SWIG_0(a[0].(Klass)) - } - panic("No match for overloaded function call") -} - -type SwigcptrConstMethods uintptr - -func (p SwigcptrConstMethods) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrConstMethods) SwigIsConstMethods() { -} - -var _wrap_ConstMethods_coo__SWIG_0 unsafe.Pointer - -func _swig_wrap_ConstMethods_coo__SWIG_0(base SwigcptrConstMethods, _ float64) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_ConstMethods_coo__SWIG_0, _swig_p) - return -} - -func (arg1 SwigcptrConstMethods) Coo__SWIG_0(arg2 float64) (_swig_ret int) { - return _swig_wrap_ConstMethods_coo__SWIG_0(arg1, arg2) -} - -var _wrap_ConstMethods_coo__SWIG_1 unsafe.Pointer - -func _swig_wrap_ConstMethods_coo__SWIG_1(base SwigcptrConstMethods) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_ConstMethods_coo__SWIG_1, _swig_p) - return -} - -func (arg1 SwigcptrConstMethods) Coo__SWIG_1() (_swig_ret int) { - return _swig_wrap_ConstMethods_coo__SWIG_1(arg1) -} - -func (p SwigcptrConstMethods) Coo(a ...interface{}) int { - argc := len(a) - if argc == 0 { - return p.Coo__SWIG_1() - } - if argc == 1 { - return p.Coo__SWIG_0(a[0].(float64)) - } - panic("No match for overloaded function call") -} - -var _wrap_new_ConstMethods unsafe.Pointer - -func _swig_wrap_new_ConstMethods() (base SwigcptrConstMethods) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_ConstMethods, _swig_p) - return -} - -func NewConstMethods() (_swig_ret ConstMethods) { - return _swig_wrap_new_ConstMethods() -} - -var _wrap_delete_ConstMethods unsafe.Pointer - -func _swig_wrap_delete_ConstMethods(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_ConstMethods, _swig_p) - return -} - -func DeleteConstMethods(arg1 ConstMethods) { - _swig_wrap_delete_ConstMethods(arg1.Swigcptr()) -} - -type ConstMethods interface { - Swigcptr() uintptr - SwigIsConstMethods() - Coo(a ...interface{}) int -} - -var _wrap_cfunc1 unsafe.Pointer - -func _swig_wrap_cfunc1(base int, _ float64, _ float64) (_ float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_cfunc1, _swig_p) - return -} - -func Cfunc1(arg1 float64, _swig_args ...interface{}) (_swig_ret float64) { - var arg2 float64 - if len(_swig_args) > 0 { - arg2 = _swig_args[0].(float64) - } - return _swig_wrap_cfunc1(len(_swig_args), arg1, arg2) -} - -var _wrap_cfunc2 unsafe.Pointer - -func _swig_wrap_cfunc2(base int, _ float64, _ float64) (_ float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_cfunc2, _swig_p) - return -} - -func Cfunc2(arg1 float64, _swig_args ...interface{}) (_swig_ret float64) { - var arg2 float64 - if len(_swig_args) > 0 { - arg2 = _swig_args[0].(float64) - } - return _swig_wrap_cfunc2(len(_swig_args), arg1, arg2) -} - -var _wrap_cfunc3 unsafe.Pointer - -func _swig_wrap_cfunc3(base int, _ float64, _ float64) (_ float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_cfunc3, _swig_p) - return -} - -func Cfunc3(arg1 float64, _swig_args ...interface{}) (_swig_ret float64) { - var arg2 float64 - if len(_swig_args) > 0 { - arg2 = _swig_args[0].(float64) - } - return _swig_wrap_cfunc3(len(_swig_args), arg1, arg2) -} - -type SwigcptrPointf uintptr - -func (p SwigcptrPointf) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrPointf) SwigIsPointf() { -} - -var _wrap_Pointf_x_set unsafe.Pointer - -func _swig_wrap_Pointf_x_set(base SwigcptrPointf, _ float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Pointf_x_set, _swig_p) - return -} - -func (arg1 SwigcptrPointf) SetX(arg2 float64) { - _swig_wrap_Pointf_x_set(arg1, arg2) -} - -var _wrap_Pointf_x_get unsafe.Pointer - -func _swig_wrap_Pointf_x_get(base SwigcptrPointf) (_ float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Pointf_x_get, _swig_p) - return -} - -func (arg1 SwigcptrPointf) GetX() (_swig_ret float64) { - return _swig_wrap_Pointf_x_get(arg1) -} - -var _wrap_Pointf_y_set unsafe.Pointer - -func _swig_wrap_Pointf_y_set(base SwigcptrPointf, _ float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Pointf_y_set, _swig_p) - return -} - -func (arg1 SwigcptrPointf) SetY(arg2 float64) { - _swig_wrap_Pointf_y_set(arg1, arg2) -} - -var _wrap_Pointf_y_get unsafe.Pointer - -func _swig_wrap_Pointf_y_get(base SwigcptrPointf) (_ float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Pointf_y_get, _swig_p) - return -} - -func (arg1 SwigcptrPointf) GetY() (_swig_ret float64) { - return _swig_wrap_Pointf_y_get(arg1) -} - -var _wrap_new_Pointf unsafe.Pointer - -func _swig_wrap_new_Pointf() (base SwigcptrPointf) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Pointf, _swig_p) - return -} - -func NewPointf() (_swig_ret Pointf) { - return _swig_wrap_new_Pointf() -} - -var _wrap_delete_Pointf unsafe.Pointer - -func _swig_wrap_delete_Pointf(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Pointf, _swig_p) - return -} - -func DeletePointf(arg1 Pointf) { - _swig_wrap_delete_Pointf(arg1.Swigcptr()) -} - -type Pointf interface { - Swigcptr() uintptr - SwigIsPointf() - SetX(arg2 float64) - GetX() (_swig_ret float64) - SetY(arg2 float64) - GetY() (_swig_ret float64) -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/default_args_runme b/Examples/test-suite/go/default_args_runme deleted file mode 100755 index 347e01e70..000000000 Binary files a/Examples/test-suite/go/default_args_runme and /dev/null differ diff --git a/Examples/test-suite/go/default_constructor.go b/Examples/test-suite/go/default_constructor.go deleted file mode 100644 index 8d4b6fe40..000000000 --- a/Examples/test-suite/go/default_constructor.go +++ /dev/null @@ -1,902 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../default_constructor.i - -package default_constructor - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrA uintptr - -func (p SwigcptrA) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrA) SwigIsA() { -} - -var _wrap_new_A unsafe.Pointer - -func _swig_wrap_new_A() (base SwigcptrA) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_A, _swig_p) - return -} - -func NewA() (_swig_ret A) { - return _swig_wrap_new_A() -} - -var _wrap_delete_A unsafe.Pointer - -func _swig_wrap_delete_A(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_A, _swig_p) - return -} - -func DeleteA(arg1 A) { - _swig_wrap_delete_A(arg1.Swigcptr()) -} - -type A interface { - Swigcptr() uintptr - SwigIsA() -} - -type SwigcptrAA uintptr - -func (p SwigcptrAA) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrAA) SwigIsAA() { -} - -var _wrap_new_AA unsafe.Pointer - -func _swig_wrap_new_AA() (base SwigcptrAA) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_AA, _swig_p) - return -} - -func NewAA() (_swig_ret AA) { - return _swig_wrap_new_AA() -} - -var _wrap_delete_AA unsafe.Pointer - -func _swig_wrap_delete_AA(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_AA, _swig_p) - return -} - -func DeleteAA(arg1 AA) { - _swig_wrap_delete_AA(arg1.Swigcptr()) -} - -func (p SwigcptrAA) SwigIsA() { -} - -func (p SwigcptrAA) SwigGetA() A { - return SwigcptrA(p.Swigcptr()) -} - -type AA interface { - Swigcptr() uintptr - SwigIsAA() - SwigIsA() - SwigGetA() A -} - -type SwigcptrB uintptr - -func (p SwigcptrB) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrB) SwigIsB() { -} - -var _wrap_new_B unsafe.Pointer - -func _swig_wrap_new_B(base int, _ int) (_ SwigcptrB) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_B, _swig_p) - return -} - -func NewB(arg1 int, arg2 int) (_swig_ret B) { - return _swig_wrap_new_B(arg1, arg2) -} - -var _wrap_delete_B unsafe.Pointer - -func _swig_wrap_delete_B(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_B, _swig_p) - return -} - -func DeleteB(arg1 B) { - _swig_wrap_delete_B(arg1.Swigcptr()) -} - -type B interface { - Swigcptr() uintptr - SwigIsB() -} - -type SwigcptrBB uintptr - -func (p SwigcptrBB) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrBB) SwigIsBB() { -} - -var _wrap_delete_BB unsafe.Pointer - -func _swig_wrap_delete_BB(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_BB, _swig_p) - return -} - -func DeleteBB(arg1 BB) { - _swig_wrap_delete_BB(arg1.Swigcptr()) -} - -func (p SwigcptrBB) SwigIsB() { -} - -func (p SwigcptrBB) SwigGetB() B { - return SwigcptrB(p.Swigcptr()) -} - -type BB interface { - Swigcptr() uintptr - SwigIsBB() - SwigIsB() - SwigGetB() B -} - -type SwigcptrC uintptr - -func (p SwigcptrC) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrC) SwigIsC() { -} - -var _wrap_delete_C unsafe.Pointer - -func _swig_wrap_delete_C(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_C, _swig_p) - return -} - -func DeleteC(arg1 C) { - _swig_wrap_delete_C(arg1.Swigcptr()) -} - -type C interface { - Swigcptr() uintptr - SwigIsC() -} - -type SwigcptrCC uintptr - -func (p SwigcptrCC) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrCC) SwigIsCC() { -} - -var _wrap_new_CC unsafe.Pointer - -func _swig_wrap_new_CC() (base SwigcptrCC) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_CC, _swig_p) - return -} - -func NewCC() (_swig_ret CC) { - return _swig_wrap_new_CC() -} - -var _wrap_delete_CC unsafe.Pointer - -func _swig_wrap_delete_CC(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_CC, _swig_p) - return -} - -func DeleteCC(arg1 CC) { - _swig_wrap_delete_CC(arg1.Swigcptr()) -} - -func (p SwigcptrCC) SwigIsC() { -} - -func (p SwigcptrCC) SwigGetC() C { - return SwigcptrC(p.Swigcptr()) -} - -type CC interface { - Swigcptr() uintptr - SwigIsCC() - SwigIsC() - SwigGetC() C -} - -type SwigcptrD uintptr - -func (p SwigcptrD) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrD) SwigIsD() { -} - -var _wrap_D_foo unsafe.Pointer - -func _swig_wrap_D_foo(base SwigcptrD) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_D_foo, _swig_p) - return -} - -func (arg1 SwigcptrD) Foo() { - _swig_wrap_D_foo(arg1) -} - -var _wrap_delete_D unsafe.Pointer - -func _swig_wrap_delete_D(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_D, _swig_p) - return -} - -func DeleteD(arg1 D) { - _swig_wrap_delete_D(arg1.Swigcptr()) -} - -type D interface { - Swigcptr() uintptr - SwigIsD() - Foo() -} - -type SwigcptrDD uintptr - -func (p SwigcptrDD) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrDD) SwigIsDD() { -} - -var _wrap_delete_DD unsafe.Pointer - -func _swig_wrap_delete_DD(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_DD, _swig_p) - return -} - -func DeleteDD(arg1 DD) { - _swig_wrap_delete_DD(arg1.Swigcptr()) -} - -var _wrap_DD_foo unsafe.Pointer - -func _swig_wrap_DD_foo(base SwigcptrDD) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_DD_foo, _swig_p) - return -} - -func (_swig_base SwigcptrDD) Foo() { - _swig_wrap_DD_foo(_swig_base) -} - -func (p SwigcptrDD) SwigIsD() { -} - -func (p SwigcptrDD) SwigGetD() D { - return SwigcptrD(p.Swigcptr()) -} - -type DD interface { - Swigcptr() uintptr - SwigIsDD() - Foo() - SwigIsD() - SwigGetD() D -} - -type SwigcptrAD uintptr - -func (p SwigcptrAD) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrAD) SwigIsAD() { -} - -var _wrap_delete_AD unsafe.Pointer - -func _swig_wrap_delete_AD(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_AD, _swig_p) - return -} - -func DeleteAD(arg1 AD) { - _swig_wrap_delete_AD(arg1.Swigcptr()) -} - -var _wrap_AD_foo unsafe.Pointer - -func _swig_wrap_AD_foo(base SwigcptrAD) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_AD_foo, _swig_p) - return -} - -func (_swig_base SwigcptrAD) Foo() { - _swig_wrap_AD_foo(_swig_base) -} - -func (p SwigcptrAD) SwigIsA() { -} - -func (p SwigcptrAD) SwigGetA() A { - return SwigcptrA(p.Swigcptr()) -} - -var _wrap_AD_SwigGetD unsafe.Pointer - -func _swig_wrap_AD_SwigGetD(base SwigcptrAD) (_ SwigcptrD) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_AD_SwigGetD, _swig_p) - return -} - -func (arg1 SwigcptrAD) SwigGetD() (_swig_ret D) { - return _swig_wrap_AD_SwigGetD(arg1) -} - -type AD interface { - Swigcptr() uintptr - SwigIsAD() - Foo() - SwigIsA() - SwigGetA() A - SwigGetD() (_swig_ret D) -} - -type SwigcptrE uintptr - -func (p SwigcptrE) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrE) SwigIsE() { -} - -var _wrap_new_E__SWIG_0 unsafe.Pointer - -func _swig_wrap_new_E__SWIG_0(base int, _ int) (_ SwigcptrE) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_E__SWIG_0, _swig_p) - return -} - -func NewE__SWIG_0(arg1 int, arg2 int) (_swig_ret E) { - return _swig_wrap_new_E__SWIG_0(arg1, arg2) -} - -var _wrap_new_E__SWIG_1 unsafe.Pointer - -func _swig_wrap_new_E__SWIG_1(base int) (_ SwigcptrE) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_E__SWIG_1, _swig_p) - return -} - -func NewE__SWIG_1(arg1 int) (_swig_ret E) { - return _swig_wrap_new_E__SWIG_1(arg1) -} - -var _wrap_new_E__SWIG_2 unsafe.Pointer - -func _swig_wrap_new_E__SWIG_2() (base SwigcptrE) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_E__SWIG_2, _swig_p) - return -} - -func NewE__SWIG_2() (_swig_ret E) { - return _swig_wrap_new_E__SWIG_2() -} - -func NewE(a ...interface{}) E { - argc := len(a) - if argc == 0 { - return NewE__SWIG_2() - } - if argc == 1 { - return NewE__SWIG_1(a[0].(int)) - } - if argc == 2 { - return NewE__SWIG_0(a[0].(int), a[1].(int)) - } - panic("No match for overloaded function call") -} - -var _wrap_delete_E unsafe.Pointer - -func _swig_wrap_delete_E(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_E, _swig_p) - return -} - -func DeleteE(arg1 E) { - _swig_wrap_delete_E(arg1.Swigcptr()) -} - -type E interface { - Swigcptr() uintptr - SwigIsE() -} - -type SwigcptrEE uintptr - -func (p SwigcptrEE) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrEE) SwigIsEE() { -} - -var _wrap_new_EE unsafe.Pointer - -func _swig_wrap_new_EE() (base SwigcptrEE) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_EE, _swig_p) - return -} - -func NewEE() (_swig_ret EE) { - return _swig_wrap_new_EE() -} - -var _wrap_delete_EE unsafe.Pointer - -func _swig_wrap_delete_EE(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_EE, _swig_p) - return -} - -func DeleteEE(arg1 EE) { - _swig_wrap_delete_EE(arg1.Swigcptr()) -} - -func (p SwigcptrEE) SwigIsE() { -} - -func (p SwigcptrEE) SwigGetE() E { - return SwigcptrE(p.Swigcptr()) -} - -type EE interface { - Swigcptr() uintptr - SwigIsEE() - SwigIsE() - SwigGetE() E -} - -type SwigcptrEB uintptr - -func (p SwigcptrEB) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrEB) SwigIsEB() { -} - -var _wrap_delete_EB unsafe.Pointer - -func _swig_wrap_delete_EB(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_EB, _swig_p) - return -} - -func DeleteEB(arg1 EB) { - _swig_wrap_delete_EB(arg1.Swigcptr()) -} - -func (p SwigcptrEB) SwigIsE() { -} - -func (p SwigcptrEB) SwigGetE() E { - return SwigcptrE(p.Swigcptr()) -} - -var _wrap_EB_SwigGetB unsafe.Pointer - -func _swig_wrap_EB_SwigGetB(base SwigcptrEB) (_ SwigcptrB) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_EB_SwigGetB, _swig_p) - return -} - -func (arg1 SwigcptrEB) SwigGetB() (_swig_ret B) { - return _swig_wrap_EB_SwigGetB(arg1) -} - -type EB interface { - Swigcptr() uintptr - SwigIsEB() - SwigIsE() - SwigGetE() E - SwigGetB() (_swig_ret B) -} - -type SwigcptrF uintptr - -func (p SwigcptrF) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrF) SwigIsF() { -} - -var _wrap_F_foo unsafe.Pointer - -func _swig_wrap_F_foo(base SwigcptrF, _ int, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_F_foo, _swig_p) - return -} - -func (arg1 SwigcptrF) Foo(arg2 int, arg3 int) { - _swig_wrap_F_foo(arg1, arg2, arg3) -} - -var _wrap_bar unsafe.Pointer - -func _swig_wrap_bar(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_bar, _swig_p) - return -} - -func Bar(arg1 F) { - _swig_wrap_bar(arg1.Swigcptr()) -} - -var _wrap_F_destroy unsafe.Pointer - -func _swig_wrap_F_destroy(base SwigcptrF) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_F_destroy, _swig_p) - return -} - -func (arg1 SwigcptrF) Destroy() { - _swig_wrap_F_destroy(arg1) -} - -var _wrap_new_F unsafe.Pointer - -func _swig_wrap_new_F() (base SwigcptrF) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_F, _swig_p) - return -} - -func NewF() (_swig_ret F) { - return _swig_wrap_new_F() -} - -type F interface { - Swigcptr() uintptr - SwigIsF() - Foo(arg2 int, arg3 int) - Destroy() -} - -type SwigcptrFFF uintptr - -func (p SwigcptrFFF) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrFFF) SwigIsFFF() { -} - -var _wrap_new_FFF unsafe.Pointer - -func _swig_wrap_new_FFF() (base SwigcptrFFF) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_FFF, _swig_p) - return -} - -func NewFFF() (_swig_ret FFF) { - return _swig_wrap_new_FFF() -} - -var _wrap_FFF_foo unsafe.Pointer - -func _swig_wrap_FFF_foo(base SwigcptrFFF, _ int, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_FFF_foo, _swig_p) - return -} - -func (_swig_base SwigcptrFFF) Foo(arg1 int, arg2 int) { - _swig_wrap_FFF_foo(_swig_base, arg1, arg2) -} - -var _wrap_FFF_destroy unsafe.Pointer - -func _swig_wrap_FFF_destroy(base SwigcptrFFF) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_FFF_destroy, _swig_p) - return -} - -func (_swig_base SwigcptrFFF) Destroy() { - _swig_wrap_FFF_destroy(_swig_base) -} - -func (p SwigcptrFFF) SwigIsF() { -} - -func (p SwigcptrFFF) SwigGetF() F { - return SwigcptrF(p.Swigcptr()) -} - -type FFF interface { - Swigcptr() uintptr - SwigIsFFF() - Foo(arg1 int, arg2 int) - Destroy() - SwigIsF() - SwigGetF() F -} - -type SwigcptrG uintptr - -func (p SwigcptrG) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrG) SwigIsG() { -} - -var _wrap_G_destroy unsafe.Pointer - -func _swig_wrap_G_destroy(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_G_destroy, _swig_p) - return -} - -func GDestroy(arg1 G) { - _swig_wrap_G_destroy(arg1.Swigcptr()) -} - -var _wrap_new_G unsafe.Pointer - -func _swig_wrap_new_G() (base SwigcptrG) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_G, _swig_p) - return -} - -func NewG() (_swig_ret G) { - return _swig_wrap_new_G() -} - -type G interface { - Swigcptr() uintptr - SwigIsG() -} - -type SwigcptrGG uintptr - -func (p SwigcptrGG) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrGG) SwigIsGG() { -} - -var _wrap_new_GG unsafe.Pointer - -func _swig_wrap_new_GG() (base SwigcptrGG) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_GG, _swig_p) - return -} - -func NewGG() (_swig_ret GG) { - return _swig_wrap_new_GG() -} - -var _wrap_delete_GG unsafe.Pointer - -func _swig_wrap_delete_GG(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_GG, _swig_p) - return -} - -func DeleteGG(arg1 GG) { - _swig_wrap_delete_GG(arg1.Swigcptr()) -} - -var _wrap_GG_destroy unsafe.Pointer - -func _swig_wrap_GG_destroy(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_GG_destroy, _swig_p) - return -} - -func GGDestroy(arg1 G) { - _swig_wrap_GG_destroy(arg1.Swigcptr()) -} - -func (p SwigcptrGG) SwigIsG() { -} - -func (p SwigcptrGG) SwigGetG() G { - return SwigcptrG(p.Swigcptr()) -} - -type GG interface { - Swigcptr() uintptr - SwigIsGG() - SwigIsG() - SwigGetG() G -} - -type SwigcptrHH uintptr - -func (p SwigcptrHH) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrHH) SwigIsHH() { -} - -var _wrap_new_HH unsafe.Pointer - -func _swig_wrap_new_HH(base int, _ int) (_ SwigcptrHH) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_HH, _swig_p) - return -} - -func NewHH(arg1 int, arg2 int) (_swig_ret HH) { - return _swig_wrap_new_HH(arg1, arg2) -} - -var _wrap_delete_HH unsafe.Pointer - -func _swig_wrap_delete_HH(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_HH, _swig_p) - return -} - -func DeleteHH(arg1 HH) { - _swig_wrap_delete_HH(arg1.Swigcptr()) -} - -type HH interface { - Swigcptr() uintptr - SwigIsHH() -} - -type SwigcptrVoid uintptr - -func (p SwigcptrVoid) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrVoid) SwigIsOSRSpatialReferenceShadow() { -} - -var _wrap_new_OSRSpatialReferenceShadow__SWIG_0 unsafe.Pointer - -func _swig_wrap_new_OSRSpatialReferenceShadow__SWIG_0(base string) (_ SwigcptrVoid) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_OSRSpatialReferenceShadow__SWIG_0, _swig_p) - return -} - -func NewOSRSpatialReferenceShadow__SWIG_0(arg1 string) (_swig_ret OSRSpatialReferenceShadow) { - return _swig_wrap_new_OSRSpatialReferenceShadow__SWIG_0(arg1) -} - -var _wrap_new_OSRSpatialReferenceShadow__SWIG_1 unsafe.Pointer - -func _swig_wrap_new_OSRSpatialReferenceShadow__SWIG_1() (base SwigcptrVoid) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_OSRSpatialReferenceShadow__SWIG_1, _swig_p) - return -} - -func NewOSRSpatialReferenceShadow__SWIG_1() (_swig_ret OSRSpatialReferenceShadow) { - return _swig_wrap_new_OSRSpatialReferenceShadow__SWIG_1() -} - -func NewOSRSpatialReferenceShadow(a ...interface{}) { - argc := len(a) - if argc == 0 { - NewOSRSpatialReferenceShadow__SWIG_1() - return - } - if argc == 1 { - NewOSRSpatialReferenceShadow__SWIG_0(a[0].(string)) - return - } - panic("No match for overloaded function call") -} - -var _wrap_delete_OSRSpatialReferenceShadow unsafe.Pointer - -func _swig_wrap_delete_OSRSpatialReferenceShadow(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_OSRSpatialReferenceShadow, _swig_p) - return -} - -func DeleteOSRSpatialReferenceShadow(arg1 OSRSpatialReferenceShadow) { - _swig_wrap_delete_OSRSpatialReferenceShadow(arg1.Swigcptr()) -} - -type OSRSpatialReferenceShadow interface { - Swigcptr() uintptr - SwigIsOSRSpatialReferenceShadow() -} - - diff --git a/Examples/test-suite/go/default_constructor_runme b/Examples/test-suite/go/default_constructor_runme deleted file mode 100755 index 46e4adfc2..000000000 Binary files a/Examples/test-suite/go/default_constructor_runme and /dev/null differ diff --git a/Examples/test-suite/go/defvalue_constructor.go b/Examples/test-suite/go/defvalue_constructor.go deleted file mode 100644 index 04758e210..000000000 --- a/Examples/test-suite/go/defvalue_constructor.go +++ /dev/null @@ -1,136 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../defvalue_constructor.i - -package defvalue_constructor - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrBar uintptr - -func (p SwigcptrBar) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrBar) SwigIsBar() { -} - -var _wrap_new_Bar unsafe.Pointer - -func _swig_wrap_new_Bar() (base SwigcptrBar) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Bar, _swig_p) - return -} - -func NewBar() (_swig_ret Bar) { - return _swig_wrap_new_Bar() -} - -var _wrap_delete_Bar unsafe.Pointer - -func _swig_wrap_delete_Bar(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Bar, _swig_p) - return -} - -func DeleteBar(arg1 Bar) { - _swig_wrap_delete_Bar(arg1.Swigcptr()) -} - -type Bar interface { - Swigcptr() uintptr - SwigIsBar() -} - -type SwigcptrBaz uintptr - -func (p SwigcptrBaz) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrBaz) SwigIsBaz() { -} - -var _wrap_new_Baz__SWIG_0 unsafe.Pointer - -func _swig_wrap_new_Baz__SWIG_0(base uintptr) (_ SwigcptrBaz) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Baz__SWIG_0, _swig_p) - return -} - -func NewBaz__SWIG_0(arg1 Bar) (_swig_ret Baz) { - return _swig_wrap_new_Baz__SWIG_0(arg1.Swigcptr()) -} - -var _wrap_new_Baz__SWIG_1 unsafe.Pointer - -func _swig_wrap_new_Baz__SWIG_1() (base SwigcptrBaz) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Baz__SWIG_1, _swig_p) - return -} - -func NewBaz__SWIG_1() (_swig_ret Baz) { - return _swig_wrap_new_Baz__SWIG_1() -} - -func NewBaz(a ...interface{}) Baz { - argc := len(a) - if argc == 0 { - return NewBaz__SWIG_1() - } - if argc == 1 { - return NewBaz__SWIG_0(a[0].(Bar)) - } - panic("No match for overloaded function call") -} - -var _wrap_delete_Baz unsafe.Pointer - -func _swig_wrap_delete_Baz(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Baz, _swig_p) - return -} - -func DeleteBaz(arg1 Baz) { - _swig_wrap_delete_Baz(arg1.Swigcptr()) -} - -type Baz interface { - Swigcptr() uintptr - SwigIsBaz() -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/derived_byvalue.go b/Examples/test-suite/go/derived_byvalue.go deleted file mode 100644 index 483215912..000000000 --- a/Examples/test-suite/go/derived_byvalue.go +++ /dev/null @@ -1,316 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../derived_byvalue.i - -package derived_byvalue - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrFoo uintptr - -func (p SwigcptrFoo) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrFoo) SwigIsFoo() { -} - -var _wrap_Foo_x_set unsafe.Pointer - -func _swig_wrap_Foo_x_set(base SwigcptrFoo, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_x_set, _swig_p) - return -} - -func (arg1 SwigcptrFoo) SetX(arg2 int) { - _swig_wrap_Foo_x_set(arg1, arg2) -} - -var _wrap_Foo_x_get unsafe.Pointer - -func _swig_wrap_Foo_x_get(base SwigcptrFoo) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_x_get, _swig_p) - return -} - -func (arg1 SwigcptrFoo) GetX() (_swig_ret int) { - return _swig_wrap_Foo_x_get(arg1) -} - -var _wrap_Foo_rmethod unsafe.Pointer - -func _swig_wrap_Foo_rmethod(base SwigcptrFoo, _ uintptr) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_rmethod, _swig_p) - return -} - -func (arg1 SwigcptrFoo) Rmethod(arg2 Foo) (_swig_ret int) { - return _swig_wrap_Foo_rmethod(arg1, arg2.Swigcptr()) -} - -var _wrap_Foo_method unsafe.Pointer - -func _swig_wrap_Foo_method(base SwigcptrFoo, _ uintptr) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_method, _swig_p) - return -} - -func (arg1 SwigcptrFoo) Method(arg2 Foo) (_swig_ret int) { - return _swig_wrap_Foo_method(arg1, arg2.Swigcptr()) -} - -var _wrap_new_Foo unsafe.Pointer - -func _swig_wrap_new_Foo() (base SwigcptrFoo) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Foo, _swig_p) - return -} - -func NewFoo() (_swig_ret Foo) { - return _swig_wrap_new_Foo() -} - -var _wrap_delete_Foo unsafe.Pointer - -func _swig_wrap_delete_Foo(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Foo, _swig_p) - return -} - -func DeleteFoo(arg1 Foo) { - _swig_wrap_delete_Foo(arg1.Swigcptr()) -} - -type Foo interface { - Swigcptr() uintptr - SwigIsFoo() - SetX(arg2 int) - GetX() (_swig_ret int) - Rmethod(arg2 Foo) (_swig_ret int) - Method(arg2 Foo) (_swig_ret int) -} - -type SwigcptrBar uintptr - -func (p SwigcptrBar) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrBar) SwigIsBar() { -} - -var _wrap_Bar_a_set unsafe.Pointer - -func _swig_wrap_Bar_a_set(base SwigcptrBar, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Bar_a_set, _swig_p) - return -} - -func (arg1 SwigcptrBar) SetA(arg2 Foo) { - _swig_wrap_Bar_a_set(arg1, arg2.Swigcptr()) -} - -var _wrap_Bar_a_get unsafe.Pointer - -func _swig_wrap_Bar_a_get(base SwigcptrBar) (_ SwigcptrFoo) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Bar_a_get, _swig_p) - return -} - -func (arg1 SwigcptrBar) GetA() (_swig_ret Foo) { - return _swig_wrap_Bar_a_get(arg1) -} - -var _wrap_Bar_b_set unsafe.Pointer - -func _swig_wrap_Bar_b_set(base SwigcptrBar, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Bar_b_set, _swig_p) - return -} - -func (arg1 SwigcptrBar) SetB(arg2 Foo) { - _swig_wrap_Bar_b_set(arg1, arg2.Swigcptr()) -} - -var _wrap_Bar_b_get unsafe.Pointer - -func _swig_wrap_Bar_b_get(base SwigcptrBar) (_ SwigcptrFoo) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Bar_b_get, _swig_p) - return -} - -func (arg1 SwigcptrBar) GetB() (_swig_ret Foo) { - return _swig_wrap_Bar_b_get(arg1) -} - -var _wrap_new_Bar unsafe.Pointer - -func _swig_wrap_new_Bar() (base SwigcptrBar) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Bar, _swig_p) - return -} - -func NewBar() (_swig_ret Bar) { - return _swig_wrap_new_Bar() -} - -var _wrap_delete_Bar unsafe.Pointer - -func _swig_wrap_delete_Bar(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Bar, _swig_p) - return -} - -func DeleteBar(arg1 Bar) { - _swig_wrap_delete_Bar(arg1.Swigcptr()) -} - -type Bar interface { - Swigcptr() uintptr - SwigIsBar() - SetA(arg2 Foo) - GetA() (_swig_ret Foo) - SetB(arg2 Foo) - GetB() (_swig_ret Foo) -} - -type SwigcptrDerFoo uintptr - -func (p SwigcptrDerFoo) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrDerFoo) SwigIsDerFoo() { -} - -var _wrap_new_DerFoo unsafe.Pointer - -func _swig_wrap_new_DerFoo() (base SwigcptrDerFoo) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_DerFoo, _swig_p) - return -} - -func NewDerFoo() (_swig_ret DerFoo) { - return _swig_wrap_new_DerFoo() -} - -var _wrap_delete_DerFoo unsafe.Pointer - -func _swig_wrap_delete_DerFoo(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_DerFoo, _swig_p) - return -} - -func DeleteDerFoo(arg1 DerFoo) { - _swig_wrap_delete_DerFoo(arg1.Swigcptr()) -} - -var _wrap_SetDerFoo_X unsafe.Pointer - -func _swig_wrap_SetDerFoo_X(base SwigcptrDerFoo, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_SetDerFoo_X, _swig_p) - return -} - -func (_swig_base SwigcptrDerFoo) SetX(arg1 int) { - _swig_wrap_SetDerFoo_X(_swig_base, arg1) -} - -var _wrap_GetDerFoo_X unsafe.Pointer - -func _swig_wrap_GetDerFoo_X(base SwigcptrDerFoo) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_GetDerFoo_X, _swig_p) - return -} - -func (_swig_base SwigcptrDerFoo) GetX() (_swig_ret int) { - return _swig_wrap_GetDerFoo_X(_swig_base) -} - -var _wrap_DerFoo_rmethod unsafe.Pointer - -func _swig_wrap_DerFoo_rmethod(base SwigcptrDerFoo, _ uintptr) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_DerFoo_rmethod, _swig_p) - return -} - -func (_swig_base SwigcptrDerFoo) Rmethod(arg1 Foo) (_swig_ret int) { - return _swig_wrap_DerFoo_rmethod(_swig_base, arg1.Swigcptr()) -} - -var _wrap_DerFoo_method unsafe.Pointer - -func _swig_wrap_DerFoo_method(base SwigcptrDerFoo, _ uintptr) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_DerFoo_method, _swig_p) - return -} - -func (_swig_base SwigcptrDerFoo) Method(arg1 Foo) (_swig_ret int) { - return _swig_wrap_DerFoo_method(_swig_base, arg1.Swigcptr()) -} - -func (p SwigcptrDerFoo) SwigIsFoo() { -} - -func (p SwigcptrDerFoo) SwigGetFoo() Foo { - return SwigcptrFoo(p.Swigcptr()) -} - -type DerFoo interface { - Swigcptr() uintptr - SwigIsDerFoo() - SetX(arg1 int) - GetX() (_swig_ret int) - Rmethod(arg1 Foo) (_swig_ret int) - Method(arg1 Foo) (_swig_ret int) - SwigIsFoo() - SwigGetFoo() Foo -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/derived_nested.go b/Examples/test-suite/go/derived_nested.go deleted file mode 100644 index f31f58160..000000000 --- a/Examples/test-suite/go/derived_nested.go +++ /dev/null @@ -1,232 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../derived_nested.i - -package derived_nested - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrA uintptr - -func (p SwigcptrA) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrA) SwigIsA() { -} - -var _wrap_A_x_set unsafe.Pointer - -func _swig_wrap_A_x_set(base SwigcptrA, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_A_x_set, _swig_p) - return -} - -func (arg1 SwigcptrA) SetX(arg2 int) { - _swig_wrap_A_x_set(arg1, arg2) -} - -var _wrap_A_x_get unsafe.Pointer - -func _swig_wrap_A_x_get(base SwigcptrA) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_A_x_get, _swig_p) - return -} - -func (arg1 SwigcptrA) GetX() (_swig_ret int) { - return _swig_wrap_A_x_get(arg1) -} - -var _wrap_new_A unsafe.Pointer - -func _swig_wrap_new_A() (base SwigcptrA) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_A, _swig_p) - return -} - -func NewA() (_swig_ret A) { - return _swig_wrap_new_A() -} - -var _wrap_delete_A unsafe.Pointer - -func _swig_wrap_delete_A(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_A, _swig_p) - return -} - -func DeleteA(arg1 A) { - _swig_wrap_delete_A(arg1.Swigcptr()) -} - -type A interface { - Swigcptr() uintptr - SwigIsA() - SetX(arg2 int) - GetX() (_swig_ret int) -} - -type SwigcptrB uintptr - -func (p SwigcptrB) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrB) SwigIsB() { -} - -var _wrap_new_B unsafe.Pointer - -func _swig_wrap_new_B() (base SwigcptrB) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_B, _swig_p) - return -} - -func NewB() (_swig_ret B) { - return _swig_wrap_new_B() -} - -var _wrap_delete_B unsafe.Pointer - -func _swig_wrap_delete_B(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_B, _swig_p) - return -} - -func DeleteB(arg1 B) { - _swig_wrap_delete_B(arg1.Swigcptr()) -} - -type B interface { - Swigcptr() uintptr - SwigIsB() -} - -type SwigcptrBB uintptr - -func (p SwigcptrBB) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrBB) SwigIsBB() { -} - -var _wrap_BB_ff_instance_set unsafe.Pointer - -func _swig_wrap_BB_ff_instance_set(base SwigcptrBB, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_BB_ff_instance_set, _swig_p) - return -} - -func (arg1 SwigcptrBB) SetFf_instance(arg2 BB_FF) { - _swig_wrap_BB_ff_instance_set(arg1, arg2.Swigcptr()) -} - -var _wrap_BB_ff_instance_get unsafe.Pointer - -func _swig_wrap_BB_ff_instance_get(base SwigcptrBB) (_ SwigcptrBB_FF) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_BB_ff_instance_get, _swig_p) - return -} - -func (arg1 SwigcptrBB) GetFf_instance() (_swig_ret BB_FF) { - return _swig_wrap_BB_ff_instance_get(arg1) -} - -var _wrap_BB_useEE unsafe.Pointer - -func _swig_wrap_BB_useEE(base SwigcptrBB, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_BB_useEE, _swig_p) - return -} - -func (arg1 SwigcptrBB) UseEE(arg2 BB_EE) { - _swig_wrap_BB_useEE(arg1, arg2.Swigcptr()) -} - -var _wrap_new_BB unsafe.Pointer - -func _swig_wrap_new_BB() (base SwigcptrBB) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_BB, _swig_p) - return -} - -func NewBB() (_swig_ret BB) { - return _swig_wrap_new_BB() -} - -var _wrap_delete_BB unsafe.Pointer - -func _swig_wrap_delete_BB(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_BB, _swig_p) - return -} - -func DeleteBB(arg1 BB) { - _swig_wrap_delete_BB(arg1.Swigcptr()) -} - -type BB interface { - Swigcptr() uintptr - SwigIsBB() - SetFf_instance(arg2 BB_FF) - GetFf_instance() (_swig_ret BB_FF) - UseEE(arg2 BB_EE) -} - - -type SwigcptrBB_FF uintptr -type BB_FF interface { - Swigcptr() uintptr; -} -func (p SwigcptrBB_FF) Swigcptr() uintptr { - return uintptr(p) -} - -type SwigcptrBB_EE uintptr -type BB_EE interface { - Swigcptr() uintptr; -} -func (p SwigcptrBB_EE) Swigcptr() uintptr { - return uintptr(p) -} - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/destructor_reprotected.go b/Examples/test-suite/go/destructor_reprotected.go deleted file mode 100644 index 9c2a54c2e..000000000 --- a/Examples/test-suite/go/destructor_reprotected.go +++ /dev/null @@ -1,154 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../destructor_reprotected.i - -package destructor_reprotected - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrA uintptr - -func (p SwigcptrA) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrA) SwigIsA() { -} - -var _wrap_new_A unsafe.Pointer - -func _swig_wrap_new_A() (base SwigcptrA) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_A, _swig_p) - return -} - -func NewA() (_swig_ret A) { - return _swig_wrap_new_A() -} - -var _wrap_delete_A unsafe.Pointer - -func _swig_wrap_delete_A(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_A, _swig_p) - return -} - -func DeleteA(arg1 A) { - _swig_wrap_delete_A(arg1.Swigcptr()) -} - -type A interface { - Swigcptr() uintptr - SwigIsA() -} - -type SwigcptrB uintptr - -func (p SwigcptrB) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrB) SwigIsB() { -} - -func (p SwigcptrB) SwigIsA() { -} - -func (p SwigcptrB) SwigGetA() A { - return SwigcptrA(p.Swigcptr()) -} - -type B interface { - Swigcptr() uintptr - SwigIsB() - SwigIsA() - SwigGetA() A -} - -type SwigcptrC uintptr - -func (p SwigcptrC) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrC) SwigIsC() { -} - -var _wrap_new_C unsafe.Pointer - -func _swig_wrap_new_C() (base SwigcptrC) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_C, _swig_p) - return -} - -func NewC() (_swig_ret C) { - return _swig_wrap_new_C() -} - -var _wrap_delete_C unsafe.Pointer - -func _swig_wrap_delete_C(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_C, _swig_p) - return -} - -func DeleteC(arg1 C) { - _swig_wrap_delete_C(arg1.Swigcptr()) -} - -func (p SwigcptrC) SwigIsB() { -} - -func (p SwigcptrC) SwigGetB() B { - return SwigcptrB(p.Swigcptr()) -} - -func (p SwigcptrC) SwigIsA() { -} - -func (p SwigcptrC) SwigGetA() A { - return SwigcptrA(p.Swigcptr()) -} - -type C interface { - Swigcptr() uintptr - SwigIsC() - SwigIsB() - SwigGetB() B - SwigIsA() - SwigGetA() A -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/director_abstract.go b/Examples/test-suite/go/director_abstract.go deleted file mode 100644 index 616ca3f58..000000000 --- a/Examples/test-suite/go/director_abstract.go +++ /dev/null @@ -1,1331 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../director_abstract.i - -package director_abstract - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type _swig_DirectorFoo struct { - SwigcptrFoo - v interface{} -} - -func (p *_swig_DirectorFoo) Swigcptr() uintptr { - return p.SwigcptrFoo.Swigcptr() -} - -func (p *_swig_DirectorFoo) SwigIsFoo() { -} - -func (p *_swig_DirectorFoo) DirectorInterface() interface{} { - return p.v -} - -var _wrap__swig_NewDirectorFooFoo unsafe.Pointer - -func _swig_NewDirectorFooFoo(_swig_director *_swig_DirectorFoo) (_swig_ret SwigcptrFoo) { - _swig_p := uintptr(unsafe.Pointer(&_swig_director)) - _cgo_runtime_cgocall(_wrap__swig_NewDirectorFooFoo, _swig_p) - return -} - -func NewDirectorFoo(v interface{}) Foo { - p := &_swig_DirectorFoo{0, v} - p.SwigcptrFoo = _swig_NewDirectorFooFoo(p) - return p -} - -var _wrap_DeleteDirectorFoo unsafe.Pointer - -func _swig_wrap_DeleteDirectorFoo(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_DeleteDirectorFoo, _swig_p) - return -} - -func DeleteDirectorFoo(arg1 Foo) { - _swig_wrap_DeleteDirectorFoo(arg1.Swigcptr()) -} - -func Swiggo_DeleteDirector_Foo(p *_swig_DirectorFoo) { - p.SwigcptrFoo = 0 -} - -type _swig_DirectorInterfaceFooPing interface { - Ping() string -} - -func (swig_p *_swig_DirectorFoo) Ping() string { - if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceFooPing); swig_ok { - return swig_g.Ping() - } - panic("call to pure virtual method") -} - -func Swig_DirectorFoo_callback_ping(p *_swig_DirectorFoo) (swig_result string) { - var swig_r string - swig_r = p.Ping() - return swig_r -} - -type _swig_DirectorInterfaceFooPong interface { - Pong() string -} - -var _wrap__swig_DirectorFoo_upcall_Pong unsafe.Pointer - -func _swig_wrap__swig_DirectorFoo_upcall_Pong(_swig_ptr SwigcptrFoo) (_swig_ret string) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) - _cgo_runtime_cgocall(_wrap__swig_DirectorFoo_upcall_Pong, _swig_p) - return -} - -func (swig_p *_swig_DirectorFoo) Pong() string { - if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceFooPong); swig_ok { - return swig_g.Pong() - } - var swig_r string - swig_r = _swig_wrap__swig_DirectorFoo_upcall_Pong(swig_p.SwigcptrFoo) - return swig_r -} - -func DirectorFooPong(p Foo) string { - var swig_r string - swig_r = _swig_wrap__swig_DirectorFoo_upcall_Pong(p.(*_swig_DirectorFoo).SwigcptrFoo) - return swig_r -} - -func Swig_DirectorFoo_callback_pong(p *_swig_DirectorFoo) (swig_result string) { - var swig_r string - swig_r = p.Pong() - return swig_r -} - -type SwigcptrFoo uintptr - -func (p SwigcptrFoo) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrFoo) SwigIsFoo() { -} - -func (p SwigcptrFoo) DirectorInterface() interface{} { - return nil -} - -var _wrap_delete_Foo unsafe.Pointer - -func _swig_wrap_delete_Foo(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Foo, _swig_p) - return -} - -func DeleteFoo(arg1 Foo) { - _swig_wrap_delete_Foo(arg1.Swigcptr()) -} - -var _wrap_Foo_ping unsafe.Pointer - -func _swig_wrap_Foo_ping(base SwigcptrFoo) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_ping, _swig_p) - return -} - -func (arg1 SwigcptrFoo) Ping() (_swig_ret string) { - return _swig_wrap_Foo_ping(arg1) -} - -var _wrap_Foo_pong unsafe.Pointer - -func _swig_wrap_Foo_pong(base SwigcptrFoo) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_pong, _swig_p) - return -} - -func (arg1 SwigcptrFoo) Pong() (_swig_ret string) { - return _swig_wrap_Foo_pong(arg1) -} - -var _wrap_new_Foo unsafe.Pointer - -func _swig_wrap_new_Foo() (base SwigcptrFoo) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Foo, _swig_p) - return -} - -func NewFoo() (_swig_ret Foo) { - return _swig_wrap_new_Foo() -} - -type Foo interface { - Swigcptr() uintptr - SwigIsFoo() - DirectorInterface() interface{} - Ping() (_swig_ret string) - Pong() (_swig_ret string) -} - -type _swig_DirectorExample0 struct { - SwigcptrExample0 - v interface{} -} - -func (p *_swig_DirectorExample0) Swigcptr() uintptr { - return p.SwigcptrExample0.Swigcptr() -} - -func (p *_swig_DirectorExample0) SwigIsExample0() { -} - -func (p *_swig_DirectorExample0) DirectorInterface() interface{} { - return p.v -} - -var _wrap__swig_NewDirectorExample0Example0__SWIG_0 unsafe.Pointer - -func _swig_NewDirectorExample0Example0__SWIG_0(_swig_director *_swig_DirectorExample0, _ int, _ int) (_swig_ret SwigcptrExample0) { - _swig_p := uintptr(unsafe.Pointer(&_swig_director)) - _cgo_runtime_cgocall(_wrap__swig_NewDirectorExample0Example0__SWIG_0, _swig_p) - return -} - -func NewDirectorExample0__SWIG_0(v interface{}, arg1 int, arg2 int) Example0 { - p := &_swig_DirectorExample0{0, v} - p.SwigcptrExample0 = _swig_NewDirectorExample0Example0__SWIG_0(p, arg1, arg2) - return p -} - -var _wrap__swig_NewDirectorExample0Example0__SWIG_1 unsafe.Pointer - -func _swig_NewDirectorExample0Example0__SWIG_1(_swig_director *_swig_DirectorExample0) (_swig_ret SwigcptrExample0) { - _swig_p := uintptr(unsafe.Pointer(&_swig_director)) - _cgo_runtime_cgocall(_wrap__swig_NewDirectorExample0Example0__SWIG_1, _swig_p) - return -} - -func NewDirectorExample0__SWIG_1(v interface{}) Example0 { - p := &_swig_DirectorExample0{0, v} - p.SwigcptrExample0 = _swig_NewDirectorExample0Example0__SWIG_1(p) - return p -} - -func NewDirectorExample0(abi interface{}, a ...interface{}) Example0 { - argc := len(a) - if argc == 0 { - return NewDirectorExample0__SWIG_1(abi) - } - if argc == 2 { - return NewDirectorExample0__SWIG_0(abi, a[0].(int), a[1].(int)) - } - panic("No match for overloaded function call") -} - -var _wrap_DeleteDirectorExample0 unsafe.Pointer - -func _swig_wrap_DeleteDirectorExample0(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_DeleteDirectorExample0, _swig_p) - return -} - -func DeleteDirectorExample0(arg1 Example0) { - _swig_wrap_DeleteDirectorExample0(arg1.Swigcptr()) -} - -func Swiggo_DeleteDirector_Example0(p *_swig_DirectorExample0) { - p.SwigcptrExample0 = 0 -} - -type _swig_DirectorInterfaceExample0Color interface { - Color(byte, byte, byte) int -} - -var _wrap__swig_DirectorExample0_upcall_Color unsafe.Pointer - -func _swig_wrap__swig_DirectorExample0_upcall_Color(_swig_ptr SwigcptrExample0, _ byte, _ byte, _ byte) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) - _cgo_runtime_cgocall(_wrap__swig_DirectorExample0_upcall_Color, _swig_p) - return -} - -func (swig_p *_swig_DirectorExample0) Color(r byte, g byte, b byte) int { - if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceExample0Color); swig_ok { - return swig_g.Color(r, g, b) - } - var swig_r int - swig_r = _swig_wrap__swig_DirectorExample0_upcall_Color(swig_p.SwigcptrExample0, r, g, b) - return swig_r -} - -func DirectorExample0Color(p Example0, arg2 byte, arg3 byte, arg4 byte) int { - var swig_r int - swig_r = _swig_wrap__swig_DirectorExample0_upcall_Color(p.(*_swig_DirectorExample0).SwigcptrExample0, arg2, arg3, arg4) - return swig_r -} - -func Swig_DirectorExample0_callback_Color(p *_swig_DirectorExample0, arg2 byte, arg3 byte, arg4 byte) (swig_result int) { - var swig_r int - swig_r = p.Color(arg2, arg3, arg4) - return swig_r -} - -type SwigcptrExample0 uintptr - -func (p SwigcptrExample0) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrExample0) SwigIsExample0() { -} - -func (p SwigcptrExample0) DirectorInterface() interface{} { - return nil -} - -var _wrap_new_Example0__SWIG_0 unsafe.Pointer - -func _swig_wrap_new_Example0__SWIG_0(base int, _ int) (_ SwigcptrExample0) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Example0__SWIG_0, _swig_p) - return -} - -func NewExample0__SWIG_0(arg1 int, arg2 int) (_swig_ret Example0) { - return _swig_wrap_new_Example0__SWIG_0(arg1, arg2) -} - -var _wrap_new_Example0__SWIG_1 unsafe.Pointer - -func _swig_wrap_new_Example0__SWIG_1() (base SwigcptrExample0) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Example0__SWIG_1, _swig_p) - return -} - -func NewExample0__SWIG_1() (_swig_ret Example0) { - return _swig_wrap_new_Example0__SWIG_1() -} - -func NewExample0(a ...interface{}) Example0 { - argc := len(a) - if argc == 0 { - return NewExample0__SWIG_1() - } - if argc == 2 { - return NewExample0__SWIG_0(a[0].(int), a[1].(int)) - } - panic("No match for overloaded function call") -} - -var _wrap_delete_Example0 unsafe.Pointer - -func _swig_wrap_delete_Example0(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Example0, _swig_p) - return -} - -func DeleteExample0(arg1 Example0) { - _swig_wrap_delete_Example0(arg1.Swigcptr()) -} - -var _wrap_Example0_GetXSize unsafe.Pointer - -func _swig_wrap_Example0_GetXSize(base SwigcptrExample0) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Example0_GetXSize, _swig_p) - return -} - -func (arg1 SwigcptrExample0) GetXSize() (_swig_ret int) { - return _swig_wrap_Example0_GetXSize(arg1) -} - -var _wrap_Example0_Color unsafe.Pointer - -func _swig_wrap_Example0_Color(base SwigcptrExample0, _ byte, _ byte, _ byte) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Example0_Color, _swig_p) - return -} - -func (arg1 SwigcptrExample0) Color(arg2 byte, arg3 byte, arg4 byte) (_swig_ret int) { - return _swig_wrap_Example0_Color(arg1, arg2, arg3, arg4) -} - -var _wrap_Example0_get_color unsafe.Pointer - -func _swig_wrap_Example0_get_color(base uintptr, _ byte, _ byte, _ byte) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Example0_get_color, _swig_p) - return -} - -func Example0Get_color(arg1 Example0, arg2 byte, arg3 byte, arg4 byte) (_swig_ret int) { - return _swig_wrap_Example0_get_color(arg1.Swigcptr(), arg2, arg3, arg4) -} - -type Example0 interface { - Swigcptr() uintptr - SwigIsExample0() - DirectorInterface() interface{} - GetXSize() (_swig_ret int) - Color(arg2 byte, arg3 byte, arg4 byte) (_swig_ret int) -} - -type _swig_DirectorExample1 struct { - SwigcptrExample1 - v interface{} -} - -func (p *_swig_DirectorExample1) Swigcptr() uintptr { - return p.SwigcptrExample1.Swigcptr() -} - -func (p *_swig_DirectorExample1) SwigIsExample1() { -} - -func (p *_swig_DirectorExample1) DirectorInterface() interface{} { - return p.v -} - -var _wrap__swig_NewDirectorExample1Example1__SWIG_0 unsafe.Pointer - -func _swig_NewDirectorExample1Example1__SWIG_0(_swig_director *_swig_DirectorExample1, _ int, _ int) (_swig_ret SwigcptrExample1) { - _swig_p := uintptr(unsafe.Pointer(&_swig_director)) - _cgo_runtime_cgocall(_wrap__swig_NewDirectorExample1Example1__SWIG_0, _swig_p) - return -} - -func NewDirectorExample1__SWIG_0(v interface{}, arg1 int, arg2 int) Example1 { - p := &_swig_DirectorExample1{0, v} - p.SwigcptrExample1 = _swig_NewDirectorExample1Example1__SWIG_0(p, arg1, arg2) - return p -} - -var _wrap__swig_NewDirectorExample1Example1__SWIG_1 unsafe.Pointer - -func _swig_NewDirectorExample1Example1__SWIG_1(_swig_director *_swig_DirectorExample1) (_swig_ret SwigcptrExample1) { - _swig_p := uintptr(unsafe.Pointer(&_swig_director)) - _cgo_runtime_cgocall(_wrap__swig_NewDirectorExample1Example1__SWIG_1, _swig_p) - return -} - -func NewDirectorExample1__SWIG_1(v interface{}) Example1 { - p := &_swig_DirectorExample1{0, v} - p.SwigcptrExample1 = _swig_NewDirectorExample1Example1__SWIG_1(p) - return p -} - -func NewDirectorExample1(abi interface{}, a ...interface{}) Example1 { - argc := len(a) - if argc == 0 { - return NewDirectorExample1__SWIG_1(abi) - } - if argc == 2 { - return NewDirectorExample1__SWIG_0(abi, a[0].(int), a[1].(int)) - } - panic("No match for overloaded function call") -} - -var _wrap_DeleteDirectorExample1 unsafe.Pointer - -func _swig_wrap_DeleteDirectorExample1(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_DeleteDirectorExample1, _swig_p) - return -} - -func DeleteDirectorExample1(arg1 Example1) { - _swig_wrap_DeleteDirectorExample1(arg1.Swigcptr()) -} - -func Swiggo_DeleteDirector_Example1(p *_swig_DirectorExample1) { - p.SwigcptrExample1 = 0 -} - -type _swig_DirectorInterfaceExample1Color interface { - Color(byte, byte, byte) int -} - -func (swig_p *_swig_DirectorExample1) Color(r byte, g byte, b byte) int { - if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceExample1Color); swig_ok { - return swig_g.Color(r, g, b) - } - panic("call to pure virtual method") -} - -func Swig_DirectorExample1_callback_Color(p *_swig_DirectorExample1, r byte, g byte, b byte) (swig_result int) { - var swig_r int - swig_r = p.Color(r, g, b) - return swig_r -} - -type SwigcptrExample1 uintptr - -func (p SwigcptrExample1) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrExample1) SwigIsExample1() { -} - -func (p SwigcptrExample1) DirectorInterface() interface{} { - return nil -} - -var _wrap_new_Example1__SWIG_0 unsafe.Pointer - -func _swig_wrap_new_Example1__SWIG_0(base int, _ int) (_ SwigcptrExample1) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Example1__SWIG_0, _swig_p) - return -} - -func NewExample1__SWIG_0(arg1 int, arg2 int) (_swig_ret Example1) { - return _swig_wrap_new_Example1__SWIG_0(arg1, arg2) -} - -var _wrap_new_Example1__SWIG_1 unsafe.Pointer - -func _swig_wrap_new_Example1__SWIG_1() (base SwigcptrExample1) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Example1__SWIG_1, _swig_p) - return -} - -func NewExample1__SWIG_1() (_swig_ret Example1) { - return _swig_wrap_new_Example1__SWIG_1() -} - -func NewExample1(a ...interface{}) Example1 { - argc := len(a) - if argc == 0 { - return NewExample1__SWIG_1() - } - if argc == 2 { - return NewExample1__SWIG_0(a[0].(int), a[1].(int)) - } - panic("No match for overloaded function call") -} - -var _wrap_delete_Example1 unsafe.Pointer - -func _swig_wrap_delete_Example1(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Example1, _swig_p) - return -} - -func DeleteExample1(arg1 Example1) { - _swig_wrap_delete_Example1(arg1.Swigcptr()) -} - -var _wrap_Example1_GetXSize unsafe.Pointer - -func _swig_wrap_Example1_GetXSize(base SwigcptrExample1) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Example1_GetXSize, _swig_p) - return -} - -func (arg1 SwigcptrExample1) GetXSize() (_swig_ret int) { - return _swig_wrap_Example1_GetXSize(arg1) -} - -var _wrap_Example1_Color unsafe.Pointer - -func _swig_wrap_Example1_Color(base SwigcptrExample1, _ byte, _ byte, _ byte) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Example1_Color, _swig_p) - return -} - -func (arg1 SwigcptrExample1) Color(arg2 byte, arg3 byte, arg4 byte) (_swig_ret int) { - return _swig_wrap_Example1_Color(arg1, arg2, arg3, arg4) -} - -var _wrap_Example1_get_color unsafe.Pointer - -func _swig_wrap_Example1_get_color(base uintptr, _ byte, _ byte, _ byte) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Example1_get_color, _swig_p) - return -} - -func Example1Get_color(arg1 Example1, arg2 byte, arg3 byte, arg4 byte) (_swig_ret int) { - return _swig_wrap_Example1_get_color(arg1.Swigcptr(), arg2, arg3, arg4) -} - -type Example1 interface { - Swigcptr() uintptr - SwigIsExample1() - DirectorInterface() interface{} - GetXSize() (_swig_ret int) - Color(arg2 byte, arg3 byte, arg4 byte) (_swig_ret int) -} - -type _swig_DirectorExample2 struct { - SwigcptrExample2 - v interface{} -} - -func (p *_swig_DirectorExample2) Swigcptr() uintptr { - return p.SwigcptrExample2.Swigcptr() -} - -func (p *_swig_DirectorExample2) SwigIsExample2() { -} - -func (p *_swig_DirectorExample2) DirectorInterface() interface{} { - return p.v -} - -var _wrap__swig_NewDirectorExample2Example2__SWIG_0 unsafe.Pointer - -func _swig_NewDirectorExample2Example2__SWIG_0(_swig_director *_swig_DirectorExample2, _ int) (_swig_ret SwigcptrExample2) { - _swig_p := uintptr(unsafe.Pointer(&_swig_director)) - _cgo_runtime_cgocall(_wrap__swig_NewDirectorExample2Example2__SWIG_0, _swig_p) - return -} - -func NewDirectorExample2__SWIG_0(v interface{}, arg1 int) Example2 { - p := &_swig_DirectorExample2{0, v} - p.SwigcptrExample2 = _swig_NewDirectorExample2Example2__SWIG_0(p, arg1) - return p -} - -var _wrap__swig_NewDirectorExample2Example2__SWIG_1 unsafe.Pointer - -func _swig_NewDirectorExample2Example2__SWIG_1(_swig_director *_swig_DirectorExample2, _ int, _ int) (_swig_ret SwigcptrExample2) { - _swig_p := uintptr(unsafe.Pointer(&_swig_director)) - _cgo_runtime_cgocall(_wrap__swig_NewDirectorExample2Example2__SWIG_1, _swig_p) - return -} - -func NewDirectorExample2__SWIG_1(v interface{}, arg1 int, arg2 int) Example2 { - p := &_swig_DirectorExample2{0, v} - p.SwigcptrExample2 = _swig_NewDirectorExample2Example2__SWIG_1(p, arg1, arg2) - return p -} - -func NewDirectorExample2(abi interface{}, a ...interface{}) Example2 { - argc := len(a) - if argc == 1 { - return NewDirectorExample2__SWIG_0(abi, a[0].(int)) - } - if argc == 2 { - return NewDirectorExample2__SWIG_1(abi, a[0].(int), a[1].(int)) - } - panic("No match for overloaded function call") -} - -var _wrap_DeleteDirectorExample2 unsafe.Pointer - -func _swig_wrap_DeleteDirectorExample2(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_DeleteDirectorExample2, _swig_p) - return -} - -func DeleteDirectorExample2(arg1 Example2) { - _swig_wrap_DeleteDirectorExample2(arg1.Swigcptr()) -} - -func Swiggo_DeleteDirector_Example2(p *_swig_DirectorExample2) { - p.SwigcptrExample2 = 0 -} - -type _swig_DirectorInterfaceExample2Color interface { - Color(byte, byte, byte) int -} - -func (swig_p *_swig_DirectorExample2) Color(r byte, g byte, b byte) int { - if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceExample2Color); swig_ok { - return swig_g.Color(r, g, b) - } - panic("call to pure virtual method") -} - -func Swig_DirectorExample2_callback_Color(p *_swig_DirectorExample2, r byte, g byte, b byte) (swig_result int) { - var swig_r int - swig_r = p.Color(r, g, b) - return swig_r -} - -type SwigcptrExample2 uintptr - -func (p SwigcptrExample2) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrExample2) SwigIsExample2() { -} - -func (p SwigcptrExample2) DirectorInterface() interface{} { - return nil -} - -var _wrap_new_Example2__SWIG_0 unsafe.Pointer - -func _swig_wrap_new_Example2__SWIG_0(base int) (_ SwigcptrExample2) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Example2__SWIG_0, _swig_p) - return -} - -func NewExample2__SWIG_0(arg1 int) (_swig_ret Example2) { - return _swig_wrap_new_Example2__SWIG_0(arg1) -} - -var _wrap_new_Example2__SWIG_1 unsafe.Pointer - -func _swig_wrap_new_Example2__SWIG_1(base int, _ int) (_ SwigcptrExample2) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Example2__SWIG_1, _swig_p) - return -} - -func NewExample2__SWIG_1(arg1 int, arg2 int) (_swig_ret Example2) { - return _swig_wrap_new_Example2__SWIG_1(arg1, arg2) -} - -func NewExample2(a ...interface{}) Example2 { - argc := len(a) - if argc == 1 { - return NewExample2__SWIG_0(a[0].(int)) - } - if argc == 2 { - return NewExample2__SWIG_1(a[0].(int), a[1].(int)) - } - panic("No match for overloaded function call") -} - -var _wrap_delete_Example2 unsafe.Pointer - -func _swig_wrap_delete_Example2(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Example2, _swig_p) - return -} - -func DeleteExample2(arg1 Example2) { - _swig_wrap_delete_Example2(arg1.Swigcptr()) -} - -var _wrap_Example2_GetXSize unsafe.Pointer - -func _swig_wrap_Example2_GetXSize(base SwigcptrExample2) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Example2_GetXSize, _swig_p) - return -} - -func (arg1 SwigcptrExample2) GetXSize() (_swig_ret int) { - return _swig_wrap_Example2_GetXSize(arg1) -} - -var _wrap_Example2_Color unsafe.Pointer - -func _swig_wrap_Example2_Color(base SwigcptrExample2, _ byte, _ byte, _ byte) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Example2_Color, _swig_p) - return -} - -func (arg1 SwigcptrExample2) Color(arg2 byte, arg3 byte, arg4 byte) (_swig_ret int) { - return _swig_wrap_Example2_Color(arg1, arg2, arg3, arg4) -} - -var _wrap_Example2_get_color unsafe.Pointer - -func _swig_wrap_Example2_get_color(base uintptr, _ byte, _ byte, _ byte) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Example2_get_color, _swig_p) - return -} - -func Example2Get_color(arg1 Example2, arg2 byte, arg3 byte, arg4 byte) (_swig_ret int) { - return _swig_wrap_Example2_get_color(arg1.Swigcptr(), arg2, arg3, arg4) -} - -type Example2 interface { - Swigcptr() uintptr - SwigIsExample2() - DirectorInterface() interface{} - GetXSize() (_swig_ret int) - Color(arg2 byte, arg3 byte, arg4 byte) (_swig_ret int) -} - -type _swig_DirectorExample4 struct { - SwigcptrExample4 - v interface{} -} - -func (p *_swig_DirectorExample4) Swigcptr() uintptr { - return p.SwigcptrExample4.Swigcptr() -} - -func (p *_swig_DirectorExample4) SwigIsExample4() { -} - -func (p *_swig_DirectorExample4) DirectorInterface() interface{} { - return p.v -} - -var _wrap__swig_NewDirectorExample4Example4__SWIG_0 unsafe.Pointer - -func _swig_NewDirectorExample4Example4__SWIG_0(_swig_director *_swig_DirectorExample4) (_swig_ret SwigcptrExample4) { - _swig_p := uintptr(unsafe.Pointer(&_swig_director)) - _cgo_runtime_cgocall(_wrap__swig_NewDirectorExample4Example4__SWIG_0, _swig_p) - return -} - -func NewDirectorExample4__SWIG_0(v interface{}) Example4 { - p := &_swig_DirectorExample4{0, v} - p.SwigcptrExample4 = _swig_NewDirectorExample4Example4__SWIG_0(p) - return p -} - -var _wrap__swig_NewDirectorExample4Example4__SWIG_1 unsafe.Pointer - -func _swig_NewDirectorExample4Example4__SWIG_1(_swig_director *_swig_DirectorExample4, _ int, _ int) (_swig_ret SwigcptrExample4) { - _swig_p := uintptr(unsafe.Pointer(&_swig_director)) - _cgo_runtime_cgocall(_wrap__swig_NewDirectorExample4Example4__SWIG_1, _swig_p) - return -} - -func NewDirectorExample4__SWIG_1(v interface{}, arg1 int, arg2 int) Example4 { - p := &_swig_DirectorExample4{0, v} - p.SwigcptrExample4 = _swig_NewDirectorExample4Example4__SWIG_1(p, arg1, arg2) - return p -} - -func NewDirectorExample4(abi interface{}, a ...interface{}) Example4 { - argc := len(a) - if argc == 0 { - return NewDirectorExample4__SWIG_0(abi) - } - if argc == 2 { - return NewDirectorExample4__SWIG_1(abi, a[0].(int), a[1].(int)) - } - panic("No match for overloaded function call") -} - -var _wrap_DeleteDirectorExample4 unsafe.Pointer - -func _swig_wrap_DeleteDirectorExample4(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_DeleteDirectorExample4, _swig_p) - return -} - -func DeleteDirectorExample4(arg1 Example4) { - _swig_wrap_DeleteDirectorExample4(arg1.Swigcptr()) -} - -func Swiggo_DeleteDirector_Example4(p *_swig_DirectorExample4) { - p.SwigcptrExample4 = 0 -} - -type _swig_DirectorInterfaceExample4Color interface { - Color(byte, byte, byte) int -} - -func (swig_p *_swig_DirectorExample4) Color(r byte, g byte, b byte) int { - if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceExample4Color); swig_ok { - return swig_g.Color(r, g, b) - } - panic("call to pure virtual method") -} - -func Swig_DirectorExample4_callback_Color(p *_swig_DirectorExample4, r byte, g byte, b byte) (swig_result int) { - var swig_r int - swig_r = p.Color(r, g, b) - return swig_r -} - -type SwigcptrExample4 uintptr - -func (p SwigcptrExample4) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrExample4) SwigIsExample4() { -} - -func (p SwigcptrExample4) DirectorInterface() interface{} { - return nil -} - -var _wrap_new_Example4__SWIG_0 unsafe.Pointer - -func _swig_wrap_new_Example4__SWIG_0() (base SwigcptrExample4) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Example4__SWIG_0, _swig_p) - return -} - -func NewExample4__SWIG_0() (_swig_ret Example4) { - return _swig_wrap_new_Example4__SWIG_0() -} - -var _wrap_new_Example4__SWIG_1 unsafe.Pointer - -func _swig_wrap_new_Example4__SWIG_1(base int, _ int) (_ SwigcptrExample4) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Example4__SWIG_1, _swig_p) - return -} - -func NewExample4__SWIG_1(arg1 int, arg2 int) (_swig_ret Example4) { - return _swig_wrap_new_Example4__SWIG_1(arg1, arg2) -} - -func NewExample4(a ...interface{}) Example4 { - argc := len(a) - if argc == 0 { - return NewExample4__SWIG_0() - } - if argc == 2 { - return NewExample4__SWIG_1(a[0].(int), a[1].(int)) - } - panic("No match for overloaded function call") -} - -var _wrap_delete_Example4 unsafe.Pointer - -func _swig_wrap_delete_Example4(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Example4, _swig_p) - return -} - -func DeleteExample4(arg1 Example4) { - _swig_wrap_delete_Example4(arg1.Swigcptr()) -} - -var _wrap_Example4_GetXSize unsafe.Pointer - -func _swig_wrap_Example4_GetXSize(base SwigcptrExample4) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Example4_GetXSize, _swig_p) - return -} - -func (arg1 SwigcptrExample4) GetXSize() (_swig_ret int) { - return _swig_wrap_Example4_GetXSize(arg1) -} - -var _wrap_Example4_Color unsafe.Pointer - -func _swig_wrap_Example4_Color(base SwigcptrExample4, _ byte, _ byte, _ byte) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Example4_Color, _swig_p) - return -} - -func (arg1 SwigcptrExample4) Color(arg2 byte, arg3 byte, arg4 byte) (_swig_ret int) { - return _swig_wrap_Example4_Color(arg1, arg2, arg3, arg4) -} - -var _wrap_Example4_get_color unsafe.Pointer - -func _swig_wrap_Example4_get_color(base uintptr, _ byte, _ byte, _ byte) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Example4_get_color, _swig_p) - return -} - -func Example4Get_color(arg1 Example4, arg2 byte, arg3 byte, arg4 byte) (_swig_ret int) { - return _swig_wrap_Example4_get_color(arg1.Swigcptr(), arg2, arg3, arg4) -} - -type Example4 interface { - Swigcptr() uintptr - SwigIsExample4() - DirectorInterface() interface{} - GetXSize() (_swig_ret int) - Color(arg2 byte, arg3 byte, arg4 byte) (_swig_ret int) -} - -type _swig_DirectorExample3_i struct { - SwigcptrExample3_i - v interface{} -} - -func (p *_swig_DirectorExample3_i) Swigcptr() uintptr { - return p.SwigcptrExample3_i.Swigcptr() -} - -func (p *_swig_DirectorExample3_i) SwigIsExample3_i() { -} - -func (p *_swig_DirectorExample3_i) DirectorInterface() interface{} { - return p.v -} - -var _wrap__swig_NewDirectorExample3_iExample3_i__SWIG_0 unsafe.Pointer - -func _swig_NewDirectorExample3_iExample3_i__SWIG_0(_swig_director *_swig_DirectorExample3_i) (_swig_ret SwigcptrExample3_i) { - _swig_p := uintptr(unsafe.Pointer(&_swig_director)) - _cgo_runtime_cgocall(_wrap__swig_NewDirectorExample3_iExample3_i__SWIG_0, _swig_p) - return -} - -func NewDirectorExample3_i__SWIG_0(v interface{}) Example3_i { - p := &_swig_DirectorExample3_i{0, v} - p.SwigcptrExample3_i = _swig_NewDirectorExample3_iExample3_i__SWIG_0(p) - return p -} - -var _wrap__swig_NewDirectorExample3_iExample3_i__SWIG_1 unsafe.Pointer - -func _swig_NewDirectorExample3_iExample3_i__SWIG_1(_swig_director *_swig_DirectorExample3_i, _ int) (_swig_ret SwigcptrExample3_i) { - _swig_p := uintptr(unsafe.Pointer(&_swig_director)) - _cgo_runtime_cgocall(_wrap__swig_NewDirectorExample3_iExample3_i__SWIG_1, _swig_p) - return -} - -func NewDirectorExample3_i__SWIG_1(v interface{}, arg1 int) Example3_i { - p := &_swig_DirectorExample3_i{0, v} - p.SwigcptrExample3_i = _swig_NewDirectorExample3_iExample3_i__SWIG_1(p, arg1) - return p -} - -var _wrap__swig_NewDirectorExample3_iExample3_i__SWIG_2 unsafe.Pointer - -func _swig_NewDirectorExample3_iExample3_i__SWIG_2(_swig_director *_swig_DirectorExample3_i, _ int, _ int) (_swig_ret SwigcptrExample3_i) { - _swig_p := uintptr(unsafe.Pointer(&_swig_director)) - _cgo_runtime_cgocall(_wrap__swig_NewDirectorExample3_iExample3_i__SWIG_2, _swig_p) - return -} - -func NewDirectorExample3_i__SWIG_2(v interface{}, arg1 int, arg2 int) Example3_i { - p := &_swig_DirectorExample3_i{0, v} - p.SwigcptrExample3_i = _swig_NewDirectorExample3_iExample3_i__SWIG_2(p, arg1, arg2) - return p -} - -func NewDirectorExample3_i(abi interface{}, a ...interface{}) Example3_i { - argc := len(a) - if argc == 0 { - return NewDirectorExample3_i__SWIG_0(abi) - } - if argc == 1 { - return NewDirectorExample3_i__SWIG_1(abi, a[0].(int)) - } - if argc == 2 { - return NewDirectorExample3_i__SWIG_2(abi, a[0].(int), a[1].(int)) - } - panic("No match for overloaded function call") -} - -var _wrap_DeleteDirectorExample3_i unsafe.Pointer - -func _swig_wrap_DeleteDirectorExample3_i(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_DeleteDirectorExample3_i, _swig_p) - return -} - -func DeleteDirectorExample3_i(arg1 Example3_i) { - _swig_wrap_DeleteDirectorExample3_i(arg1.Swigcptr()) -} - -func Swiggo_DeleteDirector_Example3_i(p *_swig_DirectorExample3_i) { - p.SwigcptrExample3_i = 0 -} - -type _swig_DirectorInterfaceExample3_iColor interface { - Color(byte, byte, byte) int -} - -func (swig_p *_swig_DirectorExample3_i) Color(r byte, g byte, b byte) int { - if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceExample3_iColor); swig_ok { - return swig_g.Color(r, g, b) - } - panic("call to pure virtual method") -} - -func Swig_DirectorExample3_i_callback_Color(p *_swig_DirectorExample3_i, r byte, g byte, b byte) (swig_result int) { - var swig_r int - swig_r = p.Color(r, g, b) - return swig_r -} - -type SwigcptrExample3_i uintptr - -func (p SwigcptrExample3_i) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrExample3_i) SwigIsExample3_i() { -} - -func (p SwigcptrExample3_i) DirectorInterface() interface{} { - return nil -} - -var _wrap_new_Example3_i__SWIG_0 unsafe.Pointer - -func _swig_wrap_new_Example3_i__SWIG_0() (base SwigcptrExample3_i) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Example3_i__SWIG_0, _swig_p) - return -} - -func NewExample3_i__SWIG_0() (_swig_ret Example3_i) { - return _swig_wrap_new_Example3_i__SWIG_0() -} - -var _wrap_new_Example3_i__SWIG_1 unsafe.Pointer - -func _swig_wrap_new_Example3_i__SWIG_1(base int) (_ SwigcptrExample3_i) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Example3_i__SWIG_1, _swig_p) - return -} - -func NewExample3_i__SWIG_1(arg1 int) (_swig_ret Example3_i) { - return _swig_wrap_new_Example3_i__SWIG_1(arg1) -} - -var _wrap_new_Example3_i__SWIG_2 unsafe.Pointer - -func _swig_wrap_new_Example3_i__SWIG_2(base int, _ int) (_ SwigcptrExample3_i) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Example3_i__SWIG_2, _swig_p) - return -} - -func NewExample3_i__SWIG_2(arg1 int, arg2 int) (_swig_ret Example3_i) { - return _swig_wrap_new_Example3_i__SWIG_2(arg1, arg2) -} - -func NewExample3_i(a ...interface{}) Example3_i { - argc := len(a) - if argc == 0 { - return NewExample3_i__SWIG_0() - } - if argc == 1 { - return NewExample3_i__SWIG_1(a[0].(int)) - } - if argc == 2 { - return NewExample3_i__SWIG_2(a[0].(int), a[1].(int)) - } - panic("No match for overloaded function call") -} - -var _wrap_delete_Example3_i unsafe.Pointer - -func _swig_wrap_delete_Example3_i(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Example3_i, _swig_p) - return -} - -func DeleteExample3_i(arg1 Example3_i) { - _swig_wrap_delete_Example3_i(arg1.Swigcptr()) -} - -var _wrap_Example3_i_Color unsafe.Pointer - -func _swig_wrap_Example3_i_Color(base SwigcptrExample3_i, _ byte, _ byte, _ byte) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Example3_i_Color, _swig_p) - return -} - -func (arg1 SwigcptrExample3_i) Color(arg2 byte, arg3 byte, arg4 byte) (_swig_ret int) { - return _swig_wrap_Example3_i_Color(arg1, arg2, arg3, arg4) -} - -var _wrap_Example3_i_get_color unsafe.Pointer - -func _swig_wrap_Example3_i_get_color(base uintptr, _ byte, _ byte, _ byte) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Example3_i_get_color, _swig_p) - return -} - -func Example3_iGet_color(arg1 Example3_i, arg2 byte, arg3 byte, arg4 byte) (_swig_ret int) { - return _swig_wrap_Example3_i_get_color(arg1.Swigcptr(), arg2, arg3, arg4) -} - -type Example3_i interface { - Swigcptr() uintptr - SwigIsExample3_i() - DirectorInterface() interface{} - Color(arg2 byte, arg3 byte, arg4 byte) (_swig_ret int) -} - -type _swig_DirectorA struct { - SwigcptrA - v interface{} -} - -func (p *_swig_DirectorA) Swigcptr() uintptr { - return p.SwigcptrA.Swigcptr() -} - -func (p *_swig_DirectorA) SwigIsA() { -} - -func (p *_swig_DirectorA) DirectorInterface() interface{} { - return p.v -} - -var _wrap__swig_NewDirectorAA unsafe.Pointer - -func _swig_NewDirectorAA(_swig_director *_swig_DirectorA, _ A) (_swig_ret SwigcptrA) { - _swig_p := uintptr(unsafe.Pointer(&_swig_director)) - _cgo_runtime_cgocall(_wrap__swig_NewDirectorAA, _swig_p) - return -} - -func NewDirectorA(v interface{}, arg1 A) A { - p := &_swig_DirectorA{0, v} - p.SwigcptrA = _swig_NewDirectorAA(p, arg1) - return p -} - -var _wrap_DeleteDirectorA unsafe.Pointer - -func _swig_wrap_DeleteDirectorA(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_DeleteDirectorA, _swig_p) - return -} - -func DeleteDirectorA(arg1 A) { - _swig_wrap_DeleteDirectorA(arg1.Swigcptr()) -} - -func Swiggo_DeleteDirector_A(p *_swig_DirectorA) { - p.SwigcptrA = 0 -} - -type _swig_DirectorInterfaceAF interface { - F() int -} - -func (swig_p *_swig_DirectorA) F() int { - if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceAF); swig_ok { - return swig_g.F() - } - panic("call to pure virtual method") -} - -func Swig_DirectorA_callback_f(p *_swig_DirectorA) (swig_result int) { - var swig_r int - swig_r = p.F() - return swig_r -} - -type SwigcptrA uintptr - -func (p SwigcptrA) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrA) SwigIsA() { -} - -func (p SwigcptrA) DirectorInterface() interface{} { - return nil -} - -var _wrap_delete_A unsafe.Pointer - -func _swig_wrap_delete_A(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_A, _swig_p) - return -} - -func DeleteA(arg1 A) { - _swig_wrap_delete_A(arg1.Swigcptr()) -} - -var _wrap_g unsafe.Pointer - -func _swig_wrap_g(base uintptr) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_g, _swig_p) - return -} - -func G(arg1 A) (_swig_ret int) { - return _swig_wrap_g(arg1.Swigcptr()) -} - -var _wrap_new_A unsafe.Pointer - -func _swig_wrap_new_A(base uintptr) (_ SwigcptrA) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_A, _swig_p) - return -} - -func NewA(arg1 A) (_swig_ret A) { - return _swig_wrap_new_A(arg1.Swigcptr()) -} - -type A interface { - Swigcptr() uintptr - SwigIsA() - DirectorInterface() interface{} -} - - -type SwigcptrSwigDirector_Example0 uintptr -type SwigDirector_Example0 interface { - Swigcptr() uintptr; -} -func (p SwigcptrSwigDirector_Example0) Swigcptr() uintptr { - return uintptr(p) -} - -type SwigcptrSwigDirector_Foo uintptr -type SwigDirector_Foo interface { - Swigcptr() uintptr; -} -func (p SwigcptrSwigDirector_Foo) Swigcptr() uintptr { - return uintptr(p) -} - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/director_abstract_wrap.h b/Examples/test-suite/go/director_abstract_wrap.h deleted file mode 100644 index a2b4e51ee..000000000 --- a/Examples/test-suite/go/director_abstract_wrap.h +++ /dev/null @@ -1,99 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../director_abstract.i - -#ifndef SWIG_director_abstract_WRAP_H_ -#define SWIG_director_abstract_WRAP_H_ - -class SwigDirector_Foo : public Foo -{ - public: - SwigDirector_Foo(void *swig_p); - virtual ~SwigDirector_Foo(); - virtual std::string ping(); - std::string _swig_upcall_pong() { - return Foo::pong(); - } - virtual std::string pong(); - private: - void *go_val; -}; - -class SwigDirector_Example0 : public Example0 -{ - public: - SwigDirector_Example0(void *swig_p, int x, int y); - SwigDirector_Example0(void *swig_p); - virtual ~SwigDirector_Example0(); - int _swig_upcall_Color(unsigned char r, unsigned char g, unsigned char b) { - return Example0::Color(r,g,b); - } - virtual int Color(unsigned char r, unsigned char g, unsigned char b); - private: - void *go_val; -}; - -class SwigDirector_Example1 : public Example1 -{ - public: - SwigDirector_Example1(void *swig_p, int x, int y); - SwigDirector_Example1(void *swig_p); - virtual ~SwigDirector_Example1(); - virtual int Color(unsigned char r, unsigned char g, unsigned char b); - private: - void *go_val; -}; - -class SwigDirector_Example2 : public Example2 -{ - public: - SwigDirector_Example2(void *swig_p, int x); - SwigDirector_Example2(void *swig_p, int x, int y); - virtual ~SwigDirector_Example2(); - virtual int Color(unsigned char r, unsigned char g, unsigned char b); - private: - void *go_val; -}; - -class SwigDirector_Example4 : public Example4 -{ - public: - SwigDirector_Example4(void *swig_p); - SwigDirector_Example4(void *swig_p, int x, int y); - virtual ~SwigDirector_Example4(); - virtual int Color(unsigned char r, unsigned char g, unsigned char b); - private: - void *go_val; -}; - -class SwigDirector_Example3_i : public ns::Example3< int > -{ - public: - SwigDirector_Example3_i(void *swig_p); - SwigDirector_Example3_i(void *swig_p, int x); - SwigDirector_Example3_i(void *swig_p, int x, int y); - virtual ~SwigDirector_Example3_i(); - virtual int Color(unsigned char r, unsigned char g, unsigned char b); - private: - void *go_val; -}; - -class SwigDirector_A : public A -{ - public: - SwigDirector_A(void *swig_p, A const &arg0); - virtual ~SwigDirector_A(); - virtual int f(); - private: - void *go_val; -}; - -#endif diff --git a/Examples/test-suite/go/director_alternating.go b/Examples/test-suite/go/director_alternating.go deleted file mode 100644 index 4f83b3c91..000000000 --- a/Examples/test-suite/go/director_alternating.go +++ /dev/null @@ -1,328 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../director_alternating.i - -package director_alternating - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type _swig_DirectorFoo struct { - SwigcptrFoo - v interface{} -} - -func (p *_swig_DirectorFoo) Swigcptr() uintptr { - return p.SwigcptrFoo.Swigcptr() -} - -func (p *_swig_DirectorFoo) SwigIsFoo() { -} - -func (p *_swig_DirectorFoo) DirectorInterface() interface{} { - return p.v -} - -var _wrap__swig_NewDirectorFooFoo unsafe.Pointer - -func _swig_NewDirectorFooFoo(_swig_director *_swig_DirectorFoo) (_swig_ret SwigcptrFoo) { - _swig_p := uintptr(unsafe.Pointer(&_swig_director)) - _cgo_runtime_cgocall(_wrap__swig_NewDirectorFooFoo, _swig_p) - return -} - -func NewDirectorFoo(v interface{}) Foo { - p := &_swig_DirectorFoo{0, v} - p.SwigcptrFoo = _swig_NewDirectorFooFoo(p) - return p -} - -var _wrap_DeleteDirectorFoo unsafe.Pointer - -func _swig_wrap_DeleteDirectorFoo(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_DeleteDirectorFoo, _swig_p) - return -} - -func DeleteDirectorFoo(arg1 Foo) { - _swig_wrap_DeleteDirectorFoo(arg1.Swigcptr()) -} - -func Swiggo_DeleteDirector_Foo(p *_swig_DirectorFoo) { - p.SwigcptrFoo = 0 -} - -type _swig_DirectorInterfaceFooId interface { - Id() int -} - -var _wrap__swig_DirectorFoo_upcall_Id unsafe.Pointer - -func _swig_wrap__swig_DirectorFoo_upcall_Id(_swig_ptr SwigcptrFoo) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) - _cgo_runtime_cgocall(_wrap__swig_DirectorFoo_upcall_Id, _swig_p) - return -} - -func (swig_p *_swig_DirectorFoo) Id() int { - if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceFooId); swig_ok { - return swig_g.Id() - } - var swig_r int - swig_r = _swig_wrap__swig_DirectorFoo_upcall_Id(swig_p.SwigcptrFoo) - return swig_r -} - -func DirectorFooId(p Foo) int { - var swig_r int - swig_r = _swig_wrap__swig_DirectorFoo_upcall_Id(p.(*_swig_DirectorFoo).SwigcptrFoo) - return swig_r -} - -func Swig_DirectorFoo_callback_id(p *_swig_DirectorFoo) (swig_result int) { - var swig_r int - swig_r = p.Id() - return swig_r -} - -type SwigcptrFoo uintptr - -func (p SwigcptrFoo) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrFoo) SwigIsFoo() { -} - -func (p SwigcptrFoo) DirectorInterface() interface{} { - return nil -} - -var _wrap_delete_Foo unsafe.Pointer - -func _swig_wrap_delete_Foo(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Foo, _swig_p) - return -} - -func DeleteFoo(arg1 Foo) { - _swig_wrap_delete_Foo(arg1.Swigcptr()) -} - -var _wrap_Foo_id unsafe.Pointer - -func _swig_wrap_Foo_id(base SwigcptrFoo) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_id, _swig_p) - return -} - -func (arg1 SwigcptrFoo) Id() (_swig_ret int) { - return _swig_wrap_Foo_id(arg1) -} - -var _wrap_new_Foo unsafe.Pointer - -func _swig_wrap_new_Foo() (base SwigcptrFoo) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Foo, _swig_p) - return -} - -func NewFoo() (_swig_ret Foo) { - return _swig_wrap_new_Foo() -} - -type Foo interface { - Swigcptr() uintptr - SwigIsFoo() - DirectorInterface() interface{} - Id() (_swig_ret int) -} - -type SwigcptrBar uintptr - -func (p SwigcptrBar) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrBar) SwigIsBar() { -} - -var _wrap_new_Bar unsafe.Pointer - -func _swig_wrap_new_Bar() (base SwigcptrBar) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Bar, _swig_p) - return -} - -func NewBar() (_swig_ret Bar) { - return _swig_wrap_new_Bar() -} - -var _wrap_delete_Bar unsafe.Pointer - -func _swig_wrap_delete_Bar(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Bar, _swig_p) - return -} - -func DeleteBar(arg1 Bar) { - _swig_wrap_delete_Bar(arg1.Swigcptr()) -} - -var _wrap_Bar_id unsafe.Pointer - -func _swig_wrap_Bar_id(base SwigcptrBar) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Bar_id, _swig_p) - return -} - -func (_swig_base SwigcptrBar) Id() (_swig_ret int) { - return _swig_wrap_Bar_id(_swig_base) -} - -func (p SwigcptrBar) SwigIsFoo() { -} - -func (p SwigcptrBar) SwigGetFoo() Foo { - return SwigcptrFoo(p.Swigcptr()) -} - -type Bar interface { - Swigcptr() uintptr - SwigIsBar() - Id() (_swig_ret int) - SwigIsFoo() - SwigGetFoo() Foo -} - -type SwigcptrBaz uintptr - -func (p SwigcptrBaz) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrBaz) SwigIsBaz() { -} - -var _wrap_Baz_id unsafe.Pointer - -func _swig_wrap_Baz_id(base SwigcptrBaz) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Baz_id, _swig_p) - return -} - -func (arg1 SwigcptrBaz) Id() (_swig_ret int) { - return _swig_wrap_Baz_id(arg1) -} - -var _wrap_new_Baz unsafe.Pointer - -func _swig_wrap_new_Baz() (base SwigcptrBaz) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Baz, _swig_p) - return -} - -func NewBaz() (_swig_ret Baz) { - return _swig_wrap_new_Baz() -} - -var _wrap_delete_Baz unsafe.Pointer - -func _swig_wrap_delete_Baz(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Baz, _swig_p) - return -} - -func DeleteBaz(arg1 Baz) { - _swig_wrap_delete_Baz(arg1.Swigcptr()) -} - -func (p SwigcptrBaz) SwigIsBar() { -} - -func (p SwigcptrBaz) SwigGetBar() Bar { - return SwigcptrBar(p.Swigcptr()) -} - -func (p SwigcptrBaz) SwigIsFoo() { -} - -func (p SwigcptrBaz) SwigGetFoo() Foo { - return SwigcptrFoo(p.Swigcptr()) -} - -type Baz interface { - Swigcptr() uintptr - SwigIsBaz() - Id() (_swig_ret int) - SwigIsBar() - SwigGetBar() Bar - SwigIsFoo() - SwigGetFoo() Foo -} - -var _wrap_getBar unsafe.Pointer - -func _swig_wrap_getBar() (base SwigcptrBar) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_getBar, _swig_p) - return -} - -func GetBar() (_swig_ret Bar) { - return _swig_wrap_getBar() -} - -var _wrap_idFromGetBar unsafe.Pointer - -func IdFromGetBar() (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_idFromGetBar, _swig_p) - return -} - -type SwigcptrSwigDirector_Foo uintptr -type SwigDirector_Foo interface { - Swigcptr() uintptr; -} -func (p SwigcptrSwigDirector_Foo) Swigcptr() uintptr { - return uintptr(p) -} - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/director_alternating_runme b/Examples/test-suite/go/director_alternating_runme deleted file mode 100755 index 44454efb3..000000000 Binary files a/Examples/test-suite/go/director_alternating_runme and /dev/null differ diff --git a/Examples/test-suite/go/director_alternating_wrap.h b/Examples/test-suite/go/director_alternating_wrap.h deleted file mode 100644 index 651935066..000000000 --- a/Examples/test-suite/go/director_alternating_wrap.h +++ /dev/null @@ -1,29 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../director_alternating.i - -#ifndef SWIG_director_alternating_WRAP_H_ -#define SWIG_director_alternating_WRAP_H_ - -class SwigDirector_Foo : public Foo -{ - public: - SwigDirector_Foo(void *swig_p); - virtual ~SwigDirector_Foo(); - int _swig_upcall_id() { - return Foo::id(); - } - virtual int id(); - private: - void *go_val; -}; - -#endif diff --git a/Examples/test-suite/go/director_basic.go b/Examples/test-suite/go/director_basic.go deleted file mode 100644 index f16bcd816..000000000 --- a/Examples/test-suite/go/director_basic.go +++ /dev/null @@ -1,1420 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../director_basic.i - -package director_basic - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type _swig_DirectorFoo struct { - SwigcptrFoo - v interface{} -} - -func (p *_swig_DirectorFoo) Swigcptr() uintptr { - return p.SwigcptrFoo.Swigcptr() -} - -func (p *_swig_DirectorFoo) SwigIsFoo() { -} - -func (p *_swig_DirectorFoo) DirectorInterface() interface{} { - return p.v -} - -var _wrap__swig_NewDirectorFooFoo unsafe.Pointer - -func _swig_NewDirectorFooFoo(_swig_director *_swig_DirectorFoo) (_swig_ret SwigcptrFoo) { - _swig_p := uintptr(unsafe.Pointer(&_swig_director)) - _cgo_runtime_cgocall(_wrap__swig_NewDirectorFooFoo, _swig_p) - return -} - -func NewDirectorFoo(v interface{}) Foo { - p := &_swig_DirectorFoo{0, v} - p.SwigcptrFoo = _swig_NewDirectorFooFoo(p) - return p -} - -var _wrap_DeleteDirectorFoo unsafe.Pointer - -func _swig_wrap_DeleteDirectorFoo(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_DeleteDirectorFoo, _swig_p) - return -} - -func DeleteDirectorFoo(arg1 Foo) { - _swig_wrap_DeleteDirectorFoo(arg1.Swigcptr()) -} - -func Swiggo_DeleteDirector_Foo(p *_swig_DirectorFoo) { - p.SwigcptrFoo = 0 -} - -type _swig_DirectorInterfaceFooPing interface { - Ping() string -} - -var _wrap__swig_DirectorFoo_upcall_Ping unsafe.Pointer - -func _swig_wrap__swig_DirectorFoo_upcall_Ping(_swig_ptr SwigcptrFoo) (_swig_ret string) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) - _cgo_runtime_cgocall(_wrap__swig_DirectorFoo_upcall_Ping, _swig_p) - return -} - -func (swig_p *_swig_DirectorFoo) Ping() string { - if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceFooPing); swig_ok { - return swig_g.Ping() - } - var swig_r string - swig_r = _swig_wrap__swig_DirectorFoo_upcall_Ping(swig_p.SwigcptrFoo) - return swig_r -} - -func DirectorFooPing(p Foo) string { - var swig_r string - swig_r = _swig_wrap__swig_DirectorFoo_upcall_Ping(p.(*_swig_DirectorFoo).SwigcptrFoo) - return swig_r -} - -func Swig_DirectorFoo_callback_ping(p *_swig_DirectorFoo) (swig_result string) { - var swig_r string - swig_r = p.Ping() - return swig_r -} - -type _swig_DirectorInterfaceFooPong interface { - Pong() string -} - -var _wrap__swig_DirectorFoo_upcall_Pong unsafe.Pointer - -func _swig_wrap__swig_DirectorFoo_upcall_Pong(_swig_ptr SwigcptrFoo) (_swig_ret string) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) - _cgo_runtime_cgocall(_wrap__swig_DirectorFoo_upcall_Pong, _swig_p) - return -} - -func (swig_p *_swig_DirectorFoo) Pong() string { - if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceFooPong); swig_ok { - return swig_g.Pong() - } - var swig_r string - swig_r = _swig_wrap__swig_DirectorFoo_upcall_Pong(swig_p.SwigcptrFoo) - return swig_r -} - -func DirectorFooPong(p Foo) string { - var swig_r string - swig_r = _swig_wrap__swig_DirectorFoo_upcall_Pong(p.(*_swig_DirectorFoo).SwigcptrFoo) - return swig_r -} - -func Swig_DirectorFoo_callback_pong(p *_swig_DirectorFoo) (swig_result string) { - var swig_r string - swig_r = p.Pong() - return swig_r -} - -type SwigcptrFoo uintptr - -func (p SwigcptrFoo) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrFoo) SwigIsFoo() { -} - -func (p SwigcptrFoo) DirectorInterface() interface{} { - return nil -} - -var _wrap_delete_Foo unsafe.Pointer - -func _swig_wrap_delete_Foo(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Foo, _swig_p) - return -} - -func DeleteFoo(arg1 Foo) { - _swig_wrap_delete_Foo(arg1.Swigcptr()) -} - -var _wrap_Foo_ping unsafe.Pointer - -func _swig_wrap_Foo_ping(base SwigcptrFoo) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_ping, _swig_p) - return -} - -func (arg1 SwigcptrFoo) Ping() (_swig_ret string) { - return _swig_wrap_Foo_ping(arg1) -} - -var _wrap_Foo_pong unsafe.Pointer - -func _swig_wrap_Foo_pong(base SwigcptrFoo) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_pong, _swig_p) - return -} - -func (arg1 SwigcptrFoo) Pong() (_swig_ret string) { - return _swig_wrap_Foo_pong(arg1) -} - -var _wrap_Foo_get_self unsafe.Pointer - -func _swig_wrap_Foo_get_self(base uintptr) (_ SwigcptrFoo) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_get_self, _swig_p) - return -} - -func FooGet_self(arg1 Foo) (_swig_ret Foo) { - return _swig_wrap_Foo_get_self(arg1.Swigcptr()) -} - -var _wrap_new_Foo unsafe.Pointer - -func _swig_wrap_new_Foo() (base SwigcptrFoo) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Foo, _swig_p) - return -} - -func NewFoo() (_swig_ret Foo) { - return _swig_wrap_new_Foo() -} - -type Foo interface { - Swigcptr() uintptr - SwigIsFoo() - DirectorInterface() interface{} - Ping() (_swig_ret string) - Pong() (_swig_ret string) -} - -type _swig_DirectorA struct { - SwigcptrA - v interface{} -} - -func (p *_swig_DirectorA) Swigcptr() uintptr { - return p.SwigcptrA.Swigcptr() -} - -func (p *_swig_DirectorA) SwigIsA() { -} - -func (p *_swig_DirectorA) DirectorInterface() interface{} { - return p.v -} - -var _wrap__swig_NewDirectorAA__SWIG_0 unsafe.Pointer - -func _swig_NewDirectorAA__SWIG_0(_swig_director *_swig_DirectorA, _ Std_complex_Sl_int_Sg_, _ float64) (_swig_ret SwigcptrA) { - _swig_p := uintptr(unsafe.Pointer(&_swig_director)) - _cgo_runtime_cgocall(_wrap__swig_NewDirectorAA__SWIG_0, _swig_p) - return -} - -func NewDirectorA__SWIG_0(v interface{}, arg1 Std_complex_Sl_int_Sg_, arg2 float64) A { - p := &_swig_DirectorA{0, v} - p.SwigcptrA = _swig_NewDirectorAA__SWIG_0(p, arg1, arg2) - return p -} - -var _wrap__swig_NewDirectorAA__SWIG_1 unsafe.Pointer - -func _swig_NewDirectorAA__SWIG_1(_swig_director *_swig_DirectorA, _ Std_complex_Sl_int_Sg_) (_swig_ret SwigcptrA) { - _swig_p := uintptr(unsafe.Pointer(&_swig_director)) - _cgo_runtime_cgocall(_wrap__swig_NewDirectorAA__SWIG_1, _swig_p) - return -} - -func NewDirectorA__SWIG_1(v interface{}, arg1 Std_complex_Sl_int_Sg_) A { - p := &_swig_DirectorA{0, v} - p.SwigcptrA = _swig_NewDirectorAA__SWIG_1(p, arg1) - return p -} - -var _wrap__swig_NewDirectorAA__SWIG_2 unsafe.Pointer - -func _swig_NewDirectorAA__SWIG_2(_swig_director *_swig_DirectorA, _ int, _ bool) (_swig_ret SwigcptrA) { - _swig_p := uintptr(unsafe.Pointer(&_swig_director)) - _cgo_runtime_cgocall(_wrap__swig_NewDirectorAA__SWIG_2, _swig_p) - return -} - -func NewDirectorA__SWIG_2(v interface{}, arg1 int, arg2 bool) A { - p := &_swig_DirectorA{0, v} - p.SwigcptrA = _swig_NewDirectorAA__SWIG_2(p, arg1, arg2) - return p -} - -var _wrap__swig_NewDirectorAA__SWIG_3 unsafe.Pointer - -func _swig_NewDirectorAA__SWIG_3(_swig_director *_swig_DirectorA, _ int) (_swig_ret SwigcptrA) { - _swig_p := uintptr(unsafe.Pointer(&_swig_director)) - _cgo_runtime_cgocall(_wrap__swig_NewDirectorAA__SWIG_3, _swig_p) - return -} - -func NewDirectorA__SWIG_3(v interface{}, arg1 int) A { - p := &_swig_DirectorA{0, v} - p.SwigcptrA = _swig_NewDirectorAA__SWIG_3(p, arg1) - return p -} - -func NewDirectorA(abi interface{}, a ...interface{}) A { - argc := len(a) - if argc == 1 { - if _, ok := a[0].(Std_complex_Sl_int_Sg_); !ok { - goto check_1 - } - return NewDirectorA__SWIG_1(abi, a[0].(Std_complex_Sl_int_Sg_)) - } -check_1: - if argc == 1 { - return NewDirectorA__SWIG_3(abi, a[0].(int)) - } - if argc == 2 { - if _, ok := a[0].(Std_complex_Sl_int_Sg_); !ok { - goto check_3 - } - if _, ok := a[1].(float64); !ok { - goto check_3 - } - return NewDirectorA__SWIG_0(abi, a[0].(Std_complex_Sl_int_Sg_), a[1].(float64)) - } -check_3: - if argc == 2 { - return NewDirectorA__SWIG_2(abi, a[0].(int), a[1].(bool)) - } - panic("No match for overloaded function call") -} - -var _wrap_DeleteDirectorA unsafe.Pointer - -func _swig_wrap_DeleteDirectorA(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_DeleteDirectorA, _swig_p) - return -} - -func DeleteDirectorA(arg1 A) { - _swig_wrap_DeleteDirectorA(arg1.Swigcptr()) -} - -func Swiggo_DeleteDirector_A(p *_swig_DirectorA) { - p.SwigcptrA = 0 -} - -type _swig_DirectorInterfaceAF__SWIG_0 interface { - F__SWIG_0(int) int -} - -var _wrap__swig_DirectorA_upcall_F__SWIG_0 unsafe.Pointer - -func _swig_wrap__swig_DirectorA_upcall_F__SWIG_0(_swig_ptr SwigcptrA, _ int) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) - _cgo_runtime_cgocall(_wrap__swig_DirectorA_upcall_F__SWIG_0, _swig_p) - return -} - -func (swig_p *_swig_DirectorA) F__SWIG_0(i int) int { - if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceAF__SWIG_0); swig_ok { - return swig_g.F__SWIG_0(i) - } - var swig_r int - swig_r = _swig_wrap__swig_DirectorA_upcall_F__SWIG_0(swig_p.SwigcptrA, i) - return swig_r -} - -func DirectorAF__SWIG_0(p A, arg2 int) int { - var swig_r int - swig_r = _swig_wrap__swig_DirectorA_upcall_F__SWIG_0(p.(*_swig_DirectorA).SwigcptrA, arg2) - return swig_r -} - -func Swig_DirectorA_callback_f__SWIG_0(p *_swig_DirectorA, arg2 int) (swig_result int) { - var swig_r int - swig_r = p.F__SWIG_0(arg2) - return swig_r -} - -type _swig_DirectorInterfaceAF__SWIG_1 interface { - F__SWIG_1() int -} - -var _wrap__swig_DirectorA_upcall_F__SWIG_1 unsafe.Pointer - -func _swig_wrap__swig_DirectorA_upcall_F__SWIG_1(_swig_ptr SwigcptrA) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) - _cgo_runtime_cgocall(_wrap__swig_DirectorA_upcall_F__SWIG_1, _swig_p) - return -} - -func (swig_p *_swig_DirectorA) F__SWIG_1() int { - if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceAF__SWIG_1); swig_ok { - return swig_g.F__SWIG_1() - } - var swig_r int - swig_r = _swig_wrap__swig_DirectorA_upcall_F__SWIG_1(swig_p.SwigcptrA) - return swig_r -} - -func DirectorAF__SWIG_1(p A) int { - var swig_r int - swig_r = _swig_wrap__swig_DirectorA_upcall_F__SWIG_1(p.(*_swig_DirectorA).SwigcptrA) - return swig_r -} - -func Swig_DirectorA_callback_f__SWIG_1(p *_swig_DirectorA) (swig_result int) { - var swig_r int - swig_r = p.F__SWIG_1() - return swig_r -} - -func (p _swig_DirectorA) F(a ...interface{}) int { - argc := len(a) - if argc == 0 { - return p.F__SWIG_1() - } - if argc == 1 { - return p.F__SWIG_0(a[0].(int)) - } - panic("No match for overloaded function call") -} - -func DirectorAF(p *_swig_DirectorA, a ...interface{}) int { - argc := len(a) - if argc == 0 { - return DirectorAF__SWIG_1(p) - } - if argc == 1 { - return DirectorAF__SWIG_0(p, a[0].(int)) - } - panic("No match for overloaded function call") -} - -type _swig_DirectorInterfaceARg__SWIG_0 interface { - Rg__SWIG_0(int) int -} - -var _wrap__swig_DirectorA_upcall_Rg__SWIG_0 unsafe.Pointer - -func _swig_wrap__swig_DirectorA_upcall_Rg__SWIG_0(_swig_ptr SwigcptrA, _ int) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) - _cgo_runtime_cgocall(_wrap__swig_DirectorA_upcall_Rg__SWIG_0, _swig_p) - return -} - -func (swig_p *_swig_DirectorA) Rg__SWIG_0(i int) int { - if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceARg__SWIG_0); swig_ok { - return swig_g.Rg__SWIG_0(i) - } - var swig_r int - swig_r = _swig_wrap__swig_DirectorA_upcall_Rg__SWIG_0(swig_p.SwigcptrA, i) - return swig_r -} - -func DirectorARg__SWIG_0(p A, arg2 int) int { - var swig_r int - swig_r = _swig_wrap__swig_DirectorA_upcall_Rg__SWIG_0(p.(*_swig_DirectorA).SwigcptrA, arg2) - return swig_r -} - -func Swig_DirectorA_callback_rg__SWIG_0(p *_swig_DirectorA, arg2 int) (swig_result int) { - var swig_r int - swig_r = p.Rg__SWIG_0(arg2) - return swig_r -} - -type _swig_DirectorInterfaceARg__SWIG_1 interface { - Rg__SWIG_1() int -} - -var _wrap__swig_DirectorA_upcall_Rg__SWIG_1 unsafe.Pointer - -func _swig_wrap__swig_DirectorA_upcall_Rg__SWIG_1(_swig_ptr SwigcptrA) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) - _cgo_runtime_cgocall(_wrap__swig_DirectorA_upcall_Rg__SWIG_1, _swig_p) - return -} - -func (swig_p *_swig_DirectorA) Rg__SWIG_1() int { - if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceARg__SWIG_1); swig_ok { - return swig_g.Rg__SWIG_1() - } - var swig_r int - swig_r = _swig_wrap__swig_DirectorA_upcall_Rg__SWIG_1(swig_p.SwigcptrA) - return swig_r -} - -func DirectorARg__SWIG_1(p A) int { - var swig_r int - swig_r = _swig_wrap__swig_DirectorA_upcall_Rg__SWIG_1(p.(*_swig_DirectorA).SwigcptrA) - return swig_r -} - -func Swig_DirectorA_callback_rg__SWIG_1(p *_swig_DirectorA) (swig_result int) { - var swig_r int - swig_r = p.Rg__SWIG_1() - return swig_r -} - -func (p _swig_DirectorA) Rg(a ...interface{}) int { - argc := len(a) - if argc == 0 { - return p.Rg__SWIG_1() - } - if argc == 1 { - return p.Rg__SWIG_0(a[0].(int)) - } - panic("No match for overloaded function call") -} - -func DirectorARg(p *_swig_DirectorA, a ...interface{}) int { - argc := len(a) - if argc == 0 { - return DirectorARg__SWIG_1(p) - } - if argc == 1 { - return DirectorARg__SWIG_0(p, a[0].(int)) - } - panic("No match for overloaded function call") -} - -type SwigcptrA uintptr - -func (p SwigcptrA) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrA) SwigIsA() { -} - -func (p SwigcptrA) DirectorInterface() interface{} { - return nil -} - -var _wrap_new_A__SWIG_0 unsafe.Pointer - -func _swig_wrap_new_A__SWIG_0(base uintptr, _ float64) (_ SwigcptrA) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_A__SWIG_0, _swig_p) - return -} - -func NewA__SWIG_0(arg1 Std_complex_Sl_int_Sg_, arg2 float64) (_swig_ret A) { - return _swig_wrap_new_A__SWIG_0(arg1.Swigcptr(), arg2) -} - -var _wrap_new_A__SWIG_1 unsafe.Pointer - -func _swig_wrap_new_A__SWIG_1(base uintptr) (_ SwigcptrA) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_A__SWIG_1, _swig_p) - return -} - -func NewA__SWIG_1(arg1 Std_complex_Sl_int_Sg_) (_swig_ret A) { - return _swig_wrap_new_A__SWIG_1(arg1.Swigcptr()) -} - -var _wrap_new_A__SWIG_2 unsafe.Pointer - -func _swig_wrap_new_A__SWIG_2(base int, _ bool) (_ SwigcptrA) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_A__SWIG_2, _swig_p) - return -} - -func NewA__SWIG_2(arg1 int, arg2 bool) (_swig_ret A) { - return _swig_wrap_new_A__SWIG_2(arg1, arg2) -} - -var _wrap_new_A__SWIG_3 unsafe.Pointer - -func _swig_wrap_new_A__SWIG_3(base int) (_ SwigcptrA) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_A__SWIG_3, _swig_p) - return -} - -func NewA__SWIG_3(arg1 int) (_swig_ret A) { - return _swig_wrap_new_A__SWIG_3(arg1) -} - -func NewA(a ...interface{}) A { - argc := len(a) - if argc == 1 { - if _, ok := a[0].(Std_complex_Sl_int_Sg_); !ok { - goto check_1 - } - return NewA__SWIG_1(a[0].(Std_complex_Sl_int_Sg_)) - } -check_1: - if argc == 1 { - return NewA__SWIG_3(a[0].(int)) - } - if argc == 2 { - if _, ok := a[0].(Std_complex_Sl_int_Sg_); !ok { - goto check_3 - } - if _, ok := a[1].(float64); !ok { - goto check_3 - } - return NewA__SWIG_0(a[0].(Std_complex_Sl_int_Sg_), a[1].(float64)) - } -check_3: - if argc == 2 { - return NewA__SWIG_2(a[0].(int), a[1].(bool)) - } - panic("No match for overloaded function call") -} - -var _wrap_delete_A unsafe.Pointer - -func _swig_wrap_delete_A(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_A, _swig_p) - return -} - -func DeleteA(arg1 A) { - _swig_wrap_delete_A(arg1.Swigcptr()) -} - -var _wrap_A_f__SWIG_0 unsafe.Pointer - -func _swig_wrap_A_f__SWIG_0(base SwigcptrA, _ int) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_A_f__SWIG_0, _swig_p) - return -} - -func (arg1 SwigcptrA) F__SWIG_0(arg2 int) (_swig_ret int) { - return _swig_wrap_A_f__SWIG_0(arg1, arg2) -} - -var _wrap_A_f__SWIG_1 unsafe.Pointer - -func _swig_wrap_A_f__SWIG_1(base SwigcptrA) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_A_f__SWIG_1, _swig_p) - return -} - -func (arg1 SwigcptrA) F__SWIG_1() (_swig_ret int) { - return _swig_wrap_A_f__SWIG_1(arg1) -} - -func (p SwigcptrA) F(a ...interface{}) int { - argc := len(a) - if argc == 0 { - return p.F__SWIG_1() - } - if argc == 1 { - return p.F__SWIG_0(a[0].(int)) - } - panic("No match for overloaded function call") -} - -var _wrap_A_rg__SWIG_0 unsafe.Pointer - -func _swig_wrap_A_rg__SWIG_0(base SwigcptrA, _ int) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_A_rg__SWIG_0, _swig_p) - return -} - -func (arg1 SwigcptrA) Rg__SWIG_0(arg2 int) (_swig_ret int) { - return _swig_wrap_A_rg__SWIG_0(arg1, arg2) -} - -var _wrap_A_rg__SWIG_1 unsafe.Pointer - -func _swig_wrap_A_rg__SWIG_1(base SwigcptrA) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_A_rg__SWIG_1, _swig_p) - return -} - -func (arg1 SwigcptrA) Rg__SWIG_1() (_swig_ret int) { - return _swig_wrap_A_rg__SWIG_1(arg1) -} - -func (p SwigcptrA) Rg(a ...interface{}) int { - argc := len(a) - if argc == 0 { - return p.Rg__SWIG_1() - } - if argc == 1 { - return p.Rg__SWIG_0(a[0].(int)) - } - panic("No match for overloaded function call") -} - -type A interface { - Swigcptr() uintptr - SwigIsA() - DirectorInterface() interface{} - F(a ...interface{}) int - Rg(a ...interface{}) int -} - -type SwigcptrA1 uintptr - -func (p SwigcptrA1) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrA1) SwigIsA1() { -} - -var _wrap_new_A1__SWIG_0 unsafe.Pointer - -func _swig_wrap_new_A1__SWIG_0(base uintptr, _ float64) (_ SwigcptrA1) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_A1__SWIG_0, _swig_p) - return -} - -func NewA1__SWIG_0(arg1 Std_complex_Sl_int_Sg_, arg2 float64) (_swig_ret A1) { - return _swig_wrap_new_A1__SWIG_0(arg1.Swigcptr(), arg2) -} - -var _wrap_new_A1__SWIG_1 unsafe.Pointer - -func _swig_wrap_new_A1__SWIG_1(base uintptr) (_ SwigcptrA1) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_A1__SWIG_1, _swig_p) - return -} - -func NewA1__SWIG_1(arg1 Std_complex_Sl_int_Sg_) (_swig_ret A1) { - return _swig_wrap_new_A1__SWIG_1(arg1.Swigcptr()) -} - -var _wrap_new_A1__SWIG_2 unsafe.Pointer - -func _swig_wrap_new_A1__SWIG_2(base int, _ bool) (_ SwigcptrA1) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_A1__SWIG_2, _swig_p) - return -} - -func NewA1__SWIG_2(arg1 int, arg2 bool) (_swig_ret A1) { - return _swig_wrap_new_A1__SWIG_2(arg1, arg2) -} - -var _wrap_new_A1__SWIG_3 unsafe.Pointer - -func _swig_wrap_new_A1__SWIG_3(base int) (_ SwigcptrA1) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_A1__SWIG_3, _swig_p) - return -} - -func NewA1__SWIG_3(arg1 int) (_swig_ret A1) { - return _swig_wrap_new_A1__SWIG_3(arg1) -} - -func NewA1(a ...interface{}) A1 { - argc := len(a) - if argc == 1 { - if _, ok := a[0].(Std_complex_Sl_int_Sg_); !ok { - goto check_1 - } - return NewA1__SWIG_1(a[0].(Std_complex_Sl_int_Sg_)) - } -check_1: - if argc == 1 { - return NewA1__SWIG_3(a[0].(int)) - } - if argc == 2 { - if _, ok := a[0].(Std_complex_Sl_int_Sg_); !ok { - goto check_3 - } - if _, ok := a[1].(float64); !ok { - goto check_3 - } - return NewA1__SWIG_0(a[0].(Std_complex_Sl_int_Sg_), a[1].(float64)) - } -check_3: - if argc == 2 { - return NewA1__SWIG_2(a[0].(int), a[1].(bool)) - } - panic("No match for overloaded function call") -} - -var _wrap_A1_ff__SWIG_0 unsafe.Pointer - -func _swig_wrap_A1_ff__SWIG_0(base SwigcptrA1, _ int) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_A1_ff__SWIG_0, _swig_p) - return -} - -func (arg1 SwigcptrA1) Ff__SWIG_0(arg2 int) (_swig_ret int) { - return _swig_wrap_A1_ff__SWIG_0(arg1, arg2) -} - -var _wrap_A1_ff__SWIG_1 unsafe.Pointer - -func _swig_wrap_A1_ff__SWIG_1(base SwigcptrA1) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_A1_ff__SWIG_1, _swig_p) - return -} - -func (arg1 SwigcptrA1) Ff__SWIG_1() (_swig_ret int) { - return _swig_wrap_A1_ff__SWIG_1(arg1) -} - -func (p SwigcptrA1) Ff(a ...interface{}) int { - argc := len(a) - if argc == 0 { - return p.Ff__SWIG_1() - } - if argc == 1 { - return p.Ff__SWIG_0(a[0].(int)) - } - panic("No match for overloaded function call") -} - -var _wrap_delete_A1 unsafe.Pointer - -func _swig_wrap_delete_A1(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_A1, _swig_p) - return -} - -func DeleteA1(arg1 A1) { - _swig_wrap_delete_A1(arg1.Swigcptr()) -} - -var _wrap_A1_f__SWIG_0 unsafe.Pointer - -func _swig_wrap_A1_f__SWIG_0(base SwigcptrA1, _ int) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_A1_f__SWIG_0, _swig_p) - return -} - -func (_swig_base SwigcptrA1) F__SWIG_0(arg1 int) (_swig_ret int) { - return _swig_wrap_A1_f__SWIG_0(_swig_base, arg1) -} - -var _wrap_A1_f__SWIG_1 unsafe.Pointer - -func _swig_wrap_A1_f__SWIG_1(base SwigcptrA1) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_A1_f__SWIG_1, _swig_p) - return -} - -func (_swig_base SwigcptrA1) F__SWIG_1() (_swig_ret int) { - return _swig_wrap_A1_f__SWIG_1(_swig_base) -} - -func (p SwigcptrA1) F(a ...interface{}) int { - argc := len(a) - if argc == 0 { - return p.F__SWIG_1() - } - if argc == 1 { - return p.F__SWIG_0(a[0].(int)) - } - panic("No match for overloaded function call") -} - -var _wrap_A1_rg__SWIG_0 unsafe.Pointer - -func _swig_wrap_A1_rg__SWIG_0(base SwigcptrA1, _ int) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_A1_rg__SWIG_0, _swig_p) - return -} - -func (_swig_base SwigcptrA1) Rg__SWIG_0(arg1 int) (_swig_ret int) { - return _swig_wrap_A1_rg__SWIG_0(_swig_base, arg1) -} - -var _wrap_A1_rg__SWIG_1 unsafe.Pointer - -func _swig_wrap_A1_rg__SWIG_1(base SwigcptrA1) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_A1_rg__SWIG_1, _swig_p) - return -} - -func (_swig_base SwigcptrA1) Rg__SWIG_1() (_swig_ret int) { - return _swig_wrap_A1_rg__SWIG_1(_swig_base) -} - -func (p SwigcptrA1) Rg(a ...interface{}) int { - argc := len(a) - if argc == 0 { - return p.Rg__SWIG_1() - } - if argc == 1 { - return p.Rg__SWIG_0(a[0].(int)) - } - panic("No match for overloaded function call") -} - -func (p SwigcptrA1) SwigIsA() { -} - -func (p SwigcptrA1) SwigGetA() A { - return SwigcptrA(p.Swigcptr()) -} - -type A1 interface { - Swigcptr() uintptr - SwigIsA1() - Ff(a ...interface{}) int - F(a ...interface{}) int - Rg(a ...interface{}) int - SwigIsA() - SwigGetA() A -} - -type SwigcptrBar uintptr - -func (p SwigcptrBar) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrBar) SwigIsBar() { -} - -var _wrap_Bar_x_set unsafe.Pointer - -func _swig_wrap_Bar_x_set(base SwigcptrBar, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Bar_x_set, _swig_p) - return -} - -func (arg1 SwigcptrBar) SetX(arg2 int) { - _swig_wrap_Bar_x_set(arg1, arg2) -} - -var _wrap_Bar_x_get unsafe.Pointer - -func _swig_wrap_Bar_x_get(base SwigcptrBar) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Bar_x_get, _swig_p) - return -} - -func (arg1 SwigcptrBar) GetX() (_swig_ret int) { - return _swig_wrap_Bar_x_get(arg1) -} - -var _wrap_new_Bar__SWIG_0 unsafe.Pointer - -func _swig_wrap_new_Bar__SWIG_0(base int) (_ SwigcptrBar) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Bar__SWIG_0, _swig_p) - return -} - -func NewBar__SWIG_0(arg1 int) (_swig_ret Bar) { - return _swig_wrap_new_Bar__SWIG_0(arg1) -} - -var _wrap_new_Bar__SWIG_1 unsafe.Pointer - -func _swig_wrap_new_Bar__SWIG_1() (base SwigcptrBar) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Bar__SWIG_1, _swig_p) - return -} - -func NewBar__SWIG_1() (_swig_ret Bar) { - return _swig_wrap_new_Bar__SWIG_1() -} - -func NewBar(a ...interface{}) Bar { - argc := len(a) - if argc == 0 { - return NewBar__SWIG_1() - } - if argc == 1 { - return NewBar__SWIG_0(a[0].(int)) - } - panic("No match for overloaded function call") -} - -var _wrap_delete_Bar unsafe.Pointer - -func _swig_wrap_delete_Bar(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Bar, _swig_p) - return -} - -func DeleteBar(arg1 Bar) { - _swig_wrap_delete_Bar(arg1.Swigcptr()) -} - -type Bar interface { - Swigcptr() uintptr - SwigIsBar() - SetX(arg2 int) - GetX() (_swig_ret int) -} - -type _swig_DirectorMyClass struct { - SwigcptrMyClass - v interface{} -} - -func (p *_swig_DirectorMyClass) Swigcptr() uintptr { - return p.SwigcptrMyClass.Swigcptr() -} - -func (p *_swig_DirectorMyClass) SwigIsMyClass() { -} - -func (p *_swig_DirectorMyClass) DirectorInterface() interface{} { - return p.v -} - -var _wrap__swig_NewDirectorMyClassMyClass__SWIG_0 unsafe.Pointer - -func _swig_NewDirectorMyClassMyClass__SWIG_0(_swig_director *_swig_DirectorMyClass, _ int) (_swig_ret SwigcptrMyClass) { - _swig_p := uintptr(unsafe.Pointer(&_swig_director)) - _cgo_runtime_cgocall(_wrap__swig_NewDirectorMyClassMyClass__SWIG_0, _swig_p) - return -} - -func NewDirectorMyClass__SWIG_0(v interface{}, arg1 int) MyClass { - p := &_swig_DirectorMyClass{0, v} - p.SwigcptrMyClass = _swig_NewDirectorMyClassMyClass__SWIG_0(p, arg1) - return p -} - -var _wrap__swig_NewDirectorMyClassMyClass__SWIG_1 unsafe.Pointer - -func _swig_NewDirectorMyClassMyClass__SWIG_1(_swig_director *_swig_DirectorMyClass) (_swig_ret SwigcptrMyClass) { - _swig_p := uintptr(unsafe.Pointer(&_swig_director)) - _cgo_runtime_cgocall(_wrap__swig_NewDirectorMyClassMyClass__SWIG_1, _swig_p) - return -} - -func NewDirectorMyClass__SWIG_1(v interface{}) MyClass { - p := &_swig_DirectorMyClass{0, v} - p.SwigcptrMyClass = _swig_NewDirectorMyClassMyClass__SWIG_1(p) - return p -} - -func NewDirectorMyClass(abi interface{}, a ...interface{}) MyClass { - argc := len(a) - if argc == 0 { - return NewDirectorMyClass__SWIG_1(abi) - } - if argc == 1 { - return NewDirectorMyClass__SWIG_0(abi, a[0].(int)) - } - panic("No match for overloaded function call") -} - -type _swig_DirectorInterfaceMyClassMethod interface { - Method(uintptr) -} - -var _wrap__swig_DirectorMyClass_upcall_Method unsafe.Pointer - -func _swig_wrap__swig_DirectorMyClass_upcall_Method(_swig_ptr SwigcptrMyClass, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) - _cgo_runtime_cgocall(_wrap__swig_DirectorMyClass_upcall_Method, _swig_p) - return -} - -func (swig_p *_swig_DirectorMyClass) Method(arg0 uintptr) { - if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceMyClassMethod); swig_ok { - swig_g.Method(arg0) - return - } - _swig_wrap__swig_DirectorMyClass_upcall_Method(swig_p.SwigcptrMyClass, arg0) -} - -func DirectorMyClassMethod(p MyClass, arg2 uintptr) { - _swig_wrap__swig_DirectorMyClass_upcall_Method(p.(*_swig_DirectorMyClass).SwigcptrMyClass, arg2) -} - -func Swig_DirectorMyClass_callback_method(p *_swig_DirectorMyClass, arg2 uintptr) { - p.Method(arg2) -} - -var _wrap_DeleteDirectorMyClass unsafe.Pointer - -func _swig_wrap_DeleteDirectorMyClass(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_DeleteDirectorMyClass, _swig_p) - return -} - -func DeleteDirectorMyClass(arg1 MyClass) { - _swig_wrap_DeleteDirectorMyClass(arg1.Swigcptr()) -} - -func Swiggo_DeleteDirector_MyClass(p *_swig_DirectorMyClass) { - p.SwigcptrMyClass = 0 -} - -type _swig_DirectorInterfaceMyClassVmethod interface { - Vmethod(Bar) Bar -} - -var _wrap__swig_DirectorMyClass_upcall_Vmethod unsafe.Pointer - -func _swig_wrap__swig_DirectorMyClass_upcall_Vmethod(_swig_ptr SwigcptrMyClass, _ uintptr) (_swig_ret SwigcptrBar) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) - _cgo_runtime_cgocall(_wrap__swig_DirectorMyClass_upcall_Vmethod, _swig_p) - return -} - -func (swig_p *_swig_DirectorMyClass) Vmethod(b Bar) Bar { - if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceMyClassVmethod); swig_ok { - return swig_g.Vmethod(b) - } - var swig_r Bar - swig_r = _swig_wrap__swig_DirectorMyClass_upcall_Vmethod(swig_p.SwigcptrMyClass, b.Swigcptr()) - return swig_r -} - -func DirectorMyClassVmethod(p MyClass, arg2 Bar) Bar { - var swig_r Bar - swig_r = _swig_wrap__swig_DirectorMyClass_upcall_Vmethod(p.(*_swig_DirectorMyClass).SwigcptrMyClass, arg2.Swigcptr()) - return swig_r -} - -func Swig_DirectorMyClass_callback_vmethod(p *_swig_DirectorMyClass, arg2 uintptr) (swig_result SwigcptrBar) { - var swig_r SwigcptrBar - swig_r = SwigcptrBar(p.Vmethod(SwigcptrBar(arg2)).Swigcptr()) - return swig_r -} - -type _swig_DirectorInterfaceMyClassPmethod interface { - Pmethod(Bar) Bar -} - -var _wrap__swig_DirectorMyClass_upcall_Pmethod unsafe.Pointer - -func _swig_wrap__swig_DirectorMyClass_upcall_Pmethod(_swig_ptr SwigcptrMyClass, _ uintptr) (_swig_ret SwigcptrBar) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) - _cgo_runtime_cgocall(_wrap__swig_DirectorMyClass_upcall_Pmethod, _swig_p) - return -} - -func (swig_p *_swig_DirectorMyClass) Pmethod(b Bar) Bar { - if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceMyClassPmethod); swig_ok { - return swig_g.Pmethod(b) - } - var swig_r Bar - swig_r = _swig_wrap__swig_DirectorMyClass_upcall_Pmethod(swig_p.SwigcptrMyClass, b.Swigcptr()) - return swig_r -} - -func DirectorMyClassPmethod(p MyClass, arg2 Bar) Bar { - var swig_r Bar - swig_r = _swig_wrap__swig_DirectorMyClass_upcall_Pmethod(p.(*_swig_DirectorMyClass).SwigcptrMyClass, arg2.Swigcptr()) - return swig_r -} - -func Swig_DirectorMyClass_callback_pmethod(p *_swig_DirectorMyClass, arg2 uintptr) (swig_result SwigcptrBar) { - var swig_r SwigcptrBar - swig_r = SwigcptrBar(p.Pmethod(SwigcptrBar(arg2)).Swigcptr()) - return swig_r -} - -type SwigcptrMyClass uintptr - -func (p SwigcptrMyClass) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrMyClass) SwigIsMyClass() { -} - -func (p SwigcptrMyClass) DirectorInterface() interface{} { - return nil -} - -var _wrap_new_MyClass__SWIG_0 unsafe.Pointer - -func _swig_wrap_new_MyClass__SWIG_0(base int) (_ SwigcptrMyClass) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_MyClass__SWIG_0, _swig_p) - return -} - -func NewMyClass__SWIG_0(arg1 int) (_swig_ret MyClass) { - return _swig_wrap_new_MyClass__SWIG_0(arg1) -} - -var _wrap_new_MyClass__SWIG_1 unsafe.Pointer - -func _swig_wrap_new_MyClass__SWIG_1() (base SwigcptrMyClass) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_MyClass__SWIG_1, _swig_p) - return -} - -func NewMyClass__SWIG_1() (_swig_ret MyClass) { - return _swig_wrap_new_MyClass__SWIG_1() -} - -func NewMyClass(a ...interface{}) MyClass { - argc := len(a) - if argc == 0 { - return NewMyClass__SWIG_1() - } - if argc == 1 { - return NewMyClass__SWIG_0(a[0].(int)) - } - panic("No match for overloaded function call") -} - -var _wrap_MyClass_method unsafe.Pointer - -func _swig_wrap_MyClass_method(base SwigcptrMyClass, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_MyClass_method, _swig_p) - return -} - -func (arg1 SwigcptrMyClass) Method(arg2 uintptr) { - _swig_wrap_MyClass_method(arg1, arg2) -} - -var _wrap_delete_MyClass unsafe.Pointer - -func _swig_wrap_delete_MyClass(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_MyClass, _swig_p) - return -} - -func DeleteMyClass(arg1 MyClass) { - _swig_wrap_delete_MyClass(arg1.Swigcptr()) -} - -var _wrap_MyClass_vmethod unsafe.Pointer - -func _swig_wrap_MyClass_vmethod(base SwigcptrMyClass, _ uintptr) (_ SwigcptrBar) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_MyClass_vmethod, _swig_p) - return -} - -func (arg1 SwigcptrMyClass) Vmethod(arg2 Bar) (_swig_ret Bar) { - return _swig_wrap_MyClass_vmethod(arg1, arg2.Swigcptr()) -} - -var _wrap_MyClass_pmethod unsafe.Pointer - -func _swig_wrap_MyClass_pmethod(base SwigcptrMyClass, _ uintptr) (_ SwigcptrBar) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_MyClass_pmethod, _swig_p) - return -} - -func (arg1 SwigcptrMyClass) Pmethod(arg2 Bar) (_swig_ret Bar) { - return _swig_wrap_MyClass_pmethod(arg1, arg2.Swigcptr()) -} - -var _wrap_MyClass_cmethod unsafe.Pointer - -func _swig_wrap_MyClass_cmethod(base SwigcptrMyClass, _ uintptr) (_ SwigcptrBar) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_MyClass_cmethod, _swig_p) - return -} - -func (arg1 SwigcptrMyClass) Cmethod(arg2 Bar) (_swig_ret Bar) { - return _swig_wrap_MyClass_cmethod(arg1, arg2.Swigcptr()) -} - -var _wrap_MyClass_get_self unsafe.Pointer - -func _swig_wrap_MyClass_get_self(base uintptr) (_ SwigcptrMyClass) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_MyClass_get_self, _swig_p) - return -} - -func MyClassGet_self(arg1 MyClass) (_swig_ret MyClass) { - return _swig_wrap_MyClass_get_self(arg1.Swigcptr()) -} - -var _wrap_MyClass_call_pmethod unsafe.Pointer - -func _swig_wrap_MyClass_call_pmethod(base uintptr, _ uintptr) (_ SwigcptrBar) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_MyClass_call_pmethod, _swig_p) - return -} - -func MyClassCall_pmethod(arg1 MyClass, arg2 Bar) (_swig_ret Bar) { - return _swig_wrap_MyClass_call_pmethod(arg1.Swigcptr(), arg2.Swigcptr()) -} - -type MyClass interface { - Swigcptr() uintptr - SwigIsMyClass() - DirectorInterface() interface{} - Method(arg2 uintptr) - Vmethod(arg2 Bar) (_swig_ret Bar) - Pmethod(arg2 Bar) (_swig_ret Bar) - Cmethod(arg2 Bar) (_swig_ret Bar) -} - -type SwigcptrMyClassT_i uintptr - -func (p SwigcptrMyClassT_i) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrMyClassT_i) SwigIsMyClassT_i() { -} - -var _wrap_new_MyClassT_i__SWIG_0 unsafe.Pointer - -func _swig_wrap_new_MyClassT_i__SWIG_0(base int) (_ SwigcptrMyClassT_i) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_MyClassT_i__SWIG_0, _swig_p) - return -} - -func NewMyClassT_i__SWIG_0(arg1 int) (_swig_ret MyClassT_i) { - return _swig_wrap_new_MyClassT_i__SWIG_0(arg1) -} - -var _wrap_new_MyClassT_i__SWIG_1 unsafe.Pointer - -func _swig_wrap_new_MyClassT_i__SWIG_1() (base SwigcptrMyClassT_i) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_MyClassT_i__SWIG_1, _swig_p) - return -} - -func NewMyClassT_i__SWIG_1() (_swig_ret MyClassT_i) { - return _swig_wrap_new_MyClassT_i__SWIG_1() -} - -func NewMyClassT_i(a ...interface{}) MyClassT_i { - argc := len(a) - if argc == 0 { - return NewMyClassT_i__SWIG_1() - } - if argc == 1 { - return NewMyClassT_i__SWIG_0(a[0].(int)) - } - panic("No match for overloaded function call") -} - -var _wrap_MyClassT_i_method unsafe.Pointer - -func _swig_wrap_MyClassT_i_method(base SwigcptrMyClassT_i, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_MyClassT_i_method, _swig_p) - return -} - -func (arg1 SwigcptrMyClassT_i) Method(arg2 uintptr) { - _swig_wrap_MyClassT_i_method(arg1, arg2) -} - -var _wrap_delete_MyClassT_i unsafe.Pointer - -func _swig_wrap_delete_MyClassT_i(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_MyClassT_i, _swig_p) - return -} - -func DeleteMyClassT_i(arg1 MyClassT_i) { - _swig_wrap_delete_MyClassT_i(arg1.Swigcptr()) -} - -type MyClassT_i interface { - Swigcptr() uintptr - SwigIsMyClassT_i() - Method(arg2 uintptr) -} - - -type SwigcptrSwigDirector_A uintptr -type SwigDirector_A interface { - Swigcptr() uintptr; -} -func (p SwigcptrSwigDirector_A) Swigcptr() uintptr { - return uintptr(p) -} - -type SwigcptrSwigDirector_Foo uintptr -type SwigDirector_Foo interface { - Swigcptr() uintptr; -} -func (p SwigcptrSwigDirector_Foo) Swigcptr() uintptr { - return uintptr(p) -} - -type SwigcptrStd_complex_Sl_int_Sg_ uintptr -type Std_complex_Sl_int_Sg_ interface { - Swigcptr() uintptr; -} -func (p SwigcptrStd_complex_Sl_int_Sg_) Swigcptr() uintptr { - return uintptr(p) -} - -type SwigcptrSwigDirector_MyClass uintptr -type SwigDirector_MyClass interface { - Swigcptr() uintptr; -} -func (p SwigcptrSwigDirector_MyClass) Swigcptr() uintptr { - return uintptr(p) -} - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/director_basic_runme b/Examples/test-suite/go/director_basic_runme deleted file mode 100755 index 3cdbb7478..000000000 Binary files a/Examples/test-suite/go/director_basic_runme and /dev/null differ diff --git a/Examples/test-suite/go/director_basic_wrap.h b/Examples/test-suite/go/director_basic_wrap.h deleted file mode 100644 index 6647a7ed7..000000000 --- a/Examples/test-suite/go/director_basic_wrap.h +++ /dev/null @@ -1,83 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../director_basic.i - -#ifndef SWIG_director_basic_WRAP_H_ -#define SWIG_director_basic_WRAP_H_ - -class SwigDirector_Foo : public Foo -{ - public: - SwigDirector_Foo(void *swig_p); - virtual ~SwigDirector_Foo(); - std::string _swig_upcall_ping() { - return Foo::ping(); - } - virtual std::string ping(); - std::string _swig_upcall_pong() { - return Foo::pong(); - } - virtual std::string pong(); - private: - void *go_val; -}; - -class SwigDirector_A : public A -{ - public: - SwigDirector_A(void *swig_p, std::complex< int > i, double d); - SwigDirector_A(void *swig_p, std::complex< int > i); - SwigDirector_A(void *swig_p, int i, bool j); - SwigDirector_A(void *swig_p, int i); - virtual ~SwigDirector_A(); - int _swig_upcall_f__SWIG_0(int i) { - return A::f(i); - } - virtual int f(int i); - int _swig_upcall_f__SWIG_1() { - return A::f(); - } - virtual int f(); - int _swig_upcall_rg__SWIG_0(int i) { - return A::gg(i); - } - virtual int gg(int i); - int _swig_upcall_rg__SWIG_1() { - return A::gg(); - } - virtual int gg(); - private: - void *go_val; -}; - -class SwigDirector_MyClass : public MyClass -{ - public: - SwigDirector_MyClass(void *swig_p, int a); - SwigDirector_MyClass(void *swig_p); - void _swig_upcall_method(VoidType *arg0) { - MyClass::method(arg0); - } - virtual void method(VoidType *arg0); - virtual ~SwigDirector_MyClass(); - Bar _swig_upcall_vmethod(Bar b) { - return MyClass::vmethod(b); - } - virtual Bar vmethod(Bar b); - Bar *_swig_upcall_pmethod(Bar *b) { - return MyClass::pmethod(b); - } - virtual Bar *pmethod(Bar *b); - private: - void *go_val; -}; - -#endif diff --git a/Examples/test-suite/go/director_binary_string.go b/Examples/test-suite/go/director_binary_string.go deleted file mode 100644 index 131f66147..000000000 --- a/Examples/test-suite/go/director_binary_string.go +++ /dev/null @@ -1,267 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../director_binary_string.i - -package director_binary_string - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -const BUFFER_SIZE_AA int = 8 -const BUFFER_SIZE_BB int = 5 -type _swig_DirectorCallback struct { - SwigcptrCallback - v interface{} -} - -func (p *_swig_DirectorCallback) Swigcptr() uintptr { - return p.SwigcptrCallback.Swigcptr() -} - -func (p *_swig_DirectorCallback) SwigIsCallback() { -} - -func (p *_swig_DirectorCallback) DirectorInterface() interface{} { - return p.v -} - -var _wrap__swig_NewDirectorCallbackCallback unsafe.Pointer - -func _swig_NewDirectorCallbackCallback(_swig_director *_swig_DirectorCallback) (_swig_ret SwigcptrCallback) { - _swig_p := uintptr(unsafe.Pointer(&_swig_director)) - _cgo_runtime_cgocall(_wrap__swig_NewDirectorCallbackCallback, _swig_p) - return -} - -func NewDirectorCallback(v interface{}) Callback { - p := &_swig_DirectorCallback{0, v} - p.SwigcptrCallback = _swig_NewDirectorCallbackCallback(p) - return p -} - -var _wrap_DeleteDirectorCallback unsafe.Pointer - -func _swig_wrap_DeleteDirectorCallback(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_DeleteDirectorCallback, _swig_p) - return -} - -func DeleteDirectorCallback(arg1 Callback) { - _swig_wrap_DeleteDirectorCallback(arg1.Swigcptr()) -} - -func Swiggo_DeleteDirector_Callback(p *_swig_DirectorCallback) { - p.SwigcptrCallback = 0 -} - -type _swig_DirectorInterfaceCallbackRun interface { - Run(string, string) -} - -var _wrap__swig_DirectorCallback_upcall_Run unsafe.Pointer - -func _swig_wrap__swig_DirectorCallback_upcall_Run(_swig_ptr SwigcptrCallback, _ string, _ string) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) - _cgo_runtime_cgocall(_wrap__swig_DirectorCallback_upcall_Run, _swig_p) - return -} - -func (swig_p *_swig_DirectorCallback) Run(dataBufferAA string, dataBufferBB string) { - if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceCallbackRun); swig_ok { - swig_g.Run(dataBufferAA, dataBufferBB) - return - } - _swig_wrap__swig_DirectorCallback_upcall_Run(swig_p.SwigcptrCallback, dataBufferAA, dataBufferBB) -} - -func DirectorCallbackRun(p Callback, arg2 string, arg4 string) { - _swig_wrap__swig_DirectorCallback_upcall_Run(p.(*_swig_DirectorCallback).SwigcptrCallback, arg2, arg4) -} - -func Swig_DirectorCallback_callback_run(p *_swig_DirectorCallback, arg2 string, arg4 string) { - p.Run(arg2, arg4) -} - -type SwigcptrCallback uintptr - -func (p SwigcptrCallback) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrCallback) SwigIsCallback() { -} - -func (p SwigcptrCallback) DirectorInterface() interface{} { - return nil -} - -var _wrap_delete_Callback unsafe.Pointer - -func _swig_wrap_delete_Callback(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Callback, _swig_p) - return -} - -func DeleteCallback(arg1 Callback) { - _swig_wrap_delete_Callback(arg1.Swigcptr()) -} - -var _wrap_Callback_run unsafe.Pointer - -func _swig_wrap_Callback_run(base SwigcptrCallback, _ string, _ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Callback_run, _swig_p) - return -} - -func (arg1 SwigcptrCallback) Run(arg2 string, arg3 string) { - _swig_wrap_Callback_run(arg1, arg2, arg3) -} - -var _wrap_new_Callback unsafe.Pointer - -func _swig_wrap_new_Callback() (base SwigcptrCallback) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Callback, _swig_p) - return -} - -func NewCallback() (_swig_ret Callback) { - return _swig_wrap_new_Callback() -} - -type Callback interface { - Swigcptr() uintptr - SwigIsCallback() - DirectorInterface() interface{} - Run(arg2 string, arg3 string) -} - -type SwigcptrCaller uintptr - -func (p SwigcptrCaller) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrCaller) SwigIsCaller() { -} - -var _wrap_new_Caller unsafe.Pointer - -func _swig_wrap_new_Caller() (base SwigcptrCaller) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Caller, _swig_p) - return -} - -func NewCaller() (_swig_ret Caller) { - return _swig_wrap_new_Caller() -} - -var _wrap_delete_Caller unsafe.Pointer - -func _swig_wrap_delete_Caller(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Caller, _swig_p) - return -} - -func DeleteCaller(arg1 Caller) { - _swig_wrap_delete_Caller(arg1.Swigcptr()) -} - -var _wrap_Caller_delCallback unsafe.Pointer - -func _swig_wrap_Caller_delCallback(base SwigcptrCaller) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Caller_delCallback, _swig_p) - return -} - -func (arg1 SwigcptrCaller) DelCallback() { - _swig_wrap_Caller_delCallback(arg1) -} - -var _wrap_Caller_setCallback unsafe.Pointer - -func _swig_wrap_Caller_setCallback(base SwigcptrCaller, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Caller_setCallback, _swig_p) - return -} - -func (arg1 SwigcptrCaller) SetCallback(arg2 Callback) { - _swig_wrap_Caller_setCallback(arg1, arg2.Swigcptr()) -} - -var _wrap_Caller_call unsafe.Pointer - -func _swig_wrap_Caller_call(base SwigcptrCaller) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Caller_call, _swig_p) - return -} - -func (arg1 SwigcptrCaller) Call() (_swig_ret int) { - return _swig_wrap_Caller_call(arg1) -} - -var _wrap_Caller_call_null unsafe.Pointer - -func _swig_wrap_Caller_call_null(base SwigcptrCaller) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Caller_call_null, _swig_p) - return -} - -func (arg1 SwigcptrCaller) Call_null() { - _swig_wrap_Caller_call_null(arg1) -} - -type Caller interface { - Swigcptr() uintptr - SwigIsCaller() - DelCallback() - SetCallback(arg2 Callback) - Call() (_swig_ret int) - Call_null() -} - - -type SwigcptrSwigDirector_Callback uintptr -type SwigDirector_Callback interface { - Swigcptr() uintptr; -} -func (p SwigcptrSwigDirector_Callback) Swigcptr() uintptr { - return uintptr(p) -} - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/director_binary_string_wrap.h b/Examples/test-suite/go/director_binary_string_wrap.h deleted file mode 100644 index 0607ede41..000000000 --- a/Examples/test-suite/go/director_binary_string_wrap.h +++ /dev/null @@ -1,29 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../director_binary_string.i - -#ifndef SWIG_director_binary_string_WRAP_H_ -#define SWIG_director_binary_string_WRAP_H_ - -class SwigDirector_Callback : public Callback -{ - public: - SwigDirector_Callback(void *swig_p); - virtual ~SwigDirector_Callback(); - void _swig_upcall_run(char *dataBufferAA, int sizeAA, char *dataBufferBB, int sizeBB) { - Callback::run(dataBufferAA,sizeAA,dataBufferBB,sizeBB); - } - virtual void run(char *dataBufferAA, int sizeAA, char *dataBufferBB, int sizeBB); - private: - void *go_val; -}; - -#endif diff --git a/Examples/test-suite/go/director_classes.go b/Examples/test-suite/go/director_classes.go deleted file mode 100644 index 8991fdc73..000000000 --- a/Examples/test-suite/go/director_classes.go +++ /dev/null @@ -1,1871 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../director_classes.i - -package director_classes - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -var _wrap_PrintDebug_set unsafe.Pointer - -func _swig_wrap_PrintDebug_set(base bool) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_PrintDebug_set, _swig_p) - return -} - -func SetPrintDebug(arg1 bool) { - _swig_wrap_PrintDebug_set(arg1) -} - -var _wrap_PrintDebug_get unsafe.Pointer - -func GetPrintDebug() (_swig_ret bool) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_PrintDebug_get, _swig_p) - return -} -type SwigcptrDoubleHolder uintptr - -func (p SwigcptrDoubleHolder) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrDoubleHolder) SwigIsDoubleHolder() { -} - -var _wrap_new_DoubleHolder__SWIG_0 unsafe.Pointer - -func _swig_wrap_new_DoubleHolder__SWIG_0(base float64) (_ SwigcptrDoubleHolder) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_DoubleHolder__SWIG_0, _swig_p) - return -} - -func NewDoubleHolder__SWIG_0(arg1 float64) (_swig_ret DoubleHolder) { - return _swig_wrap_new_DoubleHolder__SWIG_0(arg1) -} - -var _wrap_new_DoubleHolder__SWIG_1 unsafe.Pointer - -func _swig_wrap_new_DoubleHolder__SWIG_1() (base SwigcptrDoubleHolder) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_DoubleHolder__SWIG_1, _swig_p) - return -} - -func NewDoubleHolder__SWIG_1() (_swig_ret DoubleHolder) { - return _swig_wrap_new_DoubleHolder__SWIG_1() -} - -func NewDoubleHolder(a ...interface{}) DoubleHolder { - argc := len(a) - if argc == 0 { - return NewDoubleHolder__SWIG_1() - } - if argc == 1 { - return NewDoubleHolder__SWIG_0(a[0].(float64)) - } - panic("No match for overloaded function call") -} - -var _wrap_DoubleHolder_val_set unsafe.Pointer - -func _swig_wrap_DoubleHolder_val_set(base SwigcptrDoubleHolder, _ float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_DoubleHolder_val_set, _swig_p) - return -} - -func (arg1 SwigcptrDoubleHolder) SetVal(arg2 float64) { - _swig_wrap_DoubleHolder_val_set(arg1, arg2) -} - -var _wrap_DoubleHolder_val_get unsafe.Pointer - -func _swig_wrap_DoubleHolder_val_get(base SwigcptrDoubleHolder) (_ float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_DoubleHolder_val_get, _swig_p) - return -} - -func (arg1 SwigcptrDoubleHolder) GetVal() (_swig_ret float64) { - return _swig_wrap_DoubleHolder_val_get(arg1) -} - -var _wrap_delete_DoubleHolder unsafe.Pointer - -func _swig_wrap_delete_DoubleHolder(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_DoubleHolder, _swig_p) - return -} - -func DeleteDoubleHolder(arg1 DoubleHolder) { - _swig_wrap_delete_DoubleHolder(arg1.Swigcptr()) -} - -type DoubleHolder interface { - Swigcptr() uintptr - SwigIsDoubleHolder() - SetVal(arg2 float64) - GetVal() (_swig_ret float64) -} - -type _swig_DirectorBase struct { - SwigcptrBase - v interface{} -} - -func (p *_swig_DirectorBase) Swigcptr() uintptr { - return p.SwigcptrBase.Swigcptr() -} - -func (p *_swig_DirectorBase) SwigIsBase() { -} - -func (p *_swig_DirectorBase) DirectorInterface() interface{} { - return p.v -} - -var _wrap__swig_NewDirectorBaseBase unsafe.Pointer - -func _swig_NewDirectorBaseBase(_swig_director *_swig_DirectorBase, _ float64) (_swig_ret SwigcptrBase) { - _swig_p := uintptr(unsafe.Pointer(&_swig_director)) - _cgo_runtime_cgocall(_wrap__swig_NewDirectorBaseBase, _swig_p) - return -} - -func NewDirectorBase(v interface{}, arg1 float64) Base { - p := &_swig_DirectorBase{0, v} - p.SwigcptrBase = _swig_NewDirectorBaseBase(p, arg1) - return p -} - -var _wrap_DeleteDirectorBase unsafe.Pointer - -func _swig_wrap_DeleteDirectorBase(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_DeleteDirectorBase, _swig_p) - return -} - -func DeleteDirectorBase(arg1 Base) { - _swig_wrap_DeleteDirectorBase(arg1.Swigcptr()) -} - -func Swiggo_DeleteDirector_Base(p *_swig_DirectorBase) { - p.SwigcptrBase = 0 -} - -type _swig_DirectorInterfaceBaseVal interface { - Val(DoubleHolder) DoubleHolder -} - -var _wrap__swig_DirectorBase_upcall_Val unsafe.Pointer - -func _swig_wrap__swig_DirectorBase_upcall_Val(_swig_ptr SwigcptrBase, _ uintptr) (_swig_ret SwigcptrDoubleHolder) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) - _cgo_runtime_cgocall(_wrap__swig_DirectorBase_upcall_Val, _swig_p) - return -} - -func (swig_p *_swig_DirectorBase) Val(x DoubleHolder) DoubleHolder { - if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceBaseVal); swig_ok { - return swig_g.Val(x) - } - var swig_r DoubleHolder - swig_r = _swig_wrap__swig_DirectorBase_upcall_Val(swig_p.SwigcptrBase, x.Swigcptr()) - return swig_r -} - -func DirectorBaseVal(p Base, arg2 DoubleHolder) DoubleHolder { - var swig_r DoubleHolder - swig_r = _swig_wrap__swig_DirectorBase_upcall_Val(p.(*_swig_DirectorBase).SwigcptrBase, arg2.Swigcptr()) - return swig_r -} - -func Swig_DirectorBase_callback_Val(p *_swig_DirectorBase, arg2 uintptr) (swig_result SwigcptrDoubleHolder) { - var swig_r SwigcptrDoubleHolder - swig_r = SwigcptrDoubleHolder(p.Val(SwigcptrDoubleHolder(arg2)).Swigcptr()) - return swig_r -} - -type _swig_DirectorInterfaceBaseRef interface { - Ref(DoubleHolder) DoubleHolder -} - -var _wrap__swig_DirectorBase_upcall_Ref unsafe.Pointer - -func _swig_wrap__swig_DirectorBase_upcall_Ref(_swig_ptr SwigcptrBase, _ uintptr) (_swig_ret SwigcptrDoubleHolder) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) - _cgo_runtime_cgocall(_wrap__swig_DirectorBase_upcall_Ref, _swig_p) - return -} - -func (swig_p *_swig_DirectorBase) Ref(x DoubleHolder) DoubleHolder { - if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceBaseRef); swig_ok { - return swig_g.Ref(x) - } - var swig_r DoubleHolder - swig_r = _swig_wrap__swig_DirectorBase_upcall_Ref(swig_p.SwigcptrBase, x.Swigcptr()) - return swig_r -} - -func DirectorBaseRef(p Base, arg2 DoubleHolder) DoubleHolder { - var swig_r DoubleHolder - swig_r = _swig_wrap__swig_DirectorBase_upcall_Ref(p.(*_swig_DirectorBase).SwigcptrBase, arg2.Swigcptr()) - return swig_r -} - -func Swig_DirectorBase_callback_Ref(p *_swig_DirectorBase, arg2 uintptr) (swig_result SwigcptrDoubleHolder) { - var swig_r SwigcptrDoubleHolder - swig_r = SwigcptrDoubleHolder(p.Ref(SwigcptrDoubleHolder(arg2)).Swigcptr()) - return swig_r -} - -type _swig_DirectorInterfaceBasePtr interface { - Ptr(DoubleHolder) DoubleHolder -} - -var _wrap__swig_DirectorBase_upcall_Ptr unsafe.Pointer - -func _swig_wrap__swig_DirectorBase_upcall_Ptr(_swig_ptr SwigcptrBase, _ uintptr) (_swig_ret SwigcptrDoubleHolder) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) - _cgo_runtime_cgocall(_wrap__swig_DirectorBase_upcall_Ptr, _swig_p) - return -} - -func (swig_p *_swig_DirectorBase) Ptr(x DoubleHolder) DoubleHolder { - if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceBasePtr); swig_ok { - return swig_g.Ptr(x) - } - var swig_r DoubleHolder - swig_r = _swig_wrap__swig_DirectorBase_upcall_Ptr(swig_p.SwigcptrBase, x.Swigcptr()) - return swig_r -} - -func DirectorBasePtr(p Base, arg2 DoubleHolder) DoubleHolder { - var swig_r DoubleHolder - swig_r = _swig_wrap__swig_DirectorBase_upcall_Ptr(p.(*_swig_DirectorBase).SwigcptrBase, arg2.Swigcptr()) - return swig_r -} - -func Swig_DirectorBase_callback_Ptr(p *_swig_DirectorBase, arg2 uintptr) (swig_result SwigcptrDoubleHolder) { - var swig_r SwigcptrDoubleHolder - swig_r = SwigcptrDoubleHolder(p.Ptr(SwigcptrDoubleHolder(arg2)).Swigcptr()) - return swig_r -} - -type _swig_DirectorInterfaceBaseFullyOverloaded__SWIG_0 interface { - FullyOverloaded__SWIG_0(int) string -} - -var _wrap__swig_DirectorBase_upcall_FullyOverloaded__SWIG_0 unsafe.Pointer - -func _swig_wrap__swig_DirectorBase_upcall_FullyOverloaded__SWIG_0(_swig_ptr SwigcptrBase, _ int) (_swig_ret string) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) - _cgo_runtime_cgocall(_wrap__swig_DirectorBase_upcall_FullyOverloaded__SWIG_0, _swig_p) - return -} - -func (swig_p *_swig_DirectorBase) FullyOverloaded__SWIG_0(x int) string { - if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceBaseFullyOverloaded__SWIG_0); swig_ok { - return swig_g.FullyOverloaded__SWIG_0(x) - } - var swig_r string - swig_r = _swig_wrap__swig_DirectorBase_upcall_FullyOverloaded__SWIG_0(swig_p.SwigcptrBase, x) - return swig_r -} - -func DirectorBaseFullyOverloaded__SWIG_0(p Base, arg2 int) string { - var swig_r string - swig_r = _swig_wrap__swig_DirectorBase_upcall_FullyOverloaded__SWIG_0(p.(*_swig_DirectorBase).SwigcptrBase, arg2) - return swig_r -} - -func Swig_DirectorBase_callback_FullyOverloaded__SWIG_0(p *_swig_DirectorBase, arg2 int) (swig_result string) { - var swig_r string - swig_r = p.FullyOverloaded__SWIG_0(arg2) - return swig_r -} - -type _swig_DirectorInterfaceBaseFullyOverloaded__SWIG_1 interface { - FullyOverloaded__SWIG_1(bool) string -} - -var _wrap__swig_DirectorBase_upcall_FullyOverloaded__SWIG_1 unsafe.Pointer - -func _swig_wrap__swig_DirectorBase_upcall_FullyOverloaded__SWIG_1(_swig_ptr SwigcptrBase, _ bool) (_swig_ret string) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) - _cgo_runtime_cgocall(_wrap__swig_DirectorBase_upcall_FullyOverloaded__SWIG_1, _swig_p) - return -} - -func (swig_p *_swig_DirectorBase) FullyOverloaded__SWIG_1(x bool) string { - if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceBaseFullyOverloaded__SWIG_1); swig_ok { - return swig_g.FullyOverloaded__SWIG_1(x) - } - var swig_r string - swig_r = _swig_wrap__swig_DirectorBase_upcall_FullyOverloaded__SWIG_1(swig_p.SwigcptrBase, x) - return swig_r -} - -func DirectorBaseFullyOverloaded__SWIG_1(p Base, arg2 bool) string { - var swig_r string - swig_r = _swig_wrap__swig_DirectorBase_upcall_FullyOverloaded__SWIG_1(p.(*_swig_DirectorBase).SwigcptrBase, arg2) - return swig_r -} - -func Swig_DirectorBase_callback_FullyOverloaded__SWIG_1(p *_swig_DirectorBase, arg2 bool) (swig_result string) { - var swig_r string - swig_r = p.FullyOverloaded__SWIG_1(arg2) - return swig_r -} - -func (p _swig_DirectorBase) FullyOverloaded(a ...interface{}) string { - argc := len(a) - if argc == 1 { - if _, ok := a[0].(bool); !ok { - goto check_1 - } - return p.FullyOverloaded__SWIG_1(a[0].(bool)) - } -check_1: - if argc == 1 { - return p.FullyOverloaded__SWIG_0(a[0].(int)) - } - panic("No match for overloaded function call") -} - -func DirectorBaseFullyOverloaded(p *_swig_DirectorBase, a ...interface{}) string { - argc := len(a) - if argc == 1 { - if _, ok := a[0].(bool); !ok { - goto check_1 - } - return DirectorBaseFullyOverloaded__SWIG_1(p, a[0].(bool)) - } -check_1: - if argc == 1 { - return DirectorBaseFullyOverloaded__SWIG_0(p, a[0].(int)) - } - panic("No match for overloaded function call") -} - -type _swig_DirectorInterfaceBaseSemiOverloaded__SWIG_0 interface { - SemiOverloaded__SWIG_0(int) string -} - -var _wrap__swig_DirectorBase_upcall_SemiOverloaded__SWIG_0 unsafe.Pointer - -func _swig_wrap__swig_DirectorBase_upcall_SemiOverloaded__SWIG_0(_swig_ptr SwigcptrBase, _ int) (_swig_ret string) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) - _cgo_runtime_cgocall(_wrap__swig_DirectorBase_upcall_SemiOverloaded__SWIG_0, _swig_p) - return -} - -func (swig_p *_swig_DirectorBase) SemiOverloaded__SWIG_0(x int) string { - if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceBaseSemiOverloaded__SWIG_0); swig_ok { - return swig_g.SemiOverloaded__SWIG_0(x) - } - var swig_r string - swig_r = _swig_wrap__swig_DirectorBase_upcall_SemiOverloaded__SWIG_0(swig_p.SwigcptrBase, x) - return swig_r -} - -func DirectorBaseSemiOverloaded__SWIG_0(p Base, arg2 int) string { - var swig_r string - swig_r = _swig_wrap__swig_DirectorBase_upcall_SemiOverloaded__SWIG_0(p.(*_swig_DirectorBase).SwigcptrBase, arg2) - return swig_r -} - -func Swig_DirectorBase_callback_SemiOverloaded__SWIG_0(p *_swig_DirectorBase, arg2 int) (swig_result string) { - var swig_r string - swig_r = p.SemiOverloaded__SWIG_0(arg2) - return swig_r -} - -type _swig_DirectorInterfaceBaseSemiOverloaded__SWIG_1 interface { - SemiOverloaded__SWIG_1(bool) string -} - -var _wrap__swig_DirectorBase_upcall_SemiOverloaded__SWIG_1 unsafe.Pointer - -func _swig_wrap__swig_DirectorBase_upcall_SemiOverloaded__SWIG_1(_swig_ptr SwigcptrBase, _ bool) (_swig_ret string) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) - _cgo_runtime_cgocall(_wrap__swig_DirectorBase_upcall_SemiOverloaded__SWIG_1, _swig_p) - return -} - -func (swig_p *_swig_DirectorBase) SemiOverloaded__SWIG_1(x bool) string { - if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceBaseSemiOverloaded__SWIG_1); swig_ok { - return swig_g.SemiOverloaded__SWIG_1(x) - } - var swig_r string - swig_r = _swig_wrap__swig_DirectorBase_upcall_SemiOverloaded__SWIG_1(swig_p.SwigcptrBase, x) - return swig_r -} - -func DirectorBaseSemiOverloaded__SWIG_1(p Base, arg2 bool) string { - var swig_r string - swig_r = _swig_wrap__swig_DirectorBase_upcall_SemiOverloaded__SWIG_1(p.(*_swig_DirectorBase).SwigcptrBase, arg2) - return swig_r -} - -func Swig_DirectorBase_callback_SemiOverloaded__SWIG_1(p *_swig_DirectorBase, arg2 bool) (swig_result string) { - var swig_r string - swig_r = p.SemiOverloaded__SWIG_1(arg2) - return swig_r -} - -func (p _swig_DirectorBase) SemiOverloaded(a ...interface{}) string { - argc := len(a) - if argc == 1 { - if _, ok := a[0].(bool); !ok { - goto check_1 - } - return p.SemiOverloaded__SWIG_1(a[0].(bool)) - } -check_1: - if argc == 1 { - return p.SemiOverloaded__SWIG_0(a[0].(int)) - } - panic("No match for overloaded function call") -} - -func DirectorBaseSemiOverloaded(p *_swig_DirectorBase, a ...interface{}) string { - argc := len(a) - if argc == 1 { - if _, ok := a[0].(bool); !ok { - goto check_1 - } - return DirectorBaseSemiOverloaded__SWIG_1(p, a[0].(bool)) - } -check_1: - if argc == 1 { - return DirectorBaseSemiOverloaded__SWIG_0(p, a[0].(int)) - } - panic("No match for overloaded function call") -} - -type _swig_DirectorInterfaceBaseDefaultParms__SWIG_0 interface { - DefaultParms__SWIG_0(int, float64) string -} - -var _wrap__swig_DirectorBase_upcall_DefaultParms__SWIG_0 unsafe.Pointer - -func _swig_wrap__swig_DirectorBase_upcall_DefaultParms__SWIG_0(_swig_ptr SwigcptrBase, _ int, _ float64) (_swig_ret string) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) - _cgo_runtime_cgocall(_wrap__swig_DirectorBase_upcall_DefaultParms__SWIG_0, _swig_p) - return -} - -func (swig_p *_swig_DirectorBase) DefaultParms__SWIG_0(x int, y float64) string { - if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceBaseDefaultParms__SWIG_0); swig_ok { - return swig_g.DefaultParms__SWIG_0(x, y) - } - var swig_r string - swig_r = _swig_wrap__swig_DirectorBase_upcall_DefaultParms__SWIG_0(swig_p.SwigcptrBase, x, y) - return swig_r -} - -func DirectorBaseDefaultParms__SWIG_0(p Base, arg2 int, arg3 float64) string { - var swig_r string - swig_r = _swig_wrap__swig_DirectorBase_upcall_DefaultParms__SWIG_0(p.(*_swig_DirectorBase).SwigcptrBase, arg2, arg3) - return swig_r -} - -func Swig_DirectorBase_callback_DefaultParms__SWIG_0(p *_swig_DirectorBase, arg2 int, arg3 float64) (swig_result string) { - var swig_r string - swig_r = p.DefaultParms__SWIG_0(arg2, arg3) - return swig_r -} - -type _swig_DirectorInterfaceBaseDefaultParms__SWIG_1 interface { - DefaultParms__SWIG_1(int) string -} - -var _wrap__swig_DirectorBase_upcall_DefaultParms__SWIG_1 unsafe.Pointer - -func _swig_wrap__swig_DirectorBase_upcall_DefaultParms__SWIG_1(_swig_ptr SwigcptrBase, _ int) (_swig_ret string) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) - _cgo_runtime_cgocall(_wrap__swig_DirectorBase_upcall_DefaultParms__SWIG_1, _swig_p) - return -} - -func (swig_p *_swig_DirectorBase) DefaultParms__SWIG_1(x int) string { - if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceBaseDefaultParms__SWIG_1); swig_ok { - return swig_g.DefaultParms__SWIG_1(x) - } - var swig_r string - swig_r = _swig_wrap__swig_DirectorBase_upcall_DefaultParms__SWIG_1(swig_p.SwigcptrBase, x) - return swig_r -} - -func DirectorBaseDefaultParms__SWIG_1(p Base, arg2 int) string { - var swig_r string - swig_r = _swig_wrap__swig_DirectorBase_upcall_DefaultParms__SWIG_1(p.(*_swig_DirectorBase).SwigcptrBase, arg2) - return swig_r -} - -func Swig_DirectorBase_callback_DefaultParms__SWIG_1(p *_swig_DirectorBase, arg2 int) (swig_result string) { - var swig_r string - swig_r = p.DefaultParms__SWIG_1(arg2) - return swig_r -} - -func (p _swig_DirectorBase) DefaultParms(a ...interface{}) string { - argc := len(a) - if argc == 1 { - return p.DefaultParms__SWIG_1(a[0].(int)) - } - if argc == 2 { - return p.DefaultParms__SWIG_0(a[0].(int), a[1].(float64)) - } - panic("No match for overloaded function call") -} - -func DirectorBaseDefaultParms(p *_swig_DirectorBase, a ...interface{}) string { - argc := len(a) - if argc == 1 { - return DirectorBaseDefaultParms__SWIG_1(p, a[0].(int)) - } - if argc == 2 { - return DirectorBaseDefaultParms__SWIG_0(p, a[0].(int), a[1].(float64)) - } - panic("No match for overloaded function call") -} - -type SwigcptrBase uintptr - -func (p SwigcptrBase) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrBase) SwigIsBase() { -} - -func (p SwigcptrBase) DirectorInterface() interface{} { - return nil -} - -var _wrap_new_Base unsafe.Pointer - -func _swig_wrap_new_Base(base float64) (_ SwigcptrBase) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Base, _swig_p) - return -} - -func NewBase(arg1 float64) (_swig_ret Base) { - return _swig_wrap_new_Base(arg1) -} - -var _wrap_delete_Base unsafe.Pointer - -func _swig_wrap_delete_Base(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Base, _swig_p) - return -} - -func DeleteBase(arg1 Base) { - _swig_wrap_delete_Base(arg1.Swigcptr()) -} - -var _wrap_Base_Val unsafe.Pointer - -func _swig_wrap_Base_Val(base SwigcptrBase, _ uintptr) (_ SwigcptrDoubleHolder) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Base_Val, _swig_p) - return -} - -func (arg1 SwigcptrBase) Val(arg2 DoubleHolder) (_swig_ret DoubleHolder) { - return _swig_wrap_Base_Val(arg1, arg2.Swigcptr()) -} - -var _wrap_Base_Ref unsafe.Pointer - -func _swig_wrap_Base_Ref(base SwigcptrBase, _ uintptr) (_ SwigcptrDoubleHolder) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Base_Ref, _swig_p) - return -} - -func (arg1 SwigcptrBase) Ref(arg2 DoubleHolder) (_swig_ret DoubleHolder) { - return _swig_wrap_Base_Ref(arg1, arg2.Swigcptr()) -} - -var _wrap_Base_Ptr unsafe.Pointer - -func _swig_wrap_Base_Ptr(base SwigcptrBase, _ uintptr) (_ SwigcptrDoubleHolder) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Base_Ptr, _swig_p) - return -} - -func (arg1 SwigcptrBase) Ptr(arg2 DoubleHolder) (_swig_ret DoubleHolder) { - return _swig_wrap_Base_Ptr(arg1, arg2.Swigcptr()) -} - -var _wrap_Base_FullyOverloaded__SWIG_0 unsafe.Pointer - -func _swig_wrap_Base_FullyOverloaded__SWIG_0(base SwigcptrBase, _ int) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Base_FullyOverloaded__SWIG_0, _swig_p) - return -} - -func (arg1 SwigcptrBase) FullyOverloaded__SWIG_0(arg2 int) (_swig_ret string) { - return _swig_wrap_Base_FullyOverloaded__SWIG_0(arg1, arg2) -} - -var _wrap_Base_FullyOverloaded__SWIG_1 unsafe.Pointer - -func _swig_wrap_Base_FullyOverloaded__SWIG_1(base SwigcptrBase, _ bool) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Base_FullyOverloaded__SWIG_1, _swig_p) - return -} - -func (arg1 SwigcptrBase) FullyOverloaded__SWIG_1(arg2 bool) (_swig_ret string) { - return _swig_wrap_Base_FullyOverloaded__SWIG_1(arg1, arg2) -} - -func (p SwigcptrBase) FullyOverloaded(a ...interface{}) string { - argc := len(a) - if argc == 1 { - if _, ok := a[0].(bool); !ok { - goto check_1 - } - return p.FullyOverloaded__SWIG_1(a[0].(bool)) - } -check_1: - if argc == 1 { - return p.FullyOverloaded__SWIG_0(a[0].(int)) - } - panic("No match for overloaded function call") -} - -var _wrap_Base_SemiOverloaded__SWIG_0 unsafe.Pointer - -func _swig_wrap_Base_SemiOverloaded__SWIG_0(base SwigcptrBase, _ int) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Base_SemiOverloaded__SWIG_0, _swig_p) - return -} - -func (arg1 SwigcptrBase) SemiOverloaded__SWIG_0(arg2 int) (_swig_ret string) { - return _swig_wrap_Base_SemiOverloaded__SWIG_0(arg1, arg2) -} - -var _wrap_Base_SemiOverloaded__SWIG_1 unsafe.Pointer - -func _swig_wrap_Base_SemiOverloaded__SWIG_1(base SwigcptrBase, _ bool) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Base_SemiOverloaded__SWIG_1, _swig_p) - return -} - -func (arg1 SwigcptrBase) SemiOverloaded__SWIG_1(arg2 bool) (_swig_ret string) { - return _swig_wrap_Base_SemiOverloaded__SWIG_1(arg1, arg2) -} - -func (p SwigcptrBase) SemiOverloaded(a ...interface{}) string { - argc := len(a) - if argc == 1 { - if _, ok := a[0].(bool); !ok { - goto check_1 - } - return p.SemiOverloaded__SWIG_1(a[0].(bool)) - } -check_1: - if argc == 1 { - return p.SemiOverloaded__SWIG_0(a[0].(int)) - } - panic("No match for overloaded function call") -} - -var _wrap_Base_DefaultParms__SWIG_0 unsafe.Pointer - -func _swig_wrap_Base_DefaultParms__SWIG_0(base SwigcptrBase, _ int, _ float64) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Base_DefaultParms__SWIG_0, _swig_p) - return -} - -func (arg1 SwigcptrBase) DefaultParms__SWIG_0(arg2 int, arg3 float64) (_swig_ret string) { - return _swig_wrap_Base_DefaultParms__SWIG_0(arg1, arg2, arg3) -} - -var _wrap_Base_DefaultParms__SWIG_1 unsafe.Pointer - -func _swig_wrap_Base_DefaultParms__SWIG_1(base SwigcptrBase, _ int) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Base_DefaultParms__SWIG_1, _swig_p) - return -} - -func (arg1 SwigcptrBase) DefaultParms__SWIG_1(arg2 int) (_swig_ret string) { - return _swig_wrap_Base_DefaultParms__SWIG_1(arg1, arg2) -} - -func (p SwigcptrBase) DefaultParms(a ...interface{}) string { - argc := len(a) - if argc == 1 { - return p.DefaultParms__SWIG_1(a[0].(int)) - } - if argc == 2 { - return p.DefaultParms__SWIG_0(a[0].(int), a[1].(float64)) - } - panic("No match for overloaded function call") -} - -type Base interface { - Swigcptr() uintptr - SwigIsBase() - DirectorInterface() interface{} - Val(arg2 DoubleHolder) (_swig_ret DoubleHolder) - Ref(arg2 DoubleHolder) (_swig_ret DoubleHolder) - Ptr(arg2 DoubleHolder) (_swig_ret DoubleHolder) - FullyOverloaded(a ...interface{}) string - SemiOverloaded(a ...interface{}) string - DefaultParms(a ...interface{}) string -} - -type _swig_DirectorDerived struct { - SwigcptrDerived - v interface{} -} - -func (p *_swig_DirectorDerived) Swigcptr() uintptr { - return p.SwigcptrDerived.Swigcptr() -} - -func (p *_swig_DirectorDerived) SwigIsDerived() { -} - -func (p *_swig_DirectorDerived) DirectorInterface() interface{} { - return p.v -} - -var _wrap__swig_NewDirectorDerivedDerived unsafe.Pointer - -func _swig_NewDirectorDerivedDerived(_swig_director *_swig_DirectorDerived, _ float64) (_swig_ret SwigcptrDerived) { - _swig_p := uintptr(unsafe.Pointer(&_swig_director)) - _cgo_runtime_cgocall(_wrap__swig_NewDirectorDerivedDerived, _swig_p) - return -} - -func NewDirectorDerived(v interface{}, arg1 float64) Derived { - p := &_swig_DirectorDerived{0, v} - p.SwigcptrDerived = _swig_NewDirectorDerivedDerived(p, arg1) - return p -} - -var _wrap_DeleteDirectorDerived unsafe.Pointer - -func _swig_wrap_DeleteDirectorDerived(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_DeleteDirectorDerived, _swig_p) - return -} - -func DeleteDirectorDerived(arg1 Derived) { - _swig_wrap_DeleteDirectorDerived(arg1.Swigcptr()) -} - -func Swiggo_DeleteDirector_Derived(p *_swig_DirectorDerived) { - p.SwigcptrDerived = 0 -} - -type _swig_DirectorInterfaceDerivedVal interface { - Val(DoubleHolder) DoubleHolder -} - -var _wrap__swig_DirectorDerived_upcall_Val unsafe.Pointer - -func _swig_wrap__swig_DirectorDerived_upcall_Val(_swig_ptr SwigcptrDerived, _ uintptr) (_swig_ret SwigcptrDoubleHolder) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) - _cgo_runtime_cgocall(_wrap__swig_DirectorDerived_upcall_Val, _swig_p) - return -} - -func (swig_p *_swig_DirectorDerived) Val(x DoubleHolder) DoubleHolder { - if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceDerivedVal); swig_ok { - return swig_g.Val(x) - } - var swig_r DoubleHolder - swig_r = _swig_wrap__swig_DirectorDerived_upcall_Val(swig_p.SwigcptrDerived, x.Swigcptr()) - return swig_r -} - -func DirectorDerivedVal(p Derived, arg2 DoubleHolder) DoubleHolder { - var swig_r DoubleHolder - swig_r = _swig_wrap__swig_DirectorDerived_upcall_Val(p.(*_swig_DirectorDerived).SwigcptrDerived, arg2.Swigcptr()) - return swig_r -} - -func Swig_DirectorDerived_callback_Val(p *_swig_DirectorDerived, arg2 uintptr) (swig_result SwigcptrDoubleHolder) { - var swig_r SwigcptrDoubleHolder - swig_r = SwigcptrDoubleHolder(p.Val(SwigcptrDoubleHolder(arg2)).Swigcptr()) - return swig_r -} - -type _swig_DirectorInterfaceDerivedRef interface { - Ref(DoubleHolder) DoubleHolder -} - -var _wrap__swig_DirectorDerived_upcall_Ref unsafe.Pointer - -func _swig_wrap__swig_DirectorDerived_upcall_Ref(_swig_ptr SwigcptrDerived, _ uintptr) (_swig_ret SwigcptrDoubleHolder) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) - _cgo_runtime_cgocall(_wrap__swig_DirectorDerived_upcall_Ref, _swig_p) - return -} - -func (swig_p *_swig_DirectorDerived) Ref(x DoubleHolder) DoubleHolder { - if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceDerivedRef); swig_ok { - return swig_g.Ref(x) - } - var swig_r DoubleHolder - swig_r = _swig_wrap__swig_DirectorDerived_upcall_Ref(swig_p.SwigcptrDerived, x.Swigcptr()) - return swig_r -} - -func DirectorDerivedRef(p Derived, arg2 DoubleHolder) DoubleHolder { - var swig_r DoubleHolder - swig_r = _swig_wrap__swig_DirectorDerived_upcall_Ref(p.(*_swig_DirectorDerived).SwigcptrDerived, arg2.Swigcptr()) - return swig_r -} - -func Swig_DirectorDerived_callback_Ref(p *_swig_DirectorDerived, arg2 uintptr) (swig_result SwigcptrDoubleHolder) { - var swig_r SwigcptrDoubleHolder - swig_r = SwigcptrDoubleHolder(p.Ref(SwigcptrDoubleHolder(arg2)).Swigcptr()) - return swig_r -} - -type _swig_DirectorInterfaceDerivedPtr interface { - Ptr(DoubleHolder) DoubleHolder -} - -var _wrap__swig_DirectorDerived_upcall_Ptr unsafe.Pointer - -func _swig_wrap__swig_DirectorDerived_upcall_Ptr(_swig_ptr SwigcptrDerived, _ uintptr) (_swig_ret SwigcptrDoubleHolder) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) - _cgo_runtime_cgocall(_wrap__swig_DirectorDerived_upcall_Ptr, _swig_p) - return -} - -func (swig_p *_swig_DirectorDerived) Ptr(x DoubleHolder) DoubleHolder { - if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceDerivedPtr); swig_ok { - return swig_g.Ptr(x) - } - var swig_r DoubleHolder - swig_r = _swig_wrap__swig_DirectorDerived_upcall_Ptr(swig_p.SwigcptrDerived, x.Swigcptr()) - return swig_r -} - -func DirectorDerivedPtr(p Derived, arg2 DoubleHolder) DoubleHolder { - var swig_r DoubleHolder - swig_r = _swig_wrap__swig_DirectorDerived_upcall_Ptr(p.(*_swig_DirectorDerived).SwigcptrDerived, arg2.Swigcptr()) - return swig_r -} - -func Swig_DirectorDerived_callback_Ptr(p *_swig_DirectorDerived, arg2 uintptr) (swig_result SwigcptrDoubleHolder) { - var swig_r SwigcptrDoubleHolder - swig_r = SwigcptrDoubleHolder(p.Ptr(SwigcptrDoubleHolder(arg2)).Swigcptr()) - return swig_r -} - -type _swig_DirectorInterfaceDerivedFullyOverloaded__SWIG_0 interface { - FullyOverloaded__SWIG_0(int) string -} - -var _wrap__swig_DirectorDerived_upcall_FullyOverloaded__SWIG_0 unsafe.Pointer - -func _swig_wrap__swig_DirectorDerived_upcall_FullyOverloaded__SWIG_0(_swig_ptr SwigcptrDerived, _ int) (_swig_ret string) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) - _cgo_runtime_cgocall(_wrap__swig_DirectorDerived_upcall_FullyOverloaded__SWIG_0, _swig_p) - return -} - -func (swig_p *_swig_DirectorDerived) FullyOverloaded__SWIG_0(x int) string { - if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceDerivedFullyOverloaded__SWIG_0); swig_ok { - return swig_g.FullyOverloaded__SWIG_0(x) - } - var swig_r string - swig_r = _swig_wrap__swig_DirectorDerived_upcall_FullyOverloaded__SWIG_0(swig_p.SwigcptrDerived, x) - return swig_r -} - -func DirectorDerivedFullyOverloaded__SWIG_0(p Derived, arg2 int) string { - var swig_r string - swig_r = _swig_wrap__swig_DirectorDerived_upcall_FullyOverloaded__SWIG_0(p.(*_swig_DirectorDerived).SwigcptrDerived, arg2) - return swig_r -} - -func Swig_DirectorDerived_callback_FullyOverloaded__SWIG_0(p *_swig_DirectorDerived, arg2 int) (swig_result string) { - var swig_r string - swig_r = p.FullyOverloaded__SWIG_0(arg2) - return swig_r -} - -type _swig_DirectorInterfaceDerivedFullyOverloaded__SWIG_1 interface { - FullyOverloaded__SWIG_1(bool) string -} - -var _wrap__swig_DirectorDerived_upcall_FullyOverloaded__SWIG_1 unsafe.Pointer - -func _swig_wrap__swig_DirectorDerived_upcall_FullyOverloaded__SWIG_1(_swig_ptr SwigcptrDerived, _ bool) (_swig_ret string) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) - _cgo_runtime_cgocall(_wrap__swig_DirectorDerived_upcall_FullyOverloaded__SWIG_1, _swig_p) - return -} - -func (swig_p *_swig_DirectorDerived) FullyOverloaded__SWIG_1(x bool) string { - if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceDerivedFullyOverloaded__SWIG_1); swig_ok { - return swig_g.FullyOverloaded__SWIG_1(x) - } - var swig_r string - swig_r = _swig_wrap__swig_DirectorDerived_upcall_FullyOverloaded__SWIG_1(swig_p.SwigcptrDerived, x) - return swig_r -} - -func DirectorDerivedFullyOverloaded__SWIG_1(p Derived, arg2 bool) string { - var swig_r string - swig_r = _swig_wrap__swig_DirectorDerived_upcall_FullyOverloaded__SWIG_1(p.(*_swig_DirectorDerived).SwigcptrDerived, arg2) - return swig_r -} - -func Swig_DirectorDerived_callback_FullyOverloaded__SWIG_1(p *_swig_DirectorDerived, arg2 bool) (swig_result string) { - var swig_r string - swig_r = p.FullyOverloaded__SWIG_1(arg2) - return swig_r -} - -func (p _swig_DirectorDerived) FullyOverloaded(a ...interface{}) string { - argc := len(a) - if argc == 1 { - if _, ok := a[0].(bool); !ok { - goto check_1 - } - return p.FullyOverloaded__SWIG_1(a[0].(bool)) - } -check_1: - if argc == 1 { - return p.FullyOverloaded__SWIG_0(a[0].(int)) - } - panic("No match for overloaded function call") -} - -func DirectorDerivedFullyOverloaded(p *_swig_DirectorDerived, a ...interface{}) string { - argc := len(a) - if argc == 1 { - if _, ok := a[0].(bool); !ok { - goto check_1 - } - return DirectorDerivedFullyOverloaded__SWIG_1(p, a[0].(bool)) - } -check_1: - if argc == 1 { - return DirectorDerivedFullyOverloaded__SWIG_0(p, a[0].(int)) - } - panic("No match for overloaded function call") -} - -type _swig_DirectorInterfaceDerivedSemiOverloaded interface { - SemiOverloaded(int) string -} - -var _wrap__swig_DirectorDerived_upcall_SemiOverloaded unsafe.Pointer - -func _swig_wrap__swig_DirectorDerived_upcall_SemiOverloaded(_swig_ptr SwigcptrDerived, _ int) (_swig_ret string) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) - _cgo_runtime_cgocall(_wrap__swig_DirectorDerived_upcall_SemiOverloaded, _swig_p) - return -} - -func (swig_p *_swig_DirectorDerived) SemiOverloaded(x int) string { - if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceDerivedSemiOverloaded); swig_ok { - return swig_g.SemiOverloaded(x) - } - var swig_r string - swig_r = _swig_wrap__swig_DirectorDerived_upcall_SemiOverloaded(swig_p.SwigcptrDerived, x) - return swig_r -} - -func DirectorDerivedSemiOverloaded(p Derived, arg2 int) string { - var swig_r string - swig_r = _swig_wrap__swig_DirectorDerived_upcall_SemiOverloaded(p.(*_swig_DirectorDerived).SwigcptrDerived, arg2) - return swig_r -} - -func Swig_DirectorDerived_callback_SemiOverloaded(p *_swig_DirectorDerived, arg2 int) (swig_result string) { - var swig_r string - swig_r = p.SemiOverloaded(arg2) - return swig_r -} - -type _swig_DirectorInterfaceDerivedSemiOverloaded__SWIG_1 interface { - SemiOverloaded__SWIG_1(bool) string -} - -var _wrap__swig_DirectorDerived_upcall_SemiOverloaded__SWIG_1 unsafe.Pointer - -func _swig_wrap__swig_DirectorDerived_upcall_SemiOverloaded__SWIG_1(_swig_ptr SwigcptrDerived, _ bool) (_swig_ret string) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) - _cgo_runtime_cgocall(_wrap__swig_DirectorDerived_upcall_SemiOverloaded__SWIG_1, _swig_p) - return -} - -func (swig_p *_swig_DirectorDerived) SemiOverloaded__SWIG_1(x bool) string { - if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceDerivedSemiOverloaded__SWIG_1); swig_ok { - return swig_g.SemiOverloaded__SWIG_1(x) - } - var swig_r string - swig_r = _swig_wrap__swig_DirectorDerived_upcall_SemiOverloaded__SWIG_1(swig_p.SwigcptrDerived, x) - return swig_r -} - -func DirectorDerivedSemiOverloaded__SWIG_1(p Derived, arg2 bool) string { - var swig_r string - swig_r = _swig_wrap__swig_DirectorDerived_upcall_SemiOverloaded__SWIG_1(p.(*_swig_DirectorDerived).SwigcptrDerived, arg2) - return swig_r -} - -func Swig_DirectorDerived_callback_SemiOverloaded__SWIG_1(p *_swig_DirectorDerived, arg2 bool) (swig_result string) { - var swig_r string - swig_r = p.SemiOverloaded__SWIG_1(arg2) - return swig_r -} - -type _swig_DirectorInterfaceDerivedDefaultParms__SWIG_0 interface { - DefaultParms__SWIG_0(int, float64) string -} - -var _wrap__swig_DirectorDerived_upcall_DefaultParms__SWIG_0 unsafe.Pointer - -func _swig_wrap__swig_DirectorDerived_upcall_DefaultParms__SWIG_0(_swig_ptr SwigcptrDerived, _ int, _ float64) (_swig_ret string) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) - _cgo_runtime_cgocall(_wrap__swig_DirectorDerived_upcall_DefaultParms__SWIG_0, _swig_p) - return -} - -func (swig_p *_swig_DirectorDerived) DefaultParms__SWIG_0(x int, y float64) string { - if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceDerivedDefaultParms__SWIG_0); swig_ok { - return swig_g.DefaultParms__SWIG_0(x, y) - } - var swig_r string - swig_r = _swig_wrap__swig_DirectorDerived_upcall_DefaultParms__SWIG_0(swig_p.SwigcptrDerived, x, y) - return swig_r -} - -func DirectorDerivedDefaultParms__SWIG_0(p Derived, arg2 int, arg3 float64) string { - var swig_r string - swig_r = _swig_wrap__swig_DirectorDerived_upcall_DefaultParms__SWIG_0(p.(*_swig_DirectorDerived).SwigcptrDerived, arg2, arg3) - return swig_r -} - -func Swig_DirectorDerived_callback_DefaultParms__SWIG_0(p *_swig_DirectorDerived, arg2 int, arg3 float64) (swig_result string) { - var swig_r string - swig_r = p.DefaultParms__SWIG_0(arg2, arg3) - return swig_r -} - -type _swig_DirectorInterfaceDerivedDefaultParms__SWIG_1 interface { - DefaultParms__SWIG_1(int) string -} - -var _wrap__swig_DirectorDerived_upcall_DefaultParms__SWIG_1 unsafe.Pointer - -func _swig_wrap__swig_DirectorDerived_upcall_DefaultParms__SWIG_1(_swig_ptr SwigcptrDerived, _ int) (_swig_ret string) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) - _cgo_runtime_cgocall(_wrap__swig_DirectorDerived_upcall_DefaultParms__SWIG_1, _swig_p) - return -} - -func (swig_p *_swig_DirectorDerived) DefaultParms__SWIG_1(x int) string { - if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceDerivedDefaultParms__SWIG_1); swig_ok { - return swig_g.DefaultParms__SWIG_1(x) - } - var swig_r string - swig_r = _swig_wrap__swig_DirectorDerived_upcall_DefaultParms__SWIG_1(swig_p.SwigcptrDerived, x) - return swig_r -} - -func DirectorDerivedDefaultParms__SWIG_1(p Derived, arg2 int) string { - var swig_r string - swig_r = _swig_wrap__swig_DirectorDerived_upcall_DefaultParms__SWIG_1(p.(*_swig_DirectorDerived).SwigcptrDerived, arg2) - return swig_r -} - -func Swig_DirectorDerived_callback_DefaultParms__SWIG_1(p *_swig_DirectorDerived, arg2 int) (swig_result string) { - var swig_r string - swig_r = p.DefaultParms__SWIG_1(arg2) - return swig_r -} - -func (p _swig_DirectorDerived) DefaultParms(a ...interface{}) string { - argc := len(a) - if argc == 1 { - return p.DefaultParms__SWIG_1(a[0].(int)) - } - if argc == 2 { - return p.DefaultParms__SWIG_0(a[0].(int), a[1].(float64)) - } - panic("No match for overloaded function call") -} - -func DirectorDerivedDefaultParms(p *_swig_DirectorDerived, a ...interface{}) string { - argc := len(a) - if argc == 1 { - return DirectorDerivedDefaultParms__SWIG_1(p, a[0].(int)) - } - if argc == 2 { - return DirectorDerivedDefaultParms__SWIG_0(p, a[0].(int), a[1].(float64)) - } - panic("No match for overloaded function call") -} - -type SwigcptrDerived uintptr - -func (p SwigcptrDerived) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrDerived) SwigIsDerived() { -} - -func (p SwigcptrDerived) DirectorInterface() interface{} { - return nil -} - -var _wrap_new_Derived unsafe.Pointer - -func _swig_wrap_new_Derived(base float64) (_ SwigcptrDerived) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Derived, _swig_p) - return -} - -func NewDerived(arg1 float64) (_swig_ret Derived) { - return _swig_wrap_new_Derived(arg1) -} - -var _wrap_delete_Derived unsafe.Pointer - -func _swig_wrap_delete_Derived(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Derived, _swig_p) - return -} - -func DeleteDerived(arg1 Derived) { - _swig_wrap_delete_Derived(arg1.Swigcptr()) -} - -var _wrap_Derived_Val unsafe.Pointer - -func _swig_wrap_Derived_Val(base SwigcptrDerived, _ uintptr) (_ SwigcptrDoubleHolder) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Derived_Val, _swig_p) - return -} - -func (arg1 SwigcptrDerived) Val(arg2 DoubleHolder) (_swig_ret DoubleHolder) { - return _swig_wrap_Derived_Val(arg1, arg2.Swigcptr()) -} - -var _wrap_Derived_Ref unsafe.Pointer - -func _swig_wrap_Derived_Ref(base SwigcptrDerived, _ uintptr) (_ SwigcptrDoubleHolder) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Derived_Ref, _swig_p) - return -} - -func (arg1 SwigcptrDerived) Ref(arg2 DoubleHolder) (_swig_ret DoubleHolder) { - return _swig_wrap_Derived_Ref(arg1, arg2.Swigcptr()) -} - -var _wrap_Derived_Ptr unsafe.Pointer - -func _swig_wrap_Derived_Ptr(base SwigcptrDerived, _ uintptr) (_ SwigcptrDoubleHolder) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Derived_Ptr, _swig_p) - return -} - -func (arg1 SwigcptrDerived) Ptr(arg2 DoubleHolder) (_swig_ret DoubleHolder) { - return _swig_wrap_Derived_Ptr(arg1, arg2.Swigcptr()) -} - -var _wrap_Derived_FullyOverloaded__SWIG_0 unsafe.Pointer - -func _swig_wrap_Derived_FullyOverloaded__SWIG_0(base SwigcptrDerived, _ int) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Derived_FullyOverloaded__SWIG_0, _swig_p) - return -} - -func (arg1 SwigcptrDerived) FullyOverloaded__SWIG_0(arg2 int) (_swig_ret string) { - return _swig_wrap_Derived_FullyOverloaded__SWIG_0(arg1, arg2) -} - -var _wrap_Derived_FullyOverloaded__SWIG_1 unsafe.Pointer - -func _swig_wrap_Derived_FullyOverloaded__SWIG_1(base SwigcptrDerived, _ bool) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Derived_FullyOverloaded__SWIG_1, _swig_p) - return -} - -func (arg1 SwigcptrDerived) FullyOverloaded__SWIG_1(arg2 bool) (_swig_ret string) { - return _swig_wrap_Derived_FullyOverloaded__SWIG_1(arg1, arg2) -} - -func (p SwigcptrDerived) FullyOverloaded(a ...interface{}) string { - argc := len(a) - if argc == 1 { - if _, ok := a[0].(bool); !ok { - goto check_1 - } - return p.FullyOverloaded__SWIG_1(a[0].(bool)) - } -check_1: - if argc == 1 { - return p.FullyOverloaded__SWIG_0(a[0].(int)) - } - panic("No match for overloaded function call") -} - -var _wrap_Derived_SemiOverloaded unsafe.Pointer - -func _swig_wrap_Derived_SemiOverloaded(base SwigcptrDerived, _ int) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Derived_SemiOverloaded, _swig_p) - return -} - -func (arg1 SwigcptrDerived) SemiOverloaded(arg2 int) (_swig_ret string) { - return _swig_wrap_Derived_SemiOverloaded(arg1, arg2) -} - -var _wrap_Derived_DefaultParms__SWIG_0 unsafe.Pointer - -func _swig_wrap_Derived_DefaultParms__SWIG_0(base SwigcptrDerived, _ int, _ float64) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Derived_DefaultParms__SWIG_0, _swig_p) - return -} - -func (arg1 SwigcptrDerived) DefaultParms__SWIG_0(arg2 int, arg3 float64) (_swig_ret string) { - return _swig_wrap_Derived_DefaultParms__SWIG_0(arg1, arg2, arg3) -} - -var _wrap_Derived_DefaultParms__SWIG_1 unsafe.Pointer - -func _swig_wrap_Derived_DefaultParms__SWIG_1(base SwigcptrDerived, _ int) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Derived_DefaultParms__SWIG_1, _swig_p) - return -} - -func (arg1 SwigcptrDerived) DefaultParms__SWIG_1(arg2 int) (_swig_ret string) { - return _swig_wrap_Derived_DefaultParms__SWIG_1(arg1, arg2) -} - -func (p SwigcptrDerived) DefaultParms(a ...interface{}) string { - argc := len(a) - if argc == 1 { - return p.DefaultParms__SWIG_1(a[0].(int)) - } - if argc == 2 { - return p.DefaultParms__SWIG_0(a[0].(int), a[1].(float64)) - } - panic("No match for overloaded function call") -} - -func (p SwigcptrDerived) SwigIsBase() { -} - -func (p SwigcptrDerived) SwigGetBase() Base { - return SwigcptrBase(p.Swigcptr()) -} - -type Derived interface { - Swigcptr() uintptr - SwigIsDerived() - DirectorInterface() interface{} - Val(arg2 DoubleHolder) (_swig_ret DoubleHolder) - Ref(arg2 DoubleHolder) (_swig_ret DoubleHolder) - Ptr(arg2 DoubleHolder) (_swig_ret DoubleHolder) - FullyOverloaded(a ...interface{}) string - SemiOverloaded(arg2 int) (_swig_ret string) - DefaultParms(a ...interface{}) string - SwigIsBase() - SwigGetBase() Base -} - -type SwigcptrCaller uintptr - -func (p SwigcptrCaller) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrCaller) SwigIsCaller() { -} - -var _wrap_new_Caller unsafe.Pointer - -func _swig_wrap_new_Caller() (base SwigcptrCaller) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Caller, _swig_p) - return -} - -func NewCaller() (_swig_ret Caller) { - return _swig_wrap_new_Caller() -} - -var _wrap_delete_Caller unsafe.Pointer - -func _swig_wrap_delete_Caller(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Caller, _swig_p) - return -} - -func DeleteCaller(arg1 Caller) { - _swig_wrap_delete_Caller(arg1.Swigcptr()) -} - -var _wrap_Caller_set unsafe.Pointer - -func _swig_wrap_Caller_set(base SwigcptrCaller, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Caller_set, _swig_p) - return -} - -func (arg1 SwigcptrCaller) Set(arg2 Base) { - _swig_wrap_Caller_set(arg1, arg2.Swigcptr()) -} - -var _wrap_Caller_reset unsafe.Pointer - -func _swig_wrap_Caller_reset(base SwigcptrCaller) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Caller_reset, _swig_p) - return -} - -func (arg1 SwigcptrCaller) Reset() { - _swig_wrap_Caller_reset(arg1) -} - -var _wrap_Caller_ValCall unsafe.Pointer - -func _swig_wrap_Caller_ValCall(base SwigcptrCaller, _ uintptr) (_ SwigcptrDoubleHolder) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Caller_ValCall, _swig_p) - return -} - -func (arg1 SwigcptrCaller) ValCall(arg2 DoubleHolder) (_swig_ret DoubleHolder) { - return _swig_wrap_Caller_ValCall(arg1, arg2.Swigcptr()) -} - -var _wrap_Caller_RefCall unsafe.Pointer - -func _swig_wrap_Caller_RefCall(base SwigcptrCaller, _ uintptr) (_ SwigcptrDoubleHolder) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Caller_RefCall, _swig_p) - return -} - -func (arg1 SwigcptrCaller) RefCall(arg2 DoubleHolder) (_swig_ret DoubleHolder) { - return _swig_wrap_Caller_RefCall(arg1, arg2.Swigcptr()) -} - -var _wrap_Caller_PtrCall unsafe.Pointer - -func _swig_wrap_Caller_PtrCall(base SwigcptrCaller, _ uintptr) (_ SwigcptrDoubleHolder) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Caller_PtrCall, _swig_p) - return -} - -func (arg1 SwigcptrCaller) PtrCall(arg2 DoubleHolder) (_swig_ret DoubleHolder) { - return _swig_wrap_Caller_PtrCall(arg1, arg2.Swigcptr()) -} - -var _wrap_Caller_FullyOverloadedCall__SWIG_0 unsafe.Pointer - -func _swig_wrap_Caller_FullyOverloadedCall__SWIG_0(base SwigcptrCaller, _ int) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Caller_FullyOverloadedCall__SWIG_0, _swig_p) - return -} - -func (arg1 SwigcptrCaller) FullyOverloadedCall__SWIG_0(arg2 int) (_swig_ret string) { - return _swig_wrap_Caller_FullyOverloadedCall__SWIG_0(arg1, arg2) -} - -var _wrap_Caller_FullyOverloadedCall__SWIG_1 unsafe.Pointer - -func _swig_wrap_Caller_FullyOverloadedCall__SWIG_1(base SwigcptrCaller, _ bool) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Caller_FullyOverloadedCall__SWIG_1, _swig_p) - return -} - -func (arg1 SwigcptrCaller) FullyOverloadedCall__SWIG_1(arg2 bool) (_swig_ret string) { - return _swig_wrap_Caller_FullyOverloadedCall__SWIG_1(arg1, arg2) -} - -func (p SwigcptrCaller) FullyOverloadedCall(a ...interface{}) string { - argc := len(a) - if argc == 1 { - if _, ok := a[0].(bool); !ok { - goto check_1 - } - return p.FullyOverloadedCall__SWIG_1(a[0].(bool)) - } -check_1: - if argc == 1 { - return p.FullyOverloadedCall__SWIG_0(a[0].(int)) - } - panic("No match for overloaded function call") -} - -var _wrap_Caller_SemiOverloadedCall__SWIG_0 unsafe.Pointer - -func _swig_wrap_Caller_SemiOverloadedCall__SWIG_0(base SwigcptrCaller, _ int) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Caller_SemiOverloadedCall__SWIG_0, _swig_p) - return -} - -func (arg1 SwigcptrCaller) SemiOverloadedCall__SWIG_0(arg2 int) (_swig_ret string) { - return _swig_wrap_Caller_SemiOverloadedCall__SWIG_0(arg1, arg2) -} - -var _wrap_Caller_SemiOverloadedCall__SWIG_1 unsafe.Pointer - -func _swig_wrap_Caller_SemiOverloadedCall__SWIG_1(base SwigcptrCaller, _ bool) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Caller_SemiOverloadedCall__SWIG_1, _swig_p) - return -} - -func (arg1 SwigcptrCaller) SemiOverloadedCall__SWIG_1(arg2 bool) (_swig_ret string) { - return _swig_wrap_Caller_SemiOverloadedCall__SWIG_1(arg1, arg2) -} - -func (p SwigcptrCaller) SemiOverloadedCall(a ...interface{}) string { - argc := len(a) - if argc == 1 { - if _, ok := a[0].(bool); !ok { - goto check_1 - } - return p.SemiOverloadedCall__SWIG_1(a[0].(bool)) - } -check_1: - if argc == 1 { - return p.SemiOverloadedCall__SWIG_0(a[0].(int)) - } - panic("No match for overloaded function call") -} - -var _wrap_Caller_DefaultParmsCall__SWIG_0 unsafe.Pointer - -func _swig_wrap_Caller_DefaultParmsCall__SWIG_0(base SwigcptrCaller, _ int) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Caller_DefaultParmsCall__SWIG_0, _swig_p) - return -} - -func (arg1 SwigcptrCaller) DefaultParmsCall__SWIG_0(arg2 int) (_swig_ret string) { - return _swig_wrap_Caller_DefaultParmsCall__SWIG_0(arg1, arg2) -} - -var _wrap_Caller_DefaultParmsCall__SWIG_1 unsafe.Pointer - -func _swig_wrap_Caller_DefaultParmsCall__SWIG_1(base SwigcptrCaller, _ int, _ float64) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Caller_DefaultParmsCall__SWIG_1, _swig_p) - return -} - -func (arg1 SwigcptrCaller) DefaultParmsCall__SWIG_1(arg2 int, arg3 float64) (_swig_ret string) { - return _swig_wrap_Caller_DefaultParmsCall__SWIG_1(arg1, arg2, arg3) -} - -func (p SwigcptrCaller) DefaultParmsCall(a ...interface{}) string { - argc := len(a) - if argc == 1 { - return p.DefaultParmsCall__SWIG_0(a[0].(int)) - } - if argc == 2 { - return p.DefaultParmsCall__SWIG_1(a[0].(int), a[1].(float64)) - } - panic("No match for overloaded function call") -} - -type Caller interface { - Swigcptr() uintptr - SwigIsCaller() - Set(arg2 Base) - Reset() - ValCall(arg2 DoubleHolder) (_swig_ret DoubleHolder) - RefCall(arg2 DoubleHolder) (_swig_ret DoubleHolder) - PtrCall(arg2 DoubleHolder) (_swig_ret DoubleHolder) - FullyOverloadedCall(a ...interface{}) string - SemiOverloadedCall(a ...interface{}) string - DefaultParmsCall(a ...interface{}) string -} - -type _swig_DirectorBaseClass struct { - SwigcptrBaseClass - v interface{} -} - -func (p *_swig_DirectorBaseClass) Swigcptr() uintptr { - return p.SwigcptrBaseClass.Swigcptr() -} - -func (p *_swig_DirectorBaseClass) SwigIsBaseClass() { -} - -func (p *_swig_DirectorBaseClass) DirectorInterface() interface{} { - return p.v -} - -var _wrap__swig_NewDirectorBaseClassBaseClass unsafe.Pointer - -func _swig_NewDirectorBaseClassBaseClass(_swig_director *_swig_DirectorBaseClass) (_swig_ret SwigcptrBaseClass) { - _swig_p := uintptr(unsafe.Pointer(&_swig_director)) - _cgo_runtime_cgocall(_wrap__swig_NewDirectorBaseClassBaseClass, _swig_p) - return -} - -func NewDirectorBaseClass(v interface{}) BaseClass { - p := &_swig_DirectorBaseClass{0, v} - p.SwigcptrBaseClass = _swig_NewDirectorBaseClassBaseClass(p) - return p -} - -var _wrap_DeleteDirectorBaseClass unsafe.Pointer - -func _swig_wrap_DeleteDirectorBaseClass(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_DeleteDirectorBaseClass, _swig_p) - return -} - -func DeleteDirectorBaseClass(arg1 BaseClass) { - _swig_wrap_DeleteDirectorBaseClass(arg1.Swigcptr()) -} - -func Swiggo_DeleteDirector_BaseClass(p *_swig_DirectorBaseClass) { - p.SwigcptrBaseClass = 0 -} - -type _swig_DirectorInterfaceBaseClassDofoo interface { - Dofoo(*int, *int, *int) int -} - -var _wrap__swig_DirectorBaseClass_upcall_Dofoo unsafe.Pointer - -func _swig_wrap__swig_DirectorBaseClass_upcall_Dofoo(_swig_ptr SwigcptrBaseClass, _ *int, _ *int, _ *int) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) - _cgo_runtime_cgocall(_wrap__swig_DirectorBaseClass_upcall_Dofoo, _swig_p) - return -} - -func (swig_p *_swig_DirectorBaseClass) Dofoo(one *int, two *int, three *int) int { - if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceBaseClassDofoo); swig_ok { - return swig_g.Dofoo(one, two, three) - } - var swig_r int - swig_r = _swig_wrap__swig_DirectorBaseClass_upcall_Dofoo(swig_p.SwigcptrBaseClass, one, two, three) - return swig_r -} - -func DirectorBaseClassDofoo(p BaseClass, arg2 *int, arg3 *int, arg4 *int) int { - var swig_r int - swig_r = _swig_wrap__swig_DirectorBaseClass_upcall_Dofoo(p.(*_swig_DirectorBaseClass).SwigcptrBaseClass, arg2, arg3, arg4) - return swig_r -} - -func Swig_DirectorBaseClass_callback_dofoo(p *_swig_DirectorBaseClass, arg2 *int, arg3 *int, arg4 *int) (swig_result int) { - var swig_r int - swig_r = p.Dofoo(arg2, arg3, arg4) - return swig_r -} - -type SwigcptrBaseClass uintptr - -func (p SwigcptrBaseClass) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrBaseClass) SwigIsBaseClass() { -} - -func (p SwigcptrBaseClass) DirectorInterface() interface{} { - return nil -} - -var _wrap_delete_BaseClass unsafe.Pointer - -func _swig_wrap_delete_BaseClass(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_BaseClass, _swig_p) - return -} - -func DeleteBaseClass(arg1 BaseClass) { - _swig_wrap_delete_BaseClass(arg1.Swigcptr()) -} - -var _wrap_BaseClass_dofoo unsafe.Pointer - -func _swig_wrap_BaseClass_dofoo(base SwigcptrBaseClass, _ *int, _ *int, _ *int) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_BaseClass_dofoo, _swig_p) - return -} - -func (arg1 SwigcptrBaseClass) Dofoo(arg2 *int, arg3 *int, arg4 *int) (_swig_ret int) { - return _swig_wrap_BaseClass_dofoo(arg1, arg2, arg3, arg4) -} - -var _wrap_new_BaseClass unsafe.Pointer - -func _swig_wrap_new_BaseClass() (base SwigcptrBaseClass) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_BaseClass, _swig_p) - return -} - -func NewBaseClass() (_swig_ret BaseClass) { - return _swig_wrap_new_BaseClass() -} - -type BaseClass interface { - Swigcptr() uintptr - SwigIsBaseClass() - DirectorInterface() interface{} - Dofoo(arg2 *int, arg3 *int, arg4 *int) (_swig_ret int) -} - -type _swig_DirectorDerivedClass struct { - SwigcptrDerivedClass - v interface{} -} - -func (p *_swig_DirectorDerivedClass) Swigcptr() uintptr { - return p.SwigcptrDerivedClass.Swigcptr() -} - -func (p *_swig_DirectorDerivedClass) SwigIsDerivedClass() { -} - -func (p *_swig_DirectorDerivedClass) DirectorInterface() interface{} { - return p.v -} - -var _wrap__swig_NewDirectorDerivedClassDerivedClass unsafe.Pointer - -func _swig_NewDirectorDerivedClassDerivedClass(_swig_director *_swig_DirectorDerivedClass) (_swig_ret SwigcptrDerivedClass) { - _swig_p := uintptr(unsafe.Pointer(&_swig_director)) - _cgo_runtime_cgocall(_wrap__swig_NewDirectorDerivedClassDerivedClass, _swig_p) - return -} - -func NewDirectorDerivedClass(v interface{}) DerivedClass { - p := &_swig_DirectorDerivedClass{0, v} - p.SwigcptrDerivedClass = _swig_NewDirectorDerivedClassDerivedClass(p) - return p -} - -var _wrap_DeleteDirectorDerivedClass unsafe.Pointer - -func _swig_wrap_DeleteDirectorDerivedClass(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_DeleteDirectorDerivedClass, _swig_p) - return -} - -func DeleteDirectorDerivedClass(arg1 DerivedClass) { - _swig_wrap_DeleteDirectorDerivedClass(arg1.Swigcptr()) -} - -func Swiggo_DeleteDirector_DerivedClass(p *_swig_DirectorDerivedClass) { - p.SwigcptrDerivedClass = 0 -} - -type _swig_DirectorInterfaceDerivedClassDofoo interface { - Dofoo(*int, *int, *int) int -} - -var _wrap__swig_DirectorDerivedClass_upcall_Dofoo unsafe.Pointer - -func _swig_wrap__swig_DirectorDerivedClass_upcall_Dofoo(_swig_ptr SwigcptrDerivedClass, _ *int, _ *int, _ *int) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) - _cgo_runtime_cgocall(_wrap__swig_DirectorDerivedClass_upcall_Dofoo, _swig_p) - return -} - -func (swig_p *_swig_DirectorDerivedClass) Dofoo(one *int, two *int, three *int) int { - if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceDerivedClassDofoo); swig_ok { - return swig_g.Dofoo(one, two, three) - } - var swig_r int - swig_r = _swig_wrap__swig_DirectorDerivedClass_upcall_Dofoo(swig_p.SwigcptrDerivedClass, one, two, three) - return swig_r -} - -func DirectorDerivedClassDofoo(p DerivedClass, arg2 *int, arg3 *int, arg4 *int) int { - var swig_r int - swig_r = _swig_wrap__swig_DirectorDerivedClass_upcall_Dofoo(p.(*_swig_DirectorDerivedClass).SwigcptrDerivedClass, arg2, arg3, arg4) - return swig_r -} - -func Swig_DirectorDerivedClass_callback_dofoo(p *_swig_DirectorDerivedClass, arg2 *int, arg3 *int, arg4 *int) (swig_result int) { - var swig_r int - swig_r = p.Dofoo(arg2, arg3, arg4) - return swig_r -} - -type SwigcptrDerivedClass uintptr - -func (p SwigcptrDerivedClass) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrDerivedClass) SwigIsDerivedClass() { -} - -func (p SwigcptrDerivedClass) DirectorInterface() interface{} { - return nil -} - -var _wrap_new_DerivedClass unsafe.Pointer - -func _swig_wrap_new_DerivedClass() (base SwigcptrDerivedClass) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_DerivedClass, _swig_p) - return -} - -func NewDerivedClass() (_swig_ret DerivedClass) { - return _swig_wrap_new_DerivedClass() -} - -var _wrap_delete_DerivedClass unsafe.Pointer - -func _swig_wrap_delete_DerivedClass(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_DerivedClass, _swig_p) - return -} - -func DeleteDerivedClass(arg1 DerivedClass) { - _swig_wrap_delete_DerivedClass(arg1.Swigcptr()) -} - -var _wrap_DerivedClass_dofoo unsafe.Pointer - -func _swig_wrap_DerivedClass_dofoo(base SwigcptrDerivedClass, _ *int, _ *int, _ *int) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_DerivedClass_dofoo, _swig_p) - return -} - -func (_swig_base SwigcptrDerivedClass) Dofoo(arg1 *int, arg2 *int, arg3 *int) (_swig_ret int) { - return _swig_wrap_DerivedClass_dofoo(_swig_base, arg1, arg2, arg3) -} - -func (p SwigcptrDerivedClass) SwigIsBaseClass() { -} - -func (p SwigcptrDerivedClass) SwigGetBaseClass() BaseClass { - return SwigcptrBaseClass(p.Swigcptr()) -} - -type DerivedClass interface { - Swigcptr() uintptr - SwigIsDerivedClass() - DirectorInterface() interface{} - Dofoo(arg1 *int, arg2 *int, arg3 *int) (_swig_ret int) - SwigIsBaseClass() - SwigGetBaseClass() BaseClass -} - - -type SwigcptrSwigDirector_BaseClass uintptr -type SwigDirector_BaseClass interface { - Swigcptr() uintptr; -} -func (p SwigcptrSwigDirector_BaseClass) Swigcptr() uintptr { - return uintptr(p) -} - -type SwigcptrSwigDirector_Derived uintptr -type SwigDirector_Derived interface { - Swigcptr() uintptr; -} -func (p SwigcptrSwigDirector_Derived) Swigcptr() uintptr { - return uintptr(p) -} - -type SwigcptrSwigDirector_Base uintptr -type SwigDirector_Base interface { - Swigcptr() uintptr; -} -func (p SwigcptrSwigDirector_Base) Swigcptr() uintptr { - return uintptr(p) -} - -type SwigcptrSwigDirector_DerivedClass uintptr -type SwigDirector_DerivedClass interface { - Swigcptr() uintptr; -} -func (p SwigcptrSwigDirector_DerivedClass) Swigcptr() uintptr { - return uintptr(p) -} - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/director_classes_wrap.h b/Examples/test-suite/go/director_classes_wrap.h deleted file mode 100644 index a18d87f70..000000000 --- a/Examples/test-suite/go/director_classes_wrap.h +++ /dev/null @@ -1,132 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../director_classes.i - -#ifndef SWIG_director_classes_WRAP_H_ -#define SWIG_director_classes_WRAP_H_ - -class SwigDirector_Base : public Base -{ - public: - SwigDirector_Base(void *swig_p, double dd); - virtual ~SwigDirector_Base(); - DoubleHolder _swig_upcall_Val(DoubleHolder x) { - return Base::Val(x); - } - virtual DoubleHolder Val(DoubleHolder x); - DoubleHolder &_swig_upcall_Ref(DoubleHolder &x) { - return Base::Ref(x); - } - virtual DoubleHolder &Ref(DoubleHolder &x); - DoubleHolder *_swig_upcall_Ptr(DoubleHolder *x) { - return Base::Ptr(x); - } - virtual DoubleHolder *Ptr(DoubleHolder *x); - std::string _swig_upcall_FullyOverloaded__SWIG_0(int x) { - return Base::FullyOverloaded(x); - } - virtual std::string FullyOverloaded(int x); - std::string _swig_upcall_FullyOverloaded__SWIG_1(bool x) { - return Base::FullyOverloaded(x); - } - virtual std::string FullyOverloaded(bool x); - std::string _swig_upcall_SemiOverloaded__SWIG_0(int x) { - return Base::SemiOverloaded(x); - } - virtual std::string SemiOverloaded(int x); - std::string _swig_upcall_SemiOverloaded__SWIG_1(bool x) { - return Base::SemiOverloaded(x); - } - virtual std::string SemiOverloaded(bool x); - std::string _swig_upcall_DefaultParms__SWIG_0(int x, double y) { - return Base::DefaultParms(x,y); - } - virtual std::string DefaultParms(int x, double y); - std::string _swig_upcall_DefaultParms__SWIG_1(int x) { - return Base::DefaultParms(x); - } - virtual std::string DefaultParms(int x); - private: - void *go_val; -}; - -class SwigDirector_Derived : public Derived -{ - public: - SwigDirector_Derived(void *swig_p, double dd); - virtual ~SwigDirector_Derived(); - DoubleHolder _swig_upcall_Val(DoubleHolder x) { - return Derived::Val(x); - } - virtual DoubleHolder Val(DoubleHolder x); - DoubleHolder &_swig_upcall_Ref(DoubleHolder &x) { - return Derived::Ref(x); - } - virtual DoubleHolder &Ref(DoubleHolder &x); - DoubleHolder *_swig_upcall_Ptr(DoubleHolder *x) { - return Derived::Ptr(x); - } - virtual DoubleHolder *Ptr(DoubleHolder *x); - std::string _swig_upcall_FullyOverloaded__SWIG_0(int x) { - return Derived::FullyOverloaded(x); - } - virtual std::string FullyOverloaded(int x); - std::string _swig_upcall_FullyOverloaded__SWIG_1(bool x) { - return Derived::FullyOverloaded(x); - } - virtual std::string FullyOverloaded(bool x); - std::string _swig_upcall_SemiOverloaded(int x) { - return Derived::SemiOverloaded(x); - } - virtual std::string SemiOverloaded(int x); - std::string _swig_upcall_SemiOverloaded__SWIG_1(bool x) { - return Base::SemiOverloaded(x); - } - virtual std::string SemiOverloaded(bool x); - std::string _swig_upcall_DefaultParms__SWIG_0(int x, double y) { - return Derived::DefaultParms(x,y); - } - virtual std::string DefaultParms(int x, double y); - std::string _swig_upcall_DefaultParms__SWIG_1(int x) { - return Derived::DefaultParms(x); - } - virtual std::string DefaultParms(int x); - private: - void *go_val; -}; - -class SwigDirector_BaseClass : public BaseClass -{ - public: - SwigDirector_BaseClass(void *swig_p); - virtual ~SwigDirector_BaseClass(); - int _swig_upcall_dofoo(int &one, int &two, int &three) { - return BaseClass::dofoo(one,two,three); - } - virtual int dofoo(int &one, int &two, int &three); - private: - void *go_val; -}; - -class SwigDirector_DerivedClass : public DerivedClass -{ - public: - SwigDirector_DerivedClass(void *swig_p); - virtual ~SwigDirector_DerivedClass(); - int _swig_upcall_dofoo(int &one, int &two, int &three) { - return BaseClass::dofoo(one,two,three); - } - virtual int dofoo(int &one, int &two, int &three); - private: - void *go_val; -}; - -#endif diff --git a/Examples/test-suite/go/director_classic.go b/Examples/test-suite/go/director_classic.go deleted file mode 100644 index 5a3534a56..000000000 --- a/Examples/test-suite/go/director_classic.go +++ /dev/null @@ -1,1102 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../director_classic.i - -package director_classic - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type _swig_DirectorBeing struct { - SwigcptrBeing - v interface{} -} - -func (p *_swig_DirectorBeing) Swigcptr() uintptr { - return p.SwigcptrBeing.Swigcptr() -} - -func (p *_swig_DirectorBeing) SwigIsBeing() { -} - -func (p *_swig_DirectorBeing) DirectorInterface() interface{} { - return p.v -} - -var _wrap__swig_NewDirectorBeingBeing unsafe.Pointer - -func _swig_NewDirectorBeingBeing(_swig_director *_swig_DirectorBeing) (_swig_ret SwigcptrBeing) { - _swig_p := uintptr(unsafe.Pointer(&_swig_director)) - _cgo_runtime_cgocall(_wrap__swig_NewDirectorBeingBeing, _swig_p) - return -} - -func NewDirectorBeing(v interface{}) Being { - p := &_swig_DirectorBeing{0, v} - p.SwigcptrBeing = _swig_NewDirectorBeingBeing(p) - return p -} - -type _swig_DirectorInterfaceBeingId interface { - Id() string -} - -var _wrap__swig_DirectorBeing_upcall_Id unsafe.Pointer - -func _swig_wrap__swig_DirectorBeing_upcall_Id(_swig_ptr SwigcptrBeing) (_swig_ret string) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) - _cgo_runtime_cgocall(_wrap__swig_DirectorBeing_upcall_Id, _swig_p) - return -} - -func (swig_p *_swig_DirectorBeing) Id() string { - if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceBeingId); swig_ok { - return swig_g.Id() - } - var swig_r string - swig_r = _swig_wrap__swig_DirectorBeing_upcall_Id(swig_p.SwigcptrBeing) - return swig_r -} - -func DirectorBeingId(p Being) string { - var swig_r string - swig_r = _swig_wrap__swig_DirectorBeing_upcall_Id(p.(*_swig_DirectorBeing).SwigcptrBeing) - return swig_r -} - -func Swig_DirectorBeing_callback_id(p *_swig_DirectorBeing) (swig_result string) { - var swig_r string - swig_r = p.Id() - return swig_r -} - -var _wrap_DeleteDirectorBeing unsafe.Pointer - -func _swig_wrap_DeleteDirectorBeing(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_DeleteDirectorBeing, _swig_p) - return -} - -func DeleteDirectorBeing(arg1 Being) { - _swig_wrap_DeleteDirectorBeing(arg1.Swigcptr()) -} - -func Swiggo_DeleteDirector_Being(p *_swig_DirectorBeing) { - p.SwigcptrBeing = 0 -} - -type SwigcptrBeing uintptr - -func (p SwigcptrBeing) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrBeing) SwigIsBeing() { -} - -func (p SwigcptrBeing) DirectorInterface() interface{} { - return nil -} - -var _wrap_Being_id unsafe.Pointer - -func _swig_wrap_Being_id(base SwigcptrBeing) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Being_id, _swig_p) - return -} - -func (arg1 SwigcptrBeing) Id() (_swig_ret string) { - return _swig_wrap_Being_id(arg1) -} - -var _wrap_delete_Being unsafe.Pointer - -func _swig_wrap_delete_Being(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Being, _swig_p) - return -} - -func DeleteBeing(arg1 Being) { - _swig_wrap_delete_Being(arg1.Swigcptr()) -} - -var _wrap_new_Being unsafe.Pointer - -func _swig_wrap_new_Being() (base SwigcptrBeing) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Being, _swig_p) - return -} - -func NewBeing() (_swig_ret Being) { - return _swig_wrap_new_Being() -} - -type Being interface { - Swigcptr() uintptr - SwigIsBeing() - DirectorInterface() interface{} - Id() (_swig_ret string) -} - -type _swig_DirectorPerson struct { - SwigcptrPerson - v interface{} -} - -func (p *_swig_DirectorPerson) Swigcptr() uintptr { - return p.SwigcptrPerson.Swigcptr() -} - -func (p *_swig_DirectorPerson) SwigIsPerson() { -} - -func (p *_swig_DirectorPerson) DirectorInterface() interface{} { - return p.v -} - -var _wrap__swig_NewDirectorPersonPerson unsafe.Pointer - -func _swig_NewDirectorPersonPerson(_swig_director *_swig_DirectorPerson) (_swig_ret SwigcptrPerson) { - _swig_p := uintptr(unsafe.Pointer(&_swig_director)) - _cgo_runtime_cgocall(_wrap__swig_NewDirectorPersonPerson, _swig_p) - return -} - -func NewDirectorPerson(v interface{}) Person { - p := &_swig_DirectorPerson{0, v} - p.SwigcptrPerson = _swig_NewDirectorPersonPerson(p) - return p -} - -type _swig_DirectorInterfacePersonId interface { - Id() string -} - -var _wrap__swig_DirectorPerson_upcall_Id unsafe.Pointer - -func _swig_wrap__swig_DirectorPerson_upcall_Id(_swig_ptr SwigcptrPerson) (_swig_ret string) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) - _cgo_runtime_cgocall(_wrap__swig_DirectorPerson_upcall_Id, _swig_p) - return -} - -func (swig_p *_swig_DirectorPerson) Id() string { - if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfacePersonId); swig_ok { - return swig_g.Id() - } - var swig_r string - swig_r = _swig_wrap__swig_DirectorPerson_upcall_Id(swig_p.SwigcptrPerson) - return swig_r -} - -func DirectorPersonId(p Person) string { - var swig_r string - swig_r = _swig_wrap__swig_DirectorPerson_upcall_Id(p.(*_swig_DirectorPerson).SwigcptrPerson) - return swig_r -} - -func Swig_DirectorPerson_callback_id(p *_swig_DirectorPerson) (swig_result string) { - var swig_r string - swig_r = p.Id() - return swig_r -} - -var _wrap_DeleteDirectorPerson unsafe.Pointer - -func _swig_wrap_DeleteDirectorPerson(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_DeleteDirectorPerson, _swig_p) - return -} - -func DeleteDirectorPerson(arg1 Person) { - _swig_wrap_DeleteDirectorPerson(arg1.Swigcptr()) -} - -func Swiggo_DeleteDirector_Person(p *_swig_DirectorPerson) { - p.SwigcptrPerson = 0 -} - -type SwigcptrPerson uintptr - -func (p SwigcptrPerson) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrPerson) SwigIsPerson() { -} - -func (p SwigcptrPerson) DirectorInterface() interface{} { - return nil -} - -var _wrap_Person_id unsafe.Pointer - -func _swig_wrap_Person_id(base SwigcptrPerson) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Person_id, _swig_p) - return -} - -func (arg1 SwigcptrPerson) Id() (_swig_ret string) { - return _swig_wrap_Person_id(arg1) -} - -var _wrap_new_Person unsafe.Pointer - -func _swig_wrap_new_Person() (base SwigcptrPerson) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Person, _swig_p) - return -} - -func NewPerson() (_swig_ret Person) { - return _swig_wrap_new_Person() -} - -var _wrap_delete_Person unsafe.Pointer - -func _swig_wrap_delete_Person(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Person, _swig_p) - return -} - -func DeletePerson(arg1 Person) { - _swig_wrap_delete_Person(arg1.Swigcptr()) -} - -func (p SwigcptrPerson) SwigIsBeing() { -} - -func (p SwigcptrPerson) SwigGetBeing() Being { - return SwigcptrBeing(p.Swigcptr()) -} - -type Person interface { - Swigcptr() uintptr - SwigIsPerson() - DirectorInterface() interface{} - Id() (_swig_ret string) - SwigIsBeing() - SwigGetBeing() Being -} - -type _swig_DirectorChild struct { - SwigcptrChild - v interface{} -} - -func (p *_swig_DirectorChild) Swigcptr() uintptr { - return p.SwigcptrChild.Swigcptr() -} - -func (p *_swig_DirectorChild) SwigIsChild() { -} - -func (p *_swig_DirectorChild) DirectorInterface() interface{} { - return p.v -} - -var _wrap__swig_NewDirectorChildChild unsafe.Pointer - -func _swig_NewDirectorChildChild(_swig_director *_swig_DirectorChild) (_swig_ret SwigcptrChild) { - _swig_p := uintptr(unsafe.Pointer(&_swig_director)) - _cgo_runtime_cgocall(_wrap__swig_NewDirectorChildChild, _swig_p) - return -} - -func NewDirectorChild(v interface{}) Child { - p := &_swig_DirectorChild{0, v} - p.SwigcptrChild = _swig_NewDirectorChildChild(p) - return p -} - -type _swig_DirectorInterfaceChildId interface { - Id() string -} - -var _wrap__swig_DirectorChild_upcall_Id unsafe.Pointer - -func _swig_wrap__swig_DirectorChild_upcall_Id(_swig_ptr SwigcptrChild) (_swig_ret string) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) - _cgo_runtime_cgocall(_wrap__swig_DirectorChild_upcall_Id, _swig_p) - return -} - -func (swig_p *_swig_DirectorChild) Id() string { - if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceChildId); swig_ok { - return swig_g.Id() - } - var swig_r string - swig_r = _swig_wrap__swig_DirectorChild_upcall_Id(swig_p.SwigcptrChild) - return swig_r -} - -func DirectorChildId(p Child) string { - var swig_r string - swig_r = _swig_wrap__swig_DirectorChild_upcall_Id(p.(*_swig_DirectorChild).SwigcptrChild) - return swig_r -} - -func Swig_DirectorChild_callback_id(p *_swig_DirectorChild) (swig_result string) { - var swig_r string - swig_r = p.Id() - return swig_r -} - -var _wrap_DeleteDirectorChild unsafe.Pointer - -func _swig_wrap_DeleteDirectorChild(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_DeleteDirectorChild, _swig_p) - return -} - -func DeleteDirectorChild(arg1 Child) { - _swig_wrap_DeleteDirectorChild(arg1.Swigcptr()) -} - -func Swiggo_DeleteDirector_Child(p *_swig_DirectorChild) { - p.SwigcptrChild = 0 -} - -type SwigcptrChild uintptr - -func (p SwigcptrChild) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrChild) SwigIsChild() { -} - -func (p SwigcptrChild) DirectorInterface() interface{} { - return nil -} - -var _wrap_Child_id unsafe.Pointer - -func _swig_wrap_Child_id(base SwigcptrChild) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Child_id, _swig_p) - return -} - -func (arg1 SwigcptrChild) Id() (_swig_ret string) { - return _swig_wrap_Child_id(arg1) -} - -var _wrap_new_Child unsafe.Pointer - -func _swig_wrap_new_Child() (base SwigcptrChild) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Child, _swig_p) - return -} - -func NewChild() (_swig_ret Child) { - return _swig_wrap_new_Child() -} - -var _wrap_delete_Child unsafe.Pointer - -func _swig_wrap_delete_Child(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Child, _swig_p) - return -} - -func DeleteChild(arg1 Child) { - _swig_wrap_delete_Child(arg1.Swigcptr()) -} - -func (p SwigcptrChild) SwigIsPerson() { -} - -func (p SwigcptrChild) SwigGetPerson() Person { - return SwigcptrPerson(p.Swigcptr()) -} - -func (p SwigcptrChild) SwigIsBeing() { -} - -func (p SwigcptrChild) SwigGetBeing() Being { - return SwigcptrBeing(p.Swigcptr()) -} - -type Child interface { - Swigcptr() uintptr - SwigIsChild() - DirectorInterface() interface{} - Id() (_swig_ret string) - SwigIsPerson() - SwigGetPerson() Person - SwigIsBeing() - SwigGetBeing() Being -} - -type _swig_DirectorGrandChild struct { - SwigcptrGrandChild - v interface{} -} - -func (p *_swig_DirectorGrandChild) Swigcptr() uintptr { - return p.SwigcptrGrandChild.Swigcptr() -} - -func (p *_swig_DirectorGrandChild) SwigIsGrandChild() { -} - -func (p *_swig_DirectorGrandChild) DirectorInterface() interface{} { - return p.v -} - -var _wrap__swig_NewDirectorGrandChildGrandChild unsafe.Pointer - -func _swig_NewDirectorGrandChildGrandChild(_swig_director *_swig_DirectorGrandChild) (_swig_ret SwigcptrGrandChild) { - _swig_p := uintptr(unsafe.Pointer(&_swig_director)) - _cgo_runtime_cgocall(_wrap__swig_NewDirectorGrandChildGrandChild, _swig_p) - return -} - -func NewDirectorGrandChild(v interface{}) GrandChild { - p := &_swig_DirectorGrandChild{0, v} - p.SwigcptrGrandChild = _swig_NewDirectorGrandChildGrandChild(p) - return p -} - -type _swig_DirectorInterfaceGrandChildId interface { - Id() string -} - -var _wrap__swig_DirectorGrandChild_upcall_Id unsafe.Pointer - -func _swig_wrap__swig_DirectorGrandChild_upcall_Id(_swig_ptr SwigcptrGrandChild) (_swig_ret string) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) - _cgo_runtime_cgocall(_wrap__swig_DirectorGrandChild_upcall_Id, _swig_p) - return -} - -func (swig_p *_swig_DirectorGrandChild) Id() string { - if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceGrandChildId); swig_ok { - return swig_g.Id() - } - var swig_r string - swig_r = _swig_wrap__swig_DirectorGrandChild_upcall_Id(swig_p.SwigcptrGrandChild) - return swig_r -} - -func DirectorGrandChildId(p GrandChild) string { - var swig_r string - swig_r = _swig_wrap__swig_DirectorGrandChild_upcall_Id(p.(*_swig_DirectorGrandChild).SwigcptrGrandChild) - return swig_r -} - -func Swig_DirectorGrandChild_callback_id(p *_swig_DirectorGrandChild) (swig_result string) { - var swig_r string - swig_r = p.Id() - return swig_r -} - -var _wrap_DeleteDirectorGrandChild unsafe.Pointer - -func _swig_wrap_DeleteDirectorGrandChild(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_DeleteDirectorGrandChild, _swig_p) - return -} - -func DeleteDirectorGrandChild(arg1 GrandChild) { - _swig_wrap_DeleteDirectorGrandChild(arg1.Swigcptr()) -} - -func Swiggo_DeleteDirector_GrandChild(p *_swig_DirectorGrandChild) { - p.SwigcptrGrandChild = 0 -} - -type SwigcptrGrandChild uintptr - -func (p SwigcptrGrandChild) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrGrandChild) SwigIsGrandChild() { -} - -func (p SwigcptrGrandChild) DirectorInterface() interface{} { - return nil -} - -var _wrap_GrandChild_id unsafe.Pointer - -func _swig_wrap_GrandChild_id(base SwigcptrGrandChild) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_GrandChild_id, _swig_p) - return -} - -func (arg1 SwigcptrGrandChild) Id() (_swig_ret string) { - return _swig_wrap_GrandChild_id(arg1) -} - -var _wrap_new_GrandChild unsafe.Pointer - -func _swig_wrap_new_GrandChild() (base SwigcptrGrandChild) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_GrandChild, _swig_p) - return -} - -func NewGrandChild() (_swig_ret GrandChild) { - return _swig_wrap_new_GrandChild() -} - -var _wrap_delete_GrandChild unsafe.Pointer - -func _swig_wrap_delete_GrandChild(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_GrandChild, _swig_p) - return -} - -func DeleteGrandChild(arg1 GrandChild) { - _swig_wrap_delete_GrandChild(arg1.Swigcptr()) -} - -func (p SwigcptrGrandChild) SwigIsChild() { -} - -func (p SwigcptrGrandChild) SwigGetChild() Child { - return SwigcptrChild(p.Swigcptr()) -} - -func (p SwigcptrGrandChild) SwigIsPerson() { -} - -func (p SwigcptrGrandChild) SwigGetPerson() Person { - return SwigcptrPerson(p.Swigcptr()) -} - -func (p SwigcptrGrandChild) SwigIsBeing() { -} - -func (p SwigcptrGrandChild) SwigGetBeing() Being { - return SwigcptrBeing(p.Swigcptr()) -} - -type GrandChild interface { - Swigcptr() uintptr - SwigIsGrandChild() - DirectorInterface() interface{} - Id() (_swig_ret string) - SwigIsChild() - SwigGetChild() Child - SwigIsPerson() - SwigGetPerson() Person - SwigIsBeing() - SwigGetBeing() Being -} - -type _swig_DirectorOrphanPerson struct { - SwigcptrOrphanPerson - v interface{} -} - -func (p *_swig_DirectorOrphanPerson) Swigcptr() uintptr { - return p.SwigcptrOrphanPerson.Swigcptr() -} - -func (p *_swig_DirectorOrphanPerson) SwigIsOrphanPerson() { -} - -func (p *_swig_DirectorOrphanPerson) DirectorInterface() interface{} { - return p.v -} - -var _wrap__swig_NewDirectorOrphanPersonOrphanPerson unsafe.Pointer - -func _swig_NewDirectorOrphanPersonOrphanPerson(_swig_director *_swig_DirectorOrphanPerson) (_swig_ret SwigcptrOrphanPerson) { - _swig_p := uintptr(unsafe.Pointer(&_swig_director)) - _cgo_runtime_cgocall(_wrap__swig_NewDirectorOrphanPersonOrphanPerson, _swig_p) - return -} - -func NewDirectorOrphanPerson(v interface{}) OrphanPerson { - p := &_swig_DirectorOrphanPerson{0, v} - p.SwigcptrOrphanPerson = _swig_NewDirectorOrphanPersonOrphanPerson(p) - return p -} - -type _swig_DirectorInterfaceOrphanPersonId interface { - Id() string -} - -var _wrap__swig_DirectorOrphanPerson_upcall_Id unsafe.Pointer - -func _swig_wrap__swig_DirectorOrphanPerson_upcall_Id(_swig_ptr SwigcptrOrphanPerson) (_swig_ret string) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) - _cgo_runtime_cgocall(_wrap__swig_DirectorOrphanPerson_upcall_Id, _swig_p) - return -} - -func (swig_p *_swig_DirectorOrphanPerson) Id() string { - if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceOrphanPersonId); swig_ok { - return swig_g.Id() - } - var swig_r string - swig_r = _swig_wrap__swig_DirectorOrphanPerson_upcall_Id(swig_p.SwigcptrOrphanPerson) - return swig_r -} - -func DirectorOrphanPersonId(p OrphanPerson) string { - var swig_r string - swig_r = _swig_wrap__swig_DirectorOrphanPerson_upcall_Id(p.(*_swig_DirectorOrphanPerson).SwigcptrOrphanPerson) - return swig_r -} - -func Swig_DirectorOrphanPerson_callback_id(p *_swig_DirectorOrphanPerson) (swig_result string) { - var swig_r string - swig_r = p.Id() - return swig_r -} - -var _wrap_DeleteDirectorOrphanPerson unsafe.Pointer - -func _swig_wrap_DeleteDirectorOrphanPerson(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_DeleteDirectorOrphanPerson, _swig_p) - return -} - -func DeleteDirectorOrphanPerson(arg1 OrphanPerson) { - _swig_wrap_DeleteDirectorOrphanPerson(arg1.Swigcptr()) -} - -func Swiggo_DeleteDirector_OrphanPerson(p *_swig_DirectorOrphanPerson) { - p.SwigcptrOrphanPerson = 0 -} - -type SwigcptrOrphanPerson uintptr - -func (p SwigcptrOrphanPerson) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrOrphanPerson) SwigIsOrphanPerson() { -} - -func (p SwigcptrOrphanPerson) DirectorInterface() interface{} { - return nil -} - -var _wrap_new_OrphanPerson unsafe.Pointer - -func _swig_wrap_new_OrphanPerson() (base SwigcptrOrphanPerson) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_OrphanPerson, _swig_p) - return -} - -func NewOrphanPerson() (_swig_ret OrphanPerson) { - return _swig_wrap_new_OrphanPerson() -} - -var _wrap_delete_OrphanPerson unsafe.Pointer - -func _swig_wrap_delete_OrphanPerson(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_OrphanPerson, _swig_p) - return -} - -func DeleteOrphanPerson(arg1 OrphanPerson) { - _swig_wrap_delete_OrphanPerson(arg1.Swigcptr()) -} - -var _wrap_OrphanPerson_id unsafe.Pointer - -func _swig_wrap_OrphanPerson_id(base SwigcptrOrphanPerson) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_OrphanPerson_id, _swig_p) - return -} - -func (_swig_base SwigcptrOrphanPerson) Id() (_swig_ret string) { - return _swig_wrap_OrphanPerson_id(_swig_base) -} - -func (p SwigcptrOrphanPerson) SwigIsPerson() { -} - -func (p SwigcptrOrphanPerson) SwigGetPerson() Person { - return SwigcptrPerson(p.Swigcptr()) -} - -func (p SwigcptrOrphanPerson) SwigIsBeing() { -} - -func (p SwigcptrOrphanPerson) SwigGetBeing() Being { - return SwigcptrBeing(p.Swigcptr()) -} - -type OrphanPerson interface { - Swigcptr() uintptr - SwigIsOrphanPerson() - DirectorInterface() interface{} - Id() (_swig_ret string) - SwigIsPerson() - SwigGetPerson() Person - SwigIsBeing() - SwigGetBeing() Being -} - -type _swig_DirectorOrphanChild struct { - SwigcptrOrphanChild - v interface{} -} - -func (p *_swig_DirectorOrphanChild) Swigcptr() uintptr { - return p.SwigcptrOrphanChild.Swigcptr() -} - -func (p *_swig_DirectorOrphanChild) SwigIsOrphanChild() { -} - -func (p *_swig_DirectorOrphanChild) DirectorInterface() interface{} { - return p.v -} - -var _wrap__swig_NewDirectorOrphanChildOrphanChild unsafe.Pointer - -func _swig_NewDirectorOrphanChildOrphanChild(_swig_director *_swig_DirectorOrphanChild) (_swig_ret SwigcptrOrphanChild) { - _swig_p := uintptr(unsafe.Pointer(&_swig_director)) - _cgo_runtime_cgocall(_wrap__swig_NewDirectorOrphanChildOrphanChild, _swig_p) - return -} - -func NewDirectorOrphanChild(v interface{}) OrphanChild { - p := &_swig_DirectorOrphanChild{0, v} - p.SwigcptrOrphanChild = _swig_NewDirectorOrphanChildOrphanChild(p) - return p -} - -type _swig_DirectorInterfaceOrphanChildId interface { - Id() string -} - -var _wrap__swig_DirectorOrphanChild_upcall_Id unsafe.Pointer - -func _swig_wrap__swig_DirectorOrphanChild_upcall_Id(_swig_ptr SwigcptrOrphanChild) (_swig_ret string) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) - _cgo_runtime_cgocall(_wrap__swig_DirectorOrphanChild_upcall_Id, _swig_p) - return -} - -func (swig_p *_swig_DirectorOrphanChild) Id() string { - if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceOrphanChildId); swig_ok { - return swig_g.Id() - } - var swig_r string - swig_r = _swig_wrap__swig_DirectorOrphanChild_upcall_Id(swig_p.SwigcptrOrphanChild) - return swig_r -} - -func DirectorOrphanChildId(p OrphanChild) string { - var swig_r string - swig_r = _swig_wrap__swig_DirectorOrphanChild_upcall_Id(p.(*_swig_DirectorOrphanChild).SwigcptrOrphanChild) - return swig_r -} - -func Swig_DirectorOrphanChild_callback_id(p *_swig_DirectorOrphanChild) (swig_result string) { - var swig_r string - swig_r = p.Id() - return swig_r -} - -var _wrap_DeleteDirectorOrphanChild unsafe.Pointer - -func _swig_wrap_DeleteDirectorOrphanChild(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_DeleteDirectorOrphanChild, _swig_p) - return -} - -func DeleteDirectorOrphanChild(arg1 OrphanChild) { - _swig_wrap_DeleteDirectorOrphanChild(arg1.Swigcptr()) -} - -func Swiggo_DeleteDirector_OrphanChild(p *_swig_DirectorOrphanChild) { - p.SwigcptrOrphanChild = 0 -} - -type SwigcptrOrphanChild uintptr - -func (p SwigcptrOrphanChild) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrOrphanChild) SwigIsOrphanChild() { -} - -func (p SwigcptrOrphanChild) DirectorInterface() interface{} { - return nil -} - -var _wrap_new_OrphanChild unsafe.Pointer - -func _swig_wrap_new_OrphanChild() (base SwigcptrOrphanChild) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_OrphanChild, _swig_p) - return -} - -func NewOrphanChild() (_swig_ret OrphanChild) { - return _swig_wrap_new_OrphanChild() -} - -var _wrap_delete_OrphanChild unsafe.Pointer - -func _swig_wrap_delete_OrphanChild(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_OrphanChild, _swig_p) - return -} - -func DeleteOrphanChild(arg1 OrphanChild) { - _swig_wrap_delete_OrphanChild(arg1.Swigcptr()) -} - -var _wrap_OrphanChild_id unsafe.Pointer - -func _swig_wrap_OrphanChild_id(base SwigcptrOrphanChild) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_OrphanChild_id, _swig_p) - return -} - -func (_swig_base SwigcptrOrphanChild) Id() (_swig_ret string) { - return _swig_wrap_OrphanChild_id(_swig_base) -} - -func (p SwigcptrOrphanChild) SwigIsChild() { -} - -func (p SwigcptrOrphanChild) SwigGetChild() Child { - return SwigcptrChild(p.Swigcptr()) -} - -func (p SwigcptrOrphanChild) SwigIsPerson() { -} - -func (p SwigcptrOrphanChild) SwigGetPerson() Person { - return SwigcptrPerson(p.Swigcptr()) -} - -func (p SwigcptrOrphanChild) SwigIsBeing() { -} - -func (p SwigcptrOrphanChild) SwigGetBeing() Being { - return SwigcptrBeing(p.Swigcptr()) -} - -type OrphanChild interface { - Swigcptr() uintptr - SwigIsOrphanChild() - DirectorInterface() interface{} - Id() (_swig_ret string) - SwigIsChild() - SwigGetChild() Child - SwigIsPerson() - SwigGetPerson() Person - SwigIsBeing() - SwigGetBeing() Being -} - -type SwigcptrCaller uintptr - -func (p SwigcptrCaller) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrCaller) SwigIsCaller() { -} - -func (p SwigcptrCaller) DirectorInterface() interface{} { - return nil -} - -var _wrap_new_Caller unsafe.Pointer - -func _swig_wrap_new_Caller() (base SwigcptrCaller) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Caller, _swig_p) - return -} - -func NewCaller() (_swig_ret Caller) { - return _swig_wrap_new_Caller() -} - -var _wrap_delete_Caller unsafe.Pointer - -func _swig_wrap_delete_Caller(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Caller, _swig_p) - return -} - -func DeleteCaller(arg1 Caller) { - _swig_wrap_delete_Caller(arg1.Swigcptr()) -} - -var _wrap_Caller_delCallback unsafe.Pointer - -func _swig_wrap_Caller_delCallback(base SwigcptrCaller) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Caller_delCallback, _swig_p) - return -} - -func (arg1 SwigcptrCaller) DelCallback() { - _swig_wrap_Caller_delCallback(arg1) -} - -var _wrap_Caller_setCallback unsafe.Pointer - -func _swig_wrap_Caller_setCallback(base SwigcptrCaller, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Caller_setCallback, _swig_p) - return -} - -func (arg1 SwigcptrCaller) SetCallback(arg2 Person) { - _swig_wrap_Caller_setCallback(arg1, arg2.Swigcptr()) -} - -var _wrap_Caller_resetCallback unsafe.Pointer - -func _swig_wrap_Caller_resetCallback(base SwigcptrCaller) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Caller_resetCallback, _swig_p) - return -} - -func (arg1 SwigcptrCaller) ResetCallback() { - _swig_wrap_Caller_resetCallback(arg1) -} - -var _wrap_Caller_call unsafe.Pointer - -func _swig_wrap_Caller_call(base SwigcptrCaller) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Caller_call, _swig_p) - return -} - -func (arg1 SwigcptrCaller) Call() (_swig_ret string) { - return _swig_wrap_Caller_call(arg1) -} - -var _wrap_Caller_baseClass unsafe.Pointer - -func _swig_wrap_Caller_baseClass(base SwigcptrCaller) (_ SwigcptrPerson) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Caller_baseClass, _swig_p) - return -} - -func (arg1 SwigcptrCaller) BaseClass() (_swig_ret Person) { - return _swig_wrap_Caller_baseClass(arg1) -} - -type Caller interface { - Swigcptr() uintptr - SwigIsCaller() - DirectorInterface() interface{} - DelCallback() - SetCallback(arg2 Person) - ResetCallback() - Call() (_swig_ret string) - BaseClass() (_swig_ret Person) -} - - -type SwigcptrSwigDirector_Being uintptr -type SwigDirector_Being interface { - Swigcptr() uintptr; -} -func (p SwigcptrSwigDirector_Being) Swigcptr() uintptr { - return uintptr(p) -} - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - -type SwigcptrSwigDirector_GrandChild uintptr -type SwigDirector_GrandChild interface { - Swigcptr() uintptr; -} -func (p SwigcptrSwigDirector_GrandChild) Swigcptr() uintptr { - return uintptr(p) -} - -type SwigcptrSwigDirector_Person uintptr -type SwigDirector_Person interface { - Swigcptr() uintptr; -} -func (p SwigcptrSwigDirector_Person) Swigcptr() uintptr { - return uintptr(p) -} - -type SwigcptrSwigDirector_OrphanChild uintptr -type SwigDirector_OrphanChild interface { - Swigcptr() uintptr; -} -func (p SwigcptrSwigDirector_OrphanChild) Swigcptr() uintptr { - return uintptr(p) -} - -type SwigcptrSwigDirector_Child uintptr -type SwigDirector_Child interface { - Swigcptr() uintptr; -} -func (p SwigcptrSwigDirector_Child) Swigcptr() uintptr { - return uintptr(p) -} - -type SwigcptrSwigDirector_OrphanPerson uintptr -type SwigDirector_OrphanPerson interface { - Swigcptr() uintptr; -} -func (p SwigcptrSwigDirector_OrphanPerson) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/director_classic_runme b/Examples/test-suite/go/director_classic_runme deleted file mode 100755 index 1f6f65c94..000000000 Binary files a/Examples/test-suite/go/director_classic_runme and /dev/null differ diff --git a/Examples/test-suite/go/director_classic_wrap.h b/Examples/test-suite/go/director_classic_wrap.h deleted file mode 100644 index b316c893f..000000000 --- a/Examples/test-suite/go/director_classic_wrap.h +++ /dev/null @@ -1,94 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../director_classic.i - -#ifndef SWIG_director_classic_WRAP_H_ -#define SWIG_director_classic_WRAP_H_ - -class SwigDirector_Being : public Being -{ - public: - SwigDirector_Being(void *swig_p); - std::string _swig_upcall_id() { - return Being::id(); - } - virtual std::string id(); - virtual ~SwigDirector_Being(); - private: - void *go_val; -}; - -class SwigDirector_Person : public Person -{ - public: - SwigDirector_Person(void *swig_p); - std::string _swig_upcall_id() { - return Person::id(); - } - virtual std::string id(); - virtual ~SwigDirector_Person(); - private: - void *go_val; -}; - -class SwigDirector_Child : public Child -{ - public: - SwigDirector_Child(void *swig_p); - std::string _swig_upcall_id() { - return Child::id(); - } - virtual std::string id(); - virtual ~SwigDirector_Child(); - private: - void *go_val; -}; - -class SwigDirector_GrandChild : public GrandChild -{ - public: - SwigDirector_GrandChild(void *swig_p); - std::string _swig_upcall_id() { - return GrandChild::id(); - } - virtual std::string id(); - virtual ~SwigDirector_GrandChild(); - private: - void *go_val; -}; - -class SwigDirector_OrphanPerson : public OrphanPerson -{ - public: - SwigDirector_OrphanPerson(void *swig_p); - std::string _swig_upcall_id() { - return Person::id(); - } - virtual std::string id(); - virtual ~SwigDirector_OrphanPerson(); - private: - void *go_val; -}; - -class SwigDirector_OrphanChild : public OrphanChild -{ - public: - SwigDirector_OrphanChild(void *swig_p); - std::string _swig_upcall_id() { - return Child::id(); - } - virtual std::string id(); - virtual ~SwigDirector_OrphanChild(); - private: - void *go_val; -}; - -#endif diff --git a/Examples/test-suite/go/director_constructor.go b/Examples/test-suite/go/director_constructor.go deleted file mode 100644 index 2c6edcb45..000000000 --- a/Examples/test-suite/go/director_constructor.go +++ /dev/null @@ -1,290 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../director_constructor.i - -package director_constructor - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type _swig_DirectorFoo struct { - SwigcptrFoo - v interface{} -} - -func (p *_swig_DirectorFoo) Swigcptr() uintptr { - return p.SwigcptrFoo.Swigcptr() -} - -func (p *_swig_DirectorFoo) SwigIsFoo() { -} - -func (p *_swig_DirectorFoo) DirectorInterface() interface{} { - return p.v -} - -var _wrap__swig_NewDirectorFooFoo unsafe.Pointer - -func _swig_NewDirectorFooFoo(_swig_director *_swig_DirectorFoo, _ int) (_swig_ret SwigcptrFoo) { - _swig_p := uintptr(unsafe.Pointer(&_swig_director)) - _cgo_runtime_cgocall(_wrap__swig_NewDirectorFooFoo, _swig_p) - return -} - -func NewDirectorFoo(v interface{}, arg1 int) Foo { - p := &_swig_DirectorFoo{0, v} - p.SwigcptrFoo = _swig_NewDirectorFooFoo(p, arg1) - return p -} - -var _wrap_DeleteDirectorFoo unsafe.Pointer - -func _swig_wrap_DeleteDirectorFoo(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_DeleteDirectorFoo, _swig_p) - return -} - -func DeleteDirectorFoo(arg1 Foo) { - _swig_wrap_DeleteDirectorFoo(arg1.Swigcptr()) -} - -func Swiggo_DeleteDirector_Foo(p *_swig_DirectorFoo) { - p.SwigcptrFoo = 0 -} - -type _swig_DirectorInterfaceFooGetit interface { - Getit() int -} - -var _wrap__swig_DirectorFoo_upcall_Getit unsafe.Pointer - -func _swig_wrap__swig_DirectorFoo_upcall_Getit(_swig_ptr SwigcptrFoo) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) - _cgo_runtime_cgocall(_wrap__swig_DirectorFoo_upcall_Getit, _swig_p) - return -} - -func (swig_p *_swig_DirectorFoo) Getit() int { - if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceFooGetit); swig_ok { - return swig_g.Getit() - } - var swig_r int - swig_r = _swig_wrap__swig_DirectorFoo_upcall_Getit(swig_p.SwigcptrFoo) - return swig_r -} - -func DirectorFooGetit(p Foo) int { - var swig_r int - swig_r = _swig_wrap__swig_DirectorFoo_upcall_Getit(p.(*_swig_DirectorFoo).SwigcptrFoo) - return swig_r -} - -func Swig_DirectorFoo_callback_getit(p *_swig_DirectorFoo) (swig_result int) { - var swig_r int - swig_r = p.Getit() - return swig_r -} - -type _swig_DirectorInterfaceFooDoubleit interface { - Doubleit() -} - -var _wrap__swig_DirectorFoo_upcall_Doubleit unsafe.Pointer - -func _swig_wrap__swig_DirectorFoo_upcall_Doubleit(_swig_ptr SwigcptrFoo) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) - _cgo_runtime_cgocall(_wrap__swig_DirectorFoo_upcall_Doubleit, _swig_p) - return -} - -func (swig_p *_swig_DirectorFoo) Doubleit() { - if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceFooDoubleit); swig_ok { - swig_g.Doubleit() - return - } - _swig_wrap__swig_DirectorFoo_upcall_Doubleit(swig_p.SwigcptrFoo) -} - -func DirectorFooDoubleit(p Foo) { - _swig_wrap__swig_DirectorFoo_upcall_Doubleit(p.(*_swig_DirectorFoo).SwigcptrFoo) -} - -func Swig_DirectorFoo_callback_doubleit(p *_swig_DirectorFoo) { - p.Doubleit() -} - -type _swig_DirectorInterfaceFooTest interface { - Test() int -} - -func (swig_p *_swig_DirectorFoo) Test() int { - if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceFooTest); swig_ok { - return swig_g.Test() - } - panic("call to pure virtual method") -} - -func Swig_DirectorFoo_callback_test(p *_swig_DirectorFoo) (swig_result int) { - var swig_r int - swig_r = p.Test() - return swig_r -} - -type SwigcptrFoo uintptr - -func (p SwigcptrFoo) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrFoo) SwigIsFoo() { -} - -func (p SwigcptrFoo) DirectorInterface() interface{} { - return nil -} - -var _wrap_Foo_a_set unsafe.Pointer - -func _swig_wrap_Foo_a_set(base SwigcptrFoo, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_a_set, _swig_p) - return -} - -func (arg1 SwigcptrFoo) SetA(arg2 int) { - _swig_wrap_Foo_a_set(arg1, arg2) -} - -var _wrap_Foo_a_get unsafe.Pointer - -func _swig_wrap_Foo_a_get(base SwigcptrFoo) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_a_get, _swig_p) - return -} - -func (arg1 SwigcptrFoo) GetA() (_swig_ret int) { - return _swig_wrap_Foo_a_get(arg1) -} - -var _wrap_new_Foo unsafe.Pointer - -func _swig_wrap_new_Foo(base int) (_ SwigcptrFoo) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Foo, _swig_p) - return -} - -func NewFoo(arg1 int) (_swig_ret Foo) { - return _swig_wrap_new_Foo(arg1) -} - -var _wrap_delete_Foo unsafe.Pointer - -func _swig_wrap_delete_Foo(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Foo, _swig_p) - return -} - -func DeleteFoo(arg1 Foo) { - _swig_wrap_delete_Foo(arg1.Swigcptr()) -} - -var _wrap_Foo_do_test unsafe.Pointer - -func _swig_wrap_Foo_do_test(base SwigcptrFoo) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_do_test, _swig_p) - return -} - -func (arg1 SwigcptrFoo) Do_test() (_swig_ret int) { - return _swig_wrap_Foo_do_test(arg1) -} - -var _wrap_Foo_getit unsafe.Pointer - -func _swig_wrap_Foo_getit(base SwigcptrFoo) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_getit, _swig_p) - return -} - -func (arg1 SwigcptrFoo) Getit() (_swig_ret int) { - return _swig_wrap_Foo_getit(arg1) -} - -var _wrap_Foo_doubleit unsafe.Pointer - -func _swig_wrap_Foo_doubleit(base SwigcptrFoo) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_doubleit, _swig_p) - return -} - -func (arg1 SwigcptrFoo) Doubleit() { - _swig_wrap_Foo_doubleit(arg1) -} - -var _wrap_Foo_test unsafe.Pointer - -func _swig_wrap_Foo_test(base SwigcptrFoo) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_test, _swig_p) - return -} - -func (arg1 SwigcptrFoo) Test() (_swig_ret int) { - return _swig_wrap_Foo_test(arg1) -} - -type Foo interface { - Swigcptr() uintptr - SwigIsFoo() - DirectorInterface() interface{} - SetA(arg2 int) - GetA() (_swig_ret int) - Do_test() (_swig_ret int) - Getit() (_swig_ret int) - Doubleit() - Test() (_swig_ret int) -} - - -type SwigcptrSwigDirector_Foo uintptr -type SwigDirector_Foo interface { - Swigcptr() uintptr; -} -func (p SwigcptrSwigDirector_Foo) Swigcptr() uintptr { - return uintptr(p) -} - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/director_constructor_wrap.h b/Examples/test-suite/go/director_constructor_wrap.h deleted file mode 100644 index 814f687f0..000000000 --- a/Examples/test-suite/go/director_constructor_wrap.h +++ /dev/null @@ -1,34 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../director_constructor.i - -#ifndef SWIG_director_constructor_WRAP_H_ -#define SWIG_director_constructor_WRAP_H_ - -class SwigDirector_Foo : public Foo -{ - public: - SwigDirector_Foo(void *swig_p, int i); - virtual ~SwigDirector_Foo(); - int _swig_upcall_getit() { - return Foo::getit(); - } - virtual int getit(); - void _swig_upcall_doubleit() { - Foo::doubleit(); - } - virtual void doubleit(); - virtual int test(); - private: - void *go_val; -}; - -#endif diff --git a/Examples/test-suite/go/director_default.go b/Examples/test-suite/go/director_default.go deleted file mode 100644 index c87fdd35d..000000000 --- a/Examples/test-suite/go/director_default.go +++ /dev/null @@ -1,875 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../director_default.i - -package director_default - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type _swig_DirectorFoo struct { - SwigcptrFoo - v interface{} -} - -func (p *_swig_DirectorFoo) Swigcptr() uintptr { - return p.SwigcptrFoo.Swigcptr() -} - -func (p *_swig_DirectorFoo) SwigIsFoo() { -} - -func (p *_swig_DirectorFoo) DirectorInterface() interface{} { - return p.v -} - -var _wrap__swig_NewDirectorFooFoo__SWIG_0 unsafe.Pointer - -func _swig_NewDirectorFooFoo__SWIG_0(_swig_director *_swig_DirectorFoo, _ int) (_swig_ret SwigcptrFoo) { - _swig_p := uintptr(unsafe.Pointer(&_swig_director)) - _cgo_runtime_cgocall(_wrap__swig_NewDirectorFooFoo__SWIG_0, _swig_p) - return -} - -func NewDirectorFoo__SWIG_0(v interface{}, arg1 int) Foo { - p := &_swig_DirectorFoo{0, v} - p.SwigcptrFoo = _swig_NewDirectorFooFoo__SWIG_0(p, arg1) - return p -} - -var _wrap__swig_NewDirectorFooFoo__SWIG_1 unsafe.Pointer - -func _swig_NewDirectorFooFoo__SWIG_1(_swig_director *_swig_DirectorFoo) (_swig_ret SwigcptrFoo) { - _swig_p := uintptr(unsafe.Pointer(&_swig_director)) - _cgo_runtime_cgocall(_wrap__swig_NewDirectorFooFoo__SWIG_1, _swig_p) - return -} - -func NewDirectorFoo__SWIG_1(v interface{}) Foo { - p := &_swig_DirectorFoo{0, v} - p.SwigcptrFoo = _swig_NewDirectorFooFoo__SWIG_1(p) - return p -} - -func NewDirectorFoo(abi interface{}, a ...interface{}) Foo { - argc := len(a) - if argc == 0 { - return NewDirectorFoo__SWIG_1(abi) - } - if argc == 1 { - return NewDirectorFoo__SWIG_0(abi, a[0].(int)) - } - panic("No match for overloaded function call") -} - -var _wrap_DeleteDirectorFoo unsafe.Pointer - -func _swig_wrap_DeleteDirectorFoo(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_DeleteDirectorFoo, _swig_p) - return -} - -func DeleteDirectorFoo(arg1 Foo) { - _swig_wrap_DeleteDirectorFoo(arg1.Swigcptr()) -} - -func Swiggo_DeleteDirector_Foo(p *_swig_DirectorFoo) { - p.SwigcptrFoo = 0 -} - -type _swig_DirectorInterfaceFooMsg__SWIG_0 interface { - Msg__SWIG_0(string) string -} - -var _wrap__swig_DirectorFoo_upcall_Msg__SWIG_0 unsafe.Pointer - -func _swig_wrap__swig_DirectorFoo_upcall_Msg__SWIG_0(_swig_ptr SwigcptrFoo, _ string) (_swig_ret string) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) - _cgo_runtime_cgocall(_wrap__swig_DirectorFoo_upcall_Msg__SWIG_0, _swig_p) - return -} - -func (swig_p *_swig_DirectorFoo) Msg__SWIG_0(msg string) string { - if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceFooMsg__SWIG_0); swig_ok { - return swig_g.Msg__SWIG_0(msg) - } - var swig_r string - swig_r = _swig_wrap__swig_DirectorFoo_upcall_Msg__SWIG_0(swig_p.SwigcptrFoo, msg) - return swig_r -} - -func DirectorFooMsg__SWIG_0(p Foo, arg2 string) string { - var swig_r string - swig_r = _swig_wrap__swig_DirectorFoo_upcall_Msg__SWIG_0(p.(*_swig_DirectorFoo).SwigcptrFoo, arg2) - return swig_r -} - -func Swig_DirectorFoo_callback_Msg__SWIG_0(p *_swig_DirectorFoo, arg2 string) (swig_result string) { - var swig_r string - swig_r = p.Msg__SWIG_0(arg2) - return swig_r -} - -type _swig_DirectorInterfaceFooMsg__SWIG_1 interface { - Msg__SWIG_1() string -} - -var _wrap__swig_DirectorFoo_upcall_Msg__SWIG_1 unsafe.Pointer - -func _swig_wrap__swig_DirectorFoo_upcall_Msg__SWIG_1(_swig_ptr SwigcptrFoo) (_swig_ret string) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) - _cgo_runtime_cgocall(_wrap__swig_DirectorFoo_upcall_Msg__SWIG_1, _swig_p) - return -} - -func (swig_p *_swig_DirectorFoo) Msg__SWIG_1() string { - if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceFooMsg__SWIG_1); swig_ok { - return swig_g.Msg__SWIG_1() - } - var swig_r string - swig_r = _swig_wrap__swig_DirectorFoo_upcall_Msg__SWIG_1(swig_p.SwigcptrFoo) - return swig_r -} - -func DirectorFooMsg__SWIG_1(p Foo) string { - var swig_r string - swig_r = _swig_wrap__swig_DirectorFoo_upcall_Msg__SWIG_1(p.(*_swig_DirectorFoo).SwigcptrFoo) - return swig_r -} - -func Swig_DirectorFoo_callback_Msg__SWIG_1(p *_swig_DirectorFoo) (swig_result string) { - var swig_r string - swig_r = p.Msg__SWIG_1() - return swig_r -} - -func (p _swig_DirectorFoo) Msg(a ...interface{}) string { - argc := len(a) - if argc == 0 { - return p.Msg__SWIG_1() - } - if argc == 1 { - return p.Msg__SWIG_0(a[0].(string)) - } - panic("No match for overloaded function call") -} - -func DirectorFooMsg(p *_swig_DirectorFoo, a ...interface{}) string { - argc := len(a) - if argc == 0 { - return DirectorFooMsg__SWIG_1(p) - } - if argc == 1 { - return DirectorFooMsg__SWIG_0(p, a[0].(string)) - } - panic("No match for overloaded function call") -} - -type SwigcptrFoo uintptr - -func (p SwigcptrFoo) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrFoo) SwigIsFoo() { -} - -func (p SwigcptrFoo) DirectorInterface() interface{} { - return nil -} - -var _wrap_new_Foo__SWIG_0 unsafe.Pointer - -func _swig_wrap_new_Foo__SWIG_0(base int) (_ SwigcptrFoo) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Foo__SWIG_0, _swig_p) - return -} - -func NewFoo__SWIG_0(arg1 int) (_swig_ret Foo) { - return _swig_wrap_new_Foo__SWIG_0(arg1) -} - -var _wrap_new_Foo__SWIG_1 unsafe.Pointer - -func _swig_wrap_new_Foo__SWIG_1() (base SwigcptrFoo) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Foo__SWIG_1, _swig_p) - return -} - -func NewFoo__SWIG_1() (_swig_ret Foo) { - return _swig_wrap_new_Foo__SWIG_1() -} - -func NewFoo(a ...interface{}) Foo { - argc := len(a) - if argc == 0 { - return NewFoo__SWIG_1() - } - if argc == 1 { - return NewFoo__SWIG_0(a[0].(int)) - } - panic("No match for overloaded function call") -} - -var _wrap_delete_Foo unsafe.Pointer - -func _swig_wrap_delete_Foo(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Foo, _swig_p) - return -} - -func DeleteFoo(arg1 Foo) { - _swig_wrap_delete_Foo(arg1.Swigcptr()) -} - -var _wrap_Foo_Msg__SWIG_0 unsafe.Pointer - -func _swig_wrap_Foo_Msg__SWIG_0(base SwigcptrFoo, _ string) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_Msg__SWIG_0, _swig_p) - return -} - -func (arg1 SwigcptrFoo) Msg__SWIG_0(arg2 string) (_swig_ret string) { - return _swig_wrap_Foo_Msg__SWIG_0(arg1, arg2) -} - -var _wrap_Foo_Msg__SWIG_1 unsafe.Pointer - -func _swig_wrap_Foo_Msg__SWIG_1(base SwigcptrFoo) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_Msg__SWIG_1, _swig_p) - return -} - -func (arg1 SwigcptrFoo) Msg__SWIG_1() (_swig_ret string) { - return _swig_wrap_Foo_Msg__SWIG_1(arg1) -} - -func (p SwigcptrFoo) Msg(a ...interface{}) string { - argc := len(a) - if argc == 0 { - return p.Msg__SWIG_1() - } - if argc == 1 { - return p.Msg__SWIG_0(a[0].(string)) - } - panic("No match for overloaded function call") -} - -var _wrap_Foo_GetMsg__SWIG_0 unsafe.Pointer - -func _swig_wrap_Foo_GetMsg__SWIG_0(base SwigcptrFoo) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_GetMsg__SWIG_0, _swig_p) - return -} - -func (arg1 SwigcptrFoo) GetMsg__SWIG_0() (_swig_ret string) { - return _swig_wrap_Foo_GetMsg__SWIG_0(arg1) -} - -var _wrap_Foo_GetMsg__SWIG_1 unsafe.Pointer - -func _swig_wrap_Foo_GetMsg__SWIG_1(base SwigcptrFoo, _ string) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_GetMsg__SWIG_1, _swig_p) - return -} - -func (arg1 SwigcptrFoo) GetMsg__SWIG_1(arg2 string) (_swig_ret string) { - return _swig_wrap_Foo_GetMsg__SWIG_1(arg1, arg2) -} - -func (p SwigcptrFoo) GetMsg(a ...interface{}) string { - argc := len(a) - if argc == 0 { - return p.GetMsg__SWIG_0() - } - if argc == 1 { - return p.GetMsg__SWIG_1(a[0].(string)) - } - panic("No match for overloaded function call") -} - -type Foo interface { - Swigcptr() uintptr - SwigIsFoo() - DirectorInterface() interface{} - Msg(a ...interface{}) string - GetMsg(a ...interface{}) string -} - -type SwigcptrBar uintptr - -func (p SwigcptrBar) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrBar) SwigIsBar() { -} - -var _wrap_new_Bar__SWIG_0 unsafe.Pointer - -func _swig_wrap_new_Bar__SWIG_0() (base SwigcptrBar) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Bar__SWIG_0, _swig_p) - return -} - -func NewBar__SWIG_0() (_swig_ret Bar) { - return _swig_wrap_new_Bar__SWIG_0() -} - -var _wrap_new_Bar__SWIG_1 unsafe.Pointer - -func _swig_wrap_new_Bar__SWIG_1(base int) (_ SwigcptrBar) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Bar__SWIG_1, _swig_p) - return -} - -func NewBar__SWIG_1(arg1 int) (_swig_ret Bar) { - return _swig_wrap_new_Bar__SWIG_1(arg1) -} - -func NewBar(a ...interface{}) Bar { - argc := len(a) - if argc == 0 { - return NewBar__SWIG_0() - } - if argc == 1 { - return NewBar__SWIG_1(a[0].(int)) - } - panic("No match for overloaded function call") -} - -var _wrap_delete_Bar unsafe.Pointer - -func _swig_wrap_delete_Bar(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Bar, _swig_p) - return -} - -func DeleteBar(arg1 Bar) { - _swig_wrap_delete_Bar(arg1.Swigcptr()) -} - -var _wrap_Bar_Msg__SWIG_0 unsafe.Pointer - -func _swig_wrap_Bar_Msg__SWIG_0(base SwigcptrBar, _ string) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Bar_Msg__SWIG_0, _swig_p) - return -} - -func (arg1 SwigcptrBar) Msg__SWIG_0(arg2 string) (_swig_ret string) { - return _swig_wrap_Bar_Msg__SWIG_0(arg1, arg2) -} - -var _wrap_Bar_Msg__SWIG_1 unsafe.Pointer - -func _swig_wrap_Bar_Msg__SWIG_1(base SwigcptrBar) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Bar_Msg__SWIG_1, _swig_p) - return -} - -func (arg1 SwigcptrBar) Msg__SWIG_1() (_swig_ret string) { - return _swig_wrap_Bar_Msg__SWIG_1(arg1) -} - -func (p SwigcptrBar) Msg(a ...interface{}) string { - argc := len(a) - if argc == 0 { - return p.Msg__SWIG_1() - } - if argc == 1 { - return p.Msg__SWIG_0(a[0].(string)) - } - panic("No match for overloaded function call") -} - -var _wrap_Bar_GetMsg__SWIG_0 unsafe.Pointer - -func _swig_wrap_Bar_GetMsg__SWIG_0(base SwigcptrBar) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Bar_GetMsg__SWIG_0, _swig_p) - return -} - -func (arg1 SwigcptrBar) GetMsg__SWIG_0() (_swig_ret string) { - return _swig_wrap_Bar_GetMsg__SWIG_0(arg1) -} - -var _wrap_Bar_GetMsg__SWIG_1 unsafe.Pointer - -func _swig_wrap_Bar_GetMsg__SWIG_1(base SwigcptrBar, _ string) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Bar_GetMsg__SWIG_1, _swig_p) - return -} - -func (arg1 SwigcptrBar) GetMsg__SWIG_1(arg2 string) (_swig_ret string) { - return _swig_wrap_Bar_GetMsg__SWIG_1(arg1, arg2) -} - -func (p SwigcptrBar) GetMsg(a ...interface{}) string { - argc := len(a) - if argc == 0 { - return p.GetMsg__SWIG_0() - } - if argc == 1 { - return p.GetMsg__SWIG_1(a[0].(string)) - } - panic("No match for overloaded function call") -} - -type Bar interface { - Swigcptr() uintptr - SwigIsBar() - Msg(a ...interface{}) string - GetMsg(a ...interface{}) string -} - -type _swig_DirectorDefaultsBase struct { - SwigcptrDefaultsBase - v interface{} -} - -func (p *_swig_DirectorDefaultsBase) Swigcptr() uintptr { - return p.SwigcptrDefaultsBase.Swigcptr() -} - -func (p *_swig_DirectorDefaultsBase) SwigIsDefaultsBase() { -} - -func (p *_swig_DirectorDefaultsBase) DirectorInterface() interface{} { - return p.v -} - -var _wrap__swig_NewDirectorDefaultsBaseDefaultsBase unsafe.Pointer - -func _swig_NewDirectorDefaultsBaseDefaultsBase(_swig_director *_swig_DirectorDefaultsBase) (_swig_ret SwigcptrDefaultsBase) { - _swig_p := uintptr(unsafe.Pointer(&_swig_director)) - _cgo_runtime_cgocall(_wrap__swig_NewDirectorDefaultsBaseDefaultsBase, _swig_p) - return -} - -func NewDirectorDefaultsBase(v interface{}) DefaultsBase { - p := &_swig_DirectorDefaultsBase{0, v} - p.SwigcptrDefaultsBase = _swig_NewDirectorDefaultsBaseDefaultsBase(p) - return p -} - -type _swig_DirectorInterfaceDefaultsBaseDefaultargs__SWIG_0 interface { - Defaultargs__SWIG_0(float64, *int) *int -} - -func (swig_p *_swig_DirectorDefaultsBase) Defaultargs__SWIG_0(d float64, a *int) *int { - if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceDefaultsBaseDefaultargs__SWIG_0); swig_ok { - return swig_g.Defaultargs__SWIG_0(d, a) - } - panic("call to pure virtual method") -} - -func Swig_DirectorDefaultsBase_callback_defaultargs__SWIG_0(p *_swig_DirectorDefaultsBase, d float64, a *int) (swig_result *int) { - var swig_r *int - swig_r = p.Defaultargs__SWIG_0(d, a) - return swig_r -} - -type _swig_DirectorInterfaceDefaultsBaseDefaultargs__SWIG_1 interface { - Defaultargs__SWIG_1(float64) *int -} - -func (swig_p *_swig_DirectorDefaultsBase) Defaultargs__SWIG_1(d float64) *int { - if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceDefaultsBaseDefaultargs__SWIG_1); swig_ok { - return swig_g.Defaultargs__SWIG_1(d) - } - panic("call to pure virtual method") -} - -func Swig_DirectorDefaultsBase_callback_defaultargs__SWIG_1(p *_swig_DirectorDefaultsBase, d float64) (swig_result *int) { - var swig_r *int - swig_r = p.Defaultargs__SWIG_1(d) - return swig_r -} - -func (p _swig_DirectorDefaultsBase) Defaultargs(a ...interface{}) *int { - argc := len(a) - if argc == 1 { - return p.Defaultargs__SWIG_1(a[0].(float64)) - } - if argc == 2 { - return p.Defaultargs__SWIG_0(a[0].(float64), a[1].(*int)) - } - panic("No match for overloaded function call") -} - -var _wrap_DeleteDirectorDefaultsBase unsafe.Pointer - -func _swig_wrap_DeleteDirectorDefaultsBase(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_DeleteDirectorDefaultsBase, _swig_p) - return -} - -func DeleteDirectorDefaultsBase(arg1 DefaultsBase) { - _swig_wrap_DeleteDirectorDefaultsBase(arg1.Swigcptr()) -} - -func Swiggo_DeleteDirector_DefaultsBase(p *_swig_DirectorDefaultsBase) { - p.SwigcptrDefaultsBase = 0 -} - -type SwigcptrDefaultsBase uintptr - -func (p SwigcptrDefaultsBase) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrDefaultsBase) SwigIsDefaultsBase() { -} - -func (p SwigcptrDefaultsBase) DirectorInterface() interface{} { - return nil -} - -var _wrap_DefaultsBase_defaultargs__SWIG_0 unsafe.Pointer - -func _swig_wrap_DefaultsBase_defaultargs__SWIG_0(base SwigcptrDefaultsBase, _ float64, _ *int) (_ *int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_DefaultsBase_defaultargs__SWIG_0, _swig_p) - return -} - -func (arg1 SwigcptrDefaultsBase) Defaultargs__SWIG_0(arg2 float64, arg3 *int) (_swig_ret *int) { - return _swig_wrap_DefaultsBase_defaultargs__SWIG_0(arg1, arg2, arg3) -} - -var _wrap_DefaultsBase_defaultargs__SWIG_1 unsafe.Pointer - -func _swig_wrap_DefaultsBase_defaultargs__SWIG_1(base SwigcptrDefaultsBase, _ float64) (_ *int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_DefaultsBase_defaultargs__SWIG_1, _swig_p) - return -} - -func (arg1 SwigcptrDefaultsBase) Defaultargs__SWIG_1(arg2 float64) (_swig_ret *int) { - return _swig_wrap_DefaultsBase_defaultargs__SWIG_1(arg1, arg2) -} - -func (p SwigcptrDefaultsBase) Defaultargs(a ...interface{}) *int { - argc := len(a) - if argc == 1 { - return p.Defaultargs__SWIG_1(a[0].(float64)) - } - if argc == 2 { - return p.Defaultargs__SWIG_0(a[0].(float64), a[1].(*int)) - } - panic("No match for overloaded function call") -} - -var _wrap_delete_DefaultsBase unsafe.Pointer - -func _swig_wrap_delete_DefaultsBase(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_DefaultsBase, _swig_p) - return -} - -func DeleteDefaultsBase(arg1 DefaultsBase) { - _swig_wrap_delete_DefaultsBase(arg1.Swigcptr()) -} - -var _wrap_new_DefaultsBase unsafe.Pointer - -func _swig_wrap_new_DefaultsBase() (base SwigcptrDefaultsBase) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_DefaultsBase, _swig_p) - return -} - -func NewDefaultsBase() (_swig_ret DefaultsBase) { - return _swig_wrap_new_DefaultsBase() -} - -type DefaultsBase interface { - Swigcptr() uintptr - SwigIsDefaultsBase() - DirectorInterface() interface{} - Defaultargs(a ...interface{}) *int -} - -type _swig_DirectorDefaultsDerived struct { - SwigcptrDefaultsDerived - v interface{} -} - -func (p *_swig_DirectorDefaultsDerived) Swigcptr() uintptr { - return p.SwigcptrDefaultsDerived.Swigcptr() -} - -func (p *_swig_DirectorDefaultsDerived) SwigIsDefaultsDerived() { -} - -func (p *_swig_DirectorDefaultsDerived) DirectorInterface() interface{} { - return p.v -} - -var _wrap__swig_NewDirectorDefaultsDerivedDefaultsDerived unsafe.Pointer - -func _swig_NewDirectorDefaultsDerivedDefaultsDerived(_swig_director *_swig_DirectorDefaultsDerived) (_swig_ret SwigcptrDefaultsDerived) { - _swig_p := uintptr(unsafe.Pointer(&_swig_director)) - _cgo_runtime_cgocall(_wrap__swig_NewDirectorDefaultsDerivedDefaultsDerived, _swig_p) - return -} - -func NewDirectorDefaultsDerived(v interface{}) DefaultsDerived { - p := &_swig_DirectorDefaultsDerived{0, v} - p.SwigcptrDefaultsDerived = _swig_NewDirectorDefaultsDerivedDefaultsDerived(p) - return p -} - -type _swig_DirectorInterfaceDefaultsDerivedDefaultargs__SWIG_0 interface { - Defaultargs__SWIG_0(float64, *int) *int -} - -var _wrap__swig_DirectorDefaultsDerived_upcall_Defaultargs__SWIG_0 unsafe.Pointer - -func _swig_wrap__swig_DirectorDefaultsDerived_upcall_Defaultargs__SWIG_0(_swig_ptr SwigcptrDefaultsDerived, _ float64, _ *int) (_swig_ret *int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) - _cgo_runtime_cgocall(_wrap__swig_DirectorDefaultsDerived_upcall_Defaultargs__SWIG_0, _swig_p) - return -} - -func (swig_p *_swig_DirectorDefaultsDerived) Defaultargs__SWIG_0(d float64, a *int) *int { - if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceDefaultsDerivedDefaultargs__SWIG_0); swig_ok { - return swig_g.Defaultargs__SWIG_0(d, a) - } - var swig_r *int - swig_r = _swig_wrap__swig_DirectorDefaultsDerived_upcall_Defaultargs__SWIG_0(swig_p.SwigcptrDefaultsDerived, d, a) - return swig_r -} - -func DirectorDefaultsDerivedDefaultargs__SWIG_0(p DefaultsDerived, arg2 float64, arg3 *int) *int { - var swig_r *int - swig_r = _swig_wrap__swig_DirectorDefaultsDerived_upcall_Defaultargs__SWIG_0(p.(*_swig_DirectorDefaultsDerived).SwigcptrDefaultsDerived, arg2, arg3) - return swig_r -} - -func Swig_DirectorDefaultsDerived_callback_defaultargs__SWIG_0(p *_swig_DirectorDefaultsDerived, arg2 float64, arg3 *int) (swig_result *int) { - var swig_r *int - swig_r = p.Defaultargs__SWIG_0(arg2, arg3) - return swig_r -} - -type _swig_DirectorInterfaceDefaultsDerivedDefaultargs__SWIG_1 interface { - Defaultargs__SWIG_1(float64) *int -} - -var _wrap__swig_DirectorDefaultsDerived_upcall_Defaultargs__SWIG_1 unsafe.Pointer - -func _swig_wrap__swig_DirectorDefaultsDerived_upcall_Defaultargs__SWIG_1(_swig_ptr SwigcptrDefaultsDerived, _ float64) (_swig_ret *int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) - _cgo_runtime_cgocall(_wrap__swig_DirectorDefaultsDerived_upcall_Defaultargs__SWIG_1, _swig_p) - return -} - -func (swig_p *_swig_DirectorDefaultsDerived) Defaultargs__SWIG_1(d float64) *int { - if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceDefaultsDerivedDefaultargs__SWIG_1); swig_ok { - return swig_g.Defaultargs__SWIG_1(d) - } - var swig_r *int - swig_r = _swig_wrap__swig_DirectorDefaultsDerived_upcall_Defaultargs__SWIG_1(swig_p.SwigcptrDefaultsDerived, d) - return swig_r -} - -func DirectorDefaultsDerivedDefaultargs__SWIG_1(p DefaultsDerived, arg2 float64) *int { - var swig_r *int - swig_r = _swig_wrap__swig_DirectorDefaultsDerived_upcall_Defaultargs__SWIG_1(p.(*_swig_DirectorDefaultsDerived).SwigcptrDefaultsDerived, arg2) - return swig_r -} - -func Swig_DirectorDefaultsDerived_callback_defaultargs__SWIG_1(p *_swig_DirectorDefaultsDerived, arg2 float64) (swig_result *int) { - var swig_r *int - swig_r = p.Defaultargs__SWIG_1(arg2) - return swig_r -} - -func (p _swig_DirectorDefaultsDerived) Defaultargs(a ...interface{}) *int { - argc := len(a) - if argc == 1 { - return p.Defaultargs__SWIG_1(a[0].(float64)) - } - if argc == 2 { - return p.Defaultargs__SWIG_0(a[0].(float64), a[1].(*int)) - } - panic("No match for overloaded function call") -} - -func DirectorDefaultsDerivedDefaultargs(p *_swig_DirectorDefaultsDerived, a ...interface{}) *int { - argc := len(a) - if argc == 1 { - return DirectorDefaultsDerivedDefaultargs__SWIG_1(p, a[0].(float64)) - } - if argc == 2 { - return DirectorDefaultsDerivedDefaultargs__SWIG_0(p, a[0].(float64), a[1].(*int)) - } - panic("No match for overloaded function call") -} - -var _wrap_DeleteDirectorDefaultsDerived unsafe.Pointer - -func _swig_wrap_DeleteDirectorDefaultsDerived(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_DeleteDirectorDefaultsDerived, _swig_p) - return -} - -func DeleteDirectorDefaultsDerived(arg1 DefaultsDerived) { - _swig_wrap_DeleteDirectorDefaultsDerived(arg1.Swigcptr()) -} - -func Swiggo_DeleteDirector_DefaultsDerived(p *_swig_DirectorDefaultsDerived) { - p.SwigcptrDefaultsDerived = 0 -} - -type SwigcptrDefaultsDerived uintptr - -func (p SwigcptrDefaultsDerived) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrDefaultsDerived) SwigIsDefaultsDerived() { -} - -func (p SwigcptrDefaultsDerived) DirectorInterface() interface{} { - return nil -} - -var _wrap_DefaultsDerived_defaultargs__SWIG_0 unsafe.Pointer - -func _swig_wrap_DefaultsDerived_defaultargs__SWIG_0(base SwigcptrDefaultsDerived, _ float64, _ *int) (_ *int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_DefaultsDerived_defaultargs__SWIG_0, _swig_p) - return -} - -func (arg1 SwigcptrDefaultsDerived) Defaultargs__SWIG_0(arg2 float64, arg3 *int) (_swig_ret *int) { - return _swig_wrap_DefaultsDerived_defaultargs__SWIG_0(arg1, arg2, arg3) -} - -var _wrap_DefaultsDerived_defaultargs__SWIG_1 unsafe.Pointer - -func _swig_wrap_DefaultsDerived_defaultargs__SWIG_1(base SwigcptrDefaultsDerived, _ float64) (_ *int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_DefaultsDerived_defaultargs__SWIG_1, _swig_p) - return -} - -func (arg1 SwigcptrDefaultsDerived) Defaultargs__SWIG_1(arg2 float64) (_swig_ret *int) { - return _swig_wrap_DefaultsDerived_defaultargs__SWIG_1(arg1, arg2) -} - -func (p SwigcptrDefaultsDerived) Defaultargs(a ...interface{}) *int { - argc := len(a) - if argc == 1 { - return p.Defaultargs__SWIG_1(a[0].(float64)) - } - if argc == 2 { - return p.Defaultargs__SWIG_0(a[0].(float64), a[1].(*int)) - } - panic("No match for overloaded function call") -} - -var _wrap_new_DefaultsDerived unsafe.Pointer - -func _swig_wrap_new_DefaultsDerived() (base SwigcptrDefaultsDerived) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_DefaultsDerived, _swig_p) - return -} - -func NewDefaultsDerived() (_swig_ret DefaultsDerived) { - return _swig_wrap_new_DefaultsDerived() -} - -var _wrap_delete_DefaultsDerived unsafe.Pointer - -func _swig_wrap_delete_DefaultsDerived(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_DefaultsDerived, _swig_p) - return -} - -func DeleteDefaultsDerived(arg1 DefaultsDerived) { - _swig_wrap_delete_DefaultsDerived(arg1.Swigcptr()) -} - -func (p SwigcptrDefaultsDerived) SwigIsDefaultsBase() { -} - -func (p SwigcptrDefaultsDerived) SwigGetDefaultsBase() DefaultsBase { - return SwigcptrDefaultsBase(p.Swigcptr()) -} - -type DefaultsDerived interface { - Swigcptr() uintptr - SwigIsDefaultsDerived() - DirectorInterface() interface{} - Defaultargs(a ...interface{}) *int - SwigIsDefaultsBase() - SwigGetDefaultsBase() DefaultsBase -} - - -type SwigcptrSwigDirector_Foo uintptr -type SwigDirector_Foo interface { - Swigcptr() uintptr; -} -func (p SwigcptrSwigDirector_Foo) Swigcptr() uintptr { - return uintptr(p) -} - -type SwigcptrSwigDirector_DefaultsDerived uintptr -type SwigDirector_DefaultsDerived interface { - Swigcptr() uintptr; -} -func (p SwigcptrSwigDirector_DefaultsDerived) Swigcptr() uintptr { - return uintptr(p) -} - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/director_default_runme b/Examples/test-suite/go/director_default_runme deleted file mode 100755 index 3e4a374b8..000000000 Binary files a/Examples/test-suite/go/director_default_runme and /dev/null differ diff --git a/Examples/test-suite/go/director_default_wrap.h b/Examples/test-suite/go/director_default_wrap.h deleted file mode 100644 index 7426b727d..000000000 --- a/Examples/test-suite/go/director_default_wrap.h +++ /dev/null @@ -1,62 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../director_default.i - -#ifndef SWIG_director_default_WRAP_H_ -#define SWIG_director_default_WRAP_H_ - -class SwigDirector_Foo : public Foo -{ - public: - SwigDirector_Foo(void *swig_p, int i); - SwigDirector_Foo(void *swig_p); - virtual ~SwigDirector_Foo(); - std::string _swig_upcall_Msg__SWIG_0(std::string msg) { - return Foo::Msg(msg); - } - virtual std::string Msg(std::string msg); - std::string _swig_upcall_Msg__SWIG_1() { - return Foo::Msg(); - } - virtual std::string Msg(); - private: - void *go_val; -}; - -class SwigDirector_DefaultsBase : public DefaultsBase -{ - public: - SwigDirector_DefaultsBase(void *swig_p); - virtual IntegerPtr defaultargs(double d, int *a); - virtual IntegerPtr defaultargs(double d); - virtual ~SwigDirector_DefaultsBase(); - private: - void *go_val; -}; - -class SwigDirector_DefaultsDerived : public DefaultsDerived -{ - public: - SwigDirector_DefaultsDerived(void *swig_p); - int *_swig_upcall_defaultargs__SWIG_0(Double d, IntegerPtr a) { - return DefaultsDerived::defaultargs(d,a); - } - virtual int *defaultargs(Double d, IntegerPtr a); - int *_swig_upcall_defaultargs__SWIG_1(Double d) { - return DefaultsDerived::defaultargs(d); - } - virtual int *defaultargs(Double d); - virtual ~SwigDirector_DefaultsDerived(); - private: - void *go_val; -}; - -#endif diff --git a/Examples/test-suite/go/director_detect.go b/Examples/test-suite/go/director_detect.go deleted file mode 100644 index 5148e4584..000000000 --- a/Examples/test-suite/go/director_detect.go +++ /dev/null @@ -1,581 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../director_detect.i - -package director_detect - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrA uintptr - -func (p SwigcptrA) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrA) SwigIsA() { -} - -var _wrap_new_A unsafe.Pointer - -func _swig_wrap_new_A() (base SwigcptrA) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_A, _swig_p) - return -} - -func NewA() (_swig_ret A) { - return _swig_wrap_new_A() -} - -var _wrap_delete_A unsafe.Pointer - -func _swig_wrap_delete_A(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_A, _swig_p) - return -} - -func DeleteA(arg1 A) { - _swig_wrap_delete_A(arg1.Swigcptr()) -} - -type A interface { - Swigcptr() uintptr - SwigIsA() -} - -type _swig_DirectorFoo struct { - SwigcptrFoo - v interface{} -} - -func (p *_swig_DirectorFoo) Swigcptr() uintptr { - return p.SwigcptrFoo.Swigcptr() -} - -func (p *_swig_DirectorFoo) SwigIsFoo() { -} - -func (p *_swig_DirectorFoo) DirectorInterface() interface{} { - return p.v -} - -var _wrap__swig_NewDirectorFooFoo unsafe.Pointer - -func _swig_NewDirectorFooFoo(_swig_director *_swig_DirectorFoo) (_swig_ret SwigcptrFoo) { - _swig_p := uintptr(unsafe.Pointer(&_swig_director)) - _cgo_runtime_cgocall(_wrap__swig_NewDirectorFooFoo, _swig_p) - return -} - -func NewDirectorFoo(v interface{}) Foo { - p := &_swig_DirectorFoo{0, v} - p.SwigcptrFoo = _swig_NewDirectorFooFoo(p) - return p -} - -var _wrap_DeleteDirectorFoo unsafe.Pointer - -func _swig_wrap_DeleteDirectorFoo(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_DeleteDirectorFoo, _swig_p) - return -} - -func DeleteDirectorFoo(arg1 Foo) { - _swig_wrap_DeleteDirectorFoo(arg1.Swigcptr()) -} - -func Swiggo_DeleteDirector_Foo(p *_swig_DirectorFoo) { - p.SwigcptrFoo = 0 -} - -type _swig_DirectorInterfaceFooCloner interface { - Cloner() Foo -} - -func (swig_p *_swig_DirectorFoo) Cloner() Foo { - if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceFooCloner); swig_ok { - return swig_g.Cloner() - } - panic("call to pure virtual method") -} - -func Swig_DirectorFoo_callback_cloner(p *_swig_DirectorFoo) (swig_result SwigcptrFoo) { - var swig_r SwigcptrFoo - swig_r = SwigcptrFoo(p.Cloner().Swigcptr()) - return swig_r -} - -type _swig_DirectorInterfaceFooGet_value interface { - Get_value() int -} - -func (swig_p *_swig_DirectorFoo) Get_value() int { - if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceFooGet_value); swig_ok { - return swig_g.Get_value() - } - panic("call to pure virtual method") -} - -func Swig_DirectorFoo_callback_get_value(p *_swig_DirectorFoo) (swig_result int) { - var swig_r int - swig_r = p.Get_value() - return swig_r -} - -type _swig_DirectorInterfaceFooGet_class interface { - Get_class() A -} - -func (swig_p *_swig_DirectorFoo) Get_class() A { - if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceFooGet_class); swig_ok { - return swig_g.Get_class() - } - panic("call to pure virtual method") -} - -func Swig_DirectorFoo_callback_get_class(p *_swig_DirectorFoo) (swig_result SwigcptrA) { - var swig_r SwigcptrA - swig_r = SwigcptrA(p.Get_class().Swigcptr()) - return swig_r -} - -type _swig_DirectorInterfaceFooJust_do_it interface { - Just_do_it() -} - -func (swig_p *_swig_DirectorFoo) Just_do_it() { - if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceFooJust_do_it); swig_ok { - swig_g.Just_do_it() - return - } - panic("call to pure virtual method") -} - -func Swig_DirectorFoo_callback_just_do_it(p *_swig_DirectorFoo) { - p.Just_do_it() -} - -type SwigcptrFoo uintptr - -func (p SwigcptrFoo) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrFoo) SwigIsFoo() { -} - -func (p SwigcptrFoo) DirectorInterface() interface{} { - return nil -} - -var _wrap_delete_Foo unsafe.Pointer - -func _swig_wrap_delete_Foo(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Foo, _swig_p) - return -} - -func DeleteFoo(arg1 Foo) { - _swig_wrap_delete_Foo(arg1.Swigcptr()) -} - -var _wrap_Foo_cloner unsafe.Pointer - -func _swig_wrap_Foo_cloner(base SwigcptrFoo) (_ SwigcptrFoo) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_cloner, _swig_p) - return -} - -func (arg1 SwigcptrFoo) Cloner() (_swig_ret Foo) { - return _swig_wrap_Foo_cloner(arg1) -} - -var _wrap_Foo_get_value unsafe.Pointer - -func _swig_wrap_Foo_get_value(base SwigcptrFoo) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_get_value, _swig_p) - return -} - -func (arg1 SwigcptrFoo) Get_value() (_swig_ret int) { - return _swig_wrap_Foo_get_value(arg1) -} - -var _wrap_Foo_get_class unsafe.Pointer - -func _swig_wrap_Foo_get_class(base SwigcptrFoo) (_ SwigcptrA) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_get_class, _swig_p) - return -} - -func (arg1 SwigcptrFoo) Get_class() (_swig_ret A) { - return _swig_wrap_Foo_get_class(arg1) -} - -var _wrap_Foo_just_do_it unsafe.Pointer - -func _swig_wrap_Foo_just_do_it(base SwigcptrFoo) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_just_do_it, _swig_p) - return -} - -func (arg1 SwigcptrFoo) Just_do_it() { - _swig_wrap_Foo_just_do_it(arg1) -} - -var _wrap_new_Foo unsafe.Pointer - -func _swig_wrap_new_Foo() (base SwigcptrFoo) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Foo, _swig_p) - return -} - -func NewFoo() (_swig_ret Foo) { - return _swig_wrap_new_Foo() -} - -type Foo interface { - Swigcptr() uintptr - SwigIsFoo() - DirectorInterface() interface{} - Cloner() (_swig_ret Foo) - Get_value() (_swig_ret int) - Get_class() (_swig_ret A) - Just_do_it() -} - -type _swig_DirectorBar struct { - SwigcptrBar - v interface{} -} - -func (p *_swig_DirectorBar) Swigcptr() uintptr { - return p.SwigcptrBar.Swigcptr() -} - -func (p *_swig_DirectorBar) SwigIsBar() { -} - -func (p *_swig_DirectorBar) DirectorInterface() interface{} { - return p.v -} - -var _wrap__swig_NewDirectorBarBar unsafe.Pointer - -func _swig_NewDirectorBarBar(_swig_director *_swig_DirectorBar) (_swig_ret SwigcptrBar) { - _swig_p := uintptr(unsafe.Pointer(&_swig_director)) - _cgo_runtime_cgocall(_wrap__swig_NewDirectorBarBar, _swig_p) - return -} - -func NewDirectorBar(v interface{}) Bar { - p := &_swig_DirectorBar{0, v} - p.SwigcptrBar = _swig_NewDirectorBarBar(p) - return p -} - -var _wrap_DeleteDirectorBar unsafe.Pointer - -func _swig_wrap_DeleteDirectorBar(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_DeleteDirectorBar, _swig_p) - return -} - -func DeleteDirectorBar(arg1 Bar) { - _swig_wrap_DeleteDirectorBar(arg1.Swigcptr()) -} - -func Swiggo_DeleteDirector_Bar(p *_swig_DirectorBar) { - p.SwigcptrBar = 0 -} - -type _swig_DirectorInterfaceBarCloner interface { - Cloner() Bar -} - -var _wrap__swig_DirectorBar_upcall_Cloner unsafe.Pointer - -func _swig_wrap__swig_DirectorBar_upcall_Cloner(_swig_ptr SwigcptrBar) (_swig_ret SwigcptrBar) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) - _cgo_runtime_cgocall(_wrap__swig_DirectorBar_upcall_Cloner, _swig_p) - return -} - -func (swig_p *_swig_DirectorBar) Cloner() Bar { - if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceBarCloner); swig_ok { - return swig_g.Cloner() - } - var swig_r Bar - swig_r = _swig_wrap__swig_DirectorBar_upcall_Cloner(swig_p.SwigcptrBar) - return swig_r -} - -func DirectorBarCloner(p Bar) Bar { - var swig_r Bar - swig_r = _swig_wrap__swig_DirectorBar_upcall_Cloner(p.(*_swig_DirectorBar).SwigcptrBar) - return swig_r -} - -func Swig_DirectorBar_callback_cloner(p *_swig_DirectorBar) (swig_result SwigcptrBar) { - var swig_r SwigcptrBar - swig_r = SwigcptrBar(p.Cloner().Swigcptr()) - return swig_r -} - -type _swig_DirectorInterfaceBarGet_value interface { - Get_value() int -} - -var _wrap__swig_DirectorBar_upcall_Get_value unsafe.Pointer - -func _swig_wrap__swig_DirectorBar_upcall_Get_value(_swig_ptr SwigcptrBar) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) - _cgo_runtime_cgocall(_wrap__swig_DirectorBar_upcall_Get_value, _swig_p) - return -} - -func (swig_p *_swig_DirectorBar) Get_value() int { - if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceBarGet_value); swig_ok { - return swig_g.Get_value() - } - var swig_r int - swig_r = _swig_wrap__swig_DirectorBar_upcall_Get_value(swig_p.SwigcptrBar) - return swig_r -} - -func DirectorBarGet_value(p Bar) int { - var swig_r int - swig_r = _swig_wrap__swig_DirectorBar_upcall_Get_value(p.(*_swig_DirectorBar).SwigcptrBar) - return swig_r -} - -func Swig_DirectorBar_callback_get_value(p *_swig_DirectorBar) (swig_result int) { - var swig_r int - swig_r = p.Get_value() - return swig_r -} - -type _swig_DirectorInterfaceBarGet_class interface { - Get_class() A -} - -var _wrap__swig_DirectorBar_upcall_Get_class unsafe.Pointer - -func _swig_wrap__swig_DirectorBar_upcall_Get_class(_swig_ptr SwigcptrBar) (_swig_ret SwigcptrA) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) - _cgo_runtime_cgocall(_wrap__swig_DirectorBar_upcall_Get_class, _swig_p) - return -} - -func (swig_p *_swig_DirectorBar) Get_class() A { - if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceBarGet_class); swig_ok { - return swig_g.Get_class() - } - var swig_r A - swig_r = _swig_wrap__swig_DirectorBar_upcall_Get_class(swig_p.SwigcptrBar) - return swig_r -} - -func DirectorBarGet_class(p Bar) A { - var swig_r A - swig_r = _swig_wrap__swig_DirectorBar_upcall_Get_class(p.(*_swig_DirectorBar).SwigcptrBar) - return swig_r -} - -func Swig_DirectorBar_callback_get_class(p *_swig_DirectorBar) (swig_result SwigcptrA) { - var swig_r SwigcptrA - swig_r = SwigcptrA(p.Get_class().Swigcptr()) - return swig_r -} - -type _swig_DirectorInterfaceBarJust_do_it interface { - Just_do_it() -} - -var _wrap__swig_DirectorBar_upcall_Just_do_it unsafe.Pointer - -func _swig_wrap__swig_DirectorBar_upcall_Just_do_it(_swig_ptr SwigcptrBar) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) - _cgo_runtime_cgocall(_wrap__swig_DirectorBar_upcall_Just_do_it, _swig_p) - return -} - -func (swig_p *_swig_DirectorBar) Just_do_it() { - if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceBarJust_do_it); swig_ok { - swig_g.Just_do_it() - return - } - _swig_wrap__swig_DirectorBar_upcall_Just_do_it(swig_p.SwigcptrBar) -} - -func DirectorBarJust_do_it(p Bar) { - _swig_wrap__swig_DirectorBar_upcall_Just_do_it(p.(*_swig_DirectorBar).SwigcptrBar) -} - -func Swig_DirectorBar_callback_just_do_it(p *_swig_DirectorBar) { - p.Just_do_it() -} - -type SwigcptrBar uintptr - -func (p SwigcptrBar) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrBar) SwigIsBar() { -} - -func (p SwigcptrBar) DirectorInterface() interface{} { - return nil -} - -var _wrap_Bar_baseclass unsafe.Pointer - -func _swig_wrap_Bar_baseclass(base SwigcptrBar) (_ SwigcptrFoo) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Bar_baseclass, _swig_p) - return -} - -func (arg1 SwigcptrBar) Baseclass() (_swig_ret Foo) { - return _swig_wrap_Bar_baseclass(arg1) -} - -var _wrap_Bar_cloner unsafe.Pointer - -func _swig_wrap_Bar_cloner(base SwigcptrBar) (_ SwigcptrBar) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Bar_cloner, _swig_p) - return -} - -func (arg1 SwigcptrBar) Cloner() (_swig_ret Bar) { - return _swig_wrap_Bar_cloner(arg1) -} - -var _wrap_Bar_get_value unsafe.Pointer - -func _swig_wrap_Bar_get_value(base SwigcptrBar) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Bar_get_value, _swig_p) - return -} - -func (arg1 SwigcptrBar) Get_value() (_swig_ret int) { - return _swig_wrap_Bar_get_value(arg1) -} - -var _wrap_Bar_get_class unsafe.Pointer - -func _swig_wrap_Bar_get_class(base SwigcptrBar) (_ SwigcptrA) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Bar_get_class, _swig_p) - return -} - -func (arg1 SwigcptrBar) Get_class() (_swig_ret A) { - return _swig_wrap_Bar_get_class(arg1) -} - -var _wrap_Bar_just_do_it unsafe.Pointer - -func _swig_wrap_Bar_just_do_it(base SwigcptrBar) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Bar_just_do_it, _swig_p) - return -} - -func (arg1 SwigcptrBar) Just_do_it() { - _swig_wrap_Bar_just_do_it(arg1) -} - -var _wrap_new_Bar unsafe.Pointer - -func _swig_wrap_new_Bar() (base SwigcptrBar) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Bar, _swig_p) - return -} - -func NewBar() (_swig_ret Bar) { - return _swig_wrap_new_Bar() -} - -var _wrap_delete_Bar unsafe.Pointer - -func _swig_wrap_delete_Bar(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Bar, _swig_p) - return -} - -func DeleteBar(arg1 Bar) { - _swig_wrap_delete_Bar(arg1.Swigcptr()) -} - -func (p SwigcptrBar) SwigIsFoo() { -} - -func (p SwigcptrBar) SwigGetFoo() Foo { - return SwigcptrFoo(p.Swigcptr()) -} - -type Bar interface { - Swigcptr() uintptr - SwigIsBar() - DirectorInterface() interface{} - Baseclass() (_swig_ret Foo) - Cloner() (_swig_ret Bar) - Get_value() (_swig_ret int) - Get_class() (_swig_ret A) - Just_do_it() - SwigIsFoo() - SwigGetFoo() Foo -} - - -type SwigcptrSwigDirector_Bar uintptr -type SwigDirector_Bar interface { - Swigcptr() uintptr; -} -func (p SwigcptrSwigDirector_Bar) Swigcptr() uintptr { - return uintptr(p) -} - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/director_detect_runme b/Examples/test-suite/go/director_detect_runme deleted file mode 100755 index 06736d0ce..000000000 Binary files a/Examples/test-suite/go/director_detect_runme and /dev/null differ diff --git a/Examples/test-suite/go/director_detect_wrap.h b/Examples/test-suite/go/director_detect_wrap.h deleted file mode 100644 index 27d4ef17f..000000000 --- a/Examples/test-suite/go/director_detect_wrap.h +++ /dev/null @@ -1,54 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../director_detect.i - -#ifndef SWIG_director_detect_WRAP_H_ -#define SWIG_director_detect_WRAP_H_ - -class SwigDirector_Foo : public Foo -{ - public: - SwigDirector_Foo(void *swig_p); - virtual ~SwigDirector_Foo(); - virtual Foo *cloner(); - virtual int get_value(); - virtual A *get_class(); - virtual void just_do_it(); - private: - void *go_val; -}; - -class SwigDirector_Bar : public Bar -{ - public: - SwigDirector_Bar(void *swig_p); - virtual ~SwigDirector_Bar(); - Bar *_swig_upcall_cloner() { - return Bar::cloner(); - } - virtual Bar *cloner(); - foo::Int _swig_upcall_get_value() { - return Bar::get_value(); - } - virtual foo::Int get_value(); - B *_swig_upcall_get_class() { - return Bar::get_class(); - } - virtual B *get_class(); - void _swig_upcall_just_do_it() { - Bar::just_do_it(); - } - virtual void just_do_it(); - private: - void *go_val; -}; - -#endif diff --git a/Examples/test-suite/go/director_enum.go b/Examples/test-suite/go/director_enum.go deleted file mode 100644 index 39e25764c..000000000 --- a/Examples/test-suite/go/director_enum.go +++ /dev/null @@ -1,1436 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../director_enum.i - -package director_enum - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type EnumDirectorHello int -var _wrap_hi unsafe.Pointer - -func _swig_gethi() (_swig_ret EnumDirectorHello) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_hi, _swig_p) - return -} -var Hi EnumDirectorHello = _swig_gethi() -var _wrap_hello unsafe.Pointer - -func _swig_gethello() (_swig_ret EnumDirectorHello) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_hello, _swig_p) - return -} -var Hello EnumDirectorHello = _swig_gethello() -var _wrap_yo unsafe.Pointer - -func _swig_getyo() (_swig_ret EnumDirectorHello) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_yo, _swig_p) - return -} -var Yo EnumDirectorHello = _swig_getyo() -var _wrap_awright unsafe.Pointer - -func _swig_getawright() (_swig_ret EnumDirectorHello) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_awright, _swig_p) - return -} -var Awright EnumDirectorHello = _swig_getawright() -type _swig_DirectorFoo struct { - SwigcptrFoo - v interface{} -} - -func (p *_swig_DirectorFoo) Swigcptr() uintptr { - return p.SwigcptrFoo.Swigcptr() -} - -func (p *_swig_DirectorFoo) SwigIsFoo() { -} - -func (p *_swig_DirectorFoo) DirectorInterface() interface{} { - return p.v -} - -var _wrap__swig_NewDirectorFooFoo unsafe.Pointer - -func _swig_NewDirectorFooFoo(_swig_director *_swig_DirectorFoo) (_swig_ret SwigcptrFoo) { - _swig_p := uintptr(unsafe.Pointer(&_swig_director)) - _cgo_runtime_cgocall(_wrap__swig_NewDirectorFooFoo, _swig_p) - return -} - -func NewDirectorFoo(v interface{}) Foo { - p := &_swig_DirectorFoo{0, v} - p.SwigcptrFoo = _swig_NewDirectorFooFoo(p) - return p -} - -var _wrap_DeleteDirectorFoo unsafe.Pointer - -func _swig_wrap_DeleteDirectorFoo(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_DeleteDirectorFoo, _swig_p) - return -} - -func DeleteDirectorFoo(arg1 Foo) { - _swig_wrap_DeleteDirectorFoo(arg1.Swigcptr()) -} - -func Swiggo_DeleteDirector_Foo(p *_swig_DirectorFoo) { - p.SwigcptrFoo = 0 -} - -type _swig_DirectorInterfaceFooSay_hi__SWIG_0 interface { - Say_hi__SWIG_0(EnumDirectorHello) EnumDirectorHello -} - -var _wrap__swig_DirectorFoo_upcall_Say_hi__SWIG_0 unsafe.Pointer - -func _swig_wrap__swig_DirectorFoo_upcall_Say_hi__SWIG_0(_swig_ptr SwigcptrFoo, _ EnumDirectorHello) (_swig_ret EnumDirectorHello) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) - _cgo_runtime_cgocall(_wrap__swig_DirectorFoo_upcall_Say_hi__SWIG_0, _swig_p) - return -} - -func (swig_p *_swig_DirectorFoo) Say_hi__SWIG_0(h EnumDirectorHello) EnumDirectorHello { - if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceFooSay_hi__SWIG_0); swig_ok { - return swig_g.Say_hi__SWIG_0(h) - } - var swig_r EnumDirectorHello - swig_r = _swig_wrap__swig_DirectorFoo_upcall_Say_hi__SWIG_0(swig_p.SwigcptrFoo, h) - return swig_r -} - -func DirectorFooSay_hi__SWIG_0(p Foo, arg2 EnumDirectorHello) EnumDirectorHello { - var swig_r EnumDirectorHello - swig_r = _swig_wrap__swig_DirectorFoo_upcall_Say_hi__SWIG_0(p.(*_swig_DirectorFoo).SwigcptrFoo, arg2) - return swig_r -} - -func Swig_DirectorFoo_callback_say_hi__SWIG_0(p *_swig_DirectorFoo, arg2 EnumDirectorHello) (swig_result EnumDirectorHello) { - var swig_r EnumDirectorHello - swig_r = p.Say_hi__SWIG_0(arg2) - return swig_r -} - -type _swig_DirectorInterfaceFooSay_hello interface { - Say_hello(EnumDirectorHello) EnumDirectorHello -} - -var _wrap__swig_DirectorFoo_upcall_Say_hello unsafe.Pointer - -func _swig_wrap__swig_DirectorFoo_upcall_Say_hello(_swig_ptr SwigcptrFoo, _ EnumDirectorHello) (_swig_ret EnumDirectorHello) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) - _cgo_runtime_cgocall(_wrap__swig_DirectorFoo_upcall_Say_hello, _swig_p) - return -} - -func (swig_p *_swig_DirectorFoo) Say_hello(arg0 EnumDirectorHello) EnumDirectorHello { - if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceFooSay_hello); swig_ok { - return swig_g.Say_hello(arg0) - } - var swig_r EnumDirectorHello - swig_r = _swig_wrap__swig_DirectorFoo_upcall_Say_hello(swig_p.SwigcptrFoo, arg0) - return swig_r -} - -func DirectorFooSay_hello(p Foo, arg2 EnumDirectorHello) EnumDirectorHello { - var swig_r EnumDirectorHello - swig_r = _swig_wrap__swig_DirectorFoo_upcall_Say_hello(p.(*_swig_DirectorFoo).SwigcptrFoo, arg2) - return swig_r -} - -func Swig_DirectorFoo_callback_say_hello(p *_swig_DirectorFoo, arg2 EnumDirectorHello) (swig_result EnumDirectorHello) { - var swig_r EnumDirectorHello - swig_r = p.Say_hello(arg2) - return swig_r -} - -type _swig_DirectorInterfaceFooSay_hi__SWIG_1 interface { - Say_hi__SWIG_1(A) EnumDirectorHello -} - -var _wrap__swig_DirectorFoo_upcall_Say_hi__SWIG_1 unsafe.Pointer - -func _swig_wrap__swig_DirectorFoo_upcall_Say_hi__SWIG_1(_swig_ptr SwigcptrFoo, _ uintptr) (_swig_ret EnumDirectorHello) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) - _cgo_runtime_cgocall(_wrap__swig_DirectorFoo_upcall_Say_hi__SWIG_1, _swig_p) - return -} - -func (swig_p *_swig_DirectorFoo) Say_hi__SWIG_1(a A) EnumDirectorHello { - if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceFooSay_hi__SWIG_1); swig_ok { - return swig_g.Say_hi__SWIG_1(a) - } - var swig_r EnumDirectorHello - swig_r = _swig_wrap__swig_DirectorFoo_upcall_Say_hi__SWIG_1(swig_p.SwigcptrFoo, a.Swigcptr()) - return swig_r -} - -func DirectorFooSay_hi__SWIG_1(p Foo, arg2 A) EnumDirectorHello { - var swig_r EnumDirectorHello - swig_r = _swig_wrap__swig_DirectorFoo_upcall_Say_hi__SWIG_1(p.(*_swig_DirectorFoo).SwigcptrFoo, arg2.Swigcptr()) - return swig_r -} - -func Swig_DirectorFoo_callback_say_hi__SWIG_1(p *_swig_DirectorFoo, arg2 uintptr) (swig_result EnumDirectorHello) { - var swig_r EnumDirectorHello - swig_r = p.Say_hi__SWIG_1(SwigcptrA(arg2)) - return swig_r -} - -func (p _swig_DirectorFoo) Say_hi(a ...interface{}) EnumDirectorHello { - argc := len(a) - if argc == 1 { - if _, ok := a[0].(EnumDirectorHello); !ok { - goto check_1 - } - return p.Say_hi__SWIG_0(a[0].(EnumDirectorHello)) - } -check_1: - if argc == 1 { - return p.Say_hi__SWIG_1(a[0].(A)) - } - panic("No match for overloaded function call") -} - -func DirectorFooSay_hi(p *_swig_DirectorFoo, a ...interface{}) EnumDirectorHello { - argc := len(a) - if argc == 1 { - if _, ok := a[0].(EnumDirectorHello); !ok { - goto check_1 - } - return DirectorFooSay_hi__SWIG_0(p, a[0].(EnumDirectorHello)) - } -check_1: - if argc == 1 { - return DirectorFooSay_hi__SWIG_1(p, a[0].(A)) - } - panic("No match for overloaded function call") -} - -type _swig_DirectorInterfaceFooSay_bye interface { - Say_bye(EnumDirectorFooBye) EnumDirectorFooBye -} - -var _wrap__swig_DirectorFoo_upcall_Say_bye unsafe.Pointer - -func _swig_wrap__swig_DirectorFoo_upcall_Say_bye(_swig_ptr SwigcptrFoo, _ EnumDirectorFooBye) (_swig_ret EnumDirectorFooBye) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) - _cgo_runtime_cgocall(_wrap__swig_DirectorFoo_upcall_Say_bye, _swig_p) - return -} - -func (swig_p *_swig_DirectorFoo) Say_bye(b EnumDirectorFooBye) EnumDirectorFooBye { - if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceFooSay_bye); swig_ok { - return swig_g.Say_bye(b) - } - var swig_r EnumDirectorFooBye - swig_r = _swig_wrap__swig_DirectorFoo_upcall_Say_bye(swig_p.SwigcptrFoo, b) - return swig_r -} - -func DirectorFooSay_bye(p Foo, arg2 EnumDirectorFooBye) EnumDirectorFooBye { - var swig_r EnumDirectorFooBye - swig_r = _swig_wrap__swig_DirectorFoo_upcall_Say_bye(p.(*_swig_DirectorFoo).SwigcptrFoo, arg2) - return swig_r -} - -func Swig_DirectorFoo_callback_say_bye(p *_swig_DirectorFoo, arg2 EnumDirectorFooBye) (swig_result EnumDirectorFooBye) { - var swig_r EnumDirectorFooBye - swig_r = p.Say_bye(arg2) - return swig_r -} - -type _swig_DirectorInterfaceFooSay_hi_ref interface { - Say_hi_ref(*EnumDirectorHello) *EnumDirectorHello -} - -var _wrap__swig_DirectorFoo_upcall_Say_hi_ref unsafe.Pointer - -func _swig_wrap__swig_DirectorFoo_upcall_Say_hi_ref(_swig_ptr SwigcptrFoo, _ *EnumDirectorHello) (_swig_ret *EnumDirectorHello) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) - _cgo_runtime_cgocall(_wrap__swig_DirectorFoo_upcall_Say_hi_ref, _swig_p) - return -} - -func (swig_p *_swig_DirectorFoo) Say_hi_ref(h *EnumDirectorHello) *EnumDirectorHello { - if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceFooSay_hi_ref); swig_ok { - return swig_g.Say_hi_ref(h) - } - var swig_r *EnumDirectorHello - swig_r = _swig_wrap__swig_DirectorFoo_upcall_Say_hi_ref(swig_p.SwigcptrFoo, h) - return swig_r -} - -func DirectorFooSay_hi_ref(p Foo, arg2 *EnumDirectorHello) *EnumDirectorHello { - var swig_r *EnumDirectorHello - swig_r = _swig_wrap__swig_DirectorFoo_upcall_Say_hi_ref(p.(*_swig_DirectorFoo).SwigcptrFoo, arg2) - return swig_r -} - -func Swig_DirectorFoo_callback_say_hi_ref(p *_swig_DirectorFoo, arg2 *EnumDirectorHello) (swig_result *EnumDirectorHello) { - var swig_r *EnumDirectorHello - swig_r = p.Say_hi_ref(arg2) - return swig_r -} - -type SwigcptrFoo uintptr - -func (p SwigcptrFoo) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrFoo) SwigIsFoo() { -} - -func (p SwigcptrFoo) DirectorInterface() interface{} { - return nil -} - -type EnumDirectorFooBye int -var _wrap_ciao_Foo unsafe.Pointer - -func _swig_getFoo_ciao_Foo() (_swig_ret EnumDirectorFooBye) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_ciao_Foo, _swig_p) - return -} -var FooCiao EnumDirectorFooBye = _swig_getFoo_ciao_Foo() -var _wrap_aufwiedersehen_Foo unsafe.Pointer - -func _swig_getFoo_aufwiedersehen_Foo() (_swig_ret EnumDirectorFooBye) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_aufwiedersehen_Foo, _swig_p) - return -} -var FooAufwiedersehen EnumDirectorFooBye = _swig_getFoo_aufwiedersehen_Foo() -var _wrap_adios_Foo unsafe.Pointer - -func _swig_getFoo_adios_Foo() (_swig_ret EnumDirectorFooBye) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_adios_Foo, _swig_p) - return -} -var FooAdios EnumDirectorFooBye = _swig_getFoo_adios_Foo() -var _wrap_delete_Foo unsafe.Pointer - -func _swig_wrap_delete_Foo(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Foo, _swig_p) - return -} - -func DeleteFoo(arg1 Foo) { - _swig_wrap_delete_Foo(arg1.Swigcptr()) -} - -var _wrap_Foo_say_hi__SWIG_0 unsafe.Pointer - -func _swig_wrap_Foo_say_hi__SWIG_0(base SwigcptrFoo, _ EnumDirectorHello) (_ EnumDirectorHello) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_say_hi__SWIG_0, _swig_p) - return -} - -func (arg1 SwigcptrFoo) Say_hi__SWIG_0(arg2 EnumDirectorHello) (_swig_ret EnumDirectorHello) { - return _swig_wrap_Foo_say_hi__SWIG_0(arg1, arg2) -} - -var _wrap_Foo_say_hello unsafe.Pointer - -func _swig_wrap_Foo_say_hello(base SwigcptrFoo, _ EnumDirectorHello) (_ EnumDirectorHello) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_say_hello, _swig_p) - return -} - -func (arg1 SwigcptrFoo) Say_hello(arg2 EnumDirectorHello) (_swig_ret EnumDirectorHello) { - return _swig_wrap_Foo_say_hello(arg1, arg2) -} - -var _wrap_Foo_say_hi__SWIG_1 unsafe.Pointer - -func _swig_wrap_Foo_say_hi__SWIG_1(base SwigcptrFoo, _ uintptr) (_ EnumDirectorHello) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_say_hi__SWIG_1, _swig_p) - return -} - -func (arg1 SwigcptrFoo) Say_hi__SWIG_1(arg2 A) (_swig_ret EnumDirectorHello) { - return _swig_wrap_Foo_say_hi__SWIG_1(arg1, arg2.Swigcptr()) -} - -func (p SwigcptrFoo) Say_hi(a ...interface{}) EnumDirectorHello { - argc := len(a) - if argc == 1 { - if _, ok := a[0].(EnumDirectorHello); !ok { - goto check_1 - } - return p.Say_hi__SWIG_0(a[0].(EnumDirectorHello)) - } -check_1: - if argc == 1 { - return p.Say_hi__SWIG_1(a[0].(A)) - } - panic("No match for overloaded function call") -} - -var _wrap_Foo_say_bye unsafe.Pointer - -func _swig_wrap_Foo_say_bye(base SwigcptrFoo, _ EnumDirectorFooBye) (_ EnumDirectorFooBye) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_say_bye, _swig_p) - return -} - -func (arg1 SwigcptrFoo) Say_bye(arg2 EnumDirectorFooBye) (_swig_ret EnumDirectorFooBye) { - return _swig_wrap_Foo_say_bye(arg1, arg2) -} - -var _wrap_Foo_say_hi_ref unsafe.Pointer - -func _swig_wrap_Foo_say_hi_ref(base SwigcptrFoo, _ *EnumDirectorHello) (_ *EnumDirectorHello) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_say_hi_ref, _swig_p) - return -} - -func (arg1 SwigcptrFoo) Say_hi_ref(arg2 *EnumDirectorHello) (_swig_ret *EnumDirectorHello) { - return _swig_wrap_Foo_say_hi_ref(arg1, arg2) -} - -var _wrap_Foo_ping unsafe.Pointer - -func _swig_wrap_Foo_ping(base SwigcptrFoo, _ EnumDirectorHello) (_ EnumDirectorHello) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_ping, _swig_p) - return -} - -func (arg1 SwigcptrFoo) Ping(arg2 EnumDirectorHello) (_swig_ret EnumDirectorHello) { - return _swig_wrap_Foo_ping(arg1, arg2) -} - -var _wrap_Foo_ping_ref unsafe.Pointer - -func _swig_wrap_Foo_ping_ref(base SwigcptrFoo, _ *EnumDirectorHello) (_ *EnumDirectorHello) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_ping_ref, _swig_p) - return -} - -func (arg1 SwigcptrFoo) Ping_ref(arg2 *EnumDirectorHello) (_swig_ret *EnumDirectorHello) { - return _swig_wrap_Foo_ping_ref(arg1, arg2) -} - -var _wrap_Foo_ping_member_enum unsafe.Pointer - -func _swig_wrap_Foo_ping_member_enum(base SwigcptrFoo, _ EnumDirectorFooBye) (_ EnumDirectorFooBye) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_ping_member_enum, _swig_p) - return -} - -func (arg1 SwigcptrFoo) Ping_member_enum(arg2 EnumDirectorFooBye) (_swig_ret EnumDirectorFooBye) { - return _swig_wrap_Foo_ping_member_enum(arg1, arg2) -} - -var _wrap_new_Foo unsafe.Pointer - -func _swig_wrap_new_Foo() (base SwigcptrFoo) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Foo, _swig_p) - return -} - -func NewFoo() (_swig_ret Foo) { - return _swig_wrap_new_Foo() -} - -type Foo interface { - Swigcptr() uintptr - SwigIsFoo() - DirectorInterface() interface{} - Say_hello(arg2 EnumDirectorHello) (_swig_ret EnumDirectorHello) - Say_hi(a ...interface{}) EnumDirectorHello - Say_bye(arg2 EnumDirectorFooBye) (_swig_ret EnumDirectorFooBye) - Say_hi_ref(arg2 *EnumDirectorHello) (_swig_ret *EnumDirectorHello) - Ping(arg2 EnumDirectorHello) (_swig_ret EnumDirectorHello) - Ping_ref(arg2 *EnumDirectorHello) (_swig_ret *EnumDirectorHello) - Ping_member_enum(arg2 EnumDirectorFooBye) (_swig_ret EnumDirectorFooBye) -} - -type EnumDirectorFType int -var _wrap_SA unsafe.Pointer - -func _swig_getSA() (_swig_ret EnumDirectorFType) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_SA, _swig_p) - return -} -var SA EnumDirectorFType = _swig_getSA() -var _wrap_NA_ unsafe.Pointer - -func _swig_getNA_() (_swig_ret EnumDirectorFType) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_NA_, _swig_p) - return -} -var NA_ EnumDirectorFType = _swig_getNA_() -var _wrap_EA unsafe.Pointer - -func _swig_getEA() (_swig_ret EnumDirectorFType) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_EA, _swig_p) - return -} -var EA EnumDirectorFType = _swig_getEA() -type _swig_DirectorA struct { - SwigcptrA - v interface{} -} - -func (p *_swig_DirectorA) Swigcptr() uintptr { - return p.SwigcptrA.Swigcptr() -} - -func (p *_swig_DirectorA) SwigIsA() { -} - -func (p *_swig_DirectorA) DirectorInterface() interface{} { - return p.v -} - -var _wrap__swig_NewDirectorAA unsafe.Pointer - -func _swig_NewDirectorAA(_swig_director *_swig_DirectorA, _ float64, _ float64, _ EnumDirectorFType) (_swig_ret SwigcptrA) { - _swig_p := uintptr(unsafe.Pointer(&_swig_director)) - _cgo_runtime_cgocall(_wrap__swig_NewDirectorAA, _swig_p) - return -} - -func NewDirectorA(v interface{}, arg1 float64, arg2 float64, arg3 EnumDirectorFType) A { - p := &_swig_DirectorA{0, v} - p.SwigcptrA = _swig_NewDirectorAA(p, arg1, arg2, arg3) - return p -} - -var _wrap_DeleteDirectorA unsafe.Pointer - -func _swig_wrap_DeleteDirectorA(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_DeleteDirectorA, _swig_p) - return -} - -func DeleteDirectorA(arg1 A) { - _swig_wrap_DeleteDirectorA(arg1.Swigcptr()) -} - -func Swiggo_DeleteDirector_A(p *_swig_DirectorA) { - p.SwigcptrA = 0 -} - -type _swig_DirectorInterfaceAF__SWIG_0 interface { - F__SWIG_0(int) int -} - -var _wrap__swig_DirectorA_upcall_F__SWIG_0 unsafe.Pointer - -func _swig_wrap__swig_DirectorA_upcall_F__SWIG_0(_swig_ptr SwigcptrA, _ int) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) - _cgo_runtime_cgocall(_wrap__swig_DirectorA_upcall_F__SWIG_0, _swig_p) - return -} - -func (swig_p *_swig_DirectorA) F__SWIG_0(i int) int { - if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceAF__SWIG_0); swig_ok { - return swig_g.F__SWIG_0(i) - } - var swig_r int - swig_r = _swig_wrap__swig_DirectorA_upcall_F__SWIG_0(swig_p.SwigcptrA, i) - return swig_r -} - -func DirectorAF__SWIG_0(p A, arg2 int) int { - var swig_r int - swig_r = _swig_wrap__swig_DirectorA_upcall_F__SWIG_0(p.(*_swig_DirectorA).SwigcptrA, arg2) - return swig_r -} - -func Swig_DirectorA_callback_f__SWIG_0(p *_swig_DirectorA, arg2 int) (swig_result int) { - var swig_r int - swig_r = p.F__SWIG_0(arg2) - return swig_r -} - -type _swig_DirectorInterfaceAF__SWIG_1 interface { - F__SWIG_1() int -} - -var _wrap__swig_DirectorA_upcall_F__SWIG_1 unsafe.Pointer - -func _swig_wrap__swig_DirectorA_upcall_F__SWIG_1(_swig_ptr SwigcptrA) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) - _cgo_runtime_cgocall(_wrap__swig_DirectorA_upcall_F__SWIG_1, _swig_p) - return -} - -func (swig_p *_swig_DirectorA) F__SWIG_1() int { - if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceAF__SWIG_1); swig_ok { - return swig_g.F__SWIG_1() - } - var swig_r int - swig_r = _swig_wrap__swig_DirectorA_upcall_F__SWIG_1(swig_p.SwigcptrA) - return swig_r -} - -func DirectorAF__SWIG_1(p A) int { - var swig_r int - swig_r = _swig_wrap__swig_DirectorA_upcall_F__SWIG_1(p.(*_swig_DirectorA).SwigcptrA) - return swig_r -} - -func Swig_DirectorA_callback_f__SWIG_1(p *_swig_DirectorA) (swig_result int) { - var swig_r int - swig_r = p.F__SWIG_1() - return swig_r -} - -func (p _swig_DirectorA) F(a ...interface{}) int { - argc := len(a) - if argc == 0 { - return p.F__SWIG_1() - } - if argc == 1 { - return p.F__SWIG_0(a[0].(int)) - } - panic("No match for overloaded function call") -} - -func DirectorAF(p *_swig_DirectorA, a ...interface{}) int { - argc := len(a) - if argc == 0 { - return DirectorAF__SWIG_1(p) - } - if argc == 1 { - return DirectorAF__SWIG_0(p, a[0].(int)) - } - panic("No match for overloaded function call") -} - -type SwigcptrA uintptr - -func (p SwigcptrA) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrA) SwigIsA() { -} - -func (p SwigcptrA) DirectorInterface() interface{} { - return nil -} - -var _wrap_new_A unsafe.Pointer - -func _swig_wrap_new_A(base float64, _ float64, _ EnumDirectorFType) (_ SwigcptrA) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_A, _swig_p) - return -} - -func NewA(arg1 float64, arg2 float64, arg3 EnumDirectorFType) (_swig_ret A) { - return _swig_wrap_new_A(arg1, arg2, arg3) -} - -var _wrap_delete_A unsafe.Pointer - -func _swig_wrap_delete_A(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_A, _swig_p) - return -} - -func DeleteA(arg1 A) { - _swig_wrap_delete_A(arg1.Swigcptr()) -} - -var _wrap_A_f__SWIG_0 unsafe.Pointer - -func _swig_wrap_A_f__SWIG_0(base SwigcptrA, _ int) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_A_f__SWIG_0, _swig_p) - return -} - -func (arg1 SwigcptrA) F__SWIG_0(arg2 int) (_swig_ret int) { - return _swig_wrap_A_f__SWIG_0(arg1, arg2) -} - -var _wrap_A_f__SWIG_1 unsafe.Pointer - -func _swig_wrap_A_f__SWIG_1(base SwigcptrA) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_A_f__SWIG_1, _swig_p) - return -} - -func (arg1 SwigcptrA) F__SWIG_1() (_swig_ret int) { - return _swig_wrap_A_f__SWIG_1(arg1) -} - -func (p SwigcptrA) F(a ...interface{}) int { - argc := len(a) - if argc == 0 { - return p.F__SWIG_1() - } - if argc == 1 { - return p.F__SWIG_0(a[0].(int)) - } - panic("No match for overloaded function call") -} - -type A interface { - Swigcptr() uintptr - SwigIsA() - DirectorInterface() interface{} - F(a ...interface{}) int -} - -type _swig_DirectorB struct { - SwigcptrB - v interface{} -} - -func (p *_swig_DirectorB) Swigcptr() uintptr { - return p.SwigcptrB.Swigcptr() -} - -func (p *_swig_DirectorB) SwigIsB() { -} - -func (p *_swig_DirectorB) DirectorInterface() interface{} { - return p.v -} - -var _wrap__swig_NewDirectorBB unsafe.Pointer - -func _swig_NewDirectorBB(_swig_director *_swig_DirectorB, _ float64, _ float64, _ EnumDirectorFType) (_swig_ret SwigcptrB) { - _swig_p := uintptr(unsafe.Pointer(&_swig_director)) - _cgo_runtime_cgocall(_wrap__swig_NewDirectorBB, _swig_p) - return -} - -func NewDirectorB(v interface{}, arg1 float64, arg2 float64, arg3 EnumDirectorFType) B { - p := &_swig_DirectorB{0, v} - p.SwigcptrB = _swig_NewDirectorBB(p, arg1, arg2, arg3) - return p -} - -var _wrap_DeleteDirectorB unsafe.Pointer - -func _swig_wrap_DeleteDirectorB(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_DeleteDirectorB, _swig_p) - return -} - -func DeleteDirectorB(arg1 B) { - _swig_wrap_DeleteDirectorB(arg1.Swigcptr()) -} - -func Swiggo_DeleteDirector_B(p *_swig_DirectorB) { - p.SwigcptrB = 0 -} - -type _swig_DirectorInterfaceBF__SWIG_0 interface { - F__SWIG_0(int) int -} - -var _wrap__swig_DirectorB_upcall_F__SWIG_0 unsafe.Pointer - -func _swig_wrap__swig_DirectorB_upcall_F__SWIG_0(_swig_ptr SwigcptrB, _ int) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) - _cgo_runtime_cgocall(_wrap__swig_DirectorB_upcall_F__SWIG_0, _swig_p) - return -} - -func (swig_p *_swig_DirectorB) F__SWIG_0(i int) int { - if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceBF__SWIG_0); swig_ok { - return swig_g.F__SWIG_0(i) - } - var swig_r int - swig_r = _swig_wrap__swig_DirectorB_upcall_F__SWIG_0(swig_p.SwigcptrB, i) - return swig_r -} - -func DirectorBF__SWIG_0(p B, arg2 int) int { - var swig_r int - swig_r = _swig_wrap__swig_DirectorB_upcall_F__SWIG_0(p.(*_swig_DirectorB).SwigcptrB, arg2) - return swig_r -} - -func Swig_DirectorB_callback_f__SWIG_0(p *_swig_DirectorB, arg2 int) (swig_result int) { - var swig_r int - swig_r = p.F__SWIG_0(arg2) - return swig_r -} - -type _swig_DirectorInterfaceBF__SWIG_1 interface { - F__SWIG_1() int -} - -var _wrap__swig_DirectorB_upcall_F__SWIG_1 unsafe.Pointer - -func _swig_wrap__swig_DirectorB_upcall_F__SWIG_1(_swig_ptr SwigcptrB) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) - _cgo_runtime_cgocall(_wrap__swig_DirectorB_upcall_F__SWIG_1, _swig_p) - return -} - -func (swig_p *_swig_DirectorB) F__SWIG_1() int { - if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceBF__SWIG_1); swig_ok { - return swig_g.F__SWIG_1() - } - var swig_r int - swig_r = _swig_wrap__swig_DirectorB_upcall_F__SWIG_1(swig_p.SwigcptrB) - return swig_r -} - -func DirectorBF__SWIG_1(p B) int { - var swig_r int - swig_r = _swig_wrap__swig_DirectorB_upcall_F__SWIG_1(p.(*_swig_DirectorB).SwigcptrB) - return swig_r -} - -func Swig_DirectorB_callback_f__SWIG_1(p *_swig_DirectorB) (swig_result int) { - var swig_r int - swig_r = p.F__SWIG_1() - return swig_r -} - -type SwigcptrB uintptr - -func (p SwigcptrB) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrB) SwigIsB() { -} - -func (p SwigcptrB) DirectorInterface() interface{} { - return nil -} - -var _wrap_new_B unsafe.Pointer - -func _swig_wrap_new_B(base float64, _ float64, _ EnumDirectorFType) (_ SwigcptrB) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_B, _swig_p) - return -} - -func NewB(arg1 float64, arg2 float64, arg3 EnumDirectorFType) (_swig_ret B) { - return _swig_wrap_new_B(arg1, arg2, arg3) -} - -var _wrap_delete_B unsafe.Pointer - -func _swig_wrap_delete_B(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_B, _swig_p) - return -} - -func DeleteB(arg1 B) { - _swig_wrap_delete_B(arg1.Swigcptr()) -} - -var _wrap_B_f__SWIG_0 unsafe.Pointer - -func _swig_wrap_B_f__SWIG_0(base SwigcptrB, _ int) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_B_f__SWIG_0, _swig_p) - return -} - -func (_swig_base SwigcptrB) F__SWIG_0(arg1 int) (_swig_ret int) { - return _swig_wrap_B_f__SWIG_0(_swig_base, arg1) -} - -var _wrap_B_f__SWIG_1 unsafe.Pointer - -func _swig_wrap_B_f__SWIG_1(base SwigcptrB) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_B_f__SWIG_1, _swig_p) - return -} - -func (_swig_base SwigcptrB) F__SWIG_1() (_swig_ret int) { - return _swig_wrap_B_f__SWIG_1(_swig_base) -} - -func (p SwigcptrB) F(a ...interface{}) int { - argc := len(a) - if argc == 0 { - return p.F__SWIG_1() - } - if argc == 1 { - return p.F__SWIG_0(a[0].(int)) - } - panic("No match for overloaded function call") -} - -func (p SwigcptrB) SwigIsA() { -} - -func (p SwigcptrB) SwigGetA() A { - return SwigcptrA(p.Swigcptr()) -} - -type B interface { - Swigcptr() uintptr - SwigIsB() - DirectorInterface() interface{} - F(a ...interface{}) int - SwigIsA() - SwigGetA() A -} - -type _swig_DirectorA2 struct { - SwigcptrA2 - v interface{} -} - -func (p *_swig_DirectorA2) Swigcptr() uintptr { - return p.SwigcptrA2.Swigcptr() -} - -func (p *_swig_DirectorA2) SwigIsA2() { -} - -func (p *_swig_DirectorA2) DirectorInterface() interface{} { - return p.v -} - -var _wrap__swig_NewDirectorA2A2__SWIG_0 unsafe.Pointer - -func _swig_NewDirectorA2A2__SWIG_0(_swig_director *_swig_DirectorA2, _ EnumDirectorFType) (_swig_ret SwigcptrA2) { - _swig_p := uintptr(unsafe.Pointer(&_swig_director)) - _cgo_runtime_cgocall(_wrap__swig_NewDirectorA2A2__SWIG_0, _swig_p) - return -} - -func NewDirectorA2__SWIG_0(v interface{}, arg1 EnumDirectorFType) A2 { - p := &_swig_DirectorA2{0, v} - p.SwigcptrA2 = _swig_NewDirectorA2A2__SWIG_0(p, arg1) - return p -} - -var _wrap__swig_NewDirectorA2A2__SWIG_1 unsafe.Pointer - -func _swig_NewDirectorA2A2__SWIG_1(_swig_director *_swig_DirectorA2) (_swig_ret SwigcptrA2) { - _swig_p := uintptr(unsafe.Pointer(&_swig_director)) - _cgo_runtime_cgocall(_wrap__swig_NewDirectorA2A2__SWIG_1, _swig_p) - return -} - -func NewDirectorA2__SWIG_1(v interface{}) A2 { - p := &_swig_DirectorA2{0, v} - p.SwigcptrA2 = _swig_NewDirectorA2A2__SWIG_1(p) - return p -} - -func NewDirectorA2(abi interface{}, a ...interface{}) A2 { - argc := len(a) - if argc == 0 { - return NewDirectorA2__SWIG_1(abi) - } - if argc == 1 { - return NewDirectorA2__SWIG_0(abi, a[0].(EnumDirectorFType)) - } - panic("No match for overloaded function call") -} - -var _wrap_DeleteDirectorA2 unsafe.Pointer - -func _swig_wrap_DeleteDirectorA2(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_DeleteDirectorA2, _swig_p) - return -} - -func DeleteDirectorA2(arg1 A2) { - _swig_wrap_DeleteDirectorA2(arg1.Swigcptr()) -} - -func Swiggo_DeleteDirector_A2(p *_swig_DirectorA2) { - p.SwigcptrA2 = 0 -} - -type _swig_DirectorInterfaceA2F__SWIG_0 interface { - F__SWIG_0(int) int -} - -var _wrap__swig_DirectorA2_upcall_F__SWIG_0 unsafe.Pointer - -func _swig_wrap__swig_DirectorA2_upcall_F__SWIG_0(_swig_ptr SwigcptrA2, _ int) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) - _cgo_runtime_cgocall(_wrap__swig_DirectorA2_upcall_F__SWIG_0, _swig_p) - return -} - -func (swig_p *_swig_DirectorA2) F__SWIG_0(i int) int { - if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceA2F__SWIG_0); swig_ok { - return swig_g.F__SWIG_0(i) - } - var swig_r int - swig_r = _swig_wrap__swig_DirectorA2_upcall_F__SWIG_0(swig_p.SwigcptrA2, i) - return swig_r -} - -func DirectorA2F__SWIG_0(p A2, arg2 int) int { - var swig_r int - swig_r = _swig_wrap__swig_DirectorA2_upcall_F__SWIG_0(p.(*_swig_DirectorA2).SwigcptrA2, arg2) - return swig_r -} - -func Swig_DirectorA2_callback_f__SWIG_0(p *_swig_DirectorA2, arg2 int) (swig_result int) { - var swig_r int - swig_r = p.F__SWIG_0(arg2) - return swig_r -} - -type _swig_DirectorInterfaceA2F__SWIG_1 interface { - F__SWIG_1() int -} - -var _wrap__swig_DirectorA2_upcall_F__SWIG_1 unsafe.Pointer - -func _swig_wrap__swig_DirectorA2_upcall_F__SWIG_1(_swig_ptr SwigcptrA2) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) - _cgo_runtime_cgocall(_wrap__swig_DirectorA2_upcall_F__SWIG_1, _swig_p) - return -} - -func (swig_p *_swig_DirectorA2) F__SWIG_1() int { - if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceA2F__SWIG_1); swig_ok { - return swig_g.F__SWIG_1() - } - var swig_r int - swig_r = _swig_wrap__swig_DirectorA2_upcall_F__SWIG_1(swig_p.SwigcptrA2) - return swig_r -} - -func DirectorA2F__SWIG_1(p A2) int { - var swig_r int - swig_r = _swig_wrap__swig_DirectorA2_upcall_F__SWIG_1(p.(*_swig_DirectorA2).SwigcptrA2) - return swig_r -} - -func Swig_DirectorA2_callback_f__SWIG_1(p *_swig_DirectorA2) (swig_result int) { - var swig_r int - swig_r = p.F__SWIG_1() - return swig_r -} - -func (p _swig_DirectorA2) F(a ...interface{}) int { - argc := len(a) - if argc == 0 { - return p.F__SWIG_1() - } - if argc == 1 { - return p.F__SWIG_0(a[0].(int)) - } - panic("No match for overloaded function call") -} - -func DirectorA2F(p *_swig_DirectorA2, a ...interface{}) int { - argc := len(a) - if argc == 0 { - return DirectorA2F__SWIG_1(p) - } - if argc == 1 { - return DirectorA2F__SWIG_0(p, a[0].(int)) - } - panic("No match for overloaded function call") -} - -type SwigcptrA2 uintptr - -func (p SwigcptrA2) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrA2) SwigIsA2() { -} - -func (p SwigcptrA2) DirectorInterface() interface{} { - return nil -} - -var _wrap_new_A2__SWIG_0 unsafe.Pointer - -func _swig_wrap_new_A2__SWIG_0(base EnumDirectorFType) (_ SwigcptrA2) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_A2__SWIG_0, _swig_p) - return -} - -func NewA2__SWIG_0(arg1 EnumDirectorFType) (_swig_ret A2) { - return _swig_wrap_new_A2__SWIG_0(arg1) -} - -var _wrap_new_A2__SWIG_1 unsafe.Pointer - -func _swig_wrap_new_A2__SWIG_1() (base SwigcptrA2) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_A2__SWIG_1, _swig_p) - return -} - -func NewA2__SWIG_1() (_swig_ret A2) { - return _swig_wrap_new_A2__SWIG_1() -} - -func NewA2(a ...interface{}) A2 { - argc := len(a) - if argc == 0 { - return NewA2__SWIG_1() - } - if argc == 1 { - return NewA2__SWIG_0(a[0].(EnumDirectorFType)) - } - panic("No match for overloaded function call") -} - -var _wrap_delete_A2 unsafe.Pointer - -func _swig_wrap_delete_A2(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_A2, _swig_p) - return -} - -func DeleteA2(arg1 A2) { - _swig_wrap_delete_A2(arg1.Swigcptr()) -} - -var _wrap_A2_f__SWIG_0 unsafe.Pointer - -func _swig_wrap_A2_f__SWIG_0(base SwigcptrA2, _ int) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_A2_f__SWIG_0, _swig_p) - return -} - -func (arg1 SwigcptrA2) F__SWIG_0(arg2 int) (_swig_ret int) { - return _swig_wrap_A2_f__SWIG_0(arg1, arg2) -} - -var _wrap_A2_f__SWIG_1 unsafe.Pointer - -func _swig_wrap_A2_f__SWIG_1(base SwigcptrA2) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_A2_f__SWIG_1, _swig_p) - return -} - -func (arg1 SwigcptrA2) F__SWIG_1() (_swig_ret int) { - return _swig_wrap_A2_f__SWIG_1(arg1) -} - -func (p SwigcptrA2) F(a ...interface{}) int { - argc := len(a) - if argc == 0 { - return p.F__SWIG_1() - } - if argc == 1 { - return p.F__SWIG_0(a[0].(int)) - } - panic("No match for overloaded function call") -} - -type A2 interface { - Swigcptr() uintptr - SwigIsA2() - DirectorInterface() interface{} - F(a ...interface{}) int -} - -type _swig_DirectorB2 struct { - SwigcptrB2 - v interface{} -} - -func (p *_swig_DirectorB2) Swigcptr() uintptr { - return p.SwigcptrB2.Swigcptr() -} - -func (p *_swig_DirectorB2) SwigIsB2() { -} - -func (p *_swig_DirectorB2) DirectorInterface() interface{} { - return p.v -} - -var _wrap__swig_NewDirectorB2B2 unsafe.Pointer - -func _swig_NewDirectorB2B2(_swig_director *_swig_DirectorB2, _ EnumDirectorFType) (_swig_ret SwigcptrB2) { - _swig_p := uintptr(unsafe.Pointer(&_swig_director)) - _cgo_runtime_cgocall(_wrap__swig_NewDirectorB2B2, _swig_p) - return -} - -func NewDirectorB2(v interface{}, arg1 EnumDirectorFType) B2 { - p := &_swig_DirectorB2{0, v} - p.SwigcptrB2 = _swig_NewDirectorB2B2(p, arg1) - return p -} - -var _wrap_DeleteDirectorB2 unsafe.Pointer - -func _swig_wrap_DeleteDirectorB2(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_DeleteDirectorB2, _swig_p) - return -} - -func DeleteDirectorB2(arg1 B2) { - _swig_wrap_DeleteDirectorB2(arg1.Swigcptr()) -} - -func Swiggo_DeleteDirector_B2(p *_swig_DirectorB2) { - p.SwigcptrB2 = 0 -} - -type _swig_DirectorInterfaceB2F__SWIG_0 interface { - F__SWIG_0(int) int -} - -var _wrap__swig_DirectorB2_upcall_F__SWIG_0 unsafe.Pointer - -func _swig_wrap__swig_DirectorB2_upcall_F__SWIG_0(_swig_ptr SwigcptrB2, _ int) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) - _cgo_runtime_cgocall(_wrap__swig_DirectorB2_upcall_F__SWIG_0, _swig_p) - return -} - -func (swig_p *_swig_DirectorB2) F__SWIG_0(i int) int { - if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceB2F__SWIG_0); swig_ok { - return swig_g.F__SWIG_0(i) - } - var swig_r int - swig_r = _swig_wrap__swig_DirectorB2_upcall_F__SWIG_0(swig_p.SwigcptrB2, i) - return swig_r -} - -func DirectorB2F__SWIG_0(p B2, arg2 int) int { - var swig_r int - swig_r = _swig_wrap__swig_DirectorB2_upcall_F__SWIG_0(p.(*_swig_DirectorB2).SwigcptrB2, arg2) - return swig_r -} - -func Swig_DirectorB2_callback_f__SWIG_0(p *_swig_DirectorB2, arg2 int) (swig_result int) { - var swig_r int - swig_r = p.F__SWIG_0(arg2) - return swig_r -} - -type _swig_DirectorInterfaceB2F__SWIG_1 interface { - F__SWIG_1() int -} - -var _wrap__swig_DirectorB2_upcall_F__SWIG_1 unsafe.Pointer - -func _swig_wrap__swig_DirectorB2_upcall_F__SWIG_1(_swig_ptr SwigcptrB2) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) - _cgo_runtime_cgocall(_wrap__swig_DirectorB2_upcall_F__SWIG_1, _swig_p) - return -} - -func (swig_p *_swig_DirectorB2) F__SWIG_1() int { - if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceB2F__SWIG_1); swig_ok { - return swig_g.F__SWIG_1() - } - var swig_r int - swig_r = _swig_wrap__swig_DirectorB2_upcall_F__SWIG_1(swig_p.SwigcptrB2) - return swig_r -} - -func DirectorB2F__SWIG_1(p B2) int { - var swig_r int - swig_r = _swig_wrap__swig_DirectorB2_upcall_F__SWIG_1(p.(*_swig_DirectorB2).SwigcptrB2) - return swig_r -} - -func Swig_DirectorB2_callback_f__SWIG_1(p *_swig_DirectorB2) (swig_result int) { - var swig_r int - swig_r = p.F__SWIG_1() - return swig_r -} - -type SwigcptrB2 uintptr - -func (p SwigcptrB2) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrB2) SwigIsB2() { -} - -func (p SwigcptrB2) DirectorInterface() interface{} { - return nil -} - -var _wrap_new_B2 unsafe.Pointer - -func _swig_wrap_new_B2(base EnumDirectorFType) (_ SwigcptrB2) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_B2, _swig_p) - return -} - -func NewB2(arg1 EnumDirectorFType) (_swig_ret B2) { - return _swig_wrap_new_B2(arg1) -} - -var _wrap_delete_B2 unsafe.Pointer - -func _swig_wrap_delete_B2(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_B2, _swig_p) - return -} - -func DeleteB2(arg1 B2) { - _swig_wrap_delete_B2(arg1.Swigcptr()) -} - -var _wrap_B2_f__SWIG_0 unsafe.Pointer - -func _swig_wrap_B2_f__SWIG_0(base SwigcptrB2, _ int) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_B2_f__SWIG_0, _swig_p) - return -} - -func (_swig_base SwigcptrB2) F__SWIG_0(arg1 int) (_swig_ret int) { - return _swig_wrap_B2_f__SWIG_0(_swig_base, arg1) -} - -var _wrap_B2_f__SWIG_1 unsafe.Pointer - -func _swig_wrap_B2_f__SWIG_1(base SwigcptrB2) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_B2_f__SWIG_1, _swig_p) - return -} - -func (_swig_base SwigcptrB2) F__SWIG_1() (_swig_ret int) { - return _swig_wrap_B2_f__SWIG_1(_swig_base) -} - -func (p SwigcptrB2) F(a ...interface{}) int { - argc := len(a) - if argc == 0 { - return p.F__SWIG_1() - } - if argc == 1 { - return p.F__SWIG_0(a[0].(int)) - } - panic("No match for overloaded function call") -} - -func (p SwigcptrB2) SwigIsA2() { -} - -func (p SwigcptrB2) SwigGetA2() A2 { - return SwigcptrA2(p.Swigcptr()) -} - -type B2 interface { - Swigcptr() uintptr - SwigIsB2() - DirectorInterface() interface{} - F(a ...interface{}) int - SwigIsA2() - SwigGetA2() A2 -} - - -type SwigcptrSwigDirector_A uintptr -type SwigDirector_A interface { - Swigcptr() uintptr; -} -func (p SwigcptrSwigDirector_A) Swigcptr() uintptr { - return uintptr(p) -} - -type SwigcptrSwigDirector_B uintptr -type SwigDirector_B interface { - Swigcptr() uintptr; -} -func (p SwigcptrSwigDirector_B) Swigcptr() uintptr { - return uintptr(p) -} - -type SwigcptrSwigDirector_Foo uintptr -type SwigDirector_Foo interface { - Swigcptr() uintptr; -} -func (p SwigcptrSwigDirector_Foo) Swigcptr() uintptr { - return uintptr(p) -} - -type SwigcptrSwigDirector_B2 uintptr -type SwigDirector_B2 interface { - Swigcptr() uintptr; -} -func (p SwigcptrSwigDirector_B2) Swigcptr() uintptr { - return uintptr(p) -} - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - -type SwigcptrSwigDirector_A2 uintptr -type SwigDirector_A2 interface { - Swigcptr() uintptr; -} -func (p SwigcptrSwigDirector_A2) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/director_enum_runme b/Examples/test-suite/go/director_enum_runme deleted file mode 100755 index ad202226f..000000000 Binary files a/Examples/test-suite/go/director_enum_runme and /dev/null differ diff --git a/Examples/test-suite/go/director_enum_wrap.h b/Examples/test-suite/go/director_enum_wrap.h deleted file mode 100644 index 8173ee1a7..000000000 --- a/Examples/test-suite/go/director_enum_wrap.h +++ /dev/null @@ -1,114 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../director_enum.i - -#ifndef SWIG_director_enum_WRAP_H_ -#define SWIG_director_enum_WRAP_H_ - -class SwigDirector_Foo : public EnumDirector::Foo -{ - public: - SwigDirector_Foo(void *swig_p); - virtual ~SwigDirector_Foo(); - EnumDirector::Hello _swig_upcall_say_hi__SWIG_0(EnumDirector::Hello h) { - return EnumDirector::Foo::say_hi(h); - } - virtual EnumDirector::Hello say_hi(EnumDirector::Hello h); - EnumDirector::Hello _swig_upcall_say_hello(EnumDirector::Hello arg0) { - return EnumDirector::Foo::say_hello(arg0); - } - virtual EnumDirector::Hello say_hello(EnumDirector::Hello arg0); - EnumDirector::Hello _swig_upcall_say_hi__SWIG_1(EnumDirector::A *a) { - return EnumDirector::Foo::say_hi(a); - } - virtual EnumDirector::Hello say_hi(EnumDirector::A *a); - EnumDirector::Foo::Bye _swig_upcall_say_bye(EnumDirector::Foo::Bye b) { - return EnumDirector::Foo::say_bye(b); - } - virtual EnumDirector::Foo::Bye say_bye(EnumDirector::Foo::Bye b); - EnumDirector::Hello const &_swig_upcall_say_hi_ref(EnumDirector::Hello const &h) { - return EnumDirector::Foo::say_hi_ref(h); - } - virtual EnumDirector::Hello const &say_hi_ref(EnumDirector::Hello const &h); - private: - void *go_val; -}; - -class SwigDirector_A : public EnumDirector::A -{ - public: - SwigDirector_A(void *swig_p, double const a, double const b, EnumDirector::FType const c); - virtual ~SwigDirector_A(); - int _swig_upcall_f__SWIG_0(int i) { - return EnumDirector::A::f(i); - } - virtual int f(int i); - int _swig_upcall_f__SWIG_1() { - return EnumDirector::A::f(); - } - virtual int f(); - private: - void *go_val; -}; - -class SwigDirector_B : public EnumDirector::B -{ - public: - SwigDirector_B(void *swig_p, double const a, double const b, EnumDirector::FType const c); - virtual ~SwigDirector_B(); - int _swig_upcall_f__SWIG_0(int i) { - return EnumDirector::A::f(i); - } - virtual int f(int i); - int _swig_upcall_f__SWIG_1() { - return EnumDirector::A::f(); - } - virtual int f(); - private: - void *go_val; -}; - -class SwigDirector_A2 : public EnumDirector::A2 -{ - public: - SwigDirector_A2(void *swig_p, EnumDirector::FType const c); - SwigDirector_A2(void *swig_p); - virtual ~SwigDirector_A2(); - int _swig_upcall_f__SWIG_0(int i) { - return EnumDirector::A2::f(i); - } - virtual int f(int i); - int _swig_upcall_f__SWIG_1() { - return EnumDirector::A2::f(); - } - virtual int f(); - private: - void *go_val; -}; - -class SwigDirector_B2 : public EnumDirector::B2 -{ - public: - SwigDirector_B2(void *swig_p, EnumDirector::FType const c); - virtual ~SwigDirector_B2(); - int _swig_upcall_f__SWIG_0(int i) { - return EnumDirector::A2::f(i); - } - virtual int f(int i); - int _swig_upcall_f__SWIG_1() { - return EnumDirector::A2::f(); - } - virtual int f(); - private: - void *go_val; -}; - -#endif diff --git a/Examples/test-suite/go/director_exception.go b/Examples/test-suite/go/director_exception.go deleted file mode 100644 index 50f6c8885..000000000 --- a/Examples/test-suite/go/director_exception.go +++ /dev/null @@ -1,1066 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../director_exception.i - -package director_exception - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type _swig_DirectorFoo struct { - SwigcptrFoo - v interface{} -} - -func (p *_swig_DirectorFoo) Swigcptr() uintptr { - return p.SwigcptrFoo.Swigcptr() -} - -func (p *_swig_DirectorFoo) SwigIsFoo() { -} - -func (p *_swig_DirectorFoo) DirectorInterface() interface{} { - return p.v -} - -var _wrap__swig_NewDirectorFooFoo unsafe.Pointer - -func _swig_NewDirectorFooFoo(_swig_director *_swig_DirectorFoo) (_swig_ret SwigcptrFoo) { - _swig_p := uintptr(unsafe.Pointer(&_swig_director)) - _cgo_runtime_cgocall(_wrap__swig_NewDirectorFooFoo, _swig_p) - return -} - -func NewDirectorFoo(v interface{}) Foo { - p := &_swig_DirectorFoo{0, v} - p.SwigcptrFoo = _swig_NewDirectorFooFoo(p) - return p -} - -var _wrap_DeleteDirectorFoo unsafe.Pointer - -func _swig_wrap_DeleteDirectorFoo(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_DeleteDirectorFoo, _swig_p) - return -} - -func DeleteDirectorFoo(arg1 Foo) { - _swig_wrap_DeleteDirectorFoo(arg1.Swigcptr()) -} - -func Swiggo_DeleteDirector_Foo(p *_swig_DirectorFoo) { - p.SwigcptrFoo = 0 -} - -type _swig_DirectorInterfaceFooPing interface { - Ping() string -} - -var _wrap__swig_DirectorFoo_upcall_Ping unsafe.Pointer - -func _swig_wrap__swig_DirectorFoo_upcall_Ping(_swig_ptr SwigcptrFoo) (_swig_ret string) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) - _cgo_runtime_cgocall(_wrap__swig_DirectorFoo_upcall_Ping, _swig_p) - return -} - -func (swig_p *_swig_DirectorFoo) Ping() string { - if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceFooPing); swig_ok { - return swig_g.Ping() - } - var swig_r string - swig_r = _swig_wrap__swig_DirectorFoo_upcall_Ping(swig_p.SwigcptrFoo) - return swig_r -} - -func DirectorFooPing(p Foo) string { - var swig_r string - swig_r = _swig_wrap__swig_DirectorFoo_upcall_Ping(p.(*_swig_DirectorFoo).SwigcptrFoo) - return swig_r -} - -func Swig_DirectorFoo_callback_ping(p *_swig_DirectorFoo) (swig_result string) { - var swig_r string - swig_r = p.Ping() - return swig_r -} - -type _swig_DirectorInterfaceFooPong__SWIG_0 interface { - Pong__SWIG_0(int) string -} - -var _wrap__swig_DirectorFoo_upcall_Pong__SWIG_0 unsafe.Pointer - -func _swig_wrap__swig_DirectorFoo_upcall_Pong__SWIG_0(_swig_ptr SwigcptrFoo, _ int) (_swig_ret string) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) - _cgo_runtime_cgocall(_wrap__swig_DirectorFoo_upcall_Pong__SWIG_0, _swig_p) - return -} - -func (swig_p *_swig_DirectorFoo) Pong__SWIG_0(val int) string { - if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceFooPong__SWIG_0); swig_ok { - return swig_g.Pong__SWIG_0(val) - } - var swig_r string - swig_r = _swig_wrap__swig_DirectorFoo_upcall_Pong__SWIG_0(swig_p.SwigcptrFoo, val) - return swig_r -} - -func DirectorFooPong__SWIG_0(p Foo, arg2 int) string { - var swig_r string - swig_r = _swig_wrap__swig_DirectorFoo_upcall_Pong__SWIG_0(p.(*_swig_DirectorFoo).SwigcptrFoo, arg2) - return swig_r -} - -func Swig_DirectorFoo_callback_pong__SWIG_0(p *_swig_DirectorFoo, arg2 int) (swig_result string) { - var swig_r string - swig_r = p.Pong__SWIG_0(arg2) - return swig_r -} - -type _swig_DirectorInterfaceFooPong__SWIG_1 interface { - Pong__SWIG_1() string -} - -var _wrap__swig_DirectorFoo_upcall_Pong__SWIG_1 unsafe.Pointer - -func _swig_wrap__swig_DirectorFoo_upcall_Pong__SWIG_1(_swig_ptr SwigcptrFoo) (_swig_ret string) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) - _cgo_runtime_cgocall(_wrap__swig_DirectorFoo_upcall_Pong__SWIG_1, _swig_p) - return -} - -func (swig_p *_swig_DirectorFoo) Pong__SWIG_1() string { - if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceFooPong__SWIG_1); swig_ok { - return swig_g.Pong__SWIG_1() - } - var swig_r string - swig_r = _swig_wrap__swig_DirectorFoo_upcall_Pong__SWIG_1(swig_p.SwigcptrFoo) - return swig_r -} - -func DirectorFooPong__SWIG_1(p Foo) string { - var swig_r string - swig_r = _swig_wrap__swig_DirectorFoo_upcall_Pong__SWIG_1(p.(*_swig_DirectorFoo).SwigcptrFoo) - return swig_r -} - -func Swig_DirectorFoo_callback_pong__SWIG_1(p *_swig_DirectorFoo) (swig_result string) { - var swig_r string - swig_r = p.Pong__SWIG_1() - return swig_r -} - -func (p _swig_DirectorFoo) Pong(a ...interface{}) string { - argc := len(a) - if argc == 0 { - return p.Pong__SWIG_1() - } - if argc == 1 { - return p.Pong__SWIG_0(a[0].(int)) - } - panic("No match for overloaded function call") -} - -func DirectorFooPong(p *_swig_DirectorFoo, a ...interface{}) string { - argc := len(a) - if argc == 0 { - return DirectorFooPong__SWIG_1(p) - } - if argc == 1 { - return DirectorFooPong__SWIG_0(p, a[0].(int)) - } - panic("No match for overloaded function call") -} - -type SwigcptrFoo uintptr - -func (p SwigcptrFoo) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrFoo) SwigIsFoo() { -} - -func (p SwigcptrFoo) DirectorInterface() interface{} { - return nil -} - -var _wrap_delete_Foo unsafe.Pointer - -func _swig_wrap_delete_Foo(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Foo, _swig_p) - return -} - -func DeleteFoo(arg1 Foo) { - _swig_wrap_delete_Foo(arg1.Swigcptr()) -} - -var _wrap_Foo_ping unsafe.Pointer - -func _swig_wrap_Foo_ping(base SwigcptrFoo) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_ping, _swig_p) - return -} - -func (arg1 SwigcptrFoo) Ping() (_swig_ret string) { - return _swig_wrap_Foo_ping(arg1) -} - -var _wrap_Foo_pong__SWIG_0 unsafe.Pointer - -func _swig_wrap_Foo_pong__SWIG_0(base SwigcptrFoo, _ int) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_pong__SWIG_0, _swig_p) - return -} - -func (arg1 SwigcptrFoo) Pong__SWIG_0(arg2 int) (_swig_ret string) { - return _swig_wrap_Foo_pong__SWIG_0(arg1, arg2) -} - -var _wrap_Foo_pong__SWIG_1 unsafe.Pointer - -func _swig_wrap_Foo_pong__SWIG_1(base SwigcptrFoo) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_pong__SWIG_1, _swig_p) - return -} - -func (arg1 SwigcptrFoo) Pong__SWIG_1() (_swig_ret string) { - return _swig_wrap_Foo_pong__SWIG_1(arg1) -} - -func (p SwigcptrFoo) Pong(a ...interface{}) string { - argc := len(a) - if argc == 0 { - return p.Pong__SWIG_1() - } - if argc == 1 { - return p.Pong__SWIG_0(a[0].(int)) - } - panic("No match for overloaded function call") -} - -var _wrap_new_Foo unsafe.Pointer - -func _swig_wrap_new_Foo() (base SwigcptrFoo) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Foo, _swig_p) - return -} - -func NewFoo() (_swig_ret Foo) { - return _swig_wrap_new_Foo() -} - -type Foo interface { - Swigcptr() uintptr - SwigIsFoo() - DirectorInterface() interface{} - Ping() (_swig_ret string) - Pong(a ...interface{}) string -} - -var _wrap_launder unsafe.Pointer - -func _swig_wrap_launder(base uintptr) (_ SwigcptrFoo) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_launder, _swig_p) - return -} - -func Launder(arg1 Foo) (_swig_ret Foo) { - return _swig_wrap_launder(arg1.Swigcptr()) -} - -type SwigcptrException1 uintptr - -func (p SwigcptrException1) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrException1) SwigIsException1() { -} - -var _wrap_new_Exception1 unsafe.Pointer - -func _swig_wrap_new_Exception1() (base SwigcptrException1) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Exception1, _swig_p) - return -} - -func NewException1() (_swig_ret Exception1) { - return _swig_wrap_new_Exception1() -} - -var _wrap_delete_Exception1 unsafe.Pointer - -func _swig_wrap_delete_Exception1(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Exception1, _swig_p) - return -} - -func DeleteException1(arg1 Exception1) { - _swig_wrap_delete_Exception1(arg1.Swigcptr()) -} - -type Exception1 interface { - Swigcptr() uintptr - SwigIsException1() -} - -type SwigcptrException2 uintptr - -func (p SwigcptrException2) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrException2) SwigIsException2() { -} - -var _wrap_new_Exception2 unsafe.Pointer - -func _swig_wrap_new_Exception2() (base SwigcptrException2) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Exception2, _swig_p) - return -} - -func NewException2() (_swig_ret Exception2) { - return _swig_wrap_new_Exception2() -} - -var _wrap_delete_Exception2 unsafe.Pointer - -func _swig_wrap_delete_Exception2(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Exception2, _swig_p) - return -} - -func DeleteException2(arg1 Exception2) { - _swig_wrap_delete_Exception2(arg1.Swigcptr()) -} - -type Exception2 interface { - Swigcptr() uintptr - SwigIsException2() -} - -type SwigcptrBase uintptr - -func (p SwigcptrBase) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrBase) SwigIsBase() { -} - -var _wrap_delete_Base unsafe.Pointer - -func _swig_wrap_delete_Base(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Base, _swig_p) - return -} - -func DeleteBase(arg1 Base) { - _swig_wrap_delete_Base(arg1.Swigcptr()) -} - -var _wrap_new_Base unsafe.Pointer - -func _swig_wrap_new_Base() (base SwigcptrBase) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Base, _swig_p) - return -} - -func NewBase() (_swig_ret Base) { - return _swig_wrap_new_Base() -} - -type Base interface { - Swigcptr() uintptr - SwigIsBase() -} - -type _swig_DirectorBar struct { - SwigcptrBar - v interface{} -} - -func (p *_swig_DirectorBar) Swigcptr() uintptr { - return p.SwigcptrBar.Swigcptr() -} - -func (p *_swig_DirectorBar) SwigIsBar() { -} - -func (p *_swig_DirectorBar) DirectorInterface() interface{} { - return p.v -} - -var _wrap__swig_NewDirectorBarBar unsafe.Pointer - -func _swig_NewDirectorBarBar(_swig_director *_swig_DirectorBar) (_swig_ret SwigcptrBar) { - _swig_p := uintptr(unsafe.Pointer(&_swig_director)) - _cgo_runtime_cgocall(_wrap__swig_NewDirectorBarBar, _swig_p) - return -} - -func NewDirectorBar(v interface{}) Bar { - p := &_swig_DirectorBar{0, v} - p.SwigcptrBar = _swig_NewDirectorBarBar(p) - return p -} - -var _wrap_DeleteDirectorBar unsafe.Pointer - -func _swig_wrap_DeleteDirectorBar(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_DeleteDirectorBar, _swig_p) - return -} - -func DeleteDirectorBar(arg1 Bar) { - _swig_wrap_DeleteDirectorBar(arg1.Swigcptr()) -} - -func Swiggo_DeleteDirector_Bar(p *_swig_DirectorBar) { - p.SwigcptrBar = 0 -} - -type _swig_DirectorInterfaceBarPing interface { - Ping() string -} - -var _wrap__swig_DirectorBar_upcall_Ping unsafe.Pointer - -func _swig_wrap__swig_DirectorBar_upcall_Ping(_swig_ptr SwigcptrBar) (_swig_ret string) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) - _cgo_runtime_cgocall(_wrap__swig_DirectorBar_upcall_Ping, _swig_p) - return -} - -func (swig_p *_swig_DirectorBar) Ping() string { - if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceBarPing); swig_ok { - return swig_g.Ping() - } - var swig_r string - swig_r = _swig_wrap__swig_DirectorBar_upcall_Ping(swig_p.SwigcptrBar) - return swig_r -} - -func DirectorBarPing(p Bar) string { - var swig_r string - swig_r = _swig_wrap__swig_DirectorBar_upcall_Ping(p.(*_swig_DirectorBar).SwigcptrBar) - return swig_r -} - -func Swig_DirectorBar_callback_ping(p *_swig_DirectorBar) (swig_result string) { - var swig_r string - swig_r = p.Ping() - return swig_r -} - -type _swig_DirectorInterfaceBarPong interface { - Pong() string -} - -var _wrap__swig_DirectorBar_upcall_Pong unsafe.Pointer - -func _swig_wrap__swig_DirectorBar_upcall_Pong(_swig_ptr SwigcptrBar) (_swig_ret string) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) - _cgo_runtime_cgocall(_wrap__swig_DirectorBar_upcall_Pong, _swig_p) - return -} - -func (swig_p *_swig_DirectorBar) Pong() string { - if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceBarPong); swig_ok { - return swig_g.Pong() - } - var swig_r string - swig_r = _swig_wrap__swig_DirectorBar_upcall_Pong(swig_p.SwigcptrBar) - return swig_r -} - -func DirectorBarPong(p Bar) string { - var swig_r string - swig_r = _swig_wrap__swig_DirectorBar_upcall_Pong(p.(*_swig_DirectorBar).SwigcptrBar) - return swig_r -} - -func Swig_DirectorBar_callback_pong(p *_swig_DirectorBar) (swig_result string) { - var swig_r string - swig_r = p.Pong() - return swig_r -} - -type _swig_DirectorInterfaceBarPang interface { - Pang() string -} - -var _wrap__swig_DirectorBar_upcall_Pang unsafe.Pointer - -func _swig_wrap__swig_DirectorBar_upcall_Pang(_swig_ptr SwigcptrBar) (_swig_ret string) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) - _cgo_runtime_cgocall(_wrap__swig_DirectorBar_upcall_Pang, _swig_p) - return -} - -func (swig_p *_swig_DirectorBar) Pang() string { - if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceBarPang); swig_ok { - return swig_g.Pang() - } - var swig_r string - swig_r = _swig_wrap__swig_DirectorBar_upcall_Pang(swig_p.SwigcptrBar) - return swig_r -} - -func DirectorBarPang(p Bar) string { - var swig_r string - swig_r = _swig_wrap__swig_DirectorBar_upcall_Pang(p.(*_swig_DirectorBar).SwigcptrBar) - return swig_r -} - -func Swig_DirectorBar_callback_pang(p *_swig_DirectorBar) (swig_result string) { - var swig_r string - swig_r = p.Pang() - return swig_r -} - -type SwigcptrBar uintptr - -func (p SwigcptrBar) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrBar) SwigIsBar() { -} - -func (p SwigcptrBar) DirectorInterface() interface{} { - return nil -} - -var _wrap_Bar_ping unsafe.Pointer - -func _swig_wrap_Bar_ping(base SwigcptrBar) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Bar_ping, _swig_p) - return -} - -func (arg1 SwigcptrBar) Ping() (_swig_ret string) { - return _swig_wrap_Bar_ping(arg1) -} - -var _wrap_Bar_pong unsafe.Pointer - -func _swig_wrap_Bar_pong(base SwigcptrBar) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Bar_pong, _swig_p) - return -} - -func (arg1 SwigcptrBar) Pong() (_swig_ret string) { - return _swig_wrap_Bar_pong(arg1) -} - -var _wrap_Bar_pang unsafe.Pointer - -func _swig_wrap_Bar_pang(base SwigcptrBar) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Bar_pang, _swig_p) - return -} - -func (arg1 SwigcptrBar) Pang() (_swig_ret string) { - return _swig_wrap_Bar_pang(arg1) -} - -var _wrap_new_Bar unsafe.Pointer - -func _swig_wrap_new_Bar() (base SwigcptrBar) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Bar, _swig_p) - return -} - -func NewBar() (_swig_ret Bar) { - return _swig_wrap_new_Bar() -} - -var _wrap_delete_Bar unsafe.Pointer - -func _swig_wrap_delete_Bar(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Bar, _swig_p) - return -} - -func DeleteBar(arg1 Bar) { - _swig_wrap_delete_Bar(arg1.Swigcptr()) -} - -func (p SwigcptrBar) SwigIsBase() { -} - -func (p SwigcptrBar) SwigGetBase() Base { - return SwigcptrBase(p.Swigcptr()) -} - -type Bar interface { - Swigcptr() uintptr - SwigIsBar() - DirectorInterface() interface{} - Ping() (_swig_ret string) - Pong() (_swig_ret string) - Pang() (_swig_ret string) - SwigIsBase() - SwigGetBase() Base -} - -type _swig_DirectorReturnAllTypes struct { - SwigcptrReturnAllTypes - v interface{} -} - -func (p *_swig_DirectorReturnAllTypes) Swigcptr() uintptr { - return p.SwigcptrReturnAllTypes.Swigcptr() -} - -func (p *_swig_DirectorReturnAllTypes) SwigIsReturnAllTypes() { -} - -func (p *_swig_DirectorReturnAllTypes) DirectorInterface() interface{} { - return p.v -} - -var _wrap__swig_NewDirectorReturnAllTypesReturnAllTypes unsafe.Pointer - -func _swig_NewDirectorReturnAllTypesReturnAllTypes(_swig_director *_swig_DirectorReturnAllTypes) (_swig_ret SwigcptrReturnAllTypes) { - _swig_p := uintptr(unsafe.Pointer(&_swig_director)) - _cgo_runtime_cgocall(_wrap__swig_NewDirectorReturnAllTypesReturnAllTypes, _swig_p) - return -} - -func NewDirectorReturnAllTypes(v interface{}) ReturnAllTypes { - p := &_swig_DirectorReturnAllTypes{0, v} - p.SwigcptrReturnAllTypes = _swig_NewDirectorReturnAllTypesReturnAllTypes(p) - return p -} - -type _swig_DirectorInterfaceReturnAllTypesReturn_int interface { - Return_int() int -} - -var _wrap__swig_DirectorReturnAllTypes_upcall_Return_int unsafe.Pointer - -func _swig_wrap__swig_DirectorReturnAllTypes_upcall_Return_int(_swig_ptr SwigcptrReturnAllTypes) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) - _cgo_runtime_cgocall(_wrap__swig_DirectorReturnAllTypes_upcall_Return_int, _swig_p) - return -} - -func (swig_p *_swig_DirectorReturnAllTypes) Return_int() int { - if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceReturnAllTypesReturn_int); swig_ok { - return swig_g.Return_int() - } - var swig_r int - swig_r = _swig_wrap__swig_DirectorReturnAllTypes_upcall_Return_int(swig_p.SwigcptrReturnAllTypes) - return swig_r -} - -func DirectorReturnAllTypesReturn_int(p ReturnAllTypes) int { - var swig_r int - swig_r = _swig_wrap__swig_DirectorReturnAllTypes_upcall_Return_int(p.(*_swig_DirectorReturnAllTypes).SwigcptrReturnAllTypes) - return swig_r -} - -func Swig_DirectorReturnAllTypes_callback_return_int(p *_swig_DirectorReturnAllTypes) (swig_result int) { - var swig_r int - swig_r = p.Return_int() - return swig_r -} - -type _swig_DirectorInterfaceReturnAllTypesReturn_double interface { - Return_double() float64 -} - -var _wrap__swig_DirectorReturnAllTypes_upcall_Return_double unsafe.Pointer - -func _swig_wrap__swig_DirectorReturnAllTypes_upcall_Return_double(_swig_ptr SwigcptrReturnAllTypes) (_swig_ret float64) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) - _cgo_runtime_cgocall(_wrap__swig_DirectorReturnAllTypes_upcall_Return_double, _swig_p) - return -} - -func (swig_p *_swig_DirectorReturnAllTypes) Return_double() float64 { - if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceReturnAllTypesReturn_double); swig_ok { - return swig_g.Return_double() - } - var swig_r float64 - swig_r = _swig_wrap__swig_DirectorReturnAllTypes_upcall_Return_double(swig_p.SwigcptrReturnAllTypes) - return swig_r -} - -func DirectorReturnAllTypesReturn_double(p ReturnAllTypes) float64 { - var swig_r float64 - swig_r = _swig_wrap__swig_DirectorReturnAllTypes_upcall_Return_double(p.(*_swig_DirectorReturnAllTypes).SwigcptrReturnAllTypes) - return swig_r -} - -func Swig_DirectorReturnAllTypes_callback_return_double(p *_swig_DirectorReturnAllTypes) (swig_result float64) { - var swig_r float64 - swig_r = p.Return_double() - return swig_r -} - -type _swig_DirectorInterfaceReturnAllTypesReturn_const_char_star interface { - Return_const_char_star() string -} - -var _wrap__swig_DirectorReturnAllTypes_upcall_Return_const_char_star unsafe.Pointer - -func _swig_wrap__swig_DirectorReturnAllTypes_upcall_Return_const_char_star(_swig_ptr SwigcptrReturnAllTypes) (_swig_ret string) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) - _cgo_runtime_cgocall(_wrap__swig_DirectorReturnAllTypes_upcall_Return_const_char_star, _swig_p) - return -} - -func (swig_p *_swig_DirectorReturnAllTypes) Return_const_char_star() string { - if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceReturnAllTypesReturn_const_char_star); swig_ok { - return swig_g.Return_const_char_star() - } - var swig_r string - swig_r = _swig_wrap__swig_DirectorReturnAllTypes_upcall_Return_const_char_star(swig_p.SwigcptrReturnAllTypes) - return swig_r -} - -func DirectorReturnAllTypesReturn_const_char_star(p ReturnAllTypes) string { - var swig_r string - swig_r = _swig_wrap__swig_DirectorReturnAllTypes_upcall_Return_const_char_star(p.(*_swig_DirectorReturnAllTypes).SwigcptrReturnAllTypes) - return swig_r -} - -func Swig_DirectorReturnAllTypes_callback_return_const_char_star(p *_swig_DirectorReturnAllTypes) (swig_result string) { - var swig_r string - swig_r = p.Return_const_char_star() - return swig_r -} - -type _swig_DirectorInterfaceReturnAllTypesReturn_std_string interface { - Return_std_string() string -} - -var _wrap__swig_DirectorReturnAllTypes_upcall_Return_std_string unsafe.Pointer - -func _swig_wrap__swig_DirectorReturnAllTypes_upcall_Return_std_string(_swig_ptr SwigcptrReturnAllTypes) (_swig_ret string) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) - _cgo_runtime_cgocall(_wrap__swig_DirectorReturnAllTypes_upcall_Return_std_string, _swig_p) - return -} - -func (swig_p *_swig_DirectorReturnAllTypes) Return_std_string() string { - if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceReturnAllTypesReturn_std_string); swig_ok { - return swig_g.Return_std_string() - } - var swig_r string - swig_r = _swig_wrap__swig_DirectorReturnAllTypes_upcall_Return_std_string(swig_p.SwigcptrReturnAllTypes) - return swig_r -} - -func DirectorReturnAllTypesReturn_std_string(p ReturnAllTypes) string { - var swig_r string - swig_r = _swig_wrap__swig_DirectorReturnAllTypes_upcall_Return_std_string(p.(*_swig_DirectorReturnAllTypes).SwigcptrReturnAllTypes) - return swig_r -} - -func Swig_DirectorReturnAllTypes_callback_return_std_string(p *_swig_DirectorReturnAllTypes) (swig_result string) { - var swig_r string - swig_r = p.Return_std_string() - return swig_r -} - -type _swig_DirectorInterfaceReturnAllTypesReturn_Bar interface { - Return_Bar() Bar -} - -var _wrap__swig_DirectorReturnAllTypes_upcall_Return_Bar unsafe.Pointer - -func _swig_wrap__swig_DirectorReturnAllTypes_upcall_Return_Bar(_swig_ptr SwigcptrReturnAllTypes) (_swig_ret SwigcptrBar) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) - _cgo_runtime_cgocall(_wrap__swig_DirectorReturnAllTypes_upcall_Return_Bar, _swig_p) - return -} - -func (swig_p *_swig_DirectorReturnAllTypes) Return_Bar() Bar { - if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceReturnAllTypesReturn_Bar); swig_ok { - return swig_g.Return_Bar() - } - var swig_r Bar - swig_r = _swig_wrap__swig_DirectorReturnAllTypes_upcall_Return_Bar(swig_p.SwigcptrReturnAllTypes) - return swig_r -} - -func DirectorReturnAllTypesReturn_Bar(p ReturnAllTypes) Bar { - var swig_r Bar - swig_r = _swig_wrap__swig_DirectorReturnAllTypes_upcall_Return_Bar(p.(*_swig_DirectorReturnAllTypes).SwigcptrReturnAllTypes) - return swig_r -} - -func Swig_DirectorReturnAllTypes_callback_return_Bar(p *_swig_DirectorReturnAllTypes) (swig_result SwigcptrBar) { - var swig_r SwigcptrBar - swig_r = SwigcptrBar(p.Return_Bar().Swigcptr()) - return swig_r -} - -var _wrap_DeleteDirectorReturnAllTypes unsafe.Pointer - -func _swig_wrap_DeleteDirectorReturnAllTypes(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_DeleteDirectorReturnAllTypes, _swig_p) - return -} - -func DeleteDirectorReturnAllTypes(arg1 ReturnAllTypes) { - _swig_wrap_DeleteDirectorReturnAllTypes(arg1.Swigcptr()) -} - -func Swiggo_DeleteDirector_ReturnAllTypes(p *_swig_DirectorReturnAllTypes) { - p.SwigcptrReturnAllTypes = 0 -} - -type SwigcptrReturnAllTypes uintptr - -func (p SwigcptrReturnAllTypes) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrReturnAllTypes) SwigIsReturnAllTypes() { -} - -func (p SwigcptrReturnAllTypes) DirectorInterface() interface{} { - return nil -} - -var _wrap_ReturnAllTypes_call_int unsafe.Pointer - -func _swig_wrap_ReturnAllTypes_call_int(base SwigcptrReturnAllTypes) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_ReturnAllTypes_call_int, _swig_p) - return -} - -func (arg1 SwigcptrReturnAllTypes) Call_int() (_swig_ret int) { - return _swig_wrap_ReturnAllTypes_call_int(arg1) -} - -var _wrap_ReturnAllTypes_call_double unsafe.Pointer - -func _swig_wrap_ReturnAllTypes_call_double(base SwigcptrReturnAllTypes) (_ float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_ReturnAllTypes_call_double, _swig_p) - return -} - -func (arg1 SwigcptrReturnAllTypes) Call_double() (_swig_ret float64) { - return _swig_wrap_ReturnAllTypes_call_double(arg1) -} - -var _wrap_ReturnAllTypes_call_const_char_star unsafe.Pointer - -func _swig_wrap_ReturnAllTypes_call_const_char_star(base SwigcptrReturnAllTypes) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_ReturnAllTypes_call_const_char_star, _swig_p) - return -} - -func (arg1 SwigcptrReturnAllTypes) Call_const_char_star() (_swig_ret string) { - return _swig_wrap_ReturnAllTypes_call_const_char_star(arg1) -} - -var _wrap_ReturnAllTypes_call_std_string unsafe.Pointer - -func _swig_wrap_ReturnAllTypes_call_std_string(base SwigcptrReturnAllTypes) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_ReturnAllTypes_call_std_string, _swig_p) - return -} - -func (arg1 SwigcptrReturnAllTypes) Call_std_string() (_swig_ret string) { - return _swig_wrap_ReturnAllTypes_call_std_string(arg1) -} - -var _wrap_ReturnAllTypes_call_Bar unsafe.Pointer - -func _swig_wrap_ReturnAllTypes_call_Bar(base SwigcptrReturnAllTypes) (_ SwigcptrBar) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_ReturnAllTypes_call_Bar, _swig_p) - return -} - -func (arg1 SwigcptrReturnAllTypes) Call_Bar() (_swig_ret Bar) { - return _swig_wrap_ReturnAllTypes_call_Bar(arg1) -} - -var _wrap_ReturnAllTypes_return_int unsafe.Pointer - -func _swig_wrap_ReturnAllTypes_return_int(base SwigcptrReturnAllTypes) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_ReturnAllTypes_return_int, _swig_p) - return -} - -func (arg1 SwigcptrReturnAllTypes) Return_int() (_swig_ret int) { - return _swig_wrap_ReturnAllTypes_return_int(arg1) -} - -var _wrap_ReturnAllTypes_return_double unsafe.Pointer - -func _swig_wrap_ReturnAllTypes_return_double(base SwigcptrReturnAllTypes) (_ float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_ReturnAllTypes_return_double, _swig_p) - return -} - -func (arg1 SwigcptrReturnAllTypes) Return_double() (_swig_ret float64) { - return _swig_wrap_ReturnAllTypes_return_double(arg1) -} - -var _wrap_ReturnAllTypes_return_const_char_star unsafe.Pointer - -func _swig_wrap_ReturnAllTypes_return_const_char_star(base SwigcptrReturnAllTypes) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_ReturnAllTypes_return_const_char_star, _swig_p) - return -} - -func (arg1 SwigcptrReturnAllTypes) Return_const_char_star() (_swig_ret string) { - return _swig_wrap_ReturnAllTypes_return_const_char_star(arg1) -} - -var _wrap_ReturnAllTypes_return_std_string unsafe.Pointer - -func _swig_wrap_ReturnAllTypes_return_std_string(base SwigcptrReturnAllTypes) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_ReturnAllTypes_return_std_string, _swig_p) - return -} - -func (arg1 SwigcptrReturnAllTypes) Return_std_string() (_swig_ret string) { - return _swig_wrap_ReturnAllTypes_return_std_string(arg1) -} - -var _wrap_ReturnAllTypes_return_Bar unsafe.Pointer - -func _swig_wrap_ReturnAllTypes_return_Bar(base SwigcptrReturnAllTypes) (_ SwigcptrBar) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_ReturnAllTypes_return_Bar, _swig_p) - return -} - -func (arg1 SwigcptrReturnAllTypes) Return_Bar() (_swig_ret Bar) { - return _swig_wrap_ReturnAllTypes_return_Bar(arg1) -} - -var _wrap_delete_ReturnAllTypes unsafe.Pointer - -func _swig_wrap_delete_ReturnAllTypes(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_ReturnAllTypes, _swig_p) - return -} - -func DeleteReturnAllTypes(arg1 ReturnAllTypes) { - _swig_wrap_delete_ReturnAllTypes(arg1.Swigcptr()) -} - -var _wrap_new_ReturnAllTypes unsafe.Pointer - -func _swig_wrap_new_ReturnAllTypes() (base SwigcptrReturnAllTypes) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_ReturnAllTypes, _swig_p) - return -} - -func NewReturnAllTypes() (_swig_ret ReturnAllTypes) { - return _swig_wrap_new_ReturnAllTypes() -} - -type ReturnAllTypes interface { - Swigcptr() uintptr - SwigIsReturnAllTypes() - DirectorInterface() interface{} - Call_int() (_swig_ret int) - Call_double() (_swig_ret float64) - Call_const_char_star() (_swig_ret string) - Call_std_string() (_swig_ret string) - Call_Bar() (_swig_ret Bar) - Return_int() (_swig_ret int) - Return_double() (_swig_ret float64) - Return_const_char_star() (_swig_ret string) - Return_std_string() (_swig_ret string) - Return_Bar() (_swig_ret Bar) -} - - -type SwigcptrSwigDirector_ReturnAllTypes uintptr -type SwigDirector_ReturnAllTypes interface { - Swigcptr() uintptr; -} -func (p SwigcptrSwigDirector_ReturnAllTypes) Swigcptr() uintptr { - return uintptr(p) -} - -type SwigcptrSwigDirector_Foo uintptr -type SwigDirector_Foo interface { - Swigcptr() uintptr; -} -func (p SwigcptrSwigDirector_Foo) Swigcptr() uintptr { - return uintptr(p) -} - -type SwigcptrSwigDirector_Bar uintptr -type SwigDirector_Bar interface { - Swigcptr() uintptr; -} -func (p SwigcptrSwigDirector_Bar) Swigcptr() uintptr { - return uintptr(p) -} - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/director_exception_runme b/Examples/test-suite/go/director_exception_runme deleted file mode 100755 index 77b5f04d5..000000000 Binary files a/Examples/test-suite/go/director_exception_runme and /dev/null differ diff --git a/Examples/test-suite/go/director_exception_wrap.h b/Examples/test-suite/go/director_exception_wrap.h deleted file mode 100644 index 53d2ff6a0..000000000 --- a/Examples/test-suite/go/director_exception_wrap.h +++ /dev/null @@ -1,87 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../director_exception.i - -#ifndef SWIG_director_exception_WRAP_H_ -#define SWIG_director_exception_WRAP_H_ - -class SwigDirector_Foo : public Foo -{ - public: - SwigDirector_Foo(void *swig_p); - virtual ~SwigDirector_Foo(); - std::string _swig_upcall_ping() { - return Foo::ping(); - } - virtual std::string ping(); - std::string _swig_upcall_pong__SWIG_0(int val) { - return Foo::pong(val); - } - virtual std::string pong(int val); - std::string _swig_upcall_pong__SWIG_1() { - return Foo::pong(); - } - virtual std::string pong(); - private: - void *go_val; -}; - -class SwigDirector_Bar : public Bar -{ - public: - SwigDirector_Bar(void *swig_p); - virtual ~SwigDirector_Bar() throw(); - std::string _swig_upcall_ping() { - return Bar::ping(); - } - virtual std::string ping() throw(Exception1, Exception2 &); - std::string _swig_upcall_pong() { - return Bar::pong(); - } - virtual std::string pong() throw(Unknown1, int, Unknown2 &); - std::string _swig_upcall_pang() { - return Bar::pang(); - } - virtual std::string pang() throw(); - private: - void *go_val; -}; - -class SwigDirector_ReturnAllTypes : public ReturnAllTypes -{ - public: - SwigDirector_ReturnAllTypes(void *swig_p); - int _swig_upcall_return_int() { - return ReturnAllTypes::return_int(); - } - virtual int return_int(); - double _swig_upcall_return_double() { - return ReturnAllTypes::return_double(); - } - virtual double return_double(); - char const *_swig_upcall_return_const_char_star() { - return ReturnAllTypes::return_const_char_star(); - } - virtual char const *return_const_char_star(); - std::string _swig_upcall_return_std_string() { - return ReturnAllTypes::return_std_string(); - } - virtual std::string return_std_string(); - Bar _swig_upcall_return_Bar() { - return ReturnAllTypes::return_Bar(); - } - virtual Bar return_Bar(); - virtual ~SwigDirector_ReturnAllTypes(); - private: - void *go_val; -}; - -#endif diff --git a/Examples/test-suite/go/director_extend.go b/Examples/test-suite/go/director_extend.go deleted file mode 100644 index a49852131..000000000 --- a/Examples/test-suite/go/director_extend.go +++ /dev/null @@ -1,101 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../director_extend.i - -package director_extend - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrSpObject uintptr - -func (p SwigcptrSpObject) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrSpObject) SwigIsSpObject() { -} - -var _wrap_new_SpObject unsafe.Pointer - -func _swig_wrap_new_SpObject() (base SwigcptrSpObject) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_SpObject, _swig_p) - return -} - -func NewSpObject() (_swig_ret SpObject) { - return _swig_wrap_new_SpObject() -} - -var _wrap_delete_SpObject unsafe.Pointer - -func _swig_wrap_delete_SpObject(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_SpObject, _swig_p) - return -} - -func DeleteSpObject(arg1 SpObject) { - _swig_wrap_delete_SpObject(arg1.Swigcptr()) -} - -var _wrap_SpObject_getFooBar unsafe.Pointer - -func _swig_wrap_SpObject_getFooBar(base SwigcptrSpObject) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_SpObject_getFooBar, _swig_p) - return -} - -func (arg1 SwigcptrSpObject) GetFooBar() (_swig_ret int) { - return _swig_wrap_SpObject_getFooBar(arg1) -} - -var _wrap_SpObject_dummy unsafe.Pointer - -func _swig_wrap_SpObject_dummy(base SwigcptrSpObject) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_SpObject_dummy, _swig_p) - return -} - -func (arg1 SwigcptrSpObject) Dummy() (_swig_ret int) { - return _swig_wrap_SpObject_dummy(arg1) -} - -type SpObject interface { - Swigcptr() uintptr - SwigIsSpObject() - GetFooBar() (_swig_ret int) - Dummy() (_swig_ret int) -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/director_extend_runme b/Examples/test-suite/go/director_extend_runme deleted file mode 100755 index d947b2b50..000000000 Binary files a/Examples/test-suite/go/director_extend_runme and /dev/null differ diff --git a/Examples/test-suite/go/director_extend_wrap.h b/Examples/test-suite/go/director_extend_wrap.h deleted file mode 100644 index 8fc4e4d1b..000000000 --- a/Examples/test-suite/go/director_extend_wrap.h +++ /dev/null @@ -1,16 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../director_extend.i - -#ifndef SWIG_director_extend_WRAP_H_ -#define SWIG_director_extend_WRAP_H_ - -#endif diff --git a/Examples/test-suite/go/director_finalizer.go b/Examples/test-suite/go/director_finalizer.go deleted file mode 100644 index 293dfeecf..000000000 --- a/Examples/test-suite/go/director_finalizer.go +++ /dev/null @@ -1,206 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../director_finalizer.i - -package director_finalizer - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type _swig_DirectorFoo struct { - SwigcptrFoo - v interface{} -} - -func (p *_swig_DirectorFoo) Swigcptr() uintptr { - return p.SwigcptrFoo.Swigcptr() -} - -func (p *_swig_DirectorFoo) SwigIsFoo() { -} - -func (p *_swig_DirectorFoo) DirectorInterface() interface{} { - return p.v -} - -var _wrap__swig_NewDirectorFooFoo unsafe.Pointer - -func _swig_NewDirectorFooFoo(_swig_director *_swig_DirectorFoo) (_swig_ret SwigcptrFoo) { - _swig_p := uintptr(unsafe.Pointer(&_swig_director)) - _cgo_runtime_cgocall(_wrap__swig_NewDirectorFooFoo, _swig_p) - return -} - -func NewDirectorFoo(v interface{}) Foo { - p := &_swig_DirectorFoo{0, v} - p.SwigcptrFoo = _swig_NewDirectorFooFoo(p) - return p -} - -var _wrap_DeleteDirectorFoo unsafe.Pointer - -func _swig_wrap_DeleteDirectorFoo(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_DeleteDirectorFoo, _swig_p) - return -} - -func DeleteDirectorFoo(arg1 Foo) { - _swig_wrap_DeleteDirectorFoo(arg1.Swigcptr()) -} - -func Swiggo_DeleteDirector_Foo(p *_swig_DirectorFoo) { - p.SwigcptrFoo = 0 -} - -type _swig_DirectorInterfaceFooOrStatus interface { - OrStatus(int) -} - -var _wrap__swig_DirectorFoo_upcall_OrStatus unsafe.Pointer - -func _swig_wrap__swig_DirectorFoo_upcall_OrStatus(_swig_ptr SwigcptrFoo, _ int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) - _cgo_runtime_cgocall(_wrap__swig_DirectorFoo_upcall_OrStatus, _swig_p) - return -} - -func (swig_p *_swig_DirectorFoo) OrStatus(x int) { - if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceFooOrStatus); swig_ok { - swig_g.OrStatus(x) - return - } - _swig_wrap__swig_DirectorFoo_upcall_OrStatus(swig_p.SwigcptrFoo, x) -} - -func DirectorFooOrStatus(p Foo, arg2 int) { - _swig_wrap__swig_DirectorFoo_upcall_OrStatus(p.(*_swig_DirectorFoo).SwigcptrFoo, arg2) -} - -func Swig_DirectorFoo_callback_orStatus(p *_swig_DirectorFoo, arg2 int) { - p.OrStatus(arg2) -} - -type SwigcptrFoo uintptr - -func (p SwigcptrFoo) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrFoo) SwigIsFoo() { -} - -func (p SwigcptrFoo) DirectorInterface() interface{} { - return nil -} - -var _wrap_delete_Foo unsafe.Pointer - -func _swig_wrap_delete_Foo(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Foo, _swig_p) - return -} - -func DeleteFoo(arg1 Foo) { - _swig_wrap_delete_Foo(arg1.Swigcptr()) -} - -var _wrap_Foo_orStatus unsafe.Pointer - -func _swig_wrap_Foo_orStatus(base SwigcptrFoo, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_orStatus, _swig_p) - return -} - -func (arg1 SwigcptrFoo) OrStatus(arg2 int) { - _swig_wrap_Foo_orStatus(arg1, arg2) -} - -var _wrap_new_Foo unsafe.Pointer - -func _swig_wrap_new_Foo() (base SwigcptrFoo) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Foo, _swig_p) - return -} - -func NewFoo() (_swig_ret Foo) { - return _swig_wrap_new_Foo() -} - -type Foo interface { - Swigcptr() uintptr - SwigIsFoo() - DirectorInterface() interface{} - OrStatus(arg2 int) -} - -var _wrap_getStatus unsafe.Pointer - -func GetStatus() (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_getStatus, _swig_p) - return -} -var _wrap_launder unsafe.Pointer - -func _swig_wrap_launder(base uintptr) (_ SwigcptrFoo) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_launder, _swig_p) - return -} - -func Launder(arg1 Foo) (_swig_ret Foo) { - return _swig_wrap_launder(arg1.Swigcptr()) -} - -var _wrap_resetStatus unsafe.Pointer - -func _swig_wrap_resetStatus() { - var _swig_p uintptr - _cgo_runtime_cgocall(_wrap_resetStatus, _swig_p) - return -} - -func ResetStatus() { - _swig_wrap_resetStatus() -} - - -type SwigcptrSwigDirector_Foo uintptr -type SwigDirector_Foo interface { - Swigcptr() uintptr; -} -func (p SwigcptrSwigDirector_Foo) Swigcptr() uintptr { - return uintptr(p) -} - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/director_finalizer_runme b/Examples/test-suite/go/director_finalizer_runme deleted file mode 100755 index 6e2484102..000000000 Binary files a/Examples/test-suite/go/director_finalizer_runme and /dev/null differ diff --git a/Examples/test-suite/go/director_finalizer_wrap.h b/Examples/test-suite/go/director_finalizer_wrap.h deleted file mode 100644 index 07f5451d5..000000000 --- a/Examples/test-suite/go/director_finalizer_wrap.h +++ /dev/null @@ -1,29 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../director_finalizer.i - -#ifndef SWIG_director_finalizer_WRAP_H_ -#define SWIG_director_finalizer_WRAP_H_ - -class SwigDirector_Foo : public Foo -{ - public: - SwigDirector_Foo(void *swig_p); - virtual ~SwigDirector_Foo(); - void _swig_upcall_orStatus(int x) { - Foo::orStatus(x); - } - virtual void orStatus(int x); - private: - void *go_val; -}; - -#endif diff --git a/Examples/test-suite/go/director_frob.go b/Examples/test-suite/go/director_frob.go deleted file mode 100644 index 1ca9f17ee..000000000 --- a/Examples/test-suite/go/director_frob.go +++ /dev/null @@ -1,1493 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../director_frob.i - -package director_frob - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type _swig_DirectorAlpha struct { - SwigcptrAlpha - v interface{} -} - -func (p *_swig_DirectorAlpha) Swigcptr() uintptr { - return p.SwigcptrAlpha.Swigcptr() -} - -func (p *_swig_DirectorAlpha) SwigIsAlpha() { -} - -func (p *_swig_DirectorAlpha) DirectorInterface() interface{} { - return p.v -} - -var _wrap__swig_NewDirectorAlphaAlpha unsafe.Pointer - -func _swig_NewDirectorAlphaAlpha(_swig_director *_swig_DirectorAlpha) (_swig_ret SwigcptrAlpha) { - _swig_p := uintptr(unsafe.Pointer(&_swig_director)) - _cgo_runtime_cgocall(_wrap__swig_NewDirectorAlphaAlpha, _swig_p) - return -} - -func NewDirectorAlpha(v interface{}) Alpha { - p := &_swig_DirectorAlpha{0, v} - p.SwigcptrAlpha = _swig_NewDirectorAlphaAlpha(p) - return p -} - -var _wrap_DeleteDirectorAlpha unsafe.Pointer - -func _swig_wrap_DeleteDirectorAlpha(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_DeleteDirectorAlpha, _swig_p) - return -} - -func DeleteDirectorAlpha(arg1 Alpha) { - _swig_wrap_DeleteDirectorAlpha(arg1.Swigcptr()) -} - -func Swiggo_DeleteDirector_Alpha(p *_swig_DirectorAlpha) { - p.SwigcptrAlpha = 0 -} - -type _swig_DirectorInterfaceAlphaAbs_method interface { - Abs_method() string -} - -func (swig_p *_swig_DirectorAlpha) Abs_method() string { - if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceAlphaAbs_method); swig_ok { - return swig_g.Abs_method() - } - panic("call to pure virtual method") -} - -func Swig_DirectorAlpha_callback_abs_method(p *_swig_DirectorAlpha) (swig_result string) { - var swig_r string - swig_r = p.Abs_method() - return swig_r -} - -type SwigcptrAlpha uintptr - -func (p SwigcptrAlpha) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrAlpha) SwigIsAlpha() { -} - -func (p SwigcptrAlpha) DirectorInterface() interface{} { - return nil -} - -var _wrap_delete_Alpha unsafe.Pointer - -func _swig_wrap_delete_Alpha(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Alpha, _swig_p) - return -} - -func DeleteAlpha(arg1 Alpha) { - _swig_wrap_delete_Alpha(arg1.Swigcptr()) -} - -var _wrap_Alpha_abs_method unsafe.Pointer - -func _swig_wrap_Alpha_abs_method(base SwigcptrAlpha) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Alpha_abs_method, _swig_p) - return -} - -func (arg1 SwigcptrAlpha) Abs_method() (_swig_ret string) { - return _swig_wrap_Alpha_abs_method(arg1) -} - -var _wrap_new_Alpha unsafe.Pointer - -func _swig_wrap_new_Alpha() (base SwigcptrAlpha) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Alpha, _swig_p) - return -} - -func NewAlpha() (_swig_ret Alpha) { - return _swig_wrap_new_Alpha() -} - -type Alpha interface { - Swigcptr() uintptr - SwigIsAlpha() - DirectorInterface() interface{} - Abs_method() (_swig_ret string) -} - -type _swig_DirectorBravo struct { - SwigcptrBravo - v interface{} -} - -func (p *_swig_DirectorBravo) Swigcptr() uintptr { - return p.SwigcptrBravo.Swigcptr() -} - -func (p *_swig_DirectorBravo) SwigIsBravo() { -} - -func (p *_swig_DirectorBravo) DirectorInterface() interface{} { - return p.v -} - -var _wrap__swig_NewDirectorBravoBravo unsafe.Pointer - -func _swig_NewDirectorBravoBravo(_swig_director *_swig_DirectorBravo) (_swig_ret SwigcptrBravo) { - _swig_p := uintptr(unsafe.Pointer(&_swig_director)) - _cgo_runtime_cgocall(_wrap__swig_NewDirectorBravoBravo, _swig_p) - return -} - -func NewDirectorBravo(v interface{}) Bravo { - p := &_swig_DirectorBravo{0, v} - p.SwigcptrBravo = _swig_NewDirectorBravoBravo(p) - return p -} - -var _wrap_DeleteDirectorBravo unsafe.Pointer - -func _swig_wrap_DeleteDirectorBravo(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_DeleteDirectorBravo, _swig_p) - return -} - -func DeleteDirectorBravo(arg1 Bravo) { - _swig_wrap_DeleteDirectorBravo(arg1.Swigcptr()) -} - -func Swiggo_DeleteDirector_Bravo(p *_swig_DirectorBravo) { - p.SwigcptrBravo = 0 -} - -type SwigcptrBravo uintptr - -func (p SwigcptrBravo) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrBravo) SwigIsBravo() { -} - -func (p SwigcptrBravo) DirectorInterface() interface{} { - return nil -} - -var _wrap_Bravo_abs_method unsafe.Pointer - -func _swig_wrap_Bravo_abs_method(base SwigcptrBravo) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Bravo_abs_method, _swig_p) - return -} - -func (arg1 SwigcptrBravo) Abs_method() (_swig_ret string) { - return _swig_wrap_Bravo_abs_method(arg1) -} - -var _wrap_new_Bravo unsafe.Pointer - -func _swig_wrap_new_Bravo() (base SwigcptrBravo) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Bravo, _swig_p) - return -} - -func NewBravo() (_swig_ret Bravo) { - return _swig_wrap_new_Bravo() -} - -var _wrap_delete_Bravo unsafe.Pointer - -func _swig_wrap_delete_Bravo(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Bravo, _swig_p) - return -} - -func DeleteBravo(arg1 Bravo) { - _swig_wrap_delete_Bravo(arg1.Swigcptr()) -} - -func (p SwigcptrBravo) SwigIsAlpha() { -} - -func (p SwigcptrBravo) SwigGetAlpha() Alpha { - return SwigcptrAlpha(p.Swigcptr()) -} - -type Bravo interface { - Swigcptr() uintptr - SwigIsBravo() - DirectorInterface() interface{} - Abs_method() (_swig_ret string) - SwigIsAlpha() - SwigGetAlpha() Alpha -} - -type _swig_DirectorCharlie struct { - SwigcptrCharlie - v interface{} -} - -func (p *_swig_DirectorCharlie) Swigcptr() uintptr { - return p.SwigcptrCharlie.Swigcptr() -} - -func (p *_swig_DirectorCharlie) SwigIsCharlie() { -} - -func (p *_swig_DirectorCharlie) DirectorInterface() interface{} { - return p.v -} - -var _wrap__swig_NewDirectorCharlieCharlie unsafe.Pointer - -func _swig_NewDirectorCharlieCharlie(_swig_director *_swig_DirectorCharlie) (_swig_ret SwigcptrCharlie) { - _swig_p := uintptr(unsafe.Pointer(&_swig_director)) - _cgo_runtime_cgocall(_wrap__swig_NewDirectorCharlieCharlie, _swig_p) - return -} - -func NewDirectorCharlie(v interface{}) Charlie { - p := &_swig_DirectorCharlie{0, v} - p.SwigcptrCharlie = _swig_NewDirectorCharlieCharlie(p) - return p -} - -var _wrap_DeleteDirectorCharlie unsafe.Pointer - -func _swig_wrap_DeleteDirectorCharlie(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_DeleteDirectorCharlie, _swig_p) - return -} - -func DeleteDirectorCharlie(arg1 Charlie) { - _swig_wrap_DeleteDirectorCharlie(arg1.Swigcptr()) -} - -func Swiggo_DeleteDirector_Charlie(p *_swig_DirectorCharlie) { - p.SwigcptrCharlie = 0 -} - -type _swig_DirectorInterfaceCharlieAbs_method interface { - Abs_method() string -} - -var _wrap__swig_DirectorCharlie_upcall_Abs_method unsafe.Pointer - -func _swig_wrap__swig_DirectorCharlie_upcall_Abs_method(_swig_ptr SwigcptrCharlie) (_swig_ret string) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) - _cgo_runtime_cgocall(_wrap__swig_DirectorCharlie_upcall_Abs_method, _swig_p) - return -} - -func (swig_p *_swig_DirectorCharlie) Abs_method() string { - if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceCharlieAbs_method); swig_ok { - return swig_g.Abs_method() - } - var swig_r string - swig_r = _swig_wrap__swig_DirectorCharlie_upcall_Abs_method(swig_p.SwigcptrCharlie) - return swig_r -} - -func DirectorCharlieAbs_method(p Charlie) string { - var swig_r string - swig_r = _swig_wrap__swig_DirectorCharlie_upcall_Abs_method(p.(*_swig_DirectorCharlie).SwigcptrCharlie) - return swig_r -} - -func Swig_DirectorCharlie_callback_abs_method(p *_swig_DirectorCharlie) (swig_result string) { - var swig_r string - swig_r = p.Abs_method() - return swig_r -} - -type SwigcptrCharlie uintptr - -func (p SwigcptrCharlie) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrCharlie) SwigIsCharlie() { -} - -func (p SwigcptrCharlie) DirectorInterface() interface{} { - return nil -} - -var _wrap_Charlie_abs_method unsafe.Pointer - -func _swig_wrap_Charlie_abs_method(base SwigcptrCharlie) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Charlie_abs_method, _swig_p) - return -} - -func (arg1 SwigcptrCharlie) Abs_method() (_swig_ret string) { - return _swig_wrap_Charlie_abs_method(arg1) -} - -var _wrap_new_Charlie unsafe.Pointer - -func _swig_wrap_new_Charlie() (base SwigcptrCharlie) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Charlie, _swig_p) - return -} - -func NewCharlie() (_swig_ret Charlie) { - return _swig_wrap_new_Charlie() -} - -var _wrap_delete_Charlie unsafe.Pointer - -func _swig_wrap_delete_Charlie(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Charlie, _swig_p) - return -} - -func DeleteCharlie(arg1 Charlie) { - _swig_wrap_delete_Charlie(arg1.Swigcptr()) -} - -func (p SwigcptrCharlie) SwigIsBravo() { -} - -func (p SwigcptrCharlie) SwigGetBravo() Bravo { - return SwigcptrBravo(p.Swigcptr()) -} - -func (p SwigcptrCharlie) SwigIsAlpha() { -} - -func (p SwigcptrCharlie) SwigGetAlpha() Alpha { - return SwigcptrAlpha(p.Swigcptr()) -} - -type Charlie interface { - Swigcptr() uintptr - SwigIsCharlie() - DirectorInterface() interface{} - Abs_method() (_swig_ret string) - SwigIsBravo() - SwigGetBravo() Bravo - SwigIsAlpha() - SwigGetAlpha() Alpha -} - -type _swig_DirectorDelta struct { - SwigcptrDelta - v interface{} -} - -func (p *_swig_DirectorDelta) Swigcptr() uintptr { - return p.SwigcptrDelta.Swigcptr() -} - -func (p *_swig_DirectorDelta) SwigIsDelta() { -} - -func (p *_swig_DirectorDelta) DirectorInterface() interface{} { - return p.v -} - -var _wrap__swig_NewDirectorDeltaDelta unsafe.Pointer - -func _swig_NewDirectorDeltaDelta(_swig_director *_swig_DirectorDelta) (_swig_ret SwigcptrDelta) { - _swig_p := uintptr(unsafe.Pointer(&_swig_director)) - _cgo_runtime_cgocall(_wrap__swig_NewDirectorDeltaDelta, _swig_p) - return -} - -func NewDirectorDelta(v interface{}) Delta { - p := &_swig_DirectorDelta{0, v} - p.SwigcptrDelta = _swig_NewDirectorDeltaDelta(p) - return p -} - -var _wrap_DeleteDirectorDelta unsafe.Pointer - -func _swig_wrap_DeleteDirectorDelta(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_DeleteDirectorDelta, _swig_p) - return -} - -func DeleteDirectorDelta(arg1 Delta) { - _swig_wrap_DeleteDirectorDelta(arg1.Swigcptr()) -} - -func Swiggo_DeleteDirector_Delta(p *_swig_DirectorDelta) { - p.SwigcptrDelta = 0 -} - -type _swig_DirectorInterfaceDeltaAbs_method interface { - Abs_method() string -} - -var _wrap__swig_DirectorDelta_upcall_Abs_method unsafe.Pointer - -func _swig_wrap__swig_DirectorDelta_upcall_Abs_method(_swig_ptr SwigcptrDelta) (_swig_ret string) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) - _cgo_runtime_cgocall(_wrap__swig_DirectorDelta_upcall_Abs_method, _swig_p) - return -} - -func (swig_p *_swig_DirectorDelta) Abs_method() string { - if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceDeltaAbs_method); swig_ok { - return swig_g.Abs_method() - } - var swig_r string - swig_r = _swig_wrap__swig_DirectorDelta_upcall_Abs_method(swig_p.SwigcptrDelta) - return swig_r -} - -func DirectorDeltaAbs_method(p Delta) string { - var swig_r string - swig_r = _swig_wrap__swig_DirectorDelta_upcall_Abs_method(p.(*_swig_DirectorDelta).SwigcptrDelta) - return swig_r -} - -func Swig_DirectorDelta_callback_abs_method(p *_swig_DirectorDelta) (swig_result string) { - var swig_r string - swig_r = p.Abs_method() - return swig_r -} - -type SwigcptrDelta uintptr - -func (p SwigcptrDelta) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrDelta) SwigIsDelta() { -} - -func (p SwigcptrDelta) DirectorInterface() interface{} { - return nil -} - -var _wrap_new_Delta unsafe.Pointer - -func _swig_wrap_new_Delta() (base SwigcptrDelta) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Delta, _swig_p) - return -} - -func NewDelta() (_swig_ret Delta) { - return _swig_wrap_new_Delta() -} - -var _wrap_delete_Delta unsafe.Pointer - -func _swig_wrap_delete_Delta(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Delta, _swig_p) - return -} - -func DeleteDelta(arg1 Delta) { - _swig_wrap_delete_Delta(arg1.Swigcptr()) -} - -var _wrap_Delta_abs_method unsafe.Pointer - -func _swig_wrap_Delta_abs_method(base SwigcptrDelta) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Delta_abs_method, _swig_p) - return -} - -func (_swig_base SwigcptrDelta) Abs_method() (_swig_ret string) { - return _swig_wrap_Delta_abs_method(_swig_base) -} - -func (p SwigcptrDelta) SwigIsCharlie() { -} - -func (p SwigcptrDelta) SwigGetCharlie() Charlie { - return SwigcptrCharlie(p.Swigcptr()) -} - -func (p SwigcptrDelta) SwigIsBravo() { -} - -func (p SwigcptrDelta) SwigGetBravo() Bravo { - return SwigcptrBravo(p.Swigcptr()) -} - -func (p SwigcptrDelta) SwigIsAlpha() { -} - -func (p SwigcptrDelta) SwigGetAlpha() Alpha { - return SwigcptrAlpha(p.Swigcptr()) -} - -type Delta interface { - Swigcptr() uintptr - SwigIsDelta() - DirectorInterface() interface{} - Abs_method() (_swig_ret string) - SwigIsCharlie() - SwigGetCharlie() Charlie - SwigIsBravo() - SwigGetBravo() Bravo - SwigIsAlpha() - SwigGetAlpha() Alpha -} - -type _swig_DirectorOps struct { - SwigcptrOps - v interface{} -} - -func (p *_swig_DirectorOps) Swigcptr() uintptr { - return p.SwigcptrOps.Swigcptr() -} - -func (p *_swig_DirectorOps) SwigIsOps() { -} - -func (p *_swig_DirectorOps) DirectorInterface() interface{} { - return p.v -} - -var _wrap__swig_NewDirectorOpsOps unsafe.Pointer - -func _swig_NewDirectorOpsOps(_swig_director *_swig_DirectorOps) (_swig_ret SwigcptrOps) { - _swig_p := uintptr(unsafe.Pointer(&_swig_director)) - _cgo_runtime_cgocall(_wrap__swig_NewDirectorOpsOps, _swig_p) - return -} - -func NewDirectorOps(v interface{}) Ops { - p := &_swig_DirectorOps{0, v} - p.SwigcptrOps = _swig_NewDirectorOpsOps(p) - return p -} - -var _wrap_DeleteDirectorOps unsafe.Pointer - -func _swig_wrap_DeleteDirectorOps(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_DeleteDirectorOps, _swig_p) - return -} - -func DeleteDirectorOps(arg1 Ops) { - _swig_wrap_DeleteDirectorOps(arg1.Swigcptr()) -} - -func Swiggo_DeleteDirector_Ops(p *_swig_DirectorOps) { - p.SwigcptrOps = 0 -} - -type _swig_DirectorInterfaceOpsOpInt interface { - OpInt() int -} - -var _wrap__swig_DirectorOps_upcall_OpInt unsafe.Pointer - -func _swig_wrap__swig_DirectorOps_upcall_OpInt(_swig_ptr SwigcptrOps) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) - _cgo_runtime_cgocall(_wrap__swig_DirectorOps_upcall_OpInt, _swig_p) - return -} - -func (swig_p *_swig_DirectorOps) OpInt() int { - if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceOpsOpInt); swig_ok { - return swig_g.OpInt() - } - var swig_r int - swig_r = _swig_wrap__swig_DirectorOps_upcall_OpInt(swig_p.SwigcptrOps) - return swig_r -} - -func DirectorOpsOpInt(p Ops) int { - var swig_r int - swig_r = _swig_wrap__swig_DirectorOps_upcall_OpInt(p.(*_swig_DirectorOps).SwigcptrOps) - return swig_r -} - -func Swig_DirectorOps_callback_OpInt(p *_swig_DirectorOps) (swig_result int) { - var swig_r int - swig_r = p.OpInt() - return swig_r -} - -type _swig_DirectorInterfaceOpsOpIntStarStarConst interface { - OpIntStarStarConst() **int -} - -var _wrap__swig_DirectorOps_upcall_OpIntStarStarConst unsafe.Pointer - -func _swig_wrap__swig_DirectorOps_upcall_OpIntStarStarConst(_swig_ptr SwigcptrOps) (_swig_ret **int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) - _cgo_runtime_cgocall(_wrap__swig_DirectorOps_upcall_OpIntStarStarConst, _swig_p) - return -} - -func (swig_p *_swig_DirectorOps) OpIntStarStarConst() **int { - if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceOpsOpIntStarStarConst); swig_ok { - return swig_g.OpIntStarStarConst() - } - var swig_r **int - swig_r = _swig_wrap__swig_DirectorOps_upcall_OpIntStarStarConst(swig_p.SwigcptrOps) - return swig_r -} - -func DirectorOpsOpIntStarStarConst(p Ops) **int { - var swig_r **int - swig_r = _swig_wrap__swig_DirectorOps_upcall_OpIntStarStarConst(p.(*_swig_DirectorOps).SwigcptrOps) - return swig_r -} - -func Swig_DirectorOps_callback_OpIntStarStarConst(p *_swig_DirectorOps) (swig_result **int) { - var swig_r **int - swig_r = p.OpIntStarStarConst() - return swig_r -} - -type _swig_DirectorInterfaceOpsOpIntAmp interface { - OpIntAmp() *int -} - -var _wrap__swig_DirectorOps_upcall_OpIntAmp unsafe.Pointer - -func _swig_wrap__swig_DirectorOps_upcall_OpIntAmp(_swig_ptr SwigcptrOps) (_swig_ret *int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) - _cgo_runtime_cgocall(_wrap__swig_DirectorOps_upcall_OpIntAmp, _swig_p) - return -} - -func (swig_p *_swig_DirectorOps) OpIntAmp() *int { - if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceOpsOpIntAmp); swig_ok { - return swig_g.OpIntAmp() - } - var swig_r *int - swig_r = _swig_wrap__swig_DirectorOps_upcall_OpIntAmp(swig_p.SwigcptrOps) - return swig_r -} - -func DirectorOpsOpIntAmp(p Ops) *int { - var swig_r *int - swig_r = _swig_wrap__swig_DirectorOps_upcall_OpIntAmp(p.(*_swig_DirectorOps).SwigcptrOps) - return swig_r -} - -func Swig_DirectorOps_callback_OpIntAmp(p *_swig_DirectorOps) (swig_result *int) { - var swig_r *int - swig_r = p.OpIntAmp() - return swig_r -} - -type _swig_DirectorInterfaceOpsOpIntStar interface { - OpIntStar() uintptr -} - -var _wrap__swig_DirectorOps_upcall_OpIntStar unsafe.Pointer - -func _swig_wrap__swig_DirectorOps_upcall_OpIntStar(_swig_ptr SwigcptrOps) (_swig_ret uintptr) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) - _cgo_runtime_cgocall(_wrap__swig_DirectorOps_upcall_OpIntStar, _swig_p) - return -} - -func (swig_p *_swig_DirectorOps) OpIntStar() uintptr { - if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceOpsOpIntStar); swig_ok { - return swig_g.OpIntStar() - } - var swig_r uintptr - swig_r = _swig_wrap__swig_DirectorOps_upcall_OpIntStar(swig_p.SwigcptrOps) - return swig_r -} - -func DirectorOpsOpIntStar(p Ops) uintptr { - var swig_r uintptr - swig_r = _swig_wrap__swig_DirectorOps_upcall_OpIntStar(p.(*_swig_DirectorOps).SwigcptrOps) - return swig_r -} - -func Swig_DirectorOps_callback_OpIntStar(p *_swig_DirectorOps) (swig_result uintptr) { - var swig_r uintptr - swig_r = p.OpIntStar() - return swig_r -} - -type _swig_DirectorInterfaceOpsOpConstIntIntStar interface { - OpConstIntIntStar() *int -} - -var _wrap__swig_DirectorOps_upcall_OpConstIntIntStar unsafe.Pointer - -func _swig_wrap__swig_DirectorOps_upcall_OpConstIntIntStar(_swig_ptr SwigcptrOps) (_swig_ret *int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) - _cgo_runtime_cgocall(_wrap__swig_DirectorOps_upcall_OpConstIntIntStar, _swig_p) - return -} - -func (swig_p *_swig_DirectorOps) OpConstIntIntStar() *int { - if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceOpsOpConstIntIntStar); swig_ok { - return swig_g.OpConstIntIntStar() - } - var swig_r *int - swig_r = _swig_wrap__swig_DirectorOps_upcall_OpConstIntIntStar(swig_p.SwigcptrOps) - return swig_r -} - -func DirectorOpsOpConstIntIntStar(p Ops) *int { - var swig_r *int - swig_r = _swig_wrap__swig_DirectorOps_upcall_OpConstIntIntStar(p.(*_swig_DirectorOps).SwigcptrOps) - return swig_r -} - -func Swig_DirectorOps_callback_OpConstIntIntStar(p *_swig_DirectorOps) (swig_result *int) { - var swig_r *int - swig_r = p.OpConstIntIntStar() - return swig_r -} - -type SwigcptrOps uintptr - -func (p SwigcptrOps) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrOps) SwigIsOps() { -} - -func (p SwigcptrOps) DirectorInterface() interface{} { - return nil -} - -var _wrap_new_Ops unsafe.Pointer - -func _swig_wrap_new_Ops() (base SwigcptrOps) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Ops, _swig_p) - return -} - -func NewOps() (_swig_ret Ops) { - return _swig_wrap_new_Ops() -} - -var _wrap_delete_Ops unsafe.Pointer - -func _swig_wrap_delete_Ops(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Ops, _swig_p) - return -} - -func DeleteOps(arg1 Ops) { - _swig_wrap_delete_Ops(arg1.Swigcptr()) -} - -var _wrap_Ops_OpInt unsafe.Pointer - -func _swig_wrap_Ops_OpInt(base SwigcptrOps) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Ops_OpInt, _swig_p) - return -} - -func (arg1 SwigcptrOps) OpInt() (_swig_ret int) { - return _swig_wrap_Ops_OpInt(arg1) -} - -var _wrap_Ops_OpIntStarStarConst unsafe.Pointer - -func _swig_wrap_Ops_OpIntStarStarConst(base SwigcptrOps) (_ **int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Ops_OpIntStarStarConst, _swig_p) - return -} - -func (arg1 SwigcptrOps) OpIntStarStarConst() (_swig_ret **int) { - return _swig_wrap_Ops_OpIntStarStarConst(arg1) -} - -var _wrap_Ops_OpIntAmp unsafe.Pointer - -func _swig_wrap_Ops_OpIntAmp(base SwigcptrOps) (_ *int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Ops_OpIntAmp, _swig_p) - return -} - -func (arg1 SwigcptrOps) OpIntAmp() (_swig_ret *int) { - return _swig_wrap_Ops_OpIntAmp(arg1) -} - -var _wrap_Ops_OpIntStar unsafe.Pointer - -func _swig_wrap_Ops_OpIntStar(base SwigcptrOps) (_ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Ops_OpIntStar, _swig_p) - return -} - -func (arg1 SwigcptrOps) OpIntStar() (_swig_ret uintptr) { - return _swig_wrap_Ops_OpIntStar(arg1) -} - -var _wrap_Ops_OpConstIntIntStar unsafe.Pointer - -func _swig_wrap_Ops_OpConstIntIntStar(base SwigcptrOps) (_ *int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Ops_OpConstIntIntStar, _swig_p) - return -} - -func (arg1 SwigcptrOps) OpConstIntIntStar() (_swig_ret *int) { - return _swig_wrap_Ops_OpConstIntIntStar(arg1) -} - -type Ops interface { - Swigcptr() uintptr - SwigIsOps() - DirectorInterface() interface{} - OpInt() (_swig_ret int) - OpIntStarStarConst() (_swig_ret **int) - OpIntAmp() (_swig_ret *int) - OpIntStar() (_swig_ret uintptr) - OpConstIntIntStar() (_swig_ret *int) -} - -type _swig_DirectorPrims struct { - SwigcptrPrims - v interface{} -} - -func (p *_swig_DirectorPrims) Swigcptr() uintptr { - return p.SwigcptrPrims.Swigcptr() -} - -func (p *_swig_DirectorPrims) SwigIsPrims() { -} - -func (p *_swig_DirectorPrims) DirectorInterface() interface{} { - return p.v -} - -var _wrap__swig_NewDirectorPrimsPrims unsafe.Pointer - -func _swig_NewDirectorPrimsPrims(_swig_director *_swig_DirectorPrims) (_swig_ret SwigcptrPrims) { - _swig_p := uintptr(unsafe.Pointer(&_swig_director)) - _cgo_runtime_cgocall(_wrap__swig_NewDirectorPrimsPrims, _swig_p) - return -} - -func NewDirectorPrims(v interface{}) Prims { - p := &_swig_DirectorPrims{0, v} - p.SwigcptrPrims = _swig_NewDirectorPrimsPrims(p) - return p -} - -var _wrap_DeleteDirectorPrims unsafe.Pointer - -func _swig_wrap_DeleteDirectorPrims(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_DeleteDirectorPrims, _swig_p) - return -} - -func DeleteDirectorPrims(arg1 Prims) { - _swig_wrap_DeleteDirectorPrims(arg1.Swigcptr()) -} - -func Swiggo_DeleteDirector_Prims(p *_swig_DirectorPrims) { - p.SwigcptrPrims = 0 -} - -type _swig_DirectorInterfacePrimsUll interface { - Ull(uint64, uint64) uint64 -} - -var _wrap__swig_DirectorPrims_upcall_Ull unsafe.Pointer - -func _swig_wrap__swig_DirectorPrims_upcall_Ull(_swig_ptr SwigcptrPrims, _ uint64, _ uint64) (_swig_ret uint64) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) - _cgo_runtime_cgocall(_wrap__swig_DirectorPrims_upcall_Ull, _swig_p) - return -} - -func (swig_p *_swig_DirectorPrims) Ull(i uint64, j uint64) uint64 { - if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfacePrimsUll); swig_ok { - return swig_g.Ull(i, j) - } - var swig_r uint64 - swig_r = _swig_wrap__swig_DirectorPrims_upcall_Ull(swig_p.SwigcptrPrims, i, j) - return swig_r -} - -func DirectorPrimsUll(p Prims, arg2 uint64, arg3 uint64) uint64 { - var swig_r uint64 - swig_r = _swig_wrap__swig_DirectorPrims_upcall_Ull(p.(*_swig_DirectorPrims).SwigcptrPrims, arg2, arg3) - return swig_r -} - -func Swig_DirectorPrims_callback_ull(p *_swig_DirectorPrims, arg2 uint64, arg3 uint64) (swig_result uint64) { - var swig_r uint64 - swig_r = p.Ull(arg2, arg3) - return swig_r -} - -type SwigcptrPrims uintptr - -func (p SwigcptrPrims) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrPrims) SwigIsPrims() { -} - -func (p SwigcptrPrims) DirectorInterface() interface{} { - return nil -} - -var _wrap_delete_Prims unsafe.Pointer - -func _swig_wrap_delete_Prims(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Prims, _swig_p) - return -} - -func DeletePrims(arg1 Prims) { - _swig_wrap_delete_Prims(arg1.Swigcptr()) -} - -var _wrap_Prims_ull unsafe.Pointer - -func _swig_wrap_Prims_ull(base SwigcptrPrims, _ uint64, _ uint64) (_ uint64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Prims_ull, _swig_p) - return -} - -func (arg1 SwigcptrPrims) Ull(arg2 uint64, arg3 uint64) (_swig_ret uint64) { - return _swig_wrap_Prims_ull(arg1, arg2, arg3) -} - -var _wrap_Prims_callull unsafe.Pointer - -func _swig_wrap_Prims_callull(base SwigcptrPrims, _ int, _ int) (_ uint64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Prims_callull, _swig_p) - return -} - -func (arg1 SwigcptrPrims) Callull(arg2 int, arg3 int) (_swig_ret uint64) { - return _swig_wrap_Prims_callull(arg1, arg2, arg3) -} - -var _wrap_new_Prims unsafe.Pointer - -func _swig_wrap_new_Prims() (base SwigcptrPrims) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Prims, _swig_p) - return -} - -func NewPrims() (_swig_ret Prims) { - return _swig_wrap_new_Prims() -} - -type Prims interface { - Swigcptr() uintptr - SwigIsPrims() - DirectorInterface() interface{} - Ull(arg2 uint64, arg3 uint64) (_swig_ret uint64) - Callull(arg2 int, arg3 int) (_swig_ret uint64) -} - -type SwigcptrCorePoint3d uintptr - -func (p SwigcptrCorePoint3d) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrCorePoint3d) SwigIsCorePoint3d() { -} - -func (p SwigcptrCorePoint3d) DirectorInterface() interface{} { - return nil -} - -var _wrap_new_corePoint3d unsafe.Pointer - -func _swig_wrap_new_corePoint3d() (base SwigcptrCorePoint3d) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_corePoint3d, _swig_p) - return -} - -func NewCorePoint3d() (_swig_ret CorePoint3d) { - return _swig_wrap_new_corePoint3d() -} - -var _wrap_delete_corePoint3d unsafe.Pointer - -func _swig_wrap_delete_corePoint3d(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_corePoint3d, _swig_p) - return -} - -func DeleteCorePoint3d(arg1 CorePoint3d) { - _swig_wrap_delete_corePoint3d(arg1.Swigcptr()) -} - -type CorePoint3d interface { - Swigcptr() uintptr - SwigIsCorePoint3d() - DirectorInterface() interface{} -} - -type SwigcptrCoreCallbacks_On3dEngineRedrawnData uintptr - -func (p SwigcptrCoreCallbacks_On3dEngineRedrawnData) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrCoreCallbacks_On3dEngineRedrawnData) SwigIsCoreCallbacks_On3dEngineRedrawnData() { -} - -func (p SwigcptrCoreCallbacks_On3dEngineRedrawnData) DirectorInterface() interface{} { - return nil -} - -var _wrap_coreCallbacks_On3dEngineRedrawnData__eye_set unsafe.Pointer - -func _swig_wrap_coreCallbacks_On3dEngineRedrawnData__eye_set(base SwigcptrCoreCallbacks_On3dEngineRedrawnData, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_coreCallbacks_On3dEngineRedrawnData__eye_set, _swig_p) - return -} - -func (arg1 SwigcptrCoreCallbacks_On3dEngineRedrawnData) SetX_eye(arg2 CorePoint3d) { - _swig_wrap_coreCallbacks_On3dEngineRedrawnData__eye_set(arg1, arg2.Swigcptr()) -} - -var _wrap_coreCallbacks_On3dEngineRedrawnData__eye_get unsafe.Pointer - -func _swig_wrap_coreCallbacks_On3dEngineRedrawnData__eye_get(base SwigcptrCoreCallbacks_On3dEngineRedrawnData) (_ SwigcptrCorePoint3d) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_coreCallbacks_On3dEngineRedrawnData__eye_get, _swig_p) - return -} - -func (arg1 SwigcptrCoreCallbacks_On3dEngineRedrawnData) GetX_eye() (_swig_ret CorePoint3d) { - return _swig_wrap_coreCallbacks_On3dEngineRedrawnData__eye_get(arg1) -} - -var _wrap_coreCallbacks_On3dEngineRedrawnData__at_set unsafe.Pointer - -func _swig_wrap_coreCallbacks_On3dEngineRedrawnData__at_set(base SwigcptrCoreCallbacks_On3dEngineRedrawnData, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_coreCallbacks_On3dEngineRedrawnData__at_set, _swig_p) - return -} - -func (arg1 SwigcptrCoreCallbacks_On3dEngineRedrawnData) SetX_at(arg2 CorePoint3d) { - _swig_wrap_coreCallbacks_On3dEngineRedrawnData__at_set(arg1, arg2.Swigcptr()) -} - -var _wrap_coreCallbacks_On3dEngineRedrawnData__at_get unsafe.Pointer - -func _swig_wrap_coreCallbacks_On3dEngineRedrawnData__at_get(base SwigcptrCoreCallbacks_On3dEngineRedrawnData) (_ SwigcptrCorePoint3d) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_coreCallbacks_On3dEngineRedrawnData__at_get, _swig_p) - return -} - -func (arg1 SwigcptrCoreCallbacks_On3dEngineRedrawnData) GetX_at() (_swig_ret CorePoint3d) { - return _swig_wrap_coreCallbacks_On3dEngineRedrawnData__at_get(arg1) -} - -var _wrap_new_coreCallbacks_On3dEngineRedrawnData unsafe.Pointer - -func _swig_wrap_new_coreCallbacks_On3dEngineRedrawnData() (base SwigcptrCoreCallbacks_On3dEngineRedrawnData) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_coreCallbacks_On3dEngineRedrawnData, _swig_p) - return -} - -func NewCoreCallbacks_On3dEngineRedrawnData() (_swig_ret CoreCallbacks_On3dEngineRedrawnData) { - return _swig_wrap_new_coreCallbacks_On3dEngineRedrawnData() -} - -var _wrap_delete_coreCallbacks_On3dEngineRedrawnData unsafe.Pointer - -func _swig_wrap_delete_coreCallbacks_On3dEngineRedrawnData(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_coreCallbacks_On3dEngineRedrawnData, _swig_p) - return -} - -func DeleteCoreCallbacks_On3dEngineRedrawnData(arg1 CoreCallbacks_On3dEngineRedrawnData) { - _swig_wrap_delete_coreCallbacks_On3dEngineRedrawnData(arg1.Swigcptr()) -} - -type CoreCallbacks_On3dEngineRedrawnData interface { - Swigcptr() uintptr - SwigIsCoreCallbacks_On3dEngineRedrawnData() - DirectorInterface() interface{} - SetX_eye(arg2 CorePoint3d) - GetX_eye() (_swig_ret CorePoint3d) - SetX_at(arg2 CorePoint3d) - GetX_at() (_swig_ret CorePoint3d) -} - -type SwigcptrCoreCallbacksOn3dEngineRedrawnData uintptr - -func (p SwigcptrCoreCallbacksOn3dEngineRedrawnData) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrCoreCallbacksOn3dEngineRedrawnData) SwigIsCoreCallbacksOn3dEngineRedrawnData() { -} - -func (p SwigcptrCoreCallbacksOn3dEngineRedrawnData) DirectorInterface() interface{} { - return nil -} - -var _wrap_coreCallbacksOn3dEngineRedrawnData__eye_set unsafe.Pointer - -func _swig_wrap_coreCallbacksOn3dEngineRedrawnData__eye_set(base SwigcptrCoreCallbacksOn3dEngineRedrawnData, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_coreCallbacksOn3dEngineRedrawnData__eye_set, _swig_p) - return -} - -func (arg1 SwigcptrCoreCallbacksOn3dEngineRedrawnData) SetX_eye(arg2 CorePoint3d) { - _swig_wrap_coreCallbacksOn3dEngineRedrawnData__eye_set(arg1, arg2.Swigcptr()) -} - -var _wrap_coreCallbacksOn3dEngineRedrawnData__eye_get unsafe.Pointer - -func _swig_wrap_coreCallbacksOn3dEngineRedrawnData__eye_get(base SwigcptrCoreCallbacksOn3dEngineRedrawnData) (_ SwigcptrCorePoint3d) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_coreCallbacksOn3dEngineRedrawnData__eye_get, _swig_p) - return -} - -func (arg1 SwigcptrCoreCallbacksOn3dEngineRedrawnData) GetX_eye() (_swig_ret CorePoint3d) { - return _swig_wrap_coreCallbacksOn3dEngineRedrawnData__eye_get(arg1) -} - -var _wrap_coreCallbacksOn3dEngineRedrawnData__at_set unsafe.Pointer - -func _swig_wrap_coreCallbacksOn3dEngineRedrawnData__at_set(base SwigcptrCoreCallbacksOn3dEngineRedrawnData, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_coreCallbacksOn3dEngineRedrawnData__at_set, _swig_p) - return -} - -func (arg1 SwigcptrCoreCallbacksOn3dEngineRedrawnData) SetX_at(arg2 CorePoint3d) { - _swig_wrap_coreCallbacksOn3dEngineRedrawnData__at_set(arg1, arg2.Swigcptr()) -} - -var _wrap_coreCallbacksOn3dEngineRedrawnData__at_get unsafe.Pointer - -func _swig_wrap_coreCallbacksOn3dEngineRedrawnData__at_get(base SwigcptrCoreCallbacksOn3dEngineRedrawnData) (_ SwigcptrCorePoint3d) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_coreCallbacksOn3dEngineRedrawnData__at_get, _swig_p) - return -} - -func (arg1 SwigcptrCoreCallbacksOn3dEngineRedrawnData) GetX_at() (_swig_ret CorePoint3d) { - return _swig_wrap_coreCallbacksOn3dEngineRedrawnData__at_get(arg1) -} - -var _wrap_new_coreCallbacksOn3dEngineRedrawnData unsafe.Pointer - -func _swig_wrap_new_coreCallbacksOn3dEngineRedrawnData() (base SwigcptrCoreCallbacksOn3dEngineRedrawnData) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_coreCallbacksOn3dEngineRedrawnData, _swig_p) - return -} - -func NewCoreCallbacksOn3dEngineRedrawnData() (_swig_ret CoreCallbacksOn3dEngineRedrawnData) { - return _swig_wrap_new_coreCallbacksOn3dEngineRedrawnData() -} - -var _wrap_delete_coreCallbacksOn3dEngineRedrawnData unsafe.Pointer - -func _swig_wrap_delete_coreCallbacksOn3dEngineRedrawnData(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_coreCallbacksOn3dEngineRedrawnData, _swig_p) - return -} - -func DeleteCoreCallbacksOn3dEngineRedrawnData(arg1 CoreCallbacksOn3dEngineRedrawnData) { - _swig_wrap_delete_coreCallbacksOn3dEngineRedrawnData(arg1.Swigcptr()) -} - -type CoreCallbacksOn3dEngineRedrawnData interface { - Swigcptr() uintptr - SwigIsCoreCallbacksOn3dEngineRedrawnData() - DirectorInterface() interface{} - SetX_eye(arg2 CorePoint3d) - GetX_eye() (_swig_ret CorePoint3d) - SetX_at(arg2 CorePoint3d) - GetX_at() (_swig_ret CorePoint3d) -} - -type _swig_DirectorCoreCallbacks struct { - SwigcptrCoreCallbacks - v interface{} -} - -func (p *_swig_DirectorCoreCallbacks) Swigcptr() uintptr { - return p.SwigcptrCoreCallbacks.Swigcptr() -} - -func (p *_swig_DirectorCoreCallbacks) SwigIsCoreCallbacks() { -} - -func (p *_swig_DirectorCoreCallbacks) DirectorInterface() interface{} { - return p.v -} - -var _wrap__swig_NewDirectorCoreCallbacksCoreCallbacks unsafe.Pointer - -func _swig_NewDirectorCoreCallbacksCoreCallbacks(_swig_director *_swig_DirectorCoreCallbacks) (_swig_ret SwigcptrCoreCallbacks) { - _swig_p := uintptr(unsafe.Pointer(&_swig_director)) - _cgo_runtime_cgocall(_wrap__swig_NewDirectorCoreCallbacksCoreCallbacks, _swig_p) - return -} - -func NewDirectorCoreCallbacks(v interface{}) CoreCallbacks { - p := &_swig_DirectorCoreCallbacks{0, v} - p.SwigcptrCoreCallbacks = _swig_NewDirectorCoreCallbacksCoreCallbacks(p) - return p -} - -var _wrap_DeleteDirectorCoreCallbacks unsafe.Pointer - -func _swig_wrap_DeleteDirectorCoreCallbacks(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_DeleteDirectorCoreCallbacks, _swig_p) - return -} - -func DeleteDirectorCoreCallbacks(arg1 CoreCallbacks) { - _swig_wrap_DeleteDirectorCoreCallbacks(arg1.Swigcptr()) -} - -func Swiggo_DeleteDirector_coreCallbacks(p *_swig_DirectorCoreCallbacks) { - p.SwigcptrCoreCallbacks = 0 -} - -type _swig_DirectorInterfaceCoreCallbacksOn3dEngineRedrawn interface { - On3dEngineRedrawn(CoreCallbacks_On3dEngineRedrawnData) -} - -var _wrap__swig_DirectorCoreCallbacks_upcall_On3dEngineRedrawn unsafe.Pointer - -func _swig_wrap__swig_DirectorCoreCallbacks_upcall_On3dEngineRedrawn(_swig_ptr SwigcptrCoreCallbacks, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) - _cgo_runtime_cgocall(_wrap__swig_DirectorCoreCallbacks_upcall_On3dEngineRedrawn, _swig_p) - return -} - -func (swig_p *_swig_DirectorCoreCallbacks) On3dEngineRedrawn(data CoreCallbacks_On3dEngineRedrawnData) { - if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceCoreCallbacksOn3dEngineRedrawn); swig_ok { - swig_g.On3dEngineRedrawn(data) - return - } - _swig_wrap__swig_DirectorCoreCallbacks_upcall_On3dEngineRedrawn(swig_p.SwigcptrCoreCallbacks, data.Swigcptr()) -} - -func DirectorCoreCallbacksOn3dEngineRedrawn(p CoreCallbacks, arg2 CoreCallbacks_On3dEngineRedrawnData) { - _swig_wrap__swig_DirectorCoreCallbacks_upcall_On3dEngineRedrawn(p.(*_swig_DirectorCoreCallbacks).SwigcptrCoreCallbacks, arg2.Swigcptr()) -} - -func Swig_DirectorCoreCallbacks_callback_On3dEngineRedrawn(p *_swig_DirectorCoreCallbacks, arg2 uintptr) { - p.On3dEngineRedrawn(SwigcptrCoreCallbacks_On3dEngineRedrawnData(arg2)) -} - -type _swig_DirectorInterfaceCoreCallbacksOn3dEngineRedrawn2 interface { - On3dEngineRedrawn2(CoreCallbacksOn3dEngineRedrawnData) -} - -var _wrap__swig_DirectorCoreCallbacks_upcall_On3dEngineRedrawn2 unsafe.Pointer - -func _swig_wrap__swig_DirectorCoreCallbacks_upcall_On3dEngineRedrawn2(_swig_ptr SwigcptrCoreCallbacks, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) - _cgo_runtime_cgocall(_wrap__swig_DirectorCoreCallbacks_upcall_On3dEngineRedrawn2, _swig_p) - return -} - -func (swig_p *_swig_DirectorCoreCallbacks) On3dEngineRedrawn2(data CoreCallbacksOn3dEngineRedrawnData) { - if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceCoreCallbacksOn3dEngineRedrawn2); swig_ok { - swig_g.On3dEngineRedrawn2(data) - return - } - _swig_wrap__swig_DirectorCoreCallbacks_upcall_On3dEngineRedrawn2(swig_p.SwigcptrCoreCallbacks, data.Swigcptr()) -} - -func DirectorCoreCallbacksOn3dEngineRedrawn2(p CoreCallbacks, arg2 CoreCallbacksOn3dEngineRedrawnData) { - _swig_wrap__swig_DirectorCoreCallbacks_upcall_On3dEngineRedrawn2(p.(*_swig_DirectorCoreCallbacks).SwigcptrCoreCallbacks, arg2.Swigcptr()) -} - -func Swig_DirectorCoreCallbacks_callback_On3dEngineRedrawn2(p *_swig_DirectorCoreCallbacks, arg2 uintptr) { - p.On3dEngineRedrawn2(SwigcptrCoreCallbacksOn3dEngineRedrawnData(arg2)) -} - -type SwigcptrCoreCallbacks uintptr - -func (p SwigcptrCoreCallbacks) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrCoreCallbacks) SwigIsCoreCallbacks() { -} - -func (p SwigcptrCoreCallbacks) DirectorInterface() interface{} { - return nil -} - -var _wrap_new_coreCallbacks unsafe.Pointer - -func _swig_wrap_new_coreCallbacks() (base SwigcptrCoreCallbacks) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_coreCallbacks, _swig_p) - return -} - -func NewCoreCallbacks() (_swig_ret CoreCallbacks) { - return _swig_wrap_new_coreCallbacks() -} - -var _wrap_delete_coreCallbacks unsafe.Pointer - -func _swig_wrap_delete_coreCallbacks(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_coreCallbacks, _swig_p) - return -} - -func DeleteCoreCallbacks(arg1 CoreCallbacks) { - _swig_wrap_delete_coreCallbacks(arg1.Swigcptr()) -} - -var _wrap_coreCallbacks_On3dEngineRedrawn unsafe.Pointer - -func _swig_wrap_coreCallbacks_On3dEngineRedrawn(base SwigcptrCoreCallbacks, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_coreCallbacks_On3dEngineRedrawn, _swig_p) - return -} - -func (arg1 SwigcptrCoreCallbacks) On3dEngineRedrawn(arg2 CoreCallbacks_On3dEngineRedrawnData) { - _swig_wrap_coreCallbacks_On3dEngineRedrawn(arg1, arg2.Swigcptr()) -} - -var _wrap_coreCallbacks_On3dEngineRedrawn2 unsafe.Pointer - -func _swig_wrap_coreCallbacks_On3dEngineRedrawn2(base SwigcptrCoreCallbacks, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_coreCallbacks_On3dEngineRedrawn2, _swig_p) - return -} - -func (arg1 SwigcptrCoreCallbacks) On3dEngineRedrawn2(arg2 CoreCallbacksOn3dEngineRedrawnData) { - _swig_wrap_coreCallbacks_On3dEngineRedrawn2(arg1, arg2.Swigcptr()) -} - -type CoreCallbacks interface { - Swigcptr() uintptr - SwigIsCoreCallbacks() - DirectorInterface() interface{} - On3dEngineRedrawn(arg2 CoreCallbacks_On3dEngineRedrawnData) - On3dEngineRedrawn2(arg2 CoreCallbacksOn3dEngineRedrawnData) -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - -type SwigcptrSwigDirector_coreCallbacks uintptr -type SwigDirector_coreCallbacks interface { - Swigcptr() uintptr; -} -func (p SwigcptrSwigDirector_coreCallbacks) Swigcptr() uintptr { - return uintptr(p) -} - -type SwigcptrSwigDirector_Ops uintptr -type SwigDirector_Ops interface { - Swigcptr() uintptr; -} -func (p SwigcptrSwigDirector_Ops) Swigcptr() uintptr { - return uintptr(p) -} - -type SwigcptrSwigDirector_Charlie uintptr -type SwigDirector_Charlie interface { - Swigcptr() uintptr; -} -func (p SwigcptrSwigDirector_Charlie) Swigcptr() uintptr { - return uintptr(p) -} - -type SwigcptrSwigDirector_Delta uintptr -type SwigDirector_Delta interface { - Swigcptr() uintptr; -} -func (p SwigcptrSwigDirector_Delta) Swigcptr() uintptr { - return uintptr(p) -} - -type SwigcptrSwigDirector_Prims uintptr -type SwigDirector_Prims interface { - Swigcptr() uintptr; -} -func (p SwigcptrSwigDirector_Prims) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/director_frob_runme b/Examples/test-suite/go/director_frob_runme deleted file mode 100755 index 131e34611..000000000 Binary files a/Examples/test-suite/go/director_frob_runme and /dev/null differ diff --git a/Examples/test-suite/go/director_frob_wrap.h b/Examples/test-suite/go/director_frob_wrap.h deleted file mode 100644 index fe4800b67..000000000 --- a/Examples/test-suite/go/director_frob_wrap.h +++ /dev/null @@ -1,120 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../director_frob.i - -#ifndef SWIG_director_frob_WRAP_H_ -#define SWIG_director_frob_WRAP_H_ - -class SwigDirector_Alpha : public Alpha -{ - public: - SwigDirector_Alpha(void *swig_p); - virtual ~SwigDirector_Alpha(); - virtual char const *abs_method(); - private: - void *go_val; -}; - -class SwigDirector_Bravo : public Bravo -{ - public: - SwigDirector_Bravo(void *swig_p); - virtual ~SwigDirector_Bravo(); - private: - void *go_val; -}; - -class SwigDirector_Charlie : public Charlie -{ - public: - SwigDirector_Charlie(void *swig_p); - virtual ~SwigDirector_Charlie(); - char const *_swig_upcall_abs_method() { - return Charlie::abs_method(); - } - virtual char const *abs_method(); - private: - void *go_val; -}; - -class SwigDirector_Delta : public Delta -{ - public: - SwigDirector_Delta(void *swig_p); - virtual ~SwigDirector_Delta(); - char const *_swig_upcall_abs_method() { - return Charlie::abs_method(); - } - virtual char const *abs_method(); - private: - void *go_val; -}; - -class SwigDirector_Ops : public Ops -{ - public: - SwigDirector_Ops(void *swig_p); - virtual ~SwigDirector_Ops(); - int _swig_upcall_OpInt() { - return Ops::operator int(); - } - virtual operator int(); - int **_swig_upcall_OpIntStarStarConst() const { - return Ops::operator int**(); - } - virtual operator int**() const; - int &_swig_upcall_OpIntAmp() { - return Ops::operator int&(); - } - virtual operator int&(); - void *_swig_upcall_OpIntStar() { - return Ops::operator void*(); - } - virtual operator void*(); - int const *_swig_upcall_OpConstIntIntStar() { - return Ops::operator const int*(); - } - virtual operator const int*(); - private: - void *go_val; -}; - -class SwigDirector_Prims : public Prims -{ - public: - SwigDirector_Prims(void *swig_p); - virtual ~SwigDirector_Prims(); - unsigned long long _swig_upcall_ull(unsigned long long i, unsigned long long j) { - return Prims::ull(i,j); - } - virtual unsigned long long ull(unsigned long long i, unsigned long long j); - private: - void *go_val; -}; - -class SwigDirector_coreCallbacks : public coreCallbacks -{ - public: - SwigDirector_coreCallbacks(void *swig_p); - virtual ~SwigDirector_coreCallbacks(); - void _swig_upcall_On3dEngineRedrawn(coreCallbacks_On3dEngineRedrawnData const &data) { - coreCallbacks::On3dEngineRedrawn(data); - } - virtual void On3dEngineRedrawn(coreCallbacks_On3dEngineRedrawnData const &data); - void _swig_upcall_On3dEngineRedrawn2(coreCallbacksOn3dEngineRedrawnData const &data) { - coreCallbacks::On3dEngineRedrawn2(data); - } - virtual void On3dEngineRedrawn2(coreCallbacksOn3dEngineRedrawnData const &data); - private: - void *go_val; -}; - -#endif diff --git a/Examples/test-suite/go/director_ignore.go b/Examples/test-suite/go/director_ignore.go deleted file mode 100644 index e100eca26..000000000 --- a/Examples/test-suite/go/director_ignore.go +++ /dev/null @@ -1,810 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../director_ignore.i - -package director_ignore - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type _swig_DirectorDIgnores struct { - SwigcptrDIgnores - v interface{} -} - -func (p *_swig_DirectorDIgnores) Swigcptr() uintptr { - return p.SwigcptrDIgnores.Swigcptr() -} - -func (p *_swig_DirectorDIgnores) SwigIsDIgnores() { -} - -func (p *_swig_DirectorDIgnores) DirectorInterface() interface{} { - return p.v -} - -var _wrap__swig_NewDirectorDIgnoresDIgnores unsafe.Pointer - -func _swig_NewDirectorDIgnoresDIgnores(_swig_director *_swig_DirectorDIgnores) (_swig_ret SwigcptrDIgnores) { - _swig_p := uintptr(unsafe.Pointer(&_swig_director)) - _cgo_runtime_cgocall(_wrap__swig_NewDirectorDIgnoresDIgnores, _swig_p) - return -} - -func NewDirectorDIgnores(v interface{}) DIgnores { - p := &_swig_DirectorDIgnores{0, v} - p.SwigcptrDIgnores = _swig_NewDirectorDIgnoresDIgnores(p) - return p -} - -var _wrap_DeleteDirectorDIgnores unsafe.Pointer - -func _swig_wrap_DeleteDirectorDIgnores(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_DeleteDirectorDIgnores, _swig_p) - return -} - -func DeleteDirectorDIgnores(arg1 DIgnores) { - _swig_wrap_DeleteDirectorDIgnores(arg1.Swigcptr()) -} - -func Swiggo_DeleteDirector_DIgnores(p *_swig_DirectorDIgnores) { - p.SwigcptrDIgnores = 0 -} - -type _swig_DirectorInterfaceDIgnoresOverloadedMethod interface { - OverloadedMethod(bool) -} - -var _wrap__swig_DirectorDIgnores_upcall_OverloadedMethod unsafe.Pointer - -func _swig_wrap__swig_DirectorDIgnores_upcall_OverloadedMethod(_swig_ptr SwigcptrDIgnores, _ bool) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) - _cgo_runtime_cgocall(_wrap__swig_DirectorDIgnores_upcall_OverloadedMethod, _swig_p) - return -} - -func (swig_p *_swig_DirectorDIgnores) OverloadedMethod(b bool) { - if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceDIgnoresOverloadedMethod); swig_ok { - swig_g.OverloadedMethod(b) - return - } - _swig_wrap__swig_DirectorDIgnores_upcall_OverloadedMethod(swig_p.SwigcptrDIgnores, b) -} - -func DirectorDIgnoresOverloadedMethod(p DIgnores, arg2 bool) { - _swig_wrap__swig_DirectorDIgnores_upcall_OverloadedMethod(p.(*_swig_DirectorDIgnores).SwigcptrDIgnores, arg2) -} - -func Swig_DirectorDIgnores_callback_OverloadedMethod(p *_swig_DirectorDIgnores, arg2 bool) { - p.OverloadedMethod(arg2) -} - -type _swig_DirectorInterfaceDIgnoresTriple interface { - Triple(int) int -} - -var _wrap__swig_DirectorDIgnores_upcall_Triple unsafe.Pointer - -func _swig_wrap__swig_DirectorDIgnores_upcall_Triple(_swig_ptr SwigcptrDIgnores, _ int) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) - _cgo_runtime_cgocall(_wrap__swig_DirectorDIgnores_upcall_Triple, _swig_p) - return -} - -func (swig_p *_swig_DirectorDIgnores) Triple(n int) int { - if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceDIgnoresTriple); swig_ok { - return swig_g.Triple(n) - } - var swig_r int - swig_r = _swig_wrap__swig_DirectorDIgnores_upcall_Triple(swig_p.SwigcptrDIgnores, n) - return swig_r -} - -func DirectorDIgnoresTriple(p DIgnores, arg2 int) int { - var swig_r int - swig_r = _swig_wrap__swig_DirectorDIgnores_upcall_Triple(p.(*_swig_DirectorDIgnores).SwigcptrDIgnores, arg2) - return swig_r -} - -func Swig_DirectorDIgnores_callback_Triple(p *_swig_DirectorDIgnores, arg2 int) (swig_result int) { - var swig_r int - swig_r = p.Triple(arg2) - return swig_r -} - -type _swig_DirectorInterfaceDIgnoresTempMethod interface { - TempMethod() -} - -func (swig_p *_swig_DirectorDIgnores) TempMethod() { - if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceDIgnoresTempMethod); swig_ok { - swig_g.TempMethod() - return - } - panic("call to pure virtual method") -} - -func Swig_DirectorDIgnores_callback_TempMethod(p *_swig_DirectorDIgnores) { - p.TempMethod() -} - -type _swig_DirectorInterfaceDIgnoresOverloadedProtectedMethod interface { - OverloadedProtectedMethod() -} - -var _wrap__swig_DirectorDIgnores_upcall_OverloadedProtectedMethod unsafe.Pointer - -func _swig_wrap__swig_DirectorDIgnores_upcall_OverloadedProtectedMethod(_swig_ptr SwigcptrDIgnores) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) - _cgo_runtime_cgocall(_wrap__swig_DirectorDIgnores_upcall_OverloadedProtectedMethod, _swig_p) - return -} - -func (swig_p *_swig_DirectorDIgnores) OverloadedProtectedMethod() { - if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceDIgnoresOverloadedProtectedMethod); swig_ok { - swig_g.OverloadedProtectedMethod() - return - } - _swig_wrap__swig_DirectorDIgnores_upcall_OverloadedProtectedMethod(swig_p.SwigcptrDIgnores) -} - -func DirectorDIgnoresOverloadedProtectedMethod(p DIgnores) { - _swig_wrap__swig_DirectorDIgnores_upcall_OverloadedProtectedMethod(p.(*_swig_DirectorDIgnores).SwigcptrDIgnores) -} - -func Swig_DirectorDIgnores_callback_OverloadedProtectedMethod(p *_swig_DirectorDIgnores) { - p.OverloadedProtectedMethod() -} - -type SwigcptrDIgnores uintptr - -func (p SwigcptrDIgnores) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrDIgnores) SwigIsDIgnores() { -} - -func (p SwigcptrDIgnores) DirectorInterface() interface{} { - return nil -} - -var _wrap_delete_DIgnores unsafe.Pointer - -func _swig_wrap_delete_DIgnores(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_DIgnores, _swig_p) - return -} - -func DeleteDIgnores(arg1 DIgnores) { - _swig_wrap_delete_DIgnores(arg1.Swigcptr()) -} - -var _wrap_DIgnores_OverloadedMethod unsafe.Pointer - -func _swig_wrap_DIgnores_OverloadedMethod(base SwigcptrDIgnores, _ bool) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_DIgnores_OverloadedMethod, _swig_p) - return -} - -func (arg1 SwigcptrDIgnores) OverloadedMethod(arg2 bool) { - _swig_wrap_DIgnores_OverloadedMethod(arg1, arg2) -} - -var _wrap_DIgnores_Triple unsafe.Pointer - -func _swig_wrap_DIgnores_Triple(base SwigcptrDIgnores, _ int) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_DIgnores_Triple, _swig_p) - return -} - -func (arg1 SwigcptrDIgnores) Triple(arg2 int) (_swig_ret int) { - return _swig_wrap_DIgnores_Triple(arg1, arg2) -} - -var _wrap_DIgnores_TempMethod unsafe.Pointer - -func _swig_wrap_DIgnores_TempMethod(base SwigcptrDIgnores) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_DIgnores_TempMethod, _swig_p) - return -} - -func (arg1 SwigcptrDIgnores) TempMethod() { - _swig_wrap_DIgnores_TempMethod(arg1) -} - -var _wrap_new_DIgnores unsafe.Pointer - -func _swig_wrap_new_DIgnores() (base SwigcptrDIgnores) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_DIgnores, _swig_p) - return -} - -func NewDIgnores() (_swig_ret DIgnores) { - return _swig_wrap_new_DIgnores() -} - -type DIgnores interface { - Swigcptr() uintptr - SwigIsDIgnores() - DirectorInterface() interface{} - OverloadedMethod(arg2 bool) - Triple(arg2 int) (_swig_ret int) - TempMethod() -} - -type _swig_DirectorDAbstractIgnores struct { - SwigcptrDAbstractIgnores - v interface{} -} - -func (p *_swig_DirectorDAbstractIgnores) Swigcptr() uintptr { - return p.SwigcptrDAbstractIgnores.Swigcptr() -} - -func (p *_swig_DirectorDAbstractIgnores) SwigIsDAbstractIgnores() { -} - -func (p *_swig_DirectorDAbstractIgnores) DirectorInterface() interface{} { - return p.v -} - -var _wrap__swig_NewDirectorDAbstractIgnoresDAbstractIgnores unsafe.Pointer - -func _swig_NewDirectorDAbstractIgnoresDAbstractIgnores(_swig_director *_swig_DirectorDAbstractIgnores) (_swig_ret SwigcptrDAbstractIgnores) { - _swig_p := uintptr(unsafe.Pointer(&_swig_director)) - _cgo_runtime_cgocall(_wrap__swig_NewDirectorDAbstractIgnoresDAbstractIgnores, _swig_p) - return -} - -func NewDirectorDAbstractIgnores(v interface{}) DAbstractIgnores { - p := &_swig_DirectorDAbstractIgnores{0, v} - p.SwigcptrDAbstractIgnores = _swig_NewDirectorDAbstractIgnoresDAbstractIgnores(p) - return p -} - -var _wrap_DeleteDirectorDAbstractIgnores unsafe.Pointer - -func _swig_wrap_DeleteDirectorDAbstractIgnores(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_DeleteDirectorDAbstractIgnores, _swig_p) - return -} - -func DeleteDirectorDAbstractIgnores(arg1 DAbstractIgnores) { - _swig_wrap_DeleteDirectorDAbstractIgnores(arg1.Swigcptr()) -} - -func Swiggo_DeleteDirector_DAbstractIgnores(p *_swig_DirectorDAbstractIgnores) { - p.SwigcptrDAbstractIgnores = 0 -} - -type _swig_DirectorInterfaceDAbstractIgnoresOverloadedMethod interface { - OverloadedMethod(bool) float64 -} - -func (swig_p *_swig_DirectorDAbstractIgnores) OverloadedMethod(b bool) float64 { - if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceDAbstractIgnoresOverloadedMethod); swig_ok { - return swig_g.OverloadedMethod(b) - } - panic("call to pure virtual method") -} - -func Swig_DirectorDAbstractIgnores_callback_OverloadedMethod(p *_swig_DirectorDAbstractIgnores, b bool) (swig_result float64) { - var swig_r float64 - swig_r = p.OverloadedMethod(b) - return swig_r -} - -type _swig_DirectorInterfaceDAbstractIgnoresQuadruple interface { - Quadruple(int) int -} - -var _wrap__swig_DirectorDAbstractIgnores_upcall_Quadruple unsafe.Pointer - -func _swig_wrap__swig_DirectorDAbstractIgnores_upcall_Quadruple(_swig_ptr SwigcptrDAbstractIgnores, _ int) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) - _cgo_runtime_cgocall(_wrap__swig_DirectorDAbstractIgnores_upcall_Quadruple, _swig_p) - return -} - -func (swig_p *_swig_DirectorDAbstractIgnores) Quadruple(n int) int { - if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceDAbstractIgnoresQuadruple); swig_ok { - return swig_g.Quadruple(n) - } - var swig_r int - swig_r = _swig_wrap__swig_DirectorDAbstractIgnores_upcall_Quadruple(swig_p.SwigcptrDAbstractIgnores, n) - return swig_r -} - -func DirectorDAbstractIgnoresQuadruple(p DAbstractIgnores, arg2 int) int { - var swig_r int - swig_r = _swig_wrap__swig_DirectorDAbstractIgnores_upcall_Quadruple(p.(*_swig_DirectorDAbstractIgnores).SwigcptrDAbstractIgnores, arg2) - return swig_r -} - -func Swig_DirectorDAbstractIgnores_callback_Quadruple(p *_swig_DirectorDAbstractIgnores, arg2 int) (swig_result int) { - var swig_r int - swig_r = p.Quadruple(arg2) - return swig_r -} - -type _swig_DirectorInterfaceDAbstractIgnoresOverloadedProtectedMethod interface { - OverloadedProtectedMethod() float64 -} - -func (swig_p *_swig_DirectorDAbstractIgnores) OverloadedProtectedMethod() float64 { - if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceDAbstractIgnoresOverloadedProtectedMethod); swig_ok { - return swig_g.OverloadedProtectedMethod() - } - panic("call to pure virtual method") -} - -func Swig_DirectorDAbstractIgnores_callback_OverloadedProtectedMethod(p *_swig_DirectorDAbstractIgnores) (swig_result float64) { - var swig_r float64 - swig_r = p.OverloadedProtectedMethod() - return swig_r -} - -type SwigcptrDAbstractIgnores uintptr - -func (p SwigcptrDAbstractIgnores) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrDAbstractIgnores) SwigIsDAbstractIgnores() { -} - -func (p SwigcptrDAbstractIgnores) DirectorInterface() interface{} { - return nil -} - -var _wrap_delete_DAbstractIgnores unsafe.Pointer - -func _swig_wrap_delete_DAbstractIgnores(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_DAbstractIgnores, _swig_p) - return -} - -func DeleteDAbstractIgnores(arg1 DAbstractIgnores) { - _swig_wrap_delete_DAbstractIgnores(arg1.Swigcptr()) -} - -var _wrap_DAbstractIgnores_OverloadedMethod unsafe.Pointer - -func _swig_wrap_DAbstractIgnores_OverloadedMethod(base SwigcptrDAbstractIgnores, _ bool) (_ float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_DAbstractIgnores_OverloadedMethod, _swig_p) - return -} - -func (arg1 SwigcptrDAbstractIgnores) OverloadedMethod(arg2 bool) (_swig_ret float64) { - return _swig_wrap_DAbstractIgnores_OverloadedMethod(arg1, arg2) -} - -var _wrap_DAbstractIgnores_Quadruple unsafe.Pointer - -func _swig_wrap_DAbstractIgnores_Quadruple(base SwigcptrDAbstractIgnores, _ int) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_DAbstractIgnores_Quadruple, _swig_p) - return -} - -func (arg1 SwigcptrDAbstractIgnores) Quadruple(arg2 int) (_swig_ret int) { - return _swig_wrap_DAbstractIgnores_Quadruple(arg1, arg2) -} - -var _wrap_new_DAbstractIgnores unsafe.Pointer - -func _swig_wrap_new_DAbstractIgnores() (base SwigcptrDAbstractIgnores) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_DAbstractIgnores, _swig_p) - return -} - -func NewDAbstractIgnores() (_swig_ret DAbstractIgnores) { - return _swig_wrap_new_DAbstractIgnores() -} - -type DAbstractIgnores interface { - Swigcptr() uintptr - SwigIsDAbstractIgnores() - DirectorInterface() interface{} - OverloadedMethod(arg2 bool) (_swig_ret float64) - Quadruple(arg2 int) (_swig_ret int) -} - -type _swig_DirectorDTemplateAbstractIgnoresInt struct { - SwigcptrDTemplateAbstractIgnoresInt - v interface{} -} - -func (p *_swig_DirectorDTemplateAbstractIgnoresInt) Swigcptr() uintptr { - return p.SwigcptrDTemplateAbstractIgnoresInt.Swigcptr() -} - -func (p *_swig_DirectorDTemplateAbstractIgnoresInt) SwigIsDTemplateAbstractIgnoresInt() { -} - -func (p *_swig_DirectorDTemplateAbstractIgnoresInt) DirectorInterface() interface{} { - return p.v -} - -var _wrap__swig_NewDirectorDTemplateAbstractIgnoresIntDTemplateAbstractIgnoresInt unsafe.Pointer - -func _swig_NewDirectorDTemplateAbstractIgnoresIntDTemplateAbstractIgnoresInt(_swig_director *_swig_DirectorDTemplateAbstractIgnoresInt) (_swig_ret SwigcptrDTemplateAbstractIgnoresInt) { - _swig_p := uintptr(unsafe.Pointer(&_swig_director)) - _cgo_runtime_cgocall(_wrap__swig_NewDirectorDTemplateAbstractIgnoresIntDTemplateAbstractIgnoresInt, _swig_p) - return -} - -func NewDirectorDTemplateAbstractIgnoresInt(v interface{}) DTemplateAbstractIgnoresInt { - p := &_swig_DirectorDTemplateAbstractIgnoresInt{0, v} - p.SwigcptrDTemplateAbstractIgnoresInt = _swig_NewDirectorDTemplateAbstractIgnoresIntDTemplateAbstractIgnoresInt(p) - return p -} - -var _wrap_DeleteDirectorDTemplateAbstractIgnoresInt unsafe.Pointer - -func _swig_wrap_DeleteDirectorDTemplateAbstractIgnoresInt(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_DeleteDirectorDTemplateAbstractIgnoresInt, _swig_p) - return -} - -func DeleteDirectorDTemplateAbstractIgnoresInt(arg1 DTemplateAbstractIgnoresInt) { - _swig_wrap_DeleteDirectorDTemplateAbstractIgnoresInt(arg1.Swigcptr()) -} - -func Swiggo_DeleteDirector_DTemplateAbstractIgnoresInt(p *_swig_DirectorDTemplateAbstractIgnoresInt) { - p.SwigcptrDTemplateAbstractIgnoresInt = 0 -} - -type _swig_DirectorInterfaceDTemplateAbstractIgnoresIntOverloadedMethod interface { - OverloadedMethod(bool) float64 -} - -func (swig_p *_swig_DirectorDTemplateAbstractIgnoresInt) OverloadedMethod(b bool) float64 { - if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceDTemplateAbstractIgnoresIntOverloadedMethod); swig_ok { - return swig_g.OverloadedMethod(b) - } - panic("call to pure virtual method") -} - -func Swig_DirectorDTemplateAbstractIgnoresInt_callback_OverloadedMethod(p *_swig_DirectorDTemplateAbstractIgnoresInt, b bool) (swig_result float64) { - var swig_r float64 - swig_r = p.OverloadedMethod(b) - return swig_r -} - -type _swig_DirectorInterfaceDTemplateAbstractIgnoresIntQuadruple interface { - Quadruple(int) int -} - -var _wrap__swig_DirectorDTemplateAbstractIgnoresInt_upcall_Quadruple unsafe.Pointer - -func _swig_wrap__swig_DirectorDTemplateAbstractIgnoresInt_upcall_Quadruple(_swig_ptr SwigcptrDTemplateAbstractIgnoresInt, _ int) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) - _cgo_runtime_cgocall(_wrap__swig_DirectorDTemplateAbstractIgnoresInt_upcall_Quadruple, _swig_p) - return -} - -func (swig_p *_swig_DirectorDTemplateAbstractIgnoresInt) Quadruple(n int) int { - if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceDTemplateAbstractIgnoresIntQuadruple); swig_ok { - return swig_g.Quadruple(n) - } - var swig_r int - swig_r = _swig_wrap__swig_DirectorDTemplateAbstractIgnoresInt_upcall_Quadruple(swig_p.SwigcptrDTemplateAbstractIgnoresInt, n) - return swig_r -} - -func DirectorDTemplateAbstractIgnoresIntQuadruple(p DTemplateAbstractIgnoresInt, arg2 int) int { - var swig_r int - swig_r = _swig_wrap__swig_DirectorDTemplateAbstractIgnoresInt_upcall_Quadruple(p.(*_swig_DirectorDTemplateAbstractIgnoresInt).SwigcptrDTemplateAbstractIgnoresInt, arg2) - return swig_r -} - -func Swig_DirectorDTemplateAbstractIgnoresInt_callback_Quadruple(p *_swig_DirectorDTemplateAbstractIgnoresInt, arg2 int) (swig_result int) { - var swig_r int - swig_r = p.Quadruple(arg2) - return swig_r -} - -type _swig_DirectorInterfaceDTemplateAbstractIgnoresIntOverloadedProtectedMethod interface { - OverloadedProtectedMethod() float64 -} - -func (swig_p *_swig_DirectorDTemplateAbstractIgnoresInt) OverloadedProtectedMethod() float64 { - if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceDTemplateAbstractIgnoresIntOverloadedProtectedMethod); swig_ok { - return swig_g.OverloadedProtectedMethod() - } - panic("call to pure virtual method") -} - -func Swig_DirectorDTemplateAbstractIgnoresInt_callback_OverloadedProtectedMethod(p *_swig_DirectorDTemplateAbstractIgnoresInt) (swig_result float64) { - var swig_r float64 - swig_r = p.OverloadedProtectedMethod() - return swig_r -} - -type SwigcptrDTemplateAbstractIgnoresInt uintptr - -func (p SwigcptrDTemplateAbstractIgnoresInt) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrDTemplateAbstractIgnoresInt) SwigIsDTemplateAbstractIgnoresInt() { -} - -func (p SwigcptrDTemplateAbstractIgnoresInt) DirectorInterface() interface{} { - return nil -} - -var _wrap_delete_DTemplateAbstractIgnoresInt unsafe.Pointer - -func _swig_wrap_delete_DTemplateAbstractIgnoresInt(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_DTemplateAbstractIgnoresInt, _swig_p) - return -} - -func DeleteDTemplateAbstractIgnoresInt(arg1 DTemplateAbstractIgnoresInt) { - _swig_wrap_delete_DTemplateAbstractIgnoresInt(arg1.Swigcptr()) -} - -var _wrap_DTemplateAbstractIgnoresInt_OverloadedMethod unsafe.Pointer - -func _swig_wrap_DTemplateAbstractIgnoresInt_OverloadedMethod(base SwigcptrDTemplateAbstractIgnoresInt, _ bool) (_ float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_DTemplateAbstractIgnoresInt_OverloadedMethod, _swig_p) - return -} - -func (arg1 SwigcptrDTemplateAbstractIgnoresInt) OverloadedMethod(arg2 bool) (_swig_ret float64) { - return _swig_wrap_DTemplateAbstractIgnoresInt_OverloadedMethod(arg1, arg2) -} - -var _wrap_DTemplateAbstractIgnoresInt_Quadruple unsafe.Pointer - -func _swig_wrap_DTemplateAbstractIgnoresInt_Quadruple(base SwigcptrDTemplateAbstractIgnoresInt, _ int) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_DTemplateAbstractIgnoresInt_Quadruple, _swig_p) - return -} - -func (arg1 SwigcptrDTemplateAbstractIgnoresInt) Quadruple(arg2 int) (_swig_ret int) { - return _swig_wrap_DTemplateAbstractIgnoresInt_Quadruple(arg1, arg2) -} - -var _wrap_new_DTemplateAbstractIgnoresInt unsafe.Pointer - -func _swig_wrap_new_DTemplateAbstractIgnoresInt() (base SwigcptrDTemplateAbstractIgnoresInt) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_DTemplateAbstractIgnoresInt, _swig_p) - return -} - -func NewDTemplateAbstractIgnoresInt() (_swig_ret DTemplateAbstractIgnoresInt) { - return _swig_wrap_new_DTemplateAbstractIgnoresInt() -} - -type DTemplateAbstractIgnoresInt interface { - Swigcptr() uintptr - SwigIsDTemplateAbstractIgnoresInt() - DirectorInterface() interface{} - OverloadedMethod(arg2 bool) (_swig_ret float64) - Quadruple(arg2 int) (_swig_ret int) -} - -type _swig_DirectorDIgnoreConstructor struct { - SwigcptrDIgnoreConstructor - v interface{} -} - -func (p *_swig_DirectorDIgnoreConstructor) Swigcptr() uintptr { - return p.SwigcptrDIgnoreConstructor.Swigcptr() -} - -func (p *_swig_DirectorDIgnoreConstructor) SwigIsDIgnoreConstructor() { -} - -func (p *_swig_DirectorDIgnoreConstructor) DirectorInterface() interface{} { - return p.v -} - -var _wrap__swig_NewDirectorDIgnoreConstructorDIgnoreConstructor unsafe.Pointer - -func _swig_NewDirectorDIgnoreConstructorDIgnoreConstructor(_swig_director *_swig_DirectorDIgnoreConstructor, _ string, _ int) (_swig_ret SwigcptrDIgnoreConstructor) { - _swig_p := uintptr(unsafe.Pointer(&_swig_director)) - _cgo_runtime_cgocall(_wrap__swig_NewDirectorDIgnoreConstructorDIgnoreConstructor, _swig_p) - return -} - -func NewDirectorDIgnoreConstructor(v interface{}, arg1 string, arg2 int) DIgnoreConstructor { - p := &_swig_DirectorDIgnoreConstructor{0, v} - p.SwigcptrDIgnoreConstructor = _swig_NewDirectorDIgnoreConstructorDIgnoreConstructor(p, arg1, arg2) - return p -} - -var _wrap_DeleteDirectorDIgnoreConstructor unsafe.Pointer - -func _swig_wrap_DeleteDirectorDIgnoreConstructor(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_DeleteDirectorDIgnoreConstructor, _swig_p) - return -} - -func DeleteDirectorDIgnoreConstructor(arg1 DIgnoreConstructor) { - _swig_wrap_DeleteDirectorDIgnoreConstructor(arg1.Swigcptr()) -} - -func Swiggo_DeleteDirector_DIgnoreConstructor(p *_swig_DirectorDIgnoreConstructor) { - p.SwigcptrDIgnoreConstructor = 0 -} - -type SwigcptrDIgnoreConstructor uintptr - -func (p SwigcptrDIgnoreConstructor) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrDIgnoreConstructor) SwigIsDIgnoreConstructor() { -} - -func (p SwigcptrDIgnoreConstructor) DirectorInterface() interface{} { - return nil -} - -var _wrap_delete_DIgnoreConstructor unsafe.Pointer - -func _swig_wrap_delete_DIgnoreConstructor(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_DIgnoreConstructor, _swig_p) - return -} - -func DeleteDIgnoreConstructor(arg1 DIgnoreConstructor) { - _swig_wrap_delete_DIgnoreConstructor(arg1.Swigcptr()) -} - -var _wrap_new_DIgnoreConstructor unsafe.Pointer - -func _swig_wrap_new_DIgnoreConstructor(base string, _ int) (_ SwigcptrDIgnoreConstructor) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_DIgnoreConstructor, _swig_p) - return -} - -func NewDIgnoreConstructor(arg1 string, arg2 int) (_swig_ret DIgnoreConstructor) { - return _swig_wrap_new_DIgnoreConstructor(arg1, arg2) -} - -type DIgnoreConstructor interface { - Swigcptr() uintptr - SwigIsDIgnoreConstructor() - DirectorInterface() interface{} -} - -type _swig_DirectorDIgnoreOnlyConstructor struct { - SwigcptrDIgnoreOnlyConstructor - v interface{} -} - -func (p *_swig_DirectorDIgnoreOnlyConstructor) Swigcptr() uintptr { - return p.SwigcptrDIgnoreOnlyConstructor.Swigcptr() -} - -func (p *_swig_DirectorDIgnoreOnlyConstructor) SwigIsDIgnoreOnlyConstructor() { -} - -func (p *_swig_DirectorDIgnoreOnlyConstructor) DirectorInterface() interface{} { - return p.v -} - -var _wrap_DeleteDirectorDIgnoreOnlyConstructor unsafe.Pointer - -func _swig_wrap_DeleteDirectorDIgnoreOnlyConstructor(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_DeleteDirectorDIgnoreOnlyConstructor, _swig_p) - return -} - -func DeleteDirectorDIgnoreOnlyConstructor(arg1 DIgnoreOnlyConstructor) { - _swig_wrap_DeleteDirectorDIgnoreOnlyConstructor(arg1.Swigcptr()) -} - -func Swiggo_DeleteDirector_DIgnoreOnlyConstructor(p *_swig_DirectorDIgnoreOnlyConstructor) { - p.SwigcptrDIgnoreOnlyConstructor = 0 -} - -type SwigcptrDIgnoreOnlyConstructor uintptr - -func (p SwigcptrDIgnoreOnlyConstructor) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrDIgnoreOnlyConstructor) SwigIsDIgnoreOnlyConstructor() { -} - -func (p SwigcptrDIgnoreOnlyConstructor) DirectorInterface() interface{} { - return nil -} - -var _wrap_delete_DIgnoreOnlyConstructor unsafe.Pointer - -func _swig_wrap_delete_DIgnoreOnlyConstructor(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_DIgnoreOnlyConstructor, _swig_p) - return -} - -func DeleteDIgnoreOnlyConstructor(arg1 DIgnoreOnlyConstructor) { - _swig_wrap_delete_DIgnoreOnlyConstructor(arg1.Swigcptr()) -} - -type DIgnoreOnlyConstructor interface { - Swigcptr() uintptr - SwigIsDIgnoreOnlyConstructor() - DirectorInterface() interface{} -} - - -type SwigcptrSwigDirector_DIgnores uintptr -type SwigDirector_DIgnores interface { - Swigcptr() uintptr; -} -func (p SwigcptrSwigDirector_DIgnores) Swigcptr() uintptr { - return uintptr(p) -} - -type SwigcptrSwigDirector_DAbstractIgnores uintptr -type SwigDirector_DAbstractIgnores interface { - Swigcptr() uintptr; -} -func (p SwigcptrSwigDirector_DAbstractIgnores) Swigcptr() uintptr { - return uintptr(p) -} - -type SwigcptrSwigDirector_DTemplateAbstractIgnoresInt uintptr -type SwigDirector_DTemplateAbstractIgnoresInt interface { - Swigcptr() uintptr; -} -func (p SwigcptrSwigDirector_DTemplateAbstractIgnoresInt) Swigcptr() uintptr { - return uintptr(p) -} - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/director_ignore_wrap.h b/Examples/test-suite/go/director_ignore_wrap.h deleted file mode 100644 index e5bbbd802..000000000 --- a/Examples/test-suite/go/director_ignore_wrap.h +++ /dev/null @@ -1,101 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../director_ignore.i - -#ifndef SWIG_director_ignore_WRAP_H_ -#define SWIG_director_ignore_WRAP_H_ - -class SwigDirector_DIgnores : public DIgnores -{ - public: - SwigDirector_DIgnores(void *swig_p); - virtual ~SwigDirector_DIgnores(); - void _swig_upcall_OverloadedMethod(bool b) { - DIgnores::OverloadedMethod(b); - } - virtual void OverloadedMethod(bool b); - int _swig_upcall_Triple(int n) { - return DIgnores::Triple(n); - } - virtual int Triple(int n); - virtual double PublicPureVirtualMethod1(); - virtual void PublicPureVirtualMethod2(); - virtual void TempMethod(); - void _swig_upcall_OverloadedProtectedMethod() { - DIgnores::OverloadedProtectedMethod(); - } - virtual void OverloadedProtectedMethod(); - virtual double ProtectedPureVirtualMethod1(); - virtual void ProtectedPureVirtualMethod2(); - private: - void *go_val; -}; - -class SwigDirector_DAbstractIgnores : public DAbstractIgnores -{ - public: - SwigDirector_DAbstractIgnores(void *swig_p); - virtual ~SwigDirector_DAbstractIgnores(); - virtual double OverloadedMethod(int n, int xoffset, int yoffset); - virtual double OverloadedMethod(int n, int xoffset); - virtual double OverloadedMethod(int n); - virtual double OverloadedMethod(bool b); - int _swig_upcall_Quadruple(int n) { - return DAbstractIgnores::Quadruple(n); - } - virtual int Quadruple(int n); - virtual double OverloadedProtectedMethod(int n, int xoffset, int yoffset); - virtual double OverloadedProtectedMethod(int n, int xoffset); - virtual double OverloadedProtectedMethod(int n); - virtual double OverloadedProtectedMethod(); - private: - void *go_val; -}; - -class SwigDirector_DTemplateAbstractIgnoresInt : public DTemplateAbstractIgnores< int > -{ - public: - SwigDirector_DTemplateAbstractIgnoresInt(void *swig_p); - virtual ~SwigDirector_DTemplateAbstractIgnoresInt(); - virtual double OverloadedMethod(int n, int xoffset, int yoffset); - virtual double OverloadedMethod(int n, int xoffset); - virtual double OverloadedMethod(int n); - virtual double OverloadedMethod(bool b); - int _swig_upcall_Quadruple(int n) { - return DTemplateAbstractIgnores< int >::Quadruple(n); - } - virtual int Quadruple(int n); - virtual double OverloadedProtectedMethod(int n, int xoffset, int yoffset); - virtual double OverloadedProtectedMethod(int n, int xoffset); - virtual double OverloadedProtectedMethod(int n); - virtual double OverloadedProtectedMethod(); - private: - void *go_val; -}; - -class SwigDirector_DIgnoreConstructor : public DIgnoreConstructor -{ - public: - SwigDirector_DIgnoreConstructor(void *swig_p, std::string s, int i); - virtual ~SwigDirector_DIgnoreConstructor(); - private: - void *go_val; -}; - -class SwigDirector_DIgnoreOnlyConstructor : public DIgnoreOnlyConstructor -{ - public: - virtual ~SwigDirector_DIgnoreOnlyConstructor(); - private: - void *go_val; -}; - -#endif diff --git a/Examples/test-suite/go/director_keywords.go b/Examples/test-suite/go/director_keywords.go deleted file mode 100644 index 0b77ce786..000000000 --- a/Examples/test-suite/go/director_keywords.go +++ /dev/null @@ -1,175 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../director_keywords.i - -package director_keywords - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type _swig_DirectorFoo struct { - SwigcptrFoo - v interface{} -} - -func (p *_swig_DirectorFoo) Swigcptr() uintptr { - return p.SwigcptrFoo.Swigcptr() -} - -func (p *_swig_DirectorFoo) SwigIsFoo() { -} - -func (p *_swig_DirectorFoo) DirectorInterface() interface{} { - return p.v -} - -var _wrap__swig_NewDirectorFooFoo unsafe.Pointer - -func _swig_NewDirectorFooFoo(_swig_director *_swig_DirectorFoo) (_swig_ret SwigcptrFoo) { - _swig_p := uintptr(unsafe.Pointer(&_swig_director)) - _cgo_runtime_cgocall(_wrap__swig_NewDirectorFooFoo, _swig_p) - return -} - -func NewDirectorFoo(v interface{}) Foo { - p := &_swig_DirectorFoo{0, v} - p.SwigcptrFoo = _swig_NewDirectorFooFoo(p) - return p -} - -var _wrap_DeleteDirectorFoo unsafe.Pointer - -func _swig_wrap_DeleteDirectorFoo(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_DeleteDirectorFoo, _swig_p) - return -} - -func DeleteDirectorFoo(arg1 Foo) { - _swig_wrap_DeleteDirectorFoo(arg1.Swigcptr()) -} - -func Swiggo_DeleteDirector_Foo(p *_swig_DirectorFoo) { - p.SwigcptrFoo = 0 -} - -type _swig_DirectorInterfaceFooBar interface { - Bar(int) -} - -var _wrap__swig_DirectorFoo_upcall_Bar unsafe.Pointer - -func _swig_wrap__swig_DirectorFoo_upcall_Bar(_swig_ptr SwigcptrFoo, _ int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) - _cgo_runtime_cgocall(_wrap__swig_DirectorFoo_upcall_Bar, _swig_p) - return -} - -func (swig_p *_swig_DirectorFoo) Bar(abstract int) { - if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceFooBar); swig_ok { - swig_g.Bar(abstract) - return - } - _swig_wrap__swig_DirectorFoo_upcall_Bar(swig_p.SwigcptrFoo, abstract) -} - -func DirectorFooBar(p Foo, arg2 int) { - _swig_wrap__swig_DirectorFoo_upcall_Bar(p.(*_swig_DirectorFoo).SwigcptrFoo, arg2) -} - -func Swig_DirectorFoo_callback_bar(p *_swig_DirectorFoo, arg2 int) { - p.Bar(arg2) -} - -type SwigcptrFoo uintptr - -func (p SwigcptrFoo) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrFoo) SwigIsFoo() { -} - -func (p SwigcptrFoo) DirectorInterface() interface{} { - return nil -} - -var _wrap_delete_Foo unsafe.Pointer - -func _swig_wrap_delete_Foo(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Foo, _swig_p) - return -} - -func DeleteFoo(arg1 Foo) { - _swig_wrap_delete_Foo(arg1.Swigcptr()) -} - -var _wrap_Foo_bar unsafe.Pointer - -func _swig_wrap_Foo_bar(base SwigcptrFoo, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_bar, _swig_p) - return -} - -func (arg1 SwigcptrFoo) Bar(arg2 int) { - _swig_wrap_Foo_bar(arg1, arg2) -} - -var _wrap_new_Foo unsafe.Pointer - -func _swig_wrap_new_Foo() (base SwigcptrFoo) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Foo, _swig_p) - return -} - -func NewFoo() (_swig_ret Foo) { - return _swig_wrap_new_Foo() -} - -type Foo interface { - Swigcptr() uintptr - SwigIsFoo() - DirectorInterface() interface{} - Bar(arg2 int) -} - - -type SwigcptrSwigDirector_Foo uintptr -type SwigDirector_Foo interface { - Swigcptr() uintptr; -} -func (p SwigcptrSwigDirector_Foo) Swigcptr() uintptr { - return uintptr(p) -} - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/director_keywords_wrap.h b/Examples/test-suite/go/director_keywords_wrap.h deleted file mode 100644 index 46b9d2a53..000000000 --- a/Examples/test-suite/go/director_keywords_wrap.h +++ /dev/null @@ -1,29 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../director_keywords.i - -#ifndef SWIG_director_keywords_WRAP_H_ -#define SWIG_director_keywords_WRAP_H_ - -class SwigDirector_Foo : public Foo -{ - public: - SwigDirector_Foo(void *swig_p); - virtual ~SwigDirector_Foo(); - void _swig_upcall_bar(int abstract) { - Foo::bar(abstract); - } - virtual void bar(int abstract); - private: - void *go_val; -}; - -#endif diff --git a/Examples/test-suite/go/director_namespace_clash.go b/Examples/test-suite/go/director_namespace_clash.go deleted file mode 100644 index 30bc89d01..000000000 --- a/Examples/test-suite/go/director_namespace_clash.go +++ /dev/null @@ -1,313 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../director_namespace_clash.i - -package director_namespace_clash - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type _swig_DirectorGreatOne struct { - SwigcptrGreatOne - v interface{} -} - -func (p *_swig_DirectorGreatOne) Swigcptr() uintptr { - return p.SwigcptrGreatOne.Swigcptr() -} - -func (p *_swig_DirectorGreatOne) SwigIsGreatOne() { -} - -func (p *_swig_DirectorGreatOne) DirectorInterface() interface{} { - return p.v -} - -var _wrap__swig_NewDirectorGreatOneGreatOne unsafe.Pointer - -func _swig_NewDirectorGreatOneGreatOne(_swig_director *_swig_DirectorGreatOne) (_swig_ret SwigcptrGreatOne) { - _swig_p := uintptr(unsafe.Pointer(&_swig_director)) - _cgo_runtime_cgocall(_wrap__swig_NewDirectorGreatOneGreatOne, _swig_p) - return -} - -func NewDirectorGreatOne(v interface{}) GreatOne { - p := &_swig_DirectorGreatOne{0, v} - p.SwigcptrGreatOne = _swig_NewDirectorGreatOneGreatOne(p) - return p -} - -type _swig_DirectorInterfaceGreatOneSuperb interface { - Superb(int) -} - -var _wrap__swig_DirectorGreatOne_upcall_Superb unsafe.Pointer - -func _swig_wrap__swig_DirectorGreatOne_upcall_Superb(_swig_ptr SwigcptrGreatOne, _ int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) - _cgo_runtime_cgocall(_wrap__swig_DirectorGreatOne_upcall_Superb, _swig_p) - return -} - -func (swig_p *_swig_DirectorGreatOne) Superb(a int) { - if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceGreatOneSuperb); swig_ok { - swig_g.Superb(a) - return - } - _swig_wrap__swig_DirectorGreatOne_upcall_Superb(swig_p.SwigcptrGreatOne, a) -} - -func DirectorGreatOneSuperb(p GreatOne, arg2 int) { - _swig_wrap__swig_DirectorGreatOne_upcall_Superb(p.(*_swig_DirectorGreatOne).SwigcptrGreatOne, arg2) -} - -func Swig_DirectorGreatOne_callback_superb(p *_swig_DirectorGreatOne, arg2 int) { - p.Superb(arg2) -} - -var _wrap_DeleteDirectorGreatOne unsafe.Pointer - -func _swig_wrap_DeleteDirectorGreatOne(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_DeleteDirectorGreatOne, _swig_p) - return -} - -func DeleteDirectorGreatOne(arg1 GreatOne) { - _swig_wrap_DeleteDirectorGreatOne(arg1.Swigcptr()) -} - -func Swiggo_DeleteDirector_GreatOne(p *_swig_DirectorGreatOne) { - p.SwigcptrGreatOne = 0 -} - -type SwigcptrGreatOne uintptr - -func (p SwigcptrGreatOne) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrGreatOne) SwigIsGreatOne() { -} - -func (p SwigcptrGreatOne) DirectorInterface() interface{} { - return nil -} - -var _wrap_GreatOne_superb unsafe.Pointer - -func _swig_wrap_GreatOne_superb(base SwigcptrGreatOne, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_GreatOne_superb, _swig_p) - return -} - -func (arg1 SwigcptrGreatOne) Superb(arg2 int) { - _swig_wrap_GreatOne_superb(arg1, arg2) -} - -var _wrap_delete_GreatOne unsafe.Pointer - -func _swig_wrap_delete_GreatOne(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_GreatOne, _swig_p) - return -} - -func DeleteGreatOne(arg1 GreatOne) { - _swig_wrap_delete_GreatOne(arg1.Swigcptr()) -} - -var _wrap_new_GreatOne unsafe.Pointer - -func _swig_wrap_new_GreatOne() (base SwigcptrGreatOne) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_GreatOne, _swig_p) - return -} - -func NewGreatOne() (_swig_ret GreatOne) { - return _swig_wrap_new_GreatOne() -} - -type GreatOne interface { - Swigcptr() uintptr - SwigIsGreatOne() - DirectorInterface() interface{} - Superb(arg2 int) -} - -type _swig_DirectorGreat struct { - SwigcptrGreat - v interface{} -} - -func (p *_swig_DirectorGreat) Swigcptr() uintptr { - return p.SwigcptrGreat.Swigcptr() -} - -func (p *_swig_DirectorGreat) SwigIsGreat() { -} - -func (p *_swig_DirectorGreat) DirectorInterface() interface{} { - return p.v -} - -var _wrap__swig_NewDirectorGreatGreat unsafe.Pointer - -func _swig_NewDirectorGreatGreat(_swig_director *_swig_DirectorGreat) (_swig_ret SwigcptrGreat) { - _swig_p := uintptr(unsafe.Pointer(&_swig_director)) - _cgo_runtime_cgocall(_wrap__swig_NewDirectorGreatGreat, _swig_p) - return -} - -func NewDirectorGreat(v interface{}) Great { - p := &_swig_DirectorGreat{0, v} - p.SwigcptrGreat = _swig_NewDirectorGreatGreat(p) - return p -} - -type _swig_DirectorInterfaceGreatExcellent interface { - Excellent() -} - -var _wrap__swig_DirectorGreat_upcall_Excellent unsafe.Pointer - -func _swig_wrap__swig_DirectorGreat_upcall_Excellent(_swig_ptr SwigcptrGreat) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) - _cgo_runtime_cgocall(_wrap__swig_DirectorGreat_upcall_Excellent, _swig_p) - return -} - -func (swig_p *_swig_DirectorGreat) Excellent() { - if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceGreatExcellent); swig_ok { - swig_g.Excellent() - return - } - _swig_wrap__swig_DirectorGreat_upcall_Excellent(swig_p.SwigcptrGreat) -} - -func DirectorGreatExcellent(p Great) { - _swig_wrap__swig_DirectorGreat_upcall_Excellent(p.(*_swig_DirectorGreat).SwigcptrGreat) -} - -func Swig_DirectorGreat_callback_excellent(p *_swig_DirectorGreat) { - p.Excellent() -} - -var _wrap_DeleteDirectorGreat unsafe.Pointer - -func _swig_wrap_DeleteDirectorGreat(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_DeleteDirectorGreat, _swig_p) - return -} - -func DeleteDirectorGreat(arg1 Great) { - _swig_wrap_DeleteDirectorGreat(arg1.Swigcptr()) -} - -func Swiggo_DeleteDirector_Great(p *_swig_DirectorGreat) { - p.SwigcptrGreat = 0 -} - -type SwigcptrGreat uintptr - -func (p SwigcptrGreat) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrGreat) SwigIsGreat() { -} - -func (p SwigcptrGreat) DirectorInterface() interface{} { - return nil -} - -var _wrap_Great_excellent unsafe.Pointer - -func _swig_wrap_Great_excellent(base SwigcptrGreat) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Great_excellent, _swig_p) - return -} - -func (arg1 SwigcptrGreat) Excellent() { - _swig_wrap_Great_excellent(arg1) -} - -var _wrap_delete_Great unsafe.Pointer - -func _swig_wrap_delete_Great(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Great, _swig_p) - return -} - -func DeleteGreat(arg1 Great) { - _swig_wrap_delete_Great(arg1.Swigcptr()) -} - -var _wrap_new_Great unsafe.Pointer - -func _swig_wrap_new_Great() (base SwigcptrGreat) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Great, _swig_p) - return -} - -func NewGreat() (_swig_ret Great) { - return _swig_wrap_new_Great() -} - -type Great interface { - Swigcptr() uintptr - SwigIsGreat() - DirectorInterface() interface{} - Excellent() -} - - -type SwigcptrSwigDirector_GreatOne uintptr -type SwigDirector_GreatOne interface { - Swigcptr() uintptr; -} -func (p SwigcptrSwigDirector_GreatOne) Swigcptr() uintptr { - return uintptr(p) -} - -type SwigcptrSwigDirector_Great uintptr -type SwigDirector_Great interface { - Swigcptr() uintptr; -} -func (p SwigcptrSwigDirector_Great) Swigcptr() uintptr { - return uintptr(p) -} - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/director_namespace_clash_wrap.h b/Examples/test-suite/go/director_namespace_clash_wrap.h deleted file mode 100644 index e3de6ff74..000000000 --- a/Examples/test-suite/go/director_namespace_clash_wrap.h +++ /dev/null @@ -1,42 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../director_namespace_clash.i - -#ifndef SWIG_director_namespace_clash_WRAP_H_ -#define SWIG_director_namespace_clash_WRAP_H_ - -class SwigDirector_GreatOne : public One::Great -{ - public: - SwigDirector_GreatOne(void *swig_p); - void _swig_upcall_superb(int a) { - One::Great::superb(a); - } - virtual void superb(int a); - virtual ~SwigDirector_GreatOne(); - private: - void *go_val; -}; - -class SwigDirector_Great : public Two::Great -{ - public: - SwigDirector_Great(void *swig_p); - void _swig_upcall_excellent() { - Two::Great::excellent(); - } - virtual void excellent(); - virtual ~SwigDirector_Great(); - private: - void *go_val; -}; - -#endif diff --git a/Examples/test-suite/go/director_nested.go b/Examples/test-suite/go/director_nested.go deleted file mode 100644 index 3021aa542..000000000 --- a/Examples/test-suite/go/director_nested.go +++ /dev/null @@ -1,662 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../director_nested.i - -package director_nested - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type _swig_DirectorFoo_int struct { - SwigcptrFoo_int - v interface{} -} - -func (p *_swig_DirectorFoo_int) Swigcptr() uintptr { - return p.SwigcptrFoo_int.Swigcptr() -} - -func (p *_swig_DirectorFoo_int) SwigIsFoo_int() { -} - -func (p *_swig_DirectorFoo_int) DirectorInterface() interface{} { - return p.v -} - -var _wrap__swig_NewDirectorFoo_intFoo_int unsafe.Pointer - -func _swig_NewDirectorFoo_intFoo_int(_swig_director *_swig_DirectorFoo_int) (_swig_ret SwigcptrFoo_int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_director)) - _cgo_runtime_cgocall(_wrap__swig_NewDirectorFoo_intFoo_int, _swig_p) - return -} - -func NewDirectorFoo_int(v interface{}) Foo_int { - p := &_swig_DirectorFoo_int{0, v} - p.SwigcptrFoo_int = _swig_NewDirectorFoo_intFoo_int(p) - return p -} - -var _wrap_DeleteDirectorFoo_int unsafe.Pointer - -func _swig_wrap_DeleteDirectorFoo_int(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_DeleteDirectorFoo_int, _swig_p) - return -} - -func DeleteDirectorFoo_int(arg1 Foo_int) { - _swig_wrap_DeleteDirectorFoo_int(arg1.Swigcptr()) -} - -func Swiggo_DeleteDirector_Foo_int(p *_swig_DirectorFoo_int) { - p.SwigcptrFoo_int = 0 -} - -type _swig_DirectorInterfaceFoo_intDo_advance interface { - Do_advance() string -} - -func (swig_p *_swig_DirectorFoo_int) Do_advance() string { - if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceFoo_intDo_advance); swig_ok { - return swig_g.Do_advance() - } - panic("call to pure virtual method") -} - -func Swig_DirectorFoo_int_callback_do_advance(p *_swig_DirectorFoo_int) (swig_result string) { - var swig_r string - swig_r = p.Do_advance() - return swig_r -} - -type SwigcptrFoo_int uintptr - -func (p SwigcptrFoo_int) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrFoo_int) SwigIsFoo_int() { -} - -func (p SwigcptrFoo_int) DirectorInterface() interface{} { - return nil -} - -var _wrap_delete_Foo_int unsafe.Pointer - -func _swig_wrap_delete_Foo_int(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Foo_int, _swig_p) - return -} - -func DeleteFoo_int(arg1 Foo_int) { - _swig_wrap_delete_Foo_int(arg1.Swigcptr()) -} - -var _wrap_Foo_int_advance unsafe.Pointer - -func _swig_wrap_Foo_int_advance(base SwigcptrFoo_int) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_int_advance, _swig_p) - return -} - -func (arg1 SwigcptrFoo_int) Advance() (_swig_ret string) { - return _swig_wrap_Foo_int_advance(arg1) -} - -var _wrap_new_Foo_int unsafe.Pointer - -func _swig_wrap_new_Foo_int() (base SwigcptrFoo_int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Foo_int, _swig_p) - return -} - -func NewFoo_int() (_swig_ret Foo_int) { - return _swig_wrap_new_Foo_int() -} - -type Foo_int interface { - Swigcptr() uintptr - SwigIsFoo_int() - DirectorInterface() interface{} - Advance() (_swig_ret string) -} - -type _swig_DirectorBar struct { - SwigcptrBar - v interface{} -} - -func (p *_swig_DirectorBar) Swigcptr() uintptr { - return p.SwigcptrBar.Swigcptr() -} - -func (p *_swig_DirectorBar) SwigIsBar() { -} - -func (p *_swig_DirectorBar) DirectorInterface() interface{} { - return p.v -} - -var _wrap__swig_NewDirectorBarBar unsafe.Pointer - -func _swig_NewDirectorBarBar(_swig_director *_swig_DirectorBar) (_swig_ret SwigcptrBar) { - _swig_p := uintptr(unsafe.Pointer(&_swig_director)) - _cgo_runtime_cgocall(_wrap__swig_NewDirectorBarBar, _swig_p) - return -} - -func NewDirectorBar(v interface{}) Bar { - p := &_swig_DirectorBar{0, v} - p.SwigcptrBar = _swig_NewDirectorBarBar(p) - return p -} - -var _wrap_DeleteDirectorBar unsafe.Pointer - -func _swig_wrap_DeleteDirectorBar(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_DeleteDirectorBar, _swig_p) - return -} - -func DeleteDirectorBar(arg1 Bar) { - _swig_wrap_DeleteDirectorBar(arg1.Swigcptr()) -} - -func Swiggo_DeleteDirector_Bar(p *_swig_DirectorBar) { - p.SwigcptrBar = 0 -} - -type _swig_DirectorInterfaceBarDo_advance interface { - Do_advance() string -} - -var _wrap__swig_DirectorBar_upcall_Do_advance unsafe.Pointer - -func _swig_wrap__swig_DirectorBar_upcall_Do_advance(_swig_ptr SwigcptrBar) (_swig_ret string) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) - _cgo_runtime_cgocall(_wrap__swig_DirectorBar_upcall_Do_advance, _swig_p) - return -} - -func (swig_p *_swig_DirectorBar) Do_advance() string { - if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceBarDo_advance); swig_ok { - return swig_g.Do_advance() - } - var swig_r string - swig_r = _swig_wrap__swig_DirectorBar_upcall_Do_advance(swig_p.SwigcptrBar) - return swig_r -} - -func DirectorBarDo_advance(p Bar) string { - var swig_r string - swig_r = _swig_wrap__swig_DirectorBar_upcall_Do_advance(p.(*_swig_DirectorBar).SwigcptrBar) - return swig_r -} - -func Swig_DirectorBar_callback_do_advance(p *_swig_DirectorBar) (swig_result string) { - var swig_r string - swig_r = p.Do_advance() - return swig_r -} - -type _swig_DirectorInterfaceBarDo_step interface { - Do_step() string -} - -var _wrap__swig_DirectorBar_upcall_Do_step unsafe.Pointer - -func _swig_wrap__swig_DirectorBar_upcall_Do_step(_swig_ptr SwigcptrBar) (_swig_ret string) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) - _cgo_runtime_cgocall(_wrap__swig_DirectorBar_upcall_Do_step, _swig_p) - return -} - -func (swig_p *_swig_DirectorBar) Do_step() string { - if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceBarDo_step); swig_ok { - return swig_g.Do_step() - } - var swig_r string - swig_r = _swig_wrap__swig_DirectorBar_upcall_Do_step(swig_p.SwigcptrBar) - return swig_r -} - -func DirectorBarDo_step(p Bar) string { - var swig_r string - swig_r = _swig_wrap__swig_DirectorBar_upcall_Do_step(p.(*_swig_DirectorBar).SwigcptrBar) - return swig_r -} - -func Swig_DirectorBar_callback_do_step(p *_swig_DirectorBar) (swig_result string) { - var swig_r string - swig_r = p.Do_step() - return swig_r -} - -type SwigcptrBar uintptr - -func (p SwigcptrBar) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrBar) SwigIsBar() { -} - -func (p SwigcptrBar) DirectorInterface() interface{} { - return nil -} - -var _wrap_Bar_step unsafe.Pointer - -func _swig_wrap_Bar_step(base SwigcptrBar) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Bar_step, _swig_p) - return -} - -func (arg1 SwigcptrBar) Step() (_swig_ret string) { - return _swig_wrap_Bar_step(arg1) -} - -var _wrap_new_Bar unsafe.Pointer - -func _swig_wrap_new_Bar() (base SwigcptrBar) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Bar, _swig_p) - return -} - -func NewBar() (_swig_ret Bar) { - return _swig_wrap_new_Bar() -} - -var _wrap_delete_Bar unsafe.Pointer - -func _swig_wrap_delete_Bar(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Bar, _swig_p) - return -} - -func DeleteBar(arg1 Bar) { - _swig_wrap_delete_Bar(arg1.Swigcptr()) -} - -var _wrap_Bar_advance unsafe.Pointer - -func _swig_wrap_Bar_advance(base SwigcptrBar) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Bar_advance, _swig_p) - return -} - -func (_swig_base SwigcptrBar) Advance() (_swig_ret string) { - return _swig_wrap_Bar_advance(_swig_base) -} - -func (p SwigcptrBar) SwigIsFoo_int() { -} - -func (p SwigcptrBar) SwigGetFoo_int() Foo_int { - return SwigcptrFoo_int(p.Swigcptr()) -} - -type Bar interface { - Swigcptr() uintptr - SwigIsBar() - DirectorInterface() interface{} - Step() (_swig_ret string) - Advance() (_swig_ret string) - SwigIsFoo_int() - SwigGetFoo_int() Foo_int -} - -type _swig_DirectorFooBar_int struct { - SwigcptrFooBar_int - v interface{} -} - -func (p *_swig_DirectorFooBar_int) Swigcptr() uintptr { - return p.SwigcptrFooBar_int.Swigcptr() -} - -func (p *_swig_DirectorFooBar_int) SwigIsFooBar_int() { -} - -func (p *_swig_DirectorFooBar_int) DirectorInterface() interface{} { - return p.v -} - -var _wrap__swig_NewDirectorFooBar_intFooBar_int unsafe.Pointer - -func _swig_NewDirectorFooBar_intFooBar_int(_swig_director *_swig_DirectorFooBar_int) (_swig_ret SwigcptrFooBar_int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_director)) - _cgo_runtime_cgocall(_wrap__swig_NewDirectorFooBar_intFooBar_int, _swig_p) - return -} - -func NewDirectorFooBar_int(v interface{}) FooBar_int { - p := &_swig_DirectorFooBar_int{0, v} - p.SwigcptrFooBar_int = _swig_NewDirectorFooBar_intFooBar_int(p) - return p -} - -var _wrap_DeleteDirectorFooBar_int unsafe.Pointer - -func _swig_wrap_DeleteDirectorFooBar_int(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_DeleteDirectorFooBar_int, _swig_p) - return -} - -func DeleteDirectorFooBar_int(arg1 FooBar_int) { - _swig_wrap_DeleteDirectorFooBar_int(arg1.Swigcptr()) -} - -func Swiggo_DeleteDirector_FooBar_int(p *_swig_DirectorFooBar_int) { - p.SwigcptrFooBar_int = 0 -} - -type _swig_DirectorInterfaceFooBar_intDo_advance interface { - Do_advance() string -} - -var _wrap__swig_DirectorFooBar_int_upcall_Do_advance unsafe.Pointer - -func _swig_wrap__swig_DirectorFooBar_int_upcall_Do_advance(_swig_ptr SwigcptrFooBar_int) (_swig_ret string) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) - _cgo_runtime_cgocall(_wrap__swig_DirectorFooBar_int_upcall_Do_advance, _swig_p) - return -} - -func (swig_p *_swig_DirectorFooBar_int) Do_advance() string { - if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceFooBar_intDo_advance); swig_ok { - return swig_g.Do_advance() - } - var swig_r string - swig_r = _swig_wrap__swig_DirectorFooBar_int_upcall_Do_advance(swig_p.SwigcptrFooBar_int) - return swig_r -} - -func DirectorFooBar_intDo_advance(p FooBar_int) string { - var swig_r string - swig_r = _swig_wrap__swig_DirectorFooBar_int_upcall_Do_advance(p.(*_swig_DirectorFooBar_int).SwigcptrFooBar_int) - return swig_r -} - -func Swig_DirectorFooBar_int_callback_do_advance(p *_swig_DirectorFooBar_int) (swig_result string) { - var swig_r string - swig_r = p.Do_advance() - return swig_r -} - -type _swig_DirectorInterfaceFooBar_intDo_step interface { - Do_step() string -} - -var _wrap__swig_DirectorFooBar_int_upcall_Do_step unsafe.Pointer - -func _swig_wrap__swig_DirectorFooBar_int_upcall_Do_step(_swig_ptr SwigcptrFooBar_int) (_swig_ret string) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) - _cgo_runtime_cgocall(_wrap__swig_DirectorFooBar_int_upcall_Do_step, _swig_p) - return -} - -func (swig_p *_swig_DirectorFooBar_int) Do_step() string { - if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceFooBar_intDo_step); swig_ok { - return swig_g.Do_step() - } - var swig_r string - swig_r = _swig_wrap__swig_DirectorFooBar_int_upcall_Do_step(swig_p.SwigcptrFooBar_int) - return swig_r -} - -func DirectorFooBar_intDo_step(p FooBar_int) string { - var swig_r string - swig_r = _swig_wrap__swig_DirectorFooBar_int_upcall_Do_step(p.(*_swig_DirectorFooBar_int).SwigcptrFooBar_int) - return swig_r -} - -func Swig_DirectorFooBar_int_callback_do_step(p *_swig_DirectorFooBar_int) (swig_result string) { - var swig_r string - swig_r = p.Do_step() - return swig_r -} - -type _swig_DirectorInterfaceFooBar_intGet_value interface { - Get_value() int -} - -func (swig_p *_swig_DirectorFooBar_int) Get_value() int { - if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceFooBar_intGet_value); swig_ok { - return swig_g.Get_value() - } - panic("call to pure virtual method") -} - -func Swig_DirectorFooBar_int_callback_get_value(p *_swig_DirectorFooBar_int) (swig_result int) { - var swig_r int - swig_r = p.Get_value() - return swig_r -} - -type _swig_DirectorInterfaceFooBar_intGet_name interface { - Get_name() string -} - -var _wrap__swig_DirectorFooBar_int_upcall_Get_name unsafe.Pointer - -func _swig_wrap__swig_DirectorFooBar_int_upcall_Get_name(_swig_ptr SwigcptrFooBar_int) (_swig_ret string) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) - _cgo_runtime_cgocall(_wrap__swig_DirectorFooBar_int_upcall_Get_name, _swig_p) - return -} - -func (swig_p *_swig_DirectorFooBar_int) Get_name() string { - if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceFooBar_intGet_name); swig_ok { - return swig_g.Get_name() - } - var swig_r string - swig_r = _swig_wrap__swig_DirectorFooBar_int_upcall_Get_name(swig_p.SwigcptrFooBar_int) - return swig_r -} - -func DirectorFooBar_intGet_name(p FooBar_int) string { - var swig_r string - swig_r = _swig_wrap__swig_DirectorFooBar_int_upcall_Get_name(p.(*_swig_DirectorFooBar_int).SwigcptrFooBar_int) - return swig_r -} - -func Swig_DirectorFooBar_int_callback_get_name(p *_swig_DirectorFooBar_int) (swig_result string) { - var swig_r string - swig_r = p.Get_name() - return swig_r -} - -type SwigcptrFooBar_int uintptr - -func (p SwigcptrFooBar_int) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrFooBar_int) SwigIsFooBar_int() { -} - -func (p SwigcptrFooBar_int) DirectorInterface() interface{} { - return nil -} - -var _wrap_FooBar_int_get_value unsafe.Pointer - -func _swig_wrap_FooBar_int_get_value(base SwigcptrFooBar_int) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_FooBar_int_get_value, _swig_p) - return -} - -func (arg1 SwigcptrFooBar_int) Get_value() (_swig_ret int) { - return _swig_wrap_FooBar_int_get_value(arg1) -} - -var _wrap_FooBar_int_get_name unsafe.Pointer - -func _swig_wrap_FooBar_int_get_name(base SwigcptrFooBar_int) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_FooBar_int_get_name, _swig_p) - return -} - -func (arg1 SwigcptrFooBar_int) Get_name() (_swig_ret string) { - return _swig_wrap_FooBar_int_get_name(arg1) -} - -var _wrap_FooBar_int_name unsafe.Pointer - -func _swig_wrap_FooBar_int_name(base SwigcptrFooBar_int) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_FooBar_int_name, _swig_p) - return -} - -func (arg1 SwigcptrFooBar_int) Name() (_swig_ret string) { - return _swig_wrap_FooBar_int_name(arg1) -} - -var _wrap_FooBar_int_get_self unsafe.Pointer - -func _swig_wrap_FooBar_int_get_self(base uintptr) (_ SwigcptrFooBar_int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_FooBar_int_get_self, _swig_p) - return -} - -func FooBar_intGet_self(arg1 FooBar_int) (_swig_ret FooBar_int) { - return _swig_wrap_FooBar_int_get_self(arg1.Swigcptr()) -} - -var _wrap_new_FooBar_int unsafe.Pointer - -func _swig_wrap_new_FooBar_int() (base SwigcptrFooBar_int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_FooBar_int, _swig_p) - return -} - -func NewFooBar_int() (_swig_ret FooBar_int) { - return _swig_wrap_new_FooBar_int() -} - -var _wrap_delete_FooBar_int unsafe.Pointer - -func _swig_wrap_delete_FooBar_int(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_FooBar_int, _swig_p) - return -} - -func DeleteFooBar_int(arg1 FooBar_int) { - _swig_wrap_delete_FooBar_int(arg1.Swigcptr()) -} - -var _wrap_FooBar_int_step unsafe.Pointer - -func _swig_wrap_FooBar_int_step(base SwigcptrFooBar_int) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_FooBar_int_step, _swig_p) - return -} - -func (_swig_base SwigcptrFooBar_int) Step() (_swig_ret string) { - return _swig_wrap_FooBar_int_step(_swig_base) -} - -var _wrap_FooBar_int_advance unsafe.Pointer - -func _swig_wrap_FooBar_int_advance(base SwigcptrFooBar_int) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_FooBar_int_advance, _swig_p) - return -} - -func (_swig_base SwigcptrFooBar_int) Advance() (_swig_ret string) { - return _swig_wrap_FooBar_int_advance(_swig_base) -} - -func (p SwigcptrFooBar_int) SwigIsBar() { -} - -func (p SwigcptrFooBar_int) SwigGetBar() Bar { - return SwigcptrBar(p.Swigcptr()) -} - -func (p SwigcptrFooBar_int) SwigIsFoo_int() { -} - -func (p SwigcptrFooBar_int) SwigGetFoo_int() Foo_int { - return SwigcptrFoo_int(p.Swigcptr()) -} - -type FooBar_int interface { - Swigcptr() uintptr - SwigIsFooBar_int() - DirectorInterface() interface{} - Get_value() (_swig_ret int) - Get_name() (_swig_ret string) - Name() (_swig_ret string) - Step() (_swig_ret string) - Advance() (_swig_ret string) - SwigIsBar() - SwigGetBar() Bar - SwigIsFoo_int() - SwigGetFoo_int() Foo_int -} - - -type SwigcptrSwigDirector_FooBar_int uintptr -type SwigDirector_FooBar_int interface { - Swigcptr() uintptr; -} -func (p SwigcptrSwigDirector_FooBar_int) Swigcptr() uintptr { - return uintptr(p) -} - -type SwigcptrSwigDirector_Bar uintptr -type SwigDirector_Bar interface { - Swigcptr() uintptr; -} -func (p SwigcptrSwigDirector_Bar) Swigcptr() uintptr { - return uintptr(p) -} - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/director_nested_runme b/Examples/test-suite/go/director_nested_runme deleted file mode 100755 index 1aabef3a3..000000000 Binary files a/Examples/test-suite/go/director_nested_runme and /dev/null differ diff --git a/Examples/test-suite/go/director_nested_wrap.h b/Examples/test-suite/go/director_nested_wrap.h deleted file mode 100644 index 25e81d3a2..000000000 --- a/Examples/test-suite/go/director_nested_wrap.h +++ /dev/null @@ -1,65 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../director_nested.i - -#ifndef SWIG_director_nested_WRAP_H_ -#define SWIG_director_nested_WRAP_H_ - -class SwigDirector_Foo_int : public Foo< int > -{ - public: - SwigDirector_Foo_int(void *swig_p); - virtual ~SwigDirector_Foo_int(); - virtual std::string do_advance(); - private: - void *go_val; -}; - -class SwigDirector_Bar : public Bar -{ - public: - SwigDirector_Bar(void *swig_p); - virtual ~SwigDirector_Bar(); - std::string _swig_upcall_do_advance() { - return Bar::do_advance(); - } - virtual std::string do_advance(); - std::string _swig_upcall_do_step() const { - return Bar::do_step(); - } - virtual std::string do_step() const; - private: - void *go_val; -}; - -class SwigDirector_FooBar_int : public FooBar< int > -{ - public: - SwigDirector_FooBar_int(void *swig_p); - virtual ~SwigDirector_FooBar_int(); - std::string _swig_upcall_do_advance() { - return Bar::do_advance(); - } - virtual std::string do_advance(); - std::string _swig_upcall_do_step() const { - return Bar::do_step(); - } - virtual std::string do_step() const; - virtual int get_value() const; - char const *_swig_upcall_get_name() { - return FooBar< int >::get_name(); - } - virtual char const *get_name(); - private: - void *go_val; -}; - -#endif diff --git a/Examples/test-suite/go/director_nspace.go b/Examples/test-suite/go/director_nspace.go deleted file mode 100644 index cdb5b2d6e..000000000 --- a/Examples/test-suite/go/director_nspace.go +++ /dev/null @@ -1,450 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../director_nspace.i - -package director_nspace - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrFooBar uintptr - -func (p SwigcptrFooBar) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrFooBar) SwigIsFooBar() { -} - -var _wrap_new_FooBar__SWIG_0 unsafe.Pointer - -func _swig_wrap_new_FooBar__SWIG_0() (base SwigcptrFooBar) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_FooBar__SWIG_0, _swig_p) - return -} - -func NewFooBar__SWIG_0() (_swig_ret FooBar) { - return _swig_wrap_new_FooBar__SWIG_0() -} - -var _wrap_new_FooBar__SWIG_1 unsafe.Pointer - -func _swig_wrap_new_FooBar__SWIG_1(base uintptr) (_ SwigcptrFooBar) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_FooBar__SWIG_1, _swig_p) - return -} - -func NewFooBar__SWIG_1(arg1 FooBar) (_swig_ret FooBar) { - return _swig_wrap_new_FooBar__SWIG_1(arg1.Swigcptr()) -} - -func NewFooBar(a ...interface{}) FooBar { - argc := len(a) - if argc == 0 { - return NewFooBar__SWIG_0() - } - if argc == 1 { - return NewFooBar__SWIG_1(a[0].(FooBar)) - } - panic("No match for overloaded function call") -} - -var _wrap_delete_FooBar unsafe.Pointer - -func _swig_wrap_delete_FooBar(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_FooBar, _swig_p) - return -} - -func DeleteFooBar(arg1 FooBar) { - _swig_wrap_delete_FooBar(arg1.Swigcptr()) -} - -var _wrap_FooBar_FooBarDo unsafe.Pointer - -func _swig_wrap_FooBar_FooBarDo(base SwigcptrFooBar) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_FooBar_FooBarDo, _swig_p) - return -} - -func (arg1 SwigcptrFooBar) FooBarDo() (_swig_ret string) { - return _swig_wrap_FooBar_FooBarDo(arg1) -} - -type FooBar interface { - Swigcptr() uintptr - SwigIsFooBar() - FooBarDo() (_swig_ret string) -} - -type _swig_DirectorFoo struct { - SwigcptrFoo - v interface{} -} - -func (p *_swig_DirectorFoo) Swigcptr() uintptr { - return p.SwigcptrFoo.Swigcptr() -} - -func (p *_swig_DirectorFoo) SwigIsFoo() { -} - -func (p *_swig_DirectorFoo) DirectorInterface() interface{} { - return p.v -} - -var _wrap__swig_NewDirectorFooFoo unsafe.Pointer - -func _swig_NewDirectorFooFoo(_swig_director *_swig_DirectorFoo) (_swig_ret SwigcptrFoo) { - _swig_p := uintptr(unsafe.Pointer(&_swig_director)) - _cgo_runtime_cgocall(_wrap__swig_NewDirectorFooFoo, _swig_p) - return -} - -func NewDirectorFoo(v interface{}) Foo { - p := &_swig_DirectorFoo{0, v} - p.SwigcptrFoo = _swig_NewDirectorFooFoo(p) - return p -} - -var _wrap_DeleteDirectorFoo unsafe.Pointer - -func _swig_wrap_DeleteDirectorFoo(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_DeleteDirectorFoo, _swig_p) - return -} - -func DeleteDirectorFoo(arg1 Foo) { - _swig_wrap_DeleteDirectorFoo(arg1.Swigcptr()) -} - -func Swiggo_DeleteDirector_Foo(p *_swig_DirectorFoo) { - p.SwigcptrFoo = 0 -} - -type _swig_DirectorInterfaceFooPing interface { - Ping() string -} - -var _wrap__swig_DirectorFoo_upcall_Ping unsafe.Pointer - -func _swig_wrap__swig_DirectorFoo_upcall_Ping(_swig_ptr SwigcptrFoo) (_swig_ret string) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) - _cgo_runtime_cgocall(_wrap__swig_DirectorFoo_upcall_Ping, _swig_p) - return -} - -func (swig_p *_swig_DirectorFoo) Ping() string { - if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceFooPing); swig_ok { - return swig_g.Ping() - } - var swig_r string - swig_r = _swig_wrap__swig_DirectorFoo_upcall_Ping(swig_p.SwigcptrFoo) - return swig_r -} - -func DirectorFooPing(p Foo) string { - var swig_r string - swig_r = _swig_wrap__swig_DirectorFoo_upcall_Ping(p.(*_swig_DirectorFoo).SwigcptrFoo) - return swig_r -} - -func Swig_DirectorFoo_callback_ping(p *_swig_DirectorFoo) (swig_result string) { - var swig_r string - swig_r = p.Ping() - return swig_r -} - -type _swig_DirectorInterfaceFooPong interface { - Pong() string -} - -var _wrap__swig_DirectorFoo_upcall_Pong unsafe.Pointer - -func _swig_wrap__swig_DirectorFoo_upcall_Pong(_swig_ptr SwigcptrFoo) (_swig_ret string) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) - _cgo_runtime_cgocall(_wrap__swig_DirectorFoo_upcall_Pong, _swig_p) - return -} - -func (swig_p *_swig_DirectorFoo) Pong() string { - if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceFooPong); swig_ok { - return swig_g.Pong() - } - var swig_r string - swig_r = _swig_wrap__swig_DirectorFoo_upcall_Pong(swig_p.SwigcptrFoo) - return swig_r -} - -func DirectorFooPong(p Foo) string { - var swig_r string - swig_r = _swig_wrap__swig_DirectorFoo_upcall_Pong(p.(*_swig_DirectorFoo).SwigcptrFoo) - return swig_r -} - -func Swig_DirectorFoo_callback_pong(p *_swig_DirectorFoo) (swig_result string) { - var swig_r string - swig_r = p.Pong() - return swig_r -} - -type _swig_DirectorInterfaceFooFooBar interface { - FooBar(FooBar) string -} - -var _wrap__swig_DirectorFoo_upcall_FooBar unsafe.Pointer - -func _swig_wrap__swig_DirectorFoo_upcall_FooBar(_swig_ptr SwigcptrFoo, _ uintptr) (_swig_ret string) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) - _cgo_runtime_cgocall(_wrap__swig_DirectorFoo_upcall_FooBar, _swig_p) - return -} - -func (swig_p *_swig_DirectorFoo) FooBar(fb FooBar) string { - if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceFooFooBar); swig_ok { - return swig_g.FooBar(fb) - } - var swig_r string - swig_r = _swig_wrap__swig_DirectorFoo_upcall_FooBar(swig_p.SwigcptrFoo, fb.Swigcptr()) - return swig_r -} - -func DirectorFooFooBar(p Foo, arg2 FooBar) string { - var swig_r string - swig_r = _swig_wrap__swig_DirectorFoo_upcall_FooBar(p.(*_swig_DirectorFoo).SwigcptrFoo, arg2.Swigcptr()) - return swig_r -} - -func Swig_DirectorFoo_callback_fooBar(p *_swig_DirectorFoo, arg2 uintptr) (swig_result string) { - var swig_r string - swig_r = p.FooBar(SwigcptrFooBar(arg2)) - return swig_r -} - -type _swig_DirectorInterfaceFooMakeFoo interface { - MakeFoo() Foo -} - -var _wrap__swig_DirectorFoo_upcall_MakeFoo unsafe.Pointer - -func _swig_wrap__swig_DirectorFoo_upcall_MakeFoo(_swig_ptr SwigcptrFoo) (_swig_ret SwigcptrFoo) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) - _cgo_runtime_cgocall(_wrap__swig_DirectorFoo_upcall_MakeFoo, _swig_p) - return -} - -func (swig_p *_swig_DirectorFoo) MakeFoo() Foo { - if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceFooMakeFoo); swig_ok { - return swig_g.MakeFoo() - } - var swig_r Foo - swig_r = _swig_wrap__swig_DirectorFoo_upcall_MakeFoo(swig_p.SwigcptrFoo) - return swig_r -} - -func DirectorFooMakeFoo(p Foo) Foo { - var swig_r Foo - swig_r = _swig_wrap__swig_DirectorFoo_upcall_MakeFoo(p.(*_swig_DirectorFoo).SwigcptrFoo) - return swig_r -} - -func Swig_DirectorFoo_callback_makeFoo(p *_swig_DirectorFoo) (swig_result SwigcptrFoo) { - var swig_r SwigcptrFoo - swig_r = SwigcptrFoo(p.MakeFoo().Swigcptr()) - return swig_r -} - -type _swig_DirectorInterfaceFooMakeFooBar interface { - MakeFooBar() FooBar -} - -var _wrap__swig_DirectorFoo_upcall_MakeFooBar unsafe.Pointer - -func _swig_wrap__swig_DirectorFoo_upcall_MakeFooBar(_swig_ptr SwigcptrFoo) (_swig_ret SwigcptrFooBar) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) - _cgo_runtime_cgocall(_wrap__swig_DirectorFoo_upcall_MakeFooBar, _swig_p) - return -} - -func (swig_p *_swig_DirectorFoo) MakeFooBar() FooBar { - if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceFooMakeFooBar); swig_ok { - return swig_g.MakeFooBar() - } - var swig_r FooBar - swig_r = _swig_wrap__swig_DirectorFoo_upcall_MakeFooBar(swig_p.SwigcptrFoo) - return swig_r -} - -func DirectorFooMakeFooBar(p Foo) FooBar { - var swig_r FooBar - swig_r = _swig_wrap__swig_DirectorFoo_upcall_MakeFooBar(p.(*_swig_DirectorFoo).SwigcptrFoo) - return swig_r -} - -func Swig_DirectorFoo_callback_makeFooBar(p *_swig_DirectorFoo) (swig_result SwigcptrFooBar) { - var swig_r SwigcptrFooBar - swig_r = SwigcptrFooBar(p.MakeFooBar().Swigcptr()) - return swig_r -} - -type SwigcptrFoo uintptr - -func (p SwigcptrFoo) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrFoo) SwigIsFoo() { -} - -func (p SwigcptrFoo) DirectorInterface() interface{} { - return nil -} - -var _wrap_delete_Foo unsafe.Pointer - -func _swig_wrap_delete_Foo(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Foo, _swig_p) - return -} - -func DeleteFoo(arg1 Foo) { - _swig_wrap_delete_Foo(arg1.Swigcptr()) -} - -var _wrap_Foo_ping unsafe.Pointer - -func _swig_wrap_Foo_ping(base SwigcptrFoo) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_ping, _swig_p) - return -} - -func (arg1 SwigcptrFoo) Ping() (_swig_ret string) { - return _swig_wrap_Foo_ping(arg1) -} - -var _wrap_Foo_pong unsafe.Pointer - -func _swig_wrap_Foo_pong(base SwigcptrFoo) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_pong, _swig_p) - return -} - -func (arg1 SwigcptrFoo) Pong() (_swig_ret string) { - return _swig_wrap_Foo_pong(arg1) -} - -var _wrap_Foo_fooBar unsafe.Pointer - -func _swig_wrap_Foo_fooBar(base SwigcptrFoo, _ uintptr) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_fooBar, _swig_p) - return -} - -func (arg1 SwigcptrFoo) FooBar(arg2 FooBar) (_swig_ret string) { - return _swig_wrap_Foo_fooBar(arg1, arg2.Swigcptr()) -} - -var _wrap_Foo_makeFoo unsafe.Pointer - -func _swig_wrap_Foo_makeFoo(base SwigcptrFoo) (_ SwigcptrFoo) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_makeFoo, _swig_p) - return -} - -func (arg1 SwigcptrFoo) MakeFoo() (_swig_ret Foo) { - return _swig_wrap_Foo_makeFoo(arg1) -} - -var _wrap_Foo_makeFooBar unsafe.Pointer - -func _swig_wrap_Foo_makeFooBar(base SwigcptrFoo) (_ SwigcptrFooBar) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_makeFooBar, _swig_p) - return -} - -func (arg1 SwigcptrFoo) MakeFooBar() (_swig_ret FooBar) { - return _swig_wrap_Foo_makeFooBar(arg1) -} - -var _wrap_Foo_get_self unsafe.Pointer - -func _swig_wrap_Foo_get_self(base uintptr) (_ SwigcptrFoo) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_get_self, _swig_p) - return -} - -func FooGet_self(arg1 Foo) (_swig_ret Foo) { - return _swig_wrap_Foo_get_self(arg1.Swigcptr()) -} - -var _wrap_new_Foo unsafe.Pointer - -func _swig_wrap_new_Foo() (base SwigcptrFoo) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Foo, _swig_p) - return -} - -func NewFoo() (_swig_ret Foo) { - return _swig_wrap_new_Foo() -} - -type Foo interface { - Swigcptr() uintptr - SwigIsFoo() - DirectorInterface() interface{} - Ping() (_swig_ret string) - Pong() (_swig_ret string) - FooBar(arg2 FooBar) (_swig_ret string) - MakeFoo() (_swig_ret Foo) - MakeFooBar() (_swig_ret FooBar) -} - - -type SwigcptrSwigDirector_Foo uintptr -type SwigDirector_Foo interface { - Swigcptr() uintptr; -} -func (p SwigcptrSwigDirector_Foo) Swigcptr() uintptr { - return uintptr(p) -} - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/director_nspace_director_name_collision.go b/Examples/test-suite/go/director_nspace_director_name_collision.go deleted file mode 100644 index 4c69b1be0..000000000 --- a/Examples/test-suite/go/director_nspace_director_name_collision.go +++ /dev/null @@ -1,180 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../director_nspace_director_name_collision.i - -package director_nspace_director_name_collision - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type _swig_DirectorFoo struct { - SwigcptrFoo - v interface{} -} - -func (p *_swig_DirectorFoo) Swigcptr() uintptr { - return p.SwigcptrFoo.Swigcptr() -} - -func (p *_swig_DirectorFoo) SwigIsFoo() { -} - -func (p *_swig_DirectorFoo) DirectorInterface() interface{} { - return p.v -} - -var _wrap__swig_NewDirectorFooFoo unsafe.Pointer - -func _swig_NewDirectorFooFoo(_swig_director *_swig_DirectorFoo) (_swig_ret SwigcptrFoo) { - _swig_p := uintptr(unsafe.Pointer(&_swig_director)) - _cgo_runtime_cgocall(_wrap__swig_NewDirectorFooFoo, _swig_p) - return -} - -func NewDirectorFoo(v interface{}) Foo { - p := &_swig_DirectorFoo{0, v} - p.SwigcptrFoo = _swig_NewDirectorFooFoo(p) - return p -} - -var _wrap_DeleteDirectorFoo unsafe.Pointer - -func _swig_wrap_DeleteDirectorFoo(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_DeleteDirectorFoo, _swig_p) - return -} - -func DeleteDirectorFoo(arg1 Foo) { - _swig_wrap_DeleteDirectorFoo(arg1.Swigcptr()) -} - -func Swiggo_DeleteDirector_Foo(p *_swig_DirectorFoo) { - p.SwigcptrFoo = 0 -} - -type _swig_DirectorInterfaceFooPing interface { - Ping() string -} - -var _wrap__swig_DirectorFoo_upcall_Ping unsafe.Pointer - -func _swig_wrap__swig_DirectorFoo_upcall_Ping(_swig_ptr SwigcptrFoo) (_swig_ret string) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) - _cgo_runtime_cgocall(_wrap__swig_DirectorFoo_upcall_Ping, _swig_p) - return -} - -func (swig_p *_swig_DirectorFoo) Ping() string { - if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceFooPing); swig_ok { - return swig_g.Ping() - } - var swig_r string - swig_r = _swig_wrap__swig_DirectorFoo_upcall_Ping(swig_p.SwigcptrFoo) - return swig_r -} - -func DirectorFooPing(p Foo) string { - var swig_r string - swig_r = _swig_wrap__swig_DirectorFoo_upcall_Ping(p.(*_swig_DirectorFoo).SwigcptrFoo) - return swig_r -} - -func Swig_DirectorFoo_callback_ping(p *_swig_DirectorFoo) (swig_result string) { - var swig_r string - swig_r = p.Ping() - return swig_r -} - -type SwigcptrFoo uintptr - -func (p SwigcptrFoo) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrFoo) SwigIsFoo() { -} - -func (p SwigcptrFoo) DirectorInterface() interface{} { - return nil -} - -var _wrap_delete_Foo unsafe.Pointer - -func _swig_wrap_delete_Foo(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Foo, _swig_p) - return -} - -func DeleteFoo(arg1 Foo) { - _swig_wrap_delete_Foo(arg1.Swigcptr()) -} - -var _wrap_Foo_ping unsafe.Pointer - -func _swig_wrap_Foo_ping(base SwigcptrFoo) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_ping, _swig_p) - return -} - -func (arg1 SwigcptrFoo) Ping() (_swig_ret string) { - return _swig_wrap_Foo_ping(arg1) -} - -var _wrap_new_Foo unsafe.Pointer - -func _swig_wrap_new_Foo() (base SwigcptrFoo) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Foo, _swig_p) - return -} - -func NewFoo() (_swig_ret Foo) { - return _swig_wrap_new_Foo() -} - -type Foo interface { - Swigcptr() uintptr - SwigIsFoo() - DirectorInterface() interface{} - Ping() (_swig_ret string) -} - - -type SwigcptrSwigDirector_Foo uintptr -type SwigDirector_Foo interface { - Swigcptr() uintptr; -} -func (p SwigcptrSwigDirector_Foo) Swigcptr() uintptr { - return uintptr(p) -} - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/director_nspace_director_name_collision_wrap.h b/Examples/test-suite/go/director_nspace_director_name_collision_wrap.h deleted file mode 100644 index f202865c6..000000000 --- a/Examples/test-suite/go/director_nspace_director_name_collision_wrap.h +++ /dev/null @@ -1,29 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../director_nspace_director_name_collision.i - -#ifndef SWIG_director_nspace_director_name_collision_WRAP_H_ -#define SWIG_director_nspace_director_name_collision_WRAP_H_ - -class SwigDirector_Foo : public TopLevel::A::Foo -{ - public: - SwigDirector_Foo(void *swig_p); - virtual ~SwigDirector_Foo(); - std::string _swig_upcall_ping() { - return TopLevel::A::Foo::ping(); - } - virtual std::string ping(); - private: - void *go_val; -}; - -#endif diff --git a/Examples/test-suite/go/director_nspace_wrap.h b/Examples/test-suite/go/director_nspace_wrap.h deleted file mode 100644 index 552fffa1f..000000000 --- a/Examples/test-suite/go/director_nspace_wrap.h +++ /dev/null @@ -1,45 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../director_nspace.i - -#ifndef SWIG_director_nspace_WRAP_H_ -#define SWIG_director_nspace_WRAP_H_ - -class SwigDirector_Foo : public TopLevel::Bar::Foo -{ - public: - SwigDirector_Foo(void *swig_p); - virtual ~SwigDirector_Foo(); - std::string _swig_upcall_ping() { - return TopLevel::Bar::Foo::ping(); - } - virtual std::string ping(); - std::string _swig_upcall_pong() { - return TopLevel::Bar::Foo::pong(); - } - virtual std::string pong(); - std::string _swig_upcall_fooBar(TopLevel::Bar::FooBar *fb) { - return TopLevel::Bar::Foo::fooBar(fb); - } - virtual std::string fooBar(TopLevel::Bar::FooBar *fb); - TopLevel::Bar::Foo _swig_upcall_makeFoo() { - return TopLevel::Bar::Foo::makeFoo(); - } - virtual TopLevel::Bar::Foo makeFoo(); - TopLevel::Bar::FooBar _swig_upcall_makeFooBar() { - return TopLevel::Bar::Foo::makeFooBar(); - } - virtual TopLevel::Bar::FooBar makeFooBar(); - private: - void *go_val; -}; - -#endif diff --git a/Examples/test-suite/go/director_overload.go b/Examples/test-suite/go/director_overload.go deleted file mode 100644 index f99a600d4..000000000 --- a/Examples/test-suite/go/director_overload.go +++ /dev/null @@ -1,862 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../director_overload.i - -package director_overload - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type _swig_DirectorOverloadedClass struct { - SwigcptrOverloadedClass - v interface{} -} - -func (p *_swig_DirectorOverloadedClass) Swigcptr() uintptr { - return p.SwigcptrOverloadedClass.Swigcptr() -} - -func (p *_swig_DirectorOverloadedClass) SwigIsOverloadedClass() { -} - -func (p *_swig_DirectorOverloadedClass) DirectorInterface() interface{} { - return p.v -} - -var _wrap__swig_NewDirectorOverloadedClassOverloadedClass unsafe.Pointer - -func _swig_NewDirectorOverloadedClassOverloadedClass(_swig_director *_swig_DirectorOverloadedClass) (_swig_ret SwigcptrOverloadedClass) { - _swig_p := uintptr(unsafe.Pointer(&_swig_director)) - _cgo_runtime_cgocall(_wrap__swig_NewDirectorOverloadedClassOverloadedClass, _swig_p) - return -} - -func NewDirectorOverloadedClass(v interface{}) OverloadedClass { - p := &_swig_DirectorOverloadedClass{0, v} - p.SwigcptrOverloadedClass = _swig_NewDirectorOverloadedClassOverloadedClass(p) - return p -} - -var _wrap_DeleteDirectorOverloadedClass unsafe.Pointer - -func _swig_wrap_DeleteDirectorOverloadedClass(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_DeleteDirectorOverloadedClass, _swig_p) - return -} - -func DeleteDirectorOverloadedClass(arg1 OverloadedClass) { - _swig_wrap_DeleteDirectorOverloadedClass(arg1.Swigcptr()) -} - -func Swiggo_DeleteDirector_OverloadedClass(p *_swig_DirectorOverloadedClass) { - p.SwigcptrOverloadedClass = 0 -} - -type _swig_DirectorInterfaceOverloadedClassMethod1 interface { - Method1() -} - -var _wrap__swig_DirectorOverloadedClass_upcall_Method1 unsafe.Pointer - -func _swig_wrap__swig_DirectorOverloadedClass_upcall_Method1(_swig_ptr SwigcptrOverloadedClass) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) - _cgo_runtime_cgocall(_wrap__swig_DirectorOverloadedClass_upcall_Method1, _swig_p) - return -} - -func (swig_p *_swig_DirectorOverloadedClass) Method1() { - if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceOverloadedClassMethod1); swig_ok { - swig_g.Method1() - return - } - _swig_wrap__swig_DirectorOverloadedClass_upcall_Method1(swig_p.SwigcptrOverloadedClass) -} - -func DirectorOverloadedClassMethod1(p OverloadedClass) { - _swig_wrap__swig_DirectorOverloadedClass_upcall_Method1(p.(*_swig_DirectorOverloadedClass).SwigcptrOverloadedClass) -} - -func Swig_DirectorOverloadedClass_callback_method1(p *_swig_DirectorOverloadedClass) { - p.Method1() -} - -type _swig_DirectorInterfaceOverloadedClassMethod2__SWIG_0 interface { - Method2__SWIG_0() -} - -var _wrap__swig_DirectorOverloadedClass_upcall_Method2__SWIG_0 unsafe.Pointer - -func _swig_wrap__swig_DirectorOverloadedClass_upcall_Method2__SWIG_0(_swig_ptr SwigcptrOverloadedClass) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) - _cgo_runtime_cgocall(_wrap__swig_DirectorOverloadedClass_upcall_Method2__SWIG_0, _swig_p) - return -} - -func (swig_p *_swig_DirectorOverloadedClass) Method2__SWIG_0() { - if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceOverloadedClassMethod2__SWIG_0); swig_ok { - swig_g.Method2__SWIG_0() - return - } - _swig_wrap__swig_DirectorOverloadedClass_upcall_Method2__SWIG_0(swig_p.SwigcptrOverloadedClass) -} - -func DirectorOverloadedClassMethod2__SWIG_0(p OverloadedClass) { - _swig_wrap__swig_DirectorOverloadedClass_upcall_Method2__SWIG_0(p.(*_swig_DirectorOverloadedClass).SwigcptrOverloadedClass) -} - -func Swig_DirectorOverloadedClass_callback_method2__SWIG_0(p *_swig_DirectorOverloadedClass) { - p.Method2__SWIG_0() -} - -type _swig_DirectorInterfaceOverloadedClassMethod3 interface { - Method3() -} - -var _wrap__swig_DirectorOverloadedClass_upcall_Method3 unsafe.Pointer - -func _swig_wrap__swig_DirectorOverloadedClass_upcall_Method3(_swig_ptr SwigcptrOverloadedClass) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) - _cgo_runtime_cgocall(_wrap__swig_DirectorOverloadedClass_upcall_Method3, _swig_p) - return -} - -func (swig_p *_swig_DirectorOverloadedClass) Method3() { - if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceOverloadedClassMethod3); swig_ok { - swig_g.Method3() - return - } - _swig_wrap__swig_DirectorOverloadedClass_upcall_Method3(swig_p.SwigcptrOverloadedClass) -} - -func DirectorOverloadedClassMethod3(p OverloadedClass) { - _swig_wrap__swig_DirectorOverloadedClass_upcall_Method3(p.(*_swig_DirectorOverloadedClass).SwigcptrOverloadedClass) -} - -func Swig_DirectorOverloadedClass_callback_method3(p *_swig_DirectorOverloadedClass) { - p.Method3() -} - -type _swig_DirectorInterfaceOverloadedClassMethod2__SWIG_1 interface { - Method2__SWIG_1(bool) -} - -var _wrap__swig_DirectorOverloadedClass_upcall_Method2__SWIG_1 unsafe.Pointer - -func _swig_wrap__swig_DirectorOverloadedClass_upcall_Method2__SWIG_1(_swig_ptr SwigcptrOverloadedClass, _ bool) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) - _cgo_runtime_cgocall(_wrap__swig_DirectorOverloadedClass_upcall_Method2__SWIG_1, _swig_p) - return -} - -func (swig_p *_swig_DirectorOverloadedClass) Method2__SWIG_1(b bool) { - if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceOverloadedClassMethod2__SWIG_1); swig_ok { - swig_g.Method2__SWIG_1(b) - return - } - _swig_wrap__swig_DirectorOverloadedClass_upcall_Method2__SWIG_1(swig_p.SwigcptrOverloadedClass, b) -} - -func DirectorOverloadedClassMethod2__SWIG_1(p OverloadedClass, arg2 bool) { - _swig_wrap__swig_DirectorOverloadedClass_upcall_Method2__SWIG_1(p.(*_swig_DirectorOverloadedClass).SwigcptrOverloadedClass, arg2) -} - -func Swig_DirectorOverloadedClass_callback_method2__SWIG_1(p *_swig_DirectorOverloadedClass, arg2 bool) { - p.Method2__SWIG_1(arg2) -} - -func (p _swig_DirectorOverloadedClass) Method2(a ...interface{}) { - argc := len(a) - if argc == 0 { - p.Method2__SWIG_0() - return - } - if argc == 1 { - p.Method2__SWIG_1(a[0].(bool)) - return - } - panic("No match for overloaded function call") -} - -func DirectorOverloadedClassMethod2(p *_swig_DirectorOverloadedClass, a ...interface{}) { - argc := len(a) - if argc == 0 { - DirectorOverloadedClassMethod2__SWIG_0(p) - return - } - if argc == 1 { - DirectorOverloadedClassMethod2__SWIG_1(p, a[0].(bool)) - return - } - panic("No match for overloaded function call") -} - -type SwigcptrOverloadedClass uintptr - -func (p SwigcptrOverloadedClass) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrOverloadedClass) SwigIsOverloadedClass() { -} - -func (p SwigcptrOverloadedClass) DirectorInterface() interface{} { - return nil -} - -var _wrap_delete_OverloadedClass unsafe.Pointer - -func _swig_wrap_delete_OverloadedClass(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_OverloadedClass, _swig_p) - return -} - -func DeleteOverloadedClass(arg1 OverloadedClass) { - _swig_wrap_delete_OverloadedClass(arg1.Swigcptr()) -} - -var _wrap_OverloadedClass_method1 unsafe.Pointer - -func _swig_wrap_OverloadedClass_method1(base SwigcptrOverloadedClass) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_OverloadedClass_method1, _swig_p) - return -} - -func (arg1 SwigcptrOverloadedClass) Method1() { - _swig_wrap_OverloadedClass_method1(arg1) -} - -var _wrap_OverloadedClass_method2__SWIG_0 unsafe.Pointer - -func _swig_wrap_OverloadedClass_method2__SWIG_0(base SwigcptrOverloadedClass) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_OverloadedClass_method2__SWIG_0, _swig_p) - return -} - -func (arg1 SwigcptrOverloadedClass) Method2__SWIG_0() { - _swig_wrap_OverloadedClass_method2__SWIG_0(arg1) -} - -var _wrap_OverloadedClass_method3 unsafe.Pointer - -func _swig_wrap_OverloadedClass_method3(base SwigcptrOverloadedClass) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_OverloadedClass_method3, _swig_p) - return -} - -func (arg1 SwigcptrOverloadedClass) Method3() { - _swig_wrap_OverloadedClass_method3(arg1) -} - -var _wrap_OverloadedClass_method2__SWIG_1 unsafe.Pointer - -func _swig_wrap_OverloadedClass_method2__SWIG_1(base SwigcptrOverloadedClass, _ bool) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_OverloadedClass_method2__SWIG_1, _swig_p) - return -} - -func (arg1 SwigcptrOverloadedClass) Method2__SWIG_1(arg2 bool) { - _swig_wrap_OverloadedClass_method2__SWIG_1(arg1, arg2) -} - -func (p SwigcptrOverloadedClass) Method2(a ...interface{}) { - argc := len(a) - if argc == 0 { - p.Method2__SWIG_0() - return - } - if argc == 1 { - p.Method2__SWIG_1(a[0].(bool)) - return - } - panic("No match for overloaded function call") -} - -var _wrap_new_OverloadedClass unsafe.Pointer - -func _swig_wrap_new_OverloadedClass() (base SwigcptrOverloadedClass) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_OverloadedClass, _swig_p) - return -} - -func NewOverloadedClass() (_swig_ret OverloadedClass) { - return _swig_wrap_new_OverloadedClass() -} - -type OverloadedClass interface { - Swigcptr() uintptr - SwigIsOverloadedClass() - DirectorInterface() interface{} - Method1() - Method3() - Method2(a ...interface{}) -} - -type _swig_DirectorOverloadedPointers struct { - SwigcptrOverloadedPointers - v interface{} -} - -func (p *_swig_DirectorOverloadedPointers) Swigcptr() uintptr { - return p.SwigcptrOverloadedPointers.Swigcptr() -} - -func (p *_swig_DirectorOverloadedPointers) SwigIsOverloadedPointers() { -} - -func (p *_swig_DirectorOverloadedPointers) DirectorInterface() interface{} { - return p.v -} - -var _wrap__swig_NewDirectorOverloadedPointersOverloadedPointers unsafe.Pointer - -func _swig_NewDirectorOverloadedPointersOverloadedPointers(_swig_director *_swig_DirectorOverloadedPointers) (_swig_ret SwigcptrOverloadedPointers) { - _swig_p := uintptr(unsafe.Pointer(&_swig_director)) - _cgo_runtime_cgocall(_wrap__swig_NewDirectorOverloadedPointersOverloadedPointers, _swig_p) - return -} - -func NewDirectorOverloadedPointers(v interface{}) OverloadedPointers { - p := &_swig_DirectorOverloadedPointers{0, v} - p.SwigcptrOverloadedPointers = _swig_NewDirectorOverloadedPointersOverloadedPointers(p) - return p -} - -var _wrap_DeleteDirectorOverloadedPointers unsafe.Pointer - -func _swig_wrap_DeleteDirectorOverloadedPointers(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_DeleteDirectorOverloadedPointers, _swig_p) - return -} - -func DeleteDirectorOverloadedPointers(arg1 OverloadedPointers) { - _swig_wrap_DeleteDirectorOverloadedPointers(arg1.Swigcptr()) -} - -func Swiggo_DeleteDirector_OverloadedPointers(p *_swig_DirectorOverloadedPointers) { - p.SwigcptrOverloadedPointers = 0 -} - -type _swig_DirectorInterfaceOverloadedPointersMethod__SWIG_0 interface { - Method__SWIG_0(*int) -} - -var _wrap__swig_DirectorOverloadedPointers_upcall_Method__SWIG_0 unsafe.Pointer - -func _swig_wrap__swig_DirectorOverloadedPointers_upcall_Method__SWIG_0(_swig_ptr SwigcptrOverloadedPointers, _ *int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) - _cgo_runtime_cgocall(_wrap__swig_DirectorOverloadedPointers_upcall_Method__SWIG_0, _swig_p) - return -} - -func (swig_p *_swig_DirectorOverloadedPointers) Method__SWIG_0(p *int) { - if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceOverloadedPointersMethod__SWIG_0); swig_ok { - swig_g.Method__SWIG_0(p) - return - } - _swig_wrap__swig_DirectorOverloadedPointers_upcall_Method__SWIG_0(swig_p.SwigcptrOverloadedPointers, p) -} - -func DirectorOverloadedPointersMethod__SWIG_0(p OverloadedPointers, arg2 *int) { - _swig_wrap__swig_DirectorOverloadedPointers_upcall_Method__SWIG_0(p.(*_swig_DirectorOverloadedPointers).SwigcptrOverloadedPointers, arg2) -} - -func Swig_DirectorOverloadedPointers_callback_method__SWIG_0(p *_swig_DirectorOverloadedPointers, arg2 *int) { - p.Method__SWIG_0(arg2) -} - -type _swig_DirectorInterfaceOverloadedPointersMethod__SWIG_1 interface { - Method__SWIG_1(*float64) -} - -var _wrap__swig_DirectorOverloadedPointers_upcall_Method__SWIG_1 unsafe.Pointer - -func _swig_wrap__swig_DirectorOverloadedPointers_upcall_Method__SWIG_1(_swig_ptr SwigcptrOverloadedPointers, _ *float64) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) - _cgo_runtime_cgocall(_wrap__swig_DirectorOverloadedPointers_upcall_Method__SWIG_1, _swig_p) - return -} - -func (swig_p *_swig_DirectorOverloadedPointers) Method__SWIG_1(p *float64) { - if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceOverloadedPointersMethod__SWIG_1); swig_ok { - swig_g.Method__SWIG_1(p) - return - } - _swig_wrap__swig_DirectorOverloadedPointers_upcall_Method__SWIG_1(swig_p.SwigcptrOverloadedPointers, p) -} - -func DirectorOverloadedPointersMethod__SWIG_1(p OverloadedPointers, arg2 *float64) { - _swig_wrap__swig_DirectorOverloadedPointers_upcall_Method__SWIG_1(p.(*_swig_DirectorOverloadedPointers).SwigcptrOverloadedPointers, arg2) -} - -func Swig_DirectorOverloadedPointers_callback_method__SWIG_1(p *_swig_DirectorOverloadedPointers, arg2 *float64) { - p.Method__SWIG_1(arg2) -} - -type _swig_DirectorInterfaceOverloadedPointersMethod__SWIG_2 interface { - Method__SWIG_2(*bool) -} - -var _wrap__swig_DirectorOverloadedPointers_upcall_Method__SWIG_2 unsafe.Pointer - -func _swig_wrap__swig_DirectorOverloadedPointers_upcall_Method__SWIG_2(_swig_ptr SwigcptrOverloadedPointers, _ *bool) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) - _cgo_runtime_cgocall(_wrap__swig_DirectorOverloadedPointers_upcall_Method__SWIG_2, _swig_p) - return -} - -func (swig_p *_swig_DirectorOverloadedPointers) Method__SWIG_2(r *bool) { - if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceOverloadedPointersMethod__SWIG_2); swig_ok { - swig_g.Method__SWIG_2(r) - return - } - _swig_wrap__swig_DirectorOverloadedPointers_upcall_Method__SWIG_2(swig_p.SwigcptrOverloadedPointers, r) -} - -func DirectorOverloadedPointersMethod__SWIG_2(p OverloadedPointers, arg2 *bool) { - _swig_wrap__swig_DirectorOverloadedPointers_upcall_Method__SWIG_2(p.(*_swig_DirectorOverloadedPointers).SwigcptrOverloadedPointers, arg2) -} - -func Swig_DirectorOverloadedPointers_callback_method__SWIG_2(p *_swig_DirectorOverloadedPointers, arg2 *bool) { - p.Method__SWIG_2(arg2) -} - -type _swig_DirectorInterfaceOverloadedPointersMethod__SWIG_3 interface { - Method__SWIG_3(*int16) -} - -var _wrap__swig_DirectorOverloadedPointers_upcall_Method__SWIG_3 unsafe.Pointer - -func _swig_wrap__swig_DirectorOverloadedPointers_upcall_Method__SWIG_3(_swig_ptr SwigcptrOverloadedPointers, _ *int16) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) - _cgo_runtime_cgocall(_wrap__swig_DirectorOverloadedPointers_upcall_Method__SWIG_3, _swig_p) - return -} - -func (swig_p *_swig_DirectorOverloadedPointers) Method__SWIG_3(r *int16) { - if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceOverloadedPointersMethod__SWIG_3); swig_ok { - swig_g.Method__SWIG_3(r) - return - } - _swig_wrap__swig_DirectorOverloadedPointers_upcall_Method__SWIG_3(swig_p.SwigcptrOverloadedPointers, r) -} - -func DirectorOverloadedPointersMethod__SWIG_3(p OverloadedPointers, arg2 *int16) { - _swig_wrap__swig_DirectorOverloadedPointers_upcall_Method__SWIG_3(p.(*_swig_DirectorOverloadedPointers).SwigcptrOverloadedPointers, arg2) -} - -func Swig_DirectorOverloadedPointers_callback_method__SWIG_3(p *_swig_DirectorOverloadedPointers, arg2 *int16) { - p.Method__SWIG_3(arg2) -} - -type _swig_DirectorInterfaceOverloadedPointersMethod__SWIG_4 interface { - Method__SWIG_4(OverloadedClass) -} - -var _wrap__swig_DirectorOverloadedPointers_upcall_Method__SWIG_4 unsafe.Pointer - -func _swig_wrap__swig_DirectorOverloadedPointers_upcall_Method__SWIG_4(_swig_ptr SwigcptrOverloadedPointers, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) - _cgo_runtime_cgocall(_wrap__swig_DirectorOverloadedPointers_upcall_Method__SWIG_4, _swig_p) - return -} - -func (swig_p *_swig_DirectorOverloadedPointers) Method__SWIG_4(p OverloadedClass) { - if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceOverloadedPointersMethod__SWIG_4); swig_ok { - swig_g.Method__SWIG_4(p) - return - } - _swig_wrap__swig_DirectorOverloadedPointers_upcall_Method__SWIG_4(swig_p.SwigcptrOverloadedPointers, p.Swigcptr()) -} - -func DirectorOverloadedPointersMethod__SWIG_4(p OverloadedPointers, arg2 OverloadedClass) { - _swig_wrap__swig_DirectorOverloadedPointers_upcall_Method__SWIG_4(p.(*_swig_DirectorOverloadedPointers).SwigcptrOverloadedPointers, arg2.Swigcptr()) -} - -func Swig_DirectorOverloadedPointers_callback_method__SWIG_4(p *_swig_DirectorOverloadedPointers, arg2 uintptr) { - p.Method__SWIG_4(SwigcptrOverloadedClass(arg2)) -} - -type _swig_DirectorInterfaceOverloadedPointersMethod__SWIG_5 interface { - Method__SWIG_5(OverloadedPointers) -} - -var _wrap__swig_DirectorOverloadedPointers_upcall_Method__SWIG_5 unsafe.Pointer - -func _swig_wrap__swig_DirectorOverloadedPointers_upcall_Method__SWIG_5(_swig_ptr SwigcptrOverloadedPointers, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) - _cgo_runtime_cgocall(_wrap__swig_DirectorOverloadedPointers_upcall_Method__SWIG_5, _swig_p) - return -} - -func (swig_p *_swig_DirectorOverloadedPointers) Method__SWIG_5(p OverloadedPointers) { - if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceOverloadedPointersMethod__SWIG_5); swig_ok { - swig_g.Method__SWIG_5(p) - return - } - _swig_wrap__swig_DirectorOverloadedPointers_upcall_Method__SWIG_5(swig_p.SwigcptrOverloadedPointers, p.Swigcptr()) -} - -func DirectorOverloadedPointersMethod__SWIG_5(p OverloadedPointers, arg2 OverloadedPointers) { - _swig_wrap__swig_DirectorOverloadedPointers_upcall_Method__SWIG_5(p.(*_swig_DirectorOverloadedPointers).SwigcptrOverloadedPointers, arg2.Swigcptr()) -} - -func Swig_DirectorOverloadedPointers_callback_method__SWIG_5(p *_swig_DirectorOverloadedPointers, arg2 uintptr) { - p.Method__SWIG_5(SwigcptrOverloadedPointers(arg2)) -} - -func (p _swig_DirectorOverloadedPointers) Method(a ...interface{}) { - argc := len(a) - if argc == 1 { - if _, ok := a[0].(*int); !ok { - goto check_1 - } - p.Method__SWIG_0(a[0].(*int)) - return - } -check_1: - if argc == 1 { - if _, ok := a[0].(*float64); !ok { - goto check_2 - } - p.Method__SWIG_1(a[0].(*float64)) - return - } -check_2: - if argc == 1 { - if _, ok := a[0].(*bool); !ok { - goto check_3 - } - p.Method__SWIG_2(a[0].(*bool)) - return - } -check_3: - if argc == 1 { - if _, ok := a[0].(*int16); !ok { - goto check_4 - } - p.Method__SWIG_3(a[0].(*int16)) - return - } -check_4: - if argc == 1 { - if _, ok := a[0].(OverloadedClass); !ok { - goto check_5 - } - p.Method__SWIG_4(a[0].(OverloadedClass)) - return - } -check_5: - if argc == 1 { - p.Method__SWIG_5(a[0].(OverloadedPointers)) - return - } - panic("No match for overloaded function call") -} - -func DirectorOverloadedPointersMethod(p *_swig_DirectorOverloadedPointers, a ...interface{}) { - argc := len(a) - if argc == 1 { - if _, ok := a[0].(*int); !ok { - goto check_1 - } - DirectorOverloadedPointersMethod__SWIG_0(p, a[0].(*int)) - return - } -check_1: - if argc == 1 { - if _, ok := a[0].(*float64); !ok { - goto check_2 - } - DirectorOverloadedPointersMethod__SWIG_1(p, a[0].(*float64)) - return - } -check_2: - if argc == 1 { - if _, ok := a[0].(*bool); !ok { - goto check_3 - } - DirectorOverloadedPointersMethod__SWIG_2(p, a[0].(*bool)) - return - } -check_3: - if argc == 1 { - if _, ok := a[0].(*int16); !ok { - goto check_4 - } - DirectorOverloadedPointersMethod__SWIG_3(p, a[0].(*int16)) - return - } -check_4: - if argc == 1 { - if _, ok := a[0].(OverloadedClass); !ok { - goto check_5 - } - DirectorOverloadedPointersMethod__SWIG_4(p, a[0].(OverloadedClass)) - return - } -check_5: - if argc == 1 { - DirectorOverloadedPointersMethod__SWIG_5(p, a[0].(OverloadedPointers)) - return - } - panic("No match for overloaded function call") -} - -type _swig_DirectorInterfaceOverloadedPointersNotover interface { - Notover(*int) -} - -var _wrap__swig_DirectorOverloadedPointers_upcall_Notover unsafe.Pointer - -func _swig_wrap__swig_DirectorOverloadedPointers_upcall_Notover(_swig_ptr SwigcptrOverloadedPointers, _ *int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) - _cgo_runtime_cgocall(_wrap__swig_DirectorOverloadedPointers_upcall_Notover, _swig_p) - return -} - -func (swig_p *_swig_DirectorOverloadedPointers) Notover(p *int) { - if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceOverloadedPointersNotover); swig_ok { - swig_g.Notover(p) - return - } - _swig_wrap__swig_DirectorOverloadedPointers_upcall_Notover(swig_p.SwigcptrOverloadedPointers, p) -} - -func DirectorOverloadedPointersNotover(p OverloadedPointers, arg2 *int) { - _swig_wrap__swig_DirectorOverloadedPointers_upcall_Notover(p.(*_swig_DirectorOverloadedPointers).SwigcptrOverloadedPointers, arg2) -} - -func Swig_DirectorOverloadedPointers_callback_notover(p *_swig_DirectorOverloadedPointers, arg2 *int) { - p.Notover(arg2) -} - -type SwigcptrOverloadedPointers uintptr - -func (p SwigcptrOverloadedPointers) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrOverloadedPointers) SwigIsOverloadedPointers() { -} - -func (p SwigcptrOverloadedPointers) DirectorInterface() interface{} { - return nil -} - -var _wrap_delete_OverloadedPointers unsafe.Pointer - -func _swig_wrap_delete_OverloadedPointers(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_OverloadedPointers, _swig_p) - return -} - -func DeleteOverloadedPointers(arg1 OverloadedPointers) { - _swig_wrap_delete_OverloadedPointers(arg1.Swigcptr()) -} - -var _wrap_OverloadedPointers_method__SWIG_0 unsafe.Pointer - -func _swig_wrap_OverloadedPointers_method__SWIG_0(base SwigcptrOverloadedPointers, _ *int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_OverloadedPointers_method__SWIG_0, _swig_p) - return -} - -func (arg1 SwigcptrOverloadedPointers) Method__SWIG_0(arg2 *int) { - _swig_wrap_OverloadedPointers_method__SWIG_0(arg1, arg2) -} - -var _wrap_OverloadedPointers_method__SWIG_1 unsafe.Pointer - -func _swig_wrap_OverloadedPointers_method__SWIG_1(base SwigcptrOverloadedPointers, _ *float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_OverloadedPointers_method__SWIG_1, _swig_p) - return -} - -func (arg1 SwigcptrOverloadedPointers) Method__SWIG_1(arg2 *float64) { - _swig_wrap_OverloadedPointers_method__SWIG_1(arg1, arg2) -} - -var _wrap_OverloadedPointers_method__SWIG_2 unsafe.Pointer - -func _swig_wrap_OverloadedPointers_method__SWIG_2(base SwigcptrOverloadedPointers, _ *bool) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_OverloadedPointers_method__SWIG_2, _swig_p) - return -} - -func (arg1 SwigcptrOverloadedPointers) Method__SWIG_2(arg2 *bool) { - _swig_wrap_OverloadedPointers_method__SWIG_2(arg1, arg2) -} - -var _wrap_OverloadedPointers_method__SWIG_3 unsafe.Pointer - -func _swig_wrap_OverloadedPointers_method__SWIG_3(base SwigcptrOverloadedPointers, _ *int16) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_OverloadedPointers_method__SWIG_3, _swig_p) - return -} - -func (arg1 SwigcptrOverloadedPointers) Method__SWIG_3(arg2 *int16) { - _swig_wrap_OverloadedPointers_method__SWIG_3(arg1, arg2) -} - -var _wrap_OverloadedPointers_method__SWIG_4 unsafe.Pointer - -func _swig_wrap_OverloadedPointers_method__SWIG_4(base SwigcptrOverloadedPointers, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_OverloadedPointers_method__SWIG_4, _swig_p) - return -} - -func (arg1 SwigcptrOverloadedPointers) Method__SWIG_4(arg2 OverloadedClass) { - _swig_wrap_OverloadedPointers_method__SWIG_4(arg1, arg2.Swigcptr()) -} - -var _wrap_OverloadedPointers_method__SWIG_5 unsafe.Pointer - -func _swig_wrap_OverloadedPointers_method__SWIG_5(base SwigcptrOverloadedPointers, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_OverloadedPointers_method__SWIG_5, _swig_p) - return -} - -func (arg1 SwigcptrOverloadedPointers) Method__SWIG_5(arg2 OverloadedPointers) { - _swig_wrap_OverloadedPointers_method__SWIG_5(arg1, arg2.Swigcptr()) -} - -func (p SwigcptrOverloadedPointers) Method(a ...interface{}) { - argc := len(a) - if argc == 1 { - if _, ok := a[0].(*int); !ok { - goto check_1 - } - p.Method__SWIG_0(a[0].(*int)) - return - } -check_1: - if argc == 1 { - if _, ok := a[0].(*float64); !ok { - goto check_2 - } - p.Method__SWIG_1(a[0].(*float64)) - return - } -check_2: - if argc == 1 { - if _, ok := a[0].(*bool); !ok { - goto check_3 - } - p.Method__SWIG_2(a[0].(*bool)) - return - } -check_3: - if argc == 1 { - if _, ok := a[0].(*int16); !ok { - goto check_4 - } - p.Method__SWIG_3(a[0].(*int16)) - return - } -check_4: - if argc == 1 { - if _, ok := a[0].(OverloadedClass); !ok { - goto check_5 - } - p.Method__SWIG_4(a[0].(OverloadedClass)) - return - } -check_5: - if argc == 1 { - p.Method__SWIG_5(a[0].(OverloadedPointers)) - return - } - panic("No match for overloaded function call") -} - -var _wrap_OverloadedPointers_notover unsafe.Pointer - -func _swig_wrap_OverloadedPointers_notover(base SwigcptrOverloadedPointers, _ *int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_OverloadedPointers_notover, _swig_p) - return -} - -func (arg1 SwigcptrOverloadedPointers) Notover(arg2 *int) { - _swig_wrap_OverloadedPointers_notover(arg1, arg2) -} - -var _wrap_new_OverloadedPointers unsafe.Pointer - -func _swig_wrap_new_OverloadedPointers() (base SwigcptrOverloadedPointers) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_OverloadedPointers, _swig_p) - return -} - -func NewOverloadedPointers() (_swig_ret OverloadedPointers) { - return _swig_wrap_new_OverloadedPointers() -} - -type OverloadedPointers interface { - Swigcptr() uintptr - SwigIsOverloadedPointers() - DirectorInterface() interface{} - Method(a ...interface{}) - Notover(arg2 *int) -} - - -type SwigcptrSwigDirector_OverloadedPointers uintptr -type SwigDirector_OverloadedPointers interface { - Swigcptr() uintptr; -} -func (p SwigcptrSwigDirector_OverloadedPointers) Swigcptr() uintptr { - return uintptr(p) -} - -type SwigcptrSwigDirector_OverloadedClass uintptr -type SwigDirector_OverloadedClass interface { - Swigcptr() uintptr; -} -func (p SwigcptrSwigDirector_OverloadedClass) Swigcptr() uintptr { - return uintptr(p) -} - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/director_overload2.go b/Examples/test-suite/go/director_overload2.go deleted file mode 100644 index 183c02a7b..000000000 --- a/Examples/test-suite/go/director_overload2.go +++ /dev/null @@ -1,727 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../director_overload2.i - -package director_overload2 - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type _swig_DirectorOverloadBase struct { - SwigcptrOverloadBase - v interface{} -} - -func (p *_swig_DirectorOverloadBase) Swigcptr() uintptr { - return p.SwigcptrOverloadBase.Swigcptr() -} - -func (p *_swig_DirectorOverloadBase) SwigIsOverloadBase() { -} - -func (p *_swig_DirectorOverloadBase) DirectorInterface() interface{} { - return p.v -} - -var _wrap__swig_NewDirectorOverloadBaseOverloadBase unsafe.Pointer - -func _swig_NewDirectorOverloadBaseOverloadBase(_swig_director *_swig_DirectorOverloadBase) (_swig_ret SwigcptrOverloadBase) { - _swig_p := uintptr(unsafe.Pointer(&_swig_director)) - _cgo_runtime_cgocall(_wrap__swig_NewDirectorOverloadBaseOverloadBase, _swig_p) - return -} - -func NewDirectorOverloadBase(v interface{}) OverloadBase { - p := &_swig_DirectorOverloadBase{0, v} - p.SwigcptrOverloadBase = _swig_NewDirectorOverloadBaseOverloadBase(p) - return p -} - -var _wrap_DeleteDirectorOverloadBase unsafe.Pointer - -func _swig_wrap_DeleteDirectorOverloadBase(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_DeleteDirectorOverloadBase, _swig_p) - return -} - -func DeleteDirectorOverloadBase(arg1 OverloadBase) { - _swig_wrap_DeleteDirectorOverloadBase(arg1.Swigcptr()) -} - -func Swiggo_DeleteDirector_OverloadBase(p *_swig_DirectorOverloadBase) { - p.SwigcptrOverloadBase = 0 -} - -type _swig_DirectorInterfaceOverloadBaseMmm interface { - Mmm() -} - -var _wrap__swig_DirectorOverloadBase_upcall_Mmm unsafe.Pointer - -func _swig_wrap__swig_DirectorOverloadBase_upcall_Mmm(_swig_ptr SwigcptrOverloadBase) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) - _cgo_runtime_cgocall(_wrap__swig_DirectorOverloadBase_upcall_Mmm, _swig_p) - return -} - -func (swig_p *_swig_DirectorOverloadBase) Mmm() { - if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceOverloadBaseMmm); swig_ok { - swig_g.Mmm() - return - } - _swig_wrap__swig_DirectorOverloadBase_upcall_Mmm(swig_p.SwigcptrOverloadBase) -} - -func DirectorOverloadBaseMmm(p OverloadBase) { - _swig_wrap__swig_DirectorOverloadBase_upcall_Mmm(p.(*_swig_DirectorOverloadBase).SwigcptrOverloadBase) -} - -func Swig_DirectorOverloadBase_callback_mmm(p *_swig_DirectorOverloadBase) { - p.Mmm() -} - -type _swig_DirectorInterfaceOverloadBaseNnn__SWIG_0 interface { - Nnn__SWIG_0(int) -} - -var _wrap__swig_DirectorOverloadBase_upcall_Nnn__SWIG_0 unsafe.Pointer - -func _swig_wrap__swig_DirectorOverloadBase_upcall_Nnn__SWIG_0(_swig_ptr SwigcptrOverloadBase, _ int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) - _cgo_runtime_cgocall(_wrap__swig_DirectorOverloadBase_upcall_Nnn__SWIG_0, _swig_p) - return -} - -func (swig_p *_swig_DirectorOverloadBase) Nnn__SWIG_0(vvv int) { - if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceOverloadBaseNnn__SWIG_0); swig_ok { - swig_g.Nnn__SWIG_0(vvv) - return - } - _swig_wrap__swig_DirectorOverloadBase_upcall_Nnn__SWIG_0(swig_p.SwigcptrOverloadBase, vvv) -} - -func DirectorOverloadBaseNnn__SWIG_0(p OverloadBase, arg2 int) { - _swig_wrap__swig_DirectorOverloadBase_upcall_Nnn__SWIG_0(p.(*_swig_DirectorOverloadBase).SwigcptrOverloadBase, arg2) -} - -func Swig_DirectorOverloadBase_callback_nnn__SWIG_0(p *_swig_DirectorOverloadBase, arg2 int) { - p.Nnn__SWIG_0(arg2) -} - -type _swig_DirectorInterfaceOverloadBaseNnn__SWIG_1 interface { - Nnn__SWIG_1() -} - -var _wrap__swig_DirectorOverloadBase_upcall_Nnn__SWIG_1 unsafe.Pointer - -func _swig_wrap__swig_DirectorOverloadBase_upcall_Nnn__SWIG_1(_swig_ptr SwigcptrOverloadBase) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) - _cgo_runtime_cgocall(_wrap__swig_DirectorOverloadBase_upcall_Nnn__SWIG_1, _swig_p) - return -} - -func (swig_p *_swig_DirectorOverloadBase) Nnn__SWIG_1() { - if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceOverloadBaseNnn__SWIG_1); swig_ok { - swig_g.Nnn__SWIG_1() - return - } - _swig_wrap__swig_DirectorOverloadBase_upcall_Nnn__SWIG_1(swig_p.SwigcptrOverloadBase) -} - -func DirectorOverloadBaseNnn__SWIG_1(p OverloadBase) { - _swig_wrap__swig_DirectorOverloadBase_upcall_Nnn__SWIG_1(p.(*_swig_DirectorOverloadBase).SwigcptrOverloadBase) -} - -func Swig_DirectorOverloadBase_callback_nnn__SWIG_1(p *_swig_DirectorOverloadBase) { - p.Nnn__SWIG_1() -} - -func (p _swig_DirectorOverloadBase) Nnn(a ...interface{}) { - argc := len(a) - if argc == 0 { - p.Nnn__SWIG_1() - return - } - if argc == 1 { - p.Nnn__SWIG_0(a[0].(int)) - return - } - panic("No match for overloaded function call") -} - -func DirectorOverloadBaseNnn(p *_swig_DirectorOverloadBase, a ...interface{}) { - argc := len(a) - if argc == 0 { - DirectorOverloadBaseNnn__SWIG_1(p) - return - } - if argc == 1 { - DirectorOverloadBaseNnn__SWIG_0(p, a[0].(int)) - return - } - panic("No match for overloaded function call") -} - -type SwigcptrOverloadBase uintptr - -func (p SwigcptrOverloadBase) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrOverloadBase) SwigIsOverloadBase() { -} - -func (p SwigcptrOverloadBase) DirectorInterface() interface{} { - return nil -} - -var _wrap_delete_OverloadBase unsafe.Pointer - -func _swig_wrap_delete_OverloadBase(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_OverloadBase, _swig_p) - return -} - -func DeleteOverloadBase(arg1 OverloadBase) { - _swig_wrap_delete_OverloadBase(arg1.Swigcptr()) -} - -var _wrap_OverloadBase_mmm unsafe.Pointer - -func _swig_wrap_OverloadBase_mmm(base SwigcptrOverloadBase) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_OverloadBase_mmm, _swig_p) - return -} - -func (arg1 SwigcptrOverloadBase) Mmm() { - _swig_wrap_OverloadBase_mmm(arg1) -} - -var _wrap_OverloadBase_nnn__SWIG_0 unsafe.Pointer - -func _swig_wrap_OverloadBase_nnn__SWIG_0(base SwigcptrOverloadBase, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_OverloadBase_nnn__SWIG_0, _swig_p) - return -} - -func (arg1 SwigcptrOverloadBase) Nnn__SWIG_0(arg2 int) { - _swig_wrap_OverloadBase_nnn__SWIG_0(arg1, arg2) -} - -var _wrap_OverloadBase_nnn__SWIG_1 unsafe.Pointer - -func _swig_wrap_OverloadBase_nnn__SWIG_1(base SwigcptrOverloadBase) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_OverloadBase_nnn__SWIG_1, _swig_p) - return -} - -func (arg1 SwigcptrOverloadBase) Nnn__SWIG_1() { - _swig_wrap_OverloadBase_nnn__SWIG_1(arg1) -} - -func (p SwigcptrOverloadBase) Nnn(a ...interface{}) { - argc := len(a) - if argc == 0 { - p.Nnn__SWIG_1() - return - } - if argc == 1 { - p.Nnn__SWIG_0(a[0].(int)) - return - } - panic("No match for overloaded function call") -} - -var _wrap_new_OverloadBase unsafe.Pointer - -func _swig_wrap_new_OverloadBase() (base SwigcptrOverloadBase) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_OverloadBase, _swig_p) - return -} - -func NewOverloadBase() (_swig_ret OverloadBase) { - return _swig_wrap_new_OverloadBase() -} - -type OverloadBase interface { - Swigcptr() uintptr - SwigIsOverloadBase() - DirectorInterface() interface{} - Mmm() - Nnn(a ...interface{}) -} - -type _swig_DirectorOverloadDerived1 struct { - SwigcptrOverloadDerived1 - v interface{} -} - -func (p *_swig_DirectorOverloadDerived1) Swigcptr() uintptr { - return p.SwigcptrOverloadDerived1.Swigcptr() -} - -func (p *_swig_DirectorOverloadDerived1) SwigIsOverloadDerived1() { -} - -func (p *_swig_DirectorOverloadDerived1) DirectorInterface() interface{} { - return p.v -} - -var _wrap__swig_NewDirectorOverloadDerived1OverloadDerived1 unsafe.Pointer - -func _swig_NewDirectorOverloadDerived1OverloadDerived1(_swig_director *_swig_DirectorOverloadDerived1) (_swig_ret SwigcptrOverloadDerived1) { - _swig_p := uintptr(unsafe.Pointer(&_swig_director)) - _cgo_runtime_cgocall(_wrap__swig_NewDirectorOverloadDerived1OverloadDerived1, _swig_p) - return -} - -func NewDirectorOverloadDerived1(v interface{}) OverloadDerived1 { - p := &_swig_DirectorOverloadDerived1{0, v} - p.SwigcptrOverloadDerived1 = _swig_NewDirectorOverloadDerived1OverloadDerived1(p) - return p -} - -var _wrap_DeleteDirectorOverloadDerived1 unsafe.Pointer - -func _swig_wrap_DeleteDirectorOverloadDerived1(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_DeleteDirectorOverloadDerived1, _swig_p) - return -} - -func DeleteDirectorOverloadDerived1(arg1 OverloadDerived1) { - _swig_wrap_DeleteDirectorOverloadDerived1(arg1.Swigcptr()) -} - -func Swiggo_DeleteDirector_OverloadDerived1(p *_swig_DirectorOverloadDerived1) { - p.SwigcptrOverloadDerived1 = 0 -} - -type _swig_DirectorInterfaceOverloadDerived1Mmm interface { - Mmm() -} - -var _wrap__swig_DirectorOverloadDerived1_upcall_Mmm unsafe.Pointer - -func _swig_wrap__swig_DirectorOverloadDerived1_upcall_Mmm(_swig_ptr SwigcptrOverloadDerived1) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) - _cgo_runtime_cgocall(_wrap__swig_DirectorOverloadDerived1_upcall_Mmm, _swig_p) - return -} - -func (swig_p *_swig_DirectorOverloadDerived1) Mmm() { - if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceOverloadDerived1Mmm); swig_ok { - swig_g.Mmm() - return - } - _swig_wrap__swig_DirectorOverloadDerived1_upcall_Mmm(swig_p.SwigcptrOverloadDerived1) -} - -func DirectorOverloadDerived1Mmm(p OverloadDerived1) { - _swig_wrap__swig_DirectorOverloadDerived1_upcall_Mmm(p.(*_swig_DirectorOverloadDerived1).SwigcptrOverloadDerived1) -} - -func Swig_DirectorOverloadDerived1_callback_mmm(p *_swig_DirectorOverloadDerived1) { - p.Mmm() -} - -type _swig_DirectorInterfaceOverloadDerived1Nnn interface { - Nnn(int) -} - -var _wrap__swig_DirectorOverloadDerived1_upcall_Nnn unsafe.Pointer - -func _swig_wrap__swig_DirectorOverloadDerived1_upcall_Nnn(_swig_ptr SwigcptrOverloadDerived1, _ int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) - _cgo_runtime_cgocall(_wrap__swig_DirectorOverloadDerived1_upcall_Nnn, _swig_p) - return -} - -func (swig_p *_swig_DirectorOverloadDerived1) Nnn(vvv int) { - if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceOverloadDerived1Nnn); swig_ok { - swig_g.Nnn(vvv) - return - } - _swig_wrap__swig_DirectorOverloadDerived1_upcall_Nnn(swig_p.SwigcptrOverloadDerived1, vvv) -} - -func DirectorOverloadDerived1Nnn(p OverloadDerived1, arg2 int) { - _swig_wrap__swig_DirectorOverloadDerived1_upcall_Nnn(p.(*_swig_DirectorOverloadDerived1).SwigcptrOverloadDerived1, arg2) -} - -func Swig_DirectorOverloadDerived1_callback_nnn(p *_swig_DirectorOverloadDerived1, arg2 int) { - p.Nnn(arg2) -} - -type _swig_DirectorInterfaceOverloadDerived1Nnn__SWIG_1 interface { - Nnn__SWIG_1() -} - -var _wrap__swig_DirectorOverloadDerived1_upcall_Nnn__SWIG_1 unsafe.Pointer - -func _swig_wrap__swig_DirectorOverloadDerived1_upcall_Nnn__SWIG_1(_swig_ptr SwigcptrOverloadDerived1) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) - _cgo_runtime_cgocall(_wrap__swig_DirectorOverloadDerived1_upcall_Nnn__SWIG_1, _swig_p) - return -} - -func (swig_p *_swig_DirectorOverloadDerived1) Nnn__SWIG_1() { - if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceOverloadDerived1Nnn__SWIG_1); swig_ok { - swig_g.Nnn__SWIG_1() - return - } - _swig_wrap__swig_DirectorOverloadDerived1_upcall_Nnn__SWIG_1(swig_p.SwigcptrOverloadDerived1) -} - -func DirectorOverloadDerived1Nnn__SWIG_1(p OverloadDerived1) { - _swig_wrap__swig_DirectorOverloadDerived1_upcall_Nnn__SWIG_1(p.(*_swig_DirectorOverloadDerived1).SwigcptrOverloadDerived1) -} - -func Swig_DirectorOverloadDerived1_callback_nnn__SWIG_1(p *_swig_DirectorOverloadDerived1) { - p.Nnn__SWIG_1() -} - -type SwigcptrOverloadDerived1 uintptr - -func (p SwigcptrOverloadDerived1) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrOverloadDerived1) SwigIsOverloadDerived1() { -} - -func (p SwigcptrOverloadDerived1) DirectorInterface() interface{} { - return nil -} - -var _wrap_OverloadDerived1_nnn unsafe.Pointer - -func _swig_wrap_OverloadDerived1_nnn(base SwigcptrOverloadDerived1, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_OverloadDerived1_nnn, _swig_p) - return -} - -func (arg1 SwigcptrOverloadDerived1) Nnn(arg2 int) { - _swig_wrap_OverloadDerived1_nnn(arg1, arg2) -} - -var _wrap_new_OverloadDerived1 unsafe.Pointer - -func _swig_wrap_new_OverloadDerived1() (base SwigcptrOverloadDerived1) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_OverloadDerived1, _swig_p) - return -} - -func NewOverloadDerived1() (_swig_ret OverloadDerived1) { - return _swig_wrap_new_OverloadDerived1() -} - -var _wrap_delete_OverloadDerived1 unsafe.Pointer - -func _swig_wrap_delete_OverloadDerived1(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_OverloadDerived1, _swig_p) - return -} - -func DeleteOverloadDerived1(arg1 OverloadDerived1) { - _swig_wrap_delete_OverloadDerived1(arg1.Swigcptr()) -} - -var _wrap_OverloadDerived1_mmm unsafe.Pointer - -func _swig_wrap_OverloadDerived1_mmm(base SwigcptrOverloadDerived1) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_OverloadDerived1_mmm, _swig_p) - return -} - -func (_swig_base SwigcptrOverloadDerived1) Mmm() { - _swig_wrap_OverloadDerived1_mmm(_swig_base) -} - -func (p SwigcptrOverloadDerived1) SwigIsOverloadBase() { -} - -func (p SwigcptrOverloadDerived1) SwigGetOverloadBase() OverloadBase { - return SwigcptrOverloadBase(p.Swigcptr()) -} - -type OverloadDerived1 interface { - Swigcptr() uintptr - SwigIsOverloadDerived1() - DirectorInterface() interface{} - Nnn(arg2 int) - Mmm() - SwigIsOverloadBase() - SwigGetOverloadBase() OverloadBase -} - -type _swig_DirectorOverloadDerived2 struct { - SwigcptrOverloadDerived2 - v interface{} -} - -func (p *_swig_DirectorOverloadDerived2) Swigcptr() uintptr { - return p.SwigcptrOverloadDerived2.Swigcptr() -} - -func (p *_swig_DirectorOverloadDerived2) SwigIsOverloadDerived2() { -} - -func (p *_swig_DirectorOverloadDerived2) DirectorInterface() interface{} { - return p.v -} - -var _wrap__swig_NewDirectorOverloadDerived2OverloadDerived2 unsafe.Pointer - -func _swig_NewDirectorOverloadDerived2OverloadDerived2(_swig_director *_swig_DirectorOverloadDerived2) (_swig_ret SwigcptrOverloadDerived2) { - _swig_p := uintptr(unsafe.Pointer(&_swig_director)) - _cgo_runtime_cgocall(_wrap__swig_NewDirectorOverloadDerived2OverloadDerived2, _swig_p) - return -} - -func NewDirectorOverloadDerived2(v interface{}) OverloadDerived2 { - p := &_swig_DirectorOverloadDerived2{0, v} - p.SwigcptrOverloadDerived2 = _swig_NewDirectorOverloadDerived2OverloadDerived2(p) - return p -} - -var _wrap_DeleteDirectorOverloadDerived2 unsafe.Pointer - -func _swig_wrap_DeleteDirectorOverloadDerived2(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_DeleteDirectorOverloadDerived2, _swig_p) - return -} - -func DeleteDirectorOverloadDerived2(arg1 OverloadDerived2) { - _swig_wrap_DeleteDirectorOverloadDerived2(arg1.Swigcptr()) -} - -func Swiggo_DeleteDirector_OverloadDerived2(p *_swig_DirectorOverloadDerived2) { - p.SwigcptrOverloadDerived2 = 0 -} - -type _swig_DirectorInterfaceOverloadDerived2Mmm interface { - Mmm() -} - -var _wrap__swig_DirectorOverloadDerived2_upcall_Mmm unsafe.Pointer - -func _swig_wrap__swig_DirectorOverloadDerived2_upcall_Mmm(_swig_ptr SwigcptrOverloadDerived2) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) - _cgo_runtime_cgocall(_wrap__swig_DirectorOverloadDerived2_upcall_Mmm, _swig_p) - return -} - -func (swig_p *_swig_DirectorOverloadDerived2) Mmm() { - if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceOverloadDerived2Mmm); swig_ok { - swig_g.Mmm() - return - } - _swig_wrap__swig_DirectorOverloadDerived2_upcall_Mmm(swig_p.SwigcptrOverloadDerived2) -} - -func DirectorOverloadDerived2Mmm(p OverloadDerived2) { - _swig_wrap__swig_DirectorOverloadDerived2_upcall_Mmm(p.(*_swig_DirectorOverloadDerived2).SwigcptrOverloadDerived2) -} - -func Swig_DirectorOverloadDerived2_callback_mmm(p *_swig_DirectorOverloadDerived2) { - p.Mmm() -} - -type _swig_DirectorInterfaceOverloadDerived2Nnn__SWIG_0 interface { - Nnn__SWIG_0(int) -} - -var _wrap__swig_DirectorOverloadDerived2_upcall_Nnn__SWIG_0 unsafe.Pointer - -func _swig_wrap__swig_DirectorOverloadDerived2_upcall_Nnn__SWIG_0(_swig_ptr SwigcptrOverloadDerived2, _ int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) - _cgo_runtime_cgocall(_wrap__swig_DirectorOverloadDerived2_upcall_Nnn__SWIG_0, _swig_p) - return -} - -func (swig_p *_swig_DirectorOverloadDerived2) Nnn__SWIG_0(vvv int) { - if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceOverloadDerived2Nnn__SWIG_0); swig_ok { - swig_g.Nnn__SWIG_0(vvv) - return - } - _swig_wrap__swig_DirectorOverloadDerived2_upcall_Nnn__SWIG_0(swig_p.SwigcptrOverloadDerived2, vvv) -} - -func DirectorOverloadDerived2Nnn__SWIG_0(p OverloadDerived2, arg2 int) { - _swig_wrap__swig_DirectorOverloadDerived2_upcall_Nnn__SWIG_0(p.(*_swig_DirectorOverloadDerived2).SwigcptrOverloadDerived2, arg2) -} - -func Swig_DirectorOverloadDerived2_callback_nnn__SWIG_0(p *_swig_DirectorOverloadDerived2, arg2 int) { - p.Nnn__SWIG_0(arg2) -} - -type _swig_DirectorInterfaceOverloadDerived2Nnn interface { - Nnn() -} - -var _wrap__swig_DirectorOverloadDerived2_upcall_Nnn unsafe.Pointer - -func _swig_wrap__swig_DirectorOverloadDerived2_upcall_Nnn(_swig_ptr SwigcptrOverloadDerived2) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) - _cgo_runtime_cgocall(_wrap__swig_DirectorOverloadDerived2_upcall_Nnn, _swig_p) - return -} - -func (swig_p *_swig_DirectorOverloadDerived2) Nnn() { - if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceOverloadDerived2Nnn); swig_ok { - swig_g.Nnn() - return - } - _swig_wrap__swig_DirectorOverloadDerived2_upcall_Nnn(swig_p.SwigcptrOverloadDerived2) -} - -func DirectorOverloadDerived2Nnn(p OverloadDerived2) { - _swig_wrap__swig_DirectorOverloadDerived2_upcall_Nnn(p.(*_swig_DirectorOverloadDerived2).SwigcptrOverloadDerived2) -} - -func Swig_DirectorOverloadDerived2_callback_nnn(p *_swig_DirectorOverloadDerived2) { - p.Nnn() -} - -type SwigcptrOverloadDerived2 uintptr - -func (p SwigcptrOverloadDerived2) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrOverloadDerived2) SwigIsOverloadDerived2() { -} - -func (p SwigcptrOverloadDerived2) DirectorInterface() interface{} { - return nil -} - -var _wrap_OverloadDerived2_nnn unsafe.Pointer - -func _swig_wrap_OverloadDerived2_nnn(base SwigcptrOverloadDerived2) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_OverloadDerived2_nnn, _swig_p) - return -} - -func (arg1 SwigcptrOverloadDerived2) Nnn() { - _swig_wrap_OverloadDerived2_nnn(arg1) -} - -var _wrap_new_OverloadDerived2 unsafe.Pointer - -func _swig_wrap_new_OverloadDerived2() (base SwigcptrOverloadDerived2) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_OverloadDerived2, _swig_p) - return -} - -func NewOverloadDerived2() (_swig_ret OverloadDerived2) { - return _swig_wrap_new_OverloadDerived2() -} - -var _wrap_delete_OverloadDerived2 unsafe.Pointer - -func _swig_wrap_delete_OverloadDerived2(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_OverloadDerived2, _swig_p) - return -} - -func DeleteOverloadDerived2(arg1 OverloadDerived2) { - _swig_wrap_delete_OverloadDerived2(arg1.Swigcptr()) -} - -var _wrap_OverloadDerived2_mmm unsafe.Pointer - -func _swig_wrap_OverloadDerived2_mmm(base SwigcptrOverloadDerived2) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_OverloadDerived2_mmm, _swig_p) - return -} - -func (_swig_base SwigcptrOverloadDerived2) Mmm() { - _swig_wrap_OverloadDerived2_mmm(_swig_base) -} - -func (p SwigcptrOverloadDerived2) SwigIsOverloadBase() { -} - -func (p SwigcptrOverloadDerived2) SwigGetOverloadBase() OverloadBase { - return SwigcptrOverloadBase(p.Swigcptr()) -} - -type OverloadDerived2 interface { - Swigcptr() uintptr - SwigIsOverloadDerived2() - DirectorInterface() interface{} - Nnn() - Mmm() - SwigIsOverloadBase() - SwigGetOverloadBase() OverloadBase -} - - -type SwigcptrSwigDirector_OverloadDerived1 uintptr -type SwigDirector_OverloadDerived1 interface { - Swigcptr() uintptr; -} -func (p SwigcptrSwigDirector_OverloadDerived1) Swigcptr() uintptr { - return uintptr(p) -} - -type SwigcptrSwigDirector_OverloadDerived2 uintptr -type SwigDirector_OverloadDerived2 interface { - Swigcptr() uintptr; -} -func (p SwigcptrSwigDirector_OverloadDerived2) Swigcptr() uintptr { - return uintptr(p) -} - -type SwigcptrSwigDirector_OverloadBase uintptr -type SwigDirector_OverloadBase interface { - Swigcptr() uintptr; -} -func (p SwigcptrSwigDirector_OverloadBase) Swigcptr() uintptr { - return uintptr(p) -} - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/director_overload2_wrap.h b/Examples/test-suite/go/director_overload2_wrap.h deleted file mode 100644 index d1b97521e..000000000 --- a/Examples/test-suite/go/director_overload2_wrap.h +++ /dev/null @@ -1,79 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../director_overload2.i - -#ifndef SWIG_director_overload2_WRAP_H_ -#define SWIG_director_overload2_WRAP_H_ - -class SwigDirector_OverloadBase : public OverloadBase -{ - public: - SwigDirector_OverloadBase(void *swig_p); - virtual ~SwigDirector_OverloadBase(); - void _swig_upcall_mmm() { - OverloadBase::mmm(); - } - virtual void mmm(); - void _swig_upcall_nnn__SWIG_0(int vvv) { - OverloadBase::nnn(vvv); - } - virtual void nnn(int vvv); - void _swig_upcall_nnn__SWIG_1() { - OverloadBase::nnn(); - } - virtual void nnn(); - private: - void *go_val; -}; - -class SwigDirector_OverloadDerived1 : public OverloadDerived1 -{ - public: - SwigDirector_OverloadDerived1(void *swig_p); - virtual ~SwigDirector_OverloadDerived1(); - void _swig_upcall_mmm() { - OverloadBase::mmm(); - } - virtual void mmm(); - void _swig_upcall_nnn(int vvv) { - OverloadDerived1::nnn(vvv); - } - virtual void nnn(int vvv); - void _swig_upcall_nnn__SWIG_1() { - OverloadBase::nnn(); - } - virtual void nnn(); - private: - void *go_val; -}; - -class SwigDirector_OverloadDerived2 : public OverloadDerived2 -{ - public: - SwigDirector_OverloadDerived2(void *swig_p); - virtual ~SwigDirector_OverloadDerived2(); - void _swig_upcall_mmm() { - OverloadBase::mmm(); - } - virtual void mmm(); - void _swig_upcall_nnn__SWIG_0(int vvv) { - OverloadBase::nnn(vvv); - } - virtual void nnn(int vvv); - void _swig_upcall_nnn() { - OverloadDerived2::nnn(); - } - virtual void nnn(); - private: - void *go_val; -}; - -#endif diff --git a/Examples/test-suite/go/director_overload_wrap.h b/Examples/test-suite/go/director_overload_wrap.h deleted file mode 100644 index 19c96dd53..000000000 --- a/Examples/test-suite/go/director_overload_wrap.h +++ /dev/null @@ -1,78 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../director_overload.i - -#ifndef SWIG_director_overload_WRAP_H_ -#define SWIG_director_overload_WRAP_H_ - -class SwigDirector_OverloadedClass : public OverloadedClass -{ - public: - SwigDirector_OverloadedClass(void *swig_p); - virtual ~SwigDirector_OverloadedClass(); - void _swig_upcall_method1() const { - OverloadedClass::method1(); - } - virtual void method1() const; - void _swig_upcall_method2__SWIG_0() const { - OverloadedClass::method2(); - } - virtual void method2() const; - void _swig_upcall_method3() const { - OverloadedClass::method3(); - } - virtual void method3() const; - void _swig_upcall_method2__SWIG_1(bool b) const { - OverloadedClass::method2(b); - } - virtual void method2(bool b) const; - private: - void *go_val; -}; - -class SwigDirector_OverloadedPointers : public OverloadedPointers -{ - public: - SwigDirector_OverloadedPointers(void *swig_p); - virtual ~SwigDirector_OverloadedPointers(); - void _swig_upcall_method__SWIG_0(int *p) const { - OverloadedPointers::method(p); - } - virtual void method(int *p) const; - void _swig_upcall_method__SWIG_1(double *p) const { - OverloadedPointers::method(p); - } - virtual void method(double *p) const; - void _swig_upcall_method__SWIG_2(bool &r) const { - OverloadedPointers::method(r); - } - virtual void method(bool &r) const; - void _swig_upcall_method__SWIG_3(short &r) const { - OverloadedPointers::method(r); - } - virtual void method(short &r) const; - void _swig_upcall_method__SWIG_4(OverloadedClass *p) const { - OverloadedPointers::method(p); - } - virtual void method(OverloadedClass *p) const; - void _swig_upcall_method__SWIG_5(OverloadedPointers *p) const { - OverloadedPointers::method(p); - } - virtual void method(OverloadedPointers *p) const; - void _swig_upcall_notover(int *p) const { - OverloadedPointers::notover(p); - } - virtual void notover(int *p) const; - private: - void *go_val; -}; - -#endif diff --git a/Examples/test-suite/go/director_primitives.go b/Examples/test-suite/go/director_primitives.go deleted file mode 100644 index a9a566452..000000000 --- a/Examples/test-suite/go/director_primitives.go +++ /dev/null @@ -1,1368 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../director_primitives.i - -package director_primitives - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -var _wrap_PrintDebug_set unsafe.Pointer - -func _swig_wrap_PrintDebug_set(base bool) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_PrintDebug_set, _swig_p) - return -} - -func SetPrintDebug(arg1 bool) { - _swig_wrap_PrintDebug_set(arg1) -} - -var _wrap_PrintDebug_get unsafe.Pointer - -func GetPrintDebug() (_swig_ret bool) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_PrintDebug_get, _swig_p) - return -} -type HShadowMode int -var _wrap_HShadowNone unsafe.Pointer - -func _swig_getHShadowNone() (_swig_ret HShadowMode) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_HShadowNone, _swig_p) - return -} -var HShadowNone HShadowMode = _swig_getHShadowNone() -var _wrap_HShadowSoft unsafe.Pointer - -func _swig_getHShadowSoft() (_swig_ret HShadowMode) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_HShadowSoft, _swig_p) - return -} -var HShadowSoft HShadowMode = _swig_getHShadowSoft() -var _wrap_HShadowHard unsafe.Pointer - -func _swig_getHShadowHard() (_swig_ret HShadowMode) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_HShadowHard, _swig_p) - return -} -var HShadowHard HShadowMode = _swig_getHShadowHard() -type _swig_DirectorBase struct { - SwigcptrBase - v interface{} -} - -func (p *_swig_DirectorBase) Swigcptr() uintptr { - return p.SwigcptrBase.Swigcptr() -} - -func (p *_swig_DirectorBase) SwigIsBase() { -} - -func (p *_swig_DirectorBase) DirectorInterface() interface{} { - return p.v -} - -var _wrap__swig_NewDirectorBaseBase unsafe.Pointer - -func _swig_NewDirectorBaseBase(_swig_director *_swig_DirectorBase, _ float64) (_swig_ret SwigcptrBase) { - _swig_p := uintptr(unsafe.Pointer(&_swig_director)) - _cgo_runtime_cgocall(_wrap__swig_NewDirectorBaseBase, _swig_p) - return -} - -func NewDirectorBase(v interface{}, arg1 float64) Base { - p := &_swig_DirectorBase{0, v} - p.SwigcptrBase = _swig_NewDirectorBaseBase(p, arg1) - return p -} - -var _wrap_DeleteDirectorBase unsafe.Pointer - -func _swig_wrap_DeleteDirectorBase(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_DeleteDirectorBase, _swig_p) - return -} - -func DeleteDirectorBase(arg1 Base) { - _swig_wrap_DeleteDirectorBase(arg1.Swigcptr()) -} - -func Swiggo_DeleteDirector_Base(p *_swig_DirectorBase) { - p.SwigcptrBase = 0 -} - -type _swig_DirectorInterfaceBaseNoParmsMethod interface { - NoParmsMethod() -} - -var _wrap__swig_DirectorBase_upcall_NoParmsMethod unsafe.Pointer - -func _swig_wrap__swig_DirectorBase_upcall_NoParmsMethod(_swig_ptr SwigcptrBase) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) - _cgo_runtime_cgocall(_wrap__swig_DirectorBase_upcall_NoParmsMethod, _swig_p) - return -} - -func (swig_p *_swig_DirectorBase) NoParmsMethod() { - if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceBaseNoParmsMethod); swig_ok { - swig_g.NoParmsMethod() - return - } - _swig_wrap__swig_DirectorBase_upcall_NoParmsMethod(swig_p.SwigcptrBase) -} - -func DirectorBaseNoParmsMethod(p Base) { - _swig_wrap__swig_DirectorBase_upcall_NoParmsMethod(p.(*_swig_DirectorBase).SwigcptrBase) -} - -func Swig_DirectorBase_callback_NoParmsMethod(p *_swig_DirectorBase) { - p.NoParmsMethod() -} - -type _swig_DirectorInterfaceBaseBoolMethod interface { - BoolMethod(bool) bool -} - -var _wrap__swig_DirectorBase_upcall_BoolMethod unsafe.Pointer - -func _swig_wrap__swig_DirectorBase_upcall_BoolMethod(_swig_ptr SwigcptrBase, _ bool) (_swig_ret bool) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) - _cgo_runtime_cgocall(_wrap__swig_DirectorBase_upcall_BoolMethod, _swig_p) - return -} - -func (swig_p *_swig_DirectorBase) BoolMethod(x bool) bool { - if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceBaseBoolMethod); swig_ok { - return swig_g.BoolMethod(x) - } - var swig_r bool - swig_r = _swig_wrap__swig_DirectorBase_upcall_BoolMethod(swig_p.SwigcptrBase, x) - return swig_r -} - -func DirectorBaseBoolMethod(p Base, arg2 bool) bool { - var swig_r bool - swig_r = _swig_wrap__swig_DirectorBase_upcall_BoolMethod(p.(*_swig_DirectorBase).SwigcptrBase, arg2) - return swig_r -} - -func Swig_DirectorBase_callback_BoolMethod(p *_swig_DirectorBase, arg2 bool) (swig_result bool) { - var swig_r bool - swig_r = p.BoolMethod(arg2) - return swig_r -} - -type _swig_DirectorInterfaceBaseIntMethod interface { - IntMethod(int) int -} - -var _wrap__swig_DirectorBase_upcall_IntMethod unsafe.Pointer - -func _swig_wrap__swig_DirectorBase_upcall_IntMethod(_swig_ptr SwigcptrBase, _ int) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) - _cgo_runtime_cgocall(_wrap__swig_DirectorBase_upcall_IntMethod, _swig_p) - return -} - -func (swig_p *_swig_DirectorBase) IntMethod(x int) int { - if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceBaseIntMethod); swig_ok { - return swig_g.IntMethod(x) - } - var swig_r int - swig_r = _swig_wrap__swig_DirectorBase_upcall_IntMethod(swig_p.SwigcptrBase, x) - return swig_r -} - -func DirectorBaseIntMethod(p Base, arg2 int) int { - var swig_r int - swig_r = _swig_wrap__swig_DirectorBase_upcall_IntMethod(p.(*_swig_DirectorBase).SwigcptrBase, arg2) - return swig_r -} - -func Swig_DirectorBase_callback_IntMethod(p *_swig_DirectorBase, arg2 int) (swig_result int) { - var swig_r int - swig_r = p.IntMethod(arg2) - return swig_r -} - -type _swig_DirectorInterfaceBaseUIntMethod interface { - UIntMethod(uint) uint -} - -var _wrap__swig_DirectorBase_upcall_UIntMethod unsafe.Pointer - -func _swig_wrap__swig_DirectorBase_upcall_UIntMethod(_swig_ptr SwigcptrBase, _ uint) (_swig_ret uint) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) - _cgo_runtime_cgocall(_wrap__swig_DirectorBase_upcall_UIntMethod, _swig_p) - return -} - -func (swig_p *_swig_DirectorBase) UIntMethod(x uint) uint { - if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceBaseUIntMethod); swig_ok { - return swig_g.UIntMethod(x) - } - var swig_r uint - swig_r = _swig_wrap__swig_DirectorBase_upcall_UIntMethod(swig_p.SwigcptrBase, x) - return swig_r -} - -func DirectorBaseUIntMethod(p Base, arg2 uint) uint { - var swig_r uint - swig_r = _swig_wrap__swig_DirectorBase_upcall_UIntMethod(p.(*_swig_DirectorBase).SwigcptrBase, arg2) - return swig_r -} - -func Swig_DirectorBase_callback_UIntMethod(p *_swig_DirectorBase, arg2 uint) (swig_result uint) { - var swig_r uint - swig_r = p.UIntMethod(arg2) - return swig_r -} - -type _swig_DirectorInterfaceBaseFloatMethod interface { - FloatMethod(float32) float32 -} - -var _wrap__swig_DirectorBase_upcall_FloatMethod unsafe.Pointer - -func _swig_wrap__swig_DirectorBase_upcall_FloatMethod(_swig_ptr SwigcptrBase, _ float32) (_swig_ret float32) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) - _cgo_runtime_cgocall(_wrap__swig_DirectorBase_upcall_FloatMethod, _swig_p) - return -} - -func (swig_p *_swig_DirectorBase) FloatMethod(x float32) float32 { - if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceBaseFloatMethod); swig_ok { - return swig_g.FloatMethod(x) - } - var swig_r float32 - swig_r = _swig_wrap__swig_DirectorBase_upcall_FloatMethod(swig_p.SwigcptrBase, x) - return swig_r -} - -func DirectorBaseFloatMethod(p Base, arg2 float32) float32 { - var swig_r float32 - swig_r = _swig_wrap__swig_DirectorBase_upcall_FloatMethod(p.(*_swig_DirectorBase).SwigcptrBase, arg2) - return swig_r -} - -func Swig_DirectorBase_callback_FloatMethod(p *_swig_DirectorBase, arg2 float32) (swig_result float32) { - var swig_r float32 - swig_r = p.FloatMethod(arg2) - return swig_r -} - -type _swig_DirectorInterfaceBaseCharPtrMethod interface { - CharPtrMethod(string) string -} - -var _wrap__swig_DirectorBase_upcall_CharPtrMethod unsafe.Pointer - -func _swig_wrap__swig_DirectorBase_upcall_CharPtrMethod(_swig_ptr SwigcptrBase, _ string) (_swig_ret string) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) - _cgo_runtime_cgocall(_wrap__swig_DirectorBase_upcall_CharPtrMethod, _swig_p) - return -} - -func (swig_p *_swig_DirectorBase) CharPtrMethod(x string) string { - if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceBaseCharPtrMethod); swig_ok { - return swig_g.CharPtrMethod(x) - } - var swig_r string - swig_r = _swig_wrap__swig_DirectorBase_upcall_CharPtrMethod(swig_p.SwigcptrBase, x) - return swig_r -} - -func DirectorBaseCharPtrMethod(p Base, arg2 string) string { - var swig_r string - swig_r = _swig_wrap__swig_DirectorBase_upcall_CharPtrMethod(p.(*_swig_DirectorBase).SwigcptrBase, arg2) - return swig_r -} - -func Swig_DirectorBase_callback_CharPtrMethod(p *_swig_DirectorBase, arg2 string) (swig_result string) { - var swig_r string - swig_r = p.CharPtrMethod(arg2) - return swig_r -} - -type _swig_DirectorInterfaceBaseConstCharPtrMethod interface { - ConstCharPtrMethod(string) string -} - -var _wrap__swig_DirectorBase_upcall_ConstCharPtrMethod unsafe.Pointer - -func _swig_wrap__swig_DirectorBase_upcall_ConstCharPtrMethod(_swig_ptr SwigcptrBase, _ string) (_swig_ret string) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) - _cgo_runtime_cgocall(_wrap__swig_DirectorBase_upcall_ConstCharPtrMethod, _swig_p) - return -} - -func (swig_p *_swig_DirectorBase) ConstCharPtrMethod(x string) string { - if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceBaseConstCharPtrMethod); swig_ok { - return swig_g.ConstCharPtrMethod(x) - } - var swig_r string - swig_r = _swig_wrap__swig_DirectorBase_upcall_ConstCharPtrMethod(swig_p.SwigcptrBase, x) - return swig_r -} - -func DirectorBaseConstCharPtrMethod(p Base, arg2 string) string { - var swig_r string - swig_r = _swig_wrap__swig_DirectorBase_upcall_ConstCharPtrMethod(p.(*_swig_DirectorBase).SwigcptrBase, arg2) - return swig_r -} - -func Swig_DirectorBase_callback_ConstCharPtrMethod(p *_swig_DirectorBase, arg2 string) (swig_result string) { - var swig_r string - swig_r = p.ConstCharPtrMethod(arg2) - return swig_r -} - -type _swig_DirectorInterfaceBaseEnumMethod interface { - EnumMethod(HShadowMode) HShadowMode -} - -var _wrap__swig_DirectorBase_upcall_EnumMethod unsafe.Pointer - -func _swig_wrap__swig_DirectorBase_upcall_EnumMethod(_swig_ptr SwigcptrBase, _ HShadowMode) (_swig_ret HShadowMode) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) - _cgo_runtime_cgocall(_wrap__swig_DirectorBase_upcall_EnumMethod, _swig_p) - return -} - -func (swig_p *_swig_DirectorBase) EnumMethod(x HShadowMode) HShadowMode { - if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceBaseEnumMethod); swig_ok { - return swig_g.EnumMethod(x) - } - var swig_r HShadowMode - swig_r = _swig_wrap__swig_DirectorBase_upcall_EnumMethod(swig_p.SwigcptrBase, x) - return swig_r -} - -func DirectorBaseEnumMethod(p Base, arg2 HShadowMode) HShadowMode { - var swig_r HShadowMode - swig_r = _swig_wrap__swig_DirectorBase_upcall_EnumMethod(p.(*_swig_DirectorBase).SwigcptrBase, arg2) - return swig_r -} - -func Swig_DirectorBase_callback_EnumMethod(p *_swig_DirectorBase, arg2 HShadowMode) (swig_result HShadowMode) { - var swig_r HShadowMode - swig_r = p.EnumMethod(arg2) - return swig_r -} - -type _swig_DirectorInterfaceBaseManyParmsMethod interface { - ManyParmsMethod(bool, int, uint, float32, string, string, HShadowMode) -} - -var _wrap__swig_DirectorBase_upcall_ManyParmsMethod unsafe.Pointer - -func _swig_wrap__swig_DirectorBase_upcall_ManyParmsMethod(_swig_ptr SwigcptrBase, _ bool, _ int, _ uint, _ float32, _ string, _ string, _ HShadowMode) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) - _cgo_runtime_cgocall(_wrap__swig_DirectorBase_upcall_ManyParmsMethod, _swig_p) - return -} - -func (swig_p *_swig_DirectorBase) ManyParmsMethod(b bool, i int, u uint, f float32, c string, cc string, h HShadowMode) { - if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceBaseManyParmsMethod); swig_ok { - swig_g.ManyParmsMethod(b, i, u, f, c, cc, h) - return - } - _swig_wrap__swig_DirectorBase_upcall_ManyParmsMethod(swig_p.SwigcptrBase, b, i, u, f, c, cc, h) -} - -func DirectorBaseManyParmsMethod(p Base, arg2 bool, arg3 int, arg4 uint, arg5 float32, arg6 string, arg7 string, arg8 HShadowMode) { - _swig_wrap__swig_DirectorBase_upcall_ManyParmsMethod(p.(*_swig_DirectorBase).SwigcptrBase, arg2, arg3, arg4, arg5, arg6, arg7, arg8) -} - -func Swig_DirectorBase_callback_ManyParmsMethod(p *_swig_DirectorBase, arg2 bool, arg3 int, arg4 uint, arg5 float32, arg6 string, arg7 string, arg8 HShadowMode) { - p.ManyParmsMethod(arg2, arg3, arg4, arg5, arg6, arg7, arg8) -} - -type _swig_DirectorInterfaceBaseNotOverriddenMethod interface { - NotOverriddenMethod() -} - -var _wrap__swig_DirectorBase_upcall_NotOverriddenMethod unsafe.Pointer - -func _swig_wrap__swig_DirectorBase_upcall_NotOverriddenMethod(_swig_ptr SwigcptrBase) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) - _cgo_runtime_cgocall(_wrap__swig_DirectorBase_upcall_NotOverriddenMethod, _swig_p) - return -} - -func (swig_p *_swig_DirectorBase) NotOverriddenMethod() { - if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceBaseNotOverriddenMethod); swig_ok { - swig_g.NotOverriddenMethod() - return - } - _swig_wrap__swig_DirectorBase_upcall_NotOverriddenMethod(swig_p.SwigcptrBase) -} - -func DirectorBaseNotOverriddenMethod(p Base) { - _swig_wrap__swig_DirectorBase_upcall_NotOverriddenMethod(p.(*_swig_DirectorBase).SwigcptrBase) -} - -func Swig_DirectorBase_callback_NotOverriddenMethod(p *_swig_DirectorBase) { - p.NotOverriddenMethod() -} - -type SwigcptrBase uintptr - -func (p SwigcptrBase) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrBase) SwigIsBase() { -} - -func (p SwigcptrBase) DirectorInterface() interface{} { - return nil -} - -var _wrap_new_Base unsafe.Pointer - -func _swig_wrap_new_Base(base float64) (_ SwigcptrBase) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Base, _swig_p) - return -} - -func NewBase(arg1 float64) (_swig_ret Base) { - return _swig_wrap_new_Base(arg1) -} - -var _wrap_delete_Base unsafe.Pointer - -func _swig_wrap_delete_Base(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Base, _swig_p) - return -} - -func DeleteBase(arg1 Base) { - _swig_wrap_delete_Base(arg1.Swigcptr()) -} - -var _wrap_Base_NoParmsMethod unsafe.Pointer - -func _swig_wrap_Base_NoParmsMethod(base SwigcptrBase) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Base_NoParmsMethod, _swig_p) - return -} - -func (arg1 SwigcptrBase) NoParmsMethod() { - _swig_wrap_Base_NoParmsMethod(arg1) -} - -var _wrap_Base_BoolMethod unsafe.Pointer - -func _swig_wrap_Base_BoolMethod(base SwigcptrBase, _ bool) (_ bool) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Base_BoolMethod, _swig_p) - return -} - -func (arg1 SwigcptrBase) BoolMethod(arg2 bool) (_swig_ret bool) { - return _swig_wrap_Base_BoolMethod(arg1, arg2) -} - -var _wrap_Base_IntMethod unsafe.Pointer - -func _swig_wrap_Base_IntMethod(base SwigcptrBase, _ int) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Base_IntMethod, _swig_p) - return -} - -func (arg1 SwigcptrBase) IntMethod(arg2 int) (_swig_ret int) { - return _swig_wrap_Base_IntMethod(arg1, arg2) -} - -var _wrap_Base_UIntMethod unsafe.Pointer - -func _swig_wrap_Base_UIntMethod(base SwigcptrBase, _ uint) (_ uint) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Base_UIntMethod, _swig_p) - return -} - -func (arg1 SwigcptrBase) UIntMethod(arg2 uint) (_swig_ret uint) { - return _swig_wrap_Base_UIntMethod(arg1, arg2) -} - -var _wrap_Base_FloatMethod unsafe.Pointer - -func _swig_wrap_Base_FloatMethod(base SwigcptrBase, _ float32) (_ float32) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Base_FloatMethod, _swig_p) - return -} - -func (arg1 SwigcptrBase) FloatMethod(arg2 float32) (_swig_ret float32) { - return _swig_wrap_Base_FloatMethod(arg1, arg2) -} - -var _wrap_Base_CharPtrMethod unsafe.Pointer - -func _swig_wrap_Base_CharPtrMethod(base SwigcptrBase, _ string) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Base_CharPtrMethod, _swig_p) - return -} - -func (arg1 SwigcptrBase) CharPtrMethod(arg2 string) (_swig_ret string) { - return _swig_wrap_Base_CharPtrMethod(arg1, arg2) -} - -var _wrap_Base_ConstCharPtrMethod unsafe.Pointer - -func _swig_wrap_Base_ConstCharPtrMethod(base SwigcptrBase, _ string) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Base_ConstCharPtrMethod, _swig_p) - return -} - -func (arg1 SwigcptrBase) ConstCharPtrMethod(arg2 string) (_swig_ret string) { - return _swig_wrap_Base_ConstCharPtrMethod(arg1, arg2) -} - -var _wrap_Base_EnumMethod unsafe.Pointer - -func _swig_wrap_Base_EnumMethod(base SwigcptrBase, _ HShadowMode) (_ HShadowMode) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Base_EnumMethod, _swig_p) - return -} - -func (arg1 SwigcptrBase) EnumMethod(arg2 HShadowMode) (_swig_ret HShadowMode) { - return _swig_wrap_Base_EnumMethod(arg1, arg2) -} - -var _wrap_Base_ManyParmsMethod unsafe.Pointer - -func _swig_wrap_Base_ManyParmsMethod(base SwigcptrBase, _ bool, _ int, _ uint, _ float32, _ string, _ string, _ HShadowMode) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Base_ManyParmsMethod, _swig_p) - return -} - -func (arg1 SwigcptrBase) ManyParmsMethod(arg2 bool, arg3 int, arg4 uint, arg5 float32, arg6 string, arg7 string, arg8 HShadowMode) { - _swig_wrap_Base_ManyParmsMethod(arg1, arg2, arg3, arg4, arg5, arg6, arg7, arg8) -} - -var _wrap_Base_NotOverriddenMethod unsafe.Pointer - -func _swig_wrap_Base_NotOverriddenMethod(base SwigcptrBase) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Base_NotOverriddenMethod, _swig_p) - return -} - -func (arg1 SwigcptrBase) NotOverriddenMethod() { - _swig_wrap_Base_NotOverriddenMethod(arg1) -} - -type Base interface { - Swigcptr() uintptr - SwigIsBase() - DirectorInterface() interface{} - NoParmsMethod() - BoolMethod(arg2 bool) (_swig_ret bool) - IntMethod(arg2 int) (_swig_ret int) - UIntMethod(arg2 uint) (_swig_ret uint) - FloatMethod(arg2 float32) (_swig_ret float32) - CharPtrMethod(arg2 string) (_swig_ret string) - ConstCharPtrMethod(arg2 string) (_swig_ret string) - EnumMethod(arg2 HShadowMode) (_swig_ret HShadowMode) - ManyParmsMethod(arg2 bool, arg3 int, arg4 uint, arg5 float32, arg6 string, arg7 string, arg8 HShadowMode) - NotOverriddenMethod() -} - -type _swig_DirectorDerived struct { - SwigcptrDerived - v interface{} -} - -func (p *_swig_DirectorDerived) Swigcptr() uintptr { - return p.SwigcptrDerived.Swigcptr() -} - -func (p *_swig_DirectorDerived) SwigIsDerived() { -} - -func (p *_swig_DirectorDerived) DirectorInterface() interface{} { - return p.v -} - -var _wrap__swig_NewDirectorDerivedDerived unsafe.Pointer - -func _swig_NewDirectorDerivedDerived(_swig_director *_swig_DirectorDerived, _ float64) (_swig_ret SwigcptrDerived) { - _swig_p := uintptr(unsafe.Pointer(&_swig_director)) - _cgo_runtime_cgocall(_wrap__swig_NewDirectorDerivedDerived, _swig_p) - return -} - -func NewDirectorDerived(v interface{}, arg1 float64) Derived { - p := &_swig_DirectorDerived{0, v} - p.SwigcptrDerived = _swig_NewDirectorDerivedDerived(p, arg1) - return p -} - -var _wrap_DeleteDirectorDerived unsafe.Pointer - -func _swig_wrap_DeleteDirectorDerived(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_DeleteDirectorDerived, _swig_p) - return -} - -func DeleteDirectorDerived(arg1 Derived) { - _swig_wrap_DeleteDirectorDerived(arg1.Swigcptr()) -} - -func Swiggo_DeleteDirector_Derived(p *_swig_DirectorDerived) { - p.SwigcptrDerived = 0 -} - -type _swig_DirectorInterfaceDerivedNoParmsMethod interface { - NoParmsMethod() -} - -var _wrap__swig_DirectorDerived_upcall_NoParmsMethod unsafe.Pointer - -func _swig_wrap__swig_DirectorDerived_upcall_NoParmsMethod(_swig_ptr SwigcptrDerived) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) - _cgo_runtime_cgocall(_wrap__swig_DirectorDerived_upcall_NoParmsMethod, _swig_p) - return -} - -func (swig_p *_swig_DirectorDerived) NoParmsMethod() { - if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceDerivedNoParmsMethod); swig_ok { - swig_g.NoParmsMethod() - return - } - _swig_wrap__swig_DirectorDerived_upcall_NoParmsMethod(swig_p.SwigcptrDerived) -} - -func DirectorDerivedNoParmsMethod(p Derived) { - _swig_wrap__swig_DirectorDerived_upcall_NoParmsMethod(p.(*_swig_DirectorDerived).SwigcptrDerived) -} - -func Swig_DirectorDerived_callback_NoParmsMethod(p *_swig_DirectorDerived) { - p.NoParmsMethod() -} - -type _swig_DirectorInterfaceDerivedBoolMethod interface { - BoolMethod(bool) bool -} - -var _wrap__swig_DirectorDerived_upcall_BoolMethod unsafe.Pointer - -func _swig_wrap__swig_DirectorDerived_upcall_BoolMethod(_swig_ptr SwigcptrDerived, _ bool) (_swig_ret bool) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) - _cgo_runtime_cgocall(_wrap__swig_DirectorDerived_upcall_BoolMethod, _swig_p) - return -} - -func (swig_p *_swig_DirectorDerived) BoolMethod(x bool) bool { - if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceDerivedBoolMethod); swig_ok { - return swig_g.BoolMethod(x) - } - var swig_r bool - swig_r = _swig_wrap__swig_DirectorDerived_upcall_BoolMethod(swig_p.SwigcptrDerived, x) - return swig_r -} - -func DirectorDerivedBoolMethod(p Derived, arg2 bool) bool { - var swig_r bool - swig_r = _swig_wrap__swig_DirectorDerived_upcall_BoolMethod(p.(*_swig_DirectorDerived).SwigcptrDerived, arg2) - return swig_r -} - -func Swig_DirectorDerived_callback_BoolMethod(p *_swig_DirectorDerived, arg2 bool) (swig_result bool) { - var swig_r bool - swig_r = p.BoolMethod(arg2) - return swig_r -} - -type _swig_DirectorInterfaceDerivedIntMethod interface { - IntMethod(int) int -} - -var _wrap__swig_DirectorDerived_upcall_IntMethod unsafe.Pointer - -func _swig_wrap__swig_DirectorDerived_upcall_IntMethod(_swig_ptr SwigcptrDerived, _ int) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) - _cgo_runtime_cgocall(_wrap__swig_DirectorDerived_upcall_IntMethod, _swig_p) - return -} - -func (swig_p *_swig_DirectorDerived) IntMethod(x int) int { - if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceDerivedIntMethod); swig_ok { - return swig_g.IntMethod(x) - } - var swig_r int - swig_r = _swig_wrap__swig_DirectorDerived_upcall_IntMethod(swig_p.SwigcptrDerived, x) - return swig_r -} - -func DirectorDerivedIntMethod(p Derived, arg2 int) int { - var swig_r int - swig_r = _swig_wrap__swig_DirectorDerived_upcall_IntMethod(p.(*_swig_DirectorDerived).SwigcptrDerived, arg2) - return swig_r -} - -func Swig_DirectorDerived_callback_IntMethod(p *_swig_DirectorDerived, arg2 int) (swig_result int) { - var swig_r int - swig_r = p.IntMethod(arg2) - return swig_r -} - -type _swig_DirectorInterfaceDerivedUIntMethod interface { - UIntMethod(uint) uint -} - -var _wrap__swig_DirectorDerived_upcall_UIntMethod unsafe.Pointer - -func _swig_wrap__swig_DirectorDerived_upcall_UIntMethod(_swig_ptr SwigcptrDerived, _ uint) (_swig_ret uint) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) - _cgo_runtime_cgocall(_wrap__swig_DirectorDerived_upcall_UIntMethod, _swig_p) - return -} - -func (swig_p *_swig_DirectorDerived) UIntMethod(x uint) uint { - if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceDerivedUIntMethod); swig_ok { - return swig_g.UIntMethod(x) - } - var swig_r uint - swig_r = _swig_wrap__swig_DirectorDerived_upcall_UIntMethod(swig_p.SwigcptrDerived, x) - return swig_r -} - -func DirectorDerivedUIntMethod(p Derived, arg2 uint) uint { - var swig_r uint - swig_r = _swig_wrap__swig_DirectorDerived_upcall_UIntMethod(p.(*_swig_DirectorDerived).SwigcptrDerived, arg2) - return swig_r -} - -func Swig_DirectorDerived_callback_UIntMethod(p *_swig_DirectorDerived, arg2 uint) (swig_result uint) { - var swig_r uint - swig_r = p.UIntMethod(arg2) - return swig_r -} - -type _swig_DirectorInterfaceDerivedFloatMethod interface { - FloatMethod(float32) float32 -} - -var _wrap__swig_DirectorDerived_upcall_FloatMethod unsafe.Pointer - -func _swig_wrap__swig_DirectorDerived_upcall_FloatMethod(_swig_ptr SwigcptrDerived, _ float32) (_swig_ret float32) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) - _cgo_runtime_cgocall(_wrap__swig_DirectorDerived_upcall_FloatMethod, _swig_p) - return -} - -func (swig_p *_swig_DirectorDerived) FloatMethod(x float32) float32 { - if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceDerivedFloatMethod); swig_ok { - return swig_g.FloatMethod(x) - } - var swig_r float32 - swig_r = _swig_wrap__swig_DirectorDerived_upcall_FloatMethod(swig_p.SwigcptrDerived, x) - return swig_r -} - -func DirectorDerivedFloatMethod(p Derived, arg2 float32) float32 { - var swig_r float32 - swig_r = _swig_wrap__swig_DirectorDerived_upcall_FloatMethod(p.(*_swig_DirectorDerived).SwigcptrDerived, arg2) - return swig_r -} - -func Swig_DirectorDerived_callback_FloatMethod(p *_swig_DirectorDerived, arg2 float32) (swig_result float32) { - var swig_r float32 - swig_r = p.FloatMethod(arg2) - return swig_r -} - -type _swig_DirectorInterfaceDerivedCharPtrMethod interface { - CharPtrMethod(string) string -} - -var _wrap__swig_DirectorDerived_upcall_CharPtrMethod unsafe.Pointer - -func _swig_wrap__swig_DirectorDerived_upcall_CharPtrMethod(_swig_ptr SwigcptrDerived, _ string) (_swig_ret string) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) - _cgo_runtime_cgocall(_wrap__swig_DirectorDerived_upcall_CharPtrMethod, _swig_p) - return -} - -func (swig_p *_swig_DirectorDerived) CharPtrMethod(x string) string { - if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceDerivedCharPtrMethod); swig_ok { - return swig_g.CharPtrMethod(x) - } - var swig_r string - swig_r = _swig_wrap__swig_DirectorDerived_upcall_CharPtrMethod(swig_p.SwigcptrDerived, x) - return swig_r -} - -func DirectorDerivedCharPtrMethod(p Derived, arg2 string) string { - var swig_r string - swig_r = _swig_wrap__swig_DirectorDerived_upcall_CharPtrMethod(p.(*_swig_DirectorDerived).SwigcptrDerived, arg2) - return swig_r -} - -func Swig_DirectorDerived_callback_CharPtrMethod(p *_swig_DirectorDerived, arg2 string) (swig_result string) { - var swig_r string - swig_r = p.CharPtrMethod(arg2) - return swig_r -} - -type _swig_DirectorInterfaceDerivedConstCharPtrMethod interface { - ConstCharPtrMethod(string) string -} - -var _wrap__swig_DirectorDerived_upcall_ConstCharPtrMethod unsafe.Pointer - -func _swig_wrap__swig_DirectorDerived_upcall_ConstCharPtrMethod(_swig_ptr SwigcptrDerived, _ string) (_swig_ret string) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) - _cgo_runtime_cgocall(_wrap__swig_DirectorDerived_upcall_ConstCharPtrMethod, _swig_p) - return -} - -func (swig_p *_swig_DirectorDerived) ConstCharPtrMethod(x string) string { - if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceDerivedConstCharPtrMethod); swig_ok { - return swig_g.ConstCharPtrMethod(x) - } - var swig_r string - swig_r = _swig_wrap__swig_DirectorDerived_upcall_ConstCharPtrMethod(swig_p.SwigcptrDerived, x) - return swig_r -} - -func DirectorDerivedConstCharPtrMethod(p Derived, arg2 string) string { - var swig_r string - swig_r = _swig_wrap__swig_DirectorDerived_upcall_ConstCharPtrMethod(p.(*_swig_DirectorDerived).SwigcptrDerived, arg2) - return swig_r -} - -func Swig_DirectorDerived_callback_ConstCharPtrMethod(p *_swig_DirectorDerived, arg2 string) (swig_result string) { - var swig_r string - swig_r = p.ConstCharPtrMethod(arg2) - return swig_r -} - -type _swig_DirectorInterfaceDerivedEnumMethod interface { - EnumMethod(HShadowMode) HShadowMode -} - -var _wrap__swig_DirectorDerived_upcall_EnumMethod unsafe.Pointer - -func _swig_wrap__swig_DirectorDerived_upcall_EnumMethod(_swig_ptr SwigcptrDerived, _ HShadowMode) (_swig_ret HShadowMode) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) - _cgo_runtime_cgocall(_wrap__swig_DirectorDerived_upcall_EnumMethod, _swig_p) - return -} - -func (swig_p *_swig_DirectorDerived) EnumMethod(x HShadowMode) HShadowMode { - if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceDerivedEnumMethod); swig_ok { - return swig_g.EnumMethod(x) - } - var swig_r HShadowMode - swig_r = _swig_wrap__swig_DirectorDerived_upcall_EnumMethod(swig_p.SwigcptrDerived, x) - return swig_r -} - -func DirectorDerivedEnumMethod(p Derived, arg2 HShadowMode) HShadowMode { - var swig_r HShadowMode - swig_r = _swig_wrap__swig_DirectorDerived_upcall_EnumMethod(p.(*_swig_DirectorDerived).SwigcptrDerived, arg2) - return swig_r -} - -func Swig_DirectorDerived_callback_EnumMethod(p *_swig_DirectorDerived, arg2 HShadowMode) (swig_result HShadowMode) { - var swig_r HShadowMode - swig_r = p.EnumMethod(arg2) - return swig_r -} - -type _swig_DirectorInterfaceDerivedManyParmsMethod interface { - ManyParmsMethod(bool, int, uint, float32, string, string, HShadowMode) -} - -var _wrap__swig_DirectorDerived_upcall_ManyParmsMethod unsafe.Pointer - -func _swig_wrap__swig_DirectorDerived_upcall_ManyParmsMethod(_swig_ptr SwigcptrDerived, _ bool, _ int, _ uint, _ float32, _ string, _ string, _ HShadowMode) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) - _cgo_runtime_cgocall(_wrap__swig_DirectorDerived_upcall_ManyParmsMethod, _swig_p) - return -} - -func (swig_p *_swig_DirectorDerived) ManyParmsMethod(b bool, i int, u uint, f float32, c string, cc string, h HShadowMode) { - if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceDerivedManyParmsMethod); swig_ok { - swig_g.ManyParmsMethod(b, i, u, f, c, cc, h) - return - } - _swig_wrap__swig_DirectorDerived_upcall_ManyParmsMethod(swig_p.SwigcptrDerived, b, i, u, f, c, cc, h) -} - -func DirectorDerivedManyParmsMethod(p Derived, arg2 bool, arg3 int, arg4 uint, arg5 float32, arg6 string, arg7 string, arg8 HShadowMode) { - _swig_wrap__swig_DirectorDerived_upcall_ManyParmsMethod(p.(*_swig_DirectorDerived).SwigcptrDerived, arg2, arg3, arg4, arg5, arg6, arg7, arg8) -} - -func Swig_DirectorDerived_callback_ManyParmsMethod(p *_swig_DirectorDerived, arg2 bool, arg3 int, arg4 uint, arg5 float32, arg6 string, arg7 string, arg8 HShadowMode) { - p.ManyParmsMethod(arg2, arg3, arg4, arg5, arg6, arg7, arg8) -} - -type _swig_DirectorInterfaceDerivedNotOverriddenMethod interface { - NotOverriddenMethod() -} - -var _wrap__swig_DirectorDerived_upcall_NotOverriddenMethod unsafe.Pointer - -func _swig_wrap__swig_DirectorDerived_upcall_NotOverriddenMethod(_swig_ptr SwigcptrDerived) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) - _cgo_runtime_cgocall(_wrap__swig_DirectorDerived_upcall_NotOverriddenMethod, _swig_p) - return -} - -func (swig_p *_swig_DirectorDerived) NotOverriddenMethod() { - if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceDerivedNotOverriddenMethod); swig_ok { - swig_g.NotOverriddenMethod() - return - } - _swig_wrap__swig_DirectorDerived_upcall_NotOverriddenMethod(swig_p.SwigcptrDerived) -} - -func DirectorDerivedNotOverriddenMethod(p Derived) { - _swig_wrap__swig_DirectorDerived_upcall_NotOverriddenMethod(p.(*_swig_DirectorDerived).SwigcptrDerived) -} - -func Swig_DirectorDerived_callback_NotOverriddenMethod(p *_swig_DirectorDerived) { - p.NotOverriddenMethod() -} - -type SwigcptrDerived uintptr - -func (p SwigcptrDerived) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrDerived) SwigIsDerived() { -} - -func (p SwigcptrDerived) DirectorInterface() interface{} { - return nil -} - -var _wrap_new_Derived unsafe.Pointer - -func _swig_wrap_new_Derived(base float64) (_ SwigcptrDerived) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Derived, _swig_p) - return -} - -func NewDerived(arg1 float64) (_swig_ret Derived) { - return _swig_wrap_new_Derived(arg1) -} - -var _wrap_delete_Derived unsafe.Pointer - -func _swig_wrap_delete_Derived(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Derived, _swig_p) - return -} - -func DeleteDerived(arg1 Derived) { - _swig_wrap_delete_Derived(arg1.Swigcptr()) -} - -var _wrap_Derived_NoParmsMethod unsafe.Pointer - -func _swig_wrap_Derived_NoParmsMethod(base SwigcptrDerived) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Derived_NoParmsMethod, _swig_p) - return -} - -func (arg1 SwigcptrDerived) NoParmsMethod() { - _swig_wrap_Derived_NoParmsMethod(arg1) -} - -var _wrap_Derived_BoolMethod unsafe.Pointer - -func _swig_wrap_Derived_BoolMethod(base SwigcptrDerived, _ bool) (_ bool) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Derived_BoolMethod, _swig_p) - return -} - -func (arg1 SwigcptrDerived) BoolMethod(arg2 bool) (_swig_ret bool) { - return _swig_wrap_Derived_BoolMethod(arg1, arg2) -} - -var _wrap_Derived_IntMethod unsafe.Pointer - -func _swig_wrap_Derived_IntMethod(base SwigcptrDerived, _ int) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Derived_IntMethod, _swig_p) - return -} - -func (arg1 SwigcptrDerived) IntMethod(arg2 int) (_swig_ret int) { - return _swig_wrap_Derived_IntMethod(arg1, arg2) -} - -var _wrap_Derived_UIntMethod unsafe.Pointer - -func _swig_wrap_Derived_UIntMethod(base SwigcptrDerived, _ uint) (_ uint) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Derived_UIntMethod, _swig_p) - return -} - -func (arg1 SwigcptrDerived) UIntMethod(arg2 uint) (_swig_ret uint) { - return _swig_wrap_Derived_UIntMethod(arg1, arg2) -} - -var _wrap_Derived_FloatMethod unsafe.Pointer - -func _swig_wrap_Derived_FloatMethod(base SwigcptrDerived, _ float32) (_ float32) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Derived_FloatMethod, _swig_p) - return -} - -func (arg1 SwigcptrDerived) FloatMethod(arg2 float32) (_swig_ret float32) { - return _swig_wrap_Derived_FloatMethod(arg1, arg2) -} - -var _wrap_Derived_CharPtrMethod unsafe.Pointer - -func _swig_wrap_Derived_CharPtrMethod(base SwigcptrDerived, _ string) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Derived_CharPtrMethod, _swig_p) - return -} - -func (arg1 SwigcptrDerived) CharPtrMethod(arg2 string) (_swig_ret string) { - return _swig_wrap_Derived_CharPtrMethod(arg1, arg2) -} - -var _wrap_Derived_ConstCharPtrMethod unsafe.Pointer - -func _swig_wrap_Derived_ConstCharPtrMethod(base SwigcptrDerived, _ string) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Derived_ConstCharPtrMethod, _swig_p) - return -} - -func (arg1 SwigcptrDerived) ConstCharPtrMethod(arg2 string) (_swig_ret string) { - return _swig_wrap_Derived_ConstCharPtrMethod(arg1, arg2) -} - -var _wrap_Derived_EnumMethod unsafe.Pointer - -func _swig_wrap_Derived_EnumMethod(base SwigcptrDerived, _ HShadowMode) (_ HShadowMode) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Derived_EnumMethod, _swig_p) - return -} - -func (arg1 SwigcptrDerived) EnumMethod(arg2 HShadowMode) (_swig_ret HShadowMode) { - return _swig_wrap_Derived_EnumMethod(arg1, arg2) -} - -var _wrap_Derived_ManyParmsMethod unsafe.Pointer - -func _swig_wrap_Derived_ManyParmsMethod(base SwigcptrDerived, _ bool, _ int, _ uint, _ float32, _ string, _ string, _ HShadowMode) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Derived_ManyParmsMethod, _swig_p) - return -} - -func (arg1 SwigcptrDerived) ManyParmsMethod(arg2 bool, arg3 int, arg4 uint, arg5 float32, arg6 string, arg7 string, arg8 HShadowMode) { - _swig_wrap_Derived_ManyParmsMethod(arg1, arg2, arg3, arg4, arg5, arg6, arg7, arg8) -} - -var _wrap_Derived_NotOverriddenMethod unsafe.Pointer - -func _swig_wrap_Derived_NotOverriddenMethod(base SwigcptrDerived) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Derived_NotOverriddenMethod, _swig_p) - return -} - -func (_swig_base SwigcptrDerived) NotOverriddenMethod() { - _swig_wrap_Derived_NotOverriddenMethod(_swig_base) -} - -func (p SwigcptrDerived) SwigIsBase() { -} - -func (p SwigcptrDerived) SwigGetBase() Base { - return SwigcptrBase(p.Swigcptr()) -} - -type Derived interface { - Swigcptr() uintptr - SwigIsDerived() - DirectorInterface() interface{} - NoParmsMethod() - BoolMethod(arg2 bool) (_swig_ret bool) - IntMethod(arg2 int) (_swig_ret int) - UIntMethod(arg2 uint) (_swig_ret uint) - FloatMethod(arg2 float32) (_swig_ret float32) - CharPtrMethod(arg2 string) (_swig_ret string) - ConstCharPtrMethod(arg2 string) (_swig_ret string) - EnumMethod(arg2 HShadowMode) (_swig_ret HShadowMode) - ManyParmsMethod(arg2 bool, arg3 int, arg4 uint, arg5 float32, arg6 string, arg7 string, arg8 HShadowMode) - NotOverriddenMethod() - SwigIsBase() - SwigGetBase() Base -} - -type SwigcptrCaller uintptr - -func (p SwigcptrCaller) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrCaller) SwigIsCaller() { -} - -var _wrap_new_Caller unsafe.Pointer - -func _swig_wrap_new_Caller() (base SwigcptrCaller) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Caller, _swig_p) - return -} - -func NewCaller() (_swig_ret Caller) { - return _swig_wrap_new_Caller() -} - -var _wrap_delete_Caller unsafe.Pointer - -func _swig_wrap_delete_Caller(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Caller, _swig_p) - return -} - -func DeleteCaller(arg1 Caller) { - _swig_wrap_delete_Caller(arg1.Swigcptr()) -} - -var _wrap_Caller_set unsafe.Pointer - -func _swig_wrap_Caller_set(base SwigcptrCaller, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Caller_set, _swig_p) - return -} - -func (arg1 SwigcptrCaller) Set(arg2 Base) { - _swig_wrap_Caller_set(arg1, arg2.Swigcptr()) -} - -var _wrap_Caller_reset unsafe.Pointer - -func _swig_wrap_Caller_reset(base SwigcptrCaller) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Caller_reset, _swig_p) - return -} - -func (arg1 SwigcptrCaller) Reset() { - _swig_wrap_Caller_reset(arg1) -} - -var _wrap_Caller_NoParmsMethodCall unsafe.Pointer - -func _swig_wrap_Caller_NoParmsMethodCall(base SwigcptrCaller) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Caller_NoParmsMethodCall, _swig_p) - return -} - -func (arg1 SwigcptrCaller) NoParmsMethodCall() { - _swig_wrap_Caller_NoParmsMethodCall(arg1) -} - -var _wrap_Caller_BoolMethodCall unsafe.Pointer - -func _swig_wrap_Caller_BoolMethodCall(base SwigcptrCaller, _ bool) (_ bool) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Caller_BoolMethodCall, _swig_p) - return -} - -func (arg1 SwigcptrCaller) BoolMethodCall(arg2 bool) (_swig_ret bool) { - return _swig_wrap_Caller_BoolMethodCall(arg1, arg2) -} - -var _wrap_Caller_IntMethodCall unsafe.Pointer - -func _swig_wrap_Caller_IntMethodCall(base SwigcptrCaller, _ int) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Caller_IntMethodCall, _swig_p) - return -} - -func (arg1 SwigcptrCaller) IntMethodCall(arg2 int) (_swig_ret int) { - return _swig_wrap_Caller_IntMethodCall(arg1, arg2) -} - -var _wrap_Caller_UIntMethodCall unsafe.Pointer - -func _swig_wrap_Caller_UIntMethodCall(base SwigcptrCaller, _ uint) (_ uint) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Caller_UIntMethodCall, _swig_p) - return -} - -func (arg1 SwigcptrCaller) UIntMethodCall(arg2 uint) (_swig_ret uint) { - return _swig_wrap_Caller_UIntMethodCall(arg1, arg2) -} - -var _wrap_Caller_FloatMethodCall unsafe.Pointer - -func _swig_wrap_Caller_FloatMethodCall(base SwigcptrCaller, _ float32) (_ float32) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Caller_FloatMethodCall, _swig_p) - return -} - -func (arg1 SwigcptrCaller) FloatMethodCall(arg2 float32) (_swig_ret float32) { - return _swig_wrap_Caller_FloatMethodCall(arg1, arg2) -} - -var _wrap_Caller_CharPtrMethodCall unsafe.Pointer - -func _swig_wrap_Caller_CharPtrMethodCall(base SwigcptrCaller, _ string) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Caller_CharPtrMethodCall, _swig_p) - return -} - -func (arg1 SwigcptrCaller) CharPtrMethodCall(arg2 string) (_swig_ret string) { - return _swig_wrap_Caller_CharPtrMethodCall(arg1, arg2) -} - -var _wrap_Caller_ConstCharPtrMethodCall unsafe.Pointer - -func _swig_wrap_Caller_ConstCharPtrMethodCall(base SwigcptrCaller, _ string) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Caller_ConstCharPtrMethodCall, _swig_p) - return -} - -func (arg1 SwigcptrCaller) ConstCharPtrMethodCall(arg2 string) (_swig_ret string) { - return _swig_wrap_Caller_ConstCharPtrMethodCall(arg1, arg2) -} - -var _wrap_Caller_EnumMethodCall unsafe.Pointer - -func _swig_wrap_Caller_EnumMethodCall(base SwigcptrCaller, _ HShadowMode) (_ HShadowMode) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Caller_EnumMethodCall, _swig_p) - return -} - -func (arg1 SwigcptrCaller) EnumMethodCall(arg2 HShadowMode) (_swig_ret HShadowMode) { - return _swig_wrap_Caller_EnumMethodCall(arg1, arg2) -} - -var _wrap_Caller_ManyParmsMethodCall unsafe.Pointer - -func _swig_wrap_Caller_ManyParmsMethodCall(base SwigcptrCaller, _ bool, _ int, _ uint, _ float32, _ string, _ string, _ HShadowMode) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Caller_ManyParmsMethodCall, _swig_p) - return -} - -func (arg1 SwigcptrCaller) ManyParmsMethodCall(arg2 bool, arg3 int, arg4 uint, arg5 float32, arg6 string, arg7 string, arg8 HShadowMode) { - _swig_wrap_Caller_ManyParmsMethodCall(arg1, arg2, arg3, arg4, arg5, arg6, arg7, arg8) -} - -var _wrap_Caller_NotOverriddenMethodCall unsafe.Pointer - -func _swig_wrap_Caller_NotOverriddenMethodCall(base SwigcptrCaller) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Caller_NotOverriddenMethodCall, _swig_p) - return -} - -func (arg1 SwigcptrCaller) NotOverriddenMethodCall() { - _swig_wrap_Caller_NotOverriddenMethodCall(arg1) -} - -type Caller interface { - Swigcptr() uintptr - SwigIsCaller() - Set(arg2 Base) - Reset() - NoParmsMethodCall() - BoolMethodCall(arg2 bool) (_swig_ret bool) - IntMethodCall(arg2 int) (_swig_ret int) - UIntMethodCall(arg2 uint) (_swig_ret uint) - FloatMethodCall(arg2 float32) (_swig_ret float32) - CharPtrMethodCall(arg2 string) (_swig_ret string) - ConstCharPtrMethodCall(arg2 string) (_swig_ret string) - EnumMethodCall(arg2 HShadowMode) (_swig_ret HShadowMode) - ManyParmsMethodCall(arg2 bool, arg3 int, arg4 uint, arg5 float32, arg6 string, arg7 string, arg8 HShadowMode) - NotOverriddenMethodCall() -} - - -type SwigcptrSwigDirector_Derived uintptr -type SwigDirector_Derived interface { - Swigcptr() uintptr; -} -func (p SwigcptrSwigDirector_Derived) Swigcptr() uintptr { - return uintptr(p) -} - -type SwigcptrSwigDirector_Base uintptr -type SwigDirector_Base interface { - Swigcptr() uintptr; -} -func (p SwigcptrSwigDirector_Base) Swigcptr() uintptr { - return uintptr(p) -} - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/director_primitives_wrap.h b/Examples/test-suite/go/director_primitives_wrap.h deleted file mode 100644 index 62048dbd9..000000000 --- a/Examples/test-suite/go/director_primitives_wrap.h +++ /dev/null @@ -1,114 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../director_primitives.i - -#ifndef SWIG_director_primitives_WRAP_H_ -#define SWIG_director_primitives_WRAP_H_ - -class SwigDirector_Base : public Base -{ - public: - SwigDirector_Base(void *swig_p, double dd); - virtual ~SwigDirector_Base(); - void _swig_upcall_NoParmsMethod() { - Base::NoParmsMethod(); - } - virtual void NoParmsMethod(); - bool _swig_upcall_BoolMethod(bool x) { - return Base::BoolMethod(x); - } - virtual bool BoolMethod(bool x); - int _swig_upcall_IntMethod(int x) { - return Base::IntMethod(x); - } - virtual int IntMethod(int x); - unsigned int _swig_upcall_UIntMethod(unsigned int x) { - return Base::UIntMethod(x); - } - virtual unsigned int UIntMethod(unsigned int x); - float _swig_upcall_FloatMethod(float x) { - return Base::FloatMethod(x); - } - virtual float FloatMethod(float x); - char *_swig_upcall_CharPtrMethod(char *x) { - return Base::CharPtrMethod(x); - } - virtual char *CharPtrMethod(char *x); - char const *_swig_upcall_ConstCharPtrMethod(char const *x) { - return Base::ConstCharPtrMethod(x); - } - virtual char const *ConstCharPtrMethod(char const *x); - HShadowMode _swig_upcall_EnumMethod(HShadowMode x) { - return Base::EnumMethod(x); - } - virtual HShadowMode EnumMethod(HShadowMode x); - void _swig_upcall_ManyParmsMethod(bool b, int i, unsigned int u, float f, char *c, char const *cc, HShadowMode h) { - Base::ManyParmsMethod(b,i,u,f,c,cc,h); - } - virtual void ManyParmsMethod(bool b, int i, unsigned int u, float f, char *c, char const *cc, HShadowMode h); - void _swig_upcall_NotOverriddenMethod() { - Base::NotOverriddenMethod(); - } - virtual void NotOverriddenMethod(); - private: - void *go_val; -}; - -class SwigDirector_Derived : public Derived -{ - public: - SwigDirector_Derived(void *swig_p, double dd); - virtual ~SwigDirector_Derived(); - void _swig_upcall_NoParmsMethod() { - Derived::NoParmsMethod(); - } - virtual void NoParmsMethod(); - bool _swig_upcall_BoolMethod(bool x) { - return Derived::BoolMethod(x); - } - virtual bool BoolMethod(bool x); - int _swig_upcall_IntMethod(int x) { - return Derived::IntMethod(x); - } - virtual int IntMethod(int x); - unsigned int _swig_upcall_UIntMethod(unsigned int x) { - return Derived::UIntMethod(x); - } - virtual unsigned int UIntMethod(unsigned int x); - float _swig_upcall_FloatMethod(float x) { - return Derived::FloatMethod(x); - } - virtual float FloatMethod(float x); - char *_swig_upcall_CharPtrMethod(char *x) { - return Derived::CharPtrMethod(x); - } - virtual char *CharPtrMethod(char *x); - char const *_swig_upcall_ConstCharPtrMethod(char const *x) { - return Derived::ConstCharPtrMethod(x); - } - virtual char const *ConstCharPtrMethod(char const *x); - HShadowMode _swig_upcall_EnumMethod(HShadowMode x) { - return Derived::EnumMethod(x); - } - virtual HShadowMode EnumMethod(HShadowMode x); - void _swig_upcall_ManyParmsMethod(bool b, int i, unsigned int u, float f, char *c, char const *cc, HShadowMode h) { - Derived::ManyParmsMethod(b,i,u,f,c,cc,h); - } - virtual void ManyParmsMethod(bool b, int i, unsigned int u, float f, char *c, char const *cc, HShadowMode h); - void _swig_upcall_NotOverriddenMethod() { - Base::NotOverriddenMethod(); - } - virtual void NotOverriddenMethod(); - private: - void *go_val; -}; - -#endif diff --git a/Examples/test-suite/go/director_protected.go b/Examples/test-suite/go/director_protected.go deleted file mode 100644 index 7c22873e6..000000000 --- a/Examples/test-suite/go/director_protected.go +++ /dev/null @@ -1,1081 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../director_protected.i - -package director_protected - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type _swig_DirectorFoo struct { - SwigcptrFoo - v interface{} -} - -func (p *_swig_DirectorFoo) Swigcptr() uintptr { - return p.SwigcptrFoo.Swigcptr() -} - -func (p *_swig_DirectorFoo) SwigIsFoo() { -} - -func (p *_swig_DirectorFoo) DirectorInterface() interface{} { - return p.v -} - -var _wrap__swig_NewDirectorFooFoo unsafe.Pointer - -func _swig_NewDirectorFooFoo(_swig_director *_swig_DirectorFoo) (_swig_ret SwigcptrFoo) { - _swig_p := uintptr(unsafe.Pointer(&_swig_director)) - _cgo_runtime_cgocall(_wrap__swig_NewDirectorFooFoo, _swig_p) - return -} - -func NewDirectorFoo(v interface{}) Foo { - p := &_swig_DirectorFoo{0, v} - p.SwigcptrFoo = _swig_NewDirectorFooFoo(p) - return p -} - -var _wrap_DeleteDirectorFoo unsafe.Pointer - -func _swig_wrap_DeleteDirectorFoo(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_DeleteDirectorFoo, _swig_p) - return -} - -func DeleteDirectorFoo(arg1 Foo) { - _swig_wrap_DeleteDirectorFoo(arg1.Swigcptr()) -} - -func Swiggo_DeleteDirector_Foo(p *_swig_DirectorFoo) { - p.SwigcptrFoo = 0 -} - -type _swig_DirectorInterfaceFooPong interface { - Pong() string -} - -var _wrap__swig_DirectorFoo_upcall_Pong unsafe.Pointer - -func _swig_wrap__swig_DirectorFoo_upcall_Pong(_swig_ptr SwigcptrFoo) (_swig_ret string) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) - _cgo_runtime_cgocall(_wrap__swig_DirectorFoo_upcall_Pong, _swig_p) - return -} - -func (swig_p *_swig_DirectorFoo) Pong() string { - if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceFooPong); swig_ok { - return swig_g.Pong() - } - var swig_r string - swig_r = _swig_wrap__swig_DirectorFoo_upcall_Pong(swig_p.SwigcptrFoo) - return swig_r -} - -func DirectorFooPong(p Foo) string { - var swig_r string - swig_r = _swig_wrap__swig_DirectorFoo_upcall_Pong(p.(*_swig_DirectorFoo).SwigcptrFoo) - return swig_r -} - -func Swig_DirectorFoo_callback_pong(p *_swig_DirectorFoo) (swig_result string) { - var swig_r string - swig_r = p.Pong() - return swig_r -} - -type _swig_DirectorInterfaceFooPing interface { - Ping() string -} - -func (swig_p *_swig_DirectorFoo) Ping() string { - if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceFooPing); swig_ok { - return swig_g.Ping() - } - panic("call to pure virtual method") -} - -func Swig_DirectorFoo_callback_ping(p *_swig_DirectorFoo) (swig_result string) { - var swig_r string - swig_r = p.Ping() - return swig_r -} - -type _swig_DirectorInterfaceFooPang interface { - Pang() string -} - -var _wrap__swig_DirectorFoo_upcall_Pang unsafe.Pointer - -func _swig_wrap__swig_DirectorFoo_upcall_Pang(_swig_ptr SwigcptrFoo) (_swig_ret string) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) - _cgo_runtime_cgocall(_wrap__swig_DirectorFoo_upcall_Pang, _swig_p) - return -} - -func (swig_p *_swig_DirectorFoo) Pang() string { - if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceFooPang); swig_ok { - return swig_g.Pang() - } - var swig_r string - swig_r = _swig_wrap__swig_DirectorFoo_upcall_Pang(swig_p.SwigcptrFoo) - return swig_r -} - -func DirectorFooPang(p Foo) string { - var swig_r string - swig_r = _swig_wrap__swig_DirectorFoo_upcall_Pang(p.(*_swig_DirectorFoo).SwigcptrFoo) - return swig_r -} - -func Swig_DirectorFoo_callback_pang(p *_swig_DirectorFoo) (swig_result string) { - var swig_r string - swig_r = p.Pang() - return swig_r -} - -type _swig_DirectorInterfaceFooUsed interface { - Used() string -} - -var _wrap__swig_DirectorFoo_upcall_Used unsafe.Pointer - -func _swig_wrap__swig_DirectorFoo_upcall_Used(_swig_ptr SwigcptrFoo) (_swig_ret string) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) - _cgo_runtime_cgocall(_wrap__swig_DirectorFoo_upcall_Used, _swig_p) - return -} - -func (swig_p *_swig_DirectorFoo) Used() string { - if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceFooUsed); swig_ok { - return swig_g.Used() - } - var swig_r string - swig_r = _swig_wrap__swig_DirectorFoo_upcall_Used(swig_p.SwigcptrFoo) - return swig_r -} - -func DirectorFooUsed(p Foo) string { - var swig_r string - swig_r = _swig_wrap__swig_DirectorFoo_upcall_Used(p.(*_swig_DirectorFoo).SwigcptrFoo) - return swig_r -} - -func Swig_DirectorFoo_callback_used(p *_swig_DirectorFoo) (swig_result string) { - var swig_r string - swig_r = p.Used() - return swig_r -} - -type _swig_DirectorInterfaceFooCheer interface { - Cheer() string -} - -var _wrap__swig_DirectorFoo_upcall_Cheer unsafe.Pointer - -func _swig_wrap__swig_DirectorFoo_upcall_Cheer(_swig_ptr SwigcptrFoo) (_swig_ret string) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) - _cgo_runtime_cgocall(_wrap__swig_DirectorFoo_upcall_Cheer, _swig_p) - return -} - -func (swig_p *_swig_DirectorFoo) Cheer() string { - if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceFooCheer); swig_ok { - return swig_g.Cheer() - } - var swig_r string - swig_r = _swig_wrap__swig_DirectorFoo_upcall_Cheer(swig_p.SwigcptrFoo) - return swig_r -} - -func DirectorFooCheer(p Foo) string { - var swig_r string - swig_r = _swig_wrap__swig_DirectorFoo_upcall_Cheer(p.(*_swig_DirectorFoo).SwigcptrFoo) - return swig_r -} - -func Swig_DirectorFoo_callback_cheer(p *_swig_DirectorFoo) (swig_result string) { - var swig_r string - swig_r = p.Cheer() - return swig_r -} - -type SwigcptrFoo uintptr - -func (p SwigcptrFoo) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrFoo) SwigIsFoo() { -} - -func (p SwigcptrFoo) DirectorInterface() interface{} { - return nil -} - -var _wrap_delete_Foo unsafe.Pointer - -func _swig_wrap_delete_Foo(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Foo, _swig_p) - return -} - -func DeleteFoo(arg1 Foo) { - _swig_wrap_delete_Foo(arg1.Swigcptr()) -} - -var _wrap_Foo_pong unsafe.Pointer - -func _swig_wrap_Foo_pong(base SwigcptrFoo) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_pong, _swig_p) - return -} - -func (arg1 SwigcptrFoo) Pong() (_swig_ret string) { - return _swig_wrap_Foo_pong(arg1) -} - -var _wrap_Foo_s unsafe.Pointer - -func _swig_wrap_Foo_s(base SwigcptrFoo) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_s, _swig_p) - return -} - -func (arg1 SwigcptrFoo) S() (_swig_ret int) { - return _swig_wrap_Foo_s(arg1) -} - -var _wrap_Foo_q unsafe.Pointer - -func _swig_wrap_Foo_q(base SwigcptrFoo) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_q, _swig_p) - return -} - -func (arg1 SwigcptrFoo) Q() (_swig_ret int) { - return _swig_wrap_Foo_q(arg1) -} - -var _wrap_new_Foo unsafe.Pointer - -func _swig_wrap_new_Foo() (base SwigcptrFoo) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Foo, _swig_p) - return -} - -func NewFoo() (_swig_ret Foo) { - return _swig_wrap_new_Foo() -} - -type Foo interface { - Swigcptr() uintptr - SwigIsFoo() - DirectorInterface() interface{} - Pong() (_swig_ret string) - S() (_swig_ret int) - Q() (_swig_ret int) -} - -type _swig_DirectorBar struct { - SwigcptrBar - v interface{} -} - -func (p *_swig_DirectorBar) Swigcptr() uintptr { - return p.SwigcptrBar.Swigcptr() -} - -func (p *_swig_DirectorBar) SwigIsBar() { -} - -func (p *_swig_DirectorBar) DirectorInterface() interface{} { - return p.v -} - -var _wrap__swig_NewDirectorBarBar unsafe.Pointer - -func _swig_NewDirectorBarBar(_swig_director *_swig_DirectorBar) (_swig_ret SwigcptrBar) { - _swig_p := uintptr(unsafe.Pointer(&_swig_director)) - _cgo_runtime_cgocall(_wrap__swig_NewDirectorBarBar, _swig_p) - return -} - -func NewDirectorBar(v interface{}) Bar { - p := &_swig_DirectorBar{0, v} - p.SwigcptrBar = _swig_NewDirectorBarBar(p) - return p -} - -var _wrap_DeleteDirectorBar unsafe.Pointer - -func _swig_wrap_DeleteDirectorBar(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_DeleteDirectorBar, _swig_p) - return -} - -func DeleteDirectorBar(arg1 Bar) { - _swig_wrap_DeleteDirectorBar(arg1.Swigcptr()) -} - -func Swiggo_DeleteDirector_Bar(p *_swig_DirectorBar) { - p.SwigcptrBar = 0 -} - -type _swig_DirectorInterfaceBarPong interface { - Pong() string -} - -var _wrap__swig_DirectorBar_upcall_Pong unsafe.Pointer - -func _swig_wrap__swig_DirectorBar_upcall_Pong(_swig_ptr SwigcptrBar) (_swig_ret string) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) - _cgo_runtime_cgocall(_wrap__swig_DirectorBar_upcall_Pong, _swig_p) - return -} - -func (swig_p *_swig_DirectorBar) Pong() string { - if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceBarPong); swig_ok { - return swig_g.Pong() - } - var swig_r string - swig_r = _swig_wrap__swig_DirectorBar_upcall_Pong(swig_p.SwigcptrBar) - return swig_r -} - -func DirectorBarPong(p Bar) string { - var swig_r string - swig_r = _swig_wrap__swig_DirectorBar_upcall_Pong(p.(*_swig_DirectorBar).SwigcptrBar) - return swig_r -} - -func Swig_DirectorBar_callback_pong(p *_swig_DirectorBar) (swig_result string) { - var swig_r string - swig_r = p.Pong() - return swig_r -} - -type _swig_DirectorInterfaceBarPing interface { - Ping() string -} - -var _wrap__swig_DirectorBar_upcall_Ping unsafe.Pointer - -func _swig_wrap__swig_DirectorBar_upcall_Ping(_swig_ptr SwigcptrBar) (_swig_ret string) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) - _cgo_runtime_cgocall(_wrap__swig_DirectorBar_upcall_Ping, _swig_p) - return -} - -func (swig_p *_swig_DirectorBar) Ping() string { - if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceBarPing); swig_ok { - return swig_g.Ping() - } - var swig_r string - swig_r = _swig_wrap__swig_DirectorBar_upcall_Ping(swig_p.SwigcptrBar) - return swig_r -} - -func DirectorBarPing(p Bar) string { - var swig_r string - swig_r = _swig_wrap__swig_DirectorBar_upcall_Ping(p.(*_swig_DirectorBar).SwigcptrBar) - return swig_r -} - -func Swig_DirectorBar_callback_ping(p *_swig_DirectorBar) (swig_result string) { - var swig_r string - swig_r = p.Ping() - return swig_r -} - -type _swig_DirectorInterfaceBarPang interface { - Pang() string -} - -var _wrap__swig_DirectorBar_upcall_Pang unsafe.Pointer - -func _swig_wrap__swig_DirectorBar_upcall_Pang(_swig_ptr SwigcptrBar) (_swig_ret string) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) - _cgo_runtime_cgocall(_wrap__swig_DirectorBar_upcall_Pang, _swig_p) - return -} - -func (swig_p *_swig_DirectorBar) Pang() string { - if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceBarPang); swig_ok { - return swig_g.Pang() - } - var swig_r string - swig_r = _swig_wrap__swig_DirectorBar_upcall_Pang(swig_p.SwigcptrBar) - return swig_r -} - -func DirectorBarPang(p Bar) string { - var swig_r string - swig_r = _swig_wrap__swig_DirectorBar_upcall_Pang(p.(*_swig_DirectorBar).SwigcptrBar) - return swig_r -} - -func Swig_DirectorBar_callback_pang(p *_swig_DirectorBar) (swig_result string) { - var swig_r string - swig_r = p.Pang() - return swig_r -} - -type _swig_DirectorInterfaceBarUsed interface { - Used() string -} - -var _wrap__swig_DirectorBar_upcall_Used unsafe.Pointer - -func _swig_wrap__swig_DirectorBar_upcall_Used(_swig_ptr SwigcptrBar) (_swig_ret string) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) - _cgo_runtime_cgocall(_wrap__swig_DirectorBar_upcall_Used, _swig_p) - return -} - -func (swig_p *_swig_DirectorBar) Used() string { - if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceBarUsed); swig_ok { - return swig_g.Used() - } - var swig_r string - swig_r = _swig_wrap__swig_DirectorBar_upcall_Used(swig_p.SwigcptrBar) - return swig_r -} - -func DirectorBarUsed(p Bar) string { - var swig_r string - swig_r = _swig_wrap__swig_DirectorBar_upcall_Used(p.(*_swig_DirectorBar).SwigcptrBar) - return swig_r -} - -func Swig_DirectorBar_callback_used(p *_swig_DirectorBar) (swig_result string) { - var swig_r string - swig_r = p.Used() - return swig_r -} - -type _swig_DirectorInterfaceBarCheer interface { - Cheer() string -} - -var _wrap__swig_DirectorBar_upcall_Cheer unsafe.Pointer - -func _swig_wrap__swig_DirectorBar_upcall_Cheer(_swig_ptr SwigcptrBar) (_swig_ret string) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) - _cgo_runtime_cgocall(_wrap__swig_DirectorBar_upcall_Cheer, _swig_p) - return -} - -func (swig_p *_swig_DirectorBar) Cheer() string { - if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceBarCheer); swig_ok { - return swig_g.Cheer() - } - var swig_r string - swig_r = _swig_wrap__swig_DirectorBar_upcall_Cheer(swig_p.SwigcptrBar) - return swig_r -} - -func DirectorBarCheer(p Bar) string { - var swig_r string - swig_r = _swig_wrap__swig_DirectorBar_upcall_Cheer(p.(*_swig_DirectorBar).SwigcptrBar) - return swig_r -} - -func Swig_DirectorBar_callback_cheer(p *_swig_DirectorBar) (swig_result string) { - var swig_r string - swig_r = p.Cheer() - return swig_r -} - -type SwigcptrBar uintptr - -func (p SwigcptrBar) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrBar) SwigIsBar() { -} - -func (p SwigcptrBar) DirectorInterface() interface{} { - return nil -} - -var _wrap_Bar_create unsafe.Pointer - -func _swig_wrap_Bar_create(base SwigcptrBar) (_ SwigcptrFoo) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Bar_create, _swig_p) - return -} - -func (arg1 SwigcptrBar) Create() (_swig_ret Foo) { - return _swig_wrap_Bar_create(arg1) -} - -var _wrap_Bar_callping unsafe.Pointer - -func _swig_wrap_Bar_callping(base SwigcptrBar) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Bar_callping, _swig_p) - return -} - -func (arg1 SwigcptrBar) Callping() (_swig_ret string) { - return _swig_wrap_Bar_callping(arg1) -} - -var _wrap_Bar_callcheer unsafe.Pointer - -func _swig_wrap_Bar_callcheer(base SwigcptrBar) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Bar_callcheer, _swig_p) - return -} - -func (arg1 SwigcptrBar) Callcheer() (_swig_ret string) { - return _swig_wrap_Bar_callcheer(arg1) -} - -var _wrap_Bar_pong unsafe.Pointer - -func _swig_wrap_Bar_pong(base SwigcptrBar) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Bar_pong, _swig_p) - return -} - -func (arg1 SwigcptrBar) Pong() (_swig_ret string) { - return _swig_wrap_Bar_pong(arg1) -} - -var _wrap_Bar_a_set unsafe.Pointer - -func _swig_wrap_Bar_a_set(base SwigcptrBar, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Bar_a_set, _swig_p) - return -} - -func (arg1 SwigcptrBar) SetA(arg2 int) { - _swig_wrap_Bar_a_set(arg1, arg2) -} - -var _wrap_Bar_a_get unsafe.Pointer - -func _swig_wrap_Bar_a_get(base SwigcptrBar) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Bar_a_get, _swig_p) - return -} - -func (arg1 SwigcptrBar) GetA() (_swig_ret int) { - return _swig_wrap_Bar_a_get(arg1) -} - -var _wrap_Bar_used unsafe.Pointer - -func _swig_wrap_Bar_used(base SwigcptrBar) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Bar_used, _swig_p) - return -} - -func (arg1 SwigcptrBar) Used() (_swig_ret string) { - return _swig_wrap_Bar_used(arg1) -} - -type BarHello int -var _wrap_new_Bar unsafe.Pointer - -func _swig_wrap_new_Bar() (base SwigcptrBar) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Bar, _swig_p) - return -} - -func NewBar() (_swig_ret Bar) { - return _swig_wrap_new_Bar() -} - -var _wrap_delete_Bar unsafe.Pointer - -func _swig_wrap_delete_Bar(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Bar, _swig_p) - return -} - -func DeleteBar(arg1 Bar) { - _swig_wrap_delete_Bar(arg1.Swigcptr()) -} - -var _wrap_Bar_s unsafe.Pointer - -func _swig_wrap_Bar_s(base SwigcptrBar) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Bar_s, _swig_p) - return -} - -func (_swig_base SwigcptrBar) S() (_swig_ret int) { - return _swig_wrap_Bar_s(_swig_base) -} - -var _wrap_Bar_q unsafe.Pointer - -func _swig_wrap_Bar_q(base SwigcptrBar) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Bar_q, _swig_p) - return -} - -func (_swig_base SwigcptrBar) Q() (_swig_ret int) { - return _swig_wrap_Bar_q(_swig_base) -} - -func (p SwigcptrBar) SwigIsFoo() { -} - -func (p SwigcptrBar) SwigGetFoo() Foo { - return SwigcptrFoo(p.Swigcptr()) -} - -type Bar interface { - Swigcptr() uintptr - SwigIsBar() - DirectorInterface() interface{} - Create() (_swig_ret Foo) - Callping() (_swig_ret string) - Callcheer() (_swig_ret string) - Pong() (_swig_ret string) - SetA(arg2 int) - GetA() (_swig_ret int) - Used() (_swig_ret string) - S() (_swig_ret int) - Q() (_swig_ret int) - SwigIsFoo() - SwigGetFoo() Foo -} - -type SwigcptrPrivateFoo uintptr - -func (p SwigcptrPrivateFoo) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrPrivateFoo) SwigIsPrivateFoo() { -} - -var _wrap_delete_PrivateFoo unsafe.Pointer - -func _swig_wrap_delete_PrivateFoo(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_PrivateFoo, _swig_p) - return -} - -func DeletePrivateFoo(arg1 PrivateFoo) { - _swig_wrap_delete_PrivateFoo(arg1.Swigcptr()) -} - -type PrivateFoo interface { - Swigcptr() uintptr - SwigIsPrivateFoo() -} - -type _swig_DirectorA struct { - SwigcptrA - v interface{} -} - -func (p *_swig_DirectorA) Swigcptr() uintptr { - return p.SwigcptrA.Swigcptr() -} - -func (p *_swig_DirectorA) SwigIsA() { -} - -func (p *_swig_DirectorA) DirectorInterface() interface{} { - return p.v -} - -var _wrap__swig_NewDirectorAA unsafe.Pointer - -func _swig_NewDirectorAA(_swig_director *_swig_DirectorA) (_swig_ret SwigcptrA) { - _swig_p := uintptr(unsafe.Pointer(&_swig_director)) - _cgo_runtime_cgocall(_wrap__swig_NewDirectorAA, _swig_p) - return -} - -func NewDirectorA(v interface{}) A { - p := &_swig_DirectorA{0, v} - p.SwigcptrA = _swig_NewDirectorAA(p) - return p -} - -var _wrap_DeleteDirectorA unsafe.Pointer - -func _swig_wrap_DeleteDirectorA(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_DeleteDirectorA, _swig_p) - return -} - -func DeleteDirectorA(arg1 A) { - _swig_wrap_DeleteDirectorA(arg1.Swigcptr()) -} - -func Swiggo_DeleteDirector_A(p *_swig_DirectorA) { - p.SwigcptrA = 0 -} - -type _swig_DirectorInterfaceADraw interface { - Draw() -} - -var _wrap__swig_DirectorA_upcall_Draw unsafe.Pointer - -func _swig_wrap__swig_DirectorA_upcall_Draw(_swig_ptr SwigcptrA) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) - _cgo_runtime_cgocall(_wrap__swig_DirectorA_upcall_Draw, _swig_p) - return -} - -func (swig_p *_swig_DirectorA) Draw() { - if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceADraw); swig_ok { - swig_g.Draw() - return - } - _swig_wrap__swig_DirectorA_upcall_Draw(swig_p.SwigcptrA) -} - -func DirectorADraw(p A) { - _swig_wrap__swig_DirectorA_upcall_Draw(p.(*_swig_DirectorA).SwigcptrA) -} - -func Swig_DirectorA_callback_draw(p *_swig_DirectorA) { - p.Draw() -} - -type SwigcptrA uintptr - -func (p SwigcptrA) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrA) SwigIsA() { -} - -func (p SwigcptrA) DirectorInterface() interface{} { - return nil -} - -var _wrap_new_A unsafe.Pointer - -func _swig_wrap_new_A() (base SwigcptrA) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_A, _swig_p) - return -} - -func NewA() (_swig_ret A) { - return _swig_wrap_new_A() -} - -var _wrap_delete_A unsafe.Pointer - -func _swig_wrap_delete_A(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_A, _swig_p) - return -} - -func DeleteA(arg1 A) { - _swig_wrap_delete_A(arg1.Swigcptr()) -} - -type A interface { - Swigcptr() uintptr - SwigIsA() - DirectorInterface() interface{} -} - -type _swig_DirectorB struct { - SwigcptrB - v interface{} -} - -func (p *_swig_DirectorB) Swigcptr() uintptr { - return p.SwigcptrB.Swigcptr() -} - -func (p *_swig_DirectorB) SwigIsB() { -} - -func (p *_swig_DirectorB) DirectorInterface() interface{} { - return p.v -} - -var _wrap__swig_NewDirectorBB unsafe.Pointer - -func _swig_NewDirectorBB(_swig_director *_swig_DirectorB) (_swig_ret SwigcptrB) { - _swig_p := uintptr(unsafe.Pointer(&_swig_director)) - _cgo_runtime_cgocall(_wrap__swig_NewDirectorBB, _swig_p) - return -} - -func NewDirectorB(v interface{}) B { - p := &_swig_DirectorB{0, v} - p.SwigcptrB = _swig_NewDirectorBB(p) - return p -} - -var _wrap_DeleteDirectorB unsafe.Pointer - -func _swig_wrap_DeleteDirectorB(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_DeleteDirectorB, _swig_p) - return -} - -func DeleteDirectorB(arg1 B) { - _swig_wrap_DeleteDirectorB(arg1.Swigcptr()) -} - -func Swiggo_DeleteDirector_B(p *_swig_DirectorB) { - p.SwigcptrB = 0 -} - -type _swig_DirectorInterfaceBDraw interface { - Draw() -} - -var _wrap__swig_DirectorB_upcall_Draw unsafe.Pointer - -func _swig_wrap__swig_DirectorB_upcall_Draw(_swig_ptr SwigcptrB) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) - _cgo_runtime_cgocall(_wrap__swig_DirectorB_upcall_Draw, _swig_p) - return -} - -func (swig_p *_swig_DirectorB) Draw() { - if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceBDraw); swig_ok { - swig_g.Draw() - return - } - _swig_wrap__swig_DirectorB_upcall_Draw(swig_p.SwigcptrB) -} - -func DirectorBDraw(p B) { - _swig_wrap__swig_DirectorB_upcall_Draw(p.(*_swig_DirectorB).SwigcptrB) -} - -func Swig_DirectorB_callback_draw(p *_swig_DirectorB) { - p.Draw() -} - -type SwigcptrB uintptr - -func (p SwigcptrB) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrB) SwigIsB() { -} - -func (p SwigcptrB) DirectorInterface() interface{} { - return nil -} - -var _wrap_new_B unsafe.Pointer - -func _swig_wrap_new_B() (base SwigcptrB) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_B, _swig_p) - return -} - -func NewB() (_swig_ret B) { - return _swig_wrap_new_B() -} - -var _wrap_delete_B unsafe.Pointer - -func _swig_wrap_delete_B(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_B, _swig_p) - return -} - -func DeleteB(arg1 B) { - _swig_wrap_delete_B(arg1.Swigcptr()) -} - -func (p SwigcptrB) SwigIsA() { -} - -func (p SwigcptrB) SwigGetA() A { - return SwigcptrA(p.Swigcptr()) -} - -type B interface { - Swigcptr() uintptr - SwigIsB() - DirectorInterface() interface{} - SwigIsA() - SwigGetA() A -} - -type SwigcptrAA uintptr - -func (p SwigcptrAA) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrAA) SwigIsAA() { -} - -var _wrap_new_AA unsafe.Pointer - -func _swig_wrap_new_AA() (base SwigcptrAA) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_AA, _swig_p) - return -} - -func NewAA() (_swig_ret AA) { - return _swig_wrap_new_AA() -} - -var _wrap_delete_AA unsafe.Pointer - -func _swig_wrap_delete_AA(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_AA, _swig_p) - return -} - -func DeleteAA(arg1 AA) { - _swig_wrap_delete_AA(arg1.Swigcptr()) -} - -type AA interface { - Swigcptr() uintptr - SwigIsAA() -} - -type SwigcptrBB uintptr - -func (p SwigcptrBB) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrBB) SwigIsBB() { -} - -var _wrap_new_BB unsafe.Pointer - -func _swig_wrap_new_BB() (base SwigcptrBB) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_BB, _swig_p) - return -} - -func NewBB() (_swig_ret BB) { - return _swig_wrap_new_BB() -} - -var _wrap_delete_BB unsafe.Pointer - -func _swig_wrap_delete_BB(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_BB, _swig_p) - return -} - -func DeleteBB(arg1 BB) { - _swig_wrap_delete_BB(arg1.Swigcptr()) -} - -func (p SwigcptrBB) SwigIsAA() { -} - -func (p SwigcptrBB) SwigGetAA() AA { - return SwigcptrAA(p.Swigcptr()) -} - -type BB interface { - Swigcptr() uintptr - SwigIsBB() - SwigIsAA() - SwigGetAA() AA -} - - -type SwigcptrSwigDirector_A uintptr -type SwigDirector_A interface { - Swigcptr() uintptr; -} -func (p SwigcptrSwigDirector_A) Swigcptr() uintptr { - return uintptr(p) -} - -type SwigcptrSwigDirector_B uintptr -type SwigDirector_B interface { - Swigcptr() uintptr; -} -func (p SwigcptrSwigDirector_B) Swigcptr() uintptr { - return uintptr(p) -} - -type SwigcptrSwigDirector_Foo uintptr -type SwigDirector_Foo interface { - Swigcptr() uintptr; -} -func (p SwigcptrSwigDirector_Foo) Swigcptr() uintptr { - return uintptr(p) -} - -type SwigcptrSwigDirector_Bar uintptr -type SwigDirector_Bar interface { - Swigcptr() uintptr; -} -func (p SwigcptrSwigDirector_Bar) Swigcptr() uintptr { - return uintptr(p) -} - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/director_protected_overloaded.go b/Examples/test-suite/go/director_protected_overloaded.go deleted file mode 100644 index 90ca6e74e..000000000 --- a/Examples/test-suite/go/director_protected_overloaded.go +++ /dev/null @@ -1,386 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../director_protected_overloaded.i - -package director_protected_overloaded - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type _swig_DirectorIDataObserver struct { - SwigcptrIDataObserver - v interface{} -} - -func (p *_swig_DirectorIDataObserver) Swigcptr() uintptr { - return p.SwigcptrIDataObserver.Swigcptr() -} - -func (p *_swig_DirectorIDataObserver) SwigIsIDataObserver() { -} - -func (p *_swig_DirectorIDataObserver) DirectorInterface() interface{} { - return p.v -} - -var _wrap__swig_NewDirectorIDataObserverIDataObserver unsafe.Pointer - -func _swig_NewDirectorIDataObserverIDataObserver(_swig_director *_swig_DirectorIDataObserver) (_swig_ret SwigcptrIDataObserver) { - _swig_p := uintptr(unsafe.Pointer(&_swig_director)) - _cgo_runtime_cgocall(_wrap__swig_NewDirectorIDataObserverIDataObserver, _swig_p) - return -} - -func NewDirectorIDataObserver(v interface{}) IDataObserver { - p := &_swig_DirectorIDataObserver{0, v} - p.SwigcptrIDataObserver = _swig_NewDirectorIDataObserverIDataObserver(p) - return p -} - -var _wrap_DeleteDirectorIDataObserver unsafe.Pointer - -func _swig_wrap_DeleteDirectorIDataObserver(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_DeleteDirectorIDataObserver, _swig_p) - return -} - -func DeleteDirectorIDataObserver(arg1 IDataObserver) { - _swig_wrap_DeleteDirectorIDataObserver(arg1.Swigcptr()) -} - -func Swiggo_DeleteDirector_IDataObserver(p *_swig_DirectorIDataObserver) { - p.SwigcptrIDataObserver = 0 -} - -type _swig_DirectorInterfaceIDataObserverNotoverloaded interface { - Notoverloaded() -} - -func (swig_p *_swig_DirectorIDataObserver) Notoverloaded() { - if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceIDataObserverNotoverloaded); swig_ok { - swig_g.Notoverloaded() - return - } - panic("call to pure virtual method") -} - -func Swig_DirectorIDataObserver_callback_notoverloaded(p *_swig_DirectorIDataObserver) { - p.Notoverloaded() -} - -type _swig_DirectorInterfaceIDataObserverIsoverloaded__SWIG_0 interface { - Isoverloaded__SWIG_0() -} - -func (swig_p *_swig_DirectorIDataObserver) Isoverloaded__SWIG_0() { - if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceIDataObserverIsoverloaded__SWIG_0); swig_ok { - swig_g.Isoverloaded__SWIG_0() - return - } - panic("call to pure virtual method") -} - -func Swig_DirectorIDataObserver_callback_isoverloaded__SWIG_0(p *_swig_DirectorIDataObserver) { - p.Isoverloaded__SWIG_0() -} - -type _swig_DirectorInterfaceIDataObserverIsoverloaded__SWIG_1 interface { - Isoverloaded__SWIG_1(int) -} - -func (swig_p *_swig_DirectorIDataObserver) Isoverloaded__SWIG_1(i int) { - if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceIDataObserverIsoverloaded__SWIG_1); swig_ok { - swig_g.Isoverloaded__SWIG_1(i) - return - } - panic("call to pure virtual method") -} - -func Swig_DirectorIDataObserver_callback_isoverloaded__SWIG_1(p *_swig_DirectorIDataObserver, i int) { - p.Isoverloaded__SWIG_1(i) -} - -type _swig_DirectorInterfaceIDataObserverIsoverloaded__SWIG_2 interface { - Isoverloaded__SWIG_2(int, float64) -} - -func (swig_p *_swig_DirectorIDataObserver) Isoverloaded__SWIG_2(i int, d float64) { - if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceIDataObserverIsoverloaded__SWIG_2); swig_ok { - swig_g.Isoverloaded__SWIG_2(i, d) - return - } - panic("call to pure virtual method") -} - -func Swig_DirectorIDataObserver_callback_isoverloaded__SWIG_2(p *_swig_DirectorIDataObserver, i int, d float64) { - p.Isoverloaded__SWIG_2(i, d) -} - -func (p _swig_DirectorIDataObserver) Isoverloaded(a ...interface{}) { - argc := len(a) - if argc == 0 { - p.Isoverloaded__SWIG_0() - return - } - if argc == 1 { - p.Isoverloaded__SWIG_1(a[0].(int)) - return - } - if argc == 2 { - p.Isoverloaded__SWIG_2(a[0].(int), a[1].(float64)) - return - } - panic("No match for overloaded function call") -} - -type SwigcptrIDataObserver uintptr - -func (p SwigcptrIDataObserver) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrIDataObserver) SwigIsIDataObserver() { -} - -func (p SwigcptrIDataObserver) DirectorInterface() interface{} { - return nil -} - -var _wrap_delete_IDataObserver unsafe.Pointer - -func _swig_wrap_delete_IDataObserver(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_IDataObserver, _swig_p) - return -} - -func DeleteIDataObserver(arg1 IDataObserver) { - _swig_wrap_delete_IDataObserver(arg1.Swigcptr()) -} - -var _wrap_new_IDataObserver unsafe.Pointer - -func _swig_wrap_new_IDataObserver() (base SwigcptrIDataObserver) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_IDataObserver, _swig_p) - return -} - -func NewIDataObserver() (_swig_ret IDataObserver) { - return _swig_wrap_new_IDataObserver() -} - -type IDataObserver interface { - Swigcptr() uintptr - SwigIsIDataObserver() - DirectorInterface() interface{} -} - -type _swig_DirectorDerivedDataObserver struct { - SwigcptrDerivedDataObserver - v interface{} -} - -func (p *_swig_DirectorDerivedDataObserver) Swigcptr() uintptr { - return p.SwigcptrDerivedDataObserver.Swigcptr() -} - -func (p *_swig_DirectorDerivedDataObserver) SwigIsDerivedDataObserver() { -} - -func (p *_swig_DirectorDerivedDataObserver) DirectorInterface() interface{} { - return p.v -} - -var _wrap__swig_NewDirectorDerivedDataObserverDerivedDataObserver unsafe.Pointer - -func _swig_NewDirectorDerivedDataObserverDerivedDataObserver(_swig_director *_swig_DirectorDerivedDataObserver) (_swig_ret SwigcptrDerivedDataObserver) { - _swig_p := uintptr(unsafe.Pointer(&_swig_director)) - _cgo_runtime_cgocall(_wrap__swig_NewDirectorDerivedDataObserverDerivedDataObserver, _swig_p) - return -} - -func NewDirectorDerivedDataObserver(v interface{}) DerivedDataObserver { - p := &_swig_DirectorDerivedDataObserver{0, v} - p.SwigcptrDerivedDataObserver = _swig_NewDirectorDerivedDataObserverDerivedDataObserver(p) - return p -} - -var _wrap_DeleteDirectorDerivedDataObserver unsafe.Pointer - -func _swig_wrap_DeleteDirectorDerivedDataObserver(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_DeleteDirectorDerivedDataObserver, _swig_p) - return -} - -func DeleteDirectorDerivedDataObserver(arg1 DerivedDataObserver) { - _swig_wrap_DeleteDirectorDerivedDataObserver(arg1.Swigcptr()) -} - -func Swiggo_DeleteDirector_DerivedDataObserver(p *_swig_DirectorDerivedDataObserver) { - p.SwigcptrDerivedDataObserver = 0 -} - -type _swig_DirectorInterfaceDerivedDataObserverNotoverloaded interface { - Notoverloaded() -} - -func (swig_p *_swig_DirectorDerivedDataObserver) Notoverloaded() { - if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceDerivedDataObserverNotoverloaded); swig_ok { - swig_g.Notoverloaded() - return - } - panic("call to pure virtual method") -} - -func Swig_DirectorDerivedDataObserver_callback_notoverloaded(p *_swig_DirectorDerivedDataObserver) { - p.Notoverloaded() -} - -type _swig_DirectorInterfaceDerivedDataObserverIsoverloaded__SWIG_0 interface { - Isoverloaded__SWIG_0() -} - -func (swig_p *_swig_DirectorDerivedDataObserver) Isoverloaded__SWIG_0() { - if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceDerivedDataObserverIsoverloaded__SWIG_0); swig_ok { - swig_g.Isoverloaded__SWIG_0() - return - } - panic("call to pure virtual method") -} - -func Swig_DirectorDerivedDataObserver_callback_isoverloaded__SWIG_0(p *_swig_DirectorDerivedDataObserver) { - p.Isoverloaded__SWIG_0() -} - -type _swig_DirectorInterfaceDerivedDataObserverIsoverloaded__SWIG_1 interface { - Isoverloaded__SWIG_1(int) -} - -func (swig_p *_swig_DirectorDerivedDataObserver) Isoverloaded__SWIG_1(i int) { - if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceDerivedDataObserverIsoverloaded__SWIG_1); swig_ok { - swig_g.Isoverloaded__SWIG_1(i) - return - } - panic("call to pure virtual method") -} - -func Swig_DirectorDerivedDataObserver_callback_isoverloaded__SWIG_1(p *_swig_DirectorDerivedDataObserver, i int) { - p.Isoverloaded__SWIG_1(i) -} - -type _swig_DirectorInterfaceDerivedDataObserverIsoverloaded__SWIG_2 interface { - Isoverloaded__SWIG_2(int, float64) -} - -func (swig_p *_swig_DirectorDerivedDataObserver) Isoverloaded__SWIG_2(i int, d float64) { - if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceDerivedDataObserverIsoverloaded__SWIG_2); swig_ok { - swig_g.Isoverloaded__SWIG_2(i, d) - return - } - panic("call to pure virtual method") -} - -func Swig_DirectorDerivedDataObserver_callback_isoverloaded__SWIG_2(p *_swig_DirectorDerivedDataObserver, i int, d float64) { - p.Isoverloaded__SWIG_2(i, d) -} - -func (p _swig_DirectorDerivedDataObserver) Isoverloaded(a ...interface{}) { - argc := len(a) - if argc == 0 { - p.Isoverloaded__SWIG_0() - return - } - if argc == 1 { - p.Isoverloaded__SWIG_1(a[0].(int)) - return - } - if argc == 2 { - p.Isoverloaded__SWIG_2(a[0].(int), a[1].(float64)) - return - } - panic("No match for overloaded function call") -} - -type SwigcptrDerivedDataObserver uintptr - -func (p SwigcptrDerivedDataObserver) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrDerivedDataObserver) SwigIsDerivedDataObserver() { -} - -func (p SwigcptrDerivedDataObserver) DirectorInterface() interface{} { - return nil -} - -var _wrap_new_DerivedDataObserver unsafe.Pointer - -func _swig_wrap_new_DerivedDataObserver() (base SwigcptrDerivedDataObserver) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_DerivedDataObserver, _swig_p) - return -} - -func NewDerivedDataObserver() (_swig_ret DerivedDataObserver) { - return _swig_wrap_new_DerivedDataObserver() -} - -var _wrap_delete_DerivedDataObserver unsafe.Pointer - -func _swig_wrap_delete_DerivedDataObserver(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_DerivedDataObserver, _swig_p) - return -} - -func DeleteDerivedDataObserver(arg1 DerivedDataObserver) { - _swig_wrap_delete_DerivedDataObserver(arg1.Swigcptr()) -} - -func (p SwigcptrDerivedDataObserver) SwigIsIDataObserver() { -} - -func (p SwigcptrDerivedDataObserver) SwigGetIDataObserver() IDataObserver { - return SwigcptrIDataObserver(p.Swigcptr()) -} - -type DerivedDataObserver interface { - Swigcptr() uintptr - SwigIsDerivedDataObserver() - DirectorInterface() interface{} - SwigIsIDataObserver() - SwigGetIDataObserver() IDataObserver -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/director_protected_overloaded_wrap.h b/Examples/test-suite/go/director_protected_overloaded_wrap.h deleted file mode 100644 index 03d05cadd..000000000 --- a/Examples/test-suite/go/director_protected_overloaded_wrap.h +++ /dev/null @@ -1,42 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../director_protected_overloaded.i - -#ifndef SWIG_director_protected_overloaded_WRAP_H_ -#define SWIG_director_protected_overloaded_WRAP_H_ - -class SwigDirector_IDataObserver : public IDataObserver -{ - public: - SwigDirector_IDataObserver(void *swig_p); - virtual ~SwigDirector_IDataObserver(); - virtual void notoverloaded(); - virtual void isoverloaded(); - virtual void isoverloaded(int i); - virtual void isoverloaded(int i, double d); - private: - void *go_val; -}; - -class SwigDirector_DerivedDataObserver : public DerivedDataObserver -{ - public: - SwigDirector_DerivedDataObserver(void *swig_p); - virtual ~SwigDirector_DerivedDataObserver(); - virtual void notoverloaded(); - virtual void isoverloaded(); - virtual void isoverloaded(int i); - virtual void isoverloaded(int i, double d); - private: - void *go_val; -}; - -#endif diff --git a/Examples/test-suite/go/director_protected_runme b/Examples/test-suite/go/director_protected_runme deleted file mode 100755 index 3cd60841c..000000000 Binary files a/Examples/test-suite/go/director_protected_runme and /dev/null differ diff --git a/Examples/test-suite/go/director_protected_wrap.h b/Examples/test-suite/go/director_protected_wrap.h deleted file mode 100644 index ce845aa39..000000000 --- a/Examples/test-suite/go/director_protected_wrap.h +++ /dev/null @@ -1,97 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../director_protected.i - -#ifndef SWIG_director_protected_WRAP_H_ -#define SWIG_director_protected_WRAP_H_ - -class SwigDirector_Foo : public Foo -{ - public: - SwigDirector_Foo(void *swig_p); - virtual ~SwigDirector_Foo(); - std::string _swig_upcall_pong() { - return Foo::pong(); - } - virtual std::string pong(); - virtual std::string ping(); - std::string _swig_upcall_pang() { - return Foo::pang(); - } - virtual std::string pang(); - std::string _swig_upcall_used() { - return Foo::used(); - } - virtual std::string used(); - std::string _swig_upcall_cheer() { - return Foo::cheer(); - } - virtual std::string cheer(); - private: - void *go_val; -}; - -class SwigDirector_Bar : public Bar -{ - public: - SwigDirector_Bar(void *swig_p); - virtual ~SwigDirector_Bar(); - std::string _swig_upcall_pong() { - return Bar::pong(); - } - virtual std::string pong(); - std::string _swig_upcall_ping() { - return Bar::ping(); - } - virtual std::string ping(); - std::string _swig_upcall_pang() { - return Foo::pang(); - } - virtual std::string pang(); - std::string _swig_upcall_used() { - return Bar::used(); - } - virtual std::string used(); - std::string _swig_upcall_cheer() { - return Bar::cheer(); - } - virtual std::string cheer(); - private: - void *go_val; -}; - -class SwigDirector_A : public A -{ - public: - SwigDirector_A(void *swig_p); - virtual ~SwigDirector_A(); - void _swig_upcall_draw() { - A::draw(); - } - virtual void draw(); - private: - void *go_val; -}; - -class SwigDirector_B : public B -{ - public: - SwigDirector_B(void *swig_p); - virtual ~SwigDirector_B(); - void _swig_upcall_draw() { - B::draw(); - } - virtual void draw(); - private: - void *go_val; -}; - -#endif diff --git a/Examples/test-suite/go/director_redefined.go b/Examples/test-suite/go/director_redefined.go deleted file mode 100644 index c3130ec03..000000000 --- a/Examples/test-suite/go/director_redefined.go +++ /dev/null @@ -1,312 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../director_redefined.i - -package director_redefined - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrA uintptr - -func (p SwigcptrA) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrA) SwigIsA() { -} - -var _wrap_delete_A unsafe.Pointer - -func _swig_wrap_delete_A(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_A, _swig_p) - return -} - -func DeleteA(arg1 A) { - _swig_wrap_delete_A(arg1.Swigcptr()) -} - -var _wrap_A_get_val unsafe.Pointer - -func _swig_wrap_A_get_val(base SwigcptrA, _ int) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_A_get_val, _swig_p) - return -} - -func (arg1 SwigcptrA) Get_val(arg2 int) (_swig_ret int) { - return _swig_wrap_A_get_val(arg1, arg2) -} - -var _wrap_A_get_rval unsafe.Pointer - -func _swig_wrap_A_get_rval(base SwigcptrA, _ int) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_A_get_rval, _swig_p) - return -} - -func (arg1 SwigcptrA) Get_rval(arg2 int) (_swig_ret int) { - return _swig_wrap_A_get_rval(arg1, arg2) -} - -var _wrap_new_A unsafe.Pointer - -func _swig_wrap_new_A() (base SwigcptrA) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_A, _swig_p) - return -} - -func NewA() (_swig_ret A) { - return _swig_wrap_new_A() -} - -type A interface { - Swigcptr() uintptr - SwigIsA() - Get_val(arg2 int) (_swig_ret int) - Get_rval(arg2 int) (_swig_ret int) -} - -type _swig_DirectorB struct { - SwigcptrB - v interface{} -} - -func (p *_swig_DirectorB) Swigcptr() uintptr { - return p.SwigcptrB.Swigcptr() -} - -func (p *_swig_DirectorB) SwigIsB() { -} - -func (p *_swig_DirectorB) DirectorInterface() interface{} { - return p.v -} - -var _wrap__swig_NewDirectorBB unsafe.Pointer - -func _swig_NewDirectorBB(_swig_director *_swig_DirectorB) (_swig_ret SwigcptrB) { - _swig_p := uintptr(unsafe.Pointer(&_swig_director)) - _cgo_runtime_cgocall(_wrap__swig_NewDirectorBB, _swig_p) - return -} - -func NewDirectorB(v interface{}) B { - p := &_swig_DirectorB{0, v} - p.SwigcptrB = _swig_NewDirectorBB(p) - return p -} - -var _wrap_DeleteDirectorB unsafe.Pointer - -func _swig_wrap_DeleteDirectorB(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_DeleteDirectorB, _swig_p) - return -} - -func DeleteDirectorB(arg1 B) { - _swig_wrap_DeleteDirectorB(arg1.Swigcptr()) -} - -func Swiggo_DeleteDirector_B(p *_swig_DirectorB) { - p.SwigcptrB = 0 -} - -type _swig_DirectorInterfaceBGet_val interface { - Get_val(int) int -} - -var _wrap__swig_DirectorB_upcall_Get_val unsafe.Pointer - -func _swig_wrap__swig_DirectorB_upcall_Get_val(_swig_ptr SwigcptrB, _ int) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) - _cgo_runtime_cgocall(_wrap__swig_DirectorB_upcall_Get_val, _swig_p) - return -} - -func (swig_p *_swig_DirectorB) Get_val(a int) int { - if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceBGet_val); swig_ok { - return swig_g.Get_val(a) - } - var swig_r int - swig_r = _swig_wrap__swig_DirectorB_upcall_Get_val(swig_p.SwigcptrB, a) - return swig_r -} - -func DirectorBGet_val(p B, arg2 int) int { - var swig_r int - swig_r = _swig_wrap__swig_DirectorB_upcall_Get_val(p.(*_swig_DirectorB).SwigcptrB, arg2) - return swig_r -} - -func Swig_DirectorB_callback_get_val(p *_swig_DirectorB, arg2 int) (swig_result int) { - var swig_r int - swig_r = p.Get_val(arg2) - return swig_r -} - -type _swig_DirectorInterfaceBGet_rval interface { - Get_rval(int) int -} - -var _wrap__swig_DirectorB_upcall_Get_rval unsafe.Pointer - -func _swig_wrap__swig_DirectorB_upcall_Get_rval(_swig_ptr SwigcptrB, _ int) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) - _cgo_runtime_cgocall(_wrap__swig_DirectorB_upcall_Get_rval, _swig_p) - return -} - -func (swig_p *_swig_DirectorB) Get_rval(a int) int { - if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceBGet_rval); swig_ok { - return swig_g.Get_rval(a) - } - var swig_r int - swig_r = _swig_wrap__swig_DirectorB_upcall_Get_rval(swig_p.SwigcptrB, a) - return swig_r -} - -func DirectorBGet_rval(p B, arg2 int) int { - var swig_r int - swig_r = _swig_wrap__swig_DirectorB_upcall_Get_rval(p.(*_swig_DirectorB).SwigcptrB, arg2) - return swig_r -} - -func Swig_DirectorB_callback_get_rval(p *_swig_DirectorB, arg2 int) (swig_result int) { - var swig_r int - swig_r = p.Get_rval(arg2) - return swig_r -} - -type SwigcptrB uintptr - -func (p SwigcptrB) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrB) SwigIsB() { -} - -func (p SwigcptrB) DirectorInterface() interface{} { - return nil -} - -var _wrap_B_get_val unsafe.Pointer - -func _swig_wrap_B_get_val(base SwigcptrB, _ int) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_B_get_val, _swig_p) - return -} - -func (arg1 SwigcptrB) Get_val(arg2 int) (_swig_ret int) { - return _swig_wrap_B_get_val(arg1, arg2) -} - -var _wrap_B_get_rval unsafe.Pointer - -func _swig_wrap_B_get_rval(base SwigcptrB, _ int) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_B_get_rval, _swig_p) - return -} - -func (arg1 SwigcptrB) Get_rval(arg2 int) (_swig_ret int) { - return _swig_wrap_B_get_rval(arg1, arg2) -} - -var _wrap_B_get_rrval unsafe.Pointer - -func _swig_wrap_B_get_rrval(base SwigcptrB, _ int) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_B_get_rrval, _swig_p) - return -} - -func (arg1 SwigcptrB) Get_rrval(arg2 int) (_swig_ret int) { - return _swig_wrap_B_get_rrval(arg1, arg2) -} - -var _wrap_new_B unsafe.Pointer - -func _swig_wrap_new_B() (base SwigcptrB) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_B, _swig_p) - return -} - -func NewB() (_swig_ret B) { - return _swig_wrap_new_B() -} - -var _wrap_delete_B unsafe.Pointer - -func _swig_wrap_delete_B(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_B, _swig_p) - return -} - -func DeleteB(arg1 B) { - _swig_wrap_delete_B(arg1.Swigcptr()) -} - -func (p SwigcptrB) SwigIsA() { -} - -func (p SwigcptrB) SwigGetA() A { - return SwigcptrA(p.Swigcptr()) -} - -type B interface { - Swigcptr() uintptr - SwigIsB() - DirectorInterface() interface{} - Get_val(arg2 int) (_swig_ret int) - Get_rval(arg2 int) (_swig_ret int) - Get_rrval(arg2 int) (_swig_ret int) - SwigIsA() - SwigGetA() A -} - - -type SwigcptrSwigDirector_B uintptr -type SwigDirector_B interface { - Swigcptr() uintptr; -} -func (p SwigcptrSwigDirector_B) Swigcptr() uintptr { - return uintptr(p) -} - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/director_redefined_wrap.h b/Examples/test-suite/go/director_redefined_wrap.h deleted file mode 100644 index 4f09ba805..000000000 --- a/Examples/test-suite/go/director_redefined_wrap.h +++ /dev/null @@ -1,33 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../director_redefined.i - -#ifndef SWIG_director_redefined_WRAP_H_ -#define SWIG_director_redefined_WRAP_H_ - -class SwigDirector_B : public B -{ - public: - SwigDirector_B(void *swig_p); - virtual ~SwigDirector_B(); - int _swig_upcall_get_val(int a) { - return B::get_val(a); - } - virtual int get_val(int a); - int _swig_upcall_get_rval(int const &a) { - return B::get_rval(a); - } - virtual int get_rval(int const &a); - private: - void *go_val; -}; - -#endif diff --git a/Examples/test-suite/go/director_smartptr.go b/Examples/test-suite/go/director_smartptr.go deleted file mode 100644 index 6f5a7a0c5..000000000 --- a/Examples/test-suite/go/director_smartptr.go +++ /dev/null @@ -1,29 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../director_smartptr.i - -package director_smartptr - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - - diff --git a/Examples/test-suite/go/director_smartptr_wrap.h b/Examples/test-suite/go/director_smartptr_wrap.h deleted file mode 100644 index 95dd9470d..000000000 --- a/Examples/test-suite/go/director_smartptr_wrap.h +++ /dev/null @@ -1,16 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../director_smartptr.i - -#ifndef SWIG_director_smartptr_WRAP_H_ -#define SWIG_director_smartptr_WRAP_H_ - -#endif diff --git a/Examples/test-suite/go/director_string.go b/Examples/test-suite/go/director_string.go deleted file mode 100644 index c0d6f178b..000000000 --- a/Examples/test-suite/go/director_string.go +++ /dev/null @@ -1,609 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../director_string.i - -package director_string - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type _swig_DirectorA struct { - SwigcptrA - v interface{} -} - -func (p *_swig_DirectorA) Swigcptr() uintptr { - return p.SwigcptrA.Swigcptr() -} - -func (p *_swig_DirectorA) SwigIsA() { -} - -func (p *_swig_DirectorA) DirectorInterface() interface{} { - return p.v -} - -var _wrap__swig_NewDirectorAA unsafe.Pointer - -func _swig_NewDirectorAA(_swig_director *_swig_DirectorA, _ string) (_swig_ret SwigcptrA) { - _swig_p := uintptr(unsafe.Pointer(&_swig_director)) - _cgo_runtime_cgocall(_wrap__swig_NewDirectorAA, _swig_p) - return -} - -func NewDirectorA(v interface{}, arg1 string) A { - p := &_swig_DirectorA{0, v} - p.SwigcptrA = _swig_NewDirectorAA(p, arg1) - return p -} - -var _wrap_DeleteDirectorA unsafe.Pointer - -func _swig_wrap_DeleteDirectorA(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_DeleteDirectorA, _swig_p) - return -} - -func DeleteDirectorA(arg1 A) { - _swig_wrap_DeleteDirectorA(arg1.Swigcptr()) -} - -func Swiggo_DeleteDirector_A(p *_swig_DirectorA) { - p.SwigcptrA = 0 -} - -type _swig_DirectorInterfaceAGet_first interface { - Get_first() string -} - -var _wrap__swig_DirectorA_upcall_Get_first unsafe.Pointer - -func _swig_wrap__swig_DirectorA_upcall_Get_first(_swig_ptr SwigcptrA) (_swig_ret string) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) - _cgo_runtime_cgocall(_wrap__swig_DirectorA_upcall_Get_first, _swig_p) - return -} - -func (swig_p *_swig_DirectorA) Get_first() string { - if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceAGet_first); swig_ok { - return swig_g.Get_first() - } - var swig_r string - swig_r = _swig_wrap__swig_DirectorA_upcall_Get_first(swig_p.SwigcptrA) - return swig_r -} - -func DirectorAGet_first(p A) string { - var swig_r string - swig_r = _swig_wrap__swig_DirectorA_upcall_Get_first(p.(*_swig_DirectorA).SwigcptrA) - return swig_r -} - -func Swig_DirectorA_callback_get_first(p *_swig_DirectorA) (swig_result string) { - var swig_r string - swig_r = p.Get_first() - return swig_r -} - -type _swig_DirectorInterfaceAGet interface { - Get(int) string -} - -var _wrap__swig_DirectorA_upcall_Get unsafe.Pointer - -func _swig_wrap__swig_DirectorA_upcall_Get(_swig_ptr SwigcptrA, _ int) (_swig_ret string) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) - _cgo_runtime_cgocall(_wrap__swig_DirectorA_upcall_Get, _swig_p) - return -} - -func (swig_p *_swig_DirectorA) Get(n int) string { - if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceAGet); swig_ok { - return swig_g.Get(n) - } - var swig_r string - swig_r = _swig_wrap__swig_DirectorA_upcall_Get(swig_p.SwigcptrA, n) - return swig_r -} - -func DirectorAGet(p A, arg2 int) string { - var swig_r string - swig_r = _swig_wrap__swig_DirectorA_upcall_Get(p.(*_swig_DirectorA).SwigcptrA, arg2) - return swig_r -} - -func Swig_DirectorA_callback_get(p *_swig_DirectorA, arg2 int) (swig_result string) { - var swig_r string - swig_r = p.Get(arg2) - return swig_r -} - -type _swig_DirectorInterfaceACall_get_first interface { - Call_get_first() string -} - -var _wrap__swig_DirectorA_upcall_Call_get_first unsafe.Pointer - -func _swig_wrap__swig_DirectorA_upcall_Call_get_first(_swig_ptr SwigcptrA) (_swig_ret string) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) - _cgo_runtime_cgocall(_wrap__swig_DirectorA_upcall_Call_get_first, _swig_p) - return -} - -func (swig_p *_swig_DirectorA) Call_get_first() string { - if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceACall_get_first); swig_ok { - return swig_g.Call_get_first() - } - var swig_r string - swig_r = _swig_wrap__swig_DirectorA_upcall_Call_get_first(swig_p.SwigcptrA) - return swig_r -} - -func DirectorACall_get_first(p A) string { - var swig_r string - swig_r = _swig_wrap__swig_DirectorA_upcall_Call_get_first(p.(*_swig_DirectorA).SwigcptrA) - return swig_r -} - -func Swig_DirectorA_callback_call_get_first(p *_swig_DirectorA) (swig_result string) { - var swig_r string - swig_r = p.Call_get_first() - return swig_r -} - -type _swig_DirectorInterfaceACall_get interface { - Call_get(int) string -} - -var _wrap__swig_DirectorA_upcall_Call_get unsafe.Pointer - -func _swig_wrap__swig_DirectorA_upcall_Call_get(_swig_ptr SwigcptrA, _ int) (_swig_ret string) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) - _cgo_runtime_cgocall(_wrap__swig_DirectorA_upcall_Call_get, _swig_p) - return -} - -func (swig_p *_swig_DirectorA) Call_get(n int) string { - if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceACall_get); swig_ok { - return swig_g.Call_get(n) - } - var swig_r string - swig_r = _swig_wrap__swig_DirectorA_upcall_Call_get(swig_p.SwigcptrA, n) - return swig_r -} - -func DirectorACall_get(p A, arg2 int) string { - var swig_r string - swig_r = _swig_wrap__swig_DirectorA_upcall_Call_get(p.(*_swig_DirectorA).SwigcptrA, arg2) - return swig_r -} - -func Swig_DirectorA_callback_call_get(p *_swig_DirectorA, arg2 int) (swig_result string) { - var swig_r string - swig_r = p.Call_get(arg2) - return swig_r -} - -type _swig_DirectorInterfaceAString_length interface { - String_length(string) int -} - -var _wrap__swig_DirectorA_upcall_String_length unsafe.Pointer - -func _swig_wrap__swig_DirectorA_upcall_String_length(_swig_ptr SwigcptrA, _ string) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) - _cgo_runtime_cgocall(_wrap__swig_DirectorA_upcall_String_length, _swig_p) - return -} - -func (swig_p *_swig_DirectorA) String_length(s string) int { - if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceAString_length); swig_ok { - return swig_g.String_length(s) - } - var swig_r int - swig_r = _swig_wrap__swig_DirectorA_upcall_String_length(swig_p.SwigcptrA, s) - return swig_r -} - -func DirectorAString_length(p A, arg2 string) int { - var swig_r int - swig_r = _swig_wrap__swig_DirectorA_upcall_String_length(p.(*_swig_DirectorA).SwigcptrA, arg2) - return swig_r -} - -func Swig_DirectorA_callback_string_length(p *_swig_DirectorA, arg2 string) (swig_result int) { - var swig_r int - swig_r = p.String_length(arg2) - return swig_r -} - -type _swig_DirectorInterfaceAProcess_text interface { - Process_text(string) -} - -var _wrap__swig_DirectorA_upcall_Process_text unsafe.Pointer - -func _swig_wrap__swig_DirectorA_upcall_Process_text(_swig_ptr SwigcptrA, _ string) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) - _cgo_runtime_cgocall(_wrap__swig_DirectorA_upcall_Process_text, _swig_p) - return -} - -func (swig_p *_swig_DirectorA) Process_text(text string) { - if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceAProcess_text); swig_ok { - swig_g.Process_text(text) - return - } - _swig_wrap__swig_DirectorA_upcall_Process_text(swig_p.SwigcptrA, text) -} - -func DirectorAProcess_text(p A, arg2 string) { - _swig_wrap__swig_DirectorA_upcall_Process_text(p.(*_swig_DirectorA).SwigcptrA, arg2) -} - -func Swig_DirectorA_callback_process_text(p *_swig_DirectorA, arg2 string) { - p.Process_text(arg2) -} - -type SwigcptrA uintptr - -func (p SwigcptrA) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrA) SwigIsA() { -} - -func (p SwigcptrA) DirectorInterface() interface{} { - return nil -} - -var _wrap_new_A unsafe.Pointer - -func _swig_wrap_new_A(base string) (_ SwigcptrA) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_A, _swig_p) - return -} - -func NewA(arg1 string) (_swig_ret A) { - return _swig_wrap_new_A(arg1) -} - -var _wrap_delete_A unsafe.Pointer - -func _swig_wrap_delete_A(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_A, _swig_p) - return -} - -func DeleteA(arg1 A) { - _swig_wrap_delete_A(arg1.Swigcptr()) -} - -var _wrap_A_get_first unsafe.Pointer - -func _swig_wrap_A_get_first(base SwigcptrA) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_A_get_first, _swig_p) - return -} - -func (arg1 SwigcptrA) Get_first() (_swig_ret string) { - return _swig_wrap_A_get_first(arg1) -} - -var _wrap_A_get unsafe.Pointer - -func _swig_wrap_A_get(base SwigcptrA, _ int) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_A_get, _swig_p) - return -} - -func (arg1 SwigcptrA) Get(arg2 int) (_swig_ret string) { - return _swig_wrap_A_get(arg1, arg2) -} - -var _wrap_A_call_get_first unsafe.Pointer - -func _swig_wrap_A_call_get_first(base SwigcptrA) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_A_call_get_first, _swig_p) - return -} - -func (arg1 SwigcptrA) Call_get_first() (_swig_ret string) { - return _swig_wrap_A_call_get_first(arg1) -} - -var _wrap_A_call_get unsafe.Pointer - -func _swig_wrap_A_call_get(base SwigcptrA, _ int) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_A_call_get, _swig_p) - return -} - -func (arg1 SwigcptrA) Call_get(arg2 int) (_swig_ret string) { - return _swig_wrap_A_call_get(arg1, arg2) -} - -var _wrap_A_string_length unsafe.Pointer - -func _swig_wrap_A_string_length(base SwigcptrA, _ string) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_A_string_length, _swig_p) - return -} - -func (arg1 SwigcptrA) String_length(arg2 string) (_swig_ret int) { - return _swig_wrap_A_string_length(arg1, arg2) -} - -var _wrap_A_m_strings_set unsafe.Pointer - -func _swig_wrap_A_m_strings_set(base SwigcptrA, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_A_m_strings_set, _swig_p) - return -} - -func (arg1 SwigcptrA) SetM_strings(arg2 StringVector) { - _swig_wrap_A_m_strings_set(arg1, arg2.Swigcptr()) -} - -var _wrap_A_m_strings_get unsafe.Pointer - -func _swig_wrap_A_m_strings_get(base SwigcptrA) (_ SwigcptrStringVector) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_A_m_strings_get, _swig_p) - return -} - -func (arg1 SwigcptrA) GetM_strings() (_swig_ret StringVector) { - return _swig_wrap_A_m_strings_get(arg1) -} - -var _wrap_A_process_text unsafe.Pointer - -func _swig_wrap_A_process_text(base SwigcptrA, _ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_A_process_text, _swig_p) - return -} - -func (arg1 SwigcptrA) Process_text(arg2 string) { - _swig_wrap_A_process_text(arg1, arg2) -} - -var _wrap_A_call_process_func unsafe.Pointer - -func _swig_wrap_A_call_process_func(base SwigcptrA) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_A_call_process_func, _swig_p) - return -} - -func (arg1 SwigcptrA) Call_process_func() { - _swig_wrap_A_call_process_func(arg1) -} - -type A interface { - Swigcptr() uintptr - SwigIsA() - DirectorInterface() interface{} - Get_first() (_swig_ret string) - Get(arg2 int) (_swig_ret string) - Call_get_first() (_swig_ret string) - Call_get(arg2 int) (_swig_ret string) - String_length(arg2 string) (_swig_ret int) - SetM_strings(arg2 StringVector) - GetM_strings() (_swig_ret StringVector) - Process_text(arg2 string) - Call_process_func() -} - -type SwigcptrStringVector uintptr - -func (p SwigcptrStringVector) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrStringVector) SwigIsStringVector() { -} - -var _wrap_new_StringVector__SWIG_0 unsafe.Pointer - -func _swig_wrap_new_StringVector__SWIG_0() (base SwigcptrStringVector) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_StringVector__SWIG_0, _swig_p) - return -} - -func NewStringVector__SWIG_0() (_swig_ret StringVector) { - return _swig_wrap_new_StringVector__SWIG_0() -} - -var _wrap_new_StringVector__SWIG_1 unsafe.Pointer - -func _swig_wrap_new_StringVector__SWIG_1(base int64) (_ SwigcptrStringVector) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_StringVector__SWIG_1, _swig_p) - return -} - -func NewStringVector__SWIG_1(arg1 int64) (_swig_ret StringVector) { - return _swig_wrap_new_StringVector__SWIG_1(arg1) -} - -func NewStringVector(a ...interface{}) StringVector { - argc := len(a) - if argc == 0 { - return NewStringVector__SWIG_0() - } - if argc == 1 { - return NewStringVector__SWIG_1(a[0].(int64)) - } - panic("No match for overloaded function call") -} - -var _wrap_StringVector_size unsafe.Pointer - -func _swig_wrap_StringVector_size(base SwigcptrStringVector) (_ int64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_StringVector_size, _swig_p) - return -} - -func (arg1 SwigcptrStringVector) Size() (_swig_ret int64) { - return _swig_wrap_StringVector_size(arg1) -} - -var _wrap_StringVector_capacity unsafe.Pointer - -func _swig_wrap_StringVector_capacity(base SwigcptrStringVector) (_ int64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_StringVector_capacity, _swig_p) - return -} - -func (arg1 SwigcptrStringVector) Capacity() (_swig_ret int64) { - return _swig_wrap_StringVector_capacity(arg1) -} - -var _wrap_StringVector_reserve unsafe.Pointer - -func _swig_wrap_StringVector_reserve(base SwigcptrStringVector, _ int64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_StringVector_reserve, _swig_p) - return -} - -func (arg1 SwigcptrStringVector) Reserve(arg2 int64) { - _swig_wrap_StringVector_reserve(arg1, arg2) -} - -var _wrap_StringVector_isEmpty unsafe.Pointer - -func _swig_wrap_StringVector_isEmpty(base SwigcptrStringVector) (_ bool) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_StringVector_isEmpty, _swig_p) - return -} - -func (arg1 SwigcptrStringVector) IsEmpty() (_swig_ret bool) { - return _swig_wrap_StringVector_isEmpty(arg1) -} - -var _wrap_StringVector_clear unsafe.Pointer - -func _swig_wrap_StringVector_clear(base SwigcptrStringVector) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_StringVector_clear, _swig_p) - return -} - -func (arg1 SwigcptrStringVector) Clear() { - _swig_wrap_StringVector_clear(arg1) -} - -var _wrap_StringVector_add unsafe.Pointer - -func _swig_wrap_StringVector_add(base SwigcptrStringVector, _ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_StringVector_add, _swig_p) - return -} - -func (arg1 SwigcptrStringVector) Add(arg2 string) { - _swig_wrap_StringVector_add(arg1, arg2) -} - -var _wrap_StringVector_get unsafe.Pointer - -func _swig_wrap_StringVector_get(base SwigcptrStringVector, _ int) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_StringVector_get, _swig_p) - return -} - -func (arg1 SwigcptrStringVector) Get(arg2 int) (_swig_ret string) { - return _swig_wrap_StringVector_get(arg1, arg2) -} - -var _wrap_StringVector_set unsafe.Pointer - -func _swig_wrap_StringVector_set(base SwigcptrStringVector, _ int, _ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_StringVector_set, _swig_p) - return -} - -func (arg1 SwigcptrStringVector) Set(arg2 int, arg3 string) { - _swig_wrap_StringVector_set(arg1, arg2, arg3) -} - -var _wrap_delete_StringVector unsafe.Pointer - -func _swig_wrap_delete_StringVector(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_StringVector, _swig_p) - return -} - -func DeleteStringVector(arg1 StringVector) { - _swig_wrap_delete_StringVector(arg1.Swigcptr()) -} - -type StringVector interface { - Swigcptr() uintptr - SwigIsStringVector() - Size() (_swig_ret int64) - Capacity() (_swig_ret int64) - Reserve(arg2 int64) - IsEmpty() (_swig_ret bool) - Clear() - Add(arg2 string) - Get(arg2 int) (_swig_ret string) - Set(arg2 int, arg3 string) -} - - -type SwigcptrSwigDirector_A uintptr -type SwigDirector_A interface { - Swigcptr() uintptr; -} -func (p SwigcptrSwigDirector_A) Swigcptr() uintptr { - return uintptr(p) -} - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/director_string_runme b/Examples/test-suite/go/director_string_runme deleted file mode 100755 index ece4678ea..000000000 Binary files a/Examples/test-suite/go/director_string_runme and /dev/null differ diff --git a/Examples/test-suite/go/director_string_wrap.h b/Examples/test-suite/go/director_string_wrap.h deleted file mode 100644 index 73a6e6e5f..000000000 --- a/Examples/test-suite/go/director_string_wrap.h +++ /dev/null @@ -1,49 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../director_string.i - -#ifndef SWIG_director_string_WRAP_H_ -#define SWIG_director_string_WRAP_H_ - -class SwigDirector_A : public A -{ - public: - SwigDirector_A(void *swig_p, std::string const &first); - virtual ~SwigDirector_A(); - std::string const &_swig_upcall_get_first() const { - return A::get_first(); - } - virtual std::string const &get_first() const; - std::string const &_swig_upcall_get(int n) const { - return A::get(n); - } - virtual std::string const &get(int n) const; - std::string const &_swig_upcall_call_get_first() const { - return A::call_get_first(); - } - virtual std::string const &call_get_first() const; - std::string const &_swig_upcall_call_get(int n) const { - return A::call_get(n); - } - virtual std::string const &call_get(int n) const; - int _swig_upcall_string_length(std::string const &s) const { - return A::string_length(s); - } - virtual int string_length(std::string const &s) const; - void _swig_upcall_process_text(char const *text) { - A::process_text(text); - } - virtual void process_text(char const *text); - private: - void *go_val; -}; - -#endif diff --git a/Examples/test-suite/go/director_thread.go b/Examples/test-suite/go/director_thread.go deleted file mode 100644 index 13efccf57..000000000 --- a/Examples/test-suite/go/director_thread.go +++ /dev/null @@ -1,239 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../director_thread.i - -package director_thread - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -var _wrap_MilliSecondSleep unsafe.Pointer - -func _swig_wrap_MilliSecondSleep(base int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_MilliSecondSleep, _swig_p) - return -} - -func MilliSecondSleep(arg1 int) { - _swig_wrap_MilliSecondSleep(arg1) -} - -type _swig_DirectorFoo struct { - SwigcptrFoo - v interface{} -} - -func (p *_swig_DirectorFoo) Swigcptr() uintptr { - return p.SwigcptrFoo.Swigcptr() -} - -func (p *_swig_DirectorFoo) SwigIsFoo() { -} - -func (p *_swig_DirectorFoo) DirectorInterface() interface{} { - return p.v -} - -var _wrap__swig_NewDirectorFooFoo unsafe.Pointer - -func _swig_NewDirectorFooFoo(_swig_director *_swig_DirectorFoo) (_swig_ret SwigcptrFoo) { - _swig_p := uintptr(unsafe.Pointer(&_swig_director)) - _cgo_runtime_cgocall(_wrap__swig_NewDirectorFooFoo, _swig_p) - return -} - -func NewDirectorFoo(v interface{}) Foo { - p := &_swig_DirectorFoo{0, v} - p.SwigcptrFoo = _swig_NewDirectorFooFoo(p) - return p -} - -var _wrap_DeleteDirectorFoo unsafe.Pointer - -func _swig_wrap_DeleteDirectorFoo(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_DeleteDirectorFoo, _swig_p) - return -} - -func DeleteDirectorFoo(arg1 Foo) { - _swig_wrap_DeleteDirectorFoo(arg1.Swigcptr()) -} - -func Swiggo_DeleteDirector_Foo(p *_swig_DirectorFoo) { - p.SwigcptrFoo = 0 -} - -type _swig_DirectorInterfaceFooDo_foo interface { - Do_foo() -} - -var _wrap__swig_DirectorFoo_upcall_Do_foo unsafe.Pointer - -func _swig_wrap__swig_DirectorFoo_upcall_Do_foo(_swig_ptr SwigcptrFoo) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) - _cgo_runtime_cgocall(_wrap__swig_DirectorFoo_upcall_Do_foo, _swig_p) - return -} - -func (swig_p *_swig_DirectorFoo) Do_foo() { - if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceFooDo_foo); swig_ok { - swig_g.Do_foo() - return - } - _swig_wrap__swig_DirectorFoo_upcall_Do_foo(swig_p.SwigcptrFoo) -} - -func DirectorFooDo_foo(p Foo) { - _swig_wrap__swig_DirectorFoo_upcall_Do_foo(p.(*_swig_DirectorFoo).SwigcptrFoo) -} - -func Swig_DirectorFoo_callback_do_foo(p *_swig_DirectorFoo) { - p.Do_foo() -} - -type SwigcptrFoo uintptr - -func (p SwigcptrFoo) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrFoo) SwigIsFoo() { -} - -func (p SwigcptrFoo) DirectorInterface() interface{} { - return nil -} - -var _wrap_Foo_val_set unsafe.Pointer - -func _swig_wrap_Foo_val_set(base SwigcptrFoo, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_val_set, _swig_p) - return -} - -func (arg1 SwigcptrFoo) SetVal(arg2 int) { - _swig_wrap_Foo_val_set(arg1, arg2) -} - -var _wrap_Foo_val_get unsafe.Pointer - -func _swig_wrap_Foo_val_get(base SwigcptrFoo) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_val_get, _swig_p) - return -} - -func (arg1 SwigcptrFoo) GetVal() (_swig_ret int) { - return _swig_wrap_Foo_val_get(arg1) -} - -var _wrap_new_Foo unsafe.Pointer - -func _swig_wrap_new_Foo() (base SwigcptrFoo) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Foo, _swig_p) - return -} - -func NewFoo() (_swig_ret Foo) { - return _swig_wrap_new_Foo() -} - -var _wrap_delete_Foo unsafe.Pointer - -func _swig_wrap_delete_Foo(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Foo, _swig_p) - return -} - -func DeleteFoo(arg1 Foo) { - _swig_wrap_delete_Foo(arg1.Swigcptr()) -} - -var _wrap_Foo_stop unsafe.Pointer - -func _swig_wrap_Foo_stop(base SwigcptrFoo) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_stop, _swig_p) - return -} - -func (arg1 SwigcptrFoo) Stop() { - _swig_wrap_Foo_stop(arg1) -} - -var _wrap_Foo_run unsafe.Pointer - -func _swig_wrap_Foo_run(base SwigcptrFoo) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_run, _swig_p) - return -} - -func (arg1 SwigcptrFoo) Run() { - _swig_wrap_Foo_run(arg1) -} - -var _wrap_Foo_do_foo unsafe.Pointer - -func _swig_wrap_Foo_do_foo(base SwigcptrFoo) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_do_foo, _swig_p) - return -} - -func (arg1 SwigcptrFoo) Do_foo() { - _swig_wrap_Foo_do_foo(arg1) -} - -type Foo interface { - Swigcptr() uintptr - SwigIsFoo() - DirectorInterface() interface{} - SetVal(arg2 int) - GetVal() (_swig_ret int) - Stop() - Run() - Do_foo() -} - - -type SwigcptrSwigDirector_Foo uintptr -type SwigDirector_Foo interface { - Swigcptr() uintptr; -} -func (p SwigcptrSwigDirector_Foo) Swigcptr() uintptr { - return uintptr(p) -} - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/director_thread_wrap.h b/Examples/test-suite/go/director_thread_wrap.h deleted file mode 100644 index 14e4d51a7..000000000 --- a/Examples/test-suite/go/director_thread_wrap.h +++ /dev/null @@ -1,29 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../director_thread.i - -#ifndef SWIG_director_thread_WRAP_H_ -#define SWIG_director_thread_WRAP_H_ - -class SwigDirector_Foo : public Foo -{ - public: - SwigDirector_Foo(void *swig_p); - virtual ~SwigDirector_Foo(); - void _swig_upcall_do_foo() { - Foo::do_foo(); - } - virtual void do_foo(); - private: - void *go_val; -}; - -#endif diff --git a/Examples/test-suite/go/director_unroll.go b/Examples/test-suite/go/director_unroll.go deleted file mode 100644 index bd07ce74f..000000000 --- a/Examples/test-suite/go/director_unroll.go +++ /dev/null @@ -1,290 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../director_unroll.i - -package director_unroll - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type _swig_DirectorFoo struct { - SwigcptrFoo - v interface{} -} - -func (p *_swig_DirectorFoo) Swigcptr() uintptr { - return p.SwigcptrFoo.Swigcptr() -} - -func (p *_swig_DirectorFoo) SwigIsFoo() { -} - -func (p *_swig_DirectorFoo) DirectorInterface() interface{} { - return p.v -} - -var _wrap__swig_NewDirectorFooFoo unsafe.Pointer - -func _swig_NewDirectorFooFoo(_swig_director *_swig_DirectorFoo) (_swig_ret SwigcptrFoo) { - _swig_p := uintptr(unsafe.Pointer(&_swig_director)) - _cgo_runtime_cgocall(_wrap__swig_NewDirectorFooFoo, _swig_p) - return -} - -func NewDirectorFoo(v interface{}) Foo { - p := &_swig_DirectorFoo{0, v} - p.SwigcptrFoo = _swig_NewDirectorFooFoo(p) - return p -} - -var _wrap_DeleteDirectorFoo unsafe.Pointer - -func _swig_wrap_DeleteDirectorFoo(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_DeleteDirectorFoo, _swig_p) - return -} - -func DeleteDirectorFoo(arg1 Foo) { - _swig_wrap_DeleteDirectorFoo(arg1.Swigcptr()) -} - -func Swiggo_DeleteDirector_Foo(p *_swig_DirectorFoo) { - p.SwigcptrFoo = 0 -} - -type _swig_DirectorInterfaceFooPing interface { - Ping() string -} - -var _wrap__swig_DirectorFoo_upcall_Ping unsafe.Pointer - -func _swig_wrap__swig_DirectorFoo_upcall_Ping(_swig_ptr SwigcptrFoo) (_swig_ret string) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) - _cgo_runtime_cgocall(_wrap__swig_DirectorFoo_upcall_Ping, _swig_p) - return -} - -func (swig_p *_swig_DirectorFoo) Ping() string { - if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceFooPing); swig_ok { - return swig_g.Ping() - } - var swig_r string - swig_r = _swig_wrap__swig_DirectorFoo_upcall_Ping(swig_p.SwigcptrFoo) - return swig_r -} - -func DirectorFooPing(p Foo) string { - var swig_r string - swig_r = _swig_wrap__swig_DirectorFoo_upcall_Ping(p.(*_swig_DirectorFoo).SwigcptrFoo) - return swig_r -} - -func Swig_DirectorFoo_callback_ping(p *_swig_DirectorFoo) (swig_result string) { - var swig_r string - swig_r = p.Ping() - return swig_r -} - -type _swig_DirectorInterfaceFooPong interface { - Pong() string -} - -var _wrap__swig_DirectorFoo_upcall_Pong unsafe.Pointer - -func _swig_wrap__swig_DirectorFoo_upcall_Pong(_swig_ptr SwigcptrFoo) (_swig_ret string) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) - _cgo_runtime_cgocall(_wrap__swig_DirectorFoo_upcall_Pong, _swig_p) - return -} - -func (swig_p *_swig_DirectorFoo) Pong() string { - if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceFooPong); swig_ok { - return swig_g.Pong() - } - var swig_r string - swig_r = _swig_wrap__swig_DirectorFoo_upcall_Pong(swig_p.SwigcptrFoo) - return swig_r -} - -func DirectorFooPong(p Foo) string { - var swig_r string - swig_r = _swig_wrap__swig_DirectorFoo_upcall_Pong(p.(*_swig_DirectorFoo).SwigcptrFoo) - return swig_r -} - -func Swig_DirectorFoo_callback_pong(p *_swig_DirectorFoo) (swig_result string) { - var swig_r string - swig_r = p.Pong() - return swig_r -} - -type SwigcptrFoo uintptr - -func (p SwigcptrFoo) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrFoo) SwigIsFoo() { -} - -func (p SwigcptrFoo) DirectorInterface() interface{} { - return nil -} - -var _wrap_delete_Foo unsafe.Pointer - -func _swig_wrap_delete_Foo(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Foo, _swig_p) - return -} - -func DeleteFoo(arg1 Foo) { - _swig_wrap_delete_Foo(arg1.Swigcptr()) -} - -var _wrap_Foo_ping unsafe.Pointer - -func _swig_wrap_Foo_ping(base SwigcptrFoo) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_ping, _swig_p) - return -} - -func (arg1 SwigcptrFoo) Ping() (_swig_ret string) { - return _swig_wrap_Foo_ping(arg1) -} - -var _wrap_Foo_pong unsafe.Pointer - -func _swig_wrap_Foo_pong(base SwigcptrFoo) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_pong, _swig_p) - return -} - -func (arg1 SwigcptrFoo) Pong() (_swig_ret string) { - return _swig_wrap_Foo_pong(arg1) -} - -var _wrap_new_Foo unsafe.Pointer - -func _swig_wrap_new_Foo() (base SwigcptrFoo) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Foo, _swig_p) - return -} - -func NewFoo() (_swig_ret Foo) { - return _swig_wrap_new_Foo() -} - -type Foo interface { - Swigcptr() uintptr - SwigIsFoo() - DirectorInterface() interface{} - Ping() (_swig_ret string) - Pong() (_swig_ret string) -} - -type SwigcptrBar uintptr - -func (p SwigcptrBar) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrBar) SwigIsBar() { -} - -var _wrap_Bar_set unsafe.Pointer - -func _swig_wrap_Bar_set(base SwigcptrBar, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Bar_set, _swig_p) - return -} - -func (arg1 SwigcptrBar) Set(arg2 Foo) { - _swig_wrap_Bar_set(arg1, arg2.Swigcptr()) -} - -var _wrap_Bar_get unsafe.Pointer - -func _swig_wrap_Bar_get(base SwigcptrBar) (_ SwigcptrFoo) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Bar_get, _swig_p) - return -} - -func (arg1 SwigcptrBar) Get() (_swig_ret Foo) { - return _swig_wrap_Bar_get(arg1) -} - -var _wrap_new_Bar unsafe.Pointer - -func _swig_wrap_new_Bar() (base SwigcptrBar) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Bar, _swig_p) - return -} - -func NewBar() (_swig_ret Bar) { - return _swig_wrap_new_Bar() -} - -var _wrap_delete_Bar unsafe.Pointer - -func _swig_wrap_delete_Bar(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Bar, _swig_p) - return -} - -func DeleteBar(arg1 Bar) { - _swig_wrap_delete_Bar(arg1.Swigcptr()) -} - -type Bar interface { - Swigcptr() uintptr - SwigIsBar() - Set(arg2 Foo) - Get() (_swig_ret Foo) -} - - -type SwigcptrSwigDirector_Foo uintptr -type SwigDirector_Foo interface { - Swigcptr() uintptr; -} -func (p SwigcptrSwigDirector_Foo) Swigcptr() uintptr { - return uintptr(p) -} - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/director_unroll_runme b/Examples/test-suite/go/director_unroll_runme deleted file mode 100755 index e58b74644..000000000 Binary files a/Examples/test-suite/go/director_unroll_runme and /dev/null differ diff --git a/Examples/test-suite/go/director_unroll_wrap.h b/Examples/test-suite/go/director_unroll_wrap.h deleted file mode 100644 index 55273110b..000000000 --- a/Examples/test-suite/go/director_unroll_wrap.h +++ /dev/null @@ -1,33 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../director_unroll.i - -#ifndef SWIG_director_unroll_WRAP_H_ -#define SWIG_director_unroll_WRAP_H_ - -class SwigDirector_Foo : public Foo -{ - public: - SwigDirector_Foo(void *swig_p); - virtual ~SwigDirector_Foo(); - std::string _swig_upcall_ping() { - return Foo::ping(); - } - virtual std::string ping(); - std::string _swig_upcall_pong() { - return Foo::pong(); - } - virtual std::string pong(); - private: - void *go_val; -}; - -#endif diff --git a/Examples/test-suite/go/director_using.go b/Examples/test-suite/go/director_using.go deleted file mode 100644 index 4c4dec077..000000000 --- a/Examples/test-suite/go/director_using.go +++ /dev/null @@ -1,969 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../director_using.i - -package director_using - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type _swig_DirectorFoo_int struct { - SwigcptrFoo_int - v interface{} -} - -func (p *_swig_DirectorFoo_int) Swigcptr() uintptr { - return p.SwigcptrFoo_int.Swigcptr() -} - -func (p *_swig_DirectorFoo_int) SwigIsFoo_int() { -} - -func (p *_swig_DirectorFoo_int) DirectorInterface() interface{} { - return p.v -} - -var _wrap__swig_NewDirectorFoo_intFoo_int unsafe.Pointer - -func _swig_NewDirectorFoo_intFoo_int(_swig_director *_swig_DirectorFoo_int) (_swig_ret SwigcptrFoo_int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_director)) - _cgo_runtime_cgocall(_wrap__swig_NewDirectorFoo_intFoo_int, _swig_p) - return -} - -func NewDirectorFoo_int(v interface{}) Foo_int { - p := &_swig_DirectorFoo_int{0, v} - p.SwigcptrFoo_int = _swig_NewDirectorFoo_intFoo_int(p) - return p -} - -var _wrap_DeleteDirectorFoo_int unsafe.Pointer - -func _swig_wrap_DeleteDirectorFoo_int(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_DeleteDirectorFoo_int, _swig_p) - return -} - -func DeleteDirectorFoo_int(arg1 Foo_int) { - _swig_wrap_DeleteDirectorFoo_int(arg1.Swigcptr()) -} - -func Swiggo_DeleteDirector_Foo_int(p *_swig_DirectorFoo_int) { - p.SwigcptrFoo_int = 0 -} - -type _swig_DirectorInterfaceFoo_intDo_advance interface { - Do_advance() string -} - -func (swig_p *_swig_DirectorFoo_int) Do_advance() string { - if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceFoo_intDo_advance); swig_ok { - return swig_g.Do_advance() - } - panic("call to pure virtual method") -} - -func Swig_DirectorFoo_int_callback_do_advance(p *_swig_DirectorFoo_int) (swig_result string) { - var swig_r string - swig_r = p.Do_advance() - return swig_r -} - -type _swig_DirectorInterfaceFoo_intDo_step interface { - Do_step() string -} - -func (swig_p *_swig_DirectorFoo_int) Do_step() string { - if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceFoo_intDo_step); swig_ok { - return swig_g.Do_step() - } - panic("call to pure virtual method") -} - -func Swig_DirectorFoo_int_callback_do_step(p *_swig_DirectorFoo_int) (swig_result string) { - var swig_r string - swig_r = p.Do_step() - return swig_r -} - -type SwigcptrFoo_int uintptr - -func (p SwigcptrFoo_int) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrFoo_int) SwigIsFoo_int() { -} - -func (p SwigcptrFoo_int) DirectorInterface() interface{} { - return nil -} - -var _wrap_delete_Foo_int unsafe.Pointer - -func _swig_wrap_delete_Foo_int(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Foo_int, _swig_p) - return -} - -func DeleteFoo_int(arg1 Foo_int) { - _swig_wrap_delete_Foo_int(arg1.Swigcptr()) -} - -var _wrap_Foo_int_advance unsafe.Pointer - -func _swig_wrap_Foo_int_advance(base SwigcptrFoo_int) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_int_advance, _swig_p) - return -} - -func (arg1 SwigcptrFoo_int) Advance() (_swig_ret string) { - return _swig_wrap_Foo_int_advance(arg1) -} - -var _wrap_new_Foo_int unsafe.Pointer - -func _swig_wrap_new_Foo_int() (base SwigcptrFoo_int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Foo_int, _swig_p) - return -} - -func NewFoo_int() (_swig_ret Foo_int) { - return _swig_wrap_new_Foo_int() -} - -type Foo_int interface { - Swigcptr() uintptr - SwigIsFoo_int() - DirectorInterface() interface{} - Advance() (_swig_ret string) -} - -type _swig_DirectorBar struct { - SwigcptrBar - v interface{} -} - -func (p *_swig_DirectorBar) Swigcptr() uintptr { - return p.SwigcptrBar.Swigcptr() -} - -func (p *_swig_DirectorBar) SwigIsBar() { -} - -func (p *_swig_DirectorBar) DirectorInterface() interface{} { - return p.v -} - -var _wrap__swig_NewDirectorBarBar unsafe.Pointer - -func _swig_NewDirectorBarBar(_swig_director *_swig_DirectorBar) (_swig_ret SwigcptrBar) { - _swig_p := uintptr(unsafe.Pointer(&_swig_director)) - _cgo_runtime_cgocall(_wrap__swig_NewDirectorBarBar, _swig_p) - return -} - -func NewDirectorBar(v interface{}) Bar { - p := &_swig_DirectorBar{0, v} - p.SwigcptrBar = _swig_NewDirectorBarBar(p) - return p -} - -var _wrap_DeleteDirectorBar unsafe.Pointer - -func _swig_wrap_DeleteDirectorBar(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_DeleteDirectorBar, _swig_p) - return -} - -func DeleteDirectorBar(arg1 Bar) { - _swig_wrap_DeleteDirectorBar(arg1.Swigcptr()) -} - -func Swiggo_DeleteDirector_Bar(p *_swig_DirectorBar) { - p.SwigcptrBar = 0 -} - -type _swig_DirectorInterfaceBarDo_advance interface { - Do_advance() string -} - -var _wrap__swig_DirectorBar_upcall_Do_advance unsafe.Pointer - -func _swig_wrap__swig_DirectorBar_upcall_Do_advance(_swig_ptr SwigcptrBar) (_swig_ret string) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) - _cgo_runtime_cgocall(_wrap__swig_DirectorBar_upcall_Do_advance, _swig_p) - return -} - -func (swig_p *_swig_DirectorBar) Do_advance() string { - if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceBarDo_advance); swig_ok { - return swig_g.Do_advance() - } - var swig_r string - swig_r = _swig_wrap__swig_DirectorBar_upcall_Do_advance(swig_p.SwigcptrBar) - return swig_r -} - -func DirectorBarDo_advance(p Bar) string { - var swig_r string - swig_r = _swig_wrap__swig_DirectorBar_upcall_Do_advance(p.(*_swig_DirectorBar).SwigcptrBar) - return swig_r -} - -func Swig_DirectorBar_callback_do_advance(p *_swig_DirectorBar) (swig_result string) { - var swig_r string - swig_r = p.Do_advance() - return swig_r -} - -type _swig_DirectorInterfaceBarDo_step interface { - Do_step() string -} - -func (swig_p *_swig_DirectorBar) Do_step() string { - if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceBarDo_step); swig_ok { - return swig_g.Do_step() - } - panic("call to pure virtual method") -} - -func Swig_DirectorBar_callback_do_step(p *_swig_DirectorBar) (swig_result string) { - var swig_r string - swig_r = p.Do_step() - return swig_r -} - -type SwigcptrBar uintptr - -func (p SwigcptrBar) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrBar) SwigIsBar() { -} - -func (p SwigcptrBar) DirectorInterface() interface{} { - return nil -} - -var _wrap_Bar_step unsafe.Pointer - -func _swig_wrap_Bar_step(base SwigcptrBar) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Bar_step, _swig_p) - return -} - -func (arg1 SwigcptrBar) Step() (_swig_ret string) { - return _swig_wrap_Bar_step(arg1) -} - -var _wrap_Bar_do_step unsafe.Pointer - -func _swig_wrap_Bar_do_step(base SwigcptrBar) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Bar_do_step, _swig_p) - return -} - -func (arg1 SwigcptrBar) Do_step() (_swig_ret string) { - return _swig_wrap_Bar_do_step(arg1) -} - -var _wrap_new_Bar unsafe.Pointer - -func _swig_wrap_new_Bar() (base SwigcptrBar) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Bar, _swig_p) - return -} - -func NewBar() (_swig_ret Bar) { - return _swig_wrap_new_Bar() -} - -var _wrap_delete_Bar unsafe.Pointer - -func _swig_wrap_delete_Bar(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Bar, _swig_p) - return -} - -func DeleteBar(arg1 Bar) { - _swig_wrap_delete_Bar(arg1.Swigcptr()) -} - -var _wrap_Bar_advance unsafe.Pointer - -func _swig_wrap_Bar_advance(base SwigcptrBar) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Bar_advance, _swig_p) - return -} - -func (_swig_base SwigcptrBar) Advance() (_swig_ret string) { - return _swig_wrap_Bar_advance(_swig_base) -} - -func (p SwigcptrBar) SwigIsFoo_int() { -} - -func (p SwigcptrBar) SwigGetFoo_int() Foo_int { - return SwigcptrFoo_int(p.Swigcptr()) -} - -type Bar interface { - Swigcptr() uintptr - SwigIsBar() - DirectorInterface() interface{} - Step() (_swig_ret string) - Do_step() (_swig_ret string) - Advance() (_swig_ret string) - SwigIsFoo_int() - SwigGetFoo_int() Foo_int -} - -type _swig_DirectorFooBar_int struct { - SwigcptrFooBar_int - v interface{} -} - -func (p *_swig_DirectorFooBar_int) Swigcptr() uintptr { - return p.SwigcptrFooBar_int.Swigcptr() -} - -func (p *_swig_DirectorFooBar_int) SwigIsFooBar_int() { -} - -func (p *_swig_DirectorFooBar_int) DirectorInterface() interface{} { - return p.v -} - -var _wrap__swig_NewDirectorFooBar_intFooBar_int unsafe.Pointer - -func _swig_NewDirectorFooBar_intFooBar_int(_swig_director *_swig_DirectorFooBar_int) (_swig_ret SwigcptrFooBar_int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_director)) - _cgo_runtime_cgocall(_wrap__swig_NewDirectorFooBar_intFooBar_int, _swig_p) - return -} - -func NewDirectorFooBar_int(v interface{}) FooBar_int { - p := &_swig_DirectorFooBar_int{0, v} - p.SwigcptrFooBar_int = _swig_NewDirectorFooBar_intFooBar_int(p) - return p -} - -var _wrap_DeleteDirectorFooBar_int unsafe.Pointer - -func _swig_wrap_DeleteDirectorFooBar_int(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_DeleteDirectorFooBar_int, _swig_p) - return -} - -func DeleteDirectorFooBar_int(arg1 FooBar_int) { - _swig_wrap_DeleteDirectorFooBar_int(arg1.Swigcptr()) -} - -func Swiggo_DeleteDirector_FooBar_int(p *_swig_DirectorFooBar_int) { - p.SwigcptrFooBar_int = 0 -} - -type _swig_DirectorInterfaceFooBar_intDo_advance interface { - Do_advance() string -} - -var _wrap__swig_DirectorFooBar_int_upcall_Do_advance unsafe.Pointer - -func _swig_wrap__swig_DirectorFooBar_int_upcall_Do_advance(_swig_ptr SwigcptrFooBar_int) (_swig_ret string) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) - _cgo_runtime_cgocall(_wrap__swig_DirectorFooBar_int_upcall_Do_advance, _swig_p) - return -} - -func (swig_p *_swig_DirectorFooBar_int) Do_advance() string { - if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceFooBar_intDo_advance); swig_ok { - return swig_g.Do_advance() - } - var swig_r string - swig_r = _swig_wrap__swig_DirectorFooBar_int_upcall_Do_advance(swig_p.SwigcptrFooBar_int) - return swig_r -} - -func DirectorFooBar_intDo_advance(p FooBar_int) string { - var swig_r string - swig_r = _swig_wrap__swig_DirectorFooBar_int_upcall_Do_advance(p.(*_swig_DirectorFooBar_int).SwigcptrFooBar_int) - return swig_r -} - -func Swig_DirectorFooBar_int_callback_do_advance(p *_swig_DirectorFooBar_int) (swig_result string) { - var swig_r string - swig_r = p.Do_advance() - return swig_r -} - -type _swig_DirectorInterfaceFooBar_intDo_step interface { - Do_step() string -} - -func (swig_p *_swig_DirectorFooBar_int) Do_step() string { - if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceFooBar_intDo_step); swig_ok { - return swig_g.Do_step() - } - panic("call to pure virtual method") -} - -func Swig_DirectorFooBar_int_callback_do_step(p *_swig_DirectorFooBar_int) (swig_result string) { - var swig_r string - swig_r = p.Do_step() - return swig_r -} - -type _swig_DirectorInterfaceFooBar_intGet_value interface { - Get_value() int -} - -func (swig_p *_swig_DirectorFooBar_int) Get_value() int { - if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceFooBar_intGet_value); swig_ok { - return swig_g.Get_value() - } - panic("call to pure virtual method") -} - -func Swig_DirectorFooBar_int_callback_get_value(p *_swig_DirectorFooBar_int) (swig_result int) { - var swig_r int - swig_r = p.Get_value() - return swig_r -} - -type SwigcptrFooBar_int uintptr - -func (p SwigcptrFooBar_int) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrFooBar_int) SwigIsFooBar_int() { -} - -func (p SwigcptrFooBar_int) DirectorInterface() interface{} { - return nil -} - -var _wrap_FooBar_int_get_value unsafe.Pointer - -func _swig_wrap_FooBar_int_get_value(base SwigcptrFooBar_int) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_FooBar_int_get_value, _swig_p) - return -} - -func (arg1 SwigcptrFooBar_int) Get_value() (_swig_ret int) { - return _swig_wrap_FooBar_int_get_value(arg1) -} - -var _wrap_FooBar_int_do_advance unsafe.Pointer - -func _swig_wrap_FooBar_int_do_advance(base SwigcptrFooBar_int) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_FooBar_int_do_advance, _swig_p) - return -} - -func (arg1 SwigcptrFooBar_int) Do_advance() (_swig_ret string) { - return _swig_wrap_FooBar_int_do_advance(arg1) -} - -var _wrap_new_FooBar_int unsafe.Pointer - -func _swig_wrap_new_FooBar_int() (base SwigcptrFooBar_int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_FooBar_int, _swig_p) - return -} - -func NewFooBar_int() (_swig_ret FooBar_int) { - return _swig_wrap_new_FooBar_int() -} - -var _wrap_delete_FooBar_int unsafe.Pointer - -func _swig_wrap_delete_FooBar_int(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_FooBar_int, _swig_p) - return -} - -func DeleteFooBar_int(arg1 FooBar_int) { - _swig_wrap_delete_FooBar_int(arg1.Swigcptr()) -} - -var _wrap_FooBar_int_step unsafe.Pointer - -func _swig_wrap_FooBar_int_step(base SwigcptrFooBar_int) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_FooBar_int_step, _swig_p) - return -} - -func (_swig_base SwigcptrFooBar_int) Step() (_swig_ret string) { - return _swig_wrap_FooBar_int_step(_swig_base) -} - -var _wrap_FooBar_int_advance unsafe.Pointer - -func _swig_wrap_FooBar_int_advance(base SwigcptrFooBar_int) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_FooBar_int_advance, _swig_p) - return -} - -func (_swig_base SwigcptrFooBar_int) Advance() (_swig_ret string) { - return _swig_wrap_FooBar_int_advance(_swig_base) -} - -func (p SwigcptrFooBar_int) SwigIsBar() { -} - -func (p SwigcptrFooBar_int) SwigGetBar() Bar { - return SwigcptrBar(p.Swigcptr()) -} - -func (p SwigcptrFooBar_int) SwigIsFoo_int() { -} - -func (p SwigcptrFooBar_int) SwigGetFoo_int() Foo_int { - return SwigcptrFoo_int(p.Swigcptr()) -} - -type FooBar_int interface { - Swigcptr() uintptr - SwigIsFooBar_int() - DirectorInterface() interface{} - Get_value() (_swig_ret int) - Do_advance() (_swig_ret string) - Step() (_swig_ret string) - Advance() (_swig_ret string) - SwigIsBar() - SwigGetBar() Bar - SwigIsFoo_int() - SwigGetFoo_int() Foo_int -} - -type _swig_DirectorSomeBase struct { - SwigcptrSomeBase - v interface{} -} - -func (p *_swig_DirectorSomeBase) Swigcptr() uintptr { - return p.SwigcptrSomeBase.Swigcptr() -} - -func (p *_swig_DirectorSomeBase) SwigIsSomeBase() { -} - -func (p *_swig_DirectorSomeBase) DirectorInterface() interface{} { - return p.v -} - -var _wrap__swig_NewDirectorSomeBaseSomeBase unsafe.Pointer - -func _swig_NewDirectorSomeBaseSomeBase(_swig_director *_swig_DirectorSomeBase) (_swig_ret SwigcptrSomeBase) { - _swig_p := uintptr(unsafe.Pointer(&_swig_director)) - _cgo_runtime_cgocall(_wrap__swig_NewDirectorSomeBaseSomeBase, _swig_p) - return -} - -func NewDirectorSomeBase(v interface{}) SomeBase { - p := &_swig_DirectorSomeBase{0, v} - p.SwigcptrSomeBase = _swig_NewDirectorSomeBaseSomeBase(p) - return p -} - -var _wrap_DeleteDirectorSomeBase unsafe.Pointer - -func _swig_wrap_DeleteDirectorSomeBase(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_DeleteDirectorSomeBase, _swig_p) - return -} - -func DeleteDirectorSomeBase(arg1 SomeBase) { - _swig_wrap_DeleteDirectorSomeBase(arg1.Swigcptr()) -} - -func Swiggo_DeleteDirector_SomeBase(p *_swig_DirectorSomeBase) { - p.SwigcptrSomeBase = 0 -} - -type _swig_DirectorInterfaceSomeBaseMethod1 interface { - Method1() -} - -var _wrap__swig_DirectorSomeBase_upcall_Method1 unsafe.Pointer - -func _swig_wrap__swig_DirectorSomeBase_upcall_Method1(_swig_ptr SwigcptrSomeBase) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) - _cgo_runtime_cgocall(_wrap__swig_DirectorSomeBase_upcall_Method1, _swig_p) - return -} - -func (swig_p *_swig_DirectorSomeBase) Method1() { - if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceSomeBaseMethod1); swig_ok { - swig_g.Method1() - return - } - _swig_wrap__swig_DirectorSomeBase_upcall_Method1(swig_p.SwigcptrSomeBase) -} - -func DirectorSomeBaseMethod1(p SomeBase) { - _swig_wrap__swig_DirectorSomeBase_upcall_Method1(p.(*_swig_DirectorSomeBase).SwigcptrSomeBase) -} - -func Swig_DirectorSomeBase_callback_method1(p *_swig_DirectorSomeBase) { - p.Method1() -} - -type _swig_DirectorInterfaceSomeBaseMethod2 interface { - Method2() -} - -var _wrap__swig_DirectorSomeBase_upcall_Method2 unsafe.Pointer - -func _swig_wrap__swig_DirectorSomeBase_upcall_Method2(_swig_ptr SwigcptrSomeBase) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) - _cgo_runtime_cgocall(_wrap__swig_DirectorSomeBase_upcall_Method2, _swig_p) - return -} - -func (swig_p *_swig_DirectorSomeBase) Method2() { - if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceSomeBaseMethod2); swig_ok { - swig_g.Method2() - return - } - _swig_wrap__swig_DirectorSomeBase_upcall_Method2(swig_p.SwigcptrSomeBase) -} - -func DirectorSomeBaseMethod2(p SomeBase) { - _swig_wrap__swig_DirectorSomeBase_upcall_Method2(p.(*_swig_DirectorSomeBase).SwigcptrSomeBase) -} - -func Swig_DirectorSomeBase_callback_method2(p *_swig_DirectorSomeBase) { - p.Method2() -} - -type SwigcptrSomeBase uintptr - -func (p SwigcptrSomeBase) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrSomeBase) SwigIsSomeBase() { -} - -func (p SwigcptrSomeBase) DirectorInterface() interface{} { - return nil -} - -var _wrap_delete_SomeBase unsafe.Pointer - -func _swig_wrap_delete_SomeBase(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_SomeBase, _swig_p) - return -} - -func DeleteSomeBase(arg1 SomeBase) { - _swig_wrap_delete_SomeBase(arg1.Swigcptr()) -} - -var _wrap_SomeBase_method1 unsafe.Pointer - -func _swig_wrap_SomeBase_method1(base SwigcptrSomeBase) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_SomeBase_method1, _swig_p) - return -} - -func (arg1 SwigcptrSomeBase) Method1() { - _swig_wrap_SomeBase_method1(arg1) -} - -var _wrap_SomeBase_method2 unsafe.Pointer - -func _swig_wrap_SomeBase_method2(base SwigcptrSomeBase) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_SomeBase_method2, _swig_p) - return -} - -func (arg1 SwigcptrSomeBase) Method2() { - _swig_wrap_SomeBase_method2(arg1) -} - -var _wrap_new_SomeBase unsafe.Pointer - -func _swig_wrap_new_SomeBase() (base SwigcptrSomeBase) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_SomeBase, _swig_p) - return -} - -func NewSomeBase() (_swig_ret SomeBase) { - return _swig_wrap_new_SomeBase() -} - -type SomeBase interface { - Swigcptr() uintptr - SwigIsSomeBase() - DirectorInterface() interface{} - Method1() - Method2() -} - -type _swig_DirectorPrivateDerived struct { - SwigcptrPrivateDerived - v interface{} -} - -func (p *_swig_DirectorPrivateDerived) Swigcptr() uintptr { - return p.SwigcptrPrivateDerived.Swigcptr() -} - -func (p *_swig_DirectorPrivateDerived) SwigIsPrivateDerived() { -} - -func (p *_swig_DirectorPrivateDerived) DirectorInterface() interface{} { - return p.v -} - -var _wrap__swig_NewDirectorPrivateDerivedPrivateDerived unsafe.Pointer - -func _swig_NewDirectorPrivateDerivedPrivateDerived(_swig_director *_swig_DirectorPrivateDerived) (_swig_ret SwigcptrPrivateDerived) { - _swig_p := uintptr(unsafe.Pointer(&_swig_director)) - _cgo_runtime_cgocall(_wrap__swig_NewDirectorPrivateDerivedPrivateDerived, _swig_p) - return -} - -func NewDirectorPrivateDerived(v interface{}) PrivateDerived { - p := &_swig_DirectorPrivateDerived{0, v} - p.SwigcptrPrivateDerived = _swig_NewDirectorPrivateDerivedPrivateDerived(p) - return p -} - -var _wrap_DeleteDirectorPrivateDerived unsafe.Pointer - -func _swig_wrap_DeleteDirectorPrivateDerived(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_DeleteDirectorPrivateDerived, _swig_p) - return -} - -func DeleteDirectorPrivateDerived(arg1 PrivateDerived) { - _swig_wrap_DeleteDirectorPrivateDerived(arg1.Swigcptr()) -} - -func Swiggo_DeleteDirector_PrivateDerived(p *_swig_DirectorPrivateDerived) { - p.SwigcptrPrivateDerived = 0 -} - -type _swig_DirectorInterfacePrivateDerivedMethod1 interface { - Method1() -} - -var _wrap__swig_DirectorPrivateDerived_upcall_Method1 unsafe.Pointer - -func _swig_wrap__swig_DirectorPrivateDerived_upcall_Method1(_swig_ptr SwigcptrPrivateDerived) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) - _cgo_runtime_cgocall(_wrap__swig_DirectorPrivateDerived_upcall_Method1, _swig_p) - return -} - -func (swig_p *_swig_DirectorPrivateDerived) Method1() { - if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfacePrivateDerivedMethod1); swig_ok { - swig_g.Method1() - return - } - _swig_wrap__swig_DirectorPrivateDerived_upcall_Method1(swig_p.SwigcptrPrivateDerived) -} - -func DirectorPrivateDerivedMethod1(p PrivateDerived) { - _swig_wrap__swig_DirectorPrivateDerived_upcall_Method1(p.(*_swig_DirectorPrivateDerived).SwigcptrPrivateDerived) -} - -func Swig_DirectorPrivateDerived_callback_method1(p *_swig_DirectorPrivateDerived) { - p.Method1() -} - -type _swig_DirectorInterfacePrivateDerivedMethod2 interface { - Method2() -} - -var _wrap__swig_DirectorPrivateDerived_upcall_Method2 unsafe.Pointer - -func _swig_wrap__swig_DirectorPrivateDerived_upcall_Method2(_swig_ptr SwigcptrPrivateDerived) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) - _cgo_runtime_cgocall(_wrap__swig_DirectorPrivateDerived_upcall_Method2, _swig_p) - return -} - -func (swig_p *_swig_DirectorPrivateDerived) Method2() { - if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfacePrivateDerivedMethod2); swig_ok { - swig_g.Method2() - return - } - _swig_wrap__swig_DirectorPrivateDerived_upcall_Method2(swig_p.SwigcptrPrivateDerived) -} - -func DirectorPrivateDerivedMethod2(p PrivateDerived) { - _swig_wrap__swig_DirectorPrivateDerived_upcall_Method2(p.(*_swig_DirectorPrivateDerived).SwigcptrPrivateDerived) -} - -func Swig_DirectorPrivateDerived_callback_method2(p *_swig_DirectorPrivateDerived) { - p.Method2() -} - -type SwigcptrPrivateDerived uintptr - -func (p SwigcptrPrivateDerived) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrPrivateDerived) SwigIsPrivateDerived() { -} - -func (p SwigcptrPrivateDerived) DirectorInterface() interface{} { - return nil -} - -var _wrap_new_PrivateDerived unsafe.Pointer - -func _swig_wrap_new_PrivateDerived() (base SwigcptrPrivateDerived) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_PrivateDerived, _swig_p) - return -} - -func NewPrivateDerived() (_swig_ret PrivateDerived) { - return _swig_wrap_new_PrivateDerived() -} - -var _wrap_delete_PrivateDerived unsafe.Pointer - -func _swig_wrap_delete_PrivateDerived(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_PrivateDerived, _swig_p) - return -} - -func DeletePrivateDerived(arg1 PrivateDerived) { - _swig_wrap_delete_PrivateDerived(arg1.Swigcptr()) -} - -var _wrap_PrivateDerived_method1 unsafe.Pointer - -func _swig_wrap_PrivateDerived_method1(base SwigcptrPrivateDerived) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_PrivateDerived_method1, _swig_p) - return -} - -func (_swig_base SwigcptrPrivateDerived) Method1() { - _swig_wrap_PrivateDerived_method1(_swig_base) -} - -var _wrap_PrivateDerived_method2 unsafe.Pointer - -func _swig_wrap_PrivateDerived_method2(base SwigcptrPrivateDerived) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_PrivateDerived_method2, _swig_p) - return -} - -func (_swig_base SwigcptrPrivateDerived) Method2() { - _swig_wrap_PrivateDerived_method2(_swig_base) -} - -func (p SwigcptrPrivateDerived) SwigIsSomeBase() { -} - -func (p SwigcptrPrivateDerived) SwigGetSomeBase() SomeBase { - return SwigcptrSomeBase(p.Swigcptr()) -} - -type PrivateDerived interface { - Swigcptr() uintptr - SwigIsPrivateDerived() - DirectorInterface() interface{} - Method1() - Method2() - SwigIsSomeBase() - SwigGetSomeBase() SomeBase -} - - -type SwigcptrSwigDirector_PrivateDerived uintptr -type SwigDirector_PrivateDerived interface { - Swigcptr() uintptr; -} -func (p SwigcptrSwigDirector_PrivateDerived) Swigcptr() uintptr { - return uintptr(p) -} - -type SwigcptrSwigDirector_FooBar_int uintptr -type SwigDirector_FooBar_int interface { - Swigcptr() uintptr; -} -func (p SwigcptrSwigDirector_FooBar_int) Swigcptr() uintptr { - return uintptr(p) -} - -type SwigcptrSwigDirector_Bar uintptr -type SwigDirector_Bar interface { - Swigcptr() uintptr; -} -func (p SwigcptrSwigDirector_Bar) Swigcptr() uintptr { - return uintptr(p) -} - -type SwigcptrSwigDirector_SomeBase uintptr -type SwigDirector_SomeBase interface { - Swigcptr() uintptr; -} -func (p SwigcptrSwigDirector_SomeBase) Swigcptr() uintptr { - return uintptr(p) -} - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/director_using_wrap.h b/Examples/test-suite/go/director_using_wrap.h deleted file mode 100644 index 42c9c2ba4..000000000 --- a/Examples/test-suite/go/director_using_wrap.h +++ /dev/null @@ -1,90 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../director_using.i - -#ifndef SWIG_director_using_WRAP_H_ -#define SWIG_director_using_WRAP_H_ - -class SwigDirector_Foo_int : public Foo< int > -{ - public: - SwigDirector_Foo_int(void *swig_p); - virtual ~SwigDirector_Foo_int(); - virtual std::string do_advance(); - virtual std::string do_step() const; - private: - void *go_val; -}; - -class SwigDirector_Bar : public Bar -{ - public: - SwigDirector_Bar(void *swig_p); - virtual ~SwigDirector_Bar(); - std::string _swig_upcall_do_advance() { - return Bar::do_advance(); - } - virtual std::string do_advance(); - virtual std::string do_step() const; - private: - void *go_val; -}; - -class SwigDirector_FooBar_int : public FooBar< int > -{ - public: - SwigDirector_FooBar_int(void *swig_p); - virtual ~SwigDirector_FooBar_int(); - std::string _swig_upcall_do_advance() { - return FooBar< int >::do_advance(); - } - virtual std::string do_advance(); - virtual std::string do_step() const; - virtual int get_value() const; - private: - void *go_val; -}; - -class SwigDirector_SomeBase : public SomeBase -{ - public: - SwigDirector_SomeBase(void *swig_p); - virtual ~SwigDirector_SomeBase(); - void _swig_upcall_method1() { - SomeBase::method1(); - } - virtual void method1(); - void _swig_upcall_method2() { - SomeBase::method2(); - } - virtual void method2(); - private: - void *go_val; -}; - -class SwigDirector_PrivateDerived : public PrivateDerived -{ - public: - SwigDirector_PrivateDerived(void *swig_p); - virtual ~SwigDirector_PrivateDerived(); - void _swig_upcall_method1() { - SomeBase::method1(); - } - virtual void method1(); - void _swig_upcall_method2() { - SomeBase::method2(); - } - virtual void method2(); - private: - void *go_val; -}; - -#endif diff --git a/Examples/test-suite/go/director_wombat.go b/Examples/test-suite/go/director_wombat.go deleted file mode 100644 index 879c11211..000000000 --- a/Examples/test-suite/go/director_wombat.go +++ /dev/null @@ -1,528 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../director_wombat.i - -package director_wombat - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type _swig_DirectorBar struct { - SwigcptrBar - v interface{} -} - -func (p *_swig_DirectorBar) Swigcptr() uintptr { - return p.SwigcptrBar.Swigcptr() -} - -func (p *_swig_DirectorBar) SwigIsBar() { -} - -func (p *_swig_DirectorBar) DirectorInterface() interface{} { - return p.v -} - -var _wrap__swig_NewDirectorBarBar unsafe.Pointer - -func _swig_NewDirectorBarBar(_swig_director *_swig_DirectorBar) (_swig_ret SwigcptrBar) { - _swig_p := uintptr(unsafe.Pointer(&_swig_director)) - _cgo_runtime_cgocall(_wrap__swig_NewDirectorBarBar, _swig_p) - return -} - -func NewDirectorBar(v interface{}) Bar { - p := &_swig_DirectorBar{0, v} - p.SwigcptrBar = _swig_NewDirectorBarBar(p) - return p -} - -var _wrap_DeleteDirectorBar unsafe.Pointer - -func _swig_wrap_DeleteDirectorBar(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_DeleteDirectorBar, _swig_p) - return -} - -func DeleteDirectorBar(arg1 Bar) { - _swig_wrap_DeleteDirectorBar(arg1.Swigcptr()) -} - -func Swiggo_DeleteDirector_Bar(p *_swig_DirectorBar) { - p.SwigcptrBar = 0 -} - -type _swig_DirectorInterfaceBarMeth interface { - Meth() Foo_integers -} - -var _wrap__swig_DirectorBar_upcall_Meth unsafe.Pointer - -func _swig_wrap__swig_DirectorBar_upcall_Meth(_swig_ptr SwigcptrBar) (_swig_ret SwigcptrFoo_integers) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) - _cgo_runtime_cgocall(_wrap__swig_DirectorBar_upcall_Meth, _swig_p) - return -} - -func (swig_p *_swig_DirectorBar) Meth() Foo_integers { - if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceBarMeth); swig_ok { - return swig_g.Meth() - } - var swig_r Foo_integers - swig_r = _swig_wrap__swig_DirectorBar_upcall_Meth(swig_p.SwigcptrBar) - return swig_r -} - -func DirectorBarMeth(p Bar) Foo_integers { - var swig_r Foo_integers - swig_r = _swig_wrap__swig_DirectorBar_upcall_Meth(p.(*_swig_DirectorBar).SwigcptrBar) - return swig_r -} - -func Swig_DirectorBar_callback_meth(p *_swig_DirectorBar) (swig_result SwigcptrFoo_integers) { - var swig_r SwigcptrFoo_integers - swig_r = SwigcptrFoo_integers(p.Meth().Swigcptr()) - return swig_r -} - -type _swig_DirectorInterfaceBarFoo_meth_ref interface { - Foo_meth_ref(Foo_integers, int) -} - -var _wrap__swig_DirectorBar_upcall_Foo_meth_ref unsafe.Pointer - -func _swig_wrap__swig_DirectorBar_upcall_Foo_meth_ref(_swig_ptr SwigcptrBar, _ uintptr, _ int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) - _cgo_runtime_cgocall(_wrap__swig_DirectorBar_upcall_Foo_meth_ref, _swig_p) - return -} - -func (swig_p *_swig_DirectorBar) Foo_meth_ref(arg0 Foo_integers, arg1 int) { - if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceBarFoo_meth_ref); swig_ok { - swig_g.Foo_meth_ref(arg0, arg1) - return - } - _swig_wrap__swig_DirectorBar_upcall_Foo_meth_ref(swig_p.SwigcptrBar, arg0.Swigcptr(), arg1) -} - -func DirectorBarFoo_meth_ref(p Bar, arg2 Foo_integers, arg3 int) { - _swig_wrap__swig_DirectorBar_upcall_Foo_meth_ref(p.(*_swig_DirectorBar).SwigcptrBar, arg2.Swigcptr(), arg3) -} - -func Swig_DirectorBar_callback_foo_meth_ref(p *_swig_DirectorBar, arg2 uintptr, arg3 int) { - p.Foo_meth_ref(SwigcptrFoo_integers(arg2), arg3) -} - -type _swig_DirectorInterfaceBarFoo_meth_ptr interface { - Foo_meth_ptr(Foo_integers, int) -} - -var _wrap__swig_DirectorBar_upcall_Foo_meth_ptr unsafe.Pointer - -func _swig_wrap__swig_DirectorBar_upcall_Foo_meth_ptr(_swig_ptr SwigcptrBar, _ uintptr, _ int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) - _cgo_runtime_cgocall(_wrap__swig_DirectorBar_upcall_Foo_meth_ptr, _swig_p) - return -} - -func (swig_p *_swig_DirectorBar) Foo_meth_ptr(arg0 Foo_integers, arg1 int) { - if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceBarFoo_meth_ptr); swig_ok { - swig_g.Foo_meth_ptr(arg0, arg1) - return - } - _swig_wrap__swig_DirectorBar_upcall_Foo_meth_ptr(swig_p.SwigcptrBar, arg0.Swigcptr(), arg1) -} - -func DirectorBarFoo_meth_ptr(p Bar, arg2 Foo_integers, arg3 int) { - _swig_wrap__swig_DirectorBar_upcall_Foo_meth_ptr(p.(*_swig_DirectorBar).SwigcptrBar, arg2.Swigcptr(), arg3) -} - -func Swig_DirectorBar_callback_foo_meth_ptr(p *_swig_DirectorBar, arg2 uintptr, arg3 int) { - p.Foo_meth_ptr(SwigcptrFoo_integers(arg2), arg3) -} - -type _swig_DirectorInterfaceBarFoo_meth_val interface { - Foo_meth_val(Foo_integers, int) -} - -var _wrap__swig_DirectorBar_upcall_Foo_meth_val unsafe.Pointer - -func _swig_wrap__swig_DirectorBar_upcall_Foo_meth_val(_swig_ptr SwigcptrBar, _ uintptr, _ int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) - _cgo_runtime_cgocall(_wrap__swig_DirectorBar_upcall_Foo_meth_val, _swig_p) - return -} - -func (swig_p *_swig_DirectorBar) Foo_meth_val(arg0 Foo_integers, arg1 int) { - if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceBarFoo_meth_val); swig_ok { - swig_g.Foo_meth_val(arg0, arg1) - return - } - _swig_wrap__swig_DirectorBar_upcall_Foo_meth_val(swig_p.SwigcptrBar, arg0.Swigcptr(), arg1) -} - -func DirectorBarFoo_meth_val(p Bar, arg2 Foo_integers, arg3 int) { - _swig_wrap__swig_DirectorBar_upcall_Foo_meth_val(p.(*_swig_DirectorBar).SwigcptrBar, arg2.Swigcptr(), arg3) -} - -func Swig_DirectorBar_callback_foo_meth_val(p *_swig_DirectorBar, arg2 uintptr, arg3 int) { - p.Foo_meth_val(SwigcptrFoo_integers(arg2), arg3) -} - -type _swig_DirectorInterfaceBarFoo_meth_cref interface { - Foo_meth_cref(Foo_integers, int) -} - -var _wrap__swig_DirectorBar_upcall_Foo_meth_cref unsafe.Pointer - -func _swig_wrap__swig_DirectorBar_upcall_Foo_meth_cref(_swig_ptr SwigcptrBar, _ uintptr, _ int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) - _cgo_runtime_cgocall(_wrap__swig_DirectorBar_upcall_Foo_meth_cref, _swig_p) - return -} - -func (swig_p *_swig_DirectorBar) Foo_meth_cref(arg0 Foo_integers, arg1 int) { - if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceBarFoo_meth_cref); swig_ok { - swig_g.Foo_meth_cref(arg0, arg1) - return - } - _swig_wrap__swig_DirectorBar_upcall_Foo_meth_cref(swig_p.SwigcptrBar, arg0.Swigcptr(), arg1) -} - -func DirectorBarFoo_meth_cref(p Bar, arg2 Foo_integers, arg3 int) { - _swig_wrap__swig_DirectorBar_upcall_Foo_meth_cref(p.(*_swig_DirectorBar).SwigcptrBar, arg2.Swigcptr(), arg3) -} - -func Swig_DirectorBar_callback_foo_meth_cref(p *_swig_DirectorBar, arg2 uintptr, arg3 int) { - p.Foo_meth_cref(SwigcptrFoo_integers(arg2), arg3) -} - -type _swig_DirectorInterfaceBarFoo_meth_cptr interface { - Foo_meth_cptr(Foo_integers, int) -} - -var _wrap__swig_DirectorBar_upcall_Foo_meth_cptr unsafe.Pointer - -func _swig_wrap__swig_DirectorBar_upcall_Foo_meth_cptr(_swig_ptr SwigcptrBar, _ uintptr, _ int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) - _cgo_runtime_cgocall(_wrap__swig_DirectorBar_upcall_Foo_meth_cptr, _swig_p) - return -} - -func (swig_p *_swig_DirectorBar) Foo_meth_cptr(arg0 Foo_integers, arg1 int) { - if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceBarFoo_meth_cptr); swig_ok { - swig_g.Foo_meth_cptr(arg0, arg1) - return - } - _swig_wrap__swig_DirectorBar_upcall_Foo_meth_cptr(swig_p.SwigcptrBar, arg0.Swigcptr(), arg1) -} - -func DirectorBarFoo_meth_cptr(p Bar, arg2 Foo_integers, arg3 int) { - _swig_wrap__swig_DirectorBar_upcall_Foo_meth_cptr(p.(*_swig_DirectorBar).SwigcptrBar, arg2.Swigcptr(), arg3) -} - -func Swig_DirectorBar_callback_foo_meth_cptr(p *_swig_DirectorBar, arg2 uintptr, arg3 int) { - p.Foo_meth_cptr(SwigcptrFoo_integers(arg2), arg3) -} - -type SwigcptrBar uintptr - -func (p SwigcptrBar) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrBar) SwigIsBar() { -} - -func (p SwigcptrBar) DirectorInterface() interface{} { - return nil -} - -var _wrap_delete_Bar unsafe.Pointer - -func _swig_wrap_delete_Bar(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Bar, _swig_p) - return -} - -func DeleteBar(arg1 Bar) { - _swig_wrap_delete_Bar(arg1.Swigcptr()) -} - -var _wrap_Bar_meth unsafe.Pointer - -func _swig_wrap_Bar_meth(base SwigcptrBar) (_ SwigcptrFoo_integers) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Bar_meth, _swig_p) - return -} - -func (arg1 SwigcptrBar) Meth() (_swig_ret Foo_integers) { - return _swig_wrap_Bar_meth(arg1) -} - -var _wrap_Bar_foo_meth_ref unsafe.Pointer - -func _swig_wrap_Bar_foo_meth_ref(base SwigcptrBar, _ uintptr, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Bar_foo_meth_ref, _swig_p) - return -} - -func (arg1 SwigcptrBar) Foo_meth_ref(arg2 Foo_integers, arg3 int) { - _swig_wrap_Bar_foo_meth_ref(arg1, arg2.Swigcptr(), arg3) -} - -var _wrap_Bar_foo_meth_ptr unsafe.Pointer - -func _swig_wrap_Bar_foo_meth_ptr(base SwigcptrBar, _ uintptr, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Bar_foo_meth_ptr, _swig_p) - return -} - -func (arg1 SwigcptrBar) Foo_meth_ptr(arg2 Foo_integers, arg3 int) { - _swig_wrap_Bar_foo_meth_ptr(arg1, arg2.Swigcptr(), arg3) -} - -var _wrap_Bar_foo_meth_val unsafe.Pointer - -func _swig_wrap_Bar_foo_meth_val(base SwigcptrBar, _ uintptr, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Bar_foo_meth_val, _swig_p) - return -} - -func (arg1 SwigcptrBar) Foo_meth_val(arg2 Foo_integers, arg3 int) { - _swig_wrap_Bar_foo_meth_val(arg1, arg2.Swigcptr(), arg3) -} - -var _wrap_Bar_foo_meth_cref unsafe.Pointer - -func _swig_wrap_Bar_foo_meth_cref(base SwigcptrBar, _ uintptr, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Bar_foo_meth_cref, _swig_p) - return -} - -func (arg1 SwigcptrBar) Foo_meth_cref(arg2 Foo_integers, arg3 int) { - _swig_wrap_Bar_foo_meth_cref(arg1, arg2.Swigcptr(), arg3) -} - -var _wrap_Bar_foo_meth_cptr unsafe.Pointer - -func _swig_wrap_Bar_foo_meth_cptr(base SwigcptrBar, _ uintptr, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Bar_foo_meth_cptr, _swig_p) - return -} - -func (arg1 SwigcptrBar) Foo_meth_cptr(arg2 Foo_integers, arg3 int) { - _swig_wrap_Bar_foo_meth_cptr(arg1, arg2.Swigcptr(), arg3) -} - -var _wrap_new_Bar unsafe.Pointer - -func _swig_wrap_new_Bar() (base SwigcptrBar) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Bar, _swig_p) - return -} - -func NewBar() (_swig_ret Bar) { - return _swig_wrap_new_Bar() -} - -type Bar interface { - Swigcptr() uintptr - SwigIsBar() - DirectorInterface() interface{} - Meth() (_swig_ret Foo_integers) - Foo_meth_ref(arg2 Foo_integers, arg3 int) - Foo_meth_ptr(arg2 Foo_integers, arg3 int) - Foo_meth_val(arg2 Foo_integers, arg3 int) - Foo_meth_cref(arg2 Foo_integers, arg3 int) - Foo_meth_cptr(arg2 Foo_integers, arg3 int) -} - -type _swig_DirectorFoo_integers struct { - SwigcptrFoo_integers - v interface{} -} - -func (p *_swig_DirectorFoo_integers) Swigcptr() uintptr { - return p.SwigcptrFoo_integers.Swigcptr() -} - -func (p *_swig_DirectorFoo_integers) SwigIsFoo_integers() { -} - -func (p *_swig_DirectorFoo_integers) DirectorInterface() interface{} { - return p.v -} - -var _wrap__swig_NewDirectorFoo_integersFoo_integers unsafe.Pointer - -func _swig_NewDirectorFoo_integersFoo_integers(_swig_director *_swig_DirectorFoo_integers) (_swig_ret SwigcptrFoo_integers) { - _swig_p := uintptr(unsafe.Pointer(&_swig_director)) - _cgo_runtime_cgocall(_wrap__swig_NewDirectorFoo_integersFoo_integers, _swig_p) - return -} - -func NewDirectorFoo_integers(v interface{}) Foo_integers { - p := &_swig_DirectorFoo_integers{0, v} - p.SwigcptrFoo_integers = _swig_NewDirectorFoo_integersFoo_integers(p) - return p -} - -var _wrap_DeleteDirectorFoo_integers unsafe.Pointer - -func _swig_wrap_DeleteDirectorFoo_integers(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_DeleteDirectorFoo_integers, _swig_p) - return -} - -func DeleteDirectorFoo_integers(arg1 Foo_integers) { - _swig_wrap_DeleteDirectorFoo_integers(arg1.Swigcptr()) -} - -func Swiggo_DeleteDirector_Foo_integers(p *_swig_DirectorFoo_integers) { - p.SwigcptrFoo_integers = 0 -} - -type _swig_DirectorInterfaceFoo_integersMeth interface { - Meth(int) int -} - -var _wrap__swig_DirectorFoo_integers_upcall_Meth unsafe.Pointer - -func _swig_wrap__swig_DirectorFoo_integers_upcall_Meth(_swig_ptr SwigcptrFoo_integers, _ int) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) - _cgo_runtime_cgocall(_wrap__swig_DirectorFoo_integers_upcall_Meth, _swig_p) - return -} - -func (swig_p *_swig_DirectorFoo_integers) Meth(param int) int { - if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceFoo_integersMeth); swig_ok { - return swig_g.Meth(param) - } - var swig_r int - swig_r = _swig_wrap__swig_DirectorFoo_integers_upcall_Meth(swig_p.SwigcptrFoo_integers, param) - return swig_r -} - -func DirectorFoo_integersMeth(p Foo_integers, arg2 int) int { - var swig_r int - swig_r = _swig_wrap__swig_DirectorFoo_integers_upcall_Meth(p.(*_swig_DirectorFoo_integers).SwigcptrFoo_integers, arg2) - return swig_r -} - -func Swig_DirectorFoo_integers_callback_meth(p *_swig_DirectorFoo_integers, arg2 int) (swig_result int) { - var swig_r int - swig_r = p.Meth(arg2) - return swig_r -} - -type SwigcptrFoo_integers uintptr - -func (p SwigcptrFoo_integers) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrFoo_integers) SwigIsFoo_integers() { -} - -func (p SwigcptrFoo_integers) DirectorInterface() interface{} { - return nil -} - -var _wrap_new_Foo_integers unsafe.Pointer - -func _swig_wrap_new_Foo_integers() (base SwigcptrFoo_integers) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Foo_integers, _swig_p) - return -} - -func NewFoo_integers() (_swig_ret Foo_integers) { - return _swig_wrap_new_Foo_integers() -} - -var _wrap_delete_Foo_integers unsafe.Pointer - -func _swig_wrap_delete_Foo_integers(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Foo_integers, _swig_p) - return -} - -func DeleteFoo_integers(arg1 Foo_integers) { - _swig_wrap_delete_Foo_integers(arg1.Swigcptr()) -} - -var _wrap_Foo_integers_meth unsafe.Pointer - -func _swig_wrap_Foo_integers_meth(base SwigcptrFoo_integers, _ int) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_integers_meth, _swig_p) - return -} - -func (arg1 SwigcptrFoo_integers) Meth(arg2 int) (_swig_ret int) { - return _swig_wrap_Foo_integers_meth(arg1, arg2) -} - -type Foo_integers interface { - Swigcptr() uintptr - SwigIsFoo_integers() - DirectorInterface() interface{} - Meth(arg2 int) (_swig_ret int) -} - - -type SwigcptrSwigDirector_Bar uintptr -type SwigDirector_Bar interface { - Swigcptr() uintptr; -} -func (p SwigcptrSwigDirector_Bar) Swigcptr() uintptr { - return uintptr(p) -} - -type SwigcptrSwigDirector_Foo_integers uintptr -type SwigDirector_Foo_integers interface { - Swigcptr() uintptr; -} -func (p SwigcptrSwigDirector_Foo_integers) Swigcptr() uintptr { - return uintptr(p) -} - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/director_wombat_wrap.h b/Examples/test-suite/go/director_wombat_wrap.h deleted file mode 100644 index e65021439..000000000 --- a/Examples/test-suite/go/director_wombat_wrap.h +++ /dev/null @@ -1,62 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../director_wombat.i - -#ifndef SWIG_director_wombat_WRAP_H_ -#define SWIG_director_wombat_WRAP_H_ - -class SwigDirector_Bar : public Bar -{ - public: - SwigDirector_Bar(void *swig_p); - virtual ~SwigDirector_Bar(); - Foo_int *_swig_upcall_meth() { - return Bar::meth(); - } - virtual Foo_int *meth(); - void _swig_upcall_foo_meth_ref(Foo_int &arg0, int arg1) { - Bar::foo_meth_ref(arg0,arg1); - } - virtual void foo_meth_ref(Foo_int &arg0, int arg1); - void _swig_upcall_foo_meth_ptr(Foo_int *arg0, int arg1) { - Bar::foo_meth_ptr(arg0,arg1); - } - virtual void foo_meth_ptr(Foo_int *arg0, int arg1); - void _swig_upcall_foo_meth_val(Foo_int arg0, int arg1) { - Bar::foo_meth_val(arg0,arg1); - } - virtual void foo_meth_val(Foo_int arg0, int arg1); - void _swig_upcall_foo_meth_cref(Foo_int const &arg0, int arg1) { - Bar::foo_meth_cref(arg0,arg1); - } - virtual void foo_meth_cref(Foo_int const &arg0, int arg1); - void _swig_upcall_foo_meth_cptr(Foo_int const *arg0, int arg1) { - Bar::foo_meth_cptr(arg0,arg1); - } - virtual void foo_meth_cptr(Foo_int const *arg0, int arg1); - private: - void *go_val; -}; - -class SwigDirector_Foo_integers : public Foo< int > -{ - public: - SwigDirector_Foo_integers(void *swig_p); - virtual ~SwigDirector_Foo_integers(); - int _swig_upcall_meth(int param) { - return Foo< int >::meth(param); - } - virtual int meth(int param); - private: - void *go_val; -}; - -#endif diff --git a/Examples/test-suite/go/disown.go b/Examples/test-suite/go/disown.go deleted file mode 100644 index ad89189ff..000000000 --- a/Examples/test-suite/go/disown.go +++ /dev/null @@ -1,139 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../disown.i - -package disown - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrA uintptr - -func (p SwigcptrA) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrA) SwigIsA() { -} - -var _wrap_delete_A unsafe.Pointer - -func _swig_wrap_delete_A(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_A, _swig_p) - return -} - -func DeleteA(arg1 A) { - _swig_wrap_delete_A(arg1.Swigcptr()) -} - -var _wrap_new_A unsafe.Pointer - -func _swig_wrap_new_A() (base SwigcptrA) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_A, _swig_p) - return -} - -func NewA() (_swig_ret A) { - return _swig_wrap_new_A() -} - -type A interface { - Swigcptr() uintptr - SwigIsA() -} - -type SwigcptrB uintptr - -func (p SwigcptrB) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrB) SwigIsB() { -} - -var _wrap_new_B unsafe.Pointer - -func _swig_wrap_new_B() (base SwigcptrB) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_B, _swig_p) - return -} - -func NewB() (_swig_ret B) { - return _swig_wrap_new_B() -} - -var _wrap_delete_B unsafe.Pointer - -func _swig_wrap_delete_B(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_B, _swig_p) - return -} - -func DeleteB(arg1 B) { - _swig_wrap_delete_B(arg1.Swigcptr()) -} - -var _wrap_B_acquire unsafe.Pointer - -func _swig_wrap_B_acquire(base SwigcptrB, _ uintptr) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_B_acquire, _swig_p) - return -} - -func (arg1 SwigcptrB) Acquire(arg2 A) (_swig_ret int) { - return _swig_wrap_B_acquire(arg1, arg2.Swigcptr()) -} - -var _wrap_B_remove unsafe.Pointer - -func _swig_wrap_B_remove(base SwigcptrB, _ uintptr) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_B_remove, _swig_p) - return -} - -func (arg1 SwigcptrB) Remove(arg2 A) (_swig_ret int) { - return _swig_wrap_B_remove(arg1, arg2.Swigcptr()) -} - -type B interface { - Swigcptr() uintptr - SwigIsB() - Acquire(arg2 A) (_swig_ret int) - Remove(arg2 A) (_swig_ret int) -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/disown_runme b/Examples/test-suite/go/disown_runme deleted file mode 100755 index 162b3d682..000000000 Binary files a/Examples/test-suite/go/disown_runme and /dev/null differ diff --git a/Examples/test-suite/go/dynamic_cast.go b/Examples/test-suite/go/dynamic_cast.go deleted file mode 100644 index 94e9b9b66..000000000 --- a/Examples/test-suite/go/dynamic_cast.go +++ /dev/null @@ -1,178 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../dynamic_cast.i - -package dynamic_cast - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - - -func FooToBar(f Foo) Bar { - return SwigcptrBar(f.Swigcptr()) -} - -type SwigcptrFoo uintptr - -func (p SwigcptrFoo) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrFoo) SwigIsFoo() { -} - -var _wrap_delete_Foo unsafe.Pointer - -func _swig_wrap_delete_Foo(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Foo, _swig_p) - return -} - -func DeleteFoo(arg1 Foo) { - _swig_wrap_delete_Foo(arg1.Swigcptr()) -} - -var _wrap_Foo_blah unsafe.Pointer - -func _swig_wrap_Foo_blah(base SwigcptrFoo) (_ SwigcptrFoo) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_blah, _swig_p) - return -} - -func (arg1 SwigcptrFoo) Blah() (_swig_ret Foo) { - return _swig_wrap_Foo_blah(arg1) -} - -var _wrap_new_Foo unsafe.Pointer - -func _swig_wrap_new_Foo() (base SwigcptrFoo) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Foo, _swig_p) - return -} - -func NewFoo() (_swig_ret Foo) { - return _swig_wrap_new_Foo() -} - -type Foo interface { - Swigcptr() uintptr - SwigIsFoo() - Blah() (_swig_ret Foo) -} - -type SwigcptrBar uintptr - -func (p SwigcptrBar) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrBar) SwigIsBar() { -} - -var _wrap_Bar_blah unsafe.Pointer - -func _swig_wrap_Bar_blah(base SwigcptrBar) (_ SwigcptrFoo) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Bar_blah, _swig_p) - return -} - -func (arg1 SwigcptrBar) Blah() (_swig_ret Foo) { - return _swig_wrap_Bar_blah(arg1) -} - -var _wrap_Bar_test unsafe.Pointer - -func _swig_wrap_Bar_test(base SwigcptrBar) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Bar_test, _swig_p) - return -} - -func (arg1 SwigcptrBar) Test() (_swig_ret string) { - return _swig_wrap_Bar_test(arg1) -} - -var _wrap_new_Bar unsafe.Pointer - -func _swig_wrap_new_Bar() (base SwigcptrBar) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Bar, _swig_p) - return -} - -func NewBar() (_swig_ret Bar) { - return _swig_wrap_new_Bar() -} - -var _wrap_delete_Bar unsafe.Pointer - -func _swig_wrap_delete_Bar(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Bar, _swig_p) - return -} - -func DeleteBar(arg1 Bar) { - _swig_wrap_delete_Bar(arg1.Swigcptr()) -} - -func (p SwigcptrBar) SwigIsFoo() { -} - -func (p SwigcptrBar) SwigGetFoo() Foo { - return SwigcptrFoo(p.Swigcptr()) -} - -type Bar interface { - Swigcptr() uintptr - SwigIsBar() - Blah() (_swig_ret Foo) - Test() (_swig_ret string) - SwigIsFoo() - SwigGetFoo() Foo -} - -var _wrap_do_test unsafe.Pointer - -func _swig_wrap_do_test(base uintptr) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_do_test, _swig_p) - return -} - -func Do_test(arg1 Bar) (_swig_ret string) { - return _swig_wrap_do_test(arg1.Swigcptr()) -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/dynamic_cast_runme b/Examples/test-suite/go/dynamic_cast_runme deleted file mode 100755 index 333efd253..000000000 Binary files a/Examples/test-suite/go/dynamic_cast_runme and /dev/null differ diff --git a/Examples/test-suite/go/empty.go b/Examples/test-suite/go/empty.go deleted file mode 100644 index 3484c59fc..000000000 --- a/Examples/test-suite/go/empty.go +++ /dev/null @@ -1,29 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../empty.i - -package empty - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - - diff --git a/Examples/test-suite/go/empty_runme b/Examples/test-suite/go/empty_runme deleted file mode 100755 index 4f1a9f803..000000000 Binary files a/Examples/test-suite/go/empty_runme and /dev/null differ diff --git a/Examples/test-suite/go/enum_forward.go b/Examples/test-suite/go/enum_forward.go deleted file mode 100644 index 3e2cb2850..000000000 --- a/Examples/test-suite/go/enum_forward.go +++ /dev/null @@ -1,90 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../enum_forward.i - -package enum_forward - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type Enum_SS_ForwardEnum1 int -var _wrap_get_enum1 unsafe.Pointer - -func Get_enum1() (_swig_ret Enum_SS_ForwardEnum1) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_get_enum1, _swig_p) - return -} -var _wrap_test_function1 unsafe.Pointer - -func Test_function1(arg1 Enum_SS_ForwardEnum1) (_swig_ret Enum_SS_ForwardEnum1) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_test_function1, _swig_p) - return -} -var _wrap_get_enum2 unsafe.Pointer - -func Get_enum2() (_swig_ret Enum_SS_ForwardEnum2) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_get_enum2, _swig_p) - return -} -var _wrap_test_function2 unsafe.Pointer - -func Test_function2(arg1 Enum_SS_ForwardEnum2) (_swig_ret Enum_SS_ForwardEnum2) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_test_function2, _swig_p) - return -} -type Enum_SS_ForwardEnum2 int -type Enum_SS_ForwardEnum3 int -var _wrap_EEE unsafe.Pointer - -func _swig_getEEE() (_swig_ret Enum_SS_ForwardEnum3) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_EEE, _swig_p) - return -} -var EEE Enum_SS_ForwardEnum3 = _swig_getEEE() -var _wrap_FFF unsafe.Pointer - -func _swig_getFFF() (_swig_ret Enum_SS_ForwardEnum3) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_FFF, _swig_p) - return -} -var FFF Enum_SS_ForwardEnum3 = _swig_getFFF() -var _wrap_get_enum3 unsafe.Pointer - -func Get_enum3() (_swig_ret Enum_SS_ForwardEnum3) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_get_enum3, _swig_p) - return -} -var _wrap_test_function3 unsafe.Pointer - -func Test_function3(arg1 Enum_SS_ForwardEnum3) (_swig_ret Enum_SS_ForwardEnum3) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_test_function3, _swig_p) - return -} - diff --git a/Examples/test-suite/go/enum_ignore.go b/Examples/test-suite/go/enum_ignore.go deleted file mode 100644 index 5d0c7af4f..000000000 --- a/Examples/test-suite/go/enum_ignore.go +++ /dev/null @@ -1,129 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../enum_ignore.i - -package enum_ignore - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrDraw uintptr - -func (p SwigcptrDraw) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrDraw) SwigIsDraw() { -} - -var _wrap_Draw_DrawBW unsafe.Pointer - -func _swig_wrap_Draw_DrawBW(base SwigcptrDraw) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Draw_DrawBW, _swig_p) - return -} - -func (arg1 SwigcptrDraw) DrawBW() { - _swig_wrap_Draw_DrawBW(arg1) -} - -var _wrap_Draw_DrawC unsafe.Pointer - -func _swig_wrap_Draw_DrawC(base SwigcptrDraw, _ N_C) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Draw_DrawC, _swig_p) - return -} - -func (arg1 SwigcptrDraw) DrawC(arg2 N_C) { - _swig_wrap_Draw_DrawC(arg1, arg2) -} - -var _wrap_Draw_DrawC_Ptr unsafe.Pointer - -func _swig_wrap_Draw_DrawC_Ptr(base SwigcptrDraw, _ *N_C) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Draw_DrawC_Ptr, _swig_p) - return -} - -func (arg1 SwigcptrDraw) DrawC_Ptr(arg2 *N_C) { - _swig_wrap_Draw_DrawC_Ptr(arg1, arg2) -} - -var _wrap_Draw_DrawC_ConstRef unsafe.Pointer - -func _swig_wrap_Draw_DrawC_ConstRef(base SwigcptrDraw, _ *N_C) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Draw_DrawC_ConstRef, _swig_p) - return -} - -func (arg1 SwigcptrDraw) DrawC_ConstRef(arg2 *N_C) { - _swig_wrap_Draw_DrawC_ConstRef(arg1, arg2) -} - -var _wrap_new_Draw unsafe.Pointer - -func _swig_wrap_new_Draw() (base SwigcptrDraw) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Draw, _swig_p) - return -} - -func NewDraw() (_swig_ret Draw) { - return _swig_wrap_new_Draw() -} - -var _wrap_delete_Draw unsafe.Pointer - -func _swig_wrap_delete_Draw(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Draw, _swig_p) - return -} - -func DeleteDraw(arg1 Draw) { - _swig_wrap_delete_Draw(arg1.Swigcptr()) -} - -type Draw interface { - Swigcptr() uintptr - SwigIsDraw() - DrawBW() - DrawC(arg2 N_C) - DrawC_Ptr(arg2 *N_C) - DrawC_ConstRef(arg2 *N_C) -} - - -type N_C int - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/enum_macro.go b/Examples/test-suite/go/enum_macro.go deleted file mode 100644 index bddf43693..000000000 --- a/Examples/test-suite/go/enum_macro.go +++ /dev/null @@ -1,226 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../enum_macro.i - -package enum_macro - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type Enum_SS_Greeks1 int -var _wrap_alpha1 unsafe.Pointer - -func _swig_getalpha1() (_swig_ret Enum_SS_Greeks1) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_alpha1, _swig_p) - return -} -var Alpha1 Enum_SS_Greeks1 = _swig_getalpha1() -var _wrap_beta1 unsafe.Pointer - -func _swig_getbeta1() (_swig_ret Enum_SS_Greeks1) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_beta1, _swig_p) - return -} -var Beta1 Enum_SS_Greeks1 = _swig_getbeta1() -var _wrap_theta1 unsafe.Pointer - -func _swig_gettheta1() (_swig_ret Enum_SS_Greeks1) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_theta1, _swig_p) - return -} -var Theta1 Enum_SS_Greeks1 = _swig_gettheta1() -type Enum_SS_Greeks2 int -var _wrap_alpha2 unsafe.Pointer - -func _swig_getalpha2() (_swig_ret Enum_SS_Greeks2) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_alpha2, _swig_p) - return -} -var Alpha2 Enum_SS_Greeks2 = _swig_getalpha2() -var _wrap_beta2 unsafe.Pointer - -func _swig_getbeta2() (_swig_ret Enum_SS_Greeks2) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_beta2, _swig_p) - return -} -var Beta2 Enum_SS_Greeks2 = _swig_getbeta2() -var _wrap_theta2 unsafe.Pointer - -func _swig_gettheta2() (_swig_ret Enum_SS_Greeks2) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_theta2, _swig_p) - return -} -var Theta2 Enum_SS_Greeks2 = _swig_gettheta2() -type Enum_SS_Greeks3 int -var _wrap_alpha3 unsafe.Pointer - -func _swig_getalpha3() (_swig_ret Enum_SS_Greeks3) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_alpha3, _swig_p) - return -} -var Alpha3 Enum_SS_Greeks3 = _swig_getalpha3() -var _wrap_beta3 unsafe.Pointer - -func _swig_getbeta3() (_swig_ret Enum_SS_Greeks3) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_beta3, _swig_p) - return -} -var Beta3 Enum_SS_Greeks3 = _swig_getbeta3() -var _wrap_theta3 unsafe.Pointer - -func _swig_gettheta3() (_swig_ret Enum_SS_Greeks3) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_theta3, _swig_p) - return -} -var Theta3 Enum_SS_Greeks3 = _swig_gettheta3() -type Enum_SS_Greeks4 int -var _wrap_alpha4 unsafe.Pointer - -func _swig_getalpha4() (_swig_ret Enum_SS_Greeks4) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_alpha4, _swig_p) - return -} -var Alpha4 Enum_SS_Greeks4 = _swig_getalpha4() -var _wrap_beta4 unsafe.Pointer - -func _swig_getbeta4() (_swig_ret Enum_SS_Greeks4) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_beta4, _swig_p) - return -} -var Beta4 Enum_SS_Greeks4 = _swig_getbeta4() -var _wrap_theta4 unsafe.Pointer - -func _swig_gettheta4() (_swig_ret Enum_SS_Greeks4) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_theta4, _swig_p) - return -} -var Theta4 Enum_SS_Greeks4 = _swig_gettheta4() -type Enum_SS_Greeks5 int -var _wrap_alpha5 unsafe.Pointer - -func _swig_getalpha5() (_swig_ret Enum_SS_Greeks5) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_alpha5, _swig_p) - return -} -var Alpha5 Enum_SS_Greeks5 = _swig_getalpha5() -var _wrap_beta5 unsafe.Pointer - -func _swig_getbeta5() (_swig_ret Enum_SS_Greeks5) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_beta5, _swig_p) - return -} -var Beta5 Enum_SS_Greeks5 = _swig_getbeta5() -type Enum_SS_Greeks6 int -var _wrap_alpha6 unsafe.Pointer - -func _swig_getalpha6() (_swig_ret Enum_SS_Greeks6) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_alpha6, _swig_p) - return -} -var Alpha6 Enum_SS_Greeks6 = _swig_getalpha6() -var _wrap_beta6 unsafe.Pointer - -func _swig_getbeta6() (_swig_ret Enum_SS_Greeks6) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_beta6, _swig_p) - return -} -var Beta6 Enum_SS_Greeks6 = _swig_getbeta6() -type Enum_SS_Greeks7 int -var _wrap_alpha7 unsafe.Pointer - -func _swig_getalpha7() (_swig_ret Enum_SS_Greeks7) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_alpha7, _swig_p) - return -} -var Alpha7 Enum_SS_Greeks7 = _swig_getalpha7() -var _wrap_beta7 unsafe.Pointer - -func _swig_getbeta7() (_swig_ret Enum_SS_Greeks7) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_beta7, _swig_p) - return -} -var Beta7 Enum_SS_Greeks7 = _swig_getbeta7() -type Enum_SS_Greeks8 int -var _wrap_theta8 unsafe.Pointer - -func _swig_gettheta8() (_swig_ret Enum_SS_Greeks8) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_theta8, _swig_p) - return -} -var Theta8 Enum_SS_Greeks8 = _swig_gettheta8() -type Enum_SS_Greeks9 int -var _wrap_theta9 unsafe.Pointer - -func _swig_gettheta9() (_swig_ret Enum_SS_Greeks9) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_theta9, _swig_p) - return -} -var Theta9 Enum_SS_Greeks9 = _swig_gettheta9() -type Enum_SS_Greeks10 int -var _wrap_theta10 unsafe.Pointer - -func _swig_gettheta10() (_swig_ret Enum_SS_Greeks10) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_theta10, _swig_p) - return -} -var Theta10 Enum_SS_Greeks10 = _swig_gettheta10() -type Enum_SS_Greeks11 int -var _wrap_theta11 unsafe.Pointer - -func _swig_gettheta11() (_swig_ret Enum_SS_Greeks11) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_theta11, _swig_p) - return -} -var Theta11 Enum_SS_Greeks11 = _swig_gettheta11() -type Greeks12 int -var _wrap_theta12 unsafe.Pointer - -func _swig_gettheta12() (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_theta12, _swig_p) - return -} -var Theta12 int = _swig_gettheta12() -type Enum_SS_Greeks13 int - diff --git a/Examples/test-suite/go/enum_missing.go b/Examples/test-suite/go/enum_missing.go deleted file mode 100644 index 0a86f64c8..000000000 --- a/Examples/test-suite/go/enum_missing.go +++ /dev/null @@ -1,196 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../enum_missing.i - -package enum_missing - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrAVCodecContext uintptr - -func (p SwigcptrAVCodecContext) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrAVCodecContext) SwigIsAVCodecContext() { -} - -var _wrap_AVCodecContext_pix_fmt_set unsafe.Pointer - -func _swig_wrap_AVCodecContext_pix_fmt_set(base SwigcptrAVCodecContext, _ AVPixelFormat) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_AVCodecContext_pix_fmt_set, _swig_p) - return -} - -func (arg1 SwigcptrAVCodecContext) SetPix_fmt(arg2 AVPixelFormat) { - _swig_wrap_AVCodecContext_pix_fmt_set(arg1, arg2) -} - -var _wrap_AVCodecContext_pix_fmt_get unsafe.Pointer - -func _swig_wrap_AVCodecContext_pix_fmt_get(base SwigcptrAVCodecContext) (_ AVPixelFormat) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_AVCodecContext_pix_fmt_get, _swig_p) - return -} - -func (arg1 SwigcptrAVCodecContext) GetPix_fmt() (_swig_ret AVPixelFormat) { - return _swig_wrap_AVCodecContext_pix_fmt_get(arg1) -} - -var _wrap_AVCodecContext_pix_fmt2_set unsafe.Pointer - -func _swig_wrap_AVCodecContext_pix_fmt2_set(base SwigcptrAVCodecContext, _ AVPixelFormat2) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_AVCodecContext_pix_fmt2_set, _swig_p) - return -} - -func (arg1 SwigcptrAVCodecContext) SetPix_fmt2(arg2 AVPixelFormat2) { - _swig_wrap_AVCodecContext_pix_fmt2_set(arg1, arg2) -} - -var _wrap_AVCodecContext_pix_fmt2_get unsafe.Pointer - -func _swig_wrap_AVCodecContext_pix_fmt2_get(base SwigcptrAVCodecContext) (_ AVPixelFormat2) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_AVCodecContext_pix_fmt2_get, _swig_p) - return -} - -func (arg1 SwigcptrAVCodecContext) GetPix_fmt2() (_swig_ret AVPixelFormat2) { - return _swig_wrap_AVCodecContext_pix_fmt2_get(arg1) -} - -var _wrap_new_AVCodecContext unsafe.Pointer - -func _swig_wrap_new_AVCodecContext() (base SwigcptrAVCodecContext) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_AVCodecContext, _swig_p) - return -} - -func NewAVCodecContext() (_swig_ret AVCodecContext) { - return _swig_wrap_new_AVCodecContext() -} - -var _wrap_delete_AVCodecContext unsafe.Pointer - -func _swig_wrap_delete_AVCodecContext(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_AVCodecContext, _swig_p) - return -} - -func DeleteAVCodecContext(arg1 AVCodecContext) { - _swig_wrap_delete_AVCodecContext(arg1.Swigcptr()) -} - -type AVCodecContext interface { - Swigcptr() uintptr - SwigIsAVCodecContext() - SetPix_fmt(arg2 AVPixelFormat) - GetPix_fmt() (_swig_ret AVPixelFormat) - SetPix_fmt2(arg2 AVPixelFormat2) - GetPix_fmt2() (_swig_ret AVPixelFormat2) -} - -var _wrap_global_fmt_set unsafe.Pointer - -func _swig_wrap_global_fmt_set(base AVPixelFormat) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_global_fmt_set, _swig_p) - return -} - -func SetGlobal_fmt(arg1 AVPixelFormat) { - _swig_wrap_global_fmt_set(arg1) -} - -var _wrap_global_fmt_get unsafe.Pointer - -func GetGlobal_fmt() (_swig_ret AVPixelFormat) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_global_fmt_get, _swig_p) - return -} -var _wrap_global_fmt2_set unsafe.Pointer - -func _swig_wrap_global_fmt2_set(base AVPixelFormat2) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_global_fmt2_set, _swig_p) - return -} - -func SetGlobal_fmt2(arg1 AVPixelFormat2) { - _swig_wrap_global_fmt2_set(arg1) -} - -var _wrap_global_fmt2_get unsafe.Pointer - -func GetGlobal_fmt2() (_swig_ret AVPixelFormat2) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_global_fmt2_get, _swig_p) - return -} -var _wrap_use_pixel_format unsafe.Pointer - -func Use_pixel_format(arg1 AVPixelFormat) (_swig_ret AVPixelFormat) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_use_pixel_format, _swig_p) - return -} -var _wrap_use_pixel_format_ptr unsafe.Pointer - -func Use_pixel_format_ptr(arg1 *AVPixelFormat) (_swig_ret *AVPixelFormat) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_use_pixel_format_ptr, _swig_p) - return -} -var _wrap_use_pixel_format2 unsafe.Pointer - -func Use_pixel_format2(arg1 AVPixelFormat2) (_swig_ret AVPixelFormat2) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_use_pixel_format2, _swig_p) - return -} -var _wrap_use_pixel_format_ptr2 unsafe.Pointer - -func Use_pixel_format_ptr2(arg1 *AVPixelFormat2) (_swig_ret *AVPixelFormat2) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_use_pixel_format_ptr2, _swig_p) - return -} - -type AVPixelFormat2 int -type AVPixelFormat int - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/enum_plus.go b/Examples/test-suite/go/enum_plus.go deleted file mode 100644 index 8b5b7b7ef..000000000 --- a/Examples/test-suite/go/enum_plus.go +++ /dev/null @@ -1,83 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../enum_plus.i - -package enum_plus - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrIFoo uintptr - -func (p SwigcptrIFoo) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrIFoo) SwigIsIFoo() { -} - -var _wrap_Phoo_iFoo unsafe.Pointer - -func _swig_getiFoo_Phoo_iFoo() (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_Phoo_iFoo, _swig_p) - return -} -var IFooPhoo int = _swig_getiFoo_Phoo_iFoo() -var _wrap_new_iFoo unsafe.Pointer - -func _swig_wrap_new_iFoo() (base SwigcptrIFoo) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_iFoo, _swig_p) - return -} - -func NewIFoo() (_swig_ret IFoo) { - return _swig_wrap_new_iFoo() -} - -var _wrap_delete_iFoo unsafe.Pointer - -func _swig_wrap_delete_iFoo(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_iFoo, _swig_p) - return -} - -func DeleteIFoo(arg1 IFoo) { - _swig_wrap_delete_iFoo(arg1.Swigcptr()) -} - -type IFoo interface { - Swigcptr() uintptr - SwigIsIFoo() -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/enum_rename.go b/Examples/test-suite/go/enum_rename.go deleted file mode 100644 index fe0bdc655..000000000 --- a/Examples/test-suite/go/enum_rename.go +++ /dev/null @@ -1,71 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../enum_rename.i - -package enum_rename - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type Month int -var _wrap_M_Jan unsafe.Pointer - -func _swig_getM_Jan() (_swig_ret Month) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_M_Jan, _swig_p) - return -} -var M_Jan Month = _swig_getM_Jan() -var _wrap_May unsafe.Pointer - -func _swig_getMay() (_swig_ret Month) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_May, _swig_p) - return -} -var May Month = _swig_getMay() -var _wrap_M_Dec unsafe.Pointer - -func _swig_getM_Dec() (_swig_ret Month) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_M_Dec, _swig_p) - return -} -var M_Dec Month = _swig_getM_Dec() -type Severity int -var _wrap_S_Can unsafe.Pointer - -func _swig_getS_Can() (_swig_ret Severity) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_S_Can, _swig_p) - return -} -var S_Can Severity = _swig_getS_Can() -var _wrap_S_Must unsafe.Pointer - -func _swig_getS_Must() (_swig_ret Severity) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_S_Must, _swig_p) - return -} -var S_Must Severity = _swig_getS_Must() - diff --git a/Examples/test-suite/go/enum_scope_template.go b/Examples/test-suite/go/enum_scope_template.go deleted file mode 100644 index 911d5236d..000000000 --- a/Examples/test-suite/go/enum_scope_template.go +++ /dev/null @@ -1,120 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../enum_scope_template.i - -package enum_scope_template - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -var _wrap_chop unsafe.Pointer - -func Chop(arg1 Tree_Sl_int_Sg_Types) (_swig_ret Tree_Sl_int_Sg_Types) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_chop, _swig_p) - return -} -type SwigcptrTreeInt uintptr - -func (p SwigcptrTreeInt) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrTreeInt) SwigIsTreeInt() { -} - -type Tree_Sl_int_Sg_Types int -var _wrap_Oak_TreeInt unsafe.Pointer - -func _swig_getTreeInt_Oak_TreeInt() (_swig_ret Tree_Sl_int_Sg_Types) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_Oak_TreeInt, _swig_p) - return -} -var TreeIntOak Tree_Sl_int_Sg_Types = _swig_getTreeInt_Oak_TreeInt() -var _wrap_Fir_TreeInt unsafe.Pointer - -func _swig_getTreeInt_Fir_TreeInt() (_swig_ret Tree_Sl_int_Sg_Types) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_Fir_TreeInt, _swig_p) - return -} -var TreeIntFir Tree_Sl_int_Sg_Types = _swig_getTreeInt_Fir_TreeInt() -var _wrap_Cedar_TreeInt unsafe.Pointer - -func _swig_getTreeInt_Cedar_TreeInt() (_swig_ret Tree_Sl_int_Sg_Types) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_Cedar_TreeInt, _swig_p) - return -} -var TreeIntCedar Tree_Sl_int_Sg_Types = _swig_getTreeInt_Cedar_TreeInt() -var _wrap_TreeInt_chop unsafe.Pointer - -func _swig_wrap_TreeInt_chop(base SwigcptrTreeInt, _ Tree_Sl_int_Sg_Types) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_TreeInt_chop, _swig_p) - return -} - -func (arg1 SwigcptrTreeInt) Chop(arg2 Tree_Sl_int_Sg_Types) { - _swig_wrap_TreeInt_chop(arg1, arg2) -} - -var _wrap_new_TreeInt unsafe.Pointer - -func _swig_wrap_new_TreeInt() (base SwigcptrTreeInt) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_TreeInt, _swig_p) - return -} - -func NewTreeInt() (_swig_ret TreeInt) { - return _swig_wrap_new_TreeInt() -} - -var _wrap_delete_TreeInt unsafe.Pointer - -func _swig_wrap_delete_TreeInt(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_TreeInt, _swig_p) - return -} - -func DeleteTreeInt(arg1 TreeInt) { - _swig_wrap_delete_TreeInt(arg1.Swigcptr()) -} - -type TreeInt interface { - Swigcptr() uintptr - SwigIsTreeInt() - Chop(arg2 Tree_Sl_int_Sg_Types) -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/enum_template.go b/Examples/test-suite/go/enum_template.go deleted file mode 100644 index fcdd47c22..000000000 --- a/Examples/test-suite/go/enum_template.go +++ /dev/null @@ -1,119 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../enum_template.i - -package enum_template - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type ETest int -var _wrap_eTest0 unsafe.Pointer - -func _swig_geteTest0() (_swig_ret ETest) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_eTest0, _swig_p) - return -} -var ETest0 ETest = _swig_geteTest0() -var _wrap_eTest1 unsafe.Pointer - -func _swig_geteTest1() (_swig_ret ETest) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_eTest1, _swig_p) - return -} -var ETest1 ETest = _swig_geteTest1() -var _wrap_eTest2 unsafe.Pointer - -func _swig_geteTest2() (_swig_ret ETest) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_eTest2, _swig_p) - return -} -var ETest2 ETest = _swig_geteTest2() -var _wrap_TakeETest unsafe.Pointer - -func _swig_wrap_TakeETest(base ETest) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_TakeETest, _swig_p) - return -} - -func TakeETest(arg1 ETest) { - _swig_wrap_TakeETest(arg1) -} - -var _wrap_MakeETest unsafe.Pointer - -func MakeETest() (_swig_ret ETest) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_MakeETest, _swig_p) - return -} -type SwigcptrCTempl_ETest uintptr - -func (p SwigcptrCTempl_ETest) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrCTempl_ETest) SwigIsCTempl_ETest() { -} - -var _wrap_new_CTempl_ETest unsafe.Pointer - -func _swig_wrap_new_CTempl_ETest() (base SwigcptrCTempl_ETest) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_CTempl_ETest, _swig_p) - return -} - -func NewCTempl_ETest() (_swig_ret CTempl_ETest) { - return _swig_wrap_new_CTempl_ETest() -} - -var _wrap_delete_CTempl_ETest unsafe.Pointer - -func _swig_wrap_delete_CTempl_ETest(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_CTempl_ETest, _swig_p) - return -} - -func DeleteCTempl_ETest(arg1 CTempl_ETest) { - _swig_wrap_delete_CTempl_ETest(arg1.Swigcptr()) -} - -type CTempl_ETest interface { - Swigcptr() uintptr - SwigIsCTempl_ETest() -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/enum_template_runme b/Examples/test-suite/go/enum_template_runme deleted file mode 100755 index 89423b89e..000000000 Binary files a/Examples/test-suite/go/enum_template_runme and /dev/null differ diff --git a/Examples/test-suite/go/enum_thorough.go b/Examples/test-suite/go/enum_thorough.go deleted file mode 100644 index f4fb0df08..000000000 --- a/Examples/test-suite/go/enum_thorough.go +++ /dev/null @@ -1,4294 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../enum_thorough.i - -package enum_thorough - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -var _wrap_AnonEnum1 unsafe.Pointer - -func _swig_getAnonEnum1() (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_AnonEnum1, _swig_p) - return -} -var AnonEnum1 int = _swig_getAnonEnum1() -var _wrap_AnonEnum2 unsafe.Pointer - -func _swig_getAnonEnum2() (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_AnonEnum2, _swig_p) - return -} -var AnonEnum2 int = _swig_getAnonEnum2() -var _wrap_ReallyAnInteger unsafe.Pointer - -func _swig_getReallyAnInteger() (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_ReallyAnInteger, _swig_p) - return -} -var ReallyAnInteger int = _swig_getReallyAnInteger() -var _wrap_AnonSpaceEnum1 unsafe.Pointer - -func _swig_getAnonSpaceEnum1() (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_AnonSpaceEnum1, _swig_p) - return -} -var AnonSpaceEnum1 int = _swig_getAnonSpaceEnum1() -var _wrap_AnonSpaceEnum2 unsafe.Pointer - -func _swig_getAnonSpaceEnum2() (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_AnonSpaceEnum2, _swig_p) - return -} -var AnonSpaceEnum2 int = _swig_getAnonSpaceEnum2() -type SwigcptrAnonStruct uintptr - -func (p SwigcptrAnonStruct) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrAnonStruct) SwigIsAnonStruct() { -} - -var _wrap_AnonStructEnum1_AnonStruct unsafe.Pointer - -func _swig_getAnonStruct_AnonStructEnum1_AnonStruct() (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_AnonStructEnum1_AnonStruct, _swig_p) - return -} -var AnonStructAnonStructEnum1 int = _swig_getAnonStruct_AnonStructEnum1_AnonStruct() -var _wrap_AnonStructEnum2_AnonStruct unsafe.Pointer - -func _swig_getAnonStruct_AnonStructEnum2_AnonStruct() (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_AnonStructEnum2_AnonStruct, _swig_p) - return -} -var AnonStructAnonStructEnum2 int = _swig_getAnonStruct_AnonStructEnum2_AnonStruct() -var _wrap_new_AnonStruct unsafe.Pointer - -func _swig_wrap_new_AnonStruct() (base SwigcptrAnonStruct) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_AnonStruct, _swig_p) - return -} - -func NewAnonStruct() (_swig_ret AnonStruct) { - return _swig_wrap_new_AnonStruct() -} - -var _wrap_delete_AnonStruct unsafe.Pointer - -func _swig_wrap_delete_AnonStruct(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_AnonStruct, _swig_p) - return -} - -func DeleteAnonStruct(arg1 AnonStruct) { - _swig_wrap_delete_AnonStruct(arg1.Swigcptr()) -} - -type AnonStruct interface { - Swigcptr() uintptr - SwigIsAnonStruct() -} - -type Colour int -var _wrap_red unsafe.Pointer - -func _swig_getred() (_swig_ret Colour) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_red, _swig_p) - return -} -var Red Colour = _swig_getred() -var _wrap_blue unsafe.Pointer - -func _swig_getblue() (_swig_ret Colour) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_blue, _swig_p) - return -} -var Blue Colour = _swig_getblue() -var _wrap_green unsafe.Pointer - -func _swig_getgreen() (_swig_ret Colour) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_green, _swig_p) - return -} -var Green Colour = _swig_getgreen() -var _wrap_colourTest1 unsafe.Pointer - -func ColourTest1(arg1 Colour) (_swig_ret Colour) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_colourTest1, _swig_p) - return -} -var _wrap_colourTest2 unsafe.Pointer - -func ColourTest2(arg1 Colour) (_swig_ret Colour) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_colourTest2, _swig_p) - return -} -var _wrap_colourTest3 unsafe.Pointer - -func ColourTest3(arg1 Colour) (_swig_ret Colour) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_colourTest3, _swig_p) - return -} -var _wrap_colourTest4 unsafe.Pointer - -func ColourTest4(arg1 Colour) (_swig_ret Colour) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_colourTest4, _swig_p) - return -} -var _wrap_myColour_set unsafe.Pointer - -func _swig_wrap_myColour_set(base Colour) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_myColour_set, _swig_p) - return -} - -func SetMyColour(arg1 Colour) { - _swig_wrap_myColour_set(arg1) -} - -var _wrap_myColour_get unsafe.Pointer - -func GetMyColour() (_swig_ret Colour) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_myColour_get, _swig_p) - return -} -type SwigcptrSpeedClass uintptr - -func (p SwigcptrSpeedClass) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrSpeedClass) SwigIsSpeedClass() { -} - -type SpeedClassSpeed int -var _wrap_slow_SpeedClass unsafe.Pointer - -func _swig_getSpeedClass_slow_SpeedClass() (_swig_ret SpeedClassSpeed) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_slow_SpeedClass, _swig_p) - return -} -var SpeedClassSlow SpeedClassSpeed = _swig_getSpeedClass_slow_SpeedClass() -var _wrap_medium_SpeedClass unsafe.Pointer - -func _swig_getSpeedClass_medium_SpeedClass() (_swig_ret SpeedClassSpeed) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_medium_SpeedClass, _swig_p) - return -} -var SpeedClassMedium SpeedClassSpeed = _swig_getSpeedClass_medium_SpeedClass() -var _wrap_fast_SpeedClass unsafe.Pointer - -func _swig_getSpeedClass_fast_SpeedClass() (_swig_ret SpeedClassSpeed) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_fast_SpeedClass, _swig_p) - return -} -var SpeedClassFast SpeedClassSpeed = _swig_getSpeedClass_fast_SpeedClass() -var _wrap_lightning_SpeedClass unsafe.Pointer - -func _swig_getSpeedClass_lightning_SpeedClass() (_swig_ret SpeedClassSpeed) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_lightning_SpeedClass, _swig_p) - return -} -var SpeedClassLightning SpeedClassSpeed = _swig_getSpeedClass_lightning_SpeedClass() -var _wrap_SpeedClass_speedTest0 unsafe.Pointer - -func _swig_wrap_SpeedClass_speedTest0(base SwigcptrSpeedClass, _ int) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_SpeedClass_speedTest0, _swig_p) - return -} - -func (arg1 SwigcptrSpeedClass) SpeedTest0(arg2 int) (_swig_ret int) { - return _swig_wrap_SpeedClass_speedTest0(arg1, arg2) -} - -var _wrap_SpeedClass_speedTest1 unsafe.Pointer - -func _swig_wrap_SpeedClass_speedTest1(base SwigcptrSpeedClass, _ SpeedClassSpeed) (_ SpeedClassSpeed) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_SpeedClass_speedTest1, _swig_p) - return -} - -func (arg1 SwigcptrSpeedClass) SpeedTest1(arg2 SpeedClassSpeed) (_swig_ret SpeedClassSpeed) { - return _swig_wrap_SpeedClass_speedTest1(arg1, arg2) -} - -var _wrap_SpeedClass_speedTest2 unsafe.Pointer - -func _swig_wrap_SpeedClass_speedTest2(base SwigcptrSpeedClass, _ SpeedClassSpeed) (_ SpeedClassSpeed) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_SpeedClass_speedTest2, _swig_p) - return -} - -func (arg1 SwigcptrSpeedClass) SpeedTest2(arg2 SpeedClassSpeed) (_swig_ret SpeedClassSpeed) { - return _swig_wrap_SpeedClass_speedTest2(arg1, arg2) -} - -var _wrap_SpeedClass_speedTest3 unsafe.Pointer - -func _swig_wrap_SpeedClass_speedTest3(base SwigcptrSpeedClass, _ SpeedClassSpeed) (_ SpeedClassSpeed) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_SpeedClass_speedTest3, _swig_p) - return -} - -func (arg1 SwigcptrSpeedClass) SpeedTest3(arg2 SpeedClassSpeed) (_swig_ret SpeedClassSpeed) { - return _swig_wrap_SpeedClass_speedTest3(arg1, arg2) -} - -var _wrap_SpeedClass_speedTest4 unsafe.Pointer - -func _swig_wrap_SpeedClass_speedTest4(base SwigcptrSpeedClass, _ SpeedClassSpeed) (_ SpeedClassSpeed) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_SpeedClass_speedTest4, _swig_p) - return -} - -func (arg1 SwigcptrSpeedClass) SpeedTest4(arg2 SpeedClassSpeed) (_swig_ret SpeedClassSpeed) { - return _swig_wrap_SpeedClass_speedTest4(arg1, arg2) -} - -var _wrap_SpeedClass_speedTest5 unsafe.Pointer - -func _swig_wrap_SpeedClass_speedTest5(base SwigcptrSpeedClass, _ SpeedClassSpeed) (_ SpeedClassSpeed) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_SpeedClass_speedTest5, _swig_p) - return -} - -func (arg1 SwigcptrSpeedClass) SpeedTest5(arg2 SpeedClassSpeed) (_swig_ret SpeedClassSpeed) { - return _swig_wrap_SpeedClass_speedTest5(arg1, arg2) -} - -var _wrap_SpeedClass_speedTest6 unsafe.Pointer - -func _swig_wrap_SpeedClass_speedTest6(base SwigcptrSpeedClass, _ SpeedClassSpeed) (_ SpeedClassSpeed) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_SpeedClass_speedTest6, _swig_p) - return -} - -func (arg1 SwigcptrSpeedClass) SpeedTest6(arg2 SpeedClassSpeed) (_swig_ret SpeedClassSpeed) { - return _swig_wrap_SpeedClass_speedTest6(arg1, arg2) -} - -var _wrap_SpeedClass_speedTest7 unsafe.Pointer - -func _swig_wrap_SpeedClass_speedTest7(base SwigcptrSpeedClass, _ *SpeedClassSpeed) (_ *SpeedClassSpeed) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_SpeedClass_speedTest7, _swig_p) - return -} - -func (arg1 SwigcptrSpeedClass) SpeedTest7(arg2 *SpeedClassSpeed) (_swig_ret *SpeedClassSpeed) { - return _swig_wrap_SpeedClass_speedTest7(arg1, arg2) -} - -var _wrap_SpeedClass_speedTest8 unsafe.Pointer - -func _swig_wrap_SpeedClass_speedTest8(base SwigcptrSpeedClass, _ *SpeedClassSpeed) (_ *SpeedClassSpeed) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_SpeedClass_speedTest8, _swig_p) - return -} - -func (arg1 SwigcptrSpeedClass) SpeedTest8(arg2 *SpeedClassSpeed) (_swig_ret *SpeedClassSpeed) { - return _swig_wrap_SpeedClass_speedTest8(arg1, arg2) -} - -var _wrap_SpeedClass_myColour2_get unsafe.Pointer - -func _swig_wrap_SpeedClass_myColour2_get(base SwigcptrSpeedClass) (_ Colour) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_SpeedClass_myColour2_get, _swig_p) - return -} - -func (arg1 SwigcptrSpeedClass) GetMyColour2() (_swig_ret Colour) { - return _swig_wrap_SpeedClass_myColour2_get(arg1) -} - -var _wrap_SpeedClass_mySpeedtd1_set unsafe.Pointer - -func _swig_wrap_SpeedClass_mySpeedtd1_set(base SwigcptrSpeedClass, _ SpeedClassSpeed) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_SpeedClass_mySpeedtd1_set, _swig_p) - return -} - -func (arg1 SwigcptrSpeedClass) SetMySpeedtd1(arg2 SpeedClassSpeed) { - _swig_wrap_SpeedClass_mySpeedtd1_set(arg1, arg2) -} - -var _wrap_SpeedClass_mySpeedtd1_get unsafe.Pointer - -func _swig_wrap_SpeedClass_mySpeedtd1_get(base SwigcptrSpeedClass) (_ SpeedClassSpeed) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_SpeedClass_mySpeedtd1_get, _swig_p) - return -} - -func (arg1 SwigcptrSpeedClass) GetMySpeedtd1() (_swig_ret SpeedClassSpeed) { - return _swig_wrap_SpeedClass_mySpeedtd1_get(arg1) -} - -var _wrap_new_SpeedClass unsafe.Pointer - -func _swig_wrap_new_SpeedClass() (base SwigcptrSpeedClass) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_SpeedClass, _swig_p) - return -} - -func NewSpeedClass() (_swig_ret SpeedClass) { - return _swig_wrap_new_SpeedClass() -} - -var _wrap_delete_SpeedClass unsafe.Pointer - -func _swig_wrap_delete_SpeedClass(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_SpeedClass, _swig_p) - return -} - -func DeleteSpeedClass(arg1 SpeedClass) { - _swig_wrap_delete_SpeedClass(arg1.Swigcptr()) -} - -type SpeedClass interface { - Swigcptr() uintptr - SwigIsSpeedClass() - SpeedTest0(arg2 int) (_swig_ret int) - SpeedTest1(arg2 SpeedClassSpeed) (_swig_ret SpeedClassSpeed) - SpeedTest2(arg2 SpeedClassSpeed) (_swig_ret SpeedClassSpeed) - SpeedTest3(arg2 SpeedClassSpeed) (_swig_ret SpeedClassSpeed) - SpeedTest4(arg2 SpeedClassSpeed) (_swig_ret SpeedClassSpeed) - SpeedTest5(arg2 SpeedClassSpeed) (_swig_ret SpeedClassSpeed) - SpeedTest6(arg2 SpeedClassSpeed) (_swig_ret SpeedClassSpeed) - SpeedTest7(arg2 *SpeedClassSpeed) (_swig_ret *SpeedClassSpeed) - SpeedTest8(arg2 *SpeedClassSpeed) (_swig_ret *SpeedClassSpeed) - GetMyColour2() (_swig_ret Colour) - SetMySpeedtd1(arg2 SpeedClassSpeed) - GetMySpeedtd1() (_swig_ret SpeedClassSpeed) -} - -var _wrap_speedTest0 unsafe.Pointer - -func SpeedTest0(arg1 int) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_speedTest0, _swig_p) - return -} -var _wrap_speedTest1 unsafe.Pointer - -func SpeedTest1(arg1 SpeedClassSpeed) (_swig_ret SpeedClassSpeed) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_speedTest1, _swig_p) - return -} -var _wrap_speedTest2 unsafe.Pointer - -func SpeedTest2(arg1 SpeedClassSpeed) (_swig_ret SpeedClassSpeed) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_speedTest2, _swig_p) - return -} -var _wrap_speedTest3 unsafe.Pointer - -func SpeedTest3(arg1 SpeedClassSpeed) (_swig_ret SpeedClassSpeed) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_speedTest3, _swig_p) - return -} -var _wrap_speedTest4 unsafe.Pointer - -func SpeedTest4(arg1 SpeedClassSpeed) (_swig_ret SpeedClassSpeed) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_speedTest4, _swig_p) - return -} -var _wrap_speedTest5 unsafe.Pointer - -func SpeedTest5(arg1 *SpeedClassSpeed) (_swig_ret *SpeedClassSpeed) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_speedTest5, _swig_p) - return -} -type Namedanon int -var _wrap_NamedAnon1 unsafe.Pointer - -func _swig_getNamedAnon1() (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_NamedAnon1, _swig_p) - return -} -var NamedAnon1 int = _swig_getNamedAnon1() -var _wrap_NamedAnon2 unsafe.Pointer - -func _swig_getNamedAnon2() (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_NamedAnon2, _swig_p) - return -} -var NamedAnon2 int = _swig_getNamedAnon2() -var _wrap_namedanonTest1 unsafe.Pointer - -func NamedanonTest1(arg1 Namedanon) (_swig_ret Namedanon) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_namedanonTest1, _swig_p) - return -} -type Twonamestag int -var _wrap_TwoNames1 unsafe.Pointer - -func _swig_getTwoNames1() (_swig_ret Twonamestag) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_TwoNames1, _swig_p) - return -} -var TwoNames1 Twonamestag = _swig_getTwoNames1() -var _wrap_TwoNames2 unsafe.Pointer - -func _swig_getTwoNames2() (_swig_ret Twonamestag) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_TwoNames2, _swig_p) - return -} -var TwoNames2 Twonamestag = _swig_getTwoNames2() -var _wrap_TwoNames3 unsafe.Pointer - -func _swig_getTwoNames3() (_swig_ret Twonamestag) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_TwoNames3, _swig_p) - return -} -var TwoNames3 Twonamestag = _swig_getTwoNames3() -var _wrap_twonamesTest1 unsafe.Pointer - -func TwonamesTest1(arg1 Twonamestag) (_swig_ret Twonamestag) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_twonamesTest1, _swig_p) - return -} -var _wrap_twonamesTest2 unsafe.Pointer - -func TwonamesTest2(arg1 Twonamestag) (_swig_ret Twonamestag) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_twonamesTest2, _swig_p) - return -} -var _wrap_twonamesTest3 unsafe.Pointer - -func TwonamesTest3(arg1 Twonamestag) (_swig_ret Twonamestag) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_twonamesTest3, _swig_p) - return -} -type SwigcptrTwoNamesStruct uintptr - -func (p SwigcptrTwoNamesStruct) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrTwoNamesStruct) SwigIsTwoNamesStruct() { -} - -type TwoNamesStructTwonamestag int -var _wrap_TwoNamesStruct1_TwoNamesStruct unsafe.Pointer - -func _swig_getTwoNamesStruct_TwoNamesStruct1_TwoNamesStruct() (_swig_ret TwoNamesStructTwonamestag) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_TwoNamesStruct1_TwoNamesStruct, _swig_p) - return -} -var TwoNamesStructTwoNamesStruct1 TwoNamesStructTwonamestag = _swig_getTwoNamesStruct_TwoNamesStruct1_TwoNamesStruct() -var _wrap_TwoNamesStruct2_TwoNamesStruct unsafe.Pointer - -func _swig_getTwoNamesStruct_TwoNamesStruct2_TwoNamesStruct() (_swig_ret TwoNamesStructTwonamestag) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_TwoNamesStruct2_TwoNamesStruct, _swig_p) - return -} -var TwoNamesStructTwoNamesStruct2 TwoNamesStructTwonamestag = _swig_getTwoNamesStruct_TwoNamesStruct2_TwoNamesStruct() -var _wrap_TwoNamesStruct_twonamesTest1 unsafe.Pointer - -func _swig_wrap_TwoNamesStruct_twonamesTest1(base SwigcptrTwoNamesStruct, _ TwoNamesStructTwonamestag) (_ TwoNamesStructTwonamestag) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_TwoNamesStruct_twonamesTest1, _swig_p) - return -} - -func (arg1 SwigcptrTwoNamesStruct) TwonamesTest1(arg2 TwoNamesStructTwonamestag) (_swig_ret TwoNamesStructTwonamestag) { - return _swig_wrap_TwoNamesStruct_twonamesTest1(arg1, arg2) -} - -var _wrap_TwoNamesStruct_twonamesTest2 unsafe.Pointer - -func _swig_wrap_TwoNamesStruct_twonamesTest2(base SwigcptrTwoNamesStruct, _ TwoNamesStructTwonamestag) (_ TwoNamesStructTwonamestag) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_TwoNamesStruct_twonamesTest2, _swig_p) - return -} - -func (arg1 SwigcptrTwoNamesStruct) TwonamesTest2(arg2 TwoNamesStructTwonamestag) (_swig_ret TwoNamesStructTwonamestag) { - return _swig_wrap_TwoNamesStruct_twonamesTest2(arg1, arg2) -} - -var _wrap_TwoNamesStruct_twonamesTest3 unsafe.Pointer - -func _swig_wrap_TwoNamesStruct_twonamesTest3(base SwigcptrTwoNamesStruct, _ TwoNamesStructTwonamestag) (_ TwoNamesStructTwonamestag) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_TwoNamesStruct_twonamesTest3, _swig_p) - return -} - -func (arg1 SwigcptrTwoNamesStruct) TwonamesTest3(arg2 TwoNamesStructTwonamestag) (_swig_ret TwoNamesStructTwonamestag) { - return _swig_wrap_TwoNamesStruct_twonamesTest3(arg1, arg2) -} - -var _wrap_new_TwoNamesStruct unsafe.Pointer - -func _swig_wrap_new_TwoNamesStruct() (base SwigcptrTwoNamesStruct) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_TwoNamesStruct, _swig_p) - return -} - -func NewTwoNamesStruct() (_swig_ret TwoNamesStruct) { - return _swig_wrap_new_TwoNamesStruct() -} - -var _wrap_delete_TwoNamesStruct unsafe.Pointer - -func _swig_wrap_delete_TwoNamesStruct(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_TwoNamesStruct, _swig_p) - return -} - -func DeleteTwoNamesStruct(arg1 TwoNamesStruct) { - _swig_wrap_delete_TwoNamesStruct(arg1.Swigcptr()) -} - -type TwoNamesStruct interface { - Swigcptr() uintptr - SwigIsTwoNamesStruct() - TwonamesTest1(arg2 TwoNamesStructTwonamestag) (_swig_ret TwoNamesStructTwonamestag) - TwonamesTest2(arg2 TwoNamesStructTwonamestag) (_swig_ret TwoNamesStructTwonamestag) - TwonamesTest3(arg2 TwoNamesStructTwonamestag) (_swig_ret TwoNamesStructTwonamestag) -} - -type AnonSpaceNamedanonspace int -var _wrap_NamedAnonSpace1 unsafe.Pointer - -func _swig_getNamedAnonSpace1() (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_NamedAnonSpace1, _swig_p) - return -} -var NamedAnonSpace1 int = _swig_getNamedAnonSpace1() -var _wrap_NamedAnonSpace2 unsafe.Pointer - -func _swig_getNamedAnonSpace2() (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_NamedAnonSpace2, _swig_p) - return -} -var NamedAnonSpace2 int = _swig_getNamedAnonSpace2() -var _wrap_namedanonspaceTest1 unsafe.Pointer - -func NamedanonspaceTest1(arg1 AnonSpaceNamedanonspace) (_swig_ret AnonSpaceNamedanonspace) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_namedanonspaceTest1, _swig_p) - return -} -var _wrap_namedanonspaceTest2 unsafe.Pointer - -func NamedanonspaceTest2(arg1 AnonSpaceNamedanonspace) (_swig_ret AnonSpaceNamedanonspace) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_namedanonspaceTest2, _swig_p) - return -} -var _wrap_namedanonspaceTest3 unsafe.Pointer - -func NamedanonspaceTest3(arg1 AnonSpaceNamedanonspace) (_swig_ret AnonSpaceNamedanonspace) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_namedanonspaceTest3, _swig_p) - return -} -var _wrap_namedanonspaceTest4 unsafe.Pointer - -func NamedanonspaceTest4(arg1 AnonSpaceNamedanonspace) (_swig_ret AnonSpaceNamedanonspace) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_namedanonspaceTest4, _swig_p) - return -} -var _wrap_scientistsTest1 unsafe.Pointer - -func ScientistsTest1(arg1 TemplateClass_Sl_int_Sg_Scientists) (_swig_ret TemplateClass_Sl_int_Sg_Scientists) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_scientistsTest1, _swig_p) - return -} -var _wrap_scientistsTest2 unsafe.Pointer - -func ScientistsTest2(arg1 TemplateClass_Sl_int_Sg_Scientists) (_swig_ret TemplateClass_Sl_int_Sg_Scientists) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_scientistsTest2, _swig_p) - return -} -var _wrap_scientistsTest3 unsafe.Pointer - -func ScientistsTest3(arg1 TemplateClass_Sl_int_Sg_Scientists) (_swig_ret TemplateClass_Sl_int_Sg_Scientists) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_scientistsTest3, _swig_p) - return -} -var _wrap_scientistsTest4 unsafe.Pointer - -func ScientistsTest4(arg1 TemplateClass_Sl_int_Sg_Scientists) (_swig_ret TemplateClass_Sl_int_Sg_Scientists) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_scientistsTest4, _swig_p) - return -} -var _wrap_scientistsTest5 unsafe.Pointer - -func ScientistsTest5(arg1 TemplateClass_Sl_int_Sg_Scientists) (_swig_ret TemplateClass_Sl_int_Sg_Scientists) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_scientistsTest5, _swig_p) - return -} -var _wrap_scientistsTest6 unsafe.Pointer - -func ScientistsTest6(arg1 TemplateClass_Sl_int_Sg_Scientists) (_swig_ret TemplateClass_Sl_int_Sg_Scientists) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_scientistsTest6, _swig_p) - return -} -var _wrap_scientistsTest7 unsafe.Pointer - -func ScientistsTest7(arg1 TemplateClass_Sl_int_Sg_Scientists) (_swig_ret TemplateClass_Sl_int_Sg_Scientists) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_scientistsTest7, _swig_p) - return -} -var _wrap_scientistsTest8 unsafe.Pointer - -func ScientistsTest8(arg1 *TemplateClass_Sl_int_Sg_Scientists) (_swig_ret *TemplateClass_Sl_int_Sg_Scientists) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_scientistsTest8, _swig_p) - return -} -var _wrap_scientistsNameTest1 unsafe.Pointer - -func ScientistsNameTest1(arg1 NameTClass_Sl_int_Sg_Scientists) (_swig_ret NameTClass_Sl_int_Sg_Scientists) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_scientistsNameTest1, _swig_p) - return -} -var _wrap_scientistsNameTest2 unsafe.Pointer - -func ScientistsNameTest2(arg1 NameTClass_Sl_int_Sg_Scientists) (_swig_ret NameTClass_Sl_int_Sg_Scientists) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_scientistsNameTest2, _swig_p) - return -} -var _wrap_scientistsNameTest3 unsafe.Pointer - -func ScientistsNameTest3(arg1 NameTClass_Sl_int_Sg_Scientists) (_swig_ret NameTClass_Sl_int_Sg_Scientists) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_scientistsNameTest3, _swig_p) - return -} -var _wrap_scientistsNameTest4 unsafe.Pointer - -func ScientistsNameTest4(arg1 NameTClass_Sl_int_Sg_Scientists) (_swig_ret NameTClass_Sl_int_Sg_Scientists) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_scientistsNameTest4, _swig_p) - return -} -var _wrap_scientistsNameTest5 unsafe.Pointer - -func ScientistsNameTest5(arg1 NameTClass_Sl_int_Sg_Scientists) (_swig_ret NameTClass_Sl_int_Sg_Scientists) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_scientistsNameTest5, _swig_p) - return -} -var _wrap_scientistsNameTest6 unsafe.Pointer - -func ScientistsNameTest6(arg1 NameTClass_Sl_int_Sg_Scientists) (_swig_ret NameTClass_Sl_int_Sg_Scientists) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_scientistsNameTest6, _swig_p) - return -} -var _wrap_scientistsNameTest7 unsafe.Pointer - -func ScientistsNameTest7(arg1 NameTClass_Sl_int_Sg_Scientists) (_swig_ret NameTClass_Sl_int_Sg_Scientists) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_scientistsNameTest7, _swig_p) - return -} -var _wrap_scientistsNameSpaceTest1 unsafe.Pointer - -func ScientistsNameSpaceTest1(arg1 NameTClass_Sl_int_Sg_Scientists) (_swig_ret NameTClass_Sl_int_Sg_Scientists) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_scientistsNameSpaceTest1, _swig_p) - return -} -var _wrap_scientistsNameSpaceTest2 unsafe.Pointer - -func ScientistsNameSpaceTest2(arg1 NameTClass_Sl_int_Sg_Scientists) (_swig_ret NameTClass_Sl_int_Sg_Scientists) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_scientistsNameSpaceTest2, _swig_p) - return -} -var _wrap_scientistsNameSpaceTest3 unsafe.Pointer - -func ScientistsNameSpaceTest3(arg1 NameTClass_Sl_int_Sg_Scientists) (_swig_ret NameTClass_Sl_int_Sg_Scientists) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_scientistsNameSpaceTest3, _swig_p) - return -} -var _wrap_scientistsNameSpaceTest4 unsafe.Pointer - -func ScientistsNameSpaceTest4(arg1 NameTClass_Sl_int_Sg_Scientists) (_swig_ret NameTClass_Sl_int_Sg_Scientists) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_scientistsNameSpaceTest4, _swig_p) - return -} -var _wrap_scientistsNameSpaceTest5 unsafe.Pointer - -func ScientistsNameSpaceTest5(arg1 NameTClass_Sl_int_Sg_Scientists) (_swig_ret NameTClass_Sl_int_Sg_Scientists) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_scientistsNameSpaceTest5, _swig_p) - return -} -var _wrap_scientistsNameSpaceTest6 unsafe.Pointer - -func ScientistsNameSpaceTest6(arg1 NameTClass_Sl_int_Sg_Scientists) (_swig_ret NameTClass_Sl_int_Sg_Scientists) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_scientistsNameSpaceTest6, _swig_p) - return -} -var _wrap_scientistsNameSpaceTest7 unsafe.Pointer - -func ScientistsNameSpaceTest7(arg1 NameTClass_Sl_int_Sg_Scientists) (_swig_ret NameTClass_Sl_int_Sg_Scientists) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_scientistsNameSpaceTest7, _swig_p) - return -} -var _wrap_scientistsNameSpaceTest8 unsafe.Pointer - -func ScientistsNameSpaceTest8(arg1 NameTClass_Sl_int_Sg_Scientists) (_swig_ret NameTClass_Sl_int_Sg_Scientists) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_scientistsNameSpaceTest8, _swig_p) - return -} -var _wrap_scientistsNameSpaceTest9 unsafe.Pointer - -func ScientistsNameSpaceTest9(arg1 NameTClass_Sl_int_Sg_Scientists) (_swig_ret NameTClass_Sl_int_Sg_Scientists) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_scientistsNameSpaceTest9, _swig_p) - return -} -var _wrap_scientistsNameSpaceTestA unsafe.Pointer - -func ScientistsNameSpaceTestA(arg1 NameTClass_Sl_int_Sg_Scientists) (_swig_ret NameTClass_Sl_int_Sg_Scientists) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_scientistsNameSpaceTestA, _swig_p) - return -} -var _wrap_scientistsNameSpaceTestB unsafe.Pointer - -func ScientistsNameSpaceTestB(arg1 NameTClass_Sl_int_Sg_Scientists) (_swig_ret NameTClass_Sl_int_Sg_Scientists) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_scientistsNameSpaceTestB, _swig_p) - return -} -var _wrap_scientistsNameSpaceTestC unsafe.Pointer - -func ScientistsNameSpaceTestC(arg1 NameTClass_Sl_int_Sg_Scientists) (_swig_ret NameTClass_Sl_int_Sg_Scientists) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_scientistsNameSpaceTestC, _swig_p) - return -} -var _wrap_scientistsNameSpaceTestD unsafe.Pointer - -func ScientistsNameSpaceTestD(arg1 NameTClass_Sl_int_Sg_Scientists) (_swig_ret NameTClass_Sl_int_Sg_Scientists) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_scientistsNameSpaceTestD, _swig_p) - return -} -var _wrap_scientistsNameSpaceTestE unsafe.Pointer - -func ScientistsNameSpaceTestE(arg1 NameTClass_Sl_int_Sg_Scientists) (_swig_ret NameTClass_Sl_int_Sg_Scientists) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_scientistsNameSpaceTestE, _swig_p) - return -} -var _wrap_scientistsNameSpaceTestF unsafe.Pointer - -func ScientistsNameSpaceTestF(arg1 NameTClass_Sl_int_Sg_Scientists) (_swig_ret NameTClass_Sl_int_Sg_Scientists) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_scientistsNameSpaceTestF, _swig_p) - return -} -var _wrap_scientistsNameSpaceTestG unsafe.Pointer - -func ScientistsNameSpaceTestG(arg1 NameTClass_Sl_int_Sg_Scientists) (_swig_ret NameTClass_Sl_int_Sg_Scientists) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_scientistsNameSpaceTestG, _swig_p) - return -} -var _wrap_scientistsNameSpaceTestH unsafe.Pointer - -func ScientistsNameSpaceTestH(arg1 NameTClass_Sl_int_Sg_Scientists) (_swig_ret NameTClass_Sl_int_Sg_Scientists) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_scientistsNameSpaceTestH, _swig_p) - return -} -var _wrap_scientistsNameSpaceTestI unsafe.Pointer - -func ScientistsNameSpaceTestI(arg1 NameTClass_Sl_int_Sg_Scientists) (_swig_ret NameTClass_Sl_int_Sg_Scientists) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_scientistsNameSpaceTestI, _swig_p) - return -} -var _wrap_scientistsNameSpaceTestJ unsafe.Pointer - -func ScientistsNameSpaceTestJ(arg1 NameTClass_Sl_int_Sg_Scientists) (_swig_ret NameTClass_Sl_int_Sg_Scientists) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_scientistsNameSpaceTestJ, _swig_p) - return -} -var _wrap_scientistsNameSpaceTestK unsafe.Pointer - -func ScientistsNameSpaceTestK(arg1 NameTClass_Sl_int_Sg_Scientists) (_swig_ret NameTClass_Sl_int_Sg_Scientists) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_scientistsNameSpaceTestK, _swig_p) - return -} -var _wrap_scientistsNameSpaceTestL unsafe.Pointer - -func ScientistsNameSpaceTestL(arg1 NameTClass_Sl_int_Sg_Scientists) (_swig_ret NameTClass_Sl_int_Sg_Scientists) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_scientistsNameSpaceTestL, _swig_p) - return -} -type SwigcptrTemplateClassInt uintptr - -func (p SwigcptrTemplateClassInt) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrTemplateClassInt) SwigIsTemplateClassInt() { -} - -type TemplateClass_Sl_int_Sg_Scientists int -var _wrap_einstein_TemplateClassInt unsafe.Pointer - -func _swig_getTemplateClassInt_einstein_TemplateClassInt() (_swig_ret TemplateClass_Sl_int_Sg_Scientists) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_einstein_TemplateClassInt, _swig_p) - return -} -var TemplateClassIntEinstein TemplateClass_Sl_int_Sg_Scientists = _swig_getTemplateClassInt_einstein_TemplateClassInt() -var _wrap_galileo_TemplateClassInt unsafe.Pointer - -func _swig_getTemplateClassInt_galileo_TemplateClassInt() (_swig_ret TemplateClass_Sl_int_Sg_Scientists) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_galileo_TemplateClassInt, _swig_p) - return -} -var TemplateClassIntGalileo TemplateClass_Sl_int_Sg_Scientists = _swig_getTemplateClassInt_galileo_TemplateClassInt() -var _wrap_TemplateClassInt_scientistsTest1 unsafe.Pointer - -func _swig_wrap_TemplateClassInt_scientistsTest1(base SwigcptrTemplateClassInt, _ TemplateClass_Sl_int_Sg_Scientists) (_ TemplateClass_Sl_int_Sg_Scientists) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_TemplateClassInt_scientistsTest1, _swig_p) - return -} - -func (arg1 SwigcptrTemplateClassInt) ScientistsTest1(arg2 TemplateClass_Sl_int_Sg_Scientists) (_swig_ret TemplateClass_Sl_int_Sg_Scientists) { - return _swig_wrap_TemplateClassInt_scientistsTest1(arg1, arg2) -} - -var _wrap_TemplateClassInt_scientistsTest2 unsafe.Pointer - -func _swig_wrap_TemplateClassInt_scientistsTest2(base SwigcptrTemplateClassInt, _ TemplateClass_Sl_int_Sg_Scientists) (_ TemplateClass_Sl_int_Sg_Scientists) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_TemplateClassInt_scientistsTest2, _swig_p) - return -} - -func (arg1 SwigcptrTemplateClassInt) ScientistsTest2(arg2 TemplateClass_Sl_int_Sg_Scientists) (_swig_ret TemplateClass_Sl_int_Sg_Scientists) { - return _swig_wrap_TemplateClassInt_scientistsTest2(arg1, arg2) -} - -var _wrap_TemplateClassInt_scientistsTest3 unsafe.Pointer - -func _swig_wrap_TemplateClassInt_scientistsTest3(base SwigcptrTemplateClassInt, _ TemplateClass_Sl_int_Sg_Scientists) (_ TemplateClass_Sl_int_Sg_Scientists) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_TemplateClassInt_scientistsTest3, _swig_p) - return -} - -func (arg1 SwigcptrTemplateClassInt) ScientistsTest3(arg2 TemplateClass_Sl_int_Sg_Scientists) (_swig_ret TemplateClass_Sl_int_Sg_Scientists) { - return _swig_wrap_TemplateClassInt_scientistsTest3(arg1, arg2) -} - -var _wrap_TemplateClassInt_scientistsTest4 unsafe.Pointer - -func _swig_wrap_TemplateClassInt_scientistsTest4(base SwigcptrTemplateClassInt, _ TemplateClass_Sl_int_Sg_Scientists) (_ TemplateClass_Sl_int_Sg_Scientists) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_TemplateClassInt_scientistsTest4, _swig_p) - return -} - -func (arg1 SwigcptrTemplateClassInt) ScientistsTest4(arg2 TemplateClass_Sl_int_Sg_Scientists) (_swig_ret TemplateClass_Sl_int_Sg_Scientists) { - return _swig_wrap_TemplateClassInt_scientistsTest4(arg1, arg2) -} - -var _wrap_TemplateClassInt_scientistsTest5 unsafe.Pointer - -func _swig_wrap_TemplateClassInt_scientistsTest5(base SwigcptrTemplateClassInt, _ TemplateClass_Sl_int_Sg_Scientists) (_ TemplateClass_Sl_int_Sg_Scientists) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_TemplateClassInt_scientistsTest5, _swig_p) - return -} - -func (arg1 SwigcptrTemplateClassInt) ScientistsTest5(arg2 TemplateClass_Sl_int_Sg_Scientists) (_swig_ret TemplateClass_Sl_int_Sg_Scientists) { - return _swig_wrap_TemplateClassInt_scientistsTest5(arg1, arg2) -} - -var _wrap_TemplateClassInt_scientistsTest6 unsafe.Pointer - -func _swig_wrap_TemplateClassInt_scientistsTest6(base SwigcptrTemplateClassInt, _ TemplateClass_Sl_int_Sg_Scientists) (_ TemplateClass_Sl_int_Sg_Scientists) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_TemplateClassInt_scientistsTest6, _swig_p) - return -} - -func (arg1 SwigcptrTemplateClassInt) ScientistsTest6(arg2 TemplateClass_Sl_int_Sg_Scientists) (_swig_ret TemplateClass_Sl_int_Sg_Scientists) { - return _swig_wrap_TemplateClassInt_scientistsTest6(arg1, arg2) -} - -var _wrap_TemplateClassInt_scientistsTest7 unsafe.Pointer - -func _swig_wrap_TemplateClassInt_scientistsTest7(base SwigcptrTemplateClassInt, _ TemplateClass_Sl_int_Sg_Scientists) (_ TemplateClass_Sl_int_Sg_Scientists) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_TemplateClassInt_scientistsTest7, _swig_p) - return -} - -func (arg1 SwigcptrTemplateClassInt) ScientistsTest7(arg2 TemplateClass_Sl_int_Sg_Scientists) (_swig_ret TemplateClass_Sl_int_Sg_Scientists) { - return _swig_wrap_TemplateClassInt_scientistsTest7(arg1, arg2) -} - -var _wrap_TemplateClassInt_scientistsTest8 unsafe.Pointer - -func _swig_wrap_TemplateClassInt_scientistsTest8(base SwigcptrTemplateClassInt, _ TemplateClass_Sl_int_Sg_Scientists) (_ TemplateClass_Sl_int_Sg_Scientists) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_TemplateClassInt_scientistsTest8, _swig_p) - return -} - -func (arg1 SwigcptrTemplateClassInt) ScientistsTest8(arg2 TemplateClass_Sl_int_Sg_Scientists) (_swig_ret TemplateClass_Sl_int_Sg_Scientists) { - return _swig_wrap_TemplateClassInt_scientistsTest8(arg1, arg2) -} - -var _wrap_TemplateClassInt_scientistsTest9 unsafe.Pointer - -func _swig_wrap_TemplateClassInt_scientistsTest9(base SwigcptrTemplateClassInt, _ TemplateClass_Sl_int_Sg_Scientists) (_ TemplateClass_Sl_int_Sg_Scientists) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_TemplateClassInt_scientistsTest9, _swig_p) - return -} - -func (arg1 SwigcptrTemplateClassInt) ScientistsTest9(arg2 TemplateClass_Sl_int_Sg_Scientists) (_swig_ret TemplateClass_Sl_int_Sg_Scientists) { - return _swig_wrap_TemplateClassInt_scientistsTest9(arg1, arg2) -} - -var _wrap_TemplateClassInt_scientistsTestB unsafe.Pointer - -func _swig_wrap_TemplateClassInt_scientistsTestB(base SwigcptrTemplateClassInt, _ TemplateClass_Sl_int_Sg_Scientists) (_ TemplateClass_Sl_int_Sg_Scientists) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_TemplateClassInt_scientistsTestB, _swig_p) - return -} - -func (arg1 SwigcptrTemplateClassInt) ScientistsTestB(arg2 TemplateClass_Sl_int_Sg_Scientists) (_swig_ret TemplateClass_Sl_int_Sg_Scientists) { - return _swig_wrap_TemplateClassInt_scientistsTestB(arg1, arg2) -} - -var _wrap_TemplateClassInt_scientistsTestD unsafe.Pointer - -func _swig_wrap_TemplateClassInt_scientistsTestD(base SwigcptrTemplateClassInt, _ TemplateClass_Sl_int_Sg_Scientists) (_ TemplateClass_Sl_int_Sg_Scientists) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_TemplateClassInt_scientistsTestD, _swig_p) - return -} - -func (arg1 SwigcptrTemplateClassInt) ScientistsTestD(arg2 TemplateClass_Sl_int_Sg_Scientists) (_swig_ret TemplateClass_Sl_int_Sg_Scientists) { - return _swig_wrap_TemplateClassInt_scientistsTestD(arg1, arg2) -} - -var _wrap_TemplateClassInt_scientistsTestE unsafe.Pointer - -func _swig_wrap_TemplateClassInt_scientistsTestE(base SwigcptrTemplateClassInt, _ TemplateClass_Sl_int_Sg_Scientists) (_ TemplateClass_Sl_int_Sg_Scientists) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_TemplateClassInt_scientistsTestE, _swig_p) - return -} - -func (arg1 SwigcptrTemplateClassInt) ScientistsTestE(arg2 TemplateClass_Sl_int_Sg_Scientists) (_swig_ret TemplateClass_Sl_int_Sg_Scientists) { - return _swig_wrap_TemplateClassInt_scientistsTestE(arg1, arg2) -} - -var _wrap_TemplateClassInt_scientistsTestF unsafe.Pointer - -func _swig_wrap_TemplateClassInt_scientistsTestF(base SwigcptrTemplateClassInt, _ TemplateClass_Sl_int_Sg_Scientists) (_ TemplateClass_Sl_int_Sg_Scientists) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_TemplateClassInt_scientistsTestF, _swig_p) - return -} - -func (arg1 SwigcptrTemplateClassInt) ScientistsTestF(arg2 TemplateClass_Sl_int_Sg_Scientists) (_swig_ret TemplateClass_Sl_int_Sg_Scientists) { - return _swig_wrap_TemplateClassInt_scientistsTestF(arg1, arg2) -} - -var _wrap_TemplateClassInt_scientistsTestG unsafe.Pointer - -func _swig_wrap_TemplateClassInt_scientistsTestG(base SwigcptrTemplateClassInt, _ TemplateClass_Sl_int_Sg_Scientists) (_ TemplateClass_Sl_int_Sg_Scientists) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_TemplateClassInt_scientistsTestG, _swig_p) - return -} - -func (arg1 SwigcptrTemplateClassInt) ScientistsTestG(arg2 TemplateClass_Sl_int_Sg_Scientists) (_swig_ret TemplateClass_Sl_int_Sg_Scientists) { - return _swig_wrap_TemplateClassInt_scientistsTestG(arg1, arg2) -} - -var _wrap_TemplateClassInt_scientistsTestH unsafe.Pointer - -func _swig_wrap_TemplateClassInt_scientistsTestH(base SwigcptrTemplateClassInt, _ TemplateClass_Sl_int_Sg_Scientists) (_ TemplateClass_Sl_int_Sg_Scientists) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_TemplateClassInt_scientistsTestH, _swig_p) - return -} - -func (arg1 SwigcptrTemplateClassInt) ScientistsTestH(arg2 TemplateClass_Sl_int_Sg_Scientists) (_swig_ret TemplateClass_Sl_int_Sg_Scientists) { - return _swig_wrap_TemplateClassInt_scientistsTestH(arg1, arg2) -} - -var _wrap_TemplateClassInt_scientistsTestI unsafe.Pointer - -func _swig_wrap_TemplateClassInt_scientistsTestI(base SwigcptrTemplateClassInt, _ TemplateClass_Sl_int_Sg_Scientists) (_ TemplateClass_Sl_int_Sg_Scientists) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_TemplateClassInt_scientistsTestI, _swig_p) - return -} - -func (arg1 SwigcptrTemplateClassInt) ScientistsTestI(arg2 TemplateClass_Sl_int_Sg_Scientists) (_swig_ret TemplateClass_Sl_int_Sg_Scientists) { - return _swig_wrap_TemplateClassInt_scientistsTestI(arg1, arg2) -} - -var _wrap_TemplateClassInt_scientistsTestJ unsafe.Pointer - -func _swig_wrap_TemplateClassInt_scientistsTestJ(base SwigcptrTemplateClassInt, _ *TemplateClass_Sl_int_Sg_Scientists) (_ *TemplateClass_Sl_int_Sg_Scientists) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_TemplateClassInt_scientistsTestJ, _swig_p) - return -} - -func (arg1 SwigcptrTemplateClassInt) ScientistsTestJ(arg2 *TemplateClass_Sl_int_Sg_Scientists) (_swig_ret *TemplateClass_Sl_int_Sg_Scientists) { - return _swig_wrap_TemplateClassInt_scientistsTestJ(arg1, arg2) -} - -var _wrap_new_TemplateClassInt unsafe.Pointer - -func _swig_wrap_new_TemplateClassInt() (base SwigcptrTemplateClassInt) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_TemplateClassInt, _swig_p) - return -} - -func NewTemplateClassInt() (_swig_ret TemplateClassInt) { - return _swig_wrap_new_TemplateClassInt() -} - -var _wrap_delete_TemplateClassInt unsafe.Pointer - -func _swig_wrap_delete_TemplateClassInt(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_TemplateClassInt, _swig_p) - return -} - -func DeleteTemplateClassInt(arg1 TemplateClassInt) { - _swig_wrap_delete_TemplateClassInt(arg1.Swigcptr()) -} - -type TemplateClassInt interface { - Swigcptr() uintptr - SwigIsTemplateClassInt() - ScientistsTest1(arg2 TemplateClass_Sl_int_Sg_Scientists) (_swig_ret TemplateClass_Sl_int_Sg_Scientists) - ScientistsTest2(arg2 TemplateClass_Sl_int_Sg_Scientists) (_swig_ret TemplateClass_Sl_int_Sg_Scientists) - ScientistsTest3(arg2 TemplateClass_Sl_int_Sg_Scientists) (_swig_ret TemplateClass_Sl_int_Sg_Scientists) - ScientistsTest4(arg2 TemplateClass_Sl_int_Sg_Scientists) (_swig_ret TemplateClass_Sl_int_Sg_Scientists) - ScientistsTest5(arg2 TemplateClass_Sl_int_Sg_Scientists) (_swig_ret TemplateClass_Sl_int_Sg_Scientists) - ScientistsTest6(arg2 TemplateClass_Sl_int_Sg_Scientists) (_swig_ret TemplateClass_Sl_int_Sg_Scientists) - ScientistsTest7(arg2 TemplateClass_Sl_int_Sg_Scientists) (_swig_ret TemplateClass_Sl_int_Sg_Scientists) - ScientistsTest8(arg2 TemplateClass_Sl_int_Sg_Scientists) (_swig_ret TemplateClass_Sl_int_Sg_Scientists) - ScientistsTest9(arg2 TemplateClass_Sl_int_Sg_Scientists) (_swig_ret TemplateClass_Sl_int_Sg_Scientists) - ScientistsTestB(arg2 TemplateClass_Sl_int_Sg_Scientists) (_swig_ret TemplateClass_Sl_int_Sg_Scientists) - ScientistsTestD(arg2 TemplateClass_Sl_int_Sg_Scientists) (_swig_ret TemplateClass_Sl_int_Sg_Scientists) - ScientistsTestE(arg2 TemplateClass_Sl_int_Sg_Scientists) (_swig_ret TemplateClass_Sl_int_Sg_Scientists) - ScientistsTestF(arg2 TemplateClass_Sl_int_Sg_Scientists) (_swig_ret TemplateClass_Sl_int_Sg_Scientists) - ScientistsTestG(arg2 TemplateClass_Sl_int_Sg_Scientists) (_swig_ret TemplateClass_Sl_int_Sg_Scientists) - ScientistsTestH(arg2 TemplateClass_Sl_int_Sg_Scientists) (_swig_ret TemplateClass_Sl_int_Sg_Scientists) - ScientistsTestI(arg2 TemplateClass_Sl_int_Sg_Scientists) (_swig_ret TemplateClass_Sl_int_Sg_Scientists) - ScientistsTestJ(arg2 *TemplateClass_Sl_int_Sg_Scientists) (_swig_ret *TemplateClass_Sl_int_Sg_Scientists) -} - -type SwigcptrTClassInt uintptr - -func (p SwigcptrTClassInt) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrTClassInt) SwigIsTClassInt() { -} - -type NameTClass_Sl_int_Sg_Scientists int -var _wrap_faraday_TClassInt unsafe.Pointer - -func _swig_getTClassInt_faraday_TClassInt() (_swig_ret NameTClass_Sl_int_Sg_Scientists) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_faraday_TClassInt, _swig_p) - return -} -var TClassIntFaraday NameTClass_Sl_int_Sg_Scientists = _swig_getTClassInt_faraday_TClassInt() -var _wrap_bell_TClassInt unsafe.Pointer - -func _swig_getTClassInt_bell_TClassInt() (_swig_ret NameTClass_Sl_int_Sg_Scientists) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_bell_TClassInt, _swig_p) - return -} -var TClassIntBell NameTClass_Sl_int_Sg_Scientists = _swig_getTClassInt_bell_TClassInt() -var _wrap_TClassInt_scientistsNameTest1 unsafe.Pointer - -func _swig_wrap_TClassInt_scientistsNameTest1(base SwigcptrTClassInt, _ NameTClass_Sl_int_Sg_Scientists) (_ NameTClass_Sl_int_Sg_Scientists) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_TClassInt_scientistsNameTest1, _swig_p) - return -} - -func (arg1 SwigcptrTClassInt) ScientistsNameTest1(arg2 NameTClass_Sl_int_Sg_Scientists) (_swig_ret NameTClass_Sl_int_Sg_Scientists) { - return _swig_wrap_TClassInt_scientistsNameTest1(arg1, arg2) -} - -var _wrap_TClassInt_scientistsNameTest2 unsafe.Pointer - -func _swig_wrap_TClassInt_scientistsNameTest2(base SwigcptrTClassInt, _ NameTClass_Sl_int_Sg_Scientists) (_ NameTClass_Sl_int_Sg_Scientists) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_TClassInt_scientistsNameTest2, _swig_p) - return -} - -func (arg1 SwigcptrTClassInt) ScientistsNameTest2(arg2 NameTClass_Sl_int_Sg_Scientists) (_swig_ret NameTClass_Sl_int_Sg_Scientists) { - return _swig_wrap_TClassInt_scientistsNameTest2(arg1, arg2) -} - -var _wrap_TClassInt_scientistsNameTest3 unsafe.Pointer - -func _swig_wrap_TClassInt_scientistsNameTest3(base SwigcptrTClassInt, _ NameTClass_Sl_int_Sg_Scientists) (_ NameTClass_Sl_int_Sg_Scientists) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_TClassInt_scientistsNameTest3, _swig_p) - return -} - -func (arg1 SwigcptrTClassInt) ScientistsNameTest3(arg2 NameTClass_Sl_int_Sg_Scientists) (_swig_ret NameTClass_Sl_int_Sg_Scientists) { - return _swig_wrap_TClassInt_scientistsNameTest3(arg1, arg2) -} - -var _wrap_TClassInt_scientistsNameTest4 unsafe.Pointer - -func _swig_wrap_TClassInt_scientistsNameTest4(base SwigcptrTClassInt, _ NameTClass_Sl_int_Sg_Scientists) (_ NameTClass_Sl_int_Sg_Scientists) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_TClassInt_scientistsNameTest4, _swig_p) - return -} - -func (arg1 SwigcptrTClassInt) ScientistsNameTest4(arg2 NameTClass_Sl_int_Sg_Scientists) (_swig_ret NameTClass_Sl_int_Sg_Scientists) { - return _swig_wrap_TClassInt_scientistsNameTest4(arg1, arg2) -} - -var _wrap_TClassInt_scientistsNameTest5 unsafe.Pointer - -func _swig_wrap_TClassInt_scientistsNameTest5(base SwigcptrTClassInt, _ NameTClass_Sl_int_Sg_Scientists) (_ NameTClass_Sl_int_Sg_Scientists) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_TClassInt_scientistsNameTest5, _swig_p) - return -} - -func (arg1 SwigcptrTClassInt) ScientistsNameTest5(arg2 NameTClass_Sl_int_Sg_Scientists) (_swig_ret NameTClass_Sl_int_Sg_Scientists) { - return _swig_wrap_TClassInt_scientistsNameTest5(arg1, arg2) -} - -var _wrap_TClassInt_scientistsNameTest6 unsafe.Pointer - -func _swig_wrap_TClassInt_scientistsNameTest6(base SwigcptrTClassInt, _ NameTClass_Sl_int_Sg_Scientists) (_ NameTClass_Sl_int_Sg_Scientists) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_TClassInt_scientistsNameTest6, _swig_p) - return -} - -func (arg1 SwigcptrTClassInt) ScientistsNameTest6(arg2 NameTClass_Sl_int_Sg_Scientists) (_swig_ret NameTClass_Sl_int_Sg_Scientists) { - return _swig_wrap_TClassInt_scientistsNameTest6(arg1, arg2) -} - -var _wrap_TClassInt_scientistsNameTest7 unsafe.Pointer - -func _swig_wrap_TClassInt_scientistsNameTest7(base SwigcptrTClassInt, _ NameTClass_Sl_int_Sg_Scientists) (_ NameTClass_Sl_int_Sg_Scientists) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_TClassInt_scientistsNameTest7, _swig_p) - return -} - -func (arg1 SwigcptrTClassInt) ScientistsNameTest7(arg2 NameTClass_Sl_int_Sg_Scientists) (_swig_ret NameTClass_Sl_int_Sg_Scientists) { - return _swig_wrap_TClassInt_scientistsNameTest7(arg1, arg2) -} - -var _wrap_TClassInt_scientistsNameTest8 unsafe.Pointer - -func _swig_wrap_TClassInt_scientistsNameTest8(base SwigcptrTClassInt, _ NameTClass_Sl_int_Sg_Scientists) (_ NameTClass_Sl_int_Sg_Scientists) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_TClassInt_scientistsNameTest8, _swig_p) - return -} - -func (arg1 SwigcptrTClassInt) ScientistsNameTest8(arg2 NameTClass_Sl_int_Sg_Scientists) (_swig_ret NameTClass_Sl_int_Sg_Scientists) { - return _swig_wrap_TClassInt_scientistsNameTest8(arg1, arg2) -} - -var _wrap_TClassInt_scientistsNameTest9 unsafe.Pointer - -func _swig_wrap_TClassInt_scientistsNameTest9(base SwigcptrTClassInt, _ NameTClass_Sl_int_Sg_Scientists) (_ NameTClass_Sl_int_Sg_Scientists) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_TClassInt_scientistsNameTest9, _swig_p) - return -} - -func (arg1 SwigcptrTClassInt) ScientistsNameTest9(arg2 NameTClass_Sl_int_Sg_Scientists) (_swig_ret NameTClass_Sl_int_Sg_Scientists) { - return _swig_wrap_TClassInt_scientistsNameTest9(arg1, arg2) -} - -var _wrap_TClassInt_scientistsNameTestB unsafe.Pointer - -func _swig_wrap_TClassInt_scientistsNameTestB(base SwigcptrTClassInt, _ NameTClass_Sl_int_Sg_Scientists) (_ NameTClass_Sl_int_Sg_Scientists) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_TClassInt_scientistsNameTestB, _swig_p) - return -} - -func (arg1 SwigcptrTClassInt) ScientistsNameTestB(arg2 NameTClass_Sl_int_Sg_Scientists) (_swig_ret NameTClass_Sl_int_Sg_Scientists) { - return _swig_wrap_TClassInt_scientistsNameTestB(arg1, arg2) -} - -var _wrap_TClassInt_scientistsNameTestD unsafe.Pointer - -func _swig_wrap_TClassInt_scientistsNameTestD(base SwigcptrTClassInt, _ NameTClass_Sl_int_Sg_Scientists) (_ NameTClass_Sl_int_Sg_Scientists) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_TClassInt_scientistsNameTestD, _swig_p) - return -} - -func (arg1 SwigcptrTClassInt) ScientistsNameTestD(arg2 NameTClass_Sl_int_Sg_Scientists) (_swig_ret NameTClass_Sl_int_Sg_Scientists) { - return _swig_wrap_TClassInt_scientistsNameTestD(arg1, arg2) -} - -var _wrap_TClassInt_scientistsNameTestE unsafe.Pointer - -func _swig_wrap_TClassInt_scientistsNameTestE(base SwigcptrTClassInt, _ NameTClass_Sl_int_Sg_Scientists) (_ NameTClass_Sl_int_Sg_Scientists) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_TClassInt_scientistsNameTestE, _swig_p) - return -} - -func (arg1 SwigcptrTClassInt) ScientistsNameTestE(arg2 NameTClass_Sl_int_Sg_Scientists) (_swig_ret NameTClass_Sl_int_Sg_Scientists) { - return _swig_wrap_TClassInt_scientistsNameTestE(arg1, arg2) -} - -var _wrap_TClassInt_scientistsNameTestF unsafe.Pointer - -func _swig_wrap_TClassInt_scientistsNameTestF(base SwigcptrTClassInt, _ NameTClass_Sl_int_Sg_Scientists) (_ NameTClass_Sl_int_Sg_Scientists) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_TClassInt_scientistsNameTestF, _swig_p) - return -} - -func (arg1 SwigcptrTClassInt) ScientistsNameTestF(arg2 NameTClass_Sl_int_Sg_Scientists) (_swig_ret NameTClass_Sl_int_Sg_Scientists) { - return _swig_wrap_TClassInt_scientistsNameTestF(arg1, arg2) -} - -var _wrap_TClassInt_scientistsNameTestG unsafe.Pointer - -func _swig_wrap_TClassInt_scientistsNameTestG(base SwigcptrTClassInt, _ NameTClass_Sl_int_Sg_Scientists) (_ NameTClass_Sl_int_Sg_Scientists) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_TClassInt_scientistsNameTestG, _swig_p) - return -} - -func (arg1 SwigcptrTClassInt) ScientistsNameTestG(arg2 NameTClass_Sl_int_Sg_Scientists) (_swig_ret NameTClass_Sl_int_Sg_Scientists) { - return _swig_wrap_TClassInt_scientistsNameTestG(arg1, arg2) -} - -var _wrap_TClassInt_scientistsNameTestH unsafe.Pointer - -func _swig_wrap_TClassInt_scientistsNameTestH(base SwigcptrTClassInt, _ NameTClass_Sl_int_Sg_Scientists) (_ NameTClass_Sl_int_Sg_Scientists) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_TClassInt_scientistsNameTestH, _swig_p) - return -} - -func (arg1 SwigcptrTClassInt) ScientistsNameTestH(arg2 NameTClass_Sl_int_Sg_Scientists) (_swig_ret NameTClass_Sl_int_Sg_Scientists) { - return _swig_wrap_TClassInt_scientistsNameTestH(arg1, arg2) -} - -var _wrap_TClassInt_scientistsNameTestI unsafe.Pointer - -func _swig_wrap_TClassInt_scientistsNameTestI(base SwigcptrTClassInt, _ NameTClass_Sl_int_Sg_Scientists) (_ NameTClass_Sl_int_Sg_Scientists) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_TClassInt_scientistsNameTestI, _swig_p) - return -} - -func (arg1 SwigcptrTClassInt) ScientistsNameTestI(arg2 NameTClass_Sl_int_Sg_Scientists) (_swig_ret NameTClass_Sl_int_Sg_Scientists) { - return _swig_wrap_TClassInt_scientistsNameTestI(arg1, arg2) -} - -var _wrap_TClassInt_scientistsNameSpaceTest1 unsafe.Pointer - -func _swig_wrap_TClassInt_scientistsNameSpaceTest1(base SwigcptrTClassInt, _ NameTClass_Sl_int_Sg_Scientists) (_ NameTClass_Sl_int_Sg_Scientists) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_TClassInt_scientistsNameSpaceTest1, _swig_p) - return -} - -func (arg1 SwigcptrTClassInt) ScientistsNameSpaceTest1(arg2 NameTClass_Sl_int_Sg_Scientists) (_swig_ret NameTClass_Sl_int_Sg_Scientists) { - return _swig_wrap_TClassInt_scientistsNameSpaceTest1(arg1, arg2) -} - -var _wrap_TClassInt_scientistsNameSpaceTest2 unsafe.Pointer - -func _swig_wrap_TClassInt_scientistsNameSpaceTest2(base SwigcptrTClassInt, _ NameTClass_Sl_int_Sg_Scientists) (_ NameTClass_Sl_int_Sg_Scientists) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_TClassInt_scientistsNameSpaceTest2, _swig_p) - return -} - -func (arg1 SwigcptrTClassInt) ScientistsNameSpaceTest2(arg2 NameTClass_Sl_int_Sg_Scientists) (_swig_ret NameTClass_Sl_int_Sg_Scientists) { - return _swig_wrap_TClassInt_scientistsNameSpaceTest2(arg1, arg2) -} - -var _wrap_TClassInt_scientistsNameSpaceTest3 unsafe.Pointer - -func _swig_wrap_TClassInt_scientistsNameSpaceTest3(base SwigcptrTClassInt, _ NameTClass_Sl_int_Sg_Scientists) (_ NameTClass_Sl_int_Sg_Scientists) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_TClassInt_scientistsNameSpaceTest3, _swig_p) - return -} - -func (arg1 SwigcptrTClassInt) ScientistsNameSpaceTest3(arg2 NameTClass_Sl_int_Sg_Scientists) (_swig_ret NameTClass_Sl_int_Sg_Scientists) { - return _swig_wrap_TClassInt_scientistsNameSpaceTest3(arg1, arg2) -} - -var _wrap_TClassInt_scientistsNameSpaceTest4 unsafe.Pointer - -func _swig_wrap_TClassInt_scientistsNameSpaceTest4(base SwigcptrTClassInt, _ NameTClass_Sl_int_Sg_Scientists) (_ NameTClass_Sl_int_Sg_Scientists) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_TClassInt_scientistsNameSpaceTest4, _swig_p) - return -} - -func (arg1 SwigcptrTClassInt) ScientistsNameSpaceTest4(arg2 NameTClass_Sl_int_Sg_Scientists) (_swig_ret NameTClass_Sl_int_Sg_Scientists) { - return _swig_wrap_TClassInt_scientistsNameSpaceTest4(arg1, arg2) -} - -var _wrap_TClassInt_scientistsNameSpaceTest5 unsafe.Pointer - -func _swig_wrap_TClassInt_scientistsNameSpaceTest5(base SwigcptrTClassInt, _ NameTClass_Sl_int_Sg_Scientists) (_ NameTClass_Sl_int_Sg_Scientists) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_TClassInt_scientistsNameSpaceTest5, _swig_p) - return -} - -func (arg1 SwigcptrTClassInt) ScientistsNameSpaceTest5(arg2 NameTClass_Sl_int_Sg_Scientists) (_swig_ret NameTClass_Sl_int_Sg_Scientists) { - return _swig_wrap_TClassInt_scientistsNameSpaceTest5(arg1, arg2) -} - -var _wrap_TClassInt_scientistsNameSpaceTest6 unsafe.Pointer - -func _swig_wrap_TClassInt_scientistsNameSpaceTest6(base SwigcptrTClassInt, _ NameTClass_Sl_int_Sg_Scientists) (_ NameTClass_Sl_int_Sg_Scientists) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_TClassInt_scientistsNameSpaceTest6, _swig_p) - return -} - -func (arg1 SwigcptrTClassInt) ScientistsNameSpaceTest6(arg2 NameTClass_Sl_int_Sg_Scientists) (_swig_ret NameTClass_Sl_int_Sg_Scientists) { - return _swig_wrap_TClassInt_scientistsNameSpaceTest6(arg1, arg2) -} - -var _wrap_TClassInt_scientistsNameSpaceTest7 unsafe.Pointer - -func _swig_wrap_TClassInt_scientistsNameSpaceTest7(base SwigcptrTClassInt, _ NameTClass_Sl_int_Sg_Scientists) (_ NameTClass_Sl_int_Sg_Scientists) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_TClassInt_scientistsNameSpaceTest7, _swig_p) - return -} - -func (arg1 SwigcptrTClassInt) ScientistsNameSpaceTest7(arg2 NameTClass_Sl_int_Sg_Scientists) (_swig_ret NameTClass_Sl_int_Sg_Scientists) { - return _swig_wrap_TClassInt_scientistsNameSpaceTest7(arg1, arg2) -} - -var _wrap_TClassInt_scientistsOtherTest1 unsafe.Pointer - -func _swig_wrap_TClassInt_scientistsOtherTest1(base SwigcptrTClassInt, _ TemplateClass_Sl_int_Sg_Scientists) (_ TemplateClass_Sl_int_Sg_Scientists) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_TClassInt_scientistsOtherTest1, _swig_p) - return -} - -func (arg1 SwigcptrTClassInt) ScientistsOtherTest1(arg2 TemplateClass_Sl_int_Sg_Scientists) (_swig_ret TemplateClass_Sl_int_Sg_Scientists) { - return _swig_wrap_TClassInt_scientistsOtherTest1(arg1, arg2) -} - -var _wrap_TClassInt_scientistsOtherTest2 unsafe.Pointer - -func _swig_wrap_TClassInt_scientistsOtherTest2(base SwigcptrTClassInt, _ TemplateClass_Sl_int_Sg_Scientists) (_ TemplateClass_Sl_int_Sg_Scientists) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_TClassInt_scientistsOtherTest2, _swig_p) - return -} - -func (arg1 SwigcptrTClassInt) ScientistsOtherTest2(arg2 TemplateClass_Sl_int_Sg_Scientists) (_swig_ret TemplateClass_Sl_int_Sg_Scientists) { - return _swig_wrap_TClassInt_scientistsOtherTest2(arg1, arg2) -} - -var _wrap_TClassInt_scientistsOtherTest3 unsafe.Pointer - -func _swig_wrap_TClassInt_scientistsOtherTest3(base SwigcptrTClassInt, _ TemplateClass_Sl_int_Sg_Scientists) (_ TemplateClass_Sl_int_Sg_Scientists) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_TClassInt_scientistsOtherTest3, _swig_p) - return -} - -func (arg1 SwigcptrTClassInt) ScientistsOtherTest3(arg2 TemplateClass_Sl_int_Sg_Scientists) (_swig_ret TemplateClass_Sl_int_Sg_Scientists) { - return _swig_wrap_TClassInt_scientistsOtherTest3(arg1, arg2) -} - -var _wrap_TClassInt_scientistsOtherTest4 unsafe.Pointer - -func _swig_wrap_TClassInt_scientistsOtherTest4(base SwigcptrTClassInt, _ TemplateClass_Sl_int_Sg_Scientists) (_ TemplateClass_Sl_int_Sg_Scientists) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_TClassInt_scientistsOtherTest4, _swig_p) - return -} - -func (arg1 SwigcptrTClassInt) ScientistsOtherTest4(arg2 TemplateClass_Sl_int_Sg_Scientists) (_swig_ret TemplateClass_Sl_int_Sg_Scientists) { - return _swig_wrap_TClassInt_scientistsOtherTest4(arg1, arg2) -} - -var _wrap_TClassInt_scientistsOtherTest5 unsafe.Pointer - -func _swig_wrap_TClassInt_scientistsOtherTest5(base SwigcptrTClassInt, _ TemplateClass_Sl_int_Sg_Scientists) (_ TemplateClass_Sl_int_Sg_Scientists) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_TClassInt_scientistsOtherTest5, _swig_p) - return -} - -func (arg1 SwigcptrTClassInt) ScientistsOtherTest5(arg2 TemplateClass_Sl_int_Sg_Scientists) (_swig_ret TemplateClass_Sl_int_Sg_Scientists) { - return _swig_wrap_TClassInt_scientistsOtherTest5(arg1, arg2) -} - -var _wrap_TClassInt_scientistsOtherTest6 unsafe.Pointer - -func _swig_wrap_TClassInt_scientistsOtherTest6(base SwigcptrTClassInt, _ TemplateClass_Sl_int_Sg_Scientists) (_ TemplateClass_Sl_int_Sg_Scientists) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_TClassInt_scientistsOtherTest6, _swig_p) - return -} - -func (arg1 SwigcptrTClassInt) ScientistsOtherTest6(arg2 TemplateClass_Sl_int_Sg_Scientists) (_swig_ret TemplateClass_Sl_int_Sg_Scientists) { - return _swig_wrap_TClassInt_scientistsOtherTest6(arg1, arg2) -} - -var _wrap_TClassInt_scientistsOtherTest7 unsafe.Pointer - -func _swig_wrap_TClassInt_scientistsOtherTest7(base SwigcptrTClassInt, _ TemplateClass_Sl_int_Sg_Scientists) (_ TemplateClass_Sl_int_Sg_Scientists) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_TClassInt_scientistsOtherTest7, _swig_p) - return -} - -func (arg1 SwigcptrTClassInt) ScientistsOtherTest7(arg2 TemplateClass_Sl_int_Sg_Scientists) (_swig_ret TemplateClass_Sl_int_Sg_Scientists) { - return _swig_wrap_TClassInt_scientistsOtherTest7(arg1, arg2) -} - -var _wrap_new_TClassInt unsafe.Pointer - -func _swig_wrap_new_TClassInt() (base SwigcptrTClassInt) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_TClassInt, _swig_p) - return -} - -func NewTClassInt() (_swig_ret TClassInt) { - return _swig_wrap_new_TClassInt() -} - -var _wrap_delete_TClassInt unsafe.Pointer - -func _swig_wrap_delete_TClassInt(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_TClassInt, _swig_p) - return -} - -func DeleteTClassInt(arg1 TClassInt) { - _swig_wrap_delete_TClassInt(arg1.Swigcptr()) -} - -type TClassInt interface { - Swigcptr() uintptr - SwigIsTClassInt() - ScientistsNameTest1(arg2 NameTClass_Sl_int_Sg_Scientists) (_swig_ret NameTClass_Sl_int_Sg_Scientists) - ScientistsNameTest2(arg2 NameTClass_Sl_int_Sg_Scientists) (_swig_ret NameTClass_Sl_int_Sg_Scientists) - ScientistsNameTest3(arg2 NameTClass_Sl_int_Sg_Scientists) (_swig_ret NameTClass_Sl_int_Sg_Scientists) - ScientistsNameTest4(arg2 NameTClass_Sl_int_Sg_Scientists) (_swig_ret NameTClass_Sl_int_Sg_Scientists) - ScientistsNameTest5(arg2 NameTClass_Sl_int_Sg_Scientists) (_swig_ret NameTClass_Sl_int_Sg_Scientists) - ScientistsNameTest6(arg2 NameTClass_Sl_int_Sg_Scientists) (_swig_ret NameTClass_Sl_int_Sg_Scientists) - ScientistsNameTest7(arg2 NameTClass_Sl_int_Sg_Scientists) (_swig_ret NameTClass_Sl_int_Sg_Scientists) - ScientistsNameTest8(arg2 NameTClass_Sl_int_Sg_Scientists) (_swig_ret NameTClass_Sl_int_Sg_Scientists) - ScientistsNameTest9(arg2 NameTClass_Sl_int_Sg_Scientists) (_swig_ret NameTClass_Sl_int_Sg_Scientists) - ScientistsNameTestB(arg2 NameTClass_Sl_int_Sg_Scientists) (_swig_ret NameTClass_Sl_int_Sg_Scientists) - ScientistsNameTestD(arg2 NameTClass_Sl_int_Sg_Scientists) (_swig_ret NameTClass_Sl_int_Sg_Scientists) - ScientistsNameTestE(arg2 NameTClass_Sl_int_Sg_Scientists) (_swig_ret NameTClass_Sl_int_Sg_Scientists) - ScientistsNameTestF(arg2 NameTClass_Sl_int_Sg_Scientists) (_swig_ret NameTClass_Sl_int_Sg_Scientists) - ScientistsNameTestG(arg2 NameTClass_Sl_int_Sg_Scientists) (_swig_ret NameTClass_Sl_int_Sg_Scientists) - ScientistsNameTestH(arg2 NameTClass_Sl_int_Sg_Scientists) (_swig_ret NameTClass_Sl_int_Sg_Scientists) - ScientistsNameTestI(arg2 NameTClass_Sl_int_Sg_Scientists) (_swig_ret NameTClass_Sl_int_Sg_Scientists) - ScientistsNameSpaceTest1(arg2 NameTClass_Sl_int_Sg_Scientists) (_swig_ret NameTClass_Sl_int_Sg_Scientists) - ScientistsNameSpaceTest2(arg2 NameTClass_Sl_int_Sg_Scientists) (_swig_ret NameTClass_Sl_int_Sg_Scientists) - ScientistsNameSpaceTest3(arg2 NameTClass_Sl_int_Sg_Scientists) (_swig_ret NameTClass_Sl_int_Sg_Scientists) - ScientistsNameSpaceTest4(arg2 NameTClass_Sl_int_Sg_Scientists) (_swig_ret NameTClass_Sl_int_Sg_Scientists) - ScientistsNameSpaceTest5(arg2 NameTClass_Sl_int_Sg_Scientists) (_swig_ret NameTClass_Sl_int_Sg_Scientists) - ScientistsNameSpaceTest6(arg2 NameTClass_Sl_int_Sg_Scientists) (_swig_ret NameTClass_Sl_int_Sg_Scientists) - ScientistsNameSpaceTest7(arg2 NameTClass_Sl_int_Sg_Scientists) (_swig_ret NameTClass_Sl_int_Sg_Scientists) - ScientistsOtherTest1(arg2 TemplateClass_Sl_int_Sg_Scientists) (_swig_ret TemplateClass_Sl_int_Sg_Scientists) - ScientistsOtherTest2(arg2 TemplateClass_Sl_int_Sg_Scientists) (_swig_ret TemplateClass_Sl_int_Sg_Scientists) - ScientistsOtherTest3(arg2 TemplateClass_Sl_int_Sg_Scientists) (_swig_ret TemplateClass_Sl_int_Sg_Scientists) - ScientistsOtherTest4(arg2 TemplateClass_Sl_int_Sg_Scientists) (_swig_ret TemplateClass_Sl_int_Sg_Scientists) - ScientistsOtherTest5(arg2 TemplateClass_Sl_int_Sg_Scientists) (_swig_ret TemplateClass_Sl_int_Sg_Scientists) - ScientistsOtherTest6(arg2 TemplateClass_Sl_int_Sg_Scientists) (_swig_ret TemplateClass_Sl_int_Sg_Scientists) - ScientistsOtherTest7(arg2 TemplateClass_Sl_int_Sg_Scientists) (_swig_ret TemplateClass_Sl_int_Sg_Scientists) -} - -type Old_name int -var _wrap_argh unsafe.Pointer - -func _swig_getargh() (_swig_ret Old_name) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_argh, _swig_p) - return -} -var Argh Old_name = _swig_getargh() -var _wrap_eek unsafe.Pointer - -func _swig_geteek() (_swig_ret Old_name) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_eek, _swig_p) - return -} -var Eek Old_name = _swig_geteek() -var _wrap_renameTest1 unsafe.Pointer - -func RenameTest1(arg1 Old_name) (_swig_ret Old_name) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_renameTest1, _swig_p) - return -} -var _wrap_renameTest2 unsafe.Pointer - -func RenameTest2(arg1 Old_name) (_swig_ret Old_name) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_renameTest2, _swig_p) - return -} -type SwigcptrNewNameStruct uintptr - -func (p SwigcptrNewNameStruct) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrNewNameStruct) SwigIsNewNameStruct() { -} - -type OldNameStructEnumeration int -var _wrap_whizz_NewNameStruct unsafe.Pointer - -func _swig_getNewNameStruct_whizz_NewNameStruct() (_swig_ret OldNameStructEnumeration) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_whizz_NewNameStruct, _swig_p) - return -} -var NewNameStructWhizz OldNameStructEnumeration = _swig_getNewNameStruct_whizz_NewNameStruct() -var _wrap_bang_NewNameStruct unsafe.Pointer - -func _swig_getNewNameStruct_bang_NewNameStruct() (_swig_ret OldNameStructEnumeration) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_bang_NewNameStruct, _swig_p) - return -} -var NewNameStructBang OldNameStructEnumeration = _swig_getNewNameStruct_bang_NewNameStruct() -var _wrap_pop_NewNameStruct unsafe.Pointer - -func _swig_getNewNameStruct_pop_NewNameStruct() (_swig_ret OldNameStructEnumeration) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_pop_NewNameStruct, _swig_p) - return -} -var NewNameStructPop OldNameStructEnumeration = _swig_getNewNameStruct_pop_NewNameStruct() -var _wrap_NewNameStruct_renameTest1 unsafe.Pointer - -func _swig_wrap_NewNameStruct_renameTest1(base SwigcptrNewNameStruct, _ OldNameStructEnumeration) (_ OldNameStructEnumeration) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_NewNameStruct_renameTest1, _swig_p) - return -} - -func (arg1 SwigcptrNewNameStruct) RenameTest1(arg2 OldNameStructEnumeration) (_swig_ret OldNameStructEnumeration) { - return _swig_wrap_NewNameStruct_renameTest1(arg1, arg2) -} - -var _wrap_NewNameStruct_renameTest2 unsafe.Pointer - -func _swig_wrap_NewNameStruct_renameTest2(base SwigcptrNewNameStruct, _ OldNameStructEnumeration) (_ OldNameStructEnumeration) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_NewNameStruct_renameTest2, _swig_p) - return -} - -func (arg1 SwigcptrNewNameStruct) RenameTest2(arg2 OldNameStructEnumeration) (_swig_ret OldNameStructEnumeration) { - return _swig_wrap_NewNameStruct_renameTest2(arg1, arg2) -} - -type OldNameStructSimple int -var _wrap_simple1_NewNameStruct unsafe.Pointer - -func _swig_getNewNameStruct_simple1_NewNameStruct() (_swig_ret OldNameStructSimple) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_simple1_NewNameStruct, _swig_p) - return -} -var NewNameStructSimple1 OldNameStructSimple = _swig_getNewNameStruct_simple1_NewNameStruct() -type OldNameStructDoublenametag int -var _wrap_doublename1_NewNameStruct unsafe.Pointer - -func _swig_getNewNameStruct_doublename1_NewNameStruct() (_swig_ret OldNameStructDoublenametag) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_doublename1_NewNameStruct, _swig_p) - return -} -var NewNameStructDoublename1 OldNameStructDoublenametag = _swig_getNewNameStruct_doublename1_NewNameStruct() -type OldNameStructSinglename int -var _wrap_singlename1_NewNameStruct unsafe.Pointer - -func _swig_getNewNameStruct_singlename1_NewNameStruct() (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_singlename1_NewNameStruct, _swig_p) - return -} -var NewNameStructSinglename1 int = _swig_getNewNameStruct_singlename1_NewNameStruct() -var _wrap_NewNameStruct_renameTest3 unsafe.Pointer - -func _swig_wrap_NewNameStruct_renameTest3(base SwigcptrNewNameStruct, _ OldNameStructSimple) (_ OldNameStructSimple) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_NewNameStruct_renameTest3, _swig_p) - return -} - -func (arg1 SwigcptrNewNameStruct) RenameTest3(arg2 OldNameStructSimple) (_swig_ret OldNameStructSimple) { - return _swig_wrap_NewNameStruct_renameTest3(arg1, arg2) -} - -var _wrap_NewNameStruct_renameTest4 unsafe.Pointer - -func _swig_wrap_NewNameStruct_renameTest4(base SwigcptrNewNameStruct, _ OldNameStructDoublenametag) (_ OldNameStructDoublenametag) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_NewNameStruct_renameTest4, _swig_p) - return -} - -func (arg1 SwigcptrNewNameStruct) RenameTest4(arg2 OldNameStructDoublenametag) (_swig_ret OldNameStructDoublenametag) { - return _swig_wrap_NewNameStruct_renameTest4(arg1, arg2) -} - -var _wrap_NewNameStruct_renameTest5 unsafe.Pointer - -func _swig_wrap_NewNameStruct_renameTest5(base SwigcptrNewNameStruct, _ OldNameStructDoublenametag) (_ OldNameStructDoublenametag) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_NewNameStruct_renameTest5, _swig_p) - return -} - -func (arg1 SwigcptrNewNameStruct) RenameTest5(arg2 OldNameStructDoublenametag) (_swig_ret OldNameStructDoublenametag) { - return _swig_wrap_NewNameStruct_renameTest5(arg1, arg2) -} - -var _wrap_NewNameStruct_renameTest6 unsafe.Pointer - -func _swig_wrap_NewNameStruct_renameTest6(base SwigcptrNewNameStruct, _ OldNameStructSinglename) (_ OldNameStructSinglename) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_NewNameStruct_renameTest6, _swig_p) - return -} - -func (arg1 SwigcptrNewNameStruct) RenameTest6(arg2 OldNameStructSinglename) (_swig_ret OldNameStructSinglename) { - return _swig_wrap_NewNameStruct_renameTest6(arg1, arg2) -} - -var _wrap_new_NewNameStruct unsafe.Pointer - -func _swig_wrap_new_NewNameStruct() (base SwigcptrNewNameStruct) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_NewNameStruct, _swig_p) - return -} - -func NewNewNameStruct() (_swig_ret NewNameStruct) { - return _swig_wrap_new_NewNameStruct() -} - -var _wrap_delete_NewNameStruct unsafe.Pointer - -func _swig_wrap_delete_NewNameStruct(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_NewNameStruct, _swig_p) - return -} - -func DeleteNewNameStruct(arg1 NewNameStruct) { - _swig_wrap_delete_NewNameStruct(arg1.Swigcptr()) -} - -type NewNameStruct interface { - Swigcptr() uintptr - SwigIsNewNameStruct() - RenameTest1(arg2 OldNameStructEnumeration) (_swig_ret OldNameStructEnumeration) - RenameTest2(arg2 OldNameStructEnumeration) (_swig_ret OldNameStructEnumeration) - RenameTest3(arg2 OldNameStructSimple) (_swig_ret OldNameStructSimple) - RenameTest4(arg2 OldNameStructDoublenametag) (_swig_ret OldNameStructDoublenametag) - RenameTest5(arg2 OldNameStructDoublenametag) (_swig_ret OldNameStructDoublenametag) - RenameTest6(arg2 OldNameStructSinglename) (_swig_ret OldNameStructSinglename) -} - -var _wrap_renameTest3 unsafe.Pointer - -func RenameTest3(arg1 OldNameStructEnumeration) (_swig_ret OldNameStructEnumeration) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_renameTest3, _swig_p) - return -} -var _wrap_renameTest4 unsafe.Pointer - -func RenameTest4(arg1 OldNameStructSimple) (_swig_ret OldNameStructSimple) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_renameTest4, _swig_p) - return -} -var _wrap_renameTest5 unsafe.Pointer - -func RenameTest5(arg1 OldNameStructDoublenametag) (_swig_ret OldNameStructDoublenametag) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_renameTest5, _swig_p) - return -} -var _wrap_renameTest6 unsafe.Pointer - -func RenameTest6(arg1 OldNameStructDoublenametag) (_swig_ret OldNameStructDoublenametag) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_renameTest6, _swig_p) - return -} -var _wrap_renameTest7 unsafe.Pointer - -func RenameTest7(arg1 OldNameStructSinglename) (_swig_ret OldNameStructSinglename) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_renameTest7, _swig_p) - return -} -type SwigcptrTreesClass uintptr - -func (p SwigcptrTreesClass) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrTreesClass) SwigIsTreesClass() { -} - -type TreesClassTrees int -var _wrap_oak_TreesClass unsafe.Pointer - -func _swig_getTreesClass_oak_TreesClass() (_swig_ret TreesClassTrees) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_oak_TreesClass, _swig_p) - return -} -var TreesClassOak TreesClassTrees = _swig_getTreesClass_oak_TreesClass() -var _wrap_fir_TreesClass unsafe.Pointer - -func _swig_getTreesClass_fir_TreesClass() (_swig_ret TreesClassTrees) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_fir_TreesClass, _swig_p) - return -} -var TreesClassFir TreesClassTrees = _swig_getTreesClass_fir_TreesClass() -var _wrap_pine_TreesClass unsafe.Pointer - -func _swig_getTreesClass_pine_TreesClass() (_swig_ret TreesClassTrees) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_pine_TreesClass, _swig_p) - return -} -var TreesClassPine TreesClassTrees = _swig_getTreesClass_pine_TreesClass() -var _wrap_TreesClass_treesTest1 unsafe.Pointer - -func _swig_wrap_TreesClass_treesTest1(base SwigcptrTreesClass, _ TreesClassTrees) (_ TreesClassTrees) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_TreesClass_treesTest1, _swig_p) - return -} - -func (arg1 SwigcptrTreesClass) TreesTest1(arg2 TreesClassTrees) (_swig_ret TreesClassTrees) { - return _swig_wrap_TreesClass_treesTest1(arg1, arg2) -} - -var _wrap_TreesClass_treesTest2 unsafe.Pointer - -func _swig_wrap_TreesClass_treesTest2(base SwigcptrTreesClass, _ TreesClassTrees) (_ TreesClassTrees) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_TreesClass_treesTest2, _swig_p) - return -} - -func (arg1 SwigcptrTreesClass) TreesTest2(arg2 TreesClassTrees) (_swig_ret TreesClassTrees) { - return _swig_wrap_TreesClass_treesTest2(arg1, arg2) -} - -var _wrap_TreesClass_treesTest3 unsafe.Pointer - -func _swig_wrap_TreesClass_treesTest3(base SwigcptrTreesClass, _ TreesClassTrees) (_ TreesClassTrees) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_TreesClass_treesTest3, _swig_p) - return -} - -func (arg1 SwigcptrTreesClass) TreesTest3(arg2 TreesClassTrees) (_swig_ret TreesClassTrees) { - return _swig_wrap_TreesClass_treesTest3(arg1, arg2) -} - -var _wrap_TreesClass_treesTest4 unsafe.Pointer - -func _swig_wrap_TreesClass_treesTest4(base SwigcptrTreesClass, _ TreesClassTrees) (_ TreesClassTrees) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_TreesClass_treesTest4, _swig_p) - return -} - -func (arg1 SwigcptrTreesClass) TreesTest4(arg2 TreesClassTrees) (_swig_ret TreesClassTrees) { - return _swig_wrap_TreesClass_treesTest4(arg1, arg2) -} - -var _wrap_TreesClass_treesTest5 unsafe.Pointer - -func _swig_wrap_TreesClass_treesTest5(base SwigcptrTreesClass, _ TreesClassTrees) (_ TreesClassTrees) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_TreesClass_treesTest5, _swig_p) - return -} - -func (arg1 SwigcptrTreesClass) TreesTest5(arg2 TreesClassTrees) (_swig_ret TreesClassTrees) { - return _swig_wrap_TreesClass_treesTest5(arg1, arg2) -} - -var _wrap_TreesClass_treesTest6 unsafe.Pointer - -func _swig_wrap_TreesClass_treesTest6(base SwigcptrTreesClass, _ TreesClassTrees) (_ TreesClassTrees) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_TreesClass_treesTest6, _swig_p) - return -} - -func (arg1 SwigcptrTreesClass) TreesTest6(arg2 TreesClassTrees) (_swig_ret TreesClassTrees) { - return _swig_wrap_TreesClass_treesTest6(arg1, arg2) -} - -var _wrap_TreesClass_treesTest7 unsafe.Pointer - -func _swig_wrap_TreesClass_treesTest7(base SwigcptrTreesClass, _ TreesClassTrees) (_ TreesClassTrees) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_TreesClass_treesTest7, _swig_p) - return -} - -func (arg1 SwigcptrTreesClass) TreesTest7(arg2 TreesClassTrees) (_swig_ret TreesClassTrees) { - return _swig_wrap_TreesClass_treesTest7(arg1, arg2) -} - -var _wrap_TreesClass_treesTest8 unsafe.Pointer - -func _swig_wrap_TreesClass_treesTest8(base SwigcptrTreesClass, _ TreesClassTrees) (_ TreesClassTrees) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_TreesClass_treesTest8, _swig_p) - return -} - -func (arg1 SwigcptrTreesClass) TreesTest8(arg2 TreesClassTrees) (_swig_ret TreesClassTrees) { - return _swig_wrap_TreesClass_treesTest8(arg1, arg2) -} - -var _wrap_TreesClass_treesTest9 unsafe.Pointer - -func _swig_wrap_TreesClass_treesTest9(base SwigcptrTreesClass, _ TreesClassTrees) (_ TreesClassTrees) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_TreesClass_treesTest9, _swig_p) - return -} - -func (arg1 SwigcptrTreesClass) TreesTest9(arg2 TreesClassTrees) (_swig_ret TreesClassTrees) { - return _swig_wrap_TreesClass_treesTest9(arg1, arg2) -} - -var _wrap_TreesClass_treesTestA unsafe.Pointer - -func _swig_wrap_TreesClass_treesTestA(base SwigcptrTreesClass, _ TreesClassTrees) (_ TreesClassTrees) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_TreesClass_treesTestA, _swig_p) - return -} - -func (arg1 SwigcptrTreesClass) TreesTestA(arg2 TreesClassTrees) (_swig_ret TreesClassTrees) { - return _swig_wrap_TreesClass_treesTestA(arg1, arg2) -} - -var _wrap_TreesClass_treesTestB unsafe.Pointer - -func _swig_wrap_TreesClass_treesTestB(base SwigcptrTreesClass, _ TreesClassTrees) (_ TreesClassTrees) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_TreesClass_treesTestB, _swig_p) - return -} - -func (arg1 SwigcptrTreesClass) TreesTestB(arg2 TreesClassTrees) (_swig_ret TreesClassTrees) { - return _swig_wrap_TreesClass_treesTestB(arg1, arg2) -} - -var _wrap_TreesClass_treesTestC unsafe.Pointer - -func _swig_wrap_TreesClass_treesTestC(base SwigcptrTreesClass, _ TreesClassTrees) (_ TreesClassTrees) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_TreesClass_treesTestC, _swig_p) - return -} - -func (arg1 SwigcptrTreesClass) TreesTestC(arg2 TreesClassTrees) (_swig_ret TreesClassTrees) { - return _swig_wrap_TreesClass_treesTestC(arg1, arg2) -} - -var _wrap_TreesClass_treesTestD unsafe.Pointer - -func _swig_wrap_TreesClass_treesTestD(base SwigcptrTreesClass, _ TreesClassTrees) (_ TreesClassTrees) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_TreesClass_treesTestD, _swig_p) - return -} - -func (arg1 SwigcptrTreesClass) TreesTestD(arg2 TreesClassTrees) (_swig_ret TreesClassTrees) { - return _swig_wrap_TreesClass_treesTestD(arg1, arg2) -} - -var _wrap_TreesClass_treesTestE unsafe.Pointer - -func _swig_wrap_TreesClass_treesTestE(base SwigcptrTreesClass, _ TreesClassTrees) (_ TreesClassTrees) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_TreesClass_treesTestE, _swig_p) - return -} - -func (arg1 SwigcptrTreesClass) TreesTestE(arg2 TreesClassTrees) (_swig_ret TreesClassTrees) { - return _swig_wrap_TreesClass_treesTestE(arg1, arg2) -} - -var _wrap_TreesClass_treesTestF unsafe.Pointer - -func _swig_wrap_TreesClass_treesTestF(base SwigcptrTreesClass, _ TreesClassTrees) (_ TreesClassTrees) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_TreesClass_treesTestF, _swig_p) - return -} - -func (arg1 SwigcptrTreesClass) TreesTestF(arg2 TreesClassTrees) (_swig_ret TreesClassTrees) { - return _swig_wrap_TreesClass_treesTestF(arg1, arg2) -} - -var _wrap_TreesClass_treesTestG unsafe.Pointer - -func _swig_wrap_TreesClass_treesTestG(base SwigcptrTreesClass, _ TreesClassTrees) (_ TreesClassTrees) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_TreesClass_treesTestG, _swig_p) - return -} - -func (arg1 SwigcptrTreesClass) TreesTestG(arg2 TreesClassTrees) (_swig_ret TreesClassTrees) { - return _swig_wrap_TreesClass_treesTestG(arg1, arg2) -} - -var _wrap_TreesClass_treesTestH unsafe.Pointer - -func _swig_wrap_TreesClass_treesTestH(base SwigcptrTreesClass, _ TreesClassTrees) (_ TreesClassTrees) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_TreesClass_treesTestH, _swig_p) - return -} - -func (arg1 SwigcptrTreesClass) TreesTestH(arg2 TreesClassTrees) (_swig_ret TreesClassTrees) { - return _swig_wrap_TreesClass_treesTestH(arg1, arg2) -} - -var _wrap_TreesClass_treesTestI unsafe.Pointer - -func _swig_wrap_TreesClass_treesTestI(base SwigcptrTreesClass, _ TreesClassTrees) (_ TreesClassTrees) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_TreesClass_treesTestI, _swig_p) - return -} - -func (arg1 SwigcptrTreesClass) TreesTestI(arg2 TreesClassTrees) (_swig_ret TreesClassTrees) { - return _swig_wrap_TreesClass_treesTestI(arg1, arg2) -} - -var _wrap_TreesClass_treesTestJ unsafe.Pointer - -func _swig_wrap_TreesClass_treesTestJ(base SwigcptrTreesClass, _ TreesClassTrees) (_ TreesClassTrees) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_TreesClass_treesTestJ, _swig_p) - return -} - -func (arg1 SwigcptrTreesClass) TreesTestJ(arg2 TreesClassTrees) (_swig_ret TreesClassTrees) { - return _swig_wrap_TreesClass_treesTestJ(arg1, arg2) -} - -var _wrap_TreesClass_treesTestK unsafe.Pointer - -func _swig_wrap_TreesClass_treesTestK(base SwigcptrTreesClass, _ TreesClassTrees) (_ TreesClassTrees) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_TreesClass_treesTestK, _swig_p) - return -} - -func (arg1 SwigcptrTreesClass) TreesTestK(arg2 TreesClassTrees) (_swig_ret TreesClassTrees) { - return _swig_wrap_TreesClass_treesTestK(arg1, arg2) -} - -var _wrap_TreesClass_treesTestL unsafe.Pointer - -func _swig_wrap_TreesClass_treesTestL(base SwigcptrTreesClass, _ TreesClassTrees) (_ TreesClassTrees) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_TreesClass_treesTestL, _swig_p) - return -} - -func (arg1 SwigcptrTreesClass) TreesTestL(arg2 TreesClassTrees) (_swig_ret TreesClassTrees) { - return _swig_wrap_TreesClass_treesTestL(arg1, arg2) -} - -var _wrap_TreesClass_treesTestM unsafe.Pointer - -func _swig_wrap_TreesClass_treesTestM(base SwigcptrTreesClass, _ TreesClassTrees) (_ TreesClassTrees) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_TreesClass_treesTestM, _swig_p) - return -} - -func (arg1 SwigcptrTreesClass) TreesTestM(arg2 TreesClassTrees) (_swig_ret TreesClassTrees) { - return _swig_wrap_TreesClass_treesTestM(arg1, arg2) -} - -var _wrap_TreesClass_treesTestN unsafe.Pointer - -func _swig_wrap_TreesClass_treesTestN(base SwigcptrTreesClass, _ TreesClassTrees) (_ TreesClassTrees) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_TreesClass_treesTestN, _swig_p) - return -} - -func (arg1 SwigcptrTreesClass) TreesTestN(arg2 TreesClassTrees) (_swig_ret TreesClassTrees) { - return _swig_wrap_TreesClass_treesTestN(arg1, arg2) -} - -var _wrap_TreesClass_treesTestO unsafe.Pointer - -func _swig_wrap_TreesClass_treesTestO(base SwigcptrTreesClass, _ TreesClassTrees) (_ TreesClassTrees) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_TreesClass_treesTestO, _swig_p) - return -} - -func (arg1 SwigcptrTreesClass) TreesTestO(arg2 TreesClassTrees) (_swig_ret TreesClassTrees) { - return _swig_wrap_TreesClass_treesTestO(arg1, arg2) -} - -var _wrap_new_TreesClass unsafe.Pointer - -func _swig_wrap_new_TreesClass() (base SwigcptrTreesClass) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_TreesClass, _swig_p) - return -} - -func NewTreesClass() (_swig_ret TreesClass) { - return _swig_wrap_new_TreesClass() -} - -var _wrap_delete_TreesClass unsafe.Pointer - -func _swig_wrap_delete_TreesClass(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_TreesClass, _swig_p) - return -} - -func DeleteTreesClass(arg1 TreesClass) { - _swig_wrap_delete_TreesClass(arg1.Swigcptr()) -} - -type TreesClass interface { - Swigcptr() uintptr - SwigIsTreesClass() - TreesTest1(arg2 TreesClassTrees) (_swig_ret TreesClassTrees) - TreesTest2(arg2 TreesClassTrees) (_swig_ret TreesClassTrees) - TreesTest3(arg2 TreesClassTrees) (_swig_ret TreesClassTrees) - TreesTest4(arg2 TreesClassTrees) (_swig_ret TreesClassTrees) - TreesTest5(arg2 TreesClassTrees) (_swig_ret TreesClassTrees) - TreesTest6(arg2 TreesClassTrees) (_swig_ret TreesClassTrees) - TreesTest7(arg2 TreesClassTrees) (_swig_ret TreesClassTrees) - TreesTest8(arg2 TreesClassTrees) (_swig_ret TreesClassTrees) - TreesTest9(arg2 TreesClassTrees) (_swig_ret TreesClassTrees) - TreesTestA(arg2 TreesClassTrees) (_swig_ret TreesClassTrees) - TreesTestB(arg2 TreesClassTrees) (_swig_ret TreesClassTrees) - TreesTestC(arg2 TreesClassTrees) (_swig_ret TreesClassTrees) - TreesTestD(arg2 TreesClassTrees) (_swig_ret TreesClassTrees) - TreesTestE(arg2 TreesClassTrees) (_swig_ret TreesClassTrees) - TreesTestF(arg2 TreesClassTrees) (_swig_ret TreesClassTrees) - TreesTestG(arg2 TreesClassTrees) (_swig_ret TreesClassTrees) - TreesTestH(arg2 TreesClassTrees) (_swig_ret TreesClassTrees) - TreesTestI(arg2 TreesClassTrees) (_swig_ret TreesClassTrees) - TreesTestJ(arg2 TreesClassTrees) (_swig_ret TreesClassTrees) - TreesTestK(arg2 TreesClassTrees) (_swig_ret TreesClassTrees) - TreesTestL(arg2 TreesClassTrees) (_swig_ret TreesClassTrees) - TreesTestM(arg2 TreesClassTrees) (_swig_ret TreesClassTrees) - TreesTestN(arg2 TreesClassTrees) (_swig_ret TreesClassTrees) - TreesTestO(arg2 TreesClassTrees) (_swig_ret TreesClassTrees) -} - -var _wrap_treesTest1 unsafe.Pointer - -func TreesTest1(arg1 TreesClassTrees) (_swig_ret TreesClassTrees) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_treesTest1, _swig_p) - return -} -var _wrap_treesTest2 unsafe.Pointer - -func TreesTest2(arg1 TreesClassTrees) (_swig_ret TreesClassTrees) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_treesTest2, _swig_p) - return -} -var _wrap_treesTest3 unsafe.Pointer - -func TreesTest3(arg1 TreesClassTrees) (_swig_ret TreesClassTrees) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_treesTest3, _swig_p) - return -} -var _wrap_treesTest4 unsafe.Pointer - -func TreesTest4(arg1 TreesClassTrees) (_swig_ret TreesClassTrees) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_treesTest4, _swig_p) - return -} -var _wrap_treesTest5 unsafe.Pointer - -func TreesTest5(arg1 TreesClassTrees) (_swig_ret TreesClassTrees) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_treesTest5, _swig_p) - return -} -var _wrap_treesTest6 unsafe.Pointer - -func TreesTest6(arg1 TreesClassTrees) (_swig_ret TreesClassTrees) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_treesTest6, _swig_p) - return -} -var _wrap_treesTest7 unsafe.Pointer - -func TreesTest7(arg1 TreesClassTrees) (_swig_ret TreesClassTrees) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_treesTest7, _swig_p) - return -} -var _wrap_treesTest8 unsafe.Pointer - -func TreesTest8(arg1 TreesClassTrees) (_swig_ret TreesClassTrees) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_treesTest8, _swig_p) - return -} -var _wrap_treesTest9 unsafe.Pointer - -func TreesTest9(arg1 TreesClassTrees) (_swig_ret TreesClassTrees) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_treesTest9, _swig_p) - return -} -var _wrap_treesTestA unsafe.Pointer - -func TreesTestA(arg1 TreesClassTrees) (_swig_ret TreesClassTrees) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_treesTestA, _swig_p) - return -} -var _wrap_treesTestB unsafe.Pointer - -func TreesTestB(arg1 TreesClassTrees) (_swig_ret TreesClassTrees) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_treesTestB, _swig_p) - return -} -var _wrap_treesTestC unsafe.Pointer - -func TreesTestC(arg1 TreesClassTrees) (_swig_ret TreesClassTrees) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_treesTestC, _swig_p) - return -} -var _wrap_treesTestD unsafe.Pointer - -func TreesTestD(arg1 TreesClassTrees) (_swig_ret TreesClassTrees) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_treesTestD, _swig_p) - return -} -var _wrap_treesTestE unsafe.Pointer - -func TreesTestE(arg1 TreesClassTrees) (_swig_ret TreesClassTrees) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_treesTestE, _swig_p) - return -} -var _wrap_treesTestF unsafe.Pointer - -func TreesTestF(arg1 TreesClassTrees) (_swig_ret TreesClassTrees) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_treesTestF, _swig_p) - return -} -var _wrap_treesTestG unsafe.Pointer - -func TreesTestG(arg1 TreesClassTrees) (_swig_ret TreesClassTrees) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_treesTestG, _swig_p) - return -} -var _wrap_treesTestH unsafe.Pointer - -func TreesTestH(arg1 TreesClassTrees) (_swig_ret TreesClassTrees) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_treesTestH, _swig_p) - return -} -var _wrap_treesTestI unsafe.Pointer - -func TreesTestI(arg1 TreesClassTrees) (_swig_ret TreesClassTrees) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_treesTestI, _swig_p) - return -} -var _wrap_treesTestJ unsafe.Pointer - -func TreesTestJ(arg1 TreesClassTrees) (_swig_ret TreesClassTrees) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_treesTestJ, _swig_p) - return -} -var _wrap_treesTestK unsafe.Pointer - -func TreesTestK(arg1 TreesClassTrees) (_swig_ret TreesClassTrees) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_treesTestK, _swig_p) - return -} -var _wrap_treesTestL unsafe.Pointer - -func TreesTestL(arg1 TreesClassTrees) (_swig_ret TreesClassTrees) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_treesTestL, _swig_p) - return -} -var _wrap_treesTestM unsafe.Pointer - -func TreesTestM(arg1 TreesClassTrees) (_swig_ret TreesClassTrees) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_treesTestM, _swig_p) - return -} -var _wrap_treesTestO unsafe.Pointer - -func TreesTestO(arg1 TreesClassTrees) (_swig_ret TreesClassTrees) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_treesTestO, _swig_p) - return -} -var _wrap_treesTestP unsafe.Pointer - -func TreesTestP(arg1 TreesClassTrees) (_swig_ret TreesClassTrees) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_treesTestP, _swig_p) - return -} -var _wrap_treesTestQ unsafe.Pointer - -func TreesTestQ(arg1 TreesClassTrees) (_swig_ret TreesClassTrees) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_treesTestQ, _swig_p) - return -} -var _wrap_treesTestR unsafe.Pointer - -func TreesTestR(arg1 TreesClassTrees) (_swig_ret TreesClassTrees) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_treesTestR, _swig_p) - return -} -type SwigcptrHairStruct uintptr - -func (p SwigcptrHairStruct) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrHairStruct) SwigIsHairStruct() { -} - -type CurlyGreasyHairStructHair int -var _wrap_blonde_HairStruct unsafe.Pointer - -func _swig_getHairStruct_blonde_HairStruct() (_swig_ret CurlyGreasyHairStructHair) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_blonde_HairStruct, _swig_p) - return -} -var HairStructBlonde CurlyGreasyHairStructHair = _swig_getHairStruct_blonde_HairStruct() -var _wrap_ginger_HairStruct unsafe.Pointer - -func _swig_getHairStruct_ginger_HairStruct() (_swig_ret CurlyGreasyHairStructHair) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_ginger_HairStruct, _swig_p) - return -} -var HairStructGinger CurlyGreasyHairStructHair = _swig_getHairStruct_ginger_HairStruct() -var _wrap_HairStruct_hairTest1 unsafe.Pointer - -func _swig_wrap_HairStruct_hairTest1(base SwigcptrHairStruct, _ CurlyGreasyHairStructHair) (_ CurlyGreasyHairStructHair) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_HairStruct_hairTest1, _swig_p) - return -} - -func (arg1 SwigcptrHairStruct) HairTest1(arg2 CurlyGreasyHairStructHair) (_swig_ret CurlyGreasyHairStructHair) { - return _swig_wrap_HairStruct_hairTest1(arg1, arg2) -} - -var _wrap_HairStruct_hairTest2 unsafe.Pointer - -func _swig_wrap_HairStruct_hairTest2(base SwigcptrHairStruct, _ CurlyGreasyHairStructHair) (_ CurlyGreasyHairStructHair) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_HairStruct_hairTest2, _swig_p) - return -} - -func (arg1 SwigcptrHairStruct) HairTest2(arg2 CurlyGreasyHairStructHair) (_swig_ret CurlyGreasyHairStructHair) { - return _swig_wrap_HairStruct_hairTest2(arg1, arg2) -} - -var _wrap_HairStruct_hairTest3 unsafe.Pointer - -func _swig_wrap_HairStruct_hairTest3(base SwigcptrHairStruct, _ CurlyGreasyHairStructHair) (_ CurlyGreasyHairStructHair) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_HairStruct_hairTest3, _swig_p) - return -} - -func (arg1 SwigcptrHairStruct) HairTest3(arg2 CurlyGreasyHairStructHair) (_swig_ret CurlyGreasyHairStructHair) { - return _swig_wrap_HairStruct_hairTest3(arg1, arg2) -} - -var _wrap_HairStruct_hairTest4 unsafe.Pointer - -func _swig_wrap_HairStruct_hairTest4(base SwigcptrHairStruct, _ CurlyGreasyHairStructHair) (_ CurlyGreasyHairStructHair) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_HairStruct_hairTest4, _swig_p) - return -} - -func (arg1 SwigcptrHairStruct) HairTest4(arg2 CurlyGreasyHairStructHair) (_swig_ret CurlyGreasyHairStructHair) { - return _swig_wrap_HairStruct_hairTest4(arg1, arg2) -} - -var _wrap_HairStruct_hairTest5 unsafe.Pointer - -func _swig_wrap_HairStruct_hairTest5(base SwigcptrHairStruct, _ CurlyGreasyHairStructHair) (_ CurlyGreasyHairStructHair) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_HairStruct_hairTest5, _swig_p) - return -} - -func (arg1 SwigcptrHairStruct) HairTest5(arg2 CurlyGreasyHairStructHair) (_swig_ret CurlyGreasyHairStructHair) { - return _swig_wrap_HairStruct_hairTest5(arg1, arg2) -} - -var _wrap_HairStruct_hairTest6 unsafe.Pointer - -func _swig_wrap_HairStruct_hairTest6(base SwigcptrHairStruct, _ CurlyGreasyHairStructHair) (_ CurlyGreasyHairStructHair) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_HairStruct_hairTest6, _swig_p) - return -} - -func (arg1 SwigcptrHairStruct) HairTest6(arg2 CurlyGreasyHairStructHair) (_swig_ret CurlyGreasyHairStructHair) { - return _swig_wrap_HairStruct_hairTest6(arg1, arg2) -} - -var _wrap_HairStruct_hairTest7 unsafe.Pointer - -func _swig_wrap_HairStruct_hairTest7(base SwigcptrHairStruct, _ CurlyGreasyHairStructHair) (_ CurlyGreasyHairStructHair) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_HairStruct_hairTest7, _swig_p) - return -} - -func (arg1 SwigcptrHairStruct) HairTest7(arg2 CurlyGreasyHairStructHair) (_swig_ret CurlyGreasyHairStructHair) { - return _swig_wrap_HairStruct_hairTest7(arg1, arg2) -} - -var _wrap_HairStruct_hairTest8 unsafe.Pointer - -func _swig_wrap_HairStruct_hairTest8(base SwigcptrHairStruct, _ CurlyGreasyHairStructHair) (_ CurlyGreasyHairStructHair) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_HairStruct_hairTest8, _swig_p) - return -} - -func (arg1 SwigcptrHairStruct) HairTest8(arg2 CurlyGreasyHairStructHair) (_swig_ret CurlyGreasyHairStructHair) { - return _swig_wrap_HairStruct_hairTest8(arg1, arg2) -} - -var _wrap_HairStruct_hairTest9 unsafe.Pointer - -func _swig_wrap_HairStruct_hairTest9(base SwigcptrHairStruct, _ CurlyGreasyHairStructHair) (_ CurlyGreasyHairStructHair) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_HairStruct_hairTest9, _swig_p) - return -} - -func (arg1 SwigcptrHairStruct) HairTest9(arg2 CurlyGreasyHairStructHair) (_swig_ret CurlyGreasyHairStructHair) { - return _swig_wrap_HairStruct_hairTest9(arg1, arg2) -} - -var _wrap_HairStruct_hairTestA unsafe.Pointer - -func _swig_wrap_HairStruct_hairTestA(base SwigcptrHairStruct, _ CurlyGreasyHairStructHair) (_ CurlyGreasyHairStructHair) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_HairStruct_hairTestA, _swig_p) - return -} - -func (arg1 SwigcptrHairStruct) HairTestA(arg2 CurlyGreasyHairStructHair) (_swig_ret CurlyGreasyHairStructHair) { - return _swig_wrap_HairStruct_hairTestA(arg1, arg2) -} - -var _wrap_HairStruct_hairTestB unsafe.Pointer - -func _swig_wrap_HairStruct_hairTestB(base SwigcptrHairStruct, _ CurlyGreasyHairStructHair) (_ CurlyGreasyHairStructHair) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_HairStruct_hairTestB, _swig_p) - return -} - -func (arg1 SwigcptrHairStruct) HairTestB(arg2 CurlyGreasyHairStructHair) (_swig_ret CurlyGreasyHairStructHair) { - return _swig_wrap_HairStruct_hairTestB(arg1, arg2) -} - -var _wrap_HairStruct_colourTest1 unsafe.Pointer - -func _swig_wrap_HairStruct_colourTest1(base SwigcptrHairStruct, _ Colour) (_ Colour) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_HairStruct_colourTest1, _swig_p) - return -} - -func (arg1 SwigcptrHairStruct) ColourTest1(arg2 Colour) (_swig_ret Colour) { - return _swig_wrap_HairStruct_colourTest1(arg1, arg2) -} - -var _wrap_HairStruct_colourTest2 unsafe.Pointer - -func _swig_wrap_HairStruct_colourTest2(base SwigcptrHairStruct, _ Colour) (_ Colour) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_HairStruct_colourTest2, _swig_p) - return -} - -func (arg1 SwigcptrHairStruct) ColourTest2(arg2 Colour) (_swig_ret Colour) { - return _swig_wrap_HairStruct_colourTest2(arg1, arg2) -} - -var _wrap_HairStruct_namedanonTest1 unsafe.Pointer - -func _swig_wrap_HairStruct_namedanonTest1(base SwigcptrHairStruct, _ Namedanon) (_ Namedanon) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_HairStruct_namedanonTest1, _swig_p) - return -} - -func (arg1 SwigcptrHairStruct) NamedanonTest1(arg2 Namedanon) (_swig_ret Namedanon) { - return _swig_wrap_HairStruct_namedanonTest1(arg1, arg2) -} - -var _wrap_HairStruct_namedanonspaceTest1 unsafe.Pointer - -func _swig_wrap_HairStruct_namedanonspaceTest1(base SwigcptrHairStruct, _ AnonSpaceNamedanonspace) (_ AnonSpaceNamedanonspace) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_HairStruct_namedanonspaceTest1, _swig_p) - return -} - -func (arg1 SwigcptrHairStruct) NamedanonspaceTest1(arg2 AnonSpaceNamedanonspace) (_swig_ret AnonSpaceNamedanonspace) { - return _swig_wrap_HairStruct_namedanonspaceTest1(arg1, arg2) -} - -var _wrap_HairStruct_treesGlobalTest1 unsafe.Pointer - -func _swig_wrap_HairStruct_treesGlobalTest1(base SwigcptrHairStruct, _ TreesClassTrees) (_ TreesClassTrees) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_HairStruct_treesGlobalTest1, _swig_p) - return -} - -func (arg1 SwigcptrHairStruct) TreesGlobalTest1(arg2 TreesClassTrees) (_swig_ret TreesClassTrees) { - return _swig_wrap_HairStruct_treesGlobalTest1(arg1, arg2) -} - -var _wrap_HairStruct_treesGlobalTest2 unsafe.Pointer - -func _swig_wrap_HairStruct_treesGlobalTest2(base SwigcptrHairStruct, _ TreesClassTrees) (_ TreesClassTrees) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_HairStruct_treesGlobalTest2, _swig_p) - return -} - -func (arg1 SwigcptrHairStruct) TreesGlobalTest2(arg2 TreesClassTrees) (_swig_ret TreesClassTrees) { - return _swig_wrap_HairStruct_treesGlobalTest2(arg1, arg2) -} - -var _wrap_HairStruct_treesGlobalTest3 unsafe.Pointer - -func _swig_wrap_HairStruct_treesGlobalTest3(base SwigcptrHairStruct, _ TreesClassTrees) (_ TreesClassTrees) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_HairStruct_treesGlobalTest3, _swig_p) - return -} - -func (arg1 SwigcptrHairStruct) TreesGlobalTest3(arg2 TreesClassTrees) (_swig_ret TreesClassTrees) { - return _swig_wrap_HairStruct_treesGlobalTest3(arg1, arg2) -} - -var _wrap_HairStruct_treesGlobalTest4 unsafe.Pointer - -func _swig_wrap_HairStruct_treesGlobalTest4(base SwigcptrHairStruct, _ TreesClassTrees) (_ TreesClassTrees) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_HairStruct_treesGlobalTest4, _swig_p) - return -} - -func (arg1 SwigcptrHairStruct) TreesGlobalTest4(arg2 TreesClassTrees) (_swig_ret TreesClassTrees) { - return _swig_wrap_HairStruct_treesGlobalTest4(arg1, arg2) -} - -var _wrap_HairStruct_treesGlobalTest5 unsafe.Pointer - -func _swig_wrap_HairStruct_treesGlobalTest5(base SwigcptrHairStruct, _ TreesClassTrees) (_ TreesClassTrees) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_HairStruct_treesGlobalTest5, _swig_p) - return -} - -func (arg1 SwigcptrHairStruct) TreesGlobalTest5(arg2 TreesClassTrees) (_swig_ret TreesClassTrees) { - return _swig_wrap_HairStruct_treesGlobalTest5(arg1, arg2) -} - -var _wrap_new_HairStruct unsafe.Pointer - -func _swig_wrap_new_HairStruct() (base SwigcptrHairStruct) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_HairStruct, _swig_p) - return -} - -func NewHairStruct() (_swig_ret HairStruct) { - return _swig_wrap_new_HairStruct() -} - -var _wrap_delete_HairStruct unsafe.Pointer - -func _swig_wrap_delete_HairStruct(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_HairStruct, _swig_p) - return -} - -func DeleteHairStruct(arg1 HairStruct) { - _swig_wrap_delete_HairStruct(arg1.Swigcptr()) -} - -type HairStruct interface { - Swigcptr() uintptr - SwigIsHairStruct() - HairTest1(arg2 CurlyGreasyHairStructHair) (_swig_ret CurlyGreasyHairStructHair) - HairTest2(arg2 CurlyGreasyHairStructHair) (_swig_ret CurlyGreasyHairStructHair) - HairTest3(arg2 CurlyGreasyHairStructHair) (_swig_ret CurlyGreasyHairStructHair) - HairTest4(arg2 CurlyGreasyHairStructHair) (_swig_ret CurlyGreasyHairStructHair) - HairTest5(arg2 CurlyGreasyHairStructHair) (_swig_ret CurlyGreasyHairStructHair) - HairTest6(arg2 CurlyGreasyHairStructHair) (_swig_ret CurlyGreasyHairStructHair) - HairTest7(arg2 CurlyGreasyHairStructHair) (_swig_ret CurlyGreasyHairStructHair) - HairTest8(arg2 CurlyGreasyHairStructHair) (_swig_ret CurlyGreasyHairStructHair) - HairTest9(arg2 CurlyGreasyHairStructHair) (_swig_ret CurlyGreasyHairStructHair) - HairTestA(arg2 CurlyGreasyHairStructHair) (_swig_ret CurlyGreasyHairStructHair) - HairTestB(arg2 CurlyGreasyHairStructHair) (_swig_ret CurlyGreasyHairStructHair) - ColourTest1(arg2 Colour) (_swig_ret Colour) - ColourTest2(arg2 Colour) (_swig_ret Colour) - NamedanonTest1(arg2 Namedanon) (_swig_ret Namedanon) - NamedanonspaceTest1(arg2 AnonSpaceNamedanonspace) (_swig_ret AnonSpaceNamedanonspace) - TreesGlobalTest1(arg2 TreesClassTrees) (_swig_ret TreesClassTrees) - TreesGlobalTest2(arg2 TreesClassTrees) (_swig_ret TreesClassTrees) - TreesGlobalTest3(arg2 TreesClassTrees) (_swig_ret TreesClassTrees) - TreesGlobalTest4(arg2 TreesClassTrees) (_swig_ret TreesClassTrees) - TreesGlobalTest5(arg2 TreesClassTrees) (_swig_ret TreesClassTrees) -} - -var _wrap_hairTest1 unsafe.Pointer - -func HairTest1(arg1 CurlyGreasyHairStructHair) (_swig_ret CurlyGreasyHairStructHair) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_hairTest1, _swig_p) - return -} -var _wrap_hairTest2 unsafe.Pointer - -func HairTest2(arg1 CurlyGreasyHairStructHair) (_swig_ret CurlyGreasyHairStructHair) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_hairTest2, _swig_p) - return -} -var _wrap_hairTest3 unsafe.Pointer - -func HairTest3(arg1 CurlyGreasyHairStructHair) (_swig_ret CurlyGreasyHairStructHair) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_hairTest3, _swig_p) - return -} -var _wrap_hairTest4 unsafe.Pointer - -func HairTest4(arg1 CurlyGreasyHairStructHair) (_swig_ret CurlyGreasyHairStructHair) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_hairTest4, _swig_p) - return -} -var _wrap_hairTest5 unsafe.Pointer - -func HairTest5(arg1 CurlyGreasyHairStructHair) (_swig_ret CurlyGreasyHairStructHair) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_hairTest5, _swig_p) - return -} -var _wrap_hairTest6 unsafe.Pointer - -func HairTest6(arg1 CurlyGreasyHairStructHair) (_swig_ret CurlyGreasyHairStructHair) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_hairTest6, _swig_p) - return -} -var _wrap_hairTest7 unsafe.Pointer - -func HairTest7(arg1 CurlyGreasyHairStructHair) (_swig_ret CurlyGreasyHairStructHair) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_hairTest7, _swig_p) - return -} -var _wrap_hairTest8 unsafe.Pointer - -func HairTest8(arg1 CurlyGreasyHairStructHair) (_swig_ret CurlyGreasyHairStructHair) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_hairTest8, _swig_p) - return -} -var _wrap_hairTest9 unsafe.Pointer - -func HairTest9(arg1 CurlyGreasyHairStructHair) (_swig_ret CurlyGreasyHairStructHair) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_hairTest9, _swig_p) - return -} -var _wrap_hairTestA unsafe.Pointer - -func HairTestA(arg1 CurlyGreasyHairStructHair) (_swig_ret CurlyGreasyHairStructHair) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_hairTestA, _swig_p) - return -} -var _wrap_hairTestB unsafe.Pointer - -func HairTestB(arg1 CurlyGreasyHairStructHair) (_swig_ret CurlyGreasyHairStructHair) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_hairTestB, _swig_p) - return -} -var _wrap_hairTestC unsafe.Pointer - -func HairTestC(arg1 *CurlyGreasyHairStructHair) (_swig_ret *CurlyGreasyHairStructHair) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_hairTestC, _swig_p) - return -} -var _wrap_hairTestA1 unsafe.Pointer - -func HairTestA1(arg1 CurlyGreasyHairStructHair) (_swig_ret CurlyGreasyHairStructHair) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_hairTestA1, _swig_p) - return -} -var _wrap_hairTestA2 unsafe.Pointer - -func HairTestA2(arg1 CurlyGreasyHairStructHair) (_swig_ret CurlyGreasyHairStructHair) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_hairTestA2, _swig_p) - return -} -var _wrap_hairTestA3 unsafe.Pointer - -func HairTestA3(arg1 CurlyGreasyHairStructHair) (_swig_ret CurlyGreasyHairStructHair) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_hairTestA3, _swig_p) - return -} -var _wrap_hairTestA4 unsafe.Pointer - -func HairTestA4(arg1 CurlyGreasyHairStructHair) (_swig_ret CurlyGreasyHairStructHair) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_hairTestA4, _swig_p) - return -} -var _wrap_hairTestA5 unsafe.Pointer - -func HairTestA5(arg1 CurlyGreasyHairStructHair) (_swig_ret CurlyGreasyHairStructHair) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_hairTestA5, _swig_p) - return -} -var _wrap_hairTestA6 unsafe.Pointer - -func HairTestA6(arg1 CurlyGreasyHairStructHair) (_swig_ret CurlyGreasyHairStructHair) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_hairTestA6, _swig_p) - return -} -var _wrap_hairTestA7 unsafe.Pointer - -func HairTestA7(arg1 CurlyGreasyHairStructHair) (_swig_ret CurlyGreasyHairStructHair) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_hairTestA7, _swig_p) - return -} -var _wrap_hairTestA8 unsafe.Pointer - -func HairTestA8(arg1 CurlyGreasyHairStructHair) (_swig_ret CurlyGreasyHairStructHair) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_hairTestA8, _swig_p) - return -} -var _wrap_hairTestA9 unsafe.Pointer - -func HairTestA9(arg1 CurlyGreasyHairStructHair) (_swig_ret CurlyGreasyHairStructHair) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_hairTestA9, _swig_p) - return -} -var _wrap_hairTestAA unsafe.Pointer - -func HairTestAA(arg1 CurlyGreasyHairStructHair) (_swig_ret CurlyGreasyHairStructHair) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_hairTestAA, _swig_p) - return -} -var _wrap_hairTestAB unsafe.Pointer - -func HairTestAB(arg1 CurlyGreasyHairStructHair) (_swig_ret CurlyGreasyHairStructHair) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_hairTestAB, _swig_p) - return -} -var _wrap_hairTestAC unsafe.Pointer - -func HairTestAC(arg1 *CurlyGreasyHairStructHair) (_swig_ret *CurlyGreasyHairStructHair) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_hairTestAC, _swig_p) - return -} -var _wrap_hairTestB1 unsafe.Pointer - -func HairTestB1(arg1 CurlyGreasyHairStructHair) (_swig_ret CurlyGreasyHairStructHair) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_hairTestB1, _swig_p) - return -} -var _wrap_hairTestB2 unsafe.Pointer - -func HairTestB2(arg1 CurlyGreasyHairStructHair) (_swig_ret CurlyGreasyHairStructHair) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_hairTestB2, _swig_p) - return -} -var _wrap_hairTestB3 unsafe.Pointer - -func HairTestB3(arg1 CurlyGreasyHairStructHair) (_swig_ret CurlyGreasyHairStructHair) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_hairTestB3, _swig_p) - return -} -var _wrap_hairTestB4 unsafe.Pointer - -func HairTestB4(arg1 CurlyGreasyHairStructHair) (_swig_ret CurlyGreasyHairStructHair) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_hairTestB4, _swig_p) - return -} -var _wrap_hairTestB5 unsafe.Pointer - -func HairTestB5(arg1 CurlyGreasyHairStructHair) (_swig_ret CurlyGreasyHairStructHair) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_hairTestB5, _swig_p) - return -} -var _wrap_hairTestB6 unsafe.Pointer - -func HairTestB6(arg1 CurlyGreasyHairStructHair) (_swig_ret CurlyGreasyHairStructHair) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_hairTestB6, _swig_p) - return -} -var _wrap_hairTestB7 unsafe.Pointer - -func HairTestB7(arg1 CurlyGreasyHairStructHair) (_swig_ret CurlyGreasyHairStructHair) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_hairTestB7, _swig_p) - return -} -var _wrap_hairTestB8 unsafe.Pointer - -func HairTestB8(arg1 CurlyGreasyHairStructHair) (_swig_ret CurlyGreasyHairStructHair) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_hairTestB8, _swig_p) - return -} -var _wrap_hairTestB9 unsafe.Pointer - -func HairTestB9(arg1 CurlyGreasyHairStructHair) (_swig_ret CurlyGreasyHairStructHair) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_hairTestB9, _swig_p) - return -} -var _wrap_hairTestBA unsafe.Pointer - -func HairTestBA(arg1 CurlyGreasyHairStructHair) (_swig_ret CurlyGreasyHairStructHair) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_hairTestBA, _swig_p) - return -} -var _wrap_hairTestBB unsafe.Pointer - -func HairTestBB(arg1 CurlyGreasyHairStructHair) (_swig_ret CurlyGreasyHairStructHair) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_hairTestBB, _swig_p) - return -} -var _wrap_hairTestBC unsafe.Pointer - -func HairTestBC(arg1 *CurlyGreasyHairStructHair) (_swig_ret *CurlyGreasyHairStructHair) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_hairTestBC, _swig_p) - return -} -var _wrap_hairTestC1 unsafe.Pointer - -func HairTestC1(arg1 CurlyGreasyHairStructHair) (_swig_ret CurlyGreasyHairStructHair) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_hairTestC1, _swig_p) - return -} -var _wrap_hairTestC2 unsafe.Pointer - -func HairTestC2(arg1 CurlyGreasyHairStructHair) (_swig_ret CurlyGreasyHairStructHair) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_hairTestC2, _swig_p) - return -} -var _wrap_hairTestC3 unsafe.Pointer - -func HairTestC3(arg1 CurlyGreasyHairStructHair) (_swig_ret CurlyGreasyHairStructHair) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_hairTestC3, _swig_p) - return -} -var _wrap_hairTestC4 unsafe.Pointer - -func HairTestC4(arg1 CurlyGreasyHairStructHair) (_swig_ret CurlyGreasyHairStructHair) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_hairTestC4, _swig_p) - return -} -var _wrap_hairTestC5 unsafe.Pointer - -func HairTestC5(arg1 CurlyGreasyHairStructHair) (_swig_ret CurlyGreasyHairStructHair) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_hairTestC5, _swig_p) - return -} -var _wrap_hairTestC6 unsafe.Pointer - -func HairTestC6(arg1 CurlyGreasyHairStructHair) (_swig_ret CurlyGreasyHairStructHair) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_hairTestC6, _swig_p) - return -} -var _wrap_hairTestC7 unsafe.Pointer - -func HairTestC7(arg1 CurlyGreasyHairStructHair) (_swig_ret CurlyGreasyHairStructHair) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_hairTestC7, _swig_p) - return -} -var _wrap_hairTestC8 unsafe.Pointer - -func HairTestC8(arg1 CurlyGreasyHairStructHair) (_swig_ret CurlyGreasyHairStructHair) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_hairTestC8, _swig_p) - return -} -var _wrap_hairTestC9 unsafe.Pointer - -func HairTestC9(arg1 CurlyGreasyHairStructHair) (_swig_ret CurlyGreasyHairStructHair) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_hairTestC9, _swig_p) - return -} -var _wrap_hairTestCA unsafe.Pointer - -func HairTestCA(arg1 CurlyGreasyHairStructHair) (_swig_ret CurlyGreasyHairStructHair) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_hairTestCA, _swig_p) - return -} -var _wrap_hairTestCB unsafe.Pointer - -func HairTestCB(arg1 CurlyGreasyHairStructHair) (_swig_ret CurlyGreasyHairStructHair) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_hairTestCB, _swig_p) - return -} -var _wrap_hairTestCC unsafe.Pointer - -func HairTestCC(arg1 *CurlyGreasyHairStructHair) (_swig_ret *CurlyGreasyHairStructHair) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_hairTestCC, _swig_p) - return -} -type SwigcptrFirStruct uintptr - -func (p SwigcptrFirStruct) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrFirStruct) SwigIsFirStruct() { -} - -var _wrap_FirStruct_hairTestFir1 unsafe.Pointer - -func _swig_wrap_FirStruct_hairTestFir1(base SwigcptrFirStruct, _ CurlyGreasyHairStructHair) (_ CurlyGreasyHairStructHair) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_FirStruct_hairTestFir1, _swig_p) - return -} - -func (arg1 SwigcptrFirStruct) HairTestFir1(arg2 CurlyGreasyHairStructHair) (_swig_ret CurlyGreasyHairStructHair) { - return _swig_wrap_FirStruct_hairTestFir1(arg1, arg2) -} - -var _wrap_FirStruct_hairTestFir2 unsafe.Pointer - -func _swig_wrap_FirStruct_hairTestFir2(base SwigcptrFirStruct, _ CurlyGreasyHairStructHair) (_ CurlyGreasyHairStructHair) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_FirStruct_hairTestFir2, _swig_p) - return -} - -func (arg1 SwigcptrFirStruct) HairTestFir2(arg2 CurlyGreasyHairStructHair) (_swig_ret CurlyGreasyHairStructHair) { - return _swig_wrap_FirStruct_hairTestFir2(arg1, arg2) -} - -var _wrap_FirStruct_hairTestFir3 unsafe.Pointer - -func _swig_wrap_FirStruct_hairTestFir3(base SwigcptrFirStruct, _ CurlyGreasyHairStructHair) (_ CurlyGreasyHairStructHair) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_FirStruct_hairTestFir3, _swig_p) - return -} - -func (arg1 SwigcptrFirStruct) HairTestFir3(arg2 CurlyGreasyHairStructHair) (_swig_ret CurlyGreasyHairStructHair) { - return _swig_wrap_FirStruct_hairTestFir3(arg1, arg2) -} - -var _wrap_FirStruct_hairTestFir4 unsafe.Pointer - -func _swig_wrap_FirStruct_hairTestFir4(base SwigcptrFirStruct, _ CurlyGreasyHairStructHair) (_ CurlyGreasyHairStructHair) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_FirStruct_hairTestFir4, _swig_p) - return -} - -func (arg1 SwigcptrFirStruct) HairTestFir4(arg2 CurlyGreasyHairStructHair) (_swig_ret CurlyGreasyHairStructHair) { - return _swig_wrap_FirStruct_hairTestFir4(arg1, arg2) -} - -var _wrap_FirStruct_hairTestFir5 unsafe.Pointer - -func _swig_wrap_FirStruct_hairTestFir5(base SwigcptrFirStruct, _ CurlyGreasyHairStructHair) (_ CurlyGreasyHairStructHair) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_FirStruct_hairTestFir5, _swig_p) - return -} - -func (arg1 SwigcptrFirStruct) HairTestFir5(arg2 CurlyGreasyHairStructHair) (_swig_ret CurlyGreasyHairStructHair) { - return _swig_wrap_FirStruct_hairTestFir5(arg1, arg2) -} - -var _wrap_FirStruct_hairTestFir6 unsafe.Pointer - -func _swig_wrap_FirStruct_hairTestFir6(base SwigcptrFirStruct, _ CurlyGreasyHairStructHair) (_ CurlyGreasyHairStructHair) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_FirStruct_hairTestFir6, _swig_p) - return -} - -func (arg1 SwigcptrFirStruct) HairTestFir6(arg2 CurlyGreasyHairStructHair) (_swig_ret CurlyGreasyHairStructHair) { - return _swig_wrap_FirStruct_hairTestFir6(arg1, arg2) -} - -var _wrap_FirStruct_hairTestFir7 unsafe.Pointer - -func _swig_wrap_FirStruct_hairTestFir7(base SwigcptrFirStruct, _ CurlyGreasyHairStructHair) (_ CurlyGreasyHairStructHair) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_FirStruct_hairTestFir7, _swig_p) - return -} - -func (arg1 SwigcptrFirStruct) HairTestFir7(arg2 CurlyGreasyHairStructHair) (_swig_ret CurlyGreasyHairStructHair) { - return _swig_wrap_FirStruct_hairTestFir7(arg1, arg2) -} - -var _wrap_FirStruct_hairTestFir8 unsafe.Pointer - -func _swig_wrap_FirStruct_hairTestFir8(base SwigcptrFirStruct, _ CurlyGreasyHairStructHair) (_ CurlyGreasyHairStructHair) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_FirStruct_hairTestFir8, _swig_p) - return -} - -func (arg1 SwigcptrFirStruct) HairTestFir8(arg2 CurlyGreasyHairStructHair) (_swig_ret CurlyGreasyHairStructHair) { - return _swig_wrap_FirStruct_hairTestFir8(arg1, arg2) -} - -var _wrap_FirStruct_hairTestFir9 unsafe.Pointer - -func _swig_wrap_FirStruct_hairTestFir9(base SwigcptrFirStruct, _ CurlyGreasyHairStructHair) (_ CurlyGreasyHairStructHair) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_FirStruct_hairTestFir9, _swig_p) - return -} - -func (arg1 SwigcptrFirStruct) HairTestFir9(arg2 CurlyGreasyHairStructHair) (_swig_ret CurlyGreasyHairStructHair) { - return _swig_wrap_FirStruct_hairTestFir9(arg1, arg2) -} - -var _wrap_FirStruct_hairTestFirA unsafe.Pointer - -func _swig_wrap_FirStruct_hairTestFirA(base SwigcptrFirStruct, _ CurlyGreasyHairStructHair) (_ CurlyGreasyHairStructHair) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_FirStruct_hairTestFirA, _swig_p) - return -} - -func (arg1 SwigcptrFirStruct) HairTestFirA(arg2 CurlyGreasyHairStructHair) (_swig_ret CurlyGreasyHairStructHair) { - return _swig_wrap_FirStruct_hairTestFirA(arg1, arg2) -} - -var _wrap_FirStruct_hairTestFirB unsafe.Pointer - -func _swig_wrap_FirStruct_hairTestFirB(base SwigcptrFirStruct, _ CurlyGreasyHairStructHair) (_ CurlyGreasyHairStructHair) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_FirStruct_hairTestFirB, _swig_p) - return -} - -func (arg1 SwigcptrFirStruct) HairTestFirB(arg2 CurlyGreasyHairStructHair) (_swig_ret CurlyGreasyHairStructHair) { - return _swig_wrap_FirStruct_hairTestFirB(arg1, arg2) -} - -var _wrap_new_FirStruct unsafe.Pointer - -func _swig_wrap_new_FirStruct() (base SwigcptrFirStruct) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_FirStruct, _swig_p) - return -} - -func NewFirStruct() (_swig_ret FirStruct) { - return _swig_wrap_new_FirStruct() -} - -var _wrap_delete_FirStruct unsafe.Pointer - -func _swig_wrap_delete_FirStruct(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_FirStruct, _swig_p) - return -} - -func DeleteFirStruct(arg1 FirStruct) { - _swig_wrap_delete_FirStruct(arg1.Swigcptr()) -} - -var _wrap_FirStruct_hairTest1 unsafe.Pointer - -func _swig_wrap_FirStruct_hairTest1(base SwigcptrFirStruct, _ CurlyGreasyHairStructHair) (_ CurlyGreasyHairStructHair) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_FirStruct_hairTest1, _swig_p) - return -} - -func (_swig_base SwigcptrFirStruct) HairTest1(arg1 CurlyGreasyHairStructHair) (_swig_ret CurlyGreasyHairStructHair) { - return _swig_wrap_FirStruct_hairTest1(_swig_base, arg1) -} - -var _wrap_FirStruct_hairTest2 unsafe.Pointer - -func _swig_wrap_FirStruct_hairTest2(base SwigcptrFirStruct, _ CurlyGreasyHairStructHair) (_ CurlyGreasyHairStructHair) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_FirStruct_hairTest2, _swig_p) - return -} - -func (_swig_base SwigcptrFirStruct) HairTest2(arg1 CurlyGreasyHairStructHair) (_swig_ret CurlyGreasyHairStructHair) { - return _swig_wrap_FirStruct_hairTest2(_swig_base, arg1) -} - -var _wrap_FirStruct_hairTest3 unsafe.Pointer - -func _swig_wrap_FirStruct_hairTest3(base SwigcptrFirStruct, _ CurlyGreasyHairStructHair) (_ CurlyGreasyHairStructHair) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_FirStruct_hairTest3, _swig_p) - return -} - -func (_swig_base SwigcptrFirStruct) HairTest3(arg1 CurlyGreasyHairStructHair) (_swig_ret CurlyGreasyHairStructHair) { - return _swig_wrap_FirStruct_hairTest3(_swig_base, arg1) -} - -var _wrap_FirStruct_hairTest4 unsafe.Pointer - -func _swig_wrap_FirStruct_hairTest4(base SwigcptrFirStruct, _ CurlyGreasyHairStructHair) (_ CurlyGreasyHairStructHair) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_FirStruct_hairTest4, _swig_p) - return -} - -func (_swig_base SwigcptrFirStruct) HairTest4(arg1 CurlyGreasyHairStructHair) (_swig_ret CurlyGreasyHairStructHair) { - return _swig_wrap_FirStruct_hairTest4(_swig_base, arg1) -} - -var _wrap_FirStruct_hairTest5 unsafe.Pointer - -func _swig_wrap_FirStruct_hairTest5(base SwigcptrFirStruct, _ CurlyGreasyHairStructHair) (_ CurlyGreasyHairStructHair) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_FirStruct_hairTest5, _swig_p) - return -} - -func (_swig_base SwigcptrFirStruct) HairTest5(arg1 CurlyGreasyHairStructHair) (_swig_ret CurlyGreasyHairStructHair) { - return _swig_wrap_FirStruct_hairTest5(_swig_base, arg1) -} - -var _wrap_FirStruct_hairTest6 unsafe.Pointer - -func _swig_wrap_FirStruct_hairTest6(base SwigcptrFirStruct, _ CurlyGreasyHairStructHair) (_ CurlyGreasyHairStructHair) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_FirStruct_hairTest6, _swig_p) - return -} - -func (_swig_base SwigcptrFirStruct) HairTest6(arg1 CurlyGreasyHairStructHair) (_swig_ret CurlyGreasyHairStructHair) { - return _swig_wrap_FirStruct_hairTest6(_swig_base, arg1) -} - -var _wrap_FirStruct_hairTest7 unsafe.Pointer - -func _swig_wrap_FirStruct_hairTest7(base SwigcptrFirStruct, _ CurlyGreasyHairStructHair) (_ CurlyGreasyHairStructHair) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_FirStruct_hairTest7, _swig_p) - return -} - -func (_swig_base SwigcptrFirStruct) HairTest7(arg1 CurlyGreasyHairStructHair) (_swig_ret CurlyGreasyHairStructHair) { - return _swig_wrap_FirStruct_hairTest7(_swig_base, arg1) -} - -var _wrap_FirStruct_hairTest8 unsafe.Pointer - -func _swig_wrap_FirStruct_hairTest8(base SwigcptrFirStruct, _ CurlyGreasyHairStructHair) (_ CurlyGreasyHairStructHair) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_FirStruct_hairTest8, _swig_p) - return -} - -func (_swig_base SwigcptrFirStruct) HairTest8(arg1 CurlyGreasyHairStructHair) (_swig_ret CurlyGreasyHairStructHair) { - return _swig_wrap_FirStruct_hairTest8(_swig_base, arg1) -} - -var _wrap_FirStruct_hairTest9 unsafe.Pointer - -func _swig_wrap_FirStruct_hairTest9(base SwigcptrFirStruct, _ CurlyGreasyHairStructHair) (_ CurlyGreasyHairStructHair) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_FirStruct_hairTest9, _swig_p) - return -} - -func (_swig_base SwigcptrFirStruct) HairTest9(arg1 CurlyGreasyHairStructHair) (_swig_ret CurlyGreasyHairStructHair) { - return _swig_wrap_FirStruct_hairTest9(_swig_base, arg1) -} - -var _wrap_FirStruct_hairTestA unsafe.Pointer - -func _swig_wrap_FirStruct_hairTestA(base SwigcptrFirStruct, _ CurlyGreasyHairStructHair) (_ CurlyGreasyHairStructHair) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_FirStruct_hairTestA, _swig_p) - return -} - -func (_swig_base SwigcptrFirStruct) HairTestA(arg1 CurlyGreasyHairStructHair) (_swig_ret CurlyGreasyHairStructHair) { - return _swig_wrap_FirStruct_hairTestA(_swig_base, arg1) -} - -var _wrap_FirStruct_hairTestB unsafe.Pointer - -func _swig_wrap_FirStruct_hairTestB(base SwigcptrFirStruct, _ CurlyGreasyHairStructHair) (_ CurlyGreasyHairStructHair) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_FirStruct_hairTestB, _swig_p) - return -} - -func (_swig_base SwigcptrFirStruct) HairTestB(arg1 CurlyGreasyHairStructHair) (_swig_ret CurlyGreasyHairStructHair) { - return _swig_wrap_FirStruct_hairTestB(_swig_base, arg1) -} - -var _wrap_FirStruct_colourTest1 unsafe.Pointer - -func _swig_wrap_FirStruct_colourTest1(base SwigcptrFirStruct, _ Colour) (_ Colour) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_FirStruct_colourTest1, _swig_p) - return -} - -func (_swig_base SwigcptrFirStruct) ColourTest1(arg1 Colour) (_swig_ret Colour) { - return _swig_wrap_FirStruct_colourTest1(_swig_base, arg1) -} - -var _wrap_FirStruct_colourTest2 unsafe.Pointer - -func _swig_wrap_FirStruct_colourTest2(base SwigcptrFirStruct, _ Colour) (_ Colour) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_FirStruct_colourTest2, _swig_p) - return -} - -func (_swig_base SwigcptrFirStruct) ColourTest2(arg1 Colour) (_swig_ret Colour) { - return _swig_wrap_FirStruct_colourTest2(_swig_base, arg1) -} - -var _wrap_FirStruct_namedanonTest1 unsafe.Pointer - -func _swig_wrap_FirStruct_namedanonTest1(base SwigcptrFirStruct, _ Namedanon) (_ Namedanon) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_FirStruct_namedanonTest1, _swig_p) - return -} - -func (_swig_base SwigcptrFirStruct) NamedanonTest1(arg1 Namedanon) (_swig_ret Namedanon) { - return _swig_wrap_FirStruct_namedanonTest1(_swig_base, arg1) -} - -var _wrap_FirStruct_namedanonspaceTest1 unsafe.Pointer - -func _swig_wrap_FirStruct_namedanonspaceTest1(base SwigcptrFirStruct, _ AnonSpaceNamedanonspace) (_ AnonSpaceNamedanonspace) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_FirStruct_namedanonspaceTest1, _swig_p) - return -} - -func (_swig_base SwigcptrFirStruct) NamedanonspaceTest1(arg1 AnonSpaceNamedanonspace) (_swig_ret AnonSpaceNamedanonspace) { - return _swig_wrap_FirStruct_namedanonspaceTest1(_swig_base, arg1) -} - -var _wrap_FirStruct_treesGlobalTest1 unsafe.Pointer - -func _swig_wrap_FirStruct_treesGlobalTest1(base SwigcptrFirStruct, _ TreesClassTrees) (_ TreesClassTrees) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_FirStruct_treesGlobalTest1, _swig_p) - return -} - -func (_swig_base SwigcptrFirStruct) TreesGlobalTest1(arg1 TreesClassTrees) (_swig_ret TreesClassTrees) { - return _swig_wrap_FirStruct_treesGlobalTest1(_swig_base, arg1) -} - -var _wrap_FirStruct_treesGlobalTest2 unsafe.Pointer - -func _swig_wrap_FirStruct_treesGlobalTest2(base SwigcptrFirStruct, _ TreesClassTrees) (_ TreesClassTrees) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_FirStruct_treesGlobalTest2, _swig_p) - return -} - -func (_swig_base SwigcptrFirStruct) TreesGlobalTest2(arg1 TreesClassTrees) (_swig_ret TreesClassTrees) { - return _swig_wrap_FirStruct_treesGlobalTest2(_swig_base, arg1) -} - -var _wrap_FirStruct_treesGlobalTest3 unsafe.Pointer - -func _swig_wrap_FirStruct_treesGlobalTest3(base SwigcptrFirStruct, _ TreesClassTrees) (_ TreesClassTrees) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_FirStruct_treesGlobalTest3, _swig_p) - return -} - -func (_swig_base SwigcptrFirStruct) TreesGlobalTest3(arg1 TreesClassTrees) (_swig_ret TreesClassTrees) { - return _swig_wrap_FirStruct_treesGlobalTest3(_swig_base, arg1) -} - -var _wrap_FirStruct_treesGlobalTest4 unsafe.Pointer - -func _swig_wrap_FirStruct_treesGlobalTest4(base SwigcptrFirStruct, _ TreesClassTrees) (_ TreesClassTrees) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_FirStruct_treesGlobalTest4, _swig_p) - return -} - -func (_swig_base SwigcptrFirStruct) TreesGlobalTest4(arg1 TreesClassTrees) (_swig_ret TreesClassTrees) { - return _swig_wrap_FirStruct_treesGlobalTest4(_swig_base, arg1) -} - -var _wrap_FirStruct_treesGlobalTest5 unsafe.Pointer - -func _swig_wrap_FirStruct_treesGlobalTest5(base SwigcptrFirStruct, _ TreesClassTrees) (_ TreesClassTrees) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_FirStruct_treesGlobalTest5, _swig_p) - return -} - -func (_swig_base SwigcptrFirStruct) TreesGlobalTest5(arg1 TreesClassTrees) (_swig_ret TreesClassTrees) { - return _swig_wrap_FirStruct_treesGlobalTest5(_swig_base, arg1) -} - -func (p SwigcptrFirStruct) SwigIsHairStruct() { -} - -func (p SwigcptrFirStruct) SwigGetHairStruct() HairStruct { - return SwigcptrHairStruct(p.Swigcptr()) -} - -type FirStruct interface { - Swigcptr() uintptr - SwigIsFirStruct() - HairTestFir1(arg2 CurlyGreasyHairStructHair) (_swig_ret CurlyGreasyHairStructHair) - HairTestFir2(arg2 CurlyGreasyHairStructHair) (_swig_ret CurlyGreasyHairStructHair) - HairTestFir3(arg2 CurlyGreasyHairStructHair) (_swig_ret CurlyGreasyHairStructHair) - HairTestFir4(arg2 CurlyGreasyHairStructHair) (_swig_ret CurlyGreasyHairStructHair) - HairTestFir5(arg2 CurlyGreasyHairStructHair) (_swig_ret CurlyGreasyHairStructHair) - HairTestFir6(arg2 CurlyGreasyHairStructHair) (_swig_ret CurlyGreasyHairStructHair) - HairTestFir7(arg2 CurlyGreasyHairStructHair) (_swig_ret CurlyGreasyHairStructHair) - HairTestFir8(arg2 CurlyGreasyHairStructHair) (_swig_ret CurlyGreasyHairStructHair) - HairTestFir9(arg2 CurlyGreasyHairStructHair) (_swig_ret CurlyGreasyHairStructHair) - HairTestFirA(arg2 CurlyGreasyHairStructHair) (_swig_ret CurlyGreasyHairStructHair) - HairTestFirB(arg2 CurlyGreasyHairStructHair) (_swig_ret CurlyGreasyHairStructHair) - HairTest1(arg1 CurlyGreasyHairStructHair) (_swig_ret CurlyGreasyHairStructHair) - HairTest2(arg1 CurlyGreasyHairStructHair) (_swig_ret CurlyGreasyHairStructHair) - HairTest3(arg1 CurlyGreasyHairStructHair) (_swig_ret CurlyGreasyHairStructHair) - HairTest4(arg1 CurlyGreasyHairStructHair) (_swig_ret CurlyGreasyHairStructHair) - HairTest5(arg1 CurlyGreasyHairStructHair) (_swig_ret CurlyGreasyHairStructHair) - HairTest6(arg1 CurlyGreasyHairStructHair) (_swig_ret CurlyGreasyHairStructHair) - HairTest7(arg1 CurlyGreasyHairStructHair) (_swig_ret CurlyGreasyHairStructHair) - HairTest8(arg1 CurlyGreasyHairStructHair) (_swig_ret CurlyGreasyHairStructHair) - HairTest9(arg1 CurlyGreasyHairStructHair) (_swig_ret CurlyGreasyHairStructHair) - HairTestA(arg1 CurlyGreasyHairStructHair) (_swig_ret CurlyGreasyHairStructHair) - HairTestB(arg1 CurlyGreasyHairStructHair) (_swig_ret CurlyGreasyHairStructHair) - ColourTest1(arg1 Colour) (_swig_ret Colour) - ColourTest2(arg1 Colour) (_swig_ret Colour) - NamedanonTest1(arg1 Namedanon) (_swig_ret Namedanon) - NamedanonspaceTest1(arg1 AnonSpaceNamedanonspace) (_swig_ret AnonSpaceNamedanonspace) - TreesGlobalTest1(arg1 TreesClassTrees) (_swig_ret TreesClassTrees) - TreesGlobalTest2(arg1 TreesClassTrees) (_swig_ret TreesClassTrees) - TreesGlobalTest3(arg1 TreesClassTrees) (_swig_ret TreesClassTrees) - TreesGlobalTest4(arg1 TreesClassTrees) (_swig_ret TreesClassTrees) - TreesGlobalTest5(arg1 TreesClassTrees) (_swig_ret TreesClassTrees) - SwigIsHairStruct() - SwigGetHairStruct() HairStruct -} - -type SwigcptrObscure uintptr - -func (p SwigcptrObscure) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrObscure) SwigIsObscure() { -} - -type ObscureZero int -type ObscureOne int -type ObscureTwo int -var _wrap_twoagain_Obscure unsafe.Pointer - -func _swig_getObscure_twoagain_Obscure() (_swig_ret ObscureTwo) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_twoagain_Obscure, _swig_p) - return -} -var ObscureTwoagain ObscureTwo = _swig_getObscure_twoagain_Obscure() -type ObscureEmpty int -type ObscureAlsoEmpty int -var _wrap_new_Obscure unsafe.Pointer - -func _swig_wrap_new_Obscure() (base SwigcptrObscure) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Obscure, _swig_p) - return -} - -func NewObscure() (_swig_ret Obscure) { - return _swig_wrap_new_Obscure() -} - -var _wrap_delete_Obscure unsafe.Pointer - -func _swig_wrap_delete_Obscure(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Obscure, _swig_p) - return -} - -func DeleteObscure(arg1 Obscure) { - _swig_wrap_delete_Obscure(arg1.Swigcptr()) -} - -type Obscure interface { - Swigcptr() uintptr - SwigIsObscure() -} - -var _wrap_globalinstance1 unsafe.Pointer - -func _swig_getglobalinstance1() (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_globalinstance1, _swig_p) - return -} -var Globalinstance1 int = _swig_getglobalinstance1() -var _wrap_globalinstance2 unsafe.Pointer - -func _swig_getglobalinstance2() (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_globalinstance2, _swig_p) - return -} -var Globalinstance2 int = _swig_getglobalinstance2() -var _wrap_globalinstance3 unsafe.Pointer - -func _swig_getglobalinstance3() (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_globalinstance3, _swig_p) - return -} -var Globalinstance3 int = _swig_getglobalinstance3() -var _wrap_GlobalInstance_set unsafe.Pointer - -func _swig_wrap_GlobalInstance_set(base int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_GlobalInstance_set, _swig_p) - return -} - -func SetGlobalInstance(arg1 int) { - _swig_wrap_GlobalInstance_set(arg1) -} - -var _wrap_GlobalInstance_get unsafe.Pointer - -func GetGlobalInstance() (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_GlobalInstance_get, _swig_p) - return -} -type SwigcptrInstances uintptr - -func (p SwigcptrInstances) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrInstances) SwigIsInstances() { -} - -var _wrap_memberinstance1_Instances unsafe.Pointer - -func _swig_getInstances_memberinstance1_Instances() (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_memberinstance1_Instances, _swig_p) - return -} -var InstancesMemberinstance1 int = _swig_getInstances_memberinstance1_Instances() -var _wrap_memberinstance2_Instances unsafe.Pointer - -func _swig_getInstances_memberinstance2_Instances() (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_memberinstance2_Instances, _swig_p) - return -} -var InstancesMemberinstance2 int = _swig_getInstances_memberinstance2_Instances() -var _wrap_memberinstance3_Instances unsafe.Pointer - -func _swig_getInstances_memberinstance3_Instances() (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_memberinstance3_Instances, _swig_p) - return -} -var InstancesMemberinstance3 int = _swig_getInstances_memberinstance3_Instances() -var _wrap_Instances_MemberInstance_set unsafe.Pointer - -func _swig_wrap_Instances_MemberInstance_set(base SwigcptrInstances, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Instances_MemberInstance_set, _swig_p) - return -} - -func (arg1 SwigcptrInstances) SetMemberInstance(arg2 int) { - _swig_wrap_Instances_MemberInstance_set(arg1, arg2) -} - -var _wrap_Instances_MemberInstance_get unsafe.Pointer - -func _swig_wrap_Instances_MemberInstance_get(base SwigcptrInstances) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Instances_MemberInstance_get, _swig_p) - return -} - -func (arg1 SwigcptrInstances) GetMemberInstance() (_swig_ret int) { - return _swig_wrap_Instances_MemberInstance_get(arg1) -} - -var _wrap_new_Instances unsafe.Pointer - -func _swig_wrap_new_Instances() (base SwigcptrInstances) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Instances, _swig_p) - return -} - -func NewInstances() (_swig_ret Instances) { - return _swig_wrap_new_Instances() -} - -var _wrap_delete_Instances unsafe.Pointer - -func _swig_wrap_delete_Instances(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Instances, _swig_p) - return -} - -func DeleteInstances(arg1 Instances) { - _swig_wrap_delete_Instances(arg1.Swigcptr()) -} - -type Instances interface { - Swigcptr() uintptr - SwigIsInstances() - SetMemberInstance(arg2 int) - GetMemberInstance() (_swig_ret int) -} - -type SwigcptrIgnoreTest uintptr - -func (p SwigcptrIgnoreTest) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrIgnoreTest) SwigIsIgnoreTest() { -} - -type IgnoreTestIgnoreA int -var _wrap_ignoreA_zero_IgnoreTest unsafe.Pointer - -func _swig_getIgnoreTest_ignoreA_zero_IgnoreTest() (_swig_ret IgnoreTestIgnoreA) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_ignoreA_zero_IgnoreTest, _swig_p) - return -} -var IgnoreTestIgnoreA_zero IgnoreTestIgnoreA = _swig_getIgnoreTest_ignoreA_zero_IgnoreTest() -var _wrap_ignoreA_three_IgnoreTest unsafe.Pointer - -func _swig_getIgnoreTest_ignoreA_three_IgnoreTest() (_swig_ret IgnoreTestIgnoreA) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_ignoreA_three_IgnoreTest, _swig_p) - return -} -var IgnoreTestIgnoreA_three IgnoreTestIgnoreA = _swig_getIgnoreTest_ignoreA_three_IgnoreTest() -var _wrap_ignoreA_ten_IgnoreTest unsafe.Pointer - -func _swig_getIgnoreTest_ignoreA_ten_IgnoreTest() (_swig_ret IgnoreTestIgnoreA) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_ignoreA_ten_IgnoreTest, _swig_p) - return -} -var IgnoreTestIgnoreA_ten IgnoreTestIgnoreA = _swig_getIgnoreTest_ignoreA_ten_IgnoreTest() -var _wrap_ignoreA_eleven_IgnoreTest unsafe.Pointer - -func _swig_getIgnoreTest_ignoreA_eleven_IgnoreTest() (_swig_ret IgnoreTestIgnoreA) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_ignoreA_eleven_IgnoreTest, _swig_p) - return -} -var IgnoreTestIgnoreA_eleven IgnoreTestIgnoreA = _swig_getIgnoreTest_ignoreA_eleven_IgnoreTest() -var _wrap_ignoreA_thirteen_IgnoreTest unsafe.Pointer - -func _swig_getIgnoreTest_ignoreA_thirteen_IgnoreTest() (_swig_ret IgnoreTestIgnoreA) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_ignoreA_thirteen_IgnoreTest, _swig_p) - return -} -var IgnoreTestIgnoreA_thirteen IgnoreTestIgnoreA = _swig_getIgnoreTest_ignoreA_thirteen_IgnoreTest() -var _wrap_ignoreA_fourteen_IgnoreTest unsafe.Pointer - -func _swig_getIgnoreTest_ignoreA_fourteen_IgnoreTest() (_swig_ret IgnoreTestIgnoreA) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_ignoreA_fourteen_IgnoreTest, _swig_p) - return -} -var IgnoreTestIgnoreA_fourteen IgnoreTestIgnoreA = _swig_getIgnoreTest_ignoreA_fourteen_IgnoreTest() -var _wrap_ignoreA_twenty_IgnoreTest unsafe.Pointer - -func _swig_getIgnoreTest_ignoreA_twenty_IgnoreTest() (_swig_ret IgnoreTestIgnoreA) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_ignoreA_twenty_IgnoreTest, _swig_p) - return -} -var IgnoreTestIgnoreA_twenty IgnoreTestIgnoreA = _swig_getIgnoreTest_ignoreA_twenty_IgnoreTest() -var _wrap_ignoreA_thirty_IgnoreTest unsafe.Pointer - -func _swig_getIgnoreTest_ignoreA_thirty_IgnoreTest() (_swig_ret IgnoreTestIgnoreA) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_ignoreA_thirty_IgnoreTest, _swig_p) - return -} -var IgnoreTestIgnoreA_thirty IgnoreTestIgnoreA = _swig_getIgnoreTest_ignoreA_thirty_IgnoreTest() -var _wrap_ignoreA_thirty_two_IgnoreTest unsafe.Pointer - -func _swig_getIgnoreTest_ignoreA_thirty_two_IgnoreTest() (_swig_ret IgnoreTestIgnoreA) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_ignoreA_thirty_two_IgnoreTest, _swig_p) - return -} -var IgnoreTestIgnoreA_thirty_two IgnoreTestIgnoreA = _swig_getIgnoreTest_ignoreA_thirty_two_IgnoreTest() -var _wrap_ignoreA_thirty_three_IgnoreTest unsafe.Pointer - -func _swig_getIgnoreTest_ignoreA_thirty_three_IgnoreTest() (_swig_ret IgnoreTestIgnoreA) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_ignoreA_thirty_three_IgnoreTest, _swig_p) - return -} -var IgnoreTestIgnoreA_thirty_three IgnoreTestIgnoreA = _swig_getIgnoreTest_ignoreA_thirty_three_IgnoreTest() -type IgnoreTestIgnoreB int -var _wrap_ignoreB_eleven_IgnoreTest unsafe.Pointer - -func _swig_getIgnoreTest_ignoreB_eleven_IgnoreTest() (_swig_ret IgnoreTestIgnoreB) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_ignoreB_eleven_IgnoreTest, _swig_p) - return -} -var IgnoreTestIgnoreB_eleven IgnoreTestIgnoreB = _swig_getIgnoreTest_ignoreB_eleven_IgnoreTest() -var _wrap_ignoreB_twelve_IgnoreTest unsafe.Pointer - -func _swig_getIgnoreTest_ignoreB_twelve_IgnoreTest() (_swig_ret IgnoreTestIgnoreB) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_ignoreB_twelve_IgnoreTest, _swig_p) - return -} -var IgnoreTestIgnoreB_twelve IgnoreTestIgnoreB = _swig_getIgnoreTest_ignoreB_twelve_IgnoreTest() -var _wrap_ignoreB_thirty_one_IgnoreTest unsafe.Pointer - -func _swig_getIgnoreTest_ignoreB_thirty_one_IgnoreTest() (_swig_ret IgnoreTestIgnoreB) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_ignoreB_thirty_one_IgnoreTest, _swig_p) - return -} -var IgnoreTestIgnoreB_thirty_one IgnoreTestIgnoreB = _swig_getIgnoreTest_ignoreB_thirty_one_IgnoreTest() -var _wrap_ignoreB_thirty_two_IgnoreTest unsafe.Pointer - -func _swig_getIgnoreTest_ignoreB_thirty_two_IgnoreTest() (_swig_ret IgnoreTestIgnoreB) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_ignoreB_thirty_two_IgnoreTest, _swig_p) - return -} -var IgnoreTestIgnoreB_thirty_two IgnoreTestIgnoreB = _swig_getIgnoreTest_ignoreB_thirty_two_IgnoreTest() -var _wrap_ignoreB_forty_one_IgnoreTest unsafe.Pointer - -func _swig_getIgnoreTest_ignoreB_forty_one_IgnoreTest() (_swig_ret IgnoreTestIgnoreB) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_ignoreB_forty_one_IgnoreTest, _swig_p) - return -} -var IgnoreTestIgnoreB_forty_one IgnoreTestIgnoreB = _swig_getIgnoreTest_ignoreB_forty_one_IgnoreTest() -var _wrap_ignoreB_forty_two_IgnoreTest unsafe.Pointer - -func _swig_getIgnoreTest_ignoreB_forty_two_IgnoreTest() (_swig_ret IgnoreTestIgnoreB) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_ignoreB_forty_two_IgnoreTest, _swig_p) - return -} -var IgnoreTestIgnoreB_forty_two IgnoreTestIgnoreB = _swig_getIgnoreTest_ignoreB_forty_two_IgnoreTest() -type IgnoreTestIgnoreC int -var _wrap_ignoreC_ten_IgnoreTest unsafe.Pointer - -func _swig_getIgnoreTest_ignoreC_ten_IgnoreTest() (_swig_ret IgnoreTestIgnoreC) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_ignoreC_ten_IgnoreTest, _swig_p) - return -} -var IgnoreTestIgnoreC_ten IgnoreTestIgnoreC = _swig_getIgnoreTest_ignoreC_ten_IgnoreTest() -var _wrap_ignoreC_twelve_IgnoreTest unsafe.Pointer - -func _swig_getIgnoreTest_ignoreC_twelve_IgnoreTest() (_swig_ret IgnoreTestIgnoreC) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_ignoreC_twelve_IgnoreTest, _swig_p) - return -} -var IgnoreTestIgnoreC_twelve IgnoreTestIgnoreC = _swig_getIgnoreTest_ignoreC_twelve_IgnoreTest() -var _wrap_ignoreC_twenty_IgnoreTest unsafe.Pointer - -func _swig_getIgnoreTest_ignoreC_twenty_IgnoreTest() (_swig_ret IgnoreTestIgnoreC) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_ignoreC_twenty_IgnoreTest, _swig_p) - return -} -var IgnoreTestIgnoreC_twenty IgnoreTestIgnoreC = _swig_getIgnoreTest_ignoreC_twenty_IgnoreTest() -var _wrap_ignoreC_thirty_IgnoreTest unsafe.Pointer - -func _swig_getIgnoreTest_ignoreC_thirty_IgnoreTest() (_swig_ret IgnoreTestIgnoreC) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_ignoreC_thirty_IgnoreTest, _swig_p) - return -} -var IgnoreTestIgnoreC_thirty IgnoreTestIgnoreC = _swig_getIgnoreTest_ignoreC_thirty_IgnoreTest() -var _wrap_ignoreC_thirty_two_IgnoreTest unsafe.Pointer - -func _swig_getIgnoreTest_ignoreC_thirty_two_IgnoreTest() (_swig_ret IgnoreTestIgnoreC) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_ignoreC_thirty_two_IgnoreTest, _swig_p) - return -} -var IgnoreTestIgnoreC_thirty_two IgnoreTestIgnoreC = _swig_getIgnoreTest_ignoreC_thirty_two_IgnoreTest() -var _wrap_ignoreC_forty_IgnoreTest unsafe.Pointer - -func _swig_getIgnoreTest_ignoreC_forty_IgnoreTest() (_swig_ret IgnoreTestIgnoreC) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_ignoreC_forty_IgnoreTest, _swig_p) - return -} -var IgnoreTestIgnoreC_forty IgnoreTestIgnoreC = _swig_getIgnoreTest_ignoreC_forty_IgnoreTest() -var _wrap_ignoreC_forty_two_IgnoreTest unsafe.Pointer - -func _swig_getIgnoreTest_ignoreC_forty_two_IgnoreTest() (_swig_ret IgnoreTestIgnoreC) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_ignoreC_forty_two_IgnoreTest, _swig_p) - return -} -var IgnoreTestIgnoreC_forty_two IgnoreTestIgnoreC = _swig_getIgnoreTest_ignoreC_forty_two_IgnoreTest() -type IgnoreTestIgnoreD int -var _wrap_ignoreD_twenty_one_IgnoreTest unsafe.Pointer - -func _swig_getIgnoreTest_ignoreD_twenty_one_IgnoreTest() (_swig_ret IgnoreTestIgnoreD) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_ignoreD_twenty_one_IgnoreTest, _swig_p) - return -} -var IgnoreTestIgnoreD_twenty_one IgnoreTestIgnoreD = _swig_getIgnoreTest_ignoreD_twenty_one_IgnoreTest() -var _wrap_ignoreD_twenty_two_IgnoreTest unsafe.Pointer - -func _swig_getIgnoreTest_ignoreD_twenty_two_IgnoreTest() (_swig_ret IgnoreTestIgnoreD) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_ignoreD_twenty_two_IgnoreTest, _swig_p) - return -} -var IgnoreTestIgnoreD_twenty_two IgnoreTestIgnoreD = _swig_getIgnoreTest_ignoreD_twenty_two_IgnoreTest() -type IgnoreTestIgnoreE int -var _wrap_ignoreE_zero_IgnoreTest unsafe.Pointer - -func _swig_getIgnoreTest_ignoreE_zero_IgnoreTest() (_swig_ret IgnoreTestIgnoreE) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_ignoreE_zero_IgnoreTest, _swig_p) - return -} -var IgnoreTestIgnoreE_zero IgnoreTestIgnoreE = _swig_getIgnoreTest_ignoreE_zero_IgnoreTest() -var _wrap_ignoreE_twenty_one_IgnoreTest unsafe.Pointer - -func _swig_getIgnoreTest_ignoreE_twenty_one_IgnoreTest() (_swig_ret IgnoreTestIgnoreE) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_ignoreE_twenty_one_IgnoreTest, _swig_p) - return -} -var IgnoreTestIgnoreE_twenty_one IgnoreTestIgnoreE = _swig_getIgnoreTest_ignoreE_twenty_one_IgnoreTest() -var _wrap_ignoreE_twenty_two_IgnoreTest unsafe.Pointer - -func _swig_getIgnoreTest_ignoreE_twenty_two_IgnoreTest() (_swig_ret IgnoreTestIgnoreE) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_ignoreE_twenty_two_IgnoreTest, _swig_p) - return -} -var IgnoreTestIgnoreE_twenty_two IgnoreTestIgnoreE = _swig_getIgnoreTest_ignoreE_twenty_two_IgnoreTest() -var _wrap_new_IgnoreTest unsafe.Pointer - -func _swig_wrap_new_IgnoreTest() (base SwigcptrIgnoreTest) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_IgnoreTest, _swig_p) - return -} - -func NewIgnoreTest() (_swig_ret IgnoreTest) { - return _swig_wrap_new_IgnoreTest() -} - -var _wrap_delete_IgnoreTest unsafe.Pointer - -func _swig_wrap_delete_IgnoreTest(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_IgnoreTest, _swig_p) - return -} - -func DeleteIgnoreTest(arg1 IgnoreTest) { - _swig_wrap_delete_IgnoreTest(arg1.Swigcptr()) -} - -type IgnoreTest interface { - Swigcptr() uintptr - SwigIsIgnoreTest() -} - -var _wrap_ignoreATest unsafe.Pointer - -func IgnoreATest(arg1 IgnoreTestIgnoreA) (_swig_ret IgnoreTestIgnoreA) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_ignoreATest, _swig_p) - return -} -var _wrap_ignoreBTest unsafe.Pointer - -func IgnoreBTest(arg1 IgnoreTestIgnoreB) (_swig_ret IgnoreTestIgnoreB) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_ignoreBTest, _swig_p) - return -} -var _wrap_ignoreCTest unsafe.Pointer - -func IgnoreCTest(arg1 IgnoreTestIgnoreC) (_swig_ret IgnoreTestIgnoreC) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_ignoreCTest, _swig_p) - return -} -var _wrap_ignoreDTest unsafe.Pointer - -func IgnoreDTest(arg1 IgnoreTestIgnoreD) (_swig_ret IgnoreTestIgnoreD) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_ignoreDTest, _swig_p) - return -} -var _wrap_ignoreETest unsafe.Pointer - -func IgnoreETest(arg1 IgnoreTestIgnoreE) (_swig_ret IgnoreTestIgnoreE) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_ignoreETest, _swig_p) - return -} -type RepeatSpaceRepeat int -var _wrap_one unsafe.Pointer - -func _swig_getone() (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_one, _swig_p) - return -} -var One int = _swig_getone() -var _wrap_initial unsafe.Pointer - -func _swig_getinitial() (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_initial, _swig_p) - return -} -var Initial int = _swig_getinitial() -var _wrap_two unsafe.Pointer - -func _swig_gettwo() (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_two, _swig_p) - return -} -var Two int = _swig_gettwo() -var _wrap_three unsafe.Pointer - -func _swig_getthree() (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_three, _swig_p) - return -} -var Three int = _swig_getthree() -var _wrap_llast unsafe.Pointer - -func _swig_getllast() (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_llast, _swig_p) - return -} -var Llast int = _swig_getllast() -var _wrap_end unsafe.Pointer - -func _swig_getend() (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_end, _swig_p) - return -} -var End int = _swig_getend() -var _wrap_repeatTest unsafe.Pointer - -func RepeatTest(arg1 RepeatSpaceRepeat) (_swig_ret RepeatSpaceRepeat) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_repeatTest, _swig_p) - return -} -type DifferentSpaceDifferentTypes int -var _wrap_typeint unsafe.Pointer - -func _swig_gettypeint() (_swig_ret DifferentSpaceDifferentTypes) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_typeint, _swig_p) - return -} -var Typeint DifferentSpaceDifferentTypes = _swig_gettypeint() -var _wrap_typeboolfalse unsafe.Pointer - -func _swig_gettypeboolfalse() (_swig_ret DifferentSpaceDifferentTypes) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_typeboolfalse, _swig_p) - return -} -var Typeboolfalse DifferentSpaceDifferentTypes = _swig_gettypeboolfalse() -var _wrap_typebooltrue unsafe.Pointer - -func _swig_gettypebooltrue() (_swig_ret DifferentSpaceDifferentTypes) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_typebooltrue, _swig_p) - return -} -var Typebooltrue DifferentSpaceDifferentTypes = _swig_gettypebooltrue() -var _wrap_typebooltwo unsafe.Pointer - -func _swig_gettypebooltwo() (_swig_ret DifferentSpaceDifferentTypes) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_typebooltwo, _swig_p) - return -} -var Typebooltwo DifferentSpaceDifferentTypes = _swig_gettypebooltwo() -var _wrap_typechar unsafe.Pointer - -func _swig_gettypechar() (_swig_ret DifferentSpaceDifferentTypes) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_typechar, _swig_p) - return -} -var Typechar DifferentSpaceDifferentTypes = _swig_gettypechar() -var _wrap_typedefaultint unsafe.Pointer - -func _swig_gettypedefaultint() (_swig_ret DifferentSpaceDifferentTypes) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_typedefaultint, _swig_p) - return -} -var Typedefaultint DifferentSpaceDifferentTypes = _swig_gettypedefaultint() -var _wrap_differentTypesTest unsafe.Pointer - -func DifferentTypesTest(arg1 DifferentSpaceDifferentTypes) (_swig_ret DifferentSpaceDifferentTypes) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_differentTypesTest, _swig_p) - return -} -var _wrap_global_typeint unsafe.Pointer - -func _swig_getglobal_typeint() (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_global_typeint, _swig_p) - return -} -var Global_typeint int = _swig_getglobal_typeint() -var _wrap_global_typeboolfalse unsafe.Pointer - -func _swig_getglobal_typeboolfalse() (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_global_typeboolfalse, _swig_p) - return -} -var Global_typeboolfalse int = _swig_getglobal_typeboolfalse() -var _wrap_global_typebooltrue unsafe.Pointer - -func _swig_getglobal_typebooltrue() (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_global_typebooltrue, _swig_p) - return -} -var Global_typebooltrue int = _swig_getglobal_typebooltrue() -var _wrap_global_typebooltwo unsafe.Pointer - -func _swig_getglobal_typebooltwo() (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_global_typebooltwo, _swig_p) - return -} -var Global_typebooltwo int = _swig_getglobal_typebooltwo() -var _wrap_global_typechar unsafe.Pointer - -func _swig_getglobal_typechar() (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_global_typechar, _swig_p) - return -} -var Global_typechar int = _swig_getglobal_typechar() -var _wrap_global_typedefaultint unsafe.Pointer - -func _swig_getglobal_typedefaultint() (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_global_typedefaultint, _swig_p) - return -} -var Global_typedefaultint int = _swig_getglobal_typedefaultint() -var _wrap_globalDifferentTypesTest unsafe.Pointer - -func GlobalDifferentTypesTest(arg1 int) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_globalDifferentTypesTest, _swig_p) - return -} -type DifferentSpaceDifferentTypesNoConst int -var _wrap_typeint_noconst unsafe.Pointer - -func _swig_gettypeint_noconst() (_swig_ret DifferentSpaceDifferentTypesNoConst) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_typeint_noconst, _swig_p) - return -} -var Typeint_noconst DifferentSpaceDifferentTypesNoConst = _swig_gettypeint_noconst() -var _wrap_typeboolfalse_noconst unsafe.Pointer - -func _swig_gettypeboolfalse_noconst() (_swig_ret DifferentSpaceDifferentTypesNoConst) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_typeboolfalse_noconst, _swig_p) - return -} -var Typeboolfalse_noconst DifferentSpaceDifferentTypesNoConst = _swig_gettypeboolfalse_noconst() -var _wrap_typebooltrue_noconst unsafe.Pointer - -func _swig_gettypebooltrue_noconst() (_swig_ret DifferentSpaceDifferentTypesNoConst) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_typebooltrue_noconst, _swig_p) - return -} -var Typebooltrue_noconst DifferentSpaceDifferentTypesNoConst = _swig_gettypebooltrue_noconst() -var _wrap_typebooltwo_noconst unsafe.Pointer - -func _swig_gettypebooltwo_noconst() (_swig_ret DifferentSpaceDifferentTypesNoConst) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_typebooltwo_noconst, _swig_p) - return -} -var Typebooltwo_noconst DifferentSpaceDifferentTypesNoConst = _swig_gettypebooltwo_noconst() -var _wrap_typechar_noconst unsafe.Pointer - -func _swig_gettypechar_noconst() (_swig_ret DifferentSpaceDifferentTypesNoConst) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_typechar_noconst, _swig_p) - return -} -var Typechar_noconst DifferentSpaceDifferentTypesNoConst = _swig_gettypechar_noconst() -var _wrap_typedefaultint_noconst unsafe.Pointer - -func _swig_gettypedefaultint_noconst() (_swig_ret DifferentSpaceDifferentTypesNoConst) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_typedefaultint_noconst, _swig_p) - return -} -var Typedefaultint_noconst DifferentSpaceDifferentTypesNoConst = _swig_gettypedefaultint_noconst() -var _wrap_global_typeint_noconst unsafe.Pointer - -func _swig_getglobal_typeint_noconst() (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_global_typeint_noconst, _swig_p) - return -} -var Global_typeint_noconst int = _swig_getglobal_typeint_noconst() -var _wrap_global_typeboolfalse_noconst unsafe.Pointer - -func _swig_getglobal_typeboolfalse_noconst() (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_global_typeboolfalse_noconst, _swig_p) - return -} -var Global_typeboolfalse_noconst int = _swig_getglobal_typeboolfalse_noconst() -var _wrap_global_typebooltrue_noconst unsafe.Pointer - -func _swig_getglobal_typebooltrue_noconst() (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_global_typebooltrue_noconst, _swig_p) - return -} -var Global_typebooltrue_noconst int = _swig_getglobal_typebooltrue_noconst() -var _wrap_global_typebooltwo_noconst unsafe.Pointer - -func _swig_getglobal_typebooltwo_noconst() (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_global_typebooltwo_noconst, _swig_p) - return -} -var Global_typebooltwo_noconst int = _swig_getglobal_typebooltwo_noconst() -var _wrap_global_typechar_noconst unsafe.Pointer - -func _swig_getglobal_typechar_noconst() (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_global_typechar_noconst, _swig_p) - return -} -var Global_typechar_noconst int = _swig_getglobal_typechar_noconst() -var _wrap_global_typedefaultint_noconst unsafe.Pointer - -func _swig_getglobal_typedefaultint_noconst() (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_global_typedefaultint_noconst, _swig_p) - return -} -var Global_typedefaultint_noconst int = _swig_getglobal_typedefaultint_noconst() - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/enum_var.go b/Examples/test-suite/go/enum_var.go deleted file mode 100644 index e250cb631..000000000 --- a/Examples/test-suite/go/enum_var.go +++ /dev/null @@ -1,73 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../enum_var.i - -package enum_var - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type Fruit int -var _wrap_APPLE unsafe.Pointer - -func _swig_getAPPLE() (_swig_ret Fruit) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_APPLE, _swig_p) - return -} -var APPLE Fruit = _swig_getAPPLE() -var _wrap_PEAR unsafe.Pointer - -func _swig_getPEAR() (_swig_ret Fruit) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_PEAR, _swig_p) - return -} -var PEAR Fruit = _swig_getPEAR() -var _wrap_test_set unsafe.Pointer - -func _swig_wrap_test_set(base Fruit) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_test_set, _swig_p) - return -} - -func SetTest(arg1 Fruit) { - _swig_wrap_test_set(arg1) -} - -var _wrap_test_get unsafe.Pointer - -func GetTest() (_swig_ret Fruit) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_test_get, _swig_p) - return -} - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/enums.go b/Examples/test-suite/go/enums.go deleted file mode 100644 index 8a781fae8..000000000 --- a/Examples/test-suite/go/enums.go +++ /dev/null @@ -1,507 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../enums.i - -package enums - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type Foo1 int -var _wrap_CSP_ITERATION_FWD unsafe.Pointer - -func _swig_getCSP_ITERATION_FWD() (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_CSP_ITERATION_FWD, _swig_p) - return -} -var CSP_ITERATION_FWD int = _swig_getCSP_ITERATION_FWD() -var _wrap_CSP_ITERATION_BWD unsafe.Pointer - -func _swig_getCSP_ITERATION_BWD() (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_CSP_ITERATION_BWD, _swig_p) - return -} -var CSP_ITERATION_BWD int = _swig_getCSP_ITERATION_BWD() -type Enum_SS_foo2 int -var _wrap_ABCDE unsafe.Pointer - -func _swig_getABCDE() (_swig_ret Enum_SS_foo2) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_ABCDE, _swig_p) - return -} -var ABCDE Enum_SS_foo2 = _swig_getABCDE() -var _wrap_FGHJI unsafe.Pointer - -func _swig_getFGHJI() (_swig_ret Enum_SS_foo2) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_FGHJI, _swig_p) - return -} -var FGHJI Enum_SS_foo2 = _swig_getFGHJI() -var _wrap_bar1 unsafe.Pointer - -func _swig_wrap_bar1(base Foo1) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_bar1, _swig_p) - return -} - -func Bar1(arg1 Foo1) { - _swig_wrap_bar1(arg1) -} - -var _wrap_bar2 unsafe.Pointer - -func _swig_wrap_bar2(base Enum_SS_foo2) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_bar2, _swig_p) - return -} - -func Bar2(arg1 Enum_SS_foo2) { - _swig_wrap_bar2(arg1) -} - -var _wrap_bar3 unsafe.Pointer - -func _swig_wrap_bar3(base Enum_SS_foo2) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_bar3, _swig_p) - return -} - -func Bar3(arg1 Enum_SS_foo2) { - _swig_wrap_bar3(arg1) -} - -type Enum_SS_sad int -var _wrap_boo unsafe.Pointer - -func _swig_getboo() (_swig_ret Enum_SS_sad) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_boo, _swig_p) - return -} -var Boo Enum_SS_sad = _swig_getboo() -var _wrap_hoo unsafe.Pointer - -func _swig_gethoo() (_swig_ret Enum_SS_sad) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_hoo, _swig_p) - return -} -var Hoo Enum_SS_sad = _swig_gethoo() -var _wrap_globalinstance1 unsafe.Pointer - -func _swig_getglobalinstance1() (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_globalinstance1, _swig_p) - return -} -var Globalinstance1 int = _swig_getglobalinstance1() -var _wrap_globalinstance2 unsafe.Pointer - -func _swig_getglobalinstance2() (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_globalinstance2, _swig_p) - return -} -var Globalinstance2 int = _swig_getglobalinstance2() -var _wrap_globalinstance3 unsafe.Pointer - -func _swig_getglobalinstance3() (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_globalinstance3, _swig_p) - return -} -var Globalinstance3 int = _swig_getglobalinstance3() -var _wrap_GlobalInstance_set unsafe.Pointer - -func _swig_wrap_GlobalInstance_set(base int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_GlobalInstance_set, _swig_p) - return -} - -func SetGlobalInstance(arg1 int) { - _swig_wrap_GlobalInstance_set(arg1) -} - -var _wrap_GlobalInstance_get unsafe.Pointer - -func GetGlobalInstance() (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_GlobalInstance_get, _swig_p) - return -} -var _wrap_AnonEnum1 unsafe.Pointer - -func _swig_getAnonEnum1() (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_AnonEnum1, _swig_p) - return -} -var AnonEnum1 int = _swig_getAnonEnum1() -var _wrap_AnonEnum2 unsafe.Pointer - -func _swig_getAnonEnum2() (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_AnonEnum2, _swig_p) - return -} -var AnonEnum2 int = _swig_getAnonEnum2() -type SwigcptrFoo uintptr - -func (p SwigcptrFoo) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrFoo) SwigIsFoo() { -} - -var _wrap_BAR1_Foo unsafe.Pointer - -func _swig_getFoo_BAR1_Foo() (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_BAR1_Foo, _swig_p) - return -} -var FooBAR1 int = _swig_getFoo_BAR1_Foo() -var _wrap_BAR2_Foo unsafe.Pointer - -func _swig_getFoo_BAR2_Foo() (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_BAR2_Foo, _swig_p) - return -} -var FooBAR2 int = _swig_getFoo_BAR2_Foo() -var _wrap_Foo_e_set unsafe.Pointer - -func _swig_wrap_Foo_e_set(base SwigcptrFoo, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_e_set, _swig_p) - return -} - -func (arg1 SwigcptrFoo) SetE(arg2 int) { - _swig_wrap_Foo_e_set(arg1, arg2) -} - -var _wrap_Foo_e_get unsafe.Pointer - -func _swig_wrap_Foo_e_get(base SwigcptrFoo) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_e_get, _swig_p) - return -} - -func (arg1 SwigcptrFoo) GetE() (_swig_ret int) { - return _swig_wrap_Foo_e_get(arg1) -} - -var _wrap_new_Foo unsafe.Pointer - -func _swig_wrap_new_Foo() (base SwigcptrFoo) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Foo, _swig_p) - return -} - -func NewFoo() (_swig_ret Foo) { - return _swig_wrap_new_Foo() -} - -var _wrap_delete_Foo unsafe.Pointer - -func _swig_wrap_delete_Foo(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Foo, _swig_p) - return -} - -func DeleteFoo(arg1 Foo) { - _swig_wrap_delete_Foo(arg1.Swigcptr()) -} - -type Foo interface { - Swigcptr() uintptr - SwigIsFoo() - SetE(arg2 int) - GetE() (_swig_ret int) -} - -type SwigcptrIFoo uintptr - -func (p SwigcptrIFoo) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrIFoo) SwigIsIFoo() { -} - -var _wrap_Phoo_iFoo unsafe.Pointer - -func _swig_getiFoo_Phoo_iFoo() (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_Phoo_iFoo, _swig_p) - return -} -var IFooPhoo int = _swig_getiFoo_Phoo_iFoo() -var _wrap_Char_iFoo unsafe.Pointer - -func _swig_getiFoo_Char_iFoo() (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_Char_iFoo, _swig_p) - return -} -var IFooChar int = _swig_getiFoo_Char_iFoo() -var _wrap_iFoo_e_set unsafe.Pointer - -func _swig_wrap_iFoo_e_set(base SwigcptrIFoo, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_iFoo_e_set, _swig_p) - return -} - -func (arg1 SwigcptrIFoo) SetE(arg2 int) { - _swig_wrap_iFoo_e_set(arg1, arg2) -} - -var _wrap_iFoo_e_get unsafe.Pointer - -func _swig_wrap_iFoo_e_get(base SwigcptrIFoo) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_iFoo_e_get, _swig_p) - return -} - -func (arg1 SwigcptrIFoo) GetE() (_swig_ret int) { - return _swig_wrap_iFoo_e_get(arg1) -} - -var _wrap_new_iFoo unsafe.Pointer - -func _swig_wrap_new_iFoo() (base SwigcptrIFoo) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_iFoo, _swig_p) - return -} - -func NewIFoo() (_swig_ret IFoo) { - return _swig_wrap_new_iFoo() -} - -var _wrap_delete_iFoo unsafe.Pointer - -func _swig_wrap_delete_iFoo(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_iFoo, _swig_p) - return -} - -func DeleteIFoo(arg1 IFoo) { - _swig_wrap_delete_iFoo(arg1.Swigcptr()) -} - -type IFoo interface { - Swigcptr() uintptr - SwigIsIFoo() - SetE(arg2 int) - GetE() (_swig_ret int) -} - -type Enum_SS_Exclamation int -var _wrap_goodness unsafe.Pointer - -func _swig_getgoodness() (_swig_ret Enum_SS_Exclamation) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_goodness, _swig_p) - return -} -var Goodness Enum_SS_Exclamation = _swig_getgoodness() -var _wrap_gracious unsafe.Pointer - -func _swig_getgracious() (_swig_ret Enum_SS_Exclamation) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_gracious, _swig_p) - return -} -var Gracious Enum_SS_Exclamation = _swig_getgracious() -var _wrap_me unsafe.Pointer - -func _swig_getme() (_swig_ret Enum_SS_Exclamation) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_me, _swig_p) - return -} -var Me Enum_SS_Exclamation = _swig_getme() -var _wrap_enumInstance_set unsafe.Pointer - -func _swig_wrap_enumInstance_set(base Enum_SS_Exclamation) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_enumInstance_set, _swig_p) - return -} - -func SetEnumInstance(arg1 Enum_SS_Exclamation) { - _swig_wrap_enumInstance_set(arg1) -} - -var _wrap_enumInstance_get unsafe.Pointer - -func GetEnumInstance() (_swig_ret Enum_SS_Exclamation) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_enumInstance_get, _swig_p) - return -} -type Enum_SS_ContainYourself int -var _wrap_slap unsafe.Pointer - -func _swig_getslap() (_swig_ret Enum_SS_ContainYourself) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_slap, _swig_p) - return -} -var Slap Enum_SS_ContainYourself = _swig_getslap() -var _wrap_mine unsafe.Pointer - -func _swig_getmine() (_swig_ret Enum_SS_ContainYourself) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_mine, _swig_p) - return -} -var Mine Enum_SS_ContainYourself = _swig_getmine() -var _wrap_thigh unsafe.Pointer - -func _swig_getthigh() (_swig_ret Enum_SS_ContainYourself) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_thigh, _swig_p) - return -} -var Thigh Enum_SS_ContainYourself = _swig_getthigh() -var _wrap_Slap_set unsafe.Pointer - -func _swig_wrap_Slap_set(base Enum_SS_ContainYourself) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Slap_set, _swig_p) - return -} - -func SetSlap(arg1 Enum_SS_ContainYourself) { - _swig_wrap_Slap_set(arg1) -} - -var _wrap_Slap_get unsafe.Pointer - -func GetSlap() (_swig_ret Enum_SS_ContainYourself) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_Slap_get, _swig_p) - return -} -var _wrap_Mine_set unsafe.Pointer - -func _swig_wrap_Mine_set(base Enum_SS_ContainYourself) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Mine_set, _swig_p) - return -} - -func SetMine(arg1 Enum_SS_ContainYourself) { - _swig_wrap_Mine_set(arg1) -} - -var _wrap_Mine_get unsafe.Pointer - -func GetMine() (_swig_ret Enum_SS_ContainYourself) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_Mine_get, _swig_p) - return -} -var _wrap_Thigh_set unsafe.Pointer - -func _swig_wrap_Thigh_set(base Enum_SS_ContainYourself) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Thigh_set, _swig_p) - return -} - -func SetThigh(arg1 Enum_SS_ContainYourself) { - _swig_wrap_Thigh_set(arg1) -} - -var _wrap_Thigh_get unsafe.Pointer - -func GetThigh() (_swig_ret Enum_SS_ContainYourself) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_Thigh_get, _swig_p) - return -} -var _wrap_pThigh_set unsafe.Pointer - -func _swig_wrap_pThigh_set(base *Enum_SS_ContainYourself) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_pThigh_set, _swig_p) - return -} - -func SetPThigh(arg1 *Enum_SS_ContainYourself) { - _swig_wrap_pThigh_set(arg1) -} - -var _wrap_pThigh_get unsafe.Pointer - -func GetPThigh() (_swig_ret *Enum_SS_ContainYourself) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_pThigh_get, _swig_p) - return -} -var _wrap_arrayContainYourself_set unsafe.Pointer - -func _swig_wrap_arrayContainYourself_set(base *Enum_SS_ContainYourself) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_arrayContainYourself_set, _swig_p) - return -} - -func SetArrayContainYourself(arg1 *Enum_SS_ContainYourself) { - _swig_wrap_arrayContainYourself_set(arg1) -} - -var _wrap_arrayContainYourself_get unsafe.Pointer - -func GetArrayContainYourself() (_swig_ret *Enum_SS_ContainYourself) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_arrayContainYourself_get, _swig_p) - return -} - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/enums_runme b/Examples/test-suite/go/enums_runme deleted file mode 100755 index 786758034..000000000 Binary files a/Examples/test-suite/go/enums_runme and /dev/null differ diff --git a/Examples/test-suite/go/equality.go b/Examples/test-suite/go/equality.go deleted file mode 100644 index 9ec4bcd02..000000000 --- a/Examples/test-suite/go/equality.go +++ /dev/null @@ -1,336 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../equality.i - -package equality - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrPoint uintptr - -func (p SwigcptrPoint) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrPoint) SwigIsPoint() { -} - -var _wrap_Point_x_set unsafe.Pointer - -func _swig_wrap_Point_x_set(base SwigcptrPoint, _ float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Point_x_set, _swig_p) - return -} - -func (arg1 SwigcptrPoint) SetX(arg2 float64) { - _swig_wrap_Point_x_set(arg1, arg2) -} - -var _wrap_Point_x_get unsafe.Pointer - -func _swig_wrap_Point_x_get(base SwigcptrPoint) (_ float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Point_x_get, _swig_p) - return -} - -func (arg1 SwigcptrPoint) GetX() (_swig_ret float64) { - return _swig_wrap_Point_x_get(arg1) -} - -var _wrap_Point_y_set unsafe.Pointer - -func _swig_wrap_Point_y_set(base SwigcptrPoint, _ float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Point_y_set, _swig_p) - return -} - -func (arg1 SwigcptrPoint) SetY(arg2 float64) { - _swig_wrap_Point_y_set(arg1, arg2) -} - -var _wrap_Point_y_get unsafe.Pointer - -func _swig_wrap_Point_y_get(base SwigcptrPoint) (_ float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Point_y_get, _swig_p) - return -} - -func (arg1 SwigcptrPoint) GetY() (_swig_ret float64) { - return _swig_wrap_Point_y_get(arg1) -} - -var _wrap_new_Point unsafe.Pointer - -func _swig_wrap_new_Point() (base SwigcptrPoint) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Point, _swig_p) - return -} - -func NewPoint() (_swig_ret Point) { - return _swig_wrap_new_Point() -} - -var _wrap_delete_Point unsafe.Pointer - -func _swig_wrap_delete_Point(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Point, _swig_p) - return -} - -func DeletePoint(arg1 Point) { - _swig_wrap_delete_Point(arg1.Swigcptr()) -} - -type Point interface { - Swigcptr() uintptr - SwigIsPoint() - SetX(arg2 float64) - GetX() (_swig_ret float64) - SetY(arg2 float64) - GetY() (_swig_ret float64) -} - -var _wrap_s_zeroPoint_get unsafe.Pointer - -func _swig_wrap_s_zeroPoint_get() (base SwigcptrPoint) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_s_zeroPoint_get, _swig_p) - return -} - -func GetS_zeroPoint() (_swig_ret Point) { - return _swig_wrap_s_zeroPoint_get() -} - -var _wrap_MakePoint unsafe.Pointer - -func _swig_wrap_MakePoint(base float64, _ float64) (_ SwigcptrPoint) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_MakePoint, _swig_p) - return -} - -func MakePoint(arg1 float64, arg2 float64) (_swig_ret Point) { - return _swig_wrap_MakePoint(arg1, arg2) -} - -var _wrap_GetZeroPointPtr unsafe.Pointer - -func _swig_wrap_GetZeroPointPtr() (base SwigcptrPoint) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_GetZeroPointPtr, _swig_p) - return -} - -func GetZeroPointPtr() (_swig_ret Point) { - return _swig_wrap_GetZeroPointPtr() -} - -var _wrap_GetZeroPointCopy unsafe.Pointer - -func _swig_wrap_GetZeroPointCopy() (base SwigcptrPoint) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_GetZeroPointCopy, _swig_p) - return -} - -func GetZeroPointCopy() (_swig_ret Point) { - return _swig_wrap_GetZeroPointCopy() -} - -type SwigcptrEqualOpDefined uintptr - -func (p SwigcptrEqualOpDefined) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrEqualOpDefined) SwigIsEqualOpDefined() { -} - -var _wrap_new_EqualOpDefined__SWIG_0 unsafe.Pointer - -func _swig_wrap_new_EqualOpDefined__SWIG_0() (base SwigcptrEqualOpDefined) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_EqualOpDefined__SWIG_0, _swig_p) - return -} - -func NewEqualOpDefined__SWIG_0() (_swig_ret EqualOpDefined) { - return _swig_wrap_new_EqualOpDefined__SWIG_0() -} - -var _wrap_new_EqualOpDefined__SWIG_1 unsafe.Pointer - -func _swig_wrap_new_EqualOpDefined__SWIG_1(base int) (_ SwigcptrEqualOpDefined) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_EqualOpDefined__SWIG_1, _swig_p) - return -} - -func NewEqualOpDefined__SWIG_1(arg1 int) (_swig_ret EqualOpDefined) { - return _swig_wrap_new_EqualOpDefined__SWIG_1(arg1) -} - -func NewEqualOpDefined(a ...interface{}) EqualOpDefined { - argc := len(a) - if argc == 0 { - return NewEqualOpDefined__SWIG_0() - } - if argc == 1 { - return NewEqualOpDefined__SWIG_1(a[0].(int)) - } - panic("No match for overloaded function call") -} - -var _wrap_EqualOpDefined_x_set unsafe.Pointer - -func _swig_wrap_EqualOpDefined_x_set(base SwigcptrEqualOpDefined, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_EqualOpDefined_x_set, _swig_p) - return -} - -func (arg1 SwigcptrEqualOpDefined) SetX(arg2 int) { - _swig_wrap_EqualOpDefined_x_set(arg1, arg2) -} - -var _wrap_EqualOpDefined_x_get unsafe.Pointer - -func _swig_wrap_EqualOpDefined_x_get(base SwigcptrEqualOpDefined) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_EqualOpDefined_x_get, _swig_p) - return -} - -func (arg1 SwigcptrEqualOpDefined) GetX() (_swig_ret int) { - return _swig_wrap_EqualOpDefined_x_get(arg1) -} - -var _wrap_delete_EqualOpDefined unsafe.Pointer - -func _swig_wrap_delete_EqualOpDefined(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_EqualOpDefined, _swig_p) - return -} - -func DeleteEqualOpDefined(arg1 EqualOpDefined) { - _swig_wrap_delete_EqualOpDefined(arg1.Swigcptr()) -} - -type EqualOpDefined interface { - Swigcptr() uintptr - SwigIsEqualOpDefined() - SetX(arg2 int) - GetX() (_swig_ret int) -} - -type SwigcptrEqualOpWrong uintptr - -func (p SwigcptrEqualOpWrong) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrEqualOpWrong) SwigIsEqualOpWrong() { -} - -var _wrap_EqualOpWrong_GetStaticObject unsafe.Pointer - -func _swig_wrap_EqualOpWrong_GetStaticObject() (base SwigcptrEqualOpWrong) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_EqualOpWrong_GetStaticObject, _swig_p) - return -} - -func EqualOpWrongGetStaticObject() (_swig_ret EqualOpWrong) { - return _swig_wrap_EqualOpWrong_GetStaticObject() -} - -var _wrap_new_EqualOpWrong unsafe.Pointer - -func _swig_wrap_new_EqualOpWrong() (base SwigcptrEqualOpWrong) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_EqualOpWrong, _swig_p) - return -} - -func NewEqualOpWrong() (_swig_ret EqualOpWrong) { - return _swig_wrap_new_EqualOpWrong() -} - -var _wrap_delete_EqualOpWrong unsafe.Pointer - -func _swig_wrap_delete_EqualOpWrong(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_EqualOpWrong, _swig_p) - return -} - -func DeleteEqualOpWrong(arg1 EqualOpWrong) { - _swig_wrap_delete_EqualOpWrong(arg1.Swigcptr()) -} - -type EqualOpWrong interface { - Swigcptr() uintptr - SwigIsEqualOpWrong() -} - -var _wrap_s_wrongEqOp_set unsafe.Pointer - -func _swig_wrap_s_wrongEqOp_set(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_s_wrongEqOp_set, _swig_p) - return -} - -func SetS_wrongEqOp(arg1 EqualOpWrong) { - _swig_wrap_s_wrongEqOp_set(arg1.Swigcptr()) -} - -var _wrap_s_wrongEqOp_get unsafe.Pointer - -func _swig_wrap_s_wrongEqOp_get() (base SwigcptrEqualOpWrong) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_s_wrongEqOp_get, _swig_p) - return -} - -func GetS_wrongEqOp() (_swig_ret EqualOpWrong) { - return _swig_wrap_s_wrongEqOp_get() -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/evil_diamond.go b/Examples/test-suite/go/evil_diamond.go deleted file mode 100644 index cbcbd50fa..000000000 --- a/Examples/test-suite/go/evil_diamond.go +++ /dev/null @@ -1,250 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../evil_diamond.i - -package evil_diamond - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrFoo uintptr - -func (p SwigcptrFoo) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrFoo) SwigIsFoo() { -} - -var _wrap_new_foo unsafe.Pointer - -func _swig_wrap_new_foo() (base SwigcptrFoo) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_foo, _swig_p) - return -} - -func NewFoo() (_swig_ret Foo) { - return _swig_wrap_new_foo() -} - -var _wrap_delete_foo unsafe.Pointer - -func _swig_wrap_delete_foo(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_foo, _swig_p) - return -} - -func DeleteFoo(arg1 Foo) { - _swig_wrap_delete_foo(arg1.Swigcptr()) -} - -type Foo interface { - Swigcptr() uintptr - SwigIsFoo() -} - -type SwigcptrBar uintptr - -func (p SwigcptrBar) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrBar) SwigIsBar() { -} - -var _wrap_new_bar unsafe.Pointer - -func _swig_wrap_new_bar() (base SwigcptrBar) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_bar, _swig_p) - return -} - -func NewBar() (_swig_ret Bar) { - return _swig_wrap_new_bar() -} - -var _wrap_delete_bar unsafe.Pointer - -func _swig_wrap_delete_bar(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_bar, _swig_p) - return -} - -func DeleteBar(arg1 Bar) { - _swig_wrap_delete_bar(arg1.Swigcptr()) -} - -func (p SwigcptrBar) SwigIsFoo() { -} - -func (p SwigcptrBar) SwigGetFoo() Foo { - return SwigcptrFoo(p.Swigcptr()) -} - -type Bar interface { - Swigcptr() uintptr - SwigIsBar() - SwigIsFoo() - SwigGetFoo() Foo -} - -type SwigcptrBaz uintptr - -func (p SwigcptrBaz) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrBaz) SwigIsBaz() { -} - -var _wrap_new_baz unsafe.Pointer - -func _swig_wrap_new_baz() (base SwigcptrBaz) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_baz, _swig_p) - return -} - -func NewBaz() (_swig_ret Baz) { - return _swig_wrap_new_baz() -} - -var _wrap_delete_baz unsafe.Pointer - -func _swig_wrap_delete_baz(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_baz, _swig_p) - return -} - -func DeleteBaz(arg1 Baz) { - _swig_wrap_delete_baz(arg1.Swigcptr()) -} - -func (p SwigcptrBaz) SwigIsFoo() { -} - -func (p SwigcptrBaz) SwigGetFoo() Foo { - return SwigcptrFoo(p.Swigcptr()) -} - -type Baz interface { - Swigcptr() uintptr - SwigIsBaz() - SwigIsFoo() - SwigGetFoo() Foo -} - -type SwigcptrSpam uintptr - -func (p SwigcptrSpam) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrSpam) SwigIsSpam() { -} - -var _wrap_new_spam unsafe.Pointer - -func _swig_wrap_new_spam() (base SwigcptrSpam) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_spam, _swig_p) - return -} - -func NewSpam() (_swig_ret Spam) { - return _swig_wrap_new_spam() -} - -var _wrap_delete_spam unsafe.Pointer - -func _swig_wrap_delete_spam(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_spam, _swig_p) - return -} - -func DeleteSpam(arg1 Spam) { - _swig_wrap_delete_spam(arg1.Swigcptr()) -} - -func (p SwigcptrSpam) SwigIsBar() { -} - -func (p SwigcptrSpam) SwigGetBar() Bar { - return SwigcptrBar(p.Swigcptr()) -} - -func (p SwigcptrSpam) SwigIsFoo() { -} - -func (p SwigcptrSpam) SwigGetFoo() Foo { - return SwigcptrFoo(p.Swigcptr()) -} - -var _wrap_spam_SwigGetBaz unsafe.Pointer - -func _swig_wrap_spam_SwigGetBaz(base SwigcptrSpam) (_ SwigcptrBaz) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_spam_SwigGetBaz, _swig_p) - return -} - -func (arg1 SwigcptrSpam) SwigGetBaz() (_swig_ret Baz) { - return _swig_wrap_spam_SwigGetBaz(arg1) -} - -type Spam interface { - Swigcptr() uintptr - SwigIsSpam() - SwigIsBar() - SwigGetBar() Bar - SwigIsFoo() - SwigGetFoo() Foo - SwigGetBaz() (_swig_ret Baz) -} - -var _wrap_test unsafe.Pointer - -func _swig_wrap_test(base uintptr) (_ SwigcptrFoo) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_test, _swig_p) - return -} - -func Test(arg1 Foo) (_swig_ret Foo) { - return _swig_wrap_test(arg1.Swigcptr()) -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/evil_diamond_ns.go b/Examples/test-suite/go/evil_diamond_ns.go deleted file mode 100644 index eb60a0842..000000000 --- a/Examples/test-suite/go/evil_diamond_ns.go +++ /dev/null @@ -1,250 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../evil_diamond_ns.i - -package evil_diamond_ns - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrFoo uintptr - -func (p SwigcptrFoo) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrFoo) SwigIsFoo() { -} - -var _wrap_new_foo unsafe.Pointer - -func _swig_wrap_new_foo() (base SwigcptrFoo) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_foo, _swig_p) - return -} - -func NewFoo() (_swig_ret Foo) { - return _swig_wrap_new_foo() -} - -var _wrap_delete_foo unsafe.Pointer - -func _swig_wrap_delete_foo(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_foo, _swig_p) - return -} - -func DeleteFoo(arg1 Foo) { - _swig_wrap_delete_foo(arg1.Swigcptr()) -} - -type Foo interface { - Swigcptr() uintptr - SwigIsFoo() -} - -type SwigcptrBar uintptr - -func (p SwigcptrBar) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrBar) SwigIsBar() { -} - -var _wrap_new_bar unsafe.Pointer - -func _swig_wrap_new_bar() (base SwigcptrBar) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_bar, _swig_p) - return -} - -func NewBar() (_swig_ret Bar) { - return _swig_wrap_new_bar() -} - -var _wrap_delete_bar unsafe.Pointer - -func _swig_wrap_delete_bar(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_bar, _swig_p) - return -} - -func DeleteBar(arg1 Bar) { - _swig_wrap_delete_bar(arg1.Swigcptr()) -} - -func (p SwigcptrBar) SwigIsFoo() { -} - -func (p SwigcptrBar) SwigGetFoo() Foo { - return SwigcptrFoo(p.Swigcptr()) -} - -type Bar interface { - Swigcptr() uintptr - SwigIsBar() - SwigIsFoo() - SwigGetFoo() Foo -} - -type SwigcptrBaz uintptr - -func (p SwigcptrBaz) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrBaz) SwigIsBaz() { -} - -var _wrap_new_baz unsafe.Pointer - -func _swig_wrap_new_baz() (base SwigcptrBaz) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_baz, _swig_p) - return -} - -func NewBaz() (_swig_ret Baz) { - return _swig_wrap_new_baz() -} - -var _wrap_delete_baz unsafe.Pointer - -func _swig_wrap_delete_baz(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_baz, _swig_p) - return -} - -func DeleteBaz(arg1 Baz) { - _swig_wrap_delete_baz(arg1.Swigcptr()) -} - -func (p SwigcptrBaz) SwigIsFoo() { -} - -func (p SwigcptrBaz) SwigGetFoo() Foo { - return SwigcptrFoo(p.Swigcptr()) -} - -type Baz interface { - Swigcptr() uintptr - SwigIsBaz() - SwigIsFoo() - SwigGetFoo() Foo -} - -type SwigcptrSpam uintptr - -func (p SwigcptrSpam) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrSpam) SwigIsSpam() { -} - -var _wrap_new_spam unsafe.Pointer - -func _swig_wrap_new_spam() (base SwigcptrSpam) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_spam, _swig_p) - return -} - -func NewSpam() (_swig_ret Spam) { - return _swig_wrap_new_spam() -} - -var _wrap_delete_spam unsafe.Pointer - -func _swig_wrap_delete_spam(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_spam, _swig_p) - return -} - -func DeleteSpam(arg1 Spam) { - _swig_wrap_delete_spam(arg1.Swigcptr()) -} - -func (p SwigcptrSpam) SwigIsBar() { -} - -func (p SwigcptrSpam) SwigGetBar() Bar { - return SwigcptrBar(p.Swigcptr()) -} - -func (p SwigcptrSpam) SwigIsFoo() { -} - -func (p SwigcptrSpam) SwigGetFoo() Foo { - return SwigcptrFoo(p.Swigcptr()) -} - -var _wrap_spam_SwigGetBaz unsafe.Pointer - -func _swig_wrap_spam_SwigGetBaz(base SwigcptrSpam) (_ SwigcptrBaz) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_spam_SwigGetBaz, _swig_p) - return -} - -func (arg1 SwigcptrSpam) SwigGetBaz() (_swig_ret Baz) { - return _swig_wrap_spam_SwigGetBaz(arg1) -} - -type Spam interface { - Swigcptr() uintptr - SwigIsSpam() - SwigIsBar() - SwigGetBar() Bar - SwigIsFoo() - SwigGetFoo() Foo - SwigGetBaz() (_swig_ret Baz) -} - -var _wrap_test unsafe.Pointer - -func _swig_wrap_test(base uintptr) (_ SwigcptrFoo) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_test, _swig_p) - return -} - -func Test(arg1 Foo) (_swig_ret Foo) { - return _swig_wrap_test(arg1.Swigcptr()) -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/evil_diamond_prop.go b/Examples/test-suite/go/evil_diamond_prop.go deleted file mode 100644 index def449b0a..000000000 --- a/Examples/test-suite/go/evil_diamond_prop.go +++ /dev/null @@ -1,484 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../evil_diamond_prop.i - -package evil_diamond_prop - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrFoo uintptr - -func (p SwigcptrFoo) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrFoo) SwigIsFoo() { -} - -var _wrap_foo__foo_set unsafe.Pointer - -func _swig_wrap_foo__foo_set(base SwigcptrFoo, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_foo__foo_set, _swig_p) - return -} - -func (arg1 SwigcptrFoo) SetX_foo(arg2 int) { - _swig_wrap_foo__foo_set(arg1, arg2) -} - -var _wrap_foo__foo_get unsafe.Pointer - -func _swig_wrap_foo__foo_get(base SwigcptrFoo) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_foo__foo_get, _swig_p) - return -} - -func (arg1 SwigcptrFoo) GetX_foo() (_swig_ret int) { - return _swig_wrap_foo__foo_get(arg1) -} - -var _wrap_new_foo unsafe.Pointer - -func _swig_wrap_new_foo() (base SwigcptrFoo) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_foo, _swig_p) - return -} - -func NewFoo() (_swig_ret Foo) { - return _swig_wrap_new_foo() -} - -var _wrap_delete_foo unsafe.Pointer - -func _swig_wrap_delete_foo(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_foo, _swig_p) - return -} - -func DeleteFoo(arg1 Foo) { - _swig_wrap_delete_foo(arg1.Swigcptr()) -} - -type Foo interface { - Swigcptr() uintptr - SwigIsFoo() - SetX_foo(arg2 int) - GetX_foo() (_swig_ret int) -} - -type SwigcptrBar uintptr - -func (p SwigcptrBar) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrBar) SwigIsBar() { -} - -var _wrap_bar__bar_set unsafe.Pointer - -func _swig_wrap_bar__bar_set(base SwigcptrBar, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_bar__bar_set, _swig_p) - return -} - -func (arg1 SwigcptrBar) SetX_bar(arg2 int) { - _swig_wrap_bar__bar_set(arg1, arg2) -} - -var _wrap_bar__bar_get unsafe.Pointer - -func _swig_wrap_bar__bar_get(base SwigcptrBar) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_bar__bar_get, _swig_p) - return -} - -func (arg1 SwigcptrBar) GetX_bar() (_swig_ret int) { - return _swig_wrap_bar__bar_get(arg1) -} - -var _wrap_new_bar unsafe.Pointer - -func _swig_wrap_new_bar() (base SwigcptrBar) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_bar, _swig_p) - return -} - -func NewBar() (_swig_ret Bar) { - return _swig_wrap_new_bar() -} - -var _wrap_delete_bar unsafe.Pointer - -func _swig_wrap_delete_bar(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_bar, _swig_p) - return -} - -func DeleteBar(arg1 Bar) { - _swig_wrap_delete_bar(arg1.Swigcptr()) -} - -var _wrap_Setbar_X_foo unsafe.Pointer - -func _swig_wrap_Setbar_X_foo(base SwigcptrBar, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Setbar_X_foo, _swig_p) - return -} - -func (_swig_base SwigcptrBar) SetX_foo(arg1 int) { - _swig_wrap_Setbar_X_foo(_swig_base, arg1) -} - -var _wrap_Getbar_X_foo unsafe.Pointer - -func _swig_wrap_Getbar_X_foo(base SwigcptrBar) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Getbar_X_foo, _swig_p) - return -} - -func (_swig_base SwigcptrBar) GetX_foo() (_swig_ret int) { - return _swig_wrap_Getbar_X_foo(_swig_base) -} - -func (p SwigcptrBar) SwigIsFoo() { -} - -func (p SwigcptrBar) SwigGetFoo() Foo { - return SwigcptrFoo(p.Swigcptr()) -} - -type Bar interface { - Swigcptr() uintptr - SwigIsBar() - SetX_bar(arg2 int) - GetX_bar() (_swig_ret int) - SetX_foo(arg1 int) - GetX_foo() (_swig_ret int) - SwigIsFoo() - SwigGetFoo() Foo -} - -type SwigcptrBaz uintptr - -func (p SwigcptrBaz) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrBaz) SwigIsBaz() { -} - -var _wrap_baz__baz_set unsafe.Pointer - -func _swig_wrap_baz__baz_set(base SwigcptrBaz, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_baz__baz_set, _swig_p) - return -} - -func (arg1 SwigcptrBaz) SetX_baz(arg2 int) { - _swig_wrap_baz__baz_set(arg1, arg2) -} - -var _wrap_baz__baz_get unsafe.Pointer - -func _swig_wrap_baz__baz_get(base SwigcptrBaz) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_baz__baz_get, _swig_p) - return -} - -func (arg1 SwigcptrBaz) GetX_baz() (_swig_ret int) { - return _swig_wrap_baz__baz_get(arg1) -} - -var _wrap_new_baz unsafe.Pointer - -func _swig_wrap_new_baz() (base SwigcptrBaz) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_baz, _swig_p) - return -} - -func NewBaz() (_swig_ret Baz) { - return _swig_wrap_new_baz() -} - -var _wrap_delete_baz unsafe.Pointer - -func _swig_wrap_delete_baz(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_baz, _swig_p) - return -} - -func DeleteBaz(arg1 Baz) { - _swig_wrap_delete_baz(arg1.Swigcptr()) -} - -var _wrap_Setbaz_X_foo unsafe.Pointer - -func _swig_wrap_Setbaz_X_foo(base SwigcptrBaz, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Setbaz_X_foo, _swig_p) - return -} - -func (_swig_base SwigcptrBaz) SetX_foo(arg1 int) { - _swig_wrap_Setbaz_X_foo(_swig_base, arg1) -} - -var _wrap_Getbaz_X_foo unsafe.Pointer - -func _swig_wrap_Getbaz_X_foo(base SwigcptrBaz) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Getbaz_X_foo, _swig_p) - return -} - -func (_swig_base SwigcptrBaz) GetX_foo() (_swig_ret int) { - return _swig_wrap_Getbaz_X_foo(_swig_base) -} - -func (p SwigcptrBaz) SwigIsFoo() { -} - -func (p SwigcptrBaz) SwigGetFoo() Foo { - return SwigcptrFoo(p.Swigcptr()) -} - -type Baz interface { - Swigcptr() uintptr - SwigIsBaz() - SetX_baz(arg2 int) - GetX_baz() (_swig_ret int) - SetX_foo(arg1 int) - GetX_foo() (_swig_ret int) - SwigIsFoo() - SwigGetFoo() Foo -} - -type SwigcptrSpam uintptr - -func (p SwigcptrSpam) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrSpam) SwigIsSpam() { -} - -var _wrap_spam__spam_set unsafe.Pointer - -func _swig_wrap_spam__spam_set(base SwigcptrSpam, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_spam__spam_set, _swig_p) - return -} - -func (arg1 SwigcptrSpam) SetX_spam(arg2 int) { - _swig_wrap_spam__spam_set(arg1, arg2) -} - -var _wrap_spam__spam_get unsafe.Pointer - -func _swig_wrap_spam__spam_get(base SwigcptrSpam) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_spam__spam_get, _swig_p) - return -} - -func (arg1 SwigcptrSpam) GetX_spam() (_swig_ret int) { - return _swig_wrap_spam__spam_get(arg1) -} - -var _wrap_new_spam unsafe.Pointer - -func _swig_wrap_new_spam() (base SwigcptrSpam) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_spam, _swig_p) - return -} - -func NewSpam() (_swig_ret Spam) { - return _swig_wrap_new_spam() -} - -var _wrap_delete_spam unsafe.Pointer - -func _swig_wrap_delete_spam(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_spam, _swig_p) - return -} - -func DeleteSpam(arg1 Spam) { - _swig_wrap_delete_spam(arg1.Swigcptr()) -} - -var _wrap_Setspam_X_bar unsafe.Pointer - -func _swig_wrap_Setspam_X_bar(base SwigcptrSpam, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Setspam_X_bar, _swig_p) - return -} - -func (_swig_base SwigcptrSpam) SetX_bar(arg1 int) { - _swig_wrap_Setspam_X_bar(_swig_base, arg1) -} - -var _wrap_Getspam_X_bar unsafe.Pointer - -func _swig_wrap_Getspam_X_bar(base SwigcptrSpam) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Getspam_X_bar, _swig_p) - return -} - -func (_swig_base SwigcptrSpam) GetX_bar() (_swig_ret int) { - return _swig_wrap_Getspam_X_bar(_swig_base) -} - -var _wrap_Setspam_X_foo unsafe.Pointer - -func _swig_wrap_Setspam_X_foo(base SwigcptrSpam, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Setspam_X_foo, _swig_p) - return -} - -func (_swig_base SwigcptrSpam) SetX_foo(arg1 int) { - _swig_wrap_Setspam_X_foo(_swig_base, arg1) -} - -var _wrap_Getspam_X_foo unsafe.Pointer - -func _swig_wrap_Getspam_X_foo(base SwigcptrSpam) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Getspam_X_foo, _swig_p) - return -} - -func (_swig_base SwigcptrSpam) GetX_foo() (_swig_ret int) { - return _swig_wrap_Getspam_X_foo(_swig_base) -} - -var _wrap_Setspam_X_baz unsafe.Pointer - -func _swig_wrap_Setspam_X_baz(base SwigcptrSpam, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Setspam_X_baz, _swig_p) - return -} - -func (_swig_base SwigcptrSpam) SetX_baz(arg1 int) { - _swig_wrap_Setspam_X_baz(_swig_base, arg1) -} - -var _wrap_Getspam_X_baz unsafe.Pointer - -func _swig_wrap_Getspam_X_baz(base SwigcptrSpam) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Getspam_X_baz, _swig_p) - return -} - -func (_swig_base SwigcptrSpam) GetX_baz() (_swig_ret int) { - return _swig_wrap_Getspam_X_baz(_swig_base) -} - -func (p SwigcptrSpam) SwigIsBar() { -} - -func (p SwigcptrSpam) SwigGetBar() Bar { - return SwigcptrBar(p.Swigcptr()) -} - -func (p SwigcptrSpam) SwigIsFoo() { -} - -func (p SwigcptrSpam) SwigGetFoo() Foo { - return SwigcptrFoo(p.Swigcptr()) -} - -var _wrap_spam_SwigGetBaz unsafe.Pointer - -func _swig_wrap_spam_SwigGetBaz(base SwigcptrSpam) (_ SwigcptrBaz) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_spam_SwigGetBaz, _swig_p) - return -} - -func (arg1 SwigcptrSpam) SwigGetBaz() (_swig_ret Baz) { - return _swig_wrap_spam_SwigGetBaz(arg1) -} - -type Spam interface { - Swigcptr() uintptr - SwigIsSpam() - SetX_spam(arg2 int) - GetX_spam() (_swig_ret int) - SetX_bar(arg1 int) - GetX_bar() (_swig_ret int) - SetX_foo(arg1 int) - GetX_foo() (_swig_ret int) - SetX_baz(arg1 int) - GetX_baz() (_swig_ret int) - SwigIsBar() - SwigGetBar() Bar - SwigIsFoo() - SwigGetFoo() Foo - SwigGetBaz() (_swig_ret Baz) -} - -var _wrap_test unsafe.Pointer - -func _swig_wrap_test(base uintptr) (_ SwigcptrFoo) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_test, _swig_p) - return -} - -func Test(arg1 Foo) (_swig_ret Foo) { - return _swig_wrap_test(arg1.Swigcptr()) -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/exception_order.go b/Examples/test-suite/go/exception_order.go deleted file mode 100644 index dcf7a81cd..000000000 --- a/Examples/test-suite/go/exception_order.go +++ /dev/null @@ -1,441 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../exception_order.i - -package exception_order - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -var _wrap_efoovar_set unsafe.Pointer - -func _swig_wrap_efoovar_set(base int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_efoovar_set, _swig_p) - return -} - -func SetEfoovar(arg1 int) { - _swig_wrap_efoovar_set(arg1) -} - -var _wrap_efoovar_get unsafe.Pointer - -func GetEfoovar() (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_efoovar_get, _swig_p) - return -} -var _wrap_foovar_set unsafe.Pointer - -func _swig_wrap_foovar_set(base int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_foovar_set, _swig_p) - return -} - -func SetFoovar(arg1 int) { - _swig_wrap_foovar_set(arg1) -} - -var _wrap_foovar_get unsafe.Pointer - -func GetFoovar() (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_foovar_get, _swig_p) - return -} -var _wrap_cfoovar_get unsafe.Pointer - -func GetCfoovar() (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_cfoovar_get, _swig_p) - return -} -type SwigcptrE1 uintptr - -func (p SwigcptrE1) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrE1) SwigIsE1() { -} - -var _wrap_new_E1 unsafe.Pointer - -func _swig_wrap_new_E1() (base SwigcptrE1) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_E1, _swig_p) - return -} - -func NewE1() (_swig_ret E1) { - return _swig_wrap_new_E1() -} - -var _wrap_delete_E1 unsafe.Pointer - -func _swig_wrap_delete_E1(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_E1, _swig_p) - return -} - -func DeleteE1(arg1 E1) { - _swig_wrap_delete_E1(arg1.Swigcptr()) -} - -type E1 interface { - Swigcptr() uintptr - SwigIsE1() -} - -type SwigcptrE2 uintptr - -func (p SwigcptrE2) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrE2) SwigIsE2() { -} - -var _wrap_new_E2 unsafe.Pointer - -func _swig_wrap_new_E2() (base SwigcptrE2) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_E2, _swig_p) - return -} - -func NewE2() (_swig_ret E2) { - return _swig_wrap_new_E2() -} - -var _wrap_delete_E2 unsafe.Pointer - -func _swig_wrap_delete_E2(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_E2, _swig_p) - return -} - -func DeleteE2(arg1 E2) { - _swig_wrap_delete_E2(arg1.Swigcptr()) -} - -type E2 interface { - Swigcptr() uintptr - SwigIsE2() -} - -type SwigcptrE3 uintptr - -func (p SwigcptrE3) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrE3) SwigIsE3() { -} - -var _wrap_new_E3 unsafe.Pointer - -func _swig_wrap_new_E3() (base SwigcptrE3) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_E3, _swig_p) - return -} - -func NewE3() (_swig_ret E3) { - return _swig_wrap_new_E3() -} - -var _wrap_delete_E3 unsafe.Pointer - -func _swig_wrap_delete_E3(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_E3, _swig_p) - return -} - -func DeleteE3(arg1 E3) { - _swig_wrap_delete_E3(arg1.Swigcptr()) -} - -type E3 interface { - Swigcptr() uintptr - SwigIsE3() -} - -type SwigcptrA uintptr - -func (p SwigcptrA) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrA) SwigIsA() { -} - -var _wrap_A_sfoovar_set unsafe.Pointer - -func _swig_wrap_A_sfoovar_set(base int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_A_sfoovar_set, _swig_p) - return -} - -func SetASfoovar(arg1 int) { - _swig_wrap_A_sfoovar_set(arg1) -} - -var _wrap_A_sfoovar_get unsafe.Pointer - -func GetASfoovar() (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_A_sfoovar_get, _swig_p) - return -} -var _wrap_A_CSFOOVAR_A unsafe.Pointer - -func _swig_getA_A_CSFOOVAR_A() (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_A_CSFOOVAR_A, _swig_p) - return -} -var ACSFOOVAR int = _swig_getA_A_CSFOOVAR_A() -var _wrap_A_foovar_set unsafe.Pointer - -func _swig_wrap_A_foovar_set(base SwigcptrA, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_A_foovar_set, _swig_p) - return -} - -func (arg1 SwigcptrA) SetFoovar(arg2 int) { - _swig_wrap_A_foovar_set(arg1, arg2) -} - -var _wrap_A_foovar_get unsafe.Pointer - -func _swig_wrap_A_foovar_get(base SwigcptrA) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_A_foovar_get, _swig_p) - return -} - -func (arg1 SwigcptrA) GetFoovar() (_swig_ret int) { - return _swig_wrap_A_foovar_get(arg1) -} - -var _wrap_A_efoovar_set unsafe.Pointer - -func _swig_wrap_A_efoovar_set(base SwigcptrA, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_A_efoovar_set, _swig_p) - return -} - -func (arg1 SwigcptrA) SetEfoovar(arg2 int) { - _swig_wrap_A_efoovar_set(arg1, arg2) -} - -var _wrap_A_efoovar_get unsafe.Pointer - -func _swig_wrap_A_efoovar_get(base SwigcptrA) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_A_efoovar_get, _swig_p) - return -} - -func (arg1 SwigcptrA) GetEfoovar() (_swig_ret int) { - return _swig_wrap_A_efoovar_get(arg1) -} - -var _wrap_A_foo unsafe.Pointer - -func _swig_wrap_A_foo(base SwigcptrA) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_A_foo, _swig_p) - return -} - -func (arg1 SwigcptrA) Foo() (_swig_ret int) { - return _swig_wrap_A_foo(arg1) -} - -var _wrap_A_bar unsafe.Pointer - -func _swig_wrap_A_bar(base SwigcptrA) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_A_bar, _swig_p) - return -} - -func (arg1 SwigcptrA) Bar() (_swig_ret int) { - return _swig_wrap_A_bar(arg1) -} - -var _wrap_A_foobar unsafe.Pointer - -func _swig_wrap_A_foobar(base SwigcptrA) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_A_foobar, _swig_p) - return -} - -func (arg1 SwigcptrA) Foobar() (_swig_ret int) { - return _swig_wrap_A_foobar(arg1) -} - -var _wrap_A_barfoo unsafe.Pointer - -func _swig_wrap_A_barfoo(base SwigcptrA, _ int) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_A_barfoo, _swig_p) - return -} - -func (arg1 SwigcptrA) Barfoo(arg2 int) (_swig_ret int) { - return _swig_wrap_A_barfoo(arg1, arg2) -} - -var _wrap_new_A unsafe.Pointer - -func _swig_wrap_new_A() (base SwigcptrA) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_A, _swig_p) - return -} - -func NewA() (_swig_ret A) { - return _swig_wrap_new_A() -} - -var _wrap_delete_A unsafe.Pointer - -func _swig_wrap_delete_A(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_A, _swig_p) - return -} - -func DeleteA(arg1 A) { - _swig_wrap_delete_A(arg1.Swigcptr()) -} - -type A interface { - Swigcptr() uintptr - SwigIsA() - SetFoovar(arg2 int) - GetFoovar() (_swig_ret int) - SetEfoovar(arg2 int) - GetEfoovar() (_swig_ret int) - Foo() (_swig_ret int) - Bar() (_swig_ret int) - Foobar() (_swig_ret int) - Barfoo(arg2 int) (_swig_ret int) -} - -type SwigcptrET_i uintptr - -func (p SwigcptrET_i) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrET_i) SwigIsET_i() { -} - -var _wrap_new_ET_i unsafe.Pointer - -func _swig_wrap_new_ET_i() (base SwigcptrET_i) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_ET_i, _swig_p) - return -} - -func NewET_i() (_swig_ret ET_i) { - return _swig_wrap_new_ET_i() -} - -var _wrap_delete_ET_i unsafe.Pointer - -func _swig_wrap_delete_ET_i(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_ET_i, _swig_p) - return -} - -func DeleteET_i(arg1 ET_i) { - _swig_wrap_delete_ET_i(arg1.Swigcptr()) -} - -type ET_i interface { - Swigcptr() uintptr - SwigIsET_i() -} - -type SwigcptrET_d uintptr - -func (p SwigcptrET_d) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrET_d) SwigIsET_d() { -} - -var _wrap_new_ET_d unsafe.Pointer - -func _swig_wrap_new_ET_d() (base SwigcptrET_d) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_ET_d, _swig_p) - return -} - -func NewET_d() (_swig_ret ET_d) { - return _swig_wrap_new_ET_d() -} - -var _wrap_delete_ET_d unsafe.Pointer - -func _swig_wrap_delete_ET_d(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_ET_d, _swig_p) - return -} - -func DeleteET_d(arg1 ET_d) { - _swig_wrap_delete_ET_d(arg1.Swigcptr()) -} - -type ET_d interface { - Swigcptr() uintptr - SwigIsET_d() -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/exception_order_runme b/Examples/test-suite/go/exception_order_runme deleted file mode 100755 index ef48aef39..000000000 Binary files a/Examples/test-suite/go/exception_order_runme and /dev/null differ diff --git a/Examples/test-suite/go/expressions.go b/Examples/test-suite/go/expressions.go deleted file mode 100644 index c1aa6e46a..000000000 --- a/Examples/test-suite/go/expressions.go +++ /dev/null @@ -1,124 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../expressions.i - -package expressions - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrA uintptr - -func (p SwigcptrA) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrA) SwigIsA() { -} - -var _wrap_new_A__SWIG_0 unsafe.Pointer - -func _swig_wrap_new_A__SWIG_0() (base SwigcptrA) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_A__SWIG_0, _swig_p) - return -} - -func NewA__SWIG_0() (_swig_ret A) { - return _swig_wrap_new_A__SWIG_0() -} - -var _wrap_new_A__SWIG_1 unsafe.Pointer - -func _swig_wrap_new_A__SWIG_1(base int) (_ SwigcptrA) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_A__SWIG_1, _swig_p) - return -} - -func NewA__SWIG_1(arg1 int) (_swig_ret A) { - return _swig_wrap_new_A__SWIG_1(arg1) -} - -func NewA(a ...interface{}) A { - argc := len(a) - if argc == 0 { - return NewA__SWIG_0() - } - if argc == 1 { - return NewA__SWIG_1(a[0].(int)) - } - panic("No match for overloaded function call") -} - -var _wrap_A_k_set unsafe.Pointer - -func _swig_wrap_A_k_set(base SwigcptrA, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_A_k_set, _swig_p) - return -} - -func (arg1 SwigcptrA) SetK(arg2 int) { - _swig_wrap_A_k_set(arg1, arg2) -} - -var _wrap_A_k_get unsafe.Pointer - -func _swig_wrap_A_k_get(base SwigcptrA) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_A_k_get, _swig_p) - return -} - -func (arg1 SwigcptrA) GetK() (_swig_ret int) { - return _swig_wrap_A_k_get(arg1) -} - -var _wrap_delete_A unsafe.Pointer - -func _swig_wrap_delete_A(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_A, _swig_p) - return -} - -func DeleteA(arg1 A) { - _swig_wrap_delete_A(arg1.Swigcptr()) -} - -type A interface { - Swigcptr() uintptr - SwigIsA() - SetK(arg2 int) - GetK() (_swig_ret int) -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/extend.go b/Examples/test-suite/go/extend.go deleted file mode 100644 index 3a5b019af..000000000 --- a/Examples/test-suite/go/extend.go +++ /dev/null @@ -1,308 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../extend.i - -package extend - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrBase uintptr - -func (p SwigcptrBase) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrBase) SwigIsBase() { -} - -var _wrap_new_Base__SWIG_0 unsafe.Pointer - -func _swig_wrap_new_Base__SWIG_0(base int) (_ SwigcptrBase) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Base__SWIG_0, _swig_p) - return -} - -func NewBase__SWIG_0(arg1 int) (_swig_ret Base) { - return _swig_wrap_new_Base__SWIG_0(arg1) -} - -var _wrap_new_Base__SWIG_1 unsafe.Pointer - -func _swig_wrap_new_Base__SWIG_1() (base SwigcptrBase) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Base__SWIG_1, _swig_p) - return -} - -func NewBase__SWIG_1() (_swig_ret Base) { - return _swig_wrap_new_Base__SWIG_1() -} - -func NewBase(a ...interface{}) Base { - argc := len(a) - if argc == 0 { - return NewBase__SWIG_1() - } - if argc == 1 { - return NewBase__SWIG_0(a[0].(int)) - } - panic("No match for overloaded function call") -} - -var _wrap_Base_value_set unsafe.Pointer - -func _swig_wrap_Base_value_set(base SwigcptrBase, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Base_value_set, _swig_p) - return -} - -func (arg1 SwigcptrBase) SetValue(arg2 int) { - _swig_wrap_Base_value_set(arg1, arg2) -} - -var _wrap_Base_value_get unsafe.Pointer - -func _swig_wrap_Base_value_get(base SwigcptrBase) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Base_value_get, _swig_p) - return -} - -func (arg1 SwigcptrBase) GetValue() (_swig_ret int) { - return _swig_wrap_Base_value_get(arg1) -} - -var _wrap_Base_method unsafe.Pointer - -func _swig_wrap_Base_method(base SwigcptrBase, _ int) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Base_method, _swig_p) - return -} - -func (arg1 SwigcptrBase) Method(arg2 int) (_swig_ret int) { - return _swig_wrap_Base_method(arg1, arg2) -} - -var _wrap_delete_Base unsafe.Pointer - -func _swig_wrap_delete_Base(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Base, _swig_p) - return -} - -func DeleteBase(arg1 Base) { - _swig_wrap_delete_Base(arg1.Swigcptr()) -} - -var _wrap_Base_zeroVal unsafe.Pointer - -func BaseZeroVal() (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_Base_zeroVal, _swig_p) - return -} -var _wrap_Base_currentValue unsafe.Pointer - -func _swig_wrap_Base_currentValue(base SwigcptrBase) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Base_currentValue, _swig_p) - return -} - -func (arg1 SwigcptrBase) CurrentValue() (_swig_ret int) { - return _swig_wrap_Base_currentValue(arg1) -} - -var _wrap_Base_extendmethod unsafe.Pointer - -func _swig_wrap_Base_extendmethod(base SwigcptrBase, _ int) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Base_extendmethod, _swig_p) - return -} - -func (arg1 SwigcptrBase) Extendmethod(arg2 int) (_swig_ret int) { - return _swig_wrap_Base_extendmethod(arg1, arg2) -} - -type Base interface { - Swigcptr() uintptr - SwigIsBase() - SetValue(arg2 int) - GetValue() (_swig_ret int) - Method(arg2 int) (_swig_ret int) - CurrentValue() (_swig_ret int) - Extendmethod(arg2 int) (_swig_ret int) -} - -type SwigcptrDerived uintptr - -func (p SwigcptrDerived) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrDerived) SwigIsDerived() { -} - -var _wrap_Derived_actualval_set unsafe.Pointer - -func _swig_wrap_Derived_actualval_set(base SwigcptrDerived, _ float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Derived_actualval_set, _swig_p) - return -} - -func (arg1 SwigcptrDerived) SetActualval(arg2 float64) { - _swig_wrap_Derived_actualval_set(arg1, arg2) -} - -var _wrap_Derived_actualval_get unsafe.Pointer - -func _swig_wrap_Derived_actualval_get(base SwigcptrDerived) (_ float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Derived_actualval_get, _swig_p) - return -} - -func (arg1 SwigcptrDerived) GetActualval() (_swig_ret float64) { - return _swig_wrap_Derived_actualval_get(arg1) -} - -var _wrap_new_Derived unsafe.Pointer - -func _swig_wrap_new_Derived(base int) (_ SwigcptrDerived) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Derived, _swig_p) - return -} - -func NewDerived(arg1 int) (_swig_ret Derived) { - return _swig_wrap_new_Derived(arg1) -} - -var _wrap_Derived_method unsafe.Pointer - -func _swig_wrap_Derived_method(base SwigcptrDerived, _ int) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Derived_method, _swig_p) - return -} - -func (arg1 SwigcptrDerived) Method(arg2 int) (_swig_ret int) { - return _swig_wrap_Derived_method(arg1, arg2) -} - -var _wrap_Derived_extendval_set unsafe.Pointer - -func _swig_wrap_Derived_extendval_set(base SwigcptrDerived, _ float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Derived_extendval_set, _swig_p) - return -} - -func (arg1 SwigcptrDerived) SetExtendval(arg2 float64) { - _swig_wrap_Derived_extendval_set(arg1, arg2) -} - -var _wrap_Derived_extendval_get unsafe.Pointer - -func _swig_wrap_Derived_extendval_get(base SwigcptrDerived) (_ float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Derived_extendval_get, _swig_p) - return -} - -func (arg1 SwigcptrDerived) GetExtendval() (_swig_ret float64) { - return _swig_wrap_Derived_extendval_get(arg1) -} - -var _wrap_delete_Derived unsafe.Pointer - -func _swig_wrap_delete_Derived(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Derived, _swig_p) - return -} - -func DeleteDerived(arg1 Derived) { - _swig_wrap_delete_Derived(arg1.Swigcptr()) -} - -var _wrap_SetDerived_Value unsafe.Pointer - -func _swig_wrap_SetDerived_Value(base SwigcptrDerived, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_SetDerived_Value, _swig_p) - return -} - -func (_swig_base SwigcptrDerived) SetValue(arg1 int) { - _swig_wrap_SetDerived_Value(_swig_base, arg1) -} - -var _wrap_GetDerived_Value unsafe.Pointer - -func _swig_wrap_GetDerived_Value(base SwigcptrDerived) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_GetDerived_Value, _swig_p) - return -} - -func (_swig_base SwigcptrDerived) GetValue() (_swig_ret int) { - return _swig_wrap_GetDerived_Value(_swig_base) -} - -func (p SwigcptrDerived) SwigIsBase() { -} - -func (p SwigcptrDerived) SwigGetBase() Base { - return SwigcptrBase(p.Swigcptr()) -} - -type Derived interface { - Swigcptr() uintptr - SwigIsDerived() - SetActualval(arg2 float64) - GetActualval() (_swig_ret float64) - Method(arg2 int) (_swig_ret int) - SetExtendval(arg2 float64) - GetExtendval() (_swig_ret float64) - SetValue(arg1 int) - GetValue() (_swig_ret int) - SwigIsBase() - SwigGetBase() Base -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/extend_constructor_destructor.go b/Examples/test-suite/go/extend_constructor_destructor.go deleted file mode 100644 index 9d42a0fcd..000000000 --- a/Examples/test-suite/go/extend_constructor_destructor.go +++ /dev/null @@ -1,504 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../extend_constructor_destructor.i - -package extend_constructor_destructor - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -var _wrap_globalVar_set unsafe.Pointer - -func _swig_wrap_globalVar_set(base int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_globalVar_set, _swig_p) - return -} - -func SetGlobalVar(arg1 int) { - _swig_wrap_globalVar_set(arg1) -} - -var _wrap_globalVar_get unsafe.Pointer - -func GetGlobalVar() (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_globalVar_get, _swig_p) - return -} -type SwigcptrAStruct uintptr - -func (p SwigcptrAStruct) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrAStruct) SwigIsAStruct() { -} - -var _wrap_AStruct_ivar_set unsafe.Pointer - -func _swig_wrap_AStruct_ivar_set(base SwigcptrAStruct, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_AStruct_ivar_set, _swig_p) - return -} - -func (arg1 SwigcptrAStruct) SetIvar(arg2 int) { - _swig_wrap_AStruct_ivar_set(arg1, arg2) -} - -var _wrap_AStruct_ivar_get unsafe.Pointer - -func _swig_wrap_AStruct_ivar_get(base SwigcptrAStruct) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_AStruct_ivar_get, _swig_p) - return -} - -func (arg1 SwigcptrAStruct) GetIvar() (_swig_ret int) { - return _swig_wrap_AStruct_ivar_get(arg1) -} - -var _wrap_new_AStruct unsafe.Pointer - -func _swig_wrap_new_AStruct(base int) (_ SwigcptrAStruct) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_AStruct, _swig_p) - return -} - -func NewAStruct(arg1 int) (_swig_ret AStruct) { - return _swig_wrap_new_AStruct(arg1) -} - -var _wrap_delete_AStruct unsafe.Pointer - -func _swig_wrap_delete_AStruct(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_AStruct, _swig_p) - return -} - -func DeleteAStruct(arg1 AStruct) { - _swig_wrap_delete_AStruct(arg1.Swigcptr()) -} - -type AStruct interface { - Swigcptr() uintptr - SwigIsAStruct() - SetIvar(arg2 int) - GetIvar() (_swig_ret int) -} - -type SwigcptrBStruct uintptr - -func (p SwigcptrBStruct) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrBStruct) SwigIsBStruct() { -} - -var _wrap_BStruct_ivar_set unsafe.Pointer - -func _swig_wrap_BStruct_ivar_set(base SwigcptrBStruct, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_BStruct_ivar_set, _swig_p) - return -} - -func (arg1 SwigcptrBStruct) SetIvar(arg2 int) { - _swig_wrap_BStruct_ivar_set(arg1, arg2) -} - -var _wrap_BStruct_ivar_get unsafe.Pointer - -func _swig_wrap_BStruct_ivar_get(base SwigcptrBStruct) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_BStruct_ivar_get, _swig_p) - return -} - -func (arg1 SwigcptrBStruct) GetIvar() (_swig_ret int) { - return _swig_wrap_BStruct_ivar_get(arg1) -} - -var _wrap_new_BStruct unsafe.Pointer - -func _swig_wrap_new_BStruct(base int) (_ SwigcptrBStruct) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_BStruct, _swig_p) - return -} - -func NewBStruct(arg1 int) (_swig_ret BStruct) { - return _swig_wrap_new_BStruct(arg1) -} - -var _wrap_delete_BStruct unsafe.Pointer - -func _swig_wrap_delete_BStruct(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_BStruct, _swig_p) - return -} - -func DeleteBStruct(arg1 BStruct) { - _swig_wrap_delete_BStruct(arg1.Swigcptr()) -} - -type BStruct interface { - Swigcptr() uintptr - SwigIsBStruct() - SetIvar(arg2 int) - GetIvar() (_swig_ret int) -} - -type SwigcptrCStruct uintptr - -func (p SwigcptrCStruct) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrCStruct) SwigIsCStruct() { -} - -var _wrap_CStruct_ivar_set unsafe.Pointer - -func _swig_wrap_CStruct_ivar_set(base SwigcptrCStruct, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_CStruct_ivar_set, _swig_p) - return -} - -func (arg1 SwigcptrCStruct) SetIvar(arg2 int) { - _swig_wrap_CStruct_ivar_set(arg1, arg2) -} - -var _wrap_CStruct_ivar_get unsafe.Pointer - -func _swig_wrap_CStruct_ivar_get(base SwigcptrCStruct) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_CStruct_ivar_get, _swig_p) - return -} - -func (arg1 SwigcptrCStruct) GetIvar() (_swig_ret int) { - return _swig_wrap_CStruct_ivar_get(arg1) -} - -var _wrap_new_CStruct unsafe.Pointer - -func _swig_wrap_new_CStruct(base int) (_ SwigcptrCStruct) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_CStruct, _swig_p) - return -} - -func NewCStruct(arg1 int) (_swig_ret CStruct) { - return _swig_wrap_new_CStruct(arg1) -} - -var _wrap_delete_CStruct unsafe.Pointer - -func _swig_wrap_delete_CStruct(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_CStruct, _swig_p) - return -} - -func DeleteCStruct(arg1 CStruct) { - _swig_wrap_delete_CStruct(arg1.Swigcptr()) -} - -type CStruct interface { - Swigcptr() uintptr - SwigIsCStruct() - SetIvar(arg2 int) - GetIvar() (_swig_ret int) -} - -type SwigcptrDStruct uintptr - -func (p SwigcptrDStruct) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrDStruct) SwigIsDStruct() { -} - -var _wrap_DStruct_ivar_set unsafe.Pointer - -func _swig_wrap_DStruct_ivar_set(base SwigcptrDStruct, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_DStruct_ivar_set, _swig_p) - return -} - -func (arg1 SwigcptrDStruct) SetIvar(arg2 int) { - _swig_wrap_DStruct_ivar_set(arg1, arg2) -} - -var _wrap_DStruct_ivar_get unsafe.Pointer - -func _swig_wrap_DStruct_ivar_get(base SwigcptrDStruct) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_DStruct_ivar_get, _swig_p) - return -} - -func (arg1 SwigcptrDStruct) GetIvar() (_swig_ret int) { - return _swig_wrap_DStruct_ivar_get(arg1) -} - -var _wrap_new_DStruct unsafe.Pointer - -func _swig_wrap_new_DStruct(base int) (_ SwigcptrDStruct) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_DStruct, _swig_p) - return -} - -func NewDStruct(arg1 int) (_swig_ret DStruct) { - return _swig_wrap_new_DStruct(arg1) -} - -var _wrap_delete_DStruct unsafe.Pointer - -func _swig_wrap_delete_DStruct(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_DStruct, _swig_p) - return -} - -func DeleteDStruct(arg1 DStruct) { - _swig_wrap_delete_DStruct(arg1.Swigcptr()) -} - -type DStruct interface { - Swigcptr() uintptr - SwigIsDStruct() - SetIvar(arg2 int) - GetIvar() (_swig_ret int) -} - -type SwigcptrEStruct uintptr - -func (p SwigcptrEStruct) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrEStruct) SwigIsEStruct() { -} - -var _wrap_EStruct_ivar_set unsafe.Pointer - -func _swig_wrap_EStruct_ivar_set(base SwigcptrEStruct, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_EStruct_ivar_set, _swig_p) - return -} - -func (arg1 SwigcptrEStruct) SetIvar(arg2 int) { - _swig_wrap_EStruct_ivar_set(arg1, arg2) -} - -var _wrap_EStruct_ivar_get unsafe.Pointer - -func _swig_wrap_EStruct_ivar_get(base SwigcptrEStruct) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_EStruct_ivar_get, _swig_p) - return -} - -func (arg1 SwigcptrEStruct) GetIvar() (_swig_ret int) { - return _swig_wrap_EStruct_ivar_get(arg1) -} - -var _wrap_new_EStruct unsafe.Pointer - -func _swig_wrap_new_EStruct(base int) (_ SwigcptrEStruct) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_EStruct, _swig_p) - return -} - -func NewEStruct(arg1 int) (_swig_ret EStruct) { - return _swig_wrap_new_EStruct(arg1) -} - -var _wrap_delete_EStruct unsafe.Pointer - -func _swig_wrap_delete_EStruct(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_EStruct, _swig_p) - return -} - -func DeleteEStruct(arg1 EStruct) { - _swig_wrap_delete_EStruct(arg1.Swigcptr()) -} - -type EStruct interface { - Swigcptr() uintptr - SwigIsEStruct() - SetIvar(arg2 int) - GetIvar() (_swig_ret int) -} - -type SwigcptrFStruct uintptr - -func (p SwigcptrFStruct) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrFStruct) SwigIsFStruct() { -} - -var _wrap_FStruct_ivar_set unsafe.Pointer - -func _swig_wrap_FStruct_ivar_set(base SwigcptrFStruct, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_FStruct_ivar_set, _swig_p) - return -} - -func (arg1 SwigcptrFStruct) SetIvar(arg2 int) { - _swig_wrap_FStruct_ivar_set(arg1, arg2) -} - -var _wrap_FStruct_ivar_get unsafe.Pointer - -func _swig_wrap_FStruct_ivar_get(base SwigcptrFStruct) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_FStruct_ivar_get, _swig_p) - return -} - -func (arg1 SwigcptrFStruct) GetIvar() (_swig_ret int) { - return _swig_wrap_FStruct_ivar_get(arg1) -} - -var _wrap_new_FStruct unsafe.Pointer - -func _swig_wrap_new_FStruct(base int) (_ SwigcptrFStruct) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_FStruct, _swig_p) - return -} - -func NewFStruct(arg1 int) (_swig_ret FStruct) { - return _swig_wrap_new_FStruct(arg1) -} - -var _wrap_delete_FStruct unsafe.Pointer - -func _swig_wrap_delete_FStruct(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_FStruct, _swig_p) - return -} - -func DeleteFStruct(arg1 FStruct) { - _swig_wrap_delete_FStruct(arg1.Swigcptr()) -} - -type FStruct interface { - Swigcptr() uintptr - SwigIsFStruct() - SetIvar(arg2 int) - GetIvar() (_swig_ret int) -} - -type SwigcptrGStruct uintptr - -func (p SwigcptrGStruct) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrGStruct) SwigIsGStruct() { -} - -var _wrap_GStruct_ivar_set unsafe.Pointer - -func _swig_wrap_GStruct_ivar_set(base SwigcptrGStruct, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_GStruct_ivar_set, _swig_p) - return -} - -func (arg1 SwigcptrGStruct) SetIvar(arg2 int) { - _swig_wrap_GStruct_ivar_set(arg1, arg2) -} - -var _wrap_GStruct_ivar_get unsafe.Pointer - -func _swig_wrap_GStruct_ivar_get(base SwigcptrGStruct) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_GStruct_ivar_get, _swig_p) - return -} - -func (arg1 SwigcptrGStruct) GetIvar() (_swig_ret int) { - return _swig_wrap_GStruct_ivar_get(arg1) -} - -var _wrap_new_GStruct unsafe.Pointer - -func _swig_wrap_new_GStruct(base int) (_ SwigcptrGStruct) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_GStruct, _swig_p) - return -} - -func NewGStruct(arg1 int) (_swig_ret GStruct) { - return _swig_wrap_new_GStruct(arg1) -} - -var _wrap_delete_GStruct unsafe.Pointer - -func _swig_wrap_delete_GStruct(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_GStruct, _swig_p) - return -} - -func DeleteGStruct(arg1 GStruct) { - _swig_wrap_delete_GStruct(arg1.Swigcptr()) -} - -type GStruct interface { - Swigcptr() uintptr - SwigIsGStruct() - SetIvar(arg2 int) - GetIvar() (_swig_ret int) -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/extend_default.go b/Examples/test-suite/go/extend_default.go deleted file mode 100644 index 9b25ff800..000000000 --- a/Examples/test-suite/go/extend_default.go +++ /dev/null @@ -1,1696 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../extend_default.i - -package extend_default - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrBefore uintptr - -func (p SwigcptrBefore) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrBefore) SwigIsBefore() { -} - -var _wrap_Before_d_set unsafe.Pointer - -func _swig_wrap_Before_d_set(base SwigcptrBefore, _ float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Before_d_set, _swig_p) - return -} - -func (arg1 SwigcptrBefore) SetD(arg2 float64) { - _swig_wrap_Before_d_set(arg1, arg2) -} - -var _wrap_Before_d_get unsafe.Pointer - -func _swig_wrap_Before_d_get(base SwigcptrBefore) (_ float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Before_d_get, _swig_p) - return -} - -func (arg1 SwigcptrBefore) GetD() (_swig_ret float64) { - return _swig_wrap_Before_d_get(arg1) -} - -var _wrap_Before_i_set unsafe.Pointer - -func _swig_wrap_Before_i_set(base SwigcptrBefore, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Before_i_set, _swig_p) - return -} - -func (arg1 SwigcptrBefore) SetI(arg2 int) { - _swig_wrap_Before_i_set(arg1, arg2) -} - -var _wrap_Before_i_get unsafe.Pointer - -func _swig_wrap_Before_i_get(base SwigcptrBefore) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Before_i_get, _swig_p) - return -} - -func (arg1 SwigcptrBefore) GetI() (_swig_ret int) { - return _swig_wrap_Before_i_get(arg1) -} - -var _wrap_new_Before__SWIG_0 unsafe.Pointer - -func _swig_wrap_new_Before__SWIG_0(base int, _ float64) (_ SwigcptrBefore) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Before__SWIG_0, _swig_p) - return -} - -func NewBefore__SWIG_0(arg1 int, arg2 float64) (_swig_ret Before) { - return _swig_wrap_new_Before__SWIG_0(arg1, arg2) -} - -var _wrap_new_Before__SWIG_1 unsafe.Pointer - -func _swig_wrap_new_Before__SWIG_1(base int) (_ SwigcptrBefore) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Before__SWIG_1, _swig_p) - return -} - -func NewBefore__SWIG_1(arg1 int) (_swig_ret Before) { - return _swig_wrap_new_Before__SWIG_1(arg1) -} - -var _wrap_new_Before__SWIG_2 unsafe.Pointer - -func _swig_wrap_new_Before__SWIG_2() (base SwigcptrBefore) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Before__SWIG_2, _swig_p) - return -} - -func NewBefore__SWIG_2() (_swig_ret Before) { - return _swig_wrap_new_Before__SWIG_2() -} - -func NewBefore(a ...interface{}) Before { - argc := len(a) - if argc == 0 { - return NewBefore__SWIG_2() - } - if argc == 1 { - return NewBefore__SWIG_1(a[0].(int)) - } - if argc == 2 { - return NewBefore__SWIG_0(a[0].(int), a[1].(float64)) - } - panic("No match for overloaded function call") -} - -var _wrap_Before_AddedStaticMethod__SWIG_0 unsafe.Pointer - -func BeforeAddedStaticMethod__SWIG_0(arg1 int, arg2 float64) (_swig_ret float64) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_Before_AddedStaticMethod__SWIG_0, _swig_p) - return -} -var _wrap_Before_AddedStaticMethod__SWIG_1 unsafe.Pointer - -func BeforeAddedStaticMethod__SWIG_1(arg1 int) (_swig_ret float64) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_Before_AddedStaticMethod__SWIG_1, _swig_p) - return -} -var _wrap_Before_AddedStaticMethod__SWIG_2 unsafe.Pointer - -func BeforeAddedStaticMethod__SWIG_2() (_swig_ret float64) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_Before_AddedStaticMethod__SWIG_2, _swig_p) - return -} -func BeforeAddedStaticMethod(a ...interface{}) float64 { - argc := len(a) - if argc == 0 { - return BeforeAddedStaticMethod__SWIG_2() - } - if argc == 1 { - return BeforeAddedStaticMethod__SWIG_1(a[0].(int)) - } - if argc == 2 { - return BeforeAddedStaticMethod__SWIG_0(a[0].(int), a[1].(float64)) - } - panic("No match for overloaded function call") -} - -var _wrap_Before_AddedMethod__SWIG_0 unsafe.Pointer - -func _swig_wrap_Before_AddedMethod__SWIG_0(base SwigcptrBefore, _ int, _ float64) (_ float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Before_AddedMethod__SWIG_0, _swig_p) - return -} - -func (arg1 SwigcptrBefore) AddedMethod__SWIG_0(arg2 int, arg3 float64) (_swig_ret float64) { - return _swig_wrap_Before_AddedMethod__SWIG_0(arg1, arg2, arg3) -} - -var _wrap_Before_AddedMethod__SWIG_1 unsafe.Pointer - -func _swig_wrap_Before_AddedMethod__SWIG_1(base SwigcptrBefore, _ int) (_ float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Before_AddedMethod__SWIG_1, _swig_p) - return -} - -func (arg1 SwigcptrBefore) AddedMethod__SWIG_1(arg2 int) (_swig_ret float64) { - return _swig_wrap_Before_AddedMethod__SWIG_1(arg1, arg2) -} - -var _wrap_Before_AddedMethod__SWIG_2 unsafe.Pointer - -func _swig_wrap_Before_AddedMethod__SWIG_2(base SwigcptrBefore) (_ float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Before_AddedMethod__SWIG_2, _swig_p) - return -} - -func (arg1 SwigcptrBefore) AddedMethod__SWIG_2() (_swig_ret float64) { - return _swig_wrap_Before_AddedMethod__SWIG_2(arg1) -} - -func (p SwigcptrBefore) AddedMethod(a ...interface{}) float64 { - argc := len(a) - if argc == 0 { - return p.AddedMethod__SWIG_2() - } - if argc == 1 { - return p.AddedMethod__SWIG_1(a[0].(int)) - } - if argc == 2 { - return p.AddedMethod__SWIG_0(a[0].(int), a[1].(float64)) - } - panic("No match for overloaded function call") -} - -var _wrap_delete_Before unsafe.Pointer - -func _swig_wrap_delete_Before(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Before, _swig_p) - return -} - -func DeleteBefore(arg1 Before) { - _swig_wrap_delete_Before(arg1.Swigcptr()) -} - -type Before interface { - Swigcptr() uintptr - SwigIsBefore() - SetD(arg2 float64) - GetD() (_swig_ret float64) - SetI(arg2 int) - GetI() (_swig_ret int) - AddedMethod(a ...interface{}) float64 -} - -type SwigcptrAfter uintptr - -func (p SwigcptrAfter) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrAfter) SwigIsAfter() { -} - -var _wrap_After_d_set unsafe.Pointer - -func _swig_wrap_After_d_set(base SwigcptrAfter, _ float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_After_d_set, _swig_p) - return -} - -func (arg1 SwigcptrAfter) SetD(arg2 float64) { - _swig_wrap_After_d_set(arg1, arg2) -} - -var _wrap_After_d_get unsafe.Pointer - -func _swig_wrap_After_d_get(base SwigcptrAfter) (_ float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_After_d_get, _swig_p) - return -} - -func (arg1 SwigcptrAfter) GetD() (_swig_ret float64) { - return _swig_wrap_After_d_get(arg1) -} - -var _wrap_After_i_set unsafe.Pointer - -func _swig_wrap_After_i_set(base SwigcptrAfter, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_After_i_set, _swig_p) - return -} - -func (arg1 SwigcptrAfter) SetI(arg2 int) { - _swig_wrap_After_i_set(arg1, arg2) -} - -var _wrap_After_i_get unsafe.Pointer - -func _swig_wrap_After_i_get(base SwigcptrAfter) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_After_i_get, _swig_p) - return -} - -func (arg1 SwigcptrAfter) GetI() (_swig_ret int) { - return _swig_wrap_After_i_get(arg1) -} - -var _wrap_new_After__SWIG_0 unsafe.Pointer - -func _swig_wrap_new_After__SWIG_0(base int, _ float64) (_ SwigcptrAfter) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_After__SWIG_0, _swig_p) - return -} - -func NewAfter__SWIG_0(arg1 int, arg2 float64) (_swig_ret After) { - return _swig_wrap_new_After__SWIG_0(arg1, arg2) -} - -var _wrap_new_After__SWIG_1 unsafe.Pointer - -func _swig_wrap_new_After__SWIG_1(base int) (_ SwigcptrAfter) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_After__SWIG_1, _swig_p) - return -} - -func NewAfter__SWIG_1(arg1 int) (_swig_ret After) { - return _swig_wrap_new_After__SWIG_1(arg1) -} - -var _wrap_new_After__SWIG_2 unsafe.Pointer - -func _swig_wrap_new_After__SWIG_2() (base SwigcptrAfter) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_After__SWIG_2, _swig_p) - return -} - -func NewAfter__SWIG_2() (_swig_ret After) { - return _swig_wrap_new_After__SWIG_2() -} - -func NewAfter(a ...interface{}) After { - argc := len(a) - if argc == 0 { - return NewAfter__SWIG_2() - } - if argc == 1 { - return NewAfter__SWIG_1(a[0].(int)) - } - if argc == 2 { - return NewAfter__SWIG_0(a[0].(int), a[1].(float64)) - } - panic("No match for overloaded function call") -} - -var _wrap_After_AddedStaticMethod__SWIG_0 unsafe.Pointer - -func AfterAddedStaticMethod__SWIG_0(arg1 int, arg2 float64) (_swig_ret float64) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_After_AddedStaticMethod__SWIG_0, _swig_p) - return -} -var _wrap_After_AddedStaticMethod__SWIG_1 unsafe.Pointer - -func AfterAddedStaticMethod__SWIG_1(arg1 int) (_swig_ret float64) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_After_AddedStaticMethod__SWIG_1, _swig_p) - return -} -var _wrap_After_AddedStaticMethod__SWIG_2 unsafe.Pointer - -func AfterAddedStaticMethod__SWIG_2() (_swig_ret float64) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_After_AddedStaticMethod__SWIG_2, _swig_p) - return -} -func AfterAddedStaticMethod(a ...interface{}) float64 { - argc := len(a) - if argc == 0 { - return AfterAddedStaticMethod__SWIG_2() - } - if argc == 1 { - return AfterAddedStaticMethod__SWIG_1(a[0].(int)) - } - if argc == 2 { - return AfterAddedStaticMethod__SWIG_0(a[0].(int), a[1].(float64)) - } - panic("No match for overloaded function call") -} - -var _wrap_After_AddedMethod__SWIG_0 unsafe.Pointer - -func _swig_wrap_After_AddedMethod__SWIG_0(base SwigcptrAfter, _ int, _ float64) (_ float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_After_AddedMethod__SWIG_0, _swig_p) - return -} - -func (arg1 SwigcptrAfter) AddedMethod__SWIG_0(arg2 int, arg3 float64) (_swig_ret float64) { - return _swig_wrap_After_AddedMethod__SWIG_0(arg1, arg2, arg3) -} - -var _wrap_After_AddedMethod__SWIG_1 unsafe.Pointer - -func _swig_wrap_After_AddedMethod__SWIG_1(base SwigcptrAfter, _ int) (_ float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_After_AddedMethod__SWIG_1, _swig_p) - return -} - -func (arg1 SwigcptrAfter) AddedMethod__SWIG_1(arg2 int) (_swig_ret float64) { - return _swig_wrap_After_AddedMethod__SWIG_1(arg1, arg2) -} - -var _wrap_After_AddedMethod__SWIG_2 unsafe.Pointer - -func _swig_wrap_After_AddedMethod__SWIG_2(base SwigcptrAfter) (_ float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_After_AddedMethod__SWIG_2, _swig_p) - return -} - -func (arg1 SwigcptrAfter) AddedMethod__SWIG_2() (_swig_ret float64) { - return _swig_wrap_After_AddedMethod__SWIG_2(arg1) -} - -func (p SwigcptrAfter) AddedMethod(a ...interface{}) float64 { - argc := len(a) - if argc == 0 { - return p.AddedMethod__SWIG_2() - } - if argc == 1 { - return p.AddedMethod__SWIG_1(a[0].(int)) - } - if argc == 2 { - return p.AddedMethod__SWIG_0(a[0].(int), a[1].(float64)) - } - panic("No match for overloaded function call") -} - -var _wrap_delete_After unsafe.Pointer - -func _swig_wrap_delete_After(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_After, _swig_p) - return -} - -func DeleteAfter(arg1 After) { - _swig_wrap_delete_After(arg1.Swigcptr()) -} - -type After interface { - Swigcptr() uintptr - SwigIsAfter() - SetD(arg2 float64) - GetD() (_swig_ret float64) - SetI(arg2 int) - GetI() (_swig_ret int) - AddedMethod(a ...interface{}) float64 -} - -type SwigcptrOverBefore uintptr - -func (p SwigcptrOverBefore) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrOverBefore) SwigIsOverBefore() { -} - -var _wrap_new_OverBefore__SWIG_0 unsafe.Pointer - -func _swig_wrap_new_OverBefore__SWIG_0(base string, _ int, _ float64) (_ SwigcptrOverBefore) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_OverBefore__SWIG_0, _swig_p) - return -} - -func NewOverBefore__SWIG_0(arg1 string, arg2 int, arg3 float64) (_swig_ret OverBefore) { - return _swig_wrap_new_OverBefore__SWIG_0(arg1, arg2, arg3) -} - -var _wrap_new_OverBefore__SWIG_1 unsafe.Pointer - -func _swig_wrap_new_OverBefore__SWIG_1(base string, _ int) (_ SwigcptrOverBefore) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_OverBefore__SWIG_1, _swig_p) - return -} - -func NewOverBefore__SWIG_1(arg1 string, arg2 int) (_swig_ret OverBefore) { - return _swig_wrap_new_OverBefore__SWIG_1(arg1, arg2) -} - -var _wrap_new_OverBefore__SWIG_2 unsafe.Pointer - -func _swig_wrap_new_OverBefore__SWIG_2(base string) (_ SwigcptrOverBefore) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_OverBefore__SWIG_2, _swig_p) - return -} - -func NewOverBefore__SWIG_2(arg1 string) (_swig_ret OverBefore) { - return _swig_wrap_new_OverBefore__SWIG_2(arg1) -} - -var _wrap_OverBefore_AddedStaticMethod__SWIG_0 unsafe.Pointer - -func OverBeforeAddedStaticMethod__SWIG_0(arg1 string, arg2 int, arg3 float64) (_swig_ret float64) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_OverBefore_AddedStaticMethod__SWIG_0, _swig_p) - return -} -var _wrap_OverBefore_AddedStaticMethod__SWIG_1 unsafe.Pointer - -func OverBeforeAddedStaticMethod__SWIG_1(arg1 string, arg2 int) (_swig_ret float64) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_OverBefore_AddedStaticMethod__SWIG_1, _swig_p) - return -} -var _wrap_OverBefore_AddedStaticMethod__SWIG_2 unsafe.Pointer - -func OverBeforeAddedStaticMethod__SWIG_2(arg1 string) (_swig_ret float64) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_OverBefore_AddedStaticMethod__SWIG_2, _swig_p) - return -} -var _wrap_OverBefore_AddedMethod__SWIG_0 unsafe.Pointer - -func _swig_wrap_OverBefore_AddedMethod__SWIG_0(base SwigcptrOverBefore, _ string, _ int, _ float64) (_ float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_OverBefore_AddedMethod__SWIG_0, _swig_p) - return -} - -func (arg1 SwigcptrOverBefore) AddedMethod__SWIG_0(arg2 string, arg3 int, arg4 float64) (_swig_ret float64) { - return _swig_wrap_OverBefore_AddedMethod__SWIG_0(arg1, arg2, arg3, arg4) -} - -var _wrap_OverBefore_AddedMethod__SWIG_1 unsafe.Pointer - -func _swig_wrap_OverBefore_AddedMethod__SWIG_1(base SwigcptrOverBefore, _ string, _ int) (_ float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_OverBefore_AddedMethod__SWIG_1, _swig_p) - return -} - -func (arg1 SwigcptrOverBefore) AddedMethod__SWIG_1(arg2 string, arg3 int) (_swig_ret float64) { - return _swig_wrap_OverBefore_AddedMethod__SWIG_1(arg1, arg2, arg3) -} - -var _wrap_OverBefore_AddedMethod__SWIG_2 unsafe.Pointer - -func _swig_wrap_OverBefore_AddedMethod__SWIG_2(base SwigcptrOverBefore, _ string) (_ float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_OverBefore_AddedMethod__SWIG_2, _swig_p) - return -} - -func (arg1 SwigcptrOverBefore) AddedMethod__SWIG_2(arg2 string) (_swig_ret float64) { - return _swig_wrap_OverBefore_AddedMethod__SWIG_2(arg1, arg2) -} - -var _wrap_OverBefore_d_set unsafe.Pointer - -func _swig_wrap_OverBefore_d_set(base SwigcptrOverBefore, _ float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_OverBefore_d_set, _swig_p) - return -} - -func (arg1 SwigcptrOverBefore) SetD(arg2 float64) { - _swig_wrap_OverBefore_d_set(arg1, arg2) -} - -var _wrap_OverBefore_d_get unsafe.Pointer - -func _swig_wrap_OverBefore_d_get(base SwigcptrOverBefore) (_ float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_OverBefore_d_get, _swig_p) - return -} - -func (arg1 SwigcptrOverBefore) GetD() (_swig_ret float64) { - return _swig_wrap_OverBefore_d_get(arg1) -} - -var _wrap_OverBefore_i_set unsafe.Pointer - -func _swig_wrap_OverBefore_i_set(base SwigcptrOverBefore, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_OverBefore_i_set, _swig_p) - return -} - -func (arg1 SwigcptrOverBefore) SetI(arg2 int) { - _swig_wrap_OverBefore_i_set(arg1, arg2) -} - -var _wrap_OverBefore_i_get unsafe.Pointer - -func _swig_wrap_OverBefore_i_get(base SwigcptrOverBefore) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_OverBefore_i_get, _swig_p) - return -} - -func (arg1 SwigcptrOverBefore) GetI() (_swig_ret int) { - return _swig_wrap_OverBefore_i_get(arg1) -} - -var _wrap_new_OverBefore__SWIG_3 unsafe.Pointer - -func _swig_wrap_new_OverBefore__SWIG_3(base int, _ float64) (_ SwigcptrOverBefore) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_OverBefore__SWIG_3, _swig_p) - return -} - -func NewOverBefore__SWIG_3(arg1 int, arg2 float64) (_swig_ret OverBefore) { - return _swig_wrap_new_OverBefore__SWIG_3(arg1, arg2) -} - -var _wrap_new_OverBefore__SWIG_4 unsafe.Pointer - -func _swig_wrap_new_OverBefore__SWIG_4(base int) (_ SwigcptrOverBefore) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_OverBefore__SWIG_4, _swig_p) - return -} - -func NewOverBefore__SWIG_4(arg1 int) (_swig_ret OverBefore) { - return _swig_wrap_new_OverBefore__SWIG_4(arg1) -} - -var _wrap_new_OverBefore__SWIG_5 unsafe.Pointer - -func _swig_wrap_new_OverBefore__SWIG_5() (base SwigcptrOverBefore) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_OverBefore__SWIG_5, _swig_p) - return -} - -func NewOverBefore__SWIG_5() (_swig_ret OverBefore) { - return _swig_wrap_new_OverBefore__SWIG_5() -} - -func NewOverBefore(a ...interface{}) OverBefore { - argc := len(a) - if argc == 0 { - return NewOverBefore__SWIG_5() - } - if argc == 1 { - if _, ok := a[0].(int); !ok { - goto check_2 - } - return NewOverBefore__SWIG_4(a[0].(int)) - } -check_2: - if argc == 1 { - return NewOverBefore__SWIG_2(a[0].(string)) - } - if argc == 2 { - if _, ok := a[0].(int); !ok { - goto check_4 - } - if _, ok := a[1].(float64); !ok { - goto check_4 - } - return NewOverBefore__SWIG_3(a[0].(int), a[1].(float64)) - } -check_4: - if argc == 2 { - return NewOverBefore__SWIG_1(a[0].(string), a[1].(int)) - } - if argc == 3 { - return NewOverBefore__SWIG_0(a[0].(string), a[1].(int), a[2].(float64)) - } - panic("No match for overloaded function call") -} - -var _wrap_OverBefore_AddedStaticMethod__SWIG_3 unsafe.Pointer - -func OverBeforeAddedStaticMethod__SWIG_3(arg1 int, arg2 float64) (_swig_ret float64) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_OverBefore_AddedStaticMethod__SWIG_3, _swig_p) - return -} -var _wrap_OverBefore_AddedStaticMethod__SWIG_4 unsafe.Pointer - -func OverBeforeAddedStaticMethod__SWIG_4(arg1 int) (_swig_ret float64) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_OverBefore_AddedStaticMethod__SWIG_4, _swig_p) - return -} -var _wrap_OverBefore_AddedStaticMethod__SWIG_5 unsafe.Pointer - -func OverBeforeAddedStaticMethod__SWIG_5() (_swig_ret float64) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_OverBefore_AddedStaticMethod__SWIG_5, _swig_p) - return -} -func OverBeforeAddedStaticMethod(a ...interface{}) float64 { - argc := len(a) - if argc == 0 { - return OverBeforeAddedStaticMethod__SWIG_5() - } - if argc == 1 { - if _, ok := a[0].(int); !ok { - goto check_2 - } - return OverBeforeAddedStaticMethod__SWIG_4(a[0].(int)) - } -check_2: - if argc == 1 { - return OverBeforeAddedStaticMethod__SWIG_2(a[0].(string)) - } - if argc == 2 { - if _, ok := a[0].(int); !ok { - goto check_4 - } - if _, ok := a[1].(float64); !ok { - goto check_4 - } - return OverBeforeAddedStaticMethod__SWIG_3(a[0].(int), a[1].(float64)) - } -check_4: - if argc == 2 { - return OverBeforeAddedStaticMethod__SWIG_1(a[0].(string), a[1].(int)) - } - if argc == 3 { - return OverBeforeAddedStaticMethod__SWIG_0(a[0].(string), a[1].(int), a[2].(float64)) - } - panic("No match for overloaded function call") -} - -var _wrap_OverBefore_AddedMethod__SWIG_3 unsafe.Pointer - -func _swig_wrap_OverBefore_AddedMethod__SWIG_3(base SwigcptrOverBefore, _ int, _ float64) (_ float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_OverBefore_AddedMethod__SWIG_3, _swig_p) - return -} - -func (arg1 SwigcptrOverBefore) AddedMethod__SWIG_3(arg2 int, arg3 float64) (_swig_ret float64) { - return _swig_wrap_OverBefore_AddedMethod__SWIG_3(arg1, arg2, arg3) -} - -var _wrap_OverBefore_AddedMethod__SWIG_4 unsafe.Pointer - -func _swig_wrap_OverBefore_AddedMethod__SWIG_4(base SwigcptrOverBefore, _ int) (_ float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_OverBefore_AddedMethod__SWIG_4, _swig_p) - return -} - -func (arg1 SwigcptrOverBefore) AddedMethod__SWIG_4(arg2 int) (_swig_ret float64) { - return _swig_wrap_OverBefore_AddedMethod__SWIG_4(arg1, arg2) -} - -var _wrap_OverBefore_AddedMethod__SWIG_5 unsafe.Pointer - -func _swig_wrap_OverBefore_AddedMethod__SWIG_5(base SwigcptrOverBefore) (_ float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_OverBefore_AddedMethod__SWIG_5, _swig_p) - return -} - -func (arg1 SwigcptrOverBefore) AddedMethod__SWIG_5() (_swig_ret float64) { - return _swig_wrap_OverBefore_AddedMethod__SWIG_5(arg1) -} - -func (p SwigcptrOverBefore) AddedMethod(a ...interface{}) float64 { - argc := len(a) - if argc == 0 { - return p.AddedMethod__SWIG_5() - } - if argc == 1 { - if _, ok := a[0].(int); !ok { - goto check_2 - } - return p.AddedMethod__SWIG_4(a[0].(int)) - } -check_2: - if argc == 1 { - return p.AddedMethod__SWIG_2(a[0].(string)) - } - if argc == 2 { - if _, ok := a[0].(int); !ok { - goto check_4 - } - if _, ok := a[1].(float64); !ok { - goto check_4 - } - return p.AddedMethod__SWIG_3(a[0].(int), a[1].(float64)) - } -check_4: - if argc == 2 { - return p.AddedMethod__SWIG_1(a[0].(string), a[1].(int)) - } - if argc == 3 { - return p.AddedMethod__SWIG_0(a[0].(string), a[1].(int), a[2].(float64)) - } - panic("No match for overloaded function call") -} - -var _wrap_delete_OverBefore unsafe.Pointer - -func _swig_wrap_delete_OverBefore(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_OverBefore, _swig_p) - return -} - -func DeleteOverBefore(arg1 OverBefore) { - _swig_wrap_delete_OverBefore(arg1.Swigcptr()) -} - -type OverBefore interface { - Swigcptr() uintptr - SwigIsOverBefore() - SetD(arg2 float64) - GetD() (_swig_ret float64) - SetI(arg2 int) - GetI() (_swig_ret int) - AddedMethod(a ...interface{}) float64 -} - -type SwigcptrOverAfter uintptr - -func (p SwigcptrOverAfter) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrOverAfter) SwigIsOverAfter() { -} - -var _wrap_new_OverAfter__SWIG_0 unsafe.Pointer - -func _swig_wrap_new_OverAfter__SWIG_0(base string, _ int, _ float64) (_ SwigcptrOverAfter) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_OverAfter__SWIG_0, _swig_p) - return -} - -func NewOverAfter__SWIG_0(arg1 string, arg2 int, arg3 float64) (_swig_ret OverAfter) { - return _swig_wrap_new_OverAfter__SWIG_0(arg1, arg2, arg3) -} - -var _wrap_new_OverAfter__SWIG_1 unsafe.Pointer - -func _swig_wrap_new_OverAfter__SWIG_1(base string, _ int) (_ SwigcptrOverAfter) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_OverAfter__SWIG_1, _swig_p) - return -} - -func NewOverAfter__SWIG_1(arg1 string, arg2 int) (_swig_ret OverAfter) { - return _swig_wrap_new_OverAfter__SWIG_1(arg1, arg2) -} - -var _wrap_new_OverAfter__SWIG_2 unsafe.Pointer - -func _swig_wrap_new_OverAfter__SWIG_2(base string) (_ SwigcptrOverAfter) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_OverAfter__SWIG_2, _swig_p) - return -} - -func NewOverAfter__SWIG_2(arg1 string) (_swig_ret OverAfter) { - return _swig_wrap_new_OverAfter__SWIG_2(arg1) -} - -var _wrap_OverAfter_AddedStaticMethod__SWIG_0 unsafe.Pointer - -func OverAfterAddedStaticMethod__SWIG_0(arg1 string, arg2 int, arg3 float64) (_swig_ret float64) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_OverAfter_AddedStaticMethod__SWIG_0, _swig_p) - return -} -var _wrap_OverAfter_AddedStaticMethod__SWIG_1 unsafe.Pointer - -func OverAfterAddedStaticMethod__SWIG_1(arg1 string, arg2 int) (_swig_ret float64) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_OverAfter_AddedStaticMethod__SWIG_1, _swig_p) - return -} -var _wrap_OverAfter_AddedStaticMethod__SWIG_2 unsafe.Pointer - -func OverAfterAddedStaticMethod__SWIG_2(arg1 string) (_swig_ret float64) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_OverAfter_AddedStaticMethod__SWIG_2, _swig_p) - return -} -var _wrap_OverAfter_AddedMethod__SWIG_0 unsafe.Pointer - -func _swig_wrap_OverAfter_AddedMethod__SWIG_0(base SwigcptrOverAfter, _ string, _ int, _ float64) (_ float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_OverAfter_AddedMethod__SWIG_0, _swig_p) - return -} - -func (arg1 SwigcptrOverAfter) AddedMethod__SWIG_0(arg2 string, arg3 int, arg4 float64) (_swig_ret float64) { - return _swig_wrap_OverAfter_AddedMethod__SWIG_0(arg1, arg2, arg3, arg4) -} - -var _wrap_OverAfter_AddedMethod__SWIG_1 unsafe.Pointer - -func _swig_wrap_OverAfter_AddedMethod__SWIG_1(base SwigcptrOverAfter, _ string, _ int) (_ float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_OverAfter_AddedMethod__SWIG_1, _swig_p) - return -} - -func (arg1 SwigcptrOverAfter) AddedMethod__SWIG_1(arg2 string, arg3 int) (_swig_ret float64) { - return _swig_wrap_OverAfter_AddedMethod__SWIG_1(arg1, arg2, arg3) -} - -var _wrap_OverAfter_AddedMethod__SWIG_2 unsafe.Pointer - -func _swig_wrap_OverAfter_AddedMethod__SWIG_2(base SwigcptrOverAfter, _ string) (_ float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_OverAfter_AddedMethod__SWIG_2, _swig_p) - return -} - -func (arg1 SwigcptrOverAfter) AddedMethod__SWIG_2(arg2 string) (_swig_ret float64) { - return _swig_wrap_OverAfter_AddedMethod__SWIG_2(arg1, arg2) -} - -var _wrap_OverAfter_d_set unsafe.Pointer - -func _swig_wrap_OverAfter_d_set(base SwigcptrOverAfter, _ float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_OverAfter_d_set, _swig_p) - return -} - -func (arg1 SwigcptrOverAfter) SetD(arg2 float64) { - _swig_wrap_OverAfter_d_set(arg1, arg2) -} - -var _wrap_OverAfter_d_get unsafe.Pointer - -func _swig_wrap_OverAfter_d_get(base SwigcptrOverAfter) (_ float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_OverAfter_d_get, _swig_p) - return -} - -func (arg1 SwigcptrOverAfter) GetD() (_swig_ret float64) { - return _swig_wrap_OverAfter_d_get(arg1) -} - -var _wrap_OverAfter_i_set unsafe.Pointer - -func _swig_wrap_OverAfter_i_set(base SwigcptrOverAfter, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_OverAfter_i_set, _swig_p) - return -} - -func (arg1 SwigcptrOverAfter) SetI(arg2 int) { - _swig_wrap_OverAfter_i_set(arg1, arg2) -} - -var _wrap_OverAfter_i_get unsafe.Pointer - -func _swig_wrap_OverAfter_i_get(base SwigcptrOverAfter) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_OverAfter_i_get, _swig_p) - return -} - -func (arg1 SwigcptrOverAfter) GetI() (_swig_ret int) { - return _swig_wrap_OverAfter_i_get(arg1) -} - -var _wrap_new_OverAfter__SWIG_3 unsafe.Pointer - -func _swig_wrap_new_OverAfter__SWIG_3(base int, _ float64) (_ SwigcptrOverAfter) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_OverAfter__SWIG_3, _swig_p) - return -} - -func NewOverAfter__SWIG_3(arg1 int, arg2 float64) (_swig_ret OverAfter) { - return _swig_wrap_new_OverAfter__SWIG_3(arg1, arg2) -} - -var _wrap_new_OverAfter__SWIG_4 unsafe.Pointer - -func _swig_wrap_new_OverAfter__SWIG_4(base int) (_ SwigcptrOverAfter) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_OverAfter__SWIG_4, _swig_p) - return -} - -func NewOverAfter__SWIG_4(arg1 int) (_swig_ret OverAfter) { - return _swig_wrap_new_OverAfter__SWIG_4(arg1) -} - -var _wrap_new_OverAfter__SWIG_5 unsafe.Pointer - -func _swig_wrap_new_OverAfter__SWIG_5() (base SwigcptrOverAfter) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_OverAfter__SWIG_5, _swig_p) - return -} - -func NewOverAfter__SWIG_5() (_swig_ret OverAfter) { - return _swig_wrap_new_OverAfter__SWIG_5() -} - -func NewOverAfter(a ...interface{}) OverAfter { - argc := len(a) - if argc == 0 { - return NewOverAfter__SWIG_5() - } - if argc == 1 { - if _, ok := a[0].(int); !ok { - goto check_2 - } - return NewOverAfter__SWIG_4(a[0].(int)) - } -check_2: - if argc == 1 { - return NewOverAfter__SWIG_2(a[0].(string)) - } - if argc == 2 { - if _, ok := a[0].(int); !ok { - goto check_4 - } - if _, ok := a[1].(float64); !ok { - goto check_4 - } - return NewOverAfter__SWIG_3(a[0].(int), a[1].(float64)) - } -check_4: - if argc == 2 { - return NewOverAfter__SWIG_1(a[0].(string), a[1].(int)) - } - if argc == 3 { - return NewOverAfter__SWIG_0(a[0].(string), a[1].(int), a[2].(float64)) - } - panic("No match for overloaded function call") -} - -var _wrap_OverAfter_AddedStaticMethod__SWIG_3 unsafe.Pointer - -func OverAfterAddedStaticMethod__SWIG_3(arg1 int, arg2 float64) (_swig_ret float64) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_OverAfter_AddedStaticMethod__SWIG_3, _swig_p) - return -} -var _wrap_OverAfter_AddedStaticMethod__SWIG_4 unsafe.Pointer - -func OverAfterAddedStaticMethod__SWIG_4(arg1 int) (_swig_ret float64) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_OverAfter_AddedStaticMethod__SWIG_4, _swig_p) - return -} -var _wrap_OverAfter_AddedStaticMethod__SWIG_5 unsafe.Pointer - -func OverAfterAddedStaticMethod__SWIG_5() (_swig_ret float64) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_OverAfter_AddedStaticMethod__SWIG_5, _swig_p) - return -} -func OverAfterAddedStaticMethod(a ...interface{}) float64 { - argc := len(a) - if argc == 0 { - return OverAfterAddedStaticMethod__SWIG_5() - } - if argc == 1 { - if _, ok := a[0].(int); !ok { - goto check_2 - } - return OverAfterAddedStaticMethod__SWIG_4(a[0].(int)) - } -check_2: - if argc == 1 { - return OverAfterAddedStaticMethod__SWIG_2(a[0].(string)) - } - if argc == 2 { - if _, ok := a[0].(int); !ok { - goto check_4 - } - if _, ok := a[1].(float64); !ok { - goto check_4 - } - return OverAfterAddedStaticMethod__SWIG_3(a[0].(int), a[1].(float64)) - } -check_4: - if argc == 2 { - return OverAfterAddedStaticMethod__SWIG_1(a[0].(string), a[1].(int)) - } - if argc == 3 { - return OverAfterAddedStaticMethod__SWIG_0(a[0].(string), a[1].(int), a[2].(float64)) - } - panic("No match for overloaded function call") -} - -var _wrap_OverAfter_AddedMethod__SWIG_3 unsafe.Pointer - -func _swig_wrap_OverAfter_AddedMethod__SWIG_3(base SwigcptrOverAfter, _ int, _ float64) (_ float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_OverAfter_AddedMethod__SWIG_3, _swig_p) - return -} - -func (arg1 SwigcptrOverAfter) AddedMethod__SWIG_3(arg2 int, arg3 float64) (_swig_ret float64) { - return _swig_wrap_OverAfter_AddedMethod__SWIG_3(arg1, arg2, arg3) -} - -var _wrap_OverAfter_AddedMethod__SWIG_4 unsafe.Pointer - -func _swig_wrap_OverAfter_AddedMethod__SWIG_4(base SwigcptrOverAfter, _ int) (_ float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_OverAfter_AddedMethod__SWIG_4, _swig_p) - return -} - -func (arg1 SwigcptrOverAfter) AddedMethod__SWIG_4(arg2 int) (_swig_ret float64) { - return _swig_wrap_OverAfter_AddedMethod__SWIG_4(arg1, arg2) -} - -var _wrap_OverAfter_AddedMethod__SWIG_5 unsafe.Pointer - -func _swig_wrap_OverAfter_AddedMethod__SWIG_5(base SwigcptrOverAfter) (_ float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_OverAfter_AddedMethod__SWIG_5, _swig_p) - return -} - -func (arg1 SwigcptrOverAfter) AddedMethod__SWIG_5() (_swig_ret float64) { - return _swig_wrap_OverAfter_AddedMethod__SWIG_5(arg1) -} - -func (p SwigcptrOverAfter) AddedMethod(a ...interface{}) float64 { - argc := len(a) - if argc == 0 { - return p.AddedMethod__SWIG_5() - } - if argc == 1 { - if _, ok := a[0].(int); !ok { - goto check_2 - } - return p.AddedMethod__SWIG_4(a[0].(int)) - } -check_2: - if argc == 1 { - return p.AddedMethod__SWIG_2(a[0].(string)) - } - if argc == 2 { - if _, ok := a[0].(int); !ok { - goto check_4 - } - if _, ok := a[1].(float64); !ok { - goto check_4 - } - return p.AddedMethod__SWIG_3(a[0].(int), a[1].(float64)) - } -check_4: - if argc == 2 { - return p.AddedMethod__SWIG_1(a[0].(string), a[1].(int)) - } - if argc == 3 { - return p.AddedMethod__SWIG_0(a[0].(string), a[1].(int), a[2].(float64)) - } - panic("No match for overloaded function call") -} - -var _wrap_delete_OverAfter unsafe.Pointer - -func _swig_wrap_delete_OverAfter(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_OverAfter, _swig_p) - return -} - -func DeleteOverAfter(arg1 OverAfter) { - _swig_wrap_delete_OverAfter(arg1.Swigcptr()) -} - -type OverAfter interface { - Swigcptr() uintptr - SwigIsOverAfter() - SetD(arg2 float64) - GetD() (_swig_ret float64) - SetI(arg2 int) - GetI() (_swig_ret int) - AddedMethod(a ...interface{}) float64 -} - -type SwigcptrOverride uintptr - -func (p SwigcptrOverride) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrOverride) SwigIsOverride() { -} - -var _wrap_Override_over__SWIG_0 unsafe.Pointer - -func _swig_wrap_Override_over__SWIG_0(base SwigcptrOverride) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Override_over__SWIG_0, _swig_p) - return -} - -func (arg1 SwigcptrOverride) Over__SWIG_0() (_swig_ret int) { - return _swig_wrap_Override_over__SWIG_0(arg1) -} - -var _wrap_Override_ride__SWIG_0 unsafe.Pointer - -func _swig_wrap_Override_ride__SWIG_0(base SwigcptrOverride, _ int) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Override_ride__SWIG_0, _swig_p) - return -} - -func (arg1 SwigcptrOverride) Ride__SWIG_0(arg2 int) (_swig_ret int) { - return _swig_wrap_Override_ride__SWIG_0(arg1, arg2) -} - -var _wrap_Override_ride__SWIG_1 unsafe.Pointer - -func _swig_wrap_Override_ride__SWIG_1(base SwigcptrOverride) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Override_ride__SWIG_1, _swig_p) - return -} - -func (arg1 SwigcptrOverride) Ride__SWIG_1() (_swig_ret int) { - return _swig_wrap_Override_ride__SWIG_1(arg1) -} - -func (p SwigcptrOverride) Ride(a ...interface{}) int { - argc := len(a) - if argc == 0 { - return p.Ride__SWIG_1() - } - if argc == 1 { - return p.Ride__SWIG_0(a[0].(int)) - } - panic("No match for overloaded function call") -} - -var _wrap_Override_overload__SWIG_0 unsafe.Pointer - -func _swig_wrap_Override_overload__SWIG_0(base SwigcptrOverride) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Override_overload__SWIG_0, _swig_p) - return -} - -func (arg1 SwigcptrOverride) Overload__SWIG_0() (_swig_ret int) { - return _swig_wrap_Override_overload__SWIG_0(arg1) -} - -var _wrap_Override_over__SWIG_1 unsafe.Pointer - -func _swig_wrap_Override_over__SWIG_1(base SwigcptrOverride, _ int) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Override_over__SWIG_1, _swig_p) - return -} - -func (arg1 SwigcptrOverride) Over__SWIG_1(arg2 int) (_swig_ret int) { - return _swig_wrap_Override_over__SWIG_1(arg1, arg2) -} - -func (p SwigcptrOverride) Over(a ...interface{}) int { - argc := len(a) - if argc == 0 { - return p.Over__SWIG_0() - } - if argc == 1 { - return p.Over__SWIG_1(a[0].(int)) - } - panic("No match for overloaded function call") -} - -var _wrap_Override_overload__SWIG_1 unsafe.Pointer - -func _swig_wrap_Override_overload__SWIG_1(base SwigcptrOverride, _ int) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Override_overload__SWIG_1, _swig_p) - return -} - -func (arg1 SwigcptrOverride) Overload__SWIG_1(arg2 int) (_swig_ret int) { - return _swig_wrap_Override_overload__SWIG_1(arg1, arg2) -} - -func (p SwigcptrOverride) Overload(a ...interface{}) int { - argc := len(a) - if argc == 0 { - return p.Overload__SWIG_0() - } - if argc == 1 { - return p.Overload__SWIG_1(a[0].(int)) - } - panic("No match for overloaded function call") -} - -var _wrap_new_Override unsafe.Pointer - -func _swig_wrap_new_Override() (base SwigcptrOverride) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Override, _swig_p) - return -} - -func NewOverride() (_swig_ret Override) { - return _swig_wrap_new_Override() -} - -var _wrap_delete_Override unsafe.Pointer - -func _swig_wrap_delete_Override(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Override, _swig_p) - return -} - -func DeleteOverride(arg1 Override) { - _swig_wrap_delete_Override(arg1.Swigcptr()) -} - -type Override interface { - Swigcptr() uintptr - SwigIsOverride() - Ride(a ...interface{}) int - Over(a ...interface{}) int - Overload(a ...interface{}) int -} - -type SwigcptrBase uintptr - -func (p SwigcptrBase) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrBase) SwigIsBase() { -} - -var _wrap_delete_Base unsafe.Pointer - -func _swig_wrap_delete_Base(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Base, _swig_p) - return -} - -func DeleteBase(arg1 Base) { - _swig_wrap_delete_Base(arg1.Swigcptr()) -} - -var _wrap_Base_realvirtual__SWIG_0 unsafe.Pointer - -func _swig_wrap_Base_realvirtual__SWIG_0(base SwigcptrBase, _ int) (_ *int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Base_realvirtual__SWIG_0, _swig_p) - return -} - -func (arg1 SwigcptrBase) Realvirtual__SWIG_0(arg2 int) (_swig_ret *int) { - return _swig_wrap_Base_realvirtual__SWIG_0(arg1, arg2) -} - -var _wrap_Base_realvirtual__SWIG_1 unsafe.Pointer - -func _swig_wrap_Base_realvirtual__SWIG_1(base SwigcptrBase) (_ *int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Base_realvirtual__SWIG_1, _swig_p) - return -} - -func (arg1 SwigcptrBase) Realvirtual__SWIG_1() (_swig_ret *int) { - return _swig_wrap_Base_realvirtual__SWIG_1(arg1) -} - -func (p SwigcptrBase) Realvirtual(a ...interface{}) *int { - argc := len(a) - if argc == 0 { - return p.Realvirtual__SWIG_1() - } - if argc == 1 { - return p.Realvirtual__SWIG_0(a[0].(int)) - } - panic("No match for overloaded function call") -} - -var _wrap_Base_virtualmethod__SWIG_0 unsafe.Pointer - -func _swig_wrap_Base_virtualmethod__SWIG_0(base SwigcptrBase, _ int) (_ *int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Base_virtualmethod__SWIG_0, _swig_p) - return -} - -func (arg1 SwigcptrBase) Virtualmethod__SWIG_0(arg2 int) (_swig_ret *int) { - return _swig_wrap_Base_virtualmethod__SWIG_0(arg1, arg2) -} - -var _wrap_Base_virtualmethod__SWIG_1 unsafe.Pointer - -func _swig_wrap_Base_virtualmethod__SWIG_1(base SwigcptrBase) (_ *int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Base_virtualmethod__SWIG_1, _swig_p) - return -} - -func (arg1 SwigcptrBase) Virtualmethod__SWIG_1() (_swig_ret *int) { - return _swig_wrap_Base_virtualmethod__SWIG_1(arg1) -} - -func (p SwigcptrBase) Virtualmethod(a ...interface{}) *int { - argc := len(a) - if argc == 0 { - return p.Virtualmethod__SWIG_1() - } - if argc == 1 { - return p.Virtualmethod__SWIG_0(a[0].(int)) - } - panic("No match for overloaded function call") -} - -var _wrap_Base_nonvirtual__SWIG_0 unsafe.Pointer - -func _swig_wrap_Base_nonvirtual__SWIG_0(base SwigcptrBase, _ int) (_ *int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Base_nonvirtual__SWIG_0, _swig_p) - return -} - -func (arg1 SwigcptrBase) Nonvirtual__SWIG_0(arg2 int) (_swig_ret *int) { - return _swig_wrap_Base_nonvirtual__SWIG_0(arg1, arg2) -} - -var _wrap_Base_nonvirtual__SWIG_1 unsafe.Pointer - -func _swig_wrap_Base_nonvirtual__SWIG_1(base SwigcptrBase) (_ *int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Base_nonvirtual__SWIG_1, _swig_p) - return -} - -func (arg1 SwigcptrBase) Nonvirtual__SWIG_1() (_swig_ret *int) { - return _swig_wrap_Base_nonvirtual__SWIG_1(arg1) -} - -func (p SwigcptrBase) Nonvirtual(a ...interface{}) *int { - argc := len(a) - if argc == 0 { - return p.Nonvirtual__SWIG_1() - } - if argc == 1 { - return p.Nonvirtual__SWIG_0(a[0].(int)) - } - panic("No match for overloaded function call") -} - -var _wrap_Base_static_method__SWIG_0 unsafe.Pointer - -func BaseStatic_method__SWIG_0(arg1 int) (_swig_ret *int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_Base_static_method__SWIG_0, _swig_p) - return -} -var _wrap_Base_static_method__SWIG_1 unsafe.Pointer - -func BaseStatic_method__SWIG_1() (_swig_ret *int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_Base_static_method__SWIG_1, _swig_p) - return -} -func BaseStatic_method(a ...interface{}) *int { - argc := len(a) - if argc == 0 { - return BaseStatic_method__SWIG_1() - } - if argc == 1 { - return BaseStatic_method__SWIG_0(a[0].(int)) - } - panic("No match for overloaded function call") -} - -var _wrap_new_Base unsafe.Pointer - -func _swig_wrap_new_Base() (base SwigcptrBase) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Base, _swig_p) - return -} - -func NewBase() (_swig_ret Base) { - return _swig_wrap_new_Base() -} - -type Base interface { - Swigcptr() uintptr - SwigIsBase() - Realvirtual(a ...interface{}) *int - Virtualmethod(a ...interface{}) *int - Nonvirtual(a ...interface{}) *int -} - -type SwigcptrDerived uintptr - -func (p SwigcptrDerived) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrDerived) SwigIsDerived() { -} - -var _wrap_Derived_virtualmethod__SWIG_0 unsafe.Pointer - -func _swig_wrap_Derived_virtualmethod__SWIG_0(base SwigcptrDerived, _ int) (_ *int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Derived_virtualmethod__SWIG_0, _swig_p) - return -} - -func (arg1 SwigcptrDerived) Virtualmethod__SWIG_0(arg2 int) (_swig_ret *int) { - return _swig_wrap_Derived_virtualmethod__SWIG_0(arg1, arg2) -} - -var _wrap_Derived_virtualmethod__SWIG_1 unsafe.Pointer - -func _swig_wrap_Derived_virtualmethod__SWIG_1(base SwigcptrDerived) (_ *int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Derived_virtualmethod__SWIG_1, _swig_p) - return -} - -func (arg1 SwigcptrDerived) Virtualmethod__SWIG_1() (_swig_ret *int) { - return _swig_wrap_Derived_virtualmethod__SWIG_1(arg1) -} - -func (p SwigcptrDerived) Virtualmethod(a ...interface{}) *int { - argc := len(a) - if argc == 0 { - return p.Virtualmethod__SWIG_1() - } - if argc == 1 { - return p.Virtualmethod__SWIG_0(a[0].(int)) - } - panic("No match for overloaded function call") -} - -var _wrap_Derived_nonvirtual__SWIG_0 unsafe.Pointer - -func _swig_wrap_Derived_nonvirtual__SWIG_0(base SwigcptrDerived, _ int) (_ *int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Derived_nonvirtual__SWIG_0, _swig_p) - return -} - -func (arg1 SwigcptrDerived) Nonvirtual__SWIG_0(arg2 int) (_swig_ret *int) { - return _swig_wrap_Derived_nonvirtual__SWIG_0(arg1, arg2) -} - -var _wrap_Derived_nonvirtual__SWIG_1 unsafe.Pointer - -func _swig_wrap_Derived_nonvirtual__SWIG_1(base SwigcptrDerived) (_ *int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Derived_nonvirtual__SWIG_1, _swig_p) - return -} - -func (arg1 SwigcptrDerived) Nonvirtual__SWIG_1() (_swig_ret *int) { - return _swig_wrap_Derived_nonvirtual__SWIG_1(arg1) -} - -func (p SwigcptrDerived) Nonvirtual(a ...interface{}) *int { - argc := len(a) - if argc == 0 { - return p.Nonvirtual__SWIG_1() - } - if argc == 1 { - return p.Nonvirtual__SWIG_0(a[0].(int)) - } - panic("No match for overloaded function call") -} - -var _wrap_Derived_static_method__SWIG_0 unsafe.Pointer - -func DerivedStatic_method__SWIG_0(arg1 int) (_swig_ret *int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_Derived_static_method__SWIG_0, _swig_p) - return -} -var _wrap_Derived_static_method__SWIG_1 unsafe.Pointer - -func DerivedStatic_method__SWIG_1() (_swig_ret *int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_Derived_static_method__SWIG_1, _swig_p) - return -} -func DerivedStatic_method(a ...interface{}) *int { - argc := len(a) - if argc == 0 { - return DerivedStatic_method__SWIG_1() - } - if argc == 1 { - return DerivedStatic_method__SWIG_0(a[0].(int)) - } - panic("No match for overloaded function call") -} - -var _wrap_Derived_realvirtual__SWIG_0 unsafe.Pointer - -func _swig_wrap_Derived_realvirtual__SWIG_0(base SwigcptrDerived, _ int) (_ *int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Derived_realvirtual__SWIG_0, _swig_p) - return -} - -func (arg1 SwigcptrDerived) Realvirtual__SWIG_0(arg2 int) (_swig_ret *int) { - return _swig_wrap_Derived_realvirtual__SWIG_0(arg1, arg2) -} - -var _wrap_Derived_realvirtual__SWIG_1 unsafe.Pointer - -func _swig_wrap_Derived_realvirtual__SWIG_1(base SwigcptrDerived) (_ *int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Derived_realvirtual__SWIG_1, _swig_p) - return -} - -func (arg1 SwigcptrDerived) Realvirtual__SWIG_1() (_swig_ret *int) { - return _swig_wrap_Derived_realvirtual__SWIG_1(arg1) -} - -func (p SwigcptrDerived) Realvirtual(a ...interface{}) *int { - argc := len(a) - if argc == 0 { - return p.Realvirtual__SWIG_1() - } - if argc == 1 { - return p.Realvirtual__SWIG_0(a[0].(int)) - } - panic("No match for overloaded function call") -} - -var _wrap_new_Derived unsafe.Pointer - -func _swig_wrap_new_Derived() (base SwigcptrDerived) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Derived, _swig_p) - return -} - -func NewDerived() (_swig_ret Derived) { - return _swig_wrap_new_Derived() -} - -var _wrap_delete_Derived unsafe.Pointer - -func _swig_wrap_delete_Derived(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Derived, _swig_p) - return -} - -func DeleteDerived(arg1 Derived) { - _swig_wrap_delete_Derived(arg1.Swigcptr()) -} - -func (p SwigcptrDerived) SwigIsBase() { -} - -func (p SwigcptrDerived) SwigGetBase() Base { - return SwigcptrBase(p.Swigcptr()) -} - -type Derived interface { - Swigcptr() uintptr - SwigIsDerived() - Virtualmethod(a ...interface{}) *int - Nonvirtual(a ...interface{}) *int - Realvirtual(a ...interface{}) *int - SwigIsBase() - SwigGetBase() Base -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/extend_placement.go b/Examples/test-suite/go/extend_placement.go deleted file mode 100644 index 94ef42a59..000000000 --- a/Examples/test-suite/go/extend_placement.go +++ /dev/null @@ -1,815 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../extend_placement.i - -package extend_placement - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrFoo uintptr - -func (p SwigcptrFoo) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrFoo) SwigIsFoo() { -} - -var _wrap_new_Foo__SWIG_0 unsafe.Pointer - -func _swig_wrap_new_Foo__SWIG_0() (base SwigcptrFoo) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Foo__SWIG_0, _swig_p) - return -} - -func NewFoo__SWIG_0() (_swig_ret Foo) { - return _swig_wrap_new_Foo__SWIG_0() -} - -var _wrap_new_Foo__SWIG_1 unsafe.Pointer - -func _swig_wrap_new_Foo__SWIG_1(base int, _ int) (_ SwigcptrFoo) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Foo__SWIG_1, _swig_p) - return -} - -func NewFoo__SWIG_1(arg1 int, arg2 int) (_swig_ret Foo) { - return _swig_wrap_new_Foo__SWIG_1(arg1, arg2) -} - -var _wrap_Foo_spam__SWIG_0 unsafe.Pointer - -func _swig_wrap_Foo_spam__SWIG_0(base SwigcptrFoo) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_spam__SWIG_0, _swig_p) - return -} - -func (arg1 SwigcptrFoo) Spam__SWIG_0() (_swig_ret int) { - return _swig_wrap_Foo_spam__SWIG_0(arg1) -} - -var _wrap_Foo_spam__SWIG_1 unsafe.Pointer - -func _swig_wrap_Foo_spam__SWIG_1(base SwigcptrFoo, _ string) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_spam__SWIG_1, _swig_p) - return -} - -func (arg1 SwigcptrFoo) Spam__SWIG_1(arg2 string) (_swig_ret int) { - return _swig_wrap_Foo_spam__SWIG_1(arg1, arg2) -} - -var _wrap_new_Foo__SWIG_2 unsafe.Pointer - -func _swig_wrap_new_Foo__SWIG_2(base int) (_ SwigcptrFoo) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Foo__SWIG_2, _swig_p) - return -} - -func NewFoo__SWIG_2(arg1 int) (_swig_ret Foo) { - return _swig_wrap_new_Foo__SWIG_2(arg1) -} - -func NewFoo(a ...interface{}) Foo { - argc := len(a) - if argc == 0 { - return NewFoo__SWIG_0() - } - if argc == 1 { - return NewFoo__SWIG_2(a[0].(int)) - } - if argc == 2 { - return NewFoo__SWIG_1(a[0].(int), a[1].(int)) - } - panic("No match for overloaded function call") -} - -var _wrap_delete_Foo unsafe.Pointer - -func _swig_wrap_delete_Foo(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Foo, _swig_p) - return -} - -func DeleteFoo(arg1 Foo) { - _swig_wrap_delete_Foo(arg1.Swigcptr()) -} - -var _wrap_Foo_spam__SWIG_2 unsafe.Pointer - -func _swig_wrap_Foo_spam__SWIG_2(base SwigcptrFoo, _ int) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_spam__SWIG_2, _swig_p) - return -} - -func (arg1 SwigcptrFoo) Spam__SWIG_2(arg2 int) (_swig_ret int) { - return _swig_wrap_Foo_spam__SWIG_2(arg1, arg2) -} - -var _wrap_Foo_spam__SWIG_3 unsafe.Pointer - -func _swig_wrap_Foo_spam__SWIG_3(base SwigcptrFoo, _ int, _ int) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_spam__SWIG_3, _swig_p) - return -} - -func (arg1 SwigcptrFoo) Spam__SWIG_3(arg2 int, arg3 int) (_swig_ret int) { - return _swig_wrap_Foo_spam__SWIG_3(arg1, arg2, arg3) -} - -var _wrap_Foo_spam__SWIG_4 unsafe.Pointer - -func _swig_wrap_Foo_spam__SWIG_4(base SwigcptrFoo, _ int, _ int, _ int) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_spam__SWIG_4, _swig_p) - return -} - -func (arg1 SwigcptrFoo) Spam__SWIG_4(arg2 int, arg3 int, arg4 int) (_swig_ret int) { - return _swig_wrap_Foo_spam__SWIG_4(arg1, arg2, arg3, arg4) -} - -var _wrap_Foo_spam__SWIG_5 unsafe.Pointer - -func _swig_wrap_Foo_spam__SWIG_5(base SwigcptrFoo, _ uintptr, _ float64) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_spam__SWIG_5, _swig_p) - return -} - -func (arg1 SwigcptrFoo) Spam__SWIG_5(arg2 Foo, arg3 float64) (_swig_ret int) { - return _swig_wrap_Foo_spam__SWIG_5(arg1, arg2.Swigcptr(), arg3) -} - -var _wrap_Foo_spam__SWIG_6 unsafe.Pointer - -func _swig_wrap_Foo_spam__SWIG_6(base SwigcptrFoo, _ uintptr) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_spam__SWIG_6, _swig_p) - return -} - -func (arg1 SwigcptrFoo) Spam__SWIG_6(arg2 Foo) (_swig_ret int) { - return _swig_wrap_Foo_spam__SWIG_6(arg1, arg2.Swigcptr()) -} - -func (p SwigcptrFoo) Spam(a ...interface{}) int { - argc := len(a) - if argc == 0 { - return p.Spam__SWIG_0() - } - if argc == 1 { - if _, ok := a[0].(Foo); !ok { - goto check_2 - } - return p.Spam__SWIG_6(a[0].(Foo)) - } -check_2: - if argc == 1 { - if _, ok := a[0].(int); !ok { - goto check_3 - } - return p.Spam__SWIG_2(a[0].(int)) - } -check_3: - if argc == 1 { - return p.Spam__SWIG_1(a[0].(string)) - } - if argc == 2 { - if _, ok := a[0].(Foo); !ok { - goto check_5 - } - if _, ok := a[1].(float64); !ok { - goto check_5 - } - return p.Spam__SWIG_5(a[0].(Foo), a[1].(float64)) - } -check_5: - if argc == 2 { - return p.Spam__SWIG_3(a[0].(int), a[1].(int)) - } - if argc == 3 { - return p.Spam__SWIG_4(a[0].(int), a[1].(int), a[2].(int)) - } - panic("No match for overloaded function call") -} - -type Foo interface { - Swigcptr() uintptr - SwigIsFoo() - Spam(a ...interface{}) int -} - -type SwigcptrBar uintptr - -func (p SwigcptrBar) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrBar) SwigIsBar() { -} - -var _wrap_new_Bar__SWIG_0 unsafe.Pointer - -func _swig_wrap_new_Bar__SWIG_0() (base SwigcptrBar) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Bar__SWIG_0, _swig_p) - return -} - -func NewBar__SWIG_0() (_swig_ret Bar) { - return _swig_wrap_new_Bar__SWIG_0() -} - -var _wrap_Bar_spam__SWIG_0 unsafe.Pointer - -func _swig_wrap_Bar_spam__SWIG_0(base SwigcptrBar) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Bar_spam__SWIG_0, _swig_p) - return -} - -func (arg1 SwigcptrBar) Spam__SWIG_0() (_swig_ret int) { - return _swig_wrap_Bar_spam__SWIG_0(arg1) -} - -var _wrap_Bar_spam__SWIG_1 unsafe.Pointer - -func _swig_wrap_Bar_spam__SWIG_1(base SwigcptrBar, _ string) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Bar_spam__SWIG_1, _swig_p) - return -} - -func (arg1 SwigcptrBar) Spam__SWIG_1(arg2 string) (_swig_ret int) { - return _swig_wrap_Bar_spam__SWIG_1(arg1, arg2) -} - -var _wrap_new_Bar__SWIG_1 unsafe.Pointer - -func _swig_wrap_new_Bar__SWIG_1(base int) (_ SwigcptrBar) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Bar__SWIG_1, _swig_p) - return -} - -func NewBar__SWIG_1(arg1 int) (_swig_ret Bar) { - return _swig_wrap_new_Bar__SWIG_1(arg1) -} - -func NewBar(a ...interface{}) Bar { - argc := len(a) - if argc == 0 { - return NewBar__SWIG_0() - } - if argc == 1 { - return NewBar__SWIG_1(a[0].(int)) - } - panic("No match for overloaded function call") -} - -var _wrap_delete_Bar unsafe.Pointer - -func _swig_wrap_delete_Bar(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Bar, _swig_p) - return -} - -func DeleteBar(arg1 Bar) { - _swig_wrap_delete_Bar(arg1.Swigcptr()) -} - -var _wrap_Bar_spam__SWIG_2 unsafe.Pointer - -func _swig_wrap_Bar_spam__SWIG_2(base SwigcptrBar, _ int) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Bar_spam__SWIG_2, _swig_p) - return -} - -func (arg1 SwigcptrBar) Spam__SWIG_2(arg2 int) (_swig_ret int) { - return _swig_wrap_Bar_spam__SWIG_2(arg1, arg2) -} - -var _wrap_Bar_spam__SWIG_3 unsafe.Pointer - -func _swig_wrap_Bar_spam__SWIG_3(base SwigcptrBar, _ int, _ int) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Bar_spam__SWIG_3, _swig_p) - return -} - -func (arg1 SwigcptrBar) Spam__SWIG_3(arg2 int, arg3 int) (_swig_ret int) { - return _swig_wrap_Bar_spam__SWIG_3(arg1, arg2, arg3) -} - -var _wrap_Bar_spam__SWIG_4 unsafe.Pointer - -func _swig_wrap_Bar_spam__SWIG_4(base SwigcptrBar, _ int, _ int, _ int) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Bar_spam__SWIG_4, _swig_p) - return -} - -func (arg1 SwigcptrBar) Spam__SWIG_4(arg2 int, arg3 int, arg4 int) (_swig_ret int) { - return _swig_wrap_Bar_spam__SWIG_4(arg1, arg2, arg3, arg4) -} - -var _wrap_Bar_spam__SWIG_5 unsafe.Pointer - -func _swig_wrap_Bar_spam__SWIG_5(base SwigcptrBar, _ uintptr, _ float64) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Bar_spam__SWIG_5, _swig_p) - return -} - -func (arg1 SwigcptrBar) Spam__SWIG_5(arg2 Bar, arg3 float64) (_swig_ret int) { - return _swig_wrap_Bar_spam__SWIG_5(arg1, arg2.Swigcptr(), arg3) -} - -var _wrap_Bar_spam__SWIG_6 unsafe.Pointer - -func _swig_wrap_Bar_spam__SWIG_6(base SwigcptrBar, _ uintptr) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Bar_spam__SWIG_6, _swig_p) - return -} - -func (arg1 SwigcptrBar) Spam__SWIG_6(arg2 Bar) (_swig_ret int) { - return _swig_wrap_Bar_spam__SWIG_6(arg1, arg2.Swigcptr()) -} - -func (p SwigcptrBar) Spam(a ...interface{}) int { - argc := len(a) - if argc == 0 { - return p.Spam__SWIG_0() - } - if argc == 1 { - if _, ok := a[0].(Bar); !ok { - goto check_2 - } - return p.Spam__SWIG_6(a[0].(Bar)) - } -check_2: - if argc == 1 { - if _, ok := a[0].(int); !ok { - goto check_3 - } - return p.Spam__SWIG_2(a[0].(int)) - } -check_3: - if argc == 1 { - return p.Spam__SWIG_1(a[0].(string)) - } - if argc == 2 { - if _, ok := a[0].(Bar); !ok { - goto check_5 - } - if _, ok := a[1].(float64); !ok { - goto check_5 - } - return p.Spam__SWIG_5(a[0].(Bar), a[1].(float64)) - } -check_5: - if argc == 2 { - return p.Spam__SWIG_3(a[0].(int), a[1].(int)) - } - if argc == 3 { - return p.Spam__SWIG_4(a[0].(int), a[1].(int), a[2].(int)) - } - panic("No match for overloaded function call") -} - -type Bar interface { - Swigcptr() uintptr - SwigIsBar() - Spam(a ...interface{}) int -} - -type SwigcptrFooTi uintptr - -func (p SwigcptrFooTi) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrFooTi) SwigIsFooTi() { -} - -var _wrap_new_FooTi__SWIG_0 unsafe.Pointer - -func _swig_wrap_new_FooTi__SWIG_0() (base SwigcptrFooTi) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_FooTi__SWIG_0, _swig_p) - return -} - -func NewFooTi__SWIG_0() (_swig_ret FooTi) { - return _swig_wrap_new_FooTi__SWIG_0() -} - -var _wrap_new_FooTi__SWIG_1 unsafe.Pointer - -func _swig_wrap_new_FooTi__SWIG_1(base int, _ int) (_ SwigcptrFooTi) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_FooTi__SWIG_1, _swig_p) - return -} - -func NewFooTi__SWIG_1(arg1 int, arg2 int) (_swig_ret FooTi) { - return _swig_wrap_new_FooTi__SWIG_1(arg1, arg2) -} - -var _wrap_FooTi_spam__SWIG_0 unsafe.Pointer - -func _swig_wrap_FooTi_spam__SWIG_0(base SwigcptrFooTi) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_FooTi_spam__SWIG_0, _swig_p) - return -} - -func (arg1 SwigcptrFooTi) Spam__SWIG_0() (_swig_ret int) { - return _swig_wrap_FooTi_spam__SWIG_0(arg1) -} - -var _wrap_FooTi_spam__SWIG_1 unsafe.Pointer - -func _swig_wrap_FooTi_spam__SWIG_1(base SwigcptrFooTi, _ string) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_FooTi_spam__SWIG_1, _swig_p) - return -} - -func (arg1 SwigcptrFooTi) Spam__SWIG_1(arg2 string) (_swig_ret int) { - return _swig_wrap_FooTi_spam__SWIG_1(arg1, arg2) -} - -var _wrap_new_FooTi__SWIG_2 unsafe.Pointer - -func _swig_wrap_new_FooTi__SWIG_2(base int) (_ SwigcptrFooTi) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_FooTi__SWIG_2, _swig_p) - return -} - -func NewFooTi__SWIG_2(arg1 int) (_swig_ret FooTi) { - return _swig_wrap_new_FooTi__SWIG_2(arg1) -} - -func NewFooTi(a ...interface{}) FooTi { - argc := len(a) - if argc == 0 { - return NewFooTi__SWIG_0() - } - if argc == 1 { - return NewFooTi__SWIG_2(a[0].(int)) - } - if argc == 2 { - return NewFooTi__SWIG_1(a[0].(int), a[1].(int)) - } - panic("No match for overloaded function call") -} - -var _wrap_delete_FooTi unsafe.Pointer - -func _swig_wrap_delete_FooTi(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_FooTi, _swig_p) - return -} - -func DeleteFooTi(arg1 FooTi) { - _swig_wrap_delete_FooTi(arg1.Swigcptr()) -} - -var _wrap_FooTi_spam__SWIG_2 unsafe.Pointer - -func _swig_wrap_FooTi_spam__SWIG_2(base SwigcptrFooTi, _ int) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_FooTi_spam__SWIG_2, _swig_p) - return -} - -func (arg1 SwigcptrFooTi) Spam__SWIG_2(arg2 int) (_swig_ret int) { - return _swig_wrap_FooTi_spam__SWIG_2(arg1, arg2) -} - -var _wrap_FooTi_spam__SWIG_3 unsafe.Pointer - -func _swig_wrap_FooTi_spam__SWIG_3(base SwigcptrFooTi, _ int, _ int) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_FooTi_spam__SWIG_3, _swig_p) - return -} - -func (arg1 SwigcptrFooTi) Spam__SWIG_3(arg2 int, arg3 int) (_swig_ret int) { - return _swig_wrap_FooTi_spam__SWIG_3(arg1, arg2, arg3) -} - -var _wrap_FooTi_spam__SWIG_4 unsafe.Pointer - -func _swig_wrap_FooTi_spam__SWIG_4(base SwigcptrFooTi, _ int, _ int, _ int) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_FooTi_spam__SWIG_4, _swig_p) - return -} - -func (arg1 SwigcptrFooTi) Spam__SWIG_4(arg2 int, arg3 int, arg4 int) (_swig_ret int) { - return _swig_wrap_FooTi_spam__SWIG_4(arg1, arg2, arg3, arg4) -} - -var _wrap_FooTi_spam__SWIG_5 unsafe.Pointer - -func _swig_wrap_FooTi_spam__SWIG_5(base SwigcptrFooTi, _ uintptr, _ float64) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_FooTi_spam__SWIG_5, _swig_p) - return -} - -func (arg1 SwigcptrFooTi) Spam__SWIG_5(arg2 Foo, arg3 float64) (_swig_ret int) { - return _swig_wrap_FooTi_spam__SWIG_5(arg1, arg2.Swigcptr(), arg3) -} - -var _wrap_FooTi_spam__SWIG_6 unsafe.Pointer - -func _swig_wrap_FooTi_spam__SWIG_6(base SwigcptrFooTi, _ uintptr) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_FooTi_spam__SWIG_6, _swig_p) - return -} - -func (arg1 SwigcptrFooTi) Spam__SWIG_6(arg2 Foo) (_swig_ret int) { - return _swig_wrap_FooTi_spam__SWIG_6(arg1, arg2.Swigcptr()) -} - -func (p SwigcptrFooTi) Spam(a ...interface{}) int { - argc := len(a) - if argc == 0 { - return p.Spam__SWIG_0() - } - if argc == 1 { - if _, ok := a[0].(Foo); !ok { - goto check_2 - } - return p.Spam__SWIG_6(a[0].(Foo)) - } -check_2: - if argc == 1 { - if _, ok := a[0].(int); !ok { - goto check_3 - } - return p.Spam__SWIG_2(a[0].(int)) - } -check_3: - if argc == 1 { - return p.Spam__SWIG_1(a[0].(string)) - } - if argc == 2 { - if _, ok := a[0].(Foo); !ok { - goto check_5 - } - if _, ok := a[1].(float64); !ok { - goto check_5 - } - return p.Spam__SWIG_5(a[0].(Foo), a[1].(float64)) - } -check_5: - if argc == 2 { - return p.Spam__SWIG_3(a[0].(int), a[1].(int)) - } - if argc == 3 { - return p.Spam__SWIG_4(a[0].(int), a[1].(int), a[2].(int)) - } - panic("No match for overloaded function call") -} - -type FooTi interface { - Swigcptr() uintptr - SwigIsFooTi() - Spam(a ...interface{}) int -} - -type SwigcptrBarTi uintptr - -func (p SwigcptrBarTi) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrBarTi) SwigIsBarTi() { -} - -var _wrap_new_BarTi__SWIG_0 unsafe.Pointer - -func _swig_wrap_new_BarTi__SWIG_0() (base SwigcptrBarTi) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_BarTi__SWIG_0, _swig_p) - return -} - -func NewBarTi__SWIG_0() (_swig_ret BarTi) { - return _swig_wrap_new_BarTi__SWIG_0() -} - -var _wrap_BarTi_spam__SWIG_0 unsafe.Pointer - -func _swig_wrap_BarTi_spam__SWIG_0(base SwigcptrBarTi) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_BarTi_spam__SWIG_0, _swig_p) - return -} - -func (arg1 SwigcptrBarTi) Spam__SWIG_0() (_swig_ret int) { - return _swig_wrap_BarTi_spam__SWIG_0(arg1) -} - -var _wrap_BarTi_spam__SWIG_1 unsafe.Pointer - -func _swig_wrap_BarTi_spam__SWIG_1(base SwigcptrBarTi, _ string) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_BarTi_spam__SWIG_1, _swig_p) - return -} - -func (arg1 SwigcptrBarTi) Spam__SWIG_1(arg2 string) (_swig_ret int) { - return _swig_wrap_BarTi_spam__SWIG_1(arg1, arg2) -} - -var _wrap_new_BarTi__SWIG_1 unsafe.Pointer - -func _swig_wrap_new_BarTi__SWIG_1(base int) (_ SwigcptrBarTi) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_BarTi__SWIG_1, _swig_p) - return -} - -func NewBarTi__SWIG_1(arg1 int) (_swig_ret BarTi) { - return _swig_wrap_new_BarTi__SWIG_1(arg1) -} - -func NewBarTi(a ...interface{}) BarTi { - argc := len(a) - if argc == 0 { - return NewBarTi__SWIG_0() - } - if argc == 1 { - return NewBarTi__SWIG_1(a[0].(int)) - } - panic("No match for overloaded function call") -} - -var _wrap_delete_BarTi unsafe.Pointer - -func _swig_wrap_delete_BarTi(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_BarTi, _swig_p) - return -} - -func DeleteBarTi(arg1 BarTi) { - _swig_wrap_delete_BarTi(arg1.Swigcptr()) -} - -var _wrap_BarTi_spam__SWIG_2 unsafe.Pointer - -func _swig_wrap_BarTi_spam__SWIG_2(base SwigcptrBarTi, _ int) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_BarTi_spam__SWIG_2, _swig_p) - return -} - -func (arg1 SwigcptrBarTi) Spam__SWIG_2(arg2 int) (_swig_ret int) { - return _swig_wrap_BarTi_spam__SWIG_2(arg1, arg2) -} - -var _wrap_BarTi_spam__SWIG_3 unsafe.Pointer - -func _swig_wrap_BarTi_spam__SWIG_3(base SwigcptrBarTi, _ int, _ int) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_BarTi_spam__SWIG_3, _swig_p) - return -} - -func (arg1 SwigcptrBarTi) Spam__SWIG_3(arg2 int, arg3 int) (_swig_ret int) { - return _swig_wrap_BarTi_spam__SWIG_3(arg1, arg2, arg3) -} - -var _wrap_BarTi_spam__SWIG_4 unsafe.Pointer - -func _swig_wrap_BarTi_spam__SWIG_4(base SwigcptrBarTi, _ int, _ int, _ int) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_BarTi_spam__SWIG_4, _swig_p) - return -} - -func (arg1 SwigcptrBarTi) Spam__SWIG_4(arg2 int, arg3 int, arg4 int) (_swig_ret int) { - return _swig_wrap_BarTi_spam__SWIG_4(arg1, arg2, arg3, arg4) -} - -var _wrap_BarTi_spam__SWIG_5 unsafe.Pointer - -func _swig_wrap_BarTi_spam__SWIG_5(base SwigcptrBarTi, _ uintptr, _ float64) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_BarTi_spam__SWIG_5, _swig_p) - return -} - -func (arg1 SwigcptrBarTi) Spam__SWIG_5(arg2 Bar, arg3 float64) (_swig_ret int) { - return _swig_wrap_BarTi_spam__SWIG_5(arg1, arg2.Swigcptr(), arg3) -} - -var _wrap_BarTi_spam__SWIG_6 unsafe.Pointer - -func _swig_wrap_BarTi_spam__SWIG_6(base SwigcptrBarTi, _ uintptr) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_BarTi_spam__SWIG_6, _swig_p) - return -} - -func (arg1 SwigcptrBarTi) Spam__SWIG_6(arg2 Bar) (_swig_ret int) { - return _swig_wrap_BarTi_spam__SWIG_6(arg1, arg2.Swigcptr()) -} - -func (p SwigcptrBarTi) Spam(a ...interface{}) int { - argc := len(a) - if argc == 0 { - return p.Spam__SWIG_0() - } - if argc == 1 { - if _, ok := a[0].(Bar); !ok { - goto check_2 - } - return p.Spam__SWIG_6(a[0].(Bar)) - } -check_2: - if argc == 1 { - if _, ok := a[0].(int); !ok { - goto check_3 - } - return p.Spam__SWIG_2(a[0].(int)) - } -check_3: - if argc == 1 { - return p.Spam__SWIG_1(a[0].(string)) - } - if argc == 2 { - if _, ok := a[0].(Bar); !ok { - goto check_5 - } - if _, ok := a[1].(float64); !ok { - goto check_5 - } - return p.Spam__SWIG_5(a[0].(Bar), a[1].(float64)) - } -check_5: - if argc == 2 { - return p.Spam__SWIG_3(a[0].(int), a[1].(int)) - } - if argc == 3 { - return p.Spam__SWIG_4(a[0].(int), a[1].(int), a[2].(int)) - } - panic("No match for overloaded function call") -} - -type BarTi interface { - Swigcptr() uintptr - SwigIsBarTi() - Spam(a ...interface{}) int -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/extend_placement_runme b/Examples/test-suite/go/extend_placement_runme deleted file mode 100755 index a209ef272..000000000 Binary files a/Examples/test-suite/go/extend_placement_runme and /dev/null differ diff --git a/Examples/test-suite/go/extend_special_variables.go b/Examples/test-suite/go/extend_special_variables.go deleted file mode 100644 index dc3357e4a..000000000 --- a/Examples/test-suite/go/extend_special_variables.go +++ /dev/null @@ -1,162 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../extend_special_variables.i - -package extend_special_variables - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrForExtensionNewName uintptr - -func (p SwigcptrForExtensionNewName) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrForExtensionNewName) SwigIsForExtensionNewName() { -} - -var _wrap_new_ForExtensionNewName unsafe.Pointer - -func _swig_wrap_new_ForExtensionNewName() (base SwigcptrForExtensionNewName) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_ForExtensionNewName, _swig_p) - return -} - -func NewForExtensionNewName() (_swig_ret ForExtensionNewName) { - return _swig_wrap_new_ForExtensionNewName() -} - -var _wrap_ForExtensionNewName_extended_renamed__SWIG_0 unsafe.Pointer - -func _swig_wrap_ForExtensionNewName_extended_renamed__SWIG_0(base SwigcptrForExtensionNewName) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_ForExtensionNewName_extended_renamed__SWIG_0, _swig_p) - return -} - -func (arg1 SwigcptrForExtensionNewName) Extended_renamed__SWIG_0() (_swig_ret string) { - return _swig_wrap_ForExtensionNewName_extended_renamed__SWIG_0(arg1) -} - -var _wrap_ForExtensionNewName_extended_renamed__SWIG_1 unsafe.Pointer - -func _swig_wrap_ForExtensionNewName_extended_renamed__SWIG_1(base SwigcptrForExtensionNewName, _ int) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_ForExtensionNewName_extended_renamed__SWIG_1, _swig_p) - return -} - -func (arg1 SwigcptrForExtensionNewName) Extended_renamed__SWIG_1(arg2 int) (_swig_ret string) { - return _swig_wrap_ForExtensionNewName_extended_renamed__SWIG_1(arg1, arg2) -} - -func (p SwigcptrForExtensionNewName) Extended_renamed(a ...interface{}) string { - argc := len(a) - if argc == 0 { - return p.Extended_renamed__SWIG_0() - } - if argc == 1 { - return p.Extended_renamed__SWIG_1(a[0].(int)) - } - panic("No match for overloaded function call") -} - -var _wrap_delete_ForExtensionNewName unsafe.Pointer - -func _swig_wrap_delete_ForExtensionNewName(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_ForExtensionNewName, _swig_p) - return -} - -func DeleteForExtensionNewName(arg1 ForExtensionNewName) { - _swig_wrap_delete_ForExtensionNewName(arg1.Swigcptr()) -} - -type ForExtensionNewName interface { - Swigcptr() uintptr - SwigIsForExtensionNewName() - Extended_renamed(a ...interface{}) string -} - -type SwigcptrExtendTemplateInt uintptr - -func (p SwigcptrExtendTemplateInt) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrExtendTemplateInt) SwigIsExtendTemplateInt() { -} - -var _wrap_ExtendTemplateInt_extending unsafe.Pointer - -func _swig_wrap_ExtendTemplateInt_extending(base SwigcptrExtendTemplateInt) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_ExtendTemplateInt_extending, _swig_p) - return -} - -func (arg1 SwigcptrExtendTemplateInt) Extending() { - _swig_wrap_ExtendTemplateInt_extending(arg1) -} - -var _wrap_new_ExtendTemplateInt unsafe.Pointer - -func _swig_wrap_new_ExtendTemplateInt() (base SwigcptrExtendTemplateInt) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_ExtendTemplateInt, _swig_p) - return -} - -func NewExtendTemplateInt() (_swig_ret ExtendTemplateInt) { - return _swig_wrap_new_ExtendTemplateInt() -} - -var _wrap_delete_ExtendTemplateInt unsafe.Pointer - -func _swig_wrap_delete_ExtendTemplateInt(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_ExtendTemplateInt, _swig_p) - return -} - -func DeleteExtendTemplateInt(arg1 ExtendTemplateInt) { - _swig_wrap_delete_ExtendTemplateInt(arg1.Swigcptr()) -} - -type ExtendTemplateInt interface { - Swigcptr() uintptr - SwigIsExtendTemplateInt() - Extending() -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/extend_template.go b/Examples/test-suite/go/extend_template.go deleted file mode 100644 index b127a06f4..000000000 --- a/Examples/test-suite/go/extend_template.go +++ /dev/null @@ -1,101 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../extend_template.i - -package extend_template - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrFoo_0 uintptr - -func (p SwigcptrFoo_0) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrFoo_0) SwigIsFoo_0() { -} - -var _wrap_Foo_0_test1 unsafe.Pointer - -func _swig_wrap_Foo_0_test1(base SwigcptrFoo_0, _ int) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_0_test1, _swig_p) - return -} - -func (arg1 SwigcptrFoo_0) Test1(arg2 int) (_swig_ret int) { - return _swig_wrap_Foo_0_test1(arg1, arg2) -} - -var _wrap_Foo_0_test2 unsafe.Pointer - -func _swig_wrap_Foo_0_test2(base SwigcptrFoo_0, _ int) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_0_test2, _swig_p) - return -} - -func (arg1 SwigcptrFoo_0) Test2(arg2 int) (_swig_ret int) { - return _swig_wrap_Foo_0_test2(arg1, arg2) -} - -var _wrap_new_Foo_0 unsafe.Pointer - -func _swig_wrap_new_Foo_0() (base SwigcptrFoo_0) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Foo_0, _swig_p) - return -} - -func NewFoo_0() (_swig_ret Foo_0) { - return _swig_wrap_new_Foo_0() -} - -var _wrap_delete_Foo_0 unsafe.Pointer - -func _swig_wrap_delete_Foo_0(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Foo_0, _swig_p) - return -} - -func DeleteFoo_0(arg1 Foo_0) { - _swig_wrap_delete_Foo_0(arg1.Swigcptr()) -} - -type Foo_0 interface { - Swigcptr() uintptr - SwigIsFoo_0() - Test1(arg2 int) (_swig_ret int) - Test2(arg2 int) (_swig_ret int) -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/extend_template_ns.go b/Examples/test-suite/go/extend_template_ns.go deleted file mode 100644 index 5e1a0331c..000000000 --- a/Examples/test-suite/go/extend_template_ns.go +++ /dev/null @@ -1,118 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../extend_template_ns.i - -package extend_template_ns - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type OssTest int -var _wrap_One unsafe.Pointer - -func _swig_getOne() (_swig_ret OssTest) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_One, _swig_p) - return -} -var One OssTest = _swig_getOne() -var _wrap_Two unsafe.Pointer - -func _swig_getTwo() (_swig_ret OssTest) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_Two, _swig_p) - return -} -var Two OssTest = _swig_getTwo() -type SwigcptrFoo_One uintptr - -func (p SwigcptrFoo_One) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrFoo_One) SwigIsFoo_One() { -} - -var _wrap_Foo_One_test1 unsafe.Pointer - -func _swig_wrap_Foo_One_test1(base SwigcptrFoo_One, _ int) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_One_test1, _swig_p) - return -} - -func (arg1 SwigcptrFoo_One) Test1(arg2 int) (_swig_ret int) { - return _swig_wrap_Foo_One_test1(arg1, arg2) -} - -var _wrap_Foo_One_test2 unsafe.Pointer - -func _swig_wrap_Foo_One_test2(base SwigcptrFoo_One, _ int) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_One_test2, _swig_p) - return -} - -func (arg1 SwigcptrFoo_One) Test2(arg2 int) (_swig_ret int) { - return _swig_wrap_Foo_One_test2(arg1, arg2) -} - -var _wrap_new_Foo_One unsafe.Pointer - -func _swig_wrap_new_Foo_One() (base SwigcptrFoo_One) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Foo_One, _swig_p) - return -} - -func NewFoo_One() (_swig_ret Foo_One) { - return _swig_wrap_new_Foo_One() -} - -var _wrap_delete_Foo_One unsafe.Pointer - -func _swig_wrap_delete_Foo_One(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Foo_One, _swig_p) - return -} - -func DeleteFoo_One(arg1 Foo_One) { - _swig_wrap_delete_Foo_One(arg1.Swigcptr()) -} - -type Foo_One interface { - Swigcptr() uintptr - SwigIsFoo_One() - Test1(arg2 int) (_swig_ret int) - Test2(arg2 int) (_swig_ret int) -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/extend_template_ns_runme b/Examples/test-suite/go/extend_template_ns_runme deleted file mode 100755 index 828a6d988..000000000 Binary files a/Examples/test-suite/go/extend_template_ns_runme and /dev/null differ diff --git a/Examples/test-suite/go/extend_template_runme b/Examples/test-suite/go/extend_template_runme deleted file mode 100755 index df5539670..000000000 Binary files a/Examples/test-suite/go/extend_template_runme and /dev/null differ diff --git a/Examples/test-suite/go/extend_typedef_class.go b/Examples/test-suite/go/extend_typedef_class.go deleted file mode 100644 index 58d10d5c7..000000000 --- a/Examples/test-suite/go/extend_typedef_class.go +++ /dev/null @@ -1,653 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../extend_typedef_class.i - -package extend_typedef_class - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrAClass uintptr - -func (p SwigcptrAClass) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrAClass) SwigIsAClass() { -} - -var _wrap_AClass_membervar_set unsafe.Pointer - -func _swig_wrap_AClass_membervar_set(base SwigcptrAClass, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_AClass_membervar_set, _swig_p) - return -} - -func (arg1 SwigcptrAClass) SetMembervar(arg2 int) { - _swig_wrap_AClass_membervar_set(arg1, arg2) -} - -var _wrap_AClass_membervar_get unsafe.Pointer - -func _swig_wrap_AClass_membervar_get(base SwigcptrAClass) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_AClass_membervar_get, _swig_p) - return -} - -func (arg1 SwigcptrAClass) GetMembervar() (_swig_ret int) { - return _swig_wrap_AClass_membervar_get(arg1) -} - -var _wrap_AClass_getvar unsafe.Pointer - -func _swig_wrap_AClass_getvar(base SwigcptrAClass) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_AClass_getvar, _swig_p) - return -} - -func (arg1 SwigcptrAClass) Getvar() (_swig_ret int) { - return _swig_wrap_AClass_getvar(arg1) -} - -var _wrap_new_AClass unsafe.Pointer - -func _swig_wrap_new_AClass() (base SwigcptrAClass) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_AClass, _swig_p) - return -} - -func NewAClass() (_swig_ret AClass) { - return _swig_wrap_new_AClass() -} - -var _wrap_delete_AClass unsafe.Pointer - -func _swig_wrap_delete_AClass(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_AClass, _swig_p) - return -} - -func DeleteAClass(arg1 AClass) { - _swig_wrap_delete_AClass(arg1.Swigcptr()) -} - -type AClass interface { - Swigcptr() uintptr - SwigIsAClass() - SetMembervar(arg2 int) - GetMembervar() (_swig_ret int) - Getvar() (_swig_ret int) -} - -type SwigcptrBClass uintptr - -func (p SwigcptrBClass) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrBClass) SwigIsBClass() { -} - -var _wrap_BClass_membervar_set unsafe.Pointer - -func _swig_wrap_BClass_membervar_set(base SwigcptrBClass, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_BClass_membervar_set, _swig_p) - return -} - -func (arg1 SwigcptrBClass) SetMembervar(arg2 int) { - _swig_wrap_BClass_membervar_set(arg1, arg2) -} - -var _wrap_BClass_membervar_get unsafe.Pointer - -func _swig_wrap_BClass_membervar_get(base SwigcptrBClass) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_BClass_membervar_get, _swig_p) - return -} - -func (arg1 SwigcptrBClass) GetMembervar() (_swig_ret int) { - return _swig_wrap_BClass_membervar_get(arg1) -} - -var _wrap_BClass_getvar unsafe.Pointer - -func _swig_wrap_BClass_getvar(base SwigcptrBClass) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_BClass_getvar, _swig_p) - return -} - -func (arg1 SwigcptrBClass) Getvar() (_swig_ret int) { - return _swig_wrap_BClass_getvar(arg1) -} - -var _wrap_new_BClass unsafe.Pointer - -func _swig_wrap_new_BClass() (base SwigcptrBClass) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_BClass, _swig_p) - return -} - -func NewBClass() (_swig_ret BClass) { - return _swig_wrap_new_BClass() -} - -var _wrap_delete_BClass unsafe.Pointer - -func _swig_wrap_delete_BClass(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_BClass, _swig_p) - return -} - -func DeleteBClass(arg1 BClass) { - _swig_wrap_delete_BClass(arg1.Swigcptr()) -} - -type BClass interface { - Swigcptr() uintptr - SwigIsBClass() - SetMembervar(arg2 int) - GetMembervar() (_swig_ret int) - Getvar() (_swig_ret int) -} - -type SwigcptrCClass uintptr - -func (p SwigcptrCClass) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrCClass) SwigIsCClass() { -} - -var _wrap_CClass_membervar_set unsafe.Pointer - -func _swig_wrap_CClass_membervar_set(base SwigcptrCClass, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_CClass_membervar_set, _swig_p) - return -} - -func (arg1 SwigcptrCClass) SetMembervar(arg2 int) { - _swig_wrap_CClass_membervar_set(arg1, arg2) -} - -var _wrap_CClass_membervar_get unsafe.Pointer - -func _swig_wrap_CClass_membervar_get(base SwigcptrCClass) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_CClass_membervar_get, _swig_p) - return -} - -func (arg1 SwigcptrCClass) GetMembervar() (_swig_ret int) { - return _swig_wrap_CClass_membervar_get(arg1) -} - -var _wrap_CClass_getvar unsafe.Pointer - -func _swig_wrap_CClass_getvar(base SwigcptrCClass) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_CClass_getvar, _swig_p) - return -} - -func (arg1 SwigcptrCClass) Getvar() (_swig_ret int) { - return _swig_wrap_CClass_getvar(arg1) -} - -var _wrap_new_CClass unsafe.Pointer - -func _swig_wrap_new_CClass() (base SwigcptrCClass) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_CClass, _swig_p) - return -} - -func NewCClass() (_swig_ret CClass) { - return _swig_wrap_new_CClass() -} - -var _wrap_delete_CClass unsafe.Pointer - -func _swig_wrap_delete_CClass(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_CClass, _swig_p) - return -} - -func DeleteCClass(arg1 CClass) { - _swig_wrap_delete_CClass(arg1.Swigcptr()) -} - -type CClass interface { - Swigcptr() uintptr - SwigIsCClass() - SetMembervar(arg2 int) - GetMembervar() (_swig_ret int) - Getvar() (_swig_ret int) -} - -type SwigcptrDClass uintptr - -func (p SwigcptrDClass) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrDClass) SwigIsDClass() { -} - -var _wrap_DClass_membervar_set unsafe.Pointer - -func _swig_wrap_DClass_membervar_set(base SwigcptrDClass, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_DClass_membervar_set, _swig_p) - return -} - -func (arg1 SwigcptrDClass) SetMembervar(arg2 int) { - _swig_wrap_DClass_membervar_set(arg1, arg2) -} - -var _wrap_DClass_membervar_get unsafe.Pointer - -func _swig_wrap_DClass_membervar_get(base SwigcptrDClass) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_DClass_membervar_get, _swig_p) - return -} - -func (arg1 SwigcptrDClass) GetMembervar() (_swig_ret int) { - return _swig_wrap_DClass_membervar_get(arg1) -} - -var _wrap_DClass_getvar unsafe.Pointer - -func _swig_wrap_DClass_getvar(base SwigcptrDClass) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_DClass_getvar, _swig_p) - return -} - -func (arg1 SwigcptrDClass) Getvar() (_swig_ret int) { - return _swig_wrap_DClass_getvar(arg1) -} - -var _wrap_new_DClass unsafe.Pointer - -func _swig_wrap_new_DClass() (base SwigcptrDClass) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_DClass, _swig_p) - return -} - -func NewDClass() (_swig_ret DClass) { - return _swig_wrap_new_DClass() -} - -var _wrap_delete_DClass unsafe.Pointer - -func _swig_wrap_delete_DClass(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_DClass, _swig_p) - return -} - -func DeleteDClass(arg1 DClass) { - _swig_wrap_delete_DClass(arg1.Swigcptr()) -} - -type DClass interface { - Swigcptr() uintptr - SwigIsDClass() - SetMembervar(arg2 int) - GetMembervar() (_swig_ret int) - Getvar() (_swig_ret int) -} - -type SwigcptrAStruct uintptr - -func (p SwigcptrAStruct) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrAStruct) SwigIsAStruct() { -} - -var _wrap_AStruct_membervar_set unsafe.Pointer - -func _swig_wrap_AStruct_membervar_set(base SwigcptrAStruct, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_AStruct_membervar_set, _swig_p) - return -} - -func (arg1 SwigcptrAStruct) SetMembervar(arg2 int) { - _swig_wrap_AStruct_membervar_set(arg1, arg2) -} - -var _wrap_AStruct_membervar_get unsafe.Pointer - -func _swig_wrap_AStruct_membervar_get(base SwigcptrAStruct) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_AStruct_membervar_get, _swig_p) - return -} - -func (arg1 SwigcptrAStruct) GetMembervar() (_swig_ret int) { - return _swig_wrap_AStruct_membervar_get(arg1) -} - -var _wrap_AStruct_getvar unsafe.Pointer - -func _swig_wrap_AStruct_getvar(base SwigcptrAStruct) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_AStruct_getvar, _swig_p) - return -} - -func (arg1 SwigcptrAStruct) Getvar() (_swig_ret int) { - return _swig_wrap_AStruct_getvar(arg1) -} - -var _wrap_new_AStruct unsafe.Pointer - -func _swig_wrap_new_AStruct() (base SwigcptrAStruct) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_AStruct, _swig_p) - return -} - -func NewAStruct() (_swig_ret AStruct) { - return _swig_wrap_new_AStruct() -} - -var _wrap_delete_AStruct unsafe.Pointer - -func _swig_wrap_delete_AStruct(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_AStruct, _swig_p) - return -} - -func DeleteAStruct(arg1 AStruct) { - _swig_wrap_delete_AStruct(arg1.Swigcptr()) -} - -type AStruct interface { - Swigcptr() uintptr - SwigIsAStruct() - SetMembervar(arg2 int) - GetMembervar() (_swig_ret int) - Getvar() (_swig_ret int) -} - -type SwigcptrBStruct uintptr - -func (p SwigcptrBStruct) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrBStruct) SwigIsBStruct() { -} - -var _wrap_BStruct_membervar_set unsafe.Pointer - -func _swig_wrap_BStruct_membervar_set(base SwigcptrBStruct, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_BStruct_membervar_set, _swig_p) - return -} - -func (arg1 SwigcptrBStruct) SetMembervar(arg2 int) { - _swig_wrap_BStruct_membervar_set(arg1, arg2) -} - -var _wrap_BStruct_membervar_get unsafe.Pointer - -func _swig_wrap_BStruct_membervar_get(base SwigcptrBStruct) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_BStruct_membervar_get, _swig_p) - return -} - -func (arg1 SwigcptrBStruct) GetMembervar() (_swig_ret int) { - return _swig_wrap_BStruct_membervar_get(arg1) -} - -var _wrap_BStruct_getvar unsafe.Pointer - -func _swig_wrap_BStruct_getvar(base SwigcptrBStruct) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_BStruct_getvar, _swig_p) - return -} - -func (arg1 SwigcptrBStruct) Getvar() (_swig_ret int) { - return _swig_wrap_BStruct_getvar(arg1) -} - -var _wrap_new_BStruct unsafe.Pointer - -func _swig_wrap_new_BStruct() (base SwigcptrBStruct) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_BStruct, _swig_p) - return -} - -func NewBStruct() (_swig_ret BStruct) { - return _swig_wrap_new_BStruct() -} - -var _wrap_delete_BStruct unsafe.Pointer - -func _swig_wrap_delete_BStruct(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_BStruct, _swig_p) - return -} - -func DeleteBStruct(arg1 BStruct) { - _swig_wrap_delete_BStruct(arg1.Swigcptr()) -} - -type BStruct interface { - Swigcptr() uintptr - SwigIsBStruct() - SetMembervar(arg2 int) - GetMembervar() (_swig_ret int) - Getvar() (_swig_ret int) -} - -type SwigcptrCStruct uintptr - -func (p SwigcptrCStruct) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrCStruct) SwigIsCStruct() { -} - -var _wrap_CStruct_membervar_set unsafe.Pointer - -func _swig_wrap_CStruct_membervar_set(base SwigcptrCStruct, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_CStruct_membervar_set, _swig_p) - return -} - -func (arg1 SwigcptrCStruct) SetMembervar(arg2 int) { - _swig_wrap_CStruct_membervar_set(arg1, arg2) -} - -var _wrap_CStruct_membervar_get unsafe.Pointer - -func _swig_wrap_CStruct_membervar_get(base SwigcptrCStruct) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_CStruct_membervar_get, _swig_p) - return -} - -func (arg1 SwigcptrCStruct) GetMembervar() (_swig_ret int) { - return _swig_wrap_CStruct_membervar_get(arg1) -} - -var _wrap_CStruct_getvar unsafe.Pointer - -func _swig_wrap_CStruct_getvar(base SwigcptrCStruct) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_CStruct_getvar, _swig_p) - return -} - -func (arg1 SwigcptrCStruct) Getvar() (_swig_ret int) { - return _swig_wrap_CStruct_getvar(arg1) -} - -var _wrap_new_CStruct unsafe.Pointer - -func _swig_wrap_new_CStruct() (base SwigcptrCStruct) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_CStruct, _swig_p) - return -} - -func NewCStruct() (_swig_ret CStruct) { - return _swig_wrap_new_CStruct() -} - -var _wrap_delete_CStruct unsafe.Pointer - -func _swig_wrap_delete_CStruct(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_CStruct, _swig_p) - return -} - -func DeleteCStruct(arg1 CStruct) { - _swig_wrap_delete_CStruct(arg1.Swigcptr()) -} - -type CStruct interface { - Swigcptr() uintptr - SwigIsCStruct() - SetMembervar(arg2 int) - GetMembervar() (_swig_ret int) - Getvar() (_swig_ret int) -} - -type SwigcptrDStruct uintptr - -func (p SwigcptrDStruct) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrDStruct) SwigIsDStruct() { -} - -var _wrap_DStruct_membervar_set unsafe.Pointer - -func _swig_wrap_DStruct_membervar_set(base SwigcptrDStruct, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_DStruct_membervar_set, _swig_p) - return -} - -func (arg1 SwigcptrDStruct) SetMembervar(arg2 int) { - _swig_wrap_DStruct_membervar_set(arg1, arg2) -} - -var _wrap_DStruct_membervar_get unsafe.Pointer - -func _swig_wrap_DStruct_membervar_get(base SwigcptrDStruct) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_DStruct_membervar_get, _swig_p) - return -} - -func (arg1 SwigcptrDStruct) GetMembervar() (_swig_ret int) { - return _swig_wrap_DStruct_membervar_get(arg1) -} - -var _wrap_DStruct_getvar unsafe.Pointer - -func _swig_wrap_DStruct_getvar(base SwigcptrDStruct) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_DStruct_getvar, _swig_p) - return -} - -func (arg1 SwigcptrDStruct) Getvar() (_swig_ret int) { - return _swig_wrap_DStruct_getvar(arg1) -} - -var _wrap_new_DStruct unsafe.Pointer - -func _swig_wrap_new_DStruct() (base SwigcptrDStruct) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_DStruct, _swig_p) - return -} - -func NewDStruct() (_swig_ret DStruct) { - return _swig_wrap_new_DStruct() -} - -var _wrap_delete_DStruct unsafe.Pointer - -func _swig_wrap_delete_DStruct(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_DStruct, _swig_p) - return -} - -func DeleteDStruct(arg1 DStruct) { - _swig_wrap_delete_DStruct(arg1.Swigcptr()) -} - -type DStruct interface { - Swigcptr() uintptr - SwigIsDStruct() - SetMembervar(arg2 int) - GetMembervar() (_swig_ret int) - Getvar() (_swig_ret int) -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/extern_c.go b/Examples/test-suite/go/extern_c.go deleted file mode 100644 index cbb1324f8..000000000 --- a/Examples/test-suite/go/extern_c.go +++ /dev/null @@ -1,49 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../extern_c.i - -package extern_c - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -var _wrap_RealFunction unsafe.Pointer - -func _swig_wrap_RealFunction(base int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_RealFunction, _swig_p) - return -} - -func RealFunction(arg1 int) { - _swig_wrap_RealFunction(arg1) -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/extern_c_runme b/Examples/test-suite/go/extern_c_runme deleted file mode 100755 index 8eff8fd84..000000000 Binary files a/Examples/test-suite/go/extern_c_runme and /dev/null differ diff --git a/Examples/test-suite/go/extern_declaration.go b/Examples/test-suite/go/extern_declaration.go deleted file mode 100644 index 6a591d4d4..000000000 --- a/Examples/test-suite/go/extern_declaration.go +++ /dev/null @@ -1,50 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../extern_declaration.i - -package extern_declaration - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -var _wrap_externimport unsafe.Pointer - -func Externimport(arg1 int) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_externimport, _swig_p) - return -} -var _wrap_externexport unsafe.Pointer - -func Externexport(arg1 int) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_externexport, _swig_p) - return -} -var _wrap_externstdcall unsafe.Pointer - -func Externstdcall(arg1 int) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_externstdcall, _swig_p) - return -} - diff --git a/Examples/test-suite/go/extern_namespace.go b/Examples/test-suite/go/extern_namespace.go deleted file mode 100644 index 0ceeca9c8..000000000 --- a/Examples/test-suite/go/extern_namespace.go +++ /dev/null @@ -1,61 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../extern_namespace.i - -package extern_namespace - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -var _wrap_bar__SWIG_0 unsafe.Pointer - -func Bar__SWIG_0(arg1 int) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_bar__SWIG_0, _swig_p) - return -} -var _wrap_bar__SWIG_1 unsafe.Pointer - -func Bar__SWIG_1() (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_bar__SWIG_1, _swig_p) - return -} -func Bar(a ...interface{}) int { - argc := len(a) - if argc == 0 { - return Bar__SWIG_1() - } - if argc == 1 { - return Bar__SWIG_0(a[0].(int)) - } - panic("No match for overloaded function call") -} - -var _wrap_foobar unsafe.Pointer - -func Foobar(arg1 int) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_foobar, _swig_p) - return -} - diff --git a/Examples/test-suite/go/extern_throws.go b/Examples/test-suite/go/extern_throws.go deleted file mode 100644 index 10dd17c77..000000000 --- a/Examples/test-suite/go/extern_throws.go +++ /dev/null @@ -1,36 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../extern_throws.i - -package extern_throws - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -var _wrap_get unsafe.Pointer - -func Get() (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_get, _swig_p) - return -} - diff --git a/Examples/test-suite/go/features.go b/Examples/test-suite/go/features.go deleted file mode 100644 index 9d2ee19d9..000000000 --- a/Examples/test-suite/go/features.go +++ /dev/null @@ -1,834 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../features.i - -package features - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrSimple uintptr - -func (p SwigcptrSimple) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrSimple) SwigIsSimple() { -} - -var _wrap_new_Simple unsafe.Pointer - -func _swig_wrap_new_Simple() (base SwigcptrSimple) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Simple, _swig_p) - return -} - -func NewSimple() (_swig_ret Simple) { - return _swig_wrap_new_Simple() -} - -var _wrap_delete_Simple unsafe.Pointer - -func _swig_wrap_delete_Simple(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Simple, _swig_p) - return -} - -func DeleteSimple(arg1 Simple) { - _swig_wrap_delete_Simple(arg1.Swigcptr()) -} - -type Simple interface { - Swigcptr() uintptr - SwigIsSimple() -} - -type SwigcptrSimpleNS uintptr - -func (p SwigcptrSimpleNS) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrSimpleNS) SwigIsSimpleNS() { -} - -var _wrap_SimpleNS_method unsafe.Pointer - -func _swig_wrap_SimpleNS_method(base SwigcptrSimpleNS) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_SimpleNS_method, _swig_p) - return -} - -func (arg1 SwigcptrSimpleNS) Method() { - _swig_wrap_SimpleNS_method(arg1) -} - -var _wrap_SimpleNS_afunction unsafe.Pointer - -func _swig_wrap_SimpleNS_afunction(base SwigcptrSimpleNS) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_SimpleNS_afunction, _swig_p) - return -} - -func (arg1 SwigcptrSimpleNS) Afunction() { - _swig_wrap_SimpleNS_afunction(arg1) -} - -var _wrap_new_SimpleNS unsafe.Pointer - -func _swig_wrap_new_SimpleNS() (base SwigcptrSimpleNS) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_SimpleNS, _swig_p) - return -} - -func NewSimpleNS() (_swig_ret SimpleNS) { - return _swig_wrap_new_SimpleNS() -} - -var _wrap_delete_SimpleNS unsafe.Pointer - -func _swig_wrap_delete_SimpleNS(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_SimpleNS, _swig_p) - return -} - -func DeleteSimpleNS(arg1 SimpleNS) { - _swig_wrap_delete_SimpleNS(arg1.Swigcptr()) -} - -type SimpleNS interface { - Swigcptr() uintptr - SwigIsSimpleNS() - Method() - Afunction() -} - -var _wrap_FooBarInt unsafe.Pointer - -func _swig_wrap_FooBarInt(base int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_FooBarInt, _swig_p) - return -} - -func FooBarInt(arg1 int) { - _swig_wrap_FooBarInt(arg1) -} - -type SwigcptrSimpleInt uintptr - -func (p SwigcptrSimpleInt) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrSimpleInt) SwigIsSimpleInt() { -} - -var _wrap_new_SimpleInt unsafe.Pointer - -func _swig_wrap_new_SimpleInt() (base SwigcptrSimpleInt) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_SimpleInt, _swig_p) - return -} - -func NewSimpleInt() (_swig_ret SimpleInt) { - return _swig_wrap_new_SimpleInt() -} - -var _wrap_delete_SimpleInt unsafe.Pointer - -func _swig_wrap_delete_SimpleInt(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_SimpleInt, _swig_p) - return -} - -func DeleteSimpleInt(arg1 SimpleInt) { - _swig_wrap_delete_SimpleInt(arg1.Swigcptr()) -} - -type SimpleInt interface { - Swigcptr() uintptr - SwigIsSimpleInt() -} - -type SwigcptrTemplateInt uintptr - -func (p SwigcptrTemplateInt) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrTemplateInt) SwigIsTemplateInt() { -} - -var _wrap_new_TemplateInt__SWIG_0 unsafe.Pointer - -func _swig_wrap_new_TemplateInt__SWIG_0() (base SwigcptrTemplateInt) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_TemplateInt__SWIG_0, _swig_p) - return -} - -func NewTemplateInt__SWIG_0() (_swig_ret TemplateInt) { - return _swig_wrap_new_TemplateInt__SWIG_0() -} - -var _wrap_new_TemplateInt__SWIG_1 unsafe.Pointer - -func _swig_wrap_new_TemplateInt__SWIG_1(base uintptr) (_ SwigcptrTemplateInt) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_TemplateInt__SWIG_1, _swig_p) - return -} - -func NewTemplateInt__SWIG_1(arg1 TemplateInt) (_swig_ret TemplateInt) { - return _swig_wrap_new_TemplateInt__SWIG_1(arg1.Swigcptr()) -} - -func NewTemplateInt(a ...interface{}) TemplateInt { - argc := len(a) - if argc == 0 { - return NewTemplateInt__SWIG_0() - } - if argc == 1 { - return NewTemplateInt__SWIG_1(a[0].(TemplateInt)) - } - panic("No match for overloaded function call") -} - -var _wrap_delete_TemplateInt unsafe.Pointer - -func _swig_wrap_delete_TemplateInt(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_TemplateInt, _swig_p) - return -} - -func DeleteTemplateInt(arg1 TemplateInt) { - _swig_wrap_delete_TemplateInt(arg1.Swigcptr()) -} - -var _wrap_TemplateInt_foo unsafe.Pointer - -func _swig_wrap_TemplateInt_foo(base SwigcptrTemplateInt) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_TemplateInt_foo, _swig_p) - return -} - -func (arg1 SwigcptrTemplateInt) Foo() { - _swig_wrap_TemplateInt_foo(arg1) -} - -var _wrap_TemplateInt_bar unsafe.Pointer - -func _swig_wrap_TemplateInt_bar(base SwigcptrTemplateInt, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_TemplateInt_bar, _swig_p) - return -} - -func (arg1 SwigcptrTemplateInt) Bar(arg2 int) { - _swig_wrap_TemplateInt_bar(arg1, arg2) -} - -var _wrap_TemplateInt_get unsafe.Pointer - -func _swig_wrap_TemplateInt_get(base SwigcptrTemplateInt, _ int) (_ *int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_TemplateInt_get, _swig_p) - return -} - -func (arg1 SwigcptrTemplateInt) Get(arg2 int) (_swig_ret *int) { - return _swig_wrap_TemplateInt_get(arg1, arg2) -} - -var _wrap_TemplateInt_set unsafe.Pointer - -func _swig_wrap_TemplateInt_set(base SwigcptrTemplateInt, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_TemplateInt_set, _swig_p) - return -} - -func (arg1 SwigcptrTemplateInt) Set(arg2 int) { - _swig_wrap_TemplateInt_set(arg1, arg2) -} - -type TemplateInt interface { - Swigcptr() uintptr - SwigIsTemplateInt() - Foo() - Bar(arg2 int) - Get(arg2 int) (_swig_ret *int) - Set(arg2 int) -} - -type SwigcptrWildCards uintptr - -func (p SwigcptrWildCards) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrWildCards) SwigIsWildCards() { -} - -var _wrap_delete_WildCards unsafe.Pointer - -func _swig_wrap_delete_WildCards(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_WildCards, _swig_p) - return -} - -func DeleteWildCards(arg1 WildCards) { - _swig_wrap_delete_WildCards(arg1.Swigcptr()) -} - -var _wrap_WildCards_incy unsafe.Pointer - -func _swig_wrap_WildCards_incy(base SwigcptrWildCards, _ int) (_ SwigcptrWildCards) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_WildCards_incy, _swig_p) - return -} - -func (arg1 SwigcptrWildCards) Incy(arg2 int) (_swig_ret WildCards) { - return _swig_wrap_WildCards_incy(arg1, arg2) -} - -var _wrap_WildCards_wincy unsafe.Pointer - -func _swig_wrap_WildCards_wincy(base SwigcptrWildCards, _ int) (_ SwigcptrWildCards) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_WildCards_wincy, _swig_p) - return -} - -func (arg1 SwigcptrWildCards) Wincy(arg2 int) (_swig_ret WildCards) { - return _swig_wrap_WildCards_wincy(arg1, arg2) -} - -var _wrap_WildCards_spider unsafe.Pointer - -func _swig_wrap_WildCards_spider(base SwigcptrWildCards, _ int) (_ SwigcptrWildCards) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_WildCards_spider, _swig_p) - return -} - -func (arg1 SwigcptrWildCards) Spider(arg2 int) (_swig_ret WildCards) { - return _swig_wrap_WildCards_spider(arg1, arg2) -} - -var _wrap_new_WildCards unsafe.Pointer - -func _swig_wrap_new_WildCards() (base SwigcptrWildCards) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_WildCards, _swig_p) - return -} - -func NewWildCards() (_swig_ret WildCards) { - return _swig_wrap_new_WildCards() -} - -type WildCards interface { - Swigcptr() uintptr - SwigIsWildCards() - Incy(arg2 int) (_swig_ret WildCards) - Wincy(arg2 int) (_swig_ret WildCards) - Spider(arg2 int) (_swig_ret WildCards) -} - -type SwigcptrAnimals uintptr - -func (p SwigcptrAnimals) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrAnimals) SwigIsAnimals() { -} - -var _wrap_new_Animals__SWIG_0 unsafe.Pointer - -func _swig_wrap_new_Animals__SWIG_0(base int, _ float64) (_ SwigcptrAnimals) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Animals__SWIG_0, _swig_p) - return -} - -func NewAnimals__SWIG_0(arg1 int, arg2 float64) (_swig_ret Animals) { - return _swig_wrap_new_Animals__SWIG_0(arg1, arg2) -} - -var _wrap_new_Animals__SWIG_1 unsafe.Pointer - -func _swig_wrap_new_Animals__SWIG_1(base int) (_ SwigcptrAnimals) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Animals__SWIG_1, _swig_p) - return -} - -func NewAnimals__SWIG_1(arg1 int) (_swig_ret Animals) { - return _swig_wrap_new_Animals__SWIG_1(arg1) -} - -var _wrap_new_Animals__SWIG_2 unsafe.Pointer - -func _swig_wrap_new_Animals__SWIG_2() (base SwigcptrAnimals) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Animals__SWIG_2, _swig_p) - return -} - -func NewAnimals__SWIG_2() (_swig_ret Animals) { - return _swig_wrap_new_Animals__SWIG_2() -} - -func NewAnimals(a ...interface{}) Animals { - argc := len(a) - if argc == 0 { - return NewAnimals__SWIG_2() - } - if argc == 1 { - return NewAnimals__SWIG_1(a[0].(int)) - } - if argc == 2 { - return NewAnimals__SWIG_0(a[0].(int), a[1].(float64)) - } - panic("No match for overloaded function call") -} - -var _wrap_Animals_lions__SWIG_0 unsafe.Pointer - -func _swig_wrap_Animals_lions__SWIG_0(base SwigcptrAnimals, _ int, _ float64) (_ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Animals_lions__SWIG_0, _swig_p) - return -} - -func (arg1 SwigcptrAnimals) Lions__SWIG_0(arg2 int, arg3 float64) (_swig_ret uintptr) { - return _swig_wrap_Animals_lions__SWIG_0(arg1, arg2, arg3) -} - -var _wrap_Animals_lions__SWIG_1 unsafe.Pointer - -func _swig_wrap_Animals_lions__SWIG_1(base SwigcptrAnimals, _ int) (_ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Animals_lions__SWIG_1, _swig_p) - return -} - -func (arg1 SwigcptrAnimals) Lions__SWIG_1(arg2 int) (_swig_ret uintptr) { - return _swig_wrap_Animals_lions__SWIG_1(arg1, arg2) -} - -var _wrap_Animals_lions__SWIG_2 unsafe.Pointer - -func _swig_wrap_Animals_lions__SWIG_2(base SwigcptrAnimals) (_ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Animals_lions__SWIG_2, _swig_p) - return -} - -func (arg1 SwigcptrAnimals) Lions__SWIG_2() (_swig_ret uintptr) { - return _swig_wrap_Animals_lions__SWIG_2(arg1) -} - -func (p SwigcptrAnimals) Lions(a ...interface{}) uintptr { - argc := len(a) - if argc == 0 { - return p.Lions__SWIG_2() - } - if argc == 1 { - return p.Lions__SWIG_1(a[0].(int)) - } - if argc == 2 { - return p.Lions__SWIG_0(a[0].(int), a[1].(float64)) - } - panic("No match for overloaded function call") -} - -var _wrap_Animals_leopards__SWIG_0 unsafe.Pointer - -func _swig_wrap_Animals_leopards__SWIG_0(base SwigcptrAnimals, _ int, _ float64) (_ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Animals_leopards__SWIG_0, _swig_p) - return -} - -func (arg1 SwigcptrAnimals) Leopards__SWIG_0(arg2 int, arg3 float64) (_swig_ret uintptr) { - return _swig_wrap_Animals_leopards__SWIG_0(arg1, arg2, arg3) -} - -var _wrap_Animals_leopards__SWIG_1 unsafe.Pointer - -func _swig_wrap_Animals_leopards__SWIG_1(base SwigcptrAnimals, _ int) (_ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Animals_leopards__SWIG_1, _swig_p) - return -} - -func (arg1 SwigcptrAnimals) Leopards__SWIG_1(arg2 int) (_swig_ret uintptr) { - return _swig_wrap_Animals_leopards__SWIG_1(arg1, arg2) -} - -var _wrap_Animals_leopards__SWIG_2 unsafe.Pointer - -func _swig_wrap_Animals_leopards__SWIG_2(base SwigcptrAnimals) (_ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Animals_leopards__SWIG_2, _swig_p) - return -} - -func (arg1 SwigcptrAnimals) Leopards__SWIG_2() (_swig_ret uintptr) { - return _swig_wrap_Animals_leopards__SWIG_2(arg1) -} - -func (p SwigcptrAnimals) Leopards(a ...interface{}) uintptr { - argc := len(a) - if argc == 0 { - return p.Leopards__SWIG_2() - } - if argc == 1 { - return p.Leopards__SWIG_1(a[0].(int)) - } - if argc == 2 { - return p.Leopards__SWIG_0(a[0].(int), a[1].(float64)) - } - panic("No match for overloaded function call") -} - -var _wrap_Animals_cheetahs__SWIG_0 unsafe.Pointer - -func _swig_wrap_Animals_cheetahs__SWIG_0(base SwigcptrAnimals, _ int, _ float64) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Animals_cheetahs__SWIG_0, _swig_p) - return -} - -func (arg1 SwigcptrAnimals) Cheetahs__SWIG_0(arg2 int, arg3 float64) (_swig_ret int) { - return _swig_wrap_Animals_cheetahs__SWIG_0(arg1, arg2, arg3) -} - -var _wrap_Animals_cheetahs__SWIG_1 unsafe.Pointer - -func _swig_wrap_Animals_cheetahs__SWIG_1(base SwigcptrAnimals, _ int) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Animals_cheetahs__SWIG_1, _swig_p) - return -} - -func (arg1 SwigcptrAnimals) Cheetahs__SWIG_1(arg2 int) (_swig_ret int) { - return _swig_wrap_Animals_cheetahs__SWIG_1(arg1, arg2) -} - -var _wrap_Animals_cheetahs__SWIG_2 unsafe.Pointer - -func _swig_wrap_Animals_cheetahs__SWIG_2(base SwigcptrAnimals) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Animals_cheetahs__SWIG_2, _swig_p) - return -} - -func (arg1 SwigcptrAnimals) Cheetahs__SWIG_2() (_swig_ret int) { - return _swig_wrap_Animals_cheetahs__SWIG_2(arg1) -} - -func (p SwigcptrAnimals) Cheetahs(a ...interface{}) int { - argc := len(a) - if argc == 0 { - return p.Cheetahs__SWIG_2() - } - if argc == 1 { - return p.Cheetahs__SWIG_1(a[0].(int)) - } - if argc == 2 { - return p.Cheetahs__SWIG_0(a[0].(int), a[1].(float64)) - } - panic("No match for overloaded function call") -} - -var _wrap_Animals_jackal__SWIG_0 unsafe.Pointer - -func _swig_wrap_Animals_jackal__SWIG_0(base SwigcptrAnimals, _ int, _ float64) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Animals_jackal__SWIG_0, _swig_p) - return -} - -func (arg1 SwigcptrAnimals) Jackal__SWIG_0(arg2 int, arg3 float64) (_swig_ret int) { - return _swig_wrap_Animals_jackal__SWIG_0(arg1, arg2, arg3) -} - -var _wrap_Animals_jackal__SWIG_1 unsafe.Pointer - -func _swig_wrap_Animals_jackal__SWIG_1(base SwigcptrAnimals, _ int) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Animals_jackal__SWIG_1, _swig_p) - return -} - -func (arg1 SwigcptrAnimals) Jackal__SWIG_1(arg2 int) (_swig_ret int) { - return _swig_wrap_Animals_jackal__SWIG_1(arg1, arg2) -} - -var _wrap_Animals_jackal__SWIG_2 unsafe.Pointer - -func _swig_wrap_Animals_jackal__SWIG_2(base SwigcptrAnimals) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Animals_jackal__SWIG_2, _swig_p) - return -} - -func (arg1 SwigcptrAnimals) Jackal__SWIG_2() (_swig_ret int) { - return _swig_wrap_Animals_jackal__SWIG_2(arg1) -} - -func (p SwigcptrAnimals) Jackal(a ...interface{}) int { - argc := len(a) - if argc == 0 { - return p.Jackal__SWIG_2() - } - if argc == 1 { - return p.Jackal__SWIG_1(a[0].(int)) - } - if argc == 2 { - return p.Jackal__SWIG_0(a[0].(int), a[1].(float64)) - } - panic("No match for overloaded function call") -} - -var _wrap_delete_Animals unsafe.Pointer - -func _swig_wrap_delete_Animals(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Animals, _swig_p) - return -} - -func DeleteAnimals(arg1 Animals) { - _swig_wrap_delete_Animals(arg1.Swigcptr()) -} - -type Animals interface { - Swigcptr() uintptr - SwigIsAnimals() - Lions(a ...interface{}) uintptr - Leopards(a ...interface{}) uintptr - Cheetahs(a ...interface{}) int - Jackal(a ...interface{}) int -} - -type SwigcptrBase uintptr - -func (p SwigcptrBase) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrBase) SwigIsBase() { -} - -var _wrap_Base_virtualmethod unsafe.Pointer - -func _swig_wrap_Base_virtualmethod(base SwigcptrBase, _ int) (_ *string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Base_virtualmethod, _swig_p) - return -} - -func (arg1 SwigcptrBase) Virtualmethod(arg2 int) (_swig_ret *string) { - return _swig_wrap_Base_virtualmethod(arg1, arg2) -} - -var _wrap_delete_Base unsafe.Pointer - -func _swig_wrap_delete_Base(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Base, _swig_p) - return -} - -func DeleteBase(arg1 Base) { - _swig_wrap_delete_Base(arg1.Swigcptr()) -} - -var _wrap_new_Base unsafe.Pointer - -func _swig_wrap_new_Base() (base SwigcptrBase) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Base, _swig_p) - return -} - -func NewBase() (_swig_ret Base) { - return _swig_wrap_new_Base() -} - -type Base interface { - Swigcptr() uintptr - SwigIsBase() - Virtualmethod(arg2 int) (_swig_ret *string) -} - -type SwigcptrDerived uintptr - -func (p SwigcptrDerived) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrDerived) SwigIsDerived() { -} - -var _wrap_Derived_virtualmethod unsafe.Pointer - -func _swig_wrap_Derived_virtualmethod(base SwigcptrDerived, _ int) (_ *string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Derived_virtualmethod, _swig_p) - return -} - -func (arg1 SwigcptrDerived) Virtualmethod(arg2 int) (_swig_ret *string) { - return _swig_wrap_Derived_virtualmethod(arg1, arg2) -} - -var _wrap_new_Derived unsafe.Pointer - -func _swig_wrap_new_Derived() (base SwigcptrDerived) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Derived, _swig_p) - return -} - -func NewDerived() (_swig_ret Derived) { - return _swig_wrap_new_Derived() -} - -var _wrap_delete_Derived unsafe.Pointer - -func _swig_wrap_delete_Derived(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Derived, _swig_p) - return -} - -func DeleteDerived(arg1 Derived) { - _swig_wrap_delete_Derived(arg1.Swigcptr()) -} - -func (p SwigcptrDerived) SwigIsBase() { -} - -func (p SwigcptrDerived) SwigGetBase() Base { - return SwigcptrBase(p.Swigcptr()) -} - -type Derived interface { - Swigcptr() uintptr - SwigIsDerived() - Virtualmethod(arg2 int) (_swig_ret *string) - SwigIsBase() - SwigGetBase() Base -} - -type SwigcptrConversionOperators uintptr - -func (p SwigcptrConversionOperators) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrConversionOperators) SwigIsConversionOperators() { -} - -var _wrap_ConversionOperators_opbool unsafe.Pointer - -func _swig_wrap_ConversionOperators_opbool(base SwigcptrConversionOperators) (_ bool) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_ConversionOperators_opbool, _swig_p) - return -} - -func (arg1 SwigcptrConversionOperators) Opbool() (_swig_ret bool) { - return _swig_wrap_ConversionOperators_opbool(arg1) -} - -var _wrap_ConversionOperators_opuint unsafe.Pointer - -func _swig_wrap_ConversionOperators_opuint(base SwigcptrConversionOperators) (_ uint) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_ConversionOperators_opuint, _swig_p) - return -} - -func (arg1 SwigcptrConversionOperators) Opuint() (_swig_ret uint) { - return _swig_wrap_ConversionOperators_opuint(arg1) -} - -var _wrap_new_ConversionOperators unsafe.Pointer - -func _swig_wrap_new_ConversionOperators() (base SwigcptrConversionOperators) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_ConversionOperators, _swig_p) - return -} - -func NewConversionOperators() (_swig_ret ConversionOperators) { - return _swig_wrap_new_ConversionOperators() -} - -var _wrap_delete_ConversionOperators unsafe.Pointer - -func _swig_wrap_delete_ConversionOperators(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_ConversionOperators, _swig_p) - return -} - -func DeleteConversionOperators(arg1 ConversionOperators) { - _swig_wrap_delete_ConversionOperators(arg1.Swigcptr()) -} - -type ConversionOperators interface { - Swigcptr() uintptr - SwigIsConversionOperators() - Opbool() (_swig_ret bool) - Opuint() (_swig_ret uint) -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/fragments.go b/Examples/test-suite/go/fragments.go deleted file mode 100644 index e76badf4e..000000000 --- a/Examples/test-suite/go/fragments.go +++ /dev/null @@ -1,43 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../fragments.i - -package fragments - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -var _wrap_bar unsafe.Pointer - -func Bar(arg1 int) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_bar, _swig_p) - return -} -var _wrap_foo unsafe.Pointer - -func Foo(arg1 int) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_foo, _swig_p) - return -} - diff --git a/Examples/test-suite/go/friends.go b/Examples/test-suite/go/friends.go deleted file mode 100644 index e76c64350..000000000 --- a/Examples/test-suite/go/friends.go +++ /dev/null @@ -1,451 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../friends.i - -package friends - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -var _wrap_globalscope unsafe.Pointer - -func _swig_wrap_globalscope() { - var _swig_p uintptr - _cgo_runtime_cgocall(_wrap_globalscope, _swig_p) - return -} - -func Globalscope() { - _swig_wrap_globalscope() -} - -type SwigcptrB uintptr - -func (p SwigcptrB) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrB) SwigIsB() { -} - -var _wrap_new_B unsafe.Pointer - -func _swig_wrap_new_B(base int) (_ SwigcptrB) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_B, _swig_p) - return -} - -func NewB(arg1 int) (_swig_ret B) { - return _swig_wrap_new_B(arg1) -} - -var _wrap_mix unsafe.Pointer - -func _swig_wrap_mix(base uintptr, _ uintptr) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_mix, _swig_p) - return -} - -func Mix(arg1 A, arg2 B) (_swig_ret int) { - return _swig_wrap_mix(arg1.Swigcptr(), arg2.Swigcptr()) -} - -var _wrap_delete_B unsafe.Pointer - -func _swig_wrap_delete_B(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_B, _swig_p) - return -} - -func DeleteB(arg1 B) { - _swig_wrap_delete_B(arg1.Swigcptr()) -} - -type B interface { - Swigcptr() uintptr - SwigIsB() -} - -type SwigcptrA uintptr - -func (p SwigcptrA) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrA) SwigIsA() { -} - -var _wrap_new_A unsafe.Pointer - -func _swig_wrap_new_A(base int) (_ SwigcptrA) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_A, _swig_p) - return -} - -func NewA(arg1 int) (_swig_ret A) { - return _swig_wrap_new_A(arg1) -} - -var _wrap_get_val1__SWIG_0 unsafe.Pointer - -func _swig_wrap_get_val1__SWIG_0(base uintptr) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_get_val1__SWIG_0, _swig_p) - return -} - -func Get_val1__SWIG_0(arg1 A) (_swig_ret int) { - return _swig_wrap_get_val1__SWIG_0(arg1.Swigcptr()) -} - -var _wrap_get_val1__SWIG_1 unsafe.Pointer - -func _swig_wrap_get_val1__SWIG_1(base uintptr, _ int) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_get_val1__SWIG_1, _swig_p) - return -} - -func Get_val1__SWIG_1(arg1 A, arg2 int) (_swig_ret int) { - return _swig_wrap_get_val1__SWIG_1(arg1.Swigcptr(), arg2) -} - -var _wrap_get_val2 unsafe.Pointer - -func _swig_wrap_get_val2(base uintptr) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_get_val2, _swig_p) - return -} - -func Get_val2(arg1 A) (_swig_ret int) { - return _swig_wrap_get_val2(arg1.Swigcptr()) -} - -var _wrap_get_val3 unsafe.Pointer - -func _swig_wrap_get_val3(base uintptr) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_get_val3, _swig_p) - return -} - -func Get_val3(arg1 A) (_swig_ret int) { - return _swig_wrap_get_val3(arg1.Swigcptr()) -} - -var _wrap_delete_A unsafe.Pointer - -func _swig_wrap_delete_A(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_A, _swig_p) - return -} - -func DeleteA(arg1 A) { - _swig_wrap_delete_A(arg1.Swigcptr()) -} - -type A interface { - Swigcptr() uintptr - SwigIsA() -} - -var _wrap_get_val1__SWIG_2 unsafe.Pointer - -func Get_val1__SWIG_2(arg1 int, arg2 int, arg3 int) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_get_val1__SWIG_2, _swig_p) - return -} -var _wrap_bas unsafe.Pointer - -func _swig_wrap_bas() { - var _swig_p uintptr - _cgo_runtime_cgocall(_wrap_bas, _swig_p) - return -} - -func Bas() { - _swig_wrap_bas() -} - -var _wrap_baz unsafe.Pointer - -func _swig_wrap_baz() { - var _swig_p uintptr - _cgo_runtime_cgocall(_wrap_baz, _swig_p) - return -} - -func Baz() { - _swig_wrap_baz() -} - -type SwigcptrFoo uintptr - -func (p SwigcptrFoo) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrFoo) SwigIsFoo() { -} - -var _wrap_new_Foo unsafe.Pointer - -func _swig_wrap_new_Foo() (base SwigcptrFoo) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Foo, _swig_p) - return -} - -func NewFoo() (_swig_ret Foo) { - return _swig_wrap_new_Foo() -} - -var _wrap_Foo_member unsafe.Pointer - -func _swig_wrap_Foo_member(base SwigcptrFoo) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_member, _swig_p) - return -} - -func (arg1 SwigcptrFoo) Member() { - _swig_wrap_Foo_member(arg1) -} - -var _wrap_delete_Foo unsafe.Pointer - -func _swig_wrap_delete_Foo(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Foo, _swig_p) - return -} - -func DeleteFoo(arg1 Foo) { - _swig_wrap_delete_Foo(arg1.Swigcptr()) -} - -type Foo interface { - Swigcptr() uintptr - SwigIsFoo() - Member() -} - -var _wrap_bar unsafe.Pointer - -func _swig_wrap_bar() { - var _swig_p uintptr - _cgo_runtime_cgocall(_wrap_bar, _swig_p) - return -} - -func Bar() { - _swig_wrap_bar() -} - -type SwigcptrD_i uintptr - -func (p SwigcptrD_i) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrD_i) SwigIsD_i() { -} - -var _wrap_new_D_i unsafe.Pointer - -func _swig_wrap_new_D_i(base int) (_ SwigcptrD_i) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_D_i, _swig_p) - return -} - -func NewD_i(arg1 int) (_swig_ret D_i) { - return _swig_wrap_new_D_i(arg1) -} - -var _wrap_get_val1__SWIG_4 unsafe.Pointer - -func _swig_wrap_get_val1__SWIG_4(base uintptr) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_get_val1__SWIG_4, _swig_p) - return -} - -func Get_val1__SWIG_4(arg1 D_i) (_swig_ret int) { - return _swig_wrap_get_val1__SWIG_4(arg1.Swigcptr()) -} - -var _wrap_set__SWIG_1 unsafe.Pointer - -func _swig_wrap_set__SWIG_1(base uintptr, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_set__SWIG_1, _swig_p) - return -} - -func Set__SWIG_1(arg1 D_i, arg2 int) { - _swig_wrap_set__SWIG_1(arg1.Swigcptr(), arg2) -} - -var _wrap_delete_D_i unsafe.Pointer - -func _swig_wrap_delete_D_i(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_D_i, _swig_p) - return -} - -func DeleteD_i(arg1 D_i) { - _swig_wrap_delete_D_i(arg1.Swigcptr()) -} - -type D_i interface { - Swigcptr() uintptr - SwigIsD_i() -} - -type SwigcptrD_d uintptr - -func (p SwigcptrD_d) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrD_d) SwigIsD_d() { -} - -var _wrap_new_D_d unsafe.Pointer - -func _swig_wrap_new_D_d(base float64) (_ SwigcptrD_d) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_D_d, _swig_p) - return -} - -func NewD_d(arg1 float64) (_swig_ret D_d) { - return _swig_wrap_new_D_d(arg1) -} - -var _wrap_get_val1__SWIG_5 unsafe.Pointer - -func _swig_wrap_get_val1__SWIG_5(base uintptr) (_ float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_get_val1__SWIG_5, _swig_p) - return -} - -func Get_val1__SWIG_5(arg1 D_d) (_swig_ret float64) { - return _swig_wrap_get_val1__SWIG_5(arg1.Swigcptr()) -} - -func Get_val1(a ...interface{}) interface{} { - argc := len(a) - if argc == 1 { - if _, ok := a[0].(A); !ok { - goto check_1 - } - return Get_val1__SWIG_0(a[0].(A)) - } -check_1: - if argc == 1 { - if _, ok := a[0].(D_i); !ok { - goto check_2 - } - return Get_val1__SWIG_4(a[0].(D_i)) - } -check_2: - if argc == 1 { - return Get_val1__SWIG_5(a[0].(D_d)) - } - if argc == 2 { - return Get_val1__SWIG_1(a[0].(A), a[1].(int)) - } - if argc == 3 { - return Get_val1__SWIG_2(a[0].(int), a[1].(int), a[2].(int)) - } - panic("No match for overloaded function call") -} - -var _wrap_set__SWIG_2 unsafe.Pointer - -func _swig_wrap_set__SWIG_2(base uintptr, _ float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_set__SWIG_2, _swig_p) - return -} - -func Set__SWIG_2(arg1 D_d, arg2 float64) { - _swig_wrap_set__SWIG_2(arg1.Swigcptr(), arg2) -} - -func Set(a ...interface{}) { - argc := len(a) - if argc == 2 { - if _, ok := a[0].(D_i); !ok { - goto check_1 - } - if _, ok := a[1].(int); !ok { - goto check_1 - } - Set__SWIG_1(a[0].(D_i), a[1].(int)) - return - } -check_1: - if argc == 2 { - Set__SWIG_2(a[0].(D_d), a[1].(float64)) - return - } - panic("No match for overloaded function call") -} - -var _wrap_delete_D_d unsafe.Pointer - -func _swig_wrap_delete_D_d(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_D_d, _swig_p) - return -} - -func DeleteD_d(arg1 D_d) { - _swig_wrap_delete_D_d(arg1.Swigcptr()) -} - -type D_d interface { - Swigcptr() uintptr - SwigIsD_d() -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/friends_runme b/Examples/test-suite/go/friends_runme deleted file mode 100755 index d5ece09c3..000000000 Binary files a/Examples/test-suite/go/friends_runme and /dev/null differ diff --git a/Examples/test-suite/go/funcptr.go b/Examples/test-suite/go/funcptr.go deleted file mode 100644 index 0d9be944f..000000000 --- a/Examples/test-suite/go/funcptr.go +++ /dev/null @@ -1,338 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../funcptr.i - -package funcptr - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -var _wrap_distance unsafe.Pointer - -func _swig_wrap_distance(base *float64, _ *int, _ *_swig_fnptr, _ *float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_distance, _swig_p) - return -} - -func Distance(arg1 *float64, arg2 *int, arg3 *_swig_fnptr, arg4 *float64) { - _swig_wrap_distance(arg1, arg2, arg3, arg4) -} - -var _wrap_do_op unsafe.Pointer - -func Do_op(arg1 int, arg2 int, arg3 _swig_fnptr) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_do_op, _swig_p) - return -} -var _wrap_add unsafe.Pointer - -func Add(arg1 int, arg2 int) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_add, _swig_p) - return -} -var _wrap_subtract unsafe.Pointer - -func Subtract(arg1 int, arg2 int) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_subtract, _swig_p) - return -} -var _wrap_multiply unsafe.Pointer - -func Multiply(arg1 int, arg2 int) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_multiply, _swig_p) - return -} -var _wrap_nowt unsafe.Pointer - -func Nowt() (_swig_ret *int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_nowt, _swig_p) - return -} -var _wrap_nowt2 unsafe.Pointer - -func Nowt2() (_swig_ret *int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_nowt2, _swig_p) - return -} -type SwigcptrMyStruct uintptr - -func (p SwigcptrMyStruct) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrMyStruct) SwigIsMyStruct() { -} - -var _wrap_MyStruct_i_set unsafe.Pointer - -func _swig_wrap_MyStruct_i_set(base SwigcptrMyStruct, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_MyStruct_i_set, _swig_p) - return -} - -func (arg1 SwigcptrMyStruct) SetI(arg2 int) { - _swig_wrap_MyStruct_i_set(arg1, arg2) -} - -var _wrap_MyStruct_i_get unsafe.Pointer - -func _swig_wrap_MyStruct_i_get(base SwigcptrMyStruct) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_MyStruct_i_get, _swig_p) - return -} - -func (arg1 SwigcptrMyStruct) GetI() (_swig_ret int) { - return _swig_wrap_MyStruct_i_get(arg1) -} - -var _wrap_new_MyStruct unsafe.Pointer - -func _swig_wrap_new_MyStruct() (base SwigcptrMyStruct) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_MyStruct, _swig_p) - return -} - -func NewMyStruct() (_swig_ret MyStruct) { - return _swig_wrap_new_MyStruct() -} - -var _wrap_delete_MyStruct unsafe.Pointer - -func _swig_wrap_delete_MyStruct(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_MyStruct, _swig_p) - return -} - -func DeleteMyStruct(arg1 MyStruct) { - _swig_wrap_delete_MyStruct(arg1.Swigcptr()) -} - -type MyStruct interface { - Swigcptr() uintptr - SwigIsMyStruct() - SetI(arg2 int) - GetI() (_swig_ret int) -} - -var _wrap_mystructptr unsafe.Pointer - -func _swig_wrap_mystructptr() (base SwigcptrMyStruct) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_mystructptr, _swig_p) - return -} - -func Mystructptr() (_swig_ret MyStruct) { - return _swig_wrap_mystructptr() -} - -var _wrap_funcvar_set unsafe.Pointer - -func _swig_wrap_funcvar_set(base _swig_fnptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_funcvar_set, _swig_p) - return -} - -func SetFuncvar(arg1 _swig_fnptr) { - _swig_wrap_funcvar_set(arg1) -} - -var _wrap_funcvar_get unsafe.Pointer - -func GetFuncvar() (_swig_ret _swig_fnptr) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_funcvar_get, _swig_p) - return -} -var _wrap_funcvar2_set unsafe.Pointer - -func _swig_wrap_funcvar2_set(base _swig_fnptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_funcvar2_set, _swig_p) - return -} - -func SetFuncvar2(arg1 _swig_fnptr) { - _swig_wrap_funcvar2_set(arg1) -} - -var _wrap_funcvar2_get unsafe.Pointer - -func GetFuncvar2() (_swig_ret _swig_fnptr) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_funcvar2_get, _swig_p) - return -} -var _wrap_funcvar3_set unsafe.Pointer - -func _swig_wrap_funcvar3_set(base _swig_fnptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_funcvar3_set, _swig_p) - return -} - -func SetFuncvar3(arg1 _swig_fnptr) { - _swig_wrap_funcvar3_set(arg1) -} - -var _wrap_funcvar3_get unsafe.Pointer - -func GetFuncvar3() (_swig_ret _swig_fnptr) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_funcvar3_get, _swig_p) - return -} -var _wrap_funcvar4_set unsafe.Pointer - -func _swig_wrap_funcvar4_set(base _swig_fnptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_funcvar4_set, _swig_p) - return -} - -func SetFuncvar4(arg1 _swig_fnptr) { - _swig_wrap_funcvar4_set(arg1) -} - -var _wrap_funcvar4_get unsafe.Pointer - -func GetFuncvar4() (_swig_ret _swig_fnptr) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_funcvar4_get, _swig_p) - return -} -var _wrap_funcvar5_set unsafe.Pointer - -func _swig_wrap_funcvar5_set(base _swig_fnptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_funcvar5_set, _swig_p) - return -} - -func SetFuncvar5(arg1 _swig_fnptr) { - _swig_wrap_funcvar5_set(arg1) -} - -var _wrap_funcvar5_get unsafe.Pointer - -func GetFuncvar5() (_swig_ret _swig_fnptr) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_funcvar5_get, _swig_p) - return -} -var _wrap_pfunc0_set unsafe.Pointer - -func _swig_wrap_pfunc0_set(base _swig_fnptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_pfunc0_set, _swig_p) - return -} - -func SetPfunc0(arg1 _swig_fnptr) { - _swig_wrap_pfunc0_set(arg1) -} - -var _wrap_pfunc0_get unsafe.Pointer - -func GetPfunc0() (_swig_ret _swig_fnptr) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_pfunc0_get, _swig_p) - return -} -var _wrap_pfuncA_set unsafe.Pointer - -func _swig_wrap_pfuncA_set(base _swig_fnptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_pfuncA_set, _swig_p) - return -} - -func SetPfuncA(arg1 _swig_fnptr) { - _swig_wrap_pfuncA_set(arg1) -} - -var _wrap_pfuncA_get unsafe.Pointer - -func GetPfuncA() (_swig_ret _swig_fnptr) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_pfuncA_get, _swig_p) - return -} -var _wrap_pfunc1_set unsafe.Pointer - -func _swig_wrap_pfunc1_set(base _swig_fnptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_pfunc1_set, _swig_p) - return -} - -func SetPfunc1(arg1 _swig_fnptr) { - _swig_wrap_pfunc1_set(arg1) -} - -var _wrap_pfunc1_get unsafe.Pointer - -func GetPfunc1() (_swig_ret _swig_fnptr) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_pfunc1_get, _swig_p) - return -} -var _wrap_pfunc2_set unsafe.Pointer - -func _swig_wrap_pfunc2_set(base _swig_fnptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_pfunc2_set, _swig_p) - return -} - -func SetPfunc2(arg1 _swig_fnptr) { - _swig_wrap_pfunc2_set(arg1) -} - -var _wrap_pfunc2_get unsafe.Pointer - -func GetPfunc2() (_swig_ret _swig_fnptr) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_pfunc2_get, _swig_p) - return -} - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/funcptr_cpp.go b/Examples/test-suite/go/funcptr_cpp.go deleted file mode 100644 index 0071b7072..000000000 --- a/Examples/test-suite/go/funcptr_cpp.go +++ /dev/null @@ -1,116 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../funcptr_cpp.i - -package funcptr_cpp - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -var _wrap_addByValue unsafe.Pointer - -func AddByValue(arg1 int, arg2 int) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_addByValue, _swig_p) - return -} -var _wrap_addByPointer unsafe.Pointer - -func AddByPointer(arg1 int, arg2 int) (_swig_ret *int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_addByPointer, _swig_p) - return -} -var _wrap_addByReference unsafe.Pointer - -func AddByReference(arg1 int, arg2 int) (_swig_ret *int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_addByReference, _swig_p) - return -} -var _wrap_call1 unsafe.Pointer - -func Call1(arg1 _swig_fnptr, arg2 int, arg3 int) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_call1, _swig_p) - return -} -var _wrap_call2 unsafe.Pointer - -func Call2(arg1 _swig_fnptr, arg2 int, arg3 int) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_call2, _swig_p) - return -} -var _wrap_call3 unsafe.Pointer - -func Call3(arg1 _swig_fnptr, arg2 int, arg3 int) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_call3, _swig_p) - return -} -var _wrap_ADD_BY_VALUE unsafe.Pointer - -func _swig_getADD_BY_VALUE() (_swig_ret _swig_fnptr) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_ADD_BY_VALUE, _swig_p) - return -} -var ADD_BY_VALUE _swig_fnptr = _swig_getADD_BY_VALUE() -var _wrap_ADD_BY_POINTER unsafe.Pointer - -func _swig_getADD_BY_POINTER() (_swig_ret _swig_fnptr) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_ADD_BY_POINTER, _swig_p) - return -} -var ADD_BY_POINTER _swig_fnptr = _swig_getADD_BY_POINTER() -var _wrap_ADD_BY_REFERENCE unsafe.Pointer - -func _swig_getADD_BY_REFERENCE() (_swig_ret _swig_fnptr) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_ADD_BY_REFERENCE, _swig_p) - return -} -var ADD_BY_REFERENCE _swig_fnptr = _swig_getADD_BY_REFERENCE() -var _wrap_typedef_call1 unsafe.Pointer - -func Typedef_call1(arg1 *_swig_fnptr, arg2 *_swig_fnptr) (_swig_ret uintptr) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_typedef_call1, _swig_p) - return -} -var _wrap_typedef_call2 unsafe.Pointer - -func Typedef_call2(arg1 *_swig_fnptr, arg2 *_swig_fnptr) (_swig_ret uintptr) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_typedef_call2, _swig_p) - return -} -var _wrap_typedef_call3 unsafe.Pointer - -func Typedef_call3(arg1 *_swig_fnptr, arg2 *_swig_fnptr) (_swig_ret uintptr) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_typedef_call3, _swig_p) - return -} - diff --git a/Examples/test-suite/go/function_typedef.go b/Examples/test-suite/go/function_typedef.go deleted file mode 100644 index 1d8cfcf25..000000000 --- a/Examples/test-suite/go/function_typedef.go +++ /dev/null @@ -1,50 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../function_typedef.i - -package function_typedef - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -var _wrap_do_binop1 unsafe.Pointer - -func Do_binop1(arg1 *_swig_fnptr, arg2 int, arg3 int) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_do_binop1, _swig_p) - return -} -var _wrap_do_binop2 unsafe.Pointer - -func Do_binop2(arg1 *_swig_fnptr, arg2 int, arg3 int) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_do_binop2, _swig_p) - return -} -var _wrap_do_binop3 unsafe.Pointer - -func Do_binop3(arg1 _swig_fnptr, arg2 int, arg3 int) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_do_binop3, _swig_p) - return -} - diff --git a/Examples/test-suite/go/fvirtual.go b/Examples/test-suite/go/fvirtual.go deleted file mode 100644 index 1048e8b7d..000000000 --- a/Examples/test-suite/go/fvirtual.go +++ /dev/null @@ -1,171 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../fvirtual.i - -package fvirtual - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrNode uintptr - -func (p SwigcptrNode) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrNode) SwigIsNode() { -} - -var _wrap_Node_addChild unsafe.Pointer - -func _swig_wrap_Node_addChild(base SwigcptrNode, _ uintptr) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Node_addChild, _swig_p) - return -} - -func (arg1 SwigcptrNode) AddChild(arg2 Node) (_swig_ret int) { - return _swig_wrap_Node_addChild(arg1, arg2.Swigcptr()) -} - -var _wrap_delete_Node unsafe.Pointer - -func _swig_wrap_delete_Node(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Node, _swig_p) - return -} - -func DeleteNode(arg1 Node) { - _swig_wrap_delete_Node(arg1.Swigcptr()) -} - -var _wrap_new_Node unsafe.Pointer - -func _swig_wrap_new_Node() (base SwigcptrNode) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Node, _swig_p) - return -} - -func NewNode() (_swig_ret Node) { - return _swig_wrap_new_Node() -} - -type Node interface { - Swigcptr() uintptr - SwigIsNode() - AddChild(arg2 Node) (_swig_ret int) -} - -type SwigcptrNodeSwitch uintptr - -func (p SwigcptrNodeSwitch) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrNodeSwitch) SwigIsNodeSwitch() { -} - -var _wrap_NodeSwitch_addChild__SWIG_0 unsafe.Pointer - -func _swig_wrap_NodeSwitch_addChild__SWIG_0(base SwigcptrNodeSwitch, _ uintptr) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_NodeSwitch_addChild__SWIG_0, _swig_p) - return -} - -func (arg1 SwigcptrNodeSwitch) AddChild__SWIG_0(arg2 Node) (_swig_ret int) { - return _swig_wrap_NodeSwitch_addChild__SWIG_0(arg1, arg2.Swigcptr()) -} - -var _wrap_NodeSwitch_addChild__SWIG_1 unsafe.Pointer - -func _swig_wrap_NodeSwitch_addChild__SWIG_1(base SwigcptrNodeSwitch, _ uintptr, _ bool) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_NodeSwitch_addChild__SWIG_1, _swig_p) - return -} - -func (arg1 SwigcptrNodeSwitch) AddChild__SWIG_1(arg2 Node, arg3 bool) (_swig_ret int) { - return _swig_wrap_NodeSwitch_addChild__SWIG_1(arg1, arg2.Swigcptr(), arg3) -} - -func (p SwigcptrNodeSwitch) AddChild(a ...interface{}) int { - argc := len(a) - if argc == 1 { - return p.AddChild__SWIG_0(a[0].(Node)) - } - if argc == 2 { - return p.AddChild__SWIG_1(a[0].(Node), a[1].(bool)) - } - panic("No match for overloaded function call") -} - -var _wrap_delete_NodeSwitch unsafe.Pointer - -func _swig_wrap_delete_NodeSwitch(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_NodeSwitch, _swig_p) - return -} - -func DeleteNodeSwitch(arg1 NodeSwitch) { - _swig_wrap_delete_NodeSwitch(arg1.Swigcptr()) -} - -var _wrap_new_NodeSwitch unsafe.Pointer - -func _swig_wrap_new_NodeSwitch() (base SwigcptrNodeSwitch) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_NodeSwitch, _swig_p) - return -} - -func NewNodeSwitch() (_swig_ret NodeSwitch) { - return _swig_wrap_new_NodeSwitch() -} - -func (p SwigcptrNodeSwitch) SwigIsNode() { -} - -func (p SwigcptrNodeSwitch) SwigGetNode() Node { - return SwigcptrNode(p.Swigcptr()) -} - -type NodeSwitch interface { - Swigcptr() uintptr - SwigIsNodeSwitch() - AddChild(a ...interface{}) int - SwigIsNode() - SwigGetNode() Node -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/fvirtual_runme b/Examples/test-suite/go/fvirtual_runme deleted file mode 100755 index 5b9ade236..000000000 Binary files a/Examples/test-suite/go/fvirtual_runme and /dev/null differ diff --git a/Examples/test-suite/go/global_functions.go b/Examples/test-suite/go/global_functions.go deleted file mode 100644 index efb347421..000000000 --- a/Examples/test-suite/go/global_functions.go +++ /dev/null @@ -1,63 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../global_functions.i - -package global_functions - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -var _wrap_global_void unsafe.Pointer - -func _swig_wrap_global_void() { - var _swig_p uintptr - _cgo_runtime_cgocall(_wrap_global_void, _swig_p) - return -} - -func Global_void() { - _swig_wrap_global_void() -} - -var _wrap_global_one unsafe.Pointer - -func Global_one(arg1 int) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_global_one, _swig_p) - return -} -var _wrap_global_two unsafe.Pointer - -func Global_two(arg1 int, arg2 int) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_global_two, _swig_p) - return -} - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/global_namespace.go b/Examples/test-suite/go/global_namespace.go deleted file mode 100644 index 7ba3e2f8f..000000000 --- a/Examples/test-suite/go/global_namespace.go +++ /dev/null @@ -1,1039 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../global_namespace.i - -package global_namespace - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrKlass1 uintptr - -func (p SwigcptrKlass1) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrKlass1) SwigIsKlass1() { -} - -var _wrap_new_Klass1 unsafe.Pointer - -func _swig_wrap_new_Klass1() (base SwigcptrKlass1) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Klass1, _swig_p) - return -} - -func NewKlass1() (_swig_ret Klass1) { - return _swig_wrap_new_Klass1() -} - -var _wrap_delete_Klass1 unsafe.Pointer - -func _swig_wrap_delete_Klass1(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Klass1, _swig_p) - return -} - -func DeleteKlass1(arg1 Klass1) { - _swig_wrap_delete_Klass1(arg1.Swigcptr()) -} - -type Klass1 interface { - Swigcptr() uintptr - SwigIsKlass1() -} - -type SwigcptrKlass2 uintptr - -func (p SwigcptrKlass2) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrKlass2) SwigIsKlass2() { -} - -var _wrap_new_Klass2 unsafe.Pointer - -func _swig_wrap_new_Klass2() (base SwigcptrKlass2) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Klass2, _swig_p) - return -} - -func NewKlass2() (_swig_ret Klass2) { - return _swig_wrap_new_Klass2() -} - -var _wrap_delete_Klass2 unsafe.Pointer - -func _swig_wrap_delete_Klass2(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Klass2, _swig_p) - return -} - -func DeleteKlass2(arg1 Klass2) { - _swig_wrap_delete_Klass2(arg1.Swigcptr()) -} - -type Klass2 interface { - Swigcptr() uintptr - SwigIsKlass2() -} - -type SwigcptrKlass3 uintptr - -func (p SwigcptrKlass3) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrKlass3) SwigIsKlass3() { -} - -var _wrap_new_Klass3 unsafe.Pointer - -func _swig_wrap_new_Klass3() (base SwigcptrKlass3) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Klass3, _swig_p) - return -} - -func NewKlass3() (_swig_ret Klass3) { - return _swig_wrap_new_Klass3() -} - -var _wrap_delete_Klass3 unsafe.Pointer - -func _swig_wrap_delete_Klass3(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Klass3, _swig_p) - return -} - -func DeleteKlass3(arg1 Klass3) { - _swig_wrap_delete_Klass3(arg1.Swigcptr()) -} - -type Klass3 interface { - Swigcptr() uintptr - SwigIsKlass3() -} - -type SwigcptrKlass4 uintptr - -func (p SwigcptrKlass4) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrKlass4) SwigIsKlass4() { -} - -var _wrap_new_Klass4 unsafe.Pointer - -func _swig_wrap_new_Klass4() (base SwigcptrKlass4) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Klass4, _swig_p) - return -} - -func NewKlass4() (_swig_ret Klass4) { - return _swig_wrap_new_Klass4() -} - -var _wrap_delete_Klass4 unsafe.Pointer - -func _swig_wrap_delete_Klass4(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Klass4, _swig_p) - return -} - -func DeleteKlass4(arg1 Klass4) { - _swig_wrap_delete_Klass4(arg1.Swigcptr()) -} - -type Klass4 interface { - Swigcptr() uintptr - SwigIsKlass4() -} - -type SwigcptrKlass5 uintptr - -func (p SwigcptrKlass5) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrKlass5) SwigIsKlass5() { -} - -var _wrap_new_Klass5 unsafe.Pointer - -func _swig_wrap_new_Klass5() (base SwigcptrKlass5) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Klass5, _swig_p) - return -} - -func NewKlass5() (_swig_ret Klass5) { - return _swig_wrap_new_Klass5() -} - -var _wrap_delete_Klass5 unsafe.Pointer - -func _swig_wrap_delete_Klass5(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Klass5, _swig_p) - return -} - -func DeleteKlass5(arg1 Klass5) { - _swig_wrap_delete_Klass5(arg1.Swigcptr()) -} - -type Klass5 interface { - Swigcptr() uintptr - SwigIsKlass5() -} - -type SwigcptrKlass6 uintptr - -func (p SwigcptrKlass6) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrKlass6) SwigIsKlass6() { -} - -var _wrap_new_Klass6 unsafe.Pointer - -func _swig_wrap_new_Klass6() (base SwigcptrKlass6) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Klass6, _swig_p) - return -} - -func NewKlass6() (_swig_ret Klass6) { - return _swig_wrap_new_Klass6() -} - -var _wrap_delete_Klass6 unsafe.Pointer - -func _swig_wrap_delete_Klass6(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Klass6, _swig_p) - return -} - -func DeleteKlass6(arg1 Klass6) { - _swig_wrap_delete_Klass6(arg1.Swigcptr()) -} - -type Klass6 interface { - Swigcptr() uintptr - SwigIsKlass6() -} - -type SwigcptrKlass7 uintptr - -func (p SwigcptrKlass7) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrKlass7) SwigIsKlass7() { -} - -var _wrap_new_Klass7 unsafe.Pointer - -func _swig_wrap_new_Klass7() (base SwigcptrKlass7) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Klass7, _swig_p) - return -} - -func NewKlass7() (_swig_ret Klass7) { - return _swig_wrap_new_Klass7() -} - -var _wrap_delete_Klass7 unsafe.Pointer - -func _swig_wrap_delete_Klass7(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Klass7, _swig_p) - return -} - -func DeleteKlass7(arg1 Klass7) { - _swig_wrap_delete_Klass7(arg1.Swigcptr()) -} - -type Klass7 interface { - Swigcptr() uintptr - SwigIsKlass7() -} - -type SwigcptrKlassMethods uintptr - -func (p SwigcptrKlassMethods) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrKlassMethods) SwigIsKlassMethods() { -} - -var _wrap_KlassMethods_methodA unsafe.Pointer - -func _swig_wrap_KlassMethods_methodA(base uintptr, _ uintptr, _ uintptr, _ uintptr, _ uintptr, _ uintptr, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_KlassMethods_methodA, _swig_p) - return -} - -func KlassMethodsMethodA(arg1 Klass1, arg2 Klass2, arg3 Klass3, arg4 Klass4, arg5 Klass5, arg6 Klass6, arg7 Klass7) { - _swig_wrap_KlassMethods_methodA(arg1.Swigcptr(), arg2.Swigcptr(), arg3.Swigcptr(), arg4.Swigcptr(), arg5.Swigcptr(), arg6.Swigcptr(), arg7.Swigcptr()) -} - -var _wrap_KlassMethods_methodB unsafe.Pointer - -func _swig_wrap_KlassMethods_methodB(base uintptr, _ uintptr, _ uintptr, _ uintptr, _ uintptr, _ uintptr, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_KlassMethods_methodB, _swig_p) - return -} - -func KlassMethodsMethodB(arg1 Klass1, arg2 Klass2, arg3 Klass3, arg4 Klass4, arg5 Klass5, arg6 Klass6, arg7 Klass7) { - _swig_wrap_KlassMethods_methodB(arg1.Swigcptr(), arg2.Swigcptr(), arg3.Swigcptr(), arg4.Swigcptr(), arg5.Swigcptr(), arg6.Swigcptr(), arg7.Swigcptr()) -} - -var _wrap_new_KlassMethods unsafe.Pointer - -func _swig_wrap_new_KlassMethods() (base SwigcptrKlassMethods) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_KlassMethods, _swig_p) - return -} - -func NewKlassMethods() (_swig_ret KlassMethods) { - return _swig_wrap_new_KlassMethods() -} - -var _wrap_delete_KlassMethods unsafe.Pointer - -func _swig_wrap_delete_KlassMethods(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_KlassMethods, _swig_p) - return -} - -func DeleteKlassMethods(arg1 KlassMethods) { - _swig_wrap_delete_KlassMethods(arg1.Swigcptr()) -} - -type KlassMethods interface { - Swigcptr() uintptr - SwigIsKlassMethods() -} - -type SwigcptrXYZ1 uintptr - -func (p SwigcptrXYZ1) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrXYZ1) SwigIsXYZ1() { -} - -var _wrap_new_XYZ1 unsafe.Pointer - -func _swig_wrap_new_XYZ1() (base SwigcptrXYZ1) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_XYZ1, _swig_p) - return -} - -func NewXYZ1() (_swig_ret XYZ1) { - return _swig_wrap_new_XYZ1() -} - -var _wrap_delete_XYZ1 unsafe.Pointer - -func _swig_wrap_delete_XYZ1(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_XYZ1, _swig_p) - return -} - -func DeleteXYZ1(arg1 XYZ1) { - _swig_wrap_delete_XYZ1(arg1.Swigcptr()) -} - -type XYZ1 interface { - Swigcptr() uintptr - SwigIsXYZ1() -} - -type SwigcptrXYZ2 uintptr - -func (p SwigcptrXYZ2) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrXYZ2) SwigIsXYZ2() { -} - -var _wrap_new_XYZ2 unsafe.Pointer - -func _swig_wrap_new_XYZ2() (base SwigcptrXYZ2) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_XYZ2, _swig_p) - return -} - -func NewXYZ2() (_swig_ret XYZ2) { - return _swig_wrap_new_XYZ2() -} - -var _wrap_delete_XYZ2 unsafe.Pointer - -func _swig_wrap_delete_XYZ2(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_XYZ2, _swig_p) - return -} - -func DeleteXYZ2(arg1 XYZ2) { - _swig_wrap_delete_XYZ2(arg1.Swigcptr()) -} - -type XYZ2 interface { - Swigcptr() uintptr - SwigIsXYZ2() -} - -type SwigcptrXYZ3 uintptr - -func (p SwigcptrXYZ3) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrXYZ3) SwigIsXYZ3() { -} - -var _wrap_new_XYZ3 unsafe.Pointer - -func _swig_wrap_new_XYZ3() (base SwigcptrXYZ3) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_XYZ3, _swig_p) - return -} - -func NewXYZ3() (_swig_ret XYZ3) { - return _swig_wrap_new_XYZ3() -} - -var _wrap_delete_XYZ3 unsafe.Pointer - -func _swig_wrap_delete_XYZ3(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_XYZ3, _swig_p) - return -} - -func DeleteXYZ3(arg1 XYZ3) { - _swig_wrap_delete_XYZ3(arg1.Swigcptr()) -} - -type XYZ3 interface { - Swigcptr() uintptr - SwigIsXYZ3() -} - -type SwigcptrXYZ4 uintptr - -func (p SwigcptrXYZ4) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrXYZ4) SwigIsXYZ4() { -} - -var _wrap_new_XYZ4 unsafe.Pointer - -func _swig_wrap_new_XYZ4() (base SwigcptrXYZ4) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_XYZ4, _swig_p) - return -} - -func NewXYZ4() (_swig_ret XYZ4) { - return _swig_wrap_new_XYZ4() -} - -var _wrap_delete_XYZ4 unsafe.Pointer - -func _swig_wrap_delete_XYZ4(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_XYZ4, _swig_p) - return -} - -func DeleteXYZ4(arg1 XYZ4) { - _swig_wrap_delete_XYZ4(arg1.Swigcptr()) -} - -type XYZ4 interface { - Swigcptr() uintptr - SwigIsXYZ4() -} - -type SwigcptrXYZ5 uintptr - -func (p SwigcptrXYZ5) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrXYZ5) SwigIsXYZ5() { -} - -var _wrap_new_XYZ5 unsafe.Pointer - -func _swig_wrap_new_XYZ5() (base SwigcptrXYZ5) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_XYZ5, _swig_p) - return -} - -func NewXYZ5() (_swig_ret XYZ5) { - return _swig_wrap_new_XYZ5() -} - -var _wrap_delete_XYZ5 unsafe.Pointer - -func _swig_wrap_delete_XYZ5(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_XYZ5, _swig_p) - return -} - -func DeleteXYZ5(arg1 XYZ5) { - _swig_wrap_delete_XYZ5(arg1.Swigcptr()) -} - -type XYZ5 interface { - Swigcptr() uintptr - SwigIsXYZ5() -} - -type SwigcptrXYZ6 uintptr - -func (p SwigcptrXYZ6) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrXYZ6) SwigIsXYZ6() { -} - -var _wrap_new_XYZ6 unsafe.Pointer - -func _swig_wrap_new_XYZ6() (base SwigcptrXYZ6) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_XYZ6, _swig_p) - return -} - -func NewXYZ6() (_swig_ret XYZ6) { - return _swig_wrap_new_XYZ6() -} - -var _wrap_delete_XYZ6 unsafe.Pointer - -func _swig_wrap_delete_XYZ6(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_XYZ6, _swig_p) - return -} - -func DeleteXYZ6(arg1 XYZ6) { - _swig_wrap_delete_XYZ6(arg1.Swigcptr()) -} - -type XYZ6 interface { - Swigcptr() uintptr - SwigIsXYZ6() -} - -type SwigcptrXYZ7 uintptr - -func (p SwigcptrXYZ7) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrXYZ7) SwigIsXYZ7() { -} - -var _wrap_new_XYZ7 unsafe.Pointer - -func _swig_wrap_new_XYZ7() (base SwigcptrXYZ7) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_XYZ7, _swig_p) - return -} - -func NewXYZ7() (_swig_ret XYZ7) { - return _swig_wrap_new_XYZ7() -} - -var _wrap_delete_XYZ7 unsafe.Pointer - -func _swig_wrap_delete_XYZ7(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_XYZ7, _swig_p) - return -} - -func DeleteXYZ7(arg1 XYZ7) { - _swig_wrap_delete_XYZ7(arg1.Swigcptr()) -} - -type XYZ7 interface { - Swigcptr() uintptr - SwigIsXYZ7() -} - -type SwigcptrXYZMethods uintptr - -func (p SwigcptrXYZMethods) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrXYZMethods) SwigIsXYZMethods() { -} - -var _wrap_XYZMethods_methodA unsafe.Pointer - -func _swig_wrap_XYZMethods_methodA(base uintptr, _ uintptr, _ uintptr, _ uintptr, _ uintptr, _ uintptr, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_XYZMethods_methodA, _swig_p) - return -} - -func XYZMethodsMethodA(arg1 XYZ1, arg2 XYZ2, arg3 XYZ3, arg4 XYZ4, arg5 XYZ5, arg6 XYZ6, arg7 XYZ7) { - _swig_wrap_XYZMethods_methodA(arg1.Swigcptr(), arg2.Swigcptr(), arg3.Swigcptr(), arg4.Swigcptr(), arg5.Swigcptr(), arg6.Swigcptr(), arg7.Swigcptr()) -} - -var _wrap_XYZMethods_methodB unsafe.Pointer - -func _swig_wrap_XYZMethods_methodB(base uintptr, _ uintptr, _ uintptr, _ uintptr, _ uintptr, _ uintptr, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_XYZMethods_methodB, _swig_p) - return -} - -func XYZMethodsMethodB(arg1 XYZ1, arg2 XYZ2, arg3 XYZ3, arg4 XYZ4, arg5 XYZ5, arg6 XYZ6, arg7 XYZ7) { - _swig_wrap_XYZMethods_methodB(arg1.Swigcptr(), arg2.Swigcptr(), arg3.Swigcptr(), arg4.Swigcptr(), arg5.Swigcptr(), arg6.Swigcptr(), arg7.Swigcptr()) -} - -var _wrap_new_XYZMethods unsafe.Pointer - -func _swig_wrap_new_XYZMethods() (base SwigcptrXYZMethods) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_XYZMethods, _swig_p) - return -} - -func NewXYZMethods() (_swig_ret XYZMethods) { - return _swig_wrap_new_XYZMethods() -} - -var _wrap_delete_XYZMethods unsafe.Pointer - -func _swig_wrap_delete_XYZMethods(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_XYZMethods, _swig_p) - return -} - -func DeleteXYZMethods(arg1 XYZMethods) { - _swig_wrap_delete_XYZMethods(arg1.Swigcptr()) -} - -type XYZMethods interface { - Swigcptr() uintptr - SwigIsXYZMethods() -} - -type AnEnum1 int -var _wrap_anenum1 unsafe.Pointer - -func _swig_getanenum1() (_swig_ret AnEnum1) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_anenum1, _swig_p) - return -} -var Anenum1 AnEnum1 = _swig_getanenum1() -type AnEnum2 int -var _wrap_anenum2 unsafe.Pointer - -func _swig_getanenum2() (_swig_ret AnEnum2) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_anenum2, _swig_p) - return -} -var Anenum2 AnEnum2 = _swig_getanenum2() -type AnEnum3 int -var _wrap_anenum3 unsafe.Pointer - -func _swig_getanenum3() (_swig_ret AnEnum3) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_anenum3, _swig_p) - return -} -var Anenum3 AnEnum3 = _swig_getanenum3() -type SwigcptrAnEnumMethods uintptr - -func (p SwigcptrAnEnumMethods) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrAnEnumMethods) SwigIsAnEnumMethods() { -} - -var _wrap_AnEnumMethods_methodA unsafe.Pointer - -func _swig_wrap_AnEnumMethods_methodA(base AnEnum1, _ AnEnum2, _ *AnEnum3) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_AnEnumMethods_methodA, _swig_p) - return -} - -func AnEnumMethodsMethodA(arg1 AnEnum1, arg2 AnEnum2, arg3 *AnEnum3) { - _swig_wrap_AnEnumMethods_methodA(arg1, arg2, arg3) -} - -var _wrap_AnEnumMethods_methodB unsafe.Pointer - -func _swig_wrap_AnEnumMethods_methodB(base AnEnum1, _ AnEnum2, _ *AnEnum3) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_AnEnumMethods_methodB, _swig_p) - return -} - -func AnEnumMethodsMethodB(arg1 AnEnum1, arg2 AnEnum2, arg3 *AnEnum3) { - _swig_wrap_AnEnumMethods_methodB(arg1, arg2, arg3) -} - -var _wrap_new_AnEnumMethods unsafe.Pointer - -func _swig_wrap_new_AnEnumMethods() (base SwigcptrAnEnumMethods) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_AnEnumMethods, _swig_p) - return -} - -func NewAnEnumMethods() (_swig_ret AnEnumMethods) { - return _swig_wrap_new_AnEnumMethods() -} - -var _wrap_delete_AnEnumMethods unsafe.Pointer - -func _swig_wrap_delete_AnEnumMethods(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_AnEnumMethods, _swig_p) - return -} - -func DeleteAnEnumMethods(arg1 AnEnumMethods) { - _swig_wrap_delete_AnEnumMethods(arg1.Swigcptr()) -} - -type AnEnumMethods interface { - Swigcptr() uintptr - SwigIsAnEnumMethods() -} - -type SpaceTheEnum1 int -var _wrap_theenum1 unsafe.Pointer - -func _swig_gettheenum1() (_swig_ret SpaceTheEnum1) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_theenum1, _swig_p) - return -} -var Theenum1 SpaceTheEnum1 = _swig_gettheenum1() -type SpaceTheEnum2 int -var _wrap_theenum2 unsafe.Pointer - -func _swig_gettheenum2() (_swig_ret SpaceTheEnum2) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_theenum2, _swig_p) - return -} -var Theenum2 SpaceTheEnum2 = _swig_gettheenum2() -type SpaceTheEnum3 int -var _wrap_theenum3 unsafe.Pointer - -func _swig_gettheenum3() (_swig_ret SpaceTheEnum3) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_theenum3, _swig_p) - return -} -var Theenum3 SpaceTheEnum3 = _swig_gettheenum3() -type SwigcptrTheEnumMethods uintptr - -func (p SwigcptrTheEnumMethods) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrTheEnumMethods) SwigIsTheEnumMethods() { -} - -var _wrap_TheEnumMethods_methodA unsafe.Pointer - -func _swig_wrap_TheEnumMethods_methodA(base SpaceTheEnum1, _ SpaceTheEnum2, _ *SpaceTheEnum3) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_TheEnumMethods_methodA, _swig_p) - return -} - -func TheEnumMethodsMethodA(arg1 SpaceTheEnum1, arg2 SpaceTheEnum2, arg3 *SpaceTheEnum3) { - _swig_wrap_TheEnumMethods_methodA(arg1, arg2, arg3) -} - -var _wrap_TheEnumMethods_methodB unsafe.Pointer - -func _swig_wrap_TheEnumMethods_methodB(base SpaceTheEnum1, _ SpaceTheEnum2, _ *SpaceTheEnum3) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_TheEnumMethods_methodB, _swig_p) - return -} - -func TheEnumMethodsMethodB(arg1 SpaceTheEnum1, arg2 SpaceTheEnum2, arg3 *SpaceTheEnum3) { - _swig_wrap_TheEnumMethods_methodB(arg1, arg2, arg3) -} - -var _wrap_new_TheEnumMethods unsafe.Pointer - -func _swig_wrap_new_TheEnumMethods() (base SwigcptrTheEnumMethods) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_TheEnumMethods, _swig_p) - return -} - -func NewTheEnumMethods() (_swig_ret TheEnumMethods) { - return _swig_wrap_new_TheEnumMethods() -} - -var _wrap_delete_TheEnumMethods unsafe.Pointer - -func _swig_wrap_delete_TheEnumMethods(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_TheEnumMethods, _swig_p) - return -} - -func DeleteTheEnumMethods(arg1 TheEnumMethods) { - _swig_wrap_delete_TheEnumMethods(arg1.Swigcptr()) -} - -type TheEnumMethods interface { - Swigcptr() uintptr - SwigIsTheEnumMethods() -} - -var _wrap_getKlass1A unsafe.Pointer - -func _swig_wrap_getKlass1A() (base SwigcptrKlass1) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_getKlass1A, _swig_p) - return -} - -func GetKlass1A() (_swig_ret Klass1) { - return _swig_wrap_getKlass1A() -} - -var _wrap_getKlass1B unsafe.Pointer - -func _swig_wrap_getKlass1B() (base SwigcptrKlass1) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_getKlass1B, _swig_p) - return -} - -func GetKlass1B() (_swig_ret Klass1) { - return _swig_wrap_getKlass1B() -} - -var _wrap_getKlass2A unsafe.Pointer - -func _swig_wrap_getKlass2A() (base SwigcptrKlass2) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_getKlass2A, _swig_p) - return -} - -func GetKlass2A() (_swig_ret Klass2) { - return _swig_wrap_getKlass2A() -} - -var _wrap_getKlass2B unsafe.Pointer - -func _swig_wrap_getKlass2B() (base SwigcptrKlass2) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_getKlass2B, _swig_p) - return -} - -func GetKlass2B() (_swig_ret Klass2) { - return _swig_wrap_getKlass2B() -} - -var _wrap_getKlass3A unsafe.Pointer - -func _swig_wrap_getKlass3A() (base SwigcptrKlass3) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_getKlass3A, _swig_p) - return -} - -func GetKlass3A() (_swig_ret Klass3) { - return _swig_wrap_getKlass3A() -} - -var _wrap_getKlass3B unsafe.Pointer - -func _swig_wrap_getKlass3B() (base SwigcptrKlass3) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_getKlass3B, _swig_p) - return -} - -func GetKlass3B() (_swig_ret Klass3) { - return _swig_wrap_getKlass3B() -} - -var _wrap_getKlass4A unsafe.Pointer - -func _swig_wrap_getKlass4A() (base SwigcptrKlass4) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_getKlass4A, _swig_p) - return -} - -func GetKlass4A() (_swig_ret Klass4) { - return _swig_wrap_getKlass4A() -} - -var _wrap_getKlass4B unsafe.Pointer - -func _swig_wrap_getKlass4B() (base SwigcptrKlass4) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_getKlass4B, _swig_p) - return -} - -func GetKlass4B() (_swig_ret Klass4) { - return _swig_wrap_getKlass4B() -} - -var _wrap_getKlass5A unsafe.Pointer - -func _swig_wrap_getKlass5A() (base SwigcptrKlass5) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_getKlass5A, _swig_p) - return -} - -func GetKlass5A() (_swig_ret Klass5) { - return _swig_wrap_getKlass5A() -} - -var _wrap_getKlass5B unsafe.Pointer - -func _swig_wrap_getKlass5B() (base SwigcptrKlass5) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_getKlass5B, _swig_p) - return -} - -func GetKlass5B() (_swig_ret Klass5) { - return _swig_wrap_getKlass5B() -} - -var _wrap_getKlass6A unsafe.Pointer - -func _swig_wrap_getKlass6A() (base SwigcptrKlass6) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_getKlass6A, _swig_p) - return -} - -func GetKlass6A() (_swig_ret Klass6) { - return _swig_wrap_getKlass6A() -} - -var _wrap_getKlass6B unsafe.Pointer - -func _swig_wrap_getKlass6B() (base SwigcptrKlass6) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_getKlass6B, _swig_p) - return -} - -func GetKlass6B() (_swig_ret Klass6) { - return _swig_wrap_getKlass6B() -} - -var _wrap_getKlass7A unsafe.Pointer - -func _swig_wrap_getKlass7A() (base SwigcptrKlass7) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_getKlass7A, _swig_p) - return -} - -func GetKlass7A() (_swig_ret Klass7) { - return _swig_wrap_getKlass7A() -} - -var _wrap_getKlass7B unsafe.Pointer - -func _swig_wrap_getKlass7B() (base SwigcptrKlass7) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_getKlass7B, _swig_p) - return -} - -func GetKlass7B() (_swig_ret Klass7) { - return _swig_wrap_getKlass7B() -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/global_ns_arg.go b/Examples/test-suite/go/global_ns_arg.go deleted file mode 100644 index 5d67fc215..000000000 --- a/Examples/test-suite/go/global_ns_arg.go +++ /dev/null @@ -1,43 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../global_ns_arg.i - -package global_ns_arg - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -var _wrap_foo unsafe.Pointer - -func Foo(arg1 int) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_foo, _swig_p) - return -} -var _wrap_bar_fn unsafe.Pointer - -func Bar_fn() (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_bar_fn, _swig_p) - return -} - diff --git a/Examples/test-suite/go/global_ns_arg_runme b/Examples/test-suite/go/global_ns_arg_runme deleted file mode 100755 index e832d6e8f..000000000 Binary files a/Examples/test-suite/go/global_ns_arg_runme and /dev/null differ diff --git a/Examples/test-suite/go/global_scope_types.go b/Examples/test-suite/go/global_scope_types.go deleted file mode 100644 index dbf3c072d..000000000 --- a/Examples/test-suite/go/global_scope_types.go +++ /dev/null @@ -1,194 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../global_scope_types.i - -package global_scope_types - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrDingaling uintptr - -func (p SwigcptrDingaling) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrDingaling) SwigIsDingaling() { -} - -type Dingaling interface { - Swigcptr() uintptr - SwigIsDingaling() -} - -type SwigcptrTing uintptr - -func (p SwigcptrTing) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrTing) SwigIsTing() { -} - -var _wrap_new_Ting unsafe.Pointer - -func _swig_wrap_new_Ting() (base SwigcptrTing) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Ting, _swig_p) - return -} - -func NewTing() (_swig_ret Ting) { - return _swig_wrap_new_Ting() -} - -var _wrap_delete_Ting unsafe.Pointer - -func _swig_wrap_delete_Ting(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Ting, _swig_p) - return -} - -func DeleteTing(arg1 Ting) { - _swig_wrap_delete_Ting(arg1.Swigcptr()) -} - -type Ting interface { - Swigcptr() uintptr - SwigIsTing() -} - -type SwigcptrTest uintptr - -func (p SwigcptrTest) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrTest) SwigIsTest() { -} - -var _wrap_Test_something unsafe.Pointer - -func _swig_wrap_Test_something(base SwigcptrTest, _ uintptr, _ uintptr, _ uintptr, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Test_something, _swig_p) - return -} - -func (arg1 SwigcptrTest) Something(arg2 Dingaling, arg3 Dingaling, arg4 Dingaling, arg5 Dingaling) { - _swig_wrap_Test_something(arg1, arg2.Swigcptr(), arg3.Swigcptr(), arg4.Swigcptr(), arg5.Swigcptr()) -} - -var _wrap_Test_tsomething unsafe.Pointer - -func _swig_wrap_Test_tsomething(base SwigcptrTest, _ uintptr, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Test_tsomething, _swig_p) - return -} - -func (arg1 SwigcptrTest) Tsomething(arg2 MyTemplate_Sl__Dingaling_Sg_, arg3 MyTemplate_Sl_Dingaling_SS_const_Sm__Sg_) { - _swig_wrap_Test_tsomething(arg1, arg2.Swigcptr(), arg3.Swigcptr()) -} - -var _wrap_Test_nothing unsafe.Pointer - -func _swig_wrap_Test_nothing(base SwigcptrTest, _ uintptr, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Test_nothing, _swig_p) - return -} - -func (arg1 SwigcptrTest) Nothing(arg2 Ting, arg3 Ting) { - _swig_wrap_Test_nothing(arg1, arg2.Swigcptr(), arg3.Swigcptr()) -} - -var _wrap_new_Test unsafe.Pointer - -func _swig_wrap_new_Test() (base SwigcptrTest) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Test, _swig_p) - return -} - -func NewTest() (_swig_ret Test) { - return _swig_wrap_new_Test() -} - -var _wrap_delete_Test unsafe.Pointer - -func _swig_wrap_delete_Test(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Test, _swig_p) - return -} - -func DeleteTest(arg1 Test) { - _swig_wrap_delete_Test(arg1.Swigcptr()) -} - -type Test interface { - Swigcptr() uintptr - SwigIsTest() - Something(arg2 Dingaling, arg3 Dingaling, arg4 Dingaling, arg5 Dingaling) - Tsomething(arg2 MyTemplate_Sl__Dingaling_Sg_, arg3 MyTemplate_Sl_Dingaling_SS_const_Sm__Sg_) - Nothing(arg2 Ting, arg3 Ting) -} - -var _wrap_funcptrtest unsafe.Pointer - -func _swig_wrap_funcptrtest(base _swig_fnptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_funcptrtest, _swig_p) - return -} - -func Funcptrtest(arg1 _swig_fnptr) { - _swig_wrap_funcptrtest(arg1) -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - -type SwigcptrMyTemplate_Sl__Dingaling_Sg_ uintptr -type MyTemplate_Sl__Dingaling_Sg_ interface { - Swigcptr() uintptr; -} -func (p SwigcptrMyTemplate_Sl__Dingaling_Sg_) Swigcptr() uintptr { - return uintptr(p) -} - -type SwigcptrMyTemplate_Sl_Dingaling_SS_const_Sm__Sg_ uintptr -type MyTemplate_Sl_Dingaling_SS_const_Sm__Sg_ interface { - Swigcptr() uintptr; -} -func (p SwigcptrMyTemplate_Sl_Dingaling_SS_const_Sm__Sg_) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/global_vars.go b/Examples/test-suite/go/global_vars.go deleted file mode 100644 index 53b454234..000000000 --- a/Examples/test-suite/go/global_vars.go +++ /dev/null @@ -1,378 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../global_vars.i - -package global_vars - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrA uintptr - -func (p SwigcptrA) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrA) SwigIsA() { -} - -var _wrap_A_x_set unsafe.Pointer - -func _swig_wrap_A_x_set(base SwigcptrA, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_A_x_set, _swig_p) - return -} - -func (arg1 SwigcptrA) SetX(arg2 int) { - _swig_wrap_A_x_set(arg1, arg2) -} - -var _wrap_A_x_get unsafe.Pointer - -func _swig_wrap_A_x_get(base SwigcptrA) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_A_x_get, _swig_p) - return -} - -func (arg1 SwigcptrA) GetX() (_swig_ret int) { - return _swig_wrap_A_x_get(arg1) -} - -var _wrap_new_A unsafe.Pointer - -func _swig_wrap_new_A() (base SwigcptrA) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_A, _swig_p) - return -} - -func NewA() (_swig_ret A) { - return _swig_wrap_new_A() -} - -var _wrap_delete_A unsafe.Pointer - -func _swig_wrap_delete_A(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_A, _swig_p) - return -} - -func DeleteA(arg1 A) { - _swig_wrap_delete_A(arg1.Swigcptr()) -} - -type A interface { - Swigcptr() uintptr - SwigIsA() - SetX(arg2 int) - GetX() (_swig_ret int) -} - -var _wrap_b_set unsafe.Pointer - -func _swig_wrap_b_set(base string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_b_set, _swig_p) - return -} - -func SetB(arg1 string) { - _swig_wrap_b_set(arg1) -} - -var _wrap_b_get unsafe.Pointer - -func GetB() (_swig_ret string) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_b_get, _swig_p) - return -} -var _wrap_a_set unsafe.Pointer - -func _swig_wrap_a_set(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_a_set, _swig_p) - return -} - -func SetA(arg1 A) { - _swig_wrap_a_set(arg1.Swigcptr()) -} - -var _wrap_a_get unsafe.Pointer - -func _swig_wrap_a_get() (base SwigcptrA) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_a_get, _swig_p) - return -} - -func GetA() (_swig_ret A) { - return _swig_wrap_a_get() -} - -var _wrap_ap_set unsafe.Pointer - -func _swig_wrap_ap_set(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_ap_set, _swig_p) - return -} - -func SetAp(arg1 A) { - _swig_wrap_ap_set(arg1.Swigcptr()) -} - -var _wrap_ap_get unsafe.Pointer - -func _swig_wrap_ap_get() (base SwigcptrA) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_ap_get, _swig_p) - return -} - -func GetAp() (_swig_ret A) { - return _swig_wrap_ap_get() -} - -var _wrap_cap_set unsafe.Pointer - -func _swig_wrap_cap_set(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_cap_set, _swig_p) - return -} - -func SetCap(arg1 A) { - _swig_wrap_cap_set(arg1.Swigcptr()) -} - -var _wrap_cap_get unsafe.Pointer - -func _swig_wrap_cap_get() (base SwigcptrA) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_cap_get, _swig_p) - return -} - -func GetCap() (_swig_ret A) { - return _swig_wrap_cap_get() -} - -var _wrap_ar_set unsafe.Pointer - -func _swig_wrap_ar_set(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_ar_set, _swig_p) - return -} - -func SetAr(arg1 A) { - _swig_wrap_ar_set(arg1.Swigcptr()) -} - -var _wrap_ar_get unsafe.Pointer - -func _swig_wrap_ar_get() (base SwigcptrA) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_ar_get, _swig_p) - return -} - -func GetAr() (_swig_ret A) { - return _swig_wrap_ar_get() -} - -var _wrap_x_set unsafe.Pointer - -func _swig_wrap_x_set(base int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_x_set, _swig_p) - return -} - -func SetX(arg1 int) { - _swig_wrap_x_set(arg1) -} - -var _wrap_x_get unsafe.Pointer - -func GetX() (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_x_get, _swig_p) - return -} -var _wrap_xp_set unsafe.Pointer - -func _swig_wrap_xp_set(base *int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_xp_set, _swig_p) - return -} - -func SetXp(arg1 *int) { - _swig_wrap_xp_set(arg1) -} - -var _wrap_xp_get unsafe.Pointer - -func GetXp() (_swig_ret *int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_xp_get, _swig_p) - return -} -var _wrap_c_member_set unsafe.Pointer - -func _swig_wrap_c_member_set(base *int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_c_member_set, _swig_p) - return -} - -func SetC_member(arg1 *int) { - _swig_wrap_c_member_set(arg1) -} - -var _wrap_c_member_get unsafe.Pointer - -func GetC_member() (_swig_ret *int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_c_member_get, _swig_p) - return -} -var _wrap_vp_set unsafe.Pointer - -func _swig_wrap_vp_set(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_vp_set, _swig_p) - return -} - -func SetVp(arg1 uintptr) { - _swig_wrap_vp_set(arg1) -} - -var _wrap_vp_get unsafe.Pointer - -func GetVp() (_swig_ret uintptr) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_vp_get, _swig_p) - return -} -type Hello int -var _wrap_Hi unsafe.Pointer - -func _swig_getHi() (_swig_ret Hello) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_Hi, _swig_p) - return -} -var Hi Hello = _swig_getHi() -var _wrap_Hola unsafe.Pointer - -func _swig_getHola() (_swig_ret Hello) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_Hola, _swig_p) - return -} -var Hola Hello = _swig_getHola() -var _wrap_h_set unsafe.Pointer - -func _swig_wrap_h_set(base Hello) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_h_set, _swig_p) - return -} - -func SetH(arg1 Hello) { - _swig_wrap_h_set(arg1) -} - -var _wrap_h_get unsafe.Pointer - -func GetH() (_swig_ret Hello) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_h_get, _swig_p) - return -} -var _wrap_hp_set unsafe.Pointer - -func _swig_wrap_hp_set(base *Hello) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_hp_set, _swig_p) - return -} - -func SetHp(arg1 *Hello) { - _swig_wrap_hp_set(arg1) -} - -var _wrap_hp_get unsafe.Pointer - -func GetHp() (_swig_ret *Hello) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_hp_get, _swig_p) - return -} -var _wrap_hr_set unsafe.Pointer - -func _swig_wrap_hr_set(base *Hello) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_hr_set, _swig_p) - return -} - -func SetHr(arg1 *Hello) { - _swig_wrap_hr_set(arg1) -} - -var _wrap_hr_get unsafe.Pointer - -func GetHr() (_swig_ret *Hello) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_hr_get, _swig_p) - return -} -var _wrap_init unsafe.Pointer - -func _swig_wrap_init() { - var _swig_p uintptr - _cgo_runtime_cgocall(_wrap_init, _swig_p) - return -} - -func Init() { - _swig_wrap_init() -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/go_director_inout.go b/Examples/test-suite/go/go_director_inout.go deleted file mode 100644 index e99706285..000000000 --- a/Examples/test-suite/go/go_director_inout.go +++ /dev/null @@ -1,360 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../go_director_inout.i - -package go_director_inout - -import "unsafe" -import _ "runtime/cgo" -import "encoding/json" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - - - -type GoRetStruct struct { - Str string -} - - -type SwigcptrMyStruct uintptr - -func (p SwigcptrMyStruct) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrMyStruct) SwigIsMyStruct() { -} - -var _wrap_MyStruct_str_set unsafe.Pointer - -func _swig_wrap_MyStruct_str_set(base SwigcptrMyStruct, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_MyStruct_str_set, _swig_p) - return -} - -func (arg1 SwigcptrMyStruct) SetStr(arg2 Std_string) { - _swig_wrap_MyStruct_str_set(arg1, arg2.Swigcptr()) -} - -var _wrap_MyStruct_str_get unsafe.Pointer - -func _swig_wrap_MyStruct_str_get(base SwigcptrMyStruct) (_ SwigcptrStd_string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_MyStruct_str_get, _swig_p) - return -} - -func (arg1 SwigcptrMyStruct) GetStr() (_swig_ret Std_string) { - return _swig_wrap_MyStruct_str_get(arg1) -} - -var _wrap_new_MyStruct unsafe.Pointer - -func _swig_wrap_new_MyStruct() (base SwigcptrMyStruct) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_MyStruct, _swig_p) - return -} - -func NewMyStruct() (_swig_ret MyStruct) { - return _swig_wrap_new_MyStruct() -} - -var _wrap_delete_MyStruct unsafe.Pointer - -func _swig_wrap_delete_MyStruct(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_MyStruct, _swig_p) - return -} - -func DeleteMyStruct(arg1 MyStruct) { - _swig_wrap_delete_MyStruct(arg1.Swigcptr()) -} - -type MyStruct interface { - Swigcptr() uintptr - SwigIsMyStruct() - SetStr(arg2 Std_string) - GetStr() (_swig_ret Std_string) -} - -type SwigcptrRetStruct uintptr - -func (p SwigcptrRetStruct) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrRetStruct) SwigIsRetStruct() { -} - -var _wrap_RetStruct_str_set unsafe.Pointer - -func _swig_wrap_RetStruct_str_set(base SwigcptrRetStruct, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_RetStruct_str_set, _swig_p) - return -} - -func (arg1 SwigcptrRetStruct) SetStr(arg2 Std_string) { - _swig_wrap_RetStruct_str_set(arg1, arg2.Swigcptr()) -} - -var _wrap_RetStruct_str_get unsafe.Pointer - -func _swig_wrap_RetStruct_str_get(base SwigcptrRetStruct) (_ SwigcptrStd_string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_RetStruct_str_get, _swig_p) - return -} - -func (arg1 SwigcptrRetStruct) GetStr() (_swig_ret Std_string) { - return _swig_wrap_RetStruct_str_get(arg1) -} - -var _wrap_new_RetStruct unsafe.Pointer - -func _swig_wrap_new_RetStruct() (base SwigcptrRetStruct) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_RetStruct, _swig_p) - return -} - -func NewRetStruct() (_swig_ret RetStruct) { - return _swig_wrap_new_RetStruct() -} - -var _wrap_delete_RetStruct unsafe.Pointer - -func _swig_wrap_delete_RetStruct(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_RetStruct, _swig_p) - return -} - -func DeleteRetStruct(arg1 RetStruct) { - _swig_wrap_delete_RetStruct(arg1.Swigcptr()) -} - -type RetStruct interface { - Swigcptr() uintptr - SwigIsRetStruct() - SetStr(arg2 Std_string) - GetStr() (_swig_ret Std_string) -} - -type _swig_DirectorMyClass struct { - SwigcptrMyClass - v interface{} -} - -func (p *_swig_DirectorMyClass) Swigcptr() uintptr { - return p.SwigcptrMyClass.Swigcptr() -} - -func (p *_swig_DirectorMyClass) SwigIsMyClass() { -} - -func (p *_swig_DirectorMyClass) DirectorInterface() interface{} { - return p.v -} - -var _wrap__swig_NewDirectorMyClassMyClass unsafe.Pointer - -func _swig_NewDirectorMyClassMyClass(_swig_director *_swig_DirectorMyClass) (_swig_ret SwigcptrMyClass) { - _swig_p := uintptr(unsafe.Pointer(&_swig_director)) - _cgo_runtime_cgocall(_wrap__swig_NewDirectorMyClassMyClass, _swig_p) - return -} - -func NewDirectorMyClass(v interface{}) MyClass { - p := &_swig_DirectorMyClass{0, v} - p.SwigcptrMyClass = _swig_NewDirectorMyClassMyClass(p) - return p -} - -var _wrap_DeleteDirectorMyClass unsafe.Pointer - -func _swig_wrap_DeleteDirectorMyClass(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_DeleteDirectorMyClass, _swig_p) - return -} - -func DeleteDirectorMyClass(arg1 MyClass) { - _swig_wrap_DeleteDirectorMyClass(arg1.Swigcptr()) -} - -func Swiggo_DeleteDirector_MyClass(p *_swig_DirectorMyClass) { - p.SwigcptrMyClass = 0 -} - -type _swig_DirectorInterfaceMyClassAdjust interface { - Adjust(map[string]interface{}) GoRetStruct -} - -var _wrap__swig_DirectorMyClass_upcall_Adjust unsafe.Pointer - -func _swig_wrap__swig_DirectorMyClass_upcall_Adjust(_swig_ptr SwigcptrMyClass, _ string) (_swig_ret string) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) - _cgo_runtime_cgocall(_wrap__swig_DirectorMyClass_upcall_Adjust, _swig_p) - return -} - -func (swig_p *_swig_DirectorMyClass) Adjust(s map[string]interface{}) GoRetStruct { - if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceMyClassAdjust); swig_ok { - return swig_g.Adjust(s) - } - var swig_r string - var _swig_i_0 string - if b, err := json.Marshal(s); err != nil { - panic(err) - } else { - _swig_i_0 = string(b) - } - swig_r = _swig_wrap__swig_DirectorMyClass_upcall_Adjust(swig_p.SwigcptrMyClass, _swig_i_0) - var swig_r_1 GoRetStruct - - swig_r_1 = GoRetStruct{Str: swig_r} - return swig_r_1 -} - -func DirectorMyClassAdjust(p MyClass, arg2 map[string]interface{}) GoRetStruct { - var swig_r string - var _swig_i_0 string - if b, err := json.Marshal(arg2); err != nil { - panic(err) - } else { - _swig_i_0 = string(b) - } - swig_r = _swig_wrap__swig_DirectorMyClass_upcall_Adjust(p.(*_swig_DirectorMyClass).SwigcptrMyClass, _swig_i_0) - var swig_r_1 GoRetStruct - - swig_r_1 = GoRetStruct{Str: swig_r} - return swig_r_1 -} - -func Swig_DirectorMyClass_callback_Adjust(p *_swig_DirectorMyClass, arg2 string) (swig_result string) { - var swig_r GoRetStruct - var _swig_i_0 map[string]interface{} - if err := json.Unmarshal([]byte(arg2), &_swig_i_0); err != nil { - panic(err) - } - swig_r = p.Adjust(_swig_i_0) - var swig_r_1 string - - swig_r_1 = swig_r.Str - return swig_r_1 -} - -type SwigcptrMyClass uintptr - -func (p SwigcptrMyClass) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrMyClass) SwigIsMyClass() { -} - -func (p SwigcptrMyClass) DirectorInterface() interface{} { - return nil -} - -var _wrap_delete_MyClass unsafe.Pointer - -func _swig_wrap_delete_MyClass(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_MyClass, _swig_p) - return -} - -func DeleteMyClass(arg1 MyClass) { - _swig_wrap_delete_MyClass(arg1.Swigcptr()) -} - -var _wrap_MyClass_Adjust unsafe.Pointer - -func _swig_wrap_MyClass_Adjust(base SwigcptrMyClass, _ string) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_MyClass_Adjust, _swig_p) - return -} - -func (arg1 SwigcptrMyClass) Adjust(arg2 map[string]interface{}) (_swig_ret GoRetStruct) { - var swig_r string - var _swig_i_1 string - if b, err := json.Marshal(arg2); err != nil { - panic(err) - } else { - _swig_i_1 = string(b) - } - swig_r = _swig_wrap_MyClass_Adjust(arg1, _swig_i_1) - var swig_r_1 GoRetStruct - - swig_r_1 = GoRetStruct{Str: swig_r} - return swig_r_1 -} - -var _wrap_new_MyClass unsafe.Pointer - -func _swig_wrap_new_MyClass() (base SwigcptrMyClass) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_MyClass, _swig_p) - return -} - -func NewMyClass() (_swig_ret MyClass) { - return _swig_wrap_new_MyClass() -} - -type MyClass interface { - Swigcptr() uintptr - SwigIsMyClass() - DirectorInterface() interface{} - Adjust(arg2 map[string]interface{}) (_swig_ret GoRetStruct) -} - - -type SwigcptrStd_string uintptr -type Std_string interface { - Swigcptr() uintptr; -} -func (p SwigcptrStd_string) Swigcptr() uintptr { - return uintptr(p) -} - -type SwigcptrSwigDirector_MyClass uintptr -type SwigDirector_MyClass interface { - Swigcptr() uintptr; -} -func (p SwigcptrSwigDirector_MyClass) Swigcptr() uintptr { - return uintptr(p) -} - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/go_director_inout_runme b/Examples/test-suite/go/go_director_inout_runme deleted file mode 100755 index dba75e9b0..000000000 Binary files a/Examples/test-suite/go/go_director_inout_runme and /dev/null differ diff --git a/Examples/test-suite/go/go_director_inout_wrap.h b/Examples/test-suite/go/go_director_inout_wrap.h deleted file mode 100644 index 0be205b04..000000000 --- a/Examples/test-suite/go/go_director_inout_wrap.h +++ /dev/null @@ -1,29 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../go_director_inout.i - -#ifndef SWIG_go_director_inout_WRAP_H_ -#define SWIG_go_director_inout_WRAP_H_ - -class SwigDirector_MyClass : public MyClass -{ - public: - SwigDirector_MyClass(void *swig_p); - virtual ~SwigDirector_MyClass(); - RetStruct _swig_upcall_Adjust(MyStruct s) { - return MyClass::Adjust(s); - } - virtual RetStruct Adjust(MyStruct s); - private: - void *go_val; -}; - -#endif diff --git a/Examples/test-suite/go/go_inout.go b/Examples/test-suite/go/go_inout.go deleted file mode 100644 index 6d8c34f5b..000000000 --- a/Examples/test-suite/go/go_inout.go +++ /dev/null @@ -1,355 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../go_inout.i - -package go_inout - -import "unsafe" -import _ "runtime/cgo" -import "encoding/json" -import "bytes" -import "encoding/binary" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - - - -type In json.Marshaler - - -type SwigcptrMyStruct uintptr - -func (p SwigcptrMyStruct) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrMyStruct) SwigIsMyStruct() { -} - -var _wrap_MyStruct_str_set unsafe.Pointer - -func _swig_wrap_MyStruct_str_set(base SwigcptrMyStruct, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_MyStruct_str_set, _swig_p) - return -} - -func (arg1 SwigcptrMyStruct) SetStr(arg2 Std_string) { - _swig_wrap_MyStruct_str_set(arg1, arg2.Swigcptr()) -} - -var _wrap_MyStruct_str_get unsafe.Pointer - -func _swig_wrap_MyStruct_str_get(base SwigcptrMyStruct) (_ SwigcptrStd_string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_MyStruct_str_get, _swig_p) - return -} - -func (arg1 SwigcptrMyStruct) GetStr() (_swig_ret Std_string) { - return _swig_wrap_MyStruct_str_get(arg1) -} - -var _wrap_new_MyStruct unsafe.Pointer - -func _swig_wrap_new_MyStruct() (base SwigcptrMyStruct) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_MyStruct, _swig_p) - return -} - -func NewMyStruct() (_swig_ret MyStruct) { - return _swig_wrap_new_MyStruct() -} - -var _wrap_delete_MyStruct unsafe.Pointer - -func _swig_wrap_delete_MyStruct(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_MyStruct, _swig_p) - return -} - -func DeleteMyStruct(arg1 MyStruct) { - _swig_wrap_delete_MyStruct(arg1.Swigcptr()) -} - -type MyStruct interface { - Swigcptr() uintptr - SwigIsMyStruct() - SetStr(arg2 Std_string) - GetStr() (_swig_ret Std_string) -} - -type SwigcptrRetStruct uintptr - -func (p SwigcptrRetStruct) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrRetStruct) SwigIsRetStruct() { -} - -var _wrap_RetStruct_str_set unsafe.Pointer - -func _swig_wrap_RetStruct_str_set(base SwigcptrRetStruct, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_RetStruct_str_set, _swig_p) - return -} - -func (arg1 SwigcptrRetStruct) SetStr(arg2 Std_string) { - _swig_wrap_RetStruct_str_set(arg1, arg2.Swigcptr()) -} - -var _wrap_RetStruct_str_get unsafe.Pointer - -func _swig_wrap_RetStruct_str_get(base SwigcptrRetStruct) (_ SwigcptrStd_string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_RetStruct_str_get, _swig_p) - return -} - -func (arg1 SwigcptrRetStruct) GetStr() (_swig_ret Std_string) { - return _swig_wrap_RetStruct_str_get(arg1) -} - -var _wrap_new_RetStruct unsafe.Pointer - -func _swig_wrap_new_RetStruct() (base SwigcptrRetStruct) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_RetStruct, _swig_p) - return -} - -func NewRetStruct() (_swig_ret RetStruct) { - return _swig_wrap_new_RetStruct() -} - -var _wrap_delete_RetStruct unsafe.Pointer - -func _swig_wrap_delete_RetStruct(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_RetStruct, _swig_p) - return -} - -func DeleteRetStruct(arg1 RetStruct) { - _swig_wrap_delete_RetStruct(arg1.Swigcptr()) -} - -type RetStruct interface { - Swigcptr() uintptr - SwigIsRetStruct() - SetStr(arg2 Std_string) - GetStr() (_swig_ret Std_string) -} - -var _wrap_Same unsafe.Pointer - -func _swig_wrap_Same(base string) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Same, _swig_p) - return -} - -func Same(arg1 In) (_swig_ret map[string]interface{}) { - var swig_r string - var _swig_i_0 string - { - b, err := arg1.MarshalJSON() - if err != nil { - panic(err) - } - _swig_i_0 = string(b) - } - swig_r = _swig_wrap_Same(_swig_i_0) - var swig_r_1 map[string]interface{} - - if err := json.Unmarshal([]byte(swig_r), &swig_r_1); err != nil { - panic(err) - } - return swig_r_1 -} - -type SwigcptrMyArray uintptr - -func (p SwigcptrMyArray) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrMyArray) SwigIsMyArray() { -} - -var _wrap_MyArray_strings_set unsafe.Pointer - -func _swig_wrap_MyArray_strings_set(base SwigcptrMyArray, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_MyArray_strings_set, _swig_p) - return -} - -func (arg1 SwigcptrMyArray) SetStrings(arg2 Std_vector_Sl_std_string_Sg_) { - _swig_wrap_MyArray_strings_set(arg1, arg2.Swigcptr()) -} - -var _wrap_MyArray_strings_get unsafe.Pointer - -func _swig_wrap_MyArray_strings_get(base SwigcptrMyArray) (_ SwigcptrStd_vector_Sl_std_string_Sg_) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_MyArray_strings_get, _swig_p) - return -} - -func (arg1 SwigcptrMyArray) GetStrings() (_swig_ret Std_vector_Sl_std_string_Sg_) { - return _swig_wrap_MyArray_strings_get(arg1) -} - -var _wrap_new_MyArray unsafe.Pointer - -func _swig_wrap_new_MyArray() (base SwigcptrMyArray) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_MyArray, _swig_p) - return -} - -func NewMyArray() (_swig_ret MyArray) { - return _swig_wrap_new_MyArray() -} - -var _wrap_delete_MyArray unsafe.Pointer - -func _swig_wrap_delete_MyArray(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_MyArray, _swig_p) - return -} - -func DeleteMyArray(arg1 MyArray) { - _swig_wrap_delete_MyArray(arg1.Swigcptr()) -} - -type MyArray interface { - Swigcptr() uintptr - SwigIsMyArray() - SetStrings(arg2 Std_vector_Sl_std_string_Sg_) - GetStrings() (_swig_ret Std_vector_Sl_std_string_Sg_) -} - -var _wrap_getuint64 unsafe.Pointer - -func _swig_wrap_getuint64(base string) (_ SwigcptrUint64_t) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_getuint64, _swig_p) - return -} - -func Getuint64(arg1 string) (_swig_ret Uint64_t) { - return _swig_wrap_getuint64(arg1) -} - -var _wrap_putuint64 unsafe.Pointer - -func _swig_wrap_putuint64(base uintptr, _ int64, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_putuint64, _swig_p) - return -} - -func Putuint64(arg1 Std_string, arg2 int64, arg3 Uint64_t) { - _swig_wrap_putuint64(arg1.Swigcptr(), arg2, arg3.Swigcptr()) -} - -var _wrap_DoubleArray unsafe.Pointer - -func _swig_wrap_DoubleArray(base *string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_DoubleArray, _swig_p) - return -} - -func DoubleArray(arg1 *[]string) { - var _swig_i_0 *string - { - var buf bytes.Buffer - bin := binary.LittleEndian - var b [8]byte - bin.PutUint64(b[:], uint64(len(*arg1))) - buf.Write(b[:]) - for _, s := range *arg1 { - bin.PutUint64(b[:], uint64(len(s))) - buf.Write(b[:]) - buf.WriteString(s) - } - str := buf.String() - _swig_i_0 = &str - } - _swig_wrap_DoubleArray(_swig_i_0) - - { - str := *_swig_i_0 - bin := binary.LittleEndian - size := bin.Uint64([]byte(str[:8])) - str = str[8:] - r := make([]string, size) - for i := range r { - len := bin.Uint64([]byte(str[:8])) - str = str[8:] - r[i] = str[:len] - str = str[len:] - } - *arg1 = r - } - -} - - -type SwigcptrStd_string uintptr -type Std_string interface { - Swigcptr() uintptr; -} -func (p SwigcptrStd_string) Swigcptr() uintptr { - return uintptr(p) -} - -type SwigcptrStd_vector_Sl_std_string_Sg_ uintptr -type Std_vector_Sl_std_string_Sg_ interface { - Swigcptr() uintptr; -} -func (p SwigcptrStd_vector_Sl_std_string_Sg_) Swigcptr() uintptr { - return uintptr(p) -} - -type SwigcptrUint64_t uintptr -type Uint64_t interface { - Swigcptr() uintptr; -} -func (p SwigcptrUint64_t) Swigcptr() uintptr { - return uintptr(p) -} - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/go_inout_runme b/Examples/test-suite/go/go_inout_runme deleted file mode 100755 index 9a919e577..000000000 Binary files a/Examples/test-suite/go/go_inout_runme and /dev/null differ diff --git a/Examples/test-suite/go/grouping.go b/Examples/test-suite/go/grouping.go deleted file mode 100644 index 7dd55f098..000000000 --- a/Examples/test-suite/go/grouping.go +++ /dev/null @@ -1,92 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../grouping.i - -package grouping - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -var _wrap_test1 unsafe.Pointer - -func Test1(arg1 int) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_test1, _swig_p) - return -} -var _wrap_test2 unsafe.Pointer - -func Test2(arg1 int) (_swig_ret *int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_test2, _swig_p) - return -} -var _wrap_test3_set unsafe.Pointer - -func _swig_wrap_test3_set(base int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_test3_set, _swig_p) - return -} - -func SetTest3(arg1 int) { - _swig_wrap_test3_set(arg1) -} - -var _wrap_test3_get unsafe.Pointer - -func GetTest3() (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_test3_get, _swig_p) - return -} -var _wrap_do_unary unsafe.Pointer - -func Do_unary(arg1 int, arg2 *_swig_fnptr) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_do_unary, _swig_p) - return -} -var _wrap_negate unsafe.Pointer - -func Negate(arg1 int) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_negate, _swig_p) - return -} -var _wrap_NEGATE unsafe.Pointer - -func _swig_getNEGATE() (_swig_ret *_swig_fnptr) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_NEGATE, _swig_p) - return -} -var NEGATE *_swig_fnptr = _swig_getNEGATE() - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/grouping_runme b/Examples/test-suite/go/grouping_runme deleted file mode 100755 index 1327b4977..000000000 Binary files a/Examples/test-suite/go/grouping_runme and /dev/null differ diff --git a/Examples/test-suite/go/ignore_parameter.go b/Examples/test-suite/go/ignore_parameter.go deleted file mode 100644 index 5f866330c..000000000 --- a/Examples/test-suite/go/ignore_parameter.go +++ /dev/null @@ -1,307 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../ignore_parameter.i - -package ignore_parameter - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -var _wrap_jaguar unsafe.Pointer - -func Jaguar(arg1 int, arg2 float64) (_swig_ret string) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_jaguar, _swig_p) - return -} -var _wrap_lotus unsafe.Pointer - -func Lotus(arg1 string, arg2 float64) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_lotus, _swig_p) - return -} -var _wrap_tvr unsafe.Pointer - -func Tvr(arg1 string, arg2 int) (_swig_ret float64) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_tvr, _swig_p) - return -} -var _wrap_ferrari unsafe.Pointer - -func Ferrari() (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_ferrari, _swig_p) - return -} -type SwigcptrSportsCars uintptr - -func (p SwigcptrSportsCars) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrSportsCars) SwigIsSportsCars() { -} - -var _wrap_SportsCars_daimler unsafe.Pointer - -func _swig_wrap_SportsCars_daimler(base SwigcptrSportsCars, _ int, _ float64) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_SportsCars_daimler, _swig_p) - return -} - -func (arg1 SwigcptrSportsCars) Daimler(arg2 int, arg3 float64) (_swig_ret string) { - return _swig_wrap_SportsCars_daimler(arg1, arg2, arg3) -} - -var _wrap_SportsCars_astonmartin unsafe.Pointer - -func _swig_wrap_SportsCars_astonmartin(base SwigcptrSportsCars, _ string, _ float64) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_SportsCars_astonmartin, _swig_p) - return -} - -func (arg1 SwigcptrSportsCars) Astonmartin(arg2 string, arg3 float64) (_swig_ret int) { - return _swig_wrap_SportsCars_astonmartin(arg1, arg2, arg3) -} - -var _wrap_SportsCars_bugatti unsafe.Pointer - -func _swig_wrap_SportsCars_bugatti(base SwigcptrSportsCars, _ string, _ int) (_ float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_SportsCars_bugatti, _swig_p) - return -} - -func (arg1 SwigcptrSportsCars) Bugatti(arg2 string, arg3 int) (_swig_ret float64) { - return _swig_wrap_SportsCars_bugatti(arg1, arg2, arg3) -} - -var _wrap_SportsCars_lamborghini unsafe.Pointer - -func _swig_wrap_SportsCars_lamborghini(base SwigcptrSportsCars) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_SportsCars_lamborghini, _swig_p) - return -} - -func (arg1 SwigcptrSportsCars) Lamborghini() (_swig_ret int) { - return _swig_wrap_SportsCars_lamborghini(arg1) -} - -var _wrap_new_SportsCars unsafe.Pointer - -func _swig_wrap_new_SportsCars() (base SwigcptrSportsCars) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_SportsCars, _swig_p) - return -} - -func NewSportsCars() (_swig_ret SportsCars) { - return _swig_wrap_new_SportsCars() -} - -var _wrap_delete_SportsCars unsafe.Pointer - -func _swig_wrap_delete_SportsCars(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_SportsCars, _swig_p) - return -} - -func DeleteSportsCars(arg1 SportsCars) { - _swig_wrap_delete_SportsCars(arg1.Swigcptr()) -} - -type SportsCars interface { - Swigcptr() uintptr - SwigIsSportsCars() - Daimler(arg2 int, arg3 float64) (_swig_ret string) - Astonmartin(arg2 string, arg3 float64) (_swig_ret int) - Bugatti(arg2 string, arg3 int) (_swig_ret float64) - Lamborghini() (_swig_ret int) -} - -type SwigcptrMiniCooper uintptr - -func (p SwigcptrMiniCooper) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrMiniCooper) SwigIsMiniCooper() { -} - -var _wrap_new_MiniCooper unsafe.Pointer - -func _swig_wrap_new_MiniCooper(base int, _ float64) (_ SwigcptrMiniCooper) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_MiniCooper, _swig_p) - return -} - -func NewMiniCooper(arg1 int, arg2 float64) (_swig_ret MiniCooper) { - return _swig_wrap_new_MiniCooper(arg1, arg2) -} - -var _wrap_delete_MiniCooper unsafe.Pointer - -func _swig_wrap_delete_MiniCooper(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_MiniCooper, _swig_p) - return -} - -func DeleteMiniCooper(arg1 MiniCooper) { - _swig_wrap_delete_MiniCooper(arg1.Swigcptr()) -} - -type MiniCooper interface { - Swigcptr() uintptr - SwigIsMiniCooper() -} - -type SwigcptrMorrisMinor uintptr - -func (p SwigcptrMorrisMinor) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrMorrisMinor) SwigIsMorrisMinor() { -} - -var _wrap_new_MorrisMinor unsafe.Pointer - -func _swig_wrap_new_MorrisMinor(base string, _ float64) (_ SwigcptrMorrisMinor) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_MorrisMinor, _swig_p) - return -} - -func NewMorrisMinor(arg1 string, arg2 float64) (_swig_ret MorrisMinor) { - return _swig_wrap_new_MorrisMinor(arg1, arg2) -} - -var _wrap_delete_MorrisMinor unsafe.Pointer - -func _swig_wrap_delete_MorrisMinor(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_MorrisMinor, _swig_p) - return -} - -func DeleteMorrisMinor(arg1 MorrisMinor) { - _swig_wrap_delete_MorrisMinor(arg1.Swigcptr()) -} - -type MorrisMinor interface { - Swigcptr() uintptr - SwigIsMorrisMinor() -} - -type SwigcptrFordAnglia uintptr - -func (p SwigcptrFordAnglia) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrFordAnglia) SwigIsFordAnglia() { -} - -var _wrap_new_FordAnglia unsafe.Pointer - -func _swig_wrap_new_FordAnglia(base string, _ int) (_ SwigcptrFordAnglia) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_FordAnglia, _swig_p) - return -} - -func NewFordAnglia(arg1 string, arg2 int) (_swig_ret FordAnglia) { - return _swig_wrap_new_FordAnglia(arg1, arg2) -} - -var _wrap_delete_FordAnglia unsafe.Pointer - -func _swig_wrap_delete_FordAnglia(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_FordAnglia, _swig_p) - return -} - -func DeleteFordAnglia(arg1 FordAnglia) { - _swig_wrap_delete_FordAnglia(arg1.Swigcptr()) -} - -type FordAnglia interface { - Swigcptr() uintptr - SwigIsFordAnglia() -} - -type SwigcptrAustinAllegro uintptr - -func (p SwigcptrAustinAllegro) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrAustinAllegro) SwigIsAustinAllegro() { -} - -var _wrap_new_AustinAllegro unsafe.Pointer - -func _swig_wrap_new_AustinAllegro() (base SwigcptrAustinAllegro) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_AustinAllegro, _swig_p) - return -} - -func NewAustinAllegro() (_swig_ret AustinAllegro) { - return _swig_wrap_new_AustinAllegro() -} - -var _wrap_delete_AustinAllegro unsafe.Pointer - -func _swig_wrap_delete_AustinAllegro(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_AustinAllegro, _swig_p) - return -} - -func DeleteAustinAllegro(arg1 AustinAllegro) { - _swig_wrap_delete_AustinAllegro(arg1.Swigcptr()) -} - -type AustinAllegro interface { - Swigcptr() uintptr - SwigIsAustinAllegro() -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/ignore_template_constructor.go b/Examples/test-suite/go/ignore_template_constructor.go deleted file mode 100644 index 0ff6c71bc..000000000 --- a/Examples/test-suite/go/ignore_template_constructor.go +++ /dev/null @@ -1,275 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../ignore_template_constructor.i - -package ignore_template_constructor - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrFlow uintptr - -func (p SwigcptrFlow) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrFlow) SwigIsFlow() { -} - -var _wrap_new_Flow__SWIG_0 unsafe.Pointer - -func _swig_wrap_new_Flow__SWIG_0() (base SwigcptrFlow) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Flow__SWIG_0, _swig_p) - return -} - -func NewFlow__SWIG_0() (_swig_ret Flow) { - return _swig_wrap_new_Flow__SWIG_0() -} - -var _wrap_new_Flow__SWIG_1 unsafe.Pointer - -func _swig_wrap_new_Flow__SWIG_1(base float64) (_ SwigcptrFlow) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Flow__SWIG_1, _swig_p) - return -} - -func NewFlow__SWIG_1(arg1 float64) (_swig_ret Flow) { - return _swig_wrap_new_Flow__SWIG_1(arg1) -} - -func NewFlow(a ...interface{}) Flow { - argc := len(a) - if argc == 0 { - return NewFlow__SWIG_0() - } - if argc == 1 { - return NewFlow__SWIG_1(a[0].(float64)) - } - panic("No match for overloaded function call") -} - -var _wrap_delete_Flow unsafe.Pointer - -func _swig_wrap_delete_Flow(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Flow, _swig_p) - return -} - -func DeleteFlow(arg1 Flow) { - _swig_wrap_delete_Flow(arg1.Swigcptr()) -} - -type Flow interface { - Swigcptr() uintptr - SwigIsFlow() -} - -type SwigcptrVectFlow uintptr - -func (p SwigcptrVectFlow) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrVectFlow) SwigIsVectFlow() { -} - -var _wrap_new_VectFlow__SWIG_0 unsafe.Pointer - -func _swig_wrap_new_VectFlow__SWIG_0() (base SwigcptrVectFlow) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_VectFlow__SWIG_0, _swig_p) - return -} - -func NewVectFlow__SWIG_0() (_swig_ret VectFlow) { - return _swig_wrap_new_VectFlow__SWIG_0() -} - -var _wrap_new_VectFlow__SWIG_1 unsafe.Pointer - -func _swig_wrap_new_VectFlow__SWIG_1(base int64) (_ SwigcptrVectFlow) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_VectFlow__SWIG_1, _swig_p) - return -} - -func NewVectFlow__SWIG_1(arg1 int64) (_swig_ret VectFlow) { - return _swig_wrap_new_VectFlow__SWIG_1(arg1) -} - -func NewVectFlow(a ...interface{}) VectFlow { - argc := len(a) - if argc == 0 { - return NewVectFlow__SWIG_0() - } - if argc == 1 { - return NewVectFlow__SWIG_1(a[0].(int64)) - } - panic("No match for overloaded function call") -} - -var _wrap_VectFlow_size unsafe.Pointer - -func _swig_wrap_VectFlow_size(base SwigcptrVectFlow) (_ int64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_VectFlow_size, _swig_p) - return -} - -func (arg1 SwigcptrVectFlow) Size() (_swig_ret int64) { - return _swig_wrap_VectFlow_size(arg1) -} - -var _wrap_VectFlow_capacity unsafe.Pointer - -func _swig_wrap_VectFlow_capacity(base SwigcptrVectFlow) (_ int64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_VectFlow_capacity, _swig_p) - return -} - -func (arg1 SwigcptrVectFlow) Capacity() (_swig_ret int64) { - return _swig_wrap_VectFlow_capacity(arg1) -} - -var _wrap_VectFlow_reserve unsafe.Pointer - -func _swig_wrap_VectFlow_reserve(base SwigcptrVectFlow, _ int64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_VectFlow_reserve, _swig_p) - return -} - -func (arg1 SwigcptrVectFlow) Reserve(arg2 int64) { - _swig_wrap_VectFlow_reserve(arg1, arg2) -} - -var _wrap_VectFlow_isEmpty unsafe.Pointer - -func _swig_wrap_VectFlow_isEmpty(base SwigcptrVectFlow) (_ bool) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_VectFlow_isEmpty, _swig_p) - return -} - -func (arg1 SwigcptrVectFlow) IsEmpty() (_swig_ret bool) { - return _swig_wrap_VectFlow_isEmpty(arg1) -} - -var _wrap_VectFlow_clear unsafe.Pointer - -func _swig_wrap_VectFlow_clear(base SwigcptrVectFlow) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_VectFlow_clear, _swig_p) - return -} - -func (arg1 SwigcptrVectFlow) Clear() { - _swig_wrap_VectFlow_clear(arg1) -} - -var _wrap_VectFlow_add unsafe.Pointer - -func _swig_wrap_VectFlow_add(base SwigcptrVectFlow, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_VectFlow_add, _swig_p) - return -} - -func (arg1 SwigcptrVectFlow) Add(arg2 Flow) { - _swig_wrap_VectFlow_add(arg1, arg2.Swigcptr()) -} - -var _wrap_VectFlow_get unsafe.Pointer - -func _swig_wrap_VectFlow_get(base SwigcptrVectFlow, _ int) (_ SwigcptrFlow) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_VectFlow_get, _swig_p) - return -} - -func (arg1 SwigcptrVectFlow) Get(arg2 int) (_swig_ret Flow) { - return _swig_wrap_VectFlow_get(arg1, arg2) -} - -var _wrap_VectFlow_set unsafe.Pointer - -func _swig_wrap_VectFlow_set(base SwigcptrVectFlow, _ int, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_VectFlow_set, _swig_p) - return -} - -func (arg1 SwigcptrVectFlow) Set(arg2 int, arg3 Flow) { - _swig_wrap_VectFlow_set(arg1, arg2, arg3.Swigcptr()) -} - -var _wrap_delete_VectFlow unsafe.Pointer - -func _swig_wrap_delete_VectFlow(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_VectFlow, _swig_p) - return -} - -func DeleteVectFlow(arg1 VectFlow) { - _swig_wrap_delete_VectFlow(arg1.Swigcptr()) -} - -type VectFlow interface { - Swigcptr() uintptr - SwigIsVectFlow() - Size() (_swig_ret int64) - Capacity() (_swig_ret int64) - Reserve(arg2 int64) - IsEmpty() (_swig_ret bool) - Clear() - Add(arg2 Flow) - Get(arg2 int) (_swig_ret Flow) - Set(arg2 int, arg3 Flow) -} - -var _wrap_inandout unsafe.Pointer - -func _swig_wrap_inandout(base uintptr) (_ SwigcptrVectFlow) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_inandout, _swig_p) - return -} - -func Inandout(arg1 VectFlow) (_swig_ret VectFlow) { - return _swig_wrap_inandout(arg1.Swigcptr()) -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/immutable_values.go b/Examples/test-suite/go/immutable_values.go deleted file mode 100644 index 09be91c21..000000000 --- a/Examples/test-suite/go/immutable_values.go +++ /dev/null @@ -1,81 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../immutable_values.i - -package immutable_values - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -const ABC int = -11 -type Enum_SS_count int -var _wrap_Zero unsafe.Pointer - -func _swig_getZero() (_swig_ret Enum_SS_count) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_Zero, _swig_p) - return -} -var Zero Enum_SS_count = _swig_getZero() -var _wrap_One unsafe.Pointer - -func _swig_getOne() (_swig_ret Enum_SS_count) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_One, _swig_p) - return -} -var One Enum_SS_count = _swig_getOne() -var _wrap_Two unsafe.Pointer - -func _swig_getTwo() (_swig_ret Enum_SS_count) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_Two, _swig_p) - return -} -var Two Enum_SS_count = _swig_getTwo() -const XYZ int = -22 -type Enum_SS_backwards int -var _wrap_Tre unsafe.Pointer - -func _swig_getTre() (_swig_ret Enum_SS_backwards) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_Tre, _swig_p) - return -} -var Tre Enum_SS_backwards = _swig_getTre() -var _wrap_Duo unsafe.Pointer - -func _swig_getDuo() (_swig_ret Enum_SS_backwards) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_Duo, _swig_p) - return -} -var Duo Enum_SS_backwards = _swig_getDuo() -var _wrap_Uno unsafe.Pointer - -func _swig_getUno() (_swig_ret Enum_SS_backwards) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_Uno, _swig_p) - return -} -var Uno Enum_SS_backwards = _swig_getUno() - diff --git a/Examples/test-suite/go/import_nomodule.go b/Examples/test-suite/go/import_nomodule.go deleted file mode 100644 index 31df272dc..000000000 --- a/Examples/test-suite/go/import_nomodule.go +++ /dev/null @@ -1,128 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../import_nomodule.i - -package import_nomodule - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -var _wrap_create_Foo unsafe.Pointer - -func _swig_wrap_create_Foo() (base SwigcptrFoo) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_create_Foo, _swig_p) - return -} - -func Create_Foo() (_swig_ret Foo) { - return _swig_wrap_create_Foo() -} - -var _wrap_delete_Foo unsafe.Pointer - -func _swig_wrap_delete_Foo(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Foo, _swig_p) - return -} - -func Delete_Foo(arg1 Foo) { - _swig_wrap_delete_Foo(arg1.Swigcptr()) -} - -var _wrap_test1 unsafe.Pointer - -func _swig_wrap_test1(base uintptr, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_test1, _swig_p) - return -} - -func Test1(arg1 Foo, arg2 int) { - _swig_wrap_test1(arg1.Swigcptr(), arg2) -} - -type SwigcptrBar uintptr - -func (p SwigcptrBar) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrBar) SwigIsBar() { -} - -var _wrap_new_Bar unsafe.Pointer - -func _swig_wrap_new_Bar() (base SwigcptrBar) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Bar, _swig_p) - return -} - -func NewBar() (_swig_ret Bar) { - return _swig_wrap_new_Bar() -} - -var _wrap_delete_Bar unsafe.Pointer - -func _swig_wrap_delete_Bar(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Bar, _swig_p) - return -} - -func DeleteBar(arg1 Bar) { - _swig_wrap_delete_Bar(arg1.Swigcptr()) -} - -func (p SwigcptrBar) SwigIsFoo() { -} - -func (p SwigcptrBar) SwigGetFoo() Foo { - return SwigcptrFoo(p.Swigcptr()) -} - -type Bar interface { - Swigcptr() uintptr - SwigIsBar() - SwigIsFoo() - SwigGetFoo() Foo -} - - -type SwigcptrFoo uintptr -type Foo interface { - Swigcptr() uintptr; -} -func (p SwigcptrFoo) Swigcptr() uintptr { - return uintptr(p) -} - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/import_nomodule_runme b/Examples/test-suite/go/import_nomodule_runme deleted file mode 100755 index c3d6a9043..000000000 Binary files a/Examples/test-suite/go/import_nomodule_runme and /dev/null differ diff --git a/Examples/test-suite/go/import_stl_a.go b/Examples/test-suite/go/import_stl_a.go deleted file mode 100644 index f47af5bdf..000000000 --- a/Examples/test-suite/go/import_stl_a.go +++ /dev/null @@ -1,202 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../import_stl_a.i - -package import_stl_a - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrVectorInt uintptr - -func (p SwigcptrVectorInt) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrVectorInt) SwigIsVectorInt() { -} - -var _wrap_new_VectorInt__SWIG_0 unsafe.Pointer - -func _swig_wrap_new_VectorInt__SWIG_0() (base SwigcptrVectorInt) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_VectorInt__SWIG_0, _swig_p) - return -} - -func NewVectorInt__SWIG_0() (_swig_ret VectorInt) { - return _swig_wrap_new_VectorInt__SWIG_0() -} - -var _wrap_new_VectorInt__SWIG_1 unsafe.Pointer - -func _swig_wrap_new_VectorInt__SWIG_1(base int64) (_ SwigcptrVectorInt) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_VectorInt__SWIG_1, _swig_p) - return -} - -func NewVectorInt__SWIG_1(arg1 int64) (_swig_ret VectorInt) { - return _swig_wrap_new_VectorInt__SWIG_1(arg1) -} - -func NewVectorInt(a ...interface{}) VectorInt { - argc := len(a) - if argc == 0 { - return NewVectorInt__SWIG_0() - } - if argc == 1 { - return NewVectorInt__SWIG_1(a[0].(int64)) - } - panic("No match for overloaded function call") -} - -var _wrap_VectorInt_size unsafe.Pointer - -func _swig_wrap_VectorInt_size(base SwigcptrVectorInt) (_ int64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_VectorInt_size, _swig_p) - return -} - -func (arg1 SwigcptrVectorInt) Size() (_swig_ret int64) { - return _swig_wrap_VectorInt_size(arg1) -} - -var _wrap_VectorInt_capacity unsafe.Pointer - -func _swig_wrap_VectorInt_capacity(base SwigcptrVectorInt) (_ int64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_VectorInt_capacity, _swig_p) - return -} - -func (arg1 SwigcptrVectorInt) Capacity() (_swig_ret int64) { - return _swig_wrap_VectorInt_capacity(arg1) -} - -var _wrap_VectorInt_reserve unsafe.Pointer - -func _swig_wrap_VectorInt_reserve(base SwigcptrVectorInt, _ int64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_VectorInt_reserve, _swig_p) - return -} - -func (arg1 SwigcptrVectorInt) Reserve(arg2 int64) { - _swig_wrap_VectorInt_reserve(arg1, arg2) -} - -var _wrap_VectorInt_isEmpty unsafe.Pointer - -func _swig_wrap_VectorInt_isEmpty(base SwigcptrVectorInt) (_ bool) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_VectorInt_isEmpty, _swig_p) - return -} - -func (arg1 SwigcptrVectorInt) IsEmpty() (_swig_ret bool) { - return _swig_wrap_VectorInt_isEmpty(arg1) -} - -var _wrap_VectorInt_clear unsafe.Pointer - -func _swig_wrap_VectorInt_clear(base SwigcptrVectorInt) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_VectorInt_clear, _swig_p) - return -} - -func (arg1 SwigcptrVectorInt) Clear() { - _swig_wrap_VectorInt_clear(arg1) -} - -var _wrap_VectorInt_add unsafe.Pointer - -func _swig_wrap_VectorInt_add(base SwigcptrVectorInt, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_VectorInt_add, _swig_p) - return -} - -func (arg1 SwigcptrVectorInt) Add(arg2 int) { - _swig_wrap_VectorInt_add(arg1, arg2) -} - -var _wrap_VectorInt_get unsafe.Pointer - -func _swig_wrap_VectorInt_get(base SwigcptrVectorInt, _ int) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_VectorInt_get, _swig_p) - return -} - -func (arg1 SwigcptrVectorInt) Get(arg2 int) (_swig_ret int) { - return _swig_wrap_VectorInt_get(arg1, arg2) -} - -var _wrap_VectorInt_set unsafe.Pointer - -func _swig_wrap_VectorInt_set(base SwigcptrVectorInt, _ int, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_VectorInt_set, _swig_p) - return -} - -func (arg1 SwigcptrVectorInt) Set(arg2 int, arg3 int) { - _swig_wrap_VectorInt_set(arg1, arg2, arg3) -} - -var _wrap_delete_VectorInt unsafe.Pointer - -func _swig_wrap_delete_VectorInt(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_VectorInt, _swig_p) - return -} - -func DeleteVectorInt(arg1 VectorInt) { - _swig_wrap_delete_VectorInt(arg1.Swigcptr()) -} - -type VectorInt interface { - Swigcptr() uintptr - SwigIsVectorInt() - Size() (_swig_ret int64) - Capacity() (_swig_ret int64) - Reserve(arg2 int64) - IsEmpty() (_swig_ret bool) - Clear() - Add(arg2 int) - Get(arg2 int) (_swig_ret int) - Set(arg2 int, arg3 int) -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/import_stl_b.go b/Examples/test-suite/go/import_stl_b.go deleted file mode 100644 index 87bef05d5..000000000 --- a/Examples/test-suite/go/import_stl_b.go +++ /dev/null @@ -1,42 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../import_stl_b.i - -package import_stl_b - -import "unsafe" -import _ "runtime/cgo" -import "import_stl_a" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -var _wrap_process_vector unsafe.Pointer - -func _swig_wrap_process_vector(base uintptr) (_ import_stl_a.SwigcptrVectorInt) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_process_vector, _swig_p) - return -} - -func Process_vector(arg1 import_stl_a.VectorInt) (_swig_ret import_stl_a.VectorInt) { - return _swig_wrap_process_vector(arg1.Swigcptr()) -} - - diff --git a/Examples/test-suite/go/imports_a.go b/Examples/test-suite/go/imports_a.go deleted file mode 100644 index feef97609..000000000 --- a/Examples/test-suite/go/imports_a.go +++ /dev/null @@ -1,155 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../imports_a.i - -package imports_a - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type GlobalEnum int -var _wrap_globalenum1 unsafe.Pointer - -func _swig_getglobalenum1() (_swig_ret GlobalEnum) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_globalenum1, _swig_p) - return -} -var Globalenum1 GlobalEnum = _swig_getglobalenum1() -var _wrap_globalenum2 unsafe.Pointer - -func _swig_getglobalenum2() (_swig_ret GlobalEnum) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_globalenum2, _swig_p) - return -} -var Globalenum2 GlobalEnum = _swig_getglobalenum2() -var _wrap_global_test unsafe.Pointer - -func Global_test(arg1 GlobalEnum) (_swig_ret GlobalEnum) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_global_test, _swig_p) - return -} -type SwigcptrA uintptr - -func (p SwigcptrA) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrA) SwigIsA() { -} - -var _wrap_new_A unsafe.Pointer - -func _swig_wrap_new_A() (base SwigcptrA) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_A, _swig_p) - return -} - -func NewA() (_swig_ret A) { - return _swig_wrap_new_A() -} - -var _wrap_delete_A unsafe.Pointer - -func _swig_wrap_delete_A(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_A, _swig_p) - return -} - -func DeleteA(arg1 A) { - _swig_wrap_delete_A(arg1.Swigcptr()) -} - -var _wrap_A_hello unsafe.Pointer - -func _swig_wrap_A_hello(base SwigcptrA) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_A_hello, _swig_p) - return -} - -func (arg1 SwigcptrA) Hello() { - _swig_wrap_A_hello(arg1) -} - -type AMemberEnum int -var _wrap_memberenum1_A unsafe.Pointer - -func _swig_getA_memberenum1_A() (_swig_ret AMemberEnum) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_memberenum1_A, _swig_p) - return -} -var AMemberenum1 AMemberEnum = _swig_getA_memberenum1_A() -var _wrap_memberenum2_A unsafe.Pointer - -func _swig_getA_memberenum2_A() (_swig_ret AMemberEnum) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_memberenum2_A, _swig_p) - return -} -var AMemberenum2 AMemberEnum = _swig_getA_memberenum2_A() -var _wrap_A_member_virtual_test unsafe.Pointer - -func _swig_wrap_A_member_virtual_test(base SwigcptrA, _ AMemberEnum) (_ AMemberEnum) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_A_member_virtual_test, _swig_p) - return -} - -func (arg1 SwigcptrA) Member_virtual_test(arg2 AMemberEnum) (_swig_ret AMemberEnum) { - return _swig_wrap_A_member_virtual_test(arg1, arg2) -} - -var _wrap_A_global_virtual_test unsafe.Pointer - -func _swig_wrap_A_global_virtual_test(base SwigcptrA, _ GlobalEnum) (_ GlobalEnum) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_A_global_virtual_test, _swig_p) - return -} - -func (arg1 SwigcptrA) Global_virtual_test(arg2 GlobalEnum) (_swig_ret GlobalEnum) { - return _swig_wrap_A_global_virtual_test(arg1, arg2) -} - -type A interface { - Swigcptr() uintptr - SwigIsA() - Hello() - Member_virtual_test(arg2 AMemberEnum) (_swig_ret AMemberEnum) - Global_virtual_test(arg2 GlobalEnum) (_swig_ret GlobalEnum) -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/imports_b.go b/Examples/test-suite/go/imports_b.go deleted file mode 100644 index 71f9dc8df..000000000 --- a/Examples/test-suite/go/imports_b.go +++ /dev/null @@ -1,264 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../imports_b.i - -package imports_b - -import "unsafe" -import _ "runtime/cgo" -import "imports_a" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrB uintptr - -func (p SwigcptrB) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrB) SwigIsB() { -} - -var _wrap_new_B unsafe.Pointer - -func _swig_wrap_new_B() (base SwigcptrB) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_B, _swig_p) - return -} - -func NewB() (_swig_ret B) { - return _swig_wrap_new_B() -} - -var _wrap_B_bye unsafe.Pointer - -func _swig_wrap_B_bye(base SwigcptrB) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_B_bye, _swig_p) - return -} - -func (arg1 SwigcptrB) Bye() { - _swig_wrap_B_bye(arg1) -} - -var _wrap_B_member_virtual_test unsafe.Pointer - -func _swig_wrap_B_member_virtual_test(base SwigcptrB, _ imports_a.AMemberEnum) (_ imports_a.AMemberEnum) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_B_member_virtual_test, _swig_p) - return -} - -func (arg1 SwigcptrB) Member_virtual_test(arg2 imports_a.AMemberEnum) (_swig_ret imports_a.AMemberEnum) { - return _swig_wrap_B_member_virtual_test(arg1, arg2) -} - -var _wrap_B_global_virtual_test unsafe.Pointer - -func _swig_wrap_B_global_virtual_test(base SwigcptrB, _ imports_a.GlobalEnum) (_ imports_a.GlobalEnum) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_B_global_virtual_test, _swig_p) - return -} - -func (arg1 SwigcptrB) Global_virtual_test(arg2 imports_a.GlobalEnum) (_swig_ret imports_a.GlobalEnum) { - return _swig_wrap_B_global_virtual_test(arg1, arg2) -} - -var _wrap_delete_B unsafe.Pointer - -func _swig_wrap_delete_B(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_B, _swig_p) - return -} - -func DeleteB(arg1 B) { - _swig_wrap_delete_B(arg1.Swigcptr()) -} - -var _wrap_B_hello unsafe.Pointer - -func _swig_wrap_B_hello(base SwigcptrB) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_B_hello, _swig_p) - return -} - -func (_swig_base SwigcptrB) Hello() { - _swig_wrap_B_hello(_swig_base) -} - -func (p SwigcptrB) SwigIsA() { -} - -func (p SwigcptrB) SwigGetA() imports_a.A { - return imports_a.SwigcptrA(p.Swigcptr()) -} - -type B interface { - Swigcptr() uintptr - SwigIsB() - Bye() - Member_virtual_test(arg2 imports_a.AMemberEnum) (_swig_ret imports_a.AMemberEnum) - Global_virtual_test(arg2 imports_a.GlobalEnum) (_swig_ret imports_a.GlobalEnum) - Hello() - SwigIsA() - SwigGetA() imports_a.A -} - -var _wrap_global_test__SWIG_1 unsafe.Pointer - -func Global_test__SWIG_1(arg1 imports_a.AMemberEnum) (_swig_ret imports_a.AMemberEnum) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_global_test__SWIG_1, _swig_p) - return -} -func Global_test(a ...interface{}) imports_a.AMemberEnum { - argc := len(a) - if argc == 1 { - return Global_test__SWIG_1(a[0].(imports_a.AMemberEnum)) - } - panic("No match for overloaded function call") -} - -type SwigcptrC uintptr - -func (p SwigcptrC) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrC) SwigIsC() { -} - -var _wrap_C_get_a unsafe.Pointer - -func _swig_wrap_C_get_a(base SwigcptrC, _ uintptr) (_ imports_a.SwigcptrA) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_C_get_a, _swig_p) - return -} - -func (arg1 SwigcptrC) Get_a(arg2 imports_a.A) (_swig_ret imports_a.A) { - return _swig_wrap_C_get_a(arg1, arg2.Swigcptr()) -} - -var _wrap_C_get_a_type unsafe.Pointer - -func _swig_wrap_C_get_a_type(base SwigcptrC, _ uintptr) (_ imports_a.SwigcptrA) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_C_get_a_type, _swig_p) - return -} - -func (arg1 SwigcptrC) Get_a_type(arg2 imports_a.A) (_swig_ret imports_a.A) { - return _swig_wrap_C_get_a_type(arg1, arg2.Swigcptr()) -} - -var _wrap_new_C unsafe.Pointer - -func _swig_wrap_new_C() (base SwigcptrC) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_C, _swig_p) - return -} - -func NewC() (_swig_ret C) { - return _swig_wrap_new_C() -} - -var _wrap_delete_C unsafe.Pointer - -func _swig_wrap_delete_C(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_C, _swig_p) - return -} - -func DeleteC(arg1 C) { - _swig_wrap_delete_C(arg1.Swigcptr()) -} - -var _wrap_C_hello unsafe.Pointer - -func _swig_wrap_C_hello(base SwigcptrC) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_C_hello, _swig_p) - return -} - -func (_swig_base SwigcptrC) Hello() { - _swig_wrap_C_hello(_swig_base) -} - -var _wrap_C_member_virtual_test unsafe.Pointer - -func _swig_wrap_C_member_virtual_test(base SwigcptrC, _ imports_a.AMemberEnum) (_ imports_a.AMemberEnum) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_C_member_virtual_test, _swig_p) - return -} - -func (_swig_base SwigcptrC) Member_virtual_test(arg1 imports_a.AMemberEnum) (_swig_ret imports_a.AMemberEnum) { - return _swig_wrap_C_member_virtual_test(_swig_base, arg1) -} - -var _wrap_C_global_virtual_test unsafe.Pointer - -func _swig_wrap_C_global_virtual_test(base SwigcptrC, _ imports_a.GlobalEnum) (_ imports_a.GlobalEnum) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_C_global_virtual_test, _swig_p) - return -} - -func (_swig_base SwigcptrC) Global_virtual_test(arg1 imports_a.GlobalEnum) (_swig_ret imports_a.GlobalEnum) { - return _swig_wrap_C_global_virtual_test(_swig_base, arg1) -} - -func (p SwigcptrC) SwigIsA() { -} - -func (p SwigcptrC) SwigGetA() imports_a.A { - return imports_a.SwigcptrA(p.Swigcptr()) -} - -type C interface { - Swigcptr() uintptr - SwigIsC() - Get_a(arg2 imports_a.A) (_swig_ret imports_a.A) - Get_a_type(arg2 imports_a.A) (_swig_ret imports_a.A) - Hello() - Member_virtual_test(arg1 imports_a.AMemberEnum) (_swig_ret imports_a.AMemberEnum) - Global_virtual_test(arg1 imports_a.GlobalEnum) (_swig_ret imports_a.GlobalEnum) - SwigIsA() - SwigGetA() imports_a.A -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/imports_runme b/Examples/test-suite/go/imports_runme deleted file mode 100755 index cd83e8b0d..000000000 Binary files a/Examples/test-suite/go/imports_runme and /dev/null differ diff --git a/Examples/test-suite/go/inctest.go b/Examples/test-suite/go/inctest.go deleted file mode 100644 index ec261508a..000000000 --- a/Examples/test-suite/go/inctest.go +++ /dev/null @@ -1,307 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../inctest.i - -package inctest - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrA uintptr - -func (p SwigcptrA) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrA) SwigIsA() { -} - -var _wrap_A_aa_set unsafe.Pointer - -func _swig_wrap_A_aa_set(base SwigcptrA, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_A_aa_set, _swig_p) - return -} - -func (arg1 SwigcptrA) SetAa(arg2 int) { - _swig_wrap_A_aa_set(arg1, arg2) -} - -var _wrap_A_aa_get unsafe.Pointer - -func _swig_wrap_A_aa_get(base SwigcptrA) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_A_aa_get, _swig_p) - return -} - -func (arg1 SwigcptrA) GetAa() (_swig_ret int) { - return _swig_wrap_A_aa_get(arg1) -} - -var _wrap_new_A unsafe.Pointer - -func _swig_wrap_new_A() (base SwigcptrA) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_A, _swig_p) - return -} - -func NewA() (_swig_ret A) { - return _swig_wrap_new_A() -} - -var _wrap_delete_A unsafe.Pointer - -func _swig_wrap_delete_A(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_A, _swig_p) - return -} - -func DeleteA(arg1 A) { - _swig_wrap_delete_A(arg1.Swigcptr()) -} - -type A interface { - Swigcptr() uintptr - SwigIsA() - SetAa(arg2 int) - GetAa() (_swig_ret int) -} - -var _wrap_importtest1 unsafe.Pointer - -func Importtest1(arg1 int) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_importtest1, _swig_p) - return -} -type SwigcptrB uintptr - -func (p SwigcptrB) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrB) SwigIsB() { -} - -var _wrap_B_bb_set unsafe.Pointer - -func _swig_wrap_B_bb_set(base SwigcptrB, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_B_bb_set, _swig_p) - return -} - -func (arg1 SwigcptrB) SetBb(arg2 int) { - _swig_wrap_B_bb_set(arg1, arg2) -} - -var _wrap_B_bb_get unsafe.Pointer - -func _swig_wrap_B_bb_get(base SwigcptrB) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_B_bb_get, _swig_p) - return -} - -func (arg1 SwigcptrB) GetBb() (_swig_ret int) { - return _swig_wrap_B_bb_get(arg1) -} - -var _wrap_new_B unsafe.Pointer - -func _swig_wrap_new_B() (base SwigcptrB) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_B, _swig_p) - return -} - -func NewB() (_swig_ret B) { - return _swig_wrap_new_B() -} - -var _wrap_delete_B unsafe.Pointer - -func _swig_wrap_delete_B(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_B, _swig_p) - return -} - -func DeleteB(arg1 B) { - _swig_wrap_delete_B(arg1.Swigcptr()) -} - -type B interface { - Swigcptr() uintptr - SwigIsB() - SetBb(arg2 int) - GetBb() (_swig_ret int) -} - -var _wrap_importtest2 unsafe.Pointer - -func Importtest2(arg1 string) (_swig_ret string) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_importtest2, _swig_p) - return -} -type SwigcptrMY_TYPES uintptr - -func (p SwigcptrMY_TYPES) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrMY_TYPES) SwigIsMY_TYPES() { -} - -var _wrap_new_MY_TYPES unsafe.Pointer - -func _swig_wrap_new_MY_TYPES() (base SwigcptrMY_TYPES) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_MY_TYPES, _swig_p) - return -} - -func NewMY_TYPES() (_swig_ret MY_TYPES) { - return _swig_wrap_new_MY_TYPES() -} - -var _wrap_delete_MY_TYPES unsafe.Pointer - -func _swig_wrap_delete_MY_TYPES(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_MY_TYPES, _swig_p) - return -} - -func DeleteMY_TYPES(arg1 MY_TYPES) { - _swig_wrap_delete_MY_TYPES(arg1.Swigcptr()) -} - -type MY_TYPES interface { - Swigcptr() uintptr - SwigIsMY_TYPES() -} - -type SwigcptrMY_THINGS uintptr - -func (p SwigcptrMY_THINGS) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrMY_THINGS) SwigIsMY_THINGS() { -} - -var _wrap_MY_THINGS_IntegerMember_set unsafe.Pointer - -func _swig_wrap_MY_THINGS_IntegerMember_set(base SwigcptrMY_THINGS, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_MY_THINGS_IntegerMember_set, _swig_p) - return -} - -func (arg1 SwigcptrMY_THINGS) SetIntegerMember(arg2 int) { - _swig_wrap_MY_THINGS_IntegerMember_set(arg1, arg2) -} - -var _wrap_MY_THINGS_IntegerMember_get unsafe.Pointer - -func _swig_wrap_MY_THINGS_IntegerMember_get(base SwigcptrMY_THINGS) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_MY_THINGS_IntegerMember_get, _swig_p) - return -} - -func (arg1 SwigcptrMY_THINGS) GetIntegerMember() (_swig_ret int) { - return _swig_wrap_MY_THINGS_IntegerMember_get(arg1) -} - -var _wrap_MY_THINGS_DoubleMember_set unsafe.Pointer - -func _swig_wrap_MY_THINGS_DoubleMember_set(base SwigcptrMY_THINGS, _ float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_MY_THINGS_DoubleMember_set, _swig_p) - return -} - -func (arg1 SwigcptrMY_THINGS) SetDoubleMember(arg2 float64) { - _swig_wrap_MY_THINGS_DoubleMember_set(arg1, arg2) -} - -var _wrap_MY_THINGS_DoubleMember_get unsafe.Pointer - -func _swig_wrap_MY_THINGS_DoubleMember_get(base SwigcptrMY_THINGS) (_ float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_MY_THINGS_DoubleMember_get, _swig_p) - return -} - -func (arg1 SwigcptrMY_THINGS) GetDoubleMember() (_swig_ret float64) { - return _swig_wrap_MY_THINGS_DoubleMember_get(arg1) -} - -var _wrap_new_MY_THINGS unsafe.Pointer - -func _swig_wrap_new_MY_THINGS() (base SwigcptrMY_THINGS) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_MY_THINGS, _swig_p) - return -} - -func NewMY_THINGS() (_swig_ret MY_THINGS) { - return _swig_wrap_new_MY_THINGS() -} - -var _wrap_delete_MY_THINGS unsafe.Pointer - -func _swig_wrap_delete_MY_THINGS(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_MY_THINGS, _swig_p) - return -} - -func DeleteMY_THINGS(arg1 MY_THINGS) { - _swig_wrap_delete_MY_THINGS(arg1.Swigcptr()) -} - -type MY_THINGS interface { - Swigcptr() uintptr - SwigIsMY_THINGS() - SetIntegerMember(arg2 int) - GetIntegerMember() (_swig_ret int) - SetDoubleMember(arg2 float64) - GetDoubleMember() (_swig_ret float64) -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/inctest_runme b/Examples/test-suite/go/inctest_runme deleted file mode 100755 index c7f30ef30..000000000 Binary files a/Examples/test-suite/go/inctest_runme and /dev/null differ diff --git a/Examples/test-suite/go/infinity.go b/Examples/test-suite/go/infinity.go deleted file mode 100644 index d31f9f51f..000000000 --- a/Examples/test-suite/go/infinity.go +++ /dev/null @@ -1,63 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../infinity.i - -package infinity - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -var _wrap_INFINITY_get unsafe.Pointer - -func GetINFINITY() (_swig_ret float64) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_INFINITY_get, _swig_p) - return -} -var _wrap_initialise_MYINFINITY unsafe.Pointer - -func _swig_wrap_initialise_MYINFINITY() { - var _swig_p uintptr - _cgo_runtime_cgocall(_wrap_initialise_MYINFINITY, _swig_p) - return -} - -func Initialise_MYINFINITY() { - _swig_wrap_initialise_MYINFINITY() -} - -var _wrap_use_infinity unsafe.Pointer - -func Use_infinity(arg1 float32) (_swig_ret float32) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_use_infinity, _swig_p) - return -} - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/inherit.go b/Examples/test-suite/go/inherit.go deleted file mode 100644 index 38bbd5f1c..000000000 --- a/Examples/test-suite/go/inherit.go +++ /dev/null @@ -1,155 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../inherit.i - -package inherit - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -var _wrap_Foo unsafe.Pointer - -func Foo() (_swig_ret string) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_Foo, _swig_p) - return -} -type SwigcptrCBase uintptr - -func (p SwigcptrCBase) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrCBase) SwigIsCBase() { -} - -var _wrap_CBase_Foo unsafe.Pointer - -func _swig_wrap_CBase_Foo(base SwigcptrCBase) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_CBase_Foo, _swig_p) - return -} - -func (arg1 SwigcptrCBase) Foo() (_swig_ret string) { - return _swig_wrap_CBase_Foo(arg1) -} - -var _wrap_new_CBase unsafe.Pointer - -func _swig_wrap_new_CBase() (base SwigcptrCBase) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_CBase, _swig_p) - return -} - -func NewCBase() (_swig_ret CBase) { - return _swig_wrap_new_CBase() -} - -var _wrap_delete_CBase unsafe.Pointer - -func _swig_wrap_delete_CBase(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_CBase, _swig_p) - return -} - -func DeleteCBase(arg1 CBase) { - _swig_wrap_delete_CBase(arg1.Swigcptr()) -} - -type CBase interface { - Swigcptr() uintptr - SwigIsCBase() - Foo() (_swig_ret string) -} - -type SwigcptrCDerived uintptr - -func (p SwigcptrCDerived) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrCDerived) SwigIsCDerived() { -} - -var _wrap_new_CDerived unsafe.Pointer - -func _swig_wrap_new_CDerived() (base SwigcptrCDerived) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_CDerived, _swig_p) - return -} - -func NewCDerived() (_swig_ret CDerived) { - return _swig_wrap_new_CDerived() -} - -var _wrap_delete_CDerived unsafe.Pointer - -func _swig_wrap_delete_CDerived(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_CDerived, _swig_p) - return -} - -func DeleteCDerived(arg1 CDerived) { - _swig_wrap_delete_CDerived(arg1.Swigcptr()) -} - -var _wrap_CDerived_Foo unsafe.Pointer - -func _swig_wrap_CDerived_Foo(base SwigcptrCDerived) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_CDerived_Foo, _swig_p) - return -} - -func (_swig_base SwigcptrCDerived) Foo() (_swig_ret string) { - return _swig_wrap_CDerived_Foo(_swig_base) -} - -func (p SwigcptrCDerived) SwigIsCBase() { -} - -func (p SwigcptrCDerived) SwigGetCBase() CBase { - return SwigcptrCBase(p.Swigcptr()) -} - -type CDerived interface { - Swigcptr() uintptr - SwigIsCDerived() - Foo() (_swig_ret string) - SwigIsCBase() - SwigGetCBase() CBase -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/inherit_missing.go b/Examples/test-suite/go/inherit_missing.go deleted file mode 100644 index 927944400..000000000 --- a/Examples/test-suite/go/inherit_missing.go +++ /dev/null @@ -1,192 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../inherit_missing.i - -package inherit_missing - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrBar uintptr - -func (p SwigcptrBar) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrBar) SwigIsBar() { -} - -var _wrap_delete_Bar unsafe.Pointer - -func _swig_wrap_delete_Bar(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Bar, _swig_p) - return -} - -func DeleteBar(arg1 Bar) { - _swig_wrap_delete_Bar(arg1.Swigcptr()) -} - -var _wrap_Bar_blah unsafe.Pointer - -func _swig_wrap_Bar_blah(base SwigcptrBar) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Bar_blah, _swig_p) - return -} - -func (arg1 SwigcptrBar) Blah() (_swig_ret string) { - return _swig_wrap_Bar_blah(arg1) -} - -var _wrap_new_Bar unsafe.Pointer - -func _swig_wrap_new_Bar() (base SwigcptrBar) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Bar, _swig_p) - return -} - -func NewBar() (_swig_ret Bar) { - return _swig_wrap_new_Bar() -} - -type Bar interface { - Swigcptr() uintptr - SwigIsBar() - Blah() (_swig_ret string) -} - -type SwigcptrSpam uintptr - -func (p SwigcptrSpam) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrSpam) SwigIsSpam() { -} - -var _wrap_Spam_blah unsafe.Pointer - -func _swig_wrap_Spam_blah(base SwigcptrSpam) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Spam_blah, _swig_p) - return -} - -func (arg1 SwigcptrSpam) Blah() (_swig_ret string) { - return _swig_wrap_Spam_blah(arg1) -} - -var _wrap_new_Spam unsafe.Pointer - -func _swig_wrap_new_Spam() (base SwigcptrSpam) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Spam, _swig_p) - return -} - -func NewSpam() (_swig_ret Spam) { - return _swig_wrap_new_Spam() -} - -var _wrap_delete_Spam unsafe.Pointer - -func _swig_wrap_delete_Spam(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Spam, _swig_p) - return -} - -func DeleteSpam(arg1 Spam) { - _swig_wrap_delete_Spam(arg1.Swigcptr()) -} - -func (p SwigcptrSpam) SwigIsBar() { -} - -func (p SwigcptrSpam) SwigGetBar() Bar { - return SwigcptrBar(p.Swigcptr()) -} - -type Spam interface { - Swigcptr() uintptr - SwigIsSpam() - Blah() (_swig_ret string) - SwigIsBar() - SwigGetBar() Bar -} - -var _wrap_new_Foo unsafe.Pointer - -func _swig_wrap_new_Foo() (base SwigcptrFoo) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Foo, _swig_p) - return -} - -func New_Foo() (_swig_ret Foo) { - return _swig_wrap_new_Foo() -} - -var _wrap_delete_Foo unsafe.Pointer - -func _swig_wrap_delete_Foo(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Foo, _swig_p) - return -} - -func Delete_Foo(arg1 Foo) { - _swig_wrap_delete_Foo(arg1.Swigcptr()) -} - -var _wrap_do_blah unsafe.Pointer - -func _swig_wrap_do_blah(base uintptr) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_do_blah, _swig_p) - return -} - -func Do_blah(arg1 Foo) (_swig_ret string) { - return _swig_wrap_do_blah(arg1.Swigcptr()) -} - - -type SwigcptrFoo uintptr -type Foo interface { - Swigcptr() uintptr; -} -func (p SwigcptrFoo) Swigcptr() uintptr { - return uintptr(p) -} - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/inherit_missing_runme b/Examples/test-suite/go/inherit_missing_runme deleted file mode 100755 index b8a39bc5b..000000000 Binary files a/Examples/test-suite/go/inherit_missing_runme and /dev/null differ diff --git a/Examples/test-suite/go/inherit_same_name.go b/Examples/test-suite/go/inherit_same_name.go deleted file mode 100644 index 6993a8b93..000000000 --- a/Examples/test-suite/go/inherit_same_name.go +++ /dev/null @@ -1,204 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../inherit_same_name.i - -package inherit_same_name - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrBase uintptr - -func (p SwigcptrBase) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrBase) SwigIsBase() { -} - -var _wrap_new_Base unsafe.Pointer - -func _swig_wrap_new_Base() (base SwigcptrBase) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Base, _swig_p) - return -} - -func NewBase() (_swig_ret Base) { - return _swig_wrap_new_Base() -} - -var _wrap_delete_Base unsafe.Pointer - -func _swig_wrap_delete_Base(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Base, _swig_p) - return -} - -func DeleteBase(arg1 Base) { - _swig_wrap_delete_Base(arg1.Swigcptr()) -} - -type Base interface { - Swigcptr() uintptr - SwigIsBase() -} - -type SwigcptrDerived uintptr - -func (p SwigcptrDerived) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrDerived) SwigIsDerived() { -} - -var _wrap_Derived_MethodOrVariable unsafe.Pointer - -func _swig_wrap_Derived_MethodOrVariable(base SwigcptrDerived) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Derived_MethodOrVariable, _swig_p) - return -} - -func (arg1 SwigcptrDerived) MethodOrVariable() { - _swig_wrap_Derived_MethodOrVariable(arg1) -} - -var _wrap_new_Derived unsafe.Pointer - -func _swig_wrap_new_Derived() (base SwigcptrDerived) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Derived, _swig_p) - return -} - -func NewDerived() (_swig_ret Derived) { - return _swig_wrap_new_Derived() -} - -var _wrap_delete_Derived unsafe.Pointer - -func _swig_wrap_delete_Derived(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Derived, _swig_p) - return -} - -func DeleteDerived(arg1 Derived) { - _swig_wrap_delete_Derived(arg1.Swigcptr()) -} - -func (p SwigcptrDerived) SwigIsBase() { -} - -func (p SwigcptrDerived) SwigGetBase() Base { - return SwigcptrBase(p.Swigcptr()) -} - -type Derived interface { - Swigcptr() uintptr - SwigIsDerived() - MethodOrVariable() - SwigIsBase() - SwigGetBase() Base -} - -type SwigcptrBottom uintptr - -func (p SwigcptrBottom) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrBottom) SwigIsBottom() { -} - -var _wrap_Bottom_MethodOrVariable unsafe.Pointer - -func _swig_wrap_Bottom_MethodOrVariable(base SwigcptrBottom) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Bottom_MethodOrVariable, _swig_p) - return -} - -func (arg1 SwigcptrBottom) MethodOrVariable() { - _swig_wrap_Bottom_MethodOrVariable(arg1) -} - -var _wrap_new_Bottom unsafe.Pointer - -func _swig_wrap_new_Bottom() (base SwigcptrBottom) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Bottom, _swig_p) - return -} - -func NewBottom() (_swig_ret Bottom) { - return _swig_wrap_new_Bottom() -} - -var _wrap_delete_Bottom unsafe.Pointer - -func _swig_wrap_delete_Bottom(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Bottom, _swig_p) - return -} - -func DeleteBottom(arg1 Bottom) { - _swig_wrap_delete_Bottom(arg1.Swigcptr()) -} - -func (p SwigcptrBottom) SwigIsDerived() { -} - -func (p SwigcptrBottom) SwigGetDerived() Derived { - return SwigcptrDerived(p.Swigcptr()) -} - -func (p SwigcptrBottom) SwigIsBase() { -} - -func (p SwigcptrBottom) SwigGetBase() Base { - return SwigcptrBase(p.Swigcptr()) -} - -type Bottom interface { - Swigcptr() uintptr - SwigIsBottom() - MethodOrVariable() - SwigIsDerived() - SwigGetDerived() Derived - SwigIsBase() - SwigGetBase() Base -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/inherit_target_language.go b/Examples/test-suite/go/inherit_target_language.go deleted file mode 100644 index cb8656bdb..000000000 --- a/Examples/test-suite/go/inherit_target_language.go +++ /dev/null @@ -1,714 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../inherit_target_language.i - -package inherit_target_language - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrBase2 uintptr - -func (p SwigcptrBase2) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrBase2) SwigIsBase2() { -} - -var _wrap_delete_Base2 unsafe.Pointer - -func _swig_wrap_delete_Base2(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Base2, _swig_p) - return -} - -func DeleteBase2(arg1 Base2) { - _swig_wrap_delete_Base2(arg1.Swigcptr()) -} - -var _wrap_new_Base2 unsafe.Pointer - -func _swig_wrap_new_Base2() (base SwigcptrBase2) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Base2, _swig_p) - return -} - -func NewBase2() (_swig_ret Base2) { - return _swig_wrap_new_Base2() -} - -type Base2 interface { - Swigcptr() uintptr - SwigIsBase2() -} - -type SwigcptrDerived1 uintptr - -func (p SwigcptrDerived1) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrDerived1) SwigIsDerived1() { -} - -var _wrap_new_Derived1 unsafe.Pointer - -func _swig_wrap_new_Derived1() (base SwigcptrDerived1) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Derived1, _swig_p) - return -} - -func NewDerived1() (_swig_ret Derived1) { - return _swig_wrap_new_Derived1() -} - -var _wrap_delete_Derived1 unsafe.Pointer - -func _swig_wrap_delete_Derived1(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Derived1, _swig_p) - return -} - -func DeleteDerived1(arg1 Derived1) { - _swig_wrap_delete_Derived1(arg1.Swigcptr()) -} - -type Derived1 interface { - Swigcptr() uintptr - SwigIsDerived1() -} - -type SwigcptrDerived2 uintptr - -func (p SwigcptrDerived2) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrDerived2) SwigIsDerived2() { -} - -var _wrap_new_Derived2 unsafe.Pointer - -func _swig_wrap_new_Derived2() (base SwigcptrDerived2) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Derived2, _swig_p) - return -} - -func NewDerived2() (_swig_ret Derived2) { - return _swig_wrap_new_Derived2() -} - -var _wrap_delete_Derived2 unsafe.Pointer - -func _swig_wrap_delete_Derived2(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Derived2, _swig_p) - return -} - -func DeleteDerived2(arg1 Derived2) { - _swig_wrap_delete_Derived2(arg1.Swigcptr()) -} - -func (p SwigcptrDerived2) SwigIsBase2() { -} - -func (p SwigcptrDerived2) SwigGetBase2() Base2 { - return SwigcptrBase2(p.Swigcptr()) -} - -type Derived2 interface { - Swigcptr() uintptr - SwigIsDerived2() - SwigIsBase2() - SwigGetBase2() Base2 -} - -type SwigcptrMBase2a uintptr - -func (p SwigcptrMBase2a) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrMBase2a) SwigIsMBase2a() { -} - -var _wrap_delete_MBase2a unsafe.Pointer - -func _swig_wrap_delete_MBase2a(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_MBase2a, _swig_p) - return -} - -func DeleteMBase2a(arg1 MBase2a) { - _swig_wrap_delete_MBase2a(arg1.Swigcptr()) -} - -var _wrap_MBase2a_c unsafe.Pointer - -func _swig_wrap_MBase2a_c(base SwigcptrMBase2a) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_MBase2a_c, _swig_p) - return -} - -func (arg1 SwigcptrMBase2a) C() { - _swig_wrap_MBase2a_c(arg1) -} - -var _wrap_new_MBase2a unsafe.Pointer - -func _swig_wrap_new_MBase2a() (base SwigcptrMBase2a) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_MBase2a, _swig_p) - return -} - -func NewMBase2a() (_swig_ret MBase2a) { - return _swig_wrap_new_MBase2a() -} - -type MBase2a interface { - Swigcptr() uintptr - SwigIsMBase2a() - C() -} - -type SwigcptrMBase2b uintptr - -func (p SwigcptrMBase2b) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrMBase2b) SwigIsMBase2b() { -} - -var _wrap_delete_MBase2b unsafe.Pointer - -func _swig_wrap_delete_MBase2b(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_MBase2b, _swig_p) - return -} - -func DeleteMBase2b(arg1 MBase2b) { - _swig_wrap_delete_MBase2b(arg1.Swigcptr()) -} - -var _wrap_MBase2b_d unsafe.Pointer - -func _swig_wrap_MBase2b_d(base SwigcptrMBase2b) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_MBase2b_d, _swig_p) - return -} - -func (arg1 SwigcptrMBase2b) D() { - _swig_wrap_MBase2b_d(arg1) -} - -var _wrap_new_MBase2b unsafe.Pointer - -func _swig_wrap_new_MBase2b() (base SwigcptrMBase2b) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_MBase2b, _swig_p) - return -} - -func NewMBase2b() (_swig_ret MBase2b) { - return _swig_wrap_new_MBase2b() -} - -type MBase2b interface { - Swigcptr() uintptr - SwigIsMBase2b() - D() -} - -type SwigcptrMultipleDerived1 uintptr - -func (p SwigcptrMultipleDerived1) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrMultipleDerived1) SwigIsMultipleDerived1() { -} - -var _wrap_new_MultipleDerived1 unsafe.Pointer - -func _swig_wrap_new_MultipleDerived1() (base SwigcptrMultipleDerived1) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_MultipleDerived1, _swig_p) - return -} - -func NewMultipleDerived1() (_swig_ret MultipleDerived1) { - return _swig_wrap_new_MultipleDerived1() -} - -var _wrap_delete_MultipleDerived1 unsafe.Pointer - -func _swig_wrap_delete_MultipleDerived1(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_MultipleDerived1, _swig_p) - return -} - -func DeleteMultipleDerived1(arg1 MultipleDerived1) { - _swig_wrap_delete_MultipleDerived1(arg1.Swigcptr()) -} - -type MultipleDerived1 interface { - Swigcptr() uintptr - SwigIsMultipleDerived1() -} - -type SwigcptrMultipleDerived2 uintptr - -func (p SwigcptrMultipleDerived2) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrMultipleDerived2) SwigIsMultipleDerived2() { -} - -var _wrap_new_MultipleDerived2 unsafe.Pointer - -func _swig_wrap_new_MultipleDerived2() (base SwigcptrMultipleDerived2) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_MultipleDerived2, _swig_p) - return -} - -func NewMultipleDerived2() (_swig_ret MultipleDerived2) { - return _swig_wrap_new_MultipleDerived2() -} - -var _wrap_delete_MultipleDerived2 unsafe.Pointer - -func _swig_wrap_delete_MultipleDerived2(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_MultipleDerived2, _swig_p) - return -} - -func DeleteMultipleDerived2(arg1 MultipleDerived2) { - _swig_wrap_delete_MultipleDerived2(arg1.Swigcptr()) -} - -var _wrap_MultipleDerived2_d unsafe.Pointer - -func _swig_wrap_MultipleDerived2_d(base SwigcptrMultipleDerived2) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_MultipleDerived2_d, _swig_p) - return -} - -func (_swig_base SwigcptrMultipleDerived2) D() { - _swig_wrap_MultipleDerived2_d(_swig_base) -} - -var _wrap_MultipleDerived2_SwigGetMBase2b unsafe.Pointer - -func _swig_wrap_MultipleDerived2_SwigGetMBase2b(base SwigcptrMultipleDerived2) (_ SwigcptrMBase2b) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_MultipleDerived2_SwigGetMBase2b, _swig_p) - return -} - -func (arg1 SwigcptrMultipleDerived2) SwigGetMBase2b() (_swig_ret MBase2b) { - return _swig_wrap_MultipleDerived2_SwigGetMBase2b(arg1) -} - -type MultipleDerived2 interface { - Swigcptr() uintptr - SwigIsMultipleDerived2() - D() - SwigGetMBase2b() (_swig_ret MBase2b) -} - -type SwigcptrMBase3b uintptr - -func (p SwigcptrMBase3b) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrMBase3b) SwigIsMBase3b() { -} - -var _wrap_delete_MBase3b unsafe.Pointer - -func _swig_wrap_delete_MBase3b(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_MBase3b, _swig_p) - return -} - -func DeleteMBase3b(arg1 MBase3b) { - _swig_wrap_delete_MBase3b(arg1.Swigcptr()) -} - -var _wrap_MBase3b_f unsafe.Pointer - -func _swig_wrap_MBase3b_f(base SwigcptrMBase3b) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_MBase3b_f, _swig_p) - return -} - -func (arg1 SwigcptrMBase3b) F() { - _swig_wrap_MBase3b_f(arg1) -} - -var _wrap_new_MBase3b unsafe.Pointer - -func _swig_wrap_new_MBase3b() (base SwigcptrMBase3b) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_MBase3b, _swig_p) - return -} - -func NewMBase3b() (_swig_ret MBase3b) { - return _swig_wrap_new_MBase3b() -} - -type MBase3b interface { - Swigcptr() uintptr - SwigIsMBase3b() - F() -} - -type SwigcptrMBase4a uintptr - -func (p SwigcptrMBase4a) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrMBase4a) SwigIsMBase4a() { -} - -var _wrap_delete_MBase4a unsafe.Pointer - -func _swig_wrap_delete_MBase4a(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_MBase4a, _swig_p) - return -} - -func DeleteMBase4a(arg1 MBase4a) { - _swig_wrap_delete_MBase4a(arg1.Swigcptr()) -} - -var _wrap_MBase4a_g unsafe.Pointer - -func _swig_wrap_MBase4a_g(base SwigcptrMBase4a) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_MBase4a_g, _swig_p) - return -} - -func (arg1 SwigcptrMBase4a) G() { - _swig_wrap_MBase4a_g(arg1) -} - -var _wrap_new_MBase4a unsafe.Pointer - -func _swig_wrap_new_MBase4a() (base SwigcptrMBase4a) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_MBase4a, _swig_p) - return -} - -func NewMBase4a() (_swig_ret MBase4a) { - return _swig_wrap_new_MBase4a() -} - -type MBase4a interface { - Swigcptr() uintptr - SwigIsMBase4a() - G() -} - -type SwigcptrMultipleDerived3 uintptr - -func (p SwigcptrMultipleDerived3) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrMultipleDerived3) SwigIsMultipleDerived3() { -} - -var _wrap_new_MultipleDerived3 unsafe.Pointer - -func _swig_wrap_new_MultipleDerived3() (base SwigcptrMultipleDerived3) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_MultipleDerived3, _swig_p) - return -} - -func NewMultipleDerived3() (_swig_ret MultipleDerived3) { - return _swig_wrap_new_MultipleDerived3() -} - -var _wrap_delete_MultipleDerived3 unsafe.Pointer - -func _swig_wrap_delete_MultipleDerived3(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_MultipleDerived3, _swig_p) - return -} - -func DeleteMultipleDerived3(arg1 MultipleDerived3) { - _swig_wrap_delete_MultipleDerived3(arg1.Swigcptr()) -} - -var _wrap_MultipleDerived3_f unsafe.Pointer - -func _swig_wrap_MultipleDerived3_f(base SwigcptrMultipleDerived3) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_MultipleDerived3_f, _swig_p) - return -} - -func (_swig_base SwigcptrMultipleDerived3) F() { - _swig_wrap_MultipleDerived3_f(_swig_base) -} - -var _wrap_MultipleDerived3_SwigGetMBase3b unsafe.Pointer - -func _swig_wrap_MultipleDerived3_SwigGetMBase3b(base SwigcptrMultipleDerived3) (_ SwigcptrMBase3b) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_MultipleDerived3_SwigGetMBase3b, _swig_p) - return -} - -func (arg1 SwigcptrMultipleDerived3) SwigGetMBase3b() (_swig_ret MBase3b) { - return _swig_wrap_MultipleDerived3_SwigGetMBase3b(arg1) -} - -type MultipleDerived3 interface { - Swigcptr() uintptr - SwigIsMultipleDerived3() - F() - SwigGetMBase3b() (_swig_ret MBase3b) -} - -type SwigcptrMultipleDerived4 uintptr - -func (p SwigcptrMultipleDerived4) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrMultipleDerived4) SwigIsMultipleDerived4() { -} - -var _wrap_new_MultipleDerived4 unsafe.Pointer - -func _swig_wrap_new_MultipleDerived4() (base SwigcptrMultipleDerived4) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_MultipleDerived4, _swig_p) - return -} - -func NewMultipleDerived4() (_swig_ret MultipleDerived4) { - return _swig_wrap_new_MultipleDerived4() -} - -var _wrap_delete_MultipleDerived4 unsafe.Pointer - -func _swig_wrap_delete_MultipleDerived4(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_MultipleDerived4, _swig_p) - return -} - -func DeleteMultipleDerived4(arg1 MultipleDerived4) { - _swig_wrap_delete_MultipleDerived4(arg1.Swigcptr()) -} - -var _wrap_MultipleDerived4_g unsafe.Pointer - -func _swig_wrap_MultipleDerived4_g(base SwigcptrMultipleDerived4) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_MultipleDerived4_g, _swig_p) - return -} - -func (_swig_base SwigcptrMultipleDerived4) G() { - _swig_wrap_MultipleDerived4_g(_swig_base) -} - -func (p SwigcptrMultipleDerived4) SwigIsMBase4a() { -} - -func (p SwigcptrMultipleDerived4) SwigGetMBase4a() MBase4a { - return SwigcptrMBase4a(p.Swigcptr()) -} - -type MultipleDerived4 interface { - Swigcptr() uintptr - SwigIsMultipleDerived4() - G() - SwigIsMBase4a() - SwigGetMBase4a() MBase4a -} - -type SwigcptrBaseX uintptr - -func (p SwigcptrBaseX) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrBaseX) SwigIsBaseX() { -} - -var _wrap_delete_BaseX unsafe.Pointer - -func _swig_wrap_delete_BaseX(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_BaseX, _swig_p) - return -} - -func DeleteBaseX(arg1 BaseX) { - _swig_wrap_delete_BaseX(arg1.Swigcptr()) -} - -var _wrap_BaseX_basex unsafe.Pointer - -func _swig_wrap_BaseX_basex(base SwigcptrBaseX) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_BaseX_basex, _swig_p) - return -} - -func (arg1 SwigcptrBaseX) Basex() { - _swig_wrap_BaseX_basex(arg1) -} - -var _wrap_new_BaseX unsafe.Pointer - -func _swig_wrap_new_BaseX() (base SwigcptrBaseX) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_BaseX, _swig_p) - return -} - -func NewBaseX() (_swig_ret BaseX) { - return _swig_wrap_new_BaseX() -} - -type BaseX interface { - Swigcptr() uintptr - SwigIsBaseX() - Basex() -} - -type SwigcptrDerivedX uintptr - -func (p SwigcptrDerivedX) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrDerivedX) SwigIsDerivedX() { -} - -var _wrap_DerivedX_derivedx unsafe.Pointer - -func _swig_wrap_DerivedX_derivedx(base SwigcptrDerivedX) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_DerivedX_derivedx, _swig_p) - return -} - -func (arg1 SwigcptrDerivedX) Derivedx() { - _swig_wrap_DerivedX_derivedx(arg1) -} - -var _wrap_new_DerivedX unsafe.Pointer - -func _swig_wrap_new_DerivedX() (base SwigcptrDerivedX) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_DerivedX, _swig_p) - return -} - -func NewDerivedX() (_swig_ret DerivedX) { - return _swig_wrap_new_DerivedX() -} - -var _wrap_delete_DerivedX unsafe.Pointer - -func _swig_wrap_delete_DerivedX(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_DerivedX, _swig_p) - return -} - -func DeleteDerivedX(arg1 DerivedX) { - _swig_wrap_delete_DerivedX(arg1.Swigcptr()) -} - -var _wrap_DerivedX_basex unsafe.Pointer - -func _swig_wrap_DerivedX_basex(base SwigcptrDerivedX) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_DerivedX_basex, _swig_p) - return -} - -func (_swig_base SwigcptrDerivedX) Basex() { - _swig_wrap_DerivedX_basex(_swig_base) -} - -func (p SwigcptrDerivedX) SwigIsBaseX() { -} - -func (p SwigcptrDerivedX) SwigGetBaseX() BaseX { - return SwigcptrBaseX(p.Swigcptr()) -} - -type DerivedX interface { - Swigcptr() uintptr - SwigIsDerivedX() - Derivedx() - Basex() - SwigIsBaseX() - SwigGetBaseX() BaseX -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/inherit_void_arg.go b/Examples/test-suite/go/inherit_void_arg.go deleted file mode 100644 index 45f811ccf..000000000 --- a/Examples/test-suite/go/inherit_void_arg.go +++ /dev/null @@ -1,136 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../inherit_void_arg.i - -package inherit_void_arg - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrA uintptr - -func (p SwigcptrA) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrA) SwigIsA() { -} - -var _wrap_delete_A unsafe.Pointer - -func _swig_wrap_delete_A(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_A, _swig_p) - return -} - -func DeleteA(arg1 A) { - _swig_wrap_delete_A(arg1.Swigcptr()) -} - -var _wrap_A_f unsafe.Pointer - -func _swig_wrap_A_f(base SwigcptrA) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_A_f, _swig_p) - return -} - -func (arg1 SwigcptrA) F() { - _swig_wrap_A_f(arg1) -} - -type A interface { - Swigcptr() uintptr - SwigIsA() - F() -} - -type SwigcptrB uintptr - -func (p SwigcptrB) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrB) SwigIsB() { -} - -var _wrap_B_f unsafe.Pointer - -func _swig_wrap_B_f(base SwigcptrB) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_B_f, _swig_p) - return -} - -func (arg1 SwigcptrB) F() { - _swig_wrap_B_f(arg1) -} - -var _wrap_new_B unsafe.Pointer - -func _swig_wrap_new_B() (base SwigcptrB) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_B, _swig_p) - return -} - -func NewB() (_swig_ret B) { - return _swig_wrap_new_B() -} - -var _wrap_delete_B unsafe.Pointer - -func _swig_wrap_delete_B(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_B, _swig_p) - return -} - -func DeleteB(arg1 B) { - _swig_wrap_delete_B(arg1.Swigcptr()) -} - -func (p SwigcptrB) SwigIsA() { -} - -func (p SwigcptrB) SwigGetA() A { - return SwigcptrA(p.Swigcptr()) -} - -type B interface { - Swigcptr() uintptr - SwigIsB() - F() - SwigIsA() - SwigGetA() A -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/inline_initializer.go b/Examples/test-suite/go/inline_initializer.go deleted file mode 100644 index 7bcc24cbb..000000000 --- a/Examples/test-suite/go/inline_initializer.go +++ /dev/null @@ -1,75 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../inline_initializer.i - -package inline_initializer - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrFoo uintptr - -func (p SwigcptrFoo) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrFoo) SwigIsFoo() { -} - -var _wrap_new_Foo unsafe.Pointer - -func _swig_wrap_new_Foo(base int) (_ SwigcptrFoo) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Foo, _swig_p) - return -} - -func NewFoo(arg1 int) (_swig_ret Foo) { - return _swig_wrap_new_Foo(arg1) -} - -var _wrap_delete_Foo unsafe.Pointer - -func _swig_wrap_delete_Foo(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Foo, _swig_p) - return -} - -func DeleteFoo(arg1 Foo) { - _swig_wrap_delete_Foo(arg1.Swigcptr()) -} - -type Foo interface { - Swigcptr() uintptr - SwigIsFoo() -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/insert_directive.go b/Examples/test-suite/go/insert_directive.go deleted file mode 100644 index 2ba7b644b..000000000 --- a/Examples/test-suite/go/insert_directive.go +++ /dev/null @@ -1,29 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../insert_directive.i - -package insert_directive - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - - diff --git a/Examples/test-suite/go/integers.go b/Examples/test-suite/go/integers.go deleted file mode 100644 index 7807af933..000000000 --- a/Examples/test-suite/go/integers.go +++ /dev/null @@ -1,169 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../integers.i - -package integers - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -var _wrap_signed_char_identity unsafe.Pointer - -func Signed_char_identity(arg1 int8) (_swig_ret int8) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_signed_char_identity, _swig_p) - return -} -var _wrap_unsigned_char_identity unsafe.Pointer - -func Unsigned_char_identity(arg1 byte) (_swig_ret byte) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_unsigned_char_identity, _swig_p) - return -} -var _wrap_signed_short_identity unsafe.Pointer - -func Signed_short_identity(arg1 int16) (_swig_ret int16) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_signed_short_identity, _swig_p) - return -} -var _wrap_unsigned_short_identity unsafe.Pointer - -func Unsigned_short_identity(arg1 uint16) (_swig_ret uint16) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_unsigned_short_identity, _swig_p) - return -} -var _wrap_signed_int_identity unsafe.Pointer - -func Signed_int_identity(arg1 int) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_signed_int_identity, _swig_p) - return -} -var _wrap_unsigned_int_identity unsafe.Pointer - -func Unsigned_int_identity(arg1 uint) (_swig_ret uint) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_unsigned_int_identity, _swig_p) - return -} -var _wrap_signed_long_identity unsafe.Pointer - -func Signed_long_identity(arg1 int64) (_swig_ret int64) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_signed_long_identity, _swig_p) - return -} -var _wrap_unsigned_long_identity unsafe.Pointer - -func Unsigned_long_identity(arg1 uint64) (_swig_ret uint64) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_unsigned_long_identity, _swig_p) - return -} -var _wrap_signed_long_long_identity unsafe.Pointer - -func Signed_long_long_identity(arg1 int64) (_swig_ret int64) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_signed_long_long_identity, _swig_p) - return -} -var _wrap_unsigned_long_long_identity unsafe.Pointer - -func Unsigned_long_long_identity(arg1 uint64) (_swig_ret uint64) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_unsigned_long_long_identity, _swig_p) - return -} -var _wrap_signed_char_size unsafe.Pointer - -func Signed_char_size() (_swig_ret int64) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_signed_char_size, _swig_p) - return -} -var _wrap_unsigned_char_size unsafe.Pointer - -func Unsigned_char_size() (_swig_ret int64) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_unsigned_char_size, _swig_p) - return -} -var _wrap_signed_short_size unsafe.Pointer - -func Signed_short_size() (_swig_ret int64) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_signed_short_size, _swig_p) - return -} -var _wrap_unsigned_short_size unsafe.Pointer - -func Unsigned_short_size() (_swig_ret int64) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_unsigned_short_size, _swig_p) - return -} -var _wrap_signed_int_size unsafe.Pointer - -func Signed_int_size() (_swig_ret int64) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_signed_int_size, _swig_p) - return -} -var _wrap_unsigned_int_size unsafe.Pointer - -func Unsigned_int_size() (_swig_ret int64) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_unsigned_int_size, _swig_p) - return -} -var _wrap_signed_long_size unsafe.Pointer - -func Signed_long_size() (_swig_ret int64) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_signed_long_size, _swig_p) - return -} -var _wrap_unsigned_long_size unsafe.Pointer - -func Unsigned_long_size() (_swig_ret int64) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_unsigned_long_size, _swig_p) - return -} -var _wrap_signed_long_long_size unsafe.Pointer - -func Signed_long_long_size() (_swig_ret int64) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_signed_long_long_size, _swig_p) - return -} -var _wrap_unsigned_long_long_size unsafe.Pointer - -func Unsigned_long_long_size() (_swig_ret int64) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_unsigned_long_long_size, _swig_p) - return -} - diff --git a/Examples/test-suite/go/keyword_rename.go b/Examples/test-suite/go/keyword_rename.go deleted file mode 100644 index 94fe44d5c..000000000 --- a/Examples/test-suite/go/keyword_rename.go +++ /dev/null @@ -1,185 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../keyword_rename.i - -package keyword_rename - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -var _wrap_in unsafe.Pointer - -func In(arg1 int) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_in, _swig_p) - return -} -var _wrap_except unsafe.Pointer - -func Except(arg1 int) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_except, _swig_p) - return -} -var _wrap_pass unsafe.Pointer - -func Pass(arg1 int) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_pass, _swig_p) - return -} -var _wrap_tie unsafe.Pointer - -func Tie(arg1 int) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_tie, _swig_p) - return -} -var _wrap_use unsafe.Pointer - -func Use(arg1 int) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_use, _swig_p) - return -} -var _wrap_implements unsafe.Pointer - -func Implements(arg1 int) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_implements, _swig_p) - return -} -var _wrap_synchronized unsafe.Pointer - -func Synchronized(arg1 int) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_synchronized, _swig_p) - return -} -var _wrap_string unsafe.Pointer - -func String(arg1 int) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_string, _swig_p) - return -} -type SwigcptrSealed uintptr - -func (p SwigcptrSealed) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrSealed) SwigIsSealed() { -} - -var _wrap_sealed_i_set unsafe.Pointer - -func _swig_wrap_sealed_i_set(base SwigcptrSealed, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_sealed_i_set, _swig_p) - return -} - -func (arg1 SwigcptrSealed) SetI(arg2 int) { - _swig_wrap_sealed_i_set(arg1, arg2) -} - -var _wrap_sealed_i_get unsafe.Pointer - -func _swig_wrap_sealed_i_get(base SwigcptrSealed) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_sealed_i_get, _swig_p) - return -} - -func (arg1 SwigcptrSealed) GetI() (_swig_ret int) { - return _swig_wrap_sealed_i_get(arg1) -} - -var _wrap_new_sealed unsafe.Pointer - -func _swig_wrap_new_sealed() (base SwigcptrSealed) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_sealed, _swig_p) - return -} - -func NewSealed() (_swig_ret Sealed) { - return _swig_wrap_new_sealed() -} - -var _wrap_delete_sealed unsafe.Pointer - -func _swig_wrap_delete_sealed(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_sealed, _swig_p) - return -} - -func DeleteSealed(arg1 Sealed) { - _swig_wrap_delete_sealed(arg1.Swigcptr()) -} - -type Sealed interface { - Swigcptr() uintptr - SwigIsSealed() - SetI(arg2 int) - GetI() (_swig_ret int) -} - -var _wrap_Xgo unsafe.Pointer - -func Xgo(arg1 int) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_Xgo, _swig_p) - return -} -var _wrap_Xchan unsafe.Pointer - -func Xchan(arg1 int) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_Xchan, _swig_p) - return -} -var _wrap_end unsafe.Pointer - -func End(arg1 int) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_end, _swig_p) - return -} -var _wrap_nil unsafe.Pointer - -func Nil(arg1 int) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_nil, _swig_p) - return -} - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/keyword_rename_runme b/Examples/test-suite/go/keyword_rename_runme deleted file mode 100755 index b6ae7fe73..000000000 Binary files a/Examples/test-suite/go/keyword_rename_runme and /dev/null differ diff --git a/Examples/test-suite/go/kind.go b/Examples/test-suite/go/kind.go deleted file mode 100644 index 79eaeeeb2..000000000 --- a/Examples/test-suite/go/kind.go +++ /dev/null @@ -1,392 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../kind.i - -package kind - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrFoo uintptr - -func (p SwigcptrFoo) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrFoo) SwigIsFoo() { -} - -var _wrap_new_foo unsafe.Pointer - -func _swig_wrap_new_foo() (base SwigcptrFoo) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_foo, _swig_p) - return -} - -func NewFoo() (_swig_ret Foo) { - return _swig_wrap_new_foo() -} - -var _wrap_delete_foo unsafe.Pointer - -func _swig_wrap_delete_foo(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_foo, _swig_p) - return -} - -func DeleteFoo(arg1 Foo) { - _swig_wrap_delete_foo(arg1.Swigcptr()) -} - -type Foo interface { - Swigcptr() uintptr - SwigIsFoo() -} - -type SwigcptrBar uintptr - -func (p SwigcptrBar) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrBar) SwigIsBar() { -} - -var _wrap_new_bar unsafe.Pointer - -func _swig_wrap_new_bar() (base SwigcptrBar) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_bar, _swig_p) - return -} - -func NewBar() (_swig_ret Bar) { - return _swig_wrap_new_bar() -} - -var _wrap_delete_bar unsafe.Pointer - -func _swig_wrap_delete_bar(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_bar, _swig_p) - return -} - -func DeleteBar(arg1 Bar) { - _swig_wrap_delete_bar(arg1.Swigcptr()) -} - -type Bar interface { - Swigcptr() uintptr - SwigIsBar() -} - -type SwigcptrUni uintptr - -func (p SwigcptrUni) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrUni) SwigIsUni() { -} - -var _wrap_new_uni unsafe.Pointer - -func _swig_wrap_new_uni() (base SwigcptrUni) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_uni, _swig_p) - return -} - -func NewUni() (_swig_ret Uni) { - return _swig_wrap_new_uni() -} - -var _wrap_delete_uni unsafe.Pointer - -func _swig_wrap_delete_uni(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_uni, _swig_p) - return -} - -func DeleteUni(arg1 Uni) { - _swig_wrap_delete_uni(arg1.Swigcptr()) -} - -type Uni interface { - Swigcptr() uintptr - SwigIsUni() -} - -type SwigcptrTest uintptr - -func (p SwigcptrTest) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrTest) SwigIsTest() { -} - -var _wrap_test_foofn unsafe.Pointer - -func _swig_wrap_test_foofn(base SwigcptrTest, _ uintptr, _ uintptr, _ uintptr, _ uintptr, _ uintptr, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_test_foofn, _swig_p) - return -} - -func (arg1 SwigcptrTest) Foofn(arg2 Foo, arg3 Foo, arg4 Foo, arg5 Foo, arg6 Foo, arg7 Foo) { - _swig_wrap_test_foofn(arg1, arg2.Swigcptr(), arg3.Swigcptr(), arg4.Swigcptr(), arg5.Swigcptr(), arg6.Swigcptr(), arg7.Swigcptr()) -} - -var _wrap_test_barfn unsafe.Pointer - -func _swig_wrap_test_barfn(base SwigcptrTest, _ uintptr, _ uintptr, _ uintptr, _ uintptr, _ uintptr, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_test_barfn, _swig_p) - return -} - -func (arg1 SwigcptrTest) Barfn(arg2 Bar, arg3 Bar, arg4 Bar, arg5 Bar, arg6 Bar, arg7 Bar) { - _swig_wrap_test_barfn(arg1, arg2.Swigcptr(), arg3.Swigcptr(), arg4.Swigcptr(), arg5.Swigcptr(), arg6.Swigcptr(), arg7.Swigcptr()) -} - -var _wrap_test_unifn unsafe.Pointer - -func _swig_wrap_test_unifn(base SwigcptrTest, _ uintptr, _ uintptr, _ uintptr, _ uintptr, _ uintptr, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_test_unifn, _swig_p) - return -} - -func (arg1 SwigcptrTest) Unifn(arg2 Uni, arg3 Uni, arg4 Uni, arg5 Uni, arg6 Myuni, arg7 Myuni) { - _swig_wrap_test_unifn(arg1, arg2.Swigcptr(), arg3.Swigcptr(), arg4.Swigcptr(), arg5.Swigcptr(), arg6.Swigcptr(), arg7.Swigcptr()) -} - -var _wrap_test_myFooMember_set unsafe.Pointer - -func _swig_wrap_test_myFooMember_set(base SwigcptrTest, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_test_myFooMember_set, _swig_p) - return -} - -func (arg1 SwigcptrTest) SetMyFooMember(arg2 Foo) { - _swig_wrap_test_myFooMember_set(arg1, arg2.Swigcptr()) -} - -var _wrap_test_myFooMember_get unsafe.Pointer - -func _swig_wrap_test_myFooMember_get(base SwigcptrTest) (_ SwigcptrFoo) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_test_myFooMember_get, _swig_p) - return -} - -func (arg1 SwigcptrTest) GetMyFooMember() (_swig_ret Foo) { - return _swig_wrap_test_myFooMember_get(arg1) -} - -var _wrap_test_myBarMember_set unsafe.Pointer - -func _swig_wrap_test_myBarMember_set(base SwigcptrTest, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_test_myBarMember_set, _swig_p) - return -} - -func (arg1 SwigcptrTest) SetMyBarMember(arg2 Bar) { - _swig_wrap_test_myBarMember_set(arg1, arg2.Swigcptr()) -} - -var _wrap_test_myBarMember_get unsafe.Pointer - -func _swig_wrap_test_myBarMember_get(base SwigcptrTest) (_ SwigcptrBar) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_test_myBarMember_get, _swig_p) - return -} - -func (arg1 SwigcptrTest) GetMyBarMember() (_swig_ret Bar) { - return _swig_wrap_test_myBarMember_get(arg1) -} - -var _wrap_test_myUniMember_set unsafe.Pointer - -func _swig_wrap_test_myUniMember_set(base SwigcptrTest, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_test_myUniMember_set, _swig_p) - return -} - -func (arg1 SwigcptrTest) SetMyUniMember(arg2 Uni) { - _swig_wrap_test_myUniMember_set(arg1, arg2.Swigcptr()) -} - -var _wrap_test_myUniMember_get unsafe.Pointer - -func _swig_wrap_test_myUniMember_get(base SwigcptrTest) (_ SwigcptrUni) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_test_myUniMember_get, _swig_p) - return -} - -func (arg1 SwigcptrTest) GetMyUniMember() (_swig_ret Uni) { - return _swig_wrap_test_myUniMember_get(arg1) -} - -var _wrap_test_mypFooMember_set unsafe.Pointer - -func _swig_wrap_test_mypFooMember_set(base SwigcptrTest, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_test_mypFooMember_set, _swig_p) - return -} - -func (arg1 SwigcptrTest) SetMypFooMember(arg2 Foo) { - _swig_wrap_test_mypFooMember_set(arg1, arg2.Swigcptr()) -} - -var _wrap_test_mypFooMember_get unsafe.Pointer - -func _swig_wrap_test_mypFooMember_get(base SwigcptrTest) (_ SwigcptrFoo) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_test_mypFooMember_get, _swig_p) - return -} - -func (arg1 SwigcptrTest) GetMypFooMember() (_swig_ret Foo) { - return _swig_wrap_test_mypFooMember_get(arg1) -} - -var _wrap_test_mypBarMember_set unsafe.Pointer - -func _swig_wrap_test_mypBarMember_set(base SwigcptrTest, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_test_mypBarMember_set, _swig_p) - return -} - -func (arg1 SwigcptrTest) SetMypBarMember(arg2 Bar) { - _swig_wrap_test_mypBarMember_set(arg1, arg2.Swigcptr()) -} - -var _wrap_test_mypBarMember_get unsafe.Pointer - -func _swig_wrap_test_mypBarMember_get(base SwigcptrTest) (_ SwigcptrBar) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_test_mypBarMember_get, _swig_p) - return -} - -func (arg1 SwigcptrTest) GetMypBarMember() (_swig_ret Bar) { - return _swig_wrap_test_mypBarMember_get(arg1) -} - -var _wrap_test_mypUniMember_set unsafe.Pointer - -func _swig_wrap_test_mypUniMember_set(base SwigcptrTest, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_test_mypUniMember_set, _swig_p) - return -} - -func (arg1 SwigcptrTest) SetMypUniMember(arg2 Uni) { - _swig_wrap_test_mypUniMember_set(arg1, arg2.Swigcptr()) -} - -var _wrap_test_mypUniMember_get unsafe.Pointer - -func _swig_wrap_test_mypUniMember_get(base SwigcptrTest) (_ SwigcptrUni) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_test_mypUniMember_get, _swig_p) - return -} - -func (arg1 SwigcptrTest) GetMypUniMember() (_swig_ret Uni) { - return _swig_wrap_test_mypUniMember_get(arg1) -} - -var _wrap_new_test unsafe.Pointer - -func _swig_wrap_new_test() (base SwigcptrTest) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_test, _swig_p) - return -} - -func NewTest() (_swig_ret Test) { - return _swig_wrap_new_test() -} - -var _wrap_delete_test unsafe.Pointer - -func _swig_wrap_delete_test(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_test, _swig_p) - return -} - -func DeleteTest(arg1 Test) { - _swig_wrap_delete_test(arg1.Swigcptr()) -} - -type Test interface { - Swigcptr() uintptr - SwigIsTest() - Foofn(arg2 Foo, arg3 Foo, arg4 Foo, arg5 Foo, arg6 Foo, arg7 Foo) - Barfn(arg2 Bar, arg3 Bar, arg4 Bar, arg5 Bar, arg6 Bar, arg7 Bar) - Unifn(arg2 Uni, arg3 Uni, arg4 Uni, arg5 Uni, arg6 Myuni, arg7 Myuni) - SetMyFooMember(arg2 Foo) - GetMyFooMember() (_swig_ret Foo) - SetMyBarMember(arg2 Bar) - GetMyBarMember() (_swig_ret Bar) - SetMyUniMember(arg2 Uni) - GetMyUniMember() (_swig_ret Uni) - SetMypFooMember(arg2 Foo) - GetMypFooMember() (_swig_ret Foo) - SetMypBarMember(arg2 Bar) - GetMypBarMember() (_swig_ret Bar) - SetMypUniMember(arg2 Uni) - GetMypUniMember() (_swig_ret Uni) -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - -type SwigcptrMyuni uintptr -type Myuni interface { - Swigcptr() uintptr; -} -func (p SwigcptrMyuni) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/langobj.go b/Examples/test-suite/go/langobj.go deleted file mode 100644 index 36aa23339..000000000 --- a/Examples/test-suite/go/langobj.go +++ /dev/null @@ -1,36 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../langobj.i - -package langobj - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -var _wrap_identity unsafe.Pointer - -func Identity(arg1 uintptr) (_swig_ret uintptr) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_identity, _swig_p) - return -} - diff --git a/Examples/test-suite/go/lextype.go b/Examples/test-suite/go/lextype.go deleted file mode 100644 index 7aa39bfcb..000000000 --- a/Examples/test-suite/go/lextype.go +++ /dev/null @@ -1,70 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../lextype.i - -package lextype - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -const HEIGHT_Giraffe int = 100 -const WIDTH_Giraffe int = 5 -var _wrap_eat unsafe.Pointer - -func _swig_wrap_eat(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_eat, _swig_p) - return -} - -func Eat(arg1 uintptr) { - _swig_wrap_eat(arg1) -} - -var _wrap_drink unsafe.Pointer - -func _swig_wrap_drink(base *uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_drink, _swig_p) - return -} - -func Drink(arg1 *uintptr) { - _swig_wrap_drink(arg1) -} - -var _wrap_mate unsafe.Pointer - -func Mate(arg1 *uintptr) (_swig_ret uintptr) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_mate, _swig_p) - return -} - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/li_attribute.go b/Examples/test-suite/go/li_attribute.go deleted file mode 100644 index be5331738..000000000 --- a/Examples/test-suite/go/li_attribute.go +++ /dev/null @@ -1,576 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../li_attribute.i - -package li_attribute - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrA uintptr - -func (p SwigcptrA) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrA) SwigIsA() { -} - -var _wrap_new_A unsafe.Pointer - -func _swig_wrap_new_A(base int, _ int, _ int) (_ SwigcptrA) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_A, _swig_p) - return -} - -func NewA(arg1 int, arg2 int, arg3 int) (_swig_ret A) { - return _swig_wrap_new_A(arg1, arg2, arg3) -} - -var _wrap_A_a_set unsafe.Pointer - -func _swig_wrap_A_a_set(base SwigcptrA, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_A_a_set, _swig_p) - return -} - -func (arg1 SwigcptrA) SetA(arg2 int) { - _swig_wrap_A_a_set(arg1, arg2) -} - -var _wrap_A_a_get unsafe.Pointer - -func _swig_wrap_A_a_get(base SwigcptrA) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_A_a_get, _swig_p) - return -} - -func (arg1 SwigcptrA) GetA() (_swig_ret int) { - return _swig_wrap_A_a_get(arg1) -} - -var _wrap_A_b_set unsafe.Pointer - -func _swig_wrap_A_b_set(base SwigcptrA, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_A_b_set, _swig_p) - return -} - -func (arg1 SwigcptrA) SetB(arg2 int) { - _swig_wrap_A_b_set(arg1, arg2) -} - -var _wrap_A_b_get unsafe.Pointer - -func _swig_wrap_A_b_get(base SwigcptrA) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_A_b_get, _swig_p) - return -} - -func (arg1 SwigcptrA) GetB() (_swig_ret int) { - return _swig_wrap_A_b_get(arg1) -} - -var _wrap_A_c_get unsafe.Pointer - -func _swig_wrap_A_c_get(base SwigcptrA) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_A_c_get, _swig_p) - return -} - -func (arg1 SwigcptrA) GetC() (_swig_ret int) { - return _swig_wrap_A_c_get(arg1) -} - -var _wrap_A_d_set unsafe.Pointer - -func _swig_wrap_A_d_set(base SwigcptrA, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_A_d_set, _swig_p) - return -} - -func (arg1 SwigcptrA) SetD(arg2 int) { - _swig_wrap_A_d_set(arg1, arg2) -} - -var _wrap_A_d_get unsafe.Pointer - -func _swig_wrap_A_d_get(base SwigcptrA) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_A_d_get, _swig_p) - return -} - -func (arg1 SwigcptrA) GetD() (_swig_ret int) { - return _swig_wrap_A_d_get(arg1) -} - -var _wrap_delete_A unsafe.Pointer - -func _swig_wrap_delete_A(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_A, _swig_p) - return -} - -func DeleteA(arg1 A) { - _swig_wrap_delete_A(arg1.Swigcptr()) -} - -type A interface { - Swigcptr() uintptr - SwigIsA() - SetA(arg2 int) - GetA() (_swig_ret int) - SetB(arg2 int) - GetB() (_swig_ret int) - GetC() (_swig_ret int) - SetD(arg2 int) - GetD() (_swig_ret int) -} - -type SwigcptrB uintptr - -func (p SwigcptrB) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrB) SwigIsB() { -} - -var _wrap_new_B unsafe.Pointer - -func _swig_wrap_new_B(base uintptr) (_ SwigcptrB) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_B, _swig_p) - return -} - -func NewB(arg1 A) (_swig_ret B) { - return _swig_wrap_new_B(arg1.Swigcptr()) -} - -var _wrap_B_a_set unsafe.Pointer - -func _swig_wrap_B_a_set(base SwigcptrB, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_B_a_set, _swig_p) - return -} - -func (arg1 SwigcptrB) SetA(arg2 A) { - _swig_wrap_B_a_set(arg1, arg2.Swigcptr()) -} - -var _wrap_B_a_get unsafe.Pointer - -func _swig_wrap_B_a_get(base SwigcptrB) (_ SwigcptrA) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_B_a_get, _swig_p) - return -} - -func (arg1 SwigcptrB) GetA() (_swig_ret A) { - return _swig_wrap_B_a_get(arg1) -} - -var _wrap_delete_B unsafe.Pointer - -func _swig_wrap_delete_B(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_B, _swig_p) - return -} - -func DeleteB(arg1 B) { - _swig_wrap_delete_B(arg1.Swigcptr()) -} - -type B interface { - Swigcptr() uintptr - SwigIsB() - SetA(arg2 A) - GetA() (_swig_ret A) -} - -type SwigcptrParam_i uintptr - -func (p SwigcptrParam_i) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrParam_i) SwigIsParam_i() { -} - -var _wrap_new_Param_i unsafe.Pointer - -func _swig_wrap_new_Param_i(base int) (_ SwigcptrParam_i) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Param_i, _swig_p) - return -} - -func NewParam_i(arg1 int) (_swig_ret Param_i) { - return _swig_wrap_new_Param_i(arg1) -} - -var _wrap_Param_i_value_set unsafe.Pointer - -func _swig_wrap_Param_i_value_set(base SwigcptrParam_i, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Param_i_value_set, _swig_p) - return -} - -func (arg1 SwigcptrParam_i) SetValue(arg2 int) { - _swig_wrap_Param_i_value_set(arg1, arg2) -} - -var _wrap_Param_i_value_get unsafe.Pointer - -func _swig_wrap_Param_i_value_get(base SwigcptrParam_i) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Param_i_value_get, _swig_p) - return -} - -func (arg1 SwigcptrParam_i) GetValue() (_swig_ret int) { - return _swig_wrap_Param_i_value_get(arg1) -} - -var _wrap_delete_Param_i unsafe.Pointer - -func _swig_wrap_delete_Param_i(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Param_i, _swig_p) - return -} - -func DeleteParam_i(arg1 Param_i) { - _swig_wrap_delete_Param_i(arg1.Swigcptr()) -} - -type Param_i interface { - Swigcptr() uintptr - SwigIsParam_i() - SetValue(arg2 int) - GetValue() (_swig_ret int) -} - -type SwigcptrMyFoo uintptr - -func (p SwigcptrMyFoo) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrMyFoo) SwigIsMyFoo() { -} - -var _wrap_new_MyFoo unsafe.Pointer - -func _swig_wrap_new_MyFoo() (base SwigcptrMyFoo) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_MyFoo, _swig_p) - return -} - -func NewMyFoo() (_swig_ret MyFoo) { - return _swig_wrap_new_MyFoo() -} - -var _wrap_MyFoo_x_set unsafe.Pointer - -func _swig_wrap_MyFoo_x_set(base SwigcptrMyFoo, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_MyFoo_x_set, _swig_p) - return -} - -func (arg1 SwigcptrMyFoo) SetX(arg2 int) { - _swig_wrap_MyFoo_x_set(arg1, arg2) -} - -var _wrap_MyFoo_x_get unsafe.Pointer - -func _swig_wrap_MyFoo_x_get(base SwigcptrMyFoo) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_MyFoo_x_get, _swig_p) - return -} - -func (arg1 SwigcptrMyFoo) GetX() (_swig_ret int) { - return _swig_wrap_MyFoo_x_get(arg1) -} - -var _wrap_delete_MyFoo unsafe.Pointer - -func _swig_wrap_delete_MyFoo(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_MyFoo, _swig_p) - return -} - -func DeleteMyFoo(arg1 MyFoo) { - _swig_wrap_delete_MyFoo(arg1.Swigcptr()) -} - -type MyFoo interface { - Swigcptr() uintptr - SwigIsMyFoo() - SetX(arg2 int) - GetX() (_swig_ret int) -} - -type SwigcptrMyClass uintptr - -func (p SwigcptrMyClass) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrMyClass) SwigIsMyClass() { -} - -var _wrap_MyClass_Foo_set unsafe.Pointer - -func _swig_wrap_MyClass_Foo_set(base SwigcptrMyClass, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_MyClass_Foo_set, _swig_p) - return -} - -func (arg1 SwigcptrMyClass) SetFoo(arg2 MyFoo) { - _swig_wrap_MyClass_Foo_set(arg1, arg2.Swigcptr()) -} - -var _wrap_MyClass_Foo_get unsafe.Pointer - -func _swig_wrap_MyClass_Foo_get(base SwigcptrMyClass) (_ SwigcptrMyFoo) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_MyClass_Foo_get, _swig_p) - return -} - -func (arg1 SwigcptrMyClass) GetFoo() (_swig_ret MyFoo) { - return _swig_wrap_MyClass_Foo_get(arg1) -} - -var _wrap_new_MyClass unsafe.Pointer - -func _swig_wrap_new_MyClass() (base SwigcptrMyClass) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_MyClass, _swig_p) - return -} - -func NewMyClass() (_swig_ret MyClass) { - return _swig_wrap_new_MyClass() -} - -var _wrap_delete_MyClass unsafe.Pointer - -func _swig_wrap_delete_MyClass(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_MyClass, _swig_p) - return -} - -func DeleteMyClass(arg1 MyClass) { - _swig_wrap_delete_MyClass(arg1.Swigcptr()) -} - -type MyClass interface { - Swigcptr() uintptr - SwigIsMyClass() - SetFoo(arg2 MyFoo) - GetFoo() (_swig_ret MyFoo) -} - -type SwigcptrMyClassVal uintptr - -func (p SwigcptrMyClassVal) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrMyClassVal) SwigIsMyClassVal() { -} - -var _wrap_MyClassVal_ReadWriteFoo_set unsafe.Pointer - -func _swig_wrap_MyClassVal_ReadWriteFoo_set(base SwigcptrMyClassVal, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_MyClassVal_ReadWriteFoo_set, _swig_p) - return -} - -func (arg1 SwigcptrMyClassVal) SetReadWriteFoo(arg2 MyFoo) { - _swig_wrap_MyClassVal_ReadWriteFoo_set(arg1, arg2.Swigcptr()) -} - -var _wrap_MyClassVal_ReadWriteFoo_get unsafe.Pointer - -func _swig_wrap_MyClassVal_ReadWriteFoo_get(base SwigcptrMyClassVal) (_ SwigcptrMyFoo) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_MyClassVal_ReadWriteFoo_get, _swig_p) - return -} - -func (arg1 SwigcptrMyClassVal) GetReadWriteFoo() (_swig_ret MyFoo) { - return _swig_wrap_MyClassVal_ReadWriteFoo_get(arg1) -} - -var _wrap_MyClassVal_ReadOnlyFoo_get unsafe.Pointer - -func _swig_wrap_MyClassVal_ReadOnlyFoo_get(base SwigcptrMyClassVal) (_ SwigcptrMyFoo) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_MyClassVal_ReadOnlyFoo_get, _swig_p) - return -} - -func (arg1 SwigcptrMyClassVal) GetReadOnlyFoo() (_swig_ret MyFoo) { - return _swig_wrap_MyClassVal_ReadOnlyFoo_get(arg1) -} - -var _wrap_new_MyClassVal unsafe.Pointer - -func _swig_wrap_new_MyClassVal() (base SwigcptrMyClassVal) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_MyClassVal, _swig_p) - return -} - -func NewMyClassVal() (_swig_ret MyClassVal) { - return _swig_wrap_new_MyClassVal() -} - -var _wrap_delete_MyClassVal unsafe.Pointer - -func _swig_wrap_delete_MyClassVal(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_MyClassVal, _swig_p) - return -} - -func DeleteMyClassVal(arg1 MyClassVal) { - _swig_wrap_delete_MyClassVal(arg1.Swigcptr()) -} - -type MyClassVal interface { - Swigcptr() uintptr - SwigIsMyClassVal() - SetReadWriteFoo(arg2 MyFoo) - GetReadWriteFoo() (_swig_ret MyFoo) - GetReadOnlyFoo() (_swig_ret MyFoo) -} - -type SwigcptrMyStringyClass uintptr - -func (p SwigcptrMyStringyClass) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrMyStringyClass) SwigIsMyStringyClass() { -} - -var _wrap_new_MyStringyClass unsafe.Pointer - -func _swig_wrap_new_MyStringyClass(base string) (_ SwigcptrMyStringyClass) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_MyStringyClass, _swig_p) - return -} - -func NewMyStringyClass(arg1 string) (_swig_ret MyStringyClass) { - return _swig_wrap_new_MyStringyClass(arg1) -} - -var _wrap_MyStringyClass_ReadWriteString_set unsafe.Pointer - -func _swig_wrap_MyStringyClass_ReadWriteString_set(base SwigcptrMyStringyClass, _ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_MyStringyClass_ReadWriteString_set, _swig_p) - return -} - -func (arg1 SwigcptrMyStringyClass) SetReadWriteString(arg2 string) { - _swig_wrap_MyStringyClass_ReadWriteString_set(arg1, arg2) -} - -var _wrap_MyStringyClass_ReadWriteString_get unsafe.Pointer - -func _swig_wrap_MyStringyClass_ReadWriteString_get(base SwigcptrMyStringyClass) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_MyStringyClass_ReadWriteString_get, _swig_p) - return -} - -func (arg1 SwigcptrMyStringyClass) GetReadWriteString() (_swig_ret string) { - return _swig_wrap_MyStringyClass_ReadWriteString_get(arg1) -} - -var _wrap_MyStringyClass_ReadOnlyString_get unsafe.Pointer - -func _swig_wrap_MyStringyClass_ReadOnlyString_get(base SwigcptrMyStringyClass) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_MyStringyClass_ReadOnlyString_get, _swig_p) - return -} - -func (arg1 SwigcptrMyStringyClass) GetReadOnlyString() (_swig_ret string) { - return _swig_wrap_MyStringyClass_ReadOnlyString_get(arg1) -} - -var _wrap_delete_MyStringyClass unsafe.Pointer - -func _swig_wrap_delete_MyStringyClass(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_MyStringyClass, _swig_p) - return -} - -func DeleteMyStringyClass(arg1 MyStringyClass) { - _swig_wrap_delete_MyStringyClass(arg1.Swigcptr()) -} - -type MyStringyClass interface { - Swigcptr() uintptr - SwigIsMyStringyClass() - SetReadWriteString(arg2 string) - GetReadWriteString() (_swig_ret string) - GetReadOnlyString() (_swig_ret string) -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/li_attribute_runme b/Examples/test-suite/go/li_attribute_runme deleted file mode 100755 index f6f612ff4..000000000 Binary files a/Examples/test-suite/go/li_attribute_runme and /dev/null differ diff --git a/Examples/test-suite/go/li_attribute_template.go b/Examples/test-suite/go/li_attribute_template.go deleted file mode 100644 index 2b5afa26c..000000000 --- a/Examples/test-suite/go/li_attribute_template.go +++ /dev/null @@ -1,411 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../li_attribute_template.i - -package li_attribute_template - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrFoo uintptr - -func (p SwigcptrFoo) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrFoo) SwigIsFoo() { -} - -var _wrap_new_Foo unsafe.Pointer - -func _swig_wrap_new_Foo(base int) (_ SwigcptrFoo) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Foo, _swig_p) - return -} - -func NewFoo(arg1 int) (_swig_ret Foo) { - return _swig_wrap_new_Foo(arg1) -} - -var _wrap_Foo_value_set unsafe.Pointer - -func _swig_wrap_Foo_value_set(base SwigcptrFoo, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_value_set, _swig_p) - return -} - -func (arg1 SwigcptrFoo) SetValue(arg2 int) { - _swig_wrap_Foo_value_set(arg1, arg2) -} - -var _wrap_Foo_value_get unsafe.Pointer - -func _swig_wrap_Foo_value_get(base SwigcptrFoo) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_value_get, _swig_p) - return -} - -func (arg1 SwigcptrFoo) GetValue() (_swig_ret int) { - return _swig_wrap_Foo_value_get(arg1) -} - -var _wrap_delete_Foo unsafe.Pointer - -func _swig_wrap_delete_Foo(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Foo, _swig_p) - return -} - -func DeleteFoo(arg1 Foo) { - _swig_wrap_delete_Foo(arg1.Swigcptr()) -} - -type Foo interface { - Swigcptr() uintptr - SwigIsFoo() - SetValue(arg2 int) - GetValue() (_swig_ret int) -} - -type SwigcptrPair_intint uintptr - -func (p SwigcptrPair_intint) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrPair_intint) SwigIsPair_intint() { -} - -var _wrap_new_pair_intint unsafe.Pointer - -func _swig_wrap_new_pair_intint(base int, _ int) (_ SwigcptrPair_intint) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_pair_intint, _swig_p) - return -} - -func NewPair_intint(arg1 int, arg2 int) (_swig_ret Pair_intint) { - return _swig_wrap_new_pair_intint(arg1, arg2) -} - -var _wrap_pair_intint_first_set unsafe.Pointer - -func _swig_wrap_pair_intint_first_set(base SwigcptrPair_intint, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_pair_intint_first_set, _swig_p) - return -} - -func (arg1 SwigcptrPair_intint) SetFirst(arg2 int) { - _swig_wrap_pair_intint_first_set(arg1, arg2) -} - -var _wrap_pair_intint_first_get unsafe.Pointer - -func _swig_wrap_pair_intint_first_get(base SwigcptrPair_intint) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_pair_intint_first_get, _swig_p) - return -} - -func (arg1 SwigcptrPair_intint) GetFirst() (_swig_ret int) { - return _swig_wrap_pair_intint_first_get(arg1) -} - -var _wrap_pair_intint_second_set unsafe.Pointer - -func _swig_wrap_pair_intint_second_set(base SwigcptrPair_intint, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_pair_intint_second_set, _swig_p) - return -} - -func (arg1 SwigcptrPair_intint) SetSecond(arg2 int) { - _swig_wrap_pair_intint_second_set(arg1, arg2) -} - -var _wrap_pair_intint_second_get unsafe.Pointer - -func _swig_wrap_pair_intint_second_get(base SwigcptrPair_intint) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_pair_intint_second_get, _swig_p) - return -} - -func (arg1 SwigcptrPair_intint) GetSecond() (_swig_ret int) { - return _swig_wrap_pair_intint_second_get(arg1) -} - -var _wrap_delete_pair_intint unsafe.Pointer - -func _swig_wrap_delete_pair_intint(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_pair_intint, _swig_p) - return -} - -func DeletePair_intint(arg1 Pair_intint) { - _swig_wrap_delete_pair_intint(arg1.Swigcptr()) -} - -type Pair_intint interface { - Swigcptr() uintptr - SwigIsPair_intint() - SetFirst(arg2 int) - GetFirst() (_swig_ret int) - SetSecond(arg2 int) - GetSecond() (_swig_ret int) -} - -type SwigcptrCintint uintptr - -func (p SwigcptrCintint) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrCintint) SwigIsCintint() { -} - -var _wrap_new_Cintint unsafe.Pointer - -func _swig_wrap_new_Cintint(base int, _ int, _ int) (_ SwigcptrCintint) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Cintint, _swig_p) - return -} - -func NewCintint(arg1 int, arg2 int, arg3 int) (_swig_ret Cintint) { - return _swig_wrap_new_Cintint(arg1, arg2, arg3) -} - -var _wrap_Cintint_a_set unsafe.Pointer - -func _swig_wrap_Cintint_a_set(base SwigcptrCintint, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Cintint_a_set, _swig_p) - return -} - -func (arg1 SwigcptrCintint) SetA(arg2 int) { - _swig_wrap_Cintint_a_set(arg1, arg2) -} - -var _wrap_Cintint_a_get unsafe.Pointer - -func _swig_wrap_Cintint_a_get(base SwigcptrCintint) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Cintint_a_get, _swig_p) - return -} - -func (arg1 SwigcptrCintint) GetA() (_swig_ret int) { - return _swig_wrap_Cintint_a_get(arg1) -} - -var _wrap_Cintint_b_set unsafe.Pointer - -func _swig_wrap_Cintint_b_set(base SwigcptrCintint, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Cintint_b_set, _swig_p) - return -} - -func (arg1 SwigcptrCintint) SetB(arg2 int) { - _swig_wrap_Cintint_b_set(arg1, arg2) -} - -var _wrap_Cintint_b_get unsafe.Pointer - -func _swig_wrap_Cintint_b_get(base SwigcptrCintint) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Cintint_b_get, _swig_p) - return -} - -func (arg1 SwigcptrCintint) GetB() (_swig_ret int) { - return _swig_wrap_Cintint_b_get(arg1) -} - -var _wrap_Cintint_str_set unsafe.Pointer - -func _swig_wrap_Cintint_str_set(base SwigcptrCintint, _ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Cintint_str_set, _swig_p) - return -} - -func (arg1 SwigcptrCintint) SetStr(arg2 string) { - _swig_wrap_Cintint_str_set(arg1, arg2) -} - -var _wrap_Cintint_str_get unsafe.Pointer - -func _swig_wrap_Cintint_str_get(base SwigcptrCintint) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Cintint_str_get, _swig_p) - return -} - -func (arg1 SwigcptrCintint) GetStr() (_swig_ret string) { - return _swig_wrap_Cintint_str_get(arg1) -} - -var _wrap_Cintint_d_set unsafe.Pointer - -func _swig_wrap_Cintint_d_set(base SwigcptrCintint, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Cintint_d_set, _swig_p) - return -} - -func (arg1 SwigcptrCintint) SetD(arg2 Foo) { - _swig_wrap_Cintint_d_set(arg1, arg2.Swigcptr()) -} - -var _wrap_Cintint_d_get unsafe.Pointer - -func _swig_wrap_Cintint_d_get(base SwigcptrCintint) (_ SwigcptrFoo) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Cintint_d_get, _swig_p) - return -} - -func (arg1 SwigcptrCintint) GetD() (_swig_ret Foo) { - return _swig_wrap_Cintint_d_get(arg1) -} - -var _wrap_Cintint_e_set unsafe.Pointer - -func _swig_wrap_Cintint_e_set(base SwigcptrCintint, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Cintint_e_set, _swig_p) - return -} - -func (arg1 SwigcptrCintint) SetE(arg2 Foo) { - _swig_wrap_Cintint_e_set(arg1, arg2.Swigcptr()) -} - -var _wrap_Cintint_e_get unsafe.Pointer - -func _swig_wrap_Cintint_e_get(base SwigcptrCintint) (_ SwigcptrFoo) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Cintint_e_get, _swig_p) - return -} - -func (arg1 SwigcptrCintint) GetE() (_swig_ret Foo) { - return _swig_wrap_Cintint_e_get(arg1) -} - -var _wrap_Cintint_f_set unsafe.Pointer - -func _swig_wrap_Cintint_f_set(base SwigcptrCintint, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Cintint_f_set, _swig_p) - return -} - -func (arg1 SwigcptrCintint) SetF(arg2 Pair_intint) { - _swig_wrap_Cintint_f_set(arg1, arg2.Swigcptr()) -} - -var _wrap_Cintint_f_get unsafe.Pointer - -func _swig_wrap_Cintint_f_get(base SwigcptrCintint) (_ SwigcptrPair_intint) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Cintint_f_get, _swig_p) - return -} - -func (arg1 SwigcptrCintint) GetF() (_swig_ret Pair_intint) { - return _swig_wrap_Cintint_f_get(arg1) -} - -var _wrap_Cintint_g_set unsafe.Pointer - -func _swig_wrap_Cintint_g_set(base SwigcptrCintint, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Cintint_g_set, _swig_p) - return -} - -func (arg1 SwigcptrCintint) SetG(arg2 Pair_intint) { - _swig_wrap_Cintint_g_set(arg1, arg2.Swigcptr()) -} - -var _wrap_Cintint_g_get unsafe.Pointer - -func _swig_wrap_Cintint_g_get(base SwigcptrCintint) (_ SwigcptrPair_intint) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Cintint_g_get, _swig_p) - return -} - -func (arg1 SwigcptrCintint) GetG() (_swig_ret Pair_intint) { - return _swig_wrap_Cintint_g_get(arg1) -} - -var _wrap_delete_Cintint unsafe.Pointer - -func _swig_wrap_delete_Cintint(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Cintint, _swig_p) - return -} - -func DeleteCintint(arg1 Cintint) { - _swig_wrap_delete_Cintint(arg1.Swigcptr()) -} - -type Cintint interface { - Swigcptr() uintptr - SwigIsCintint() - SetA(arg2 int) - GetA() (_swig_ret int) - SetB(arg2 int) - GetB() (_swig_ret int) - SetStr(arg2 string) - GetStr() (_swig_ret string) - SetD(arg2 Foo) - GetD() (_swig_ret Foo) - SetE(arg2 Foo) - GetE() (_swig_ret Foo) - SetF(arg2 Pair_intint) - GetF() (_swig_ret Pair_intint) - SetG(arg2 Pair_intint) - GetG() (_swig_ret Pair_intint) -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/li_boost_shared_ptr.go b/Examples/test-suite/go/li_boost_shared_ptr.go deleted file mode 100644 index de3f8d872..000000000 --- a/Examples/test-suite/go/li_boost_shared_ptr.go +++ /dev/null @@ -1,1856 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../li_boost_shared_ptr.i - -package li_boost_shared_ptr - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -var _wrap_debug_shared_set unsafe.Pointer - -func _swig_wrap_debug_shared_set(base bool) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_debug_shared_set, _swig_p) - return -} - -func SetDebug_shared(arg1 bool) { - _swig_wrap_debug_shared_set(arg1) -} - -var _wrap_debug_shared_get unsafe.Pointer - -func GetDebug_shared() (_swig_ret bool) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_debug_shared_get, _swig_p) - return -} -type SwigcptrKlass uintptr - -func (p SwigcptrKlass) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrKlass) SwigIsKlass() { -} - -var _wrap_new_Klass__SWIG_0 unsafe.Pointer - -func _swig_wrap_new_Klass__SWIG_0() (base SwigcptrKlass) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Klass__SWIG_0, _swig_p) - return -} - -func NewKlass__SWIG_0() (_swig_ret Klass) { - return _swig_wrap_new_Klass__SWIG_0() -} - -var _wrap_new_Klass__SWIG_1 unsafe.Pointer - -func _swig_wrap_new_Klass__SWIG_1(base string) (_ SwigcptrKlass) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Klass__SWIG_1, _swig_p) - return -} - -func NewKlass__SWIG_1(arg1 string) (_swig_ret Klass) { - return _swig_wrap_new_Klass__SWIG_1(arg1) -} - -var _wrap_delete_Klass unsafe.Pointer - -func _swig_wrap_delete_Klass(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Klass, _swig_p) - return -} - -func DeleteKlass(arg1 Klass) { - _swig_wrap_delete_Klass(arg1.Swigcptr()) -} - -var _wrap_Klass_getValue unsafe.Pointer - -func _swig_wrap_Klass_getValue(base SwigcptrKlass) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Klass_getValue, _swig_p) - return -} - -func (arg1 SwigcptrKlass) GetValue() (_swig_ret string) { - return _swig_wrap_Klass_getValue(arg1) -} - -var _wrap_Klass_append unsafe.Pointer - -func _swig_wrap_Klass_append(base SwigcptrKlass, _ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Klass_append, _swig_p) - return -} - -func (arg1 SwigcptrKlass) Append(arg2 string) { - _swig_wrap_Klass_append(arg1, arg2) -} - -var _wrap_new_Klass__SWIG_2 unsafe.Pointer - -func _swig_wrap_new_Klass__SWIG_2(base uintptr) (_ SwigcptrKlass) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Klass__SWIG_2, _swig_p) - return -} - -func NewKlass__SWIG_2(arg1 Klass) (_swig_ret Klass) { - return _swig_wrap_new_Klass__SWIG_2(arg1.Swigcptr()) -} - -func NewKlass(a ...interface{}) Klass { - argc := len(a) - if argc == 0 { - return NewKlass__SWIG_0() - } - if argc == 1 { - if _, ok := a[0].(string); !ok { - goto check_2 - } - return NewKlass__SWIG_1(a[0].(string)) - } -check_2: - if argc == 1 { - return NewKlass__SWIG_2(a[0].(Klass)) - } - panic("No match for overloaded function call") -} - -var _wrap_Klass_getTotal_count unsafe.Pointer - -func KlassGetTotal_count() (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_Klass_getTotal_count, _swig_p) - return -} -type Klass interface { - Swigcptr() uintptr - SwigIsKlass() - GetValue() (_swig_ret string) - Append(arg2 string) -} - -type SwigcptrKlassDerived uintptr - -func (p SwigcptrKlassDerived) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrKlassDerived) SwigIsKlassDerived() { -} - -var _wrap_new_KlassDerived__SWIG_0 unsafe.Pointer - -func _swig_wrap_new_KlassDerived__SWIG_0() (base SwigcptrKlassDerived) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_KlassDerived__SWIG_0, _swig_p) - return -} - -func NewKlassDerived__SWIG_0() (_swig_ret KlassDerived) { - return _swig_wrap_new_KlassDerived__SWIG_0() -} - -var _wrap_new_KlassDerived__SWIG_1 unsafe.Pointer - -func _swig_wrap_new_KlassDerived__SWIG_1(base string) (_ SwigcptrKlassDerived) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_KlassDerived__SWIG_1, _swig_p) - return -} - -func NewKlassDerived__SWIG_1(arg1 string) (_swig_ret KlassDerived) { - return _swig_wrap_new_KlassDerived__SWIG_1(arg1) -} - -var _wrap_new_KlassDerived__SWIG_2 unsafe.Pointer - -func _swig_wrap_new_KlassDerived__SWIG_2(base uintptr) (_ SwigcptrKlassDerived) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_KlassDerived__SWIG_2, _swig_p) - return -} - -func NewKlassDerived__SWIG_2(arg1 KlassDerived) (_swig_ret KlassDerived) { - return _swig_wrap_new_KlassDerived__SWIG_2(arg1.Swigcptr()) -} - -func NewKlassDerived(a ...interface{}) KlassDerived { - argc := len(a) - if argc == 0 { - return NewKlassDerived__SWIG_0() - } - if argc == 1 { - if _, ok := a[0].(string); !ok { - goto check_2 - } - return NewKlassDerived__SWIG_1(a[0].(string)) - } -check_2: - if argc == 1 { - return NewKlassDerived__SWIG_2(a[0].(KlassDerived)) - } - panic("No match for overloaded function call") -} - -var _wrap_delete_KlassDerived unsafe.Pointer - -func _swig_wrap_delete_KlassDerived(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_KlassDerived, _swig_p) - return -} - -func DeleteKlassDerived(arg1 KlassDerived) { - _swig_wrap_delete_KlassDerived(arg1.Swigcptr()) -} - -var _wrap_KlassDerived_getValue unsafe.Pointer - -func _swig_wrap_KlassDerived_getValue(base SwigcptrKlassDerived) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_KlassDerived_getValue, _swig_p) - return -} - -func (arg1 SwigcptrKlassDerived) GetValue() (_swig_ret string) { - return _swig_wrap_KlassDerived_getValue(arg1) -} - -var _wrap_KlassDerived_append unsafe.Pointer - -func _swig_wrap_KlassDerived_append(base SwigcptrKlassDerived, _ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_KlassDerived_append, _swig_p) - return -} - -func (_swig_base SwigcptrKlassDerived) Append(arg1 string) { - _swig_wrap_KlassDerived_append(_swig_base, arg1) -} - -var _wrap_KlassDerived_getTotal_count unsafe.Pointer - -func KlassDerivedGetTotal_count() (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_KlassDerived_getTotal_count, _swig_p) - return -} -var _wrap_KlassDerived_SwigGetKlass unsafe.Pointer - -func _swig_wrap_KlassDerived_SwigGetKlass(base SwigcptrKlassDerived) (_ SwigcptrKlass) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_KlassDerived_SwigGetKlass, _swig_p) - return -} - -func (arg1 SwigcptrKlassDerived) SwigGetKlass() (_swig_ret Klass) { - return _swig_wrap_KlassDerived_SwigGetKlass(arg1) -} - -type KlassDerived interface { - Swigcptr() uintptr - SwigIsKlassDerived() - GetValue() (_swig_ret string) - Append(arg1 string) - SwigGetKlass() (_swig_ret Klass) -} - -var _wrap_derivedpointertest unsafe.Pointer - -func _swig_wrap_derivedpointertest(base uintptr) (_ SwigcptrKlassDerived) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_derivedpointertest, _swig_p) - return -} - -func Derivedpointertest(arg1 KlassDerived) (_swig_ret KlassDerived) { - return _swig_wrap_derivedpointertest(arg1.Swigcptr()) -} - -var _wrap_derivedreftest unsafe.Pointer - -func _swig_wrap_derivedreftest(base uintptr) (_ SwigcptrKlassDerived) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_derivedreftest, _swig_p) - return -} - -func Derivedreftest(arg1 KlassDerived) (_swig_ret KlassDerived) { - return _swig_wrap_derivedreftest(arg1.Swigcptr()) -} - -var _wrap_derivedsmartptrtest unsafe.Pointer - -func _swig_wrap_derivedsmartptrtest(base uintptr) (_ SwigcptrSwigBoost_shared_ptr_Sl_Space_KlassDerived_Sg_) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_derivedsmartptrtest, _swig_p) - return -} - -func Derivedsmartptrtest(arg1 SwigBoost_shared_ptr_Sl_Space_KlassDerived_Sg_) (_swig_ret SwigBoost_shared_ptr_Sl_Space_KlassDerived_Sg_) { - return _swig_wrap_derivedsmartptrtest(arg1.Swigcptr()) -} - -var _wrap_derivedsmartptrpointertest unsafe.Pointer - -func _swig_wrap_derivedsmartptrpointertest(base uintptr) (_ SwigcptrSwigBoost_shared_ptr_Sl_Space_KlassDerived_Sg_) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_derivedsmartptrpointertest, _swig_p) - return -} - -func Derivedsmartptrpointertest(arg1 SwigBoost_shared_ptr_Sl_Space_KlassDerived_Sg_) (_swig_ret SwigBoost_shared_ptr_Sl_Space_KlassDerived_Sg_) { - return _swig_wrap_derivedsmartptrpointertest(arg1.Swigcptr()) -} - -var _wrap_derivedsmartptrreftest unsafe.Pointer - -func _swig_wrap_derivedsmartptrreftest(base uintptr) (_ SwigcptrSwigBoost_shared_ptr_Sl_Space_KlassDerived_Sg_) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_derivedsmartptrreftest, _swig_p) - return -} - -func Derivedsmartptrreftest(arg1 SwigBoost_shared_ptr_Sl_Space_KlassDerived_Sg_) (_swig_ret SwigBoost_shared_ptr_Sl_Space_KlassDerived_Sg_) { - return _swig_wrap_derivedsmartptrreftest(arg1.Swigcptr()) -} - -var _wrap_derivedsmartptrpointerreftest unsafe.Pointer - -func _swig_wrap_derivedsmartptrpointerreftest(base uintptr) (_ SwigcptrSwigBoost_shared_ptr_Sl_Space_KlassDerived_Sg_) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_derivedsmartptrpointerreftest, _swig_p) - return -} - -func Derivedsmartptrpointerreftest(arg1 SwigBoost_shared_ptr_Sl_Space_KlassDerived_Sg_) (_swig_ret SwigBoost_shared_ptr_Sl_Space_KlassDerived_Sg_) { - return _swig_wrap_derivedsmartptrpointerreftest(arg1.Swigcptr()) -} - -type SwigcptrKlass2ndDerived uintptr - -func (p SwigcptrKlass2ndDerived) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrKlass2ndDerived) SwigIsKlass2ndDerived() { -} - -var _wrap_new_Klass2ndDerived__SWIG_0 unsafe.Pointer - -func _swig_wrap_new_Klass2ndDerived__SWIG_0() (base SwigcptrKlass2ndDerived) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Klass2ndDerived__SWIG_0, _swig_p) - return -} - -func NewKlass2ndDerived__SWIG_0() (_swig_ret Klass2ndDerived) { - return _swig_wrap_new_Klass2ndDerived__SWIG_0() -} - -var _wrap_new_Klass2ndDerived__SWIG_1 unsafe.Pointer - -func _swig_wrap_new_Klass2ndDerived__SWIG_1(base string) (_ SwigcptrKlass2ndDerived) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Klass2ndDerived__SWIG_1, _swig_p) - return -} - -func NewKlass2ndDerived__SWIG_1(arg1 string) (_swig_ret Klass2ndDerived) { - return _swig_wrap_new_Klass2ndDerived__SWIG_1(arg1) -} - -func NewKlass2ndDerived(a ...interface{}) Klass2ndDerived { - argc := len(a) - if argc == 0 { - return NewKlass2ndDerived__SWIG_0() - } - if argc == 1 { - return NewKlass2ndDerived__SWIG_1(a[0].(string)) - } - panic("No match for overloaded function call") -} - -var _wrap_delete_Klass2ndDerived unsafe.Pointer - -func _swig_wrap_delete_Klass2ndDerived(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Klass2ndDerived, _swig_p) - return -} - -func DeleteKlass2ndDerived(arg1 Klass2ndDerived) { - _swig_wrap_delete_Klass2ndDerived(arg1.Swigcptr()) -} - -var _wrap_Klass2ndDerived_getValue unsafe.Pointer - -func _swig_wrap_Klass2ndDerived_getValue(base SwigcptrKlass2ndDerived) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Klass2ndDerived_getValue, _swig_p) - return -} - -func (_swig_base SwigcptrKlass2ndDerived) GetValue() (_swig_ret string) { - return _swig_wrap_Klass2ndDerived_getValue(_swig_base) -} - -var _wrap_Klass2ndDerived_append unsafe.Pointer - -func _swig_wrap_Klass2ndDerived_append(base SwigcptrKlass2ndDerived, _ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Klass2ndDerived_append, _swig_p) - return -} - -func (_swig_base SwigcptrKlass2ndDerived) Append(arg1 string) { - _swig_wrap_Klass2ndDerived_append(_swig_base, arg1) -} - -var _wrap_Klass2ndDerived_getTotal_count unsafe.Pointer - -func Klass2ndDerivedGetTotal_count() (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_Klass2ndDerived_getTotal_count, _swig_p) - return -} -func (p SwigcptrKlass2ndDerived) SwigIsKlass() { -} - -func (p SwigcptrKlass2ndDerived) SwigGetKlass() Klass { - return SwigcptrKlass(p.Swigcptr()) -} - -type Klass2ndDerived interface { - Swigcptr() uintptr - SwigIsKlass2ndDerived() - GetValue() (_swig_ret string) - Append(arg1 string) - SwigIsKlass() - SwigGetKlass() Klass -} - -type SwigcptrKlass3rdDerived uintptr - -func (p SwigcptrKlass3rdDerived) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrKlass3rdDerived) SwigIsKlass3rdDerived() { -} - -var _wrap_new_Klass3rdDerived__SWIG_0 unsafe.Pointer - -func _swig_wrap_new_Klass3rdDerived__SWIG_0() (base SwigcptrKlass3rdDerived) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Klass3rdDerived__SWIG_0, _swig_p) - return -} - -func NewKlass3rdDerived__SWIG_0() (_swig_ret Klass3rdDerived) { - return _swig_wrap_new_Klass3rdDerived__SWIG_0() -} - -var _wrap_new_Klass3rdDerived__SWIG_1 unsafe.Pointer - -func _swig_wrap_new_Klass3rdDerived__SWIG_1(base string) (_ SwigcptrKlass3rdDerived) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Klass3rdDerived__SWIG_1, _swig_p) - return -} - -func NewKlass3rdDerived__SWIG_1(arg1 string) (_swig_ret Klass3rdDerived) { - return _swig_wrap_new_Klass3rdDerived__SWIG_1(arg1) -} - -func NewKlass3rdDerived(a ...interface{}) Klass3rdDerived { - argc := len(a) - if argc == 0 { - return NewKlass3rdDerived__SWIG_0() - } - if argc == 1 { - return NewKlass3rdDerived__SWIG_1(a[0].(string)) - } - panic("No match for overloaded function call") -} - -var _wrap_delete_Klass3rdDerived unsafe.Pointer - -func _swig_wrap_delete_Klass3rdDerived(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Klass3rdDerived, _swig_p) - return -} - -func DeleteKlass3rdDerived(arg1 Klass3rdDerived) { - _swig_wrap_delete_Klass3rdDerived(arg1.Swigcptr()) -} - -var _wrap_Klass3rdDerived_getValue unsafe.Pointer - -func _swig_wrap_Klass3rdDerived_getValue(base SwigcptrKlass3rdDerived) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Klass3rdDerived_getValue, _swig_p) - return -} - -func (arg1 SwigcptrKlass3rdDerived) GetValue() (_swig_ret string) { - return _swig_wrap_Klass3rdDerived_getValue(arg1) -} - -var _wrap_Klass3rdDerived_append unsafe.Pointer - -func _swig_wrap_Klass3rdDerived_append(base SwigcptrKlass3rdDerived, _ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Klass3rdDerived_append, _swig_p) - return -} - -func (_swig_base SwigcptrKlass3rdDerived) Append(arg1 string) { - _swig_wrap_Klass3rdDerived_append(_swig_base, arg1) -} - -var _wrap_Klass3rdDerived_getTotal_count unsafe.Pointer - -func Klass3rdDerivedGetTotal_count() (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_Klass3rdDerived_getTotal_count, _swig_p) - return -} -var _wrap_Klass3rdDerived_SwigGetKlass2ndDerived unsafe.Pointer - -func _swig_wrap_Klass3rdDerived_SwigGetKlass2ndDerived(base SwigcptrKlass3rdDerived) (_ SwigcptrKlass2ndDerived) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Klass3rdDerived_SwigGetKlass2ndDerived, _swig_p) - return -} - -func (arg1 SwigcptrKlass3rdDerived) SwigGetKlass2ndDerived() (_swig_ret Klass2ndDerived) { - return _swig_wrap_Klass3rdDerived_SwigGetKlass2ndDerived(arg1) -} - -func (p SwigcptrKlass3rdDerived) SwigGetKlass() Klass { - return p.SwigGetKlass2ndDerived().SwigGetKlass() -} - -type Klass3rdDerived interface { - Swigcptr() uintptr - SwigIsKlass3rdDerived() - GetValue() (_swig_ret string) - Append(arg1 string) - SwigGetKlass2ndDerived() (_swig_ret Klass2ndDerived) - SwigGetKlass() Klass -} - -var _wrap_test3rdupcast unsafe.Pointer - -func _swig_wrap_test3rdupcast(base uintptr) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_test3rdupcast, _swig_p) - return -} - -func Test3rdupcast(arg1 SwigBoost_shared_ptr_Sl_Space_Klass_Sg_) (_swig_ret string) { - return _swig_wrap_test3rdupcast(arg1.Swigcptr()) -} - -var _wrap_factorycreate unsafe.Pointer - -func _swig_wrap_factorycreate() (base SwigcptrSwigBoost_shared_ptr_Sl_Space_Klass_Sg_) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_factorycreate, _swig_p) - return -} - -func Factorycreate() (_swig_ret SwigBoost_shared_ptr_Sl_Space_Klass_Sg_) { - return _swig_wrap_factorycreate() -} - -var _wrap_smartpointertest unsafe.Pointer - -func _swig_wrap_smartpointertest(base uintptr) (_ SwigcptrSwigBoost_shared_ptr_Sl_Space_Klass_Sg_) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_smartpointertest, _swig_p) - return -} - -func Smartpointertest(arg1 SwigBoost_shared_ptr_Sl_Space_Klass_Sg_) (_swig_ret SwigBoost_shared_ptr_Sl_Space_Klass_Sg_) { - return _swig_wrap_smartpointertest(arg1.Swigcptr()) -} - -var _wrap_smartpointerpointertest unsafe.Pointer - -func _swig_wrap_smartpointerpointertest(base uintptr) (_ SwigcptrSwigBoost_shared_ptr_Sl_Space_Klass_Sg_) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_smartpointerpointertest, _swig_p) - return -} - -func Smartpointerpointertest(arg1 SwigBoost_shared_ptr_Sl_Space_Klass_Sg_) (_swig_ret SwigBoost_shared_ptr_Sl_Space_Klass_Sg_) { - return _swig_wrap_smartpointerpointertest(arg1.Swigcptr()) -} - -var _wrap_smartpointerreftest unsafe.Pointer - -func _swig_wrap_smartpointerreftest(base uintptr) (_ SwigcptrSwigBoost_shared_ptr_Sl_Space_Klass_Sg_) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_smartpointerreftest, _swig_p) - return -} - -func Smartpointerreftest(arg1 SwigBoost_shared_ptr_Sl_Space_Klass_Sg_) (_swig_ret SwigBoost_shared_ptr_Sl_Space_Klass_Sg_) { - return _swig_wrap_smartpointerreftest(arg1.Swigcptr()) -} - -var _wrap_smartpointerpointerreftest unsafe.Pointer - -func _swig_wrap_smartpointerpointerreftest(base uintptr) (_ SwigcptrSwigBoost_shared_ptr_Sl_Space_Klass_Sg_) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_smartpointerpointerreftest, _swig_p) - return -} - -func Smartpointerpointerreftest(arg1 SwigBoost_shared_ptr_Sl_Space_Klass_Sg_) (_swig_ret SwigBoost_shared_ptr_Sl_Space_Klass_Sg_) { - return _swig_wrap_smartpointerpointerreftest(arg1.Swigcptr()) -} - -var _wrap_constsmartpointertest unsafe.Pointer - -func _swig_wrap_constsmartpointertest(base uintptr) (_ SwigcptrSwigBoost_shared_ptr_Sl_Space_Klass_SS_const_Sg_) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_constsmartpointertest, _swig_p) - return -} - -func Constsmartpointertest(arg1 SwigBoost_shared_ptr_Sl_Space_Klass_SS_const_Sg_) (_swig_ret SwigBoost_shared_ptr_Sl_Space_Klass_SS_const_Sg_) { - return _swig_wrap_constsmartpointertest(arg1.Swigcptr()) -} - -var _wrap_constsmartpointerpointertest unsafe.Pointer - -func _swig_wrap_constsmartpointerpointertest(base uintptr) (_ SwigcptrSwigBoost_shared_ptr_Sl_Space_Klass_SS_const_Sg_) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_constsmartpointerpointertest, _swig_p) - return -} - -func Constsmartpointerpointertest(arg1 SwigBoost_shared_ptr_Sl_Space_Klass_SS_const_Sg_) (_swig_ret SwigBoost_shared_ptr_Sl_Space_Klass_SS_const_Sg_) { - return _swig_wrap_constsmartpointerpointertest(arg1.Swigcptr()) -} - -var _wrap_constsmartpointerreftest unsafe.Pointer - -func _swig_wrap_constsmartpointerreftest(base uintptr) (_ SwigcptrSwigBoost_shared_ptr_Sl_Space_Klass_SS_const_Sg_) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_constsmartpointerreftest, _swig_p) - return -} - -func Constsmartpointerreftest(arg1 SwigBoost_shared_ptr_Sl_Space_Klass_SS_const_Sg_) (_swig_ret SwigBoost_shared_ptr_Sl_Space_Klass_SS_const_Sg_) { - return _swig_wrap_constsmartpointerreftest(arg1.Swigcptr()) -} - -var _wrap_valuetest unsafe.Pointer - -func _swig_wrap_valuetest(base uintptr) (_ SwigcptrKlass) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_valuetest, _swig_p) - return -} - -func Valuetest(arg1 Klass) (_swig_ret Klass) { - return _swig_wrap_valuetest(arg1.Swigcptr()) -} - -var _wrap_pointertest unsafe.Pointer - -func _swig_wrap_pointertest(base uintptr) (_ SwigcptrKlass) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_pointertest, _swig_p) - return -} - -func Pointertest(arg1 Klass) (_swig_ret Klass) { - return _swig_wrap_pointertest(arg1.Swigcptr()) -} - -var _wrap_reftest unsafe.Pointer - -func _swig_wrap_reftest(base uintptr) (_ SwigcptrKlass) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_reftest, _swig_p) - return -} - -func Reftest(arg1 Klass) (_swig_ret Klass) { - return _swig_wrap_reftest(arg1.Swigcptr()) -} - -var _wrap_pointerreftest unsafe.Pointer - -func _swig_wrap_pointerreftest(base uintptr) (_ SwigcptrKlass) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_pointerreftest, _swig_p) - return -} - -func Pointerreftest(arg1 Klass) (_swig_ret Klass) { - return _swig_wrap_pointerreftest(arg1.Swigcptr()) -} - -var _wrap_nullsmartpointerpointertest unsafe.Pointer - -func _swig_wrap_nullsmartpointerpointertest(base uintptr) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_nullsmartpointerpointertest, _swig_p) - return -} - -func Nullsmartpointerpointertest(arg1 SwigBoost_shared_ptr_Sl_Space_Klass_Sg_) (_swig_ret string) { - return _swig_wrap_nullsmartpointerpointertest(arg1.Swigcptr()) -} - -var _wrap_pointerownertest unsafe.Pointer - -func _swig_wrap_pointerownertest() (base SwigcptrKlass) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_pointerownertest, _swig_p) - return -} - -func Pointerownertest() (_swig_ret Klass) { - return _swig_wrap_pointerownertest() -} - -var _wrap_smartpointerpointerownertest unsafe.Pointer - -func _swig_wrap_smartpointerpointerownertest() (base SwigcptrSwigBoost_shared_ptr_Sl_Space_Klass_Sg_) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_smartpointerpointerownertest, _swig_p) - return -} - -func Smartpointerpointerownertest() (_swig_ret SwigBoost_shared_ptr_Sl_Space_Klass_Sg_) { - return _swig_wrap_smartpointerpointerownertest() -} - -var _wrap_use_count__SWIG_0 unsafe.Pointer - -func _swig_wrap_use_count__SWIG_0(base uintptr) (_ int64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_use_count__SWIG_0, _swig_p) - return -} - -func Use_count__SWIG_0(arg1 SwigBoost_shared_ptr_Sl_Space_Klass3rdDerived_Sg_) (_swig_ret int64) { - return _swig_wrap_use_count__SWIG_0(arg1.Swigcptr()) -} - -var _wrap_use_count__SWIG_1 unsafe.Pointer - -func _swig_wrap_use_count__SWIG_1(base uintptr) (_ int64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_use_count__SWIG_1, _swig_p) - return -} - -func Use_count__SWIG_1(arg1 SwigBoost_shared_ptr_Sl_Space_Klass2ndDerived_Sg_) (_swig_ret int64) { - return _swig_wrap_use_count__SWIG_1(arg1.Swigcptr()) -} - -var _wrap_use_count__SWIG_2 unsafe.Pointer - -func _swig_wrap_use_count__SWIG_2(base uintptr) (_ int64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_use_count__SWIG_2, _swig_p) - return -} - -func Use_count__SWIG_2(arg1 SwigBoost_shared_ptr_Sl_Space_KlassDerived_Sg_) (_swig_ret int64) { - return _swig_wrap_use_count__SWIG_2(arg1.Swigcptr()) -} - -var _wrap_use_count__SWIG_3 unsafe.Pointer - -func _swig_wrap_use_count__SWIG_3(base uintptr) (_ int64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_use_count__SWIG_3, _swig_p) - return -} - -func Use_count__SWIG_3(arg1 SwigBoost_shared_ptr_Sl_Space_Klass_Sg_) (_swig_ret int64) { - return _swig_wrap_use_count__SWIG_3(arg1.Swigcptr()) -} - -func Use_count(a ...interface{}) int64 { - argc := len(a) - if argc == 1 { - if _, ok := a[0].(SwigBoost_shared_ptr_Sl_Space_Klass3rdDerived_Sg_); !ok { - goto check_1 - } - return Use_count__SWIG_0(a[0].(SwigBoost_shared_ptr_Sl_Space_Klass3rdDerived_Sg_)) - } -check_1: - if argc == 1 { - if _, ok := a[0].(SwigBoost_shared_ptr_Sl_Space_Klass2ndDerived_Sg_); !ok { - goto check_2 - } - return Use_count__SWIG_1(a[0].(SwigBoost_shared_ptr_Sl_Space_Klass2ndDerived_Sg_)) - } -check_2: - if argc == 1 { - if _, ok := a[0].(SwigBoost_shared_ptr_Sl_Space_KlassDerived_Sg_); !ok { - goto check_3 - } - return Use_count__SWIG_2(a[0].(SwigBoost_shared_ptr_Sl_Space_KlassDerived_Sg_)) - } -check_3: - if argc == 1 { - return Use_count__SWIG_3(a[0].(SwigBoost_shared_ptr_Sl_Space_Klass_Sg_)) - } - panic("No match for overloaded function call") -} - -var _wrap_ref_1 unsafe.Pointer - -func _swig_wrap_ref_1() (base SwigcptrSwigBoost_shared_ptr_Sl_Space_Klass_Sg_) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_ref_1, _swig_p) - return -} - -func Ref_1() (_swig_ret SwigBoost_shared_ptr_Sl_Space_Klass_Sg_) { - return _swig_wrap_ref_1() -} - -var _wrap_overload_rawbyval__SWIG_0 unsafe.Pointer - -func Overload_rawbyval__SWIG_0(arg1 int) (_swig_ret string) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_overload_rawbyval__SWIG_0, _swig_p) - return -} -var _wrap_overload_rawbyval__SWIG_1 unsafe.Pointer - -func _swig_wrap_overload_rawbyval__SWIG_1(base uintptr) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_overload_rawbyval__SWIG_1, _swig_p) - return -} - -func Overload_rawbyval__SWIG_1(arg1 Klass) (_swig_ret string) { - return _swig_wrap_overload_rawbyval__SWIG_1(arg1.Swigcptr()) -} - -func Overload_rawbyval(a ...interface{}) string { - argc := len(a) - if argc == 1 { - if _, ok := a[0].(Klass); !ok { - goto check_1 - } - return Overload_rawbyval__SWIG_1(a[0].(Klass)) - } -check_1: - if argc == 1 { - return Overload_rawbyval__SWIG_0(a[0].(int)) - } - panic("No match for overloaded function call") -} - -var _wrap_overload_rawbyref__SWIG_0 unsafe.Pointer - -func Overload_rawbyref__SWIG_0(arg1 int) (_swig_ret string) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_overload_rawbyref__SWIG_0, _swig_p) - return -} -var _wrap_overload_rawbyref__SWIG_1 unsafe.Pointer - -func _swig_wrap_overload_rawbyref__SWIG_1(base uintptr) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_overload_rawbyref__SWIG_1, _swig_p) - return -} - -func Overload_rawbyref__SWIG_1(arg1 Klass) (_swig_ret string) { - return _swig_wrap_overload_rawbyref__SWIG_1(arg1.Swigcptr()) -} - -func Overload_rawbyref(a ...interface{}) string { - argc := len(a) - if argc == 1 { - if _, ok := a[0].(Klass); !ok { - goto check_1 - } - return Overload_rawbyref__SWIG_1(a[0].(Klass)) - } -check_1: - if argc == 1 { - return Overload_rawbyref__SWIG_0(a[0].(int)) - } - panic("No match for overloaded function call") -} - -var _wrap_overload_rawbyptr__SWIG_0 unsafe.Pointer - -func Overload_rawbyptr__SWIG_0(arg1 int) (_swig_ret string) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_overload_rawbyptr__SWIG_0, _swig_p) - return -} -var _wrap_overload_rawbyptr__SWIG_1 unsafe.Pointer - -func _swig_wrap_overload_rawbyptr__SWIG_1(base uintptr) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_overload_rawbyptr__SWIG_1, _swig_p) - return -} - -func Overload_rawbyptr__SWIG_1(arg1 Klass) (_swig_ret string) { - return _swig_wrap_overload_rawbyptr__SWIG_1(arg1.Swigcptr()) -} - -func Overload_rawbyptr(a ...interface{}) string { - argc := len(a) - if argc == 1 { - if _, ok := a[0].(Klass); !ok { - goto check_1 - } - return Overload_rawbyptr__SWIG_1(a[0].(Klass)) - } -check_1: - if argc == 1 { - return Overload_rawbyptr__SWIG_0(a[0].(int)) - } - panic("No match for overloaded function call") -} - -var _wrap_overload_rawbyptrref__SWIG_0 unsafe.Pointer - -func Overload_rawbyptrref__SWIG_0(arg1 int) (_swig_ret string) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_overload_rawbyptrref__SWIG_0, _swig_p) - return -} -var _wrap_overload_rawbyptrref__SWIG_1 unsafe.Pointer - -func _swig_wrap_overload_rawbyptrref__SWIG_1(base uintptr) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_overload_rawbyptrref__SWIG_1, _swig_p) - return -} - -func Overload_rawbyptrref__SWIG_1(arg1 Klass) (_swig_ret string) { - return _swig_wrap_overload_rawbyptrref__SWIG_1(arg1.Swigcptr()) -} - -func Overload_rawbyptrref(a ...interface{}) string { - argc := len(a) - if argc == 1 { - if _, ok := a[0].(Klass); !ok { - goto check_1 - } - return Overload_rawbyptrref__SWIG_1(a[0].(Klass)) - } -check_1: - if argc == 1 { - return Overload_rawbyptrref__SWIG_0(a[0].(int)) - } - panic("No match for overloaded function call") -} - -var _wrap_overload_smartbyval__SWIG_0 unsafe.Pointer - -func Overload_smartbyval__SWIG_0(arg1 int) (_swig_ret string) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_overload_smartbyval__SWIG_0, _swig_p) - return -} -var _wrap_overload_smartbyval__SWIG_1 unsafe.Pointer - -func _swig_wrap_overload_smartbyval__SWIG_1(base uintptr) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_overload_smartbyval__SWIG_1, _swig_p) - return -} - -func Overload_smartbyval__SWIG_1(arg1 SwigBoost_shared_ptr_Sl_Space_Klass_Sg_) (_swig_ret string) { - return _swig_wrap_overload_smartbyval__SWIG_1(arg1.Swigcptr()) -} - -func Overload_smartbyval(a ...interface{}) string { - argc := len(a) - if argc == 1 { - if _, ok := a[0].(SwigBoost_shared_ptr_Sl_Space_Klass_Sg_); !ok { - goto check_1 - } - return Overload_smartbyval__SWIG_1(a[0].(SwigBoost_shared_ptr_Sl_Space_Klass_Sg_)) - } -check_1: - if argc == 1 { - return Overload_smartbyval__SWIG_0(a[0].(int)) - } - panic("No match for overloaded function call") -} - -var _wrap_overload_smartbyref__SWIG_0 unsafe.Pointer - -func Overload_smartbyref__SWIG_0(arg1 int) (_swig_ret string) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_overload_smartbyref__SWIG_0, _swig_p) - return -} -var _wrap_overload_smartbyref__SWIG_1 unsafe.Pointer - -func _swig_wrap_overload_smartbyref__SWIG_1(base uintptr) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_overload_smartbyref__SWIG_1, _swig_p) - return -} - -func Overload_smartbyref__SWIG_1(arg1 SwigBoost_shared_ptr_Sl_Space_Klass_Sg_) (_swig_ret string) { - return _swig_wrap_overload_smartbyref__SWIG_1(arg1.Swigcptr()) -} - -func Overload_smartbyref(a ...interface{}) string { - argc := len(a) - if argc == 1 { - if _, ok := a[0].(SwigBoost_shared_ptr_Sl_Space_Klass_Sg_); !ok { - goto check_1 - } - return Overload_smartbyref__SWIG_1(a[0].(SwigBoost_shared_ptr_Sl_Space_Klass_Sg_)) - } -check_1: - if argc == 1 { - return Overload_smartbyref__SWIG_0(a[0].(int)) - } - panic("No match for overloaded function call") -} - -var _wrap_overload_smartbyptr__SWIG_0 unsafe.Pointer - -func Overload_smartbyptr__SWIG_0(arg1 int) (_swig_ret string) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_overload_smartbyptr__SWIG_0, _swig_p) - return -} -var _wrap_overload_smartbyptr__SWIG_1 unsafe.Pointer - -func _swig_wrap_overload_smartbyptr__SWIG_1(base uintptr) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_overload_smartbyptr__SWIG_1, _swig_p) - return -} - -func Overload_smartbyptr__SWIG_1(arg1 SwigBoost_shared_ptr_Sl_Space_Klass_Sg_) (_swig_ret string) { - return _swig_wrap_overload_smartbyptr__SWIG_1(arg1.Swigcptr()) -} - -func Overload_smartbyptr(a ...interface{}) string { - argc := len(a) - if argc == 1 { - if _, ok := a[0].(SwigBoost_shared_ptr_Sl_Space_Klass_Sg_); !ok { - goto check_1 - } - return Overload_smartbyptr__SWIG_1(a[0].(SwigBoost_shared_ptr_Sl_Space_Klass_Sg_)) - } -check_1: - if argc == 1 { - return Overload_smartbyptr__SWIG_0(a[0].(int)) - } - panic("No match for overloaded function call") -} - -var _wrap_overload_smartbyptrref__SWIG_0 unsafe.Pointer - -func Overload_smartbyptrref__SWIG_0(arg1 int) (_swig_ret string) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_overload_smartbyptrref__SWIG_0, _swig_p) - return -} -var _wrap_overload_smartbyptrref__SWIG_1 unsafe.Pointer - -func _swig_wrap_overload_smartbyptrref__SWIG_1(base uintptr) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_overload_smartbyptrref__SWIG_1, _swig_p) - return -} - -func Overload_smartbyptrref__SWIG_1(arg1 SwigBoost_shared_ptr_Sl_Space_Klass_Sg_) (_swig_ret string) { - return _swig_wrap_overload_smartbyptrref__SWIG_1(arg1.Swigcptr()) -} - -func Overload_smartbyptrref(a ...interface{}) string { - argc := len(a) - if argc == 1 { - if _, ok := a[0].(SwigBoost_shared_ptr_Sl_Space_Klass_Sg_); !ok { - goto check_1 - } - return Overload_smartbyptrref__SWIG_1(a[0].(SwigBoost_shared_ptr_Sl_Space_Klass_Sg_)) - } -check_1: - if argc == 1 { - return Overload_smartbyptrref__SWIG_0(a[0].(int)) - } - panic("No match for overloaded function call") -} - -type SwigcptrMemberVariables uintptr - -func (p SwigcptrMemberVariables) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrMemberVariables) SwigIsMemberVariables() { -} - -var _wrap_new_MemberVariables unsafe.Pointer - -func _swig_wrap_new_MemberVariables() (base SwigcptrMemberVariables) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_MemberVariables, _swig_p) - return -} - -func NewMemberVariables() (_swig_ret MemberVariables) { - return _swig_wrap_new_MemberVariables() -} - -var _wrap_MemberVariables_SmartMemberValue_set unsafe.Pointer - -func _swig_wrap_MemberVariables_SmartMemberValue_set(base SwigcptrMemberVariables, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_MemberVariables_SmartMemberValue_set, _swig_p) - return -} - -func (arg1 SwigcptrMemberVariables) SetSmartMemberValue(arg2 SwigBoost_shared_ptr_Sl_Space_Klass_Sg_) { - _swig_wrap_MemberVariables_SmartMemberValue_set(arg1, arg2.Swigcptr()) -} - -var _wrap_MemberVariables_SmartMemberValue_get unsafe.Pointer - -func _swig_wrap_MemberVariables_SmartMemberValue_get(base SwigcptrMemberVariables) (_ SwigcptrSwigBoost_shared_ptr_Sl_Space_Klass_Sg_) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_MemberVariables_SmartMemberValue_get, _swig_p) - return -} - -func (arg1 SwigcptrMemberVariables) GetSmartMemberValue() (_swig_ret SwigBoost_shared_ptr_Sl_Space_Klass_Sg_) { - return _swig_wrap_MemberVariables_SmartMemberValue_get(arg1) -} - -var _wrap_MemberVariables_SmartMemberPointer_set unsafe.Pointer - -func _swig_wrap_MemberVariables_SmartMemberPointer_set(base SwigcptrMemberVariables, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_MemberVariables_SmartMemberPointer_set, _swig_p) - return -} - -func (arg1 SwigcptrMemberVariables) SetSmartMemberPointer(arg2 SwigBoost_shared_ptr_Sl_Space_Klass_Sg_) { - _swig_wrap_MemberVariables_SmartMemberPointer_set(arg1, arg2.Swigcptr()) -} - -var _wrap_MemberVariables_SmartMemberPointer_get unsafe.Pointer - -func _swig_wrap_MemberVariables_SmartMemberPointer_get(base SwigcptrMemberVariables) (_ SwigcptrSwigBoost_shared_ptr_Sl_Space_Klass_Sg_) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_MemberVariables_SmartMemberPointer_get, _swig_p) - return -} - -func (arg1 SwigcptrMemberVariables) GetSmartMemberPointer() (_swig_ret SwigBoost_shared_ptr_Sl_Space_Klass_Sg_) { - return _swig_wrap_MemberVariables_SmartMemberPointer_get(arg1) -} - -var _wrap_MemberVariables_SmartMemberReference_set unsafe.Pointer - -func _swig_wrap_MemberVariables_SmartMemberReference_set(base SwigcptrMemberVariables, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_MemberVariables_SmartMemberReference_set, _swig_p) - return -} - -func (arg1 SwigcptrMemberVariables) SetSmartMemberReference(arg2 SwigBoost_shared_ptr_Sl_Space_Klass_Sg_) { - _swig_wrap_MemberVariables_SmartMemberReference_set(arg1, arg2.Swigcptr()) -} - -var _wrap_MemberVariables_SmartMemberReference_get unsafe.Pointer - -func _swig_wrap_MemberVariables_SmartMemberReference_get(base SwigcptrMemberVariables) (_ SwigcptrSwigBoost_shared_ptr_Sl_Space_Klass_Sg_) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_MemberVariables_SmartMemberReference_get, _swig_p) - return -} - -func (arg1 SwigcptrMemberVariables) GetSmartMemberReference() (_swig_ret SwigBoost_shared_ptr_Sl_Space_Klass_Sg_) { - return _swig_wrap_MemberVariables_SmartMemberReference_get(arg1) -} - -var _wrap_MemberVariables_MemberValue_set unsafe.Pointer - -func _swig_wrap_MemberVariables_MemberValue_set(base SwigcptrMemberVariables, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_MemberVariables_MemberValue_set, _swig_p) - return -} - -func (arg1 SwigcptrMemberVariables) SetMemberValue(arg2 Klass) { - _swig_wrap_MemberVariables_MemberValue_set(arg1, arg2.Swigcptr()) -} - -var _wrap_MemberVariables_MemberValue_get unsafe.Pointer - -func _swig_wrap_MemberVariables_MemberValue_get(base SwigcptrMemberVariables) (_ SwigcptrKlass) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_MemberVariables_MemberValue_get, _swig_p) - return -} - -func (arg1 SwigcptrMemberVariables) GetMemberValue() (_swig_ret Klass) { - return _swig_wrap_MemberVariables_MemberValue_get(arg1) -} - -var _wrap_MemberVariables_MemberPointer_set unsafe.Pointer - -func _swig_wrap_MemberVariables_MemberPointer_set(base SwigcptrMemberVariables, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_MemberVariables_MemberPointer_set, _swig_p) - return -} - -func (arg1 SwigcptrMemberVariables) SetMemberPointer(arg2 Klass) { - _swig_wrap_MemberVariables_MemberPointer_set(arg1, arg2.Swigcptr()) -} - -var _wrap_MemberVariables_MemberPointer_get unsafe.Pointer - -func _swig_wrap_MemberVariables_MemberPointer_get(base SwigcptrMemberVariables) (_ SwigcptrKlass) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_MemberVariables_MemberPointer_get, _swig_p) - return -} - -func (arg1 SwigcptrMemberVariables) GetMemberPointer() (_swig_ret Klass) { - return _swig_wrap_MemberVariables_MemberPointer_get(arg1) -} - -var _wrap_MemberVariables_MemberReference_set unsafe.Pointer - -func _swig_wrap_MemberVariables_MemberReference_set(base SwigcptrMemberVariables, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_MemberVariables_MemberReference_set, _swig_p) - return -} - -func (arg1 SwigcptrMemberVariables) SetMemberReference(arg2 Klass) { - _swig_wrap_MemberVariables_MemberReference_set(arg1, arg2.Swigcptr()) -} - -var _wrap_MemberVariables_MemberReference_get unsafe.Pointer - -func _swig_wrap_MemberVariables_MemberReference_get(base SwigcptrMemberVariables) (_ SwigcptrKlass) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_MemberVariables_MemberReference_get, _swig_p) - return -} - -func (arg1 SwigcptrMemberVariables) GetMemberReference() (_swig_ret Klass) { - return _swig_wrap_MemberVariables_MemberReference_get(arg1) -} - -var _wrap_delete_MemberVariables unsafe.Pointer - -func _swig_wrap_delete_MemberVariables(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_MemberVariables, _swig_p) - return -} - -func DeleteMemberVariables(arg1 MemberVariables) { - _swig_wrap_delete_MemberVariables(arg1.Swigcptr()) -} - -type MemberVariables interface { - Swigcptr() uintptr - SwigIsMemberVariables() - SetSmartMemberValue(arg2 SwigBoost_shared_ptr_Sl_Space_Klass_Sg_) - GetSmartMemberValue() (_swig_ret SwigBoost_shared_ptr_Sl_Space_Klass_Sg_) - SetSmartMemberPointer(arg2 SwigBoost_shared_ptr_Sl_Space_Klass_Sg_) - GetSmartMemberPointer() (_swig_ret SwigBoost_shared_ptr_Sl_Space_Klass_Sg_) - SetSmartMemberReference(arg2 SwigBoost_shared_ptr_Sl_Space_Klass_Sg_) - GetSmartMemberReference() (_swig_ret SwigBoost_shared_ptr_Sl_Space_Klass_Sg_) - SetMemberValue(arg2 Klass) - GetMemberValue() (_swig_ret Klass) - SetMemberPointer(arg2 Klass) - GetMemberPointer() (_swig_ret Klass) - SetMemberReference(arg2 Klass) - GetMemberReference() (_swig_ret Klass) -} - -var _wrap_GlobalSmartValue_set unsafe.Pointer - -func _swig_wrap_GlobalSmartValue_set(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_GlobalSmartValue_set, _swig_p) - return -} - -func SetGlobalSmartValue(arg1 SwigBoost_shared_ptr_Sl_Space_Klass_Sg_) { - _swig_wrap_GlobalSmartValue_set(arg1.Swigcptr()) -} - -var _wrap_GlobalSmartValue_get unsafe.Pointer - -func _swig_wrap_GlobalSmartValue_get() (base SwigcptrSwigBoost_shared_ptr_Sl_Space_Klass_Sg_) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_GlobalSmartValue_get, _swig_p) - return -} - -func GetGlobalSmartValue() (_swig_ret SwigBoost_shared_ptr_Sl_Space_Klass_Sg_) { - return _swig_wrap_GlobalSmartValue_get() -} - -var _wrap_GlobalValue_set unsafe.Pointer - -func _swig_wrap_GlobalValue_set(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_GlobalValue_set, _swig_p) - return -} - -func SetGlobalValue(arg1 Klass) { - _swig_wrap_GlobalValue_set(arg1.Swigcptr()) -} - -var _wrap_GlobalValue_get unsafe.Pointer - -func _swig_wrap_GlobalValue_get() (base SwigcptrKlass) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_GlobalValue_get, _swig_p) - return -} - -func GetGlobalValue() (_swig_ret Klass) { - return _swig_wrap_GlobalValue_get() -} - -var _wrap_GlobalPointer_set unsafe.Pointer - -func _swig_wrap_GlobalPointer_set(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_GlobalPointer_set, _swig_p) - return -} - -func SetGlobalPointer(arg1 Klass) { - _swig_wrap_GlobalPointer_set(arg1.Swigcptr()) -} - -var _wrap_GlobalPointer_get unsafe.Pointer - -func _swig_wrap_GlobalPointer_get() (base SwigcptrKlass) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_GlobalPointer_get, _swig_p) - return -} - -func GetGlobalPointer() (_swig_ret Klass) { - return _swig_wrap_GlobalPointer_get() -} - -var _wrap_GlobalReference_set unsafe.Pointer - -func _swig_wrap_GlobalReference_set(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_GlobalReference_set, _swig_p) - return -} - -func SetGlobalReference(arg1 Klass) { - _swig_wrap_GlobalReference_set(arg1.Swigcptr()) -} - -var _wrap_GlobalReference_get unsafe.Pointer - -func _swig_wrap_GlobalReference_get() (base SwigcptrKlass) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_GlobalReference_get, _swig_p) - return -} - -func GetGlobalReference() (_swig_ret Klass) { - return _swig_wrap_GlobalReference_get() -} - -type SwigcptrBaseIntDouble uintptr - -func (p SwigcptrBaseIntDouble) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrBaseIntDouble) SwigIsBaseIntDouble() { -} - -var _wrap_BaseIntDouble_klassBase_set unsafe.Pointer - -func _swig_wrap_BaseIntDouble_klassBase_set(base SwigcptrBaseIntDouble, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_BaseIntDouble_klassBase_set, _swig_p) - return -} - -func (arg1 SwigcptrBaseIntDouble) SetKlassBase(arg2 Klass) { - _swig_wrap_BaseIntDouble_klassBase_set(arg1, arg2.Swigcptr()) -} - -var _wrap_BaseIntDouble_klassBase_get unsafe.Pointer - -func _swig_wrap_BaseIntDouble_klassBase_get(base SwigcptrBaseIntDouble) (_ SwigcptrKlass) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_BaseIntDouble_klassBase_get, _swig_p) - return -} - -func (arg1 SwigcptrBaseIntDouble) GetKlassBase() (_swig_ret Klass) { - return _swig_wrap_BaseIntDouble_klassBase_get(arg1) -} - -var _wrap_BaseIntDouble_baseVal1_set unsafe.Pointer - -func _swig_wrap_BaseIntDouble_baseVal1_set(base SwigcptrBaseIntDouble, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_BaseIntDouble_baseVal1_set, _swig_p) - return -} - -func (arg1 SwigcptrBaseIntDouble) SetBaseVal1(arg2 int) { - _swig_wrap_BaseIntDouble_baseVal1_set(arg1, arg2) -} - -var _wrap_BaseIntDouble_baseVal1_get unsafe.Pointer - -func _swig_wrap_BaseIntDouble_baseVal1_get(base SwigcptrBaseIntDouble) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_BaseIntDouble_baseVal1_get, _swig_p) - return -} - -func (arg1 SwigcptrBaseIntDouble) GetBaseVal1() (_swig_ret int) { - return _swig_wrap_BaseIntDouble_baseVal1_get(arg1) -} - -var _wrap_BaseIntDouble_baseVal2_set unsafe.Pointer - -func _swig_wrap_BaseIntDouble_baseVal2_set(base SwigcptrBaseIntDouble, _ float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_BaseIntDouble_baseVal2_set, _swig_p) - return -} - -func (arg1 SwigcptrBaseIntDouble) SetBaseVal2(arg2 float64) { - _swig_wrap_BaseIntDouble_baseVal2_set(arg1, arg2) -} - -var _wrap_BaseIntDouble_baseVal2_get unsafe.Pointer - -func _swig_wrap_BaseIntDouble_baseVal2_get(base SwigcptrBaseIntDouble) (_ float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_BaseIntDouble_baseVal2_get, _swig_p) - return -} - -func (arg1 SwigcptrBaseIntDouble) GetBaseVal2() (_swig_ret float64) { - return _swig_wrap_BaseIntDouble_baseVal2_get(arg1) -} - -var _wrap_new_BaseIntDouble unsafe.Pointer - -func _swig_wrap_new_BaseIntDouble(base int, _ float64) (_ SwigcptrBaseIntDouble) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_BaseIntDouble, _swig_p) - return -} - -func NewBaseIntDouble(arg1 int, arg2 float64) (_swig_ret BaseIntDouble) { - return _swig_wrap_new_BaseIntDouble(arg1, arg2) -} - -var _wrap_BaseIntDouble_getValue unsafe.Pointer - -func _swig_wrap_BaseIntDouble_getValue(base SwigcptrBaseIntDouble) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_BaseIntDouble_getValue, _swig_p) - return -} - -func (arg1 SwigcptrBaseIntDouble) GetValue() (_swig_ret string) { - return _swig_wrap_BaseIntDouble_getValue(arg1) -} - -var _wrap_delete_BaseIntDouble unsafe.Pointer - -func _swig_wrap_delete_BaseIntDouble(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_BaseIntDouble, _swig_p) - return -} - -func DeleteBaseIntDouble(arg1 BaseIntDouble) { - _swig_wrap_delete_BaseIntDouble(arg1.Swigcptr()) -} - -type BaseIntDouble interface { - Swigcptr() uintptr - SwigIsBaseIntDouble() - SetKlassBase(arg2 Klass) - GetKlassBase() (_swig_ret Klass) - SetBaseVal1(arg2 int) - GetBaseVal1() (_swig_ret int) - SetBaseVal2(arg2 float64) - GetBaseVal2() (_swig_ret float64) - GetValue() (_swig_ret string) -} - -var _wrap_pair_id2 unsafe.Pointer - -func _swig_wrap_pair_id2(base uintptr) (_ SwigcptrPairIntDouble) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_pair_id2, _swig_p) - return -} - -func Pair_id2(arg1 PairIntDouble) (_swig_ret PairIntDouble) { - return _swig_wrap_pair_id2(arg1.Swigcptr()) -} - -var _wrap_pair_id1 unsafe.Pointer - -func _swig_wrap_pair_id1(base uintptr) (_ SwigcptrSwigBoost_shared_ptr_Sl_Pair_Sl_int_Sc_double_Sg__Sg_) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_pair_id1, _swig_p) - return -} - -func Pair_id1(arg1 SwigBoost_shared_ptr_Sl_Pair_Sl_int_Sc_double_Sg__Sg_) (_swig_ret SwigBoost_shared_ptr_Sl_Pair_Sl_int_Sc_double_Sg__Sg_) { - return _swig_wrap_pair_id1(arg1.Swigcptr()) -} - -type SwigcptrPairIntDouble uintptr - -func (p SwigcptrPairIntDouble) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrPairIntDouble) SwigIsPairIntDouble() { -} - -var _wrap_PairIntDouble_klassPair_set unsafe.Pointer - -func _swig_wrap_PairIntDouble_klassPair_set(base SwigcptrPairIntDouble, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_PairIntDouble_klassPair_set, _swig_p) - return -} - -func (arg1 SwigcptrPairIntDouble) SetKlassPair(arg2 Klass) { - _swig_wrap_PairIntDouble_klassPair_set(arg1, arg2.Swigcptr()) -} - -var _wrap_PairIntDouble_klassPair_get unsafe.Pointer - -func _swig_wrap_PairIntDouble_klassPair_get(base SwigcptrPairIntDouble) (_ SwigcptrKlass) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_PairIntDouble_klassPair_get, _swig_p) - return -} - -func (arg1 SwigcptrPairIntDouble) GetKlassPair() (_swig_ret Klass) { - return _swig_wrap_PairIntDouble_klassPair_get(arg1) -} - -var _wrap_PairIntDouble_val1_set unsafe.Pointer - -func _swig_wrap_PairIntDouble_val1_set(base SwigcptrPairIntDouble, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_PairIntDouble_val1_set, _swig_p) - return -} - -func (arg1 SwigcptrPairIntDouble) SetVal1(arg2 int) { - _swig_wrap_PairIntDouble_val1_set(arg1, arg2) -} - -var _wrap_PairIntDouble_val1_get unsafe.Pointer - -func _swig_wrap_PairIntDouble_val1_get(base SwigcptrPairIntDouble) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_PairIntDouble_val1_get, _swig_p) - return -} - -func (arg1 SwigcptrPairIntDouble) GetVal1() (_swig_ret int) { - return _swig_wrap_PairIntDouble_val1_get(arg1) -} - -var _wrap_PairIntDouble_val2_set unsafe.Pointer - -func _swig_wrap_PairIntDouble_val2_set(base SwigcptrPairIntDouble, _ float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_PairIntDouble_val2_set, _swig_p) - return -} - -func (arg1 SwigcptrPairIntDouble) SetVal2(arg2 float64) { - _swig_wrap_PairIntDouble_val2_set(arg1, arg2) -} - -var _wrap_PairIntDouble_val2_get unsafe.Pointer - -func _swig_wrap_PairIntDouble_val2_get(base SwigcptrPairIntDouble) (_ float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_PairIntDouble_val2_get, _swig_p) - return -} - -func (arg1 SwigcptrPairIntDouble) GetVal2() (_swig_ret float64) { - return _swig_wrap_PairIntDouble_val2_get(arg1) -} - -var _wrap_new_PairIntDouble unsafe.Pointer - -func _swig_wrap_new_PairIntDouble(base int, _ float64) (_ SwigcptrPairIntDouble) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_PairIntDouble, _swig_p) - return -} - -func NewPairIntDouble(arg1 int, arg2 float64) (_swig_ret PairIntDouble) { - return _swig_wrap_new_PairIntDouble(arg1, arg2) -} - -var _wrap_PairIntDouble_getValue unsafe.Pointer - -func _swig_wrap_PairIntDouble_getValue(base SwigcptrPairIntDouble) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_PairIntDouble_getValue, _swig_p) - return -} - -func (arg1 SwigcptrPairIntDouble) GetValue() (_swig_ret string) { - return _swig_wrap_PairIntDouble_getValue(arg1) -} - -var _wrap_delete_PairIntDouble unsafe.Pointer - -func _swig_wrap_delete_PairIntDouble(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_PairIntDouble, _swig_p) - return -} - -func DeletePairIntDouble(arg1 PairIntDouble) { - _swig_wrap_delete_PairIntDouble(arg1.Swigcptr()) -} - -var _wrap_SetPairIntDouble_KlassBase unsafe.Pointer - -func _swig_wrap_SetPairIntDouble_KlassBase(base SwigcptrPairIntDouble, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_SetPairIntDouble_KlassBase, _swig_p) - return -} - -func (_swig_base SwigcptrPairIntDouble) SetKlassBase(arg1 Klass) { - _swig_wrap_SetPairIntDouble_KlassBase(_swig_base, arg1.Swigcptr()) -} - -var _wrap_GetPairIntDouble_KlassBase unsafe.Pointer - -func _swig_wrap_GetPairIntDouble_KlassBase(base SwigcptrPairIntDouble) (_ SwigcptrKlass) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_GetPairIntDouble_KlassBase, _swig_p) - return -} - -func (_swig_base SwigcptrPairIntDouble) GetKlassBase() (_swig_ret Klass) { - return _swig_wrap_GetPairIntDouble_KlassBase(_swig_base) -} - -var _wrap_SetPairIntDouble_BaseVal1 unsafe.Pointer - -func _swig_wrap_SetPairIntDouble_BaseVal1(base SwigcptrPairIntDouble, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_SetPairIntDouble_BaseVal1, _swig_p) - return -} - -func (_swig_base SwigcptrPairIntDouble) SetBaseVal1(arg1 int) { - _swig_wrap_SetPairIntDouble_BaseVal1(_swig_base, arg1) -} - -var _wrap_GetPairIntDouble_BaseVal1 unsafe.Pointer - -func _swig_wrap_GetPairIntDouble_BaseVal1(base SwigcptrPairIntDouble) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_GetPairIntDouble_BaseVal1, _swig_p) - return -} - -func (_swig_base SwigcptrPairIntDouble) GetBaseVal1() (_swig_ret int) { - return _swig_wrap_GetPairIntDouble_BaseVal1(_swig_base) -} - -var _wrap_SetPairIntDouble_BaseVal2 unsafe.Pointer - -func _swig_wrap_SetPairIntDouble_BaseVal2(base SwigcptrPairIntDouble, _ float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_SetPairIntDouble_BaseVal2, _swig_p) - return -} - -func (_swig_base SwigcptrPairIntDouble) SetBaseVal2(arg1 float64) { - _swig_wrap_SetPairIntDouble_BaseVal2(_swig_base, arg1) -} - -var _wrap_GetPairIntDouble_BaseVal2 unsafe.Pointer - -func _swig_wrap_GetPairIntDouble_BaseVal2(base SwigcptrPairIntDouble) (_ float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_GetPairIntDouble_BaseVal2, _swig_p) - return -} - -func (_swig_base SwigcptrPairIntDouble) GetBaseVal2() (_swig_ret float64) { - return _swig_wrap_GetPairIntDouble_BaseVal2(_swig_base) -} - -func (p SwigcptrPairIntDouble) SwigIsBaseIntDouble() { -} - -func (p SwigcptrPairIntDouble) SwigGetBaseIntDouble() BaseIntDouble { - return SwigcptrBaseIntDouble(p.Swigcptr()) -} - -type PairIntDouble interface { - Swigcptr() uintptr - SwigIsPairIntDouble() - SetKlassPair(arg2 Klass) - GetKlassPair() (_swig_ret Klass) - SetVal1(arg2 int) - GetVal1() (_swig_ret int) - SetVal2(arg2 float64) - GetVal2() (_swig_ret float64) - GetValue() (_swig_ret string) - SetKlassBase(arg1 Klass) - GetKlassBase() (_swig_ret Klass) - SetBaseVal1(arg1 int) - GetBaseVal1() (_swig_ret int) - SetBaseVal2(arg1 float64) - GetBaseVal2() (_swig_ret float64) - SwigIsBaseIntDouble() - SwigGetBaseIntDouble() BaseIntDouble -} - -var _wrap_NOT_COUNTING_get unsafe.Pointer - -func GetNOT_COUNTING() (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_NOT_COUNTING_get, _swig_p) - return -} -var _wrap_shared_ptr_wrapper_count unsafe.Pointer - -func Shared_ptr_wrapper_count() (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_shared_ptr_wrapper_count, _swig_p) - return -} - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - -type SwigcptrSwigBoost_shared_ptr_Sl_Pair_Sl_int_Sc_double_Sg__Sg_ uintptr -type SwigBoost_shared_ptr_Sl_Pair_Sl_int_Sc_double_Sg__Sg_ interface { - Swigcptr() uintptr; -} -func (p SwigcptrSwigBoost_shared_ptr_Sl_Pair_Sl_int_Sc_double_Sg__Sg_) Swigcptr() uintptr { - return uintptr(p) -} - -type SwigcptrSwigBoost_shared_ptr_Sl_Space_Klass_SS_const_Sg_ uintptr -type SwigBoost_shared_ptr_Sl_Space_Klass_SS_const_Sg_ interface { - Swigcptr() uintptr; -} -func (p SwigcptrSwigBoost_shared_ptr_Sl_Space_Klass_SS_const_Sg_) Swigcptr() uintptr { - return uintptr(p) -} - -type SwigcptrSwigBoost_shared_ptr_Sl_Space_Klass_Sg_ uintptr -type SwigBoost_shared_ptr_Sl_Space_Klass_Sg_ interface { - Swigcptr() uintptr; -} -func (p SwigcptrSwigBoost_shared_ptr_Sl_Space_Klass_Sg_) Swigcptr() uintptr { - return uintptr(p) -} - -type SwigcptrSwigBoost_shared_ptr_Sl_Space_Klass2ndDerived_Sg_ uintptr -type SwigBoost_shared_ptr_Sl_Space_Klass2ndDerived_Sg_ interface { - Swigcptr() uintptr; -} -func (p SwigcptrSwigBoost_shared_ptr_Sl_Space_Klass2ndDerived_Sg_) Swigcptr() uintptr { - return uintptr(p) -} - -type SwigcptrSwigBoost_shared_ptr_Sl_Space_Klass3rdDerived_Sg_ uintptr -type SwigBoost_shared_ptr_Sl_Space_Klass3rdDerived_Sg_ interface { - Swigcptr() uintptr; -} -func (p SwigcptrSwigBoost_shared_ptr_Sl_Space_Klass3rdDerived_Sg_) Swigcptr() uintptr { - return uintptr(p) -} - -type SwigcptrSwigBoost_shared_ptr_Sl_Space_KlassDerived_Sg_ uintptr -type SwigBoost_shared_ptr_Sl_Space_KlassDerived_Sg_ interface { - Swigcptr() uintptr; -} -func (p SwigcptrSwigBoost_shared_ptr_Sl_Space_KlassDerived_Sg_) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/li_boost_shared_ptr_attribute.go b/Examples/test-suite/go/li_boost_shared_ptr_attribute.go deleted file mode 100644 index 76e2d0172..000000000 --- a/Examples/test-suite/go/li_boost_shared_ptr_attribute.go +++ /dev/null @@ -1,29 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../li_boost_shared_ptr_attribute.i - -package li_boost_shared_ptr_attribute - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - - diff --git a/Examples/test-suite/go/li_boost_shared_ptr_bits.go b/Examples/test-suite/go/li_boost_shared_ptr_bits.go deleted file mode 100644 index d292aa634..000000000 --- a/Examples/test-suite/go/li_boost_shared_ptr_bits.go +++ /dev/null @@ -1,417 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../li_boost_shared_ptr_bits.i - -package li_boost_shared_ptr_bits - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrNonDynamic uintptr - -func (p SwigcptrNonDynamic) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrNonDynamic) SwigIsNonDynamic() { -} - -var _wrap_NonDynamic_i_set unsafe.Pointer - -func _swig_wrap_NonDynamic_i_set(base SwigcptrNonDynamic, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_NonDynamic_i_set, _swig_p) - return -} - -func (arg1 SwigcptrNonDynamic) SetI(arg2 int) { - _swig_wrap_NonDynamic_i_set(arg1, arg2) -} - -var _wrap_NonDynamic_i_get unsafe.Pointer - -func _swig_wrap_NonDynamic_i_get(base SwigcptrNonDynamic) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_NonDynamic_i_get, _swig_p) - return -} - -func (arg1 SwigcptrNonDynamic) GetI() (_swig_ret int) { - return _swig_wrap_NonDynamic_i_get(arg1) -} - -var _wrap_new_NonDynamic unsafe.Pointer - -func _swig_wrap_new_NonDynamic() (base SwigcptrNonDynamic) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_NonDynamic, _swig_p) - return -} - -func NewNonDynamic() (_swig_ret NonDynamic) { - return _swig_wrap_new_NonDynamic() -} - -var _wrap_delete_NonDynamic unsafe.Pointer - -func _swig_wrap_delete_NonDynamic(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_NonDynamic, _swig_p) - return -} - -func DeleteNonDynamic(arg1 NonDynamic) { - _swig_wrap_delete_NonDynamic(arg1.Swigcptr()) -} - -type NonDynamic interface { - Swigcptr() uintptr - SwigIsNonDynamic() - SetI(arg2 int) - GetI() (_swig_ret int) -} - -var _wrap_boing unsafe.Pointer - -func _swig_wrap_boing(base uintptr) (_ SwigcptrBoost_shared_ptr_Sl_NonDynamic_Sg_) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_boing, _swig_p) - return -} - -func Boing(arg1 Boost_shared_ptr_Sl_NonDynamic_Sg_) (_swig_ret Boost_shared_ptr_Sl_NonDynamic_Sg_) { - return _swig_wrap_boing(arg1.Swigcptr()) -} - -type SwigcptrIntHolder uintptr - -func (p SwigcptrIntHolder) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrIntHolder) SwigIsIntHolder() { -} - -var _wrap_IntHolder_val_set unsafe.Pointer - -func _swig_wrap_IntHolder_val_set(base SwigcptrIntHolder, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_IntHolder_val_set, _swig_p) - return -} - -func (arg1 SwigcptrIntHolder) SetVal(arg2 int) { - _swig_wrap_IntHolder_val_set(arg1, arg2) -} - -var _wrap_IntHolder_val_get unsafe.Pointer - -func _swig_wrap_IntHolder_val_get(base SwigcptrIntHolder) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_IntHolder_val_get, _swig_p) - return -} - -func (arg1 SwigcptrIntHolder) GetVal() (_swig_ret int) { - return _swig_wrap_IntHolder_val_get(arg1) -} - -var _wrap_new_IntHolder unsafe.Pointer - -func _swig_wrap_new_IntHolder(base int) (_ SwigcptrIntHolder) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_IntHolder, _swig_p) - return -} - -func NewIntHolder(arg1 int) (_swig_ret IntHolder) { - return _swig_wrap_new_IntHolder(arg1) -} - -var _wrap_delete_IntHolder unsafe.Pointer - -func _swig_wrap_delete_IntHolder(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_IntHolder, _swig_p) - return -} - -func DeleteIntHolder(arg1 IntHolder) { - _swig_wrap_delete_IntHolder(arg1.Swigcptr()) -} - -type IntHolder interface { - Swigcptr() uintptr - SwigIsIntHolder() - SetVal(arg2 int) - GetVal() (_swig_ret int) -} - -var _wrap_sum unsafe.Pointer - -func _swig_wrap_sum(base uintptr) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_sum, _swig_p) - return -} - -func Sum(arg1 VectorIntHolder) (_swig_ret int) { - return _swig_wrap_sum(arg1.Swigcptr()) -} - -type SwigcptrVectorIntHolder uintptr - -func (p SwigcptrVectorIntHolder) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrVectorIntHolder) SwigIsVectorIntHolder() { -} - -var _wrap_new_VectorIntHolder__SWIG_0 unsafe.Pointer - -func _swig_wrap_new_VectorIntHolder__SWIG_0() (base SwigcptrVectorIntHolder) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_VectorIntHolder__SWIG_0, _swig_p) - return -} - -func NewVectorIntHolder__SWIG_0() (_swig_ret VectorIntHolder) { - return _swig_wrap_new_VectorIntHolder__SWIG_0() -} - -var _wrap_new_VectorIntHolder__SWIG_1 unsafe.Pointer - -func _swig_wrap_new_VectorIntHolder__SWIG_1(base int64) (_ SwigcptrVectorIntHolder) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_VectorIntHolder__SWIG_1, _swig_p) - return -} - -func NewVectorIntHolder__SWIG_1(arg1 int64) (_swig_ret VectorIntHolder) { - return _swig_wrap_new_VectorIntHolder__SWIG_1(arg1) -} - -func NewVectorIntHolder(a ...interface{}) VectorIntHolder { - argc := len(a) - if argc == 0 { - return NewVectorIntHolder__SWIG_0() - } - if argc == 1 { - return NewVectorIntHolder__SWIG_1(a[0].(int64)) - } - panic("No match for overloaded function call") -} - -var _wrap_VectorIntHolder_size unsafe.Pointer - -func _swig_wrap_VectorIntHolder_size(base SwigcptrVectorIntHolder) (_ int64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_VectorIntHolder_size, _swig_p) - return -} - -func (arg1 SwigcptrVectorIntHolder) Size() (_swig_ret int64) { - return _swig_wrap_VectorIntHolder_size(arg1) -} - -var _wrap_VectorIntHolder_capacity unsafe.Pointer - -func _swig_wrap_VectorIntHolder_capacity(base SwigcptrVectorIntHolder) (_ int64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_VectorIntHolder_capacity, _swig_p) - return -} - -func (arg1 SwigcptrVectorIntHolder) Capacity() (_swig_ret int64) { - return _swig_wrap_VectorIntHolder_capacity(arg1) -} - -var _wrap_VectorIntHolder_reserve unsafe.Pointer - -func _swig_wrap_VectorIntHolder_reserve(base SwigcptrVectorIntHolder, _ int64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_VectorIntHolder_reserve, _swig_p) - return -} - -func (arg1 SwigcptrVectorIntHolder) Reserve(arg2 int64) { - _swig_wrap_VectorIntHolder_reserve(arg1, arg2) -} - -var _wrap_VectorIntHolder_isEmpty unsafe.Pointer - -func _swig_wrap_VectorIntHolder_isEmpty(base SwigcptrVectorIntHolder) (_ bool) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_VectorIntHolder_isEmpty, _swig_p) - return -} - -func (arg1 SwigcptrVectorIntHolder) IsEmpty() (_swig_ret bool) { - return _swig_wrap_VectorIntHolder_isEmpty(arg1) -} - -var _wrap_VectorIntHolder_clear unsafe.Pointer - -func _swig_wrap_VectorIntHolder_clear(base SwigcptrVectorIntHolder) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_VectorIntHolder_clear, _swig_p) - return -} - -func (arg1 SwigcptrVectorIntHolder) Clear() { - _swig_wrap_VectorIntHolder_clear(arg1) -} - -var _wrap_VectorIntHolder_add unsafe.Pointer - -func _swig_wrap_VectorIntHolder_add(base SwigcptrVectorIntHolder, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_VectorIntHolder_add, _swig_p) - return -} - -func (arg1 SwigcptrVectorIntHolder) Add(arg2 Boost_shared_ptr_Sl_IntHolder_Sg_) { - _swig_wrap_VectorIntHolder_add(arg1, arg2.Swigcptr()) -} - -var _wrap_VectorIntHolder_get unsafe.Pointer - -func _swig_wrap_VectorIntHolder_get(base SwigcptrVectorIntHolder, _ int) (_ SwigcptrBoost_shared_ptr_Sl_IntHolder_Sg_) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_VectorIntHolder_get, _swig_p) - return -} - -func (arg1 SwigcptrVectorIntHolder) Get(arg2 int) (_swig_ret Boost_shared_ptr_Sl_IntHolder_Sg_) { - return _swig_wrap_VectorIntHolder_get(arg1, arg2) -} - -var _wrap_VectorIntHolder_set unsafe.Pointer - -func _swig_wrap_VectorIntHolder_set(base SwigcptrVectorIntHolder, _ int, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_VectorIntHolder_set, _swig_p) - return -} - -func (arg1 SwigcptrVectorIntHolder) Set(arg2 int, arg3 Boost_shared_ptr_Sl_IntHolder_Sg_) { - _swig_wrap_VectorIntHolder_set(arg1, arg2, arg3.Swigcptr()) -} - -var _wrap_delete_VectorIntHolder unsafe.Pointer - -func _swig_wrap_delete_VectorIntHolder(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_VectorIntHolder, _swig_p) - return -} - -func DeleteVectorIntHolder(arg1 VectorIntHolder) { - _swig_wrap_delete_VectorIntHolder(arg1.Swigcptr()) -} - -type VectorIntHolder interface { - Swigcptr() uintptr - SwigIsVectorIntHolder() - Size() (_swig_ret int64) - Capacity() (_swig_ret int64) - Reserve(arg2 int64) - IsEmpty() (_swig_ret bool) - Clear() - Add(arg2 Boost_shared_ptr_Sl_IntHolder_Sg_) - Get(arg2 int) (_swig_ret Boost_shared_ptr_Sl_IntHolder_Sg_) - Set(arg2 int, arg3 Boost_shared_ptr_Sl_IntHolder_Sg_) -} - -type SwigcptrHiddenDestructor uintptr - -func (p SwigcptrHiddenDestructor) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrHiddenDestructor) SwigIsHiddenDestructor() { -} - -var _wrap_HiddenDestructor_create unsafe.Pointer - -func _swig_wrap_HiddenDestructor_create() (base SwigcptrBoost_shared_ptr_Sl_HiddenDestructor_Sg_) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_HiddenDestructor_create, _swig_p) - return -} - -func HiddenDestructorCreate() (_swig_ret Boost_shared_ptr_Sl_HiddenDestructor_Sg_) { - return _swig_wrap_HiddenDestructor_create() -} - -var _wrap_HiddenDestructor_doit unsafe.Pointer - -func _swig_wrap_HiddenDestructor_doit(base SwigcptrHiddenDestructor) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_HiddenDestructor_doit, _swig_p) - return -} - -func (arg1 SwigcptrHiddenDestructor) Doit() { - _swig_wrap_HiddenDestructor_doit(arg1) -} - -type HiddenDestructor interface { - Swigcptr() uintptr - SwigIsHiddenDestructor() - Doit() -} - - -type SwigcptrBoost_shared_ptr_Sl_NonDynamic_Sg_ uintptr -type Boost_shared_ptr_Sl_NonDynamic_Sg_ interface { - Swigcptr() uintptr; -} -func (p SwigcptrBoost_shared_ptr_Sl_NonDynamic_Sg_) Swigcptr() uintptr { - return uintptr(p) -} - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - -type SwigcptrBoost_shared_ptr_Sl_IntHolder_Sg_ uintptr -type Boost_shared_ptr_Sl_IntHolder_Sg_ interface { - Swigcptr() uintptr; -} -func (p SwigcptrBoost_shared_ptr_Sl_IntHolder_Sg_) Swigcptr() uintptr { - return uintptr(p) -} - -type SwigcptrBoost_shared_ptr_Sl_HiddenDestructor_Sg_ uintptr -type Boost_shared_ptr_Sl_HiddenDestructor_Sg_ interface { - Swigcptr() uintptr; -} -func (p SwigcptrBoost_shared_ptr_Sl_HiddenDestructor_Sg_) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/li_boost_shared_ptr_template.go b/Examples/test-suite/go/li_boost_shared_ptr_template.go deleted file mode 100644 index fba6ed8dd..000000000 --- a/Examples/test-suite/go/li_boost_shared_ptr_template.go +++ /dev/null @@ -1,343 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../li_boost_shared_ptr_template.i - -package li_boost_shared_ptr_template - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -var _wrap_bar_getter unsafe.Pointer - -func _swig_wrap_bar_getter(base uintptr) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_bar_getter, _swig_p) - return -} - -func Bar_getter(arg1 BaseINTEGER) (_swig_ret int) { - return _swig_wrap_bar_getter(arg1.Swigcptr()) -} - -type SwigcptrBaseINTEGER uintptr - -func (p SwigcptrBaseINTEGER) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrBaseINTEGER) SwigIsBaseINTEGER() { -} - -var _wrap_BaseINTEGER_bar unsafe.Pointer - -func _swig_wrap_BaseINTEGER_bar(base SwigcptrBaseINTEGER) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_BaseINTEGER_bar, _swig_p) - return -} - -func (arg1 SwigcptrBaseINTEGER) Bar() (_swig_ret int) { - return _swig_wrap_BaseINTEGER_bar(arg1) -} - -var _wrap_new_BaseINTEGER unsafe.Pointer - -func _swig_wrap_new_BaseINTEGER() (base SwigcptrBaseINTEGER) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_BaseINTEGER, _swig_p) - return -} - -func NewBaseINTEGER() (_swig_ret BaseINTEGER) { - return _swig_wrap_new_BaseINTEGER() -} - -var _wrap_delete_BaseINTEGER unsafe.Pointer - -func _swig_wrap_delete_BaseINTEGER(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_BaseINTEGER, _swig_p) - return -} - -func DeleteBaseINTEGER(arg1 BaseINTEGER) { - _swig_wrap_delete_BaseINTEGER(arg1.Swigcptr()) -} - -type BaseINTEGER interface { - Swigcptr() uintptr - SwigIsBaseINTEGER() - Bar() (_swig_ret int) -} - -type SwigcptrDerivedINTEGER uintptr - -func (p SwigcptrDerivedINTEGER) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrDerivedINTEGER) SwigIsDerivedINTEGER() { -} - -var _wrap_DerivedINTEGER_bar unsafe.Pointer - -func _swig_wrap_DerivedINTEGER_bar(base SwigcptrDerivedINTEGER) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_DerivedINTEGER_bar, _swig_p) - return -} - -func (arg1 SwigcptrDerivedINTEGER) Bar() (_swig_ret int) { - return _swig_wrap_DerivedINTEGER_bar(arg1) -} - -var _wrap_new_DerivedINTEGER unsafe.Pointer - -func _swig_wrap_new_DerivedINTEGER() (base SwigcptrDerivedINTEGER) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_DerivedINTEGER, _swig_p) - return -} - -func NewDerivedINTEGER() (_swig_ret DerivedINTEGER) { - return _swig_wrap_new_DerivedINTEGER() -} - -var _wrap_delete_DerivedINTEGER unsafe.Pointer - -func _swig_wrap_delete_DerivedINTEGER(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_DerivedINTEGER, _swig_p) - return -} - -func DeleteDerivedINTEGER(arg1 DerivedINTEGER) { - _swig_wrap_delete_DerivedINTEGER(arg1.Swigcptr()) -} - -func (p SwigcptrDerivedINTEGER) SwigIsBaseINTEGER() { -} - -func (p SwigcptrDerivedINTEGER) SwigGetBaseINTEGER() BaseINTEGER { - return SwigcptrBaseINTEGER(p.Swigcptr()) -} - -type DerivedINTEGER interface { - Swigcptr() uintptr - SwigIsDerivedINTEGER() - Bar() (_swig_ret int) - SwigIsBaseINTEGER() - SwigGetBaseINTEGER() BaseINTEGER -} - -var _wrap_bar2_getter unsafe.Pointer - -func _swig_wrap_bar2_getter(base uintptr) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_bar2_getter, _swig_p) - return -} - -func Bar2_getter(arg1 BaseDefaultInt) (_swig_ret int) { - return _swig_wrap_bar2_getter(arg1.Swigcptr()) -} - -type SwigcptrBaseDefaultInt uintptr - -func (p SwigcptrBaseDefaultInt) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrBaseDefaultInt) SwigIsBaseDefaultInt() { -} - -var _wrap_BaseDefaultInt_bar2 unsafe.Pointer - -func _swig_wrap_BaseDefaultInt_bar2(base SwigcptrBaseDefaultInt) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_BaseDefaultInt_bar2, _swig_p) - return -} - -func (arg1 SwigcptrBaseDefaultInt) Bar2() (_swig_ret int) { - return _swig_wrap_BaseDefaultInt_bar2(arg1) -} - -var _wrap_new_BaseDefaultInt unsafe.Pointer - -func _swig_wrap_new_BaseDefaultInt() (base SwigcptrBaseDefaultInt) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_BaseDefaultInt, _swig_p) - return -} - -func NewBaseDefaultInt() (_swig_ret BaseDefaultInt) { - return _swig_wrap_new_BaseDefaultInt() -} - -var _wrap_delete_BaseDefaultInt unsafe.Pointer - -func _swig_wrap_delete_BaseDefaultInt(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_BaseDefaultInt, _swig_p) - return -} - -func DeleteBaseDefaultInt(arg1 BaseDefaultInt) { - _swig_wrap_delete_BaseDefaultInt(arg1.Swigcptr()) -} - -type BaseDefaultInt interface { - Swigcptr() uintptr - SwigIsBaseDefaultInt() - Bar2() (_swig_ret int) -} - -type SwigcptrDerivedDefaultInt uintptr - -func (p SwigcptrDerivedDefaultInt) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrDerivedDefaultInt) SwigIsDerivedDefaultInt() { -} - -var _wrap_DerivedDefaultInt_bar2 unsafe.Pointer - -func _swig_wrap_DerivedDefaultInt_bar2(base SwigcptrDerivedDefaultInt) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_DerivedDefaultInt_bar2, _swig_p) - return -} - -func (arg1 SwigcptrDerivedDefaultInt) Bar2() (_swig_ret int) { - return _swig_wrap_DerivedDefaultInt_bar2(arg1) -} - -var _wrap_new_DerivedDefaultInt unsafe.Pointer - -func _swig_wrap_new_DerivedDefaultInt() (base SwigcptrDerivedDefaultInt) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_DerivedDefaultInt, _swig_p) - return -} - -func NewDerivedDefaultInt() (_swig_ret DerivedDefaultInt) { - return _swig_wrap_new_DerivedDefaultInt() -} - -var _wrap_delete_DerivedDefaultInt unsafe.Pointer - -func _swig_wrap_delete_DerivedDefaultInt(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_DerivedDefaultInt, _swig_p) - return -} - -func DeleteDerivedDefaultInt(arg1 DerivedDefaultInt) { - _swig_wrap_delete_DerivedDefaultInt(arg1.Swigcptr()) -} - -func (p SwigcptrDerivedDefaultInt) SwigIsBaseDefaultInt() { -} - -func (p SwigcptrDerivedDefaultInt) SwigGetBaseDefaultInt() BaseDefaultInt { - return SwigcptrBaseDefaultInt(p.Swigcptr()) -} - -type DerivedDefaultInt interface { - Swigcptr() uintptr - SwigIsDerivedDefaultInt() - Bar2() (_swig_ret int) - SwigIsBaseDefaultInt() - SwigGetBaseDefaultInt() BaseDefaultInt -} - -type SwigcptrDerivedDefaultInt2 uintptr - -func (p SwigcptrDerivedDefaultInt2) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrDerivedDefaultInt2) SwigIsDerivedDefaultInt2() { -} - -var _wrap_DerivedDefaultInt2_bar2 unsafe.Pointer - -func _swig_wrap_DerivedDefaultInt2_bar2(base SwigcptrDerivedDefaultInt2) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_DerivedDefaultInt2_bar2, _swig_p) - return -} - -func (arg1 SwigcptrDerivedDefaultInt2) Bar2() (_swig_ret int) { - return _swig_wrap_DerivedDefaultInt2_bar2(arg1) -} - -var _wrap_new_DerivedDefaultInt2 unsafe.Pointer - -func _swig_wrap_new_DerivedDefaultInt2() (base SwigcptrDerivedDefaultInt2) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_DerivedDefaultInt2, _swig_p) - return -} - -func NewDerivedDefaultInt2() (_swig_ret DerivedDefaultInt2) { - return _swig_wrap_new_DerivedDefaultInt2() -} - -var _wrap_delete_DerivedDefaultInt2 unsafe.Pointer - -func _swig_wrap_delete_DerivedDefaultInt2(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_DerivedDefaultInt2, _swig_p) - return -} - -func DeleteDerivedDefaultInt2(arg1 DerivedDefaultInt2) { - _swig_wrap_delete_DerivedDefaultInt2(arg1.Swigcptr()) -} - -func (p SwigcptrDerivedDefaultInt2) SwigIsBaseDefaultInt() { -} - -func (p SwigcptrDerivedDefaultInt2) SwigGetBaseDefaultInt() BaseDefaultInt { - return SwigcptrBaseDefaultInt(p.Swigcptr()) -} - -type DerivedDefaultInt2 interface { - Swigcptr() uintptr - SwigIsDerivedDefaultInt2() - Bar2() (_swig_ret int) - SwigIsBaseDefaultInt() - SwigGetBaseDefaultInt() BaseDefaultInt -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/li_carrays.go b/Examples/test-suite/go/li_carrays.go deleted file mode 100644 index 9a9d6b035..000000000 --- a/Examples/test-suite/go/li_carrays.go +++ /dev/null @@ -1,529 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../li_carrays.i - -package li_carrays - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -var _wrap_new_intArray unsafe.Pointer - -func New_intArray(arg1 int) (_swig_ret *int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_new_intArray, _swig_p) - return -} -var _wrap_delete_intArray unsafe.Pointer - -func _swig_wrap_delete_intArray(base *int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_intArray, _swig_p) - return -} - -func Delete_intArray(arg1 *int) { - _swig_wrap_delete_intArray(arg1) -} - -var _wrap_intArray_getitem unsafe.Pointer - -func IntArray_getitem(arg1 *int, arg2 int) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_intArray_getitem, _swig_p) - return -} -var _wrap_intArray_setitem unsafe.Pointer - -func _swig_wrap_intArray_setitem(base *int, _ int, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_intArray_setitem, _swig_p) - return -} - -func IntArray_setitem(arg1 *int, arg2 int, arg3 int) { - _swig_wrap_intArray_setitem(arg1, arg2, arg3) -} - -type SwigcptrDoubleArray uintptr - -func (p SwigcptrDoubleArray) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrDoubleArray) SwigIsDoubleArray() { -} - -var _wrap_new_doubleArray unsafe.Pointer - -func _swig_wrap_new_doubleArray(base int) (_ SwigcptrDoubleArray) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_doubleArray, _swig_p) - return -} - -func NewDoubleArray(arg1 int) (_swig_ret DoubleArray) { - return _swig_wrap_new_doubleArray(arg1) -} - -var _wrap_delete_doubleArray unsafe.Pointer - -func _swig_wrap_delete_doubleArray(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_doubleArray, _swig_p) - return -} - -func DeleteDoubleArray(arg1 DoubleArray) { - _swig_wrap_delete_doubleArray(arg1.Swigcptr()) -} - -var _wrap_doubleArray_getitem unsafe.Pointer - -func _swig_wrap_doubleArray_getitem(base SwigcptrDoubleArray, _ int) (_ float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_doubleArray_getitem, _swig_p) - return -} - -func (arg1 SwigcptrDoubleArray) Getitem(arg2 int) (_swig_ret float64) { - return _swig_wrap_doubleArray_getitem(arg1, arg2) -} - -var _wrap_doubleArray_setitem unsafe.Pointer - -func _swig_wrap_doubleArray_setitem(base SwigcptrDoubleArray, _ int, _ float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_doubleArray_setitem, _swig_p) - return -} - -func (arg1 SwigcptrDoubleArray) Setitem(arg2 int, arg3 float64) { - _swig_wrap_doubleArray_setitem(arg1, arg2, arg3) -} - -var _wrap_doubleArray_cast unsafe.Pointer - -func _swig_wrap_doubleArray_cast(base SwigcptrDoubleArray) (_ *float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_doubleArray_cast, _swig_p) - return -} - -func (arg1 SwigcptrDoubleArray) Cast() (_swig_ret *float64) { - return _swig_wrap_doubleArray_cast(arg1) -} - -var _wrap_doubleArray_frompointer unsafe.Pointer - -func _swig_wrap_doubleArray_frompointer(base *float64) (_ SwigcptrDoubleArray) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_doubleArray_frompointer, _swig_p) - return -} - -func DoubleArrayFrompointer(arg1 *float64) (_swig_ret DoubleArray) { - return _swig_wrap_doubleArray_frompointer(arg1) -} - -type DoubleArray interface { - Swigcptr() uintptr - SwigIsDoubleArray() - Getitem(arg2 int) (_swig_ret float64) - Setitem(arg2 int, arg3 float64) - Cast() (_swig_ret *float64) -} - -type SwigcptrXY uintptr - -func (p SwigcptrXY) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrXY) SwigIsXY() { -} - -var _wrap_XY_x_set unsafe.Pointer - -func _swig_wrap_XY_x_set(base SwigcptrXY, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_XY_x_set, _swig_p) - return -} - -func (arg1 SwigcptrXY) SetX(arg2 int) { - _swig_wrap_XY_x_set(arg1, arg2) -} - -var _wrap_XY_x_get unsafe.Pointer - -func _swig_wrap_XY_x_get(base SwigcptrXY) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_XY_x_get, _swig_p) - return -} - -func (arg1 SwigcptrXY) GetX() (_swig_ret int) { - return _swig_wrap_XY_x_get(arg1) -} - -var _wrap_XY_y_set unsafe.Pointer - -func _swig_wrap_XY_y_set(base SwigcptrXY, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_XY_y_set, _swig_p) - return -} - -func (arg1 SwigcptrXY) SetY(arg2 int) { - _swig_wrap_XY_y_set(arg1, arg2) -} - -var _wrap_XY_y_get unsafe.Pointer - -func _swig_wrap_XY_y_get(base SwigcptrXY) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_XY_y_get, _swig_p) - return -} - -func (arg1 SwigcptrXY) GetY() (_swig_ret int) { - return _swig_wrap_XY_y_get(arg1) -} - -var _wrap_new_XY unsafe.Pointer - -func _swig_wrap_new_XY() (base SwigcptrXY) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_XY, _swig_p) - return -} - -func NewXY() (_swig_ret XY) { - return _swig_wrap_new_XY() -} - -var _wrap_delete_XY unsafe.Pointer - -func _swig_wrap_delete_XY(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_XY, _swig_p) - return -} - -func DeleteXY(arg1 XY) { - _swig_wrap_delete_XY(arg1.Swigcptr()) -} - -type XY interface { - Swigcptr() uintptr - SwigIsXY() - SetX(arg2 int) - GetX() (_swig_ret int) - SetY(arg2 int) - GetY() (_swig_ret int) -} - -var _wrap_globalXYArray_set unsafe.Pointer - -func _swig_wrap_globalXYArray_set(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_globalXYArray_set, _swig_p) - return -} - -func SetGlobalXYArray(arg1 XY) { - _swig_wrap_globalXYArray_set(arg1.Swigcptr()) -} - -var _wrap_globalXYArray_get unsafe.Pointer - -func _swig_wrap_globalXYArray_get() (base SwigcptrXY) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_globalXYArray_get, _swig_p) - return -} - -func GetGlobalXYArray() (_swig_ret XY) { - return _swig_wrap_globalXYArray_get() -} - -type SwigcptrAB uintptr - -func (p SwigcptrAB) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrAB) SwigIsAB() { -} - -var _wrap_AB_a_set unsafe.Pointer - -func _swig_wrap_AB_a_set(base SwigcptrAB, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_AB_a_set, _swig_p) - return -} - -func (arg1 SwigcptrAB) SetA(arg2 int) { - _swig_wrap_AB_a_set(arg1, arg2) -} - -var _wrap_AB_a_get unsafe.Pointer - -func _swig_wrap_AB_a_get(base SwigcptrAB) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_AB_a_get, _swig_p) - return -} - -func (arg1 SwigcptrAB) GetA() (_swig_ret int) { - return _swig_wrap_AB_a_get(arg1) -} - -var _wrap_AB_b_set unsafe.Pointer - -func _swig_wrap_AB_b_set(base SwigcptrAB, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_AB_b_set, _swig_p) - return -} - -func (arg1 SwigcptrAB) SetB(arg2 int) { - _swig_wrap_AB_b_set(arg1, arg2) -} - -var _wrap_AB_b_get unsafe.Pointer - -func _swig_wrap_AB_b_get(base SwigcptrAB) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_AB_b_get, _swig_p) - return -} - -func (arg1 SwigcptrAB) GetB() (_swig_ret int) { - return _swig_wrap_AB_b_get(arg1) -} - -var _wrap_new_AB unsafe.Pointer - -func _swig_wrap_new_AB() (base SwigcptrAB) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_AB, _swig_p) - return -} - -func NewAB() (_swig_ret AB) { - return _swig_wrap_new_AB() -} - -var _wrap_delete_AB unsafe.Pointer - -func _swig_wrap_delete_AB(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_AB, _swig_p) - return -} - -func DeleteAB(arg1 AB) { - _swig_wrap_delete_AB(arg1.Swigcptr()) -} - -type AB interface { - Swigcptr() uintptr - SwigIsAB() - SetA(arg2 int) - GetA() (_swig_ret int) - SetB(arg2 int) - GetB() (_swig_ret int) -} - -var _wrap_globalABArray_set unsafe.Pointer - -func _swig_wrap_globalABArray_set(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_globalABArray_set, _swig_p) - return -} - -func SetGlobalABArray(arg1 AB) { - _swig_wrap_globalABArray_set(arg1.Swigcptr()) -} - -var _wrap_globalABArray_get unsafe.Pointer - -func _swig_wrap_globalABArray_get() (base SwigcptrAB) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_globalABArray_get, _swig_p) - return -} - -func GetGlobalABArray() (_swig_ret AB) { - return _swig_wrap_globalABArray_get() -} - -type SwigcptrXYArray uintptr - -func (p SwigcptrXYArray) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrXYArray) SwigIsXYArray() { -} - -var _wrap_new_XYArray unsafe.Pointer - -func _swig_wrap_new_XYArray(base int) (_ SwigcptrXYArray) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_XYArray, _swig_p) - return -} - -func NewXYArray(arg1 int) (_swig_ret XYArray) { - return _swig_wrap_new_XYArray(arg1) -} - -var _wrap_delete_XYArray unsafe.Pointer - -func _swig_wrap_delete_XYArray(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_XYArray, _swig_p) - return -} - -func DeleteXYArray(arg1 XYArray) { - _swig_wrap_delete_XYArray(arg1.Swigcptr()) -} - -var _wrap_XYArray_getitem unsafe.Pointer - -func _swig_wrap_XYArray_getitem(base SwigcptrXYArray, _ int) (_ SwigcptrXY) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_XYArray_getitem, _swig_p) - return -} - -func (arg1 SwigcptrXYArray) Getitem(arg2 int) (_swig_ret XY) { - return _swig_wrap_XYArray_getitem(arg1, arg2) -} - -var _wrap_XYArray_setitem unsafe.Pointer - -func _swig_wrap_XYArray_setitem(base SwigcptrXYArray, _ int, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_XYArray_setitem, _swig_p) - return -} - -func (arg1 SwigcptrXYArray) Setitem(arg2 int, arg3 XY) { - _swig_wrap_XYArray_setitem(arg1, arg2, arg3.Swigcptr()) -} - -var _wrap_XYArray_cast unsafe.Pointer - -func _swig_wrap_XYArray_cast(base SwigcptrXYArray) (_ SwigcptrXY) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_XYArray_cast, _swig_p) - return -} - -func (arg1 SwigcptrXYArray) Cast() (_swig_ret XY) { - return _swig_wrap_XYArray_cast(arg1) -} - -var _wrap_XYArray_frompointer unsafe.Pointer - -func _swig_wrap_XYArray_frompointer(base uintptr) (_ SwigcptrXYArray) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_XYArray_frompointer, _swig_p) - return -} - -func XYArrayFrompointer(arg1 XY) (_swig_ret XYArray) { - return _swig_wrap_XYArray_frompointer(arg1.Swigcptr()) -} - -type XYArray interface { - Swigcptr() uintptr - SwigIsXYArray() - Getitem(arg2 int) (_swig_ret XY) - Setitem(arg2 int, arg3 XY) - Cast() (_swig_ret XY) -} - -var _wrap_new_ABArray unsafe.Pointer - -func _swig_wrap_new_ABArray(base int) (_ SwigcptrAB) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_ABArray, _swig_p) - return -} - -func New_ABArray(arg1 int) (_swig_ret AB) { - return _swig_wrap_new_ABArray(arg1) -} - -var _wrap_delete_ABArray unsafe.Pointer - -func _swig_wrap_delete_ABArray(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_ABArray, _swig_p) - return -} - -func Delete_ABArray(arg1 AB) { - _swig_wrap_delete_ABArray(arg1.Swigcptr()) -} - -var _wrap_ABArray_getitem unsafe.Pointer - -func _swig_wrap_ABArray_getitem(base uintptr, _ int) (_ SwigcptrAB) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_ABArray_getitem, _swig_p) - return -} - -func ABArray_getitem(arg1 AB, arg2 int) (_swig_ret AB) { - return _swig_wrap_ABArray_getitem(arg1.Swigcptr(), arg2) -} - -var _wrap_ABArray_setitem unsafe.Pointer - -func _swig_wrap_ABArray_setitem(base uintptr, _ int, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_ABArray_setitem, _swig_p) - return -} - -func ABArray_setitem(arg1 AB, arg2 int, arg3 AB) { - _swig_wrap_ABArray_setitem(arg1.Swigcptr(), arg2, arg3.Swigcptr()) -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/li_carrays_runme b/Examples/test-suite/go/li_carrays_runme deleted file mode 100755 index 67404be6a..000000000 Binary files a/Examples/test-suite/go/li_carrays_runme and /dev/null differ diff --git a/Examples/test-suite/go/li_cdata.go b/Examples/test-suite/go/li_cdata.go deleted file mode 100644 index 3e645731f..000000000 --- a/Examples/test-suite/go/li_cdata.go +++ /dev/null @@ -1,104 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../li_cdata.i - -package li_cdata - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -var _wrap_cdata unsafe.Pointer - -func _swig_wrap_cdata(base int, _ uintptr, _ int) (_ []byte ) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_cdata, _swig_p) - return -} - -func Cdata(arg1 uintptr, _swig_args ...interface{}) (_swig_ret []byte ) { - var arg2 int - if len(_swig_args) > 0 { - arg2 = _swig_args[0].(int) - } - return _swig_wrap_cdata(len(_swig_args), arg1, arg2) -} - -var _wrap_memmove unsafe.Pointer - -func _swig_wrap_memmove(base uintptr, _ string, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_memmove, _swig_p) - return -} - -func Memmove(arg1 uintptr, arg2 string, arg3 int) { - _swig_wrap_memmove(arg1, arg2, arg3) -} - -var _wrap_cdata_int unsafe.Pointer - -func _swig_wrap_cdata_int(base int, _ *int, _ int) (_ []byte ) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_cdata_int, _swig_p) - return -} - -func Cdata_int(arg1 *int, _swig_args ...interface{}) (_swig_ret []byte ) { - var arg2 int - if len(_swig_args) > 0 { - arg2 = _swig_args[0].(int) - } - return _swig_wrap_cdata_int(len(_swig_args), arg1, arg2) -} - -var _wrap_cdata_double unsafe.Pointer - -func _swig_wrap_cdata_double(base int, _ *float64, _ int) (_ []byte ) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_cdata_double, _swig_p) - return -} - -func Cdata_double(arg1 *float64, _swig_args ...interface{}) (_swig_ret []byte ) { - var arg2 int - if len(_swig_args) > 0 { - arg2 = _swig_args[0].(int) - } - return _swig_wrap_cdata_double(len(_swig_args), arg1, arg2) -} - -var _wrap_malloc unsafe.Pointer - -func Malloc(arg1 int64) (_swig_ret uintptr) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_malloc, _swig_p) - return -} - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/li_cdata_runme b/Examples/test-suite/go/li_cdata_runme deleted file mode 100755 index 196f24f7e..000000000 Binary files a/Examples/test-suite/go/li_cdata_runme and /dev/null differ diff --git a/Examples/test-suite/go/li_cmalloc.go b/Examples/test-suite/go/li_cmalloc.go deleted file mode 100644 index 8a032c376..000000000 --- a/Examples/test-suite/go/li_cmalloc.go +++ /dev/null @@ -1,272 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../li_cmalloc.i - -package li_cmalloc - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -var _wrap_malloc_int unsafe.Pointer - -func _swig_wrap_malloc_int(base int, _ int) (_ *int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_malloc_int, _swig_p) - return -} - -func Malloc_int(_swig_args ...interface{}) (_swig_ret *int) { - var arg1 int - if len(_swig_args) > 0 { - arg1 = _swig_args[0].(int) - } - return _swig_wrap_malloc_int(len(_swig_args), arg1) -} - -var _wrap_calloc_int unsafe.Pointer - -func _swig_wrap_calloc_int(base int, _ int, _ int) (_ *int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_calloc_int, _swig_p) - return -} - -func Calloc_int(_swig_args ...interface{}) (_swig_ret *int) { - var arg1 int - if len(_swig_args) > 0 { - arg1 = _swig_args[0].(int) - } - var arg2 int - if len(_swig_args) > 1 { - arg2 = _swig_args[1].(int) - } - return _swig_wrap_calloc_int(len(_swig_args), arg1, arg2) -} - -var _wrap_realloc_int unsafe.Pointer - -func Realloc_int(arg1 *int, arg2 int) (_swig_ret *int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_realloc_int, _swig_p) - return -} -var _wrap_free_int unsafe.Pointer - -func _swig_wrap_free_int(base *int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_free_int, _swig_p) - return -} - -func Free_int(arg1 *int) { - _swig_wrap_free_int(arg1) -} - -var _wrap_sizeof_int unsafe.Pointer - -func _swig_getsizeof_int() (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_sizeof_int, _swig_p) - return -} -var Sizeof_int int = _swig_getsizeof_int() -var _wrap_malloc_double unsafe.Pointer - -func _swig_wrap_malloc_double(base int, _ int) (_ *float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_malloc_double, _swig_p) - return -} - -func Malloc_double(_swig_args ...interface{}) (_swig_ret *float64) { - var arg1 int - if len(_swig_args) > 0 { - arg1 = _swig_args[0].(int) - } - return _swig_wrap_malloc_double(len(_swig_args), arg1) -} - -var _wrap_calloc_double unsafe.Pointer - -func _swig_wrap_calloc_double(base int, _ int, _ int) (_ *float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_calloc_double, _swig_p) - return -} - -func Calloc_double(_swig_args ...interface{}) (_swig_ret *float64) { - var arg1 int - if len(_swig_args) > 0 { - arg1 = _swig_args[0].(int) - } - var arg2 int - if len(_swig_args) > 1 { - arg2 = _swig_args[1].(int) - } - return _swig_wrap_calloc_double(len(_swig_args), arg1, arg2) -} - -var _wrap_realloc_double unsafe.Pointer - -func Realloc_double(arg1 *float64, arg2 int) (_swig_ret *float64) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_realloc_double, _swig_p) - return -} -var _wrap_free_double unsafe.Pointer - -func _swig_wrap_free_double(base *float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_free_double, _swig_p) - return -} - -func Free_double(arg1 *float64) { - _swig_wrap_free_double(arg1) -} - -var _wrap_sizeof_double unsafe.Pointer - -func _swig_getsizeof_double() (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_sizeof_double, _swig_p) - return -} -var Sizeof_double int = _swig_getsizeof_double() -var _wrap_malloc_void unsafe.Pointer - -func Malloc_void(arg1 int) (_swig_ret uintptr) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_malloc_void, _swig_p) - return -} -var _wrap_calloc_void unsafe.Pointer - -func _swig_wrap_calloc_void(base int, _ int, _ int) (_ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_calloc_void, _swig_p) - return -} - -func Calloc_void(_swig_args ...interface{}) (_swig_ret uintptr) { - var arg1 int - if len(_swig_args) > 0 { - arg1 = _swig_args[0].(int) - } - var arg2 int - if len(_swig_args) > 1 { - arg2 = _swig_args[1].(int) - } - return _swig_wrap_calloc_void(len(_swig_args), arg1, arg2) -} - -var _wrap_realloc_void unsafe.Pointer - -func Realloc_void(arg1 uintptr, arg2 int) (_swig_ret uintptr) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_realloc_void, _swig_p) - return -} -var _wrap_free_void unsafe.Pointer - -func _swig_wrap_free_void(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_free_void, _swig_p) - return -} - -func Free_void(arg1 uintptr) { - _swig_wrap_free_void(arg1) -} - -var _wrap_malloc_intp unsafe.Pointer - -func _swig_wrap_malloc_intp(base int, _ int) (_ **int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_malloc_intp, _swig_p) - return -} - -func Malloc_intp(_swig_args ...interface{}) (_swig_ret **int) { - var arg1 int - if len(_swig_args) > 0 { - arg1 = _swig_args[0].(int) - } - return _swig_wrap_malloc_intp(len(_swig_args), arg1) -} - -var _wrap_calloc_intp unsafe.Pointer - -func _swig_wrap_calloc_intp(base int, _ int, _ int) (_ **int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_calloc_intp, _swig_p) - return -} - -func Calloc_intp(_swig_args ...interface{}) (_swig_ret **int) { - var arg1 int - if len(_swig_args) > 0 { - arg1 = _swig_args[0].(int) - } - var arg2 int - if len(_swig_args) > 1 { - arg2 = _swig_args[1].(int) - } - return _swig_wrap_calloc_intp(len(_swig_args), arg1, arg2) -} - -var _wrap_realloc_intp unsafe.Pointer - -func Realloc_intp(arg1 **int, arg2 int) (_swig_ret **int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_realloc_intp, _swig_p) - return -} -var _wrap_free_intp unsafe.Pointer - -func _swig_wrap_free_intp(base **int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_free_intp, _swig_p) - return -} - -func Free_intp(arg1 **int) { - _swig_wrap_free_intp(arg1) -} - -var _wrap_sizeof_intp unsafe.Pointer - -func _swig_getsizeof_intp() (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_sizeof_intp, _swig_p) - return -} -var Sizeof_intp int = _swig_getsizeof_intp() - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/li_cmalloc_runme b/Examples/test-suite/go/li_cmalloc_runme deleted file mode 100755 index f6bf4f7a7..000000000 Binary files a/Examples/test-suite/go/li_cmalloc_runme and /dev/null differ diff --git a/Examples/test-suite/go/li_constraints.go b/Examples/test-suite/go/li_constraints.go deleted file mode 100644 index db57d888e..000000000 --- a/Examples/test-suite/go/li_constraints.go +++ /dev/null @@ -1,109 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../li_constraints.i - -package li_constraints - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -var _wrap_test_nonnegative unsafe.Pointer - -func _swig_wrap_test_nonnegative(base float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_test_nonnegative, _swig_p) - return -} - -func Test_nonnegative(arg1 float64) { - _swig_wrap_test_nonnegative(arg1) -} - -var _wrap_test_nonpositive unsafe.Pointer - -func _swig_wrap_test_nonpositive(base float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_test_nonpositive, _swig_p) - return -} - -func Test_nonpositive(arg1 float64) { - _swig_wrap_test_nonpositive(arg1) -} - -var _wrap_test_positive unsafe.Pointer - -func _swig_wrap_test_positive(base float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_test_positive, _swig_p) - return -} - -func Test_positive(arg1 float64) { - _swig_wrap_test_positive(arg1) -} - -var _wrap_test_negative unsafe.Pointer - -func _swig_wrap_test_negative(base float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_test_negative, _swig_p) - return -} - -func Test_negative(arg1 float64) { - _swig_wrap_test_negative(arg1) -} - -var _wrap_test_nonzero unsafe.Pointer - -func _swig_wrap_test_nonzero(base float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_test_nonzero, _swig_p) - return -} - -func Test_nonzero(arg1 float64) { - _swig_wrap_test_nonzero(arg1) -} - -var _wrap_test_nonnull unsafe.Pointer - -func _swig_wrap_test_nonnull(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_test_nonnull, _swig_p) - return -} - -func Test_nonnull(arg1 uintptr) { - _swig_wrap_test_nonnull(arg1) -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/li_cpointer.go b/Examples/test-suite/go/li_cpointer.go deleted file mode 100644 index a2c425a86..000000000 --- a/Examples/test-suite/go/li_cpointer.go +++ /dev/null @@ -1,178 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../li_cpointer.i - -package li_cpointer - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -var _wrap_new_intp unsafe.Pointer - -func New_intp() (_swig_ret *int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_new_intp, _swig_p) - return -} -var _wrap_copy_intp unsafe.Pointer - -func Copy_intp(arg1 int) (_swig_ret *int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_copy_intp, _swig_p) - return -} -var _wrap_delete_intp unsafe.Pointer - -func _swig_wrap_delete_intp(base *int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_intp, _swig_p) - return -} - -func Delete_intp(arg1 *int) { - _swig_wrap_delete_intp(arg1) -} - -var _wrap_intp_assign unsafe.Pointer - -func _swig_wrap_intp_assign(base *int, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_intp_assign, _swig_p) - return -} - -func Intp_assign(arg1 *int, arg2 int) { - _swig_wrap_intp_assign(arg1, arg2) -} - -var _wrap_intp_value unsafe.Pointer - -func Intp_value(arg1 *int) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_intp_value, _swig_p) - return -} -type SwigcptrDoublep uintptr - -func (p SwigcptrDoublep) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrDoublep) SwigIsDoublep() { -} - -var _wrap_new_doublep unsafe.Pointer - -func _swig_wrap_new_doublep() (base SwigcptrDoublep) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_doublep, _swig_p) - return -} - -func NewDoublep() (_swig_ret Doublep) { - return _swig_wrap_new_doublep() -} - -var _wrap_delete_doublep unsafe.Pointer - -func _swig_wrap_delete_doublep(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_doublep, _swig_p) - return -} - -func DeleteDoublep(arg1 Doublep) { - _swig_wrap_delete_doublep(arg1.Swigcptr()) -} - -var _wrap_doublep_assign unsafe.Pointer - -func _swig_wrap_doublep_assign(base SwigcptrDoublep, _ float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_doublep_assign, _swig_p) - return -} - -func (arg1 SwigcptrDoublep) Assign(arg2 float64) { - _swig_wrap_doublep_assign(arg1, arg2) -} - -var _wrap_doublep_value unsafe.Pointer - -func _swig_wrap_doublep_value(base SwigcptrDoublep) (_ float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_doublep_value, _swig_p) - return -} - -func (arg1 SwigcptrDoublep) Value() (_swig_ret float64) { - return _swig_wrap_doublep_value(arg1) -} - -var _wrap_doublep_cast unsafe.Pointer - -func _swig_wrap_doublep_cast(base SwigcptrDoublep) (_ *float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_doublep_cast, _swig_p) - return -} - -func (arg1 SwigcptrDoublep) Cast() (_swig_ret *float64) { - return _swig_wrap_doublep_cast(arg1) -} - -var _wrap_doublep_frompointer unsafe.Pointer - -func _swig_wrap_doublep_frompointer(base *float64) (_ SwigcptrDoublep) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_doublep_frompointer, _swig_p) - return -} - -func DoublepFrompointer(arg1 *float64) (_swig_ret Doublep) { - return _swig_wrap_doublep_frompointer(arg1) -} - -type Doublep interface { - Swigcptr() uintptr - SwigIsDoublep() - Assign(arg2 float64) - Value() (_swig_ret float64) - Cast() (_swig_ret *float64) -} - -var _wrap_int_to_uint unsafe.Pointer - -func Int_to_uint(arg1 int) (_swig_ret uint) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_int_to_uint, _swig_p) - return -} - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/li_cpointer_runme b/Examples/test-suite/go/li_cpointer_runme deleted file mode 100755 index 612390139..000000000 Binary files a/Examples/test-suite/go/li_cpointer_runme and /dev/null differ diff --git a/Examples/test-suite/go/li_math.go b/Examples/test-suite/go/li_math.go deleted file mode 100644 index bf882e136..000000000 --- a/Examples/test-suite/go/li_math.go +++ /dev/null @@ -1,175 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../li_math.i - -package li_math - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -var _wrap_cos unsafe.Pointer - -func Cos(arg1 float64) (_swig_ret float64) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_cos, _swig_p) - return -} -var _wrap_sin unsafe.Pointer - -func Sin(arg1 float64) (_swig_ret float64) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_sin, _swig_p) - return -} -var _wrap_tan unsafe.Pointer - -func Tan(arg1 float64) (_swig_ret float64) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_tan, _swig_p) - return -} -var _wrap_acos unsafe.Pointer - -func Acos(arg1 float64) (_swig_ret float64) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_acos, _swig_p) - return -} -var _wrap_asin unsafe.Pointer - -func Asin(arg1 float64) (_swig_ret float64) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_asin, _swig_p) - return -} -var _wrap_atan unsafe.Pointer - -func Atan(arg1 float64) (_swig_ret float64) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_atan, _swig_p) - return -} -var _wrap_atan2 unsafe.Pointer - -func Atan2(arg1 float64, arg2 float64) (_swig_ret float64) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_atan2, _swig_p) - return -} -var _wrap_cosh unsafe.Pointer - -func Cosh(arg1 float64) (_swig_ret float64) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_cosh, _swig_p) - return -} -var _wrap_sinh unsafe.Pointer - -func Sinh(arg1 float64) (_swig_ret float64) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_sinh, _swig_p) - return -} -var _wrap_tanh unsafe.Pointer - -func Tanh(arg1 float64) (_swig_ret float64) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_tanh, _swig_p) - return -} -var _wrap_exp unsafe.Pointer - -func Exp(arg1 float64) (_swig_ret float64) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_exp, _swig_p) - return -} -var _wrap_log unsafe.Pointer - -func Log(arg1 float64) (_swig_ret float64) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_log, _swig_p) - return -} -var _wrap_log10 unsafe.Pointer - -func Log10(arg1 float64) (_swig_ret float64) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_log10, _swig_p) - return -} -var _wrap_pow unsafe.Pointer - -func Pow(arg1 float64, arg2 float64) (_swig_ret float64) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_pow, _swig_p) - return -} -var _wrap_sqrt unsafe.Pointer - -func Sqrt(arg1 float64) (_swig_ret float64) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_sqrt, _swig_p) - return -} -var _wrap_fabs unsafe.Pointer - -func Fabs(arg1 float64) (_swig_ret float64) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_fabs, _swig_p) - return -} -var _wrap_ceil unsafe.Pointer - -func Ceil(arg1 float64) (_swig_ret float64) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_ceil, _swig_p) - return -} -var _wrap_floor unsafe.Pointer - -func Floor(arg1 float64) (_swig_ret float64) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_floor, _swig_p) - return -} -var _wrap_fmod unsafe.Pointer - -func Fmod(arg1 float64, arg2 float64) (_swig_ret float64) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_fmod, _swig_p) - return -} -const M_E float64 = 2.7182818284590452354 -const M_LOG2E float64 = 1.4426950408889634074 -const M_LOG10E float64 = 0.43429448190325182765 -const M_LN2 float64 = 0.69314718055994530942 -const M_LN10 float64 = 2.30258509299404568402 -const M_PI float64 = 3.14159265358979323846 -const M_PI_2 float64 = 1.57079632679489661923 -const M_PI_4 float64 = 0.78539816339744830962 -const M_1_PI float64 = 0.31830988618379067154 -const M_2_PI float64 = 0.63661977236758134308 -const M_2_SQRTPI float64 = 1.12837916709551257390 -const M_SQRT2 float64 = 1.41421356237309504880 -const M_SQRT1_2 float64 = 0.70710678118654752440 - diff --git a/Examples/test-suite/go/li_std_auto_ptr.go b/Examples/test-suite/go/li_std_auto_ptr.go deleted file mode 100644 index 4954ac911..000000000 --- a/Examples/test-suite/go/li_std_auto_ptr.go +++ /dev/null @@ -1,29 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../li_std_auto_ptr.i - -package li_std_auto_ptr - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - - diff --git a/Examples/test-suite/go/li_std_combinations.go b/Examples/test-suite/go/li_std_combinations.go deleted file mode 100644 index 8942dbc69..000000000 --- a/Examples/test-suite/go/li_std_combinations.go +++ /dev/null @@ -1,1374 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../li_std_combinations.i - -package li_std_combinations - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrVectorInt uintptr - -func (p SwigcptrVectorInt) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrVectorInt) SwigIsVectorInt() { -} - -var _wrap_new_VectorInt__SWIG_0 unsafe.Pointer - -func _swig_wrap_new_VectorInt__SWIG_0() (base SwigcptrVectorInt) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_VectorInt__SWIG_0, _swig_p) - return -} - -func NewVectorInt__SWIG_0() (_swig_ret VectorInt) { - return _swig_wrap_new_VectorInt__SWIG_0() -} - -var _wrap_new_VectorInt__SWIG_1 unsafe.Pointer - -func _swig_wrap_new_VectorInt__SWIG_1(base int64) (_ SwigcptrVectorInt) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_VectorInt__SWIG_1, _swig_p) - return -} - -func NewVectorInt__SWIG_1(arg1 int64) (_swig_ret VectorInt) { - return _swig_wrap_new_VectorInt__SWIG_1(arg1) -} - -func NewVectorInt(a ...interface{}) VectorInt { - argc := len(a) - if argc == 0 { - return NewVectorInt__SWIG_0() - } - if argc == 1 { - return NewVectorInt__SWIG_1(a[0].(int64)) - } - panic("No match for overloaded function call") -} - -var _wrap_VectorInt_size unsafe.Pointer - -func _swig_wrap_VectorInt_size(base SwigcptrVectorInt) (_ int64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_VectorInt_size, _swig_p) - return -} - -func (arg1 SwigcptrVectorInt) Size() (_swig_ret int64) { - return _swig_wrap_VectorInt_size(arg1) -} - -var _wrap_VectorInt_capacity unsafe.Pointer - -func _swig_wrap_VectorInt_capacity(base SwigcptrVectorInt) (_ int64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_VectorInt_capacity, _swig_p) - return -} - -func (arg1 SwigcptrVectorInt) Capacity() (_swig_ret int64) { - return _swig_wrap_VectorInt_capacity(arg1) -} - -var _wrap_VectorInt_reserve unsafe.Pointer - -func _swig_wrap_VectorInt_reserve(base SwigcptrVectorInt, _ int64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_VectorInt_reserve, _swig_p) - return -} - -func (arg1 SwigcptrVectorInt) Reserve(arg2 int64) { - _swig_wrap_VectorInt_reserve(arg1, arg2) -} - -var _wrap_VectorInt_isEmpty unsafe.Pointer - -func _swig_wrap_VectorInt_isEmpty(base SwigcptrVectorInt) (_ bool) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_VectorInt_isEmpty, _swig_p) - return -} - -func (arg1 SwigcptrVectorInt) IsEmpty() (_swig_ret bool) { - return _swig_wrap_VectorInt_isEmpty(arg1) -} - -var _wrap_VectorInt_clear unsafe.Pointer - -func _swig_wrap_VectorInt_clear(base SwigcptrVectorInt) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_VectorInt_clear, _swig_p) - return -} - -func (arg1 SwigcptrVectorInt) Clear() { - _swig_wrap_VectorInt_clear(arg1) -} - -var _wrap_VectorInt_add unsafe.Pointer - -func _swig_wrap_VectorInt_add(base SwigcptrVectorInt, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_VectorInt_add, _swig_p) - return -} - -func (arg1 SwigcptrVectorInt) Add(arg2 int) { - _swig_wrap_VectorInt_add(arg1, arg2) -} - -var _wrap_VectorInt_get unsafe.Pointer - -func _swig_wrap_VectorInt_get(base SwigcptrVectorInt, _ int) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_VectorInt_get, _swig_p) - return -} - -func (arg1 SwigcptrVectorInt) Get(arg2 int) (_swig_ret int) { - return _swig_wrap_VectorInt_get(arg1, arg2) -} - -var _wrap_VectorInt_set unsafe.Pointer - -func _swig_wrap_VectorInt_set(base SwigcptrVectorInt, _ int, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_VectorInt_set, _swig_p) - return -} - -func (arg1 SwigcptrVectorInt) Set(arg2 int, arg3 int) { - _swig_wrap_VectorInt_set(arg1, arg2, arg3) -} - -var _wrap_delete_VectorInt unsafe.Pointer - -func _swig_wrap_delete_VectorInt(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_VectorInt, _swig_p) - return -} - -func DeleteVectorInt(arg1 VectorInt) { - _swig_wrap_delete_VectorInt(arg1.Swigcptr()) -} - -type VectorInt interface { - Swigcptr() uintptr - SwigIsVectorInt() - Size() (_swig_ret int64) - Capacity() (_swig_ret int64) - Reserve(arg2 int64) - IsEmpty() (_swig_ret bool) - Clear() - Add(arg2 int) - Get(arg2 int) (_swig_ret int) - Set(arg2 int, arg3 int) -} - -type SwigcptrVectorString uintptr - -func (p SwigcptrVectorString) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrVectorString) SwigIsVectorString() { -} - -var _wrap_new_VectorString__SWIG_0 unsafe.Pointer - -func _swig_wrap_new_VectorString__SWIG_0() (base SwigcptrVectorString) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_VectorString__SWIG_0, _swig_p) - return -} - -func NewVectorString__SWIG_0() (_swig_ret VectorString) { - return _swig_wrap_new_VectorString__SWIG_0() -} - -var _wrap_new_VectorString__SWIG_1 unsafe.Pointer - -func _swig_wrap_new_VectorString__SWIG_1(base int64) (_ SwigcptrVectorString) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_VectorString__SWIG_1, _swig_p) - return -} - -func NewVectorString__SWIG_1(arg1 int64) (_swig_ret VectorString) { - return _swig_wrap_new_VectorString__SWIG_1(arg1) -} - -func NewVectorString(a ...interface{}) VectorString { - argc := len(a) - if argc == 0 { - return NewVectorString__SWIG_0() - } - if argc == 1 { - return NewVectorString__SWIG_1(a[0].(int64)) - } - panic("No match for overloaded function call") -} - -var _wrap_VectorString_size unsafe.Pointer - -func _swig_wrap_VectorString_size(base SwigcptrVectorString) (_ int64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_VectorString_size, _swig_p) - return -} - -func (arg1 SwigcptrVectorString) Size() (_swig_ret int64) { - return _swig_wrap_VectorString_size(arg1) -} - -var _wrap_VectorString_capacity unsafe.Pointer - -func _swig_wrap_VectorString_capacity(base SwigcptrVectorString) (_ int64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_VectorString_capacity, _swig_p) - return -} - -func (arg1 SwigcptrVectorString) Capacity() (_swig_ret int64) { - return _swig_wrap_VectorString_capacity(arg1) -} - -var _wrap_VectorString_reserve unsafe.Pointer - -func _swig_wrap_VectorString_reserve(base SwigcptrVectorString, _ int64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_VectorString_reserve, _swig_p) - return -} - -func (arg1 SwigcptrVectorString) Reserve(arg2 int64) { - _swig_wrap_VectorString_reserve(arg1, arg2) -} - -var _wrap_VectorString_isEmpty unsafe.Pointer - -func _swig_wrap_VectorString_isEmpty(base SwigcptrVectorString) (_ bool) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_VectorString_isEmpty, _swig_p) - return -} - -func (arg1 SwigcptrVectorString) IsEmpty() (_swig_ret bool) { - return _swig_wrap_VectorString_isEmpty(arg1) -} - -var _wrap_VectorString_clear unsafe.Pointer - -func _swig_wrap_VectorString_clear(base SwigcptrVectorString) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_VectorString_clear, _swig_p) - return -} - -func (arg1 SwigcptrVectorString) Clear() { - _swig_wrap_VectorString_clear(arg1) -} - -var _wrap_VectorString_add unsafe.Pointer - -func _swig_wrap_VectorString_add(base SwigcptrVectorString, _ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_VectorString_add, _swig_p) - return -} - -func (arg1 SwigcptrVectorString) Add(arg2 string) { - _swig_wrap_VectorString_add(arg1, arg2) -} - -var _wrap_VectorString_get unsafe.Pointer - -func _swig_wrap_VectorString_get(base SwigcptrVectorString, _ int) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_VectorString_get, _swig_p) - return -} - -func (arg1 SwigcptrVectorString) Get(arg2 int) (_swig_ret string) { - return _swig_wrap_VectorString_get(arg1, arg2) -} - -var _wrap_VectorString_set unsafe.Pointer - -func _swig_wrap_VectorString_set(base SwigcptrVectorString, _ int, _ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_VectorString_set, _swig_p) - return -} - -func (arg1 SwigcptrVectorString) Set(arg2 int, arg3 string) { - _swig_wrap_VectorString_set(arg1, arg2, arg3) -} - -var _wrap_delete_VectorString unsafe.Pointer - -func _swig_wrap_delete_VectorString(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_VectorString, _swig_p) - return -} - -func DeleteVectorString(arg1 VectorString) { - _swig_wrap_delete_VectorString(arg1.Swigcptr()) -} - -type VectorString interface { - Swigcptr() uintptr - SwigIsVectorString() - Size() (_swig_ret int64) - Capacity() (_swig_ret int64) - Reserve(arg2 int64) - IsEmpty() (_swig_ret bool) - Clear() - Add(arg2 string) - Get(arg2 int) (_swig_ret string) - Set(arg2 int, arg3 string) -} - -type SwigcptrPairIntString uintptr - -func (p SwigcptrPairIntString) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrPairIntString) SwigIsPairIntString() { -} - -var _wrap_new_PairIntString__SWIG_0 unsafe.Pointer - -func _swig_wrap_new_PairIntString__SWIG_0() (base SwigcptrPairIntString) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_PairIntString__SWIG_0, _swig_p) - return -} - -func NewPairIntString__SWIG_0() (_swig_ret PairIntString) { - return _swig_wrap_new_PairIntString__SWIG_0() -} - -var _wrap_new_PairIntString__SWIG_1 unsafe.Pointer - -func _swig_wrap_new_PairIntString__SWIG_1(base int, _ string) (_ SwigcptrPairIntString) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_PairIntString__SWIG_1, _swig_p) - return -} - -func NewPairIntString__SWIG_1(arg1 int, arg2 string) (_swig_ret PairIntString) { - return _swig_wrap_new_PairIntString__SWIG_1(arg1, arg2) -} - -var _wrap_new_PairIntString__SWIG_2 unsafe.Pointer - -func _swig_wrap_new_PairIntString__SWIG_2(base uintptr) (_ SwigcptrPairIntString) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_PairIntString__SWIG_2, _swig_p) - return -} - -func NewPairIntString__SWIG_2(arg1 PairIntString) (_swig_ret PairIntString) { - return _swig_wrap_new_PairIntString__SWIG_2(arg1.Swigcptr()) -} - -func NewPairIntString(a ...interface{}) PairIntString { - argc := len(a) - if argc == 0 { - return NewPairIntString__SWIG_0() - } - if argc == 1 { - return NewPairIntString__SWIG_2(a[0].(PairIntString)) - } - if argc == 2 { - return NewPairIntString__SWIG_1(a[0].(int), a[1].(string)) - } - panic("No match for overloaded function call") -} - -var _wrap_PairIntString_first_set unsafe.Pointer - -func _swig_wrap_PairIntString_first_set(base SwigcptrPairIntString, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_PairIntString_first_set, _swig_p) - return -} - -func (arg1 SwigcptrPairIntString) SetFirst(arg2 int) { - _swig_wrap_PairIntString_first_set(arg1, arg2) -} - -var _wrap_PairIntString_first_get unsafe.Pointer - -func _swig_wrap_PairIntString_first_get(base SwigcptrPairIntString) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_PairIntString_first_get, _swig_p) - return -} - -func (arg1 SwigcptrPairIntString) GetFirst() (_swig_ret int) { - return _swig_wrap_PairIntString_first_get(arg1) -} - -var _wrap_PairIntString_second_set unsafe.Pointer - -func _swig_wrap_PairIntString_second_set(base SwigcptrPairIntString, _ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_PairIntString_second_set, _swig_p) - return -} - -func (arg1 SwigcptrPairIntString) SetSecond(arg2 string) { - _swig_wrap_PairIntString_second_set(arg1, arg2) -} - -var _wrap_PairIntString_second_get unsafe.Pointer - -func _swig_wrap_PairIntString_second_get(base SwigcptrPairIntString) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_PairIntString_second_get, _swig_p) - return -} - -func (arg1 SwigcptrPairIntString) GetSecond() (_swig_ret string) { - return _swig_wrap_PairIntString_second_get(arg1) -} - -var _wrap_delete_PairIntString unsafe.Pointer - -func _swig_wrap_delete_PairIntString(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_PairIntString, _swig_p) - return -} - -func DeletePairIntString(arg1 PairIntString) { - _swig_wrap_delete_PairIntString(arg1.Swigcptr()) -} - -type PairIntString interface { - Swigcptr() uintptr - SwigIsPairIntString() - SetFirst(arg2 int) - GetFirst() (_swig_ret int) - SetSecond(arg2 string) - GetSecond() (_swig_ret string) -} - -type SwigcptrVectorPairIntString uintptr - -func (p SwigcptrVectorPairIntString) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrVectorPairIntString) SwigIsVectorPairIntString() { -} - -var _wrap_new_VectorPairIntString__SWIG_0 unsafe.Pointer - -func _swig_wrap_new_VectorPairIntString__SWIG_0() (base SwigcptrVectorPairIntString) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_VectorPairIntString__SWIG_0, _swig_p) - return -} - -func NewVectorPairIntString__SWIG_0() (_swig_ret VectorPairIntString) { - return _swig_wrap_new_VectorPairIntString__SWIG_0() -} - -var _wrap_new_VectorPairIntString__SWIG_1 unsafe.Pointer - -func _swig_wrap_new_VectorPairIntString__SWIG_1(base int64) (_ SwigcptrVectorPairIntString) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_VectorPairIntString__SWIG_1, _swig_p) - return -} - -func NewVectorPairIntString__SWIG_1(arg1 int64) (_swig_ret VectorPairIntString) { - return _swig_wrap_new_VectorPairIntString__SWIG_1(arg1) -} - -func NewVectorPairIntString(a ...interface{}) VectorPairIntString { - argc := len(a) - if argc == 0 { - return NewVectorPairIntString__SWIG_0() - } - if argc == 1 { - return NewVectorPairIntString__SWIG_1(a[0].(int64)) - } - panic("No match for overloaded function call") -} - -var _wrap_VectorPairIntString_size unsafe.Pointer - -func _swig_wrap_VectorPairIntString_size(base SwigcptrVectorPairIntString) (_ int64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_VectorPairIntString_size, _swig_p) - return -} - -func (arg1 SwigcptrVectorPairIntString) Size() (_swig_ret int64) { - return _swig_wrap_VectorPairIntString_size(arg1) -} - -var _wrap_VectorPairIntString_capacity unsafe.Pointer - -func _swig_wrap_VectorPairIntString_capacity(base SwigcptrVectorPairIntString) (_ int64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_VectorPairIntString_capacity, _swig_p) - return -} - -func (arg1 SwigcptrVectorPairIntString) Capacity() (_swig_ret int64) { - return _swig_wrap_VectorPairIntString_capacity(arg1) -} - -var _wrap_VectorPairIntString_reserve unsafe.Pointer - -func _swig_wrap_VectorPairIntString_reserve(base SwigcptrVectorPairIntString, _ int64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_VectorPairIntString_reserve, _swig_p) - return -} - -func (arg1 SwigcptrVectorPairIntString) Reserve(arg2 int64) { - _swig_wrap_VectorPairIntString_reserve(arg1, arg2) -} - -var _wrap_VectorPairIntString_isEmpty unsafe.Pointer - -func _swig_wrap_VectorPairIntString_isEmpty(base SwigcptrVectorPairIntString) (_ bool) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_VectorPairIntString_isEmpty, _swig_p) - return -} - -func (arg1 SwigcptrVectorPairIntString) IsEmpty() (_swig_ret bool) { - return _swig_wrap_VectorPairIntString_isEmpty(arg1) -} - -var _wrap_VectorPairIntString_clear unsafe.Pointer - -func _swig_wrap_VectorPairIntString_clear(base SwigcptrVectorPairIntString) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_VectorPairIntString_clear, _swig_p) - return -} - -func (arg1 SwigcptrVectorPairIntString) Clear() { - _swig_wrap_VectorPairIntString_clear(arg1) -} - -var _wrap_VectorPairIntString_add unsafe.Pointer - -func _swig_wrap_VectorPairIntString_add(base SwigcptrVectorPairIntString, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_VectorPairIntString_add, _swig_p) - return -} - -func (arg1 SwigcptrVectorPairIntString) Add(arg2 PairIntString) { - _swig_wrap_VectorPairIntString_add(arg1, arg2.Swigcptr()) -} - -var _wrap_VectorPairIntString_get unsafe.Pointer - -func _swig_wrap_VectorPairIntString_get(base SwigcptrVectorPairIntString, _ int) (_ SwigcptrPairIntString) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_VectorPairIntString_get, _swig_p) - return -} - -func (arg1 SwigcptrVectorPairIntString) Get(arg2 int) (_swig_ret PairIntString) { - return _swig_wrap_VectorPairIntString_get(arg1, arg2) -} - -var _wrap_VectorPairIntString_set unsafe.Pointer - -func _swig_wrap_VectorPairIntString_set(base SwigcptrVectorPairIntString, _ int, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_VectorPairIntString_set, _swig_p) - return -} - -func (arg1 SwigcptrVectorPairIntString) Set(arg2 int, arg3 PairIntString) { - _swig_wrap_VectorPairIntString_set(arg1, arg2, arg3.Swigcptr()) -} - -var _wrap_delete_VectorPairIntString unsafe.Pointer - -func _swig_wrap_delete_VectorPairIntString(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_VectorPairIntString, _swig_p) - return -} - -func DeleteVectorPairIntString(arg1 VectorPairIntString) { - _swig_wrap_delete_VectorPairIntString(arg1.Swigcptr()) -} - -type VectorPairIntString interface { - Swigcptr() uintptr - SwigIsVectorPairIntString() - Size() (_swig_ret int64) - Capacity() (_swig_ret int64) - Reserve(arg2 int64) - IsEmpty() (_swig_ret bool) - Clear() - Add(arg2 PairIntString) - Get(arg2 int) (_swig_ret PairIntString) - Set(arg2 int, arg3 PairIntString) -} - -type SwigcptrPairIntVectorString uintptr - -func (p SwigcptrPairIntVectorString) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrPairIntVectorString) SwigIsPairIntVectorString() { -} - -var _wrap_new_PairIntVectorString__SWIG_0 unsafe.Pointer - -func _swig_wrap_new_PairIntVectorString__SWIG_0() (base SwigcptrPairIntVectorString) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_PairIntVectorString__SWIG_0, _swig_p) - return -} - -func NewPairIntVectorString__SWIG_0() (_swig_ret PairIntVectorString) { - return _swig_wrap_new_PairIntVectorString__SWIG_0() -} - -var _wrap_new_PairIntVectorString__SWIG_1 unsafe.Pointer - -func _swig_wrap_new_PairIntVectorString__SWIG_1(base int, _ uintptr) (_ SwigcptrPairIntVectorString) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_PairIntVectorString__SWIG_1, _swig_p) - return -} - -func NewPairIntVectorString__SWIG_1(arg1 int, arg2 VectorString) (_swig_ret PairIntVectorString) { - return _swig_wrap_new_PairIntVectorString__SWIG_1(arg1, arg2.Swigcptr()) -} - -var _wrap_new_PairIntVectorString__SWIG_2 unsafe.Pointer - -func _swig_wrap_new_PairIntVectorString__SWIG_2(base uintptr) (_ SwigcptrPairIntVectorString) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_PairIntVectorString__SWIG_2, _swig_p) - return -} - -func NewPairIntVectorString__SWIG_2(arg1 PairIntVectorString) (_swig_ret PairIntVectorString) { - return _swig_wrap_new_PairIntVectorString__SWIG_2(arg1.Swigcptr()) -} - -func NewPairIntVectorString(a ...interface{}) PairIntVectorString { - argc := len(a) - if argc == 0 { - return NewPairIntVectorString__SWIG_0() - } - if argc == 1 { - return NewPairIntVectorString__SWIG_2(a[0].(PairIntVectorString)) - } - if argc == 2 { - return NewPairIntVectorString__SWIG_1(a[0].(int), a[1].(VectorString)) - } - panic("No match for overloaded function call") -} - -var _wrap_PairIntVectorString_first_set unsafe.Pointer - -func _swig_wrap_PairIntVectorString_first_set(base SwigcptrPairIntVectorString, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_PairIntVectorString_first_set, _swig_p) - return -} - -func (arg1 SwigcptrPairIntVectorString) SetFirst(arg2 int) { - _swig_wrap_PairIntVectorString_first_set(arg1, arg2) -} - -var _wrap_PairIntVectorString_first_get unsafe.Pointer - -func _swig_wrap_PairIntVectorString_first_get(base SwigcptrPairIntVectorString) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_PairIntVectorString_first_get, _swig_p) - return -} - -func (arg1 SwigcptrPairIntVectorString) GetFirst() (_swig_ret int) { - return _swig_wrap_PairIntVectorString_first_get(arg1) -} - -var _wrap_PairIntVectorString_second_set unsafe.Pointer - -func _swig_wrap_PairIntVectorString_second_set(base SwigcptrPairIntVectorString, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_PairIntVectorString_second_set, _swig_p) - return -} - -func (arg1 SwigcptrPairIntVectorString) SetSecond(arg2 VectorString) { - _swig_wrap_PairIntVectorString_second_set(arg1, arg2.Swigcptr()) -} - -var _wrap_PairIntVectorString_second_get unsafe.Pointer - -func _swig_wrap_PairIntVectorString_second_get(base SwigcptrPairIntVectorString) (_ SwigcptrVectorString) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_PairIntVectorString_second_get, _swig_p) - return -} - -func (arg1 SwigcptrPairIntVectorString) GetSecond() (_swig_ret VectorString) { - return _swig_wrap_PairIntVectorString_second_get(arg1) -} - -var _wrap_delete_PairIntVectorString unsafe.Pointer - -func _swig_wrap_delete_PairIntVectorString(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_PairIntVectorString, _swig_p) - return -} - -func DeletePairIntVectorString(arg1 PairIntVectorString) { - _swig_wrap_delete_PairIntVectorString(arg1.Swigcptr()) -} - -type PairIntVectorString interface { - Swigcptr() uintptr - SwigIsPairIntVectorString() - SetFirst(arg2 int) - GetFirst() (_swig_ret int) - SetSecond(arg2 VectorString) - GetSecond() (_swig_ret VectorString) -} - -type SwigcptrVectorVectorString uintptr - -func (p SwigcptrVectorVectorString) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrVectorVectorString) SwigIsVectorVectorString() { -} - -var _wrap_new_VectorVectorString__SWIG_0 unsafe.Pointer - -func _swig_wrap_new_VectorVectorString__SWIG_0() (base SwigcptrVectorVectorString) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_VectorVectorString__SWIG_0, _swig_p) - return -} - -func NewVectorVectorString__SWIG_0() (_swig_ret VectorVectorString) { - return _swig_wrap_new_VectorVectorString__SWIG_0() -} - -var _wrap_new_VectorVectorString__SWIG_1 unsafe.Pointer - -func _swig_wrap_new_VectorVectorString__SWIG_1(base int64) (_ SwigcptrVectorVectorString) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_VectorVectorString__SWIG_1, _swig_p) - return -} - -func NewVectorVectorString__SWIG_1(arg1 int64) (_swig_ret VectorVectorString) { - return _swig_wrap_new_VectorVectorString__SWIG_1(arg1) -} - -func NewVectorVectorString(a ...interface{}) VectorVectorString { - argc := len(a) - if argc == 0 { - return NewVectorVectorString__SWIG_0() - } - if argc == 1 { - return NewVectorVectorString__SWIG_1(a[0].(int64)) - } - panic("No match for overloaded function call") -} - -var _wrap_VectorVectorString_size unsafe.Pointer - -func _swig_wrap_VectorVectorString_size(base SwigcptrVectorVectorString) (_ int64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_VectorVectorString_size, _swig_p) - return -} - -func (arg1 SwigcptrVectorVectorString) Size() (_swig_ret int64) { - return _swig_wrap_VectorVectorString_size(arg1) -} - -var _wrap_VectorVectorString_capacity unsafe.Pointer - -func _swig_wrap_VectorVectorString_capacity(base SwigcptrVectorVectorString) (_ int64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_VectorVectorString_capacity, _swig_p) - return -} - -func (arg1 SwigcptrVectorVectorString) Capacity() (_swig_ret int64) { - return _swig_wrap_VectorVectorString_capacity(arg1) -} - -var _wrap_VectorVectorString_reserve unsafe.Pointer - -func _swig_wrap_VectorVectorString_reserve(base SwigcptrVectorVectorString, _ int64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_VectorVectorString_reserve, _swig_p) - return -} - -func (arg1 SwigcptrVectorVectorString) Reserve(arg2 int64) { - _swig_wrap_VectorVectorString_reserve(arg1, arg2) -} - -var _wrap_VectorVectorString_isEmpty unsafe.Pointer - -func _swig_wrap_VectorVectorString_isEmpty(base SwigcptrVectorVectorString) (_ bool) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_VectorVectorString_isEmpty, _swig_p) - return -} - -func (arg1 SwigcptrVectorVectorString) IsEmpty() (_swig_ret bool) { - return _swig_wrap_VectorVectorString_isEmpty(arg1) -} - -var _wrap_VectorVectorString_clear unsafe.Pointer - -func _swig_wrap_VectorVectorString_clear(base SwigcptrVectorVectorString) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_VectorVectorString_clear, _swig_p) - return -} - -func (arg1 SwigcptrVectorVectorString) Clear() { - _swig_wrap_VectorVectorString_clear(arg1) -} - -var _wrap_VectorVectorString_add unsafe.Pointer - -func _swig_wrap_VectorVectorString_add(base SwigcptrVectorVectorString, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_VectorVectorString_add, _swig_p) - return -} - -func (arg1 SwigcptrVectorVectorString) Add(arg2 VectorString) { - _swig_wrap_VectorVectorString_add(arg1, arg2.Swigcptr()) -} - -var _wrap_VectorVectorString_get unsafe.Pointer - -func _swig_wrap_VectorVectorString_get(base SwigcptrVectorVectorString, _ int) (_ SwigcptrVectorString) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_VectorVectorString_get, _swig_p) - return -} - -func (arg1 SwigcptrVectorVectorString) Get(arg2 int) (_swig_ret VectorString) { - return _swig_wrap_VectorVectorString_get(arg1, arg2) -} - -var _wrap_VectorVectorString_set unsafe.Pointer - -func _swig_wrap_VectorVectorString_set(base SwigcptrVectorVectorString, _ int, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_VectorVectorString_set, _swig_p) - return -} - -func (arg1 SwigcptrVectorVectorString) Set(arg2 int, arg3 VectorString) { - _swig_wrap_VectorVectorString_set(arg1, arg2, arg3.Swigcptr()) -} - -var _wrap_delete_VectorVectorString unsafe.Pointer - -func _swig_wrap_delete_VectorVectorString(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_VectorVectorString, _swig_p) - return -} - -func DeleteVectorVectorString(arg1 VectorVectorString) { - _swig_wrap_delete_VectorVectorString(arg1.Swigcptr()) -} - -type VectorVectorString interface { - Swigcptr() uintptr - SwigIsVectorVectorString() - Size() (_swig_ret int64) - Capacity() (_swig_ret int64) - Reserve(arg2 int64) - IsEmpty() (_swig_ret bool) - Clear() - Add(arg2 VectorString) - Get(arg2 int) (_swig_ret VectorString) - Set(arg2 int, arg3 VectorString) -} - -type SwigcptrPairIntPairIntString uintptr - -func (p SwigcptrPairIntPairIntString) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrPairIntPairIntString) SwigIsPairIntPairIntString() { -} - -var _wrap_new_PairIntPairIntString__SWIG_0 unsafe.Pointer - -func _swig_wrap_new_PairIntPairIntString__SWIG_0() (base SwigcptrPairIntPairIntString) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_PairIntPairIntString__SWIG_0, _swig_p) - return -} - -func NewPairIntPairIntString__SWIG_0() (_swig_ret PairIntPairIntString) { - return _swig_wrap_new_PairIntPairIntString__SWIG_0() -} - -var _wrap_new_PairIntPairIntString__SWIG_1 unsafe.Pointer - -func _swig_wrap_new_PairIntPairIntString__SWIG_1(base int, _ uintptr) (_ SwigcptrPairIntPairIntString) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_PairIntPairIntString__SWIG_1, _swig_p) - return -} - -func NewPairIntPairIntString__SWIG_1(arg1 int, arg2 PairIntString) (_swig_ret PairIntPairIntString) { - return _swig_wrap_new_PairIntPairIntString__SWIG_1(arg1, arg2.Swigcptr()) -} - -var _wrap_new_PairIntPairIntString__SWIG_2 unsafe.Pointer - -func _swig_wrap_new_PairIntPairIntString__SWIG_2(base uintptr) (_ SwigcptrPairIntPairIntString) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_PairIntPairIntString__SWIG_2, _swig_p) - return -} - -func NewPairIntPairIntString__SWIG_2(arg1 PairIntPairIntString) (_swig_ret PairIntPairIntString) { - return _swig_wrap_new_PairIntPairIntString__SWIG_2(arg1.Swigcptr()) -} - -func NewPairIntPairIntString(a ...interface{}) PairIntPairIntString { - argc := len(a) - if argc == 0 { - return NewPairIntPairIntString__SWIG_0() - } - if argc == 1 { - return NewPairIntPairIntString__SWIG_2(a[0].(PairIntPairIntString)) - } - if argc == 2 { - return NewPairIntPairIntString__SWIG_1(a[0].(int), a[1].(PairIntString)) - } - panic("No match for overloaded function call") -} - -var _wrap_PairIntPairIntString_first_set unsafe.Pointer - -func _swig_wrap_PairIntPairIntString_first_set(base SwigcptrPairIntPairIntString, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_PairIntPairIntString_first_set, _swig_p) - return -} - -func (arg1 SwigcptrPairIntPairIntString) SetFirst(arg2 int) { - _swig_wrap_PairIntPairIntString_first_set(arg1, arg2) -} - -var _wrap_PairIntPairIntString_first_get unsafe.Pointer - -func _swig_wrap_PairIntPairIntString_first_get(base SwigcptrPairIntPairIntString) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_PairIntPairIntString_first_get, _swig_p) - return -} - -func (arg1 SwigcptrPairIntPairIntString) GetFirst() (_swig_ret int) { - return _swig_wrap_PairIntPairIntString_first_get(arg1) -} - -var _wrap_PairIntPairIntString_second_set unsafe.Pointer - -func _swig_wrap_PairIntPairIntString_second_set(base SwigcptrPairIntPairIntString, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_PairIntPairIntString_second_set, _swig_p) - return -} - -func (arg1 SwigcptrPairIntPairIntString) SetSecond(arg2 PairIntString) { - _swig_wrap_PairIntPairIntString_second_set(arg1, arg2.Swigcptr()) -} - -var _wrap_PairIntPairIntString_second_get unsafe.Pointer - -func _swig_wrap_PairIntPairIntString_second_get(base SwigcptrPairIntPairIntString) (_ SwigcptrPairIntString) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_PairIntPairIntString_second_get, _swig_p) - return -} - -func (arg1 SwigcptrPairIntPairIntString) GetSecond() (_swig_ret PairIntString) { - return _swig_wrap_PairIntPairIntString_second_get(arg1) -} - -var _wrap_delete_PairIntPairIntString unsafe.Pointer - -func _swig_wrap_delete_PairIntPairIntString(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_PairIntPairIntString, _swig_p) - return -} - -func DeletePairIntPairIntString(arg1 PairIntPairIntString) { - _swig_wrap_delete_PairIntPairIntString(arg1.Swigcptr()) -} - -type PairIntPairIntString interface { - Swigcptr() uintptr - SwigIsPairIntPairIntString() - SetFirst(arg2 int) - GetFirst() (_swig_ret int) - SetSecond(arg2 PairIntString) - GetSecond() (_swig_ret PairIntString) -} - -type SwigcptrPairDoubleString uintptr - -func (p SwigcptrPairDoubleString) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrPairDoubleString) SwigIsPairDoubleString() { -} - -var _wrap_new_PairDoubleString__SWIG_0 unsafe.Pointer - -func _swig_wrap_new_PairDoubleString__SWIG_0() (base SwigcptrPairDoubleString) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_PairDoubleString__SWIG_0, _swig_p) - return -} - -func NewPairDoubleString__SWIG_0() (_swig_ret PairDoubleString) { - return _swig_wrap_new_PairDoubleString__SWIG_0() -} - -var _wrap_new_PairDoubleString__SWIG_1 unsafe.Pointer - -func _swig_wrap_new_PairDoubleString__SWIG_1(base float64, _ string) (_ SwigcptrPairDoubleString) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_PairDoubleString__SWIG_1, _swig_p) - return -} - -func NewPairDoubleString__SWIG_1(arg1 float64, arg2 string) (_swig_ret PairDoubleString) { - return _swig_wrap_new_PairDoubleString__SWIG_1(arg1, arg2) -} - -var _wrap_new_PairDoubleString__SWIG_2 unsafe.Pointer - -func _swig_wrap_new_PairDoubleString__SWIG_2(base uintptr) (_ SwigcptrPairDoubleString) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_PairDoubleString__SWIG_2, _swig_p) - return -} - -func NewPairDoubleString__SWIG_2(arg1 PairDoubleString) (_swig_ret PairDoubleString) { - return _swig_wrap_new_PairDoubleString__SWIG_2(arg1.Swigcptr()) -} - -func NewPairDoubleString(a ...interface{}) PairDoubleString { - argc := len(a) - if argc == 0 { - return NewPairDoubleString__SWIG_0() - } - if argc == 1 { - return NewPairDoubleString__SWIG_2(a[0].(PairDoubleString)) - } - if argc == 2 { - return NewPairDoubleString__SWIG_1(a[0].(float64), a[1].(string)) - } - panic("No match for overloaded function call") -} - -var _wrap_PairDoubleString_first_set unsafe.Pointer - -func _swig_wrap_PairDoubleString_first_set(base SwigcptrPairDoubleString, _ float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_PairDoubleString_first_set, _swig_p) - return -} - -func (arg1 SwigcptrPairDoubleString) SetFirst(arg2 float64) { - _swig_wrap_PairDoubleString_first_set(arg1, arg2) -} - -var _wrap_PairDoubleString_first_get unsafe.Pointer - -func _swig_wrap_PairDoubleString_first_get(base SwigcptrPairDoubleString) (_ float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_PairDoubleString_first_get, _swig_p) - return -} - -func (arg1 SwigcptrPairDoubleString) GetFirst() (_swig_ret float64) { - return _swig_wrap_PairDoubleString_first_get(arg1) -} - -var _wrap_PairDoubleString_second_set unsafe.Pointer - -func _swig_wrap_PairDoubleString_second_set(base SwigcptrPairDoubleString, _ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_PairDoubleString_second_set, _swig_p) - return -} - -func (arg1 SwigcptrPairDoubleString) SetSecond(arg2 string) { - _swig_wrap_PairDoubleString_second_set(arg1, arg2) -} - -var _wrap_PairDoubleString_second_get unsafe.Pointer - -func _swig_wrap_PairDoubleString_second_get(base SwigcptrPairDoubleString) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_PairDoubleString_second_get, _swig_p) - return -} - -func (arg1 SwigcptrPairDoubleString) GetSecond() (_swig_ret string) { - return _swig_wrap_PairDoubleString_second_get(arg1) -} - -var _wrap_delete_PairDoubleString unsafe.Pointer - -func _swig_wrap_delete_PairDoubleString(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_PairDoubleString, _swig_p) - return -} - -func DeletePairDoubleString(arg1 PairDoubleString) { - _swig_wrap_delete_PairDoubleString(arg1.Swigcptr()) -} - -type PairDoubleString interface { - Swigcptr() uintptr - SwigIsPairDoubleString() - SetFirst(arg2 float64) - GetFirst() (_swig_ret float64) - SetSecond(arg2 string) - GetSecond() (_swig_ret string) -} - -type SwigcptrVectorPairDoubleString uintptr - -func (p SwigcptrVectorPairDoubleString) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrVectorPairDoubleString) SwigIsVectorPairDoubleString() { -} - -var _wrap_new_VectorPairDoubleString__SWIG_0 unsafe.Pointer - -func _swig_wrap_new_VectorPairDoubleString__SWIG_0() (base SwigcptrVectorPairDoubleString) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_VectorPairDoubleString__SWIG_0, _swig_p) - return -} - -func NewVectorPairDoubleString__SWIG_0() (_swig_ret VectorPairDoubleString) { - return _swig_wrap_new_VectorPairDoubleString__SWIG_0() -} - -var _wrap_new_VectorPairDoubleString__SWIG_1 unsafe.Pointer - -func _swig_wrap_new_VectorPairDoubleString__SWIG_1(base int64) (_ SwigcptrVectorPairDoubleString) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_VectorPairDoubleString__SWIG_1, _swig_p) - return -} - -func NewVectorPairDoubleString__SWIG_1(arg1 int64) (_swig_ret VectorPairDoubleString) { - return _swig_wrap_new_VectorPairDoubleString__SWIG_1(arg1) -} - -func NewVectorPairDoubleString(a ...interface{}) VectorPairDoubleString { - argc := len(a) - if argc == 0 { - return NewVectorPairDoubleString__SWIG_0() - } - if argc == 1 { - return NewVectorPairDoubleString__SWIG_1(a[0].(int64)) - } - panic("No match for overloaded function call") -} - -var _wrap_VectorPairDoubleString_size unsafe.Pointer - -func _swig_wrap_VectorPairDoubleString_size(base SwigcptrVectorPairDoubleString) (_ int64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_VectorPairDoubleString_size, _swig_p) - return -} - -func (arg1 SwigcptrVectorPairDoubleString) Size() (_swig_ret int64) { - return _swig_wrap_VectorPairDoubleString_size(arg1) -} - -var _wrap_VectorPairDoubleString_capacity unsafe.Pointer - -func _swig_wrap_VectorPairDoubleString_capacity(base SwigcptrVectorPairDoubleString) (_ int64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_VectorPairDoubleString_capacity, _swig_p) - return -} - -func (arg1 SwigcptrVectorPairDoubleString) Capacity() (_swig_ret int64) { - return _swig_wrap_VectorPairDoubleString_capacity(arg1) -} - -var _wrap_VectorPairDoubleString_reserve unsafe.Pointer - -func _swig_wrap_VectorPairDoubleString_reserve(base SwigcptrVectorPairDoubleString, _ int64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_VectorPairDoubleString_reserve, _swig_p) - return -} - -func (arg1 SwigcptrVectorPairDoubleString) Reserve(arg2 int64) { - _swig_wrap_VectorPairDoubleString_reserve(arg1, arg2) -} - -var _wrap_VectorPairDoubleString_isEmpty unsafe.Pointer - -func _swig_wrap_VectorPairDoubleString_isEmpty(base SwigcptrVectorPairDoubleString) (_ bool) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_VectorPairDoubleString_isEmpty, _swig_p) - return -} - -func (arg1 SwigcptrVectorPairDoubleString) IsEmpty() (_swig_ret bool) { - return _swig_wrap_VectorPairDoubleString_isEmpty(arg1) -} - -var _wrap_VectorPairDoubleString_clear unsafe.Pointer - -func _swig_wrap_VectorPairDoubleString_clear(base SwigcptrVectorPairDoubleString) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_VectorPairDoubleString_clear, _swig_p) - return -} - -func (arg1 SwigcptrVectorPairDoubleString) Clear() { - _swig_wrap_VectorPairDoubleString_clear(arg1) -} - -var _wrap_VectorPairDoubleString_add unsafe.Pointer - -func _swig_wrap_VectorPairDoubleString_add(base SwigcptrVectorPairDoubleString, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_VectorPairDoubleString_add, _swig_p) - return -} - -func (arg1 SwigcptrVectorPairDoubleString) Add(arg2 PairDoubleString) { - _swig_wrap_VectorPairDoubleString_add(arg1, arg2.Swigcptr()) -} - -var _wrap_VectorPairDoubleString_get unsafe.Pointer - -func _swig_wrap_VectorPairDoubleString_get(base SwigcptrVectorPairDoubleString, _ int) (_ SwigcptrPairDoubleString) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_VectorPairDoubleString_get, _swig_p) - return -} - -func (arg1 SwigcptrVectorPairDoubleString) Get(arg2 int) (_swig_ret PairDoubleString) { - return _swig_wrap_VectorPairDoubleString_get(arg1, arg2) -} - -var _wrap_VectorPairDoubleString_set unsafe.Pointer - -func _swig_wrap_VectorPairDoubleString_set(base SwigcptrVectorPairDoubleString, _ int, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_VectorPairDoubleString_set, _swig_p) - return -} - -func (arg1 SwigcptrVectorPairDoubleString) Set(arg2 int, arg3 PairDoubleString) { - _swig_wrap_VectorPairDoubleString_set(arg1, arg2, arg3.Swigcptr()) -} - -var _wrap_delete_VectorPairDoubleString unsafe.Pointer - -func _swig_wrap_delete_VectorPairDoubleString(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_VectorPairDoubleString, _swig_p) - return -} - -func DeleteVectorPairDoubleString(arg1 VectorPairDoubleString) { - _swig_wrap_delete_VectorPairDoubleString(arg1.Swigcptr()) -} - -type VectorPairDoubleString interface { - Swigcptr() uintptr - SwigIsVectorPairDoubleString() - Size() (_swig_ret int64) - Capacity() (_swig_ret int64) - Reserve(arg2 int64) - IsEmpty() (_swig_ret bool) - Clear() - Add(arg2 PairDoubleString) - Get(arg2 int) (_swig_ret PairDoubleString) - Set(arg2 int, arg3 PairDoubleString) -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/li_std_deque.go b/Examples/test-suite/go/li_std_deque.go deleted file mode 100644 index 21aef968e..000000000 --- a/Examples/test-suite/go/li_std_deque.go +++ /dev/null @@ -1,1174 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../li_std_deque.i - -package li_std_deque - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrIntDeque uintptr - -func (p SwigcptrIntDeque) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrIntDeque) SwigIsIntDeque() { -} - -var _wrap_IntDeque_empty unsafe.Pointer - -func _swig_wrap_IntDeque_empty(base SwigcptrIntDeque) (_ bool) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_IntDeque_empty, _swig_p) - return -} - -func (arg1 SwigcptrIntDeque) Empty() (_swig_ret bool) { - return _swig_wrap_IntDeque_empty(arg1) -} - -var _wrap_new_IntDeque__SWIG_0 unsafe.Pointer - -func _swig_wrap_new_IntDeque__SWIG_0() (base SwigcptrIntDeque) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_IntDeque__SWIG_0, _swig_p) - return -} - -func NewIntDeque__SWIG_0() (_swig_ret IntDeque) { - return _swig_wrap_new_IntDeque__SWIG_0() -} - -var _wrap_new_IntDeque__SWIG_1 unsafe.Pointer - -func _swig_wrap_new_IntDeque__SWIG_1(base uint, _ int) (_ SwigcptrIntDeque) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_IntDeque__SWIG_1, _swig_p) - return -} - -func NewIntDeque__SWIG_1(arg1 uint, arg2 int) (_swig_ret IntDeque) { - return _swig_wrap_new_IntDeque__SWIG_1(arg1, arg2) -} - -var _wrap_new_IntDeque__SWIG_2 unsafe.Pointer - -func _swig_wrap_new_IntDeque__SWIG_2(base uint) (_ SwigcptrIntDeque) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_IntDeque__SWIG_2, _swig_p) - return -} - -func NewIntDeque__SWIG_2(arg1 uint) (_swig_ret IntDeque) { - return _swig_wrap_new_IntDeque__SWIG_2(arg1) -} - -var _wrap_new_IntDeque__SWIG_3 unsafe.Pointer - -func _swig_wrap_new_IntDeque__SWIG_3(base uintptr) (_ SwigcptrIntDeque) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_IntDeque__SWIG_3, _swig_p) - return -} - -func NewIntDeque__SWIG_3(arg1 IntDeque) (_swig_ret IntDeque) { - return _swig_wrap_new_IntDeque__SWIG_3(arg1.Swigcptr()) -} - -func NewIntDeque(a ...interface{}) IntDeque { - argc := len(a) - if argc == 0 { - return NewIntDeque__SWIG_0() - } - if argc == 1 { - if _, ok := a[0].(IntDeque); !ok { - goto check_2 - } - return NewIntDeque__SWIG_3(a[0].(IntDeque)) - } -check_2: - if argc == 1 { - return NewIntDeque__SWIG_2(a[0].(uint)) - } - if argc == 2 { - return NewIntDeque__SWIG_1(a[0].(uint), a[1].(int)) - } - panic("No match for overloaded function call") -} - -var _wrap_delete_IntDeque unsafe.Pointer - -func _swig_wrap_delete_IntDeque(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_IntDeque, _swig_p) - return -} - -func DeleteIntDeque(arg1 IntDeque) { - _swig_wrap_delete_IntDeque(arg1.Swigcptr()) -} - -var _wrap_IntDeque_assign unsafe.Pointer - -func _swig_wrap_IntDeque_assign(base SwigcptrIntDeque, _ uint, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_IntDeque_assign, _swig_p) - return -} - -func (arg1 SwigcptrIntDeque) Assign(arg2 uint, arg3 int) { - _swig_wrap_IntDeque_assign(arg1, arg2, arg3) -} - -var _wrap_IntDeque_swap unsafe.Pointer - -func _swig_wrap_IntDeque_swap(base SwigcptrIntDeque, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_IntDeque_swap, _swig_p) - return -} - -func (arg1 SwigcptrIntDeque) Swap(arg2 IntDeque) { - _swig_wrap_IntDeque_swap(arg1, arg2.Swigcptr()) -} - -var _wrap_IntDeque_size unsafe.Pointer - -func _swig_wrap_IntDeque_size(base SwigcptrIntDeque) (_ uint) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_IntDeque_size, _swig_p) - return -} - -func (arg1 SwigcptrIntDeque) Size() (_swig_ret uint) { - return _swig_wrap_IntDeque_size(arg1) -} - -var _wrap_IntDeque_max_size unsafe.Pointer - -func _swig_wrap_IntDeque_max_size(base SwigcptrIntDeque) (_ uint) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_IntDeque_max_size, _swig_p) - return -} - -func (arg1 SwigcptrIntDeque) Max_size() (_swig_ret uint) { - return _swig_wrap_IntDeque_max_size(arg1) -} - -var _wrap_IntDeque_resize__SWIG_0 unsafe.Pointer - -func _swig_wrap_IntDeque_resize__SWIG_0(base SwigcptrIntDeque, _ uint, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_IntDeque_resize__SWIG_0, _swig_p) - return -} - -func (arg1 SwigcptrIntDeque) Resize__SWIG_0(arg2 uint, arg3 int) { - _swig_wrap_IntDeque_resize__SWIG_0(arg1, arg2, arg3) -} - -var _wrap_IntDeque_resize__SWIG_1 unsafe.Pointer - -func _swig_wrap_IntDeque_resize__SWIG_1(base SwigcptrIntDeque, _ uint) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_IntDeque_resize__SWIG_1, _swig_p) - return -} - -func (arg1 SwigcptrIntDeque) Resize__SWIG_1(arg2 uint) { - _swig_wrap_IntDeque_resize__SWIG_1(arg1, arg2) -} - -func (p SwigcptrIntDeque) Resize(a ...interface{}) { - argc := len(a) - if argc == 1 { - p.Resize__SWIG_1(a[0].(uint)) - return - } - if argc == 2 { - p.Resize__SWIG_0(a[0].(uint), a[1].(int)) - return - } - panic("No match for overloaded function call") -} - -var _wrap_IntDeque_front unsafe.Pointer - -func _swig_wrap_IntDeque_front(base SwigcptrIntDeque) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_IntDeque_front, _swig_p) - return -} - -func (arg1 SwigcptrIntDeque) Front() (_swig_ret int) { - return _swig_wrap_IntDeque_front(arg1) -} - -var _wrap_IntDeque_back unsafe.Pointer - -func _swig_wrap_IntDeque_back(base SwigcptrIntDeque) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_IntDeque_back, _swig_p) - return -} - -func (arg1 SwigcptrIntDeque) Back() (_swig_ret int) { - return _swig_wrap_IntDeque_back(arg1) -} - -var _wrap_IntDeque_push_front unsafe.Pointer - -func _swig_wrap_IntDeque_push_front(base SwigcptrIntDeque, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_IntDeque_push_front, _swig_p) - return -} - -func (arg1 SwigcptrIntDeque) Push_front(arg2 int) { - _swig_wrap_IntDeque_push_front(arg1, arg2) -} - -var _wrap_IntDeque_push_back unsafe.Pointer - -func _swig_wrap_IntDeque_push_back(base SwigcptrIntDeque, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_IntDeque_push_back, _swig_p) - return -} - -func (arg1 SwigcptrIntDeque) Push_back(arg2 int) { - _swig_wrap_IntDeque_push_back(arg1, arg2) -} - -var _wrap_IntDeque_pop_front unsafe.Pointer - -func _swig_wrap_IntDeque_pop_front(base SwigcptrIntDeque) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_IntDeque_pop_front, _swig_p) - return -} - -func (arg1 SwigcptrIntDeque) Pop_front() { - _swig_wrap_IntDeque_pop_front(arg1) -} - -var _wrap_IntDeque_pop_back unsafe.Pointer - -func _swig_wrap_IntDeque_pop_back(base SwigcptrIntDeque) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_IntDeque_pop_back, _swig_p) - return -} - -func (arg1 SwigcptrIntDeque) Pop_back() { - _swig_wrap_IntDeque_pop_back(arg1) -} - -var _wrap_IntDeque_clear unsafe.Pointer - -func _swig_wrap_IntDeque_clear(base SwigcptrIntDeque) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_IntDeque_clear, _swig_p) - return -} - -func (arg1 SwigcptrIntDeque) Clear() { - _swig_wrap_IntDeque_clear(arg1) -} - -var _wrap_IntDeque_getitem unsafe.Pointer - -func _swig_wrap_IntDeque_getitem(base SwigcptrIntDeque, _ int) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_IntDeque_getitem, _swig_p) - return -} - -func (arg1 SwigcptrIntDeque) Getitem(arg2 int) (_swig_ret int) { - return _swig_wrap_IntDeque_getitem(arg1, arg2) -} - -var _wrap_IntDeque_setitem unsafe.Pointer - -func _swig_wrap_IntDeque_setitem(base SwigcptrIntDeque, _ int, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_IntDeque_setitem, _swig_p) - return -} - -func (arg1 SwigcptrIntDeque) Setitem(arg2 int, arg3 int) { - _swig_wrap_IntDeque_setitem(arg1, arg2, arg3) -} - -var _wrap_IntDeque_delitem unsafe.Pointer - -func _swig_wrap_IntDeque_delitem(base SwigcptrIntDeque, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_IntDeque_delitem, _swig_p) - return -} - -func (arg1 SwigcptrIntDeque) Delitem(arg2 int) { - _swig_wrap_IntDeque_delitem(arg1, arg2) -} - -var _wrap_IntDeque_getslice unsafe.Pointer - -func _swig_wrap_IntDeque_getslice(base SwigcptrIntDeque, _ int, _ int) (_ SwigcptrIntDeque) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_IntDeque_getslice, _swig_p) - return -} - -func (arg1 SwigcptrIntDeque) Getslice(arg2 int, arg3 int) (_swig_ret IntDeque) { - return _swig_wrap_IntDeque_getslice(arg1, arg2, arg3) -} - -var _wrap_IntDeque_setslice unsafe.Pointer - -func _swig_wrap_IntDeque_setslice(base SwigcptrIntDeque, _ int, _ int, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_IntDeque_setslice, _swig_p) - return -} - -func (arg1 SwigcptrIntDeque) Setslice(arg2 int, arg3 int, arg4 IntDeque) { - _swig_wrap_IntDeque_setslice(arg1, arg2, arg3, arg4.Swigcptr()) -} - -var _wrap_IntDeque_delslice unsafe.Pointer - -func _swig_wrap_IntDeque_delslice(base SwigcptrIntDeque, _ int, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_IntDeque_delslice, _swig_p) - return -} - -func (arg1 SwigcptrIntDeque) Delslice(arg2 int, arg3 int) { - _swig_wrap_IntDeque_delslice(arg1, arg2, arg3) -} - -type IntDeque interface { - Swigcptr() uintptr - SwigIsIntDeque() - Empty() (_swig_ret bool) - Assign(arg2 uint, arg3 int) - Swap(arg2 IntDeque) - Size() (_swig_ret uint) - Max_size() (_swig_ret uint) - Resize(a ...interface{}) - Front() (_swig_ret int) - Back() (_swig_ret int) - Push_front(arg2 int) - Push_back(arg2 int) - Pop_front() - Pop_back() - Clear() - Getitem(arg2 int) (_swig_ret int) - Setitem(arg2 int, arg3 int) - Delitem(arg2 int) - Getslice(arg2 int, arg3 int) (_swig_ret IntDeque) - Setslice(arg2 int, arg3 int, arg4 IntDeque) - Delslice(arg2 int, arg3 int) -} - -type SwigcptrDoubleDeque uintptr - -func (p SwigcptrDoubleDeque) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrDoubleDeque) SwigIsDoubleDeque() { -} - -var _wrap_DoubleDeque_empty unsafe.Pointer - -func _swig_wrap_DoubleDeque_empty(base SwigcptrDoubleDeque) (_ bool) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_DoubleDeque_empty, _swig_p) - return -} - -func (arg1 SwigcptrDoubleDeque) Empty() (_swig_ret bool) { - return _swig_wrap_DoubleDeque_empty(arg1) -} - -var _wrap_new_DoubleDeque__SWIG_0 unsafe.Pointer - -func _swig_wrap_new_DoubleDeque__SWIG_0() (base SwigcptrDoubleDeque) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_DoubleDeque__SWIG_0, _swig_p) - return -} - -func NewDoubleDeque__SWIG_0() (_swig_ret DoubleDeque) { - return _swig_wrap_new_DoubleDeque__SWIG_0() -} - -var _wrap_new_DoubleDeque__SWIG_1 unsafe.Pointer - -func _swig_wrap_new_DoubleDeque__SWIG_1(base uint, _ float64) (_ SwigcptrDoubleDeque) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_DoubleDeque__SWIG_1, _swig_p) - return -} - -func NewDoubleDeque__SWIG_1(arg1 uint, arg2 float64) (_swig_ret DoubleDeque) { - return _swig_wrap_new_DoubleDeque__SWIG_1(arg1, arg2) -} - -var _wrap_new_DoubleDeque__SWIG_2 unsafe.Pointer - -func _swig_wrap_new_DoubleDeque__SWIG_2(base uint) (_ SwigcptrDoubleDeque) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_DoubleDeque__SWIG_2, _swig_p) - return -} - -func NewDoubleDeque__SWIG_2(arg1 uint) (_swig_ret DoubleDeque) { - return _swig_wrap_new_DoubleDeque__SWIG_2(arg1) -} - -var _wrap_new_DoubleDeque__SWIG_3 unsafe.Pointer - -func _swig_wrap_new_DoubleDeque__SWIG_3(base uintptr) (_ SwigcptrDoubleDeque) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_DoubleDeque__SWIG_3, _swig_p) - return -} - -func NewDoubleDeque__SWIG_3(arg1 DoubleDeque) (_swig_ret DoubleDeque) { - return _swig_wrap_new_DoubleDeque__SWIG_3(arg1.Swigcptr()) -} - -func NewDoubleDeque(a ...interface{}) DoubleDeque { - argc := len(a) - if argc == 0 { - return NewDoubleDeque__SWIG_0() - } - if argc == 1 { - if _, ok := a[0].(DoubleDeque); !ok { - goto check_2 - } - return NewDoubleDeque__SWIG_3(a[0].(DoubleDeque)) - } -check_2: - if argc == 1 { - return NewDoubleDeque__SWIG_2(a[0].(uint)) - } - if argc == 2 { - return NewDoubleDeque__SWIG_1(a[0].(uint), a[1].(float64)) - } - panic("No match for overloaded function call") -} - -var _wrap_delete_DoubleDeque unsafe.Pointer - -func _swig_wrap_delete_DoubleDeque(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_DoubleDeque, _swig_p) - return -} - -func DeleteDoubleDeque(arg1 DoubleDeque) { - _swig_wrap_delete_DoubleDeque(arg1.Swigcptr()) -} - -var _wrap_DoubleDeque_assign unsafe.Pointer - -func _swig_wrap_DoubleDeque_assign(base SwigcptrDoubleDeque, _ uint, _ float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_DoubleDeque_assign, _swig_p) - return -} - -func (arg1 SwigcptrDoubleDeque) Assign(arg2 uint, arg3 float64) { - _swig_wrap_DoubleDeque_assign(arg1, arg2, arg3) -} - -var _wrap_DoubleDeque_swap unsafe.Pointer - -func _swig_wrap_DoubleDeque_swap(base SwigcptrDoubleDeque, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_DoubleDeque_swap, _swig_p) - return -} - -func (arg1 SwigcptrDoubleDeque) Swap(arg2 DoubleDeque) { - _swig_wrap_DoubleDeque_swap(arg1, arg2.Swigcptr()) -} - -var _wrap_DoubleDeque_size unsafe.Pointer - -func _swig_wrap_DoubleDeque_size(base SwigcptrDoubleDeque) (_ uint) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_DoubleDeque_size, _swig_p) - return -} - -func (arg1 SwigcptrDoubleDeque) Size() (_swig_ret uint) { - return _swig_wrap_DoubleDeque_size(arg1) -} - -var _wrap_DoubleDeque_max_size unsafe.Pointer - -func _swig_wrap_DoubleDeque_max_size(base SwigcptrDoubleDeque) (_ uint) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_DoubleDeque_max_size, _swig_p) - return -} - -func (arg1 SwigcptrDoubleDeque) Max_size() (_swig_ret uint) { - return _swig_wrap_DoubleDeque_max_size(arg1) -} - -var _wrap_DoubleDeque_resize__SWIG_0 unsafe.Pointer - -func _swig_wrap_DoubleDeque_resize__SWIG_0(base SwigcptrDoubleDeque, _ uint, _ float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_DoubleDeque_resize__SWIG_0, _swig_p) - return -} - -func (arg1 SwigcptrDoubleDeque) Resize__SWIG_0(arg2 uint, arg3 float64) { - _swig_wrap_DoubleDeque_resize__SWIG_0(arg1, arg2, arg3) -} - -var _wrap_DoubleDeque_resize__SWIG_1 unsafe.Pointer - -func _swig_wrap_DoubleDeque_resize__SWIG_1(base SwigcptrDoubleDeque, _ uint) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_DoubleDeque_resize__SWIG_1, _swig_p) - return -} - -func (arg1 SwigcptrDoubleDeque) Resize__SWIG_1(arg2 uint) { - _swig_wrap_DoubleDeque_resize__SWIG_1(arg1, arg2) -} - -func (p SwigcptrDoubleDeque) Resize(a ...interface{}) { - argc := len(a) - if argc == 1 { - p.Resize__SWIG_1(a[0].(uint)) - return - } - if argc == 2 { - p.Resize__SWIG_0(a[0].(uint), a[1].(float64)) - return - } - panic("No match for overloaded function call") -} - -var _wrap_DoubleDeque_front unsafe.Pointer - -func _swig_wrap_DoubleDeque_front(base SwigcptrDoubleDeque) (_ float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_DoubleDeque_front, _swig_p) - return -} - -func (arg1 SwigcptrDoubleDeque) Front() (_swig_ret float64) { - return _swig_wrap_DoubleDeque_front(arg1) -} - -var _wrap_DoubleDeque_back unsafe.Pointer - -func _swig_wrap_DoubleDeque_back(base SwigcptrDoubleDeque) (_ float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_DoubleDeque_back, _swig_p) - return -} - -func (arg1 SwigcptrDoubleDeque) Back() (_swig_ret float64) { - return _swig_wrap_DoubleDeque_back(arg1) -} - -var _wrap_DoubleDeque_push_front unsafe.Pointer - -func _swig_wrap_DoubleDeque_push_front(base SwigcptrDoubleDeque, _ float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_DoubleDeque_push_front, _swig_p) - return -} - -func (arg1 SwigcptrDoubleDeque) Push_front(arg2 float64) { - _swig_wrap_DoubleDeque_push_front(arg1, arg2) -} - -var _wrap_DoubleDeque_push_back unsafe.Pointer - -func _swig_wrap_DoubleDeque_push_back(base SwigcptrDoubleDeque, _ float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_DoubleDeque_push_back, _swig_p) - return -} - -func (arg1 SwigcptrDoubleDeque) Push_back(arg2 float64) { - _swig_wrap_DoubleDeque_push_back(arg1, arg2) -} - -var _wrap_DoubleDeque_pop_front unsafe.Pointer - -func _swig_wrap_DoubleDeque_pop_front(base SwigcptrDoubleDeque) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_DoubleDeque_pop_front, _swig_p) - return -} - -func (arg1 SwigcptrDoubleDeque) Pop_front() { - _swig_wrap_DoubleDeque_pop_front(arg1) -} - -var _wrap_DoubleDeque_pop_back unsafe.Pointer - -func _swig_wrap_DoubleDeque_pop_back(base SwigcptrDoubleDeque) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_DoubleDeque_pop_back, _swig_p) - return -} - -func (arg1 SwigcptrDoubleDeque) Pop_back() { - _swig_wrap_DoubleDeque_pop_back(arg1) -} - -var _wrap_DoubleDeque_clear unsafe.Pointer - -func _swig_wrap_DoubleDeque_clear(base SwigcptrDoubleDeque) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_DoubleDeque_clear, _swig_p) - return -} - -func (arg1 SwigcptrDoubleDeque) Clear() { - _swig_wrap_DoubleDeque_clear(arg1) -} - -var _wrap_DoubleDeque_getitem unsafe.Pointer - -func _swig_wrap_DoubleDeque_getitem(base SwigcptrDoubleDeque, _ int) (_ float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_DoubleDeque_getitem, _swig_p) - return -} - -func (arg1 SwigcptrDoubleDeque) Getitem(arg2 int) (_swig_ret float64) { - return _swig_wrap_DoubleDeque_getitem(arg1, arg2) -} - -var _wrap_DoubleDeque_setitem unsafe.Pointer - -func _swig_wrap_DoubleDeque_setitem(base SwigcptrDoubleDeque, _ int, _ float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_DoubleDeque_setitem, _swig_p) - return -} - -func (arg1 SwigcptrDoubleDeque) Setitem(arg2 int, arg3 float64) { - _swig_wrap_DoubleDeque_setitem(arg1, arg2, arg3) -} - -var _wrap_DoubleDeque_delitem unsafe.Pointer - -func _swig_wrap_DoubleDeque_delitem(base SwigcptrDoubleDeque, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_DoubleDeque_delitem, _swig_p) - return -} - -func (arg1 SwigcptrDoubleDeque) Delitem(arg2 int) { - _swig_wrap_DoubleDeque_delitem(arg1, arg2) -} - -var _wrap_DoubleDeque_getslice unsafe.Pointer - -func _swig_wrap_DoubleDeque_getslice(base SwigcptrDoubleDeque, _ int, _ int) (_ SwigcptrDoubleDeque) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_DoubleDeque_getslice, _swig_p) - return -} - -func (arg1 SwigcptrDoubleDeque) Getslice(arg2 int, arg3 int) (_swig_ret DoubleDeque) { - return _swig_wrap_DoubleDeque_getslice(arg1, arg2, arg3) -} - -var _wrap_DoubleDeque_setslice unsafe.Pointer - -func _swig_wrap_DoubleDeque_setslice(base SwigcptrDoubleDeque, _ int, _ int, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_DoubleDeque_setslice, _swig_p) - return -} - -func (arg1 SwigcptrDoubleDeque) Setslice(arg2 int, arg3 int, arg4 DoubleDeque) { - _swig_wrap_DoubleDeque_setslice(arg1, arg2, arg3, arg4.Swigcptr()) -} - -var _wrap_DoubleDeque_delslice unsafe.Pointer - -func _swig_wrap_DoubleDeque_delslice(base SwigcptrDoubleDeque, _ int, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_DoubleDeque_delslice, _swig_p) - return -} - -func (arg1 SwigcptrDoubleDeque) Delslice(arg2 int, arg3 int) { - _swig_wrap_DoubleDeque_delslice(arg1, arg2, arg3) -} - -type DoubleDeque interface { - Swigcptr() uintptr - SwigIsDoubleDeque() - Empty() (_swig_ret bool) - Assign(arg2 uint, arg3 float64) - Swap(arg2 DoubleDeque) - Size() (_swig_ret uint) - Max_size() (_swig_ret uint) - Resize(a ...interface{}) - Front() (_swig_ret float64) - Back() (_swig_ret float64) - Push_front(arg2 float64) - Push_back(arg2 float64) - Pop_front() - Pop_back() - Clear() - Getitem(arg2 int) (_swig_ret float64) - Setitem(arg2 int, arg3 float64) - Delitem(arg2 int) - Getslice(arg2 int, arg3 int) (_swig_ret DoubleDeque) - Setslice(arg2 int, arg3 int, arg4 DoubleDeque) - Delslice(arg2 int, arg3 int) -} - -type SwigcptrRealDeque uintptr - -func (p SwigcptrRealDeque) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrRealDeque) SwigIsRealDeque() { -} - -var _wrap_RealDeque_empty unsafe.Pointer - -func _swig_wrap_RealDeque_empty(base SwigcptrRealDeque) (_ bool) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_RealDeque_empty, _swig_p) - return -} - -func (arg1 SwigcptrRealDeque) Empty() (_swig_ret bool) { - return _swig_wrap_RealDeque_empty(arg1) -} - -var _wrap_new_RealDeque__SWIG_0 unsafe.Pointer - -func _swig_wrap_new_RealDeque__SWIG_0() (base SwigcptrRealDeque) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_RealDeque__SWIG_0, _swig_p) - return -} - -func NewRealDeque__SWIG_0() (_swig_ret RealDeque) { - return _swig_wrap_new_RealDeque__SWIG_0() -} - -var _wrap_new_RealDeque__SWIG_1 unsafe.Pointer - -func _swig_wrap_new_RealDeque__SWIG_1(base uint, _ float32) (_ SwigcptrRealDeque) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_RealDeque__SWIG_1, _swig_p) - return -} - -func NewRealDeque__SWIG_1(arg1 uint, arg2 float32) (_swig_ret RealDeque) { - return _swig_wrap_new_RealDeque__SWIG_1(arg1, arg2) -} - -var _wrap_new_RealDeque__SWIG_2 unsafe.Pointer - -func _swig_wrap_new_RealDeque__SWIG_2(base uint) (_ SwigcptrRealDeque) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_RealDeque__SWIG_2, _swig_p) - return -} - -func NewRealDeque__SWIG_2(arg1 uint) (_swig_ret RealDeque) { - return _swig_wrap_new_RealDeque__SWIG_2(arg1) -} - -var _wrap_new_RealDeque__SWIG_3 unsafe.Pointer - -func _swig_wrap_new_RealDeque__SWIG_3(base uintptr) (_ SwigcptrRealDeque) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_RealDeque__SWIG_3, _swig_p) - return -} - -func NewRealDeque__SWIG_3(arg1 RealDeque) (_swig_ret RealDeque) { - return _swig_wrap_new_RealDeque__SWIG_3(arg1.Swigcptr()) -} - -func NewRealDeque(a ...interface{}) RealDeque { - argc := len(a) - if argc == 0 { - return NewRealDeque__SWIG_0() - } - if argc == 1 { - if _, ok := a[0].(RealDeque); !ok { - goto check_2 - } - return NewRealDeque__SWIG_3(a[0].(RealDeque)) - } -check_2: - if argc == 1 { - return NewRealDeque__SWIG_2(a[0].(uint)) - } - if argc == 2 { - return NewRealDeque__SWIG_1(a[0].(uint), a[1].(float32)) - } - panic("No match for overloaded function call") -} - -var _wrap_delete_RealDeque unsafe.Pointer - -func _swig_wrap_delete_RealDeque(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_RealDeque, _swig_p) - return -} - -func DeleteRealDeque(arg1 RealDeque) { - _swig_wrap_delete_RealDeque(arg1.Swigcptr()) -} - -var _wrap_RealDeque_assign unsafe.Pointer - -func _swig_wrap_RealDeque_assign(base SwigcptrRealDeque, _ uint, _ float32) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_RealDeque_assign, _swig_p) - return -} - -func (arg1 SwigcptrRealDeque) Assign(arg2 uint, arg3 float32) { - _swig_wrap_RealDeque_assign(arg1, arg2, arg3) -} - -var _wrap_RealDeque_swap unsafe.Pointer - -func _swig_wrap_RealDeque_swap(base SwigcptrRealDeque, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_RealDeque_swap, _swig_p) - return -} - -func (arg1 SwigcptrRealDeque) Swap(arg2 RealDeque) { - _swig_wrap_RealDeque_swap(arg1, arg2.Swigcptr()) -} - -var _wrap_RealDeque_size unsafe.Pointer - -func _swig_wrap_RealDeque_size(base SwigcptrRealDeque) (_ uint) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_RealDeque_size, _swig_p) - return -} - -func (arg1 SwigcptrRealDeque) Size() (_swig_ret uint) { - return _swig_wrap_RealDeque_size(arg1) -} - -var _wrap_RealDeque_max_size unsafe.Pointer - -func _swig_wrap_RealDeque_max_size(base SwigcptrRealDeque) (_ uint) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_RealDeque_max_size, _swig_p) - return -} - -func (arg1 SwigcptrRealDeque) Max_size() (_swig_ret uint) { - return _swig_wrap_RealDeque_max_size(arg1) -} - -var _wrap_RealDeque_resize__SWIG_0 unsafe.Pointer - -func _swig_wrap_RealDeque_resize__SWIG_0(base SwigcptrRealDeque, _ uint, _ float32) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_RealDeque_resize__SWIG_0, _swig_p) - return -} - -func (arg1 SwigcptrRealDeque) Resize__SWIG_0(arg2 uint, arg3 float32) { - _swig_wrap_RealDeque_resize__SWIG_0(arg1, arg2, arg3) -} - -var _wrap_RealDeque_resize__SWIG_1 unsafe.Pointer - -func _swig_wrap_RealDeque_resize__SWIG_1(base SwigcptrRealDeque, _ uint) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_RealDeque_resize__SWIG_1, _swig_p) - return -} - -func (arg1 SwigcptrRealDeque) Resize__SWIG_1(arg2 uint) { - _swig_wrap_RealDeque_resize__SWIG_1(arg1, arg2) -} - -func (p SwigcptrRealDeque) Resize(a ...interface{}) { - argc := len(a) - if argc == 1 { - p.Resize__SWIG_1(a[0].(uint)) - return - } - if argc == 2 { - p.Resize__SWIG_0(a[0].(uint), a[1].(float32)) - return - } - panic("No match for overloaded function call") -} - -var _wrap_RealDeque_front unsafe.Pointer - -func _swig_wrap_RealDeque_front(base SwigcptrRealDeque) (_ float32) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_RealDeque_front, _swig_p) - return -} - -func (arg1 SwigcptrRealDeque) Front() (_swig_ret float32) { - return _swig_wrap_RealDeque_front(arg1) -} - -var _wrap_RealDeque_back unsafe.Pointer - -func _swig_wrap_RealDeque_back(base SwigcptrRealDeque) (_ float32) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_RealDeque_back, _swig_p) - return -} - -func (arg1 SwigcptrRealDeque) Back() (_swig_ret float32) { - return _swig_wrap_RealDeque_back(arg1) -} - -var _wrap_RealDeque_push_front unsafe.Pointer - -func _swig_wrap_RealDeque_push_front(base SwigcptrRealDeque, _ float32) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_RealDeque_push_front, _swig_p) - return -} - -func (arg1 SwigcptrRealDeque) Push_front(arg2 float32) { - _swig_wrap_RealDeque_push_front(arg1, arg2) -} - -var _wrap_RealDeque_push_back unsafe.Pointer - -func _swig_wrap_RealDeque_push_back(base SwigcptrRealDeque, _ float32) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_RealDeque_push_back, _swig_p) - return -} - -func (arg1 SwigcptrRealDeque) Push_back(arg2 float32) { - _swig_wrap_RealDeque_push_back(arg1, arg2) -} - -var _wrap_RealDeque_pop_front unsafe.Pointer - -func _swig_wrap_RealDeque_pop_front(base SwigcptrRealDeque) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_RealDeque_pop_front, _swig_p) - return -} - -func (arg1 SwigcptrRealDeque) Pop_front() { - _swig_wrap_RealDeque_pop_front(arg1) -} - -var _wrap_RealDeque_pop_back unsafe.Pointer - -func _swig_wrap_RealDeque_pop_back(base SwigcptrRealDeque) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_RealDeque_pop_back, _swig_p) - return -} - -func (arg1 SwigcptrRealDeque) Pop_back() { - _swig_wrap_RealDeque_pop_back(arg1) -} - -var _wrap_RealDeque_clear unsafe.Pointer - -func _swig_wrap_RealDeque_clear(base SwigcptrRealDeque) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_RealDeque_clear, _swig_p) - return -} - -func (arg1 SwigcptrRealDeque) Clear() { - _swig_wrap_RealDeque_clear(arg1) -} - -var _wrap_RealDeque_getitem unsafe.Pointer - -func _swig_wrap_RealDeque_getitem(base SwigcptrRealDeque, _ int) (_ float32) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_RealDeque_getitem, _swig_p) - return -} - -func (arg1 SwigcptrRealDeque) Getitem(arg2 int) (_swig_ret float32) { - return _swig_wrap_RealDeque_getitem(arg1, arg2) -} - -var _wrap_RealDeque_setitem unsafe.Pointer - -func _swig_wrap_RealDeque_setitem(base SwigcptrRealDeque, _ int, _ float32) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_RealDeque_setitem, _swig_p) - return -} - -func (arg1 SwigcptrRealDeque) Setitem(arg2 int, arg3 float32) { - _swig_wrap_RealDeque_setitem(arg1, arg2, arg3) -} - -var _wrap_RealDeque_delitem unsafe.Pointer - -func _swig_wrap_RealDeque_delitem(base SwigcptrRealDeque, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_RealDeque_delitem, _swig_p) - return -} - -func (arg1 SwigcptrRealDeque) Delitem(arg2 int) { - _swig_wrap_RealDeque_delitem(arg1, arg2) -} - -var _wrap_RealDeque_getslice unsafe.Pointer - -func _swig_wrap_RealDeque_getslice(base SwigcptrRealDeque, _ int, _ int) (_ SwigcptrRealDeque) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_RealDeque_getslice, _swig_p) - return -} - -func (arg1 SwigcptrRealDeque) Getslice(arg2 int, arg3 int) (_swig_ret RealDeque) { - return _swig_wrap_RealDeque_getslice(arg1, arg2, arg3) -} - -var _wrap_RealDeque_setslice unsafe.Pointer - -func _swig_wrap_RealDeque_setslice(base SwigcptrRealDeque, _ int, _ int, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_RealDeque_setslice, _swig_p) - return -} - -func (arg1 SwigcptrRealDeque) Setslice(arg2 int, arg3 int, arg4 RealDeque) { - _swig_wrap_RealDeque_setslice(arg1, arg2, arg3, arg4.Swigcptr()) -} - -var _wrap_RealDeque_delslice unsafe.Pointer - -func _swig_wrap_RealDeque_delslice(base SwigcptrRealDeque, _ int, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_RealDeque_delslice, _swig_p) - return -} - -func (arg1 SwigcptrRealDeque) Delslice(arg2 int, arg3 int) { - _swig_wrap_RealDeque_delslice(arg1, arg2, arg3) -} - -type RealDeque interface { - Swigcptr() uintptr - SwigIsRealDeque() - Empty() (_swig_ret bool) - Assign(arg2 uint, arg3 float32) - Swap(arg2 RealDeque) - Size() (_swig_ret uint) - Max_size() (_swig_ret uint) - Resize(a ...interface{}) - Front() (_swig_ret float32) - Back() (_swig_ret float32) - Push_front(arg2 float32) - Push_back(arg2 float32) - Pop_front() - Pop_back() - Clear() - Getitem(arg2 int) (_swig_ret float32) - Setitem(arg2 int, arg3 float32) - Delitem(arg2 int) - Getslice(arg2 int, arg3 int) (_swig_ret RealDeque) - Setslice(arg2 int, arg3 int, arg4 RealDeque) - Delslice(arg2 int, arg3 int) -} - -var _wrap_average unsafe.Pointer - -func _swig_wrap_average(base uintptr) (_ float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_average, _swig_p) - return -} - -func Average(arg1 IntDeque) (_swig_ret float64) { - return _swig_wrap_average(arg1.Swigcptr()) -} - -var _wrap_half unsafe.Pointer - -func _swig_wrap_half(base uintptr) (_ SwigcptrRealDeque) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_half, _swig_p) - return -} - -func Half(arg1 RealDeque) (_swig_ret RealDeque) { - return _swig_wrap_half(arg1.Swigcptr()) -} - -var _wrap_halve_in_place unsafe.Pointer - -func _swig_wrap_halve_in_place(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_halve_in_place, _swig_p) - return -} - -func Halve_in_place(arg1 DoubleDeque) { - _swig_wrap_halve_in_place(arg1.Swigcptr()) -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/li_std_except.go b/Examples/test-suite/go/li_std_except.go deleted file mode 100644 index 80815e971..000000000 --- a/Examples/test-suite/go/li_std_except.go +++ /dev/null @@ -1,346 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../li_std_except.i - -package li_std_except - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrE1 uintptr - -func (p SwigcptrE1) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrE1) SwigIsE1() { -} - -var _wrap_new_E1 unsafe.Pointer - -func _swig_wrap_new_E1() (base SwigcptrE1) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_E1, _swig_p) - return -} - -func NewE1() (_swig_ret E1) { - return _swig_wrap_new_E1() -} - -var _wrap_delete_E1 unsafe.Pointer - -func _swig_wrap_delete_E1(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_E1, _swig_p) - return -} - -func DeleteE1(arg1 E1) { - _swig_wrap_delete_E1(arg1.Swigcptr()) -} - -type E1 interface { - Swigcptr() uintptr - SwigIsE1() -} - -type SwigcptrE2 uintptr - -func (p SwigcptrE2) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrE2) SwigIsE2() { -} - -var _wrap_new_E2 unsafe.Pointer - -func _swig_wrap_new_E2() (base SwigcptrE2) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_E2, _swig_p) - return -} - -func NewE2() (_swig_ret E2) { - return _swig_wrap_new_E2() -} - -var _wrap_delete_E2 unsafe.Pointer - -func _swig_wrap_delete_E2(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_E2, _swig_p) - return -} - -func DeleteE2(arg1 E2) { - _swig_wrap_delete_E2(arg1.Swigcptr()) -} - -type E2 interface { - Swigcptr() uintptr - SwigIsE2() -} - -type SwigcptrTest uintptr - -func (p SwigcptrTest) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrTest) SwigIsTest() { -} - -var _wrap_Test_foo1 unsafe.Pointer - -func _swig_wrap_Test_foo1(base SwigcptrTest) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Test_foo1, _swig_p) - return -} - -func (arg1 SwigcptrTest) Foo1() (_swig_ret int) { - return _swig_wrap_Test_foo1(arg1) -} - -var _wrap_Test_foo2 unsafe.Pointer - -func _swig_wrap_Test_foo2(base SwigcptrTest) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Test_foo2, _swig_p) - return -} - -func (arg1 SwigcptrTest) Foo2() (_swig_ret int) { - return _swig_wrap_Test_foo2(arg1) -} - -var _wrap_Test_foo3 unsafe.Pointer - -func _swig_wrap_Test_foo3(base SwigcptrTest) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Test_foo3, _swig_p) - return -} - -func (arg1 SwigcptrTest) Foo3() (_swig_ret int) { - return _swig_wrap_Test_foo3(arg1) -} - -var _wrap_Test_foo4 unsafe.Pointer - -func _swig_wrap_Test_foo4(base SwigcptrTest) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Test_foo4, _swig_p) - return -} - -func (arg1 SwigcptrTest) Foo4() (_swig_ret int) { - return _swig_wrap_Test_foo4(arg1) -} - -var _wrap_Test_throw_bad_exception unsafe.Pointer - -func _swig_wrap_Test_throw_bad_exception(base SwigcptrTest) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Test_throw_bad_exception, _swig_p) - return -} - -func (arg1 SwigcptrTest) Throw_bad_exception() { - _swig_wrap_Test_throw_bad_exception(arg1) -} - -var _wrap_Test_throw_domain_error unsafe.Pointer - -func _swig_wrap_Test_throw_domain_error(base SwigcptrTest) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Test_throw_domain_error, _swig_p) - return -} - -func (arg1 SwigcptrTest) Throw_domain_error() { - _swig_wrap_Test_throw_domain_error(arg1) -} - -var _wrap_Test_throw_exception unsafe.Pointer - -func _swig_wrap_Test_throw_exception(base SwigcptrTest) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Test_throw_exception, _swig_p) - return -} - -func (arg1 SwigcptrTest) Throw_exception() { - _swig_wrap_Test_throw_exception(arg1) -} - -var _wrap_Test_throw_invalid_argument unsafe.Pointer - -func _swig_wrap_Test_throw_invalid_argument(base SwigcptrTest) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Test_throw_invalid_argument, _swig_p) - return -} - -func (arg1 SwigcptrTest) Throw_invalid_argument() { - _swig_wrap_Test_throw_invalid_argument(arg1) -} - -var _wrap_Test_throw_length_error unsafe.Pointer - -func _swig_wrap_Test_throw_length_error(base SwigcptrTest) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Test_throw_length_error, _swig_p) - return -} - -func (arg1 SwigcptrTest) Throw_length_error() { - _swig_wrap_Test_throw_length_error(arg1) -} - -var _wrap_Test_throw_logic_error unsafe.Pointer - -func _swig_wrap_Test_throw_logic_error(base SwigcptrTest) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Test_throw_logic_error, _swig_p) - return -} - -func (arg1 SwigcptrTest) Throw_logic_error() { - _swig_wrap_Test_throw_logic_error(arg1) -} - -var _wrap_Test_throw_out_of_range unsafe.Pointer - -func _swig_wrap_Test_throw_out_of_range(base SwigcptrTest) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Test_throw_out_of_range, _swig_p) - return -} - -func (arg1 SwigcptrTest) Throw_out_of_range() { - _swig_wrap_Test_throw_out_of_range(arg1) -} - -var _wrap_Test_throw_overflow_error unsafe.Pointer - -func _swig_wrap_Test_throw_overflow_error(base SwigcptrTest) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Test_throw_overflow_error, _swig_p) - return -} - -func (arg1 SwigcptrTest) Throw_overflow_error() { - _swig_wrap_Test_throw_overflow_error(arg1) -} - -var _wrap_Test_throw_range_error unsafe.Pointer - -func _swig_wrap_Test_throw_range_error(base SwigcptrTest) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Test_throw_range_error, _swig_p) - return -} - -func (arg1 SwigcptrTest) Throw_range_error() { - _swig_wrap_Test_throw_range_error(arg1) -} - -var _wrap_Test_throw_runtime_error unsafe.Pointer - -func _swig_wrap_Test_throw_runtime_error(base SwigcptrTest) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Test_throw_runtime_error, _swig_p) - return -} - -func (arg1 SwigcptrTest) Throw_runtime_error() { - _swig_wrap_Test_throw_runtime_error(arg1) -} - -var _wrap_Test_throw_underflow_error unsafe.Pointer - -func _swig_wrap_Test_throw_underflow_error(base SwigcptrTest) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Test_throw_underflow_error, _swig_p) - return -} - -func (arg1 SwigcptrTest) Throw_underflow_error() { - _swig_wrap_Test_throw_underflow_error(arg1) -} - -var _wrap_new_Test unsafe.Pointer - -func _swig_wrap_new_Test() (base SwigcptrTest) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Test, _swig_p) - return -} - -func NewTest() (_swig_ret Test) { - return _swig_wrap_new_Test() -} - -var _wrap_delete_Test unsafe.Pointer - -func _swig_wrap_delete_Test(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Test, _swig_p) - return -} - -func DeleteTest(arg1 Test) { - _swig_wrap_delete_Test(arg1.Swigcptr()) -} - -type Test interface { - Swigcptr() uintptr - SwigIsTest() - Foo1() (_swig_ret int) - Foo2() (_swig_ret int) - Foo3() (_swig_ret int) - Foo4() (_swig_ret int) - Throw_bad_exception() - Throw_domain_error() - Throw_exception() - Throw_invalid_argument() - Throw_length_error() - Throw_logic_error() - Throw_out_of_range() - Throw_overflow_error() - Throw_range_error() - Throw_runtime_error() - Throw_underflow_error() -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/li_std_except_as_class.go b/Examples/test-suite/go/li_std_except_as_class.go deleted file mode 100644 index 0c654c612..000000000 --- a/Examples/test-suite/go/li_std_except_as_class.go +++ /dev/null @@ -1,49 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../li_std_except_as_class.i - -package li_std_except_as_class - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -var _wrap_test_domain_error unsafe.Pointer - -func _swig_wrap_test_domain_error() { - var _swig_p uintptr - _cgo_runtime_cgocall(_wrap_test_domain_error, _swig_p) - return -} - -func Test_domain_error() { - _swig_wrap_test_domain_error() -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/li_std_map.go b/Examples/test-suite/go/li_std_map.go deleted file mode 100644 index 5413a9b01..000000000 --- a/Examples/test-suite/go/li_std_map.go +++ /dev/null @@ -1,2700 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../li_std_map.i - -package li_std_map - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrMap uintptr - -func (p SwigcptrMap) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrMap) SwigIsMap() { -} - -var _wrap_map_val_set unsafe.Pointer - -func _swig_wrap_map_val_set(base SwigcptrMap, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_map_val_set, _swig_p) - return -} - -func (arg1 SwigcptrMap) SetVal(arg2 int) { - _swig_wrap_map_val_set(arg1, arg2) -} - -var _wrap_map_val_get unsafe.Pointer - -func _swig_wrap_map_val_get(base SwigcptrMap) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_map_val_get, _swig_p) - return -} - -func (arg1 SwigcptrMap) GetVal() (_swig_ret int) { - return _swig_wrap_map_val_get(arg1) -} - -var _wrap_new_map unsafe.Pointer - -func _swig_wrap_new_map(base int) (_ SwigcptrMap) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_map, _swig_p) - return -} - -func NewMap(arg1 int) (_swig_ret Map) { - return _swig_wrap_new_map(arg1) -} - -var _wrap_delete_map unsafe.Pointer - -func _swig_wrap_delete_map(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_map, _swig_p) - return -} - -func DeleteMap(arg1 Map) { - _swig_wrap_delete_map(arg1.Swigcptr()) -} - -type Map interface { - Swigcptr() uintptr - SwigIsMap() - SetVal(arg2 int) - GetVal() (_swig_ret int) -} - -type SwigcptrIntIntMap uintptr - -func (p SwigcptrIntIntMap) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrIntIntMap) SwigIsIntIntMap() { -} - -var _wrap_new_IntIntMap__SWIG_0 unsafe.Pointer - -func _swig_wrap_new_IntIntMap__SWIG_0() (base SwigcptrIntIntMap) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_IntIntMap__SWIG_0, _swig_p) - return -} - -func NewIntIntMap__SWIG_0() (_swig_ret IntIntMap) { - return _swig_wrap_new_IntIntMap__SWIG_0() -} - -var _wrap_new_IntIntMap__SWIG_1 unsafe.Pointer - -func _swig_wrap_new_IntIntMap__SWIG_1(base uintptr) (_ SwigcptrIntIntMap) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_IntIntMap__SWIG_1, _swig_p) - return -} - -func NewIntIntMap__SWIG_1(arg1 IntIntMap) (_swig_ret IntIntMap) { - return _swig_wrap_new_IntIntMap__SWIG_1(arg1.Swigcptr()) -} - -func NewIntIntMap(a ...interface{}) IntIntMap { - argc := len(a) - if argc == 0 { - return NewIntIntMap__SWIG_0() - } - if argc == 1 { - return NewIntIntMap__SWIG_1(a[0].(IntIntMap)) - } - panic("No match for overloaded function call") -} - -var _wrap_IntIntMap_size unsafe.Pointer - -func _swig_wrap_IntIntMap_size(base SwigcptrIntIntMap) (_ uint) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_IntIntMap_size, _swig_p) - return -} - -func (arg1 SwigcptrIntIntMap) Size() (_swig_ret uint) { - return _swig_wrap_IntIntMap_size(arg1) -} - -var _wrap_IntIntMap_empty unsafe.Pointer - -func _swig_wrap_IntIntMap_empty(base SwigcptrIntIntMap) (_ bool) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_IntIntMap_empty, _swig_p) - return -} - -func (arg1 SwigcptrIntIntMap) Empty() (_swig_ret bool) { - return _swig_wrap_IntIntMap_empty(arg1) -} - -var _wrap_IntIntMap_clear unsafe.Pointer - -func _swig_wrap_IntIntMap_clear(base SwigcptrIntIntMap) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_IntIntMap_clear, _swig_p) - return -} - -func (arg1 SwigcptrIntIntMap) Clear() { - _swig_wrap_IntIntMap_clear(arg1) -} - -var _wrap_IntIntMap_get unsafe.Pointer - -func _swig_wrap_IntIntMap_get(base SwigcptrIntIntMap, _ int) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_IntIntMap_get, _swig_p) - return -} - -func (arg1 SwigcptrIntIntMap) Get(arg2 int) (_swig_ret int) { - return _swig_wrap_IntIntMap_get(arg1, arg2) -} - -var _wrap_IntIntMap_set unsafe.Pointer - -func _swig_wrap_IntIntMap_set(base SwigcptrIntIntMap, _ int, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_IntIntMap_set, _swig_p) - return -} - -func (arg1 SwigcptrIntIntMap) Set(arg2 int, arg3 int) { - _swig_wrap_IntIntMap_set(arg1, arg2, arg3) -} - -var _wrap_IntIntMap_del unsafe.Pointer - -func _swig_wrap_IntIntMap_del(base SwigcptrIntIntMap, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_IntIntMap_del, _swig_p) - return -} - -func (arg1 SwigcptrIntIntMap) Del(arg2 int) { - _swig_wrap_IntIntMap_del(arg1, arg2) -} - -var _wrap_IntIntMap_has_key unsafe.Pointer - -func _swig_wrap_IntIntMap_has_key(base SwigcptrIntIntMap, _ int) (_ bool) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_IntIntMap_has_key, _swig_p) - return -} - -func (arg1 SwigcptrIntIntMap) Has_key(arg2 int) (_swig_ret bool) { - return _swig_wrap_IntIntMap_has_key(arg1, arg2) -} - -var _wrap_delete_IntIntMap unsafe.Pointer - -func _swig_wrap_delete_IntIntMap(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_IntIntMap, _swig_p) - return -} - -func DeleteIntIntMap(arg1 IntIntMap) { - _swig_wrap_delete_IntIntMap(arg1.Swigcptr()) -} - -type IntIntMap interface { - Swigcptr() uintptr - SwigIsIntIntMap() - Size() (_swig_ret uint) - Empty() (_swig_ret bool) - Clear() - Get(arg2 int) (_swig_ret int) - Set(arg2 int, arg3 int) - Del(arg2 int) - Has_key(arg2 int) (_swig_ret bool) -} - -type SwigcptrStringIntMap uintptr - -func (p SwigcptrStringIntMap) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrStringIntMap) SwigIsStringIntMap() { -} - -var _wrap_new_StringIntMap__SWIG_0 unsafe.Pointer - -func _swig_wrap_new_StringIntMap__SWIG_0() (base SwigcptrStringIntMap) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_StringIntMap__SWIG_0, _swig_p) - return -} - -func NewStringIntMap__SWIG_0() (_swig_ret StringIntMap) { - return _swig_wrap_new_StringIntMap__SWIG_0() -} - -var _wrap_new_StringIntMap__SWIG_1 unsafe.Pointer - -func _swig_wrap_new_StringIntMap__SWIG_1(base uintptr) (_ SwigcptrStringIntMap) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_StringIntMap__SWIG_1, _swig_p) - return -} - -func NewStringIntMap__SWIG_1(arg1 StringIntMap) (_swig_ret StringIntMap) { - return _swig_wrap_new_StringIntMap__SWIG_1(arg1.Swigcptr()) -} - -func NewStringIntMap(a ...interface{}) StringIntMap { - argc := len(a) - if argc == 0 { - return NewStringIntMap__SWIG_0() - } - if argc == 1 { - return NewStringIntMap__SWIG_1(a[0].(StringIntMap)) - } - panic("No match for overloaded function call") -} - -var _wrap_StringIntMap_size unsafe.Pointer - -func _swig_wrap_StringIntMap_size(base SwigcptrStringIntMap) (_ uint) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_StringIntMap_size, _swig_p) - return -} - -func (arg1 SwigcptrStringIntMap) Size() (_swig_ret uint) { - return _swig_wrap_StringIntMap_size(arg1) -} - -var _wrap_StringIntMap_empty unsafe.Pointer - -func _swig_wrap_StringIntMap_empty(base SwigcptrStringIntMap) (_ bool) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_StringIntMap_empty, _swig_p) - return -} - -func (arg1 SwigcptrStringIntMap) Empty() (_swig_ret bool) { - return _swig_wrap_StringIntMap_empty(arg1) -} - -var _wrap_StringIntMap_clear unsafe.Pointer - -func _swig_wrap_StringIntMap_clear(base SwigcptrStringIntMap) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_StringIntMap_clear, _swig_p) - return -} - -func (arg1 SwigcptrStringIntMap) Clear() { - _swig_wrap_StringIntMap_clear(arg1) -} - -var _wrap_StringIntMap_get unsafe.Pointer - -func _swig_wrap_StringIntMap_get(base SwigcptrStringIntMap, _ string) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_StringIntMap_get, _swig_p) - return -} - -func (arg1 SwigcptrStringIntMap) Get(arg2 string) (_swig_ret int) { - return _swig_wrap_StringIntMap_get(arg1, arg2) -} - -var _wrap_StringIntMap_set unsafe.Pointer - -func _swig_wrap_StringIntMap_set(base SwigcptrStringIntMap, _ string, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_StringIntMap_set, _swig_p) - return -} - -func (arg1 SwigcptrStringIntMap) Set(arg2 string, arg3 int) { - _swig_wrap_StringIntMap_set(arg1, arg2, arg3) -} - -var _wrap_StringIntMap_del unsafe.Pointer - -func _swig_wrap_StringIntMap_del(base SwigcptrStringIntMap, _ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_StringIntMap_del, _swig_p) - return -} - -func (arg1 SwigcptrStringIntMap) Del(arg2 string) { - _swig_wrap_StringIntMap_del(arg1, arg2) -} - -var _wrap_StringIntMap_has_key unsafe.Pointer - -func _swig_wrap_StringIntMap_has_key(base SwigcptrStringIntMap, _ string) (_ bool) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_StringIntMap_has_key, _swig_p) - return -} - -func (arg1 SwigcptrStringIntMap) Has_key(arg2 string) (_swig_ret bool) { - return _swig_wrap_StringIntMap_has_key(arg1, arg2) -} - -var _wrap_delete_StringIntMap unsafe.Pointer - -func _swig_wrap_delete_StringIntMap(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_StringIntMap, _swig_p) - return -} - -func DeleteStringIntMap(arg1 StringIntMap) { - _swig_wrap_delete_StringIntMap(arg1.Swigcptr()) -} - -type StringIntMap interface { - Swigcptr() uintptr - SwigIsStringIntMap() - Size() (_swig_ret uint) - Empty() (_swig_ret bool) - Clear() - Get(arg2 string) (_swig_ret int) - Set(arg2 string, arg3 int) - Del(arg2 string) - Has_key(arg2 string) (_swig_ret bool) -} - -var _wrap_valueAverage unsafe.Pointer - -func _swig_wrap_valueAverage(base uintptr) (_ float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_valueAverage, _swig_p) - return -} - -func ValueAverage(arg1 StringIntMap) (_swig_ret float64) { - return _swig_wrap_valueAverage(arg1.Swigcptr()) -} - -var _wrap_stringifyKeys unsafe.Pointer - -func _swig_wrap_stringifyKeys(base uintptr) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_stringifyKeys, _swig_p) - return -} - -func StringifyKeys(arg1 StringIntMap) (_swig_ret string) { - return _swig_wrap_stringifyKeys(arg1.Swigcptr()) -} - -type SwigcptrStruct uintptr - -func (p SwigcptrStruct) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrStruct) SwigIsStruct() { -} - -var _wrap_Struct_num_set unsafe.Pointer - -func _swig_wrap_Struct_num_set(base SwigcptrStruct, _ float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Struct_num_set, _swig_p) - return -} - -func (arg1 SwigcptrStruct) SetNum(arg2 float64) { - _swig_wrap_Struct_num_set(arg1, arg2) -} - -var _wrap_Struct_num_get unsafe.Pointer - -func _swig_wrap_Struct_num_get(base SwigcptrStruct) (_ float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Struct_num_get, _swig_p) - return -} - -func (arg1 SwigcptrStruct) GetNum() (_swig_ret float64) { - return _swig_wrap_Struct_num_get(arg1) -} - -var _wrap_new_Struct__SWIG_0 unsafe.Pointer - -func _swig_wrap_new_Struct__SWIG_0() (base SwigcptrStruct) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Struct__SWIG_0, _swig_p) - return -} - -func NewStruct__SWIG_0() (_swig_ret Struct) { - return _swig_wrap_new_Struct__SWIG_0() -} - -var _wrap_new_Struct__SWIG_1 unsafe.Pointer - -func _swig_wrap_new_Struct__SWIG_1(base float64) (_ SwigcptrStruct) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Struct__SWIG_1, _swig_p) - return -} - -func NewStruct__SWIG_1(arg1 float64) (_swig_ret Struct) { - return _swig_wrap_new_Struct__SWIG_1(arg1) -} - -func NewStruct(a ...interface{}) Struct { - argc := len(a) - if argc == 0 { - return NewStruct__SWIG_0() - } - if argc == 1 { - return NewStruct__SWIG_1(a[0].(float64)) - } - panic("No match for overloaded function call") -} - -var _wrap_delete_Struct unsafe.Pointer - -func _swig_wrap_delete_Struct(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Struct, _swig_p) - return -} - -func DeleteStruct(arg1 Struct) { - _swig_wrap_delete_Struct(arg1.Swigcptr()) -} - -type Struct interface { - Swigcptr() uintptr - SwigIsStruct() - SetNum(arg2 float64) - GetNum() (_swig_ret float64) -} - -type SwigcptrIntIntPtrMap uintptr - -func (p SwigcptrIntIntPtrMap) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrIntIntPtrMap) SwigIsIntIntPtrMap() { -} - -var _wrap_new_IntIntPtrMap__SWIG_0 unsafe.Pointer - -func _swig_wrap_new_IntIntPtrMap__SWIG_0() (base SwigcptrIntIntPtrMap) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_IntIntPtrMap__SWIG_0, _swig_p) - return -} - -func NewIntIntPtrMap__SWIG_0() (_swig_ret IntIntPtrMap) { - return _swig_wrap_new_IntIntPtrMap__SWIG_0() -} - -var _wrap_new_IntIntPtrMap__SWIG_1 unsafe.Pointer - -func _swig_wrap_new_IntIntPtrMap__SWIG_1(base uintptr) (_ SwigcptrIntIntPtrMap) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_IntIntPtrMap__SWIG_1, _swig_p) - return -} - -func NewIntIntPtrMap__SWIG_1(arg1 IntIntPtrMap) (_swig_ret IntIntPtrMap) { - return _swig_wrap_new_IntIntPtrMap__SWIG_1(arg1.Swigcptr()) -} - -func NewIntIntPtrMap(a ...interface{}) IntIntPtrMap { - argc := len(a) - if argc == 0 { - return NewIntIntPtrMap__SWIG_0() - } - if argc == 1 { - return NewIntIntPtrMap__SWIG_1(a[0].(IntIntPtrMap)) - } - panic("No match for overloaded function call") -} - -var _wrap_IntIntPtrMap_size unsafe.Pointer - -func _swig_wrap_IntIntPtrMap_size(base SwigcptrIntIntPtrMap) (_ uint) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_IntIntPtrMap_size, _swig_p) - return -} - -func (arg1 SwigcptrIntIntPtrMap) Size() (_swig_ret uint) { - return _swig_wrap_IntIntPtrMap_size(arg1) -} - -var _wrap_IntIntPtrMap_empty unsafe.Pointer - -func _swig_wrap_IntIntPtrMap_empty(base SwigcptrIntIntPtrMap) (_ bool) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_IntIntPtrMap_empty, _swig_p) - return -} - -func (arg1 SwigcptrIntIntPtrMap) Empty() (_swig_ret bool) { - return _swig_wrap_IntIntPtrMap_empty(arg1) -} - -var _wrap_IntIntPtrMap_clear unsafe.Pointer - -func _swig_wrap_IntIntPtrMap_clear(base SwigcptrIntIntPtrMap) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_IntIntPtrMap_clear, _swig_p) - return -} - -func (arg1 SwigcptrIntIntPtrMap) Clear() { - _swig_wrap_IntIntPtrMap_clear(arg1) -} - -var _wrap_IntIntPtrMap_get unsafe.Pointer - -func _swig_wrap_IntIntPtrMap_get(base SwigcptrIntIntPtrMap, _ int) (_ *int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_IntIntPtrMap_get, _swig_p) - return -} - -func (arg1 SwigcptrIntIntPtrMap) Get(arg2 int) (_swig_ret *int) { - return _swig_wrap_IntIntPtrMap_get(arg1, arg2) -} - -var _wrap_IntIntPtrMap_set unsafe.Pointer - -func _swig_wrap_IntIntPtrMap_set(base SwigcptrIntIntPtrMap, _ int, _ *int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_IntIntPtrMap_set, _swig_p) - return -} - -func (arg1 SwigcptrIntIntPtrMap) Set(arg2 int, arg3 *int) { - _swig_wrap_IntIntPtrMap_set(arg1, arg2, arg3) -} - -var _wrap_IntIntPtrMap_del unsafe.Pointer - -func _swig_wrap_IntIntPtrMap_del(base SwigcptrIntIntPtrMap, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_IntIntPtrMap_del, _swig_p) - return -} - -func (arg1 SwigcptrIntIntPtrMap) Del(arg2 int) { - _swig_wrap_IntIntPtrMap_del(arg1, arg2) -} - -var _wrap_IntIntPtrMap_has_key unsafe.Pointer - -func _swig_wrap_IntIntPtrMap_has_key(base SwigcptrIntIntPtrMap, _ int) (_ bool) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_IntIntPtrMap_has_key, _swig_p) - return -} - -func (arg1 SwigcptrIntIntPtrMap) Has_key(arg2 int) (_swig_ret bool) { - return _swig_wrap_IntIntPtrMap_has_key(arg1, arg2) -} - -var _wrap_delete_IntIntPtrMap unsafe.Pointer - -func _swig_wrap_delete_IntIntPtrMap(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_IntIntPtrMap, _swig_p) - return -} - -func DeleteIntIntPtrMap(arg1 IntIntPtrMap) { - _swig_wrap_delete_IntIntPtrMap(arg1.Swigcptr()) -} - -type IntIntPtrMap interface { - Swigcptr() uintptr - SwigIsIntIntPtrMap() - Size() (_swig_ret uint) - Empty() (_swig_ret bool) - Clear() - Get(arg2 int) (_swig_ret *int) - Set(arg2 int, arg3 *int) - Del(arg2 int) - Has_key(arg2 int) (_swig_ret bool) -} - -type SwigcptrIntConstIntPtrMap uintptr - -func (p SwigcptrIntConstIntPtrMap) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrIntConstIntPtrMap) SwigIsIntConstIntPtrMap() { -} - -var _wrap_new_IntConstIntPtrMap__SWIG_0 unsafe.Pointer - -func _swig_wrap_new_IntConstIntPtrMap__SWIG_0() (base SwigcptrIntConstIntPtrMap) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_IntConstIntPtrMap__SWIG_0, _swig_p) - return -} - -func NewIntConstIntPtrMap__SWIG_0() (_swig_ret IntConstIntPtrMap) { - return _swig_wrap_new_IntConstIntPtrMap__SWIG_0() -} - -var _wrap_new_IntConstIntPtrMap__SWIG_1 unsafe.Pointer - -func _swig_wrap_new_IntConstIntPtrMap__SWIG_1(base uintptr) (_ SwigcptrIntConstIntPtrMap) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_IntConstIntPtrMap__SWIG_1, _swig_p) - return -} - -func NewIntConstIntPtrMap__SWIG_1(arg1 IntConstIntPtrMap) (_swig_ret IntConstIntPtrMap) { - return _swig_wrap_new_IntConstIntPtrMap__SWIG_1(arg1.Swigcptr()) -} - -func NewIntConstIntPtrMap(a ...interface{}) IntConstIntPtrMap { - argc := len(a) - if argc == 0 { - return NewIntConstIntPtrMap__SWIG_0() - } - if argc == 1 { - return NewIntConstIntPtrMap__SWIG_1(a[0].(IntConstIntPtrMap)) - } - panic("No match for overloaded function call") -} - -var _wrap_IntConstIntPtrMap_size unsafe.Pointer - -func _swig_wrap_IntConstIntPtrMap_size(base SwigcptrIntConstIntPtrMap) (_ uint) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_IntConstIntPtrMap_size, _swig_p) - return -} - -func (arg1 SwigcptrIntConstIntPtrMap) Size() (_swig_ret uint) { - return _swig_wrap_IntConstIntPtrMap_size(arg1) -} - -var _wrap_IntConstIntPtrMap_empty unsafe.Pointer - -func _swig_wrap_IntConstIntPtrMap_empty(base SwigcptrIntConstIntPtrMap) (_ bool) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_IntConstIntPtrMap_empty, _swig_p) - return -} - -func (arg1 SwigcptrIntConstIntPtrMap) Empty() (_swig_ret bool) { - return _swig_wrap_IntConstIntPtrMap_empty(arg1) -} - -var _wrap_IntConstIntPtrMap_clear unsafe.Pointer - -func _swig_wrap_IntConstIntPtrMap_clear(base SwigcptrIntConstIntPtrMap) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_IntConstIntPtrMap_clear, _swig_p) - return -} - -func (arg1 SwigcptrIntConstIntPtrMap) Clear() { - _swig_wrap_IntConstIntPtrMap_clear(arg1) -} - -var _wrap_IntConstIntPtrMap_get unsafe.Pointer - -func _swig_wrap_IntConstIntPtrMap_get(base SwigcptrIntConstIntPtrMap, _ int) (_ *int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_IntConstIntPtrMap_get, _swig_p) - return -} - -func (arg1 SwigcptrIntConstIntPtrMap) Get(arg2 int) (_swig_ret *int) { - return _swig_wrap_IntConstIntPtrMap_get(arg1, arg2) -} - -var _wrap_IntConstIntPtrMap_set unsafe.Pointer - -func _swig_wrap_IntConstIntPtrMap_set(base SwigcptrIntConstIntPtrMap, _ int, _ *int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_IntConstIntPtrMap_set, _swig_p) - return -} - -func (arg1 SwigcptrIntConstIntPtrMap) Set(arg2 int, arg3 *int) { - _swig_wrap_IntConstIntPtrMap_set(arg1, arg2, arg3) -} - -var _wrap_IntConstIntPtrMap_del unsafe.Pointer - -func _swig_wrap_IntConstIntPtrMap_del(base SwigcptrIntConstIntPtrMap, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_IntConstIntPtrMap_del, _swig_p) - return -} - -func (arg1 SwigcptrIntConstIntPtrMap) Del(arg2 int) { - _swig_wrap_IntConstIntPtrMap_del(arg1, arg2) -} - -var _wrap_IntConstIntPtrMap_has_key unsafe.Pointer - -func _swig_wrap_IntConstIntPtrMap_has_key(base SwigcptrIntConstIntPtrMap, _ int) (_ bool) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_IntConstIntPtrMap_has_key, _swig_p) - return -} - -func (arg1 SwigcptrIntConstIntPtrMap) Has_key(arg2 int) (_swig_ret bool) { - return _swig_wrap_IntConstIntPtrMap_has_key(arg1, arg2) -} - -var _wrap_delete_IntConstIntPtrMap unsafe.Pointer - -func _swig_wrap_delete_IntConstIntPtrMap(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_IntConstIntPtrMap, _swig_p) - return -} - -func DeleteIntConstIntPtrMap(arg1 IntConstIntPtrMap) { - _swig_wrap_delete_IntConstIntPtrMap(arg1.Swigcptr()) -} - -type IntConstIntPtrMap interface { - Swigcptr() uintptr - SwigIsIntConstIntPtrMap() - Size() (_swig_ret uint) - Empty() (_swig_ret bool) - Clear() - Get(arg2 int) (_swig_ret *int) - Set(arg2 int, arg3 *int) - Del(arg2 int) - Has_key(arg2 int) (_swig_ret bool) -} - -type SwigcptrIntStructMap uintptr - -func (p SwigcptrIntStructMap) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrIntStructMap) SwigIsIntStructMap() { -} - -var _wrap_new_IntStructMap__SWIG_0 unsafe.Pointer - -func _swig_wrap_new_IntStructMap__SWIG_0() (base SwigcptrIntStructMap) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_IntStructMap__SWIG_0, _swig_p) - return -} - -func NewIntStructMap__SWIG_0() (_swig_ret IntStructMap) { - return _swig_wrap_new_IntStructMap__SWIG_0() -} - -var _wrap_new_IntStructMap__SWIG_1 unsafe.Pointer - -func _swig_wrap_new_IntStructMap__SWIG_1(base uintptr) (_ SwigcptrIntStructMap) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_IntStructMap__SWIG_1, _swig_p) - return -} - -func NewIntStructMap__SWIG_1(arg1 IntStructMap) (_swig_ret IntStructMap) { - return _swig_wrap_new_IntStructMap__SWIG_1(arg1.Swigcptr()) -} - -func NewIntStructMap(a ...interface{}) IntStructMap { - argc := len(a) - if argc == 0 { - return NewIntStructMap__SWIG_0() - } - if argc == 1 { - return NewIntStructMap__SWIG_1(a[0].(IntStructMap)) - } - panic("No match for overloaded function call") -} - -var _wrap_IntStructMap_size unsafe.Pointer - -func _swig_wrap_IntStructMap_size(base SwigcptrIntStructMap) (_ uint) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_IntStructMap_size, _swig_p) - return -} - -func (arg1 SwigcptrIntStructMap) Size() (_swig_ret uint) { - return _swig_wrap_IntStructMap_size(arg1) -} - -var _wrap_IntStructMap_empty unsafe.Pointer - -func _swig_wrap_IntStructMap_empty(base SwigcptrIntStructMap) (_ bool) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_IntStructMap_empty, _swig_p) - return -} - -func (arg1 SwigcptrIntStructMap) Empty() (_swig_ret bool) { - return _swig_wrap_IntStructMap_empty(arg1) -} - -var _wrap_IntStructMap_clear unsafe.Pointer - -func _swig_wrap_IntStructMap_clear(base SwigcptrIntStructMap) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_IntStructMap_clear, _swig_p) - return -} - -func (arg1 SwigcptrIntStructMap) Clear() { - _swig_wrap_IntStructMap_clear(arg1) -} - -var _wrap_IntStructMap_get unsafe.Pointer - -func _swig_wrap_IntStructMap_get(base SwigcptrIntStructMap, _ int) (_ SwigcptrStruct) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_IntStructMap_get, _swig_p) - return -} - -func (arg1 SwigcptrIntStructMap) Get(arg2 int) (_swig_ret Struct) { - return _swig_wrap_IntStructMap_get(arg1, arg2) -} - -var _wrap_IntStructMap_set unsafe.Pointer - -func _swig_wrap_IntStructMap_set(base SwigcptrIntStructMap, _ int, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_IntStructMap_set, _swig_p) - return -} - -func (arg1 SwigcptrIntStructMap) Set(arg2 int, arg3 Struct) { - _swig_wrap_IntStructMap_set(arg1, arg2, arg3.Swigcptr()) -} - -var _wrap_IntStructMap_del unsafe.Pointer - -func _swig_wrap_IntStructMap_del(base SwigcptrIntStructMap, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_IntStructMap_del, _swig_p) - return -} - -func (arg1 SwigcptrIntStructMap) Del(arg2 int) { - _swig_wrap_IntStructMap_del(arg1, arg2) -} - -var _wrap_IntStructMap_has_key unsafe.Pointer - -func _swig_wrap_IntStructMap_has_key(base SwigcptrIntStructMap, _ int) (_ bool) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_IntStructMap_has_key, _swig_p) - return -} - -func (arg1 SwigcptrIntStructMap) Has_key(arg2 int) (_swig_ret bool) { - return _swig_wrap_IntStructMap_has_key(arg1, arg2) -} - -var _wrap_delete_IntStructMap unsafe.Pointer - -func _swig_wrap_delete_IntStructMap(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_IntStructMap, _swig_p) - return -} - -func DeleteIntStructMap(arg1 IntStructMap) { - _swig_wrap_delete_IntStructMap(arg1.Swigcptr()) -} - -type IntStructMap interface { - Swigcptr() uintptr - SwigIsIntStructMap() - Size() (_swig_ret uint) - Empty() (_swig_ret bool) - Clear() - Get(arg2 int) (_swig_ret Struct) - Set(arg2 int, arg3 Struct) - Del(arg2 int) - Has_key(arg2 int) (_swig_ret bool) -} - -type SwigcptrIntStructPtrMap uintptr - -func (p SwigcptrIntStructPtrMap) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrIntStructPtrMap) SwigIsIntStructPtrMap() { -} - -var _wrap_new_IntStructPtrMap__SWIG_0 unsafe.Pointer - -func _swig_wrap_new_IntStructPtrMap__SWIG_0() (base SwigcptrIntStructPtrMap) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_IntStructPtrMap__SWIG_0, _swig_p) - return -} - -func NewIntStructPtrMap__SWIG_0() (_swig_ret IntStructPtrMap) { - return _swig_wrap_new_IntStructPtrMap__SWIG_0() -} - -var _wrap_new_IntStructPtrMap__SWIG_1 unsafe.Pointer - -func _swig_wrap_new_IntStructPtrMap__SWIG_1(base uintptr) (_ SwigcptrIntStructPtrMap) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_IntStructPtrMap__SWIG_1, _swig_p) - return -} - -func NewIntStructPtrMap__SWIG_1(arg1 IntStructPtrMap) (_swig_ret IntStructPtrMap) { - return _swig_wrap_new_IntStructPtrMap__SWIG_1(arg1.Swigcptr()) -} - -func NewIntStructPtrMap(a ...interface{}) IntStructPtrMap { - argc := len(a) - if argc == 0 { - return NewIntStructPtrMap__SWIG_0() - } - if argc == 1 { - return NewIntStructPtrMap__SWIG_1(a[0].(IntStructPtrMap)) - } - panic("No match for overloaded function call") -} - -var _wrap_IntStructPtrMap_size unsafe.Pointer - -func _swig_wrap_IntStructPtrMap_size(base SwigcptrIntStructPtrMap) (_ uint) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_IntStructPtrMap_size, _swig_p) - return -} - -func (arg1 SwigcptrIntStructPtrMap) Size() (_swig_ret uint) { - return _swig_wrap_IntStructPtrMap_size(arg1) -} - -var _wrap_IntStructPtrMap_empty unsafe.Pointer - -func _swig_wrap_IntStructPtrMap_empty(base SwigcptrIntStructPtrMap) (_ bool) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_IntStructPtrMap_empty, _swig_p) - return -} - -func (arg1 SwigcptrIntStructPtrMap) Empty() (_swig_ret bool) { - return _swig_wrap_IntStructPtrMap_empty(arg1) -} - -var _wrap_IntStructPtrMap_clear unsafe.Pointer - -func _swig_wrap_IntStructPtrMap_clear(base SwigcptrIntStructPtrMap) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_IntStructPtrMap_clear, _swig_p) - return -} - -func (arg1 SwigcptrIntStructPtrMap) Clear() { - _swig_wrap_IntStructPtrMap_clear(arg1) -} - -var _wrap_IntStructPtrMap_get unsafe.Pointer - -func _swig_wrap_IntStructPtrMap_get(base SwigcptrIntStructPtrMap, _ int) (_ SwigcptrStruct) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_IntStructPtrMap_get, _swig_p) - return -} - -func (arg1 SwigcptrIntStructPtrMap) Get(arg2 int) (_swig_ret Struct) { - return _swig_wrap_IntStructPtrMap_get(arg1, arg2) -} - -var _wrap_IntStructPtrMap_set unsafe.Pointer - -func _swig_wrap_IntStructPtrMap_set(base SwigcptrIntStructPtrMap, _ int, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_IntStructPtrMap_set, _swig_p) - return -} - -func (arg1 SwigcptrIntStructPtrMap) Set(arg2 int, arg3 Struct) { - _swig_wrap_IntStructPtrMap_set(arg1, arg2, arg3.Swigcptr()) -} - -var _wrap_IntStructPtrMap_del unsafe.Pointer - -func _swig_wrap_IntStructPtrMap_del(base SwigcptrIntStructPtrMap, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_IntStructPtrMap_del, _swig_p) - return -} - -func (arg1 SwigcptrIntStructPtrMap) Del(arg2 int) { - _swig_wrap_IntStructPtrMap_del(arg1, arg2) -} - -var _wrap_IntStructPtrMap_has_key unsafe.Pointer - -func _swig_wrap_IntStructPtrMap_has_key(base SwigcptrIntStructPtrMap, _ int) (_ bool) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_IntStructPtrMap_has_key, _swig_p) - return -} - -func (arg1 SwigcptrIntStructPtrMap) Has_key(arg2 int) (_swig_ret bool) { - return _swig_wrap_IntStructPtrMap_has_key(arg1, arg2) -} - -var _wrap_delete_IntStructPtrMap unsafe.Pointer - -func _swig_wrap_delete_IntStructPtrMap(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_IntStructPtrMap, _swig_p) - return -} - -func DeleteIntStructPtrMap(arg1 IntStructPtrMap) { - _swig_wrap_delete_IntStructPtrMap(arg1.Swigcptr()) -} - -type IntStructPtrMap interface { - Swigcptr() uintptr - SwigIsIntStructPtrMap() - Size() (_swig_ret uint) - Empty() (_swig_ret bool) - Clear() - Get(arg2 int) (_swig_ret Struct) - Set(arg2 int, arg3 Struct) - Del(arg2 int) - Has_key(arg2 int) (_swig_ret bool) -} - -type SwigcptrIntStructConstPtrMap uintptr - -func (p SwigcptrIntStructConstPtrMap) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrIntStructConstPtrMap) SwigIsIntStructConstPtrMap() { -} - -var _wrap_new_IntStructConstPtrMap__SWIG_0 unsafe.Pointer - -func _swig_wrap_new_IntStructConstPtrMap__SWIG_0() (base SwigcptrIntStructConstPtrMap) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_IntStructConstPtrMap__SWIG_0, _swig_p) - return -} - -func NewIntStructConstPtrMap__SWIG_0() (_swig_ret IntStructConstPtrMap) { - return _swig_wrap_new_IntStructConstPtrMap__SWIG_0() -} - -var _wrap_new_IntStructConstPtrMap__SWIG_1 unsafe.Pointer - -func _swig_wrap_new_IntStructConstPtrMap__SWIG_1(base uintptr) (_ SwigcptrIntStructConstPtrMap) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_IntStructConstPtrMap__SWIG_1, _swig_p) - return -} - -func NewIntStructConstPtrMap__SWIG_1(arg1 IntStructConstPtrMap) (_swig_ret IntStructConstPtrMap) { - return _swig_wrap_new_IntStructConstPtrMap__SWIG_1(arg1.Swigcptr()) -} - -func NewIntStructConstPtrMap(a ...interface{}) IntStructConstPtrMap { - argc := len(a) - if argc == 0 { - return NewIntStructConstPtrMap__SWIG_0() - } - if argc == 1 { - return NewIntStructConstPtrMap__SWIG_1(a[0].(IntStructConstPtrMap)) - } - panic("No match for overloaded function call") -} - -var _wrap_IntStructConstPtrMap_size unsafe.Pointer - -func _swig_wrap_IntStructConstPtrMap_size(base SwigcptrIntStructConstPtrMap) (_ uint) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_IntStructConstPtrMap_size, _swig_p) - return -} - -func (arg1 SwigcptrIntStructConstPtrMap) Size() (_swig_ret uint) { - return _swig_wrap_IntStructConstPtrMap_size(arg1) -} - -var _wrap_IntStructConstPtrMap_empty unsafe.Pointer - -func _swig_wrap_IntStructConstPtrMap_empty(base SwigcptrIntStructConstPtrMap) (_ bool) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_IntStructConstPtrMap_empty, _swig_p) - return -} - -func (arg1 SwigcptrIntStructConstPtrMap) Empty() (_swig_ret bool) { - return _swig_wrap_IntStructConstPtrMap_empty(arg1) -} - -var _wrap_IntStructConstPtrMap_clear unsafe.Pointer - -func _swig_wrap_IntStructConstPtrMap_clear(base SwigcptrIntStructConstPtrMap) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_IntStructConstPtrMap_clear, _swig_p) - return -} - -func (arg1 SwigcptrIntStructConstPtrMap) Clear() { - _swig_wrap_IntStructConstPtrMap_clear(arg1) -} - -var _wrap_IntStructConstPtrMap_get unsafe.Pointer - -func _swig_wrap_IntStructConstPtrMap_get(base SwigcptrIntStructConstPtrMap, _ int) (_ SwigcptrStruct) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_IntStructConstPtrMap_get, _swig_p) - return -} - -func (arg1 SwigcptrIntStructConstPtrMap) Get(arg2 int) (_swig_ret Struct) { - return _swig_wrap_IntStructConstPtrMap_get(arg1, arg2) -} - -var _wrap_IntStructConstPtrMap_set unsafe.Pointer - -func _swig_wrap_IntStructConstPtrMap_set(base SwigcptrIntStructConstPtrMap, _ int, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_IntStructConstPtrMap_set, _swig_p) - return -} - -func (arg1 SwigcptrIntStructConstPtrMap) Set(arg2 int, arg3 Struct) { - _swig_wrap_IntStructConstPtrMap_set(arg1, arg2, arg3.Swigcptr()) -} - -var _wrap_IntStructConstPtrMap_del unsafe.Pointer - -func _swig_wrap_IntStructConstPtrMap_del(base SwigcptrIntStructConstPtrMap, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_IntStructConstPtrMap_del, _swig_p) - return -} - -func (arg1 SwigcptrIntStructConstPtrMap) Del(arg2 int) { - _swig_wrap_IntStructConstPtrMap_del(arg1, arg2) -} - -var _wrap_IntStructConstPtrMap_has_key unsafe.Pointer - -func _swig_wrap_IntStructConstPtrMap_has_key(base SwigcptrIntStructConstPtrMap, _ int) (_ bool) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_IntStructConstPtrMap_has_key, _swig_p) - return -} - -func (arg1 SwigcptrIntStructConstPtrMap) Has_key(arg2 int) (_swig_ret bool) { - return _swig_wrap_IntStructConstPtrMap_has_key(arg1, arg2) -} - -var _wrap_delete_IntStructConstPtrMap unsafe.Pointer - -func _swig_wrap_delete_IntStructConstPtrMap(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_IntStructConstPtrMap, _swig_p) - return -} - -func DeleteIntStructConstPtrMap(arg1 IntStructConstPtrMap) { - _swig_wrap_delete_IntStructConstPtrMap(arg1.Swigcptr()) -} - -type IntStructConstPtrMap interface { - Swigcptr() uintptr - SwigIsIntStructConstPtrMap() - Size() (_swig_ret uint) - Empty() (_swig_ret bool) - Clear() - Get(arg2 int) (_swig_ret Struct) - Set(arg2 int, arg3 Struct) - Del(arg2 int) - Has_key(arg2 int) (_swig_ret bool) -} - -type SwigcptrStructPtrIntMap uintptr - -func (p SwigcptrStructPtrIntMap) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrStructPtrIntMap) SwigIsStructPtrIntMap() { -} - -var _wrap_new_StructPtrIntMap__SWIG_0 unsafe.Pointer - -func _swig_wrap_new_StructPtrIntMap__SWIG_0() (base SwigcptrStructPtrIntMap) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_StructPtrIntMap__SWIG_0, _swig_p) - return -} - -func NewStructPtrIntMap__SWIG_0() (_swig_ret StructPtrIntMap) { - return _swig_wrap_new_StructPtrIntMap__SWIG_0() -} - -var _wrap_new_StructPtrIntMap__SWIG_1 unsafe.Pointer - -func _swig_wrap_new_StructPtrIntMap__SWIG_1(base uintptr) (_ SwigcptrStructPtrIntMap) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_StructPtrIntMap__SWIG_1, _swig_p) - return -} - -func NewStructPtrIntMap__SWIG_1(arg1 StructPtrIntMap) (_swig_ret StructPtrIntMap) { - return _swig_wrap_new_StructPtrIntMap__SWIG_1(arg1.Swigcptr()) -} - -func NewStructPtrIntMap(a ...interface{}) StructPtrIntMap { - argc := len(a) - if argc == 0 { - return NewStructPtrIntMap__SWIG_0() - } - if argc == 1 { - return NewStructPtrIntMap__SWIG_1(a[0].(StructPtrIntMap)) - } - panic("No match for overloaded function call") -} - -var _wrap_StructPtrIntMap_size unsafe.Pointer - -func _swig_wrap_StructPtrIntMap_size(base SwigcptrStructPtrIntMap) (_ uint) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_StructPtrIntMap_size, _swig_p) - return -} - -func (arg1 SwigcptrStructPtrIntMap) Size() (_swig_ret uint) { - return _swig_wrap_StructPtrIntMap_size(arg1) -} - -var _wrap_StructPtrIntMap_empty unsafe.Pointer - -func _swig_wrap_StructPtrIntMap_empty(base SwigcptrStructPtrIntMap) (_ bool) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_StructPtrIntMap_empty, _swig_p) - return -} - -func (arg1 SwigcptrStructPtrIntMap) Empty() (_swig_ret bool) { - return _swig_wrap_StructPtrIntMap_empty(arg1) -} - -var _wrap_StructPtrIntMap_clear unsafe.Pointer - -func _swig_wrap_StructPtrIntMap_clear(base SwigcptrStructPtrIntMap) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_StructPtrIntMap_clear, _swig_p) - return -} - -func (arg1 SwigcptrStructPtrIntMap) Clear() { - _swig_wrap_StructPtrIntMap_clear(arg1) -} - -var _wrap_StructPtrIntMap_get unsafe.Pointer - -func _swig_wrap_StructPtrIntMap_get(base SwigcptrStructPtrIntMap, _ uintptr) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_StructPtrIntMap_get, _swig_p) - return -} - -func (arg1 SwigcptrStructPtrIntMap) Get(arg2 Struct) (_swig_ret int) { - return _swig_wrap_StructPtrIntMap_get(arg1, arg2.Swigcptr()) -} - -var _wrap_StructPtrIntMap_set unsafe.Pointer - -func _swig_wrap_StructPtrIntMap_set(base SwigcptrStructPtrIntMap, _ uintptr, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_StructPtrIntMap_set, _swig_p) - return -} - -func (arg1 SwigcptrStructPtrIntMap) Set(arg2 Struct, arg3 int) { - _swig_wrap_StructPtrIntMap_set(arg1, arg2.Swigcptr(), arg3) -} - -var _wrap_StructPtrIntMap_del unsafe.Pointer - -func _swig_wrap_StructPtrIntMap_del(base SwigcptrStructPtrIntMap, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_StructPtrIntMap_del, _swig_p) - return -} - -func (arg1 SwigcptrStructPtrIntMap) Del(arg2 Struct) { - _swig_wrap_StructPtrIntMap_del(arg1, arg2.Swigcptr()) -} - -var _wrap_StructPtrIntMap_has_key unsafe.Pointer - -func _swig_wrap_StructPtrIntMap_has_key(base SwigcptrStructPtrIntMap, _ uintptr) (_ bool) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_StructPtrIntMap_has_key, _swig_p) - return -} - -func (arg1 SwigcptrStructPtrIntMap) Has_key(arg2 Struct) (_swig_ret bool) { - return _swig_wrap_StructPtrIntMap_has_key(arg1, arg2.Swigcptr()) -} - -var _wrap_delete_StructPtrIntMap unsafe.Pointer - -func _swig_wrap_delete_StructPtrIntMap(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_StructPtrIntMap, _swig_p) - return -} - -func DeleteStructPtrIntMap(arg1 StructPtrIntMap) { - _swig_wrap_delete_StructPtrIntMap(arg1.Swigcptr()) -} - -type StructPtrIntMap interface { - Swigcptr() uintptr - SwigIsStructPtrIntMap() - Size() (_swig_ret uint) - Empty() (_swig_ret bool) - Clear() - Get(arg2 Struct) (_swig_ret int) - Set(arg2 Struct, arg3 int) - Del(arg2 Struct) - Has_key(arg2 Struct) (_swig_ret bool) -} - -type SwigcptrStructIntMap uintptr - -func (p SwigcptrStructIntMap) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrStructIntMap) SwigIsStructIntMap() { -} - -var _wrap_new_StructIntMap__SWIG_0 unsafe.Pointer - -func _swig_wrap_new_StructIntMap__SWIG_0() (base SwigcptrStructIntMap) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_StructIntMap__SWIG_0, _swig_p) - return -} - -func NewStructIntMap__SWIG_0() (_swig_ret StructIntMap) { - return _swig_wrap_new_StructIntMap__SWIG_0() -} - -var _wrap_new_StructIntMap__SWIG_1 unsafe.Pointer - -func _swig_wrap_new_StructIntMap__SWIG_1(base uintptr) (_ SwigcptrStructIntMap) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_StructIntMap__SWIG_1, _swig_p) - return -} - -func NewStructIntMap__SWIG_1(arg1 StructIntMap) (_swig_ret StructIntMap) { - return _swig_wrap_new_StructIntMap__SWIG_1(arg1.Swigcptr()) -} - -func NewStructIntMap(a ...interface{}) StructIntMap { - argc := len(a) - if argc == 0 { - return NewStructIntMap__SWIG_0() - } - if argc == 1 { - return NewStructIntMap__SWIG_1(a[0].(StructIntMap)) - } - panic("No match for overloaded function call") -} - -var _wrap_StructIntMap_size unsafe.Pointer - -func _swig_wrap_StructIntMap_size(base SwigcptrStructIntMap) (_ uint) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_StructIntMap_size, _swig_p) - return -} - -func (arg1 SwigcptrStructIntMap) Size() (_swig_ret uint) { - return _swig_wrap_StructIntMap_size(arg1) -} - -var _wrap_StructIntMap_empty unsafe.Pointer - -func _swig_wrap_StructIntMap_empty(base SwigcptrStructIntMap) (_ bool) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_StructIntMap_empty, _swig_p) - return -} - -func (arg1 SwigcptrStructIntMap) Empty() (_swig_ret bool) { - return _swig_wrap_StructIntMap_empty(arg1) -} - -var _wrap_StructIntMap_clear unsafe.Pointer - -func _swig_wrap_StructIntMap_clear(base SwigcptrStructIntMap) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_StructIntMap_clear, _swig_p) - return -} - -func (arg1 SwigcptrStructIntMap) Clear() { - _swig_wrap_StructIntMap_clear(arg1) -} - -var _wrap_StructIntMap_get unsafe.Pointer - -func _swig_wrap_StructIntMap_get(base SwigcptrStructIntMap, _ uintptr) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_StructIntMap_get, _swig_p) - return -} - -func (arg1 SwigcptrStructIntMap) Get(arg2 Struct) (_swig_ret int) { - return _swig_wrap_StructIntMap_get(arg1, arg2.Swigcptr()) -} - -var _wrap_StructIntMap_set unsafe.Pointer - -func _swig_wrap_StructIntMap_set(base SwigcptrStructIntMap, _ uintptr, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_StructIntMap_set, _swig_p) - return -} - -func (arg1 SwigcptrStructIntMap) Set(arg2 Struct, arg3 int) { - _swig_wrap_StructIntMap_set(arg1, arg2.Swigcptr(), arg3) -} - -var _wrap_StructIntMap_del unsafe.Pointer - -func _swig_wrap_StructIntMap_del(base SwigcptrStructIntMap, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_StructIntMap_del, _swig_p) - return -} - -func (arg1 SwigcptrStructIntMap) Del(arg2 Struct) { - _swig_wrap_StructIntMap_del(arg1, arg2.Swigcptr()) -} - -var _wrap_StructIntMap_has_key unsafe.Pointer - -func _swig_wrap_StructIntMap_has_key(base SwigcptrStructIntMap, _ uintptr) (_ bool) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_StructIntMap_has_key, _swig_p) - return -} - -func (arg1 SwigcptrStructIntMap) Has_key(arg2 Struct) (_swig_ret bool) { - return _swig_wrap_StructIntMap_has_key(arg1, arg2.Swigcptr()) -} - -var _wrap_delete_StructIntMap unsafe.Pointer - -func _swig_wrap_delete_StructIntMap(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_StructIntMap, _swig_p) - return -} - -func DeleteStructIntMap(arg1 StructIntMap) { - _swig_wrap_delete_StructIntMap(arg1.Swigcptr()) -} - -type StructIntMap interface { - Swigcptr() uintptr - SwigIsStructIntMap() - Size() (_swig_ret uint) - Empty() (_swig_ret bool) - Clear() - Get(arg2 Struct) (_swig_ret int) - Set(arg2 Struct, arg3 int) - Del(arg2 Struct) - Has_key(arg2 Struct) (_swig_ret bool) -} - -type SwigcptrA uintptr - -func (p SwigcptrA) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrA) SwigIsA() { -} - -var _wrap_A_val_set unsafe.Pointer - -func _swig_wrap_A_val_set(base SwigcptrA, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_A_val_set, _swig_p) - return -} - -func (arg1 SwigcptrA) SetVal(arg2 int) { - _swig_wrap_A_val_set(arg1, arg2) -} - -var _wrap_A_val_get unsafe.Pointer - -func _swig_wrap_A_val_get(base SwigcptrA) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_A_val_get, _swig_p) - return -} - -func (arg1 SwigcptrA) GetVal() (_swig_ret int) { - return _swig_wrap_A_val_get(arg1) -} - -var _wrap_new_A__SWIG_0 unsafe.Pointer - -func _swig_wrap_new_A__SWIG_0(base int) (_ SwigcptrA) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_A__SWIG_0, _swig_p) - return -} - -func NewA__SWIG_0(arg1 int) (_swig_ret A) { - return _swig_wrap_new_A__SWIG_0(arg1) -} - -var _wrap_new_A__SWIG_1 unsafe.Pointer - -func _swig_wrap_new_A__SWIG_1() (base SwigcptrA) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_A__SWIG_1, _swig_p) - return -} - -func NewA__SWIG_1() (_swig_ret A) { - return _swig_wrap_new_A__SWIG_1() -} - -func NewA(a ...interface{}) A { - argc := len(a) - if argc == 0 { - return NewA__SWIG_1() - } - if argc == 1 { - return NewA__SWIG_0(a[0].(int)) - } - panic("No match for overloaded function call") -} - -var _wrap_delete_A unsafe.Pointer - -func _swig_wrap_delete_A(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_A, _swig_p) - return -} - -func DeleteA(arg1 A) { - _swig_wrap_delete_A(arg1.Swigcptr()) -} - -type A interface { - Swigcptr() uintptr - SwigIsA() - SetVal(arg2 int) - GetVal() (_swig_ret int) -} - -type SwigcptrPairii uintptr - -func (p SwigcptrPairii) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrPairii) SwigIsPairii() { -} - -var _wrap_new_pairii__SWIG_0 unsafe.Pointer - -func _swig_wrap_new_pairii__SWIG_0() (base SwigcptrPairii) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_pairii__SWIG_0, _swig_p) - return -} - -func NewPairii__SWIG_0() (_swig_ret Pairii) { - return _swig_wrap_new_pairii__SWIG_0() -} - -var _wrap_new_pairii__SWIG_1 unsafe.Pointer - -func _swig_wrap_new_pairii__SWIG_1(base int, _ int) (_ SwigcptrPairii) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_pairii__SWIG_1, _swig_p) - return -} - -func NewPairii__SWIG_1(arg1 int, arg2 int) (_swig_ret Pairii) { - return _swig_wrap_new_pairii__SWIG_1(arg1, arg2) -} - -var _wrap_new_pairii__SWIG_2 unsafe.Pointer - -func _swig_wrap_new_pairii__SWIG_2(base uintptr) (_ SwigcptrPairii) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_pairii__SWIG_2, _swig_p) - return -} - -func NewPairii__SWIG_2(arg1 Pairii) (_swig_ret Pairii) { - return _swig_wrap_new_pairii__SWIG_2(arg1.Swigcptr()) -} - -func NewPairii(a ...interface{}) Pairii { - argc := len(a) - if argc == 0 { - return NewPairii__SWIG_0() - } - if argc == 1 { - return NewPairii__SWIG_2(a[0].(Pairii)) - } - if argc == 2 { - return NewPairii__SWIG_1(a[0].(int), a[1].(int)) - } - panic("No match for overloaded function call") -} - -var _wrap_pairii_first_set unsafe.Pointer - -func _swig_wrap_pairii_first_set(base SwigcptrPairii, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_pairii_first_set, _swig_p) - return -} - -func (arg1 SwigcptrPairii) SetFirst(arg2 int) { - _swig_wrap_pairii_first_set(arg1, arg2) -} - -var _wrap_pairii_first_get unsafe.Pointer - -func _swig_wrap_pairii_first_get(base SwigcptrPairii) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_pairii_first_get, _swig_p) - return -} - -func (arg1 SwigcptrPairii) GetFirst() (_swig_ret int) { - return _swig_wrap_pairii_first_get(arg1) -} - -var _wrap_pairii_second_set unsafe.Pointer - -func _swig_wrap_pairii_second_set(base SwigcptrPairii, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_pairii_second_set, _swig_p) - return -} - -func (arg1 SwigcptrPairii) SetSecond(arg2 int) { - _swig_wrap_pairii_second_set(arg1, arg2) -} - -var _wrap_pairii_second_get unsafe.Pointer - -func _swig_wrap_pairii_second_get(base SwigcptrPairii) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_pairii_second_get, _swig_p) - return -} - -func (arg1 SwigcptrPairii) GetSecond() (_swig_ret int) { - return _swig_wrap_pairii_second_get(arg1) -} - -var _wrap_delete_pairii unsafe.Pointer - -func _swig_wrap_delete_pairii(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_pairii, _swig_p) - return -} - -func DeletePairii(arg1 Pairii) { - _swig_wrap_delete_pairii(arg1.Swigcptr()) -} - -type Pairii interface { - Swigcptr() uintptr - SwigIsPairii() - SetFirst(arg2 int) - GetFirst() (_swig_ret int) - SetSecond(arg2 int) - GetSecond() (_swig_ret int) -} - -type SwigcptrPairAA uintptr - -func (p SwigcptrPairAA) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrPairAA) SwigIsPairAA() { -} - -var _wrap_new_pairAA__SWIG_0 unsafe.Pointer - -func _swig_wrap_new_pairAA__SWIG_0() (base SwigcptrPairAA) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_pairAA__SWIG_0, _swig_p) - return -} - -func NewPairAA__SWIG_0() (_swig_ret PairAA) { - return _swig_wrap_new_pairAA__SWIG_0() -} - -var _wrap_new_pairAA__SWIG_1 unsafe.Pointer - -func _swig_wrap_new_pairAA__SWIG_1(base int, _ uintptr) (_ SwigcptrPairAA) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_pairAA__SWIG_1, _swig_p) - return -} - -func NewPairAA__SWIG_1(arg1 int, arg2 A) (_swig_ret PairAA) { - return _swig_wrap_new_pairAA__SWIG_1(arg1, arg2.Swigcptr()) -} - -var _wrap_new_pairAA__SWIG_2 unsafe.Pointer - -func _swig_wrap_new_pairAA__SWIG_2(base uintptr) (_ SwigcptrPairAA) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_pairAA__SWIG_2, _swig_p) - return -} - -func NewPairAA__SWIG_2(arg1 PairAA) (_swig_ret PairAA) { - return _swig_wrap_new_pairAA__SWIG_2(arg1.Swigcptr()) -} - -func NewPairAA(a ...interface{}) PairAA { - argc := len(a) - if argc == 0 { - return NewPairAA__SWIG_0() - } - if argc == 1 { - return NewPairAA__SWIG_2(a[0].(PairAA)) - } - if argc == 2 { - return NewPairAA__SWIG_1(a[0].(int), a[1].(A)) - } - panic("No match for overloaded function call") -} - -var _wrap_pairAA_first_set unsafe.Pointer - -func _swig_wrap_pairAA_first_set(base SwigcptrPairAA, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_pairAA_first_set, _swig_p) - return -} - -func (arg1 SwigcptrPairAA) SetFirst(arg2 int) { - _swig_wrap_pairAA_first_set(arg1, arg2) -} - -var _wrap_pairAA_first_get unsafe.Pointer - -func _swig_wrap_pairAA_first_get(base SwigcptrPairAA) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_pairAA_first_get, _swig_p) - return -} - -func (arg1 SwigcptrPairAA) GetFirst() (_swig_ret int) { - return _swig_wrap_pairAA_first_get(arg1) -} - -var _wrap_pairAA_second_set unsafe.Pointer - -func _swig_wrap_pairAA_second_set(base SwigcptrPairAA, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_pairAA_second_set, _swig_p) - return -} - -func (arg1 SwigcptrPairAA) SetSecond(arg2 A) { - _swig_wrap_pairAA_second_set(arg1, arg2.Swigcptr()) -} - -var _wrap_pairAA_second_get unsafe.Pointer - -func _swig_wrap_pairAA_second_get(base SwigcptrPairAA) (_ SwigcptrA) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_pairAA_second_get, _swig_p) - return -} - -func (arg1 SwigcptrPairAA) GetSecond() (_swig_ret A) { - return _swig_wrap_pairAA_second_get(arg1) -} - -var _wrap_delete_pairAA unsafe.Pointer - -func _swig_wrap_delete_pairAA(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_pairAA, _swig_p) - return -} - -func DeletePairAA(arg1 PairAA) { - _swig_wrap_delete_pairAA(arg1.Swigcptr()) -} - -type PairAA interface { - Swigcptr() uintptr - SwigIsPairAA() - SetFirst(arg2 int) - GetFirst() (_swig_ret int) - SetSecond(arg2 A) - GetSecond() (_swig_ret A) -} - -type SwigcptrPairA uintptr - -func (p SwigcptrPairA) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrPairA) SwigIsPairA() { -} - -var _wrap_new_pairA__SWIG_0 unsafe.Pointer - -func _swig_wrap_new_pairA__SWIG_0() (base SwigcptrPairA) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_pairA__SWIG_0, _swig_p) - return -} - -func NewPairA__SWIG_0() (_swig_ret PairA) { - return _swig_wrap_new_pairA__SWIG_0() -} - -var _wrap_new_pairA__SWIG_1 unsafe.Pointer - -func _swig_wrap_new_pairA__SWIG_1(base int, _ uintptr) (_ SwigcptrPairA) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_pairA__SWIG_1, _swig_p) - return -} - -func NewPairA__SWIG_1(arg1 int, arg2 A) (_swig_ret PairA) { - return _swig_wrap_new_pairA__SWIG_1(arg1, arg2.Swigcptr()) -} - -var _wrap_new_pairA__SWIG_2 unsafe.Pointer - -func _swig_wrap_new_pairA__SWIG_2(base uintptr) (_ SwigcptrPairA) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_pairA__SWIG_2, _swig_p) - return -} - -func NewPairA__SWIG_2(arg1 PairA) (_swig_ret PairA) { - return _swig_wrap_new_pairA__SWIG_2(arg1.Swigcptr()) -} - -func NewPairA(a ...interface{}) PairA { - argc := len(a) - if argc == 0 { - return NewPairA__SWIG_0() - } - if argc == 1 { - return NewPairA__SWIG_2(a[0].(PairA)) - } - if argc == 2 { - return NewPairA__SWIG_1(a[0].(int), a[1].(A)) - } - panic("No match for overloaded function call") -} - -var _wrap_pairA_first_set unsafe.Pointer - -func _swig_wrap_pairA_first_set(base SwigcptrPairA, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_pairA_first_set, _swig_p) - return -} - -func (arg1 SwigcptrPairA) SetFirst(arg2 int) { - _swig_wrap_pairA_first_set(arg1, arg2) -} - -var _wrap_pairA_first_get unsafe.Pointer - -func _swig_wrap_pairA_first_get(base SwigcptrPairA) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_pairA_first_get, _swig_p) - return -} - -func (arg1 SwigcptrPairA) GetFirst() (_swig_ret int) { - return _swig_wrap_pairA_first_get(arg1) -} - -var _wrap_pairA_second_set unsafe.Pointer - -func _swig_wrap_pairA_second_set(base SwigcptrPairA, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_pairA_second_set, _swig_p) - return -} - -func (arg1 SwigcptrPairA) SetSecond(arg2 A) { - _swig_wrap_pairA_second_set(arg1, arg2.Swigcptr()) -} - -var _wrap_pairA_second_get unsafe.Pointer - -func _swig_wrap_pairA_second_get(base SwigcptrPairA) (_ SwigcptrA) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_pairA_second_get, _swig_p) - return -} - -func (arg1 SwigcptrPairA) GetSecond() (_swig_ret A) { - return _swig_wrap_pairA_second_get(arg1) -} - -var _wrap_delete_pairA unsafe.Pointer - -func _swig_wrap_delete_pairA(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_pairA, _swig_p) - return -} - -func DeletePairA(arg1 PairA) { - _swig_wrap_delete_pairA(arg1.Swigcptr()) -} - -type PairA interface { - Swigcptr() uintptr - SwigIsPairA() - SetFirst(arg2 int) - GetFirst() (_swig_ret int) - SetSecond(arg2 A) - GetSecond() (_swig_ret A) -} - -type SwigcptrMapA uintptr - -func (p SwigcptrMapA) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrMapA) SwigIsMapA() { -} - -var _wrap_new_mapA__SWIG_0 unsafe.Pointer - -func _swig_wrap_new_mapA__SWIG_0() (base SwigcptrMapA) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_mapA__SWIG_0, _swig_p) - return -} - -func NewMapA__SWIG_0() (_swig_ret MapA) { - return _swig_wrap_new_mapA__SWIG_0() -} - -var _wrap_new_mapA__SWIG_1 unsafe.Pointer - -func _swig_wrap_new_mapA__SWIG_1(base uintptr) (_ SwigcptrMapA) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_mapA__SWIG_1, _swig_p) - return -} - -func NewMapA__SWIG_1(arg1 MapA) (_swig_ret MapA) { - return _swig_wrap_new_mapA__SWIG_1(arg1.Swigcptr()) -} - -func NewMapA(a ...interface{}) MapA { - argc := len(a) - if argc == 0 { - return NewMapA__SWIG_0() - } - if argc == 1 { - return NewMapA__SWIG_1(a[0].(MapA)) - } - panic("No match for overloaded function call") -} - -var _wrap_mapA_size unsafe.Pointer - -func _swig_wrap_mapA_size(base SwigcptrMapA) (_ uint) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_mapA_size, _swig_p) - return -} - -func (arg1 SwigcptrMapA) Size() (_swig_ret uint) { - return _swig_wrap_mapA_size(arg1) -} - -var _wrap_mapA_empty unsafe.Pointer - -func _swig_wrap_mapA_empty(base SwigcptrMapA) (_ bool) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_mapA_empty, _swig_p) - return -} - -func (arg1 SwigcptrMapA) Empty() (_swig_ret bool) { - return _swig_wrap_mapA_empty(arg1) -} - -var _wrap_mapA_clear unsafe.Pointer - -func _swig_wrap_mapA_clear(base SwigcptrMapA) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_mapA_clear, _swig_p) - return -} - -func (arg1 SwigcptrMapA) Clear() { - _swig_wrap_mapA_clear(arg1) -} - -var _wrap_mapA_get unsafe.Pointer - -func _swig_wrap_mapA_get(base SwigcptrMapA, _ int) (_ SwigcptrA) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_mapA_get, _swig_p) - return -} - -func (arg1 SwigcptrMapA) Get(arg2 int) (_swig_ret A) { - return _swig_wrap_mapA_get(arg1, arg2) -} - -var _wrap_mapA_set unsafe.Pointer - -func _swig_wrap_mapA_set(base SwigcptrMapA, _ int, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_mapA_set, _swig_p) - return -} - -func (arg1 SwigcptrMapA) Set(arg2 int, arg3 A) { - _swig_wrap_mapA_set(arg1, arg2, arg3.Swigcptr()) -} - -var _wrap_mapA_del unsafe.Pointer - -func _swig_wrap_mapA_del(base SwigcptrMapA, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_mapA_del, _swig_p) - return -} - -func (arg1 SwigcptrMapA) Del(arg2 int) { - _swig_wrap_mapA_del(arg1, arg2) -} - -var _wrap_mapA_has_key unsafe.Pointer - -func _swig_wrap_mapA_has_key(base SwigcptrMapA, _ int) (_ bool) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_mapA_has_key, _swig_p) - return -} - -func (arg1 SwigcptrMapA) Has_key(arg2 int) (_swig_ret bool) { - return _swig_wrap_mapA_has_key(arg1, arg2) -} - -var _wrap_delete_mapA unsafe.Pointer - -func _swig_wrap_delete_mapA(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_mapA, _swig_p) - return -} - -func DeleteMapA(arg1 MapA) { - _swig_wrap_delete_mapA(arg1.Swigcptr()) -} - -type MapA interface { - Swigcptr() uintptr - SwigIsMapA() - Size() (_swig_ret uint) - Empty() (_swig_ret bool) - Clear() - Get(arg2 int) (_swig_ret A) - Set(arg2 int, arg3 A) - Del(arg2 int) - Has_key(arg2 int) (_swig_ret bool) -} - -type SwigcptrPaircA1 uintptr - -func (p SwigcptrPaircA1) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrPaircA1) SwigIsPaircA1() { -} - -var _wrap_new_paircA1__SWIG_0 unsafe.Pointer - -func _swig_wrap_new_paircA1__SWIG_0() (base SwigcptrPaircA1) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_paircA1__SWIG_0, _swig_p) - return -} - -func NewPaircA1__SWIG_0() (_swig_ret PaircA1) { - return _swig_wrap_new_paircA1__SWIG_0() -} - -var _wrap_new_paircA1__SWIG_1 unsafe.Pointer - -func _swig_wrap_new_paircA1__SWIG_1(base int, _ uintptr) (_ SwigcptrPaircA1) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_paircA1__SWIG_1, _swig_p) - return -} - -func NewPaircA1__SWIG_1(arg1 int, arg2 A) (_swig_ret PaircA1) { - return _swig_wrap_new_paircA1__SWIG_1(arg1, arg2.Swigcptr()) -} - -var _wrap_new_paircA1__SWIG_2 unsafe.Pointer - -func _swig_wrap_new_paircA1__SWIG_2(base uintptr) (_ SwigcptrPaircA1) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_paircA1__SWIG_2, _swig_p) - return -} - -func NewPaircA1__SWIG_2(arg1 PaircA1) (_swig_ret PaircA1) { - return _swig_wrap_new_paircA1__SWIG_2(arg1.Swigcptr()) -} - -func NewPaircA1(a ...interface{}) PaircA1 { - argc := len(a) - if argc == 0 { - return NewPaircA1__SWIG_0() - } - if argc == 1 { - return NewPaircA1__SWIG_2(a[0].(PaircA1)) - } - if argc == 2 { - return NewPaircA1__SWIG_1(a[0].(int), a[1].(A)) - } - panic("No match for overloaded function call") -} - -var _wrap_paircA1_first_get unsafe.Pointer - -func _swig_wrap_paircA1_first_get(base SwigcptrPaircA1) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_paircA1_first_get, _swig_p) - return -} - -func (arg1 SwigcptrPaircA1) GetFirst() (_swig_ret int) { - return _swig_wrap_paircA1_first_get(arg1) -} - -var _wrap_paircA1_second_set unsafe.Pointer - -func _swig_wrap_paircA1_second_set(base SwigcptrPaircA1, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_paircA1_second_set, _swig_p) - return -} - -func (arg1 SwigcptrPaircA1) SetSecond(arg2 A) { - _swig_wrap_paircA1_second_set(arg1, arg2.Swigcptr()) -} - -var _wrap_paircA1_second_get unsafe.Pointer - -func _swig_wrap_paircA1_second_get(base SwigcptrPaircA1) (_ SwigcptrA) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_paircA1_second_get, _swig_p) - return -} - -func (arg1 SwigcptrPaircA1) GetSecond() (_swig_ret A) { - return _swig_wrap_paircA1_second_get(arg1) -} - -var _wrap_delete_paircA1 unsafe.Pointer - -func _swig_wrap_delete_paircA1(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_paircA1, _swig_p) - return -} - -func DeletePaircA1(arg1 PaircA1) { - _swig_wrap_delete_paircA1(arg1.Swigcptr()) -} - -type PaircA1 interface { - Swigcptr() uintptr - SwigIsPaircA1() - GetFirst() (_swig_ret int) - SetSecond(arg2 A) - GetSecond() (_swig_ret A) -} - -type SwigcptrPaircA2 uintptr - -func (p SwigcptrPaircA2) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrPaircA2) SwigIsPaircA2() { -} - -var _wrap_new_paircA2__SWIG_0 unsafe.Pointer - -func _swig_wrap_new_paircA2__SWIG_0() (base SwigcptrPaircA2) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_paircA2__SWIG_0, _swig_p) - return -} - -func NewPaircA2__SWIG_0() (_swig_ret PaircA2) { - return _swig_wrap_new_paircA2__SWIG_0() -} - -var _wrap_new_paircA2__SWIG_1 unsafe.Pointer - -func _swig_wrap_new_paircA2__SWIG_1(base int, _ uintptr) (_ SwigcptrPaircA2) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_paircA2__SWIG_1, _swig_p) - return -} - -func NewPaircA2__SWIG_1(arg1 int, arg2 A) (_swig_ret PaircA2) { - return _swig_wrap_new_paircA2__SWIG_1(arg1, arg2.Swigcptr()) -} - -var _wrap_new_paircA2__SWIG_2 unsafe.Pointer - -func _swig_wrap_new_paircA2__SWIG_2(base uintptr) (_ SwigcptrPaircA2) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_paircA2__SWIG_2, _swig_p) - return -} - -func NewPaircA2__SWIG_2(arg1 PaircA2) (_swig_ret PaircA2) { - return _swig_wrap_new_paircA2__SWIG_2(arg1.Swigcptr()) -} - -func NewPaircA2(a ...interface{}) PaircA2 { - argc := len(a) - if argc == 0 { - return NewPaircA2__SWIG_0() - } - if argc == 1 { - return NewPaircA2__SWIG_2(a[0].(PaircA2)) - } - if argc == 2 { - return NewPaircA2__SWIG_1(a[0].(int), a[1].(A)) - } - panic("No match for overloaded function call") -} - -var _wrap_paircA2_first_get unsafe.Pointer - -func _swig_wrap_paircA2_first_get(base SwigcptrPaircA2) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_paircA2_first_get, _swig_p) - return -} - -func (arg1 SwigcptrPaircA2) GetFirst() (_swig_ret int) { - return _swig_wrap_paircA2_first_get(arg1) -} - -var _wrap_paircA2_second_set unsafe.Pointer - -func _swig_wrap_paircA2_second_set(base SwigcptrPaircA2, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_paircA2_second_set, _swig_p) - return -} - -func (arg1 SwigcptrPaircA2) SetSecond(arg2 A) { - _swig_wrap_paircA2_second_set(arg1, arg2.Swigcptr()) -} - -var _wrap_paircA2_second_get unsafe.Pointer - -func _swig_wrap_paircA2_second_get(base SwigcptrPaircA2) (_ SwigcptrA) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_paircA2_second_get, _swig_p) - return -} - -func (arg1 SwigcptrPaircA2) GetSecond() (_swig_ret A) { - return _swig_wrap_paircA2_second_get(arg1) -} - -var _wrap_delete_paircA2 unsafe.Pointer - -func _swig_wrap_delete_paircA2(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_paircA2, _swig_p) - return -} - -func DeletePaircA2(arg1 PaircA2) { - _swig_wrap_delete_paircA2(arg1.Swigcptr()) -} - -type PaircA2 interface { - Swigcptr() uintptr - SwigIsPaircA2() - GetFirst() (_swig_ret int) - SetSecond(arg2 A) - GetSecond() (_swig_ret A) -} - -type SwigcptrPairiiA uintptr - -func (p SwigcptrPairiiA) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrPairiiA) SwigIsPairiiA() { -} - -var _wrap_new_pairiiA__SWIG_0 unsafe.Pointer - -func _swig_wrap_new_pairiiA__SWIG_0() (base SwigcptrPairiiA) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_pairiiA__SWIG_0, _swig_p) - return -} - -func NewPairiiA__SWIG_0() (_swig_ret PairiiA) { - return _swig_wrap_new_pairiiA__SWIG_0() -} - -var _wrap_new_pairiiA__SWIG_1 unsafe.Pointer - -func _swig_wrap_new_pairiiA__SWIG_1(base int, _ uintptr) (_ SwigcptrPairiiA) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_pairiiA__SWIG_1, _swig_p) - return -} - -func NewPairiiA__SWIG_1(arg1 int, arg2 PairA) (_swig_ret PairiiA) { - return _swig_wrap_new_pairiiA__SWIG_1(arg1, arg2.Swigcptr()) -} - -var _wrap_new_pairiiA__SWIG_2 unsafe.Pointer - -func _swig_wrap_new_pairiiA__SWIG_2(base uintptr) (_ SwigcptrPairiiA) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_pairiiA__SWIG_2, _swig_p) - return -} - -func NewPairiiA__SWIG_2(arg1 PairiiA) (_swig_ret PairiiA) { - return _swig_wrap_new_pairiiA__SWIG_2(arg1.Swigcptr()) -} - -func NewPairiiA(a ...interface{}) PairiiA { - argc := len(a) - if argc == 0 { - return NewPairiiA__SWIG_0() - } - if argc == 1 { - return NewPairiiA__SWIG_2(a[0].(PairiiA)) - } - if argc == 2 { - return NewPairiiA__SWIG_1(a[0].(int), a[1].(PairA)) - } - panic("No match for overloaded function call") -} - -var _wrap_pairiiA_first_set unsafe.Pointer - -func _swig_wrap_pairiiA_first_set(base SwigcptrPairiiA, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_pairiiA_first_set, _swig_p) - return -} - -func (arg1 SwigcptrPairiiA) SetFirst(arg2 int) { - _swig_wrap_pairiiA_first_set(arg1, arg2) -} - -var _wrap_pairiiA_first_get unsafe.Pointer - -func _swig_wrap_pairiiA_first_get(base SwigcptrPairiiA) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_pairiiA_first_get, _swig_p) - return -} - -func (arg1 SwigcptrPairiiA) GetFirst() (_swig_ret int) { - return _swig_wrap_pairiiA_first_get(arg1) -} - -var _wrap_pairiiA_second_set unsafe.Pointer - -func _swig_wrap_pairiiA_second_set(base SwigcptrPairiiA, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_pairiiA_second_set, _swig_p) - return -} - -func (arg1 SwigcptrPairiiA) SetSecond(arg2 PairA) { - _swig_wrap_pairiiA_second_set(arg1, arg2.Swigcptr()) -} - -var _wrap_pairiiA_second_get unsafe.Pointer - -func _swig_wrap_pairiiA_second_get(base SwigcptrPairiiA) (_ SwigcptrPairA) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_pairiiA_second_get, _swig_p) - return -} - -func (arg1 SwigcptrPairiiA) GetSecond() (_swig_ret PairA) { - return _swig_wrap_pairiiA_second_get(arg1) -} - -var _wrap_delete_pairiiA unsafe.Pointer - -func _swig_wrap_delete_pairiiA(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_pairiiA, _swig_p) - return -} - -func DeletePairiiA(arg1 PairiiA) { - _swig_wrap_delete_pairiiA(arg1.Swigcptr()) -} - -type PairiiA interface { - Swigcptr() uintptr - SwigIsPairiiA() - SetFirst(arg2 int) - GetFirst() (_swig_ret int) - SetSecond(arg2 PairA) - GetSecond() (_swig_ret PairA) -} - -type SwigcptrPairiiAc uintptr - -func (p SwigcptrPairiiAc) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrPairiiAc) SwigIsPairiiAc() { -} - -var _wrap_new_pairiiAc__SWIG_0 unsafe.Pointer - -func _swig_wrap_new_pairiiAc__SWIG_0() (base SwigcptrPairiiAc) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_pairiiAc__SWIG_0, _swig_p) - return -} - -func NewPairiiAc__SWIG_0() (_swig_ret PairiiAc) { - return _swig_wrap_new_pairiiAc__SWIG_0() -} - -var _wrap_new_pairiiAc__SWIG_1 unsafe.Pointer - -func _swig_wrap_new_pairiiAc__SWIG_1(base int, _ uintptr) (_ SwigcptrPairiiAc) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_pairiiAc__SWIG_1, _swig_p) - return -} - -func NewPairiiAc__SWIG_1(arg1 int, arg2 PairA) (_swig_ret PairiiAc) { - return _swig_wrap_new_pairiiAc__SWIG_1(arg1, arg2.Swigcptr()) -} - -var _wrap_new_pairiiAc__SWIG_2 unsafe.Pointer - -func _swig_wrap_new_pairiiAc__SWIG_2(base uintptr) (_ SwigcptrPairiiAc) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_pairiiAc__SWIG_2, _swig_p) - return -} - -func NewPairiiAc__SWIG_2(arg1 PairiiAc) (_swig_ret PairiiAc) { - return _swig_wrap_new_pairiiAc__SWIG_2(arg1.Swigcptr()) -} - -func NewPairiiAc(a ...interface{}) PairiiAc { - argc := len(a) - if argc == 0 { - return NewPairiiAc__SWIG_0() - } - if argc == 1 { - return NewPairiiAc__SWIG_2(a[0].(PairiiAc)) - } - if argc == 2 { - return NewPairiiAc__SWIG_1(a[0].(int), a[1].(PairA)) - } - panic("No match for overloaded function call") -} - -var _wrap_pairiiAc_first_set unsafe.Pointer - -func _swig_wrap_pairiiAc_first_set(base SwigcptrPairiiAc, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_pairiiAc_first_set, _swig_p) - return -} - -func (arg1 SwigcptrPairiiAc) SetFirst(arg2 int) { - _swig_wrap_pairiiAc_first_set(arg1, arg2) -} - -var _wrap_pairiiAc_first_get unsafe.Pointer - -func _swig_wrap_pairiiAc_first_get(base SwigcptrPairiiAc) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_pairiiAc_first_get, _swig_p) - return -} - -func (arg1 SwigcptrPairiiAc) GetFirst() (_swig_ret int) { - return _swig_wrap_pairiiAc_first_get(arg1) -} - -var _wrap_pairiiAc_second_get unsafe.Pointer - -func _swig_wrap_pairiiAc_second_get(base SwigcptrPairiiAc) (_ SwigcptrPairA) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_pairiiAc_second_get, _swig_p) - return -} - -func (arg1 SwigcptrPairiiAc) GetSecond() (_swig_ret PairA) { - return _swig_wrap_pairiiAc_second_get(arg1) -} - -var _wrap_delete_pairiiAc unsafe.Pointer - -func _swig_wrap_delete_pairiiAc(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_pairiiAc, _swig_p) - return -} - -func DeletePairiiAc(arg1 PairiiAc) { - _swig_wrap_delete_pairiiAc(arg1.Swigcptr()) -} - -type PairiiAc interface { - Swigcptr() uintptr - SwigIsPairiiAc() - SetFirst(arg2 int) - GetFirst() (_swig_ret int) - GetSecond() (_swig_ret PairA) -} - -var _wrap_p_identa unsafe.Pointer - -func _swig_wrap_p_identa(base uintptr) (_ SwigcptrPairA) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_p_identa, _swig_p) - return -} - -func P_identa(arg1 PairA) (_swig_ret PairA) { - return _swig_wrap_p_identa(arg1.Swigcptr()) -} - -var _wrap_m_identa unsafe.Pointer - -func _swig_wrap_m_identa(base uintptr) (_ SwigcptrMapA) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_m_identa, _swig_p) - return -} - -func M_identa(arg1 MapA) (_swig_ret MapA) { - return _swig_wrap_m_identa(arg1.Swigcptr()) -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/li_std_map_runme b/Examples/test-suite/go/li_std_map_runme deleted file mode 100755 index ab7aa0af1..000000000 Binary files a/Examples/test-suite/go/li_std_map_runme and /dev/null differ diff --git a/Examples/test-suite/go/li_std_pair.go b/Examples/test-suite/go/li_std_pair.go deleted file mode 100644 index fba461400..000000000 --- a/Examples/test-suite/go/li_std_pair.go +++ /dev/null @@ -1,249 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../li_std_pair.i - -package li_std_pair - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrIntPair uintptr - -func (p SwigcptrIntPair) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrIntPair) SwigIsIntPair() { -} - -var _wrap_new_IntPair__SWIG_0 unsafe.Pointer - -func _swig_wrap_new_IntPair__SWIG_0() (base SwigcptrIntPair) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_IntPair__SWIG_0, _swig_p) - return -} - -func NewIntPair__SWIG_0() (_swig_ret IntPair) { - return _swig_wrap_new_IntPair__SWIG_0() -} - -var _wrap_new_IntPair__SWIG_1 unsafe.Pointer - -func _swig_wrap_new_IntPair__SWIG_1(base int, _ int) (_ SwigcptrIntPair) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_IntPair__SWIG_1, _swig_p) - return -} - -func NewIntPair__SWIG_1(arg1 int, arg2 int) (_swig_ret IntPair) { - return _swig_wrap_new_IntPair__SWIG_1(arg1, arg2) -} - -var _wrap_new_IntPair__SWIG_2 unsafe.Pointer - -func _swig_wrap_new_IntPair__SWIG_2(base uintptr) (_ SwigcptrIntPair) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_IntPair__SWIG_2, _swig_p) - return -} - -func NewIntPair__SWIG_2(arg1 IntPair) (_swig_ret IntPair) { - return _swig_wrap_new_IntPair__SWIG_2(arg1.Swigcptr()) -} - -func NewIntPair(a ...interface{}) IntPair { - argc := len(a) - if argc == 0 { - return NewIntPair__SWIG_0() - } - if argc == 1 { - return NewIntPair__SWIG_2(a[0].(IntPair)) - } - if argc == 2 { - return NewIntPair__SWIG_1(a[0].(int), a[1].(int)) - } - panic("No match for overloaded function call") -} - -var _wrap_IntPair_first_set unsafe.Pointer - -func _swig_wrap_IntPair_first_set(base SwigcptrIntPair, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_IntPair_first_set, _swig_p) - return -} - -func (arg1 SwigcptrIntPair) SetFirst(arg2 int) { - _swig_wrap_IntPair_first_set(arg1, arg2) -} - -var _wrap_IntPair_first_get unsafe.Pointer - -func _swig_wrap_IntPair_first_get(base SwigcptrIntPair) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_IntPair_first_get, _swig_p) - return -} - -func (arg1 SwigcptrIntPair) GetFirst() (_swig_ret int) { - return _swig_wrap_IntPair_first_get(arg1) -} - -var _wrap_IntPair_second_set unsafe.Pointer - -func _swig_wrap_IntPair_second_set(base SwigcptrIntPair, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_IntPair_second_set, _swig_p) - return -} - -func (arg1 SwigcptrIntPair) SetSecond(arg2 int) { - _swig_wrap_IntPair_second_set(arg1, arg2) -} - -var _wrap_IntPair_second_get unsafe.Pointer - -func _swig_wrap_IntPair_second_get(base SwigcptrIntPair) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_IntPair_second_get, _swig_p) - return -} - -func (arg1 SwigcptrIntPair) GetSecond() (_swig_ret int) { - return _swig_wrap_IntPair_second_get(arg1) -} - -var _wrap_delete_IntPair unsafe.Pointer - -func _swig_wrap_delete_IntPair(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_IntPair, _swig_p) - return -} - -func DeleteIntPair(arg1 IntPair) { - _swig_wrap_delete_IntPair(arg1.Swigcptr()) -} - -type IntPair interface { - Swigcptr() uintptr - SwigIsIntPair() - SetFirst(arg2 int) - GetFirst() (_swig_ret int) - SetSecond(arg2 int) - GetSecond() (_swig_ret int) -} - -var _wrap_makeIntPair unsafe.Pointer - -func _swig_wrap_makeIntPair(base int, _ int) (_ SwigcptrIntPair) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_makeIntPair, _swig_p) - return -} - -func MakeIntPair(arg1 int, arg2 int) (_swig_ret IntPair) { - return _swig_wrap_makeIntPair(arg1, arg2) -} - -var _wrap_makeIntPairPtr unsafe.Pointer - -func _swig_wrap_makeIntPairPtr(base int, _ int) (_ SwigcptrIntPair) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_makeIntPairPtr, _swig_p) - return -} - -func MakeIntPairPtr(arg1 int, arg2 int) (_swig_ret IntPair) { - return _swig_wrap_makeIntPairPtr(arg1, arg2) -} - -var _wrap_makeIntPairRef unsafe.Pointer - -func _swig_wrap_makeIntPairRef(base int, _ int) (_ SwigcptrIntPair) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_makeIntPairRef, _swig_p) - return -} - -func MakeIntPairRef(arg1 int, arg2 int) (_swig_ret IntPair) { - return _swig_wrap_makeIntPairRef(arg1, arg2) -} - -var _wrap_makeIntPairConstRef unsafe.Pointer - -func _swig_wrap_makeIntPairConstRef(base int, _ int) (_ SwigcptrIntPair) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_makeIntPairConstRef, _swig_p) - return -} - -func MakeIntPairConstRef(arg1 int, arg2 int) (_swig_ret IntPair) { - return _swig_wrap_makeIntPairConstRef(arg1, arg2) -} - -var _wrap_product1 unsafe.Pointer - -func _swig_wrap_product1(base uintptr) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_product1, _swig_p) - return -} - -func Product1(arg1 IntPair) (_swig_ret int) { - return _swig_wrap_product1(arg1.Swigcptr()) -} - -var _wrap_product2 unsafe.Pointer - -func _swig_wrap_product2(base uintptr) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_product2, _swig_p) - return -} - -func Product2(arg1 IntPair) (_swig_ret int) { - return _swig_wrap_product2(arg1.Swigcptr()) -} - -var _wrap_product3 unsafe.Pointer - -func _swig_wrap_product3(base uintptr) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_product3, _swig_p) - return -} - -func Product3(arg1 IntPair) (_swig_ret int) { - return _swig_wrap_product3(arg1.Swigcptr()) -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/li_std_pair_using.go b/Examples/test-suite/go/li_std_pair_using.go deleted file mode 100644 index 8ae4917a5..000000000 --- a/Examples/test-suite/go/li_std_pair_using.go +++ /dev/null @@ -1,305 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../li_std_pair_using.i - -package li_std_pair_using - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrStringStringPair uintptr - -func (p SwigcptrStringStringPair) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrStringStringPair) SwigIsStringStringPair() { -} - -var _wrap_new_StringStringPair__SWIG_0 unsafe.Pointer - -func _swig_wrap_new_StringStringPair__SWIG_0() (base SwigcptrStringStringPair) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_StringStringPair__SWIG_0, _swig_p) - return -} - -func NewStringStringPair__SWIG_0() (_swig_ret StringStringPair) { - return _swig_wrap_new_StringStringPair__SWIG_0() -} - -var _wrap_new_StringStringPair__SWIG_1 unsafe.Pointer - -func _swig_wrap_new_StringStringPair__SWIG_1(base string, _ string) (_ SwigcptrStringStringPair) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_StringStringPair__SWIG_1, _swig_p) - return -} - -func NewStringStringPair__SWIG_1(arg1 string, arg2 string) (_swig_ret StringStringPair) { - return _swig_wrap_new_StringStringPair__SWIG_1(arg1, arg2) -} - -var _wrap_new_StringStringPair__SWIG_2 unsafe.Pointer - -func _swig_wrap_new_StringStringPair__SWIG_2(base uintptr) (_ SwigcptrStringStringPair) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_StringStringPair__SWIG_2, _swig_p) - return -} - -func NewStringStringPair__SWIG_2(arg1 StringStringPair) (_swig_ret StringStringPair) { - return _swig_wrap_new_StringStringPair__SWIG_2(arg1.Swigcptr()) -} - -func NewStringStringPair(a ...interface{}) StringStringPair { - argc := len(a) - if argc == 0 { - return NewStringStringPair__SWIG_0() - } - if argc == 1 { - return NewStringStringPair__SWIG_2(a[0].(StringStringPair)) - } - if argc == 2 { - return NewStringStringPair__SWIG_1(a[0].(string), a[1].(string)) - } - panic("No match for overloaded function call") -} - -var _wrap_StringStringPair_first_set unsafe.Pointer - -func _swig_wrap_StringStringPair_first_set(base SwigcptrStringStringPair, _ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_StringStringPair_first_set, _swig_p) - return -} - -func (arg1 SwigcptrStringStringPair) SetFirst(arg2 string) { - _swig_wrap_StringStringPair_first_set(arg1, arg2) -} - -var _wrap_StringStringPair_first_get unsafe.Pointer - -func _swig_wrap_StringStringPair_first_get(base SwigcptrStringStringPair) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_StringStringPair_first_get, _swig_p) - return -} - -func (arg1 SwigcptrStringStringPair) GetFirst() (_swig_ret string) { - return _swig_wrap_StringStringPair_first_get(arg1) -} - -var _wrap_StringStringPair_second_set unsafe.Pointer - -func _swig_wrap_StringStringPair_second_set(base SwigcptrStringStringPair, _ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_StringStringPair_second_set, _swig_p) - return -} - -func (arg1 SwigcptrStringStringPair) SetSecond(arg2 string) { - _swig_wrap_StringStringPair_second_set(arg1, arg2) -} - -var _wrap_StringStringPair_second_get unsafe.Pointer - -func _swig_wrap_StringStringPair_second_get(base SwigcptrStringStringPair) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_StringStringPair_second_get, _swig_p) - return -} - -func (arg1 SwigcptrStringStringPair) GetSecond() (_swig_ret string) { - return _swig_wrap_StringStringPair_second_get(arg1) -} - -var _wrap_delete_StringStringPair unsafe.Pointer - -func _swig_wrap_delete_StringStringPair(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_StringStringPair, _swig_p) - return -} - -func DeleteStringStringPair(arg1 StringStringPair) { - _swig_wrap_delete_StringStringPair(arg1.Swigcptr()) -} - -type StringStringPair interface { - Swigcptr() uintptr - SwigIsStringStringPair() - SetFirst(arg2 string) - GetFirst() (_swig_ret string) - SetSecond(arg2 string) - GetSecond() (_swig_ret string) -} - -type SwigcptrStringIntPair uintptr - -func (p SwigcptrStringIntPair) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrStringIntPair) SwigIsStringIntPair() { -} - -var _wrap_new_StringIntPair__SWIG_0 unsafe.Pointer - -func _swig_wrap_new_StringIntPair__SWIG_0() (base SwigcptrStringIntPair) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_StringIntPair__SWIG_0, _swig_p) - return -} - -func NewStringIntPair__SWIG_0() (_swig_ret StringIntPair) { - return _swig_wrap_new_StringIntPair__SWIG_0() -} - -var _wrap_new_StringIntPair__SWIG_1 unsafe.Pointer - -func _swig_wrap_new_StringIntPair__SWIG_1(base string, _ int) (_ SwigcptrStringIntPair) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_StringIntPair__SWIG_1, _swig_p) - return -} - -func NewStringIntPair__SWIG_1(arg1 string, arg2 int) (_swig_ret StringIntPair) { - return _swig_wrap_new_StringIntPair__SWIG_1(arg1, arg2) -} - -var _wrap_new_StringIntPair__SWIG_2 unsafe.Pointer - -func _swig_wrap_new_StringIntPair__SWIG_2(base uintptr) (_ SwigcptrStringIntPair) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_StringIntPair__SWIG_2, _swig_p) - return -} - -func NewStringIntPair__SWIG_2(arg1 StringIntPair) (_swig_ret StringIntPair) { - return _swig_wrap_new_StringIntPair__SWIG_2(arg1.Swigcptr()) -} - -func NewStringIntPair(a ...interface{}) StringIntPair { - argc := len(a) - if argc == 0 { - return NewStringIntPair__SWIG_0() - } - if argc == 1 { - return NewStringIntPair__SWIG_2(a[0].(StringIntPair)) - } - if argc == 2 { - return NewStringIntPair__SWIG_1(a[0].(string), a[1].(int)) - } - panic("No match for overloaded function call") -} - -var _wrap_StringIntPair_first_set unsafe.Pointer - -func _swig_wrap_StringIntPair_first_set(base SwigcptrStringIntPair, _ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_StringIntPair_first_set, _swig_p) - return -} - -func (arg1 SwigcptrStringIntPair) SetFirst(arg2 string) { - _swig_wrap_StringIntPair_first_set(arg1, arg2) -} - -var _wrap_StringIntPair_first_get unsafe.Pointer - -func _swig_wrap_StringIntPair_first_get(base SwigcptrStringIntPair) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_StringIntPair_first_get, _swig_p) - return -} - -func (arg1 SwigcptrStringIntPair) GetFirst() (_swig_ret string) { - return _swig_wrap_StringIntPair_first_get(arg1) -} - -var _wrap_StringIntPair_second_set unsafe.Pointer - -func _swig_wrap_StringIntPair_second_set(base SwigcptrStringIntPair, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_StringIntPair_second_set, _swig_p) - return -} - -func (arg1 SwigcptrStringIntPair) SetSecond(arg2 int) { - _swig_wrap_StringIntPair_second_set(arg1, arg2) -} - -var _wrap_StringIntPair_second_get unsafe.Pointer - -func _swig_wrap_StringIntPair_second_get(base SwigcptrStringIntPair) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_StringIntPair_second_get, _swig_p) - return -} - -func (arg1 SwigcptrStringIntPair) GetSecond() (_swig_ret int) { - return _swig_wrap_StringIntPair_second_get(arg1) -} - -var _wrap_delete_StringIntPair unsafe.Pointer - -func _swig_wrap_delete_StringIntPair(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_StringIntPair, _swig_p) - return -} - -func DeleteStringIntPair(arg1 StringIntPair) { - _swig_wrap_delete_StringIntPair(arg1.Swigcptr()) -} - -type StringIntPair interface { - Swigcptr() uintptr - SwigIsStringIntPair() - SetFirst(arg2 string) - GetFirst() (_swig_ret string) - SetSecond(arg2 int) - GetSecond() (_swig_ret int) -} - -var _wrap_bounce unsafe.Pointer - -func _swig_wrap_bounce(base uintptr) (_ SwigcptrStringStringPair) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_bounce, _swig_p) - return -} - -func Bounce(arg1 StringStringPair) (_swig_ret StringStringPair) { - return _swig_wrap_bounce(arg1.Swigcptr()) -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/li_std_string.go b/Examples/test-suite/go/li_std_string.go deleted file mode 100644 index b8f1a9f49..000000000 --- a/Examples/test-suite/go/li_std_string.go +++ /dev/null @@ -1,487 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../li_std_string.i - -package li_std_string - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -var _wrap_test_value unsafe.Pointer - -func Test_value(arg1 string) (_swig_ret string) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_test_value, _swig_p) - return -} -var _wrap_test_const_reference unsafe.Pointer - -func Test_const_reference(arg1 string) (_swig_ret string) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_test_const_reference, _swig_p) - return -} -var _wrap_test_pointer unsafe.Pointer - -func _swig_wrap_test_pointer(base *string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_test_pointer, _swig_p) - return -} - -func Test_pointer(arg1 *string) { - _swig_wrap_test_pointer(arg1) -} - -var _wrap_test_pointer_out unsafe.Pointer - -func Test_pointer_out() (_swig_ret *string) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_test_pointer_out, _swig_p) - return -} -var _wrap_test_const_pointer unsafe.Pointer - -func _swig_wrap_test_const_pointer(base *string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_test_const_pointer, _swig_p) - return -} - -func Test_const_pointer(arg1 *string) { - _swig_wrap_test_const_pointer(arg1) -} - -var _wrap_test_const_pointer_out unsafe.Pointer - -func Test_const_pointer_out() (_swig_ret *string) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_test_const_pointer_out, _swig_p) - return -} -var _wrap_test_reference unsafe.Pointer - -func _swig_wrap_test_reference(base *string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_test_reference, _swig_p) - return -} - -func Test_reference(arg1 *string) { - _swig_wrap_test_reference(arg1) -} - -var _wrap_test_reference_out unsafe.Pointer - -func Test_reference_out() (_swig_ret *string) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_test_reference_out, _swig_p) - return -} -var _wrap_test_reference_input unsafe.Pointer - -func Test_reference_input(arg1 *string) (_swig_ret string) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_test_reference_input, _swig_p) - return -} -var _wrap_test_reference_inout unsafe.Pointer - -func _swig_wrap_test_reference_inout(base *string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_test_reference_inout, _swig_p) - return -} - -func Test_reference_inout(arg1 *string) { - _swig_wrap_test_reference_inout(arg1) -} - -var _wrap_test_throw unsafe.Pointer - -func _swig_wrap_test_throw() { - var _swig_p uintptr - _cgo_runtime_cgocall(_wrap_test_throw, _swig_p) - return -} - -func Test_throw() { - _swig_wrap_test_throw() -} - -var _wrap_test_const_reference_throw unsafe.Pointer - -func _swig_wrap_test_const_reference_throw() { - var _swig_p uintptr - _cgo_runtime_cgocall(_wrap_test_const_reference_throw, _swig_p) - return -} - -func Test_const_reference_throw() { - _swig_wrap_test_const_reference_throw() -} - -var _wrap_test_pointer_throw unsafe.Pointer - -func _swig_wrap_test_pointer_throw() { - var _swig_p uintptr - _cgo_runtime_cgocall(_wrap_test_pointer_throw, _swig_p) - return -} - -func Test_pointer_throw() { - _swig_wrap_test_pointer_throw() -} - -var _wrap_test_const_pointer_throw unsafe.Pointer - -func _swig_wrap_test_const_pointer_throw() { - var _swig_p uintptr - _cgo_runtime_cgocall(_wrap_test_const_pointer_throw, _swig_p) - return -} - -func Test_const_pointer_throw() { - _swig_wrap_test_const_pointer_throw() -} - -var _wrap_GlobalString_set unsafe.Pointer - -func _swig_wrap_GlobalString_set(base string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_GlobalString_set, _swig_p) - return -} - -func SetGlobalString(arg1 string) { - _swig_wrap_GlobalString_set(arg1) -} - -var _wrap_GlobalString_get unsafe.Pointer - -func GetGlobalString() (_swig_ret string) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_GlobalString_get, _swig_p) - return -} -var _wrap_GlobalString2_set unsafe.Pointer - -func _swig_wrap_GlobalString2_set(base string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_GlobalString2_set, _swig_p) - return -} - -func SetGlobalString2(arg1 string) { - _swig_wrap_GlobalString2_set(arg1) -} - -var _wrap_GlobalString2_get unsafe.Pointer - -func GetGlobalString2() (_swig_ret string) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_GlobalString2_get, _swig_p) - return -} -var _wrap_ConstGlobalString_get unsafe.Pointer - -func GetConstGlobalString() (_swig_ret string) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_ConstGlobalString_get, _swig_p) - return -} -type SwigcptrStructure uintptr - -func (p SwigcptrStructure) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrStructure) SwigIsStructure() { -} - -var _wrap_Structure_MemberString_set unsafe.Pointer - -func _swig_wrap_Structure_MemberString_set(base SwigcptrStructure, _ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Structure_MemberString_set, _swig_p) - return -} - -func (arg1 SwigcptrStructure) SetMemberString(arg2 string) { - _swig_wrap_Structure_MemberString_set(arg1, arg2) -} - -var _wrap_Structure_MemberString_get unsafe.Pointer - -func _swig_wrap_Structure_MemberString_get(base SwigcptrStructure) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Structure_MemberString_get, _swig_p) - return -} - -func (arg1 SwigcptrStructure) GetMemberString() (_swig_ret string) { - return _swig_wrap_Structure_MemberString_get(arg1) -} - -var _wrap_Structure_MemberString2_set unsafe.Pointer - -func _swig_wrap_Structure_MemberString2_set(base SwigcptrStructure, _ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Structure_MemberString2_set, _swig_p) - return -} - -func (arg1 SwigcptrStructure) SetMemberString2(arg2 string) { - _swig_wrap_Structure_MemberString2_set(arg1, arg2) -} - -var _wrap_Structure_MemberString2_get unsafe.Pointer - -func _swig_wrap_Structure_MemberString2_get(base SwigcptrStructure) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Structure_MemberString2_get, _swig_p) - return -} - -func (arg1 SwigcptrStructure) GetMemberString2() (_swig_ret string) { - return _swig_wrap_Structure_MemberString2_get(arg1) -} - -var _wrap_Structure_StaticMemberString_set unsafe.Pointer - -func _swig_wrap_Structure_StaticMemberString_set(base string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Structure_StaticMemberString_set, _swig_p) - return -} - -func SetStructureStaticMemberString(arg1 string) { - _swig_wrap_Structure_StaticMemberString_set(arg1) -} - -var _wrap_Structure_StaticMemberString_get unsafe.Pointer - -func GetStructureStaticMemberString() (_swig_ret string) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_Structure_StaticMemberString_get, _swig_p) - return -} -var _wrap_Structure_StaticMemberString2_set unsafe.Pointer - -func _swig_wrap_Structure_StaticMemberString2_set(base string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Structure_StaticMemberString2_set, _swig_p) - return -} - -func SetStructureStaticMemberString2(arg1 string) { - _swig_wrap_Structure_StaticMemberString2_set(arg1) -} - -var _wrap_Structure_StaticMemberString2_get unsafe.Pointer - -func GetStructureStaticMemberString2() (_swig_ret string) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_Structure_StaticMemberString2_get, _swig_p) - return -} -var _wrap_Structure_ConstMemberString_get unsafe.Pointer - -func _swig_wrap_Structure_ConstMemberString_get(base SwigcptrStructure) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Structure_ConstMemberString_get, _swig_p) - return -} - -func (arg1 SwigcptrStructure) GetConstMemberString() (_swig_ret string) { - return _swig_wrap_Structure_ConstMemberString_get(arg1) -} - -var _wrap_Structure_ConstStaticMemberString_get unsafe.Pointer - -func GetStructureConstStaticMemberString() (_swig_ret string) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_Structure_ConstStaticMemberString_get, _swig_p) - return -} -var _wrap_new_Structure unsafe.Pointer - -func _swig_wrap_new_Structure() (base SwigcptrStructure) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Structure, _swig_p) - return -} - -func NewStructure() (_swig_ret Structure) { - return _swig_wrap_new_Structure() -} - -var _wrap_delete_Structure unsafe.Pointer - -func _swig_wrap_delete_Structure(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Structure, _swig_p) - return -} - -func DeleteStructure(arg1 Structure) { - _swig_wrap_delete_Structure(arg1.Swigcptr()) -} - -type Structure interface { - Swigcptr() uintptr - SwigIsStructure() - SetMemberString(arg2 string) - GetMemberString() (_swig_ret string) - SetMemberString2(arg2 string) - GetMemberString2() (_swig_ret string) - GetConstMemberString() (_swig_ret string) -} - -type SwigcptrFoo uintptr - -func (p SwigcptrFoo) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrFoo) SwigIsFoo() { -} - -var _wrap_Foo_test__SWIG_0 unsafe.Pointer - -func _swig_wrap_Foo_test__SWIG_0(base SwigcptrFoo, _ uint64) (_ uint64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_test__SWIG_0, _swig_p) - return -} - -func (arg1 SwigcptrFoo) Test__SWIG_0(arg2 uint64) (_swig_ret uint64) { - return _swig_wrap_Foo_test__SWIG_0(arg1, arg2) -} - -var _wrap_Foo_test__SWIG_1 unsafe.Pointer - -func _swig_wrap_Foo_test__SWIG_1(base SwigcptrFoo, _ string) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_test__SWIG_1, _swig_p) - return -} - -func (arg1 SwigcptrFoo) Test__SWIG_1(arg2 string) (_swig_ret string) { - return _swig_wrap_Foo_test__SWIG_1(arg1, arg2) -} - -func (p SwigcptrFoo) Test(a ...interface{}) interface{} { - argc := len(a) - if argc == 1 { - if _, ok := a[0].(string); !ok { - goto check_1 - } - return p.Test__SWIG_1(a[0].(string)) - } -check_1: - if argc == 1 { - return p.Test__SWIG_0(a[0].(uint64)) - } - panic("No match for overloaded function call") -} - -var _wrap_Foo_testl unsafe.Pointer - -func _swig_wrap_Foo_testl(base SwigcptrFoo, _ uint64) (_ uint64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_testl, _swig_p) - return -} - -func (arg1 SwigcptrFoo) Testl(arg2 uint64) (_swig_ret uint64) { - return _swig_wrap_Foo_testl(arg1, arg2) -} - -var _wrap_new_Foo unsafe.Pointer - -func _swig_wrap_new_Foo() (base SwigcptrFoo) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Foo, _swig_p) - return -} - -func NewFoo() (_swig_ret Foo) { - return _swig_wrap_new_Foo() -} - -var _wrap_delete_Foo unsafe.Pointer - -func _swig_wrap_delete_Foo(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Foo, _swig_p) - return -} - -func DeleteFoo(arg1 Foo) { - _swig_wrap_delete_Foo(arg1.Swigcptr()) -} - -type Foo interface { - Swigcptr() uintptr - SwigIsFoo() - Test(a ...interface{}) interface{} - Testl(arg2 uint64) (_swig_ret uint64) -} - -var _wrap_stdstring_empty unsafe.Pointer - -func Stdstring_empty() (_swig_ret string) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_stdstring_empty, _swig_p) - return -} -var _wrap_c_empty unsafe.Pointer - -func C_empty() (_swig_ret string) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_c_empty, _swig_p) - return -} -var _wrap_c_null unsafe.Pointer - -func C_null() (_swig_ret string) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_c_null, _swig_p) - return -} -var _wrap_get_null unsafe.Pointer - -func Get_null(arg1 string) (_swig_ret string) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_get_null, _swig_p) - return -} - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/li_std_vector.go b/Examples/test-suite/go/li_std_vector.go deleted file mode 100644 index 736af7f2d..000000000 --- a/Examples/test-suite/go/li_std_vector.go +++ /dev/null @@ -1,3412 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../li_std_vector.i - -package li_std_vector - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrIntVector uintptr - -func (p SwigcptrIntVector) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrIntVector) SwigIsIntVector() { -} - -var _wrap_new_IntVector__SWIG_0 unsafe.Pointer - -func _swig_wrap_new_IntVector__SWIG_0() (base SwigcptrIntVector) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_IntVector__SWIG_0, _swig_p) - return -} - -func NewIntVector__SWIG_0() (_swig_ret IntVector) { - return _swig_wrap_new_IntVector__SWIG_0() -} - -var _wrap_new_IntVector__SWIG_1 unsafe.Pointer - -func _swig_wrap_new_IntVector__SWIG_1(base int64) (_ SwigcptrIntVector) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_IntVector__SWIG_1, _swig_p) - return -} - -func NewIntVector__SWIG_1(arg1 int64) (_swig_ret IntVector) { - return _swig_wrap_new_IntVector__SWIG_1(arg1) -} - -func NewIntVector(a ...interface{}) IntVector { - argc := len(a) - if argc == 0 { - return NewIntVector__SWIG_0() - } - if argc == 1 { - return NewIntVector__SWIG_1(a[0].(int64)) - } - panic("No match for overloaded function call") -} - -var _wrap_IntVector_size unsafe.Pointer - -func _swig_wrap_IntVector_size(base SwigcptrIntVector) (_ int64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_IntVector_size, _swig_p) - return -} - -func (arg1 SwigcptrIntVector) Size() (_swig_ret int64) { - return _swig_wrap_IntVector_size(arg1) -} - -var _wrap_IntVector_capacity unsafe.Pointer - -func _swig_wrap_IntVector_capacity(base SwigcptrIntVector) (_ int64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_IntVector_capacity, _swig_p) - return -} - -func (arg1 SwigcptrIntVector) Capacity() (_swig_ret int64) { - return _swig_wrap_IntVector_capacity(arg1) -} - -var _wrap_IntVector_reserve unsafe.Pointer - -func _swig_wrap_IntVector_reserve(base SwigcptrIntVector, _ int64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_IntVector_reserve, _swig_p) - return -} - -func (arg1 SwigcptrIntVector) Reserve(arg2 int64) { - _swig_wrap_IntVector_reserve(arg1, arg2) -} - -var _wrap_IntVector_isEmpty unsafe.Pointer - -func _swig_wrap_IntVector_isEmpty(base SwigcptrIntVector) (_ bool) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_IntVector_isEmpty, _swig_p) - return -} - -func (arg1 SwigcptrIntVector) IsEmpty() (_swig_ret bool) { - return _swig_wrap_IntVector_isEmpty(arg1) -} - -var _wrap_IntVector_clear unsafe.Pointer - -func _swig_wrap_IntVector_clear(base SwigcptrIntVector) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_IntVector_clear, _swig_p) - return -} - -func (arg1 SwigcptrIntVector) Clear() { - _swig_wrap_IntVector_clear(arg1) -} - -var _wrap_IntVector_add unsafe.Pointer - -func _swig_wrap_IntVector_add(base SwigcptrIntVector, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_IntVector_add, _swig_p) - return -} - -func (arg1 SwigcptrIntVector) Add(arg2 int) { - _swig_wrap_IntVector_add(arg1, arg2) -} - -var _wrap_IntVector_get unsafe.Pointer - -func _swig_wrap_IntVector_get(base SwigcptrIntVector, _ int) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_IntVector_get, _swig_p) - return -} - -func (arg1 SwigcptrIntVector) Get(arg2 int) (_swig_ret int) { - return _swig_wrap_IntVector_get(arg1, arg2) -} - -var _wrap_IntVector_set unsafe.Pointer - -func _swig_wrap_IntVector_set(base SwigcptrIntVector, _ int, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_IntVector_set, _swig_p) - return -} - -func (arg1 SwigcptrIntVector) Set(arg2 int, arg3 int) { - _swig_wrap_IntVector_set(arg1, arg2, arg3) -} - -var _wrap_delete_IntVector unsafe.Pointer - -func _swig_wrap_delete_IntVector(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_IntVector, _swig_p) - return -} - -func DeleteIntVector(arg1 IntVector) { - _swig_wrap_delete_IntVector(arg1.Swigcptr()) -} - -type IntVector interface { - Swigcptr() uintptr - SwigIsIntVector() - Size() (_swig_ret int64) - Capacity() (_swig_ret int64) - Reserve(arg2 int64) - IsEmpty() (_swig_ret bool) - Clear() - Add(arg2 int) - Get(arg2 int) (_swig_ret int) - Set(arg2 int, arg3 int) -} - -type SwigcptrBoolVector uintptr - -func (p SwigcptrBoolVector) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrBoolVector) SwigIsBoolVector() { -} - -var _wrap_new_BoolVector__SWIG_0 unsafe.Pointer - -func _swig_wrap_new_BoolVector__SWIG_0() (base SwigcptrBoolVector) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_BoolVector__SWIG_0, _swig_p) - return -} - -func NewBoolVector__SWIG_0() (_swig_ret BoolVector) { - return _swig_wrap_new_BoolVector__SWIG_0() -} - -var _wrap_new_BoolVector__SWIG_1 unsafe.Pointer - -func _swig_wrap_new_BoolVector__SWIG_1(base int64) (_ SwigcptrBoolVector) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_BoolVector__SWIG_1, _swig_p) - return -} - -func NewBoolVector__SWIG_1(arg1 int64) (_swig_ret BoolVector) { - return _swig_wrap_new_BoolVector__SWIG_1(arg1) -} - -func NewBoolVector(a ...interface{}) BoolVector { - argc := len(a) - if argc == 0 { - return NewBoolVector__SWIG_0() - } - if argc == 1 { - return NewBoolVector__SWIG_1(a[0].(int64)) - } - panic("No match for overloaded function call") -} - -var _wrap_BoolVector_size unsafe.Pointer - -func _swig_wrap_BoolVector_size(base SwigcptrBoolVector) (_ int64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_BoolVector_size, _swig_p) - return -} - -func (arg1 SwigcptrBoolVector) Size() (_swig_ret int64) { - return _swig_wrap_BoolVector_size(arg1) -} - -var _wrap_BoolVector_capacity unsafe.Pointer - -func _swig_wrap_BoolVector_capacity(base SwigcptrBoolVector) (_ int64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_BoolVector_capacity, _swig_p) - return -} - -func (arg1 SwigcptrBoolVector) Capacity() (_swig_ret int64) { - return _swig_wrap_BoolVector_capacity(arg1) -} - -var _wrap_BoolVector_reserve unsafe.Pointer - -func _swig_wrap_BoolVector_reserve(base SwigcptrBoolVector, _ int64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_BoolVector_reserve, _swig_p) - return -} - -func (arg1 SwigcptrBoolVector) Reserve(arg2 int64) { - _swig_wrap_BoolVector_reserve(arg1, arg2) -} - -var _wrap_BoolVector_isEmpty unsafe.Pointer - -func _swig_wrap_BoolVector_isEmpty(base SwigcptrBoolVector) (_ bool) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_BoolVector_isEmpty, _swig_p) - return -} - -func (arg1 SwigcptrBoolVector) IsEmpty() (_swig_ret bool) { - return _swig_wrap_BoolVector_isEmpty(arg1) -} - -var _wrap_BoolVector_clear unsafe.Pointer - -func _swig_wrap_BoolVector_clear(base SwigcptrBoolVector) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_BoolVector_clear, _swig_p) - return -} - -func (arg1 SwigcptrBoolVector) Clear() { - _swig_wrap_BoolVector_clear(arg1) -} - -var _wrap_BoolVector_add unsafe.Pointer - -func _swig_wrap_BoolVector_add(base SwigcptrBoolVector, _ bool) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_BoolVector_add, _swig_p) - return -} - -func (arg1 SwigcptrBoolVector) Add(arg2 bool) { - _swig_wrap_BoolVector_add(arg1, arg2) -} - -var _wrap_BoolVector_get unsafe.Pointer - -func _swig_wrap_BoolVector_get(base SwigcptrBoolVector, _ int) (_ bool) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_BoolVector_get, _swig_p) - return -} - -func (arg1 SwigcptrBoolVector) Get(arg2 int) (_swig_ret bool) { - return _swig_wrap_BoolVector_get(arg1, arg2) -} - -var _wrap_BoolVector_set unsafe.Pointer - -func _swig_wrap_BoolVector_set(base SwigcptrBoolVector, _ int, _ bool) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_BoolVector_set, _swig_p) - return -} - -func (arg1 SwigcptrBoolVector) Set(arg2 int, arg3 bool) { - _swig_wrap_BoolVector_set(arg1, arg2, arg3) -} - -var _wrap_delete_BoolVector unsafe.Pointer - -func _swig_wrap_delete_BoolVector(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_BoolVector, _swig_p) - return -} - -func DeleteBoolVector(arg1 BoolVector) { - _swig_wrap_delete_BoolVector(arg1.Swigcptr()) -} - -type BoolVector interface { - Swigcptr() uintptr - SwigIsBoolVector() - Size() (_swig_ret int64) - Capacity() (_swig_ret int64) - Reserve(arg2 int64) - IsEmpty() (_swig_ret bool) - Clear() - Add(arg2 bool) - Get(arg2 int) (_swig_ret bool) - Set(arg2 int, arg3 bool) -} - -type SwigcptrCharVector uintptr - -func (p SwigcptrCharVector) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrCharVector) SwigIsCharVector() { -} - -var _wrap_new_CharVector__SWIG_0 unsafe.Pointer - -func _swig_wrap_new_CharVector__SWIG_0() (base SwigcptrCharVector) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_CharVector__SWIG_0, _swig_p) - return -} - -func NewCharVector__SWIG_0() (_swig_ret CharVector) { - return _swig_wrap_new_CharVector__SWIG_0() -} - -var _wrap_new_CharVector__SWIG_1 unsafe.Pointer - -func _swig_wrap_new_CharVector__SWIG_1(base int64) (_ SwigcptrCharVector) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_CharVector__SWIG_1, _swig_p) - return -} - -func NewCharVector__SWIG_1(arg1 int64) (_swig_ret CharVector) { - return _swig_wrap_new_CharVector__SWIG_1(arg1) -} - -func NewCharVector(a ...interface{}) CharVector { - argc := len(a) - if argc == 0 { - return NewCharVector__SWIG_0() - } - if argc == 1 { - return NewCharVector__SWIG_1(a[0].(int64)) - } - panic("No match for overloaded function call") -} - -var _wrap_CharVector_size unsafe.Pointer - -func _swig_wrap_CharVector_size(base SwigcptrCharVector) (_ int64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_CharVector_size, _swig_p) - return -} - -func (arg1 SwigcptrCharVector) Size() (_swig_ret int64) { - return _swig_wrap_CharVector_size(arg1) -} - -var _wrap_CharVector_capacity unsafe.Pointer - -func _swig_wrap_CharVector_capacity(base SwigcptrCharVector) (_ int64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_CharVector_capacity, _swig_p) - return -} - -func (arg1 SwigcptrCharVector) Capacity() (_swig_ret int64) { - return _swig_wrap_CharVector_capacity(arg1) -} - -var _wrap_CharVector_reserve unsafe.Pointer - -func _swig_wrap_CharVector_reserve(base SwigcptrCharVector, _ int64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_CharVector_reserve, _swig_p) - return -} - -func (arg1 SwigcptrCharVector) Reserve(arg2 int64) { - _swig_wrap_CharVector_reserve(arg1, arg2) -} - -var _wrap_CharVector_isEmpty unsafe.Pointer - -func _swig_wrap_CharVector_isEmpty(base SwigcptrCharVector) (_ bool) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_CharVector_isEmpty, _swig_p) - return -} - -func (arg1 SwigcptrCharVector) IsEmpty() (_swig_ret bool) { - return _swig_wrap_CharVector_isEmpty(arg1) -} - -var _wrap_CharVector_clear unsafe.Pointer - -func _swig_wrap_CharVector_clear(base SwigcptrCharVector) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_CharVector_clear, _swig_p) - return -} - -func (arg1 SwigcptrCharVector) Clear() { - _swig_wrap_CharVector_clear(arg1) -} - -var _wrap_CharVector_add unsafe.Pointer - -func _swig_wrap_CharVector_add(base SwigcptrCharVector, _ byte) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_CharVector_add, _swig_p) - return -} - -func (arg1 SwigcptrCharVector) Add(arg2 byte) { - _swig_wrap_CharVector_add(arg1, arg2) -} - -var _wrap_CharVector_get unsafe.Pointer - -func _swig_wrap_CharVector_get(base SwigcptrCharVector, _ int) (_ byte) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_CharVector_get, _swig_p) - return -} - -func (arg1 SwigcptrCharVector) Get(arg2 int) (_swig_ret byte) { - return _swig_wrap_CharVector_get(arg1, arg2) -} - -var _wrap_CharVector_set unsafe.Pointer - -func _swig_wrap_CharVector_set(base SwigcptrCharVector, _ int, _ byte) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_CharVector_set, _swig_p) - return -} - -func (arg1 SwigcptrCharVector) Set(arg2 int, arg3 byte) { - _swig_wrap_CharVector_set(arg1, arg2, arg3) -} - -var _wrap_delete_CharVector unsafe.Pointer - -func _swig_wrap_delete_CharVector(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_CharVector, _swig_p) - return -} - -func DeleteCharVector(arg1 CharVector) { - _swig_wrap_delete_CharVector(arg1.Swigcptr()) -} - -type CharVector interface { - Swigcptr() uintptr - SwigIsCharVector() - Size() (_swig_ret int64) - Capacity() (_swig_ret int64) - Reserve(arg2 int64) - IsEmpty() (_swig_ret bool) - Clear() - Add(arg2 byte) - Get(arg2 int) (_swig_ret byte) - Set(arg2 int, arg3 byte) -} - -type SwigcptrShortVector uintptr - -func (p SwigcptrShortVector) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrShortVector) SwigIsShortVector() { -} - -var _wrap_new_ShortVector__SWIG_0 unsafe.Pointer - -func _swig_wrap_new_ShortVector__SWIG_0() (base SwigcptrShortVector) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_ShortVector__SWIG_0, _swig_p) - return -} - -func NewShortVector__SWIG_0() (_swig_ret ShortVector) { - return _swig_wrap_new_ShortVector__SWIG_0() -} - -var _wrap_new_ShortVector__SWIG_1 unsafe.Pointer - -func _swig_wrap_new_ShortVector__SWIG_1(base int64) (_ SwigcptrShortVector) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_ShortVector__SWIG_1, _swig_p) - return -} - -func NewShortVector__SWIG_1(arg1 int64) (_swig_ret ShortVector) { - return _swig_wrap_new_ShortVector__SWIG_1(arg1) -} - -func NewShortVector(a ...interface{}) ShortVector { - argc := len(a) - if argc == 0 { - return NewShortVector__SWIG_0() - } - if argc == 1 { - return NewShortVector__SWIG_1(a[0].(int64)) - } - panic("No match for overloaded function call") -} - -var _wrap_ShortVector_size unsafe.Pointer - -func _swig_wrap_ShortVector_size(base SwigcptrShortVector) (_ int64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_ShortVector_size, _swig_p) - return -} - -func (arg1 SwigcptrShortVector) Size() (_swig_ret int64) { - return _swig_wrap_ShortVector_size(arg1) -} - -var _wrap_ShortVector_capacity unsafe.Pointer - -func _swig_wrap_ShortVector_capacity(base SwigcptrShortVector) (_ int64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_ShortVector_capacity, _swig_p) - return -} - -func (arg1 SwigcptrShortVector) Capacity() (_swig_ret int64) { - return _swig_wrap_ShortVector_capacity(arg1) -} - -var _wrap_ShortVector_reserve unsafe.Pointer - -func _swig_wrap_ShortVector_reserve(base SwigcptrShortVector, _ int64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_ShortVector_reserve, _swig_p) - return -} - -func (arg1 SwigcptrShortVector) Reserve(arg2 int64) { - _swig_wrap_ShortVector_reserve(arg1, arg2) -} - -var _wrap_ShortVector_isEmpty unsafe.Pointer - -func _swig_wrap_ShortVector_isEmpty(base SwigcptrShortVector) (_ bool) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_ShortVector_isEmpty, _swig_p) - return -} - -func (arg1 SwigcptrShortVector) IsEmpty() (_swig_ret bool) { - return _swig_wrap_ShortVector_isEmpty(arg1) -} - -var _wrap_ShortVector_clear unsafe.Pointer - -func _swig_wrap_ShortVector_clear(base SwigcptrShortVector) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_ShortVector_clear, _swig_p) - return -} - -func (arg1 SwigcptrShortVector) Clear() { - _swig_wrap_ShortVector_clear(arg1) -} - -var _wrap_ShortVector_add unsafe.Pointer - -func _swig_wrap_ShortVector_add(base SwigcptrShortVector, _ int16) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_ShortVector_add, _swig_p) - return -} - -func (arg1 SwigcptrShortVector) Add(arg2 int16) { - _swig_wrap_ShortVector_add(arg1, arg2) -} - -var _wrap_ShortVector_get unsafe.Pointer - -func _swig_wrap_ShortVector_get(base SwigcptrShortVector, _ int) (_ int16) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_ShortVector_get, _swig_p) - return -} - -func (arg1 SwigcptrShortVector) Get(arg2 int) (_swig_ret int16) { - return _swig_wrap_ShortVector_get(arg1, arg2) -} - -var _wrap_ShortVector_set unsafe.Pointer - -func _swig_wrap_ShortVector_set(base SwigcptrShortVector, _ int, _ int16) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_ShortVector_set, _swig_p) - return -} - -func (arg1 SwigcptrShortVector) Set(arg2 int, arg3 int16) { - _swig_wrap_ShortVector_set(arg1, arg2, arg3) -} - -var _wrap_delete_ShortVector unsafe.Pointer - -func _swig_wrap_delete_ShortVector(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_ShortVector, _swig_p) - return -} - -func DeleteShortVector(arg1 ShortVector) { - _swig_wrap_delete_ShortVector(arg1.Swigcptr()) -} - -type ShortVector interface { - Swigcptr() uintptr - SwigIsShortVector() - Size() (_swig_ret int64) - Capacity() (_swig_ret int64) - Reserve(arg2 int64) - IsEmpty() (_swig_ret bool) - Clear() - Add(arg2 int16) - Get(arg2 int) (_swig_ret int16) - Set(arg2 int, arg3 int16) -} - -type SwigcptrLongVector uintptr - -func (p SwigcptrLongVector) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrLongVector) SwigIsLongVector() { -} - -var _wrap_new_LongVector__SWIG_0 unsafe.Pointer - -func _swig_wrap_new_LongVector__SWIG_0() (base SwigcptrLongVector) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_LongVector__SWIG_0, _swig_p) - return -} - -func NewLongVector__SWIG_0() (_swig_ret LongVector) { - return _swig_wrap_new_LongVector__SWIG_0() -} - -var _wrap_new_LongVector__SWIG_1 unsafe.Pointer - -func _swig_wrap_new_LongVector__SWIG_1(base int64) (_ SwigcptrLongVector) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_LongVector__SWIG_1, _swig_p) - return -} - -func NewLongVector__SWIG_1(arg1 int64) (_swig_ret LongVector) { - return _swig_wrap_new_LongVector__SWIG_1(arg1) -} - -func NewLongVector(a ...interface{}) LongVector { - argc := len(a) - if argc == 0 { - return NewLongVector__SWIG_0() - } - if argc == 1 { - return NewLongVector__SWIG_1(a[0].(int64)) - } - panic("No match for overloaded function call") -} - -var _wrap_LongVector_size unsafe.Pointer - -func _swig_wrap_LongVector_size(base SwigcptrLongVector) (_ int64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_LongVector_size, _swig_p) - return -} - -func (arg1 SwigcptrLongVector) Size() (_swig_ret int64) { - return _swig_wrap_LongVector_size(arg1) -} - -var _wrap_LongVector_capacity unsafe.Pointer - -func _swig_wrap_LongVector_capacity(base SwigcptrLongVector) (_ int64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_LongVector_capacity, _swig_p) - return -} - -func (arg1 SwigcptrLongVector) Capacity() (_swig_ret int64) { - return _swig_wrap_LongVector_capacity(arg1) -} - -var _wrap_LongVector_reserve unsafe.Pointer - -func _swig_wrap_LongVector_reserve(base SwigcptrLongVector, _ int64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_LongVector_reserve, _swig_p) - return -} - -func (arg1 SwigcptrLongVector) Reserve(arg2 int64) { - _swig_wrap_LongVector_reserve(arg1, arg2) -} - -var _wrap_LongVector_isEmpty unsafe.Pointer - -func _swig_wrap_LongVector_isEmpty(base SwigcptrLongVector) (_ bool) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_LongVector_isEmpty, _swig_p) - return -} - -func (arg1 SwigcptrLongVector) IsEmpty() (_swig_ret bool) { - return _swig_wrap_LongVector_isEmpty(arg1) -} - -var _wrap_LongVector_clear unsafe.Pointer - -func _swig_wrap_LongVector_clear(base SwigcptrLongVector) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_LongVector_clear, _swig_p) - return -} - -func (arg1 SwigcptrLongVector) Clear() { - _swig_wrap_LongVector_clear(arg1) -} - -var _wrap_LongVector_add unsafe.Pointer - -func _swig_wrap_LongVector_add(base SwigcptrLongVector, _ int64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_LongVector_add, _swig_p) - return -} - -func (arg1 SwigcptrLongVector) Add(arg2 int64) { - _swig_wrap_LongVector_add(arg1, arg2) -} - -var _wrap_LongVector_get unsafe.Pointer - -func _swig_wrap_LongVector_get(base SwigcptrLongVector, _ int) (_ int64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_LongVector_get, _swig_p) - return -} - -func (arg1 SwigcptrLongVector) Get(arg2 int) (_swig_ret int64) { - return _swig_wrap_LongVector_get(arg1, arg2) -} - -var _wrap_LongVector_set unsafe.Pointer - -func _swig_wrap_LongVector_set(base SwigcptrLongVector, _ int, _ int64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_LongVector_set, _swig_p) - return -} - -func (arg1 SwigcptrLongVector) Set(arg2 int, arg3 int64) { - _swig_wrap_LongVector_set(arg1, arg2, arg3) -} - -var _wrap_delete_LongVector unsafe.Pointer - -func _swig_wrap_delete_LongVector(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_LongVector, _swig_p) - return -} - -func DeleteLongVector(arg1 LongVector) { - _swig_wrap_delete_LongVector(arg1.Swigcptr()) -} - -type LongVector interface { - Swigcptr() uintptr - SwigIsLongVector() - Size() (_swig_ret int64) - Capacity() (_swig_ret int64) - Reserve(arg2 int64) - IsEmpty() (_swig_ret bool) - Clear() - Add(arg2 int64) - Get(arg2 int) (_swig_ret int64) - Set(arg2 int, arg3 int64) -} - -type SwigcptrUCharVector uintptr - -func (p SwigcptrUCharVector) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrUCharVector) SwigIsUCharVector() { -} - -var _wrap_new_UCharVector__SWIG_0 unsafe.Pointer - -func _swig_wrap_new_UCharVector__SWIG_0() (base SwigcptrUCharVector) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_UCharVector__SWIG_0, _swig_p) - return -} - -func NewUCharVector__SWIG_0() (_swig_ret UCharVector) { - return _swig_wrap_new_UCharVector__SWIG_0() -} - -var _wrap_new_UCharVector__SWIG_1 unsafe.Pointer - -func _swig_wrap_new_UCharVector__SWIG_1(base int64) (_ SwigcptrUCharVector) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_UCharVector__SWIG_1, _swig_p) - return -} - -func NewUCharVector__SWIG_1(arg1 int64) (_swig_ret UCharVector) { - return _swig_wrap_new_UCharVector__SWIG_1(arg1) -} - -func NewUCharVector(a ...interface{}) UCharVector { - argc := len(a) - if argc == 0 { - return NewUCharVector__SWIG_0() - } - if argc == 1 { - return NewUCharVector__SWIG_1(a[0].(int64)) - } - panic("No match for overloaded function call") -} - -var _wrap_UCharVector_size unsafe.Pointer - -func _swig_wrap_UCharVector_size(base SwigcptrUCharVector) (_ int64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_UCharVector_size, _swig_p) - return -} - -func (arg1 SwigcptrUCharVector) Size() (_swig_ret int64) { - return _swig_wrap_UCharVector_size(arg1) -} - -var _wrap_UCharVector_capacity unsafe.Pointer - -func _swig_wrap_UCharVector_capacity(base SwigcptrUCharVector) (_ int64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_UCharVector_capacity, _swig_p) - return -} - -func (arg1 SwigcptrUCharVector) Capacity() (_swig_ret int64) { - return _swig_wrap_UCharVector_capacity(arg1) -} - -var _wrap_UCharVector_reserve unsafe.Pointer - -func _swig_wrap_UCharVector_reserve(base SwigcptrUCharVector, _ int64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_UCharVector_reserve, _swig_p) - return -} - -func (arg1 SwigcptrUCharVector) Reserve(arg2 int64) { - _swig_wrap_UCharVector_reserve(arg1, arg2) -} - -var _wrap_UCharVector_isEmpty unsafe.Pointer - -func _swig_wrap_UCharVector_isEmpty(base SwigcptrUCharVector) (_ bool) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_UCharVector_isEmpty, _swig_p) - return -} - -func (arg1 SwigcptrUCharVector) IsEmpty() (_swig_ret bool) { - return _swig_wrap_UCharVector_isEmpty(arg1) -} - -var _wrap_UCharVector_clear unsafe.Pointer - -func _swig_wrap_UCharVector_clear(base SwigcptrUCharVector) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_UCharVector_clear, _swig_p) - return -} - -func (arg1 SwigcptrUCharVector) Clear() { - _swig_wrap_UCharVector_clear(arg1) -} - -var _wrap_UCharVector_add unsafe.Pointer - -func _swig_wrap_UCharVector_add(base SwigcptrUCharVector, _ byte) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_UCharVector_add, _swig_p) - return -} - -func (arg1 SwigcptrUCharVector) Add(arg2 byte) { - _swig_wrap_UCharVector_add(arg1, arg2) -} - -var _wrap_UCharVector_get unsafe.Pointer - -func _swig_wrap_UCharVector_get(base SwigcptrUCharVector, _ int) (_ byte) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_UCharVector_get, _swig_p) - return -} - -func (arg1 SwigcptrUCharVector) Get(arg2 int) (_swig_ret byte) { - return _swig_wrap_UCharVector_get(arg1, arg2) -} - -var _wrap_UCharVector_set unsafe.Pointer - -func _swig_wrap_UCharVector_set(base SwigcptrUCharVector, _ int, _ byte) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_UCharVector_set, _swig_p) - return -} - -func (arg1 SwigcptrUCharVector) Set(arg2 int, arg3 byte) { - _swig_wrap_UCharVector_set(arg1, arg2, arg3) -} - -var _wrap_delete_UCharVector unsafe.Pointer - -func _swig_wrap_delete_UCharVector(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_UCharVector, _swig_p) - return -} - -func DeleteUCharVector(arg1 UCharVector) { - _swig_wrap_delete_UCharVector(arg1.Swigcptr()) -} - -type UCharVector interface { - Swigcptr() uintptr - SwigIsUCharVector() - Size() (_swig_ret int64) - Capacity() (_swig_ret int64) - Reserve(arg2 int64) - IsEmpty() (_swig_ret bool) - Clear() - Add(arg2 byte) - Get(arg2 int) (_swig_ret byte) - Set(arg2 int, arg3 byte) -} - -type SwigcptrUIntVector uintptr - -func (p SwigcptrUIntVector) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrUIntVector) SwigIsUIntVector() { -} - -var _wrap_new_UIntVector__SWIG_0 unsafe.Pointer - -func _swig_wrap_new_UIntVector__SWIG_0() (base SwigcptrUIntVector) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_UIntVector__SWIG_0, _swig_p) - return -} - -func NewUIntVector__SWIG_0() (_swig_ret UIntVector) { - return _swig_wrap_new_UIntVector__SWIG_0() -} - -var _wrap_new_UIntVector__SWIG_1 unsafe.Pointer - -func _swig_wrap_new_UIntVector__SWIG_1(base int64) (_ SwigcptrUIntVector) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_UIntVector__SWIG_1, _swig_p) - return -} - -func NewUIntVector__SWIG_1(arg1 int64) (_swig_ret UIntVector) { - return _swig_wrap_new_UIntVector__SWIG_1(arg1) -} - -func NewUIntVector(a ...interface{}) UIntVector { - argc := len(a) - if argc == 0 { - return NewUIntVector__SWIG_0() - } - if argc == 1 { - return NewUIntVector__SWIG_1(a[0].(int64)) - } - panic("No match for overloaded function call") -} - -var _wrap_UIntVector_size unsafe.Pointer - -func _swig_wrap_UIntVector_size(base SwigcptrUIntVector) (_ int64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_UIntVector_size, _swig_p) - return -} - -func (arg1 SwigcptrUIntVector) Size() (_swig_ret int64) { - return _swig_wrap_UIntVector_size(arg1) -} - -var _wrap_UIntVector_capacity unsafe.Pointer - -func _swig_wrap_UIntVector_capacity(base SwigcptrUIntVector) (_ int64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_UIntVector_capacity, _swig_p) - return -} - -func (arg1 SwigcptrUIntVector) Capacity() (_swig_ret int64) { - return _swig_wrap_UIntVector_capacity(arg1) -} - -var _wrap_UIntVector_reserve unsafe.Pointer - -func _swig_wrap_UIntVector_reserve(base SwigcptrUIntVector, _ int64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_UIntVector_reserve, _swig_p) - return -} - -func (arg1 SwigcptrUIntVector) Reserve(arg2 int64) { - _swig_wrap_UIntVector_reserve(arg1, arg2) -} - -var _wrap_UIntVector_isEmpty unsafe.Pointer - -func _swig_wrap_UIntVector_isEmpty(base SwigcptrUIntVector) (_ bool) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_UIntVector_isEmpty, _swig_p) - return -} - -func (arg1 SwigcptrUIntVector) IsEmpty() (_swig_ret bool) { - return _swig_wrap_UIntVector_isEmpty(arg1) -} - -var _wrap_UIntVector_clear unsafe.Pointer - -func _swig_wrap_UIntVector_clear(base SwigcptrUIntVector) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_UIntVector_clear, _swig_p) - return -} - -func (arg1 SwigcptrUIntVector) Clear() { - _swig_wrap_UIntVector_clear(arg1) -} - -var _wrap_UIntVector_add unsafe.Pointer - -func _swig_wrap_UIntVector_add(base SwigcptrUIntVector, _ uint) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_UIntVector_add, _swig_p) - return -} - -func (arg1 SwigcptrUIntVector) Add(arg2 uint) { - _swig_wrap_UIntVector_add(arg1, arg2) -} - -var _wrap_UIntVector_get unsafe.Pointer - -func _swig_wrap_UIntVector_get(base SwigcptrUIntVector, _ int) (_ uint) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_UIntVector_get, _swig_p) - return -} - -func (arg1 SwigcptrUIntVector) Get(arg2 int) (_swig_ret uint) { - return _swig_wrap_UIntVector_get(arg1, arg2) -} - -var _wrap_UIntVector_set unsafe.Pointer - -func _swig_wrap_UIntVector_set(base SwigcptrUIntVector, _ int, _ uint) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_UIntVector_set, _swig_p) - return -} - -func (arg1 SwigcptrUIntVector) Set(arg2 int, arg3 uint) { - _swig_wrap_UIntVector_set(arg1, arg2, arg3) -} - -var _wrap_delete_UIntVector unsafe.Pointer - -func _swig_wrap_delete_UIntVector(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_UIntVector, _swig_p) - return -} - -func DeleteUIntVector(arg1 UIntVector) { - _swig_wrap_delete_UIntVector(arg1.Swigcptr()) -} - -type UIntVector interface { - Swigcptr() uintptr - SwigIsUIntVector() - Size() (_swig_ret int64) - Capacity() (_swig_ret int64) - Reserve(arg2 int64) - IsEmpty() (_swig_ret bool) - Clear() - Add(arg2 uint) - Get(arg2 int) (_swig_ret uint) - Set(arg2 int, arg3 uint) -} - -type SwigcptrUShortVector uintptr - -func (p SwigcptrUShortVector) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrUShortVector) SwigIsUShortVector() { -} - -var _wrap_new_UShortVector__SWIG_0 unsafe.Pointer - -func _swig_wrap_new_UShortVector__SWIG_0() (base SwigcptrUShortVector) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_UShortVector__SWIG_0, _swig_p) - return -} - -func NewUShortVector__SWIG_0() (_swig_ret UShortVector) { - return _swig_wrap_new_UShortVector__SWIG_0() -} - -var _wrap_new_UShortVector__SWIG_1 unsafe.Pointer - -func _swig_wrap_new_UShortVector__SWIG_1(base int64) (_ SwigcptrUShortVector) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_UShortVector__SWIG_1, _swig_p) - return -} - -func NewUShortVector__SWIG_1(arg1 int64) (_swig_ret UShortVector) { - return _swig_wrap_new_UShortVector__SWIG_1(arg1) -} - -func NewUShortVector(a ...interface{}) UShortVector { - argc := len(a) - if argc == 0 { - return NewUShortVector__SWIG_0() - } - if argc == 1 { - return NewUShortVector__SWIG_1(a[0].(int64)) - } - panic("No match for overloaded function call") -} - -var _wrap_UShortVector_size unsafe.Pointer - -func _swig_wrap_UShortVector_size(base SwigcptrUShortVector) (_ int64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_UShortVector_size, _swig_p) - return -} - -func (arg1 SwigcptrUShortVector) Size() (_swig_ret int64) { - return _swig_wrap_UShortVector_size(arg1) -} - -var _wrap_UShortVector_capacity unsafe.Pointer - -func _swig_wrap_UShortVector_capacity(base SwigcptrUShortVector) (_ int64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_UShortVector_capacity, _swig_p) - return -} - -func (arg1 SwigcptrUShortVector) Capacity() (_swig_ret int64) { - return _swig_wrap_UShortVector_capacity(arg1) -} - -var _wrap_UShortVector_reserve unsafe.Pointer - -func _swig_wrap_UShortVector_reserve(base SwigcptrUShortVector, _ int64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_UShortVector_reserve, _swig_p) - return -} - -func (arg1 SwigcptrUShortVector) Reserve(arg2 int64) { - _swig_wrap_UShortVector_reserve(arg1, arg2) -} - -var _wrap_UShortVector_isEmpty unsafe.Pointer - -func _swig_wrap_UShortVector_isEmpty(base SwigcptrUShortVector) (_ bool) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_UShortVector_isEmpty, _swig_p) - return -} - -func (arg1 SwigcptrUShortVector) IsEmpty() (_swig_ret bool) { - return _swig_wrap_UShortVector_isEmpty(arg1) -} - -var _wrap_UShortVector_clear unsafe.Pointer - -func _swig_wrap_UShortVector_clear(base SwigcptrUShortVector) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_UShortVector_clear, _swig_p) - return -} - -func (arg1 SwigcptrUShortVector) Clear() { - _swig_wrap_UShortVector_clear(arg1) -} - -var _wrap_UShortVector_add unsafe.Pointer - -func _swig_wrap_UShortVector_add(base SwigcptrUShortVector, _ uint16) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_UShortVector_add, _swig_p) - return -} - -func (arg1 SwigcptrUShortVector) Add(arg2 uint16) { - _swig_wrap_UShortVector_add(arg1, arg2) -} - -var _wrap_UShortVector_get unsafe.Pointer - -func _swig_wrap_UShortVector_get(base SwigcptrUShortVector, _ int) (_ uint16) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_UShortVector_get, _swig_p) - return -} - -func (arg1 SwigcptrUShortVector) Get(arg2 int) (_swig_ret uint16) { - return _swig_wrap_UShortVector_get(arg1, arg2) -} - -var _wrap_UShortVector_set unsafe.Pointer - -func _swig_wrap_UShortVector_set(base SwigcptrUShortVector, _ int, _ uint16) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_UShortVector_set, _swig_p) - return -} - -func (arg1 SwigcptrUShortVector) Set(arg2 int, arg3 uint16) { - _swig_wrap_UShortVector_set(arg1, arg2, arg3) -} - -var _wrap_delete_UShortVector unsafe.Pointer - -func _swig_wrap_delete_UShortVector(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_UShortVector, _swig_p) - return -} - -func DeleteUShortVector(arg1 UShortVector) { - _swig_wrap_delete_UShortVector(arg1.Swigcptr()) -} - -type UShortVector interface { - Swigcptr() uintptr - SwigIsUShortVector() - Size() (_swig_ret int64) - Capacity() (_swig_ret int64) - Reserve(arg2 int64) - IsEmpty() (_swig_ret bool) - Clear() - Add(arg2 uint16) - Get(arg2 int) (_swig_ret uint16) - Set(arg2 int, arg3 uint16) -} - -type SwigcptrULongVector uintptr - -func (p SwigcptrULongVector) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrULongVector) SwigIsULongVector() { -} - -var _wrap_new_ULongVector__SWIG_0 unsafe.Pointer - -func _swig_wrap_new_ULongVector__SWIG_0() (base SwigcptrULongVector) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_ULongVector__SWIG_0, _swig_p) - return -} - -func NewULongVector__SWIG_0() (_swig_ret ULongVector) { - return _swig_wrap_new_ULongVector__SWIG_0() -} - -var _wrap_new_ULongVector__SWIG_1 unsafe.Pointer - -func _swig_wrap_new_ULongVector__SWIG_1(base int64) (_ SwigcptrULongVector) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_ULongVector__SWIG_1, _swig_p) - return -} - -func NewULongVector__SWIG_1(arg1 int64) (_swig_ret ULongVector) { - return _swig_wrap_new_ULongVector__SWIG_1(arg1) -} - -func NewULongVector(a ...interface{}) ULongVector { - argc := len(a) - if argc == 0 { - return NewULongVector__SWIG_0() - } - if argc == 1 { - return NewULongVector__SWIG_1(a[0].(int64)) - } - panic("No match for overloaded function call") -} - -var _wrap_ULongVector_size unsafe.Pointer - -func _swig_wrap_ULongVector_size(base SwigcptrULongVector) (_ int64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_ULongVector_size, _swig_p) - return -} - -func (arg1 SwigcptrULongVector) Size() (_swig_ret int64) { - return _swig_wrap_ULongVector_size(arg1) -} - -var _wrap_ULongVector_capacity unsafe.Pointer - -func _swig_wrap_ULongVector_capacity(base SwigcptrULongVector) (_ int64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_ULongVector_capacity, _swig_p) - return -} - -func (arg1 SwigcptrULongVector) Capacity() (_swig_ret int64) { - return _swig_wrap_ULongVector_capacity(arg1) -} - -var _wrap_ULongVector_reserve unsafe.Pointer - -func _swig_wrap_ULongVector_reserve(base SwigcptrULongVector, _ int64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_ULongVector_reserve, _swig_p) - return -} - -func (arg1 SwigcptrULongVector) Reserve(arg2 int64) { - _swig_wrap_ULongVector_reserve(arg1, arg2) -} - -var _wrap_ULongVector_isEmpty unsafe.Pointer - -func _swig_wrap_ULongVector_isEmpty(base SwigcptrULongVector) (_ bool) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_ULongVector_isEmpty, _swig_p) - return -} - -func (arg1 SwigcptrULongVector) IsEmpty() (_swig_ret bool) { - return _swig_wrap_ULongVector_isEmpty(arg1) -} - -var _wrap_ULongVector_clear unsafe.Pointer - -func _swig_wrap_ULongVector_clear(base SwigcptrULongVector) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_ULongVector_clear, _swig_p) - return -} - -func (arg1 SwigcptrULongVector) Clear() { - _swig_wrap_ULongVector_clear(arg1) -} - -var _wrap_ULongVector_add unsafe.Pointer - -func _swig_wrap_ULongVector_add(base SwigcptrULongVector, _ uint64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_ULongVector_add, _swig_p) - return -} - -func (arg1 SwigcptrULongVector) Add(arg2 uint64) { - _swig_wrap_ULongVector_add(arg1, arg2) -} - -var _wrap_ULongVector_get unsafe.Pointer - -func _swig_wrap_ULongVector_get(base SwigcptrULongVector, _ int) (_ uint64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_ULongVector_get, _swig_p) - return -} - -func (arg1 SwigcptrULongVector) Get(arg2 int) (_swig_ret uint64) { - return _swig_wrap_ULongVector_get(arg1, arg2) -} - -var _wrap_ULongVector_set unsafe.Pointer - -func _swig_wrap_ULongVector_set(base SwigcptrULongVector, _ int, _ uint64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_ULongVector_set, _swig_p) - return -} - -func (arg1 SwigcptrULongVector) Set(arg2 int, arg3 uint64) { - _swig_wrap_ULongVector_set(arg1, arg2, arg3) -} - -var _wrap_delete_ULongVector unsafe.Pointer - -func _swig_wrap_delete_ULongVector(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_ULongVector, _swig_p) - return -} - -func DeleteULongVector(arg1 ULongVector) { - _swig_wrap_delete_ULongVector(arg1.Swigcptr()) -} - -type ULongVector interface { - Swigcptr() uintptr - SwigIsULongVector() - Size() (_swig_ret int64) - Capacity() (_swig_ret int64) - Reserve(arg2 int64) - IsEmpty() (_swig_ret bool) - Clear() - Add(arg2 uint64) - Get(arg2 int) (_swig_ret uint64) - Set(arg2 int, arg3 uint64) -} - -type SwigcptrDoubleVector uintptr - -func (p SwigcptrDoubleVector) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrDoubleVector) SwigIsDoubleVector() { -} - -var _wrap_new_DoubleVector__SWIG_0 unsafe.Pointer - -func _swig_wrap_new_DoubleVector__SWIG_0() (base SwigcptrDoubleVector) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_DoubleVector__SWIG_0, _swig_p) - return -} - -func NewDoubleVector__SWIG_0() (_swig_ret DoubleVector) { - return _swig_wrap_new_DoubleVector__SWIG_0() -} - -var _wrap_new_DoubleVector__SWIG_1 unsafe.Pointer - -func _swig_wrap_new_DoubleVector__SWIG_1(base int64) (_ SwigcptrDoubleVector) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_DoubleVector__SWIG_1, _swig_p) - return -} - -func NewDoubleVector__SWIG_1(arg1 int64) (_swig_ret DoubleVector) { - return _swig_wrap_new_DoubleVector__SWIG_1(arg1) -} - -func NewDoubleVector(a ...interface{}) DoubleVector { - argc := len(a) - if argc == 0 { - return NewDoubleVector__SWIG_0() - } - if argc == 1 { - return NewDoubleVector__SWIG_1(a[0].(int64)) - } - panic("No match for overloaded function call") -} - -var _wrap_DoubleVector_size unsafe.Pointer - -func _swig_wrap_DoubleVector_size(base SwigcptrDoubleVector) (_ int64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_DoubleVector_size, _swig_p) - return -} - -func (arg1 SwigcptrDoubleVector) Size() (_swig_ret int64) { - return _swig_wrap_DoubleVector_size(arg1) -} - -var _wrap_DoubleVector_capacity unsafe.Pointer - -func _swig_wrap_DoubleVector_capacity(base SwigcptrDoubleVector) (_ int64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_DoubleVector_capacity, _swig_p) - return -} - -func (arg1 SwigcptrDoubleVector) Capacity() (_swig_ret int64) { - return _swig_wrap_DoubleVector_capacity(arg1) -} - -var _wrap_DoubleVector_reserve unsafe.Pointer - -func _swig_wrap_DoubleVector_reserve(base SwigcptrDoubleVector, _ int64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_DoubleVector_reserve, _swig_p) - return -} - -func (arg1 SwigcptrDoubleVector) Reserve(arg2 int64) { - _swig_wrap_DoubleVector_reserve(arg1, arg2) -} - -var _wrap_DoubleVector_isEmpty unsafe.Pointer - -func _swig_wrap_DoubleVector_isEmpty(base SwigcptrDoubleVector) (_ bool) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_DoubleVector_isEmpty, _swig_p) - return -} - -func (arg1 SwigcptrDoubleVector) IsEmpty() (_swig_ret bool) { - return _swig_wrap_DoubleVector_isEmpty(arg1) -} - -var _wrap_DoubleVector_clear unsafe.Pointer - -func _swig_wrap_DoubleVector_clear(base SwigcptrDoubleVector) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_DoubleVector_clear, _swig_p) - return -} - -func (arg1 SwigcptrDoubleVector) Clear() { - _swig_wrap_DoubleVector_clear(arg1) -} - -var _wrap_DoubleVector_add unsafe.Pointer - -func _swig_wrap_DoubleVector_add(base SwigcptrDoubleVector, _ float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_DoubleVector_add, _swig_p) - return -} - -func (arg1 SwigcptrDoubleVector) Add(arg2 float64) { - _swig_wrap_DoubleVector_add(arg1, arg2) -} - -var _wrap_DoubleVector_get unsafe.Pointer - -func _swig_wrap_DoubleVector_get(base SwigcptrDoubleVector, _ int) (_ float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_DoubleVector_get, _swig_p) - return -} - -func (arg1 SwigcptrDoubleVector) Get(arg2 int) (_swig_ret float64) { - return _swig_wrap_DoubleVector_get(arg1, arg2) -} - -var _wrap_DoubleVector_set unsafe.Pointer - -func _swig_wrap_DoubleVector_set(base SwigcptrDoubleVector, _ int, _ float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_DoubleVector_set, _swig_p) - return -} - -func (arg1 SwigcptrDoubleVector) Set(arg2 int, arg3 float64) { - _swig_wrap_DoubleVector_set(arg1, arg2, arg3) -} - -var _wrap_delete_DoubleVector unsafe.Pointer - -func _swig_wrap_delete_DoubleVector(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_DoubleVector, _swig_p) - return -} - -func DeleteDoubleVector(arg1 DoubleVector) { - _swig_wrap_delete_DoubleVector(arg1.Swigcptr()) -} - -type DoubleVector interface { - Swigcptr() uintptr - SwigIsDoubleVector() - Size() (_swig_ret int64) - Capacity() (_swig_ret int64) - Reserve(arg2 int64) - IsEmpty() (_swig_ret bool) - Clear() - Add(arg2 float64) - Get(arg2 int) (_swig_ret float64) - Set(arg2 int, arg3 float64) -} - -type SwigcptrStringVector uintptr - -func (p SwigcptrStringVector) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrStringVector) SwigIsStringVector() { -} - -var _wrap_new_StringVector__SWIG_0 unsafe.Pointer - -func _swig_wrap_new_StringVector__SWIG_0() (base SwigcptrStringVector) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_StringVector__SWIG_0, _swig_p) - return -} - -func NewStringVector__SWIG_0() (_swig_ret StringVector) { - return _swig_wrap_new_StringVector__SWIG_0() -} - -var _wrap_new_StringVector__SWIG_1 unsafe.Pointer - -func _swig_wrap_new_StringVector__SWIG_1(base int64) (_ SwigcptrStringVector) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_StringVector__SWIG_1, _swig_p) - return -} - -func NewStringVector__SWIG_1(arg1 int64) (_swig_ret StringVector) { - return _swig_wrap_new_StringVector__SWIG_1(arg1) -} - -func NewStringVector(a ...interface{}) StringVector { - argc := len(a) - if argc == 0 { - return NewStringVector__SWIG_0() - } - if argc == 1 { - return NewStringVector__SWIG_1(a[0].(int64)) - } - panic("No match for overloaded function call") -} - -var _wrap_StringVector_size unsafe.Pointer - -func _swig_wrap_StringVector_size(base SwigcptrStringVector) (_ int64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_StringVector_size, _swig_p) - return -} - -func (arg1 SwigcptrStringVector) Size() (_swig_ret int64) { - return _swig_wrap_StringVector_size(arg1) -} - -var _wrap_StringVector_capacity unsafe.Pointer - -func _swig_wrap_StringVector_capacity(base SwigcptrStringVector) (_ int64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_StringVector_capacity, _swig_p) - return -} - -func (arg1 SwigcptrStringVector) Capacity() (_swig_ret int64) { - return _swig_wrap_StringVector_capacity(arg1) -} - -var _wrap_StringVector_reserve unsafe.Pointer - -func _swig_wrap_StringVector_reserve(base SwigcptrStringVector, _ int64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_StringVector_reserve, _swig_p) - return -} - -func (arg1 SwigcptrStringVector) Reserve(arg2 int64) { - _swig_wrap_StringVector_reserve(arg1, arg2) -} - -var _wrap_StringVector_isEmpty unsafe.Pointer - -func _swig_wrap_StringVector_isEmpty(base SwigcptrStringVector) (_ bool) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_StringVector_isEmpty, _swig_p) - return -} - -func (arg1 SwigcptrStringVector) IsEmpty() (_swig_ret bool) { - return _swig_wrap_StringVector_isEmpty(arg1) -} - -var _wrap_StringVector_clear unsafe.Pointer - -func _swig_wrap_StringVector_clear(base SwigcptrStringVector) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_StringVector_clear, _swig_p) - return -} - -func (arg1 SwigcptrStringVector) Clear() { - _swig_wrap_StringVector_clear(arg1) -} - -var _wrap_StringVector_add unsafe.Pointer - -func _swig_wrap_StringVector_add(base SwigcptrStringVector, _ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_StringVector_add, _swig_p) - return -} - -func (arg1 SwigcptrStringVector) Add(arg2 string) { - _swig_wrap_StringVector_add(arg1, arg2) -} - -var _wrap_StringVector_get unsafe.Pointer - -func _swig_wrap_StringVector_get(base SwigcptrStringVector, _ int) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_StringVector_get, _swig_p) - return -} - -func (arg1 SwigcptrStringVector) Get(arg2 int) (_swig_ret string) { - return _swig_wrap_StringVector_get(arg1, arg2) -} - -var _wrap_StringVector_set unsafe.Pointer - -func _swig_wrap_StringVector_set(base SwigcptrStringVector, _ int, _ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_StringVector_set, _swig_p) - return -} - -func (arg1 SwigcptrStringVector) Set(arg2 int, arg3 string) { - _swig_wrap_StringVector_set(arg1, arg2, arg3) -} - -var _wrap_delete_StringVector unsafe.Pointer - -func _swig_wrap_delete_StringVector(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_StringVector, _swig_p) - return -} - -func DeleteStringVector(arg1 StringVector) { - _swig_wrap_delete_StringVector(arg1.Swigcptr()) -} - -type StringVector interface { - Swigcptr() uintptr - SwigIsStringVector() - Size() (_swig_ret int64) - Capacity() (_swig_ret int64) - Reserve(arg2 int64) - IsEmpty() (_swig_ret bool) - Clear() - Add(arg2 string) - Get(arg2 int) (_swig_ret string) - Set(arg2 int, arg3 string) -} - -var _wrap_typedef_test unsafe.Pointer - -func Typedef_test(arg1 int64) (_swig_ret int64) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_typedef_test, _swig_p) - return -} -type SwigcptrRealVector uintptr - -func (p SwigcptrRealVector) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrRealVector) SwigIsRealVector() { -} - -var _wrap_new_RealVector__SWIG_0 unsafe.Pointer - -func _swig_wrap_new_RealVector__SWIG_0() (base SwigcptrRealVector) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_RealVector__SWIG_0, _swig_p) - return -} - -func NewRealVector__SWIG_0() (_swig_ret RealVector) { - return _swig_wrap_new_RealVector__SWIG_0() -} - -var _wrap_new_RealVector__SWIG_1 unsafe.Pointer - -func _swig_wrap_new_RealVector__SWIG_1(base int64) (_ SwigcptrRealVector) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_RealVector__SWIG_1, _swig_p) - return -} - -func NewRealVector__SWIG_1(arg1 int64) (_swig_ret RealVector) { - return _swig_wrap_new_RealVector__SWIG_1(arg1) -} - -func NewRealVector(a ...interface{}) RealVector { - argc := len(a) - if argc == 0 { - return NewRealVector__SWIG_0() - } - if argc == 1 { - return NewRealVector__SWIG_1(a[0].(int64)) - } - panic("No match for overloaded function call") -} - -var _wrap_RealVector_size unsafe.Pointer - -func _swig_wrap_RealVector_size(base SwigcptrRealVector) (_ int64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_RealVector_size, _swig_p) - return -} - -func (arg1 SwigcptrRealVector) Size() (_swig_ret int64) { - return _swig_wrap_RealVector_size(arg1) -} - -var _wrap_RealVector_capacity unsafe.Pointer - -func _swig_wrap_RealVector_capacity(base SwigcptrRealVector) (_ int64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_RealVector_capacity, _swig_p) - return -} - -func (arg1 SwigcptrRealVector) Capacity() (_swig_ret int64) { - return _swig_wrap_RealVector_capacity(arg1) -} - -var _wrap_RealVector_reserve unsafe.Pointer - -func _swig_wrap_RealVector_reserve(base SwigcptrRealVector, _ int64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_RealVector_reserve, _swig_p) - return -} - -func (arg1 SwigcptrRealVector) Reserve(arg2 int64) { - _swig_wrap_RealVector_reserve(arg1, arg2) -} - -var _wrap_RealVector_isEmpty unsafe.Pointer - -func _swig_wrap_RealVector_isEmpty(base SwigcptrRealVector) (_ bool) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_RealVector_isEmpty, _swig_p) - return -} - -func (arg1 SwigcptrRealVector) IsEmpty() (_swig_ret bool) { - return _swig_wrap_RealVector_isEmpty(arg1) -} - -var _wrap_RealVector_clear unsafe.Pointer - -func _swig_wrap_RealVector_clear(base SwigcptrRealVector) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_RealVector_clear, _swig_p) - return -} - -func (arg1 SwigcptrRealVector) Clear() { - _swig_wrap_RealVector_clear(arg1) -} - -var _wrap_RealVector_add unsafe.Pointer - -func _swig_wrap_RealVector_add(base SwigcptrRealVector, _ float32) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_RealVector_add, _swig_p) - return -} - -func (arg1 SwigcptrRealVector) Add(arg2 float32) { - _swig_wrap_RealVector_add(arg1, arg2) -} - -var _wrap_RealVector_get unsafe.Pointer - -func _swig_wrap_RealVector_get(base SwigcptrRealVector, _ int) (_ float32) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_RealVector_get, _swig_p) - return -} - -func (arg1 SwigcptrRealVector) Get(arg2 int) (_swig_ret float32) { - return _swig_wrap_RealVector_get(arg1, arg2) -} - -var _wrap_RealVector_set unsafe.Pointer - -func _swig_wrap_RealVector_set(base SwigcptrRealVector, _ int, _ float32) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_RealVector_set, _swig_p) - return -} - -func (arg1 SwigcptrRealVector) Set(arg2 int, arg3 float32) { - _swig_wrap_RealVector_set(arg1, arg2, arg3) -} - -var _wrap_delete_RealVector unsafe.Pointer - -func _swig_wrap_delete_RealVector(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_RealVector, _swig_p) - return -} - -func DeleteRealVector(arg1 RealVector) { - _swig_wrap_delete_RealVector(arg1.Swigcptr()) -} - -type RealVector interface { - Swigcptr() uintptr - SwigIsRealVector() - Size() (_swig_ret int64) - Capacity() (_swig_ret int64) - Reserve(arg2 int64) - IsEmpty() (_swig_ret bool) - Clear() - Add(arg2 float32) - Get(arg2 int) (_swig_ret float32) - Set(arg2 int, arg3 float32) -} - -var _wrap_average unsafe.Pointer - -func _swig_wrap_average(base uintptr) (_ float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_average, _swig_p) - return -} - -func Average(arg1 IntVector) (_swig_ret float64) { - return _swig_wrap_average(arg1.Swigcptr()) -} - -var _wrap_half unsafe.Pointer - -func _swig_wrap_half(base uintptr) (_ SwigcptrRealVector) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_half, _swig_p) - return -} - -func Half(arg1 RealVector) (_swig_ret RealVector) { - return _swig_wrap_half(arg1.Swigcptr()) -} - -var _wrap_halve_in_place unsafe.Pointer - -func _swig_wrap_halve_in_place(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_halve_in_place, _swig_p) - return -} - -func Halve_in_place(arg1 DoubleVector) { - _swig_wrap_halve_in_place(arg1.Swigcptr()) -} - -type SwigcptrStruct uintptr - -func (p SwigcptrStruct) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrStruct) SwigIsStruct() { -} - -var _wrap_Struct_num_set unsafe.Pointer - -func _swig_wrap_Struct_num_set(base SwigcptrStruct, _ float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Struct_num_set, _swig_p) - return -} - -func (arg1 SwigcptrStruct) SetNum(arg2 float64) { - _swig_wrap_Struct_num_set(arg1, arg2) -} - -var _wrap_Struct_num_get unsafe.Pointer - -func _swig_wrap_Struct_num_get(base SwigcptrStruct) (_ float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Struct_num_get, _swig_p) - return -} - -func (arg1 SwigcptrStruct) GetNum() (_swig_ret float64) { - return _swig_wrap_Struct_num_get(arg1) -} - -var _wrap_new_Struct__SWIG_0 unsafe.Pointer - -func _swig_wrap_new_Struct__SWIG_0() (base SwigcptrStruct) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Struct__SWIG_0, _swig_p) - return -} - -func NewStruct__SWIG_0() (_swig_ret Struct) { - return _swig_wrap_new_Struct__SWIG_0() -} - -var _wrap_new_Struct__SWIG_1 unsafe.Pointer - -func _swig_wrap_new_Struct__SWIG_1(base float64) (_ SwigcptrStruct) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Struct__SWIG_1, _swig_p) - return -} - -func NewStruct__SWIG_1(arg1 float64) (_swig_ret Struct) { - return _swig_wrap_new_Struct__SWIG_1(arg1) -} - -func NewStruct(a ...interface{}) Struct { - argc := len(a) - if argc == 0 { - return NewStruct__SWIG_0() - } - if argc == 1 { - return NewStruct__SWIG_1(a[0].(float64)) - } - panic("No match for overloaded function call") -} - -var _wrap_delete_Struct unsafe.Pointer - -func _swig_wrap_delete_Struct(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Struct, _swig_p) - return -} - -func DeleteStruct(arg1 Struct) { - _swig_wrap_delete_Struct(arg1.Swigcptr()) -} - -type Struct interface { - Swigcptr() uintptr - SwigIsStruct() - SetNum(arg2 float64) - GetNum() (_swig_ret float64) -} - -type SwigcptrStructure uintptr - -func (p SwigcptrStructure) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrStructure) SwigIsStructure() { -} - -var _wrap_Structure_num_set unsafe.Pointer - -func _swig_wrap_Structure_num_set(base SwigcptrStructure, _ float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Structure_num_set, _swig_p) - return -} - -func (arg1 SwigcptrStructure) SetNum(arg2 float64) { - _swig_wrap_Structure_num_set(arg1, arg2) -} - -var _wrap_Structure_num_get unsafe.Pointer - -func _swig_wrap_Structure_num_get(base SwigcptrStructure) (_ float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Structure_num_get, _swig_p) - return -} - -func (arg1 SwigcptrStructure) GetNum() (_swig_ret float64) { - return _swig_wrap_Structure_num_get(arg1) -} - -var _wrap_new_Structure__SWIG_0 unsafe.Pointer - -func _swig_wrap_new_Structure__SWIG_0() (base SwigcptrStructure) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Structure__SWIG_0, _swig_p) - return -} - -func NewStructure__SWIG_0() (_swig_ret Structure) { - return _swig_wrap_new_Structure__SWIG_0() -} - -var _wrap_new_Structure__SWIG_1 unsafe.Pointer - -func _swig_wrap_new_Structure__SWIG_1(base float64) (_ SwigcptrStructure) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Structure__SWIG_1, _swig_p) - return -} - -func NewStructure__SWIG_1(arg1 float64) (_swig_ret Structure) { - return _swig_wrap_new_Structure__SWIG_1(arg1) -} - -func NewStructure(a ...interface{}) Structure { - argc := len(a) - if argc == 0 { - return NewStructure__SWIG_0() - } - if argc == 1 { - return NewStructure__SWIG_1(a[0].(float64)) - } - panic("No match for overloaded function call") -} - -var _wrap_delete_Structure unsafe.Pointer - -func _swig_wrap_delete_Structure(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Structure, _swig_p) - return -} - -func DeleteStructure(arg1 Structure) { - _swig_wrap_delete_Structure(arg1.Swigcptr()) -} - -type Structure interface { - Swigcptr() uintptr - SwigIsStructure() - SetNum(arg2 float64) - GetNum() (_swig_ret float64) -} - -var _wrap_vecreal unsafe.Pointer - -func _swig_wrap_vecreal(base uintptr) (_ SwigcptrRealVector) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_vecreal, _swig_p) - return -} - -func Vecreal(arg1 RealVector) (_swig_ret RealVector) { - return _swig_wrap_vecreal(arg1.Swigcptr()) -} - -var _wrap_vecintptr__SWIG_0 unsafe.Pointer - -func _swig_wrap_vecintptr__SWIG_0(base uintptr) (_ SwigcptrIntVector) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_vecintptr__SWIG_0, _swig_p) - return -} - -func Vecintptr__SWIG_0(arg1 IntVector) (_swig_ret IntVector) { - return _swig_wrap_vecintptr__SWIG_0(arg1.Swigcptr()) -} - -var _wrap_vecintptr__SWIG_1 unsafe.Pointer - -func _swig_wrap_vecintptr__SWIG_1(base uintptr) (_ SwigcptrIntPtrVector) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_vecintptr__SWIG_1, _swig_p) - return -} - -func Vecintptr__SWIG_1(arg1 IntPtrVector) (_swig_ret IntPtrVector) { - return _swig_wrap_vecintptr__SWIG_1(arg1.Swigcptr()) -} - -func Vecintptr(a ...interface{}) interface{} { - argc := len(a) - if argc == 1 { - if _, ok := a[0].(IntVector); !ok { - goto check_1 - } - return Vecintptr__SWIG_0(a[0].(IntVector)) - } -check_1: - if argc == 1 { - return Vecintptr__SWIG_1(a[0].(IntPtrVector)) - } - panic("No match for overloaded function call") -} - -var _wrap_vecintconstptr unsafe.Pointer - -func _swig_wrap_vecintconstptr(base uintptr) (_ SwigcptrIntConstPtrVector) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_vecintconstptr, _swig_p) - return -} - -func Vecintconstptr(arg1 IntConstPtrVector) (_swig_ret IntConstPtrVector) { - return _swig_wrap_vecintconstptr(arg1.Swigcptr()) -} - -var _wrap_vecstruct unsafe.Pointer - -func _swig_wrap_vecstruct(base uintptr) (_ SwigcptrStructVector) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_vecstruct, _swig_p) - return -} - -func Vecstruct(arg1 StructVector) (_swig_ret StructVector) { - return _swig_wrap_vecstruct(arg1.Swigcptr()) -} - -var _wrap_vecstructptr unsafe.Pointer - -func _swig_wrap_vecstructptr(base uintptr) (_ SwigcptrStructPtrVector) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_vecstructptr, _swig_p) - return -} - -func Vecstructptr(arg1 StructPtrVector) (_swig_ret StructPtrVector) { - return _swig_wrap_vecstructptr(arg1.Swigcptr()) -} - -var _wrap_vecstructconstptr unsafe.Pointer - -func _swig_wrap_vecstructconstptr(base uintptr) (_ SwigcptrStructConstPtrVector) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_vecstructconstptr, _swig_p) - return -} - -func Vecstructconstptr(arg1 StructConstPtrVector) (_swig_ret StructConstPtrVector) { - return _swig_wrap_vecstructconstptr(arg1.Swigcptr()) -} - -type SwigcptrIntPtrVector uintptr - -func (p SwigcptrIntPtrVector) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrIntPtrVector) SwigIsIntPtrVector() { -} - -var _wrap_new_IntPtrVector__SWIG_0 unsafe.Pointer - -func _swig_wrap_new_IntPtrVector__SWIG_0() (base SwigcptrIntPtrVector) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_IntPtrVector__SWIG_0, _swig_p) - return -} - -func NewIntPtrVector__SWIG_0() (_swig_ret IntPtrVector) { - return _swig_wrap_new_IntPtrVector__SWIG_0() -} - -var _wrap_new_IntPtrVector__SWIG_1 unsafe.Pointer - -func _swig_wrap_new_IntPtrVector__SWIG_1(base int64) (_ SwigcptrIntPtrVector) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_IntPtrVector__SWIG_1, _swig_p) - return -} - -func NewIntPtrVector__SWIG_1(arg1 int64) (_swig_ret IntPtrVector) { - return _swig_wrap_new_IntPtrVector__SWIG_1(arg1) -} - -func NewIntPtrVector(a ...interface{}) IntPtrVector { - argc := len(a) - if argc == 0 { - return NewIntPtrVector__SWIG_0() - } - if argc == 1 { - return NewIntPtrVector__SWIG_1(a[0].(int64)) - } - panic("No match for overloaded function call") -} - -var _wrap_IntPtrVector_size unsafe.Pointer - -func _swig_wrap_IntPtrVector_size(base SwigcptrIntPtrVector) (_ int64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_IntPtrVector_size, _swig_p) - return -} - -func (arg1 SwigcptrIntPtrVector) Size() (_swig_ret int64) { - return _swig_wrap_IntPtrVector_size(arg1) -} - -var _wrap_IntPtrVector_capacity unsafe.Pointer - -func _swig_wrap_IntPtrVector_capacity(base SwigcptrIntPtrVector) (_ int64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_IntPtrVector_capacity, _swig_p) - return -} - -func (arg1 SwigcptrIntPtrVector) Capacity() (_swig_ret int64) { - return _swig_wrap_IntPtrVector_capacity(arg1) -} - -var _wrap_IntPtrVector_reserve unsafe.Pointer - -func _swig_wrap_IntPtrVector_reserve(base SwigcptrIntPtrVector, _ int64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_IntPtrVector_reserve, _swig_p) - return -} - -func (arg1 SwigcptrIntPtrVector) Reserve(arg2 int64) { - _swig_wrap_IntPtrVector_reserve(arg1, arg2) -} - -var _wrap_IntPtrVector_isEmpty unsafe.Pointer - -func _swig_wrap_IntPtrVector_isEmpty(base SwigcptrIntPtrVector) (_ bool) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_IntPtrVector_isEmpty, _swig_p) - return -} - -func (arg1 SwigcptrIntPtrVector) IsEmpty() (_swig_ret bool) { - return _swig_wrap_IntPtrVector_isEmpty(arg1) -} - -var _wrap_IntPtrVector_clear unsafe.Pointer - -func _swig_wrap_IntPtrVector_clear(base SwigcptrIntPtrVector) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_IntPtrVector_clear, _swig_p) - return -} - -func (arg1 SwigcptrIntPtrVector) Clear() { - _swig_wrap_IntPtrVector_clear(arg1) -} - -var _wrap_IntPtrVector_add unsafe.Pointer - -func _swig_wrap_IntPtrVector_add(base SwigcptrIntPtrVector, _ *int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_IntPtrVector_add, _swig_p) - return -} - -func (arg1 SwigcptrIntPtrVector) Add(arg2 *int) { - _swig_wrap_IntPtrVector_add(arg1, arg2) -} - -var _wrap_IntPtrVector_get unsafe.Pointer - -func _swig_wrap_IntPtrVector_get(base SwigcptrIntPtrVector, _ int) (_ *int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_IntPtrVector_get, _swig_p) - return -} - -func (arg1 SwigcptrIntPtrVector) Get(arg2 int) (_swig_ret *int) { - return _swig_wrap_IntPtrVector_get(arg1, arg2) -} - -var _wrap_IntPtrVector_set unsafe.Pointer - -func _swig_wrap_IntPtrVector_set(base SwigcptrIntPtrVector, _ int, _ *int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_IntPtrVector_set, _swig_p) - return -} - -func (arg1 SwigcptrIntPtrVector) Set(arg2 int, arg3 *int) { - _swig_wrap_IntPtrVector_set(arg1, arg2, arg3) -} - -var _wrap_delete_IntPtrVector unsafe.Pointer - -func _swig_wrap_delete_IntPtrVector(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_IntPtrVector, _swig_p) - return -} - -func DeleteIntPtrVector(arg1 IntPtrVector) { - _swig_wrap_delete_IntPtrVector(arg1.Swigcptr()) -} - -type IntPtrVector interface { - Swigcptr() uintptr - SwigIsIntPtrVector() - Size() (_swig_ret int64) - Capacity() (_swig_ret int64) - Reserve(arg2 int64) - IsEmpty() (_swig_ret bool) - Clear() - Add(arg2 *int) - Get(arg2 int) (_swig_ret *int) - Set(arg2 int, arg3 *int) -} - -type SwigcptrIntConstPtrVector uintptr - -func (p SwigcptrIntConstPtrVector) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrIntConstPtrVector) SwigIsIntConstPtrVector() { -} - -var _wrap_new_IntConstPtrVector__SWIG_0 unsafe.Pointer - -func _swig_wrap_new_IntConstPtrVector__SWIG_0() (base SwigcptrIntConstPtrVector) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_IntConstPtrVector__SWIG_0, _swig_p) - return -} - -func NewIntConstPtrVector__SWIG_0() (_swig_ret IntConstPtrVector) { - return _swig_wrap_new_IntConstPtrVector__SWIG_0() -} - -var _wrap_new_IntConstPtrVector__SWIG_1 unsafe.Pointer - -func _swig_wrap_new_IntConstPtrVector__SWIG_1(base int64) (_ SwigcptrIntConstPtrVector) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_IntConstPtrVector__SWIG_1, _swig_p) - return -} - -func NewIntConstPtrVector__SWIG_1(arg1 int64) (_swig_ret IntConstPtrVector) { - return _swig_wrap_new_IntConstPtrVector__SWIG_1(arg1) -} - -func NewIntConstPtrVector(a ...interface{}) IntConstPtrVector { - argc := len(a) - if argc == 0 { - return NewIntConstPtrVector__SWIG_0() - } - if argc == 1 { - return NewIntConstPtrVector__SWIG_1(a[0].(int64)) - } - panic("No match for overloaded function call") -} - -var _wrap_IntConstPtrVector_size unsafe.Pointer - -func _swig_wrap_IntConstPtrVector_size(base SwigcptrIntConstPtrVector) (_ int64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_IntConstPtrVector_size, _swig_p) - return -} - -func (arg1 SwigcptrIntConstPtrVector) Size() (_swig_ret int64) { - return _swig_wrap_IntConstPtrVector_size(arg1) -} - -var _wrap_IntConstPtrVector_capacity unsafe.Pointer - -func _swig_wrap_IntConstPtrVector_capacity(base SwigcptrIntConstPtrVector) (_ int64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_IntConstPtrVector_capacity, _swig_p) - return -} - -func (arg1 SwigcptrIntConstPtrVector) Capacity() (_swig_ret int64) { - return _swig_wrap_IntConstPtrVector_capacity(arg1) -} - -var _wrap_IntConstPtrVector_reserve unsafe.Pointer - -func _swig_wrap_IntConstPtrVector_reserve(base SwigcptrIntConstPtrVector, _ int64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_IntConstPtrVector_reserve, _swig_p) - return -} - -func (arg1 SwigcptrIntConstPtrVector) Reserve(arg2 int64) { - _swig_wrap_IntConstPtrVector_reserve(arg1, arg2) -} - -var _wrap_IntConstPtrVector_isEmpty unsafe.Pointer - -func _swig_wrap_IntConstPtrVector_isEmpty(base SwigcptrIntConstPtrVector) (_ bool) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_IntConstPtrVector_isEmpty, _swig_p) - return -} - -func (arg1 SwigcptrIntConstPtrVector) IsEmpty() (_swig_ret bool) { - return _swig_wrap_IntConstPtrVector_isEmpty(arg1) -} - -var _wrap_IntConstPtrVector_clear unsafe.Pointer - -func _swig_wrap_IntConstPtrVector_clear(base SwigcptrIntConstPtrVector) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_IntConstPtrVector_clear, _swig_p) - return -} - -func (arg1 SwigcptrIntConstPtrVector) Clear() { - _swig_wrap_IntConstPtrVector_clear(arg1) -} - -var _wrap_IntConstPtrVector_add unsafe.Pointer - -func _swig_wrap_IntConstPtrVector_add(base SwigcptrIntConstPtrVector, _ *int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_IntConstPtrVector_add, _swig_p) - return -} - -func (arg1 SwigcptrIntConstPtrVector) Add(arg2 *int) { - _swig_wrap_IntConstPtrVector_add(arg1, arg2) -} - -var _wrap_IntConstPtrVector_get unsafe.Pointer - -func _swig_wrap_IntConstPtrVector_get(base SwigcptrIntConstPtrVector, _ int) (_ *int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_IntConstPtrVector_get, _swig_p) - return -} - -func (arg1 SwigcptrIntConstPtrVector) Get(arg2 int) (_swig_ret *int) { - return _swig_wrap_IntConstPtrVector_get(arg1, arg2) -} - -var _wrap_IntConstPtrVector_set unsafe.Pointer - -func _swig_wrap_IntConstPtrVector_set(base SwigcptrIntConstPtrVector, _ int, _ *int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_IntConstPtrVector_set, _swig_p) - return -} - -func (arg1 SwigcptrIntConstPtrVector) Set(arg2 int, arg3 *int) { - _swig_wrap_IntConstPtrVector_set(arg1, arg2, arg3) -} - -var _wrap_delete_IntConstPtrVector unsafe.Pointer - -func _swig_wrap_delete_IntConstPtrVector(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_IntConstPtrVector, _swig_p) - return -} - -func DeleteIntConstPtrVector(arg1 IntConstPtrVector) { - _swig_wrap_delete_IntConstPtrVector(arg1.Swigcptr()) -} - -type IntConstPtrVector interface { - Swigcptr() uintptr - SwigIsIntConstPtrVector() - Size() (_swig_ret int64) - Capacity() (_swig_ret int64) - Reserve(arg2 int64) - IsEmpty() (_swig_ret bool) - Clear() - Add(arg2 *int) - Get(arg2 int) (_swig_ret *int) - Set(arg2 int, arg3 *int) -} - -type SwigcptrStructVector uintptr - -func (p SwigcptrStructVector) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrStructVector) SwigIsStructVector() { -} - -var _wrap_new_StructVector__SWIG_0 unsafe.Pointer - -func _swig_wrap_new_StructVector__SWIG_0() (base SwigcptrStructVector) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_StructVector__SWIG_0, _swig_p) - return -} - -func NewStructVector__SWIG_0() (_swig_ret StructVector) { - return _swig_wrap_new_StructVector__SWIG_0() -} - -var _wrap_new_StructVector__SWIG_1 unsafe.Pointer - -func _swig_wrap_new_StructVector__SWIG_1(base int64) (_ SwigcptrStructVector) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_StructVector__SWIG_1, _swig_p) - return -} - -func NewStructVector__SWIG_1(arg1 int64) (_swig_ret StructVector) { - return _swig_wrap_new_StructVector__SWIG_1(arg1) -} - -func NewStructVector(a ...interface{}) StructVector { - argc := len(a) - if argc == 0 { - return NewStructVector__SWIG_0() - } - if argc == 1 { - return NewStructVector__SWIG_1(a[0].(int64)) - } - panic("No match for overloaded function call") -} - -var _wrap_StructVector_size unsafe.Pointer - -func _swig_wrap_StructVector_size(base SwigcptrStructVector) (_ int64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_StructVector_size, _swig_p) - return -} - -func (arg1 SwigcptrStructVector) Size() (_swig_ret int64) { - return _swig_wrap_StructVector_size(arg1) -} - -var _wrap_StructVector_capacity unsafe.Pointer - -func _swig_wrap_StructVector_capacity(base SwigcptrStructVector) (_ int64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_StructVector_capacity, _swig_p) - return -} - -func (arg1 SwigcptrStructVector) Capacity() (_swig_ret int64) { - return _swig_wrap_StructVector_capacity(arg1) -} - -var _wrap_StructVector_reserve unsafe.Pointer - -func _swig_wrap_StructVector_reserve(base SwigcptrStructVector, _ int64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_StructVector_reserve, _swig_p) - return -} - -func (arg1 SwigcptrStructVector) Reserve(arg2 int64) { - _swig_wrap_StructVector_reserve(arg1, arg2) -} - -var _wrap_StructVector_isEmpty unsafe.Pointer - -func _swig_wrap_StructVector_isEmpty(base SwigcptrStructVector) (_ bool) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_StructVector_isEmpty, _swig_p) - return -} - -func (arg1 SwigcptrStructVector) IsEmpty() (_swig_ret bool) { - return _swig_wrap_StructVector_isEmpty(arg1) -} - -var _wrap_StructVector_clear unsafe.Pointer - -func _swig_wrap_StructVector_clear(base SwigcptrStructVector) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_StructVector_clear, _swig_p) - return -} - -func (arg1 SwigcptrStructVector) Clear() { - _swig_wrap_StructVector_clear(arg1) -} - -var _wrap_StructVector_add unsafe.Pointer - -func _swig_wrap_StructVector_add(base SwigcptrStructVector, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_StructVector_add, _swig_p) - return -} - -func (arg1 SwigcptrStructVector) Add(arg2 Struct) { - _swig_wrap_StructVector_add(arg1, arg2.Swigcptr()) -} - -var _wrap_StructVector_get unsafe.Pointer - -func _swig_wrap_StructVector_get(base SwigcptrStructVector, _ int) (_ SwigcptrStruct) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_StructVector_get, _swig_p) - return -} - -func (arg1 SwigcptrStructVector) Get(arg2 int) (_swig_ret Struct) { - return _swig_wrap_StructVector_get(arg1, arg2) -} - -var _wrap_StructVector_set unsafe.Pointer - -func _swig_wrap_StructVector_set(base SwigcptrStructVector, _ int, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_StructVector_set, _swig_p) - return -} - -func (arg1 SwigcptrStructVector) Set(arg2 int, arg3 Struct) { - _swig_wrap_StructVector_set(arg1, arg2, arg3.Swigcptr()) -} - -var _wrap_delete_StructVector unsafe.Pointer - -func _swig_wrap_delete_StructVector(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_StructVector, _swig_p) - return -} - -func DeleteStructVector(arg1 StructVector) { - _swig_wrap_delete_StructVector(arg1.Swigcptr()) -} - -type StructVector interface { - Swigcptr() uintptr - SwigIsStructVector() - Size() (_swig_ret int64) - Capacity() (_swig_ret int64) - Reserve(arg2 int64) - IsEmpty() (_swig_ret bool) - Clear() - Add(arg2 Struct) - Get(arg2 int) (_swig_ret Struct) - Set(arg2 int, arg3 Struct) -} - -type SwigcptrStructPtrVector uintptr - -func (p SwigcptrStructPtrVector) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrStructPtrVector) SwigIsStructPtrVector() { -} - -var _wrap_new_StructPtrVector__SWIG_0 unsafe.Pointer - -func _swig_wrap_new_StructPtrVector__SWIG_0() (base SwigcptrStructPtrVector) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_StructPtrVector__SWIG_0, _swig_p) - return -} - -func NewStructPtrVector__SWIG_0() (_swig_ret StructPtrVector) { - return _swig_wrap_new_StructPtrVector__SWIG_0() -} - -var _wrap_new_StructPtrVector__SWIG_1 unsafe.Pointer - -func _swig_wrap_new_StructPtrVector__SWIG_1(base int64) (_ SwigcptrStructPtrVector) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_StructPtrVector__SWIG_1, _swig_p) - return -} - -func NewStructPtrVector__SWIG_1(arg1 int64) (_swig_ret StructPtrVector) { - return _swig_wrap_new_StructPtrVector__SWIG_1(arg1) -} - -func NewStructPtrVector(a ...interface{}) StructPtrVector { - argc := len(a) - if argc == 0 { - return NewStructPtrVector__SWIG_0() - } - if argc == 1 { - return NewStructPtrVector__SWIG_1(a[0].(int64)) - } - panic("No match for overloaded function call") -} - -var _wrap_StructPtrVector_size unsafe.Pointer - -func _swig_wrap_StructPtrVector_size(base SwigcptrStructPtrVector) (_ int64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_StructPtrVector_size, _swig_p) - return -} - -func (arg1 SwigcptrStructPtrVector) Size() (_swig_ret int64) { - return _swig_wrap_StructPtrVector_size(arg1) -} - -var _wrap_StructPtrVector_capacity unsafe.Pointer - -func _swig_wrap_StructPtrVector_capacity(base SwigcptrStructPtrVector) (_ int64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_StructPtrVector_capacity, _swig_p) - return -} - -func (arg1 SwigcptrStructPtrVector) Capacity() (_swig_ret int64) { - return _swig_wrap_StructPtrVector_capacity(arg1) -} - -var _wrap_StructPtrVector_reserve unsafe.Pointer - -func _swig_wrap_StructPtrVector_reserve(base SwigcptrStructPtrVector, _ int64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_StructPtrVector_reserve, _swig_p) - return -} - -func (arg1 SwigcptrStructPtrVector) Reserve(arg2 int64) { - _swig_wrap_StructPtrVector_reserve(arg1, arg2) -} - -var _wrap_StructPtrVector_isEmpty unsafe.Pointer - -func _swig_wrap_StructPtrVector_isEmpty(base SwigcptrStructPtrVector) (_ bool) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_StructPtrVector_isEmpty, _swig_p) - return -} - -func (arg1 SwigcptrStructPtrVector) IsEmpty() (_swig_ret bool) { - return _swig_wrap_StructPtrVector_isEmpty(arg1) -} - -var _wrap_StructPtrVector_clear unsafe.Pointer - -func _swig_wrap_StructPtrVector_clear(base SwigcptrStructPtrVector) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_StructPtrVector_clear, _swig_p) - return -} - -func (arg1 SwigcptrStructPtrVector) Clear() { - _swig_wrap_StructPtrVector_clear(arg1) -} - -var _wrap_StructPtrVector_add unsafe.Pointer - -func _swig_wrap_StructPtrVector_add(base SwigcptrStructPtrVector, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_StructPtrVector_add, _swig_p) - return -} - -func (arg1 SwigcptrStructPtrVector) Add(arg2 Struct) { - _swig_wrap_StructPtrVector_add(arg1, arg2.Swigcptr()) -} - -var _wrap_StructPtrVector_get unsafe.Pointer - -func _swig_wrap_StructPtrVector_get(base SwigcptrStructPtrVector, _ int) (_ SwigcptrStruct) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_StructPtrVector_get, _swig_p) - return -} - -func (arg1 SwigcptrStructPtrVector) Get(arg2 int) (_swig_ret Struct) { - return _swig_wrap_StructPtrVector_get(arg1, arg2) -} - -var _wrap_StructPtrVector_set unsafe.Pointer - -func _swig_wrap_StructPtrVector_set(base SwigcptrStructPtrVector, _ int, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_StructPtrVector_set, _swig_p) - return -} - -func (arg1 SwigcptrStructPtrVector) Set(arg2 int, arg3 Struct) { - _swig_wrap_StructPtrVector_set(arg1, arg2, arg3.Swigcptr()) -} - -var _wrap_delete_StructPtrVector unsafe.Pointer - -func _swig_wrap_delete_StructPtrVector(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_StructPtrVector, _swig_p) - return -} - -func DeleteStructPtrVector(arg1 StructPtrVector) { - _swig_wrap_delete_StructPtrVector(arg1.Swigcptr()) -} - -type StructPtrVector interface { - Swigcptr() uintptr - SwigIsStructPtrVector() - Size() (_swig_ret int64) - Capacity() (_swig_ret int64) - Reserve(arg2 int64) - IsEmpty() (_swig_ret bool) - Clear() - Add(arg2 Struct) - Get(arg2 int) (_swig_ret Struct) - Set(arg2 int, arg3 Struct) -} - -type SwigcptrStructConstPtrVector uintptr - -func (p SwigcptrStructConstPtrVector) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrStructConstPtrVector) SwigIsStructConstPtrVector() { -} - -var _wrap_new_StructConstPtrVector__SWIG_0 unsafe.Pointer - -func _swig_wrap_new_StructConstPtrVector__SWIG_0() (base SwigcptrStructConstPtrVector) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_StructConstPtrVector__SWIG_0, _swig_p) - return -} - -func NewStructConstPtrVector__SWIG_0() (_swig_ret StructConstPtrVector) { - return _swig_wrap_new_StructConstPtrVector__SWIG_0() -} - -var _wrap_new_StructConstPtrVector__SWIG_1 unsafe.Pointer - -func _swig_wrap_new_StructConstPtrVector__SWIG_1(base int64) (_ SwigcptrStructConstPtrVector) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_StructConstPtrVector__SWIG_1, _swig_p) - return -} - -func NewStructConstPtrVector__SWIG_1(arg1 int64) (_swig_ret StructConstPtrVector) { - return _swig_wrap_new_StructConstPtrVector__SWIG_1(arg1) -} - -func NewStructConstPtrVector(a ...interface{}) StructConstPtrVector { - argc := len(a) - if argc == 0 { - return NewStructConstPtrVector__SWIG_0() - } - if argc == 1 { - return NewStructConstPtrVector__SWIG_1(a[0].(int64)) - } - panic("No match for overloaded function call") -} - -var _wrap_StructConstPtrVector_size unsafe.Pointer - -func _swig_wrap_StructConstPtrVector_size(base SwigcptrStructConstPtrVector) (_ int64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_StructConstPtrVector_size, _swig_p) - return -} - -func (arg1 SwigcptrStructConstPtrVector) Size() (_swig_ret int64) { - return _swig_wrap_StructConstPtrVector_size(arg1) -} - -var _wrap_StructConstPtrVector_capacity unsafe.Pointer - -func _swig_wrap_StructConstPtrVector_capacity(base SwigcptrStructConstPtrVector) (_ int64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_StructConstPtrVector_capacity, _swig_p) - return -} - -func (arg1 SwigcptrStructConstPtrVector) Capacity() (_swig_ret int64) { - return _swig_wrap_StructConstPtrVector_capacity(arg1) -} - -var _wrap_StructConstPtrVector_reserve unsafe.Pointer - -func _swig_wrap_StructConstPtrVector_reserve(base SwigcptrStructConstPtrVector, _ int64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_StructConstPtrVector_reserve, _swig_p) - return -} - -func (arg1 SwigcptrStructConstPtrVector) Reserve(arg2 int64) { - _swig_wrap_StructConstPtrVector_reserve(arg1, arg2) -} - -var _wrap_StructConstPtrVector_isEmpty unsafe.Pointer - -func _swig_wrap_StructConstPtrVector_isEmpty(base SwigcptrStructConstPtrVector) (_ bool) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_StructConstPtrVector_isEmpty, _swig_p) - return -} - -func (arg1 SwigcptrStructConstPtrVector) IsEmpty() (_swig_ret bool) { - return _swig_wrap_StructConstPtrVector_isEmpty(arg1) -} - -var _wrap_StructConstPtrVector_clear unsafe.Pointer - -func _swig_wrap_StructConstPtrVector_clear(base SwigcptrStructConstPtrVector) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_StructConstPtrVector_clear, _swig_p) - return -} - -func (arg1 SwigcptrStructConstPtrVector) Clear() { - _swig_wrap_StructConstPtrVector_clear(arg1) -} - -var _wrap_StructConstPtrVector_add unsafe.Pointer - -func _swig_wrap_StructConstPtrVector_add(base SwigcptrStructConstPtrVector, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_StructConstPtrVector_add, _swig_p) - return -} - -func (arg1 SwigcptrStructConstPtrVector) Add(arg2 Struct) { - _swig_wrap_StructConstPtrVector_add(arg1, arg2.Swigcptr()) -} - -var _wrap_StructConstPtrVector_get unsafe.Pointer - -func _swig_wrap_StructConstPtrVector_get(base SwigcptrStructConstPtrVector, _ int) (_ SwigcptrStruct) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_StructConstPtrVector_get, _swig_p) - return -} - -func (arg1 SwigcptrStructConstPtrVector) Get(arg2 int) (_swig_ret Struct) { - return _swig_wrap_StructConstPtrVector_get(arg1, arg2) -} - -var _wrap_StructConstPtrVector_set unsafe.Pointer - -func _swig_wrap_StructConstPtrVector_set(base SwigcptrStructConstPtrVector, _ int, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_StructConstPtrVector_set, _swig_p) - return -} - -func (arg1 SwigcptrStructConstPtrVector) Set(arg2 int, arg3 Struct) { - _swig_wrap_StructConstPtrVector_set(arg1, arg2, arg3.Swigcptr()) -} - -var _wrap_delete_StructConstPtrVector unsafe.Pointer - -func _swig_wrap_delete_StructConstPtrVector(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_StructConstPtrVector, _swig_p) - return -} - -func DeleteStructConstPtrVector(arg1 StructConstPtrVector) { - _swig_wrap_delete_StructConstPtrVector(arg1.Swigcptr()) -} - -type StructConstPtrVector interface { - Swigcptr() uintptr - SwigIsStructConstPtrVector() - Size() (_swig_ret int64) - Capacity() (_swig_ret int64) - Reserve(arg2 int64) - IsEmpty() (_swig_ret bool) - Clear() - Add(arg2 Struct) - Get(arg2 int) (_swig_ret Struct) - Set(arg2 int, arg3 Struct) -} - -type SwigcptrMyClass uintptr - -func (p SwigcptrMyClass) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrMyClass) SwigIsMyClass() { -} - -var _wrap_new_MyClass unsafe.Pointer - -func _swig_wrap_new_MyClass() (base SwigcptrMyClass) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_MyClass, _swig_p) - return -} - -func NewMyClass() (_swig_ret MyClass) { - return _swig_wrap_new_MyClass() -} - -var _wrap_delete_MyClass unsafe.Pointer - -func _swig_wrap_delete_MyClass(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_MyClass, _swig_p) - return -} - -func DeleteMyClass(arg1 MyClass) { - _swig_wrap_delete_MyClass(arg1.Swigcptr()) -} - -type MyClass interface { - Swigcptr() uintptr - SwigIsMyClass() -} - -type SwigcptrMyClassPtrVector uintptr - -func (p SwigcptrMyClassPtrVector) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrMyClassPtrVector) SwigIsMyClassPtrVector() { -} - -var _wrap_new_MyClassPtrVector__SWIG_0 unsafe.Pointer - -func _swig_wrap_new_MyClassPtrVector__SWIG_0() (base SwigcptrMyClassPtrVector) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_MyClassPtrVector__SWIG_0, _swig_p) - return -} - -func NewMyClassPtrVector__SWIG_0() (_swig_ret MyClassPtrVector) { - return _swig_wrap_new_MyClassPtrVector__SWIG_0() -} - -var _wrap_new_MyClassPtrVector__SWIG_1 unsafe.Pointer - -func _swig_wrap_new_MyClassPtrVector__SWIG_1(base int64) (_ SwigcptrMyClassPtrVector) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_MyClassPtrVector__SWIG_1, _swig_p) - return -} - -func NewMyClassPtrVector__SWIG_1(arg1 int64) (_swig_ret MyClassPtrVector) { - return _swig_wrap_new_MyClassPtrVector__SWIG_1(arg1) -} - -func NewMyClassPtrVector(a ...interface{}) MyClassPtrVector { - argc := len(a) - if argc == 0 { - return NewMyClassPtrVector__SWIG_0() - } - if argc == 1 { - return NewMyClassPtrVector__SWIG_1(a[0].(int64)) - } - panic("No match for overloaded function call") -} - -var _wrap_MyClassPtrVector_size unsafe.Pointer - -func _swig_wrap_MyClassPtrVector_size(base SwigcptrMyClassPtrVector) (_ int64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_MyClassPtrVector_size, _swig_p) - return -} - -func (arg1 SwigcptrMyClassPtrVector) Size() (_swig_ret int64) { - return _swig_wrap_MyClassPtrVector_size(arg1) -} - -var _wrap_MyClassPtrVector_capacity unsafe.Pointer - -func _swig_wrap_MyClassPtrVector_capacity(base SwigcptrMyClassPtrVector) (_ int64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_MyClassPtrVector_capacity, _swig_p) - return -} - -func (arg1 SwigcptrMyClassPtrVector) Capacity() (_swig_ret int64) { - return _swig_wrap_MyClassPtrVector_capacity(arg1) -} - -var _wrap_MyClassPtrVector_reserve unsafe.Pointer - -func _swig_wrap_MyClassPtrVector_reserve(base SwigcptrMyClassPtrVector, _ int64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_MyClassPtrVector_reserve, _swig_p) - return -} - -func (arg1 SwigcptrMyClassPtrVector) Reserve(arg2 int64) { - _swig_wrap_MyClassPtrVector_reserve(arg1, arg2) -} - -var _wrap_MyClassPtrVector_isEmpty unsafe.Pointer - -func _swig_wrap_MyClassPtrVector_isEmpty(base SwigcptrMyClassPtrVector) (_ bool) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_MyClassPtrVector_isEmpty, _swig_p) - return -} - -func (arg1 SwigcptrMyClassPtrVector) IsEmpty() (_swig_ret bool) { - return _swig_wrap_MyClassPtrVector_isEmpty(arg1) -} - -var _wrap_MyClassPtrVector_clear unsafe.Pointer - -func _swig_wrap_MyClassPtrVector_clear(base SwigcptrMyClassPtrVector) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_MyClassPtrVector_clear, _swig_p) - return -} - -func (arg1 SwigcptrMyClassPtrVector) Clear() { - _swig_wrap_MyClassPtrVector_clear(arg1) -} - -var _wrap_MyClassPtrVector_add unsafe.Pointer - -func _swig_wrap_MyClassPtrVector_add(base SwigcptrMyClassPtrVector, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_MyClassPtrVector_add, _swig_p) - return -} - -func (arg1 SwigcptrMyClassPtrVector) Add(arg2 MyClass) { - _swig_wrap_MyClassPtrVector_add(arg1, arg2.Swigcptr()) -} - -var _wrap_MyClassPtrVector_get unsafe.Pointer - -func _swig_wrap_MyClassPtrVector_get(base SwigcptrMyClassPtrVector, _ int) (_ SwigcptrMyClass) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_MyClassPtrVector_get, _swig_p) - return -} - -func (arg1 SwigcptrMyClassPtrVector) Get(arg2 int) (_swig_ret MyClass) { - return _swig_wrap_MyClassPtrVector_get(arg1, arg2) -} - -var _wrap_MyClassPtrVector_set unsafe.Pointer - -func _swig_wrap_MyClassPtrVector_set(base SwigcptrMyClassPtrVector, _ int, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_MyClassPtrVector_set, _swig_p) - return -} - -func (arg1 SwigcptrMyClassPtrVector) Set(arg2 int, arg3 MyClass) { - _swig_wrap_MyClassPtrVector_set(arg1, arg2, arg3.Swigcptr()) -} - -var _wrap_delete_MyClassPtrVector unsafe.Pointer - -func _swig_wrap_delete_MyClassPtrVector(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_MyClassPtrVector, _swig_p) - return -} - -func DeleteMyClassPtrVector(arg1 MyClassPtrVector) { - _swig_wrap_delete_MyClassPtrVector(arg1.Swigcptr()) -} - -type MyClassPtrVector interface { - Swigcptr() uintptr - SwigIsMyClassPtrVector() - Size() (_swig_ret int64) - Capacity() (_swig_ret int64) - Reserve(arg2 int64) - IsEmpty() (_swig_ret bool) - Clear() - Add(arg2 MyClass) - Get(arg2 int) (_swig_ret MyClass) - Set(arg2 int, arg3 MyClass) -} - -type SwigcptrRetsMetadata uintptr - -func (p SwigcptrRetsMetadata) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrRetsMetadata) SwigIsRetsMetadata() { -} - -var _wrap_RetsMetadata_GetAllResources unsafe.Pointer - -func _swig_wrap_RetsMetadata_GetAllResources(base SwigcptrRetsMetadata, _ int64) (_ SwigcptrMyClassPtrVector) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_RetsMetadata_GetAllResources, _swig_p) - return -} - -func (arg1 SwigcptrRetsMetadata) GetAllResources(arg2 int64) (_swig_ret MyClassPtrVector) { - return _swig_wrap_RetsMetadata_GetAllResources(arg1, arg2) -} - -var _wrap_new_RetsMetadata unsafe.Pointer - -func _swig_wrap_new_RetsMetadata() (base SwigcptrRetsMetadata) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_RetsMetadata, _swig_p) - return -} - -func NewRetsMetadata() (_swig_ret RetsMetadata) { - return _swig_wrap_new_RetsMetadata() -} - -var _wrap_delete_RetsMetadata unsafe.Pointer - -func _swig_wrap_delete_RetsMetadata(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_RetsMetadata, _swig_p) - return -} - -func DeleteRetsMetadata(arg1 RetsMetadata) { - _swig_wrap_delete_RetsMetadata(arg1.Swigcptr()) -} - -type RetsMetadata interface { - Swigcptr() uintptr - SwigIsRetsMetadata() - GetAllResources(arg2 int64) (_swig_ret MyClassPtrVector) -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/li_std_vector_enum.go b/Examples/test-suite/go/li_std_vector_enum.go deleted file mode 100644 index 335520588..000000000 --- a/Examples/test-suite/go/li_std_vector_enum.go +++ /dev/null @@ -1,304 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../li_std_vector_enum.i - -package li_std_vector_enum - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrEnumVector uintptr - -func (p SwigcptrEnumVector) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrEnumVector) SwigIsEnumVector() { -} - -var _wrap_new_EnumVector unsafe.Pointer - -func _swig_wrap_new_EnumVector() (base SwigcptrEnumVector) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_EnumVector, _swig_p) - return -} - -func NewEnumVector() (_swig_ret EnumVector) { - return _swig_wrap_new_EnumVector() -} - -type EnumVectorNumbers int -var _wrap_ten_EnumVector unsafe.Pointer - -func _swig_getEnumVector_ten_EnumVector() (_swig_ret EnumVectorNumbers) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_ten_EnumVector, _swig_p) - return -} -var EnumVectorTen EnumVectorNumbers = _swig_getEnumVector_ten_EnumVector() -var _wrap_twenty_EnumVector unsafe.Pointer - -func _swig_getEnumVector_twenty_EnumVector() (_swig_ret EnumVectorNumbers) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_twenty_EnumVector, _swig_p) - return -} -var EnumVectorTwenty EnumVectorNumbers = _swig_getEnumVector_twenty_EnumVector() -var _wrap_thirty_EnumVector unsafe.Pointer - -func _swig_getEnumVector_thirty_EnumVector() (_swig_ret EnumVectorNumbers) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_thirty_EnumVector, _swig_p) - return -} -var EnumVectorThirty EnumVectorNumbers = _swig_getEnumVector_thirty_EnumVector() -var _wrap_EnumVector_nums_set unsafe.Pointer - -func _swig_wrap_EnumVector_nums_set(base SwigcptrEnumVector, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_EnumVector_nums_set, _swig_p) - return -} - -func (arg1 SwigcptrEnumVector) SetNums(arg2 Vector_numbers) { - _swig_wrap_EnumVector_nums_set(arg1, arg2.Swigcptr()) -} - -var _wrap_EnumVector_nums_get unsafe.Pointer - -func _swig_wrap_EnumVector_nums_get(base SwigcptrEnumVector) (_ SwigcptrVector_numbers) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_EnumVector_nums_get, _swig_p) - return -} - -func (arg1 SwigcptrEnumVector) GetNums() (_swig_ret Vector_numbers) { - return _swig_wrap_EnumVector_nums_get(arg1) -} - -var _wrap_EnumVector_fill_numbers unsafe.Pointer - -func _swig_wrap_EnumVector_fill_numbers(base SwigcptrEnumVector) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_EnumVector_fill_numbers, _swig_p) - return -} - -func (arg1 SwigcptrEnumVector) Fill_numbers() { - _swig_wrap_EnumVector_fill_numbers(arg1) -} - -var _wrap_delete_EnumVector unsafe.Pointer - -func _swig_wrap_delete_EnumVector(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_EnumVector, _swig_p) - return -} - -func DeleteEnumVector(arg1 EnumVector) { - _swig_wrap_delete_EnumVector(arg1.Swigcptr()) -} - -type EnumVector interface { - Swigcptr() uintptr - SwigIsEnumVector() - SetNums(arg2 Vector_numbers) - GetNums() (_swig_ret Vector_numbers) - Fill_numbers() -} - -type SwigcptrVector_numbers uintptr - -func (p SwigcptrVector_numbers) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrVector_numbers) SwigIsVector_numbers() { -} - -var _wrap_new_vector_numbers__SWIG_0 unsafe.Pointer - -func _swig_wrap_new_vector_numbers__SWIG_0() (base SwigcptrVector_numbers) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_vector_numbers__SWIG_0, _swig_p) - return -} - -func NewVector_numbers__SWIG_0() (_swig_ret Vector_numbers) { - return _swig_wrap_new_vector_numbers__SWIG_0() -} - -var _wrap_new_vector_numbers__SWIG_1 unsafe.Pointer - -func _swig_wrap_new_vector_numbers__SWIG_1(base int64) (_ SwigcptrVector_numbers) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_vector_numbers__SWIG_1, _swig_p) - return -} - -func NewVector_numbers__SWIG_1(arg1 int64) (_swig_ret Vector_numbers) { - return _swig_wrap_new_vector_numbers__SWIG_1(arg1) -} - -func NewVector_numbers(a ...interface{}) Vector_numbers { - argc := len(a) - if argc == 0 { - return NewVector_numbers__SWIG_0() - } - if argc == 1 { - return NewVector_numbers__SWIG_1(a[0].(int64)) - } - panic("No match for overloaded function call") -} - -var _wrap_vector_numbers_size unsafe.Pointer - -func _swig_wrap_vector_numbers_size(base SwigcptrVector_numbers) (_ int64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_vector_numbers_size, _swig_p) - return -} - -func (arg1 SwigcptrVector_numbers) Size() (_swig_ret int64) { - return _swig_wrap_vector_numbers_size(arg1) -} - -var _wrap_vector_numbers_capacity unsafe.Pointer - -func _swig_wrap_vector_numbers_capacity(base SwigcptrVector_numbers) (_ int64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_vector_numbers_capacity, _swig_p) - return -} - -func (arg1 SwigcptrVector_numbers) Capacity() (_swig_ret int64) { - return _swig_wrap_vector_numbers_capacity(arg1) -} - -var _wrap_vector_numbers_reserve unsafe.Pointer - -func _swig_wrap_vector_numbers_reserve(base SwigcptrVector_numbers, _ int64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_vector_numbers_reserve, _swig_p) - return -} - -func (arg1 SwigcptrVector_numbers) Reserve(arg2 int64) { - _swig_wrap_vector_numbers_reserve(arg1, arg2) -} - -var _wrap_vector_numbers_isEmpty unsafe.Pointer - -func _swig_wrap_vector_numbers_isEmpty(base SwigcptrVector_numbers) (_ bool) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_vector_numbers_isEmpty, _swig_p) - return -} - -func (arg1 SwigcptrVector_numbers) IsEmpty() (_swig_ret bool) { - return _swig_wrap_vector_numbers_isEmpty(arg1) -} - -var _wrap_vector_numbers_clear unsafe.Pointer - -func _swig_wrap_vector_numbers_clear(base SwigcptrVector_numbers) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_vector_numbers_clear, _swig_p) - return -} - -func (arg1 SwigcptrVector_numbers) Clear() { - _swig_wrap_vector_numbers_clear(arg1) -} - -var _wrap_vector_numbers_add unsafe.Pointer - -func _swig_wrap_vector_numbers_add(base SwigcptrVector_numbers, _ *EnumVectorNumbers) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_vector_numbers_add, _swig_p) - return -} - -func (arg1 SwigcptrVector_numbers) Add(arg2 *EnumVectorNumbers) { - _swig_wrap_vector_numbers_add(arg1, arg2) -} - -var _wrap_vector_numbers_get unsafe.Pointer - -func _swig_wrap_vector_numbers_get(base SwigcptrVector_numbers, _ int) (_ *EnumVectorNumbers) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_vector_numbers_get, _swig_p) - return -} - -func (arg1 SwigcptrVector_numbers) Get(arg2 int) (_swig_ret *EnumVectorNumbers) { - return _swig_wrap_vector_numbers_get(arg1, arg2) -} - -var _wrap_vector_numbers_set unsafe.Pointer - -func _swig_wrap_vector_numbers_set(base SwigcptrVector_numbers, _ int, _ *EnumVectorNumbers) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_vector_numbers_set, _swig_p) - return -} - -func (arg1 SwigcptrVector_numbers) Set(arg2 int, arg3 *EnumVectorNumbers) { - _swig_wrap_vector_numbers_set(arg1, arg2, arg3) -} - -var _wrap_delete_vector_numbers unsafe.Pointer - -func _swig_wrap_delete_vector_numbers(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_vector_numbers, _swig_p) - return -} - -func DeleteVector_numbers(arg1 Vector_numbers) { - _swig_wrap_delete_vector_numbers(arg1.Swigcptr()) -} - -type Vector_numbers interface { - Swigcptr() uintptr - SwigIsVector_numbers() - Size() (_swig_ret int64) - Capacity() (_swig_ret int64) - Reserve(arg2 int64) - IsEmpty() (_swig_ret bool) - Clear() - Add(arg2 *EnumVectorNumbers) - Get(arg2 int) (_swig_ret *EnumVectorNumbers) - Set(arg2 int, arg3 *EnumVectorNumbers) -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/li_std_vector_member_var.go b/Examples/test-suite/go/li_std_vector_member_var.go deleted file mode 100644 index b58619888..000000000 --- a/Examples/test-suite/go/li_std_vector_member_var.go +++ /dev/null @@ -1,459 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../li_std_vector_member_var.i - -package li_std_vector_member_var - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrVectorDbl uintptr - -func (p SwigcptrVectorDbl) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrVectorDbl) SwigIsVectorDbl() { -} - -var _wrap_new_vectorDbl__SWIG_0 unsafe.Pointer - -func _swig_wrap_new_vectorDbl__SWIG_0() (base SwigcptrVectorDbl) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_vectorDbl__SWIG_0, _swig_p) - return -} - -func NewVectorDbl__SWIG_0() (_swig_ret VectorDbl) { - return _swig_wrap_new_vectorDbl__SWIG_0() -} - -var _wrap_new_vectorDbl__SWIG_1 unsafe.Pointer - -func _swig_wrap_new_vectorDbl__SWIG_1(base int64) (_ SwigcptrVectorDbl) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_vectorDbl__SWIG_1, _swig_p) - return -} - -func NewVectorDbl__SWIG_1(arg1 int64) (_swig_ret VectorDbl) { - return _swig_wrap_new_vectorDbl__SWIG_1(arg1) -} - -func NewVectorDbl(a ...interface{}) VectorDbl { - argc := len(a) - if argc == 0 { - return NewVectorDbl__SWIG_0() - } - if argc == 1 { - return NewVectorDbl__SWIG_1(a[0].(int64)) - } - panic("No match for overloaded function call") -} - -var _wrap_vectorDbl_size unsafe.Pointer - -func _swig_wrap_vectorDbl_size(base SwigcptrVectorDbl) (_ int64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_vectorDbl_size, _swig_p) - return -} - -func (arg1 SwigcptrVectorDbl) Size() (_swig_ret int64) { - return _swig_wrap_vectorDbl_size(arg1) -} - -var _wrap_vectorDbl_capacity unsafe.Pointer - -func _swig_wrap_vectorDbl_capacity(base SwigcptrVectorDbl) (_ int64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_vectorDbl_capacity, _swig_p) - return -} - -func (arg1 SwigcptrVectorDbl) Capacity() (_swig_ret int64) { - return _swig_wrap_vectorDbl_capacity(arg1) -} - -var _wrap_vectorDbl_reserve unsafe.Pointer - -func _swig_wrap_vectorDbl_reserve(base SwigcptrVectorDbl, _ int64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_vectorDbl_reserve, _swig_p) - return -} - -func (arg1 SwigcptrVectorDbl) Reserve(arg2 int64) { - _swig_wrap_vectorDbl_reserve(arg1, arg2) -} - -var _wrap_vectorDbl_isEmpty unsafe.Pointer - -func _swig_wrap_vectorDbl_isEmpty(base SwigcptrVectorDbl) (_ bool) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_vectorDbl_isEmpty, _swig_p) - return -} - -func (arg1 SwigcptrVectorDbl) IsEmpty() (_swig_ret bool) { - return _swig_wrap_vectorDbl_isEmpty(arg1) -} - -var _wrap_vectorDbl_clear unsafe.Pointer - -func _swig_wrap_vectorDbl_clear(base SwigcptrVectorDbl) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_vectorDbl_clear, _swig_p) - return -} - -func (arg1 SwigcptrVectorDbl) Clear() { - _swig_wrap_vectorDbl_clear(arg1) -} - -var _wrap_vectorDbl_add unsafe.Pointer - -func _swig_wrap_vectorDbl_add(base SwigcptrVectorDbl, _ float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_vectorDbl_add, _swig_p) - return -} - -func (arg1 SwigcptrVectorDbl) Add(arg2 float64) { - _swig_wrap_vectorDbl_add(arg1, arg2) -} - -var _wrap_vectorDbl_get unsafe.Pointer - -func _swig_wrap_vectorDbl_get(base SwigcptrVectorDbl, _ int) (_ float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_vectorDbl_get, _swig_p) - return -} - -func (arg1 SwigcptrVectorDbl) Get(arg2 int) (_swig_ret float64) { - return _swig_wrap_vectorDbl_get(arg1, arg2) -} - -var _wrap_vectorDbl_set unsafe.Pointer - -func _swig_wrap_vectorDbl_set(base SwigcptrVectorDbl, _ int, _ float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_vectorDbl_set, _swig_p) - return -} - -func (arg1 SwigcptrVectorDbl) Set(arg2 int, arg3 float64) { - _swig_wrap_vectorDbl_set(arg1, arg2, arg3) -} - -var _wrap_delete_vectorDbl unsafe.Pointer - -func _swig_wrap_delete_vectorDbl(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_vectorDbl, _swig_p) - return -} - -func DeleteVectorDbl(arg1 VectorDbl) { - _swig_wrap_delete_vectorDbl(arg1.Swigcptr()) -} - -type VectorDbl interface { - Swigcptr() uintptr - SwigIsVectorDbl() - Size() (_swig_ret int64) - Capacity() (_swig_ret int64) - Reserve(arg2 int64) - IsEmpty() (_swig_ret bool) - Clear() - Add(arg2 float64) - Get(arg2 int) (_swig_ret float64) - Set(arg2 int, arg3 float64) -} - -type SwigcptrTest uintptr - -func (p SwigcptrTest) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrTest) SwigIsTest() { -} - -var _wrap_Test_v_set unsafe.Pointer - -func _swig_wrap_Test_v_set(base SwigcptrTest, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Test_v_set, _swig_p) - return -} - -func (arg1 SwigcptrTest) SetV(arg2 VectorDbl) { - _swig_wrap_Test_v_set(arg1, arg2.Swigcptr()) -} - -var _wrap_Test_v_get unsafe.Pointer - -func _swig_wrap_Test_v_get(base SwigcptrTest) (_ SwigcptrVectorDbl) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Test_v_get, _swig_p) - return -} - -func (arg1 SwigcptrTest) GetV() (_swig_ret VectorDbl) { - return _swig_wrap_Test_v_get(arg1) -} - -var _wrap_Test_x_set unsafe.Pointer - -func _swig_wrap_Test_x_set(base SwigcptrTest, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Test_x_set, _swig_p) - return -} - -func (arg1 SwigcptrTest) SetX(arg2 int) { - _swig_wrap_Test_x_set(arg1, arg2) -} - -var _wrap_Test_x_get unsafe.Pointer - -func _swig_wrap_Test_x_get(base SwigcptrTest) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Test_x_get, _swig_p) - return -} - -func (arg1 SwigcptrTest) GetX() (_swig_ret int) { - return _swig_wrap_Test_x_get(arg1) -} - -var _wrap_new_Test unsafe.Pointer - -func _swig_wrap_new_Test() (base SwigcptrTest) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Test, _swig_p) - return -} - -func NewTest() (_swig_ret Test) { - return _swig_wrap_new_Test() -} - -var _wrap_Test_f unsafe.Pointer - -func _swig_wrap_Test_f(base SwigcptrTest, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Test_f, _swig_p) - return -} - -func (arg1 SwigcptrTest) F(arg2 int) { - _swig_wrap_Test_f(arg1, arg2) -} - -var _wrap_delete_Test unsafe.Pointer - -func _swig_wrap_delete_Test(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Test, _swig_p) - return -} - -func DeleteTest(arg1 Test) { - _swig_wrap_delete_Test(arg1.Swigcptr()) -} - -type Test interface { - Swigcptr() uintptr - SwigIsTest() - SetV(arg2 VectorDbl) - GetV() (_swig_ret VectorDbl) - SetX(arg2 int) - GetX() (_swig_ret int) - F(arg2 int) -} - -type SwigcptrS uintptr - -func (p SwigcptrS) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrS) SwigIsS() { -} - -var _wrap_S_x_set unsafe.Pointer - -func _swig_wrap_S_x_set(base SwigcptrS, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_S_x_set, _swig_p) - return -} - -func (arg1 SwigcptrS) SetX(arg2 int) { - _swig_wrap_S_x_set(arg1, arg2) -} - -var _wrap_S_x_get unsafe.Pointer - -func _swig_wrap_S_x_get(base SwigcptrS) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_S_x_get, _swig_p) - return -} - -func (arg1 SwigcptrS) GetX() (_swig_ret int) { - return _swig_wrap_S_x_get(arg1) -} - -var _wrap_new_S unsafe.Pointer - -func _swig_wrap_new_S() (base SwigcptrS) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_S, _swig_p) - return -} - -func NewS() (_swig_ret S) { - return _swig_wrap_new_S() -} - -var _wrap_delete_S unsafe.Pointer - -func _swig_wrap_delete_S(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_S, _swig_p) - return -} - -func DeleteS(arg1 S) { - _swig_wrap_delete_S(arg1.Swigcptr()) -} - -type S interface { - Swigcptr() uintptr - SwigIsS() - SetX(arg2 int) - GetX() (_swig_ret int) -} - -type SwigcptrT uintptr - -func (p SwigcptrT) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrT) SwigIsT() { -} - -var _wrap_T_start_t_set unsafe.Pointer - -func _swig_wrap_T_start_t_set(base SwigcptrT, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_T_start_t_set, _swig_p) - return -} - -func (arg1 SwigcptrT) SetStart_t(arg2 S) { - _swig_wrap_T_start_t_set(arg1, arg2.Swigcptr()) -} - -var _wrap_T_start_t_get unsafe.Pointer - -func _swig_wrap_T_start_t_get(base SwigcptrT) (_ SwigcptrS) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_T_start_t_get, _swig_p) - return -} - -func (arg1 SwigcptrT) GetStart_t() (_swig_ret S) { - return _swig_wrap_T_start_t_get(arg1) -} - -var _wrap_T_length_set unsafe.Pointer - -func _swig_wrap_T_length_set(base SwigcptrT, _ uint) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_T_length_set, _swig_p) - return -} - -func (arg1 SwigcptrT) SetLength(arg2 uint) { - _swig_wrap_T_length_set(arg1, arg2) -} - -var _wrap_T_length_get unsafe.Pointer - -func _swig_wrap_T_length_get(base SwigcptrT) (_ uint) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_T_length_get, _swig_p) - return -} - -func (arg1 SwigcptrT) GetLength() (_swig_ret uint) { - return _swig_wrap_T_length_get(arg1) -} - -var _wrap_new_T unsafe.Pointer - -func _swig_wrap_new_T() (base SwigcptrT) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_T, _swig_p) - return -} - -func NewT() (_swig_ret T) { - return _swig_wrap_new_T() -} - -var _wrap_delete_T unsafe.Pointer - -func _swig_wrap_delete_T(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_T, _swig_p) - return -} - -func DeleteT(arg1 T) { - _swig_wrap_delete_T(arg1.Swigcptr()) -} - -type T interface { - Swigcptr() uintptr - SwigIsT() - SetStart_t(arg2 S) - GetStart_t() (_swig_ret S) - SetLength(arg2 uint) - GetLength() (_swig_ret uint) -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/li_stdint.go b/Examples/test-suite/go/li_stdint.go deleted file mode 100644 index cd5d0b0ab..000000000 --- a/Examples/test-suite/go/li_stdint.go +++ /dev/null @@ -1,943 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../li_stdint.i - -package li_stdint - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrStdInts uintptr - -func (p SwigcptrStdInts) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrStdInts) SwigIsStdInts() { -} - -var _wrap_StdInts_int8_member_set unsafe.Pointer - -func _swig_wrap_StdInts_int8_member_set(base SwigcptrStdInts, _ int8) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_StdInts_int8_member_set, _swig_p) - return -} - -func (arg1 SwigcptrStdInts) SetInt8_member(arg2 int8) { - _swig_wrap_StdInts_int8_member_set(arg1, arg2) -} - -var _wrap_StdInts_int8_member_get unsafe.Pointer - -func _swig_wrap_StdInts_int8_member_get(base SwigcptrStdInts) (_ int8) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_StdInts_int8_member_get, _swig_p) - return -} - -func (arg1 SwigcptrStdInts) GetInt8_member() (_swig_ret int8) { - return _swig_wrap_StdInts_int8_member_get(arg1) -} - -var _wrap_StdInts_int16_member_set unsafe.Pointer - -func _swig_wrap_StdInts_int16_member_set(base SwigcptrStdInts, _ int16) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_StdInts_int16_member_set, _swig_p) - return -} - -func (arg1 SwigcptrStdInts) SetInt16_member(arg2 int16) { - _swig_wrap_StdInts_int16_member_set(arg1, arg2) -} - -var _wrap_StdInts_int16_member_get unsafe.Pointer - -func _swig_wrap_StdInts_int16_member_get(base SwigcptrStdInts) (_ int16) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_StdInts_int16_member_get, _swig_p) - return -} - -func (arg1 SwigcptrStdInts) GetInt16_member() (_swig_ret int16) { - return _swig_wrap_StdInts_int16_member_get(arg1) -} - -var _wrap_StdInts_int32_member_set unsafe.Pointer - -func _swig_wrap_StdInts_int32_member_set(base SwigcptrStdInts, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_StdInts_int32_member_set, _swig_p) - return -} - -func (arg1 SwigcptrStdInts) SetInt32_member(arg2 int) { - _swig_wrap_StdInts_int32_member_set(arg1, arg2) -} - -var _wrap_StdInts_int32_member_get unsafe.Pointer - -func _swig_wrap_StdInts_int32_member_get(base SwigcptrStdInts) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_StdInts_int32_member_get, _swig_p) - return -} - -func (arg1 SwigcptrStdInts) GetInt32_member() (_swig_ret int) { - return _swig_wrap_StdInts_int32_member_get(arg1) -} - -var _wrap_StdInts_int64_member_set unsafe.Pointer - -func _swig_wrap_StdInts_int64_member_set(base SwigcptrStdInts, _ int64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_StdInts_int64_member_set, _swig_p) - return -} - -func (arg1 SwigcptrStdInts) SetInt64_member(arg2 int64) { - _swig_wrap_StdInts_int64_member_set(arg1, arg2) -} - -var _wrap_StdInts_int64_member_get unsafe.Pointer - -func _swig_wrap_StdInts_int64_member_get(base SwigcptrStdInts) (_ int64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_StdInts_int64_member_get, _swig_p) - return -} - -func (arg1 SwigcptrStdInts) GetInt64_member() (_swig_ret int64) { - return _swig_wrap_StdInts_int64_member_get(arg1) -} - -var _wrap_StdInts_uint8_member_set unsafe.Pointer - -func _swig_wrap_StdInts_uint8_member_set(base SwigcptrStdInts, _ byte) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_StdInts_uint8_member_set, _swig_p) - return -} - -func (arg1 SwigcptrStdInts) SetUint8_member(arg2 byte) { - _swig_wrap_StdInts_uint8_member_set(arg1, arg2) -} - -var _wrap_StdInts_uint8_member_get unsafe.Pointer - -func _swig_wrap_StdInts_uint8_member_get(base SwigcptrStdInts) (_ byte) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_StdInts_uint8_member_get, _swig_p) - return -} - -func (arg1 SwigcptrStdInts) GetUint8_member() (_swig_ret byte) { - return _swig_wrap_StdInts_uint8_member_get(arg1) -} - -var _wrap_StdInts_uint16_member_set unsafe.Pointer - -func _swig_wrap_StdInts_uint16_member_set(base SwigcptrStdInts, _ uint16) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_StdInts_uint16_member_set, _swig_p) - return -} - -func (arg1 SwigcptrStdInts) SetUint16_member(arg2 uint16) { - _swig_wrap_StdInts_uint16_member_set(arg1, arg2) -} - -var _wrap_StdInts_uint16_member_get unsafe.Pointer - -func _swig_wrap_StdInts_uint16_member_get(base SwigcptrStdInts) (_ uint16) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_StdInts_uint16_member_get, _swig_p) - return -} - -func (arg1 SwigcptrStdInts) GetUint16_member() (_swig_ret uint16) { - return _swig_wrap_StdInts_uint16_member_get(arg1) -} - -var _wrap_StdInts_uint32_member_set unsafe.Pointer - -func _swig_wrap_StdInts_uint32_member_set(base SwigcptrStdInts, _ uint) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_StdInts_uint32_member_set, _swig_p) - return -} - -func (arg1 SwigcptrStdInts) SetUint32_member(arg2 uint) { - _swig_wrap_StdInts_uint32_member_set(arg1, arg2) -} - -var _wrap_StdInts_uint32_member_get unsafe.Pointer - -func _swig_wrap_StdInts_uint32_member_get(base SwigcptrStdInts) (_ uint) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_StdInts_uint32_member_get, _swig_p) - return -} - -func (arg1 SwigcptrStdInts) GetUint32_member() (_swig_ret uint) { - return _swig_wrap_StdInts_uint32_member_get(arg1) -} - -var _wrap_StdInts_uint64_member_set unsafe.Pointer - -func _swig_wrap_StdInts_uint64_member_set(base SwigcptrStdInts, _ uint64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_StdInts_uint64_member_set, _swig_p) - return -} - -func (arg1 SwigcptrStdInts) SetUint64_member(arg2 uint64) { - _swig_wrap_StdInts_uint64_member_set(arg1, arg2) -} - -var _wrap_StdInts_uint64_member_get unsafe.Pointer - -func _swig_wrap_StdInts_uint64_member_get(base SwigcptrStdInts) (_ uint64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_StdInts_uint64_member_get, _swig_p) - return -} - -func (arg1 SwigcptrStdInts) GetUint64_member() (_swig_ret uint64) { - return _swig_wrap_StdInts_uint64_member_get(arg1) -} - -var _wrap_new_StdInts unsafe.Pointer - -func _swig_wrap_new_StdInts() (base SwigcptrStdInts) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_StdInts, _swig_p) - return -} - -func NewStdInts() (_swig_ret StdInts) { - return _swig_wrap_new_StdInts() -} - -var _wrap_delete_StdInts unsafe.Pointer - -func _swig_wrap_delete_StdInts(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_StdInts, _swig_p) - return -} - -func DeleteStdInts(arg1 StdInts) { - _swig_wrap_delete_StdInts(arg1.Swigcptr()) -} - -type StdInts interface { - Swigcptr() uintptr - SwigIsStdInts() - SetInt8_member(arg2 int8) - GetInt8_member() (_swig_ret int8) - SetInt16_member(arg2 int16) - GetInt16_member() (_swig_ret int16) - SetInt32_member(arg2 int) - GetInt32_member() (_swig_ret int) - SetInt64_member(arg2 int64) - GetInt64_member() (_swig_ret int64) - SetUint8_member(arg2 byte) - GetUint8_member() (_swig_ret byte) - SetUint16_member(arg2 uint16) - GetUint16_member() (_swig_ret uint16) - SetUint32_member(arg2 uint) - GetUint32_member() (_swig_ret uint) - SetUint64_member(arg2 uint64) - GetUint64_member() (_swig_ret uint64) -} - -var _wrap_int8_td unsafe.Pointer - -func Int8_td(arg1 int8) (_swig_ret int8) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_int8_td, _swig_p) - return -} -var _wrap_int16_td unsafe.Pointer - -func Int16_td(arg1 int16) (_swig_ret int16) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_int16_td, _swig_p) - return -} -var _wrap_int32_td unsafe.Pointer - -func Int32_td(arg1 int) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_int32_td, _swig_p) - return -} -var _wrap_int64_td unsafe.Pointer - -func Int64_td(arg1 int64) (_swig_ret int64) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_int64_td, _swig_p) - return -} -var _wrap_uint8_td unsafe.Pointer - -func Uint8_td(arg1 int8) (_swig_ret byte) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_uint8_td, _swig_p) - return -} -var _wrap_uint16_td unsafe.Pointer - -func Uint16_td(arg1 int16) (_swig_ret uint16) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_uint16_td, _swig_p) - return -} -var _wrap_uint32_td unsafe.Pointer - -func Uint32_td(arg1 int) (_swig_ret uint) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_uint32_td, _swig_p) - return -} -var _wrap_uint64_td unsafe.Pointer - -func Uint64_td(arg1 int64) (_swig_ret uint64) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_uint64_td, _swig_p) - return -} -type SwigcptrStdIntFasts uintptr - -func (p SwigcptrStdIntFasts) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrStdIntFasts) SwigIsStdIntFasts() { -} - -var _wrap_StdIntFasts_int_fast8_member_set unsafe.Pointer - -func _swig_wrap_StdIntFasts_int_fast8_member_set(base SwigcptrStdIntFasts, _ int8) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_StdIntFasts_int_fast8_member_set, _swig_p) - return -} - -func (arg1 SwigcptrStdIntFasts) SetInt_fast8_member(arg2 int8) { - _swig_wrap_StdIntFasts_int_fast8_member_set(arg1, arg2) -} - -var _wrap_StdIntFasts_int_fast8_member_get unsafe.Pointer - -func _swig_wrap_StdIntFasts_int_fast8_member_get(base SwigcptrStdIntFasts) (_ int8) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_StdIntFasts_int_fast8_member_get, _swig_p) - return -} - -func (arg1 SwigcptrStdIntFasts) GetInt_fast8_member() (_swig_ret int8) { - return _swig_wrap_StdIntFasts_int_fast8_member_get(arg1) -} - -var _wrap_StdIntFasts_int_fast16_member_set unsafe.Pointer - -func _swig_wrap_StdIntFasts_int_fast16_member_set(base SwigcptrStdIntFasts, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_StdIntFasts_int_fast16_member_set, _swig_p) - return -} - -func (arg1 SwigcptrStdIntFasts) SetInt_fast16_member(arg2 int) { - _swig_wrap_StdIntFasts_int_fast16_member_set(arg1, arg2) -} - -var _wrap_StdIntFasts_int_fast16_member_get unsafe.Pointer - -func _swig_wrap_StdIntFasts_int_fast16_member_get(base SwigcptrStdIntFasts) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_StdIntFasts_int_fast16_member_get, _swig_p) - return -} - -func (arg1 SwigcptrStdIntFasts) GetInt_fast16_member() (_swig_ret int) { - return _swig_wrap_StdIntFasts_int_fast16_member_get(arg1) -} - -var _wrap_StdIntFasts_int_fast32_member_set unsafe.Pointer - -func _swig_wrap_StdIntFasts_int_fast32_member_set(base SwigcptrStdIntFasts, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_StdIntFasts_int_fast32_member_set, _swig_p) - return -} - -func (arg1 SwigcptrStdIntFasts) SetInt_fast32_member(arg2 int) { - _swig_wrap_StdIntFasts_int_fast32_member_set(arg1, arg2) -} - -var _wrap_StdIntFasts_int_fast32_member_get unsafe.Pointer - -func _swig_wrap_StdIntFasts_int_fast32_member_get(base SwigcptrStdIntFasts) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_StdIntFasts_int_fast32_member_get, _swig_p) - return -} - -func (arg1 SwigcptrStdIntFasts) GetInt_fast32_member() (_swig_ret int) { - return _swig_wrap_StdIntFasts_int_fast32_member_get(arg1) -} - -var _wrap_StdIntFasts_int_fast64_member_set unsafe.Pointer - -func _swig_wrap_StdIntFasts_int_fast64_member_set(base SwigcptrStdIntFasts, _ int64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_StdIntFasts_int_fast64_member_set, _swig_p) - return -} - -func (arg1 SwigcptrStdIntFasts) SetInt_fast64_member(arg2 int64) { - _swig_wrap_StdIntFasts_int_fast64_member_set(arg1, arg2) -} - -var _wrap_StdIntFasts_int_fast64_member_get unsafe.Pointer - -func _swig_wrap_StdIntFasts_int_fast64_member_get(base SwigcptrStdIntFasts) (_ int64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_StdIntFasts_int_fast64_member_get, _swig_p) - return -} - -func (arg1 SwigcptrStdIntFasts) GetInt_fast64_member() (_swig_ret int64) { - return _swig_wrap_StdIntFasts_int_fast64_member_get(arg1) -} - -var _wrap_StdIntFasts_uint_fast8_member_set unsafe.Pointer - -func _swig_wrap_StdIntFasts_uint_fast8_member_set(base SwigcptrStdIntFasts, _ byte) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_StdIntFasts_uint_fast8_member_set, _swig_p) - return -} - -func (arg1 SwigcptrStdIntFasts) SetUint_fast8_member(arg2 byte) { - _swig_wrap_StdIntFasts_uint_fast8_member_set(arg1, arg2) -} - -var _wrap_StdIntFasts_uint_fast8_member_get unsafe.Pointer - -func _swig_wrap_StdIntFasts_uint_fast8_member_get(base SwigcptrStdIntFasts) (_ byte) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_StdIntFasts_uint_fast8_member_get, _swig_p) - return -} - -func (arg1 SwigcptrStdIntFasts) GetUint_fast8_member() (_swig_ret byte) { - return _swig_wrap_StdIntFasts_uint_fast8_member_get(arg1) -} - -var _wrap_StdIntFasts_uint_fast16_member_set unsafe.Pointer - -func _swig_wrap_StdIntFasts_uint_fast16_member_set(base SwigcptrStdIntFasts, _ uint) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_StdIntFasts_uint_fast16_member_set, _swig_p) - return -} - -func (arg1 SwigcptrStdIntFasts) SetUint_fast16_member(arg2 uint) { - _swig_wrap_StdIntFasts_uint_fast16_member_set(arg1, arg2) -} - -var _wrap_StdIntFasts_uint_fast16_member_get unsafe.Pointer - -func _swig_wrap_StdIntFasts_uint_fast16_member_get(base SwigcptrStdIntFasts) (_ uint) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_StdIntFasts_uint_fast16_member_get, _swig_p) - return -} - -func (arg1 SwigcptrStdIntFasts) GetUint_fast16_member() (_swig_ret uint) { - return _swig_wrap_StdIntFasts_uint_fast16_member_get(arg1) -} - -var _wrap_StdIntFasts_uint_fast32_member_set unsafe.Pointer - -func _swig_wrap_StdIntFasts_uint_fast32_member_set(base SwigcptrStdIntFasts, _ uint) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_StdIntFasts_uint_fast32_member_set, _swig_p) - return -} - -func (arg1 SwigcptrStdIntFasts) SetUint_fast32_member(arg2 uint) { - _swig_wrap_StdIntFasts_uint_fast32_member_set(arg1, arg2) -} - -var _wrap_StdIntFasts_uint_fast32_member_get unsafe.Pointer - -func _swig_wrap_StdIntFasts_uint_fast32_member_get(base SwigcptrStdIntFasts) (_ uint) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_StdIntFasts_uint_fast32_member_get, _swig_p) - return -} - -func (arg1 SwigcptrStdIntFasts) GetUint_fast32_member() (_swig_ret uint) { - return _swig_wrap_StdIntFasts_uint_fast32_member_get(arg1) -} - -var _wrap_StdIntFasts_uint_fast64_member_set unsafe.Pointer - -func _swig_wrap_StdIntFasts_uint_fast64_member_set(base SwigcptrStdIntFasts, _ uint64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_StdIntFasts_uint_fast64_member_set, _swig_p) - return -} - -func (arg1 SwigcptrStdIntFasts) SetUint_fast64_member(arg2 uint64) { - _swig_wrap_StdIntFasts_uint_fast64_member_set(arg1, arg2) -} - -var _wrap_StdIntFasts_uint_fast64_member_get unsafe.Pointer - -func _swig_wrap_StdIntFasts_uint_fast64_member_get(base SwigcptrStdIntFasts) (_ uint64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_StdIntFasts_uint_fast64_member_get, _swig_p) - return -} - -func (arg1 SwigcptrStdIntFasts) GetUint_fast64_member() (_swig_ret uint64) { - return _swig_wrap_StdIntFasts_uint_fast64_member_get(arg1) -} - -var _wrap_new_StdIntFasts unsafe.Pointer - -func _swig_wrap_new_StdIntFasts() (base SwigcptrStdIntFasts) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_StdIntFasts, _swig_p) - return -} - -func NewStdIntFasts() (_swig_ret StdIntFasts) { - return _swig_wrap_new_StdIntFasts() -} - -var _wrap_delete_StdIntFasts unsafe.Pointer - -func _swig_wrap_delete_StdIntFasts(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_StdIntFasts, _swig_p) - return -} - -func DeleteStdIntFasts(arg1 StdIntFasts) { - _swig_wrap_delete_StdIntFasts(arg1.Swigcptr()) -} - -type StdIntFasts interface { - Swigcptr() uintptr - SwigIsStdIntFasts() - SetInt_fast8_member(arg2 int8) - GetInt_fast8_member() (_swig_ret int8) - SetInt_fast16_member(arg2 int) - GetInt_fast16_member() (_swig_ret int) - SetInt_fast32_member(arg2 int) - GetInt_fast32_member() (_swig_ret int) - SetInt_fast64_member(arg2 int64) - GetInt_fast64_member() (_swig_ret int64) - SetUint_fast8_member(arg2 byte) - GetUint_fast8_member() (_swig_ret byte) - SetUint_fast16_member(arg2 uint) - GetUint_fast16_member() (_swig_ret uint) - SetUint_fast32_member(arg2 uint) - GetUint_fast32_member() (_swig_ret uint) - SetUint_fast64_member(arg2 uint64) - GetUint_fast64_member() (_swig_ret uint64) -} - -var _wrap_int_fast8_td unsafe.Pointer - -func Int_fast8_td(arg1 int8) (_swig_ret int8) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_int_fast8_td, _swig_p) - return -} -var _wrap_int_fast16_td unsafe.Pointer - -func Int_fast16_td(arg1 int) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_int_fast16_td, _swig_p) - return -} -var _wrap_int_fast32_td unsafe.Pointer - -func Int_fast32_td(arg1 int) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_int_fast32_td, _swig_p) - return -} -var _wrap_int_fast64_td unsafe.Pointer - -func Int_fast64_td(arg1 int64) (_swig_ret int64) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_int_fast64_td, _swig_p) - return -} -var _wrap_uint_fast8_td unsafe.Pointer - -func Uint_fast8_td(arg1 int8) (_swig_ret byte) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_uint_fast8_td, _swig_p) - return -} -var _wrap_uint_fast16_td unsafe.Pointer - -func Uint_fast16_td(arg1 int) (_swig_ret uint) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_uint_fast16_td, _swig_p) - return -} -var _wrap_uint_fast32_td unsafe.Pointer - -func Uint_fast32_td(arg1 int) (_swig_ret uint) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_uint_fast32_td, _swig_p) - return -} -var _wrap_uint_fast64_td unsafe.Pointer - -func Uint_fast64_td(arg1 int64) (_swig_ret uint64) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_uint_fast64_td, _swig_p) - return -} -type SwigcptrStdIntLeasts uintptr - -func (p SwigcptrStdIntLeasts) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrStdIntLeasts) SwigIsStdIntLeasts() { -} - -var _wrap_StdIntLeasts_int_least8_member_set unsafe.Pointer - -func _swig_wrap_StdIntLeasts_int_least8_member_set(base SwigcptrStdIntLeasts, _ int8) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_StdIntLeasts_int_least8_member_set, _swig_p) - return -} - -func (arg1 SwigcptrStdIntLeasts) SetInt_least8_member(arg2 int8) { - _swig_wrap_StdIntLeasts_int_least8_member_set(arg1, arg2) -} - -var _wrap_StdIntLeasts_int_least8_member_get unsafe.Pointer - -func _swig_wrap_StdIntLeasts_int_least8_member_get(base SwigcptrStdIntLeasts) (_ int8) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_StdIntLeasts_int_least8_member_get, _swig_p) - return -} - -func (arg1 SwigcptrStdIntLeasts) GetInt_least8_member() (_swig_ret int8) { - return _swig_wrap_StdIntLeasts_int_least8_member_get(arg1) -} - -var _wrap_StdIntLeasts_int_least16_member_set unsafe.Pointer - -func _swig_wrap_StdIntLeasts_int_least16_member_set(base SwigcptrStdIntLeasts, _ int16) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_StdIntLeasts_int_least16_member_set, _swig_p) - return -} - -func (arg1 SwigcptrStdIntLeasts) SetInt_least16_member(arg2 int16) { - _swig_wrap_StdIntLeasts_int_least16_member_set(arg1, arg2) -} - -var _wrap_StdIntLeasts_int_least16_member_get unsafe.Pointer - -func _swig_wrap_StdIntLeasts_int_least16_member_get(base SwigcptrStdIntLeasts) (_ int16) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_StdIntLeasts_int_least16_member_get, _swig_p) - return -} - -func (arg1 SwigcptrStdIntLeasts) GetInt_least16_member() (_swig_ret int16) { - return _swig_wrap_StdIntLeasts_int_least16_member_get(arg1) -} - -var _wrap_StdIntLeasts_int_least32_member_set unsafe.Pointer - -func _swig_wrap_StdIntLeasts_int_least32_member_set(base SwigcptrStdIntLeasts, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_StdIntLeasts_int_least32_member_set, _swig_p) - return -} - -func (arg1 SwigcptrStdIntLeasts) SetInt_least32_member(arg2 int) { - _swig_wrap_StdIntLeasts_int_least32_member_set(arg1, arg2) -} - -var _wrap_StdIntLeasts_int_least32_member_get unsafe.Pointer - -func _swig_wrap_StdIntLeasts_int_least32_member_get(base SwigcptrStdIntLeasts) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_StdIntLeasts_int_least32_member_get, _swig_p) - return -} - -func (arg1 SwigcptrStdIntLeasts) GetInt_least32_member() (_swig_ret int) { - return _swig_wrap_StdIntLeasts_int_least32_member_get(arg1) -} - -var _wrap_StdIntLeasts_int_least64_member_set unsafe.Pointer - -func _swig_wrap_StdIntLeasts_int_least64_member_set(base SwigcptrStdIntLeasts, _ int64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_StdIntLeasts_int_least64_member_set, _swig_p) - return -} - -func (arg1 SwigcptrStdIntLeasts) SetInt_least64_member(arg2 int64) { - _swig_wrap_StdIntLeasts_int_least64_member_set(arg1, arg2) -} - -var _wrap_StdIntLeasts_int_least64_member_get unsafe.Pointer - -func _swig_wrap_StdIntLeasts_int_least64_member_get(base SwigcptrStdIntLeasts) (_ int64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_StdIntLeasts_int_least64_member_get, _swig_p) - return -} - -func (arg1 SwigcptrStdIntLeasts) GetInt_least64_member() (_swig_ret int64) { - return _swig_wrap_StdIntLeasts_int_least64_member_get(arg1) -} - -var _wrap_StdIntLeasts_uint_least8_member_set unsafe.Pointer - -func _swig_wrap_StdIntLeasts_uint_least8_member_set(base SwigcptrStdIntLeasts, _ byte) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_StdIntLeasts_uint_least8_member_set, _swig_p) - return -} - -func (arg1 SwigcptrStdIntLeasts) SetUint_least8_member(arg2 byte) { - _swig_wrap_StdIntLeasts_uint_least8_member_set(arg1, arg2) -} - -var _wrap_StdIntLeasts_uint_least8_member_get unsafe.Pointer - -func _swig_wrap_StdIntLeasts_uint_least8_member_get(base SwigcptrStdIntLeasts) (_ byte) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_StdIntLeasts_uint_least8_member_get, _swig_p) - return -} - -func (arg1 SwigcptrStdIntLeasts) GetUint_least8_member() (_swig_ret byte) { - return _swig_wrap_StdIntLeasts_uint_least8_member_get(arg1) -} - -var _wrap_StdIntLeasts_uint_least16_member_set unsafe.Pointer - -func _swig_wrap_StdIntLeasts_uint_least16_member_set(base SwigcptrStdIntLeasts, _ uint16) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_StdIntLeasts_uint_least16_member_set, _swig_p) - return -} - -func (arg1 SwigcptrStdIntLeasts) SetUint_least16_member(arg2 uint16) { - _swig_wrap_StdIntLeasts_uint_least16_member_set(arg1, arg2) -} - -var _wrap_StdIntLeasts_uint_least16_member_get unsafe.Pointer - -func _swig_wrap_StdIntLeasts_uint_least16_member_get(base SwigcptrStdIntLeasts) (_ uint16) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_StdIntLeasts_uint_least16_member_get, _swig_p) - return -} - -func (arg1 SwigcptrStdIntLeasts) GetUint_least16_member() (_swig_ret uint16) { - return _swig_wrap_StdIntLeasts_uint_least16_member_get(arg1) -} - -var _wrap_StdIntLeasts_uint_least32_member_set unsafe.Pointer - -func _swig_wrap_StdIntLeasts_uint_least32_member_set(base SwigcptrStdIntLeasts, _ uint) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_StdIntLeasts_uint_least32_member_set, _swig_p) - return -} - -func (arg1 SwigcptrStdIntLeasts) SetUint_least32_member(arg2 uint) { - _swig_wrap_StdIntLeasts_uint_least32_member_set(arg1, arg2) -} - -var _wrap_StdIntLeasts_uint_least32_member_get unsafe.Pointer - -func _swig_wrap_StdIntLeasts_uint_least32_member_get(base SwigcptrStdIntLeasts) (_ uint) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_StdIntLeasts_uint_least32_member_get, _swig_p) - return -} - -func (arg1 SwigcptrStdIntLeasts) GetUint_least32_member() (_swig_ret uint) { - return _swig_wrap_StdIntLeasts_uint_least32_member_get(arg1) -} - -var _wrap_StdIntLeasts_uint_least64_member_set unsafe.Pointer - -func _swig_wrap_StdIntLeasts_uint_least64_member_set(base SwigcptrStdIntLeasts, _ uint64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_StdIntLeasts_uint_least64_member_set, _swig_p) - return -} - -func (arg1 SwigcptrStdIntLeasts) SetUint_least64_member(arg2 uint64) { - _swig_wrap_StdIntLeasts_uint_least64_member_set(arg1, arg2) -} - -var _wrap_StdIntLeasts_uint_least64_member_get unsafe.Pointer - -func _swig_wrap_StdIntLeasts_uint_least64_member_get(base SwigcptrStdIntLeasts) (_ uint64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_StdIntLeasts_uint_least64_member_get, _swig_p) - return -} - -func (arg1 SwigcptrStdIntLeasts) GetUint_least64_member() (_swig_ret uint64) { - return _swig_wrap_StdIntLeasts_uint_least64_member_get(arg1) -} - -var _wrap_new_StdIntLeasts unsafe.Pointer - -func _swig_wrap_new_StdIntLeasts() (base SwigcptrStdIntLeasts) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_StdIntLeasts, _swig_p) - return -} - -func NewStdIntLeasts() (_swig_ret StdIntLeasts) { - return _swig_wrap_new_StdIntLeasts() -} - -var _wrap_delete_StdIntLeasts unsafe.Pointer - -func _swig_wrap_delete_StdIntLeasts(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_StdIntLeasts, _swig_p) - return -} - -func DeleteStdIntLeasts(arg1 StdIntLeasts) { - _swig_wrap_delete_StdIntLeasts(arg1.Swigcptr()) -} - -type StdIntLeasts interface { - Swigcptr() uintptr - SwigIsStdIntLeasts() - SetInt_least8_member(arg2 int8) - GetInt_least8_member() (_swig_ret int8) - SetInt_least16_member(arg2 int16) - GetInt_least16_member() (_swig_ret int16) - SetInt_least32_member(arg2 int) - GetInt_least32_member() (_swig_ret int) - SetInt_least64_member(arg2 int64) - GetInt_least64_member() (_swig_ret int64) - SetUint_least8_member(arg2 byte) - GetUint_least8_member() (_swig_ret byte) - SetUint_least16_member(arg2 uint16) - GetUint_least16_member() (_swig_ret uint16) - SetUint_least32_member(arg2 uint) - GetUint_least32_member() (_swig_ret uint) - SetUint_least64_member(arg2 uint64) - GetUint_least64_member() (_swig_ret uint64) -} - -var _wrap_int_least8_td unsafe.Pointer - -func Int_least8_td(arg1 int8) (_swig_ret int8) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_int_least8_td, _swig_p) - return -} -var _wrap_int_least16_td unsafe.Pointer - -func Int_least16_td(arg1 int16) (_swig_ret int16) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_int_least16_td, _swig_p) - return -} -var _wrap_int_least32_td unsafe.Pointer - -func Int_least32_td(arg1 int) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_int_least32_td, _swig_p) - return -} -var _wrap_int_least64_td unsafe.Pointer - -func Int_least64_td(arg1 int64) (_swig_ret int64) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_int_least64_td, _swig_p) - return -} -var _wrap_uint_least8_td unsafe.Pointer - -func Uint_least8_td(arg1 int8) (_swig_ret byte) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_uint_least8_td, _swig_p) - return -} -var _wrap_uint_least16_td unsafe.Pointer - -func Uint_least16_td(arg1 int16) (_swig_ret uint16) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_uint_least16_td, _swig_p) - return -} -var _wrap_uint_least32_td unsafe.Pointer - -func Uint_least32_td(arg1 int) (_swig_ret uint) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_uint_least32_td, _swig_p) - return -} -var _wrap_uint_least64_td unsafe.Pointer - -func Uint_least64_td(arg1 int64) (_swig_ret uint64) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_uint_least64_td, _swig_p) - return -} - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/li_swigtype_inout.go b/Examples/test-suite/go/li_swigtype_inout.go deleted file mode 100644 index 82019831b..000000000 --- a/Examples/test-suite/go/li_swigtype_inout.go +++ /dev/null @@ -1,218 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../li_swigtype_inout.i - -package li_swigtype_inout - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrXXX uintptr - -func (p SwigcptrXXX) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrXXX) SwigIsXXX() { -} - -var _wrap_new_XXX__SWIG_0 unsafe.Pointer - -func _swig_wrap_new_XXX__SWIG_0(base int) (_ SwigcptrXXX) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_XXX__SWIG_0, _swig_p) - return -} - -func NewXXX__SWIG_0(arg1 int) (_swig_ret XXX) { - return _swig_wrap_new_XXX__SWIG_0(arg1) -} - -var _wrap_new_XXX__SWIG_1 unsafe.Pointer - -func _swig_wrap_new_XXX__SWIG_1(base uintptr) (_ SwigcptrXXX) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_XXX__SWIG_1, _swig_p) - return -} - -func NewXXX__SWIG_1(arg1 XXX) (_swig_ret XXX) { - return _swig_wrap_new_XXX__SWIG_1(arg1.Swigcptr()) -} - -func NewXXX(a ...interface{}) XXX { - argc := len(a) - if argc == 1 { - if _, ok := a[0].(XXX); !ok { - goto check_1 - } - return NewXXX__SWIG_1(a[0].(XXX)) - } -check_1: - if argc == 1 { - return NewXXX__SWIG_0(a[0].(int)) - } - panic("No match for overloaded function call") -} - -var _wrap_delete_XXX unsafe.Pointer - -func _swig_wrap_delete_XXX(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_XXX, _swig_p) - return -} - -func DeleteXXX(arg1 XXX) { - _swig_wrap_delete_XXX(arg1.Swigcptr()) -} - -var _wrap_XXX_showInfo unsafe.Pointer - -func _swig_wrap_XXX_showInfo(base SwigcptrXXX) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_XXX_showInfo, _swig_p) - return -} - -func (arg1 SwigcptrXXX) ShowInfo() { - _swig_wrap_XXX_showInfo(arg1) -} - -var _wrap_XXX_value_set unsafe.Pointer - -func _swig_wrap_XXX_value_set(base SwigcptrXXX, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_XXX_value_set, _swig_p) - return -} - -func (arg1 SwigcptrXXX) SetValue(arg2 int) { - _swig_wrap_XXX_value_set(arg1, arg2) -} - -var _wrap_XXX_value_get unsafe.Pointer - -func _swig_wrap_XXX_value_get(base SwigcptrXXX) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_XXX_value_get, _swig_p) - return -} - -func (arg1 SwigcptrXXX) GetValue() (_swig_ret int) { - return _swig_wrap_XXX_value_get(arg1) -} - -var _wrap_XXX_debug_XXX unsafe.Pointer - -func _swig_getXXX_XXX_debug_XXX() (_swig_ret bool) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_XXX_debug_XXX, _swig_p) - return -} -var XXXDebug bool = _swig_getXXX_XXX_debug_XXX() -var _wrap_XXX_count_set unsafe.Pointer - -func _swig_wrap_XXX_count_set(base int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_XXX_count_set, _swig_p) - return -} - -func SetXXXCount(arg1 int) { - _swig_wrap_XXX_count_set(arg1) -} - -var _wrap_XXX_count_get unsafe.Pointer - -func GetXXXCount() (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_XXX_count_get, _swig_p) - return -} -type XXX interface { - Swigcptr() uintptr - SwigIsXXX() - ShowInfo() - SetValue(arg2 int) - GetValue() (_swig_ret int) -} - -var _wrap_ptr_ref_out unsafe.Pointer - -func _swig_wrap_ptr_ref_out(base uintptr, _ uintptr, _ uintptr, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_ptr_ref_out, _swig_p) - return -} - -func Ptr_ref_out(arg1 XXX, arg2 XXX, arg3 XXX, arg4 XXX) { - _swig_wrap_ptr_ref_out(arg1.Swigcptr(), arg2.Swigcptr(), arg3.Swigcptr(), arg4.Swigcptr()) -} - -type SwigcptrConstructorTest uintptr - -func (p SwigcptrConstructorTest) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrConstructorTest) SwigIsConstructorTest() { -} - -var _wrap_new_ConstructorTest unsafe.Pointer - -func _swig_wrap_new_ConstructorTest(base uintptr, _ uintptr, _ uintptr, _ uintptr) (_ SwigcptrConstructorTest) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_ConstructorTest, _swig_p) - return -} - -func NewConstructorTest(arg1 XXX, arg2 XXX, arg3 XXX, arg4 XXX) (_swig_ret ConstructorTest) { - return _swig_wrap_new_ConstructorTest(arg1.Swigcptr(), arg2.Swigcptr(), arg3.Swigcptr(), arg4.Swigcptr()) -} - -var _wrap_delete_ConstructorTest unsafe.Pointer - -func _swig_wrap_delete_ConstructorTest(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_ConstructorTest, _swig_p) - return -} - -func DeleteConstructorTest(arg1 ConstructorTest) { - _swig_wrap_delete_ConstructorTest(arg1.Swigcptr()) -} - -type ConstructorTest interface { - Swigcptr() uintptr - SwigIsConstructorTest() -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/li_typemaps.go b/Examples/test-suite/go/li_typemaps.go deleted file mode 100644 index 88448449d..000000000 --- a/Examples/test-suite/go/li_typemaps.go +++ /dev/null @@ -1,931 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../li_typemaps.i - -package li_typemaps - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrFoo uintptr - -func (p SwigcptrFoo) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrFoo) SwigIsFoo() { -} - -var _wrap_Foo_a_set unsafe.Pointer - -func _swig_wrap_Foo_a_set(base SwigcptrFoo, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_a_set, _swig_p) - return -} - -func (arg1 SwigcptrFoo) SetA(arg2 int) { - _swig_wrap_Foo_a_set(arg1, arg2) -} - -var _wrap_Foo_a_get unsafe.Pointer - -func _swig_wrap_Foo_a_get(base SwigcptrFoo) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_a_get, _swig_p) - return -} - -func (arg1 SwigcptrFoo) GetA() (_swig_ret int) { - return _swig_wrap_Foo_a_get(arg1) -} - -var _wrap_new_Foo unsafe.Pointer - -func _swig_wrap_new_Foo() (base SwigcptrFoo) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Foo, _swig_p) - return -} - -func NewFoo() (_swig_ret Foo) { - return _swig_wrap_new_Foo() -} - -var _wrap_delete_Foo unsafe.Pointer - -func _swig_wrap_delete_Foo(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Foo, _swig_p) - return -} - -func DeleteFoo(arg1 Foo) { - _swig_wrap_delete_Foo(arg1.Swigcptr()) -} - -type Foo interface { - Swigcptr() uintptr - SwigIsFoo() - SetA(arg2 int) - GetA() (_swig_ret int) -} - -var _wrap_in_bool unsafe.Pointer - -func In_bool(arg1 bool) (_swig_ret bool) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_in_bool, _swig_p) - return -} -var _wrap_in_int unsafe.Pointer - -func In_int(arg1 int) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_in_int, _swig_p) - return -} -var _wrap_in_long unsafe.Pointer - -func In_long(arg1 int64) (_swig_ret int64) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_in_long, _swig_p) - return -} -var _wrap_in_short unsafe.Pointer - -func In_short(arg1 int16) (_swig_ret int16) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_in_short, _swig_p) - return -} -var _wrap_in_uint unsafe.Pointer - -func In_uint(arg1 uint) (_swig_ret uint) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_in_uint, _swig_p) - return -} -var _wrap_in_ushort unsafe.Pointer - -func In_ushort(arg1 uint16) (_swig_ret uint16) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_in_ushort, _swig_p) - return -} -var _wrap_in_ulong unsafe.Pointer - -func In_ulong(arg1 uint64) (_swig_ret uint64) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_in_ulong, _swig_p) - return -} -var _wrap_in_uchar unsafe.Pointer - -func In_uchar(arg1 byte) (_swig_ret byte) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_in_uchar, _swig_p) - return -} -var _wrap_in_schar unsafe.Pointer - -func In_schar(arg1 int8) (_swig_ret int8) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_in_schar, _swig_p) - return -} -var _wrap_in_float unsafe.Pointer - -func In_float(arg1 float32) (_swig_ret float32) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_in_float, _swig_p) - return -} -var _wrap_in_double unsafe.Pointer - -func In_double(arg1 float64) (_swig_ret float64) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_in_double, _swig_p) - return -} -var _wrap_in_longlong unsafe.Pointer - -func In_longlong(arg1 int64) (_swig_ret int64) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_in_longlong, _swig_p) - return -} -var _wrap_in_ulonglong unsafe.Pointer - -func In_ulonglong(arg1 uint64) (_swig_ret uint64) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_in_ulonglong, _swig_p) - return -} -var _wrap_inr_bool unsafe.Pointer - -func Inr_bool(arg1 bool) (_swig_ret bool) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_inr_bool, _swig_p) - return -} -var _wrap_inr_int unsafe.Pointer - -func Inr_int(arg1 int) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_inr_int, _swig_p) - return -} -var _wrap_inr_long unsafe.Pointer - -func Inr_long(arg1 int64) (_swig_ret int64) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_inr_long, _swig_p) - return -} -var _wrap_inr_short unsafe.Pointer - -func Inr_short(arg1 int16) (_swig_ret int16) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_inr_short, _swig_p) - return -} -var _wrap_inr_uint unsafe.Pointer - -func Inr_uint(arg1 uint) (_swig_ret uint) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_inr_uint, _swig_p) - return -} -var _wrap_inr_ushort unsafe.Pointer - -func Inr_ushort(arg1 uint16) (_swig_ret uint16) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_inr_ushort, _swig_p) - return -} -var _wrap_inr_ulong unsafe.Pointer - -func Inr_ulong(arg1 uint64) (_swig_ret uint64) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_inr_ulong, _swig_p) - return -} -var _wrap_inr_uchar unsafe.Pointer - -func Inr_uchar(arg1 byte) (_swig_ret byte) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_inr_uchar, _swig_p) - return -} -var _wrap_inr_schar unsafe.Pointer - -func Inr_schar(arg1 int8) (_swig_ret int8) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_inr_schar, _swig_p) - return -} -var _wrap_inr_float unsafe.Pointer - -func Inr_float(arg1 float32) (_swig_ret float32) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_inr_float, _swig_p) - return -} -var _wrap_inr_double unsafe.Pointer - -func Inr_double(arg1 float64) (_swig_ret float64) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_inr_double, _swig_p) - return -} -var _wrap_inr_longlong unsafe.Pointer - -func Inr_longlong(arg1 int64) (_swig_ret int64) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_inr_longlong, _swig_p) - return -} -var _wrap_inr_ulonglong unsafe.Pointer - -func Inr_ulonglong(arg1 uint64) (_swig_ret uint64) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_inr_ulonglong, _swig_p) - return -} -var _wrap_out_bool unsafe.Pointer - -func _swig_wrap_out_bool(base bool, _ []bool) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_out_bool, _swig_p) - return -} - -func Out_bool(arg1 bool, arg2 []bool) { - _swig_wrap_out_bool(arg1, arg2) -} - -var _wrap_out_int unsafe.Pointer - -func _swig_wrap_out_int(base int, _ []int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_out_int, _swig_p) - return -} - -func Out_int(arg1 int, arg2 []int) { - _swig_wrap_out_int(arg1, arg2) -} - -var _wrap_out_short unsafe.Pointer - -func _swig_wrap_out_short(base int16, _ []int16) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_out_short, _swig_p) - return -} - -func Out_short(arg1 int16, arg2 []int16) { - _swig_wrap_out_short(arg1, arg2) -} - -var _wrap_out_long unsafe.Pointer - -func _swig_wrap_out_long(base int64, _ []int64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_out_long, _swig_p) - return -} - -func Out_long(arg1 int64, arg2 []int64) { - _swig_wrap_out_long(arg1, arg2) -} - -var _wrap_out_uint unsafe.Pointer - -func _swig_wrap_out_uint(base uint, _ []uint) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_out_uint, _swig_p) - return -} - -func Out_uint(arg1 uint, arg2 []uint) { - _swig_wrap_out_uint(arg1, arg2) -} - -var _wrap_out_ushort unsafe.Pointer - -func _swig_wrap_out_ushort(base uint16, _ []uint16) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_out_ushort, _swig_p) - return -} - -func Out_ushort(arg1 uint16, arg2 []uint16) { - _swig_wrap_out_ushort(arg1, arg2) -} - -var _wrap_out_ulong unsafe.Pointer - -func _swig_wrap_out_ulong(base uint64, _ []uint64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_out_ulong, _swig_p) - return -} - -func Out_ulong(arg1 uint64, arg2 []uint64) { - _swig_wrap_out_ulong(arg1, arg2) -} - -var _wrap_out_uchar unsafe.Pointer - -func _swig_wrap_out_uchar(base byte, _ []byte) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_out_uchar, _swig_p) - return -} - -func Out_uchar(arg1 byte, arg2 []byte) { - _swig_wrap_out_uchar(arg1, arg2) -} - -var _wrap_out_schar unsafe.Pointer - -func _swig_wrap_out_schar(base int8, _ []int8) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_out_schar, _swig_p) - return -} - -func Out_schar(arg1 int8, arg2 []int8) { - _swig_wrap_out_schar(arg1, arg2) -} - -var _wrap_out_float unsafe.Pointer - -func _swig_wrap_out_float(base float32, _ []float32) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_out_float, _swig_p) - return -} - -func Out_float(arg1 float32, arg2 []float32) { - _swig_wrap_out_float(arg1, arg2) -} - -var _wrap_out_double unsafe.Pointer - -func _swig_wrap_out_double(base float64, _ []float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_out_double, _swig_p) - return -} - -func Out_double(arg1 float64, arg2 []float64) { - _swig_wrap_out_double(arg1, arg2) -} - -var _wrap_out_longlong unsafe.Pointer - -func _swig_wrap_out_longlong(base int64, _ []int64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_out_longlong, _swig_p) - return -} - -func Out_longlong(arg1 int64, arg2 []int64) { - _swig_wrap_out_longlong(arg1, arg2) -} - -var _wrap_out_ulonglong unsafe.Pointer - -func _swig_wrap_out_ulonglong(base uint64, _ []uint64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_out_ulonglong, _swig_p) - return -} - -func Out_ulonglong(arg1 uint64, arg2 []uint64) { - _swig_wrap_out_ulonglong(arg1, arg2) -} - -var _wrap_out_foo unsafe.Pointer - -func _swig_wrap_out_foo(base int, _ []int) (_ SwigcptrFoo) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_out_foo, _swig_p) - return -} - -func Out_foo(arg1 int, arg2 []int) (_swig_ret Foo) { - return _swig_wrap_out_foo(arg1, arg2) -} - -var _wrap_outr_bool unsafe.Pointer - -func _swig_wrap_outr_bool(base bool, _ []bool) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_outr_bool, _swig_p) - return -} - -func Outr_bool(arg1 bool, arg2 []bool) { - _swig_wrap_outr_bool(arg1, arg2) -} - -var _wrap_outr_int unsafe.Pointer - -func _swig_wrap_outr_int(base int, _ []int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_outr_int, _swig_p) - return -} - -func Outr_int(arg1 int, arg2 []int) { - _swig_wrap_outr_int(arg1, arg2) -} - -var _wrap_outr_short unsafe.Pointer - -func _swig_wrap_outr_short(base int16, _ []int16) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_outr_short, _swig_p) - return -} - -func Outr_short(arg1 int16, arg2 []int16) { - _swig_wrap_outr_short(arg1, arg2) -} - -var _wrap_outr_long unsafe.Pointer - -func _swig_wrap_outr_long(base int64, _ []int64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_outr_long, _swig_p) - return -} - -func Outr_long(arg1 int64, arg2 []int64) { - _swig_wrap_outr_long(arg1, arg2) -} - -var _wrap_outr_uint unsafe.Pointer - -func _swig_wrap_outr_uint(base uint, _ []uint) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_outr_uint, _swig_p) - return -} - -func Outr_uint(arg1 uint, arg2 []uint) { - _swig_wrap_outr_uint(arg1, arg2) -} - -var _wrap_outr_ushort unsafe.Pointer - -func _swig_wrap_outr_ushort(base uint16, _ []uint16) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_outr_ushort, _swig_p) - return -} - -func Outr_ushort(arg1 uint16, arg2 []uint16) { - _swig_wrap_outr_ushort(arg1, arg2) -} - -var _wrap_outr_ulong unsafe.Pointer - -func _swig_wrap_outr_ulong(base uint64, _ []uint64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_outr_ulong, _swig_p) - return -} - -func Outr_ulong(arg1 uint64, arg2 []uint64) { - _swig_wrap_outr_ulong(arg1, arg2) -} - -var _wrap_outr_uchar unsafe.Pointer - -func _swig_wrap_outr_uchar(base byte, _ []byte) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_outr_uchar, _swig_p) - return -} - -func Outr_uchar(arg1 byte, arg2 []byte) { - _swig_wrap_outr_uchar(arg1, arg2) -} - -var _wrap_outr_schar unsafe.Pointer - -func _swig_wrap_outr_schar(base int8, _ []int8) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_outr_schar, _swig_p) - return -} - -func Outr_schar(arg1 int8, arg2 []int8) { - _swig_wrap_outr_schar(arg1, arg2) -} - -var _wrap_outr_float unsafe.Pointer - -func _swig_wrap_outr_float(base float32, _ []float32) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_outr_float, _swig_p) - return -} - -func Outr_float(arg1 float32, arg2 []float32) { - _swig_wrap_outr_float(arg1, arg2) -} - -var _wrap_outr_double unsafe.Pointer - -func _swig_wrap_outr_double(base float64, _ []float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_outr_double, _swig_p) - return -} - -func Outr_double(arg1 float64, arg2 []float64) { - _swig_wrap_outr_double(arg1, arg2) -} - -var _wrap_outr_longlong unsafe.Pointer - -func _swig_wrap_outr_longlong(base int64, _ []int64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_outr_longlong, _swig_p) - return -} - -func Outr_longlong(arg1 int64, arg2 []int64) { - _swig_wrap_outr_longlong(arg1, arg2) -} - -var _wrap_outr_ulonglong unsafe.Pointer - -func _swig_wrap_outr_ulonglong(base uint64, _ []uint64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_outr_ulonglong, _swig_p) - return -} - -func Outr_ulonglong(arg1 uint64, arg2 []uint64) { - _swig_wrap_outr_ulonglong(arg1, arg2) -} - -var _wrap_inout_bool unsafe.Pointer - -func _swig_wrap_inout_bool(base []bool) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_inout_bool, _swig_p) - return -} - -func Inout_bool(arg1 []bool) { - _swig_wrap_inout_bool(arg1) -} - -var _wrap_inout_int unsafe.Pointer - -func _swig_wrap_inout_int(base []int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_inout_int, _swig_p) - return -} - -func Inout_int(arg1 []int) { - _swig_wrap_inout_int(arg1) -} - -var _wrap_inout_short unsafe.Pointer - -func _swig_wrap_inout_short(base []int16) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_inout_short, _swig_p) - return -} - -func Inout_short(arg1 []int16) { - _swig_wrap_inout_short(arg1) -} - -var _wrap_inout_long unsafe.Pointer - -func _swig_wrap_inout_long(base []int64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_inout_long, _swig_p) - return -} - -func Inout_long(arg1 []int64) { - _swig_wrap_inout_long(arg1) -} - -var _wrap_inout_uint unsafe.Pointer - -func _swig_wrap_inout_uint(base []uint) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_inout_uint, _swig_p) - return -} - -func Inout_uint(arg1 []uint) { - _swig_wrap_inout_uint(arg1) -} - -var _wrap_inout_ushort unsafe.Pointer - -func _swig_wrap_inout_ushort(base []uint16) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_inout_ushort, _swig_p) - return -} - -func Inout_ushort(arg1 []uint16) { - _swig_wrap_inout_ushort(arg1) -} - -var _wrap_inout_ulong unsafe.Pointer - -func _swig_wrap_inout_ulong(base []uint64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_inout_ulong, _swig_p) - return -} - -func Inout_ulong(arg1 []uint64) { - _swig_wrap_inout_ulong(arg1) -} - -var _wrap_inout_uchar unsafe.Pointer - -func _swig_wrap_inout_uchar(base []byte) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_inout_uchar, _swig_p) - return -} - -func Inout_uchar(arg1 []byte) { - _swig_wrap_inout_uchar(arg1) -} - -var _wrap_inout_schar unsafe.Pointer - -func _swig_wrap_inout_schar(base []int8) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_inout_schar, _swig_p) - return -} - -func Inout_schar(arg1 []int8) { - _swig_wrap_inout_schar(arg1) -} - -var _wrap_inout_float unsafe.Pointer - -func _swig_wrap_inout_float(base []float32) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_inout_float, _swig_p) - return -} - -func Inout_float(arg1 []float32) { - _swig_wrap_inout_float(arg1) -} - -var _wrap_inout_double unsafe.Pointer - -func _swig_wrap_inout_double(base []float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_inout_double, _swig_p) - return -} - -func Inout_double(arg1 []float64) { - _swig_wrap_inout_double(arg1) -} - -var _wrap_inout_longlong unsafe.Pointer - -func _swig_wrap_inout_longlong(base []int64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_inout_longlong, _swig_p) - return -} - -func Inout_longlong(arg1 []int64) { - _swig_wrap_inout_longlong(arg1) -} - -var _wrap_inout_ulonglong unsafe.Pointer - -func _swig_wrap_inout_ulonglong(base []uint64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_inout_ulonglong, _swig_p) - return -} - -func Inout_ulonglong(arg1 []uint64) { - _swig_wrap_inout_ulonglong(arg1) -} - -var _wrap_inoutr_bool unsafe.Pointer - -func _swig_wrap_inoutr_bool(base []bool) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_inoutr_bool, _swig_p) - return -} - -func Inoutr_bool(arg1 []bool) { - _swig_wrap_inoutr_bool(arg1) -} - -var _wrap_inoutr_int unsafe.Pointer - -func _swig_wrap_inoutr_int(base []int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_inoutr_int, _swig_p) - return -} - -func Inoutr_int(arg1 []int) { - _swig_wrap_inoutr_int(arg1) -} - -var _wrap_inoutr_short unsafe.Pointer - -func _swig_wrap_inoutr_short(base []int16) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_inoutr_short, _swig_p) - return -} - -func Inoutr_short(arg1 []int16) { - _swig_wrap_inoutr_short(arg1) -} - -var _wrap_inoutr_long unsafe.Pointer - -func _swig_wrap_inoutr_long(base []int64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_inoutr_long, _swig_p) - return -} - -func Inoutr_long(arg1 []int64) { - _swig_wrap_inoutr_long(arg1) -} - -var _wrap_inoutr_uint unsafe.Pointer - -func _swig_wrap_inoutr_uint(base []uint) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_inoutr_uint, _swig_p) - return -} - -func Inoutr_uint(arg1 []uint) { - _swig_wrap_inoutr_uint(arg1) -} - -var _wrap_inoutr_ushort unsafe.Pointer - -func _swig_wrap_inoutr_ushort(base []uint16) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_inoutr_ushort, _swig_p) - return -} - -func Inoutr_ushort(arg1 []uint16) { - _swig_wrap_inoutr_ushort(arg1) -} - -var _wrap_inoutr_ulong unsafe.Pointer - -func _swig_wrap_inoutr_ulong(base []uint64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_inoutr_ulong, _swig_p) - return -} - -func Inoutr_ulong(arg1 []uint64) { - _swig_wrap_inoutr_ulong(arg1) -} - -var _wrap_inoutr_uchar unsafe.Pointer - -func _swig_wrap_inoutr_uchar(base []byte) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_inoutr_uchar, _swig_p) - return -} - -func Inoutr_uchar(arg1 []byte) { - _swig_wrap_inoutr_uchar(arg1) -} - -var _wrap_inoutr_schar unsafe.Pointer - -func _swig_wrap_inoutr_schar(base []int8) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_inoutr_schar, _swig_p) - return -} - -func Inoutr_schar(arg1 []int8) { - _swig_wrap_inoutr_schar(arg1) -} - -var _wrap_inoutr_float unsafe.Pointer - -func _swig_wrap_inoutr_float(base []float32) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_inoutr_float, _swig_p) - return -} - -func Inoutr_float(arg1 []float32) { - _swig_wrap_inoutr_float(arg1) -} - -var _wrap_inoutr_double unsafe.Pointer - -func _swig_wrap_inoutr_double(base []float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_inoutr_double, _swig_p) - return -} - -func Inoutr_double(arg1 []float64) { - _swig_wrap_inoutr_double(arg1) -} - -var _wrap_inoutr_longlong unsafe.Pointer - -func _swig_wrap_inoutr_longlong(base []int64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_inoutr_longlong, _swig_p) - return -} - -func Inoutr_longlong(arg1 []int64) { - _swig_wrap_inoutr_longlong(arg1) -} - -var _wrap_inoutr_ulonglong unsafe.Pointer - -func _swig_wrap_inoutr_ulonglong(base []uint64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_inoutr_ulonglong, _swig_p) - return -} - -func Inoutr_ulonglong(arg1 []uint64) { - _swig_wrap_inoutr_ulonglong(arg1) -} - -var _wrap_inoutr_int2 unsafe.Pointer - -func _swig_wrap_inoutr_int2(base []int, _ []int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_inoutr_int2, _swig_p) - return -} - -func Inoutr_int2(arg1 []int, arg2 []int) { - _swig_wrap_inoutr_int2(arg1, arg2) -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/li_typemaps_apply.go b/Examples/test-suite/go/li_typemaps_apply.go deleted file mode 100644 index b9b4d0694..000000000 --- a/Examples/test-suite/go/li_typemaps_apply.go +++ /dev/null @@ -1,575 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../li_typemaps_apply.i - -package li_typemaps_apply - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -var _wrap_input_ptr_bool unsafe.Pointer - -func Input_ptr_bool(arg1 bool) (_swig_ret bool) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_input_ptr_bool, _swig_p) - return -} -var _wrap_input_ref_bool unsafe.Pointer - -func Input_ref_bool(arg1 bool) (_swig_ret bool) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_input_ref_bool, _swig_p) - return -} -var _wrap_output_ptr_bool unsafe.Pointer - -func Output_ptr_bool(arg1 bool, arg2 []bool) (_swig_ret []bool) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_output_ptr_bool, _swig_p) - return -} -var _wrap_output_ref_bool unsafe.Pointer - -func Output_ref_bool(arg1 bool, arg2 []bool) (_swig_ret []bool) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_output_ref_bool, _swig_p) - return -} -var _wrap_inout_ptr_bool unsafe.Pointer - -func Inout_ptr_bool(arg1 []bool) (_swig_ret []bool) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_inout_ptr_bool, _swig_p) - return -} -var _wrap_inout_ref_bool unsafe.Pointer - -func Inout_ref_bool(arg1 []bool) (_swig_ret []bool) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_inout_ref_bool, _swig_p) - return -} -var _wrap_input_ptr_int unsafe.Pointer - -func Input_ptr_int(arg1 int) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_input_ptr_int, _swig_p) - return -} -var _wrap_input_ref_int unsafe.Pointer - -func Input_ref_int(arg1 int) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_input_ref_int, _swig_p) - return -} -var _wrap_output_ptr_int unsafe.Pointer - -func Output_ptr_int(arg1 int, arg2 []int) (_swig_ret []int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_output_ptr_int, _swig_p) - return -} -var _wrap_output_ref_int unsafe.Pointer - -func Output_ref_int(arg1 int, arg2 []int) (_swig_ret []int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_output_ref_int, _swig_p) - return -} -var _wrap_inout_ptr_int unsafe.Pointer - -func Inout_ptr_int(arg1 []int) (_swig_ret []int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_inout_ptr_int, _swig_p) - return -} -var _wrap_inout_ref_int unsafe.Pointer - -func Inout_ref_int(arg1 []int) (_swig_ret []int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_inout_ref_int, _swig_p) - return -} -var _wrap_input_ptr_short unsafe.Pointer - -func Input_ptr_short(arg1 int16) (_swig_ret int16) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_input_ptr_short, _swig_p) - return -} -var _wrap_input_ref_short unsafe.Pointer - -func Input_ref_short(arg1 int16) (_swig_ret int16) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_input_ref_short, _swig_p) - return -} -var _wrap_output_ptr_short unsafe.Pointer - -func Output_ptr_short(arg1 int16, arg2 []int16) (_swig_ret []int16) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_output_ptr_short, _swig_p) - return -} -var _wrap_output_ref_short unsafe.Pointer - -func Output_ref_short(arg1 int16, arg2 []int16) (_swig_ret []int16) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_output_ref_short, _swig_p) - return -} -var _wrap_inout_ptr_short unsafe.Pointer - -func Inout_ptr_short(arg1 []int16) (_swig_ret []int16) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_inout_ptr_short, _swig_p) - return -} -var _wrap_inout_ref_short unsafe.Pointer - -func Inout_ref_short(arg1 []int16) (_swig_ret []int16) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_inout_ref_short, _swig_p) - return -} -var _wrap_input_ptr_long unsafe.Pointer - -func Input_ptr_long(arg1 int64) (_swig_ret int64) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_input_ptr_long, _swig_p) - return -} -var _wrap_input_ref_long unsafe.Pointer - -func Input_ref_long(arg1 int64) (_swig_ret int64) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_input_ref_long, _swig_p) - return -} -var _wrap_output_ptr_long unsafe.Pointer - -func Output_ptr_long(arg1 int64, arg2 []int64) (_swig_ret []int64) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_output_ptr_long, _swig_p) - return -} -var _wrap_output_ref_long unsafe.Pointer - -func Output_ref_long(arg1 int64, arg2 []int64) (_swig_ret []int64) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_output_ref_long, _swig_p) - return -} -var _wrap_inout_ptr_long unsafe.Pointer - -func Inout_ptr_long(arg1 []int64) (_swig_ret []int64) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_inout_ptr_long, _swig_p) - return -} -var _wrap_inout_ref_long unsafe.Pointer - -func Inout_ref_long(arg1 []int64) (_swig_ret []int64) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_inout_ref_long, _swig_p) - return -} -var _wrap_input_ptr_uint unsafe.Pointer - -func Input_ptr_uint(arg1 uint) (_swig_ret uint) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_input_ptr_uint, _swig_p) - return -} -var _wrap_input_ref_uint unsafe.Pointer - -func Input_ref_uint(arg1 uint) (_swig_ret uint) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_input_ref_uint, _swig_p) - return -} -var _wrap_output_ptr_uint unsafe.Pointer - -func Output_ptr_uint(arg1 uint, arg2 []uint) (_swig_ret []uint) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_output_ptr_uint, _swig_p) - return -} -var _wrap_output_ref_uint unsafe.Pointer - -func Output_ref_uint(arg1 uint, arg2 []uint) (_swig_ret []uint) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_output_ref_uint, _swig_p) - return -} -var _wrap_inout_ptr_uint unsafe.Pointer - -func Inout_ptr_uint(arg1 []uint) (_swig_ret []uint) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_inout_ptr_uint, _swig_p) - return -} -var _wrap_inout_ref_uint unsafe.Pointer - -func Inout_ref_uint(arg1 []uint) (_swig_ret []uint) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_inout_ref_uint, _swig_p) - return -} -var _wrap_input_ptr_ushort unsafe.Pointer - -func Input_ptr_ushort(arg1 uint16) (_swig_ret uint16) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_input_ptr_ushort, _swig_p) - return -} -var _wrap_input_ref_ushort unsafe.Pointer - -func Input_ref_ushort(arg1 uint16) (_swig_ret uint16) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_input_ref_ushort, _swig_p) - return -} -var _wrap_output_ptr_ushort unsafe.Pointer - -func Output_ptr_ushort(arg1 uint16, arg2 []uint16) (_swig_ret []uint16) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_output_ptr_ushort, _swig_p) - return -} -var _wrap_output_ref_ushort unsafe.Pointer - -func Output_ref_ushort(arg1 uint16, arg2 []uint16) (_swig_ret []uint16) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_output_ref_ushort, _swig_p) - return -} -var _wrap_inout_ptr_ushort unsafe.Pointer - -func Inout_ptr_ushort(arg1 []uint16) (_swig_ret []uint16) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_inout_ptr_ushort, _swig_p) - return -} -var _wrap_inout_ref_ushort unsafe.Pointer - -func Inout_ref_ushort(arg1 []uint16) (_swig_ret []uint16) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_inout_ref_ushort, _swig_p) - return -} -var _wrap_input_ptr_ulong unsafe.Pointer - -func Input_ptr_ulong(arg1 uint64) (_swig_ret uint64) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_input_ptr_ulong, _swig_p) - return -} -var _wrap_input_ref_ulong unsafe.Pointer - -func Input_ref_ulong(arg1 uint64) (_swig_ret uint64) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_input_ref_ulong, _swig_p) - return -} -var _wrap_output_ptr_ulong unsafe.Pointer - -func Output_ptr_ulong(arg1 uint64, arg2 []uint64) (_swig_ret []uint64) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_output_ptr_ulong, _swig_p) - return -} -var _wrap_output_ref_ulong unsafe.Pointer - -func Output_ref_ulong(arg1 uint64, arg2 []uint64) (_swig_ret []uint64) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_output_ref_ulong, _swig_p) - return -} -var _wrap_inout_ptr_ulong unsafe.Pointer - -func Inout_ptr_ulong(arg1 []uint64) (_swig_ret []uint64) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_inout_ptr_ulong, _swig_p) - return -} -var _wrap_inout_ref_ulong unsafe.Pointer - -func Inout_ref_ulong(arg1 []uint64) (_swig_ret []uint64) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_inout_ref_ulong, _swig_p) - return -} -var _wrap_input_ptr_uchar unsafe.Pointer - -func Input_ptr_uchar(arg1 byte) (_swig_ret byte) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_input_ptr_uchar, _swig_p) - return -} -var _wrap_input_ref_uchar unsafe.Pointer - -func Input_ref_uchar(arg1 byte) (_swig_ret byte) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_input_ref_uchar, _swig_p) - return -} -var _wrap_output_ptr_uchar unsafe.Pointer - -func Output_ptr_uchar(arg1 byte, arg2 []byte) (_swig_ret []byte) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_output_ptr_uchar, _swig_p) - return -} -var _wrap_output_ref_uchar unsafe.Pointer - -func Output_ref_uchar(arg1 byte, arg2 []byte) (_swig_ret []byte) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_output_ref_uchar, _swig_p) - return -} -var _wrap_inout_ptr_uchar unsafe.Pointer - -func Inout_ptr_uchar(arg1 []byte) (_swig_ret []byte) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_inout_ptr_uchar, _swig_p) - return -} -var _wrap_inout_ref_uchar unsafe.Pointer - -func Inout_ref_uchar(arg1 []byte) (_swig_ret []byte) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_inout_ref_uchar, _swig_p) - return -} -var _wrap_input_ptr_schar unsafe.Pointer - -func Input_ptr_schar(arg1 int8) (_swig_ret int8) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_input_ptr_schar, _swig_p) - return -} -var _wrap_input_ref_schar unsafe.Pointer - -func Input_ref_schar(arg1 int8) (_swig_ret int8) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_input_ref_schar, _swig_p) - return -} -var _wrap_output_ptr_schar unsafe.Pointer - -func Output_ptr_schar(arg1 int8, arg2 []int8) (_swig_ret []int8) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_output_ptr_schar, _swig_p) - return -} -var _wrap_output_ref_schar unsafe.Pointer - -func Output_ref_schar(arg1 int8, arg2 []int8) (_swig_ret []int8) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_output_ref_schar, _swig_p) - return -} -var _wrap_inout_ptr_schar unsafe.Pointer - -func Inout_ptr_schar(arg1 []int8) (_swig_ret []int8) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_inout_ptr_schar, _swig_p) - return -} -var _wrap_inout_ref_schar unsafe.Pointer - -func Inout_ref_schar(arg1 []int8) (_swig_ret []int8) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_inout_ref_schar, _swig_p) - return -} -var _wrap_input_ptr_float unsafe.Pointer - -func Input_ptr_float(arg1 float32) (_swig_ret float32) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_input_ptr_float, _swig_p) - return -} -var _wrap_input_ref_float unsafe.Pointer - -func Input_ref_float(arg1 float32) (_swig_ret float32) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_input_ref_float, _swig_p) - return -} -var _wrap_output_ptr_float unsafe.Pointer - -func Output_ptr_float(arg1 float32, arg2 []float32) (_swig_ret []float32) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_output_ptr_float, _swig_p) - return -} -var _wrap_output_ref_float unsafe.Pointer - -func Output_ref_float(arg1 float32, arg2 []float32) (_swig_ret []float32) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_output_ref_float, _swig_p) - return -} -var _wrap_inout_ptr_float unsafe.Pointer - -func Inout_ptr_float(arg1 []float32) (_swig_ret []float32) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_inout_ptr_float, _swig_p) - return -} -var _wrap_inout_ref_float unsafe.Pointer - -func Inout_ref_float(arg1 []float32) (_swig_ret []float32) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_inout_ref_float, _swig_p) - return -} -var _wrap_input_ptr_double unsafe.Pointer - -func Input_ptr_double(arg1 float64) (_swig_ret float64) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_input_ptr_double, _swig_p) - return -} -var _wrap_input_ref_double unsafe.Pointer - -func Input_ref_double(arg1 float64) (_swig_ret float64) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_input_ref_double, _swig_p) - return -} -var _wrap_output_ptr_double unsafe.Pointer - -func Output_ptr_double(arg1 float64, arg2 []float64) (_swig_ret []float64) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_output_ptr_double, _swig_p) - return -} -var _wrap_output_ref_double unsafe.Pointer - -func Output_ref_double(arg1 float64, arg2 []float64) (_swig_ret []float64) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_output_ref_double, _swig_p) - return -} -var _wrap_inout_ptr_double unsafe.Pointer - -func Inout_ptr_double(arg1 []float64) (_swig_ret []float64) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_inout_ptr_double, _swig_p) - return -} -var _wrap_inout_ref_double unsafe.Pointer - -func Inout_ref_double(arg1 []float64) (_swig_ret []float64) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_inout_ref_double, _swig_p) - return -} -var _wrap_input_ptr_longlong unsafe.Pointer - -func Input_ptr_longlong(arg1 int64) (_swig_ret int64) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_input_ptr_longlong, _swig_p) - return -} -var _wrap_input_ref_longlong unsafe.Pointer - -func Input_ref_longlong(arg1 int64) (_swig_ret int64) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_input_ref_longlong, _swig_p) - return -} -var _wrap_output_ptr_longlong unsafe.Pointer - -func Output_ptr_longlong(arg1 int64, arg2 []int64) (_swig_ret []int64) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_output_ptr_longlong, _swig_p) - return -} -var _wrap_output_ref_longlong unsafe.Pointer - -func Output_ref_longlong(arg1 int64, arg2 []int64) (_swig_ret []int64) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_output_ref_longlong, _swig_p) - return -} -var _wrap_inout_ptr_longlong unsafe.Pointer - -func Inout_ptr_longlong(arg1 []int64) (_swig_ret []int64) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_inout_ptr_longlong, _swig_p) - return -} -var _wrap_inout_ref_longlong unsafe.Pointer - -func Inout_ref_longlong(arg1 []int64) (_swig_ret []int64) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_inout_ref_longlong, _swig_p) - return -} -var _wrap_input_ptr_ulonglong unsafe.Pointer - -func Input_ptr_ulonglong(arg1 uint64) (_swig_ret uint64) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_input_ptr_ulonglong, _swig_p) - return -} -var _wrap_input_ref_ulonglong unsafe.Pointer - -func Input_ref_ulonglong(arg1 uint64) (_swig_ret uint64) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_input_ref_ulonglong, _swig_p) - return -} -var _wrap_output_ptr_ulonglong unsafe.Pointer - -func Output_ptr_ulonglong(arg1 uint64, arg2 []uint64) (_swig_ret []uint64) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_output_ptr_ulonglong, _swig_p) - return -} -var _wrap_output_ref_ulonglong unsafe.Pointer - -func Output_ref_ulonglong(arg1 uint64, arg2 []uint64) (_swig_ret []uint64) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_output_ref_ulonglong, _swig_p) - return -} -var _wrap_inout_ptr_ulonglong unsafe.Pointer - -func Inout_ptr_ulonglong(arg1 []uint64) (_swig_ret []uint64) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_inout_ptr_ulonglong, _swig_p) - return -} -var _wrap_inout_ref_ulonglong unsafe.Pointer - -func Inout_ref_ulonglong(arg1 []uint64) (_swig_ret []uint64) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_inout_ref_ulonglong, _swig_p) - return -} - diff --git a/Examples/test-suite/go/li_windows.go b/Examples/test-suite/go/li_windows.go deleted file mode 100644 index c8e035584..000000000 --- a/Examples/test-suite/go/li_windows.go +++ /dev/null @@ -1,624 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../li_windows.i - -package li_windows - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -var _wrap_int8_val unsafe.Pointer - -func Int8_val(arg1 int8) (_swig_ret int8) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_int8_val, _swig_p) - return -} -var _wrap_int16_val unsafe.Pointer - -func Int16_val(arg1 int16) (_swig_ret int16) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_int16_val, _swig_p) - return -} -var _wrap_int32_val unsafe.Pointer - -func Int32_val(arg1 int) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_int32_val, _swig_p) - return -} -var _wrap_int64_val unsafe.Pointer - -func Int64_val(arg1 int64) (_swig_ret int64) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_int64_val, _swig_p) - return -} -var _wrap_uint8_val unsafe.Pointer - -func Uint8_val(arg1 byte) (_swig_ret byte) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_uint8_val, _swig_p) - return -} -var _wrap_uint16_val unsafe.Pointer - -func Uint16_val(arg1 uint16) (_swig_ret uint16) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_uint16_val, _swig_p) - return -} -var _wrap_uint32_val unsafe.Pointer - -func Uint32_val(arg1 uint) (_swig_ret uint) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_uint32_val, _swig_p) - return -} -var _wrap_uint64_val unsafe.Pointer - -func Uint64_val(arg1 uint64) (_swig_ret uint64) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_uint64_val, _swig_p) - return -} -var _wrap_int8_ref unsafe.Pointer - -func Int8_ref(arg1 int8) (_swig_ret int8) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_int8_ref, _swig_p) - return -} -var _wrap_int16_ref unsafe.Pointer - -func Int16_ref(arg1 int16) (_swig_ret int16) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_int16_ref, _swig_p) - return -} -var _wrap_int32_ref unsafe.Pointer - -func Int32_ref(arg1 int) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_int32_ref, _swig_p) - return -} -var _wrap_int64_ref unsafe.Pointer - -func Int64_ref(arg1 int64) (_swig_ret int64) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_int64_ref, _swig_p) - return -} -var _wrap_uint8_ref unsafe.Pointer - -func Uint8_ref(arg1 byte) (_swig_ret byte) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_uint8_ref, _swig_p) - return -} -var _wrap_uint16_ref unsafe.Pointer - -func Uint16_ref(arg1 uint16) (_swig_ret uint16) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_uint16_ref, _swig_p) - return -} -var _wrap_uint32_ref unsafe.Pointer - -func Uint32_ref(arg1 uint) (_swig_ret uint) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_uint32_ref, _swig_p) - return -} -var _wrap_uint64_ref unsafe.Pointer - -func Uint64_ref(arg1 uint64) (_swig_ret uint64) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_uint64_ref, _swig_p) - return -} -var _wrap_int8_global_set unsafe.Pointer - -func _swig_wrap_int8_global_set(base int8) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_int8_global_set, _swig_p) - return -} - -func SetInt8_global(arg1 int8) { - _swig_wrap_int8_global_set(arg1) -} - -var _wrap_int8_global_get unsafe.Pointer - -func GetInt8_global() (_swig_ret int8) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_int8_global_get, _swig_p) - return -} -var _wrap_int16_global_set unsafe.Pointer - -func _swig_wrap_int16_global_set(base int16) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_int16_global_set, _swig_p) - return -} - -func SetInt16_global(arg1 int16) { - _swig_wrap_int16_global_set(arg1) -} - -var _wrap_int16_global_get unsafe.Pointer - -func GetInt16_global() (_swig_ret int16) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_int16_global_get, _swig_p) - return -} -var _wrap_int32_global_set unsafe.Pointer - -func _swig_wrap_int32_global_set(base int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_int32_global_set, _swig_p) - return -} - -func SetInt32_global(arg1 int) { - _swig_wrap_int32_global_set(arg1) -} - -var _wrap_int32_global_get unsafe.Pointer - -func GetInt32_global() (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_int32_global_get, _swig_p) - return -} -var _wrap_int64_global_set unsafe.Pointer - -func _swig_wrap_int64_global_set(base int64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_int64_global_set, _swig_p) - return -} - -func SetInt64_global(arg1 int64) { - _swig_wrap_int64_global_set(arg1) -} - -var _wrap_int64_global_get unsafe.Pointer - -func GetInt64_global() (_swig_ret int64) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_int64_global_get, _swig_p) - return -} -var _wrap_uint8_global_set unsafe.Pointer - -func _swig_wrap_uint8_global_set(base byte) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_uint8_global_set, _swig_p) - return -} - -func SetUint8_global(arg1 byte) { - _swig_wrap_uint8_global_set(arg1) -} - -var _wrap_uint8_global_get unsafe.Pointer - -func GetUint8_global() (_swig_ret byte) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_uint8_global_get, _swig_p) - return -} -var _wrap_uint16_global_set unsafe.Pointer - -func _swig_wrap_uint16_global_set(base uint16) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_uint16_global_set, _swig_p) - return -} - -func SetUint16_global(arg1 uint16) { - _swig_wrap_uint16_global_set(arg1) -} - -var _wrap_uint16_global_get unsafe.Pointer - -func GetUint16_global() (_swig_ret uint16) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_uint16_global_get, _swig_p) - return -} -var _wrap_uint32_global_set unsafe.Pointer - -func _swig_wrap_uint32_global_set(base uint) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_uint32_global_set, _swig_p) - return -} - -func SetUint32_global(arg1 uint) { - _swig_wrap_uint32_global_set(arg1) -} - -var _wrap_uint32_global_get unsafe.Pointer - -func GetUint32_global() (_swig_ret uint) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_uint32_global_get, _swig_p) - return -} -var _wrap_uint64_global_set unsafe.Pointer - -func _swig_wrap_uint64_global_set(base uint64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_uint64_global_set, _swig_p) - return -} - -func SetUint64_global(arg1 uint64) { - _swig_wrap_uint64_global_set(arg1) -} - -var _wrap_uint64_global_get unsafe.Pointer - -func GetUint64_global() (_swig_ret uint64) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_uint64_global_get, _swig_p) - return -} -type SwigcptrWindowsInts uintptr - -func (p SwigcptrWindowsInts) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrWindowsInts) SwigIsWindowsInts() { -} - -var _wrap_WindowsInts_int8_member_set unsafe.Pointer - -func _swig_wrap_WindowsInts_int8_member_set(base SwigcptrWindowsInts, _ int8) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_WindowsInts_int8_member_set, _swig_p) - return -} - -func (arg1 SwigcptrWindowsInts) SetInt8_member(arg2 int8) { - _swig_wrap_WindowsInts_int8_member_set(arg1, arg2) -} - -var _wrap_WindowsInts_int8_member_get unsafe.Pointer - -func _swig_wrap_WindowsInts_int8_member_get(base SwigcptrWindowsInts) (_ int8) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_WindowsInts_int8_member_get, _swig_p) - return -} - -func (arg1 SwigcptrWindowsInts) GetInt8_member() (_swig_ret int8) { - return _swig_wrap_WindowsInts_int8_member_get(arg1) -} - -var _wrap_WindowsInts_int16_member_set unsafe.Pointer - -func _swig_wrap_WindowsInts_int16_member_set(base SwigcptrWindowsInts, _ int16) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_WindowsInts_int16_member_set, _swig_p) - return -} - -func (arg1 SwigcptrWindowsInts) SetInt16_member(arg2 int16) { - _swig_wrap_WindowsInts_int16_member_set(arg1, arg2) -} - -var _wrap_WindowsInts_int16_member_get unsafe.Pointer - -func _swig_wrap_WindowsInts_int16_member_get(base SwigcptrWindowsInts) (_ int16) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_WindowsInts_int16_member_get, _swig_p) - return -} - -func (arg1 SwigcptrWindowsInts) GetInt16_member() (_swig_ret int16) { - return _swig_wrap_WindowsInts_int16_member_get(arg1) -} - -var _wrap_WindowsInts_int32_member_set unsafe.Pointer - -func _swig_wrap_WindowsInts_int32_member_set(base SwigcptrWindowsInts, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_WindowsInts_int32_member_set, _swig_p) - return -} - -func (arg1 SwigcptrWindowsInts) SetInt32_member(arg2 int) { - _swig_wrap_WindowsInts_int32_member_set(arg1, arg2) -} - -var _wrap_WindowsInts_int32_member_get unsafe.Pointer - -func _swig_wrap_WindowsInts_int32_member_get(base SwigcptrWindowsInts) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_WindowsInts_int32_member_get, _swig_p) - return -} - -func (arg1 SwigcptrWindowsInts) GetInt32_member() (_swig_ret int) { - return _swig_wrap_WindowsInts_int32_member_get(arg1) -} - -var _wrap_WindowsInts_int64_member_set unsafe.Pointer - -func _swig_wrap_WindowsInts_int64_member_set(base SwigcptrWindowsInts, _ int64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_WindowsInts_int64_member_set, _swig_p) - return -} - -func (arg1 SwigcptrWindowsInts) SetInt64_member(arg2 int64) { - _swig_wrap_WindowsInts_int64_member_set(arg1, arg2) -} - -var _wrap_WindowsInts_int64_member_get unsafe.Pointer - -func _swig_wrap_WindowsInts_int64_member_get(base SwigcptrWindowsInts) (_ int64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_WindowsInts_int64_member_get, _swig_p) - return -} - -func (arg1 SwigcptrWindowsInts) GetInt64_member() (_swig_ret int64) { - return _swig_wrap_WindowsInts_int64_member_get(arg1) -} - -var _wrap_WindowsInts_uint8_member_set unsafe.Pointer - -func _swig_wrap_WindowsInts_uint8_member_set(base SwigcptrWindowsInts, _ byte) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_WindowsInts_uint8_member_set, _swig_p) - return -} - -func (arg1 SwigcptrWindowsInts) SetUint8_member(arg2 byte) { - _swig_wrap_WindowsInts_uint8_member_set(arg1, arg2) -} - -var _wrap_WindowsInts_uint8_member_get unsafe.Pointer - -func _swig_wrap_WindowsInts_uint8_member_get(base SwigcptrWindowsInts) (_ byte) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_WindowsInts_uint8_member_get, _swig_p) - return -} - -func (arg1 SwigcptrWindowsInts) GetUint8_member() (_swig_ret byte) { - return _swig_wrap_WindowsInts_uint8_member_get(arg1) -} - -var _wrap_WindowsInts_uint16_member_set unsafe.Pointer - -func _swig_wrap_WindowsInts_uint16_member_set(base SwigcptrWindowsInts, _ uint16) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_WindowsInts_uint16_member_set, _swig_p) - return -} - -func (arg1 SwigcptrWindowsInts) SetUint16_member(arg2 uint16) { - _swig_wrap_WindowsInts_uint16_member_set(arg1, arg2) -} - -var _wrap_WindowsInts_uint16_member_get unsafe.Pointer - -func _swig_wrap_WindowsInts_uint16_member_get(base SwigcptrWindowsInts) (_ uint16) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_WindowsInts_uint16_member_get, _swig_p) - return -} - -func (arg1 SwigcptrWindowsInts) GetUint16_member() (_swig_ret uint16) { - return _swig_wrap_WindowsInts_uint16_member_get(arg1) -} - -var _wrap_WindowsInts_uint32_member_set unsafe.Pointer - -func _swig_wrap_WindowsInts_uint32_member_set(base SwigcptrWindowsInts, _ uint) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_WindowsInts_uint32_member_set, _swig_p) - return -} - -func (arg1 SwigcptrWindowsInts) SetUint32_member(arg2 uint) { - _swig_wrap_WindowsInts_uint32_member_set(arg1, arg2) -} - -var _wrap_WindowsInts_uint32_member_get unsafe.Pointer - -func _swig_wrap_WindowsInts_uint32_member_get(base SwigcptrWindowsInts) (_ uint) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_WindowsInts_uint32_member_get, _swig_p) - return -} - -func (arg1 SwigcptrWindowsInts) GetUint32_member() (_swig_ret uint) { - return _swig_wrap_WindowsInts_uint32_member_get(arg1) -} - -var _wrap_WindowsInts_uint64_member_set unsafe.Pointer - -func _swig_wrap_WindowsInts_uint64_member_set(base SwigcptrWindowsInts, _ uint64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_WindowsInts_uint64_member_set, _swig_p) - return -} - -func (arg1 SwigcptrWindowsInts) SetUint64_member(arg2 uint64) { - _swig_wrap_WindowsInts_uint64_member_set(arg1, arg2) -} - -var _wrap_WindowsInts_uint64_member_get unsafe.Pointer - -func _swig_wrap_WindowsInts_uint64_member_get(base SwigcptrWindowsInts) (_ uint64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_WindowsInts_uint64_member_get, _swig_p) - return -} - -func (arg1 SwigcptrWindowsInts) GetUint64_member() (_swig_ret uint64) { - return _swig_wrap_WindowsInts_uint64_member_get(arg1) -} - -var _wrap_new_WindowsInts unsafe.Pointer - -func _swig_wrap_new_WindowsInts() (base SwigcptrWindowsInts) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_WindowsInts, _swig_p) - return -} - -func NewWindowsInts() (_swig_ret WindowsInts) { - return _swig_wrap_new_WindowsInts() -} - -var _wrap_delete_WindowsInts unsafe.Pointer - -func _swig_wrap_delete_WindowsInts(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_WindowsInts, _swig_p) - return -} - -func DeleteWindowsInts(arg1 WindowsInts) { - _swig_wrap_delete_WindowsInts(arg1.Swigcptr()) -} - -type WindowsInts interface { - Swigcptr() uintptr - SwigIsWindowsInts() - SetInt8_member(arg2 int8) - GetInt8_member() (_swig_ret int8) - SetInt16_member(arg2 int16) - GetInt16_member() (_swig_ret int16) - SetInt32_member(arg2 int) - GetInt32_member() (_swig_ret int) - SetInt64_member(arg2 int64) - GetInt64_member() (_swig_ret int64) - SetUint8_member(arg2 byte) - GetUint8_member() (_swig_ret byte) - SetUint16_member(arg2 uint16) - GetUint16_member() (_swig_ret uint16) - SetUint32_member(arg2 uint) - GetUint32_member() (_swig_ret uint) - SetUint64_member(arg2 uint64) - GetUint64_member() (_swig_ret uint64) -} - -var _wrap_int8_td unsafe.Pointer - -func Int8_td(arg1 int8) (_swig_ret int8) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_int8_td, _swig_p) - return -} -var _wrap_int16_td unsafe.Pointer - -func Int16_td(arg1 int16) (_swig_ret int16) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_int16_td, _swig_p) - return -} -var _wrap_int32_td unsafe.Pointer - -func Int32_td(arg1 int) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_int32_td, _swig_p) - return -} -var _wrap_int64_td unsafe.Pointer - -func Int64_td(arg1 int64) (_swig_ret int64) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_int64_td, _swig_p) - return -} -var _wrap_uint8_td unsafe.Pointer - -func Uint8_td(arg1 int8) (_swig_ret byte) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_uint8_td, _swig_p) - return -} -var _wrap_uint16_td unsafe.Pointer - -func Uint16_td(arg1 int16) (_swig_ret uint16) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_uint16_td, _swig_p) - return -} -var _wrap_uint32_td unsafe.Pointer - -func Uint32_td(arg1 int) (_swig_ret uint) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_uint32_td, _swig_p) - return -} -var _wrap_uint64_td unsafe.Pointer - -func Uint64_td(arg1 int64) (_swig_ret uint64) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_uint64_td, _swig_p) - return -} -var _wrap_declspecstdcall unsafe.Pointer - -func Declspecstdcall(arg1 int) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_declspecstdcall, _swig_p) - return -} -var _wrap_mefod unsafe.Pointer - -func Mefod(arg1 uint) (_swig_ret uint) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_mefod, _swig_p) - return -} -var _wrap_funktion unsafe.Pointer - -func Funktion(arg1 string) (_swig_ret string) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_funktion, _swig_p) - return -} - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/long_long.go b/Examples/test-suite/go/long_long.go deleted file mode 100644 index 783876eb2..000000000 --- a/Examples/test-suite/go/long_long.go +++ /dev/null @@ -1,195 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../long_long.i - -package long_long - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -var _wrap_foo1 unsafe.Pointer - -func _swig_wrap_foo1(base int64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_foo1, _swig_p) - return -} - -func Foo1(arg1 int64) { - _swig_wrap_foo1(arg1) -} - -var _wrap_foo2 unsafe.Pointer - -func _swig_wrap_foo2(base int64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_foo2, _swig_p) - return -} - -func Foo2(arg1 int64) { - _swig_wrap_foo2(arg1) -} - -var _wrap_foo3 unsafe.Pointer - -func _swig_wrap_foo3(base int64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_foo3, _swig_p) - return -} - -func Foo3(arg1 int64) { - _swig_wrap_foo3(arg1) -} - -var _wrap_foo4 unsafe.Pointer - -func _swig_wrap_foo4(base uint64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_foo4, _swig_p) - return -} - -func Foo4(arg1 uint64) { - _swig_wrap_foo4(arg1) -} - -var _wrap_foo5 unsafe.Pointer - -func _swig_wrap_foo5(base int64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_foo5, _swig_p) - return -} - -func Foo5(arg1 int64) { - _swig_wrap_foo5(arg1) -} - -var _wrap_foo6 unsafe.Pointer - -func _swig_wrap_foo6(base uint64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_foo6, _swig_p) - return -} - -func Foo6(arg1 uint64) { - _swig_wrap_foo6(arg1) -} - -var _wrap_bar1 unsafe.Pointer - -func Bar1() (_swig_ret int64) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_bar1, _swig_p) - return -} -var _wrap_bar2 unsafe.Pointer - -func Bar2() (_swig_ret int64) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_bar2, _swig_p) - return -} -var _wrap_bar3 unsafe.Pointer - -func Bar3() (_swig_ret int64) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_bar3, _swig_p) - return -} -var _wrap_bar4 unsafe.Pointer - -func Bar4() (_swig_ret uint64) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_bar4, _swig_p) - return -} -var _wrap_bar5 unsafe.Pointer - -func Bar5() (_swig_ret int64) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_bar5, _swig_p) - return -} -var _wrap_bar6 unsafe.Pointer - -func Bar6() (_swig_ret uint64) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_bar6, _swig_p) - return -} -var _wrap_ll_set unsafe.Pointer - -func _swig_wrap_ll_set(base int64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_ll_set, _swig_p) - return -} - -func SetLl(arg1 int64) { - _swig_wrap_ll_set(arg1) -} - -var _wrap_ll_get unsafe.Pointer - -func GetLl() (_swig_ret int64) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_ll_get, _swig_p) - return -} -var _wrap_ull_set unsafe.Pointer - -func _swig_wrap_ull_set(base uint64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_ull_set, _swig_p) - return -} - -func SetUll(arg1 uint64) { - _swig_wrap_ull_set(arg1) -} - -var _wrap_ull_get unsafe.Pointer - -func GetUll() (_swig_ret uint64) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_ull_get, _swig_p) - return -} -const Lconst1 int64 = 1234567890 -const Lconst2 uint64 = 1234567890 -const Lconst3 int64 = 1234567 -const Lconst4 uint64 = 1234567 -const Lconst5 int64 = 987654321 -const Lconst6 uint64 = 987654321 - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/long_long_apply.go b/Examples/test-suite/go/long_long_apply.go deleted file mode 100644 index cf6432912..000000000 --- a/Examples/test-suite/go/long_long_apply.go +++ /dev/null @@ -1,241 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../long_long_apply.i - -package long_long_apply - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -var _wrap_value1 unsafe.Pointer - -func Value1(arg1 int64) (_swig_ret int64) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_value1, _swig_p) - return -} -var _wrap_value2 unsafe.Pointer - -func Value2(arg1 uint64) (_swig_ret uint64) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_value2, _swig_p) - return -} -var _wrap_ref1 unsafe.Pointer - -func Ref1(arg1 int64) (_swig_ret int64) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_ref1, _swig_p) - return -} -var _wrap_ref2 unsafe.Pointer - -func Ref2(arg1 uint64) (_swig_ret uint64) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_ref2, _swig_p) - return -} -var _wrap_global1_set unsafe.Pointer - -func _swig_wrap_global1_set(base int64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_global1_set, _swig_p) - return -} - -func SetGlobal1(arg1 int64) { - _swig_wrap_global1_set(arg1) -} - -var _wrap_global1_get unsafe.Pointer - -func GetGlobal1() (_swig_ret int64) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_global1_get, _swig_p) - return -} -var _wrap_global2_set unsafe.Pointer - -func _swig_wrap_global2_set(base uint64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_global2_set, _swig_p) - return -} - -func SetGlobal2(arg1 uint64) { - _swig_wrap_global2_set(arg1) -} - -var _wrap_global2_get unsafe.Pointer - -func GetGlobal2() (_swig_ret uint64) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_global2_get, _swig_p) - return -} -var _wrap_global_ref1_get unsafe.Pointer - -func GetGlobal_ref1() (_swig_ret int64) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_global_ref1_get, _swig_p) - return -} -var _wrap_global_ref2_get unsafe.Pointer - -func GetGlobal_ref2() (_swig_ret uint64) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_global_ref2_get, _swig_p) - return -} -var _wrap_in_longlong unsafe.Pointer - -func In_longlong(arg1 int64) (_swig_ret int64) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_in_longlong, _swig_p) - return -} -var _wrap_in_ulonglong unsafe.Pointer - -func In_ulonglong(arg1 uint64) (_swig_ret uint64) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_in_ulonglong, _swig_p) - return -} -var _wrap_inr_longlong unsafe.Pointer - -func Inr_longlong(arg1 int64) (_swig_ret int64) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_inr_longlong, _swig_p) - return -} -var _wrap_inr_ulonglong unsafe.Pointer - -func Inr_ulonglong(arg1 uint64) (_swig_ret uint64) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_inr_ulonglong, _swig_p) - return -} -var _wrap_out_longlong unsafe.Pointer - -func _swig_wrap_out_longlong(base int64, _ []int64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_out_longlong, _swig_p) - return -} - -func Out_longlong(arg1 int64, arg2 []int64) { - _swig_wrap_out_longlong(arg1, arg2) -} - -var _wrap_out_ulonglong unsafe.Pointer - -func _swig_wrap_out_ulonglong(base uint64, _ []uint64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_out_ulonglong, _swig_p) - return -} - -func Out_ulonglong(arg1 uint64, arg2 []uint64) { - _swig_wrap_out_ulonglong(arg1, arg2) -} - -var _wrap_outr_longlong unsafe.Pointer - -func _swig_wrap_outr_longlong(base int64, _ []int64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_outr_longlong, _swig_p) - return -} - -func Outr_longlong(arg1 int64, arg2 []int64) { - _swig_wrap_outr_longlong(arg1, arg2) -} - -var _wrap_outr_ulonglong unsafe.Pointer - -func _swig_wrap_outr_ulonglong(base uint64, _ []uint64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_outr_ulonglong, _swig_p) - return -} - -func Outr_ulonglong(arg1 uint64, arg2 []uint64) { - _swig_wrap_outr_ulonglong(arg1, arg2) -} - -var _wrap_inout_longlong unsafe.Pointer - -func _swig_wrap_inout_longlong(base []int64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_inout_longlong, _swig_p) - return -} - -func Inout_longlong(arg1 []int64) { - _swig_wrap_inout_longlong(arg1) -} - -var _wrap_inout_ulonglong unsafe.Pointer - -func _swig_wrap_inout_ulonglong(base []uint64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_inout_ulonglong, _swig_p) - return -} - -func Inout_ulonglong(arg1 []uint64) { - _swig_wrap_inout_ulonglong(arg1) -} - -var _wrap_inoutr_longlong unsafe.Pointer - -func _swig_wrap_inoutr_longlong(base []int64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_inoutr_longlong, _swig_p) - return -} - -func Inoutr_longlong(arg1 []int64) { - _swig_wrap_inoutr_longlong(arg1) -} - -var _wrap_inoutr_ulonglong unsafe.Pointer - -func _swig_wrap_inoutr_ulonglong(base []uint64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_inoutr_ulonglong, _swig_p) - return -} - -func Inoutr_ulonglong(arg1 []uint64) { - _swig_wrap_inoutr_ulonglong(arg1) -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/member_funcptr_galore.go b/Examples/test-suite/go/member_funcptr_galore.go deleted file mode 100644 index 554b06255..000000000 --- a/Examples/test-suite/go/member_funcptr_galore.go +++ /dev/null @@ -1,432 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../member_funcptr_galore.i - -package member_funcptr_galore - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrFunktions uintptr - -func (p SwigcptrFunktions) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrFunktions) SwigIsFunktions() { -} - -var _wrap_Funktions_addByValue unsafe.Pointer - -func _swig_wrap_Funktions_addByValue(base SwigcptrFunktions, _ int, _ int) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Funktions_addByValue, _swig_p) - return -} - -func (arg1 SwigcptrFunktions) AddByValue(arg2 int, arg3 int) (_swig_ret int) { - return _swig_wrap_Funktions_addByValue(arg1, arg2, arg3) -} - -var _wrap_Funktions_addByPointer unsafe.Pointer - -func _swig_wrap_Funktions_addByPointer(base SwigcptrFunktions, _ int, _ int) (_ *int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Funktions_addByPointer, _swig_p) - return -} - -func (arg1 SwigcptrFunktions) AddByPointer(arg2 int, arg3 int) (_swig_ret *int) { - return _swig_wrap_Funktions_addByPointer(arg1, arg2, arg3) -} - -var _wrap_Funktions_addByReference unsafe.Pointer - -func _swig_wrap_Funktions_addByReference(base SwigcptrFunktions, _ int, _ int) (_ *int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Funktions_addByReference, _swig_p) - return -} - -func (arg1 SwigcptrFunktions) AddByReference(arg2 int, arg3 int) (_swig_ret *int) { - return _swig_wrap_Funktions_addByReference(arg1, arg2, arg3) -} - -var _wrap_new_Funktions unsafe.Pointer - -func _swig_wrap_new_Funktions() (base SwigcptrFunktions) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Funktions, _swig_p) - return -} - -func NewFunktions() (_swig_ret Funktions) { - return _swig_wrap_new_Funktions() -} - -var _wrap_delete_Funktions unsafe.Pointer - -func _swig_wrap_delete_Funktions(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Funktions, _swig_p) - return -} - -func DeleteFunktions(arg1 Funktions) { - _swig_wrap_delete_Funktions(arg1.Swigcptr()) -} - -type Funktions interface { - Swigcptr() uintptr - SwigIsFunktions() - AddByValue(arg2 int, arg3 int) (_swig_ret int) - AddByPointer(arg2 int, arg3 int) (_swig_ret *int) - AddByReference(arg2 int, arg3 int) (_swig_ret *int) -} - -type SwigcptrShape uintptr - -func (p SwigcptrShape) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrShape) SwigIsShape() { -} - -var _wrap_Shape_x_set unsafe.Pointer - -func _swig_wrap_Shape_x_set(base SwigcptrShape, _ float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Shape_x_set, _swig_p) - return -} - -func (arg1 SwigcptrShape) SetX(arg2 float64) { - _swig_wrap_Shape_x_set(arg1, arg2) -} - -var _wrap_Shape_x_get unsafe.Pointer - -func _swig_wrap_Shape_x_get(base SwigcptrShape) (_ float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Shape_x_get, _swig_p) - return -} - -func (arg1 SwigcptrShape) GetX() (_swig_ret float64) { - return _swig_wrap_Shape_x_get(arg1) -} - -var _wrap_Shape_y_set unsafe.Pointer - -func _swig_wrap_Shape_y_set(base SwigcptrShape, _ float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Shape_y_set, _swig_p) - return -} - -func (arg1 SwigcptrShape) SetY(arg2 float64) { - _swig_wrap_Shape_y_set(arg1, arg2) -} - -var _wrap_Shape_y_get unsafe.Pointer - -func _swig_wrap_Shape_y_get(base SwigcptrShape) (_ float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Shape_y_get, _swig_p) - return -} - -func (arg1 SwigcptrShape) GetY() (_swig_ret float64) { - return _swig_wrap_Shape_y_get(arg1) -} - -var _wrap_Shape_z_set unsafe.Pointer - -func _swig_wrap_Shape_z_set(base SwigcptrShape, _ *float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Shape_z_set, _swig_p) - return -} - -func (arg1 SwigcptrShape) SetZ(arg2 *float64) { - _swig_wrap_Shape_z_set(arg1, arg2) -} - -var _wrap_Shape_z_get unsafe.Pointer - -func _swig_wrap_Shape_z_get(base SwigcptrShape) (_ *float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Shape_z_get, _swig_p) - return -} - -func (arg1 SwigcptrShape) GetZ() (_swig_ret *float64) { - return _swig_wrap_Shape_z_get(arg1) -} - -var _wrap_Shape_move unsafe.Pointer - -func _swig_wrap_Shape_move(base SwigcptrShape, _ float64, _ float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Shape_move, _swig_p) - return -} - -func (arg1 SwigcptrShape) Move(arg2 float64, arg3 float64) { - _swig_wrap_Shape_move(arg1, arg2, arg3) -} - -var _wrap_Shape_area unsafe.Pointer - -func _swig_wrap_Shape_area(base SwigcptrShape, _ uintptr, _ _swig_memberptr) (_ float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Shape_area, _swig_p) - return -} - -func (arg1 SwigcptrShape) Area(arg2 Shape, arg3 _swig_memberptr) (_swig_ret float64) { - return _swig_wrap_Shape_area(arg1, arg2.Swigcptr(), arg3) -} - -var _wrap_Shape_abc unsafe.Pointer - -func _swig_wrap_Shape_abc(base SwigcptrShape, _ uintptr, _ uintptr) (_ float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Shape_abc, _swig_p) - return -} - -func (arg1 SwigcptrShape) Abc(arg2 Thing_Sl_short_Sg_, arg3 Thing_Sl_Space_Shape_SS_const_Sm__Sg_) (_swig_ret float64) { - return _swig_wrap_Shape_abc(arg1, arg2.Swigcptr(), arg3.Swigcptr()) -} - -var _wrap_new_Shape unsafe.Pointer - -func _swig_wrap_new_Shape() (base SwigcptrShape) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Shape, _swig_p) - return -} - -func NewShape() (_swig_ret Shape) { - return _swig_wrap_new_Shape() -} - -var _wrap_delete_Shape unsafe.Pointer - -func _swig_wrap_delete_Shape(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Shape, _swig_p) - return -} - -func DeleteShape(arg1 Shape) { - _swig_wrap_delete_Shape(arg1.Swigcptr()) -} - -type Shape interface { - Swigcptr() uintptr - SwigIsShape() - SetX(arg2 float64) - GetX() (_swig_ret float64) - SetY(arg2 float64) - GetY() (_swig_ret float64) - SetZ(arg2 *float64) - GetZ() (_swig_ret *float64) - Move(arg2 float64, arg3 float64) - Area(arg2 Shape, arg3 _swig_memberptr) (_swig_ret float64) - Abc(arg2 Thing_Sl_short_Sg_, arg3 Thing_Sl_Space_Shape_SS_const_Sm__Sg_) (_swig_ret float64) -} - -var _wrap_do_op unsafe.Pointer - -func _swig_wrap_do_op(base uintptr, _ _swig_memberptr) (_ float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_do_op, _swig_p) - return -} - -func Do_op(arg1 Shape, arg2 _swig_memberptr) (_swig_ret float64) { - return _swig_wrap_do_op(arg1.Swigcptr(), arg2) -} - -var _wrap_areapt unsafe.Pointer - -func Areapt() (_swig_ret _swig_memberptr) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_areapt, _swig_p) - return -} -var _wrap_abcpt unsafe.Pointer - -func Abcpt() (_swig_ret _swig_memberptr) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_abcpt, _swig_p) - return -} -var _wrap_areavar_set unsafe.Pointer - -func _swig_wrap_areavar_set(base _swig_memberptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_areavar_set, _swig_p) - return -} - -func SetAreavar(arg1 _swig_memberptr) { - _swig_wrap_areavar_set(arg1) -} - -var _wrap_areavar_get unsafe.Pointer - -func GetAreavar() (_swig_ret _swig_memberptr) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_areavar_get, _swig_p) - return -} -var _wrap_abcvar_set unsafe.Pointer - -func _swig_wrap_abcvar_set(base _swig_memberptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_abcvar_set, _swig_p) - return -} - -func SetAbcvar(arg1 _swig_memberptr) { - _swig_wrap_abcvar_set(arg1) -} - -var _wrap_abcvar_get unsafe.Pointer - -func GetAbcvar() (_swig_ret _swig_memberptr) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_abcvar_get, _swig_p) - return -} -var _wrap_AREAPT unsafe.Pointer - -func _swig_getAREAPT() (_swig_ret _swig_memberptr) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_AREAPT, _swig_p) - return -} -var AREAPT _swig_memberptr = _swig_getAREAPT() -var _wrap_PERIMPT unsafe.Pointer - -func _swig_getPERIMPT() (_swig_ret _swig_memberptr) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_PERIMPT, _swig_p) - return -} -var PERIMPT _swig_memberptr = _swig_getPERIMPT() -var _wrap_NULLPT unsafe.Pointer - -func _swig_getNULLPT() (_swig_ret _swig_memberptr) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_NULLPT, _swig_p) - return -} -var NULLPT _swig_memberptr = _swig_getNULLPT() -var _wrap_call1 unsafe.Pointer - -func Call1(arg1 _swig_memberptr, arg2 int, arg3 int) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_call1, _swig_p) - return -} -var _wrap_call2 unsafe.Pointer - -func Call2(arg1 _swig_memberptr, arg2 int, arg3 int) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_call2, _swig_p) - return -} -var _wrap_call3 unsafe.Pointer - -func Call3(arg1 _swig_memberptr, arg2 int, arg3 int) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_call3, _swig_p) - return -} -var _wrap_ADD_BY_VALUE unsafe.Pointer - -func _swig_getADD_BY_VALUE() (_swig_ret _swig_memberptr) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_ADD_BY_VALUE, _swig_p) - return -} -var ADD_BY_VALUE _swig_memberptr = _swig_getADD_BY_VALUE() -var _wrap_ADD_BY_POINTER unsafe.Pointer - -func _swig_getADD_BY_POINTER() (_swig_ret _swig_memberptr) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_ADD_BY_POINTER, _swig_p) - return -} -var ADD_BY_POINTER _swig_memberptr = _swig_getADD_BY_POINTER() -var _wrap_ADD_BY_REFERENCE unsafe.Pointer - -func _swig_getADD_BY_REFERENCE() (_swig_ret _swig_memberptr) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_ADD_BY_REFERENCE, _swig_p) - return -} -var ADD_BY_REFERENCE _swig_memberptr = _swig_getADD_BY_REFERENCE() -var _wrap_unreal1 unsafe.Pointer - -func Unreal1(arg1 _swig_memberptr) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_unreal1, _swig_p) - return -} -var _wrap_unreal2 unsafe.Pointer - -func Unreal2(arg1 _swig_memberptr) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_unreal2, _swig_p) - return -} - -type SwigcptrThing_Sl_short_Sg_ uintptr -type Thing_Sl_short_Sg_ interface { - Swigcptr() uintptr; -} -func (p SwigcptrThing_Sl_short_Sg_) Swigcptr() uintptr { - return uintptr(p) -} - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - -type SwigcptrThing_Sl_Space_Shape_SS_const_Sm__Sg_ uintptr -type Thing_Sl_Space_Shape_SS_const_Sm__Sg_ interface { - Swigcptr() uintptr; -} -func (p SwigcptrThing_Sl_Space_Shape_SS_const_Sm__Sg_) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/member_pointer.go b/Examples/test-suite/go/member_pointer.go deleted file mode 100644 index 3a6cb8556..000000000 --- a/Examples/test-suite/go/member_pointer.go +++ /dev/null @@ -1,737 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../member_pointer.i - -package member_pointer - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrShape uintptr - -func (p SwigcptrShape) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrShape) SwigIsShape() { -} - -var _wrap_delete_Shape unsafe.Pointer - -func _swig_wrap_delete_Shape(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Shape, _swig_p) - return -} - -func DeleteShape(arg1 Shape) { - _swig_wrap_delete_Shape(arg1.Swigcptr()) -} - -var _wrap_Shape_x_set unsafe.Pointer - -func _swig_wrap_Shape_x_set(base SwigcptrShape, _ float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Shape_x_set, _swig_p) - return -} - -func (arg1 SwigcptrShape) SetX(arg2 float64) { - _swig_wrap_Shape_x_set(arg1, arg2) -} - -var _wrap_Shape_x_get unsafe.Pointer - -func _swig_wrap_Shape_x_get(base SwigcptrShape) (_ float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Shape_x_get, _swig_p) - return -} - -func (arg1 SwigcptrShape) GetX() (_swig_ret float64) { - return _swig_wrap_Shape_x_get(arg1) -} - -var _wrap_Shape_y_set unsafe.Pointer - -func _swig_wrap_Shape_y_set(base SwigcptrShape, _ float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Shape_y_set, _swig_p) - return -} - -func (arg1 SwigcptrShape) SetY(arg2 float64) { - _swig_wrap_Shape_y_set(arg1, arg2) -} - -var _wrap_Shape_y_get unsafe.Pointer - -func _swig_wrap_Shape_y_get(base SwigcptrShape) (_ float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Shape_y_get, _swig_p) - return -} - -func (arg1 SwigcptrShape) GetY() (_swig_ret float64) { - return _swig_wrap_Shape_y_get(arg1) -} - -var _wrap_Shape_z_set unsafe.Pointer - -func _swig_wrap_Shape_z_set(base SwigcptrShape, _ *float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Shape_z_set, _swig_p) - return -} - -func (arg1 SwigcptrShape) SetZ(arg2 *float64) { - _swig_wrap_Shape_z_set(arg1, arg2) -} - -var _wrap_Shape_z_get unsafe.Pointer - -func _swig_wrap_Shape_z_get(base SwigcptrShape) (_ *float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Shape_z_get, _swig_p) - return -} - -func (arg1 SwigcptrShape) GetZ() (_swig_ret *float64) { - return _swig_wrap_Shape_z_get(arg1) -} - -var _wrap_Shape_move unsafe.Pointer - -func _swig_wrap_Shape_move(base SwigcptrShape, _ float64, _ float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Shape_move, _swig_p) - return -} - -func (arg1 SwigcptrShape) Move(arg2 float64, arg3 float64) { - _swig_wrap_Shape_move(arg1, arg2, arg3) -} - -var _wrap_Shape_area unsafe.Pointer - -func _swig_wrap_Shape_area(base SwigcptrShape) (_ float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Shape_area, _swig_p) - return -} - -func (arg1 SwigcptrShape) Area() (_swig_ret float64) { - return _swig_wrap_Shape_area(arg1) -} - -var _wrap_Shape_perimeter unsafe.Pointer - -func _swig_wrap_Shape_perimeter(base SwigcptrShape) (_ float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Shape_perimeter, _swig_p) - return -} - -func (arg1 SwigcptrShape) Perimeter() (_swig_ret float64) { - return _swig_wrap_Shape_perimeter(arg1) -} - -var _wrap_Shape_nshapes_set unsafe.Pointer - -func _swig_wrap_Shape_nshapes_set(base int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Shape_nshapes_set, _swig_p) - return -} - -func SetShapeNshapes(arg1 int) { - _swig_wrap_Shape_nshapes_set(arg1) -} - -var _wrap_Shape_nshapes_get unsafe.Pointer - -func GetShapeNshapes() (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_Shape_nshapes_get, _swig_p) - return -} -type Shape interface { - Swigcptr() uintptr - SwigIsShape() - SetX(arg2 float64) - GetX() (_swig_ret float64) - SetY(arg2 float64) - GetY() (_swig_ret float64) - SetZ(arg2 *float64) - GetZ() (_swig_ret *float64) - Move(arg2 float64, arg3 float64) - Area() (_swig_ret float64) - Perimeter() (_swig_ret float64) -} - -type SwigcptrCircle uintptr - -func (p SwigcptrCircle) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrCircle) SwigIsCircle() { -} - -var _wrap_new_Circle unsafe.Pointer - -func _swig_wrap_new_Circle(base float64) (_ SwigcptrCircle) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Circle, _swig_p) - return -} - -func NewCircle(arg1 float64) (_swig_ret Circle) { - return _swig_wrap_new_Circle(arg1) -} - -var _wrap_Circle_area unsafe.Pointer - -func _swig_wrap_Circle_area(base SwigcptrCircle) (_ float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Circle_area, _swig_p) - return -} - -func (arg1 SwigcptrCircle) Area() (_swig_ret float64) { - return _swig_wrap_Circle_area(arg1) -} - -var _wrap_Circle_perimeter unsafe.Pointer - -func _swig_wrap_Circle_perimeter(base SwigcptrCircle) (_ float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Circle_perimeter, _swig_p) - return -} - -func (arg1 SwigcptrCircle) Perimeter() (_swig_ret float64) { - return _swig_wrap_Circle_perimeter(arg1) -} - -var _wrap_delete_Circle unsafe.Pointer - -func _swig_wrap_delete_Circle(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Circle, _swig_p) - return -} - -func DeleteCircle(arg1 Circle) { - _swig_wrap_delete_Circle(arg1.Swigcptr()) -} - -var _wrap_SetCircle_X unsafe.Pointer - -func _swig_wrap_SetCircle_X(base SwigcptrCircle, _ float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_SetCircle_X, _swig_p) - return -} - -func (_swig_base SwigcptrCircle) SetX(arg1 float64) { - _swig_wrap_SetCircle_X(_swig_base, arg1) -} - -var _wrap_GetCircle_X unsafe.Pointer - -func _swig_wrap_GetCircle_X(base SwigcptrCircle) (_ float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_GetCircle_X, _swig_p) - return -} - -func (_swig_base SwigcptrCircle) GetX() (_swig_ret float64) { - return _swig_wrap_GetCircle_X(_swig_base) -} - -var _wrap_SetCircle_Y unsafe.Pointer - -func _swig_wrap_SetCircle_Y(base SwigcptrCircle, _ float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_SetCircle_Y, _swig_p) - return -} - -func (_swig_base SwigcptrCircle) SetY(arg1 float64) { - _swig_wrap_SetCircle_Y(_swig_base, arg1) -} - -var _wrap_GetCircle_Y unsafe.Pointer - -func _swig_wrap_GetCircle_Y(base SwigcptrCircle) (_ float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_GetCircle_Y, _swig_p) - return -} - -func (_swig_base SwigcptrCircle) GetY() (_swig_ret float64) { - return _swig_wrap_GetCircle_Y(_swig_base) -} - -var _wrap_SetCircle_Z unsafe.Pointer - -func _swig_wrap_SetCircle_Z(base SwigcptrCircle, _ *float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_SetCircle_Z, _swig_p) - return -} - -func (_swig_base SwigcptrCircle) SetZ(arg1 *float64) { - _swig_wrap_SetCircle_Z(_swig_base, arg1) -} - -var _wrap_GetCircle_Z unsafe.Pointer - -func _swig_wrap_GetCircle_Z(base SwigcptrCircle) (_ *float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_GetCircle_Z, _swig_p) - return -} - -func (_swig_base SwigcptrCircle) GetZ() (_swig_ret *float64) { - return _swig_wrap_GetCircle_Z(_swig_base) -} - -var _wrap_Circle_move unsafe.Pointer - -func _swig_wrap_Circle_move(base SwigcptrCircle, _ float64, _ float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Circle_move, _swig_p) - return -} - -func (_swig_base SwigcptrCircle) Move(arg1 float64, arg2 float64) { - _swig_wrap_Circle_move(_swig_base, arg1, arg2) -} - -func (p SwigcptrCircle) SwigIsShape() { -} - -func (p SwigcptrCircle) SwigGetShape() Shape { - return SwigcptrShape(p.Swigcptr()) -} - -type Circle interface { - Swigcptr() uintptr - SwigIsCircle() - Area() (_swig_ret float64) - Perimeter() (_swig_ret float64) - SetX(arg1 float64) - GetX() (_swig_ret float64) - SetY(arg1 float64) - GetY() (_swig_ret float64) - SetZ(arg1 *float64) - GetZ() (_swig_ret *float64) - Move(arg1 float64, arg2 float64) - SwigIsShape() - SwigGetShape() Shape -} - -type SwigcptrSquare uintptr - -func (p SwigcptrSquare) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrSquare) SwigIsSquare() { -} - -var _wrap_new_Square unsafe.Pointer - -func _swig_wrap_new_Square(base float64) (_ SwigcptrSquare) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Square, _swig_p) - return -} - -func NewSquare(arg1 float64) (_swig_ret Square) { - return _swig_wrap_new_Square(arg1) -} - -var _wrap_Square_area unsafe.Pointer - -func _swig_wrap_Square_area(base SwigcptrSquare) (_ float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Square_area, _swig_p) - return -} - -func (arg1 SwigcptrSquare) Area() (_swig_ret float64) { - return _swig_wrap_Square_area(arg1) -} - -var _wrap_Square_perimeter unsafe.Pointer - -func _swig_wrap_Square_perimeter(base SwigcptrSquare) (_ float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Square_perimeter, _swig_p) - return -} - -func (arg1 SwigcptrSquare) Perimeter() (_swig_ret float64) { - return _swig_wrap_Square_perimeter(arg1) -} - -var _wrap_delete_Square unsafe.Pointer - -func _swig_wrap_delete_Square(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Square, _swig_p) - return -} - -func DeleteSquare(arg1 Square) { - _swig_wrap_delete_Square(arg1.Swigcptr()) -} - -var _wrap_SetSquare_X unsafe.Pointer - -func _swig_wrap_SetSquare_X(base SwigcptrSquare, _ float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_SetSquare_X, _swig_p) - return -} - -func (_swig_base SwigcptrSquare) SetX(arg1 float64) { - _swig_wrap_SetSquare_X(_swig_base, arg1) -} - -var _wrap_GetSquare_X unsafe.Pointer - -func _swig_wrap_GetSquare_X(base SwigcptrSquare) (_ float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_GetSquare_X, _swig_p) - return -} - -func (_swig_base SwigcptrSquare) GetX() (_swig_ret float64) { - return _swig_wrap_GetSquare_X(_swig_base) -} - -var _wrap_SetSquare_Y unsafe.Pointer - -func _swig_wrap_SetSquare_Y(base SwigcptrSquare, _ float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_SetSquare_Y, _swig_p) - return -} - -func (_swig_base SwigcptrSquare) SetY(arg1 float64) { - _swig_wrap_SetSquare_Y(_swig_base, arg1) -} - -var _wrap_GetSquare_Y unsafe.Pointer - -func _swig_wrap_GetSquare_Y(base SwigcptrSquare) (_ float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_GetSquare_Y, _swig_p) - return -} - -func (_swig_base SwigcptrSquare) GetY() (_swig_ret float64) { - return _swig_wrap_GetSquare_Y(_swig_base) -} - -var _wrap_SetSquare_Z unsafe.Pointer - -func _swig_wrap_SetSquare_Z(base SwigcptrSquare, _ *float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_SetSquare_Z, _swig_p) - return -} - -func (_swig_base SwigcptrSquare) SetZ(arg1 *float64) { - _swig_wrap_SetSquare_Z(_swig_base, arg1) -} - -var _wrap_GetSquare_Z unsafe.Pointer - -func _swig_wrap_GetSquare_Z(base SwigcptrSquare) (_ *float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_GetSquare_Z, _swig_p) - return -} - -func (_swig_base SwigcptrSquare) GetZ() (_swig_ret *float64) { - return _swig_wrap_GetSquare_Z(_swig_base) -} - -var _wrap_Square_move unsafe.Pointer - -func _swig_wrap_Square_move(base SwigcptrSquare, _ float64, _ float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Square_move, _swig_p) - return -} - -func (_swig_base SwigcptrSquare) Move(arg1 float64, arg2 float64) { - _swig_wrap_Square_move(_swig_base, arg1, arg2) -} - -func (p SwigcptrSquare) SwigIsShape() { -} - -func (p SwigcptrSquare) SwigGetShape() Shape { - return SwigcptrShape(p.Swigcptr()) -} - -type Square interface { - Swigcptr() uintptr - SwigIsSquare() - Area() (_swig_ret float64) - Perimeter() (_swig_ret float64) - SetX(arg1 float64) - GetX() (_swig_ret float64) - SetY(arg1 float64) - GetY() (_swig_ret float64) - SetZ(arg1 *float64) - GetZ() (_swig_ret *float64) - Move(arg1 float64, arg2 float64) - SwigIsShape() - SwigGetShape() Shape -} - -var _wrap_do_op unsafe.Pointer - -func _swig_wrap_do_op(base uintptr, _ _swig_memberptr) (_ float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_do_op, _swig_p) - return -} - -func Do_op(arg1 Shape, arg2 _swig_memberptr) (_swig_ret float64) { - return _swig_wrap_do_op(arg1.Swigcptr(), arg2) -} - -var _wrap_areapt unsafe.Pointer - -func Areapt() (_swig_ret _swig_memberptr) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_areapt, _swig_p) - return -} -var _wrap_perimeterpt unsafe.Pointer - -func Perimeterpt() (_swig_ret _swig_memberptr) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_perimeterpt, _swig_p) - return -} -var _wrap_areavar_set unsafe.Pointer - -func _swig_wrap_areavar_set(base _swig_memberptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_areavar_set, _swig_p) - return -} - -func SetAreavar(arg1 _swig_memberptr) { - _swig_wrap_areavar_set(arg1) -} - -var _wrap_areavar_get unsafe.Pointer - -func GetAreavar() (_swig_ret _swig_memberptr) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_areavar_get, _swig_p) - return -} -var _wrap_perimetervar_set unsafe.Pointer - -func _swig_wrap_perimetervar_set(base _swig_memberptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_perimetervar_set, _swig_p) - return -} - -func SetPerimetervar(arg1 _swig_memberptr) { - _swig_wrap_perimetervar_set(arg1) -} - -var _wrap_perimetervar_get unsafe.Pointer - -func GetPerimetervar() (_swig_ret _swig_memberptr) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_perimetervar_get, _swig_p) - return -} -var _wrap_AREAPT unsafe.Pointer - -func _swig_getAREAPT() (_swig_ret _swig_memberptr) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_AREAPT, _swig_p) - return -} -var AREAPT _swig_memberptr = _swig_getAREAPT() -var _wrap_PERIMPT unsafe.Pointer - -func _swig_getPERIMPT() (_swig_ret _swig_memberptr) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_PERIMPT, _swig_p) - return -} -var PERIMPT _swig_memberptr = _swig_getPERIMPT() -var _wrap_NULLPT unsafe.Pointer - -func _swig_getNULLPT() (_swig_ret _swig_memberptr) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_NULLPT, _swig_p) - return -} -var NULLPT _swig_memberptr = _swig_getNULLPT() -type SwigcptrFunktions uintptr - -func (p SwigcptrFunktions) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrFunktions) SwigIsFunktions() { -} - -var _wrap_Funktions_addByValue unsafe.Pointer - -func _swig_wrap_Funktions_addByValue(base SwigcptrFunktions, _ int, _ int) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Funktions_addByValue, _swig_p) - return -} - -func (arg1 SwigcptrFunktions) AddByValue(arg2 int, arg3 int) (_swig_ret int) { - return _swig_wrap_Funktions_addByValue(arg1, arg2, arg3) -} - -var _wrap_Funktions_addByPointer unsafe.Pointer - -func _swig_wrap_Funktions_addByPointer(base SwigcptrFunktions, _ int, _ int) (_ *int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Funktions_addByPointer, _swig_p) - return -} - -func (arg1 SwigcptrFunktions) AddByPointer(arg2 int, arg3 int) (_swig_ret *int) { - return _swig_wrap_Funktions_addByPointer(arg1, arg2, arg3) -} - -var _wrap_Funktions_addByReference unsafe.Pointer - -func _swig_wrap_Funktions_addByReference(base SwigcptrFunktions, _ int, _ int) (_ *int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Funktions_addByReference, _swig_p) - return -} - -func (arg1 SwigcptrFunktions) AddByReference(arg2 int, arg3 int) (_swig_ret *int) { - return _swig_wrap_Funktions_addByReference(arg1, arg2, arg3) -} - -var _wrap_new_Funktions unsafe.Pointer - -func _swig_wrap_new_Funktions() (base SwigcptrFunktions) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Funktions, _swig_p) - return -} - -func NewFunktions() (_swig_ret Funktions) { - return _swig_wrap_new_Funktions() -} - -var _wrap_delete_Funktions unsafe.Pointer - -func _swig_wrap_delete_Funktions(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Funktions, _swig_p) - return -} - -func DeleteFunktions(arg1 Funktions) { - _swig_wrap_delete_Funktions(arg1.Swigcptr()) -} - -type Funktions interface { - Swigcptr() uintptr - SwigIsFunktions() - AddByValue(arg2 int, arg3 int) (_swig_ret int) - AddByPointer(arg2 int, arg3 int) (_swig_ret *int) - AddByReference(arg2 int, arg3 int) (_swig_ret *int) -} - -var _wrap_call1 unsafe.Pointer - -func Call1(arg1 _swig_memberptr, arg2 int, arg3 int) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_call1, _swig_p) - return -} -var _wrap_call2 unsafe.Pointer - -func Call2(arg1 _swig_memberptr, arg2 int, arg3 int) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_call2, _swig_p) - return -} -var _wrap_call3 unsafe.Pointer - -func Call3(arg1 _swig_memberptr, arg2 int, arg3 int) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_call3, _swig_p) - return -} -var _wrap_ADD_BY_VALUE unsafe.Pointer - -func _swig_getADD_BY_VALUE() (_swig_ret _swig_memberptr) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_ADD_BY_VALUE, _swig_p) - return -} -var ADD_BY_VALUE _swig_memberptr = _swig_getADD_BY_VALUE() -var _wrap_ADD_BY_POINTER unsafe.Pointer - -func _swig_getADD_BY_POINTER() (_swig_ret _swig_memberptr) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_ADD_BY_POINTER, _swig_p) - return -} -var ADD_BY_POINTER _swig_memberptr = _swig_getADD_BY_POINTER() -var _wrap_ADD_BY_REFERENCE unsafe.Pointer - -func _swig_getADD_BY_REFERENCE() (_swig_ret _swig_memberptr) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_ADD_BY_REFERENCE, _swig_p) - return -} -var ADD_BY_REFERENCE _swig_memberptr = _swig_getADD_BY_REFERENCE() - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/member_pointer_runme b/Examples/test-suite/go/member_pointer_runme deleted file mode 100755 index 4260d872e..000000000 Binary files a/Examples/test-suite/go/member_pointer_runme and /dev/null differ diff --git a/Examples/test-suite/go/member_template.go b/Examples/test-suite/go/member_template.go deleted file mode 100644 index a305b50f0..000000000 --- a/Examples/test-suite/go/member_template.go +++ /dev/null @@ -1,165 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../member_template.i - -package member_template - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrFooint uintptr - -func (p SwigcptrFooint) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrFooint) SwigIsFooint() { -} - -var _wrap_Fooint_maxi unsafe.Pointer - -func _swig_wrap_Fooint_maxi(base SwigcptrFooint, _ int, _ int) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Fooint_maxi, _swig_p) - return -} - -func (arg1 SwigcptrFooint) Maxi(arg2 int, arg3 int) (_swig_ret int) { - return _swig_wrap_Fooint_maxi(arg1, arg2, arg3) -} - -var _wrap_Fooint_maxd unsafe.Pointer - -func _swig_wrap_Fooint_maxd(base SwigcptrFooint, _ float64, _ float64) (_ float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Fooint_maxd, _swig_p) - return -} - -func (arg1 SwigcptrFooint) Maxd(arg2 float64, arg3 float64) (_swig_ret float64) { - return _swig_wrap_Fooint_maxd(arg1, arg2, arg3) -} - -var _wrap_new_Fooint unsafe.Pointer - -func _swig_wrap_new_Fooint() (base SwigcptrFooint) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Fooint, _swig_p) - return -} - -func NewFooint() (_swig_ret Fooint) { - return _swig_wrap_new_Fooint() -} - -var _wrap_delete_Fooint unsafe.Pointer - -func _swig_wrap_delete_Fooint(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Fooint, _swig_p) - return -} - -func DeleteFooint(arg1 Fooint) { - _swig_wrap_delete_Fooint(arg1.Swigcptr()) -} - -type Fooint interface { - Swigcptr() uintptr - SwigIsFooint() - Maxi(arg2 int, arg3 int) (_swig_ret int) - Maxd(arg2 float64, arg3 float64) (_swig_ret float64) -} - -type SwigcptrFoodouble uintptr - -func (p SwigcptrFoodouble) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrFoodouble) SwigIsFoodouble() { -} - -var _wrap_Foodouble_maxi unsafe.Pointer - -func _swig_wrap_Foodouble_maxi(base SwigcptrFoodouble, _ int, _ int) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foodouble_maxi, _swig_p) - return -} - -func (arg1 SwigcptrFoodouble) Maxi(arg2 int, arg3 int) (_swig_ret int) { - return _swig_wrap_Foodouble_maxi(arg1, arg2, arg3) -} - -var _wrap_Foodouble_maxd unsafe.Pointer - -func _swig_wrap_Foodouble_maxd(base SwigcptrFoodouble, _ float64, _ float64) (_ float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foodouble_maxd, _swig_p) - return -} - -func (arg1 SwigcptrFoodouble) Maxd(arg2 float64, arg3 float64) (_swig_ret float64) { - return _swig_wrap_Foodouble_maxd(arg1, arg2, arg3) -} - -var _wrap_new_Foodouble unsafe.Pointer - -func _swig_wrap_new_Foodouble() (base SwigcptrFoodouble) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Foodouble, _swig_p) - return -} - -func NewFoodouble() (_swig_ret Foodouble) { - return _swig_wrap_new_Foodouble() -} - -var _wrap_delete_Foodouble unsafe.Pointer - -func _swig_wrap_delete_Foodouble(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Foodouble, _swig_p) - return -} - -func DeleteFoodouble(arg1 Foodouble) { - _swig_wrap_delete_Foodouble(arg1.Swigcptr()) -} - -type Foodouble interface { - Swigcptr() uintptr - SwigIsFoodouble() - Maxi(arg2 int, arg3 int) (_swig_ret int) - Maxd(arg2 float64, arg3 float64) (_swig_ret float64) -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/memberin_extend.go b/Examples/test-suite/go/memberin_extend.go deleted file mode 100644 index de9f51ee3..000000000 --- a/Examples/test-suite/go/memberin_extend.go +++ /dev/null @@ -1,101 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../memberin_extend.i - -package memberin_extend - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrExtendMe uintptr - -func (p SwigcptrExtendMe) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrExtendMe) SwigIsExtendMe() { -} - -var _wrap_ExtendMe_thing_set unsafe.Pointer - -func _swig_wrap_ExtendMe_thing_set(base SwigcptrExtendMe, _ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_ExtendMe_thing_set, _swig_p) - return -} - -func (arg1 SwigcptrExtendMe) SetThing(arg2 string) { - _swig_wrap_ExtendMe_thing_set(arg1, arg2) -} - -var _wrap_ExtendMe_thing_get unsafe.Pointer - -func _swig_wrap_ExtendMe_thing_get(base SwigcptrExtendMe) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_ExtendMe_thing_get, _swig_p) - return -} - -func (arg1 SwigcptrExtendMe) GetThing() (_swig_ret string) { - return _swig_wrap_ExtendMe_thing_get(arg1) -} - -var _wrap_new_ExtendMe unsafe.Pointer - -func _swig_wrap_new_ExtendMe() (base SwigcptrExtendMe) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_ExtendMe, _swig_p) - return -} - -func NewExtendMe() (_swig_ret ExtendMe) { - return _swig_wrap_new_ExtendMe() -} - -var _wrap_delete_ExtendMe unsafe.Pointer - -func _swig_wrap_delete_ExtendMe(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_ExtendMe, _swig_p) - return -} - -func DeleteExtendMe(arg1 ExtendMe) { - _swig_wrap_delete_ExtendMe(arg1.Swigcptr()) -} - -type ExtendMe interface { - Swigcptr() uintptr - SwigIsExtendMe() - SetThing(arg2 string) - GetThing() (_swig_ret string) -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/memberin_extend_c.go b/Examples/test-suite/go/memberin_extend_c.go deleted file mode 100644 index 4f128e9a3..000000000 --- a/Examples/test-suite/go/memberin_extend_c.go +++ /dev/null @@ -1,101 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../memberin_extend_c.i - -package memberin_extend_c - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrPerson uintptr - -func (p SwigcptrPerson) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrPerson) SwigIsPerson() { -} - -var _wrap_Person_name_set unsafe.Pointer - -func _swig_wrap_Person_name_set(base SwigcptrPerson, _ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Person_name_set, _swig_p) - return -} - -func (arg1 SwigcptrPerson) SetName(arg2 string) { - _swig_wrap_Person_name_set(arg1, arg2) -} - -var _wrap_Person_name_get unsafe.Pointer - -func _swig_wrap_Person_name_get(base SwigcptrPerson) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Person_name_get, _swig_p) - return -} - -func (arg1 SwigcptrPerson) GetName() (_swig_ret string) { - return _swig_wrap_Person_name_get(arg1) -} - -var _wrap_new_Person unsafe.Pointer - -func _swig_wrap_new_Person() (base SwigcptrPerson) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Person, _swig_p) - return -} - -func NewPerson() (_swig_ret Person) { - return _swig_wrap_new_Person() -} - -var _wrap_delete_Person unsafe.Pointer - -func _swig_wrap_delete_Person(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Person, _swig_p) - return -} - -func DeletePerson(arg1 Person) { - _swig_wrap_delete_Person(arg1.Swigcptr()) -} - -type Person interface { - Swigcptr() uintptr - SwigIsPerson() - SetName(arg2 string) - GetName() (_swig_ret string) -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/memberin_extend_c_runme b/Examples/test-suite/go/memberin_extend_c_runme deleted file mode 100755 index 6836c2671..000000000 Binary files a/Examples/test-suite/go/memberin_extend_c_runme and /dev/null differ diff --git a/Examples/test-suite/go/minherit.go b/Examples/test-suite/go/minherit.go deleted file mode 100644 index 7c63cc646..000000000 --- a/Examples/test-suite/go/minherit.go +++ /dev/null @@ -1,612 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../minherit.i - -package minherit - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrFoo uintptr - -func (p SwigcptrFoo) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrFoo) SwigIsFoo() { -} - -var _wrap_new_Foo unsafe.Pointer - -func _swig_wrap_new_Foo() (base SwigcptrFoo) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Foo, _swig_p) - return -} - -func NewFoo() (_swig_ret Foo) { - return _swig_wrap_new_Foo() -} - -var _wrap_delete_Foo unsafe.Pointer - -func _swig_wrap_delete_Foo(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Foo, _swig_p) - return -} - -func DeleteFoo(arg1 Foo) { - _swig_wrap_delete_Foo(arg1.Swigcptr()) -} - -var _wrap_Foo_xget unsafe.Pointer - -func _swig_wrap_Foo_xget(base SwigcptrFoo) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_xget, _swig_p) - return -} - -func (arg1 SwigcptrFoo) Xget() (_swig_ret int) { - return _swig_wrap_Foo_xget(arg1) -} - -type Foo interface { - Swigcptr() uintptr - SwigIsFoo() - Xget() (_swig_ret int) -} - -var _wrap_toFooPtr unsafe.Pointer - -func _swig_wrap_toFooPtr(base uintptr) (_ SwigcptrFoo) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_toFooPtr, _swig_p) - return -} - -func ToFooPtr(arg1 Foo) (_swig_ret Foo) { - return _swig_wrap_toFooPtr(arg1.Swigcptr()) -} - -type SwigcptrBar uintptr - -func (p SwigcptrBar) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrBar) SwigIsBar() { -} - -var _wrap_new_Bar unsafe.Pointer - -func _swig_wrap_new_Bar() (base SwigcptrBar) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Bar, _swig_p) - return -} - -func NewBar() (_swig_ret Bar) { - return _swig_wrap_new_Bar() -} - -var _wrap_delete_Bar unsafe.Pointer - -func _swig_wrap_delete_Bar(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Bar, _swig_p) - return -} - -func DeleteBar(arg1 Bar) { - _swig_wrap_delete_Bar(arg1.Swigcptr()) -} - -var _wrap_Bar_yget unsafe.Pointer - -func _swig_wrap_Bar_yget(base SwigcptrBar) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Bar_yget, _swig_p) - return -} - -func (arg1 SwigcptrBar) Yget() (_swig_ret int) { - return _swig_wrap_Bar_yget(arg1) -} - -type Bar interface { - Swigcptr() uintptr - SwigIsBar() - Yget() (_swig_ret int) -} - -var _wrap_toBarPtr unsafe.Pointer - -func _swig_wrap_toBarPtr(base uintptr) (_ SwigcptrBar) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_toBarPtr, _swig_p) - return -} - -func ToBarPtr(arg1 Bar) (_swig_ret Bar) { - return _swig_wrap_toBarPtr(arg1.Swigcptr()) -} - -type SwigcptrFooBar uintptr - -func (p SwigcptrFooBar) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrFooBar) SwigIsFooBar() { -} - -var _wrap_new_FooBar unsafe.Pointer - -func _swig_wrap_new_FooBar() (base SwigcptrFooBar) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_FooBar, _swig_p) - return -} - -func NewFooBar() (_swig_ret FooBar) { - return _swig_wrap_new_FooBar() -} - -var _wrap_FooBar_zget unsafe.Pointer - -func _swig_wrap_FooBar_zget(base SwigcptrFooBar) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_FooBar_zget, _swig_p) - return -} - -func (arg1 SwigcptrFooBar) Zget() (_swig_ret int) { - return _swig_wrap_FooBar_zget(arg1) -} - -var _wrap_delete_FooBar unsafe.Pointer - -func _swig_wrap_delete_FooBar(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_FooBar, _swig_p) - return -} - -func DeleteFooBar(arg1 FooBar) { - _swig_wrap_delete_FooBar(arg1.Swigcptr()) -} - -var _wrap_FooBar_xget unsafe.Pointer - -func _swig_wrap_FooBar_xget(base SwigcptrFooBar) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_FooBar_xget, _swig_p) - return -} - -func (_swig_base SwigcptrFooBar) Xget() (_swig_ret int) { - return _swig_wrap_FooBar_xget(_swig_base) -} - -var _wrap_FooBar_yget unsafe.Pointer - -func _swig_wrap_FooBar_yget(base SwigcptrFooBar) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_FooBar_yget, _swig_p) - return -} - -func (_swig_base SwigcptrFooBar) Yget() (_swig_ret int) { - return _swig_wrap_FooBar_yget(_swig_base) -} - -func (p SwigcptrFooBar) SwigIsFoo() { -} - -func (p SwigcptrFooBar) SwigGetFoo() Foo { - return SwigcptrFoo(p.Swigcptr()) -} - -var _wrap_FooBar_SwigGetBar unsafe.Pointer - -func _swig_wrap_FooBar_SwigGetBar(base SwigcptrFooBar) (_ SwigcptrBar) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_FooBar_SwigGetBar, _swig_p) - return -} - -func (arg1 SwigcptrFooBar) SwigGetBar() (_swig_ret Bar) { - return _swig_wrap_FooBar_SwigGetBar(arg1) -} - -type FooBar interface { - Swigcptr() uintptr - SwigIsFooBar() - Zget() (_swig_ret int) - Xget() (_swig_ret int) - Yget() (_swig_ret int) - SwigIsFoo() - SwigGetFoo() Foo - SwigGetBar() (_swig_ret Bar) -} - -var _wrap_toFooBarPtr unsafe.Pointer - -func _swig_wrap_toFooBarPtr(base uintptr) (_ SwigcptrFooBar) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_toFooBarPtr, _swig_p) - return -} - -func ToFooBarPtr(arg1 FooBar) (_swig_ret FooBar) { - return _swig_wrap_toFooBarPtr(arg1.Swigcptr()) -} - -type SwigcptrSpam uintptr - -func (p SwigcptrSpam) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrSpam) SwigIsSpam() { -} - -var _wrap_new_Spam unsafe.Pointer - -func _swig_wrap_new_Spam() (base SwigcptrSpam) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Spam, _swig_p) - return -} - -func NewSpam() (_swig_ret Spam) { - return _swig_wrap_new_Spam() -} - -var _wrap_Spam_wget unsafe.Pointer - -func _swig_wrap_Spam_wget(base SwigcptrSpam) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Spam_wget, _swig_p) - return -} - -func (arg1 SwigcptrSpam) Wget() (_swig_ret int) { - return _swig_wrap_Spam_wget(arg1) -} - -var _wrap_delete_Spam unsafe.Pointer - -func _swig_wrap_delete_Spam(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Spam, _swig_p) - return -} - -func DeleteSpam(arg1 Spam) { - _swig_wrap_delete_Spam(arg1.Swigcptr()) -} - -var _wrap_Spam_zget unsafe.Pointer - -func _swig_wrap_Spam_zget(base SwigcptrSpam) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Spam_zget, _swig_p) - return -} - -func (_swig_base SwigcptrSpam) Zget() (_swig_ret int) { - return _swig_wrap_Spam_zget(_swig_base) -} - -var _wrap_Spam_xget unsafe.Pointer - -func _swig_wrap_Spam_xget(base SwigcptrSpam) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Spam_xget, _swig_p) - return -} - -func (_swig_base SwigcptrSpam) Xget() (_swig_ret int) { - return _swig_wrap_Spam_xget(_swig_base) -} - -var _wrap_Spam_yget unsafe.Pointer - -func _swig_wrap_Spam_yget(base SwigcptrSpam) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Spam_yget, _swig_p) - return -} - -func (_swig_base SwigcptrSpam) Yget() (_swig_ret int) { - return _swig_wrap_Spam_yget(_swig_base) -} - -func (p SwigcptrSpam) SwigIsFooBar() { -} - -func (p SwigcptrSpam) SwigGetFooBar() FooBar { - return SwigcptrFooBar(p.Swigcptr()) -} - -func (p SwigcptrSpam) SwigIsFoo() { -} - -func (p SwigcptrSpam) SwigGetFoo() Foo { - return SwigcptrFoo(p.Swigcptr()) -} - -func (p SwigcptrSpam) SwigGetBar() Bar { - return p.SwigGetFooBar().SwigGetBar() -} - -type Spam interface { - Swigcptr() uintptr - SwigIsSpam() - Wget() (_swig_ret int) - Zget() (_swig_ret int) - Xget() (_swig_ret int) - Yget() (_swig_ret int) - SwigIsFooBar() - SwigGetFooBar() FooBar - SwigIsFoo() - SwigGetFoo() Foo - SwigGetBar() Bar -} - -var _wrap_toSpamPtr unsafe.Pointer - -func _swig_wrap_toSpamPtr(base uintptr) (_ SwigcptrSpam) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_toSpamPtr, _swig_p) - return -} - -func ToSpamPtr(arg1 Spam) (_swig_ret Spam) { - return _swig_wrap_toSpamPtr(arg1.Swigcptr()) -} - -var _wrap_xget unsafe.Pointer - -func _swig_wrap_xget(base uintptr) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_xget, _swig_p) - return -} - -func Xget(arg1 Foo) (_swig_ret int) { - return _swig_wrap_xget(arg1.Swigcptr()) -} - -var _wrap_yget unsafe.Pointer - -func _swig_wrap_yget(base uintptr) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_yget, _swig_p) - return -} - -func Yget(arg1 Bar) (_swig_ret int) { - return _swig_wrap_yget(arg1.Swigcptr()) -} - -var _wrap_zget unsafe.Pointer - -func _swig_wrap_zget(base uintptr) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_zget, _swig_p) - return -} - -func Zget(arg1 FooBar) (_swig_ret int) { - return _swig_wrap_zget(arg1.Swigcptr()) -} - -var _wrap_wget unsafe.Pointer - -func _swig_wrap_wget(base uintptr) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_wget, _swig_p) - return -} - -func Wget(arg1 Spam) (_swig_ret int) { - return _swig_wrap_wget(arg1.Swigcptr()) -} - -type SwigcptrIntVector uintptr - -func (p SwigcptrIntVector) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrIntVector) SwigIsIntVector() { -} - -var _wrap_new_IntVector__SWIG_0 unsafe.Pointer - -func _swig_wrap_new_IntVector__SWIG_0() (base SwigcptrIntVector) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_IntVector__SWIG_0, _swig_p) - return -} - -func NewIntVector__SWIG_0() (_swig_ret IntVector) { - return _swig_wrap_new_IntVector__SWIG_0() -} - -var _wrap_new_IntVector__SWIG_1 unsafe.Pointer - -func _swig_wrap_new_IntVector__SWIG_1(base int64) (_ SwigcptrIntVector) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_IntVector__SWIG_1, _swig_p) - return -} - -func NewIntVector__SWIG_1(arg1 int64) (_swig_ret IntVector) { - return _swig_wrap_new_IntVector__SWIG_1(arg1) -} - -func NewIntVector(a ...interface{}) IntVector { - argc := len(a) - if argc == 0 { - return NewIntVector__SWIG_0() - } - if argc == 1 { - return NewIntVector__SWIG_1(a[0].(int64)) - } - panic("No match for overloaded function call") -} - -var _wrap_IntVector_size unsafe.Pointer - -func _swig_wrap_IntVector_size(base SwigcptrIntVector) (_ int64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_IntVector_size, _swig_p) - return -} - -func (arg1 SwigcptrIntVector) Size() (_swig_ret int64) { - return _swig_wrap_IntVector_size(arg1) -} - -var _wrap_IntVector_capacity unsafe.Pointer - -func _swig_wrap_IntVector_capacity(base SwigcptrIntVector) (_ int64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_IntVector_capacity, _swig_p) - return -} - -func (arg1 SwigcptrIntVector) Capacity() (_swig_ret int64) { - return _swig_wrap_IntVector_capacity(arg1) -} - -var _wrap_IntVector_reserve unsafe.Pointer - -func _swig_wrap_IntVector_reserve(base SwigcptrIntVector, _ int64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_IntVector_reserve, _swig_p) - return -} - -func (arg1 SwigcptrIntVector) Reserve(arg2 int64) { - _swig_wrap_IntVector_reserve(arg1, arg2) -} - -var _wrap_IntVector_isEmpty unsafe.Pointer - -func _swig_wrap_IntVector_isEmpty(base SwigcptrIntVector) (_ bool) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_IntVector_isEmpty, _swig_p) - return -} - -func (arg1 SwigcptrIntVector) IsEmpty() (_swig_ret bool) { - return _swig_wrap_IntVector_isEmpty(arg1) -} - -var _wrap_IntVector_clear unsafe.Pointer - -func _swig_wrap_IntVector_clear(base SwigcptrIntVector) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_IntVector_clear, _swig_p) - return -} - -func (arg1 SwigcptrIntVector) Clear() { - _swig_wrap_IntVector_clear(arg1) -} - -var _wrap_IntVector_add unsafe.Pointer - -func _swig_wrap_IntVector_add(base SwigcptrIntVector, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_IntVector_add, _swig_p) - return -} - -func (arg1 SwigcptrIntVector) Add(arg2 int) { - _swig_wrap_IntVector_add(arg1, arg2) -} - -var _wrap_IntVector_get unsafe.Pointer - -func _swig_wrap_IntVector_get(base SwigcptrIntVector, _ int) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_IntVector_get, _swig_p) - return -} - -func (arg1 SwigcptrIntVector) Get(arg2 int) (_swig_ret int) { - return _swig_wrap_IntVector_get(arg1, arg2) -} - -var _wrap_IntVector_set unsafe.Pointer - -func _swig_wrap_IntVector_set(base SwigcptrIntVector, _ int, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_IntVector_set, _swig_p) - return -} - -func (arg1 SwigcptrIntVector) Set(arg2 int, arg3 int) { - _swig_wrap_IntVector_set(arg1, arg2, arg3) -} - -var _wrap_delete_IntVector unsafe.Pointer - -func _swig_wrap_delete_IntVector(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_IntVector, _swig_p) - return -} - -func DeleteIntVector(arg1 IntVector) { - _swig_wrap_delete_IntVector(arg1.Swigcptr()) -} - -type IntVector interface { - Swigcptr() uintptr - SwigIsIntVector() - Size() (_swig_ret int64) - Capacity() (_swig_ret int64) - Reserve(arg2 int64) - IsEmpty() (_swig_ret bool) - Clear() - Add(arg2 int) - Get(arg2 int) (_swig_ret int) - Set(arg2 int, arg3 int) -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/minherit2.go b/Examples/test-suite/go/minherit2.go deleted file mode 100644 index cef2d9dce..000000000 --- a/Examples/test-suite/go/minherit2.go +++ /dev/null @@ -1,201 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../minherit2.i - -package minherit2 - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrIRemoteSyncIO uintptr - -func (p SwigcptrIRemoteSyncIO) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrIRemoteSyncIO) SwigIsIRemoteSyncIO() { -} - -var _wrap_delete_IRemoteSyncIO unsafe.Pointer - -func _swig_wrap_delete_IRemoteSyncIO(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_IRemoteSyncIO, _swig_p) - return -} - -func DeleteIRemoteSyncIO(arg1 IRemoteSyncIO) { - _swig_wrap_delete_IRemoteSyncIO(arg1.Swigcptr()) -} - -var _wrap_IRemoteSyncIO_syncmethod unsafe.Pointer - -func _swig_wrap_IRemoteSyncIO_syncmethod(base SwigcptrIRemoteSyncIO) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_IRemoteSyncIO_syncmethod, _swig_p) - return -} - -func (arg1 SwigcptrIRemoteSyncIO) Syncmethod() { - _swig_wrap_IRemoteSyncIO_syncmethod(arg1) -} - -type IRemoteSyncIO interface { - Swigcptr() uintptr - SwigIsIRemoteSyncIO() - Syncmethod() -} - -type SwigcptrIRemoteAsyncIO uintptr - -func (p SwigcptrIRemoteAsyncIO) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrIRemoteAsyncIO) SwigIsIRemoteAsyncIO() { -} - -var _wrap_delete_IRemoteAsyncIO unsafe.Pointer - -func _swig_wrap_delete_IRemoteAsyncIO(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_IRemoteAsyncIO, _swig_p) - return -} - -func DeleteIRemoteAsyncIO(arg1 IRemoteAsyncIO) { - _swig_wrap_delete_IRemoteAsyncIO(arg1.Swigcptr()) -} - -var _wrap_IRemoteAsyncIO_asyncmethod unsafe.Pointer - -func _swig_wrap_IRemoteAsyncIO_asyncmethod(base SwigcptrIRemoteAsyncIO) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_IRemoteAsyncIO_asyncmethod, _swig_p) - return -} - -func (arg1 SwigcptrIRemoteAsyncIO) Asyncmethod() { - _swig_wrap_IRemoteAsyncIO_asyncmethod(arg1) -} - -type IRemoteAsyncIO interface { - Swigcptr() uintptr - SwigIsIRemoteAsyncIO() - Asyncmethod() -} - -type SwigcptrRemoteMpe uintptr - -func (p SwigcptrRemoteMpe) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrRemoteMpe) SwigIsRemoteMpe() { -} - -var _wrap_RemoteMpe_syncmethod unsafe.Pointer - -func _swig_wrap_RemoteMpe_syncmethod(base SwigcptrRemoteMpe) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_RemoteMpe_syncmethod, _swig_p) - return -} - -func (arg1 SwigcptrRemoteMpe) Syncmethod() { - _swig_wrap_RemoteMpe_syncmethod(arg1) -} - -var _wrap_RemoteMpe_asyncmethod unsafe.Pointer - -func _swig_wrap_RemoteMpe_asyncmethod(base SwigcptrRemoteMpe) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_RemoteMpe_asyncmethod, _swig_p) - return -} - -func (arg1 SwigcptrRemoteMpe) Asyncmethod() { - _swig_wrap_RemoteMpe_asyncmethod(arg1) -} - -var _wrap_new_RemoteMpe unsafe.Pointer - -func _swig_wrap_new_RemoteMpe() (base SwigcptrRemoteMpe) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_RemoteMpe, _swig_p) - return -} - -func NewRemoteMpe() (_swig_ret RemoteMpe) { - return _swig_wrap_new_RemoteMpe() -} - -var _wrap_delete_RemoteMpe unsafe.Pointer - -func _swig_wrap_delete_RemoteMpe(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_RemoteMpe, _swig_p) - return -} - -func DeleteRemoteMpe(arg1 RemoteMpe) { - _swig_wrap_delete_RemoteMpe(arg1.Swigcptr()) -} - -func (p SwigcptrRemoteMpe) SwigIsIRemoteSyncIO() { -} - -func (p SwigcptrRemoteMpe) SwigGetIRemoteSyncIO() IRemoteSyncIO { - return SwigcptrIRemoteSyncIO(p.Swigcptr()) -} - -var _wrap_RemoteMpe_SwigGetIRemoteAsyncIO unsafe.Pointer - -func _swig_wrap_RemoteMpe_SwigGetIRemoteAsyncIO(base SwigcptrRemoteMpe) (_ SwigcptrIRemoteAsyncIO) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_RemoteMpe_SwigGetIRemoteAsyncIO, _swig_p) - return -} - -func (arg1 SwigcptrRemoteMpe) SwigGetIRemoteAsyncIO() (_swig_ret IRemoteAsyncIO) { - return _swig_wrap_RemoteMpe_SwigGetIRemoteAsyncIO(arg1) -} - -type RemoteMpe interface { - Swigcptr() uintptr - SwigIsRemoteMpe() - Syncmethod() - Asyncmethod() - SwigIsIRemoteSyncIO() - SwigGetIRemoteSyncIO() IRemoteSyncIO - SwigGetIRemoteAsyncIO() (_swig_ret IRemoteAsyncIO) -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/minherit_runme b/Examples/test-suite/go/minherit_runme deleted file mode 100755 index 69e32c2f4..000000000 Binary files a/Examples/test-suite/go/minherit_runme and /dev/null differ diff --git a/Examples/test-suite/go/mixed_types.go b/Examples/test-suite/go/mixed_types.go deleted file mode 100644 index 635df222e..000000000 --- a/Examples/test-suite/go/mixed_types.go +++ /dev/null @@ -1,839 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../mixed_types.i - -package mixed_types - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -var _wrap_ref_pointer__SWIG_0 unsafe.Pointer - -func Ref_pointer__SWIG_0(arg1 *uintptr) (_swig_ret uintptr) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_ref_pointer__SWIG_0, _swig_p) - return -} -type SwigcptrA uintptr - -func (p SwigcptrA) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrA) SwigIsA() { -} - -var _wrap_new_A unsafe.Pointer - -func _swig_wrap_new_A() (base SwigcptrA) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_A, _swig_p) - return -} - -func NewA() (_swig_ret A) { - return _swig_wrap_new_A() -} - -var _wrap_delete_A unsafe.Pointer - -func _swig_wrap_delete_A(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_A, _swig_p) - return -} - -func DeleteA(arg1 A) { - _swig_wrap_delete_A(arg1.Swigcptr()) -} - -type A interface { - Swigcptr() uintptr - SwigIsA() -} - -var _wrap_ref_pointer__SWIG_1 unsafe.Pointer - -func _swig_wrap_ref_pointer__SWIG_1(base uintptr) (_ SwigcptrA) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_ref_pointer__SWIG_1, _swig_p) - return -} - -func Ref_pointer__SWIG_1(arg1 A) (_swig_ret A) { - return _swig_wrap_ref_pointer__SWIG_1(arg1.Swigcptr()) -} - -func Ref_pointer(a ...interface{}) interface{} { - argc := len(a) - if argc == 1 { - if _, ok := a[0].(*uintptr); !ok { - goto check_1 - } - return Ref_pointer__SWIG_0(a[0].(*uintptr)) - } -check_1: - if argc == 1 { - return Ref_pointer__SWIG_1(a[0].(A)) - } - panic("No match for overloaded function call") -} - -var _wrap_ref_pointer_1 unsafe.Pointer - -func _swig_wrap_ref_pointer_1(base uintptr) (_ SwigcptrA) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_ref_pointer_1, _swig_p) - return -} - -func Ref_pointer_1(arg1 A) (_swig_ret A) { - return _swig_wrap_ref_pointer_1(arg1.Swigcptr()) -} - -var _wrap_pointer_1 unsafe.Pointer - -func _swig_wrap_pointer_1(base uintptr) (_ SwigcptrA) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_pointer_1, _swig_p) - return -} - -func Pointer_1(arg1 A) (_swig_ret A) { - return _swig_wrap_pointer_1(arg1.Swigcptr()) -} - -var _wrap_ref_const unsafe.Pointer - -func _swig_wrap_ref_const(base uintptr) (_ SwigcptrA) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_ref_const, _swig_p) - return -} - -func Ref_const(arg1 A) (_swig_ret A) { - return _swig_wrap_ref_const(arg1.Swigcptr()) -} - -type Hello int -var _wrap_hi unsafe.Pointer - -func _swig_gethi() (_swig_ret Hello) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_hi, _swig_p) - return -} -var Hi Hello = _swig_gethi() -var _wrap_sint unsafe.Pointer - -func Sint(arg1 int) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_sint, _swig_p) - return -} -var _wrap_ref_int unsafe.Pointer - -func Ref_int(arg1 int) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_ref_int, _swig_p) - return -} -var _wrap_senum unsafe.Pointer - -func Senum(arg1 Hello) (_swig_ret Hello) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_senum, _swig_p) - return -} -var _wrap_ref_enum unsafe.Pointer - -func Ref_enum(arg1 *Hello) (_swig_ret *Hello) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_ref_enum, _swig_p) - return -} -var _wrap_rptr_const unsafe.Pointer - -func _swig_wrap_rptr_const(base uintptr) (_ SwigcptrA) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_rptr_const, _swig_p) - return -} - -func Rptr_const(arg1 A) (_swig_ret A) { - return _swig_wrap_rptr_const(arg1.Swigcptr()) -} - -var _wrap_rptr_const2 unsafe.Pointer - -func _swig_wrap_rptr_const2(base uintptr) (_ SwigcptrA) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_rptr_const2, _swig_p) - return -} - -func Rptr_const2(arg1 A) (_swig_ret A) { - return _swig_wrap_rptr_const2(arg1.Swigcptr()) -} - -var _wrap_rptr_void unsafe.Pointer - -func Rptr_void(arg1 *uintptr) (_swig_ret *uintptr) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_rptr_void, _swig_p) - return -} -var _wrap_cref_a unsafe.Pointer - -func _swig_wrap_cref_a(base uintptr) (_ SwigcptrA) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_cref_a, _swig_p) - return -} - -func Cref_a(arg1 A) (_swig_ret A) { - return _swig_wrap_cref_a(arg1.Swigcptr()) -} - -var _wrap_ref_a unsafe.Pointer - -func _swig_wrap_ref_a(base uintptr) (_ SwigcptrA) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_ref_a, _swig_p) - return -} - -func Ref_a(arg1 A) (_swig_ret A) { - return _swig_wrap_ref_a(arg1.Swigcptr()) -} - -var _wrap_test_a unsafe.Pointer - -func Test_a(arg1 string, arg2 string, arg3 string, arg4 string) (_swig_ret string) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_test_a, _swig_p) - return -} -var _wrap_test_b unsafe.Pointer - -func Test_b(arg1 string) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_test_b, _swig_p) - return -} -var _wrap_test_c unsafe.Pointer - -func Test_c(arg1 *string) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_test_c, _swig_p) - return -} -var _wrap_test_d unsafe.Pointer - -func Test_d(arg1 *string) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_test_d, _swig_p) - return -} -var _wrap_test_e unsafe.Pointer - -func _swig_wrap_test_e(base uintptr) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_test_e, _swig_p) - return -} - -func Test_e(arg1 NameT_Sl_char_Sg_) (_swig_ret int) { - return _swig_wrap_test_e(arg1.Swigcptr()) -} - -var _wrap_test_f unsafe.Pointer - -func _swig_wrap_test_f(base uintptr) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_test_f, _swig_p) - return -} - -func Test_f(arg1 NameT_Sl_char_Sg_) (_swig_ret int) { - return _swig_wrap_test_f(arg1.Swigcptr()) -} - -var _wrap_test_g unsafe.Pointer - -func _swig_wrap_test_g(base uintptr) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_test_g, _swig_p) - return -} - -func Test_g(arg1 NameT_Sl_char_Sg_) (_swig_ret int) { - return _swig_wrap_test_g(arg1.Swigcptr()) -} - -type SwigcptrFoo uintptr - -func (p SwigcptrFoo) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrFoo) SwigIsFoo() { -} - -var _wrap_Foo_foo unsafe.Pointer - -func _swig_wrap_Foo_foo(base SwigcptrFoo, _ uintptr) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_foo, _swig_p) - return -} - -func (arg1 SwigcptrFoo) Foo(arg2 A) (_swig_ret int) { - return _swig_wrap_Foo_foo(arg1, arg2.Swigcptr()) -} - -var _wrap_Foo_foon unsafe.Pointer - -func _swig_wrap_Foo_foon(base SwigcptrFoo, _ *string) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_foon, _swig_p) - return -} - -func (arg1 SwigcptrFoo) Foon(arg2 *string) (_swig_ret int) { - return _swig_wrap_Foo_foon(arg1, arg2) -} - -var _wrap_new_Foo unsafe.Pointer - -func _swig_wrap_new_Foo() (base SwigcptrFoo) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Foo, _swig_p) - return -} - -func NewFoo() (_swig_ret Foo) { - return _swig_wrap_new_Foo() -} - -var _wrap_delete_Foo unsafe.Pointer - -func _swig_wrap_delete_Foo(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Foo, _swig_p) - return -} - -func DeleteFoo(arg1 Foo) { - _swig_wrap_delete_Foo(arg1.Swigcptr()) -} - -type Foo interface { - Swigcptr() uintptr - SwigIsFoo() - Foo(arg2 A) (_swig_ret int) - Foon(arg2 *string) (_swig_ret int) -} - -const ARRAY_LEN_X int = 2 -const ARRAY_LEN_Y int = 4 -type Finger int -var _wrap_One unsafe.Pointer - -func _swig_getOne() (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_One, _swig_p) - return -} -var One int = _swig_getOne() -var _wrap_Two unsafe.Pointer - -func _swig_getTwo() (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_Two, _swig_p) - return -} -var Two int = _swig_getTwo() -var _wrap_Three unsafe.Pointer - -func _swig_getThree() (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_Three, _swig_p) - return -} -var Three int = _swig_getThree() -var _wrap_Four unsafe.Pointer - -func _swig_getFour() (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_Four, _swig_p) - return -} -var Four int = _swig_getFour() -var _wrap_Five unsafe.Pointer - -func _swig_getFive() (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_Five, _swig_p) - return -} -var Five int = _swig_getFive() -type SwigcptrSimpleStruct uintptr - -func (p SwigcptrSimpleStruct) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrSimpleStruct) SwigIsSimpleStruct() { -} - -var _wrap_SimpleStruct_double_field_set unsafe.Pointer - -func _swig_wrap_SimpleStruct_double_field_set(base SwigcptrSimpleStruct, _ float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_SimpleStruct_double_field_set, _swig_p) - return -} - -func (arg1 SwigcptrSimpleStruct) SetDouble_field(arg2 float64) { - _swig_wrap_SimpleStruct_double_field_set(arg1, arg2) -} - -var _wrap_SimpleStruct_double_field_get unsafe.Pointer - -func _swig_wrap_SimpleStruct_double_field_get(base SwigcptrSimpleStruct) (_ float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_SimpleStruct_double_field_get, _swig_p) - return -} - -func (arg1 SwigcptrSimpleStruct) GetDouble_field() (_swig_ret float64) { - return _swig_wrap_SimpleStruct_double_field_get(arg1) -} - -var _wrap_new_SimpleStruct unsafe.Pointer - -func _swig_wrap_new_SimpleStruct() (base SwigcptrSimpleStruct) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_SimpleStruct, _swig_p) - return -} - -func NewSimpleStruct() (_swig_ret SimpleStruct) { - return _swig_wrap_new_SimpleStruct() -} - -var _wrap_delete_SimpleStruct unsafe.Pointer - -func _swig_wrap_delete_SimpleStruct(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_SimpleStruct, _swig_p) - return -} - -func DeleteSimpleStruct(arg1 SimpleStruct) { - _swig_wrap_delete_SimpleStruct(arg1.Swigcptr()) -} - -type SimpleStruct interface { - Swigcptr() uintptr - SwigIsSimpleStruct() - SetDouble_field(arg2 float64) - GetDouble_field() (_swig_ret float64) -} - -var _wrap_array_c_set unsafe.Pointer - -func _swig_wrap_array_c_set(base *string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_array_c_set, _swig_p) - return -} - -func SetArray_c(arg1 *string) { - _swig_wrap_array_c_set(arg1) -} - -var _wrap_array_c_get unsafe.Pointer - -func GetArray_c() (_swig_ret *string) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_array_c_get, _swig_p) - return -} -var _wrap_array_sc_set unsafe.Pointer - -func _swig_wrap_array_sc_set(base *string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_array_sc_set, _swig_p) - return -} - -func SetArray_sc(arg1 *string) { - _swig_wrap_array_sc_set(arg1) -} - -var _wrap_array_sc_get unsafe.Pointer - -func GetArray_sc() (_swig_ret *string) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_array_sc_get, _swig_p) - return -} -var _wrap_array_uc_set unsafe.Pointer - -func _swig_wrap_array_uc_set(base *string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_array_uc_set, _swig_p) - return -} - -func SetArray_uc(arg1 *string) { - _swig_wrap_array_uc_set(arg1) -} - -var _wrap_array_uc_get unsafe.Pointer - -func GetArray_uc() (_swig_ret *string) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_array_uc_get, _swig_p) - return -} -var _wrap_array_s_set unsafe.Pointer - -func _swig_wrap_array_s_set(base **int16) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_array_s_set, _swig_p) - return -} - -func SetArray_s(arg1 **int16) { - _swig_wrap_array_s_set(arg1) -} - -var _wrap_array_s_get unsafe.Pointer - -func GetArray_s() (_swig_ret **int16) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_array_s_get, _swig_p) - return -} -var _wrap_array_us_set unsafe.Pointer - -func _swig_wrap_array_us_set(base **uint16) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_array_us_set, _swig_p) - return -} - -func SetArray_us(arg1 **uint16) { - _swig_wrap_array_us_set(arg1) -} - -var _wrap_array_us_get unsafe.Pointer - -func GetArray_us() (_swig_ret **uint16) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_array_us_get, _swig_p) - return -} -var _wrap_array_i_set unsafe.Pointer - -func _swig_wrap_array_i_set(base **int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_array_i_set, _swig_p) - return -} - -func SetArray_i(arg1 **int) { - _swig_wrap_array_i_set(arg1) -} - -var _wrap_array_i_get unsafe.Pointer - -func GetArray_i() (_swig_ret **int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_array_i_get, _swig_p) - return -} -var _wrap_array_ui_set unsafe.Pointer - -func _swig_wrap_array_ui_set(base **uint) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_array_ui_set, _swig_p) - return -} - -func SetArray_ui(arg1 **uint) { - _swig_wrap_array_ui_set(arg1) -} - -var _wrap_array_ui_get unsafe.Pointer - -func GetArray_ui() (_swig_ret **uint) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_array_ui_get, _swig_p) - return -} -var _wrap_array_l_set unsafe.Pointer - -func _swig_wrap_array_l_set(base **int64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_array_l_set, _swig_p) - return -} - -func SetArray_l(arg1 **int64) { - _swig_wrap_array_l_set(arg1) -} - -var _wrap_array_l_get unsafe.Pointer - -func GetArray_l() (_swig_ret **int64) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_array_l_get, _swig_p) - return -} -var _wrap_array_ul_set unsafe.Pointer - -func _swig_wrap_array_ul_set(base **uint64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_array_ul_set, _swig_p) - return -} - -func SetArray_ul(arg1 **uint64) { - _swig_wrap_array_ul_set(arg1) -} - -var _wrap_array_ul_get unsafe.Pointer - -func GetArray_ul() (_swig_ret **uint64) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_array_ul_get, _swig_p) - return -} -var _wrap_array_ll_set unsafe.Pointer - -func _swig_wrap_array_ll_set(base **int64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_array_ll_set, _swig_p) - return -} - -func SetArray_ll(arg1 **int64) { - _swig_wrap_array_ll_set(arg1) -} - -var _wrap_array_ll_get unsafe.Pointer - -func GetArray_ll() (_swig_ret **int64) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_array_ll_get, _swig_p) - return -} -var _wrap_array_f_set unsafe.Pointer - -func _swig_wrap_array_f_set(base **float32) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_array_f_set, _swig_p) - return -} - -func SetArray_f(arg1 **float32) { - _swig_wrap_array_f_set(arg1) -} - -var _wrap_array_f_get unsafe.Pointer - -func GetArray_f() (_swig_ret **float32) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_array_f_get, _swig_p) - return -} -var _wrap_array_d_set unsafe.Pointer - -func _swig_wrap_array_d_set(base **float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_array_d_set, _swig_p) - return -} - -func SetArray_d(arg1 **float64) { - _swig_wrap_array_d_set(arg1) -} - -var _wrap_array_d_get unsafe.Pointer - -func GetArray_d() (_swig_ret **float64) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_array_d_get, _swig_p) - return -} -var _wrap_array_struct_set unsafe.Pointer - -func _swig_wrap_array_struct_set(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_array_struct_set, _swig_p) - return -} - -func SetArray_struct(arg1 SimpleStruct) { - _swig_wrap_array_struct_set(arg1.Swigcptr()) -} - -var _wrap_array_struct_get unsafe.Pointer - -func _swig_wrap_array_struct_get() (base SwigcptrSimpleStruct) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_array_struct_get, _swig_p) - return -} - -func GetArray_struct() (_swig_ret SimpleStruct) { - return _swig_wrap_array_struct_get() -} - -var _wrap_array_structpointers_set unsafe.Pointer - -func _swig_wrap_array_structpointers_set(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_array_structpointers_set, _swig_p) - return -} - -func SetArray_structpointers(arg1 SimpleStruct) { - _swig_wrap_array_structpointers_set(arg1.Swigcptr()) -} - -var _wrap_array_structpointers_get unsafe.Pointer - -func _swig_wrap_array_structpointers_get() (base SwigcptrSimpleStruct) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_array_structpointers_get, _swig_p) - return -} - -func GetArray_structpointers() (_swig_ret SimpleStruct) { - return _swig_wrap_array_structpointers_get() -} - -var _wrap_array_ipointers_set unsafe.Pointer - -func _swig_wrap_array_ipointers_set(base ***int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_array_ipointers_set, _swig_p) - return -} - -func SetArray_ipointers(arg1 ***int) { - _swig_wrap_array_ipointers_set(arg1) -} - -var _wrap_array_ipointers_get unsafe.Pointer - -func GetArray_ipointers() (_swig_ret ***int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_array_ipointers_get, _swig_p) - return -} -var _wrap_array_enum_set unsafe.Pointer - -func _swig_wrap_array_enum_set(base **Finger) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_array_enum_set, _swig_p) - return -} - -func SetArray_enum(arg1 **Finger) { - _swig_wrap_array_enum_set(arg1) -} - -var _wrap_array_enum_get unsafe.Pointer - -func GetArray_enum() (_swig_ret **Finger) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_array_enum_get, _swig_p) - return -} -var _wrap_array_enumpointers_set unsafe.Pointer - -func _swig_wrap_array_enumpointers_set(base ***Finger) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_array_enumpointers_set, _swig_p) - return -} - -func SetArray_enumpointers(arg1 ***Finger) { - _swig_wrap_array_enumpointers_set(arg1) -} - -var _wrap_array_enumpointers_get unsafe.Pointer - -func GetArray_enumpointers() (_swig_ret ***Finger) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_array_enumpointers_get, _swig_p) - return -} -var _wrap_array_const_i_get unsafe.Pointer - -func GetArray_const_i() (_swig_ret **int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_array_const_i_get, _swig_p) - return -} -var _wrap_fn_taking_arrays unsafe.Pointer - -func _swig_wrap_fn_taking_arrays(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_fn_taking_arrays, _swig_p) - return -} - -func Fn_taking_arrays(arg1 SimpleStruct) { - _swig_wrap_fn_taking_arrays(arg1.Swigcptr()) -} - -var _wrap_get_2d_array unsafe.Pointer - -func Get_2d_array(arg1 **int, arg2 int, arg3 int) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_get_2d_array, _swig_p) - return -} - -type SwigcptrNameT_Sl_char_Sg_ uintptr -type NameT_Sl_char_Sg_ interface { - Swigcptr() uintptr; -} -func (p SwigcptrNameT_Sl_char_Sg_) Swigcptr() uintptr { - return uintptr(p) -} - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/mod_a.go b/Examples/test-suite/go/mod_a.go deleted file mode 100644 index 8ca8c58e5..000000000 --- a/Examples/test-suite/go/mod_a.go +++ /dev/null @@ -1,182 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../mod_a.i - -package mod_a - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrA uintptr - -func (p SwigcptrA) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrA) SwigIsA() { -} - -var _wrap_new_A unsafe.Pointer - -func _swig_wrap_new_A() (base SwigcptrA) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_A, _swig_p) - return -} - -func NewA() (_swig_ret A) { - return _swig_wrap_new_A() -} - -var _wrap_A_GetC unsafe.Pointer - -func _swig_wrap_A_GetC(base SwigcptrA) (_ SwigcptrC) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_A_GetC, _swig_p) - return -} - -func (arg1 SwigcptrA) GetC() (_swig_ret C) { - return _swig_wrap_A_GetC(arg1) -} - -var _wrap_A_DoSomething unsafe.Pointer - -func _swig_wrap_A_DoSomething(base SwigcptrA, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_A_DoSomething, _swig_p) - return -} - -func (arg1 SwigcptrA) DoSomething(arg2 A) { - _swig_wrap_A_DoSomething(arg1, arg2.Swigcptr()) -} - -var _wrap_delete_A unsafe.Pointer - -func _swig_wrap_delete_A(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_A, _swig_p) - return -} - -func DeleteA(arg1 A) { - _swig_wrap_delete_A(arg1.Swigcptr()) -} - -type A interface { - Swigcptr() uintptr - SwigIsA() - GetC() (_swig_ret C) - DoSomething(arg2 A) -} - -type SwigcptrB uintptr - -func (p SwigcptrB) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrB) SwigIsB() { -} - -var _wrap_new_B unsafe.Pointer - -func _swig_wrap_new_B() (base SwigcptrB) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_B, _swig_p) - return -} - -func NewB() (_swig_ret B) { - return _swig_wrap_new_B() -} - -var _wrap_delete_B unsafe.Pointer - -func _swig_wrap_delete_B(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_B, _swig_p) - return -} - -func DeleteB(arg1 B) { - _swig_wrap_delete_B(arg1.Swigcptr()) -} - -var _wrap_B_GetC unsafe.Pointer - -func _swig_wrap_B_GetC(base SwigcptrB) (_ SwigcptrC) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_B_GetC, _swig_p) - return -} - -func (_swig_base SwigcptrB) GetC() (_swig_ret C) { - return _swig_wrap_B_GetC(_swig_base) -} - -var _wrap_B_DoSomething unsafe.Pointer - -func _swig_wrap_B_DoSomething(base SwigcptrB, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_B_DoSomething, _swig_p) - return -} - -func (_swig_base SwigcptrB) DoSomething(arg1 A) { - _swig_wrap_B_DoSomething(_swig_base, arg1.Swigcptr()) -} - -func (p SwigcptrB) SwigIsA() { -} - -func (p SwigcptrB) SwigGetA() A { - return SwigcptrA(p.Swigcptr()) -} - -type B interface { - Swigcptr() uintptr - SwigIsB() - GetC() (_swig_ret C) - DoSomething(arg1 A) - SwigIsA() - SwigGetA() A -} - - -type SwigcptrC uintptr -type C interface { - Swigcptr() uintptr; -} -func (p SwigcptrC) Swigcptr() uintptr { - return uintptr(p) -} - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/mod_b.go b/Examples/test-suite/go/mod_b.go deleted file mode 100644 index dcd2cddf5..000000000 --- a/Examples/test-suite/go/mod_b.go +++ /dev/null @@ -1,211 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../mod_b.i - -package mod_b - -import "unsafe" -import _ "runtime/cgo" -import "mod_a" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrC uintptr - -func (p SwigcptrC) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrC) SwigIsC() { -} - -var _wrap_new_C unsafe.Pointer - -func _swig_wrap_new_C() (base SwigcptrC) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_C, _swig_p) - return -} - -func NewC() (_swig_ret C) { - return _swig_wrap_new_C() -} - -var _wrap_delete_C unsafe.Pointer - -func _swig_wrap_delete_C(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_C, _swig_p) - return -} - -func DeleteC(arg1 C) { - _swig_wrap_delete_C(arg1.Swigcptr()) -} - -var _wrap_C_GetC unsafe.Pointer - -func _swig_wrap_C_GetC(base SwigcptrC) (_ SwigcptrC) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_C_GetC, _swig_p) - return -} - -func (_swig_base SwigcptrC) GetC() (_swig_ret C) { - return _swig_wrap_C_GetC(_swig_base) -} - -var _wrap_C_DoSomething unsafe.Pointer - -func _swig_wrap_C_DoSomething(base SwigcptrC, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_C_DoSomething, _swig_p) - return -} - -func (_swig_base SwigcptrC) DoSomething(arg1 mod_a.A) { - _swig_wrap_C_DoSomething(_swig_base, arg1.Swigcptr()) -} - -func (p SwigcptrC) SwigIsB() { -} - -func (p SwigcptrC) SwigGetB() mod_a.B { - return mod_a.SwigcptrB(p.Swigcptr()) -} - -func (p SwigcptrC) SwigIsA() { -} - -func (p SwigcptrC) SwigGetA() mod_a.A { - return mod_a.SwigcptrA(p.Swigcptr()) -} - -type C interface { - Swigcptr() uintptr - SwigIsC() - GetC() (_swig_ret C) - DoSomething(arg1 mod_a.A) - SwigIsB() - SwigGetB() mod_a.B - SwigIsA() - SwigGetA() mod_a.A -} - -type SwigcptrD uintptr - -func (p SwigcptrD) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrD) SwigIsD() { -} - -var _wrap_new_D unsafe.Pointer - -func _swig_wrap_new_D() (base SwigcptrD) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_D, _swig_p) - return -} - -func NewD() (_swig_ret D) { - return _swig_wrap_new_D() -} - -var _wrap_delete_D unsafe.Pointer - -func _swig_wrap_delete_D(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_D, _swig_p) - return -} - -func DeleteD(arg1 D) { - _swig_wrap_delete_D(arg1.Swigcptr()) -} - -var _wrap_D_GetC unsafe.Pointer - -func _swig_wrap_D_GetC(base SwigcptrD) (_ SwigcptrC) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_D_GetC, _swig_p) - return -} - -func (_swig_base SwigcptrD) GetC() (_swig_ret C) { - return _swig_wrap_D_GetC(_swig_base) -} - -var _wrap_D_DoSomething unsafe.Pointer - -func _swig_wrap_D_DoSomething(base SwigcptrD, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_D_DoSomething, _swig_p) - return -} - -func (_swig_base SwigcptrD) DoSomething(arg1 mod_a.A) { - _swig_wrap_D_DoSomething(_swig_base, arg1.Swigcptr()) -} - -func (p SwigcptrD) SwigIsC() { -} - -func (p SwigcptrD) SwigGetC() C { - return SwigcptrC(p.Swigcptr()) -} - -func (p SwigcptrD) SwigIsB() { -} - -func (p SwigcptrD) SwigGetB() mod_a.B { - return mod_a.SwigcptrB(p.Swigcptr()) -} - -func (p SwigcptrD) SwigIsA() { -} - -func (p SwigcptrD) SwigGetA() mod_a.A { - return mod_a.SwigcptrA(p.Swigcptr()) -} - -type D interface { - Swigcptr() uintptr - SwigIsD() - GetC() (_swig_ret C) - DoSomething(arg1 mod_a.A) - SwigIsC() - SwigGetC() C - SwigIsB() - SwigGetB() mod_a.B - SwigIsA() - SwigGetA() mod_a.A -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/mod_runme b/Examples/test-suite/go/mod_runme deleted file mode 100755 index 462d85c55..000000000 Binary files a/Examples/test-suite/go/mod_runme and /dev/null differ diff --git a/Examples/test-suite/go/multi_import_a.go b/Examples/test-suite/go/multi_import_a.go deleted file mode 100644 index 0de4ce7a7..000000000 --- a/Examples/test-suite/go/multi_import_a.go +++ /dev/null @@ -1,111 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../multi_import_a.i - -package multi_import_a - -import "unsafe" -import _ "runtime/cgo" -import "multi_import_b" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrZZZ uintptr - -func (p SwigcptrZZZ) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrZZZ) SwigIsZZZ() { -} - -var _wrap_ZZZ_testz unsafe.Pointer - -func _swig_wrap_ZZZ_testz(base SwigcptrZZZ) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_ZZZ_testz, _swig_p) - return -} - -func (arg1 SwigcptrZZZ) Testz() (_swig_ret int) { - return _swig_wrap_ZZZ_testz(arg1) -} - -var _wrap_new_ZZZ unsafe.Pointer - -func _swig_wrap_new_ZZZ() (base SwigcptrZZZ) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_ZZZ, _swig_p) - return -} - -func NewZZZ() (_swig_ret ZZZ) { - return _swig_wrap_new_ZZZ() -} - -var _wrap_delete_ZZZ unsafe.Pointer - -func _swig_wrap_delete_ZZZ(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_ZZZ, _swig_p) - return -} - -func DeleteZZZ(arg1 ZZZ) { - _swig_wrap_delete_ZZZ(arg1.Swigcptr()) -} - -var _wrap_ZZZ_testx unsafe.Pointer - -func _swig_wrap_ZZZ_testx(base SwigcptrZZZ) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_ZZZ_testx, _swig_p) - return -} - -func (_swig_base SwigcptrZZZ) Testx() (_swig_ret int) { - return _swig_wrap_ZZZ_testx(_swig_base) -} - -func (p SwigcptrZZZ) SwigIsXXX() { -} - -func (p SwigcptrZZZ) SwigGetXXX() multi_import_b.XXX { - return multi_import_b.SwigcptrXXX(p.Swigcptr()) -} - -type ZZZ interface { - Swigcptr() uintptr - SwigIsZZZ() - Testz() (_swig_ret int) - Testx() (_swig_ret int) - SwigIsXXX() - SwigGetXXX() multi_import_b.XXX -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/multi_import_b.go b/Examples/test-suite/go/multi_import_b.go deleted file mode 100644 index 7b3f1e142..000000000 --- a/Examples/test-suite/go/multi_import_b.go +++ /dev/null @@ -1,161 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../multi_import_b.i - -package multi_import_b - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrXXX uintptr - -func (p SwigcptrXXX) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrXXX) SwigIsXXX() { -} - -var _wrap_XXX_testx unsafe.Pointer - -func _swig_wrap_XXX_testx(base SwigcptrXXX) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_XXX_testx, _swig_p) - return -} - -func (arg1 SwigcptrXXX) Testx() (_swig_ret int) { - return _swig_wrap_XXX_testx(arg1) -} - -var _wrap_new_XXX unsafe.Pointer - -func _swig_wrap_new_XXX() (base SwigcptrXXX) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_XXX, _swig_p) - return -} - -func NewXXX() (_swig_ret XXX) { - return _swig_wrap_new_XXX() -} - -var _wrap_delete_XXX unsafe.Pointer - -func _swig_wrap_delete_XXX(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_XXX, _swig_p) - return -} - -func DeleteXXX(arg1 XXX) { - _swig_wrap_delete_XXX(arg1.Swigcptr()) -} - -type XXX interface { - Swigcptr() uintptr - SwigIsXXX() - Testx() (_swig_ret int) -} - -type SwigcptrYYY uintptr - -func (p SwigcptrYYY) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrYYY) SwigIsYYY() { -} - -var _wrap_YYY_testy unsafe.Pointer - -func _swig_wrap_YYY_testy(base SwigcptrYYY) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_YYY_testy, _swig_p) - return -} - -func (arg1 SwigcptrYYY) Testy() (_swig_ret int) { - return _swig_wrap_YYY_testy(arg1) -} - -var _wrap_new_YYY unsafe.Pointer - -func _swig_wrap_new_YYY() (base SwigcptrYYY) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_YYY, _swig_p) - return -} - -func NewYYY() (_swig_ret YYY) { - return _swig_wrap_new_YYY() -} - -var _wrap_delete_YYY unsafe.Pointer - -func _swig_wrap_delete_YYY(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_YYY, _swig_p) - return -} - -func DeleteYYY(arg1 YYY) { - _swig_wrap_delete_YYY(arg1.Swigcptr()) -} - -var _wrap_YYY_testx unsafe.Pointer - -func _swig_wrap_YYY_testx(base SwigcptrYYY) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_YYY_testx, _swig_p) - return -} - -func (_swig_base SwigcptrYYY) Testx() (_swig_ret int) { - return _swig_wrap_YYY_testx(_swig_base) -} - -func (p SwigcptrYYY) SwigIsXXX() { -} - -func (p SwigcptrYYY) SwigGetXXX() XXX { - return SwigcptrXXX(p.Swigcptr()) -} - -type YYY interface { - Swigcptr() uintptr - SwigIsYYY() - Testy() (_swig_ret int) - Testx() (_swig_ret int) - SwigIsXXX() - SwigGetXXX() XXX -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/multi_import_runme b/Examples/test-suite/go/multi_import_runme deleted file mode 100755 index 496623d1b..000000000 Binary files a/Examples/test-suite/go/multi_import_runme and /dev/null differ diff --git a/Examples/test-suite/go/multiple_inheritance.go b/Examples/test-suite/go/multiple_inheritance.go deleted file mode 100644 index aefc76ceb..000000000 --- a/Examples/test-suite/go/multiple_inheritance.go +++ /dev/null @@ -1,718 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../multiple_inheritance.i - -package multiple_inheritance - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrBar uintptr - -func (p SwigcptrBar) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrBar) SwigIsBar() { -} - -var _wrap_delete_Bar unsafe.Pointer - -func _swig_wrap_delete_Bar(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Bar, _swig_p) - return -} - -func DeleteBar(arg1 Bar) { - _swig_wrap_delete_Bar(arg1.Swigcptr()) -} - -var _wrap_Bar_bar unsafe.Pointer - -func _swig_wrap_Bar_bar(base SwigcptrBar) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Bar_bar, _swig_p) - return -} - -func (arg1 SwigcptrBar) Bar() (_swig_ret int) { - return _swig_wrap_Bar_bar(arg1) -} - -var _wrap_new_Bar unsafe.Pointer - -func _swig_wrap_new_Bar() (base SwigcptrBar) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Bar, _swig_p) - return -} - -func NewBar() (_swig_ret Bar) { - return _swig_wrap_new_Bar() -} - -type Bar interface { - Swigcptr() uintptr - SwigIsBar() - Bar() (_swig_ret int) -} - -type SwigcptrFoo uintptr - -func (p SwigcptrFoo) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrFoo) SwigIsFoo() { -} - -var _wrap_delete_Foo unsafe.Pointer - -func _swig_wrap_delete_Foo(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Foo, _swig_p) - return -} - -func DeleteFoo(arg1 Foo) { - _swig_wrap_delete_Foo(arg1.Swigcptr()) -} - -var _wrap_Foo_foo unsafe.Pointer - -func _swig_wrap_Foo_foo(base SwigcptrFoo) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_foo, _swig_p) - return -} - -func (arg1 SwigcptrFoo) Foo() (_swig_ret int) { - return _swig_wrap_Foo_foo(arg1) -} - -var _wrap_new_Foo unsafe.Pointer - -func _swig_wrap_new_Foo() (base SwigcptrFoo) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Foo, _swig_p) - return -} - -func NewFoo() (_swig_ret Foo) { - return _swig_wrap_new_Foo() -} - -type Foo interface { - Swigcptr() uintptr - SwigIsFoo() - Foo() (_swig_ret int) -} - -type SwigcptrSpamInt uintptr - -func (p SwigcptrSpamInt) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrSpamInt) SwigIsSpamInt() { -} - -var _wrap_delete_SpamInt unsafe.Pointer - -func _swig_wrap_delete_SpamInt(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_SpamInt, _swig_p) - return -} - -func DeleteSpamInt(arg1 SpamInt) { - _swig_wrap_delete_SpamInt(arg1.Swigcptr()) -} - -var _wrap_SpamInt_spam unsafe.Pointer - -func _swig_wrap_SpamInt_spam(base SwigcptrSpamInt, _ int) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_SpamInt_spam, _swig_p) - return -} - -func (arg1 SwigcptrSpamInt) Spam(arg2 int) (_swig_ret int) { - return _swig_wrap_SpamInt_spam(arg1, arg2) -} - -var _wrap_new_SpamInt unsafe.Pointer - -func _swig_wrap_new_SpamInt() (base SwigcptrSpamInt) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_SpamInt, _swig_p) - return -} - -func NewSpamInt() (_swig_ret SpamInt) { - return _swig_wrap_new_SpamInt() -} - -type SpamInt interface { - Swigcptr() uintptr - SwigIsSpamInt() - Spam(arg2 int) (_swig_ret int) -} - -type SwigcptrFooBar uintptr - -func (p SwigcptrFooBar) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrFooBar) SwigIsFooBar() { -} - -var _wrap_FooBar_fooBar unsafe.Pointer - -func _swig_wrap_FooBar_fooBar(base SwigcptrFooBar) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_FooBar_fooBar, _swig_p) - return -} - -func (arg1 SwigcptrFooBar) FooBar() (_swig_ret int) { - return _swig_wrap_FooBar_fooBar(arg1) -} - -var _wrap_new_FooBar unsafe.Pointer - -func _swig_wrap_new_FooBar() (base SwigcptrFooBar) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_FooBar, _swig_p) - return -} - -func NewFooBar() (_swig_ret FooBar) { - return _swig_wrap_new_FooBar() -} - -var _wrap_delete_FooBar unsafe.Pointer - -func _swig_wrap_delete_FooBar(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_FooBar, _swig_p) - return -} - -func DeleteFooBar(arg1 FooBar) { - _swig_wrap_delete_FooBar(arg1.Swigcptr()) -} - -var _wrap_FooBar_foo unsafe.Pointer - -func _swig_wrap_FooBar_foo(base SwigcptrFooBar) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_FooBar_foo, _swig_p) - return -} - -func (_swig_base SwigcptrFooBar) Foo() (_swig_ret int) { - return _swig_wrap_FooBar_foo(_swig_base) -} - -var _wrap_FooBar_bar unsafe.Pointer - -func _swig_wrap_FooBar_bar(base SwigcptrFooBar) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_FooBar_bar, _swig_p) - return -} - -func (_swig_base SwigcptrFooBar) Bar() (_swig_ret int) { - return _swig_wrap_FooBar_bar(_swig_base) -} - -func (p SwigcptrFooBar) SwigIsFoo() { -} - -func (p SwigcptrFooBar) SwigGetFoo() Foo { - return SwigcptrFoo(p.Swigcptr()) -} - -var _wrap_FooBar_SwigGetBar unsafe.Pointer - -func _swig_wrap_FooBar_SwigGetBar(base SwigcptrFooBar) (_ SwigcptrBar) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_FooBar_SwigGetBar, _swig_p) - return -} - -func (arg1 SwigcptrFooBar) SwigGetBar() (_swig_ret Bar) { - return _swig_wrap_FooBar_SwigGetBar(arg1) -} - -type FooBar interface { - Swigcptr() uintptr - SwigIsFooBar() - FooBar() (_swig_ret int) - Foo() (_swig_ret int) - Bar() (_swig_ret int) - SwigIsFoo() - SwigGetFoo() Foo - SwigGetBar() (_swig_ret Bar) -} - -type SwigcptrFooBarSpam uintptr - -func (p SwigcptrFooBarSpam) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrFooBarSpam) SwigIsFooBarSpam() { -} - -var _wrap_FooBarSpam_fooBarSpam unsafe.Pointer - -func _swig_wrap_FooBarSpam_fooBarSpam(base SwigcptrFooBarSpam) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_FooBarSpam_fooBarSpam, _swig_p) - return -} - -func (arg1 SwigcptrFooBarSpam) FooBarSpam() (_swig_ret int) { - return _swig_wrap_FooBarSpam_fooBarSpam(arg1) -} - -var _wrap_new_FooBarSpam unsafe.Pointer - -func _swig_wrap_new_FooBarSpam() (base SwigcptrFooBarSpam) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_FooBarSpam, _swig_p) - return -} - -func NewFooBarSpam() (_swig_ret FooBarSpam) { - return _swig_wrap_new_FooBarSpam() -} - -var _wrap_delete_FooBarSpam unsafe.Pointer - -func _swig_wrap_delete_FooBarSpam(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_FooBarSpam, _swig_p) - return -} - -func DeleteFooBarSpam(arg1 FooBarSpam) { - _swig_wrap_delete_FooBarSpam(arg1.Swigcptr()) -} - -var _wrap_FooBarSpam_foo unsafe.Pointer - -func _swig_wrap_FooBarSpam_foo(base SwigcptrFooBarSpam) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_FooBarSpam_foo, _swig_p) - return -} - -func (_swig_base SwigcptrFooBarSpam) Foo() (_swig_ret int) { - return _swig_wrap_FooBarSpam_foo(_swig_base) -} - -var _wrap_FooBarSpam_bar unsafe.Pointer - -func _swig_wrap_FooBarSpam_bar(base SwigcptrFooBarSpam) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_FooBarSpam_bar, _swig_p) - return -} - -func (_swig_base SwigcptrFooBarSpam) Bar() (_swig_ret int) { - return _swig_wrap_FooBarSpam_bar(_swig_base) -} - -var _wrap_FooBarSpam_spam unsafe.Pointer - -func _swig_wrap_FooBarSpam_spam(base SwigcptrFooBarSpam, _ int) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_FooBarSpam_spam, _swig_p) - return -} - -func (_swig_base SwigcptrFooBarSpam) Spam(arg1 int) (_swig_ret int) { - return _swig_wrap_FooBarSpam_spam(_swig_base, arg1) -} - -func (p SwigcptrFooBarSpam) SwigIsFoo() { -} - -func (p SwigcptrFooBarSpam) SwigGetFoo() Foo { - return SwigcptrFoo(p.Swigcptr()) -} - -var _wrap_FooBarSpam_SwigGetBar unsafe.Pointer - -func _swig_wrap_FooBarSpam_SwigGetBar(base SwigcptrFooBarSpam) (_ SwigcptrBar) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_FooBarSpam_SwigGetBar, _swig_p) - return -} - -func (arg1 SwigcptrFooBarSpam) SwigGetBar() (_swig_ret Bar) { - return _swig_wrap_FooBarSpam_SwigGetBar(arg1) -} - -var _wrap_FooBarSpam_SwigGetSpamInt unsafe.Pointer - -func _swig_wrap_FooBarSpam_SwigGetSpamInt(base SwigcptrFooBarSpam) (_ SwigcptrSpamInt) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_FooBarSpam_SwigGetSpamInt, _swig_p) - return -} - -func (arg1 SwigcptrFooBarSpam) SwigGetSpamInt() (_swig_ret SpamInt) { - return _swig_wrap_FooBarSpam_SwigGetSpamInt(arg1) -} - -type FooBarSpam interface { - Swigcptr() uintptr - SwigIsFooBarSpam() - FooBarSpam() (_swig_ret int) - Foo() (_swig_ret int) - Bar() (_swig_ret int) - Spam(arg1 int) (_swig_ret int) - SwigIsFoo() - SwigGetFoo() Foo - SwigGetBar() (_swig_ret Bar) - SwigGetSpamInt() (_swig_ret SpamInt) -} - -type SwigcptrIgnoreDerived1 uintptr - -func (p SwigcptrIgnoreDerived1) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrIgnoreDerived1) SwigIsIgnoreDerived1() { -} - -var _wrap_IgnoreDerived1_ignorederived1 unsafe.Pointer - -func _swig_wrap_IgnoreDerived1_ignorederived1(base SwigcptrIgnoreDerived1) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_IgnoreDerived1_ignorederived1, _swig_p) - return -} - -func (arg1 SwigcptrIgnoreDerived1) Ignorederived1() (_swig_ret int) { - return _swig_wrap_IgnoreDerived1_ignorederived1(arg1) -} - -var _wrap_new_IgnoreDerived1 unsafe.Pointer - -func _swig_wrap_new_IgnoreDerived1() (base SwigcptrIgnoreDerived1) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_IgnoreDerived1, _swig_p) - return -} - -func NewIgnoreDerived1() (_swig_ret IgnoreDerived1) { - return _swig_wrap_new_IgnoreDerived1() -} - -var _wrap_delete_IgnoreDerived1 unsafe.Pointer - -func _swig_wrap_delete_IgnoreDerived1(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_IgnoreDerived1, _swig_p) - return -} - -func DeleteIgnoreDerived1(arg1 IgnoreDerived1) { - _swig_wrap_delete_IgnoreDerived1(arg1.Swigcptr()) -} - -var _wrap_IgnoreDerived1_bar unsafe.Pointer - -func _swig_wrap_IgnoreDerived1_bar(base SwigcptrIgnoreDerived1) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_IgnoreDerived1_bar, _swig_p) - return -} - -func (_swig_base SwigcptrIgnoreDerived1) Bar() (_swig_ret int) { - return _swig_wrap_IgnoreDerived1_bar(_swig_base) -} - -var _wrap_IgnoreDerived1_SwigGetBar unsafe.Pointer - -func _swig_wrap_IgnoreDerived1_SwigGetBar(base SwigcptrIgnoreDerived1) (_ SwigcptrBar) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_IgnoreDerived1_SwigGetBar, _swig_p) - return -} - -func (arg1 SwigcptrIgnoreDerived1) SwigGetBar() (_swig_ret Bar) { - return _swig_wrap_IgnoreDerived1_SwigGetBar(arg1) -} - -type IgnoreDerived1 interface { - Swigcptr() uintptr - SwigIsIgnoreDerived1() - Ignorederived1() (_swig_ret int) - Bar() (_swig_ret int) - SwigGetBar() (_swig_ret Bar) -} - -type SwigcptrIgnoreDerived2 uintptr - -func (p SwigcptrIgnoreDerived2) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrIgnoreDerived2) SwigIsIgnoreDerived2() { -} - -var _wrap_IgnoreDerived2_ignorederived2 unsafe.Pointer - -func _swig_wrap_IgnoreDerived2_ignorederived2(base SwigcptrIgnoreDerived2) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_IgnoreDerived2_ignorederived2, _swig_p) - return -} - -func (arg1 SwigcptrIgnoreDerived2) Ignorederived2() (_swig_ret int) { - return _swig_wrap_IgnoreDerived2_ignorederived2(arg1) -} - -var _wrap_new_IgnoreDerived2 unsafe.Pointer - -func _swig_wrap_new_IgnoreDerived2() (base SwigcptrIgnoreDerived2) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_IgnoreDerived2, _swig_p) - return -} - -func NewIgnoreDerived2() (_swig_ret IgnoreDerived2) { - return _swig_wrap_new_IgnoreDerived2() -} - -var _wrap_delete_IgnoreDerived2 unsafe.Pointer - -func _swig_wrap_delete_IgnoreDerived2(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_IgnoreDerived2, _swig_p) - return -} - -func DeleteIgnoreDerived2(arg1 IgnoreDerived2) { - _swig_wrap_delete_IgnoreDerived2(arg1.Swigcptr()) -} - -var _wrap_IgnoreDerived2_bar unsafe.Pointer - -func _swig_wrap_IgnoreDerived2_bar(base SwigcptrIgnoreDerived2) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_IgnoreDerived2_bar, _swig_p) - return -} - -func (_swig_base SwigcptrIgnoreDerived2) Bar() (_swig_ret int) { - return _swig_wrap_IgnoreDerived2_bar(_swig_base) -} - -var _wrap_IgnoreDerived2_SwigGetBar unsafe.Pointer - -func _swig_wrap_IgnoreDerived2_SwigGetBar(base SwigcptrIgnoreDerived2) (_ SwigcptrBar) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_IgnoreDerived2_SwigGetBar, _swig_p) - return -} - -func (arg1 SwigcptrIgnoreDerived2) SwigGetBar() (_swig_ret Bar) { - return _swig_wrap_IgnoreDerived2_SwigGetBar(arg1) -} - -type IgnoreDerived2 interface { - Swigcptr() uintptr - SwigIsIgnoreDerived2() - Ignorederived2() (_swig_ret int) - Bar() (_swig_ret int) - SwigGetBar() (_swig_ret Bar) -} - -type SwigcptrIgnoreDerived3 uintptr - -func (p SwigcptrIgnoreDerived3) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrIgnoreDerived3) SwigIsIgnoreDerived3() { -} - -var _wrap_IgnoreDerived3_ignorederived3 unsafe.Pointer - -func _swig_wrap_IgnoreDerived3_ignorederived3(base SwigcptrIgnoreDerived3) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_IgnoreDerived3_ignorederived3, _swig_p) - return -} - -func (arg1 SwigcptrIgnoreDerived3) Ignorederived3() (_swig_ret int) { - return _swig_wrap_IgnoreDerived3_ignorederived3(arg1) -} - -var _wrap_new_IgnoreDerived3 unsafe.Pointer - -func _swig_wrap_new_IgnoreDerived3() (base SwigcptrIgnoreDerived3) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_IgnoreDerived3, _swig_p) - return -} - -func NewIgnoreDerived3() (_swig_ret IgnoreDerived3) { - return _swig_wrap_new_IgnoreDerived3() -} - -var _wrap_delete_IgnoreDerived3 unsafe.Pointer - -func _swig_wrap_delete_IgnoreDerived3(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_IgnoreDerived3, _swig_p) - return -} - -func DeleteIgnoreDerived3(arg1 IgnoreDerived3) { - _swig_wrap_delete_IgnoreDerived3(arg1.Swigcptr()) -} - -var _wrap_IgnoreDerived3_bar unsafe.Pointer - -func _swig_wrap_IgnoreDerived3_bar(base SwigcptrIgnoreDerived3) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_IgnoreDerived3_bar, _swig_p) - return -} - -func (_swig_base SwigcptrIgnoreDerived3) Bar() (_swig_ret int) { - return _swig_wrap_IgnoreDerived3_bar(_swig_base) -} - -var _wrap_IgnoreDerived3_SwigGetBar unsafe.Pointer - -func _swig_wrap_IgnoreDerived3_SwigGetBar(base SwigcptrIgnoreDerived3) (_ SwigcptrBar) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_IgnoreDerived3_SwigGetBar, _swig_p) - return -} - -func (arg1 SwigcptrIgnoreDerived3) SwigGetBar() (_swig_ret Bar) { - return _swig_wrap_IgnoreDerived3_SwigGetBar(arg1) -} - -type IgnoreDerived3 interface { - Swigcptr() uintptr - SwigIsIgnoreDerived3() - Ignorederived3() (_swig_ret int) - Bar() (_swig_ret int) - SwigGetBar() (_swig_ret Bar) -} - -type SwigcptrIgnoreDerived4 uintptr - -func (p SwigcptrIgnoreDerived4) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrIgnoreDerived4) SwigIsIgnoreDerived4() { -} - -var _wrap_IgnoreDerived4_ignorederived4 unsafe.Pointer - -func _swig_wrap_IgnoreDerived4_ignorederived4(base SwigcptrIgnoreDerived4) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_IgnoreDerived4_ignorederived4, _swig_p) - return -} - -func (arg1 SwigcptrIgnoreDerived4) Ignorederived4() (_swig_ret int) { - return _swig_wrap_IgnoreDerived4_ignorederived4(arg1) -} - -var _wrap_new_IgnoreDerived4 unsafe.Pointer - -func _swig_wrap_new_IgnoreDerived4() (base SwigcptrIgnoreDerived4) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_IgnoreDerived4, _swig_p) - return -} - -func NewIgnoreDerived4() (_swig_ret IgnoreDerived4) { - return _swig_wrap_new_IgnoreDerived4() -} - -var _wrap_delete_IgnoreDerived4 unsafe.Pointer - -func _swig_wrap_delete_IgnoreDerived4(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_IgnoreDerived4, _swig_p) - return -} - -func DeleteIgnoreDerived4(arg1 IgnoreDerived4) { - _swig_wrap_delete_IgnoreDerived4(arg1.Swigcptr()) -} - -var _wrap_IgnoreDerived4_bar unsafe.Pointer - -func _swig_wrap_IgnoreDerived4_bar(base SwigcptrIgnoreDerived4) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_IgnoreDerived4_bar, _swig_p) - return -} - -func (_swig_base SwigcptrIgnoreDerived4) Bar() (_swig_ret int) { - return _swig_wrap_IgnoreDerived4_bar(_swig_base) -} - -func (p SwigcptrIgnoreDerived4) SwigIsBar() { -} - -func (p SwigcptrIgnoreDerived4) SwigGetBar() Bar { - return SwigcptrBar(p.Swigcptr()) -} - -type IgnoreDerived4 interface { - Swigcptr() uintptr - SwigIsIgnoreDerived4() - Ignorederived4() (_swig_ret int) - Bar() (_swig_ret int) - SwigIsBar() - SwigGetBar() Bar -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/name.go b/Examples/test-suite/go/name.go deleted file mode 100644 index 0a65598ca..000000000 --- a/Examples/test-suite/go/name.go +++ /dev/null @@ -1,69 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../name.i - -package name - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -var _wrap_foo_2 unsafe.Pointer - -func _swig_wrap_foo_2() { - var _swig_p uintptr - _cgo_runtime_cgocall(_wrap_foo_2, _swig_p) - return -} - -func Foo_2() { - _swig_wrap_foo_2() -} - -var _wrap_bar_2_set unsafe.Pointer - -func _swig_wrap_bar_2_set(base int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_bar_2_set, _swig_p) - return -} - -func SetBar_2(arg1 int) { - _swig_wrap_bar_2_set(arg1) -} - -var _wrap_bar_2_get unsafe.Pointer - -func GetBar_2() (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_bar_2_get, _swig_p) - return -} -const Baz_2 int = 47 - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/name_cxx.go b/Examples/test-suite/go/name_cxx.go deleted file mode 100644 index 6c0ab893b..000000000 --- a/Examples/test-suite/go/name_cxx.go +++ /dev/null @@ -1,146 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../name_cxx.i - -package name_cxx - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -var _wrap_bar_int unsafe.Pointer - -func _swig_wrap_bar_int(base int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_bar_int, _swig_p) - return -} - -func Bar_int(arg1 int) { - _swig_wrap_bar_int(arg1) -} - -var _wrap_bar_double unsafe.Pointer - -func _swig_wrap_bar_double(base float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_bar_double, _swig_p) - return -} - -func Bar_double(arg1 float64) { - _swig_wrap_bar_double(arg1) -} - -type SwigcptrAA uintptr - -func (p SwigcptrAA) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrAA) SwigIsAA() { -} - -var _wrap_new_AA unsafe.Pointer - -func _swig_wrap_new_AA() (base SwigcptrAA) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_AA, _swig_p) - return -} - -func NewAA() (_swig_ret AA) { - return _swig_wrap_new_AA() -} - -var _wrap_delete_AA unsafe.Pointer - -func _swig_wrap_delete_AA(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_AA, _swig_p) - return -} - -func DeleteAA(arg1 AA) { - _swig_wrap_delete_AA(arg1.Swigcptr()) -} - -type AA interface { - Swigcptr() uintptr - SwigIsAA() -} - -type SwigcptrB uintptr - -func (p SwigcptrB) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrB) SwigIsB() { -} - -var _wrap_new_B unsafe.Pointer - -func _swig_wrap_new_B() (base SwigcptrB) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_B, _swig_p) - return -} - -func NewB() (_swig_ret B) { - return _swig_wrap_new_B() -} - -var _wrap_delete_B unsafe.Pointer - -func _swig_wrap_delete_B(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_B, _swig_p) - return -} - -func DeleteB(arg1 B) { - _swig_wrap_delete_B(arg1.Swigcptr()) -} - -func (p SwigcptrB) SwigIsAA() { -} - -func (p SwigcptrB) SwigGetAA() AA { - return SwigcptrAA(p.Swigcptr()) -} - -type B interface { - Swigcptr() uintptr - SwigIsB() - SwigIsAA() - SwigGetAA() AA -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/name_warnings.go b/Examples/test-suite/go/name_warnings.go deleted file mode 100644 index ceb55ece7..000000000 --- a/Examples/test-suite/go/name_warnings.go +++ /dev/null @@ -1,169 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../name_warnings.i - -package name_warnings - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrA uintptr - -func (p SwigcptrA) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrA) SwigIsA() { -} - -var _wrap_A_clone unsafe.Pointer - -func _swig_wrap_A_clone(base SwigcptrA, _ int) (_ SwigcptrA) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_A_clone, _swig_p) - return -} - -func (arg1 SwigcptrA) Clone(arg2 int) (_swig_ret A) { - return _swig_wrap_A_clone(arg1, arg2) -} - -var _wrap_delete_A unsafe.Pointer - -func _swig_wrap_delete_A(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_A, _swig_p) - return -} - -func DeleteA(arg1 A) { - _swig_wrap_delete_A(arg1.Swigcptr()) -} - -var _wrap_new_A unsafe.Pointer - -func _swig_wrap_new_A() (base SwigcptrA) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_A, _swig_p) - return -} - -func NewA() (_swig_ret A) { - return _swig_wrap_new_A() -} - -type A interface { - Swigcptr() uintptr - SwigIsA() - Clone(arg2 int) (_swig_ret A) -} - -type SwigcptrB uintptr - -func (p SwigcptrB) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrB) SwigIsB() { -} - -var _wrap_new_B unsafe.Pointer - -func _swig_wrap_new_B() (base SwigcptrB) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_B, _swig_p) - return -} - -func NewB() (_swig_ret B) { - return _swig_wrap_new_B() -} - -var _wrap_delete_B unsafe.Pointer - -func _swig_wrap_delete_B(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_B, _swig_p) - return -} - -func DeleteB(arg1 B) { - _swig_wrap_delete_B(arg1.Swigcptr()) -} - -var _wrap_B_clone unsafe.Pointer - -func _swig_wrap_B_clone(base SwigcptrB, _ int) (_ SwigcptrA) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_B_clone, _swig_p) - return -} - -func (_swig_base SwigcptrB) Clone(arg1 int) (_swig_ret A) { - return _swig_wrap_B_clone(_swig_base, arg1) -} - -func (p SwigcptrB) SwigIsA() { -} - -func (p SwigcptrB) SwigGetA() A { - return SwigcptrA(p.Swigcptr()) -} - -type B interface { - Swigcptr() uintptr - SwigIsB() - Clone(arg1 int) (_swig_ret A) - SwigIsA() - SwigGetA() A -} - -var _wrap_max_i unsafe.Pointer - -func Max_i(arg1 int, arg2 int) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_max_i, _swig_p) - return -} -var _wrap_foo unsafe.Pointer - -func Foo(arg1 float64, arg2 float64) (_swig_ret float64) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_foo, _swig_p) - return -} -var _wrap_bar unsafe.Pointer - -func Bar(arg1 float64, arg2 bool) (_swig_ret float64) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_bar, _swig_p) - return -} - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/namespace_class.go b/Examples/test-suite/go/namespace_class.go deleted file mode 100644 index 7629f12e8..000000000 --- a/Examples/test-suite/go/namespace_class.go +++ /dev/null @@ -1,1280 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../namespace_class.i - -package namespace_class - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -var _wrap_FooBarInt unsafe.Pointer - -func _swig_wrap_FooBarInt(base int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_FooBarInt, _swig_p) - return -} - -func FooBarInt(arg1 int) { - _swig_wrap_FooBarInt(arg1) -} - -var _wrap_BarFooInt unsafe.Pointer - -func _swig_wrap_BarFooInt(base int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_BarFooInt, _swig_p) - return -} - -func BarFooInt(arg1 int) { - _swig_wrap_BarFooInt(arg1) -} - -type TestHello int -var _wrap_Hi unsafe.Pointer - -func _swig_getHi() (_swig_ret TestHello) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_Hi, _swig_p) - return -} -var Hi TestHello = _swig_getHi() -type SwigcptrBar uintptr - -func (p SwigcptrBar) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrBar) SwigIsBar() { -} - -var _wrap_Bar_foo unsafe.Pointer - -func _swig_wrap_Bar_foo(base SwigcptrBar, _ TestHello) (_ TestHello) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Bar_foo, _swig_p) - return -} - -func (arg1 SwigcptrBar) Foo(arg2 TestHello) (_swig_ret TestHello) { - return _swig_wrap_Bar_foo(arg1, arg2) -} - -var _wrap_new_Bar unsafe.Pointer - -func _swig_wrap_new_Bar() (base SwigcptrBar) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Bar, _swig_p) - return -} - -func NewBar() (_swig_ret Bar) { - return _swig_wrap_new_Bar() -} - -var _wrap_delete_Bar unsafe.Pointer - -func _swig_wrap_delete_Bar(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Bar, _swig_p) - return -} - -func DeleteBar(arg1 Bar) { - _swig_wrap_delete_Bar(arg1.Swigcptr()) -} - -type Bar interface { - Swigcptr() uintptr - SwigIsBar() - Foo(arg2 TestHello) (_swig_ret TestHello) -} - -var _wrap_a_set unsafe.Pointer - -func _swig_wrap_a_set(base int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_a_set, _swig_p) - return -} - -func SetA(arg1 int) { - _swig_wrap_a_set(arg1) -} - -var _wrap_a_get unsafe.Pointer - -func GetA() (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_a_get, _swig_p) - return -} -type SwigcptrFoo uintptr - -func (p SwigcptrFoo) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrFoo) SwigIsFoo() { -} - -var _wrap_Foo_bar unsafe.Pointer - -func _swig_wrap_Foo_bar(base SwigcptrFoo, _ TestHello) (_ TestHello) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_bar, _swig_p) - return -} - -func (arg1 SwigcptrFoo) Bar(arg2 TestHello) (_swig_ret TestHello) { - return _swig_wrap_Foo_bar(arg1, arg2) -} - -var _wrap_new_Foo unsafe.Pointer - -func _swig_wrap_new_Foo() (base SwigcptrFoo) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Foo, _swig_p) - return -} - -func NewFoo() (_swig_ret Foo) { - return _swig_wrap_new_Foo() -} - -var _wrap_delete_Foo unsafe.Pointer - -func _swig_wrap_delete_Foo(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Foo, _swig_p) - return -} - -func DeleteFoo(arg1 Foo) { - _swig_wrap_delete_Foo(arg1.Swigcptr()) -} - -var _wrap_Foo_foo unsafe.Pointer - -func _swig_wrap_Foo_foo(base SwigcptrFoo, _ TestHello) (_ TestHello) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_foo, _swig_p) - return -} - -func (_swig_base SwigcptrFoo) Foo(arg1 TestHello) (_swig_ret TestHello) { - return _swig_wrap_Foo_foo(_swig_base, arg1) -} - -func (p SwigcptrFoo) SwigIsBar() { -} - -func (p SwigcptrFoo) SwigGetBar() Bar { - return SwigcptrBar(p.Swigcptr()) -} - -type Foo interface { - Swigcptr() uintptr - SwigIsFoo() - Bar(arg2 TestHello) (_swig_ret TestHello) - Foo(arg1 TestHello) (_swig_ret TestHello) - SwigIsBar() - SwigGetBar() Bar -} - -type SwigcptrTest uintptr - -func (p SwigcptrTest) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrTest) SwigIsTest() { -} - -var _wrap_Test_foo unsafe.Pointer - -func _swig_wrap_Test_foo(base SwigcptrTest, _ TestHello) (_ TestHello) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Test_foo, _swig_p) - return -} - -func (arg1 SwigcptrTest) Foo(arg2 TestHello) (_swig_ret TestHello) { - return _swig_wrap_Test_foo(arg1, arg2) -} - -var _wrap_new_Test unsafe.Pointer - -func _swig_wrap_new_Test() (base SwigcptrTest) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Test, _swig_p) - return -} - -func NewTest() (_swig_ret Test) { - return _swig_wrap_new_Test() -} - -var _wrap_delete_Test unsafe.Pointer - -func _swig_wrap_delete_Test(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Test, _swig_p) - return -} - -func DeleteTest(arg1 Test) { - _swig_wrap_delete_Test(arg1.Swigcptr()) -} - -type Test interface { - Swigcptr() uintptr - SwigIsTest() - Foo(arg2 TestHello) (_swig_ret TestHello) -} - -type SwigcptrBor uintptr - -func (p SwigcptrBor) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrBor) SwigIsBor() { -} - -var _wrap_Bor_foo unsafe.Pointer - -func _swig_wrap_Bor_foo(base SwigcptrBor, _ TestHello) (_ TestHello) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Bor_foo, _swig_p) - return -} - -func (arg1 SwigcptrBor) Foo(arg2 TestHello) (_swig_ret TestHello) { - return _swig_wrap_Bor_foo(arg1, arg2) -} - -var _wrap_new_Bor unsafe.Pointer - -func _swig_wrap_new_Bor() (base SwigcptrBor) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Bor, _swig_p) - return -} - -func NewBor() (_swig_ret Bor) { - return _swig_wrap_new_Bor() -} - -var _wrap_delete_Bor unsafe.Pointer - -func _swig_wrap_delete_Bor(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Bor, _swig_p) - return -} - -func DeleteBor(arg1 Bor) { - _swig_wrap_delete_Bor(arg1.Swigcptr()) -} - -type Bor interface { - Swigcptr() uintptr - SwigIsBor() - Foo(arg2 TestHello) (_swig_ret TestHello) -} - -type SwigcptrFoobar uintptr - -func (p SwigcptrFoobar) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrFoobar) SwigIsFoobar() { -} - -var _wrap_Foobar_bar unsafe.Pointer - -func _swig_wrap_Foobar_bar(base SwigcptrFoobar, _ TestHello) (_ TestHello) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foobar_bar, _swig_p) - return -} - -func (arg1 SwigcptrFoobar) Bar(arg2 TestHello) (_swig_ret TestHello) { - return _swig_wrap_Foobar_bar(arg1, arg2) -} - -var _wrap_new_Foobar unsafe.Pointer - -func _swig_wrap_new_Foobar() (base SwigcptrFoobar) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Foobar, _swig_p) - return -} - -func NewFoobar() (_swig_ret Foobar) { - return _swig_wrap_new_Foobar() -} - -var _wrap_delete_Foobar unsafe.Pointer - -func _swig_wrap_delete_Foobar(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Foobar, _swig_p) - return -} - -func DeleteFoobar(arg1 Foobar) { - _swig_wrap_delete_Foobar(arg1.Swigcptr()) -} - -var _wrap_Foobar_foo unsafe.Pointer - -func _swig_wrap_Foobar_foo(base SwigcptrFoobar, _ TestHello) (_ TestHello) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foobar_foo, _swig_p) - return -} - -func (_swig_base SwigcptrFoobar) Foo(arg1 TestHello) (_swig_ret TestHello) { - return _swig_wrap_Foobar_foo(_swig_base, arg1) -} - -func (p SwigcptrFoobar) SwigIsBar() { -} - -func (p SwigcptrFoobar) SwigGetBar() Bar { - return SwigcptrBar(p.Swigcptr()) -} - -type Foobar interface { - Swigcptr() uintptr - SwigIsFoobar() - Bar(arg2 TestHello) (_swig_ret TestHello) - Foo(arg1 TestHello) (_swig_ret TestHello) - SwigIsBar() - SwigGetBar() Bar -} - -type SwigcptrFooT_i uintptr - -func (p SwigcptrFooT_i) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrFooT_i) SwigIsFooT_i() { -} - -var _wrap_FooT_i_quack unsafe.Pointer - -func _swig_wrap_FooT_i_quack(base SwigcptrFooT_i, _ int) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_FooT_i_quack, _swig_p) - return -} - -func (arg1 SwigcptrFooT_i) Quack(arg2 int) (_swig_ret int) { - return _swig_wrap_FooT_i_quack(arg1, arg2) -} - -var _wrap_new_FooT_i unsafe.Pointer - -func _swig_wrap_new_FooT_i() (base SwigcptrFooT_i) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_FooT_i, _swig_p) - return -} - -func NewFooT_i() (_swig_ret FooT_i) { - return _swig_wrap_new_FooT_i() -} - -var _wrap_delete_FooT_i unsafe.Pointer - -func _swig_wrap_delete_FooT_i(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_FooT_i, _swig_p) - return -} - -func DeleteFooT_i(arg1 FooT_i) { - _swig_wrap_delete_FooT_i(arg1.Swigcptr()) -} - -type FooT_i interface { - Swigcptr() uintptr - SwigIsFooT_i() - Quack(arg2 int) (_swig_ret int) -} - -type SwigcptrFooT_H uintptr - -func (p SwigcptrFooT_H) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrFooT_H) SwigIsFooT_H() { -} - -var _wrap_FooT_H_foo unsafe.Pointer - -func _swig_wrap_FooT_H_foo(base SwigcptrFooT_H, _ TestHello) (_ TestHello) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_FooT_H_foo, _swig_p) - return -} - -func (arg1 SwigcptrFooT_H) Foo(arg2 TestHello) (_swig_ret TestHello) { - return _swig_wrap_FooT_H_foo(arg1, arg2) -} - -var _wrap_FooT_H_bar unsafe.Pointer - -func _swig_wrap_FooT_H_bar(base SwigcptrFooT_H, _ TestHello) (_ TestHello) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_FooT_H_bar, _swig_p) - return -} - -func (arg1 SwigcptrFooT_H) Bar(arg2 TestHello) (_swig_ret TestHello) { - return _swig_wrap_FooT_H_bar(arg1, arg2) -} - -var _wrap_new_FooT_H unsafe.Pointer - -func _swig_wrap_new_FooT_H() (base SwigcptrFooT_H) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_FooT_H, _swig_p) - return -} - -func NewFooT_H() (_swig_ret FooT_H) { - return _swig_wrap_new_FooT_H() -} - -var _wrap_delete_FooT_H unsafe.Pointer - -func _swig_wrap_delete_FooT_H(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_FooT_H, _swig_p) - return -} - -func DeleteFooT_H(arg1 FooT_H) { - _swig_wrap_delete_FooT_H(arg1.Swigcptr()) -} - -type FooT_H interface { - Swigcptr() uintptr - SwigIsFooT_H() - Foo(arg2 TestHello) (_swig_ret TestHello) - Bar(arg2 TestHello) (_swig_ret TestHello) -} - -type SwigcptrFooT_d uintptr - -func (p SwigcptrFooT_d) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrFooT_d) SwigIsFooT_d() { -} - -var _wrap_FooT_d_moo unsafe.Pointer - -func _swig_wrap_FooT_d_moo(base SwigcptrFooT_d, _ float64) (_ float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_FooT_d_moo, _swig_p) - return -} - -func (arg1 SwigcptrFooT_d) Moo(arg2 float64) (_swig_ret float64) { - return _swig_wrap_FooT_d_moo(arg1, arg2) -} - -var _wrap_new_FooT_d unsafe.Pointer - -func _swig_wrap_new_FooT_d() (base SwigcptrFooT_d) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_FooT_d, _swig_p) - return -} - -func NewFooT_d() (_swig_ret FooT_d) { - return _swig_wrap_new_FooT_d() -} - -var _wrap_delete_FooT_d unsafe.Pointer - -func _swig_wrap_delete_FooT_d(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_FooT_d, _swig_p) - return -} - -func DeleteFooT_d(arg1 FooT_d) { - _swig_wrap_delete_FooT_d(arg1.Swigcptr()) -} - -type FooT_d interface { - Swigcptr() uintptr - SwigIsFooT_d() - Moo(arg2 float64) (_swig_ret float64) -} - -type SwigcptrBarT_H uintptr - -func (p SwigcptrBarT_H) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrBarT_H) SwigIsBarT_H() { -} - -var _wrap_new_BarT_H unsafe.Pointer - -func _swig_wrap_new_BarT_H() (base SwigcptrBarT_H) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_BarT_H, _swig_p) - return -} - -func NewBarT_H() (_swig_ret BarT_H) { - return _swig_wrap_new_BarT_H() -} - -var _wrap_delete_BarT_H unsafe.Pointer - -func _swig_wrap_delete_BarT_H(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_BarT_H, _swig_p) - return -} - -func DeleteBarT_H(arg1 BarT_H) { - _swig_wrap_delete_BarT_H(arg1.Swigcptr()) -} - -type BarT_H interface { - Swigcptr() uintptr - SwigIsBarT_H() -} - -type SwigcptrPoo_i uintptr - -func (p SwigcptrPoo_i) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrPoo_i) SwigIsPoo_i() { -} - -var _wrap_new_Poo_i unsafe.Pointer - -func _swig_wrap_new_Poo_i() (base SwigcptrPoo_i) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Poo_i, _swig_p) - return -} - -func NewPoo_i() (_swig_ret Poo_i) { - return _swig_wrap_new_Poo_i() -} - -var _wrap_delete_Poo_i unsafe.Pointer - -func _swig_wrap_delete_Poo_i(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Poo_i, _swig_p) - return -} - -func DeletePoo_i(arg1 Poo_i) { - _swig_wrap_delete_Poo_i(arg1.Swigcptr()) -} - -type Poo_i interface { - Swigcptr() uintptr - SwigIsPoo_i() -} - -type SwigcptrBooT_H uintptr - -func (p SwigcptrBooT_H) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrBooT_H) SwigIsBooT_H() { -} - -var _wrap_new_BooT_H unsafe.Pointer - -func _swig_wrap_new_BooT_H() (base SwigcptrBooT_H) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_BooT_H, _swig_p) - return -} - -func NewBooT_H() (_swig_ret BooT_H) { - return _swig_wrap_new_BooT_H() -} - -var _wrap_delete_BooT_H unsafe.Pointer - -func _swig_wrap_delete_BooT_H(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_BooT_H, _swig_p) - return -} - -func DeleteBooT_H(arg1 BooT_H) { - _swig_wrap_delete_BooT_H(arg1.Swigcptr()) -} - -type BooT_H interface { - Swigcptr() uintptr - SwigIsBooT_H() -} - -type SwigcptrBooT_i uintptr - -func (p SwigcptrBooT_i) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrBooT_i) SwigIsBooT_i() { -} - -var _wrap_new_BooT_i unsafe.Pointer - -func _swig_wrap_new_BooT_i() (base SwigcptrBooT_i) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_BooT_i, _swig_p) - return -} - -func NewBooT_i() (_swig_ret BooT_i) { - return _swig_wrap_new_BooT_i() -} - -var _wrap_delete_BooT_i unsafe.Pointer - -func _swig_wrap_delete_BooT_i(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_BooT_i, _swig_p) - return -} - -func DeleteBooT_i(arg1 BooT_i) { - _swig_wrap_delete_BooT_i(arg1.Swigcptr()) -} - -type BooT_i interface { - Swigcptr() uintptr - SwigIsBooT_i() -} - -type SwigcptrEulerT3D uintptr - -func (p SwigcptrEulerT3D) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrEulerT3D) SwigIsEulerT3D() { -} - -var _wrap_EulerT3D_hello unsafe.Pointer - -func _swig_wrap_EulerT3D_hello() { - var _swig_p uintptr - _cgo_runtime_cgocall(_wrap_EulerT3D_hello, _swig_p) - return -} - -func EulerT3DHello() { - _swig_wrap_EulerT3D_hello() -} - -var _wrap_EulerT3D_toFrame unsafe.Pointer - -func _swig_wrap_EulerT3D_toFrame(base int, _ int, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_EulerT3D_toFrame, _swig_p) - return -} - -func EulerT3DToFrame(arg1 int, arg2 int, arg3 int) { - _swig_wrap_EulerT3D_toFrame(arg1, arg2, arg3) -} - -var _wrap_EulerT3D_callint unsafe.Pointer - -func _swig_wrap_EulerT3D_callint(base SwigcptrEulerT3D, _ *int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_EulerT3D_callint, _swig_p) - return -} - -func (arg1 SwigcptrEulerT3D) Callint(arg2 *int) { - _swig_wrap_EulerT3D_callint(arg1, arg2) -} - -var _wrap_EulerT3D_lessint unsafe.Pointer - -func _swig_wrap_EulerT3D_lessint(base SwigcptrEulerT3D, _ *int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_EulerT3D_lessint, _swig_p) - return -} - -func (arg1 SwigcptrEulerT3D) Lessint(arg2 *int) { - _swig_wrap_EulerT3D_lessint(arg1, arg2) -} - -var _wrap_EulerT3D_callfooi unsafe.Pointer - -func _swig_wrap_EulerT3D_callfooi(base SwigcptrEulerT3D, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_EulerT3D_callfooi, _swig_p) - return -} - -func (arg1 SwigcptrEulerT3D) Callfooi(arg2 FooT_i) { - _swig_wrap_EulerT3D_callfooi(arg1, arg2.Swigcptr()) -} - -var _wrap_EulerT3D_lessfooi unsafe.Pointer - -func _swig_wrap_EulerT3D_lessfooi(base SwigcptrEulerT3D, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_EulerT3D_lessfooi, _swig_p) - return -} - -func (arg1 SwigcptrEulerT3D) Lessfooi(arg2 FooT_i) { - _swig_wrap_EulerT3D_lessfooi(arg1, arg2.Swigcptr()) -} - -var _wrap_new_EulerT3D unsafe.Pointer - -func _swig_wrap_new_EulerT3D() (base SwigcptrEulerT3D) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_EulerT3D, _swig_p) - return -} - -func NewEulerT3D() (_swig_ret EulerT3D) { - return _swig_wrap_new_EulerT3D() -} - -var _wrap_delete_EulerT3D unsafe.Pointer - -func _swig_wrap_delete_EulerT3D(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_EulerT3D, _swig_p) - return -} - -func DeleteEulerT3D(arg1 EulerT3D) { - _swig_wrap_delete_EulerT3D(arg1.Swigcptr()) -} - -type EulerT3D interface { - Swigcptr() uintptr - SwigIsEulerT3D() - Callint(arg2 *int) - Lessint(arg2 *int) - Callfooi(arg2 FooT_i) - Lessfooi(arg2 FooT_i) -} - -type SwigcptrAla uintptr - -func (p SwigcptrAla) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrAla) SwigIsAla() { -} - -var _wrap_new_Ala unsafe.Pointer - -func _swig_wrap_new_Ala() (base SwigcptrAla) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Ala, _swig_p) - return -} - -func NewAla() (_swig_ret Ala) { - return _swig_wrap_new_Ala() -} - -var _wrap_Ala_hi unsafe.Pointer - -func _swig_wrap_Ala_hi() { - var _swig_p uintptr - _cgo_runtime_cgocall(_wrap_Ala_hi, _swig_p) - return -} - -func AlaHi() { - _swig_wrap_Ala_hi() -} - -var _wrap_delete_Ala unsafe.Pointer - -func _swig_wrap_delete_Ala(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Ala, _swig_p) - return -} - -func DeleteAla(arg1 Ala) { - _swig_wrap_delete_Ala(arg1.Swigcptr()) -} - -type Ala interface { - Swigcptr() uintptr - SwigIsAla() -} - -type SwigcptrFile uintptr - -func (p SwigcptrFile) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrFile) SwigIsFile() { -} - -var _wrap_new_File unsafe.Pointer - -func _swig_wrap_new_File() (base SwigcptrFile) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_File, _swig_p) - return -} - -func NewFile() (_swig_ret File) { - return _swig_wrap_new_File() -} - -var _wrap_delete_File unsafe.Pointer - -func _swig_wrap_delete_File(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_File, _swig_p) - return -} - -func DeleteFile(arg1 File) { - _swig_wrap_delete_File(arg1.Swigcptr()) -} - -type File interface { - Swigcptr() uintptr - SwigIsFile() -} - -type SwigcptrAudioProperties uintptr - -func (p SwigcptrAudioProperties) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrAudioProperties) SwigIsAudioProperties() { -} - -var _wrap_new_AudioProperties unsafe.Pointer - -func _swig_wrap_new_AudioProperties() (base SwigcptrAudioProperties) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_AudioProperties, _swig_p) - return -} - -func NewAudioProperties() (_swig_ret AudioProperties) { - return _swig_wrap_new_AudioProperties() -} - -var _wrap_delete_AudioProperties unsafe.Pointer - -func _swig_wrap_delete_AudioProperties(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_AudioProperties, _swig_p) - return -} - -func DeleteAudioProperties(arg1 AudioProperties) { - _swig_wrap_delete_AudioProperties(arg1.Swigcptr()) -} - -type AudioProperties interface { - Swigcptr() uintptr - SwigIsAudioProperties() -} - -type SwigcptrAudioPropertiesFile uintptr - -func (p SwigcptrAudioPropertiesFile) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrAudioPropertiesFile) SwigIsAudioPropertiesFile() { -} - -var _wrap_new_AudioPropertiesFile unsafe.Pointer - -func _swig_wrap_new_AudioPropertiesFile() (base SwigcptrAudioPropertiesFile) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_AudioPropertiesFile, _swig_p) - return -} - -func NewAudioPropertiesFile() (_swig_ret AudioPropertiesFile) { - return _swig_wrap_new_AudioPropertiesFile() -} - -var _wrap_delete_AudioPropertiesFile unsafe.Pointer - -func _swig_wrap_delete_AudioPropertiesFile(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_AudioPropertiesFile, _swig_p) - return -} - -func DeleteAudioPropertiesFile(arg1 AudioPropertiesFile) { - _swig_wrap_delete_AudioPropertiesFile(arg1.Swigcptr()) -} - -type AudioPropertiesFile interface { - Swigcptr() uintptr - SwigIsAudioPropertiesFile() -} - -type SwigcptrProperties uintptr - -func (p SwigcptrProperties) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrProperties) SwigIsProperties() { -} - -var _wrap_new_Properties unsafe.Pointer - -func _swig_wrap_new_Properties(base uintptr) (_ SwigcptrProperties) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Properties, _swig_p) - return -} - -func NewProperties(arg1 FLACFile) (_swig_ret Properties) { - return _swig_wrap_new_Properties(arg1.Swigcptr()) -} - -var _wrap_delete_Properties unsafe.Pointer - -func _swig_wrap_delete_Properties(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Properties, _swig_p) - return -} - -func DeleteProperties(arg1 Properties) { - _swig_wrap_delete_Properties(arg1.Swigcptr()) -} - -func (p SwigcptrProperties) SwigIsAudioProperties() { -} - -func (p SwigcptrProperties) SwigGetAudioProperties() AudioProperties { - return SwigcptrAudioProperties(p.Swigcptr()) -} - -type Properties interface { - Swigcptr() uintptr - SwigIsProperties() - SwigIsAudioProperties() - SwigGetAudioProperties() AudioProperties -} - -type SwigcptrPropertiesFile uintptr - -func (p SwigcptrPropertiesFile) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrPropertiesFile) SwigIsPropertiesFile() { -} - -var _wrap_new_PropertiesFile__SWIG_0 unsafe.Pointer - -func _swig_wrap_new_PropertiesFile__SWIG_0(base uintptr) (_ SwigcptrPropertiesFile) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_PropertiesFile__SWIG_0, _swig_p) - return -} - -func NewPropertiesFile__SWIG_0(arg1 File) (_swig_ret PropertiesFile) { - return _swig_wrap_new_PropertiesFile__SWIG_0(arg1.Swigcptr()) -} - -var _wrap_new_PropertiesFile__SWIG_1 unsafe.Pointer - -func _swig_wrap_new_PropertiesFile__SWIG_1() (base SwigcptrPropertiesFile) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_PropertiesFile__SWIG_1, _swig_p) - return -} - -func NewPropertiesFile__SWIG_1() (_swig_ret PropertiesFile) { - return _swig_wrap_new_PropertiesFile__SWIG_1() -} - -func NewPropertiesFile(a ...interface{}) PropertiesFile { - argc := len(a) - if argc == 0 { - return NewPropertiesFile__SWIG_1() - } - if argc == 1 { - return NewPropertiesFile__SWIG_0(a[0].(File)) - } - panic("No match for overloaded function call") -} - -var _wrap_delete_PropertiesFile unsafe.Pointer - -func _swig_wrap_delete_PropertiesFile(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_PropertiesFile, _swig_p) - return -} - -func DeletePropertiesFile(arg1 PropertiesFile) { - _swig_wrap_delete_PropertiesFile(arg1.Swigcptr()) -} - -func (p SwigcptrPropertiesFile) SwigIsAudioPropertiesFile() { -} - -func (p SwigcptrPropertiesFile) SwigGetAudioPropertiesFile() AudioPropertiesFile { - return SwigcptrAudioPropertiesFile(p.Swigcptr()) -} - -type PropertiesFile interface { - Swigcptr() uintptr - SwigIsPropertiesFile() - SwigIsAudioPropertiesFile() - SwigGetAudioPropertiesFile() AudioPropertiesFile -} - -type SwigcptrPropertiesFree uintptr - -func (p SwigcptrPropertiesFree) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrPropertiesFree) SwigIsPropertiesFree() { -} - -var _wrap_new_PropertiesFree unsafe.Pointer - -func _swig_wrap_new_PropertiesFree(base uintptr) (_ SwigcptrPropertiesFree) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_PropertiesFree, _swig_p) - return -} - -func NewPropertiesFree(arg1 FLACFile) (_swig_ret PropertiesFree) { - return _swig_wrap_new_PropertiesFree(arg1.Swigcptr()) -} - -var _wrap_delete_PropertiesFree unsafe.Pointer - -func _swig_wrap_delete_PropertiesFree(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_PropertiesFree, _swig_p) - return -} - -func DeletePropertiesFree(arg1 PropertiesFree) { - _swig_wrap_delete_PropertiesFree(arg1.Swigcptr()) -} - -func (p SwigcptrPropertiesFree) SwigIsAudioProperties() { -} - -func (p SwigcptrPropertiesFree) SwigGetAudioProperties() AudioProperties { - return SwigcptrAudioProperties(p.Swigcptr()) -} - -type PropertiesFree interface { - Swigcptr() uintptr - SwigIsPropertiesFree() - SwigIsAudioProperties() - SwigGetAudioProperties() AudioProperties -} - -type SwigcptrFooFilePrivate uintptr - -func (p SwigcptrFooFilePrivate) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrFooFilePrivate) SwigIsFooFilePrivate() { -} - -var _wrap_new_FooFilePrivate unsafe.Pointer - -func _swig_wrap_new_FooFilePrivate(base uintptr) (_ SwigcptrFooFilePrivate) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_FooFilePrivate, _swig_p) - return -} - -func NewFooFilePrivate(arg1 File) (_swig_ret FooFilePrivate) { - return _swig_wrap_new_FooFilePrivate(arg1.Swigcptr()) -} - -var _wrap_delete_FooFilePrivate unsafe.Pointer - -func _swig_wrap_delete_FooFilePrivate(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_FooFilePrivate, _swig_p) - return -} - -func DeleteFooFilePrivate(arg1 FooFilePrivate) { - _swig_wrap_delete_FooFilePrivate(arg1.Swigcptr()) -} - -type FooFilePrivate interface { - Swigcptr() uintptr - SwigIsFooFilePrivate() -} - -type SwigcptrFooFile uintptr - -func (p SwigcptrFooFile) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrFooFile) SwigIsFooFile() { -} - -var _wrap_new_FooFile unsafe.Pointer - -func _swig_wrap_new_FooFile(base uintptr) (_ SwigcptrFooFile) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_FooFile, _swig_p) - return -} - -func NewFooFile(arg1 File) (_swig_ret FooFile) { - return _swig_wrap_new_FooFile(arg1.Swigcptr()) -} - -var _wrap_delete_FooFile unsafe.Pointer - -func _swig_wrap_delete_FooFile(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_FooFile, _swig_p) - return -} - -func DeleteFooFile(arg1 FooFile) { - _swig_wrap_delete_FooFile(arg1.Swigcptr()) -} - -func (p SwigcptrFooFile) SwigIsPropertiesFile() { -} - -func (p SwigcptrFooFile) SwigGetPropertiesFile() PropertiesFile { - return SwigcptrPropertiesFile(p.Swigcptr()) -} - -func (p SwigcptrFooFile) SwigIsAudioPropertiesFile() { -} - -func (p SwigcptrFooFile) SwigGetAudioPropertiesFile() AudioPropertiesFile { - return SwigcptrAudioPropertiesFile(p.Swigcptr()) -} - -type FooFile interface { - Swigcptr() uintptr - SwigIsFooFile() - SwigIsPropertiesFile() - SwigGetPropertiesFile() PropertiesFile - SwigIsAudioPropertiesFile() - SwigGetAudioPropertiesFile() AudioPropertiesFile -} - -type SwigcptrFLACFile uintptr - -func (p SwigcptrFLACFile) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrFLACFile) SwigIsFLACFile() { -} - -var _wrap_new_FLACFile unsafe.Pointer - -func _swig_wrap_new_FLACFile() (base SwigcptrFLACFile) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_FLACFile, _swig_p) - return -} - -func NewFLACFile() (_swig_ret FLACFile) { - return _swig_wrap_new_FLACFile() -} - -var _wrap_delete_FLACFile unsafe.Pointer - -func _swig_wrap_delete_FLACFile(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_FLACFile, _swig_p) - return -} - -func DeleteFLACFile(arg1 FLACFile) { - _swig_wrap_delete_FLACFile(arg1.Swigcptr()) -} - -type FLACFile interface { - Swigcptr() uintptr - SwigIsFLACFile() -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/namespace_class_runme b/Examples/test-suite/go/namespace_class_runme deleted file mode 100755 index 9f4c939b4..000000000 Binary files a/Examples/test-suite/go/namespace_class_runme and /dev/null differ diff --git a/Examples/test-suite/go/namespace_enum.go b/Examples/test-suite/go/namespace_enum.go deleted file mode 100644 index a2ef92b83..000000000 --- a/Examples/test-suite/go/namespace_enum.go +++ /dev/null @@ -1,117 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../namespace_enum.i - -package namespace_enum - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type FooSwig int -var _wrap_LAGER unsafe.Pointer - -func _swig_getLAGER() (_swig_ret FooSwig) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_LAGER, _swig_p) - return -} -var LAGER FooSwig = _swig_getLAGER() -var _wrap_STOUT unsafe.Pointer - -func _swig_getSTOUT() (_swig_ret FooSwig) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_STOUT, _swig_p) - return -} -var STOUT FooSwig = _swig_getSTOUT() -var _wrap_ALE unsafe.Pointer - -func _swig_getALE() (_swig_ret FooSwig) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_ALE, _swig_p) - return -} -var ALE FooSwig = _swig_getALE() -type SwigcptrBar uintptr - -func (p SwigcptrBar) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrBar) SwigIsBar() { -} - -type FooBarSpeed int -var _wrap_SLOW_Bar unsafe.Pointer - -func _swig_getBar_SLOW_Bar() (_swig_ret FooBarSpeed) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_SLOW_Bar, _swig_p) - return -} -var BarSLOW FooBarSpeed = _swig_getBar_SLOW_Bar() -var _wrap_FAST_Bar unsafe.Pointer - -func _swig_getBar_FAST_Bar() (_swig_ret FooBarSpeed) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_FAST_Bar, _swig_p) - return -} -var BarFAST FooBarSpeed = _swig_getBar_FAST_Bar() -var _wrap_new_Bar unsafe.Pointer - -func _swig_wrap_new_Bar() (base SwigcptrBar) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Bar, _swig_p) - return -} - -func NewBar() (_swig_ret Bar) { - return _swig_wrap_new_Bar() -} - -var _wrap_delete_Bar unsafe.Pointer - -func _swig_wrap_delete_Bar(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Bar, _swig_p) - return -} - -func DeleteBar(arg1 Bar) { - _swig_wrap_delete_Bar(arg1.Swigcptr()) -} - -type Bar interface { - Swigcptr() uintptr - SwigIsBar() -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/namespace_extend.go b/Examples/test-suite/go/namespace_extend.go deleted file mode 100644 index 1c544bb8b..000000000 --- a/Examples/test-suite/go/namespace_extend.go +++ /dev/null @@ -1,88 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../namespace_extend.i - -package namespace_extend - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrBar uintptr - -func (p SwigcptrBar) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrBar) SwigIsBar() { -} - -var _wrap_new_bar unsafe.Pointer - -func _swig_wrap_new_bar() (base SwigcptrBar) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_bar, _swig_p) - return -} - -func NewBar() (_swig_ret Bar) { - return _swig_wrap_new_bar() -} - -var _wrap_delete_bar unsafe.Pointer - -func _swig_wrap_delete_bar(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_bar, _swig_p) - return -} - -func DeleteBar(arg1 Bar) { - _swig_wrap_delete_bar(arg1.Swigcptr()) -} - -var _wrap_bar_blah unsafe.Pointer - -func _swig_wrap_bar_blah(base SwigcptrBar, _ int) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_bar_blah, _swig_p) - return -} - -func (arg1 SwigcptrBar) Blah(arg2 int) (_swig_ret int) { - return _swig_wrap_bar_blah(arg1, arg2) -} - -type Bar interface { - Swigcptr() uintptr - SwigIsBar() - Blah(arg2 int) (_swig_ret int) -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/namespace_forward_declaration.go b/Examples/test-suite/go/namespace_forward_declaration.go deleted file mode 100644 index 2f4999995..000000000 --- a/Examples/test-suite/go/namespace_forward_declaration.go +++ /dev/null @@ -1,211 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../namespace_forward_declaration.i - -package namespace_forward_declaration - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrYYY uintptr - -func (p SwigcptrYYY) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrYYY) SwigIsYYY() { -} - -var _wrap_YYY_yyy unsafe.Pointer - -func _swig_wrap_YYY_yyy(base SwigcptrYYY, _ int) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_YYY_yyy, _swig_p) - return -} - -func (arg1 SwigcptrYYY) Yyy(arg2 int) (_swig_ret int) { - return _swig_wrap_YYY_yyy(arg1, arg2) -} - -var _wrap_new_YYY unsafe.Pointer - -func _swig_wrap_new_YYY() (base SwigcptrYYY) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_YYY, _swig_p) - return -} - -func NewYYY() (_swig_ret YYY) { - return _swig_wrap_new_YYY() -} - -var _wrap_delete_YYY unsafe.Pointer - -func _swig_wrap_delete_YYY(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_YYY, _swig_p) - return -} - -func DeleteYYY(arg1 YYY) { - _swig_wrap_delete_YYY(arg1.Swigcptr()) -} - -type YYY interface { - Swigcptr() uintptr - SwigIsYYY() - Yyy(arg2 int) (_swig_ret int) -} - -type SwigcptrXXX uintptr - -func (p SwigcptrXXX) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrXXX) SwigIsXXX() { -} - -var _wrap_XXX_xxx unsafe.Pointer - -func _swig_wrap_XXX_xxx(base SwigcptrXXX, _ int) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_XXX_xxx, _swig_p) - return -} - -func (arg1 SwigcptrXXX) Xxx(arg2 int) (_swig_ret int) { - return _swig_wrap_XXX_xxx(arg1, arg2) -} - -var _wrap_new_XXX unsafe.Pointer - -func _swig_wrap_new_XXX() (base SwigcptrXXX) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_XXX, _swig_p) - return -} - -func NewXXX() (_swig_ret XXX) { - return _swig_wrap_new_XXX() -} - -var _wrap_delete_XXX unsafe.Pointer - -func _swig_wrap_delete_XXX(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_XXX, _swig_p) - return -} - -func DeleteXXX(arg1 XXX) { - _swig_wrap_delete_XXX(arg1.Swigcptr()) -} - -type XXX interface { - Swigcptr() uintptr - SwigIsXXX() - Xxx(arg2 int) (_swig_ret int) -} - -var _wrap_testXXX1 unsafe.Pointer - -func _swig_wrap_testXXX1(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_testXXX1, _swig_p) - return -} - -func TestXXX1(arg1 XXX) { - _swig_wrap_testXXX1(arg1.Swigcptr()) -} - -var _wrap_testXXX2 unsafe.Pointer - -func _swig_wrap_testXXX2(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_testXXX2, _swig_p) - return -} - -func TestXXX2(arg1 XXX) { - _swig_wrap_testXXX2(arg1.Swigcptr()) -} - -var _wrap_testXXX3 unsafe.Pointer - -func _swig_wrap_testXXX3(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_testXXX3, _swig_p) - return -} - -func TestXXX3(arg1 XXX) { - _swig_wrap_testXXX3(arg1.Swigcptr()) -} - -var _wrap_testYYY1 unsafe.Pointer - -func _swig_wrap_testYYY1(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_testYYY1, _swig_p) - return -} - -func TestYYY1(arg1 YYY) { - _swig_wrap_testYYY1(arg1.Swigcptr()) -} - -var _wrap_testYYY2 unsafe.Pointer - -func _swig_wrap_testYYY2(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_testYYY2, _swig_p) - return -} - -func TestYYY2(arg1 YYY) { - _swig_wrap_testYYY2(arg1.Swigcptr()) -} - -var _wrap_testYYY3 unsafe.Pointer - -func _swig_wrap_testYYY3(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_testYYY3, _swig_p) - return -} - -func TestYYY3(arg1 YYY) { - _swig_wrap_testYYY3(arg1.Swigcptr()) -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/namespace_nested.go b/Examples/test-suite/go/namespace_nested.go deleted file mode 100644 index e70205153..000000000 --- a/Examples/test-suite/go/namespace_nested.go +++ /dev/null @@ -1,339 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../namespace_nested.i - -package namespace_nested - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrHi0 uintptr - -func (p SwigcptrHi0) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrHi0) SwigIsHi0() { -} - -var _wrap_new_hi0 unsafe.Pointer - -func _swig_wrap_new_hi0() (base SwigcptrHi0) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_hi0, _swig_p) - return -} - -func NewHi0() (_swig_ret Hi0) { - return _swig_wrap_new_hi0() -} - -var _wrap_delete_hi0 unsafe.Pointer - -func _swig_wrap_delete_hi0(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_hi0, _swig_p) - return -} - -func DeleteHi0(arg1 Hi0) { - _swig_wrap_delete_hi0(arg1.Swigcptr()) -} - -type Hi0 interface { - Swigcptr() uintptr - SwigIsHi0() -} - -type SwigcptrHi_hi0 uintptr - -func (p SwigcptrHi_hi0) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrHi_hi0) SwigIsHi_hi0() { -} - -var _wrap_new_Hi_hi0 unsafe.Pointer - -func _swig_wrap_new_Hi_hi0() (base SwigcptrHi_hi0) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Hi_hi0, _swig_p) - return -} - -func NewHi_hi0() (_swig_ret Hi_hi0) { - return _swig_wrap_new_Hi_hi0() -} - -var _wrap_delete_Hi_hi0 unsafe.Pointer - -func _swig_wrap_delete_Hi_hi0(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Hi_hi0, _swig_p) - return -} - -func DeleteHi_hi0(arg1 Hi_hi0) { - _swig_wrap_delete_Hi_hi0(arg1.Swigcptr()) -} - -func (p SwigcptrHi_hi0) SwigIsHi0() { -} - -func (p SwigcptrHi_hi0) SwigGetHi0() Hi0 { - return SwigcptrHi0(p.Swigcptr()) -} - -type Hi_hi0 interface { - Swigcptr() uintptr - SwigIsHi_hi0() - SwigIsHi0() - SwigGetHi0() Hi0 -} - -type SwigcptrHi1_hi0 uintptr - -func (p SwigcptrHi1_hi0) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrHi1_hi0) SwigIsHi1_hi0() { -} - -var _wrap_new_hi1_hi0 unsafe.Pointer - -func _swig_wrap_new_hi1_hi0() (base SwigcptrHi1_hi0) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_hi1_hi0, _swig_p) - return -} - -func NewHi1_hi0() (_swig_ret Hi1_hi0) { - return _swig_wrap_new_hi1_hi0() -} - -var _wrap_delete_hi1_hi0 unsafe.Pointer - -func _swig_wrap_delete_hi1_hi0(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_hi1_hi0, _swig_p) - return -} - -func DeleteHi1_hi0(arg1 Hi1_hi0) { - _swig_wrap_delete_hi1_hi0(arg1.Swigcptr()) -} - -func (p SwigcptrHi1_hi0) SwigIsHi_hi0() { -} - -func (p SwigcptrHi1_hi0) SwigGetHi_hi0() Hi_hi0 { - return SwigcptrHi_hi0(p.Swigcptr()) -} - -func (p SwigcptrHi1_hi0) SwigIsHi0() { -} - -func (p SwigcptrHi1_hi0) SwigGetHi0() Hi0 { - return SwigcptrHi0(p.Swigcptr()) -} - -type Hi1_hi0 interface { - Swigcptr() uintptr - SwigIsHi1_hi0() - SwigIsHi_hi0() - SwigGetHi_hi0() Hi_hi0 - SwigIsHi0() - SwigGetHi0() Hi0 -} - -type SwigcptrMyFoo uintptr - -func (p SwigcptrMyFoo) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrMyFoo) SwigIsMyFoo() { -} - -var _wrap_new_MyFoo unsafe.Pointer - -func _swig_wrap_new_MyFoo() (base SwigcptrMyFoo) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_MyFoo, _swig_p) - return -} - -func NewMyFoo() (_swig_ret MyFoo) { - return _swig_wrap_new_MyFoo() -} - -var _wrap_delete_MyFoo unsafe.Pointer - -func _swig_wrap_delete_MyFoo(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_MyFoo, _swig_p) - return -} - -func DeleteMyFoo(arg1 MyFoo) { - _swig_wrap_delete_MyFoo(arg1.Swigcptr()) -} - -type MyFoo interface { - Swigcptr() uintptr - SwigIsMyFoo() -} - -type SwigcptrBar uintptr - -func (p SwigcptrBar) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrBar) SwigIsBar() { -} - -var _wrap_new_Bar unsafe.Pointer - -func _swig_wrap_new_Bar() (base SwigcptrBar) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Bar, _swig_p) - return -} - -func NewBar() (_swig_ret Bar) { - return _swig_wrap_new_Bar() -} - -var _wrap_delete_Bar unsafe.Pointer - -func _swig_wrap_delete_Bar(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Bar, _swig_p) - return -} - -func DeleteBar(arg1 Bar) { - _swig_wrap_delete_Bar(arg1.Swigcptr()) -} - -type Bar interface { - Swigcptr() uintptr - SwigIsBar() -} - -type SwigcptrFoo uintptr - -func (p SwigcptrFoo) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrFoo) SwigIsFoo() { -} - -var _wrap_new_Foo unsafe.Pointer - -func _swig_wrap_new_Foo() (base SwigcptrFoo) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Foo, _swig_p) - return -} - -func NewFoo() (_swig_ret Foo) { - return _swig_wrap_new_Foo() -} - -var _wrap_delete_Foo unsafe.Pointer - -func _swig_wrap_delete_Foo(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Foo, _swig_p) - return -} - -func DeleteFoo(arg1 Foo) { - _swig_wrap_delete_Foo(arg1.Swigcptr()) -} - -type Foo interface { - Swigcptr() uintptr - SwigIsFoo() -} - -type SwigcptrConnectedSubgraphFinder uintptr - -func (p SwigcptrConnectedSubgraphFinder) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrConnectedSubgraphFinder) SwigIsConnectedSubgraphFinder() { -} - -var _wrap_new_ConnectedSubgraphFinder unsafe.Pointer - -func _swig_wrap_new_ConnectedSubgraphFinder(base int) (_ SwigcptrConnectedSubgraphFinder) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_ConnectedSubgraphFinder, _swig_p) - return -} - -func NewConnectedSubgraphFinder(arg1 int) (_swig_ret ConnectedSubgraphFinder) { - return _swig_wrap_new_ConnectedSubgraphFinder(arg1) -} - -var _wrap_delete_ConnectedSubgraphFinder unsafe.Pointer - -func _swig_wrap_delete_ConnectedSubgraphFinder(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_ConnectedSubgraphFinder, _swig_p) - return -} - -func DeleteConnectedSubgraphFinder(arg1 ConnectedSubgraphFinder) { - _swig_wrap_delete_ConnectedSubgraphFinder(arg1.Swigcptr()) -} - -func (p SwigcptrConnectedSubgraphFinder) SwigIsFoo() { -} - -func (p SwigcptrConnectedSubgraphFinder) SwigGetFoo() Foo { - return SwigcptrFoo(p.Swigcptr()) -} - -type ConnectedSubgraphFinder interface { - Swigcptr() uintptr - SwigIsConnectedSubgraphFinder() - SwigIsFoo() - SwigGetFoo() Foo -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/namespace_spaces.go b/Examples/test-suite/go/namespace_spaces.go deleted file mode 100644 index 56a8904e0..000000000 --- a/Examples/test-suite/go/namespace_spaces.go +++ /dev/null @@ -1,140 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../namespace_spaces.i - -package namespace_spaces - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrFoo uintptr - -func (p SwigcptrFoo) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrFoo) SwigIsFoo() { -} - -var _wrap_new_Foo unsafe.Pointer - -func _swig_wrap_new_Foo() (base SwigcptrFoo) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Foo, _swig_p) - return -} - -func NewFoo() (_swig_ret Foo) { - return _swig_wrap_new_Foo() -} - -var _wrap_delete_Foo unsafe.Pointer - -func _swig_wrap_delete_Foo(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Foo, _swig_p) - return -} - -func DeleteFoo(arg1 Foo) { - _swig_wrap_delete_Foo(arg1.Swigcptr()) -} - -var _wrap_Foo_blah unsafe.Pointer - -func _swig_wrap_Foo_blah(base SwigcptrFoo, _ int) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_blah, _swig_p) - return -} - -func (arg1 SwigcptrFoo) Blah(arg2 int) (_swig_ret int) { - return _swig_wrap_Foo_blah(arg1, arg2) -} - -var _wrap_Foo_spam unsafe.Pointer - -func _swig_wrap_Foo_spam(base SwigcptrFoo, _ int) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_spam, _swig_p) - return -} - -func (arg1 SwigcptrFoo) Spam(arg2 int) (_swig_ret int) { - return _swig_wrap_Foo_spam(arg1, arg2) -} - -var _wrap_Foo_bar unsafe.Pointer - -func _swig_wrap_Foo_bar(base SwigcptrFoo, _ int) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_bar, _swig_p) - return -} - -func (arg1 SwigcptrFoo) Bar(arg2 int) (_swig_ret int) { - return _swig_wrap_Foo_bar(arg1, arg2) -} - -var _wrap_Foo_func_ptr_set unsafe.Pointer - -func _swig_wrap_Foo_func_ptr_set(base SwigcptrFoo, _ _swig_memberptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_func_ptr_set, _swig_p) - return -} - -func (arg1 SwigcptrFoo) SetFunc_ptr(arg2 _swig_memberptr) { - _swig_wrap_Foo_func_ptr_set(arg1, arg2) -} - -var _wrap_Foo_func_ptr_get unsafe.Pointer - -func _swig_wrap_Foo_func_ptr_get(base SwigcptrFoo) (_ _swig_memberptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_func_ptr_get, _swig_p) - return -} - -func (arg1 SwigcptrFoo) GetFunc_ptr() (_swig_ret _swig_memberptr) { - return _swig_wrap_Foo_func_ptr_get(arg1) -} - -type Foo interface { - Swigcptr() uintptr - SwigIsFoo() - Blah(arg2 int) (_swig_ret int) - Spam(arg2 int) (_swig_ret int) - Bar(arg2 int) (_swig_ret int) - SetFunc_ptr(arg2 _swig_memberptr) - GetFunc_ptr() (_swig_ret _swig_memberptr) -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/namespace_template.go b/Examples/test-suite/go/namespace_template.go deleted file mode 100644 index 4af8c70f0..000000000 --- a/Examples/test-suite/go/namespace_template.go +++ /dev/null @@ -1,269 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../namespace_template.i - -package namespace_template - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -var _wrap_maxint unsafe.Pointer - -func Maxint(arg1 int, arg2 int) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_maxint, _swig_p) - return -} -type SwigcptrVectorint uintptr - -func (p SwigcptrVectorint) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrVectorint) SwigIsVectorint() { -} - -var _wrap_new_vectorint unsafe.Pointer - -func _swig_wrap_new_vectorint() (base SwigcptrVectorint) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_vectorint, _swig_p) - return -} - -func NewVectorint() (_swig_ret Vectorint) { - return _swig_wrap_new_vectorint() -} - -var _wrap_delete_vectorint unsafe.Pointer - -func _swig_wrap_delete_vectorint(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_vectorint, _swig_p) - return -} - -func DeleteVectorint(arg1 Vectorint) { - _swig_wrap_delete_vectorint(arg1.Swigcptr()) -} - -var _wrap_vectorint_blah unsafe.Pointer - -func _swig_wrap_vectorint_blah(base SwigcptrVectorint, _ int) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_vectorint_blah, _swig_p) - return -} - -func (arg1 SwigcptrVectorint) Blah(arg2 int) (_swig_ret string) { - return _swig_wrap_vectorint_blah(arg1, arg2) -} - -type Vectorint interface { - Swigcptr() uintptr - SwigIsVectorint() - Blah(arg2 int) (_swig_ret string) -} - -var _wrap_maxshort unsafe.Pointer - -func Maxshort(arg1 int16, arg2 int16) (_swig_ret int16) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_maxshort, _swig_p) - return -} -type SwigcptrVectorshort uintptr - -func (p SwigcptrVectorshort) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrVectorshort) SwigIsVectorshort() { -} - -var _wrap_new_vectorshort unsafe.Pointer - -func _swig_wrap_new_vectorshort() (base SwigcptrVectorshort) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_vectorshort, _swig_p) - return -} - -func NewVectorshort() (_swig_ret Vectorshort) { - return _swig_wrap_new_vectorshort() -} - -var _wrap_delete_vectorshort unsafe.Pointer - -func _swig_wrap_delete_vectorshort(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_vectorshort, _swig_p) - return -} - -func DeleteVectorshort(arg1 Vectorshort) { - _swig_wrap_delete_vectorshort(arg1.Swigcptr()) -} - -var _wrap_vectorshort_blah unsafe.Pointer - -func _swig_wrap_vectorshort_blah(base SwigcptrVectorshort, _ int16) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_vectorshort_blah, _swig_p) - return -} - -func (arg1 SwigcptrVectorshort) Blah(arg2 int16) (_swig_ret string) { - return _swig_wrap_vectorshort_blah(arg1, arg2) -} - -type Vectorshort interface { - Swigcptr() uintptr - SwigIsVectorshort() - Blah(arg2 int16) (_swig_ret string) -} - -var _wrap_maxlong unsafe.Pointer - -func Maxlong(arg1 int64, arg2 int64) (_swig_ret int64) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_maxlong, _swig_p) - return -} -type SwigcptrVectorlong uintptr - -func (p SwigcptrVectorlong) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrVectorlong) SwigIsVectorlong() { -} - -var _wrap_new_vectorlong unsafe.Pointer - -func _swig_wrap_new_vectorlong() (base SwigcptrVectorlong) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_vectorlong, _swig_p) - return -} - -func NewVectorlong() (_swig_ret Vectorlong) { - return _swig_wrap_new_vectorlong() -} - -var _wrap_delete_vectorlong unsafe.Pointer - -func _swig_wrap_delete_vectorlong(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_vectorlong, _swig_p) - return -} - -func DeleteVectorlong(arg1 Vectorlong) { - _swig_wrap_delete_vectorlong(arg1.Swigcptr()) -} - -var _wrap_vectorlong_blah unsafe.Pointer - -func _swig_wrap_vectorlong_blah(base SwigcptrVectorlong, _ int64) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_vectorlong_blah, _swig_p) - return -} - -func (arg1 SwigcptrVectorlong) Blah(arg2 int64) (_swig_ret string) { - return _swig_wrap_vectorlong_blah(arg1, arg2) -} - -type Vectorlong interface { - Swigcptr() uintptr - SwigIsVectorlong() - Blah(arg2 int64) (_swig_ret string) -} - -var _wrap_maxInteger unsafe.Pointer - -func MaxInteger(arg1 int, arg2 int) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_maxInteger, _swig_p) - return -} -type SwigcptrVectorInteger uintptr - -func (p SwigcptrVectorInteger) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrVectorInteger) SwigIsVectorInteger() { -} - -var _wrap_new_vectorInteger unsafe.Pointer - -func _swig_wrap_new_vectorInteger() (base SwigcptrVectorInteger) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_vectorInteger, _swig_p) - return -} - -func NewVectorInteger() (_swig_ret VectorInteger) { - return _swig_wrap_new_vectorInteger() -} - -var _wrap_delete_vectorInteger unsafe.Pointer - -func _swig_wrap_delete_vectorInteger(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_vectorInteger, _swig_p) - return -} - -func DeleteVectorInteger(arg1 VectorInteger) { - _swig_wrap_delete_vectorInteger(arg1.Swigcptr()) -} - -var _wrap_vectorInteger_blah unsafe.Pointer - -func _swig_wrap_vectorInteger_blah(base SwigcptrVectorInteger, _ int) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_vectorInteger_blah, _swig_p) - return -} - -func (arg1 SwigcptrVectorInteger) Blah(arg2 int) (_swig_ret string) { - return _swig_wrap_vectorInteger_blah(arg1, arg2) -} - -type VectorInteger interface { - Swigcptr() uintptr - SwigIsVectorInteger() - Blah(arg2 int) (_swig_ret string) -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/namespace_typedef_class.go b/Examples/test-suite/go/namespace_typedef_class.go deleted file mode 100644 index 8e8448e5c..000000000 --- a/Examples/test-suite/go/namespace_typedef_class.go +++ /dev/null @@ -1,165 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../namespace_typedef_class.i - -package namespace_typedef_class - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrS1 uintptr - -func (p SwigcptrS1) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrS1) SwigIsS1() { -} - -var _wrap_S1_n_set unsafe.Pointer - -func _swig_wrap_S1_n_set(base SwigcptrS1, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_S1_n_set, _swig_p) - return -} - -func (arg1 SwigcptrS1) SetN(arg2 int) { - _swig_wrap_S1_n_set(arg1, arg2) -} - -var _wrap_S1_n_get unsafe.Pointer - -func _swig_wrap_S1_n_get(base SwigcptrS1) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_S1_n_get, _swig_p) - return -} - -func (arg1 SwigcptrS1) GetN() (_swig_ret int) { - return _swig_wrap_S1_n_get(arg1) -} - -var _wrap_new_S1 unsafe.Pointer - -func _swig_wrap_new_S1() (base SwigcptrS1) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_S1, _swig_p) - return -} - -func NewS1() (_swig_ret S1) { - return _swig_wrap_new_S1() -} - -var _wrap_delete_S1 unsafe.Pointer - -func _swig_wrap_delete_S1(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_S1, _swig_p) - return -} - -func DeleteS1(arg1 S1) { - _swig_wrap_delete_S1(arg1.Swigcptr()) -} - -type S1 interface { - Swigcptr() uintptr - SwigIsS1() - SetN(arg2 int) - GetN() (_swig_ret int) -} - -type SwigcptrS2 uintptr - -func (p SwigcptrS2) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrS2) SwigIsS2() { -} - -var _wrap_S2_n_set unsafe.Pointer - -func _swig_wrap_S2_n_set(base SwigcptrS2, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_S2_n_set, _swig_p) - return -} - -func (arg1 SwigcptrS2) SetN(arg2 int) { - _swig_wrap_S2_n_set(arg1, arg2) -} - -var _wrap_S2_n_get unsafe.Pointer - -func _swig_wrap_S2_n_get(base SwigcptrS2) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_S2_n_get, _swig_p) - return -} - -func (arg1 SwigcptrS2) GetN() (_swig_ret int) { - return _swig_wrap_S2_n_get(arg1) -} - -var _wrap_new_S2 unsafe.Pointer - -func _swig_wrap_new_S2() (base SwigcptrS2) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_S2, _swig_p) - return -} - -func NewS2() (_swig_ret S2) { - return _swig_wrap_new_S2() -} - -var _wrap_delete_S2 unsafe.Pointer - -func _swig_wrap_delete_S2(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_S2, _swig_p) - return -} - -func DeleteS2(arg1 S2) { - _swig_wrap_delete_S2(arg1.Swigcptr()) -} - -type S2 interface { - Swigcptr() uintptr - SwigIsS2() - SetN(arg2 int) - GetN() (_swig_ret int) -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/namespace_typemap.go b/Examples/test-suite/go/namespace_typemap.go deleted file mode 100644 index 5fdb44d84..000000000 --- a/Examples/test-suite/go/namespace_typemap.go +++ /dev/null @@ -1,204 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../namespace_typemap.i - -package namespace_typemap - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -var _wrap_stest1 unsafe.Pointer - -func Stest1(arg1 string) (_swig_ret string) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_stest1, _swig_p) - return -} -var _wrap_ctest1 unsafe.Pointer - -func Ctest1(arg1 complex128) (_swig_ret float64) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_ctest1, _swig_p) - return -} -var _wrap_stest2 unsafe.Pointer - -func Stest2(arg1 string) (_swig_ret string) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_stest2, _swig_p) - return -} -var _wrap_ctest2 unsafe.Pointer - -func Ctest2(arg1 complex128) (_swig_ret float64) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_ctest2, _swig_p) - return -} -var _wrap_stest3 unsafe.Pointer - -func Stest3(arg1 string) (_swig_ret string) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_stest3, _swig_p) - return -} -var _wrap_ctest3 unsafe.Pointer - -func Ctest3(arg1 complex128) (_swig_ret float64) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_ctest3, _swig_p) - return -} -var _wrap_stest4 unsafe.Pointer - -func Stest4(arg1 string) (_swig_ret string) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_stest4, _swig_p) - return -} -var _wrap_ctest4 unsafe.Pointer - -func Ctest4(arg1 complex128) (_swig_ret float64) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_ctest4, _swig_p) - return -} -var _wrap_stest5 unsafe.Pointer - -func Stest5(arg1 string) (_swig_ret string) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_stest5, _swig_p) - return -} -var _wrap_ctest5 unsafe.Pointer - -func Ctest5(arg1 complex128) (_swig_ret float64) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_ctest5, _swig_p) - return -} -var _wrap_stest6 unsafe.Pointer - -func Stest6(arg1 string) (_swig_ret string) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_stest6, _swig_p) - return -} -var _wrap_ctest6 unsafe.Pointer - -func Ctest6(arg1 complex128) (_swig_ret float64) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_ctest6, _swig_p) - return -} -var _wrap_stest7 unsafe.Pointer - -func Stest7(arg1 string) (_swig_ret string) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_stest7, _swig_p) - return -} -var _wrap_ctest7 unsafe.Pointer - -func Ctest7(arg1 complex128) (_swig_ret float64) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_ctest7, _swig_p) - return -} -var _wrap_stest8 unsafe.Pointer - -func Stest8(arg1 string) (_swig_ret string) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_stest8, _swig_p) - return -} -var _wrap_ctest8 unsafe.Pointer - -func Ctest8(arg1 complex128) (_swig_ret float64) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_ctest8, _swig_p) - return -} -var _wrap_stest9 unsafe.Pointer - -func Stest9(arg1 string) (_swig_ret string) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_stest9, _swig_p) - return -} -var _wrap_ctest9 unsafe.Pointer - -func Ctest9(arg1 complex128) (_swig_ret float64) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_ctest9, _swig_p) - return -} -var _wrap_stest10 unsafe.Pointer - -func Stest10(arg1 string) (_swig_ret string) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_stest10, _swig_p) - return -} -var _wrap_ctest10 unsafe.Pointer - -func Ctest10(arg1 complex128) (_swig_ret float64) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_ctest10, _swig_p) - return -} -var _wrap_stest11 unsafe.Pointer - -func Stest11(arg1 string) (_swig_ret string) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_stest11, _swig_p) - return -} -var _wrap_ctest11 unsafe.Pointer - -func Ctest11(arg1 complex128) (_swig_ret float64) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_ctest11, _swig_p) - return -} -var _wrap_stest12 unsafe.Pointer - -func Stest12(arg1 string) (_swig_ret string) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_stest12, _swig_p) - return -} -var _wrap_ctest12 unsafe.Pointer - -func Ctest12(arg1 complex128) (_swig_ret float64) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_ctest12, _swig_p) - return -} -var _wrap_ttest1 unsafe.Pointer - -func Ttest1(arg1 int) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_ttest1, _swig_p) - return -} - diff --git a/Examples/test-suite/go/namespace_typemap_runme b/Examples/test-suite/go/namespace_typemap_runme deleted file mode 100755 index 18ebaa3c4..000000000 Binary files a/Examples/test-suite/go/namespace_typemap_runme and /dev/null differ diff --git a/Examples/test-suite/go/namespace_union.go b/Examples/test-suite/go/namespace_union.go deleted file mode 100644 index a6754d656..000000000 --- a/Examples/test-suite/go/namespace_union.go +++ /dev/null @@ -1,101 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../namespace_union.i - -package namespace_union - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrVariant uintptr - -func (p SwigcptrVariant) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrVariant) SwigIsVariant() { -} - -var _wrap_new_Variant unsafe.Pointer - -func _swig_wrap_new_Variant() (base SwigcptrVariant) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Variant, _swig_p) - return -} - -func NewVariant() (_swig_ret Variant) { - return _swig_wrap_new_Variant() -} - -var _wrap_Variant_varType_set unsafe.Pointer - -func _swig_wrap_Variant_varType_set(base SwigcptrVariant, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Variant_varType_set, _swig_p) - return -} - -func (arg1 SwigcptrVariant) SetVarType(arg2 int) { - _swig_wrap_Variant_varType_set(arg1, arg2) -} - -var _wrap_Variant_varType_get unsafe.Pointer - -func _swig_wrap_Variant_varType_get(base SwigcptrVariant) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Variant_varType_get, _swig_p) - return -} - -func (arg1 SwigcptrVariant) GetVarType() (_swig_ret int) { - return _swig_wrap_Variant_varType_get(arg1) -} - -var _wrap_delete_Variant unsafe.Pointer - -func _swig_wrap_delete_Variant(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Variant, _swig_p) - return -} - -func DeleteVariant(arg1 Variant) { - _swig_wrap_delete_Variant(arg1.Swigcptr()) -} - -type Variant interface { - Swigcptr() uintptr - SwigIsVariant() - SetVarType(arg2 int) - GetVarType() (_swig_ret int) -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/namespace_virtual_method.go b/Examples/test-suite/go/namespace_virtual_method.go deleted file mode 100644 index 5f391ead6..000000000 --- a/Examples/test-suite/go/namespace_virtual_method.go +++ /dev/null @@ -1,144 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../namespace_virtual_method.i - -package namespace_virtual_method - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrFoo uintptr - -func (p SwigcptrFoo) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrFoo) SwigIsFoo() { -} - -var _wrap_delete_Foo unsafe.Pointer - -func _swig_wrap_delete_Foo(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Foo, _swig_p) - return -} - -func DeleteFoo(arg1 Foo) { - _swig_wrap_delete_Foo(arg1.Swigcptr()) -} - -var _wrap_Foo_bar unsafe.Pointer - -func _swig_wrap_Foo_bar(base SwigcptrFoo, _ uintptr) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_bar, _swig_p) - return -} - -func (arg1 SwigcptrFoo) Bar(arg2 A_B_Foo) (_swig_ret int) { - return _swig_wrap_Foo_bar(arg1, arg2.Swigcptr()) -} - -type Foo interface { - Swigcptr() uintptr - SwigIsFoo() - Bar(arg2 A_B_Foo) (_swig_ret int) -} - -type SwigcptrSpam uintptr - -func (p SwigcptrSpam) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrSpam) SwigIsSpam() { -} - -var _wrap_new_Spam unsafe.Pointer - -func _swig_wrap_new_Spam() (base SwigcptrSpam) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Spam, _swig_p) - return -} - -func NewSpam() (_swig_ret Spam) { - return _swig_wrap_new_Spam() -} - -var _wrap_delete_Spam unsafe.Pointer - -func _swig_wrap_delete_Spam(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Spam, _swig_p) - return -} - -func DeleteSpam(arg1 Spam) { - _swig_wrap_delete_Spam(arg1.Swigcptr()) -} - -var _wrap_Spam_bar unsafe.Pointer - -func _swig_wrap_Spam_bar(base SwigcptrSpam, _ uintptr) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Spam_bar, _swig_p) - return -} - -func (arg1 SwigcptrSpam) Bar(arg2 A_B_Foo) (_swig_ret int) { - return _swig_wrap_Spam_bar(arg1, arg2.Swigcptr()) -} - -func (p SwigcptrSpam) SwigIsFoo() { -} - -func (p SwigcptrSpam) SwigGetFoo() Foo { - return SwigcptrFoo(p.Swigcptr()) -} - -type Spam interface { - Swigcptr() uintptr - SwigIsSpam() - Bar(arg2 A_B_Foo) (_swig_ret int) - SwigIsFoo() - SwigGetFoo() Foo -} - - -type SwigcptrA_B_Foo uintptr -type A_B_Foo interface { - Swigcptr() uintptr; -} -func (p SwigcptrA_B_Foo) Swigcptr() uintptr { - return uintptr(p) -} - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/namespace_virtual_method_runme b/Examples/test-suite/go/namespace_virtual_method_runme deleted file mode 100755 index 45d022639..000000000 Binary files a/Examples/test-suite/go/namespace_virtual_method_runme and /dev/null differ diff --git a/Examples/test-suite/go/naturalvar.go b/Examples/test-suite/go/naturalvar.go deleted file mode 100644 index d7120476a..000000000 --- a/Examples/test-suite/go/naturalvar.go +++ /dev/null @@ -1,234 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../naturalvar.i - -package naturalvar - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrFoo uintptr - -func (p SwigcptrFoo) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrFoo) SwigIsFoo() { -} - -var _wrap_new_Foo unsafe.Pointer - -func _swig_wrap_new_Foo() (base SwigcptrFoo) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Foo, _swig_p) - return -} - -func NewFoo() (_swig_ret Foo) { - return _swig_wrap_new_Foo() -} - -var _wrap_delete_Foo unsafe.Pointer - -func _swig_wrap_delete_Foo(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Foo, _swig_p) - return -} - -func DeleteFoo(arg1 Foo) { - _swig_wrap_delete_Foo(arg1.Swigcptr()) -} - -type Foo interface { - Swigcptr() uintptr - SwigIsFoo() -} - -var _wrap_f_set unsafe.Pointer - -func _swig_wrap_f_set(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_f_set, _swig_p) - return -} - -func SetF(arg1 Foo) { - _swig_wrap_f_set(arg1.Swigcptr()) -} - -var _wrap_f_get unsafe.Pointer - -func _swig_wrap_f_get() (base SwigcptrFoo) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_f_get, _swig_p) - return -} - -func GetF() (_swig_ret Foo) { - return _swig_wrap_f_get() -} - -var _wrap_s_set unsafe.Pointer - -func _swig_wrap_s_set(base string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_s_set, _swig_p) - return -} - -func SetS(arg1 string) { - _swig_wrap_s_set(arg1) -} - -var _wrap_s_get unsafe.Pointer - -func GetS() (_swig_ret string) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_s_get, _swig_p) - return -} -type SwigcptrBar uintptr - -func (p SwigcptrBar) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrBar) SwigIsBar() { -} - -var _wrap_Bar_i_set unsafe.Pointer - -func _swig_wrap_Bar_i_set(base SwigcptrBar, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Bar_i_set, _swig_p) - return -} - -func (arg1 SwigcptrBar) SetI(arg2 int) { - _swig_wrap_Bar_i_set(arg1, arg2) -} - -var _wrap_Bar_i_get unsafe.Pointer - -func _swig_wrap_Bar_i_get(base SwigcptrBar) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Bar_i_get, _swig_p) - return -} - -func (arg1 SwigcptrBar) GetI() (_swig_ret int) { - return _swig_wrap_Bar_i_get(arg1) -} - -var _wrap_Bar_f_set unsafe.Pointer - -func _swig_wrap_Bar_f_set(base SwigcptrBar, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Bar_f_set, _swig_p) - return -} - -func (arg1 SwigcptrBar) SetF(arg2 Foo) { - _swig_wrap_Bar_f_set(arg1, arg2.Swigcptr()) -} - -var _wrap_Bar_f_get unsafe.Pointer - -func _swig_wrap_Bar_f_get(base SwigcptrBar) (_ SwigcptrFoo) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Bar_f_get, _swig_p) - return -} - -func (arg1 SwigcptrBar) GetF() (_swig_ret Foo) { - return _swig_wrap_Bar_f_get(arg1) -} - -var _wrap_Bar_s_set unsafe.Pointer - -func _swig_wrap_Bar_s_set(base SwigcptrBar, _ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Bar_s_set, _swig_p) - return -} - -func (arg1 SwigcptrBar) SetS(arg2 string) { - _swig_wrap_Bar_s_set(arg1, arg2) -} - -var _wrap_Bar_s_get unsafe.Pointer - -func _swig_wrap_Bar_s_get(base SwigcptrBar) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Bar_s_get, _swig_p) - return -} - -func (arg1 SwigcptrBar) GetS() (_swig_ret string) { - return _swig_wrap_Bar_s_get(arg1) -} - -var _wrap_new_Bar unsafe.Pointer - -func _swig_wrap_new_Bar() (base SwigcptrBar) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Bar, _swig_p) - return -} - -func NewBar() (_swig_ret Bar) { - return _swig_wrap_new_Bar() -} - -var _wrap_delete_Bar unsafe.Pointer - -func _swig_wrap_delete_Bar(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Bar, _swig_p) - return -} - -func DeleteBar(arg1 Bar) { - _swig_wrap_delete_Bar(arg1.Swigcptr()) -} - -type Bar interface { - Swigcptr() uintptr - SwigIsBar() - SetI(arg2 int) - GetI() (_swig_ret int) - SetF(arg2 Foo) - GetF() (_swig_ret Foo) - SetS(arg2 string) - GetS() (_swig_ret string) -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/naturalvar_more.go b/Examples/test-suite/go/naturalvar_more.go deleted file mode 100644 index 3cbada1bb..000000000 --- a/Examples/test-suite/go/naturalvar_more.go +++ /dev/null @@ -1,506 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../naturalvar_more.i - -package naturalvar_more - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrK uintptr - -func (p SwigcptrK) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrK) SwigIsK() { -} - -var _wrap_new_K unsafe.Pointer - -func _swig_wrap_new_K() (base SwigcptrK) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_K, _swig_p) - return -} - -func NewK() (_swig_ret K) { - return _swig_wrap_new_K() -} - -var _wrap_delete_K unsafe.Pointer - -func _swig_wrap_delete_K(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_K, _swig_p) - return -} - -func DeleteK(arg1 K) { - _swig_wrap_delete_K(arg1.Swigcptr()) -} - -type K interface { - Swigcptr() uintptr - SwigIsK() -} - -var _wrap_glob_set unsafe.Pointer - -func _swig_wrap_glob_set(base int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_glob_set, _swig_p) - return -} - -func SetGlob(arg1 int) { - _swig_wrap_glob_set(arg1) -} - -var _wrap_glob_get unsafe.Pointer - -func GetGlob() (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_glob_get, _swig_p) - return -} -type SpaceE int -var _wrap_E1 unsafe.Pointer - -func _swig_getE1() (_swig_ret SpaceE) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_E1, _swig_p) - return -} -var E1 SpaceE = _swig_getE1() -var _wrap_E2 unsafe.Pointer - -func _swig_getE2() (_swig_ret SpaceE) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_E2, _swig_p) - return -} -var E2 SpaceE = _swig_getE2() -var _wrap_E3 unsafe.Pointer - -func _swig_getE3() (_swig_ret SpaceE) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_E3, _swig_p) - return -} -var E3 SpaceE = _swig_getE3() -type SwigcptrTE uintptr - -func (p SwigcptrTE) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrTE) SwigIsTE() { -} - -var _wrap_new_TE unsafe.Pointer - -func _swig_wrap_new_TE() (base SwigcptrTE) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_TE, _swig_p) - return -} - -func NewTE() (_swig_ret TE) { - return _swig_wrap_new_TE() -} - -var _wrap_delete_TE unsafe.Pointer - -func _swig_wrap_delete_TE(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_TE, _swig_p) - return -} - -func DeleteTE(arg1 TE) { - _swig_wrap_delete_TE(arg1.Swigcptr()) -} - -type TE interface { - Swigcptr() uintptr - SwigIsTE() -} - -type SwigcptrVectorString uintptr - -func (p SwigcptrVectorString) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrVectorString) SwigIsVectorString() { -} - -var _wrap_new_VectorString__SWIG_0 unsafe.Pointer - -func _swig_wrap_new_VectorString__SWIG_0() (base SwigcptrVectorString) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_VectorString__SWIG_0, _swig_p) - return -} - -func NewVectorString__SWIG_0() (_swig_ret VectorString) { - return _swig_wrap_new_VectorString__SWIG_0() -} - -var _wrap_new_VectorString__SWIG_1 unsafe.Pointer - -func _swig_wrap_new_VectorString__SWIG_1(base int64) (_ SwigcptrVectorString) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_VectorString__SWIG_1, _swig_p) - return -} - -func NewVectorString__SWIG_1(arg1 int64) (_swig_ret VectorString) { - return _swig_wrap_new_VectorString__SWIG_1(arg1) -} - -func NewVectorString(a ...interface{}) VectorString { - argc := len(a) - if argc == 0 { - return NewVectorString__SWIG_0() - } - if argc == 1 { - return NewVectorString__SWIG_1(a[0].(int64)) - } - panic("No match for overloaded function call") -} - -var _wrap_VectorString_size unsafe.Pointer - -func _swig_wrap_VectorString_size(base SwigcptrVectorString) (_ int64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_VectorString_size, _swig_p) - return -} - -func (arg1 SwigcptrVectorString) Size() (_swig_ret int64) { - return _swig_wrap_VectorString_size(arg1) -} - -var _wrap_VectorString_capacity unsafe.Pointer - -func _swig_wrap_VectorString_capacity(base SwigcptrVectorString) (_ int64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_VectorString_capacity, _swig_p) - return -} - -func (arg1 SwigcptrVectorString) Capacity() (_swig_ret int64) { - return _swig_wrap_VectorString_capacity(arg1) -} - -var _wrap_VectorString_reserve unsafe.Pointer - -func _swig_wrap_VectorString_reserve(base SwigcptrVectorString, _ int64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_VectorString_reserve, _swig_p) - return -} - -func (arg1 SwigcptrVectorString) Reserve(arg2 int64) { - _swig_wrap_VectorString_reserve(arg1, arg2) -} - -var _wrap_VectorString_isEmpty unsafe.Pointer - -func _swig_wrap_VectorString_isEmpty(base SwigcptrVectorString) (_ bool) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_VectorString_isEmpty, _swig_p) - return -} - -func (arg1 SwigcptrVectorString) IsEmpty() (_swig_ret bool) { - return _swig_wrap_VectorString_isEmpty(arg1) -} - -var _wrap_VectorString_clear unsafe.Pointer - -func _swig_wrap_VectorString_clear(base SwigcptrVectorString) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_VectorString_clear, _swig_p) - return -} - -func (arg1 SwigcptrVectorString) Clear() { - _swig_wrap_VectorString_clear(arg1) -} - -var _wrap_VectorString_add unsafe.Pointer - -func _swig_wrap_VectorString_add(base SwigcptrVectorString, _ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_VectorString_add, _swig_p) - return -} - -func (arg1 SwigcptrVectorString) Add(arg2 string) { - _swig_wrap_VectorString_add(arg1, arg2) -} - -var _wrap_VectorString_get unsafe.Pointer - -func _swig_wrap_VectorString_get(base SwigcptrVectorString, _ int) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_VectorString_get, _swig_p) - return -} - -func (arg1 SwigcptrVectorString) Get(arg2 int) (_swig_ret string) { - return _swig_wrap_VectorString_get(arg1, arg2) -} - -var _wrap_VectorString_set unsafe.Pointer - -func _swig_wrap_VectorString_set(base SwigcptrVectorString, _ int, _ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_VectorString_set, _swig_p) - return -} - -func (arg1 SwigcptrVectorString) Set(arg2 int, arg3 string) { - _swig_wrap_VectorString_set(arg1, arg2, arg3) -} - -var _wrap_delete_VectorString unsafe.Pointer - -func _swig_wrap_delete_VectorString(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_VectorString, _swig_p) - return -} - -func DeleteVectorString(arg1 VectorString) { - _swig_wrap_delete_VectorString(arg1.Swigcptr()) -} - -type VectorString interface { - Swigcptr() uintptr - SwigIsVectorString() - Size() (_swig_ret int64) - Capacity() (_swig_ret int64) - Reserve(arg2 int64) - IsEmpty() (_swig_ret bool) - Clear() - Add(arg2 string) - Get(arg2 int) (_swig_ret string) - Set(arg2 int, arg3 string) -} - -type SwigcptrS uintptr - -func (p SwigcptrS) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrS) SwigIsS() { -} - -var _wrap_S_te_set unsafe.Pointer - -func _swig_wrap_S_te_set(base SwigcptrS, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_S_te_set, _swig_p) - return -} - -func (arg1 SwigcptrS) SetTe(arg2 TE) { - _swig_wrap_S_te_set(arg1, arg2.Swigcptr()) -} - -var _wrap_S_te_get unsafe.Pointer - -func _swig_wrap_S_te_get(base SwigcptrS) (_ SwigcptrTE) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_S_te_get, _swig_p) - return -} - -func (arg1 SwigcptrS) GetTe() (_swig_ret TE) { - return _swig_wrap_S_te_get(arg1) -} - -var _wrap_S_const_te_get unsafe.Pointer - -func _swig_wrap_S_const_te_get(base SwigcptrS) (_ SwigcptrTE) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_S_const_te_get, _swig_p) - return -} - -func (arg1 SwigcptrS) GetConst_te() (_swig_ret TE) { - return _swig_wrap_S_const_te_get(arg1) -} - -var _wrap_S_const_string_member_get unsafe.Pointer - -func _swig_wrap_S_const_string_member_get(base SwigcptrS) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_S_const_string_member_get, _swig_p) - return -} - -func (arg1 SwigcptrS) GetConst_string_member() (_swig_ret string) { - return _swig_wrap_S_const_string_member_get(arg1) -} - -var _wrap_S_string_member_set unsafe.Pointer - -func _swig_wrap_S_string_member_set(base SwigcptrS, _ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_S_string_member_set, _swig_p) - return -} - -func (arg1 SwigcptrS) SetString_member(arg2 string) { - _swig_wrap_S_string_member_set(arg1, arg2) -} - -var _wrap_S_string_member_get unsafe.Pointer - -func _swig_wrap_S_string_member_get(base SwigcptrS) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_S_string_member_get, _swig_p) - return -} - -func (arg1 SwigcptrS) GetString_member() (_swig_ret string) { - return _swig_wrap_S_string_member_get(arg1) -} - -var _wrap_S_hidden_set unsafe.Pointer - -func _swig_wrap_S_hidden_set(base SwigcptrS, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_S_hidden_set, _swig_p) - return -} - -func (arg1 SwigcptrS) SetHidden(arg2 Hidden) { - _swig_wrap_S_hidden_set(arg1, arg2.Swigcptr()) -} - -var _wrap_S_hidden_get unsafe.Pointer - -func _swig_wrap_S_hidden_get(base SwigcptrS) (_ SwigcptrHidden) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_S_hidden_get, _swig_p) - return -} - -func (arg1 SwigcptrS) GetHidden() (_swig_ret Hidden) { - return _swig_wrap_S_hidden_get(arg1) -} - -var _wrap_S_noidea_set unsafe.Pointer - -func _swig_wrap_S_noidea_set(base SwigcptrS, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_S_noidea_set, _swig_p) - return -} - -func (arg1 SwigcptrS) SetNoidea(arg2 Ace_NoIdea_Sl_Hidden_Sg_) { - _swig_wrap_S_noidea_set(arg1, arg2.Swigcptr()) -} - -var _wrap_S_noidea_get unsafe.Pointer - -func _swig_wrap_S_noidea_get(base SwigcptrS) (_ SwigcptrAce_NoIdea_Sl_Hidden_Sg_) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_S_noidea_get, _swig_p) - return -} - -func (arg1 SwigcptrS) GetNoidea() (_swig_ret Ace_NoIdea_Sl_Hidden_Sg_) { - return _swig_wrap_S_noidea_get(arg1) -} - -var _wrap_new_S unsafe.Pointer - -func _swig_wrap_new_S() (base SwigcptrS) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_S, _swig_p) - return -} - -func NewS() (_swig_ret S) { - return _swig_wrap_new_S() -} - -var _wrap_delete_S unsafe.Pointer - -func _swig_wrap_delete_S(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_S, _swig_p) - return -} - -func DeleteS(arg1 S) { - _swig_wrap_delete_S(arg1.Swigcptr()) -} - -type S interface { - Swigcptr() uintptr - SwigIsS() - SetTe(arg2 TE) - GetTe() (_swig_ret TE) - GetConst_te() (_swig_ret TE) - GetConst_string_member() (_swig_ret string) - SetString_member(arg2 string) - GetString_member() (_swig_ret string) - SetHidden(arg2 Hidden) - GetHidden() (_swig_ret Hidden) - SetNoidea(arg2 Ace_NoIdea_Sl_Hidden_Sg_) - GetNoidea() (_swig_ret Ace_NoIdea_Sl_Hidden_Sg_) -} - - -type SwigcptrAce_NoIdea_Sl_Hidden_Sg_ uintptr -type Ace_NoIdea_Sl_Hidden_Sg_ interface { - Swigcptr() uintptr; -} -func (p SwigcptrAce_NoIdea_Sl_Hidden_Sg_) Swigcptr() uintptr { - return uintptr(p) -} - -type SwigcptrHidden uintptr -type Hidden interface { - Swigcptr() uintptr; -} -func (p SwigcptrHidden) Swigcptr() uintptr { - return uintptr(p) -} - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/naturalvar_onoff.go b/Examples/test-suite/go/naturalvar_onoff.go deleted file mode 100644 index 9d5490344..000000000 --- a/Examples/test-suite/go/naturalvar_onoff.go +++ /dev/null @@ -1,383 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../naturalvar_onoff.i - -package naturalvar_onoff - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrMember1 uintptr - -func (p SwigcptrMember1) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrMember1) SwigIsMember1() { -} - -var _wrap_new_Member1 unsafe.Pointer - -func _swig_wrap_new_Member1() (base SwigcptrMember1) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Member1, _swig_p) - return -} - -func NewMember1() (_swig_ret Member1) { - return _swig_wrap_new_Member1() -} - -var _wrap_delete_Member1 unsafe.Pointer - -func _swig_wrap_delete_Member1(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Member1, _swig_p) - return -} - -func DeleteMember1(arg1 Member1) { - _swig_wrap_delete_Member1(arg1.Swigcptr()) -} - -type Member1 interface { - Swigcptr() uintptr - SwigIsMember1() -} - -type SwigcptrMember2 uintptr - -func (p SwigcptrMember2) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrMember2) SwigIsMember2() { -} - -var _wrap_new_Member2 unsafe.Pointer - -func _swig_wrap_new_Member2() (base SwigcptrMember2) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Member2, _swig_p) - return -} - -func NewMember2() (_swig_ret Member2) { - return _swig_wrap_new_Member2() -} - -var _wrap_delete_Member2 unsafe.Pointer - -func _swig_wrap_delete_Member2(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Member2, _swig_p) - return -} - -func DeleteMember2(arg1 Member2) { - _swig_wrap_delete_Member2(arg1.Swigcptr()) -} - -type Member2 interface { - Swigcptr() uintptr - SwigIsMember2() -} - -type SwigcptrMember3 uintptr - -func (p SwigcptrMember3) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrMember3) SwigIsMember3() { -} - -var _wrap_new_Member3 unsafe.Pointer - -func _swig_wrap_new_Member3() (base SwigcptrMember3) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Member3, _swig_p) - return -} - -func NewMember3() (_swig_ret Member3) { - return _swig_wrap_new_Member3() -} - -var _wrap_delete_Member3 unsafe.Pointer - -func _swig_wrap_delete_Member3(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Member3, _swig_p) - return -} - -func DeleteMember3(arg1 Member3) { - _swig_wrap_delete_Member3(arg1.Swigcptr()) -} - -type Member3 interface { - Swigcptr() uintptr - SwigIsMember3() -} - -type SwigcptrMember4 uintptr - -func (p SwigcptrMember4) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrMember4) SwigIsMember4() { -} - -var _wrap_new_Member4 unsafe.Pointer - -func _swig_wrap_new_Member4() (base SwigcptrMember4) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Member4, _swig_p) - return -} - -func NewMember4() (_swig_ret Member4) { - return _swig_wrap_new_Member4() -} - -var _wrap_delete_Member4 unsafe.Pointer - -func _swig_wrap_delete_Member4(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Member4, _swig_p) - return -} - -func DeleteMember4(arg1 Member4) { - _swig_wrap_delete_Member4(arg1.Swigcptr()) -} - -type Member4 interface { - Swigcptr() uintptr - SwigIsMember4() -} - -type SwigcptrVars uintptr - -func (p SwigcptrVars) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrVars) SwigIsVars() { -} - -var _wrap_Vars_member1On_set unsafe.Pointer - -func _swig_wrap_Vars_member1On_set(base SwigcptrVars, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Vars_member1On_set, _swig_p) - return -} - -func (arg1 SwigcptrVars) SetMember1On(arg2 Member1) { - _swig_wrap_Vars_member1On_set(arg1, arg2.Swigcptr()) -} - -var _wrap_Vars_member1On_get unsafe.Pointer - -func _swig_wrap_Vars_member1On_get(base SwigcptrVars) (_ SwigcptrMember1) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Vars_member1On_get, _swig_p) - return -} - -func (arg1 SwigcptrVars) GetMember1On() (_swig_ret Member1) { - return _swig_wrap_Vars_member1On_get(arg1) -} - -var _wrap_Vars_member2Off_set unsafe.Pointer - -func _swig_wrap_Vars_member2Off_set(base SwigcptrVars, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Vars_member2Off_set, _swig_p) - return -} - -func (arg1 SwigcptrVars) SetMember2Off(arg2 Member2) { - _swig_wrap_Vars_member2Off_set(arg1, arg2.Swigcptr()) -} - -var _wrap_Vars_member2Off_get unsafe.Pointer - -func _swig_wrap_Vars_member2Off_get(base SwigcptrVars) (_ SwigcptrMember2) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Vars_member2Off_get, _swig_p) - return -} - -func (arg1 SwigcptrVars) GetMember2Off() (_swig_ret Member2) { - return _swig_wrap_Vars_member2Off_get(arg1) -} - -var _wrap_Vars_member3Off_set unsafe.Pointer - -func _swig_wrap_Vars_member3Off_set(base SwigcptrVars, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Vars_member3Off_set, _swig_p) - return -} - -func (arg1 SwigcptrVars) SetMember3Off(arg2 Member3) { - _swig_wrap_Vars_member3Off_set(arg1, arg2.Swigcptr()) -} - -var _wrap_Vars_member3Off_get unsafe.Pointer - -func _swig_wrap_Vars_member3Off_get(base SwigcptrVars) (_ SwigcptrMember3) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Vars_member3Off_get, _swig_p) - return -} - -func (arg1 SwigcptrVars) GetMember3Off() (_swig_ret Member3) { - return _swig_wrap_Vars_member3Off_get(arg1) -} - -var _wrap_Vars_member3On_set unsafe.Pointer - -func _swig_wrap_Vars_member3On_set(base SwigcptrVars, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Vars_member3On_set, _swig_p) - return -} - -func (arg1 SwigcptrVars) SetMember3On(arg2 Member3) { - _swig_wrap_Vars_member3On_set(arg1, arg2.Swigcptr()) -} - -var _wrap_Vars_member3On_get unsafe.Pointer - -func _swig_wrap_Vars_member3On_get(base SwigcptrVars) (_ SwigcptrMember3) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Vars_member3On_get, _swig_p) - return -} - -func (arg1 SwigcptrVars) GetMember3On() (_swig_ret Member3) { - return _swig_wrap_Vars_member3On_get(arg1) -} - -var _wrap_Vars_member4Off_set unsafe.Pointer - -func _swig_wrap_Vars_member4Off_set(base SwigcptrVars, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Vars_member4Off_set, _swig_p) - return -} - -func (arg1 SwigcptrVars) SetMember4Off(arg2 Member4) { - _swig_wrap_Vars_member4Off_set(arg1, arg2.Swigcptr()) -} - -var _wrap_Vars_member4Off_get unsafe.Pointer - -func _swig_wrap_Vars_member4Off_get(base SwigcptrVars) (_ SwigcptrMember4) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Vars_member4Off_get, _swig_p) - return -} - -func (arg1 SwigcptrVars) GetMember4Off() (_swig_ret Member4) { - return _swig_wrap_Vars_member4Off_get(arg1) -} - -var _wrap_Vars_member4On_set unsafe.Pointer - -func _swig_wrap_Vars_member4On_set(base SwigcptrVars, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Vars_member4On_set, _swig_p) - return -} - -func (arg1 SwigcptrVars) SetMember4On(arg2 Member4) { - _swig_wrap_Vars_member4On_set(arg1, arg2.Swigcptr()) -} - -var _wrap_Vars_member4On_get unsafe.Pointer - -func _swig_wrap_Vars_member4On_get(base SwigcptrVars) (_ SwigcptrMember4) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Vars_member4On_get, _swig_p) - return -} - -func (arg1 SwigcptrVars) GetMember4On() (_swig_ret Member4) { - return _swig_wrap_Vars_member4On_get(arg1) -} - -var _wrap_new_Vars unsafe.Pointer - -func _swig_wrap_new_Vars() (base SwigcptrVars) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Vars, _swig_p) - return -} - -func NewVars() (_swig_ret Vars) { - return _swig_wrap_new_Vars() -} - -var _wrap_delete_Vars unsafe.Pointer - -func _swig_wrap_delete_Vars(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Vars, _swig_p) - return -} - -func DeleteVars(arg1 Vars) { - _swig_wrap_delete_Vars(arg1.Swigcptr()) -} - -type Vars interface { - Swigcptr() uintptr - SwigIsVars() - SetMember1On(arg2 Member1) - GetMember1On() (_swig_ret Member1) - SetMember2Off(arg2 Member2) - GetMember2Off() (_swig_ret Member2) - SetMember3Off(arg2 Member3) - GetMember3Off() (_swig_ret Member3) - SetMember3On(arg2 Member3) - GetMember3On() (_swig_ret Member3) - SetMember4Off(arg2 Member4) - GetMember4Off() (_swig_ret Member4) - SetMember4On(arg2 Member4) - GetMember4On() (_swig_ret Member4) -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/naturalvar_runme b/Examples/test-suite/go/naturalvar_runme deleted file mode 100755 index 799b5ff44..000000000 Binary files a/Examples/test-suite/go/naturalvar_runme and /dev/null differ diff --git a/Examples/test-suite/go/nested.go b/Examples/test-suite/go/nested.go deleted file mode 100644 index 4ec3692d1..000000000 --- a/Examples/test-suite/go/nested.go +++ /dev/null @@ -1,910 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../nested.i - -package nested - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrTestStruct uintptr - -func (p SwigcptrTestStruct) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrTestStruct) SwigIsTestStruct() { -} - -var _wrap_TestStruct_a_set unsafe.Pointer - -func _swig_wrap_TestStruct_a_set(base SwigcptrTestStruct, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_TestStruct_a_set, _swig_p) - return -} - -func (arg1 SwigcptrTestStruct) SetA(arg2 int) { - _swig_wrap_TestStruct_a_set(arg1, arg2) -} - -var _wrap_TestStruct_a_get unsafe.Pointer - -func _swig_wrap_TestStruct_a_get(base SwigcptrTestStruct) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_TestStruct_a_get, _swig_p) - return -} - -func (arg1 SwigcptrTestStruct) GetA() (_swig_ret int) { - return _swig_wrap_TestStruct_a_get(arg1) -} - -var _wrap_new_TestStruct unsafe.Pointer - -func _swig_wrap_new_TestStruct() (base SwigcptrTestStruct) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_TestStruct, _swig_p) - return -} - -func NewTestStruct() (_swig_ret TestStruct) { - return _swig_wrap_new_TestStruct() -} - -var _wrap_delete_TestStruct unsafe.Pointer - -func _swig_wrap_delete_TestStruct(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_TestStruct, _swig_p) - return -} - -func DeleteTestStruct(arg1 TestStruct) { - _swig_wrap_delete_TestStruct(arg1.Swigcptr()) -} - -type TestStruct interface { - Swigcptr() uintptr - SwigIsTestStruct() - SetA(arg2 int) - GetA() (_swig_ret int) -} - -type SwigcptrOuterStructNamed uintptr - -func (p SwigcptrOuterStructNamed) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrOuterStructNamed) SwigIsOuterStructNamed() { -} - -var _wrap_OuterStructNamed_inner_struct_named_set unsafe.Pointer - -func _swig_wrap_OuterStructNamed_inner_struct_named_set(base SwigcptrOuterStructNamed, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_OuterStructNamed_inner_struct_named_set, _swig_p) - return -} - -func (arg1 SwigcptrOuterStructNamed) SetInner_struct_named(arg2 InnerStructNamed) { - _swig_wrap_OuterStructNamed_inner_struct_named_set(arg1, arg2.Swigcptr()) -} - -var _wrap_OuterStructNamed_inner_struct_named_get unsafe.Pointer - -func _swig_wrap_OuterStructNamed_inner_struct_named_get(base SwigcptrOuterStructNamed) (_ SwigcptrInnerStructNamed) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_OuterStructNamed_inner_struct_named_get, _swig_p) - return -} - -func (arg1 SwigcptrOuterStructNamed) GetInner_struct_named() (_swig_ret InnerStructNamed) { - return _swig_wrap_OuterStructNamed_inner_struct_named_get(arg1) -} - -var _wrap_OuterStructNamed_inner_union_named_set unsafe.Pointer - -func _swig_wrap_OuterStructNamed_inner_union_named_set(base SwigcptrOuterStructNamed, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_OuterStructNamed_inner_union_named_set, _swig_p) - return -} - -func (arg1 SwigcptrOuterStructNamed) SetInner_union_named(arg2 InnerUnionNamed) { - _swig_wrap_OuterStructNamed_inner_union_named_set(arg1, arg2.Swigcptr()) -} - -var _wrap_OuterStructNamed_inner_union_named_get unsafe.Pointer - -func _swig_wrap_OuterStructNamed_inner_union_named_get(base SwigcptrOuterStructNamed) (_ SwigcptrInnerUnionNamed) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_OuterStructNamed_inner_union_named_get, _swig_p) - return -} - -func (arg1 SwigcptrOuterStructNamed) GetInner_union_named() (_swig_ret InnerUnionNamed) { - return _swig_wrap_OuterStructNamed_inner_union_named_get(arg1) -} - -var _wrap_new_OuterStructNamed unsafe.Pointer - -func _swig_wrap_new_OuterStructNamed() (base SwigcptrOuterStructNamed) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_OuterStructNamed, _swig_p) - return -} - -func NewOuterStructNamed() (_swig_ret OuterStructNamed) { - return _swig_wrap_new_OuterStructNamed() -} - -var _wrap_delete_OuterStructNamed unsafe.Pointer - -func _swig_wrap_delete_OuterStructNamed(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_OuterStructNamed, _swig_p) - return -} - -func DeleteOuterStructNamed(arg1 OuterStructNamed) { - _swig_wrap_delete_OuterStructNamed(arg1.Swigcptr()) -} - -type OuterStructNamed interface { - Swigcptr() uintptr - SwigIsOuterStructNamed() - SetInner_struct_named(arg2 InnerStructNamed) - GetInner_struct_named() (_swig_ret InnerStructNamed) - SetInner_union_named(arg2 InnerUnionNamed) - GetInner_union_named() (_swig_ret InnerUnionNamed) -} - -type SwigcptrInnerStructNamed uintptr - -func (p SwigcptrInnerStructNamed) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrInnerStructNamed) SwigIsInnerStructNamed() { -} - -var _wrap_InnerStructNamed_dd_set unsafe.Pointer - -func _swig_wrap_InnerStructNamed_dd_set(base SwigcptrInnerStructNamed, _ float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_InnerStructNamed_dd_set, _swig_p) - return -} - -func (arg1 SwigcptrInnerStructNamed) SetDd(arg2 float64) { - _swig_wrap_InnerStructNamed_dd_set(arg1, arg2) -} - -var _wrap_InnerStructNamed_dd_get unsafe.Pointer - -func _swig_wrap_InnerStructNamed_dd_get(base SwigcptrInnerStructNamed) (_ float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_InnerStructNamed_dd_get, _swig_p) - return -} - -func (arg1 SwigcptrInnerStructNamed) GetDd() (_swig_ret float64) { - return _swig_wrap_InnerStructNamed_dd_get(arg1) -} - -var _wrap_new_InnerStructNamed unsafe.Pointer - -func _swig_wrap_new_InnerStructNamed() (base SwigcptrInnerStructNamed) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_InnerStructNamed, _swig_p) - return -} - -func NewInnerStructNamed() (_swig_ret InnerStructNamed) { - return _swig_wrap_new_InnerStructNamed() -} - -var _wrap_delete_InnerStructNamed unsafe.Pointer - -func _swig_wrap_delete_InnerStructNamed(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_InnerStructNamed, _swig_p) - return -} - -func DeleteInnerStructNamed(arg1 InnerStructNamed) { - _swig_wrap_delete_InnerStructNamed(arg1.Swigcptr()) -} - -type InnerStructNamed interface { - Swigcptr() uintptr - SwigIsInnerStructNamed() - SetDd(arg2 float64) - GetDd() (_swig_ret float64) -} - -type SwigcptrInnerUnionNamed uintptr - -func (p SwigcptrInnerUnionNamed) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrInnerUnionNamed) SwigIsInnerUnionNamed() { -} - -var _wrap_InnerUnionNamed_ee_set unsafe.Pointer - -func _swig_wrap_InnerUnionNamed_ee_set(base SwigcptrInnerUnionNamed, _ float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_InnerUnionNamed_ee_set, _swig_p) - return -} - -func (arg1 SwigcptrInnerUnionNamed) SetEe(arg2 float64) { - _swig_wrap_InnerUnionNamed_ee_set(arg1, arg2) -} - -var _wrap_InnerUnionNamed_ee_get unsafe.Pointer - -func _swig_wrap_InnerUnionNamed_ee_get(base SwigcptrInnerUnionNamed) (_ float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_InnerUnionNamed_ee_get, _swig_p) - return -} - -func (arg1 SwigcptrInnerUnionNamed) GetEe() (_swig_ret float64) { - return _swig_wrap_InnerUnionNamed_ee_get(arg1) -} - -var _wrap_InnerUnionNamed_ff_set unsafe.Pointer - -func _swig_wrap_InnerUnionNamed_ff_set(base SwigcptrInnerUnionNamed, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_InnerUnionNamed_ff_set, _swig_p) - return -} - -func (arg1 SwigcptrInnerUnionNamed) SetFf(arg2 int) { - _swig_wrap_InnerUnionNamed_ff_set(arg1, arg2) -} - -var _wrap_InnerUnionNamed_ff_get unsafe.Pointer - -func _swig_wrap_InnerUnionNamed_ff_get(base SwigcptrInnerUnionNamed) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_InnerUnionNamed_ff_get, _swig_p) - return -} - -func (arg1 SwigcptrInnerUnionNamed) GetFf() (_swig_ret int) { - return _swig_wrap_InnerUnionNamed_ff_get(arg1) -} - -var _wrap_new_InnerUnionNamed unsafe.Pointer - -func _swig_wrap_new_InnerUnionNamed() (base SwigcptrInnerUnionNamed) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_InnerUnionNamed, _swig_p) - return -} - -func NewInnerUnionNamed() (_swig_ret InnerUnionNamed) { - return _swig_wrap_new_InnerUnionNamed() -} - -var _wrap_delete_InnerUnionNamed unsafe.Pointer - -func _swig_wrap_delete_InnerUnionNamed(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_InnerUnionNamed, _swig_p) - return -} - -func DeleteInnerUnionNamed(arg1 InnerUnionNamed) { - _swig_wrap_delete_InnerUnionNamed(arg1.Swigcptr()) -} - -type InnerUnionNamed interface { - Swigcptr() uintptr - SwigIsInnerUnionNamed() - SetEe(arg2 float64) - GetEe() (_swig_ret float64) - SetFf(arg2 int) - GetFf() (_swig_ret int) -} - -type SwigcptrOuterStructUnnamed uintptr - -func (p SwigcptrOuterStructUnnamed) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrOuterStructUnnamed) SwigIsOuterStructUnnamed() { -} - -var _wrap_OuterStructUnnamed_inner_struct_unnamed_get unsafe.Pointer - -func _swig_wrap_OuterStructUnnamed_inner_struct_unnamed_get(base SwigcptrOuterStructUnnamed) (_ SwigcptrOuterStructUnnamed_inner_struct_unnamed) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_OuterStructUnnamed_inner_struct_unnamed_get, _swig_p) - return -} - -func (arg1 SwigcptrOuterStructUnnamed) GetInner_struct_unnamed() (_swig_ret OuterStructUnnamed_inner_struct_unnamed) { - return _swig_wrap_OuterStructUnnamed_inner_struct_unnamed_get(arg1) -} - -var _wrap_OuterStructUnnamed_inner_union_unnamed_get unsafe.Pointer - -func _swig_wrap_OuterStructUnnamed_inner_union_unnamed_get(base SwigcptrOuterStructUnnamed) (_ SwigcptrOuterStructUnnamed_inner_union_unnamed) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_OuterStructUnnamed_inner_union_unnamed_get, _swig_p) - return -} - -func (arg1 SwigcptrOuterStructUnnamed) GetInner_union_unnamed() (_swig_ret OuterStructUnnamed_inner_union_unnamed) { - return _swig_wrap_OuterStructUnnamed_inner_union_unnamed_get(arg1) -} - -var _wrap_new_OuterStructUnnamed unsafe.Pointer - -func _swig_wrap_new_OuterStructUnnamed() (base SwigcptrOuterStructUnnamed) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_OuterStructUnnamed, _swig_p) - return -} - -func NewOuterStructUnnamed() (_swig_ret OuterStructUnnamed) { - return _swig_wrap_new_OuterStructUnnamed() -} - -var _wrap_delete_OuterStructUnnamed unsafe.Pointer - -func _swig_wrap_delete_OuterStructUnnamed(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_OuterStructUnnamed, _swig_p) - return -} - -func DeleteOuterStructUnnamed(arg1 OuterStructUnnamed) { - _swig_wrap_delete_OuterStructUnnamed(arg1.Swigcptr()) -} - -type OuterStructUnnamed interface { - Swigcptr() uintptr - SwigIsOuterStructUnnamed() - GetInner_struct_unnamed() (_swig_ret OuterStructUnnamed_inner_struct_unnamed) - GetInner_union_unnamed() (_swig_ret OuterStructUnnamed_inner_union_unnamed) -} - -type SwigcptrOuterStructUnnamed_inner_union_unnamed uintptr - -func (p SwigcptrOuterStructUnnamed_inner_union_unnamed) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrOuterStructUnnamed_inner_union_unnamed) SwigIsOuterStructUnnamed_inner_union_unnamed() { -} - -var _wrap_OuterStructUnnamed_inner_union_unnamed_yy_set unsafe.Pointer - -func _swig_wrap_OuterStructUnnamed_inner_union_unnamed_yy_set(base SwigcptrOuterStructUnnamed_inner_union_unnamed, _ float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_OuterStructUnnamed_inner_union_unnamed_yy_set, _swig_p) - return -} - -func (arg1 SwigcptrOuterStructUnnamed_inner_union_unnamed) SetYy(arg2 float64) { - _swig_wrap_OuterStructUnnamed_inner_union_unnamed_yy_set(arg1, arg2) -} - -var _wrap_OuterStructUnnamed_inner_union_unnamed_yy_get unsafe.Pointer - -func _swig_wrap_OuterStructUnnamed_inner_union_unnamed_yy_get(base SwigcptrOuterStructUnnamed_inner_union_unnamed) (_ float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_OuterStructUnnamed_inner_union_unnamed_yy_get, _swig_p) - return -} - -func (arg1 SwigcptrOuterStructUnnamed_inner_union_unnamed) GetYy() (_swig_ret float64) { - return _swig_wrap_OuterStructUnnamed_inner_union_unnamed_yy_get(arg1) -} - -var _wrap_OuterStructUnnamed_inner_union_unnamed_zz_set unsafe.Pointer - -func _swig_wrap_OuterStructUnnamed_inner_union_unnamed_zz_set(base SwigcptrOuterStructUnnamed_inner_union_unnamed, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_OuterStructUnnamed_inner_union_unnamed_zz_set, _swig_p) - return -} - -func (arg1 SwigcptrOuterStructUnnamed_inner_union_unnamed) SetZz(arg2 int) { - _swig_wrap_OuterStructUnnamed_inner_union_unnamed_zz_set(arg1, arg2) -} - -var _wrap_OuterStructUnnamed_inner_union_unnamed_zz_get unsafe.Pointer - -func _swig_wrap_OuterStructUnnamed_inner_union_unnamed_zz_get(base SwigcptrOuterStructUnnamed_inner_union_unnamed) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_OuterStructUnnamed_inner_union_unnamed_zz_get, _swig_p) - return -} - -func (arg1 SwigcptrOuterStructUnnamed_inner_union_unnamed) GetZz() (_swig_ret int) { - return _swig_wrap_OuterStructUnnamed_inner_union_unnamed_zz_get(arg1) -} - -var _wrap_new_OuterStructUnnamed_inner_union_unnamed unsafe.Pointer - -func _swig_wrap_new_OuterStructUnnamed_inner_union_unnamed() (base SwigcptrOuterStructUnnamed_inner_union_unnamed) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_OuterStructUnnamed_inner_union_unnamed, _swig_p) - return -} - -func NewOuterStructUnnamed_inner_union_unnamed() (_swig_ret OuterStructUnnamed_inner_union_unnamed) { - return _swig_wrap_new_OuterStructUnnamed_inner_union_unnamed() -} - -var _wrap_delete_OuterStructUnnamed_inner_union_unnamed unsafe.Pointer - -func _swig_wrap_delete_OuterStructUnnamed_inner_union_unnamed(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_OuterStructUnnamed_inner_union_unnamed, _swig_p) - return -} - -func DeleteOuterStructUnnamed_inner_union_unnamed(arg1 OuterStructUnnamed_inner_union_unnamed) { - _swig_wrap_delete_OuterStructUnnamed_inner_union_unnamed(arg1.Swigcptr()) -} - -type OuterStructUnnamed_inner_union_unnamed interface { - Swigcptr() uintptr - SwigIsOuterStructUnnamed_inner_union_unnamed() - SetYy(arg2 float64) - GetYy() (_swig_ret float64) - SetZz(arg2 int) - GetZz() (_swig_ret int) -} - -type SwigcptrOuterStructUnnamed_inner_struct_unnamed uintptr - -func (p SwigcptrOuterStructUnnamed_inner_struct_unnamed) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrOuterStructUnnamed_inner_struct_unnamed) SwigIsOuterStructUnnamed_inner_struct_unnamed() { -} - -var _wrap_OuterStructUnnamed_inner_struct_unnamed_xx_set unsafe.Pointer - -func _swig_wrap_OuterStructUnnamed_inner_struct_unnamed_xx_set(base SwigcptrOuterStructUnnamed_inner_struct_unnamed, _ float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_OuterStructUnnamed_inner_struct_unnamed_xx_set, _swig_p) - return -} - -func (arg1 SwigcptrOuterStructUnnamed_inner_struct_unnamed) SetXx(arg2 float64) { - _swig_wrap_OuterStructUnnamed_inner_struct_unnamed_xx_set(arg1, arg2) -} - -var _wrap_OuterStructUnnamed_inner_struct_unnamed_xx_get unsafe.Pointer - -func _swig_wrap_OuterStructUnnamed_inner_struct_unnamed_xx_get(base SwigcptrOuterStructUnnamed_inner_struct_unnamed) (_ float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_OuterStructUnnamed_inner_struct_unnamed_xx_get, _swig_p) - return -} - -func (arg1 SwigcptrOuterStructUnnamed_inner_struct_unnamed) GetXx() (_swig_ret float64) { - return _swig_wrap_OuterStructUnnamed_inner_struct_unnamed_xx_get(arg1) -} - -var _wrap_new_OuterStructUnnamed_inner_struct_unnamed unsafe.Pointer - -func _swig_wrap_new_OuterStructUnnamed_inner_struct_unnamed() (base SwigcptrOuterStructUnnamed_inner_struct_unnamed) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_OuterStructUnnamed_inner_struct_unnamed, _swig_p) - return -} - -func NewOuterStructUnnamed_inner_struct_unnamed() (_swig_ret OuterStructUnnamed_inner_struct_unnamed) { - return _swig_wrap_new_OuterStructUnnamed_inner_struct_unnamed() -} - -var _wrap_delete_OuterStructUnnamed_inner_struct_unnamed unsafe.Pointer - -func _swig_wrap_delete_OuterStructUnnamed_inner_struct_unnamed(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_OuterStructUnnamed_inner_struct_unnamed, _swig_p) - return -} - -func DeleteOuterStructUnnamed_inner_struct_unnamed(arg1 OuterStructUnnamed_inner_struct_unnamed) { - _swig_wrap_delete_OuterStructUnnamed_inner_struct_unnamed(arg1.Swigcptr()) -} - -type OuterStructUnnamed_inner_struct_unnamed interface { - Swigcptr() uintptr - SwigIsOuterStructUnnamed_inner_struct_unnamed() - SetXx(arg2 float64) - GetXx() (_swig_ret float64) -} - -type SwigcptrOuterStruct uintptr - -func (p SwigcptrOuterStruct) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrOuterStruct) SwigIsOuterStruct() { -} - -var _wrap_OuterStruct_EmbeddedUnion_get unsafe.Pointer - -func _swig_wrap_OuterStruct_EmbeddedUnion_get(base SwigcptrOuterStruct) (_ SwigcptrOuterStruct_EmbeddedUnion) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_OuterStruct_EmbeddedUnion_get, _swig_p) - return -} - -func (arg1 SwigcptrOuterStruct) GetEmbeddedUnion() (_swig_ret OuterStruct_EmbeddedUnion) { - return _swig_wrap_OuterStruct_EmbeddedUnion_get(arg1) -} - -var _wrap_new_OuterStruct unsafe.Pointer - -func _swig_wrap_new_OuterStruct() (base SwigcptrOuterStruct) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_OuterStruct, _swig_p) - return -} - -func NewOuterStruct() (_swig_ret OuterStruct) { - return _swig_wrap_new_OuterStruct() -} - -var _wrap_delete_OuterStruct unsafe.Pointer - -func _swig_wrap_delete_OuterStruct(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_OuterStruct, _swig_p) - return -} - -func DeleteOuterStruct(arg1 OuterStruct) { - _swig_wrap_delete_OuterStruct(arg1.Swigcptr()) -} - -type OuterStruct interface { - Swigcptr() uintptr - SwigIsOuterStruct() - GetEmbeddedUnion() (_swig_ret OuterStruct_EmbeddedUnion) -} - -type SwigcptrOuterStruct_EmbeddedUnion uintptr - -func (p SwigcptrOuterStruct_EmbeddedUnion) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrOuterStruct_EmbeddedUnion) SwigIsOuterStruct_EmbeddedUnion() { -} - -var _wrap_OuterStruct_EmbeddedUnion_OuterNestedStruct_get unsafe.Pointer - -func _swig_wrap_OuterStruct_EmbeddedUnion_OuterNestedStruct_get(base SwigcptrOuterStruct_EmbeddedUnion) (_ SwigcptrOuter_nested_struct) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_OuterStruct_EmbeddedUnion_OuterNestedStruct_get, _swig_p) - return -} - -func (arg1 SwigcptrOuterStruct_EmbeddedUnion) GetOuterNestedStruct() (_swig_ret Outer_nested_struct) { - return _swig_wrap_OuterStruct_EmbeddedUnion_OuterNestedStruct_get(arg1) -} - -var _wrap_new_OuterStruct_EmbeddedUnion unsafe.Pointer - -func _swig_wrap_new_OuterStruct_EmbeddedUnion() (base SwigcptrOuterStruct_EmbeddedUnion) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_OuterStruct_EmbeddedUnion, _swig_p) - return -} - -func NewOuterStruct_EmbeddedUnion() (_swig_ret OuterStruct_EmbeddedUnion) { - return _swig_wrap_new_OuterStruct_EmbeddedUnion() -} - -var _wrap_delete_OuterStruct_EmbeddedUnion unsafe.Pointer - -func _swig_wrap_delete_OuterStruct_EmbeddedUnion(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_OuterStruct_EmbeddedUnion, _swig_p) - return -} - -func DeleteOuterStruct_EmbeddedUnion(arg1 OuterStruct_EmbeddedUnion) { - _swig_wrap_delete_OuterStruct_EmbeddedUnion(arg1.Swigcptr()) -} - -type OuterStruct_EmbeddedUnion interface { - Swigcptr() uintptr - SwigIsOuterStruct_EmbeddedUnion() - GetOuterNestedStruct() (_swig_ret Outer_nested_struct) -} - -type SwigcptrInner_nested_union uintptr - -func (p SwigcptrInner_nested_union) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrInner_nested_union) SwigIsInner_nested_union() { -} - -const BAD_STYLE int = 1 -var _wrap_inner_nested_union_red_set unsafe.Pointer - -func _swig_wrap_inner_nested_union_red_set(base SwigcptrInner_nested_union, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_inner_nested_union_red_set, _swig_p) - return -} - -func (arg1 SwigcptrInner_nested_union) SetRed(arg2 int) { - _swig_wrap_inner_nested_union_red_set(arg1, arg2) -} - -var _wrap_inner_nested_union_red_get unsafe.Pointer - -func _swig_wrap_inner_nested_union_red_get(base SwigcptrInner_nested_union) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_inner_nested_union_red_get, _swig_p) - return -} - -func (arg1 SwigcptrInner_nested_union) GetRed() (_swig_ret int) { - return _swig_wrap_inner_nested_union_red_get(arg1) -} - -var _wrap_inner_nested_union_green_set unsafe.Pointer - -func _swig_wrap_inner_nested_union_green_set(base SwigcptrInner_nested_union, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_inner_nested_union_green_set, _swig_p) - return -} - -func (arg1 SwigcptrInner_nested_union) SetGreen(arg2 TestStruct) { - _swig_wrap_inner_nested_union_green_set(arg1, arg2.Swigcptr()) -} - -var _wrap_inner_nested_union_green_get unsafe.Pointer - -func _swig_wrap_inner_nested_union_green_get(base SwigcptrInner_nested_union) (_ SwigcptrTestStruct) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_inner_nested_union_green_get, _swig_p) - return -} - -func (arg1 SwigcptrInner_nested_union) GetGreen() (_swig_ret TestStruct) { - return _swig_wrap_inner_nested_union_green_get(arg1) -} - -var _wrap_new_inner_nested_union unsafe.Pointer - -func _swig_wrap_new_inner_nested_union() (base SwigcptrInner_nested_union) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_inner_nested_union, _swig_p) - return -} - -func NewInner_nested_union() (_swig_ret Inner_nested_union) { - return _swig_wrap_new_inner_nested_union() -} - -var _wrap_delete_inner_nested_union unsafe.Pointer - -func _swig_wrap_delete_inner_nested_union(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_inner_nested_union, _swig_p) - return -} - -func DeleteInner_nested_union(arg1 Inner_nested_union) { - _swig_wrap_delete_inner_nested_union(arg1.Swigcptr()) -} - -type Inner_nested_union interface { - Swigcptr() uintptr - SwigIsInner_nested_union() - SetRed(arg2 int) - GetRed() (_swig_ret int) - SetGreen(arg2 TestStruct) - GetGreen() (_swig_ret TestStruct) -} - -type SwigcptrInner_nested_struct uintptr - -func (p SwigcptrInner_nested_struct) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrInner_nested_struct) SwigIsInner_nested_struct() { -} - -var _wrap_inner_nested_struct_blue_set unsafe.Pointer - -func _swig_wrap_inner_nested_struct_blue_set(base SwigcptrInner_nested_struct, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_inner_nested_struct_blue_set, _swig_p) - return -} - -func (arg1 SwigcptrInner_nested_struct) SetBlue(arg2 int) { - _swig_wrap_inner_nested_struct_blue_set(arg1, arg2) -} - -var _wrap_inner_nested_struct_blue_get unsafe.Pointer - -func _swig_wrap_inner_nested_struct_blue_get(base SwigcptrInner_nested_struct) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_inner_nested_struct_blue_get, _swig_p) - return -} - -func (arg1 SwigcptrInner_nested_struct) GetBlue() (_swig_ret int) { - return _swig_wrap_inner_nested_struct_blue_get(arg1) -} - -var _wrap_new_inner_nested_struct unsafe.Pointer - -func _swig_wrap_new_inner_nested_struct() (base SwigcptrInner_nested_struct) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_inner_nested_struct, _swig_p) - return -} - -func NewInner_nested_struct() (_swig_ret Inner_nested_struct) { - return _swig_wrap_new_inner_nested_struct() -} - -var _wrap_delete_inner_nested_struct unsafe.Pointer - -func _swig_wrap_delete_inner_nested_struct(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_inner_nested_struct, _swig_p) - return -} - -func DeleteInner_nested_struct(arg1 Inner_nested_struct) { - _swig_wrap_delete_inner_nested_struct(arg1.Swigcptr()) -} - -type Inner_nested_struct interface { - Swigcptr() uintptr - SwigIsInner_nested_struct() - SetBlue(arg2 int) - GetBlue() (_swig_ret int) -} - -type SwigcptrOuter_nested_struct uintptr - -func (p SwigcptrOuter_nested_struct) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrOuter_nested_struct) SwigIsOuter_nested_struct() { -} - -var _wrap_outer_nested_struct_InnerNestedUnion_set unsafe.Pointer - -func _swig_wrap_outer_nested_struct_InnerNestedUnion_set(base SwigcptrOuter_nested_struct, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_outer_nested_struct_InnerNestedUnion_set, _swig_p) - return -} - -func (arg1 SwigcptrOuter_nested_struct) SetInnerNestedUnion(arg2 Inner_nested_union) { - _swig_wrap_outer_nested_struct_InnerNestedUnion_set(arg1, arg2.Swigcptr()) -} - -var _wrap_outer_nested_struct_InnerNestedUnion_get unsafe.Pointer - -func _swig_wrap_outer_nested_struct_InnerNestedUnion_get(base SwigcptrOuter_nested_struct) (_ SwigcptrInner_nested_union) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_outer_nested_struct_InnerNestedUnion_get, _swig_p) - return -} - -func (arg1 SwigcptrOuter_nested_struct) GetInnerNestedUnion() (_swig_ret Inner_nested_union) { - return _swig_wrap_outer_nested_struct_InnerNestedUnion_get(arg1) -} - -var _wrap_outer_nested_struct_InnerNestedStruct_set unsafe.Pointer - -func _swig_wrap_outer_nested_struct_InnerNestedStruct_set(base SwigcptrOuter_nested_struct, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_outer_nested_struct_InnerNestedStruct_set, _swig_p) - return -} - -func (arg1 SwigcptrOuter_nested_struct) SetInnerNestedStruct(arg2 Inner_nested_struct) { - _swig_wrap_outer_nested_struct_InnerNestedStruct_set(arg1, arg2.Swigcptr()) -} - -var _wrap_outer_nested_struct_InnerNestedStruct_get unsafe.Pointer - -func _swig_wrap_outer_nested_struct_InnerNestedStruct_get(base SwigcptrOuter_nested_struct) (_ SwigcptrInner_nested_struct) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_outer_nested_struct_InnerNestedStruct_get, _swig_p) - return -} - -func (arg1 SwigcptrOuter_nested_struct) GetInnerNestedStruct() (_swig_ret Inner_nested_struct) { - return _swig_wrap_outer_nested_struct_InnerNestedStruct_get(arg1) -} - -var _wrap_new_outer_nested_struct unsafe.Pointer - -func _swig_wrap_new_outer_nested_struct() (base SwigcptrOuter_nested_struct) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_outer_nested_struct, _swig_p) - return -} - -func NewOuter_nested_struct() (_swig_ret Outer_nested_struct) { - return _swig_wrap_new_outer_nested_struct() -} - -var _wrap_delete_outer_nested_struct unsafe.Pointer - -func _swig_wrap_delete_outer_nested_struct(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_outer_nested_struct, _swig_p) - return -} - -func DeleteOuter_nested_struct(arg1 Outer_nested_struct) { - _swig_wrap_delete_outer_nested_struct(arg1.Swigcptr()) -} - -type Outer_nested_struct interface { - Swigcptr() uintptr - SwigIsOuter_nested_struct() - SetInnerNestedUnion(arg2 Inner_nested_union) - GetInnerNestedUnion() (_swig_ret Inner_nested_union) - SetInnerNestedStruct(arg2 Inner_nested_struct) - GetInnerNestedStruct() (_swig_ret Inner_nested_struct) -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/nested_class.go b/Examples/test-suite/go/nested_class.go deleted file mode 100644 index ac3656639..000000000 --- a/Examples/test-suite/go/nested_class.go +++ /dev/null @@ -1,850 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../nested_class.i - -package nested_class - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrOuter uintptr - -func (p SwigcptrOuter) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrOuter) SwigIsOuter() { -} - -var _wrap_Outer_InnerClass2Instance_set unsafe.Pointer - -func _swig_wrap_Outer_InnerClass2Instance_set(base SwigcptrOuter, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Outer_InnerClass2Instance_set, _swig_p) - return -} - -func (arg1 SwigcptrOuter) SetInnerClass2Instance(arg2 Outer_InnerClass2) { - _swig_wrap_Outer_InnerClass2Instance_set(arg1, arg2.Swigcptr()) -} - -var _wrap_Outer_InnerClass2Instance_get unsafe.Pointer - -func _swig_wrap_Outer_InnerClass2Instance_get(base SwigcptrOuter) (_ SwigcptrOuter_InnerClass2) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Outer_InnerClass2Instance_get, _swig_p) - return -} - -func (arg1 SwigcptrOuter) GetInnerClass2Instance() (_swig_ret Outer_InnerClass2) { - return _swig_wrap_Outer_InnerClass2Instance_get(arg1) -} - -var _wrap_Outer_InnerStruct2Instance_set unsafe.Pointer - -func _swig_wrap_Outer_InnerStruct2Instance_set(base SwigcptrOuter, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Outer_InnerStruct2Instance_set, _swig_p) - return -} - -func (arg1 SwigcptrOuter) SetInnerStruct2Instance(arg2 Outer_InnerStruct2) { - _swig_wrap_Outer_InnerStruct2Instance_set(arg1, arg2.Swigcptr()) -} - -var _wrap_Outer_InnerStruct2Instance_get unsafe.Pointer - -func _swig_wrap_Outer_InnerStruct2Instance_get(base SwigcptrOuter) (_ SwigcptrOuter_InnerStruct2) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Outer_InnerStruct2Instance_get, _swig_p) - return -} - -func (arg1 SwigcptrOuter) GetInnerStruct2Instance() (_swig_ret Outer_InnerStruct2) { - return _swig_wrap_Outer_InnerStruct2Instance_get(arg1) -} - -var _wrap_Outer_InnerUnion2Instance_set unsafe.Pointer - -func _swig_wrap_Outer_InnerUnion2Instance_set(base SwigcptrOuter, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Outer_InnerUnion2Instance_set, _swig_p) - return -} - -func (arg1 SwigcptrOuter) SetInnerUnion2Instance(arg2 Outer_InnerUnion2) { - _swig_wrap_Outer_InnerUnion2Instance_set(arg1, arg2.Swigcptr()) -} - -var _wrap_Outer_InnerUnion2Instance_get unsafe.Pointer - -func _swig_wrap_Outer_InnerUnion2Instance_get(base SwigcptrOuter) (_ SwigcptrOuter_InnerUnion2) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Outer_InnerUnion2Instance_get, _swig_p) - return -} - -func (arg1 SwigcptrOuter) GetInnerUnion2Instance() (_swig_ret Outer_InnerUnion2) { - return _swig_wrap_Outer_InnerUnion2Instance_get(arg1) -} - -var _wrap_Outer_makeInnerStruct1 unsafe.Pointer - -func _swig_wrap_Outer_makeInnerStruct1(base SwigcptrOuter) (_ SwigcptrOuter_InnerStruct1) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Outer_makeInnerStruct1, _swig_p) - return -} - -func (arg1 SwigcptrOuter) MakeInnerStruct1() (_swig_ret Outer_InnerStruct1) { - return _swig_wrap_Outer_makeInnerStruct1(arg1) -} - -var _wrap_Outer_makeInnerClass1 unsafe.Pointer - -func _swig_wrap_Outer_makeInnerClass1(base SwigcptrOuter) (_ SwigcptrOuter_InnerClass1) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Outer_makeInnerClass1, _swig_p) - return -} - -func (arg1 SwigcptrOuter) MakeInnerClass1() (_swig_ret Outer_InnerClass1) { - return _swig_wrap_Outer_makeInnerClass1(arg1) -} - -var _wrap_Outer_makeInnerUnion1 unsafe.Pointer - -func _swig_wrap_Outer_makeInnerUnion1(base SwigcptrOuter) (_ SwigcptrOuter_InnerUnion1) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Outer_makeInnerUnion1, _swig_p) - return -} - -func (arg1 SwigcptrOuter) MakeInnerUnion1() (_swig_ret Outer_InnerUnion1) { - return _swig_wrap_Outer_makeInnerUnion1(arg1) -} - -var _wrap_Outer_makeInnerStruct2 unsafe.Pointer - -func _swig_wrap_Outer_makeInnerStruct2(base SwigcptrOuter) (_ SwigcptrOuter_InnerStruct2) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Outer_makeInnerStruct2, _swig_p) - return -} - -func (arg1 SwigcptrOuter) MakeInnerStruct2() (_swig_ret Outer_InnerStruct2) { - return _swig_wrap_Outer_makeInnerStruct2(arg1) -} - -var _wrap_Outer_makeInnerClass2 unsafe.Pointer - -func _swig_wrap_Outer_makeInnerClass2(base SwigcptrOuter) (_ SwigcptrOuter_InnerClass2) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Outer_makeInnerClass2, _swig_p) - return -} - -func (arg1 SwigcptrOuter) MakeInnerClass2() (_swig_ret Outer_InnerClass2) { - return _swig_wrap_Outer_makeInnerClass2(arg1) -} - -var _wrap_Outer_makeInnerUnion2 unsafe.Pointer - -func _swig_wrap_Outer_makeInnerUnion2(base SwigcptrOuter) (_ SwigcptrOuter_InnerUnion2) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Outer_makeInnerUnion2, _swig_p) - return -} - -func (arg1 SwigcptrOuter) MakeInnerUnion2() (_swig_ret Outer_InnerUnion2) { - return _swig_wrap_Outer_makeInnerUnion2(arg1) -} - -var _wrap_Outer_makeInnerStruct4Typedef unsafe.Pointer - -func _swig_wrap_Outer_makeInnerStruct4Typedef(base SwigcptrOuter) (_ SwigcptrOuter_InnerStruct4Typedef) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Outer_makeInnerStruct4Typedef, _swig_p) - return -} - -func (arg1 SwigcptrOuter) MakeInnerStruct4Typedef() (_swig_ret Outer_InnerStruct4Typedef) { - return _swig_wrap_Outer_makeInnerStruct4Typedef(arg1) -} - -var _wrap_Outer_makeInnerClass4Typedef unsafe.Pointer - -func _swig_wrap_Outer_makeInnerClass4Typedef(base SwigcptrOuter) (_ SwigcptrOuter_InnerClass4Typedef) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Outer_makeInnerClass4Typedef, _swig_p) - return -} - -func (arg1 SwigcptrOuter) MakeInnerClass4Typedef() (_swig_ret Outer_InnerClass4Typedef) { - return _swig_wrap_Outer_makeInnerClass4Typedef(arg1) -} - -var _wrap_Outer_makeInnerUnion4Typedef unsafe.Pointer - -func _swig_wrap_Outer_makeInnerUnion4Typedef(base SwigcptrOuter) (_ SwigcptrOuter_InnerUnion4Typedef) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Outer_makeInnerUnion4Typedef, _swig_p) - return -} - -func (arg1 SwigcptrOuter) MakeInnerUnion4Typedef() (_swig_ret Outer_InnerUnion4Typedef) { - return _swig_wrap_Outer_makeInnerUnion4Typedef(arg1) -} - -var _wrap_Outer_makeInnerStruct5 unsafe.Pointer - -func _swig_wrap_Outer_makeInnerStruct5(base SwigcptrOuter) (_ SwigcptrOuter_InnerStruct5) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Outer_makeInnerStruct5, _swig_p) - return -} - -func (arg1 SwigcptrOuter) MakeInnerStruct5() (_swig_ret Outer_InnerStruct5) { - return _swig_wrap_Outer_makeInnerStruct5(arg1) -} - -var _wrap_Outer_makeInnerClass5 unsafe.Pointer - -func _swig_wrap_Outer_makeInnerClass5(base SwigcptrOuter) (_ SwigcptrOuter_InnerClass5) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Outer_makeInnerClass5, _swig_p) - return -} - -func (arg1 SwigcptrOuter) MakeInnerClass5() (_swig_ret Outer_InnerClass5) { - return _swig_wrap_Outer_makeInnerClass5(arg1) -} - -var _wrap_Outer_makeInnerUnion5 unsafe.Pointer - -func _swig_wrap_Outer_makeInnerUnion5(base SwigcptrOuter) (_ SwigcptrOuter_InnerUnion5) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Outer_makeInnerUnion5, _swig_p) - return -} - -func (arg1 SwigcptrOuter) MakeInnerUnion5() (_swig_ret Outer_InnerUnion5) { - return _swig_wrap_Outer_makeInnerUnion5(arg1) -} - -var _wrap_Outer_makeInnerStruct5Typedef unsafe.Pointer - -func _swig_wrap_Outer_makeInnerStruct5Typedef(base SwigcptrOuter) (_ SwigcptrOuter_InnerStruct5) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Outer_makeInnerStruct5Typedef, _swig_p) - return -} - -func (arg1 SwigcptrOuter) MakeInnerStruct5Typedef() (_swig_ret Outer_InnerStruct5) { - return _swig_wrap_Outer_makeInnerStruct5Typedef(arg1) -} - -var _wrap_Outer_makeInnerClass5Typedef unsafe.Pointer - -func _swig_wrap_Outer_makeInnerClass5Typedef(base SwigcptrOuter) (_ SwigcptrOuter_InnerClass5) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Outer_makeInnerClass5Typedef, _swig_p) - return -} - -func (arg1 SwigcptrOuter) MakeInnerClass5Typedef() (_swig_ret Outer_InnerClass5) { - return _swig_wrap_Outer_makeInnerClass5Typedef(arg1) -} - -var _wrap_Outer_makeInnerUnion5Typedef unsafe.Pointer - -func _swig_wrap_Outer_makeInnerUnion5Typedef(base SwigcptrOuter) (_ SwigcptrOuter_InnerUnion5) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Outer_makeInnerUnion5Typedef, _swig_p) - return -} - -func (arg1 SwigcptrOuter) MakeInnerUnion5Typedef() (_swig_ret Outer_InnerUnion5) { - return _swig_wrap_Outer_makeInnerUnion5Typedef(arg1) -} - -var _wrap_Outer_MultipleInstance1_set unsafe.Pointer - -func _swig_wrap_Outer_MultipleInstance1_set(base SwigcptrOuter, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Outer_MultipleInstance1_set, _swig_p) - return -} - -func (arg1 SwigcptrOuter) SetMultipleInstance1(arg2 Outer_InnerMultiple) { - _swig_wrap_Outer_MultipleInstance1_set(arg1, arg2.Swigcptr()) -} - -var _wrap_Outer_MultipleInstance1_get unsafe.Pointer - -func _swig_wrap_Outer_MultipleInstance1_get(base SwigcptrOuter) (_ SwigcptrOuter_InnerMultiple) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Outer_MultipleInstance1_get, _swig_p) - return -} - -func (arg1 SwigcptrOuter) GetMultipleInstance1() (_swig_ret Outer_InnerMultiple) { - return _swig_wrap_Outer_MultipleInstance1_get(arg1) -} - -var _wrap_Outer_MultipleInstance2_set unsafe.Pointer - -func _swig_wrap_Outer_MultipleInstance2_set(base SwigcptrOuter, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Outer_MultipleInstance2_set, _swig_p) - return -} - -func (arg1 SwigcptrOuter) SetMultipleInstance2(arg2 Outer_InnerMultiple) { - _swig_wrap_Outer_MultipleInstance2_set(arg1, arg2.Swigcptr()) -} - -var _wrap_Outer_MultipleInstance2_get unsafe.Pointer - -func _swig_wrap_Outer_MultipleInstance2_get(base SwigcptrOuter) (_ SwigcptrOuter_InnerMultiple) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Outer_MultipleInstance2_get, _swig_p) - return -} - -func (arg1 SwigcptrOuter) GetMultipleInstance2() (_swig_ret Outer_InnerMultiple) { - return _swig_wrap_Outer_MultipleInstance2_get(arg1) -} - -var _wrap_Outer_MultipleInstance3_set unsafe.Pointer - -func _swig_wrap_Outer_MultipleInstance3_set(base SwigcptrOuter, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Outer_MultipleInstance3_set, _swig_p) - return -} - -func (arg1 SwigcptrOuter) SetMultipleInstance3(arg2 Outer_InnerMultiple) { - _swig_wrap_Outer_MultipleInstance3_set(arg1, arg2.Swigcptr()) -} - -var _wrap_Outer_MultipleInstance3_get unsafe.Pointer - -func _swig_wrap_Outer_MultipleInstance3_get(base SwigcptrOuter) (_ SwigcptrOuter_InnerMultiple) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Outer_MultipleInstance3_get, _swig_p) - return -} - -func (arg1 SwigcptrOuter) GetMultipleInstance3() (_swig_ret Outer_InnerMultiple) { - return _swig_wrap_Outer_MultipleInstance3_get(arg1) -} - -var _wrap_Outer_MultipleInstance4_set unsafe.Pointer - -func _swig_wrap_Outer_MultipleInstance4_set(base SwigcptrOuter, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Outer_MultipleInstance4_set, _swig_p) - return -} - -func (arg1 SwigcptrOuter) SetMultipleInstance4(arg2 Outer_InnerMultiple) { - _swig_wrap_Outer_MultipleInstance4_set(arg1, arg2.Swigcptr()) -} - -var _wrap_Outer_MultipleInstance4_get unsafe.Pointer - -func _swig_wrap_Outer_MultipleInstance4_get(base SwigcptrOuter) (_ SwigcptrOuter_InnerMultiple) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Outer_MultipleInstance4_get, _swig_p) - return -} - -func (arg1 SwigcptrOuter) GetMultipleInstance4() (_swig_ret Outer_InnerMultiple) { - return _swig_wrap_Outer_MultipleInstance4_get(arg1) -} - -var _wrap_Outer_MultipleDerivedInstance1_set unsafe.Pointer - -func _swig_wrap_Outer_MultipleDerivedInstance1_set(base SwigcptrOuter, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Outer_MultipleDerivedInstance1_set, _swig_p) - return -} - -func (arg1 SwigcptrOuter) SetMultipleDerivedInstance1(arg2 Outer_InnerMultipleDerived) { - _swig_wrap_Outer_MultipleDerivedInstance1_set(arg1, arg2.Swigcptr()) -} - -var _wrap_Outer_MultipleDerivedInstance1_get unsafe.Pointer - -func _swig_wrap_Outer_MultipleDerivedInstance1_get(base SwigcptrOuter) (_ SwigcptrOuter_InnerMultipleDerived) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Outer_MultipleDerivedInstance1_get, _swig_p) - return -} - -func (arg1 SwigcptrOuter) GetMultipleDerivedInstance1() (_swig_ret Outer_InnerMultipleDerived) { - return _swig_wrap_Outer_MultipleDerivedInstance1_get(arg1) -} - -var _wrap_Outer_MultipleDerivedInstance2_set unsafe.Pointer - -func _swig_wrap_Outer_MultipleDerivedInstance2_set(base SwigcptrOuter, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Outer_MultipleDerivedInstance2_set, _swig_p) - return -} - -func (arg1 SwigcptrOuter) SetMultipleDerivedInstance2(arg2 Outer_InnerMultipleDerived) { - _swig_wrap_Outer_MultipleDerivedInstance2_set(arg1, arg2.Swigcptr()) -} - -var _wrap_Outer_MultipleDerivedInstance2_get unsafe.Pointer - -func _swig_wrap_Outer_MultipleDerivedInstance2_get(base SwigcptrOuter) (_ SwigcptrOuter_InnerMultipleDerived) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Outer_MultipleDerivedInstance2_get, _swig_p) - return -} - -func (arg1 SwigcptrOuter) GetMultipleDerivedInstance2() (_swig_ret Outer_InnerMultipleDerived) { - return _swig_wrap_Outer_MultipleDerivedInstance2_get(arg1) -} - -var _wrap_Outer_MultipleDerivedInstance3_set unsafe.Pointer - -func _swig_wrap_Outer_MultipleDerivedInstance3_set(base SwigcptrOuter, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Outer_MultipleDerivedInstance3_set, _swig_p) - return -} - -func (arg1 SwigcptrOuter) SetMultipleDerivedInstance3(arg2 Outer_InnerMultipleDerived) { - _swig_wrap_Outer_MultipleDerivedInstance3_set(arg1, arg2.Swigcptr()) -} - -var _wrap_Outer_MultipleDerivedInstance3_get unsafe.Pointer - -func _swig_wrap_Outer_MultipleDerivedInstance3_get(base SwigcptrOuter) (_ SwigcptrOuter_InnerMultipleDerived) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Outer_MultipleDerivedInstance3_get, _swig_p) - return -} - -func (arg1 SwigcptrOuter) GetMultipleDerivedInstance3() (_swig_ret Outer_InnerMultipleDerived) { - return _swig_wrap_Outer_MultipleDerivedInstance3_get(arg1) -} - -var _wrap_Outer_MultipleDerivedInstance4_set unsafe.Pointer - -func _swig_wrap_Outer_MultipleDerivedInstance4_set(base SwigcptrOuter, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Outer_MultipleDerivedInstance4_set, _swig_p) - return -} - -func (arg1 SwigcptrOuter) SetMultipleDerivedInstance4(arg2 Outer_InnerMultipleDerived) { - _swig_wrap_Outer_MultipleDerivedInstance4_set(arg1, arg2.Swigcptr()) -} - -var _wrap_Outer_MultipleDerivedInstance4_get unsafe.Pointer - -func _swig_wrap_Outer_MultipleDerivedInstance4_get(base SwigcptrOuter) (_ SwigcptrOuter_InnerMultipleDerived) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Outer_MultipleDerivedInstance4_get, _swig_p) - return -} - -func (arg1 SwigcptrOuter) GetMultipleDerivedInstance4() (_swig_ret Outer_InnerMultipleDerived) { - return _swig_wrap_Outer_MultipleDerivedInstance4_get(arg1) -} - -var _wrap_Outer_makeInnerMultipleAnonTypedef1 unsafe.Pointer - -func _swig_wrap_Outer_makeInnerMultipleAnonTypedef1(base SwigcptrOuter) (_ SwigcptrOuter_InnerMultipleAnonTypedef1) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Outer_makeInnerMultipleAnonTypedef1, _swig_p) - return -} - -func (arg1 SwigcptrOuter) MakeInnerMultipleAnonTypedef1() (_swig_ret Outer_InnerMultipleAnonTypedef1) { - return _swig_wrap_Outer_makeInnerMultipleAnonTypedef1(arg1) -} - -var _wrap_Outer_makeInnerMultipleAnonTypedef2 unsafe.Pointer - -func _swig_wrap_Outer_makeInnerMultipleAnonTypedef2(base SwigcptrOuter) (_ SwigcptrOuter_InnerMultipleAnonTypedef2) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Outer_makeInnerMultipleAnonTypedef2, _swig_p) - return -} - -func (arg1 SwigcptrOuter) MakeInnerMultipleAnonTypedef2() (_swig_ret Outer_InnerMultipleAnonTypedef2) { - return _swig_wrap_Outer_makeInnerMultipleAnonTypedef2(arg1) -} - -var _wrap_Outer_makeInnerMultipleAnonTypedef3 unsafe.Pointer - -func _swig_wrap_Outer_makeInnerMultipleAnonTypedef3(base SwigcptrOuter) (_ SwigcptrOuter_InnerMultipleAnonTypedef3) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Outer_makeInnerMultipleAnonTypedef3, _swig_p) - return -} - -func (arg1 SwigcptrOuter) MakeInnerMultipleAnonTypedef3() (_swig_ret Outer_InnerMultipleAnonTypedef3) { - return _swig_wrap_Outer_makeInnerMultipleAnonTypedef3(arg1) -} - -var _wrap_Outer_makeInnerMultipleNamedTypedef unsafe.Pointer - -func _swig_wrap_Outer_makeInnerMultipleNamedTypedef(base SwigcptrOuter) (_ SwigcptrOuter_InnerMultipleNamedTypedef) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Outer_makeInnerMultipleNamedTypedef, _swig_p) - return -} - -func (arg1 SwigcptrOuter) MakeInnerMultipleNamedTypedef() (_swig_ret Outer_InnerMultipleNamedTypedef) { - return _swig_wrap_Outer_makeInnerMultipleNamedTypedef(arg1) -} - -var _wrap_Outer_makeInnerMultipleNamedTypedef1 unsafe.Pointer - -func _swig_wrap_Outer_makeInnerMultipleNamedTypedef1(base SwigcptrOuter) (_ SwigcptrOuter_InnerMultipleNamedTypedef) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Outer_makeInnerMultipleNamedTypedef1, _swig_p) - return -} - -func (arg1 SwigcptrOuter) MakeInnerMultipleNamedTypedef1() (_swig_ret Outer_InnerMultipleNamedTypedef) { - return _swig_wrap_Outer_makeInnerMultipleNamedTypedef1(arg1) -} - -var _wrap_Outer_makeInnerMultipleNamedTypedef2 unsafe.Pointer - -func _swig_wrap_Outer_makeInnerMultipleNamedTypedef2(base SwigcptrOuter) (_ SwigcptrOuter_InnerMultipleNamedTypedef) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Outer_makeInnerMultipleNamedTypedef2, _swig_p) - return -} - -func (arg1 SwigcptrOuter) MakeInnerMultipleNamedTypedef2() (_swig_ret Outer_InnerMultipleNamedTypedef) { - return _swig_wrap_Outer_makeInnerMultipleNamedTypedef2(arg1) -} - -var _wrap_Outer_makeInnerMultipleNamedTypedef3 unsafe.Pointer - -func _swig_wrap_Outer_makeInnerMultipleNamedTypedef3(base SwigcptrOuter) (_ SwigcptrOuter_InnerMultipleNamedTypedef) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Outer_makeInnerMultipleNamedTypedef3, _swig_p) - return -} - -func (arg1 SwigcptrOuter) MakeInnerMultipleNamedTypedef3() (_swig_ret Outer_InnerMultipleNamedTypedef) { - return _swig_wrap_Outer_makeInnerMultipleNamedTypedef3(arg1) -} - -var _wrap_Outer_makeInnerSameName unsafe.Pointer - -func _swig_wrap_Outer_makeInnerSameName(base SwigcptrOuter) (_ SwigcptrOuter_InnerSameName) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Outer_makeInnerSameName, _swig_p) - return -} - -func (arg1 SwigcptrOuter) MakeInnerSameName() (_swig_ret Outer_InnerSameName) { - return _swig_wrap_Outer_makeInnerSameName(arg1) -} - -var _wrap_new_Outer unsafe.Pointer - -func _swig_wrap_new_Outer() (base SwigcptrOuter) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Outer, _swig_p) - return -} - -func NewOuter() (_swig_ret Outer) { - return _swig_wrap_new_Outer() -} - -var _wrap_delete_Outer unsafe.Pointer - -func _swig_wrap_delete_Outer(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Outer, _swig_p) - return -} - -func DeleteOuter(arg1 Outer) { - _swig_wrap_delete_Outer(arg1.Swigcptr()) -} - -type Outer interface { - Swigcptr() uintptr - SwigIsOuter() - SetInnerClass2Instance(arg2 Outer_InnerClass2) - GetInnerClass2Instance() (_swig_ret Outer_InnerClass2) - SetInnerStruct2Instance(arg2 Outer_InnerStruct2) - GetInnerStruct2Instance() (_swig_ret Outer_InnerStruct2) - SetInnerUnion2Instance(arg2 Outer_InnerUnion2) - GetInnerUnion2Instance() (_swig_ret Outer_InnerUnion2) - MakeInnerStruct1() (_swig_ret Outer_InnerStruct1) - MakeInnerClass1() (_swig_ret Outer_InnerClass1) - MakeInnerUnion1() (_swig_ret Outer_InnerUnion1) - MakeInnerStruct2() (_swig_ret Outer_InnerStruct2) - MakeInnerClass2() (_swig_ret Outer_InnerClass2) - MakeInnerUnion2() (_swig_ret Outer_InnerUnion2) - MakeInnerStruct4Typedef() (_swig_ret Outer_InnerStruct4Typedef) - MakeInnerClass4Typedef() (_swig_ret Outer_InnerClass4Typedef) - MakeInnerUnion4Typedef() (_swig_ret Outer_InnerUnion4Typedef) - MakeInnerStruct5() (_swig_ret Outer_InnerStruct5) - MakeInnerClass5() (_swig_ret Outer_InnerClass5) - MakeInnerUnion5() (_swig_ret Outer_InnerUnion5) - MakeInnerStruct5Typedef() (_swig_ret Outer_InnerStruct5) - MakeInnerClass5Typedef() (_swig_ret Outer_InnerClass5) - MakeInnerUnion5Typedef() (_swig_ret Outer_InnerUnion5) - SetMultipleInstance1(arg2 Outer_InnerMultiple) - GetMultipleInstance1() (_swig_ret Outer_InnerMultiple) - SetMultipleInstance2(arg2 Outer_InnerMultiple) - GetMultipleInstance2() (_swig_ret Outer_InnerMultiple) - SetMultipleInstance3(arg2 Outer_InnerMultiple) - GetMultipleInstance3() (_swig_ret Outer_InnerMultiple) - SetMultipleInstance4(arg2 Outer_InnerMultiple) - GetMultipleInstance4() (_swig_ret Outer_InnerMultiple) - SetMultipleDerivedInstance1(arg2 Outer_InnerMultipleDerived) - GetMultipleDerivedInstance1() (_swig_ret Outer_InnerMultipleDerived) - SetMultipleDerivedInstance2(arg2 Outer_InnerMultipleDerived) - GetMultipleDerivedInstance2() (_swig_ret Outer_InnerMultipleDerived) - SetMultipleDerivedInstance3(arg2 Outer_InnerMultipleDerived) - GetMultipleDerivedInstance3() (_swig_ret Outer_InnerMultipleDerived) - SetMultipleDerivedInstance4(arg2 Outer_InnerMultipleDerived) - GetMultipleDerivedInstance4() (_swig_ret Outer_InnerMultipleDerived) - MakeInnerMultipleAnonTypedef1() (_swig_ret Outer_InnerMultipleAnonTypedef1) - MakeInnerMultipleAnonTypedef2() (_swig_ret Outer_InnerMultipleAnonTypedef2) - MakeInnerMultipleAnonTypedef3() (_swig_ret Outer_InnerMultipleAnonTypedef3) - MakeInnerMultipleNamedTypedef() (_swig_ret Outer_InnerMultipleNamedTypedef) - MakeInnerMultipleNamedTypedef1() (_swig_ret Outer_InnerMultipleNamedTypedef) - MakeInnerMultipleNamedTypedef2() (_swig_ret Outer_InnerMultipleNamedTypedef) - MakeInnerMultipleNamedTypedef3() (_swig_ret Outer_InnerMultipleNamedTypedef) - MakeInnerSameName() (_swig_ret Outer_InnerSameName) -} - -type SwigcptrOuter2 uintptr - -func (p SwigcptrOuter2) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrOuter2) SwigIsOuter2() { -} - -var _wrap_new_Outer2 unsafe.Pointer - -func _swig_wrap_new_Outer2() (base SwigcptrOuter2) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Outer2, _swig_p) - return -} - -func NewOuter2() (_swig_ret Outer2) { - return _swig_wrap_new_Outer2() -} - -var _wrap_delete_Outer2 unsafe.Pointer - -func _swig_wrap_delete_Outer2(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Outer2, _swig_p) - return -} - -func DeleteOuter2(arg1 Outer2) { - _swig_wrap_delete_Outer2(arg1.Swigcptr()) -} - -type Outer2 interface { - Swigcptr() uintptr - SwigIsOuter2() -} - - -type SwigcptrOuter_InnerClass5 uintptr -type Outer_InnerClass5 interface { - Swigcptr() uintptr; -} -func (p SwigcptrOuter_InnerClass5) Swigcptr() uintptr { - return uintptr(p) -} - -type SwigcptrOuter_InnerMultipleDerived uintptr -type Outer_InnerMultipleDerived interface { - Swigcptr() uintptr; -} -func (p SwigcptrOuter_InnerMultipleDerived) Swigcptr() uintptr { - return uintptr(p) -} - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - -type SwigcptrOuter_InnerStruct1 uintptr -type Outer_InnerStruct1 interface { - Swigcptr() uintptr; -} -func (p SwigcptrOuter_InnerStruct1) Swigcptr() uintptr { - return uintptr(p) -} - -type SwigcptrOuter_InnerStruct2 uintptr -type Outer_InnerStruct2 interface { - Swigcptr() uintptr; -} -func (p SwigcptrOuter_InnerStruct2) Swigcptr() uintptr { - return uintptr(p) -} - -type SwigcptrOuter_InnerUnion4Typedef uintptr -type Outer_InnerUnion4Typedef interface { - Swigcptr() uintptr; -} -func (p SwigcptrOuter_InnerUnion4Typedef) Swigcptr() uintptr { - return uintptr(p) -} - -type SwigcptrOuter_InnerClass4Typedef uintptr -type Outer_InnerClass4Typedef interface { - Swigcptr() uintptr; -} -func (p SwigcptrOuter_InnerClass4Typedef) Swigcptr() uintptr { - return uintptr(p) -} - -type SwigcptrOuter_InnerStruct4Typedef uintptr -type Outer_InnerStruct4Typedef interface { - Swigcptr() uintptr; -} -func (p SwigcptrOuter_InnerStruct4Typedef) Swigcptr() uintptr { - return uintptr(p) -} - -type SwigcptrOuter_InnerMultipleNamedTypedef uintptr -type Outer_InnerMultipleNamedTypedef interface { - Swigcptr() uintptr; -} -func (p SwigcptrOuter_InnerMultipleNamedTypedef) Swigcptr() uintptr { - return uintptr(p) -} - -type SwigcptrOuter_InnerStruct5 uintptr -type Outer_InnerStruct5 interface { - Swigcptr() uintptr; -} -func (p SwigcptrOuter_InnerStruct5) Swigcptr() uintptr { - return uintptr(p) -} - -type SwigcptrOuter_InnerMultipleAnonTypedef1 uintptr -type Outer_InnerMultipleAnonTypedef1 interface { - Swigcptr() uintptr; -} -func (p SwigcptrOuter_InnerMultipleAnonTypedef1) Swigcptr() uintptr { - return uintptr(p) -} - -type SwigcptrOuter_InnerMultipleAnonTypedef2 uintptr -type Outer_InnerMultipleAnonTypedef2 interface { - Swigcptr() uintptr; -} -func (p SwigcptrOuter_InnerMultipleAnonTypedef2) Swigcptr() uintptr { - return uintptr(p) -} - -type SwigcptrOuter_InnerUnion1 uintptr -type Outer_InnerUnion1 interface { - Swigcptr() uintptr; -} -func (p SwigcptrOuter_InnerUnion1) Swigcptr() uintptr { - return uintptr(p) -} - -type SwigcptrOuter_InnerMultipleAnonTypedef3 uintptr -type Outer_InnerMultipleAnonTypedef3 interface { - Swigcptr() uintptr; -} -func (p SwigcptrOuter_InnerMultipleAnonTypedef3) Swigcptr() uintptr { - return uintptr(p) -} - -type SwigcptrOuter_InnerUnion2 uintptr -type Outer_InnerUnion2 interface { - Swigcptr() uintptr; -} -func (p SwigcptrOuter_InnerUnion2) Swigcptr() uintptr { - return uintptr(p) -} - -type SwigcptrOuter_InnerClass1 uintptr -type Outer_InnerClass1 interface { - Swigcptr() uintptr; -} -func (p SwigcptrOuter_InnerClass1) Swigcptr() uintptr { - return uintptr(p) -} - -type SwigcptrOuter_InnerMultiple uintptr -type Outer_InnerMultiple interface { - Swigcptr() uintptr; -} -func (p SwigcptrOuter_InnerMultiple) Swigcptr() uintptr { - return uintptr(p) -} - -type SwigcptrOuter_InnerClass2 uintptr -type Outer_InnerClass2 interface { - Swigcptr() uintptr; -} -func (p SwigcptrOuter_InnerClass2) Swigcptr() uintptr { - return uintptr(p) -} - -type SwigcptrOuter_InnerSameName uintptr -type Outer_InnerSameName interface { - Swigcptr() uintptr; -} -func (p SwigcptrOuter_InnerSameName) Swigcptr() uintptr { - return uintptr(p) -} - -type SwigcptrOuter_InnerUnion5 uintptr -type Outer_InnerUnion5 interface { - Swigcptr() uintptr; -} -func (p SwigcptrOuter_InnerUnion5) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/nested_comment.go b/Examples/test-suite/go/nested_comment.go deleted file mode 100644 index 0668255b8..000000000 --- a/Examples/test-suite/go/nested_comment.go +++ /dev/null @@ -1,113 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../nested_comment.i - -package nested_comment - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrS2 uintptr - -func (p SwigcptrS2) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrS2) SwigIsS2() { -} - -var _wrap_new_s2 unsafe.Pointer - -func _swig_wrap_new_s2() (base SwigcptrS2) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_s2, _swig_p) - return -} - -func NewS2() (_swig_ret S2) { - return _swig_wrap_new_s2() -} - -var _wrap_delete_s2 unsafe.Pointer - -func _swig_wrap_delete_s2(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_s2, _swig_p) - return -} - -func DeleteS2(arg1 S2) { - _swig_wrap_delete_s2(arg1.Swigcptr()) -} - -type S2 interface { - Swigcptr() uintptr - SwigIsS2() -} - -type SwigcptrA uintptr - -func (p SwigcptrA) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrA) SwigIsA() { -} - -var _wrap_new_a unsafe.Pointer - -func _swig_wrap_new_a() (base SwigcptrA) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_a, _swig_p) - return -} - -func NewA() (_swig_ret A) { - return _swig_wrap_new_a() -} - -var _wrap_delete_a unsafe.Pointer - -func _swig_wrap_delete_a(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_a, _swig_p) - return -} - -func DeleteA(arg1 A) { - _swig_wrap_delete_a(arg1.Swigcptr()) -} - -type A interface { - Swigcptr() uintptr - SwigIsA() -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/nested_directors.go b/Examples/test-suite/go/nested_directors.go deleted file mode 100644 index 02f6adffa..000000000 --- a/Examples/test-suite/go/nested_directors.go +++ /dev/null @@ -1,299 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../nested_directors.i - -package nested_directors - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type _swig_DirectorBase struct { - SwigcptrBase - v interface{} -} - -func (p *_swig_DirectorBase) Swigcptr() uintptr { - return p.SwigcptrBase.Swigcptr() -} - -func (p *_swig_DirectorBase) SwigIsBase() { -} - -func (p *_swig_DirectorBase) DirectorInterface() interface{} { - return p.v -} - -var _wrap__swig_NewDirectorBaseBase unsafe.Pointer - -func _swig_NewDirectorBaseBase(_swig_director *_swig_DirectorBase) (_swig_ret SwigcptrBase) { - _swig_p := uintptr(unsafe.Pointer(&_swig_director)) - _cgo_runtime_cgocall(_wrap__swig_NewDirectorBaseBase, _swig_p) - return -} - -func NewDirectorBase(v interface{}) Base { - p := &_swig_DirectorBase{0, v} - p.SwigcptrBase = _swig_NewDirectorBaseBase(p) - return p -} - -var _wrap_DeleteDirectorBase unsafe.Pointer - -func _swig_wrap_DeleteDirectorBase(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_DeleteDirectorBase, _swig_p) - return -} - -func DeleteDirectorBase(arg1 Base) { - _swig_wrap_DeleteDirectorBase(arg1.Swigcptr()) -} - -func Swiggo_DeleteDirector_Base(p *_swig_DirectorBase) { - p.SwigcptrBase = 0 -} - -type _swig_DirectorInterfaceBaseDoNothing interface { - DoNothing() bool -} - -func (swig_p *_swig_DirectorBase) DoNothing() bool { - if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceBaseDoNothing); swig_ok { - return swig_g.DoNothing() - } - panic("call to pure virtual method") -} - -func Swig_DirectorBase_callback_DoNothing(p *_swig_DirectorBase) (swig_result bool) { - var swig_r bool - swig_r = p.DoNothing() - return swig_r -} - -type SwigcptrBase uintptr - -func (p SwigcptrBase) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrBase) SwigIsBase() { -} - -func (p SwigcptrBase) DirectorInterface() interface{} { - return nil -} - -var _wrap_delete_Base unsafe.Pointer - -func _swig_wrap_delete_Base(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Base, _swig_p) - return -} - -func DeleteBase(arg1 Base) { - _swig_wrap_delete_Base(arg1.Swigcptr()) -} - -var _wrap_new_Base unsafe.Pointer - -func _swig_wrap_new_Base() (base SwigcptrBase) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Base, _swig_p) - return -} - -func NewBase() (_swig_ret Base) { - return _swig_wrap_new_Base() -} - -type Base interface { - Swigcptr() uintptr - SwigIsBase() - DirectorInterface() interface{} -} - -type _swig_DirectorSub struct { - SwigcptrSub - v interface{} -} - -func (p *_swig_DirectorSub) Swigcptr() uintptr { - return p.SwigcptrSub.Swigcptr() -} - -func (p *_swig_DirectorSub) SwigIsSub() { -} - -func (p *_swig_DirectorSub) DirectorInterface() interface{} { - return p.v -} - -var _wrap__swig_NewDirectorSubSub unsafe.Pointer - -func _swig_NewDirectorSubSub(_swig_director *_swig_DirectorSub) (_swig_ret SwigcptrSub) { - _swig_p := uintptr(unsafe.Pointer(&_swig_director)) - _cgo_runtime_cgocall(_wrap__swig_NewDirectorSubSub, _swig_p) - return -} - -func NewDirectorSub(v interface{}) Sub { - p := &_swig_DirectorSub{0, v} - p.SwigcptrSub = _swig_NewDirectorSubSub(p) - return p -} - -var _wrap_DeleteDirectorSub unsafe.Pointer - -func _swig_wrap_DeleteDirectorSub(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_DeleteDirectorSub, _swig_p) - return -} - -func DeleteDirectorSub(arg1 Sub) { - _swig_wrap_DeleteDirectorSub(arg1.Swigcptr()) -} - -func Swiggo_DeleteDirector_Sub(p *_swig_DirectorSub) { - p.SwigcptrSub = 0 -} - -type _swig_DirectorInterfaceSubDoNothing interface { - DoNothing() bool -} - -func (swig_p *_swig_DirectorSub) DoNothing() bool { - if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceSubDoNothing); swig_ok { - return swig_g.DoNothing() - } - panic("call to pure virtual method") -} - -func Swig_DirectorSub_callback_DoNothing(p *_swig_DirectorSub) (swig_result bool) { - var swig_r bool - swig_r = p.DoNothing() - return swig_r -} - -type _swig_DirectorInterfaceSubGetValue interface { - GetValue() bool -} - -var _wrap__swig_DirectorSub_upcall_GetValue unsafe.Pointer - -func _swig_wrap__swig_DirectorSub_upcall_GetValue(_swig_ptr SwigcptrSub) (_swig_ret bool) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) - _cgo_runtime_cgocall(_wrap__swig_DirectorSub_upcall_GetValue, _swig_p) - return -} - -func (swig_p *_swig_DirectorSub) GetValue() bool { - if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceSubGetValue); swig_ok { - return swig_g.GetValue() - } - var swig_r bool - swig_r = _swig_wrap__swig_DirectorSub_upcall_GetValue(swig_p.SwigcptrSub) - return swig_r -} - -func DirectorSubGetValue(p Sub) bool { - var swig_r bool - swig_r = _swig_wrap__swig_DirectorSub_upcall_GetValue(p.(*_swig_DirectorSub).SwigcptrSub) - return swig_r -} - -func Swig_DirectorSub_callback_GetValue(p *_swig_DirectorSub) (swig_result bool) { - var swig_r bool - swig_r = p.GetValue() - return swig_r -} - -type SwigcptrSub uintptr - -func (p SwigcptrSub) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrSub) SwigIsSub() { -} - -func (p SwigcptrSub) DirectorInterface() interface{} { - return nil -} - -var _wrap_delete_Sub unsafe.Pointer - -func _swig_wrap_delete_Sub(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Sub, _swig_p) - return -} - -func DeleteSub(arg1 Sub) { - _swig_wrap_delete_Sub(arg1.Swigcptr()) -} - -var _wrap_new_Sub unsafe.Pointer - -func _swig_wrap_new_Sub() (base SwigcptrSub) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Sub, _swig_p) - return -} - -func NewSub() (_swig_ret Sub) { - return _swig_wrap_new_Sub() -} - -func (p SwigcptrSub) SwigIsBase() { -} - -func (p SwigcptrSub) SwigGetBase() Base { - return SwigcptrBase(p.Swigcptr()) -} - -type Sub interface { - Swigcptr() uintptr - SwigIsSub() - DirectorInterface() interface{} - SwigIsBase() - SwigGetBase() Base -} - - -type SwigcptrSwigDirector_Sub uintptr -type SwigDirector_Sub interface { - Swigcptr() uintptr; -} -func (p SwigcptrSwigDirector_Sub) Swigcptr() uintptr { - return uintptr(p) -} - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/nested_directors_wrap.h b/Examples/test-suite/go/nested_directors_wrap.h deleted file mode 100644 index e2bd53c6b..000000000 --- a/Examples/test-suite/go/nested_directors_wrap.h +++ /dev/null @@ -1,41 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../nested_directors.i - -#ifndef SWIG_nested_directors_WRAP_H_ -#define SWIG_nested_directors_WRAP_H_ - -class SwigDirector_Base : public NN::Base -{ - public: - SwigDirector_Base(void *swig_p); - virtual ~SwigDirector_Base(); - virtual bool DoNothing(); - private: - void *go_val; -}; - -class SwigDirector_Sub : public NN::Sub -{ - public: - SwigDirector_Sub(void *swig_p); - virtual ~SwigDirector_Sub(); - virtual bool DoNothing(); - bool _swig_upcall_GetValue() const { - return NN::Sub::GetValue(); - } - virtual bool GetValue() const; - using NN::Sub::DoSomething; - private: - void *go_val; -}; - -#endif diff --git a/Examples/test-suite/go/nested_extend_c.go b/Examples/test-suite/go/nested_extend_c.go deleted file mode 100644 index 284a87f31..000000000 --- a/Examples/test-suite/go/nested_extend_c.go +++ /dev/null @@ -1,875 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../nested_extend_c.i - -package nested_extend_c - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrNestedA uintptr - -func (p SwigcptrNestedA) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrNestedA) SwigIsNestedA() { -} - -var _wrap_NestedA_hiA_instance_set unsafe.Pointer - -func _swig_wrap_NestedA_hiA_instance_set(base SwigcptrNestedA, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_NestedA_hiA_instance_set, _swig_p) - return -} - -func (arg1 SwigcptrNestedA) SetHiA_instance(arg2 HiA) { - _swig_wrap_NestedA_hiA_instance_set(arg1, arg2.Swigcptr()) -} - -var _wrap_NestedA_hiA_instance_get unsafe.Pointer - -func _swig_wrap_NestedA_hiA_instance_get(base SwigcptrNestedA) (_ SwigcptrHiA) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_NestedA_hiA_instance_get, _swig_p) - return -} - -func (arg1 SwigcptrNestedA) GetHiA_instance() (_swig_ret HiA) { - return _swig_wrap_NestedA_hiA_instance_get(arg1) -} - -var _wrap_NestedA_lowA_instance_set unsafe.Pointer - -func _swig_wrap_NestedA_lowA_instance_set(base SwigcptrNestedA, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_NestedA_lowA_instance_set, _swig_p) - return -} - -func (arg1 SwigcptrNestedA) SetLowA_instance(arg2 LowA) { - _swig_wrap_NestedA_lowA_instance_set(arg1, arg2.Swigcptr()) -} - -var _wrap_NestedA_lowA_instance_get unsafe.Pointer - -func _swig_wrap_NestedA_lowA_instance_get(base SwigcptrNestedA) (_ SwigcptrLowA) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_NestedA_lowA_instance_get, _swig_p) - return -} - -func (arg1 SwigcptrNestedA) GetLowA_instance() (_swig_ret LowA) { - return _swig_wrap_NestedA_lowA_instance_get(arg1) -} - -var _wrap_NestedA_a_set unsafe.Pointer - -func _swig_wrap_NestedA_a_set(base SwigcptrNestedA, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_NestedA_a_set, _swig_p) - return -} - -func (arg1 SwigcptrNestedA) SetA(arg2 int) { - _swig_wrap_NestedA_a_set(arg1, arg2) -} - -var _wrap_NestedA_a_get unsafe.Pointer - -func _swig_wrap_NestedA_a_get(base SwigcptrNestedA) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_NestedA_a_get, _swig_p) - return -} - -func (arg1 SwigcptrNestedA) GetA() (_swig_ret int) { - return _swig_wrap_NestedA_a_get(arg1) -} - -var _wrap_NestedA_swig_size_NestedA unsafe.Pointer - -func _swig_getNestedA_NestedA_swig_size_NestedA() (_swig_ret int64) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_NestedA_swig_size_NestedA, _swig_p) - return -} -var NestedASwig_size int64 = _swig_getNestedA_NestedA_swig_size_NestedA() -var _wrap_new_NestedA unsafe.Pointer - -func _swig_wrap_new_NestedA() (base SwigcptrNestedA) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_NestedA, _swig_p) - return -} - -func NewNestedA() (_swig_ret NestedA) { - return _swig_wrap_new_NestedA() -} - -var _wrap_delete_NestedA unsafe.Pointer - -func _swig_wrap_delete_NestedA(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_NestedA, _swig_p) - return -} - -func DeleteNestedA(arg1 NestedA) { - _swig_wrap_delete_NestedA(arg1.Swigcptr()) -} - -type NestedA interface { - Swigcptr() uintptr - SwigIsNestedA() - SetHiA_instance(arg2 HiA) - GetHiA_instance() (_swig_ret HiA) - SetLowA_instance(arg2 LowA) - GetLowA_instance() (_swig_ret LowA) - SetA(arg2 int) - GetA() (_swig_ret int) -} - -type SwigcptrHiA uintptr - -func (p SwigcptrHiA) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrHiA) SwigIsHiA() { -} - -var _wrap_hiA_c_set unsafe.Pointer - -func _swig_wrap_hiA_c_set(base SwigcptrHiA, _ byte) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_hiA_c_set, _swig_p) - return -} - -func (arg1 SwigcptrHiA) SetC(arg2 byte) { - _swig_wrap_hiA_c_set(arg1, arg2) -} - -var _wrap_hiA_c_get unsafe.Pointer - -func _swig_wrap_hiA_c_get(base SwigcptrHiA) (_ byte) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_hiA_c_get, _swig_p) - return -} - -func (arg1 SwigcptrHiA) GetC() (_swig_ret byte) { - return _swig_wrap_hiA_c_get(arg1) -} - -var _wrap_hiA_d_set unsafe.Pointer - -func _swig_wrap_hiA_d_set(base SwigcptrHiA, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_hiA_d_set, _swig_p) - return -} - -func (arg1 SwigcptrHiA) SetD(arg2 int) { - _swig_wrap_hiA_d_set(arg1, arg2) -} - -var _wrap_hiA_d_get unsafe.Pointer - -func _swig_wrap_hiA_d_get(base SwigcptrHiA) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_hiA_d_get, _swig_p) - return -} - -func (arg1 SwigcptrHiA) GetD() (_swig_ret int) { - return _swig_wrap_hiA_d_get(arg1) -} - -var _wrap_new_hiA unsafe.Pointer - -func _swig_wrap_new_hiA() (base SwigcptrHiA) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_hiA, _swig_p) - return -} - -func NewHiA() (_swig_ret HiA) { - return _swig_wrap_new_hiA() -} - -var _wrap_hiA_hi_extend unsafe.Pointer - -func _swig_wrap_hiA_hi_extend(base SwigcptrHiA) (_ byte) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_hiA_hi_extend, _swig_p) - return -} - -func (arg1 SwigcptrHiA) Hi_extend() (_swig_ret byte) { - return _swig_wrap_hiA_hi_extend(arg1) -} - -var _wrap_hiA_swig_size_hiA unsafe.Pointer - -func _swig_gethiA_hiA_swig_size_hiA() (_swig_ret int64) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_hiA_swig_size_hiA, _swig_p) - return -} -var HiASwig_size int64 = _swig_gethiA_hiA_swig_size_hiA() -var _wrap_delete_hiA unsafe.Pointer - -func _swig_wrap_delete_hiA(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_hiA, _swig_p) - return -} - -func DeleteHiA(arg1 HiA) { - _swig_wrap_delete_hiA(arg1.Swigcptr()) -} - -type HiA interface { - Swigcptr() uintptr - SwigIsHiA() - SetC(arg2 byte) - GetC() (_swig_ret byte) - SetD(arg2 int) - GetD() (_swig_ret int) - Hi_extend() (_swig_ret byte) -} - -type SwigcptrLowA uintptr - -func (p SwigcptrLowA) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrLowA) SwigIsLowA() { -} - -var _wrap_lowA_name_set unsafe.Pointer - -func _swig_wrap_lowA_name_set(base SwigcptrLowA, _ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_lowA_name_set, _swig_p) - return -} - -func (arg1 SwigcptrLowA) SetName(arg2 string) { - _swig_wrap_lowA_name_set(arg1, arg2) -} - -var _wrap_lowA_name_get unsafe.Pointer - -func _swig_wrap_lowA_name_get(base SwigcptrLowA) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_lowA_name_get, _swig_p) - return -} - -func (arg1 SwigcptrLowA) GetName() (_swig_ret string) { - return _swig_wrap_lowA_name_get(arg1) -} - -var _wrap_lowA_num_set unsafe.Pointer - -func _swig_wrap_lowA_num_set(base SwigcptrLowA, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_lowA_num_set, _swig_p) - return -} - -func (arg1 SwigcptrLowA) SetNum(arg2 int) { - _swig_wrap_lowA_num_set(arg1, arg2) -} - -var _wrap_lowA_num_get unsafe.Pointer - -func _swig_wrap_lowA_num_get(base SwigcptrLowA) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_lowA_num_get, _swig_p) - return -} - -func (arg1 SwigcptrLowA) GetNum() (_swig_ret int) { - return _swig_wrap_lowA_num_get(arg1) -} - -var _wrap_new_lowA unsafe.Pointer - -func _swig_wrap_new_lowA() (base SwigcptrLowA) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_lowA, _swig_p) - return -} - -func NewLowA() (_swig_ret LowA) { - return _swig_wrap_new_lowA() -} - -var _wrap_lowA_low_extend unsafe.Pointer - -func _swig_wrap_lowA_low_extend(base SwigcptrLowA) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_lowA_low_extend, _swig_p) - return -} - -func (arg1 SwigcptrLowA) Low_extend() (_swig_ret int) { - return _swig_wrap_lowA_low_extend(arg1) -} - -var _wrap_lowA_swig_size_lowA unsafe.Pointer - -func _swig_getlowA_lowA_swig_size_lowA() (_swig_ret int64) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_lowA_swig_size_lowA, _swig_p) - return -} -var LowASwig_size int64 = _swig_getlowA_lowA_swig_size_lowA() -var _wrap_delete_lowA unsafe.Pointer - -func _swig_wrap_delete_lowA(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_lowA, _swig_p) - return -} - -func DeleteLowA(arg1 LowA) { - _swig_wrap_delete_lowA(arg1.Swigcptr()) -} - -type LowA interface { - Swigcptr() uintptr - SwigIsLowA() - SetName(arg2 string) - GetName() (_swig_ret string) - SetNum(arg2 int) - GetNum() (_swig_ret int) - Low_extend() (_swig_ret int) -} - -type SwigcptrNestedB uintptr - -func (p SwigcptrNestedB) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrNestedB) SwigIsNestedB() { -} - -var _wrap_NestedB_hiB_instance_get unsafe.Pointer - -func _swig_wrap_NestedB_hiB_instance_get(base SwigcptrNestedB) (_ SwigcptrHiB) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_NestedB_hiB_instance_get, _swig_p) - return -} - -func (arg1 SwigcptrNestedB) GetHiB_instance() (_swig_ret HiB) { - return _swig_wrap_NestedB_hiB_instance_get(arg1) -} - -var _wrap_NestedB_lowB_instance_get unsafe.Pointer - -func _swig_wrap_NestedB_lowB_instance_get(base SwigcptrNestedB) (_ SwigcptrLowB) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_NestedB_lowB_instance_get, _swig_p) - return -} - -func (arg1 SwigcptrNestedB) GetLowB_instance() (_swig_ret LowB) { - return _swig_wrap_NestedB_lowB_instance_get(arg1) -} - -var _wrap_NestedB_a_set unsafe.Pointer - -func _swig_wrap_NestedB_a_set(base SwigcptrNestedB, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_NestedB_a_set, _swig_p) - return -} - -func (arg1 SwigcptrNestedB) SetA(arg2 int) { - _swig_wrap_NestedB_a_set(arg1, arg2) -} - -var _wrap_NestedB_a_get unsafe.Pointer - -func _swig_wrap_NestedB_a_get(base SwigcptrNestedB) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_NestedB_a_get, _swig_p) - return -} - -func (arg1 SwigcptrNestedB) GetA() (_swig_ret int) { - return _swig_wrap_NestedB_a_get(arg1) -} - -var _wrap_new_NestedB unsafe.Pointer - -func _swig_wrap_new_NestedB() (base SwigcptrNestedB) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_NestedB, _swig_p) - return -} - -func NewNestedB() (_swig_ret NestedB) { - return _swig_wrap_new_NestedB() -} - -var _wrap_delete_NestedB unsafe.Pointer - -func _swig_wrap_delete_NestedB(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_NestedB, _swig_p) - return -} - -func DeleteNestedB(arg1 NestedB) { - _swig_wrap_delete_NestedB(arg1.Swigcptr()) -} - -type NestedB interface { - Swigcptr() uintptr - SwigIsNestedB() - GetHiB_instance() (_swig_ret HiB) - GetLowB_instance() (_swig_ret LowB) - SetA(arg2 int) - GetA() (_swig_ret int) -} - -type SwigcptrHiB uintptr - -func (p SwigcptrHiB) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrHiB) SwigIsHiB() { -} - -var _wrap_hiB_c_set unsafe.Pointer - -func _swig_wrap_hiB_c_set(base SwigcptrHiB, _ byte) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_hiB_c_set, _swig_p) - return -} - -func (arg1 SwigcptrHiB) SetC(arg2 byte) { - _swig_wrap_hiB_c_set(arg1, arg2) -} - -var _wrap_hiB_c_get unsafe.Pointer - -func _swig_wrap_hiB_c_get(base SwigcptrHiB) (_ byte) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_hiB_c_get, _swig_p) - return -} - -func (arg1 SwigcptrHiB) GetC() (_swig_ret byte) { - return _swig_wrap_hiB_c_get(arg1) -} - -var _wrap_hiB_d_set unsafe.Pointer - -func _swig_wrap_hiB_d_set(base SwigcptrHiB, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_hiB_d_set, _swig_p) - return -} - -func (arg1 SwigcptrHiB) SetD(arg2 int) { - _swig_wrap_hiB_d_set(arg1, arg2) -} - -var _wrap_hiB_d_get unsafe.Pointer - -func _swig_wrap_hiB_d_get(base SwigcptrHiB) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_hiB_d_get, _swig_p) - return -} - -func (arg1 SwigcptrHiB) GetD() (_swig_ret int) { - return _swig_wrap_hiB_d_get(arg1) -} - -var _wrap_new_hiB unsafe.Pointer - -func _swig_wrap_new_hiB() (base SwigcptrHiB) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_hiB, _swig_p) - return -} - -func NewHiB() (_swig_ret HiB) { - return _swig_wrap_new_hiB() -} - -var _wrap_hiB_hi_extend unsafe.Pointer - -func _swig_wrap_hiB_hi_extend(base SwigcptrHiB) (_ byte) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_hiB_hi_extend, _swig_p) - return -} - -func (arg1 SwigcptrHiB) Hi_extend() (_swig_ret byte) { - return _swig_wrap_hiB_hi_extend(arg1) -} - -var _wrap_hiB_swig_size_hiB unsafe.Pointer - -func _swig_gethiB_hiB_swig_size_hiB() (_swig_ret int64) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_hiB_swig_size_hiB, _swig_p) - return -} -var HiBSwig_size int64 = _swig_gethiB_hiB_swig_size_hiB() -var _wrap_delete_hiB unsafe.Pointer - -func _swig_wrap_delete_hiB(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_hiB, _swig_p) - return -} - -func DeleteHiB(arg1 HiB) { - _swig_wrap_delete_hiB(arg1.Swigcptr()) -} - -type HiB interface { - Swigcptr() uintptr - SwigIsHiB() - SetC(arg2 byte) - GetC() (_swig_ret byte) - SetD(arg2 int) - GetD() (_swig_ret int) - Hi_extend() (_swig_ret byte) -} - -type SwigcptrLowB uintptr - -func (p SwigcptrLowB) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrLowB) SwigIsLowB() { -} - -var _wrap_lowB_name_set unsafe.Pointer - -func _swig_wrap_lowB_name_set(base SwigcptrLowB, _ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_lowB_name_set, _swig_p) - return -} - -func (arg1 SwigcptrLowB) SetName(arg2 string) { - _swig_wrap_lowB_name_set(arg1, arg2) -} - -var _wrap_lowB_name_get unsafe.Pointer - -func _swig_wrap_lowB_name_get(base SwigcptrLowB) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_lowB_name_get, _swig_p) - return -} - -func (arg1 SwigcptrLowB) GetName() (_swig_ret string) { - return _swig_wrap_lowB_name_get(arg1) -} - -var _wrap_lowB_num_set unsafe.Pointer - -func _swig_wrap_lowB_num_set(base SwigcptrLowB, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_lowB_num_set, _swig_p) - return -} - -func (arg1 SwigcptrLowB) SetNum(arg2 int) { - _swig_wrap_lowB_num_set(arg1, arg2) -} - -var _wrap_lowB_num_get unsafe.Pointer - -func _swig_wrap_lowB_num_get(base SwigcptrLowB) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_lowB_num_get, _swig_p) - return -} - -func (arg1 SwigcptrLowB) GetNum() (_swig_ret int) { - return _swig_wrap_lowB_num_get(arg1) -} - -var _wrap_new_lowB unsafe.Pointer - -func _swig_wrap_new_lowB() (base SwigcptrLowB) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_lowB, _swig_p) - return -} - -func NewLowB() (_swig_ret LowB) { - return _swig_wrap_new_lowB() -} - -var _wrap_lowB_low_extend unsafe.Pointer - -func _swig_wrap_lowB_low_extend(base SwigcptrLowB) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_lowB_low_extend, _swig_p) - return -} - -func (arg1 SwigcptrLowB) Low_extend() (_swig_ret int) { - return _swig_wrap_lowB_low_extend(arg1) -} - -var _wrap_lowB_swig_size_lowB unsafe.Pointer - -func _swig_getlowB_lowB_swig_size_lowB() (_swig_ret int64) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_lowB_swig_size_lowB, _swig_p) - return -} -var LowBSwig_size int64 = _swig_getlowB_lowB_swig_size_lowB() -var _wrap_delete_lowB unsafe.Pointer - -func _swig_wrap_delete_lowB(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_lowB, _swig_p) - return -} - -func DeleteLowB(arg1 LowB) { - _swig_wrap_delete_lowB(arg1.Swigcptr()) -} - -type LowB interface { - Swigcptr() uintptr - SwigIsLowB() - SetName(arg2 string) - GetName() (_swig_ret string) - SetNum(arg2 int) - GetNum() (_swig_ret int) - Low_extend() (_swig_ret int) -} - -type SwigcptrFOO uintptr - -func (p SwigcptrFOO) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrFOO) SwigIsFOO() { -} - -var _wrap_FOO_a_set unsafe.Pointer - -func _swig_wrap_FOO_a_set(base SwigcptrFOO, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_FOO_a_set, _swig_p) - return -} - -func (arg1 SwigcptrFOO) SetA(arg2 int) { - _swig_wrap_FOO_a_set(arg1, arg2) -} - -var _wrap_FOO_a_get unsafe.Pointer - -func _swig_wrap_FOO_a_get(base SwigcptrFOO) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_FOO_a_get, _swig_p) - return -} - -func (arg1 SwigcptrFOO) GetA() (_swig_ret int) { - return _swig_wrap_FOO_a_get(arg1) -} - -var _wrap_FOO_bar_get unsafe.Pointer - -func _swig_wrap_FOO_bar_get(base SwigcptrFOO) (_ SwigcptrFOO_bar) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_FOO_bar_get, _swig_p) - return -} - -func (arg1 SwigcptrFOO) GetBar() (_swig_ret FOO_bar) { - return _swig_wrap_FOO_bar_get(arg1) -} - -var _wrap_new_FOO unsafe.Pointer - -func _swig_wrap_new_FOO() (base SwigcptrFOO) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_FOO, _swig_p) - return -} - -func NewFOO() (_swig_ret FOO) { - return _swig_wrap_new_FOO() -} - -var _wrap_delete_FOO unsafe.Pointer - -func _swig_wrap_delete_FOO(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_FOO, _swig_p) - return -} - -func DeleteFOO(arg1 FOO) { - _swig_wrap_delete_FOO(arg1.Swigcptr()) -} - -type FOO interface { - Swigcptr() uintptr - SwigIsFOO() - SetA(arg2 int) - GetA() (_swig_ret int) - GetBar() (_swig_ret FOO_bar) -} - -type SwigcptrFOO_bar uintptr - -func (p SwigcptrFOO_bar) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrFOO_bar) SwigIsFOO_bar() { -} - -var _wrap_FOO_bar_c_set unsafe.Pointer - -func _swig_wrap_FOO_bar_c_set(base SwigcptrFOO_bar, _ byte) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_FOO_bar_c_set, _swig_p) - return -} - -func (arg1 SwigcptrFOO_bar) SetC(arg2 byte) { - _swig_wrap_FOO_bar_c_set(arg1, arg2) -} - -var _wrap_FOO_bar_c_get unsafe.Pointer - -func _swig_wrap_FOO_bar_c_get(base SwigcptrFOO_bar) (_ byte) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_FOO_bar_c_get, _swig_p) - return -} - -func (arg1 SwigcptrFOO_bar) GetC() (_swig_ret byte) { - return _swig_wrap_FOO_bar_c_get(arg1) -} - -var _wrap_FOO_bar_d_set unsafe.Pointer - -func _swig_wrap_FOO_bar_d_set(base SwigcptrFOO_bar, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_FOO_bar_d_set, _swig_p) - return -} - -func (arg1 SwigcptrFOO_bar) SetD(arg2 int) { - _swig_wrap_FOO_bar_d_set(arg1, arg2) -} - -var _wrap_FOO_bar_d_get unsafe.Pointer - -func _swig_wrap_FOO_bar_d_get(base SwigcptrFOO_bar) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_FOO_bar_d_get, _swig_p) - return -} - -func (arg1 SwigcptrFOO_bar) GetD() (_swig_ret int) { - return _swig_wrap_FOO_bar_d_get(arg1) -} - -var _wrap_FOO_bar_bar_extend unsafe.Pointer - -func _swig_wrap_FOO_bar_bar_extend(base SwigcptrFOO_bar) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_FOO_bar_bar_extend, _swig_p) - return -} - -func (arg1 SwigcptrFOO_bar) Bar_extend() { - _swig_wrap_FOO_bar_bar_extend(arg1) -} - -var _wrap_new_FOO_bar unsafe.Pointer - -func _swig_wrap_new_FOO_bar() (base SwigcptrFOO_bar) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_FOO_bar, _swig_p) - return -} - -func NewFOO_bar() (_swig_ret FOO_bar) { - return _swig_wrap_new_FOO_bar() -} - -var _wrap_delete_FOO_bar unsafe.Pointer - -func _swig_wrap_delete_FOO_bar(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_FOO_bar, _swig_p) - return -} - -func DeleteFOO_bar(arg1 FOO_bar) { - _swig_wrap_delete_FOO_bar(arg1.Swigcptr()) -} - -type FOO_bar interface { - Swigcptr() uintptr - SwigIsFOO_bar() - SetC(arg2 byte) - GetC() (_swig_ret byte) - SetD(arg2 int) - GetD() (_swig_ret int) - Bar_extend() -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/nested_scope.go b/Examples/test-suite/go/nested_scope.go deleted file mode 100644 index ae4d2b7a9..000000000 --- a/Examples/test-suite/go/nested_scope.go +++ /dev/null @@ -1,203 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../nested_scope.i - -package nested_scope - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrGlobal_ uintptr - -func (p SwigcptrGlobal_) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrGlobal_) SwigIsGlobal_() { -} - -var _wrap_Global__instance_set unsafe.Pointer - -func _swig_wrap_Global__instance_set(base SwigcptrGlobal_, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Global__instance_set, _swig_p) - return -} - -func (arg1 SwigcptrGlobal_) SetInstance(arg2 Nested) { - _swig_wrap_Global__instance_set(arg1, arg2.Swigcptr()) -} - -var _wrap_Global__instance_get unsafe.Pointer - -func _swig_wrap_Global__instance_get(base SwigcptrGlobal_) (_ SwigcptrNested) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Global__instance_get, _swig_p) - return -} - -func (arg1 SwigcptrGlobal_) GetInstance() (_swig_ret Nested) { - return _swig_wrap_Global__instance_get(arg1) -} - -var _wrap_new_Global_ unsafe.Pointer - -func _swig_wrap_new_Global_() (base SwigcptrGlobal_) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Global_, _swig_p) - return -} - -func NewGlobal_() (_swig_ret Global_) { - return _swig_wrap_new_Global_() -} - -var _wrap_delete_Global_ unsafe.Pointer - -func _swig_wrap_delete_Global_(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Global_, _swig_p) - return -} - -func DeleteGlobal_(arg1 Global_) { - _swig_wrap_delete_Global_(arg1.Swigcptr()) -} - -type Global_ interface { - Swigcptr() uintptr - SwigIsGlobal_() - SetInstance(arg2 Nested) - GetInstance() (_swig_ret Nested) -} - -type SwigcptrOuter uintptr - -func (p SwigcptrOuter) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrOuter) SwigIsOuter() { -} - -var _wrap_new_Outer unsafe.Pointer - -func _swig_wrap_new_Outer() (base SwigcptrOuter) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Outer, _swig_p) - return -} - -func NewOuter() (_swig_ret Outer) { - return _swig_wrap_new_Outer() -} - -var _wrap_delete_Outer unsafe.Pointer - -func _swig_wrap_delete_Outer(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Outer, _swig_p) - return -} - -func DeleteOuter(arg1 Outer) { - _swig_wrap_delete_Outer(arg1.Swigcptr()) -} - -type Outer interface { - Swigcptr() uintptr - SwigIsOuter() -} - -type SwigcptrNested uintptr - -func (p SwigcptrNested) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrNested) SwigIsNested() { -} - -var _wrap_Nested_data_set unsafe.Pointer - -func _swig_wrap_Nested_data_set(base SwigcptrNested, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Nested_data_set, _swig_p) - return -} - -func (arg1 SwigcptrNested) SetData(arg2 int) { - _swig_wrap_Nested_data_set(arg1, arg2) -} - -var _wrap_Nested_data_get unsafe.Pointer - -func _swig_wrap_Nested_data_get(base SwigcptrNested) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Nested_data_get, _swig_p) - return -} - -func (arg1 SwigcptrNested) GetData() (_swig_ret int) { - return _swig_wrap_Nested_data_get(arg1) -} - -var _wrap_new_Nested unsafe.Pointer - -func _swig_wrap_new_Nested() (base SwigcptrNested) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Nested, _swig_p) - return -} - -func NewNested() (_swig_ret Nested) { - return _swig_wrap_new_Nested() -} - -var _wrap_delete_Nested unsafe.Pointer - -func _swig_wrap_delete_Nested(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Nested, _swig_p) - return -} - -func DeleteNested(arg1 Nested) { - _swig_wrap_delete_Nested(arg1.Swigcptr()) -} - -type Nested interface { - Swigcptr() uintptr - SwigIsNested() - SetData(arg2 int) - GetData() (_swig_ret int) -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/nested_structs.go b/Examples/test-suite/go/nested_structs.go deleted file mode 100644 index 79ca10941..000000000 --- a/Examples/test-suite/go/nested_structs.go +++ /dev/null @@ -1,470 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../nested_structs.i - -package nested_structs - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrOuter uintptr - -func (p SwigcptrOuter) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrOuter) SwigIsOuter() { -} - -var _wrap_Outer_inside1_set unsafe.Pointer - -func _swig_wrap_Outer_inside1_set(base SwigcptrOuter, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Outer_inside1_set, _swig_p) - return -} - -func (arg1 SwigcptrOuter) SetInside1(arg2 Named) { - _swig_wrap_Outer_inside1_set(arg1, arg2.Swigcptr()) -} - -var _wrap_Outer_inside1_get unsafe.Pointer - -func _swig_wrap_Outer_inside1_get(base SwigcptrOuter) (_ SwigcptrNamed) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Outer_inside1_get, _swig_p) - return -} - -func (arg1 SwigcptrOuter) GetInside1() (_swig_ret Named) { - return _swig_wrap_Outer_inside1_get(arg1) -} - -var _wrap_Outer_inside2_set unsafe.Pointer - -func _swig_wrap_Outer_inside2_set(base SwigcptrOuter, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Outer_inside2_set, _swig_p) - return -} - -func (arg1 SwigcptrOuter) SetInside2(arg2 Named) { - _swig_wrap_Outer_inside2_set(arg1, arg2.Swigcptr()) -} - -var _wrap_Outer_inside2_get unsafe.Pointer - -func _swig_wrap_Outer_inside2_get(base SwigcptrOuter) (_ SwigcptrNamed) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Outer_inside2_get, _swig_p) - return -} - -func (arg1 SwigcptrOuter) GetInside2() (_swig_ret Named) { - return _swig_wrap_Outer_inside2_get(arg1) -} - -var _wrap_Outer_inside3_set unsafe.Pointer - -func _swig_wrap_Outer_inside3_set(base SwigcptrOuter, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Outer_inside3_set, _swig_p) - return -} - -func (arg1 SwigcptrOuter) SetInside3(arg2 Named) { - _swig_wrap_Outer_inside3_set(arg1, arg2.Swigcptr()) -} - -var _wrap_Outer_inside3_get unsafe.Pointer - -func _swig_wrap_Outer_inside3_get(base SwigcptrOuter) (_ SwigcptrNamed) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Outer_inside3_get, _swig_p) - return -} - -func (arg1 SwigcptrOuter) GetInside3() (_swig_ret Named) { - return _swig_wrap_Outer_inside3_get(arg1) -} - -var _wrap_Outer_inside4_set unsafe.Pointer - -func _swig_wrap_Outer_inside4_set(base SwigcptrOuter, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Outer_inside4_set, _swig_p) - return -} - -func (arg1 SwigcptrOuter) SetInside4(arg2 Named) { - _swig_wrap_Outer_inside4_set(arg1, arg2.Swigcptr()) -} - -var _wrap_Outer_inside4_get unsafe.Pointer - -func _swig_wrap_Outer_inside4_get(base SwigcptrOuter) (_ SwigcptrNamed) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Outer_inside4_get, _swig_p) - return -} - -func (arg1 SwigcptrOuter) GetInside4() (_swig_ret Named) { - return _swig_wrap_Outer_inside4_get(arg1) -} - -var _wrap_Outer_inside5_set unsafe.Pointer - -func _swig_wrap_Outer_inside5_set(base SwigcptrOuter, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Outer_inside5_set, _swig_p) - return -} - -func (arg1 SwigcptrOuter) SetInside5(arg2 Named) { - _swig_wrap_Outer_inside5_set(arg1, arg2.Swigcptr()) -} - -var _wrap_Outer_inside5_get unsafe.Pointer - -func _swig_wrap_Outer_inside5_get(base SwigcptrOuter) (_ SwigcptrNamed) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Outer_inside5_get, _swig_p) - return -} - -func (arg1 SwigcptrOuter) GetInside5() (_swig_ret Named) { - return _swig_wrap_Outer_inside5_get(arg1) -} - -var _wrap_Outer_inner1_get unsafe.Pointer - -func _swig_wrap_Outer_inner1_get(base SwigcptrOuter) (_ SwigcptrOuter_inner1) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Outer_inner1_get, _swig_p) - return -} - -func (arg1 SwigcptrOuter) GetInner1() (_swig_ret Outer_inner1) { - return _swig_wrap_Outer_inner1_get(arg1) -} - -var _wrap_Outer_inner2_get unsafe.Pointer - -func _swig_wrap_Outer_inner2_get(base SwigcptrOuter) (_ SwigcptrOuter_inner1) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Outer_inner2_get, _swig_p) - return -} - -func (arg1 SwigcptrOuter) GetInner2() (_swig_ret Outer_inner1) { - return _swig_wrap_Outer_inner2_get(arg1) -} - -var _wrap_Outer_inner3_get unsafe.Pointer - -func _swig_wrap_Outer_inner3_get(base SwigcptrOuter) (_ SwigcptrOuter_inner1) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Outer_inner3_get, _swig_p) - return -} - -func (arg1 SwigcptrOuter) GetInner3() (_swig_ret Outer_inner1) { - return _swig_wrap_Outer_inner3_get(arg1) -} - -var _wrap_Outer_inner4_get unsafe.Pointer - -func _swig_wrap_Outer_inner4_get(base SwigcptrOuter) (_ SwigcptrOuter_inner1) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Outer_inner4_get, _swig_p) - return -} - -func (arg1 SwigcptrOuter) GetInner4() (_swig_ret Outer_inner1) { - return _swig_wrap_Outer_inner4_get(arg1) -} - -var _wrap_Outer_inner5_get unsafe.Pointer - -func _swig_wrap_Outer_inner5_get(base SwigcptrOuter) (_ SwigcptrOuter_inner1) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Outer_inner5_get, _swig_p) - return -} - -func (arg1 SwigcptrOuter) GetInner5() (_swig_ret Outer_inner1) { - return _swig_wrap_Outer_inner5_get(arg1) -} - -var _wrap_new_Outer unsafe.Pointer - -func _swig_wrap_new_Outer() (base SwigcptrOuter) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Outer, _swig_p) - return -} - -func NewOuter() (_swig_ret Outer) { - return _swig_wrap_new_Outer() -} - -var _wrap_delete_Outer unsafe.Pointer - -func _swig_wrap_delete_Outer(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Outer, _swig_p) - return -} - -func DeleteOuter(arg1 Outer) { - _swig_wrap_delete_Outer(arg1.Swigcptr()) -} - -type Outer interface { - Swigcptr() uintptr - SwigIsOuter() - SetInside1(arg2 Named) - GetInside1() (_swig_ret Named) - SetInside2(arg2 Named) - GetInside2() (_swig_ret Named) - SetInside3(arg2 Named) - GetInside3() (_swig_ret Named) - SetInside4(arg2 Named) - GetInside4() (_swig_ret Named) - SetInside5(arg2 Named) - GetInside5() (_swig_ret Named) - GetInner1() (_swig_ret Outer_inner1) - GetInner2() (_swig_ret Outer_inner1) - GetInner3() (_swig_ret Outer_inner1) - GetInner4() (_swig_ret Outer_inner1) - GetInner5() (_swig_ret Outer_inner1) -} - -type SwigcptrOuter_inner1 uintptr - -func (p SwigcptrOuter_inner1) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrOuter_inner1) SwigIsOuter_inner1() { -} - -var _wrap_Outer_inner1_val_set unsafe.Pointer - -func _swig_wrap_Outer_inner1_val_set(base SwigcptrOuter_inner1, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Outer_inner1_val_set, _swig_p) - return -} - -func (arg1 SwigcptrOuter_inner1) SetVal(arg2 int) { - _swig_wrap_Outer_inner1_val_set(arg1, arg2) -} - -var _wrap_Outer_inner1_val_get unsafe.Pointer - -func _swig_wrap_Outer_inner1_val_get(base SwigcptrOuter_inner1) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Outer_inner1_val_get, _swig_p) - return -} - -func (arg1 SwigcptrOuter_inner1) GetVal() (_swig_ret int) { - return _swig_wrap_Outer_inner1_val_get(arg1) -} - -var _wrap_new_Outer_inner1 unsafe.Pointer - -func _swig_wrap_new_Outer_inner1() (base SwigcptrOuter_inner1) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Outer_inner1, _swig_p) - return -} - -func NewOuter_inner1() (_swig_ret Outer_inner1) { - return _swig_wrap_new_Outer_inner1() -} - -var _wrap_delete_Outer_inner1 unsafe.Pointer - -func _swig_wrap_delete_Outer_inner1(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Outer_inner1, _swig_p) - return -} - -func DeleteOuter_inner1(arg1 Outer_inner1) { - _swig_wrap_delete_Outer_inner1(arg1.Swigcptr()) -} - -type Outer_inner1 interface { - Swigcptr() uintptr - SwigIsOuter_inner1() - SetVal(arg2 int) - GetVal() (_swig_ret int) -} - -type SwigcptrNamed uintptr - -func (p SwigcptrNamed) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrNamed) SwigIsNamed() { -} - -var _wrap_Named_val_set unsafe.Pointer - -func _swig_wrap_Named_val_set(base SwigcptrNamed, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Named_val_set, _swig_p) - return -} - -func (arg1 SwigcptrNamed) SetVal(arg2 int) { - _swig_wrap_Named_val_set(arg1, arg2) -} - -var _wrap_Named_val_get unsafe.Pointer - -func _swig_wrap_Named_val_get(base SwigcptrNamed) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Named_val_get, _swig_p) - return -} - -func (arg1 SwigcptrNamed) GetVal() (_swig_ret int) { - return _swig_wrap_Named_val_get(arg1) -} - -var _wrap_new_Named unsafe.Pointer - -func _swig_wrap_new_Named() (base SwigcptrNamed) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Named, _swig_p) - return -} - -func NewNamed() (_swig_ret Named) { - return _swig_wrap_new_Named() -} - -var _wrap_delete_Named unsafe.Pointer - -func _swig_wrap_delete_Named(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Named, _swig_p) - return -} - -func DeleteNamed(arg1 Named) { - _swig_wrap_delete_Named(arg1.Swigcptr()) -} - -type Named interface { - Swigcptr() uintptr - SwigIsNamed() - SetVal(arg2 int) - GetVal() (_swig_ret int) -} - -var _wrap_outer_set unsafe.Pointer - -func _swig_wrap_outer_set(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_outer_set, _swig_p) - return -} - -func SetOuter(arg1 Outer) { - _swig_wrap_outer_set(arg1.Swigcptr()) -} - -var _wrap_outer_get unsafe.Pointer - -func _swig_wrap_outer_get() (base SwigcptrOuter) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_outer_get, _swig_p) - return -} - -func GetOuter() (_swig_ret Outer) { - return _swig_wrap_outer_get() -} - -var _wrap_setValues unsafe.Pointer - -func _swig_wrap_setValues(base uintptr, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_setValues, _swig_p) - return -} - -func SetValues(arg1 Outer, arg2 int) { - _swig_wrap_setValues(arg1.Swigcptr(), arg2) -} - -var _wrap_getInside1Val unsafe.Pointer - -func _swig_wrap_getInside1Val(base uintptr) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_getInside1Val, _swig_p) - return -} - -func GetInside1Val(arg1 Outer) (_swig_ret int) { - return _swig_wrap_getInside1Val(arg1.Swigcptr()) -} - -var _wrap_nestedByVal unsafe.Pointer - -func _swig_wrap_nestedByVal(base uintptr) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_nestedByVal, _swig_p) - return -} - -func NestedByVal(arg1 Named) (_swig_ret int) { - return _swig_wrap_nestedByVal(arg1.Swigcptr()) -} - -var _wrap_nestedByPtr unsafe.Pointer - -func _swig_wrap_nestedByPtr(base uintptr) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_nestedByPtr, _swig_p) - return -} - -func NestedByPtr(arg1 Named) (_swig_ret int) { - return _swig_wrap_nestedByPtr(arg1.Swigcptr()) -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/nested_workaround.go b/Examples/test-suite/go/nested_workaround.go deleted file mode 100644 index 5ecffc810..000000000 --- a/Examples/test-suite/go/nested_workaround.go +++ /dev/null @@ -1,201 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../nested_workaround.i - -package nested_workaround - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrOuter uintptr - -func (p SwigcptrOuter) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrOuter) SwigIsOuter() { -} - -var _wrap_Outer_createInner unsafe.Pointer - -func _swig_wrap_Outer_createInner(base SwigcptrOuter, _ int) (_ SwigcptrInner) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Outer_createInner, _swig_p) - return -} - -func (arg1 SwigcptrOuter) CreateInner(arg2 int) (_swig_ret Inner) { - return _swig_wrap_Outer_createInner(arg1, arg2) -} - -var _wrap_Outer_getInnerValue unsafe.Pointer - -func _swig_wrap_Outer_getInnerValue(base SwigcptrOuter, _ uintptr) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Outer_getInnerValue, _swig_p) - return -} - -func (arg1 SwigcptrOuter) GetInnerValue(arg2 Inner) (_swig_ret int) { - return _swig_wrap_Outer_getInnerValue(arg1, arg2.Swigcptr()) -} - -var _wrap_Outer_doubleInnerValue unsafe.Pointer - -func _swig_wrap_Outer_doubleInnerValue(base SwigcptrOuter, _ uintptr) (_ SwigcptrInner) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Outer_doubleInnerValue, _swig_p) - return -} - -func (arg1 SwigcptrOuter) DoubleInnerValue(arg2 Inner) (_swig_ret Inner) { - return _swig_wrap_Outer_doubleInnerValue(arg1, arg2.Swigcptr()) -} - -var _wrap_new_Outer unsafe.Pointer - -func _swig_wrap_new_Outer() (base SwigcptrOuter) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Outer, _swig_p) - return -} - -func NewOuter() (_swig_ret Outer) { - return _swig_wrap_new_Outer() -} - -var _wrap_delete_Outer unsafe.Pointer - -func _swig_wrap_delete_Outer(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Outer, _swig_p) - return -} - -func DeleteOuter(arg1 Outer) { - _swig_wrap_delete_Outer(arg1.Swigcptr()) -} - -type Outer interface { - Swigcptr() uintptr - SwigIsOuter() - CreateInner(arg2 int) (_swig_ret Inner) - GetInnerValue(arg2 Inner) (_swig_ret int) - DoubleInnerValue(arg2 Inner) (_swig_ret Inner) -} - -type SwigcptrInner uintptr - -func (p SwigcptrInner) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrInner) SwigIsInner() { -} - -var _wrap_new_Inner__SWIG_0 unsafe.Pointer - -func _swig_wrap_new_Inner__SWIG_0(base int) (_ SwigcptrInner) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Inner__SWIG_0, _swig_p) - return -} - -func NewInner__SWIG_0(arg1 int) (_swig_ret Inner) { - return _swig_wrap_new_Inner__SWIG_0(arg1) -} - -var _wrap_new_Inner__SWIG_1 unsafe.Pointer - -func _swig_wrap_new_Inner__SWIG_1() (base SwigcptrInner) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Inner__SWIG_1, _swig_p) - return -} - -func NewInner__SWIG_1() (_swig_ret Inner) { - return _swig_wrap_new_Inner__SWIG_1() -} - -func NewInner(a ...interface{}) Inner { - argc := len(a) - if argc == 0 { - return NewInner__SWIG_1() - } - if argc == 1 { - return NewInner__SWIG_0(a[0].(int)) - } - panic("No match for overloaded function call") -} - -var _wrap_Inner_setValue unsafe.Pointer - -func _swig_wrap_Inner_setValue(base SwigcptrInner, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Inner_setValue, _swig_p) - return -} - -func (arg1 SwigcptrInner) SetValue(arg2 int) { - _swig_wrap_Inner_setValue(arg1, arg2) -} - -var _wrap_Inner_getValue unsafe.Pointer - -func _swig_wrap_Inner_getValue(base SwigcptrInner) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Inner_getValue, _swig_p) - return -} - -func (arg1 SwigcptrInner) GetValue() (_swig_ret int) { - return _swig_wrap_Inner_getValue(arg1) -} - -var _wrap_delete_Inner unsafe.Pointer - -func _swig_wrap_delete_Inner(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Inner, _swig_p) - return -} - -func DeleteInner(arg1 Inner) { - _swig_wrap_delete_Inner(arg1.Swigcptr()) -} - -type Inner interface { - Swigcptr() uintptr - SwigIsInner() - SetValue(arg2 int) - GetValue() (_swig_ret int) -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/nested_workaround_runme b/Examples/test-suite/go/nested_workaround_runme deleted file mode 100755 index dcfc224c5..000000000 Binary files a/Examples/test-suite/go/nested_workaround_runme and /dev/null differ diff --git a/Examples/test-suite/go/newobject1.go b/Examples/test-suite/go/newobject1.go deleted file mode 100644 index 71faa6c51..000000000 --- a/Examples/test-suite/go/newobject1.go +++ /dev/null @@ -1,95 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../newobject1.i - -package newobject1 - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrFoo uintptr - -func (p SwigcptrFoo) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrFoo) SwigIsFoo() { -} - -var _wrap_Foo_makeFoo unsafe.Pointer - -func _swig_wrap_Foo_makeFoo() (base SwigcptrFoo) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_makeFoo, _swig_p) - return -} - -func FooMakeFoo() (_swig_ret Foo) { - return _swig_wrap_Foo_makeFoo() -} - -var _wrap_Foo_makeMore unsafe.Pointer - -func _swig_wrap_Foo_makeMore(base SwigcptrFoo) (_ SwigcptrFoo) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_makeMore, _swig_p) - return -} - -func (arg1 SwigcptrFoo) MakeMore() (_swig_ret Foo) { - return _swig_wrap_Foo_makeMore(arg1) -} - -var _wrap_Foo_fooCount unsafe.Pointer - -func FooFooCount() (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_Foo_fooCount, _swig_p) - return -} -var _wrap_delete_Foo unsafe.Pointer - -func _swig_wrap_delete_Foo(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Foo, _swig_p) - return -} - -func DeleteFoo(arg1 Foo) { - _swig_wrap_delete_Foo(arg1.Swigcptr()) -} - -type Foo interface { - Swigcptr() uintptr - SwigIsFoo() - MakeMore() (_swig_ret Foo) -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/newobject2.go b/Examples/test-suite/go/newobject2.go deleted file mode 100644 index d8d38c76d..000000000 --- a/Examples/test-suite/go/newobject2.go +++ /dev/null @@ -1,132 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../newobject2.i - -package newobject2 - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrFoo uintptr - -func (p SwigcptrFoo) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrFoo) SwigIsFoo() { -} - -var _wrap_Foo_dummy_set unsafe.Pointer - -func _swig_wrap_Foo_dummy_set(base SwigcptrFoo, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_dummy_set, _swig_p) - return -} - -func (arg1 SwigcptrFoo) SetDummy(arg2 int) { - _swig_wrap_Foo_dummy_set(arg1, arg2) -} - -var _wrap_Foo_dummy_get unsafe.Pointer - -func _swig_wrap_Foo_dummy_get(base SwigcptrFoo) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_dummy_get, _swig_p) - return -} - -func (arg1 SwigcptrFoo) GetDummy() (_swig_ret int) { - return _swig_wrap_Foo_dummy_get(arg1) -} - -var _wrap_delete_Foo unsafe.Pointer - -func _swig_wrap_delete_Foo(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Foo, _swig_p) - return -} - -func DeleteFoo(arg1 Foo) { - _swig_wrap_delete_Foo(arg1.Swigcptr()) -} - -var _wrap_new_Foo unsafe.Pointer - -func _swig_wrap_new_Foo() (base SwigcptrFoo) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Foo, _swig_p) - return -} - -func NewFoo() (_swig_ret Foo) { - return _swig_wrap_new_Foo() -} - -type Foo interface { - Swigcptr() uintptr - SwigIsFoo() - SetDummy(arg2 int) - GetDummy() (_swig_ret int) -} - -var _wrap_makeFoo unsafe.Pointer - -func _swig_wrap_makeFoo() (base SwigcptrFoo) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_makeFoo, _swig_p) - return -} - -func MakeFoo() (_swig_ret Foo) { - return _swig_wrap_makeFoo() -} - -var _wrap_fooCount unsafe.Pointer - -func FooCount() (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_fooCount, _swig_p) - return -} -var _wrap_do_stuff unsafe.Pointer - -func _swig_wrap_do_stuff(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_do_stuff, _swig_p) - return -} - -func Do_stuff(arg1 Foo) { - _swig_wrap_do_stuff(arg1.Swigcptr()) -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/nspace.go b/Examples/test-suite/go/nspace.go deleted file mode 100644 index 25d158c8d..000000000 --- a/Examples/test-suite/go/nspace.go +++ /dev/null @@ -1,29 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../nspace.i - -package nspace - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - - diff --git a/Examples/test-suite/go/nspace_extend.go b/Examples/test-suite/go/nspace_extend.go deleted file mode 100644 index 89ae7fb04..000000000 --- a/Examples/test-suite/go/nspace_extend.go +++ /dev/null @@ -1,29 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../nspace_extend.i - -package nspace_extend - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - - diff --git a/Examples/test-suite/go/null_pointer.go b/Examples/test-suite/go/null_pointer.go deleted file mode 100644 index 13d6a7914..000000000 --- a/Examples/test-suite/go/null_pointer.go +++ /dev/null @@ -1,99 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../null_pointer.i - -package null_pointer - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrA uintptr - -func (p SwigcptrA) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrA) SwigIsA() { -} - -var _wrap_new_A unsafe.Pointer - -func _swig_wrap_new_A() (base SwigcptrA) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_A, _swig_p) - return -} - -func NewA() (_swig_ret A) { - return _swig_wrap_new_A() -} - -var _wrap_delete_A unsafe.Pointer - -func _swig_wrap_delete_A(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_A, _swig_p) - return -} - -func DeleteA(arg1 A) { - _swig_wrap_delete_A(arg1.Swigcptr()) -} - -type A interface { - Swigcptr() uintptr - SwigIsA() -} - -var _wrap_Xfunc unsafe.Pointer - -func _swig_wrap_Xfunc(base uintptr) (_ bool) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Xfunc, _swig_p) - return -} - -func Xfunc(arg1 A) (_swig_ret bool) { - return _swig_wrap_Xfunc(arg1.Swigcptr()) -} - -var _wrap_getnull unsafe.Pointer - -func _swig_wrap_getnull() (base SwigcptrA) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_getnull, _swig_p) - return -} - -func Getnull() (_swig_ret A) { - return _swig_wrap_getnull() -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/operator_overload.go b/Examples/test-suite/go/operator_overload.go deleted file mode 100644 index 1ce96277d..000000000 --- a/Examples/test-suite/go/operator_overload.go +++ /dev/null @@ -1,1152 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../operator_overload.i - -package operator_overload - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrOp uintptr - -func (p SwigcptrOp) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrOp) SwigIsOp() { -} - -var _wrap_Op_i_set unsafe.Pointer - -func _swig_wrap_Op_i_set(base SwigcptrOp, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Op_i_set, _swig_p) - return -} - -func (arg1 SwigcptrOp) SetI(arg2 int) { - _swig_wrap_Op_i_set(arg1, arg2) -} - -var _wrap_Op_i_get unsafe.Pointer - -func _swig_wrap_Op_i_get(base SwigcptrOp) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Op_i_get, _swig_p) - return -} - -func (arg1 SwigcptrOp) GetI() (_swig_ret int) { - return _swig_wrap_Op_i_get(arg1) -} - -var _wrap_new_Op__SWIG_0 unsafe.Pointer - -func _swig_wrap_new_Op__SWIG_0(base int) (_ SwigcptrOp) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Op__SWIG_0, _swig_p) - return -} - -func NewOp__SWIG_0(arg1 int) (_swig_ret Op) { - return _swig_wrap_new_Op__SWIG_0(arg1) -} - -var _wrap_new_Op__SWIG_1 unsafe.Pointer - -func _swig_wrap_new_Op__SWIG_1() (base SwigcptrOp) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Op__SWIG_1, _swig_p) - return -} - -func NewOp__SWIG_1() (_swig_ret Op) { - return _swig_wrap_new_Op__SWIG_1() -} - -var _wrap_new_Op__SWIG_2 unsafe.Pointer - -func _swig_wrap_new_Op__SWIG_2(base uintptr) (_ SwigcptrOp) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Op__SWIG_2, _swig_p) - return -} - -func NewOp__SWIG_2(arg1 Op) (_swig_ret Op) { - return _swig_wrap_new_Op__SWIG_2(arg1.Swigcptr()) -} - -func NewOp(a ...interface{}) Op { - argc := len(a) - if argc == 0 { - return NewOp__SWIG_1() - } - if argc == 1 { - if _, ok := a[0].(Op); !ok { - goto check_2 - } - return NewOp__SWIG_2(a[0].(Op)) - } -check_2: - if argc == 1 { - return NewOp__SWIG_0(a[0].(int)) - } - panic("No match for overloaded function call") -} - -var _wrap_delete_Op unsafe.Pointer - -func _swig_wrap_delete_Op(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Op, _swig_p) - return -} - -func DeleteOp(arg1 Op) { - _swig_wrap_delete_Op(arg1.Swigcptr()) -} - -var _wrap_And unsafe.Pointer - -func _swig_wrap_And(base uintptr, _ uintptr) (_ SwigcptrOp) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_And, _swig_p) - return -} - -func And(arg1 Op, arg2 Op) (_swig_ret Op) { - return _swig_wrap_And(arg1.Swigcptr(), arg2.Swigcptr()) -} - -var _wrap_Or unsafe.Pointer - -func _swig_wrap_Or(base uintptr, _ uintptr) (_ SwigcptrOp) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Or, _swig_p) - return -} - -func Or(arg1 Op, arg2 Op) (_swig_ret Op) { - return _swig_wrap_Or(arg1.Swigcptr(), arg2.Swigcptr()) -} - -var _wrap_Op_Equal unsafe.Pointer - -func _swig_wrap_Op_Equal(base SwigcptrOp, _ uintptr) (_ SwigcptrOp) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Op_Equal, _swig_p) - return -} - -func (arg1 SwigcptrOp) Equal(arg2 Op) (_swig_ret Op) { - return _swig_wrap_Op_Equal(arg1, arg2.Swigcptr()) -} - -var _wrap_Op_PlusEqual unsafe.Pointer - -func _swig_wrap_Op_PlusEqual(base SwigcptrOp, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Op_PlusEqual, _swig_p) - return -} - -func (arg1 SwigcptrOp) PlusEqual(arg2 Op) { - _swig_wrap_Op_PlusEqual(arg1, arg2.Swigcptr()) -} - -var _wrap_Op_MinusEqual unsafe.Pointer - -func _swig_wrap_Op_MinusEqual(base SwigcptrOp, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Op_MinusEqual, _swig_p) - return -} - -func (arg1 SwigcptrOp) MinusEqual(arg2 Op) { - _swig_wrap_Op_MinusEqual(arg1, arg2.Swigcptr()) -} - -var _wrap_Op_MultiplyEqual unsafe.Pointer - -func _swig_wrap_Op_MultiplyEqual(base SwigcptrOp, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Op_MultiplyEqual, _swig_p) - return -} - -func (arg1 SwigcptrOp) MultiplyEqual(arg2 Op) { - _swig_wrap_Op_MultiplyEqual(arg1, arg2.Swigcptr()) -} - -var _wrap_Op_DivideEqual unsafe.Pointer - -func _swig_wrap_Op_DivideEqual(base SwigcptrOp, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Op_DivideEqual, _swig_p) - return -} - -func (arg1 SwigcptrOp) DivideEqual(arg2 Op) { - _swig_wrap_Op_DivideEqual(arg1, arg2.Swigcptr()) -} - -var _wrap_Op_PercentEqual unsafe.Pointer - -func _swig_wrap_Op_PercentEqual(base SwigcptrOp, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Op_PercentEqual, _swig_p) - return -} - -func (arg1 SwigcptrOp) PercentEqual(arg2 Op) { - _swig_wrap_Op_PercentEqual(arg1, arg2.Swigcptr()) -} - -var _wrap_Plus unsafe.Pointer - -func _swig_wrap_Plus(base uintptr, _ uintptr) (_ SwigcptrOp) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Plus, _swig_p) - return -} - -func Plus(arg1 Op, arg2 Op) (_swig_ret Op) { - return _swig_wrap_Plus(arg1.Swigcptr(), arg2.Swigcptr()) -} - -var _wrap_Minus unsafe.Pointer - -func _swig_wrap_Minus(base uintptr, _ uintptr) (_ SwigcptrOp) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Minus, _swig_p) - return -} - -func Minus(arg1 Op, arg2 Op) (_swig_ret Op) { - return _swig_wrap_Minus(arg1.Swigcptr(), arg2.Swigcptr()) -} - -var _wrap_Multiply unsafe.Pointer - -func _swig_wrap_Multiply(base uintptr, _ uintptr) (_ SwigcptrOp) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Multiply, _swig_p) - return -} - -func Multiply(arg1 Op, arg2 Op) (_swig_ret Op) { - return _swig_wrap_Multiply(arg1.Swigcptr(), arg2.Swigcptr()) -} - -var _wrap_Divide unsafe.Pointer - -func _swig_wrap_Divide(base uintptr, _ uintptr) (_ SwigcptrOp) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Divide, _swig_p) - return -} - -func Divide(arg1 Op, arg2 Op) (_swig_ret Op) { - return _swig_wrap_Divide(arg1.Swigcptr(), arg2.Swigcptr()) -} - -var _wrap_Percent unsafe.Pointer - -func _swig_wrap_Percent(base uintptr, _ uintptr) (_ SwigcptrOp) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Percent, _swig_p) - return -} - -func Percent(arg1 Op, arg2 Op) (_swig_ret Op) { - return _swig_wrap_Percent(arg1.Swigcptr(), arg2.Swigcptr()) -} - -var _wrap_Op_Minus__SWIG_0 unsafe.Pointer - -func _swig_wrap_Op_Minus__SWIG_0(base SwigcptrOp) (_ SwigcptrOp) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Op_Minus__SWIG_0, _swig_p) - return -} - -func (arg1 SwigcptrOp) Minus__SWIG_0() (_swig_ret Op) { - return _swig_wrap_Op_Minus__SWIG_0(arg1) -} - -var _wrap_Op_Not unsafe.Pointer - -func _swig_wrap_Op_Not(base SwigcptrOp) (_ bool) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Op_Not, _swig_p) - return -} - -func (arg1 SwigcptrOp) Not() (_swig_ret bool) { - return _swig_wrap_Op_Not(arg1) -} - -var _wrap_Op_IndexIntoConst unsafe.Pointer - -func _swig_wrap_Op_IndexIntoConst(base SwigcptrOp, _ uint) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Op_IndexIntoConst, _swig_p) - return -} - -func (arg1 SwigcptrOp) IndexIntoConst(arg2 uint) (_swig_ret int) { - return _swig_wrap_Op_IndexIntoConst(arg1, arg2) -} - -var _wrap_Op_IndexInto unsafe.Pointer - -func _swig_wrap_Op_IndexInto(base SwigcptrOp, _ uint) (_ *int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Op_IndexInto, _swig_p) - return -} - -func (arg1 SwigcptrOp) IndexInto(arg2 uint) (_swig_ret *int) { - return _swig_wrap_Op_IndexInto(arg1, arg2) -} - -var _wrap_Op_Functor__SWIG_0 unsafe.Pointer - -func _swig_wrap_Op_Functor__SWIG_0(base SwigcptrOp, _ int) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Op_Functor__SWIG_0, _swig_p) - return -} - -func (arg1 SwigcptrOp) Functor__SWIG_0(arg2 int) (_swig_ret int) { - return _swig_wrap_Op_Functor__SWIG_0(arg1, arg2) -} - -var _wrap_Op_Functor__SWIG_1 unsafe.Pointer - -func _swig_wrap_Op_Functor__SWIG_1(base SwigcptrOp) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Op_Functor__SWIG_1, _swig_p) - return -} - -func (arg1 SwigcptrOp) Functor__SWIG_1() (_swig_ret int) { - return _swig_wrap_Op_Functor__SWIG_1(arg1) -} - -var _wrap_Op_Functor__SWIG_2 unsafe.Pointer - -func _swig_wrap_Op_Functor__SWIG_2(base SwigcptrOp, _ int, _ int) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Op_Functor__SWIG_2, _swig_p) - return -} - -func (arg1 SwigcptrOp) Functor__SWIG_2(arg2 int, arg3 int) (_swig_ret int) { - return _swig_wrap_Op_Functor__SWIG_2(arg1, arg2, arg3) -} - -func (p SwigcptrOp) Functor(a ...interface{}) int { - argc := len(a) - if argc == 0 { - return p.Functor__SWIG_1() - } - if argc == 1 { - return p.Functor__SWIG_0(a[0].(int)) - } - if argc == 2 { - return p.Functor__SWIG_2(a[0].(int), a[1].(int)) - } - panic("No match for overloaded function call") -} - -var _wrap_Op_PlusPlusPrefix unsafe.Pointer - -func _swig_wrap_Op_PlusPlusPrefix(base SwigcptrOp) (_ SwigcptrOp) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Op_PlusPlusPrefix, _swig_p) - return -} - -func (arg1 SwigcptrOp) PlusPlusPrefix() (_swig_ret Op) { - return _swig_wrap_Op_PlusPlusPrefix(arg1) -} - -var _wrap_Op_PlusPlusPostfix unsafe.Pointer - -func _swig_wrap_Op_PlusPlusPostfix(base SwigcptrOp, _ int) (_ SwigcptrOp) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Op_PlusPlusPostfix, _swig_p) - return -} - -func (arg1 SwigcptrOp) PlusPlusPostfix(arg2 int) (_swig_ret Op) { - return _swig_wrap_Op_PlusPlusPostfix(arg1, arg2) -} - -var _wrap_Op_MinusMinusPrefix unsafe.Pointer - -func _swig_wrap_Op_MinusMinusPrefix(base SwigcptrOp) (_ SwigcptrOp) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Op_MinusMinusPrefix, _swig_p) - return -} - -func (arg1 SwigcptrOp) MinusMinusPrefix() (_swig_ret Op) { - return _swig_wrap_Op_MinusMinusPrefix(arg1) -} - -var _wrap_Op_MinusMinusPostfix unsafe.Pointer - -func _swig_wrap_Op_MinusMinusPostfix(base SwigcptrOp, _ int) (_ SwigcptrOp) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Op_MinusMinusPostfix, _swig_p) - return -} - -func (arg1 SwigcptrOp) MinusMinusPostfix(arg2 int) (_swig_ret Op) { - return _swig_wrap_Op_MinusMinusPostfix(arg1, arg2) -} - -var _wrap_Op_DoubleCast unsafe.Pointer - -func _swig_wrap_Op_DoubleCast(base SwigcptrOp) (_ float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Op_DoubleCast, _swig_p) - return -} - -func (arg1 SwigcptrOp) DoubleCast() (_swig_ret float64) { - return _swig_wrap_Op_DoubleCast(arg1) -} - -var _wrap_Op_IntCast unsafe.Pointer - -func _swig_wrap_Op_IntCast(base SwigcptrOp) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Op_IntCast, _swig_p) - return -} - -func (arg1 SwigcptrOp) IntCast() (_swig_ret int) { - return _swig_wrap_Op_IntCast(arg1) -} - -var _wrap_Op_sanity_check unsafe.Pointer - -func _swig_wrap_Op_sanity_check() { - var _swig_p uintptr - _cgo_runtime_cgocall(_wrap_Op_sanity_check, _swig_p) - return -} - -func OpSanity_check() { - _swig_wrap_Op_sanity_check() -} - -var _wrap_Op_And unsafe.Pointer - -func _swig_wrap_Op_And(base SwigcptrOp, _ uintptr) (_ SwigcptrOp) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Op_And, _swig_p) - return -} - -func (arg1 SwigcptrOp) And(arg2 Op) (_swig_ret Op) { - return _swig_wrap_Op_And(arg1, arg2.Swigcptr()) -} - -var _wrap_Op_Or unsafe.Pointer - -func _swig_wrap_Op_Or(base SwigcptrOp, _ uintptr) (_ SwigcptrOp) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Op_Or, _swig_p) - return -} - -func (arg1 SwigcptrOp) Or(arg2 Op) (_swig_ret Op) { - return _swig_wrap_Op_Or(arg1, arg2.Swigcptr()) -} - -var _wrap_Op_Plus unsafe.Pointer - -func _swig_wrap_Op_Plus(base SwigcptrOp, _ uintptr) (_ SwigcptrOp) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Op_Plus, _swig_p) - return -} - -func (arg1 SwigcptrOp) Plus(arg2 Op) (_swig_ret Op) { - return _swig_wrap_Op_Plus(arg1, arg2.Swigcptr()) -} - -var _wrap_Op_Minus__SWIG_1 unsafe.Pointer - -func _swig_wrap_Op_Minus__SWIG_1(base SwigcptrOp, _ uintptr) (_ SwigcptrOp) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Op_Minus__SWIG_1, _swig_p) - return -} - -func (arg1 SwigcptrOp) Minus__SWIG_1(arg2 Op) (_swig_ret Op) { - return _swig_wrap_Op_Minus__SWIG_1(arg1, arg2.Swigcptr()) -} - -func (p SwigcptrOp) Minus(a ...interface{}) Op { - argc := len(a) - if argc == 0 { - return p.Minus__SWIG_0() - } - if argc == 1 { - return p.Minus__SWIG_1(a[0].(Op)) - } - panic("No match for overloaded function call") -} - -var _wrap_Op_Multiply unsafe.Pointer - -func _swig_wrap_Op_Multiply(base SwigcptrOp, _ uintptr) (_ SwigcptrOp) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Op_Multiply, _swig_p) - return -} - -func (arg1 SwigcptrOp) Multiply(arg2 Op) (_swig_ret Op) { - return _swig_wrap_Op_Multiply(arg1, arg2.Swigcptr()) -} - -var _wrap_Op_Divide unsafe.Pointer - -func _swig_wrap_Op_Divide(base SwigcptrOp, _ uintptr) (_ SwigcptrOp) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Op_Divide, _swig_p) - return -} - -func (arg1 SwigcptrOp) Divide(arg2 Op) (_swig_ret Op) { - return _swig_wrap_Op_Divide(arg1, arg2.Swigcptr()) -} - -var _wrap_Op_Percent unsafe.Pointer - -func _swig_wrap_Op_Percent(base SwigcptrOp, _ uintptr) (_ SwigcptrOp) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Op_Percent, _swig_p) - return -} - -func (arg1 SwigcptrOp) Percent(arg2 Op) (_swig_ret Op) { - return _swig_wrap_Op_Percent(arg1, arg2.Swigcptr()) -} - -var _wrap_Op_EqualEqual unsafe.Pointer - -func _swig_wrap_Op_EqualEqual(base SwigcptrOp, _ uintptr) (_ bool) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Op_EqualEqual, _swig_p) - return -} - -func (arg1 SwigcptrOp) EqualEqual(arg2 Op) (_swig_ret bool) { - return _swig_wrap_Op_EqualEqual(arg1, arg2.Swigcptr()) -} - -var _wrap_Op_NotEqual unsafe.Pointer - -func _swig_wrap_Op_NotEqual(base SwigcptrOp, _ uintptr) (_ bool) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Op_NotEqual, _swig_p) - return -} - -func (arg1 SwigcptrOp) NotEqual(arg2 Op) (_swig_ret bool) { - return _swig_wrap_Op_NotEqual(arg1, arg2.Swigcptr()) -} - -var _wrap_Op_LessThan unsafe.Pointer - -func _swig_wrap_Op_LessThan(base SwigcptrOp, _ uintptr) (_ bool) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Op_LessThan, _swig_p) - return -} - -func (arg1 SwigcptrOp) LessThan(arg2 Op) (_swig_ret bool) { - return _swig_wrap_Op_LessThan(arg1, arg2.Swigcptr()) -} - -var _wrap_Op_LessThanEqual unsafe.Pointer - -func _swig_wrap_Op_LessThanEqual(base SwigcptrOp, _ uintptr) (_ bool) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Op_LessThanEqual, _swig_p) - return -} - -func (arg1 SwigcptrOp) LessThanEqual(arg2 Op) (_swig_ret bool) { - return _swig_wrap_Op_LessThanEqual(arg1, arg2.Swigcptr()) -} - -var _wrap_Op_GreaterThan unsafe.Pointer - -func _swig_wrap_Op_GreaterThan(base SwigcptrOp, _ uintptr) (_ bool) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Op_GreaterThan, _swig_p) - return -} - -func (arg1 SwigcptrOp) GreaterThan(arg2 Op) (_swig_ret bool) { - return _swig_wrap_Op_GreaterThan(arg1, arg2.Swigcptr()) -} - -var _wrap_Op_GreaterThanEqual unsafe.Pointer - -func _swig_wrap_Op_GreaterThanEqual(base SwigcptrOp, _ uintptr) (_ bool) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Op_GreaterThanEqual, _swig_p) - return -} - -func (arg1 SwigcptrOp) GreaterThanEqual(arg2 Op) (_swig_ret bool) { - return _swig_wrap_Op_GreaterThanEqual(arg1, arg2.Swigcptr()) -} - -var _wrap_Op___rsub__ unsafe.Pointer - -func _swig_wrap_Op___rsub__(base SwigcptrOp, _ int) (_ SwigcptrOp) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Op___rsub__, _swig_p) - return -} - -func (arg1 SwigcptrOp) X__rsub__(arg2 int) (_swig_ret Op) { - return _swig_wrap_Op___rsub__(arg1, arg2) -} - -var _wrap_Op___str__ unsafe.Pointer - -func _swig_wrap_Op___str__(base SwigcptrOp) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Op___str__, _swig_p) - return -} - -func (arg1 SwigcptrOp) X__str__() (_swig_ret string) { - return _swig_wrap_Op___str__(arg1) -} - -var _wrap_Op___getitem__ unsafe.Pointer - -func _swig_wrap_Op___getitem__(base SwigcptrOp, _ uint) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Op___getitem__, _swig_p) - return -} - -func (arg1 SwigcptrOp) X__getitem__(arg2 uint) (_swig_ret int) { - return _swig_wrap_Op___getitem__(arg1, arg2) -} - -var _wrap_Op___setitem__ unsafe.Pointer - -func _swig_wrap_Op___setitem__(base SwigcptrOp, _ uint, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Op___setitem__, _swig_p) - return -} - -func (arg1 SwigcptrOp) X__setitem__(arg2 uint, arg3 int) { - _swig_wrap_Op___setitem__(arg1, arg2, arg3) -} - -type Op interface { - Swigcptr() uintptr - SwigIsOp() - SetI(arg2 int) - GetI() (_swig_ret int) - Equal(arg2 Op) (_swig_ret Op) - PlusEqual(arg2 Op) - MinusEqual(arg2 Op) - MultiplyEqual(arg2 Op) - DivideEqual(arg2 Op) - PercentEqual(arg2 Op) - Not() (_swig_ret bool) - IndexIntoConst(arg2 uint) (_swig_ret int) - IndexInto(arg2 uint) (_swig_ret *int) - Functor(a ...interface{}) int - PlusPlusPrefix() (_swig_ret Op) - PlusPlusPostfix(arg2 int) (_swig_ret Op) - MinusMinusPrefix() (_swig_ret Op) - MinusMinusPostfix(arg2 int) (_swig_ret Op) - DoubleCast() (_swig_ret float64) - IntCast() (_swig_ret int) - And(arg2 Op) (_swig_ret Op) - Or(arg2 Op) (_swig_ret Op) - Plus(arg2 Op) (_swig_ret Op) - Minus(a ...interface{}) Op - Multiply(arg2 Op) (_swig_ret Op) - Divide(arg2 Op) (_swig_ret Op) - Percent(arg2 Op) (_swig_ret Op) - EqualEqual(arg2 Op) (_swig_ret bool) - NotEqual(arg2 Op) (_swig_ret bool) - LessThan(arg2 Op) (_swig_ret bool) - LessThanEqual(arg2 Op) (_swig_ret bool) - GreaterThan(arg2 Op) (_swig_ret bool) - GreaterThanEqual(arg2 Op) (_swig_ret bool) - X__rsub__(arg2 int) (_swig_ret Op) - X__str__() (_swig_ret string) - X__getitem__(arg2 uint) (_swig_ret int) - X__setitem__(arg2 uint, arg3 int) -} - -var _wrap_EqualEqual unsafe.Pointer - -func _swig_wrap_EqualEqual(base uintptr, _ uintptr) (_ bool) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_EqualEqual, _swig_p) - return -} - -func EqualEqual(arg1 Op, arg2 Op) (_swig_ret bool) { - return _swig_wrap_EqualEqual(arg1.Swigcptr(), arg2.Swigcptr()) -} - -var _wrap_NotEqual unsafe.Pointer - -func _swig_wrap_NotEqual(base uintptr, _ uintptr) (_ bool) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_NotEqual, _swig_p) - return -} - -func NotEqual(arg1 Op, arg2 Op) (_swig_ret bool) { - return _swig_wrap_NotEqual(arg1.Swigcptr(), arg2.Swigcptr()) -} - -var _wrap_LessThan unsafe.Pointer - -func _swig_wrap_LessThan(base uintptr, _ uintptr) (_ bool) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_LessThan, _swig_p) - return -} - -func LessThan(arg1 Op, arg2 Op) (_swig_ret bool) { - return _swig_wrap_LessThan(arg1.Swigcptr(), arg2.Swigcptr()) -} - -var _wrap_LessThanEqual unsafe.Pointer - -func _swig_wrap_LessThanEqual(base uintptr, _ uintptr) (_ bool) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_LessThanEqual, _swig_p) - return -} - -func LessThanEqual(arg1 Op, arg2 Op) (_swig_ret bool) { - return _swig_wrap_LessThanEqual(arg1.Swigcptr(), arg2.Swigcptr()) -} - -var _wrap_GreaterThan unsafe.Pointer - -func _swig_wrap_GreaterThan(base uintptr, _ uintptr) (_ bool) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_GreaterThan, _swig_p) - return -} - -func GreaterThan(arg1 Op, arg2 Op) (_swig_ret bool) { - return _swig_wrap_GreaterThan(arg1.Swigcptr(), arg2.Swigcptr()) -} - -var _wrap_GreaterThanEqual unsafe.Pointer - -func _swig_wrap_GreaterThanEqual(base uintptr, _ uintptr) (_ bool) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_GreaterThanEqual, _swig_p) - return -} - -func GreaterThanEqual(arg1 Op, arg2 Op) (_swig_ret bool) { - return _swig_wrap_GreaterThanEqual(arg1.Swigcptr(), arg2.Swigcptr()) -} - -type SwigcptrOpDerived uintptr - -func (p SwigcptrOpDerived) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrOpDerived) SwigIsOpDerived() { -} - -var _wrap_new_OpDerived__SWIG_0 unsafe.Pointer - -func _swig_wrap_new_OpDerived__SWIG_0(base int) (_ SwigcptrOpDerived) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_OpDerived__SWIG_0, _swig_p) - return -} - -func NewOpDerived__SWIG_0(arg1 int) (_swig_ret OpDerived) { - return _swig_wrap_new_OpDerived__SWIG_0(arg1) -} - -var _wrap_new_OpDerived__SWIG_1 unsafe.Pointer - -func _swig_wrap_new_OpDerived__SWIG_1() (base SwigcptrOpDerived) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_OpDerived__SWIG_1, _swig_p) - return -} - -func NewOpDerived__SWIG_1() (_swig_ret OpDerived) { - return _swig_wrap_new_OpDerived__SWIG_1() -} - -func NewOpDerived(a ...interface{}) OpDerived { - argc := len(a) - if argc == 0 { - return NewOpDerived__SWIG_1() - } - if argc == 1 { - return NewOpDerived__SWIG_0(a[0].(int)) - } - panic("No match for overloaded function call") -} - -var _wrap_OpDerived_IntCast unsafe.Pointer - -func _swig_wrap_OpDerived_IntCast(base SwigcptrOpDerived) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_OpDerived_IntCast, _swig_p) - return -} - -func (arg1 SwigcptrOpDerived) IntCast() (_swig_ret int) { - return _swig_wrap_OpDerived_IntCast(arg1) -} - -var _wrap_delete_OpDerived unsafe.Pointer - -func _swig_wrap_delete_OpDerived(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_OpDerived, _swig_p) - return -} - -func DeleteOpDerived(arg1 OpDerived) { - _swig_wrap_delete_OpDerived(arg1.Swigcptr()) -} - -var _wrap_SetOpDerived_I unsafe.Pointer - -func _swig_wrap_SetOpDerived_I(base SwigcptrOpDerived, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_SetOpDerived_I, _swig_p) - return -} - -func (_swig_base SwigcptrOpDerived) SetI(arg1 int) { - _swig_wrap_SetOpDerived_I(_swig_base, arg1) -} - -var _wrap_GetOpDerived_I unsafe.Pointer - -func _swig_wrap_GetOpDerived_I(base SwigcptrOpDerived) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_GetOpDerived_I, _swig_p) - return -} - -func (_swig_base SwigcptrOpDerived) GetI() (_swig_ret int) { - return _swig_wrap_GetOpDerived_I(_swig_base) -} - -var _wrap_OpDerived_Equal unsafe.Pointer - -func _swig_wrap_OpDerived_Equal(base SwigcptrOpDerived, _ uintptr) (_ SwigcptrOp) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_OpDerived_Equal, _swig_p) - return -} - -func (_swig_base SwigcptrOpDerived) Equal(arg1 Op) (_swig_ret Op) { - return _swig_wrap_OpDerived_Equal(_swig_base, arg1.Swigcptr()) -} - -var _wrap_OpDerived_PlusEqual unsafe.Pointer - -func _swig_wrap_OpDerived_PlusEqual(base SwigcptrOpDerived, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_OpDerived_PlusEqual, _swig_p) - return -} - -func (_swig_base SwigcptrOpDerived) PlusEqual(arg1 Op) { - _swig_wrap_OpDerived_PlusEqual(_swig_base, arg1.Swigcptr()) -} - -var _wrap_OpDerived_MinusEqual unsafe.Pointer - -func _swig_wrap_OpDerived_MinusEqual(base SwigcptrOpDerived, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_OpDerived_MinusEqual, _swig_p) - return -} - -func (_swig_base SwigcptrOpDerived) MinusEqual(arg1 Op) { - _swig_wrap_OpDerived_MinusEqual(_swig_base, arg1.Swigcptr()) -} - -var _wrap_OpDerived_MultiplyEqual unsafe.Pointer - -func _swig_wrap_OpDerived_MultiplyEqual(base SwigcptrOpDerived, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_OpDerived_MultiplyEqual, _swig_p) - return -} - -func (_swig_base SwigcptrOpDerived) MultiplyEqual(arg1 Op) { - _swig_wrap_OpDerived_MultiplyEqual(_swig_base, arg1.Swigcptr()) -} - -var _wrap_OpDerived_DivideEqual unsafe.Pointer - -func _swig_wrap_OpDerived_DivideEqual(base SwigcptrOpDerived, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_OpDerived_DivideEqual, _swig_p) - return -} - -func (_swig_base SwigcptrOpDerived) DivideEqual(arg1 Op) { - _swig_wrap_OpDerived_DivideEqual(_swig_base, arg1.Swigcptr()) -} - -var _wrap_OpDerived_PercentEqual unsafe.Pointer - -func _swig_wrap_OpDerived_PercentEqual(base SwigcptrOpDerived, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_OpDerived_PercentEqual, _swig_p) - return -} - -func (_swig_base SwigcptrOpDerived) PercentEqual(arg1 Op) { - _swig_wrap_OpDerived_PercentEqual(_swig_base, arg1.Swigcptr()) -} - -var _wrap_OpDerived_Minus__SWIG_0 unsafe.Pointer - -func _swig_wrap_OpDerived_Minus__SWIG_0(base SwigcptrOpDerived) (_ SwigcptrOp) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_OpDerived_Minus__SWIG_0, _swig_p) - return -} - -func (_swig_base SwigcptrOpDerived) Minus__SWIG_0() (_swig_ret Op) { - return _swig_wrap_OpDerived_Minus__SWIG_0(_swig_base) -} - -var _wrap_OpDerived_Minus__SWIG_1 unsafe.Pointer - -func _swig_wrap_OpDerived_Minus__SWIG_1(base SwigcptrOpDerived, _ uintptr) (_ SwigcptrOp) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_OpDerived_Minus__SWIG_1, _swig_p) - return -} - -func (_swig_base SwigcptrOpDerived) Minus__SWIG_1(arg1 Op) (_swig_ret Op) { - return _swig_wrap_OpDerived_Minus__SWIG_1(_swig_base, arg1.Swigcptr()) -} - -func (p SwigcptrOpDerived) Minus(a ...interface{}) Op { - argc := len(a) - if argc == 0 { - return p.Minus__SWIG_0() - } - if argc == 1 { - return p.Minus__SWIG_1(a[0].(Op)) - } - panic("No match for overloaded function call") -} - -var _wrap_OpDerived_Not unsafe.Pointer - -func _swig_wrap_OpDerived_Not(base SwigcptrOpDerived) (_ bool) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_OpDerived_Not, _swig_p) - return -} - -func (_swig_base SwigcptrOpDerived) Not() (_swig_ret bool) { - return _swig_wrap_OpDerived_Not(_swig_base) -} - -var _wrap_OpDerived_IndexIntoConst unsafe.Pointer - -func _swig_wrap_OpDerived_IndexIntoConst(base SwigcptrOpDerived, _ uint) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_OpDerived_IndexIntoConst, _swig_p) - return -} - -func (_swig_base SwigcptrOpDerived) IndexIntoConst(arg1 uint) (_swig_ret int) { - return _swig_wrap_OpDerived_IndexIntoConst(_swig_base, arg1) -} - -var _wrap_OpDerived_Functor__SWIG_0 unsafe.Pointer - -func _swig_wrap_OpDerived_Functor__SWIG_0(base SwigcptrOpDerived, _ int) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_OpDerived_Functor__SWIG_0, _swig_p) - return -} - -func (_swig_base SwigcptrOpDerived) Functor__SWIG_0(arg1 int) (_swig_ret int) { - return _swig_wrap_OpDerived_Functor__SWIG_0(_swig_base, arg1) -} - -var _wrap_OpDerived_Functor__SWIG_1 unsafe.Pointer - -func _swig_wrap_OpDerived_Functor__SWIG_1(base SwigcptrOpDerived) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_OpDerived_Functor__SWIG_1, _swig_p) - return -} - -func (_swig_base SwigcptrOpDerived) Functor__SWIG_1() (_swig_ret int) { - return _swig_wrap_OpDerived_Functor__SWIG_1(_swig_base) -} - -var _wrap_OpDerived_Functor__SWIG_2 unsafe.Pointer - -func _swig_wrap_OpDerived_Functor__SWIG_2(base SwigcptrOpDerived, _ int, _ int) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_OpDerived_Functor__SWIG_2, _swig_p) - return -} - -func (_swig_base SwigcptrOpDerived) Functor__SWIG_2(arg1 int, arg2 int) (_swig_ret int) { - return _swig_wrap_OpDerived_Functor__SWIG_2(_swig_base, arg1, arg2) -} - -func (p SwigcptrOpDerived) Functor(a ...interface{}) int { - argc := len(a) - if argc == 0 { - return p.Functor__SWIG_1() - } - if argc == 1 { - return p.Functor__SWIG_0(a[0].(int)) - } - if argc == 2 { - return p.Functor__SWIG_2(a[0].(int), a[1].(int)) - } - panic("No match for overloaded function call") -} - -var _wrap_OpDerived_PlusPlusPrefix unsafe.Pointer - -func _swig_wrap_OpDerived_PlusPlusPrefix(base SwigcptrOpDerived) (_ SwigcptrOp) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_OpDerived_PlusPlusPrefix, _swig_p) - return -} - -func (_swig_base SwigcptrOpDerived) PlusPlusPrefix() (_swig_ret Op) { - return _swig_wrap_OpDerived_PlusPlusPrefix(_swig_base) -} - -var _wrap_OpDerived_MinusMinusPrefix unsafe.Pointer - -func _swig_wrap_OpDerived_MinusMinusPrefix(base SwigcptrOpDerived) (_ SwigcptrOp) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_OpDerived_MinusMinusPrefix, _swig_p) - return -} - -func (_swig_base SwigcptrOpDerived) MinusMinusPrefix() (_swig_ret Op) { - return _swig_wrap_OpDerived_MinusMinusPrefix(_swig_base) -} - -var _wrap_OpDerived_DoubleCast unsafe.Pointer - -func _swig_wrap_OpDerived_DoubleCast(base SwigcptrOpDerived) (_ float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_OpDerived_DoubleCast, _swig_p) - return -} - -func (_swig_base SwigcptrOpDerived) DoubleCast() (_swig_ret float64) { - return _swig_wrap_OpDerived_DoubleCast(_swig_base) -} - -var _wrap_OpDerived_sanity_check unsafe.Pointer - -func _swig_wrap_OpDerived_sanity_check() { - var _swig_p uintptr - _cgo_runtime_cgocall(_wrap_OpDerived_sanity_check, _swig_p) - return -} - -func OpDerivedSanity_check() { - _swig_wrap_OpDerived_sanity_check() -} - -func (p SwigcptrOpDerived) SwigIsOp() { -} - -func (p SwigcptrOpDerived) SwigGetOp() Op { - return SwigcptrOp(p.Swigcptr()) -} - -type OpDerived interface { - Swigcptr() uintptr - SwigIsOpDerived() - IntCast() (_swig_ret int) - SetI(arg1 int) - GetI() (_swig_ret int) - Equal(arg1 Op) (_swig_ret Op) - PlusEqual(arg1 Op) - MinusEqual(arg1 Op) - MultiplyEqual(arg1 Op) - DivideEqual(arg1 Op) - PercentEqual(arg1 Op) - Minus(a ...interface{}) Op - Not() (_swig_ret bool) - IndexIntoConst(arg1 uint) (_swig_ret int) - Functor(a ...interface{}) int - PlusPlusPrefix() (_swig_ret Op) - MinusMinusPrefix() (_swig_ret Op) - DoubleCast() (_swig_ret float64) - SwigIsOp() - SwigGetOp() Op -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/operator_overload_break.go b/Examples/test-suite/go/operator_overload_break.go deleted file mode 100644 index 131a858dc..000000000 --- a/Examples/test-suite/go/operator_overload_break.go +++ /dev/null @@ -1,287 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../operator_overload_break.i - -package operator_overload_break - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrOp uintptr - -func (p SwigcptrOp) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrOp) SwigIsOp() { -} - -var _wrap_new_Op__SWIG_0 unsafe.Pointer - -func _swig_wrap_new_Op__SWIG_0(base int) (_ SwigcptrOp) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Op__SWIG_0, _swig_p) - return -} - -func NewOp__SWIG_0(arg1 int) (_swig_ret Op) { - return _swig_wrap_new_Op__SWIG_0(arg1) -} - -var _wrap_new_Op__SWIG_1 unsafe.Pointer - -func _swig_wrap_new_Op__SWIG_1(base uintptr) (_ SwigcptrOp) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Op__SWIG_1, _swig_p) - return -} - -func NewOp__SWIG_1(arg1 Op) (_swig_ret Op) { - return _swig_wrap_new_Op__SWIG_1(arg1.Swigcptr()) -} - -func NewOp(a ...interface{}) Op { - argc := len(a) - if argc == 1 { - if _, ok := a[0].(Op); !ok { - goto check_1 - } - return NewOp__SWIG_1(a[0].(Op)) - } -check_1: - if argc == 1 { - return NewOp__SWIG_0(a[0].(int)) - } - panic("No match for overloaded function call") -} - -var _wrap_Op_EqualEqual__SWIG_0 unsafe.Pointer - -func _swig_wrap_Op_EqualEqual__SWIG_0(base SwigcptrOp, _ uintptr) (_ bool) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Op_EqualEqual__SWIG_0, _swig_p) - return -} - -func (arg1 SwigcptrOp) EqualEqual__SWIG_0(arg2 Op) (_swig_ret bool) { - return _swig_wrap_Op_EqualEqual__SWIG_0(arg1, arg2.Swigcptr()) -} - -var _wrap_Op_EqualEqual__SWIG_1 unsafe.Pointer - -func _swig_wrap_Op_EqualEqual__SWIG_1(base SwigcptrOp, _ int) (_ bool) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Op_EqualEqual__SWIG_1, _swig_p) - return -} - -func (arg1 SwigcptrOp) EqualEqual__SWIG_1(arg2 int) (_swig_ret bool) { - return _swig_wrap_Op_EqualEqual__SWIG_1(arg1, arg2) -} - -func (p SwigcptrOp) EqualEqual(a ...interface{}) bool { - argc := len(a) - if argc == 1 { - if _, ok := a[0].(Op); !ok { - goto check_1 - } - return p.EqualEqual__SWIG_0(a[0].(Op)) - } -check_1: - if argc == 1 { - return p.EqualEqual__SWIG_1(a[0].(int)) - } - panic("No match for overloaded function call") -} - -var _wrap_Op_Plus__SWIG_0 unsafe.Pointer - -func _swig_wrap_Op_Plus__SWIG_0(base SwigcptrOp, _ uintptr) (_ SwigcptrOp) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Op_Plus__SWIG_0, _swig_p) - return -} - -func (arg1 SwigcptrOp) Plus__SWIG_0(arg2 Op) (_swig_ret Op) { - return _swig_wrap_Op_Plus__SWIG_0(arg1, arg2.Swigcptr()) -} - -var _wrap_Op_Plus__SWIG_1 unsafe.Pointer - -func _swig_wrap_Op_Plus__SWIG_1(base SwigcptrOp, _ int) (_ SwigcptrOp) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Op_Plus__SWIG_1, _swig_p) - return -} - -func (arg1 SwigcptrOp) Plus__SWIG_1(arg2 int) (_swig_ret Op) { - return _swig_wrap_Op_Plus__SWIG_1(arg1, arg2) -} - -func (p SwigcptrOp) Plus(a ...interface{}) Op { - argc := len(a) - if argc == 1 { - if _, ok := a[0].(Op); !ok { - goto check_1 - } - return p.Plus__SWIG_0(a[0].(Op)) - } -check_1: - if argc == 1 { - return p.Plus__SWIG_1(a[0].(int)) - } - panic("No match for overloaded function call") -} - -var _wrap_Op_Minus__SWIG_0 unsafe.Pointer - -func _swig_wrap_Op_Minus__SWIG_0(base SwigcptrOp, _ uintptr) (_ SwigcptrOp) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Op_Minus__SWIG_0, _swig_p) - return -} - -func (arg1 SwigcptrOp) Minus__SWIG_0(arg2 Op) (_swig_ret Op) { - return _swig_wrap_Op_Minus__SWIG_0(arg1, arg2.Swigcptr()) -} - -var _wrap_Op_Minus__SWIG_1 unsafe.Pointer - -func _swig_wrap_Op_Minus__SWIG_1(base SwigcptrOp, _ int) (_ SwigcptrOp) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Op_Minus__SWIG_1, _swig_p) - return -} - -func (arg1 SwigcptrOp) Minus__SWIG_1(arg2 int) (_swig_ret Op) { - return _swig_wrap_Op_Minus__SWIG_1(arg1, arg2) -} - -func (p SwigcptrOp) Minus(a ...interface{}) Op { - argc := len(a) - if argc == 1 { - if _, ok := a[0].(Op); !ok { - goto check_1 - } - return p.Minus__SWIG_0(a[0].(Op)) - } -check_1: - if argc == 1 { - return p.Minus__SWIG_1(a[0].(int)) - } - panic("No match for overloaded function call") -} - -var _wrap_Op___rsub__ unsafe.Pointer - -func _swig_wrap_Op___rsub__(base SwigcptrOp, _ int) (_ SwigcptrOp) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Op___rsub__, _swig_p) - return -} - -func (arg1 SwigcptrOp) X__rsub__(arg2 int) (_swig_ret Op) { - return _swig_wrap_Op___rsub__(arg1, arg2) -} - -var _wrap_Op_PlusPlusPrefix unsafe.Pointer - -func _swig_wrap_Op_PlusPlusPrefix(base SwigcptrOp) (_ SwigcptrOp) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Op_PlusPlusPrefix, _swig_p) - return -} - -func (arg1 SwigcptrOp) PlusPlusPrefix() (_swig_ret Op) { - return _swig_wrap_Op_PlusPlusPrefix(arg1) -} - -var _wrap_Op_PrintK unsafe.Pointer - -func _swig_wrap_Op_PrintK(base SwigcptrOp) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Op_PrintK, _swig_p) - return -} - -func (arg1 SwigcptrOp) PrintK() { - _swig_wrap_Op_PrintK(arg1) -} - -var _wrap_Op_k_set unsafe.Pointer - -func _swig_wrap_Op_k_set(base SwigcptrOp, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Op_k_set, _swig_p) - return -} - -func (arg1 SwigcptrOp) SetK(arg2 int) { - _swig_wrap_Op_k_set(arg1, arg2) -} - -var _wrap_Op_k_get unsafe.Pointer - -func _swig_wrap_Op_k_get(base SwigcptrOp) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Op_k_get, _swig_p) - return -} - -func (arg1 SwigcptrOp) GetK() (_swig_ret int) { - return _swig_wrap_Op_k_get(arg1) -} - -var _wrap_delete_Op unsafe.Pointer - -func _swig_wrap_delete_Op(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Op, _swig_p) - return -} - -func DeleteOp(arg1 Op) { - _swig_wrap_delete_Op(arg1.Swigcptr()) -} - -type Op interface { - Swigcptr() uintptr - SwigIsOp() - EqualEqual(a ...interface{}) bool - Plus(a ...interface{}) Op - Minus(a ...interface{}) Op - X__rsub__(arg2 int) (_swig_ret Op) - PlusPlusPrefix() (_swig_ret Op) - PrintK() - SetK(arg2 int) - GetK() (_swig_ret int) -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/operator_pointer_ref.go b/Examples/test-suite/go/operator_pointer_ref.go deleted file mode 100644 index d011bd433..000000000 --- a/Examples/test-suite/go/operator_pointer_ref.go +++ /dev/null @@ -1,111 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../operator_pointer_ref.i - -package operator_pointer_ref - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrMyClass uintptr - -func (p SwigcptrMyClass) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrMyClass) SwigIsMyClass() { -} - -var _wrap_new_MyClass__SWIG_0 unsafe.Pointer - -func _swig_wrap_new_MyClass__SWIG_0(base string) (_ SwigcptrMyClass) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_MyClass__SWIG_0, _swig_p) - return -} - -func NewMyClass__SWIG_0(arg1 string) (_swig_ret MyClass) { - return _swig_wrap_new_MyClass__SWIG_0(arg1) -} - -var _wrap_new_MyClass__SWIG_1 unsafe.Pointer - -func _swig_wrap_new_MyClass__SWIG_1() (base SwigcptrMyClass) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_MyClass__SWIG_1, _swig_p) - return -} - -func NewMyClass__SWIG_1() (_swig_ret MyClass) { - return _swig_wrap_new_MyClass__SWIG_1() -} - -func NewMyClass(a ...interface{}) MyClass { - argc := len(a) - if argc == 0 { - return NewMyClass__SWIG_1() - } - if argc == 1 { - return NewMyClass__SWIG_0(a[0].(string)) - } - panic("No match for overloaded function call") -} - -var _wrap_delete_MyClass unsafe.Pointer - -func _swig_wrap_delete_MyClass(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_MyClass, _swig_p) - return -} - -func DeleteMyClass(arg1 MyClass) { - _swig_wrap_delete_MyClass(arg1.Swigcptr()) -} - -var _wrap_MyClass_AsCharStarRef unsafe.Pointer - -func _swig_wrap_MyClass_AsCharStarRef(base SwigcptrMyClass) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_MyClass_AsCharStarRef, _swig_p) - return -} - -func (arg1 SwigcptrMyClass) AsCharStarRef() (_swig_ret string) { - return _swig_wrap_MyClass_AsCharStarRef(arg1) -} - -type MyClass interface { - Swigcptr() uintptr - SwigIsMyClass() - AsCharStarRef() (_swig_ret string) -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/operbool.go b/Examples/test-suite/go/operbool.go deleted file mode 100644 index 472f02e02..000000000 --- a/Examples/test-suite/go/operbool.go +++ /dev/null @@ -1,88 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../operbool.i - -package operbool - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrTest uintptr - -func (p SwigcptrTest) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrTest) SwigIsTest() { -} - -var _wrap_Test_operator_bool unsafe.Pointer - -func _swig_wrap_Test_operator_bool(base SwigcptrTest) (_ bool) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Test_operator_bool, _swig_p) - return -} - -func (arg1 SwigcptrTest) Operator_bool() (_swig_ret bool) { - return _swig_wrap_Test_operator_bool(arg1) -} - -var _wrap_new_Test unsafe.Pointer - -func _swig_wrap_new_Test() (base SwigcptrTest) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Test, _swig_p) - return -} - -func NewTest() (_swig_ret Test) { - return _swig_wrap_new_Test() -} - -var _wrap_delete_Test unsafe.Pointer - -func _swig_wrap_delete_Test(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Test, _swig_p) - return -} - -func DeleteTest(arg1 Test) { - _swig_wrap_delete_Test(arg1.Swigcptr()) -} - -type Test interface { - Swigcptr() uintptr - SwigIsTest() - Operator_bool() (_swig_ret bool) -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/ordering.go b/Examples/test-suite/go/ordering.go deleted file mode 100644 index 94a821508..000000000 --- a/Examples/test-suite/go/ordering.go +++ /dev/null @@ -1,101 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../ordering.i - -package ordering - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrKlass uintptr - -func (p SwigcptrKlass) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrKlass) SwigIsKlass() { -} - -var _wrap_Klass_variable_set unsafe.Pointer - -func _swig_wrap_Klass_variable_set(base SwigcptrKlass, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Klass_variable_set, _swig_p) - return -} - -func (arg1 SwigcptrKlass) SetVariable(arg2 int) { - _swig_wrap_Klass_variable_set(arg1, arg2) -} - -var _wrap_Klass_variable_get unsafe.Pointer - -func _swig_wrap_Klass_variable_get(base SwigcptrKlass) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Klass_variable_get, _swig_p) - return -} - -func (arg1 SwigcptrKlass) GetVariable() (_swig_ret int) { - return _swig_wrap_Klass_variable_get(arg1) -} - -var _wrap_new_Klass unsafe.Pointer - -func _swig_wrap_new_Klass() (base SwigcptrKlass) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Klass, _swig_p) - return -} - -func NewKlass() (_swig_ret Klass) { - return _swig_wrap_new_Klass() -} - -var _wrap_delete_Klass unsafe.Pointer - -func _swig_wrap_delete_Klass(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Klass, _swig_p) - return -} - -func DeleteKlass(arg1 Klass) { - _swig_wrap_delete_Klass(arg1.Swigcptr()) -} - -type Klass interface { - Swigcptr() uintptr - SwigIsKlass() - SetVariable(arg2 int) - GetVariable() (_swig_ret int) -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/overload_bool.go b/Examples/test-suite/go/overload_bool.go deleted file mode 100644 index 8c11c1ee8..000000000 --- a/Examples/test-suite/go/overload_bool.go +++ /dev/null @@ -1,143 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../overload_bool.i - -package overload_bool - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -var _wrap_overloaded__SWIG_0 unsafe.Pointer - -func Overloaded__SWIG_0(arg1 bool) (_swig_ret string) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_overloaded__SWIG_0, _swig_p) - return -} -var _wrap_overloaded__SWIG_1 unsafe.Pointer - -func Overloaded__SWIG_1(arg1 int) (_swig_ret string) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_overloaded__SWIG_1, _swig_p) - return -} -var _wrap_overloaded__SWIG_2 unsafe.Pointer - -func Overloaded__SWIG_2(arg1 string) (_swig_ret string) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_overloaded__SWIG_2, _swig_p) - return -} -func Overloaded(a ...interface{}) string { - argc := len(a) - if argc == 1 { - if _, ok := a[0].(bool); !ok { - goto check_1 - } - return Overloaded__SWIG_0(a[0].(bool)) - } -check_1: - if argc == 1 { - if _, ok := a[0].(int); !ok { - goto check_2 - } - return Overloaded__SWIG_1(a[0].(int)) - } -check_2: - if argc == 1 { - return Overloaded__SWIG_2(a[0].(string)) - } - panic("No match for overloaded function call") -} - -var _wrap_boolfunction unsafe.Pointer - -func Boolfunction(arg1 bool) (_swig_ret string) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_boolfunction, _swig_p) - return -} -var _wrap_intfunction unsafe.Pointer - -func Intfunction(arg1 int) (_swig_ret string) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_intfunction, _swig_p) - return -} -var _wrap_overloaded_ref__SWIG_0 unsafe.Pointer - -func Overloaded_ref__SWIG_0(arg1 bool) (_swig_ret string) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_overloaded_ref__SWIG_0, _swig_p) - return -} -var _wrap_overloaded_ref__SWIG_1 unsafe.Pointer - -func Overloaded_ref__SWIG_1(arg1 int) (_swig_ret string) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_overloaded_ref__SWIG_1, _swig_p) - return -} -var _wrap_overloaded_ref__SWIG_2 unsafe.Pointer - -func Overloaded_ref__SWIG_2(arg1 string) (_swig_ret string) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_overloaded_ref__SWIG_2, _swig_p) - return -} -func Overloaded_ref(a ...interface{}) string { - argc := len(a) - if argc == 1 { - if _, ok := a[0].(bool); !ok { - goto check_1 - } - return Overloaded_ref__SWIG_0(a[0].(bool)) - } -check_1: - if argc == 1 { - if _, ok := a[0].(int); !ok { - goto check_2 - } - return Overloaded_ref__SWIG_1(a[0].(int)) - } -check_2: - if argc == 1 { - return Overloaded_ref__SWIG_2(a[0].(string)) - } - panic("No match for overloaded function call") -} - -var _wrap_boolfunction_ref unsafe.Pointer - -func Boolfunction_ref(arg1 bool) (_swig_ret string) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_boolfunction_ref, _swig_p) - return -} -var _wrap_intfunction_ref unsafe.Pointer - -func Intfunction_ref(arg1 int) (_swig_ret string) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_intfunction_ref, _swig_p) - return -} - diff --git a/Examples/test-suite/go/overload_copy.go b/Examples/test-suite/go/overload_copy.go deleted file mode 100644 index a7b239ba4..000000000 --- a/Examples/test-suite/go/overload_copy.go +++ /dev/null @@ -1,98 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../overload_copy.i - -package overload_copy - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrFoo uintptr - -func (p SwigcptrFoo) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrFoo) SwigIsFoo() { -} - -var _wrap_new_Foo__SWIG_0 unsafe.Pointer - -func _swig_wrap_new_Foo__SWIG_0() (base SwigcptrFoo) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Foo__SWIG_0, _swig_p) - return -} - -func NewFoo__SWIG_0() (_swig_ret Foo) { - return _swig_wrap_new_Foo__SWIG_0() -} - -var _wrap_new_Foo__SWIG_1 unsafe.Pointer - -func _swig_wrap_new_Foo__SWIG_1(base uintptr) (_ SwigcptrFoo) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Foo__SWIG_1, _swig_p) - return -} - -func NewFoo__SWIG_1(arg1 Foo) (_swig_ret Foo) { - return _swig_wrap_new_Foo__SWIG_1(arg1.Swigcptr()) -} - -func NewFoo(a ...interface{}) Foo { - argc := len(a) - if argc == 0 { - return NewFoo__SWIG_0() - } - if argc == 1 { - return NewFoo__SWIG_1(a[0].(Foo)) - } - panic("No match for overloaded function call") -} - -var _wrap_delete_Foo unsafe.Pointer - -func _swig_wrap_delete_Foo(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Foo, _swig_p) - return -} - -func DeleteFoo(arg1 Foo) { - _swig_wrap_delete_Foo(arg1.Swigcptr()) -} - -type Foo interface { - Swigcptr() uintptr - SwigIsFoo() -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/overload_copy_runme b/Examples/test-suite/go/overload_copy_runme deleted file mode 100755 index dedcf988a..000000000 Binary files a/Examples/test-suite/go/overload_copy_runme and /dev/null differ diff --git a/Examples/test-suite/go/overload_extend.go b/Examples/test-suite/go/overload_extend.go deleted file mode 100644 index fc3ea70c7..000000000 --- a/Examples/test-suite/go/overload_extend.go +++ /dev/null @@ -1,248 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../overload_extend.i - -package overload_extend - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrFoo uintptr - -func (p SwigcptrFoo) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrFoo) SwigIsFoo() { -} - -var _wrap_Foo_variable_set unsafe.Pointer - -func _swig_wrap_Foo_variable_set(base SwigcptrFoo, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_variable_set, _swig_p) - return -} - -func (arg1 SwigcptrFoo) SetVariable(arg2 int) { - _swig_wrap_Foo_variable_set(arg1, arg2) -} - -var _wrap_Foo_variable_get unsafe.Pointer - -func _swig_wrap_Foo_variable_get(base SwigcptrFoo) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_variable_get, _swig_p) - return -} - -func (arg1 SwigcptrFoo) GetVariable() (_swig_ret int) { - return _swig_wrap_Foo_variable_get(arg1) -} - -var _wrap_Foo_test__SWIG_0 unsafe.Pointer - -func _swig_wrap_Foo_test__SWIG_0(base SwigcptrFoo) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_test__SWIG_0, _swig_p) - return -} - -func (arg1 SwigcptrFoo) Test__SWIG_0() (_swig_ret int) { - return _swig_wrap_Foo_test__SWIG_0(arg1) -} - -var _wrap_Foo_test__SWIG_1 unsafe.Pointer - -func _swig_wrap_Foo_test__SWIG_1(base SwigcptrFoo, _ int) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_test__SWIG_1, _swig_p) - return -} - -func (arg1 SwigcptrFoo) Test__SWIG_1(arg2 int) (_swig_ret int) { - return _swig_wrap_Foo_test__SWIG_1(arg1, arg2) -} - -var _wrap_Foo_test__SWIG_2 unsafe.Pointer - -func _swig_wrap_Foo_test__SWIG_2(base SwigcptrFoo, _ string) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_test__SWIG_2, _swig_p) - return -} - -func (arg1 SwigcptrFoo) Test__SWIG_2(arg2 string) (_swig_ret int) { - return _swig_wrap_Foo_test__SWIG_2(arg1, arg2) -} - -var _wrap_Foo_test__SWIG_3 unsafe.Pointer - -func _swig_wrap_Foo_test__SWIG_3(base int, _ SwigcptrFoo, _ float64, _ float64) (_ float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_test__SWIG_3, _swig_p) - return -} - -func (arg1 SwigcptrFoo) Test__SWIG_3(arg2 float64, _swig_args ...interface{}) (_swig_ret float64) { - var arg3 float64 - if len(_swig_args) > 0 { - arg3 = _swig_args[0].(float64) - } - return _swig_wrap_Foo_test__SWIG_3(len(_swig_args), arg1, arg2, arg3) -} - -func (p SwigcptrFoo) Test(a ...interface{}) interface{} { - argc := len(a) - if argc == 0 { - return p.Test__SWIG_0() - } - if argc == 1 { - if _, ok := a[0].(int); !ok { - goto check_2 - } - return p.Test__SWIG_1(a[0].(int)) - } -check_2: - if argc >= 1 && argc <= 2 { - if _, ok := a[0].(float64); !ok { - goto check_3 - } - switch argc { - case 1: - return p.Test__SWIG_3(a[0].(float64)) - case 2: - return p.Test__SWIG_3(a[0].(float64), a[1]) - } - } -check_3: - if argc == 1 { - return p.Test__SWIG_2(a[0].(string)) - } - panic("No match for overloaded function call") -} - -var _wrap_new_Foo unsafe.Pointer - -func _swig_wrap_new_Foo() (base SwigcptrFoo) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Foo, _swig_p) - return -} - -func NewFoo() (_swig_ret Foo) { - return _swig_wrap_new_Foo() -} - -var _wrap_delete_Foo unsafe.Pointer - -func _swig_wrap_delete_Foo(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Foo, _swig_p) - return -} - -func DeleteFoo(arg1 Foo) { - _swig_wrap_delete_Foo(arg1.Swigcptr()) -} - -type Foo interface { - Swigcptr() uintptr - SwigIsFoo() - SetVariable(arg2 int) - GetVariable() (_swig_ret int) - Test(a ...interface{}) interface{} -} - -type SwigcptrBar uintptr - -func (p SwigcptrBar) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrBar) SwigIsBar() { -} - -var _wrap_new_Bar unsafe.Pointer - -func _swig_wrap_new_Bar() (base SwigcptrBar) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Bar, _swig_p) - return -} - -func NewBar() (_swig_ret Bar) { - return _swig_wrap_new_Bar() -} - -var _wrap_delete_Bar unsafe.Pointer - -func _swig_wrap_delete_Bar(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Bar, _swig_p) - return -} - -func DeleteBar(arg1 Bar) { - _swig_wrap_delete_Bar(arg1.Swigcptr()) -} - -var _wrap_Bar_variable_set unsafe.Pointer - -func _swig_wrap_Bar_variable_set(base SwigcptrBar, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Bar_variable_set, _swig_p) - return -} - -func (arg1 SwigcptrBar) SetVariable(arg2 int) { - _swig_wrap_Bar_variable_set(arg1, arg2) -} - -var _wrap_Bar_variable_get unsafe.Pointer - -func _swig_wrap_Bar_variable_get(base SwigcptrBar) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Bar_variable_get, _swig_p) - return -} - -func (arg1 SwigcptrBar) GetVariable() (_swig_ret int) { - return _swig_wrap_Bar_variable_get(arg1) -} - -type Bar interface { - Swigcptr() uintptr - SwigIsBar() - SetVariable(arg2 int) - GetVariable() (_swig_ret int) -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/overload_extend_runme b/Examples/test-suite/go/overload_extend_runme deleted file mode 100755 index fe478c241..000000000 Binary files a/Examples/test-suite/go/overload_extend_runme and /dev/null differ diff --git a/Examples/test-suite/go/overload_extendc.go b/Examples/test-suite/go/overload_extendc.go deleted file mode 100644 index 3123c48de..000000000 --- a/Examples/test-suite/go/overload_extendc.go +++ /dev/null @@ -1,226 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../overload_extendc.i - -package overload_extendc - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrFoo uintptr - -func (p SwigcptrFoo) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrFoo) SwigIsFoo() { -} - -var _wrap_Foo_dummy_set unsafe.Pointer - -func _swig_wrap_Foo_dummy_set(base SwigcptrFoo, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_dummy_set, _swig_p) - return -} - -func (arg1 SwigcptrFoo) SetDummy(arg2 int) { - _swig_wrap_Foo_dummy_set(arg1, arg2) -} - -var _wrap_Foo_dummy_get unsafe.Pointer - -func _swig_wrap_Foo_dummy_get(base SwigcptrFoo) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_dummy_get, _swig_p) - return -} - -func (arg1 SwigcptrFoo) GetDummy() (_swig_ret int) { - return _swig_wrap_Foo_dummy_get(arg1) -} - -var _wrap_Foo_test__SWIG_0 unsafe.Pointer - -func _swig_wrap_Foo_test__SWIG_0(base SwigcptrFoo, _ int) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_test__SWIG_0, _swig_p) - return -} - -func (arg1 SwigcptrFoo) Test__SWIG_0(arg2 int) (_swig_ret int) { - return _swig_wrap_Foo_test__SWIG_0(arg1, arg2) -} - -var _wrap_Foo_test__SWIG_1 unsafe.Pointer - -func _swig_wrap_Foo_test__SWIG_1(base SwigcptrFoo, _ string) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_test__SWIG_1, _swig_p) - return -} - -func (arg1 SwigcptrFoo) Test__SWIG_1(arg2 string) (_swig_ret int) { - return _swig_wrap_Foo_test__SWIG_1(arg1, arg2) -} - -var _wrap_Foo_test__SWIG_2 unsafe.Pointer - -func _swig_wrap_Foo_test__SWIG_2(base SwigcptrFoo, _ float64, _ float64) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_test__SWIG_2, _swig_p) - return -} - -func (arg1 SwigcptrFoo) Test__SWIG_2(arg2 float64, arg3 float64) (_swig_ret int) { - return _swig_wrap_Foo_test__SWIG_2(arg1, arg2, arg3) -} - -var _wrap_Foo_test__SWIG_3 unsafe.Pointer - -func _swig_wrap_Foo_test__SWIG_3(base int, _ SwigcptrFoo, _ string, _ int, _ int) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_test__SWIG_3, _swig_p) - return -} - -func (arg1 SwigcptrFoo) Test__SWIG_3(arg2 string, arg3 int, _swig_args ...interface{}) (_swig_ret int) { - var arg4 int - if len(_swig_args) > 0 { - arg4 = _swig_args[0].(int) - } - return _swig_wrap_Foo_test__SWIG_3(len(_swig_args), arg1, arg2, arg3, arg4) -} - -var _wrap_Foo_test__SWIG_4 unsafe.Pointer - -func _swig_wrap_Foo_test__SWIG_4(base int, _ SwigcptrFoo, _ uintptr, _ int, _ int) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_test__SWIG_4, _swig_p) - return -} - -func (arg1 SwigcptrFoo) Test__SWIG_4(arg2 Foo, _swig_args ...interface{}) (_swig_ret int) { - var arg3 int - if len(_swig_args) > 0 { - arg3 = _swig_args[0].(int) - } - var arg4 int - if len(_swig_args) > 1 { - arg4 = _swig_args[1].(int) - } - return _swig_wrap_Foo_test__SWIG_4(len(_swig_args), arg1, arg2.Swigcptr(), arg3, arg4) -} - -func (p SwigcptrFoo) Test(a ...interface{}) int { - argc := len(a) - if argc >= 1 && argc <= 3 { - if _, ok := a[0].(Foo); !ok { - goto check_1 - } - if argc > 1 { - if _, ok := a[1].(int); !ok { - goto check_1 - } - } - switch argc { - case 1: - return p.Test__SWIG_4(a[0].(Foo)) - case 2: - return p.Test__SWIG_4(a[0].(Foo), a[1]) - case 3: - return p.Test__SWIG_4(a[0].(Foo), a[1], a[2]) - } - } -check_1: - if argc == 1 { - if _, ok := a[0].(int); !ok { - goto check_2 - } - return p.Test__SWIG_0(a[0].(int)) - } -check_2: - if argc == 1 { - return p.Test__SWIG_1(a[0].(string)) - } - if argc == 2 { - if _, ok := a[0].(float64); !ok { - goto check_4 - } - if _, ok := a[1].(float64); !ok { - goto check_4 - } - return p.Test__SWIG_2(a[0].(float64), a[1].(float64)) - } -check_4: - if argc >= 2 && argc <= 3 { - switch argc { - case 2: - return p.Test__SWIG_3(a[0].(string), a[1].(int)) - case 3: - return p.Test__SWIG_3(a[0].(string), a[1].(int), a[2]) - } - } - panic("No match for overloaded function call") -} - -var _wrap_new_Foo unsafe.Pointer - -func _swig_wrap_new_Foo() (base SwigcptrFoo) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Foo, _swig_p) - return -} - -func NewFoo() (_swig_ret Foo) { - return _swig_wrap_new_Foo() -} - -var _wrap_delete_Foo unsafe.Pointer - -func _swig_wrap_delete_Foo(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Foo, _swig_p) - return -} - -func DeleteFoo(arg1 Foo) { - _swig_wrap_delete_Foo(arg1.Swigcptr()) -} - -type Foo interface { - Swigcptr() uintptr - SwigIsFoo() - SetDummy(arg2 int) - GetDummy() (_swig_ret int) - Test(a ...interface{}) int -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/overload_extendc_runme b/Examples/test-suite/go/overload_extendc_runme deleted file mode 100755 index 7c1d7bcab..000000000 Binary files a/Examples/test-suite/go/overload_extendc_runme and /dev/null differ diff --git a/Examples/test-suite/go/overload_method.go b/Examples/test-suite/go/overload_method.go deleted file mode 100644 index 9ed580a0b..000000000 --- a/Examples/test-suite/go/overload_method.go +++ /dev/null @@ -1,125 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../overload_method.i - -package overload_method - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrBase uintptr - -func (p SwigcptrBase) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrBase) SwigIsBase() { -} - -var _wrap_new_Base unsafe.Pointer - -func _swig_wrap_new_Base() (base SwigcptrBase) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Base, _swig_p) - return -} - -func NewBase() (_swig_ret Base) { - return _swig_wrap_new_Base() -} - -var _wrap_Base_method unsafe.Pointer - -func _swig_wrap_Base_method(base SwigcptrBase) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Base_method, _swig_p) - return -} - -func (arg1 SwigcptrBase) Method() (_swig_ret int) { - return _swig_wrap_Base_method(arg1) -} - -var _wrap_Base_overloaded_method__SWIG_0 unsafe.Pointer - -func _swig_wrap_Base_overloaded_method__SWIG_0(base SwigcptrBase, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Base_overloaded_method__SWIG_0, _swig_p) - return -} - -func (arg1 SwigcptrBase) Overloaded_method__SWIG_0(arg2 int) { - _swig_wrap_Base_overloaded_method__SWIG_0(arg1, arg2) -} - -var _wrap_Base_overloaded_method__SWIG_1 unsafe.Pointer - -func _swig_wrap_Base_overloaded_method__SWIG_1(base SwigcptrBase) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Base_overloaded_method__SWIG_1, _swig_p) - return -} - -func (arg1 SwigcptrBase) Overloaded_method__SWIG_1() (_swig_ret int) { - return _swig_wrap_Base_overloaded_method__SWIG_1(arg1) -} - -func (p SwigcptrBase) Overloaded_method(a ...interface{}) interface{} { - argc := len(a) - if argc == 0 { - return p.Overloaded_method__SWIG_1() - } - if argc == 1 { - p.Overloaded_method__SWIG_0(a[0].(int)) - return 0 - } - panic("No match for overloaded function call") -} - -var _wrap_delete_Base unsafe.Pointer - -func _swig_wrap_delete_Base(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Base, _swig_p) - return -} - -func DeleteBase(arg1 Base) { - _swig_wrap_delete_Base(arg1.Swigcptr()) -} - -type Base interface { - Swigcptr() uintptr - SwigIsBase() - Method() (_swig_ret int) - Overloaded_method(a ...interface{}) interface{} -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/overload_numeric.go b/Examples/test-suite/go/overload_numeric.go deleted file mode 100644 index 1e416bb6f..000000000 --- a/Examples/test-suite/go/overload_numeric.go +++ /dev/null @@ -1,340 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../overload_numeric.i - -package overload_numeric - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrLimits uintptr - -func (p SwigcptrLimits) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrLimits) SwigIsLimits() { -} - -var _wrap_Limits_schar_min unsafe.Pointer - -func _swig_wrap_Limits_schar_min(base SwigcptrLimits) (_ int8) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Limits_schar_min, _swig_p) - return -} - -func (arg1 SwigcptrLimits) Schar_min() (_swig_ret int8) { - return _swig_wrap_Limits_schar_min(arg1) -} - -var _wrap_Limits_schar_max unsafe.Pointer - -func _swig_wrap_Limits_schar_max(base SwigcptrLimits) (_ int8) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Limits_schar_max, _swig_p) - return -} - -func (arg1 SwigcptrLimits) Schar_max() (_swig_ret int8) { - return _swig_wrap_Limits_schar_max(arg1) -} - -var _wrap_Limits_shrt_min unsafe.Pointer - -func _swig_wrap_Limits_shrt_min(base SwigcptrLimits) (_ int16) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Limits_shrt_min, _swig_p) - return -} - -func (arg1 SwigcptrLimits) Shrt_min() (_swig_ret int16) { - return _swig_wrap_Limits_shrt_min(arg1) -} - -var _wrap_Limits_shrt_max unsafe.Pointer - -func _swig_wrap_Limits_shrt_max(base SwigcptrLimits) (_ int16) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Limits_shrt_max, _swig_p) - return -} - -func (arg1 SwigcptrLimits) Shrt_max() (_swig_ret int16) { - return _swig_wrap_Limits_shrt_max(arg1) -} - -var _wrap_Limits_int_min unsafe.Pointer - -func _swig_wrap_Limits_int_min(base SwigcptrLimits) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Limits_int_min, _swig_p) - return -} - -func (arg1 SwigcptrLimits) Int_min() (_swig_ret int) { - return _swig_wrap_Limits_int_min(arg1) -} - -var _wrap_Limits_int_max unsafe.Pointer - -func _swig_wrap_Limits_int_max(base SwigcptrLimits) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Limits_int_max, _swig_p) - return -} - -func (arg1 SwigcptrLimits) Int_max() (_swig_ret int) { - return _swig_wrap_Limits_int_max(arg1) -} - -var _wrap_Limits_flt_min unsafe.Pointer - -func _swig_wrap_Limits_flt_min(base SwigcptrLimits) (_ float32) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Limits_flt_min, _swig_p) - return -} - -func (arg1 SwigcptrLimits) Flt_min() (_swig_ret float32) { - return _swig_wrap_Limits_flt_min(arg1) -} - -var _wrap_Limits_flt_max unsafe.Pointer - -func _swig_wrap_Limits_flt_max(base SwigcptrLimits) (_ float32) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Limits_flt_max, _swig_p) - return -} - -func (arg1 SwigcptrLimits) Flt_max() (_swig_ret float32) { - return _swig_wrap_Limits_flt_max(arg1) -} - -var _wrap_Limits_dbl_max unsafe.Pointer - -func _swig_wrap_Limits_dbl_max(base SwigcptrLimits) (_ float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Limits_dbl_max, _swig_p) - return -} - -func (arg1 SwigcptrLimits) Dbl_max() (_swig_ret float64) { - return _swig_wrap_Limits_dbl_max(arg1) -} - -var _wrap_new_Limits unsafe.Pointer - -func _swig_wrap_new_Limits() (base SwigcptrLimits) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Limits, _swig_p) - return -} - -func NewLimits() (_swig_ret Limits) { - return _swig_wrap_new_Limits() -} - -var _wrap_delete_Limits unsafe.Pointer - -func _swig_wrap_delete_Limits(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Limits, _swig_p) - return -} - -func DeleteLimits(arg1 Limits) { - _swig_wrap_delete_Limits(arg1.Swigcptr()) -} - -type Limits interface { - Swigcptr() uintptr - SwigIsLimits() - Schar_min() (_swig_ret int8) - Schar_max() (_swig_ret int8) - Shrt_min() (_swig_ret int16) - Shrt_max() (_swig_ret int16) - Int_min() (_swig_ret int) - Int_max() (_swig_ret int) - Flt_min() (_swig_ret float32) - Flt_max() (_swig_ret float32) - Dbl_max() (_swig_ret float64) -} - -type SwigcptrNums uintptr - -func (p SwigcptrNums) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrNums) SwigIsNums() { -} - -var _wrap_Nums_over__SWIG_0 unsafe.Pointer - -func _swig_wrap_Nums_over__SWIG_0(base SwigcptrNums, _ int8) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Nums_over__SWIG_0, _swig_p) - return -} - -func (arg1 SwigcptrNums) Over__SWIG_0(arg2 int8) (_swig_ret string) { - return _swig_wrap_Nums_over__SWIG_0(arg1, arg2) -} - -var _wrap_Nums_over__SWIG_1 unsafe.Pointer - -func _swig_wrap_Nums_over__SWIG_1(base SwigcptrNums, _ int16) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Nums_over__SWIG_1, _swig_p) - return -} - -func (arg1 SwigcptrNums) Over__SWIG_1(arg2 int16) (_swig_ret string) { - return _swig_wrap_Nums_over__SWIG_1(arg1, arg2) -} - -var _wrap_Nums_over__SWIG_2 unsafe.Pointer - -func _swig_wrap_Nums_over__SWIG_2(base SwigcptrNums, _ int) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Nums_over__SWIG_2, _swig_p) - return -} - -func (arg1 SwigcptrNums) Over__SWIG_2(arg2 int) (_swig_ret string) { - return _swig_wrap_Nums_over__SWIG_2(arg1, arg2) -} - -var _wrap_Nums_over__SWIG_3 unsafe.Pointer - -func _swig_wrap_Nums_over__SWIG_3(base SwigcptrNums, _ float32) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Nums_over__SWIG_3, _swig_p) - return -} - -func (arg1 SwigcptrNums) Over__SWIG_3(arg2 float32) (_swig_ret string) { - return _swig_wrap_Nums_over__SWIG_3(arg1, arg2) -} - -var _wrap_Nums_over__SWIG_4 unsafe.Pointer - -func _swig_wrap_Nums_over__SWIG_4(base SwigcptrNums, _ float64) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Nums_over__SWIG_4, _swig_p) - return -} - -func (arg1 SwigcptrNums) Over__SWIG_4(arg2 float64) (_swig_ret string) { - return _swig_wrap_Nums_over__SWIG_4(arg1, arg2) -} - -func (p SwigcptrNums) Over(a ...interface{}) string { - argc := len(a) - if argc == 1 { - if _, ok := a[0].(int8); !ok { - goto check_1 - } - return p.Over__SWIG_0(a[0].(int8)) - } -check_1: - if argc == 1 { - if _, ok := a[0].(int16); !ok { - goto check_2 - } - return p.Over__SWIG_1(a[0].(int16)) - } -check_2: - if argc == 1 { - if _, ok := a[0].(int); !ok { - goto check_3 - } - return p.Over__SWIG_2(a[0].(int)) - } -check_3: - if argc == 1 { - if _, ok := a[0].(float32); !ok { - goto check_4 - } - return p.Over__SWIG_3(a[0].(float32)) - } -check_4: - if argc == 1 { - return p.Over__SWIG_4(a[0].(float64)) - } - panic("No match for overloaded function call") -} - -var _wrap_Nums_doublebounce unsafe.Pointer - -func _swig_wrap_Nums_doublebounce(base SwigcptrNums, _ float64) (_ float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Nums_doublebounce, _swig_p) - return -} - -func (arg1 SwigcptrNums) Doublebounce(arg2 float64) (_swig_ret float64) { - return _swig_wrap_Nums_doublebounce(arg1, arg2) -} - -var _wrap_new_Nums unsafe.Pointer - -func _swig_wrap_new_Nums() (base SwigcptrNums) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Nums, _swig_p) - return -} - -func NewNums() (_swig_ret Nums) { - return _swig_wrap_new_Nums() -} - -var _wrap_delete_Nums unsafe.Pointer - -func _swig_wrap_delete_Nums(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Nums, _swig_p) - return -} - -func DeleteNums(arg1 Nums) { - _swig_wrap_delete_Nums(arg1.Swigcptr()) -} - -type Nums interface { - Swigcptr() uintptr - SwigIsNums() - Over(a ...interface{}) string - Doublebounce(arg2 float64) (_swig_ret float64) -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/overload_polymorphic.go b/Examples/test-suite/go/overload_polymorphic.go deleted file mode 100644 index 38d83bbe3..000000000 --- a/Examples/test-suite/go/overload_polymorphic.go +++ /dev/null @@ -1,156 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../overload_polymorphic.i - -package overload_polymorphic - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrBase uintptr - -func (p SwigcptrBase) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrBase) SwigIsBase() { -} - -var _wrap_new_Base unsafe.Pointer - -func _swig_wrap_new_Base() (base SwigcptrBase) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Base, _swig_p) - return -} - -func NewBase() (_swig_ret Base) { - return _swig_wrap_new_Base() -} - -var _wrap_delete_Base unsafe.Pointer - -func _swig_wrap_delete_Base(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Base, _swig_p) - return -} - -func DeleteBase(arg1 Base) { - _swig_wrap_delete_Base(arg1.Swigcptr()) -} - -type Base interface { - Swigcptr() uintptr - SwigIsBase() -} - -type SwigcptrDerived uintptr - -func (p SwigcptrDerived) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrDerived) SwigIsDerived() { -} - -var _wrap_new_Derived unsafe.Pointer - -func _swig_wrap_new_Derived() (base SwigcptrDerived) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Derived, _swig_p) - return -} - -func NewDerived() (_swig_ret Derived) { - return _swig_wrap_new_Derived() -} - -var _wrap_delete_Derived unsafe.Pointer - -func _swig_wrap_delete_Derived(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Derived, _swig_p) - return -} - -func DeleteDerived(arg1 Derived) { - _swig_wrap_delete_Derived(arg1.Swigcptr()) -} - -func (p SwigcptrDerived) SwigIsBase() { -} - -func (p SwigcptrDerived) SwigGetBase() Base { - return SwigcptrBase(p.Swigcptr()) -} - -type Derived interface { - Swigcptr() uintptr - SwigIsDerived() - SwigIsBase() - SwigGetBase() Base -} - -var _wrap_test__SWIG_0 unsafe.Pointer - -func _swig_wrap_test__SWIG_0(base uintptr) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_test__SWIG_0, _swig_p) - return -} - -func Test__SWIG_0(arg1 Base) (_swig_ret int) { - return _swig_wrap_test__SWIG_0(arg1.Swigcptr()) -} - -var _wrap_test__SWIG_1 unsafe.Pointer - -func Test__SWIG_1(arg1 int) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_test__SWIG_1, _swig_p) - return -} -func Test(a ...interface{}) int { - argc := len(a) - if argc == 1 { - if _, ok := a[0].(Base); !ok { - goto check_1 - } - return Test__SWIG_0(a[0].(Base)) - } -check_1: - if argc == 1 { - return Test__SWIG_1(a[0].(int)) - } - panic("No match for overloaded function call") -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/overload_polymorphic_runme b/Examples/test-suite/go/overload_polymorphic_runme deleted file mode 100755 index f1249bc18..000000000 Binary files a/Examples/test-suite/go/overload_polymorphic_runme and /dev/null differ diff --git a/Examples/test-suite/go/overload_polymorphic_runme.go~ b/Examples/test-suite/go/overload_polymorphic_runme.go~ deleted file mode 100644 index ae5aa036d..000000000 --- a/Examples/test-suite/go/overload_polymorphic_runme.go~ +++ /dev/null @@ -1,11 +0,0 @@ -package main - -import "./overload_polymorphic" - -func main(){ - t := overload_polymorphic.NewDerived() - - if overload_polymorphic.Test(t) != 1 { - panic("failed") - } -} diff --git a/Examples/test-suite/go/overload_rename.go b/Examples/test-suite/go/overload_rename.go deleted file mode 100644 index dfcb639b0..000000000 --- a/Examples/test-suite/go/overload_rename.go +++ /dev/null @@ -1,133 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../overload_rename.i - -package overload_rename - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrFoo uintptr - -func (p SwigcptrFoo) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrFoo) SwigIsFoo() { -} - -var _wrap_new_Foo__SWIG_0 unsafe.Pointer - -func _swig_wrap_new_Foo__SWIG_0(base float32, _ float32) (_ SwigcptrFoo) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Foo__SWIG_0, _swig_p) - return -} - -func NewFoo__SWIG_0(arg1 float32, arg2 float32) (_swig_ret Foo) { - return _swig_wrap_new_Foo__SWIG_0(arg1, arg2) -} - -var _wrap_new_Foo__SWIG_1 unsafe.Pointer - -func _swig_wrap_new_Foo__SWIG_1(base float32) (_ SwigcptrFoo) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Foo__SWIG_1, _swig_p) - return -} - -func NewFoo__SWIG_1(arg1 float32) (_swig_ret Foo) { - return _swig_wrap_new_Foo__SWIG_1(arg1) -} - -func NewFoo(a ...interface{}) Foo { - argc := len(a) - if argc == 1 { - return NewFoo__SWIG_1(a[0].(float32)) - } - if argc == 2 { - return NewFoo__SWIG_0(a[0].(float32), a[1].(float32)) - } - panic("No match for overloaded function call") -} - -var _wrap_new_Foo_int__SWIG_0 unsafe.Pointer - -func _swig_wrap_new_Foo_int__SWIG_0(base float32, _ int, _ float32) (_ SwigcptrFoo) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Foo_int__SWIG_0, _swig_p) - return -} - -func NewFoo_int__SWIG_0(arg1 float32, arg2 int, arg3 float32) (_swig_ret Foo) { - return _swig_wrap_new_Foo_int__SWIG_0(arg1, arg2, arg3) -} - -var _wrap_new_Foo_int__SWIG_1 unsafe.Pointer - -func _swig_wrap_new_Foo_int__SWIG_1(base float32, _ int) (_ SwigcptrFoo) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Foo_int__SWIG_1, _swig_p) - return -} - -func NewFoo_int__SWIG_1(arg1 float32, arg2 int) (_swig_ret Foo) { - return _swig_wrap_new_Foo_int__SWIG_1(arg1, arg2) -} - -func NewFoo_int(a ...interface{}) Foo { - argc := len(a) - if argc == 2 { - return NewFoo_int__SWIG_1(a[0].(float32), a[1].(int)) - } - if argc == 3 { - return NewFoo_int__SWIG_0(a[0].(float32), a[1].(int), a[2].(float32)) - } - panic("No match for overloaded function call") -} - -var _wrap_delete_Foo unsafe.Pointer - -func _swig_wrap_delete_Foo(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Foo, _swig_p) - return -} - -func DeleteFoo(arg1 Foo) { - _swig_wrap_delete_Foo(arg1.Swigcptr()) -} - -type Foo interface { - Swigcptr() uintptr - SwigIsFoo() -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/overload_rename_runme b/Examples/test-suite/go/overload_rename_runme deleted file mode 100755 index 987910277..000000000 Binary files a/Examples/test-suite/go/overload_rename_runme and /dev/null differ diff --git a/Examples/test-suite/go/overload_return_type.go b/Examples/test-suite/go/overload_return_type.go deleted file mode 100644 index 8291131b2..000000000 --- a/Examples/test-suite/go/overload_return_type.go +++ /dev/null @@ -1,215 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../overload_return_type.i - -package overload_return_type - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrA uintptr - -func (p SwigcptrA) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrA) SwigIsA() { -} - -var _wrap_new_A unsafe.Pointer - -func _swig_wrap_new_A() (base SwigcptrA) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_A, _swig_p) - return -} - -func NewA() (_swig_ret A) { - return _swig_wrap_new_A() -} - -var _wrap_delete_A unsafe.Pointer - -func _swig_wrap_delete_A(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_A, _swig_p) - return -} - -func DeleteA(arg1 A) { - _swig_wrap_delete_A(arg1.Swigcptr()) -} - -type A interface { - Swigcptr() uintptr - SwigIsA() -} - -type SwigcptrB uintptr - -func (p SwigcptrB) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrB) SwigIsB() { -} - -var _wrap_B_foo__SWIG_0 unsafe.Pointer - -func _swig_wrap_B_foo__SWIG_0(base SwigcptrB, _ int) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_B_foo__SWIG_0, _swig_p) - return -} - -func (arg1 SwigcptrB) Foo__SWIG_0(arg2 int) (_swig_ret int) { - return _swig_wrap_B_foo__SWIG_0(arg1, arg2) -} - -var _wrap_B_foo__SWIG_1 unsafe.Pointer - -func _swig_wrap_B_foo__SWIG_1(base SwigcptrB, _ string) (_ SwigcptrA) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_B_foo__SWIG_1, _swig_p) - return -} - -func (arg1 SwigcptrB) Foo__SWIG_1(arg2 string) (_swig_ret A) { - return _swig_wrap_B_foo__SWIG_1(arg1, arg2) -} - -func (p SwigcptrB) Foo(a ...interface{}) interface{} { - argc := len(a) - if argc == 1 { - if _, ok := a[0].(int); !ok { - goto check_1 - } - return p.Foo__SWIG_0(a[0].(int)) - } -check_1: - if argc == 1 { - return p.Foo__SWIG_1(a[0].(string)) - } - panic("No match for overloaded function call") -} - -var _wrap_new_B unsafe.Pointer - -func _swig_wrap_new_B() (base SwigcptrB) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_B, _swig_p) - return -} - -func NewB() (_swig_ret B) { - return _swig_wrap_new_B() -} - -var _wrap_delete_B unsafe.Pointer - -func _swig_wrap_delete_B(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_B, _swig_p) - return -} - -func DeleteB(arg1 B) { - _swig_wrap_delete_B(arg1.Swigcptr()) -} - -type B interface { - Swigcptr() uintptr - SwigIsB() - Foo(a ...interface{}) interface{} -} - -var _wrap_foo__SWIG_0 unsafe.Pointer - -func _swig_wrap_foo__SWIG_0(base int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_foo__SWIG_0, _swig_p) - return -} - -func Foo__SWIG_0(arg1 int) { - _swig_wrap_foo__SWIG_0(arg1) -} - -var _wrap_foo__SWIG_1 unsafe.Pointer - -func Foo__SWIG_1() (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_foo__SWIG_1, _swig_p) - return -} -func Foo(a ...interface{}) interface{} { - argc := len(a) - if argc == 0 { - return Foo__SWIG_1() - } - if argc == 1 { - Foo__SWIG_0(a[0].(int)) - return 0 - } - panic("No match for overloaded function call") -} - -var _wrap_bar__SWIG_0 unsafe.Pointer - -func Bar__SWIG_0() (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_bar__SWIG_0, _swig_p) - return -} -var _wrap_bar__SWIG_1 unsafe.Pointer - -func _swig_wrap_bar__SWIG_1(base int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_bar__SWIG_1, _swig_p) - return -} - -func Bar__SWIG_1(arg1 int) { - _swig_wrap_bar__SWIG_1(arg1) -} - -func Bar(a ...interface{}) interface{} { - argc := len(a) - if argc == 0 { - return Bar__SWIG_0() - } - if argc == 1 { - Bar__SWIG_1(a[0].(int)) - return 0 - } - panic("No match for overloaded function call") -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/overload_simple.go b/Examples/test-suite/go/overload_simple.go deleted file mode 100644 index a09d30154..000000000 --- a/Examples/test-suite/go/overload_simple.go +++ /dev/null @@ -1,1060 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../overload_simple.i - -package overload_simple - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrFoos uintptr - -func (p SwigcptrFoos) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrFoos) SwigIsFoos() { -} - -var _wrap_new_Foos unsafe.Pointer - -func _swig_wrap_new_Foos() (base SwigcptrFoos) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Foos, _swig_p) - return -} - -func NewFoos() (_swig_ret Foos) { - return _swig_wrap_new_Foos() -} - -var _wrap_delete_Foos unsafe.Pointer - -func _swig_wrap_delete_Foos(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Foos, _swig_p) - return -} - -func DeleteFoos(arg1 Foos) { - _swig_wrap_delete_Foos(arg1.Swigcptr()) -} - -type Foos interface { - Swigcptr() uintptr - SwigIsFoos() -} - -type SwigcptrBar uintptr - -func (p SwigcptrBar) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrBar) SwigIsBar() { -} - -var _wrap_new_Bar__SWIG_0 unsafe.Pointer - -func _swig_wrap_new_Bar__SWIG_0(base int) (_ SwigcptrBar) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Bar__SWIG_0, _swig_p) - return -} - -func NewBar__SWIG_0(arg1 int) (_swig_ret Bar) { - return _swig_wrap_new_Bar__SWIG_0(arg1) -} - -var _wrap_new_Bar__SWIG_1 unsafe.Pointer - -func _swig_wrap_new_Bar__SWIG_1() (base SwigcptrBar) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Bar__SWIG_1, _swig_p) - return -} - -func NewBar__SWIG_1() (_swig_ret Bar) { - return _swig_wrap_new_Bar__SWIG_1() -} - -func NewBar(a ...interface{}) Bar { - argc := len(a) - if argc == 0 { - return NewBar__SWIG_1() - } - if argc == 1 { - return NewBar__SWIG_0(a[0].(int)) - } - panic("No match for overloaded function call") -} - -var _wrap_Bar_foo__SWIG_0 unsafe.Pointer - -func BarFoo__SWIG_0(arg1 int, arg2 int) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_Bar_foo__SWIG_0, _swig_p) - return -} -var _wrap_Bar_foo__SWIG_1 unsafe.Pointer - -func BarFoo__SWIG_1(arg1 int) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_Bar_foo__SWIG_1, _swig_p) - return -} -var _wrap_Bar_foo__SWIG_2 unsafe.Pointer - -func BarFoo__SWIG_2() (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_Bar_foo__SWIG_2, _swig_p) - return -} -func BarFoo(a ...interface{}) int { - argc := len(a) - if argc == 0 { - return BarFoo__SWIG_2() - } - if argc == 1 { - return BarFoo__SWIG_1(a[0].(int)) - } - if argc == 2 { - return BarFoo__SWIG_0(a[0].(int), a[1].(int)) - } - panic("No match for overloaded function call") -} - -var _wrap_Bar_num_set unsafe.Pointer - -func _swig_wrap_Bar_num_set(base SwigcptrBar, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Bar_num_set, _swig_p) - return -} - -func (arg1 SwigcptrBar) SetNum(arg2 int) { - _swig_wrap_Bar_num_set(arg1, arg2) -} - -var _wrap_Bar_num_get unsafe.Pointer - -func _swig_wrap_Bar_num_get(base SwigcptrBar) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Bar_num_get, _swig_p) - return -} - -func (arg1 SwigcptrBar) GetNum() (_swig_ret int) { - return _swig_wrap_Bar_num_get(arg1) -} - -var _wrap_delete_Bar unsafe.Pointer - -func _swig_wrap_delete_Bar(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Bar, _swig_p) - return -} - -func DeleteBar(arg1 Bar) { - _swig_wrap_delete_Bar(arg1.Swigcptr()) -} - -type Bar interface { - Swigcptr() uintptr - SwigIsBar() - SetNum(arg2 int) - GetNum() (_swig_ret int) -} - -var _wrap_foo__SWIG_0 unsafe.Pointer - -func Foo__SWIG_0() (_swig_ret string) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_foo__SWIG_0, _swig_p) - return -} -var _wrap_foo__SWIG_1 unsafe.Pointer - -func Foo__SWIG_1(arg1 int) (_swig_ret string) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_foo__SWIG_1, _swig_p) - return -} -var _wrap_foo__SWIG_2 unsafe.Pointer - -func Foo__SWIG_2(arg1 float64) (_swig_ret string) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_foo__SWIG_2, _swig_p) - return -} -var _wrap_foo__SWIG_3 unsafe.Pointer - -func Foo__SWIG_3(arg1 string) (_swig_ret string) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_foo__SWIG_3, _swig_p) - return -} -var _wrap_foo__SWIG_4 unsafe.Pointer - -func _swig_wrap_foo__SWIG_4(base uintptr) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_foo__SWIG_4, _swig_p) - return -} - -func Foo__SWIG_4(arg1 Foos) (_swig_ret string) { - return _swig_wrap_foo__SWIG_4(arg1.Swigcptr()) -} - -var _wrap_foo__SWIG_5 unsafe.Pointer - -func _swig_wrap_foo__SWIG_5(base uintptr) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_foo__SWIG_5, _swig_p) - return -} - -func Foo__SWIG_5(arg1 Bar) (_swig_ret string) { - return _swig_wrap_foo__SWIG_5(arg1.Swigcptr()) -} - -var _wrap_foo__SWIG_6 unsafe.Pointer - -func Foo__SWIG_6(arg1 uintptr) (_swig_ret string) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_foo__SWIG_6, _swig_p) - return -} -var _wrap_foo__SWIG_7 unsafe.Pointer - -func _swig_wrap_foo__SWIG_7(base uintptr, _ int) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_foo__SWIG_7, _swig_p) - return -} - -func Foo__SWIG_7(arg1 Foos, arg2 int) (_swig_ret string) { - return _swig_wrap_foo__SWIG_7(arg1.Swigcptr(), arg2) -} - -var _wrap_foo__SWIG_8 unsafe.Pointer - -func _swig_wrap_foo__SWIG_8(base float64, _ uintptr) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_foo__SWIG_8, _swig_p) - return -} - -func Foo__SWIG_8(arg1 float64, arg2 Bar) (_swig_ret string) { - return _swig_wrap_foo__SWIG_8(arg1, arg2.Swigcptr()) -} - -func Foo(a ...interface{}) string { - argc := len(a) - if argc == 0 { - return Foo__SWIG_0() - } - if argc == 1 { - if _, ok := a[0].(Foos); !ok { - goto check_2 - } - return Foo__SWIG_4(a[0].(Foos)) - } -check_2: - if argc == 1 { - if _, ok := a[0].(Bar); !ok { - goto check_3 - } - return Foo__SWIG_5(a[0].(Bar)) - } -check_3: - if argc == 1 { - if _, ok := a[0].(uintptr); !ok { - goto check_4 - } - return Foo__SWIG_6(a[0].(uintptr)) - } -check_4: - if argc == 1 { - if _, ok := a[0].(int); !ok { - goto check_5 - } - return Foo__SWIG_1(a[0].(int)) - } -check_5: - if argc == 1 { - if _, ok := a[0].(float64); !ok { - goto check_6 - } - return Foo__SWIG_2(a[0].(float64)) - } -check_6: - if argc == 1 { - return Foo__SWIG_3(a[0].(string)) - } - if argc == 2 { - if _, ok := a[0].(Foos); !ok { - goto check_8 - } - if _, ok := a[1].(int); !ok { - goto check_8 - } - return Foo__SWIG_7(a[0].(Foos), a[1].(int)) - } -check_8: - if argc == 2 { - return Foo__SWIG_8(a[0].(float64), a[1].(Bar)) - } - panic("No match for overloaded function call") -} - -var _wrap_blah__SWIG_0 unsafe.Pointer - -func Blah__SWIG_0(arg1 float64) (_swig_ret string) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_blah__SWIG_0, _swig_p) - return -} -var _wrap_blah__SWIG_1 unsafe.Pointer - -func Blah__SWIG_1(arg1 string) (_swig_ret string) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_blah__SWIG_1, _swig_p) - return -} -func Blah(a ...interface{}) string { - argc := len(a) - if argc == 1 { - if _, ok := a[0].(float64); !ok { - goto check_1 - } - return Blah__SWIG_0(a[0].(float64)) - } -check_1: - if argc == 1 { - return Blah__SWIG_1(a[0].(string)) - } - panic("No match for overloaded function call") -} - -type SwigcptrSpam uintptr - -func (p SwigcptrSpam) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrSpam) SwigIsSpam() { -} - -var _wrap_new_Spam__SWIG_0 unsafe.Pointer - -func _swig_wrap_new_Spam__SWIG_0() (base SwigcptrSpam) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Spam__SWIG_0, _swig_p) - return -} - -func NewSpam__SWIG_0() (_swig_ret Spam) { - return _swig_wrap_new_Spam__SWIG_0() -} - -var _wrap_new_Spam__SWIG_1 unsafe.Pointer - -func _swig_wrap_new_Spam__SWIG_1(base int) (_ SwigcptrSpam) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Spam__SWIG_1, _swig_p) - return -} - -func NewSpam__SWIG_1(arg1 int) (_swig_ret Spam) { - return _swig_wrap_new_Spam__SWIG_1(arg1) -} - -var _wrap_new_Spam__SWIG_2 unsafe.Pointer - -func _swig_wrap_new_Spam__SWIG_2(base float64) (_ SwigcptrSpam) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Spam__SWIG_2, _swig_p) - return -} - -func NewSpam__SWIG_2(arg1 float64) (_swig_ret Spam) { - return _swig_wrap_new_Spam__SWIG_2(arg1) -} - -var _wrap_new_Spam__SWIG_3 unsafe.Pointer - -func _swig_wrap_new_Spam__SWIG_3(base string) (_ SwigcptrSpam) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Spam__SWIG_3, _swig_p) - return -} - -func NewSpam__SWIG_3(arg1 string) (_swig_ret Spam) { - return _swig_wrap_new_Spam__SWIG_3(arg1) -} - -var _wrap_new_Spam__SWIG_4 unsafe.Pointer - -func _swig_wrap_new_Spam__SWIG_4(base uintptr) (_ SwigcptrSpam) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Spam__SWIG_4, _swig_p) - return -} - -func NewSpam__SWIG_4(arg1 Foos) (_swig_ret Spam) { - return _swig_wrap_new_Spam__SWIG_4(arg1.Swigcptr()) -} - -var _wrap_new_Spam__SWIG_5 unsafe.Pointer - -func _swig_wrap_new_Spam__SWIG_5(base uintptr) (_ SwigcptrSpam) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Spam__SWIG_5, _swig_p) - return -} - -func NewSpam__SWIG_5(arg1 Bar) (_swig_ret Spam) { - return _swig_wrap_new_Spam__SWIG_5(arg1.Swigcptr()) -} - -var _wrap_new_Spam__SWIG_6 unsafe.Pointer - -func _swig_wrap_new_Spam__SWIG_6(base uintptr) (_ SwigcptrSpam) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Spam__SWIG_6, _swig_p) - return -} - -func NewSpam__SWIG_6(arg1 uintptr) (_swig_ret Spam) { - return _swig_wrap_new_Spam__SWIG_6(arg1) -} - -func NewSpam(a ...interface{}) Spam { - argc := len(a) - if argc == 0 { - return NewSpam__SWIG_0() - } - if argc == 1 { - if _, ok := a[0].(Foos); !ok { - goto check_2 - } - return NewSpam__SWIG_4(a[0].(Foos)) - } -check_2: - if argc == 1 { - if _, ok := a[0].(Bar); !ok { - goto check_3 - } - return NewSpam__SWIG_5(a[0].(Bar)) - } -check_3: - if argc == 1 { - if _, ok := a[0].(uintptr); !ok { - goto check_4 - } - return NewSpam__SWIG_6(a[0].(uintptr)) - } -check_4: - if argc == 1 { - if _, ok := a[0].(int); !ok { - goto check_5 - } - return NewSpam__SWIG_1(a[0].(int)) - } -check_5: - if argc == 1 { - if _, ok := a[0].(float64); !ok { - goto check_6 - } - return NewSpam__SWIG_2(a[0].(float64)) - } -check_6: - if argc == 1 { - return NewSpam__SWIG_3(a[0].(string)) - } - panic("No match for overloaded function call") -} - -var _wrap_Spam_Xtype_get unsafe.Pointer - -func _swig_wrap_Spam_Xtype_get(base SwigcptrSpam) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Spam_Xtype_get, _swig_p) - return -} - -func (arg1 SwigcptrSpam) GetXtype() (_swig_ret string) { - return _swig_wrap_Spam_Xtype_get(arg1) -} - -var _wrap_Spam_foo__SWIG_0 unsafe.Pointer - -func _swig_wrap_Spam_foo__SWIG_0(base SwigcptrSpam, _ int) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Spam_foo__SWIG_0, _swig_p) - return -} - -func (arg1 SwigcptrSpam) Foo__SWIG_0(arg2 int) (_swig_ret string) { - return _swig_wrap_Spam_foo__SWIG_0(arg1, arg2) -} - -var _wrap_Spam_foo__SWIG_1 unsafe.Pointer - -func _swig_wrap_Spam_foo__SWIG_1(base SwigcptrSpam, _ float64) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Spam_foo__SWIG_1, _swig_p) - return -} - -func (arg1 SwigcptrSpam) Foo__SWIG_1(arg2 float64) (_swig_ret string) { - return _swig_wrap_Spam_foo__SWIG_1(arg1, arg2) -} - -var _wrap_Spam_foo__SWIG_2 unsafe.Pointer - -func _swig_wrap_Spam_foo__SWIG_2(base SwigcptrSpam, _ string) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Spam_foo__SWIG_2, _swig_p) - return -} - -func (arg1 SwigcptrSpam) Foo__SWIG_2(arg2 string) (_swig_ret string) { - return _swig_wrap_Spam_foo__SWIG_2(arg1, arg2) -} - -var _wrap_Spam_foo__SWIG_3 unsafe.Pointer - -func _swig_wrap_Spam_foo__SWIG_3(base SwigcptrSpam, _ uintptr) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Spam_foo__SWIG_3, _swig_p) - return -} - -func (arg1 SwigcptrSpam) Foo__SWIG_3(arg2 Foos) (_swig_ret string) { - return _swig_wrap_Spam_foo__SWIG_3(arg1, arg2.Swigcptr()) -} - -var _wrap_Spam_foo__SWIG_4 unsafe.Pointer - -func _swig_wrap_Spam_foo__SWIG_4(base SwigcptrSpam, _ uintptr) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Spam_foo__SWIG_4, _swig_p) - return -} - -func (arg1 SwigcptrSpam) Foo__SWIG_4(arg2 Bar) (_swig_ret string) { - return _swig_wrap_Spam_foo__SWIG_4(arg1, arg2.Swigcptr()) -} - -var _wrap_Spam_foo__SWIG_5 unsafe.Pointer - -func _swig_wrap_Spam_foo__SWIG_5(base SwigcptrSpam, _ uintptr) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Spam_foo__SWIG_5, _swig_p) - return -} - -func (arg1 SwigcptrSpam) Foo__SWIG_5(arg2 uintptr) (_swig_ret string) { - return _swig_wrap_Spam_foo__SWIG_5(arg1, arg2) -} - -func (p SwigcptrSpam) Foo(a ...interface{}) string { - argc := len(a) - if argc == 1 { - if _, ok := a[0].(Foos); !ok { - goto check_1 - } - return p.Foo__SWIG_3(a[0].(Foos)) - } -check_1: - if argc == 1 { - if _, ok := a[0].(Bar); !ok { - goto check_2 - } - return p.Foo__SWIG_4(a[0].(Bar)) - } -check_2: - if argc == 1 { - if _, ok := a[0].(uintptr); !ok { - goto check_3 - } - return p.Foo__SWIG_5(a[0].(uintptr)) - } -check_3: - if argc == 1 { - if _, ok := a[0].(int); !ok { - goto check_4 - } - return p.Foo__SWIG_0(a[0].(int)) - } -check_4: - if argc == 1 { - if _, ok := a[0].(float64); !ok { - goto check_5 - } - return p.Foo__SWIG_1(a[0].(float64)) - } -check_5: - if argc == 1 { - return p.Foo__SWIG_2(a[0].(string)) - } - panic("No match for overloaded function call") -} - -var _wrap_Spam_bar__SWIG_0 unsafe.Pointer - -func SpamBar__SWIG_0(arg1 int) (_swig_ret string) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_Spam_bar__SWIG_0, _swig_p) - return -} -var _wrap_Spam_bar__SWIG_1 unsafe.Pointer - -func SpamBar__SWIG_1(arg1 float64) (_swig_ret string) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_Spam_bar__SWIG_1, _swig_p) - return -} -var _wrap_Spam_bar__SWIG_2 unsafe.Pointer - -func SpamBar__SWIG_2(arg1 string) (_swig_ret string) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_Spam_bar__SWIG_2, _swig_p) - return -} -var _wrap_Spam_bar__SWIG_3 unsafe.Pointer - -func _swig_wrap_Spam_bar__SWIG_3(base uintptr) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Spam_bar__SWIG_3, _swig_p) - return -} - -func SpamBar__SWIG_3(arg1 Foos) (_swig_ret string) { - return _swig_wrap_Spam_bar__SWIG_3(arg1.Swigcptr()) -} - -var _wrap_Spam_bar__SWIG_4 unsafe.Pointer - -func _swig_wrap_Spam_bar__SWIG_4(base uintptr) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Spam_bar__SWIG_4, _swig_p) - return -} - -func SpamBar__SWIG_4(arg1 Bar) (_swig_ret string) { - return _swig_wrap_Spam_bar__SWIG_4(arg1.Swigcptr()) -} - -var _wrap_Spam_bar__SWIG_5 unsafe.Pointer - -func SpamBar__SWIG_5(arg1 uintptr) (_swig_ret string) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_Spam_bar__SWIG_5, _swig_p) - return -} -func SpamBar(a ...interface{}) string { - argc := len(a) - if argc == 1 { - if _, ok := a[0].(Foos); !ok { - goto check_1 - } - return SpamBar__SWIG_3(a[0].(Foos)) - } -check_1: - if argc == 1 { - if _, ok := a[0].(Bar); !ok { - goto check_2 - } - return SpamBar__SWIG_4(a[0].(Bar)) - } -check_2: - if argc == 1 { - if _, ok := a[0].(uintptr); !ok { - goto check_3 - } - return SpamBar__SWIG_5(a[0].(uintptr)) - } -check_3: - if argc == 1 { - if _, ok := a[0].(int); !ok { - goto check_4 - } - return SpamBar__SWIG_0(a[0].(int)) - } -check_4: - if argc == 1 { - if _, ok := a[0].(float64); !ok { - goto check_5 - } - return SpamBar__SWIG_1(a[0].(float64)) - } -check_5: - if argc == 1 { - return SpamBar__SWIG_2(a[0].(string)) - } - panic("No match for overloaded function call") -} - -var _wrap_delete_Spam unsafe.Pointer - -func _swig_wrap_delete_Spam(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Spam, _swig_p) - return -} - -func DeleteSpam(arg1 Spam) { - _swig_wrap_delete_Spam(arg1.Swigcptr()) -} - -type Spam interface { - Swigcptr() uintptr - SwigIsSpam() - GetXtype() (_swig_ret string) - Foo(a ...interface{}) string -} - -var _wrap_fbool__SWIG_0 unsafe.Pointer - -func Fbool__SWIG_0(arg1 bool) (_swig_ret bool) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_fbool__SWIG_0, _swig_p) - return -} -var _wrap_fbool__SWIG_1 unsafe.Pointer - -func Fbool__SWIG_1(arg1 int) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_fbool__SWIG_1, _swig_p) - return -} -func Fbool(a ...interface{}) interface{} { - argc := len(a) - if argc == 1 { - if _, ok := a[0].(bool); !ok { - goto check_1 - } - return Fbool__SWIG_0(a[0].(bool)) - } -check_1: - if argc == 1 { - return Fbool__SWIG_1(a[0].(int)) - } - panic("No match for overloaded function call") -} - -var _wrap_fint unsafe.Pointer - -func Fint(arg1 int) (_swig_ret string) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_fint, _swig_p) - return -} -var _wrap_fdouble unsafe.Pointer - -func Fdouble(arg1 float64) (_swig_ret string) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_fdouble, _swig_p) - return -} -var _wrap_num__SWIG_0 unsafe.Pointer - -func Num__SWIG_0(arg1 int) (_swig_ret string) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_num__SWIG_0, _swig_p) - return -} -var _wrap_num__SWIG_1 unsafe.Pointer - -func Num__SWIG_1(arg1 float64) (_swig_ret string) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_num__SWIG_1, _swig_p) - return -} -func Num(a ...interface{}) string { - argc := len(a) - if argc == 1 { - if _, ok := a[0].(int); !ok { - goto check_1 - } - return Num__SWIG_0(a[0].(int)) - } -check_1: - if argc == 1 { - return Num__SWIG_1(a[0].(float64)) - } - panic("No match for overloaded function call") -} - -var _wrap_fid__SWIG_0 unsafe.Pointer - -func Fid__SWIG_0(arg1 int, arg2 int) (_swig_ret string) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_fid__SWIG_0, _swig_p) - return -} -var _wrap_fid__SWIG_1 unsafe.Pointer - -func Fid__SWIG_1(arg1 int, arg2 float64) (_swig_ret string) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_fid__SWIG_1, _swig_p) - return -} -var _wrap_fid__SWIG_2 unsafe.Pointer - -func Fid__SWIG_2(arg1 float64, arg2 int) (_swig_ret string) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_fid__SWIG_2, _swig_p) - return -} -var _wrap_fid__SWIG_3 unsafe.Pointer - -func Fid__SWIG_3(arg1 float64, arg2 float64) (_swig_ret string) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_fid__SWIG_3, _swig_p) - return -} -func Fid(a ...interface{}) string { - argc := len(a) - if argc == 2 { - if _, ok := a[0].(int); !ok { - goto check_1 - } - if _, ok := a[1].(int); !ok { - goto check_1 - } - return Fid__SWIG_0(a[0].(int), a[1].(int)) - } -check_1: - if argc == 2 { - if _, ok := a[0].(int); !ok { - goto check_2 - } - if _, ok := a[1].(float64); !ok { - goto check_2 - } - return Fid__SWIG_1(a[0].(int), a[1].(float64)) - } -check_2: - if argc == 2 { - if _, ok := a[1].(int); !ok { - goto check_3 - } - return Fid__SWIG_2(a[0].(float64), a[1].(int)) - } -check_3: - if argc == 2 { - return Fid__SWIG_3(a[0].(float64), a[1].(float64)) - } - panic("No match for overloaded function call") -} - -var _wrap_ull__SWIG_0 unsafe.Pointer - -func Ull__SWIG_0() (_swig_ret uint64) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_ull__SWIG_0, _swig_p) - return -} -var _wrap_ull__SWIG_1 unsafe.Pointer - -func Ull__SWIG_1(arg1 uint64) (_swig_ret uint64) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_ull__SWIG_1, _swig_p) - return -} -func Ull(a ...interface{}) uint64 { - argc := len(a) - if argc == 0 { - return Ull__SWIG_0() - } - if argc == 1 { - return Ull__SWIG_1(a[0].(uint64)) - } - panic("No match for overloaded function call") -} - -var _wrap_ll__SWIG_0 unsafe.Pointer - -func Ll__SWIG_0() (_swig_ret int64) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_ll__SWIG_0, _swig_p) - return -} -var _wrap_ll__SWIG_1 unsafe.Pointer - -func Ll__SWIG_1(arg1 int64) (_swig_ret int64) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_ll__SWIG_1, _swig_p) - return -} -func Ll(a ...interface{}) int64 { - argc := len(a) - if argc == 0 { - return Ll__SWIG_0() - } - if argc == 1 { - return Ll__SWIG_1(a[0].(int64)) - } - panic("No match for overloaded function call") -} - -var _wrap_malloc_void unsafe.Pointer - -func Malloc_void(arg1 int) (_swig_ret uintptr) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_malloc_void, _swig_p) - return -} -var _wrap_free_void unsafe.Pointer - -func _swig_wrap_free_void(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_free_void, _swig_p) - return -} - -func Free_void(arg1 uintptr) { - _swig_wrap_free_void(arg1) -} - -type SwigcptrClassA uintptr - -func (p SwigcptrClassA) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrClassA) SwigIsClassA() { -} - -var _wrap_new_ClassA unsafe.Pointer - -func _swig_wrap_new_ClassA() (base SwigcptrClassA) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_ClassA, _swig_p) - return -} - -func NewClassA() (_swig_ret ClassA) { - return _swig_wrap_new_ClassA() -} - -var _wrap_ClassA_method1__SWIG_0 unsafe.Pointer - -func _swig_wrap_ClassA_method1__SWIG_0(base SwigcptrClassA) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_ClassA_method1__SWIG_0, _swig_p) - return -} - -func (arg1 SwigcptrClassA) Method1__SWIG_0() (_swig_ret int) { - return _swig_wrap_ClassA_method1__SWIG_0(arg1) -} - -var _wrap_ClassA_method1__SWIG_1 unsafe.Pointer - -func _swig_wrap_ClassA_method1__SWIG_1(base SwigcptrClassA, _ int) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_ClassA_method1__SWIG_1, _swig_p) - return -} - -func (arg1 SwigcptrClassA) Method1__SWIG_1(arg2 int) (_swig_ret int) { - return _swig_wrap_ClassA_method1__SWIG_1(arg1, arg2) -} - -func (p SwigcptrClassA) Method1(a ...interface{}) int { - argc := len(a) - if argc == 0 { - return p.Method1__SWIG_0() - } - if argc == 1 { - return p.Method1__SWIG_1(a[0].(int)) - } - panic("No match for overloaded function call") -} - -var _wrap_delete_ClassA unsafe.Pointer - -func _swig_wrap_delete_ClassA(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_ClassA, _swig_p) - return -} - -func DeleteClassA(arg1 ClassA) { - _swig_wrap_delete_ClassA(arg1.Swigcptr()) -} - -type ClassA interface { - Swigcptr() uintptr - SwigIsClassA() - Method1(a ...interface{}) int -} - -var _wrap_int_object__SWIG_0 unsafe.Pointer - -func _swig_wrap_int_object__SWIG_0(base uintptr) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_int_object__SWIG_0, _swig_p) - return -} - -func Int_object__SWIG_0(arg1 Spam) (_swig_ret int) { - return _swig_wrap_int_object__SWIG_0(arg1.Swigcptr()) -} - -var _wrap_int_object__SWIG_1 unsafe.Pointer - -func Int_object__SWIG_1(arg1 int) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_int_object__SWIG_1, _swig_p) - return -} -func Int_object(a ...interface{}) int { - argc := len(a) - if argc == 1 { - if _, ok := a[0].(Spam); !ok { - goto check_1 - } - return Int_object__SWIG_0(a[0].(Spam)) - } -check_1: - if argc == 1 { - return Int_object__SWIG_1(a[0].(int)) - } - panic("No match for overloaded function call") -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/overload_simple_runme b/Examples/test-suite/go/overload_simple_runme deleted file mode 100755 index 94cf3ce48..000000000 Binary files a/Examples/test-suite/go/overload_simple_runme and /dev/null differ diff --git a/Examples/test-suite/go/overload_subtype.go b/Examples/test-suite/go/overload_subtype.go deleted file mode 100644 index 37dbe4400..000000000 --- a/Examples/test-suite/go/overload_subtype.go +++ /dev/null @@ -1,161 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../overload_subtype.i - -package overload_subtype - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrFoo uintptr - -func (p SwigcptrFoo) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrFoo) SwigIsFoo() { -} - -var _wrap_new_Foo unsafe.Pointer - -func _swig_wrap_new_Foo() (base SwigcptrFoo) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Foo, _swig_p) - return -} - -func NewFoo() (_swig_ret Foo) { - return _swig_wrap_new_Foo() -} - -var _wrap_delete_Foo unsafe.Pointer - -func _swig_wrap_delete_Foo(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Foo, _swig_p) - return -} - -func DeleteFoo(arg1 Foo) { - _swig_wrap_delete_Foo(arg1.Swigcptr()) -} - -type Foo interface { - Swigcptr() uintptr - SwigIsFoo() -} - -type SwigcptrBar uintptr - -func (p SwigcptrBar) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrBar) SwigIsBar() { -} - -var _wrap_new_Bar unsafe.Pointer - -func _swig_wrap_new_Bar() (base SwigcptrBar) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Bar, _swig_p) - return -} - -func NewBar() (_swig_ret Bar) { - return _swig_wrap_new_Bar() -} - -var _wrap_delete_Bar unsafe.Pointer - -func _swig_wrap_delete_Bar(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Bar, _swig_p) - return -} - -func DeleteBar(arg1 Bar) { - _swig_wrap_delete_Bar(arg1.Swigcptr()) -} - -func (p SwigcptrBar) SwigIsFoo() { -} - -func (p SwigcptrBar) SwigGetFoo() Foo { - return SwigcptrFoo(p.Swigcptr()) -} - -type Bar interface { - Swigcptr() uintptr - SwigIsBar() - SwigIsFoo() - SwigGetFoo() Foo -} - -var _wrap_spam__SWIG_0 unsafe.Pointer - -func _swig_wrap_spam__SWIG_0(base uintptr) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_spam__SWIG_0, _swig_p) - return -} - -func Spam__SWIG_0(arg1 Foo) (_swig_ret int) { - return _swig_wrap_spam__SWIG_0(arg1.Swigcptr()) -} - -var _wrap_spam__SWIG_1 unsafe.Pointer - -func _swig_wrap_spam__SWIG_1(base uintptr) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_spam__SWIG_1, _swig_p) - return -} - -func Spam__SWIG_1(arg1 Bar) (_swig_ret int) { - return _swig_wrap_spam__SWIG_1(arg1.Swigcptr()) -} - -func Spam(a ...interface{}) int { - argc := len(a) - if argc == 1 { - if _, ok := a[0].(Bar); !ok { - goto check_1 - } - return Spam__SWIG_1(a[0].(Bar)) - } -check_1: - if argc == 1 { - return Spam__SWIG_0(a[0].(Foo)) - } - panic("No match for overloaded function call") -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/overload_subtype_runme b/Examples/test-suite/go/overload_subtype_runme deleted file mode 100755 index adf12382f..000000000 Binary files a/Examples/test-suite/go/overload_subtype_runme and /dev/null differ diff --git a/Examples/test-suite/go/overload_template.go b/Examples/test-suite/go/overload_template.go deleted file mode 100644 index 2d800049e..000000000 --- a/Examples/test-suite/go/overload_template.go +++ /dev/null @@ -1,1185 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../overload_template.i - -package overload_template - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -var _wrap_foo__SWIG_0 unsafe.Pointer - -func Foo__SWIG_0() (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_foo__SWIG_0, _swig_p) - return -} -var _wrap_foo__SWIG_2 unsafe.Pointer - -func Foo__SWIG_2(arg1 int) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_foo__SWIG_2, _swig_p) - return -} -var _wrap_foo__SWIG_3 unsafe.Pointer - -func Foo__SWIG_3(arg1 float64) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_foo__SWIG_3, _swig_p) - return -} -func Foo(a ...interface{}) int { - argc := len(a) - if argc == 0 { - return Foo__SWIG_0() - } - if argc == 1 { - if _, ok := a[0].(int); !ok { - goto check_2 - } - return Foo__SWIG_2(a[0].(int)) - } -check_2: - if argc == 1 { - return Foo__SWIG_3(a[0].(float64)) - } - panic("No match for overloaded function call") -} - -var _wrap_maximum__SWIG_1 unsafe.Pointer - -func Maximum__SWIG_1(arg1 int, arg2 int) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_maximum__SWIG_1, _swig_p) - return -} -var _wrap_maximum__SWIG_2 unsafe.Pointer - -func Maximum__SWIG_2(arg1 float64, arg2 float64) (_swig_ret float64) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_maximum__SWIG_2, _swig_p) - return -} -func Maximum(a ...interface{}) interface{} { - argc := len(a) - if argc == 2 { - if _, ok := a[0].(int); !ok { - goto check_1 - } - if _, ok := a[1].(int); !ok { - goto check_1 - } - return Maximum__SWIG_1(a[0].(int), a[1].(int)) - } -check_1: - if argc == 2 { - return Maximum__SWIG_2(a[0].(float64), a[1].(float64)) - } - panic("No match for overloaded function call") -} - -var _wrap_mix1__SWIG_0 unsafe.Pointer - -func Mix1__SWIG_0(arg1 string) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_mix1__SWIG_0, _swig_p) - return -} -var _wrap_mix1__SWIG_3 unsafe.Pointer - -func Mix1__SWIG_3(arg1 float64, arg2 float64) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_mix1__SWIG_3, _swig_p) - return -} -var _wrap_mix1__SWIG_4 unsafe.Pointer - -func Mix1__SWIG_4(arg1 float64) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_mix1__SWIG_4, _swig_p) - return -} -func Mix1(a ...interface{}) int { - argc := len(a) - if argc == 1 { - if _, ok := a[0].(float64); !ok { - goto check_1 - } - return Mix1__SWIG_4(a[0].(float64)) - } -check_1: - if argc == 1 { - return Mix1__SWIG_0(a[0].(string)) - } - if argc == 2 { - return Mix1__SWIG_3(a[0].(float64), a[1].(float64)) - } - panic("No match for overloaded function call") -} - -var _wrap_mix2__SWIG_1 unsafe.Pointer - -func Mix2__SWIG_1(arg1 string) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_mix2__SWIG_1, _swig_p) - return -} -var _wrap_mix2__SWIG_3 unsafe.Pointer - -func Mix2__SWIG_3(arg1 float64, arg2 float64) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_mix2__SWIG_3, _swig_p) - return -} -var _wrap_mix2__SWIG_4 unsafe.Pointer - -func Mix2__SWIG_4(arg1 float64) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_mix2__SWIG_4, _swig_p) - return -} -func Mix2(a ...interface{}) int { - argc := len(a) - if argc == 1 { - if _, ok := a[0].(float64); !ok { - goto check_1 - } - return Mix2__SWIG_4(a[0].(float64)) - } -check_1: - if argc == 1 { - return Mix2__SWIG_1(a[0].(string)) - } - if argc == 2 { - return Mix2__SWIG_3(a[0].(float64), a[1].(float64)) - } - panic("No match for overloaded function call") -} - -var _wrap_mix3__SWIG_2 unsafe.Pointer - -func Mix3__SWIG_2(arg1 string) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_mix3__SWIG_2, _swig_p) - return -} -var _wrap_mix3__SWIG_3 unsafe.Pointer - -func Mix3__SWIG_3(arg1 float64, arg2 float64) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_mix3__SWIG_3, _swig_p) - return -} -var _wrap_mix3__SWIG_4 unsafe.Pointer - -func Mix3__SWIG_4(arg1 float64) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_mix3__SWIG_4, _swig_p) - return -} -func Mix3(a ...interface{}) int { - argc := len(a) - if argc == 1 { - if _, ok := a[0].(float64); !ok { - goto check_1 - } - return Mix3__SWIG_4(a[0].(float64)) - } -check_1: - if argc == 1 { - return Mix3__SWIG_2(a[0].(string)) - } - if argc == 2 { - return Mix3__SWIG_3(a[0].(float64), a[1].(float64)) - } - panic("No match for overloaded function call") -} - -var _wrap_overtparams1__SWIG_2 unsafe.Pointer - -func Overtparams1__SWIG_2(arg1 int) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_overtparams1__SWIG_2, _swig_p) - return -} -var _wrap_overtparams1__SWIG_3 unsafe.Pointer - -func Overtparams1__SWIG_3(arg1 float64, arg2 int) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_overtparams1__SWIG_3, _swig_p) - return -} -func Overtparams1(a ...interface{}) int { - argc := len(a) - if argc == 1 { - return Overtparams1__SWIG_2(a[0].(int)) - } - if argc == 2 { - return Overtparams1__SWIG_3(a[0].(float64), a[1].(int)) - } - panic("No match for overloaded function call") -} - -var _wrap_overtparams2 unsafe.Pointer - -func Overtparams2(arg1 float64, arg2 int) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_overtparams2, _swig_p) - return -} -var _wrap_overloaded__SWIG_1 unsafe.Pointer - -func Overloaded__SWIG_1() (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_overloaded__SWIG_1, _swig_p) - return -} -var _wrap_overloaded__SWIG_3 unsafe.Pointer - -func Overloaded__SWIG_3(arg1 float64, arg2 int) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_overloaded__SWIG_3, _swig_p) - return -} -func Overloaded(a ...interface{}) int { - argc := len(a) - if argc == 0 { - return Overloaded__SWIG_1() - } - if argc == 2 { - return Overloaded__SWIG_3(a[0].(float64), a[1].(int)) - } - panic("No match for overloaded function call") -} - -var _wrap_overloadedagain__SWIG_0 unsafe.Pointer - -func Overloadedagain__SWIG_0(arg1 string) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_overloadedagain__SWIG_0, _swig_p) - return -} -var _wrap_overloadedagain__SWIG_3 unsafe.Pointer - -func Overloadedagain__SWIG_3() (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_overloadedagain__SWIG_3, _swig_p) - return -} -func Overloadedagain(a ...interface{}) int { - argc := len(a) - if argc == 0 { - return Overloadedagain__SWIG_3() - } - if argc == 1 { - return Overloadedagain__SWIG_0(a[0].(string)) - } - panic("No match for overloaded function call") -} - -var _wrap_xyz unsafe.Pointer - -func _swig_wrap_xyz() { - var _swig_p uintptr - _cgo_runtime_cgocall(_wrap_xyz, _swig_p) - return -} - -func Xyz() { - _swig_wrap_xyz() -} - -var _wrap_xyz_double unsafe.Pointer - -func _swig_wrap_xyz_double() { - var _swig_p uintptr - _cgo_runtime_cgocall(_wrap_xyz_double, _swig_p) - return -} - -func Xyz_double() { - _swig_wrap_xyz_double() -} - -var _wrap_xyz_int unsafe.Pointer - -func _swig_wrap_xyz_int() { - var _swig_p uintptr - _cgo_runtime_cgocall(_wrap_xyz_int, _swig_p) - return -} - -func Xyz_int() { - _swig_wrap_xyz_int() -} - -var _wrap_specialization__SWIG_4 unsafe.Pointer - -func Specialization__SWIG_4(arg1 int) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_specialization__SWIG_4, _swig_p) - return -} -var _wrap_specialization__SWIG_5 unsafe.Pointer - -func Specialization__SWIG_5(arg1 float64) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_specialization__SWIG_5, _swig_p) - return -} -var _wrap_specialization__SWIG_6 unsafe.Pointer - -func Specialization__SWIG_6(arg1 int, arg2 int) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_specialization__SWIG_6, _swig_p) - return -} -var _wrap_specialization__SWIG_7 unsafe.Pointer - -func Specialization__SWIG_7(arg1 float64, arg2 float64) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_specialization__SWIG_7, _swig_p) - return -} -var _wrap_specialization__SWIG_8 unsafe.Pointer - -func Specialization__SWIG_8(arg1 string, arg2 string) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_specialization__SWIG_8, _swig_p) - return -} -func Specialization(a ...interface{}) int { - argc := len(a) - if argc == 1 { - if _, ok := a[0].(int); !ok { - goto check_1 - } - return Specialization__SWIG_4(a[0].(int)) - } -check_1: - if argc == 1 { - return Specialization__SWIG_5(a[0].(float64)) - } - if argc == 2 { - if _, ok := a[0].(int); !ok { - goto check_3 - } - if _, ok := a[1].(int); !ok { - goto check_3 - } - return Specialization__SWIG_6(a[0].(int), a[1].(int)) - } -check_3: - if argc == 2 { - if _, ok := a[0].(float64); !ok { - goto check_4 - } - if _, ok := a[1].(float64); !ok { - goto check_4 - } - return Specialization__SWIG_7(a[0].(float64), a[1].(float64)) - } -check_4: - if argc == 2 { - return Specialization__SWIG_8(a[0].(string), a[1].(string)) - } - panic("No match for overloaded function call") -} - -var _wrap_overload__SWIG_0 unsafe.Pointer - -func Overload__SWIG_0(arg1 string) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_overload__SWIG_0, _swig_p) - return -} -var _wrap_overload__SWIG_4 unsafe.Pointer - -func Overload__SWIG_4() (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_overload__SWIG_4, _swig_p) - return -} -type SwigcptrKlass uintptr - -func (p SwigcptrKlass) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrKlass) SwigIsKlass() { -} - -var _wrap_new_Klass unsafe.Pointer - -func _swig_wrap_new_Klass() (base SwigcptrKlass) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Klass, _swig_p) - return -} - -func NewKlass() (_swig_ret Klass) { - return _swig_wrap_new_Klass() -} - -var _wrap_delete_Klass unsafe.Pointer - -func _swig_wrap_delete_Klass(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Klass, _swig_p) - return -} - -func DeleteKlass(arg1 Klass) { - _swig_wrap_delete_Klass(arg1.Swigcptr()) -} - -type Klass interface { - Swigcptr() uintptr - SwigIsKlass() -} - -var _wrap_overload__SWIG_5 unsafe.Pointer - -func Overload__SWIG_5(arg1 int) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_overload__SWIG_5, _swig_p) - return -} -var _wrap_overload__SWIG_6 unsafe.Pointer - -func Overload__SWIG_6(arg1 int, arg2 int) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_overload__SWIG_6, _swig_p) - return -} -var _wrap_overload__SWIG_7 unsafe.Pointer - -func Overload__SWIG_7(arg1 int, arg2 string) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_overload__SWIG_7, _swig_p) - return -} -var _wrap_overload__SWIG_8 unsafe.Pointer - -func _swig_wrap_overload__SWIG_8(base uintptr) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_overload__SWIG_8, _swig_p) - return -} - -func Overload__SWIG_8(arg1 Klass) (_swig_ret int) { - return _swig_wrap_overload__SWIG_8(arg1.Swigcptr()) -} - -var _wrap_overload__SWIG_9 unsafe.Pointer - -func _swig_wrap_overload__SWIG_9(base uintptr, _ uintptr) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_overload__SWIG_9, _swig_p) - return -} - -func Overload__SWIG_9(arg1 Klass, arg2 Klass) (_swig_ret int) { - return _swig_wrap_overload__SWIG_9(arg1.Swigcptr(), arg2.Swigcptr()) -} - -var _wrap_overload__SWIG_10 unsafe.Pointer - -func _swig_wrap_overload__SWIG_10(base uintptr, _ string) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_overload__SWIG_10, _swig_p) - return -} - -func Overload__SWIG_10(arg1 Klass, arg2 string) (_swig_ret int) { - return _swig_wrap_overload__SWIG_10(arg1.Swigcptr(), arg2) -} - -var _wrap_overload__SWIG_11 unsafe.Pointer - -func Overload__SWIG_11(arg1 float64) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_overload__SWIG_11, _swig_p) - return -} -var _wrap_overload__SWIG_12 unsafe.Pointer - -func Overload__SWIG_12(arg1 float64, arg2 float64) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_overload__SWIG_12, _swig_p) - return -} -var _wrap_overload__SWIG_13 unsafe.Pointer - -func Overload__SWIG_13(arg1 float64, arg2 string) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_overload__SWIG_13, _swig_p) - return -} -func Overload(a ...interface{}) int { - argc := len(a) - if argc == 0 { - return Overload__SWIG_4() - } - if argc == 1 { - if _, ok := a[0].(Klass); !ok { - goto check_2 - } - return Overload__SWIG_8(a[0].(Klass)) - } -check_2: - if argc == 1 { - if _, ok := a[0].(int); !ok { - goto check_3 - } - return Overload__SWIG_5(a[0].(int)) - } -check_3: - if argc == 1 { - if _, ok := a[0].(float64); !ok { - goto check_4 - } - return Overload__SWIG_11(a[0].(float64)) - } -check_4: - if argc == 1 { - return Overload__SWIG_0(a[0].(string)) - } - if argc == 2 { - if _, ok := a[0].(Klass); !ok { - goto check_6 - } - if _, ok := a[1].(Klass); !ok { - goto check_6 - } - return Overload__SWIG_9(a[0].(Klass), a[1].(Klass)) - } -check_6: - if argc == 2 { - if _, ok := a[0].(Klass); !ok { - goto check_7 - } - if _, ok := a[1].(string); !ok { - goto check_7 - } - return Overload__SWIG_10(a[0].(Klass), a[1].(string)) - } -check_7: - if argc == 2 { - if _, ok := a[0].(int); !ok { - goto check_8 - } - if _, ok := a[1].(int); !ok { - goto check_8 - } - return Overload__SWIG_6(a[0].(int), a[1].(int)) - } -check_8: - if argc == 2 { - if _, ok := a[0].(int); !ok { - goto check_9 - } - if _, ok := a[1].(string); !ok { - goto check_9 - } - return Overload__SWIG_7(a[0].(int), a[1].(string)) - } -check_9: - if argc == 2 { - if _, ok := a[1].(float64); !ok { - goto check_10 - } - return Overload__SWIG_12(a[0].(float64), a[1].(float64)) - } -check_10: - if argc == 2 { - return Overload__SWIG_13(a[0].(float64), a[1].(string)) - } - panic("No match for overloaded function call") -} - -var _wrap_nsoverload__SWIG_0 unsafe.Pointer - -func Nsoverload__SWIG_0(arg1 string) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_nsoverload__SWIG_0, _swig_p) - return -} -var _wrap_nsoverload__SWIG_4 unsafe.Pointer - -func Nsoverload__SWIG_4() (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_nsoverload__SWIG_4, _swig_p) - return -} -var _wrap_nsoverload__SWIG_5 unsafe.Pointer - -func Nsoverload__SWIG_5(arg1 int) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_nsoverload__SWIG_5, _swig_p) - return -} -var _wrap_nsoverload__SWIG_6 unsafe.Pointer - -func Nsoverload__SWIG_6(arg1 int, arg2 int) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_nsoverload__SWIG_6, _swig_p) - return -} -var _wrap_nsoverload__SWIG_7 unsafe.Pointer - -func Nsoverload__SWIG_7(arg1 int, arg2 string) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_nsoverload__SWIG_7, _swig_p) - return -} -var _wrap_nsoverload__SWIG_8 unsafe.Pointer - -func _swig_wrap_nsoverload__SWIG_8(base uintptr) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_nsoverload__SWIG_8, _swig_p) - return -} - -func Nsoverload__SWIG_8(arg1 Klass) (_swig_ret int) { - return _swig_wrap_nsoverload__SWIG_8(arg1.Swigcptr()) -} - -var _wrap_nsoverload__SWIG_9 unsafe.Pointer - -func _swig_wrap_nsoverload__SWIG_9(base uintptr, _ uintptr) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_nsoverload__SWIG_9, _swig_p) - return -} - -func Nsoverload__SWIG_9(arg1 Klass, arg2 Klass) (_swig_ret int) { - return _swig_wrap_nsoverload__SWIG_9(arg1.Swigcptr(), arg2.Swigcptr()) -} - -var _wrap_nsoverload__SWIG_10 unsafe.Pointer - -func _swig_wrap_nsoverload__SWIG_10(base uintptr, _ string) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_nsoverload__SWIG_10, _swig_p) - return -} - -func Nsoverload__SWIG_10(arg1 Klass, arg2 string) (_swig_ret int) { - return _swig_wrap_nsoverload__SWIG_10(arg1.Swigcptr(), arg2) -} - -var _wrap_nsoverload__SWIG_11 unsafe.Pointer - -func Nsoverload__SWIG_11(arg1 float64) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_nsoverload__SWIG_11, _swig_p) - return -} -var _wrap_nsoverload__SWIG_12 unsafe.Pointer - -func Nsoverload__SWIG_12(arg1 float64, arg2 float64) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_nsoverload__SWIG_12, _swig_p) - return -} -var _wrap_nsoverload__SWIG_13 unsafe.Pointer - -func Nsoverload__SWIG_13(arg1 float64, arg2 string) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_nsoverload__SWIG_13, _swig_p) - return -} -func Nsoverload(a ...interface{}) int { - argc := len(a) - if argc == 0 { - return Nsoverload__SWIG_4() - } - if argc == 1 { - if _, ok := a[0].(Klass); !ok { - goto check_2 - } - return Nsoverload__SWIG_8(a[0].(Klass)) - } -check_2: - if argc == 1 { - if _, ok := a[0].(int); !ok { - goto check_3 - } - return Nsoverload__SWIG_5(a[0].(int)) - } -check_3: - if argc == 1 { - if _, ok := a[0].(float64); !ok { - goto check_4 - } - return Nsoverload__SWIG_11(a[0].(float64)) - } -check_4: - if argc == 1 { - return Nsoverload__SWIG_0(a[0].(string)) - } - if argc == 2 { - if _, ok := a[0].(Klass); !ok { - goto check_6 - } - if _, ok := a[1].(Klass); !ok { - goto check_6 - } - return Nsoverload__SWIG_9(a[0].(Klass), a[1].(Klass)) - } -check_6: - if argc == 2 { - if _, ok := a[0].(Klass); !ok { - goto check_7 - } - if _, ok := a[1].(string); !ok { - goto check_7 - } - return Nsoverload__SWIG_10(a[0].(Klass), a[1].(string)) - } -check_7: - if argc == 2 { - if _, ok := a[0].(int); !ok { - goto check_8 - } - if _, ok := a[1].(int); !ok { - goto check_8 - } - return Nsoverload__SWIG_6(a[0].(int), a[1].(int)) - } -check_8: - if argc == 2 { - if _, ok := a[0].(int); !ok { - goto check_9 - } - if _, ok := a[1].(string); !ok { - goto check_9 - } - return Nsoverload__SWIG_7(a[0].(int), a[1].(string)) - } -check_9: - if argc == 2 { - if _, ok := a[1].(float64); !ok { - goto check_10 - } - return Nsoverload__SWIG_12(a[0].(float64), a[1].(float64)) - } -check_10: - if argc == 2 { - return Nsoverload__SWIG_13(a[0].(float64), a[1].(string)) - } - panic("No match for overloaded function call") -} - -type SwigcptrA uintptr - -func (p SwigcptrA) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrA) SwigIsA() { -} - -var _wrap_A_foo__SWIG_0 unsafe.Pointer - -func _swig_wrap_A_foo__SWIG_0(base float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_A_foo__SWIG_0, _swig_p) - return -} - -func AFoo__SWIG_0(arg1 float64) { - _swig_wrap_A_foo__SWIG_0(arg1) -} - -var _wrap_A_foo__SWIG_1 unsafe.Pointer - -func _swig_wrap_A_foo__SWIG_1(base int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_A_foo__SWIG_1, _swig_p) - return -} - -func AFoo__SWIG_1(arg1 int) { - _swig_wrap_A_foo__SWIG_1(arg1) -} - -var _wrap_A_foo__SWIG_2 unsafe.Pointer - -func _swig_wrap_A_foo__SWIG_2(base byte) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_A_foo__SWIG_2, _swig_p) - return -} - -func AFoo__SWIG_2(arg1 byte) { - _swig_wrap_A_foo__SWIG_2(arg1) -} - -func AFoo(a ...interface{}) { - argc := len(a) - if argc == 1 { - if _, ok := a[0].(int); !ok { - goto check_1 - } - AFoo__SWIG_1(a[0].(int)) - return - } -check_1: - if argc == 1 { - if _, ok := a[0].(float64); !ok { - goto check_2 - } - AFoo__SWIG_0(a[0].(float64)) - return - } -check_2: - if argc == 1 { - AFoo__SWIG_2(a[0].(byte)) - return - } - panic("No match for overloaded function call") -} - -var _wrap_new_A unsafe.Pointer - -func _swig_wrap_new_A() (base SwigcptrA) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_A, _swig_p) - return -} - -func NewA() (_swig_ret A) { - return _swig_wrap_new_A() -} - -var _wrap_delete_A unsafe.Pointer - -func _swig_wrap_delete_A(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_A, _swig_p) - return -} - -func DeleteA(arg1 A) { - _swig_wrap_delete_A(arg1.Swigcptr()) -} - -type A interface { - Swigcptr() uintptr - SwigIsA() -} - -type SwigcptrB uintptr - -func (p SwigcptrB) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrB) SwigIsB() { -} - -var _wrap_B_foo__SWIG_0 unsafe.Pointer - -func _swig_wrap_B_foo__SWIG_0(base SwigcptrB, _ float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_B_foo__SWIG_0, _swig_p) - return -} - -func (arg1 SwigcptrB) Foo__SWIG_0(arg2 float64) { - _swig_wrap_B_foo__SWIG_0(arg1, arg2) -} - -var _wrap_B_foo__SWIG_1 unsafe.Pointer - -func _swig_wrap_B_foo__SWIG_1(base SwigcptrB, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_B_foo__SWIG_1, _swig_p) - return -} - -func (arg1 SwigcptrB) Foo__SWIG_1(arg2 int) { - _swig_wrap_B_foo__SWIG_1(arg1, arg2) -} - -var _wrap_B_foo__SWIG_2 unsafe.Pointer - -func _swig_wrap_B_foo__SWIG_2(base SwigcptrB, _ byte) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_B_foo__SWIG_2, _swig_p) - return -} - -func (arg1 SwigcptrB) Foo__SWIG_2(arg2 byte) { - _swig_wrap_B_foo__SWIG_2(arg1, arg2) -} - -func (p SwigcptrB) Foo(a ...interface{}) { - argc := len(a) - if argc == 1 { - if _, ok := a[0].(int); !ok { - goto check_1 - } - p.Foo__SWIG_1(a[0].(int)) - return - } -check_1: - if argc == 1 { - if _, ok := a[0].(float64); !ok { - goto check_2 - } - p.Foo__SWIG_0(a[0].(float64)) - return - } -check_2: - if argc == 1 { - p.Foo__SWIG_2(a[0].(byte)) - return - } - panic("No match for overloaded function call") -} - -var _wrap_new_B unsafe.Pointer - -func _swig_wrap_new_B() (base SwigcptrB) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_B, _swig_p) - return -} - -func NewB() (_swig_ret B) { - return _swig_wrap_new_B() -} - -var _wrap_delete_B unsafe.Pointer - -func _swig_wrap_delete_B(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_B, _swig_p) - return -} - -func DeleteB(arg1 B) { - _swig_wrap_delete_B(arg1.Swigcptr()) -} - -type B interface { - Swigcptr() uintptr - SwigIsB() - Foo(a ...interface{}) -} - -type SwigcptrBar_d uintptr - -func (p SwigcptrBar_d) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrBar_d) SwigIsBar_d() { -} - -var _wrap_Bar_d_foo__SWIG_0 unsafe.Pointer - -func _swig_wrap_Bar_d_foo__SWIG_0(base SwigcptrBar_d, _ float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Bar_d_foo__SWIG_0, _swig_p) - return -} - -func (arg1 SwigcptrBar_d) Foo__SWIG_0(arg2 float64) { - _swig_wrap_Bar_d_foo__SWIG_0(arg1, arg2) -} - -var _wrap_Bar_d_foo__SWIG_1 unsafe.Pointer - -func _swig_wrap_Bar_d_foo__SWIG_1(base SwigcptrBar_d, _ float64, _ float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Bar_d_foo__SWIG_1, _swig_p) - return -} - -func (arg1 SwigcptrBar_d) Foo__SWIG_1(arg2 float64, arg3 float64) { - _swig_wrap_Bar_d_foo__SWIG_1(arg1, arg2, arg3) -} - -var _wrap_Bar_d_foo__SWIG_2 unsafe.Pointer - -func _swig_wrap_Bar_d_foo__SWIG_2(base SwigcptrBar_d, _ int, _ int, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Bar_d_foo__SWIG_2, _swig_p) - return -} - -func (arg1 SwigcptrBar_d) Foo__SWIG_2(arg2 int, arg3 int, arg4 int) { - _swig_wrap_Bar_d_foo__SWIG_2(arg1, arg2, arg3, arg4) -} - -func (p SwigcptrBar_d) Foo(a ...interface{}) { - argc := len(a) - if argc == 1 { - p.Foo__SWIG_0(a[0].(float64)) - return - } - if argc == 2 { - p.Foo__SWIG_1(a[0].(float64), a[1].(float64)) - return - } - if argc == 3 { - p.Foo__SWIG_2(a[0].(int), a[1].(int), a[2].(int)) - return - } - panic("No match for overloaded function call") -} - -var _wrap_new_Bar_d unsafe.Pointer - -func _swig_wrap_new_Bar_d() (base SwigcptrBar_d) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Bar_d, _swig_p) - return -} - -func NewBar_d() (_swig_ret Bar_d) { - return _swig_wrap_new_Bar_d() -} - -var _wrap_delete_Bar_d unsafe.Pointer - -func _swig_wrap_delete_Bar_d(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Bar_d, _swig_p) - return -} - -func DeleteBar_d(arg1 Bar_d) { - _swig_wrap_delete_Bar_d(arg1.Swigcptr()) -} - -type Bar_d interface { - Swigcptr() uintptr - SwigIsBar_d() - Foo(a ...interface{}) -} - -type SwigcptrFoo_d uintptr - -func (p SwigcptrFoo_d) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrFoo_d) SwigIsFoo_d() { -} - -var _wrap_Foo_d_bar__SWIG_0 unsafe.Pointer - -func _swig_wrap_Foo_d_bar__SWIG_0(base SwigcptrFoo_d, _ float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_d_bar__SWIG_0, _swig_p) - return -} - -func (arg1 SwigcptrFoo_d) Bar__SWIG_0(arg2 float64) { - _swig_wrap_Foo_d_bar__SWIG_0(arg1, arg2) -} - -var _wrap_Foo_d_bar__SWIG_1 unsafe.Pointer - -func _swig_wrap_Foo_d_bar__SWIG_1(base SwigcptrFoo_d, _ float64, _ float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_d_bar__SWIG_1, _swig_p) - return -} - -func (arg1 SwigcptrFoo_d) Bar__SWIG_1(arg2 float64, arg3 float64) { - _swig_wrap_Foo_d_bar__SWIG_1(arg1, arg2, arg3) -} - -var _wrap_Foo_d_bar__SWIG_2 unsafe.Pointer - -func _swig_wrap_Foo_d_bar__SWIG_2(base SwigcptrFoo_d, _ int, _ int, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_d_bar__SWIG_2, _swig_p) - return -} - -func (arg1 SwigcptrFoo_d) Bar__SWIG_2(arg2 int, arg3 int, arg4 int) { - _swig_wrap_Foo_d_bar__SWIG_2(arg1, arg2, arg3, arg4) -} - -func (p SwigcptrFoo_d) Bar(a ...interface{}) { - argc := len(a) - if argc == 1 { - p.Bar__SWIG_0(a[0].(float64)) - return - } - if argc == 2 { - p.Bar__SWIG_1(a[0].(float64), a[1].(float64)) - return - } - if argc == 3 { - p.Bar__SWIG_2(a[0].(int), a[1].(int), a[2].(int)) - return - } - panic("No match for overloaded function call") -} - -var _wrap_new_Foo_d unsafe.Pointer - -func _swig_wrap_new_Foo_d() (base SwigcptrFoo_d) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Foo_d, _swig_p) - return -} - -func NewFoo_d() (_swig_ret Foo_d) { - return _swig_wrap_new_Foo_d() -} - -var _wrap_delete_Foo_d unsafe.Pointer - -func _swig_wrap_delete_Foo_d(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Foo_d, _swig_p) - return -} - -func DeleteFoo_d(arg1 Foo_d) { - _swig_wrap_delete_Foo_d(arg1.Swigcptr()) -} - -type Foo_d interface { - Swigcptr() uintptr - SwigIsFoo_d() - Bar(a ...interface{}) -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/overload_template_fast.go b/Examples/test-suite/go/overload_template_fast.go deleted file mode 100644 index 0bfd3a5b6..000000000 --- a/Examples/test-suite/go/overload_template_fast.go +++ /dev/null @@ -1,1185 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../overload_template_fast.i - -package overload_template_fast - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -var _wrap_foo__SWIG_0 unsafe.Pointer - -func Foo__SWIG_0() (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_foo__SWIG_0, _swig_p) - return -} -var _wrap_foo__SWIG_2 unsafe.Pointer - -func Foo__SWIG_2(arg1 int) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_foo__SWIG_2, _swig_p) - return -} -var _wrap_foo__SWIG_3 unsafe.Pointer - -func Foo__SWIG_3(arg1 float64) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_foo__SWIG_3, _swig_p) - return -} -func Foo(a ...interface{}) int { - argc := len(a) - if argc == 0 { - return Foo__SWIG_0() - } - if argc == 1 { - if _, ok := a[0].(int); !ok { - goto check_2 - } - return Foo__SWIG_2(a[0].(int)) - } -check_2: - if argc == 1 { - return Foo__SWIG_3(a[0].(float64)) - } - panic("No match for overloaded function call") -} - -var _wrap_maximum__SWIG_1 unsafe.Pointer - -func Maximum__SWIG_1(arg1 int, arg2 int) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_maximum__SWIG_1, _swig_p) - return -} -var _wrap_maximum__SWIG_2 unsafe.Pointer - -func Maximum__SWIG_2(arg1 float64, arg2 float64) (_swig_ret float64) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_maximum__SWIG_2, _swig_p) - return -} -func Maximum(a ...interface{}) interface{} { - argc := len(a) - if argc == 2 { - if _, ok := a[0].(int); !ok { - goto check_1 - } - if _, ok := a[1].(int); !ok { - goto check_1 - } - return Maximum__SWIG_1(a[0].(int), a[1].(int)) - } -check_1: - if argc == 2 { - return Maximum__SWIG_2(a[0].(float64), a[1].(float64)) - } - panic("No match for overloaded function call") -} - -var _wrap_mix1__SWIG_0 unsafe.Pointer - -func Mix1__SWIG_0(arg1 string) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_mix1__SWIG_0, _swig_p) - return -} -var _wrap_mix1__SWIG_3 unsafe.Pointer - -func Mix1__SWIG_3(arg1 float64, arg2 float64) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_mix1__SWIG_3, _swig_p) - return -} -var _wrap_mix1__SWIG_4 unsafe.Pointer - -func Mix1__SWIG_4(arg1 float64) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_mix1__SWIG_4, _swig_p) - return -} -func Mix1(a ...interface{}) int { - argc := len(a) - if argc == 1 { - if _, ok := a[0].(float64); !ok { - goto check_1 - } - return Mix1__SWIG_4(a[0].(float64)) - } -check_1: - if argc == 1 { - return Mix1__SWIG_0(a[0].(string)) - } - if argc == 2 { - return Mix1__SWIG_3(a[0].(float64), a[1].(float64)) - } - panic("No match for overloaded function call") -} - -var _wrap_mix2__SWIG_1 unsafe.Pointer - -func Mix2__SWIG_1(arg1 string) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_mix2__SWIG_1, _swig_p) - return -} -var _wrap_mix2__SWIG_3 unsafe.Pointer - -func Mix2__SWIG_3(arg1 float64, arg2 float64) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_mix2__SWIG_3, _swig_p) - return -} -var _wrap_mix2__SWIG_4 unsafe.Pointer - -func Mix2__SWIG_4(arg1 float64) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_mix2__SWIG_4, _swig_p) - return -} -func Mix2(a ...interface{}) int { - argc := len(a) - if argc == 1 { - if _, ok := a[0].(float64); !ok { - goto check_1 - } - return Mix2__SWIG_4(a[0].(float64)) - } -check_1: - if argc == 1 { - return Mix2__SWIG_1(a[0].(string)) - } - if argc == 2 { - return Mix2__SWIG_3(a[0].(float64), a[1].(float64)) - } - panic("No match for overloaded function call") -} - -var _wrap_mix3__SWIG_2 unsafe.Pointer - -func Mix3__SWIG_2(arg1 string) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_mix3__SWIG_2, _swig_p) - return -} -var _wrap_mix3__SWIG_3 unsafe.Pointer - -func Mix3__SWIG_3(arg1 float64, arg2 float64) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_mix3__SWIG_3, _swig_p) - return -} -var _wrap_mix3__SWIG_4 unsafe.Pointer - -func Mix3__SWIG_4(arg1 float64) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_mix3__SWIG_4, _swig_p) - return -} -func Mix3(a ...interface{}) int { - argc := len(a) - if argc == 1 { - if _, ok := a[0].(float64); !ok { - goto check_1 - } - return Mix3__SWIG_4(a[0].(float64)) - } -check_1: - if argc == 1 { - return Mix3__SWIG_2(a[0].(string)) - } - if argc == 2 { - return Mix3__SWIG_3(a[0].(float64), a[1].(float64)) - } - panic("No match for overloaded function call") -} - -var _wrap_overtparams1__SWIG_2 unsafe.Pointer - -func Overtparams1__SWIG_2(arg1 int) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_overtparams1__SWIG_2, _swig_p) - return -} -var _wrap_overtparams1__SWIG_3 unsafe.Pointer - -func Overtparams1__SWIG_3(arg1 float64, arg2 int) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_overtparams1__SWIG_3, _swig_p) - return -} -func Overtparams1(a ...interface{}) int { - argc := len(a) - if argc == 1 { - return Overtparams1__SWIG_2(a[0].(int)) - } - if argc == 2 { - return Overtparams1__SWIG_3(a[0].(float64), a[1].(int)) - } - panic("No match for overloaded function call") -} - -var _wrap_overtparams2 unsafe.Pointer - -func Overtparams2(arg1 float64, arg2 int) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_overtparams2, _swig_p) - return -} -var _wrap_overloaded__SWIG_1 unsafe.Pointer - -func Overloaded__SWIG_1() (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_overloaded__SWIG_1, _swig_p) - return -} -var _wrap_overloaded__SWIG_3 unsafe.Pointer - -func Overloaded__SWIG_3(arg1 float64, arg2 int) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_overloaded__SWIG_3, _swig_p) - return -} -func Overloaded(a ...interface{}) int { - argc := len(a) - if argc == 0 { - return Overloaded__SWIG_1() - } - if argc == 2 { - return Overloaded__SWIG_3(a[0].(float64), a[1].(int)) - } - panic("No match for overloaded function call") -} - -var _wrap_overloadedagain__SWIG_0 unsafe.Pointer - -func Overloadedagain__SWIG_0(arg1 string) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_overloadedagain__SWIG_0, _swig_p) - return -} -var _wrap_overloadedagain__SWIG_3 unsafe.Pointer - -func Overloadedagain__SWIG_3() (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_overloadedagain__SWIG_3, _swig_p) - return -} -func Overloadedagain(a ...interface{}) int { - argc := len(a) - if argc == 0 { - return Overloadedagain__SWIG_3() - } - if argc == 1 { - return Overloadedagain__SWIG_0(a[0].(string)) - } - panic("No match for overloaded function call") -} - -var _wrap_xyz unsafe.Pointer - -func _swig_wrap_xyz() { - var _swig_p uintptr - _cgo_runtime_cgocall(_wrap_xyz, _swig_p) - return -} - -func Xyz() { - _swig_wrap_xyz() -} - -var _wrap_xyz_double unsafe.Pointer - -func _swig_wrap_xyz_double() { - var _swig_p uintptr - _cgo_runtime_cgocall(_wrap_xyz_double, _swig_p) - return -} - -func Xyz_double() { - _swig_wrap_xyz_double() -} - -var _wrap_xyz_int unsafe.Pointer - -func _swig_wrap_xyz_int() { - var _swig_p uintptr - _cgo_runtime_cgocall(_wrap_xyz_int, _swig_p) - return -} - -func Xyz_int() { - _swig_wrap_xyz_int() -} - -var _wrap_specialization__SWIG_4 unsafe.Pointer - -func Specialization__SWIG_4(arg1 int) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_specialization__SWIG_4, _swig_p) - return -} -var _wrap_specialization__SWIG_5 unsafe.Pointer - -func Specialization__SWIG_5(arg1 float64) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_specialization__SWIG_5, _swig_p) - return -} -var _wrap_specialization__SWIG_6 unsafe.Pointer - -func Specialization__SWIG_6(arg1 int, arg2 int) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_specialization__SWIG_6, _swig_p) - return -} -var _wrap_specialization__SWIG_7 unsafe.Pointer - -func Specialization__SWIG_7(arg1 float64, arg2 float64) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_specialization__SWIG_7, _swig_p) - return -} -var _wrap_specialization__SWIG_8 unsafe.Pointer - -func Specialization__SWIG_8(arg1 string, arg2 string) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_specialization__SWIG_8, _swig_p) - return -} -func Specialization(a ...interface{}) int { - argc := len(a) - if argc == 1 { - if _, ok := a[0].(int); !ok { - goto check_1 - } - return Specialization__SWIG_4(a[0].(int)) - } -check_1: - if argc == 1 { - return Specialization__SWIG_5(a[0].(float64)) - } - if argc == 2 { - if _, ok := a[0].(int); !ok { - goto check_3 - } - if _, ok := a[1].(int); !ok { - goto check_3 - } - return Specialization__SWIG_6(a[0].(int), a[1].(int)) - } -check_3: - if argc == 2 { - if _, ok := a[0].(float64); !ok { - goto check_4 - } - if _, ok := a[1].(float64); !ok { - goto check_4 - } - return Specialization__SWIG_7(a[0].(float64), a[1].(float64)) - } -check_4: - if argc == 2 { - return Specialization__SWIG_8(a[0].(string), a[1].(string)) - } - panic("No match for overloaded function call") -} - -var _wrap_overload__SWIG_0 unsafe.Pointer - -func Overload__SWIG_0(arg1 string) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_overload__SWIG_0, _swig_p) - return -} -var _wrap_overload__SWIG_4 unsafe.Pointer - -func Overload__SWIG_4() (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_overload__SWIG_4, _swig_p) - return -} -type SwigcptrKlass uintptr - -func (p SwigcptrKlass) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrKlass) SwigIsKlass() { -} - -var _wrap_new_Klass unsafe.Pointer - -func _swig_wrap_new_Klass() (base SwigcptrKlass) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Klass, _swig_p) - return -} - -func NewKlass() (_swig_ret Klass) { - return _swig_wrap_new_Klass() -} - -var _wrap_delete_Klass unsafe.Pointer - -func _swig_wrap_delete_Klass(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Klass, _swig_p) - return -} - -func DeleteKlass(arg1 Klass) { - _swig_wrap_delete_Klass(arg1.Swigcptr()) -} - -type Klass interface { - Swigcptr() uintptr - SwigIsKlass() -} - -var _wrap_overload__SWIG_5 unsafe.Pointer - -func Overload__SWIG_5(arg1 int) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_overload__SWIG_5, _swig_p) - return -} -var _wrap_overload__SWIG_6 unsafe.Pointer - -func Overload__SWIG_6(arg1 int, arg2 int) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_overload__SWIG_6, _swig_p) - return -} -var _wrap_overload__SWIG_7 unsafe.Pointer - -func Overload__SWIG_7(arg1 int, arg2 string) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_overload__SWIG_7, _swig_p) - return -} -var _wrap_overload__SWIG_8 unsafe.Pointer - -func _swig_wrap_overload__SWIG_8(base uintptr) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_overload__SWIG_8, _swig_p) - return -} - -func Overload__SWIG_8(arg1 Klass) (_swig_ret int) { - return _swig_wrap_overload__SWIG_8(arg1.Swigcptr()) -} - -var _wrap_overload__SWIG_9 unsafe.Pointer - -func _swig_wrap_overload__SWIG_9(base uintptr, _ uintptr) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_overload__SWIG_9, _swig_p) - return -} - -func Overload__SWIG_9(arg1 Klass, arg2 Klass) (_swig_ret int) { - return _swig_wrap_overload__SWIG_9(arg1.Swigcptr(), arg2.Swigcptr()) -} - -var _wrap_overload__SWIG_10 unsafe.Pointer - -func _swig_wrap_overload__SWIG_10(base uintptr, _ string) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_overload__SWIG_10, _swig_p) - return -} - -func Overload__SWIG_10(arg1 Klass, arg2 string) (_swig_ret int) { - return _swig_wrap_overload__SWIG_10(arg1.Swigcptr(), arg2) -} - -var _wrap_overload__SWIG_11 unsafe.Pointer - -func Overload__SWIG_11(arg1 float64) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_overload__SWIG_11, _swig_p) - return -} -var _wrap_overload__SWIG_12 unsafe.Pointer - -func Overload__SWIG_12(arg1 float64, arg2 float64) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_overload__SWIG_12, _swig_p) - return -} -var _wrap_overload__SWIG_13 unsafe.Pointer - -func Overload__SWIG_13(arg1 float64, arg2 string) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_overload__SWIG_13, _swig_p) - return -} -func Overload(a ...interface{}) int { - argc := len(a) - if argc == 0 { - return Overload__SWIG_4() - } - if argc == 1 { - if _, ok := a[0].(Klass); !ok { - goto check_2 - } - return Overload__SWIG_8(a[0].(Klass)) - } -check_2: - if argc == 1 { - if _, ok := a[0].(int); !ok { - goto check_3 - } - return Overload__SWIG_5(a[0].(int)) - } -check_3: - if argc == 1 { - if _, ok := a[0].(float64); !ok { - goto check_4 - } - return Overload__SWIG_11(a[0].(float64)) - } -check_4: - if argc == 1 { - return Overload__SWIG_0(a[0].(string)) - } - if argc == 2 { - if _, ok := a[0].(Klass); !ok { - goto check_6 - } - if _, ok := a[1].(Klass); !ok { - goto check_6 - } - return Overload__SWIG_9(a[0].(Klass), a[1].(Klass)) - } -check_6: - if argc == 2 { - if _, ok := a[0].(Klass); !ok { - goto check_7 - } - if _, ok := a[1].(string); !ok { - goto check_7 - } - return Overload__SWIG_10(a[0].(Klass), a[1].(string)) - } -check_7: - if argc == 2 { - if _, ok := a[0].(int); !ok { - goto check_8 - } - if _, ok := a[1].(int); !ok { - goto check_8 - } - return Overload__SWIG_6(a[0].(int), a[1].(int)) - } -check_8: - if argc == 2 { - if _, ok := a[0].(int); !ok { - goto check_9 - } - if _, ok := a[1].(string); !ok { - goto check_9 - } - return Overload__SWIG_7(a[0].(int), a[1].(string)) - } -check_9: - if argc == 2 { - if _, ok := a[1].(float64); !ok { - goto check_10 - } - return Overload__SWIG_12(a[0].(float64), a[1].(float64)) - } -check_10: - if argc == 2 { - return Overload__SWIG_13(a[0].(float64), a[1].(string)) - } - panic("No match for overloaded function call") -} - -var _wrap_nsoverload__SWIG_0 unsafe.Pointer - -func Nsoverload__SWIG_0(arg1 string) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_nsoverload__SWIG_0, _swig_p) - return -} -var _wrap_nsoverload__SWIG_4 unsafe.Pointer - -func Nsoverload__SWIG_4() (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_nsoverload__SWIG_4, _swig_p) - return -} -var _wrap_nsoverload__SWIG_5 unsafe.Pointer - -func Nsoverload__SWIG_5(arg1 int) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_nsoverload__SWIG_5, _swig_p) - return -} -var _wrap_nsoverload__SWIG_6 unsafe.Pointer - -func Nsoverload__SWIG_6(arg1 int, arg2 int) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_nsoverload__SWIG_6, _swig_p) - return -} -var _wrap_nsoverload__SWIG_7 unsafe.Pointer - -func Nsoverload__SWIG_7(arg1 int, arg2 string) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_nsoverload__SWIG_7, _swig_p) - return -} -var _wrap_nsoverload__SWIG_8 unsafe.Pointer - -func _swig_wrap_nsoverload__SWIG_8(base uintptr) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_nsoverload__SWIG_8, _swig_p) - return -} - -func Nsoverload__SWIG_8(arg1 Klass) (_swig_ret int) { - return _swig_wrap_nsoverload__SWIG_8(arg1.Swigcptr()) -} - -var _wrap_nsoverload__SWIG_9 unsafe.Pointer - -func _swig_wrap_nsoverload__SWIG_9(base uintptr, _ uintptr) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_nsoverload__SWIG_9, _swig_p) - return -} - -func Nsoverload__SWIG_9(arg1 Klass, arg2 Klass) (_swig_ret int) { - return _swig_wrap_nsoverload__SWIG_9(arg1.Swigcptr(), arg2.Swigcptr()) -} - -var _wrap_nsoverload__SWIG_10 unsafe.Pointer - -func _swig_wrap_nsoverload__SWIG_10(base uintptr, _ string) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_nsoverload__SWIG_10, _swig_p) - return -} - -func Nsoverload__SWIG_10(arg1 Klass, arg2 string) (_swig_ret int) { - return _swig_wrap_nsoverload__SWIG_10(arg1.Swigcptr(), arg2) -} - -var _wrap_nsoverload__SWIG_11 unsafe.Pointer - -func Nsoverload__SWIG_11(arg1 float64) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_nsoverload__SWIG_11, _swig_p) - return -} -var _wrap_nsoverload__SWIG_12 unsafe.Pointer - -func Nsoverload__SWIG_12(arg1 float64, arg2 float64) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_nsoverload__SWIG_12, _swig_p) - return -} -var _wrap_nsoverload__SWIG_13 unsafe.Pointer - -func Nsoverload__SWIG_13(arg1 float64, arg2 string) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_nsoverload__SWIG_13, _swig_p) - return -} -func Nsoverload(a ...interface{}) int { - argc := len(a) - if argc == 0 { - return Nsoverload__SWIG_4() - } - if argc == 1 { - if _, ok := a[0].(Klass); !ok { - goto check_2 - } - return Nsoverload__SWIG_8(a[0].(Klass)) - } -check_2: - if argc == 1 { - if _, ok := a[0].(int); !ok { - goto check_3 - } - return Nsoverload__SWIG_5(a[0].(int)) - } -check_3: - if argc == 1 { - if _, ok := a[0].(float64); !ok { - goto check_4 - } - return Nsoverload__SWIG_11(a[0].(float64)) - } -check_4: - if argc == 1 { - return Nsoverload__SWIG_0(a[0].(string)) - } - if argc == 2 { - if _, ok := a[0].(Klass); !ok { - goto check_6 - } - if _, ok := a[1].(Klass); !ok { - goto check_6 - } - return Nsoverload__SWIG_9(a[0].(Klass), a[1].(Klass)) - } -check_6: - if argc == 2 { - if _, ok := a[0].(Klass); !ok { - goto check_7 - } - if _, ok := a[1].(string); !ok { - goto check_7 - } - return Nsoverload__SWIG_10(a[0].(Klass), a[1].(string)) - } -check_7: - if argc == 2 { - if _, ok := a[0].(int); !ok { - goto check_8 - } - if _, ok := a[1].(int); !ok { - goto check_8 - } - return Nsoverload__SWIG_6(a[0].(int), a[1].(int)) - } -check_8: - if argc == 2 { - if _, ok := a[0].(int); !ok { - goto check_9 - } - if _, ok := a[1].(string); !ok { - goto check_9 - } - return Nsoverload__SWIG_7(a[0].(int), a[1].(string)) - } -check_9: - if argc == 2 { - if _, ok := a[1].(float64); !ok { - goto check_10 - } - return Nsoverload__SWIG_12(a[0].(float64), a[1].(float64)) - } -check_10: - if argc == 2 { - return Nsoverload__SWIG_13(a[0].(float64), a[1].(string)) - } - panic("No match for overloaded function call") -} - -type SwigcptrA uintptr - -func (p SwigcptrA) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrA) SwigIsA() { -} - -var _wrap_A_foo__SWIG_0 unsafe.Pointer - -func _swig_wrap_A_foo__SWIG_0(base float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_A_foo__SWIG_0, _swig_p) - return -} - -func AFoo__SWIG_0(arg1 float64) { - _swig_wrap_A_foo__SWIG_0(arg1) -} - -var _wrap_A_foo__SWIG_1 unsafe.Pointer - -func _swig_wrap_A_foo__SWIG_1(base int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_A_foo__SWIG_1, _swig_p) - return -} - -func AFoo__SWIG_1(arg1 int) { - _swig_wrap_A_foo__SWIG_1(arg1) -} - -var _wrap_A_foo__SWIG_2 unsafe.Pointer - -func _swig_wrap_A_foo__SWIG_2(base byte) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_A_foo__SWIG_2, _swig_p) - return -} - -func AFoo__SWIG_2(arg1 byte) { - _swig_wrap_A_foo__SWIG_2(arg1) -} - -func AFoo(a ...interface{}) { - argc := len(a) - if argc == 1 { - if _, ok := a[0].(int); !ok { - goto check_1 - } - AFoo__SWIG_1(a[0].(int)) - return - } -check_1: - if argc == 1 { - if _, ok := a[0].(float64); !ok { - goto check_2 - } - AFoo__SWIG_0(a[0].(float64)) - return - } -check_2: - if argc == 1 { - AFoo__SWIG_2(a[0].(byte)) - return - } - panic("No match for overloaded function call") -} - -var _wrap_new_A unsafe.Pointer - -func _swig_wrap_new_A() (base SwigcptrA) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_A, _swig_p) - return -} - -func NewA() (_swig_ret A) { - return _swig_wrap_new_A() -} - -var _wrap_delete_A unsafe.Pointer - -func _swig_wrap_delete_A(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_A, _swig_p) - return -} - -func DeleteA(arg1 A) { - _swig_wrap_delete_A(arg1.Swigcptr()) -} - -type A interface { - Swigcptr() uintptr - SwigIsA() -} - -type SwigcptrB uintptr - -func (p SwigcptrB) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrB) SwigIsB() { -} - -var _wrap_B_foo__SWIG_0 unsafe.Pointer - -func _swig_wrap_B_foo__SWIG_0(base SwigcptrB, _ float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_B_foo__SWIG_0, _swig_p) - return -} - -func (arg1 SwigcptrB) Foo__SWIG_0(arg2 float64) { - _swig_wrap_B_foo__SWIG_0(arg1, arg2) -} - -var _wrap_B_foo__SWIG_1 unsafe.Pointer - -func _swig_wrap_B_foo__SWIG_1(base SwigcptrB, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_B_foo__SWIG_1, _swig_p) - return -} - -func (arg1 SwigcptrB) Foo__SWIG_1(arg2 int) { - _swig_wrap_B_foo__SWIG_1(arg1, arg2) -} - -var _wrap_B_foo__SWIG_2 unsafe.Pointer - -func _swig_wrap_B_foo__SWIG_2(base SwigcptrB, _ byte) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_B_foo__SWIG_2, _swig_p) - return -} - -func (arg1 SwigcptrB) Foo__SWIG_2(arg2 byte) { - _swig_wrap_B_foo__SWIG_2(arg1, arg2) -} - -func (p SwigcptrB) Foo(a ...interface{}) { - argc := len(a) - if argc == 1 { - if _, ok := a[0].(int); !ok { - goto check_1 - } - p.Foo__SWIG_1(a[0].(int)) - return - } -check_1: - if argc == 1 { - if _, ok := a[0].(float64); !ok { - goto check_2 - } - p.Foo__SWIG_0(a[0].(float64)) - return - } -check_2: - if argc == 1 { - p.Foo__SWIG_2(a[0].(byte)) - return - } - panic("No match for overloaded function call") -} - -var _wrap_new_B unsafe.Pointer - -func _swig_wrap_new_B() (base SwigcptrB) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_B, _swig_p) - return -} - -func NewB() (_swig_ret B) { - return _swig_wrap_new_B() -} - -var _wrap_delete_B unsafe.Pointer - -func _swig_wrap_delete_B(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_B, _swig_p) - return -} - -func DeleteB(arg1 B) { - _swig_wrap_delete_B(arg1.Swigcptr()) -} - -type B interface { - Swigcptr() uintptr - SwigIsB() - Foo(a ...interface{}) -} - -type SwigcptrBar_d uintptr - -func (p SwigcptrBar_d) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrBar_d) SwigIsBar_d() { -} - -var _wrap_Bar_d_foo__SWIG_0 unsafe.Pointer - -func _swig_wrap_Bar_d_foo__SWIG_0(base SwigcptrBar_d, _ float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Bar_d_foo__SWIG_0, _swig_p) - return -} - -func (arg1 SwigcptrBar_d) Foo__SWIG_0(arg2 float64) { - _swig_wrap_Bar_d_foo__SWIG_0(arg1, arg2) -} - -var _wrap_Bar_d_foo__SWIG_1 unsafe.Pointer - -func _swig_wrap_Bar_d_foo__SWIG_1(base SwigcptrBar_d, _ float64, _ float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Bar_d_foo__SWIG_1, _swig_p) - return -} - -func (arg1 SwigcptrBar_d) Foo__SWIG_1(arg2 float64, arg3 float64) { - _swig_wrap_Bar_d_foo__SWIG_1(arg1, arg2, arg3) -} - -var _wrap_Bar_d_foo__SWIG_2 unsafe.Pointer - -func _swig_wrap_Bar_d_foo__SWIG_2(base SwigcptrBar_d, _ int, _ int, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Bar_d_foo__SWIG_2, _swig_p) - return -} - -func (arg1 SwigcptrBar_d) Foo__SWIG_2(arg2 int, arg3 int, arg4 int) { - _swig_wrap_Bar_d_foo__SWIG_2(arg1, arg2, arg3, arg4) -} - -func (p SwigcptrBar_d) Foo(a ...interface{}) { - argc := len(a) - if argc == 1 { - p.Foo__SWIG_0(a[0].(float64)) - return - } - if argc == 2 { - p.Foo__SWIG_1(a[0].(float64), a[1].(float64)) - return - } - if argc == 3 { - p.Foo__SWIG_2(a[0].(int), a[1].(int), a[2].(int)) - return - } - panic("No match for overloaded function call") -} - -var _wrap_new_Bar_d unsafe.Pointer - -func _swig_wrap_new_Bar_d() (base SwigcptrBar_d) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Bar_d, _swig_p) - return -} - -func NewBar_d() (_swig_ret Bar_d) { - return _swig_wrap_new_Bar_d() -} - -var _wrap_delete_Bar_d unsafe.Pointer - -func _swig_wrap_delete_Bar_d(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Bar_d, _swig_p) - return -} - -func DeleteBar_d(arg1 Bar_d) { - _swig_wrap_delete_Bar_d(arg1.Swigcptr()) -} - -type Bar_d interface { - Swigcptr() uintptr - SwigIsBar_d() - Foo(a ...interface{}) -} - -type SwigcptrFoo_d uintptr - -func (p SwigcptrFoo_d) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrFoo_d) SwigIsFoo_d() { -} - -var _wrap_Foo_d_bar__SWIG_0 unsafe.Pointer - -func _swig_wrap_Foo_d_bar__SWIG_0(base SwigcptrFoo_d, _ float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_d_bar__SWIG_0, _swig_p) - return -} - -func (arg1 SwigcptrFoo_d) Bar__SWIG_0(arg2 float64) { - _swig_wrap_Foo_d_bar__SWIG_0(arg1, arg2) -} - -var _wrap_Foo_d_bar__SWIG_1 unsafe.Pointer - -func _swig_wrap_Foo_d_bar__SWIG_1(base SwigcptrFoo_d, _ float64, _ float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_d_bar__SWIG_1, _swig_p) - return -} - -func (arg1 SwigcptrFoo_d) Bar__SWIG_1(arg2 float64, arg3 float64) { - _swig_wrap_Foo_d_bar__SWIG_1(arg1, arg2, arg3) -} - -var _wrap_Foo_d_bar__SWIG_2 unsafe.Pointer - -func _swig_wrap_Foo_d_bar__SWIG_2(base SwigcptrFoo_d, _ int, _ int, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_d_bar__SWIG_2, _swig_p) - return -} - -func (arg1 SwigcptrFoo_d) Bar__SWIG_2(arg2 int, arg3 int, arg4 int) { - _swig_wrap_Foo_d_bar__SWIG_2(arg1, arg2, arg3, arg4) -} - -func (p SwigcptrFoo_d) Bar(a ...interface{}) { - argc := len(a) - if argc == 1 { - p.Bar__SWIG_0(a[0].(float64)) - return - } - if argc == 2 { - p.Bar__SWIG_1(a[0].(float64), a[1].(float64)) - return - } - if argc == 3 { - p.Bar__SWIG_2(a[0].(int), a[1].(int), a[2].(int)) - return - } - panic("No match for overloaded function call") -} - -var _wrap_new_Foo_d unsafe.Pointer - -func _swig_wrap_new_Foo_d() (base SwigcptrFoo_d) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Foo_d, _swig_p) - return -} - -func NewFoo_d() (_swig_ret Foo_d) { - return _swig_wrap_new_Foo_d() -} - -var _wrap_delete_Foo_d unsafe.Pointer - -func _swig_wrap_delete_Foo_d(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Foo_d, _swig_p) - return -} - -func DeleteFoo_d(arg1 Foo_d) { - _swig_wrap_delete_Foo_d(arg1.Swigcptr()) -} - -type Foo_d interface { - Swigcptr() uintptr - SwigIsFoo_d() - Bar(a ...interface{}) -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/overload_template_fast_runme b/Examples/test-suite/go/overload_template_fast_runme deleted file mode 100755 index d74cd0045..000000000 Binary files a/Examples/test-suite/go/overload_template_fast_runme and /dev/null differ diff --git a/Examples/test-suite/go/overload_template_runme b/Examples/test-suite/go/overload_template_runme deleted file mode 100755 index 1d20b2fce..000000000 Binary files a/Examples/test-suite/go/overload_template_runme and /dev/null differ diff --git a/Examples/test-suite/go/packageoption_a.go b/Examples/test-suite/go/packageoption_a.go deleted file mode 100644 index a949eed62..000000000 --- a/Examples/test-suite/go/packageoption_a.go +++ /dev/null @@ -1,152 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../packageoption_a.i - -package packageoption_a - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrA uintptr - -func (p SwigcptrA) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrA) SwigIsA() { -} - -var _wrap_A_testInt unsafe.Pointer - -func _swig_wrap_A_testInt(base SwigcptrA) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_A_testInt, _swig_p) - return -} - -func (arg1 SwigcptrA) TestInt() (_swig_ret int) { - return _swig_wrap_A_testInt(arg1) -} - -var _wrap_new_A unsafe.Pointer - -func _swig_wrap_new_A() (base SwigcptrA) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_A, _swig_p) - return -} - -func NewA() (_swig_ret A) { - return _swig_wrap_new_A() -} - -var _wrap_delete_A unsafe.Pointer - -func _swig_wrap_delete_A(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_A, _swig_p) - return -} - -func DeleteA(arg1 A) { - _swig_wrap_delete_A(arg1.Swigcptr()) -} - -type A interface { - Swigcptr() uintptr - SwigIsA() - TestInt() (_swig_ret int) -} - -type SwigcptrBase uintptr - -func (p SwigcptrBase) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrBase) SwigIsBase() { -} - -var _wrap_Base_vmethod unsafe.Pointer - -func _swig_wrap_Base_vmethod(base SwigcptrBase) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Base_vmethod, _swig_p) - return -} - -func (arg1 SwigcptrBase) Vmethod() (_swig_ret int) { - return _swig_wrap_Base_vmethod(arg1) -} - -var _wrap_Base_basemethod unsafe.Pointer - -func _swig_wrap_Base_basemethod(base SwigcptrBase) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Base_basemethod, _swig_p) - return -} - -func (arg1 SwigcptrBase) Basemethod() (_swig_ret int) { - return _swig_wrap_Base_basemethod(arg1) -} - -var _wrap_delete_Base unsafe.Pointer - -func _swig_wrap_delete_Base(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Base, _swig_p) - return -} - -func DeleteBase(arg1 Base) { - _swig_wrap_delete_Base(arg1.Swigcptr()) -} - -var _wrap_new_Base unsafe.Pointer - -func _swig_wrap_new_Base() (base SwigcptrBase) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Base, _swig_p) - return -} - -func NewBase() (_swig_ret Base) { - return _swig_wrap_new_Base() -} - -type Base interface { - Swigcptr() uintptr - SwigIsBase() - Vmethod() (_swig_ret int) - Basemethod() (_swig_ret int) -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/packageoption_b.go b/Examples/test-suite/go/packageoption_b.go deleted file mode 100644 index 6c86df625..000000000 --- a/Examples/test-suite/go/packageoption_b.go +++ /dev/null @@ -1,88 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../packageoption_b.i - -package packageoption_b - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrB uintptr - -func (p SwigcptrB) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrB) SwigIsB() { -} - -var _wrap_B_testInt unsafe.Pointer - -func _swig_wrap_B_testInt(base SwigcptrB) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_B_testInt, _swig_p) - return -} - -func (arg1 SwigcptrB) TestInt() (_swig_ret int) { - return _swig_wrap_B_testInt(arg1) -} - -var _wrap_new_B unsafe.Pointer - -func _swig_wrap_new_B() (base SwigcptrB) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_B, _swig_p) - return -} - -func NewB() (_swig_ret B) { - return _swig_wrap_new_B() -} - -var _wrap_delete_B unsafe.Pointer - -func _swig_wrap_delete_B(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_B, _swig_p) - return -} - -func DeleteB(arg1 B) { - _swig_wrap_delete_B(arg1.Swigcptr()) -} - -type B interface { - Swigcptr() uintptr - SwigIsB() - TestInt() (_swig_ret int) -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/packageoption_c.go b/Examples/test-suite/go/packageoption_c.go deleted file mode 100644 index 21a9f09f1..000000000 --- a/Examples/test-suite/go/packageoption_c.go +++ /dev/null @@ -1,111 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../packageoption_c.i - -package packageoption_c - -import "unsafe" -import _ "runtime/cgo" -import "packageoption_a" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrDerived uintptr - -func (p SwigcptrDerived) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrDerived) SwigIsDerived() { -} - -var _wrap_Derived_vmethod unsafe.Pointer - -func _swig_wrap_Derived_vmethod(base SwigcptrDerived) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Derived_vmethod, _swig_p) - return -} - -func (arg1 SwigcptrDerived) Vmethod() (_swig_ret int) { - return _swig_wrap_Derived_vmethod(arg1) -} - -var _wrap_delete_Derived unsafe.Pointer - -func _swig_wrap_delete_Derived(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Derived, _swig_p) - return -} - -func DeleteDerived(arg1 Derived) { - _swig_wrap_delete_Derived(arg1.Swigcptr()) -} - -var _wrap_new_Derived unsafe.Pointer - -func _swig_wrap_new_Derived() (base SwigcptrDerived) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Derived, _swig_p) - return -} - -func NewDerived() (_swig_ret Derived) { - return _swig_wrap_new_Derived() -} - -var _wrap_Derived_basemethod unsafe.Pointer - -func _swig_wrap_Derived_basemethod(base SwigcptrDerived) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Derived_basemethod, _swig_p) - return -} - -func (_swig_base SwigcptrDerived) Basemethod() (_swig_ret int) { - return _swig_wrap_Derived_basemethod(_swig_base) -} - -func (p SwigcptrDerived) SwigIsBase() { -} - -func (p SwigcptrDerived) SwigGetBase() packageoption_a.Base { - return packageoption_a.SwigcptrBase(p.Swigcptr()) -} - -type Derived interface { - Swigcptr() uintptr - SwigIsDerived() - Vmethod() (_swig_ret int) - Basemethod() (_swig_ret int) - SwigIsBase() - SwigGetBase() packageoption_a.Base -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/pointer_reference.go b/Examples/test-suite/go/pointer_reference.go deleted file mode 100644 index 638599f52..000000000 --- a/Examples/test-suite/go/pointer_reference.go +++ /dev/null @@ -1,219 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../pointer_reference.i - -package pointer_reference - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -var _wrap_foo unsafe.Pointer - -func _swig_wrap_foo(base **int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_foo, _swig_p) - return -} - -func Foo(arg1 **int) { - _swig_wrap_foo(arg1) -} - -type SwigcptrStruct uintptr - -func (p SwigcptrStruct) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrStruct) SwigIsStruct() { -} - -var _wrap_Struct_value_set unsafe.Pointer - -func _swig_wrap_Struct_value_set(base SwigcptrStruct, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Struct_value_set, _swig_p) - return -} - -func (arg1 SwigcptrStruct) SetValue(arg2 int) { - _swig_wrap_Struct_value_set(arg1, arg2) -} - -var _wrap_Struct_value_get unsafe.Pointer - -func _swig_wrap_Struct_value_get(base SwigcptrStruct) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Struct_value_get, _swig_p) - return -} - -func (arg1 SwigcptrStruct) GetValue() (_swig_ret int) { - return _swig_wrap_Struct_value_get(arg1) -} - -var _wrap_new_Struct unsafe.Pointer - -func _swig_wrap_new_Struct(base int) (_ SwigcptrStruct) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Struct, _swig_p) - return -} - -func NewStruct(arg1 int) (_swig_ret Struct) { - return _swig_wrap_new_Struct(arg1) -} - -var _wrap_Struct_instance_set unsafe.Pointer - -func _swig_wrap_Struct_instance_set(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Struct_instance_set, _swig_p) - return -} - -func SetStructInstance(arg1 Struct) { - _swig_wrap_Struct_instance_set(arg1.Swigcptr()) -} - -var _wrap_Struct_instance_get unsafe.Pointer - -func _swig_wrap_Struct_instance_get() (base SwigcptrStruct) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Struct_instance_get, _swig_p) - return -} - -func GetStructInstance() (_swig_ret Struct) { - return _swig_wrap_Struct_instance_get() -} - -var _wrap_Struct_pInstance_set unsafe.Pointer - -func _swig_wrap_Struct_pInstance_set(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Struct_pInstance_set, _swig_p) - return -} - -func SetStructPInstance(arg1 Struct) { - _swig_wrap_Struct_pInstance_set(arg1.Swigcptr()) -} - -var _wrap_Struct_pInstance_get unsafe.Pointer - -func _swig_wrap_Struct_pInstance_get() (base SwigcptrStruct) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Struct_pInstance_get, _swig_p) - return -} - -func GetStructPInstance() (_swig_ret Struct) { - return _swig_wrap_Struct_pInstance_get() -} - -var _wrap_delete_Struct unsafe.Pointer - -func _swig_wrap_delete_Struct(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Struct, _swig_p) - return -} - -func DeleteStruct(arg1 Struct) { - _swig_wrap_delete_Struct(arg1.Swigcptr()) -} - -type Struct interface { - Swigcptr() uintptr - SwigIsStruct() - SetValue(arg2 int) - GetValue() (_swig_ret int) -} - -var _wrap_set unsafe.Pointer - -func _swig_wrap_set(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_set, _swig_p) - return -} - -func Set(arg1 Struct) { - _swig_wrap_set(arg1.Swigcptr()) -} - -var _wrap_get unsafe.Pointer - -func _swig_wrap_get() (base SwigcptrStruct) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_get, _swig_p) - return -} - -func Get() (_swig_ret Struct) { - return _swig_wrap_get() -} - -var _wrap_overloading__SWIG_0 unsafe.Pointer - -func Overloading__SWIG_0(arg1 int) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_overloading__SWIG_0, _swig_p) - return -} -var _wrap_overloading__SWIG_1 unsafe.Pointer - -func _swig_wrap_overloading__SWIG_1(base uintptr) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_overloading__SWIG_1, _swig_p) - return -} - -func Overloading__SWIG_1(arg1 Struct) (_swig_ret int) { - return _swig_wrap_overloading__SWIG_1(arg1.Swigcptr()) -} - -func Overloading(a ...interface{}) int { - argc := len(a) - if argc == 1 { - if _, ok := a[0].(Struct); !ok { - goto check_1 - } - return Overloading__SWIG_1(a[0].(Struct)) - } -check_1: - if argc == 1 { - return Overloading__SWIG_0(a[0].(int)) - } - panic("No match for overloaded function call") -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/preproc.go b/Examples/test-suite/go/preproc.go deleted file mode 100644 index 1b0c0a389..000000000 --- a/Examples/test-suite/go/preproc.go +++ /dev/null @@ -1,403 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../preproc.i - -package preproc - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -const SLASHSLASH string = "//" -var _wrap_hello0 unsafe.Pointer - -func Hello0() (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_hello0, _swig_p) - return -} -var _wrap_hello1 unsafe.Pointer - -func Hello1() (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_hello1, _swig_p) - return -} -var _wrap_hello2 unsafe.Pointer - -func Hello2() (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_hello2, _swig_p) - return -} -var _wrap_f unsafe.Pointer - -func F(arg1 int) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_f, _swig_p) - return -} -const A5 string = "helloworld" -const B5 int = 3+4 -var _wrap_c5 unsafe.Pointer - -func _swig_getc5() (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_c5, _swig_p) - return -} -var C5 int = _swig_getc5() -const D5 int = 123 -const C1 string = "hello" -const ALONG_NAME int = 42 -const C4 string = "Hello" -var _wrap_a6 unsafe.Pointer - -func _swig_geta6() (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_a6, _swig_p) - return -} -var A6 int = _swig_geta6() -var _wrap_b6 unsafe.Pointer - -func _swig_getb6() (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_b6, _swig_p) - return -} -var B6 int = _swig_getb6() -var _wrap_c6 unsafe.Pointer - -func _swig_getc6() (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_c6, _swig_p) - return -} -var C6 int = _swig_getc6() -var _wrap_d6 unsafe.Pointer - -func _swig_getd6() (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_d6, _swig_p) - return -} -var D6 int = _swig_getd6() -type SwigcptrEmbeddedDefines uintptr - -func (p SwigcptrEmbeddedDefines) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrEmbeddedDefines) SwigIsEmbeddedDefines() { -} - -var _wrap_EmbeddedDefines_dummy_set unsafe.Pointer - -func _swig_wrap_EmbeddedDefines_dummy_set(base SwigcptrEmbeddedDefines, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_EmbeddedDefines_dummy_set, _swig_p) - return -} - -func (arg1 SwigcptrEmbeddedDefines) SetDummy(arg2 int) { - _swig_wrap_EmbeddedDefines_dummy_set(arg1, arg2) -} - -var _wrap_EmbeddedDefines_dummy_get unsafe.Pointer - -func _swig_wrap_EmbeddedDefines_dummy_get(base SwigcptrEmbeddedDefines) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_EmbeddedDefines_dummy_get, _swig_p) - return -} - -func (arg1 SwigcptrEmbeddedDefines) GetDummy() (_swig_ret int) { - return _swig_wrap_EmbeddedDefines_dummy_get(arg1) -} - -const EMBEDDED_DEFINE int = 44 -const EMBEDDED_SWIG_CONSTANT int = 55 -var _wrap_new_EmbeddedDefines unsafe.Pointer - -func _swig_wrap_new_EmbeddedDefines() (base SwigcptrEmbeddedDefines) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_EmbeddedDefines, _swig_p) - return -} - -func NewEmbeddedDefines() (_swig_ret EmbeddedDefines) { - return _swig_wrap_new_EmbeddedDefines() -} - -var _wrap_delete_EmbeddedDefines unsafe.Pointer - -func _swig_wrap_delete_EmbeddedDefines(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_EmbeddedDefines, _swig_p) - return -} - -func DeleteEmbeddedDefines(arg1 EmbeddedDefines) { - _swig_wrap_delete_EmbeddedDefines(arg1.Swigcptr()) -} - -type EmbeddedDefines interface { - Swigcptr() uintptr - SwigIsEmbeddedDefines() - SetDummy(arg2 int) - GetDummy() (_swig_ret int) -} - -const A1 int = 1+2 -const A2 int = 3-4 -var _wrap_A3 unsafe.Pointer - -func _swig_getA3() (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_A3, _swig_p) - return -} -var A3 int = _swig_getA3() -var _wrap_A4 unsafe.Pointer - -func _swig_getA4() (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_A4, _swig_p) - return -} -var A4 int = _swig_getA4() -var _wrap_A7 unsafe.Pointer - -func _swig_getA7() (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_A7, _swig_p) - return -} -var A7 int = _swig_getA7() -var _wrap_A8 unsafe.Pointer - -func _swig_getA8() (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_A8, _swig_p) - return -} -var A8 int = _swig_getA8() -var _wrap_A9 unsafe.Pointer - -func _swig_getA9() (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_A9, _swig_p) - return -} -var A9 int = _swig_getA9() -var _wrap_A10 unsafe.Pointer - -func _swig_getA10() (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_A10, _swig_p) - return -} -var A10 int = _swig_getA10() -var _wrap_A11 unsafe.Pointer - -func _swig_getA11() (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_A11, _swig_p) - return -} -var A11 int = _swig_getA11() -var _wrap_A12 unsafe.Pointer - -func _swig_getA12() (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_A12, _swig_p) - return -} -var A12 int = _swig_getA12() -var _wrap_A13 unsafe.Pointer - -func _swig_getA13() (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_A13, _swig_p) - return -} -var A13 int = _swig_getA13() -const X__GMP_HAVE_CONST int = 0 -const X__GMP_HAVE_PROTOTYPES int = 0 -const X__GMP_HAVE_TOKEN_PASTE int = 0 -const ONE int = 1 -const One int = 1 -const Two int = 2 -const Three int = 3 -var _wrap_endif_get unsafe.Pointer - -func GetEndif() (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_endif_get, _swig_p) - return -} -var _wrap_define_get unsafe.Pointer - -func GetDefine() (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_define_get, _swig_p) - return -} -var _wrap_defined_get unsafe.Pointer - -func GetDefined() (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_defined_get, _swig_p) - return -} -var _wrap_test unsafe.Pointer - -func Test(arg1 int) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_test, _swig_p) - return -} -var _wrap_SOME_MASK_DEF unsafe.Pointer - -func _swig_getSOME_MASK_DEF() (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_SOME_MASK_DEF, _swig_p) - return -} -var SOME_MASK_DEF int = _swig_getSOME_MASK_DEF() -var _wrap_BOLTZMANN unsafe.Pointer - -func _swig_getBOLTZMANN() (_swig_ret float64) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_BOLTZMANN, _swig_p) - return -} -var BOLTZMANN float64 = _swig_getBOLTZMANN() -var _wrap_AVOGADRO unsafe.Pointer - -func _swig_getAVOGADRO() (_swig_ret float64) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_AVOGADRO, _swig_p) - return -} -var AVOGADRO float64 = _swig_getAVOGADRO() -var _wrap_RGAS unsafe.Pointer - -func _swig_getRGAS() (_swig_ret float64) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_RGAS, _swig_p) - return -} -var RGAS float64 = _swig_getRGAS() -var _wrap_RGASX unsafe.Pointer - -func _swig_getRGASX() (_swig_ret float64) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_RGASX, _swig_p) - return -} -var RGASX float64 = _swig_getRGASX() -type SwigcptrTypeNameTraits uintptr - -func (p SwigcptrTypeNameTraits) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrTypeNameTraits) SwigIsTypeNameTraits() { -} - -var _wrap_TypeNameTraits_val_set unsafe.Pointer - -func _swig_wrap_TypeNameTraits_val_set(base SwigcptrTypeNameTraits, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_TypeNameTraits_val_set, _swig_p) - return -} - -func (arg1 SwigcptrTypeNameTraits) SetVal(arg2 int) { - _swig_wrap_TypeNameTraits_val_set(arg1, arg2) -} - -var _wrap_TypeNameTraits_val_get unsafe.Pointer - -func _swig_wrap_TypeNameTraits_val_get(base SwigcptrTypeNameTraits) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_TypeNameTraits_val_get, _swig_p) - return -} - -func (arg1 SwigcptrTypeNameTraits) GetVal() (_swig_ret int) { - return _swig_wrap_TypeNameTraits_val_get(arg1) -} - -var _wrap_new_TypeNameTraits unsafe.Pointer - -func _swig_wrap_new_TypeNameTraits() (base SwigcptrTypeNameTraits) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_TypeNameTraits, _swig_p) - return -} - -func NewTypeNameTraits() (_swig_ret TypeNameTraits) { - return _swig_wrap_new_TypeNameTraits() -} - -var _wrap_delete_TypeNameTraits unsafe.Pointer - -func _swig_wrap_delete_TypeNameTraits(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_TypeNameTraits, _swig_p) - return -} - -func DeleteTypeNameTraits(arg1 TypeNameTraits) { - _swig_wrap_delete_TypeNameTraits(arg1.Swigcptr()) -} - -type TypeNameTraits interface { - Swigcptr() uintptr - SwigIsTypeNameTraits() - SetVal(arg2 int) - GetVal() (_swig_ret int) -} - -var _wrap_method unsafe.Pointer - -func _swig_wrap_method(base uintptr) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_method, _swig_p) - return -} - -func Method(arg1 TypeNameTraits) (_swig_ret int) { - return _swig_wrap_method(arg1.Swigcptr()) -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/preproc_constants.go b/Examples/test-suite/go/preproc_constants.go deleted file mode 100644 index 17279e3d9..000000000 --- a/Examples/test-suite/go/preproc_constants.go +++ /dev/null @@ -1,246 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../preproc_constants.i - -package preproc_constants - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -const CONST_INT1 int = 10 -const CONST_INT2 int = 0xFF -const CONST_UINT1 uint = 10 -const CONST_UINT2 uint = 10 -const CONST_UINT3 uint = 0xFF -const CONST_UINT4 uint = 0xFF -const CONST_LONG1 int64 = 10 -const CONST_LONG2 int64 = 10 -const CONST_LONG3 int64 = 0xFF -const CONST_LONG4 int64 = 0xFF -const CONST_LLONG1 int64 = 10 -const CONST_LLONG2 int64 = 10 -const CONST_LLONG3 int64 = 0xFF -const CONST_LLONG4 int64 = 0xFF -const CONST_ULLONG1 uint64 = 10 -const CONST_ULLONG2 uint64 = 10 -const CONST_ULLONG3 uint64 = 0xFF -const CONST_ULLONG4 uint64 = 0xFF -const CONST_DOUBLE1 float64 = 10e1 -const CONST_DOUBLE2 float64 = 10E1 -const CONST_DOUBLE3 float64 = 12.3 -const CONST_DOUBLE4 float64 = 12. -const CONST_DOUBLE5 float64 = 12.3 -const CONST_DOUBLE6 float64 = 12.3 -const CONST_BOOL1 bool = true -const CONST_BOOL2 bool = false -const CONST_CHAR byte = 'x' -const CONST_STRING1 string = "const string" -const CONST_STRING2 string = "const string" -const CONST_STRING3 string = "log-revprops" -var _wrap_INT_AND_BOOL unsafe.Pointer - -func _swig_getINT_AND_BOOL() (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_INT_AND_BOOL, _swig_p) - return -} -var INT_AND_BOOL int = _swig_getINT_AND_BOOL() -var _wrap_INT_AND_INT unsafe.Pointer - -func _swig_getINT_AND_INT() (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_INT_AND_INT, _swig_p) - return -} -var INT_AND_INT int = _swig_getINT_AND_INT() -var _wrap_INT_AND_UINT unsafe.Pointer - -func _swig_getINT_AND_UINT() (_swig_ret uint) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_INT_AND_UINT, _swig_p) - return -} -var INT_AND_UINT uint = _swig_getINT_AND_UINT() -var _wrap_INT_AND_LONG unsafe.Pointer - -func _swig_getINT_AND_LONG() (_swig_ret int64) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_INT_AND_LONG, _swig_p) - return -} -var INT_AND_LONG int64 = _swig_getINT_AND_LONG() -var _wrap_INT_AND_ULONG unsafe.Pointer - -func _swig_getINT_AND_ULONG() (_swig_ret uint64) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_INT_AND_ULONG, _swig_p) - return -} -var INT_AND_ULONG uint64 = _swig_getINT_AND_ULONG() -var _wrap_INT_AND_LLONG unsafe.Pointer - -func _swig_getINT_AND_LLONG() (_swig_ret int64) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_INT_AND_LLONG, _swig_p) - return -} -var INT_AND_LLONG int64 = _swig_getINT_AND_LLONG() -var _wrap_INT_AND_ULLONG unsafe.Pointer - -func _swig_getINT_AND_ULLONG() (_swig_ret uint64) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_INT_AND_ULLONG, _swig_p) - return -} -var INT_AND_ULLONG uint64 = _swig_getINT_AND_ULLONG() -var _wrap_BOOL_AND_BOOL unsafe.Pointer - -func _swig_getBOOL_AND_BOOL() (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_BOOL_AND_BOOL, _swig_p) - return -} -var BOOL_AND_BOOL int = _swig_getBOOL_AND_BOOL() -var _wrap_EXPR_MULTIPLY unsafe.Pointer - -func _swig_getEXPR_MULTIPLY() (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_EXPR_MULTIPLY, _swig_p) - return -} -var EXPR_MULTIPLY int = _swig_getEXPR_MULTIPLY() -var _wrap_EXPR_DIVIDE unsafe.Pointer - -func _swig_getEXPR_DIVIDE() (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_EXPR_DIVIDE, _swig_p) - return -} -var EXPR_DIVIDE int = _swig_getEXPR_DIVIDE() -const EXPR_PLUS int = 0xFF+2 -const EXPR_MINUS int = 0xFF+2 -var _wrap_EXPR_LSHIFT unsafe.Pointer - -func _swig_getEXPR_LSHIFT() (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_EXPR_LSHIFT, _swig_p) - return -} -var EXPR_LSHIFT int = _swig_getEXPR_LSHIFT() -var _wrap_EXPR_RSHIFT unsafe.Pointer - -func _swig_getEXPR_RSHIFT() (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_EXPR_RSHIFT, _swig_p) - return -} -var EXPR_RSHIFT int = _swig_getEXPR_RSHIFT() -var _wrap_EXPR_LTE unsafe.Pointer - -func _swig_getEXPR_LTE() (_swig_ret bool) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_EXPR_LTE, _swig_p) - return -} -var EXPR_LTE bool = _swig_getEXPR_LTE() -var _wrap_EXPR_GTE unsafe.Pointer - -func _swig_getEXPR_GTE() (_swig_ret bool) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_EXPR_GTE, _swig_p) - return -} -var EXPR_GTE bool = _swig_getEXPR_GTE() -var _wrap_EXPR_INEQUALITY unsafe.Pointer - -func _swig_getEXPR_INEQUALITY() (_swig_ret bool) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_EXPR_INEQUALITY, _swig_p) - return -} -var EXPR_INEQUALITY bool = _swig_getEXPR_INEQUALITY() -var _wrap_EXPR_EQUALITY unsafe.Pointer - -func _swig_getEXPR_EQUALITY() (_swig_ret bool) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_EXPR_EQUALITY, _swig_p) - return -} -var EXPR_EQUALITY bool = _swig_getEXPR_EQUALITY() -var _wrap_EXPR_AND unsafe.Pointer - -func _swig_getEXPR_AND() (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_EXPR_AND, _swig_p) - return -} -var EXPR_AND int = _swig_getEXPR_AND() -var _wrap_EXPR_XOR unsafe.Pointer - -func _swig_getEXPR_XOR() (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_EXPR_XOR, _swig_p) - return -} -var EXPR_XOR int = _swig_getEXPR_XOR() -var _wrap_EXPR_OR unsafe.Pointer - -func _swig_getEXPR_OR() (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_EXPR_OR, _swig_p) - return -} -var EXPR_OR int = _swig_getEXPR_OR() -var _wrap_EXPR_LAND unsafe.Pointer - -func _swig_getEXPR_LAND() (_swig_ret bool) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_EXPR_LAND, _swig_p) - return -} -var EXPR_LAND bool = _swig_getEXPR_LAND() -var _wrap_EXPR_LOR unsafe.Pointer - -func _swig_getEXPR_LOR() (_swig_ret bool) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_EXPR_LOR, _swig_p) - return -} -var EXPR_LOR bool = _swig_getEXPR_LOR() -var _wrap_EXPR_CONDITIONAL unsafe.Pointer - -func _swig_getEXPR_CONDITIONAL() (_swig_ret float64) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_EXPR_CONDITIONAL, _swig_p) - return -} -var EXPR_CONDITIONAL float64 = _swig_getEXPR_CONDITIONAL() -type MyEnum int -var _wrap_kValue unsafe.Pointer - -func _swig_getkValue() (_swig_ret MyEnum) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_kValue, _swig_p) - return -} -var KValue MyEnum = _swig_getkValue() - diff --git a/Examples/test-suite/go/preproc_constants_c.go b/Examples/test-suite/go/preproc_constants_c.go deleted file mode 100644 index 5db835913..000000000 --- a/Examples/test-suite/go/preproc_constants_c.go +++ /dev/null @@ -1,246 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../preproc_constants_c.i - -package preproc_constants_c - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -const CONST_INT1 int = 10 -const CONST_INT2 int = 0xFF -const CONST_UINT1 uint = 10 -const CONST_UINT2 uint = 10 -const CONST_UINT3 uint = 0xFF -const CONST_UINT4 uint = 0xFF -const CONST_LONG1 int64 = 10 -const CONST_LONG2 int64 = 10 -const CONST_LONG3 int64 = 0xFF -const CONST_LONG4 int64 = 0xFF -const CONST_LLONG1 int64 = 10 -const CONST_LLONG2 int64 = 10 -const CONST_LLONG3 int64 = 0xFF -const CONST_LLONG4 int64 = 0xFF -const CONST_ULLONG1 uint64 = 10 -const CONST_ULLONG2 uint64 = 10 -const CONST_ULLONG3 uint64 = 0xFF -const CONST_ULLONG4 uint64 = 0xFF -const CONST_DOUBLE1 float64 = 10e1 -const CONST_DOUBLE2 float64 = 10E1 -const CONST_DOUBLE3 float64 = 12.3 -const CONST_DOUBLE4 float64 = 12. -const CONST_DOUBLE5 float64 = 12.3 -const CONST_DOUBLE6 float64 = 12.3 -const CONST_BOOL1 int = 1 -const CONST_BOOL2 int = 0 -const CONST_CHAR byte = 'x' -const CONST_STRING1 string = "const string" -const CONST_STRING2 string = "const string" -const CONST_STRING3 string = "log-revprops" -var _wrap_INT_AND_BOOL unsafe.Pointer - -func _swig_getINT_AND_BOOL() (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_INT_AND_BOOL, _swig_p) - return -} -var INT_AND_BOOL int = _swig_getINT_AND_BOOL() -var _wrap_INT_AND_INT unsafe.Pointer - -func _swig_getINT_AND_INT() (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_INT_AND_INT, _swig_p) - return -} -var INT_AND_INT int = _swig_getINT_AND_INT() -var _wrap_INT_AND_UINT unsafe.Pointer - -func _swig_getINT_AND_UINT() (_swig_ret uint) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_INT_AND_UINT, _swig_p) - return -} -var INT_AND_UINT uint = _swig_getINT_AND_UINT() -var _wrap_INT_AND_LONG unsafe.Pointer - -func _swig_getINT_AND_LONG() (_swig_ret int64) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_INT_AND_LONG, _swig_p) - return -} -var INT_AND_LONG int64 = _swig_getINT_AND_LONG() -var _wrap_INT_AND_ULONG unsafe.Pointer - -func _swig_getINT_AND_ULONG() (_swig_ret uint64) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_INT_AND_ULONG, _swig_p) - return -} -var INT_AND_ULONG uint64 = _swig_getINT_AND_ULONG() -var _wrap_INT_AND_LLONG unsafe.Pointer - -func _swig_getINT_AND_LLONG() (_swig_ret int64) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_INT_AND_LLONG, _swig_p) - return -} -var INT_AND_LLONG int64 = _swig_getINT_AND_LLONG() -var _wrap_INT_AND_ULLONG unsafe.Pointer - -func _swig_getINT_AND_ULLONG() (_swig_ret uint64) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_INT_AND_ULLONG, _swig_p) - return -} -var INT_AND_ULLONG uint64 = _swig_getINT_AND_ULLONG() -var _wrap_BOOL_AND_BOOL unsafe.Pointer - -func _swig_getBOOL_AND_BOOL() (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_BOOL_AND_BOOL, _swig_p) - return -} -var BOOL_AND_BOOL int = _swig_getBOOL_AND_BOOL() -var _wrap_EXPR_MULTIPLY unsafe.Pointer - -func _swig_getEXPR_MULTIPLY() (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_EXPR_MULTIPLY, _swig_p) - return -} -var EXPR_MULTIPLY int = _swig_getEXPR_MULTIPLY() -var _wrap_EXPR_DIVIDE unsafe.Pointer - -func _swig_getEXPR_DIVIDE() (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_EXPR_DIVIDE, _swig_p) - return -} -var EXPR_DIVIDE int = _swig_getEXPR_DIVIDE() -const EXPR_PLUS int = 0xFF+2 -const EXPR_MINUS int = 0xFF+2 -var _wrap_EXPR_LSHIFT unsafe.Pointer - -func _swig_getEXPR_LSHIFT() (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_EXPR_LSHIFT, _swig_p) - return -} -var EXPR_LSHIFT int = _swig_getEXPR_LSHIFT() -var _wrap_EXPR_RSHIFT unsafe.Pointer - -func _swig_getEXPR_RSHIFT() (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_EXPR_RSHIFT, _swig_p) - return -} -var EXPR_RSHIFT int = _swig_getEXPR_RSHIFT() -var _wrap_EXPR_LTE unsafe.Pointer - -func _swig_getEXPR_LTE() (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_EXPR_LTE, _swig_p) - return -} -var EXPR_LTE int = _swig_getEXPR_LTE() -var _wrap_EXPR_GTE unsafe.Pointer - -func _swig_getEXPR_GTE() (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_EXPR_GTE, _swig_p) - return -} -var EXPR_GTE int = _swig_getEXPR_GTE() -var _wrap_EXPR_INEQUALITY unsafe.Pointer - -func _swig_getEXPR_INEQUALITY() (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_EXPR_INEQUALITY, _swig_p) - return -} -var EXPR_INEQUALITY int = _swig_getEXPR_INEQUALITY() -var _wrap_EXPR_EQUALITY unsafe.Pointer - -func _swig_getEXPR_EQUALITY() (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_EXPR_EQUALITY, _swig_p) - return -} -var EXPR_EQUALITY int = _swig_getEXPR_EQUALITY() -var _wrap_EXPR_AND unsafe.Pointer - -func _swig_getEXPR_AND() (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_EXPR_AND, _swig_p) - return -} -var EXPR_AND int = _swig_getEXPR_AND() -var _wrap_EXPR_XOR unsafe.Pointer - -func _swig_getEXPR_XOR() (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_EXPR_XOR, _swig_p) - return -} -var EXPR_XOR int = _swig_getEXPR_XOR() -var _wrap_EXPR_OR unsafe.Pointer - -func _swig_getEXPR_OR() (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_EXPR_OR, _swig_p) - return -} -var EXPR_OR int = _swig_getEXPR_OR() -var _wrap_EXPR_LAND unsafe.Pointer - -func _swig_getEXPR_LAND() (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_EXPR_LAND, _swig_p) - return -} -var EXPR_LAND int = _swig_getEXPR_LAND() -var _wrap_EXPR_LOR unsafe.Pointer - -func _swig_getEXPR_LOR() (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_EXPR_LOR, _swig_p) - return -} -var EXPR_LOR int = _swig_getEXPR_LOR() -var _wrap_EXPR_CONDITIONAL unsafe.Pointer - -func _swig_getEXPR_CONDITIONAL() (_swig_ret float64) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_EXPR_CONDITIONAL, _swig_p) - return -} -var EXPR_CONDITIONAL float64 = _swig_getEXPR_CONDITIONAL() -type Enum_SS_MyEnum int -var _wrap_kValue unsafe.Pointer - -func _swig_getkValue() (_swig_ret Enum_SS_MyEnum) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_kValue, _swig_p) - return -} -var KValue Enum_SS_MyEnum = _swig_getkValue() - diff --git a/Examples/test-suite/go/preproc_defined.go b/Examples/test-suite/go/preproc_defined.go deleted file mode 100644 index 442480e7d..000000000 --- a/Examples/test-suite/go/preproc_defined.go +++ /dev/null @@ -1,144 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../preproc_defined.i - -package preproc_defined - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -var _wrap_call_checking unsafe.Pointer - -func Call_checking() (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_call_checking, _swig_p) - return -} -var _wrap_thing unsafe.Pointer - -func _swig_wrap_thing(base int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_thing, _swig_p) - return -} - -func Thing(arg1 int) { - _swig_wrap_thing(arg1) -} - -var _wrap_stuff unsafe.Pointer - -func _swig_wrap_stuff(base int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_stuff, _swig_p) - return -} - -func Stuff(arg1 int) { - _swig_wrap_stuff(arg1) -} - -type SwigcptrDefined uintptr - -func (p SwigcptrDefined) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrDefined) SwigIsDefined() { -} - -var _wrap_Defined_defined_set unsafe.Pointer - -func _swig_wrap_Defined_defined_set(base SwigcptrDefined, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Defined_defined_set, _swig_p) - return -} - -func (arg1 SwigcptrDefined) SetDefined(arg2 int) { - _swig_wrap_Defined_defined_set(arg1, arg2) -} - -var _wrap_Defined_defined_get unsafe.Pointer - -func _swig_wrap_Defined_defined_get(base SwigcptrDefined) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Defined_defined_get, _swig_p) - return -} - -func (arg1 SwigcptrDefined) GetDefined() (_swig_ret int) { - return _swig_wrap_Defined_defined_get(arg1) -} - -var _wrap_new_Defined unsafe.Pointer - -func _swig_wrap_new_Defined() (base SwigcptrDefined) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Defined, _swig_p) - return -} - -func NewDefined() (_swig_ret Defined) { - return _swig_wrap_new_Defined() -} - -var _wrap_delete_Defined unsafe.Pointer - -func _swig_wrap_delete_Defined(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Defined, _swig_p) - return -} - -func DeleteDefined(arg1 Defined) { - _swig_wrap_delete_Defined(arg1.Swigcptr()) -} - -type Defined interface { - Swigcptr() uintptr - SwigIsDefined() - SetDefined(arg2 int) - GetDefined() (_swig_ret int) -} - -var _wrap_bumpf unsafe.Pointer - -func _swig_wrap_bumpf(base int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_bumpf, _swig_p) - return -} - -func Bumpf(arg1 int) { - _swig_wrap_bumpf(arg1) -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/preproc_include.go b/Examples/test-suite/go/preproc_include.go deleted file mode 100644 index fd6b855f7..000000000 --- a/Examples/test-suite/go/preproc_include.go +++ /dev/null @@ -1,84 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../preproc_include.i - -package preproc_include - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -var _wrap_multiply10 unsafe.Pointer - -func Multiply10(arg1 int) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_multiply10, _swig_p) - return -} -var _wrap_multiply20 unsafe.Pointer - -func Multiply20(arg1 int) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_multiply20, _swig_p) - return -} -const PREPROC_INCLUDE_C string = "preproc_include_c.h" -var _wrap_multiply30 unsafe.Pointer - -func Multiply30(arg1 int) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_multiply30, _swig_p) - return -} -var _wrap_multiply40 unsafe.Pointer - -func Multiply40(arg1 int) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_multiply40, _swig_p) - return -} -const INCLUDE_E string = "preproc_include_e withspace.h" -var _wrap_multiply50 unsafe.Pointer - -func Multiply50(arg1 int) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_multiply50, _swig_p) - return -} -const INCLUDE_F string = "preproc_include_f withspace.h" -var _wrap_multiply60 unsafe.Pointer - -func Multiply60(arg1 int) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_multiply60, _swig_p) - return -} -var _wrap_multiply70 unsafe.Pointer - -func Multiply70(arg1 int) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_multiply70, _swig_p) - return -} -const Const1 int = 1 -const Const2 int = 2 -const Const3 int = 3 - diff --git a/Examples/test-suite/go/preproc_line_file.go b/Examples/test-suite/go/preproc_line_file.go deleted file mode 100644 index ab0fe1ea9..000000000 --- a/Examples/test-suite/go/preproc_line_file.go +++ /dev/null @@ -1,316 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../preproc_line_file.i - -package preproc_line_file - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -const MYLINE int = 4 -const MYLINE_ADJUSTED int = 5+100 -const MYFILE string = "./../preproc_line_file.i" -const MYFILE_ADJUSTED string = "./../preproc_line_file.i.bak" -const MY_STRINGNUM_A string = "my15" -const MY_STRINGNUM_B string = "my16" -var _wrap_thing27_get unsafe.Pointer - -func GetThing27() (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_thing27_get, _swig_p) - return -} -var _wrap_thing28_get unsafe.Pointer - -func GetThing28() (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_thing28_get, _swig_p) - return -} -const MYLINE2 int = 30 -type SwigcptrSillyStruct uintptr - -func (p SwigcptrSillyStruct) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrSillyStruct) SwigIsSillyStruct() { -} - -var _wrap_SillyStruct_num_set unsafe.Pointer - -func _swig_wrap_SillyStruct_num_set(base SwigcptrSillyStruct, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_SillyStruct_num_set, _swig_p) - return -} - -func (arg1 SwigcptrSillyStruct) SetNum(arg2 int) { - _swig_wrap_SillyStruct_num_set(arg1, arg2) -} - -var _wrap_SillyStruct_num_get unsafe.Pointer - -func _swig_wrap_SillyStruct_num_get(base SwigcptrSillyStruct) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_SillyStruct_num_get, _swig_p) - return -} - -func (arg1 SwigcptrSillyStruct) GetNum() (_swig_ret int) { - return _swig_wrap_SillyStruct_num_get(arg1) -} - -var _wrap_new_SillyStruct unsafe.Pointer - -func _swig_wrap_new_SillyStruct() (base SwigcptrSillyStruct) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_SillyStruct, _swig_p) - return -} - -func NewSillyStruct() (_swig_ret SillyStruct) { - return _swig_wrap_new_SillyStruct() -} - -var _wrap_delete_SillyStruct unsafe.Pointer - -func _swig_wrap_delete_SillyStruct(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_SillyStruct, _swig_p) - return -} - -func DeleteSillyStruct(arg1 SillyStruct) { - _swig_wrap_delete_SillyStruct(arg1.Swigcptr()) -} - -type SillyStruct interface { - Swigcptr() uintptr - SwigIsSillyStruct() - SetNum(arg2 int) - GetNum() (_swig_ret int) -} - -type SwigcptrSillyMacroClass uintptr - -func (p SwigcptrSillyMacroClass) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrSillyMacroClass) SwigIsSillyMacroClass() { -} - -var _wrap_SillyMacroClass_num_set unsafe.Pointer - -func _swig_wrap_SillyMacroClass_num_set(base SwigcptrSillyMacroClass, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_SillyMacroClass_num_set, _swig_p) - return -} - -func (arg1 SwigcptrSillyMacroClass) SetNum(arg2 int) { - _swig_wrap_SillyMacroClass_num_set(arg1, arg2) -} - -var _wrap_SillyMacroClass_num_get unsafe.Pointer - -func _swig_wrap_SillyMacroClass_num_get(base SwigcptrSillyMacroClass) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_SillyMacroClass_num_get, _swig_p) - return -} - -func (arg1 SwigcptrSillyMacroClass) GetNum() (_swig_ret int) { - return _swig_wrap_SillyMacroClass_num_get(arg1) -} - -var _wrap_new_SillyMacroClass unsafe.Pointer - -func _swig_wrap_new_SillyMacroClass() (base SwigcptrSillyMacroClass) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_SillyMacroClass, _swig_p) - return -} - -func NewSillyMacroClass() (_swig_ret SillyMacroClass) { - return _swig_wrap_new_SillyMacroClass() -} - -var _wrap_delete_SillyMacroClass unsafe.Pointer - -func _swig_wrap_delete_SillyMacroClass(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_SillyMacroClass, _swig_p) - return -} - -func DeleteSillyMacroClass(arg1 SillyMacroClass) { - _swig_wrap_delete_SillyMacroClass(arg1.Swigcptr()) -} - -type SillyMacroClass interface { - Swigcptr() uintptr - SwigIsSillyMacroClass() - SetNum(arg2 int) - GetNum() (_swig_ret int) -} - -type SwigcptrSillyMultipleMacroStruct uintptr - -func (p SwigcptrSillyMultipleMacroStruct) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrSillyMultipleMacroStruct) SwigIsSillyMultipleMacroStruct() { -} - -var _wrap_SillyMultipleMacroStruct_num_set unsafe.Pointer - -func _swig_wrap_SillyMultipleMacroStruct_num_set(base SwigcptrSillyMultipleMacroStruct, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_SillyMultipleMacroStruct_num_set, _swig_p) - return -} - -func (arg1 SwigcptrSillyMultipleMacroStruct) SetNum(arg2 int) { - _swig_wrap_SillyMultipleMacroStruct_num_set(arg1, arg2) -} - -var _wrap_SillyMultipleMacroStruct_num_get unsafe.Pointer - -func _swig_wrap_SillyMultipleMacroStruct_num_get(base SwigcptrSillyMultipleMacroStruct) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_SillyMultipleMacroStruct_num_get, _swig_p) - return -} - -func (arg1 SwigcptrSillyMultipleMacroStruct) GetNum() (_swig_ret int) { - return _swig_wrap_SillyMultipleMacroStruct_num_get(arg1) -} - -var _wrap_new_SillyMultipleMacroStruct unsafe.Pointer - -func _swig_wrap_new_SillyMultipleMacroStruct() (base SwigcptrSillyMultipleMacroStruct) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_SillyMultipleMacroStruct, _swig_p) - return -} - -func NewSillyMultipleMacroStruct() (_swig_ret SillyMultipleMacroStruct) { - return _swig_wrap_new_SillyMultipleMacroStruct() -} - -var _wrap_delete_SillyMultipleMacroStruct unsafe.Pointer - -func _swig_wrap_delete_SillyMultipleMacroStruct(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_SillyMultipleMacroStruct, _swig_p) - return -} - -func DeleteSillyMultipleMacroStruct(arg1 SillyMultipleMacroStruct) { - _swig_wrap_delete_SillyMultipleMacroStruct(arg1.Swigcptr()) -} - -type SillyMultipleMacroStruct interface { - Swigcptr() uintptr - SwigIsSillyMultipleMacroStruct() - SetNum(arg2 int) - GetNum() (_swig_ret int) -} - -const INLINE_FILE string = "./../preproc_line_file.i" -const INLINE_LINE int = 87 -type SwigcptrSlash uintptr - -func (p SwigcptrSlash) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrSlash) SwigIsSlash() { -} - -var _wrap_Slash_num_set unsafe.Pointer - -func _swig_wrap_Slash_num_set(base SwigcptrSlash, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Slash_num_set, _swig_p) - return -} - -func (arg1 SwigcptrSlash) SetNum(arg2 int) { - _swig_wrap_Slash_num_set(arg1, arg2) -} - -var _wrap_Slash_num_get unsafe.Pointer - -func _swig_wrap_Slash_num_get(base SwigcptrSlash) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Slash_num_get, _swig_p) - return -} - -func (arg1 SwigcptrSlash) GetNum() (_swig_ret int) { - return _swig_wrap_Slash_num_get(arg1) -} - -var _wrap_new_Slash unsafe.Pointer - -func _swig_wrap_new_Slash() (base SwigcptrSlash) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Slash, _swig_p) - return -} - -func NewSlash() (_swig_ret Slash) { - return _swig_wrap_new_Slash() -} - -var _wrap_delete_Slash unsafe.Pointer - -func _swig_wrap_delete_Slash(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Slash, _swig_p) - return -} - -func DeleteSlash(arg1 Slash) { - _swig_wrap_delete_Slash(arg1.Swigcptr()) -} - -type Slash interface { - Swigcptr() uintptr - SwigIsSlash() - SetNum(arg2 int) - GetNum() (_swig_ret int) -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/preproc_runme b/Examples/test-suite/go/preproc_runme deleted file mode 100755 index 1f6e6c4dc..000000000 Binary files a/Examples/test-suite/go/preproc_runme and /dev/null differ diff --git a/Examples/test-suite/go/primitive_ref.go b/Examples/test-suite/go/primitive_ref.go deleted file mode 100644 index 3e21da11f..000000000 --- a/Examples/test-suite/go/primitive_ref.go +++ /dev/null @@ -1,233 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../primitive_ref.i - -package primitive_ref - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -var _wrap_ref_int unsafe.Pointer - -func Ref_int(arg1 int) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_ref_int, _swig_p) - return -} -var _wrap_ref_uint unsafe.Pointer - -func Ref_uint(arg1 uint) (_swig_ret uint) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_ref_uint, _swig_p) - return -} -var _wrap_ref_short unsafe.Pointer - -func Ref_short(arg1 int16) (_swig_ret int16) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_ref_short, _swig_p) - return -} -var _wrap_ref_ushort unsafe.Pointer - -func Ref_ushort(arg1 uint16) (_swig_ret uint16) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_ref_ushort, _swig_p) - return -} -var _wrap_ref_long unsafe.Pointer - -func Ref_long(arg1 int64) (_swig_ret int64) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_ref_long, _swig_p) - return -} -var _wrap_ref_ulong unsafe.Pointer - -func Ref_ulong(arg1 uint64) (_swig_ret uint64) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_ref_ulong, _swig_p) - return -} -var _wrap_ref_schar unsafe.Pointer - -func Ref_schar(arg1 int8) (_swig_ret int8) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_ref_schar, _swig_p) - return -} -var _wrap_ref_uchar unsafe.Pointer - -func Ref_uchar(arg1 byte) (_swig_ret byte) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_ref_uchar, _swig_p) - return -} -var _wrap_ref_char unsafe.Pointer - -func Ref_char(arg1 byte) (_swig_ret byte) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_ref_char, _swig_p) - return -} -var _wrap_ref_float unsafe.Pointer - -func Ref_float(arg1 float32) (_swig_ret float32) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_ref_float, _swig_p) - return -} -var _wrap_ref_double unsafe.Pointer - -func Ref_double(arg1 float64) (_swig_ret float64) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_ref_double, _swig_p) - return -} -var _wrap_ref_bool unsafe.Pointer - -func Ref_bool(arg1 bool) (_swig_ret bool) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_ref_bool, _swig_p) - return -} -var _wrap_ref_longlong unsafe.Pointer - -func Ref_longlong(arg1 int64) (_swig_ret int64) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_ref_longlong, _swig_p) - return -} -var _wrap_ref_ulonglong unsafe.Pointer - -func Ref_ulonglong(arg1 uint64) (_swig_ret uint64) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_ref_ulonglong, _swig_p) - return -} -var _wrap_ref_over__SWIG_0 unsafe.Pointer - -func Ref_over__SWIG_0(arg1 int) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_ref_over__SWIG_0, _swig_p) - return -} -type SwigcptrA uintptr - -func (p SwigcptrA) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrA) SwigIsA() { -} - -var _wrap_A_v_set unsafe.Pointer - -func _swig_wrap_A_v_set(base SwigcptrA, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_A_v_set, _swig_p) - return -} - -func (arg1 SwigcptrA) SetV(arg2 int) { - _swig_wrap_A_v_set(arg1, arg2) -} - -var _wrap_A_v_get unsafe.Pointer - -func _swig_wrap_A_v_get(base SwigcptrA) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_A_v_get, _swig_p) - return -} - -func (arg1 SwigcptrA) GetV() (_swig_ret int) { - return _swig_wrap_A_v_get(arg1) -} - -var _wrap_new_A unsafe.Pointer - -func _swig_wrap_new_A(base int) (_ SwigcptrA) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_A, _swig_p) - return -} - -func NewA(arg1 int) (_swig_ret A) { - return _swig_wrap_new_A(arg1) -} - -var _wrap_delete_A unsafe.Pointer - -func _swig_wrap_delete_A(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_A, _swig_p) - return -} - -func DeleteA(arg1 A) { - _swig_wrap_delete_A(arg1.Swigcptr()) -} - -type A interface { - Swigcptr() uintptr - SwigIsA() - SetV(arg2 int) - GetV() (_swig_ret int) -} - -var _wrap_ref_over__SWIG_1 unsafe.Pointer - -func _swig_wrap_ref_over__SWIG_1(base uintptr) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_ref_over__SWIG_1, _swig_p) - return -} - -func Ref_over__SWIG_1(arg1 A) (_swig_ret int) { - return _swig_wrap_ref_over__SWIG_1(arg1.Swigcptr()) -} - -func Ref_over(a ...interface{}) int { - argc := len(a) - if argc == 1 { - if _, ok := a[0].(A); !ok { - goto check_1 - } - return Ref_over__SWIG_1(a[0].(A)) - } -check_1: - if argc == 1 { - return Ref_over__SWIG_0(a[0].(int)) - } - panic("No match for overloaded function call") -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/primitive_ref_runme b/Examples/test-suite/go/primitive_ref_runme deleted file mode 100755 index c43b8ae5c..000000000 Binary files a/Examples/test-suite/go/primitive_ref_runme and /dev/null differ diff --git a/Examples/test-suite/go/private_assign.go b/Examples/test-suite/go/private_assign.go deleted file mode 100644 index a1f6fe823..000000000 --- a/Examples/test-suite/go/private_assign.go +++ /dev/null @@ -1,190 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../private_assign.i - -package private_assign - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrFoo uintptr - -func (p SwigcptrFoo) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrFoo) SwigIsFoo() { -} - -var _wrap_Foo_bar unsafe.Pointer - -func _swig_wrap_Foo_bar(base SwigcptrFoo) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_bar, _swig_p) - return -} - -func (arg1 SwigcptrFoo) Bar() { - _swig_wrap_Foo_bar(arg1) -} - -var _wrap_new_Foo unsafe.Pointer - -func _swig_wrap_new_Foo() (base SwigcptrFoo) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Foo, _swig_p) - return -} - -func NewFoo() (_swig_ret Foo) { - return _swig_wrap_new_Foo() -} - -var _wrap_delete_Foo unsafe.Pointer - -func _swig_wrap_delete_Foo(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Foo, _swig_p) - return -} - -func DeleteFoo(arg1 Foo) { - _swig_wrap_delete_Foo(arg1.Swigcptr()) -} - -type Foo interface { - Swigcptr() uintptr - SwigIsFoo() - Bar() -} - -var _wrap_blah unsafe.Pointer - -func _swig_wrap_blah() (base SwigcptrFoo) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_blah, _swig_p) - return -} - -func Blah() (_swig_ret Foo) { - return _swig_wrap_blah() -} - -type SwigcptrBar uintptr - -func (p SwigcptrBar) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrBar) SwigIsBar() { -} - -var _wrap_new_Bar unsafe.Pointer - -func _swig_wrap_new_Bar() (base SwigcptrBar) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Bar, _swig_p) - return -} - -func NewBar() (_swig_ret Bar) { - return _swig_wrap_new_Bar() -} - -var _wrap_delete_Bar unsafe.Pointer - -func _swig_wrap_delete_Bar(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Bar, _swig_p) - return -} - -func DeleteBar(arg1 Bar) { - _swig_wrap_delete_Bar(arg1.Swigcptr()) -} - -type Bar interface { - Swigcptr() uintptr - SwigIsBar() -} - -type SwigcptrTROOT uintptr - -func (p SwigcptrTROOT) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrTROOT) SwigIsTROOT() { -} - -var _wrap_delete_TROOT unsafe.Pointer - -func _swig_wrap_delete_TROOT(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_TROOT, _swig_p) - return -} - -func DeleteTROOT(arg1 TROOT) { - _swig_wrap_delete_TROOT(arg1.Swigcptr()) -} - -type TROOT interface { - Swigcptr() uintptr - SwigIsTROOT() -} - -type SwigcptrA uintptr - -func (p SwigcptrA) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrA) SwigIsA() { -} - -var _wrap_delete_A unsafe.Pointer - -func _swig_wrap_delete_A(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_A, _swig_p) - return -} - -func DeleteA(arg1 A) { - _swig_wrap_delete_A(arg1.Swigcptr()) -} - -type A interface { - Swigcptr() uintptr - SwigIsA() -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/protected_rename.go b/Examples/test-suite/go/protected_rename.go deleted file mode 100644 index e0bec854d..000000000 --- a/Examples/test-suite/go/protected_rename.go +++ /dev/null @@ -1,88 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../protected_rename.i - -package protected_rename - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrFoo uintptr - -func (p SwigcptrFoo) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrFoo) SwigIsFoo() { -} - -var _wrap_Foo_x unsafe.Pointer - -func _swig_wrap_Foo_x(base SwigcptrFoo) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_x, _swig_p) - return -} - -func (arg1 SwigcptrFoo) X() { - _swig_wrap_Foo_x(arg1) -} - -var _wrap_new_Foo unsafe.Pointer - -func _swig_wrap_new_Foo() (base SwigcptrFoo) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Foo, _swig_p) - return -} - -func NewFoo() (_swig_ret Foo) { - return _swig_wrap_new_Foo() -} - -var _wrap_delete_Foo unsafe.Pointer - -func _swig_wrap_delete_Foo(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Foo, _swig_p) - return -} - -func DeleteFoo(arg1 Foo) { - _swig_wrap_delete_Foo(arg1.Swigcptr()) -} - -type Foo interface { - Swigcptr() uintptr - SwigIsFoo() - X() -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/pure_virtual.go b/Examples/test-suite/go/pure_virtual.go deleted file mode 100644 index 38b9fa74c..000000000 --- a/Examples/test-suite/go/pure_virtual.go +++ /dev/null @@ -1,537 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../pure_virtual.i - -package pure_virtual - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrA uintptr - -func (p SwigcptrA) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrA) SwigIsA() { -} - -var _wrap_delete_A unsafe.Pointer - -func _swig_wrap_delete_A(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_A, _swig_p) - return -} - -func DeleteA(arg1 A) { - _swig_wrap_delete_A(arg1.Swigcptr()) -} - -var _wrap_A_something unsafe.Pointer - -func _swig_wrap_A_something(base SwigcptrA) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_A_something, _swig_p) - return -} - -func (arg1 SwigcptrA) Something() { - _swig_wrap_A_something(arg1) -} - -var _wrap_A_method unsafe.Pointer - -func _swig_wrap_A_method(base SwigcptrA) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_A_method, _swig_p) - return -} - -func (arg1 SwigcptrA) Method() { - _swig_wrap_A_method(arg1) -} - -type A interface { - Swigcptr() uintptr - SwigIsA() - Something() - Method() -} - -type SwigcptrB uintptr - -func (p SwigcptrB) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrB) SwigIsB() { -} - -var _wrap_new_B unsafe.Pointer - -func _swig_wrap_new_B() (base SwigcptrB) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_B, _swig_p) - return -} - -func NewB() (_swig_ret B) { - return _swig_wrap_new_B() -} - -var _wrap_delete_B unsafe.Pointer - -func _swig_wrap_delete_B(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_B, _swig_p) - return -} - -func DeleteB(arg1 B) { - _swig_wrap_delete_B(arg1.Swigcptr()) -} - -var _wrap_B_something unsafe.Pointer - -func _swig_wrap_B_something(base SwigcptrB) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_B_something, _swig_p) - return -} - -func (arg1 SwigcptrB) Something() { - _swig_wrap_B_something(arg1) -} - -var _wrap_B_method unsafe.Pointer - -func _swig_wrap_B_method(base SwigcptrB) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_B_method, _swig_p) - return -} - -func (arg1 SwigcptrB) Method() { - _swig_wrap_B_method(arg1) -} - -func (p SwigcptrB) SwigIsA() { -} - -func (p SwigcptrB) SwigGetA() A { - return SwigcptrA(p.Swigcptr()) -} - -type B interface { - Swigcptr() uintptr - SwigIsB() - Something() - Method() - SwigIsA() - SwigGetA() A -} - -type SwigcptrC uintptr - -func (p SwigcptrC) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrC) SwigIsC() { -} - -var _wrap_delete_C unsafe.Pointer - -func _swig_wrap_delete_C(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_C, _swig_p) - return -} - -func DeleteC(arg1 C) { - _swig_wrap_delete_C(arg1.Swigcptr()) -} - -var _wrap_C_method unsafe.Pointer - -func _swig_wrap_C_method(base SwigcptrC) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_C_method, _swig_p) - return -} - -func (arg1 SwigcptrC) Method() { - _swig_wrap_C_method(arg1) -} - -var _wrap_C_something unsafe.Pointer - -func _swig_wrap_C_something(base SwigcptrC) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_C_something, _swig_p) - return -} - -func (_swig_base SwigcptrC) Something() { - _swig_wrap_C_something(_swig_base) -} - -func (p SwigcptrC) SwigIsA() { -} - -func (p SwigcptrC) SwigGetA() A { - return SwigcptrA(p.Swigcptr()) -} - -type C interface { - Swigcptr() uintptr - SwigIsC() - Method() - Something() - SwigIsA() - SwigGetA() A -} - -type SwigcptrD uintptr - -func (p SwigcptrD) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrD) SwigIsD() { -} - -var _wrap_delete_D unsafe.Pointer - -func _swig_wrap_delete_D(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_D, _swig_p) - return -} - -func DeleteD(arg1 D) { - _swig_wrap_delete_D(arg1.Swigcptr()) -} - -var _wrap_D_something unsafe.Pointer - -func _swig_wrap_D_something(base SwigcptrD) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_D_something, _swig_p) - return -} - -func (arg1 SwigcptrD) Something() { - _swig_wrap_D_something(arg1) -} - -var _wrap_new_D unsafe.Pointer - -func _swig_wrap_new_D() (base SwigcptrD) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_D, _swig_p) - return -} - -func NewD() (_swig_ret D) { - return _swig_wrap_new_D() -} - -var _wrap_D_method unsafe.Pointer - -func _swig_wrap_D_method(base SwigcptrD) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_D_method, _swig_p) - return -} - -func (_swig_base SwigcptrD) Method() { - _swig_wrap_D_method(_swig_base) -} - -func (p SwigcptrD) SwigIsC() { -} - -func (p SwigcptrD) SwigGetC() C { - return SwigcptrC(p.Swigcptr()) -} - -func (p SwigcptrD) SwigIsA() { -} - -func (p SwigcptrD) SwigGetA() A { - return SwigcptrA(p.Swigcptr()) -} - -type D interface { - Swigcptr() uintptr - SwigIsD() - Something() - Method() - SwigIsC() - SwigGetC() C - SwigIsA() - SwigGetA() A -} - -type SwigcptrAA uintptr - -func (p SwigcptrAA) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrAA) SwigIsAA() { -} - -var _wrap_delete_AA unsafe.Pointer - -func _swig_wrap_delete_AA(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_AA, _swig_p) - return -} - -func DeleteAA(arg1 AA) { - _swig_wrap_delete_AA(arg1.Swigcptr()) -} - -var _wrap_AA_method2 unsafe.Pointer - -func _swig_wrap_AA_method2(base SwigcptrAA) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_AA_method2, _swig_p) - return -} - -func (arg1 SwigcptrAA) Method2() { - _swig_wrap_AA_method2(arg1) -} - -type AA interface { - Swigcptr() uintptr - SwigIsAA() - Method2() -} - -type SwigcptrE uintptr - -func (p SwigcptrE) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrE) SwigIsE() { -} - -var _wrap_E_something unsafe.Pointer - -func _swig_wrap_E_something(base SwigcptrE) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_E_something, _swig_p) - return -} - -func (arg1 SwigcptrE) Something() { - _swig_wrap_E_something(arg1) -} - -var _wrap_E_method unsafe.Pointer - -func _swig_wrap_E_method(base SwigcptrE) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_E_method, _swig_p) - return -} - -func (_swig_base SwigcptrE) Method() { - _swig_wrap_E_method(_swig_base) -} - -var _wrap_E_method2 unsafe.Pointer - -func _swig_wrap_E_method2(base SwigcptrE) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_E_method2, _swig_p) - return -} - -func (_swig_base SwigcptrE) Method2() { - _swig_wrap_E_method2(_swig_base) -} - -func (p SwigcptrE) SwigIsC() { -} - -func (p SwigcptrE) SwigGetC() C { - return SwigcptrC(p.Swigcptr()) -} - -func (p SwigcptrE) SwigIsA() { -} - -func (p SwigcptrE) SwigGetA() A { - return SwigcptrA(p.Swigcptr()) -} - -var _wrap_E_SwigGetAA unsafe.Pointer - -func _swig_wrap_E_SwigGetAA(base SwigcptrE) (_ SwigcptrAA) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_E_SwigGetAA, _swig_p) - return -} - -func (arg1 SwigcptrE) SwigGetAA() (_swig_ret AA) { - return _swig_wrap_E_SwigGetAA(arg1) -} - -type E interface { - Swigcptr() uintptr - SwigIsE() - Something() - Method() - Method2() - SwigIsC() - SwigGetC() C - SwigIsA() - SwigGetA() A - SwigGetAA() (_swig_ret AA) -} - -type SwigcptrF uintptr - -func (p SwigcptrF) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrF) SwigIsF() { -} - -var _wrap_F_method2 unsafe.Pointer - -func _swig_wrap_F_method2(base SwigcptrF) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_F_method2, _swig_p) - return -} - -func (arg1 SwigcptrF) Method2() { - _swig_wrap_F_method2(arg1) -} - -var _wrap_new_F unsafe.Pointer - -func _swig_wrap_new_F() (base SwigcptrF) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_F, _swig_p) - return -} - -func NewF() (_swig_ret F) { - return _swig_wrap_new_F() -} - -var _wrap_delete_F unsafe.Pointer - -func _swig_wrap_delete_F(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_F, _swig_p) - return -} - -func DeleteF(arg1 F) { - _swig_wrap_delete_F(arg1.Swigcptr()) -} - -var _wrap_F_something unsafe.Pointer - -func _swig_wrap_F_something(base SwigcptrF) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_F_something, _swig_p) - return -} - -func (_swig_base SwigcptrF) Something() { - _swig_wrap_F_something(_swig_base) -} - -var _wrap_F_method unsafe.Pointer - -func _swig_wrap_F_method(base SwigcptrF) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_F_method, _swig_p) - return -} - -func (_swig_base SwigcptrF) Method() { - _swig_wrap_F_method(_swig_base) -} - -func (p SwigcptrF) SwigIsE() { -} - -func (p SwigcptrF) SwigGetE() E { - return SwigcptrE(p.Swigcptr()) -} - -func (p SwigcptrF) SwigIsC() { -} - -func (p SwigcptrF) SwigGetC() C { - return SwigcptrC(p.Swigcptr()) -} - -func (p SwigcptrF) SwigIsA() { -} - -func (p SwigcptrF) SwigGetA() A { - return SwigcptrA(p.Swigcptr()) -} - -func (p SwigcptrF) SwigGetAA() AA { - return p.SwigGetE().SwigGetAA() -} - -type F interface { - Swigcptr() uintptr - SwigIsF() - Method2() - Something() - Method() - SwigIsE() - SwigGetE() E - SwigIsC() - SwigGetC() C - SwigIsA() - SwigGetA() A - SwigGetAA() AA -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/redefined.go b/Examples/test-suite/go/redefined.go deleted file mode 100644 index 3326ad380..000000000 --- a/Examples/test-suite/go/redefined.go +++ /dev/null @@ -1,134 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../redefined.i - -package redefined - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -const Agua int = 0 -const REDUNDANT int = 1 -var _wrap_hello unsafe.Pointer - -func Hello(arg1 int) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_hello, _swig_p) - return -} -type SwigcptrA uintptr - -func (p SwigcptrA) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrA) SwigIsA() { -} - -var _wrap_foo unsafe.Pointer - -func _swig_wrap_foo(base uintptr, _ uintptr) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_foo, _swig_p) - return -} - -func Foo(arg1 A, arg2 B) (_swig_ret int) { - return _swig_wrap_foo(arg1.Swigcptr(), arg2.Swigcptr()) -} - -var _wrap_new_A unsafe.Pointer - -func _swig_wrap_new_A() (base SwigcptrA) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_A, _swig_p) - return -} - -func NewA() (_swig_ret A) { - return _swig_wrap_new_A() -} - -var _wrap_delete_A unsafe.Pointer - -func _swig_wrap_delete_A(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_A, _swig_p) - return -} - -func DeleteA(arg1 A) { - _swig_wrap_delete_A(arg1.Swigcptr()) -} - -type A interface { - Swigcptr() uintptr - SwigIsA() -} - -type SwigcptrB uintptr - -func (p SwigcptrB) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrB) SwigIsB() { -} - -var _wrap_new_B unsafe.Pointer - -func _swig_wrap_new_B() (base SwigcptrB) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_B, _swig_p) - return -} - -func NewB() (_swig_ret B) { - return _swig_wrap_new_B() -} - -var _wrap_delete_B unsafe.Pointer - -func _swig_wrap_delete_B(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_B, _swig_p) - return -} - -func DeleteB(arg1 B) { - _swig_wrap_delete_B(arg1.Swigcptr()) -} - -type B interface { - Swigcptr() uintptr - SwigIsB() -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/redefined_not.go b/Examples/test-suite/go/redefined_not.go deleted file mode 100644 index 73ab4b2a5..000000000 --- a/Examples/test-suite/go/redefined_not.go +++ /dev/null @@ -1,29 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../redefined_not.i - -package redefined_not - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - - diff --git a/Examples/test-suite/go/refcount.go b/Examples/test-suite/go/refcount.go deleted file mode 100644 index ddfca5b4e..000000000 --- a/Examples/test-suite/go/refcount.go +++ /dev/null @@ -1,797 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../refcount.i - -package refcount - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrRCObjBase uintptr - -func (p SwigcptrRCObjBase) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrRCObjBase) SwigIsRCObjBase() { -} - -var _wrap_RCObjBase_ref_count unsafe.Pointer - -func _swig_wrap_RCObjBase_ref_count(base SwigcptrRCObjBase) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_RCObjBase_ref_count, _swig_p) - return -} - -func (arg1 SwigcptrRCObjBase) Ref_count() (_swig_ret int) { - return _swig_wrap_RCObjBase_ref_count(arg1) -} - -var _wrap_RCObjBase_addref unsafe.Pointer - -func _swig_wrap_RCObjBase_addref(base SwigcptrRCObjBase) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_RCObjBase_addref, _swig_p) - return -} - -func (arg1 SwigcptrRCObjBase) Addref() (_swig_ret int) { - return _swig_wrap_RCObjBase_addref(arg1) -} - -var _wrap_RCObjBase_delref unsafe.Pointer - -func _swig_wrap_RCObjBase_delref(base SwigcptrRCObjBase) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_RCObjBase_delref, _swig_p) - return -} - -func (arg1 SwigcptrRCObjBase) Delref() (_swig_ret int) { - return _swig_wrap_RCObjBase_delref(arg1) -} - -type RCObjBase interface { - Swigcptr() uintptr - SwigIsRCObjBase() - Ref_count() (_swig_ret int) - Addref() (_swig_ret int) - Delref() (_swig_ret int) -} - -type SwigcptrRCObj uintptr - -func (p SwigcptrRCObj) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrRCObj) SwigIsRCObj() { -} - -var _wrap_delete_RCObj unsafe.Pointer - -func _swig_wrap_delete_RCObj(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_RCObj, _swig_p) - return -} - -func DeleteRCObj(arg1 RCObj) { - _swig_wrap_delete_RCObj(arg1.Swigcptr()) -} - -var _wrap_RCObj_ref_count unsafe.Pointer - -func _swig_wrap_RCObj_ref_count(base SwigcptrRCObj) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_RCObj_ref_count, _swig_p) - return -} - -func (_swig_base SwigcptrRCObj) Ref_count() (_swig_ret int) { - return _swig_wrap_RCObj_ref_count(_swig_base) -} - -var _wrap_RCObj_addref unsafe.Pointer - -func _swig_wrap_RCObj_addref(base SwigcptrRCObj) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_RCObj_addref, _swig_p) - return -} - -func (_swig_base SwigcptrRCObj) Addref() (_swig_ret int) { - return _swig_wrap_RCObj_addref(_swig_base) -} - -var _wrap_RCObj_delref unsafe.Pointer - -func _swig_wrap_RCObj_delref(base SwigcptrRCObj) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_RCObj_delref, _swig_p) - return -} - -func (_swig_base SwigcptrRCObj) Delref() (_swig_ret int) { - return _swig_wrap_RCObj_delref(_swig_base) -} - -func (p SwigcptrRCObj) SwigIsRCObjBase() { -} - -func (p SwigcptrRCObj) SwigGetRCObjBase() RCObjBase { - return SwigcptrRCObjBase(p.Swigcptr()) -} - -type RCObj interface { - Swigcptr() uintptr - SwigIsRCObj() - Ref_count() (_swig_ret int) - Addref() (_swig_ret int) - Delref() (_swig_ret int) - SwigIsRCObjBase() - SwigGetRCObjBase() RCObjBase -} - -type SwigcptrA uintptr - -func (p SwigcptrA) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrA) SwigIsA() { -} - -var _wrap_new_A unsafe.Pointer - -func _swig_wrap_new_A() (base SwigcptrA) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_A, _swig_p) - return -} - -func NewA() (_swig_ret A) { - return _swig_wrap_new_A() -} - -var _wrap_delete_A unsafe.Pointer - -func _swig_wrap_delete_A(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_A, _swig_p) - return -} - -func DeleteA(arg1 A) { - _swig_wrap_delete_A(arg1.Swigcptr()) -} - -var _wrap_A_ref_count unsafe.Pointer - -func _swig_wrap_A_ref_count(base SwigcptrA) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_A_ref_count, _swig_p) - return -} - -func (_swig_base SwigcptrA) Ref_count() (_swig_ret int) { - return _swig_wrap_A_ref_count(_swig_base) -} - -var _wrap_A_addref unsafe.Pointer - -func _swig_wrap_A_addref(base SwigcptrA) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_A_addref, _swig_p) - return -} - -func (_swig_base SwigcptrA) Addref() (_swig_ret int) { - return _swig_wrap_A_addref(_swig_base) -} - -var _wrap_A_delref unsafe.Pointer - -func _swig_wrap_A_delref(base SwigcptrA) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_A_delref, _swig_p) - return -} - -func (_swig_base SwigcptrA) Delref() (_swig_ret int) { - return _swig_wrap_A_delref(_swig_base) -} - -func (p SwigcptrA) SwigIsRCObj() { -} - -func (p SwigcptrA) SwigGetRCObj() RCObj { - return SwigcptrRCObj(p.Swigcptr()) -} - -func (p SwigcptrA) SwigIsRCObjBase() { -} - -func (p SwigcptrA) SwigGetRCObjBase() RCObjBase { - return SwigcptrRCObjBase(p.Swigcptr()) -} - -type A interface { - Swigcptr() uintptr - SwigIsA() - Ref_count() (_swig_ret int) - Addref() (_swig_ret int) - Delref() (_swig_ret int) - SwigIsRCObj() - SwigGetRCObj() RCObj - SwigIsRCObjBase() - SwigGetRCObjBase() RCObjBase -} - -type SwigcptrA1 uintptr - -func (p SwigcptrA1) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrA1) SwigIsA1() { -} - -var _wrap_delete_A1 unsafe.Pointer - -func _swig_wrap_delete_A1(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_A1, _swig_p) - return -} - -func DeleteA1(arg1 A1) { - _swig_wrap_delete_A1(arg1.Swigcptr()) -} - -var _wrap_A1_ref_count unsafe.Pointer - -func _swig_wrap_A1_ref_count(base SwigcptrA1) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_A1_ref_count, _swig_p) - return -} - -func (_swig_base SwigcptrA1) Ref_count() (_swig_ret int) { - return _swig_wrap_A1_ref_count(_swig_base) -} - -var _wrap_A1_addref unsafe.Pointer - -func _swig_wrap_A1_addref(base SwigcptrA1) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_A1_addref, _swig_p) - return -} - -func (_swig_base SwigcptrA1) Addref() (_swig_ret int) { - return _swig_wrap_A1_addref(_swig_base) -} - -var _wrap_A1_delref unsafe.Pointer - -func _swig_wrap_A1_delref(base SwigcptrA1) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_A1_delref, _swig_p) - return -} - -func (_swig_base SwigcptrA1) Delref() (_swig_ret int) { - return _swig_wrap_A1_delref(_swig_base) -} - -func (p SwigcptrA1) SwigIsA() { -} - -func (p SwigcptrA1) SwigGetA() A { - return SwigcptrA(p.Swigcptr()) -} - -func (p SwigcptrA1) SwigIsRCObj() { -} - -func (p SwigcptrA1) SwigGetRCObj() RCObj { - return SwigcptrRCObj(p.Swigcptr()) -} - -func (p SwigcptrA1) SwigIsRCObjBase() { -} - -func (p SwigcptrA1) SwigGetRCObjBase() RCObjBase { - return SwigcptrRCObjBase(p.Swigcptr()) -} - -type A1 interface { - Swigcptr() uintptr - SwigIsA1() - Ref_count() (_swig_ret int) - Addref() (_swig_ret int) - Delref() (_swig_ret int) - SwigIsA() - SwigGetA() A - SwigIsRCObj() - SwigGetRCObj() RCObj - SwigIsRCObjBase() - SwigGetRCObjBase() RCObjBase -} - -type SwigcptrA2 uintptr - -func (p SwigcptrA2) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrA2) SwigIsA2() { -} - -var _wrap_new_A2 unsafe.Pointer - -func _swig_wrap_new_A2() (base SwigcptrA2) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_A2, _swig_p) - return -} - -func NewA2() (_swig_ret A2) { - return _swig_wrap_new_A2() -} - -var _wrap_delete_A2 unsafe.Pointer - -func _swig_wrap_delete_A2(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_A2, _swig_p) - return -} - -func DeleteA2(arg1 A2) { - _swig_wrap_delete_A2(arg1.Swigcptr()) -} - -var _wrap_A2_ref_count unsafe.Pointer - -func _swig_wrap_A2_ref_count(base SwigcptrA2) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_A2_ref_count, _swig_p) - return -} - -func (_swig_base SwigcptrA2) Ref_count() (_swig_ret int) { - return _swig_wrap_A2_ref_count(_swig_base) -} - -var _wrap_A2_addref unsafe.Pointer - -func _swig_wrap_A2_addref(base SwigcptrA2) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_A2_addref, _swig_p) - return -} - -func (_swig_base SwigcptrA2) Addref() (_swig_ret int) { - return _swig_wrap_A2_addref(_swig_base) -} - -var _wrap_A2_delref unsafe.Pointer - -func _swig_wrap_A2_delref(base SwigcptrA2) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_A2_delref, _swig_p) - return -} - -func (_swig_base SwigcptrA2) Delref() (_swig_ret int) { - return _swig_wrap_A2_delref(_swig_base) -} - -func (p SwigcptrA2) SwigIsA() { -} - -func (p SwigcptrA2) SwigGetA() A { - return SwigcptrA(p.Swigcptr()) -} - -func (p SwigcptrA2) SwigIsRCObj() { -} - -func (p SwigcptrA2) SwigGetRCObj() RCObj { - return SwigcptrRCObj(p.Swigcptr()) -} - -func (p SwigcptrA2) SwigIsRCObjBase() { -} - -func (p SwigcptrA2) SwigGetRCObjBase() RCObjBase { - return SwigcptrRCObjBase(p.Swigcptr()) -} - -type A2 interface { - Swigcptr() uintptr - SwigIsA2() - Ref_count() (_swig_ret int) - Addref() (_swig_ret int) - Delref() (_swig_ret int) - SwigIsA() - SwigGetA() A - SwigIsRCObj() - SwigGetRCObj() RCObj - SwigIsRCObjBase() - SwigGetRCObjBase() RCObjBase -} - -type SwigcptrA3 uintptr - -func (p SwigcptrA3) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrA3) SwigIsA3() { -} - -var _wrap_new_A3 unsafe.Pointer - -func _swig_wrap_new_A3() (base SwigcptrA3) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_A3, _swig_p) - return -} - -func NewA3() (_swig_ret A3) { - return _swig_wrap_new_A3() -} - -var _wrap_delete_A3 unsafe.Pointer - -func _swig_wrap_delete_A3(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_A3, _swig_p) - return -} - -func DeleteA3(arg1 A3) { - _swig_wrap_delete_A3(arg1.Swigcptr()) -} - -var _wrap_A3_ref_count unsafe.Pointer - -func _swig_wrap_A3_ref_count(base SwigcptrA3) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_A3_ref_count, _swig_p) - return -} - -func (_swig_base SwigcptrA3) Ref_count() (_swig_ret int) { - return _swig_wrap_A3_ref_count(_swig_base) -} - -var _wrap_A3_addref unsafe.Pointer - -func _swig_wrap_A3_addref(base SwigcptrA3) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_A3_addref, _swig_p) - return -} - -func (_swig_base SwigcptrA3) Addref() (_swig_ret int) { - return _swig_wrap_A3_addref(_swig_base) -} - -var _wrap_A3_delref unsafe.Pointer - -func _swig_wrap_A3_delref(base SwigcptrA3) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_A3_delref, _swig_p) - return -} - -func (_swig_base SwigcptrA3) Delref() (_swig_ret int) { - return _swig_wrap_A3_delref(_swig_base) -} - -func (p SwigcptrA3) SwigIsA1() { -} - -func (p SwigcptrA3) SwigGetA1() A1 { - return SwigcptrA1(p.Swigcptr()) -} - -func (p SwigcptrA3) SwigIsA() { -} - -func (p SwigcptrA3) SwigGetA() A { - return SwigcptrA(p.Swigcptr()) -} - -func (p SwigcptrA3) SwigIsRCObj() { -} - -func (p SwigcptrA3) SwigGetRCObj() RCObj { - return SwigcptrRCObj(p.Swigcptr()) -} - -func (p SwigcptrA3) SwigIsRCObjBase() { -} - -func (p SwigcptrA3) SwigGetRCObjBase() RCObjBase { - return SwigcptrRCObjBase(p.Swigcptr()) -} - -type A3 interface { - Swigcptr() uintptr - SwigIsA3() - Ref_count() (_swig_ret int) - Addref() (_swig_ret int) - Delref() (_swig_ret int) - SwigIsA1() - SwigGetA1() A1 - SwigIsA() - SwigGetA() A - SwigIsRCObj() - SwigGetRCObj() RCObj - SwigIsRCObjBase() - SwigGetRCObjBase() RCObjBase -} - -type SwigcptrB uintptr - -func (p SwigcptrB) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrB) SwigIsB() { -} - -var _wrap_new_B unsafe.Pointer - -func _swig_wrap_new_B(base uintptr) (_ SwigcptrB) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_B, _swig_p) - return -} - -func NewB(arg1 A) (_swig_ret B) { - return _swig_wrap_new_B(arg1.Swigcptr()) -} - -var _wrap_B_get_a unsafe.Pointer - -func _swig_wrap_B_get_a(base SwigcptrB) (_ SwigcptrA) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_B_get_a, _swig_p) - return -} - -func (arg1 SwigcptrB) Get_a() (_swig_ret A) { - return _swig_wrap_B_get_a(arg1) -} - -var _wrap_B_create unsafe.Pointer - -func _swig_wrap_B_create(base uintptr) (_ SwigcptrB) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_B_create, _swig_p) - return -} - -func BCreate(arg1 A) (_swig_ret B) { - return _swig_wrap_B_create(arg1.Swigcptr()) -} - -var _wrap_B_cloner unsafe.Pointer - -func _swig_wrap_B_cloner(base SwigcptrB) (_ SwigcptrB) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_B_cloner, _swig_p) - return -} - -func (arg1 SwigcptrB) Cloner() (_swig_ret B) { - return _swig_wrap_B_cloner(arg1) -} - -var _wrap_delete_B unsafe.Pointer - -func _swig_wrap_delete_B(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_B, _swig_p) - return -} - -func DeleteB(arg1 B) { - _swig_wrap_delete_B(arg1.Swigcptr()) -} - -var _wrap_B_get_rca unsafe.Pointer - -func _swig_wrap_B_get_rca(base SwigcptrB) (_ SwigcptrRCPtr_Sl_A_Sg_) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_B_get_rca, _swig_p) - return -} - -func (arg1 SwigcptrB) Get_rca() (_swig_ret RCPtr_Sl_A_Sg_) { - return _swig_wrap_B_get_rca(arg1) -} - -var _wrap_B_ref_count unsafe.Pointer - -func _swig_wrap_B_ref_count(base SwigcptrB) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_B_ref_count, _swig_p) - return -} - -func (_swig_base SwigcptrB) Ref_count() (_swig_ret int) { - return _swig_wrap_B_ref_count(_swig_base) -} - -var _wrap_B_addref unsafe.Pointer - -func _swig_wrap_B_addref(base SwigcptrB) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_B_addref, _swig_p) - return -} - -func (_swig_base SwigcptrB) Addref() (_swig_ret int) { - return _swig_wrap_B_addref(_swig_base) -} - -var _wrap_B_delref unsafe.Pointer - -func _swig_wrap_B_delref(base SwigcptrB) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_B_delref, _swig_p) - return -} - -func (_swig_base SwigcptrB) Delref() (_swig_ret int) { - return _swig_wrap_B_delref(_swig_base) -} - -func (p SwigcptrB) SwigIsRCObj() { -} - -func (p SwigcptrB) SwigGetRCObj() RCObj { - return SwigcptrRCObj(p.Swigcptr()) -} - -func (p SwigcptrB) SwigIsRCObjBase() { -} - -func (p SwigcptrB) SwigGetRCObjBase() RCObjBase { - return SwigcptrRCObjBase(p.Swigcptr()) -} - -type B interface { - Swigcptr() uintptr - SwigIsB() - Get_a() (_swig_ret A) - Cloner() (_swig_ret B) - Get_rca() (_swig_ret RCPtr_Sl_A_Sg_) - Ref_count() (_swig_ret int) - Addref() (_swig_ret int) - Delref() (_swig_ret int) - SwigIsRCObj() - SwigGetRCObj() RCObj - SwigIsRCObjBase() - SwigGetRCObjBase() RCObjBase -} - -var _wrap_global_create unsafe.Pointer - -func _swig_wrap_global_create(base uintptr) (_ SwigcptrB) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_global_create, _swig_p) - return -} - -func Global_create(arg1 A) (_swig_ret B) { - return _swig_wrap_global_create(arg1.Swigcptr()) -} - -type SwigcptrFactory uintptr - -func (p SwigcptrFactory) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrFactory) SwigIsFactory() { -} - -var _wrap_Factory_create unsafe.Pointer - -func _swig_wrap_Factory_create(base uintptr) (_ SwigcptrB) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Factory_create, _swig_p) - return -} - -func FactoryCreate(arg1 A) (_swig_ret B) { - return _swig_wrap_Factory_create(arg1.Swigcptr()) -} - -var _wrap_Factory_create2 unsafe.Pointer - -func _swig_wrap_Factory_create2(base SwigcptrFactory, _ uintptr) (_ SwigcptrB) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Factory_create2, _swig_p) - return -} - -func (arg1 SwigcptrFactory) Create2(arg2 A) (_swig_ret B) { - return _swig_wrap_Factory_create2(arg1, arg2.Swigcptr()) -} - -var _wrap_new_Factory unsafe.Pointer - -func _swig_wrap_new_Factory() (base SwigcptrFactory) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Factory, _swig_p) - return -} - -func NewFactory() (_swig_ret Factory) { - return _swig_wrap_new_Factory() -} - -var _wrap_delete_Factory unsafe.Pointer - -func _swig_wrap_delete_Factory(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Factory, _swig_p) - return -} - -func DeleteFactory(arg1 Factory) { - _swig_wrap_delete_Factory(arg1.Swigcptr()) -} - -type Factory interface { - Swigcptr() uintptr - SwigIsFactory() - Create2(arg2 A) (_swig_ret B) -} - - -type SwigcptrRCPtr_Sl_A_Sg_ uintptr -type RCPtr_Sl_A_Sg_ interface { - Swigcptr() uintptr; -} -func (p SwigcptrRCPtr_Sl_A_Sg_) Swigcptr() uintptr { - return uintptr(p) -} - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/refcount_runme b/Examples/test-suite/go/refcount_runme deleted file mode 100755 index b379b29f8..000000000 Binary files a/Examples/test-suite/go/refcount_runme and /dev/null differ diff --git a/Examples/test-suite/go/reference_global_vars.go b/Examples/test-suite/go/reference_global_vars.go deleted file mode 100644 index 23300088c..000000000 --- a/Examples/test-suite/go/reference_global_vars.go +++ /dev/null @@ -1,756 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../reference_global_vars.i - -package reference_global_vars - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrTestClass uintptr - -func (p SwigcptrTestClass) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrTestClass) SwigIsTestClass() { -} - -var _wrap_TestClass_num_set unsafe.Pointer - -func _swig_wrap_TestClass_num_set(base SwigcptrTestClass, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_TestClass_num_set, _swig_p) - return -} - -func (arg1 SwigcptrTestClass) SetNum(arg2 int) { - _swig_wrap_TestClass_num_set(arg1, arg2) -} - -var _wrap_TestClass_num_get unsafe.Pointer - -func _swig_wrap_TestClass_num_get(base SwigcptrTestClass) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_TestClass_num_get, _swig_p) - return -} - -func (arg1 SwigcptrTestClass) GetNum() (_swig_ret int) { - return _swig_wrap_TestClass_num_get(arg1) -} - -var _wrap_new_TestClass__SWIG_0 unsafe.Pointer - -func _swig_wrap_new_TestClass__SWIG_0(base int) (_ SwigcptrTestClass) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_TestClass__SWIG_0, _swig_p) - return -} - -func NewTestClass__SWIG_0(arg1 int) (_swig_ret TestClass) { - return _swig_wrap_new_TestClass__SWIG_0(arg1) -} - -var _wrap_new_TestClass__SWIG_1 unsafe.Pointer - -func _swig_wrap_new_TestClass__SWIG_1() (base SwigcptrTestClass) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_TestClass__SWIG_1, _swig_p) - return -} - -func NewTestClass__SWIG_1() (_swig_ret TestClass) { - return _swig_wrap_new_TestClass__SWIG_1() -} - -func NewTestClass(a ...interface{}) TestClass { - argc := len(a) - if argc == 0 { - return NewTestClass__SWIG_1() - } - if argc == 1 { - return NewTestClass__SWIG_0(a[0].(int)) - } - panic("No match for overloaded function call") -} - -var _wrap_delete_TestClass unsafe.Pointer - -func _swig_wrap_delete_TestClass(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_TestClass, _swig_p) - return -} - -func DeleteTestClass(arg1 TestClass) { - _swig_wrap_delete_TestClass(arg1.Swigcptr()) -} - -type TestClass interface { - Swigcptr() uintptr - SwigIsTestClass() - SetNum(arg2 int) - GetNum() (_swig_ret int) -} - -var _wrap_getconstTC unsafe.Pointer - -func _swig_wrap_getconstTC() (base SwigcptrTestClass) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_getconstTC, _swig_p) - return -} - -func GetconstTC() (_swig_ret TestClass) { - return _swig_wrap_getconstTC() -} - -var _wrap_var_bool_set unsafe.Pointer - -func _swig_wrap_var_bool_set(base *bool) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_var_bool_set, _swig_p) - return -} - -func SetVar_bool(arg1 *bool) { - _swig_wrap_var_bool_set(arg1) -} - -var _wrap_var_bool_get unsafe.Pointer - -func GetVar_bool() (_swig_ret *bool) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_var_bool_get, _swig_p) - return -} -var _wrap_setref_bool unsafe.Pointer - -func Setref_bool(arg1 *bool) (_swig_ret bool) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_setref_bool, _swig_p) - return -} -var _wrap_createref_bool unsafe.Pointer - -func Createref_bool(arg1 bool) (_swig_ret *bool) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_createref_bool, _swig_p) - return -} -var _wrap_value_bool unsafe.Pointer - -func Value_bool(arg1 *bool) (_swig_ret bool) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_value_bool, _swig_p) - return -} -var _wrap_var_char_set unsafe.Pointer - -func _swig_wrap_var_char_set(base *byte) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_var_char_set, _swig_p) - return -} - -func SetVar_char(arg1 *byte) { - _swig_wrap_var_char_set(arg1) -} - -var _wrap_var_char_get unsafe.Pointer - -func GetVar_char() (_swig_ret *byte) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_var_char_get, _swig_p) - return -} -var _wrap_setref_char unsafe.Pointer - -func Setref_char(arg1 *byte) (_swig_ret byte) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_setref_char, _swig_p) - return -} -var _wrap_createref_char unsafe.Pointer - -func Createref_char(arg1 byte) (_swig_ret *byte) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_createref_char, _swig_p) - return -} -var _wrap_value_char unsafe.Pointer - -func Value_char(arg1 *byte) (_swig_ret byte) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_value_char, _swig_p) - return -} -var _wrap_var_unsigned_char_set unsafe.Pointer - -func _swig_wrap_var_unsigned_char_set(base *byte) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_var_unsigned_char_set, _swig_p) - return -} - -func SetVar_unsigned_char(arg1 *byte) { - _swig_wrap_var_unsigned_char_set(arg1) -} - -var _wrap_var_unsigned_char_get unsafe.Pointer - -func GetVar_unsigned_char() (_swig_ret *byte) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_var_unsigned_char_get, _swig_p) - return -} -var _wrap_setref_unsigned_char unsafe.Pointer - -func Setref_unsigned_char(arg1 *byte) (_swig_ret byte) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_setref_unsigned_char, _swig_p) - return -} -var _wrap_createref_unsigned_char unsafe.Pointer - -func Createref_unsigned_char(arg1 byte) (_swig_ret *byte) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_createref_unsigned_char, _swig_p) - return -} -var _wrap_value_unsigned_char unsafe.Pointer - -func Value_unsigned_char(arg1 *byte) (_swig_ret byte) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_value_unsigned_char, _swig_p) - return -} -var _wrap_var_signed_char_set unsafe.Pointer - -func _swig_wrap_var_signed_char_set(base *int8) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_var_signed_char_set, _swig_p) - return -} - -func SetVar_signed_char(arg1 *int8) { - _swig_wrap_var_signed_char_set(arg1) -} - -var _wrap_var_signed_char_get unsafe.Pointer - -func GetVar_signed_char() (_swig_ret *int8) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_var_signed_char_get, _swig_p) - return -} -var _wrap_setref_signed_char unsafe.Pointer - -func Setref_signed_char(arg1 *int8) (_swig_ret int8) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_setref_signed_char, _swig_p) - return -} -var _wrap_createref_signed_char unsafe.Pointer - -func Createref_signed_char(arg1 int8) (_swig_ret *int8) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_createref_signed_char, _swig_p) - return -} -var _wrap_value_signed_char unsafe.Pointer - -func Value_signed_char(arg1 *int8) (_swig_ret int8) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_value_signed_char, _swig_p) - return -} -var _wrap_var_short_set unsafe.Pointer - -func _swig_wrap_var_short_set(base *int16) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_var_short_set, _swig_p) - return -} - -func SetVar_short(arg1 *int16) { - _swig_wrap_var_short_set(arg1) -} - -var _wrap_var_short_get unsafe.Pointer - -func GetVar_short() (_swig_ret *int16) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_var_short_get, _swig_p) - return -} -var _wrap_setref_short unsafe.Pointer - -func Setref_short(arg1 *int16) (_swig_ret int16) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_setref_short, _swig_p) - return -} -var _wrap_createref_short unsafe.Pointer - -func Createref_short(arg1 int16) (_swig_ret *int16) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_createref_short, _swig_p) - return -} -var _wrap_value_short unsafe.Pointer - -func Value_short(arg1 *int16) (_swig_ret int16) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_value_short, _swig_p) - return -} -var _wrap_var_unsigned_short_set unsafe.Pointer - -func _swig_wrap_var_unsigned_short_set(base *uint16) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_var_unsigned_short_set, _swig_p) - return -} - -func SetVar_unsigned_short(arg1 *uint16) { - _swig_wrap_var_unsigned_short_set(arg1) -} - -var _wrap_var_unsigned_short_get unsafe.Pointer - -func GetVar_unsigned_short() (_swig_ret *uint16) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_var_unsigned_short_get, _swig_p) - return -} -var _wrap_setref_unsigned_short unsafe.Pointer - -func Setref_unsigned_short(arg1 *uint16) (_swig_ret uint16) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_setref_unsigned_short, _swig_p) - return -} -var _wrap_createref_unsigned_short unsafe.Pointer - -func Createref_unsigned_short(arg1 uint16) (_swig_ret *uint16) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_createref_unsigned_short, _swig_p) - return -} -var _wrap_value_unsigned_short unsafe.Pointer - -func Value_unsigned_short(arg1 *uint16) (_swig_ret uint16) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_value_unsigned_short, _swig_p) - return -} -var _wrap_var_int_set unsafe.Pointer - -func _swig_wrap_var_int_set(base *int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_var_int_set, _swig_p) - return -} - -func SetVar_int(arg1 *int) { - _swig_wrap_var_int_set(arg1) -} - -var _wrap_var_int_get unsafe.Pointer - -func GetVar_int() (_swig_ret *int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_var_int_get, _swig_p) - return -} -var _wrap_setref_int unsafe.Pointer - -func Setref_int(arg1 *int) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_setref_int, _swig_p) - return -} -var _wrap_createref_int unsafe.Pointer - -func Createref_int(arg1 int) (_swig_ret *int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_createref_int, _swig_p) - return -} -var _wrap_value_int unsafe.Pointer - -func Value_int(arg1 *int) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_value_int, _swig_p) - return -} -var _wrap_var_unsigned_int_set unsafe.Pointer - -func _swig_wrap_var_unsigned_int_set(base *uint) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_var_unsigned_int_set, _swig_p) - return -} - -func SetVar_unsigned_int(arg1 *uint) { - _swig_wrap_var_unsigned_int_set(arg1) -} - -var _wrap_var_unsigned_int_get unsafe.Pointer - -func GetVar_unsigned_int() (_swig_ret *uint) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_var_unsigned_int_get, _swig_p) - return -} -var _wrap_setref_unsigned_int unsafe.Pointer - -func Setref_unsigned_int(arg1 *uint) (_swig_ret uint) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_setref_unsigned_int, _swig_p) - return -} -var _wrap_createref_unsigned_int unsafe.Pointer - -func Createref_unsigned_int(arg1 uint) (_swig_ret *uint) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_createref_unsigned_int, _swig_p) - return -} -var _wrap_value_unsigned_int unsafe.Pointer - -func Value_unsigned_int(arg1 *uint) (_swig_ret uint) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_value_unsigned_int, _swig_p) - return -} -var _wrap_var_long_set unsafe.Pointer - -func _swig_wrap_var_long_set(base *int64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_var_long_set, _swig_p) - return -} - -func SetVar_long(arg1 *int64) { - _swig_wrap_var_long_set(arg1) -} - -var _wrap_var_long_get unsafe.Pointer - -func GetVar_long() (_swig_ret *int64) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_var_long_get, _swig_p) - return -} -var _wrap_setref_long unsafe.Pointer - -func Setref_long(arg1 *int64) (_swig_ret int64) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_setref_long, _swig_p) - return -} -var _wrap_createref_long unsafe.Pointer - -func Createref_long(arg1 int64) (_swig_ret *int64) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_createref_long, _swig_p) - return -} -var _wrap_value_long unsafe.Pointer - -func Value_long(arg1 *int64) (_swig_ret int64) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_value_long, _swig_p) - return -} -var _wrap_var_unsigned_long_set unsafe.Pointer - -func _swig_wrap_var_unsigned_long_set(base *uint64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_var_unsigned_long_set, _swig_p) - return -} - -func SetVar_unsigned_long(arg1 *uint64) { - _swig_wrap_var_unsigned_long_set(arg1) -} - -var _wrap_var_unsigned_long_get unsafe.Pointer - -func GetVar_unsigned_long() (_swig_ret *uint64) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_var_unsigned_long_get, _swig_p) - return -} -var _wrap_setref_unsigned_long unsafe.Pointer - -func Setref_unsigned_long(arg1 *uint64) (_swig_ret uint64) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_setref_unsigned_long, _swig_p) - return -} -var _wrap_createref_unsigned_long unsafe.Pointer - -func Createref_unsigned_long(arg1 uint64) (_swig_ret *uint64) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_createref_unsigned_long, _swig_p) - return -} -var _wrap_value_unsigned_long unsafe.Pointer - -func Value_unsigned_long(arg1 *uint64) (_swig_ret uint64) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_value_unsigned_long, _swig_p) - return -} -var _wrap_var_float_set unsafe.Pointer - -func _swig_wrap_var_float_set(base *float32) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_var_float_set, _swig_p) - return -} - -func SetVar_float(arg1 *float32) { - _swig_wrap_var_float_set(arg1) -} - -var _wrap_var_float_get unsafe.Pointer - -func GetVar_float() (_swig_ret *float32) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_var_float_get, _swig_p) - return -} -var _wrap_setref_float unsafe.Pointer - -func Setref_float(arg1 *float32) (_swig_ret float32) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_setref_float, _swig_p) - return -} -var _wrap_createref_float unsafe.Pointer - -func Createref_float(arg1 float32) (_swig_ret *float32) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_createref_float, _swig_p) - return -} -var _wrap_value_float unsafe.Pointer - -func Value_float(arg1 *float32) (_swig_ret float32) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_value_float, _swig_p) - return -} -var _wrap_var_double_set unsafe.Pointer - -func _swig_wrap_var_double_set(base *float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_var_double_set, _swig_p) - return -} - -func SetVar_double(arg1 *float64) { - _swig_wrap_var_double_set(arg1) -} - -var _wrap_var_double_get unsafe.Pointer - -func GetVar_double() (_swig_ret *float64) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_var_double_get, _swig_p) - return -} -var _wrap_setref_double unsafe.Pointer - -func Setref_double(arg1 *float64) (_swig_ret float64) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_setref_double, _swig_p) - return -} -var _wrap_createref_double unsafe.Pointer - -func Createref_double(arg1 float64) (_swig_ret *float64) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_createref_double, _swig_p) - return -} -var _wrap_value_double unsafe.Pointer - -func Value_double(arg1 *float64) (_swig_ret float64) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_value_double, _swig_p) - return -} -var _wrap_var_long_long_set unsafe.Pointer - -func _swig_wrap_var_long_long_set(base *int64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_var_long_long_set, _swig_p) - return -} - -func SetVar_long_long(arg1 *int64) { - _swig_wrap_var_long_long_set(arg1) -} - -var _wrap_var_long_long_get unsafe.Pointer - -func GetVar_long_long() (_swig_ret *int64) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_var_long_long_get, _swig_p) - return -} -var _wrap_setref_long_long unsafe.Pointer - -func Setref_long_long(arg1 *int64) (_swig_ret int64) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_setref_long_long, _swig_p) - return -} -var _wrap_createref_long_long unsafe.Pointer - -func Createref_long_long(arg1 int64) (_swig_ret *int64) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_createref_long_long, _swig_p) - return -} -var _wrap_value_long_long unsafe.Pointer - -func Value_long_long(arg1 *int64) (_swig_ret int64) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_value_long_long, _swig_p) - return -} -var _wrap_var_unsigned_long_long_set unsafe.Pointer - -func _swig_wrap_var_unsigned_long_long_set(base *uint64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_var_unsigned_long_long_set, _swig_p) - return -} - -func SetVar_unsigned_long_long(arg1 *uint64) { - _swig_wrap_var_unsigned_long_long_set(arg1) -} - -var _wrap_var_unsigned_long_long_get unsafe.Pointer - -func GetVar_unsigned_long_long() (_swig_ret *uint64) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_var_unsigned_long_long_get, _swig_p) - return -} -var _wrap_setref_unsigned_long_long unsafe.Pointer - -func Setref_unsigned_long_long(arg1 *uint64) (_swig_ret uint64) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_setref_unsigned_long_long, _swig_p) - return -} -var _wrap_createref_unsigned_long_long unsafe.Pointer - -func Createref_unsigned_long_long(arg1 uint64) (_swig_ret *uint64) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_createref_unsigned_long_long, _swig_p) - return -} -var _wrap_value_unsigned_long_long unsafe.Pointer - -func Value_unsigned_long_long(arg1 *uint64) (_swig_ret uint64) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_value_unsigned_long_long, _swig_p) - return -} -var _wrap_var_TestClass_set unsafe.Pointer - -func _swig_wrap_var_TestClass_set(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_var_TestClass_set, _swig_p) - return -} - -func SetVar_TestClass(arg1 TestClass) { - _swig_wrap_var_TestClass_set(arg1.Swigcptr()) -} - -var _wrap_var_TestClass_get unsafe.Pointer - -func _swig_wrap_var_TestClass_get() (base SwigcptrTestClass) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_var_TestClass_get, _swig_p) - return -} - -func GetVar_TestClass() (_swig_ret TestClass) { - return _swig_wrap_var_TestClass_get() -} - -var _wrap_setref_TestClass unsafe.Pointer - -func _swig_wrap_setref_TestClass(base uintptr) (_ SwigcptrTestClass) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_setref_TestClass, _swig_p) - return -} - -func Setref_TestClass(arg1 TestClass) (_swig_ret TestClass) { - return _swig_wrap_setref_TestClass(arg1.Swigcptr()) -} - -var _wrap_createref_TestClass unsafe.Pointer - -func _swig_wrap_createref_TestClass(base uintptr) (_ SwigcptrTestClass) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_createref_TestClass, _swig_p) - return -} - -func Createref_TestClass(arg1 TestClass) (_swig_ret TestClass) { - return _swig_wrap_createref_TestClass(arg1.Swigcptr()) -} - -var _wrap_value_TestClass unsafe.Pointer - -func _swig_wrap_value_TestClass(base uintptr) (_ SwigcptrTestClass) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_value_TestClass, _swig_p) - return -} - -func Value_TestClass(arg1 TestClass) (_swig_ret TestClass) { - return _swig_wrap_value_TestClass(arg1.Swigcptr()) -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/reference_global_vars_runme b/Examples/test-suite/go/reference_global_vars_runme deleted file mode 100755 index f7e400a73..000000000 Binary files a/Examples/test-suite/go/reference_global_vars_runme and /dev/null differ diff --git a/Examples/test-suite/go/register_par.go b/Examples/test-suite/go/register_par.go deleted file mode 100644 index f52f46490..000000000 --- a/Examples/test-suite/go/register_par.go +++ /dev/null @@ -1,57 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../register_par.i - -package register_par - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -var _wrap_clear_tree_flags unsafe.Pointer - -func _swig_wrap_clear_tree_flags(base uintptr, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_clear_tree_flags, _swig_p) - return -} - -func Clear_tree_flags(arg1 Tree, arg2 int) { - _swig_wrap_clear_tree_flags(arg1.Swigcptr(), arg2) -} - - -type SwigcptrTree uintptr -type Tree interface { - Swigcptr() uintptr; -} -func (p SwigcptrTree) Swigcptr() uintptr { - return uintptr(p) -} - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/rename1.go b/Examples/test-suite/go/rename1.go deleted file mode 100644 index a23dc4fe1..000000000 --- a/Examples/test-suite/go/rename1.go +++ /dev/null @@ -1,1023 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../rename1.i - -package rename1 - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrKlass uintptr - -func (p SwigcptrKlass) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrKlass) SwigIsKlass() { -} - -var _wrap_new_Klass__SWIG_0 unsafe.Pointer - -func _swig_wrap_new_Klass__SWIG_0(base int) (_ SwigcptrKlass) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Klass__SWIG_0, _swig_p) - return -} - -func NewKlass__SWIG_0(arg1 int) (_swig_ret Klass) { - return _swig_wrap_new_Klass__SWIG_0(arg1) -} - -var _wrap_new_Klass__SWIG_1 unsafe.Pointer - -func _swig_wrap_new_Klass__SWIG_1() (base SwigcptrKlass) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Klass__SWIG_1, _swig_p) - return -} - -func NewKlass__SWIG_1() (_swig_ret Klass) { - return _swig_wrap_new_Klass__SWIG_1() -} - -func NewKlass(a ...interface{}) Klass { - argc := len(a) - if argc == 0 { - return NewKlass__SWIG_1() - } - if argc == 1 { - return NewKlass__SWIG_0(a[0].(int)) - } - panic("No match for overloaded function call") -} - -var _wrap_delete_Klass unsafe.Pointer - -func _swig_wrap_delete_Klass(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Klass, _swig_p) - return -} - -func DeleteKlass(arg1 Klass) { - _swig_wrap_delete_Klass(arg1.Swigcptr()) -} - -type Klass interface { - Swigcptr() uintptr - SwigIsKlass() -} - -type SwigcptrAnother uintptr - -func (p SwigcptrAnother) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrAnother) SwigIsAnother() { -} - -var _wrap_new_Another unsafe.Pointer - -func _swig_wrap_new_Another() (base SwigcptrAnother) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Another, _swig_p) - return -} - -func NewAnother() (_swig_ret Another) { - return _swig_wrap_new_Another() -} - -var _wrap_delete_Another unsafe.Pointer - -func _swig_wrap_delete_Another(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Another, _swig_p) - return -} - -func DeleteAnother(arg1 Another) { - _swig_wrap_delete_Another(arg1.Swigcptr()) -} - -type Another interface { - Swigcptr() uintptr - SwigIsAnother() -} - -type SpaceEnu int -var _wrap_En1 unsafe.Pointer - -func _swig_getEn1() (_swig_ret SpaceEnu) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_En1, _swig_p) - return -} -var En1 SpaceEnu = _swig_getEn1() -var _wrap_En2 unsafe.Pointer - -func _swig_getEn2() (_swig_ret SpaceEnu) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_En2, _swig_p) - return -} -var En2 SpaceEnu = _swig_getEn2() -var _wrap_En3 unsafe.Pointer - -func _swig_getEn3() (_swig_ret SpaceEnu) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_En3, _swig_p) - return -} -var En3 SpaceEnu = _swig_getEn3() -type SwigcptrABC uintptr - -func (p SwigcptrABC) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrABC) SwigIsABC() { -} - -var _wrap_ABC_methodABC unsafe.Pointer - -func _swig_wrap_ABC_methodABC(base SwigcptrABC, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_ABC_methodABC, _swig_p) - return -} - -func (arg1 SwigcptrABC) MethodABC(arg2 ABC) { - _swig_wrap_ABC_methodABC(arg1, arg2.Swigcptr()) -} - -var _wrap_ABC_methodKlass unsafe.Pointer - -func _swig_wrap_ABC_methodKlass(base SwigcptrABC, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_ABC_methodKlass, _swig_p) - return -} - -func (arg1 SwigcptrABC) MethodKlass(arg2 Klass) { - _swig_wrap_ABC_methodKlass(arg1, arg2.Swigcptr()) -} - -var _wrap_ABC_opABC unsafe.Pointer - -func _swig_wrap_ABC_opABC(base SwigcptrABC) (_ SwigcptrABC) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_ABC_opABC, _swig_p) - return -} - -func (arg1 SwigcptrABC) OpABC() (_swig_ret ABC) { - return _swig_wrap_ABC_opABC(arg1) -} - -var _wrap_ABC_opKlass unsafe.Pointer - -func _swig_wrap_ABC_opKlass(base SwigcptrABC) (_ SwigcptrKlass) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_ABC_opKlass, _swig_p) - return -} - -func (arg1 SwigcptrABC) OpKlass() (_swig_ret Klass) { - return _swig_wrap_ABC_opKlass(arg1) -} - -var _wrap_new_ABC unsafe.Pointer - -func _swig_wrap_new_ABC() (base SwigcptrABC) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_ABC, _swig_p) - return -} - -func NewABC() (_swig_ret ABC) { - return _swig_wrap_new_ABC() -} - -var _wrap_delete_ABC unsafe.Pointer - -func _swig_wrap_delete_ABC(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_ABC, _swig_p) - return -} - -func DeleteABC(arg1 ABC) { - _swig_wrap_delete_ABC(arg1.Swigcptr()) -} - -type ABC interface { - Swigcptr() uintptr - SwigIsABC() - MethodABC(arg2 ABC) - MethodKlass(arg2 Klass) - OpABC() (_swig_ret ABC) - OpKlass() (_swig_ret Klass) -} - -type SwigcptrXYZInt uintptr - -func (p SwigcptrXYZInt) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrXYZInt) SwigIsXYZInt() { -} - -var _wrap_XYZInt_opIntPtrA unsafe.Pointer - -func _swig_wrap_XYZInt_opIntPtrA(base SwigcptrXYZInt) (_ SwigcptrNotXYZInt) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_XYZInt_opIntPtrA, _swig_p) - return -} - -func (arg1 SwigcptrXYZInt) OpIntPtrA() (_swig_ret NotXYZInt) { - return _swig_wrap_XYZInt_opIntPtrA(arg1) -} - -var _wrap_XYZInt_opIntPtrB unsafe.Pointer - -func _swig_wrap_XYZInt_opIntPtrB(base SwigcptrXYZInt) (_ SwigcptrXYZInt) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_XYZInt_opIntPtrB, _swig_p) - return -} - -func (arg1 SwigcptrXYZInt) OpIntPtrB() (_swig_ret XYZInt) { - return _swig_wrap_XYZInt_opIntPtrB(arg1) -} - -var _wrap_XYZInt_opAnother2 unsafe.Pointer - -func _swig_wrap_XYZInt_opAnother2(base SwigcptrXYZInt) (_ SwigcptrAnother) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_XYZInt_opAnother2, _swig_p) - return -} - -func (arg1 SwigcptrXYZInt) OpAnother2() (_swig_ret Another) { - return _swig_wrap_XYZInt_opAnother2(arg1) -} - -var _wrap_XYZInt_tMethod2 unsafe.Pointer - -func _swig_wrap_XYZInt_tMethod2(base SwigcptrXYZInt, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_XYZInt_tMethod2, _swig_p) - return -} - -func (arg1 SwigcptrXYZInt) TMethod2(arg2 int) { - _swig_wrap_XYZInt_tMethod2(arg1, arg2) -} - -var _wrap_XYZInt_tMethodNotXYZ2 unsafe.Pointer - -func _swig_wrap_XYZInt_tMethodNotXYZ2(base SwigcptrXYZInt, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_XYZInt_tMethodNotXYZ2, _swig_p) - return -} - -func (arg1 SwigcptrXYZInt) TMethodNotXYZ2(arg2 NotXYZInt) { - _swig_wrap_XYZInt_tMethodNotXYZ2(arg1, arg2.Swigcptr()) -} - -var _wrap_XYZInt_tMethodXYZ2 unsafe.Pointer - -func _swig_wrap_XYZInt_tMethodXYZ2(base SwigcptrXYZInt, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_XYZInt_tMethodXYZ2, _swig_p) - return -} - -func (arg1 SwigcptrXYZInt) TMethodXYZ2(arg2 XYZInt) { - _swig_wrap_XYZInt_tMethodXYZ2(arg1, arg2.Swigcptr()) -} - -var _wrap_XYZInt_opT2 unsafe.Pointer - -func _swig_wrap_XYZInt_opT2(base SwigcptrXYZInt) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_XYZInt_opT2, _swig_p) - return -} - -func (arg1 SwigcptrXYZInt) OpT2() (_swig_ret int) { - return _swig_wrap_XYZInt_opT2(arg1) -} - -var _wrap_XYZInt_opNotXYZ2 unsafe.Pointer - -func _swig_wrap_XYZInt_opNotXYZ2(base SwigcptrXYZInt) (_ SwigcptrNotXYZInt) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_XYZInt_opNotXYZ2, _swig_p) - return -} - -func (arg1 SwigcptrXYZInt) OpNotXYZ2() (_swig_ret NotXYZInt) { - return _swig_wrap_XYZInt_opNotXYZ2(arg1) -} - -var _wrap_XYZInt_opXYZ2 unsafe.Pointer - -func _swig_wrap_XYZInt_opXYZ2(base SwigcptrXYZInt) (_ SwigcptrXYZInt) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_XYZInt_opXYZ2, _swig_p) - return -} - -func (arg1 SwigcptrXYZInt) OpXYZ2() (_swig_ret XYZInt) { - return _swig_wrap_XYZInt_opXYZ2(arg1) -} - -var _wrap_new_XYZInt unsafe.Pointer - -func _swig_wrap_new_XYZInt() (base SwigcptrXYZInt) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_XYZInt, _swig_p) - return -} - -func NewXYZInt() (_swig_ret XYZInt) { - return _swig_wrap_new_XYZInt() -} - -var _wrap_delete_XYZInt unsafe.Pointer - -func _swig_wrap_delete_XYZInt(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_XYZInt, _swig_p) - return -} - -func DeleteXYZInt(arg1 XYZInt) { - _swig_wrap_delete_XYZInt(arg1.Swigcptr()) -} - -type XYZInt interface { - Swigcptr() uintptr - SwigIsXYZInt() - OpIntPtrA() (_swig_ret NotXYZInt) - OpIntPtrB() (_swig_ret XYZInt) - OpAnother2() (_swig_ret Another) - TMethod2(arg2 int) - TMethodNotXYZ2(arg2 NotXYZInt) - TMethodXYZ2(arg2 XYZInt) - OpT2() (_swig_ret int) - OpNotXYZ2() (_swig_ret NotXYZInt) - OpXYZ2() (_swig_ret XYZInt) -} - -type SwigcptrXYZDouble uintptr - -func (p SwigcptrXYZDouble) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrXYZDouble) SwigIsXYZDouble() { -} - -var _wrap_XYZDouble_opIntPtrA unsafe.Pointer - -func _swig_wrap_XYZDouble_opIntPtrA(base SwigcptrXYZDouble) (_ SwigcptrNotXYZInt) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_XYZDouble_opIntPtrA, _swig_p) - return -} - -func (arg1 SwigcptrXYZDouble) OpIntPtrA() (_swig_ret NotXYZInt) { - return _swig_wrap_XYZDouble_opIntPtrA(arg1) -} - -var _wrap_XYZDouble_opIntPtrB unsafe.Pointer - -func _swig_wrap_XYZDouble_opIntPtrB(base SwigcptrXYZDouble) (_ SwigcptrXYZInt) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_XYZDouble_opIntPtrB, _swig_p) - return -} - -func (arg1 SwigcptrXYZDouble) OpIntPtrB() (_swig_ret XYZInt) { - return _swig_wrap_XYZDouble_opIntPtrB(arg1) -} - -var _wrap_XYZDouble_opAnother1 unsafe.Pointer - -func _swig_wrap_XYZDouble_opAnother1(base SwigcptrXYZDouble) (_ SwigcptrAnother) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_XYZDouble_opAnother1, _swig_p) - return -} - -func (arg1 SwigcptrXYZDouble) OpAnother1() (_swig_ret Another) { - return _swig_wrap_XYZDouble_opAnother1(arg1) -} - -var _wrap_XYZDouble_tMethod1 unsafe.Pointer - -func _swig_wrap_XYZDouble_tMethod1(base SwigcptrXYZDouble, _ float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_XYZDouble_tMethod1, _swig_p) - return -} - -func (arg1 SwigcptrXYZDouble) TMethod1(arg2 float64) { - _swig_wrap_XYZDouble_tMethod1(arg1, arg2) -} - -var _wrap_XYZDouble_tMethodNotXYZ1 unsafe.Pointer - -func _swig_wrap_XYZDouble_tMethodNotXYZ1(base SwigcptrXYZDouble, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_XYZDouble_tMethodNotXYZ1, _swig_p) - return -} - -func (arg1 SwigcptrXYZDouble) TMethodNotXYZ1(arg2 NotXYZDouble) { - _swig_wrap_XYZDouble_tMethodNotXYZ1(arg1, arg2.Swigcptr()) -} - -var _wrap_XYZDouble_tMethodXYZ1 unsafe.Pointer - -func _swig_wrap_XYZDouble_tMethodXYZ1(base SwigcptrXYZDouble, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_XYZDouble_tMethodXYZ1, _swig_p) - return -} - -func (arg1 SwigcptrXYZDouble) TMethodXYZ1(arg2 XYZDouble) { - _swig_wrap_XYZDouble_tMethodXYZ1(arg1, arg2.Swigcptr()) -} - -var _wrap_XYZDouble_opT1 unsafe.Pointer - -func _swig_wrap_XYZDouble_opT1(base SwigcptrXYZDouble) (_ float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_XYZDouble_opT1, _swig_p) - return -} - -func (arg1 SwigcptrXYZDouble) OpT1() (_swig_ret float64) { - return _swig_wrap_XYZDouble_opT1(arg1) -} - -var _wrap_XYZDouble_opNotXYZ1 unsafe.Pointer - -func _swig_wrap_XYZDouble_opNotXYZ1(base SwigcptrXYZDouble) (_ SwigcptrNotXYZDouble) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_XYZDouble_opNotXYZ1, _swig_p) - return -} - -func (arg1 SwigcptrXYZDouble) OpNotXYZ1() (_swig_ret NotXYZDouble) { - return _swig_wrap_XYZDouble_opNotXYZ1(arg1) -} - -var _wrap_XYZDouble_opXYZ1 unsafe.Pointer - -func _swig_wrap_XYZDouble_opXYZ1(base SwigcptrXYZDouble) (_ SwigcptrXYZDouble) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_XYZDouble_opXYZ1, _swig_p) - return -} - -func (arg1 SwigcptrXYZDouble) OpXYZ1() (_swig_ret XYZDouble) { - return _swig_wrap_XYZDouble_opXYZ1(arg1) -} - -var _wrap_new_XYZDouble unsafe.Pointer - -func _swig_wrap_new_XYZDouble() (base SwigcptrXYZDouble) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_XYZDouble, _swig_p) - return -} - -func NewXYZDouble() (_swig_ret XYZDouble) { - return _swig_wrap_new_XYZDouble() -} - -var _wrap_delete_XYZDouble unsafe.Pointer - -func _swig_wrap_delete_XYZDouble(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_XYZDouble, _swig_p) - return -} - -func DeleteXYZDouble(arg1 XYZDouble) { - _swig_wrap_delete_XYZDouble(arg1.Swigcptr()) -} - -type XYZDouble interface { - Swigcptr() uintptr - SwigIsXYZDouble() - OpIntPtrA() (_swig_ret NotXYZInt) - OpIntPtrB() (_swig_ret XYZInt) - OpAnother1() (_swig_ret Another) - TMethod1(arg2 float64) - TMethodNotXYZ1(arg2 NotXYZDouble) - TMethodXYZ1(arg2 XYZDouble) - OpT1() (_swig_ret float64) - OpNotXYZ1() (_swig_ret NotXYZDouble) - OpXYZ1() (_swig_ret XYZDouble) -} - -type SwigcptrXYZKlass uintptr - -func (p SwigcptrXYZKlass) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrXYZKlass) SwigIsXYZKlass() { -} - -var _wrap_XYZKlass_opIntPtrA unsafe.Pointer - -func _swig_wrap_XYZKlass_opIntPtrA(base SwigcptrXYZKlass) (_ SwigcptrNotXYZInt) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_XYZKlass_opIntPtrA, _swig_p) - return -} - -func (arg1 SwigcptrXYZKlass) OpIntPtrA() (_swig_ret NotXYZInt) { - return _swig_wrap_XYZKlass_opIntPtrA(arg1) -} - -var _wrap_XYZKlass_opIntPtrB unsafe.Pointer - -func _swig_wrap_XYZKlass_opIntPtrB(base SwigcptrXYZKlass) (_ SwigcptrXYZInt) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_XYZKlass_opIntPtrB, _swig_p) - return -} - -func (arg1 SwigcptrXYZKlass) OpIntPtrB() (_swig_ret XYZInt) { - return _swig_wrap_XYZKlass_opIntPtrB(arg1) -} - -var _wrap_XYZKlass_opAnother3 unsafe.Pointer - -func _swig_wrap_XYZKlass_opAnother3(base SwigcptrXYZKlass) (_ SwigcptrAnother) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_XYZKlass_opAnother3, _swig_p) - return -} - -func (arg1 SwigcptrXYZKlass) OpAnother3() (_swig_ret Another) { - return _swig_wrap_XYZKlass_opAnother3(arg1) -} - -var _wrap_XYZKlass_tMethod3 unsafe.Pointer - -func _swig_wrap_XYZKlass_tMethod3(base SwigcptrXYZKlass, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_XYZKlass_tMethod3, _swig_p) - return -} - -func (arg1 SwigcptrXYZKlass) TMethod3(arg2 Klass) { - _swig_wrap_XYZKlass_tMethod3(arg1, arg2.Swigcptr()) -} - -var _wrap_XYZKlass_tMethodNotXYZ3 unsafe.Pointer - -func _swig_wrap_XYZKlass_tMethodNotXYZ3(base SwigcptrXYZKlass, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_XYZKlass_tMethodNotXYZ3, _swig_p) - return -} - -func (arg1 SwigcptrXYZKlass) TMethodNotXYZ3(arg2 NotXYZKlass) { - _swig_wrap_XYZKlass_tMethodNotXYZ3(arg1, arg2.Swigcptr()) -} - -var _wrap_XYZKlass_tMethodXYZ3 unsafe.Pointer - -func _swig_wrap_XYZKlass_tMethodXYZ3(base SwigcptrXYZKlass, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_XYZKlass_tMethodXYZ3, _swig_p) - return -} - -func (arg1 SwigcptrXYZKlass) TMethodXYZ3(arg2 XYZKlass) { - _swig_wrap_XYZKlass_tMethodXYZ3(arg1, arg2.Swigcptr()) -} - -var _wrap_XYZKlass_opT3 unsafe.Pointer - -func _swig_wrap_XYZKlass_opT3(base SwigcptrXYZKlass) (_ SwigcptrKlass) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_XYZKlass_opT3, _swig_p) - return -} - -func (arg1 SwigcptrXYZKlass) OpT3() (_swig_ret Klass) { - return _swig_wrap_XYZKlass_opT3(arg1) -} - -var _wrap_XYZKlass_opNotXYZ3 unsafe.Pointer - -func _swig_wrap_XYZKlass_opNotXYZ3(base SwigcptrXYZKlass) (_ SwigcptrNotXYZKlass) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_XYZKlass_opNotXYZ3, _swig_p) - return -} - -func (arg1 SwigcptrXYZKlass) OpNotXYZ3() (_swig_ret NotXYZKlass) { - return _swig_wrap_XYZKlass_opNotXYZ3(arg1) -} - -var _wrap_XYZKlass_opXYZ3 unsafe.Pointer - -func _swig_wrap_XYZKlass_opXYZ3(base SwigcptrXYZKlass) (_ SwigcptrXYZKlass) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_XYZKlass_opXYZ3, _swig_p) - return -} - -func (arg1 SwigcptrXYZKlass) OpXYZ3() (_swig_ret XYZKlass) { - return _swig_wrap_XYZKlass_opXYZ3(arg1) -} - -var _wrap_new_XYZKlass unsafe.Pointer - -func _swig_wrap_new_XYZKlass() (base SwigcptrXYZKlass) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_XYZKlass, _swig_p) - return -} - -func NewXYZKlass() (_swig_ret XYZKlass) { - return _swig_wrap_new_XYZKlass() -} - -var _wrap_delete_XYZKlass unsafe.Pointer - -func _swig_wrap_delete_XYZKlass(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_XYZKlass, _swig_p) - return -} - -func DeleteXYZKlass(arg1 XYZKlass) { - _swig_wrap_delete_XYZKlass(arg1.Swigcptr()) -} - -type XYZKlass interface { - Swigcptr() uintptr - SwigIsXYZKlass() - OpIntPtrA() (_swig_ret NotXYZInt) - OpIntPtrB() (_swig_ret XYZInt) - OpAnother3() (_swig_ret Another) - TMethod3(arg2 Klass) - TMethodNotXYZ3(arg2 NotXYZKlass) - TMethodXYZ3(arg2 XYZKlass) - OpT3() (_swig_ret Klass) - OpNotXYZ3() (_swig_ret NotXYZKlass) - OpXYZ3() (_swig_ret XYZKlass) -} - -type SwigcptrXYZEnu uintptr - -func (p SwigcptrXYZEnu) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrXYZEnu) SwigIsXYZEnu() { -} - -var _wrap_XYZEnu_opIntPtrA unsafe.Pointer - -func _swig_wrap_XYZEnu_opIntPtrA(base SwigcptrXYZEnu) (_ SwigcptrNotXYZInt) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_XYZEnu_opIntPtrA, _swig_p) - return -} - -func (arg1 SwigcptrXYZEnu) OpIntPtrA() (_swig_ret NotXYZInt) { - return _swig_wrap_XYZEnu_opIntPtrA(arg1) -} - -var _wrap_XYZEnu_opIntPtrB unsafe.Pointer - -func _swig_wrap_XYZEnu_opIntPtrB(base SwigcptrXYZEnu) (_ SwigcptrXYZInt) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_XYZEnu_opIntPtrB, _swig_p) - return -} - -func (arg1 SwigcptrXYZEnu) OpIntPtrB() (_swig_ret XYZInt) { - return _swig_wrap_XYZEnu_opIntPtrB(arg1) -} - -var _wrap_XYZEnu_opAnother4 unsafe.Pointer - -func _swig_wrap_XYZEnu_opAnother4(base SwigcptrXYZEnu) (_ SwigcptrAnother) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_XYZEnu_opAnother4, _swig_p) - return -} - -func (arg1 SwigcptrXYZEnu) OpAnother4() (_swig_ret Another) { - return _swig_wrap_XYZEnu_opAnother4(arg1) -} - -var _wrap_XYZEnu_tMethod4 unsafe.Pointer - -func _swig_wrap_XYZEnu_tMethod4(base SwigcptrXYZEnu, _ SpaceEnu) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_XYZEnu_tMethod4, _swig_p) - return -} - -func (arg1 SwigcptrXYZEnu) TMethod4(arg2 SpaceEnu) { - _swig_wrap_XYZEnu_tMethod4(arg1, arg2) -} - -var _wrap_XYZEnu_tMethodNotXYZ4 unsafe.Pointer - -func _swig_wrap_XYZEnu_tMethodNotXYZ4(base SwigcptrXYZEnu, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_XYZEnu_tMethodNotXYZ4, _swig_p) - return -} - -func (arg1 SwigcptrXYZEnu) TMethodNotXYZ4(arg2 NotXYZEnu) { - _swig_wrap_XYZEnu_tMethodNotXYZ4(arg1, arg2.Swigcptr()) -} - -var _wrap_XYZEnu_tMethodXYZ4 unsafe.Pointer - -func _swig_wrap_XYZEnu_tMethodXYZ4(base SwigcptrXYZEnu, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_XYZEnu_tMethodXYZ4, _swig_p) - return -} - -func (arg1 SwigcptrXYZEnu) TMethodXYZ4(arg2 XYZEnu) { - _swig_wrap_XYZEnu_tMethodXYZ4(arg1, arg2.Swigcptr()) -} - -var _wrap_XYZEnu_opT4 unsafe.Pointer - -func _swig_wrap_XYZEnu_opT4(base SwigcptrXYZEnu) (_ SpaceEnu) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_XYZEnu_opT4, _swig_p) - return -} - -func (arg1 SwigcptrXYZEnu) OpT4() (_swig_ret SpaceEnu) { - return _swig_wrap_XYZEnu_opT4(arg1) -} - -var _wrap_XYZEnu_opNotXYZ4 unsafe.Pointer - -func _swig_wrap_XYZEnu_opNotXYZ4(base SwigcptrXYZEnu) (_ SwigcptrNotXYZEnu) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_XYZEnu_opNotXYZ4, _swig_p) - return -} - -func (arg1 SwigcptrXYZEnu) OpNotXYZ4() (_swig_ret NotXYZEnu) { - return _swig_wrap_XYZEnu_opNotXYZ4(arg1) -} - -var _wrap_XYZEnu_opXYZ4 unsafe.Pointer - -func _swig_wrap_XYZEnu_opXYZ4(base SwigcptrXYZEnu) (_ SwigcptrXYZEnu) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_XYZEnu_opXYZ4, _swig_p) - return -} - -func (arg1 SwigcptrXYZEnu) OpXYZ4() (_swig_ret XYZEnu) { - return _swig_wrap_XYZEnu_opXYZ4(arg1) -} - -var _wrap_new_XYZEnu unsafe.Pointer - -func _swig_wrap_new_XYZEnu() (base SwigcptrXYZEnu) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_XYZEnu, _swig_p) - return -} - -func NewXYZEnu() (_swig_ret XYZEnu) { - return _swig_wrap_new_XYZEnu() -} - -var _wrap_delete_XYZEnu unsafe.Pointer - -func _swig_wrap_delete_XYZEnu(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_XYZEnu, _swig_p) - return -} - -func DeleteXYZEnu(arg1 XYZEnu) { - _swig_wrap_delete_XYZEnu(arg1.Swigcptr()) -} - -type XYZEnu interface { - Swigcptr() uintptr - SwigIsXYZEnu() - OpIntPtrA() (_swig_ret NotXYZInt) - OpIntPtrB() (_swig_ret XYZInt) - OpAnother4() (_swig_ret Another) - TMethod4(arg2 SpaceEnu) - TMethodNotXYZ4(arg2 NotXYZEnu) - TMethodXYZ4(arg2 XYZEnu) - OpT4() (_swig_ret SpaceEnu) - OpNotXYZ4() (_swig_ret NotXYZEnu) - OpXYZ4() (_swig_ret XYZEnu) -} - -type SwigcptrNotXYZInt uintptr - -func (p SwigcptrNotXYZInt) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrNotXYZInt) SwigIsNotXYZInt() { -} - -var _wrap_new_NotXYZInt unsafe.Pointer - -func _swig_wrap_new_NotXYZInt() (base SwigcptrNotXYZInt) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_NotXYZInt, _swig_p) - return -} - -func NewNotXYZInt() (_swig_ret NotXYZInt) { - return _swig_wrap_new_NotXYZInt() -} - -var _wrap_delete_NotXYZInt unsafe.Pointer - -func _swig_wrap_delete_NotXYZInt(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_NotXYZInt, _swig_p) - return -} - -func DeleteNotXYZInt(arg1 NotXYZInt) { - _swig_wrap_delete_NotXYZInt(arg1.Swigcptr()) -} - -type NotXYZInt interface { - Swigcptr() uintptr - SwigIsNotXYZInt() -} - -type SwigcptrNotXYZDouble uintptr - -func (p SwigcptrNotXYZDouble) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrNotXYZDouble) SwigIsNotXYZDouble() { -} - -var _wrap_new_NotXYZDouble unsafe.Pointer - -func _swig_wrap_new_NotXYZDouble() (base SwigcptrNotXYZDouble) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_NotXYZDouble, _swig_p) - return -} - -func NewNotXYZDouble() (_swig_ret NotXYZDouble) { - return _swig_wrap_new_NotXYZDouble() -} - -var _wrap_delete_NotXYZDouble unsafe.Pointer - -func _swig_wrap_delete_NotXYZDouble(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_NotXYZDouble, _swig_p) - return -} - -func DeleteNotXYZDouble(arg1 NotXYZDouble) { - _swig_wrap_delete_NotXYZDouble(arg1.Swigcptr()) -} - -type NotXYZDouble interface { - Swigcptr() uintptr - SwigIsNotXYZDouble() -} - -type SwigcptrNotXYZKlass uintptr - -func (p SwigcptrNotXYZKlass) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrNotXYZKlass) SwigIsNotXYZKlass() { -} - -var _wrap_new_NotXYZKlass unsafe.Pointer - -func _swig_wrap_new_NotXYZKlass() (base SwigcptrNotXYZKlass) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_NotXYZKlass, _swig_p) - return -} - -func NewNotXYZKlass() (_swig_ret NotXYZKlass) { - return _swig_wrap_new_NotXYZKlass() -} - -var _wrap_delete_NotXYZKlass unsafe.Pointer - -func _swig_wrap_delete_NotXYZKlass(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_NotXYZKlass, _swig_p) - return -} - -func DeleteNotXYZKlass(arg1 NotXYZKlass) { - _swig_wrap_delete_NotXYZKlass(arg1.Swigcptr()) -} - -type NotXYZKlass interface { - Swigcptr() uintptr - SwigIsNotXYZKlass() -} - -type SwigcptrNotXYZEnu uintptr - -func (p SwigcptrNotXYZEnu) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrNotXYZEnu) SwigIsNotXYZEnu() { -} - -var _wrap_new_NotXYZEnu unsafe.Pointer - -func _swig_wrap_new_NotXYZEnu() (base SwigcptrNotXYZEnu) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_NotXYZEnu, _swig_p) - return -} - -func NewNotXYZEnu() (_swig_ret NotXYZEnu) { - return _swig_wrap_new_NotXYZEnu() -} - -var _wrap_delete_NotXYZEnu unsafe.Pointer - -func _swig_wrap_delete_NotXYZEnu(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_NotXYZEnu, _swig_p) - return -} - -func DeleteNotXYZEnu(arg1 NotXYZEnu) { - _swig_wrap_delete_NotXYZEnu(arg1.Swigcptr()) -} - -type NotXYZEnu interface { - Swigcptr() uintptr - SwigIsNotXYZEnu() -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/rename2.go b/Examples/test-suite/go/rename2.go deleted file mode 100644 index 106dc07ff..000000000 --- a/Examples/test-suite/go/rename2.go +++ /dev/null @@ -1,1023 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../rename2.i - -package rename2 - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrKlass uintptr - -func (p SwigcptrKlass) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrKlass) SwigIsKlass() { -} - -var _wrap_new_Klass__SWIG_0 unsafe.Pointer - -func _swig_wrap_new_Klass__SWIG_0(base int) (_ SwigcptrKlass) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Klass__SWIG_0, _swig_p) - return -} - -func NewKlass__SWIG_0(arg1 int) (_swig_ret Klass) { - return _swig_wrap_new_Klass__SWIG_0(arg1) -} - -var _wrap_new_Klass__SWIG_1 unsafe.Pointer - -func _swig_wrap_new_Klass__SWIG_1() (base SwigcptrKlass) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Klass__SWIG_1, _swig_p) - return -} - -func NewKlass__SWIG_1() (_swig_ret Klass) { - return _swig_wrap_new_Klass__SWIG_1() -} - -func NewKlass(a ...interface{}) Klass { - argc := len(a) - if argc == 0 { - return NewKlass__SWIG_1() - } - if argc == 1 { - return NewKlass__SWIG_0(a[0].(int)) - } - panic("No match for overloaded function call") -} - -var _wrap_delete_Klass unsafe.Pointer - -func _swig_wrap_delete_Klass(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Klass, _swig_p) - return -} - -func DeleteKlass(arg1 Klass) { - _swig_wrap_delete_Klass(arg1.Swigcptr()) -} - -type Klass interface { - Swigcptr() uintptr - SwigIsKlass() -} - -type SwigcptrAnother uintptr - -func (p SwigcptrAnother) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrAnother) SwigIsAnother() { -} - -var _wrap_new_Another unsafe.Pointer - -func _swig_wrap_new_Another() (base SwigcptrAnother) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Another, _swig_p) - return -} - -func NewAnother() (_swig_ret Another) { - return _swig_wrap_new_Another() -} - -var _wrap_delete_Another unsafe.Pointer - -func _swig_wrap_delete_Another(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Another, _swig_p) - return -} - -func DeleteAnother(arg1 Another) { - _swig_wrap_delete_Another(arg1.Swigcptr()) -} - -type Another interface { - Swigcptr() uintptr - SwigIsAnother() -} - -type SpaceEnu int -var _wrap_En1 unsafe.Pointer - -func _swig_getEn1() (_swig_ret SpaceEnu) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_En1, _swig_p) - return -} -var En1 SpaceEnu = _swig_getEn1() -var _wrap_En2 unsafe.Pointer - -func _swig_getEn2() (_swig_ret SpaceEnu) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_En2, _swig_p) - return -} -var En2 SpaceEnu = _swig_getEn2() -var _wrap_En3 unsafe.Pointer - -func _swig_getEn3() (_swig_ret SpaceEnu) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_En3, _swig_p) - return -} -var En3 SpaceEnu = _swig_getEn3() -type SwigcptrABC uintptr - -func (p SwigcptrABC) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrABC) SwigIsABC() { -} - -var _wrap_ABC_methodABC unsafe.Pointer - -func _swig_wrap_ABC_methodABC(base SwigcptrABC, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_ABC_methodABC, _swig_p) - return -} - -func (arg1 SwigcptrABC) MethodABC(arg2 ABC) { - _swig_wrap_ABC_methodABC(arg1, arg2.Swigcptr()) -} - -var _wrap_ABC_methodKlass unsafe.Pointer - -func _swig_wrap_ABC_methodKlass(base SwigcptrABC, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_ABC_methodKlass, _swig_p) - return -} - -func (arg1 SwigcptrABC) MethodKlass(arg2 Klass) { - _swig_wrap_ABC_methodKlass(arg1, arg2.Swigcptr()) -} - -var _wrap_ABC_opABC unsafe.Pointer - -func _swig_wrap_ABC_opABC(base SwigcptrABC) (_ SwigcptrABC) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_ABC_opABC, _swig_p) - return -} - -func (arg1 SwigcptrABC) OpABC() (_swig_ret ABC) { - return _swig_wrap_ABC_opABC(arg1) -} - -var _wrap_ABC_opKlass unsafe.Pointer - -func _swig_wrap_ABC_opKlass(base SwigcptrABC) (_ SwigcptrKlass) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_ABC_opKlass, _swig_p) - return -} - -func (arg1 SwigcptrABC) OpKlass() (_swig_ret Klass) { - return _swig_wrap_ABC_opKlass(arg1) -} - -var _wrap_new_ABC unsafe.Pointer - -func _swig_wrap_new_ABC() (base SwigcptrABC) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_ABC, _swig_p) - return -} - -func NewABC() (_swig_ret ABC) { - return _swig_wrap_new_ABC() -} - -var _wrap_delete_ABC unsafe.Pointer - -func _swig_wrap_delete_ABC(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_ABC, _swig_p) - return -} - -func DeleteABC(arg1 ABC) { - _swig_wrap_delete_ABC(arg1.Swigcptr()) -} - -type ABC interface { - Swigcptr() uintptr - SwigIsABC() - MethodABC(arg2 ABC) - MethodKlass(arg2 Klass) - OpABC() (_swig_ret ABC) - OpKlass() (_swig_ret Klass) -} - -type SwigcptrXYZInt uintptr - -func (p SwigcptrXYZInt) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrXYZInt) SwigIsXYZInt() { -} - -var _wrap_XYZInt_opIntPtrA unsafe.Pointer - -func _swig_wrap_XYZInt_opIntPtrA(base SwigcptrXYZInt) (_ SwigcptrNotXYZInt) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_XYZInt_opIntPtrA, _swig_p) - return -} - -func (arg1 SwigcptrXYZInt) OpIntPtrA() (_swig_ret NotXYZInt) { - return _swig_wrap_XYZInt_opIntPtrA(arg1) -} - -var _wrap_XYZInt_opIntPtrB unsafe.Pointer - -func _swig_wrap_XYZInt_opIntPtrB(base SwigcptrXYZInt) (_ SwigcptrXYZInt) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_XYZInt_opIntPtrB, _swig_p) - return -} - -func (arg1 SwigcptrXYZInt) OpIntPtrB() (_swig_ret XYZInt) { - return _swig_wrap_XYZInt_opIntPtrB(arg1) -} - -var _wrap_XYZInt_opAnother2 unsafe.Pointer - -func _swig_wrap_XYZInt_opAnother2(base SwigcptrXYZInt) (_ SwigcptrAnother) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_XYZInt_opAnother2, _swig_p) - return -} - -func (arg1 SwigcptrXYZInt) OpAnother2() (_swig_ret Another) { - return _swig_wrap_XYZInt_opAnother2(arg1) -} - -var _wrap_XYZInt_tMethod2 unsafe.Pointer - -func _swig_wrap_XYZInt_tMethod2(base SwigcptrXYZInt, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_XYZInt_tMethod2, _swig_p) - return -} - -func (arg1 SwigcptrXYZInt) TMethod2(arg2 int) { - _swig_wrap_XYZInt_tMethod2(arg1, arg2) -} - -var _wrap_XYZInt_tMethodNotXYZ2 unsafe.Pointer - -func _swig_wrap_XYZInt_tMethodNotXYZ2(base SwigcptrXYZInt, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_XYZInt_tMethodNotXYZ2, _swig_p) - return -} - -func (arg1 SwigcptrXYZInt) TMethodNotXYZ2(arg2 NotXYZInt) { - _swig_wrap_XYZInt_tMethodNotXYZ2(arg1, arg2.Swigcptr()) -} - -var _wrap_XYZInt_tMethodXYZ2 unsafe.Pointer - -func _swig_wrap_XYZInt_tMethodXYZ2(base SwigcptrXYZInt, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_XYZInt_tMethodXYZ2, _swig_p) - return -} - -func (arg1 SwigcptrXYZInt) TMethodXYZ2(arg2 XYZInt) { - _swig_wrap_XYZInt_tMethodXYZ2(arg1, arg2.Swigcptr()) -} - -var _wrap_XYZInt_opT2 unsafe.Pointer - -func _swig_wrap_XYZInt_opT2(base SwigcptrXYZInt) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_XYZInt_opT2, _swig_p) - return -} - -func (arg1 SwigcptrXYZInt) OpT2() (_swig_ret int) { - return _swig_wrap_XYZInt_opT2(arg1) -} - -var _wrap_XYZInt_opNotXYZ2 unsafe.Pointer - -func _swig_wrap_XYZInt_opNotXYZ2(base SwigcptrXYZInt) (_ SwigcptrNotXYZInt) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_XYZInt_opNotXYZ2, _swig_p) - return -} - -func (arg1 SwigcptrXYZInt) OpNotXYZ2() (_swig_ret NotXYZInt) { - return _swig_wrap_XYZInt_opNotXYZ2(arg1) -} - -var _wrap_XYZInt_opXYZ2 unsafe.Pointer - -func _swig_wrap_XYZInt_opXYZ2(base SwigcptrXYZInt) (_ SwigcptrXYZInt) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_XYZInt_opXYZ2, _swig_p) - return -} - -func (arg1 SwigcptrXYZInt) OpXYZ2() (_swig_ret XYZInt) { - return _swig_wrap_XYZInt_opXYZ2(arg1) -} - -var _wrap_new_XYZInt unsafe.Pointer - -func _swig_wrap_new_XYZInt() (base SwigcptrXYZInt) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_XYZInt, _swig_p) - return -} - -func NewXYZInt() (_swig_ret XYZInt) { - return _swig_wrap_new_XYZInt() -} - -var _wrap_delete_XYZInt unsafe.Pointer - -func _swig_wrap_delete_XYZInt(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_XYZInt, _swig_p) - return -} - -func DeleteXYZInt(arg1 XYZInt) { - _swig_wrap_delete_XYZInt(arg1.Swigcptr()) -} - -type XYZInt interface { - Swigcptr() uintptr - SwigIsXYZInt() - OpIntPtrA() (_swig_ret NotXYZInt) - OpIntPtrB() (_swig_ret XYZInt) - OpAnother2() (_swig_ret Another) - TMethod2(arg2 int) - TMethodNotXYZ2(arg2 NotXYZInt) - TMethodXYZ2(arg2 XYZInt) - OpT2() (_swig_ret int) - OpNotXYZ2() (_swig_ret NotXYZInt) - OpXYZ2() (_swig_ret XYZInt) -} - -type SwigcptrXYZDouble uintptr - -func (p SwigcptrXYZDouble) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrXYZDouble) SwigIsXYZDouble() { -} - -var _wrap_XYZDouble_opIntPtrA unsafe.Pointer - -func _swig_wrap_XYZDouble_opIntPtrA(base SwigcptrXYZDouble) (_ SwigcptrNotXYZInt) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_XYZDouble_opIntPtrA, _swig_p) - return -} - -func (arg1 SwigcptrXYZDouble) OpIntPtrA() (_swig_ret NotXYZInt) { - return _swig_wrap_XYZDouble_opIntPtrA(arg1) -} - -var _wrap_XYZDouble_opIntPtrB unsafe.Pointer - -func _swig_wrap_XYZDouble_opIntPtrB(base SwigcptrXYZDouble) (_ SwigcptrXYZInt) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_XYZDouble_opIntPtrB, _swig_p) - return -} - -func (arg1 SwigcptrXYZDouble) OpIntPtrB() (_swig_ret XYZInt) { - return _swig_wrap_XYZDouble_opIntPtrB(arg1) -} - -var _wrap_XYZDouble_opAnother1 unsafe.Pointer - -func _swig_wrap_XYZDouble_opAnother1(base SwigcptrXYZDouble) (_ SwigcptrAnother) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_XYZDouble_opAnother1, _swig_p) - return -} - -func (arg1 SwigcptrXYZDouble) OpAnother1() (_swig_ret Another) { - return _swig_wrap_XYZDouble_opAnother1(arg1) -} - -var _wrap_XYZDouble_tMethod1 unsafe.Pointer - -func _swig_wrap_XYZDouble_tMethod1(base SwigcptrXYZDouble, _ float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_XYZDouble_tMethod1, _swig_p) - return -} - -func (arg1 SwigcptrXYZDouble) TMethod1(arg2 float64) { - _swig_wrap_XYZDouble_tMethod1(arg1, arg2) -} - -var _wrap_XYZDouble_tMethodNotXYZ1 unsafe.Pointer - -func _swig_wrap_XYZDouble_tMethodNotXYZ1(base SwigcptrXYZDouble, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_XYZDouble_tMethodNotXYZ1, _swig_p) - return -} - -func (arg1 SwigcptrXYZDouble) TMethodNotXYZ1(arg2 NotXYZDouble) { - _swig_wrap_XYZDouble_tMethodNotXYZ1(arg1, arg2.Swigcptr()) -} - -var _wrap_XYZDouble_tMethodXYZ1 unsafe.Pointer - -func _swig_wrap_XYZDouble_tMethodXYZ1(base SwigcptrXYZDouble, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_XYZDouble_tMethodXYZ1, _swig_p) - return -} - -func (arg1 SwigcptrXYZDouble) TMethodXYZ1(arg2 XYZDouble) { - _swig_wrap_XYZDouble_tMethodXYZ1(arg1, arg2.Swigcptr()) -} - -var _wrap_XYZDouble_opT1 unsafe.Pointer - -func _swig_wrap_XYZDouble_opT1(base SwigcptrXYZDouble) (_ float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_XYZDouble_opT1, _swig_p) - return -} - -func (arg1 SwigcptrXYZDouble) OpT1() (_swig_ret float64) { - return _swig_wrap_XYZDouble_opT1(arg1) -} - -var _wrap_XYZDouble_opNotXYZ1 unsafe.Pointer - -func _swig_wrap_XYZDouble_opNotXYZ1(base SwigcptrXYZDouble) (_ SwigcptrNotXYZDouble) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_XYZDouble_opNotXYZ1, _swig_p) - return -} - -func (arg1 SwigcptrXYZDouble) OpNotXYZ1() (_swig_ret NotXYZDouble) { - return _swig_wrap_XYZDouble_opNotXYZ1(arg1) -} - -var _wrap_XYZDouble_opXYZ1 unsafe.Pointer - -func _swig_wrap_XYZDouble_opXYZ1(base SwigcptrXYZDouble) (_ SwigcptrXYZDouble) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_XYZDouble_opXYZ1, _swig_p) - return -} - -func (arg1 SwigcptrXYZDouble) OpXYZ1() (_swig_ret XYZDouble) { - return _swig_wrap_XYZDouble_opXYZ1(arg1) -} - -var _wrap_new_XYZDouble unsafe.Pointer - -func _swig_wrap_new_XYZDouble() (base SwigcptrXYZDouble) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_XYZDouble, _swig_p) - return -} - -func NewXYZDouble() (_swig_ret XYZDouble) { - return _swig_wrap_new_XYZDouble() -} - -var _wrap_delete_XYZDouble unsafe.Pointer - -func _swig_wrap_delete_XYZDouble(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_XYZDouble, _swig_p) - return -} - -func DeleteXYZDouble(arg1 XYZDouble) { - _swig_wrap_delete_XYZDouble(arg1.Swigcptr()) -} - -type XYZDouble interface { - Swigcptr() uintptr - SwigIsXYZDouble() - OpIntPtrA() (_swig_ret NotXYZInt) - OpIntPtrB() (_swig_ret XYZInt) - OpAnother1() (_swig_ret Another) - TMethod1(arg2 float64) - TMethodNotXYZ1(arg2 NotXYZDouble) - TMethodXYZ1(arg2 XYZDouble) - OpT1() (_swig_ret float64) - OpNotXYZ1() (_swig_ret NotXYZDouble) - OpXYZ1() (_swig_ret XYZDouble) -} - -type SwigcptrXYZKlass uintptr - -func (p SwigcptrXYZKlass) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrXYZKlass) SwigIsXYZKlass() { -} - -var _wrap_XYZKlass_opIntPtrA unsafe.Pointer - -func _swig_wrap_XYZKlass_opIntPtrA(base SwigcptrXYZKlass) (_ SwigcptrNotXYZInt) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_XYZKlass_opIntPtrA, _swig_p) - return -} - -func (arg1 SwigcptrXYZKlass) OpIntPtrA() (_swig_ret NotXYZInt) { - return _swig_wrap_XYZKlass_opIntPtrA(arg1) -} - -var _wrap_XYZKlass_opIntPtrB unsafe.Pointer - -func _swig_wrap_XYZKlass_opIntPtrB(base SwigcptrXYZKlass) (_ SwigcptrXYZInt) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_XYZKlass_opIntPtrB, _swig_p) - return -} - -func (arg1 SwigcptrXYZKlass) OpIntPtrB() (_swig_ret XYZInt) { - return _swig_wrap_XYZKlass_opIntPtrB(arg1) -} - -var _wrap_XYZKlass_opAnother3 unsafe.Pointer - -func _swig_wrap_XYZKlass_opAnother3(base SwigcptrXYZKlass) (_ SwigcptrAnother) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_XYZKlass_opAnother3, _swig_p) - return -} - -func (arg1 SwigcptrXYZKlass) OpAnother3() (_swig_ret Another) { - return _swig_wrap_XYZKlass_opAnother3(arg1) -} - -var _wrap_XYZKlass_tMethod3 unsafe.Pointer - -func _swig_wrap_XYZKlass_tMethod3(base SwigcptrXYZKlass, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_XYZKlass_tMethod3, _swig_p) - return -} - -func (arg1 SwigcptrXYZKlass) TMethod3(arg2 Klass) { - _swig_wrap_XYZKlass_tMethod3(arg1, arg2.Swigcptr()) -} - -var _wrap_XYZKlass_tMethodNotXYZ3 unsafe.Pointer - -func _swig_wrap_XYZKlass_tMethodNotXYZ3(base SwigcptrXYZKlass, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_XYZKlass_tMethodNotXYZ3, _swig_p) - return -} - -func (arg1 SwigcptrXYZKlass) TMethodNotXYZ3(arg2 NotXYZKlass) { - _swig_wrap_XYZKlass_tMethodNotXYZ3(arg1, arg2.Swigcptr()) -} - -var _wrap_XYZKlass_tMethodXYZ3 unsafe.Pointer - -func _swig_wrap_XYZKlass_tMethodXYZ3(base SwigcptrXYZKlass, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_XYZKlass_tMethodXYZ3, _swig_p) - return -} - -func (arg1 SwigcptrXYZKlass) TMethodXYZ3(arg2 XYZKlass) { - _swig_wrap_XYZKlass_tMethodXYZ3(arg1, arg2.Swigcptr()) -} - -var _wrap_XYZKlass_opT3 unsafe.Pointer - -func _swig_wrap_XYZKlass_opT3(base SwigcptrXYZKlass) (_ SwigcptrKlass) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_XYZKlass_opT3, _swig_p) - return -} - -func (arg1 SwigcptrXYZKlass) OpT3() (_swig_ret Klass) { - return _swig_wrap_XYZKlass_opT3(arg1) -} - -var _wrap_XYZKlass_opNotXYZ3 unsafe.Pointer - -func _swig_wrap_XYZKlass_opNotXYZ3(base SwigcptrXYZKlass) (_ SwigcptrNotXYZKlass) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_XYZKlass_opNotXYZ3, _swig_p) - return -} - -func (arg1 SwigcptrXYZKlass) OpNotXYZ3() (_swig_ret NotXYZKlass) { - return _swig_wrap_XYZKlass_opNotXYZ3(arg1) -} - -var _wrap_XYZKlass_opXYZ3 unsafe.Pointer - -func _swig_wrap_XYZKlass_opXYZ3(base SwigcptrXYZKlass) (_ SwigcptrXYZKlass) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_XYZKlass_opXYZ3, _swig_p) - return -} - -func (arg1 SwigcptrXYZKlass) OpXYZ3() (_swig_ret XYZKlass) { - return _swig_wrap_XYZKlass_opXYZ3(arg1) -} - -var _wrap_new_XYZKlass unsafe.Pointer - -func _swig_wrap_new_XYZKlass() (base SwigcptrXYZKlass) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_XYZKlass, _swig_p) - return -} - -func NewXYZKlass() (_swig_ret XYZKlass) { - return _swig_wrap_new_XYZKlass() -} - -var _wrap_delete_XYZKlass unsafe.Pointer - -func _swig_wrap_delete_XYZKlass(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_XYZKlass, _swig_p) - return -} - -func DeleteXYZKlass(arg1 XYZKlass) { - _swig_wrap_delete_XYZKlass(arg1.Swigcptr()) -} - -type XYZKlass interface { - Swigcptr() uintptr - SwigIsXYZKlass() - OpIntPtrA() (_swig_ret NotXYZInt) - OpIntPtrB() (_swig_ret XYZInt) - OpAnother3() (_swig_ret Another) - TMethod3(arg2 Klass) - TMethodNotXYZ3(arg2 NotXYZKlass) - TMethodXYZ3(arg2 XYZKlass) - OpT3() (_swig_ret Klass) - OpNotXYZ3() (_swig_ret NotXYZKlass) - OpXYZ3() (_swig_ret XYZKlass) -} - -type SwigcptrXYZEnu uintptr - -func (p SwigcptrXYZEnu) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrXYZEnu) SwigIsXYZEnu() { -} - -var _wrap_XYZEnu_opIntPtrA unsafe.Pointer - -func _swig_wrap_XYZEnu_opIntPtrA(base SwigcptrXYZEnu) (_ SwigcptrNotXYZInt) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_XYZEnu_opIntPtrA, _swig_p) - return -} - -func (arg1 SwigcptrXYZEnu) OpIntPtrA() (_swig_ret NotXYZInt) { - return _swig_wrap_XYZEnu_opIntPtrA(arg1) -} - -var _wrap_XYZEnu_opIntPtrB unsafe.Pointer - -func _swig_wrap_XYZEnu_opIntPtrB(base SwigcptrXYZEnu) (_ SwigcptrXYZInt) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_XYZEnu_opIntPtrB, _swig_p) - return -} - -func (arg1 SwigcptrXYZEnu) OpIntPtrB() (_swig_ret XYZInt) { - return _swig_wrap_XYZEnu_opIntPtrB(arg1) -} - -var _wrap_XYZEnu_opAnother4 unsafe.Pointer - -func _swig_wrap_XYZEnu_opAnother4(base SwigcptrXYZEnu) (_ SwigcptrAnother) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_XYZEnu_opAnother4, _swig_p) - return -} - -func (arg1 SwigcptrXYZEnu) OpAnother4() (_swig_ret Another) { - return _swig_wrap_XYZEnu_opAnother4(arg1) -} - -var _wrap_XYZEnu_tMethod4 unsafe.Pointer - -func _swig_wrap_XYZEnu_tMethod4(base SwigcptrXYZEnu, _ SpaceEnu) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_XYZEnu_tMethod4, _swig_p) - return -} - -func (arg1 SwigcptrXYZEnu) TMethod4(arg2 SpaceEnu) { - _swig_wrap_XYZEnu_tMethod4(arg1, arg2) -} - -var _wrap_XYZEnu_tMethodNotXYZ4 unsafe.Pointer - -func _swig_wrap_XYZEnu_tMethodNotXYZ4(base SwigcptrXYZEnu, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_XYZEnu_tMethodNotXYZ4, _swig_p) - return -} - -func (arg1 SwigcptrXYZEnu) TMethodNotXYZ4(arg2 NotXYZEnu) { - _swig_wrap_XYZEnu_tMethodNotXYZ4(arg1, arg2.Swigcptr()) -} - -var _wrap_XYZEnu_tMethodXYZ4 unsafe.Pointer - -func _swig_wrap_XYZEnu_tMethodXYZ4(base SwigcptrXYZEnu, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_XYZEnu_tMethodXYZ4, _swig_p) - return -} - -func (arg1 SwigcptrXYZEnu) TMethodXYZ4(arg2 XYZEnu) { - _swig_wrap_XYZEnu_tMethodXYZ4(arg1, arg2.Swigcptr()) -} - -var _wrap_XYZEnu_opT4 unsafe.Pointer - -func _swig_wrap_XYZEnu_opT4(base SwigcptrXYZEnu) (_ SpaceEnu) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_XYZEnu_opT4, _swig_p) - return -} - -func (arg1 SwigcptrXYZEnu) OpT4() (_swig_ret SpaceEnu) { - return _swig_wrap_XYZEnu_opT4(arg1) -} - -var _wrap_XYZEnu_opNotXYZ4 unsafe.Pointer - -func _swig_wrap_XYZEnu_opNotXYZ4(base SwigcptrXYZEnu) (_ SwigcptrNotXYZEnu) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_XYZEnu_opNotXYZ4, _swig_p) - return -} - -func (arg1 SwigcptrXYZEnu) OpNotXYZ4() (_swig_ret NotXYZEnu) { - return _swig_wrap_XYZEnu_opNotXYZ4(arg1) -} - -var _wrap_XYZEnu_opXYZ4 unsafe.Pointer - -func _swig_wrap_XYZEnu_opXYZ4(base SwigcptrXYZEnu) (_ SwigcptrXYZEnu) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_XYZEnu_opXYZ4, _swig_p) - return -} - -func (arg1 SwigcptrXYZEnu) OpXYZ4() (_swig_ret XYZEnu) { - return _swig_wrap_XYZEnu_opXYZ4(arg1) -} - -var _wrap_new_XYZEnu unsafe.Pointer - -func _swig_wrap_new_XYZEnu() (base SwigcptrXYZEnu) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_XYZEnu, _swig_p) - return -} - -func NewXYZEnu() (_swig_ret XYZEnu) { - return _swig_wrap_new_XYZEnu() -} - -var _wrap_delete_XYZEnu unsafe.Pointer - -func _swig_wrap_delete_XYZEnu(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_XYZEnu, _swig_p) - return -} - -func DeleteXYZEnu(arg1 XYZEnu) { - _swig_wrap_delete_XYZEnu(arg1.Swigcptr()) -} - -type XYZEnu interface { - Swigcptr() uintptr - SwigIsXYZEnu() - OpIntPtrA() (_swig_ret NotXYZInt) - OpIntPtrB() (_swig_ret XYZInt) - OpAnother4() (_swig_ret Another) - TMethod4(arg2 SpaceEnu) - TMethodNotXYZ4(arg2 NotXYZEnu) - TMethodXYZ4(arg2 XYZEnu) - OpT4() (_swig_ret SpaceEnu) - OpNotXYZ4() (_swig_ret NotXYZEnu) - OpXYZ4() (_swig_ret XYZEnu) -} - -type SwigcptrNotXYZInt uintptr - -func (p SwigcptrNotXYZInt) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrNotXYZInt) SwigIsNotXYZInt() { -} - -var _wrap_new_NotXYZInt unsafe.Pointer - -func _swig_wrap_new_NotXYZInt() (base SwigcptrNotXYZInt) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_NotXYZInt, _swig_p) - return -} - -func NewNotXYZInt() (_swig_ret NotXYZInt) { - return _swig_wrap_new_NotXYZInt() -} - -var _wrap_delete_NotXYZInt unsafe.Pointer - -func _swig_wrap_delete_NotXYZInt(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_NotXYZInt, _swig_p) - return -} - -func DeleteNotXYZInt(arg1 NotXYZInt) { - _swig_wrap_delete_NotXYZInt(arg1.Swigcptr()) -} - -type NotXYZInt interface { - Swigcptr() uintptr - SwigIsNotXYZInt() -} - -type SwigcptrNotXYZDouble uintptr - -func (p SwigcptrNotXYZDouble) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrNotXYZDouble) SwigIsNotXYZDouble() { -} - -var _wrap_new_NotXYZDouble unsafe.Pointer - -func _swig_wrap_new_NotXYZDouble() (base SwigcptrNotXYZDouble) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_NotXYZDouble, _swig_p) - return -} - -func NewNotXYZDouble() (_swig_ret NotXYZDouble) { - return _swig_wrap_new_NotXYZDouble() -} - -var _wrap_delete_NotXYZDouble unsafe.Pointer - -func _swig_wrap_delete_NotXYZDouble(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_NotXYZDouble, _swig_p) - return -} - -func DeleteNotXYZDouble(arg1 NotXYZDouble) { - _swig_wrap_delete_NotXYZDouble(arg1.Swigcptr()) -} - -type NotXYZDouble interface { - Swigcptr() uintptr - SwigIsNotXYZDouble() -} - -type SwigcptrNotXYZKlass uintptr - -func (p SwigcptrNotXYZKlass) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrNotXYZKlass) SwigIsNotXYZKlass() { -} - -var _wrap_new_NotXYZKlass unsafe.Pointer - -func _swig_wrap_new_NotXYZKlass() (base SwigcptrNotXYZKlass) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_NotXYZKlass, _swig_p) - return -} - -func NewNotXYZKlass() (_swig_ret NotXYZKlass) { - return _swig_wrap_new_NotXYZKlass() -} - -var _wrap_delete_NotXYZKlass unsafe.Pointer - -func _swig_wrap_delete_NotXYZKlass(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_NotXYZKlass, _swig_p) - return -} - -func DeleteNotXYZKlass(arg1 NotXYZKlass) { - _swig_wrap_delete_NotXYZKlass(arg1.Swigcptr()) -} - -type NotXYZKlass interface { - Swigcptr() uintptr - SwigIsNotXYZKlass() -} - -type SwigcptrNotXYZEnu uintptr - -func (p SwigcptrNotXYZEnu) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrNotXYZEnu) SwigIsNotXYZEnu() { -} - -var _wrap_new_NotXYZEnu unsafe.Pointer - -func _swig_wrap_new_NotXYZEnu() (base SwigcptrNotXYZEnu) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_NotXYZEnu, _swig_p) - return -} - -func NewNotXYZEnu() (_swig_ret NotXYZEnu) { - return _swig_wrap_new_NotXYZEnu() -} - -var _wrap_delete_NotXYZEnu unsafe.Pointer - -func _swig_wrap_delete_NotXYZEnu(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_NotXYZEnu, _swig_p) - return -} - -func DeleteNotXYZEnu(arg1 NotXYZEnu) { - _swig_wrap_delete_NotXYZEnu(arg1.Swigcptr()) -} - -type NotXYZEnu interface { - Swigcptr() uintptr - SwigIsNotXYZEnu() -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/rename3.go b/Examples/test-suite/go/rename3.go deleted file mode 100644 index ff8bcf360..000000000 --- a/Examples/test-suite/go/rename3.go +++ /dev/null @@ -1,1023 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../rename3.i - -package rename3 - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrKlass uintptr - -func (p SwigcptrKlass) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrKlass) SwigIsKlass() { -} - -var _wrap_new_Klass__SWIG_0 unsafe.Pointer - -func _swig_wrap_new_Klass__SWIG_0(base int) (_ SwigcptrKlass) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Klass__SWIG_0, _swig_p) - return -} - -func NewKlass__SWIG_0(arg1 int) (_swig_ret Klass) { - return _swig_wrap_new_Klass__SWIG_0(arg1) -} - -var _wrap_new_Klass__SWIG_1 unsafe.Pointer - -func _swig_wrap_new_Klass__SWIG_1() (base SwigcptrKlass) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Klass__SWIG_1, _swig_p) - return -} - -func NewKlass__SWIG_1() (_swig_ret Klass) { - return _swig_wrap_new_Klass__SWIG_1() -} - -func NewKlass(a ...interface{}) Klass { - argc := len(a) - if argc == 0 { - return NewKlass__SWIG_1() - } - if argc == 1 { - return NewKlass__SWIG_0(a[0].(int)) - } - panic("No match for overloaded function call") -} - -var _wrap_delete_Klass unsafe.Pointer - -func _swig_wrap_delete_Klass(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Klass, _swig_p) - return -} - -func DeleteKlass(arg1 Klass) { - _swig_wrap_delete_Klass(arg1.Swigcptr()) -} - -type Klass interface { - Swigcptr() uintptr - SwigIsKlass() -} - -type SwigcptrAnother uintptr - -func (p SwigcptrAnother) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrAnother) SwigIsAnother() { -} - -var _wrap_new_Another unsafe.Pointer - -func _swig_wrap_new_Another() (base SwigcptrAnother) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Another, _swig_p) - return -} - -func NewAnother() (_swig_ret Another) { - return _swig_wrap_new_Another() -} - -var _wrap_delete_Another unsafe.Pointer - -func _swig_wrap_delete_Another(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Another, _swig_p) - return -} - -func DeleteAnother(arg1 Another) { - _swig_wrap_delete_Another(arg1.Swigcptr()) -} - -type Another interface { - Swigcptr() uintptr - SwigIsAnother() -} - -type SpaceEnu int -var _wrap_En1 unsafe.Pointer - -func _swig_getEn1() (_swig_ret SpaceEnu) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_En1, _swig_p) - return -} -var En1 SpaceEnu = _swig_getEn1() -var _wrap_En2 unsafe.Pointer - -func _swig_getEn2() (_swig_ret SpaceEnu) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_En2, _swig_p) - return -} -var En2 SpaceEnu = _swig_getEn2() -var _wrap_En3 unsafe.Pointer - -func _swig_getEn3() (_swig_ret SpaceEnu) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_En3, _swig_p) - return -} -var En3 SpaceEnu = _swig_getEn3() -type SwigcptrABC uintptr - -func (p SwigcptrABC) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrABC) SwigIsABC() { -} - -var _wrap_ABC_methodABC unsafe.Pointer - -func _swig_wrap_ABC_methodABC(base SwigcptrABC, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_ABC_methodABC, _swig_p) - return -} - -func (arg1 SwigcptrABC) MethodABC(arg2 ABC) { - _swig_wrap_ABC_methodABC(arg1, arg2.Swigcptr()) -} - -var _wrap_ABC_methodKlass unsafe.Pointer - -func _swig_wrap_ABC_methodKlass(base SwigcptrABC, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_ABC_methodKlass, _swig_p) - return -} - -func (arg1 SwigcptrABC) MethodKlass(arg2 Klass) { - _swig_wrap_ABC_methodKlass(arg1, arg2.Swigcptr()) -} - -var _wrap_ABC_opABC unsafe.Pointer - -func _swig_wrap_ABC_opABC(base SwigcptrABC) (_ SwigcptrABC) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_ABC_opABC, _swig_p) - return -} - -func (arg1 SwigcptrABC) OpABC() (_swig_ret ABC) { - return _swig_wrap_ABC_opABC(arg1) -} - -var _wrap_ABC_opKlass unsafe.Pointer - -func _swig_wrap_ABC_opKlass(base SwigcptrABC) (_ SwigcptrKlass) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_ABC_opKlass, _swig_p) - return -} - -func (arg1 SwigcptrABC) OpKlass() (_swig_ret Klass) { - return _swig_wrap_ABC_opKlass(arg1) -} - -var _wrap_new_ABC unsafe.Pointer - -func _swig_wrap_new_ABC() (base SwigcptrABC) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_ABC, _swig_p) - return -} - -func NewABC() (_swig_ret ABC) { - return _swig_wrap_new_ABC() -} - -var _wrap_delete_ABC unsafe.Pointer - -func _swig_wrap_delete_ABC(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_ABC, _swig_p) - return -} - -func DeleteABC(arg1 ABC) { - _swig_wrap_delete_ABC(arg1.Swigcptr()) -} - -type ABC interface { - Swigcptr() uintptr - SwigIsABC() - MethodABC(arg2 ABC) - MethodKlass(arg2 Klass) - OpABC() (_swig_ret ABC) - OpKlass() (_swig_ret Klass) -} - -type SwigcptrXYZInt uintptr - -func (p SwigcptrXYZInt) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrXYZInt) SwigIsXYZInt() { -} - -var _wrap_XYZInt_opIntPtrA unsafe.Pointer - -func _swig_wrap_XYZInt_opIntPtrA(base SwigcptrXYZInt) (_ SwigcptrNotXYZInt) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_XYZInt_opIntPtrA, _swig_p) - return -} - -func (arg1 SwigcptrXYZInt) OpIntPtrA() (_swig_ret NotXYZInt) { - return _swig_wrap_XYZInt_opIntPtrA(arg1) -} - -var _wrap_XYZInt_opIntPtrB unsafe.Pointer - -func _swig_wrap_XYZInt_opIntPtrB(base SwigcptrXYZInt) (_ SwigcptrXYZInt) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_XYZInt_opIntPtrB, _swig_p) - return -} - -func (arg1 SwigcptrXYZInt) OpIntPtrB() (_swig_ret XYZInt) { - return _swig_wrap_XYZInt_opIntPtrB(arg1) -} - -var _wrap_XYZInt_opAnother2 unsafe.Pointer - -func _swig_wrap_XYZInt_opAnother2(base SwigcptrXYZInt) (_ SwigcptrAnother) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_XYZInt_opAnother2, _swig_p) - return -} - -func (arg1 SwigcptrXYZInt) OpAnother2() (_swig_ret Another) { - return _swig_wrap_XYZInt_opAnother2(arg1) -} - -var _wrap_XYZInt_tMethod2 unsafe.Pointer - -func _swig_wrap_XYZInt_tMethod2(base SwigcptrXYZInt, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_XYZInt_tMethod2, _swig_p) - return -} - -func (arg1 SwigcptrXYZInt) TMethod2(arg2 int) { - _swig_wrap_XYZInt_tMethod2(arg1, arg2) -} - -var _wrap_XYZInt_tMethodNotXYZ2 unsafe.Pointer - -func _swig_wrap_XYZInt_tMethodNotXYZ2(base SwigcptrXYZInt, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_XYZInt_tMethodNotXYZ2, _swig_p) - return -} - -func (arg1 SwigcptrXYZInt) TMethodNotXYZ2(arg2 NotXYZInt) { - _swig_wrap_XYZInt_tMethodNotXYZ2(arg1, arg2.Swigcptr()) -} - -var _wrap_XYZInt_tMethodXYZ2 unsafe.Pointer - -func _swig_wrap_XYZInt_tMethodXYZ2(base SwigcptrXYZInt, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_XYZInt_tMethodXYZ2, _swig_p) - return -} - -func (arg1 SwigcptrXYZInt) TMethodXYZ2(arg2 XYZInt) { - _swig_wrap_XYZInt_tMethodXYZ2(arg1, arg2.Swigcptr()) -} - -var _wrap_XYZInt_opT2 unsafe.Pointer - -func _swig_wrap_XYZInt_opT2(base SwigcptrXYZInt) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_XYZInt_opT2, _swig_p) - return -} - -func (arg1 SwigcptrXYZInt) OpT2() (_swig_ret int) { - return _swig_wrap_XYZInt_opT2(arg1) -} - -var _wrap_XYZInt_opNotXYZ2 unsafe.Pointer - -func _swig_wrap_XYZInt_opNotXYZ2(base SwigcptrXYZInt) (_ SwigcptrNotXYZInt) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_XYZInt_opNotXYZ2, _swig_p) - return -} - -func (arg1 SwigcptrXYZInt) OpNotXYZ2() (_swig_ret NotXYZInt) { - return _swig_wrap_XYZInt_opNotXYZ2(arg1) -} - -var _wrap_XYZInt_opXYZ2 unsafe.Pointer - -func _swig_wrap_XYZInt_opXYZ2(base SwigcptrXYZInt) (_ SwigcptrXYZInt) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_XYZInt_opXYZ2, _swig_p) - return -} - -func (arg1 SwigcptrXYZInt) OpXYZ2() (_swig_ret XYZInt) { - return _swig_wrap_XYZInt_opXYZ2(arg1) -} - -var _wrap_new_XYZInt unsafe.Pointer - -func _swig_wrap_new_XYZInt() (base SwigcptrXYZInt) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_XYZInt, _swig_p) - return -} - -func NewXYZInt() (_swig_ret XYZInt) { - return _swig_wrap_new_XYZInt() -} - -var _wrap_delete_XYZInt unsafe.Pointer - -func _swig_wrap_delete_XYZInt(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_XYZInt, _swig_p) - return -} - -func DeleteXYZInt(arg1 XYZInt) { - _swig_wrap_delete_XYZInt(arg1.Swigcptr()) -} - -type XYZInt interface { - Swigcptr() uintptr - SwigIsXYZInt() - OpIntPtrA() (_swig_ret NotXYZInt) - OpIntPtrB() (_swig_ret XYZInt) - OpAnother2() (_swig_ret Another) - TMethod2(arg2 int) - TMethodNotXYZ2(arg2 NotXYZInt) - TMethodXYZ2(arg2 XYZInt) - OpT2() (_swig_ret int) - OpNotXYZ2() (_swig_ret NotXYZInt) - OpXYZ2() (_swig_ret XYZInt) -} - -type SwigcptrXYZDouble uintptr - -func (p SwigcptrXYZDouble) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrXYZDouble) SwigIsXYZDouble() { -} - -var _wrap_XYZDouble_opIntPtrA unsafe.Pointer - -func _swig_wrap_XYZDouble_opIntPtrA(base SwigcptrXYZDouble) (_ SwigcptrNotXYZInt) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_XYZDouble_opIntPtrA, _swig_p) - return -} - -func (arg1 SwigcptrXYZDouble) OpIntPtrA() (_swig_ret NotXYZInt) { - return _swig_wrap_XYZDouble_opIntPtrA(arg1) -} - -var _wrap_XYZDouble_opIntPtrB unsafe.Pointer - -func _swig_wrap_XYZDouble_opIntPtrB(base SwigcptrXYZDouble) (_ SwigcptrXYZInt) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_XYZDouble_opIntPtrB, _swig_p) - return -} - -func (arg1 SwigcptrXYZDouble) OpIntPtrB() (_swig_ret XYZInt) { - return _swig_wrap_XYZDouble_opIntPtrB(arg1) -} - -var _wrap_XYZDouble_opAnother1 unsafe.Pointer - -func _swig_wrap_XYZDouble_opAnother1(base SwigcptrXYZDouble) (_ SwigcptrAnother) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_XYZDouble_opAnother1, _swig_p) - return -} - -func (arg1 SwigcptrXYZDouble) OpAnother1() (_swig_ret Another) { - return _swig_wrap_XYZDouble_opAnother1(arg1) -} - -var _wrap_XYZDouble_tMethod1 unsafe.Pointer - -func _swig_wrap_XYZDouble_tMethod1(base SwigcptrXYZDouble, _ float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_XYZDouble_tMethod1, _swig_p) - return -} - -func (arg1 SwigcptrXYZDouble) TMethod1(arg2 float64) { - _swig_wrap_XYZDouble_tMethod1(arg1, arg2) -} - -var _wrap_XYZDouble_tMethodNotXYZ1 unsafe.Pointer - -func _swig_wrap_XYZDouble_tMethodNotXYZ1(base SwigcptrXYZDouble, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_XYZDouble_tMethodNotXYZ1, _swig_p) - return -} - -func (arg1 SwigcptrXYZDouble) TMethodNotXYZ1(arg2 NotXYZDouble) { - _swig_wrap_XYZDouble_tMethodNotXYZ1(arg1, arg2.Swigcptr()) -} - -var _wrap_XYZDouble_tMethodXYZ1 unsafe.Pointer - -func _swig_wrap_XYZDouble_tMethodXYZ1(base SwigcptrXYZDouble, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_XYZDouble_tMethodXYZ1, _swig_p) - return -} - -func (arg1 SwigcptrXYZDouble) TMethodXYZ1(arg2 XYZDouble) { - _swig_wrap_XYZDouble_tMethodXYZ1(arg1, arg2.Swigcptr()) -} - -var _wrap_XYZDouble_opT1 unsafe.Pointer - -func _swig_wrap_XYZDouble_opT1(base SwigcptrXYZDouble) (_ float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_XYZDouble_opT1, _swig_p) - return -} - -func (arg1 SwigcptrXYZDouble) OpT1() (_swig_ret float64) { - return _swig_wrap_XYZDouble_opT1(arg1) -} - -var _wrap_XYZDouble_opNotXYZ1 unsafe.Pointer - -func _swig_wrap_XYZDouble_opNotXYZ1(base SwigcptrXYZDouble) (_ SwigcptrNotXYZDouble) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_XYZDouble_opNotXYZ1, _swig_p) - return -} - -func (arg1 SwigcptrXYZDouble) OpNotXYZ1() (_swig_ret NotXYZDouble) { - return _swig_wrap_XYZDouble_opNotXYZ1(arg1) -} - -var _wrap_XYZDouble_opXYZ1 unsafe.Pointer - -func _swig_wrap_XYZDouble_opXYZ1(base SwigcptrXYZDouble) (_ SwigcptrXYZDouble) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_XYZDouble_opXYZ1, _swig_p) - return -} - -func (arg1 SwigcptrXYZDouble) OpXYZ1() (_swig_ret XYZDouble) { - return _swig_wrap_XYZDouble_opXYZ1(arg1) -} - -var _wrap_new_XYZDouble unsafe.Pointer - -func _swig_wrap_new_XYZDouble() (base SwigcptrXYZDouble) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_XYZDouble, _swig_p) - return -} - -func NewXYZDouble() (_swig_ret XYZDouble) { - return _swig_wrap_new_XYZDouble() -} - -var _wrap_delete_XYZDouble unsafe.Pointer - -func _swig_wrap_delete_XYZDouble(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_XYZDouble, _swig_p) - return -} - -func DeleteXYZDouble(arg1 XYZDouble) { - _swig_wrap_delete_XYZDouble(arg1.Swigcptr()) -} - -type XYZDouble interface { - Swigcptr() uintptr - SwigIsXYZDouble() - OpIntPtrA() (_swig_ret NotXYZInt) - OpIntPtrB() (_swig_ret XYZInt) - OpAnother1() (_swig_ret Another) - TMethod1(arg2 float64) - TMethodNotXYZ1(arg2 NotXYZDouble) - TMethodXYZ1(arg2 XYZDouble) - OpT1() (_swig_ret float64) - OpNotXYZ1() (_swig_ret NotXYZDouble) - OpXYZ1() (_swig_ret XYZDouble) -} - -type SwigcptrXYZKlass uintptr - -func (p SwigcptrXYZKlass) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrXYZKlass) SwigIsXYZKlass() { -} - -var _wrap_XYZKlass_opIntPtrA unsafe.Pointer - -func _swig_wrap_XYZKlass_opIntPtrA(base SwigcptrXYZKlass) (_ SwigcptrNotXYZInt) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_XYZKlass_opIntPtrA, _swig_p) - return -} - -func (arg1 SwigcptrXYZKlass) OpIntPtrA() (_swig_ret NotXYZInt) { - return _swig_wrap_XYZKlass_opIntPtrA(arg1) -} - -var _wrap_XYZKlass_opIntPtrB unsafe.Pointer - -func _swig_wrap_XYZKlass_opIntPtrB(base SwigcptrXYZKlass) (_ SwigcptrXYZInt) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_XYZKlass_opIntPtrB, _swig_p) - return -} - -func (arg1 SwigcptrXYZKlass) OpIntPtrB() (_swig_ret XYZInt) { - return _swig_wrap_XYZKlass_opIntPtrB(arg1) -} - -var _wrap_XYZKlass_opAnother3 unsafe.Pointer - -func _swig_wrap_XYZKlass_opAnother3(base SwigcptrXYZKlass) (_ SwigcptrAnother) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_XYZKlass_opAnother3, _swig_p) - return -} - -func (arg1 SwigcptrXYZKlass) OpAnother3() (_swig_ret Another) { - return _swig_wrap_XYZKlass_opAnother3(arg1) -} - -var _wrap_XYZKlass_tMethod3 unsafe.Pointer - -func _swig_wrap_XYZKlass_tMethod3(base SwigcptrXYZKlass, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_XYZKlass_tMethod3, _swig_p) - return -} - -func (arg1 SwigcptrXYZKlass) TMethod3(arg2 Klass) { - _swig_wrap_XYZKlass_tMethod3(arg1, arg2.Swigcptr()) -} - -var _wrap_XYZKlass_tMethodNotXYZ3 unsafe.Pointer - -func _swig_wrap_XYZKlass_tMethodNotXYZ3(base SwigcptrXYZKlass, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_XYZKlass_tMethodNotXYZ3, _swig_p) - return -} - -func (arg1 SwigcptrXYZKlass) TMethodNotXYZ3(arg2 NotXYZKlass) { - _swig_wrap_XYZKlass_tMethodNotXYZ3(arg1, arg2.Swigcptr()) -} - -var _wrap_XYZKlass_tMethodXYZ3 unsafe.Pointer - -func _swig_wrap_XYZKlass_tMethodXYZ3(base SwigcptrXYZKlass, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_XYZKlass_tMethodXYZ3, _swig_p) - return -} - -func (arg1 SwigcptrXYZKlass) TMethodXYZ3(arg2 XYZKlass) { - _swig_wrap_XYZKlass_tMethodXYZ3(arg1, arg2.Swigcptr()) -} - -var _wrap_XYZKlass_opT3 unsafe.Pointer - -func _swig_wrap_XYZKlass_opT3(base SwigcptrXYZKlass) (_ SwigcptrKlass) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_XYZKlass_opT3, _swig_p) - return -} - -func (arg1 SwigcptrXYZKlass) OpT3() (_swig_ret Klass) { - return _swig_wrap_XYZKlass_opT3(arg1) -} - -var _wrap_XYZKlass_opNotXYZ3 unsafe.Pointer - -func _swig_wrap_XYZKlass_opNotXYZ3(base SwigcptrXYZKlass) (_ SwigcptrNotXYZKlass) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_XYZKlass_opNotXYZ3, _swig_p) - return -} - -func (arg1 SwigcptrXYZKlass) OpNotXYZ3() (_swig_ret NotXYZKlass) { - return _swig_wrap_XYZKlass_opNotXYZ3(arg1) -} - -var _wrap_XYZKlass_opXYZ3 unsafe.Pointer - -func _swig_wrap_XYZKlass_opXYZ3(base SwigcptrXYZKlass) (_ SwigcptrXYZKlass) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_XYZKlass_opXYZ3, _swig_p) - return -} - -func (arg1 SwigcptrXYZKlass) OpXYZ3() (_swig_ret XYZKlass) { - return _swig_wrap_XYZKlass_opXYZ3(arg1) -} - -var _wrap_new_XYZKlass unsafe.Pointer - -func _swig_wrap_new_XYZKlass() (base SwigcptrXYZKlass) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_XYZKlass, _swig_p) - return -} - -func NewXYZKlass() (_swig_ret XYZKlass) { - return _swig_wrap_new_XYZKlass() -} - -var _wrap_delete_XYZKlass unsafe.Pointer - -func _swig_wrap_delete_XYZKlass(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_XYZKlass, _swig_p) - return -} - -func DeleteXYZKlass(arg1 XYZKlass) { - _swig_wrap_delete_XYZKlass(arg1.Swigcptr()) -} - -type XYZKlass interface { - Swigcptr() uintptr - SwigIsXYZKlass() - OpIntPtrA() (_swig_ret NotXYZInt) - OpIntPtrB() (_swig_ret XYZInt) - OpAnother3() (_swig_ret Another) - TMethod3(arg2 Klass) - TMethodNotXYZ3(arg2 NotXYZKlass) - TMethodXYZ3(arg2 XYZKlass) - OpT3() (_swig_ret Klass) - OpNotXYZ3() (_swig_ret NotXYZKlass) - OpXYZ3() (_swig_ret XYZKlass) -} - -type SwigcptrXYZEnu uintptr - -func (p SwigcptrXYZEnu) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrXYZEnu) SwigIsXYZEnu() { -} - -var _wrap_XYZEnu_opIntPtrA unsafe.Pointer - -func _swig_wrap_XYZEnu_opIntPtrA(base SwigcptrXYZEnu) (_ SwigcptrNotXYZInt) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_XYZEnu_opIntPtrA, _swig_p) - return -} - -func (arg1 SwigcptrXYZEnu) OpIntPtrA() (_swig_ret NotXYZInt) { - return _swig_wrap_XYZEnu_opIntPtrA(arg1) -} - -var _wrap_XYZEnu_opIntPtrB unsafe.Pointer - -func _swig_wrap_XYZEnu_opIntPtrB(base SwigcptrXYZEnu) (_ SwigcptrXYZInt) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_XYZEnu_opIntPtrB, _swig_p) - return -} - -func (arg1 SwigcptrXYZEnu) OpIntPtrB() (_swig_ret XYZInt) { - return _swig_wrap_XYZEnu_opIntPtrB(arg1) -} - -var _wrap_XYZEnu_opAnother4 unsafe.Pointer - -func _swig_wrap_XYZEnu_opAnother4(base SwigcptrXYZEnu) (_ SwigcptrAnother) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_XYZEnu_opAnother4, _swig_p) - return -} - -func (arg1 SwigcptrXYZEnu) OpAnother4() (_swig_ret Another) { - return _swig_wrap_XYZEnu_opAnother4(arg1) -} - -var _wrap_XYZEnu_tMethod4 unsafe.Pointer - -func _swig_wrap_XYZEnu_tMethod4(base SwigcptrXYZEnu, _ SpaceEnu) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_XYZEnu_tMethod4, _swig_p) - return -} - -func (arg1 SwigcptrXYZEnu) TMethod4(arg2 SpaceEnu) { - _swig_wrap_XYZEnu_tMethod4(arg1, arg2) -} - -var _wrap_XYZEnu_tMethodNotXYZ4 unsafe.Pointer - -func _swig_wrap_XYZEnu_tMethodNotXYZ4(base SwigcptrXYZEnu, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_XYZEnu_tMethodNotXYZ4, _swig_p) - return -} - -func (arg1 SwigcptrXYZEnu) TMethodNotXYZ4(arg2 NotXYZEnu) { - _swig_wrap_XYZEnu_tMethodNotXYZ4(arg1, arg2.Swigcptr()) -} - -var _wrap_XYZEnu_tMethodXYZ4 unsafe.Pointer - -func _swig_wrap_XYZEnu_tMethodXYZ4(base SwigcptrXYZEnu, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_XYZEnu_tMethodXYZ4, _swig_p) - return -} - -func (arg1 SwigcptrXYZEnu) TMethodXYZ4(arg2 XYZEnu) { - _swig_wrap_XYZEnu_tMethodXYZ4(arg1, arg2.Swigcptr()) -} - -var _wrap_XYZEnu_opT4 unsafe.Pointer - -func _swig_wrap_XYZEnu_opT4(base SwigcptrXYZEnu) (_ SpaceEnu) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_XYZEnu_opT4, _swig_p) - return -} - -func (arg1 SwigcptrXYZEnu) OpT4() (_swig_ret SpaceEnu) { - return _swig_wrap_XYZEnu_opT4(arg1) -} - -var _wrap_XYZEnu_opNotXYZ4 unsafe.Pointer - -func _swig_wrap_XYZEnu_opNotXYZ4(base SwigcptrXYZEnu) (_ SwigcptrNotXYZEnu) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_XYZEnu_opNotXYZ4, _swig_p) - return -} - -func (arg1 SwigcptrXYZEnu) OpNotXYZ4() (_swig_ret NotXYZEnu) { - return _swig_wrap_XYZEnu_opNotXYZ4(arg1) -} - -var _wrap_XYZEnu_opXYZ4 unsafe.Pointer - -func _swig_wrap_XYZEnu_opXYZ4(base SwigcptrXYZEnu) (_ SwigcptrXYZEnu) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_XYZEnu_opXYZ4, _swig_p) - return -} - -func (arg1 SwigcptrXYZEnu) OpXYZ4() (_swig_ret XYZEnu) { - return _swig_wrap_XYZEnu_opXYZ4(arg1) -} - -var _wrap_new_XYZEnu unsafe.Pointer - -func _swig_wrap_new_XYZEnu() (base SwigcptrXYZEnu) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_XYZEnu, _swig_p) - return -} - -func NewXYZEnu() (_swig_ret XYZEnu) { - return _swig_wrap_new_XYZEnu() -} - -var _wrap_delete_XYZEnu unsafe.Pointer - -func _swig_wrap_delete_XYZEnu(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_XYZEnu, _swig_p) - return -} - -func DeleteXYZEnu(arg1 XYZEnu) { - _swig_wrap_delete_XYZEnu(arg1.Swigcptr()) -} - -type XYZEnu interface { - Swigcptr() uintptr - SwigIsXYZEnu() - OpIntPtrA() (_swig_ret NotXYZInt) - OpIntPtrB() (_swig_ret XYZInt) - OpAnother4() (_swig_ret Another) - TMethod4(arg2 SpaceEnu) - TMethodNotXYZ4(arg2 NotXYZEnu) - TMethodXYZ4(arg2 XYZEnu) - OpT4() (_swig_ret SpaceEnu) - OpNotXYZ4() (_swig_ret NotXYZEnu) - OpXYZ4() (_swig_ret XYZEnu) -} - -type SwigcptrNotXYZInt uintptr - -func (p SwigcptrNotXYZInt) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrNotXYZInt) SwigIsNotXYZInt() { -} - -var _wrap_new_NotXYZInt unsafe.Pointer - -func _swig_wrap_new_NotXYZInt() (base SwigcptrNotXYZInt) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_NotXYZInt, _swig_p) - return -} - -func NewNotXYZInt() (_swig_ret NotXYZInt) { - return _swig_wrap_new_NotXYZInt() -} - -var _wrap_delete_NotXYZInt unsafe.Pointer - -func _swig_wrap_delete_NotXYZInt(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_NotXYZInt, _swig_p) - return -} - -func DeleteNotXYZInt(arg1 NotXYZInt) { - _swig_wrap_delete_NotXYZInt(arg1.Swigcptr()) -} - -type NotXYZInt interface { - Swigcptr() uintptr - SwigIsNotXYZInt() -} - -type SwigcptrNotXYZDouble uintptr - -func (p SwigcptrNotXYZDouble) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrNotXYZDouble) SwigIsNotXYZDouble() { -} - -var _wrap_new_NotXYZDouble unsafe.Pointer - -func _swig_wrap_new_NotXYZDouble() (base SwigcptrNotXYZDouble) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_NotXYZDouble, _swig_p) - return -} - -func NewNotXYZDouble() (_swig_ret NotXYZDouble) { - return _swig_wrap_new_NotXYZDouble() -} - -var _wrap_delete_NotXYZDouble unsafe.Pointer - -func _swig_wrap_delete_NotXYZDouble(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_NotXYZDouble, _swig_p) - return -} - -func DeleteNotXYZDouble(arg1 NotXYZDouble) { - _swig_wrap_delete_NotXYZDouble(arg1.Swigcptr()) -} - -type NotXYZDouble interface { - Swigcptr() uintptr - SwigIsNotXYZDouble() -} - -type SwigcptrNotXYZKlass uintptr - -func (p SwigcptrNotXYZKlass) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrNotXYZKlass) SwigIsNotXYZKlass() { -} - -var _wrap_new_NotXYZKlass unsafe.Pointer - -func _swig_wrap_new_NotXYZKlass() (base SwigcptrNotXYZKlass) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_NotXYZKlass, _swig_p) - return -} - -func NewNotXYZKlass() (_swig_ret NotXYZKlass) { - return _swig_wrap_new_NotXYZKlass() -} - -var _wrap_delete_NotXYZKlass unsafe.Pointer - -func _swig_wrap_delete_NotXYZKlass(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_NotXYZKlass, _swig_p) - return -} - -func DeleteNotXYZKlass(arg1 NotXYZKlass) { - _swig_wrap_delete_NotXYZKlass(arg1.Swigcptr()) -} - -type NotXYZKlass interface { - Swigcptr() uintptr - SwigIsNotXYZKlass() -} - -type SwigcptrNotXYZEnu uintptr - -func (p SwigcptrNotXYZEnu) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrNotXYZEnu) SwigIsNotXYZEnu() { -} - -var _wrap_new_NotXYZEnu unsafe.Pointer - -func _swig_wrap_new_NotXYZEnu() (base SwigcptrNotXYZEnu) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_NotXYZEnu, _swig_p) - return -} - -func NewNotXYZEnu() (_swig_ret NotXYZEnu) { - return _swig_wrap_new_NotXYZEnu() -} - -var _wrap_delete_NotXYZEnu unsafe.Pointer - -func _swig_wrap_delete_NotXYZEnu(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_NotXYZEnu, _swig_p) - return -} - -func DeleteNotXYZEnu(arg1 NotXYZEnu) { - _swig_wrap_delete_NotXYZEnu(arg1.Swigcptr()) -} - -type NotXYZEnu interface { - Swigcptr() uintptr - SwigIsNotXYZEnu() -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/rename4.go b/Examples/test-suite/go/rename4.go deleted file mode 100644 index 09ffa1f62..000000000 --- a/Examples/test-suite/go/rename4.go +++ /dev/null @@ -1,1023 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../rename4.i - -package rename4 - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrKlass uintptr - -func (p SwigcptrKlass) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrKlass) SwigIsKlass() { -} - -var _wrap_new_Klass__SWIG_0 unsafe.Pointer - -func _swig_wrap_new_Klass__SWIG_0(base int) (_ SwigcptrKlass) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Klass__SWIG_0, _swig_p) - return -} - -func NewKlass__SWIG_0(arg1 int) (_swig_ret Klass) { - return _swig_wrap_new_Klass__SWIG_0(arg1) -} - -var _wrap_new_Klass__SWIG_1 unsafe.Pointer - -func _swig_wrap_new_Klass__SWIG_1() (base SwigcptrKlass) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Klass__SWIG_1, _swig_p) - return -} - -func NewKlass__SWIG_1() (_swig_ret Klass) { - return _swig_wrap_new_Klass__SWIG_1() -} - -func NewKlass(a ...interface{}) Klass { - argc := len(a) - if argc == 0 { - return NewKlass__SWIG_1() - } - if argc == 1 { - return NewKlass__SWIG_0(a[0].(int)) - } - panic("No match for overloaded function call") -} - -var _wrap_delete_Klass unsafe.Pointer - -func _swig_wrap_delete_Klass(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Klass, _swig_p) - return -} - -func DeleteKlass(arg1 Klass) { - _swig_wrap_delete_Klass(arg1.Swigcptr()) -} - -type Klass interface { - Swigcptr() uintptr - SwigIsKlass() -} - -type SwigcptrAnother uintptr - -func (p SwigcptrAnother) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrAnother) SwigIsAnother() { -} - -var _wrap_new_Another unsafe.Pointer - -func _swig_wrap_new_Another() (base SwigcptrAnother) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Another, _swig_p) - return -} - -func NewAnother() (_swig_ret Another) { - return _swig_wrap_new_Another() -} - -var _wrap_delete_Another unsafe.Pointer - -func _swig_wrap_delete_Another(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Another, _swig_p) - return -} - -func DeleteAnother(arg1 Another) { - _swig_wrap_delete_Another(arg1.Swigcptr()) -} - -type Another interface { - Swigcptr() uintptr - SwigIsAnother() -} - -type SpaceEnu int -var _wrap_En1 unsafe.Pointer - -func _swig_getEn1() (_swig_ret SpaceEnu) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_En1, _swig_p) - return -} -var En1 SpaceEnu = _swig_getEn1() -var _wrap_En2 unsafe.Pointer - -func _swig_getEn2() (_swig_ret SpaceEnu) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_En2, _swig_p) - return -} -var En2 SpaceEnu = _swig_getEn2() -var _wrap_En3 unsafe.Pointer - -func _swig_getEn3() (_swig_ret SpaceEnu) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_En3, _swig_p) - return -} -var En3 SpaceEnu = _swig_getEn3() -type SwigcptrABC uintptr - -func (p SwigcptrABC) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrABC) SwigIsABC() { -} - -var _wrap_ABC_methodABC unsafe.Pointer - -func _swig_wrap_ABC_methodABC(base SwigcptrABC, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_ABC_methodABC, _swig_p) - return -} - -func (arg1 SwigcptrABC) MethodABC(arg2 ABC) { - _swig_wrap_ABC_methodABC(arg1, arg2.Swigcptr()) -} - -var _wrap_ABC_methodKlass unsafe.Pointer - -func _swig_wrap_ABC_methodKlass(base SwigcptrABC, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_ABC_methodKlass, _swig_p) - return -} - -func (arg1 SwigcptrABC) MethodKlass(arg2 Klass) { - _swig_wrap_ABC_methodKlass(arg1, arg2.Swigcptr()) -} - -var _wrap_ABC_opABC unsafe.Pointer - -func _swig_wrap_ABC_opABC(base SwigcptrABC) (_ SwigcptrABC) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_ABC_opABC, _swig_p) - return -} - -func (arg1 SwigcptrABC) OpABC() (_swig_ret ABC) { - return _swig_wrap_ABC_opABC(arg1) -} - -var _wrap_ABC_opKlass unsafe.Pointer - -func _swig_wrap_ABC_opKlass(base SwigcptrABC) (_ SwigcptrKlass) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_ABC_opKlass, _swig_p) - return -} - -func (arg1 SwigcptrABC) OpKlass() (_swig_ret Klass) { - return _swig_wrap_ABC_opKlass(arg1) -} - -var _wrap_new_ABC unsafe.Pointer - -func _swig_wrap_new_ABC() (base SwigcptrABC) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_ABC, _swig_p) - return -} - -func NewABC() (_swig_ret ABC) { - return _swig_wrap_new_ABC() -} - -var _wrap_delete_ABC unsafe.Pointer - -func _swig_wrap_delete_ABC(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_ABC, _swig_p) - return -} - -func DeleteABC(arg1 ABC) { - _swig_wrap_delete_ABC(arg1.Swigcptr()) -} - -type ABC interface { - Swigcptr() uintptr - SwigIsABC() - MethodABC(arg2 ABC) - MethodKlass(arg2 Klass) - OpABC() (_swig_ret ABC) - OpKlass() (_swig_ret Klass) -} - -type SwigcptrXYZInt uintptr - -func (p SwigcptrXYZInt) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrXYZInt) SwigIsXYZInt() { -} - -var _wrap_XYZInt_opIntPtrA unsafe.Pointer - -func _swig_wrap_XYZInt_opIntPtrA(base SwigcptrXYZInt) (_ SwigcptrNotXYZInt) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_XYZInt_opIntPtrA, _swig_p) - return -} - -func (arg1 SwigcptrXYZInt) OpIntPtrA() (_swig_ret NotXYZInt) { - return _swig_wrap_XYZInt_opIntPtrA(arg1) -} - -var _wrap_XYZInt_opIntPtrB unsafe.Pointer - -func _swig_wrap_XYZInt_opIntPtrB(base SwigcptrXYZInt) (_ SwigcptrXYZInt) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_XYZInt_opIntPtrB, _swig_p) - return -} - -func (arg1 SwigcptrXYZInt) OpIntPtrB() (_swig_ret XYZInt) { - return _swig_wrap_XYZInt_opIntPtrB(arg1) -} - -var _wrap_XYZInt_opAnother2 unsafe.Pointer - -func _swig_wrap_XYZInt_opAnother2(base SwigcptrXYZInt) (_ SwigcptrAnother) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_XYZInt_opAnother2, _swig_p) - return -} - -func (arg1 SwigcptrXYZInt) OpAnother2() (_swig_ret Another) { - return _swig_wrap_XYZInt_opAnother2(arg1) -} - -var _wrap_XYZInt_tMethod2 unsafe.Pointer - -func _swig_wrap_XYZInt_tMethod2(base SwigcptrXYZInt, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_XYZInt_tMethod2, _swig_p) - return -} - -func (arg1 SwigcptrXYZInt) TMethod2(arg2 int) { - _swig_wrap_XYZInt_tMethod2(arg1, arg2) -} - -var _wrap_XYZInt_tMethodNotXYZ2 unsafe.Pointer - -func _swig_wrap_XYZInt_tMethodNotXYZ2(base SwigcptrXYZInt, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_XYZInt_tMethodNotXYZ2, _swig_p) - return -} - -func (arg1 SwigcptrXYZInt) TMethodNotXYZ2(arg2 NotXYZInt) { - _swig_wrap_XYZInt_tMethodNotXYZ2(arg1, arg2.Swigcptr()) -} - -var _wrap_XYZInt_tMethodXYZ2 unsafe.Pointer - -func _swig_wrap_XYZInt_tMethodXYZ2(base SwigcptrXYZInt, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_XYZInt_tMethodXYZ2, _swig_p) - return -} - -func (arg1 SwigcptrXYZInt) TMethodXYZ2(arg2 XYZInt) { - _swig_wrap_XYZInt_tMethodXYZ2(arg1, arg2.Swigcptr()) -} - -var _wrap_XYZInt_opT2 unsafe.Pointer - -func _swig_wrap_XYZInt_opT2(base SwigcptrXYZInt) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_XYZInt_opT2, _swig_p) - return -} - -func (arg1 SwigcptrXYZInt) OpT2() (_swig_ret int) { - return _swig_wrap_XYZInt_opT2(arg1) -} - -var _wrap_XYZInt_opNotXYZ2 unsafe.Pointer - -func _swig_wrap_XYZInt_opNotXYZ2(base SwigcptrXYZInt) (_ SwigcptrNotXYZInt) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_XYZInt_opNotXYZ2, _swig_p) - return -} - -func (arg1 SwigcptrXYZInt) OpNotXYZ2() (_swig_ret NotXYZInt) { - return _swig_wrap_XYZInt_opNotXYZ2(arg1) -} - -var _wrap_XYZInt_opXYZ2 unsafe.Pointer - -func _swig_wrap_XYZInt_opXYZ2(base SwigcptrXYZInt) (_ SwigcptrXYZInt) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_XYZInt_opXYZ2, _swig_p) - return -} - -func (arg1 SwigcptrXYZInt) OpXYZ2() (_swig_ret XYZInt) { - return _swig_wrap_XYZInt_opXYZ2(arg1) -} - -var _wrap_new_XYZInt unsafe.Pointer - -func _swig_wrap_new_XYZInt() (base SwigcptrXYZInt) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_XYZInt, _swig_p) - return -} - -func NewXYZInt() (_swig_ret XYZInt) { - return _swig_wrap_new_XYZInt() -} - -var _wrap_delete_XYZInt unsafe.Pointer - -func _swig_wrap_delete_XYZInt(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_XYZInt, _swig_p) - return -} - -func DeleteXYZInt(arg1 XYZInt) { - _swig_wrap_delete_XYZInt(arg1.Swigcptr()) -} - -type XYZInt interface { - Swigcptr() uintptr - SwigIsXYZInt() - OpIntPtrA() (_swig_ret NotXYZInt) - OpIntPtrB() (_swig_ret XYZInt) - OpAnother2() (_swig_ret Another) - TMethod2(arg2 int) - TMethodNotXYZ2(arg2 NotXYZInt) - TMethodXYZ2(arg2 XYZInt) - OpT2() (_swig_ret int) - OpNotXYZ2() (_swig_ret NotXYZInt) - OpXYZ2() (_swig_ret XYZInt) -} - -type SwigcptrXYZDouble uintptr - -func (p SwigcptrXYZDouble) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrXYZDouble) SwigIsXYZDouble() { -} - -var _wrap_XYZDouble_opIntPtrA unsafe.Pointer - -func _swig_wrap_XYZDouble_opIntPtrA(base SwigcptrXYZDouble) (_ SwigcptrNotXYZInt) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_XYZDouble_opIntPtrA, _swig_p) - return -} - -func (arg1 SwigcptrXYZDouble) OpIntPtrA() (_swig_ret NotXYZInt) { - return _swig_wrap_XYZDouble_opIntPtrA(arg1) -} - -var _wrap_XYZDouble_opIntPtrB unsafe.Pointer - -func _swig_wrap_XYZDouble_opIntPtrB(base SwigcptrXYZDouble) (_ SwigcptrXYZInt) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_XYZDouble_opIntPtrB, _swig_p) - return -} - -func (arg1 SwigcptrXYZDouble) OpIntPtrB() (_swig_ret XYZInt) { - return _swig_wrap_XYZDouble_opIntPtrB(arg1) -} - -var _wrap_XYZDouble_opAnother1 unsafe.Pointer - -func _swig_wrap_XYZDouble_opAnother1(base SwigcptrXYZDouble) (_ SwigcptrAnother) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_XYZDouble_opAnother1, _swig_p) - return -} - -func (arg1 SwigcptrXYZDouble) OpAnother1() (_swig_ret Another) { - return _swig_wrap_XYZDouble_opAnother1(arg1) -} - -var _wrap_XYZDouble_tMethod1 unsafe.Pointer - -func _swig_wrap_XYZDouble_tMethod1(base SwigcptrXYZDouble, _ float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_XYZDouble_tMethod1, _swig_p) - return -} - -func (arg1 SwigcptrXYZDouble) TMethod1(arg2 float64) { - _swig_wrap_XYZDouble_tMethod1(arg1, arg2) -} - -var _wrap_XYZDouble_tMethodNotXYZ1 unsafe.Pointer - -func _swig_wrap_XYZDouble_tMethodNotXYZ1(base SwigcptrXYZDouble, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_XYZDouble_tMethodNotXYZ1, _swig_p) - return -} - -func (arg1 SwigcptrXYZDouble) TMethodNotXYZ1(arg2 NotXYZDouble) { - _swig_wrap_XYZDouble_tMethodNotXYZ1(arg1, arg2.Swigcptr()) -} - -var _wrap_XYZDouble_tMethodXYZ1 unsafe.Pointer - -func _swig_wrap_XYZDouble_tMethodXYZ1(base SwigcptrXYZDouble, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_XYZDouble_tMethodXYZ1, _swig_p) - return -} - -func (arg1 SwigcptrXYZDouble) TMethodXYZ1(arg2 XYZDouble) { - _swig_wrap_XYZDouble_tMethodXYZ1(arg1, arg2.Swigcptr()) -} - -var _wrap_XYZDouble_opT1 unsafe.Pointer - -func _swig_wrap_XYZDouble_opT1(base SwigcptrXYZDouble) (_ float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_XYZDouble_opT1, _swig_p) - return -} - -func (arg1 SwigcptrXYZDouble) OpT1() (_swig_ret float64) { - return _swig_wrap_XYZDouble_opT1(arg1) -} - -var _wrap_XYZDouble_opNotXYZ1 unsafe.Pointer - -func _swig_wrap_XYZDouble_opNotXYZ1(base SwigcptrXYZDouble) (_ SwigcptrNotXYZDouble) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_XYZDouble_opNotXYZ1, _swig_p) - return -} - -func (arg1 SwigcptrXYZDouble) OpNotXYZ1() (_swig_ret NotXYZDouble) { - return _swig_wrap_XYZDouble_opNotXYZ1(arg1) -} - -var _wrap_XYZDouble_opXYZ1 unsafe.Pointer - -func _swig_wrap_XYZDouble_opXYZ1(base SwigcptrXYZDouble) (_ SwigcptrXYZDouble) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_XYZDouble_opXYZ1, _swig_p) - return -} - -func (arg1 SwigcptrXYZDouble) OpXYZ1() (_swig_ret XYZDouble) { - return _swig_wrap_XYZDouble_opXYZ1(arg1) -} - -var _wrap_new_XYZDouble unsafe.Pointer - -func _swig_wrap_new_XYZDouble() (base SwigcptrXYZDouble) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_XYZDouble, _swig_p) - return -} - -func NewXYZDouble() (_swig_ret XYZDouble) { - return _swig_wrap_new_XYZDouble() -} - -var _wrap_delete_XYZDouble unsafe.Pointer - -func _swig_wrap_delete_XYZDouble(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_XYZDouble, _swig_p) - return -} - -func DeleteXYZDouble(arg1 XYZDouble) { - _swig_wrap_delete_XYZDouble(arg1.Swigcptr()) -} - -type XYZDouble interface { - Swigcptr() uintptr - SwigIsXYZDouble() - OpIntPtrA() (_swig_ret NotXYZInt) - OpIntPtrB() (_swig_ret XYZInt) - OpAnother1() (_swig_ret Another) - TMethod1(arg2 float64) - TMethodNotXYZ1(arg2 NotXYZDouble) - TMethodXYZ1(arg2 XYZDouble) - OpT1() (_swig_ret float64) - OpNotXYZ1() (_swig_ret NotXYZDouble) - OpXYZ1() (_swig_ret XYZDouble) -} - -type SwigcptrXYZKlass uintptr - -func (p SwigcptrXYZKlass) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrXYZKlass) SwigIsXYZKlass() { -} - -var _wrap_XYZKlass_opIntPtrA unsafe.Pointer - -func _swig_wrap_XYZKlass_opIntPtrA(base SwigcptrXYZKlass) (_ SwigcptrNotXYZInt) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_XYZKlass_opIntPtrA, _swig_p) - return -} - -func (arg1 SwigcptrXYZKlass) OpIntPtrA() (_swig_ret NotXYZInt) { - return _swig_wrap_XYZKlass_opIntPtrA(arg1) -} - -var _wrap_XYZKlass_opIntPtrB unsafe.Pointer - -func _swig_wrap_XYZKlass_opIntPtrB(base SwigcptrXYZKlass) (_ SwigcptrXYZInt) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_XYZKlass_opIntPtrB, _swig_p) - return -} - -func (arg1 SwigcptrXYZKlass) OpIntPtrB() (_swig_ret XYZInt) { - return _swig_wrap_XYZKlass_opIntPtrB(arg1) -} - -var _wrap_XYZKlass_opAnother3 unsafe.Pointer - -func _swig_wrap_XYZKlass_opAnother3(base SwigcptrXYZKlass) (_ SwigcptrAnother) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_XYZKlass_opAnother3, _swig_p) - return -} - -func (arg1 SwigcptrXYZKlass) OpAnother3() (_swig_ret Another) { - return _swig_wrap_XYZKlass_opAnother3(arg1) -} - -var _wrap_XYZKlass_tMethod3 unsafe.Pointer - -func _swig_wrap_XYZKlass_tMethod3(base SwigcptrXYZKlass, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_XYZKlass_tMethod3, _swig_p) - return -} - -func (arg1 SwigcptrXYZKlass) TMethod3(arg2 Klass) { - _swig_wrap_XYZKlass_tMethod3(arg1, arg2.Swigcptr()) -} - -var _wrap_XYZKlass_tMethodNotXYZ3 unsafe.Pointer - -func _swig_wrap_XYZKlass_tMethodNotXYZ3(base SwigcptrXYZKlass, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_XYZKlass_tMethodNotXYZ3, _swig_p) - return -} - -func (arg1 SwigcptrXYZKlass) TMethodNotXYZ3(arg2 NotXYZKlass) { - _swig_wrap_XYZKlass_tMethodNotXYZ3(arg1, arg2.Swigcptr()) -} - -var _wrap_XYZKlass_tMethodXYZ3 unsafe.Pointer - -func _swig_wrap_XYZKlass_tMethodXYZ3(base SwigcptrXYZKlass, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_XYZKlass_tMethodXYZ3, _swig_p) - return -} - -func (arg1 SwigcptrXYZKlass) TMethodXYZ3(arg2 XYZKlass) { - _swig_wrap_XYZKlass_tMethodXYZ3(arg1, arg2.Swigcptr()) -} - -var _wrap_XYZKlass_opT3 unsafe.Pointer - -func _swig_wrap_XYZKlass_opT3(base SwigcptrXYZKlass) (_ SwigcptrKlass) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_XYZKlass_opT3, _swig_p) - return -} - -func (arg1 SwigcptrXYZKlass) OpT3() (_swig_ret Klass) { - return _swig_wrap_XYZKlass_opT3(arg1) -} - -var _wrap_XYZKlass_opNotXYZ3 unsafe.Pointer - -func _swig_wrap_XYZKlass_opNotXYZ3(base SwigcptrXYZKlass) (_ SwigcptrNotXYZKlass) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_XYZKlass_opNotXYZ3, _swig_p) - return -} - -func (arg1 SwigcptrXYZKlass) OpNotXYZ3() (_swig_ret NotXYZKlass) { - return _swig_wrap_XYZKlass_opNotXYZ3(arg1) -} - -var _wrap_XYZKlass_opXYZ3 unsafe.Pointer - -func _swig_wrap_XYZKlass_opXYZ3(base SwigcptrXYZKlass) (_ SwigcptrXYZKlass) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_XYZKlass_opXYZ3, _swig_p) - return -} - -func (arg1 SwigcptrXYZKlass) OpXYZ3() (_swig_ret XYZKlass) { - return _swig_wrap_XYZKlass_opXYZ3(arg1) -} - -var _wrap_new_XYZKlass unsafe.Pointer - -func _swig_wrap_new_XYZKlass() (base SwigcptrXYZKlass) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_XYZKlass, _swig_p) - return -} - -func NewXYZKlass() (_swig_ret XYZKlass) { - return _swig_wrap_new_XYZKlass() -} - -var _wrap_delete_XYZKlass unsafe.Pointer - -func _swig_wrap_delete_XYZKlass(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_XYZKlass, _swig_p) - return -} - -func DeleteXYZKlass(arg1 XYZKlass) { - _swig_wrap_delete_XYZKlass(arg1.Swigcptr()) -} - -type XYZKlass interface { - Swigcptr() uintptr - SwigIsXYZKlass() - OpIntPtrA() (_swig_ret NotXYZInt) - OpIntPtrB() (_swig_ret XYZInt) - OpAnother3() (_swig_ret Another) - TMethod3(arg2 Klass) - TMethodNotXYZ3(arg2 NotXYZKlass) - TMethodXYZ3(arg2 XYZKlass) - OpT3() (_swig_ret Klass) - OpNotXYZ3() (_swig_ret NotXYZKlass) - OpXYZ3() (_swig_ret XYZKlass) -} - -type SwigcptrXYZEnu uintptr - -func (p SwigcptrXYZEnu) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrXYZEnu) SwigIsXYZEnu() { -} - -var _wrap_XYZEnu_opIntPtrA unsafe.Pointer - -func _swig_wrap_XYZEnu_opIntPtrA(base SwigcptrXYZEnu) (_ SwigcptrNotXYZInt) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_XYZEnu_opIntPtrA, _swig_p) - return -} - -func (arg1 SwigcptrXYZEnu) OpIntPtrA() (_swig_ret NotXYZInt) { - return _swig_wrap_XYZEnu_opIntPtrA(arg1) -} - -var _wrap_XYZEnu_opIntPtrB unsafe.Pointer - -func _swig_wrap_XYZEnu_opIntPtrB(base SwigcptrXYZEnu) (_ SwigcptrXYZInt) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_XYZEnu_opIntPtrB, _swig_p) - return -} - -func (arg1 SwigcptrXYZEnu) OpIntPtrB() (_swig_ret XYZInt) { - return _swig_wrap_XYZEnu_opIntPtrB(arg1) -} - -var _wrap_XYZEnu_opAnother4 unsafe.Pointer - -func _swig_wrap_XYZEnu_opAnother4(base SwigcptrXYZEnu) (_ SwigcptrAnother) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_XYZEnu_opAnother4, _swig_p) - return -} - -func (arg1 SwigcptrXYZEnu) OpAnother4() (_swig_ret Another) { - return _swig_wrap_XYZEnu_opAnother4(arg1) -} - -var _wrap_XYZEnu_tMethod4 unsafe.Pointer - -func _swig_wrap_XYZEnu_tMethod4(base SwigcptrXYZEnu, _ SpaceEnu) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_XYZEnu_tMethod4, _swig_p) - return -} - -func (arg1 SwigcptrXYZEnu) TMethod4(arg2 SpaceEnu) { - _swig_wrap_XYZEnu_tMethod4(arg1, arg2) -} - -var _wrap_XYZEnu_tMethodNotXYZ4 unsafe.Pointer - -func _swig_wrap_XYZEnu_tMethodNotXYZ4(base SwigcptrXYZEnu, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_XYZEnu_tMethodNotXYZ4, _swig_p) - return -} - -func (arg1 SwigcptrXYZEnu) TMethodNotXYZ4(arg2 NotXYZEnu) { - _swig_wrap_XYZEnu_tMethodNotXYZ4(arg1, arg2.Swigcptr()) -} - -var _wrap_XYZEnu_tMethodXYZ4 unsafe.Pointer - -func _swig_wrap_XYZEnu_tMethodXYZ4(base SwigcptrXYZEnu, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_XYZEnu_tMethodXYZ4, _swig_p) - return -} - -func (arg1 SwigcptrXYZEnu) TMethodXYZ4(arg2 XYZEnu) { - _swig_wrap_XYZEnu_tMethodXYZ4(arg1, arg2.Swigcptr()) -} - -var _wrap_XYZEnu_opT4 unsafe.Pointer - -func _swig_wrap_XYZEnu_opT4(base SwigcptrXYZEnu) (_ SpaceEnu) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_XYZEnu_opT4, _swig_p) - return -} - -func (arg1 SwigcptrXYZEnu) OpT4() (_swig_ret SpaceEnu) { - return _swig_wrap_XYZEnu_opT4(arg1) -} - -var _wrap_XYZEnu_opNotXYZ4 unsafe.Pointer - -func _swig_wrap_XYZEnu_opNotXYZ4(base SwigcptrXYZEnu) (_ SwigcptrNotXYZEnu) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_XYZEnu_opNotXYZ4, _swig_p) - return -} - -func (arg1 SwigcptrXYZEnu) OpNotXYZ4() (_swig_ret NotXYZEnu) { - return _swig_wrap_XYZEnu_opNotXYZ4(arg1) -} - -var _wrap_XYZEnu_opXYZ4 unsafe.Pointer - -func _swig_wrap_XYZEnu_opXYZ4(base SwigcptrXYZEnu) (_ SwigcptrXYZEnu) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_XYZEnu_opXYZ4, _swig_p) - return -} - -func (arg1 SwigcptrXYZEnu) OpXYZ4() (_swig_ret XYZEnu) { - return _swig_wrap_XYZEnu_opXYZ4(arg1) -} - -var _wrap_new_XYZEnu unsafe.Pointer - -func _swig_wrap_new_XYZEnu() (base SwigcptrXYZEnu) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_XYZEnu, _swig_p) - return -} - -func NewXYZEnu() (_swig_ret XYZEnu) { - return _swig_wrap_new_XYZEnu() -} - -var _wrap_delete_XYZEnu unsafe.Pointer - -func _swig_wrap_delete_XYZEnu(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_XYZEnu, _swig_p) - return -} - -func DeleteXYZEnu(arg1 XYZEnu) { - _swig_wrap_delete_XYZEnu(arg1.Swigcptr()) -} - -type XYZEnu interface { - Swigcptr() uintptr - SwigIsXYZEnu() - OpIntPtrA() (_swig_ret NotXYZInt) - OpIntPtrB() (_swig_ret XYZInt) - OpAnother4() (_swig_ret Another) - TMethod4(arg2 SpaceEnu) - TMethodNotXYZ4(arg2 NotXYZEnu) - TMethodXYZ4(arg2 XYZEnu) - OpT4() (_swig_ret SpaceEnu) - OpNotXYZ4() (_swig_ret NotXYZEnu) - OpXYZ4() (_swig_ret XYZEnu) -} - -type SwigcptrNotXYZInt uintptr - -func (p SwigcptrNotXYZInt) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrNotXYZInt) SwigIsNotXYZInt() { -} - -var _wrap_new_NotXYZInt unsafe.Pointer - -func _swig_wrap_new_NotXYZInt() (base SwigcptrNotXYZInt) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_NotXYZInt, _swig_p) - return -} - -func NewNotXYZInt() (_swig_ret NotXYZInt) { - return _swig_wrap_new_NotXYZInt() -} - -var _wrap_delete_NotXYZInt unsafe.Pointer - -func _swig_wrap_delete_NotXYZInt(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_NotXYZInt, _swig_p) - return -} - -func DeleteNotXYZInt(arg1 NotXYZInt) { - _swig_wrap_delete_NotXYZInt(arg1.Swigcptr()) -} - -type NotXYZInt interface { - Swigcptr() uintptr - SwigIsNotXYZInt() -} - -type SwigcptrNotXYZDouble uintptr - -func (p SwigcptrNotXYZDouble) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrNotXYZDouble) SwigIsNotXYZDouble() { -} - -var _wrap_new_NotXYZDouble unsafe.Pointer - -func _swig_wrap_new_NotXYZDouble() (base SwigcptrNotXYZDouble) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_NotXYZDouble, _swig_p) - return -} - -func NewNotXYZDouble() (_swig_ret NotXYZDouble) { - return _swig_wrap_new_NotXYZDouble() -} - -var _wrap_delete_NotXYZDouble unsafe.Pointer - -func _swig_wrap_delete_NotXYZDouble(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_NotXYZDouble, _swig_p) - return -} - -func DeleteNotXYZDouble(arg1 NotXYZDouble) { - _swig_wrap_delete_NotXYZDouble(arg1.Swigcptr()) -} - -type NotXYZDouble interface { - Swigcptr() uintptr - SwigIsNotXYZDouble() -} - -type SwigcptrNotXYZKlass uintptr - -func (p SwigcptrNotXYZKlass) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrNotXYZKlass) SwigIsNotXYZKlass() { -} - -var _wrap_new_NotXYZKlass unsafe.Pointer - -func _swig_wrap_new_NotXYZKlass() (base SwigcptrNotXYZKlass) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_NotXYZKlass, _swig_p) - return -} - -func NewNotXYZKlass() (_swig_ret NotXYZKlass) { - return _swig_wrap_new_NotXYZKlass() -} - -var _wrap_delete_NotXYZKlass unsafe.Pointer - -func _swig_wrap_delete_NotXYZKlass(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_NotXYZKlass, _swig_p) - return -} - -func DeleteNotXYZKlass(arg1 NotXYZKlass) { - _swig_wrap_delete_NotXYZKlass(arg1.Swigcptr()) -} - -type NotXYZKlass interface { - Swigcptr() uintptr - SwigIsNotXYZKlass() -} - -type SwigcptrNotXYZEnu uintptr - -func (p SwigcptrNotXYZEnu) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrNotXYZEnu) SwigIsNotXYZEnu() { -} - -var _wrap_new_NotXYZEnu unsafe.Pointer - -func _swig_wrap_new_NotXYZEnu() (base SwigcptrNotXYZEnu) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_NotXYZEnu, _swig_p) - return -} - -func NewNotXYZEnu() (_swig_ret NotXYZEnu) { - return _swig_wrap_new_NotXYZEnu() -} - -var _wrap_delete_NotXYZEnu unsafe.Pointer - -func _swig_wrap_delete_NotXYZEnu(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_NotXYZEnu, _swig_p) - return -} - -func DeleteNotXYZEnu(arg1 NotXYZEnu) { - _swig_wrap_delete_NotXYZEnu(arg1.Swigcptr()) -} - -type NotXYZEnu interface { - Swigcptr() uintptr - SwigIsNotXYZEnu() -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/rename_pcre_encoder.go b/Examples/test-suite/go/rename_pcre_encoder.go deleted file mode 100644 index 468cd366f..000000000 --- a/Examples/test-suite/go/rename_pcre_encoder.go +++ /dev/null @@ -1,274 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../rename_pcre_encoder.i - -package rename_pcre_encoder - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrSomeWidget uintptr - -func (p SwigcptrSomeWidget) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrSomeWidget) SwigIsSomeWidget() { -} - -var _wrap_SomeWidget_put_borderWidth unsafe.Pointer - -func _swig_wrap_SomeWidget_put_borderWidth(base SwigcptrSomeWidget, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_SomeWidget_put_borderWidth, _swig_p) - return -} - -func (arg1 SwigcptrSomeWidget) Put_borderWidth(arg2 int) { - _swig_wrap_SomeWidget_put_borderWidth(arg1, arg2) -} - -var _wrap_SomeWidget_get_borderWidth unsafe.Pointer - -func _swig_wrap_SomeWidget_get_borderWidth(base SwigcptrSomeWidget) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_SomeWidget_get_borderWidth, _swig_p) - return -} - -func (arg1 SwigcptrSomeWidget) Get_borderWidth() (_swig_ret int) { - return _swig_wrap_SomeWidget_get_borderWidth(arg1) -} - -var _wrap_SomeWidget_put_size unsafe.Pointer - -func _swig_wrap_SomeWidget_put_size(base SwigcptrSomeWidget, _ int, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_SomeWidget_put_size, _swig_p) - return -} - -func (arg1 SwigcptrSomeWidget) Put_size(arg2 int, arg3 int) { - _swig_wrap_SomeWidget_put_size(arg1, arg2, arg3) -} - -var _wrap_SomeWidget_m_width_set unsafe.Pointer - -func _swig_wrap_SomeWidget_m_width_set(base SwigcptrSomeWidget, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_SomeWidget_m_width_set, _swig_p) - return -} - -func (arg1 SwigcptrSomeWidget) SetM_width(arg2 int) { - _swig_wrap_SomeWidget_m_width_set(arg1, arg2) -} - -var _wrap_SomeWidget_m_width_get unsafe.Pointer - -func _swig_wrap_SomeWidget_m_width_get(base SwigcptrSomeWidget) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_SomeWidget_m_width_get, _swig_p) - return -} - -func (arg1 SwigcptrSomeWidget) GetM_width() (_swig_ret int) { - return _swig_wrap_SomeWidget_m_width_get(arg1) -} - -var _wrap_new_SomeWidget unsafe.Pointer - -func _swig_wrap_new_SomeWidget() (base SwigcptrSomeWidget) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_SomeWidget, _swig_p) - return -} - -func NewSomeWidget() (_swig_ret SomeWidget) { - return _swig_wrap_new_SomeWidget() -} - -var _wrap_delete_SomeWidget unsafe.Pointer - -func _swig_wrap_delete_SomeWidget(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_SomeWidget, _swig_p) - return -} - -func DeleteSomeWidget(arg1 SomeWidget) { - _swig_wrap_delete_SomeWidget(arg1.Swigcptr()) -} - -type SomeWidget interface { - Swigcptr() uintptr - SwigIsSomeWidget() - Put_borderWidth(arg2 int) - Get_borderWidth() (_swig_ret int) - Put_size(arg2 int, arg3 int) - SetM_width(arg2 int) - GetM_width() (_swig_ret int) -} - -type SwigcptrAnotherWidget uintptr - -func (p SwigcptrAnotherWidget) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrAnotherWidget) SwigIsAnotherWidget() { -} - -var _wrap_AnotherWidget_DoSomething unsafe.Pointer - -func _swig_wrap_AnotherWidget_DoSomething(base SwigcptrAnotherWidget) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_AnotherWidget_DoSomething, _swig_p) - return -} - -func (arg1 SwigcptrAnotherWidget) DoSomething() { - _swig_wrap_AnotherWidget_DoSomething(arg1) -} - -var _wrap_new_AnotherWidget unsafe.Pointer - -func _swig_wrap_new_AnotherWidget() (base SwigcptrAnotherWidget) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_AnotherWidget, _swig_p) - return -} - -func NewAnotherWidget() (_swig_ret AnotherWidget) { - return _swig_wrap_new_AnotherWidget() -} - -var _wrap_delete_AnotherWidget unsafe.Pointer - -func _swig_wrap_delete_AnotherWidget(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_AnotherWidget, _swig_p) - return -} - -func DeleteAnotherWidget(arg1 AnotherWidget) { - _swig_wrap_delete_AnotherWidget(arg1.Swigcptr()) -} - -type AnotherWidget interface { - Swigcptr() uintptr - SwigIsAnotherWidget() - DoSomething() -} - -type SwigcptrWxEVTSomeEvent uintptr - -func (p SwigcptrWxEVTSomeEvent) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrWxEVTSomeEvent) SwigIsWxEVTSomeEvent() { -} - -var _wrap_new_wxEVTSomeEvent unsafe.Pointer - -func _swig_wrap_new_wxEVTSomeEvent() (base SwigcptrWxEVTSomeEvent) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_wxEVTSomeEvent, _swig_p) - return -} - -func NewWxEVTSomeEvent() (_swig_ret WxEVTSomeEvent) { - return _swig_wrap_new_wxEVTSomeEvent() -} - -var _wrap_delete_wxEVTSomeEvent unsafe.Pointer - -func _swig_wrap_delete_wxEVTSomeEvent(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_wxEVTSomeEvent, _swig_p) - return -} - -func DeleteWxEVTSomeEvent(arg1 WxEVTSomeEvent) { - _swig_wrap_delete_wxEVTSomeEvent(arg1.Swigcptr()) -} - -type WxEVTSomeEvent interface { - Swigcptr() uintptr - SwigIsWxEVTSomeEvent() -} - -type SwigcptrXUnchangedName uintptr - -func (p SwigcptrXUnchangedName) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrXUnchangedName) SwigIsXUnchangedName() { -} - -var _wrap_new_xUnchangedName unsafe.Pointer - -func _swig_wrap_new_xUnchangedName() (base SwigcptrXUnchangedName) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_xUnchangedName, _swig_p) - return -} - -func NewXUnchangedName() (_swig_ret XUnchangedName) { - return _swig_wrap_new_xUnchangedName() -} - -var _wrap_delete_xUnchangedName unsafe.Pointer - -func _swig_wrap_delete_xUnchangedName(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_xUnchangedName, _swig_p) - return -} - -func DeleteXUnchangedName(arg1 XUnchangedName) { - _swig_wrap_delete_xUnchangedName(arg1.Swigcptr()) -} - -type XUnchangedName interface { - Swigcptr() uintptr - SwigIsXUnchangedName() -} - -var _wrap_StartINSAneAndUNSAvoryTraNSAtlanticRaNSAck unsafe.Pointer - -func StartINSAneAndUNSAvoryTraNSAtlanticRaNSAck() (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_StartINSAneAndUNSAvoryTraNSAtlanticRaNSAck, _swig_p) - return -} - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/rename_pcre_enum.go b/Examples/test-suite/go/rename_pcre_enum.go deleted file mode 100644 index c14159c59..000000000 --- a/Examples/test-suite/go/rename_pcre_enum.go +++ /dev/null @@ -1,96 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../rename_pcre_enum.i - -package rename_pcre_enum - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type Foo int -var _wrap_First unsafe.Pointer - -func _swig_getFirst() (_swig_ret Foo) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_First, _swig_p) - return -} -var First Foo = _swig_getFirst() -var _wrap_Second unsafe.Pointer - -func _swig_getSecond() (_swig_ret Foo) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_Second, _swig_p) - return -} -var Second Foo = _swig_getSecond() -type BoundaryCondition int -var _wrap_MinMax unsafe.Pointer - -func _swig_getMinMax() (_swig_ret BoundaryCondition) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_MinMax, _swig_p) - return -} -var MinMax BoundaryCondition = _swig_getMinMax() -var _wrap_MaxMin unsafe.Pointer - -func _swig_getMaxMin() (_swig_ret BoundaryCondition) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_MaxMin, _swig_p) - return -} -var MaxMin BoundaryCondition = _swig_getMaxMin() -var _wrap_MaxMax unsafe.Pointer - -func _swig_getMaxMax() (_swig_ret BoundaryCondition) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_MaxMax, _swig_p) - return -} -var MaxMax BoundaryCondition = _swig_getMaxMax() -type Colour int -var _wrap_red unsafe.Pointer - -func _swig_getred() (_swig_ret Colour) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_red, _swig_p) - return -} -var Red Colour = _swig_getred() -var _wrap_blue unsafe.Pointer - -func _swig_getblue() (_swig_ret Colour) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_blue, _swig_p) - return -} -var Blue Colour = _swig_getblue() -var _wrap_green unsafe.Pointer - -func _swig_getgreen() (_swig_ret Colour) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_green, _swig_p) - return -} -var Green Colour = _swig_getgreen() - diff --git a/Examples/test-suite/go/rename_predicates.go b/Examples/test-suite/go/rename_predicates.go deleted file mode 100644 index d85ed19e1..000000000 --- a/Examples/test-suite/go/rename_predicates.go +++ /dev/null @@ -1,424 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../rename_predicates.i - -package rename_predicates - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrRenamePredicates uintptr - -func (p SwigcptrRenamePredicates) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrRenamePredicates) SwigIsRenamePredicates() { -} - -var _wrap_new_RenamePredicates__SWIG_0 unsafe.Pointer - -func _swig_wrap_new_RenamePredicates__SWIG_0(base int) (_ SwigcptrRenamePredicates) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_RenamePredicates__SWIG_0, _swig_p) - return -} - -func NewRenamePredicates__SWIG_0(arg1 int) (_swig_ret RenamePredicates) { - return _swig_wrap_new_RenamePredicates__SWIG_0(arg1) -} - -var _wrap_new_RenamePredicates__SWIG_1 unsafe.Pointer - -func _swig_wrap_new_RenamePredicates__SWIG_1() (base SwigcptrRenamePredicates) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_RenamePredicates__SWIG_1, _swig_p) - return -} - -func NewRenamePredicates__SWIG_1() (_swig_ret RenamePredicates) { - return _swig_wrap_new_RenamePredicates__SWIG_1() -} - -func NewRenamePredicates(a ...interface{}) RenamePredicates { - argc := len(a) - if argc == 0 { - return NewRenamePredicates__SWIG_1() - } - if argc == 1 { - return NewRenamePredicates__SWIG_0(a[0].(int)) - } - panic("No match for overloaded function call") -} - -var _wrap_RenamePredicates_MF_member_function unsafe.Pointer - -func _swig_wrap_RenamePredicates_MF_member_function(base SwigcptrRenamePredicates) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_RenamePredicates_MF_member_function, _swig_p) - return -} - -func (arg1 SwigcptrRenamePredicates) MF_member_function() { - _swig_wrap_RenamePredicates_MF_member_function(arg1) -} - -var _wrap_RenamePredicates_MF_static_member_function unsafe.Pointer - -func _swig_wrap_RenamePredicates_MF_static_member_function() { - var _swig_p uintptr - _cgo_runtime_cgocall(_wrap_RenamePredicates_MF_static_member_function, _swig_p) - return -} - -func RenamePredicatesMF_static_member_function() { - _swig_wrap_RenamePredicates_MF_static_member_function() -} - -var _wrap_RenamePredicates_MV_member_variable_set unsafe.Pointer - -func _swig_wrap_RenamePredicates_MV_member_variable_set(base SwigcptrRenamePredicates, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_RenamePredicates_MV_member_variable_set, _swig_p) - return -} - -func (arg1 SwigcptrRenamePredicates) SetMV_member_variable(arg2 int) { - _swig_wrap_RenamePredicates_MV_member_variable_set(arg1, arg2) -} - -var _wrap_RenamePredicates_MV_member_variable_get unsafe.Pointer - -func _swig_wrap_RenamePredicates_MV_member_variable_get(base SwigcptrRenamePredicates) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_RenamePredicates_MV_member_variable_get, _swig_p) - return -} - -func (arg1 SwigcptrRenamePredicates) GetMV_member_variable() (_swig_ret int) { - return _swig_wrap_RenamePredicates_MV_member_variable_get(arg1) -} - -var _wrap_RenamePredicates_MV_static_member_variable_set unsafe.Pointer - -func _swig_wrap_RenamePredicates_MV_static_member_variable_set(base int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_RenamePredicates_MV_static_member_variable_set, _swig_p) - return -} - -func SetRenamePredicatesMV_static_member_variable(arg1 int) { - _swig_wrap_RenamePredicates_MV_static_member_variable_set(arg1) -} - -var _wrap_RenamePredicates_MV_static_member_variable_get unsafe.Pointer - -func GetRenamePredicatesMV_static_member_variable() (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_RenamePredicates_MV_static_member_variable_get, _swig_p) - return -} -var _wrap_RenamePredicates_MF_extend_function_before unsafe.Pointer - -func _swig_wrap_RenamePredicates_MF_extend_function_before(base SwigcptrRenamePredicates) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_RenamePredicates_MF_extend_function_before, _swig_p) - return -} - -func (arg1 SwigcptrRenamePredicates) MF_extend_function_before() { - _swig_wrap_RenamePredicates_MF_extend_function_before(arg1) -} - -var _wrap_RenamePredicates_MF_extend_function_after unsafe.Pointer - -func _swig_wrap_RenamePredicates_MF_extend_function_after(base SwigcptrRenamePredicates) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_RenamePredicates_MF_extend_function_after, _swig_p) - return -} - -func (arg1 SwigcptrRenamePredicates) MF_extend_function_after() { - _swig_wrap_RenamePredicates_MF_extend_function_after(arg1) -} - -var _wrap_delete_RenamePredicates unsafe.Pointer - -func _swig_wrap_delete_RenamePredicates(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_RenamePredicates, _swig_p) - return -} - -func DeleteRenamePredicates(arg1 RenamePredicates) { - _swig_wrap_delete_RenamePredicates(arg1.Swigcptr()) -} - -type RenamePredicates interface { - Swigcptr() uintptr - SwigIsRenamePredicates() - MF_member_function() - SetMV_member_variable(arg2 int) - GetMV_member_variable() (_swig_ret int) - MF_extend_function_before() - MF_extend_function_after() -} - -var _wrap_GV_global_variable_set unsafe.Pointer - -func _swig_wrap_GV_global_variable_set(base int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_GV_global_variable_set, _swig_p) - return -} - -func SetGV_global_variable(arg1 int) { - _swig_wrap_GV_global_variable_set(arg1) -} - -var _wrap_GV_global_variable_get unsafe.Pointer - -func GetGV_global_variable() (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_GV_global_variable_get, _swig_p) - return -} -var _wrap_GF_global_function unsafe.Pointer - -func _swig_wrap_GF_global_function() { - var _swig_p uintptr - _cgo_runtime_cgocall(_wrap_GF_global_function, _swig_p) - return -} - -func GF_global_function() { - _swig_wrap_GF_global_function() -} - -var _wrap_UC_UPPERCASE unsafe.Pointer - -func _swig_wrap_UC_UPPERCASE() { - var _swig_p uintptr - _cgo_runtime_cgocall(_wrap_UC_UPPERCASE, _swig_p) - return -} - -func UC_UPPERCASE() { - _swig_wrap_UC_UPPERCASE() -} - -var _wrap_LC_lowercase unsafe.Pointer - -func _swig_wrap_LC_lowercase() { - var _swig_p uintptr - _cgo_runtime_cgocall(_wrap_LC_lowercase, _swig_p) - return -} - -func LC_lowercase() { - _swig_wrap_LC_lowercase() -} - -var _wrap_TI_Title unsafe.Pointer - -func _swig_wrap_TI_Title() { - var _swig_p uintptr - _cgo_runtime_cgocall(_wrap_TI_Title, _swig_p) - return -} - -func TI_Title() { - _swig_wrap_TI_Title() -} - -var _wrap_FU_FirstUpperCase unsafe.Pointer - -func _swig_wrap_FU_FirstUpperCase() { - var _swig_p uintptr - _cgo_runtime_cgocall(_wrap_FU_FirstUpperCase, _swig_p) - return -} - -func FU_FirstUpperCase() { - _swig_wrap_FU_FirstUpperCase() -} - -var _wrap_FL_firstLowerCase unsafe.Pointer - -func _swig_wrap_FL_firstLowerCase() { - var _swig_p uintptr - _cgo_runtime_cgocall(_wrap_FL_firstLowerCase, _swig_p) - return -} - -func FL_firstLowerCase() { - _swig_wrap_FL_firstLowerCase() -} - -var _wrap_CA_CamelCase unsafe.Pointer - -func _swig_wrap_CA_CamelCase() { - var _swig_p uintptr - _cgo_runtime_cgocall(_wrap_CA_CamelCase, _swig_p) - return -} - -func CA_CamelCase() { - _swig_wrap_CA_CamelCase() -} - -var _wrap_LC_lowerCamelCase unsafe.Pointer - -func _swig_wrap_LC_lowerCamelCase() { - var _swig_p uintptr - _cgo_runtime_cgocall(_wrap_LC_lowerCamelCase, _swig_p) - return -} - -func LC_lowerCamelCase() { - _swig_wrap_LC_lowerCamelCase() -} - -var _wrap_UC_under_case_it unsafe.Pointer - -func _swig_wrap_UC_under_case_it() { - var _swig_p uintptr - _cgo_runtime_cgocall(_wrap_UC_under_case_it, _swig_p) - return -} - -func UC_under_case_it() { - _swig_wrap_UC_under_case_it() -} - -type SwigcptrExtendCheck uintptr - -func (p SwigcptrExtendCheck) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrExtendCheck) SwigIsExtendCheck() { -} - -var _wrap_ExtendCheck_MF_real_member1 unsafe.Pointer - -func _swig_wrap_ExtendCheck_MF_real_member1(base SwigcptrExtendCheck) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_ExtendCheck_MF_real_member1, _swig_p) - return -} - -func (arg1 SwigcptrExtendCheck) MF_real_member1() { - _swig_wrap_ExtendCheck_MF_real_member1(arg1) -} - -var _wrap_ExtendCheck_EX_EXTENDMETHOD2 unsafe.Pointer - -func _swig_wrap_ExtendCheck_EX_EXTENDMETHOD2(base SwigcptrExtendCheck) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_ExtendCheck_EX_EXTENDMETHOD2, _swig_p) - return -} - -func (arg1 SwigcptrExtendCheck) EX_EXTENDMETHOD2() { - _swig_wrap_ExtendCheck_EX_EXTENDMETHOD2(arg1) -} - -var _wrap_ExtendCheck_MF_real_member2 unsafe.Pointer - -func _swig_wrap_ExtendCheck_MF_real_member2(base SwigcptrExtendCheck) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_ExtendCheck_MF_real_member2, _swig_p) - return -} - -func (arg1 SwigcptrExtendCheck) MF_real_member2() { - _swig_wrap_ExtendCheck_MF_real_member2(arg1) -} - -var _wrap_ExtendCheck_EX_EXTENDMETHOD1 unsafe.Pointer - -func _swig_wrap_ExtendCheck_EX_EXTENDMETHOD1(base SwigcptrExtendCheck) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_ExtendCheck_EX_EXTENDMETHOD1, _swig_p) - return -} - -func (arg1 SwigcptrExtendCheck) EX_EXTENDMETHOD1() { - _swig_wrap_ExtendCheck_EX_EXTENDMETHOD1(arg1) -} - -var _wrap_ExtendCheck_EX_EXTENDMETHOD3 unsafe.Pointer - -func _swig_wrap_ExtendCheck_EX_EXTENDMETHOD3(base SwigcptrExtendCheck) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_ExtendCheck_EX_EXTENDMETHOD3, _swig_p) - return -} - -func (arg1 SwigcptrExtendCheck) EX_EXTENDMETHOD3() { - _swig_wrap_ExtendCheck_EX_EXTENDMETHOD3(arg1) -} - -var _wrap_new_ExtendCheck unsafe.Pointer - -func _swig_wrap_new_ExtendCheck() (base SwigcptrExtendCheck) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_ExtendCheck, _swig_p) - return -} - -func NewExtendCheck() (_swig_ret ExtendCheck) { - return _swig_wrap_new_ExtendCheck() -} - -var _wrap_delete_ExtendCheck unsafe.Pointer - -func _swig_wrap_delete_ExtendCheck(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_ExtendCheck, _swig_p) - return -} - -func DeleteExtendCheck(arg1 ExtendCheck) { - _swig_wrap_delete_ExtendCheck(arg1.Swigcptr()) -} - -type ExtendCheck interface { - Swigcptr() uintptr - SwigIsExtendCheck() - MF_real_member1() - EX_EXTENDMETHOD2() - MF_real_member2() - EX_EXTENDMETHOD1() - EX_EXTENDMETHOD3() -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/rename_scope.go b/Examples/test-suite/go/rename_scope.go deleted file mode 100644 index f37f1d5b0..000000000 --- a/Examples/test-suite/go/rename_scope.go +++ /dev/null @@ -1,300 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../rename_scope.i - -package rename_scope - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type OssPolarization int -var _wrap_UnaryPolarization unsafe.Pointer - -func _swig_getUnaryPolarization() (_swig_ret OssPolarization) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_UnaryPolarization, _swig_p) - return -} -var UnaryPolarization OssPolarization = _swig_getUnaryPolarization() -var _wrap_BinaryPolarization unsafe.Pointer - -func _swig_getBinaryPolarization() (_swig_ret OssPolarization) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_BinaryPolarization, _swig_p) - return -} -var BinaryPolarization OssPolarization = _swig_getBinaryPolarization() -type SwigcptrInterface_UP uintptr - -func (p SwigcptrInterface_UP) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrInterface_UP) SwigIsInterface_UP() { -} - -var _wrap_new_Interface_UP unsafe.Pointer - -func _swig_wrap_new_Interface_UP() (base SwigcptrInterface_UP) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Interface_UP, _swig_p) - return -} - -func NewInterface_UP() (_swig_ret Interface_UP) { - return _swig_wrap_new_Interface_UP() -} - -var _wrap_delete_Interface_UP unsafe.Pointer - -func _swig_wrap_delete_Interface_UP(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Interface_UP, _swig_p) - return -} - -func DeleteInterface_UP(arg1 Interface_UP) { - _swig_wrap_delete_Interface_UP(arg1.Swigcptr()) -} - -type Interface_UP interface { - Swigcptr() uintptr - SwigIsInterface_UP() -} - -type SwigcptrInterface_BP uintptr - -func (p SwigcptrInterface_BP) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrInterface_BP) SwigIsInterface_BP() { -} - -var _wrap_new_Interface_BP unsafe.Pointer - -func _swig_wrap_new_Interface_BP() (base SwigcptrInterface_BP) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Interface_BP, _swig_p) - return -} - -func NewInterface_BP() (_swig_ret Interface_BP) { - return _swig_wrap_new_Interface_BP() -} - -var _wrap_delete_Interface_BP unsafe.Pointer - -func _swig_wrap_delete_Interface_BP(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Interface_BP, _swig_p) - return -} - -func DeleteInterface_BP(arg1 Interface_BP) { - _swig_wrap_delete_Interface_BP(arg1.Swigcptr()) -} - -type Interface_BP interface { - Swigcptr() uintptr - SwigIsInterface_BP() -} - -type SwigcptrNatural_UP uintptr - -func (p SwigcptrNatural_UP) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrNatural_UP) SwigIsNatural_UP() { -} - -var _wrap_Natural_UP_rtest unsafe.Pointer - -func _swig_wrap_Natural_UP_rtest(base SwigcptrNatural_UP) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Natural_UP_rtest, _swig_p) - return -} - -func (arg1 SwigcptrNatural_UP) Rtest() (_swig_ret int) { - return _swig_wrap_Natural_UP_rtest(arg1) -} - -var _wrap_new_Natural_UP unsafe.Pointer - -func _swig_wrap_new_Natural_UP() (base SwigcptrNatural_UP) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Natural_UP, _swig_p) - return -} - -func NewNatural_UP() (_swig_ret Natural_UP) { - return _swig_wrap_new_Natural_UP() -} - -var _wrap_delete_Natural_UP unsafe.Pointer - -func _swig_wrap_delete_Natural_UP(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Natural_UP, _swig_p) - return -} - -func DeleteNatural_UP(arg1 Natural_UP) { - _swig_wrap_delete_Natural_UP(arg1.Swigcptr()) -} - -func (p SwigcptrNatural_UP) SwigIsInterface_UP() { -} - -func (p SwigcptrNatural_UP) SwigGetInterface_UP() Interface_UP { - return SwigcptrInterface_UP(p.Swigcptr()) -} - -type Natural_UP interface { - Swigcptr() uintptr - SwigIsNatural_UP() - Rtest() (_swig_ret int) - SwigIsInterface_UP() - SwigGetInterface_UP() Interface_UP -} - -type SwigcptrNatural_BP uintptr - -func (p SwigcptrNatural_BP) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrNatural_BP) SwigIsNatural_BP() { -} - -var _wrap_Natural_BP_rtest unsafe.Pointer - -func _swig_wrap_Natural_BP_rtest(base SwigcptrNatural_BP) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Natural_BP_rtest, _swig_p) - return -} - -func (arg1 SwigcptrNatural_BP) Rtest() (_swig_ret int) { - return _swig_wrap_Natural_BP_rtest(arg1) -} - -var _wrap_new_Natural_BP unsafe.Pointer - -func _swig_wrap_new_Natural_BP() (base SwigcptrNatural_BP) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Natural_BP, _swig_p) - return -} - -func NewNatural_BP() (_swig_ret Natural_BP) { - return _swig_wrap_new_Natural_BP() -} - -var _wrap_delete_Natural_BP unsafe.Pointer - -func _swig_wrap_delete_Natural_BP(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Natural_BP, _swig_p) - return -} - -func DeleteNatural_BP(arg1 Natural_BP) { - _swig_wrap_delete_Natural_BP(arg1.Swigcptr()) -} - -func (p SwigcptrNatural_BP) SwigIsInterface_BP() { -} - -func (p SwigcptrNatural_BP) SwigGetInterface_BP() Interface_BP { - return SwigcptrInterface_BP(p.Swigcptr()) -} - -type Natural_BP interface { - Swigcptr() uintptr - SwigIsNatural_BP() - Rtest() (_swig_ret int) - SwigIsInterface_BP() - SwigGetInterface_BP() Interface_BP -} - -type SwigcptrBucket uintptr - -func (p SwigcptrBucket) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrBucket) SwigIsBucket() { -} - -var _wrap_new_Bucket unsafe.Pointer - -func _swig_wrap_new_Bucket() (base SwigcptrBucket) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Bucket, _swig_p) - return -} - -func NewBucket() (_swig_ret Bucket) { - return _swig_wrap_new_Bucket() -} - -var _wrap_equals unsafe.Pointer - -func _swig_wrap_equals(base uintptr, _ uintptr) (_ bool) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_equals, _swig_p) - return -} - -func Equals(arg1 Bucket, arg2 Bucket) (_swig_ret bool) { - return _swig_wrap_equals(arg1.Swigcptr(), arg2.Swigcptr()) -} - -var _wrap_delete_Bucket unsafe.Pointer - -func _swig_wrap_delete_Bucket(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Bucket, _swig_p) - return -} - -func DeleteBucket(arg1 Bucket) { - _swig_wrap_delete_Bucket(arg1.Swigcptr()) -} - -type Bucket interface { - Swigcptr() uintptr - SwigIsBucket() -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/rename_scope_runme b/Examples/test-suite/go/rename_scope_runme deleted file mode 100755 index 36112680e..000000000 Binary files a/Examples/test-suite/go/rename_scope_runme and /dev/null differ diff --git a/Examples/test-suite/go/rename_simple.go b/Examples/test-suite/go/rename_simple.go deleted file mode 100644 index 92b20e273..000000000 --- a/Examples/test-suite/go/rename_simple.go +++ /dev/null @@ -1,190 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../rename_simple.i - -package rename_simple - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrNewStruct uintptr - -func (p SwigcptrNewStruct) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrNewStruct) SwigIsNewStruct() { -} - -var _wrap_ONE_NewStruct unsafe.Pointer - -func _swig_getNewStruct_ONE_NewStruct() (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_ONE_NewStruct, _swig_p) - return -} -var NewStructONE int = _swig_getNewStruct_ONE_NewStruct() -var _wrap_TWO_NewStruct unsafe.Pointer - -func _swig_getNewStruct_TWO_NewStruct() (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_TWO_NewStruct, _swig_p) - return -} -var NewStructTWO int = _swig_getNewStruct_TWO_NewStruct() -var _wrap_THREE_NewStruct unsafe.Pointer - -func _swig_getNewStruct_THREE_NewStruct() (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_THREE_NewStruct, _swig_p) - return -} -var NewStructTHREE int = _swig_getNewStruct_THREE_NewStruct() -var _wrap_new_NewStruct unsafe.Pointer - -func _swig_wrap_new_NewStruct() (base SwigcptrNewStruct) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_NewStruct, _swig_p) - return -} - -func NewNewStruct() (_swig_ret NewStruct) { - return _swig_wrap_new_NewStruct() -} - -var _wrap_NewStruct_NewInstanceVariable_set unsafe.Pointer - -func _swig_wrap_NewStruct_NewInstanceVariable_set(base SwigcptrNewStruct, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_NewStruct_NewInstanceVariable_set, _swig_p) - return -} - -func (arg1 SwigcptrNewStruct) SetNewInstanceVariable(arg2 int) { - _swig_wrap_NewStruct_NewInstanceVariable_set(arg1, arg2) -} - -var _wrap_NewStruct_NewInstanceVariable_get unsafe.Pointer - -func _swig_wrap_NewStruct_NewInstanceVariable_get(base SwigcptrNewStruct) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_NewStruct_NewInstanceVariable_get, _swig_p) - return -} - -func (arg1 SwigcptrNewStruct) GetNewInstanceVariable() (_swig_ret int) { - return _swig_wrap_NewStruct_NewInstanceVariable_get(arg1) -} - -var _wrap_NewStruct_NewInstanceMethod unsafe.Pointer - -func _swig_wrap_NewStruct_NewInstanceMethod(base SwigcptrNewStruct) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_NewStruct_NewInstanceMethod, _swig_p) - return -} - -func (arg1 SwigcptrNewStruct) NewInstanceMethod() (_swig_ret int) { - return _swig_wrap_NewStruct_NewInstanceMethod(arg1) -} - -var _wrap_NewStruct_NewStaticVariable_set unsafe.Pointer - -func _swig_wrap_NewStruct_NewStaticVariable_set(base int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_NewStruct_NewStaticVariable_set, _swig_p) - return -} - -func SetNewStructNewStaticVariable(arg1 int) { - _swig_wrap_NewStruct_NewStaticVariable_set(arg1) -} - -var _wrap_NewStruct_NewStaticVariable_get unsafe.Pointer - -func GetNewStructNewStaticVariable() (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_NewStruct_NewStaticVariable_get, _swig_p) - return -} -var _wrap_NewStruct_NewStaticMethod unsafe.Pointer - -func NewStructNewStaticMethod() (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_NewStruct_NewStaticMethod, _swig_p) - return -} -var _wrap_delete_NewStruct unsafe.Pointer - -func _swig_wrap_delete_NewStruct(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_NewStruct, _swig_p) - return -} - -func DeleteNewStruct(arg1 NewStruct) { - _swig_wrap_delete_NewStruct(arg1.Swigcptr()) -} - -type NewStruct interface { - Swigcptr() uintptr - SwigIsNewStruct() - SetNewInstanceVariable(arg2 int) - GetNewInstanceVariable() (_swig_ret int) - NewInstanceMethod() (_swig_ret int) -} - -var _wrap_NewFunction unsafe.Pointer - -func NewFunction() (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_NewFunction, _swig_p) - return -} -var _wrap_NewGlobalVariable_set unsafe.Pointer - -func _swig_wrap_NewGlobalVariable_set(base int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_NewGlobalVariable_set, _swig_p) - return -} - -func SetNewGlobalVariable(arg1 int) { - _swig_wrap_NewGlobalVariable_set(arg1) -} - -var _wrap_NewGlobalVariable_get unsafe.Pointer - -func GetNewGlobalVariable() (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_NewGlobalVariable_get, _swig_p) - return -} - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/rename_simple_runme b/Examples/test-suite/go/rename_simple_runme deleted file mode 100755 index df2bb2983..000000000 Binary files a/Examples/test-suite/go/rename_simple_runme and /dev/null differ diff --git a/Examples/test-suite/go/rename_strip_encoder.go b/Examples/test-suite/go/rename_strip_encoder.go deleted file mode 100644 index e0cedabb9..000000000 --- a/Examples/test-suite/go/rename_strip_encoder.go +++ /dev/null @@ -1,126 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../rename_strip_encoder.i - -package rename_strip_encoder - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrSomeWidget uintptr - -func (p SwigcptrSomeWidget) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrSomeWidget) SwigIsSomeWidget() { -} - -var _wrap_new_SomeWidget unsafe.Pointer - -func _swig_wrap_new_SomeWidget() (base SwigcptrSomeWidget) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_SomeWidget, _swig_p) - return -} - -func NewSomeWidget() (_swig_ret SomeWidget) { - return _swig_wrap_new_SomeWidget() -} - -var _wrap_delete_SomeWidget unsafe.Pointer - -func _swig_wrap_delete_SomeWidget(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_SomeWidget, _swig_p) - return -} - -func DeleteSomeWidget(arg1 SomeWidget) { - _swig_wrap_delete_SomeWidget(arg1.Swigcptr()) -} - -type SomeWidget interface { - Swigcptr() uintptr - SwigIsSomeWidget() -} - -type SwigcptrAnotherWidget uintptr - -func (p SwigcptrAnotherWidget) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrAnotherWidget) SwigIsAnotherWidget() { -} - -var _wrap_AnotherWidget_DoSomething unsafe.Pointer - -func _swig_wrap_AnotherWidget_DoSomething(base SwigcptrAnotherWidget) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_AnotherWidget_DoSomething, _swig_p) - return -} - -func (arg1 SwigcptrAnotherWidget) DoSomething() { - _swig_wrap_AnotherWidget_DoSomething(arg1) -} - -var _wrap_new_AnotherWidget unsafe.Pointer - -func _swig_wrap_new_AnotherWidget() (base SwigcptrAnotherWidget) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_AnotherWidget, _swig_p) - return -} - -func NewAnotherWidget() (_swig_ret AnotherWidget) { - return _swig_wrap_new_AnotherWidget() -} - -var _wrap_delete_AnotherWidget unsafe.Pointer - -func _swig_wrap_delete_AnotherWidget(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_AnotherWidget, _swig_p) - return -} - -func DeleteAnotherWidget(arg1 AnotherWidget) { - _swig_wrap_delete_AnotherWidget(arg1.Swigcptr()) -} - -type AnotherWidget interface { - Swigcptr() uintptr - SwigIsAnotherWidget() - DoSomething() -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/rename_strip_encoder_runme b/Examples/test-suite/go/rename_strip_encoder_runme deleted file mode 100755 index dd7dcd5b8..000000000 Binary files a/Examples/test-suite/go/rename_strip_encoder_runme and /dev/null differ diff --git a/Examples/test-suite/go/restrict_cplusplus.go b/Examples/test-suite/go/restrict_cplusplus.go deleted file mode 100644 index 4c0706a33..000000000 --- a/Examples/test-suite/go/restrict_cplusplus.go +++ /dev/null @@ -1,101 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../restrict_cplusplus.i - -package restrict_cplusplus - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrFoo uintptr - -func (p SwigcptrFoo) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrFoo) SwigIsFoo() { -} - -var _wrap_Foo_restrict_set unsafe.Pointer - -func _swig_wrap_Foo_restrict_set(base SwigcptrFoo, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_restrict_set, _swig_p) - return -} - -func (arg1 SwigcptrFoo) SetRestrict(arg2 int) { - _swig_wrap_Foo_restrict_set(arg1, arg2) -} - -var _wrap_Foo_restrict_get unsafe.Pointer - -func _swig_wrap_Foo_restrict_get(base SwigcptrFoo) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_restrict_get, _swig_p) - return -} - -func (arg1 SwigcptrFoo) GetRestrict() (_swig_ret int) { - return _swig_wrap_Foo_restrict_get(arg1) -} - -var _wrap_new_Foo unsafe.Pointer - -func _swig_wrap_new_Foo() (base SwigcptrFoo) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Foo, _swig_p) - return -} - -func NewFoo() (_swig_ret Foo) { - return _swig_wrap_new_Foo() -} - -var _wrap_delete_Foo unsafe.Pointer - -func _swig_wrap_delete_Foo(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Foo, _swig_p) - return -} - -func DeleteFoo(arg1 Foo) { - _swig_wrap_delete_Foo(arg1.Swigcptr()) -} - -type Foo interface { - Swigcptr() uintptr - SwigIsFoo() - SetRestrict(arg2 int) - GetRestrict() (_swig_ret int) -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/ret_by_value.go b/Examples/test-suite/go/ret_by_value.go deleted file mode 100644 index e8ffd5700..000000000 --- a/Examples/test-suite/go/ret_by_value.go +++ /dev/null @@ -1,139 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../ret_by_value.i - -package ret_by_value - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrTest uintptr - -func (p SwigcptrTest) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrTest) SwigIsTest() { -} - -var _wrap_test_myInt_set unsafe.Pointer - -func _swig_wrap_test_myInt_set(base SwigcptrTest, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_test_myInt_set, _swig_p) - return -} - -func (arg1 SwigcptrTest) SetMyInt(arg2 int) { - _swig_wrap_test_myInt_set(arg1, arg2) -} - -var _wrap_test_myInt_get unsafe.Pointer - -func _swig_wrap_test_myInt_get(base SwigcptrTest) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_test_myInt_get, _swig_p) - return -} - -func (arg1 SwigcptrTest) GetMyInt() (_swig_ret int) { - return _swig_wrap_test_myInt_get(arg1) -} - -var _wrap_test_myShort_set unsafe.Pointer - -func _swig_wrap_test_myShort_set(base SwigcptrTest, _ int16) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_test_myShort_set, _swig_p) - return -} - -func (arg1 SwigcptrTest) SetMyShort(arg2 int16) { - _swig_wrap_test_myShort_set(arg1, arg2) -} - -var _wrap_test_myShort_get unsafe.Pointer - -func _swig_wrap_test_myShort_get(base SwigcptrTest) (_ int16) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_test_myShort_get, _swig_p) - return -} - -func (arg1 SwigcptrTest) GetMyShort() (_swig_ret int16) { - return _swig_wrap_test_myShort_get(arg1) -} - -var _wrap_new_test unsafe.Pointer - -func _swig_wrap_new_test() (base SwigcptrTest) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_test, _swig_p) - return -} - -func NewTest() (_swig_ret Test) { - return _swig_wrap_new_test() -} - -var _wrap_delete_test unsafe.Pointer - -func _swig_wrap_delete_test(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_test, _swig_p) - return -} - -func DeleteTest(arg1 Test) { - _swig_wrap_delete_test(arg1.Swigcptr()) -} - -type Test interface { - Swigcptr() uintptr - SwigIsTest() - SetMyInt(arg2 int) - GetMyInt() (_swig_ret int) - SetMyShort(arg2 int16) - GetMyShort() (_swig_ret int16) -} - -var _wrap_get_test unsafe.Pointer - -func _swig_wrap_get_test() (base SwigcptrTest) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_get_test, _swig_p) - return -} - -func Get_test() (_swig_ret Test) { - return _swig_wrap_get_test() -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/ret_by_value_runme b/Examples/test-suite/go/ret_by_value_runme deleted file mode 100755 index 0ac7b6d8e..000000000 Binary files a/Examples/test-suite/go/ret_by_value_runme and /dev/null differ diff --git a/Examples/test-suite/go/return_const_value.go b/Examples/test-suite/go/return_const_value.go deleted file mode 100644 index 489d0fbe7..000000000 --- a/Examples/test-suite/go/return_const_value.go +++ /dev/null @@ -1,257 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../return_const_value.i - -package return_const_value - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrFoo uintptr - -func (p SwigcptrFoo) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrFoo) SwigIsFoo() { -} - -var _wrap_Foo__val_set unsafe.Pointer - -func _swig_wrap_Foo__val_set(base SwigcptrFoo, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo__val_set, _swig_p) - return -} - -func (arg1 SwigcptrFoo) SetX_val(arg2 int) { - _swig_wrap_Foo__val_set(arg1, arg2) -} - -var _wrap_Foo__val_get unsafe.Pointer - -func _swig_wrap_Foo__val_get(base SwigcptrFoo) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo__val_get, _swig_p) - return -} - -func (arg1 SwigcptrFoo) GetX_val() (_swig_ret int) { - return _swig_wrap_Foo__val_get(arg1) -} - -var _wrap_new_Foo unsafe.Pointer - -func _swig_wrap_new_Foo(base int) (_ SwigcptrFoo) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Foo, _swig_p) - return -} - -func NewFoo(arg1 int) (_swig_ret Foo) { - return _swig_wrap_new_Foo(arg1) -} - -var _wrap_Foo_getVal unsafe.Pointer - -func _swig_wrap_Foo_getVal(base SwigcptrFoo) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_getVal, _swig_p) - return -} - -func (arg1 SwigcptrFoo) GetVal() (_swig_ret int) { - return _swig_wrap_Foo_getVal(arg1) -} - -var _wrap_delete_Foo unsafe.Pointer - -func _swig_wrap_delete_Foo(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Foo, _swig_p) - return -} - -func DeleteFoo(arg1 Foo) { - _swig_wrap_delete_Foo(arg1.Swigcptr()) -} - -type Foo interface { - Swigcptr() uintptr - SwigIsFoo() - SetX_val(arg2 int) - GetX_val() (_swig_ret int) - GetVal() (_swig_ret int) -} - -type SwigcptrFoo_ptr uintptr - -func (p SwigcptrFoo_ptr) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrFoo_ptr) SwigIsFoo_ptr() { -} - -var _wrap_new_Foo_ptr__SWIG_0 unsafe.Pointer - -func _swig_wrap_new_Foo_ptr__SWIG_0(base uintptr, _ bool) (_ SwigcptrFoo_ptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Foo_ptr__SWIG_0, _swig_p) - return -} - -func NewFoo_ptr__SWIG_0(arg1 Foo, arg2 bool) (_swig_ret Foo_ptr) { - return _swig_wrap_new_Foo_ptr__SWIG_0(arg1.Swigcptr(), arg2) -} - -var _wrap_new_Foo_ptr__SWIG_1 unsafe.Pointer - -func _swig_wrap_new_Foo_ptr__SWIG_1(base uintptr) (_ SwigcptrFoo_ptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Foo_ptr__SWIG_1, _swig_p) - return -} - -func NewFoo_ptr__SWIG_1(arg1 Foo) (_swig_ret Foo_ptr) { - return _swig_wrap_new_Foo_ptr__SWIG_1(arg1.Swigcptr()) -} - -var _wrap_Foo_ptr_getPtr unsafe.Pointer - -func _swig_wrap_Foo_ptr_getPtr() (base SwigcptrFoo_ptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_ptr_getPtr, _swig_p) - return -} - -func Foo_ptrGetPtr() (_swig_ret Foo_ptr) { - return _swig_wrap_Foo_ptr_getPtr() -} - -var _wrap_Foo_ptr_getConstPtr unsafe.Pointer - -func _swig_wrap_Foo_ptr_getConstPtr() (base SwigcptrFoo_ptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_ptr_getConstPtr, _swig_p) - return -} - -func Foo_ptrGetConstPtr() (_swig_ret Foo_ptr) { - return _swig_wrap_Foo_ptr_getConstPtr() -} - -var _wrap_Foo_ptr___deref__ unsafe.Pointer - -func _swig_wrap_Foo_ptr___deref__(base SwigcptrFoo_ptr) (_ SwigcptrFoo) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_ptr___deref__, _swig_p) - return -} - -func (arg1 SwigcptrFoo_ptr) X__deref__() (_swig_ret Foo) { - return _swig_wrap_Foo_ptr___deref__(arg1) -} - -var _wrap_new_Foo_ptr__SWIG_2 unsafe.Pointer - -func _swig_wrap_new_Foo_ptr__SWIG_2(base uintptr) (_ SwigcptrFoo_ptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Foo_ptr__SWIG_2, _swig_p) - return -} - -func NewFoo_ptr__SWIG_2(arg1 Foo_ptr) (_swig_ret Foo_ptr) { - return _swig_wrap_new_Foo_ptr__SWIG_2(arg1.Swigcptr()) -} - -func NewFoo_ptr(a ...interface{}) Foo_ptr { - argc := len(a) - if argc == 1 { - if _, ok := a[0].(Foo); !ok { - goto check_1 - } - return NewFoo_ptr__SWIG_1(a[0].(Foo)) - } -check_1: - if argc == 1 { - return NewFoo_ptr__SWIG_2(a[0].(Foo_ptr)) - } - if argc == 2 { - return NewFoo_ptr__SWIG_0(a[0].(Foo), a[1].(bool)) - } - panic("No match for overloaded function call") -} - -var _wrap_delete_Foo_ptr unsafe.Pointer - -func _swig_wrap_delete_Foo_ptr(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Foo_ptr, _swig_p) - return -} - -func DeleteFoo_ptr(arg1 Foo_ptr) { - _swig_wrap_delete_Foo_ptr(arg1.Swigcptr()) -} - -var _wrap_Foo_ptr__val_get unsafe.Pointer - -func _swig_wrap_Foo_ptr__val_get(base SwigcptrFoo_ptr) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_ptr__val_get, _swig_p) - return -} - -func (arg1 SwigcptrFoo_ptr) GetX_val() (_swig_ret int) { - return _swig_wrap_Foo_ptr__val_get(arg1) -} - -var _wrap_Foo_ptr_getVal unsafe.Pointer - -func _swig_wrap_Foo_ptr_getVal(base SwigcptrFoo_ptr) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_ptr_getVal, _swig_p) - return -} - -func (arg1 SwigcptrFoo_ptr) GetVal() (_swig_ret int) { - return _swig_wrap_Foo_ptr_getVal(arg1) -} - -type Foo_ptr interface { - Swigcptr() uintptr - SwigIsFoo_ptr() - X__deref__() (_swig_ret Foo) - GetX_val() (_swig_ret int) - GetVal() (_swig_ret int) -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/return_const_value_runme b/Examples/test-suite/go/return_const_value_runme deleted file mode 100755 index 5de430b26..000000000 Binary files a/Examples/test-suite/go/return_const_value_runme and /dev/null differ diff --git a/Examples/test-suite/go/return_value_scope.go b/Examples/test-suite/go/return_value_scope.go deleted file mode 100644 index f00e591cb..000000000 --- a/Examples/test-suite/go/return_value_scope.go +++ /dev/null @@ -1,164 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../return_value_scope.i - -package return_value_scope - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrFoo uintptr - -func (p SwigcptrFoo) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrFoo) SwigIsFoo() { -} - -var _wrap_new_Foo unsafe.Pointer - -func _swig_wrap_new_Foo(base int) (_ SwigcptrFoo) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Foo, _swig_p) - return -} - -func NewFoo(arg1 int) (_swig_ret Foo) { - return _swig_wrap_new_Foo(arg1) -} - -var _wrap_delete_Foo unsafe.Pointer - -func _swig_wrap_delete_Foo(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Foo, _swig_p) - return -} - -func DeleteFoo(arg1 Foo) { - _swig_wrap_delete_Foo(arg1.Swigcptr()) -} - -type Foo interface { - Swigcptr() uintptr - SwigIsFoo() -} - -type SwigcptrBar uintptr - -func (p SwigcptrBar) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrBar) SwigIsBar() { -} - -var _wrap_new_Bar unsafe.Pointer - -func _swig_wrap_new_Bar() (base SwigcptrBar) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Bar, _swig_p) - return -} - -func NewBar() (_swig_ret Bar) { - return _swig_wrap_new_Bar() -} - -var _wrap_delete_Bar unsafe.Pointer - -func _swig_wrap_delete_Bar(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Bar, _swig_p) - return -} - -func DeleteBar(arg1 Bar) { - _swig_wrap_delete_Bar(arg1.Swigcptr()) -} - -type Bar interface { - Swigcptr() uintptr - SwigIsBar() -} - -type SwigcptrSpam uintptr - -func (p SwigcptrSpam) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrSpam) SwigIsSpam() { -} - -var _wrap_Spam_test unsafe.Pointer - -func _swig_wrap_Spam_test(base SwigcptrSpam) (_ SwigcptrFoo) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Spam_test, _swig_p) - return -} - -func (arg1 SwigcptrSpam) Test() (_swig_ret Foo) { - return _swig_wrap_Spam_test(arg1) -} - -var _wrap_new_Spam unsafe.Pointer - -func _swig_wrap_new_Spam() (base SwigcptrSpam) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Spam, _swig_p) - return -} - -func NewSpam() (_swig_ret Spam) { - return _swig_wrap_new_Spam() -} - -var _wrap_delete_Spam unsafe.Pointer - -func _swig_wrap_delete_Spam(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Spam, _swig_p) - return -} - -func DeleteSpam(arg1 Spam) { - _swig_wrap_delete_Spam(arg1.Swigcptr()) -} - -type Spam interface { - Swigcptr() uintptr - SwigIsSpam() - Test() (_swig_ret Foo) -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/rname.go b/Examples/test-suite/go/rname.go deleted file mode 100644 index 7498f2829..000000000 --- a/Examples/test-suite/go/rname.go +++ /dev/null @@ -1,292 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../rname.i - -package rname - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrBar uintptr - -func (p SwigcptrBar) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrBar) SwigIsBar() { -} - -var _wrap_Bar_foo_i unsafe.Pointer - -func _swig_wrap_Bar_foo_i(base SwigcptrBar, _ int) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Bar_foo_i, _swig_p) - return -} - -func (arg1 SwigcptrBar) Foo_i(arg2 int) (_swig_ret string) { - return _swig_wrap_Bar_foo_i(arg1, arg2) -} - -var _wrap_Bar_foo_d unsafe.Pointer - -func _swig_wrap_Bar_foo_d(base SwigcptrBar, _ float64) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Bar_foo_d, _swig_p) - return -} - -func (arg1 SwigcptrBar) Foo_d(arg2 float64) (_swig_ret string) { - return _swig_wrap_Bar_foo_d(arg1, arg2) -} - -var _wrap_Bar_foo unsafe.Pointer - -func _swig_wrap_Bar_foo(base SwigcptrBar, _ int16) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Bar_foo, _swig_p) - return -} - -func (arg1 SwigcptrBar) Foo(arg2 int16) (_swig_ret string) { - return _swig_wrap_Bar_foo(arg1, arg2) -} - -var _wrap_Bar_foo_u unsafe.Pointer - -func _swig_wrap_Bar_foo_u(base SwigcptrBar, _ uint) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Bar_foo_u, _swig_p) - return -} - -func (arg1 SwigcptrBar) Foo_u(arg2 uint) (_swig_ret string) { - return _swig_wrap_Bar_foo_u(arg1, arg2) -} - -var _wrap_new_Bar unsafe.Pointer - -func _swig_wrap_new_Bar() (base SwigcptrBar) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Bar, _swig_p) - return -} - -func NewBar() (_swig_ret Bar) { - return _swig_wrap_new_Bar() -} - -var _wrap_delete_Bar unsafe.Pointer - -func _swig_wrap_delete_Bar(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Bar, _swig_p) - return -} - -func DeleteBar(arg1 Bar) { - _swig_wrap_delete_Bar(arg1.Swigcptr()) -} - -type Bar interface { - Swigcptr() uintptr - SwigIsBar() - Foo_i(arg2 int) (_swig_ret string) - Foo_d(arg2 float64) (_swig_ret string) - Foo(arg2 int16) (_swig_ret string) - Foo_u(arg2 uint) (_swig_ret string) -} - -var _wrap_foo_i unsafe.Pointer - -func Foo_i(arg1 int) (_swig_ret string) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_foo_i, _swig_p) - return -} -var _wrap_foo_d unsafe.Pointer - -func Foo_d(arg1 float64) (_swig_ret string) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_foo_d, _swig_p) - return -} -var _wrap_foo_s unsafe.Pointer - -func Foo_s(arg1 int16) (_swig_ret string) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_foo_s, _swig_p) - return -} -var _wrap_foo unsafe.Pointer - -func Foo(arg1 uint) (_swig_ret string) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_foo, _swig_p) - return -} -type SwigcptrRenamedBase uintptr - -func (p SwigcptrRenamedBase) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrRenamedBase) SwigIsRenamedBase() { -} - -var _wrap_new_RenamedBase unsafe.Pointer - -func _swig_wrap_new_RenamedBase() (base SwigcptrRenamedBase) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_RenamedBase, _swig_p) - return -} - -func NewRenamedBase() (_swig_ret RenamedBase) { - return _swig_wrap_new_RenamedBase() -} - -var _wrap_delete_RenamedBase unsafe.Pointer - -func _swig_wrap_delete_RenamedBase(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_RenamedBase, _swig_p) - return -} - -func DeleteRenamedBase(arg1 RenamedBase) { - _swig_wrap_delete_RenamedBase(arg1.Swigcptr()) -} - -var _wrap_RenamedBase_fn unsafe.Pointer - -func _swig_wrap_RenamedBase_fn(base SwigcptrRenamedBase, _ uintptr, _ uintptr, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_RenamedBase_fn, _swig_p) - return -} - -func (arg1 SwigcptrRenamedBase) Fn(arg2 RenamedBase, arg3 RenamedBase, arg4 RenamedBase) { - _swig_wrap_RenamedBase_fn(arg1, arg2.Swigcptr(), arg3.Swigcptr(), arg4.Swigcptr()) -} - -var _wrap_RenamedBase_newname unsafe.Pointer - -func _swig_wrap_RenamedBase_newname(base SwigcptrRenamedBase, _ float64) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_RenamedBase_newname, _swig_p) - return -} - -func (arg1 SwigcptrRenamedBase) Newname(arg2 float64) (_swig_ret string) { - return _swig_wrap_RenamedBase_newname(arg1, arg2) -} - -type RenamedBase interface { - Swigcptr() uintptr - SwigIsRenamedBase() - Fn(arg2 RenamedBase, arg3 RenamedBase, arg4 RenamedBase) - Newname(arg2 float64) (_swig_ret string) -} - -type SwigcptrRenamedDerived uintptr - -func (p SwigcptrRenamedDerived) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrRenamedDerived) SwigIsRenamedDerived() { -} - -var _wrap_new_RenamedDerived unsafe.Pointer - -func _swig_wrap_new_RenamedDerived() (base SwigcptrRenamedDerived) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_RenamedDerived, _swig_p) - return -} - -func NewRenamedDerived() (_swig_ret RenamedDerived) { - return _swig_wrap_new_RenamedDerived() -} - -var _wrap_delete_RenamedDerived unsafe.Pointer - -func _swig_wrap_delete_RenamedDerived(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_RenamedDerived, _swig_p) - return -} - -func DeleteRenamedDerived(arg1 RenamedDerived) { - _swig_wrap_delete_RenamedDerived(arg1.Swigcptr()) -} - -var _wrap_RenamedDerived_Xfunc unsafe.Pointer - -func _swig_wrap_RenamedDerived_Xfunc(base SwigcptrRenamedDerived, _ uintptr, _ uintptr, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_RenamedDerived_Xfunc, _swig_p) - return -} - -func (arg1 SwigcptrRenamedDerived) Xfunc(arg2 RenamedBase, arg3 RenamedBase, arg4 RenamedBase) { - _swig_wrap_RenamedDerived_Xfunc(arg1, arg2.Swigcptr(), arg3.Swigcptr(), arg4.Swigcptr()) -} - -var _wrap_RenamedDerived_newname unsafe.Pointer - -func _swig_wrap_RenamedDerived_newname(base SwigcptrRenamedDerived, _ float64) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_RenamedDerived_newname, _swig_p) - return -} - -func (arg1 SwigcptrRenamedDerived) Newname(arg2 float64) (_swig_ret string) { - return _swig_wrap_RenamedDerived_newname(arg1, arg2) -} - -func (p SwigcptrRenamedDerived) SwigIsRenamedBase() { -} - -func (p SwigcptrRenamedDerived) SwigGetRenamedBase() RenamedBase { - return SwigcptrRenamedBase(p.Swigcptr()) -} - -type RenamedDerived interface { - Swigcptr() uintptr - SwigIsRenamedDerived() - Xfunc(arg2 RenamedBase, arg3 RenamedBase, arg4 RenamedBase) - Newname(arg2 float64) (_swig_ret string) - SwigIsRenamedBase() - SwigGetRenamedBase() RenamedBase -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/samename.go b/Examples/test-suite/go/samename.go deleted file mode 100644 index 322192826..000000000 --- a/Examples/test-suite/go/samename.go +++ /dev/null @@ -1,88 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../samename.i - -package samename - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrSamename uintptr - -func (p SwigcptrSamename) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrSamename) SwigIsSamename() { -} - -var _wrap_samename_do_something unsafe.Pointer - -func _swig_wrap_samename_do_something(base SwigcptrSamename) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_samename_do_something, _swig_p) - return -} - -func (arg1 SwigcptrSamename) Do_something() { - _swig_wrap_samename_do_something(arg1) -} - -var _wrap_new_samename unsafe.Pointer - -func _swig_wrap_new_samename() (base SwigcptrSamename) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_samename, _swig_p) - return -} - -func NewSamename() (_swig_ret Samename) { - return _swig_wrap_new_samename() -} - -var _wrap_delete_samename unsafe.Pointer - -func _swig_wrap_delete_samename(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_samename, _swig_p) - return -} - -func DeleteSamename(arg1 Samename) { - _swig_wrap_delete_samename(arg1.Swigcptr()) -} - -type Samename interface { - Swigcptr() uintptr - SwigIsSamename() - Do_something() -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/simple_array.go b/Examples/test-suite/go/simple_array.go deleted file mode 100644 index 2dfe676fb..000000000 --- a/Examples/test-suite/go/simple_array.go +++ /dev/null @@ -1,201 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../simple_array.i - -package simple_array - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -var _wrap_x_set unsafe.Pointer - -func _swig_wrap_x_set(base *int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_x_set, _swig_p) - return -} - -func SetX(arg1 *int) { - _swig_wrap_x_set(arg1) -} - -var _wrap_x_get unsafe.Pointer - -func GetX() (_swig_ret *int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_x_get, _swig_p) - return -} -var _wrap_y_set unsafe.Pointer - -func _swig_wrap_y_set(base *float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_y_set, _swig_p) - return -} - -func SetY(arg1 *float64) { - _swig_wrap_y_set(arg1) -} - -var _wrap_y_get unsafe.Pointer - -func GetY() (_swig_ret *float64) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_y_get, _swig_p) - return -} -type SwigcptrBarArray uintptr - -func (p SwigcptrBarArray) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrBarArray) SwigIsBarArray() { -} - -var _wrap_BarArray_i_set unsafe.Pointer - -func _swig_wrap_BarArray_i_set(base SwigcptrBarArray, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_BarArray_i_set, _swig_p) - return -} - -func (arg1 SwigcptrBarArray) SetI(arg2 int) { - _swig_wrap_BarArray_i_set(arg1, arg2) -} - -var _wrap_BarArray_i_get unsafe.Pointer - -func _swig_wrap_BarArray_i_get(base SwigcptrBarArray) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_BarArray_i_get, _swig_p) - return -} - -func (arg1 SwigcptrBarArray) GetI() (_swig_ret int) { - return _swig_wrap_BarArray_i_get(arg1) -} - -var _wrap_BarArray_d_set unsafe.Pointer - -func _swig_wrap_BarArray_d_set(base SwigcptrBarArray, _ float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_BarArray_d_set, _swig_p) - return -} - -func (arg1 SwigcptrBarArray) SetD(arg2 float64) { - _swig_wrap_BarArray_d_set(arg1, arg2) -} - -var _wrap_BarArray_d_get unsafe.Pointer - -func _swig_wrap_BarArray_d_get(base SwigcptrBarArray) (_ float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_BarArray_d_get, _swig_p) - return -} - -func (arg1 SwigcptrBarArray) GetD() (_swig_ret float64) { - return _swig_wrap_BarArray_d_get(arg1) -} - -var _wrap_new_BarArray unsafe.Pointer - -func _swig_wrap_new_BarArray() (base SwigcptrBarArray) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_BarArray, _swig_p) - return -} - -func NewBarArray() (_swig_ret BarArray) { - return _swig_wrap_new_BarArray() -} - -var _wrap_delete_BarArray unsafe.Pointer - -func _swig_wrap_delete_BarArray(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_BarArray, _swig_p) - return -} - -func DeleteBarArray(arg1 BarArray) { - _swig_wrap_delete_BarArray(arg1.Swigcptr()) -} - -type BarArray interface { - Swigcptr() uintptr - SwigIsBarArray() - SetI(arg2 int) - GetI() (_swig_ret int) - SetD(arg2 float64) - GetD() (_swig_ret float64) -} - -var _wrap_bars_set unsafe.Pointer - -func _swig_wrap_bars_set(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_bars_set, _swig_p) - return -} - -func SetBars(arg1 BarArray) { - _swig_wrap_bars_set(arg1.Swigcptr()) -} - -var _wrap_bars_get unsafe.Pointer - -func _swig_wrap_bars_get() (base SwigcptrBarArray) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_bars_get, _swig_p) - return -} - -func GetBars() (_swig_ret BarArray) { - return _swig_wrap_bars_get() -} - -var _wrap_initArray unsafe.Pointer - -func _swig_wrap_initArray() { - var _swig_p uintptr - _cgo_runtime_cgocall(_wrap_initArray, _swig_p) - return -} - -func InitArray() { - _swig_wrap_initArray() -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/sizeof_pointer.go b/Examples/test-suite/go/sizeof_pointer.go deleted file mode 100644 index 50ca2a54e..000000000 --- a/Examples/test-suite/go/sizeof_pointer.go +++ /dev/null @@ -1,153 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../sizeof_pointer.i - -package sizeof_pointer - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrSizeofPointerTest uintptr - -func (p SwigcptrSizeofPointerTest) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrSizeofPointerTest) SwigIsSizeofPointerTest() { -} - -var _wrap_SizeofPointerTest_array1_set unsafe.Pointer - -func _swig_wrap_SizeofPointerTest_array1_set(base SwigcptrSizeofPointerTest, _ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_SizeofPointerTest_array1_set, _swig_p) - return -} - -func (arg1 SwigcptrSizeofPointerTest) SetArray1(arg2 string) { - _swig_wrap_SizeofPointerTest_array1_set(arg1, arg2) -} - -var _wrap_SizeofPointerTest_array1_get unsafe.Pointer - -func _swig_wrap_SizeofPointerTest_array1_get(base SwigcptrSizeofPointerTest) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_SizeofPointerTest_array1_get, _swig_p) - return -} - -func (arg1 SwigcptrSizeofPointerTest) GetArray1() (_swig_ret string) { - return _swig_wrap_SizeofPointerTest_array1_get(arg1) -} - -var _wrap_SizeofPointerTest_array2_set unsafe.Pointer - -func _swig_wrap_SizeofPointerTest_array2_set(base SwigcptrSizeofPointerTest, _ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_SizeofPointerTest_array2_set, _swig_p) - return -} - -func (arg1 SwigcptrSizeofPointerTest) SetArray2(arg2 string) { - _swig_wrap_SizeofPointerTest_array2_set(arg1, arg2) -} - -var _wrap_SizeofPointerTest_array2_get unsafe.Pointer - -func _swig_wrap_SizeofPointerTest_array2_get(base SwigcptrSizeofPointerTest) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_SizeofPointerTest_array2_get, _swig_p) - return -} - -func (arg1 SwigcptrSizeofPointerTest) GetArray2() (_swig_ret string) { - return _swig_wrap_SizeofPointerTest_array2_get(arg1) -} - -var _wrap_SizeofPointerTest_array3_set unsafe.Pointer - -func _swig_wrap_SizeofPointerTest_array3_set(base SwigcptrSizeofPointerTest, _ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_SizeofPointerTest_array3_set, _swig_p) - return -} - -func (arg1 SwigcptrSizeofPointerTest) SetArray3(arg2 string) { - _swig_wrap_SizeofPointerTest_array3_set(arg1, arg2) -} - -var _wrap_SizeofPointerTest_array3_get unsafe.Pointer - -func _swig_wrap_SizeofPointerTest_array3_get(base SwigcptrSizeofPointerTest) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_SizeofPointerTest_array3_get, _swig_p) - return -} - -func (arg1 SwigcptrSizeofPointerTest) GetArray3() (_swig_ret string) { - return _swig_wrap_SizeofPointerTest_array3_get(arg1) -} - -var _wrap_new_SizeofPointerTest unsafe.Pointer - -func _swig_wrap_new_SizeofPointerTest() (base SwigcptrSizeofPointerTest) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_SizeofPointerTest, _swig_p) - return -} - -func NewSizeofPointerTest() (_swig_ret SizeofPointerTest) { - return _swig_wrap_new_SizeofPointerTest() -} - -var _wrap_delete_SizeofPointerTest unsafe.Pointer - -func _swig_wrap_delete_SizeofPointerTest(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_SizeofPointerTest, _swig_p) - return -} - -func DeleteSizeofPointerTest(arg1 SizeofPointerTest) { - _swig_wrap_delete_SizeofPointerTest(arg1.Swigcptr()) -} - -type SizeofPointerTest interface { - Swigcptr() uintptr - SwigIsSizeofPointerTest() - SetArray1(arg2 string) - GetArray1() (_swig_ret string) - SetArray2(arg2 string) - GetArray2() (_swig_ret string) - SetArray3(arg2 string) - GetArray3() (_swig_ret string) -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/sizet.go b/Examples/test-suite/go/sizet.go deleted file mode 100644 index 99deb22ed..000000000 --- a/Examples/test-suite/go/sizet.go +++ /dev/null @@ -1,57 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../sizet.i - -package sizet - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -var _wrap_test1 unsafe.Pointer - -func Test1(arg1 int64) (_swig_ret int64) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_test1, _swig_p) - return -} -var _wrap_test2 unsafe.Pointer - -func Test2(arg1 int64) (_swig_ret int64) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_test2, _swig_p) - return -} -var _wrap_test3 unsafe.Pointer - -func Test3(arg1 int64) (_swig_ret int64) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_test3, _swig_p) - return -} -var _wrap_test4 unsafe.Pointer - -func Test4(arg1 int64) (_swig_ret int64) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_test4, _swig_p) - return -} - diff --git a/Examples/test-suite/go/smart_pointer_const.go b/Examples/test-suite/go/smart_pointer_const.go deleted file mode 100644 index 9baad6c4b..000000000 --- a/Examples/test-suite/go/smart_pointer_const.go +++ /dev/null @@ -1,204 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../smart_pointer_const.i - -package smart_pointer_const - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrFoo uintptr - -func (p SwigcptrFoo) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrFoo) SwigIsFoo() { -} - -var _wrap_Foo_x_set unsafe.Pointer - -func _swig_wrap_Foo_x_set(base SwigcptrFoo, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_x_set, _swig_p) - return -} - -func (arg1 SwigcptrFoo) SetX(arg2 int) { - _swig_wrap_Foo_x_set(arg1, arg2) -} - -var _wrap_Foo_x_get unsafe.Pointer - -func _swig_wrap_Foo_x_get(base SwigcptrFoo) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_x_get, _swig_p) - return -} - -func (arg1 SwigcptrFoo) GetX() (_swig_ret int) { - return _swig_wrap_Foo_x_get(arg1) -} - -var _wrap_Foo_getx unsafe.Pointer - -func _swig_wrap_Foo_getx(base SwigcptrFoo) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_getx, _swig_p) - return -} - -func (arg1 SwigcptrFoo) Getx() (_swig_ret int) { - return _swig_wrap_Foo_getx(arg1) -} - -var _wrap_new_Foo unsafe.Pointer - -func _swig_wrap_new_Foo() (base SwigcptrFoo) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Foo, _swig_p) - return -} - -func NewFoo() (_swig_ret Foo) { - return _swig_wrap_new_Foo() -} - -var _wrap_delete_Foo unsafe.Pointer - -func _swig_wrap_delete_Foo(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Foo, _swig_p) - return -} - -func DeleteFoo(arg1 Foo) { - _swig_wrap_delete_Foo(arg1.Swigcptr()) -} - -type Foo interface { - Swigcptr() uintptr - SwigIsFoo() - SetX(arg2 int) - GetX() (_swig_ret int) - Getx() (_swig_ret int) -} - -type SwigcptrBar uintptr - -func (p SwigcptrBar) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrBar) SwigIsBar() { -} - -var _wrap_new_Bar unsafe.Pointer - -func _swig_wrap_new_Bar(base uintptr) (_ SwigcptrBar) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Bar, _swig_p) - return -} - -func NewBar(arg1 Foo) (_swig_ret Bar) { - return _swig_wrap_new_Bar(arg1.Swigcptr()) -} - -var _wrap_Bar___deref__ unsafe.Pointer - -func _swig_wrap_Bar___deref__(base SwigcptrBar) (_ SwigcptrFoo) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Bar___deref__, _swig_p) - return -} - -func (arg1 SwigcptrBar) X__deref__() (_swig_ret Foo) { - return _swig_wrap_Bar___deref__(arg1) -} - -var _wrap_delete_Bar unsafe.Pointer - -func _swig_wrap_delete_Bar(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Bar, _swig_p) - return -} - -func DeleteBar(arg1 Bar) { - _swig_wrap_delete_Bar(arg1.Swigcptr()) -} - -var _wrap_Bar_x_set unsafe.Pointer - -func _swig_wrap_Bar_x_set(base SwigcptrBar, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Bar_x_set, _swig_p) - return -} - -func (arg1 SwigcptrBar) SetX(arg2 int) { - _swig_wrap_Bar_x_set(arg1, arg2) -} - -var _wrap_Bar_x_get unsafe.Pointer - -func _swig_wrap_Bar_x_get(base SwigcptrBar) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Bar_x_get, _swig_p) - return -} - -func (arg1 SwigcptrBar) GetX() (_swig_ret int) { - return _swig_wrap_Bar_x_get(arg1) -} - -var _wrap_Bar_getx unsafe.Pointer - -func _swig_wrap_Bar_getx(base SwigcptrBar) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Bar_getx, _swig_p) - return -} - -func (arg1 SwigcptrBar) Getx() (_swig_ret int) { - return _swig_wrap_Bar_getx(arg1) -} - -type Bar interface { - Swigcptr() uintptr - SwigIsBar() - X__deref__() (_swig_ret Foo) - SetX(arg2 int) - GetX() (_swig_ret int) - Getx() (_swig_ret int) -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/smart_pointer_const2.go b/Examples/test-suite/go/smart_pointer_const2.go deleted file mode 100644 index dd10755fd..000000000 --- a/Examples/test-suite/go/smart_pointer_const2.go +++ /dev/null @@ -1,204 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../smart_pointer_const2.i - -package smart_pointer_const2 - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrFoo uintptr - -func (p SwigcptrFoo) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrFoo) SwigIsFoo() { -} - -var _wrap_Foo_x_set unsafe.Pointer - -func _swig_wrap_Foo_x_set(base SwigcptrFoo, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_x_set, _swig_p) - return -} - -func (arg1 SwigcptrFoo) SetX(arg2 int) { - _swig_wrap_Foo_x_set(arg1, arg2) -} - -var _wrap_Foo_x_get unsafe.Pointer - -func _swig_wrap_Foo_x_get(base SwigcptrFoo) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_x_get, _swig_p) - return -} - -func (arg1 SwigcptrFoo) GetX() (_swig_ret int) { - return _swig_wrap_Foo_x_get(arg1) -} - -var _wrap_Foo_getx unsafe.Pointer - -func _swig_wrap_Foo_getx(base SwigcptrFoo) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_getx, _swig_p) - return -} - -func (arg1 SwigcptrFoo) Getx() (_swig_ret int) { - return _swig_wrap_Foo_getx(arg1) -} - -var _wrap_Foo_test unsafe.Pointer - -func _swig_wrap_Foo_test(base SwigcptrFoo) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_test, _swig_p) - return -} - -func (arg1 SwigcptrFoo) Test() (_swig_ret int) { - return _swig_wrap_Foo_test(arg1) -} - -var _wrap_new_Foo unsafe.Pointer - -func _swig_wrap_new_Foo() (base SwigcptrFoo) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Foo, _swig_p) - return -} - -func NewFoo() (_swig_ret Foo) { - return _swig_wrap_new_Foo() -} - -var _wrap_delete_Foo unsafe.Pointer - -func _swig_wrap_delete_Foo(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Foo, _swig_p) - return -} - -func DeleteFoo(arg1 Foo) { - _swig_wrap_delete_Foo(arg1.Swigcptr()) -} - -type Foo interface { - Swigcptr() uintptr - SwigIsFoo() - SetX(arg2 int) - GetX() (_swig_ret int) - Getx() (_swig_ret int) - Test() (_swig_ret int) -} - -type SwigcptrBar uintptr - -func (p SwigcptrBar) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrBar) SwigIsBar() { -} - -var _wrap_new_Bar unsafe.Pointer - -func _swig_wrap_new_Bar(base uintptr) (_ SwigcptrBar) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Bar, _swig_p) - return -} - -func NewBar(arg1 Foo) (_swig_ret Bar) { - return _swig_wrap_new_Bar(arg1.Swigcptr()) -} - -var _wrap_Bar___deref__ unsafe.Pointer - -func _swig_wrap_Bar___deref__(base SwigcptrBar) (_ SwigcptrFoo) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Bar___deref__, _swig_p) - return -} - -func (arg1 SwigcptrBar) X__deref__() (_swig_ret Foo) { - return _swig_wrap_Bar___deref__(arg1) -} - -var _wrap_delete_Bar unsafe.Pointer - -func _swig_wrap_delete_Bar(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Bar, _swig_p) - return -} - -func DeleteBar(arg1 Bar) { - _swig_wrap_delete_Bar(arg1.Swigcptr()) -} - -var _wrap_Bar_x_get unsafe.Pointer - -func _swig_wrap_Bar_x_get(base SwigcptrBar) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Bar_x_get, _swig_p) - return -} - -func (arg1 SwigcptrBar) GetX() (_swig_ret int) { - return _swig_wrap_Bar_x_get(arg1) -} - -var _wrap_Bar_getx unsafe.Pointer - -func _swig_wrap_Bar_getx(base SwigcptrBar) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Bar_getx, _swig_p) - return -} - -func (arg1 SwigcptrBar) Getx() (_swig_ret int) { - return _swig_wrap_Bar_getx(arg1) -} - -type Bar interface { - Swigcptr() uintptr - SwigIsBar() - X__deref__() (_swig_ret Foo) - GetX() (_swig_ret int) - Getx() (_swig_ret int) -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/smart_pointer_const_overload.go b/Examples/test-suite/go/smart_pointer_const_overload.go deleted file mode 100644 index 9b6ef9b5b..000000000 --- a/Examples/test-suite/go/smart_pointer_const_overload.go +++ /dev/null @@ -1,805 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../smart_pointer_const_overload.i - -package smart_pointer_const_overload - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -var _wrap_CONST_ACCESS_set unsafe.Pointer - -func _swig_wrap_CONST_ACCESS_set(base int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_CONST_ACCESS_set, _swig_p) - return -} - -func SetCONST_ACCESS(arg1 int) { - _swig_wrap_CONST_ACCESS_set(arg1) -} - -var _wrap_CONST_ACCESS_get unsafe.Pointer - -func GetCONST_ACCESS() (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_CONST_ACCESS_get, _swig_p) - return -} -var _wrap_MUTABLE_ACCESS_set unsafe.Pointer - -func _swig_wrap_MUTABLE_ACCESS_set(base int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_MUTABLE_ACCESS_set, _swig_p) - return -} - -func SetMUTABLE_ACCESS(arg1 int) { - _swig_wrap_MUTABLE_ACCESS_set(arg1) -} - -var _wrap_MUTABLE_ACCESS_get unsafe.Pointer - -func GetMUTABLE_ACCESS() (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_MUTABLE_ACCESS_get, _swig_p) - return -} -var _wrap_new_int unsafe.Pointer - -func New_int(arg1 int) (_swig_ret *int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_new_int, _swig_p) - return -} -var _wrap_get_int unsafe.Pointer - -func Get_int(arg1 *int) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_get_int, _swig_p) - return -} -var _wrap_set_int unsafe.Pointer - -func _swig_wrap_set_int(base *int, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_set_int, _swig_p) - return -} - -func Set_int(arg1 *int, arg2 int) { - _swig_wrap_set_int(arg1, arg2) -} - -var _wrap_delete_int unsafe.Pointer - -func _swig_wrap_delete_int(base *int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_int, _swig_p) - return -} - -func Delete_int(arg1 *int) { - _swig_wrap_delete_int(arg1) -} - -type SwigcptrFoo uintptr - -func (p SwigcptrFoo) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrFoo) SwigIsFoo() { -} - -var _wrap_Foo_x_set unsafe.Pointer - -func _swig_wrap_Foo_x_set(base SwigcptrFoo, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_x_set, _swig_p) - return -} - -func (arg1 SwigcptrFoo) SetX(arg2 int) { - _swig_wrap_Foo_x_set(arg1, arg2) -} - -var _wrap_Foo_x_get unsafe.Pointer - -func _swig_wrap_Foo_x_get(base SwigcptrFoo) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_x_get, _swig_p) - return -} - -func (arg1 SwigcptrFoo) GetX() (_swig_ret int) { - return _swig_wrap_Foo_x_get(arg1) -} - -var _wrap_Foo_xp_get unsafe.Pointer - -func _swig_wrap_Foo_xp_get(base SwigcptrFoo) (_ *int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_xp_get, _swig_p) - return -} - -func (arg1 SwigcptrFoo) GetXp() (_swig_ret *int) { - return _swig_wrap_Foo_xp_get(arg1) -} - -var _wrap_Foo_y_get unsafe.Pointer - -func _swig_wrap_Foo_y_get(base SwigcptrFoo) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_y_get, _swig_p) - return -} - -func (arg1 SwigcptrFoo) GetY() (_swig_ret int) { - return _swig_wrap_Foo_y_get(arg1) -} - -var _wrap_Foo_yp_set unsafe.Pointer - -func _swig_wrap_Foo_yp_set(base SwigcptrFoo, _ *int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_yp_set, _swig_p) - return -} - -func (arg1 SwigcptrFoo) SetYp(arg2 *int) { - _swig_wrap_Foo_yp_set(arg1, arg2) -} - -var _wrap_Foo_yp_get unsafe.Pointer - -func _swig_wrap_Foo_yp_get(base SwigcptrFoo) (_ *int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_yp_get, _swig_p) - return -} - -func (arg1 SwigcptrFoo) GetYp() (_swig_ret *int) { - return _swig_wrap_Foo_yp_get(arg1) -} - -var _wrap_Foo_access_set unsafe.Pointer - -func _swig_wrap_Foo_access_set(base SwigcptrFoo, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_access_set, _swig_p) - return -} - -func (arg1 SwigcptrFoo) SetAccess(arg2 int) { - _swig_wrap_Foo_access_set(arg1, arg2) -} - -var _wrap_Foo_access_get unsafe.Pointer - -func _swig_wrap_Foo_access_get(base SwigcptrFoo) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_access_get, _swig_p) - return -} - -func (arg1 SwigcptrFoo) GetAccess() (_swig_ret int) { - return _swig_wrap_Foo_access_get(arg1) -} - -var _wrap_new_Foo unsafe.Pointer - -func _swig_wrap_new_Foo() (base SwigcptrFoo) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Foo, _swig_p) - return -} - -func NewFoo() (_swig_ret Foo) { - return _swig_wrap_new_Foo() -} - -var _wrap_Foo_getx unsafe.Pointer - -func _swig_wrap_Foo_getx(base SwigcptrFoo) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_getx, _swig_p) - return -} - -func (arg1 SwigcptrFoo) Getx() (_swig_ret int) { - return _swig_wrap_Foo_getx(arg1) -} - -var _wrap_Foo_setx unsafe.Pointer - -func _swig_wrap_Foo_setx(base SwigcptrFoo, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_setx, _swig_p) - return -} - -func (arg1 SwigcptrFoo) Setx(arg2 int) { - _swig_wrap_Foo_setx(arg1, arg2) -} - -var _wrap_Foo_stat unsafe.Pointer - -func _swig_wrap_Foo_stat() { - var _swig_p uintptr - _cgo_runtime_cgocall(_wrap_Foo_stat, _swig_p) - return -} - -func FooStat() { - _swig_wrap_Foo_stat() -} - -var _wrap_Foo_getx2 unsafe.Pointer - -func _swig_wrap_Foo_getx2(base SwigcptrFoo) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_getx2, _swig_p) - return -} - -func (arg1 SwigcptrFoo) Getx2() (_swig_ret int) { - return _swig_wrap_Foo_getx2(arg1) -} - -var _wrap_Foo_setx2 unsafe.Pointer - -func _swig_wrap_Foo_setx2(base SwigcptrFoo, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_setx2, _swig_p) - return -} - -func (arg1 SwigcptrFoo) Setx2(arg2 int) { - _swig_wrap_Foo_setx2(arg1, arg2) -} - -var _wrap_delete_Foo unsafe.Pointer - -func _swig_wrap_delete_Foo(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Foo, _swig_p) - return -} - -func DeleteFoo(arg1 Foo) { - _swig_wrap_delete_Foo(arg1.Swigcptr()) -} - -type Foo interface { - Swigcptr() uintptr - SwigIsFoo() - SetX(arg2 int) - GetX() (_swig_ret int) - GetXp() (_swig_ret *int) - GetY() (_swig_ret int) - SetYp(arg2 *int) - GetYp() (_swig_ret *int) - SetAccess(arg2 int) - GetAccess() (_swig_ret int) - Getx() (_swig_ret int) - Setx(arg2 int) - Getx2() (_swig_ret int) - Setx2(arg2 int) -} - -type SwigcptrBar uintptr - -func (p SwigcptrBar) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrBar) SwigIsBar() { -} - -var _wrap_new_Bar unsafe.Pointer - -func _swig_wrap_new_Bar(base uintptr) (_ SwigcptrBar) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Bar, _swig_p) - return -} - -func NewBar(arg1 Foo) (_swig_ret Bar) { - return _swig_wrap_new_Bar(arg1.Swigcptr()) -} - -var _wrap_Bar___deref____SWIG_0 unsafe.Pointer - -func _swig_wrap_Bar___deref____SWIG_0(base SwigcptrBar) (_ SwigcptrFoo) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Bar___deref____SWIG_0, _swig_p) - return -} - -func (arg1 SwigcptrBar) X__deref____SWIG_0() (_swig_ret Foo) { - return _swig_wrap_Bar___deref____SWIG_0(arg1) -} - -var _wrap_Bar___deref____SWIG_1 unsafe.Pointer - -func _swig_wrap_Bar___deref____SWIG_1(base SwigcptrBar) (_ SwigcptrFoo) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Bar___deref____SWIG_1, _swig_p) - return -} - -func (arg1 SwigcptrBar) X__deref____SWIG_1() (_swig_ret Foo) { - return _swig_wrap_Bar___deref____SWIG_1(arg1) -} - -func (p SwigcptrBar) X__deref__(a ...interface{}) interface{} { - argc := len(a) - if argc == 0 { - return p.X__deref____SWIG_0() - } - if argc == 0 { - return p.X__deref____SWIG_1() - } - panic("No match for overloaded function call") -} - -var _wrap_delete_Bar unsafe.Pointer - -func _swig_wrap_delete_Bar(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Bar, _swig_p) - return -} - -func DeleteBar(arg1 Bar) { - _swig_wrap_delete_Bar(arg1.Swigcptr()) -} - -var _wrap_Bar_x_set unsafe.Pointer - -func _swig_wrap_Bar_x_set(base SwigcptrBar, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Bar_x_set, _swig_p) - return -} - -func (arg1 SwigcptrBar) SetX(arg2 int) { - _swig_wrap_Bar_x_set(arg1, arg2) -} - -var _wrap_Bar_x_get unsafe.Pointer - -func _swig_wrap_Bar_x_get(base SwigcptrBar) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Bar_x_get, _swig_p) - return -} - -func (arg1 SwigcptrBar) GetX() (_swig_ret int) { - return _swig_wrap_Bar_x_get(arg1) -} - -var _wrap_Bar_xp_get unsafe.Pointer - -func _swig_wrap_Bar_xp_get(base SwigcptrBar) (_ *int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Bar_xp_get, _swig_p) - return -} - -func (arg1 SwigcptrBar) GetXp() (_swig_ret *int) { - return _swig_wrap_Bar_xp_get(arg1) -} - -var _wrap_Bar_y_get unsafe.Pointer - -func _swig_wrap_Bar_y_get(base SwigcptrBar) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Bar_y_get, _swig_p) - return -} - -func (arg1 SwigcptrBar) GetY() (_swig_ret int) { - return _swig_wrap_Bar_y_get(arg1) -} - -var _wrap_Bar_yp_set unsafe.Pointer - -func _swig_wrap_Bar_yp_set(base SwigcptrBar, _ *int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Bar_yp_set, _swig_p) - return -} - -func (arg1 SwigcptrBar) SetYp(arg2 *int) { - _swig_wrap_Bar_yp_set(arg1, arg2) -} - -var _wrap_Bar_yp_get unsafe.Pointer - -func _swig_wrap_Bar_yp_get(base SwigcptrBar) (_ *int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Bar_yp_get, _swig_p) - return -} - -func (arg1 SwigcptrBar) GetYp() (_swig_ret *int) { - return _swig_wrap_Bar_yp_get(arg1) -} - -var _wrap_Bar_access_set unsafe.Pointer - -func _swig_wrap_Bar_access_set(base SwigcptrBar, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Bar_access_set, _swig_p) - return -} - -func (arg1 SwigcptrBar) SetAccess(arg2 int) { - _swig_wrap_Bar_access_set(arg1, arg2) -} - -var _wrap_Bar_access_get unsafe.Pointer - -func _swig_wrap_Bar_access_get(base SwigcptrBar) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Bar_access_get, _swig_p) - return -} - -func (arg1 SwigcptrBar) GetAccess() (_swig_ret int) { - return _swig_wrap_Bar_access_get(arg1) -} - -var _wrap_Bar_getx unsafe.Pointer - -func _swig_wrap_Bar_getx(base SwigcptrBar) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Bar_getx, _swig_p) - return -} - -func (arg1 SwigcptrBar) Getx() (_swig_ret int) { - return _swig_wrap_Bar_getx(arg1) -} - -var _wrap_Bar_setx unsafe.Pointer - -func _swig_wrap_Bar_setx(base SwigcptrBar, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Bar_setx, _swig_p) - return -} - -func (arg1 SwigcptrBar) Setx(arg2 int) { - _swig_wrap_Bar_setx(arg1, arg2) -} - -var _wrap_Bar_stat unsafe.Pointer - -func _swig_wrap_Bar_stat(base SwigcptrBar) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Bar_stat, _swig_p) - return -} - -func (arg1 SwigcptrBar) Stat() { - _swig_wrap_Bar_stat(arg1) -} - -var _wrap_Bar_getx2 unsafe.Pointer - -func _swig_wrap_Bar_getx2(base SwigcptrBar) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Bar_getx2, _swig_p) - return -} - -func (arg1 SwigcptrBar) Getx2() (_swig_ret int) { - return _swig_wrap_Bar_getx2(arg1) -} - -var _wrap_Bar_setx2 unsafe.Pointer - -func _swig_wrap_Bar_setx2(base SwigcptrBar, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Bar_setx2, _swig_p) - return -} - -func (arg1 SwigcptrBar) Setx2(arg2 int) { - _swig_wrap_Bar_setx2(arg1, arg2) -} - -type Bar interface { - Swigcptr() uintptr - SwigIsBar() - X__deref__(a ...interface{}) interface{} - SetX(arg2 int) - GetX() (_swig_ret int) - GetXp() (_swig_ret *int) - GetY() (_swig_ret int) - SetYp(arg2 *int) - GetYp() (_swig_ret *int) - SetAccess(arg2 int) - GetAccess() (_swig_ret int) - Getx() (_swig_ret int) - Setx(arg2 int) - Stat() - Getx2() (_swig_ret int) - Setx2(arg2 int) -} - -type SwigcptrBar2 uintptr - -func (p SwigcptrBar2) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrBar2) SwigIsBar2() { -} - -var _wrap_new_Bar2 unsafe.Pointer - -func _swig_wrap_new_Bar2(base uintptr) (_ SwigcptrBar2) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Bar2, _swig_p) - return -} - -func NewBar2(arg1 Foo) (_swig_ret Bar2) { - return _swig_wrap_new_Bar2(arg1.Swigcptr()) -} - -var _wrap_Bar2___deref____SWIG_0 unsafe.Pointer - -func _swig_wrap_Bar2___deref____SWIG_0(base SwigcptrBar2) (_ SwigcptrFoo) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Bar2___deref____SWIG_0, _swig_p) - return -} - -func (arg1 SwigcptrBar2) X__deref____SWIG_0() (_swig_ret Foo) { - return _swig_wrap_Bar2___deref____SWIG_0(arg1) -} - -var _wrap_Bar2___deref____SWIG_1 unsafe.Pointer - -func _swig_wrap_Bar2___deref____SWIG_1(base SwigcptrBar2) (_ SwigcptrFoo) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Bar2___deref____SWIG_1, _swig_p) - return -} - -func (arg1 SwigcptrBar2) X__deref____SWIG_1() (_swig_ret Foo) { - return _swig_wrap_Bar2___deref____SWIG_1(arg1) -} - -func (p SwigcptrBar2) X__deref__(a ...interface{}) interface{} { - argc := len(a) - if argc == 0 { - return p.X__deref____SWIG_0() - } - if argc == 0 { - return p.X__deref____SWIG_1() - } - panic("No match for overloaded function call") -} - -var _wrap_delete_Bar2 unsafe.Pointer - -func _swig_wrap_delete_Bar2(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Bar2, _swig_p) - return -} - -func DeleteBar2(arg1 Bar2) { - _swig_wrap_delete_Bar2(arg1.Swigcptr()) -} - -var _wrap_Bar2_x_set unsafe.Pointer - -func _swig_wrap_Bar2_x_set(base SwigcptrBar2, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Bar2_x_set, _swig_p) - return -} - -func (arg1 SwigcptrBar2) SetX(arg2 int) { - _swig_wrap_Bar2_x_set(arg1, arg2) -} - -var _wrap_Bar2_x_get unsafe.Pointer - -func _swig_wrap_Bar2_x_get(base SwigcptrBar2) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Bar2_x_get, _swig_p) - return -} - -func (arg1 SwigcptrBar2) GetX() (_swig_ret int) { - return _swig_wrap_Bar2_x_get(arg1) -} - -var _wrap_Bar2_xp_get unsafe.Pointer - -func _swig_wrap_Bar2_xp_get(base SwigcptrBar2) (_ *int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Bar2_xp_get, _swig_p) - return -} - -func (arg1 SwigcptrBar2) GetXp() (_swig_ret *int) { - return _swig_wrap_Bar2_xp_get(arg1) -} - -var _wrap_Bar2_y_get unsafe.Pointer - -func _swig_wrap_Bar2_y_get(base SwigcptrBar2) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Bar2_y_get, _swig_p) - return -} - -func (arg1 SwigcptrBar2) GetY() (_swig_ret int) { - return _swig_wrap_Bar2_y_get(arg1) -} - -var _wrap_Bar2_yp_set unsafe.Pointer - -func _swig_wrap_Bar2_yp_set(base SwigcptrBar2, _ *int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Bar2_yp_set, _swig_p) - return -} - -func (arg1 SwigcptrBar2) SetYp(arg2 *int) { - _swig_wrap_Bar2_yp_set(arg1, arg2) -} - -var _wrap_Bar2_yp_get unsafe.Pointer - -func _swig_wrap_Bar2_yp_get(base SwigcptrBar2) (_ *int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Bar2_yp_get, _swig_p) - return -} - -func (arg1 SwigcptrBar2) GetYp() (_swig_ret *int) { - return _swig_wrap_Bar2_yp_get(arg1) -} - -var _wrap_Bar2_access_set unsafe.Pointer - -func _swig_wrap_Bar2_access_set(base SwigcptrBar2, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Bar2_access_set, _swig_p) - return -} - -func (arg1 SwigcptrBar2) SetAccess(arg2 int) { - _swig_wrap_Bar2_access_set(arg1, arg2) -} - -var _wrap_Bar2_access_get unsafe.Pointer - -func _swig_wrap_Bar2_access_get(base SwigcptrBar2) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Bar2_access_get, _swig_p) - return -} - -func (arg1 SwigcptrBar2) GetAccess() (_swig_ret int) { - return _swig_wrap_Bar2_access_get(arg1) -} - -var _wrap_Bar2_getx unsafe.Pointer - -func _swig_wrap_Bar2_getx(base SwigcptrBar2) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Bar2_getx, _swig_p) - return -} - -func (arg1 SwigcptrBar2) Getx() (_swig_ret int) { - return _swig_wrap_Bar2_getx(arg1) -} - -var _wrap_Bar2_setx unsafe.Pointer - -func _swig_wrap_Bar2_setx(base SwigcptrBar2, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Bar2_setx, _swig_p) - return -} - -func (arg1 SwigcptrBar2) Setx(arg2 int) { - _swig_wrap_Bar2_setx(arg1, arg2) -} - -var _wrap_Bar2_stat unsafe.Pointer - -func _swig_wrap_Bar2_stat(base SwigcptrBar2) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Bar2_stat, _swig_p) - return -} - -func (arg1 SwigcptrBar2) Stat() { - _swig_wrap_Bar2_stat(arg1) -} - -var _wrap_Bar2_getx2 unsafe.Pointer - -func _swig_wrap_Bar2_getx2(base SwigcptrBar2) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Bar2_getx2, _swig_p) - return -} - -func (arg1 SwigcptrBar2) Getx2() (_swig_ret int) { - return _swig_wrap_Bar2_getx2(arg1) -} - -var _wrap_Bar2_setx2 unsafe.Pointer - -func _swig_wrap_Bar2_setx2(base SwigcptrBar2, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Bar2_setx2, _swig_p) - return -} - -func (arg1 SwigcptrBar2) Setx2(arg2 int) { - _swig_wrap_Bar2_setx2(arg1, arg2) -} - -type Bar2 interface { - Swigcptr() uintptr - SwigIsBar2() - X__deref__(a ...interface{}) interface{} - SetX(arg2 int) - GetX() (_swig_ret int) - GetXp() (_swig_ret *int) - GetY() (_swig_ret int) - SetYp(arg2 *int) - GetYp() (_swig_ret *int) - SetAccess(arg2 int) - GetAccess() (_swig_ret int) - Getx() (_swig_ret int) - Setx(arg2 int) - Stat() - Getx2() (_swig_ret int) - Setx2(arg2 int) -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/smart_pointer_extend.go b/Examples/test-suite/go/smart_pointer_extend.go deleted file mode 100644 index c42f5afa7..000000000 --- a/Examples/test-suite/go/smart_pointer_extend.go +++ /dev/null @@ -1,1107 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../smart_pointer_extend.i - -package smart_pointer_extend - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrCBase uintptr - -func (p SwigcptrCBase) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrCBase) SwigIsCBase() { -} - -var _wrap_CBase_hello unsafe.Pointer - -func CBaseHello() (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_CBase_hello, _swig_p) - return -} -var _wrap_CBase_x_set unsafe.Pointer - -func _swig_wrap_CBase_x_set(base SwigcptrCBase, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_CBase_x_set, _swig_p) - return -} - -func (arg1 SwigcptrCBase) SetX(arg2 int) { - _swig_wrap_CBase_x_set(arg1, arg2) -} - -var _wrap_CBase_x_get unsafe.Pointer - -func _swig_wrap_CBase_x_get(base SwigcptrCBase) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_CBase_x_get, _swig_p) - return -} - -func (arg1 SwigcptrCBase) GetX() (_swig_ret int) { - return _swig_wrap_CBase_x_get(arg1) -} - -var _wrap_CBase_z_CBase unsafe.Pointer - -func _swig_getCBase_CBase_z_CBase() (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_CBase_z_CBase, _swig_p) - return -} -var CBaseZ int = _swig_getCBase_CBase_z_CBase() -var _wrap_CBase_foo unsafe.Pointer - -func _swig_wrap_CBase_foo(base SwigcptrCBase) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_CBase_foo, _swig_p) - return -} - -func (arg1 SwigcptrCBase) Foo() (_swig_ret int) { - return _swig_wrap_CBase_foo(arg1) -} - -var _wrap_CBase_bar unsafe.Pointer - -func _swig_wrap_CBase_bar(base SwigcptrCBase) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_CBase_bar, _swig_p) - return -} - -func (arg1 SwigcptrCBase) Bar() (_swig_ret int) { - return _swig_wrap_CBase_bar(arg1) -} - -var _wrap_CBase_boo unsafe.Pointer - -func _swig_wrap_CBase_boo(base SwigcptrCBase, _ int) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_CBase_boo, _swig_p) - return -} - -func (arg1 SwigcptrCBase) Boo(arg2 int) (_swig_ret int) { - return _swig_wrap_CBase_boo(arg1, arg2) -} - -var _wrap_new_CBase unsafe.Pointer - -func _swig_wrap_new_CBase() (base SwigcptrCBase) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_CBase, _swig_p) - return -} - -func NewCBase() (_swig_ret CBase) { - return _swig_wrap_new_CBase() -} - -var _wrap_delete_CBase unsafe.Pointer - -func _swig_wrap_delete_CBase(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_CBase, _swig_p) - return -} - -func DeleteCBase(arg1 CBase) { - _swig_wrap_delete_CBase(arg1.Swigcptr()) -} - -type CBase interface { - Swigcptr() uintptr - SwigIsCBase() - SetX(arg2 int) - GetX() (_swig_ret int) - Foo() (_swig_ret int) - Bar() (_swig_ret int) - Boo(arg2 int) (_swig_ret int) -} - -type SwigcptrCDerived uintptr - -func (p SwigcptrCDerived) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrCDerived) SwigIsCDerived() { -} - -var _wrap_CDerived_foo unsafe.Pointer - -func _swig_wrap_CDerived_foo(base SwigcptrCDerived) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_CDerived_foo, _swig_p) - return -} - -func (arg1 SwigcptrCDerived) Foo() (_swig_ret int) { - return _swig_wrap_CDerived_foo(arg1) -} - -var _wrap_new_CDerived unsafe.Pointer - -func _swig_wrap_new_CDerived() (base SwigcptrCDerived) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_CDerived, _swig_p) - return -} - -func NewCDerived() (_swig_ret CDerived) { - return _swig_wrap_new_CDerived() -} - -var _wrap_delete_CDerived unsafe.Pointer - -func _swig_wrap_delete_CDerived(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_CDerived, _swig_p) - return -} - -func DeleteCDerived(arg1 CDerived) { - _swig_wrap_delete_CDerived(arg1.Swigcptr()) -} - -var _wrap_CDerived_hello unsafe.Pointer - -func CDerivedHello() (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_CDerived_hello, _swig_p) - return -} -var _wrap_SetCDerived_X unsafe.Pointer - -func _swig_wrap_SetCDerived_X(base SwigcptrCDerived, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_SetCDerived_X, _swig_p) - return -} - -func (_swig_base SwigcptrCDerived) SetX(arg1 int) { - _swig_wrap_SetCDerived_X(_swig_base, arg1) -} - -var _wrap_GetCDerived_X unsafe.Pointer - -func _swig_wrap_GetCDerived_X(base SwigcptrCDerived) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_GetCDerived_X, _swig_p) - return -} - -func (_swig_base SwigcptrCDerived) GetX() (_swig_ret int) { - return _swig_wrap_GetCDerived_X(_swig_base) -} - -func (p SwigcptrCDerived) SwigIsCBase() { -} - -func (p SwigcptrCDerived) SwigGetCBase() CBase { - return SwigcptrCBase(p.Swigcptr()) -} - -type CDerived interface { - Swigcptr() uintptr - SwigIsCDerived() - Foo() (_swig_ret int) - SetX(arg1 int) - GetX() (_swig_ret int) - SwigIsCBase() - SwigGetCBase() CBase -} - -type SwigcptrCPtr uintptr - -func (p SwigcptrCPtr) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrCPtr) SwigIsCPtr() { -} - -var _wrap_CPtr___deref__ unsafe.Pointer - -func _swig_wrap_CPtr___deref__(base SwigcptrCPtr) (_ SwigcptrCDerived) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_CPtr___deref__, _swig_p) - return -} - -func (arg1 SwigcptrCPtr) X__deref__() (_swig_ret CDerived) { - return _swig_wrap_CPtr___deref__(arg1) -} - -var _wrap_new_CPtr unsafe.Pointer - -func _swig_wrap_new_CPtr() (base SwigcptrCPtr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_CPtr, _swig_p) - return -} - -func NewCPtr() (_swig_ret CPtr) { - return _swig_wrap_new_CPtr() -} - -var _wrap_delete_CPtr unsafe.Pointer - -func _swig_wrap_delete_CPtr(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_CPtr, _swig_p) - return -} - -func DeleteCPtr(arg1 CPtr) { - _swig_wrap_delete_CPtr(arg1.Swigcptr()) -} - -var _wrap_CPtr_foo unsafe.Pointer - -func _swig_wrap_CPtr_foo(base SwigcptrCPtr) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_CPtr_foo, _swig_p) - return -} - -func (arg1 SwigcptrCPtr) Foo() (_swig_ret int) { - return _swig_wrap_CPtr_foo(arg1) -} - -var _wrap_CPtr_hello unsafe.Pointer - -func _swig_wrap_CPtr_hello(base SwigcptrCPtr) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_CPtr_hello, _swig_p) - return -} - -func (arg1 SwigcptrCPtr) Hello() (_swig_ret int) { - return _swig_wrap_CPtr_hello(arg1) -} - -var _wrap_CPtr_x_set unsafe.Pointer - -func _swig_wrap_CPtr_x_set(base SwigcptrCPtr, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_CPtr_x_set, _swig_p) - return -} - -func (arg1 SwigcptrCPtr) SetX(arg2 int) { - _swig_wrap_CPtr_x_set(arg1, arg2) -} - -var _wrap_CPtr_x_get unsafe.Pointer - -func _swig_wrap_CPtr_x_get(base SwigcptrCPtr) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_CPtr_x_get, _swig_p) - return -} - -func (arg1 SwigcptrCPtr) GetX() (_swig_ret int) { - return _swig_wrap_CPtr_x_get(arg1) -} - -var _wrap_CPtr_z_get unsafe.Pointer - -func _swig_wrap_CPtr_z_get(base SwigcptrCPtr) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_CPtr_z_get, _swig_p) - return -} - -func (arg1 SwigcptrCPtr) GetZ() (_swig_ret int) { - return _swig_wrap_CPtr_z_get(arg1) -} - -var _wrap_CPtr_bar unsafe.Pointer - -func _swig_wrap_CPtr_bar(base SwigcptrCPtr) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_CPtr_bar, _swig_p) - return -} - -func (arg1 SwigcptrCPtr) Bar() (_swig_ret int) { - return _swig_wrap_CPtr_bar(arg1) -} - -var _wrap_CPtr_boo unsafe.Pointer - -func _swig_wrap_CPtr_boo(base SwigcptrCPtr, _ int) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_CPtr_boo, _swig_p) - return -} - -func (arg1 SwigcptrCPtr) Boo(arg2 int) (_swig_ret int) { - return _swig_wrap_CPtr_boo(arg1, arg2) -} - -type CPtr interface { - Swigcptr() uintptr - SwigIsCPtr() - X__deref__() (_swig_ret CDerived) - Foo() (_swig_ret int) - Hello() (_swig_ret int) - SetX(arg2 int) - GetX() (_swig_ret int) - GetZ() (_swig_ret int) - Bar() (_swig_ret int) - Boo(arg2 int) (_swig_ret int) -} - -var _wrap_get_hello unsafe.Pointer - -func _swig_wrap_get_hello(base uintptr) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_get_hello, _swig_p) - return -} - -func Get_hello(arg1 CPtr) (_swig_ret int) { - return _swig_wrap_get_hello(arg1.Swigcptr()) -} - -type SwigcptrCPtrConst uintptr - -func (p SwigcptrCPtrConst) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrCPtrConst) SwigIsCPtrConst() { -} - -var _wrap_CPtrConst___deref__ unsafe.Pointer - -func _swig_wrap_CPtrConst___deref__(base SwigcptrCPtrConst) (_ SwigcptrCDerived) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_CPtrConst___deref__, _swig_p) - return -} - -func (arg1 SwigcptrCPtrConst) X__deref__() (_swig_ret CDerived) { - return _swig_wrap_CPtrConst___deref__(arg1) -} - -var _wrap_new_CPtrConst unsafe.Pointer - -func _swig_wrap_new_CPtrConst() (base SwigcptrCPtrConst) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_CPtrConst, _swig_p) - return -} - -func NewCPtrConst() (_swig_ret CPtrConst) { - return _swig_wrap_new_CPtrConst() -} - -var _wrap_delete_CPtrConst unsafe.Pointer - -func _swig_wrap_delete_CPtrConst(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_CPtrConst, _swig_p) - return -} - -func DeleteCPtrConst(arg1 CPtrConst) { - _swig_wrap_delete_CPtrConst(arg1.Swigcptr()) -} - -var _wrap_CPtrConst_x_get unsafe.Pointer - -func _swig_wrap_CPtrConst_x_get(base SwigcptrCPtrConst) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_CPtrConst_x_get, _swig_p) - return -} - -func (arg1 SwigcptrCPtrConst) GetX() (_swig_ret int) { - return _swig_wrap_CPtrConst_x_get(arg1) -} - -var _wrap_CPtrConst_z_get unsafe.Pointer - -func _swig_wrap_CPtrConst_z_get(base SwigcptrCPtrConst) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_CPtrConst_z_get, _swig_p) - return -} - -func (arg1 SwigcptrCPtrConst) GetZ() (_swig_ret int) { - return _swig_wrap_CPtrConst_z_get(arg1) -} - -type CPtrConst interface { - Swigcptr() uintptr - SwigIsCPtrConst() - X__deref__() (_swig_ret CDerived) - GetX() (_swig_ret int) - GetZ() (_swig_ret int) -} - -type SwigcptrFoo uintptr - -func (p SwigcptrFoo) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrFoo) SwigIsFoo() { -} - -var _wrap_Foo_extension__SWIG_0 unsafe.Pointer - -func _swig_wrap_Foo_extension__SWIG_0(base SwigcptrFoo, _ int, _ int) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_extension__SWIG_0, _swig_p) - return -} - -func (arg1 SwigcptrFoo) Extension__SWIG_0(arg2 int, arg3 int) (_swig_ret int) { - return _swig_wrap_Foo_extension__SWIG_0(arg1, arg2, arg3) -} - -var _wrap_Foo_extension__SWIG_1 unsafe.Pointer - -func _swig_wrap_Foo_extension__SWIG_1(base SwigcptrFoo, _ int) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_extension__SWIG_1, _swig_p) - return -} - -func (arg1 SwigcptrFoo) Extension__SWIG_1(arg2 int) (_swig_ret int) { - return _swig_wrap_Foo_extension__SWIG_1(arg1, arg2) -} - -var _wrap_Foo_extension__SWIG_2 unsafe.Pointer - -func _swig_wrap_Foo_extension__SWIG_2(base SwigcptrFoo) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_extension__SWIG_2, _swig_p) - return -} - -func (arg1 SwigcptrFoo) Extension__SWIG_2() (_swig_ret int) { - return _swig_wrap_Foo_extension__SWIG_2(arg1) -} - -func (p SwigcptrFoo) Extension(a ...interface{}) int { - argc := len(a) - if argc == 0 { - return p.Extension__SWIG_2() - } - if argc == 1 { - return p.Extension__SWIG_1(a[0].(int)) - } - if argc == 2 { - return p.Extension__SWIG_0(a[0].(int), a[1].(int)) - } - panic("No match for overloaded function call") -} - -var _wrap_new_Foo unsafe.Pointer - -func _swig_wrap_new_Foo() (base SwigcptrFoo) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Foo, _swig_p) - return -} - -func NewFoo() (_swig_ret Foo) { - return _swig_wrap_new_Foo() -} - -var _wrap_delete_Foo unsafe.Pointer - -func _swig_wrap_delete_Foo(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Foo, _swig_p) - return -} - -func DeleteFoo(arg1 Foo) { - _swig_wrap_delete_Foo(arg1.Swigcptr()) -} - -type Foo interface { - Swigcptr() uintptr - SwigIsFoo() - Extension(a ...interface{}) int -} - -type SwigcptrBar uintptr - -func (p SwigcptrBar) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrBar) SwigIsBar() { -} - -var _wrap_new_Bar unsafe.Pointer - -func _swig_wrap_new_Bar(base uintptr) (_ SwigcptrBar) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Bar, _swig_p) - return -} - -func NewBar(arg1 Foo) (_swig_ret Bar) { - return _swig_wrap_new_Bar(arg1.Swigcptr()) -} - -var _wrap_Bar___deref__ unsafe.Pointer - -func _swig_wrap_Bar___deref__(base SwigcptrBar) (_ SwigcptrFoo) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Bar___deref__, _swig_p) - return -} - -func (arg1 SwigcptrBar) X__deref__() (_swig_ret Foo) { - return _swig_wrap_Bar___deref__(arg1) -} - -var _wrap_delete_Bar unsafe.Pointer - -func _swig_wrap_delete_Bar(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Bar, _swig_p) - return -} - -func DeleteBar(arg1 Bar) { - _swig_wrap_delete_Bar(arg1.Swigcptr()) -} - -var _wrap_Bar_extension__SWIG_0 unsafe.Pointer - -func _swig_wrap_Bar_extension__SWIG_0(base SwigcptrBar, _ int, _ int) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Bar_extension__SWIG_0, _swig_p) - return -} - -func (arg1 SwigcptrBar) Extension__SWIG_0(arg2 int, arg3 int) (_swig_ret int) { - return _swig_wrap_Bar_extension__SWIG_0(arg1, arg2, arg3) -} - -var _wrap_Bar_extension__SWIG_1 unsafe.Pointer - -func _swig_wrap_Bar_extension__SWIG_1(base SwigcptrBar, _ int) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Bar_extension__SWIG_1, _swig_p) - return -} - -func (arg1 SwigcptrBar) Extension__SWIG_1(arg2 int) (_swig_ret int) { - return _swig_wrap_Bar_extension__SWIG_1(arg1, arg2) -} - -var _wrap_Bar_extension__SWIG_2 unsafe.Pointer - -func _swig_wrap_Bar_extension__SWIG_2(base SwigcptrBar) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Bar_extension__SWIG_2, _swig_p) - return -} - -func (arg1 SwigcptrBar) Extension__SWIG_2() (_swig_ret int) { - return _swig_wrap_Bar_extension__SWIG_2(arg1) -} - -func (p SwigcptrBar) Extension(a ...interface{}) int { - argc := len(a) - if argc == 0 { - return p.Extension__SWIG_2() - } - if argc == 1 { - return p.Extension__SWIG_1(a[0].(int)) - } - if argc == 2 { - return p.Extension__SWIG_0(a[0].(int), a[1].(int)) - } - panic("No match for overloaded function call") -} - -type Bar interface { - Swigcptr() uintptr - SwigIsBar() - X__deref__() (_swig_ret Foo) - Extension(a ...interface{}) int -} - -type SwigcptrCFoo uintptr - -func (p SwigcptrCFoo) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrCFoo) SwigIsCFoo() { -} - -var _wrap_CFoo_StatFun__SWIG_0 unsafe.Pointer - -func _swig_wrap_CFoo_StatFun__SWIG_0() { - var _swig_p uintptr - _cgo_runtime_cgocall(_wrap_CFoo_StatFun__SWIG_0, _swig_p) - return -} - -func CFooStatFun__SWIG_0() { - _swig_wrap_CFoo_StatFun__SWIG_0() -} - -var _wrap_CFoo_StatFun__SWIG_1 unsafe.Pointer - -func _swig_wrap_CFoo_StatFun__SWIG_1(base int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_CFoo_StatFun__SWIG_1, _swig_p) - return -} - -func CFooStatFun__SWIG_1(arg1 int) { - _swig_wrap_CFoo_StatFun__SWIG_1(arg1) -} - -func CFooStatFun(a ...interface{}) { - argc := len(a) - if argc == 0 { - CFooStatFun__SWIG_0() - return - } - if argc == 1 { - CFooStatFun__SWIG_1(a[0].(int)) - return - } - panic("No match for overloaded function call") -} - -var _wrap_CFoo_HoHoHo unsafe.Pointer - -func _swig_wrap_CFoo_HoHoHo(base int, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_CFoo_HoHoHo, _swig_p) - return -} - -func CFooHoHoHo(arg1 int, arg2 int) { - _swig_wrap_CFoo_HoHoHo(arg1, arg2) -} - -var _wrap_new_CFoo unsafe.Pointer - -func _swig_wrap_new_CFoo() (base SwigcptrCFoo) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_CFoo, _swig_p) - return -} - -func NewCFoo() (_swig_ret CFoo) { - return _swig_wrap_new_CFoo() -} - -var _wrap_delete_CFoo unsafe.Pointer - -func _swig_wrap_delete_CFoo(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_CFoo, _swig_p) - return -} - -func DeleteCFoo(arg1 CFoo) { - _swig_wrap_delete_CFoo(arg1.Swigcptr()) -} - -type CFoo interface { - Swigcptr() uintptr - SwigIsCFoo() -} - -type SwigcptrCPtrFoo uintptr - -func (p SwigcptrCPtrFoo) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrCPtrFoo) SwigIsCPtrFoo() { -} - -var _wrap_CPtrFoo___deref__ unsafe.Pointer - -func _swig_wrap_CPtrFoo___deref__(base SwigcptrCPtrFoo) (_ SwigcptrCFoo) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_CPtrFoo___deref__, _swig_p) - return -} - -func (arg1 SwigcptrCPtrFoo) X__deref__() (_swig_ret CFoo) { - return _swig_wrap_CPtrFoo___deref__(arg1) -} - -var _wrap_new_CPtrFoo unsafe.Pointer - -func _swig_wrap_new_CPtrFoo() (base SwigcptrCPtrFoo) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_CPtrFoo, _swig_p) - return -} - -func NewCPtrFoo() (_swig_ret CPtrFoo) { - return _swig_wrap_new_CPtrFoo() -} - -var _wrap_delete_CPtrFoo unsafe.Pointer - -func _swig_wrap_delete_CPtrFoo(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_CPtrFoo, _swig_p) - return -} - -func DeleteCPtrFoo(arg1 CPtrFoo) { - _swig_wrap_delete_CPtrFoo(arg1.Swigcptr()) -} - -var _wrap_CPtrFoo_StatFun__SWIG_0 unsafe.Pointer - -func _swig_wrap_CPtrFoo_StatFun__SWIG_0(base SwigcptrCPtrFoo) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_CPtrFoo_StatFun__SWIG_0, _swig_p) - return -} - -func (arg1 SwigcptrCPtrFoo) StatFun__SWIG_0() { - _swig_wrap_CPtrFoo_StatFun__SWIG_0(arg1) -} - -var _wrap_CPtrFoo_StatFun__SWIG_1 unsafe.Pointer - -func _swig_wrap_CPtrFoo_StatFun__SWIG_1(base SwigcptrCPtrFoo, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_CPtrFoo_StatFun__SWIG_1, _swig_p) - return -} - -func (arg1 SwigcptrCPtrFoo) StatFun__SWIG_1(arg2 int) { - _swig_wrap_CPtrFoo_StatFun__SWIG_1(arg1, arg2) -} - -func (p SwigcptrCPtrFoo) StatFun(a ...interface{}) { - argc := len(a) - if argc == 0 { - p.StatFun__SWIG_0() - return - } - if argc == 1 { - p.StatFun__SWIG_1(a[0].(int)) - return - } - panic("No match for overloaded function call") -} - -var _wrap_CPtrFoo_HoHoHo unsafe.Pointer - -func _swig_wrap_CPtrFoo_HoHoHo(base SwigcptrCPtrFoo, _ int, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_CPtrFoo_HoHoHo, _swig_p) - return -} - -func (arg1 SwigcptrCPtrFoo) HoHoHo(arg2 int, arg3 int) { - _swig_wrap_CPtrFoo_HoHoHo(arg1, arg2, arg3) -} - -type CPtrFoo interface { - Swigcptr() uintptr - SwigIsCPtrFoo() - X__deref__() (_swig_ret CFoo) - StatFun(a ...interface{}) - HoHoHo(arg2 int, arg3 int) -} - -type SwigcptrDPtrFoo uintptr - -func (p SwigcptrDPtrFoo) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrDPtrFoo) SwigIsDPtrFoo() { -} - -var _wrap_new_DPtrFoo unsafe.Pointer - -func _swig_wrap_new_DPtrFoo(base uintptr) (_ SwigcptrDPtrFoo) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_DPtrFoo, _swig_p) - return -} - -func NewDPtrFoo(arg1 DFoo) (_swig_ret DPtrFoo) { - return _swig_wrap_new_DPtrFoo(arg1.Swigcptr()) -} - -var _wrap_DPtrFoo___deref__ unsafe.Pointer - -func _swig_wrap_DPtrFoo___deref__(base SwigcptrDPtrFoo) (_ SwigcptrDFoo) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_DPtrFoo___deref__, _swig_p) - return -} - -func (arg1 SwigcptrDPtrFoo) X__deref__() (_swig_ret DFoo) { - return _swig_wrap_DPtrFoo___deref__(arg1) -} - -var _wrap_delete_DPtrFoo unsafe.Pointer - -func _swig_wrap_delete_DPtrFoo(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_DPtrFoo, _swig_p) - return -} - -func DeleteDPtrFoo(arg1 DPtrFoo) { - _swig_wrap_delete_DPtrFoo(arg1.Swigcptr()) -} - -var _wrap_DPtrFoo_F unsafe.Pointer - -func _swig_wrap_DPtrFoo_F(base SwigcptrDPtrFoo) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_DPtrFoo_F, _swig_p) - return -} - -func (arg1 SwigcptrDPtrFoo) F() { - _swig_wrap_DPtrFoo_F(arg1) -} - -var _wrap_DPtrFoo_SExt__SWIG_0 unsafe.Pointer - -func _swig_wrap_DPtrFoo_SExt__SWIG_0(base SwigcptrDPtrFoo, _ int) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_DPtrFoo_SExt__SWIG_0, _swig_p) - return -} - -func (arg1 SwigcptrDPtrFoo) SExt__SWIG_0(arg2 int) (_swig_ret int) { - return _swig_wrap_DPtrFoo_SExt__SWIG_0(arg1, arg2) -} - -var _wrap_DPtrFoo_SExt__SWIG_1 unsafe.Pointer - -func _swig_wrap_DPtrFoo_SExt__SWIG_1(base SwigcptrDPtrFoo) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_DPtrFoo_SExt__SWIG_1, _swig_p) - return -} - -func (arg1 SwigcptrDPtrFoo) SExt__SWIG_1() (_swig_ret int) { - return _swig_wrap_DPtrFoo_SExt__SWIG_1(arg1) -} - -func (p SwigcptrDPtrFoo) SExt(a ...interface{}) int { - argc := len(a) - if argc == 0 { - return p.SExt__SWIG_1() - } - if argc == 1 { - return p.SExt__SWIG_0(a[0].(int)) - } - panic("No match for overloaded function call") -} - -var _wrap_DPtrFoo_Ext__SWIG_0 unsafe.Pointer - -func _swig_wrap_DPtrFoo_Ext__SWIG_0(base SwigcptrDPtrFoo, _ int) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_DPtrFoo_Ext__SWIG_0, _swig_p) - return -} - -func (arg1 SwigcptrDPtrFoo) Ext__SWIG_0(arg2 int) (_swig_ret int) { - return _swig_wrap_DPtrFoo_Ext__SWIG_0(arg1, arg2) -} - -var _wrap_DPtrFoo_Ext__SWIG_1 unsafe.Pointer - -func _swig_wrap_DPtrFoo_Ext__SWIG_1(base SwigcptrDPtrFoo) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_DPtrFoo_Ext__SWIG_1, _swig_p) - return -} - -func (arg1 SwigcptrDPtrFoo) Ext__SWIG_1() (_swig_ret int) { - return _swig_wrap_DPtrFoo_Ext__SWIG_1(arg1) -} - -func (p SwigcptrDPtrFoo) Ext(a ...interface{}) int { - argc := len(a) - if argc == 0 { - return p.Ext__SWIG_1() - } - if argc == 1 { - return p.Ext__SWIG_0(a[0].(int)) - } - panic("No match for overloaded function call") -} - -type DPtrFoo interface { - Swigcptr() uintptr - SwigIsDPtrFoo() - X__deref__() (_swig_ret DFoo) - F() - SExt(a ...interface{}) int - Ext(a ...interface{}) int -} - -type SwigcptrDFoo uintptr - -func (p SwigcptrDFoo) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrDFoo) SwigIsDFoo() { -} - -var _wrap_DFoo_F unsafe.Pointer - -func _swig_wrap_DFoo_F(base SwigcptrDFoo) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_DFoo_F, _swig_p) - return -} - -func (arg1 SwigcptrDFoo) F() { - _swig_wrap_DFoo_F(arg1) -} - -var _wrap_DFoo_SExt__SWIG_0 unsafe.Pointer - -func DFooSExt__SWIG_0(arg1 int) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_DFoo_SExt__SWIG_0, _swig_p) - return -} -var _wrap_DFoo_SExt__SWIG_1 unsafe.Pointer - -func DFooSExt__SWIG_1() (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_DFoo_SExt__SWIG_1, _swig_p) - return -} -func DFooSExt(a ...interface{}) int { - argc := len(a) - if argc == 0 { - return DFooSExt__SWIG_1() - } - if argc == 1 { - return DFooSExt__SWIG_0(a[0].(int)) - } - panic("No match for overloaded function call") -} - -var _wrap_DFoo_Ext__SWIG_0 unsafe.Pointer - -func _swig_wrap_DFoo_Ext__SWIG_0(base SwigcptrDFoo, _ int) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_DFoo_Ext__SWIG_0, _swig_p) - return -} - -func (arg1 SwigcptrDFoo) Ext__SWIG_0(arg2 int) (_swig_ret int) { - return _swig_wrap_DFoo_Ext__SWIG_0(arg1, arg2) -} - -var _wrap_DFoo_Ext__SWIG_1 unsafe.Pointer - -func _swig_wrap_DFoo_Ext__SWIG_1(base SwigcptrDFoo) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_DFoo_Ext__SWIG_1, _swig_p) - return -} - -func (arg1 SwigcptrDFoo) Ext__SWIG_1() (_swig_ret int) { - return _swig_wrap_DFoo_Ext__SWIG_1(arg1) -} - -func (p SwigcptrDFoo) Ext(a ...interface{}) int { - argc := len(a) - if argc == 0 { - return p.Ext__SWIG_1() - } - if argc == 1 { - return p.Ext__SWIG_0(a[0].(int)) - } - panic("No match for overloaded function call") -} - -var _wrap_new_DFoo unsafe.Pointer - -func _swig_wrap_new_DFoo() (base SwigcptrDFoo) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_DFoo, _swig_p) - return -} - -func NewDFoo() (_swig_ret DFoo) { - return _swig_wrap_new_DFoo() -} - -var _wrap_delete_DFoo unsafe.Pointer - -func _swig_wrap_delete_DFoo(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_DFoo, _swig_p) - return -} - -func DeleteDFoo(arg1 DFoo) { - _swig_wrap_delete_DFoo(arg1.Swigcptr()) -} - -type DFoo interface { - Swigcptr() uintptr - SwigIsDFoo() - F() - Ext(a ...interface{}) int -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/smart_pointer_extend_runme b/Examples/test-suite/go/smart_pointer_extend_runme deleted file mode 100755 index 120c1d3ba..000000000 Binary files a/Examples/test-suite/go/smart_pointer_extend_runme and /dev/null differ diff --git a/Examples/test-suite/go/smart_pointer_inherit.go b/Examples/test-suite/go/smart_pointer_inherit.go deleted file mode 100644 index f58dba6b0..000000000 --- a/Examples/test-suite/go/smart_pointer_inherit.go +++ /dev/null @@ -1,1007 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../smart_pointer_inherit.i - -package smart_pointer_inherit - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrBase uintptr - -func (p SwigcptrBase) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrBase) SwigIsBase() { -} - -var _wrap_delete_Base unsafe.Pointer - -func _swig_wrap_delete_Base(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Base, _swig_p) - return -} - -func DeleteBase(arg1 Base) { - _swig_wrap_delete_Base(arg1.Swigcptr()) -} - -var _wrap_Base_value unsafe.Pointer - -func _swig_wrap_Base_value(base SwigcptrBase) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Base_value, _swig_p) - return -} - -func (arg1 SwigcptrBase) Value() (_swig_ret int) { - return _swig_wrap_Base_value(arg1) -} - -var _wrap_Base_value2 unsafe.Pointer - -func _swig_wrap_Base_value2(base SwigcptrBase) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Base_value2, _swig_p) - return -} - -func (arg1 SwigcptrBase) Value2() (_swig_ret int) { - return _swig_wrap_Base_value2(arg1) -} - -var _wrap_Base_value3 unsafe.Pointer - -func _swig_wrap_Base_value3(base SwigcptrBase) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Base_value3, _swig_p) - return -} - -func (arg1 SwigcptrBase) Value3() (_swig_ret int) { - return _swig_wrap_Base_value3(arg1) -} - -var _wrap_Base_valuehide unsafe.Pointer - -func _swig_wrap_Base_valuehide(base SwigcptrBase) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Base_valuehide, _swig_p) - return -} - -func (arg1 SwigcptrBase) Valuehide() (_swig_ret int) { - return _swig_wrap_Base_valuehide(arg1) -} - -var _wrap_Base_val_set unsafe.Pointer - -func _swig_wrap_Base_val_set(base SwigcptrBase, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Base_val_set, _swig_p) - return -} - -func (arg1 SwigcptrBase) SetVal(arg2 int) { - _swig_wrap_Base_val_set(arg1, arg2) -} - -var _wrap_Base_val_get unsafe.Pointer - -func _swig_wrap_Base_val_get(base SwigcptrBase) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Base_val_get, _swig_p) - return -} - -func (arg1 SwigcptrBase) GetVal() (_swig_ret int) { - return _swig_wrap_Base_val_get(arg1) -} - -type Base interface { - Swigcptr() uintptr - SwigIsBase() - Value() (_swig_ret int) - Value2() (_swig_ret int) - Value3() (_swig_ret int) - Valuehide() (_swig_ret int) - SetVal(arg2 int) - GetVal() (_swig_ret int) -} - -type SwigcptrDerived uintptr - -func (p SwigcptrDerived) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrDerived) SwigIsDerived() { -} - -var _wrap_new_Derived unsafe.Pointer - -func _swig_wrap_new_Derived(base int) (_ SwigcptrDerived) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Derived, _swig_p) - return -} - -func NewDerived(arg1 int) (_swig_ret Derived) { - return _swig_wrap_new_Derived(arg1) -} - -var _wrap_Derived_value unsafe.Pointer - -func _swig_wrap_Derived_value(base SwigcptrDerived) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Derived_value, _swig_p) - return -} - -func (arg1 SwigcptrDerived) Value() (_swig_ret int) { - return _swig_wrap_Derived_value(arg1) -} - -var _wrap_Derived_value3 unsafe.Pointer - -func _swig_wrap_Derived_value3(base SwigcptrDerived) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Derived_value3, _swig_p) - return -} - -func (arg1 SwigcptrDerived) Value3() (_swig_ret int) { - return _swig_wrap_Derived_value3(arg1) -} - -var _wrap_Derived_valuehide unsafe.Pointer - -func _swig_wrap_Derived_valuehide(base SwigcptrDerived) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Derived_valuehide, _swig_p) - return -} - -func (arg1 SwigcptrDerived) Valuehide() (_swig_ret int) { - return _swig_wrap_Derived_valuehide(arg1) -} - -var _wrap_delete_Derived unsafe.Pointer - -func _swig_wrap_delete_Derived(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Derived, _swig_p) - return -} - -func DeleteDerived(arg1 Derived) { - _swig_wrap_delete_Derived(arg1.Swigcptr()) -} - -var _wrap_Derived_value2 unsafe.Pointer - -func _swig_wrap_Derived_value2(base SwigcptrDerived) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Derived_value2, _swig_p) - return -} - -func (_swig_base SwigcptrDerived) Value2() (_swig_ret int) { - return _swig_wrap_Derived_value2(_swig_base) -} - -var _wrap_SetDerived_Val unsafe.Pointer - -func _swig_wrap_SetDerived_Val(base SwigcptrDerived, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_SetDerived_Val, _swig_p) - return -} - -func (_swig_base SwigcptrDerived) SetVal(arg1 int) { - _swig_wrap_SetDerived_Val(_swig_base, arg1) -} - -var _wrap_GetDerived_Val unsafe.Pointer - -func _swig_wrap_GetDerived_Val(base SwigcptrDerived) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_GetDerived_Val, _swig_p) - return -} - -func (_swig_base SwigcptrDerived) GetVal() (_swig_ret int) { - return _swig_wrap_GetDerived_Val(_swig_base) -} - -func (p SwigcptrDerived) SwigIsBase() { -} - -func (p SwigcptrDerived) SwigGetBase() Base { - return SwigcptrBase(p.Swigcptr()) -} - -type Derived interface { - Swigcptr() uintptr - SwigIsDerived() - Value() (_swig_ret int) - Value3() (_swig_ret int) - Valuehide() (_swig_ret int) - Value2() (_swig_ret int) - SetVal(arg1 int) - GetVal() (_swig_ret int) - SwigIsBase() - SwigGetBase() Base -} - -type SwigcptrSmartBase uintptr - -func (p SwigcptrSmartBase) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrSmartBase) SwigIsSmartBase() { -} - -var _wrap_new_SmartBase unsafe.Pointer - -func _swig_wrap_new_SmartBase(base uintptr) (_ SwigcptrSmartBase) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_SmartBase, _swig_p) - return -} - -func NewSmartBase(arg1 Base) (_swig_ret SmartBase) { - return _swig_wrap_new_SmartBase(arg1.Swigcptr()) -} - -var _wrap_SmartBase___deref__ unsafe.Pointer - -func _swig_wrap_SmartBase___deref__(base SwigcptrSmartBase) (_ SwigcptrBase) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_SmartBase___deref__, _swig_p) - return -} - -func (arg1 SwigcptrSmartBase) X__deref__() (_swig_ret Base) { - return _swig_wrap_SmartBase___deref__(arg1) -} - -var _wrap_delete_SmartBase unsafe.Pointer - -func _swig_wrap_delete_SmartBase(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_SmartBase, _swig_p) - return -} - -func DeleteSmartBase(arg1 SmartBase) { - _swig_wrap_delete_SmartBase(arg1.Swigcptr()) -} - -var _wrap_SmartBase_value unsafe.Pointer - -func _swig_wrap_SmartBase_value(base SwigcptrSmartBase) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_SmartBase_value, _swig_p) - return -} - -func (arg1 SwigcptrSmartBase) Value() (_swig_ret int) { - return _swig_wrap_SmartBase_value(arg1) -} - -var _wrap_SmartBase_value2 unsafe.Pointer - -func _swig_wrap_SmartBase_value2(base SwigcptrSmartBase) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_SmartBase_value2, _swig_p) - return -} - -func (arg1 SwigcptrSmartBase) Value2() (_swig_ret int) { - return _swig_wrap_SmartBase_value2(arg1) -} - -var _wrap_SmartBase_value3 unsafe.Pointer - -func _swig_wrap_SmartBase_value3(base SwigcptrSmartBase) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_SmartBase_value3, _swig_p) - return -} - -func (arg1 SwigcptrSmartBase) Value3() (_swig_ret int) { - return _swig_wrap_SmartBase_value3(arg1) -} - -var _wrap_SmartBase_valuehide unsafe.Pointer - -func _swig_wrap_SmartBase_valuehide(base SwigcptrSmartBase) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_SmartBase_valuehide, _swig_p) - return -} - -func (arg1 SwigcptrSmartBase) Valuehide() (_swig_ret int) { - return _swig_wrap_SmartBase_valuehide(arg1) -} - -var _wrap_SmartBase_val_set unsafe.Pointer - -func _swig_wrap_SmartBase_val_set(base SwigcptrSmartBase, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_SmartBase_val_set, _swig_p) - return -} - -func (arg1 SwigcptrSmartBase) SetVal(arg2 int) { - _swig_wrap_SmartBase_val_set(arg1, arg2) -} - -var _wrap_SmartBase_val_get unsafe.Pointer - -func _swig_wrap_SmartBase_val_get(base SwigcptrSmartBase) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_SmartBase_val_get, _swig_p) - return -} - -func (arg1 SwigcptrSmartBase) GetVal() (_swig_ret int) { - return _swig_wrap_SmartBase_val_get(arg1) -} - -type SmartBase interface { - Swigcptr() uintptr - SwigIsSmartBase() - X__deref__() (_swig_ret Base) - Value() (_swig_ret int) - Value2() (_swig_ret int) - Value3() (_swig_ret int) - Valuehide() (_swig_ret int) - SetVal(arg2 int) - GetVal() (_swig_ret int) -} - -type SwigcptrSmartDerived uintptr - -func (p SwigcptrSmartDerived) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrSmartDerived) SwigIsSmartDerived() { -} - -var _wrap_new_SmartDerived unsafe.Pointer - -func _swig_wrap_new_SmartDerived(base uintptr) (_ SwigcptrSmartDerived) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_SmartDerived, _swig_p) - return -} - -func NewSmartDerived(arg1 Derived) (_swig_ret SmartDerived) { - return _swig_wrap_new_SmartDerived(arg1.Swigcptr()) -} - -var _wrap_SmartDerived___deref__ unsafe.Pointer - -func _swig_wrap_SmartDerived___deref__(base SwigcptrSmartDerived) (_ SwigcptrDerived) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_SmartDerived___deref__, _swig_p) - return -} - -func (arg1 SwigcptrSmartDerived) X__deref__() (_swig_ret Derived) { - return _swig_wrap_SmartDerived___deref__(arg1) -} - -var _wrap_delete_SmartDerived unsafe.Pointer - -func _swig_wrap_delete_SmartDerived(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_SmartDerived, _swig_p) - return -} - -func DeleteSmartDerived(arg1 SmartDerived) { - _swig_wrap_delete_SmartDerived(arg1.Swigcptr()) -} - -var _wrap_SmartDerived_value unsafe.Pointer - -func _swig_wrap_SmartDerived_value(base SwigcptrSmartDerived) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_SmartDerived_value, _swig_p) - return -} - -func (arg1 SwigcptrSmartDerived) Value() (_swig_ret int) { - return _swig_wrap_SmartDerived_value(arg1) -} - -var _wrap_SmartDerived_value3 unsafe.Pointer - -func _swig_wrap_SmartDerived_value3(base SwigcptrSmartDerived) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_SmartDerived_value3, _swig_p) - return -} - -func (arg1 SwigcptrSmartDerived) Value3() (_swig_ret int) { - return _swig_wrap_SmartDerived_value3(arg1) -} - -var _wrap_SmartDerived_valuehide unsafe.Pointer - -func _swig_wrap_SmartDerived_valuehide(base SwigcptrSmartDerived) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_SmartDerived_valuehide, _swig_p) - return -} - -func (arg1 SwigcptrSmartDerived) Valuehide() (_swig_ret int) { - return _swig_wrap_SmartDerived_valuehide(arg1) -} - -var _wrap_SmartDerived_value2 unsafe.Pointer - -func _swig_wrap_SmartDerived_value2(base SwigcptrSmartDerived) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_SmartDerived_value2, _swig_p) - return -} - -func (arg1 SwigcptrSmartDerived) Value2() (_swig_ret int) { - return _swig_wrap_SmartDerived_value2(arg1) -} - -var _wrap_SmartDerived_val_set unsafe.Pointer - -func _swig_wrap_SmartDerived_val_set(base SwigcptrSmartDerived, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_SmartDerived_val_set, _swig_p) - return -} - -func (arg1 SwigcptrSmartDerived) SetVal(arg2 int) { - _swig_wrap_SmartDerived_val_set(arg1, arg2) -} - -var _wrap_SmartDerived_val_get unsafe.Pointer - -func _swig_wrap_SmartDerived_val_get(base SwigcptrSmartDerived) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_SmartDerived_val_get, _swig_p) - return -} - -func (arg1 SwigcptrSmartDerived) GetVal() (_swig_ret int) { - return _swig_wrap_SmartDerived_val_get(arg1) -} - -type SmartDerived interface { - Swigcptr() uintptr - SwigIsSmartDerived() - X__deref__() (_swig_ret Derived) - Value() (_swig_ret int) - Value3() (_swig_ret int) - Valuehide() (_swig_ret int) - Value2() (_swig_ret int) - SetVal(arg2 int) - GetVal() (_swig_ret int) -} - -type SwigcptrItkLevelSetNodeUS2 uintptr - -func (p SwigcptrItkLevelSetNodeUS2) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrItkLevelSetNodeUS2) SwigIsItkLevelSetNodeUS2() { -} - -var _wrap_new_ItkLevelSetNodeUS2 unsafe.Pointer - -func _swig_wrap_new_ItkLevelSetNodeUS2() (base SwigcptrItkLevelSetNodeUS2) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_ItkLevelSetNodeUS2, _swig_p) - return -} - -func NewItkLevelSetNodeUS2() (_swig_ret ItkLevelSetNodeUS2) { - return _swig_wrap_new_ItkLevelSetNodeUS2() -} - -var _wrap_delete_ItkLevelSetNodeUS2 unsafe.Pointer - -func _swig_wrap_delete_ItkLevelSetNodeUS2(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_ItkLevelSetNodeUS2, _swig_p) - return -} - -func DeleteItkLevelSetNodeUS2(arg1 ItkLevelSetNodeUS2) { - _swig_wrap_delete_ItkLevelSetNodeUS2(arg1.Swigcptr()) -} - -type ItkLevelSetNodeUS2 interface { - Swigcptr() uintptr - SwigIsItkLevelSetNodeUS2() -} - -type SwigcptrVectorLevelSetNodeUS2 uintptr - -func (p SwigcptrVectorLevelSetNodeUS2) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrVectorLevelSetNodeUS2) SwigIsVectorLevelSetNodeUS2() { -} - -var _wrap_new_VectorLevelSetNodeUS2__SWIG_0 unsafe.Pointer - -func _swig_wrap_new_VectorLevelSetNodeUS2__SWIG_0() (base SwigcptrVectorLevelSetNodeUS2) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_VectorLevelSetNodeUS2__SWIG_0, _swig_p) - return -} - -func NewVectorLevelSetNodeUS2__SWIG_0() (_swig_ret VectorLevelSetNodeUS2) { - return _swig_wrap_new_VectorLevelSetNodeUS2__SWIG_0() -} - -var _wrap_new_VectorLevelSetNodeUS2__SWIG_1 unsafe.Pointer - -func _swig_wrap_new_VectorLevelSetNodeUS2__SWIG_1(base int64) (_ SwigcptrVectorLevelSetNodeUS2) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_VectorLevelSetNodeUS2__SWIG_1, _swig_p) - return -} - -func NewVectorLevelSetNodeUS2__SWIG_1(arg1 int64) (_swig_ret VectorLevelSetNodeUS2) { - return _swig_wrap_new_VectorLevelSetNodeUS2__SWIG_1(arg1) -} - -func NewVectorLevelSetNodeUS2(a ...interface{}) VectorLevelSetNodeUS2 { - argc := len(a) - if argc == 0 { - return NewVectorLevelSetNodeUS2__SWIG_0() - } - if argc == 1 { - return NewVectorLevelSetNodeUS2__SWIG_1(a[0].(int64)) - } - panic("No match for overloaded function call") -} - -var _wrap_VectorLevelSetNodeUS2_size unsafe.Pointer - -func _swig_wrap_VectorLevelSetNodeUS2_size(base SwigcptrVectorLevelSetNodeUS2) (_ int64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_VectorLevelSetNodeUS2_size, _swig_p) - return -} - -func (arg1 SwigcptrVectorLevelSetNodeUS2) Size() (_swig_ret int64) { - return _swig_wrap_VectorLevelSetNodeUS2_size(arg1) -} - -var _wrap_VectorLevelSetNodeUS2_capacity unsafe.Pointer - -func _swig_wrap_VectorLevelSetNodeUS2_capacity(base SwigcptrVectorLevelSetNodeUS2) (_ int64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_VectorLevelSetNodeUS2_capacity, _swig_p) - return -} - -func (arg1 SwigcptrVectorLevelSetNodeUS2) Capacity() (_swig_ret int64) { - return _swig_wrap_VectorLevelSetNodeUS2_capacity(arg1) -} - -var _wrap_VectorLevelSetNodeUS2_reserve unsafe.Pointer - -func _swig_wrap_VectorLevelSetNodeUS2_reserve(base SwigcptrVectorLevelSetNodeUS2, _ int64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_VectorLevelSetNodeUS2_reserve, _swig_p) - return -} - -func (arg1 SwigcptrVectorLevelSetNodeUS2) Reserve(arg2 int64) { - _swig_wrap_VectorLevelSetNodeUS2_reserve(arg1, arg2) -} - -var _wrap_VectorLevelSetNodeUS2_isEmpty unsafe.Pointer - -func _swig_wrap_VectorLevelSetNodeUS2_isEmpty(base SwigcptrVectorLevelSetNodeUS2) (_ bool) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_VectorLevelSetNodeUS2_isEmpty, _swig_p) - return -} - -func (arg1 SwigcptrVectorLevelSetNodeUS2) IsEmpty() (_swig_ret bool) { - return _swig_wrap_VectorLevelSetNodeUS2_isEmpty(arg1) -} - -var _wrap_VectorLevelSetNodeUS2_clear unsafe.Pointer - -func _swig_wrap_VectorLevelSetNodeUS2_clear(base SwigcptrVectorLevelSetNodeUS2) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_VectorLevelSetNodeUS2_clear, _swig_p) - return -} - -func (arg1 SwigcptrVectorLevelSetNodeUS2) Clear() { - _swig_wrap_VectorLevelSetNodeUS2_clear(arg1) -} - -var _wrap_VectorLevelSetNodeUS2_add unsafe.Pointer - -func _swig_wrap_VectorLevelSetNodeUS2_add(base SwigcptrVectorLevelSetNodeUS2, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_VectorLevelSetNodeUS2_add, _swig_p) - return -} - -func (arg1 SwigcptrVectorLevelSetNodeUS2) Add(arg2 ItkLevelSetNodeUS2) { - _swig_wrap_VectorLevelSetNodeUS2_add(arg1, arg2.Swigcptr()) -} - -var _wrap_VectorLevelSetNodeUS2_get unsafe.Pointer - -func _swig_wrap_VectorLevelSetNodeUS2_get(base SwigcptrVectorLevelSetNodeUS2, _ int) (_ SwigcptrItkLevelSetNodeUS2) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_VectorLevelSetNodeUS2_get, _swig_p) - return -} - -func (arg1 SwigcptrVectorLevelSetNodeUS2) Get(arg2 int) (_swig_ret ItkLevelSetNodeUS2) { - return _swig_wrap_VectorLevelSetNodeUS2_get(arg1, arg2) -} - -var _wrap_VectorLevelSetNodeUS2_set unsafe.Pointer - -func _swig_wrap_VectorLevelSetNodeUS2_set(base SwigcptrVectorLevelSetNodeUS2, _ int, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_VectorLevelSetNodeUS2_set, _swig_p) - return -} - -func (arg1 SwigcptrVectorLevelSetNodeUS2) Set(arg2 int, arg3 ItkLevelSetNodeUS2) { - _swig_wrap_VectorLevelSetNodeUS2_set(arg1, arg2, arg3.Swigcptr()) -} - -var _wrap_delete_VectorLevelSetNodeUS2 unsafe.Pointer - -func _swig_wrap_delete_VectorLevelSetNodeUS2(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_VectorLevelSetNodeUS2, _swig_p) - return -} - -func DeleteVectorLevelSetNodeUS2(arg1 VectorLevelSetNodeUS2) { - _swig_wrap_delete_VectorLevelSetNodeUS2(arg1.Swigcptr()) -} - -type VectorLevelSetNodeUS2 interface { - Swigcptr() uintptr - SwigIsVectorLevelSetNodeUS2() - Size() (_swig_ret int64) - Capacity() (_swig_ret int64) - Reserve(arg2 int64) - IsEmpty() (_swig_ret bool) - Clear() - Add(arg2 ItkLevelSetNodeUS2) - Get(arg2 int) (_swig_ret ItkLevelSetNodeUS2) - Set(arg2 int, arg3 ItkLevelSetNodeUS2) -} - -type SwigcptrItkVectorContainerUILSNUS2 uintptr - -func (p SwigcptrItkVectorContainerUILSNUS2) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrItkVectorContainerUILSNUS2) SwigIsItkVectorContainerUILSNUS2() { -} - -var _wrap_new_ItkVectorContainerUILSNUS2 unsafe.Pointer - -func _swig_wrap_new_ItkVectorContainerUILSNUS2() (base SwigcptrItkVectorContainerUILSNUS2) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_ItkVectorContainerUILSNUS2, _swig_p) - return -} - -func NewItkVectorContainerUILSNUS2() (_swig_ret ItkVectorContainerUILSNUS2) { - return _swig_wrap_new_ItkVectorContainerUILSNUS2() -} - -var _wrap_delete_ItkVectorContainerUILSNUS2 unsafe.Pointer - -func _swig_wrap_delete_ItkVectorContainerUILSNUS2(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_ItkVectorContainerUILSNUS2, _swig_p) - return -} - -func DeleteItkVectorContainerUILSNUS2(arg1 ItkVectorContainerUILSNUS2) { - _swig_wrap_delete_ItkVectorContainerUILSNUS2(arg1.Swigcptr()) -} - -var _wrap_ItkVectorContainerUILSNUS2_size unsafe.Pointer - -func _swig_wrap_ItkVectorContainerUILSNUS2_size(base SwigcptrItkVectorContainerUILSNUS2) (_ int64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_ItkVectorContainerUILSNUS2_size, _swig_p) - return -} - -func (_swig_base SwigcptrItkVectorContainerUILSNUS2) Size() (_swig_ret int64) { - return _swig_wrap_ItkVectorContainerUILSNUS2_size(_swig_base) -} - -var _wrap_ItkVectorContainerUILSNUS2_capacity unsafe.Pointer - -func _swig_wrap_ItkVectorContainerUILSNUS2_capacity(base SwigcptrItkVectorContainerUILSNUS2) (_ int64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_ItkVectorContainerUILSNUS2_capacity, _swig_p) - return -} - -func (_swig_base SwigcptrItkVectorContainerUILSNUS2) Capacity() (_swig_ret int64) { - return _swig_wrap_ItkVectorContainerUILSNUS2_capacity(_swig_base) -} - -var _wrap_ItkVectorContainerUILSNUS2_reserve unsafe.Pointer - -func _swig_wrap_ItkVectorContainerUILSNUS2_reserve(base SwigcptrItkVectorContainerUILSNUS2, _ int64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_ItkVectorContainerUILSNUS2_reserve, _swig_p) - return -} - -func (_swig_base SwigcptrItkVectorContainerUILSNUS2) Reserve(arg1 int64) { - _swig_wrap_ItkVectorContainerUILSNUS2_reserve(_swig_base, arg1) -} - -var _wrap_ItkVectorContainerUILSNUS2_isEmpty unsafe.Pointer - -func _swig_wrap_ItkVectorContainerUILSNUS2_isEmpty(base SwigcptrItkVectorContainerUILSNUS2) (_ bool) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_ItkVectorContainerUILSNUS2_isEmpty, _swig_p) - return -} - -func (_swig_base SwigcptrItkVectorContainerUILSNUS2) IsEmpty() (_swig_ret bool) { - return _swig_wrap_ItkVectorContainerUILSNUS2_isEmpty(_swig_base) -} - -var _wrap_ItkVectorContainerUILSNUS2_clear unsafe.Pointer - -func _swig_wrap_ItkVectorContainerUILSNUS2_clear(base SwigcptrItkVectorContainerUILSNUS2) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_ItkVectorContainerUILSNUS2_clear, _swig_p) - return -} - -func (_swig_base SwigcptrItkVectorContainerUILSNUS2) Clear() { - _swig_wrap_ItkVectorContainerUILSNUS2_clear(_swig_base) -} - -var _wrap_ItkVectorContainerUILSNUS2_add unsafe.Pointer - -func _swig_wrap_ItkVectorContainerUILSNUS2_add(base SwigcptrItkVectorContainerUILSNUS2, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_ItkVectorContainerUILSNUS2_add, _swig_p) - return -} - -func (_swig_base SwigcptrItkVectorContainerUILSNUS2) Add(arg1 ItkLevelSetNodeUS2) { - _swig_wrap_ItkVectorContainerUILSNUS2_add(_swig_base, arg1.Swigcptr()) -} - -func (p SwigcptrItkVectorContainerUILSNUS2) SwigIsVectorLevelSetNodeUS2() { -} - -func (p SwigcptrItkVectorContainerUILSNUS2) SwigGetVectorLevelSetNodeUS2() VectorLevelSetNodeUS2 { - return SwigcptrVectorLevelSetNodeUS2(p.Swigcptr()) -} - -type ItkVectorContainerUILSNUS2 interface { - Swigcptr() uintptr - SwigIsItkVectorContainerUILSNUS2() - Size() (_swig_ret int64) - Capacity() (_swig_ret int64) - Reserve(arg1 int64) - IsEmpty() (_swig_ret bool) - Clear() - Add(arg1 ItkLevelSetNodeUS2) - SwigIsVectorLevelSetNodeUS2() - SwigGetVectorLevelSetNodeUS2() VectorLevelSetNodeUS2 -} - -type SwigcptrItkVectorContainerUILSNUS2_Pointer uintptr - -func (p SwigcptrItkVectorContainerUILSNUS2_Pointer) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrItkVectorContainerUILSNUS2_Pointer) SwigIsItkVectorContainerUILSNUS2_Pointer() { -} - -var _wrap_ItkVectorContainerUILSNUS2_Pointer___deref__ unsafe.Pointer - -func _swig_wrap_ItkVectorContainerUILSNUS2_Pointer___deref__(base SwigcptrItkVectorContainerUILSNUS2_Pointer) (_ SwigcptrItkVectorContainerUILSNUS2) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_ItkVectorContainerUILSNUS2_Pointer___deref__, _swig_p) - return -} - -func (arg1 SwigcptrItkVectorContainerUILSNUS2_Pointer) X__deref__() (_swig_ret ItkVectorContainerUILSNUS2) { - return _swig_wrap_ItkVectorContainerUILSNUS2_Pointer___deref__(arg1) -} - -var _wrap_new_ItkVectorContainerUILSNUS2_Pointer unsafe.Pointer - -func _swig_wrap_new_ItkVectorContainerUILSNUS2_Pointer() (base SwigcptrItkVectorContainerUILSNUS2_Pointer) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_ItkVectorContainerUILSNUS2_Pointer, _swig_p) - return -} - -func NewItkVectorContainerUILSNUS2_Pointer() (_swig_ret ItkVectorContainerUILSNUS2_Pointer) { - return _swig_wrap_new_ItkVectorContainerUILSNUS2_Pointer() -} - -var _wrap_delete_ItkVectorContainerUILSNUS2_Pointer unsafe.Pointer - -func _swig_wrap_delete_ItkVectorContainerUILSNUS2_Pointer(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_ItkVectorContainerUILSNUS2_Pointer, _swig_p) - return -} - -func DeleteItkVectorContainerUILSNUS2_Pointer(arg1 ItkVectorContainerUILSNUS2_Pointer) { - _swig_wrap_delete_ItkVectorContainerUILSNUS2_Pointer(arg1.Swigcptr()) -} - -var _wrap_ItkVectorContainerUILSNUS2_Pointer_size unsafe.Pointer - -func _swig_wrap_ItkVectorContainerUILSNUS2_Pointer_size(base SwigcptrItkVectorContainerUILSNUS2_Pointer) (_ int64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_ItkVectorContainerUILSNUS2_Pointer_size, _swig_p) - return -} - -func (arg1 SwigcptrItkVectorContainerUILSNUS2_Pointer) Size() (_swig_ret int64) { - return _swig_wrap_ItkVectorContainerUILSNUS2_Pointer_size(arg1) -} - -var _wrap_ItkVectorContainerUILSNUS2_Pointer_capacity unsafe.Pointer - -func _swig_wrap_ItkVectorContainerUILSNUS2_Pointer_capacity(base SwigcptrItkVectorContainerUILSNUS2_Pointer) (_ int64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_ItkVectorContainerUILSNUS2_Pointer_capacity, _swig_p) - return -} - -func (arg1 SwigcptrItkVectorContainerUILSNUS2_Pointer) Capacity() (_swig_ret int64) { - return _swig_wrap_ItkVectorContainerUILSNUS2_Pointer_capacity(arg1) -} - -var _wrap_ItkVectorContainerUILSNUS2_Pointer_reserve unsafe.Pointer - -func _swig_wrap_ItkVectorContainerUILSNUS2_Pointer_reserve(base SwigcptrItkVectorContainerUILSNUS2_Pointer, _ int64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_ItkVectorContainerUILSNUS2_Pointer_reserve, _swig_p) - return -} - -func (arg1 SwigcptrItkVectorContainerUILSNUS2_Pointer) Reserve(arg2 int64) { - _swig_wrap_ItkVectorContainerUILSNUS2_Pointer_reserve(arg1, arg2) -} - -var _wrap_ItkVectorContainerUILSNUS2_Pointer_isEmpty unsafe.Pointer - -func _swig_wrap_ItkVectorContainerUILSNUS2_Pointer_isEmpty(base SwigcptrItkVectorContainerUILSNUS2_Pointer) (_ bool) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_ItkVectorContainerUILSNUS2_Pointer_isEmpty, _swig_p) - return -} - -func (arg1 SwigcptrItkVectorContainerUILSNUS2_Pointer) IsEmpty() (_swig_ret bool) { - return _swig_wrap_ItkVectorContainerUILSNUS2_Pointer_isEmpty(arg1) -} - -var _wrap_ItkVectorContainerUILSNUS2_Pointer_clear unsafe.Pointer - -func _swig_wrap_ItkVectorContainerUILSNUS2_Pointer_clear(base SwigcptrItkVectorContainerUILSNUS2_Pointer) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_ItkVectorContainerUILSNUS2_Pointer_clear, _swig_p) - return -} - -func (arg1 SwigcptrItkVectorContainerUILSNUS2_Pointer) Clear() { - _swig_wrap_ItkVectorContainerUILSNUS2_Pointer_clear(arg1) -} - -var _wrap_ItkVectorContainerUILSNUS2_Pointer_add unsafe.Pointer - -func _swig_wrap_ItkVectorContainerUILSNUS2_Pointer_add(base SwigcptrItkVectorContainerUILSNUS2_Pointer, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_ItkVectorContainerUILSNUS2_Pointer_add, _swig_p) - return -} - -func (arg1 SwigcptrItkVectorContainerUILSNUS2_Pointer) Add(arg2 ItkLevelSetNodeUS2) { - _swig_wrap_ItkVectorContainerUILSNUS2_Pointer_add(arg1, arg2.Swigcptr()) -} - -var _wrap_ItkVectorContainerUILSNUS2_Pointer_get unsafe.Pointer - -func _swig_wrap_ItkVectorContainerUILSNUS2_Pointer_get(base SwigcptrItkVectorContainerUILSNUS2_Pointer, _ int) (_ SwigcptrItkLevelSetNodeUS2) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_ItkVectorContainerUILSNUS2_Pointer_get, _swig_p) - return -} - -func (arg1 SwigcptrItkVectorContainerUILSNUS2_Pointer) Get(arg2 int) (_swig_ret ItkLevelSetNodeUS2) { - return _swig_wrap_ItkVectorContainerUILSNUS2_Pointer_get(arg1, arg2) -} - -var _wrap_ItkVectorContainerUILSNUS2_Pointer_set unsafe.Pointer - -func _swig_wrap_ItkVectorContainerUILSNUS2_Pointer_set(base SwigcptrItkVectorContainerUILSNUS2_Pointer, _ int, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_ItkVectorContainerUILSNUS2_Pointer_set, _swig_p) - return -} - -func (arg1 SwigcptrItkVectorContainerUILSNUS2_Pointer) Set(arg2 int, arg3 ItkLevelSetNodeUS2) { - _swig_wrap_ItkVectorContainerUILSNUS2_Pointer_set(arg1, arg2, arg3.Swigcptr()) -} - -type ItkVectorContainerUILSNUS2_Pointer interface { - Swigcptr() uintptr - SwigIsItkVectorContainerUILSNUS2_Pointer() - X__deref__() (_swig_ret ItkVectorContainerUILSNUS2) - Size() (_swig_ret int64) - Capacity() (_swig_ret int64) - Reserve(arg2 int64) - IsEmpty() (_swig_ret bool) - Clear() - Add(arg2 ItkLevelSetNodeUS2) - Get(arg2 int) (_swig_ret ItkLevelSetNodeUS2) - Set(arg2 int, arg3 ItkLevelSetNodeUS2) -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/smart_pointer_member.go b/Examples/test-suite/go/smart_pointer_member.go deleted file mode 100644 index 36c07f7e6..000000000 --- a/Examples/test-suite/go/smart_pointer_member.go +++ /dev/null @@ -1,483 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../smart_pointer_member.i - -package smart_pointer_member - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrFoo uintptr - -func (p SwigcptrFoo) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrFoo) SwigIsFoo() { -} - -var _wrap_Foo_x_set unsafe.Pointer - -func _swig_wrap_Foo_x_set(base SwigcptrFoo, _ *int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_x_set, _swig_p) - return -} - -func (arg1 SwigcptrFoo) SetX(arg2 *int) { - _swig_wrap_Foo_x_set(arg1, arg2) -} - -var _wrap_Foo_x_get unsafe.Pointer - -func _swig_wrap_Foo_x_get(base SwigcptrFoo) (_ *int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_x_get, _swig_p) - return -} - -func (arg1 SwigcptrFoo) GetX() (_swig_ret *int) { - return _swig_wrap_Foo_x_get(arg1) -} - -var _wrap_Foo_y_set unsafe.Pointer - -func _swig_wrap_Foo_y_set(base SwigcptrFoo, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_y_set, _swig_p) - return -} - -func (arg1 SwigcptrFoo) SetY(arg2 int) { - _swig_wrap_Foo_y_set(arg1, arg2) -} - -var _wrap_Foo_y_get unsafe.Pointer - -func _swig_wrap_Foo_y_get(base SwigcptrFoo) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_y_get, _swig_p) - return -} - -func (arg1 SwigcptrFoo) GetY() (_swig_ret int) { - return _swig_wrap_Foo_y_get(arg1) -} - -var _wrap_Foo_z_get unsafe.Pointer - -func GetFooZ() (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_Foo_z_get, _swig_p) - return -} -var _wrap_Foo_ZZ_Foo unsafe.Pointer - -func _swig_getFoo_Foo_ZZ_Foo() (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_Foo_ZZ_Foo, _swig_p) - return -} -var FooZZ int = _swig_getFoo_Foo_ZZ_Foo() -var _wrap_Foo_zx_set unsafe.Pointer - -func _swig_wrap_Foo_zx_set(base int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_zx_set, _swig_p) - return -} - -func SetFooZx(arg1 int) { - _swig_wrap_Foo_zx_set(arg1) -} - -var _wrap_Foo_zx_get unsafe.Pointer - -func GetFooZx() (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_Foo_zx_get, _swig_p) - return -} -var _wrap_Foo_boo unsafe.Pointer - -func FooBoo() (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_Foo_boo, _swig_p) - return -} -var _wrap_new_Foo unsafe.Pointer - -func _swig_wrap_new_Foo() (base SwigcptrFoo) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Foo, _swig_p) - return -} - -func NewFoo() (_swig_ret Foo) { - return _swig_wrap_new_Foo() -} - -var _wrap_delete_Foo unsafe.Pointer - -func _swig_wrap_delete_Foo(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Foo, _swig_p) - return -} - -func DeleteFoo(arg1 Foo) { - _swig_wrap_delete_Foo(arg1.Swigcptr()) -} - -type Foo interface { - Swigcptr() uintptr - SwigIsFoo() - SetX(arg2 *int) - GetX() (_swig_ret *int) - SetY(arg2 int) - GetY() (_swig_ret int) -} - -type SwigcptrBar uintptr - -func (p SwigcptrBar) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrBar) SwigIsBar() { -} - -var _wrap_new_Bar unsafe.Pointer - -func _swig_wrap_new_Bar(base uintptr) (_ SwigcptrBar) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Bar, _swig_p) - return -} - -func NewBar(arg1 Foo) (_swig_ret Bar) { - return _swig_wrap_new_Bar(arg1.Swigcptr()) -} - -var _wrap_Bar___deref__ unsafe.Pointer - -func _swig_wrap_Bar___deref__(base SwigcptrBar) (_ SwigcptrFoo) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Bar___deref__, _swig_p) - return -} - -func (arg1 SwigcptrBar) X__deref__() (_swig_ret Foo) { - return _swig_wrap_Bar___deref__(arg1) -} - -var _wrap_Bar_bua unsafe.Pointer - -func BarBua() (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_Bar_bua, _swig_p) - return -} -var _wrap_delete_Bar unsafe.Pointer - -func _swig_wrap_delete_Bar(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Bar, _swig_p) - return -} - -func DeleteBar(arg1 Bar) { - _swig_wrap_delete_Bar(arg1.Swigcptr()) -} - -var _wrap_Bar_x_set unsafe.Pointer - -func _swig_wrap_Bar_x_set(base SwigcptrBar, _ *int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Bar_x_set, _swig_p) - return -} - -func (arg1 SwigcptrBar) SetX(arg2 *int) { - _swig_wrap_Bar_x_set(arg1, arg2) -} - -var _wrap_Bar_x_get unsafe.Pointer - -func _swig_wrap_Bar_x_get(base SwigcptrBar) (_ *int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Bar_x_get, _swig_p) - return -} - -func (arg1 SwigcptrBar) GetX() (_swig_ret *int) { - return _swig_wrap_Bar_x_get(arg1) -} - -var _wrap_Bar_y_set unsafe.Pointer - -func _swig_wrap_Bar_y_set(base SwigcptrBar, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Bar_y_set, _swig_p) - return -} - -func (arg1 SwigcptrBar) SetY(arg2 int) { - _swig_wrap_Bar_y_set(arg1, arg2) -} - -var _wrap_Bar_y_get unsafe.Pointer - -func _swig_wrap_Bar_y_get(base SwigcptrBar) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Bar_y_get, _swig_p) - return -} - -func (arg1 SwigcptrBar) GetY() (_swig_ret int) { - return _swig_wrap_Bar_y_get(arg1) -} - -var _wrap_Bar_z_get unsafe.Pointer - -func _swig_wrap_Bar_z_get(base SwigcptrBar) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Bar_z_get, _swig_p) - return -} - -func (arg1 SwigcptrBar) GetZ() (_swig_ret int) { - return _swig_wrap_Bar_z_get(arg1) -} - -var _wrap_Bar_ZZ_get unsafe.Pointer - -func _swig_wrap_Bar_ZZ_get(base SwigcptrBar) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Bar_ZZ_get, _swig_p) - return -} - -func (arg1 SwigcptrBar) GetZZ() (_swig_ret int) { - return _swig_wrap_Bar_ZZ_get(arg1) -} - -var _wrap_Bar_zx_set unsafe.Pointer - -func _swig_wrap_Bar_zx_set(base SwigcptrBar, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Bar_zx_set, _swig_p) - return -} - -func (arg1 SwigcptrBar) SetZx(arg2 int) { - _swig_wrap_Bar_zx_set(arg1, arg2) -} - -var _wrap_Bar_zx_get unsafe.Pointer - -func _swig_wrap_Bar_zx_get(base SwigcptrBar) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Bar_zx_get, _swig_p) - return -} - -func (arg1 SwigcptrBar) GetZx() (_swig_ret int) { - return _swig_wrap_Bar_zx_get(arg1) -} - -var _wrap_Bar_boo unsafe.Pointer - -func _swig_wrap_Bar_boo(base SwigcptrBar) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Bar_boo, _swig_p) - return -} - -func (arg1 SwigcptrBar) Boo() (_swig_ret int) { - return _swig_wrap_Bar_boo(arg1) -} - -type Bar interface { - Swigcptr() uintptr - SwigIsBar() - X__deref__() (_swig_ret Foo) - SetX(arg2 *int) - GetX() (_swig_ret *int) - SetY(arg2 int) - GetY() (_swig_ret int) - GetZ() (_swig_ret int) - GetZZ() (_swig_ret int) - SetZx(arg2 int) - GetZx() (_swig_ret int) - Boo() (_swig_ret int) -} - -type SwigcptrCBar uintptr - -func (p SwigcptrCBar) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrCBar) SwigIsCBar() { -} - -var _wrap_new_CBar unsafe.Pointer - -func _swig_wrap_new_CBar(base uintptr) (_ SwigcptrCBar) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_CBar, _swig_p) - return -} - -func NewCBar(arg1 Foo) (_swig_ret CBar) { - return _swig_wrap_new_CBar(arg1.Swigcptr()) -} - -var _wrap_CBar___deref__ unsafe.Pointer - -func _swig_wrap_CBar___deref__(base SwigcptrCBar) (_ SwigcptrFoo) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_CBar___deref__, _swig_p) - return -} - -func (arg1 SwigcptrCBar) X__deref__() (_swig_ret Foo) { - return _swig_wrap_CBar___deref__(arg1) -} - -var _wrap_delete_CBar unsafe.Pointer - -func _swig_wrap_delete_CBar(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_CBar, _swig_p) - return -} - -func DeleteCBar(arg1 CBar) { - _swig_wrap_delete_CBar(arg1.Swigcptr()) -} - -var _wrap_CBar_x_get unsafe.Pointer - -func _swig_wrap_CBar_x_get(base SwigcptrCBar) (_ *int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_CBar_x_get, _swig_p) - return -} - -func (arg1 SwigcptrCBar) GetX() (_swig_ret *int) { - return _swig_wrap_CBar_x_get(arg1) -} - -var _wrap_CBar_y_get unsafe.Pointer - -func _swig_wrap_CBar_y_get(base SwigcptrCBar) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_CBar_y_get, _swig_p) - return -} - -func (arg1 SwigcptrCBar) GetY() (_swig_ret int) { - return _swig_wrap_CBar_y_get(arg1) -} - -var _wrap_CBar_z_get unsafe.Pointer - -func _swig_wrap_CBar_z_get(base SwigcptrCBar) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_CBar_z_get, _swig_p) - return -} - -func (arg1 SwigcptrCBar) GetZ() (_swig_ret int) { - return _swig_wrap_CBar_z_get(arg1) -} - -var _wrap_CBar_ZZ_get unsafe.Pointer - -func _swig_wrap_CBar_ZZ_get(base SwigcptrCBar) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_CBar_ZZ_get, _swig_p) - return -} - -func (arg1 SwigcptrCBar) GetZZ() (_swig_ret int) { - return _swig_wrap_CBar_ZZ_get(arg1) -} - -var _wrap_CBar_zx_get unsafe.Pointer - -func _swig_wrap_CBar_zx_get(base SwigcptrCBar) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_CBar_zx_get, _swig_p) - return -} - -func (arg1 SwigcptrCBar) GetZx() (_swig_ret int) { - return _swig_wrap_CBar_zx_get(arg1) -} - -type CBar interface { - Swigcptr() uintptr - SwigIsCBar() - X__deref__() (_swig_ret Foo) - GetX() (_swig_ret *int) - GetY() (_swig_ret int) - GetZ() (_swig_ret int) - GetZZ() (_swig_ret int) - GetZx() (_swig_ret int) -} - -var _wrap_get_y unsafe.Pointer - -func _swig_wrap_get_y(base uintptr) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_get_y, _swig_p) - return -} - -func Get_y(arg1 Bar) (_swig_ret int) { - return _swig_wrap_get_y(arg1.Swigcptr()) -} - -var _wrap_get_z unsafe.Pointer - -func _swig_wrap_get_z(base uintptr) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_get_z, _swig_p) - return -} - -func Get_z(arg1 Bar) (_swig_ret int) { - return _swig_wrap_get_z(arg1.Swigcptr()) -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/smart_pointer_member_runme b/Examples/test-suite/go/smart_pointer_member_runme deleted file mode 100755 index 04be2c275..000000000 Binary files a/Examples/test-suite/go/smart_pointer_member_runme and /dev/null differ diff --git a/Examples/test-suite/go/smart_pointer_multi.go b/Examples/test-suite/go/smart_pointer_multi.go deleted file mode 100644 index 9b1b30f15..000000000 --- a/Examples/test-suite/go/smart_pointer_multi.go +++ /dev/null @@ -1,384 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../smart_pointer_multi.i - -package smart_pointer_multi - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrFoo uintptr - -func (p SwigcptrFoo) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrFoo) SwigIsFoo() { -} - -var _wrap_Foo_x_set unsafe.Pointer - -func _swig_wrap_Foo_x_set(base SwigcptrFoo, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_x_set, _swig_p) - return -} - -func (arg1 SwigcptrFoo) SetX(arg2 int) { - _swig_wrap_Foo_x_set(arg1, arg2) -} - -var _wrap_Foo_x_get unsafe.Pointer - -func _swig_wrap_Foo_x_get(base SwigcptrFoo) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_x_get, _swig_p) - return -} - -func (arg1 SwigcptrFoo) GetX() (_swig_ret int) { - return _swig_wrap_Foo_x_get(arg1) -} - -var _wrap_Foo_getx unsafe.Pointer - -func _swig_wrap_Foo_getx(base SwigcptrFoo) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_getx, _swig_p) - return -} - -func (arg1 SwigcptrFoo) Getx() (_swig_ret int) { - return _swig_wrap_Foo_getx(arg1) -} - -var _wrap_new_Foo unsafe.Pointer - -func _swig_wrap_new_Foo() (base SwigcptrFoo) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Foo, _swig_p) - return -} - -func NewFoo() (_swig_ret Foo) { - return _swig_wrap_new_Foo() -} - -var _wrap_delete_Foo unsafe.Pointer - -func _swig_wrap_delete_Foo(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Foo, _swig_p) - return -} - -func DeleteFoo(arg1 Foo) { - _swig_wrap_delete_Foo(arg1.Swigcptr()) -} - -type Foo interface { - Swigcptr() uintptr - SwigIsFoo() - SetX(arg2 int) - GetX() (_swig_ret int) - Getx() (_swig_ret int) -} - -type SwigcptrBar uintptr - -func (p SwigcptrBar) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrBar) SwigIsBar() { -} - -var _wrap_new_Bar unsafe.Pointer - -func _swig_wrap_new_Bar(base uintptr) (_ SwigcptrBar) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Bar, _swig_p) - return -} - -func NewBar(arg1 Foo) (_swig_ret Bar) { - return _swig_wrap_new_Bar(arg1.Swigcptr()) -} - -var _wrap_Bar___deref__ unsafe.Pointer - -func _swig_wrap_Bar___deref__(base SwigcptrBar) (_ SwigcptrFoo) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Bar___deref__, _swig_p) - return -} - -func (arg1 SwigcptrBar) X__deref__() (_swig_ret Foo) { - return _swig_wrap_Bar___deref__(arg1) -} - -var _wrap_delete_Bar unsafe.Pointer - -func _swig_wrap_delete_Bar(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Bar, _swig_p) - return -} - -func DeleteBar(arg1 Bar) { - _swig_wrap_delete_Bar(arg1.Swigcptr()) -} - -var _wrap_Bar_x_set unsafe.Pointer - -func _swig_wrap_Bar_x_set(base SwigcptrBar, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Bar_x_set, _swig_p) - return -} - -func (arg1 SwigcptrBar) SetX(arg2 int) { - _swig_wrap_Bar_x_set(arg1, arg2) -} - -var _wrap_Bar_x_get unsafe.Pointer - -func _swig_wrap_Bar_x_get(base SwigcptrBar) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Bar_x_get, _swig_p) - return -} - -func (arg1 SwigcptrBar) GetX() (_swig_ret int) { - return _swig_wrap_Bar_x_get(arg1) -} - -var _wrap_Bar_getx unsafe.Pointer - -func _swig_wrap_Bar_getx(base SwigcptrBar) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Bar_getx, _swig_p) - return -} - -func (arg1 SwigcptrBar) Getx() (_swig_ret int) { - return _swig_wrap_Bar_getx(arg1) -} - -type Bar interface { - Swigcptr() uintptr - SwigIsBar() - X__deref__() (_swig_ret Foo) - SetX(arg2 int) - GetX() (_swig_ret int) - Getx() (_swig_ret int) -} - -type SwigcptrSpam uintptr - -func (p SwigcptrSpam) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrSpam) SwigIsSpam() { -} - -var _wrap_new_Spam unsafe.Pointer - -func _swig_wrap_new_Spam(base uintptr) (_ SwigcptrSpam) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Spam, _swig_p) - return -} - -func NewSpam(arg1 Bar) (_swig_ret Spam) { - return _swig_wrap_new_Spam(arg1.Swigcptr()) -} - -var _wrap_Spam___deref__ unsafe.Pointer - -func _swig_wrap_Spam___deref__(base SwigcptrSpam) (_ SwigcptrBar) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Spam___deref__, _swig_p) - return -} - -func (arg1 SwigcptrSpam) X__deref__() (_swig_ret Bar) { - return _swig_wrap_Spam___deref__(arg1) -} - -var _wrap_delete_Spam unsafe.Pointer - -func _swig_wrap_delete_Spam(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Spam, _swig_p) - return -} - -func DeleteSpam(arg1 Spam) { - _swig_wrap_delete_Spam(arg1.Swigcptr()) -} - -var _wrap_Spam_x_set unsafe.Pointer - -func _swig_wrap_Spam_x_set(base SwigcptrSpam, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Spam_x_set, _swig_p) - return -} - -func (arg1 SwigcptrSpam) SetX(arg2 int) { - _swig_wrap_Spam_x_set(arg1, arg2) -} - -var _wrap_Spam_x_get unsafe.Pointer - -func _swig_wrap_Spam_x_get(base SwigcptrSpam) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Spam_x_get, _swig_p) - return -} - -func (arg1 SwigcptrSpam) GetX() (_swig_ret int) { - return _swig_wrap_Spam_x_get(arg1) -} - -var _wrap_Spam_getx unsafe.Pointer - -func _swig_wrap_Spam_getx(base SwigcptrSpam) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Spam_getx, _swig_p) - return -} - -func (arg1 SwigcptrSpam) Getx() (_swig_ret int) { - return _swig_wrap_Spam_getx(arg1) -} - -type Spam interface { - Swigcptr() uintptr - SwigIsSpam() - X__deref__() (_swig_ret Bar) - SetX(arg2 int) - GetX() (_swig_ret int) - Getx() (_swig_ret int) -} - -type SwigcptrGrok uintptr - -func (p SwigcptrGrok) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrGrok) SwigIsGrok() { -} - -var _wrap_new_Grok unsafe.Pointer - -func _swig_wrap_new_Grok(base uintptr) (_ SwigcptrGrok) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Grok, _swig_p) - return -} - -func NewGrok(arg1 Bar) (_swig_ret Grok) { - return _swig_wrap_new_Grok(arg1.Swigcptr()) -} - -var _wrap_Grok___deref__ unsafe.Pointer - -func _swig_wrap_Grok___deref__(base SwigcptrGrok) (_ SwigcptrBar) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Grok___deref__, _swig_p) - return -} - -func (arg1 SwigcptrGrok) X__deref__() (_swig_ret Bar) { - return _swig_wrap_Grok___deref__(arg1) -} - -var _wrap_delete_Grok unsafe.Pointer - -func _swig_wrap_delete_Grok(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Grok, _swig_p) - return -} - -func DeleteGrok(arg1 Grok) { - _swig_wrap_delete_Grok(arg1.Swigcptr()) -} - -var _wrap_Grok_x_set unsafe.Pointer - -func _swig_wrap_Grok_x_set(base SwigcptrGrok, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Grok_x_set, _swig_p) - return -} - -func (arg1 SwigcptrGrok) SetX(arg2 int) { - _swig_wrap_Grok_x_set(arg1, arg2) -} - -var _wrap_Grok_x_get unsafe.Pointer - -func _swig_wrap_Grok_x_get(base SwigcptrGrok) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Grok_x_get, _swig_p) - return -} - -func (arg1 SwigcptrGrok) GetX() (_swig_ret int) { - return _swig_wrap_Grok_x_get(arg1) -} - -var _wrap_Grok_getx unsafe.Pointer - -func _swig_wrap_Grok_getx(base SwigcptrGrok) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Grok_getx, _swig_p) - return -} - -func (arg1 SwigcptrGrok) Getx() (_swig_ret int) { - return _swig_wrap_Grok_getx(arg1) -} - -type Grok interface { - Swigcptr() uintptr - SwigIsGrok() - X__deref__() (_swig_ret Bar) - SetX(arg2 int) - GetX() (_swig_ret int) - Getx() (_swig_ret int) -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/smart_pointer_multi_runme b/Examples/test-suite/go/smart_pointer_multi_runme deleted file mode 100755 index 3c0d785c9..000000000 Binary files a/Examples/test-suite/go/smart_pointer_multi_runme and /dev/null differ diff --git a/Examples/test-suite/go/smart_pointer_multi_typedef.go b/Examples/test-suite/go/smart_pointer_multi_typedef.go deleted file mode 100644 index a272cf972..000000000 --- a/Examples/test-suite/go/smart_pointer_multi_typedef.go +++ /dev/null @@ -1,384 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../smart_pointer_multi_typedef.i - -package smart_pointer_multi_typedef - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrFoo uintptr - -func (p SwigcptrFoo) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrFoo) SwigIsFoo() { -} - -var _wrap_Foo_x_set unsafe.Pointer - -func _swig_wrap_Foo_x_set(base SwigcptrFoo, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_x_set, _swig_p) - return -} - -func (arg1 SwigcptrFoo) SetX(arg2 int) { - _swig_wrap_Foo_x_set(arg1, arg2) -} - -var _wrap_Foo_x_get unsafe.Pointer - -func _swig_wrap_Foo_x_get(base SwigcptrFoo) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_x_get, _swig_p) - return -} - -func (arg1 SwigcptrFoo) GetX() (_swig_ret int) { - return _swig_wrap_Foo_x_get(arg1) -} - -var _wrap_Foo_getx unsafe.Pointer - -func _swig_wrap_Foo_getx(base SwigcptrFoo) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_getx, _swig_p) - return -} - -func (arg1 SwigcptrFoo) Getx() (_swig_ret int) { - return _swig_wrap_Foo_getx(arg1) -} - -var _wrap_new_Foo unsafe.Pointer - -func _swig_wrap_new_Foo() (base SwigcptrFoo) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Foo, _swig_p) - return -} - -func NewFoo() (_swig_ret Foo) { - return _swig_wrap_new_Foo() -} - -var _wrap_delete_Foo unsafe.Pointer - -func _swig_wrap_delete_Foo(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Foo, _swig_p) - return -} - -func DeleteFoo(arg1 Foo) { - _swig_wrap_delete_Foo(arg1.Swigcptr()) -} - -type Foo interface { - Swigcptr() uintptr - SwigIsFoo() - SetX(arg2 int) - GetX() (_swig_ret int) - Getx() (_swig_ret int) -} - -type SwigcptrBar uintptr - -func (p SwigcptrBar) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrBar) SwigIsBar() { -} - -var _wrap_new_Bar unsafe.Pointer - -func _swig_wrap_new_Bar(base uintptr) (_ SwigcptrBar) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Bar, _swig_p) - return -} - -func NewBar(arg1 Foo) (_swig_ret Bar) { - return _swig_wrap_new_Bar(arg1.Swigcptr()) -} - -var _wrap_Bar___deref__ unsafe.Pointer - -func _swig_wrap_Bar___deref__(base SwigcptrBar) (_ SwigcptrFoo) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Bar___deref__, _swig_p) - return -} - -func (arg1 SwigcptrBar) X__deref__() (_swig_ret Foo) { - return _swig_wrap_Bar___deref__(arg1) -} - -var _wrap_delete_Bar unsafe.Pointer - -func _swig_wrap_delete_Bar(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Bar, _swig_p) - return -} - -func DeleteBar(arg1 Bar) { - _swig_wrap_delete_Bar(arg1.Swigcptr()) -} - -var _wrap_Bar_x_set unsafe.Pointer - -func _swig_wrap_Bar_x_set(base SwigcptrBar, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Bar_x_set, _swig_p) - return -} - -func (arg1 SwigcptrBar) SetX(arg2 int) { - _swig_wrap_Bar_x_set(arg1, arg2) -} - -var _wrap_Bar_x_get unsafe.Pointer - -func _swig_wrap_Bar_x_get(base SwigcptrBar) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Bar_x_get, _swig_p) - return -} - -func (arg1 SwigcptrBar) GetX() (_swig_ret int) { - return _swig_wrap_Bar_x_get(arg1) -} - -var _wrap_Bar_getx unsafe.Pointer - -func _swig_wrap_Bar_getx(base SwigcptrBar) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Bar_getx, _swig_p) - return -} - -func (arg1 SwigcptrBar) Getx() (_swig_ret int) { - return _swig_wrap_Bar_getx(arg1) -} - -type Bar interface { - Swigcptr() uintptr - SwigIsBar() - X__deref__() (_swig_ret Foo) - SetX(arg2 int) - GetX() (_swig_ret int) - Getx() (_swig_ret int) -} - -type SwigcptrSpam uintptr - -func (p SwigcptrSpam) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrSpam) SwigIsSpam() { -} - -var _wrap_new_Spam unsafe.Pointer - -func _swig_wrap_new_Spam(base uintptr) (_ SwigcptrSpam) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Spam, _swig_p) - return -} - -func NewSpam(arg1 Bar) (_swig_ret Spam) { - return _swig_wrap_new_Spam(arg1.Swigcptr()) -} - -var _wrap_Spam___deref__ unsafe.Pointer - -func _swig_wrap_Spam___deref__(base SwigcptrSpam) (_ SwigcptrBar) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Spam___deref__, _swig_p) - return -} - -func (arg1 SwigcptrSpam) X__deref__() (_swig_ret Bar) { - return _swig_wrap_Spam___deref__(arg1) -} - -var _wrap_delete_Spam unsafe.Pointer - -func _swig_wrap_delete_Spam(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Spam, _swig_p) - return -} - -func DeleteSpam(arg1 Spam) { - _swig_wrap_delete_Spam(arg1.Swigcptr()) -} - -var _wrap_Spam_x_set unsafe.Pointer - -func _swig_wrap_Spam_x_set(base SwigcptrSpam, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Spam_x_set, _swig_p) - return -} - -func (arg1 SwigcptrSpam) SetX(arg2 int) { - _swig_wrap_Spam_x_set(arg1, arg2) -} - -var _wrap_Spam_x_get unsafe.Pointer - -func _swig_wrap_Spam_x_get(base SwigcptrSpam) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Spam_x_get, _swig_p) - return -} - -func (arg1 SwigcptrSpam) GetX() (_swig_ret int) { - return _swig_wrap_Spam_x_get(arg1) -} - -var _wrap_Spam_getx unsafe.Pointer - -func _swig_wrap_Spam_getx(base SwigcptrSpam) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Spam_getx, _swig_p) - return -} - -func (arg1 SwigcptrSpam) Getx() (_swig_ret int) { - return _swig_wrap_Spam_getx(arg1) -} - -type Spam interface { - Swigcptr() uintptr - SwigIsSpam() - X__deref__() (_swig_ret Bar) - SetX(arg2 int) - GetX() (_swig_ret int) - Getx() (_swig_ret int) -} - -type SwigcptrGrok uintptr - -func (p SwigcptrGrok) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrGrok) SwigIsGrok() { -} - -var _wrap_new_Grok unsafe.Pointer - -func _swig_wrap_new_Grok(base uintptr) (_ SwigcptrGrok) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Grok, _swig_p) - return -} - -func NewGrok(arg1 Bar) (_swig_ret Grok) { - return _swig_wrap_new_Grok(arg1.Swigcptr()) -} - -var _wrap_Grok___deref__ unsafe.Pointer - -func _swig_wrap_Grok___deref__(base SwigcptrGrok) (_ SwigcptrBar) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Grok___deref__, _swig_p) - return -} - -func (arg1 SwigcptrGrok) X__deref__() (_swig_ret Bar) { - return _swig_wrap_Grok___deref__(arg1) -} - -var _wrap_delete_Grok unsafe.Pointer - -func _swig_wrap_delete_Grok(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Grok, _swig_p) - return -} - -func DeleteGrok(arg1 Grok) { - _swig_wrap_delete_Grok(arg1.Swigcptr()) -} - -var _wrap_Grok_x_set unsafe.Pointer - -func _swig_wrap_Grok_x_set(base SwigcptrGrok, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Grok_x_set, _swig_p) - return -} - -func (arg1 SwigcptrGrok) SetX(arg2 int) { - _swig_wrap_Grok_x_set(arg1, arg2) -} - -var _wrap_Grok_x_get unsafe.Pointer - -func _swig_wrap_Grok_x_get(base SwigcptrGrok) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Grok_x_get, _swig_p) - return -} - -func (arg1 SwigcptrGrok) GetX() (_swig_ret int) { - return _swig_wrap_Grok_x_get(arg1) -} - -var _wrap_Grok_getx unsafe.Pointer - -func _swig_wrap_Grok_getx(base SwigcptrGrok) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Grok_getx, _swig_p) - return -} - -func (arg1 SwigcptrGrok) Getx() (_swig_ret int) { - return _swig_wrap_Grok_getx(arg1) -} - -type Grok interface { - Swigcptr() uintptr - SwigIsGrok() - X__deref__() (_swig_ret Bar) - SetX(arg2 int) - GetX() (_swig_ret int) - Getx() (_swig_ret int) -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/smart_pointer_multi_typedef_runme b/Examples/test-suite/go/smart_pointer_multi_typedef_runme deleted file mode 100755 index 2bbd3e1ce..000000000 Binary files a/Examples/test-suite/go/smart_pointer_multi_typedef_runme and /dev/null differ diff --git a/Examples/test-suite/go/smart_pointer_namespace.go b/Examples/test-suite/go/smart_pointer_namespace.go deleted file mode 100644 index 09fccbdd1..000000000 --- a/Examples/test-suite/go/smart_pointer_namespace.go +++ /dev/null @@ -1,267 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../smart_pointer_namespace.i - -package smart_pointer_namespace - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrObj1 uintptr - -func (p SwigcptrObj1) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrObj1) SwigIsObj1() { -} - -var _wrap_new_Obj1 unsafe.Pointer - -func _swig_wrap_new_Obj1() (base SwigcptrObj1) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Obj1, _swig_p) - return -} - -func NewObj1() (_swig_ret Obj1) { - return _swig_wrap_new_Obj1() -} - -var _wrap_Obj1_donothing unsafe.Pointer - -func _swig_wrap_Obj1_donothing(base SwigcptrObj1) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Obj1_donothing, _swig_p) - return -} - -func (arg1 SwigcptrObj1) Donothing() { - _swig_wrap_Obj1_donothing(arg1) -} - -var _wrap_delete_Obj1 unsafe.Pointer - -func _swig_wrap_delete_Obj1(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Obj1, _swig_p) - return -} - -func DeleteObj1(arg1 Obj1) { - _swig_wrap_delete_Obj1(arg1.Swigcptr()) -} - -type Obj1 interface { - Swigcptr() uintptr - SwigIsObj1() - Donothing() -} - -type SwigcptrObj1_ptr uintptr - -func (p SwigcptrObj1_ptr) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrObj1_ptr) SwigIsObj1_ptr() { -} - -var _wrap_new_Obj1_ptr unsafe.Pointer - -func _swig_wrap_new_Obj1_ptr(base uintptr) (_ SwigcptrObj1_ptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Obj1_ptr, _swig_p) - return -} - -func NewObj1_ptr(arg1 Obj1) (_swig_ret Obj1_ptr) { - return _swig_wrap_new_Obj1_ptr(arg1.Swigcptr()) -} - -var _wrap_delete_Obj1_ptr unsafe.Pointer - -func _swig_wrap_delete_Obj1_ptr(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Obj1_ptr, _swig_p) - return -} - -func DeleteObj1_ptr(arg1 Obj1_ptr) { - _swig_wrap_delete_Obj1_ptr(arg1.Swigcptr()) -} - -var _wrap_Obj1_ptr___deref__ unsafe.Pointer - -func _swig_wrap_Obj1_ptr___deref__(base SwigcptrObj1_ptr) (_ SwigcptrObj1) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Obj1_ptr___deref__, _swig_p) - return -} - -func (arg1 SwigcptrObj1_ptr) X__deref__() (_swig_ret Obj1) { - return _swig_wrap_Obj1_ptr___deref__(arg1) -} - -var _wrap_Obj1_ptr_donothing unsafe.Pointer - -func _swig_wrap_Obj1_ptr_donothing(base SwigcptrObj1_ptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Obj1_ptr_donothing, _swig_p) - return -} - -func (arg1 SwigcptrObj1_ptr) Donothing() { - _swig_wrap_Obj1_ptr_donothing(arg1) -} - -type Obj1_ptr interface { - Swigcptr() uintptr - SwigIsObj1_ptr() - X__deref__() (_swig_ret Obj1) - Donothing() -} - -type SwigcptrObj2 uintptr - -func (p SwigcptrObj2) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrObj2) SwigIsObj2() { -} - -var _wrap_new_Obj2 unsafe.Pointer - -func _swig_wrap_new_Obj2() (base SwigcptrObj2) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Obj2, _swig_p) - return -} - -func NewObj2() (_swig_ret Obj2) { - return _swig_wrap_new_Obj2() -} - -var _wrap_Obj2_donothing unsafe.Pointer - -func _swig_wrap_Obj2_donothing(base SwigcptrObj2) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Obj2_donothing, _swig_p) - return -} - -func (arg1 SwigcptrObj2) Donothing() { - _swig_wrap_Obj2_donothing(arg1) -} - -var _wrap_delete_Obj2 unsafe.Pointer - -func _swig_wrap_delete_Obj2(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Obj2, _swig_p) - return -} - -func DeleteObj2(arg1 Obj2) { - _swig_wrap_delete_Obj2(arg1.Swigcptr()) -} - -type Obj2 interface { - Swigcptr() uintptr - SwigIsObj2() - Donothing() -} - -type SwigcptrObj2_ptr uintptr - -func (p SwigcptrObj2_ptr) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrObj2_ptr) SwigIsObj2_ptr() { -} - -var _wrap_new_Obj2_ptr unsafe.Pointer - -func _swig_wrap_new_Obj2_ptr(base uintptr) (_ SwigcptrObj2_ptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Obj2_ptr, _swig_p) - return -} - -func NewObj2_ptr(arg1 Obj2) (_swig_ret Obj2_ptr) { - return _swig_wrap_new_Obj2_ptr(arg1.Swigcptr()) -} - -var _wrap_delete_Obj2_ptr unsafe.Pointer - -func _swig_wrap_delete_Obj2_ptr(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Obj2_ptr, _swig_p) - return -} - -func DeleteObj2_ptr(arg1 Obj2_ptr) { - _swig_wrap_delete_Obj2_ptr(arg1.Swigcptr()) -} - -var _wrap_Obj2_ptr___deref__ unsafe.Pointer - -func _swig_wrap_Obj2_ptr___deref__(base SwigcptrObj2_ptr) (_ SwigcptrObj2) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Obj2_ptr___deref__, _swig_p) - return -} - -func (arg1 SwigcptrObj2_ptr) X__deref__() (_swig_ret Obj2) { - return _swig_wrap_Obj2_ptr___deref__(arg1) -} - -var _wrap_Obj2_ptr_donothing unsafe.Pointer - -func _swig_wrap_Obj2_ptr_donothing(base SwigcptrObj2_ptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Obj2_ptr_donothing, _swig_p) - return -} - -func (arg1 SwigcptrObj2_ptr) Donothing() { - _swig_wrap_Obj2_ptr_donothing(arg1) -} - -type Obj2_ptr interface { - Swigcptr() uintptr - SwigIsObj2_ptr() - X__deref__() (_swig_ret Obj2) - Donothing() -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/smart_pointer_namespace2.go b/Examples/test-suite/go/smart_pointer_namespace2.go deleted file mode 100644 index dbefe5b5d..000000000 --- a/Examples/test-suite/go/smart_pointer_namespace2.go +++ /dev/null @@ -1,267 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../smart_pointer_namespace2.i - -package smart_pointer_namespace2 - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrObj1 uintptr - -func (p SwigcptrObj1) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrObj1) SwigIsObj1() { -} - -var _wrap_new_Obj1 unsafe.Pointer - -func _swig_wrap_new_Obj1() (base SwigcptrObj1) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Obj1, _swig_p) - return -} - -func NewObj1() (_swig_ret Obj1) { - return _swig_wrap_new_Obj1() -} - -var _wrap_Obj1_donothing unsafe.Pointer - -func _swig_wrap_Obj1_donothing(base SwigcptrObj1) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Obj1_donothing, _swig_p) - return -} - -func (arg1 SwigcptrObj1) Donothing() { - _swig_wrap_Obj1_donothing(arg1) -} - -var _wrap_delete_Obj1 unsafe.Pointer - -func _swig_wrap_delete_Obj1(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Obj1, _swig_p) - return -} - -func DeleteObj1(arg1 Obj1) { - _swig_wrap_delete_Obj1(arg1.Swigcptr()) -} - -type Obj1 interface { - Swigcptr() uintptr - SwigIsObj1() - Donothing() -} - -type SwigcptrObj1_ptr uintptr - -func (p SwigcptrObj1_ptr) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrObj1_ptr) SwigIsObj1_ptr() { -} - -var _wrap_new_Obj1_ptr unsafe.Pointer - -func _swig_wrap_new_Obj1_ptr(base uintptr) (_ SwigcptrObj1_ptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Obj1_ptr, _swig_p) - return -} - -func NewObj1_ptr(arg1 Obj1) (_swig_ret Obj1_ptr) { - return _swig_wrap_new_Obj1_ptr(arg1.Swigcptr()) -} - -var _wrap_delete_Obj1_ptr unsafe.Pointer - -func _swig_wrap_delete_Obj1_ptr(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Obj1_ptr, _swig_p) - return -} - -func DeleteObj1_ptr(arg1 Obj1_ptr) { - _swig_wrap_delete_Obj1_ptr(arg1.Swigcptr()) -} - -var _wrap_Obj1_ptr___deref__ unsafe.Pointer - -func _swig_wrap_Obj1_ptr___deref__(base SwigcptrObj1_ptr) (_ SwigcptrObj1) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Obj1_ptr___deref__, _swig_p) - return -} - -func (arg1 SwigcptrObj1_ptr) X__deref__() (_swig_ret Obj1) { - return _swig_wrap_Obj1_ptr___deref__(arg1) -} - -var _wrap_Obj1_ptr_donothing unsafe.Pointer - -func _swig_wrap_Obj1_ptr_donothing(base SwigcptrObj1_ptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Obj1_ptr_donothing, _swig_p) - return -} - -func (arg1 SwigcptrObj1_ptr) Donothing() { - _swig_wrap_Obj1_ptr_donothing(arg1) -} - -type Obj1_ptr interface { - Swigcptr() uintptr - SwigIsObj1_ptr() - X__deref__() (_swig_ret Obj1) - Donothing() -} - -type SwigcptrObj2 uintptr - -func (p SwigcptrObj2) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrObj2) SwigIsObj2() { -} - -var _wrap_new_Obj2 unsafe.Pointer - -func _swig_wrap_new_Obj2() (base SwigcptrObj2) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Obj2, _swig_p) - return -} - -func NewObj2() (_swig_ret Obj2) { - return _swig_wrap_new_Obj2() -} - -var _wrap_Obj2_donothing unsafe.Pointer - -func _swig_wrap_Obj2_donothing(base SwigcptrObj2) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Obj2_donothing, _swig_p) - return -} - -func (arg1 SwigcptrObj2) Donothing() { - _swig_wrap_Obj2_donothing(arg1) -} - -var _wrap_delete_Obj2 unsafe.Pointer - -func _swig_wrap_delete_Obj2(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Obj2, _swig_p) - return -} - -func DeleteObj2(arg1 Obj2) { - _swig_wrap_delete_Obj2(arg1.Swigcptr()) -} - -type Obj2 interface { - Swigcptr() uintptr - SwigIsObj2() - Donothing() -} - -type SwigcptrObj2_ptr uintptr - -func (p SwigcptrObj2_ptr) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrObj2_ptr) SwigIsObj2_ptr() { -} - -var _wrap_new_Obj2_ptr unsafe.Pointer - -func _swig_wrap_new_Obj2_ptr(base uintptr) (_ SwigcptrObj2_ptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Obj2_ptr, _swig_p) - return -} - -func NewObj2_ptr(arg1 Obj2) (_swig_ret Obj2_ptr) { - return _swig_wrap_new_Obj2_ptr(arg1.Swigcptr()) -} - -var _wrap_delete_Obj2_ptr unsafe.Pointer - -func _swig_wrap_delete_Obj2_ptr(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Obj2_ptr, _swig_p) - return -} - -func DeleteObj2_ptr(arg1 Obj2_ptr) { - _swig_wrap_delete_Obj2_ptr(arg1.Swigcptr()) -} - -var _wrap_Obj2_ptr___deref__ unsafe.Pointer - -func _swig_wrap_Obj2_ptr___deref__(base SwigcptrObj2_ptr) (_ SwigcptrObj2) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Obj2_ptr___deref__, _swig_p) - return -} - -func (arg1 SwigcptrObj2_ptr) X__deref__() (_swig_ret Obj2) { - return _swig_wrap_Obj2_ptr___deref__(arg1) -} - -var _wrap_Obj2_ptr_donothing unsafe.Pointer - -func _swig_wrap_Obj2_ptr_donothing(base SwigcptrObj2_ptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Obj2_ptr_donothing, _swig_p) - return -} - -func (arg1 SwigcptrObj2_ptr) Donothing() { - _swig_wrap_Obj2_ptr_donothing(arg1) -} - -type Obj2_ptr interface { - Swigcptr() uintptr - SwigIsObj2_ptr() - X__deref__() (_swig_ret Obj2) - Donothing() -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/smart_pointer_not.go b/Examples/test-suite/go/smart_pointer_not.go deleted file mode 100644 index 381afdfe5..000000000 --- a/Examples/test-suite/go/smart_pointer_not.go +++ /dev/null @@ -1,267 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../smart_pointer_not.i - -package smart_pointer_not - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrFoo uintptr - -func (p SwigcptrFoo) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrFoo) SwigIsFoo() { -} - -var _wrap_Foo_x_set unsafe.Pointer - -func _swig_wrap_Foo_x_set(base SwigcptrFoo, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_x_set, _swig_p) - return -} - -func (arg1 SwigcptrFoo) SetX(arg2 int) { - _swig_wrap_Foo_x_set(arg1, arg2) -} - -var _wrap_Foo_x_get unsafe.Pointer - -func _swig_wrap_Foo_x_get(base SwigcptrFoo) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_x_get, _swig_p) - return -} - -func (arg1 SwigcptrFoo) GetX() (_swig_ret int) { - return _swig_wrap_Foo_x_get(arg1) -} - -var _wrap_Foo_getx unsafe.Pointer - -func _swig_wrap_Foo_getx(base SwigcptrFoo) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_getx, _swig_p) - return -} - -func (arg1 SwigcptrFoo) Getx() (_swig_ret int) { - return _swig_wrap_Foo_getx(arg1) -} - -var _wrap_new_Foo unsafe.Pointer - -func _swig_wrap_new_Foo() (base SwigcptrFoo) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Foo, _swig_p) - return -} - -func NewFoo() (_swig_ret Foo) { - return _swig_wrap_new_Foo() -} - -var _wrap_delete_Foo unsafe.Pointer - -func _swig_wrap_delete_Foo(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Foo, _swig_p) - return -} - -func DeleteFoo(arg1 Foo) { - _swig_wrap_delete_Foo(arg1.Swigcptr()) -} - -type Foo interface { - Swigcptr() uintptr - SwigIsFoo() - SetX(arg2 int) - GetX() (_swig_ret int) - Getx() (_swig_ret int) -} - -type SwigcptrBar uintptr - -func (p SwigcptrBar) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrBar) SwigIsBar() { -} - -var _wrap_new_Bar unsafe.Pointer - -func _swig_wrap_new_Bar(base uintptr) (_ SwigcptrBar) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Bar, _swig_p) - return -} - -func NewBar(arg1 Foo) (_swig_ret Bar) { - return _swig_wrap_new_Bar(arg1.Swigcptr()) -} - -var _wrap_Bar___deref__ unsafe.Pointer - -func _swig_wrap_Bar___deref__(base SwigcptrBar) (_ SwigcptrFoo) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Bar___deref__, _swig_p) - return -} - -func (arg1 SwigcptrBar) X__deref__() (_swig_ret Foo) { - return _swig_wrap_Bar___deref__(arg1) -} - -var _wrap_delete_Bar unsafe.Pointer - -func _swig_wrap_delete_Bar(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Bar, _swig_p) - return -} - -func DeleteBar(arg1 Bar) { - _swig_wrap_delete_Bar(arg1.Swigcptr()) -} - -type Bar interface { - Swigcptr() uintptr - SwigIsBar() - X__deref__() (_swig_ret Foo) -} - -type SwigcptrSpam uintptr - -func (p SwigcptrSpam) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrSpam) SwigIsSpam() { -} - -var _wrap_new_Spam unsafe.Pointer - -func _swig_wrap_new_Spam(base uintptr) (_ SwigcptrSpam) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Spam, _swig_p) - return -} - -func NewSpam(arg1 Foo) (_swig_ret Spam) { - return _swig_wrap_new_Spam(arg1.Swigcptr()) -} - -var _wrap_Spam___deref__ unsafe.Pointer - -func _swig_wrap_Spam___deref__(base SwigcptrSpam) (_ SwigcptrFoo) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Spam___deref__, _swig_p) - return -} - -func (arg1 SwigcptrSpam) X__deref__() (_swig_ret Foo) { - return _swig_wrap_Spam___deref__(arg1) -} - -var _wrap_delete_Spam unsafe.Pointer - -func _swig_wrap_delete_Spam(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Spam, _swig_p) - return -} - -func DeleteSpam(arg1 Spam) { - _swig_wrap_delete_Spam(arg1.Swigcptr()) -} - -type Spam interface { - Swigcptr() uintptr - SwigIsSpam() - X__deref__() (_swig_ret Foo) -} - -type SwigcptrGrok uintptr - -func (p SwigcptrGrok) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrGrok) SwigIsGrok() { -} - -var _wrap_new_Grok unsafe.Pointer - -func _swig_wrap_new_Grok(base uintptr) (_ SwigcptrGrok) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Grok, _swig_p) - return -} - -func NewGrok(arg1 Foo) (_swig_ret Grok) { - return _swig_wrap_new_Grok(arg1.Swigcptr()) -} - -var _wrap_Grok___deref__ unsafe.Pointer - -func _swig_wrap_Grok___deref__(base SwigcptrGrok) (_ SwigcptrFoo) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Grok___deref__, _swig_p) - return -} - -func (arg1 SwigcptrGrok) X__deref__() (_swig_ret Foo) { - return _swig_wrap_Grok___deref__(arg1) -} - -var _wrap_delete_Grok unsafe.Pointer - -func _swig_wrap_delete_Grok(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Grok, _swig_p) - return -} - -func DeleteGrok(arg1 Grok) { - _swig_wrap_delete_Grok(arg1.Swigcptr()) -} - -type Grok interface { - Swigcptr() uintptr - SwigIsGrok() - X__deref__() (_swig_ret Foo) -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/smart_pointer_overload.go b/Examples/test-suite/go/smart_pointer_overload.go deleted file mode 100644 index d90aea0ec..000000000 --- a/Examples/test-suite/go/smart_pointer_overload.go +++ /dev/null @@ -1,296 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../smart_pointer_overload.i - -package smart_pointer_overload - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrFoo uintptr - -func (p SwigcptrFoo) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrFoo) SwigIsFoo() { -} - -var _wrap_Foo_x_set unsafe.Pointer - -func _swig_wrap_Foo_x_set(base SwigcptrFoo, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_x_set, _swig_p) - return -} - -func (arg1 SwigcptrFoo) SetX(arg2 int) { - _swig_wrap_Foo_x_set(arg1, arg2) -} - -var _wrap_Foo_x_get unsafe.Pointer - -func _swig_wrap_Foo_x_get(base SwigcptrFoo) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_x_get, _swig_p) - return -} - -func (arg1 SwigcptrFoo) GetX() (_swig_ret int) { - return _swig_wrap_Foo_x_get(arg1) -} - -var _wrap_Foo_test__SWIG_0 unsafe.Pointer - -func _swig_wrap_Foo_test__SWIG_0(base SwigcptrFoo, _ int) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_test__SWIG_0, _swig_p) - return -} - -func (arg1 SwigcptrFoo) Test__SWIG_0(arg2 int) (_swig_ret int) { - return _swig_wrap_Foo_test__SWIG_0(arg1, arg2) -} - -var _wrap_Foo_test__SWIG_1 unsafe.Pointer - -func _swig_wrap_Foo_test__SWIG_1(base SwigcptrFoo, _ float64) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_test__SWIG_1, _swig_p) - return -} - -func (arg1 SwigcptrFoo) Test__SWIG_1(arg2 float64) (_swig_ret int) { - return _swig_wrap_Foo_test__SWIG_1(arg1, arg2) -} - -var _wrap_Foo_test__SWIG_2 unsafe.Pointer - -func _swig_wrap_Foo_test__SWIG_2(base SwigcptrFoo, _ string) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_test__SWIG_2, _swig_p) - return -} - -func (arg1 SwigcptrFoo) Test__SWIG_2(arg2 string) (_swig_ret int) { - return _swig_wrap_Foo_test__SWIG_2(arg1, arg2) -} - -func (p SwigcptrFoo) Test(a ...interface{}) int { - argc := len(a) - if argc == 1 { - if _, ok := a[0].(int); !ok { - goto check_1 - } - return p.Test__SWIG_0(a[0].(int)) - } -check_1: - if argc == 1 { - if _, ok := a[0].(float64); !ok { - goto check_2 - } - return p.Test__SWIG_1(a[0].(float64)) - } -check_2: - if argc == 1 { - return p.Test__SWIG_2(a[0].(string)) - } - panic("No match for overloaded function call") -} - -var _wrap_new_Foo unsafe.Pointer - -func _swig_wrap_new_Foo() (base SwigcptrFoo) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Foo, _swig_p) - return -} - -func NewFoo() (_swig_ret Foo) { - return _swig_wrap_new_Foo() -} - -var _wrap_delete_Foo unsafe.Pointer - -func _swig_wrap_delete_Foo(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Foo, _swig_p) - return -} - -func DeleteFoo(arg1 Foo) { - _swig_wrap_delete_Foo(arg1.Swigcptr()) -} - -type Foo interface { - Swigcptr() uintptr - SwigIsFoo() - SetX(arg2 int) - GetX() (_swig_ret int) - Test(a ...interface{}) int -} - -type SwigcptrBar uintptr - -func (p SwigcptrBar) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrBar) SwigIsBar() { -} - -var _wrap_new_Bar unsafe.Pointer - -func _swig_wrap_new_Bar(base uintptr) (_ SwigcptrBar) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Bar, _swig_p) - return -} - -func NewBar(arg1 Foo) (_swig_ret Bar) { - return _swig_wrap_new_Bar(arg1.Swigcptr()) -} - -var _wrap_Bar___deref__ unsafe.Pointer - -func _swig_wrap_Bar___deref__(base SwigcptrBar) (_ SwigcptrFoo) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Bar___deref__, _swig_p) - return -} - -func (arg1 SwigcptrBar) X__deref__() (_swig_ret Foo) { - return _swig_wrap_Bar___deref__(arg1) -} - -var _wrap_delete_Bar unsafe.Pointer - -func _swig_wrap_delete_Bar(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Bar, _swig_p) - return -} - -func DeleteBar(arg1 Bar) { - _swig_wrap_delete_Bar(arg1.Swigcptr()) -} - -var _wrap_Bar_x_set unsafe.Pointer - -func _swig_wrap_Bar_x_set(base SwigcptrBar, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Bar_x_set, _swig_p) - return -} - -func (arg1 SwigcptrBar) SetX(arg2 int) { - _swig_wrap_Bar_x_set(arg1, arg2) -} - -var _wrap_Bar_x_get unsafe.Pointer - -func _swig_wrap_Bar_x_get(base SwigcptrBar) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Bar_x_get, _swig_p) - return -} - -func (arg1 SwigcptrBar) GetX() (_swig_ret int) { - return _swig_wrap_Bar_x_get(arg1) -} - -var _wrap_Bar_test__SWIG_0 unsafe.Pointer - -func _swig_wrap_Bar_test__SWIG_0(base SwigcptrBar, _ int) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Bar_test__SWIG_0, _swig_p) - return -} - -func (arg1 SwigcptrBar) Test__SWIG_0(arg2 int) (_swig_ret int) { - return _swig_wrap_Bar_test__SWIG_0(arg1, arg2) -} - -var _wrap_Bar_test__SWIG_1 unsafe.Pointer - -func _swig_wrap_Bar_test__SWIG_1(base SwigcptrBar, _ float64) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Bar_test__SWIG_1, _swig_p) - return -} - -func (arg1 SwigcptrBar) Test__SWIG_1(arg2 float64) (_swig_ret int) { - return _swig_wrap_Bar_test__SWIG_1(arg1, arg2) -} - -var _wrap_Bar_test__SWIG_2 unsafe.Pointer - -func _swig_wrap_Bar_test__SWIG_2(base SwigcptrBar, _ string) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Bar_test__SWIG_2, _swig_p) - return -} - -func (arg1 SwigcptrBar) Test__SWIG_2(arg2 string) (_swig_ret int) { - return _swig_wrap_Bar_test__SWIG_2(arg1, arg2) -} - -func (p SwigcptrBar) Test(a ...interface{}) int { - argc := len(a) - if argc == 1 { - if _, ok := a[0].(int); !ok { - goto check_1 - } - return p.Test__SWIG_0(a[0].(int)) - } -check_1: - if argc == 1 { - if _, ok := a[0].(float64); !ok { - goto check_2 - } - return p.Test__SWIG_1(a[0].(float64)) - } -check_2: - if argc == 1 { - return p.Test__SWIG_2(a[0].(string)) - } - panic("No match for overloaded function call") -} - -type Bar interface { - Swigcptr() uintptr - SwigIsBar() - X__deref__() (_swig_ret Foo) - SetX(arg2 int) - GetX() (_swig_ret int) - Test(a ...interface{}) int -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/smart_pointer_overload_runme b/Examples/test-suite/go/smart_pointer_overload_runme deleted file mode 100755 index 6eb06c48d..000000000 Binary files a/Examples/test-suite/go/smart_pointer_overload_runme and /dev/null differ diff --git a/Examples/test-suite/go/smart_pointer_protected.go b/Examples/test-suite/go/smart_pointer_protected.go deleted file mode 100644 index 0003a5181..000000000 --- a/Examples/test-suite/go/smart_pointer_protected.go +++ /dev/null @@ -1,265 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../smart_pointer_protected.i - -package smart_pointer_protected - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrA uintptr - -func (p SwigcptrA) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrA) SwigIsA() { -} - -var _wrap_delete_A unsafe.Pointer - -func _swig_wrap_delete_A(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_A, _swig_p) - return -} - -func DeleteA(arg1 A) { - _swig_wrap_delete_A(arg1.Swigcptr()) -} - -var _wrap_A_value unsafe.Pointer - -func _swig_wrap_A_value(base SwigcptrA, _ uintptr) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_A_value, _swig_p) - return -} - -func (arg1 SwigcptrA) Value(arg2 A) (_swig_ret int) { - return _swig_wrap_A_value(arg1, arg2.Swigcptr()) -} - -var _wrap_A_index_set unsafe.Pointer - -func _swig_wrap_A_index_set(base SwigcptrA, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_A_index_set, _swig_p) - return -} - -func (arg1 SwigcptrA) SetIndex(arg2 int) { - _swig_wrap_A_index_set(arg1, arg2) -} - -var _wrap_A_index_get unsafe.Pointer - -func _swig_wrap_A_index_get(base SwigcptrA) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_A_index_get, _swig_p) - return -} - -func (arg1 SwigcptrA) GetIndex() (_swig_ret int) { - return _swig_wrap_A_index_get(arg1) -} - -type A interface { - Swigcptr() uintptr - SwigIsA() - Value(arg2 A) (_swig_ret int) - SetIndex(arg2 int) - GetIndex() (_swig_ret int) -} - -type SwigcptrB uintptr - -func (p SwigcptrB) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrB) SwigIsB() { -} - -var _wrap_new_B unsafe.Pointer - -func _swig_wrap_new_B() (base SwigcptrB) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_B, _swig_p) - return -} - -func NewB() (_swig_ret B) { - return _swig_wrap_new_B() -} - -var _wrap_delete_B unsafe.Pointer - -func _swig_wrap_delete_B(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_B, _swig_p) - return -} - -func DeleteB(arg1 B) { - _swig_wrap_delete_B(arg1.Swigcptr()) -} - -var _wrap_B_value unsafe.Pointer - -func _swig_wrap_B_value(base SwigcptrB, _ uintptr) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_B_value, _swig_p) - return -} - -func (_swig_base SwigcptrB) Value(arg1 A) (_swig_ret int) { - return _swig_wrap_B_value(_swig_base, arg1.Swigcptr()) -} - -var _wrap_SetB_Index unsafe.Pointer - -func _swig_wrap_SetB_Index(base SwigcptrB, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_SetB_Index, _swig_p) - return -} - -func (_swig_base SwigcptrB) SetIndex(arg1 int) { - _swig_wrap_SetB_Index(_swig_base, arg1) -} - -var _wrap_GetB_Index unsafe.Pointer - -func _swig_wrap_GetB_Index(base SwigcptrB) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_GetB_Index, _swig_p) - return -} - -func (_swig_base SwigcptrB) GetIndex() (_swig_ret int) { - return _swig_wrap_GetB_Index(_swig_base) -} - -func (p SwigcptrB) SwigIsA() { -} - -func (p SwigcptrB) SwigGetA() A { - return SwigcptrA(p.Swigcptr()) -} - -type B interface { - Swigcptr() uintptr - SwigIsB() - Value(arg1 A) (_swig_ret int) - SetIndex(arg1 int) - GetIndex() (_swig_ret int) - SwigIsA() - SwigGetA() A -} - -type SwigcptrC uintptr - -func (p SwigcptrC) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrC) SwigIsC() { -} - -var _wrap_C___deref__ unsafe.Pointer - -func _swig_wrap_C___deref__(base SwigcptrC) (_ SwigcptrB) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_C___deref__, _swig_p) - return -} - -func (arg1 SwigcptrC) X__deref__() (_swig_ret B) { - return _swig_wrap_C___deref__(arg1) -} - -var _wrap_new_C unsafe.Pointer - -func _swig_wrap_new_C() (base SwigcptrC) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_C, _swig_p) - return -} - -func NewC() (_swig_ret C) { - return _swig_wrap_new_C() -} - -var _wrap_delete_C unsafe.Pointer - -func _swig_wrap_delete_C(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_C, _swig_p) - return -} - -func DeleteC(arg1 C) { - _swig_wrap_delete_C(arg1.Swigcptr()) -} - -var _wrap_C_index_set unsafe.Pointer - -func _swig_wrap_C_index_set(base SwigcptrC, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_C_index_set, _swig_p) - return -} - -func (arg1 SwigcptrC) SetIndex(arg2 int) { - _swig_wrap_C_index_set(arg1, arg2) -} - -var _wrap_C_index_get unsafe.Pointer - -func _swig_wrap_C_index_get(base SwigcptrC) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_C_index_get, _swig_p) - return -} - -func (arg1 SwigcptrC) GetIndex() (_swig_ret int) { - return _swig_wrap_C_index_get(arg1) -} - -type C interface { - Swigcptr() uintptr - SwigIsC() - X__deref__() (_swig_ret B) - SetIndex(arg2 int) - GetIndex() (_swig_ret int) -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/smart_pointer_rename.go b/Examples/test-suite/go/smart_pointer_rename.go deleted file mode 100644 index 1f967df2b..000000000 --- a/Examples/test-suite/go/smart_pointer_rename.go +++ /dev/null @@ -1,191 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../smart_pointer_rename.i - -package smart_pointer_rename - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrFoo uintptr - -func (p SwigcptrFoo) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrFoo) SwigIsFoo() { -} - -var _wrap_Foo_ftest1 unsafe.Pointer - -func _swig_wrap_Foo_ftest1(base SwigcptrFoo, _ int) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_ftest1, _swig_p) - return -} - -func (arg1 SwigcptrFoo) Ftest1(arg2 int) (_swig_ret int) { - return _swig_wrap_Foo_ftest1(arg1, arg2) -} - -var _wrap_Foo_ftest2 unsafe.Pointer - -func _swig_wrap_Foo_ftest2(base SwigcptrFoo, _ int, _ int) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_ftest2, _swig_p) - return -} - -func (arg1 SwigcptrFoo) Ftest2(arg2 int, arg3 int) (_swig_ret int) { - return _swig_wrap_Foo_ftest2(arg1, arg2, arg3) -} - -var _wrap_new_Foo unsafe.Pointer - -func _swig_wrap_new_Foo() (base SwigcptrFoo) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Foo, _swig_p) - return -} - -func NewFoo() (_swig_ret Foo) { - return _swig_wrap_new_Foo() -} - -var _wrap_delete_Foo unsafe.Pointer - -func _swig_wrap_delete_Foo(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Foo, _swig_p) - return -} - -func DeleteFoo(arg1 Foo) { - _swig_wrap_delete_Foo(arg1.Swigcptr()) -} - -type Foo interface { - Swigcptr() uintptr - SwigIsFoo() - Ftest1(arg2 int) (_swig_ret int) - Ftest2(arg2 int, arg3 int) (_swig_ret int) -} - -type SwigcptrBar uintptr - -func (p SwigcptrBar) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrBar) SwigIsBar() { -} - -var _wrap_new_Bar unsafe.Pointer - -func _swig_wrap_new_Bar(base uintptr) (_ SwigcptrBar) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Bar, _swig_p) - return -} - -func NewBar(arg1 Foo) (_swig_ret Bar) { - return _swig_wrap_new_Bar(arg1.Swigcptr()) -} - -var _wrap_Bar___deref__ unsafe.Pointer - -func _swig_wrap_Bar___deref__(base SwigcptrBar) (_ SwigcptrFoo) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Bar___deref__, _swig_p) - return -} - -func (arg1 SwigcptrBar) X__deref__() (_swig_ret Foo) { - return _swig_wrap_Bar___deref__(arg1) -} - -var _wrap_Bar_test unsafe.Pointer - -func _swig_wrap_Bar_test(base SwigcptrBar) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Bar_test, _swig_p) - return -} - -func (arg1 SwigcptrBar) Test() (_swig_ret int) { - return _swig_wrap_Bar_test(arg1) -} - -var _wrap_delete_Bar unsafe.Pointer - -func _swig_wrap_delete_Bar(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Bar, _swig_p) - return -} - -func DeleteBar(arg1 Bar) { - _swig_wrap_delete_Bar(arg1.Swigcptr()) -} - -var _wrap_Bar_ftest1 unsafe.Pointer - -func _swig_wrap_Bar_ftest1(base SwigcptrBar, _ int) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Bar_ftest1, _swig_p) - return -} - -func (arg1 SwigcptrBar) Ftest1(arg2 int) (_swig_ret int) { - return _swig_wrap_Bar_ftest1(arg1, arg2) -} - -var _wrap_Bar_ftest2 unsafe.Pointer - -func _swig_wrap_Bar_ftest2(base SwigcptrBar, _ int, _ int) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Bar_ftest2, _swig_p) - return -} - -func (arg1 SwigcptrBar) Ftest2(arg2 int, arg3 int) (_swig_ret int) { - return _swig_wrap_Bar_ftest2(arg1, arg2, arg3) -} - -type Bar interface { - Swigcptr() uintptr - SwigIsBar() - X__deref__() (_swig_ret Foo) - Test() (_swig_ret int) - Ftest1(arg2 int) (_swig_ret int) - Ftest2(arg2 int, arg3 int) (_swig_ret int) -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/smart_pointer_rename_runme b/Examples/test-suite/go/smart_pointer_rename_runme deleted file mode 100755 index 6e712dd20..000000000 Binary files a/Examples/test-suite/go/smart_pointer_rename_runme and /dev/null differ diff --git a/Examples/test-suite/go/smart_pointer_simple.go b/Examples/test-suite/go/smart_pointer_simple.go deleted file mode 100644 index d3d5b934e..000000000 --- a/Examples/test-suite/go/smart_pointer_simple.go +++ /dev/null @@ -1,204 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../smart_pointer_simple.i - -package smart_pointer_simple - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrFoo uintptr - -func (p SwigcptrFoo) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrFoo) SwigIsFoo() { -} - -var _wrap_Foo_x_set unsafe.Pointer - -func _swig_wrap_Foo_x_set(base SwigcptrFoo, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_x_set, _swig_p) - return -} - -func (arg1 SwigcptrFoo) SetX(arg2 int) { - _swig_wrap_Foo_x_set(arg1, arg2) -} - -var _wrap_Foo_x_get unsafe.Pointer - -func _swig_wrap_Foo_x_get(base SwigcptrFoo) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_x_get, _swig_p) - return -} - -func (arg1 SwigcptrFoo) GetX() (_swig_ret int) { - return _swig_wrap_Foo_x_get(arg1) -} - -var _wrap_Foo_getx unsafe.Pointer - -func _swig_wrap_Foo_getx(base SwigcptrFoo) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_getx, _swig_p) - return -} - -func (arg1 SwigcptrFoo) Getx() (_swig_ret int) { - return _swig_wrap_Foo_getx(arg1) -} - -var _wrap_new_Foo unsafe.Pointer - -func _swig_wrap_new_Foo() (base SwigcptrFoo) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Foo, _swig_p) - return -} - -func NewFoo() (_swig_ret Foo) { - return _swig_wrap_new_Foo() -} - -var _wrap_delete_Foo unsafe.Pointer - -func _swig_wrap_delete_Foo(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Foo, _swig_p) - return -} - -func DeleteFoo(arg1 Foo) { - _swig_wrap_delete_Foo(arg1.Swigcptr()) -} - -type Foo interface { - Swigcptr() uintptr - SwigIsFoo() - SetX(arg2 int) - GetX() (_swig_ret int) - Getx() (_swig_ret int) -} - -type SwigcptrBar uintptr - -func (p SwigcptrBar) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrBar) SwigIsBar() { -} - -var _wrap_new_Bar unsafe.Pointer - -func _swig_wrap_new_Bar(base uintptr) (_ SwigcptrBar) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Bar, _swig_p) - return -} - -func NewBar(arg1 Foo) (_swig_ret Bar) { - return _swig_wrap_new_Bar(arg1.Swigcptr()) -} - -var _wrap_Bar___deref__ unsafe.Pointer - -func _swig_wrap_Bar___deref__(base SwigcptrBar) (_ SwigcptrFoo) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Bar___deref__, _swig_p) - return -} - -func (arg1 SwigcptrBar) X__deref__() (_swig_ret Foo) { - return _swig_wrap_Bar___deref__(arg1) -} - -var _wrap_delete_Bar unsafe.Pointer - -func _swig_wrap_delete_Bar(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Bar, _swig_p) - return -} - -func DeleteBar(arg1 Bar) { - _swig_wrap_delete_Bar(arg1.Swigcptr()) -} - -var _wrap_Bar_x_set unsafe.Pointer - -func _swig_wrap_Bar_x_set(base SwigcptrBar, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Bar_x_set, _swig_p) - return -} - -func (arg1 SwigcptrBar) SetX(arg2 int) { - _swig_wrap_Bar_x_set(arg1, arg2) -} - -var _wrap_Bar_x_get unsafe.Pointer - -func _swig_wrap_Bar_x_get(base SwigcptrBar) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Bar_x_get, _swig_p) - return -} - -func (arg1 SwigcptrBar) GetX() (_swig_ret int) { - return _swig_wrap_Bar_x_get(arg1) -} - -var _wrap_Bar_getx unsafe.Pointer - -func _swig_wrap_Bar_getx(base SwigcptrBar) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Bar_getx, _swig_p) - return -} - -func (arg1 SwigcptrBar) Getx() (_swig_ret int) { - return _swig_wrap_Bar_getx(arg1) -} - -type Bar interface { - Swigcptr() uintptr - SwigIsBar() - X__deref__() (_swig_ret Foo) - SetX(arg2 int) - GetX() (_swig_ret int) - Getx() (_swig_ret int) -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/smart_pointer_simple_runme b/Examples/test-suite/go/smart_pointer_simple_runme deleted file mode 100755 index b759a8c23..000000000 Binary files a/Examples/test-suite/go/smart_pointer_simple_runme and /dev/null differ diff --git a/Examples/test-suite/go/smart_pointer_static.go b/Examples/test-suite/go/smart_pointer_static.go deleted file mode 100644 index bf096a805..000000000 --- a/Examples/test-suite/go/smart_pointer_static.go +++ /dev/null @@ -1,196 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../smart_pointer_static.i - -package smart_pointer_static - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrMyHandle_Foo2 uintptr - -func (p SwigcptrMyHandle_Foo2) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrMyHandle_Foo2) SwigIsMyHandle_Foo2() { -} - -var _wrap_MyHandle_Foo2___deref__ unsafe.Pointer - -func _swig_wrap_MyHandle_Foo2___deref__(base SwigcptrMyHandle_Foo2) (_ SwigcptrFoo2) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_MyHandle_Foo2___deref__, _swig_p) - return -} - -func (arg1 SwigcptrMyHandle_Foo2) X__deref__() (_swig_ret Foo2) { - return _swig_wrap_MyHandle_Foo2___deref__(arg1) -} - -var _wrap_new_MyHandle_Foo2 unsafe.Pointer - -func _swig_wrap_new_MyHandle_Foo2() (base SwigcptrMyHandle_Foo2) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_MyHandle_Foo2, _swig_p) - return -} - -func NewMyHandle_Foo2() (_swig_ret MyHandle_Foo2) { - return _swig_wrap_new_MyHandle_Foo2() -} - -var _wrap_delete_MyHandle_Foo2 unsafe.Pointer - -func _swig_wrap_delete_MyHandle_Foo2(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_MyHandle_Foo2, _swig_p) - return -} - -func DeleteMyHandle_Foo2(arg1 MyHandle_Foo2) { - _swig_wrap_delete_MyHandle_Foo2(arg1.Swigcptr()) -} - -var _wrap_MyHandle_Foo2_sum__SWIG_0 unsafe.Pointer - -func _swig_wrap_MyHandle_Foo2_sum__SWIG_0(base SwigcptrMyHandle_Foo2, _ int, _ int) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_MyHandle_Foo2_sum__SWIG_0, _swig_p) - return -} - -func (arg1 SwigcptrMyHandle_Foo2) Sum__SWIG_0(arg2 int, arg3 int) (_swig_ret int) { - return _swig_wrap_MyHandle_Foo2_sum__SWIG_0(arg1, arg2, arg3) -} - -var _wrap_MyHandle_Foo2_sum__SWIG_1 unsafe.Pointer - -func _swig_wrap_MyHandle_Foo2_sum__SWIG_1(base SwigcptrMyHandle_Foo2, _ int, _ int, _ int) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_MyHandle_Foo2_sum__SWIG_1, _swig_p) - return -} - -func (arg1 SwigcptrMyHandle_Foo2) Sum__SWIG_1(arg2 int, arg3 int, arg4 int) (_swig_ret int) { - return _swig_wrap_MyHandle_Foo2_sum__SWIG_1(arg1, arg2, arg3, arg4) -} - -func (p SwigcptrMyHandle_Foo2) Sum(a ...interface{}) int { - argc := len(a) - if argc == 2 { - return p.Sum__SWIG_0(a[0].(int), a[1].(int)) - } - if argc == 3 { - return p.Sum__SWIG_1(a[0].(int), a[1].(int), a[2].(int)) - } - panic("No match for overloaded function call") -} - -type MyHandle_Foo2 interface { - Swigcptr() uintptr - SwigIsMyHandle_Foo2() - X__deref__() (_swig_ret Foo2) - Sum(a ...interface{}) int -} - -type SwigcptrFoo2 uintptr - -func (p SwigcptrFoo2) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrFoo2) SwigIsFoo2() { -} - -var _wrap_delete_Foo2 unsafe.Pointer - -func _swig_wrap_delete_Foo2(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Foo2, _swig_p) - return -} - -func DeleteFoo2(arg1 Foo2) { - _swig_wrap_delete_Foo2(arg1.Swigcptr()) -} - -var _wrap_Foo2_sum__SWIG_0 unsafe.Pointer - -func _swig_wrap_Foo2_sum__SWIG_0(base SwigcptrFoo2, _ int, _ int) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo2_sum__SWIG_0, _swig_p) - return -} - -func (arg1 SwigcptrFoo2) Sum__SWIG_0(arg2 int, arg3 int) (_swig_ret int) { - return _swig_wrap_Foo2_sum__SWIG_0(arg1, arg2, arg3) -} - -var _wrap_Foo2_sum__SWIG_1 unsafe.Pointer - -func Foo2Sum__SWIG_1(arg1 int, arg2 int, arg3 int) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_Foo2_sum__SWIG_1, _swig_p) - return -} -func Foo2Sum(a ...interface{}) int { - argc := len(a) - if argc == 3 { - if _, ok := a[0].(Foo2); !ok { - goto check_1 - } - return a[0].(SwigcptrFoo2).Sum__SWIG_0(a[1].(int), a[2].(int)) - } -check_1: - if argc == 3 { - return Foo2Sum__SWIG_1(a[0].(int), a[1].(int), a[2].(int)) - } - panic("No match for overloaded function call") -} - -var _wrap_new_Foo2 unsafe.Pointer - -func _swig_wrap_new_Foo2() (base SwigcptrFoo2) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Foo2, _swig_p) - return -} - -func NewFoo2() (_swig_ret Foo2) { - return _swig_wrap_new_Foo2() -} - -type Foo2 interface { - Swigcptr() uintptr - SwigIsFoo2() -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/smart_pointer_template_const_overload.go b/Examples/test-suite/go/smart_pointer_template_const_overload.go deleted file mode 100644 index 562b0c3ed..000000000 --- a/Examples/test-suite/go/smart_pointer_template_const_overload.go +++ /dev/null @@ -1,373 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../smart_pointer_template_const_overload.i - -package smart_pointer_template_const_overload - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrFooImplementation uintptr - -func (p SwigcptrFooImplementation) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrFooImplementation) SwigIsFooImplementation() { -} - -var _wrap_FooImplementation_mingy unsafe.Pointer - -func _swig_wrap_FooImplementation_mingy(base SwigcptrFooImplementation) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_FooImplementation_mingy, _swig_p) - return -} - -func (arg1 SwigcptrFooImplementation) Mingy() (_swig_ret int) { - return _swig_wrap_FooImplementation_mingy(arg1) -} - -var _wrap_FooImplementation_constmingy unsafe.Pointer - -func _swig_wrap_FooImplementation_constmingy(base SwigcptrFooImplementation) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_FooImplementation_constmingy, _swig_p) - return -} - -func (arg1 SwigcptrFooImplementation) Constmingy() (_swig_ret int) { - return _swig_wrap_FooImplementation_constmingy(arg1) -} - -var _wrap_FooImplementation_thingy unsafe.Pointer - -func FooImplementationThingy() (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_FooImplementation_thingy, _swig_p) - return -} -var _wrap_FooImplementation_svariable_set unsafe.Pointer - -func _swig_wrap_FooImplementation_svariable_set(base int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_FooImplementation_svariable_set, _swig_p) - return -} - -func SetFooImplementationSvariable(arg1 int) { - _swig_wrap_FooImplementation_svariable_set(arg1) -} - -var _wrap_FooImplementation_svariable_get unsafe.Pointer - -func GetFooImplementationSvariable() (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_FooImplementation_svariable_get, _swig_p) - return -} -var _wrap_FooImplementation_constsvariable_get unsafe.Pointer - -func GetFooImplementationConstsvariable() (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_FooImplementation_constsvariable_get, _swig_p) - return -} -var _wrap_FooImplementation_normalvariable_set unsafe.Pointer - -func _swig_wrap_FooImplementation_normalvariable_set(base SwigcptrFooImplementation, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_FooImplementation_normalvariable_set, _swig_p) - return -} - -func (arg1 SwigcptrFooImplementation) SetNormalvariable(arg2 int) { - _swig_wrap_FooImplementation_normalvariable_set(arg1, arg2) -} - -var _wrap_FooImplementation_normalvariable_get unsafe.Pointer - -func _swig_wrap_FooImplementation_normalvariable_get(base SwigcptrFooImplementation) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_FooImplementation_normalvariable_get, _swig_p) - return -} - -func (arg1 SwigcptrFooImplementation) GetNormalvariable() (_swig_ret int) { - return _swig_wrap_FooImplementation_normalvariable_get(arg1) -} - -var _wrap_new_FooImplementation unsafe.Pointer - -func _swig_wrap_new_FooImplementation() (base SwigcptrFooImplementation) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_FooImplementation, _swig_p) - return -} - -func NewFooImplementation() (_swig_ret FooImplementation) { - return _swig_wrap_new_FooImplementation() -} - -var _wrap_delete_FooImplementation unsafe.Pointer - -func _swig_wrap_delete_FooImplementation(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_FooImplementation, _swig_p) - return -} - -func DeleteFooImplementation(arg1 FooImplementation) { - _swig_wrap_delete_FooImplementation(arg1.Swigcptr()) -} - -type FooImplementation interface { - Swigcptr() uintptr - SwigIsFooImplementation() - Mingy() (_swig_ret int) - Constmingy() (_swig_ret int) - SetNormalvariable(arg2 int) - GetNormalvariable() (_swig_ret int) -} - -var _wrap_tester unsafe.Pointer - -func _swig_wrap_tester() { - var _swig_p uintptr - _cgo_runtime_cgocall(_wrap_tester, _swig_p) - return -} - -func Tester() { - _swig_wrap_tester() -} - -type SwigcptrFooSmartPointer uintptr - -func (p SwigcptrFooSmartPointer) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrFooSmartPointer) SwigIsFooSmartPointer() { -} - -var _wrap_new_FooSmartPointer__SWIG_0 unsafe.Pointer - -func _swig_wrap_new_FooSmartPointer__SWIG_0(base uintptr) (_ SwigcptrFooSmartPointer) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_FooSmartPointer__SWIG_0, _swig_p) - return -} - -func NewFooSmartPointer__SWIG_0(arg1 FooImplementation) (_swig_ret FooSmartPointer) { - return _swig_wrap_new_FooSmartPointer__SWIG_0(arg1.Swigcptr()) -} - -var _wrap_new_FooSmartPointer__SWIG_1 unsafe.Pointer - -func _swig_wrap_new_FooSmartPointer__SWIG_1() (base SwigcptrFooSmartPointer) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_FooSmartPointer__SWIG_1, _swig_p) - return -} - -func NewFooSmartPointer__SWIG_1() (_swig_ret FooSmartPointer) { - return _swig_wrap_new_FooSmartPointer__SWIG_1() -} - -func NewFooSmartPointer(a ...interface{}) FooSmartPointer { - argc := len(a) - if argc == 0 { - return NewFooSmartPointer__SWIG_1() - } - if argc == 1 { - return NewFooSmartPointer__SWIG_0(a[0].(FooImplementation)) - } - panic("No match for overloaded function call") -} - -var _wrap_FooSmartPointer___deref____SWIG_0 unsafe.Pointer - -func _swig_wrap_FooSmartPointer___deref____SWIG_0(base SwigcptrFooSmartPointer) (_ SwigcptrFooImplementation) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_FooSmartPointer___deref____SWIG_0, _swig_p) - return -} - -func (arg1 SwigcptrFooSmartPointer) X__deref____SWIG_0() (_swig_ret FooImplementation) { - return _swig_wrap_FooSmartPointer___deref____SWIG_0(arg1) -} - -var _wrap_FooSmartPointer___deref____SWIG_1 unsafe.Pointer - -func _swig_wrap_FooSmartPointer___deref____SWIG_1(base SwigcptrFooSmartPointer) (_ SwigcptrFooImplementation) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_FooSmartPointer___deref____SWIG_1, _swig_p) - return -} - -func (arg1 SwigcptrFooSmartPointer) X__deref____SWIG_1() (_swig_ret FooImplementation) { - return _swig_wrap_FooSmartPointer___deref____SWIG_1(arg1) -} - -func (p SwigcptrFooSmartPointer) X__deref__(a ...interface{}) interface{} { - argc := len(a) - if argc == 0 { - return p.X__deref____SWIG_0() - } - if argc == 0 { - return p.X__deref____SWIG_1() - } - panic("No match for overloaded function call") -} - -var _wrap_delete_FooSmartPointer unsafe.Pointer - -func _swig_wrap_delete_FooSmartPointer(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_FooSmartPointer, _swig_p) - return -} - -func DeleteFooSmartPointer(arg1 FooSmartPointer) { - _swig_wrap_delete_FooSmartPointer(arg1.Swigcptr()) -} - -var _wrap_FooSmartPointer_mingy unsafe.Pointer - -func _swig_wrap_FooSmartPointer_mingy(base SwigcptrFooSmartPointer) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_FooSmartPointer_mingy, _swig_p) - return -} - -func (arg1 SwigcptrFooSmartPointer) Mingy() (_swig_ret int) { - return _swig_wrap_FooSmartPointer_mingy(arg1) -} - -var _wrap_FooSmartPointer_constmingy unsafe.Pointer - -func _swig_wrap_FooSmartPointer_constmingy(base SwigcptrFooSmartPointer) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_FooSmartPointer_constmingy, _swig_p) - return -} - -func (arg1 SwigcptrFooSmartPointer) Constmingy() (_swig_ret int) { - return _swig_wrap_FooSmartPointer_constmingy(arg1) -} - -var _wrap_FooSmartPointer_thingy unsafe.Pointer - -func _swig_wrap_FooSmartPointer_thingy(base SwigcptrFooSmartPointer) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_FooSmartPointer_thingy, _swig_p) - return -} - -func (arg1 SwigcptrFooSmartPointer) Thingy() (_swig_ret int) { - return _swig_wrap_FooSmartPointer_thingy(arg1) -} - -var _wrap_FooSmartPointer_svariable_set unsafe.Pointer - -func _swig_wrap_FooSmartPointer_svariable_set(base SwigcptrFooSmartPointer, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_FooSmartPointer_svariable_set, _swig_p) - return -} - -func (arg1 SwigcptrFooSmartPointer) SetSvariable(arg2 int) { - _swig_wrap_FooSmartPointer_svariable_set(arg1, arg2) -} - -var _wrap_FooSmartPointer_svariable_get unsafe.Pointer - -func _swig_wrap_FooSmartPointer_svariable_get(base SwigcptrFooSmartPointer) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_FooSmartPointer_svariable_get, _swig_p) - return -} - -func (arg1 SwigcptrFooSmartPointer) GetSvariable() (_swig_ret int) { - return _swig_wrap_FooSmartPointer_svariable_get(arg1) -} - -var _wrap_FooSmartPointer_constsvariable_get unsafe.Pointer - -func _swig_wrap_FooSmartPointer_constsvariable_get(base SwigcptrFooSmartPointer) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_FooSmartPointer_constsvariable_get, _swig_p) - return -} - -func (arg1 SwigcptrFooSmartPointer) GetConstsvariable() (_swig_ret int) { - return _swig_wrap_FooSmartPointer_constsvariable_get(arg1) -} - -var _wrap_FooSmartPointer_normalvariable_set unsafe.Pointer - -func _swig_wrap_FooSmartPointer_normalvariable_set(base SwigcptrFooSmartPointer, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_FooSmartPointer_normalvariable_set, _swig_p) - return -} - -func (arg1 SwigcptrFooSmartPointer) SetNormalvariable(arg2 int) { - _swig_wrap_FooSmartPointer_normalvariable_set(arg1, arg2) -} - -var _wrap_FooSmartPointer_normalvariable_get unsafe.Pointer - -func _swig_wrap_FooSmartPointer_normalvariable_get(base SwigcptrFooSmartPointer) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_FooSmartPointer_normalvariable_get, _swig_p) - return -} - -func (arg1 SwigcptrFooSmartPointer) GetNormalvariable() (_swig_ret int) { - return _swig_wrap_FooSmartPointer_normalvariable_get(arg1) -} - -type FooSmartPointer interface { - Swigcptr() uintptr - SwigIsFooSmartPointer() - X__deref__(a ...interface{}) interface{} - Mingy() (_swig_ret int) - Constmingy() (_swig_ret int) - Thingy() (_swig_ret int) - SetSvariable(arg2 int) - GetSvariable() (_swig_ret int) - GetConstsvariable() (_swig_ret int) - SetNormalvariable(arg2 int) - GetNormalvariable() (_swig_ret int) -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/smart_pointer_template_defaults_overload.go b/Examples/test-suite/go/smart_pointer_template_defaults_overload.go deleted file mode 100644 index 1ac97b7be..000000000 --- a/Examples/test-suite/go/smart_pointer_template_defaults_overload.go +++ /dev/null @@ -1,748 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../smart_pointer_template_defaults_overload.i - -package smart_pointer_template_defaults_overload - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrStringDoubleMap uintptr - -func (p SwigcptrStringDoubleMap) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrStringDoubleMap) SwigIsStringDoubleMap() { -} - -var _wrap_new_StringDoubleMap__SWIG_0 unsafe.Pointer - -func _swig_wrap_new_StringDoubleMap__SWIG_0() (base SwigcptrStringDoubleMap) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_StringDoubleMap__SWIG_0, _swig_p) - return -} - -func NewStringDoubleMap__SWIG_0() (_swig_ret StringDoubleMap) { - return _swig_wrap_new_StringDoubleMap__SWIG_0() -} - -var _wrap_new_StringDoubleMap__SWIG_1 unsafe.Pointer - -func _swig_wrap_new_StringDoubleMap__SWIG_1(base uintptr) (_ SwigcptrStringDoubleMap) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_StringDoubleMap__SWIG_1, _swig_p) - return -} - -func NewStringDoubleMap__SWIG_1(arg1 StringDoubleMap) (_swig_ret StringDoubleMap) { - return _swig_wrap_new_StringDoubleMap__SWIG_1(arg1.Swigcptr()) -} - -func NewStringDoubleMap(a ...interface{}) StringDoubleMap { - argc := len(a) - if argc == 0 { - return NewStringDoubleMap__SWIG_0() - } - if argc == 1 { - return NewStringDoubleMap__SWIG_1(a[0].(StringDoubleMap)) - } - panic("No match for overloaded function call") -} - -var _wrap_StringDoubleMap_size unsafe.Pointer - -func _swig_wrap_StringDoubleMap_size(base SwigcptrStringDoubleMap) (_ uint) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_StringDoubleMap_size, _swig_p) - return -} - -func (arg1 SwigcptrStringDoubleMap) Size() (_swig_ret uint) { - return _swig_wrap_StringDoubleMap_size(arg1) -} - -var _wrap_StringDoubleMap_empty unsafe.Pointer - -func _swig_wrap_StringDoubleMap_empty(base SwigcptrStringDoubleMap) (_ bool) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_StringDoubleMap_empty, _swig_p) - return -} - -func (arg1 SwigcptrStringDoubleMap) Empty() (_swig_ret bool) { - return _swig_wrap_StringDoubleMap_empty(arg1) -} - -var _wrap_StringDoubleMap_clear unsafe.Pointer - -func _swig_wrap_StringDoubleMap_clear(base SwigcptrStringDoubleMap) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_StringDoubleMap_clear, _swig_p) - return -} - -func (arg1 SwigcptrStringDoubleMap) Clear() { - _swig_wrap_StringDoubleMap_clear(arg1) -} - -var _wrap_StringDoubleMap_get unsafe.Pointer - -func _swig_wrap_StringDoubleMap_get(base SwigcptrStringDoubleMap, _ string) (_ float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_StringDoubleMap_get, _swig_p) - return -} - -func (arg1 SwigcptrStringDoubleMap) Get(arg2 string) (_swig_ret float64) { - return _swig_wrap_StringDoubleMap_get(arg1, arg2) -} - -var _wrap_StringDoubleMap_set unsafe.Pointer - -func _swig_wrap_StringDoubleMap_set(base SwigcptrStringDoubleMap, _ string, _ float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_StringDoubleMap_set, _swig_p) - return -} - -func (arg1 SwigcptrStringDoubleMap) Set(arg2 string, arg3 float64) { - _swig_wrap_StringDoubleMap_set(arg1, arg2, arg3) -} - -var _wrap_StringDoubleMap_del unsafe.Pointer - -func _swig_wrap_StringDoubleMap_del(base SwigcptrStringDoubleMap, _ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_StringDoubleMap_del, _swig_p) - return -} - -func (arg1 SwigcptrStringDoubleMap) Del(arg2 string) { - _swig_wrap_StringDoubleMap_del(arg1, arg2) -} - -var _wrap_StringDoubleMap_has_key unsafe.Pointer - -func _swig_wrap_StringDoubleMap_has_key(base SwigcptrStringDoubleMap, _ string) (_ bool) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_StringDoubleMap_has_key, _swig_p) - return -} - -func (arg1 SwigcptrStringDoubleMap) Has_key(arg2 string) (_swig_ret bool) { - return _swig_wrap_StringDoubleMap_has_key(arg1, arg2) -} - -var _wrap_delete_StringDoubleMap unsafe.Pointer - -func _swig_wrap_delete_StringDoubleMap(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_StringDoubleMap, _swig_p) - return -} - -func DeleteStringDoubleMap(arg1 StringDoubleMap) { - _swig_wrap_delete_StringDoubleMap(arg1.Swigcptr()) -} - -type StringDoubleMap interface { - Swigcptr() uintptr - SwigIsStringDoubleMap() - Size() (_swig_ret uint) - Empty() (_swig_ret bool) - Clear() - Get(arg2 string) (_swig_ret float64) - Set(arg2 string, arg3 float64) - Del(arg2 string) - Has_key(arg2 string) (_swig_ret bool) -} - -type SwigcptrWrappedMap uintptr - -func (p SwigcptrWrappedMap) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrWrappedMap) SwigIsWrappedMap() { -} - -var _wrap_new_WrappedMap unsafe.Pointer - -func _swig_wrap_new_WrappedMap(base uintptr) (_ SwigcptrWrappedMap) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_WrappedMap, _swig_p) - return -} - -func NewWrappedMap(arg1 StringDoubleMap) (_swig_ret WrappedMap) { - return _swig_wrap_new_WrappedMap(arg1.Swigcptr()) -} - -var _wrap_WrappedMap___deref____SWIG_0 unsafe.Pointer - -func _swig_wrap_WrappedMap___deref____SWIG_0(base SwigcptrWrappedMap) (_ SwigcptrStringDoubleMap) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_WrappedMap___deref____SWIG_0, _swig_p) - return -} - -func (arg1 SwigcptrWrappedMap) X__deref____SWIG_0() (_swig_ret StringDoubleMap) { - return _swig_wrap_WrappedMap___deref____SWIG_0(arg1) -} - -var _wrap_WrappedMap___deref____SWIG_1 unsafe.Pointer - -func _swig_wrap_WrappedMap___deref____SWIG_1(base SwigcptrWrappedMap) (_ SwigcptrStringDoubleMap) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_WrappedMap___deref____SWIG_1, _swig_p) - return -} - -func (arg1 SwigcptrWrappedMap) X__deref____SWIG_1() (_swig_ret StringDoubleMap) { - return _swig_wrap_WrappedMap___deref____SWIG_1(arg1) -} - -func (p SwigcptrWrappedMap) X__deref__(a ...interface{}) interface{} { - argc := len(a) - if argc == 0 { - return p.X__deref____SWIG_0() - } - if argc == 0 { - return p.X__deref____SWIG_1() - } - panic("No match for overloaded function call") -} - -var _wrap_delete_WrappedMap unsafe.Pointer - -func _swig_wrap_delete_WrappedMap(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_WrappedMap, _swig_p) - return -} - -func DeleteWrappedMap(arg1 WrappedMap) { - _swig_wrap_delete_WrappedMap(arg1.Swigcptr()) -} - -var _wrap_WrappedMap_size unsafe.Pointer - -func _swig_wrap_WrappedMap_size(base SwigcptrWrappedMap) (_ uint) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_WrappedMap_size, _swig_p) - return -} - -func (arg1 SwigcptrWrappedMap) Size() (_swig_ret uint) { - return _swig_wrap_WrappedMap_size(arg1) -} - -var _wrap_WrappedMap_empty unsafe.Pointer - -func _swig_wrap_WrappedMap_empty(base SwigcptrWrappedMap) (_ bool) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_WrappedMap_empty, _swig_p) - return -} - -func (arg1 SwigcptrWrappedMap) Empty() (_swig_ret bool) { - return _swig_wrap_WrappedMap_empty(arg1) -} - -var _wrap_WrappedMap_clear unsafe.Pointer - -func _swig_wrap_WrappedMap_clear(base SwigcptrWrappedMap) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_WrappedMap_clear, _swig_p) - return -} - -func (arg1 SwigcptrWrappedMap) Clear() { - _swig_wrap_WrappedMap_clear(arg1) -} - -var _wrap_WrappedMap_get unsafe.Pointer - -func _swig_wrap_WrappedMap_get(base SwigcptrWrappedMap, _ string) (_ float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_WrappedMap_get, _swig_p) - return -} - -func (arg1 SwigcptrWrappedMap) Get(arg2 string) (_swig_ret float64) { - return _swig_wrap_WrappedMap_get(arg1, arg2) -} - -var _wrap_WrappedMap_set unsafe.Pointer - -func _swig_wrap_WrappedMap_set(base SwigcptrWrappedMap, _ string, _ float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_WrappedMap_set, _swig_p) - return -} - -func (arg1 SwigcptrWrappedMap) Set(arg2 string, arg3 float64) { - _swig_wrap_WrappedMap_set(arg1, arg2, arg3) -} - -var _wrap_WrappedMap_del unsafe.Pointer - -func _swig_wrap_WrappedMap_del(base SwigcptrWrappedMap, _ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_WrappedMap_del, _swig_p) - return -} - -func (arg1 SwigcptrWrappedMap) Del(arg2 string) { - _swig_wrap_WrappedMap_del(arg1, arg2) -} - -var _wrap_WrappedMap_has_key unsafe.Pointer - -func _swig_wrap_WrappedMap_has_key(base SwigcptrWrappedMap, _ string) (_ bool) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_WrappedMap_has_key, _swig_p) - return -} - -func (arg1 SwigcptrWrappedMap) Has_key(arg2 string) (_swig_ret bool) { - return _swig_wrap_WrappedMap_has_key(arg1, arg2) -} - -type WrappedMap interface { - Swigcptr() uintptr - SwigIsWrappedMap() - X__deref__(a ...interface{}) interface{} - Size() (_swig_ret uint) - Empty() (_swig_ret bool) - Clear() - Get(arg2 string) (_swig_ret float64) - Set(arg2 string, arg3 float64) - Del(arg2 string) - Has_key(arg2 string) (_swig_ret bool) -} - -type SwigcptrContainerInt uintptr - -func (p SwigcptrContainerInt) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrContainerInt) SwigIsContainerInt() { -} - -var _wrap_ContainerInt_rubout__SWIG_0 unsafe.Pointer - -func _swig_wrap_ContainerInt_rubout__SWIG_0(base SwigcptrContainerInt) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_ContainerInt_rubout__SWIG_0, _swig_p) - return -} - -func (arg1 SwigcptrContainerInt) Rubout__SWIG_0() (_swig_ret int) { - return _swig_wrap_ContainerInt_rubout__SWIG_0(arg1) -} - -var _wrap_ContainerInt_rubout__SWIG_1 unsafe.Pointer - -func _swig_wrap_ContainerInt_rubout__SWIG_1(base SwigcptrContainerInt, _ float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_ContainerInt_rubout__SWIG_1, _swig_p) - return -} - -func (arg1 SwigcptrContainerInt) Rubout__SWIG_1(arg2 float64) { - _swig_wrap_ContainerInt_rubout__SWIG_1(arg1, arg2) -} - -var _wrap_ContainerInt_factory__SWIG_0 unsafe.Pointer - -func _swig_wrap_ContainerInt_factory__SWIG_0() (base SwigcptrContainerInt) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_ContainerInt_factory__SWIG_0, _swig_p) - return -} - -func ContainerIntFactory__SWIG_0() (_swig_ret ContainerInt) { - return _swig_wrap_ContainerInt_factory__SWIG_0() -} - -var _wrap_ContainerInt_factory__SWIG_1 unsafe.Pointer - -func _swig_wrap_ContainerInt_factory__SWIG_1(base bool) (_ SwigcptrContainerInt) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_ContainerInt_factory__SWIG_1, _swig_p) - return -} - -func ContainerIntFactory__SWIG_1(arg1 bool) (_swig_ret ContainerInt) { - return _swig_wrap_ContainerInt_factory__SWIG_1(arg1) -} - -func ContainerIntFactory(a ...interface{}) ContainerInt { - argc := len(a) - if argc == 0 { - return ContainerIntFactory__SWIG_0() - } - if argc == 1 { - return ContainerIntFactory__SWIG_1(a[0].(bool)) - } - panic("No match for overloaded function call") -} - -var _wrap_ContainerInt_staticstuff unsafe.Pointer - -func _swig_wrap_ContainerInt_staticstuff(base bool) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_ContainerInt_staticstuff, _swig_p) - return -} - -func ContainerIntStaticstuff(arg1 bool) { - _swig_wrap_ContainerInt_staticstuff(arg1) -} - -var _wrap_ContainerInt_rubout__SWIG_2 unsafe.Pointer - -func _swig_wrap_ContainerInt_rubout__SWIG_2(base SwigcptrContainerInt, _ bool) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_ContainerInt_rubout__SWIG_2, _swig_p) - return -} - -func (arg1 SwigcptrContainerInt) Rubout__SWIG_2(arg2 bool) { - _swig_wrap_ContainerInt_rubout__SWIG_2(arg1, arg2) -} - -var _wrap_ContainerInt_rubout__SWIG_3 unsafe.Pointer - -func _swig_wrap_ContainerInt_rubout__SWIG_3(base SwigcptrContainerInt, _ int, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_ContainerInt_rubout__SWIG_3, _swig_p) - return -} - -func (arg1 SwigcptrContainerInt) Rubout__SWIG_3(arg2 int, arg3 int) { - _swig_wrap_ContainerInt_rubout__SWIG_3(arg1, arg2, arg3) -} - -var _wrap_ContainerInt_rubout__SWIG_4 unsafe.Pointer - -func _swig_wrap_ContainerInt_rubout__SWIG_4(base SwigcptrContainerInt, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_ContainerInt_rubout__SWIG_4, _swig_p) - return -} - -func (arg1 SwigcptrContainerInt) Rubout__SWIG_4(arg2 int) { - _swig_wrap_ContainerInt_rubout__SWIG_4(arg1, arg2) -} - -func (p SwigcptrContainerInt) Rubout(a ...interface{}) interface{} { - argc := len(a) - if argc == 0 { - return p.Rubout__SWIG_0() - } - if argc == 1 { - if _, ok := a[0].(bool); !ok { - goto check_2 - } - p.Rubout__SWIG_2(a[0].(bool)) - return 0 - } -check_2: - if argc == 1 { - if _, ok := a[0].(int); !ok { - goto check_3 - } - p.Rubout__SWIG_4(a[0].(int)) - return 0 - } -check_3: - if argc == 1 { - p.Rubout__SWIG_1(a[0].(float64)) - return 0 - } - if argc == 2 { - p.Rubout__SWIG_3(a[0].(int), a[1].(int)) - return 0 - } - panic("No match for overloaded function call") -} - -var _wrap_new_ContainerInt unsafe.Pointer - -func _swig_wrap_new_ContainerInt() (base SwigcptrContainerInt) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_ContainerInt, _swig_p) - return -} - -func NewContainerInt() (_swig_ret ContainerInt) { - return _swig_wrap_new_ContainerInt() -} - -var _wrap_delete_ContainerInt unsafe.Pointer - -func _swig_wrap_delete_ContainerInt(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_ContainerInt, _swig_p) - return -} - -func DeleteContainerInt(arg1 ContainerInt) { - _swig_wrap_delete_ContainerInt(arg1.Swigcptr()) -} - -type ContainerInt interface { - Swigcptr() uintptr - SwigIsContainerInt() - Rubout(a ...interface{}) interface{} -} - -type SwigcptrWrapContainerInt uintptr - -func (p SwigcptrWrapContainerInt) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrWrapContainerInt) SwigIsWrapContainerInt() { -} - -var _wrap_new_WrapContainerInt unsafe.Pointer - -func _swig_wrap_new_WrapContainerInt(base uintptr) (_ SwigcptrWrapContainerInt) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_WrapContainerInt, _swig_p) - return -} - -func NewWrapContainerInt(arg1 ContainerInt) (_swig_ret WrapContainerInt) { - return _swig_wrap_new_WrapContainerInt(arg1.Swigcptr()) -} - -var _wrap_WrapContainerInt___deref____SWIG_0 unsafe.Pointer - -func _swig_wrap_WrapContainerInt___deref____SWIG_0(base SwigcptrWrapContainerInt) (_ SwigcptrContainerInt) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_WrapContainerInt___deref____SWIG_0, _swig_p) - return -} - -func (arg1 SwigcptrWrapContainerInt) X__deref____SWIG_0() (_swig_ret ContainerInt) { - return _swig_wrap_WrapContainerInt___deref____SWIG_0(arg1) -} - -var _wrap_WrapContainerInt___deref____SWIG_1 unsafe.Pointer - -func _swig_wrap_WrapContainerInt___deref____SWIG_1(base SwigcptrWrapContainerInt) (_ SwigcptrContainerInt) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_WrapContainerInt___deref____SWIG_1, _swig_p) - return -} - -func (arg1 SwigcptrWrapContainerInt) X__deref____SWIG_1() (_swig_ret ContainerInt) { - return _swig_wrap_WrapContainerInt___deref____SWIG_1(arg1) -} - -func (p SwigcptrWrapContainerInt) X__deref__(a ...interface{}) interface{} { - argc := len(a) - if argc == 0 { - return p.X__deref____SWIG_0() - } - if argc == 0 { - return p.X__deref____SWIG_1() - } - panic("No match for overloaded function call") -} - -var _wrap_delete_WrapContainerInt unsafe.Pointer - -func _swig_wrap_delete_WrapContainerInt(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_WrapContainerInt, _swig_p) - return -} - -func DeleteWrapContainerInt(arg1 WrapContainerInt) { - _swig_wrap_delete_WrapContainerInt(arg1.Swigcptr()) -} - -var _wrap_WrapContainerInt_rubout__SWIG_0 unsafe.Pointer - -func _swig_wrap_WrapContainerInt_rubout__SWIG_0(base SwigcptrWrapContainerInt) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_WrapContainerInt_rubout__SWIG_0, _swig_p) - return -} - -func (arg1 SwigcptrWrapContainerInt) Rubout__SWIG_0() (_swig_ret int) { - return _swig_wrap_WrapContainerInt_rubout__SWIG_0(arg1) -} - -var _wrap_WrapContainerInt_rubout__SWIG_1 unsafe.Pointer - -func _swig_wrap_WrapContainerInt_rubout__SWIG_1(base SwigcptrWrapContainerInt, _ float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_WrapContainerInt_rubout__SWIG_1, _swig_p) - return -} - -func (arg1 SwigcptrWrapContainerInt) Rubout__SWIG_1(arg2 float64) { - _swig_wrap_WrapContainerInt_rubout__SWIG_1(arg1, arg2) -} - -var _wrap_WrapContainerInt_rubout__SWIG_2 unsafe.Pointer - -func _swig_wrap_WrapContainerInt_rubout__SWIG_2(base SwigcptrWrapContainerInt, _ bool) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_WrapContainerInt_rubout__SWIG_2, _swig_p) - return -} - -func (arg1 SwigcptrWrapContainerInt) Rubout__SWIG_2(arg2 bool) { - _swig_wrap_WrapContainerInt_rubout__SWIG_2(arg1, arg2) -} - -var _wrap_WrapContainerInt_rubout__SWIG_3 unsafe.Pointer - -func _swig_wrap_WrapContainerInt_rubout__SWIG_3(base SwigcptrWrapContainerInt, _ int, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_WrapContainerInt_rubout__SWIG_3, _swig_p) - return -} - -func (arg1 SwigcptrWrapContainerInt) Rubout__SWIG_3(arg2 int, arg3 int) { - _swig_wrap_WrapContainerInt_rubout__SWIG_3(arg1, arg2, arg3) -} - -var _wrap_WrapContainerInt_rubout__SWIG_4 unsafe.Pointer - -func _swig_wrap_WrapContainerInt_rubout__SWIG_4(base SwigcptrWrapContainerInt, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_WrapContainerInt_rubout__SWIG_4, _swig_p) - return -} - -func (arg1 SwigcptrWrapContainerInt) Rubout__SWIG_4(arg2 int) { - _swig_wrap_WrapContainerInt_rubout__SWIG_4(arg1, arg2) -} - -func (p SwigcptrWrapContainerInt) Rubout(a ...interface{}) interface{} { - argc := len(a) - if argc == 0 { - return p.Rubout__SWIG_0() - } - if argc == 1 { - if _, ok := a[0].(bool); !ok { - goto check_2 - } - p.Rubout__SWIG_2(a[0].(bool)) - return 0 - } -check_2: - if argc == 1 { - if _, ok := a[0].(int); !ok { - goto check_3 - } - p.Rubout__SWIG_4(a[0].(int)) - return 0 - } -check_3: - if argc == 1 { - p.Rubout__SWIG_1(a[0].(float64)) - return 0 - } - if argc == 2 { - p.Rubout__SWIG_3(a[0].(int), a[1].(int)) - return 0 - } - panic("No match for overloaded function call") -} - -var _wrap_WrapContainerInt_factory__SWIG_0 unsafe.Pointer - -func _swig_wrap_WrapContainerInt_factory__SWIG_0(base SwigcptrWrapContainerInt) (_ SwigcptrContainerInt) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_WrapContainerInt_factory__SWIG_0, _swig_p) - return -} - -func (arg1 SwigcptrWrapContainerInt) Factory__SWIG_0() (_swig_ret ContainerInt) { - return _swig_wrap_WrapContainerInt_factory__SWIG_0(arg1) -} - -var _wrap_WrapContainerInt_factory__SWIG_1 unsafe.Pointer - -func _swig_wrap_WrapContainerInt_factory__SWIG_1(base SwigcptrWrapContainerInt, _ bool) (_ SwigcptrContainerInt) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_WrapContainerInt_factory__SWIG_1, _swig_p) - return -} - -func (arg1 SwigcptrWrapContainerInt) Factory__SWIG_1(arg2 bool) (_swig_ret ContainerInt) { - return _swig_wrap_WrapContainerInt_factory__SWIG_1(arg1, arg2) -} - -func (p SwigcptrWrapContainerInt) Factory(a ...interface{}) ContainerInt { - argc := len(a) - if argc == 0 { - return p.Factory__SWIG_0() - } - if argc == 1 { - return p.Factory__SWIG_1(a[0].(bool)) - } - panic("No match for overloaded function call") -} - -var _wrap_WrapContainerInt_staticstuff unsafe.Pointer - -func _swig_wrap_WrapContainerInt_staticstuff(base SwigcptrWrapContainerInt, _ bool) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_WrapContainerInt_staticstuff, _swig_p) - return -} - -func (arg1 SwigcptrWrapContainerInt) Staticstuff(arg2 bool) { - _swig_wrap_WrapContainerInt_staticstuff(arg1, arg2) -} - -type WrapContainerInt interface { - Swigcptr() uintptr - SwigIsWrapContainerInt() - X__deref__(a ...interface{}) interface{} - Rubout(a ...interface{}) interface{} - Factory(a ...interface{}) ContainerInt - Staticstuff(arg2 bool) -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/smart_pointer_templatemethods.go b/Examples/test-suite/go/smart_pointer_templatemethods.go deleted file mode 100644 index 1fe3bd40c..000000000 --- a/Examples/test-suite/go/smart_pointer_templatemethods.go +++ /dev/null @@ -1,431 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../smart_pointer_templatemethods.i - -package smart_pointer_templatemethods - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrInterfaceId uintptr - -func (p SwigcptrInterfaceId) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrInterfaceId) SwigIsInterfaceId() { -} - -var _wrap_new_InterfaceId__SWIG_0 unsafe.Pointer - -func _swig_wrap_new_InterfaceId__SWIG_0(base uint16) (_ SwigcptrInterfaceId) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_InterfaceId__SWIG_0, _swig_p) - return -} - -func NewInterfaceId__SWIG_0(arg1 uint16) (_swig_ret InterfaceId) { - return _swig_wrap_new_InterfaceId__SWIG_0(arg1) -} - -var _wrap_new_InterfaceId__SWIG_1 unsafe.Pointer - -func _swig_wrap_new_InterfaceId__SWIG_1() (base SwigcptrInterfaceId) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_InterfaceId__SWIG_1, _swig_p) - return -} - -func NewInterfaceId__SWIG_1() (_swig_ret InterfaceId) { - return _swig_wrap_new_InterfaceId__SWIG_1() -} - -func NewInterfaceId(a ...interface{}) InterfaceId { - argc := len(a) - if argc == 0 { - return NewInterfaceId__SWIG_1() - } - if argc == 1 { - return NewInterfaceId__SWIG_0(a[0].(uint16)) - } - panic("No match for overloaded function call") -} - -var _wrap_delete_InterfaceId unsafe.Pointer - -func _swig_wrap_delete_InterfaceId(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_InterfaceId, _swig_p) - return -} - -func DeleteInterfaceId(arg1 InterfaceId) { - _swig_wrap_delete_InterfaceId(arg1.Swigcptr()) -} - -type InterfaceId interface { - Swigcptr() uintptr - SwigIsInterfaceId() -} - -type SwigcptrObjct uintptr - -func (p SwigcptrObjct) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrObjct) SwigIsObjct() { -} - -var _wrap_new_Objct unsafe.Pointer - -func _swig_wrap_new_Objct() (base SwigcptrObjct) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Objct, _swig_p) - return -} - -func NewObjct() (_swig_ret Objct) { - return _swig_wrap_new_Objct() -} - -var _wrap_delete_Objct unsafe.Pointer - -func _swig_wrap_delete_Objct(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Objct, _swig_p) - return -} - -func DeleteObjct(arg1 Objct) { - _swig_wrap_delete_Objct(arg1.Swigcptr()) -} - -var _wrap_Objct_DisposeObjct unsafe.Pointer - -func _swig_wrap_Objct_DisposeObjct(base SwigcptrObjct) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Objct_DisposeObjct, _swig_p) - return -} - -func (arg1 SwigcptrObjct) DisposeObjct() { - _swig_wrap_Objct_DisposeObjct(arg1) -} - -var _wrap_Objct_QueryInterfaceObjct unsafe.Pointer - -func _swig_wrap_Objct_QueryInterfaceObjct(base SwigcptrObjct, _ uintptr) (_ SwigcptrPtrObjct) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Objct_QueryInterfaceObjct, _swig_p) - return -} - -func (arg1 SwigcptrObjct) QueryInterfaceObjct(arg2 InterfaceId) (_swig_ret PtrObjct) { - return _swig_wrap_Objct_QueryInterfaceObjct(arg1, arg2.Swigcptr()) -} - -type Objct interface { - Swigcptr() uintptr - SwigIsObjct() - DisposeObjct() - QueryInterfaceObjct(arg2 InterfaceId) (_swig_ret PtrObjct) -} - -type SwigcptrPtrObjct uintptr - -func (p SwigcptrPtrObjct) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrPtrObjct) SwigIsPtrObjct() { -} - -var _wrap_new_PtrObjct unsafe.Pointer - -func _swig_wrap_new_PtrObjct() (base SwigcptrPtrObjct) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_PtrObjct, _swig_p) - return -} - -func NewPtrObjct() (_swig_ret PtrObjct) { - return _swig_wrap_new_PtrObjct() -} - -var _wrap_PtrObjct___deref__ unsafe.Pointer - -func _swig_wrap_PtrObjct___deref__(base SwigcptrPtrObjct) (_ SwigcptrObjct) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_PtrObjct___deref__, _swig_p) - return -} - -func (arg1 SwigcptrPtrObjct) X__deref__() (_swig_ret Objct) { - return _swig_wrap_PtrObjct___deref__(arg1) -} - -var _wrap_delete_PtrObjct unsafe.Pointer - -func _swig_wrap_delete_PtrObjct(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_PtrObjct, _swig_p) - return -} - -func DeletePtrObjct(arg1 PtrObjct) { - _swig_wrap_delete_PtrObjct(arg1.Swigcptr()) -} - -var _wrap_PtrObjct_DisposeObjct unsafe.Pointer - -func _swig_wrap_PtrObjct_DisposeObjct(base SwigcptrPtrObjct) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_PtrObjct_DisposeObjct, _swig_p) - return -} - -func (arg1 SwigcptrPtrObjct) DisposeObjct() { - _swig_wrap_PtrObjct_DisposeObjct(arg1) -} - -var _wrap_PtrObjct_QueryInterfaceObjct unsafe.Pointer - -func _swig_wrap_PtrObjct_QueryInterfaceObjct(base SwigcptrPtrObjct, _ uintptr) (_ SwigcptrPtrObjct) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_PtrObjct_QueryInterfaceObjct, _swig_p) - return -} - -func (arg1 SwigcptrPtrObjct) QueryInterfaceObjct(arg2 InterfaceId) (_swig_ret PtrObjct) { - return _swig_wrap_PtrObjct_QueryInterfaceObjct(arg1, arg2.Swigcptr()) -} - -type PtrObjct interface { - Swigcptr() uintptr - SwigIsPtrObjct() - X__deref__() (_swig_ret Objct) - DisposeObjct() - QueryInterfaceObjct(arg2 InterfaceId) (_swig_ret PtrObjct) -} - -type SwigcptrPtrInt uintptr - -func (p SwigcptrPtrInt) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrPtrInt) SwigIsPtrInt() { -} - -var _wrap_new_PtrInt unsafe.Pointer - -func _swig_wrap_new_PtrInt() (base SwigcptrPtrInt) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_PtrInt, _swig_p) - return -} - -func NewPtrInt() (_swig_ret PtrInt) { - return _swig_wrap_new_PtrInt() -} - -var _wrap_PtrInt___deref__ unsafe.Pointer - -func _swig_wrap_PtrInt___deref__(base SwigcptrPtrInt) (_ *int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_PtrInt___deref__, _swig_p) - return -} - -func (arg1 SwigcptrPtrInt) X__deref__() (_swig_ret *int) { - return _swig_wrap_PtrInt___deref__(arg1) -} - -var _wrap_delete_PtrInt unsafe.Pointer - -func _swig_wrap_delete_PtrInt(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_PtrInt, _swig_p) - return -} - -func DeletePtrInt(arg1 PtrInt) { - _swig_wrap_delete_PtrInt(arg1.Swigcptr()) -} - -type PtrInt interface { - Swigcptr() uintptr - SwigIsPtrInt() - X__deref__() (_swig_ret *int) -} - -type SwigcptrObjektInt uintptr - -func (p SwigcptrObjektInt) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrObjektInt) SwigIsObjektInt() { -} - -var _wrap_new_ObjektInt unsafe.Pointer - -func _swig_wrap_new_ObjektInt() (base SwigcptrObjektInt) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_ObjektInt, _swig_p) - return -} - -func NewObjektInt() (_swig_ret ObjektInt) { - return _swig_wrap_new_ObjektInt() -} - -var _wrap_delete_ObjektInt unsafe.Pointer - -func _swig_wrap_delete_ObjektInt(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_ObjektInt, _swig_p) - return -} - -func DeleteObjektInt(arg1 ObjektInt) { - _swig_wrap_delete_ObjektInt(arg1.Swigcptr()) -} - -var _wrap_ObjektInt_QueryInterface unsafe.Pointer - -func _swig_wrap_ObjektInt_QueryInterface(base SwigcptrObjektInt, _ uintptr) (_ SwigcptrPtrInt) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_ObjektInt_QueryInterface, _swig_p) - return -} - -func (arg1 SwigcptrObjektInt) QueryInterface(arg2 InterfaceId) (_swig_ret PtrInt) { - return _swig_wrap_ObjektInt_QueryInterface(arg1, arg2.Swigcptr()) -} - -var _wrap_ObjektInt_DisposeObjekt unsafe.Pointer - -func _swig_wrap_ObjektInt_DisposeObjekt(base SwigcptrObjektInt) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_ObjektInt_DisposeObjekt, _swig_p) - return -} - -func (arg1 SwigcptrObjektInt) DisposeObjekt() { - _swig_wrap_ObjektInt_DisposeObjekt(arg1) -} - -type ObjektInt interface { - Swigcptr() uintptr - SwigIsObjektInt() - QueryInterface(arg2 InterfaceId) (_swig_ret PtrInt) - DisposeObjekt() -} - -type SwigcptrPtrObjektInt uintptr - -func (p SwigcptrPtrObjektInt) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrPtrObjektInt) SwigIsPtrObjektInt() { -} - -var _wrap_new_PtrObjektInt unsafe.Pointer - -func _swig_wrap_new_PtrObjektInt() (base SwigcptrPtrObjektInt) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_PtrObjektInt, _swig_p) - return -} - -func NewPtrObjektInt() (_swig_ret PtrObjektInt) { - return _swig_wrap_new_PtrObjektInt() -} - -var _wrap_PtrObjektInt___deref__ unsafe.Pointer - -func _swig_wrap_PtrObjektInt___deref__(base SwigcptrPtrObjektInt) (_ SwigcptrObjektInt) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_PtrObjektInt___deref__, _swig_p) - return -} - -func (arg1 SwigcptrPtrObjektInt) X__deref__() (_swig_ret ObjektInt) { - return _swig_wrap_PtrObjektInt___deref__(arg1) -} - -var _wrap_delete_PtrObjektInt unsafe.Pointer - -func _swig_wrap_delete_PtrObjektInt(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_PtrObjektInt, _swig_p) - return -} - -func DeletePtrObjektInt(arg1 PtrObjektInt) { - _swig_wrap_delete_PtrObjektInt(arg1.Swigcptr()) -} - -var _wrap_PtrObjektInt_QueryInterface unsafe.Pointer - -func _swig_wrap_PtrObjektInt_QueryInterface(base SwigcptrPtrObjektInt, _ uintptr) (_ SwigcptrPtrInt) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_PtrObjektInt_QueryInterface, _swig_p) - return -} - -func (arg1 SwigcptrPtrObjektInt) QueryInterface(arg2 InterfaceId) (_swig_ret PtrInt) { - return _swig_wrap_PtrObjektInt_QueryInterface(arg1, arg2.Swigcptr()) -} - -var _wrap_PtrObjektInt_DisposeObjekt unsafe.Pointer - -func _swig_wrap_PtrObjektInt_DisposeObjekt(base SwigcptrPtrObjektInt) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_PtrObjektInt_DisposeObjekt, _swig_p) - return -} - -func (arg1 SwigcptrPtrObjektInt) DisposeObjekt() { - _swig_wrap_PtrObjektInt_DisposeObjekt(arg1) -} - -type PtrObjektInt interface { - Swigcptr() uintptr - SwigIsPtrObjektInt() - X__deref__() (_swig_ret ObjektInt) - QueryInterface(arg2 InterfaceId) (_swig_ret PtrInt) - DisposeObjekt() -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/smart_pointer_templatevariables.go b/Examples/test-suite/go/smart_pointer_templatevariables.go deleted file mode 100644 index 463d41287..000000000 --- a/Examples/test-suite/go/smart_pointer_templatevariables.go +++ /dev/null @@ -1,277 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../smart_pointer_templatevariables.i - -package smart_pointer_templatevariables - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -var _wrap_create unsafe.Pointer - -func _swig_wrap_create(base int, _ int16) (_ SwigcptrDiffImContainer_D) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_create, _swig_p) - return -} - -func Create(arg1 int, arg2 int16) (_swig_ret DiffImContainer_D) { - return _swig_wrap_create(arg1, arg2) -} - -type SwigcptrBasicString uintptr - -func (p SwigcptrBasicString) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrBasicString) SwigIsBasicString() { -} - -var _wrap_BasicString_npos_set unsafe.Pointer - -func _swig_wrap_BasicString_npos_set(base SwigcptrBasicString, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_BasicString_npos_set, _swig_p) - return -} - -func (arg1 SwigcptrBasicString) SetNpos(arg2 int) { - _swig_wrap_BasicString_npos_set(arg1, arg2) -} - -var _wrap_BasicString_npos_get unsafe.Pointer - -func _swig_wrap_BasicString_npos_get(base SwigcptrBasicString) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_BasicString_npos_get, _swig_p) - return -} - -func (arg1 SwigcptrBasicString) GetNpos() (_swig_ret int) { - return _swig_wrap_BasicString_npos_get(arg1) -} - -var _wrap_new_BasicString unsafe.Pointer - -func _swig_wrap_new_BasicString() (base SwigcptrBasicString) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_BasicString, _swig_p) - return -} - -func NewBasicString() (_swig_ret BasicString) { - return _swig_wrap_new_BasicString() -} - -var _wrap_delete_BasicString unsafe.Pointer - -func _swig_wrap_delete_BasicString(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_BasicString, _swig_p) - return -} - -func DeleteBasicString(arg1 BasicString) { - _swig_wrap_delete_BasicString(arg1.Swigcptr()) -} - -type BasicString interface { - Swigcptr() uintptr - SwigIsBasicString() - SetNpos(arg2 int) - GetNpos() (_swig_ret int) -} - -type SwigcptrDiffImContainer_D uintptr - -func (p SwigcptrDiffImContainer_D) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrDiffImContainer_D) SwigIsDiffImContainer_D() { -} - -var _wrap_DiffImContainer_D_id_set unsafe.Pointer - -func _swig_wrap_DiffImContainer_D_id_set(base SwigcptrDiffImContainer_D, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_DiffImContainer_D_id_set, _swig_p) - return -} - -func (arg1 SwigcptrDiffImContainer_D) SetId(arg2 int) { - _swig_wrap_DiffImContainer_D_id_set(arg1, arg2) -} - -var _wrap_DiffImContainer_D_id_get unsafe.Pointer - -func _swig_wrap_DiffImContainer_D_id_get(base SwigcptrDiffImContainer_D) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_DiffImContainer_D_id_get, _swig_p) - return -} - -func (arg1 SwigcptrDiffImContainer_D) GetId() (_swig_ret int) { - return _swig_wrap_DiffImContainer_D_id_get(arg1) -} - -var _wrap_new_DiffImContainer_D unsafe.Pointer - -func _swig_wrap_new_DiffImContainer_D() (base SwigcptrDiffImContainer_D) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_DiffImContainer_D, _swig_p) - return -} - -func NewDiffImContainer_D() (_swig_ret DiffImContainer_D) { - return _swig_wrap_new_DiffImContainer_D() -} - -var _wrap_delete_DiffImContainer_D unsafe.Pointer - -func _swig_wrap_delete_DiffImContainer_D(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_DiffImContainer_D, _swig_p) - return -} - -func DeleteDiffImContainer_D(arg1 DiffImContainer_D) { - _swig_wrap_delete_DiffImContainer_D(arg1.Swigcptr()) -} - -type DiffImContainer_D interface { - Swigcptr() uintptr - SwigIsDiffImContainer_D() - SetId(arg2 int) - GetId() (_swig_ret int) -} - -type SwigcptrDiffImContainerPtr_D uintptr - -func (p SwigcptrDiffImContainerPtr_D) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrDiffImContainerPtr_D) SwigIsDiffImContainerPtr_D() { -} - -var _wrap_new_DiffImContainerPtr_D__SWIG_0 unsafe.Pointer - -func _swig_wrap_new_DiffImContainerPtr_D__SWIG_0(base uintptr) (_ SwigcptrDiffImContainerPtr_D) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_DiffImContainerPtr_D__SWIG_0, _swig_p) - return -} - -func NewDiffImContainerPtr_D__SWIG_0(arg1 DiffImContainer_D) (_swig_ret DiffImContainerPtr_D) { - return _swig_wrap_new_DiffImContainerPtr_D__SWIG_0(arg1.Swigcptr()) -} - -var _wrap_new_DiffImContainerPtr_D__SWIG_1 unsafe.Pointer - -func _swig_wrap_new_DiffImContainerPtr_D__SWIG_1() (base SwigcptrDiffImContainerPtr_D) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_DiffImContainerPtr_D__SWIG_1, _swig_p) - return -} - -func NewDiffImContainerPtr_D__SWIG_1() (_swig_ret DiffImContainerPtr_D) { - return _swig_wrap_new_DiffImContainerPtr_D__SWIG_1() -} - -func NewDiffImContainerPtr_D(a ...interface{}) DiffImContainerPtr_D { - argc := len(a) - if argc == 0 { - return NewDiffImContainerPtr_D__SWIG_1() - } - if argc == 1 { - return NewDiffImContainerPtr_D__SWIG_0(a[0].(DiffImContainer_D)) - } - panic("No match for overloaded function call") -} - -var _wrap_delete_DiffImContainerPtr_D unsafe.Pointer - -func _swig_wrap_delete_DiffImContainerPtr_D(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_DiffImContainerPtr_D, _swig_p) - return -} - -func DeleteDiffImContainerPtr_D(arg1 DiffImContainerPtr_D) { - _swig_wrap_delete_DiffImContainerPtr_D(arg1.Swigcptr()) -} - -var _wrap_DiffImContainerPtr_D___deref__ unsafe.Pointer - -func _swig_wrap_DiffImContainerPtr_D___deref__(base SwigcptrDiffImContainerPtr_D) (_ SwigcptrDiffImContainer_D) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_DiffImContainerPtr_D___deref__, _swig_p) - return -} - -func (arg1 SwigcptrDiffImContainerPtr_D) X__deref__() (_swig_ret DiffImContainer_D) { - return _swig_wrap_DiffImContainerPtr_D___deref__(arg1) -} - -var _wrap_DiffImContainerPtr_D_id_set unsafe.Pointer - -func _swig_wrap_DiffImContainerPtr_D_id_set(base SwigcptrDiffImContainerPtr_D, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_DiffImContainerPtr_D_id_set, _swig_p) - return -} - -func (arg1 SwigcptrDiffImContainerPtr_D) SetId(arg2 int) { - _swig_wrap_DiffImContainerPtr_D_id_set(arg1, arg2) -} - -var _wrap_DiffImContainerPtr_D_id_get unsafe.Pointer - -func _swig_wrap_DiffImContainerPtr_D_id_get(base SwigcptrDiffImContainerPtr_D) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_DiffImContainerPtr_D_id_get, _swig_p) - return -} - -func (arg1 SwigcptrDiffImContainerPtr_D) GetId() (_swig_ret int) { - return _swig_wrap_DiffImContainerPtr_D_id_get(arg1) -} - -type DiffImContainerPtr_D interface { - Swigcptr() uintptr - SwigIsDiffImContainerPtr_D() - X__deref__() (_swig_ret DiffImContainer_D) - SetId(arg2 int) - GetId() (_swig_ret int) -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/smart_pointer_templatevariables_runme b/Examples/test-suite/go/smart_pointer_templatevariables_runme deleted file mode 100755 index e405cf1fd..000000000 Binary files a/Examples/test-suite/go/smart_pointer_templatevariables_runme and /dev/null differ diff --git a/Examples/test-suite/go/smart_pointer_typedef.go b/Examples/test-suite/go/smart_pointer_typedef.go deleted file mode 100644 index 78126f9ec..000000000 --- a/Examples/test-suite/go/smart_pointer_typedef.go +++ /dev/null @@ -1,204 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../smart_pointer_typedef.i - -package smart_pointer_typedef - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrFoo uintptr - -func (p SwigcptrFoo) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrFoo) SwigIsFoo() { -} - -var _wrap_Foo_x_set unsafe.Pointer - -func _swig_wrap_Foo_x_set(base SwigcptrFoo, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_x_set, _swig_p) - return -} - -func (arg1 SwigcptrFoo) SetX(arg2 int) { - _swig_wrap_Foo_x_set(arg1, arg2) -} - -var _wrap_Foo_x_get unsafe.Pointer - -func _swig_wrap_Foo_x_get(base SwigcptrFoo) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_x_get, _swig_p) - return -} - -func (arg1 SwigcptrFoo) GetX() (_swig_ret int) { - return _swig_wrap_Foo_x_get(arg1) -} - -var _wrap_Foo_getx unsafe.Pointer - -func _swig_wrap_Foo_getx(base SwigcptrFoo) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_getx, _swig_p) - return -} - -func (arg1 SwigcptrFoo) Getx() (_swig_ret int) { - return _swig_wrap_Foo_getx(arg1) -} - -var _wrap_new_Foo unsafe.Pointer - -func _swig_wrap_new_Foo() (base SwigcptrFoo) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Foo, _swig_p) - return -} - -func NewFoo() (_swig_ret Foo) { - return _swig_wrap_new_Foo() -} - -var _wrap_delete_Foo unsafe.Pointer - -func _swig_wrap_delete_Foo(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Foo, _swig_p) - return -} - -func DeleteFoo(arg1 Foo) { - _swig_wrap_delete_Foo(arg1.Swigcptr()) -} - -type Foo interface { - Swigcptr() uintptr - SwigIsFoo() - SetX(arg2 int) - GetX() (_swig_ret int) - Getx() (_swig_ret int) -} - -type SwigcptrBar uintptr - -func (p SwigcptrBar) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrBar) SwigIsBar() { -} - -var _wrap_new_Bar unsafe.Pointer - -func _swig_wrap_new_Bar(base uintptr) (_ SwigcptrBar) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Bar, _swig_p) - return -} - -func NewBar(arg1 Foo) (_swig_ret Bar) { - return _swig_wrap_new_Bar(arg1.Swigcptr()) -} - -var _wrap_Bar___deref__ unsafe.Pointer - -func _swig_wrap_Bar___deref__(base SwigcptrBar) (_ SwigcptrFoo) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Bar___deref__, _swig_p) - return -} - -func (arg1 SwigcptrBar) X__deref__() (_swig_ret Foo) { - return _swig_wrap_Bar___deref__(arg1) -} - -var _wrap_delete_Bar unsafe.Pointer - -func _swig_wrap_delete_Bar(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Bar, _swig_p) - return -} - -func DeleteBar(arg1 Bar) { - _swig_wrap_delete_Bar(arg1.Swigcptr()) -} - -var _wrap_Bar_x_set unsafe.Pointer - -func _swig_wrap_Bar_x_set(base SwigcptrBar, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Bar_x_set, _swig_p) - return -} - -func (arg1 SwigcptrBar) SetX(arg2 int) { - _swig_wrap_Bar_x_set(arg1, arg2) -} - -var _wrap_Bar_x_get unsafe.Pointer - -func _swig_wrap_Bar_x_get(base SwigcptrBar) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Bar_x_get, _swig_p) - return -} - -func (arg1 SwigcptrBar) GetX() (_swig_ret int) { - return _swig_wrap_Bar_x_get(arg1) -} - -var _wrap_Bar_getx unsafe.Pointer - -func _swig_wrap_Bar_getx(base SwigcptrBar) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Bar_getx, _swig_p) - return -} - -func (arg1 SwigcptrBar) Getx() (_swig_ret int) { - return _swig_wrap_Bar_getx(arg1) -} - -type Bar interface { - Swigcptr() uintptr - SwigIsBar() - X__deref__() (_swig_ret Foo) - SetX(arg2 int) - GetX() (_swig_ret int) - Getx() (_swig_ret int) -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/smart_pointer_typedef_runme b/Examples/test-suite/go/smart_pointer_typedef_runme deleted file mode 100755 index 0e25d343e..000000000 Binary files a/Examples/test-suite/go/smart_pointer_typedef_runme and /dev/null differ diff --git a/Examples/test-suite/go/sneaky1.go b/Examples/test-suite/go/sneaky1.go deleted file mode 100644 index d2791da28..000000000 --- a/Examples/test-suite/go/sneaky1.go +++ /dev/null @@ -1,57 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../sneaky1.i - -package sneaky1 - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -var _wrap_add unsafe.Pointer - -func Add(arg1 int, arg2 int) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_add, _swig_p) - return -} -var _wrap_subtract unsafe.Pointer - -func Subtract(arg1 int, arg2 int) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_subtract, _swig_p) - return -} -var _wrap_mul unsafe.Pointer - -func Mul(arg1 int, arg2 int) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_mul, _swig_p) - return -} -var _wrap_divide unsafe.Pointer - -func Divide(arg1 int, arg2 int) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_divide, _swig_p) - return -} - diff --git a/Examples/test-suite/go/sneaky1_runme b/Examples/test-suite/go/sneaky1_runme deleted file mode 100755 index 744553450..000000000 Binary files a/Examples/test-suite/go/sneaky1_runme and /dev/null differ diff --git a/Examples/test-suite/go/special_variable_macros.go b/Examples/test-suite/go/special_variable_macros.go deleted file mode 100644 index 913fdbb8b..000000000 --- a/Examples/test-suite/go/special_variable_macros.go +++ /dev/null @@ -1,414 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../special_variable_macros.i - -package special_variable_macros - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrName uintptr - -func (p SwigcptrName) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrName) SwigIsName() { -} - -var _wrap_new_Name__SWIG_0 unsafe.Pointer - -func _swig_wrap_new_Name__SWIG_0(base string) (_ SwigcptrName) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Name__SWIG_0, _swig_p) - return -} - -func NewName__SWIG_0(arg1 string) (_swig_ret Name) { - return _swig_wrap_new_Name__SWIG_0(arg1) -} - -var _wrap_new_Name__SWIG_1 unsafe.Pointer - -func _swig_wrap_new_Name__SWIG_1() (base SwigcptrName) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Name__SWIG_1, _swig_p) - return -} - -func NewName__SWIG_1() (_swig_ret Name) { - return _swig_wrap_new_Name__SWIG_1() -} - -var _wrap_new_Name__SWIG_2 unsafe.Pointer - -func _swig_wrap_new_Name__SWIG_2(base uintptr) (_ SwigcptrName) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Name__SWIG_2, _swig_p) - return -} - -func NewName__SWIG_2(arg1 Name) (_swig_ret Name) { - return _swig_wrap_new_Name__SWIG_2(arg1.Swigcptr()) -} - -func NewName(a ...interface{}) Name { - argc := len(a) - if argc == 0 { - return NewName__SWIG_1() - } - if argc == 1 { - if _, ok := a[0].(Name); !ok { - goto check_2 - } - return NewName__SWIG_2(a[0].(Name)) - } -check_2: - if argc == 1 { - return NewName__SWIG_0(a[0].(string)) - } - panic("No match for overloaded function call") -} - -var _wrap_delete_Name unsafe.Pointer - -func _swig_wrap_delete_Name(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Name, _swig_p) - return -} - -func DeleteName(arg1 Name) { - _swig_wrap_delete_Name(arg1.Swigcptr()) -} - -var _wrap_Name_getName unsafe.Pointer - -func _swig_wrap_Name_getName(base SwigcptrName) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Name_getName, _swig_p) - return -} - -func (arg1 SwigcptrName) GetName() (_swig_ret string) { - return _swig_wrap_Name_getName(arg1) -} - -var _wrap_Name_getNamePtr unsafe.Pointer - -func _swig_wrap_Name_getNamePtr(base SwigcptrName) (_ SwigcptrName) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Name_getNamePtr, _swig_p) - return -} - -func (arg1 SwigcptrName) GetNamePtr() (_swig_ret Name) { - return _swig_wrap_Name_getNamePtr(arg1) -} - -type Name interface { - Swigcptr() uintptr - SwigIsName() - GetName() (_swig_ret string) - GetNamePtr() (_swig_ret Name) -} - -type SwigcptrNameWrap uintptr - -func (p SwigcptrNameWrap) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrNameWrap) SwigIsNameWrap() { -} - -var _wrap_new_NameWrap__SWIG_0 unsafe.Pointer - -func _swig_wrap_new_NameWrap__SWIG_0(base string) (_ SwigcptrNameWrap) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_NameWrap__SWIG_0, _swig_p) - return -} - -func NewNameWrap__SWIG_0(arg1 string) (_swig_ret NameWrap) { - return _swig_wrap_new_NameWrap__SWIG_0(arg1) -} - -var _wrap_new_NameWrap__SWIG_1 unsafe.Pointer - -func _swig_wrap_new_NameWrap__SWIG_1() (base SwigcptrNameWrap) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_NameWrap__SWIG_1, _swig_p) - return -} - -func NewNameWrap__SWIG_1() (_swig_ret NameWrap) { - return _swig_wrap_new_NameWrap__SWIG_1() -} - -func NewNameWrap(a ...interface{}) NameWrap { - argc := len(a) - if argc == 0 { - return NewNameWrap__SWIG_1() - } - if argc == 1 { - return NewNameWrap__SWIG_0(a[0].(string)) - } - panic("No match for overloaded function call") -} - -var _wrap_NameWrap_getNamePtr unsafe.Pointer - -func _swig_wrap_NameWrap_getNamePtr(base SwigcptrNameWrap) (_ SwigcptrName) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_NameWrap_getNamePtr, _swig_p) - return -} - -func (arg1 SwigcptrNameWrap) GetNamePtr() (_swig_ret Name) { - return _swig_wrap_NameWrap_getNamePtr(arg1) -} - -var _wrap_delete_NameWrap unsafe.Pointer - -func _swig_wrap_delete_NameWrap(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_NameWrap, _swig_p) - return -} - -func DeleteNameWrap(arg1 NameWrap) { - _swig_wrap_delete_NameWrap(arg1.Swigcptr()) -} - -type NameWrap interface { - Swigcptr() uintptr - SwigIsNameWrap() - GetNamePtr() (_swig_ret Name) -} - -var _wrap_testFred unsafe.Pointer - -func _swig_wrap_testFred(base uintptr) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_testFred, _swig_p) - return -} - -func TestFred(arg1 Name) (_swig_ret string) { - return _swig_wrap_testFred(arg1.Swigcptr()) -} - -var _wrap_testJack unsafe.Pointer - -func _swig_wrap_testJack(base uintptr) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_testJack, _swig_p) - return -} - -func TestJack(arg1 Name) (_swig_ret string) { - return _swig_wrap_testJack(arg1.Swigcptr()) -} - -var _wrap_testJill unsafe.Pointer - -func _swig_wrap_testJill(base uintptr) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_testJill, _swig_p) - return -} - -func TestJill(arg1 Name) (_swig_ret string) { - return _swig_wrap_testJill(arg1.Swigcptr()) -} - -var _wrap_testMary unsafe.Pointer - -func _swig_wrap_testMary(base uintptr) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_testMary, _swig_p) - return -} - -func TestMary(arg1 Name) (_swig_ret string) { - return _swig_wrap_testMary(arg1.Swigcptr()) -} - -var _wrap_testJames unsafe.Pointer - -func _swig_wrap_testJames(base uintptr) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_testJames, _swig_p) - return -} - -func TestJames(arg1 Name) (_swig_ret string) { - return _swig_wrap_testJames(arg1.Swigcptr()) -} - -var _wrap_testJim unsafe.Pointer - -func _swig_wrap_testJim(base uintptr) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_testJim, _swig_p) - return -} - -func TestJim(arg1 Name) (_swig_ret string) { - return _swig_wrap_testJim(arg1.Swigcptr()) -} - -var _wrap_testJohn unsafe.Pointer - -func _swig_wrap_testJohn(base uintptr) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_testJohn, _swig_p) - return -} - -func TestJohn(arg1 PairIntBool) (_swig_ret int) { - return _swig_wrap_testJohn(arg1.Swigcptr()) -} - -type SwigcptrPairIntBool uintptr - -func (p SwigcptrPairIntBool) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrPairIntBool) SwigIsPairIntBool() { -} - -var _wrap_new_PairIntBool__SWIG_0 unsafe.Pointer - -func _swig_wrap_new_PairIntBool__SWIG_0(base int, _ bool) (_ SwigcptrPairIntBool) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_PairIntBool__SWIG_0, _swig_p) - return -} - -func NewPairIntBool__SWIG_0(arg1 int, arg2 bool) (_swig_ret PairIntBool) { - return _swig_wrap_new_PairIntBool__SWIG_0(arg1, arg2) -} - -var _wrap_new_PairIntBool__SWIG_1 unsafe.Pointer - -func _swig_wrap_new_PairIntBool__SWIG_1() (base SwigcptrPairIntBool) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_PairIntBool__SWIG_1, _swig_p) - return -} - -func NewPairIntBool__SWIG_1() (_swig_ret PairIntBool) { - return _swig_wrap_new_PairIntBool__SWIG_1() -} - -func NewPairIntBool(a ...interface{}) PairIntBool { - argc := len(a) - if argc == 0 { - return NewPairIntBool__SWIG_1() - } - if argc == 2 { - return NewPairIntBool__SWIG_0(a[0].(int), a[1].(bool)) - } - panic("No match for overloaded function call") -} - -var _wrap_PairIntBool_first_set unsafe.Pointer - -func _swig_wrap_PairIntBool_first_set(base SwigcptrPairIntBool, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_PairIntBool_first_set, _swig_p) - return -} - -func (arg1 SwigcptrPairIntBool) SetFirst(arg2 int) { - _swig_wrap_PairIntBool_first_set(arg1, arg2) -} - -var _wrap_PairIntBool_first_get unsafe.Pointer - -func _swig_wrap_PairIntBool_first_get(base SwigcptrPairIntBool) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_PairIntBool_first_get, _swig_p) - return -} - -func (arg1 SwigcptrPairIntBool) GetFirst() (_swig_ret int) { - return _swig_wrap_PairIntBool_first_get(arg1) -} - -var _wrap_PairIntBool_second_set unsafe.Pointer - -func _swig_wrap_PairIntBool_second_set(base SwigcptrPairIntBool, _ bool) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_PairIntBool_second_set, _swig_p) - return -} - -func (arg1 SwigcptrPairIntBool) SetSecond(arg2 bool) { - _swig_wrap_PairIntBool_second_set(arg1, arg2) -} - -var _wrap_PairIntBool_second_get unsafe.Pointer - -func _swig_wrap_PairIntBool_second_get(base SwigcptrPairIntBool) (_ bool) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_PairIntBool_second_get, _swig_p) - return -} - -func (arg1 SwigcptrPairIntBool) GetSecond() (_swig_ret bool) { - return _swig_wrap_PairIntBool_second_get(arg1) -} - -var _wrap_delete_PairIntBool unsafe.Pointer - -func _swig_wrap_delete_PairIntBool(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_PairIntBool, _swig_p) - return -} - -func DeletePairIntBool(arg1 PairIntBool) { - _swig_wrap_delete_PairIntBool(arg1.Swigcptr()) -} - -type PairIntBool interface { - Swigcptr() uintptr - SwigIsPairIntBool() - SetFirst(arg2 int) - GetFirst() (_swig_ret int) - SetSecond(arg2 bool) - GetSecond() (_swig_ret bool) -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/special_variable_macros_runme b/Examples/test-suite/go/special_variable_macros_runme deleted file mode 100755 index 397403867..000000000 Binary files a/Examples/test-suite/go/special_variable_macros_runme and /dev/null differ diff --git a/Examples/test-suite/go/special_variables.go b/Examples/test-suite/go/special_variables.go deleted file mode 100644 index 881ae38d6..000000000 --- a/Examples/test-suite/go/special_variables.go +++ /dev/null @@ -1,621 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../special_variables.i - -package special_variables - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -var _wrap_testmethod unsafe.Pointer - -func _swig_wrap_testmethod(base int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_testmethod, _swig_p) - return -} - -func Testmethod(arg1 int) { - _swig_wrap_testmethod(arg1) -} - -type SwigcptrKKK uintptr - -func (p SwigcptrKKK) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrKKK) SwigIsKKK() { -} - -var _wrap_KKK_testmethod unsafe.Pointer - -func _swig_wrap_KKK_testmethod(base SwigcptrKKK, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_KKK_testmethod, _swig_p) - return -} - -func (arg1 SwigcptrKKK) Testmethod(arg2 int) { - _swig_wrap_KKK_testmethod(arg1, arg2) -} - -var _wrap_KKK_teststaticmethod unsafe.Pointer - -func _swig_wrap_KKK_teststaticmethod(base int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_KKK_teststaticmethod, _swig_p) - return -} - -func KKKTeststaticmethod(arg1 int) { - _swig_wrap_KKK_teststaticmethod(arg1) -} - -var _wrap_new_KKK unsafe.Pointer - -func _swig_wrap_new_KKK() (base SwigcptrKKK) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_KKK, _swig_p) - return -} - -func NewKKK() (_swig_ret KKK) { - return _swig_wrap_new_KKK() -} - -var _wrap_delete_KKK unsafe.Pointer - -func _swig_wrap_delete_KKK(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_KKK, _swig_p) - return -} - -func DeleteKKK(arg1 KKK) { - _swig_wrap_delete_KKK(arg1.Swigcptr()) -} - -type KKK interface { - Swigcptr() uintptr - SwigIsKKK() - Testmethod(arg2 int) -} - -var _wrap_ExceptionVars unsafe.Pointer - -func ExceptionVars(arg1 float64, arg2 float64) (_swig_ret string) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_ExceptionVars, _swig_p) - return -} -var _wrap_overloadedmethod__SWIG_0 unsafe.Pointer - -func Overloadedmethod__SWIG_0(arg1 float64) (_swig_ret string) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_overloadedmethod__SWIG_0, _swig_p) - return -} -var _wrap_overloadedmethod__SWIG_1 unsafe.Pointer - -func Overloadedmethod__SWIG_1() (_swig_ret string) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_overloadedmethod__SWIG_1, _swig_p) - return -} -func Overloadedmethod(a ...interface{}) string { - argc := len(a) - if argc == 0 { - return Overloadedmethod__SWIG_1() - } - if argc == 1 { - return Overloadedmethod__SWIG_0(a[0].(float64)) - } - panic("No match for overloaded function call") -} - -var _wrap_declaration_set unsafe.Pointer - -func _swig_wrap_declaration_set(base string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_declaration_set, _swig_p) - return -} - -func SetDeclaration(arg1 string) { - _swig_wrap_declaration_set(arg1) -} - -var _wrap_declaration_get unsafe.Pointer - -func GetDeclaration() (_swig_ret string) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_declaration_get, _swig_p) - return -} -type SwigcptrABC uintptr - -func (p SwigcptrABC) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrABC) SwigIsABC() { -} - -var _wrap_new_ABC__SWIG_0 unsafe.Pointer - -func _swig_wrap_new_ABC__SWIG_0(base int, _ float64) (_ SwigcptrABC) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_ABC__SWIG_0, _swig_p) - return -} - -func NewABC__SWIG_0(arg1 int, arg2 float64) (_swig_ret ABC) { - return _swig_wrap_new_ABC__SWIG_0(arg1, arg2) -} - -var _wrap_new_ABC__SWIG_1 unsafe.Pointer - -func _swig_wrap_new_ABC__SWIG_1() (base SwigcptrABC) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_ABC__SWIG_1, _swig_p) - return -} - -func NewABC__SWIG_1() (_swig_ret ABC) { - return _swig_wrap_new_ABC__SWIG_1() -} - -func NewABC(a ...interface{}) ABC { - argc := len(a) - if argc == 0 { - return NewABC__SWIG_1() - } - if argc == 2 { - return NewABC__SWIG_0(a[0].(int), a[1].(float64)) - } - panic("No match for overloaded function call") -} - -var _wrap_ABC_staticmethod unsafe.Pointer - -func ABCStaticmethod(arg1 int, arg2 bool) (_swig_ret *int16) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_ABC_staticmethod, _swig_p) - return -} -var _wrap_ABC_instancemethod__SWIG_0 unsafe.Pointer - -func _swig_wrap_ABC_instancemethod__SWIG_0(base SwigcptrABC, _ int, _ bool) (_ *int16) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_ABC_instancemethod__SWIG_0, _swig_p) - return -} - -func (arg1 SwigcptrABC) Instancemethod__SWIG_0(arg2 int, arg3 bool) (_swig_ret *int16) { - return _swig_wrap_ABC_instancemethod__SWIG_0(arg1, arg2, arg3) -} - -var _wrap_ABC_instancemethod__SWIG_1 unsafe.Pointer - -func _swig_wrap_ABC_instancemethod__SWIG_1(base SwigcptrABC, _ int) (_ *int16) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_ABC_instancemethod__SWIG_1, _swig_p) - return -} - -func (arg1 SwigcptrABC) Instancemethod__SWIG_1(arg2 int) (_swig_ret *int16) { - return _swig_wrap_ABC_instancemethod__SWIG_1(arg1, arg2) -} - -func (p SwigcptrABC) Instancemethod(a ...interface{}) *int16 { - argc := len(a) - if argc == 1 { - return p.Instancemethod__SWIG_1(a[0].(int)) - } - if argc == 2 { - return p.Instancemethod__SWIG_0(a[0].(int), a[1].(bool)) - } - panic("No match for overloaded function call") -} - -var _wrap_ABC_constmethod unsafe.Pointer - -func _swig_wrap_ABC_constmethod(base SwigcptrABC, _ int) (_ *int16) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_ABC_constmethod, _swig_p) - return -} - -func (arg1 SwigcptrABC) Constmethod(arg2 int) (_swig_ret *int16) { - return _swig_wrap_ABC_constmethod(arg1, arg2) -} - -var _wrap_delete_ABC unsafe.Pointer - -func _swig_wrap_delete_ABC(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_ABC, _swig_p) - return -} - -func DeleteABC(arg1 ABC) { - _swig_wrap_delete_ABC(arg1.Swigcptr()) -} - -type ABC interface { - Swigcptr() uintptr - SwigIsABC() - Instancemethod(a ...interface{}) *int16 - Constmethod(arg2 int) (_swig_ret *int16) -} - -var _wrap_globtemplate unsafe.Pointer - -func _swig_wrap_globtemplate(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_globtemplate, _swig_p) - return -} - -func Globtemplate(arg1 TemplateABC) { - _swig_wrap_globtemplate(arg1.Swigcptr()) -} - -type SwigcptrTemplateABC uintptr - -func (p SwigcptrTemplateABC) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrTemplateABC) SwigIsTemplateABC() { -} - -var _wrap_TemplateABC_tmethod unsafe.Pointer - -func _swig_wrap_TemplateABC_tmethod(base SwigcptrTemplateABC, _ uintptr) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_TemplateABC_tmethod, _swig_p) - return -} - -func (arg1 SwigcptrTemplateABC) Tmethod(arg2 ABC) (_swig_ret string) { - return _swig_wrap_TemplateABC_tmethod(arg1, arg2.Swigcptr()) -} - -var _wrap_new_TemplateABC unsafe.Pointer - -func _swig_wrap_new_TemplateABC() (base SwigcptrTemplateABC) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_TemplateABC, _swig_p) - return -} - -func NewTemplateABC() (_swig_ret TemplateABC) { - return _swig_wrap_new_TemplateABC() -} - -var _wrap_delete_TemplateABC unsafe.Pointer - -func _swig_wrap_delete_TemplateABC(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_TemplateABC, _swig_p) - return -} - -func DeleteTemplateABC(arg1 TemplateABC) { - _swig_wrap_delete_TemplateABC(arg1.Swigcptr()) -} - -type TemplateABC interface { - Swigcptr() uintptr - SwigIsTemplateABC() - Tmethod(arg2 ABC) (_swig_ret string) -} - -var _wrap_director_testmethod unsafe.Pointer - -func _swig_wrap_director_testmethod(base int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_director_testmethod, _swig_p) - return -} - -func Director_testmethod(arg1 int) { - _swig_wrap_director_testmethod(arg1) -} - -type _swig_DirectorDirectorTest struct { - SwigcptrDirectorTest - v interface{} -} - -func (p *_swig_DirectorDirectorTest) Swigcptr() uintptr { - return p.SwigcptrDirectorTest.Swigcptr() -} - -func (p *_swig_DirectorDirectorTest) SwigIsDirectorTest() { -} - -func (p *_swig_DirectorDirectorTest) DirectorInterface() interface{} { - return p.v -} - -var _wrap__swig_NewDirectorDirectorTestDirectorTest unsafe.Pointer - -func _swig_NewDirectorDirectorTestDirectorTest(_swig_director *_swig_DirectorDirectorTest) (_swig_ret SwigcptrDirectorTest) { - _swig_p := uintptr(unsafe.Pointer(&_swig_director)) - _cgo_runtime_cgocall(_wrap__swig_NewDirectorDirectorTestDirectorTest, _swig_p) - return -} - -func NewDirectorDirectorTest(v interface{}) DirectorTest { - p := &_swig_DirectorDirectorTest{0, v} - p.SwigcptrDirectorTest = _swig_NewDirectorDirectorTestDirectorTest(p) - return p -} - -type _swig_DirectorInterfaceDirectorTestDirector_testmethod interface { - Director_testmethod(int) -} - -var _wrap__swig_DirectorDirectorTest_upcall_Director_testmethod unsafe.Pointer - -func _swig_wrap__swig_DirectorDirectorTest_upcall_Director_testmethod(_swig_ptr SwigcptrDirectorTest, _ int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) - _cgo_runtime_cgocall(_wrap__swig_DirectorDirectorTest_upcall_Director_testmethod, _swig_p) - return -} - -func (swig_p *_swig_DirectorDirectorTest) Director_testmethod(i int) { - if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceDirectorTestDirector_testmethod); swig_ok { - swig_g.Director_testmethod(i) - return - } - _swig_wrap__swig_DirectorDirectorTest_upcall_Director_testmethod(swig_p.SwigcptrDirectorTest, i) -} - -func DirectorDirectorTestDirector_testmethod(p DirectorTest, arg2 int) { - _swig_wrap__swig_DirectorDirectorTest_upcall_Director_testmethod(p.(*_swig_DirectorDirectorTest).SwigcptrDirectorTest, arg2) -} - -func Swig_DirectorDirectorTest_callback_director_testmethod(p *_swig_DirectorDirectorTest, arg2 int) { - p.Director_testmethod(arg2) -} - -var _wrap_DeleteDirectorDirectorTest unsafe.Pointer - -func _swig_wrap_DeleteDirectorDirectorTest(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_DeleteDirectorDirectorTest, _swig_p) - return -} - -func DeleteDirectorDirectorTest(arg1 DirectorTest) { - _swig_wrap_DeleteDirectorDirectorTest(arg1.Swigcptr()) -} - -func Swiggo_DeleteDirector_DirectorTest(p *_swig_DirectorDirectorTest) { - p.SwigcptrDirectorTest = 0 -} - -type SwigcptrDirectorTest uintptr - -func (p SwigcptrDirectorTest) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrDirectorTest) SwigIsDirectorTest() { -} - -func (p SwigcptrDirectorTest) DirectorInterface() interface{} { - return nil -} - -var _wrap_DirectorTest_director_testmethod unsafe.Pointer - -func _swig_wrap_DirectorTest_director_testmethod(base SwigcptrDirectorTest, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_DirectorTest_director_testmethod, _swig_p) - return -} - -func (arg1 SwigcptrDirectorTest) Director_testmethod(arg2 int) { - _swig_wrap_DirectorTest_director_testmethod(arg1, arg2) -} - -var _wrap_delete_DirectorTest unsafe.Pointer - -func _swig_wrap_delete_DirectorTest(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_DirectorTest, _swig_p) - return -} - -func DeleteDirectorTest(arg1 DirectorTest) { - _swig_wrap_delete_DirectorTest(arg1.Swigcptr()) -} - -var _wrap_new_DirectorTest unsafe.Pointer - -func _swig_wrap_new_DirectorTest() (base SwigcptrDirectorTest) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_DirectorTest, _swig_p) - return -} - -func NewDirectorTest() (_swig_ret DirectorTest) { - return _swig_wrap_new_DirectorTest() -} - -type DirectorTest interface { - Swigcptr() uintptr - SwigIsDirectorTest() - DirectorInterface() interface{} - Director_testmethod(arg2 int) -} - -type SwigcptrDEFNewName uintptr - -func (p SwigcptrDEFNewName) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrDEFNewName) SwigIsDEFNewName() { -} - -var _wrap_DEFNewName_instance_def unsafe.Pointer - -func _swig_wrap_DEFNewName_instance_def(base SwigcptrDEFNewName) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_DEFNewName_instance_def, _swig_p) - return -} - -func (arg1 SwigcptrDEFNewName) Instance_def() { - _swig_wrap_DEFNewName_instance_def(arg1) -} - -var _wrap_DEFNewName_static_def unsafe.Pointer - -func _swig_wrap_DEFNewName_static_def() { - var _swig_p uintptr - _cgo_runtime_cgocall(_wrap_DEFNewName_static_def, _swig_p) - return -} - -func DEFNewNameStatic_def() { - _swig_wrap_DEFNewName_static_def() -} - -var _wrap_new_DEFNewName unsafe.Pointer - -func _swig_wrap_new_DEFNewName() (base SwigcptrDEFNewName) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_DEFNewName, _swig_p) - return -} - -func NewDEFNewName() (_swig_ret DEFNewName) { - return _swig_wrap_new_DEFNewName() -} - -var _wrap_delete_DEFNewName unsafe.Pointer - -func _swig_wrap_delete_DEFNewName(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_DEFNewName, _swig_p) - return -} - -func DeleteDEFNewName(arg1 DEFNewName) { - _swig_wrap_delete_DEFNewName(arg1.Swigcptr()) -} - -var _wrap_DEFNewName_staticmethod unsafe.Pointer - -func DEFNewNameStaticmethod(arg1 int, arg2 bool) (_swig_ret *int16) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_DEFNewName_staticmethod, _swig_p) - return -} -var _wrap_DEFNewName_instancemethod__SWIG_0 unsafe.Pointer - -func _swig_wrap_DEFNewName_instancemethod__SWIG_0(base SwigcptrDEFNewName, _ int, _ bool) (_ *int16) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_DEFNewName_instancemethod__SWIG_0, _swig_p) - return -} - -func (_swig_base SwigcptrDEFNewName) Instancemethod__SWIG_0(arg1 int, arg2 bool) (_swig_ret *int16) { - return _swig_wrap_DEFNewName_instancemethod__SWIG_0(_swig_base, arg1, arg2) -} - -var _wrap_DEFNewName_instancemethod__SWIG_1 unsafe.Pointer - -func _swig_wrap_DEFNewName_instancemethod__SWIG_1(base SwigcptrDEFNewName, _ int) (_ *int16) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_DEFNewName_instancemethod__SWIG_1, _swig_p) - return -} - -func (_swig_base SwigcptrDEFNewName) Instancemethod__SWIG_1(arg1 int) (_swig_ret *int16) { - return _swig_wrap_DEFNewName_instancemethod__SWIG_1(_swig_base, arg1) -} - -func (p SwigcptrDEFNewName) Instancemethod(a ...interface{}) *int16 { - argc := len(a) - if argc == 1 { - return p.Instancemethod__SWIG_1(a[0].(int)) - } - if argc == 2 { - return p.Instancemethod__SWIG_0(a[0].(int), a[1].(bool)) - } - panic("No match for overloaded function call") -} - -var _wrap_DEFNewName_constmethod unsafe.Pointer - -func _swig_wrap_DEFNewName_constmethod(base SwigcptrDEFNewName, _ int) (_ *int16) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_DEFNewName_constmethod, _swig_p) - return -} - -func (_swig_base SwigcptrDEFNewName) Constmethod(arg1 int) (_swig_ret *int16) { - return _swig_wrap_DEFNewName_constmethod(_swig_base, arg1) -} - -func (p SwigcptrDEFNewName) SwigIsABC() { -} - -func (p SwigcptrDEFNewName) SwigGetABC() ABC { - return SwigcptrABC(p.Swigcptr()) -} - -type DEFNewName interface { - Swigcptr() uintptr - SwigIsDEFNewName() - Instance_def() - Instancemethod(a ...interface{}) *int16 - Constmethod(arg1 int) (_swig_ret *int16) - SwigIsABC() - SwigGetABC() ABC -} - - -type SwigcptrSwigDirector_DirectorTest uintptr -type SwigDirector_DirectorTest interface { - Swigcptr() uintptr; -} -func (p SwigcptrSwigDirector_DirectorTest) Swigcptr() uintptr { - return uintptr(p) -} - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/special_variables_wrap.h b/Examples/test-suite/go/special_variables_wrap.h deleted file mode 100644 index 09f9a0ced..000000000 --- a/Examples/test-suite/go/special_variables_wrap.h +++ /dev/null @@ -1,29 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../special_variables.i - -#ifndef SWIG_special_variables_WRAP_H_ -#define SWIG_special_variables_WRAP_H_ - -class SwigDirector_DirectorTest : public DirectorTest -{ - public: - SwigDirector_DirectorTest(void *swig_p); - void _swig_upcall_director_testmethod(int i) { - DirectorTest::director_testmethod(i); - } - virtual void director_testmethod(int i); - virtual ~SwigDirector_DirectorTest(); - private: - void *go_val; -}; - -#endif diff --git a/Examples/test-suite/go/static_array_member.go b/Examples/test-suite/go/static_array_member.go deleted file mode 100644 index ecb5b1015..000000000 --- a/Examples/test-suite/go/static_array_member.go +++ /dev/null @@ -1,75 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../static_array_member.i - -package static_array_member - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrRB uintptr - -func (p SwigcptrRB) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrRB) SwigIsRB() { -} - -var _wrap_new_RB unsafe.Pointer - -func _swig_wrap_new_RB() (base SwigcptrRB) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_RB, _swig_p) - return -} - -func NewRB() (_swig_ret RB) { - return _swig_wrap_new_RB() -} - -var _wrap_delete_RB unsafe.Pointer - -func _swig_wrap_delete_RB(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_RB, _swig_p) - return -} - -func DeleteRB(arg1 RB) { - _swig_wrap_delete_RB(arg1.Swigcptr()) -} - -type RB interface { - Swigcptr() uintptr - SwigIsRB() -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/static_const_member.go b/Examples/test-suite/go/static_const_member.go deleted file mode 100644 index 4be143258..000000000 --- a/Examples/test-suite/go/static_const_member.go +++ /dev/null @@ -1,107 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../static_const_member.i - -package static_const_member - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrX uintptr - -func (p SwigcptrX) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrX) SwigIsX() { -} - -var _wrap_X_PN_X unsafe.Pointer - -func _swig_getX_X_PN_X() (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_X_PN_X, _swig_p) - return -} -var XPN int = _swig_getX_X_PN_X() -var _wrap_X_CN_X unsafe.Pointer - -func _swig_getX_X_CN_X() (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_X_CN_X, _swig_p) - return -} -var XCN int = _swig_getX_X_CN_X() -var _wrap_X_EN_X unsafe.Pointer - -func _swig_getX_X_EN_X() (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_X_EN_X, _swig_p) - return -} -var XEN int = _swig_getX_X_EN_X() -var _wrap_X_CHARTEST_X unsafe.Pointer - -func _swig_getX_X_CHARTEST_X() (_swig_ret byte) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_X_CHARTEST_X, _swig_p) - return -} -var XCHARTEST byte = _swig_getX_X_CHARTEST_X() -var _wrap_new_X unsafe.Pointer - -func _swig_wrap_new_X() (base SwigcptrX) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_X, _swig_p) - return -} - -func NewX() (_swig_ret X) { - return _swig_wrap_new_X() -} - -var _wrap_delete_X unsafe.Pointer - -func _swig_wrap_delete_X(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_X, _swig_p) - return -} - -func DeleteX(arg1 X) { - _swig_wrap_delete_X(arg1.Swigcptr()) -} - -type X interface { - Swigcptr() uintptr - SwigIsX() -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/static_const_member_2.go b/Examples/test-suite/go/static_const_member_2.go deleted file mode 100644 index af4e91a6d..000000000 --- a/Examples/test-suite/go/static_const_member_2.go +++ /dev/null @@ -1,283 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../static_const_member_2.i - -package static_const_member_2 - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrCavityPackFlags uintptr - -func (p SwigcptrCavityPackFlags) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrCavityPackFlags) SwigIsCavityPackFlags() { -} - -var _wrap_CavityPackFlags_forward_field_CavityPackFlags unsafe.Pointer - -func _swig_getCavityPackFlags_CavityPackFlags_forward_field_CavityPackFlags() (_swig_ret uint) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_CavityPackFlags_forward_field_CavityPackFlags, _swig_p) - return -} -var CavityPackFlagsForward_field uint = _swig_getCavityPackFlags_CavityPackFlags_forward_field_CavityPackFlags() -var _wrap_CavityPackFlags_backward_field_CavityPackFlags unsafe.Pointer - -func _swig_getCavityPackFlags_CavityPackFlags_backward_field_CavityPackFlags() (_swig_ret uint) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_CavityPackFlags_backward_field_CavityPackFlags, _swig_p) - return -} -var CavityPackFlagsBackward_field uint = _swig_getCavityPackFlags_CavityPackFlags_backward_field_CavityPackFlags() -var _wrap_CavityPackFlags_cavity_flags_get unsafe.Pointer - -func GetCavityPackFlagsCavity_flags() (_swig_ret uint) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_CavityPackFlags_cavity_flags_get, _swig_p) - return -} -var _wrap_CavityPackFlags_flags_set unsafe.Pointer - -func _swig_wrap_CavityPackFlags_flags_set(base uint) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_CavityPackFlags_flags_set, _swig_p) - return -} - -func SetCavityPackFlagsFlags(arg1 uint) { - _swig_wrap_CavityPackFlags_flags_set(arg1) -} - -var _wrap_CavityPackFlags_flags_get unsafe.Pointer - -func GetCavityPackFlagsFlags() (_swig_ret uint) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_CavityPackFlags_flags_get, _swig_p) - return -} -var _wrap_CavityPackFlags_reftest_get unsafe.Pointer - -func GetCavityPackFlagsReftest() (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_CavityPackFlags_reftest_get, _swig_p) - return -} -var _wrap_new_CavityPackFlags unsafe.Pointer - -func _swig_wrap_new_CavityPackFlags() (base SwigcptrCavityPackFlags) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_CavityPackFlags, _swig_p) - return -} - -func NewCavityPackFlags() (_swig_ret CavityPackFlags) { - return _swig_wrap_new_CavityPackFlags() -} - -var _wrap_delete_CavityPackFlags unsafe.Pointer - -func _swig_wrap_delete_CavityPackFlags(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_CavityPackFlags, _swig_p) - return -} - -func DeleteCavityPackFlags(arg1 CavityPackFlags) { - _swig_wrap_delete_CavityPackFlags(arg1.Swigcptr()) -} - -type CavityPackFlags interface { - Swigcptr() uintptr - SwigIsCavityPackFlags() -} - -type SwigcptrTest_int uintptr - -func (p SwigcptrTest_int) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrTest_int) SwigIsTest_int() { -} - -var _wrap_LeftIndex_Test_int unsafe.Pointer - -func _swig_getTest_int_LeftIndex_Test_int() (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_LeftIndex_Test_int, _swig_p) - return -} -var Test_intLeftIndex int = _swig_getTest_int_LeftIndex_Test_int() -var _wrap_RightIndex_Test_int unsafe.Pointer - -func _swig_getTest_int_RightIndex_Test_int() (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_RightIndex_Test_int, _swig_p) - return -} -var Test_intRightIndex int = _swig_getTest_int_RightIndex_Test_int() -var _wrap_Test_int_current_profile_Test_int unsafe.Pointer - -func _swig_getTest_int_Test_int_current_profile_Test_int() (_swig_ret uint) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_Test_int_current_profile_Test_int, _swig_p) - return -} -var Test_intCurrent_profile uint = _swig_getTest_int_Test_int_current_profile_Test_int() -var _wrap_new_Test_int unsafe.Pointer - -func _swig_wrap_new_Test_int() (base SwigcptrTest_int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Test_int, _swig_p) - return -} - -func NewTest_int() (_swig_ret Test_int) { - return _swig_wrap_new_Test_int() -} - -var _wrap_delete_Test_int unsafe.Pointer - -func _swig_wrap_delete_Test_int(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Test_int, _swig_p) - return -} - -func DeleteTest_int(arg1 Test_int) { - _swig_wrap_delete_Test_int(arg1.Swigcptr()) -} - -func (p SwigcptrTest_int) SwigIsCavityPackFlags() { -} - -func (p SwigcptrTest_int) SwigGetCavityPackFlags() CavityPackFlags { - return SwigcptrCavityPackFlags(p.Swigcptr()) -} - -type Test_int interface { - Swigcptr() uintptr - SwigIsTest_int() - SwigIsCavityPackFlags() - SwigGetCavityPackFlags() CavityPackFlags -} - -type SwigcptrFoo uintptr - -func (p SwigcptrFoo) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrFoo) SwigIsFoo() { -} - -var _wrap_Foo_val_set unsafe.Pointer - -func _swig_wrap_Foo_val_set(base SwigcptrFoo, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_val_set, _swig_p) - return -} - -func (arg1 SwigcptrFoo) SetVal(arg2 int) { - _swig_wrap_Foo_val_set(arg1, arg2) -} - -var _wrap_Foo_val_get unsafe.Pointer - -func _swig_wrap_Foo_val_get(base SwigcptrFoo) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_val_get, _swig_p) - return -} - -func (arg1 SwigcptrFoo) GetVal() (_swig_ret int) { - return _swig_wrap_Foo_val_get(arg1) -} - -var _wrap_new_Foo unsafe.Pointer - -func _swig_wrap_new_Foo(base int) (_ SwigcptrFoo) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Foo, _swig_p) - return -} - -func NewFoo(arg1 int) (_swig_ret Foo) { - return _swig_wrap_new_Foo(arg1) -} - -var _wrap_Foo_BAR_get unsafe.Pointer - -func _swig_wrap_Foo_BAR_get() (base SwigcptrFoo) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_BAR_get, _swig_p) - return -} - -func GetFooBAR() (_swig_ret Foo) { - return _swig_wrap_Foo_BAR_get() -} - -var _wrap_Foo_BAZ_get unsafe.Pointer - -func _swig_wrap_Foo_BAZ_get() (base SwigcptrFoo) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_BAZ_get, _swig_p) - return -} - -func GetFooBAZ() (_swig_ret Foo) { - return _swig_wrap_Foo_BAZ_get() -} - -var _wrap_delete_Foo unsafe.Pointer - -func _swig_wrap_delete_Foo(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Foo, _swig_p) - return -} - -func DeleteFoo(arg1 Foo) { - _swig_wrap_delete_Foo(arg1.Swigcptr()) -} - -type Foo interface { - Swigcptr() uintptr - SwigIsFoo() - SetVal(arg2 int) - GetVal() (_swig_ret int) -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/static_const_member_2_runme b/Examples/test-suite/go/static_const_member_2_runme deleted file mode 100755 index 33dea6a0e..000000000 Binary files a/Examples/test-suite/go/static_const_member_2_runme and /dev/null differ diff --git a/Examples/test-suite/go/string_simple.go b/Examples/test-suite/go/string_simple.go deleted file mode 100644 index eccde2e30..000000000 --- a/Examples/test-suite/go/string_simple.go +++ /dev/null @@ -1,36 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../string_simple.i - -package string_simple - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -var _wrap_copy_string unsafe.Pointer - -func Copy_string(arg1 string) (_swig_ret string) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_copy_string, _swig_p) - return -} - diff --git a/Examples/test-suite/go/struct_initialization.go b/Examples/test-suite/go/struct_initialization.go deleted file mode 100644 index 152d7c581..000000000 --- a/Examples/test-suite/go/struct_initialization.go +++ /dev/null @@ -1,709 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../struct_initialization.i - -package struct_initialization - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrStructA uintptr - -func (p SwigcptrStructA) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrStructA) SwigIsStructA() { -} - -var _wrap_StructA_x_set unsafe.Pointer - -func _swig_wrap_StructA_x_set(base SwigcptrStructA, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_StructA_x_set, _swig_p) - return -} - -func (arg1 SwigcptrStructA) SetX(arg2 int) { - _swig_wrap_StructA_x_set(arg1, arg2) -} - -var _wrap_StructA_x_get unsafe.Pointer - -func _swig_wrap_StructA_x_get(base SwigcptrStructA) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_StructA_x_get, _swig_p) - return -} - -func (arg1 SwigcptrStructA) GetX() (_swig_ret int) { - return _swig_wrap_StructA_x_get(arg1) -} - -var _wrap_new_StructA unsafe.Pointer - -func _swig_wrap_new_StructA() (base SwigcptrStructA) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_StructA, _swig_p) - return -} - -func NewStructA() (_swig_ret StructA) { - return _swig_wrap_new_StructA() -} - -var _wrap_delete_StructA unsafe.Pointer - -func _swig_wrap_delete_StructA(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_StructA, _swig_p) - return -} - -func DeleteStructA(arg1 StructA) { - _swig_wrap_delete_StructA(arg1.Swigcptr()) -} - -type StructA interface { - Swigcptr() uintptr - SwigIsStructA() - SetX(arg2 int) - GetX() (_swig_ret int) -} - -var _wrap_instanceA1_set unsafe.Pointer - -func _swig_wrap_instanceA1_set(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_instanceA1_set, _swig_p) - return -} - -func SetInstanceA1(arg1 StructA) { - _swig_wrap_instanceA1_set(arg1.Swigcptr()) -} - -var _wrap_instanceA1_get unsafe.Pointer - -func _swig_wrap_instanceA1_get() (base SwigcptrStructA) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_instanceA1_get, _swig_p) - return -} - -func GetInstanceA1() (_swig_ret StructA) { - return _swig_wrap_instanceA1_get() -} - -type SwigcptrStructB uintptr - -func (p SwigcptrStructB) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrStructB) SwigIsStructB() { -} - -var _wrap_StructB_x_set unsafe.Pointer - -func _swig_wrap_StructB_x_set(base SwigcptrStructB, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_StructB_x_set, _swig_p) - return -} - -func (arg1 SwigcptrStructB) SetX(arg2 int) { - _swig_wrap_StructB_x_set(arg1, arg2) -} - -var _wrap_StructB_x_get unsafe.Pointer - -func _swig_wrap_StructB_x_get(base SwigcptrStructB) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_StructB_x_get, _swig_p) - return -} - -func (arg1 SwigcptrStructB) GetX() (_swig_ret int) { - return _swig_wrap_StructB_x_get(arg1) -} - -var _wrap_new_StructB unsafe.Pointer - -func _swig_wrap_new_StructB() (base SwigcptrStructB) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_StructB, _swig_p) - return -} - -func NewStructB() (_swig_ret StructB) { - return _swig_wrap_new_StructB() -} - -var _wrap_delete_StructB unsafe.Pointer - -func _swig_wrap_delete_StructB(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_StructB, _swig_p) - return -} - -func DeleteStructB(arg1 StructB) { - _swig_wrap_delete_StructB(arg1.Swigcptr()) -} - -type StructB interface { - Swigcptr() uintptr - SwigIsStructB() - SetX(arg2 int) - GetX() (_swig_ret int) -} - -var _wrap_instanceB1_set unsafe.Pointer - -func _swig_wrap_instanceB1_set(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_instanceB1_set, _swig_p) - return -} - -func SetInstanceB1(arg1 StructB) { - _swig_wrap_instanceB1_set(arg1.Swigcptr()) -} - -var _wrap_instanceB1_get unsafe.Pointer - -func _swig_wrap_instanceB1_get() (base SwigcptrStructB) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_instanceB1_get, _swig_p) - return -} - -func GetInstanceB1() (_swig_ret StructB) { - return _swig_wrap_instanceB1_get() -} - -var _wrap_instanceB2_set unsafe.Pointer - -func _swig_wrap_instanceB2_set(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_instanceB2_set, _swig_p) - return -} - -func SetInstanceB2(arg1 StructB) { - _swig_wrap_instanceB2_set(arg1.Swigcptr()) -} - -var _wrap_instanceB2_get unsafe.Pointer - -func _swig_wrap_instanceB2_get() (base SwigcptrStructB) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_instanceB2_get, _swig_p) - return -} - -func GetInstanceB2() (_swig_ret StructB) { - return _swig_wrap_instanceB2_get() -} - -var _wrap_instanceB3_set unsafe.Pointer - -func _swig_wrap_instanceB3_set(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_instanceB3_set, _swig_p) - return -} - -func SetInstanceB3(arg1 StructB) { - _swig_wrap_instanceB3_set(arg1.Swigcptr()) -} - -var _wrap_instanceB3_get unsafe.Pointer - -func _swig_wrap_instanceB3_get() (base SwigcptrStructB) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_instanceB3_get, _swig_p) - return -} - -func GetInstanceB3() (_swig_ret StructB) { - return _swig_wrap_instanceB3_get() -} - -type SwigcptrStructC uintptr - -func (p SwigcptrStructC) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrStructC) SwigIsStructC() { -} - -var _wrap_StructC_x_set unsafe.Pointer - -func _swig_wrap_StructC_x_set(base SwigcptrStructC, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_StructC_x_set, _swig_p) - return -} - -func (arg1 SwigcptrStructC) SetX(arg2 int) { - _swig_wrap_StructC_x_set(arg1, arg2) -} - -var _wrap_StructC_x_get unsafe.Pointer - -func _swig_wrap_StructC_x_get(base SwigcptrStructC) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_StructC_x_get, _swig_p) - return -} - -func (arg1 SwigcptrStructC) GetX() (_swig_ret int) { - return _swig_wrap_StructC_x_get(arg1) -} - -var _wrap_new_StructC unsafe.Pointer - -func _swig_wrap_new_StructC() (base SwigcptrStructC) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_StructC, _swig_p) - return -} - -func NewStructC() (_swig_ret StructC) { - return _swig_wrap_new_StructC() -} - -var _wrap_delete_StructC unsafe.Pointer - -func _swig_wrap_delete_StructC(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_StructC, _swig_p) - return -} - -func DeleteStructC(arg1 StructC) { - _swig_wrap_delete_StructC(arg1.Swigcptr()) -} - -type StructC interface { - Swigcptr() uintptr - SwigIsStructC() - SetX(arg2 int) - GetX() (_swig_ret int) -} - -var _wrap_instanceC1_set unsafe.Pointer - -func _swig_wrap_instanceC1_set(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_instanceC1_set, _swig_p) - return -} - -func SetInstanceC1(arg1 StructC) { - _swig_wrap_instanceC1_set(arg1.Swigcptr()) -} - -var _wrap_instanceC1_get unsafe.Pointer - -func _swig_wrap_instanceC1_get() (base SwigcptrStructC) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_instanceC1_get, _swig_p) - return -} - -func GetInstanceC1() (_swig_ret StructC) { - return _swig_wrap_instanceC1_get() -} - -type SwigcptrStructD uintptr - -func (p SwigcptrStructD) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrStructD) SwigIsStructD() { -} - -var _wrap_StructD_x_set unsafe.Pointer - -func _swig_wrap_StructD_x_set(base SwigcptrStructD, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_StructD_x_set, _swig_p) - return -} - -func (arg1 SwigcptrStructD) SetX(arg2 int) { - _swig_wrap_StructD_x_set(arg1, arg2) -} - -var _wrap_StructD_x_get unsafe.Pointer - -func _swig_wrap_StructD_x_get(base SwigcptrStructD) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_StructD_x_get, _swig_p) - return -} - -func (arg1 SwigcptrStructD) GetX() (_swig_ret int) { - return _swig_wrap_StructD_x_get(arg1) -} - -var _wrap_new_StructD unsafe.Pointer - -func _swig_wrap_new_StructD() (base SwigcptrStructD) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_StructD, _swig_p) - return -} - -func NewStructD() (_swig_ret StructD) { - return _swig_wrap_new_StructD() -} - -var _wrap_delete_StructD unsafe.Pointer - -func _swig_wrap_delete_StructD(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_StructD, _swig_p) - return -} - -func DeleteStructD(arg1 StructD) { - _swig_wrap_delete_StructD(arg1.Swigcptr()) -} - -type StructD interface { - Swigcptr() uintptr - SwigIsStructD() - SetX(arg2 int) - GetX() (_swig_ret int) -} - -var _wrap_instanceD1_set unsafe.Pointer - -func _swig_wrap_instanceD1_set(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_instanceD1_set, _swig_p) - return -} - -func SetInstanceD1(arg1 StructD) { - _swig_wrap_instanceD1_set(arg1.Swigcptr()) -} - -var _wrap_instanceD1_get unsafe.Pointer - -func _swig_wrap_instanceD1_get() (base SwigcptrStructD) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_instanceD1_get, _swig_p) - return -} - -func GetInstanceD1() (_swig_ret StructD) { - return _swig_wrap_instanceD1_get() -} - -var _wrap_instanceD2_set unsafe.Pointer - -func _swig_wrap_instanceD2_set(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_instanceD2_set, _swig_p) - return -} - -func SetInstanceD2(arg1 StructD) { - _swig_wrap_instanceD2_set(arg1.Swigcptr()) -} - -var _wrap_instanceD2_get unsafe.Pointer - -func _swig_wrap_instanceD2_get() (base SwigcptrStructD) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_instanceD2_get, _swig_p) - return -} - -func GetInstanceD2() (_swig_ret StructD) { - return _swig_wrap_instanceD2_get() -} - -var _wrap_instanceD3_set unsafe.Pointer - -func _swig_wrap_instanceD3_set(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_instanceD3_set, _swig_p) - return -} - -func SetInstanceD3(arg1 StructD) { - _swig_wrap_instanceD3_set(arg1.Swigcptr()) -} - -var _wrap_instanceD3_get unsafe.Pointer - -func _swig_wrap_instanceD3_get() (base SwigcptrStructD) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_instanceD3_get, _swig_p) - return -} - -func GetInstanceD3() (_swig_ret StructD) { - return _swig_wrap_instanceD3_get() -} - -type SwigcptrStructE uintptr - -func (p SwigcptrStructE) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrStructE) SwigIsStructE() { -} - -var _wrap_StructE_x_set unsafe.Pointer - -func _swig_wrap_StructE_x_set(base SwigcptrStructE, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_StructE_x_set, _swig_p) - return -} - -func (arg1 SwigcptrStructE) SetX(arg2 int) { - _swig_wrap_StructE_x_set(arg1, arg2) -} - -var _wrap_StructE_x_get unsafe.Pointer - -func _swig_wrap_StructE_x_get(base SwigcptrStructE) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_StructE_x_get, _swig_p) - return -} - -func (arg1 SwigcptrStructE) GetX() (_swig_ret int) { - return _swig_wrap_StructE_x_get(arg1) -} - -var _wrap_new_StructE unsafe.Pointer - -func _swig_wrap_new_StructE() (base SwigcptrStructE) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_StructE, _swig_p) - return -} - -func NewStructE() (_swig_ret StructE) { - return _swig_wrap_new_StructE() -} - -var _wrap_delete_StructE unsafe.Pointer - -func _swig_wrap_delete_StructE(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_StructE, _swig_p) - return -} - -func DeleteStructE(arg1 StructE) { - _swig_wrap_delete_StructE(arg1.Swigcptr()) -} - -type StructE interface { - Swigcptr() uintptr - SwigIsStructE() - SetX(arg2 int) - GetX() (_swig_ret int) -} - -var _wrap_instanceE1_set unsafe.Pointer - -func _swig_wrap_instanceE1_set(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_instanceE1_set, _swig_p) - return -} - -func SetInstanceE1(arg1 StructE) { - _swig_wrap_instanceE1_set(arg1.Swigcptr()) -} - -var _wrap_instanceE1_get unsafe.Pointer - -func _swig_wrap_instanceE1_get() (base SwigcptrStructE) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_instanceE1_get, _swig_p) - return -} - -func GetInstanceE1() (_swig_ret StructE) { - return _swig_wrap_instanceE1_get() -} - -type SwigcptrStructF uintptr - -func (p SwigcptrStructF) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrStructF) SwigIsStructF() { -} - -var _wrap_StructF_x_set unsafe.Pointer - -func _swig_wrap_StructF_x_set(base SwigcptrStructF, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_StructF_x_set, _swig_p) - return -} - -func (arg1 SwigcptrStructF) SetX(arg2 int) { - _swig_wrap_StructF_x_set(arg1, arg2) -} - -var _wrap_StructF_x_get unsafe.Pointer - -func _swig_wrap_StructF_x_get(base SwigcptrStructF) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_StructF_x_get, _swig_p) - return -} - -func (arg1 SwigcptrStructF) GetX() (_swig_ret int) { - return _swig_wrap_StructF_x_get(arg1) -} - -var _wrap_new_StructF unsafe.Pointer - -func _swig_wrap_new_StructF() (base SwigcptrStructF) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_StructF, _swig_p) - return -} - -func NewStructF() (_swig_ret StructF) { - return _swig_wrap_new_StructF() -} - -var _wrap_delete_StructF unsafe.Pointer - -func _swig_wrap_delete_StructF(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_StructF, _swig_p) - return -} - -func DeleteStructF(arg1 StructF) { - _swig_wrap_delete_StructF(arg1.Swigcptr()) -} - -type StructF interface { - Swigcptr() uintptr - SwigIsStructF() - SetX(arg2 int) - GetX() (_swig_ret int) -} - -var _wrap_instanceF1_set unsafe.Pointer - -func _swig_wrap_instanceF1_set(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_instanceF1_set, _swig_p) - return -} - -func SetInstanceF1(arg1 StructF) { - _swig_wrap_instanceF1_set(arg1.Swigcptr()) -} - -var _wrap_instanceF1_get unsafe.Pointer - -func _swig_wrap_instanceF1_get() (base SwigcptrStructF) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_instanceF1_get, _swig_p) - return -} - -func GetInstanceF1() (_swig_ret StructF) { - return _swig_wrap_instanceF1_get() -} - -var _wrap_instanceF2_set unsafe.Pointer - -func _swig_wrap_instanceF2_set(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_instanceF2_set, _swig_p) - return -} - -func SetInstanceF2(arg1 StructF) { - _swig_wrap_instanceF2_set(arg1.Swigcptr()) -} - -var _wrap_instanceF2_get unsafe.Pointer - -func _swig_wrap_instanceF2_get() (base SwigcptrStructF) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_instanceF2_get, _swig_p) - return -} - -func GetInstanceF2() (_swig_ret StructF) { - return _swig_wrap_instanceF2_get() -} - -var _wrap_instanceF3_set unsafe.Pointer - -func _swig_wrap_instanceF3_set(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_instanceF3_set, _swig_p) - return -} - -func SetInstanceF3(arg1 StructF) { - _swig_wrap_instanceF3_set(arg1.Swigcptr()) -} - -var _wrap_instanceF3_get unsafe.Pointer - -func _swig_wrap_instanceF3_get() (base SwigcptrStructF) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_instanceF3_get, _swig_p) - return -} - -func GetInstanceF3() (_swig_ret StructF) { - return _swig_wrap_instanceF3_get() -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/struct_initialization_cpp.go b/Examples/test-suite/go/struct_initialization_cpp.go deleted file mode 100644 index f59284bcb..000000000 --- a/Examples/test-suite/go/struct_initialization_cpp.go +++ /dev/null @@ -1,709 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../struct_initialization_cpp.i - -package struct_initialization_cpp - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrStructA uintptr - -func (p SwigcptrStructA) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrStructA) SwigIsStructA() { -} - -var _wrap_StructA_x_set unsafe.Pointer - -func _swig_wrap_StructA_x_set(base SwigcptrStructA, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_StructA_x_set, _swig_p) - return -} - -func (arg1 SwigcptrStructA) SetX(arg2 int) { - _swig_wrap_StructA_x_set(arg1, arg2) -} - -var _wrap_StructA_x_get unsafe.Pointer - -func _swig_wrap_StructA_x_get(base SwigcptrStructA) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_StructA_x_get, _swig_p) - return -} - -func (arg1 SwigcptrStructA) GetX() (_swig_ret int) { - return _swig_wrap_StructA_x_get(arg1) -} - -var _wrap_new_StructA unsafe.Pointer - -func _swig_wrap_new_StructA() (base SwigcptrStructA) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_StructA, _swig_p) - return -} - -func NewStructA() (_swig_ret StructA) { - return _swig_wrap_new_StructA() -} - -var _wrap_delete_StructA unsafe.Pointer - -func _swig_wrap_delete_StructA(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_StructA, _swig_p) - return -} - -func DeleteStructA(arg1 StructA) { - _swig_wrap_delete_StructA(arg1.Swigcptr()) -} - -type StructA interface { - Swigcptr() uintptr - SwigIsStructA() - SetX(arg2 int) - GetX() (_swig_ret int) -} - -var _wrap_instanceA1_set unsafe.Pointer - -func _swig_wrap_instanceA1_set(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_instanceA1_set, _swig_p) - return -} - -func SetInstanceA1(arg1 StructA) { - _swig_wrap_instanceA1_set(arg1.Swigcptr()) -} - -var _wrap_instanceA1_get unsafe.Pointer - -func _swig_wrap_instanceA1_get() (base SwigcptrStructA) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_instanceA1_get, _swig_p) - return -} - -func GetInstanceA1() (_swig_ret StructA) { - return _swig_wrap_instanceA1_get() -} - -type SwigcptrStructB uintptr - -func (p SwigcptrStructB) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrStructB) SwigIsStructB() { -} - -var _wrap_StructB_x_set unsafe.Pointer - -func _swig_wrap_StructB_x_set(base SwigcptrStructB, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_StructB_x_set, _swig_p) - return -} - -func (arg1 SwigcptrStructB) SetX(arg2 int) { - _swig_wrap_StructB_x_set(arg1, arg2) -} - -var _wrap_StructB_x_get unsafe.Pointer - -func _swig_wrap_StructB_x_get(base SwigcptrStructB) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_StructB_x_get, _swig_p) - return -} - -func (arg1 SwigcptrStructB) GetX() (_swig_ret int) { - return _swig_wrap_StructB_x_get(arg1) -} - -var _wrap_new_StructB unsafe.Pointer - -func _swig_wrap_new_StructB() (base SwigcptrStructB) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_StructB, _swig_p) - return -} - -func NewStructB() (_swig_ret StructB) { - return _swig_wrap_new_StructB() -} - -var _wrap_delete_StructB unsafe.Pointer - -func _swig_wrap_delete_StructB(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_StructB, _swig_p) - return -} - -func DeleteStructB(arg1 StructB) { - _swig_wrap_delete_StructB(arg1.Swigcptr()) -} - -type StructB interface { - Swigcptr() uintptr - SwigIsStructB() - SetX(arg2 int) - GetX() (_swig_ret int) -} - -var _wrap_instanceB1_set unsafe.Pointer - -func _swig_wrap_instanceB1_set(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_instanceB1_set, _swig_p) - return -} - -func SetInstanceB1(arg1 StructB) { - _swig_wrap_instanceB1_set(arg1.Swigcptr()) -} - -var _wrap_instanceB1_get unsafe.Pointer - -func _swig_wrap_instanceB1_get() (base SwigcptrStructB) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_instanceB1_get, _swig_p) - return -} - -func GetInstanceB1() (_swig_ret StructB) { - return _swig_wrap_instanceB1_get() -} - -var _wrap_instanceB2_set unsafe.Pointer - -func _swig_wrap_instanceB2_set(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_instanceB2_set, _swig_p) - return -} - -func SetInstanceB2(arg1 StructB) { - _swig_wrap_instanceB2_set(arg1.Swigcptr()) -} - -var _wrap_instanceB2_get unsafe.Pointer - -func _swig_wrap_instanceB2_get() (base SwigcptrStructB) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_instanceB2_get, _swig_p) - return -} - -func GetInstanceB2() (_swig_ret StructB) { - return _swig_wrap_instanceB2_get() -} - -var _wrap_instanceB3_set unsafe.Pointer - -func _swig_wrap_instanceB3_set(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_instanceB3_set, _swig_p) - return -} - -func SetInstanceB3(arg1 StructB) { - _swig_wrap_instanceB3_set(arg1.Swigcptr()) -} - -var _wrap_instanceB3_get unsafe.Pointer - -func _swig_wrap_instanceB3_get() (base SwigcptrStructB) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_instanceB3_get, _swig_p) - return -} - -func GetInstanceB3() (_swig_ret StructB) { - return _swig_wrap_instanceB3_get() -} - -type SwigcptrStructC uintptr - -func (p SwigcptrStructC) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrStructC) SwigIsStructC() { -} - -var _wrap_StructC_x_set unsafe.Pointer - -func _swig_wrap_StructC_x_set(base SwigcptrStructC, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_StructC_x_set, _swig_p) - return -} - -func (arg1 SwigcptrStructC) SetX(arg2 int) { - _swig_wrap_StructC_x_set(arg1, arg2) -} - -var _wrap_StructC_x_get unsafe.Pointer - -func _swig_wrap_StructC_x_get(base SwigcptrStructC) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_StructC_x_get, _swig_p) - return -} - -func (arg1 SwigcptrStructC) GetX() (_swig_ret int) { - return _swig_wrap_StructC_x_get(arg1) -} - -var _wrap_new_StructC unsafe.Pointer - -func _swig_wrap_new_StructC() (base SwigcptrStructC) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_StructC, _swig_p) - return -} - -func NewStructC() (_swig_ret StructC) { - return _swig_wrap_new_StructC() -} - -var _wrap_delete_StructC unsafe.Pointer - -func _swig_wrap_delete_StructC(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_StructC, _swig_p) - return -} - -func DeleteStructC(arg1 StructC) { - _swig_wrap_delete_StructC(arg1.Swigcptr()) -} - -type StructC interface { - Swigcptr() uintptr - SwigIsStructC() - SetX(arg2 int) - GetX() (_swig_ret int) -} - -var _wrap_instanceC1_set unsafe.Pointer - -func _swig_wrap_instanceC1_set(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_instanceC1_set, _swig_p) - return -} - -func SetInstanceC1(arg1 StructC) { - _swig_wrap_instanceC1_set(arg1.Swigcptr()) -} - -var _wrap_instanceC1_get unsafe.Pointer - -func _swig_wrap_instanceC1_get() (base SwigcptrStructC) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_instanceC1_get, _swig_p) - return -} - -func GetInstanceC1() (_swig_ret StructC) { - return _swig_wrap_instanceC1_get() -} - -type SwigcptrStructD uintptr - -func (p SwigcptrStructD) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrStructD) SwigIsStructD() { -} - -var _wrap_StructD_x_set unsafe.Pointer - -func _swig_wrap_StructD_x_set(base SwigcptrStructD, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_StructD_x_set, _swig_p) - return -} - -func (arg1 SwigcptrStructD) SetX(arg2 int) { - _swig_wrap_StructD_x_set(arg1, arg2) -} - -var _wrap_StructD_x_get unsafe.Pointer - -func _swig_wrap_StructD_x_get(base SwigcptrStructD) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_StructD_x_get, _swig_p) - return -} - -func (arg1 SwigcptrStructD) GetX() (_swig_ret int) { - return _swig_wrap_StructD_x_get(arg1) -} - -var _wrap_new_StructD unsafe.Pointer - -func _swig_wrap_new_StructD() (base SwigcptrStructD) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_StructD, _swig_p) - return -} - -func NewStructD() (_swig_ret StructD) { - return _swig_wrap_new_StructD() -} - -var _wrap_delete_StructD unsafe.Pointer - -func _swig_wrap_delete_StructD(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_StructD, _swig_p) - return -} - -func DeleteStructD(arg1 StructD) { - _swig_wrap_delete_StructD(arg1.Swigcptr()) -} - -type StructD interface { - Swigcptr() uintptr - SwigIsStructD() - SetX(arg2 int) - GetX() (_swig_ret int) -} - -var _wrap_instanceD1_set unsafe.Pointer - -func _swig_wrap_instanceD1_set(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_instanceD1_set, _swig_p) - return -} - -func SetInstanceD1(arg1 StructD) { - _swig_wrap_instanceD1_set(arg1.Swigcptr()) -} - -var _wrap_instanceD1_get unsafe.Pointer - -func _swig_wrap_instanceD1_get() (base SwigcptrStructD) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_instanceD1_get, _swig_p) - return -} - -func GetInstanceD1() (_swig_ret StructD) { - return _swig_wrap_instanceD1_get() -} - -var _wrap_instanceD2_set unsafe.Pointer - -func _swig_wrap_instanceD2_set(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_instanceD2_set, _swig_p) - return -} - -func SetInstanceD2(arg1 StructD) { - _swig_wrap_instanceD2_set(arg1.Swigcptr()) -} - -var _wrap_instanceD2_get unsafe.Pointer - -func _swig_wrap_instanceD2_get() (base SwigcptrStructD) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_instanceD2_get, _swig_p) - return -} - -func GetInstanceD2() (_swig_ret StructD) { - return _swig_wrap_instanceD2_get() -} - -var _wrap_instanceD3_set unsafe.Pointer - -func _swig_wrap_instanceD3_set(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_instanceD3_set, _swig_p) - return -} - -func SetInstanceD3(arg1 StructD) { - _swig_wrap_instanceD3_set(arg1.Swigcptr()) -} - -var _wrap_instanceD3_get unsafe.Pointer - -func _swig_wrap_instanceD3_get() (base SwigcptrStructD) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_instanceD3_get, _swig_p) - return -} - -func GetInstanceD3() (_swig_ret StructD) { - return _swig_wrap_instanceD3_get() -} - -type SwigcptrStructE uintptr - -func (p SwigcptrStructE) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrStructE) SwigIsStructE() { -} - -var _wrap_StructE_x_set unsafe.Pointer - -func _swig_wrap_StructE_x_set(base SwigcptrStructE, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_StructE_x_set, _swig_p) - return -} - -func (arg1 SwigcptrStructE) SetX(arg2 int) { - _swig_wrap_StructE_x_set(arg1, arg2) -} - -var _wrap_StructE_x_get unsafe.Pointer - -func _swig_wrap_StructE_x_get(base SwigcptrStructE) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_StructE_x_get, _swig_p) - return -} - -func (arg1 SwigcptrStructE) GetX() (_swig_ret int) { - return _swig_wrap_StructE_x_get(arg1) -} - -var _wrap_new_StructE unsafe.Pointer - -func _swig_wrap_new_StructE() (base SwigcptrStructE) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_StructE, _swig_p) - return -} - -func NewStructE() (_swig_ret StructE) { - return _swig_wrap_new_StructE() -} - -var _wrap_delete_StructE unsafe.Pointer - -func _swig_wrap_delete_StructE(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_StructE, _swig_p) - return -} - -func DeleteStructE(arg1 StructE) { - _swig_wrap_delete_StructE(arg1.Swigcptr()) -} - -type StructE interface { - Swigcptr() uintptr - SwigIsStructE() - SetX(arg2 int) - GetX() (_swig_ret int) -} - -var _wrap_instanceE1_set unsafe.Pointer - -func _swig_wrap_instanceE1_set(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_instanceE1_set, _swig_p) - return -} - -func SetInstanceE1(arg1 StructE) { - _swig_wrap_instanceE1_set(arg1.Swigcptr()) -} - -var _wrap_instanceE1_get unsafe.Pointer - -func _swig_wrap_instanceE1_get() (base SwigcptrStructE) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_instanceE1_get, _swig_p) - return -} - -func GetInstanceE1() (_swig_ret StructE) { - return _swig_wrap_instanceE1_get() -} - -type SwigcptrStructF uintptr - -func (p SwigcptrStructF) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrStructF) SwigIsStructF() { -} - -var _wrap_StructF_x_set unsafe.Pointer - -func _swig_wrap_StructF_x_set(base SwigcptrStructF, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_StructF_x_set, _swig_p) - return -} - -func (arg1 SwigcptrStructF) SetX(arg2 int) { - _swig_wrap_StructF_x_set(arg1, arg2) -} - -var _wrap_StructF_x_get unsafe.Pointer - -func _swig_wrap_StructF_x_get(base SwigcptrStructF) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_StructF_x_get, _swig_p) - return -} - -func (arg1 SwigcptrStructF) GetX() (_swig_ret int) { - return _swig_wrap_StructF_x_get(arg1) -} - -var _wrap_new_StructF unsafe.Pointer - -func _swig_wrap_new_StructF() (base SwigcptrStructF) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_StructF, _swig_p) - return -} - -func NewStructF() (_swig_ret StructF) { - return _swig_wrap_new_StructF() -} - -var _wrap_delete_StructF unsafe.Pointer - -func _swig_wrap_delete_StructF(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_StructF, _swig_p) - return -} - -func DeleteStructF(arg1 StructF) { - _swig_wrap_delete_StructF(arg1.Swigcptr()) -} - -type StructF interface { - Swigcptr() uintptr - SwigIsStructF() - SetX(arg2 int) - GetX() (_swig_ret int) -} - -var _wrap_instanceF1_set unsafe.Pointer - -func _swig_wrap_instanceF1_set(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_instanceF1_set, _swig_p) - return -} - -func SetInstanceF1(arg1 StructF) { - _swig_wrap_instanceF1_set(arg1.Swigcptr()) -} - -var _wrap_instanceF1_get unsafe.Pointer - -func _swig_wrap_instanceF1_get() (base SwigcptrStructF) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_instanceF1_get, _swig_p) - return -} - -func GetInstanceF1() (_swig_ret StructF) { - return _swig_wrap_instanceF1_get() -} - -var _wrap_instanceF2_set unsafe.Pointer - -func _swig_wrap_instanceF2_set(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_instanceF2_set, _swig_p) - return -} - -func SetInstanceF2(arg1 StructF) { - _swig_wrap_instanceF2_set(arg1.Swigcptr()) -} - -var _wrap_instanceF2_get unsafe.Pointer - -func _swig_wrap_instanceF2_get() (base SwigcptrStructF) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_instanceF2_get, _swig_p) - return -} - -func GetInstanceF2() (_swig_ret StructF) { - return _swig_wrap_instanceF2_get() -} - -var _wrap_instanceF3_set unsafe.Pointer - -func _swig_wrap_instanceF3_set(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_instanceF3_set, _swig_p) - return -} - -func SetInstanceF3(arg1 StructF) { - _swig_wrap_instanceF3_set(arg1.Swigcptr()) -} - -var _wrap_instanceF3_get unsafe.Pointer - -func _swig_wrap_instanceF3_get() (base SwigcptrStructF) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_instanceF3_get, _swig_p) - return -} - -func GetInstanceF3() (_swig_ret StructF) { - return _swig_wrap_instanceF3_get() -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/struct_initialization_runme b/Examples/test-suite/go/struct_initialization_runme deleted file mode 100755 index a637928a5..000000000 Binary files a/Examples/test-suite/go/struct_initialization_runme and /dev/null differ diff --git a/Examples/test-suite/go/struct_rename.go b/Examples/test-suite/go/struct_rename.go deleted file mode 100644 index 5c9aa6eee..000000000 --- a/Examples/test-suite/go/struct_rename.go +++ /dev/null @@ -1,101 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../struct_rename.i - -package struct_rename - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrBar uintptr - -func (p SwigcptrBar) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrBar) SwigIsBar() { -} - -var _wrap_Bar_x_set unsafe.Pointer - -func _swig_wrap_Bar_x_set(base SwigcptrBar, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Bar_x_set, _swig_p) - return -} - -func (arg1 SwigcptrBar) SetX(arg2 int) { - _swig_wrap_Bar_x_set(arg1, arg2) -} - -var _wrap_Bar_x_get unsafe.Pointer - -func _swig_wrap_Bar_x_get(base SwigcptrBar) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Bar_x_get, _swig_p) - return -} - -func (arg1 SwigcptrBar) GetX() (_swig_ret int) { - return _swig_wrap_Bar_x_get(arg1) -} - -var _wrap_new_Bar unsafe.Pointer - -func _swig_wrap_new_Bar() (base SwigcptrBar) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Bar, _swig_p) - return -} - -func NewBar() (_swig_ret Bar) { - return _swig_wrap_new_Bar() -} - -var _wrap_delete_Bar unsafe.Pointer - -func _swig_wrap_delete_Bar(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Bar, _swig_p) - return -} - -func DeleteBar(arg1 Bar) { - _swig_wrap_delete_Bar(arg1.Swigcptr()) -} - -type Bar interface { - Swigcptr() uintptr - SwigIsBar() - SetX(arg2 int) - GetX() (_swig_ret int) -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/struct_rename_runme b/Examples/test-suite/go/struct_rename_runme deleted file mode 100755 index 67ae92a4c..000000000 Binary files a/Examples/test-suite/go/struct_rename_runme and /dev/null differ diff --git a/Examples/test-suite/go/struct_value.go b/Examples/test-suite/go/struct_value.go deleted file mode 100644 index 1d56cb142..000000000 --- a/Examples/test-suite/go/struct_value.go +++ /dev/null @@ -1,191 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../struct_value.i - -package struct_value - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrFoo uintptr - -func (p SwigcptrFoo) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrFoo) SwigIsFoo() { -} - -var _wrap_Foo_x_set unsafe.Pointer - -func _swig_wrap_Foo_x_set(base SwigcptrFoo, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_x_set, _swig_p) - return -} - -func (arg1 SwigcptrFoo) SetX(arg2 int) { - _swig_wrap_Foo_x_set(arg1, arg2) -} - -var _wrap_Foo_x_get unsafe.Pointer - -func _swig_wrap_Foo_x_get(base SwigcptrFoo) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_x_get, _swig_p) - return -} - -func (arg1 SwigcptrFoo) GetX() (_swig_ret int) { - return _swig_wrap_Foo_x_get(arg1) -} - -var _wrap_new_Foo unsafe.Pointer - -func _swig_wrap_new_Foo() (base SwigcptrFoo) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Foo, _swig_p) - return -} - -func NewFoo() (_swig_ret Foo) { - return _swig_wrap_new_Foo() -} - -var _wrap_delete_Foo unsafe.Pointer - -func _swig_wrap_delete_Foo(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Foo, _swig_p) - return -} - -func DeleteFoo(arg1 Foo) { - _swig_wrap_delete_Foo(arg1.Swigcptr()) -} - -type Foo interface { - Swigcptr() uintptr - SwigIsFoo() - SetX(arg2 int) - GetX() (_swig_ret int) -} - -type SwigcptrBar uintptr - -func (p SwigcptrBar) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrBar) SwigIsBar() { -} - -var _wrap_Bar_a_set unsafe.Pointer - -func _swig_wrap_Bar_a_set(base SwigcptrBar, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Bar_a_set, _swig_p) - return -} - -func (arg1 SwigcptrBar) SetA(arg2 Foo) { - _swig_wrap_Bar_a_set(arg1, arg2.Swigcptr()) -} - -var _wrap_Bar_a_get unsafe.Pointer - -func _swig_wrap_Bar_a_get(base SwigcptrBar) (_ SwigcptrFoo) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Bar_a_get, _swig_p) - return -} - -func (arg1 SwigcptrBar) GetA() (_swig_ret Foo) { - return _swig_wrap_Bar_a_get(arg1) -} - -var _wrap_Bar_b_set unsafe.Pointer - -func _swig_wrap_Bar_b_set(base SwigcptrBar, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Bar_b_set, _swig_p) - return -} - -func (arg1 SwigcptrBar) SetB(arg2 Foo) { - _swig_wrap_Bar_b_set(arg1, arg2.Swigcptr()) -} - -var _wrap_Bar_b_get unsafe.Pointer - -func _swig_wrap_Bar_b_get(base SwigcptrBar) (_ SwigcptrFoo) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Bar_b_get, _swig_p) - return -} - -func (arg1 SwigcptrBar) GetB() (_swig_ret Foo) { - return _swig_wrap_Bar_b_get(arg1) -} - -var _wrap_new_Bar unsafe.Pointer - -func _swig_wrap_new_Bar() (base SwigcptrBar) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Bar, _swig_p) - return -} - -func NewBar() (_swig_ret Bar) { - return _swig_wrap_new_Bar() -} - -var _wrap_delete_Bar unsafe.Pointer - -func _swig_wrap_delete_Bar(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Bar, _swig_p) - return -} - -func DeleteBar(arg1 Bar) { - _swig_wrap_delete_Bar(arg1.Swigcptr()) -} - -type Bar interface { - Swigcptr() uintptr - SwigIsBar() - SetA(arg2 Foo) - GetA() (_swig_ret Foo) - SetB(arg2 Foo) - GetB() (_swig_ret Foo) -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/struct_value_runme b/Examples/test-suite/go/struct_value_runme deleted file mode 100755 index dd1b701bf..000000000 Binary files a/Examples/test-suite/go/struct_value_runme and /dev/null differ diff --git a/Examples/test-suite/go/symbol_clash.go b/Examples/test-suite/go/symbol_clash.go deleted file mode 100644 index fcc78a267..000000000 --- a/Examples/test-suite/go/symbol_clash.go +++ /dev/null @@ -1,29 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../symbol_clash.i - -package symbol_clash - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - - diff --git a/Examples/test-suite/go/template_arg_replace.go b/Examples/test-suite/go/template_arg_replace.go deleted file mode 100644 index 62b0c7738..000000000 --- a/Examples/test-suite/go/template_arg_replace.go +++ /dev/null @@ -1,88 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../template_arg_replace.i - -package template_arg_replace - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrMatrix33f uintptr - -func (p SwigcptrMatrix33f) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrMatrix33f) SwigIsMatrix33f() { -} - -var _wrap_matrix33f_Func unsafe.Pointer - -func _swig_wrap_matrix33f_Func(base SwigcptrMatrix33f, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_matrix33f_Func, _swig_p) - return -} - -func (arg1 SwigcptrMatrix33f) Func(arg2 Matrix33f) { - _swig_wrap_matrix33f_Func(arg1, arg2.Swigcptr()) -} - -var _wrap_new_matrix33f unsafe.Pointer - -func _swig_wrap_new_matrix33f() (base SwigcptrMatrix33f) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_matrix33f, _swig_p) - return -} - -func NewMatrix33f() (_swig_ret Matrix33f) { - return _swig_wrap_new_matrix33f() -} - -var _wrap_delete_matrix33f unsafe.Pointer - -func _swig_wrap_delete_matrix33f(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_matrix33f, _swig_p) - return -} - -func DeleteMatrix33f(arg1 Matrix33f) { - _swig_wrap_delete_matrix33f(arg1.Swigcptr()) -} - -type Matrix33f interface { - Swigcptr() uintptr - SwigIsMatrix33f() - Func(arg2 Matrix33f) -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/template_arg_scope.go b/Examples/test-suite/go/template_arg_scope.go deleted file mode 100644 index 942880886..000000000 --- a/Examples/test-suite/go/template_arg_scope.go +++ /dev/null @@ -1,96 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../template_arg_scope.i - -package template_arg_scope - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrBar uintptr - -func (p SwigcptrBar) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrBar) SwigIsBar() { -} - -var _wrap_new_Bar unsafe.Pointer - -func _swig_wrap_new_Bar() (base SwigcptrBar) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Bar, _swig_p) - return -} - -func NewBar() (_swig_ret Bar) { - return _swig_wrap_new_Bar() -} - -var _wrap_Bar_spam unsafe.Pointer - -func _swig_wrap_Bar_spam(base SwigcptrBar, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Bar_spam, _swig_p) - return -} - -func (arg1 SwigcptrBar) Spam(arg2 Foo_Sl_Bar_Sg_) { - _swig_wrap_Bar_spam(arg1, arg2.Swigcptr()) -} - -var _wrap_delete_Bar unsafe.Pointer - -func _swig_wrap_delete_Bar(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Bar, _swig_p) - return -} - -func DeleteBar(arg1 Bar) { - _swig_wrap_delete_Bar(arg1.Swigcptr()) -} - -type Bar interface { - Swigcptr() uintptr - SwigIsBar() - Spam(arg2 Foo_Sl_Bar_Sg_) -} - - -type SwigcptrFoo_Sl_Bar_Sg_ uintptr -type Foo_Sl_Bar_Sg_ interface { - Swigcptr() uintptr; -} -func (p SwigcptrFoo_Sl_Bar_Sg_) Swigcptr() uintptr { - return uintptr(p) -} - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/template_arg_typename.go b/Examples/test-suite/go/template_arg_typename.go deleted file mode 100644 index 43c22cc46..000000000 --- a/Examples/test-suite/go/template_arg_typename.go +++ /dev/null @@ -1,122 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../template_arg_typename.i - -package template_arg_typename - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrUnaryFunction_bool_bool uintptr - -func (p SwigcptrUnaryFunction_bool_bool) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrUnaryFunction_bool_bool) SwigIsUnaryFunction_bool_bool() { -} - -var _wrap_new_UnaryFunction_bool_bool unsafe.Pointer - -func _swig_wrap_new_UnaryFunction_bool_bool() (base SwigcptrUnaryFunction_bool_bool) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_UnaryFunction_bool_bool, _swig_p) - return -} - -func NewUnaryFunction_bool_bool() (_swig_ret UnaryFunction_bool_bool) { - return _swig_wrap_new_UnaryFunction_bool_bool() -} - -var _wrap_delete_UnaryFunction_bool_bool unsafe.Pointer - -func _swig_wrap_delete_UnaryFunction_bool_bool(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_UnaryFunction_bool_bool, _swig_p) - return -} - -func DeleteUnaryFunction_bool_bool(arg1 UnaryFunction_bool_bool) { - _swig_wrap_delete_UnaryFunction_bool_bool(arg1.Swigcptr()) -} - -type UnaryFunction_bool_bool interface { - Swigcptr() uintptr - SwigIsUnaryFunction_bool_bool() -} - -type SwigcptrBoolUnaryFunction_bool uintptr - -func (p SwigcptrBoolUnaryFunction_bool) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrBoolUnaryFunction_bool) SwigIsBoolUnaryFunction_bool() { -} - -var _wrap_new_BoolUnaryFunction_bool unsafe.Pointer - -func _swig_wrap_new_BoolUnaryFunction_bool(base *uintptr) (_ SwigcptrBoolUnaryFunction_bool) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_BoolUnaryFunction_bool, _swig_p) - return -} - -func NewBoolUnaryFunction_bool(arg1 *uintptr) (_swig_ret BoolUnaryFunction_bool) { - return _swig_wrap_new_BoolUnaryFunction_bool(arg1) -} - -var _wrap_delete_BoolUnaryFunction_bool unsafe.Pointer - -func _swig_wrap_delete_BoolUnaryFunction_bool(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_BoolUnaryFunction_bool, _swig_p) - return -} - -func DeleteBoolUnaryFunction_bool(arg1 BoolUnaryFunction_bool) { - _swig_wrap_delete_BoolUnaryFunction_bool(arg1.Swigcptr()) -} - -func (p SwigcptrBoolUnaryFunction_bool) SwigIsUnaryFunction_bool_bool() { -} - -func (p SwigcptrBoolUnaryFunction_bool) SwigGetUnaryFunction_bool_bool() UnaryFunction_bool_bool { - return SwigcptrUnaryFunction_bool_bool(p.Swigcptr()) -} - -type BoolUnaryFunction_bool interface { - Swigcptr() uintptr - SwigIsBoolUnaryFunction_bool() - SwigIsUnaryFunction_bool_bool() - SwigGetUnaryFunction_bool_bool() UnaryFunction_bool_bool -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/template_array_numeric.go b/Examples/test-suite/go/template_array_numeric.go deleted file mode 100644 index f114be4d2..000000000 --- a/Examples/test-suite/go/template_array_numeric.go +++ /dev/null @@ -1,110 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../template_array_numeric.i - -package template_array_numeric - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrArray4f uintptr - -func (p SwigcptrArray4f) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrArray4f) SwigIsArray4f() { -} - -var _wrap_new_Array4f__SWIG_0 unsafe.Pointer - -func _swig_wrap_new_Array4f__SWIG_0() (base SwigcptrArray4f) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Array4f__SWIG_0, _swig_p) - return -} - -func NewArray4f__SWIG_0() (_swig_ret Array4f) { - return _swig_wrap_new_Array4f__SWIG_0() -} - -var _wrap_new_Array4f__SWIG_1 unsafe.Pointer - -func _swig_wrap_new_Array4f__SWIG_1(base *float32) (_ SwigcptrArray4f) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Array4f__SWIG_1, _swig_p) - return -} - -func NewArray4f__SWIG_1(arg1 *float32) (_swig_ret Array4f) { - return _swig_wrap_new_Array4f__SWIG_1(arg1) -} - -func NewArray4f(a ...interface{}) Array4f { - argc := len(a) - if argc == 0 { - return NewArray4f__SWIG_0() - } - if argc == 1 { - return NewArray4f__SWIG_1(a[0].(*float32)) - } - panic("No match for overloaded function call") -} - -var _wrap_delete_Array4f unsafe.Pointer - -func _swig_wrap_delete_Array4f(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Array4f, _swig_p) - return -} - -func DeleteArray4f(arg1 Array4f) { - _swig_wrap_delete_Array4f(arg1.Swigcptr()) -} - -type Array4f interface { - Swigcptr() uintptr - SwigIsArray4f() -} - -var _wrap_make_array4f unsafe.Pointer - -func _swig_wrap_make_array4f(base *float32) (_ SwigcptrArray4f) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_make_array4f, _swig_p) - return -} - -func Make_array4f(arg1 *float32) (_swig_ret Array4f) { - return _swig_wrap_make_array4f(arg1) -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/template_base_template.go b/Examples/test-suite/go/template_base_template.go deleted file mode 100644 index 96e545c17..000000000 --- a/Examples/test-suite/go/template_base_template.go +++ /dev/null @@ -1,160 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../template_base_template.i - -package template_base_template - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrTraits_dd uintptr - -func (p SwigcptrTraits_dd) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrTraits_dd) SwigIsTraits_dd() { -} - -var _wrap_new_traits_dd unsafe.Pointer - -func _swig_wrap_new_traits_dd() (base SwigcptrTraits_dd) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_traits_dd, _swig_p) - return -} - -func NewTraits_dd() (_swig_ret Traits_dd) { - return _swig_wrap_new_traits_dd() -} - -var _wrap_delete_traits_dd unsafe.Pointer - -func _swig_wrap_delete_traits_dd(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_traits_dd, _swig_p) - return -} - -func DeleteTraits_dd(arg1 Traits_dd) { - _swig_wrap_delete_traits_dd(arg1.Swigcptr()) -} - -type Traits_dd interface { - Swigcptr() uintptr - SwigIsTraits_dd() -} - -type SwigcptrFunktion_dd uintptr - -func (p SwigcptrFunktion_dd) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrFunktion_dd) SwigIsFunktion_dd() { -} - -var _wrap_new_Funktion_dd unsafe.Pointer - -func _swig_wrap_new_Funktion_dd() (base SwigcptrFunktion_dd) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Funktion_dd, _swig_p) - return -} - -func NewFunktion_dd() (_swig_ret Funktion_dd) { - return _swig_wrap_new_Funktion_dd() -} - -var _wrap_delete_Funktion_dd unsafe.Pointer - -func _swig_wrap_delete_Funktion_dd(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Funktion_dd, _swig_p) - return -} - -func DeleteFunktion_dd(arg1 Funktion_dd) { - _swig_wrap_delete_Funktion_dd(arg1.Swigcptr()) -} - -type Funktion_dd interface { - Swigcptr() uintptr - SwigIsFunktion_dd() -} - -type SwigcptrKlass_dd uintptr - -func (p SwigcptrKlass_dd) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrKlass_dd) SwigIsKlass_dd() { -} - -var _wrap_new_Klass_dd unsafe.Pointer - -func _swig_wrap_new_Klass_dd() (base SwigcptrKlass_dd) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Klass_dd, _swig_p) - return -} - -func NewKlass_dd() (_swig_ret Klass_dd) { - return _swig_wrap_new_Klass_dd() -} - -var _wrap_delete_Klass_dd unsafe.Pointer - -func _swig_wrap_delete_Klass_dd(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Klass_dd, _swig_p) - return -} - -func DeleteKlass_dd(arg1 Klass_dd) { - _swig_wrap_delete_Klass_dd(arg1.Swigcptr()) -} - -func (p SwigcptrKlass_dd) SwigIsFunktion_dd() { -} - -func (p SwigcptrKlass_dd) SwigGetFunktion_dd() Funktion_dd { - return SwigcptrFunktion_dd(p.Swigcptr()) -} - -type Klass_dd interface { - Swigcptr() uintptr - SwigIsKlass_dd() - SwigIsFunktion_dd() - SwigGetFunktion_dd() Funktion_dd -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/template_basic.go b/Examples/test-suite/go/template_basic.go deleted file mode 100644 index d4bb23bf2..000000000 --- a/Examples/test-suite/go/template_basic.go +++ /dev/null @@ -1,289 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../template_basic.i - -package template_basic - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -var _wrap_maxint unsafe.Pointer - -func Maxint(arg1 int, arg2 int) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_maxint, _swig_p) - return -} -var _wrap_maxdouble unsafe.Pointer - -func Maxdouble(arg1 float64, arg2 float64) (_swig_ret float64) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_maxdouble, _swig_p) - return -} -type SwigcptrVecint uintptr - -func (p SwigcptrVecint) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrVecint) SwigIsVecint() { -} - -var _wrap_new_vecint unsafe.Pointer - -func _swig_wrap_new_vecint(base int) (_ SwigcptrVecint) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_vecint, _swig_p) - return -} - -func NewVecint(arg1 int) (_swig_ret Vecint) { - return _swig_wrap_new_vecint(arg1) -} - -var _wrap_vecint_get unsafe.Pointer - -func _swig_wrap_vecint_get(base SwigcptrVecint, _ int) (_ *int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_vecint_get, _swig_p) - return -} - -func (arg1 SwigcptrVecint) Get(arg2 int) (_swig_ret *int) { - return _swig_wrap_vecint_get(arg1, arg2) -} - -var _wrap_vecint_set unsafe.Pointer - -func _swig_wrap_vecint_set(base SwigcptrVecint, _ int, _ *int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_vecint_set, _swig_p) - return -} - -func (arg1 SwigcptrVecint) Set(arg2 int, arg3 *int) { - _swig_wrap_vecint_set(arg1, arg2, arg3) -} - -var _wrap_vecint_testconst unsafe.Pointer - -func _swig_wrap_vecint_testconst(base SwigcptrVecint, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_vecint_testconst, _swig_p) - return -} - -func (arg1 SwigcptrVecint) Testconst(arg2 int) { - _swig_wrap_vecint_testconst(arg1, arg2) -} - -var _wrap_delete_vecint unsafe.Pointer - -func _swig_wrap_delete_vecint(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_vecint, _swig_p) - return -} - -func DeleteVecint(arg1 Vecint) { - _swig_wrap_delete_vecint(arg1.Swigcptr()) -} - -type Vecint interface { - Swigcptr() uintptr - SwigIsVecint() - Get(arg2 int) (_swig_ret *int) - Set(arg2 int, arg3 *int) - Testconst(arg2 int) -} - -type SwigcptrVecdouble uintptr - -func (p SwigcptrVecdouble) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrVecdouble) SwigIsVecdouble() { -} - -var _wrap_new_vecdouble unsafe.Pointer - -func _swig_wrap_new_vecdouble(base int) (_ SwigcptrVecdouble) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_vecdouble, _swig_p) - return -} - -func NewVecdouble(arg1 int) (_swig_ret Vecdouble) { - return _swig_wrap_new_vecdouble(arg1) -} - -var _wrap_vecdouble_get unsafe.Pointer - -func _swig_wrap_vecdouble_get(base SwigcptrVecdouble, _ int) (_ *float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_vecdouble_get, _swig_p) - return -} - -func (arg1 SwigcptrVecdouble) Get(arg2 int) (_swig_ret *float64) { - return _swig_wrap_vecdouble_get(arg1, arg2) -} - -var _wrap_vecdouble_set unsafe.Pointer - -func _swig_wrap_vecdouble_set(base SwigcptrVecdouble, _ int, _ *float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_vecdouble_set, _swig_p) - return -} - -func (arg1 SwigcptrVecdouble) Set(arg2 int, arg3 *float64) { - _swig_wrap_vecdouble_set(arg1, arg2, arg3) -} - -var _wrap_vecdouble_testconst unsafe.Pointer - -func _swig_wrap_vecdouble_testconst(base SwigcptrVecdouble, _ float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_vecdouble_testconst, _swig_p) - return -} - -func (arg1 SwigcptrVecdouble) Testconst(arg2 float64) { - _swig_wrap_vecdouble_testconst(arg1, arg2) -} - -var _wrap_delete_vecdouble unsafe.Pointer - -func _swig_wrap_delete_vecdouble(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_vecdouble, _swig_p) - return -} - -func DeleteVecdouble(arg1 Vecdouble) { - _swig_wrap_delete_vecdouble(arg1.Swigcptr()) -} - -type Vecdouble interface { - Swigcptr() uintptr - SwigIsVecdouble() - Get(arg2 int) (_swig_ret *float64) - Set(arg2 int, arg3 *float64) - Testconst(arg2 float64) -} - -var _wrap_maxintp unsafe.Pointer - -func Maxintp(arg1 **int, arg2 **int) (_swig_ret **int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_maxintp, _swig_p) - return -} -type SwigcptrVecintp uintptr - -func (p SwigcptrVecintp) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrVecintp) SwigIsVecintp() { -} - -var _wrap_new_vecintp unsafe.Pointer - -func _swig_wrap_new_vecintp(base int) (_ SwigcptrVecintp) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_vecintp, _swig_p) - return -} - -func NewVecintp(arg1 int) (_swig_ret Vecintp) { - return _swig_wrap_new_vecintp(arg1) -} - -var _wrap_vecintp_get unsafe.Pointer - -func _swig_wrap_vecintp_get(base SwigcptrVecintp, _ int) (_ ***int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_vecintp_get, _swig_p) - return -} - -func (arg1 SwigcptrVecintp) Get(arg2 int) (_swig_ret ***int) { - return _swig_wrap_vecintp_get(arg1, arg2) -} - -var _wrap_vecintp_set unsafe.Pointer - -func _swig_wrap_vecintp_set(base SwigcptrVecintp, _ int, _ ***int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_vecintp_set, _swig_p) - return -} - -func (arg1 SwigcptrVecintp) Set(arg2 int, arg3 ***int) { - _swig_wrap_vecintp_set(arg1, arg2, arg3) -} - -var _wrap_vecintp_testconst unsafe.Pointer - -func _swig_wrap_vecintp_testconst(base SwigcptrVecintp, _ **int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_vecintp_testconst, _swig_p) - return -} - -func (arg1 SwigcptrVecintp) Testconst(arg2 **int) { - _swig_wrap_vecintp_testconst(arg1, arg2) -} - -var _wrap_delete_vecintp unsafe.Pointer - -func _swig_wrap_delete_vecintp(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_vecintp, _swig_p) - return -} - -func DeleteVecintp(arg1 Vecintp) { - _swig_wrap_delete_vecintp(arg1.Swigcptr()) -} - -type Vecintp interface { - Swigcptr() uintptr - SwigIsVecintp() - Get(arg2 int) (_swig_ret ***int) - Set(arg2 int, arg3 ***int) - Testconst(arg2 **int) -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/template_classes.go b/Examples/test-suite/go/template_classes.go deleted file mode 100644 index ffbb94187..000000000 --- a/Examples/test-suite/go/template_classes.go +++ /dev/null @@ -1,152 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../template_classes.i - -package template_classes - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrPointInt uintptr - -func (p SwigcptrPointInt) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrPointInt) SwigIsPointInt() { -} - -var _wrap_PointInt_getX unsafe.Pointer - -func _swig_wrap_PointInt_getX(base SwigcptrPointInt) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_PointInt_getX, _swig_p) - return -} - -func (arg1 SwigcptrPointInt) GetX() (_swig_ret int) { - return _swig_wrap_PointInt_getX(arg1) -} - -var _wrap_new_PointInt unsafe.Pointer - -func _swig_wrap_new_PointInt() (base SwigcptrPointInt) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_PointInt, _swig_p) - return -} - -func NewPointInt() (_swig_ret PointInt) { - return _swig_wrap_new_PointInt() -} - -var _wrap_delete_PointInt unsafe.Pointer - -func _swig_wrap_delete_PointInt(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_PointInt, _swig_p) - return -} - -func DeletePointInt(arg1 PointInt) { - _swig_wrap_delete_PointInt(arg1.Swigcptr()) -} - -type PointInt interface { - Swigcptr() uintptr - SwigIsPointInt() - GetX() (_swig_ret int) -} - -type SwigcptrRectangleInt uintptr - -func (p SwigcptrRectangleInt) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrRectangleInt) SwigIsRectangleInt() { -} - -var _wrap_RectangleInt_getPoint unsafe.Pointer - -func _swig_wrap_RectangleInt_getPoint(base SwigcptrRectangleInt) (_ SwigcptrPointInt) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_RectangleInt_getPoint, _swig_p) - return -} - -func (arg1 SwigcptrRectangleInt) GetPoint() (_swig_ret PointInt) { - return _swig_wrap_RectangleInt_getPoint(arg1) -} - -var _wrap_RectangleInt_setPoint unsafe.Pointer - -func _swig_wrap_RectangleInt_setPoint(base SwigcptrRectangleInt, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_RectangleInt_setPoint, _swig_p) - return -} - -func (arg1 SwigcptrRectangleInt) SetPoint(arg2 PointInt) { - _swig_wrap_RectangleInt_setPoint(arg1, arg2.Swigcptr()) -} - -var _wrap_new_RectangleInt unsafe.Pointer - -func _swig_wrap_new_RectangleInt() (base SwigcptrRectangleInt) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_RectangleInt, _swig_p) - return -} - -func NewRectangleInt() (_swig_ret RectangleInt) { - return _swig_wrap_new_RectangleInt() -} - -var _wrap_delete_RectangleInt unsafe.Pointer - -func _swig_wrap_delete_RectangleInt(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_RectangleInt, _swig_p) - return -} - -func DeleteRectangleInt(arg1 RectangleInt) { - _swig_wrap_delete_RectangleInt(arg1.Swigcptr()) -} - -type RectangleInt interface { - Swigcptr() uintptr - SwigIsRectangleInt() - GetPoint() (_swig_ret PointInt) - SetPoint(arg2 PointInt) -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/template_const_ref.go b/Examples/test-suite/go/template_const_ref.go deleted file mode 100644 index 99b9a0680..000000000 --- a/Examples/test-suite/go/template_const_ref.go +++ /dev/null @@ -1,177 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../template_const_ref.i - -package template_const_ref - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrBar uintptr - -func (p SwigcptrBar) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrBar) SwigIsBar() { -} - -var _wrap_new_Bar unsafe.Pointer - -func _swig_wrap_new_Bar() (base SwigcptrBar) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Bar, _swig_p) - return -} - -func NewBar() (_swig_ret Bar) { - return _swig_wrap_new_Bar() -} - -var _wrap_delete_Bar unsafe.Pointer - -func _swig_wrap_delete_Bar(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Bar, _swig_p) - return -} - -func DeleteBar(arg1 Bar) { - _swig_wrap_delete_Bar(arg1.Swigcptr()) -} - -type Bar interface { - Swigcptr() uintptr - SwigIsBar() -} - -type SwigcptrFoob uintptr - -func (p SwigcptrFoob) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrFoob) SwigIsFoob() { -} - -var _wrap_Foob_bar unsafe.Pointer - -func _swig_wrap_Foob_bar(base SwigcptrFoob, _ uintptr) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foob_bar, _swig_p) - return -} - -func (arg1 SwigcptrFoob) Bar(arg2 Bar) (_swig_ret string) { - return _swig_wrap_Foob_bar(arg1, arg2.Swigcptr()) -} - -var _wrap_new_Foob unsafe.Pointer - -func _swig_wrap_new_Foob() (base SwigcptrFoob) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Foob, _swig_p) - return -} - -func NewFoob() (_swig_ret Foob) { - return _swig_wrap_new_Foob() -} - -var _wrap_delete_Foob unsafe.Pointer - -func _swig_wrap_delete_Foob(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Foob, _swig_p) - return -} - -func DeleteFoob(arg1 Foob) { - _swig_wrap_delete_Foob(arg1.Swigcptr()) -} - -type Foob interface { - Swigcptr() uintptr - SwigIsFoob() - Bar(arg2 Bar) (_swig_ret string) -} - -type SwigcptrFooi uintptr - -func (p SwigcptrFooi) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrFooi) SwigIsFooi() { -} - -var _wrap_Fooi_bar unsafe.Pointer - -func _swig_wrap_Fooi_bar(base SwigcptrFooi, _ *int) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Fooi_bar, _swig_p) - return -} - -func (arg1 SwigcptrFooi) Bar(arg2 *int) (_swig_ret string) { - return _swig_wrap_Fooi_bar(arg1, arg2) -} - -var _wrap_new_Fooi unsafe.Pointer - -func _swig_wrap_new_Fooi() (base SwigcptrFooi) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Fooi, _swig_p) - return -} - -func NewFooi() (_swig_ret Fooi) { - return _swig_wrap_new_Fooi() -} - -var _wrap_delete_Fooi unsafe.Pointer - -func _swig_wrap_delete_Fooi(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Fooi, _swig_p) - return -} - -func DeleteFooi(arg1 Fooi) { - _swig_wrap_delete_Fooi(arg1.Swigcptr()) -} - -type Fooi interface { - Swigcptr() uintptr - SwigIsFooi() - Bar(arg2 *int) (_swig_ret string) -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/template_construct.go b/Examples/test-suite/go/template_construct.go deleted file mode 100644 index b6abfb002..000000000 --- a/Examples/test-suite/go/template_construct.go +++ /dev/null @@ -1,75 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../template_construct.i - -package template_construct - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrFoo_int uintptr - -func (p SwigcptrFoo_int) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrFoo_int) SwigIsFoo_int() { -} - -var _wrap_new_Foo_int unsafe.Pointer - -func _swig_wrap_new_Foo_int(base int) (_ SwigcptrFoo_int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Foo_int, _swig_p) - return -} - -func NewFoo_int(arg1 int) (_swig_ret Foo_int) { - return _swig_wrap_new_Foo_int(arg1) -} - -var _wrap_delete_Foo_int unsafe.Pointer - -func _swig_wrap_delete_Foo_int(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Foo_int, _swig_p) - return -} - -func DeleteFoo_int(arg1 Foo_int) { - _swig_wrap_delete_Foo_int(arg1.Swigcptr()) -} - -type Foo_int interface { - Swigcptr() uintptr - SwigIsFoo_int() -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/template_default.go b/Examples/test-suite/go/template_default.go deleted file mode 100644 index 7b29b2962..000000000 --- a/Examples/test-suite/go/template_default.go +++ /dev/null @@ -1,793 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../template_default.i - -package template_default - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrParm uintptr - -func (p SwigcptrParm) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrParm) SwigIsParm() { -} - -var _wrap_new_Parm unsafe.Pointer - -func _swig_wrap_new_Parm() (base SwigcptrParm) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Parm, _swig_p) - return -} - -func NewParm() (_swig_ret Parm) { - return _swig_wrap_new_Parm() -} - -var _wrap_delete_Parm unsafe.Pointer - -func _swig_wrap_delete_Parm(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Parm, _swig_p) - return -} - -func DeleteParm(arg1 Parm) { - _swig_wrap_delete_Parm(arg1.Swigcptr()) -} - -type Parm interface { - Swigcptr() uintptr - SwigIsParm() -} - -var _wrap_one_get unsafe.Pointer - -func GetOne() (_swig_ret uint) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_one_get, _swig_p) - return -} -var _wrap_two_get unsafe.Pointer - -func GetTwo() (_swig_ret uint) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_two_get, _swig_p) - return -} -type SwigcptrA_p uintptr - -func (p SwigcptrA_p) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrA_p) SwigIsA_p() { -} - -var _wrap_new_A_p unsafe.Pointer - -func _swig_wrap_new_A_p() (base SwigcptrA_p) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_A_p, _swig_p) - return -} - -func NewA_p() (_swig_ret A_p) { - return _swig_wrap_new_A_p() -} - -var _wrap_delete_A_p unsafe.Pointer - -func _swig_wrap_delete_A_p(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_A_p, _swig_p) - return -} - -func DeleteA_p(arg1 A_p) { - _swig_wrap_delete_A_p(arg1.Swigcptr()) -} - -type A_p interface { - Swigcptr() uintptr - SwigIsA_p() -} - -type SwigcptrN_1p uintptr - -func (p SwigcptrN_1p) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrN_1p) SwigIsN_1p() { -} - -var _wrap_new_N_1p unsafe.Pointer - -func _swig_wrap_new_N_1p() (base SwigcptrN_1p) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_N_1p, _swig_p) - return -} - -func NewN_1p() (_swig_ret N_1p) { - return _swig_wrap_new_N_1p() -} - -var _wrap_delete_N_1p unsafe.Pointer - -func _swig_wrap_delete_N_1p(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_N_1p, _swig_p) - return -} - -func DeleteN_1p(arg1 N_1p) { - _swig_wrap_delete_N_1p(arg1.Swigcptr()) -} - -type N_1p interface { - Swigcptr() uintptr - SwigIsN_1p() -} - -type SwigcptrA_ii uintptr - -func (p SwigcptrA_ii) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrA_ii) SwigIsA_ii() { -} - -var _wrap_A_ii_bar unsafe.Pointer - -func _swig_wrap_A_ii_bar(base SwigcptrA_ii) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_A_ii_bar, _swig_p) - return -} - -func (arg1 SwigcptrA_ii) Bar() (_swig_ret int) { - return _swig_wrap_A_ii_bar(arg1) -} - -var _wrap_new_A_ii unsafe.Pointer - -func _swig_wrap_new_A_ii() (base SwigcptrA_ii) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_A_ii, _swig_p) - return -} - -func NewA_ii() (_swig_ret A_ii) { - return _swig_wrap_new_A_ii() -} - -var _wrap_delete_A_ii unsafe.Pointer - -func _swig_wrap_delete_A_ii(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_A_ii, _swig_p) - return -} - -func DeleteA_ii(arg1 A_ii) { - _swig_wrap_delete_A_ii(arg1.Swigcptr()) -} - -type A_ii interface { - Swigcptr() uintptr - SwigIsA_ii() - Bar() (_swig_ret int) -} - -type SwigcptrA_d uintptr - -func (p SwigcptrA_d) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrA_d) SwigIsA_d() { -} - -var _wrap_A_d_bar unsafe.Pointer - -func _swig_wrap_A_d_bar(base SwigcptrA_d) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_A_d_bar, _swig_p) - return -} - -func (arg1 SwigcptrA_d) Bar() (_swig_ret int) { - return _swig_wrap_A_d_bar(arg1) -} - -var _wrap_new_A_d unsafe.Pointer - -func _swig_wrap_new_A_d() (base SwigcptrA_d) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_A_d, _swig_p) - return -} - -func NewA_d() (_swig_ret A_d) { - return _swig_wrap_new_A_d() -} - -var _wrap_delete_A_d unsafe.Pointer - -func _swig_wrap_delete_A_d(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_A_d, _swig_p) - return -} - -func DeleteA_d(arg1 A_d) { - _swig_wrap_delete_A_d(arg1.Swigcptr()) -} - -type A_d interface { - Swigcptr() uintptr - SwigIsA_d() - Bar() (_swig_ret int) -} - -type SwigcptrN_d uintptr - -func (p SwigcptrN_d) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrN_d) SwigIsN_d() { -} - -var _wrap_N_d_bar unsafe.Pointer - -func _swig_wrap_N_d_bar(base SwigcptrN_d) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_N_d_bar, _swig_p) - return -} - -func (arg1 SwigcptrN_d) Bar() (_swig_ret int) { - return _swig_wrap_N_d_bar(arg1) -} - -var _wrap_new_N_d unsafe.Pointer - -func _swig_wrap_new_N_d() (base SwigcptrN_d) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_N_d, _swig_p) - return -} - -func NewN_d() (_swig_ret N_d) { - return _swig_wrap_new_N_d() -} - -var _wrap_delete_N_d unsafe.Pointer - -func _swig_wrap_delete_N_d(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_N_d, _swig_p) - return -} - -func DeleteN_d(arg1 N_d) { - _swig_wrap_delete_N_d(arg1.Swigcptr()) -} - -type N_d interface { - Swigcptr() uintptr - SwigIsN_d() - Bar() (_swig_ret int) -} - -type SwigcptrB uintptr - -func (p SwigcptrB) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrB) SwigIsB() { -} - -var _wrap_new_B unsafe.Pointer - -func _swig_wrap_new_B() (base SwigcptrB) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_B, _swig_p) - return -} - -func NewB() (_swig_ret B) { - return _swig_wrap_new_B() -} - -var _wrap_delete_B unsafe.Pointer - -func _swig_wrap_delete_B(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_B, _swig_p) - return -} - -func DeleteB(arg1 B) { - _swig_wrap_delete_B(arg1.Swigcptr()) -} - -func (p SwigcptrB) SwigIsA_ii() { -} - -func (p SwigcptrB) SwigGetA_ii() A_ii { - return SwigcptrA_ii(p.Swigcptr()) -} - -type B interface { - Swigcptr() uintptr - SwigIsB() - SwigIsA_ii() - SwigGetA_ii() A_ii -} - -type SwigcptrC uintptr - -func (p SwigcptrC) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrC) SwigIsC() { -} - -var _wrap_new_C unsafe.Pointer - -func _swig_wrap_new_C() (base SwigcptrC) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_C, _swig_p) - return -} - -func NewC() (_swig_ret C) { - return _swig_wrap_new_C() -} - -var _wrap_delete_C unsafe.Pointer - -func _swig_wrap_delete_C(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_C, _swig_p) - return -} - -func DeleteC(arg1 C) { - _swig_wrap_delete_C(arg1.Swigcptr()) -} - -func (p SwigcptrC) SwigIsN_d() { -} - -func (p SwigcptrC) SwigGetN_d() N_d { - return SwigcptrN_d(p.Swigcptr()) -} - -type C interface { - Swigcptr() uintptr - SwigIsC() - SwigIsN_d() - SwigGetN_d() N_d -} - -var _wrap_get_a1 unsafe.Pointer - -func _swig_wrap_get_a1(base uintptr) (_ SwigcptrA_ii) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_get_a1, _swig_p) - return -} - -func Get_a1(arg1 A_ii) (_swig_ret A_ii) { - return _swig_wrap_get_a1(arg1.Swigcptr()) -} - -var _wrap_get_a2 unsafe.Pointer - -func _swig_wrap_get_a2(base uintptr) (_ SwigcptrA_ii) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_get_a2, _swig_p) - return -} - -func Get_a2(arg1 A_ii) (_swig_ret A_ii) { - return _swig_wrap_get_a2(arg1.Swigcptr()) -} - -type SwigcptrTraits uintptr - -func (p SwigcptrTraits) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrTraits) SwigIsTraits() { -} - -var _wrap_Traits_c_Traits unsafe.Pointer - -func _swig_getTraits_Traits_c_Traits() (_swig_ret uint) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_Traits_c_Traits, _swig_p) - return -} -var TraitsC uint = _swig_getTraits_Traits_c_Traits() -var _wrap_new_Traits unsafe.Pointer - -func _swig_wrap_new_Traits() (base SwigcptrTraits) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Traits, _swig_p) - return -} - -func NewTraits() (_swig_ret Traits) { - return _swig_wrap_new_Traits() -} - -var _wrap_delete_Traits unsafe.Pointer - -func _swig_wrap_delete_Traits(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Traits, _swig_p) - return -} - -func DeleteTraits(arg1 Traits) { - _swig_wrap_delete_Traits(arg1.Swigcptr()) -} - -type Traits interface { - Swigcptr() uintptr - SwigIsTraits() -} - -type SwigcptrDoo uintptr - -func (p SwigcptrDoo) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrDoo) SwigIsDoo() { -} - -var _wrap_new_Doo unsafe.Pointer - -func _swig_wrap_new_Doo() (base SwigcptrDoo) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Doo, _swig_p) - return -} - -func NewDoo() (_swig_ret Doo) { - return _swig_wrap_new_Doo() -} - -var _wrap_delete_Doo unsafe.Pointer - -func _swig_wrap_delete_Doo(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Doo, _swig_p) - return -} - -func DeleteDoo(arg1 Doo) { - _swig_wrap_delete_Doo(arg1.Swigcptr()) -} - -func (p SwigcptrDoo) SwigIsN_d() { -} - -func (p SwigcptrDoo) SwigGetN_d() N_d { - return SwigcptrN_d(p.Swigcptr()) -} - -type Doo interface { - Swigcptr() uintptr - SwigIsDoo() - SwigIsN_d() - SwigGetN_d() N_d -} - -type SwigcptrBoo uintptr - -func (p SwigcptrBoo) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrBoo) SwigIsBoo() { -} - -var _wrap_new_Boo unsafe.Pointer - -func _swig_wrap_new_Boo() (base SwigcptrBoo) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Boo, _swig_p) - return -} - -func NewBoo() (_swig_ret Boo) { - return _swig_wrap_new_Boo() -} - -var _wrap_delete_Boo unsafe.Pointer - -func _swig_wrap_delete_Boo(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Boo, _swig_p) - return -} - -func DeleteBoo(arg1 Boo) { - _swig_wrap_delete_Boo(arg1.Swigcptr()) -} - -func (p SwigcptrBoo) SwigIsDoo() { -} - -func (p SwigcptrBoo) SwigGetDoo() Doo { - return SwigcptrDoo(p.Swigcptr()) -} - -func (p SwigcptrBoo) SwigIsN_d() { -} - -func (p SwigcptrBoo) SwigGetN_d() N_d { - return SwigcptrN_d(p.Swigcptr()) -} - -type Boo interface { - Swigcptr() uintptr - SwigIsBoo() - SwigIsDoo() - SwigGetDoo() Doo - SwigIsN_d() - SwigGetN_d() N_d -} - -type SwigcptrDer uintptr - -func (p SwigcptrDer) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrDer) SwigIsDer() { -} - -var _wrap_new_Der unsafe.Pointer - -func _swig_wrap_new_Der() (base SwigcptrDer) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Der, _swig_p) - return -} - -func NewDer() (_swig_ret Der) { - return _swig_wrap_new_Der() -} - -var _wrap_delete_Der unsafe.Pointer - -func _swig_wrap_delete_Der(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Der, _swig_p) - return -} - -func DeleteDer(arg1 Der) { - _swig_wrap_delete_Der(arg1.Swigcptr()) -} - -func (p SwigcptrDer) SwigIsBoo() { -} - -func (p SwigcptrDer) SwigGetBoo() Boo { - return SwigcptrBoo(p.Swigcptr()) -} - -func (p SwigcptrDer) SwigIsDoo() { -} - -func (p SwigcptrDer) SwigGetDoo() Doo { - return SwigcptrDoo(p.Swigcptr()) -} - -func (p SwigcptrDer) SwigIsN_d() { -} - -func (p SwigcptrDer) SwigGetN_d() N_d { - return SwigcptrN_d(p.Swigcptr()) -} - -type Der interface { - Swigcptr() uintptr - SwigIsDer() - SwigIsBoo() - SwigGetBoo() Boo - SwigIsDoo() - SwigGetDoo() Doo - SwigIsN_d() - SwigGetN_d() N_d -} - -type SwigcptrCFoo uintptr - -func (p SwigcptrCFoo) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrCFoo) SwigIsCFoo() { -} - -var _wrap_new_CFoo unsafe.Pointer - -func _swig_wrap_new_CFoo() (base SwigcptrCFoo) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_CFoo, _swig_p) - return -} - -func NewCFoo() (_swig_ret CFoo) { - return _swig_wrap_new_CFoo() -} - -var _wrap_delete_CFoo unsafe.Pointer - -func _swig_wrap_delete_CFoo(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_CFoo, _swig_p) - return -} - -func DeleteCFoo(arg1 CFoo) { - _swig_wrap_delete_CFoo(arg1.Swigcptr()) -} - -type CFoo interface { - Swigcptr() uintptr - SwigIsCFoo() -} - -var _wrap_foo unsafe.Pointer - -func Foo(arg1 *_swig_fnptr, arg2 *_swig_fnptr, arg3 *_swig_fnptr) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_foo, _swig_p) - return -} -var _wrap_g__SWIG_0 unsafe.Pointer - -func _swig_wrap_g__SWIG_0(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_g__SWIG_0, _swig_p) - return -} - -func G__SWIG_0(arg1 Std_vector_Sl_double_Sg_) { - _swig_wrap_g__SWIG_0(arg1.Swigcptr()) -} - -var _wrap_g__SWIG_1 unsafe.Pointer - -func _swig_wrap_g__SWIG_1() { - var _swig_p uintptr - _cgo_runtime_cgocall(_wrap_g__SWIG_1, _swig_p) - return -} - -func G__SWIG_1() { - _swig_wrap_g__SWIG_1() -} - -func G(a ...interface{}) { - argc := len(a) - if argc == 0 { - G__SWIG_1() - return - } - if argc == 1 { - G__SWIG_0(a[0].(Std_vector_Sl_double_Sg_)) - return - } - panic("No match for overloaded function call") -} - -var _wrap_q__SWIG_0 unsafe.Pointer - -func _swig_wrap_q__SWIG_0(base float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_q__SWIG_0, _swig_p) - return -} - -func Q__SWIG_0(arg1 float64) { - _swig_wrap_q__SWIG_0(arg1) -} - -var _wrap_q__SWIG_1 unsafe.Pointer - -func _swig_wrap_q__SWIG_1() { - var _swig_p uintptr - _cgo_runtime_cgocall(_wrap_q__SWIG_1, _swig_p) - return -} - -func Q__SWIG_1() { - _swig_wrap_q__SWIG_1() -} - -func Q(a ...interface{}) { - argc := len(a) - if argc == 0 { - Q__SWIG_1() - return - } - if argc == 1 { - Q__SWIG_0(a[0].(float64)) - return - } - panic("No match for overloaded function call") -} - -var _wrap_Bf unsafe.Pointer - -func _swig_getBf() (_swig_ret _swig_fnptr) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_Bf, _swig_p) - return -} -var Bf _swig_fnptr = _swig_getBf() -var _wrap_Cf unsafe.Pointer - -func _swig_getCf() (_swig_ret _swig_fnptr) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_Cf, _swig_p) - return -} -var Cf _swig_fnptr = _swig_getCf() - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - -type SwigcptrStd_vector_Sl_double_Sg_ uintptr -type Std_vector_Sl_double_Sg_ interface { - Swigcptr() uintptr; -} -func (p SwigcptrStd_vector_Sl_double_Sg_) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/template_default2.go b/Examples/test-suite/go/template_default2.go deleted file mode 100644 index fe4f1acb2..000000000 --- a/Examples/test-suite/go/template_default2.go +++ /dev/null @@ -1,279 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../template_default2.i - -package template_default2 - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type OssPolarization int -var _wrap_UnaryPolarization unsafe.Pointer - -func _swig_getUnaryPolarization() (_swig_ret OssPolarization) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_UnaryPolarization, _swig_p) - return -} -var UnaryPolarization OssPolarization = _swig_getUnaryPolarization() -var _wrap_BinaryPolarization unsafe.Pointer - -func _swig_getBinaryPolarization() (_swig_ret OssPolarization) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_BinaryPolarization, _swig_p) - return -} -var BinaryPolarization OssPolarization = _swig_getBinaryPolarization() -type SwigcptrTraits uintptr - -func (p SwigcptrTraits) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrTraits) SwigIsTraits() { -} - -var _wrap_traits_pmode_traits unsafe.Pointer - -func _swig_gettraits_traits_pmode_traits() (_swig_ret OssPolarization) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_traits_pmode_traits, _swig_p) - return -} -var TraitsPmode OssPolarization = _swig_gettraits_traits_pmode_traits() -var _wrap_new_traits unsafe.Pointer - -func _swig_wrap_new_traits() (base SwigcptrTraits) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_traits, _swig_p) - return -} - -func NewTraits() (_swig_ret Traits) { - return _swig_wrap_new_traits() -} - -var _wrap_delete_traits unsafe.Pointer - -func _swig_wrap_delete_traits(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_traits, _swig_p) - return -} - -func DeleteTraits(arg1 Traits) { - _swig_wrap_delete_traits(arg1.Swigcptr()) -} - -type Traits interface { - Swigcptr() uintptr - SwigIsTraits() -} - -type SwigcptrInterface_UP uintptr - -func (p SwigcptrInterface_UP) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrInterface_UP) SwigIsInterface_UP() { -} - -var _wrap_new_Interface_UP unsafe.Pointer - -func _swig_wrap_new_Interface_UP() (base SwigcptrInterface_UP) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Interface_UP, _swig_p) - return -} - -func NewInterface_UP() (_swig_ret Interface_UP) { - return _swig_wrap_new_Interface_UP() -} - -var _wrap_delete_Interface_UP unsafe.Pointer - -func _swig_wrap_delete_Interface_UP(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Interface_UP, _swig_p) - return -} - -func DeleteInterface_UP(arg1 Interface_UP) { - _swig_wrap_delete_Interface_UP(arg1.Swigcptr()) -} - -type Interface_UP interface { - Swigcptr() uintptr - SwigIsInterface_UP() -} - -type SwigcptrModule_UP1 uintptr - -func (p SwigcptrModule_UP1) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrModule_UP1) SwigIsModule_UP1() { -} - -var _wrap_new_Module_UP1 unsafe.Pointer - -func _swig_wrap_new_Module_UP1() (base SwigcptrModule_UP1) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Module_UP1, _swig_p) - return -} - -func NewModule_UP1() (_swig_ret Module_UP1) { - return _swig_wrap_new_Module_UP1() -} - -var _wrap_delete_Module_UP1 unsafe.Pointer - -func _swig_wrap_delete_Module_UP1(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Module_UP1, _swig_p) - return -} - -func DeleteModule_UP1(arg1 Module_UP1) { - _swig_wrap_delete_Module_UP1(arg1.Swigcptr()) -} - -func (p SwigcptrModule_UP1) SwigIsInterface_UP() { -} - -func (p SwigcptrModule_UP1) SwigGetInterface_UP() Interface_UP { - return SwigcptrInterface_UP(p.Swigcptr()) -} - -type Module_UP1 interface { - Swigcptr() uintptr - SwigIsModule_UP1() - SwigIsInterface_UP() - SwigGetInterface_UP() Interface_UP -} - -type SwigcptrModule_UP2 uintptr - -func (p SwigcptrModule_UP2) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrModule_UP2) SwigIsModule_UP2() { -} - -var _wrap_new_Module_UP2 unsafe.Pointer - -func _swig_wrap_new_Module_UP2() (base SwigcptrModule_UP2) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Module_UP2, _swig_p) - return -} - -func NewModule_UP2() (_swig_ret Module_UP2) { - return _swig_wrap_new_Module_UP2() -} - -var _wrap_delete_Module_UP2 unsafe.Pointer - -func _swig_wrap_delete_Module_UP2(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Module_UP2, _swig_p) - return -} - -func DeleteModule_UP2(arg1 Module_UP2) { - _swig_wrap_delete_Module_UP2(arg1.Swigcptr()) -} - -func (p SwigcptrModule_UP2) SwigIsInterface_UP() { -} - -func (p SwigcptrModule_UP2) SwigGetInterface_UP() Interface_UP { - return SwigcptrInterface_UP(p.Swigcptr()) -} - -type Module_UP2 interface { - Swigcptr() uintptr - SwigIsModule_UP2() - SwigIsInterface_UP() - SwigGetInterface_UP() Interface_UP -} - -type SwigcptrModule_UP3 uintptr - -func (p SwigcptrModule_UP3) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrModule_UP3) SwigIsModule_UP3() { -} - -var _wrap_new_Module_UP3 unsafe.Pointer - -func _swig_wrap_new_Module_UP3() (base SwigcptrModule_UP3) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Module_UP3, _swig_p) - return -} - -func NewModule_UP3() (_swig_ret Module_UP3) { - return _swig_wrap_new_Module_UP3() -} - -var _wrap_delete_Module_UP3 unsafe.Pointer - -func _swig_wrap_delete_Module_UP3(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Module_UP3, _swig_p) - return -} - -func DeleteModule_UP3(arg1 Module_UP3) { - _swig_wrap_delete_Module_UP3(arg1.Swigcptr()) -} - -func (p SwigcptrModule_UP3) SwigIsInterface_UP() { -} - -func (p SwigcptrModule_UP3) SwigGetInterface_UP() Interface_UP { - return SwigcptrInterface_UP(p.Swigcptr()) -} - -type Module_UP3 interface { - Swigcptr() uintptr - SwigIsModule_UP3() - SwigIsInterface_UP() - SwigGetInterface_UP() Interface_UP -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/template_default_arg.go b/Examples/test-suite/go/template_default_arg.go deleted file mode 100644 index ba18b8240..000000000 --- a/Examples/test-suite/go/template_default_arg.go +++ /dev/null @@ -1,2105 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../template_default_arg.i - -package template_default_arg - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -var _wrap_foob__SWIG_0 unsafe.Pointer - -func _swig_wrap_foob__SWIG_0(base uintptr) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_foob__SWIG_0, _swig_p) - return -} - -func Foob__SWIG_0(arg1 Foo_int) (_swig_ret int) { - return _swig_wrap_foob__SWIG_0(arg1.Swigcptr()) -} - -var _wrap_foob__SWIG_1 unsafe.Pointer - -func Foob__SWIG_1() (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_foob__SWIG_1, _swig_p) - return -} -func Foob(a ...interface{}) int { - argc := len(a) - if argc == 0 { - return Foob__SWIG_1() - } - if argc == 1 { - return Foob__SWIG_0(a[0].(Foo_int)) - } - panic("No match for overloaded function call") -} - -type SwigcptrFoo_int uintptr - -func (p SwigcptrFoo_int) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrFoo_int) SwigIsFoo_int() { -} - -var _wrap_new_Foo_int__SWIG_0 unsafe.Pointer - -func _swig_wrap_new_Foo_int__SWIG_0(base uint) (_ SwigcptrFoo_int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Foo_int__SWIG_0, _swig_p) - return -} - -func NewFoo_int__SWIG_0(arg1 uint) (_swig_ret Foo_int) { - return _swig_wrap_new_Foo_int__SWIG_0(arg1) -} - -var _wrap_new_Foo_int__SWIG_1 unsafe.Pointer - -func _swig_wrap_new_Foo_int__SWIG_1() (base SwigcptrFoo_int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Foo_int__SWIG_1, _swig_p) - return -} - -func NewFoo_int__SWIG_1() (_swig_ret Foo_int) { - return _swig_wrap_new_Foo_int__SWIG_1() -} - -func NewFoo_int(a ...interface{}) Foo_int { - argc := len(a) - if argc == 0 { - return NewFoo_int__SWIG_1() - } - if argc == 1 { - return NewFoo_int__SWIG_0(a[0].(uint)) - } - panic("No match for overloaded function call") -} - -var _wrap_delete_Foo_int unsafe.Pointer - -func _swig_wrap_delete_Foo_int(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Foo_int, _swig_p) - return -} - -func DeleteFoo_int(arg1 Foo_int) { - _swig_wrap_delete_Foo_int(arg1.Swigcptr()) -} - -type Foo_int interface { - Swigcptr() uintptr - SwigIsFoo_int() -} - -type SwigcptrHello_int uintptr - -func (p SwigcptrHello_int) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrHello_int) SwigIsHello_int() { -} - -var _wrap_new_Hello_int__SWIG_0 unsafe.Pointer - -func _swig_wrap_new_Hello_int__SWIG_0(base uint) (_ SwigcptrHello_int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Hello_int__SWIG_0, _swig_p) - return -} - -func NewHello_int__SWIG_0(arg1 uint) (_swig_ret Hello_int) { - return _swig_wrap_new_Hello_int__SWIG_0(arg1) -} - -var _wrap_new_Hello_int__SWIG_1 unsafe.Pointer - -func _swig_wrap_new_Hello_int__SWIG_1() (base SwigcptrHello_int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Hello_int__SWIG_1, _swig_p) - return -} - -func NewHello_int__SWIG_1() (_swig_ret Hello_int) { - return _swig_wrap_new_Hello_int__SWIG_1() -} - -func NewHello_int(a ...interface{}) Hello_int { - argc := len(a) - if argc == 0 { - return NewHello_int__SWIG_1() - } - if argc == 1 { - return NewHello_int__SWIG_0(a[0].(uint)) - } - panic("No match for overloaded function call") -} - -type Hello_Sl_int_Sg_Hi int -var _wrap_hi_Hello_int unsafe.Pointer - -func _swig_getHello_int_hi_Hello_int() (_swig_ret Hello_Sl_int_Sg_Hi) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_hi_Hello_int, _swig_p) - return -} -var Hello_intHi Hello_Sl_int_Sg_Hi = _swig_getHello_int_hi_Hello_int() -var _wrap_hello_Hello_int unsafe.Pointer - -func _swig_getHello_int_hello_Hello_int() (_swig_ret Hello_Sl_int_Sg_Hi) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_hello_Hello_int, _swig_p) - return -} -var Hello_intHello Hello_Sl_int_Sg_Hi = _swig_getHello_int_hello_Hello_int() -var _wrap_Hello_int_foo__SWIG_0 unsafe.Pointer - -func _swig_wrap_Hello_int_foo__SWIG_0(base SwigcptrHello_int, _ Hello_Sl_int_Sg_Hi) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Hello_int_foo__SWIG_0, _swig_p) - return -} - -func (arg1 SwigcptrHello_int) Foo__SWIG_0(arg2 Hello_Sl_int_Sg_Hi) { - _swig_wrap_Hello_int_foo__SWIG_0(arg1, arg2) -} - -var _wrap_Hello_int_foo__SWIG_1 unsafe.Pointer - -func _swig_wrap_Hello_int_foo__SWIG_1(base SwigcptrHello_int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Hello_int_foo__SWIG_1, _swig_p) - return -} - -func (arg1 SwigcptrHello_int) Foo__SWIG_1() { - _swig_wrap_Hello_int_foo__SWIG_1(arg1) -} - -func (p SwigcptrHello_int) Foo(a ...interface{}) { - argc := len(a) - if argc == 0 { - p.Foo__SWIG_1() - return - } - if argc == 1 { - p.Foo__SWIG_0(a[0].(Hello_Sl_int_Sg_Hi)) - return - } - panic("No match for overloaded function call") -} - -var _wrap_delete_Hello_int unsafe.Pointer - -func _swig_wrap_delete_Hello_int(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Hello_int, _swig_p) - return -} - -func DeleteHello_int(arg1 Hello_int) { - _swig_wrap_delete_Hello_int(arg1.Swigcptr()) -} - -type Hello_int interface { - Swigcptr() uintptr - SwigIsHello_int() - Foo(a ...interface{}) -} - -type SwigcptrX_int uintptr - -func (p SwigcptrX_int) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrX_int) SwigIsX_int() { -} - -var _wrap_new_X_int__SWIG_0 unsafe.Pointer - -func _swig_wrap_new_X_int__SWIG_0(base int) (_ SwigcptrX_int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_X_int__SWIG_0, _swig_p) - return -} - -func NewX_int__SWIG_0(arg1 int) (_swig_ret X_int) { - return _swig_wrap_new_X_int__SWIG_0(arg1) -} - -var _wrap_new_X_int__SWIG_1 unsafe.Pointer - -func _swig_wrap_new_X_int__SWIG_1() (base SwigcptrX_int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_X_int__SWIG_1, _swig_p) - return -} - -func NewX_int__SWIG_1() (_swig_ret X_int) { - return _swig_wrap_new_X_int__SWIG_1() -} - -var _wrap_new_X_int__SWIG_2 unsafe.Pointer - -func _swig_wrap_new_X_int__SWIG_2(base float64, _ int) (_ SwigcptrX_int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_X_int__SWIG_2, _swig_p) - return -} - -func NewX_int__SWIG_2(arg1 float64, arg2 int) (_swig_ret X_int) { - return _swig_wrap_new_X_int__SWIG_2(arg1, arg2) -} - -var _wrap_new_X_int__SWIG_3 unsafe.Pointer - -func _swig_wrap_new_X_int__SWIG_3(base float64) (_ SwigcptrX_int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_X_int__SWIG_3, _swig_p) - return -} - -func NewX_int__SWIG_3(arg1 float64) (_swig_ret X_int) { - return _swig_wrap_new_X_int__SWIG_3(arg1) -} - -func NewX_int(a ...interface{}) X_int { - argc := len(a) - if argc == 0 { - return NewX_int__SWIG_1() - } - if argc == 1 { - if _, ok := a[0].(int); !ok { - goto check_2 - } - return NewX_int__SWIG_0(a[0].(int)) - } -check_2: - if argc == 1 { - return NewX_int__SWIG_3(a[0].(float64)) - } - if argc == 2 { - return NewX_int__SWIG_2(a[0].(float64), a[1].(int)) - } - panic("No match for overloaded function call") -} - -var _wrap_X_int_meth__SWIG_0 unsafe.Pointer - -func _swig_wrap_X_int_meth__SWIG_0(base SwigcptrX_int, _ float64, _ int) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_X_int_meth__SWIG_0, _swig_p) - return -} - -func (arg1 SwigcptrX_int) Meth__SWIG_0(arg2 float64, arg3 int) (_swig_ret int) { - return _swig_wrap_X_int_meth__SWIG_0(arg1, arg2, arg3) -} - -var _wrap_X_int_meth__SWIG_1 unsafe.Pointer - -func _swig_wrap_X_int_meth__SWIG_1(base SwigcptrX_int, _ float64) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_X_int_meth__SWIG_1, _swig_p) - return -} - -func (arg1 SwigcptrX_int) Meth__SWIG_1(arg2 float64) (_swig_ret int) { - return _swig_wrap_X_int_meth__SWIG_1(arg1, arg2) -} - -var _wrap_X_int_meth__SWIG_2 unsafe.Pointer - -func _swig_wrap_X_int_meth__SWIG_2(base SwigcptrX_int, _ int) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_X_int_meth__SWIG_2, _swig_p) - return -} - -func (arg1 SwigcptrX_int) Meth__SWIG_2(arg2 int) (_swig_ret int) { - return _swig_wrap_X_int_meth__SWIG_2(arg1, arg2) -} - -var _wrap_X_int_meth__SWIG_3 unsafe.Pointer - -func _swig_wrap_X_int_meth__SWIG_3(base SwigcptrX_int) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_X_int_meth__SWIG_3, _swig_p) - return -} - -func (arg1 SwigcptrX_int) Meth__SWIG_3() (_swig_ret int) { - return _swig_wrap_X_int_meth__SWIG_3(arg1) -} - -func (p SwigcptrX_int) Meth(a ...interface{}) interface{} { - argc := len(a) - if argc == 0 { - return p.Meth__SWIG_3() - } - if argc == 1 { - if _, ok := a[0].(int); !ok { - goto check_2 - } - return p.Meth__SWIG_2(a[0].(int)) - } -check_2: - if argc == 1 { - return p.Meth__SWIG_1(a[0].(float64)) - } - if argc == 2 { - return p.Meth__SWIG_0(a[0].(float64), a[1].(int)) - } - panic("No match for overloaded function call") -} - -var _wrap_delete_X_int unsafe.Pointer - -func _swig_wrap_delete_X_int(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_X_int, _swig_p) - return -} - -func DeleteX_int(arg1 X_int) { - _swig_wrap_delete_X_int(arg1.Swigcptr()) -} - -type X_int interface { - Swigcptr() uintptr - SwigIsX_int() - Meth(a ...interface{}) interface{} -} - -type SwigcptrX_longlong uintptr - -func (p SwigcptrX_longlong) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrX_longlong) SwigIsX_longlong() { -} - -var _wrap_new_X_longlong__SWIG_0 unsafe.Pointer - -func _swig_wrap_new_X_longlong__SWIG_0(base int64) (_ SwigcptrX_longlong) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_X_longlong__SWIG_0, _swig_p) - return -} - -func NewX_longlong__SWIG_0(arg1 int64) (_swig_ret X_longlong) { - return _swig_wrap_new_X_longlong__SWIG_0(arg1) -} - -var _wrap_new_X_longlong__SWIG_1 unsafe.Pointer - -func _swig_wrap_new_X_longlong__SWIG_1() (base SwigcptrX_longlong) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_X_longlong__SWIG_1, _swig_p) - return -} - -func NewX_longlong__SWIG_1() (_swig_ret X_longlong) { - return _swig_wrap_new_X_longlong__SWIG_1() -} - -var _wrap_new_X_longlong__SWIG_2 unsafe.Pointer - -func _swig_wrap_new_X_longlong__SWIG_2(base float64, _ int64) (_ SwigcptrX_longlong) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_X_longlong__SWIG_2, _swig_p) - return -} - -func NewX_longlong__SWIG_2(arg1 float64, arg2 int64) (_swig_ret X_longlong) { - return _swig_wrap_new_X_longlong__SWIG_2(arg1, arg2) -} - -var _wrap_new_X_longlong__SWIG_3 unsafe.Pointer - -func _swig_wrap_new_X_longlong__SWIG_3(base float64) (_ SwigcptrX_longlong) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_X_longlong__SWIG_3, _swig_p) - return -} - -func NewX_longlong__SWIG_3(arg1 float64) (_swig_ret X_longlong) { - return _swig_wrap_new_X_longlong__SWIG_3(arg1) -} - -func NewX_longlong(a ...interface{}) X_longlong { - argc := len(a) - if argc == 0 { - return NewX_longlong__SWIG_1() - } - if argc == 1 { - if _, ok := a[0].(int64); !ok { - goto check_2 - } - return NewX_longlong__SWIG_0(a[0].(int64)) - } -check_2: - if argc == 1 { - return NewX_longlong__SWIG_3(a[0].(float64)) - } - if argc == 2 { - return NewX_longlong__SWIG_2(a[0].(float64), a[1].(int64)) - } - panic("No match for overloaded function call") -} - -var _wrap_X_longlong_meth__SWIG_0 unsafe.Pointer - -func _swig_wrap_X_longlong_meth__SWIG_0(base SwigcptrX_longlong, _ float64, _ int64) (_ int64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_X_longlong_meth__SWIG_0, _swig_p) - return -} - -func (arg1 SwigcptrX_longlong) Meth__SWIG_0(arg2 float64, arg3 int64) (_swig_ret int64) { - return _swig_wrap_X_longlong_meth__SWIG_0(arg1, arg2, arg3) -} - -var _wrap_X_longlong_meth__SWIG_1 unsafe.Pointer - -func _swig_wrap_X_longlong_meth__SWIG_1(base SwigcptrX_longlong, _ float64) (_ int64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_X_longlong_meth__SWIG_1, _swig_p) - return -} - -func (arg1 SwigcptrX_longlong) Meth__SWIG_1(arg2 float64) (_swig_ret int64) { - return _swig_wrap_X_longlong_meth__SWIG_1(arg1, arg2) -} - -var _wrap_X_longlong_meth__SWIG_2 unsafe.Pointer - -func _swig_wrap_X_longlong_meth__SWIG_2(base SwigcptrX_longlong, _ int64) (_ int64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_X_longlong_meth__SWIG_2, _swig_p) - return -} - -func (arg1 SwigcptrX_longlong) Meth__SWIG_2(arg2 int64) (_swig_ret int64) { - return _swig_wrap_X_longlong_meth__SWIG_2(arg1, arg2) -} - -var _wrap_X_longlong_meth__SWIG_3 unsafe.Pointer - -func _swig_wrap_X_longlong_meth__SWIG_3(base SwigcptrX_longlong) (_ int64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_X_longlong_meth__SWIG_3, _swig_p) - return -} - -func (arg1 SwigcptrX_longlong) Meth__SWIG_3() (_swig_ret int64) { - return _swig_wrap_X_longlong_meth__SWIG_3(arg1) -} - -func (p SwigcptrX_longlong) Meth(a ...interface{}) interface{} { - argc := len(a) - if argc == 0 { - return p.Meth__SWIG_3() - } - if argc == 1 { - if _, ok := a[0].(int64); !ok { - goto check_2 - } - return p.Meth__SWIG_2(a[0].(int64)) - } -check_2: - if argc == 1 { - return p.Meth__SWIG_1(a[0].(float64)) - } - if argc == 2 { - return p.Meth__SWIG_0(a[0].(float64), a[1].(int64)) - } - panic("No match for overloaded function call") -} - -var _wrap_delete_X_longlong unsafe.Pointer - -func _swig_wrap_delete_X_longlong(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_X_longlong, _swig_p) - return -} - -func DeleteX_longlong(arg1 X_longlong) { - _swig_wrap_delete_X_longlong(arg1.Swigcptr()) -} - -type X_longlong interface { - Swigcptr() uintptr - SwigIsX_longlong() - Meth(a ...interface{}) interface{} -} - -type SwigcptrX_unsigned uintptr - -func (p SwigcptrX_unsigned) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrX_unsigned) SwigIsX_unsigned() { -} - -var _wrap_new_X_unsigned__SWIG_0 unsafe.Pointer - -func _swig_wrap_new_X_unsigned__SWIG_0(base uint) (_ SwigcptrX_unsigned) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_X_unsigned__SWIG_0, _swig_p) - return -} - -func NewX_unsigned__SWIG_0(arg1 uint) (_swig_ret X_unsigned) { - return _swig_wrap_new_X_unsigned__SWIG_0(arg1) -} - -var _wrap_new_X_unsigned__SWIG_1 unsafe.Pointer - -func _swig_wrap_new_X_unsigned__SWIG_1() (base SwigcptrX_unsigned) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_X_unsigned__SWIG_1, _swig_p) - return -} - -func NewX_unsigned__SWIG_1() (_swig_ret X_unsigned) { - return _swig_wrap_new_X_unsigned__SWIG_1() -} - -var _wrap_new_X_unsigned__SWIG_2 unsafe.Pointer - -func _swig_wrap_new_X_unsigned__SWIG_2(base float64, _ uint) (_ SwigcptrX_unsigned) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_X_unsigned__SWIG_2, _swig_p) - return -} - -func NewX_unsigned__SWIG_2(arg1 float64, arg2 uint) (_swig_ret X_unsigned) { - return _swig_wrap_new_X_unsigned__SWIG_2(arg1, arg2) -} - -var _wrap_new_X_unsigned__SWIG_3 unsafe.Pointer - -func _swig_wrap_new_X_unsigned__SWIG_3(base float64) (_ SwigcptrX_unsigned) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_X_unsigned__SWIG_3, _swig_p) - return -} - -func NewX_unsigned__SWIG_3(arg1 float64) (_swig_ret X_unsigned) { - return _swig_wrap_new_X_unsigned__SWIG_3(arg1) -} - -func NewX_unsigned(a ...interface{}) X_unsigned { - argc := len(a) - if argc == 0 { - return NewX_unsigned__SWIG_1() - } - if argc == 1 { - if _, ok := a[0].(uint); !ok { - goto check_2 - } - return NewX_unsigned__SWIG_0(a[0].(uint)) - } -check_2: - if argc == 1 { - return NewX_unsigned__SWIG_3(a[0].(float64)) - } - if argc == 2 { - return NewX_unsigned__SWIG_2(a[0].(float64), a[1].(uint)) - } - panic("No match for overloaded function call") -} - -var _wrap_X_unsigned_meth__SWIG_0 unsafe.Pointer - -func _swig_wrap_X_unsigned_meth__SWIG_0(base SwigcptrX_unsigned, _ float64, _ uint) (_ uint) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_X_unsigned_meth__SWIG_0, _swig_p) - return -} - -func (arg1 SwigcptrX_unsigned) Meth__SWIG_0(arg2 float64, arg3 uint) (_swig_ret uint) { - return _swig_wrap_X_unsigned_meth__SWIG_0(arg1, arg2, arg3) -} - -var _wrap_X_unsigned_meth__SWIG_1 unsafe.Pointer - -func _swig_wrap_X_unsigned_meth__SWIG_1(base SwigcptrX_unsigned, _ float64) (_ uint) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_X_unsigned_meth__SWIG_1, _swig_p) - return -} - -func (arg1 SwigcptrX_unsigned) Meth__SWIG_1(arg2 float64) (_swig_ret uint) { - return _swig_wrap_X_unsigned_meth__SWIG_1(arg1, arg2) -} - -var _wrap_X_unsigned_meth__SWIG_2 unsafe.Pointer - -func _swig_wrap_X_unsigned_meth__SWIG_2(base SwigcptrX_unsigned, _ uint) (_ uint) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_X_unsigned_meth__SWIG_2, _swig_p) - return -} - -func (arg1 SwigcptrX_unsigned) Meth__SWIG_2(arg2 uint) (_swig_ret uint) { - return _swig_wrap_X_unsigned_meth__SWIG_2(arg1, arg2) -} - -var _wrap_X_unsigned_meth__SWIG_3 unsafe.Pointer - -func _swig_wrap_X_unsigned_meth__SWIG_3(base SwigcptrX_unsigned) (_ uint) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_X_unsigned_meth__SWIG_3, _swig_p) - return -} - -func (arg1 SwigcptrX_unsigned) Meth__SWIG_3() (_swig_ret uint) { - return _swig_wrap_X_unsigned_meth__SWIG_3(arg1) -} - -func (p SwigcptrX_unsigned) Meth(a ...interface{}) interface{} { - argc := len(a) - if argc == 0 { - return p.Meth__SWIG_3() - } - if argc == 1 { - if _, ok := a[0].(uint); !ok { - goto check_2 - } - return p.Meth__SWIG_2(a[0].(uint)) - } -check_2: - if argc == 1 { - return p.Meth__SWIG_1(a[0].(float64)) - } - if argc == 2 { - return p.Meth__SWIG_0(a[0].(float64), a[1].(uint)) - } - panic("No match for overloaded function call") -} - -var _wrap_delete_X_unsigned unsafe.Pointer - -func _swig_wrap_delete_X_unsigned(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_X_unsigned, _swig_p) - return -} - -func DeleteX_unsigned(arg1 X_unsigned) { - _swig_wrap_delete_X_unsigned(arg1.Swigcptr()) -} - -type X_unsigned interface { - Swigcptr() uintptr - SwigIsX_unsigned() - Meth(a ...interface{}) interface{} -} - -type SwigcptrY_unsigned uintptr - -func (p SwigcptrY_unsigned) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrY_unsigned) SwigIsY_unsigned() { -} - -var _wrap_Y_unsigned_meth_SWIG_0_0 unsafe.Pointer - -func _swig_wrap_Y_unsigned_meth_SWIG_0_0(base SwigcptrY_unsigned, _ float64, _ uint) (_ uint) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Y_unsigned_meth_SWIG_0_0, _swig_p) - return -} - -func (arg1 SwigcptrY_unsigned) Meth_SWIG_0_0(arg2 float64, arg3 uint) (_swig_ret uint) { - return _swig_wrap_Y_unsigned_meth_SWIG_0_0(arg1, arg2, arg3) -} - -var _wrap_Y_unsigned_meth_SWIG_0_1 unsafe.Pointer - -func _swig_wrap_Y_unsigned_meth_SWIG_0_1(base SwigcptrY_unsigned, _ float64) (_ uint) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Y_unsigned_meth_SWIG_0_1, _swig_p) - return -} - -func (arg1 SwigcptrY_unsigned) Meth_SWIG_0_1(arg2 float64) (_swig_ret uint) { - return _swig_wrap_Y_unsigned_meth_SWIG_0_1(arg1, arg2) -} - -var _wrap_Y_unsigned_meth_SWIG_0_2 unsafe.Pointer - -func _swig_wrap_Y_unsigned_meth_SWIG_0_2(base SwigcptrY_unsigned, _ uint) (_ uint) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Y_unsigned_meth_SWIG_0_2, _swig_p) - return -} - -func (arg1 SwigcptrY_unsigned) Meth_SWIG_0_2(arg2 uint) (_swig_ret uint) { - return _swig_wrap_Y_unsigned_meth_SWIG_0_2(arg1, arg2) -} - -var _wrap_Y_unsigned_meth_SWIG_0_3 unsafe.Pointer - -func _swig_wrap_Y_unsigned_meth_SWIG_0_3(base SwigcptrY_unsigned) (_ uint) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Y_unsigned_meth_SWIG_0_3, _swig_p) - return -} - -func (arg1 SwigcptrY_unsigned) Meth_SWIG_0_3() (_swig_ret uint) { - return _swig_wrap_Y_unsigned_meth_SWIG_0_3(arg1) -} - -func (p SwigcptrY_unsigned) Meth(a ...interface{}) interface{} { - argc := len(a) - if argc == 0 { - return p.Meth_SWIG_0_3() - } - if argc == 1 { - if _, ok := a[0].(uint); !ok { - goto check_2 - } - return p.Meth_SWIG_0_2(a[0].(uint)) - } -check_2: - if argc == 1 { - return p.Meth_SWIG_0_1(a[0].(float64)) - } - if argc == 2 { - return p.Meth_SWIG_0_0(a[0].(float64), a[1].(uint)) - } - panic("No match for overloaded function call") -} - -var _wrap_new_Y_unsigned unsafe.Pointer - -func _swig_wrap_new_Y_unsigned() (base SwigcptrY_unsigned) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Y_unsigned, _swig_p) - return -} - -func NewY_unsigned() (_swig_ret Y_unsigned) { - return _swig_wrap_new_Y_unsigned() -} - -var _wrap_delete_Y_unsigned unsafe.Pointer - -func _swig_wrap_delete_Y_unsigned(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Y_unsigned, _swig_p) - return -} - -func DeleteY_unsigned(arg1 Y_unsigned) { - _swig_wrap_delete_Y_unsigned(arg1.Swigcptr()) -} - -type Y_unsigned interface { - Swigcptr() uintptr - SwigIsY_unsigned() - Meth(a ...interface{}) interface{} -} - -type SwigcptrX_hello_unsigned uintptr - -func (p SwigcptrX_hello_unsigned) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrX_hello_unsigned) SwigIsX_hello_unsigned() { -} - -var _wrap_new_X_hello_unsigned__SWIG_0 unsafe.Pointer - -func _swig_wrap_new_X_hello_unsigned__SWIG_0(base uintptr) (_ SwigcptrX_hello_unsigned) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_X_hello_unsigned__SWIG_0, _swig_p) - return -} - -func NewX_hello_unsigned__SWIG_0(arg1 Hello_int) (_swig_ret X_hello_unsigned) { - return _swig_wrap_new_X_hello_unsigned__SWIG_0(arg1.Swigcptr()) -} - -var _wrap_new_X_hello_unsigned__SWIG_1 unsafe.Pointer - -func _swig_wrap_new_X_hello_unsigned__SWIG_1() (base SwigcptrX_hello_unsigned) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_X_hello_unsigned__SWIG_1, _swig_p) - return -} - -func NewX_hello_unsigned__SWIG_1() (_swig_ret X_hello_unsigned) { - return _swig_wrap_new_X_hello_unsigned__SWIG_1() -} - -var _wrap_new_X_hello_unsigned__SWIG_2 unsafe.Pointer - -func _swig_wrap_new_X_hello_unsigned__SWIG_2(base float64, _ uintptr) (_ SwigcptrX_hello_unsigned) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_X_hello_unsigned__SWIG_2, _swig_p) - return -} - -func NewX_hello_unsigned__SWIG_2(arg1 float64, arg2 Hello_int) (_swig_ret X_hello_unsigned) { - return _swig_wrap_new_X_hello_unsigned__SWIG_2(arg1, arg2.Swigcptr()) -} - -var _wrap_new_X_hello_unsigned__SWIG_3 unsafe.Pointer - -func _swig_wrap_new_X_hello_unsigned__SWIG_3(base float64) (_ SwigcptrX_hello_unsigned) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_X_hello_unsigned__SWIG_3, _swig_p) - return -} - -func NewX_hello_unsigned__SWIG_3(arg1 float64) (_swig_ret X_hello_unsigned) { - return _swig_wrap_new_X_hello_unsigned__SWIG_3(arg1) -} - -func NewX_hello_unsigned(a ...interface{}) X_hello_unsigned { - argc := len(a) - if argc == 0 { - return NewX_hello_unsigned__SWIG_1() - } - if argc == 1 { - if _, ok := a[0].(Hello_int); !ok { - goto check_2 - } - return NewX_hello_unsigned__SWIG_0(a[0].(Hello_int)) - } -check_2: - if argc == 1 { - return NewX_hello_unsigned__SWIG_3(a[0].(float64)) - } - if argc == 2 { - return NewX_hello_unsigned__SWIG_2(a[0].(float64), a[1].(Hello_int)) - } - panic("No match for overloaded function call") -} - -var _wrap_X_hello_unsigned_meth__SWIG_0 unsafe.Pointer - -func _swig_wrap_X_hello_unsigned_meth__SWIG_0(base SwigcptrX_hello_unsigned, _ float64, _ uintptr) (_ SwigcptrHello_int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_X_hello_unsigned_meth__SWIG_0, _swig_p) - return -} - -func (arg1 SwigcptrX_hello_unsigned) Meth__SWIG_0(arg2 float64, arg3 Hello_int) (_swig_ret Hello_int) { - return _swig_wrap_X_hello_unsigned_meth__SWIG_0(arg1, arg2, arg3.Swigcptr()) -} - -var _wrap_X_hello_unsigned_meth__SWIG_1 unsafe.Pointer - -func _swig_wrap_X_hello_unsigned_meth__SWIG_1(base SwigcptrX_hello_unsigned, _ float64) (_ SwigcptrHello_int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_X_hello_unsigned_meth__SWIG_1, _swig_p) - return -} - -func (arg1 SwigcptrX_hello_unsigned) Meth__SWIG_1(arg2 float64) (_swig_ret Hello_int) { - return _swig_wrap_X_hello_unsigned_meth__SWIG_1(arg1, arg2) -} - -var _wrap_X_hello_unsigned_meth__SWIG_2 unsafe.Pointer - -func _swig_wrap_X_hello_unsigned_meth__SWIG_2(base SwigcptrX_hello_unsigned, _ uintptr) (_ SwigcptrHello_int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_X_hello_unsigned_meth__SWIG_2, _swig_p) - return -} - -func (arg1 SwigcptrX_hello_unsigned) Meth__SWIG_2(arg2 Hello_int) (_swig_ret Hello_int) { - return _swig_wrap_X_hello_unsigned_meth__SWIG_2(arg1, arg2.Swigcptr()) -} - -var _wrap_X_hello_unsigned_meth__SWIG_3 unsafe.Pointer - -func _swig_wrap_X_hello_unsigned_meth__SWIG_3(base SwigcptrX_hello_unsigned) (_ SwigcptrHello_int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_X_hello_unsigned_meth__SWIG_3, _swig_p) - return -} - -func (arg1 SwigcptrX_hello_unsigned) Meth__SWIG_3() (_swig_ret Hello_int) { - return _swig_wrap_X_hello_unsigned_meth__SWIG_3(arg1) -} - -func (p SwigcptrX_hello_unsigned) Meth(a ...interface{}) interface{} { - argc := len(a) - if argc == 0 { - return p.Meth__SWIG_3() - } - if argc == 1 { - if _, ok := a[0].(Hello_int); !ok { - goto check_2 - } - return p.Meth__SWIG_2(a[0].(Hello_int)) - } -check_2: - if argc == 1 { - return p.Meth__SWIG_1(a[0].(float64)) - } - if argc == 2 { - return p.Meth__SWIG_0(a[0].(float64), a[1].(Hello_int)) - } - panic("No match for overloaded function call") -} - -var _wrap_delete_X_hello_unsigned unsafe.Pointer - -func _swig_wrap_delete_X_hello_unsigned(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_X_hello_unsigned, _swig_p) - return -} - -func DeleteX_hello_unsigned(arg1 X_hello_unsigned) { - _swig_wrap_delete_X_hello_unsigned(arg1.Swigcptr()) -} - -type X_hello_unsigned interface { - Swigcptr() uintptr - SwigIsX_hello_unsigned() - Meth(a ...interface{}) interface{} -} - -type SwigcptrY_hello_unsigned uintptr - -func (p SwigcptrY_hello_unsigned) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrY_hello_unsigned) SwigIsY_hello_unsigned() { -} - -var _wrap_Y_hello_unsigned_meth_SWIG_0_0 unsafe.Pointer - -func _swig_wrap_Y_hello_unsigned_meth_SWIG_0_0(base SwigcptrY_hello_unsigned, _ float64, _ uintptr) (_ SwigcptrHello_int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Y_hello_unsigned_meth_SWIG_0_0, _swig_p) - return -} - -func (arg1 SwigcptrY_hello_unsigned) Meth_SWIG_0_0(arg2 float64, arg3 Hello_int) (_swig_ret Hello_int) { - return _swig_wrap_Y_hello_unsigned_meth_SWIG_0_0(arg1, arg2, arg3.Swigcptr()) -} - -var _wrap_Y_hello_unsigned_meth_SWIG_0_1 unsafe.Pointer - -func _swig_wrap_Y_hello_unsigned_meth_SWIG_0_1(base SwigcptrY_hello_unsigned, _ float64) (_ SwigcptrHello_int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Y_hello_unsigned_meth_SWIG_0_1, _swig_p) - return -} - -func (arg1 SwigcptrY_hello_unsigned) Meth_SWIG_0_1(arg2 float64) (_swig_ret Hello_int) { - return _swig_wrap_Y_hello_unsigned_meth_SWIG_0_1(arg1, arg2) -} - -var _wrap_Y_hello_unsigned_meth_SWIG_0_2 unsafe.Pointer - -func _swig_wrap_Y_hello_unsigned_meth_SWIG_0_2(base SwigcptrY_hello_unsigned, _ uintptr) (_ SwigcptrHello_int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Y_hello_unsigned_meth_SWIG_0_2, _swig_p) - return -} - -func (arg1 SwigcptrY_hello_unsigned) Meth_SWIG_0_2(arg2 Hello_int) (_swig_ret Hello_int) { - return _swig_wrap_Y_hello_unsigned_meth_SWIG_0_2(arg1, arg2.Swigcptr()) -} - -var _wrap_Y_hello_unsigned_meth_SWIG_0_3 unsafe.Pointer - -func _swig_wrap_Y_hello_unsigned_meth_SWIG_0_3(base SwigcptrY_hello_unsigned) (_ SwigcptrHello_int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Y_hello_unsigned_meth_SWIG_0_3, _swig_p) - return -} - -func (arg1 SwigcptrY_hello_unsigned) Meth_SWIG_0_3() (_swig_ret Hello_int) { - return _swig_wrap_Y_hello_unsigned_meth_SWIG_0_3(arg1) -} - -func (p SwigcptrY_hello_unsigned) Meth(a ...interface{}) interface{} { - argc := len(a) - if argc == 0 { - return p.Meth_SWIG_0_3() - } - if argc == 1 { - if _, ok := a[0].(Hello_int); !ok { - goto check_2 - } - return p.Meth_SWIG_0_2(a[0].(Hello_int)) - } -check_2: - if argc == 1 { - return p.Meth_SWIG_0_1(a[0].(float64)) - } - if argc == 2 { - return p.Meth_SWIG_0_0(a[0].(float64), a[1].(Hello_int)) - } - panic("No match for overloaded function call") -} - -var _wrap_new_Y_hello_unsigned unsafe.Pointer - -func _swig_wrap_new_Y_hello_unsigned() (base SwigcptrY_hello_unsigned) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Y_hello_unsigned, _swig_p) - return -} - -func NewY_hello_unsigned() (_swig_ret Y_hello_unsigned) { - return _swig_wrap_new_Y_hello_unsigned() -} - -var _wrap_delete_Y_hello_unsigned unsafe.Pointer - -func _swig_wrap_delete_Y_hello_unsigned(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Y_hello_unsigned, _swig_p) - return -} - -func DeleteY_hello_unsigned(arg1 Y_hello_unsigned) { - _swig_wrap_delete_Y_hello_unsigned(arg1.Swigcptr()) -} - -type Y_hello_unsigned interface { - Swigcptr() uintptr - SwigIsY_hello_unsigned() - Meth(a ...interface{}) interface{} -} - -type SwigcptrX_Foo_Foo_int uintptr - -func (p SwigcptrX_Foo_Foo_int) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrX_Foo_Foo_int) SwigIsX_Foo_Foo_int() { -} - -var _wrap_new_X_Foo_Foo_int__SWIG_0 unsafe.Pointer - -func _swig_wrap_new_X_Foo_Foo_int__SWIG_0(base uintptr) (_ SwigcptrX_Foo_Foo_int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_X_Foo_Foo_int__SWIG_0, _swig_p) - return -} - -func NewX_Foo_Foo_int__SWIG_0(arg1 Foo_Sl_Foo_Sl_int_Sg__Sg_) (_swig_ret X_Foo_Foo_int) { - return _swig_wrap_new_X_Foo_Foo_int__SWIG_0(arg1.Swigcptr()) -} - -var _wrap_new_X_Foo_Foo_int__SWIG_1 unsafe.Pointer - -func _swig_wrap_new_X_Foo_Foo_int__SWIG_1() (base SwigcptrX_Foo_Foo_int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_X_Foo_Foo_int__SWIG_1, _swig_p) - return -} - -func NewX_Foo_Foo_int__SWIG_1() (_swig_ret X_Foo_Foo_int) { - return _swig_wrap_new_X_Foo_Foo_int__SWIG_1() -} - -var _wrap_new_X_Foo_Foo_int__SWIG_2 unsafe.Pointer - -func _swig_wrap_new_X_Foo_Foo_int__SWIG_2(base float64, _ uintptr) (_ SwigcptrX_Foo_Foo_int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_X_Foo_Foo_int__SWIG_2, _swig_p) - return -} - -func NewX_Foo_Foo_int__SWIG_2(arg1 float64, arg2 Foo_Sl_Foo_Sl_int_Sg__Sg_) (_swig_ret X_Foo_Foo_int) { - return _swig_wrap_new_X_Foo_Foo_int__SWIG_2(arg1, arg2.Swigcptr()) -} - -var _wrap_new_X_Foo_Foo_int__SWIG_3 unsafe.Pointer - -func _swig_wrap_new_X_Foo_Foo_int__SWIG_3(base float64) (_ SwigcptrX_Foo_Foo_int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_X_Foo_Foo_int__SWIG_3, _swig_p) - return -} - -func NewX_Foo_Foo_int__SWIG_3(arg1 float64) (_swig_ret X_Foo_Foo_int) { - return _swig_wrap_new_X_Foo_Foo_int__SWIG_3(arg1) -} - -func NewX_Foo_Foo_int(a ...interface{}) X_Foo_Foo_int { - argc := len(a) - if argc == 0 { - return NewX_Foo_Foo_int__SWIG_1() - } - if argc == 1 { - if _, ok := a[0].(Foo_Sl_Foo_Sl_int_Sg__Sg_); !ok { - goto check_2 - } - return NewX_Foo_Foo_int__SWIG_0(a[0].(Foo_Sl_Foo_Sl_int_Sg__Sg_)) - } -check_2: - if argc == 1 { - return NewX_Foo_Foo_int__SWIG_3(a[0].(float64)) - } - if argc == 2 { - return NewX_Foo_Foo_int__SWIG_2(a[0].(float64), a[1].(Foo_Sl_Foo_Sl_int_Sg__Sg_)) - } - panic("No match for overloaded function call") -} - -var _wrap_X_Foo_Foo_int_meth__SWIG_0 unsafe.Pointer - -func _swig_wrap_X_Foo_Foo_int_meth__SWIG_0(base SwigcptrX_Foo_Foo_int, _ float64, _ uintptr) (_ SwigcptrFoo_Sl_Foo_Sl_int_Sg__Sg_) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_X_Foo_Foo_int_meth__SWIG_0, _swig_p) - return -} - -func (arg1 SwigcptrX_Foo_Foo_int) Meth__SWIG_0(arg2 float64, arg3 Foo_Sl_Foo_Sl_int_Sg__Sg_) (_swig_ret Foo_Sl_Foo_Sl_int_Sg__Sg_) { - return _swig_wrap_X_Foo_Foo_int_meth__SWIG_0(arg1, arg2, arg3.Swigcptr()) -} - -var _wrap_X_Foo_Foo_int_meth__SWIG_1 unsafe.Pointer - -func _swig_wrap_X_Foo_Foo_int_meth__SWIG_1(base SwigcptrX_Foo_Foo_int, _ float64) (_ SwigcptrFoo_Sl_Foo_Sl_int_Sg__Sg_) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_X_Foo_Foo_int_meth__SWIG_1, _swig_p) - return -} - -func (arg1 SwigcptrX_Foo_Foo_int) Meth__SWIG_1(arg2 float64) (_swig_ret Foo_Sl_Foo_Sl_int_Sg__Sg_) { - return _swig_wrap_X_Foo_Foo_int_meth__SWIG_1(arg1, arg2) -} - -var _wrap_X_Foo_Foo_int_meth__SWIG_2 unsafe.Pointer - -func _swig_wrap_X_Foo_Foo_int_meth__SWIG_2(base SwigcptrX_Foo_Foo_int, _ uintptr) (_ SwigcptrFoo_Sl_Foo_Sl_int_Sg__Sg_) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_X_Foo_Foo_int_meth__SWIG_2, _swig_p) - return -} - -func (arg1 SwigcptrX_Foo_Foo_int) Meth__SWIG_2(arg2 Foo_Sl_Foo_Sl_int_Sg__Sg_) (_swig_ret Foo_Sl_Foo_Sl_int_Sg__Sg_) { - return _swig_wrap_X_Foo_Foo_int_meth__SWIG_2(arg1, arg2.Swigcptr()) -} - -var _wrap_X_Foo_Foo_int_meth__SWIG_3 unsafe.Pointer - -func _swig_wrap_X_Foo_Foo_int_meth__SWIG_3(base SwigcptrX_Foo_Foo_int) (_ SwigcptrFoo_Sl_Foo_Sl_int_Sg__Sg_) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_X_Foo_Foo_int_meth__SWIG_3, _swig_p) - return -} - -func (arg1 SwigcptrX_Foo_Foo_int) Meth__SWIG_3() (_swig_ret Foo_Sl_Foo_Sl_int_Sg__Sg_) { - return _swig_wrap_X_Foo_Foo_int_meth__SWIG_3(arg1) -} - -func (p SwigcptrX_Foo_Foo_int) Meth(a ...interface{}) interface{} { - argc := len(a) - if argc == 0 { - return p.Meth__SWIG_3() - } - if argc == 1 { - if _, ok := a[0].(Foo_Sl_Foo_Sl_int_Sg__Sg_); !ok { - goto check_2 - } - return p.Meth__SWIG_2(a[0].(Foo_Sl_Foo_Sl_int_Sg__Sg_)) - } -check_2: - if argc == 1 { - return p.Meth__SWIG_1(a[0].(float64)) - } - if argc == 2 { - return p.Meth__SWIG_0(a[0].(float64), a[1].(Foo_Sl_Foo_Sl_int_Sg__Sg_)) - } - panic("No match for overloaded function call") -} - -var _wrap_delete_X_Foo_Foo_int unsafe.Pointer - -func _swig_wrap_delete_X_Foo_Foo_int(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_X_Foo_Foo_int, _swig_p) - return -} - -func DeleteX_Foo_Foo_int(arg1 X_Foo_Foo_int) { - _swig_wrap_delete_X_Foo_Foo_int(arg1.Swigcptr()) -} - -type X_Foo_Foo_int interface { - Swigcptr() uintptr - SwigIsX_Foo_Foo_int() - Meth(a ...interface{}) interface{} -} - -type SwigcptrZ_8 uintptr - -func (p SwigcptrZ_8) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrZ_8) SwigIsZ_8() { -} - -var _wrap_new_Z_8__SWIG_0 unsafe.Pointer - -func _swig_wrap_new_Z_8__SWIG_0(base int) (_ SwigcptrZ_8) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Z_8__SWIG_0, _swig_p) - return -} - -func NewZ_8__SWIG_0(arg1 int) (_swig_ret Z_8) { - return _swig_wrap_new_Z_8__SWIG_0(arg1) -} - -var _wrap_new_Z_8__SWIG_1 unsafe.Pointer - -func _swig_wrap_new_Z_8__SWIG_1() (base SwigcptrZ_8) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Z_8__SWIG_1, _swig_p) - return -} - -func NewZ_8__SWIG_1() (_swig_ret Z_8) { - return _swig_wrap_new_Z_8__SWIG_1() -} - -var _wrap_new_Z_8__SWIG_2 unsafe.Pointer - -func _swig_wrap_new_Z_8__SWIG_2(base float64, _ int) (_ SwigcptrZ_8) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Z_8__SWIG_2, _swig_p) - return -} - -func NewZ_8__SWIG_2(arg1 float64, arg2 int) (_swig_ret Z_8) { - return _swig_wrap_new_Z_8__SWIG_2(arg1, arg2) -} - -var _wrap_new_Z_8__SWIG_3 unsafe.Pointer - -func _swig_wrap_new_Z_8__SWIG_3(base float64) (_ SwigcptrZ_8) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Z_8__SWIG_3, _swig_p) - return -} - -func NewZ_8__SWIG_3(arg1 float64) (_swig_ret Z_8) { - return _swig_wrap_new_Z_8__SWIG_3(arg1) -} - -func NewZ_8(a ...interface{}) Z_8 { - argc := len(a) - if argc == 0 { - return NewZ_8__SWIG_1() - } - if argc == 1 { - if _, ok := a[0].(int); !ok { - goto check_2 - } - return NewZ_8__SWIG_0(a[0].(int)) - } -check_2: - if argc == 1 { - return NewZ_8__SWIG_3(a[0].(float64)) - } - if argc == 2 { - return NewZ_8__SWIG_2(a[0].(float64), a[1].(int)) - } - panic("No match for overloaded function call") -} - -var _wrap_delete_Z_8 unsafe.Pointer - -func _swig_wrap_delete_Z_8(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Z_8, _swig_p) - return -} - -func DeleteZ_8(arg1 Z_8) { - _swig_wrap_delete_Z_8(arg1.Swigcptr()) -} - -type Z_8 interface { - Swigcptr() uintptr - SwigIsZ_8() -} - -type SwigcptrFoo_Z_8 uintptr - -func (p SwigcptrFoo_Z_8) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrFoo_Z_8) SwigIsFoo_Z_8() { -} - -var _wrap_new_Foo_Z_8__SWIG_0 unsafe.Pointer - -func _swig_wrap_new_Foo_Z_8__SWIG_0(base uint) (_ SwigcptrFoo_Z_8) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Foo_Z_8__SWIG_0, _swig_p) - return -} - -func NewFoo_Z_8__SWIG_0(arg1 uint) (_swig_ret Foo_Z_8) { - return _swig_wrap_new_Foo_Z_8__SWIG_0(arg1) -} - -var _wrap_new_Foo_Z_8__SWIG_1 unsafe.Pointer - -func _swig_wrap_new_Foo_Z_8__SWIG_1() (base SwigcptrFoo_Z_8) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Foo_Z_8__SWIG_1, _swig_p) - return -} - -func NewFoo_Z_8__SWIG_1() (_swig_ret Foo_Z_8) { - return _swig_wrap_new_Foo_Z_8__SWIG_1() -} - -func NewFoo_Z_8(a ...interface{}) Foo_Z_8 { - argc := len(a) - if argc == 0 { - return NewFoo_Z_8__SWIG_1() - } - if argc == 1 { - return NewFoo_Z_8__SWIG_0(a[0].(uint)) - } - panic("No match for overloaded function call") -} - -var _wrap_delete_Foo_Z_8 unsafe.Pointer - -func _swig_wrap_delete_Foo_Z_8(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Foo_Z_8, _swig_p) - return -} - -func DeleteFoo_Z_8(arg1 Foo_Z_8) { - _swig_wrap_delete_Foo_Z_8(arg1.Swigcptr()) -} - -type Foo_Z_8 interface { - Swigcptr() uintptr - SwigIsFoo_Z_8() -} - -type SwigcptrX_Foo_Z_8 uintptr - -func (p SwigcptrX_Foo_Z_8) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrX_Foo_Z_8) SwigIsX_Foo_Z_8() { -} - -var _wrap_new_X_Foo_Z_8__SWIG_0 unsafe.Pointer - -func _swig_wrap_new_X_Foo_Z_8__SWIG_0(base uintptr) (_ SwigcptrX_Foo_Z_8) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_X_Foo_Z_8__SWIG_0, _swig_p) - return -} - -func NewX_Foo_Z_8__SWIG_0(arg1 Foo_Z_8) (_swig_ret X_Foo_Z_8) { - return _swig_wrap_new_X_Foo_Z_8__SWIG_0(arg1.Swigcptr()) -} - -var _wrap_new_X_Foo_Z_8__SWIG_1 unsafe.Pointer - -func _swig_wrap_new_X_Foo_Z_8__SWIG_1() (base SwigcptrX_Foo_Z_8) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_X_Foo_Z_8__SWIG_1, _swig_p) - return -} - -func NewX_Foo_Z_8__SWIG_1() (_swig_ret X_Foo_Z_8) { - return _swig_wrap_new_X_Foo_Z_8__SWIG_1() -} - -var _wrap_new_X_Foo_Z_8__SWIG_2 unsafe.Pointer - -func _swig_wrap_new_X_Foo_Z_8__SWIG_2(base float64, _ uintptr) (_ SwigcptrX_Foo_Z_8) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_X_Foo_Z_8__SWIG_2, _swig_p) - return -} - -func NewX_Foo_Z_8__SWIG_2(arg1 float64, arg2 Foo_Z_8) (_swig_ret X_Foo_Z_8) { - return _swig_wrap_new_X_Foo_Z_8__SWIG_2(arg1, arg2.Swigcptr()) -} - -var _wrap_new_X_Foo_Z_8__SWIG_3 unsafe.Pointer - -func _swig_wrap_new_X_Foo_Z_8__SWIG_3(base float64) (_ SwigcptrX_Foo_Z_8) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_X_Foo_Z_8__SWIG_3, _swig_p) - return -} - -func NewX_Foo_Z_8__SWIG_3(arg1 float64) (_swig_ret X_Foo_Z_8) { - return _swig_wrap_new_X_Foo_Z_8__SWIG_3(arg1) -} - -func NewX_Foo_Z_8(a ...interface{}) X_Foo_Z_8 { - argc := len(a) - if argc == 0 { - return NewX_Foo_Z_8__SWIG_1() - } - if argc == 1 { - if _, ok := a[0].(Foo_Z_8); !ok { - goto check_2 - } - return NewX_Foo_Z_8__SWIG_0(a[0].(Foo_Z_8)) - } -check_2: - if argc == 1 { - return NewX_Foo_Z_8__SWIG_3(a[0].(float64)) - } - if argc == 2 { - return NewX_Foo_Z_8__SWIG_2(a[0].(float64), a[1].(Foo_Z_8)) - } - panic("No match for overloaded function call") -} - -var _wrap_X_Foo_Z_8_meth__SWIG_0 unsafe.Pointer - -func _swig_wrap_X_Foo_Z_8_meth__SWIG_0(base SwigcptrX_Foo_Z_8, _ float64, _ uintptr) (_ SwigcptrFoo_Z_8) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_X_Foo_Z_8_meth__SWIG_0, _swig_p) - return -} - -func (arg1 SwigcptrX_Foo_Z_8) Meth__SWIG_0(arg2 float64, arg3 Foo_Z_8) (_swig_ret Foo_Z_8) { - return _swig_wrap_X_Foo_Z_8_meth__SWIG_0(arg1, arg2, arg3.Swigcptr()) -} - -var _wrap_X_Foo_Z_8_meth__SWIG_1 unsafe.Pointer - -func _swig_wrap_X_Foo_Z_8_meth__SWIG_1(base SwigcptrX_Foo_Z_8, _ float64) (_ SwigcptrFoo_Z_8) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_X_Foo_Z_8_meth__SWIG_1, _swig_p) - return -} - -func (arg1 SwigcptrX_Foo_Z_8) Meth__SWIG_1(arg2 float64) (_swig_ret Foo_Z_8) { - return _swig_wrap_X_Foo_Z_8_meth__SWIG_1(arg1, arg2) -} - -var _wrap_X_Foo_Z_8_meth__SWIG_2 unsafe.Pointer - -func _swig_wrap_X_Foo_Z_8_meth__SWIG_2(base SwigcptrX_Foo_Z_8, _ uintptr) (_ SwigcptrFoo_Z_8) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_X_Foo_Z_8_meth__SWIG_2, _swig_p) - return -} - -func (arg1 SwigcptrX_Foo_Z_8) Meth__SWIG_2(arg2 Foo_Z_8) (_swig_ret Foo_Z_8) { - return _swig_wrap_X_Foo_Z_8_meth__SWIG_2(arg1, arg2.Swigcptr()) -} - -var _wrap_X_Foo_Z_8_meth__SWIG_3 unsafe.Pointer - -func _swig_wrap_X_Foo_Z_8_meth__SWIG_3(base SwigcptrX_Foo_Z_8) (_ SwigcptrFoo_Z_8) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_X_Foo_Z_8_meth__SWIG_3, _swig_p) - return -} - -func (arg1 SwigcptrX_Foo_Z_8) Meth__SWIG_3() (_swig_ret Foo_Z_8) { - return _swig_wrap_X_Foo_Z_8_meth__SWIG_3(arg1) -} - -func (p SwigcptrX_Foo_Z_8) Meth(a ...interface{}) interface{} { - argc := len(a) - if argc == 0 { - return p.Meth__SWIG_3() - } - if argc == 1 { - if _, ok := a[0].(Foo_Z_8); !ok { - goto check_2 - } - return p.Meth__SWIG_2(a[0].(Foo_Z_8)) - } -check_2: - if argc == 1 { - return p.Meth__SWIG_1(a[0].(float64)) - } - if argc == 2 { - return p.Meth__SWIG_0(a[0].(float64), a[1].(Foo_Z_8)) - } - panic("No match for overloaded function call") -} - -var _wrap_delete_X_Foo_Z_8 unsafe.Pointer - -func _swig_wrap_delete_X_Foo_Z_8(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_X_Foo_Z_8, _swig_p) - return -} - -func DeleteX_Foo_Z_8(arg1 X_Foo_Z_8) { - _swig_wrap_delete_X_Foo_Z_8(arg1.Swigcptr()) -} - -type X_Foo_Z_8 interface { - Swigcptr() uintptr - SwigIsX_Foo_Z_8() - Meth(a ...interface{}) interface{} -} - -type SwigcptrBar uintptr - -func (p SwigcptrBar) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrBar) SwigIsBar() { -} - -var _wrap_new_Bar unsafe.Pointer - -func _swig_wrap_new_Bar(base uint) (_ SwigcptrBar) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Bar, _swig_p) - return -} - -func NewBar(arg1 uint) (_swig_ret Bar) { - return _swig_wrap_new_Bar(arg1) -} - -var _wrap_delete_Bar unsafe.Pointer - -func _swig_wrap_delete_Bar(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Bar, _swig_p) - return -} - -func DeleteBar(arg1 Bar) { - _swig_wrap_delete_Bar(arg1.Swigcptr()) -} - -var _wrap_Bar_foo__SWIG_0 unsafe.Pointer - -func _swig_wrap_Bar_foo__SWIG_0(base SwigcptrBar, _ Hello_Sl_int_Sg_Hi) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Bar_foo__SWIG_0, _swig_p) - return -} - -func (_swig_base SwigcptrBar) Foo__SWIG_0(arg1 Hello_Sl_int_Sg_Hi) { - _swig_wrap_Bar_foo__SWIG_0(_swig_base, arg1) -} - -var _wrap_Bar_foo__SWIG_1 unsafe.Pointer - -func _swig_wrap_Bar_foo__SWIG_1(base SwigcptrBar) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Bar_foo__SWIG_1, _swig_p) - return -} - -func (_swig_base SwigcptrBar) Foo__SWIG_1() { - _swig_wrap_Bar_foo__SWIG_1(_swig_base) -} - -func (p SwigcptrBar) Foo(a ...interface{}) { - argc := len(a) - if argc == 0 { - p.Foo__SWIG_1() - return - } - if argc == 1 { - p.Foo__SWIG_0(a[0].(Hello_Sl_int_Sg_Hi)) - return - } - panic("No match for overloaded function call") -} - -func (p SwigcptrBar) SwigIsHello_int() { -} - -func (p SwigcptrBar) SwigGetHello_int() Hello_int { - return SwigcptrHello_int(p.Swigcptr()) -} - -type Bar interface { - Swigcptr() uintptr - SwigIsBar() - Foo(a ...interface{}) - SwigIsHello_int() - SwigGetHello_int() Hello_int -} - -var _wrap_ott__SWIG_6 unsafe.Pointer - -func _swig_wrap_ott__SWIG_6(base uintptr) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_ott__SWIG_6, _swig_p) - return -} - -func Ott__SWIG_6(arg1 Foo_int) (_swig_ret int) { - return _swig_wrap_ott__SWIG_6(arg1.Swigcptr()) -} - -var _wrap_ott__SWIG_10 unsafe.Pointer - -func Ott__SWIG_10(arg1 int, arg2 int) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_ott__SWIG_10, _swig_p) - return -} -var _wrap_ott__SWIG_11 unsafe.Pointer - -func Ott__SWIG_11(arg1 int) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_ott__SWIG_11, _swig_p) - return -} -var _wrap_ott__SWIG_12 unsafe.Pointer - -func Ott__SWIG_12() (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_ott__SWIG_12, _swig_p) - return -} -var _wrap_ott__SWIG_13 unsafe.Pointer - -func Ott__SWIG_13(arg1 string, arg2 int, arg3 int) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_ott__SWIG_13, _swig_p) - return -} -var _wrap_ott__SWIG_14 unsafe.Pointer - -func Ott__SWIG_14(arg1 string, arg2 int) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_ott__SWIG_14, _swig_p) - return -} -var _wrap_ott__SWIG_15 unsafe.Pointer - -func Ott__SWIG_15(arg1 string) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_ott__SWIG_15, _swig_p) - return -} -var _wrap_ott__SWIG_16 unsafe.Pointer - -func _swig_wrap_ott__SWIG_16(base uintptr, _ float64) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_ott__SWIG_16, _swig_p) - return -} - -func Ott__SWIG_16(arg1 Hello_int, arg2 float64) (_swig_ret int) { - return _swig_wrap_ott__SWIG_16(arg1.Swigcptr(), arg2) -} - -var _wrap_ott__SWIG_17 unsafe.Pointer - -func _swig_wrap_ott__SWIG_17(base uintptr) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_ott__SWIG_17, _swig_p) - return -} - -func Ott__SWIG_17(arg1 Hello_int) (_swig_ret int) { - return _swig_wrap_ott__SWIG_17(arg1.Swigcptr()) -} - -func Ott(a ...interface{}) int { - argc := len(a) - if argc == 0 { - return Ott__SWIG_12() - } - if argc == 1 { - if _, ok := a[0].(Foo_int); !ok { - goto check_2 - } - return Ott__SWIG_6(a[0].(Foo_int)) - } -check_2: - if argc == 1 { - if _, ok := a[0].(Hello_int); !ok { - goto check_3 - } - return Ott__SWIG_17(a[0].(Hello_int)) - } -check_3: - if argc == 1 { - if _, ok := a[0].(int); !ok { - goto check_4 - } - return Ott__SWIG_11(a[0].(int)) - } -check_4: - if argc == 1 { - return Ott__SWIG_15(a[0].(string)) - } - if argc == 2 { - if _, ok := a[0].(Hello_int); !ok { - goto check_6 - } - if _, ok := a[1].(float64); !ok { - goto check_6 - } - return Ott__SWIG_16(a[0].(Hello_int), a[1].(float64)) - } -check_6: - if argc == 2 { - if _, ok := a[0].(int); !ok { - goto check_7 - } - return Ott__SWIG_10(a[0].(int), a[1].(int)) - } -check_7: - if argc == 2 { - return Ott__SWIG_14(a[0].(string), a[1].(int)) - } - if argc == 3 { - return Ott__SWIG_13(a[0].(string), a[1].(int), a[2].(int)) - } - panic("No match for overloaded function call") -} - -var _wrap_ottint__SWIG_0 unsafe.Pointer - -func _swig_wrap_ottint__SWIG_0(base uintptr, _ int) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_ottint__SWIG_0, _swig_p) - return -} - -func Ottint__SWIG_0(arg1 Hello_int, arg2 int) (_swig_ret int) { - return _swig_wrap_ottint__SWIG_0(arg1.Swigcptr(), arg2) -} - -var _wrap_ottint__SWIG_1 unsafe.Pointer - -func _swig_wrap_ottint__SWIG_1(base uintptr) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_ottint__SWIG_1, _swig_p) - return -} - -func Ottint__SWIG_1(arg1 Hello_int) (_swig_ret int) { - return _swig_wrap_ottint__SWIG_1(arg1.Swigcptr()) -} - -func Ottint(a ...interface{}) int { - argc := len(a) - if argc == 1 { - return Ottint__SWIG_1(a[0].(Hello_int)) - } - if argc == 2 { - return Ottint__SWIG_0(a[0].(Hello_int), a[1].(int)) - } - panic("No match for overloaded function call") -} - -var _wrap_ottstring__SWIG_0 unsafe.Pointer - -func _swig_wrap_ottstring__SWIG_0(base uintptr, _ string) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_ottstring__SWIG_0, _swig_p) - return -} - -func Ottstring__SWIG_0(arg1 Hello_int, arg2 string) (_swig_ret int) { - return _swig_wrap_ottstring__SWIG_0(arg1.Swigcptr(), arg2) -} - -var _wrap_ottstring__SWIG_1 unsafe.Pointer - -func _swig_wrap_ottstring__SWIG_1(base uintptr) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_ottstring__SWIG_1, _swig_p) - return -} - -func Ottstring__SWIG_1(arg1 Hello_int) (_swig_ret int) { - return _swig_wrap_ottstring__SWIG_1(arg1.Swigcptr()) -} - -func Ottstring(a ...interface{}) int { - argc := len(a) - if argc == 1 { - return Ottstring__SWIG_1(a[0].(Hello_int)) - } - if argc == 2 { - return Ottstring__SWIG_0(a[0].(Hello_int), a[1].(string)) - } - panic("No match for overloaded function call") -} - -var _wrap_nsott__SWIG_6 unsafe.Pointer - -func _swig_wrap_nsott__SWIG_6(base uintptr) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_nsott__SWIG_6, _swig_p) - return -} - -func Nsott__SWIG_6(arg1 Foo_int) (_swig_ret int) { - return _swig_wrap_nsott__SWIG_6(arg1.Swigcptr()) -} - -var _wrap_nsott__SWIG_10 unsafe.Pointer - -func Nsott__SWIG_10(arg1 int, arg2 int) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_nsott__SWIG_10, _swig_p) - return -} -var _wrap_nsott__SWIG_11 unsafe.Pointer - -func Nsott__SWIG_11(arg1 int) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_nsott__SWIG_11, _swig_p) - return -} -var _wrap_nsott__SWIG_12 unsafe.Pointer - -func Nsott__SWIG_12() (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_nsott__SWIG_12, _swig_p) - return -} -var _wrap_nsott__SWIG_13 unsafe.Pointer - -func Nsott__SWIG_13(arg1 string, arg2 int, arg3 int) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_nsott__SWIG_13, _swig_p) - return -} -var _wrap_nsott__SWIG_14 unsafe.Pointer - -func Nsott__SWIG_14(arg1 string, arg2 int) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_nsott__SWIG_14, _swig_p) - return -} -var _wrap_nsott__SWIG_15 unsafe.Pointer - -func Nsott__SWIG_15(arg1 string) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_nsott__SWIG_15, _swig_p) - return -} -var _wrap_nsott__SWIG_16 unsafe.Pointer - -func _swig_wrap_nsott__SWIG_16(base uintptr, _ float64) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_nsott__SWIG_16, _swig_p) - return -} - -func Nsott__SWIG_16(arg1 Hello_int, arg2 float64) (_swig_ret int) { - return _swig_wrap_nsott__SWIG_16(arg1.Swigcptr(), arg2) -} - -var _wrap_nsott__SWIG_17 unsafe.Pointer - -func _swig_wrap_nsott__SWIG_17(base uintptr) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_nsott__SWIG_17, _swig_p) - return -} - -func Nsott__SWIG_17(arg1 Hello_int) (_swig_ret int) { - return _swig_wrap_nsott__SWIG_17(arg1.Swigcptr()) -} - -func Nsott(a ...interface{}) int { - argc := len(a) - if argc == 0 { - return Nsott__SWIG_12() - } - if argc == 1 { - if _, ok := a[0].(Foo_int); !ok { - goto check_2 - } - return Nsott__SWIG_6(a[0].(Foo_int)) - } -check_2: - if argc == 1 { - if _, ok := a[0].(Hello_int); !ok { - goto check_3 - } - return Nsott__SWIG_17(a[0].(Hello_int)) - } -check_3: - if argc == 1 { - if _, ok := a[0].(int); !ok { - goto check_4 - } - return Nsott__SWIG_11(a[0].(int)) - } -check_4: - if argc == 1 { - return Nsott__SWIG_15(a[0].(string)) - } - if argc == 2 { - if _, ok := a[0].(Hello_int); !ok { - goto check_6 - } - if _, ok := a[1].(float64); !ok { - goto check_6 - } - return Nsott__SWIG_16(a[0].(Hello_int), a[1].(float64)) - } -check_6: - if argc == 2 { - if _, ok := a[0].(int); !ok { - goto check_7 - } - return Nsott__SWIG_10(a[0].(int), a[1].(int)) - } -check_7: - if argc == 2 { - return Nsott__SWIG_14(a[0].(string), a[1].(int)) - } - if argc == 3 { - return Nsott__SWIG_13(a[0].(string), a[1].(int), a[2].(int)) - } - panic("No match for overloaded function call") -} - -var _wrap_nsottint__SWIG_0 unsafe.Pointer - -func _swig_wrap_nsottint__SWIG_0(base uintptr, _ int) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_nsottint__SWIG_0, _swig_p) - return -} - -func Nsottint__SWIG_0(arg1 Hello_int, arg2 int) (_swig_ret int) { - return _swig_wrap_nsottint__SWIG_0(arg1.Swigcptr(), arg2) -} - -var _wrap_nsottint__SWIG_1 unsafe.Pointer - -func _swig_wrap_nsottint__SWIG_1(base uintptr) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_nsottint__SWIG_1, _swig_p) - return -} - -func Nsottint__SWIG_1(arg1 Hello_int) (_swig_ret int) { - return _swig_wrap_nsottint__SWIG_1(arg1.Swigcptr()) -} - -func Nsottint(a ...interface{}) int { - argc := len(a) - if argc == 1 { - return Nsottint__SWIG_1(a[0].(Hello_int)) - } - if argc == 2 { - return Nsottint__SWIG_0(a[0].(Hello_int), a[1].(int)) - } - panic("No match for overloaded function call") -} - -var _wrap_nsottstring__SWIG_0 unsafe.Pointer - -func _swig_wrap_nsottstring__SWIG_0(base uintptr, _ string) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_nsottstring__SWIG_0, _swig_p) - return -} - -func Nsottstring__SWIG_0(arg1 Hello_int, arg2 string) (_swig_ret int) { - return _swig_wrap_nsottstring__SWIG_0(arg1.Swigcptr(), arg2) -} - -var _wrap_nsottstring__SWIG_1 unsafe.Pointer - -func _swig_wrap_nsottstring__SWIG_1(base uintptr) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_nsottstring__SWIG_1, _swig_p) - return -} - -func Nsottstring__SWIG_1(arg1 Hello_int) (_swig_ret int) { - return _swig_wrap_nsottstring__SWIG_1(arg1.Swigcptr()) -} - -func Nsottstring(a ...interface{}) int { - argc := len(a) - if argc == 1 { - return Nsottstring__SWIG_1(a[0].(Hello_int)) - } - if argc == 2 { - return Nsottstring__SWIG_0(a[0].(Hello_int), a[1].(string)) - } - panic("No match for overloaded function call") -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - -type SwigcptrFoo_Sl_Foo_Sl_int_Sg__Sg_ uintptr -type Foo_Sl_Foo_Sl_int_Sg__Sg_ interface { - Swigcptr() uintptr; -} -func (p SwigcptrFoo_Sl_Foo_Sl_int_Sg__Sg_) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/template_default_arg_runme b/Examples/test-suite/go/template_default_arg_runme deleted file mode 100755 index 475840cbb..000000000 Binary files a/Examples/test-suite/go/template_default_arg_runme and /dev/null differ diff --git a/Examples/test-suite/go/template_default_arg_virtual_destructor.go b/Examples/test-suite/go/template_default_arg_virtual_destructor.go deleted file mode 100644 index a63d7719d..000000000 --- a/Examples/test-suite/go/template_default_arg_virtual_destructor.go +++ /dev/null @@ -1,151 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../template_default_arg_virtual_destructor.i - -package template_default_arg_virtual_destructor - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrA uintptr - -func (p SwigcptrA) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrA) SwigIsA() { -} - -var _wrap_new_A unsafe.Pointer - -func _swig_wrap_new_A() (base SwigcptrA) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_A, _swig_p) - return -} - -func NewA() (_swig_ret A) { - return _swig_wrap_new_A() -} - -var _wrap_delete_A unsafe.Pointer - -func _swig_wrap_delete_A(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_A, _swig_p) - return -} - -func DeleteA(arg1 A) { - _swig_wrap_delete_A(arg1.Swigcptr()) -} - -type A interface { - Swigcptr() uintptr - SwigIsA() -} - -type SwigcptrB_AF uintptr - -func (p SwigcptrB_AF) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrB_AF) SwigIsB_AF() { -} - -var _wrap_new_B_AF unsafe.Pointer - -func _swig_wrap_new_B_AF(base float32) (_ SwigcptrB_AF) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_B_AF, _swig_p) - return -} - -func NewB_AF(arg1 float32) (_swig_ret B_AF) { - return _swig_wrap_new_B_AF(arg1) -} - -var _wrap_delete_B_AF unsafe.Pointer - -func _swig_wrap_delete_B_AF(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_B_AF, _swig_p) - return -} - -func DeleteB_AF(arg1 B_AF) { - _swig_wrap_delete_B_AF(arg1.Swigcptr()) -} - -type B_AF interface { - Swigcptr() uintptr - SwigIsB_AF() -} - -type SwigcptrB_A uintptr - -func (p SwigcptrB_A) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrB_A) SwigIsB_A() { -} - -var _wrap_new_B_A unsafe.Pointer - -func _swig_wrap_new_B_A(base int, _ int) (_ SwigcptrB_A) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_B_A, _swig_p) - return -} - -func NewB_A(arg1 int, arg2 int) (_swig_ret B_A) { - return _swig_wrap_new_B_A(arg1, arg2) -} - -var _wrap_delete_B_A unsafe.Pointer - -func _swig_wrap_delete_B_A(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_B_A, _swig_p) - return -} - -func DeleteB_A(arg1 B_A) { - _swig_wrap_delete_B_A(arg1.Swigcptr()) -} - -type B_A interface { - Swigcptr() uintptr - SwigIsB_A() -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/template_default_class_parms.go b/Examples/test-suite/go/template_default_class_parms.go deleted file mode 100644 index 5b073bcad..000000000 --- a/Examples/test-suite/go/template_default_class_parms.go +++ /dev/null @@ -1,525 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../template_default_class_parms.i - -package template_default_class_parms - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrSomeType uintptr - -func (p SwigcptrSomeType) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrSomeType) SwigIsSomeType() { -} - -var _wrap_new_SomeType unsafe.Pointer - -func _swig_wrap_new_SomeType() (base SwigcptrSomeType) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_SomeType, _swig_p) - return -} - -func NewSomeType() (_swig_ret SomeType) { - return _swig_wrap_new_SomeType() -} - -var _wrap_delete_SomeType unsafe.Pointer - -func _swig_wrap_delete_SomeType(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_SomeType, _swig_p) - return -} - -func DeleteSomeType(arg1 SomeType) { - _swig_wrap_delete_SomeType(arg1.Swigcptr()) -} - -type SomeType interface { - Swigcptr() uintptr - SwigIsSomeType() -} - -type SwigcptrAnotherType uintptr - -func (p SwigcptrAnotherType) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrAnotherType) SwigIsAnotherType() { -} - -var _wrap_new_AnotherType unsafe.Pointer - -func _swig_wrap_new_AnotherType() (base SwigcptrAnotherType) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_AnotherType, _swig_p) - return -} - -func NewAnotherType() (_swig_ret AnotherType) { - return _swig_wrap_new_AnotherType() -} - -var _wrap_delete_AnotherType unsafe.Pointer - -func _swig_wrap_delete_AnotherType(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_AnotherType, _swig_p) - return -} - -func DeleteAnotherType(arg1 AnotherType) { - _swig_wrap_delete_AnotherType(arg1.Swigcptr()) -} - -type AnotherType interface { - Swigcptr() uintptr - SwigIsAnotherType() -} - -type SwigcptrDefaultBar uintptr - -func (p SwigcptrDefaultBar) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrDefaultBar) SwigIsDefaultBar() { -} - -var _wrap_DefaultBar_CType_set unsafe.Pointer - -func _swig_wrap_DefaultBar_CType_set(base SwigcptrDefaultBar, _ float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_DefaultBar_CType_set, _swig_p) - return -} - -func (arg1 SwigcptrDefaultBar) SetCType(arg2 float64) { - _swig_wrap_DefaultBar_CType_set(arg1, arg2) -} - -var _wrap_DefaultBar_CType_get unsafe.Pointer - -func _swig_wrap_DefaultBar_CType_get(base SwigcptrDefaultBar) (_ float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_DefaultBar_CType_get, _swig_p) - return -} - -func (arg1 SwigcptrDefaultBar) GetCType() (_swig_ret float64) { - return _swig_wrap_DefaultBar_CType_get(arg1) -} - -var _wrap_DefaultBar_DType_set unsafe.Pointer - -func _swig_wrap_DefaultBar_DType_set(base SwigcptrDefaultBar, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_DefaultBar_DType_set, _swig_p) - return -} - -func (arg1 SwigcptrDefaultBar) SetDType(arg2 SomeType) { - _swig_wrap_DefaultBar_DType_set(arg1, arg2.Swigcptr()) -} - -var _wrap_DefaultBar_DType_get unsafe.Pointer - -func _swig_wrap_DefaultBar_DType_get(base SwigcptrDefaultBar) (_ SwigcptrSomeType) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_DefaultBar_DType_get, _swig_p) - return -} - -func (arg1 SwigcptrDefaultBar) GetDType() (_swig_ret SomeType) { - return _swig_wrap_DefaultBar_DType_get(arg1) -} - -var _wrap_DefaultBar_EType_set unsafe.Pointer - -func _swig_wrap_DefaultBar_EType_set(base SwigcptrDefaultBar, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_DefaultBar_EType_set, _swig_p) - return -} - -func (arg1 SwigcptrDefaultBar) SetEType(arg2 int) { - _swig_wrap_DefaultBar_EType_set(arg1, arg2) -} - -var _wrap_DefaultBar_EType_get unsafe.Pointer - -func _swig_wrap_DefaultBar_EType_get(base SwigcptrDefaultBar) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_DefaultBar_EType_get, _swig_p) - return -} - -func (arg1 SwigcptrDefaultBar) GetEType() (_swig_ret int) { - return _swig_wrap_DefaultBar_EType_get(arg1) -} - -var _wrap_new_DefaultBar unsafe.Pointer - -func _swig_wrap_new_DefaultBar(base float64, _ uintptr, _ int) (_ SwigcptrDefaultBar) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_DefaultBar, _swig_p) - return -} - -func NewDefaultBar(arg1 float64, arg2 SomeType, arg3 int) (_swig_ret DefaultBar) { - return _swig_wrap_new_DefaultBar(arg1, arg2.Swigcptr(), arg3) -} - -var _wrap_DefaultBar_method unsafe.Pointer - -func _swig_wrap_DefaultBar_method(base SwigcptrDefaultBar, _ float64, _ uintptr, _ int) (_ float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_DefaultBar_method, _swig_p) - return -} - -func (arg1 SwigcptrDefaultBar) Method(arg2 float64, arg3 SomeType, arg4 int) (_swig_ret float64) { - return _swig_wrap_DefaultBar_method(arg1, arg2, arg3.Swigcptr(), arg4) -} - -var _wrap_delete_DefaultBar unsafe.Pointer - -func _swig_wrap_delete_DefaultBar(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_DefaultBar, _swig_p) - return -} - -func DeleteDefaultBar(arg1 DefaultBar) { - _swig_wrap_delete_DefaultBar(arg1.Swigcptr()) -} - -type DefaultBar interface { - Swigcptr() uintptr - SwigIsDefaultBar() - SetCType(arg2 float64) - GetCType() (_swig_ret float64) - SetDType(arg2 SomeType) - GetDType() (_swig_ret SomeType) - SetEType(arg2 int) - GetEType() (_swig_ret int) - Method(arg2 float64, arg3 SomeType, arg4 int) (_swig_ret float64) -} - -type SwigcptrDefaultFoo uintptr - -func (p SwigcptrDefaultFoo) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrDefaultFoo) SwigIsDefaultFoo() { -} - -var _wrap_DefaultFoo_TType_set unsafe.Pointer - -func _swig_wrap_DefaultFoo_TType_set(base SwigcptrDefaultFoo, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_DefaultFoo_TType_set, _swig_p) - return -} - -func (arg1 SwigcptrDefaultFoo) SetTType(arg2 SomeType) { - _swig_wrap_DefaultFoo_TType_set(arg1, arg2.Swigcptr()) -} - -var _wrap_DefaultFoo_TType_get unsafe.Pointer - -func _swig_wrap_DefaultFoo_TType_get(base SwigcptrDefaultFoo) (_ SwigcptrSomeType) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_DefaultFoo_TType_get, _swig_p) - return -} - -func (arg1 SwigcptrDefaultFoo) GetTType() (_swig_ret SomeType) { - return _swig_wrap_DefaultFoo_TType_get(arg1) -} - -var _wrap_new_DefaultFoo unsafe.Pointer - -func _swig_wrap_new_DefaultFoo(base uintptr) (_ SwigcptrDefaultFoo) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_DefaultFoo, _swig_p) - return -} - -func NewDefaultFoo(arg1 SomeType) (_swig_ret DefaultFoo) { - return _swig_wrap_new_DefaultFoo(arg1.Swigcptr()) -} - -var _wrap_DefaultFoo_method unsafe.Pointer - -func _swig_wrap_DefaultFoo_method(base SwigcptrDefaultFoo, _ uintptr) (_ SwigcptrSomeType) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_DefaultFoo_method, _swig_p) - return -} - -func (arg1 SwigcptrDefaultFoo) Method(arg2 SomeType) (_swig_ret SomeType) { - return _swig_wrap_DefaultFoo_method(arg1, arg2.Swigcptr()) -} - -var _wrap_delete_DefaultFoo unsafe.Pointer - -func _swig_wrap_delete_DefaultFoo(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_DefaultFoo, _swig_p) - return -} - -func DeleteDefaultFoo(arg1 DefaultFoo) { - _swig_wrap_delete_DefaultFoo(arg1.Swigcptr()) -} - -type DefaultFoo interface { - Swigcptr() uintptr - SwigIsDefaultFoo() - SetTType(arg2 SomeType) - GetTType() (_swig_ret SomeType) - Method(arg2 SomeType) (_swig_ret SomeType) -} - -type SwigcptrBarAnotherTypeBool uintptr - -func (p SwigcptrBarAnotherTypeBool) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrBarAnotherTypeBool) SwigIsBarAnotherTypeBool() { -} - -var _wrap_BarAnotherTypeBool_CType_set unsafe.Pointer - -func _swig_wrap_BarAnotherTypeBool_CType_set(base SwigcptrBarAnotherTypeBool, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_BarAnotherTypeBool_CType_set, _swig_p) - return -} - -func (arg1 SwigcptrBarAnotherTypeBool) SetCType(arg2 AnotherType) { - _swig_wrap_BarAnotherTypeBool_CType_set(arg1, arg2.Swigcptr()) -} - -var _wrap_BarAnotherTypeBool_CType_get unsafe.Pointer - -func _swig_wrap_BarAnotherTypeBool_CType_get(base SwigcptrBarAnotherTypeBool) (_ SwigcptrAnotherType) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_BarAnotherTypeBool_CType_get, _swig_p) - return -} - -func (arg1 SwigcptrBarAnotherTypeBool) GetCType() (_swig_ret AnotherType) { - return _swig_wrap_BarAnotherTypeBool_CType_get(arg1) -} - -var _wrap_BarAnotherTypeBool_DType_set unsafe.Pointer - -func _swig_wrap_BarAnotherTypeBool_DType_set(base SwigcptrBarAnotherTypeBool, _ bool) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_BarAnotherTypeBool_DType_set, _swig_p) - return -} - -func (arg1 SwigcptrBarAnotherTypeBool) SetDType(arg2 bool) { - _swig_wrap_BarAnotherTypeBool_DType_set(arg1, arg2) -} - -var _wrap_BarAnotherTypeBool_DType_get unsafe.Pointer - -func _swig_wrap_BarAnotherTypeBool_DType_get(base SwigcptrBarAnotherTypeBool) (_ bool) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_BarAnotherTypeBool_DType_get, _swig_p) - return -} - -func (arg1 SwigcptrBarAnotherTypeBool) GetDType() (_swig_ret bool) { - return _swig_wrap_BarAnotherTypeBool_DType_get(arg1) -} - -var _wrap_BarAnotherTypeBool_EType_set unsafe.Pointer - -func _swig_wrap_BarAnotherTypeBool_EType_set(base SwigcptrBarAnotherTypeBool, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_BarAnotherTypeBool_EType_set, _swig_p) - return -} - -func (arg1 SwigcptrBarAnotherTypeBool) SetEType(arg2 int) { - _swig_wrap_BarAnotherTypeBool_EType_set(arg1, arg2) -} - -var _wrap_BarAnotherTypeBool_EType_get unsafe.Pointer - -func _swig_wrap_BarAnotherTypeBool_EType_get(base SwigcptrBarAnotherTypeBool) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_BarAnotherTypeBool_EType_get, _swig_p) - return -} - -func (arg1 SwigcptrBarAnotherTypeBool) GetEType() (_swig_ret int) { - return _swig_wrap_BarAnotherTypeBool_EType_get(arg1) -} - -var _wrap_new_BarAnotherTypeBool unsafe.Pointer - -func _swig_wrap_new_BarAnotherTypeBool(base uintptr, _ bool, _ int) (_ SwigcptrBarAnotherTypeBool) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_BarAnotherTypeBool, _swig_p) - return -} - -func NewBarAnotherTypeBool(arg1 AnotherType, arg2 bool, arg3 int) (_swig_ret BarAnotherTypeBool) { - return _swig_wrap_new_BarAnotherTypeBool(arg1.Swigcptr(), arg2, arg3) -} - -var _wrap_BarAnotherTypeBool_method unsafe.Pointer - -func _swig_wrap_BarAnotherTypeBool_method(base SwigcptrBarAnotherTypeBool, _ uintptr, _ bool, _ int) (_ SwigcptrAnotherType) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_BarAnotherTypeBool_method, _swig_p) - return -} - -func (arg1 SwigcptrBarAnotherTypeBool) Method(arg2 AnotherType, arg3 bool, arg4 int) (_swig_ret AnotherType) { - return _swig_wrap_BarAnotherTypeBool_method(arg1, arg2.Swigcptr(), arg3, arg4) -} - -var _wrap_delete_BarAnotherTypeBool unsafe.Pointer - -func _swig_wrap_delete_BarAnotherTypeBool(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_BarAnotherTypeBool, _swig_p) - return -} - -func DeleteBarAnotherTypeBool(arg1 BarAnotherTypeBool) { - _swig_wrap_delete_BarAnotherTypeBool(arg1.Swigcptr()) -} - -type BarAnotherTypeBool interface { - Swigcptr() uintptr - SwigIsBarAnotherTypeBool() - SetCType(arg2 AnotherType) - GetCType() (_swig_ret AnotherType) - SetDType(arg2 bool) - GetDType() (_swig_ret bool) - SetEType(arg2 int) - GetEType() (_swig_ret int) - Method(arg2 AnotherType, arg3 bool, arg4 int) (_swig_ret AnotherType) -} - -type SwigcptrFooAnotherType uintptr - -func (p SwigcptrFooAnotherType) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrFooAnotherType) SwigIsFooAnotherType() { -} - -var _wrap_FooAnotherType_TType_set unsafe.Pointer - -func _swig_wrap_FooAnotherType_TType_set(base SwigcptrFooAnotherType, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_FooAnotherType_TType_set, _swig_p) - return -} - -func (arg1 SwigcptrFooAnotherType) SetTType(arg2 AnotherType) { - _swig_wrap_FooAnotherType_TType_set(arg1, arg2.Swigcptr()) -} - -var _wrap_FooAnotherType_TType_get unsafe.Pointer - -func _swig_wrap_FooAnotherType_TType_get(base SwigcptrFooAnotherType) (_ SwigcptrAnotherType) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_FooAnotherType_TType_get, _swig_p) - return -} - -func (arg1 SwigcptrFooAnotherType) GetTType() (_swig_ret AnotherType) { - return _swig_wrap_FooAnotherType_TType_get(arg1) -} - -var _wrap_new_FooAnotherType unsafe.Pointer - -func _swig_wrap_new_FooAnotherType(base uintptr) (_ SwigcptrFooAnotherType) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_FooAnotherType, _swig_p) - return -} - -func NewFooAnotherType(arg1 AnotherType) (_swig_ret FooAnotherType) { - return _swig_wrap_new_FooAnotherType(arg1.Swigcptr()) -} - -var _wrap_FooAnotherType_method unsafe.Pointer - -func _swig_wrap_FooAnotherType_method(base SwigcptrFooAnotherType, _ uintptr) (_ SwigcptrAnotherType) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_FooAnotherType_method, _swig_p) - return -} - -func (arg1 SwigcptrFooAnotherType) Method(arg2 AnotherType) (_swig_ret AnotherType) { - return _swig_wrap_FooAnotherType_method(arg1, arg2.Swigcptr()) -} - -var _wrap_delete_FooAnotherType unsafe.Pointer - -func _swig_wrap_delete_FooAnotherType(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_FooAnotherType, _swig_p) - return -} - -func DeleteFooAnotherType(arg1 FooAnotherType) { - _swig_wrap_delete_FooAnotherType(arg1.Swigcptr()) -} - -type FooAnotherType interface { - Swigcptr() uintptr - SwigIsFooAnotherType() - SetTType(arg2 AnotherType) - GetTType() (_swig_ret AnotherType) - Method(arg2 AnotherType) (_swig_ret AnotherType) -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/template_default_class_parms_typedef.go b/Examples/test-suite/go/template_default_class_parms_typedef.go deleted file mode 100644 index 4638c3168..000000000 --- a/Examples/test-suite/go/template_default_class_parms_typedef.go +++ /dev/null @@ -1,983 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../template_default_class_parms_typedef.i - -package template_default_class_parms_typedef - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrSomeType uintptr - -func (p SwigcptrSomeType) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrSomeType) SwigIsSomeType() { -} - -var _wrap_new_SomeType unsafe.Pointer - -func _swig_wrap_new_SomeType() (base SwigcptrSomeType) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_SomeType, _swig_p) - return -} - -func NewSomeType() (_swig_ret SomeType) { - return _swig_wrap_new_SomeType() -} - -var _wrap_delete_SomeType unsafe.Pointer - -func _swig_wrap_delete_SomeType(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_SomeType, _swig_p) - return -} - -func DeleteSomeType(arg1 SomeType) { - _swig_wrap_delete_SomeType(arg1.Swigcptr()) -} - -type SomeType interface { - Swigcptr() uintptr - SwigIsSomeType() -} - -type SwigcptrAnotherType uintptr - -func (p SwigcptrAnotherType) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrAnotherType) SwigIsAnotherType() { -} - -var _wrap_new_AnotherType unsafe.Pointer - -func _swig_wrap_new_AnotherType() (base SwigcptrAnotherType) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_AnotherType, _swig_p) - return -} - -func NewAnotherType() (_swig_ret AnotherType) { - return _swig_wrap_new_AnotherType() -} - -var _wrap_delete_AnotherType unsafe.Pointer - -func _swig_wrap_delete_AnotherType(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_AnotherType, _swig_p) - return -} - -func DeleteAnotherType(arg1 AnotherType) { - _swig_wrap_delete_AnotherType(arg1.Swigcptr()) -} - -type AnotherType interface { - Swigcptr() uintptr - SwigIsAnotherType() -} - -type SwigcptrDefaultBar uintptr - -func (p SwigcptrDefaultBar) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrDefaultBar) SwigIsDefaultBar() { -} - -var _wrap_DefaultBar_CType_set unsafe.Pointer - -func _swig_wrap_DefaultBar_CType_set(base SwigcptrDefaultBar, _ float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_DefaultBar_CType_set, _swig_p) - return -} - -func (arg1 SwigcptrDefaultBar) SetCType(arg2 float64) { - _swig_wrap_DefaultBar_CType_set(arg1, arg2) -} - -var _wrap_DefaultBar_CType_get unsafe.Pointer - -func _swig_wrap_DefaultBar_CType_get(base SwigcptrDefaultBar) (_ float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_DefaultBar_CType_get, _swig_p) - return -} - -func (arg1 SwigcptrDefaultBar) GetCType() (_swig_ret float64) { - return _swig_wrap_DefaultBar_CType_get(arg1) -} - -var _wrap_DefaultBar_DType_set unsafe.Pointer - -func _swig_wrap_DefaultBar_DType_set(base SwigcptrDefaultBar, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_DefaultBar_DType_set, _swig_p) - return -} - -func (arg1 SwigcptrDefaultBar) SetDType(arg2 SomeType) { - _swig_wrap_DefaultBar_DType_set(arg1, arg2.Swigcptr()) -} - -var _wrap_DefaultBar_DType_get unsafe.Pointer - -func _swig_wrap_DefaultBar_DType_get(base SwigcptrDefaultBar) (_ SwigcptrSomeType) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_DefaultBar_DType_get, _swig_p) - return -} - -func (arg1 SwigcptrDefaultBar) GetDType() (_swig_ret SomeType) { - return _swig_wrap_DefaultBar_DType_get(arg1) -} - -var _wrap_DefaultBar_EType_set unsafe.Pointer - -func _swig_wrap_DefaultBar_EType_set(base SwigcptrDefaultBar, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_DefaultBar_EType_set, _swig_p) - return -} - -func (arg1 SwigcptrDefaultBar) SetEType(arg2 int) { - _swig_wrap_DefaultBar_EType_set(arg1, arg2) -} - -var _wrap_DefaultBar_EType_get unsafe.Pointer - -func _swig_wrap_DefaultBar_EType_get(base SwigcptrDefaultBar) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_DefaultBar_EType_get, _swig_p) - return -} - -func (arg1 SwigcptrDefaultBar) GetEType() (_swig_ret int) { - return _swig_wrap_DefaultBar_EType_get(arg1) -} - -var _wrap_new_DefaultBar__SWIG_0 unsafe.Pointer - -func _swig_wrap_new_DefaultBar__SWIG_0(base float64, _ uintptr, _ int) (_ SwigcptrDefaultBar) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_DefaultBar__SWIG_0, _swig_p) - return -} - -func NewDefaultBar__SWIG_0(arg1 float64, arg2 SomeType, arg3 int) (_swig_ret DefaultBar) { - return _swig_wrap_new_DefaultBar__SWIG_0(arg1, arg2.Swigcptr(), arg3) -} - -var _wrap_DefaultBar_method unsafe.Pointer - -func _swig_wrap_DefaultBar_method(base SwigcptrDefaultBar, _ float64, _ uintptr, _ int) (_ float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_DefaultBar_method, _swig_p) - return -} - -func (arg1 SwigcptrDefaultBar) Method(arg2 float64, arg3 SomeType, arg4 int) (_swig_ret float64) { - return _swig_wrap_DefaultBar_method(arg1, arg2, arg3.Swigcptr(), arg4) -} - -var _wrap_new_DefaultBar__SWIG_1 unsafe.Pointer - -func _swig_wrap_new_DefaultBar__SWIG_1(base bool, _ float64, _ uintptr, _ int) (_ SwigcptrDefaultBar) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_DefaultBar__SWIG_1, _swig_p) - return -} - -func NewDefaultBar__SWIG_1(arg1 bool, arg2 float64, arg3 SomeType, arg4 int) (_swig_ret DefaultBar) { - return _swig_wrap_new_DefaultBar__SWIG_1(arg1, arg2, arg3.Swigcptr(), arg4) -} - -var _wrap_DefaultBar_method_1 unsafe.Pointer - -func _swig_wrap_DefaultBar_method_1(base SwigcptrDefaultBar, _ float64, _ uintptr, _ int) (_ float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_DefaultBar_method_1, _swig_p) - return -} - -func (arg1 SwigcptrDefaultBar) Method_1(arg2 float64, arg3 SomeType, arg4 int) (_swig_ret float64) { - return _swig_wrap_DefaultBar_method_1(arg1, arg2, arg3.Swigcptr(), arg4) -} - -var _wrap_new_DefaultBar__SWIG_2 unsafe.Pointer - -func _swig_wrap_new_DefaultBar__SWIG_2(base bool, _ bool, _ float64, _ uintptr, _ int) (_ SwigcptrDefaultBar) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_DefaultBar__SWIG_2, _swig_p) - return -} - -func NewDefaultBar__SWIG_2(arg1 bool, arg2 bool, arg3 float64, arg4 SomeType, arg5 int) (_swig_ret DefaultBar) { - return _swig_wrap_new_DefaultBar__SWIG_2(arg1, arg2, arg3, arg4.Swigcptr(), arg5) -} - -var _wrap_DefaultBar_method_2 unsafe.Pointer - -func _swig_wrap_DefaultBar_method_2(base SwigcptrDefaultBar, _ float64, _ uintptr, _ int) (_ float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_DefaultBar_method_2, _swig_p) - return -} - -func (arg1 SwigcptrDefaultBar) Method_2(arg2 float64, arg3 SomeType, arg4 int) (_swig_ret float64) { - return _swig_wrap_DefaultBar_method_2(arg1, arg2, arg3.Swigcptr(), arg4) -} - -var _wrap_new_DefaultBar__SWIG_3 unsafe.Pointer - -func _swig_wrap_new_DefaultBar__SWIG_3(base bool, _ bool, _ bool, _ float64, _ uintptr, _ int) (_ SwigcptrDefaultBar) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_DefaultBar__SWIG_3, _swig_p) - return -} - -func NewDefaultBar__SWIG_3(arg1 bool, arg2 bool, arg3 bool, arg4 float64, arg5 SomeType, arg6 int) (_swig_ret DefaultBar) { - return _swig_wrap_new_DefaultBar__SWIG_3(arg1, arg2, arg3, arg4, arg5.Swigcptr(), arg6) -} - -func NewDefaultBar(a ...interface{}) DefaultBar { - argc := len(a) - if argc == 3 { - return NewDefaultBar__SWIG_0(a[0].(float64), a[1].(SomeType), a[2].(int)) - } - if argc == 4 { - return NewDefaultBar__SWIG_1(a[0].(bool), a[1].(float64), a[2].(SomeType), a[3].(int)) - } - if argc == 5 { - return NewDefaultBar__SWIG_2(a[0].(bool), a[1].(bool), a[2].(float64), a[3].(SomeType), a[4].(int)) - } - if argc == 6 { - return NewDefaultBar__SWIG_3(a[0].(bool), a[1].(bool), a[2].(bool), a[3].(float64), a[4].(SomeType), a[5].(int)) - } - panic("No match for overloaded function call") -} - -var _wrap_DefaultBar_method_3 unsafe.Pointer - -func _swig_wrap_DefaultBar_method_3(base SwigcptrDefaultBar, _ float64, _ uintptr, _ int) (_ float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_DefaultBar_method_3, _swig_p) - return -} - -func (arg1 SwigcptrDefaultBar) Method_3(arg2 float64, arg3 SomeType, arg4 int) (_swig_ret float64) { - return _swig_wrap_DefaultBar_method_3(arg1, arg2, arg3.Swigcptr(), arg4) -} - -var _wrap_delete_DefaultBar unsafe.Pointer - -func _swig_wrap_delete_DefaultBar(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_DefaultBar, _swig_p) - return -} - -func DeleteDefaultBar(arg1 DefaultBar) { - _swig_wrap_delete_DefaultBar(arg1.Swigcptr()) -} - -type DefaultBar interface { - Swigcptr() uintptr - SwigIsDefaultBar() - SetCType(arg2 float64) - GetCType() (_swig_ret float64) - SetDType(arg2 SomeType) - GetDType() (_swig_ret SomeType) - SetEType(arg2 int) - GetEType() (_swig_ret int) - Method(arg2 float64, arg3 SomeType, arg4 int) (_swig_ret float64) - Method_1(arg2 float64, arg3 SomeType, arg4 int) (_swig_ret float64) - Method_2(arg2 float64, arg3 SomeType, arg4 int) (_swig_ret float64) - Method_3(arg2 float64, arg3 SomeType, arg4 int) (_swig_ret float64) -} - -type SwigcptrDefaultFoo uintptr - -func (p SwigcptrDefaultFoo) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrDefaultFoo) SwigIsDefaultFoo() { -} - -var _wrap_DefaultFoo_TType_set unsafe.Pointer - -func _swig_wrap_DefaultFoo_TType_set(base SwigcptrDefaultFoo, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_DefaultFoo_TType_set, _swig_p) - return -} - -func (arg1 SwigcptrDefaultFoo) SetTType(arg2 SomeType) { - _swig_wrap_DefaultFoo_TType_set(arg1, arg2.Swigcptr()) -} - -var _wrap_DefaultFoo_TType_get unsafe.Pointer - -func _swig_wrap_DefaultFoo_TType_get(base SwigcptrDefaultFoo) (_ SwigcptrSomeType) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_DefaultFoo_TType_get, _swig_p) - return -} - -func (arg1 SwigcptrDefaultFoo) GetTType() (_swig_ret SomeType) { - return _swig_wrap_DefaultFoo_TType_get(arg1) -} - -var _wrap_new_DefaultFoo__SWIG_0 unsafe.Pointer - -func _swig_wrap_new_DefaultFoo__SWIG_0(base uintptr) (_ SwigcptrDefaultFoo) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_DefaultFoo__SWIG_0, _swig_p) - return -} - -func NewDefaultFoo__SWIG_0(arg1 SomeType) (_swig_ret DefaultFoo) { - return _swig_wrap_new_DefaultFoo__SWIG_0(arg1.Swigcptr()) -} - -var _wrap_DefaultFoo_method unsafe.Pointer - -func _swig_wrap_DefaultFoo_method(base SwigcptrDefaultFoo, _ uintptr) (_ SwigcptrSomeType) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_DefaultFoo_method, _swig_p) - return -} - -func (arg1 SwigcptrDefaultFoo) Method(arg2 SomeType) (_swig_ret SomeType) { - return _swig_wrap_DefaultFoo_method(arg1, arg2.Swigcptr()) -} - -var _wrap_new_DefaultFoo__SWIG_1 unsafe.Pointer - -func _swig_wrap_new_DefaultFoo__SWIG_1(base uintptr, _ uintptr) (_ SwigcptrDefaultFoo) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_DefaultFoo__SWIG_1, _swig_p) - return -} - -func NewDefaultFoo__SWIG_1(arg1 SomeType, arg2 SomeType) (_swig_ret DefaultFoo) { - return _swig_wrap_new_DefaultFoo__SWIG_1(arg1.Swigcptr(), arg2.Swigcptr()) -} - -var _wrap_DefaultFoo_method_A unsafe.Pointer - -func _swig_wrap_DefaultFoo_method_A(base SwigcptrDefaultFoo, _ uintptr) (_ SwigcptrSomeType) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_DefaultFoo_method_A, _swig_p) - return -} - -func (arg1 SwigcptrDefaultFoo) Method_A(arg2 SomeType) (_swig_ret SomeType) { - return _swig_wrap_DefaultFoo_method_A(arg1, arg2.Swigcptr()) -} - -var _wrap_new_DefaultFoo__SWIG_2 unsafe.Pointer - -func _swig_wrap_new_DefaultFoo__SWIG_2(base uintptr, _ uintptr, _ uintptr) (_ SwigcptrDefaultFoo) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_DefaultFoo__SWIG_2, _swig_p) - return -} - -func NewDefaultFoo__SWIG_2(arg1 SomeType, arg2 SomeType, arg3 SomeType) (_swig_ret DefaultFoo) { - return _swig_wrap_new_DefaultFoo__SWIG_2(arg1.Swigcptr(), arg2.Swigcptr(), arg3.Swigcptr()) -} - -var _wrap_DefaultFoo_method_B unsafe.Pointer - -func _swig_wrap_DefaultFoo_method_B(base SwigcptrDefaultFoo, _ uintptr) (_ SwigcptrSomeType) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_DefaultFoo_method_B, _swig_p) - return -} - -func (arg1 SwigcptrDefaultFoo) Method_B(arg2 SomeType) (_swig_ret SomeType) { - return _swig_wrap_DefaultFoo_method_B(arg1, arg2.Swigcptr()) -} - -var _wrap_new_DefaultFoo__SWIG_3 unsafe.Pointer - -func _swig_wrap_new_DefaultFoo__SWIG_3(base uintptr, _ uintptr, _ uintptr, _ uintptr) (_ SwigcptrDefaultFoo) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_DefaultFoo__SWIG_3, _swig_p) - return -} - -func NewDefaultFoo__SWIG_3(arg1 SomeType, arg2 SomeType, arg3 SomeType, arg4 SomeType) (_swig_ret DefaultFoo) { - return _swig_wrap_new_DefaultFoo__SWIG_3(arg1.Swigcptr(), arg2.Swigcptr(), arg3.Swigcptr(), arg4.Swigcptr()) -} - -func NewDefaultFoo(a ...interface{}) DefaultFoo { - argc := len(a) - if argc == 1 { - return NewDefaultFoo__SWIG_0(a[0].(SomeType)) - } - if argc == 2 { - return NewDefaultFoo__SWIG_1(a[0].(SomeType), a[1].(SomeType)) - } - if argc == 3 { - return NewDefaultFoo__SWIG_2(a[0].(SomeType), a[1].(SomeType), a[2].(SomeType)) - } - if argc == 4 { - return NewDefaultFoo__SWIG_3(a[0].(SomeType), a[1].(SomeType), a[2].(SomeType), a[3].(SomeType)) - } - panic("No match for overloaded function call") -} - -var _wrap_DefaultFoo_method_C unsafe.Pointer - -func _swig_wrap_DefaultFoo_method_C(base SwigcptrDefaultFoo, _ uintptr) (_ SwigcptrSomeType) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_DefaultFoo_method_C, _swig_p) - return -} - -func (arg1 SwigcptrDefaultFoo) Method_C(arg2 SomeType) (_swig_ret SomeType) { - return _swig_wrap_DefaultFoo_method_C(arg1, arg2.Swigcptr()) -} - -var _wrap_delete_DefaultFoo unsafe.Pointer - -func _swig_wrap_delete_DefaultFoo(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_DefaultFoo, _swig_p) - return -} - -func DeleteDefaultFoo(arg1 DefaultFoo) { - _swig_wrap_delete_DefaultFoo(arg1.Swigcptr()) -} - -type DefaultFoo interface { - Swigcptr() uintptr - SwigIsDefaultFoo() - SetTType(arg2 SomeType) - GetTType() (_swig_ret SomeType) - Method(arg2 SomeType) (_swig_ret SomeType) - Method_A(arg2 SomeType) (_swig_ret SomeType) - Method_B(arg2 SomeType) (_swig_ret SomeType) - Method_C(arg2 SomeType) (_swig_ret SomeType) -} - -type SwigcptrBarAnotherTypeBool uintptr - -func (p SwigcptrBarAnotherTypeBool) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrBarAnotherTypeBool) SwigIsBarAnotherTypeBool() { -} - -var _wrap_BarAnotherTypeBool_CType_set unsafe.Pointer - -func _swig_wrap_BarAnotherTypeBool_CType_set(base SwigcptrBarAnotherTypeBool, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_BarAnotherTypeBool_CType_set, _swig_p) - return -} - -func (arg1 SwigcptrBarAnotherTypeBool) SetCType(arg2 AnotherType) { - _swig_wrap_BarAnotherTypeBool_CType_set(arg1, arg2.Swigcptr()) -} - -var _wrap_BarAnotherTypeBool_CType_get unsafe.Pointer - -func _swig_wrap_BarAnotherTypeBool_CType_get(base SwigcptrBarAnotherTypeBool) (_ SwigcptrAnotherType) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_BarAnotherTypeBool_CType_get, _swig_p) - return -} - -func (arg1 SwigcptrBarAnotherTypeBool) GetCType() (_swig_ret AnotherType) { - return _swig_wrap_BarAnotherTypeBool_CType_get(arg1) -} - -var _wrap_BarAnotherTypeBool_DType_set unsafe.Pointer - -func _swig_wrap_BarAnotherTypeBool_DType_set(base SwigcptrBarAnotherTypeBool, _ bool) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_BarAnotherTypeBool_DType_set, _swig_p) - return -} - -func (arg1 SwigcptrBarAnotherTypeBool) SetDType(arg2 bool) { - _swig_wrap_BarAnotherTypeBool_DType_set(arg1, arg2) -} - -var _wrap_BarAnotherTypeBool_DType_get unsafe.Pointer - -func _swig_wrap_BarAnotherTypeBool_DType_get(base SwigcptrBarAnotherTypeBool) (_ bool) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_BarAnotherTypeBool_DType_get, _swig_p) - return -} - -func (arg1 SwigcptrBarAnotherTypeBool) GetDType() (_swig_ret bool) { - return _swig_wrap_BarAnotherTypeBool_DType_get(arg1) -} - -var _wrap_BarAnotherTypeBool_EType_set unsafe.Pointer - -func _swig_wrap_BarAnotherTypeBool_EType_set(base SwigcptrBarAnotherTypeBool, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_BarAnotherTypeBool_EType_set, _swig_p) - return -} - -func (arg1 SwigcptrBarAnotherTypeBool) SetEType(arg2 int) { - _swig_wrap_BarAnotherTypeBool_EType_set(arg1, arg2) -} - -var _wrap_BarAnotherTypeBool_EType_get unsafe.Pointer - -func _swig_wrap_BarAnotherTypeBool_EType_get(base SwigcptrBarAnotherTypeBool) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_BarAnotherTypeBool_EType_get, _swig_p) - return -} - -func (arg1 SwigcptrBarAnotherTypeBool) GetEType() (_swig_ret int) { - return _swig_wrap_BarAnotherTypeBool_EType_get(arg1) -} - -var _wrap_new_BarAnotherTypeBool__SWIG_0 unsafe.Pointer - -func _swig_wrap_new_BarAnotherTypeBool__SWIG_0(base uintptr, _ bool, _ int) (_ SwigcptrBarAnotherTypeBool) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_BarAnotherTypeBool__SWIG_0, _swig_p) - return -} - -func NewBarAnotherTypeBool__SWIG_0(arg1 AnotherType, arg2 bool, arg3 int) (_swig_ret BarAnotherTypeBool) { - return _swig_wrap_new_BarAnotherTypeBool__SWIG_0(arg1.Swigcptr(), arg2, arg3) -} - -var _wrap_BarAnotherTypeBool_method unsafe.Pointer - -func _swig_wrap_BarAnotherTypeBool_method(base SwigcptrBarAnotherTypeBool, _ uintptr, _ bool, _ int) (_ SwigcptrAnotherType) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_BarAnotherTypeBool_method, _swig_p) - return -} - -func (arg1 SwigcptrBarAnotherTypeBool) Method(arg2 AnotherType, arg3 bool, arg4 int) (_swig_ret AnotherType) { - return _swig_wrap_BarAnotherTypeBool_method(arg1, arg2.Swigcptr(), arg3, arg4) -} - -var _wrap_new_BarAnotherTypeBool__SWIG_1 unsafe.Pointer - -func _swig_wrap_new_BarAnotherTypeBool__SWIG_1(base bool, _ uintptr, _ bool, _ int) (_ SwigcptrBarAnotherTypeBool) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_BarAnotherTypeBool__SWIG_1, _swig_p) - return -} - -func NewBarAnotherTypeBool__SWIG_1(arg1 bool, arg2 AnotherType, arg3 bool, arg4 int) (_swig_ret BarAnotherTypeBool) { - return _swig_wrap_new_BarAnotherTypeBool__SWIG_1(arg1, arg2.Swigcptr(), arg3, arg4) -} - -var _wrap_BarAnotherTypeBool_method_1 unsafe.Pointer - -func _swig_wrap_BarAnotherTypeBool_method_1(base SwigcptrBarAnotherTypeBool, _ uintptr, _ bool, _ int) (_ SwigcptrAnotherType) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_BarAnotherTypeBool_method_1, _swig_p) - return -} - -func (arg1 SwigcptrBarAnotherTypeBool) Method_1(arg2 AnotherType, arg3 bool, arg4 int) (_swig_ret AnotherType) { - return _swig_wrap_BarAnotherTypeBool_method_1(arg1, arg2.Swigcptr(), arg3, arg4) -} - -var _wrap_new_BarAnotherTypeBool__SWIG_2 unsafe.Pointer - -func _swig_wrap_new_BarAnotherTypeBool__SWIG_2(base bool, _ bool, _ uintptr, _ bool, _ int) (_ SwigcptrBarAnotherTypeBool) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_BarAnotherTypeBool__SWIG_2, _swig_p) - return -} - -func NewBarAnotherTypeBool__SWIG_2(arg1 bool, arg2 bool, arg3 AnotherType, arg4 bool, arg5 int) (_swig_ret BarAnotherTypeBool) { - return _swig_wrap_new_BarAnotherTypeBool__SWIG_2(arg1, arg2, arg3.Swigcptr(), arg4, arg5) -} - -var _wrap_BarAnotherTypeBool_method_2 unsafe.Pointer - -func _swig_wrap_BarAnotherTypeBool_method_2(base SwigcptrBarAnotherTypeBool, _ uintptr, _ bool, _ int) (_ SwigcptrAnotherType) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_BarAnotherTypeBool_method_2, _swig_p) - return -} - -func (arg1 SwigcptrBarAnotherTypeBool) Method_2(arg2 AnotherType, arg3 bool, arg4 int) (_swig_ret AnotherType) { - return _swig_wrap_BarAnotherTypeBool_method_2(arg1, arg2.Swigcptr(), arg3, arg4) -} - -var _wrap_new_BarAnotherTypeBool__SWIG_3 unsafe.Pointer - -func _swig_wrap_new_BarAnotherTypeBool__SWIG_3(base bool, _ bool, _ bool, _ uintptr, _ bool, _ int) (_ SwigcptrBarAnotherTypeBool) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_BarAnotherTypeBool__SWIG_3, _swig_p) - return -} - -func NewBarAnotherTypeBool__SWIG_3(arg1 bool, arg2 bool, arg3 bool, arg4 AnotherType, arg5 bool, arg6 int) (_swig_ret BarAnotherTypeBool) { - return _swig_wrap_new_BarAnotherTypeBool__SWIG_3(arg1, arg2, arg3, arg4.Swigcptr(), arg5, arg6) -} - -func NewBarAnotherTypeBool(a ...interface{}) BarAnotherTypeBool { - argc := len(a) - if argc == 3 { - return NewBarAnotherTypeBool__SWIG_0(a[0].(AnotherType), a[1].(bool), a[2].(int)) - } - if argc == 4 { - return NewBarAnotherTypeBool__SWIG_1(a[0].(bool), a[1].(AnotherType), a[2].(bool), a[3].(int)) - } - if argc == 5 { - return NewBarAnotherTypeBool__SWIG_2(a[0].(bool), a[1].(bool), a[2].(AnotherType), a[3].(bool), a[4].(int)) - } - if argc == 6 { - return NewBarAnotherTypeBool__SWIG_3(a[0].(bool), a[1].(bool), a[2].(bool), a[3].(AnotherType), a[4].(bool), a[5].(int)) - } - panic("No match for overloaded function call") -} - -var _wrap_BarAnotherTypeBool_method_3 unsafe.Pointer - -func _swig_wrap_BarAnotherTypeBool_method_3(base SwigcptrBarAnotherTypeBool, _ uintptr, _ bool, _ int) (_ SwigcptrAnotherType) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_BarAnotherTypeBool_method_3, _swig_p) - return -} - -func (arg1 SwigcptrBarAnotherTypeBool) Method_3(arg2 AnotherType, arg3 bool, arg4 int) (_swig_ret AnotherType) { - return _swig_wrap_BarAnotherTypeBool_method_3(arg1, arg2.Swigcptr(), arg3, arg4) -} - -var _wrap_delete_BarAnotherTypeBool unsafe.Pointer - -func _swig_wrap_delete_BarAnotherTypeBool(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_BarAnotherTypeBool, _swig_p) - return -} - -func DeleteBarAnotherTypeBool(arg1 BarAnotherTypeBool) { - _swig_wrap_delete_BarAnotherTypeBool(arg1.Swigcptr()) -} - -type BarAnotherTypeBool interface { - Swigcptr() uintptr - SwigIsBarAnotherTypeBool() - SetCType(arg2 AnotherType) - GetCType() (_swig_ret AnotherType) - SetDType(arg2 bool) - GetDType() (_swig_ret bool) - SetEType(arg2 int) - GetEType() (_swig_ret int) - Method(arg2 AnotherType, arg3 bool, arg4 int) (_swig_ret AnotherType) - Method_1(arg2 AnotherType, arg3 bool, arg4 int) (_swig_ret AnotherType) - Method_2(arg2 AnotherType, arg3 bool, arg4 int) (_swig_ret AnotherType) - Method_3(arg2 AnotherType, arg3 bool, arg4 int) (_swig_ret AnotherType) -} - -type SwigcptrFooAnotherType uintptr - -func (p SwigcptrFooAnotherType) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrFooAnotherType) SwigIsFooAnotherType() { -} - -var _wrap_FooAnotherType_TType_set unsafe.Pointer - -func _swig_wrap_FooAnotherType_TType_set(base SwigcptrFooAnotherType, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_FooAnotherType_TType_set, _swig_p) - return -} - -func (arg1 SwigcptrFooAnotherType) SetTType(arg2 AnotherType) { - _swig_wrap_FooAnotherType_TType_set(arg1, arg2.Swigcptr()) -} - -var _wrap_FooAnotherType_TType_get unsafe.Pointer - -func _swig_wrap_FooAnotherType_TType_get(base SwigcptrFooAnotherType) (_ SwigcptrAnotherType) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_FooAnotherType_TType_get, _swig_p) - return -} - -func (arg1 SwigcptrFooAnotherType) GetTType() (_swig_ret AnotherType) { - return _swig_wrap_FooAnotherType_TType_get(arg1) -} - -var _wrap_new_FooAnotherType__SWIG_0 unsafe.Pointer - -func _swig_wrap_new_FooAnotherType__SWIG_0(base uintptr) (_ SwigcptrFooAnotherType) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_FooAnotherType__SWIG_0, _swig_p) - return -} - -func NewFooAnotherType__SWIG_0(arg1 AnotherType) (_swig_ret FooAnotherType) { - return _swig_wrap_new_FooAnotherType__SWIG_0(arg1.Swigcptr()) -} - -var _wrap_FooAnotherType_method unsafe.Pointer - -func _swig_wrap_FooAnotherType_method(base SwigcptrFooAnotherType, _ uintptr) (_ SwigcptrAnotherType) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_FooAnotherType_method, _swig_p) - return -} - -func (arg1 SwigcptrFooAnotherType) Method(arg2 AnotherType) (_swig_ret AnotherType) { - return _swig_wrap_FooAnotherType_method(arg1, arg2.Swigcptr()) -} - -var _wrap_new_FooAnotherType__SWIG_1 unsafe.Pointer - -func _swig_wrap_new_FooAnotherType__SWIG_1(base uintptr, _ uintptr) (_ SwigcptrFooAnotherType) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_FooAnotherType__SWIG_1, _swig_p) - return -} - -func NewFooAnotherType__SWIG_1(arg1 AnotherType, arg2 AnotherType) (_swig_ret FooAnotherType) { - return _swig_wrap_new_FooAnotherType__SWIG_1(arg1.Swigcptr(), arg2.Swigcptr()) -} - -var _wrap_FooAnotherType_method_A unsafe.Pointer - -func _swig_wrap_FooAnotherType_method_A(base SwigcptrFooAnotherType, _ uintptr) (_ SwigcptrAnotherType) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_FooAnotherType_method_A, _swig_p) - return -} - -func (arg1 SwigcptrFooAnotherType) Method_A(arg2 AnotherType) (_swig_ret AnotherType) { - return _swig_wrap_FooAnotherType_method_A(arg1, arg2.Swigcptr()) -} - -var _wrap_new_FooAnotherType__SWIG_2 unsafe.Pointer - -func _swig_wrap_new_FooAnotherType__SWIG_2(base uintptr, _ uintptr, _ uintptr) (_ SwigcptrFooAnotherType) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_FooAnotherType__SWIG_2, _swig_p) - return -} - -func NewFooAnotherType__SWIG_2(arg1 AnotherType, arg2 AnotherType, arg3 AnotherType) (_swig_ret FooAnotherType) { - return _swig_wrap_new_FooAnotherType__SWIG_2(arg1.Swigcptr(), arg2.Swigcptr(), arg3.Swigcptr()) -} - -var _wrap_FooAnotherType_method_B unsafe.Pointer - -func _swig_wrap_FooAnotherType_method_B(base SwigcptrFooAnotherType, _ uintptr) (_ SwigcptrAnotherType) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_FooAnotherType_method_B, _swig_p) - return -} - -func (arg1 SwigcptrFooAnotherType) Method_B(arg2 AnotherType) (_swig_ret AnotherType) { - return _swig_wrap_FooAnotherType_method_B(arg1, arg2.Swigcptr()) -} - -var _wrap_new_FooAnotherType__SWIG_3 unsafe.Pointer - -func _swig_wrap_new_FooAnotherType__SWIG_3(base uintptr, _ uintptr, _ uintptr, _ uintptr) (_ SwigcptrFooAnotherType) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_FooAnotherType__SWIG_3, _swig_p) - return -} - -func NewFooAnotherType__SWIG_3(arg1 AnotherType, arg2 AnotherType, arg3 AnotherType, arg4 AnotherType) (_swig_ret FooAnotherType) { - return _swig_wrap_new_FooAnotherType__SWIG_3(arg1.Swigcptr(), arg2.Swigcptr(), arg3.Swigcptr(), arg4.Swigcptr()) -} - -func NewFooAnotherType(a ...interface{}) FooAnotherType { - argc := len(a) - if argc == 1 { - return NewFooAnotherType__SWIG_0(a[0].(AnotherType)) - } - if argc == 2 { - return NewFooAnotherType__SWIG_1(a[0].(AnotherType), a[1].(AnotherType)) - } - if argc == 3 { - return NewFooAnotherType__SWIG_2(a[0].(AnotherType), a[1].(AnotherType), a[2].(AnotherType)) - } - if argc == 4 { - return NewFooAnotherType__SWIG_3(a[0].(AnotherType), a[1].(AnotherType), a[2].(AnotherType), a[3].(AnotherType)) - } - panic("No match for overloaded function call") -} - -var _wrap_FooAnotherType_method_C unsafe.Pointer - -func _swig_wrap_FooAnotherType_method_C(base SwigcptrFooAnotherType, _ uintptr) (_ SwigcptrAnotherType) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_FooAnotherType_method_C, _swig_p) - return -} - -func (arg1 SwigcptrFooAnotherType) Method_C(arg2 AnotherType) (_swig_ret AnotherType) { - return _swig_wrap_FooAnotherType_method_C(arg1, arg2.Swigcptr()) -} - -var _wrap_delete_FooAnotherType unsafe.Pointer - -func _swig_wrap_delete_FooAnotherType(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_FooAnotherType, _swig_p) - return -} - -func DeleteFooAnotherType(arg1 FooAnotherType) { - _swig_wrap_delete_FooAnotherType(arg1.Swigcptr()) -} - -type FooAnotherType interface { - Swigcptr() uintptr - SwigIsFooAnotherType() - SetTType(arg2 AnotherType) - GetTType() (_swig_ret AnotherType) - Method(arg2 AnotherType) (_swig_ret AnotherType) - Method_A(arg2 AnotherType) (_swig_ret AnotherType) - Method_B(arg2 AnotherType) (_swig_ret AnotherType) - Method_C(arg2 AnotherType) (_swig_ret AnotherType) -} - -type SwigcptrUsesBarDouble uintptr - -func (p SwigcptrUsesBarDouble) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrUsesBarDouble) SwigIsUsesBarDouble() { -} - -var _wrap_UsesBarDouble_use_A unsafe.Pointer - -func _swig_wrap_UsesBarDouble_use_A(base SwigcptrUsesBarDouble, _ float64, _ uintptr, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_UsesBarDouble_use_A, _swig_p) - return -} - -func (arg1 SwigcptrUsesBarDouble) Use_A(arg2 float64, arg3 SomeType, arg4 int) { - _swig_wrap_UsesBarDouble_use_A(arg1, arg2, arg3.Swigcptr(), arg4) -} - -var _wrap_UsesBarDouble_use_B unsafe.Pointer - -func _swig_wrap_UsesBarDouble_use_B(base SwigcptrUsesBarDouble, _ float64, _ uintptr, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_UsesBarDouble_use_B, _swig_p) - return -} - -func (arg1 SwigcptrUsesBarDouble) Use_B(arg2 float64, arg3 SomeType, arg4 int) { - _swig_wrap_UsesBarDouble_use_B(arg1, arg2, arg3.Swigcptr(), arg4) -} - -var _wrap_UsesBarDouble_use_C unsafe.Pointer - -func _swig_wrap_UsesBarDouble_use_C(base SwigcptrUsesBarDouble, _ float64, _ uintptr, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_UsesBarDouble_use_C, _swig_p) - return -} - -func (arg1 SwigcptrUsesBarDouble) Use_C(arg2 float64, arg3 SomeType, arg4 int) { - _swig_wrap_UsesBarDouble_use_C(arg1, arg2, arg3.Swigcptr(), arg4) -} - -var _wrap_UsesBarDouble_use_D unsafe.Pointer - -func _swig_wrap_UsesBarDouble_use_D(base SwigcptrUsesBarDouble, _ float64, _ uintptr, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_UsesBarDouble_use_D, _swig_p) - return -} - -func (arg1 SwigcptrUsesBarDouble) Use_D(arg2 float64, arg3 SomeType, arg4 int) { - _swig_wrap_UsesBarDouble_use_D(arg1, arg2, arg3.Swigcptr(), arg4) -} - -var _wrap_new_UsesBarDouble unsafe.Pointer - -func _swig_wrap_new_UsesBarDouble() (base SwigcptrUsesBarDouble) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_UsesBarDouble, _swig_p) - return -} - -func NewUsesBarDouble() (_swig_ret UsesBarDouble) { - return _swig_wrap_new_UsesBarDouble() -} - -var _wrap_delete_UsesBarDouble unsafe.Pointer - -func _swig_wrap_delete_UsesBarDouble(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_UsesBarDouble, _swig_p) - return -} - -func DeleteUsesBarDouble(arg1 UsesBarDouble) { - _swig_wrap_delete_UsesBarDouble(arg1.Swigcptr()) -} - -type UsesBarDouble interface { - Swigcptr() uintptr - SwigIsUsesBarDouble() - Use_A(arg2 float64, arg3 SomeType, arg4 int) - Use_B(arg2 float64, arg3 SomeType, arg4 int) - Use_C(arg2 float64, arg3 SomeType, arg4 int) - Use_D(arg2 float64, arg3 SomeType, arg4 int) -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/template_default_inherit.go b/Examples/test-suite/go/template_default_inherit.go deleted file mode 100644 index 6fae760d6..000000000 --- a/Examples/test-suite/go/template_default_inherit.go +++ /dev/null @@ -1,168 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../template_default_inherit.i - -package template_default_inherit - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrA_int uintptr - -func (p SwigcptrA_int) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrA_int) SwigIsA_int() { -} - -var _wrap_A_int_nindex_A_int unsafe.Pointer - -func _swig_getA_int_A_int_nindex_A_int() (_swig_ret uint) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_A_int_nindex_A_int, _swig_p) - return -} -var A_intNindex uint = _swig_getA_int_A_int_nindex_A_int() -var _wrap_new_A_int unsafe.Pointer - -func _swig_wrap_new_A_int() (base SwigcptrA_int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_A_int, _swig_p) - return -} - -func NewA_int() (_swig_ret A_int) { - return _swig_wrap_new_A_int() -} - -var _wrap_delete_A_int unsafe.Pointer - -func _swig_wrap_delete_A_int(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_A_int, _swig_p) - return -} - -func DeleteA_int(arg1 A_int) { - _swig_wrap_delete_A_int(arg1.Swigcptr()) -} - -type A_int interface { - Swigcptr() uintptr - SwigIsA_int() -} - -type SwigcptrB_int uintptr - -func (p SwigcptrB_int) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrB_int) SwigIsB_int() { -} - -var _wrap_B_int_say_hi__SWIG_0 unsafe.Pointer - -func _swig_wrap_B_int_say_hi__SWIG_0(base SwigcptrB_int, _ uint) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_B_int_say_hi__SWIG_0, _swig_p) - return -} - -func (arg1 SwigcptrB_int) Say_hi__SWIG_0(arg2 uint) { - _swig_wrap_B_int_say_hi__SWIG_0(arg1, arg2) -} - -var _wrap_B_int_say_hi__SWIG_1 unsafe.Pointer - -func _swig_wrap_B_int_say_hi__SWIG_1(base SwigcptrB_int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_B_int_say_hi__SWIG_1, _swig_p) - return -} - -func (arg1 SwigcptrB_int) Say_hi__SWIG_1() { - _swig_wrap_B_int_say_hi__SWIG_1(arg1) -} - -func (p SwigcptrB_int) Say_hi(a ...interface{}) { - argc := len(a) - if argc == 0 { - p.Say_hi__SWIG_1() - return - } - if argc == 1 { - p.Say_hi__SWIG_0(a[0].(uint)) - return - } - panic("No match for overloaded function call") -} - -var _wrap_new_B_int unsafe.Pointer - -func _swig_wrap_new_B_int() (base SwigcptrB_int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_B_int, _swig_p) - return -} - -func NewB_int() (_swig_ret B_int) { - return _swig_wrap_new_B_int() -} - -var _wrap_delete_B_int unsafe.Pointer - -func _swig_wrap_delete_B_int(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_B_int, _swig_p) - return -} - -func DeleteB_int(arg1 B_int) { - _swig_wrap_delete_B_int(arg1.Swigcptr()) -} - -func (p SwigcptrB_int) SwigIsA_int() { -} - -func (p SwigcptrB_int) SwigGetA_int() A_int { - return SwigcptrA_int(p.Swigcptr()) -} - -type B_int interface { - Swigcptr() uintptr - SwigIsB_int() - Say_hi(a ...interface{}) - SwigIsA_int() - SwigGetA_int() A_int -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/template_default_qualify.go b/Examples/test-suite/go/template_default_qualify.go deleted file mode 100644 index 067fd7e88..000000000 --- a/Examples/test-suite/go/template_default_qualify.go +++ /dev/null @@ -1,241 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../template_default_qualify.i - -package template_default_qualify - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type OssPolarization int -var _wrap_UnaryPolarization unsafe.Pointer - -func _swig_getUnaryPolarization() (_swig_ret OssPolarization) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_UnaryPolarization, _swig_p) - return -} -var UnaryPolarization OssPolarization = _swig_getUnaryPolarization() -var _wrap_BinaryPolarization unsafe.Pointer - -func _swig_getBinaryPolarization() (_swig_ret OssPolarization) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_BinaryPolarization, _swig_p) - return -} -var BinaryPolarization OssPolarization = _swig_getBinaryPolarization() -type SwigcptrEtraits uintptr - -func (p SwigcptrEtraits) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrEtraits) SwigIsEtraits() { -} - -var _wrap_etraits_pmode_etraits unsafe.Pointer - -func _swig_getetraits_etraits_pmode_etraits() (_swig_ret OssPolarization) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_etraits_pmode_etraits, _swig_p) - return -} -var EtraitsPmode OssPolarization = _swig_getetraits_etraits_pmode_etraits() -var _wrap_new_etraits unsafe.Pointer - -func _swig_wrap_new_etraits() (base SwigcptrEtraits) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_etraits, _swig_p) - return -} - -func NewEtraits() (_swig_ret Etraits) { - return _swig_wrap_new_etraits() -} - -var _wrap_delete_etraits unsafe.Pointer - -func _swig_wrap_delete_etraits(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_etraits, _swig_p) - return -} - -func DeleteEtraits(arg1 Etraits) { - _swig_wrap_delete_etraits(arg1.Swigcptr()) -} - -type Etraits interface { - Swigcptr() uintptr - SwigIsEtraits() -} - -type SwigcptrInterface_UP uintptr - -func (p SwigcptrInterface_UP) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrInterface_UP) SwigIsInterface_UP() { -} - -var _wrap_new_Interface_UP unsafe.Pointer - -func _swig_wrap_new_Interface_UP() (base SwigcptrInterface_UP) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Interface_UP, _swig_p) - return -} - -func NewInterface_UP() (_swig_ret Interface_UP) { - return _swig_wrap_new_Interface_UP() -} - -var _wrap_delete_Interface_UP unsafe.Pointer - -func _swig_wrap_delete_Interface_UP(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Interface_UP, _swig_p) - return -} - -func DeleteInterface_UP(arg1 Interface_UP) { - _swig_wrap_delete_Interface_UP(arg1.Swigcptr()) -} - -type Interface_UP interface { - Swigcptr() uintptr - SwigIsInterface_UP() -} - -type SwigcptrModule_etraits uintptr - -func (p SwigcptrModule_etraits) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrModule_etraits) SwigIsModule_etraits() { -} - -var _wrap_new_Module_etraits unsafe.Pointer - -func _swig_wrap_new_Module_etraits() (base SwigcptrModule_etraits) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Module_etraits, _swig_p) - return -} - -func NewModule_etraits() (_swig_ret Module_etraits) { - return _swig_wrap_new_Module_etraits() -} - -var _wrap_delete_Module_etraits unsafe.Pointer - -func _swig_wrap_delete_Module_etraits(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Module_etraits, _swig_p) - return -} - -func DeleteModule_etraits(arg1 Module_etraits) { - _swig_wrap_delete_Module_etraits(arg1.Swigcptr()) -} - -func (p SwigcptrModule_etraits) SwigIsInterface_UP() { -} - -func (p SwigcptrModule_etraits) SwigGetInterface_UP() Interface_UP { - return SwigcptrInterface_UP(p.Swigcptr()) -} - -type Module_etraits interface { - Swigcptr() uintptr - SwigIsModule_etraits() - SwigIsInterface_UP() - SwigGetInterface_UP() Interface_UP -} - -type SwigcptrHModule1 uintptr - -func (p SwigcptrHModule1) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrHModule1) SwigIsHModule1() { -} - -var _wrap_new_HModule1 unsafe.Pointer - -func _swig_wrap_new_HModule1() (base SwigcptrHModule1) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_HModule1, _swig_p) - return -} - -func NewHModule1() (_swig_ret HModule1) { - return _swig_wrap_new_HModule1() -} - -var _wrap_delete_HModule1 unsafe.Pointer - -func _swig_wrap_delete_HModule1(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_HModule1, _swig_p) - return -} - -func DeleteHModule1(arg1 HModule1) { - _swig_wrap_delete_HModule1(arg1.Swigcptr()) -} - -func (p SwigcptrHModule1) SwigIsModule_etraits() { -} - -func (p SwigcptrHModule1) SwigGetModule_etraits() Module_etraits { - return SwigcptrModule_etraits(p.Swigcptr()) -} - -func (p SwigcptrHModule1) SwigIsInterface_UP() { -} - -func (p SwigcptrHModule1) SwigGetInterface_UP() Interface_UP { - return SwigcptrInterface_UP(p.Swigcptr()) -} - -type HModule1 interface { - Swigcptr() uintptr - SwigIsHModule1() - SwigIsModule_etraits() - SwigGetModule_etraits() Module_etraits - SwigIsInterface_UP() - SwigGetInterface_UP() Interface_UP -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/template_default_vw.go b/Examples/test-suite/go/template_default_vw.go deleted file mode 100644 index 01c110ce4..000000000 --- a/Examples/test-suite/go/template_default_vw.go +++ /dev/null @@ -1,159 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../template_default_vw.i - -package template_default_vw - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrSomeClass uintptr - -func (p SwigcptrSomeClass) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrSomeClass) SwigIsSomeClass() { -} - -var _wrap_new_SomeClass unsafe.Pointer - -func _swig_wrap_new_SomeClass() (base SwigcptrSomeClass) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_SomeClass, _swig_p) - return -} - -func NewSomeClass() (_swig_ret SomeClass) { - return _swig_wrap_new_SomeClass() -} - -var _wrap_delete_SomeClass unsafe.Pointer - -func _swig_wrap_delete_SomeClass(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_SomeClass, _swig_p) - return -} - -func DeleteSomeClass(arg1 SomeClass) { - _swig_wrap_delete_SomeClass(arg1.Swigcptr()) -} - -type SomeClass interface { - Swigcptr() uintptr - SwigIsSomeClass() -} - -type SwigcptrAnotherClass uintptr - -func (p SwigcptrAnotherClass) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrAnotherClass) SwigIsAnotherClass() { -} - -var _wrap_AnotherClass_someFunc__SWIG_0 unsafe.Pointer - -func _swig_wrap_AnotherClass_someFunc__SWIG_0(base SwigcptrAnotherClass, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_AnotherClass_someFunc__SWIG_0, _swig_p) - return -} - -func (arg1 SwigcptrAnotherClass) SomeFunc__SWIG_0(arg2 Handle_Sl_SomeClass_Sg_) { - _swig_wrap_AnotherClass_someFunc__SWIG_0(arg1, arg2.Swigcptr()) -} - -var _wrap_AnotherClass_someFunc__SWIG_1 unsafe.Pointer - -func _swig_wrap_AnotherClass_someFunc__SWIG_1(base SwigcptrAnotherClass) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_AnotherClass_someFunc__SWIG_1, _swig_p) - return -} - -func (arg1 SwigcptrAnotherClass) SomeFunc__SWIG_1() { - _swig_wrap_AnotherClass_someFunc__SWIG_1(arg1) -} - -func (p SwigcptrAnotherClass) SomeFunc(a ...interface{}) { - argc := len(a) - if argc == 0 { - p.SomeFunc__SWIG_1() - return - } - if argc == 1 { - p.SomeFunc__SWIG_0(a[0].(Handle_Sl_SomeClass_Sg_)) - return - } - panic("No match for overloaded function call") -} - -var _wrap_new_AnotherClass unsafe.Pointer - -func _swig_wrap_new_AnotherClass() (base SwigcptrAnotherClass) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_AnotherClass, _swig_p) - return -} - -func NewAnotherClass() (_swig_ret AnotherClass) { - return _swig_wrap_new_AnotherClass() -} - -var _wrap_delete_AnotherClass unsafe.Pointer - -func _swig_wrap_delete_AnotherClass(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_AnotherClass, _swig_p) - return -} - -func DeleteAnotherClass(arg1 AnotherClass) { - _swig_wrap_delete_AnotherClass(arg1.Swigcptr()) -} - -type AnotherClass interface { - Swigcptr() uintptr - SwigIsAnotherClass() - SomeFunc(a ...interface{}) -} - - -type SwigcptrHandle_Sl_SomeClass_Sg_ uintptr -type Handle_Sl_SomeClass_Sg_ interface { - Swigcptr() uintptr; -} -func (p SwigcptrHandle_Sl_SomeClass_Sg_) Swigcptr() uintptr { - return uintptr(p) -} - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/template_enum.go b/Examples/test-suite/go/template_enum.go deleted file mode 100644 index 2fc607b4e..000000000 --- a/Examples/test-suite/go/template_enum.go +++ /dev/null @@ -1,263 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../template_enum.i - -package template_enum - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrFoo_i uintptr - -func (p SwigcptrFoo_i) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrFoo_i) SwigIsFoo_i() { -} - -var _wrap_FOO_foo_i unsafe.Pointer - -func _swig_getfoo_i_FOO_foo_i() (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_FOO_foo_i, _swig_p) - return -} -var Foo_iFOO int = _swig_getfoo_i_FOO_foo_i() -var _wrap_BAR_foo_i unsafe.Pointer - -func _swig_getfoo_i_BAR_foo_i() (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_BAR_foo_i, _swig_p) - return -} -var Foo_iBAR int = _swig_getfoo_i_BAR_foo_i() -var _wrap_new_foo_i unsafe.Pointer - -func _swig_wrap_new_foo_i() (base SwigcptrFoo_i) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_foo_i, _swig_p) - return -} - -func NewFoo_i() (_swig_ret Foo_i) { - return _swig_wrap_new_foo_i() -} - -var _wrap_delete_foo_i unsafe.Pointer - -func _swig_wrap_delete_foo_i(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_foo_i, _swig_p) - return -} - -func DeleteFoo_i(arg1 Foo_i) { - _swig_wrap_delete_foo_i(arg1.Swigcptr()) -} - -type Foo_i interface { - Swigcptr() uintptr - SwigIsFoo_i() -} - -type SwigcptrFoo_d uintptr - -func (p SwigcptrFoo_d) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrFoo_d) SwigIsFoo_d() { -} - -var _wrap_FOO_foo_d unsafe.Pointer - -func _swig_getfoo_d_FOO_foo_d() (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_FOO_foo_d, _swig_p) - return -} -var Foo_dFOO int = _swig_getfoo_d_FOO_foo_d() -var _wrap_BAR_foo_d unsafe.Pointer - -func _swig_getfoo_d_BAR_foo_d() (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_BAR_foo_d, _swig_p) - return -} -var Foo_dBAR int = _swig_getfoo_d_BAR_foo_d() -var _wrap_new_foo_d unsafe.Pointer - -func _swig_wrap_new_foo_d() (base SwigcptrFoo_d) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_foo_d, _swig_p) - return -} - -func NewFoo_d() (_swig_ret Foo_d) { - return _swig_wrap_new_foo_d() -} - -var _wrap_delete_foo_d unsafe.Pointer - -func _swig_wrap_delete_foo_d(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_foo_d, _swig_p) - return -} - -func DeleteFoo_d(arg1 Foo_d) { - _swig_wrap_delete_foo_d(arg1.Swigcptr()) -} - -type Foo_d interface { - Swigcptr() uintptr - SwigIsFoo_d() -} - -type SwigcptrRGBTraits uintptr - -func (p SwigcptrRGBTraits) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrRGBTraits) SwigIsRGBTraits() { -} - -var _wrap_NumComponents_RGBTraits unsafe.Pointer - -func _swig_getRGBTraits_NumComponents_RGBTraits() (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_NumComponents_RGBTraits, _swig_p) - return -} -var RGBTraitsNumComponents int = _swig_getRGBTraits_NumComponents_RGBTraits() -var _wrap_new_RGBTraits unsafe.Pointer - -func _swig_wrap_new_RGBTraits() (base SwigcptrRGBTraits) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_RGBTraits, _swig_p) - return -} - -func NewRGBTraits() (_swig_ret RGBTraits) { - return _swig_wrap_new_RGBTraits() -} - -var _wrap_delete_RGBTraits unsafe.Pointer - -func _swig_wrap_delete_RGBTraits(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_RGBTraits, _swig_p) - return -} - -func DeleteRGBTraits(arg1 RGBTraits) { - _swig_wrap_delete_RGBTraits(arg1.Swigcptr()) -} - -type RGBTraits interface { - Swigcptr() uintptr - SwigIsRGBTraits() -} - -type SwigcptrColor uintptr - -func (p SwigcptrColor) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrColor) SwigIsColor() { -} - -var _wrap_NumComponents_Color unsafe.Pointer - -func _swig_getColor_NumComponents_Color() (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_NumComponents_Color, _swig_p) - return -} -var ColorNumComponents int = _swig_getColor_NumComponents_Color() -var _wrap_Color_data_set unsafe.Pointer - -func _swig_wrap_Color_data_set(base SwigcptrColor, _ *float32) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Color_data_set, _swig_p) - return -} - -func (arg1 SwigcptrColor) SetData(arg2 *float32) { - _swig_wrap_Color_data_set(arg1, arg2) -} - -var _wrap_Color_data_get unsafe.Pointer - -func _swig_wrap_Color_data_get(base SwigcptrColor) (_ *float32) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Color_data_get, _swig_p) - return -} - -func (arg1 SwigcptrColor) GetData() (_swig_ret *float32) { - return _swig_wrap_Color_data_get(arg1) -} - -var _wrap_new_Color unsafe.Pointer - -func _swig_wrap_new_Color() (base SwigcptrColor) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Color, _swig_p) - return -} - -func NewColor() (_swig_ret Color) { - return _swig_wrap_new_Color() -} - -var _wrap_delete_Color unsafe.Pointer - -func _swig_wrap_delete_Color(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Color, _swig_p) - return -} - -func DeleteColor(arg1 Color) { - _swig_wrap_delete_Color(arg1.Swigcptr()) -} - -type Color interface { - Swigcptr() uintptr - SwigIsColor() - SetData(arg2 *float32) - GetData() (_swig_ret *float32) -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/template_enum_ns_inherit.go b/Examples/test-suite/go/template_enum_ns_inherit.go deleted file mode 100644 index ddb617e92..000000000 --- a/Examples/test-suite/go/template_enum_ns_inherit.go +++ /dev/null @@ -1,271 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../template_enum_ns_inherit.i - -package template_enum_ns_inherit - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type OssPolarization int -var _wrap_UnaryPolarization unsafe.Pointer - -func _swig_getUnaryPolarization() (_swig_ret OssPolarization) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_UnaryPolarization, _swig_p) - return -} -var UnaryPolarization OssPolarization = _swig_getUnaryPolarization() -var _wrap_BinaryPolarization unsafe.Pointer - -func _swig_getBinaryPolarization() (_swig_ret OssPolarization) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_BinaryPolarization, _swig_p) - return -} -var BinaryPolarization OssPolarization = _swig_getBinaryPolarization() -type SwigcptrInterface_UP uintptr - -func (p SwigcptrInterface_UP) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrInterface_UP) SwigIsInterface_UP() { -} - -var _wrap_new_Interface_UP unsafe.Pointer - -func _swig_wrap_new_Interface_UP() (base SwigcptrInterface_UP) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Interface_UP, _swig_p) - return -} - -func NewInterface_UP() (_swig_ret Interface_UP) { - return _swig_wrap_new_Interface_UP() -} - -var _wrap_delete_Interface_UP unsafe.Pointer - -func _swig_wrap_delete_Interface_UP(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Interface_UP, _swig_p) - return -} - -func DeleteInterface_UP(arg1 Interface_UP) { - _swig_wrap_delete_Interface_UP(arg1.Swigcptr()) -} - -type Interface_UP interface { - Swigcptr() uintptr - SwigIsInterface_UP() -} - -type SwigcptrModule_UPIUP uintptr - -func (p SwigcptrModule_UPIUP) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrModule_UPIUP) SwigIsModule_UPIUP() { -} - -var _wrap_new_Module_UPIUP unsafe.Pointer - -func _swig_wrap_new_Module_UPIUP() (base SwigcptrModule_UPIUP) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Module_UPIUP, _swig_p) - return -} - -func NewModule_UPIUP() (_swig_ret Module_UPIUP) { - return _swig_wrap_new_Module_UPIUP() -} - -var _wrap_delete_Module_UPIUP unsafe.Pointer - -func _swig_wrap_delete_Module_UPIUP(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Module_UPIUP, _swig_p) - return -} - -func DeleteModule_UPIUP(arg1 Module_UPIUP) { - _swig_wrap_delete_Module_UPIUP(arg1.Swigcptr()) -} - -type Module_UPIUP interface { - Swigcptr() uintptr - SwigIsModule_UPIUP() -} - -type SwigcptrHInterface1 uintptr - -func (p SwigcptrHInterface1) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrHInterface1) SwigIsHInterface1() { -} - -var _wrap_new_HInterface1 unsafe.Pointer - -func _swig_wrap_new_HInterface1() (base SwigcptrHInterface1) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_HInterface1, _swig_p) - return -} - -func NewHInterface1() (_swig_ret HInterface1) { - return _swig_wrap_new_HInterface1() -} - -var _wrap_delete_HInterface1 unsafe.Pointer - -func _swig_wrap_delete_HInterface1(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_HInterface1, _swig_p) - return -} - -func DeleteHInterface1(arg1 HInterface1) { - _swig_wrap_delete_HInterface1(arg1.Swigcptr()) -} - -func (p SwigcptrHInterface1) SwigIsInterface_UP() { -} - -func (p SwigcptrHInterface1) SwigGetInterface_UP() Interface_UP { - return SwigcptrInterface_UP(p.Swigcptr()) -} - -type HInterface1 interface { - Swigcptr() uintptr - SwigIsHInterface1() - SwigIsInterface_UP() - SwigGetInterface_UP() Interface_UP -} - -type SwigcptrHInterface2 uintptr - -func (p SwigcptrHInterface2) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrHInterface2) SwigIsHInterface2() { -} - -var _wrap_new_HInterface2 unsafe.Pointer - -func _swig_wrap_new_HInterface2() (base SwigcptrHInterface2) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_HInterface2, _swig_p) - return -} - -func NewHInterface2() (_swig_ret HInterface2) { - return _swig_wrap_new_HInterface2() -} - -var _wrap_delete_HInterface2 unsafe.Pointer - -func _swig_wrap_delete_HInterface2(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_HInterface2, _swig_p) - return -} - -func DeleteHInterface2(arg1 HInterface2) { - _swig_wrap_delete_HInterface2(arg1.Swigcptr()) -} - -func (p SwigcptrHInterface2) SwigIsInterface_UP() { -} - -func (p SwigcptrHInterface2) SwigGetInterface_UP() Interface_UP { - return SwigcptrInterface_UP(p.Swigcptr()) -} - -type HInterface2 interface { - Swigcptr() uintptr - SwigIsHInterface2() - SwigIsInterface_UP() - SwigGetInterface_UP() Interface_UP -} - -type SwigcptrHModule1 uintptr - -func (p SwigcptrHModule1) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrHModule1) SwigIsHModule1() { -} - -var _wrap_new_HModule1 unsafe.Pointer - -func _swig_wrap_new_HModule1() (base SwigcptrHModule1) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_HModule1, _swig_p) - return -} - -func NewHModule1() (_swig_ret HModule1) { - return _swig_wrap_new_HModule1() -} - -var _wrap_delete_HModule1 unsafe.Pointer - -func _swig_wrap_delete_HModule1(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_HModule1, _swig_p) - return -} - -func DeleteHModule1(arg1 HModule1) { - _swig_wrap_delete_HModule1(arg1.Swigcptr()) -} - -func (p SwigcptrHModule1) SwigIsModule_UPIUP() { -} - -func (p SwigcptrHModule1) SwigGetModule_UPIUP() Module_UPIUP { - return SwigcptrModule_UPIUP(p.Swigcptr()) -} - -type HModule1 interface { - Swigcptr() uintptr - SwigIsHModule1() - SwigIsModule_UPIUP() - SwigGetModule_UPIUP() Module_UPIUP -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/template_enum_typedef.go b/Examples/test-suite/go/template_enum_typedef.go deleted file mode 100644 index 9a6ed25cd..000000000 --- a/Examples/test-suite/go/template_enum_typedef.go +++ /dev/null @@ -1,197 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../template_enum_typedef.i - -package template_enum_typedef - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type OssPolarization int -var _wrap_UnaryPolarization unsafe.Pointer - -func _swig_getUnaryPolarization() (_swig_ret OssPolarization) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_UnaryPolarization, _swig_p) - return -} -var UnaryPolarization OssPolarization = _swig_getUnaryPolarization() -var _wrap_BinaryPolarization unsafe.Pointer - -func _swig_getBinaryPolarization() (_swig_ret OssPolarization) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_BinaryPolarization, _swig_p) - return -} -var BinaryPolarization OssPolarization = _swig_getBinaryPolarization() -type SwigcptrEtraits uintptr - -func (p SwigcptrEtraits) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrEtraits) SwigIsEtraits() { -} - -var _wrap_etraits_pmode_etraits unsafe.Pointer - -func _swig_getetraits_etraits_pmode_etraits() (_swig_ret OssPolarization) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_etraits_pmode_etraits, _swig_p) - return -} -var EtraitsPmode OssPolarization = _swig_getetraits_etraits_pmode_etraits() -var _wrap_new_etraits unsafe.Pointer - -func _swig_wrap_new_etraits() (base SwigcptrEtraits) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_etraits, _swig_p) - return -} - -func NewEtraits() (_swig_ret Etraits) { - return _swig_wrap_new_etraits() -} - -var _wrap_delete_etraits unsafe.Pointer - -func _swig_wrap_delete_etraits(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_etraits, _swig_p) - return -} - -func DeleteEtraits(arg1 Etraits) { - _swig_wrap_delete_etraits(arg1.Swigcptr()) -} - -type Etraits interface { - Swigcptr() uintptr - SwigIsEtraits() -} - -type SwigcptrInterface_UP uintptr - -func (p SwigcptrInterface_UP) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrInterface_UP) SwigIsInterface_UP() { -} - -var _wrap_new_Interface_UP unsafe.Pointer - -func _swig_wrap_new_Interface_UP() (base SwigcptrInterface_UP) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Interface_UP, _swig_p) - return -} - -func NewInterface_UP() (_swig_ret Interface_UP) { - return _swig_wrap_new_Interface_UP() -} - -var _wrap_delete_Interface_UP unsafe.Pointer - -func _swig_wrap_delete_Interface_UP(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Interface_UP, _swig_p) - return -} - -func DeleteInterface_UP(arg1 Interface_UP) { - _swig_wrap_delete_Interface_UP(arg1.Swigcptr()) -} - -type Interface_UP interface { - Swigcptr() uintptr - SwigIsInterface_UP() -} - -type SwigcptrModule_UP uintptr - -func (p SwigcptrModule_UP) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrModule_UP) SwigIsModule_UP() { -} - -var _wrap_Module_UP_P_Module_UP unsafe.Pointer - -func _swig_getModule_UP_Module_UP_P_Module_UP() (_swig_ret OssPolarization) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_Module_UP_P_Module_UP, _swig_p) - return -} -var Module_UPP OssPolarization = _swig_getModule_UP_Module_UP_P_Module_UP() -var _wrap_Module_UP_get unsafe.Pointer - -func _swig_wrap_Module_UP_get(base SwigcptrModule_UP, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Module_UP_get, _swig_p) - return -} - -func (arg1 SwigcptrModule_UP) Get(arg2 Interface_UP) { - _swig_wrap_Module_UP_get(arg1, arg2.Swigcptr()) -} - -var _wrap_new_Module_UP unsafe.Pointer - -func _swig_wrap_new_Module_UP() (base SwigcptrModule_UP) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Module_UP, _swig_p) - return -} - -func NewModule_UP() (_swig_ret Module_UP) { - return _swig_wrap_new_Module_UP() -} - -var _wrap_delete_Module_UP unsafe.Pointer - -func _swig_wrap_delete_Module_UP(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Module_UP, _swig_p) - return -} - -func DeleteModule_UP(arg1 Module_UP) { - _swig_wrap_delete_Module_UP(arg1.Swigcptr()) -} - -type Module_UP interface { - Swigcptr() uintptr - SwigIsModule_UP() - Get(arg2 Interface_UP) -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/template_explicit.go b/Examples/test-suite/go/template_explicit.go deleted file mode 100644 index 69f91688e..000000000 --- a/Examples/test-suite/go/template_explicit.go +++ /dev/null @@ -1,289 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../template_explicit.i - -package template_explicit - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -var _wrap_maxint unsafe.Pointer - -func Maxint(arg1 int, arg2 int) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_maxint, _swig_p) - return -} -var _wrap_maxdouble unsafe.Pointer - -func Maxdouble(arg1 float64, arg2 float64) (_swig_ret float64) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_maxdouble, _swig_p) - return -} -type SwigcptrVecint uintptr - -func (p SwigcptrVecint) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrVecint) SwigIsVecint() { -} - -var _wrap_new_vecint unsafe.Pointer - -func _swig_wrap_new_vecint(base int) (_ SwigcptrVecint) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_vecint, _swig_p) - return -} - -func NewVecint(arg1 int) (_swig_ret Vecint) { - return _swig_wrap_new_vecint(arg1) -} - -var _wrap_vecint_get unsafe.Pointer - -func _swig_wrap_vecint_get(base SwigcptrVecint, _ int) (_ *int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_vecint_get, _swig_p) - return -} - -func (arg1 SwigcptrVecint) Get(arg2 int) (_swig_ret *int) { - return _swig_wrap_vecint_get(arg1, arg2) -} - -var _wrap_vecint_set unsafe.Pointer - -func _swig_wrap_vecint_set(base SwigcptrVecint, _ int, _ *int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_vecint_set, _swig_p) - return -} - -func (arg1 SwigcptrVecint) Set(arg2 int, arg3 *int) { - _swig_wrap_vecint_set(arg1, arg2, arg3) -} - -var _wrap_vecint_testconst unsafe.Pointer - -func _swig_wrap_vecint_testconst(base SwigcptrVecint, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_vecint_testconst, _swig_p) - return -} - -func (arg1 SwigcptrVecint) Testconst(arg2 int) { - _swig_wrap_vecint_testconst(arg1, arg2) -} - -var _wrap_delete_vecint unsafe.Pointer - -func _swig_wrap_delete_vecint(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_vecint, _swig_p) - return -} - -func DeleteVecint(arg1 Vecint) { - _swig_wrap_delete_vecint(arg1.Swigcptr()) -} - -type Vecint interface { - Swigcptr() uintptr - SwigIsVecint() - Get(arg2 int) (_swig_ret *int) - Set(arg2 int, arg3 *int) - Testconst(arg2 int) -} - -type SwigcptrVecdouble uintptr - -func (p SwigcptrVecdouble) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrVecdouble) SwigIsVecdouble() { -} - -var _wrap_new_vecdouble unsafe.Pointer - -func _swig_wrap_new_vecdouble(base int) (_ SwigcptrVecdouble) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_vecdouble, _swig_p) - return -} - -func NewVecdouble(arg1 int) (_swig_ret Vecdouble) { - return _swig_wrap_new_vecdouble(arg1) -} - -var _wrap_vecdouble_get unsafe.Pointer - -func _swig_wrap_vecdouble_get(base SwigcptrVecdouble, _ int) (_ *float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_vecdouble_get, _swig_p) - return -} - -func (arg1 SwigcptrVecdouble) Get(arg2 int) (_swig_ret *float64) { - return _swig_wrap_vecdouble_get(arg1, arg2) -} - -var _wrap_vecdouble_set unsafe.Pointer - -func _swig_wrap_vecdouble_set(base SwigcptrVecdouble, _ int, _ *float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_vecdouble_set, _swig_p) - return -} - -func (arg1 SwigcptrVecdouble) Set(arg2 int, arg3 *float64) { - _swig_wrap_vecdouble_set(arg1, arg2, arg3) -} - -var _wrap_vecdouble_testconst unsafe.Pointer - -func _swig_wrap_vecdouble_testconst(base SwigcptrVecdouble, _ float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_vecdouble_testconst, _swig_p) - return -} - -func (arg1 SwigcptrVecdouble) Testconst(arg2 float64) { - _swig_wrap_vecdouble_testconst(arg1, arg2) -} - -var _wrap_delete_vecdouble unsafe.Pointer - -func _swig_wrap_delete_vecdouble(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_vecdouble, _swig_p) - return -} - -func DeleteVecdouble(arg1 Vecdouble) { - _swig_wrap_delete_vecdouble(arg1.Swigcptr()) -} - -type Vecdouble interface { - Swigcptr() uintptr - SwigIsVecdouble() - Get(arg2 int) (_swig_ret *float64) - Set(arg2 int, arg3 *float64) - Testconst(arg2 float64) -} - -var _wrap_maxintp unsafe.Pointer - -func Maxintp(arg1 **int, arg2 **int) (_swig_ret **int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_maxintp, _swig_p) - return -} -type SwigcptrVecintp uintptr - -func (p SwigcptrVecintp) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrVecintp) SwigIsVecintp() { -} - -var _wrap_new_vecintp unsafe.Pointer - -func _swig_wrap_new_vecintp(base int) (_ SwigcptrVecintp) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_vecintp, _swig_p) - return -} - -func NewVecintp(arg1 int) (_swig_ret Vecintp) { - return _swig_wrap_new_vecintp(arg1) -} - -var _wrap_vecintp_get unsafe.Pointer - -func _swig_wrap_vecintp_get(base SwigcptrVecintp, _ int) (_ ***int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_vecintp_get, _swig_p) - return -} - -func (arg1 SwigcptrVecintp) Get(arg2 int) (_swig_ret ***int) { - return _swig_wrap_vecintp_get(arg1, arg2) -} - -var _wrap_vecintp_set unsafe.Pointer - -func _swig_wrap_vecintp_set(base SwigcptrVecintp, _ int, _ ***int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_vecintp_set, _swig_p) - return -} - -func (arg1 SwigcptrVecintp) Set(arg2 int, arg3 ***int) { - _swig_wrap_vecintp_set(arg1, arg2, arg3) -} - -var _wrap_vecintp_testconst unsafe.Pointer - -func _swig_wrap_vecintp_testconst(base SwigcptrVecintp, _ **int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_vecintp_testconst, _swig_p) - return -} - -func (arg1 SwigcptrVecintp) Testconst(arg2 **int) { - _swig_wrap_vecintp_testconst(arg1, arg2) -} - -var _wrap_delete_vecintp unsafe.Pointer - -func _swig_wrap_delete_vecintp(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_vecintp, _swig_p) - return -} - -func DeleteVecintp(arg1 Vecintp) { - _swig_wrap_delete_vecintp(arg1.Swigcptr()) -} - -type Vecintp interface { - Swigcptr() uintptr - SwigIsVecintp() - Get(arg2 int) (_swig_ret ***int) - Set(arg2 int, arg3 ***int) - Testconst(arg2 **int) -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/template_extend1.go b/Examples/test-suite/go/template_extend1.go deleted file mode 100644 index 7990a6b76..000000000 --- a/Examples/test-suite/go/template_extend1.go +++ /dev/null @@ -1,139 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../template_extend1.i - -package template_extend1 - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrLBaz uintptr - -func (p SwigcptrLBaz) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrLBaz) SwigIsLBaz() { -} - -var _wrap_lBaz_foo unsafe.Pointer - -func _swig_wrap_lBaz_foo(base SwigcptrLBaz) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_lBaz_foo, _swig_p) - return -} - -func (arg1 SwigcptrLBaz) Foo() (_swig_ret string) { - return _swig_wrap_lBaz_foo(arg1) -} - -var _wrap_new_lBaz unsafe.Pointer - -func _swig_wrap_new_lBaz() (base SwigcptrLBaz) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_lBaz, _swig_p) - return -} - -func NewLBaz() (_swig_ret LBaz) { - return _swig_wrap_new_lBaz() -} - -var _wrap_delete_lBaz unsafe.Pointer - -func _swig_wrap_delete_lBaz(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_lBaz, _swig_p) - return -} - -func DeleteLBaz(arg1 LBaz) { - _swig_wrap_delete_lBaz(arg1.Swigcptr()) -} - -type LBaz interface { - Swigcptr() uintptr - SwigIsLBaz() - Foo() (_swig_ret string) -} - -type SwigcptrDBaz uintptr - -func (p SwigcptrDBaz) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrDBaz) SwigIsDBaz() { -} - -var _wrap_dBaz_foo unsafe.Pointer - -func _swig_wrap_dBaz_foo(base SwigcptrDBaz) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_dBaz_foo, _swig_p) - return -} - -func (arg1 SwigcptrDBaz) Foo() (_swig_ret string) { - return _swig_wrap_dBaz_foo(arg1) -} - -var _wrap_new_dBaz unsafe.Pointer - -func _swig_wrap_new_dBaz() (base SwigcptrDBaz) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_dBaz, _swig_p) - return -} - -func NewDBaz() (_swig_ret DBaz) { - return _swig_wrap_new_dBaz() -} - -var _wrap_delete_dBaz unsafe.Pointer - -func _swig_wrap_delete_dBaz(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_dBaz, _swig_p) - return -} - -func DeleteDBaz(arg1 DBaz) { - _swig_wrap_delete_dBaz(arg1.Swigcptr()) -} - -type DBaz interface { - Swigcptr() uintptr - SwigIsDBaz() - Foo() (_swig_ret string) -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/template_extend1_runme b/Examples/test-suite/go/template_extend1_runme deleted file mode 100755 index c14e341b9..000000000 Binary files a/Examples/test-suite/go/template_extend1_runme and /dev/null differ diff --git a/Examples/test-suite/go/template_extend2.go b/Examples/test-suite/go/template_extend2.go deleted file mode 100644 index 9e7f8fa4e..000000000 --- a/Examples/test-suite/go/template_extend2.go +++ /dev/null @@ -1,139 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../template_extend2.i - -package template_extend2 - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrLBaz uintptr - -func (p SwigcptrLBaz) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrLBaz) SwigIsLBaz() { -} - -var _wrap_lBaz_foo unsafe.Pointer - -func _swig_wrap_lBaz_foo(base SwigcptrLBaz) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_lBaz_foo, _swig_p) - return -} - -func (arg1 SwigcptrLBaz) Foo() (_swig_ret string) { - return _swig_wrap_lBaz_foo(arg1) -} - -var _wrap_new_lBaz unsafe.Pointer - -func _swig_wrap_new_lBaz() (base SwigcptrLBaz) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_lBaz, _swig_p) - return -} - -func NewLBaz() (_swig_ret LBaz) { - return _swig_wrap_new_lBaz() -} - -var _wrap_delete_lBaz unsafe.Pointer - -func _swig_wrap_delete_lBaz(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_lBaz, _swig_p) - return -} - -func DeleteLBaz(arg1 LBaz) { - _swig_wrap_delete_lBaz(arg1.Swigcptr()) -} - -type LBaz interface { - Swigcptr() uintptr - SwigIsLBaz() - Foo() (_swig_ret string) -} - -type SwigcptrDBaz uintptr - -func (p SwigcptrDBaz) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrDBaz) SwigIsDBaz() { -} - -var _wrap_dBaz_foo unsafe.Pointer - -func _swig_wrap_dBaz_foo(base SwigcptrDBaz) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_dBaz_foo, _swig_p) - return -} - -func (arg1 SwigcptrDBaz) Foo() (_swig_ret string) { - return _swig_wrap_dBaz_foo(arg1) -} - -var _wrap_new_dBaz unsafe.Pointer - -func _swig_wrap_new_dBaz() (base SwigcptrDBaz) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_dBaz, _swig_p) - return -} - -func NewDBaz() (_swig_ret DBaz) { - return _swig_wrap_new_dBaz() -} - -var _wrap_delete_dBaz unsafe.Pointer - -func _swig_wrap_delete_dBaz(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_dBaz, _swig_p) - return -} - -func DeleteDBaz(arg1 DBaz) { - _swig_wrap_delete_dBaz(arg1.Swigcptr()) -} - -type DBaz interface { - Swigcptr() uintptr - SwigIsDBaz() - Foo() (_swig_ret string) -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/template_extend2_runme b/Examples/test-suite/go/template_extend2_runme deleted file mode 100755 index 6808440b7..000000000 Binary files a/Examples/test-suite/go/template_extend2_runme and /dev/null differ diff --git a/Examples/test-suite/go/template_extend_overload.go b/Examples/test-suite/go/template_extend_overload.go deleted file mode 100644 index bb4712470..000000000 --- a/Examples/test-suite/go/template_extend_overload.go +++ /dev/null @@ -1,400 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../template_extend_overload.i - -package template_extend_overload - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrA_double uintptr - -func (p SwigcptrA_double) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrA_double) SwigIsA_double() { -} - -var _wrap_A_double_compose__SWIG_0 unsafe.Pointer - -func _swig_wrap_A_double_compose__SWIG_0(base SwigcptrA_double, _ uintptr) (_ SwigcptrA_bool) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_A_double_compose__SWIG_0, _swig_p) - return -} - -func (arg1 SwigcptrA_double) Compose__SWIG_0(arg2 B_Sl_double_Sc_bool_Sg_) (_swig_ret A_bool) { - return _swig_wrap_A_double_compose__SWIG_0(arg1, arg2.Swigcptr()) -} - -var _wrap_A_double_compose__SWIG_1 unsafe.Pointer - -func _swig_wrap_A_double_compose__SWIG_1(base SwigcptrA_double, _ uintptr) (_ SwigcptrA_double) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_A_double_compose__SWIG_1, _swig_p) - return -} - -func (arg1 SwigcptrA_double) Compose__SWIG_1(arg2 B_Sl_double_Sc_double_Sg_) (_swig_ret A_double) { - return _swig_wrap_A_double_compose__SWIG_1(arg1, arg2.Swigcptr()) -} - -var _wrap_A_double_compose__SWIG_2 unsafe.Pointer - -func _swig_wrap_A_double_compose__SWIG_2(base SwigcptrA_double, _ uintptr) (_ SwigcptrA_int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_A_double_compose__SWIG_2, _swig_p) - return -} - -func (arg1 SwigcptrA_double) Compose__SWIG_2(arg2 B_Sl_double_Sc_int_Sg_) (_swig_ret A_int) { - return _swig_wrap_A_double_compose__SWIG_2(arg1, arg2.Swigcptr()) -} - -func (p SwigcptrA_double) Compose(a ...interface{}) interface{} { - argc := len(a) - if argc == 1 { - if _, ok := a[0].(B_Sl_double_Sc_bool_Sg_); !ok { - goto check_1 - } - return p.Compose__SWIG_0(a[0].(B_Sl_double_Sc_bool_Sg_)) - } -check_1: - if argc == 1 { - if _, ok := a[0].(B_Sl_double_Sc_double_Sg_); !ok { - goto check_2 - } - return p.Compose__SWIG_1(a[0].(B_Sl_double_Sc_double_Sg_)) - } -check_2: - if argc == 1 { - return p.Compose__SWIG_2(a[0].(B_Sl_double_Sc_int_Sg_)) - } - panic("No match for overloaded function call") -} - -var _wrap_new_A_double unsafe.Pointer - -func _swig_wrap_new_A_double() (base SwigcptrA_double) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_A_double, _swig_p) - return -} - -func NewA_double() (_swig_ret A_double) { - return _swig_wrap_new_A_double() -} - -var _wrap_delete_A_double unsafe.Pointer - -func _swig_wrap_delete_A_double(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_A_double, _swig_p) - return -} - -func DeleteA_double(arg1 A_double) { - _swig_wrap_delete_A_double(arg1.Swigcptr()) -} - -type A_double interface { - Swigcptr() uintptr - SwigIsA_double() - Compose(a ...interface{}) interface{} -} - -type SwigcptrA_int uintptr - -func (p SwigcptrA_int) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrA_int) SwigIsA_int() { -} - -var _wrap_A_int_compose__SWIG_0 unsafe.Pointer - -func _swig_wrap_A_int_compose__SWIG_0(base SwigcptrA_int, _ uintptr) (_ SwigcptrA_bool) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_A_int_compose__SWIG_0, _swig_p) - return -} - -func (arg1 SwigcptrA_int) Compose__SWIG_0(arg2 B_Sl_int_Sc_bool_Sg_) (_swig_ret A_bool) { - return _swig_wrap_A_int_compose__SWIG_0(arg1, arg2.Swigcptr()) -} - -var _wrap_A_int_compose__SWIG_1 unsafe.Pointer - -func _swig_wrap_A_int_compose__SWIG_1(base SwigcptrA_int, _ uintptr) (_ SwigcptrA_double) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_A_int_compose__SWIG_1, _swig_p) - return -} - -func (arg1 SwigcptrA_int) Compose__SWIG_1(arg2 B_Sl_int_Sc_double_Sg_) (_swig_ret A_double) { - return _swig_wrap_A_int_compose__SWIG_1(arg1, arg2.Swigcptr()) -} - -var _wrap_A_int_compose__SWIG_2 unsafe.Pointer - -func _swig_wrap_A_int_compose__SWIG_2(base SwigcptrA_int, _ uintptr) (_ SwigcptrA_int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_A_int_compose__SWIG_2, _swig_p) - return -} - -func (arg1 SwigcptrA_int) Compose__SWIG_2(arg2 B_Sl_int_Sc_int_Sg_) (_swig_ret A_int) { - return _swig_wrap_A_int_compose__SWIG_2(arg1, arg2.Swigcptr()) -} - -func (p SwigcptrA_int) Compose(a ...interface{}) interface{} { - argc := len(a) - if argc == 1 { - if _, ok := a[0].(B_Sl_int_Sc_bool_Sg_); !ok { - goto check_1 - } - return p.Compose__SWIG_0(a[0].(B_Sl_int_Sc_bool_Sg_)) - } -check_1: - if argc == 1 { - if _, ok := a[0].(B_Sl_int_Sc_double_Sg_); !ok { - goto check_2 - } - return p.Compose__SWIG_1(a[0].(B_Sl_int_Sc_double_Sg_)) - } -check_2: - if argc == 1 { - return p.Compose__SWIG_2(a[0].(B_Sl_int_Sc_int_Sg_)) - } - panic("No match for overloaded function call") -} - -var _wrap_new_A_int unsafe.Pointer - -func _swig_wrap_new_A_int() (base SwigcptrA_int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_A_int, _swig_p) - return -} - -func NewA_int() (_swig_ret A_int) { - return _swig_wrap_new_A_int() -} - -var _wrap_delete_A_int unsafe.Pointer - -func _swig_wrap_delete_A_int(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_A_int, _swig_p) - return -} - -func DeleteA_int(arg1 A_int) { - _swig_wrap_delete_A_int(arg1.Swigcptr()) -} - -type A_int interface { - Swigcptr() uintptr - SwigIsA_int() - Compose(a ...interface{}) interface{} -} - -type SwigcptrA_bool uintptr - -func (p SwigcptrA_bool) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrA_bool) SwigIsA_bool() { -} - -var _wrap_A_bool_compose__SWIG_0 unsafe.Pointer - -func _swig_wrap_A_bool_compose__SWIG_0(base SwigcptrA_bool, _ uintptr) (_ SwigcptrA_bool) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_A_bool_compose__SWIG_0, _swig_p) - return -} - -func (arg1 SwigcptrA_bool) Compose__SWIG_0(arg2 B_Sl_bool_Sc_bool_Sg_) (_swig_ret A_bool) { - return _swig_wrap_A_bool_compose__SWIG_0(arg1, arg2.Swigcptr()) -} - -var _wrap_A_bool_compose__SWIG_1 unsafe.Pointer - -func _swig_wrap_A_bool_compose__SWIG_1(base SwigcptrA_bool, _ uintptr) (_ SwigcptrA_double) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_A_bool_compose__SWIG_1, _swig_p) - return -} - -func (arg1 SwigcptrA_bool) Compose__SWIG_1(arg2 B_Sl_bool_Sc_double_Sg_) (_swig_ret A_double) { - return _swig_wrap_A_bool_compose__SWIG_1(arg1, arg2.Swigcptr()) -} - -var _wrap_A_bool_compose__SWIG_2 unsafe.Pointer - -func _swig_wrap_A_bool_compose__SWIG_2(base SwigcptrA_bool, _ uintptr) (_ SwigcptrA_int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_A_bool_compose__SWIG_2, _swig_p) - return -} - -func (arg1 SwigcptrA_bool) Compose__SWIG_2(arg2 B_Sl_bool_Sc_int_Sg_) (_swig_ret A_int) { - return _swig_wrap_A_bool_compose__SWIG_2(arg1, arg2.Swigcptr()) -} - -func (p SwigcptrA_bool) Compose(a ...interface{}) interface{} { - argc := len(a) - if argc == 1 { - if _, ok := a[0].(B_Sl_bool_Sc_bool_Sg_); !ok { - goto check_1 - } - return p.Compose__SWIG_0(a[0].(B_Sl_bool_Sc_bool_Sg_)) - } -check_1: - if argc == 1 { - if _, ok := a[0].(B_Sl_bool_Sc_double_Sg_); !ok { - goto check_2 - } - return p.Compose__SWIG_1(a[0].(B_Sl_bool_Sc_double_Sg_)) - } -check_2: - if argc == 1 { - return p.Compose__SWIG_2(a[0].(B_Sl_bool_Sc_int_Sg_)) - } - panic("No match for overloaded function call") -} - -var _wrap_new_A_bool unsafe.Pointer - -func _swig_wrap_new_A_bool() (base SwigcptrA_bool) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_A_bool, _swig_p) - return -} - -func NewA_bool() (_swig_ret A_bool) { - return _swig_wrap_new_A_bool() -} - -var _wrap_delete_A_bool unsafe.Pointer - -func _swig_wrap_delete_A_bool(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_A_bool, _swig_p) - return -} - -func DeleteA_bool(arg1 A_bool) { - _swig_wrap_delete_A_bool(arg1.Swigcptr()) -} - -type A_bool interface { - Swigcptr() uintptr - SwigIsA_bool() - Compose(a ...interface{}) interface{} -} - - -type SwigcptrB_Sl_double_Sc_bool_Sg_ uintptr -type B_Sl_double_Sc_bool_Sg_ interface { - Swigcptr() uintptr; -} -func (p SwigcptrB_Sl_double_Sc_bool_Sg_) Swigcptr() uintptr { - return uintptr(p) -} - -type SwigcptrB_Sl_int_Sc_bool_Sg_ uintptr -type B_Sl_int_Sc_bool_Sg_ interface { - Swigcptr() uintptr; -} -func (p SwigcptrB_Sl_int_Sc_bool_Sg_) Swigcptr() uintptr { - return uintptr(p) -} - -type SwigcptrB_Sl_bool_Sc_bool_Sg_ uintptr -type B_Sl_bool_Sc_bool_Sg_ interface { - Swigcptr() uintptr; -} -func (p SwigcptrB_Sl_bool_Sc_bool_Sg_) Swigcptr() uintptr { - return uintptr(p) -} - -type SwigcptrB_Sl_double_Sc_double_Sg_ uintptr -type B_Sl_double_Sc_double_Sg_ interface { - Swigcptr() uintptr; -} -func (p SwigcptrB_Sl_double_Sc_double_Sg_) Swigcptr() uintptr { - return uintptr(p) -} - -type SwigcptrB_Sl_double_Sc_int_Sg_ uintptr -type B_Sl_double_Sc_int_Sg_ interface { - Swigcptr() uintptr; -} -func (p SwigcptrB_Sl_double_Sc_int_Sg_) Swigcptr() uintptr { - return uintptr(p) -} - -type SwigcptrB_Sl_int_Sc_double_Sg_ uintptr -type B_Sl_int_Sc_double_Sg_ interface { - Swigcptr() uintptr; -} -func (p SwigcptrB_Sl_int_Sc_double_Sg_) Swigcptr() uintptr { - return uintptr(p) -} - -type SwigcptrB_Sl_bool_Sc_double_Sg_ uintptr -type B_Sl_bool_Sc_double_Sg_ interface { - Swigcptr() uintptr; -} -func (p SwigcptrB_Sl_bool_Sc_double_Sg_) Swigcptr() uintptr { - return uintptr(p) -} - -type SwigcptrB_Sl_int_Sc_int_Sg_ uintptr -type B_Sl_int_Sc_int_Sg_ interface { - Swigcptr() uintptr; -} -func (p SwigcptrB_Sl_int_Sc_int_Sg_) Swigcptr() uintptr { - return uintptr(p) -} - -type SwigcptrB_Sl_bool_Sc_int_Sg_ uintptr -type B_Sl_bool_Sc_int_Sg_ interface { - Swigcptr() uintptr; -} -func (p SwigcptrB_Sl_bool_Sc_int_Sg_) Swigcptr() uintptr { - return uintptr(p) -} - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/template_extend_overload_2.go b/Examples/test-suite/go/template_extend_overload_2.go deleted file mode 100644 index 5eef74577..000000000 --- a/Examples/test-suite/go/template_extend_overload_2.go +++ /dev/null @@ -1,385 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../template_extend_overload_2.i - -package template_extend_overload_2 - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrA uintptr - -func (p SwigcptrA) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrA) SwigIsA() { -} - -var _wrap_new_A__SWIG_0 unsafe.Pointer - -func _swig_wrap_new_A__SWIG_0() (base SwigcptrA) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_A__SWIG_0, _swig_p) - return -} - -func NewA__SWIG_0() (_swig_ret A) { - return _swig_wrap_new_A__SWIG_0() -} - -var _wrap_new_A__SWIG_1 unsafe.Pointer - -func _swig_wrap_new_A__SWIG_1(base int) (_ SwigcptrA) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_A__SWIG_1, _swig_p) - return -} - -func NewA__SWIG_1(arg1 int) (_swig_ret A) { - return _swig_wrap_new_A__SWIG_1(arg1) -} - -var _wrap_A_hi__SWIG_0 unsafe.Pointer - -func _swig_wrap_A_hi__SWIG_0(base SwigcptrA) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_A_hi__SWIG_0, _swig_p) - return -} - -func (arg1 SwigcptrA) Hi__SWIG_0() (_swig_ret int) { - return _swig_wrap_A_hi__SWIG_0(arg1) -} - -var _wrap_A_hi__SWIG_1 unsafe.Pointer - -func _swig_wrap_A_hi__SWIG_1(base SwigcptrA, _ int) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_A_hi__SWIG_1, _swig_p) - return -} - -func (arg1 SwigcptrA) Hi__SWIG_1(arg2 int) (_swig_ret int) { - return _swig_wrap_A_hi__SWIG_1(arg1, arg2) -} - -func (p SwigcptrA) Hi(a ...interface{}) int { - argc := len(a) - if argc == 0 { - return p.Hi__SWIG_0() - } - if argc == 1 { - return p.Hi__SWIG_1(a[0].(int)) - } - panic("No match for overloaded function call") -} - -var _wrap_new_A__SWIG_2 unsafe.Pointer - -func _swig_wrap_new_A__SWIG_2(base float64) (_ SwigcptrA) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_A__SWIG_2, _swig_p) - return -} - -func NewA__SWIG_2(arg1 float64) (_swig_ret A) { - return _swig_wrap_new_A__SWIG_2(arg1) -} - -func NewA(a ...interface{}) A { - argc := len(a) - if argc == 0 { - return NewA__SWIG_0() - } - if argc == 1 { - if _, ok := a[0].(int); !ok { - goto check_2 - } - return NewA__SWIG_1(a[0].(int)) - } -check_2: - if argc == 1 { - return NewA__SWIG_2(a[0].(float64)) - } - panic("No match for overloaded function call") -} - -var _wrap_delete_A unsafe.Pointer - -func _swig_wrap_delete_A(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_A, _swig_p) - return -} - -func DeleteA(arg1 A) { - _swig_wrap_delete_A(arg1.Swigcptr()) -} - -type A interface { - Swigcptr() uintptr - SwigIsA() - Hi(a ...interface{}) int -} - -type SwigcptrAT_double uintptr - -func (p SwigcptrAT_double) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrAT_double) SwigIsAT_double() { -} - -var _wrap_new_AT_double__SWIG_0 unsafe.Pointer - -func _swig_wrap_new_AT_double__SWIG_0() (base SwigcptrAT_double) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_AT_double__SWIG_0, _swig_p) - return -} - -func NewAT_double__SWIG_0() (_swig_ret AT_double) { - return _swig_wrap_new_AT_double__SWIG_0() -} - -var _wrap_new_AT_double__SWIG_1 unsafe.Pointer - -func _swig_wrap_new_AT_double__SWIG_1(base int) (_ SwigcptrAT_double) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_AT_double__SWIG_1, _swig_p) - return -} - -func NewAT_double__SWIG_1(arg1 int) (_swig_ret AT_double) { - return _swig_wrap_new_AT_double__SWIG_1(arg1) -} - -var _wrap_AT_double_hi__SWIG_0 unsafe.Pointer - -func _swig_wrap_AT_double_hi__SWIG_0(base SwigcptrAT_double) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_AT_double_hi__SWIG_0, _swig_p) - return -} - -func (arg1 SwigcptrAT_double) Hi__SWIG_0() (_swig_ret int) { - return _swig_wrap_AT_double_hi__SWIG_0(arg1) -} - -var _wrap_AT_double_hi__SWIG_1 unsafe.Pointer - -func _swig_wrap_AT_double_hi__SWIG_1(base SwigcptrAT_double, _ int) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_AT_double_hi__SWIG_1, _swig_p) - return -} - -func (arg1 SwigcptrAT_double) Hi__SWIG_1(arg2 int) (_swig_ret int) { - return _swig_wrap_AT_double_hi__SWIG_1(arg1, arg2) -} - -func (p SwigcptrAT_double) Hi(a ...interface{}) int { - argc := len(a) - if argc == 0 { - return p.Hi__SWIG_0() - } - if argc == 1 { - return p.Hi__SWIG_1(a[0].(int)) - } - panic("No match for overloaded function call") -} - -var _wrap_new_AT_double__SWIG_2 unsafe.Pointer - -func _swig_wrap_new_AT_double__SWIG_2(base float64) (_ SwigcptrAT_double) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_AT_double__SWIG_2, _swig_p) - return -} - -func NewAT_double__SWIG_2(arg1 float64) (_swig_ret AT_double) { - return _swig_wrap_new_AT_double__SWIG_2(arg1) -} - -func NewAT_double(a ...interface{}) AT_double { - argc := len(a) - if argc == 0 { - return NewAT_double__SWIG_0() - } - if argc == 1 { - if _, ok := a[0].(int); !ok { - goto check_2 - } - return NewAT_double__SWIG_1(a[0].(int)) - } -check_2: - if argc == 1 { - return NewAT_double__SWIG_2(a[0].(float64)) - } - panic("No match for overloaded function call") -} - -var _wrap_delete_AT_double unsafe.Pointer - -func _swig_wrap_delete_AT_double(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_AT_double, _swig_p) - return -} - -func DeleteAT_double(arg1 AT_double) { - _swig_wrap_delete_AT_double(arg1.Swigcptr()) -} - -type AT_double interface { - Swigcptr() uintptr - SwigIsAT_double() - Hi(a ...interface{}) int -} - -type SwigcptrBT_double uintptr - -func (p SwigcptrBT_double) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrBT_double) SwigIsBT_double() { -} - -var _wrap_new_BT_double__SWIG_0 unsafe.Pointer - -func _swig_wrap_new_BT_double__SWIG_0() (base SwigcptrBT_double) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_BT_double__SWIG_0, _swig_p) - return -} - -func NewBT_double__SWIG_0() (_swig_ret BT_double) { - return _swig_wrap_new_BT_double__SWIG_0() -} - -var _wrap_new_BT_double__SWIG_1 unsafe.Pointer - -func _swig_wrap_new_BT_double__SWIG_1(base int) (_ SwigcptrBT_double) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_BT_double__SWIG_1, _swig_p) - return -} - -func NewBT_double__SWIG_1(arg1 int) (_swig_ret BT_double) { - return _swig_wrap_new_BT_double__SWIG_1(arg1) -} - -var _wrap_BT_double_hi__SWIG_0 unsafe.Pointer - -func _swig_wrap_BT_double_hi__SWIG_0(base SwigcptrBT_double) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_BT_double_hi__SWIG_0, _swig_p) - return -} - -func (arg1 SwigcptrBT_double) Hi__SWIG_0() (_swig_ret int) { - return _swig_wrap_BT_double_hi__SWIG_0(arg1) -} - -var _wrap_BT_double_hi__SWIG_1 unsafe.Pointer - -func _swig_wrap_BT_double_hi__SWIG_1(base SwigcptrBT_double, _ int) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_BT_double_hi__SWIG_1, _swig_p) - return -} - -func (arg1 SwigcptrBT_double) Hi__SWIG_1(arg2 int) (_swig_ret int) { - return _swig_wrap_BT_double_hi__SWIG_1(arg1, arg2) -} - -func (p SwigcptrBT_double) Hi(a ...interface{}) int { - argc := len(a) - if argc == 0 { - return p.Hi__SWIG_0() - } - if argc == 1 { - return p.Hi__SWIG_1(a[0].(int)) - } - panic("No match for overloaded function call") -} - -var _wrap_new_BT_double__SWIG_2 unsafe.Pointer - -func _swig_wrap_new_BT_double__SWIG_2(base float64) (_ SwigcptrBT_double) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_BT_double__SWIG_2, _swig_p) - return -} - -func NewBT_double__SWIG_2(arg1 float64) (_swig_ret BT_double) { - return _swig_wrap_new_BT_double__SWIG_2(arg1) -} - -func NewBT_double(a ...interface{}) BT_double { - argc := len(a) - if argc == 0 { - return NewBT_double__SWIG_0() - } - if argc == 1 { - if _, ok := a[0].(int); !ok { - goto check_2 - } - return NewBT_double__SWIG_1(a[0].(int)) - } -check_2: - if argc == 1 { - return NewBT_double__SWIG_2(a[0].(float64)) - } - panic("No match for overloaded function call") -} - -var _wrap_delete_BT_double unsafe.Pointer - -func _swig_wrap_delete_BT_double(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_BT_double, _swig_p) - return -} - -func DeleteBT_double(arg1 BT_double) { - _swig_wrap_delete_BT_double(arg1.Swigcptr()) -} - -type BT_double interface { - Swigcptr() uintptr - SwigIsBT_double() - Hi(a ...interface{}) int -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/template_forward.go b/Examples/test-suite/go/template_forward.go deleted file mode 100644 index e9af0f5c0..000000000 --- a/Examples/test-suite/go/template_forward.go +++ /dev/null @@ -1,378 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../template_forward.i - -package template_forward - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -var _wrap_test1 unsafe.Pointer - -func _swig_wrap_test1(base uintptr) (_ float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_test1, _swig_p) - return -} - -func Test1(arg1 Foo_bar_Sl_double_Sg_) (_swig_ret float64) { - return _swig_wrap_test1(arg1.Swigcptr()) -} - -var _wrap_test2 unsafe.Pointer - -func _swig_wrap_test2() (base SwigcptrFoo_bar_Sl_double_Sg_) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_test2, _swig_p) - return -} - -func Test2() (_swig_ret Foo_bar_Sl_double_Sg_) { - return _swig_wrap_test2() -} - -type SwigcptrDescribable uintptr - -func (p SwigcptrDescribable) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrDescribable) SwigIsDescribable() { -} - -var _wrap_Describable_describe unsafe.Pointer - -func _swig_wrap_Describable_describe(base SwigcptrDescribable) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Describable_describe, _swig_p) - return -} - -func (arg1 SwigcptrDescribable) Describe() { - _swig_wrap_Describable_describe(arg1) -} - -var _wrap_new_Describable unsafe.Pointer - -func _swig_wrap_new_Describable() (base SwigcptrDescribable) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Describable, _swig_p) - return -} - -func NewDescribable() (_swig_ret Describable) { - return _swig_wrap_new_Describable() -} - -var _wrap_delete_Describable unsafe.Pointer - -func _swig_wrap_delete_Describable(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Describable, _swig_p) - return -} - -func DeleteDescribable(arg1 Describable) { - _swig_wrap_delete_Describable(arg1.Swigcptr()) -} - -type Describable interface { - Swigcptr() uintptr - SwigIsDescribable() - Describe() -} - -type SwigcptrLinearOpBase_double uintptr - -func (p SwigcptrLinearOpBase_double) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrLinearOpBase_double) SwigIsLinearOpBase_double() { -} - -var _wrap_new_LinearOpBase_double unsafe.Pointer - -func _swig_wrap_new_LinearOpBase_double() (base SwigcptrLinearOpBase_double) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_LinearOpBase_double, _swig_p) - return -} - -func NewLinearOpBase_double() (_swig_ret LinearOpBase_double) { - return _swig_wrap_new_LinearOpBase_double() -} - -var _wrap_delete_LinearOpBase_double unsafe.Pointer - -func _swig_wrap_delete_LinearOpBase_double(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_LinearOpBase_double, _swig_p) - return -} - -func DeleteLinearOpBase_double(arg1 LinearOpBase_double) { - _swig_wrap_delete_LinearOpBase_double(arg1.Swigcptr()) -} - -var _wrap_LinearOpBase_double_describe unsafe.Pointer - -func _swig_wrap_LinearOpBase_double_describe(base SwigcptrLinearOpBase_double) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_LinearOpBase_double_describe, _swig_p) - return -} - -func (_swig_base SwigcptrLinearOpBase_double) Describe() { - _swig_wrap_LinearOpBase_double_describe(_swig_base) -} - -func (p SwigcptrLinearOpBase_double) SwigIsDescribable() { -} - -func (p SwigcptrLinearOpBase_double) SwigGetDescribable() Describable { - return SwigcptrDescribable(p.Swigcptr()) -} - -type LinearOpBase_double interface { - Swigcptr() uintptr - SwigIsLinearOpBase_double() - Describe() - SwigIsDescribable() - SwigGetDescribable() Describable -} - -type SwigcptrVectorBase_double uintptr - -func (p SwigcptrVectorBase_double) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrVectorBase_double) SwigIsVectorBase_double() { -} - -var _wrap_VectorBase_double_describe unsafe.Pointer - -func _swig_wrap_VectorBase_double_describe(base SwigcptrVectorBase_double) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_VectorBase_double_describe, _swig_p) - return -} - -func (arg1 SwigcptrVectorBase_double) Describe() { - _swig_wrap_VectorBase_double_describe(arg1) -} - -var _wrap_new_VectorBase_double unsafe.Pointer - -func _swig_wrap_new_VectorBase_double() (base SwigcptrVectorBase_double) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_VectorBase_double, _swig_p) - return -} - -func NewVectorBase_double() (_swig_ret VectorBase_double) { - return _swig_wrap_new_VectorBase_double() -} - -var _wrap_delete_VectorBase_double unsafe.Pointer - -func _swig_wrap_delete_VectorBase_double(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_VectorBase_double, _swig_p) - return -} - -func DeleteVectorBase_double(arg1 VectorBase_double) { - _swig_wrap_delete_VectorBase_double(arg1.Swigcptr()) -} - -func (p SwigcptrVectorBase_double) SwigIsLinearOpBase_double() { -} - -func (p SwigcptrVectorBase_double) SwigGetLinearOpBase_double() LinearOpBase_double { - return SwigcptrLinearOpBase_double(p.Swigcptr()) -} - -func (p SwigcptrVectorBase_double) SwigIsDescribable() { -} - -func (p SwigcptrVectorBase_double) SwigGetDescribable() Describable { - return SwigcptrDescribable(p.Swigcptr()) -} - -type VectorBase_double interface { - Swigcptr() uintptr - SwigIsVectorBase_double() - Describe() - SwigIsLinearOpBase_double() - SwigGetLinearOpBase_double() LinearOpBase_double - SwigIsDescribable() - SwigGetDescribable() Describable -} - -type SwigcptrLinearOpBase_int uintptr - -func (p SwigcptrLinearOpBase_int) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrLinearOpBase_int) SwigIsLinearOpBase_int() { -} - -var _wrap_new_LinearOpBase_int unsafe.Pointer - -func _swig_wrap_new_LinearOpBase_int() (base SwigcptrLinearOpBase_int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_LinearOpBase_int, _swig_p) - return -} - -func NewLinearOpBase_int() (_swig_ret LinearOpBase_int) { - return _swig_wrap_new_LinearOpBase_int() -} - -var _wrap_delete_LinearOpBase_int unsafe.Pointer - -func _swig_wrap_delete_LinearOpBase_int(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_LinearOpBase_int, _swig_p) - return -} - -func DeleteLinearOpBase_int(arg1 LinearOpBase_int) { - _swig_wrap_delete_LinearOpBase_int(arg1.Swigcptr()) -} - -var _wrap_LinearOpBase_int_describe unsafe.Pointer - -func _swig_wrap_LinearOpBase_int_describe(base SwigcptrLinearOpBase_int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_LinearOpBase_int_describe, _swig_p) - return -} - -func (_swig_base SwigcptrLinearOpBase_int) Describe() { - _swig_wrap_LinearOpBase_int_describe(_swig_base) -} - -func (p SwigcptrLinearOpBase_int) SwigIsDescribable() { -} - -func (p SwigcptrLinearOpBase_int) SwigGetDescribable() Describable { - return SwigcptrDescribable(p.Swigcptr()) -} - -type LinearOpBase_int interface { - Swigcptr() uintptr - SwigIsLinearOpBase_int() - Describe() - SwigIsDescribable() - SwigGetDescribable() Describable -} - -type SwigcptrVectorBase_int uintptr - -func (p SwigcptrVectorBase_int) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrVectorBase_int) SwigIsVectorBase_int() { -} - -var _wrap_VectorBase_int_describe unsafe.Pointer - -func _swig_wrap_VectorBase_int_describe(base SwigcptrVectorBase_int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_VectorBase_int_describe, _swig_p) - return -} - -func (arg1 SwigcptrVectorBase_int) Describe() { - _swig_wrap_VectorBase_int_describe(arg1) -} - -var _wrap_new_VectorBase_int unsafe.Pointer - -func _swig_wrap_new_VectorBase_int() (base SwigcptrVectorBase_int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_VectorBase_int, _swig_p) - return -} - -func NewVectorBase_int() (_swig_ret VectorBase_int) { - return _swig_wrap_new_VectorBase_int() -} - -var _wrap_delete_VectorBase_int unsafe.Pointer - -func _swig_wrap_delete_VectorBase_int(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_VectorBase_int, _swig_p) - return -} - -func DeleteVectorBase_int(arg1 VectorBase_int) { - _swig_wrap_delete_VectorBase_int(arg1.Swigcptr()) -} - -func (p SwigcptrVectorBase_int) SwigIsLinearOpBase_int() { -} - -func (p SwigcptrVectorBase_int) SwigGetLinearOpBase_int() LinearOpBase_int { - return SwigcptrLinearOpBase_int(p.Swigcptr()) -} - -func (p SwigcptrVectorBase_int) SwigIsDescribable() { -} - -func (p SwigcptrVectorBase_int) SwigGetDescribable() Describable { - return SwigcptrDescribable(p.Swigcptr()) -} - -type VectorBase_int interface { - Swigcptr() uintptr - SwigIsVectorBase_int() - Describe() - SwigIsLinearOpBase_int() - SwigGetLinearOpBase_int() LinearOpBase_int - SwigIsDescribable() - SwigGetDescribable() Describable -} - - -type SwigcptrFoo_bar_Sl_double_Sg_ uintptr -type Foo_bar_Sl_double_Sg_ interface { - Swigcptr() uintptr; -} -func (p SwigcptrFoo_bar_Sl_double_Sg_) Swigcptr() uintptr { - return uintptr(p) -} - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/template_inherit.go b/Examples/test-suite/go/template_inherit.go deleted file mode 100644 index e60aa816d..000000000 --- a/Examples/test-suite/go/template_inherit.go +++ /dev/null @@ -1,484 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../template_inherit.i - -package template_inherit - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrFooInt uintptr - -func (p SwigcptrFooInt) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrFooInt) SwigIsFooInt() { -} - -var _wrap_delete_FooInt unsafe.Pointer - -func _swig_wrap_delete_FooInt(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_FooInt, _swig_p) - return -} - -func DeleteFooInt(arg1 FooInt) { - _swig_wrap_delete_FooInt(arg1.Swigcptr()) -} - -var _wrap_FooInt_blah unsafe.Pointer - -func _swig_wrap_FooInt_blah(base SwigcptrFooInt) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_FooInt_blah, _swig_p) - return -} - -func (arg1 SwigcptrFooInt) Blah() (_swig_ret string) { - return _swig_wrap_FooInt_blah(arg1) -} - -var _wrap_FooInt_foomethod unsafe.Pointer - -func _swig_wrap_FooInt_foomethod(base SwigcptrFooInt) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_FooInt_foomethod, _swig_p) - return -} - -func (arg1 SwigcptrFooInt) Foomethod() (_swig_ret string) { - return _swig_wrap_FooInt_foomethod(arg1) -} - -var _wrap_new_FooInt unsafe.Pointer - -func _swig_wrap_new_FooInt() (base SwigcptrFooInt) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_FooInt, _swig_p) - return -} - -func NewFooInt() (_swig_ret FooInt) { - return _swig_wrap_new_FooInt() -} - -type FooInt interface { - Swigcptr() uintptr - SwigIsFooInt() - Blah() (_swig_ret string) - Foomethod() (_swig_ret string) -} - -type SwigcptrFooDouble uintptr - -func (p SwigcptrFooDouble) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrFooDouble) SwigIsFooDouble() { -} - -var _wrap_delete_FooDouble unsafe.Pointer - -func _swig_wrap_delete_FooDouble(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_FooDouble, _swig_p) - return -} - -func DeleteFooDouble(arg1 FooDouble) { - _swig_wrap_delete_FooDouble(arg1.Swigcptr()) -} - -var _wrap_FooDouble_blah unsafe.Pointer - -func _swig_wrap_FooDouble_blah(base SwigcptrFooDouble) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_FooDouble_blah, _swig_p) - return -} - -func (arg1 SwigcptrFooDouble) Blah() (_swig_ret string) { - return _swig_wrap_FooDouble_blah(arg1) -} - -var _wrap_FooDouble_foomethod unsafe.Pointer - -func _swig_wrap_FooDouble_foomethod(base SwigcptrFooDouble) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_FooDouble_foomethod, _swig_p) - return -} - -func (arg1 SwigcptrFooDouble) Foomethod() (_swig_ret string) { - return _swig_wrap_FooDouble_foomethod(arg1) -} - -var _wrap_new_FooDouble unsafe.Pointer - -func _swig_wrap_new_FooDouble() (base SwigcptrFooDouble) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_FooDouble, _swig_p) - return -} - -func NewFooDouble() (_swig_ret FooDouble) { - return _swig_wrap_new_FooDouble() -} - -type FooDouble interface { - Swigcptr() uintptr - SwigIsFooDouble() - Blah() (_swig_ret string) - Foomethod() (_swig_ret string) -} - -type SwigcptrFooUInt uintptr - -func (p SwigcptrFooUInt) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrFooUInt) SwigIsFooUInt() { -} - -var _wrap_delete_FooUInt unsafe.Pointer - -func _swig_wrap_delete_FooUInt(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_FooUInt, _swig_p) - return -} - -func DeleteFooUInt(arg1 FooUInt) { - _swig_wrap_delete_FooUInt(arg1.Swigcptr()) -} - -var _wrap_FooUInt_blah unsafe.Pointer - -func _swig_wrap_FooUInt_blah(base SwigcptrFooUInt) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_FooUInt_blah, _swig_p) - return -} - -func (arg1 SwigcptrFooUInt) Blah() (_swig_ret string) { - return _swig_wrap_FooUInt_blah(arg1) -} - -var _wrap_FooUInt_foomethod unsafe.Pointer - -func _swig_wrap_FooUInt_foomethod(base SwigcptrFooUInt) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_FooUInt_foomethod, _swig_p) - return -} - -func (arg1 SwigcptrFooUInt) Foomethod() (_swig_ret string) { - return _swig_wrap_FooUInt_foomethod(arg1) -} - -var _wrap_new_FooUInt unsafe.Pointer - -func _swig_wrap_new_FooUInt() (base SwigcptrFooUInt) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_FooUInt, _swig_p) - return -} - -func NewFooUInt() (_swig_ret FooUInt) { - return _swig_wrap_new_FooUInt() -} - -type FooUInt interface { - Swigcptr() uintptr - SwigIsFooUInt() - Blah() (_swig_ret string) - Foomethod() (_swig_ret string) -} - -type SwigcptrBarInt uintptr - -func (p SwigcptrBarInt) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrBarInt) SwigIsBarInt() { -} - -var _wrap_BarInt_blah unsafe.Pointer - -func _swig_wrap_BarInt_blah(base SwigcptrBarInt) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_BarInt_blah, _swig_p) - return -} - -func (arg1 SwigcptrBarInt) Blah() (_swig_ret string) { - return _swig_wrap_BarInt_blah(arg1) -} - -var _wrap_new_BarInt unsafe.Pointer - -func _swig_wrap_new_BarInt() (base SwigcptrBarInt) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_BarInt, _swig_p) - return -} - -func NewBarInt() (_swig_ret BarInt) { - return _swig_wrap_new_BarInt() -} - -var _wrap_delete_BarInt unsafe.Pointer - -func _swig_wrap_delete_BarInt(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_BarInt, _swig_p) - return -} - -func DeleteBarInt(arg1 BarInt) { - _swig_wrap_delete_BarInt(arg1.Swigcptr()) -} - -var _wrap_BarInt_foomethod unsafe.Pointer - -func _swig_wrap_BarInt_foomethod(base SwigcptrBarInt) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_BarInt_foomethod, _swig_p) - return -} - -func (_swig_base SwigcptrBarInt) Foomethod() (_swig_ret string) { - return _swig_wrap_BarInt_foomethod(_swig_base) -} - -func (p SwigcptrBarInt) SwigIsFooInt() { -} - -func (p SwigcptrBarInt) SwigGetFooInt() FooInt { - return SwigcptrFooInt(p.Swigcptr()) -} - -type BarInt interface { - Swigcptr() uintptr - SwigIsBarInt() - Blah() (_swig_ret string) - Foomethod() (_swig_ret string) - SwigIsFooInt() - SwigGetFooInt() FooInt -} - -type SwigcptrBarDouble uintptr - -func (p SwigcptrBarDouble) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrBarDouble) SwigIsBarDouble() { -} - -var _wrap_BarDouble_blah unsafe.Pointer - -func _swig_wrap_BarDouble_blah(base SwigcptrBarDouble) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_BarDouble_blah, _swig_p) - return -} - -func (arg1 SwigcptrBarDouble) Blah() (_swig_ret string) { - return _swig_wrap_BarDouble_blah(arg1) -} - -var _wrap_new_BarDouble unsafe.Pointer - -func _swig_wrap_new_BarDouble() (base SwigcptrBarDouble) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_BarDouble, _swig_p) - return -} - -func NewBarDouble() (_swig_ret BarDouble) { - return _swig_wrap_new_BarDouble() -} - -var _wrap_delete_BarDouble unsafe.Pointer - -func _swig_wrap_delete_BarDouble(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_BarDouble, _swig_p) - return -} - -func DeleteBarDouble(arg1 BarDouble) { - _swig_wrap_delete_BarDouble(arg1.Swigcptr()) -} - -var _wrap_BarDouble_foomethod unsafe.Pointer - -func _swig_wrap_BarDouble_foomethod(base SwigcptrBarDouble) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_BarDouble_foomethod, _swig_p) - return -} - -func (_swig_base SwigcptrBarDouble) Foomethod() (_swig_ret string) { - return _swig_wrap_BarDouble_foomethod(_swig_base) -} - -func (p SwigcptrBarDouble) SwigIsFooDouble() { -} - -func (p SwigcptrBarDouble) SwigGetFooDouble() FooDouble { - return SwigcptrFooDouble(p.Swigcptr()) -} - -type BarDouble interface { - Swigcptr() uintptr - SwigIsBarDouble() - Blah() (_swig_ret string) - Foomethod() (_swig_ret string) - SwigIsFooDouble() - SwigGetFooDouble() FooDouble -} - -type SwigcptrBarUInt uintptr - -func (p SwigcptrBarUInt) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrBarUInt) SwigIsBarUInt() { -} - -var _wrap_BarUInt_blah unsafe.Pointer - -func _swig_wrap_BarUInt_blah(base SwigcptrBarUInt) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_BarUInt_blah, _swig_p) - return -} - -func (arg1 SwigcptrBarUInt) Blah() (_swig_ret string) { - return _swig_wrap_BarUInt_blah(arg1) -} - -var _wrap_new_BarUInt unsafe.Pointer - -func _swig_wrap_new_BarUInt() (base SwigcptrBarUInt) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_BarUInt, _swig_p) - return -} - -func NewBarUInt() (_swig_ret BarUInt) { - return _swig_wrap_new_BarUInt() -} - -var _wrap_delete_BarUInt unsafe.Pointer - -func _swig_wrap_delete_BarUInt(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_BarUInt, _swig_p) - return -} - -func DeleteBarUInt(arg1 BarUInt) { - _swig_wrap_delete_BarUInt(arg1.Swigcptr()) -} - -var _wrap_BarUInt_foomethod unsafe.Pointer - -func _swig_wrap_BarUInt_foomethod(base SwigcptrBarUInt) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_BarUInt_foomethod, _swig_p) - return -} - -func (_swig_base SwigcptrBarUInt) Foomethod() (_swig_ret string) { - return _swig_wrap_BarUInt_foomethod(_swig_base) -} - -func (p SwigcptrBarUInt) SwigIsFooUInt() { -} - -func (p SwigcptrBarUInt) SwigGetFooUInt() FooUInt { - return SwigcptrFooUInt(p.Swigcptr()) -} - -type BarUInt interface { - Swigcptr() uintptr - SwigIsBarUInt() - Blah() (_swig_ret string) - Foomethod() (_swig_ret string) - SwigIsFooUInt() - SwigGetFooUInt() FooUInt -} - -var _wrap_invoke_blah_int unsafe.Pointer - -func _swig_wrap_invoke_blah_int(base uintptr) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_invoke_blah_int, _swig_p) - return -} - -func Invoke_blah_int(arg1 FooInt) (_swig_ret string) { - return _swig_wrap_invoke_blah_int(arg1.Swigcptr()) -} - -var _wrap_invoke_blah_double unsafe.Pointer - -func _swig_wrap_invoke_blah_double(base uintptr) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_invoke_blah_double, _swig_p) - return -} - -func Invoke_blah_double(arg1 FooDouble) (_swig_ret string) { - return _swig_wrap_invoke_blah_double(arg1.Swigcptr()) -} - -var _wrap_invoke_blah_uint unsafe.Pointer - -func _swig_wrap_invoke_blah_uint(base uintptr) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_invoke_blah_uint, _swig_p) - return -} - -func Invoke_blah_uint(arg1 FooUInt) (_swig_ret string) { - return _swig_wrap_invoke_blah_uint(arg1.Swigcptr()) -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/template_inherit_abstract.go b/Examples/test-suite/go/template_inherit_abstract.go deleted file mode 100644 index 8caf1feee..000000000 --- a/Examples/test-suite/go/template_inherit_abstract.go +++ /dev/null @@ -1,358 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../template_inherit_abstract.i - -package template_inherit_abstract - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrModuleBase uintptr - -func (p SwigcptrModuleBase) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrModuleBase) SwigIsModuleBase() { -} - -var _wrap_delete_ModuleBase unsafe.Pointer - -func _swig_wrap_delete_ModuleBase(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_ModuleBase, _swig_p) - return -} - -func DeleteModuleBase(arg1 ModuleBase) { - _swig_wrap_delete_ModuleBase(arg1.Swigcptr()) -} - -var _wrap_ModuleBase_get unsafe.Pointer - -func _swig_wrap_ModuleBase_get(base SwigcptrModuleBase) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_ModuleBase_get, _swig_p) - return -} - -func (arg1 SwigcptrModuleBase) Get() (_swig_ret int) { - return _swig_wrap_ModuleBase_get(arg1) -} - -type ModuleBase interface { - Swigcptr() uintptr - SwigIsModuleBase() - Get() (_swig_ret int) -} - -type SwigcptrB uintptr - -func (p SwigcptrB) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrB) SwigIsB() { -} - -var _wrap_new_B unsafe.Pointer - -func _swig_wrap_new_B() (base SwigcptrB) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_B, _swig_p) - return -} - -func NewB() (_swig_ret B) { - return _swig_wrap_new_B() -} - -var _wrap_delete_B unsafe.Pointer - -func _swig_wrap_delete_B(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_B, _swig_p) - return -} - -func DeleteB(arg1 B) { - _swig_wrap_delete_B(arg1.Swigcptr()) -} - -type B interface { - Swigcptr() uintptr - SwigIsB() -} - -type SwigcptrWrap_B uintptr - -func (p SwigcptrWrap_B) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrWrap_B) SwigIsWrap_B() { -} - -var _wrap_new_Wrap_B unsafe.Pointer - -func _swig_wrap_new_Wrap_B() (base SwigcptrWrap_B) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Wrap_B, _swig_p) - return -} - -func NewWrap_B() (_swig_ret Wrap_B) { - return _swig_wrap_new_Wrap_B() -} - -var _wrap_delete_Wrap_B unsafe.Pointer - -func _swig_wrap_delete_Wrap_B(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Wrap_B, _swig_p) - return -} - -func DeleteWrap_B(arg1 Wrap_B) { - _swig_wrap_delete_Wrap_B(arg1.Swigcptr()) -} - -type Wrap_B interface { - Swigcptr() uintptr - SwigIsWrap_B() -} - -type SwigcptrModule_B uintptr - -func (p SwigcptrModule_B) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrModule_B) SwigIsModule_B() { -} - -var _wrap_delete_Module_B unsafe.Pointer - -func _swig_wrap_delete_Module_B(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Module_B, _swig_p) - return -} - -func DeleteModule_B(arg1 Module_B) { - _swig_wrap_delete_Module_B(arg1.Swigcptr()) -} - -var _wrap_Module_B_get unsafe.Pointer - -func _swig_wrap_Module_B_get(base SwigcptrModule_B) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Module_B_get, _swig_p) - return -} - -func (_swig_base SwigcptrModule_B) Get() (_swig_ret int) { - return _swig_wrap_Module_B_get(_swig_base) -} - -func (p SwigcptrModule_B) SwigIsWrap_B() { -} - -func (p SwigcptrModule_B) SwigGetWrap_B() Wrap_B { - return SwigcptrWrap_B(p.Swigcptr()) -} - -var _wrap_Module_B_SwigGetModuleBase unsafe.Pointer - -func _swig_wrap_Module_B_SwigGetModuleBase(base SwigcptrModule_B) (_ SwigcptrModuleBase) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Module_B_SwigGetModuleBase, _swig_p) - return -} - -func (arg1 SwigcptrModule_B) SwigGetModuleBase() (_swig_ret ModuleBase) { - return _swig_wrap_Module_B_SwigGetModuleBase(arg1) -} - -type Module_B interface { - Swigcptr() uintptr - SwigIsModule_B() - Get() (_swig_ret int) - SwigIsWrap_B() - SwigGetWrap_B() Wrap_B - SwigGetModuleBase() (_swig_ret ModuleBase) -} - -type SwigcptrHModule_B uintptr - -func (p SwigcptrHModule_B) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrHModule_B) SwigIsHModule_B() { -} - -var _wrap_delete_HModule_B unsafe.Pointer - -func _swig_wrap_delete_HModule_B(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_HModule_B, _swig_p) - return -} - -func DeleteHModule_B(arg1 HModule_B) { - _swig_wrap_delete_HModule_B(arg1.Swigcptr()) -} - -var _wrap_HModule_B_get unsafe.Pointer - -func _swig_wrap_HModule_B_get(base SwigcptrHModule_B) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_HModule_B_get, _swig_p) - return -} - -func (_swig_base SwigcptrHModule_B) Get() (_swig_ret int) { - return _swig_wrap_HModule_B_get(_swig_base) -} - -func (p SwigcptrHModule_B) SwigIsModule_B() { -} - -func (p SwigcptrHModule_B) SwigGetModule_B() Module_B { - return SwigcptrModule_B(p.Swigcptr()) -} - -func (p SwigcptrHModule_B) SwigIsWrap_B() { -} - -func (p SwigcptrHModule_B) SwigGetWrap_B() Wrap_B { - return SwigcptrWrap_B(p.Swigcptr()) -} - -func (p SwigcptrHModule_B) SwigGetModuleBase() ModuleBase { - return p.SwigGetModule_B().SwigGetModuleBase() -} - -type HModule_B interface { - Swigcptr() uintptr - SwigIsHModule_B() - Get() (_swig_ret int) - SwigIsModule_B() - SwigGetModule_B() Module_B - SwigIsWrap_B() - SwigGetWrap_B() Wrap_B - SwigGetModuleBase() ModuleBase -} - -type SwigcptrTest uintptr - -func (p SwigcptrTest) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrTest) SwigIsTest() { -} - -var _wrap_test_get unsafe.Pointer - -func _swig_wrap_test_get(base SwigcptrTest) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_test_get, _swig_p) - return -} - -func (arg1 SwigcptrTest) Get() (_swig_ret int) { - return _swig_wrap_test_get(arg1) -} - -var _wrap_new_test unsafe.Pointer - -func _swig_wrap_new_test() (base SwigcptrTest) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_test, _swig_p) - return -} - -func NewTest() (_swig_ret Test) { - return _swig_wrap_new_test() -} - -var _wrap_delete_test unsafe.Pointer - -func _swig_wrap_delete_test(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_test, _swig_p) - return -} - -func DeleteTest(arg1 Test) { - _swig_wrap_delete_test(arg1.Swigcptr()) -} - -func (p SwigcptrTest) SwigIsHModule_B() { -} - -func (p SwigcptrTest) SwigGetHModule_B() HModule_B { - return SwigcptrHModule_B(p.Swigcptr()) -} - -func (p SwigcptrTest) SwigIsModule_B() { -} - -func (p SwigcptrTest) SwigGetModule_B() Module_B { - return SwigcptrModule_B(p.Swigcptr()) -} - -func (p SwigcptrTest) SwigIsWrap_B() { -} - -func (p SwigcptrTest) SwigGetWrap_B() Wrap_B { - return SwigcptrWrap_B(p.Swigcptr()) -} - -func (p SwigcptrTest) SwigGetModuleBase() ModuleBase { - return p.SwigGetHModule_B().SwigGetModule_B().SwigGetModuleBase() -} - -type Test interface { - Swigcptr() uintptr - SwigIsTest() - Get() (_swig_ret int) - SwigIsHModule_B() - SwigGetHModule_B() HModule_B - SwigIsModule_B() - SwigGetModule_B() Module_B - SwigIsWrap_B() - SwigGetWrap_B() Wrap_B - SwigGetModuleBase() ModuleBase -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/template_inherit_runme b/Examples/test-suite/go/template_inherit_runme deleted file mode 100755 index 3d9050afa..000000000 Binary files a/Examples/test-suite/go/template_inherit_runme and /dev/null differ diff --git a/Examples/test-suite/go/template_int_const.go b/Examples/test-suite/go/template_int_const.go deleted file mode 100644 index e419369de..000000000 --- a/Examples/test-suite/go/template_int_const.go +++ /dev/null @@ -1,410 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../template_int_const.i - -package template_int_const - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type Polarization int -var _wrap_UnaryPolarization unsafe.Pointer - -func _swig_getUnaryPolarization() (_swig_ret Polarization) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_UnaryPolarization, _swig_p) - return -} -var UnaryPolarization Polarization = _swig_getUnaryPolarization() -var _wrap_BinaryPolarization unsafe.Pointer - -func _swig_getBinaryPolarization() (_swig_ret Polarization) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_BinaryPolarization, _swig_p) - return -} -var BinaryPolarization Polarization = _swig_getBinaryPolarization() -type SwigcptrInterface_traits uintptr - -func (p SwigcptrInterface_traits) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrInterface_traits) SwigIsInterface_traits() { -} - -var _wrap_interface_traits_polarization_interface_traits unsafe.Pointer - -func _swig_getinterface_traits_interface_traits_polarization_interface_traits() (_swig_ret Polarization) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_interface_traits_polarization_interface_traits, _swig_p) - return -} -var Interface_traitsPolarization Polarization = _swig_getinterface_traits_interface_traits_polarization_interface_traits() -var _wrap_new_interface_traits unsafe.Pointer - -func _swig_wrap_new_interface_traits() (base SwigcptrInterface_traits) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_interface_traits, _swig_p) - return -} - -func NewInterface_traits() (_swig_ret Interface_traits) { - return _swig_wrap_new_interface_traits() -} - -var _wrap_delete_interface_traits unsafe.Pointer - -func _swig_wrap_delete_interface_traits(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_interface_traits, _swig_p) - return -} - -func DeleteInterface_traits(arg1 Interface_traits) { - _swig_wrap_delete_interface_traits(arg1.Swigcptr()) -} - -type Interface_traits interface { - Swigcptr() uintptr - SwigIsInterface_traits() -} - -type SwigcptrModule_traits uintptr - -func (p SwigcptrModule_traits) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrModule_traits) SwigIsModule_traits() { -} - -var _wrap_module_traits_category_module_traits unsafe.Pointer - -func _swig_getmodule_traits_module_traits_category_module_traits() (_swig_ret uint) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_module_traits_category_module_traits, _swig_p) - return -} -var Module_traitsCategory uint = _swig_getmodule_traits_module_traits_category_module_traits() -var _wrap_new_module_traits unsafe.Pointer - -func _swig_wrap_new_module_traits() (base SwigcptrModule_traits) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_module_traits, _swig_p) - return -} - -func NewModule_traits() (_swig_ret Module_traits) { - return _swig_wrap_new_module_traits() -} - -var _wrap_delete_module_traits unsafe.Pointer - -func _swig_wrap_delete_module_traits(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_module_traits, _swig_p) - return -} - -func DeleteModule_traits(arg1 Module_traits) { - _swig_wrap_delete_module_traits(arg1.Swigcptr()) -} - -type Module_traits interface { - Swigcptr() uintptr - SwigIsModule_traits() -} - -type SwigcptrInterface_UP uintptr - -func (p SwigcptrInterface_UP) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrInterface_UP) SwigIsInterface_UP() { -} - -var _wrap_new_Interface_UP unsafe.Pointer - -func _swig_wrap_new_Interface_UP() (base SwigcptrInterface_UP) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Interface_UP, _swig_p) - return -} - -func NewInterface_UP() (_swig_ret Interface_UP) { - return _swig_wrap_new_Interface_UP() -} - -var _wrap_delete_Interface_UP unsafe.Pointer - -func _swig_wrap_delete_Interface_UP(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Interface_UP, _swig_p) - return -} - -func DeleteInterface_UP(arg1 Interface_UP) { - _swig_wrap_delete_Interface_UP(arg1.Swigcptr()) -} - -type Interface_UP interface { - Swigcptr() uintptr - SwigIsInterface_UP() -} - -type SwigcptrModule_1 uintptr - -func (p SwigcptrModule_1) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrModule_1) SwigIsModule_1() { -} - -var _wrap_new_Module_1 unsafe.Pointer - -func _swig_wrap_new_Module_1() (base SwigcptrModule_1) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Module_1, _swig_p) - return -} - -func NewModule_1() (_swig_ret Module_1) { - return _swig_wrap_new_Module_1() -} - -var _wrap_delete_Module_1 unsafe.Pointer - -func _swig_wrap_delete_Module_1(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Module_1, _swig_p) - return -} - -func DeleteModule_1(arg1 Module_1) { - _swig_wrap_delete_Module_1(arg1.Swigcptr()) -} - -type Module_1 interface { - Swigcptr() uintptr - SwigIsModule_1() -} - -type SwigcptrExtInterface1 uintptr - -func (p SwigcptrExtInterface1) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrExtInterface1) SwigIsExtInterface1() { -} - -var _wrap_new_ExtInterface1 unsafe.Pointer - -func _swig_wrap_new_ExtInterface1() (base SwigcptrExtInterface1) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_ExtInterface1, _swig_p) - return -} - -func NewExtInterface1() (_swig_ret ExtInterface1) { - return _swig_wrap_new_ExtInterface1() -} - -var _wrap_delete_ExtInterface1 unsafe.Pointer - -func _swig_wrap_delete_ExtInterface1(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_ExtInterface1, _swig_p) - return -} - -func DeleteExtInterface1(arg1 ExtInterface1) { - _swig_wrap_delete_ExtInterface1(arg1.Swigcptr()) -} - -func (p SwigcptrExtInterface1) SwigIsInterface_UP() { -} - -func (p SwigcptrExtInterface1) SwigGetInterface_UP() Interface_UP { - return SwigcptrInterface_UP(p.Swigcptr()) -} - -type ExtInterface1 interface { - Swigcptr() uintptr - SwigIsExtInterface1() - SwigIsInterface_UP() - SwigGetInterface_UP() Interface_UP -} - -type SwigcptrExtInterface2 uintptr - -func (p SwigcptrExtInterface2) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrExtInterface2) SwigIsExtInterface2() { -} - -var _wrap_new_ExtInterface2 unsafe.Pointer - -func _swig_wrap_new_ExtInterface2() (base SwigcptrExtInterface2) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_ExtInterface2, _swig_p) - return -} - -func NewExtInterface2() (_swig_ret ExtInterface2) { - return _swig_wrap_new_ExtInterface2() -} - -var _wrap_delete_ExtInterface2 unsafe.Pointer - -func _swig_wrap_delete_ExtInterface2(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_ExtInterface2, _swig_p) - return -} - -func DeleteExtInterface2(arg1 ExtInterface2) { - _swig_wrap_delete_ExtInterface2(arg1.Swigcptr()) -} - -func (p SwigcptrExtInterface2) SwigIsInterface_UP() { -} - -func (p SwigcptrExtInterface2) SwigGetInterface_UP() Interface_UP { - return SwigcptrInterface_UP(p.Swigcptr()) -} - -type ExtInterface2 interface { - Swigcptr() uintptr - SwigIsExtInterface2() - SwigIsInterface_UP() - SwigGetInterface_UP() Interface_UP -} - -type SwigcptrExtModule1 uintptr - -func (p SwigcptrExtModule1) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrExtModule1) SwigIsExtModule1() { -} - -var _wrap_new_ExtModule1 unsafe.Pointer - -func _swig_wrap_new_ExtModule1() (base SwigcptrExtModule1) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_ExtModule1, _swig_p) - return -} - -func NewExtModule1() (_swig_ret ExtModule1) { - return _swig_wrap_new_ExtModule1() -} - -var _wrap_delete_ExtModule1 unsafe.Pointer - -func _swig_wrap_delete_ExtModule1(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_ExtModule1, _swig_p) - return -} - -func DeleteExtModule1(arg1 ExtModule1) { - _swig_wrap_delete_ExtModule1(arg1.Swigcptr()) -} - -func (p SwigcptrExtModule1) SwigIsModule_1() { -} - -func (p SwigcptrExtModule1) SwigGetModule_1() Module_1 { - return SwigcptrModule_1(p.Swigcptr()) -} - -type ExtModule1 interface { - Swigcptr() uintptr - SwigIsExtModule1() - SwigIsModule_1() - SwigGetModule_1() Module_1 -} - -type SwigcptrExtModule2 uintptr - -func (p SwigcptrExtModule2) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrExtModule2) SwigIsExtModule2() { -} - -var _wrap_new_ExtModule2 unsafe.Pointer - -func _swig_wrap_new_ExtModule2() (base SwigcptrExtModule2) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_ExtModule2, _swig_p) - return -} - -func NewExtModule2() (_swig_ret ExtModule2) { - return _swig_wrap_new_ExtModule2() -} - -var _wrap_delete_ExtModule2 unsafe.Pointer - -func _swig_wrap_delete_ExtModule2(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_ExtModule2, _swig_p) - return -} - -func DeleteExtModule2(arg1 ExtModule2) { - _swig_wrap_delete_ExtModule2(arg1.Swigcptr()) -} - -func (p SwigcptrExtModule2) SwigIsModule_1() { -} - -func (p SwigcptrExtModule2) SwigGetModule_1() Module_1 { - return SwigcptrModule_1(p.Swigcptr()) -} - -type ExtModule2 interface { - Swigcptr() uintptr - SwigIsExtModule2() - SwigIsModule_1() - SwigGetModule_1() Module_1 -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/template_methods.go b/Examples/test-suite/go/template_methods.go deleted file mode 100644 index fff042e8b..000000000 --- a/Examples/test-suite/go/template_methods.go +++ /dev/null @@ -1,322 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../template_methods.i - -package template_methods - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -var _wrap_convolve1Bool__SWIG_0 unsafe.Pointer - -func Convolve1Bool__SWIG_0() (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_convolve1Bool__SWIG_0, _swig_p) - return -} -var _wrap_convolve1Bool__SWIG_1 unsafe.Pointer - -func _swig_wrap_convolve1Bool__SWIG_1(base bool) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_convolve1Bool__SWIG_1, _swig_p) - return -} - -func Convolve1Bool__SWIG_1(arg1 bool) { - _swig_wrap_convolve1Bool__SWIG_1(arg1) -} - -func Convolve1Bool(a ...interface{}) interface{} { - argc := len(a) - if argc == 0 { - return Convolve1Bool__SWIG_0() - } - if argc == 1 { - Convolve1Bool__SWIG_1(a[0].(bool)) - return 0 - } - panic("No match for overloaded function call") -} - -var _wrap_convolve2Float unsafe.Pointer - -func Convolve2Float() (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_convolve2Float, _swig_p) - return -} -var _wrap_convolve3FloatRenamed unsafe.Pointer - -func _swig_wrap_convolve3FloatRenamed(base float32) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_convolve3FloatRenamed, _swig_p) - return -} - -func Convolve3FloatRenamed(arg1 float32) { - _swig_wrap_convolve3FloatRenamed(arg1) -} - -var _wrap_convolve4Float unsafe.Pointer - -func Convolve4Float() (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_convolve4Float, _swig_p) - return -} -var _wrap_convolve4FloatRenamed unsafe.Pointer - -func _swig_wrap_convolve4FloatRenamed(base float32) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_convolve4FloatRenamed, _swig_p) - return -} - -func Convolve4FloatRenamed(arg1 float32) { - _swig_wrap_convolve4FloatRenamed(arg1) -} - -var _wrap_convolve5FloatRenamed__SWIG_0 unsafe.Pointer - -func Convolve5FloatRenamed__SWIG_0() (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_convolve5FloatRenamed__SWIG_0, _swig_p) - return -} -var _wrap_convolve5FloatRenamed__SWIG_1 unsafe.Pointer - -func _swig_wrap_convolve5FloatRenamed__SWIG_1(base float32) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_convolve5FloatRenamed__SWIG_1, _swig_p) - return -} - -func Convolve5FloatRenamed__SWIG_1(arg1 float32) { - _swig_wrap_convolve5FloatRenamed__SWIG_1(arg1) -} - -func Convolve5FloatRenamed(a ...interface{}) interface{} { - argc := len(a) - if argc == 0 { - return Convolve5FloatRenamed__SWIG_0() - } - if argc == 1 { - Convolve5FloatRenamed__SWIG_1(a[0].(float32)) - return 0 - } - panic("No match for overloaded function call") -} - -type SwigcptrKlass uintptr - -func (p SwigcptrKlass) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrKlass) SwigIsKlass() { -} - -var _wrap_Klass_KlassTMethodBoolRenamed unsafe.Pointer - -func _swig_wrap_Klass_KlassTMethodBoolRenamed(base SwigcptrKlass, _ bool) (_ bool) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Klass_KlassTMethodBoolRenamed, _swig_p) - return -} - -func (arg1 SwigcptrKlass) KlassTMethodBoolRenamed(arg2 bool) (_swig_ret bool) { - return _swig_wrap_Klass_KlassTMethodBoolRenamed(arg1, arg2) -} - -var _wrap_Klass_KlassTMethodBool unsafe.Pointer - -func _swig_wrap_Klass_KlassTMethodBool(base SwigcptrKlass) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Klass_KlassTMethodBool, _swig_p) - return -} - -func (arg1 SwigcptrKlass) KlassTMethodBool() { - _swig_wrap_Klass_KlassTMethodBool(arg1) -} - -var _wrap_Klass_KlassStaticTMethodBoolRenamed unsafe.Pointer - -func KlassKlassStaticTMethodBoolRenamed(arg1 bool) (_swig_ret bool) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_Klass_KlassStaticTMethodBoolRenamed, _swig_p) - return -} -var _wrap_Klass_KlassStaticTMethodBool unsafe.Pointer - -func _swig_wrap_Klass_KlassStaticTMethodBool() { - var _swig_p uintptr - _cgo_runtime_cgocall(_wrap_Klass_KlassStaticTMethodBool, _swig_p) - return -} - -func KlassKlassStaticTMethodBool() { - _swig_wrap_Klass_KlassStaticTMethodBool() -} - -var _wrap_new_Klass unsafe.Pointer - -func _swig_wrap_new_Klass() (base SwigcptrKlass) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Klass, _swig_p) - return -} - -func NewKlass() (_swig_ret Klass) { - return _swig_wrap_new_Klass() -} - -var _wrap_delete_Klass unsafe.Pointer - -func _swig_wrap_delete_Klass(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Klass, _swig_p) - return -} - -func DeleteKlass(arg1 Klass) { - _swig_wrap_delete_Klass(arg1.Swigcptr()) -} - -type Klass interface { - Swigcptr() uintptr - SwigIsKlass() - KlassTMethodBoolRenamed(arg2 bool) (_swig_ret bool) - KlassTMethodBool() -} - -type SwigcptrComponentProperties uintptr - -func (p SwigcptrComponentProperties) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrComponentProperties) SwigIsComponentProperties() { -} - -var _wrap_new_ComponentProperties unsafe.Pointer - -func _swig_wrap_new_ComponentProperties() (base SwigcptrComponentProperties) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_ComponentProperties, _swig_p) - return -} - -func NewComponentProperties() (_swig_ret ComponentProperties) { - return _swig_wrap_new_ComponentProperties() -} - -var _wrap_delete_ComponentProperties unsafe.Pointer - -func _swig_wrap_delete_ComponentProperties(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_ComponentProperties, _swig_p) - return -} - -func DeleteComponentProperties(arg1 ComponentProperties) { - _swig_wrap_delete_ComponentProperties(arg1.Swigcptr()) -} - -var _wrap_ComponentProperties_adda__SWIG_3 unsafe.Pointer - -func _swig_wrap_ComponentProperties_adda__SWIG_3(base SwigcptrComponentProperties, _ string, _ string, _ string, _ float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_ComponentProperties_adda__SWIG_3, _swig_p) - return -} - -func (arg1 SwigcptrComponentProperties) Adda__SWIG_3(arg2 string, arg3 string, arg4 string, arg5 float64) { - _swig_wrap_ComponentProperties_adda__SWIG_3(arg1, arg2, arg3, arg4, arg5) -} - -var _wrap_ComponentProperties_adda__SWIG_4 unsafe.Pointer - -func _swig_wrap_ComponentProperties_adda__SWIG_4(base SwigcptrComponentProperties, _ string, _ string, _ string, _ string, _ string, _ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_ComponentProperties_adda__SWIG_4, _swig_p) - return -} - -func (arg1 SwigcptrComponentProperties) Adda__SWIG_4(arg2 string, arg3 string, arg4 string, arg5 string, arg6 string, arg7 string) { - _swig_wrap_ComponentProperties_adda__SWIG_4(arg1, arg2, arg3, arg4, arg5, arg6, arg7) -} - -var _wrap_ComponentProperties_adda__SWIG_5 unsafe.Pointer - -func _swig_wrap_ComponentProperties_adda__SWIG_5(base SwigcptrComponentProperties, _ string, _ int, _ string, _ int, _ string, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_ComponentProperties_adda__SWIG_5, _swig_p) - return -} - -func (arg1 SwigcptrComponentProperties) Adda__SWIG_5(arg2 string, arg3 int, arg4 string, arg5 int, arg6 string, arg7 int) { - _swig_wrap_ComponentProperties_adda__SWIG_5(arg1, arg2, arg3, arg4, arg5, arg6, arg7) -} - -func (p SwigcptrComponentProperties) Adda(a ...interface{}) { - argc := len(a) - if argc == 4 { - p.Adda__SWIG_3(a[0].(string), a[1].(string), a[2].(string), a[3].(float64)) - return - } - if argc == 6 { - if _, ok := a[1].(string); !ok { - goto check_2 - } - if _, ok := a[3].(string); !ok { - goto check_2 - } - if _, ok := a[5].(string); !ok { - goto check_2 - } - p.Adda__SWIG_4(a[0].(string), a[1].(string), a[2].(string), a[3].(string), a[4].(string), a[5].(string)) - return - } -check_2: - if argc == 6 { - p.Adda__SWIG_5(a[0].(string), a[1].(int), a[2].(string), a[3].(int), a[4].(string), a[5].(int)) - return - } - panic("No match for overloaded function call") -} - -type ComponentProperties interface { - Swigcptr() uintptr - SwigIsComponentProperties() - Adda(a ...interface{}) -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/template_namespace_forward_declaration.go b/Examples/test-suite/go/template_namespace_forward_declaration.go deleted file mode 100644 index 56b0ccfd6..000000000 --- a/Examples/test-suite/go/template_namespace_forward_declaration.go +++ /dev/null @@ -1,211 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../template_namespace_forward_declaration.i - -package template_namespace_forward_declaration - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -var _wrap_testXXX1 unsafe.Pointer - -func _swig_wrap_testXXX1(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_testXXX1, _swig_p) - return -} - -func TestXXX1(arg1 XXXInt) { - _swig_wrap_testXXX1(arg1.Swigcptr()) -} - -var _wrap_testXXX2 unsafe.Pointer - -func _swig_wrap_testXXX2(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_testXXX2, _swig_p) - return -} - -func TestXXX2(arg1 XXXInt) { - _swig_wrap_testXXX2(arg1.Swigcptr()) -} - -var _wrap_testXXX3 unsafe.Pointer - -func _swig_wrap_testXXX3(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_testXXX3, _swig_p) - return -} - -func TestXXX3(arg1 XXXInt) { - _swig_wrap_testXXX3(arg1.Swigcptr()) -} - -var _wrap_testYYY1 unsafe.Pointer - -func _swig_wrap_testYYY1(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_testYYY1, _swig_p) - return -} - -func TestYYY1(arg1 YYYInt) { - _swig_wrap_testYYY1(arg1.Swigcptr()) -} - -var _wrap_testYYY2 unsafe.Pointer - -func _swig_wrap_testYYY2(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_testYYY2, _swig_p) - return -} - -func TestYYY2(arg1 YYYInt) { - _swig_wrap_testYYY2(arg1.Swigcptr()) -} - -var _wrap_testYYY3 unsafe.Pointer - -func _swig_wrap_testYYY3(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_testYYY3, _swig_p) - return -} - -func TestYYY3(arg1 YYYInt) { - _swig_wrap_testYYY3(arg1.Swigcptr()) -} - -type SwigcptrXXXInt uintptr - -func (p SwigcptrXXXInt) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrXXXInt) SwigIsXXXInt() { -} - -var _wrap_XXXInt_xxx unsafe.Pointer - -func _swig_wrap_XXXInt_xxx(base SwigcptrXXXInt, _ int) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_XXXInt_xxx, _swig_p) - return -} - -func (arg1 SwigcptrXXXInt) Xxx(arg2 int) (_swig_ret int) { - return _swig_wrap_XXXInt_xxx(arg1, arg2) -} - -var _wrap_new_XXXInt unsafe.Pointer - -func _swig_wrap_new_XXXInt() (base SwigcptrXXXInt) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_XXXInt, _swig_p) - return -} - -func NewXXXInt() (_swig_ret XXXInt) { - return _swig_wrap_new_XXXInt() -} - -var _wrap_delete_XXXInt unsafe.Pointer - -func _swig_wrap_delete_XXXInt(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_XXXInt, _swig_p) - return -} - -func DeleteXXXInt(arg1 XXXInt) { - _swig_wrap_delete_XXXInt(arg1.Swigcptr()) -} - -type XXXInt interface { - Swigcptr() uintptr - SwigIsXXXInt() - Xxx(arg2 int) (_swig_ret int) -} - -type SwigcptrYYYInt uintptr - -func (p SwigcptrYYYInt) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrYYYInt) SwigIsYYYInt() { -} - -var _wrap_YYYInt_yyy unsafe.Pointer - -func _swig_wrap_YYYInt_yyy(base SwigcptrYYYInt, _ int) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_YYYInt_yyy, _swig_p) - return -} - -func (arg1 SwigcptrYYYInt) Yyy(arg2 int) (_swig_ret int) { - return _swig_wrap_YYYInt_yyy(arg1, arg2) -} - -var _wrap_new_YYYInt unsafe.Pointer - -func _swig_wrap_new_YYYInt() (base SwigcptrYYYInt) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_YYYInt, _swig_p) - return -} - -func NewYYYInt() (_swig_ret YYYInt) { - return _swig_wrap_new_YYYInt() -} - -var _wrap_delete_YYYInt unsafe.Pointer - -func _swig_wrap_delete_YYYInt(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_YYYInt, _swig_p) - return -} - -func DeleteYYYInt(arg1 YYYInt) { - _swig_wrap_delete_YYYInt(arg1.Swigcptr()) -} - -type YYYInt interface { - Swigcptr() uintptr - SwigIsYYYInt() - Yyy(arg2 int) (_swig_ret int) -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/template_nested.go b/Examples/test-suite/go/template_nested.go deleted file mode 100644 index 43bfddec3..000000000 --- a/Examples/test-suite/go/template_nested.go +++ /dev/null @@ -1,919 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../template_nested.i - -package template_nested - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrNormalClass uintptr - -func (p SwigcptrNormalClass) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrNormalClass) SwigIsNormalClass() { -} - -var _wrap_new_NormalClass unsafe.Pointer - -func _swig_wrap_new_NormalClass() (base SwigcptrNormalClass) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_NormalClass, _swig_p) - return -} - -func NewNormalClass() (_swig_ret NormalClass) { - return _swig_wrap_new_NormalClass() -} - -var _wrap_delete_NormalClass unsafe.Pointer - -func _swig_wrap_delete_NormalClass(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_NormalClass, _swig_p) - return -} - -func DeleteNormalClass(arg1 NormalClass) { - _swig_wrap_delete_NormalClass(arg1.Swigcptr()) -} - -type NormalClass interface { - Swigcptr() uintptr - SwigIsNormalClass() -} - -type SwigcptrT_NormalTemplateNormalClass uintptr - -func (p SwigcptrT_NormalTemplateNormalClass) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrT_NormalTemplateNormalClass) SwigIsT_NormalTemplateNormalClass() { -} - -var _wrap_T_NormalTemplateNormalClass_tmethod unsafe.Pointer - -func _swig_wrap_T_NormalTemplateNormalClass_tmethod(base SwigcptrT_NormalTemplateNormalClass, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_T_NormalTemplateNormalClass_tmethod, _swig_p) - return -} - -func (arg1 SwigcptrT_NormalTemplateNormalClass) Tmethod(arg2 NormalClass) { - _swig_wrap_T_NormalTemplateNormalClass_tmethod(arg1, arg2.Swigcptr()) -} - -var _wrap_new_T_NormalTemplateNormalClass unsafe.Pointer - -func _swig_wrap_new_T_NormalTemplateNormalClass() (base SwigcptrT_NormalTemplateNormalClass) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_T_NormalTemplateNormalClass, _swig_p) - return -} - -func NewT_NormalTemplateNormalClass() (_swig_ret T_NormalTemplateNormalClass) { - return _swig_wrap_new_T_NormalTemplateNormalClass() -} - -var _wrap_delete_T_NormalTemplateNormalClass unsafe.Pointer - -func _swig_wrap_delete_T_NormalTemplateNormalClass(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_T_NormalTemplateNormalClass, _swig_p) - return -} - -func DeleteT_NormalTemplateNormalClass(arg1 T_NormalTemplateNormalClass) { - _swig_wrap_delete_T_NormalTemplateNormalClass(arg1.Swigcptr()) -} - -type T_NormalTemplateNormalClass interface { - Swigcptr() uintptr - SwigIsT_NormalTemplateNormalClass() - Tmethod(arg2 NormalClass) -} - -type SwigcptrT_NormalTemplateInt uintptr - -func (p SwigcptrT_NormalTemplateInt) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrT_NormalTemplateInt) SwigIsT_NormalTemplateInt() { -} - -var _wrap_T_NormalTemplateInt_tmethod unsafe.Pointer - -func _swig_wrap_T_NormalTemplateInt_tmethod(base SwigcptrT_NormalTemplateInt, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_T_NormalTemplateInt_tmethod, _swig_p) - return -} - -func (arg1 SwigcptrT_NormalTemplateInt) Tmethod(arg2 int) { - _swig_wrap_T_NormalTemplateInt_tmethod(arg1, arg2) -} - -var _wrap_new_T_NormalTemplateInt unsafe.Pointer - -func _swig_wrap_new_T_NormalTemplateInt() (base SwigcptrT_NormalTemplateInt) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_T_NormalTemplateInt, _swig_p) - return -} - -func NewT_NormalTemplateInt() (_swig_ret T_NormalTemplateInt) { - return _swig_wrap_new_T_NormalTemplateInt() -} - -var _wrap_delete_T_NormalTemplateInt unsafe.Pointer - -func _swig_wrap_delete_T_NormalTemplateInt(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_T_NormalTemplateInt, _swig_p) - return -} - -func DeleteT_NormalTemplateInt(arg1 T_NormalTemplateInt) { - _swig_wrap_delete_T_NormalTemplateInt(arg1.Swigcptr()) -} - -type T_NormalTemplateInt interface { - Swigcptr() uintptr - SwigIsT_NormalTemplateInt() - Tmethod(arg2 int) -} - -type SwigcptrT_NormalTemplateDouble uintptr - -func (p SwigcptrT_NormalTemplateDouble) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrT_NormalTemplateDouble) SwigIsT_NormalTemplateDouble() { -} - -var _wrap_T_NormalTemplateDouble_tmethod unsafe.Pointer - -func _swig_wrap_T_NormalTemplateDouble_tmethod(base SwigcptrT_NormalTemplateDouble, _ float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_T_NormalTemplateDouble_tmethod, _swig_p) - return -} - -func (arg1 SwigcptrT_NormalTemplateDouble) Tmethod(arg2 float64) { - _swig_wrap_T_NormalTemplateDouble_tmethod(arg1, arg2) -} - -var _wrap_new_T_NormalTemplateDouble unsafe.Pointer - -func _swig_wrap_new_T_NormalTemplateDouble() (base SwigcptrT_NormalTemplateDouble) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_T_NormalTemplateDouble, _swig_p) - return -} - -func NewT_NormalTemplateDouble() (_swig_ret T_NormalTemplateDouble) { - return _swig_wrap_new_T_NormalTemplateDouble() -} - -var _wrap_delete_T_NormalTemplateDouble unsafe.Pointer - -func _swig_wrap_delete_T_NormalTemplateDouble(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_T_NormalTemplateDouble, _swig_p) - return -} - -func DeleteT_NormalTemplateDouble(arg1 T_NormalTemplateDouble) { - _swig_wrap_delete_T_NormalTemplateDouble(arg1.Swigcptr()) -} - -type T_NormalTemplateDouble interface { - Swigcptr() uintptr - SwigIsT_NormalTemplateDouble() - Tmethod(arg2 float64) -} - -type SwigcptrOuterClass uintptr - -func (p SwigcptrOuterClass) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrOuterClass) SwigIsOuterClass() { -} - -var _wrap_OuterClass_useInner1 unsafe.Pointer - -func _swig_wrap_OuterClass_useInner1(base SwigcptrOuterClass, _ uintptr) (_ SwigcptrT_OuterClassInner1Int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_OuterClass_useInner1, _swig_p) - return -} - -func (arg1 SwigcptrOuterClass) UseInner1(arg2 T_OuterClassInner1Int) (_swig_ret T_OuterClassInner1Int) { - return _swig_wrap_OuterClass_useInner1(arg1, arg2.Swigcptr()) -} - -var _wrap_OuterClass_useInner2 unsafe.Pointer - -func _swig_wrap_OuterClass_useInner2(base SwigcptrOuterClass, _ uintptr) (_ SwigcptrT_OuterClassInner2Int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_OuterClass_useInner2, _swig_p) - return -} - -func (arg1 SwigcptrOuterClass) UseInner2(arg2 T_OuterClassInner2Int) (_swig_ret T_OuterClassInner2Int) { - return _swig_wrap_OuterClass_useInner2(arg1, arg2.Swigcptr()) -} - -var _wrap_OuterClass_useInner2Again unsafe.Pointer - -func _swig_wrap_OuterClass_useInner2Again(base SwigcptrOuterClass, _ uintptr) (_ SwigcptrT_OuterClassInner2NormalClass) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_OuterClass_useInner2Again, _swig_p) - return -} - -func (arg1 SwigcptrOuterClass) UseInner2Again(arg2 T_OuterClassInner2NormalClass) (_swig_ret T_OuterClassInner2NormalClass) { - return _swig_wrap_OuterClass_useInner2Again(arg1, arg2.Swigcptr()) -} - -var _wrap_OuterClass_iii_set unsafe.Pointer - -func _swig_wrap_OuterClass_iii_set(base SwigcptrOuterClass, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_OuterClass_iii_set, _swig_p) - return -} - -func (arg1 SwigcptrOuterClass) SetIii(arg2 int) { - _swig_wrap_OuterClass_iii_set(arg1, arg2) -} - -var _wrap_OuterClass_iii_get unsafe.Pointer - -func _swig_wrap_OuterClass_iii_get(base SwigcptrOuterClass) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_OuterClass_iii_get, _swig_p) - return -} - -func (arg1 SwigcptrOuterClass) GetIii() (_swig_ret int) { - return _swig_wrap_OuterClass_iii_get(arg1) -} - -var _wrap_OuterClass_T_OuterTMethodNormalClass unsafe.Pointer - -func _swig_wrap_OuterClass_T_OuterTMethodNormalClass(base SwigcptrOuterClass, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_OuterClass_T_OuterTMethodNormalClass, _swig_p) - return -} - -func (arg1 SwigcptrOuterClass) T_OuterTMethodNormalClass(arg2 NormalClass) { - _swig_wrap_OuterClass_T_OuterTMethodNormalClass(arg1, arg2.Swigcptr()) -} - -var _wrap_new_OuterClass unsafe.Pointer - -func _swig_wrap_new_OuterClass() (base SwigcptrOuterClass) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_OuterClass, _swig_p) - return -} - -func NewOuterClass() (_swig_ret OuterClass) { - return _swig_wrap_new_OuterClass() -} - -var _wrap_delete_OuterClass unsafe.Pointer - -func _swig_wrap_delete_OuterClass(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_OuterClass, _swig_p) - return -} - -func DeleteOuterClass(arg1 OuterClass) { - _swig_wrap_delete_OuterClass(arg1.Swigcptr()) -} - -type OuterClass interface { - Swigcptr() uintptr - SwigIsOuterClass() - UseInner1(arg2 T_OuterClassInner1Int) (_swig_ret T_OuterClassInner1Int) - UseInner2(arg2 T_OuterClassInner2Int) (_swig_ret T_OuterClassInner2Int) - UseInner2Again(arg2 T_OuterClassInner2NormalClass) (_swig_ret T_OuterClassInner2NormalClass) - SetIii(arg2 int) - GetIii() (_swig_ret int) - T_OuterTMethodNormalClass(arg2 NormalClass) -} - -type SwigcptrT_OuterClassInner1Double uintptr - -func (p SwigcptrT_OuterClassInner1Double) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrT_OuterClassInner1Double) SwigIsT_OuterClassInner1Double() { -} - -var _wrap_new_T_OuterClassInner1Double unsafe.Pointer - -func _swig_wrap_new_T_OuterClassInner1Double() (base SwigcptrT_OuterClassInner1Double) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_T_OuterClassInner1Double, _swig_p) - return -} - -func NewT_OuterClassInner1Double() (_swig_ret T_OuterClassInner1Double) { - return _swig_wrap_new_T_OuterClassInner1Double() -} - -var _wrap_delete_T_OuterClassInner1Double unsafe.Pointer - -func _swig_wrap_delete_T_OuterClassInner1Double(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_T_OuterClassInner1Double, _swig_p) - return -} - -func DeleteT_OuterClassInner1Double(arg1 T_OuterClassInner1Double) { - _swig_wrap_delete_T_OuterClassInner1Double(arg1.Swigcptr()) -} - -type T_OuterClassInner1Double interface { - Swigcptr() uintptr - SwigIsT_OuterClassInner1Double() -} - -type SwigcptrT_OuterClassInner2Double uintptr - -func (p SwigcptrT_OuterClassInner2Double) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrT_OuterClassInner2Double) SwigIsT_OuterClassInner2Double() { -} - -var _wrap_T_OuterClassInner2Double_embeddedVar_set unsafe.Pointer - -func _swig_wrap_T_OuterClassInner2Double_embeddedVar_set(base SwigcptrT_OuterClassInner2Double, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_T_OuterClassInner2Double_embeddedVar_set, _swig_p) - return -} - -func (arg1 SwigcptrT_OuterClassInner2Double) SetEmbeddedVar(arg2 int) { - _swig_wrap_T_OuterClassInner2Double_embeddedVar_set(arg1, arg2) -} - -var _wrap_T_OuterClassInner2Double_embeddedVar_get unsafe.Pointer - -func _swig_wrap_T_OuterClassInner2Double_embeddedVar_get(base SwigcptrT_OuterClassInner2Double) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_T_OuterClassInner2Double_embeddedVar_get, _swig_p) - return -} - -func (arg1 SwigcptrT_OuterClassInner2Double) GetEmbeddedVar() (_swig_ret int) { - return _swig_wrap_T_OuterClassInner2Double_embeddedVar_get(arg1) -} - -var _wrap_new_T_OuterClassInner2Double unsafe.Pointer - -func _swig_wrap_new_T_OuterClassInner2Double() (base SwigcptrT_OuterClassInner2Double) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_T_OuterClassInner2Double, _swig_p) - return -} - -func NewT_OuterClassInner2Double() (_swig_ret T_OuterClassInner2Double) { - return _swig_wrap_new_T_OuterClassInner2Double() -} - -var _wrap_delete_T_OuterClassInner2Double unsafe.Pointer - -func _swig_wrap_delete_T_OuterClassInner2Double(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_T_OuterClassInner2Double, _swig_p) - return -} - -func DeleteT_OuterClassInner2Double(arg1 T_OuterClassInner2Double) { - _swig_wrap_delete_T_OuterClassInner2Double(arg1.Swigcptr()) -} - -func (p SwigcptrT_OuterClassInner2Double) SwigIsT_NormalTemplateDouble() { -} - -func (p SwigcptrT_OuterClassInner2Double) SwigGetT_NormalTemplateDouble() T_NormalTemplateDouble { - return SwigcptrT_NormalTemplateDouble(p.Swigcptr()) -} - -type T_OuterClassInner2Double interface { - Swigcptr() uintptr - SwigIsT_OuterClassInner2Double() - SetEmbeddedVar(arg2 int) - GetEmbeddedVar() (_swig_ret int) - SwigIsT_NormalTemplateDouble() - SwigGetT_NormalTemplateDouble() T_NormalTemplateDouble -} - -type SwigcptrT_OuterClassInner1Int uintptr - -func (p SwigcptrT_OuterClassInner1Int) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrT_OuterClassInner1Int) SwigIsT_OuterClassInner1Int() { -} - -var _wrap_new_T_OuterClassInner1Int unsafe.Pointer - -func _swig_wrap_new_T_OuterClassInner1Int() (base SwigcptrT_OuterClassInner1Int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_T_OuterClassInner1Int, _swig_p) - return -} - -func NewT_OuterClassInner1Int() (_swig_ret T_OuterClassInner1Int) { - return _swig_wrap_new_T_OuterClassInner1Int() -} - -var _wrap_delete_T_OuterClassInner1Int unsafe.Pointer - -func _swig_wrap_delete_T_OuterClassInner1Int(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_T_OuterClassInner1Int, _swig_p) - return -} - -func DeleteT_OuterClassInner1Int(arg1 T_OuterClassInner1Int) { - _swig_wrap_delete_T_OuterClassInner1Int(arg1.Swigcptr()) -} - -type T_OuterClassInner1Int interface { - Swigcptr() uintptr - SwigIsT_OuterClassInner1Int() -} - -type SwigcptrT_OuterClassInner2NormalClass uintptr - -func (p SwigcptrT_OuterClassInner2NormalClass) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrT_OuterClassInner2NormalClass) SwigIsT_OuterClassInner2NormalClass() { -} - -var _wrap_T_OuterClassInner2NormalClass_embeddedVar_set unsafe.Pointer - -func _swig_wrap_T_OuterClassInner2NormalClass_embeddedVar_set(base SwigcptrT_OuterClassInner2NormalClass, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_T_OuterClassInner2NormalClass_embeddedVar_set, _swig_p) - return -} - -func (arg1 SwigcptrT_OuterClassInner2NormalClass) SetEmbeddedVar(arg2 int) { - _swig_wrap_T_OuterClassInner2NormalClass_embeddedVar_set(arg1, arg2) -} - -var _wrap_T_OuterClassInner2NormalClass_embeddedVar_get unsafe.Pointer - -func _swig_wrap_T_OuterClassInner2NormalClass_embeddedVar_get(base SwigcptrT_OuterClassInner2NormalClass) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_T_OuterClassInner2NormalClass_embeddedVar_get, _swig_p) - return -} - -func (arg1 SwigcptrT_OuterClassInner2NormalClass) GetEmbeddedVar() (_swig_ret int) { - return _swig_wrap_T_OuterClassInner2NormalClass_embeddedVar_get(arg1) -} - -var _wrap_new_T_OuterClassInner2NormalClass unsafe.Pointer - -func _swig_wrap_new_T_OuterClassInner2NormalClass() (base SwigcptrT_OuterClassInner2NormalClass) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_T_OuterClassInner2NormalClass, _swig_p) - return -} - -func NewT_OuterClassInner2NormalClass() (_swig_ret T_OuterClassInner2NormalClass) { - return _swig_wrap_new_T_OuterClassInner2NormalClass() -} - -var _wrap_delete_T_OuterClassInner2NormalClass unsafe.Pointer - -func _swig_wrap_delete_T_OuterClassInner2NormalClass(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_T_OuterClassInner2NormalClass, _swig_p) - return -} - -func DeleteT_OuterClassInner2NormalClass(arg1 T_OuterClassInner2NormalClass) { - _swig_wrap_delete_T_OuterClassInner2NormalClass(arg1.Swigcptr()) -} - -func (p SwigcptrT_OuterClassInner2NormalClass) SwigIsT_NormalTemplateNormalClass() { -} - -func (p SwigcptrT_OuterClassInner2NormalClass) SwigGetT_NormalTemplateNormalClass() T_NormalTemplateNormalClass { - return SwigcptrT_NormalTemplateNormalClass(p.Swigcptr()) -} - -type T_OuterClassInner2NormalClass interface { - Swigcptr() uintptr - SwigIsT_OuterClassInner2NormalClass() - SetEmbeddedVar(arg2 int) - GetEmbeddedVar() (_swig_ret int) - SwigIsT_NormalTemplateNormalClass() - SwigGetT_NormalTemplateNormalClass() T_NormalTemplateNormalClass -} - -type SwigcptrT_OuterClassInner2Int uintptr - -func (p SwigcptrT_OuterClassInner2Int) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrT_OuterClassInner2Int) SwigIsT_OuterClassInner2Int() { -} - -var _wrap_T_OuterClassInner2Int_embeddedVar_set unsafe.Pointer - -func _swig_wrap_T_OuterClassInner2Int_embeddedVar_set(base SwigcptrT_OuterClassInner2Int, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_T_OuterClassInner2Int_embeddedVar_set, _swig_p) - return -} - -func (arg1 SwigcptrT_OuterClassInner2Int) SetEmbeddedVar(arg2 int) { - _swig_wrap_T_OuterClassInner2Int_embeddedVar_set(arg1, arg2) -} - -var _wrap_T_OuterClassInner2Int_embeddedVar_get unsafe.Pointer - -func _swig_wrap_T_OuterClassInner2Int_embeddedVar_get(base SwigcptrT_OuterClassInner2Int) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_T_OuterClassInner2Int_embeddedVar_get, _swig_p) - return -} - -func (arg1 SwigcptrT_OuterClassInner2Int) GetEmbeddedVar() (_swig_ret int) { - return _swig_wrap_T_OuterClassInner2Int_embeddedVar_get(arg1) -} - -var _wrap_new_T_OuterClassInner2Int unsafe.Pointer - -func _swig_wrap_new_T_OuterClassInner2Int() (base SwigcptrT_OuterClassInner2Int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_T_OuterClassInner2Int, _swig_p) - return -} - -func NewT_OuterClassInner2Int() (_swig_ret T_OuterClassInner2Int) { - return _swig_wrap_new_T_OuterClassInner2Int() -} - -var _wrap_delete_T_OuterClassInner2Int unsafe.Pointer - -func _swig_wrap_delete_T_OuterClassInner2Int(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_T_OuterClassInner2Int, _swig_p) - return -} - -func DeleteT_OuterClassInner2Int(arg1 T_OuterClassInner2Int) { - _swig_wrap_delete_T_OuterClassInner2Int(arg1.Swigcptr()) -} - -func (p SwigcptrT_OuterClassInner2Int) SwigIsT_NormalTemplateInt() { -} - -func (p SwigcptrT_OuterClassInner2Int) SwigGetT_NormalTemplateInt() T_NormalTemplateInt { - return SwigcptrT_NormalTemplateInt(p.Swigcptr()) -} - -type T_OuterClassInner2Int interface { - Swigcptr() uintptr - SwigIsT_OuterClassInner2Int() - SetEmbeddedVar(arg2 int) - GetEmbeddedVar() (_swig_ret int) - SwigIsT_NormalTemplateInt() - SwigGetT_NormalTemplateInt() T_NormalTemplateInt -} - -type SwigcptrABC uintptr - -func (p SwigcptrABC) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrABC) SwigIsABC() { -} - -var _wrap_new_ABC unsafe.Pointer - -func _swig_wrap_new_ABC() (base SwigcptrABC) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_ABC, _swig_p) - return -} - -func NewABC() (_swig_ret ABC) { - return _swig_wrap_new_ABC() -} - -var _wrap_delete_ABC unsafe.Pointer - -func _swig_wrap_delete_ABC(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_ABC, _swig_p) - return -} - -func DeleteABC(arg1 ABC) { - _swig_wrap_delete_ABC(arg1.Swigcptr()) -} - -type ABC interface { - Swigcptr() uintptr - SwigIsABC() -} - -type SwigcptrTemplateFuncs uintptr - -func (p SwigcptrTemplateFuncs) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrTemplateFuncs) SwigIsTemplateFuncs() { -} - -var _wrap_TemplateFuncs_T_TemplateFuncs1Int unsafe.Pointer - -func _swig_wrap_TemplateFuncs_T_TemplateFuncs1Int(base SwigcptrTemplateFuncs, _ int) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_TemplateFuncs_T_TemplateFuncs1Int, _swig_p) - return -} - -func (arg1 SwigcptrTemplateFuncs) T_TemplateFuncs1Int(arg2 int) (_swig_ret int) { - return _swig_wrap_TemplateFuncs_T_TemplateFuncs1Int(arg1, arg2) -} - -var _wrap_TemplateFuncs_T_TemplateFuncs2Double unsafe.Pointer - -func _swig_wrap_TemplateFuncs_T_TemplateFuncs2Double(base SwigcptrTemplateFuncs, _ float64) (_ float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_TemplateFuncs_T_TemplateFuncs2Double, _swig_p) - return -} - -func (arg1 SwigcptrTemplateFuncs) T_TemplateFuncs2Double(arg2 float64) (_swig_ret float64) { - return _swig_wrap_TemplateFuncs_T_TemplateFuncs2Double(arg1, arg2) -} - -var _wrap_new_TemplateFuncs unsafe.Pointer - -func _swig_wrap_new_TemplateFuncs() (base SwigcptrTemplateFuncs) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_TemplateFuncs, _swig_p) - return -} - -func NewTemplateFuncs() (_swig_ret TemplateFuncs) { - return _swig_wrap_new_TemplateFuncs() -} - -var _wrap_delete_TemplateFuncs unsafe.Pointer - -func _swig_wrap_delete_TemplateFuncs(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_TemplateFuncs, _swig_p) - return -} - -func DeleteTemplateFuncs(arg1 TemplateFuncs) { - _swig_wrap_delete_TemplateFuncs(arg1.Swigcptr()) -} - -type TemplateFuncs interface { - Swigcptr() uintptr - SwigIsTemplateFuncs() - T_TemplateFuncs1Int(arg2 int) (_swig_ret int) - T_TemplateFuncs2Double(arg2 float64) (_swig_ret float64) -} - -type SwigcptrT_NestedOuterTemplateDouble uintptr - -func (p SwigcptrT_NestedOuterTemplateDouble) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrT_NestedOuterTemplateDouble) SwigIsT_NestedOuterTemplateDouble() { -} - -var _wrap_T_NestedOuterTemplateDouble_hohum unsafe.Pointer - -func _swig_wrap_T_NestedOuterTemplateDouble_hohum(base SwigcptrT_NestedOuterTemplateDouble, _ float64) (_ float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_T_NestedOuterTemplateDouble_hohum, _swig_p) - return -} - -func (arg1 SwigcptrT_NestedOuterTemplateDouble) Hohum(arg2 float64) (_swig_ret float64) { - return _swig_wrap_T_NestedOuterTemplateDouble_hohum(arg1, arg2) -} - -var _wrap_T_NestedOuterTemplateDouble_useNestedInnerTemplate1 unsafe.Pointer - -func _swig_wrap_T_NestedOuterTemplateDouble_useNestedInnerTemplate1(base SwigcptrT_NestedOuterTemplateDouble, _ uintptr) (_ SwigcptrNs_OuterTemplate_Sl_double_Sg__NestedInnerTemplate1_Sl_short_Sg_) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_T_NestedOuterTemplateDouble_useNestedInnerTemplate1, _swig_p) - return -} - -func (arg1 SwigcptrT_NestedOuterTemplateDouble) UseNestedInnerTemplate1(arg2 Ns_OuterTemplate_Sl_double_Sg__NestedInnerTemplate1_Sl_short_Sg_) (_swig_ret Ns_OuterTemplate_Sl_double_Sg__NestedInnerTemplate1_Sl_short_Sg_) { - return _swig_wrap_T_NestedOuterTemplateDouble_useNestedInnerTemplate1(arg1, arg2.Swigcptr()) -} - -var _wrap_T_NestedOuterTemplateDouble_useNestedInnerTemplate2 unsafe.Pointer - -func _swig_wrap_T_NestedOuterTemplateDouble_useNestedInnerTemplate2(base SwigcptrT_NestedOuterTemplateDouble, _ uintptr) (_ SwigcptrNs_OuterTemplate_Sl_double_Sg__NestedInnerTemplate2_Sl_short_Sg_) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_T_NestedOuterTemplateDouble_useNestedInnerTemplate2, _swig_p) - return -} - -func (arg1 SwigcptrT_NestedOuterTemplateDouble) UseNestedInnerTemplate2(arg2 Ns_OuterTemplate_Sl_double_Sg__NestedInnerTemplate2_Sl_short_Sg_) (_swig_ret Ns_OuterTemplate_Sl_double_Sg__NestedInnerTemplate2_Sl_short_Sg_) { - return _swig_wrap_T_NestedOuterTemplateDouble_useNestedInnerTemplate2(arg1, arg2.Swigcptr()) -} - -var _wrap_T_NestedOuterTemplateDouble_useNestedInnerTemplate3 unsafe.Pointer - -func _swig_wrap_T_NestedOuterTemplateDouble_useNestedInnerTemplate3(base SwigcptrT_NestedOuterTemplateDouble, _ uintptr) (_ SwigcptrNs_OuterTemplate_Sl_double_Sg__NestedInnerTemplate3_Sl_short_Sg_) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_T_NestedOuterTemplateDouble_useNestedInnerTemplate3, _swig_p) - return -} - -func (arg1 SwigcptrT_NestedOuterTemplateDouble) UseNestedInnerTemplate3(arg2 Ns_OuterTemplate_Sl_double_Sg__NestedInnerTemplate3_Sl_short_Sg_) (_swig_ret Ns_OuterTemplate_Sl_double_Sg__NestedInnerTemplate3_Sl_short_Sg_) { - return _swig_wrap_T_NestedOuterTemplateDouble_useNestedInnerTemplate3(arg1, arg2.Swigcptr()) -} - -var _wrap_T_NestedOuterTemplateDouble_useNestedStruct unsafe.Pointer - -func _swig_wrap_T_NestedOuterTemplateDouble_useNestedStruct(base SwigcptrT_NestedOuterTemplateDouble, _ uintptr) (_ SwigcptrNestedStruct) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_T_NestedOuterTemplateDouble_useNestedStruct, _swig_p) - return -} - -func (arg1 SwigcptrT_NestedOuterTemplateDouble) UseNestedStruct(arg2 NestedStruct) (_swig_ret NestedStruct) { - return _swig_wrap_T_NestedOuterTemplateDouble_useNestedStruct(arg1, arg2.Swigcptr()) -} - -var _wrap_new_T_NestedOuterTemplateDouble unsafe.Pointer - -func _swig_wrap_new_T_NestedOuterTemplateDouble() (base SwigcptrT_NestedOuterTemplateDouble) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_T_NestedOuterTemplateDouble, _swig_p) - return -} - -func NewT_NestedOuterTemplateDouble() (_swig_ret T_NestedOuterTemplateDouble) { - return _swig_wrap_new_T_NestedOuterTemplateDouble() -} - -var _wrap_delete_T_NestedOuterTemplateDouble unsafe.Pointer - -func _swig_wrap_delete_T_NestedOuterTemplateDouble(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_T_NestedOuterTemplateDouble, _swig_p) - return -} - -func DeleteT_NestedOuterTemplateDouble(arg1 T_NestedOuterTemplateDouble) { - _swig_wrap_delete_T_NestedOuterTemplateDouble(arg1.Swigcptr()) -} - -type T_NestedOuterTemplateDouble interface { - Swigcptr() uintptr - SwigIsT_NestedOuterTemplateDouble() - Hohum(arg2 float64) (_swig_ret float64) - UseNestedInnerTemplate1(arg2 Ns_OuterTemplate_Sl_double_Sg__NestedInnerTemplate1_Sl_short_Sg_) (_swig_ret Ns_OuterTemplate_Sl_double_Sg__NestedInnerTemplate1_Sl_short_Sg_) - UseNestedInnerTemplate2(arg2 Ns_OuterTemplate_Sl_double_Sg__NestedInnerTemplate2_Sl_short_Sg_) (_swig_ret Ns_OuterTemplate_Sl_double_Sg__NestedInnerTemplate2_Sl_short_Sg_) - UseNestedInnerTemplate3(arg2 Ns_OuterTemplate_Sl_double_Sg__NestedInnerTemplate3_Sl_short_Sg_) (_swig_ret Ns_OuterTemplate_Sl_double_Sg__NestedInnerTemplate3_Sl_short_Sg_) - UseNestedStruct(arg2 NestedStruct) (_swig_ret NestedStruct) -} - -type SwigcptrNestedStruct uintptr - -func (p SwigcptrNestedStruct) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrNestedStruct) SwigIsNestedStruct() { -} - -var _wrap_new_NestedStruct unsafe.Pointer - -func _swig_wrap_new_NestedStruct() (base SwigcptrNestedStruct) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_NestedStruct, _swig_p) - return -} - -func NewNestedStruct() (_swig_ret NestedStruct) { - return _swig_wrap_new_NestedStruct() -} - -var _wrap_NestedStruct_hohum unsafe.Pointer - -func _swig_wrap_NestedStruct_hohum(base SwigcptrNestedStruct) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_NestedStruct_hohum, _swig_p) - return -} - -func (arg1 SwigcptrNestedStruct) Hohum() { - _swig_wrap_NestedStruct_hohum(arg1) -} - -var _wrap_delete_NestedStruct unsafe.Pointer - -func _swig_wrap_delete_NestedStruct(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_NestedStruct, _swig_p) - return -} - -func DeleteNestedStruct(arg1 NestedStruct) { - _swig_wrap_delete_NestedStruct(arg1.Swigcptr()) -} - -type NestedStruct interface { - Swigcptr() uintptr - SwigIsNestedStruct() - Hohum() -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - -type SwigcptrNs_OuterTemplate_Sl_double_Sg__NestedInnerTemplate3_Sl_short_Sg_ uintptr -type Ns_OuterTemplate_Sl_double_Sg__NestedInnerTemplate3_Sl_short_Sg_ interface { - Swigcptr() uintptr; -} -func (p SwigcptrNs_OuterTemplate_Sl_double_Sg__NestedInnerTemplate3_Sl_short_Sg_) Swigcptr() uintptr { - return uintptr(p) -} - -type SwigcptrNs_OuterTemplate_Sl_double_Sg__NestedInnerTemplate2_Sl_short_Sg_ uintptr -type Ns_OuterTemplate_Sl_double_Sg__NestedInnerTemplate2_Sl_short_Sg_ interface { - Swigcptr() uintptr; -} -func (p SwigcptrNs_OuterTemplate_Sl_double_Sg__NestedInnerTemplate2_Sl_short_Sg_) Swigcptr() uintptr { - return uintptr(p) -} - -type SwigcptrNs_OuterTemplate_Sl_double_Sg__NestedInnerTemplate1_Sl_short_Sg_ uintptr -type Ns_OuterTemplate_Sl_double_Sg__NestedInnerTemplate1_Sl_short_Sg_ interface { - Swigcptr() uintptr; -} -func (p SwigcptrNs_OuterTemplate_Sl_double_Sg__NestedInnerTemplate1_Sl_short_Sg_) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/template_nested_typemaps.go b/Examples/test-suite/go/template_nested_typemaps.go deleted file mode 100644 index 4b6ee25fb..000000000 --- a/Examples/test-suite/go/template_nested_typemaps.go +++ /dev/null @@ -1,182 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../template_nested_typemaps.i - -package template_nested_typemaps - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -var _wrap_globalInt1 unsafe.Pointer - -func GlobalInt1(arg1 int) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_globalInt1, _swig_p) - return -} -var _wrap_globalShort1 unsafe.Pointer - -func GlobalShort1(arg1 int16) (_swig_ret int16) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_globalShort1, _swig_p) - return -} -var _wrap_globalInt2 unsafe.Pointer - -func GlobalInt2(arg1 int) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_globalInt2, _swig_p) - return -} -var _wrap_globalShort2 unsafe.Pointer - -func GlobalShort2(arg1 int16) (_swig_ret int16) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_globalShort2, _swig_p) - return -} -type SwigcptrBreezeString uintptr - -func (p SwigcptrBreezeString) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrBreezeString) SwigIsBreezeString() { -} - -var _wrap_BreezeString_methodInt1 unsafe.Pointer - -func _swig_wrap_BreezeString_methodInt1(base SwigcptrBreezeString, _ int) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_BreezeString_methodInt1, _swig_p) - return -} - -func (arg1 SwigcptrBreezeString) MethodInt1(arg2 int) (_swig_ret int) { - return _swig_wrap_BreezeString_methodInt1(arg1, arg2) -} - -var _wrap_BreezeString_methodInt2 unsafe.Pointer - -func _swig_wrap_BreezeString_methodInt2(base SwigcptrBreezeString, _ int) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_BreezeString_methodInt2, _swig_p) - return -} - -func (arg1 SwigcptrBreezeString) MethodInt2(arg2 int) (_swig_ret int) { - return _swig_wrap_BreezeString_methodInt2(arg1, arg2) -} - -var _wrap_BreezeString_takeIt unsafe.Pointer - -func _swig_wrap_BreezeString_takeIt(base SwigcptrBreezeString, _ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_BreezeString_takeIt, _swig_p) - return -} - -func (arg1 SwigcptrBreezeString) TakeIt(arg2 string) { - _swig_wrap_BreezeString_takeIt(arg1, arg2) -} - -var _wrap_BreezeString_methodShort1 unsafe.Pointer - -func _swig_wrap_BreezeString_methodShort1(base SwigcptrBreezeString, _ int16) (_ int16) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_BreezeString_methodShort1, _swig_p) - return -} - -func (arg1 SwigcptrBreezeString) MethodShort1(arg2 int16) (_swig_ret int16) { - return _swig_wrap_BreezeString_methodShort1(arg1, arg2) -} - -var _wrap_BreezeString_methodShort2 unsafe.Pointer - -func _swig_wrap_BreezeString_methodShort2(base SwigcptrBreezeString, _ int16) (_ int16) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_BreezeString_methodShort2, _swig_p) - return -} - -func (arg1 SwigcptrBreezeString) MethodShort2(arg2 int16) (_swig_ret int16) { - return _swig_wrap_BreezeString_methodShort2(arg1, arg2) -} - -var _wrap_new_BreezeString unsafe.Pointer - -func _swig_wrap_new_BreezeString() (base SwigcptrBreezeString) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_BreezeString, _swig_p) - return -} - -func NewBreezeString() (_swig_ret BreezeString) { - return _swig_wrap_new_BreezeString() -} - -var _wrap_delete_BreezeString unsafe.Pointer - -func _swig_wrap_delete_BreezeString(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_BreezeString, _swig_p) - return -} - -func DeleteBreezeString(arg1 BreezeString) { - _swig_wrap_delete_BreezeString(arg1.Swigcptr()) -} - -type BreezeString interface { - Swigcptr() uintptr - SwigIsBreezeString() - MethodInt1(arg2 int) (_swig_ret int) - MethodInt2(arg2 int) (_swig_ret int) - TakeIt(arg2 string) - MethodShort1(arg2 int16) (_swig_ret int16) - MethodShort2(arg2 int16) (_swig_ret int16) -} - -var _wrap_globalInt3 unsafe.Pointer - -func GlobalInt3(arg1 int) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_globalInt3, _swig_p) - return -} -var _wrap_globalShort3 unsafe.Pointer - -func GlobalShort3(arg1 int16) (_swig_ret int16) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_globalShort3, _swig_p) - return -} - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/template_ns.go b/Examples/test-suite/go/template_ns.go deleted file mode 100644 index d4b268d58..000000000 --- a/Examples/test-suite/go/template_ns.go +++ /dev/null @@ -1,263 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../template_ns.i - -package template_ns - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrPairii uintptr - -func (p SwigcptrPairii) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrPairii) SwigIsPairii() { -} - -var _wrap_pairii_first_set unsafe.Pointer - -func _swig_wrap_pairii_first_set(base SwigcptrPairii, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_pairii_first_set, _swig_p) - return -} - -func (arg1 SwigcptrPairii) SetFirst(arg2 int) { - _swig_wrap_pairii_first_set(arg1, arg2) -} - -var _wrap_pairii_first_get unsafe.Pointer - -func _swig_wrap_pairii_first_get(base SwigcptrPairii) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_pairii_first_get, _swig_p) - return -} - -func (arg1 SwigcptrPairii) GetFirst() (_swig_ret int) { - return _swig_wrap_pairii_first_get(arg1) -} - -var _wrap_pairii_second_set unsafe.Pointer - -func _swig_wrap_pairii_second_set(base SwigcptrPairii, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_pairii_second_set, _swig_p) - return -} - -func (arg1 SwigcptrPairii) SetSecond(arg2 int) { - _swig_wrap_pairii_second_set(arg1, arg2) -} - -var _wrap_pairii_second_get unsafe.Pointer - -func _swig_wrap_pairii_second_get(base SwigcptrPairii) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_pairii_second_get, _swig_p) - return -} - -func (arg1 SwigcptrPairii) GetSecond() (_swig_ret int) { - return _swig_wrap_pairii_second_get(arg1) -} - -var _wrap_new_pairii__SWIG_0 unsafe.Pointer - -func _swig_wrap_new_pairii__SWIG_0(base int, _ int) (_ SwigcptrPairii) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_pairii__SWIG_0, _swig_p) - return -} - -func NewPairii__SWIG_0(arg1 int, arg2 int) (_swig_ret Pairii) { - return _swig_wrap_new_pairii__SWIG_0(arg1, arg2) -} - -var _wrap_new_pairii__SWIG_1 unsafe.Pointer - -func _swig_wrap_new_pairii__SWIG_1(base uintptr) (_ SwigcptrPairii) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_pairii__SWIG_1, _swig_p) - return -} - -func NewPairii__SWIG_1(arg1 Pairii) (_swig_ret Pairii) { - return _swig_wrap_new_pairii__SWIG_1(arg1.Swigcptr()) -} - -func NewPairii(a ...interface{}) Pairii { - argc := len(a) - if argc == 1 { - return NewPairii__SWIG_1(a[0].(Pairii)) - } - if argc == 2 { - return NewPairii__SWIG_0(a[0].(int), a[1].(int)) - } - panic("No match for overloaded function call") -} - -var _wrap_delete_pairii unsafe.Pointer - -func _swig_wrap_delete_pairii(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_pairii, _swig_p) - return -} - -func DeletePairii(arg1 Pairii) { - _swig_wrap_delete_pairii(arg1.Swigcptr()) -} - -type Pairii interface { - Swigcptr() uintptr - SwigIsPairii() - SetFirst(arg2 int) - GetFirst() (_swig_ret int) - SetSecond(arg2 int) - GetSecond() (_swig_ret int) -} - -type SwigcptrPairdd uintptr - -func (p SwigcptrPairdd) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrPairdd) SwigIsPairdd() { -} - -var _wrap_pairdd_first_set unsafe.Pointer - -func _swig_wrap_pairdd_first_set(base SwigcptrPairdd, _ float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_pairdd_first_set, _swig_p) - return -} - -func (arg1 SwigcptrPairdd) SetFirst(arg2 float64) { - _swig_wrap_pairdd_first_set(arg1, arg2) -} - -var _wrap_pairdd_first_get unsafe.Pointer - -func _swig_wrap_pairdd_first_get(base SwigcptrPairdd) (_ float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_pairdd_first_get, _swig_p) - return -} - -func (arg1 SwigcptrPairdd) GetFirst() (_swig_ret float64) { - return _swig_wrap_pairdd_first_get(arg1) -} - -var _wrap_pairdd_second_set unsafe.Pointer - -func _swig_wrap_pairdd_second_set(base SwigcptrPairdd, _ float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_pairdd_second_set, _swig_p) - return -} - -func (arg1 SwigcptrPairdd) SetSecond(arg2 float64) { - _swig_wrap_pairdd_second_set(arg1, arg2) -} - -var _wrap_pairdd_second_get unsafe.Pointer - -func _swig_wrap_pairdd_second_get(base SwigcptrPairdd) (_ float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_pairdd_second_get, _swig_p) - return -} - -func (arg1 SwigcptrPairdd) GetSecond() (_swig_ret float64) { - return _swig_wrap_pairdd_second_get(arg1) -} - -var _wrap_new_pairdd__SWIG_0 unsafe.Pointer - -func _swig_wrap_new_pairdd__SWIG_0(base float64, _ float64) (_ SwigcptrPairdd) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_pairdd__SWIG_0, _swig_p) - return -} - -func NewPairdd__SWIG_0(arg1 float64, arg2 float64) (_swig_ret Pairdd) { - return _swig_wrap_new_pairdd__SWIG_0(arg1, arg2) -} - -var _wrap_new_pairdd__SWIG_1 unsafe.Pointer - -func _swig_wrap_new_pairdd__SWIG_1(base uintptr) (_ SwigcptrPairdd) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_pairdd__SWIG_1, _swig_p) - return -} - -func NewPairdd__SWIG_1(arg1 Pairdd) (_swig_ret Pairdd) { - return _swig_wrap_new_pairdd__SWIG_1(arg1.Swigcptr()) -} - -func NewPairdd(a ...interface{}) Pairdd { - argc := len(a) - if argc == 1 { - return NewPairdd__SWIG_1(a[0].(Pairdd)) - } - if argc == 2 { - return NewPairdd__SWIG_0(a[0].(float64), a[1].(float64)) - } - panic("No match for overloaded function call") -} - -var _wrap_delete_pairdd unsafe.Pointer - -func _swig_wrap_delete_pairdd(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_pairdd, _swig_p) - return -} - -func DeletePairdd(arg1 Pairdd) { - _swig_wrap_delete_pairdd(arg1.Swigcptr()) -} - -type Pairdd interface { - Swigcptr() uintptr - SwigIsPairdd() - SetFirst(arg2 float64) - GetFirst() (_swig_ret float64) - SetSecond(arg2 float64) - GetSecond() (_swig_ret float64) -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/template_ns2.go b/Examples/test-suite/go/template_ns2.go deleted file mode 100644 index 6c592006d..000000000 --- a/Examples/test-suite/go/template_ns2.go +++ /dev/null @@ -1,69 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../template_ns2.i - -package template_ns2 - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -var _wrap_test1 unsafe.Pointer - -func _swig_wrap_test1(base uintptr) (_ SwigcptrFoo_bar_Sl_int_Sg_) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_test1, _swig_p) - return -} - -func Test1(arg1 Foo_bar_Sl_int_Sg_) (_swig_ret Foo_bar_Sl_int_Sg_) { - return _swig_wrap_test1(arg1.Swigcptr()) -} - -var _wrap_test2 unsafe.Pointer - -func _swig_wrap_test2(base uintptr) (_ SwigcptrFoo_bar_Sl_int_Sm__Sg_) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_test2, _swig_p) - return -} - -func Test2(arg1 Foo_bar_Sl_int_Sm__Sg_) (_swig_ret Foo_bar_Sl_int_Sm__Sg_) { - return _swig_wrap_test2(arg1.Swigcptr()) -} - - -type SwigcptrFoo_bar_Sl_int_Sm__Sg_ uintptr -type Foo_bar_Sl_int_Sm__Sg_ interface { - Swigcptr() uintptr; -} -func (p SwigcptrFoo_bar_Sl_int_Sm__Sg_) Swigcptr() uintptr { - return uintptr(p) -} - -type SwigcptrFoo_bar_Sl_int_Sg_ uintptr -type Foo_bar_Sl_int_Sg_ interface { - Swigcptr() uintptr; -} -func (p SwigcptrFoo_bar_Sl_int_Sg_) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/template_ns3.go b/Examples/test-suite/go/template_ns3.go deleted file mode 100644 index 41844f4db..000000000 --- a/Examples/test-suite/go/template_ns3.go +++ /dev/null @@ -1,88 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../template_ns3.i - -package template_ns3 - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrBari uintptr - -func (p SwigcptrBari) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrBari) SwigIsBari() { -} - -var _wrap_bari_test unsafe.Pointer - -func _swig_wrap_bari_test(base SwigcptrBari, _ int) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_bari_test, _swig_p) - return -} - -func (arg1 SwigcptrBari) Test(arg2 int) (_swig_ret int) { - return _swig_wrap_bari_test(arg1, arg2) -} - -var _wrap_new_bari unsafe.Pointer - -func _swig_wrap_new_bari() (base SwigcptrBari) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_bari, _swig_p) - return -} - -func NewBari() (_swig_ret Bari) { - return _swig_wrap_new_bari() -} - -var _wrap_delete_bari unsafe.Pointer - -func _swig_wrap_delete_bari(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_bari, _swig_p) - return -} - -func DeleteBari(arg1 Bari) { - _swig_wrap_delete_bari(arg1.Swigcptr()) -} - -type Bari interface { - Swigcptr() uintptr - SwigIsBari() - Test(arg2 int) (_swig_ret int) -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/template_ns4.go b/Examples/test-suite/go/template_ns4.go deleted file mode 100644 index e21230ff3..000000000 --- a/Examples/test-suite/go/template_ns4.go +++ /dev/null @@ -1,267 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../template_ns4.i - -package template_ns4 - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrDouble uintptr - -func (p SwigcptrDouble) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrDouble) SwigIsDouble() { -} - -var _wrap_new_Double unsafe.Pointer - -func _swig_wrap_new_Double() (base SwigcptrDouble) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Double, _swig_p) - return -} - -func NewDouble() (_swig_ret Double) { - return _swig_wrap_new_Double() -} - -var _wrap_delete_Double unsafe.Pointer - -func _swig_wrap_delete_Double(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Double, _swig_p) - return -} - -func DeleteDouble(arg1 Double) { - _swig_wrap_delete_Double(arg1.Swigcptr()) -} - -type Double interface { - Swigcptr() uintptr - SwigIsDouble() -} - -type SwigcptrFunction_DD uintptr - -func (p SwigcptrFunction_DD) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrFunction_DD) SwigIsFunction_DD() { -} - -var _wrap_Function_DD_test unsafe.Pointer - -func _swig_wrap_Function_DD_test(base SwigcptrFunction_DD) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Function_DD_test, _swig_p) - return -} - -func (arg1 SwigcptrFunction_DD) Test() (_swig_ret string) { - return _swig_wrap_Function_DD_test(arg1) -} - -var _wrap_new_Function_DD unsafe.Pointer - -func _swig_wrap_new_Function_DD() (base SwigcptrFunction_DD) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Function_DD, _swig_p) - return -} - -func NewFunction_DD() (_swig_ret Function_DD) { - return _swig_wrap_new_Function_DD() -} - -var _wrap_delete_Function_DD unsafe.Pointer - -func _swig_wrap_delete_Function_DD(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Function_DD, _swig_p) - return -} - -func DeleteFunction_DD(arg1 Function_DD) { - _swig_wrap_delete_Function_DD(arg1.Swigcptr()) -} - -type Function_DD interface { - Swigcptr() uintptr - SwigIsFunction_DD() - Test() (_swig_ret string) -} - -type SwigcptrArithFunction_DD uintptr - -func (p SwigcptrArithFunction_DD) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrArithFunction_DD) SwigIsArithFunction_DD() { -} - -var _wrap_new_ArithFunction_DD unsafe.Pointer - -func _swig_wrap_new_ArithFunction_DD() (base SwigcptrArithFunction_DD) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_ArithFunction_DD, _swig_p) - return -} - -func NewArithFunction_DD() (_swig_ret ArithFunction_DD) { - return _swig_wrap_new_ArithFunction_DD() -} - -var _wrap_delete_ArithFunction_DD unsafe.Pointer - -func _swig_wrap_delete_ArithFunction_DD(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_ArithFunction_DD, _swig_p) - return -} - -func DeleteArithFunction_DD(arg1 ArithFunction_DD) { - _swig_wrap_delete_ArithFunction_DD(arg1.Swigcptr()) -} - -var _wrap_ArithFunction_DD_test unsafe.Pointer - -func _swig_wrap_ArithFunction_DD_test(base SwigcptrArithFunction_DD) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_ArithFunction_DD_test, _swig_p) - return -} - -func (_swig_base SwigcptrArithFunction_DD) Test() (_swig_ret string) { - return _swig_wrap_ArithFunction_DD_test(_swig_base) -} - -func (p SwigcptrArithFunction_DD) SwigIsFunction_DD() { -} - -func (p SwigcptrArithFunction_DD) SwigGetFunction_DD() Function_DD { - return SwigcptrFunction_DD(p.Swigcptr()) -} - -type ArithFunction_DD interface { - Swigcptr() uintptr - SwigIsArithFunction_DD() - Test() (_swig_ret string) - SwigIsFunction_DD() - SwigGetFunction_DD() Function_DD -} - -type SwigcptrClass_DD uintptr - -func (p SwigcptrClass_DD) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrClass_DD) SwigIsClass_DD() { -} - -var _wrap_new_Class_DD unsafe.Pointer - -func _swig_wrap_new_Class_DD() (base SwigcptrClass_DD) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Class_DD, _swig_p) - return -} - -func NewClass_DD() (_swig_ret Class_DD) { - return _swig_wrap_new_Class_DD() -} - -var _wrap_delete_Class_DD unsafe.Pointer - -func _swig_wrap_delete_Class_DD(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Class_DD, _swig_p) - return -} - -func DeleteClass_DD(arg1 Class_DD) { - _swig_wrap_delete_Class_DD(arg1.Swigcptr()) -} - -var _wrap_Class_DD_test unsafe.Pointer - -func _swig_wrap_Class_DD_test(base SwigcptrClass_DD) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Class_DD_test, _swig_p) - return -} - -func (_swig_base SwigcptrClass_DD) Test() (_swig_ret string) { - return _swig_wrap_Class_DD_test(_swig_base) -} - -func (p SwigcptrClass_DD) SwigIsArithFunction_DD() { -} - -func (p SwigcptrClass_DD) SwigGetArithFunction_DD() ArithFunction_DD { - return SwigcptrArithFunction_DD(p.Swigcptr()) -} - -func (p SwigcptrClass_DD) SwigIsFunction_DD() { -} - -func (p SwigcptrClass_DD) SwigGetFunction_DD() Function_DD { - return SwigcptrFunction_DD(p.Swigcptr()) -} - -type Class_DD interface { - Swigcptr() uintptr - SwigIsClass_DD() - Test() (_swig_ret string) - SwigIsArithFunction_DD() - SwigGetArithFunction_DD() ArithFunction_DD - SwigIsFunction_DD() - SwigGetFunction_DD() Function_DD -} - -var _wrap_make_Class_DD unsafe.Pointer - -func _swig_wrap_make_Class_DD() (base SwigcptrArithFunction_DD) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_make_Class_DD, _swig_p) - return -} - -func Make_Class_DD() (_swig_ret ArithFunction_DD) { - return _swig_wrap_make_Class_DD() -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/template_ns4_runme b/Examples/test-suite/go/template_ns4_runme deleted file mode 100755 index a6829a6d0..000000000 Binary files a/Examples/test-suite/go/template_ns4_runme and /dev/null differ diff --git a/Examples/test-suite/go/template_ns_enum.go b/Examples/test-suite/go/template_ns_enum.go deleted file mode 100644 index 5d5eac73f..000000000 --- a/Examples/test-suite/go/template_ns_enum.go +++ /dev/null @@ -1,66 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../template_ns_enum.i - -package template_ns_enum - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type HelloHello int -var _wrap_Hi unsafe.Pointer - -func _swig_getHi() (_swig_ret HelloHello) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_Hi, _swig_p) - return -} -var Hi HelloHello = _swig_getHi() -var _wrap_Hola unsafe.Pointer - -func _swig_getHola() (_swig_ret HelloHello) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_Hola, _swig_p) - return -} -var Hola HelloHello = _swig_getHola() -var _wrap_say_hi unsafe.Pointer - -func _swig_wrap_say_hi() (base SwigcptrHello_traits_Sl_hello_Hi_Sg__value_type) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_say_hi, _swig_p) - return -} - -func Say_hi() (_swig_ret Hello_traits_Sl_hello_Hi_Sg__value_type) { - return _swig_wrap_say_hi() -} - - -type SwigcptrHello_traits_Sl_hello_Hi_Sg__value_type uintptr -type Hello_traits_Sl_hello_Hi_Sg__value_type interface { - Swigcptr() uintptr; -} -func (p SwigcptrHello_traits_Sl_hello_Hi_Sg__value_type) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/template_ns_enum2.go b/Examples/test-suite/go/template_ns_enum2.go deleted file mode 100644 index c82e3e771..000000000 --- a/Examples/test-suite/go/template_ns_enum2.go +++ /dev/null @@ -1,113 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../template_ns_enum2.i - -package template_ns_enum2 - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type HiHello int -var _wrap_Hi unsafe.Pointer - -func _swig_getHi() (_swig_ret HiHello) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_Hi, _swig_p) - return -} -var Hi HiHello = _swig_getHi() -var _wrap_Hola unsafe.Pointer - -func _swig_getHola() (_swig_ret HiHello) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_Hola, _swig_p) - return -} -var Hola HiHello = _swig_getHola() -type SwigcptrB uintptr - -func (p SwigcptrB) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrB) SwigIsB() { -} - -var _wrap_B_evaluate unsafe.Pointer - -func _swig_wrap_B_evaluate(base SwigcptrB, _ uintptr) (_ SwigcptrHi_traits_Sl_hi_Hola_Sg__value_type) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_B_evaluate, _swig_p) - return -} - -func (arg1 SwigcptrB) Evaluate(arg2 Hi_traits_Sl_hi_Hola_Sg__value_type) (_swig_ret Hi_traits_Sl_hi_Hola_Sg__value_type) { - return _swig_wrap_B_evaluate(arg1, arg2.Swigcptr()) -} - -var _wrap_new_B unsafe.Pointer - -func _swig_wrap_new_B() (base SwigcptrB) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_B, _swig_p) - return -} - -func NewB() (_swig_ret B) { - return _swig_wrap_new_B() -} - -var _wrap_delete_B unsafe.Pointer - -func _swig_wrap_delete_B(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_B, _swig_p) - return -} - -func DeleteB(arg1 B) { - _swig_wrap_delete_B(arg1.Swigcptr()) -} - -type B interface { - Swigcptr() uintptr - SwigIsB() - Evaluate(arg2 Hi_traits_Sl_hi_Hola_Sg__value_type) (_swig_ret Hi_traits_Sl_hi_Hola_Sg__value_type) -} - - -type SwigcptrHi_traits_Sl_hi_Hola_Sg__value_type uintptr -type Hi_traits_Sl_hi_Hola_Sg__value_type interface { - Swigcptr() uintptr; -} -func (p SwigcptrHi_traits_Sl_hi_Hola_Sg__value_type) Swigcptr() uintptr { - return uintptr(p) -} - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/template_ns_inherit.go b/Examples/test-suite/go/template_ns_inherit.go deleted file mode 100644 index 219432a15..000000000 --- a/Examples/test-suite/go/template_ns_inherit.go +++ /dev/null @@ -1,122 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../template_ns_inherit.i - -package template_ns_inherit - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrVUnaryFunction_id uintptr - -func (p SwigcptrVUnaryFunction_id) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrVUnaryFunction_id) SwigIsVUnaryFunction_id() { -} - -var _wrap_new_VUnaryFunction_id unsafe.Pointer - -func _swig_wrap_new_VUnaryFunction_id() (base SwigcptrVUnaryFunction_id) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_VUnaryFunction_id, _swig_p) - return -} - -func NewVUnaryFunction_id() (_swig_ret VUnaryFunction_id) { - return _swig_wrap_new_VUnaryFunction_id() -} - -var _wrap_delete_VUnaryFunction_id unsafe.Pointer - -func _swig_wrap_delete_VUnaryFunction_id(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_VUnaryFunction_id, _swig_p) - return -} - -func DeleteVUnaryFunction_id(arg1 VUnaryFunction_id) { - _swig_wrap_delete_VUnaryFunction_id(arg1.Swigcptr()) -} - -type VUnaryFunction_id interface { - Swigcptr() uintptr - SwigIsVUnaryFunction_id() -} - -type SwigcptrUnaryFunction_id uintptr - -func (p SwigcptrUnaryFunction_id) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrUnaryFunction_id) SwigIsUnaryFunction_id() { -} - -var _wrap_new_UnaryFunction_id unsafe.Pointer - -func _swig_wrap_new_UnaryFunction_id() (base SwigcptrUnaryFunction_id) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_UnaryFunction_id, _swig_p) - return -} - -func NewUnaryFunction_id() (_swig_ret UnaryFunction_id) { - return _swig_wrap_new_UnaryFunction_id() -} - -var _wrap_delete_UnaryFunction_id unsafe.Pointer - -func _swig_wrap_delete_UnaryFunction_id(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_UnaryFunction_id, _swig_p) - return -} - -func DeleteUnaryFunction_id(arg1 UnaryFunction_id) { - _swig_wrap_delete_UnaryFunction_id(arg1.Swigcptr()) -} - -func (p SwigcptrUnaryFunction_id) SwigIsVUnaryFunction_id() { -} - -func (p SwigcptrUnaryFunction_id) SwigGetVUnaryFunction_id() VUnaryFunction_id { - return SwigcptrVUnaryFunction_id(p.Swigcptr()) -} - -type UnaryFunction_id interface { - Swigcptr() uintptr - SwigIsUnaryFunction_id() - SwigIsVUnaryFunction_id() - SwigGetVUnaryFunction_id() VUnaryFunction_id -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/template_ns_runme b/Examples/test-suite/go/template_ns_runme deleted file mode 100755 index 03b5d5494..000000000 Binary files a/Examples/test-suite/go/template_ns_runme and /dev/null differ diff --git a/Examples/test-suite/go/template_ns_scope.go b/Examples/test-suite/go/template_ns_scope.go deleted file mode 100644 index 17ad559f8..000000000 --- a/Examples/test-suite/go/template_ns_scope.go +++ /dev/null @@ -1,152 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../template_ns_scope.i - -package template_ns_scope - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type HiHello int -var _wrap_Hi unsafe.Pointer - -func _swig_getHi() (_swig_ret HiHello) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_Hi, _swig_p) - return -} -var Hi HiHello = _swig_getHi() -var _wrap_Hola unsafe.Pointer - -func _swig_getHola() (_swig_ret HiHello) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_Hola, _swig_p) - return -} -var Hola HiHello = _swig_getHola() -type SwigcptrA_Hi uintptr - -func (p SwigcptrA_Hi) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrA_Hi) SwigIsA_Hi() { -} - -var _wrap_new_A_Hi unsafe.Pointer - -func _swig_wrap_new_A_Hi() (base SwigcptrA_Hi) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_A_Hi, _swig_p) - return -} - -func NewA_Hi() (_swig_ret A_Hi) { - return _swig_wrap_new_A_Hi() -} - -var _wrap_delete_A_Hi unsafe.Pointer - -func _swig_wrap_delete_A_Hi(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_A_Hi, _swig_p) - return -} - -func DeleteA_Hi(arg1 A_Hi) { - _swig_wrap_delete_A_Hi(arg1.Swigcptr()) -} - -type A_Hi interface { - Swigcptr() uintptr - SwigIsA_Hi() -} - -type SwigcptrB_Hi uintptr - -func (p SwigcptrB_Hi) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrB_Hi) SwigIsB_Hi() { -} - -var _wrap_B_Hi_say_hi unsafe.Pointer - -func _swig_wrap_B_Hi_say_hi(base SwigcptrB_Hi) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_B_Hi_say_hi, _swig_p) - return -} - -func (arg1 SwigcptrB_Hi) Say_hi() (_swig_ret int) { - return _swig_wrap_B_Hi_say_hi(arg1) -} - -var _wrap_new_B_Hi unsafe.Pointer - -func _swig_wrap_new_B_Hi() (base SwigcptrB_Hi) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_B_Hi, _swig_p) - return -} - -func NewB_Hi() (_swig_ret B_Hi) { - return _swig_wrap_new_B_Hi() -} - -var _wrap_delete_B_Hi unsafe.Pointer - -func _swig_wrap_delete_B_Hi(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_B_Hi, _swig_p) - return -} - -func DeleteB_Hi(arg1 B_Hi) { - _swig_wrap_delete_B_Hi(arg1.Swigcptr()) -} - -func (p SwigcptrB_Hi) SwigIsA_Hi() { -} - -func (p SwigcptrB_Hi) SwigGetA_Hi() A_Hi { - return SwigcptrA_Hi(p.Swigcptr()) -} - -type B_Hi interface { - Swigcptr() uintptr - SwigIsB_Hi() - Say_hi() (_swig_ret int) - SwigIsA_Hi() - SwigGetA_Hi() A_Hi -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/template_opaque.go b/Examples/test-suite/go/template_opaque.go deleted file mode 100644 index c69b80297..000000000 --- a/Examples/test-suite/go/template_opaque.go +++ /dev/null @@ -1,259 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../template_opaque.i - -package template_opaque - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -var _wrap_FillVector__SWIG_0 unsafe.Pointer - -func _swig_wrap_FillVector__SWIG_0(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_FillVector__SWIG_0, _swig_p) - return -} - -func FillVector__SWIG_0(arg1 OpaqueVectorType) { - _swig_wrap_FillVector__SWIG_0(arg1.Swigcptr()) -} - -var _wrap_FillVector__SWIG_1 unsafe.Pointer - -func _swig_wrap_FillVector__SWIG_1(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_FillVector__SWIG_1, _swig_p) - return -} - -func FillVector__SWIG_1(arg1 Std_vector_Sl_enum_SS_Hello_Sg_) { - _swig_wrap_FillVector__SWIG_1(arg1.Swigcptr()) -} - -func FillVector(a ...interface{}) { - argc := len(a) - if argc == 1 { - if _, ok := a[0].(OpaqueVectorType); !ok { - goto check_1 - } - FillVector__SWIG_0(a[0].(OpaqueVectorType)) - return - } -check_1: - if argc == 1 { - FillVector__SWIG_1(a[0].(Std_vector_Sl_enum_SS_Hello_Sg_)) - return - } - panic("No match for overloaded function call") -} - -type SwigcptrOpaqueVectorType uintptr - -func (p SwigcptrOpaqueVectorType) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrOpaqueVectorType) SwigIsOpaqueVectorType() { -} - -var _wrap_new_OpaqueVectorType__SWIG_0 unsafe.Pointer - -func _swig_wrap_new_OpaqueVectorType__SWIG_0() (base SwigcptrOpaqueVectorType) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_OpaqueVectorType__SWIG_0, _swig_p) - return -} - -func NewOpaqueVectorType__SWIG_0() (_swig_ret OpaqueVectorType) { - return _swig_wrap_new_OpaqueVectorType__SWIG_0() -} - -var _wrap_new_OpaqueVectorType__SWIG_1 unsafe.Pointer - -func _swig_wrap_new_OpaqueVectorType__SWIG_1(base int64) (_ SwigcptrOpaqueVectorType) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_OpaqueVectorType__SWIG_1, _swig_p) - return -} - -func NewOpaqueVectorType__SWIG_1(arg1 int64) (_swig_ret OpaqueVectorType) { - return _swig_wrap_new_OpaqueVectorType__SWIG_1(arg1) -} - -func NewOpaqueVectorType(a ...interface{}) OpaqueVectorType { - argc := len(a) - if argc == 0 { - return NewOpaqueVectorType__SWIG_0() - } - if argc == 1 { - return NewOpaqueVectorType__SWIG_1(a[0].(int64)) - } - panic("No match for overloaded function call") -} - -var _wrap_OpaqueVectorType_size unsafe.Pointer - -func _swig_wrap_OpaqueVectorType_size(base SwigcptrOpaqueVectorType) (_ int64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_OpaqueVectorType_size, _swig_p) - return -} - -func (arg1 SwigcptrOpaqueVectorType) Size() (_swig_ret int64) { - return _swig_wrap_OpaqueVectorType_size(arg1) -} - -var _wrap_OpaqueVectorType_capacity unsafe.Pointer - -func _swig_wrap_OpaqueVectorType_capacity(base SwigcptrOpaqueVectorType) (_ int64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_OpaqueVectorType_capacity, _swig_p) - return -} - -func (arg1 SwigcptrOpaqueVectorType) Capacity() (_swig_ret int64) { - return _swig_wrap_OpaqueVectorType_capacity(arg1) -} - -var _wrap_OpaqueVectorType_reserve unsafe.Pointer - -func _swig_wrap_OpaqueVectorType_reserve(base SwigcptrOpaqueVectorType, _ int64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_OpaqueVectorType_reserve, _swig_p) - return -} - -func (arg1 SwigcptrOpaqueVectorType) Reserve(arg2 int64) { - _swig_wrap_OpaqueVectorType_reserve(arg1, arg2) -} - -var _wrap_OpaqueVectorType_isEmpty unsafe.Pointer - -func _swig_wrap_OpaqueVectorType_isEmpty(base SwigcptrOpaqueVectorType) (_ bool) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_OpaqueVectorType_isEmpty, _swig_p) - return -} - -func (arg1 SwigcptrOpaqueVectorType) IsEmpty() (_swig_ret bool) { - return _swig_wrap_OpaqueVectorType_isEmpty(arg1) -} - -var _wrap_OpaqueVectorType_clear unsafe.Pointer - -func _swig_wrap_OpaqueVectorType_clear(base SwigcptrOpaqueVectorType) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_OpaqueVectorType_clear, _swig_p) - return -} - -func (arg1 SwigcptrOpaqueVectorType) Clear() { - _swig_wrap_OpaqueVectorType_clear(arg1) -} - -var _wrap_OpaqueVectorType_add unsafe.Pointer - -func _swig_wrap_OpaqueVectorType_add(base SwigcptrOpaqueVectorType, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_OpaqueVectorType_add, _swig_p) - return -} - -func (arg1 SwigcptrOpaqueVectorType) Add(arg2 A_OpaqueStruct) { - _swig_wrap_OpaqueVectorType_add(arg1, arg2.Swigcptr()) -} - -var _wrap_OpaqueVectorType_get unsafe.Pointer - -func _swig_wrap_OpaqueVectorType_get(base SwigcptrOpaqueVectorType, _ int) (_ SwigcptrA_OpaqueStruct) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_OpaqueVectorType_get, _swig_p) - return -} - -func (arg1 SwigcptrOpaqueVectorType) Get(arg2 int) (_swig_ret A_OpaqueStruct) { - return _swig_wrap_OpaqueVectorType_get(arg1, arg2) -} - -var _wrap_OpaqueVectorType_set unsafe.Pointer - -func _swig_wrap_OpaqueVectorType_set(base SwigcptrOpaqueVectorType, _ int, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_OpaqueVectorType_set, _swig_p) - return -} - -func (arg1 SwigcptrOpaqueVectorType) Set(arg2 int, arg3 A_OpaqueStruct) { - _swig_wrap_OpaqueVectorType_set(arg1, arg2, arg3.Swigcptr()) -} - -var _wrap_delete_OpaqueVectorType unsafe.Pointer - -func _swig_wrap_delete_OpaqueVectorType(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_OpaqueVectorType, _swig_p) - return -} - -func DeleteOpaqueVectorType(arg1 OpaqueVectorType) { - _swig_wrap_delete_OpaqueVectorType(arg1.Swigcptr()) -} - -type OpaqueVectorType interface { - Swigcptr() uintptr - SwigIsOpaqueVectorType() - Size() (_swig_ret int64) - Capacity() (_swig_ret int64) - Reserve(arg2 int64) - IsEmpty() (_swig_ret bool) - Clear() - Add(arg2 A_OpaqueStruct) - Get(arg2 int) (_swig_ret A_OpaqueStruct) - Set(arg2 int, arg3 A_OpaqueStruct) -} - - -type SwigcptrStd_vector_Sl_enum_SS_Hello_Sg_ uintptr -type Std_vector_Sl_enum_SS_Hello_Sg_ interface { - Swigcptr() uintptr; -} -func (p SwigcptrStd_vector_Sl_enum_SS_Hello_Sg_) Swigcptr() uintptr { - return uintptr(p) -} - -type SwigcptrA_OpaqueStruct uintptr -type A_OpaqueStruct interface { - Swigcptr() uintptr; -} -func (p SwigcptrA_OpaqueStruct) Swigcptr() uintptr { - return uintptr(p) -} - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/template_opaque_runme b/Examples/test-suite/go/template_opaque_runme deleted file mode 100755 index d0d93f80b..000000000 Binary files a/Examples/test-suite/go/template_opaque_runme and /dev/null differ diff --git a/Examples/test-suite/go/template_partial_arg.go b/Examples/test-suite/go/template_partial_arg.go deleted file mode 100644 index 2eb381b6c..000000000 --- a/Examples/test-suite/go/template_partial_arg.go +++ /dev/null @@ -1,203 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../template_partial_arg.i - -package template_partial_arg - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrBar uintptr - -func (p SwigcptrBar) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrBar) SwigIsBar() { -} - -var _wrap_new_Bar unsafe.Pointer - -func _swig_wrap_new_Bar() (base SwigcptrBar) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Bar, _swig_p) - return -} - -func NewBar() (_swig_ret Bar) { - return _swig_wrap_new_Bar() -} - -var _wrap_delete_Bar unsafe.Pointer - -func _swig_wrap_delete_Bar(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Bar, _swig_p) - return -} - -func DeleteBar(arg1 Bar) { - _swig_wrap_delete_Bar(arg1.Swigcptr()) -} - -type Bar interface { - Swigcptr() uintptr - SwigIsBar() -} - -type SwigcptrFoo1 uintptr - -func (p SwigcptrFoo1) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrFoo1) SwigIsFoo1() { -} - -var _wrap_Foo1_bar unsafe.Pointer - -func _swig_wrap_Foo1_bar(base SwigcptrFoo1) (_ SwigcptrBar) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo1_bar, _swig_p) - return -} - -func (arg1 SwigcptrFoo1) Bar() (_swig_ret Bar) { - return _swig_wrap_Foo1_bar(arg1) -} - -var _wrap_Foo1_baz unsafe.Pointer - -func _swig_wrap_Foo1_baz(base SwigcptrFoo1) (_ SwigcptrBar) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo1_baz, _swig_p) - return -} - -func (arg1 SwigcptrFoo1) Baz() (_swig_ret Bar) { - return _swig_wrap_Foo1_baz(arg1) -} - -var _wrap_new_Foo1 unsafe.Pointer - -func _swig_wrap_new_Foo1() (base SwigcptrFoo1) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Foo1, _swig_p) - return -} - -func NewFoo1() (_swig_ret Foo1) { - return _swig_wrap_new_Foo1() -} - -var _wrap_delete_Foo1 unsafe.Pointer - -func _swig_wrap_delete_Foo1(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Foo1, _swig_p) - return -} - -func DeleteFoo1(arg1 Foo1) { - _swig_wrap_delete_Foo1(arg1.Swigcptr()) -} - -type Foo1 interface { - Swigcptr() uintptr - SwigIsFoo1() - Bar() (_swig_ret Bar) - Baz() (_swig_ret Bar) -} - -type SwigcptrFoo2 uintptr - -func (p SwigcptrFoo2) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrFoo2) SwigIsFoo2() { -} - -var _wrap_Foo2_bar unsafe.Pointer - -func _swig_wrap_Foo2_bar(base SwigcptrFoo2) (_ SwigcptrBar) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo2_bar, _swig_p) - return -} - -func (arg1 SwigcptrFoo2) Bar() (_swig_ret Bar) { - return _swig_wrap_Foo2_bar(arg1) -} - -var _wrap_Foo2_baz unsafe.Pointer - -func _swig_wrap_Foo2_baz(base SwigcptrFoo2) (_ SwigcptrBar) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo2_baz, _swig_p) - return -} - -func (arg1 SwigcptrFoo2) Baz() (_swig_ret Bar) { - return _swig_wrap_Foo2_baz(arg1) -} - -var _wrap_new_Foo2 unsafe.Pointer - -func _swig_wrap_new_Foo2() (base SwigcptrFoo2) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Foo2, _swig_p) - return -} - -func NewFoo2() (_swig_ret Foo2) { - return _swig_wrap_new_Foo2() -} - -var _wrap_delete_Foo2 unsafe.Pointer - -func _swig_wrap_delete_Foo2(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Foo2, _swig_p) - return -} - -func DeleteFoo2(arg1 Foo2) { - _swig_wrap_delete_Foo2(arg1.Swigcptr()) -} - -type Foo2 interface { - Swigcptr() uintptr - SwigIsFoo2() - Bar() (_swig_ret Bar) - Baz() (_swig_ret Bar) -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/template_partial_specialization.go b/Examples/test-suite/go/template_partial_specialization.go deleted file mode 100644 index 71fa10017..000000000 --- a/Examples/test-suite/go/template_partial_specialization.go +++ /dev/null @@ -1,1962 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../template_partial_specialization.i - -package template_partial_specialization - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrA uintptr - -func (p SwigcptrA) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrA) SwigIsA() { -} - -var _wrap_A_a unsafe.Pointer - -func _swig_wrap_A_a(base SwigcptrA) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_A_a, _swig_p) - return -} - -func (arg1 SwigcptrA) A() { - _swig_wrap_A_a(arg1) -} - -var _wrap_new_A unsafe.Pointer - -func _swig_wrap_new_A() (base SwigcptrA) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_A, _swig_p) - return -} - -func NewA() (_swig_ret A) { - return _swig_wrap_new_A() -} - -var _wrap_delete_A unsafe.Pointer - -func _swig_wrap_delete_A(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_A, _swig_p) - return -} - -func DeleteA(arg1 A) { - _swig_wrap_delete_A(arg1.Swigcptr()) -} - -type A interface { - Swigcptr() uintptr - SwigIsA() - A() -} - -type SwigcptrB uintptr - -func (p SwigcptrB) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrB) SwigIsB() { -} - -var _wrap_B_b unsafe.Pointer - -func _swig_wrap_B_b(base SwigcptrB) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_B_b, _swig_p) - return -} - -func (arg1 SwigcptrB) B() { - _swig_wrap_B_b(arg1) -} - -var _wrap_new_B unsafe.Pointer - -func _swig_wrap_new_B() (base SwigcptrB) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_B, _swig_p) - return -} - -func NewB() (_swig_ret B) { - return _swig_wrap_new_B() -} - -var _wrap_delete_B unsafe.Pointer - -func _swig_wrap_delete_B(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_B, _swig_p) - return -} - -func DeleteB(arg1 B) { - _swig_wrap_delete_B(arg1.Swigcptr()) -} - -type B interface { - Swigcptr() uintptr - SwigIsB() - B() -} - -type SwigcptrC uintptr - -func (p SwigcptrC) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrC) SwigIsC() { -} - -var _wrap_C_c unsafe.Pointer - -func _swig_wrap_C_c(base SwigcptrC) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_C_c, _swig_p) - return -} - -func (arg1 SwigcptrC) C() { - _swig_wrap_C_c(arg1) -} - -var _wrap_new_C unsafe.Pointer - -func _swig_wrap_new_C() (base SwigcptrC) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_C, _swig_p) - return -} - -func NewC() (_swig_ret C) { - return _swig_wrap_new_C() -} - -var _wrap_delete_C unsafe.Pointer - -func _swig_wrap_delete_C(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_C, _swig_p) - return -} - -func DeleteC(arg1 C) { - _swig_wrap_delete_C(arg1.Swigcptr()) -} - -type C interface { - Swigcptr() uintptr - SwigIsC() - C() -} - -type SwigcptrD uintptr - -func (p SwigcptrD) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrD) SwigIsD() { -} - -var _wrap_D_d unsafe.Pointer - -func _swig_wrap_D_d(base SwigcptrD) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_D_d, _swig_p) - return -} - -func (arg1 SwigcptrD) D() { - _swig_wrap_D_d(arg1) -} - -var _wrap_new_D unsafe.Pointer - -func _swig_wrap_new_D() (base SwigcptrD) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_D, _swig_p) - return -} - -func NewD() (_swig_ret D) { - return _swig_wrap_new_D() -} - -var _wrap_delete_D unsafe.Pointer - -func _swig_wrap_delete_D(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_D, _swig_p) - return -} - -func DeleteD(arg1 D) { - _swig_wrap_delete_D(arg1.Swigcptr()) -} - -type D interface { - Swigcptr() uintptr - SwigIsD() - D() -} - -type SwigcptrE uintptr - -func (p SwigcptrE) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrE) SwigIsE() { -} - -var _wrap_E_e unsafe.Pointer - -func _swig_wrap_E_e(base SwigcptrE) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_E_e, _swig_p) - return -} - -func (arg1 SwigcptrE) E() { - _swig_wrap_E_e(arg1) -} - -var _wrap_new_E unsafe.Pointer - -func _swig_wrap_new_E() (base SwigcptrE) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_E, _swig_p) - return -} - -func NewE() (_swig_ret E) { - return _swig_wrap_new_E() -} - -var _wrap_delete_E unsafe.Pointer - -func _swig_wrap_delete_E(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_E, _swig_p) - return -} - -func DeleteE(arg1 E) { - _swig_wrap_delete_E(arg1.Swigcptr()) -} - -type E interface { - Swigcptr() uintptr - SwigIsE() - E() -} - -type SwigcptrF uintptr - -func (p SwigcptrF) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrF) SwigIsF() { -} - -var _wrap_F_f unsafe.Pointer - -func _swig_wrap_F_f(base SwigcptrF) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_F_f, _swig_p) - return -} - -func (arg1 SwigcptrF) F() { - _swig_wrap_F_f(arg1) -} - -var _wrap_new_F unsafe.Pointer - -func _swig_wrap_new_F() (base SwigcptrF) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_F, _swig_p) - return -} - -func NewF() (_swig_ret F) { - return _swig_wrap_new_F() -} - -var _wrap_delete_F unsafe.Pointer - -func _swig_wrap_delete_F(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_F, _swig_p) - return -} - -func DeleteF(arg1 F) { - _swig_wrap_delete_F(arg1.Swigcptr()) -} - -type F interface { - Swigcptr() uintptr - SwigIsF() - F() -} - -type SwigcptrG uintptr - -func (p SwigcptrG) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrG) SwigIsG() { -} - -var _wrap_G_g unsafe.Pointer - -func _swig_wrap_G_g(base SwigcptrG) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_G_g, _swig_p) - return -} - -func (arg1 SwigcptrG) G() { - _swig_wrap_G_g(arg1) -} - -var _wrap_new_G unsafe.Pointer - -func _swig_wrap_new_G() (base SwigcptrG) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_G, _swig_p) - return -} - -func NewG() (_swig_ret G) { - return _swig_wrap_new_G() -} - -var _wrap_delete_G unsafe.Pointer - -func _swig_wrap_delete_G(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_G, _swig_p) - return -} - -func DeleteG(arg1 G) { - _swig_wrap_delete_G(arg1.Swigcptr()) -} - -type G interface { - Swigcptr() uintptr - SwigIsG() - G() -} - -type SwigcptrH uintptr - -func (p SwigcptrH) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrH) SwigIsH() { -} - -var _wrap_H_h unsafe.Pointer - -func _swig_wrap_H_h(base SwigcptrH) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_H_h, _swig_p) - return -} - -func (arg1 SwigcptrH) H() { - _swig_wrap_H_h(arg1) -} - -var _wrap_new_H unsafe.Pointer - -func _swig_wrap_new_H() (base SwigcptrH) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_H, _swig_p) - return -} - -func NewH() (_swig_ret H) { - return _swig_wrap_new_H() -} - -var _wrap_delete_H unsafe.Pointer - -func _swig_wrap_delete_H(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_H, _swig_p) - return -} - -func DeleteH(arg1 H) { - _swig_wrap_delete_H(arg1.Swigcptr()) -} - -type H interface { - Swigcptr() uintptr - SwigIsH() - H() -} - -type SwigcptrI uintptr - -func (p SwigcptrI) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrI) SwigIsI() { -} - -var _wrap_I_i unsafe.Pointer - -func _swig_wrap_I_i(base SwigcptrI) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_I_i, _swig_p) - return -} - -func (arg1 SwigcptrI) I() { - _swig_wrap_I_i(arg1) -} - -var _wrap_new_I unsafe.Pointer - -func _swig_wrap_new_I() (base SwigcptrI) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_I, _swig_p) - return -} - -func NewI() (_swig_ret I) { - return _swig_wrap_new_I() -} - -var _wrap_delete_I unsafe.Pointer - -func _swig_wrap_delete_I(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_I, _swig_p) - return -} - -func DeleteI(arg1 I) { - _swig_wrap_delete_I(arg1.Swigcptr()) -} - -type I interface { - Swigcptr() uintptr - SwigIsI() - I() -} - -type SwigcptrJ uintptr - -func (p SwigcptrJ) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrJ) SwigIsJ() { -} - -var _wrap_J_j unsafe.Pointer - -func _swig_wrap_J_j(base SwigcptrJ) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_J_j, _swig_p) - return -} - -func (arg1 SwigcptrJ) J() { - _swig_wrap_J_j(arg1) -} - -var _wrap_new_J unsafe.Pointer - -func _swig_wrap_new_J() (base SwigcptrJ) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_J, _swig_p) - return -} - -func NewJ() (_swig_ret J) { - return _swig_wrap_new_J() -} - -var _wrap_delete_J unsafe.Pointer - -func _swig_wrap_delete_J(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_J, _swig_p) - return -} - -func DeleteJ(arg1 J) { - _swig_wrap_delete_J(arg1.Swigcptr()) -} - -type J interface { - Swigcptr() uintptr - SwigIsJ() - J() -} - -type SwigcptrK uintptr - -func (p SwigcptrK) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrK) SwigIsK() { -} - -var _wrap_K_k unsafe.Pointer - -func _swig_wrap_K_k(base SwigcptrK) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_K_k, _swig_p) - return -} - -func (arg1 SwigcptrK) K() { - _swig_wrap_K_k(arg1) -} - -var _wrap_new_K unsafe.Pointer - -func _swig_wrap_new_K() (base SwigcptrK) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_K, _swig_p) - return -} - -func NewK() (_swig_ret K) { - return _swig_wrap_new_K() -} - -var _wrap_delete_K unsafe.Pointer - -func _swig_wrap_delete_K(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_K, _swig_p) - return -} - -func DeleteK(arg1 K) { - _swig_wrap_delete_K(arg1.Swigcptr()) -} - -type K interface { - Swigcptr() uintptr - SwigIsK() - K() -} - -type SwigcptrL uintptr - -func (p SwigcptrL) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrL) SwigIsL() { -} - -var _wrap_L_l unsafe.Pointer - -func _swig_wrap_L_l(base SwigcptrL) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_L_l, _swig_p) - return -} - -func (arg1 SwigcptrL) L() { - _swig_wrap_L_l(arg1) -} - -var _wrap_new_L unsafe.Pointer - -func _swig_wrap_new_L() (base SwigcptrL) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_L, _swig_p) - return -} - -func NewL() (_swig_ret L) { - return _swig_wrap_new_L() -} - -var _wrap_delete_L unsafe.Pointer - -func _swig_wrap_delete_L(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_L, _swig_p) - return -} - -func DeleteL(arg1 L) { - _swig_wrap_delete_L(arg1.Swigcptr()) -} - -type L interface { - Swigcptr() uintptr - SwigIsL() - L() -} - -type SwigcptrBB uintptr - -func (p SwigcptrBB) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrBB) SwigIsBB() { -} - -var _wrap_BB_b unsafe.Pointer - -func _swig_wrap_BB_b(base SwigcptrBB) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_BB_b, _swig_p) - return -} - -func (arg1 SwigcptrBB) B() { - _swig_wrap_BB_b(arg1) -} - -var _wrap_new_BB unsafe.Pointer - -func _swig_wrap_new_BB() (base SwigcptrBB) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_BB, _swig_p) - return -} - -func NewBB() (_swig_ret BB) { - return _swig_wrap_new_BB() -} - -var _wrap_delete_BB unsafe.Pointer - -func _swig_wrap_delete_BB(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_BB, _swig_p) - return -} - -func DeleteBB(arg1 BB) { - _swig_wrap_delete_BB(arg1.Swigcptr()) -} - -type BB interface { - Swigcptr() uintptr - SwigIsBB() - B() -} - -type SwigcptrBBB uintptr - -func (p SwigcptrBBB) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrBBB) SwigIsBBB() { -} - -var _wrap_BBB_b unsafe.Pointer - -func _swig_wrap_BBB_b(base SwigcptrBBB) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_BBB_b, _swig_p) - return -} - -func (arg1 SwigcptrBBB) B() { - _swig_wrap_BBB_b(arg1) -} - -var _wrap_new_BBB unsafe.Pointer - -func _swig_wrap_new_BBB() (base SwigcptrBBB) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_BBB, _swig_p) - return -} - -func NewBBB() (_swig_ret BBB) { - return _swig_wrap_new_BBB() -} - -var _wrap_delete_BBB unsafe.Pointer - -func _swig_wrap_delete_BBB(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_BBB, _swig_p) - return -} - -func DeleteBBB(arg1 BBB) { - _swig_wrap_delete_BBB(arg1.Swigcptr()) -} - -type BBB interface { - Swigcptr() uintptr - SwigIsBBB() - B() -} - -type SwigcptrBBBB uintptr - -func (p SwigcptrBBBB) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrBBBB) SwigIsBBBB() { -} - -var _wrap_BBBB_b unsafe.Pointer - -func _swig_wrap_BBBB_b(base SwigcptrBBBB) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_BBBB_b, _swig_p) - return -} - -func (arg1 SwigcptrBBBB) B() { - _swig_wrap_BBBB_b(arg1) -} - -var _wrap_new_BBBB unsafe.Pointer - -func _swig_wrap_new_BBBB() (base SwigcptrBBBB) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_BBBB, _swig_p) - return -} - -func NewBBBB() (_swig_ret BBBB) { - return _swig_wrap_new_BBBB() -} - -var _wrap_delete_BBBB unsafe.Pointer - -func _swig_wrap_delete_BBBB(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_BBBB, _swig_p) - return -} - -func DeleteBBBB(arg1 BBBB) { - _swig_wrap_delete_BBBB(arg1.Swigcptr()) -} - -type BBBB interface { - Swigcptr() uintptr - SwigIsBBBB() - B() -} - -type SwigcptrBBBBB uintptr - -func (p SwigcptrBBBBB) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrBBBBB) SwigIsBBBBB() { -} - -var _wrap_BBBBB_b unsafe.Pointer - -func _swig_wrap_BBBBB_b(base SwigcptrBBBBB) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_BBBBB_b, _swig_p) - return -} - -func (arg1 SwigcptrBBBBB) B() { - _swig_wrap_BBBBB_b(arg1) -} - -var _wrap_new_BBBBB unsafe.Pointer - -func _swig_wrap_new_BBBBB() (base SwigcptrBBBBB) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_BBBBB, _swig_p) - return -} - -func NewBBBBB() (_swig_ret BBBBB) { - return _swig_wrap_new_BBBBB() -} - -var _wrap_delete_BBBBB unsafe.Pointer - -func _swig_wrap_delete_BBBBB(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_BBBBB, _swig_p) - return -} - -func DeleteBBBBB(arg1 BBBBB) { - _swig_wrap_delete_BBBBB(arg1.Swigcptr()) -} - -type BBBBB interface { - Swigcptr() uintptr - SwigIsBBBBB() - B() -} - -type SwigcptrB1 uintptr - -func (p SwigcptrB1) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrB1) SwigIsB1() { -} - -var _wrap_B1_b unsafe.Pointer - -func _swig_wrap_B1_b(base SwigcptrB1) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_B1_b, _swig_p) - return -} - -func (arg1 SwigcptrB1) B() { - _swig_wrap_B1_b(arg1) -} - -var _wrap_new_B1 unsafe.Pointer - -func _swig_wrap_new_B1() (base SwigcptrB1) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_B1, _swig_p) - return -} - -func NewB1() (_swig_ret B1) { - return _swig_wrap_new_B1() -} - -var _wrap_delete_B1 unsafe.Pointer - -func _swig_wrap_delete_B1(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_B1, _swig_p) - return -} - -func DeleteB1(arg1 B1) { - _swig_wrap_delete_B1(arg1.Swigcptr()) -} - -type B1 interface { - Swigcptr() uintptr - SwigIsB1() - B() -} - -type SwigcptrB2 uintptr - -func (p SwigcptrB2) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrB2) SwigIsB2() { -} - -var _wrap_B2_b unsafe.Pointer - -func _swig_wrap_B2_b(base SwigcptrB2) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_B2_b, _swig_p) - return -} - -func (arg1 SwigcptrB2) B() { - _swig_wrap_B2_b(arg1) -} - -var _wrap_new_B2 unsafe.Pointer - -func _swig_wrap_new_B2() (base SwigcptrB2) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_B2, _swig_p) - return -} - -func NewB2() (_swig_ret B2) { - return _swig_wrap_new_B2() -} - -var _wrap_delete_B2 unsafe.Pointer - -func _swig_wrap_delete_B2(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_B2, _swig_p) - return -} - -func DeleteB2(arg1 B2) { - _swig_wrap_delete_B2(arg1.Swigcptr()) -} - -type B2 interface { - Swigcptr() uintptr - SwigIsB2() - B() -} - -type SwigcptrB3 uintptr - -func (p SwigcptrB3) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrB3) SwigIsB3() { -} - -var _wrap_B3_b unsafe.Pointer - -func _swig_wrap_B3_b(base SwigcptrB3) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_B3_b, _swig_p) - return -} - -func (arg1 SwigcptrB3) B() { - _swig_wrap_B3_b(arg1) -} - -var _wrap_new_B3 unsafe.Pointer - -func _swig_wrap_new_B3() (base SwigcptrB3) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_B3, _swig_p) - return -} - -func NewB3() (_swig_ret B3) { - return _swig_wrap_new_B3() -} - -var _wrap_delete_B3 unsafe.Pointer - -func _swig_wrap_delete_B3(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_B3, _swig_p) - return -} - -func DeleteB3(arg1 B3) { - _swig_wrap_delete_B3(arg1.Swigcptr()) -} - -type B3 interface { - Swigcptr() uintptr - SwigIsB3() - B() -} - -type SwigcptrB4 uintptr - -func (p SwigcptrB4) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrB4) SwigIsB4() { -} - -var _wrap_B4_b unsafe.Pointer - -func _swig_wrap_B4_b(base SwigcptrB4) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_B4_b, _swig_p) - return -} - -func (arg1 SwigcptrB4) B() { - _swig_wrap_B4_b(arg1) -} - -var _wrap_new_B4 unsafe.Pointer - -func _swig_wrap_new_B4() (base SwigcptrB4) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_B4, _swig_p) - return -} - -func NewB4() (_swig_ret B4) { - return _swig_wrap_new_B4() -} - -var _wrap_delete_B4 unsafe.Pointer - -func _swig_wrap_delete_B4(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_B4, _swig_p) - return -} - -func DeleteB4(arg1 B4) { - _swig_wrap_delete_B4(arg1.Swigcptr()) -} - -type B4 interface { - Swigcptr() uintptr - SwigIsB4() - B() -} - -type SwigcptrConcrete uintptr - -func (p SwigcptrConcrete) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrConcrete) SwigIsConcrete() { -} - -var _wrap_new_Concrete unsafe.Pointer - -func _swig_wrap_new_Concrete() (base SwigcptrConcrete) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Concrete, _swig_p) - return -} - -func NewConcrete() (_swig_ret Concrete) { - return _swig_wrap_new_Concrete() -} - -var _wrap_delete_Concrete unsafe.Pointer - -func _swig_wrap_delete_Concrete(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Concrete, _swig_p) - return -} - -func DeleteConcrete(arg1 Concrete) { - _swig_wrap_delete_Concrete(arg1.Swigcptr()) -} - -type Concrete interface { - Swigcptr() uintptr - SwigIsConcrete() -} - -type SwigcptrA_ uintptr - -func (p SwigcptrA_) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrA_) SwigIsA_() { -} - -var _wrap_A__a unsafe.Pointer - -func _swig_wrap_A__a(base SwigcptrA_) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_A__a, _swig_p) - return -} - -func (arg1 SwigcptrA_) A() { - _swig_wrap_A__a(arg1) -} - -var _wrap_new_A_ unsafe.Pointer - -func _swig_wrap_new_A_() (base SwigcptrA_) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_A_, _swig_p) - return -} - -func NewA_() (_swig_ret A_) { - return _swig_wrap_new_A_() -} - -var _wrap_delete_A_ unsafe.Pointer - -func _swig_wrap_delete_A_(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_A_, _swig_p) - return -} - -func DeleteA_(arg1 A_) { - _swig_wrap_delete_A_(arg1.Swigcptr()) -} - -type A_ interface { - Swigcptr() uintptr - SwigIsA_() - A() -} - -type SwigcptrB_ uintptr - -func (p SwigcptrB_) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrB_) SwigIsB_() { -} - -var _wrap_B__b unsafe.Pointer - -func _swig_wrap_B__b(base SwigcptrB_) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_B__b, _swig_p) - return -} - -func (arg1 SwigcptrB_) B() { - _swig_wrap_B__b(arg1) -} - -var _wrap_new_B_ unsafe.Pointer - -func _swig_wrap_new_B_() (base SwigcptrB_) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_B_, _swig_p) - return -} - -func NewB_() (_swig_ret B_) { - return _swig_wrap_new_B_() -} - -var _wrap_delete_B_ unsafe.Pointer - -func _swig_wrap_delete_B_(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_B_, _swig_p) - return -} - -func DeleteB_(arg1 B_) { - _swig_wrap_delete_B_(arg1.Swigcptr()) -} - -type B_ interface { - Swigcptr() uintptr - SwigIsB_() - B() -} - -type SwigcptrC_ uintptr - -func (p SwigcptrC_) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrC_) SwigIsC_() { -} - -var _wrap_C__c unsafe.Pointer - -func _swig_wrap_C__c(base SwigcptrC_) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_C__c, _swig_p) - return -} - -func (arg1 SwigcptrC_) C() { - _swig_wrap_C__c(arg1) -} - -var _wrap_new_C_ unsafe.Pointer - -func _swig_wrap_new_C_() (base SwigcptrC_) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_C_, _swig_p) - return -} - -func NewC_() (_swig_ret C_) { - return _swig_wrap_new_C_() -} - -var _wrap_delete_C_ unsafe.Pointer - -func _swig_wrap_delete_C_(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_C_, _swig_p) - return -} - -func DeleteC_(arg1 C_) { - _swig_wrap_delete_C_(arg1.Swigcptr()) -} - -type C_ interface { - Swigcptr() uintptr - SwigIsC_() - C() -} - -type SwigcptrD_ uintptr - -func (p SwigcptrD_) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrD_) SwigIsD_() { -} - -var _wrap_D__d unsafe.Pointer - -func _swig_wrap_D__d(base SwigcptrD_) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_D__d, _swig_p) - return -} - -func (arg1 SwigcptrD_) D() { - _swig_wrap_D__d(arg1) -} - -var _wrap_new_D_ unsafe.Pointer - -func _swig_wrap_new_D_() (base SwigcptrD_) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_D_, _swig_p) - return -} - -func NewD_() (_swig_ret D_) { - return _swig_wrap_new_D_() -} - -var _wrap_delete_D_ unsafe.Pointer - -func _swig_wrap_delete_D_(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_D_, _swig_p) - return -} - -func DeleteD_(arg1 D_) { - _swig_wrap_delete_D_(arg1.Swigcptr()) -} - -type D_ interface { - Swigcptr() uintptr - SwigIsD_() - D() -} - -type SwigcptrE_ uintptr - -func (p SwigcptrE_) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrE_) SwigIsE_() { -} - -var _wrap_E__e unsafe.Pointer - -func _swig_wrap_E__e(base SwigcptrE_) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_E__e, _swig_p) - return -} - -func (arg1 SwigcptrE_) E() { - _swig_wrap_E__e(arg1) -} - -var _wrap_new_E_ unsafe.Pointer - -func _swig_wrap_new_E_() (base SwigcptrE_) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_E_, _swig_p) - return -} - -func NewE_() (_swig_ret E_) { - return _swig_wrap_new_E_() -} - -var _wrap_delete_E_ unsafe.Pointer - -func _swig_wrap_delete_E_(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_E_, _swig_p) - return -} - -func DeleteE_(arg1 E_) { - _swig_wrap_delete_E_(arg1.Swigcptr()) -} - -type E_ interface { - Swigcptr() uintptr - SwigIsE_() - E() -} - -type SwigcptrF_ uintptr - -func (p SwigcptrF_) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrF_) SwigIsF_() { -} - -var _wrap_F__f unsafe.Pointer - -func _swig_wrap_F__f(base SwigcptrF_) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_F__f, _swig_p) - return -} - -func (arg1 SwigcptrF_) F() { - _swig_wrap_F__f(arg1) -} - -var _wrap_new_F_ unsafe.Pointer - -func _swig_wrap_new_F_() (base SwigcptrF_) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_F_, _swig_p) - return -} - -func NewF_() (_swig_ret F_) { - return _swig_wrap_new_F_() -} - -var _wrap_delete_F_ unsafe.Pointer - -func _swig_wrap_delete_F_(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_F_, _swig_p) - return -} - -func DeleteF_(arg1 F_) { - _swig_wrap_delete_F_(arg1.Swigcptr()) -} - -type F_ interface { - Swigcptr() uintptr - SwigIsF_() - F() -} - -type SwigcptrG_ uintptr - -func (p SwigcptrG_) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrG_) SwigIsG_() { -} - -var _wrap_G__g unsafe.Pointer - -func _swig_wrap_G__g(base SwigcptrG_) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_G__g, _swig_p) - return -} - -func (arg1 SwigcptrG_) G() { - _swig_wrap_G__g(arg1) -} - -var _wrap_new_G_ unsafe.Pointer - -func _swig_wrap_new_G_() (base SwigcptrG_) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_G_, _swig_p) - return -} - -func NewG_() (_swig_ret G_) { - return _swig_wrap_new_G_() -} - -var _wrap_delete_G_ unsafe.Pointer - -func _swig_wrap_delete_G_(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_G_, _swig_p) - return -} - -func DeleteG_(arg1 G_) { - _swig_wrap_delete_G_(arg1.Swigcptr()) -} - -type G_ interface { - Swigcptr() uintptr - SwigIsG_() - G() -} - -type SwigcptrC1_ uintptr - -func (p SwigcptrC1_) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrC1_) SwigIsC1_() { -} - -var _wrap_C1__c unsafe.Pointer - -func _swig_wrap_C1__c(base SwigcptrC1_) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_C1__c, _swig_p) - return -} - -func (arg1 SwigcptrC1_) C() { - _swig_wrap_C1__c(arg1) -} - -var _wrap_new_C1_ unsafe.Pointer - -func _swig_wrap_new_C1_() (base SwigcptrC1_) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_C1_, _swig_p) - return -} - -func NewC1_() (_swig_ret C1_) { - return _swig_wrap_new_C1_() -} - -var _wrap_delete_C1_ unsafe.Pointer - -func _swig_wrap_delete_C1_(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_C1_, _swig_p) - return -} - -func DeleteC1_(arg1 C1_) { - _swig_wrap_delete_C1_(arg1.Swigcptr()) -} - -type C1_ interface { - Swigcptr() uintptr - SwigIsC1_() - C() -} - -type SwigcptrC2_ uintptr - -func (p SwigcptrC2_) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrC2_) SwigIsC2_() { -} - -var _wrap_C2__c unsafe.Pointer - -func _swig_wrap_C2__c(base SwigcptrC2_) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_C2__c, _swig_p) - return -} - -func (arg1 SwigcptrC2_) C() { - _swig_wrap_C2__c(arg1) -} - -var _wrap_new_C2_ unsafe.Pointer - -func _swig_wrap_new_C2_() (base SwigcptrC2_) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_C2_, _swig_p) - return -} - -func NewC2_() (_swig_ret C2_) { - return _swig_wrap_new_C2_() -} - -var _wrap_delete_C2_ unsafe.Pointer - -func _swig_wrap_delete_C2_(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_C2_, _swig_p) - return -} - -func DeleteC2_(arg1 C2_) { - _swig_wrap_delete_C2_(arg1.Swigcptr()) -} - -type C2_ interface { - Swigcptr() uintptr - SwigIsC2_() - C() -} - -type SwigcptrC3_ uintptr - -func (p SwigcptrC3_) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrC3_) SwigIsC3_() { -} - -var _wrap_C3__c unsafe.Pointer - -func _swig_wrap_C3__c(base SwigcptrC3_) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_C3__c, _swig_p) - return -} - -func (arg1 SwigcptrC3_) C() { - _swig_wrap_C3__c(arg1) -} - -var _wrap_new_C3_ unsafe.Pointer - -func _swig_wrap_new_C3_() (base SwigcptrC3_) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_C3_, _swig_p) - return -} - -func NewC3_() (_swig_ret C3_) { - return _swig_wrap_new_C3_() -} - -var _wrap_delete_C3_ unsafe.Pointer - -func _swig_wrap_delete_C3_(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_C3_, _swig_p) - return -} - -func DeleteC3_(arg1 C3_) { - _swig_wrap_delete_C3_(arg1.Swigcptr()) -} - -type C3_ interface { - Swigcptr() uintptr - SwigIsC3_() - C() -} - -type SwigcptrC4_ uintptr - -func (p SwigcptrC4_) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrC4_) SwigIsC4_() { -} - -var _wrap_C4__c unsafe.Pointer - -func _swig_wrap_C4__c(base SwigcptrC4_) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_C4__c, _swig_p) - return -} - -func (arg1 SwigcptrC4_) C() { - _swig_wrap_C4__c(arg1) -} - -var _wrap_new_C4_ unsafe.Pointer - -func _swig_wrap_new_C4_() (base SwigcptrC4_) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_C4_, _swig_p) - return -} - -func NewC4_() (_swig_ret C4_) { - return _swig_wrap_new_C4_() -} - -var _wrap_delete_C4_ unsafe.Pointer - -func _swig_wrap_delete_C4_(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_C4_, _swig_p) - return -} - -func DeleteC4_(arg1 C4_) { - _swig_wrap_delete_C4_(arg1.Swigcptr()) -} - -type C4_ interface { - Swigcptr() uintptr - SwigIsC4_() - C() -} - -type SwigcptrB1_ uintptr - -func (p SwigcptrB1_) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrB1_) SwigIsB1_() { -} - -var _wrap_B1__b unsafe.Pointer - -func _swig_wrap_B1__b(base SwigcptrB1_) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_B1__b, _swig_p) - return -} - -func (arg1 SwigcptrB1_) B() { - _swig_wrap_B1__b(arg1) -} - -var _wrap_new_B1_ unsafe.Pointer - -func _swig_wrap_new_B1_() (base SwigcptrB1_) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_B1_, _swig_p) - return -} - -func NewB1_() (_swig_ret B1_) { - return _swig_wrap_new_B1_() -} - -var _wrap_delete_B1_ unsafe.Pointer - -func _swig_wrap_delete_B1_(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_B1_, _swig_p) - return -} - -func DeleteB1_(arg1 B1_) { - _swig_wrap_delete_B1_(arg1.Swigcptr()) -} - -type B1_ interface { - Swigcptr() uintptr - SwigIsB1_() - B() -} - -type SwigcptrE1_ uintptr - -func (p SwigcptrE1_) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrE1_) SwigIsE1_() { -} - -var _wrap_E1__e unsafe.Pointer - -func _swig_wrap_E1__e(base SwigcptrE1_) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_E1__e, _swig_p) - return -} - -func (arg1 SwigcptrE1_) E() { - _swig_wrap_E1__e(arg1) -} - -var _wrap_new_E1_ unsafe.Pointer - -func _swig_wrap_new_E1_() (base SwigcptrE1_) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_E1_, _swig_p) - return -} - -func NewE1_() (_swig_ret E1_) { - return _swig_wrap_new_E1_() -} - -var _wrap_delete_E1_ unsafe.Pointer - -func _swig_wrap_delete_E1_(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_E1_, _swig_p) - return -} - -func DeleteE1_(arg1 E1_) { - _swig_wrap_delete_E1_(arg1.Swigcptr()) -} - -type E1_ interface { - Swigcptr() uintptr - SwigIsE1_() - E() -} - -type SwigcptrE2_ uintptr - -func (p SwigcptrE2_) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrE2_) SwigIsE2_() { -} - -var _wrap_E2__e unsafe.Pointer - -func _swig_wrap_E2__e(base SwigcptrE2_) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_E2__e, _swig_p) - return -} - -func (arg1 SwigcptrE2_) E() { - _swig_wrap_E2__e(arg1) -} - -var _wrap_new_E2_ unsafe.Pointer - -func _swig_wrap_new_E2_() (base SwigcptrE2_) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_E2_, _swig_p) - return -} - -func NewE2_() (_swig_ret E2_) { - return _swig_wrap_new_E2_() -} - -var _wrap_delete_E2_ unsafe.Pointer - -func _swig_wrap_delete_E2_(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_E2_, _swig_p) - return -} - -func DeleteE2_(arg1 E2_) { - _swig_wrap_delete_E2_(arg1.Swigcptr()) -} - -type E2_ interface { - Swigcptr() uintptr - SwigIsE2_() - E() -} - -type SwigcptrH_ uintptr - -func (p SwigcptrH_) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrH_) SwigIsH_() { -} - -var _wrap_H__h unsafe.Pointer - -func _swig_wrap_H__h(base SwigcptrH_) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_H__h, _swig_p) - return -} - -func (arg1 SwigcptrH_) H() { - _swig_wrap_H__h(arg1) -} - -var _wrap_new_H_ unsafe.Pointer - -func _swig_wrap_new_H_() (base SwigcptrH_) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_H_, _swig_p) - return -} - -func NewH_() (_swig_ret H_) { - return _swig_wrap_new_H_() -} - -var _wrap_delete_H_ unsafe.Pointer - -func _swig_wrap_delete_H_(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_H_, _swig_p) - return -} - -func DeleteH_(arg1 H_) { - _swig_wrap_delete_H_(arg1.Swigcptr()) -} - -type H_ interface { - Swigcptr() uintptr - SwigIsH_() - H() -} - -type SwigcptrFiveParm1 uintptr - -func (p SwigcptrFiveParm1) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrFiveParm1) SwigIsFiveParm1() { -} - -var _wrap_FiveParm1_b unsafe.Pointer - -func _swig_wrap_FiveParm1_b(base SwigcptrFiveParm1) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_FiveParm1_b, _swig_p) - return -} - -func (arg1 SwigcptrFiveParm1) B() { - _swig_wrap_FiveParm1_b(arg1) -} - -var _wrap_new_FiveParm1 unsafe.Pointer - -func _swig_wrap_new_FiveParm1() (base SwigcptrFiveParm1) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_FiveParm1, _swig_p) - return -} - -func NewFiveParm1() (_swig_ret FiveParm1) { - return _swig_wrap_new_FiveParm1() -} - -var _wrap_delete_FiveParm1 unsafe.Pointer - -func _swig_wrap_delete_FiveParm1(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_FiveParm1, _swig_p) - return -} - -func DeleteFiveParm1(arg1 FiveParm1) { - _swig_wrap_delete_FiveParm1(arg1.Swigcptr()) -} - -type FiveParm1 interface { - Swigcptr() uintptr - SwigIsFiveParm1() - B() -} - -type SwigcptrThreeParmInt uintptr - -func (p SwigcptrThreeParmInt) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrThreeParmInt) SwigIsThreeParmInt() { -} - -var _wrap_ThreeParmInt_a2 unsafe.Pointer - -func _swig_wrap_ThreeParmInt_a2(base SwigcptrThreeParmInt) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_ThreeParmInt_a2, _swig_p) - return -} - -func (arg1 SwigcptrThreeParmInt) A2() { - _swig_wrap_ThreeParmInt_a2(arg1) -} - -var _wrap_new_ThreeParmInt unsafe.Pointer - -func _swig_wrap_new_ThreeParmInt() (base SwigcptrThreeParmInt) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_ThreeParmInt, _swig_p) - return -} - -func NewThreeParmInt() (_swig_ret ThreeParmInt) { - return _swig_wrap_new_ThreeParmInt() -} - -var _wrap_delete_ThreeParmInt unsafe.Pointer - -func _swig_wrap_delete_ThreeParmInt(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_ThreeParmInt, _swig_p) - return -} - -func DeleteThreeParmInt(arg1 ThreeParmInt) { - _swig_wrap_delete_ThreeParmInt(arg1.Swigcptr()) -} - -type ThreeParmInt interface { - Swigcptr() uintptr - SwigIsThreeParmInt() - A2() -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/template_partial_specialization_typedef.go b/Examples/test-suite/go/template_partial_specialization_typedef.go deleted file mode 100644 index cc06cfe83..000000000 --- a/Examples/test-suite/go/template_partial_specialization_typedef.go +++ /dev/null @@ -1,1809 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../template_partial_specialization_typedef.i - -package template_partial_specialization_typedef - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrA uintptr - -func (p SwigcptrA) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrA) SwigIsA() { -} - -var _wrap_A_a unsafe.Pointer - -func _swig_wrap_A_a(base SwigcptrA) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_A_a, _swig_p) - return -} - -func (arg1 SwigcptrA) A() { - _swig_wrap_A_a(arg1) -} - -var _wrap_new_A unsafe.Pointer - -func _swig_wrap_new_A() (base SwigcptrA) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_A, _swig_p) - return -} - -func NewA() (_swig_ret A) { - return _swig_wrap_new_A() -} - -var _wrap_delete_A unsafe.Pointer - -func _swig_wrap_delete_A(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_A, _swig_p) - return -} - -func DeleteA(arg1 A) { - _swig_wrap_delete_A(arg1.Swigcptr()) -} - -type A interface { - Swigcptr() uintptr - SwigIsA() - A() -} - -type SwigcptrB uintptr - -func (p SwigcptrB) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrB) SwigIsB() { -} - -var _wrap_B_b unsafe.Pointer - -func _swig_wrap_B_b(base SwigcptrB) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_B_b, _swig_p) - return -} - -func (arg1 SwigcptrB) B() { - _swig_wrap_B_b(arg1) -} - -var _wrap_new_B unsafe.Pointer - -func _swig_wrap_new_B() (base SwigcptrB) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_B, _swig_p) - return -} - -func NewB() (_swig_ret B) { - return _swig_wrap_new_B() -} - -var _wrap_delete_B unsafe.Pointer - -func _swig_wrap_delete_B(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_B, _swig_p) - return -} - -func DeleteB(arg1 B) { - _swig_wrap_delete_B(arg1.Swigcptr()) -} - -type B interface { - Swigcptr() uintptr - SwigIsB() - B() -} - -type SwigcptrC uintptr - -func (p SwigcptrC) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrC) SwigIsC() { -} - -var _wrap_C_c unsafe.Pointer - -func _swig_wrap_C_c(base SwigcptrC) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_C_c, _swig_p) - return -} - -func (arg1 SwigcptrC) C() { - _swig_wrap_C_c(arg1) -} - -var _wrap_new_C unsafe.Pointer - -func _swig_wrap_new_C() (base SwigcptrC) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_C, _swig_p) - return -} - -func NewC() (_swig_ret C) { - return _swig_wrap_new_C() -} - -var _wrap_delete_C unsafe.Pointer - -func _swig_wrap_delete_C(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_C, _swig_p) - return -} - -func DeleteC(arg1 C) { - _swig_wrap_delete_C(arg1.Swigcptr()) -} - -type C interface { - Swigcptr() uintptr - SwigIsC() - C() -} - -type SwigcptrD uintptr - -func (p SwigcptrD) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrD) SwigIsD() { -} - -var _wrap_D_d unsafe.Pointer - -func _swig_wrap_D_d(base SwigcptrD) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_D_d, _swig_p) - return -} - -func (arg1 SwigcptrD) D() { - _swig_wrap_D_d(arg1) -} - -var _wrap_new_D unsafe.Pointer - -func _swig_wrap_new_D() (base SwigcptrD) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_D, _swig_p) - return -} - -func NewD() (_swig_ret D) { - return _swig_wrap_new_D() -} - -var _wrap_delete_D unsafe.Pointer - -func _swig_wrap_delete_D(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_D, _swig_p) - return -} - -func DeleteD(arg1 D) { - _swig_wrap_delete_D(arg1.Swigcptr()) -} - -type D interface { - Swigcptr() uintptr - SwigIsD() - D() -} - -type SwigcptrE uintptr - -func (p SwigcptrE) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrE) SwigIsE() { -} - -var _wrap_E_e unsafe.Pointer - -func _swig_wrap_E_e(base SwigcptrE) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_E_e, _swig_p) - return -} - -func (arg1 SwigcptrE) E() { - _swig_wrap_E_e(arg1) -} - -var _wrap_new_E unsafe.Pointer - -func _swig_wrap_new_E() (base SwigcptrE) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_E, _swig_p) - return -} - -func NewE() (_swig_ret E) { - return _swig_wrap_new_E() -} - -var _wrap_delete_E unsafe.Pointer - -func _swig_wrap_delete_E(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_E, _swig_p) - return -} - -func DeleteE(arg1 E) { - _swig_wrap_delete_E(arg1.Swigcptr()) -} - -type E interface { - Swigcptr() uintptr - SwigIsE() - E() -} - -type SwigcptrF uintptr - -func (p SwigcptrF) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrF) SwigIsF() { -} - -var _wrap_F_f unsafe.Pointer - -func _swig_wrap_F_f(base SwigcptrF) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_F_f, _swig_p) - return -} - -func (arg1 SwigcptrF) F() { - _swig_wrap_F_f(arg1) -} - -var _wrap_new_F unsafe.Pointer - -func _swig_wrap_new_F() (base SwigcptrF) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_F, _swig_p) - return -} - -func NewF() (_swig_ret F) { - return _swig_wrap_new_F() -} - -var _wrap_delete_F unsafe.Pointer - -func _swig_wrap_delete_F(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_F, _swig_p) - return -} - -func DeleteF(arg1 F) { - _swig_wrap_delete_F(arg1.Swigcptr()) -} - -type F interface { - Swigcptr() uintptr - SwigIsF() - F() -} - -type SwigcptrG uintptr - -func (p SwigcptrG) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrG) SwigIsG() { -} - -var _wrap_G_g unsafe.Pointer - -func _swig_wrap_G_g(base SwigcptrG) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_G_g, _swig_p) - return -} - -func (arg1 SwigcptrG) G() { - _swig_wrap_G_g(arg1) -} - -var _wrap_new_G unsafe.Pointer - -func _swig_wrap_new_G() (base SwigcptrG) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_G, _swig_p) - return -} - -func NewG() (_swig_ret G) { - return _swig_wrap_new_G() -} - -var _wrap_delete_G unsafe.Pointer - -func _swig_wrap_delete_G(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_G, _swig_p) - return -} - -func DeleteG(arg1 G) { - _swig_wrap_delete_G(arg1.Swigcptr()) -} - -type G interface { - Swigcptr() uintptr - SwigIsG() - G() -} - -type SwigcptrH uintptr - -func (p SwigcptrH) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrH) SwigIsH() { -} - -var _wrap_H_h unsafe.Pointer - -func _swig_wrap_H_h(base SwigcptrH) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_H_h, _swig_p) - return -} - -func (arg1 SwigcptrH) H() { - _swig_wrap_H_h(arg1) -} - -var _wrap_new_H unsafe.Pointer - -func _swig_wrap_new_H() (base SwigcptrH) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_H, _swig_p) - return -} - -func NewH() (_swig_ret H) { - return _swig_wrap_new_H() -} - -var _wrap_delete_H unsafe.Pointer - -func _swig_wrap_delete_H(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_H, _swig_p) - return -} - -func DeleteH(arg1 H) { - _swig_wrap_delete_H(arg1.Swigcptr()) -} - -type H interface { - Swigcptr() uintptr - SwigIsH() - H() -} - -type SwigcptrI uintptr - -func (p SwigcptrI) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrI) SwigIsI() { -} - -var _wrap_I_i unsafe.Pointer - -func _swig_wrap_I_i(base SwigcptrI) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_I_i, _swig_p) - return -} - -func (arg1 SwigcptrI) I() { - _swig_wrap_I_i(arg1) -} - -var _wrap_new_I unsafe.Pointer - -func _swig_wrap_new_I() (base SwigcptrI) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_I, _swig_p) - return -} - -func NewI() (_swig_ret I) { - return _swig_wrap_new_I() -} - -var _wrap_delete_I unsafe.Pointer - -func _swig_wrap_delete_I(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_I, _swig_p) - return -} - -func DeleteI(arg1 I) { - _swig_wrap_delete_I(arg1.Swigcptr()) -} - -type I interface { - Swigcptr() uintptr - SwigIsI() - I() -} - -type SwigcptrJ uintptr - -func (p SwigcptrJ) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrJ) SwigIsJ() { -} - -var _wrap_J_j unsafe.Pointer - -func _swig_wrap_J_j(base SwigcptrJ) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_J_j, _swig_p) - return -} - -func (arg1 SwigcptrJ) J() { - _swig_wrap_J_j(arg1) -} - -var _wrap_new_J unsafe.Pointer - -func _swig_wrap_new_J() (base SwigcptrJ) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_J, _swig_p) - return -} - -func NewJ() (_swig_ret J) { - return _swig_wrap_new_J() -} - -var _wrap_delete_J unsafe.Pointer - -func _swig_wrap_delete_J(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_J, _swig_p) - return -} - -func DeleteJ(arg1 J) { - _swig_wrap_delete_J(arg1.Swigcptr()) -} - -type J interface { - Swigcptr() uintptr - SwigIsJ() - J() -} - -type SwigcptrK uintptr - -func (p SwigcptrK) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrK) SwigIsK() { -} - -var _wrap_K_k unsafe.Pointer - -func _swig_wrap_K_k(base SwigcptrK) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_K_k, _swig_p) - return -} - -func (arg1 SwigcptrK) K() { - _swig_wrap_K_k(arg1) -} - -var _wrap_new_K unsafe.Pointer - -func _swig_wrap_new_K() (base SwigcptrK) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_K, _swig_p) - return -} - -func NewK() (_swig_ret K) { - return _swig_wrap_new_K() -} - -var _wrap_delete_K unsafe.Pointer - -func _swig_wrap_delete_K(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_K, _swig_p) - return -} - -func DeleteK(arg1 K) { - _swig_wrap_delete_K(arg1.Swigcptr()) -} - -type K interface { - Swigcptr() uintptr - SwigIsK() - K() -} - -type SwigcptrL uintptr - -func (p SwigcptrL) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrL) SwigIsL() { -} - -var _wrap_L_l unsafe.Pointer - -func _swig_wrap_L_l(base SwigcptrL) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_L_l, _swig_p) - return -} - -func (arg1 SwigcptrL) L() { - _swig_wrap_L_l(arg1) -} - -var _wrap_new_L unsafe.Pointer - -func _swig_wrap_new_L() (base SwigcptrL) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_L, _swig_p) - return -} - -func NewL() (_swig_ret L) { - return _swig_wrap_new_L() -} - -var _wrap_delete_L unsafe.Pointer - -func _swig_wrap_delete_L(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_L, _swig_p) - return -} - -func DeleteL(arg1 L) { - _swig_wrap_delete_L(arg1.Swigcptr()) -} - -type L interface { - Swigcptr() uintptr - SwigIsL() - L() -} - -type SwigcptrBB uintptr - -func (p SwigcptrBB) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrBB) SwigIsBB() { -} - -var _wrap_BB_b unsafe.Pointer - -func _swig_wrap_BB_b(base SwigcptrBB) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_BB_b, _swig_p) - return -} - -func (arg1 SwigcptrBB) B() { - _swig_wrap_BB_b(arg1) -} - -var _wrap_new_BB unsafe.Pointer - -func _swig_wrap_new_BB() (base SwigcptrBB) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_BB, _swig_p) - return -} - -func NewBB() (_swig_ret BB) { - return _swig_wrap_new_BB() -} - -var _wrap_delete_BB unsafe.Pointer - -func _swig_wrap_delete_BB(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_BB, _swig_p) - return -} - -func DeleteBB(arg1 BB) { - _swig_wrap_delete_BB(arg1.Swigcptr()) -} - -type BB interface { - Swigcptr() uintptr - SwigIsBB() - B() -} - -type SwigcptrBBB uintptr - -func (p SwigcptrBBB) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrBBB) SwigIsBBB() { -} - -var _wrap_BBB_b unsafe.Pointer - -func _swig_wrap_BBB_b(base SwigcptrBBB) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_BBB_b, _swig_p) - return -} - -func (arg1 SwigcptrBBB) B() { - _swig_wrap_BBB_b(arg1) -} - -var _wrap_new_BBB unsafe.Pointer - -func _swig_wrap_new_BBB() (base SwigcptrBBB) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_BBB, _swig_p) - return -} - -func NewBBB() (_swig_ret BBB) { - return _swig_wrap_new_BBB() -} - -var _wrap_delete_BBB unsafe.Pointer - -func _swig_wrap_delete_BBB(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_BBB, _swig_p) - return -} - -func DeleteBBB(arg1 BBB) { - _swig_wrap_delete_BBB(arg1.Swigcptr()) -} - -type BBB interface { - Swigcptr() uintptr - SwigIsBBB() - B() -} - -type SwigcptrBBBB uintptr - -func (p SwigcptrBBBB) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrBBBB) SwigIsBBBB() { -} - -var _wrap_BBBB_b unsafe.Pointer - -func _swig_wrap_BBBB_b(base SwigcptrBBBB) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_BBBB_b, _swig_p) - return -} - -func (arg1 SwigcptrBBBB) B() { - _swig_wrap_BBBB_b(arg1) -} - -var _wrap_new_BBBB unsafe.Pointer - -func _swig_wrap_new_BBBB() (base SwigcptrBBBB) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_BBBB, _swig_p) - return -} - -func NewBBBB() (_swig_ret BBBB) { - return _swig_wrap_new_BBBB() -} - -var _wrap_delete_BBBB unsafe.Pointer - -func _swig_wrap_delete_BBBB(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_BBBB, _swig_p) - return -} - -func DeleteBBBB(arg1 BBBB) { - _swig_wrap_delete_BBBB(arg1.Swigcptr()) -} - -type BBBB interface { - Swigcptr() uintptr - SwigIsBBBB() - B() -} - -type SwigcptrBBBBB uintptr - -func (p SwigcptrBBBBB) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrBBBBB) SwigIsBBBBB() { -} - -var _wrap_BBBBB_b unsafe.Pointer - -func _swig_wrap_BBBBB_b(base SwigcptrBBBBB) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_BBBBB_b, _swig_p) - return -} - -func (arg1 SwigcptrBBBBB) B() { - _swig_wrap_BBBBB_b(arg1) -} - -var _wrap_new_BBBBB unsafe.Pointer - -func _swig_wrap_new_BBBBB() (base SwigcptrBBBBB) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_BBBBB, _swig_p) - return -} - -func NewBBBBB() (_swig_ret BBBBB) { - return _swig_wrap_new_BBBBB() -} - -var _wrap_delete_BBBBB unsafe.Pointer - -func _swig_wrap_delete_BBBBB(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_BBBBB, _swig_p) - return -} - -func DeleteBBBBB(arg1 BBBBB) { - _swig_wrap_delete_BBBBB(arg1.Swigcptr()) -} - -type BBBBB interface { - Swigcptr() uintptr - SwigIsBBBBB() - B() -} - -type SwigcptrB1 uintptr - -func (p SwigcptrB1) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrB1) SwigIsB1() { -} - -var _wrap_B1_b unsafe.Pointer - -func _swig_wrap_B1_b(base SwigcptrB1) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_B1_b, _swig_p) - return -} - -func (arg1 SwigcptrB1) B() { - _swig_wrap_B1_b(arg1) -} - -var _wrap_new_B1 unsafe.Pointer - -func _swig_wrap_new_B1() (base SwigcptrB1) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_B1, _swig_p) - return -} - -func NewB1() (_swig_ret B1) { - return _swig_wrap_new_B1() -} - -var _wrap_delete_B1 unsafe.Pointer - -func _swig_wrap_delete_B1(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_B1, _swig_p) - return -} - -func DeleteB1(arg1 B1) { - _swig_wrap_delete_B1(arg1.Swigcptr()) -} - -type B1 interface { - Swigcptr() uintptr - SwigIsB1() - B() -} - -type SwigcptrB2 uintptr - -func (p SwigcptrB2) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrB2) SwigIsB2() { -} - -var _wrap_B2_b unsafe.Pointer - -func _swig_wrap_B2_b(base SwigcptrB2) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_B2_b, _swig_p) - return -} - -func (arg1 SwigcptrB2) B() { - _swig_wrap_B2_b(arg1) -} - -var _wrap_new_B2 unsafe.Pointer - -func _swig_wrap_new_B2() (base SwigcptrB2) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_B2, _swig_p) - return -} - -func NewB2() (_swig_ret B2) { - return _swig_wrap_new_B2() -} - -var _wrap_delete_B2 unsafe.Pointer - -func _swig_wrap_delete_B2(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_B2, _swig_p) - return -} - -func DeleteB2(arg1 B2) { - _swig_wrap_delete_B2(arg1.Swigcptr()) -} - -type B2 interface { - Swigcptr() uintptr - SwigIsB2() - B() -} - -type SwigcptrB3 uintptr - -func (p SwigcptrB3) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrB3) SwigIsB3() { -} - -var _wrap_B3_b unsafe.Pointer - -func _swig_wrap_B3_b(base SwigcptrB3) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_B3_b, _swig_p) - return -} - -func (arg1 SwigcptrB3) B() { - _swig_wrap_B3_b(arg1) -} - -var _wrap_new_B3 unsafe.Pointer - -func _swig_wrap_new_B3() (base SwigcptrB3) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_B3, _swig_p) - return -} - -func NewB3() (_swig_ret B3) { - return _swig_wrap_new_B3() -} - -var _wrap_delete_B3 unsafe.Pointer - -func _swig_wrap_delete_B3(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_B3, _swig_p) - return -} - -func DeleteB3(arg1 B3) { - _swig_wrap_delete_B3(arg1.Swigcptr()) -} - -type B3 interface { - Swigcptr() uintptr - SwigIsB3() - B() -} - -type SwigcptrB4 uintptr - -func (p SwigcptrB4) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrB4) SwigIsB4() { -} - -var _wrap_B4_b unsafe.Pointer - -func _swig_wrap_B4_b(base SwigcptrB4) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_B4_b, _swig_p) - return -} - -func (arg1 SwigcptrB4) B() { - _swig_wrap_B4_b(arg1) -} - -var _wrap_new_B4 unsafe.Pointer - -func _swig_wrap_new_B4() (base SwigcptrB4) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_B4, _swig_p) - return -} - -func NewB4() (_swig_ret B4) { - return _swig_wrap_new_B4() -} - -var _wrap_delete_B4 unsafe.Pointer - -func _swig_wrap_delete_B4(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_B4, _swig_p) - return -} - -func DeleteB4(arg1 B4) { - _swig_wrap_delete_B4(arg1.Swigcptr()) -} - -type B4 interface { - Swigcptr() uintptr - SwigIsB4() - B() -} - -type SwigcptrConcrete uintptr - -func (p SwigcptrConcrete) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrConcrete) SwigIsConcrete() { -} - -var _wrap_new_Concrete unsafe.Pointer - -func _swig_wrap_new_Concrete() (base SwigcptrConcrete) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Concrete, _swig_p) - return -} - -func NewConcrete() (_swig_ret Concrete) { - return _swig_wrap_new_Concrete() -} - -var _wrap_delete_Concrete unsafe.Pointer - -func _swig_wrap_delete_Concrete(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Concrete, _swig_p) - return -} - -func DeleteConcrete(arg1 Concrete) { - _swig_wrap_delete_Concrete(arg1.Swigcptr()) -} - -type Concrete interface { - Swigcptr() uintptr - SwigIsConcrete() -} - -type SwigcptrA_ uintptr - -func (p SwigcptrA_) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrA_) SwigIsA_() { -} - -var _wrap_A__a unsafe.Pointer - -func _swig_wrap_A__a(base SwigcptrA_) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_A__a, _swig_p) - return -} - -func (arg1 SwigcptrA_) A() { - _swig_wrap_A__a(arg1) -} - -var _wrap_new_A_ unsafe.Pointer - -func _swig_wrap_new_A_() (base SwigcptrA_) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_A_, _swig_p) - return -} - -func NewA_() (_swig_ret A_) { - return _swig_wrap_new_A_() -} - -var _wrap_delete_A_ unsafe.Pointer - -func _swig_wrap_delete_A_(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_A_, _swig_p) - return -} - -func DeleteA_(arg1 A_) { - _swig_wrap_delete_A_(arg1.Swigcptr()) -} - -type A_ interface { - Swigcptr() uintptr - SwigIsA_() - A() -} - -type SwigcptrB_ uintptr - -func (p SwigcptrB_) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrB_) SwigIsB_() { -} - -var _wrap_B__b unsafe.Pointer - -func _swig_wrap_B__b(base SwigcptrB_) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_B__b, _swig_p) - return -} - -func (arg1 SwigcptrB_) B() { - _swig_wrap_B__b(arg1) -} - -var _wrap_new_B_ unsafe.Pointer - -func _swig_wrap_new_B_() (base SwigcptrB_) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_B_, _swig_p) - return -} - -func NewB_() (_swig_ret B_) { - return _swig_wrap_new_B_() -} - -var _wrap_delete_B_ unsafe.Pointer - -func _swig_wrap_delete_B_(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_B_, _swig_p) - return -} - -func DeleteB_(arg1 B_) { - _swig_wrap_delete_B_(arg1.Swigcptr()) -} - -type B_ interface { - Swigcptr() uintptr - SwigIsB_() - B() -} - -type SwigcptrC_ uintptr - -func (p SwigcptrC_) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrC_) SwigIsC_() { -} - -var _wrap_C__c unsafe.Pointer - -func _swig_wrap_C__c(base SwigcptrC_) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_C__c, _swig_p) - return -} - -func (arg1 SwigcptrC_) C() { - _swig_wrap_C__c(arg1) -} - -var _wrap_new_C_ unsafe.Pointer - -func _swig_wrap_new_C_() (base SwigcptrC_) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_C_, _swig_p) - return -} - -func NewC_() (_swig_ret C_) { - return _swig_wrap_new_C_() -} - -var _wrap_delete_C_ unsafe.Pointer - -func _swig_wrap_delete_C_(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_C_, _swig_p) - return -} - -func DeleteC_(arg1 C_) { - _swig_wrap_delete_C_(arg1.Swigcptr()) -} - -type C_ interface { - Swigcptr() uintptr - SwigIsC_() - C() -} - -type SwigcptrD_ uintptr - -func (p SwigcptrD_) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrD_) SwigIsD_() { -} - -var _wrap_D__d unsafe.Pointer - -func _swig_wrap_D__d(base SwigcptrD_) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_D__d, _swig_p) - return -} - -func (arg1 SwigcptrD_) D() { - _swig_wrap_D__d(arg1) -} - -var _wrap_new_D_ unsafe.Pointer - -func _swig_wrap_new_D_() (base SwigcptrD_) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_D_, _swig_p) - return -} - -func NewD_() (_swig_ret D_) { - return _swig_wrap_new_D_() -} - -var _wrap_delete_D_ unsafe.Pointer - -func _swig_wrap_delete_D_(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_D_, _swig_p) - return -} - -func DeleteD_(arg1 D_) { - _swig_wrap_delete_D_(arg1.Swigcptr()) -} - -type D_ interface { - Swigcptr() uintptr - SwigIsD_() - D() -} - -type SwigcptrE_ uintptr - -func (p SwigcptrE_) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrE_) SwigIsE_() { -} - -var _wrap_E__e unsafe.Pointer - -func _swig_wrap_E__e(base SwigcptrE_) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_E__e, _swig_p) - return -} - -func (arg1 SwigcptrE_) E() { - _swig_wrap_E__e(arg1) -} - -var _wrap_new_E_ unsafe.Pointer - -func _swig_wrap_new_E_() (base SwigcptrE_) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_E_, _swig_p) - return -} - -func NewE_() (_swig_ret E_) { - return _swig_wrap_new_E_() -} - -var _wrap_delete_E_ unsafe.Pointer - -func _swig_wrap_delete_E_(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_E_, _swig_p) - return -} - -func DeleteE_(arg1 E_) { - _swig_wrap_delete_E_(arg1.Swigcptr()) -} - -type E_ interface { - Swigcptr() uintptr - SwigIsE_() - E() -} - -type SwigcptrF_ uintptr - -func (p SwigcptrF_) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrF_) SwigIsF_() { -} - -var _wrap_F__f unsafe.Pointer - -func _swig_wrap_F__f(base SwigcptrF_) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_F__f, _swig_p) - return -} - -func (arg1 SwigcptrF_) F() { - _swig_wrap_F__f(arg1) -} - -var _wrap_new_F_ unsafe.Pointer - -func _swig_wrap_new_F_() (base SwigcptrF_) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_F_, _swig_p) - return -} - -func NewF_() (_swig_ret F_) { - return _swig_wrap_new_F_() -} - -var _wrap_delete_F_ unsafe.Pointer - -func _swig_wrap_delete_F_(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_F_, _swig_p) - return -} - -func DeleteF_(arg1 F_) { - _swig_wrap_delete_F_(arg1.Swigcptr()) -} - -type F_ interface { - Swigcptr() uintptr - SwigIsF_() - F() -} - -type SwigcptrG_ uintptr - -func (p SwigcptrG_) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrG_) SwigIsG_() { -} - -var _wrap_G__g unsafe.Pointer - -func _swig_wrap_G__g(base SwigcptrG_) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_G__g, _swig_p) - return -} - -func (arg1 SwigcptrG_) G() { - _swig_wrap_G__g(arg1) -} - -var _wrap_new_G_ unsafe.Pointer - -func _swig_wrap_new_G_() (base SwigcptrG_) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_G_, _swig_p) - return -} - -func NewG_() (_swig_ret G_) { - return _swig_wrap_new_G_() -} - -var _wrap_delete_G_ unsafe.Pointer - -func _swig_wrap_delete_G_(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_G_, _swig_p) - return -} - -func DeleteG_(arg1 G_) { - _swig_wrap_delete_G_(arg1.Swigcptr()) -} - -type G_ interface { - Swigcptr() uintptr - SwigIsG_() - G() -} - -type SwigcptrC1_ uintptr - -func (p SwigcptrC1_) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrC1_) SwigIsC1_() { -} - -var _wrap_C1__c unsafe.Pointer - -func _swig_wrap_C1__c(base SwigcptrC1_) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_C1__c, _swig_p) - return -} - -func (arg1 SwigcptrC1_) C() { - _swig_wrap_C1__c(arg1) -} - -var _wrap_new_C1_ unsafe.Pointer - -func _swig_wrap_new_C1_() (base SwigcptrC1_) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_C1_, _swig_p) - return -} - -func NewC1_() (_swig_ret C1_) { - return _swig_wrap_new_C1_() -} - -var _wrap_delete_C1_ unsafe.Pointer - -func _swig_wrap_delete_C1_(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_C1_, _swig_p) - return -} - -func DeleteC1_(arg1 C1_) { - _swig_wrap_delete_C1_(arg1.Swigcptr()) -} - -type C1_ interface { - Swigcptr() uintptr - SwigIsC1_() - C() -} - -type SwigcptrC2_ uintptr - -func (p SwigcptrC2_) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrC2_) SwigIsC2_() { -} - -var _wrap_C2__c unsafe.Pointer - -func _swig_wrap_C2__c(base SwigcptrC2_) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_C2__c, _swig_p) - return -} - -func (arg1 SwigcptrC2_) C() { - _swig_wrap_C2__c(arg1) -} - -var _wrap_new_C2_ unsafe.Pointer - -func _swig_wrap_new_C2_() (base SwigcptrC2_) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_C2_, _swig_p) - return -} - -func NewC2_() (_swig_ret C2_) { - return _swig_wrap_new_C2_() -} - -var _wrap_delete_C2_ unsafe.Pointer - -func _swig_wrap_delete_C2_(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_C2_, _swig_p) - return -} - -func DeleteC2_(arg1 C2_) { - _swig_wrap_delete_C2_(arg1.Swigcptr()) -} - -type C2_ interface { - Swigcptr() uintptr - SwigIsC2_() - C() -} - -type SwigcptrC3_ uintptr - -func (p SwigcptrC3_) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrC3_) SwigIsC3_() { -} - -var _wrap_C3__c unsafe.Pointer - -func _swig_wrap_C3__c(base SwigcptrC3_) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_C3__c, _swig_p) - return -} - -func (arg1 SwigcptrC3_) C() { - _swig_wrap_C3__c(arg1) -} - -var _wrap_new_C3_ unsafe.Pointer - -func _swig_wrap_new_C3_() (base SwigcptrC3_) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_C3_, _swig_p) - return -} - -func NewC3_() (_swig_ret C3_) { - return _swig_wrap_new_C3_() -} - -var _wrap_delete_C3_ unsafe.Pointer - -func _swig_wrap_delete_C3_(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_C3_, _swig_p) - return -} - -func DeleteC3_(arg1 C3_) { - _swig_wrap_delete_C3_(arg1.Swigcptr()) -} - -type C3_ interface { - Swigcptr() uintptr - SwigIsC3_() - C() -} - -type SwigcptrC4_ uintptr - -func (p SwigcptrC4_) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrC4_) SwigIsC4_() { -} - -var _wrap_C4__c unsafe.Pointer - -func _swig_wrap_C4__c(base SwigcptrC4_) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_C4__c, _swig_p) - return -} - -func (arg1 SwigcptrC4_) C() { - _swig_wrap_C4__c(arg1) -} - -var _wrap_new_C4_ unsafe.Pointer - -func _swig_wrap_new_C4_() (base SwigcptrC4_) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_C4_, _swig_p) - return -} - -func NewC4_() (_swig_ret C4_) { - return _swig_wrap_new_C4_() -} - -var _wrap_delete_C4_ unsafe.Pointer - -func _swig_wrap_delete_C4_(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_C4_, _swig_p) - return -} - -func DeleteC4_(arg1 C4_) { - _swig_wrap_delete_C4_(arg1.Swigcptr()) -} - -type C4_ interface { - Swigcptr() uintptr - SwigIsC4_() - C() -} - -type SwigcptrB1_ uintptr - -func (p SwigcptrB1_) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrB1_) SwigIsB1_() { -} - -var _wrap_B1__b unsafe.Pointer - -func _swig_wrap_B1__b(base SwigcptrB1_) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_B1__b, _swig_p) - return -} - -func (arg1 SwigcptrB1_) B() { - _swig_wrap_B1__b(arg1) -} - -var _wrap_new_B1_ unsafe.Pointer - -func _swig_wrap_new_B1_() (base SwigcptrB1_) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_B1_, _swig_p) - return -} - -func NewB1_() (_swig_ret B1_) { - return _swig_wrap_new_B1_() -} - -var _wrap_delete_B1_ unsafe.Pointer - -func _swig_wrap_delete_B1_(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_B1_, _swig_p) - return -} - -func DeleteB1_(arg1 B1_) { - _swig_wrap_delete_B1_(arg1.Swigcptr()) -} - -type B1_ interface { - Swigcptr() uintptr - SwigIsB1_() - B() -} - -type SwigcptrE1_ uintptr - -func (p SwigcptrE1_) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrE1_) SwigIsE1_() { -} - -var _wrap_E1__e unsafe.Pointer - -func _swig_wrap_E1__e(base SwigcptrE1_) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_E1__e, _swig_p) - return -} - -func (arg1 SwigcptrE1_) E() { - _swig_wrap_E1__e(arg1) -} - -var _wrap_new_E1_ unsafe.Pointer - -func _swig_wrap_new_E1_() (base SwigcptrE1_) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_E1_, _swig_p) - return -} - -func NewE1_() (_swig_ret E1_) { - return _swig_wrap_new_E1_() -} - -var _wrap_delete_E1_ unsafe.Pointer - -func _swig_wrap_delete_E1_(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_E1_, _swig_p) - return -} - -func DeleteE1_(arg1 E1_) { - _swig_wrap_delete_E1_(arg1.Swigcptr()) -} - -type E1_ interface { - Swigcptr() uintptr - SwigIsE1_() - E() -} - -type SwigcptrE2_ uintptr - -func (p SwigcptrE2_) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrE2_) SwigIsE2_() { -} - -var _wrap_E2__e unsafe.Pointer - -func _swig_wrap_E2__e(base SwigcptrE2_) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_E2__e, _swig_p) - return -} - -func (arg1 SwigcptrE2_) E() { - _swig_wrap_E2__e(arg1) -} - -var _wrap_new_E2_ unsafe.Pointer - -func _swig_wrap_new_E2_() (base SwigcptrE2_) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_E2_, _swig_p) - return -} - -func NewE2_() (_swig_ret E2_) { - return _swig_wrap_new_E2_() -} - -var _wrap_delete_E2_ unsafe.Pointer - -func _swig_wrap_delete_E2_(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_E2_, _swig_p) - return -} - -func DeleteE2_(arg1 E2_) { - _swig_wrap_delete_E2_(arg1.Swigcptr()) -} - -type E2_ interface { - Swigcptr() uintptr - SwigIsE2_() - E() -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/template_qualifier.go b/Examples/test-suite/go/template_qualifier.go deleted file mode 100644 index 4549d2f69..000000000 --- a/Examples/test-suite/go/template_qualifier.go +++ /dev/null @@ -1,88 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../template_qualifier.i - -package template_qualifier - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrX uintptr - -func (p SwigcptrX) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrX) SwigIsX() { -} - -var _wrap_X_xalloc_int unsafe.Pointer - -func _swig_wrap_X_xalloc_int(base SwigcptrX) (_ SwigcptrX) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_X_xalloc_int, _swig_p) - return -} - -func (arg1 SwigcptrX) Xalloc_int() (_swig_ret X) { - return _swig_wrap_X_xalloc_int(arg1) -} - -var _wrap_new_X unsafe.Pointer - -func _swig_wrap_new_X() (base SwigcptrX) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_X, _swig_p) - return -} - -func NewX() (_swig_ret X) { - return _swig_wrap_new_X() -} - -var _wrap_delete_X unsafe.Pointer - -func _swig_wrap_delete_X(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_X, _swig_p) - return -} - -func DeleteX(arg1 X) { - _swig_wrap_delete_X(arg1.Swigcptr()) -} - -type X interface { - Swigcptr() uintptr - SwigIsX() - Xalloc_int() (_swig_ret X) -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/template_ref_type.go b/Examples/test-suite/go/template_ref_type.go deleted file mode 100644 index 53ea6bfd1..000000000 --- a/Examples/test-suite/go/template_ref_type.go +++ /dev/null @@ -1,203 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../template_ref_type.i - -package template_ref_type - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrX uintptr - -func (p SwigcptrX) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrX) SwigIsX() { -} - -var _wrap_X__i_set unsafe.Pointer - -func _swig_wrap_X__i_set(base SwigcptrX, _ uint) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_X__i_set, _swig_p) - return -} - -func (arg1 SwigcptrX) SetX_i(arg2 uint) { - _swig_wrap_X__i_set(arg1, arg2) -} - -var _wrap_X__i_get unsafe.Pointer - -func _swig_wrap_X__i_get(base SwigcptrX) (_ uint) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_X__i_get, _swig_p) - return -} - -func (arg1 SwigcptrX) GetX_i() (_swig_ret uint) { - return _swig_wrap_X__i_get(arg1) -} - -var _wrap_new_X unsafe.Pointer - -func _swig_wrap_new_X() (base SwigcptrX) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_X, _swig_p) - return -} - -func NewX() (_swig_ret X) { - return _swig_wrap_new_X() -} - -var _wrap_delete_X unsafe.Pointer - -func _swig_wrap_delete_X(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_X, _swig_p) - return -} - -func DeleteX(arg1 X) { - _swig_wrap_delete_X(arg1.Swigcptr()) -} - -type X interface { - Swigcptr() uintptr - SwigIsX() - SetX_i(arg2 uint) - GetX_i() (_swig_ret uint) -} - -type SwigcptrXC uintptr - -func (p SwigcptrXC) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrXC) SwigIsXC() { -} - -var _wrap_new_XC unsafe.Pointer - -func _swig_wrap_new_XC() (base SwigcptrXC) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_XC, _swig_p) - return -} - -func NewXC() (_swig_ret XC) { - return _swig_wrap_new_XC() -} - -var _wrap_XC_reset unsafe.Pointer - -func _swig_wrap_XC_reset(base SwigcptrXC) (_ bool) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_XC_reset, _swig_p) - return -} - -func (arg1 SwigcptrXC) Reset() (_swig_ret bool) { - return _swig_wrap_XC_reset(arg1) -} - -var _wrap_delete_XC unsafe.Pointer - -func _swig_wrap_delete_XC(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_XC, _swig_p) - return -} - -func DeleteXC(arg1 XC) { - _swig_wrap_delete_XC(arg1.Swigcptr()) -} - -type XC interface { - Swigcptr() uintptr - SwigIsXC() - Reset() (_swig_ret bool) -} - -type SwigcptrY uintptr - -func (p SwigcptrY) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrY) SwigIsY() { -} - -var _wrap_new_Y unsafe.Pointer - -func _swig_wrap_new_Y() (base SwigcptrY) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Y, _swig_p) - return -} - -func NewY() (_swig_ret Y) { - return _swig_wrap_new_Y() -} - -var _wrap_Y_find unsafe.Pointer - -func _swig_wrap_Y_find(base SwigcptrY, _ uintptr) (_ bool) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Y_find, _swig_p) - return -} - -func (arg1 SwigcptrY) Find(arg2 XC) (_swig_ret bool) { - return _swig_wrap_Y_find(arg1, arg2.Swigcptr()) -} - -var _wrap_delete_Y unsafe.Pointer - -func _swig_wrap_delete_Y(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Y, _swig_p) - return -} - -func DeleteY(arg1 Y) { - _swig_wrap_delete_Y(arg1.Swigcptr()) -} - -type Y interface { - Swigcptr() uintptr - SwigIsY() - Find(arg2 XC) (_swig_ret bool) -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/template_ref_type_runme b/Examples/test-suite/go/template_ref_type_runme deleted file mode 100755 index 439d6a507..000000000 Binary files a/Examples/test-suite/go/template_ref_type_runme and /dev/null differ diff --git a/Examples/test-suite/go/template_rename.go b/Examples/test-suite/go/template_rename.go deleted file mode 100644 index 18490cbab..000000000 --- a/Examples/test-suite/go/template_rename.go +++ /dev/null @@ -1,267 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../template_rename.i - -package template_rename - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrIFoo uintptr - -func (p SwigcptrIFoo) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrIFoo) SwigIsIFoo() { -} - -var _wrap_iFoo_blah_test unsafe.Pointer - -func _swig_wrap_iFoo_blah_test(base SwigcptrIFoo, _ int) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_iFoo_blah_test, _swig_p) - return -} - -func (arg1 SwigcptrIFoo) Blah_test(arg2 int) (_swig_ret int) { - return _swig_wrap_iFoo_blah_test(arg1, arg2) -} - -var _wrap_iFoo_spam_test unsafe.Pointer - -func _swig_wrap_iFoo_spam_test(base SwigcptrIFoo, _ int) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_iFoo_spam_test, _swig_p) - return -} - -func (arg1 SwigcptrIFoo) Spam_test(arg2 int) (_swig_ret int) { - return _swig_wrap_iFoo_spam_test(arg1, arg2) -} - -var _wrap_iFoo_groki_test unsafe.Pointer - -func _swig_wrap_iFoo_groki_test(base SwigcptrIFoo, _ int) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_iFoo_groki_test, _swig_p) - return -} - -func (arg1 SwigcptrIFoo) Groki_test(arg2 int) (_swig_ret int) { - return _swig_wrap_iFoo_groki_test(arg1, arg2) -} - -var _wrap_new_iFoo unsafe.Pointer - -func _swig_wrap_new_iFoo() (base SwigcptrIFoo) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_iFoo, _swig_p) - return -} - -func NewIFoo() (_swig_ret IFoo) { - return _swig_wrap_new_iFoo() -} - -var _wrap_delete_iFoo unsafe.Pointer - -func _swig_wrap_delete_iFoo(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_iFoo, _swig_p) - return -} - -func DeleteIFoo(arg1 IFoo) { - _swig_wrap_delete_iFoo(arg1.Swigcptr()) -} - -type IFoo interface { - Swigcptr() uintptr - SwigIsIFoo() - Blah_test(arg2 int) (_swig_ret int) - Spam_test(arg2 int) (_swig_ret int) - Groki_test(arg2 int) (_swig_ret int) -} - -type SwigcptrDFoo uintptr - -func (p SwigcptrDFoo) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrDFoo) SwigIsDFoo() { -} - -var _wrap_dFoo_blah_test unsafe.Pointer - -func _swig_wrap_dFoo_blah_test(base SwigcptrDFoo, _ int) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_dFoo_blah_test, _swig_p) - return -} - -func (arg1 SwigcptrDFoo) Blah_test(arg2 int) (_swig_ret int) { - return _swig_wrap_dFoo_blah_test(arg1, arg2) -} - -var _wrap_dFoo_spam unsafe.Pointer - -func _swig_wrap_dFoo_spam(base SwigcptrDFoo, _ int) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_dFoo_spam, _swig_p) - return -} - -func (arg1 SwigcptrDFoo) Spam(arg2 int) (_swig_ret int) { - return _swig_wrap_dFoo_spam(arg1, arg2) -} - -var _wrap_dFoo_grok_test unsafe.Pointer - -func _swig_wrap_dFoo_grok_test(base SwigcptrDFoo, _ int) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_dFoo_grok_test, _swig_p) - return -} - -func (arg1 SwigcptrDFoo) Grok_test(arg2 int) (_swig_ret int) { - return _swig_wrap_dFoo_grok_test(arg1, arg2) -} - -var _wrap_new_dFoo unsafe.Pointer - -func _swig_wrap_new_dFoo() (base SwigcptrDFoo) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_dFoo, _swig_p) - return -} - -func NewDFoo() (_swig_ret DFoo) { - return _swig_wrap_new_dFoo() -} - -var _wrap_delete_dFoo unsafe.Pointer - -func _swig_wrap_delete_dFoo(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_dFoo, _swig_p) - return -} - -func DeleteDFoo(arg1 DFoo) { - _swig_wrap_delete_dFoo(arg1.Swigcptr()) -} - -type DFoo interface { - Swigcptr() uintptr - SwigIsDFoo() - Blah_test(arg2 int) (_swig_ret int) - Spam(arg2 int) (_swig_ret int) - Grok_test(arg2 int) (_swig_ret int) -} - -type SwigcptrFlow uintptr - -func (p SwigcptrFlow) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrFlow) SwigIsFlow() { -} - -var _wrap_new_Flow unsafe.Pointer - -func _swig_wrap_new_Flow(base float64) (_ SwigcptrFlow) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Flow, _swig_p) - return -} - -func NewFlow(arg1 float64) (_swig_ret Flow) { - return _swig_wrap_new_Flow(arg1) -} - -var _wrap_delete_Flow unsafe.Pointer - -func _swig_wrap_delete_Flow(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Flow, _swig_p) - return -} - -func DeleteFlow(arg1 Flow) { - _swig_wrap_delete_Flow(arg1.Swigcptr()) -} - -type Flow interface { - Swigcptr() uintptr - SwigIsFlow() -} - -type SwigcptrVectFlow uintptr - -func (p SwigcptrVectFlow) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrVectFlow) SwigIsVectFlow() { -} - -var _wrap_new_VectFlow unsafe.Pointer - -func _swig_wrap_new_VectFlow() (base SwigcptrVectFlow) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_VectFlow, _swig_p) - return -} - -func NewVectFlow() (_swig_ret VectFlow) { - return _swig_wrap_new_VectFlow() -} - -var _wrap_delete_VectFlow unsafe.Pointer - -func _swig_wrap_delete_VectFlow(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_VectFlow, _swig_p) - return -} - -func DeleteVectFlow(arg1 VectFlow) { - _swig_wrap_delete_VectFlow(arg1.Swigcptr()) -} - -type VectFlow interface { - Swigcptr() uintptr - SwigIsVectFlow() -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/template_rename_runme b/Examples/test-suite/go/template_rename_runme deleted file mode 100755 index 0d8a6626d..000000000 Binary files a/Examples/test-suite/go/template_rename_runme and /dev/null differ diff --git a/Examples/test-suite/go/template_retvalue.go b/Examples/test-suite/go/template_retvalue.go deleted file mode 100644 index 10e6c29d7..000000000 --- a/Examples/test-suite/go/template_retvalue.go +++ /dev/null @@ -1,202 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../template_retvalue.i - -package template_retvalue - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type Hello int -var _wrap_Hi unsafe.Pointer - -func _swig_getHi() (_swig_ret Hello) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_Hi, _swig_p) - return -} -var Hi Hello = _swig_getHi() -var _wrap_Hola unsafe.Pointer - -func _swig_getHola() (_swig_ret Hello) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_Hola, _swig_p) - return -} -var Hola Hello = _swig_getHola() -type SwigcptrC uintptr - -func (p SwigcptrC) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrC) SwigIsC() { -} - -var _wrap_new_C unsafe.Pointer - -func _swig_wrap_new_C(base int) (_ SwigcptrC) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_C, _swig_p) - return -} - -func NewC(arg1 int) (_swig_ret C) { - return _swig_wrap_new_C(arg1) -} - -var _wrap_delete_C unsafe.Pointer - -func _swig_wrap_delete_C(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_C, _swig_p) - return -} - -func DeleteC(arg1 C) { - _swig_wrap_delete_C(arg1.Swigcptr()) -} - -type C interface { - Swigcptr() uintptr - SwigIsC() -} - -type SwigcptrA_Hi uintptr - -func (p SwigcptrA_Hi) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrA_Hi) SwigIsA_Hi() { -} - -var _wrap_new_A_Hi unsafe.Pointer - -func _swig_wrap_new_A_Hi(base int) (_ SwigcptrA_Hi) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_A_Hi, _swig_p) - return -} - -func NewA_Hi(arg1 int) (_swig_ret A_Hi) { - return _swig_wrap_new_A_Hi(arg1) -} - -var _wrap_delete_A_Hi unsafe.Pointer - -func _swig_wrap_delete_A_Hi(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_A_Hi, _swig_p) - return -} - -func DeleteA_Hi(arg1 A_Hi) { - _swig_wrap_delete_A_Hi(arg1.Swigcptr()) -} - -type A_Hi interface { - Swigcptr() uintptr - SwigIsA_Hi() -} - -type SwigcptrB_Hola uintptr - -func (p SwigcptrB_Hola) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrB_Hola) SwigIsB_Hola() { -} - -var _wrap_B_Hola_get_c unsafe.Pointer - -func _swig_wrap_B_Hola_get_c(base SwigcptrB_Hola) (_ SwigcptrC) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_B_Hola_get_c, _swig_p) - return -} - -func (arg1 SwigcptrB_Hola) Get_c() (_swig_ret C) { - return _swig_wrap_B_Hola_get_c(arg1) -} - -var _wrap_B_Hola_get_a unsafe.Pointer - -func _swig_wrap_B_Hola_get_a(base SwigcptrB_Hola) (_ SwigcptrA_Sl_Hola_Sg_) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_B_Hola_get_a, _swig_p) - return -} - -func (arg1 SwigcptrB_Hola) Get_a() (_swig_ret A_Sl_Hola_Sg_) { - return _swig_wrap_B_Hola_get_a(arg1) -} - -var _wrap_new_B_Hola unsafe.Pointer - -func _swig_wrap_new_B_Hola() (base SwigcptrB_Hola) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_B_Hola, _swig_p) - return -} - -func NewB_Hola() (_swig_ret B_Hola) { - return _swig_wrap_new_B_Hola() -} - -var _wrap_delete_B_Hola unsafe.Pointer - -func _swig_wrap_delete_B_Hola(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_B_Hola, _swig_p) - return -} - -func DeleteB_Hola(arg1 B_Hola) { - _swig_wrap_delete_B_Hola(arg1.Swigcptr()) -} - -type B_Hola interface { - Swigcptr() uintptr - SwigIsB_Hola() - Get_c() (_swig_ret C) - Get_a() (_swig_ret A_Sl_Hola_Sg_) -} - - -type SwigcptrA_Sl_Hola_Sg_ uintptr -type A_Sl_Hola_Sg_ interface { - Swigcptr() uintptr; -} -func (p SwigcptrA_Sl_Hola_Sg_) Swigcptr() uintptr { - return uintptr(p) -} - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/template_specialization.go b/Examples/test-suite/go/template_specialization.go deleted file mode 100644 index 6b7a26fc6..000000000 --- a/Examples/test-suite/go/template_specialization.go +++ /dev/null @@ -1,152 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../template_specialization.i - -package template_specialization - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrUnaryFunction_double uintptr - -func (p SwigcptrUnaryFunction_double) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrUnaryFunction_double) SwigIsUnaryFunction_double() { -} - -var _wrap_UnaryFunction_double_negate unsafe.Pointer - -func _swig_wrap_UnaryFunction_double_negate(base SwigcptrUnaryFunction_double) (_ SwigcptrUnaryFunction_double) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_UnaryFunction_double_negate, _swig_p) - return -} - -func (arg1 SwigcptrUnaryFunction_double) Negate() (_swig_ret UnaryFunction_double) { - return _swig_wrap_UnaryFunction_double_negate(arg1) -} - -var _wrap_new_UnaryFunction_double unsafe.Pointer - -func _swig_wrap_new_UnaryFunction_double() (base SwigcptrUnaryFunction_double) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_UnaryFunction_double, _swig_p) - return -} - -func NewUnaryFunction_double() (_swig_ret UnaryFunction_double) { - return _swig_wrap_new_UnaryFunction_double() -} - -var _wrap_delete_UnaryFunction_double unsafe.Pointer - -func _swig_wrap_delete_UnaryFunction_double(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_UnaryFunction_double, _swig_p) - return -} - -func DeleteUnaryFunction_double(arg1 UnaryFunction_double) { - _swig_wrap_delete_UnaryFunction_double(arg1.Swigcptr()) -} - -type UnaryFunction_double interface { - Swigcptr() uintptr - SwigIsUnaryFunction_double() - Negate() (_swig_ret UnaryFunction_double) -} - -type SwigcptrUnaryFunction_bool uintptr - -func (p SwigcptrUnaryFunction_bool) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrUnaryFunction_bool) SwigIsUnaryFunction_bool() { -} - -var _wrap_UnaryFunction_bool_not1 unsafe.Pointer - -func _swig_wrap_UnaryFunction_bool_not1(base SwigcptrUnaryFunction_bool) (_ SwigcptrUnaryFunction_bool) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_UnaryFunction_bool_not1, _swig_p) - return -} - -func (arg1 SwigcptrUnaryFunction_bool) Not1() (_swig_ret UnaryFunction_bool) { - return _swig_wrap_UnaryFunction_bool_not1(arg1) -} - -var _wrap_UnaryFunction_bool_foo unsafe.Pointer - -func _swig_wrap_UnaryFunction_bool_foo(base SwigcptrUnaryFunction_bool, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_UnaryFunction_bool_foo, _swig_p) - return -} - -func (arg1 SwigcptrUnaryFunction_bool) Foo(arg2 UnaryFunction_bool) { - _swig_wrap_UnaryFunction_bool_foo(arg1, arg2.Swigcptr()) -} - -var _wrap_new_UnaryFunction_bool unsafe.Pointer - -func _swig_wrap_new_UnaryFunction_bool() (base SwigcptrUnaryFunction_bool) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_UnaryFunction_bool, _swig_p) - return -} - -func NewUnaryFunction_bool() (_swig_ret UnaryFunction_bool) { - return _swig_wrap_new_UnaryFunction_bool() -} - -var _wrap_delete_UnaryFunction_bool unsafe.Pointer - -func _swig_wrap_delete_UnaryFunction_bool(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_UnaryFunction_bool, _swig_p) - return -} - -func DeleteUnaryFunction_bool(arg1 UnaryFunction_bool) { - _swig_wrap_delete_UnaryFunction_bool(arg1.Swigcptr()) -} - -type UnaryFunction_bool interface { - Swigcptr() uintptr - SwigIsUnaryFunction_bool() - Not1() (_swig_ret UnaryFunction_bool) - Foo(arg2 UnaryFunction_bool) -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/template_specialization_defarg.go b/Examples/test-suite/go/template_specialization_defarg.go deleted file mode 100644 index b9b66377e..000000000 --- a/Examples/test-suite/go/template_specialization_defarg.go +++ /dev/null @@ -1,368 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../template_specialization_defarg.i - -package template_specialization_defarg - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrC_i uintptr - -func (p SwigcptrC_i) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrC_i) SwigIsC_i() { -} - -var _wrap_C_i_hi unsafe.Pointer - -func _swig_wrap_C_i_hi(base SwigcptrC_i) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_C_i_hi, _swig_p) - return -} - -func (arg1 SwigcptrC_i) Hi() (_swig_ret int) { - return _swig_wrap_C_i_hi(arg1) -} - -var _wrap_new_C_i unsafe.Pointer - -func _swig_wrap_new_C_i(base int) (_ SwigcptrC_i) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_C_i, _swig_p) - return -} - -func NewC_i(arg1 int) (_swig_ret C_i) { - return _swig_wrap_new_C_i(arg1) -} - -var _wrap_delete_C_i unsafe.Pointer - -func _swig_wrap_delete_C_i(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_C_i, _swig_p) - return -} - -func DeleteC_i(arg1 C_i) { - _swig_wrap_delete_C_i(arg1.Swigcptr()) -} - -type C_i interface { - Swigcptr() uintptr - SwigIsC_i() - Hi() (_swig_ret int) -} - -type SwigcptrC_dd uintptr - -func (p SwigcptrC_dd) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrC_dd) SwigIsC_dd() { -} - -var _wrap_C_dd_hello unsafe.Pointer - -func _swig_wrap_C_dd_hello(base SwigcptrC_dd) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_C_dd_hello, _swig_p) - return -} - -func (arg1 SwigcptrC_dd) Hello() (_swig_ret int) { - return _swig_wrap_C_dd_hello(arg1) -} - -var _wrap_new_C_dd unsafe.Pointer - -func _swig_wrap_new_C_dd(base float64) (_ SwigcptrC_dd) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_C_dd, _swig_p) - return -} - -func NewC_dd(arg1 float64) (_swig_ret C_dd) { - return _swig_wrap_new_C_dd(arg1) -} - -var _wrap_delete_C_dd unsafe.Pointer - -func _swig_wrap_delete_C_dd(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_C_dd, _swig_p) - return -} - -func DeleteC_dd(arg1 C_dd) { - _swig_wrap_delete_C_dd(arg1.Swigcptr()) -} - -type C_dd interface { - Swigcptr() uintptr - SwigIsC_dd() - Hello() (_swig_ret int) -} - -type SwigcptrC_d uintptr - -func (p SwigcptrC_d) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrC_d) SwigIsC_d() { -} - -var _wrap_C_d_hello unsafe.Pointer - -func _swig_wrap_C_d_hello(base SwigcptrC_d) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_C_d_hello, _swig_p) - return -} - -func (arg1 SwigcptrC_d) Hello() (_swig_ret int) { - return _swig_wrap_C_d_hello(arg1) -} - -var _wrap_new_C_d unsafe.Pointer - -func _swig_wrap_new_C_d(base float64) (_ SwigcptrC_d) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_C_d, _swig_p) - return -} - -func NewC_d(arg1 float64) (_swig_ret C_d) { - return _swig_wrap_new_C_d(arg1) -} - -var _wrap_delete_C_d unsafe.Pointer - -func _swig_wrap_delete_C_d(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_C_d, _swig_p) - return -} - -func DeleteC_d(arg1 C_d) { - _swig_wrap_delete_C_d(arg1.Swigcptr()) -} - -type C_d interface { - Swigcptr() uintptr - SwigIsC_d() - Hello() (_swig_ret int) -} - -type SwigcptrD_i uintptr - -func (p SwigcptrD_i) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrD_i) SwigIsD_i() { -} - -var _wrap_new_D_i unsafe.Pointer - -func _swig_wrap_new_D_i(base int) (_ SwigcptrD_i) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_D_i, _swig_p) - return -} - -func NewD_i(arg1 int) (_swig_ret D_i) { - return _swig_wrap_new_D_i(arg1) -} - -var _wrap_delete_D_i unsafe.Pointer - -func _swig_wrap_delete_D_i(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_D_i, _swig_p) - return -} - -func DeleteD_i(arg1 D_i) { - _swig_wrap_delete_D_i(arg1.Swigcptr()) -} - -type D_i interface { - Swigcptr() uintptr - SwigIsD_i() -} - -type SwigcptrD_d uintptr - -func (p SwigcptrD_d) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrD_d) SwigIsD_d() { -} - -var _wrap_new_D_d unsafe.Pointer - -func _swig_wrap_new_D_d() (base SwigcptrD_d) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_D_d, _swig_p) - return -} - -func NewD_d() (_swig_ret D_d) { - return _swig_wrap_new_D_d() -} - -var _wrap_D_d_foo unsafe.Pointer - -func _swig_wrap_D_d_foo(base SwigcptrD_d) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_D_d_foo, _swig_p) - return -} - -func (arg1 SwigcptrD_d) Foo() (_swig_ret int) { - return _swig_wrap_D_d_foo(arg1) -} - -var _wrap_delete_D_d unsafe.Pointer - -func _swig_wrap_delete_D_d(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_D_d, _swig_p) - return -} - -func DeleteD_d(arg1 D_d) { - _swig_wrap_delete_D_d(arg1.Swigcptr()) -} - -type D_d interface { - Swigcptr() uintptr - SwigIsD_d() - Foo() (_swig_ret int) -} - -type SwigcptrVector_i uintptr - -func (p SwigcptrVector_i) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrVector_i) SwigIsVector_i() { -} - -var _wrap_new_Vector_i unsafe.Pointer - -func _swig_wrap_new_Vector_i(base int) (_ SwigcptrVector_i) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Vector_i, _swig_p) - return -} - -func NewVector_i(arg1 int) (_swig_ret Vector_i) { - return _swig_wrap_new_Vector_i(arg1) -} - -var _wrap_delete_Vector_i unsafe.Pointer - -func _swig_wrap_delete_Vector_i(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Vector_i, _swig_p) - return -} - -func DeleteVector_i(arg1 Vector_i) { - _swig_wrap_delete_Vector_i(arg1.Swigcptr()) -} - -type Vector_i interface { - Swigcptr() uintptr - SwigIsVector_i() -} - -type SwigcptrVector_d uintptr - -func (p SwigcptrVector_d) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrVector_d) SwigIsVector_d() { -} - -var _wrap_new_Vector_d unsafe.Pointer - -func _swig_wrap_new_Vector_d() (base SwigcptrVector_d) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Vector_d, _swig_p) - return -} - -func NewVector_d() (_swig_ret Vector_d) { - return _swig_wrap_new_Vector_d() -} - -var _wrap_Vector_d_foo unsafe.Pointer - -func _swig_wrap_Vector_d_foo(base SwigcptrVector_d) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Vector_d_foo, _swig_p) - return -} - -func (arg1 SwigcptrVector_d) Foo() (_swig_ret int) { - return _swig_wrap_Vector_d_foo(arg1) -} - -var _wrap_delete_Vector_d unsafe.Pointer - -func _swig_wrap_delete_Vector_d(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Vector_d, _swig_p) - return -} - -func DeleteVector_d(arg1 Vector_d) { - _swig_wrap_delete_Vector_d(arg1.Swigcptr()) -} - -type Vector_d interface { - Swigcptr() uintptr - SwigIsVector_d() - Foo() (_swig_ret int) -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/template_specialization_enum.go b/Examples/test-suite/go/template_specialization_enum.go deleted file mode 100644 index 40fc24677..000000000 --- a/Examples/test-suite/go/template_specialization_enum.go +++ /dev/null @@ -1,218 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../template_specialization_enum.i - -package template_specialization_enum - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type Hello int -var _wrap_hi unsafe.Pointer - -func _swig_gethi() (_swig_ret Hello) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_hi, _swig_p) - return -} -var Hi Hello = _swig_gethi() -type SwigcptrBase_dd uintptr - -func (p SwigcptrBase_dd) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrBase_dd) SwigIsBase_dd() { -} - -var _wrap_new_Base_dd unsafe.Pointer - -func _swig_wrap_new_Base_dd() (base SwigcptrBase_dd) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Base_dd, _swig_p) - return -} - -func NewBase_dd() (_swig_ret Base_dd) { - return _swig_wrap_new_Base_dd() -} - -var _wrap_delete_Base_dd unsafe.Pointer - -func _swig_wrap_delete_Base_dd(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Base_dd, _swig_p) - return -} - -func DeleteBase_dd(arg1 Base_dd) { - _swig_wrap_delete_Base_dd(arg1.Swigcptr()) -} - -type Base_dd interface { - Swigcptr() uintptr - SwigIsBase_dd() -} - -type SwigcptrBase_ii uintptr - -func (p SwigcptrBase_ii) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrBase_ii) SwigIsBase_ii() { -} - -var _wrap_new_Base_ii unsafe.Pointer - -func _swig_wrap_new_Base_ii() (base SwigcptrBase_ii) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Base_ii, _swig_p) - return -} - -func NewBase_ii() (_swig_ret Base_ii) { - return _swig_wrap_new_Base_ii() -} - -var _wrap_delete_Base_ii unsafe.Pointer - -func _swig_wrap_delete_Base_ii(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Base_ii, _swig_p) - return -} - -func DeleteBase_ii(arg1 Base_ii) { - _swig_wrap_delete_Base_ii(arg1.Swigcptr()) -} - -type Base_ii interface { - Swigcptr() uintptr - SwigIsBase_ii() -} - -type SwigcptrC_i uintptr - -func (p SwigcptrC_i) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrC_i) SwigIsC_i() { -} - -var _wrap_C_i_fhi unsafe.Pointer - -func _swig_wrap_C_i_fhi(base SwigcptrC_i) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_C_i_fhi, _swig_p) - return -} - -func (arg1 SwigcptrC_i) Fhi() (_swig_ret int) { - return _swig_wrap_C_i_fhi(arg1) -} - -var _wrap_delete_C_i unsafe.Pointer - -func _swig_wrap_delete_C_i(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_C_i, _swig_p) - return -} - -func DeleteC_i(arg1 C_i) { - _swig_wrap_delete_C_i(arg1.Swigcptr()) -} - -func (p SwigcptrC_i) SwigIsBase_dd() { -} - -func (p SwigcptrC_i) SwigGetBase_dd() Base_dd { - return SwigcptrBase_dd(p.Swigcptr()) -} - -type C_i interface { - Swigcptr() uintptr - SwigIsC_i() - Fhi() (_swig_ret int) - SwigIsBase_dd() - SwigGetBase_dd() Base_dd -} - -type SwigcptrC_d uintptr - -func (p SwigcptrC_d) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrC_d) SwigIsC_d() { -} - -var _wrap_C_d_fhello unsafe.Pointer - -func _swig_wrap_C_d_fhello(base SwigcptrC_d) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_C_d_fhello, _swig_p) - return -} - -func (arg1 SwigcptrC_d) Fhello() (_swig_ret int) { - return _swig_wrap_C_d_fhello(arg1) -} - -var _wrap_delete_C_d unsafe.Pointer - -func _swig_wrap_delete_C_d(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_C_d, _swig_p) - return -} - -func DeleteC_d(arg1 C_d) { - _swig_wrap_delete_C_d(arg1.Swigcptr()) -} - -func (p SwigcptrC_d) SwigIsBase_ii() { -} - -func (p SwigcptrC_d) SwigGetBase_ii() Base_ii { - return SwigcptrBase_ii(p.Swigcptr()) -} - -type C_d interface { - Swigcptr() uintptr - SwigIsC_d() - Fhello() (_swig_ret int) - SwigIsBase_ii() - SwigGetBase_ii() Base_ii -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/template_static.go b/Examples/test-suite/go/template_static.go deleted file mode 100644 index 5dc9d9660..000000000 --- a/Examples/test-suite/go/template_static.go +++ /dev/null @@ -1,196 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../template_static.i - -package template_static - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrFoo_i uintptr - -func (p SwigcptrFoo_i) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrFoo_i) SwigIsFoo_i() { -} - -var _wrap_foo_i_test_set unsafe.Pointer - -func _swig_wrap_foo_i_test_set(base int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_foo_i_test_set, _swig_p) - return -} - -func SetFoo_iTest(arg1 int) { - _swig_wrap_foo_i_test_set(arg1) -} - -var _wrap_foo_i_test_get unsafe.Pointer - -func GetFoo_iTest() (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_foo_i_test_get, _swig_p) - return -} -var _wrap_new_foo_i unsafe.Pointer - -func _swig_wrap_new_foo_i() (base SwigcptrFoo_i) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_foo_i, _swig_p) - return -} - -func NewFoo_i() (_swig_ret Foo_i) { - return _swig_wrap_new_foo_i() -} - -var _wrap_delete_foo_i unsafe.Pointer - -func _swig_wrap_delete_foo_i(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_foo_i, _swig_p) - return -} - -func DeleteFoo_i(arg1 Foo_i) { - _swig_wrap_delete_foo_i(arg1.Swigcptr()) -} - -type Foo_i interface { - Swigcptr() uintptr - SwigIsFoo_i() -} - -type SwigcptrFoo_d uintptr - -func (p SwigcptrFoo_d) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrFoo_d) SwigIsFoo_d() { -} - -var _wrap_foo_d_test_set unsafe.Pointer - -func _swig_wrap_foo_d_test_set(base int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_foo_d_test_set, _swig_p) - return -} - -func SetFoo_dTest(arg1 int) { - _swig_wrap_foo_d_test_set(arg1) -} - -var _wrap_foo_d_test_get unsafe.Pointer - -func GetFoo_dTest() (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_foo_d_test_get, _swig_p) - return -} -var _wrap_new_foo_d unsafe.Pointer - -func _swig_wrap_new_foo_d() (base SwigcptrFoo_d) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_foo_d, _swig_p) - return -} - -func NewFoo_d() (_swig_ret Foo_d) { - return _swig_wrap_new_foo_d() -} - -var _wrap_delete_foo_d unsafe.Pointer - -func _swig_wrap_delete_foo_d(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_foo_d, _swig_p) - return -} - -func DeleteFoo_d(arg1 Foo_d) { - _swig_wrap_delete_foo_d(arg1.Swigcptr()) -} - -type Foo_d interface { - Swigcptr() uintptr - SwigIsFoo_d() -} - -type SwigcptrFoo uintptr - -func (p SwigcptrFoo) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrFoo) SwigIsFoo() { -} - -var _wrap_Foo_bar_double unsafe.Pointer - -func FooBar_double(arg1 int) (_swig_ret float64) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_Foo_bar_double, _swig_p) - return -} -var _wrap_new_Foo unsafe.Pointer - -func _swig_wrap_new_Foo() (base SwigcptrFoo) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Foo, _swig_p) - return -} - -func NewFoo() (_swig_ret Foo) { - return _swig_wrap_new_Foo() -} - -var _wrap_delete_Foo unsafe.Pointer - -func _swig_wrap_delete_Foo(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Foo, _swig_p) - return -} - -func DeleteFoo(arg1 Foo) { - _swig_wrap_delete_Foo(arg1.Swigcptr()) -} - -type Foo interface { - Swigcptr() uintptr - SwigIsFoo() -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/template_static_runme b/Examples/test-suite/go/template_static_runme deleted file mode 100755 index 4065ea8e4..000000000 Binary files a/Examples/test-suite/go/template_static_runme and /dev/null differ diff --git a/Examples/test-suite/go/template_tbase_template.go b/Examples/test-suite/go/template_tbase_template.go deleted file mode 100644 index 0f78b0cff..000000000 --- a/Examples/test-suite/go/template_tbase_template.go +++ /dev/null @@ -1,198 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../template_tbase_template.i - -package template_tbase_template - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrTraits_dd uintptr - -func (p SwigcptrTraits_dd) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrTraits_dd) SwigIsTraits_dd() { -} - -var _wrap_new_traits_dd unsafe.Pointer - -func _swig_wrap_new_traits_dd() (base SwigcptrTraits_dd) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_traits_dd, _swig_p) - return -} - -func NewTraits_dd() (_swig_ret Traits_dd) { - return _swig_wrap_new_traits_dd() -} - -var _wrap_delete_traits_dd unsafe.Pointer - -func _swig_wrap_delete_traits_dd(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_traits_dd, _swig_p) - return -} - -func DeleteTraits_dd(arg1 Traits_dd) { - _swig_wrap_delete_traits_dd(arg1.Swigcptr()) -} - -type Traits_dd interface { - Swigcptr() uintptr - SwigIsTraits_dd() -} - -type SwigcptrFunktion_dd uintptr - -func (p SwigcptrFunktion_dd) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrFunktion_dd) SwigIsFunktion_dd() { -} - -var _wrap_Funktion_dd_test unsafe.Pointer - -func _swig_wrap_Funktion_dd_test(base SwigcptrFunktion_dd) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Funktion_dd_test, _swig_p) - return -} - -func (arg1 SwigcptrFunktion_dd) Test() (_swig_ret string) { - return _swig_wrap_Funktion_dd_test(arg1) -} - -var _wrap_new_Funktion_dd unsafe.Pointer - -func _swig_wrap_new_Funktion_dd() (base SwigcptrFunktion_dd) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Funktion_dd, _swig_p) - return -} - -func NewFunktion_dd() (_swig_ret Funktion_dd) { - return _swig_wrap_new_Funktion_dd() -} - -var _wrap_delete_Funktion_dd unsafe.Pointer - -func _swig_wrap_delete_Funktion_dd(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Funktion_dd, _swig_p) - return -} - -func DeleteFunktion_dd(arg1 Funktion_dd) { - _swig_wrap_delete_Funktion_dd(arg1.Swigcptr()) -} - -type Funktion_dd interface { - Swigcptr() uintptr - SwigIsFunktion_dd() - Test() (_swig_ret string) -} - -type SwigcptrClass_dd uintptr - -func (p SwigcptrClass_dd) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrClass_dd) SwigIsClass_dd() { -} - -var _wrap_new_Class_dd unsafe.Pointer - -func _swig_wrap_new_Class_dd() (base SwigcptrClass_dd) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Class_dd, _swig_p) - return -} - -func NewClass_dd() (_swig_ret Class_dd) { - return _swig_wrap_new_Class_dd() -} - -var _wrap_delete_Class_dd unsafe.Pointer - -func _swig_wrap_delete_Class_dd(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Class_dd, _swig_p) - return -} - -func DeleteClass_dd(arg1 Class_dd) { - _swig_wrap_delete_Class_dd(arg1.Swigcptr()) -} - -var _wrap_Class_dd_test unsafe.Pointer - -func _swig_wrap_Class_dd_test(base SwigcptrClass_dd) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Class_dd_test, _swig_p) - return -} - -func (_swig_base SwigcptrClass_dd) Test() (_swig_ret string) { - return _swig_wrap_Class_dd_test(_swig_base) -} - -func (p SwigcptrClass_dd) SwigIsFunktion_dd() { -} - -func (p SwigcptrClass_dd) SwigGetFunktion_dd() Funktion_dd { - return SwigcptrFunktion_dd(p.Swigcptr()) -} - -type Class_dd interface { - Swigcptr() uintptr - SwigIsClass_dd() - Test() (_swig_ret string) - SwigIsFunktion_dd() - SwigGetFunktion_dd() Funktion_dd -} - -var _wrap_make_Class_dd unsafe.Pointer - -func _swig_wrap_make_Class_dd() (base SwigcptrFunktion_dd) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_make_Class_dd, _swig_p) - return -} - -func Make_Class_dd() (_swig_ret Funktion_dd) { - return _swig_wrap_make_Class_dd() -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/template_tbase_template_runme b/Examples/test-suite/go/template_tbase_template_runme deleted file mode 100755 index 64e808a02..000000000 Binary files a/Examples/test-suite/go/template_tbase_template_runme and /dev/null differ diff --git a/Examples/test-suite/go/template_template_parameters.go b/Examples/test-suite/go/template_template_parameters.go deleted file mode 100644 index 37f34a689..000000000 --- a/Examples/test-suite/go/template_template_parameters.go +++ /dev/null @@ -1,297 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../template_template_parameters.i - -package template_template_parameters - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -var _wrap_TestInstantiations unsafe.Pointer - -func _swig_wrap_TestInstantiations() { - var _swig_p uintptr - _cgo_runtime_cgocall(_wrap_TestInstantiations, _swig_p) - return -} - -func TestInstantiations() { - _swig_wrap_TestInstantiations() -} - -type SwigcptrListImplFastBool uintptr - -func (p SwigcptrListImplFastBool) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrListImplFastBool) SwigIsListImplFastBool() { -} - -var _wrap_new_ListImplFastBool unsafe.Pointer - -func _swig_wrap_new_ListImplFastBool() (base SwigcptrListImplFastBool) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_ListImplFastBool, _swig_p) - return -} - -func NewListImplFastBool() (_swig_ret ListImplFastBool) { - return _swig_wrap_new_ListImplFastBool() -} - -var _wrap_delete_ListImplFastBool unsafe.Pointer - -func _swig_wrap_delete_ListImplFastBool(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_ListImplFastBool, _swig_p) - return -} - -func DeleteListImplFastBool(arg1 ListImplFastBool) { - _swig_wrap_delete_ListImplFastBool(arg1.Swigcptr()) -} - -type ListImplFastBool interface { - Swigcptr() uintptr - SwigIsListImplFastBool() -} - -type SwigcptrListFastBool uintptr - -func (p SwigcptrListFastBool) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrListFastBool) SwigIsListFastBool() { -} - -var _wrap_ListFastBool_item_set unsafe.Pointer - -func _swig_wrap_ListFastBool_item_set(base SwigcptrListFastBool, _ bool) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_ListFastBool_item_set, _swig_p) - return -} - -func (arg1 SwigcptrListFastBool) SetItem(arg2 bool) { - _swig_wrap_ListFastBool_item_set(arg1, arg2) -} - -var _wrap_ListFastBool_item_get unsafe.Pointer - -func _swig_wrap_ListFastBool_item_get(base SwigcptrListFastBool) (_ bool) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_ListFastBool_item_get, _swig_p) - return -} - -func (arg1 SwigcptrListFastBool) GetItem() (_swig_ret bool) { - return _swig_wrap_ListFastBool_item_get(arg1) -} - -var _wrap_ListFastBool_xx unsafe.Pointer - -func _swig_wrap_ListFastBool_xx(base SwigcptrListFastBool) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_ListFastBool_xx, _swig_p) - return -} - -func (arg1 SwigcptrListFastBool) Xx() { - _swig_wrap_ListFastBool_xx(arg1) -} - -var _wrap_new_ListFastBool unsafe.Pointer - -func _swig_wrap_new_ListFastBool() (base SwigcptrListFastBool) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_ListFastBool, _swig_p) - return -} - -func NewListFastBool() (_swig_ret ListFastBool) { - return _swig_wrap_new_ListFastBool() -} - -var _wrap_delete_ListFastBool unsafe.Pointer - -func _swig_wrap_delete_ListFastBool(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_ListFastBool, _swig_p) - return -} - -func DeleteListFastBool(arg1 ListFastBool) { - _swig_wrap_delete_ListFastBool(arg1.Swigcptr()) -} - -func (p SwigcptrListFastBool) SwigIsListImplFastBool() { -} - -func (p SwigcptrListFastBool) SwigGetListImplFastBool() ListImplFastBool { - return SwigcptrListImplFastBool(p.Swigcptr()) -} - -type ListFastBool interface { - Swigcptr() uintptr - SwigIsListFastBool() - SetItem(arg2 bool) - GetItem() (_swig_ret bool) - Xx() - SwigIsListImplFastBool() - SwigGetListImplFastBool() ListImplFastBool -} - -type SwigcptrListImplFastDouble uintptr - -func (p SwigcptrListImplFastDouble) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrListImplFastDouble) SwigIsListImplFastDouble() { -} - -var _wrap_new_ListImplFastDouble unsafe.Pointer - -func _swig_wrap_new_ListImplFastDouble() (base SwigcptrListImplFastDouble) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_ListImplFastDouble, _swig_p) - return -} - -func NewListImplFastDouble() (_swig_ret ListImplFastDouble) { - return _swig_wrap_new_ListImplFastDouble() -} - -var _wrap_delete_ListImplFastDouble unsafe.Pointer - -func _swig_wrap_delete_ListImplFastDouble(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_ListImplFastDouble, _swig_p) - return -} - -func DeleteListImplFastDouble(arg1 ListImplFastDouble) { - _swig_wrap_delete_ListImplFastDouble(arg1.Swigcptr()) -} - -type ListImplFastDouble interface { - Swigcptr() uintptr - SwigIsListImplFastDouble() -} - -type SwigcptrListDefaultDouble uintptr - -func (p SwigcptrListDefaultDouble) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrListDefaultDouble) SwigIsListDefaultDouble() { -} - -var _wrap_ListDefaultDouble_item_set unsafe.Pointer - -func _swig_wrap_ListDefaultDouble_item_set(base SwigcptrListDefaultDouble, _ float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_ListDefaultDouble_item_set, _swig_p) - return -} - -func (arg1 SwigcptrListDefaultDouble) SetItem(arg2 float64) { - _swig_wrap_ListDefaultDouble_item_set(arg1, arg2) -} - -var _wrap_ListDefaultDouble_item_get unsafe.Pointer - -func _swig_wrap_ListDefaultDouble_item_get(base SwigcptrListDefaultDouble) (_ float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_ListDefaultDouble_item_get, _swig_p) - return -} - -func (arg1 SwigcptrListDefaultDouble) GetItem() (_swig_ret float64) { - return _swig_wrap_ListDefaultDouble_item_get(arg1) -} - -var _wrap_ListDefaultDouble_xx unsafe.Pointer - -func _swig_wrap_ListDefaultDouble_xx(base SwigcptrListDefaultDouble) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_ListDefaultDouble_xx, _swig_p) - return -} - -func (arg1 SwigcptrListDefaultDouble) Xx() { - _swig_wrap_ListDefaultDouble_xx(arg1) -} - -var _wrap_new_ListDefaultDouble unsafe.Pointer - -func _swig_wrap_new_ListDefaultDouble() (base SwigcptrListDefaultDouble) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_ListDefaultDouble, _swig_p) - return -} - -func NewListDefaultDouble() (_swig_ret ListDefaultDouble) { - return _swig_wrap_new_ListDefaultDouble() -} - -var _wrap_delete_ListDefaultDouble unsafe.Pointer - -func _swig_wrap_delete_ListDefaultDouble(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_ListDefaultDouble, _swig_p) - return -} - -func DeleteListDefaultDouble(arg1 ListDefaultDouble) { - _swig_wrap_delete_ListDefaultDouble(arg1.Swigcptr()) -} - -func (p SwigcptrListDefaultDouble) SwigIsListImplFastDouble() { -} - -func (p SwigcptrListDefaultDouble) SwigGetListImplFastDouble() ListImplFastDouble { - return SwigcptrListImplFastDouble(p.Swigcptr()) -} - -type ListDefaultDouble interface { - Swigcptr() uintptr - SwigIsListDefaultDouble() - SetItem(arg2 float64) - GetItem() (_swig_ret float64) - Xx() - SwigIsListImplFastDouble() - SwigGetListImplFastDouble() ListImplFastDouble -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/template_type_namespace.go b/Examples/test-suite/go/template_type_namespace.go deleted file mode 100644 index eb6253111..000000000 --- a/Examples/test-suite/go/template_type_namespace.go +++ /dev/null @@ -1,214 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../template_type_namespace.i - -package template_type_namespace - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrString_vector uintptr - -func (p SwigcptrString_vector) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrString_vector) SwigIsString_vector() { -} - -var _wrap_new_string_vector__SWIG_0 unsafe.Pointer - -func _swig_wrap_new_string_vector__SWIG_0() (base SwigcptrString_vector) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_string_vector__SWIG_0, _swig_p) - return -} - -func NewString_vector__SWIG_0() (_swig_ret String_vector) { - return _swig_wrap_new_string_vector__SWIG_0() -} - -var _wrap_new_string_vector__SWIG_1 unsafe.Pointer - -func _swig_wrap_new_string_vector__SWIG_1(base int64) (_ SwigcptrString_vector) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_string_vector__SWIG_1, _swig_p) - return -} - -func NewString_vector__SWIG_1(arg1 int64) (_swig_ret String_vector) { - return _swig_wrap_new_string_vector__SWIG_1(arg1) -} - -func NewString_vector(a ...interface{}) String_vector { - argc := len(a) - if argc == 0 { - return NewString_vector__SWIG_0() - } - if argc == 1 { - return NewString_vector__SWIG_1(a[0].(int64)) - } - panic("No match for overloaded function call") -} - -var _wrap_string_vector_size unsafe.Pointer - -func _swig_wrap_string_vector_size(base SwigcptrString_vector) (_ int64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_string_vector_size, _swig_p) - return -} - -func (arg1 SwigcptrString_vector) Size() (_swig_ret int64) { - return _swig_wrap_string_vector_size(arg1) -} - -var _wrap_string_vector_capacity unsafe.Pointer - -func _swig_wrap_string_vector_capacity(base SwigcptrString_vector) (_ int64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_string_vector_capacity, _swig_p) - return -} - -func (arg1 SwigcptrString_vector) Capacity() (_swig_ret int64) { - return _swig_wrap_string_vector_capacity(arg1) -} - -var _wrap_string_vector_reserve unsafe.Pointer - -func _swig_wrap_string_vector_reserve(base SwigcptrString_vector, _ int64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_string_vector_reserve, _swig_p) - return -} - -func (arg1 SwigcptrString_vector) Reserve(arg2 int64) { - _swig_wrap_string_vector_reserve(arg1, arg2) -} - -var _wrap_string_vector_isEmpty unsafe.Pointer - -func _swig_wrap_string_vector_isEmpty(base SwigcptrString_vector) (_ bool) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_string_vector_isEmpty, _swig_p) - return -} - -func (arg1 SwigcptrString_vector) IsEmpty() (_swig_ret bool) { - return _swig_wrap_string_vector_isEmpty(arg1) -} - -var _wrap_string_vector_clear unsafe.Pointer - -func _swig_wrap_string_vector_clear(base SwigcptrString_vector) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_string_vector_clear, _swig_p) - return -} - -func (arg1 SwigcptrString_vector) Clear() { - _swig_wrap_string_vector_clear(arg1) -} - -var _wrap_string_vector_add unsafe.Pointer - -func _swig_wrap_string_vector_add(base SwigcptrString_vector, _ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_string_vector_add, _swig_p) - return -} - -func (arg1 SwigcptrString_vector) Add(arg2 string) { - _swig_wrap_string_vector_add(arg1, arg2) -} - -var _wrap_string_vector_get unsafe.Pointer - -func _swig_wrap_string_vector_get(base SwigcptrString_vector, _ int) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_string_vector_get, _swig_p) - return -} - -func (arg1 SwigcptrString_vector) Get(arg2 int) (_swig_ret string) { - return _swig_wrap_string_vector_get(arg1, arg2) -} - -var _wrap_string_vector_set unsafe.Pointer - -func _swig_wrap_string_vector_set(base SwigcptrString_vector, _ int, _ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_string_vector_set, _swig_p) - return -} - -func (arg1 SwigcptrString_vector) Set(arg2 int, arg3 string) { - _swig_wrap_string_vector_set(arg1, arg2, arg3) -} - -var _wrap_delete_string_vector unsafe.Pointer - -func _swig_wrap_delete_string_vector(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_string_vector, _swig_p) - return -} - -func DeleteString_vector(arg1 String_vector) { - _swig_wrap_delete_string_vector(arg1.Swigcptr()) -} - -type String_vector interface { - Swigcptr() uintptr - SwigIsString_vector() - Size() (_swig_ret int64) - Capacity() (_swig_ret int64) - Reserve(arg2 int64) - IsEmpty() (_swig_ret bool) - Clear() - Add(arg2 string) - Get(arg2 int) (_swig_ret string) - Set(arg2 int, arg3 string) -} - -var _wrap_foo unsafe.Pointer - -func _swig_wrap_foo() (base SwigcptrString_vector) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_foo, _swig_p) - return -} - -func Foo() (_swig_ret String_vector) { - return _swig_wrap_foo() -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/template_type_namespace_runme b/Examples/test-suite/go/template_type_namespace_runme deleted file mode 100755 index 65afce038..000000000 Binary files a/Examples/test-suite/go/template_type_namespace_runme and /dev/null differ diff --git a/Examples/test-suite/go/template_typedef.go b/Examples/test-suite/go/template_typedef.go deleted file mode 100644 index 1f179e277..000000000 --- a/Examples/test-suite/go/template_typedef.go +++ /dev/null @@ -1,444 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../template_typedef.i - -package template_typedef - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrUnaryFunctionBase uintptr - -func (p SwigcptrUnaryFunctionBase) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrUnaryFunctionBase) SwigIsUnaryFunctionBase() { -} - -var _wrap_new_UnaryFunctionBase unsafe.Pointer - -func _swig_wrap_new_UnaryFunctionBase() (base SwigcptrUnaryFunctionBase) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_UnaryFunctionBase, _swig_p) - return -} - -func NewUnaryFunctionBase() (_swig_ret UnaryFunctionBase) { - return _swig_wrap_new_UnaryFunctionBase() -} - -var _wrap_delete_UnaryFunctionBase unsafe.Pointer - -func _swig_wrap_delete_UnaryFunctionBase(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_UnaryFunctionBase, _swig_p) - return -} - -func DeleteUnaryFunctionBase(arg1 UnaryFunctionBase) { - _swig_wrap_delete_UnaryFunctionBase(arg1.Swigcptr()) -} - -type UnaryFunctionBase interface { - Swigcptr() uintptr - SwigIsUnaryFunctionBase() -} - -type SwigcptrUnaryFunction_float_float uintptr - -func (p SwigcptrUnaryFunction_float_float) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrUnaryFunction_float_float) SwigIsUnaryFunction_float_float() { -} - -var _wrap_new_UnaryFunction_float_float unsafe.Pointer - -func _swig_wrap_new_UnaryFunction_float_float() (base SwigcptrUnaryFunction_float_float) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_UnaryFunction_float_float, _swig_p) - return -} - -func NewUnaryFunction_float_float() (_swig_ret UnaryFunction_float_float) { - return _swig_wrap_new_UnaryFunction_float_float() -} - -var _wrap_delete_UnaryFunction_float_float unsafe.Pointer - -func _swig_wrap_delete_UnaryFunction_float_float(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_UnaryFunction_float_float, _swig_p) - return -} - -func DeleteUnaryFunction_float_float(arg1 UnaryFunction_float_float) { - _swig_wrap_delete_UnaryFunction_float_float(arg1.Swigcptr()) -} - -func (p SwigcptrUnaryFunction_float_float) SwigIsUnaryFunctionBase() { -} - -func (p SwigcptrUnaryFunction_float_float) SwigGetUnaryFunctionBase() UnaryFunctionBase { - return SwigcptrUnaryFunctionBase(p.Swigcptr()) -} - -type UnaryFunction_float_float interface { - Swigcptr() uintptr - SwigIsUnaryFunction_float_float() - SwigIsUnaryFunctionBase() - SwigGetUnaryFunctionBase() UnaryFunctionBase -} - -type SwigcptrArithUnaryFunction_float_float uintptr - -func (p SwigcptrArithUnaryFunction_float_float) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrArithUnaryFunction_float_float) SwigIsArithUnaryFunction_float_float() { -} - -var _wrap_new_ArithUnaryFunction_float_float unsafe.Pointer - -func _swig_wrap_new_ArithUnaryFunction_float_float() (base SwigcptrArithUnaryFunction_float_float) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_ArithUnaryFunction_float_float, _swig_p) - return -} - -func NewArithUnaryFunction_float_float() (_swig_ret ArithUnaryFunction_float_float) { - return _swig_wrap_new_ArithUnaryFunction_float_float() -} - -var _wrap_delete_ArithUnaryFunction_float_float unsafe.Pointer - -func _swig_wrap_delete_ArithUnaryFunction_float_float(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_ArithUnaryFunction_float_float, _swig_p) - return -} - -func DeleteArithUnaryFunction_float_float(arg1 ArithUnaryFunction_float_float) { - _swig_wrap_delete_ArithUnaryFunction_float_float(arg1.Swigcptr()) -} - -func (p SwigcptrArithUnaryFunction_float_float) SwigIsUnaryFunction_float_float() { -} - -func (p SwigcptrArithUnaryFunction_float_float) SwigGetUnaryFunction_float_float() UnaryFunction_float_float { - return SwigcptrUnaryFunction_float_float(p.Swigcptr()) -} - -func (p SwigcptrArithUnaryFunction_float_float) SwigIsUnaryFunctionBase() { -} - -func (p SwigcptrArithUnaryFunction_float_float) SwigGetUnaryFunctionBase() UnaryFunctionBase { - return SwigcptrUnaryFunctionBase(p.Swigcptr()) -} - -type ArithUnaryFunction_float_float interface { - Swigcptr() uintptr - SwigIsArithUnaryFunction_float_float() - SwigIsUnaryFunction_float_float() - SwigGetUnaryFunction_float_float() UnaryFunction_float_float - SwigIsUnaryFunctionBase() - SwigGetUnaryFunctionBase() UnaryFunctionBase -} - -var _wrap_make_Identity_float unsafe.Pointer - -func _swig_wrap_make_Identity_float() (base SwigcptrArithUnaryFunction_float_float) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_make_Identity_float, _swig_p) - return -} - -func Make_Identity_float() (_swig_ret ArithUnaryFunction_float_float) { - return _swig_wrap_make_Identity_float() -} - -type SwigcptrUnaryFunction_reald_reald uintptr - -func (p SwigcptrUnaryFunction_reald_reald) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrUnaryFunction_reald_reald) SwigIsUnaryFunction_reald_reald() { -} - -var _wrap_new_UnaryFunction_reald_reald unsafe.Pointer - -func _swig_wrap_new_UnaryFunction_reald_reald() (base SwigcptrUnaryFunction_reald_reald) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_UnaryFunction_reald_reald, _swig_p) - return -} - -func NewUnaryFunction_reald_reald() (_swig_ret UnaryFunction_reald_reald) { - return _swig_wrap_new_UnaryFunction_reald_reald() -} - -var _wrap_delete_UnaryFunction_reald_reald unsafe.Pointer - -func _swig_wrap_delete_UnaryFunction_reald_reald(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_UnaryFunction_reald_reald, _swig_p) - return -} - -func DeleteUnaryFunction_reald_reald(arg1 UnaryFunction_reald_reald) { - _swig_wrap_delete_UnaryFunction_reald_reald(arg1.Swigcptr()) -} - -func (p SwigcptrUnaryFunction_reald_reald) SwigIsUnaryFunctionBase() { -} - -func (p SwigcptrUnaryFunction_reald_reald) SwigGetUnaryFunctionBase() UnaryFunctionBase { - return SwigcptrUnaryFunctionBase(p.Swigcptr()) -} - -type UnaryFunction_reald_reald interface { - Swigcptr() uintptr - SwigIsUnaryFunction_reald_reald() - SwigIsUnaryFunctionBase() - SwigGetUnaryFunctionBase() UnaryFunctionBase -} - -type SwigcptrArithUnaryFunction_reald_reald uintptr - -func (p SwigcptrArithUnaryFunction_reald_reald) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrArithUnaryFunction_reald_reald) SwigIsArithUnaryFunction_reald_reald() { -} - -var _wrap_new_ArithUnaryFunction_reald_reald unsafe.Pointer - -func _swig_wrap_new_ArithUnaryFunction_reald_reald() (base SwigcptrArithUnaryFunction_reald_reald) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_ArithUnaryFunction_reald_reald, _swig_p) - return -} - -func NewArithUnaryFunction_reald_reald() (_swig_ret ArithUnaryFunction_reald_reald) { - return _swig_wrap_new_ArithUnaryFunction_reald_reald() -} - -var _wrap_delete_ArithUnaryFunction_reald_reald unsafe.Pointer - -func _swig_wrap_delete_ArithUnaryFunction_reald_reald(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_ArithUnaryFunction_reald_reald, _swig_p) - return -} - -func DeleteArithUnaryFunction_reald_reald(arg1 ArithUnaryFunction_reald_reald) { - _swig_wrap_delete_ArithUnaryFunction_reald_reald(arg1.Swigcptr()) -} - -func (p SwigcptrArithUnaryFunction_reald_reald) SwigIsUnaryFunction_reald_reald() { -} - -func (p SwigcptrArithUnaryFunction_reald_reald) SwigGetUnaryFunction_reald_reald() UnaryFunction_reald_reald { - return SwigcptrUnaryFunction_reald_reald(p.Swigcptr()) -} - -func (p SwigcptrArithUnaryFunction_reald_reald) SwigIsUnaryFunctionBase() { -} - -func (p SwigcptrArithUnaryFunction_reald_reald) SwigGetUnaryFunctionBase() UnaryFunctionBase { - return SwigcptrUnaryFunctionBase(p.Swigcptr()) -} - -type ArithUnaryFunction_reald_reald interface { - Swigcptr() uintptr - SwigIsArithUnaryFunction_reald_reald() - SwigIsUnaryFunction_reald_reald() - SwigGetUnaryFunction_reald_reald() UnaryFunction_reald_reald - SwigIsUnaryFunctionBase() - SwigGetUnaryFunctionBase() UnaryFunctionBase -} - -var _wrap_make_Identity_reald unsafe.Pointer - -func _swig_wrap_make_Identity_reald() (base SwigcptrArithUnaryFunction_reald_reald) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_make_Identity_reald, _swig_p) - return -} - -func Make_Identity_reald() (_swig_ret ArithUnaryFunction_reald_reald) { - return _swig_wrap_make_Identity_reald() -} - -type SwigcptrUnaryFunction_float_reald uintptr - -func (p SwigcptrUnaryFunction_float_reald) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrUnaryFunction_float_reald) SwigIsUnaryFunction_float_reald() { -} - -var _wrap_new_UnaryFunction_float_reald unsafe.Pointer - -func _swig_wrap_new_UnaryFunction_float_reald() (base SwigcptrUnaryFunction_float_reald) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_UnaryFunction_float_reald, _swig_p) - return -} - -func NewUnaryFunction_float_reald() (_swig_ret UnaryFunction_float_reald) { - return _swig_wrap_new_UnaryFunction_float_reald() -} - -var _wrap_delete_UnaryFunction_float_reald unsafe.Pointer - -func _swig_wrap_delete_UnaryFunction_float_reald(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_UnaryFunction_float_reald, _swig_p) - return -} - -func DeleteUnaryFunction_float_reald(arg1 UnaryFunction_float_reald) { - _swig_wrap_delete_UnaryFunction_float_reald(arg1.Swigcptr()) -} - -func (p SwigcptrUnaryFunction_float_reald) SwigIsUnaryFunctionBase() { -} - -func (p SwigcptrUnaryFunction_float_reald) SwigGetUnaryFunctionBase() UnaryFunctionBase { - return SwigcptrUnaryFunctionBase(p.Swigcptr()) -} - -type UnaryFunction_float_reald interface { - Swigcptr() uintptr - SwigIsUnaryFunction_float_reald() - SwigIsUnaryFunctionBase() - SwigGetUnaryFunctionBase() UnaryFunctionBase -} - -type SwigcptrArithUnaryFunction_float_reald uintptr - -func (p SwigcptrArithUnaryFunction_float_reald) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrArithUnaryFunction_float_reald) SwigIsArithUnaryFunction_float_reald() { -} - -var _wrap_new_ArithUnaryFunction_float_reald unsafe.Pointer - -func _swig_wrap_new_ArithUnaryFunction_float_reald() (base SwigcptrArithUnaryFunction_float_reald) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_ArithUnaryFunction_float_reald, _swig_p) - return -} - -func NewArithUnaryFunction_float_reald() (_swig_ret ArithUnaryFunction_float_reald) { - return _swig_wrap_new_ArithUnaryFunction_float_reald() -} - -var _wrap_delete_ArithUnaryFunction_float_reald unsafe.Pointer - -func _swig_wrap_delete_ArithUnaryFunction_float_reald(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_ArithUnaryFunction_float_reald, _swig_p) - return -} - -func DeleteArithUnaryFunction_float_reald(arg1 ArithUnaryFunction_float_reald) { - _swig_wrap_delete_ArithUnaryFunction_float_reald(arg1.Swigcptr()) -} - -func (p SwigcptrArithUnaryFunction_float_reald) SwigIsUnaryFunction_float_reald() { -} - -func (p SwigcptrArithUnaryFunction_float_reald) SwigGetUnaryFunction_float_reald() UnaryFunction_float_reald { - return SwigcptrUnaryFunction_float_reald(p.Swigcptr()) -} - -func (p SwigcptrArithUnaryFunction_float_reald) SwigIsUnaryFunctionBase() { -} - -func (p SwigcptrArithUnaryFunction_float_reald) SwigGetUnaryFunctionBase() UnaryFunctionBase { - return SwigcptrUnaryFunctionBase(p.Swigcptr()) -} - -type ArithUnaryFunction_float_reald interface { - Swigcptr() uintptr - SwigIsArithUnaryFunction_float_reald() - SwigIsUnaryFunction_float_reald() - SwigGetUnaryFunction_float_reald() UnaryFunction_float_reald - SwigIsUnaryFunctionBase() - SwigGetUnaryFunctionBase() UnaryFunctionBase -} - -var _wrap_make_Multiplies_float_float_reald_reald unsafe.Pointer - -func _swig_wrap_make_Multiplies_float_float_reald_reald(base uintptr, _ uintptr) (_ SwigcptrArithUnaryFunction_float_reald) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_make_Multiplies_float_float_reald_reald, _swig_p) - return -} - -func Make_Multiplies_float_float_reald_reald(arg1 ArithUnaryFunction_float_float, arg2 ArithUnaryFunction_reald_reald) (_swig_ret ArithUnaryFunction_float_reald) { - return _swig_wrap_make_Multiplies_float_float_reald_reald(arg1.Swigcptr(), arg2.Swigcptr()) -} - -var _wrap_make_Multiplies_float_float_float_float unsafe.Pointer - -func _swig_wrap_make_Multiplies_float_float_float_float(base uintptr, _ uintptr) (_ SwigcptrArithUnaryFunction_float_float) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_make_Multiplies_float_float_float_float, _swig_p) - return -} - -func Make_Multiplies_float_float_float_float(arg1 ArithUnaryFunction_float_float, arg2 ArithUnaryFunction_float_float) (_swig_ret ArithUnaryFunction_float_float) { - return _swig_wrap_make_Multiplies_float_float_float_float(arg1.Swigcptr(), arg2.Swigcptr()) -} - -var _wrap_make_Multiplies_reald_reald_reald_reald unsafe.Pointer - -func _swig_wrap_make_Multiplies_reald_reald_reald_reald(base uintptr, _ uintptr) (_ SwigcptrArithUnaryFunction_reald_reald) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_make_Multiplies_reald_reald_reald_reald, _swig_p) - return -} - -func Make_Multiplies_reald_reald_reald_reald(arg1 ArithUnaryFunction_reald_reald, arg2 ArithUnaryFunction_reald_reald) (_swig_ret ArithUnaryFunction_reald_reald) { - return _swig_wrap_make_Multiplies_reald_reald_reald_reald(arg1.Swigcptr(), arg2.Swigcptr()) -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/template_typedef_class_template.go b/Examples/test-suite/go/template_typedef_class_template.go deleted file mode 100644 index 77409546e..000000000 --- a/Examples/test-suite/go/template_typedef_class_template.go +++ /dev/null @@ -1,294 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../template_typedef_class_template.i - -package template_typedef_class_template - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrA uintptr - -func (p SwigcptrA) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrA) SwigIsA() { -} - -var _wrap_A_val_set unsafe.Pointer - -func _swig_wrap_A_val_set(base SwigcptrA, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_A_val_set, _swig_p) - return -} - -func (arg1 SwigcptrA) SetVal(arg2 int) { - _swig_wrap_A_val_set(arg1, arg2) -} - -var _wrap_A_val_get unsafe.Pointer - -func _swig_wrap_A_val_get(base SwigcptrA) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_A_val_get, _swig_p) - return -} - -func (arg1 SwigcptrA) GetVal() (_swig_ret int) { - return _swig_wrap_A_val_get(arg1) -} - -var _wrap_new_A__SWIG_0 unsafe.Pointer - -func _swig_wrap_new_A__SWIG_0(base int) (_ SwigcptrA) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_A__SWIG_0, _swig_p) - return -} - -func NewA__SWIG_0(arg1 int) (_swig_ret A) { - return _swig_wrap_new_A__SWIG_0(arg1) -} - -var _wrap_new_A__SWIG_1 unsafe.Pointer - -func _swig_wrap_new_A__SWIG_1() (base SwigcptrA) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_A__SWIG_1, _swig_p) - return -} - -func NewA__SWIG_1() (_swig_ret A) { - return _swig_wrap_new_A__SWIG_1() -} - -func NewA(a ...interface{}) A { - argc := len(a) - if argc == 0 { - return NewA__SWIG_1() - } - if argc == 1 { - return NewA__SWIG_0(a[0].(int)) - } - panic("No match for overloaded function call") -} - -var _wrap_delete_A unsafe.Pointer - -func _swig_wrap_delete_A(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_A, _swig_p) - return -} - -func DeleteA(arg1 A) { - _swig_wrap_delete_A(arg1.Swigcptr()) -} - -type A interface { - Swigcptr() uintptr - SwigIsA() - SetVal(arg2 int) - GetVal() (_swig_ret int) -} - -type SwigcptrPairA uintptr - -func (p SwigcptrPairA) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrPairA) SwigIsPairA() { -} - -var _wrap_PairA_first_set unsafe.Pointer - -func _swig_wrap_PairA_first_set(base SwigcptrPairA, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_PairA_first_set, _swig_p) - return -} - -func (arg1 SwigcptrPairA) SetFirst(arg2 int) { - _swig_wrap_PairA_first_set(arg1, arg2) -} - -var _wrap_PairA_first_get unsafe.Pointer - -func _swig_wrap_PairA_first_get(base SwigcptrPairA) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_PairA_first_get, _swig_p) - return -} - -func (arg1 SwigcptrPairA) GetFirst() (_swig_ret int) { - return _swig_wrap_PairA_first_get(arg1) -} - -var _wrap_PairA_second_set unsafe.Pointer - -func _swig_wrap_PairA_second_set(base SwigcptrPairA, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_PairA_second_set, _swig_p) - return -} - -func (arg1 SwigcptrPairA) SetSecond(arg2 A) { - _swig_wrap_PairA_second_set(arg1, arg2.Swigcptr()) -} - -var _wrap_PairA_second_get unsafe.Pointer - -func _swig_wrap_PairA_second_get(base SwigcptrPairA) (_ SwigcptrA) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_PairA_second_get, _swig_p) - return -} - -func (arg1 SwigcptrPairA) GetSecond() (_swig_ret A) { - return _swig_wrap_PairA_second_get(arg1) -} - -var _wrap_new_PairA unsafe.Pointer - -func _swig_wrap_new_PairA() (base SwigcptrPairA) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_PairA, _swig_p) - return -} - -func NewPairA() (_swig_ret PairA) { - return _swig_wrap_new_PairA() -} - -var _wrap_delete_PairA unsafe.Pointer - -func _swig_wrap_delete_PairA(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_PairA, _swig_p) - return -} - -func DeletePairA(arg1 PairA) { - _swig_wrap_delete_PairA(arg1.Swigcptr()) -} - -type PairA interface { - Swigcptr() uintptr - SwigIsPairA() - SetFirst(arg2 int) - GetFirst() (_swig_ret int) - SetSecond(arg2 A) - GetSecond() (_swig_ret A) -} - -type SwigcptrMultimapA uintptr - -func (p SwigcptrMultimapA) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrMultimapA) SwigIsMultimapA() { -} - -var _wrap_MultimapA_equal_range_1 unsafe.Pointer - -func _swig_wrap_MultimapA_equal_range_1(base SwigcptrMultimapA, _ int) (_ SwigcptrStandard_Pair_Sl_Standard_Multimap_Sl_int_Sc_A_Sm__Sg__iterator_Sc_Standard_Multimap_Sl_int_Sc_A_Sm__Sg__iterator_Sg_) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_MultimapA_equal_range_1, _swig_p) - return -} - -func (arg1 SwigcptrMultimapA) Equal_range_1(arg2 int) (_swig_ret Standard_Pair_Sl_Standard_Multimap_Sl_int_Sc_A_Sm__Sg__iterator_Sc_Standard_Multimap_Sl_int_Sc_A_Sm__Sg__iterator_Sg_) { - return _swig_wrap_MultimapA_equal_range_1(arg1, arg2) -} - -var _wrap_MultimapA_equal_range_2 unsafe.Pointer - -func _swig_wrap_MultimapA_equal_range_2(base SwigcptrMultimapA, _ int) (_ SwigcptrStandard_Pair_Sl_Standard_Multimap_Sl_int_Sc_A_Sm__Sg__const_iterator_Sc_Standard_Multimap_Sl_int_Sc_A_Sm__Sg__const_iterator_Sg_) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_MultimapA_equal_range_2, _swig_p) - return -} - -func (arg1 SwigcptrMultimapA) Equal_range_2(arg2 int) (_swig_ret Standard_Pair_Sl_Standard_Multimap_Sl_int_Sc_A_Sm__Sg__const_iterator_Sc_Standard_Multimap_Sl_int_Sc_A_Sm__Sg__const_iterator_Sg_) { - return _swig_wrap_MultimapA_equal_range_2(arg1, arg2) -} - -var _wrap_new_MultimapA unsafe.Pointer - -func _swig_wrap_new_MultimapA() (base SwigcptrMultimapA) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_MultimapA, _swig_p) - return -} - -func NewMultimapA() (_swig_ret MultimapA) { - return _swig_wrap_new_MultimapA() -} - -var _wrap_delete_MultimapA unsafe.Pointer - -func _swig_wrap_delete_MultimapA(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_MultimapA, _swig_p) - return -} - -func DeleteMultimapA(arg1 MultimapA) { - _swig_wrap_delete_MultimapA(arg1.Swigcptr()) -} - -type MultimapA interface { - Swigcptr() uintptr - SwigIsMultimapA() - Equal_range_1(arg2 int) (_swig_ret Standard_Pair_Sl_Standard_Multimap_Sl_int_Sc_A_Sm__Sg__iterator_Sc_Standard_Multimap_Sl_int_Sc_A_Sm__Sg__iterator_Sg_) - Equal_range_2(arg2 int) (_swig_ret Standard_Pair_Sl_Standard_Multimap_Sl_int_Sc_A_Sm__Sg__const_iterator_Sc_Standard_Multimap_Sl_int_Sc_A_Sm__Sg__const_iterator_Sg_) -} - - -type SwigcptrStandard_Pair_Sl_Standard_Multimap_Sl_int_Sc_A_Sm__Sg__const_iterator_Sc_Standard_Multimap_Sl_int_Sc_A_Sm__Sg__const_iterator_Sg_ uintptr -type Standard_Pair_Sl_Standard_Multimap_Sl_int_Sc_A_Sm__Sg__const_iterator_Sc_Standard_Multimap_Sl_int_Sc_A_Sm__Sg__const_iterator_Sg_ interface { - Swigcptr() uintptr; -} -func (p SwigcptrStandard_Pair_Sl_Standard_Multimap_Sl_int_Sc_A_Sm__Sg__const_iterator_Sc_Standard_Multimap_Sl_int_Sc_A_Sm__Sg__const_iterator_Sg_) Swigcptr() uintptr { - return uintptr(p) -} - -type SwigcptrStandard_Pair_Sl_Standard_Multimap_Sl_int_Sc_A_Sm__Sg__iterator_Sc_Standard_Multimap_Sl_int_Sc_A_Sm__Sg__iterator_Sg_ uintptr -type Standard_Pair_Sl_Standard_Multimap_Sl_int_Sc_A_Sm__Sg__iterator_Sc_Standard_Multimap_Sl_int_Sc_A_Sm__Sg__iterator_Sg_ interface { - Swigcptr() uintptr; -} -func (p SwigcptrStandard_Pair_Sl_Standard_Multimap_Sl_int_Sc_A_Sm__Sg__iterator_Sc_Standard_Multimap_Sl_int_Sc_A_Sm__Sg__iterator_Sg_) Swigcptr() uintptr { - return uintptr(p) -} - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/template_typedef_cplx.go b/Examples/test-suite/go/template_typedef_cplx.go deleted file mode 100644 index c84dd2eb9..000000000 --- a/Examples/test-suite/go/template_typedef_cplx.go +++ /dev/null @@ -1,456 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../template_typedef_cplx.i - -package template_typedef_cplx - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrUnaryFunctionBase uintptr - -func (p SwigcptrUnaryFunctionBase) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrUnaryFunctionBase) SwigIsUnaryFunctionBase() { -} - -var _wrap_new_UnaryFunctionBase unsafe.Pointer - -func _swig_wrap_new_UnaryFunctionBase() (base SwigcptrUnaryFunctionBase) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_UnaryFunctionBase, _swig_p) - return -} - -func NewUnaryFunctionBase() (_swig_ret UnaryFunctionBase) { - return _swig_wrap_new_UnaryFunctionBase() -} - -var _wrap_delete_UnaryFunctionBase unsafe.Pointer - -func _swig_wrap_delete_UnaryFunctionBase(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_UnaryFunctionBase, _swig_p) - return -} - -func DeleteUnaryFunctionBase(arg1 UnaryFunctionBase) { - _swig_wrap_delete_UnaryFunctionBase(arg1.Swigcptr()) -} - -type UnaryFunctionBase interface { - Swigcptr() uintptr - SwigIsUnaryFunctionBase() -} - -type SwigcptrUnaryFunction_double_double uintptr - -func (p SwigcptrUnaryFunction_double_double) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrUnaryFunction_double_double) SwigIsUnaryFunction_double_double() { -} - -var _wrap_new_UnaryFunction_double_double unsafe.Pointer - -func _swig_wrap_new_UnaryFunction_double_double() (base SwigcptrUnaryFunction_double_double) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_UnaryFunction_double_double, _swig_p) - return -} - -func NewUnaryFunction_double_double() (_swig_ret UnaryFunction_double_double) { - return _swig_wrap_new_UnaryFunction_double_double() -} - -var _wrap_delete_UnaryFunction_double_double unsafe.Pointer - -func _swig_wrap_delete_UnaryFunction_double_double(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_UnaryFunction_double_double, _swig_p) - return -} - -func DeleteUnaryFunction_double_double(arg1 UnaryFunction_double_double) { - _swig_wrap_delete_UnaryFunction_double_double(arg1.Swigcptr()) -} - -func (p SwigcptrUnaryFunction_double_double) SwigIsUnaryFunctionBase() { -} - -func (p SwigcptrUnaryFunction_double_double) SwigGetUnaryFunctionBase() UnaryFunctionBase { - return SwigcptrUnaryFunctionBase(p.Swigcptr()) -} - -type UnaryFunction_double_double interface { - Swigcptr() uintptr - SwigIsUnaryFunction_double_double() - SwigIsUnaryFunctionBase() - SwigGetUnaryFunctionBase() UnaryFunctionBase -} - -type SwigcptrArithUnaryFunction_double_double uintptr - -func (p SwigcptrArithUnaryFunction_double_double) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrArithUnaryFunction_double_double) SwigIsArithUnaryFunction_double_double() { -} - -var _wrap_new_ArithUnaryFunction_double_double unsafe.Pointer - -func _swig_wrap_new_ArithUnaryFunction_double_double() (base SwigcptrArithUnaryFunction_double_double) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_ArithUnaryFunction_double_double, _swig_p) - return -} - -func NewArithUnaryFunction_double_double() (_swig_ret ArithUnaryFunction_double_double) { - return _swig_wrap_new_ArithUnaryFunction_double_double() -} - -var _wrap_delete_ArithUnaryFunction_double_double unsafe.Pointer - -func _swig_wrap_delete_ArithUnaryFunction_double_double(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_ArithUnaryFunction_double_double, _swig_p) - return -} - -func DeleteArithUnaryFunction_double_double(arg1 ArithUnaryFunction_double_double) { - _swig_wrap_delete_ArithUnaryFunction_double_double(arg1.Swigcptr()) -} - -func (p SwigcptrArithUnaryFunction_double_double) SwigIsUnaryFunction_double_double() { -} - -func (p SwigcptrArithUnaryFunction_double_double) SwigGetUnaryFunction_double_double() UnaryFunction_double_double { - return SwigcptrUnaryFunction_double_double(p.Swigcptr()) -} - -func (p SwigcptrArithUnaryFunction_double_double) SwigIsUnaryFunctionBase() { -} - -func (p SwigcptrArithUnaryFunction_double_double) SwigGetUnaryFunctionBase() UnaryFunctionBase { - return SwigcptrUnaryFunctionBase(p.Swigcptr()) -} - -type ArithUnaryFunction_double_double interface { - Swigcptr() uintptr - SwigIsArithUnaryFunction_double_double() - SwigIsUnaryFunction_double_double() - SwigGetUnaryFunction_double_double() UnaryFunction_double_double - SwigIsUnaryFunctionBase() - SwigGetUnaryFunctionBase() UnaryFunctionBase -} - -var _wrap_make_Identity_double unsafe.Pointer - -func _swig_wrap_make_Identity_double() (base SwigcptrArithUnaryFunction_double_double) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_make_Identity_double, _swig_p) - return -} - -func Make_Identity_double() (_swig_ret ArithUnaryFunction_double_double) { - return _swig_wrap_make_Identity_double() -} - -type SwigcptrUnaryFunction_complex_complex uintptr - -func (p SwigcptrUnaryFunction_complex_complex) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrUnaryFunction_complex_complex) SwigIsUnaryFunction_complex_complex() { -} - -var _wrap_new_UnaryFunction_complex_complex unsafe.Pointer - -func _swig_wrap_new_UnaryFunction_complex_complex() (base SwigcptrUnaryFunction_complex_complex) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_UnaryFunction_complex_complex, _swig_p) - return -} - -func NewUnaryFunction_complex_complex() (_swig_ret UnaryFunction_complex_complex) { - return _swig_wrap_new_UnaryFunction_complex_complex() -} - -var _wrap_delete_UnaryFunction_complex_complex unsafe.Pointer - -func _swig_wrap_delete_UnaryFunction_complex_complex(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_UnaryFunction_complex_complex, _swig_p) - return -} - -func DeleteUnaryFunction_complex_complex(arg1 UnaryFunction_complex_complex) { - _swig_wrap_delete_UnaryFunction_complex_complex(arg1.Swigcptr()) -} - -func (p SwigcptrUnaryFunction_complex_complex) SwigIsUnaryFunctionBase() { -} - -func (p SwigcptrUnaryFunction_complex_complex) SwigGetUnaryFunctionBase() UnaryFunctionBase { - return SwigcptrUnaryFunctionBase(p.Swigcptr()) -} - -type UnaryFunction_complex_complex interface { - Swigcptr() uintptr - SwigIsUnaryFunction_complex_complex() - SwigIsUnaryFunctionBase() - SwigGetUnaryFunctionBase() UnaryFunctionBase -} - -type SwigcptrArithUnaryFunction_complex_complex uintptr - -func (p SwigcptrArithUnaryFunction_complex_complex) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrArithUnaryFunction_complex_complex) SwigIsArithUnaryFunction_complex_complex() { -} - -var _wrap_new_ArithUnaryFunction_complex_complex unsafe.Pointer - -func _swig_wrap_new_ArithUnaryFunction_complex_complex() (base SwigcptrArithUnaryFunction_complex_complex) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_ArithUnaryFunction_complex_complex, _swig_p) - return -} - -func NewArithUnaryFunction_complex_complex() (_swig_ret ArithUnaryFunction_complex_complex) { - return _swig_wrap_new_ArithUnaryFunction_complex_complex() -} - -var _wrap_delete_ArithUnaryFunction_complex_complex unsafe.Pointer - -func _swig_wrap_delete_ArithUnaryFunction_complex_complex(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_ArithUnaryFunction_complex_complex, _swig_p) - return -} - -func DeleteArithUnaryFunction_complex_complex(arg1 ArithUnaryFunction_complex_complex) { - _swig_wrap_delete_ArithUnaryFunction_complex_complex(arg1.Swigcptr()) -} - -func (p SwigcptrArithUnaryFunction_complex_complex) SwigIsUnaryFunction_complex_complex() { -} - -func (p SwigcptrArithUnaryFunction_complex_complex) SwigGetUnaryFunction_complex_complex() UnaryFunction_complex_complex { - return SwigcptrUnaryFunction_complex_complex(p.Swigcptr()) -} - -func (p SwigcptrArithUnaryFunction_complex_complex) SwigIsUnaryFunctionBase() { -} - -func (p SwigcptrArithUnaryFunction_complex_complex) SwigGetUnaryFunctionBase() UnaryFunctionBase { - return SwigcptrUnaryFunctionBase(p.Swigcptr()) -} - -type ArithUnaryFunction_complex_complex interface { - Swigcptr() uintptr - SwigIsArithUnaryFunction_complex_complex() - SwigIsUnaryFunction_complex_complex() - SwigGetUnaryFunction_complex_complex() UnaryFunction_complex_complex - SwigIsUnaryFunctionBase() - SwigGetUnaryFunctionBase() UnaryFunctionBase -} - -var _wrap_make_Identity_complex unsafe.Pointer - -func _swig_wrap_make_Identity_complex() (base SwigcptrArithUnaryFunction_complex_complex) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_make_Identity_complex, _swig_p) - return -} - -func Make_Identity_complex() (_swig_ret ArithUnaryFunction_complex_complex) { - return _swig_wrap_make_Identity_complex() -} - -type SwigcptrUnaryFunction_double_complex uintptr - -func (p SwigcptrUnaryFunction_double_complex) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrUnaryFunction_double_complex) SwigIsUnaryFunction_double_complex() { -} - -var _wrap_new_UnaryFunction_double_complex unsafe.Pointer - -func _swig_wrap_new_UnaryFunction_double_complex() (base SwigcptrUnaryFunction_double_complex) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_UnaryFunction_double_complex, _swig_p) - return -} - -func NewUnaryFunction_double_complex() (_swig_ret UnaryFunction_double_complex) { - return _swig_wrap_new_UnaryFunction_double_complex() -} - -var _wrap_delete_UnaryFunction_double_complex unsafe.Pointer - -func _swig_wrap_delete_UnaryFunction_double_complex(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_UnaryFunction_double_complex, _swig_p) - return -} - -func DeleteUnaryFunction_double_complex(arg1 UnaryFunction_double_complex) { - _swig_wrap_delete_UnaryFunction_double_complex(arg1.Swigcptr()) -} - -func (p SwigcptrUnaryFunction_double_complex) SwigIsUnaryFunctionBase() { -} - -func (p SwigcptrUnaryFunction_double_complex) SwigGetUnaryFunctionBase() UnaryFunctionBase { - return SwigcptrUnaryFunctionBase(p.Swigcptr()) -} - -type UnaryFunction_double_complex interface { - Swigcptr() uintptr - SwigIsUnaryFunction_double_complex() - SwigIsUnaryFunctionBase() - SwigGetUnaryFunctionBase() UnaryFunctionBase -} - -type SwigcptrArithUnaryFunction_double_complex uintptr - -func (p SwigcptrArithUnaryFunction_double_complex) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrArithUnaryFunction_double_complex) SwigIsArithUnaryFunction_double_complex() { -} - -var _wrap_new_ArithUnaryFunction_double_complex unsafe.Pointer - -func _swig_wrap_new_ArithUnaryFunction_double_complex() (base SwigcptrArithUnaryFunction_double_complex) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_ArithUnaryFunction_double_complex, _swig_p) - return -} - -func NewArithUnaryFunction_double_complex() (_swig_ret ArithUnaryFunction_double_complex) { - return _swig_wrap_new_ArithUnaryFunction_double_complex() -} - -var _wrap_delete_ArithUnaryFunction_double_complex unsafe.Pointer - -func _swig_wrap_delete_ArithUnaryFunction_double_complex(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_ArithUnaryFunction_double_complex, _swig_p) - return -} - -func DeleteArithUnaryFunction_double_complex(arg1 ArithUnaryFunction_double_complex) { - _swig_wrap_delete_ArithUnaryFunction_double_complex(arg1.Swigcptr()) -} - -func (p SwigcptrArithUnaryFunction_double_complex) SwigIsUnaryFunction_double_complex() { -} - -func (p SwigcptrArithUnaryFunction_double_complex) SwigGetUnaryFunction_double_complex() UnaryFunction_double_complex { - return SwigcptrUnaryFunction_double_complex(p.Swigcptr()) -} - -func (p SwigcptrArithUnaryFunction_double_complex) SwigIsUnaryFunctionBase() { -} - -func (p SwigcptrArithUnaryFunction_double_complex) SwigGetUnaryFunctionBase() UnaryFunctionBase { - return SwigcptrUnaryFunctionBase(p.Swigcptr()) -} - -type ArithUnaryFunction_double_complex interface { - Swigcptr() uintptr - SwigIsArithUnaryFunction_double_complex() - SwigIsUnaryFunction_double_complex() - SwigGetUnaryFunction_double_complex() UnaryFunction_double_complex - SwigIsUnaryFunctionBase() - SwigGetUnaryFunctionBase() UnaryFunctionBase -} - -var _wrap_make_Multiplies_double_double_complex_complex unsafe.Pointer - -func _swig_wrap_make_Multiplies_double_double_complex_complex(base uintptr, _ uintptr) (_ SwigcptrArithUnaryFunction_double_complex) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_make_Multiplies_double_double_complex_complex, _swig_p) - return -} - -func Make_Multiplies_double_double_complex_complex(arg1 ArithUnaryFunction_double_double, arg2 ArithUnaryFunction_complex_complex) (_swig_ret ArithUnaryFunction_double_complex) { - return _swig_wrap_make_Multiplies_double_double_complex_complex(arg1.Swigcptr(), arg2.Swigcptr()) -} - -var _wrap_make_Multiplies_double_double_double_double unsafe.Pointer - -func _swig_wrap_make_Multiplies_double_double_double_double(base uintptr, _ uintptr) (_ SwigcptrArithUnaryFunction_double_double) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_make_Multiplies_double_double_double_double, _swig_p) - return -} - -func Make_Multiplies_double_double_double_double(arg1 ArithUnaryFunction_double_double, arg2 ArithUnaryFunction_double_double) (_swig_ret ArithUnaryFunction_double_double) { - return _swig_wrap_make_Multiplies_double_double_double_double(arg1.Swigcptr(), arg2.Swigcptr()) -} - -var _wrap_make_Multiplies_complex_complex_complex_complex unsafe.Pointer - -func _swig_wrap_make_Multiplies_complex_complex_complex_complex(base uintptr, _ uintptr) (_ SwigcptrArithUnaryFunction_complex_complex) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_make_Multiplies_complex_complex_complex_complex, _swig_p) - return -} - -func Make_Multiplies_complex_complex_complex_complex(arg1 ArithUnaryFunction_complex_complex, arg2 ArithUnaryFunction_complex_complex) (_swig_ret ArithUnaryFunction_complex_complex) { - return _swig_wrap_make_Multiplies_complex_complex_complex_complex(arg1.Swigcptr(), arg2.Swigcptr()) -} - -var _wrap_make_Multiplies_complex_complex_double_double unsafe.Pointer - -func _swig_wrap_make_Multiplies_complex_complex_double_double(base uintptr, _ uintptr) (_ SwigcptrArithUnaryFunction_double_complex) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_make_Multiplies_complex_complex_double_double, _swig_p) - return -} - -func Make_Multiplies_complex_complex_double_double(arg1 ArithUnaryFunction_complex_complex, arg2 ArithUnaryFunction_double_double) (_swig_ret ArithUnaryFunction_double_complex) { - return _swig_wrap_make_Multiplies_complex_complex_double_double(arg1.Swigcptr(), arg2.Swigcptr()) -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/template_typedef_cplx2.go b/Examples/test-suite/go/template_typedef_cplx2.go deleted file mode 100644 index 36ecb343f..000000000 --- a/Examples/test-suite/go/template_typedef_cplx2.go +++ /dev/null @@ -1,664 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../template_typedef_cplx2.i - -package template_typedef_cplx2 - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrUnaryFunctionBase uintptr - -func (p SwigcptrUnaryFunctionBase) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrUnaryFunctionBase) SwigIsUnaryFunctionBase() { -} - -var _wrap_UnaryFunctionBase_get_base_value unsafe.Pointer - -func _swig_wrap_UnaryFunctionBase_get_base_value(base SwigcptrUnaryFunctionBase) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_UnaryFunctionBase_get_base_value, _swig_p) - return -} - -func (arg1 SwigcptrUnaryFunctionBase) Get_base_value() (_swig_ret int) { - return _swig_wrap_UnaryFunctionBase_get_base_value(arg1) -} - -var _wrap_new_UnaryFunctionBase unsafe.Pointer - -func _swig_wrap_new_UnaryFunctionBase() (base SwigcptrUnaryFunctionBase) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_UnaryFunctionBase, _swig_p) - return -} - -func NewUnaryFunctionBase() (_swig_ret UnaryFunctionBase) { - return _swig_wrap_new_UnaryFunctionBase() -} - -var _wrap_delete_UnaryFunctionBase unsafe.Pointer - -func _swig_wrap_delete_UnaryFunctionBase(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_UnaryFunctionBase, _swig_p) - return -} - -func DeleteUnaryFunctionBase(arg1 UnaryFunctionBase) { - _swig_wrap_delete_UnaryFunctionBase(arg1.Swigcptr()) -} - -type UnaryFunctionBase interface { - Swigcptr() uintptr - SwigIsUnaryFunctionBase() - Get_base_value() (_swig_ret int) -} - -type SwigcptrUnaryFunction_double_double uintptr - -func (p SwigcptrUnaryFunction_double_double) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrUnaryFunction_double_double) SwigIsUnaryFunction_double_double() { -} - -var _wrap_UnaryFunction_double_double_get_value unsafe.Pointer - -func _swig_wrap_UnaryFunction_double_double_get_value(base SwigcptrUnaryFunction_double_double) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_UnaryFunction_double_double_get_value, _swig_p) - return -} - -func (arg1 SwigcptrUnaryFunction_double_double) Get_value() (_swig_ret int) { - return _swig_wrap_UnaryFunction_double_double_get_value(arg1) -} - -var _wrap_new_UnaryFunction_double_double unsafe.Pointer - -func _swig_wrap_new_UnaryFunction_double_double() (base SwigcptrUnaryFunction_double_double) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_UnaryFunction_double_double, _swig_p) - return -} - -func NewUnaryFunction_double_double() (_swig_ret UnaryFunction_double_double) { - return _swig_wrap_new_UnaryFunction_double_double() -} - -var _wrap_delete_UnaryFunction_double_double unsafe.Pointer - -func _swig_wrap_delete_UnaryFunction_double_double(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_UnaryFunction_double_double, _swig_p) - return -} - -func DeleteUnaryFunction_double_double(arg1 UnaryFunction_double_double) { - _swig_wrap_delete_UnaryFunction_double_double(arg1.Swigcptr()) -} - -var _wrap_UnaryFunction_double_double_get_base_value unsafe.Pointer - -func _swig_wrap_UnaryFunction_double_double_get_base_value(base SwigcptrUnaryFunction_double_double) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_UnaryFunction_double_double_get_base_value, _swig_p) - return -} - -func (_swig_base SwigcptrUnaryFunction_double_double) Get_base_value() (_swig_ret int) { - return _swig_wrap_UnaryFunction_double_double_get_base_value(_swig_base) -} - -func (p SwigcptrUnaryFunction_double_double) SwigIsUnaryFunctionBase() { -} - -func (p SwigcptrUnaryFunction_double_double) SwigGetUnaryFunctionBase() UnaryFunctionBase { - return SwigcptrUnaryFunctionBase(p.Swigcptr()) -} - -type UnaryFunction_double_double interface { - Swigcptr() uintptr - SwigIsUnaryFunction_double_double() - Get_value() (_swig_ret int) - Get_base_value() (_swig_ret int) - SwigIsUnaryFunctionBase() - SwigGetUnaryFunctionBase() UnaryFunctionBase -} - -type SwigcptrArithUnaryFunction_double_double uintptr - -func (p SwigcptrArithUnaryFunction_double_double) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrArithUnaryFunction_double_double) SwigIsArithUnaryFunction_double_double() { -} - -var _wrap_ArithUnaryFunction_double_double_get_arith_value unsafe.Pointer - -func _swig_wrap_ArithUnaryFunction_double_double_get_arith_value(base SwigcptrArithUnaryFunction_double_double) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_ArithUnaryFunction_double_double_get_arith_value, _swig_p) - return -} - -func (arg1 SwigcptrArithUnaryFunction_double_double) Get_arith_value() (_swig_ret int) { - return _swig_wrap_ArithUnaryFunction_double_double_get_arith_value(arg1) -} - -var _wrap_new_ArithUnaryFunction_double_double unsafe.Pointer - -func _swig_wrap_new_ArithUnaryFunction_double_double() (base SwigcptrArithUnaryFunction_double_double) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_ArithUnaryFunction_double_double, _swig_p) - return -} - -func NewArithUnaryFunction_double_double() (_swig_ret ArithUnaryFunction_double_double) { - return _swig_wrap_new_ArithUnaryFunction_double_double() -} - -var _wrap_delete_ArithUnaryFunction_double_double unsafe.Pointer - -func _swig_wrap_delete_ArithUnaryFunction_double_double(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_ArithUnaryFunction_double_double, _swig_p) - return -} - -func DeleteArithUnaryFunction_double_double(arg1 ArithUnaryFunction_double_double) { - _swig_wrap_delete_ArithUnaryFunction_double_double(arg1.Swigcptr()) -} - -var _wrap_ArithUnaryFunction_double_double_get_value unsafe.Pointer - -func _swig_wrap_ArithUnaryFunction_double_double_get_value(base SwigcptrArithUnaryFunction_double_double) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_ArithUnaryFunction_double_double_get_value, _swig_p) - return -} - -func (_swig_base SwigcptrArithUnaryFunction_double_double) Get_value() (_swig_ret int) { - return _swig_wrap_ArithUnaryFunction_double_double_get_value(_swig_base) -} - -var _wrap_ArithUnaryFunction_double_double_get_base_value unsafe.Pointer - -func _swig_wrap_ArithUnaryFunction_double_double_get_base_value(base SwigcptrArithUnaryFunction_double_double) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_ArithUnaryFunction_double_double_get_base_value, _swig_p) - return -} - -func (_swig_base SwigcptrArithUnaryFunction_double_double) Get_base_value() (_swig_ret int) { - return _swig_wrap_ArithUnaryFunction_double_double_get_base_value(_swig_base) -} - -func (p SwigcptrArithUnaryFunction_double_double) SwigIsUnaryFunction_double_double() { -} - -func (p SwigcptrArithUnaryFunction_double_double) SwigGetUnaryFunction_double_double() UnaryFunction_double_double { - return SwigcptrUnaryFunction_double_double(p.Swigcptr()) -} - -func (p SwigcptrArithUnaryFunction_double_double) SwigIsUnaryFunctionBase() { -} - -func (p SwigcptrArithUnaryFunction_double_double) SwigGetUnaryFunctionBase() UnaryFunctionBase { - return SwigcptrUnaryFunctionBase(p.Swigcptr()) -} - -type ArithUnaryFunction_double_double interface { - Swigcptr() uintptr - SwigIsArithUnaryFunction_double_double() - Get_arith_value() (_swig_ret int) - Get_value() (_swig_ret int) - Get_base_value() (_swig_ret int) - SwigIsUnaryFunction_double_double() - SwigGetUnaryFunction_double_double() UnaryFunction_double_double - SwigIsUnaryFunctionBase() - SwigGetUnaryFunctionBase() UnaryFunctionBase -} - -var _wrap_make_Identity_double unsafe.Pointer - -func _swig_wrap_make_Identity_double() (base SwigcptrArithUnaryFunction_double_double) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_make_Identity_double, _swig_p) - return -} - -func Make_Identity_double() (_swig_ret ArithUnaryFunction_double_double) { - return _swig_wrap_make_Identity_double() -} - -type SwigcptrUnaryFunction_complex_complex uintptr - -func (p SwigcptrUnaryFunction_complex_complex) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrUnaryFunction_complex_complex) SwigIsUnaryFunction_complex_complex() { -} - -var _wrap_UnaryFunction_complex_complex_get_value unsafe.Pointer - -func _swig_wrap_UnaryFunction_complex_complex_get_value(base SwigcptrUnaryFunction_complex_complex) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_UnaryFunction_complex_complex_get_value, _swig_p) - return -} - -func (arg1 SwigcptrUnaryFunction_complex_complex) Get_value() (_swig_ret int) { - return _swig_wrap_UnaryFunction_complex_complex_get_value(arg1) -} - -var _wrap_new_UnaryFunction_complex_complex unsafe.Pointer - -func _swig_wrap_new_UnaryFunction_complex_complex() (base SwigcptrUnaryFunction_complex_complex) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_UnaryFunction_complex_complex, _swig_p) - return -} - -func NewUnaryFunction_complex_complex() (_swig_ret UnaryFunction_complex_complex) { - return _swig_wrap_new_UnaryFunction_complex_complex() -} - -var _wrap_delete_UnaryFunction_complex_complex unsafe.Pointer - -func _swig_wrap_delete_UnaryFunction_complex_complex(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_UnaryFunction_complex_complex, _swig_p) - return -} - -func DeleteUnaryFunction_complex_complex(arg1 UnaryFunction_complex_complex) { - _swig_wrap_delete_UnaryFunction_complex_complex(arg1.Swigcptr()) -} - -var _wrap_UnaryFunction_complex_complex_get_base_value unsafe.Pointer - -func _swig_wrap_UnaryFunction_complex_complex_get_base_value(base SwigcptrUnaryFunction_complex_complex) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_UnaryFunction_complex_complex_get_base_value, _swig_p) - return -} - -func (_swig_base SwigcptrUnaryFunction_complex_complex) Get_base_value() (_swig_ret int) { - return _swig_wrap_UnaryFunction_complex_complex_get_base_value(_swig_base) -} - -func (p SwigcptrUnaryFunction_complex_complex) SwigIsUnaryFunctionBase() { -} - -func (p SwigcptrUnaryFunction_complex_complex) SwigGetUnaryFunctionBase() UnaryFunctionBase { - return SwigcptrUnaryFunctionBase(p.Swigcptr()) -} - -type UnaryFunction_complex_complex interface { - Swigcptr() uintptr - SwigIsUnaryFunction_complex_complex() - Get_value() (_swig_ret int) - Get_base_value() (_swig_ret int) - SwigIsUnaryFunctionBase() - SwigGetUnaryFunctionBase() UnaryFunctionBase -} - -type SwigcptrArithUnaryFunction_complex_complex uintptr - -func (p SwigcptrArithUnaryFunction_complex_complex) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrArithUnaryFunction_complex_complex) SwigIsArithUnaryFunction_complex_complex() { -} - -var _wrap_ArithUnaryFunction_complex_complex_get_arith_value unsafe.Pointer - -func _swig_wrap_ArithUnaryFunction_complex_complex_get_arith_value(base SwigcptrArithUnaryFunction_complex_complex) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_ArithUnaryFunction_complex_complex_get_arith_value, _swig_p) - return -} - -func (arg1 SwigcptrArithUnaryFunction_complex_complex) Get_arith_value() (_swig_ret int) { - return _swig_wrap_ArithUnaryFunction_complex_complex_get_arith_value(arg1) -} - -var _wrap_new_ArithUnaryFunction_complex_complex unsafe.Pointer - -func _swig_wrap_new_ArithUnaryFunction_complex_complex() (base SwigcptrArithUnaryFunction_complex_complex) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_ArithUnaryFunction_complex_complex, _swig_p) - return -} - -func NewArithUnaryFunction_complex_complex() (_swig_ret ArithUnaryFunction_complex_complex) { - return _swig_wrap_new_ArithUnaryFunction_complex_complex() -} - -var _wrap_delete_ArithUnaryFunction_complex_complex unsafe.Pointer - -func _swig_wrap_delete_ArithUnaryFunction_complex_complex(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_ArithUnaryFunction_complex_complex, _swig_p) - return -} - -func DeleteArithUnaryFunction_complex_complex(arg1 ArithUnaryFunction_complex_complex) { - _swig_wrap_delete_ArithUnaryFunction_complex_complex(arg1.Swigcptr()) -} - -var _wrap_ArithUnaryFunction_complex_complex_get_value unsafe.Pointer - -func _swig_wrap_ArithUnaryFunction_complex_complex_get_value(base SwigcptrArithUnaryFunction_complex_complex) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_ArithUnaryFunction_complex_complex_get_value, _swig_p) - return -} - -func (_swig_base SwigcptrArithUnaryFunction_complex_complex) Get_value() (_swig_ret int) { - return _swig_wrap_ArithUnaryFunction_complex_complex_get_value(_swig_base) -} - -var _wrap_ArithUnaryFunction_complex_complex_get_base_value unsafe.Pointer - -func _swig_wrap_ArithUnaryFunction_complex_complex_get_base_value(base SwigcptrArithUnaryFunction_complex_complex) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_ArithUnaryFunction_complex_complex_get_base_value, _swig_p) - return -} - -func (_swig_base SwigcptrArithUnaryFunction_complex_complex) Get_base_value() (_swig_ret int) { - return _swig_wrap_ArithUnaryFunction_complex_complex_get_base_value(_swig_base) -} - -func (p SwigcptrArithUnaryFunction_complex_complex) SwigIsUnaryFunction_complex_complex() { -} - -func (p SwigcptrArithUnaryFunction_complex_complex) SwigGetUnaryFunction_complex_complex() UnaryFunction_complex_complex { - return SwigcptrUnaryFunction_complex_complex(p.Swigcptr()) -} - -func (p SwigcptrArithUnaryFunction_complex_complex) SwigIsUnaryFunctionBase() { -} - -func (p SwigcptrArithUnaryFunction_complex_complex) SwigGetUnaryFunctionBase() UnaryFunctionBase { - return SwigcptrUnaryFunctionBase(p.Swigcptr()) -} - -type ArithUnaryFunction_complex_complex interface { - Swigcptr() uintptr - SwigIsArithUnaryFunction_complex_complex() - Get_arith_value() (_swig_ret int) - Get_value() (_swig_ret int) - Get_base_value() (_swig_ret int) - SwigIsUnaryFunction_complex_complex() - SwigGetUnaryFunction_complex_complex() UnaryFunction_complex_complex - SwigIsUnaryFunctionBase() - SwigGetUnaryFunctionBase() UnaryFunctionBase -} - -var _wrap_make_Identity_complex unsafe.Pointer - -func _swig_wrap_make_Identity_complex() (base SwigcptrArithUnaryFunction_complex_complex) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_make_Identity_complex, _swig_p) - return -} - -func Make_Identity_complex() (_swig_ret ArithUnaryFunction_complex_complex) { - return _swig_wrap_make_Identity_complex() -} - -type SwigcptrUnaryFunction_double_complex uintptr - -func (p SwigcptrUnaryFunction_double_complex) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrUnaryFunction_double_complex) SwigIsUnaryFunction_double_complex() { -} - -var _wrap_UnaryFunction_double_complex_get_value unsafe.Pointer - -func _swig_wrap_UnaryFunction_double_complex_get_value(base SwigcptrUnaryFunction_double_complex) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_UnaryFunction_double_complex_get_value, _swig_p) - return -} - -func (arg1 SwigcptrUnaryFunction_double_complex) Get_value() (_swig_ret int) { - return _swig_wrap_UnaryFunction_double_complex_get_value(arg1) -} - -var _wrap_new_UnaryFunction_double_complex unsafe.Pointer - -func _swig_wrap_new_UnaryFunction_double_complex() (base SwigcptrUnaryFunction_double_complex) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_UnaryFunction_double_complex, _swig_p) - return -} - -func NewUnaryFunction_double_complex() (_swig_ret UnaryFunction_double_complex) { - return _swig_wrap_new_UnaryFunction_double_complex() -} - -var _wrap_delete_UnaryFunction_double_complex unsafe.Pointer - -func _swig_wrap_delete_UnaryFunction_double_complex(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_UnaryFunction_double_complex, _swig_p) - return -} - -func DeleteUnaryFunction_double_complex(arg1 UnaryFunction_double_complex) { - _swig_wrap_delete_UnaryFunction_double_complex(arg1.Swigcptr()) -} - -var _wrap_UnaryFunction_double_complex_get_base_value unsafe.Pointer - -func _swig_wrap_UnaryFunction_double_complex_get_base_value(base SwigcptrUnaryFunction_double_complex) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_UnaryFunction_double_complex_get_base_value, _swig_p) - return -} - -func (_swig_base SwigcptrUnaryFunction_double_complex) Get_base_value() (_swig_ret int) { - return _swig_wrap_UnaryFunction_double_complex_get_base_value(_swig_base) -} - -func (p SwigcptrUnaryFunction_double_complex) SwigIsUnaryFunctionBase() { -} - -func (p SwigcptrUnaryFunction_double_complex) SwigGetUnaryFunctionBase() UnaryFunctionBase { - return SwigcptrUnaryFunctionBase(p.Swigcptr()) -} - -type UnaryFunction_double_complex interface { - Swigcptr() uintptr - SwigIsUnaryFunction_double_complex() - Get_value() (_swig_ret int) - Get_base_value() (_swig_ret int) - SwigIsUnaryFunctionBase() - SwigGetUnaryFunctionBase() UnaryFunctionBase -} - -type SwigcptrArithUnaryFunction_double_complex uintptr - -func (p SwigcptrArithUnaryFunction_double_complex) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrArithUnaryFunction_double_complex) SwigIsArithUnaryFunction_double_complex() { -} - -var _wrap_ArithUnaryFunction_double_complex_get_arith_value unsafe.Pointer - -func _swig_wrap_ArithUnaryFunction_double_complex_get_arith_value(base SwigcptrArithUnaryFunction_double_complex) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_ArithUnaryFunction_double_complex_get_arith_value, _swig_p) - return -} - -func (arg1 SwigcptrArithUnaryFunction_double_complex) Get_arith_value() (_swig_ret int) { - return _swig_wrap_ArithUnaryFunction_double_complex_get_arith_value(arg1) -} - -var _wrap_new_ArithUnaryFunction_double_complex unsafe.Pointer - -func _swig_wrap_new_ArithUnaryFunction_double_complex() (base SwigcptrArithUnaryFunction_double_complex) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_ArithUnaryFunction_double_complex, _swig_p) - return -} - -func NewArithUnaryFunction_double_complex() (_swig_ret ArithUnaryFunction_double_complex) { - return _swig_wrap_new_ArithUnaryFunction_double_complex() -} - -var _wrap_delete_ArithUnaryFunction_double_complex unsafe.Pointer - -func _swig_wrap_delete_ArithUnaryFunction_double_complex(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_ArithUnaryFunction_double_complex, _swig_p) - return -} - -func DeleteArithUnaryFunction_double_complex(arg1 ArithUnaryFunction_double_complex) { - _swig_wrap_delete_ArithUnaryFunction_double_complex(arg1.Swigcptr()) -} - -var _wrap_ArithUnaryFunction_double_complex_get_value unsafe.Pointer - -func _swig_wrap_ArithUnaryFunction_double_complex_get_value(base SwigcptrArithUnaryFunction_double_complex) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_ArithUnaryFunction_double_complex_get_value, _swig_p) - return -} - -func (_swig_base SwigcptrArithUnaryFunction_double_complex) Get_value() (_swig_ret int) { - return _swig_wrap_ArithUnaryFunction_double_complex_get_value(_swig_base) -} - -var _wrap_ArithUnaryFunction_double_complex_get_base_value unsafe.Pointer - -func _swig_wrap_ArithUnaryFunction_double_complex_get_base_value(base SwigcptrArithUnaryFunction_double_complex) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_ArithUnaryFunction_double_complex_get_base_value, _swig_p) - return -} - -func (_swig_base SwigcptrArithUnaryFunction_double_complex) Get_base_value() (_swig_ret int) { - return _swig_wrap_ArithUnaryFunction_double_complex_get_base_value(_swig_base) -} - -func (p SwigcptrArithUnaryFunction_double_complex) SwigIsUnaryFunction_double_complex() { -} - -func (p SwigcptrArithUnaryFunction_double_complex) SwigGetUnaryFunction_double_complex() UnaryFunction_double_complex { - return SwigcptrUnaryFunction_double_complex(p.Swigcptr()) -} - -func (p SwigcptrArithUnaryFunction_double_complex) SwigIsUnaryFunctionBase() { -} - -func (p SwigcptrArithUnaryFunction_double_complex) SwigGetUnaryFunctionBase() UnaryFunctionBase { - return SwigcptrUnaryFunctionBase(p.Swigcptr()) -} - -type ArithUnaryFunction_double_complex interface { - Swigcptr() uintptr - SwigIsArithUnaryFunction_double_complex() - Get_arith_value() (_swig_ret int) - Get_value() (_swig_ret int) - Get_base_value() (_swig_ret int) - SwigIsUnaryFunction_double_complex() - SwigGetUnaryFunction_double_complex() UnaryFunction_double_complex - SwigIsUnaryFunctionBase() - SwigGetUnaryFunctionBase() UnaryFunctionBase -} - -var _wrap_make_Multiplies_double_double_complex_complex unsafe.Pointer - -func _swig_wrap_make_Multiplies_double_double_complex_complex(base uintptr, _ uintptr) (_ SwigcptrArithUnaryFunction_double_complex) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_make_Multiplies_double_double_complex_complex, _swig_p) - return -} - -func Make_Multiplies_double_double_complex_complex(arg1 ArithUnaryFunction_double_double, arg2 ArithUnaryFunction_complex_complex) (_swig_ret ArithUnaryFunction_double_complex) { - return _swig_wrap_make_Multiplies_double_double_complex_complex(arg1.Swigcptr(), arg2.Swigcptr()) -} - -var _wrap_make_Multiplies_double_double_double_double unsafe.Pointer - -func _swig_wrap_make_Multiplies_double_double_double_double(base uintptr, _ uintptr) (_ SwigcptrArithUnaryFunction_double_double) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_make_Multiplies_double_double_double_double, _swig_p) - return -} - -func Make_Multiplies_double_double_double_double(arg1 ArithUnaryFunction_double_double, arg2 ArithUnaryFunction_double_double) (_swig_ret ArithUnaryFunction_double_double) { - return _swig_wrap_make_Multiplies_double_double_double_double(arg1.Swigcptr(), arg2.Swigcptr()) -} - -var _wrap_make_Multiplies_complex_complex_complex_complex unsafe.Pointer - -func _swig_wrap_make_Multiplies_complex_complex_complex_complex(base uintptr, _ uintptr) (_ SwigcptrArithUnaryFunction_complex_complex) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_make_Multiplies_complex_complex_complex_complex, _swig_p) - return -} - -func Make_Multiplies_complex_complex_complex_complex(arg1 ArithUnaryFunction_complex_complex, arg2 ArithUnaryFunction_complex_complex) (_swig_ret ArithUnaryFunction_complex_complex) { - return _swig_wrap_make_Multiplies_complex_complex_complex_complex(arg1.Swigcptr(), arg2.Swigcptr()) -} - -var _wrap_make_Multiplies_complex_complex_double_double unsafe.Pointer - -func _swig_wrap_make_Multiplies_complex_complex_double_double(base uintptr, _ uintptr) (_ SwigcptrArithUnaryFunction_double_complex) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_make_Multiplies_complex_complex_double_double, _swig_p) - return -} - -func Make_Multiplies_complex_complex_double_double(arg1 ArithUnaryFunction_complex_complex, arg2 ArithUnaryFunction_double_double) (_swig_ret ArithUnaryFunction_double_complex) { - return _swig_wrap_make_Multiplies_complex_complex_double_double(arg1.Swigcptr(), arg2.Swigcptr()) -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/template_typedef_cplx3.go b/Examples/test-suite/go/template_typedef_cplx3.go deleted file mode 100644 index f11865ec9..000000000 --- a/Examples/test-suite/go/template_typedef_cplx3.go +++ /dev/null @@ -1,896 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../template_typedef_cplx3.i - -package template_typedef_cplx3 - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrUnaryFunctionBase uintptr - -func (p SwigcptrUnaryFunctionBase) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrUnaryFunctionBase) SwigIsUnaryFunctionBase() { -} - -var _wrap_UnaryFunctionBase_get_base_value unsafe.Pointer - -func _swig_wrap_UnaryFunctionBase_get_base_value(base SwigcptrUnaryFunctionBase) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_UnaryFunctionBase_get_base_value, _swig_p) - return -} - -func (arg1 SwigcptrUnaryFunctionBase) Get_base_value() (_swig_ret int) { - return _swig_wrap_UnaryFunctionBase_get_base_value(arg1) -} - -var _wrap_new_UnaryFunctionBase unsafe.Pointer - -func _swig_wrap_new_UnaryFunctionBase() (base SwigcptrUnaryFunctionBase) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_UnaryFunctionBase, _swig_p) - return -} - -func NewUnaryFunctionBase() (_swig_ret UnaryFunctionBase) { - return _swig_wrap_new_UnaryFunctionBase() -} - -var _wrap_delete_UnaryFunctionBase unsafe.Pointer - -func _swig_wrap_delete_UnaryFunctionBase(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_UnaryFunctionBase, _swig_p) - return -} - -func DeleteUnaryFunctionBase(arg1 UnaryFunctionBase) { - _swig_wrap_delete_UnaryFunctionBase(arg1.Swigcptr()) -} - -type UnaryFunctionBase interface { - Swigcptr() uintptr - SwigIsUnaryFunctionBase() - Get_base_value() (_swig_ret int) -} - -type SwigcptrUnaryFunction_double_double uintptr - -func (p SwigcptrUnaryFunction_double_double) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrUnaryFunction_double_double) SwigIsUnaryFunction_double_double() { -} - -var _wrap_UnaryFunction_double_double_get_value unsafe.Pointer - -func _swig_wrap_UnaryFunction_double_double_get_value(base SwigcptrUnaryFunction_double_double) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_UnaryFunction_double_double_get_value, _swig_p) - return -} - -func (arg1 SwigcptrUnaryFunction_double_double) Get_value() (_swig_ret int) { - return _swig_wrap_UnaryFunction_double_double_get_value(arg1) -} - -var _wrap_new_UnaryFunction_double_double unsafe.Pointer - -func _swig_wrap_new_UnaryFunction_double_double() (base SwigcptrUnaryFunction_double_double) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_UnaryFunction_double_double, _swig_p) - return -} - -func NewUnaryFunction_double_double() (_swig_ret UnaryFunction_double_double) { - return _swig_wrap_new_UnaryFunction_double_double() -} - -var _wrap_delete_UnaryFunction_double_double unsafe.Pointer - -func _swig_wrap_delete_UnaryFunction_double_double(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_UnaryFunction_double_double, _swig_p) - return -} - -func DeleteUnaryFunction_double_double(arg1 UnaryFunction_double_double) { - _swig_wrap_delete_UnaryFunction_double_double(arg1.Swigcptr()) -} - -var _wrap_UnaryFunction_double_double_get_base_value unsafe.Pointer - -func _swig_wrap_UnaryFunction_double_double_get_base_value(base SwigcptrUnaryFunction_double_double) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_UnaryFunction_double_double_get_base_value, _swig_p) - return -} - -func (_swig_base SwigcptrUnaryFunction_double_double) Get_base_value() (_swig_ret int) { - return _swig_wrap_UnaryFunction_double_double_get_base_value(_swig_base) -} - -func (p SwigcptrUnaryFunction_double_double) SwigIsUnaryFunctionBase() { -} - -func (p SwigcptrUnaryFunction_double_double) SwigGetUnaryFunctionBase() UnaryFunctionBase { - return SwigcptrUnaryFunctionBase(p.Swigcptr()) -} - -type UnaryFunction_double_double interface { - Swigcptr() uintptr - SwigIsUnaryFunction_double_double() - Get_value() (_swig_ret int) - Get_base_value() (_swig_ret int) - SwigIsUnaryFunctionBase() - SwigGetUnaryFunctionBase() UnaryFunctionBase -} - -type SwigcptrArithUnaryFunction_double_double uintptr - -func (p SwigcptrArithUnaryFunction_double_double) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrArithUnaryFunction_double_double) SwigIsArithUnaryFunction_double_double() { -} - -var _wrap_ArithUnaryFunction_double_double_get_arith_value unsafe.Pointer - -func _swig_wrap_ArithUnaryFunction_double_double_get_arith_value(base SwigcptrArithUnaryFunction_double_double) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_ArithUnaryFunction_double_double_get_arith_value, _swig_p) - return -} - -func (arg1 SwigcptrArithUnaryFunction_double_double) Get_arith_value() (_swig_ret int) { - return _swig_wrap_ArithUnaryFunction_double_double_get_arith_value(arg1) -} - -var _wrap_new_ArithUnaryFunction_double_double unsafe.Pointer - -func _swig_wrap_new_ArithUnaryFunction_double_double() (base SwigcptrArithUnaryFunction_double_double) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_ArithUnaryFunction_double_double, _swig_p) - return -} - -func NewArithUnaryFunction_double_double() (_swig_ret ArithUnaryFunction_double_double) { - return _swig_wrap_new_ArithUnaryFunction_double_double() -} - -var _wrap_delete_ArithUnaryFunction_double_double unsafe.Pointer - -func _swig_wrap_delete_ArithUnaryFunction_double_double(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_ArithUnaryFunction_double_double, _swig_p) - return -} - -func DeleteArithUnaryFunction_double_double(arg1 ArithUnaryFunction_double_double) { - _swig_wrap_delete_ArithUnaryFunction_double_double(arg1.Swigcptr()) -} - -var _wrap_ArithUnaryFunction_double_double_get_value unsafe.Pointer - -func _swig_wrap_ArithUnaryFunction_double_double_get_value(base SwigcptrArithUnaryFunction_double_double) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_ArithUnaryFunction_double_double_get_value, _swig_p) - return -} - -func (_swig_base SwigcptrArithUnaryFunction_double_double) Get_value() (_swig_ret int) { - return _swig_wrap_ArithUnaryFunction_double_double_get_value(_swig_base) -} - -var _wrap_ArithUnaryFunction_double_double_get_base_value unsafe.Pointer - -func _swig_wrap_ArithUnaryFunction_double_double_get_base_value(base SwigcptrArithUnaryFunction_double_double) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_ArithUnaryFunction_double_double_get_base_value, _swig_p) - return -} - -func (_swig_base SwigcptrArithUnaryFunction_double_double) Get_base_value() (_swig_ret int) { - return _swig_wrap_ArithUnaryFunction_double_double_get_base_value(_swig_base) -} - -func (p SwigcptrArithUnaryFunction_double_double) SwigIsUnaryFunction_double_double() { -} - -func (p SwigcptrArithUnaryFunction_double_double) SwigGetUnaryFunction_double_double() UnaryFunction_double_double { - return SwigcptrUnaryFunction_double_double(p.Swigcptr()) -} - -func (p SwigcptrArithUnaryFunction_double_double) SwigIsUnaryFunctionBase() { -} - -func (p SwigcptrArithUnaryFunction_double_double) SwigGetUnaryFunctionBase() UnaryFunctionBase { - return SwigcptrUnaryFunctionBase(p.Swigcptr()) -} - -type ArithUnaryFunction_double_double interface { - Swigcptr() uintptr - SwigIsArithUnaryFunction_double_double() - Get_arith_value() (_swig_ret int) - Get_value() (_swig_ret int) - Get_base_value() (_swig_ret int) - SwigIsUnaryFunction_double_double() - SwigGetUnaryFunction_double_double() UnaryFunction_double_double - SwigIsUnaryFunctionBase() - SwigGetUnaryFunctionBase() UnaryFunctionBase -} - -var _wrap_make_Identity_double unsafe.Pointer - -func _swig_wrap_make_Identity_double() (base SwigcptrArithUnaryFunction_double_double) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_make_Identity_double, _swig_p) - return -} - -func Make_Identity_double() (_swig_ret ArithUnaryFunction_double_double) { - return _swig_wrap_make_Identity_double() -} - -type SwigcptrUnaryFunction_complex_complex uintptr - -func (p SwigcptrUnaryFunction_complex_complex) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrUnaryFunction_complex_complex) SwigIsUnaryFunction_complex_complex() { -} - -var _wrap_UnaryFunction_complex_complex_get_value unsafe.Pointer - -func _swig_wrap_UnaryFunction_complex_complex_get_value(base SwigcptrUnaryFunction_complex_complex) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_UnaryFunction_complex_complex_get_value, _swig_p) - return -} - -func (arg1 SwigcptrUnaryFunction_complex_complex) Get_value() (_swig_ret int) { - return _swig_wrap_UnaryFunction_complex_complex_get_value(arg1) -} - -var _wrap_new_UnaryFunction_complex_complex unsafe.Pointer - -func _swig_wrap_new_UnaryFunction_complex_complex() (base SwigcptrUnaryFunction_complex_complex) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_UnaryFunction_complex_complex, _swig_p) - return -} - -func NewUnaryFunction_complex_complex() (_swig_ret UnaryFunction_complex_complex) { - return _swig_wrap_new_UnaryFunction_complex_complex() -} - -var _wrap_delete_UnaryFunction_complex_complex unsafe.Pointer - -func _swig_wrap_delete_UnaryFunction_complex_complex(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_UnaryFunction_complex_complex, _swig_p) - return -} - -func DeleteUnaryFunction_complex_complex(arg1 UnaryFunction_complex_complex) { - _swig_wrap_delete_UnaryFunction_complex_complex(arg1.Swigcptr()) -} - -var _wrap_UnaryFunction_complex_complex_get_base_value unsafe.Pointer - -func _swig_wrap_UnaryFunction_complex_complex_get_base_value(base SwigcptrUnaryFunction_complex_complex) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_UnaryFunction_complex_complex_get_base_value, _swig_p) - return -} - -func (_swig_base SwigcptrUnaryFunction_complex_complex) Get_base_value() (_swig_ret int) { - return _swig_wrap_UnaryFunction_complex_complex_get_base_value(_swig_base) -} - -func (p SwigcptrUnaryFunction_complex_complex) SwigIsUnaryFunctionBase() { -} - -func (p SwigcptrUnaryFunction_complex_complex) SwigGetUnaryFunctionBase() UnaryFunctionBase { - return SwigcptrUnaryFunctionBase(p.Swigcptr()) -} - -type UnaryFunction_complex_complex interface { - Swigcptr() uintptr - SwigIsUnaryFunction_complex_complex() - Get_value() (_swig_ret int) - Get_base_value() (_swig_ret int) - SwigIsUnaryFunctionBase() - SwigGetUnaryFunctionBase() UnaryFunctionBase -} - -type SwigcptrArithUnaryFunction_complex_complex uintptr - -func (p SwigcptrArithUnaryFunction_complex_complex) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrArithUnaryFunction_complex_complex) SwigIsArithUnaryFunction_complex_complex() { -} - -var _wrap_ArithUnaryFunction_complex_complex_get_arith_value unsafe.Pointer - -func _swig_wrap_ArithUnaryFunction_complex_complex_get_arith_value(base SwigcptrArithUnaryFunction_complex_complex) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_ArithUnaryFunction_complex_complex_get_arith_value, _swig_p) - return -} - -func (arg1 SwigcptrArithUnaryFunction_complex_complex) Get_arith_value() (_swig_ret int) { - return _swig_wrap_ArithUnaryFunction_complex_complex_get_arith_value(arg1) -} - -var _wrap_new_ArithUnaryFunction_complex_complex unsafe.Pointer - -func _swig_wrap_new_ArithUnaryFunction_complex_complex() (base SwigcptrArithUnaryFunction_complex_complex) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_ArithUnaryFunction_complex_complex, _swig_p) - return -} - -func NewArithUnaryFunction_complex_complex() (_swig_ret ArithUnaryFunction_complex_complex) { - return _swig_wrap_new_ArithUnaryFunction_complex_complex() -} - -var _wrap_delete_ArithUnaryFunction_complex_complex unsafe.Pointer - -func _swig_wrap_delete_ArithUnaryFunction_complex_complex(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_ArithUnaryFunction_complex_complex, _swig_p) - return -} - -func DeleteArithUnaryFunction_complex_complex(arg1 ArithUnaryFunction_complex_complex) { - _swig_wrap_delete_ArithUnaryFunction_complex_complex(arg1.Swigcptr()) -} - -var _wrap_ArithUnaryFunction_complex_complex_get_value unsafe.Pointer - -func _swig_wrap_ArithUnaryFunction_complex_complex_get_value(base SwigcptrArithUnaryFunction_complex_complex) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_ArithUnaryFunction_complex_complex_get_value, _swig_p) - return -} - -func (_swig_base SwigcptrArithUnaryFunction_complex_complex) Get_value() (_swig_ret int) { - return _swig_wrap_ArithUnaryFunction_complex_complex_get_value(_swig_base) -} - -var _wrap_ArithUnaryFunction_complex_complex_get_base_value unsafe.Pointer - -func _swig_wrap_ArithUnaryFunction_complex_complex_get_base_value(base SwigcptrArithUnaryFunction_complex_complex) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_ArithUnaryFunction_complex_complex_get_base_value, _swig_p) - return -} - -func (_swig_base SwigcptrArithUnaryFunction_complex_complex) Get_base_value() (_swig_ret int) { - return _swig_wrap_ArithUnaryFunction_complex_complex_get_base_value(_swig_base) -} - -func (p SwigcptrArithUnaryFunction_complex_complex) SwigIsUnaryFunction_complex_complex() { -} - -func (p SwigcptrArithUnaryFunction_complex_complex) SwigGetUnaryFunction_complex_complex() UnaryFunction_complex_complex { - return SwigcptrUnaryFunction_complex_complex(p.Swigcptr()) -} - -func (p SwigcptrArithUnaryFunction_complex_complex) SwigIsUnaryFunctionBase() { -} - -func (p SwigcptrArithUnaryFunction_complex_complex) SwigGetUnaryFunctionBase() UnaryFunctionBase { - return SwigcptrUnaryFunctionBase(p.Swigcptr()) -} - -type ArithUnaryFunction_complex_complex interface { - Swigcptr() uintptr - SwigIsArithUnaryFunction_complex_complex() - Get_arith_value() (_swig_ret int) - Get_value() (_swig_ret int) - Get_base_value() (_swig_ret int) - SwigIsUnaryFunction_complex_complex() - SwigGetUnaryFunction_complex_complex() UnaryFunction_complex_complex - SwigIsUnaryFunctionBase() - SwigGetUnaryFunctionBase() UnaryFunctionBase -} - -var _wrap_make_Identity_complex unsafe.Pointer - -func _swig_wrap_make_Identity_complex() (base SwigcptrArithUnaryFunction_complex_complex) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_make_Identity_complex, _swig_p) - return -} - -func Make_Identity_complex() (_swig_ret ArithUnaryFunction_complex_complex) { - return _swig_wrap_make_Identity_complex() -} - -type SwigcptrUnaryFunction_double_complex uintptr - -func (p SwigcptrUnaryFunction_double_complex) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrUnaryFunction_double_complex) SwigIsUnaryFunction_double_complex() { -} - -var _wrap_UnaryFunction_double_complex_get_value unsafe.Pointer - -func _swig_wrap_UnaryFunction_double_complex_get_value(base SwigcptrUnaryFunction_double_complex) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_UnaryFunction_double_complex_get_value, _swig_p) - return -} - -func (arg1 SwigcptrUnaryFunction_double_complex) Get_value() (_swig_ret int) { - return _swig_wrap_UnaryFunction_double_complex_get_value(arg1) -} - -var _wrap_new_UnaryFunction_double_complex unsafe.Pointer - -func _swig_wrap_new_UnaryFunction_double_complex() (base SwigcptrUnaryFunction_double_complex) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_UnaryFunction_double_complex, _swig_p) - return -} - -func NewUnaryFunction_double_complex() (_swig_ret UnaryFunction_double_complex) { - return _swig_wrap_new_UnaryFunction_double_complex() -} - -var _wrap_delete_UnaryFunction_double_complex unsafe.Pointer - -func _swig_wrap_delete_UnaryFunction_double_complex(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_UnaryFunction_double_complex, _swig_p) - return -} - -func DeleteUnaryFunction_double_complex(arg1 UnaryFunction_double_complex) { - _swig_wrap_delete_UnaryFunction_double_complex(arg1.Swigcptr()) -} - -var _wrap_UnaryFunction_double_complex_get_base_value unsafe.Pointer - -func _swig_wrap_UnaryFunction_double_complex_get_base_value(base SwigcptrUnaryFunction_double_complex) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_UnaryFunction_double_complex_get_base_value, _swig_p) - return -} - -func (_swig_base SwigcptrUnaryFunction_double_complex) Get_base_value() (_swig_ret int) { - return _swig_wrap_UnaryFunction_double_complex_get_base_value(_swig_base) -} - -func (p SwigcptrUnaryFunction_double_complex) SwigIsUnaryFunctionBase() { -} - -func (p SwigcptrUnaryFunction_double_complex) SwigGetUnaryFunctionBase() UnaryFunctionBase { - return SwigcptrUnaryFunctionBase(p.Swigcptr()) -} - -type UnaryFunction_double_complex interface { - Swigcptr() uintptr - SwigIsUnaryFunction_double_complex() - Get_value() (_swig_ret int) - Get_base_value() (_swig_ret int) - SwigIsUnaryFunctionBase() - SwigGetUnaryFunctionBase() UnaryFunctionBase -} - -type SwigcptrArithUnaryFunction_double_complex uintptr - -func (p SwigcptrArithUnaryFunction_double_complex) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrArithUnaryFunction_double_complex) SwigIsArithUnaryFunction_double_complex() { -} - -var _wrap_ArithUnaryFunction_double_complex_get_arith_value unsafe.Pointer - -func _swig_wrap_ArithUnaryFunction_double_complex_get_arith_value(base SwigcptrArithUnaryFunction_double_complex) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_ArithUnaryFunction_double_complex_get_arith_value, _swig_p) - return -} - -func (arg1 SwigcptrArithUnaryFunction_double_complex) Get_arith_value() (_swig_ret int) { - return _swig_wrap_ArithUnaryFunction_double_complex_get_arith_value(arg1) -} - -var _wrap_new_ArithUnaryFunction_double_complex unsafe.Pointer - -func _swig_wrap_new_ArithUnaryFunction_double_complex() (base SwigcptrArithUnaryFunction_double_complex) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_ArithUnaryFunction_double_complex, _swig_p) - return -} - -func NewArithUnaryFunction_double_complex() (_swig_ret ArithUnaryFunction_double_complex) { - return _swig_wrap_new_ArithUnaryFunction_double_complex() -} - -var _wrap_delete_ArithUnaryFunction_double_complex unsafe.Pointer - -func _swig_wrap_delete_ArithUnaryFunction_double_complex(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_ArithUnaryFunction_double_complex, _swig_p) - return -} - -func DeleteArithUnaryFunction_double_complex(arg1 ArithUnaryFunction_double_complex) { - _swig_wrap_delete_ArithUnaryFunction_double_complex(arg1.Swigcptr()) -} - -var _wrap_ArithUnaryFunction_double_complex_get_value unsafe.Pointer - -func _swig_wrap_ArithUnaryFunction_double_complex_get_value(base SwigcptrArithUnaryFunction_double_complex) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_ArithUnaryFunction_double_complex_get_value, _swig_p) - return -} - -func (_swig_base SwigcptrArithUnaryFunction_double_complex) Get_value() (_swig_ret int) { - return _swig_wrap_ArithUnaryFunction_double_complex_get_value(_swig_base) -} - -var _wrap_ArithUnaryFunction_double_complex_get_base_value unsafe.Pointer - -func _swig_wrap_ArithUnaryFunction_double_complex_get_base_value(base SwigcptrArithUnaryFunction_double_complex) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_ArithUnaryFunction_double_complex_get_base_value, _swig_p) - return -} - -func (_swig_base SwigcptrArithUnaryFunction_double_complex) Get_base_value() (_swig_ret int) { - return _swig_wrap_ArithUnaryFunction_double_complex_get_base_value(_swig_base) -} - -func (p SwigcptrArithUnaryFunction_double_complex) SwigIsUnaryFunction_double_complex() { -} - -func (p SwigcptrArithUnaryFunction_double_complex) SwigGetUnaryFunction_double_complex() UnaryFunction_double_complex { - return SwigcptrUnaryFunction_double_complex(p.Swigcptr()) -} - -func (p SwigcptrArithUnaryFunction_double_complex) SwigIsUnaryFunctionBase() { -} - -func (p SwigcptrArithUnaryFunction_double_complex) SwigGetUnaryFunctionBase() UnaryFunctionBase { - return SwigcptrUnaryFunctionBase(p.Swigcptr()) -} - -type ArithUnaryFunction_double_complex interface { - Swigcptr() uintptr - SwigIsArithUnaryFunction_double_complex() - Get_arith_value() (_swig_ret int) - Get_value() (_swig_ret int) - Get_base_value() (_swig_ret int) - SwigIsUnaryFunction_double_complex() - SwigGetUnaryFunction_double_complex() UnaryFunction_double_complex - SwigIsUnaryFunctionBase() - SwigGetUnaryFunctionBase() UnaryFunctionBase -} - -var _wrap_make_Multiplies_double_double_complex_complex unsafe.Pointer - -func _swig_wrap_make_Multiplies_double_double_complex_complex(base uintptr, _ uintptr) (_ SwigcptrArithUnaryFunction_double_complex) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_make_Multiplies_double_double_complex_complex, _swig_p) - return -} - -func Make_Multiplies_double_double_complex_complex(arg1 ArithUnaryFunction_double_double, arg2 ArithUnaryFunction_complex_complex) (_swig_ret ArithUnaryFunction_double_complex) { - return _swig_wrap_make_Multiplies_double_double_complex_complex(arg1.Swigcptr(), arg2.Swigcptr()) -} - -var _wrap_make_Multiplies_double_double_double_double unsafe.Pointer - -func _swig_wrap_make_Multiplies_double_double_double_double(base uintptr, _ uintptr) (_ SwigcptrArithUnaryFunction_double_double) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_make_Multiplies_double_double_double_double, _swig_p) - return -} - -func Make_Multiplies_double_double_double_double(arg1 ArithUnaryFunction_double_double, arg2 ArithUnaryFunction_double_double) (_swig_ret ArithUnaryFunction_double_double) { - return _swig_wrap_make_Multiplies_double_double_double_double(arg1.Swigcptr(), arg2.Swigcptr()) -} - -var _wrap_make_Multiplies_complex_complex_complex_complex unsafe.Pointer - -func _swig_wrap_make_Multiplies_complex_complex_complex_complex(base uintptr, _ uintptr) (_ SwigcptrArithUnaryFunction_complex_complex) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_make_Multiplies_complex_complex_complex_complex, _swig_p) - return -} - -func Make_Multiplies_complex_complex_complex_complex(arg1 ArithUnaryFunction_complex_complex, arg2 ArithUnaryFunction_complex_complex) (_swig_ret ArithUnaryFunction_complex_complex) { - return _swig_wrap_make_Multiplies_complex_complex_complex_complex(arg1.Swigcptr(), arg2.Swigcptr()) -} - -var _wrap_make_Multiplies_complex_complex_double_double unsafe.Pointer - -func _swig_wrap_make_Multiplies_complex_complex_double_double(base uintptr, _ uintptr) (_ SwigcptrArithUnaryFunction_double_complex) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_make_Multiplies_complex_complex_double_double, _swig_p) - return -} - -func Make_Multiplies_complex_complex_double_double(arg1 ArithUnaryFunction_complex_complex, arg2 ArithUnaryFunction_double_double) (_swig_ret ArithUnaryFunction_double_complex) { - return _swig_wrap_make_Multiplies_complex_complex_double_double(arg1.Swigcptr(), arg2.Swigcptr()) -} - -var _wrap_my_func_r unsafe.Pointer - -func _swig_wrap_my_func_r(base uintptr) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_my_func_r, _swig_p) - return -} - -func My_func_r(arg1 ArithUnaryFunction_double_double) (_swig_ret int) { - return _swig_wrap_my_func_r(arg1.Swigcptr()) -} - -var _wrap_my_func_c unsafe.Pointer - -func _swig_wrap_my_func_c(base uintptr) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_my_func_c, _swig_p) - return -} - -func My_func_c(arg1 ArithUnaryFunction_complex_complex) (_swig_ret int) { - return _swig_wrap_my_func_c(arg1.Swigcptr()) -} - -type SwigcptrSin uintptr - -func (p SwigcptrSin) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrSin) SwigIsSin() { -} - -var _wrap_new_Sin unsafe.Pointer - -func _swig_wrap_new_Sin() (base SwigcptrSin) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Sin, _swig_p) - return -} - -func NewSin() (_swig_ret Sin) { - return _swig_wrap_new_Sin() -} - -var _wrap_delete_Sin unsafe.Pointer - -func _swig_wrap_delete_Sin(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Sin, _swig_p) - return -} - -func DeleteSin(arg1 Sin) { - _swig_wrap_delete_Sin(arg1.Swigcptr()) -} - -var _wrap_Sin_get_arith_value unsafe.Pointer - -func _swig_wrap_Sin_get_arith_value(base SwigcptrSin) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Sin_get_arith_value, _swig_p) - return -} - -func (_swig_base SwigcptrSin) Get_arith_value() (_swig_ret int) { - return _swig_wrap_Sin_get_arith_value(_swig_base) -} - -var _wrap_Sin_get_value unsafe.Pointer - -func _swig_wrap_Sin_get_value(base SwigcptrSin) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Sin_get_value, _swig_p) - return -} - -func (_swig_base SwigcptrSin) Get_value() (_swig_ret int) { - return _swig_wrap_Sin_get_value(_swig_base) -} - -var _wrap_Sin_get_base_value unsafe.Pointer - -func _swig_wrap_Sin_get_base_value(base SwigcptrSin) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Sin_get_base_value, _swig_p) - return -} - -func (_swig_base SwigcptrSin) Get_base_value() (_swig_ret int) { - return _swig_wrap_Sin_get_base_value(_swig_base) -} - -func (p SwigcptrSin) SwigIsArithUnaryFunction_double_double() { -} - -func (p SwigcptrSin) SwigGetArithUnaryFunction_double_double() ArithUnaryFunction_double_double { - return SwigcptrArithUnaryFunction_double_double(p.Swigcptr()) -} - -func (p SwigcptrSin) SwigIsUnaryFunction_double_double() { -} - -func (p SwigcptrSin) SwigGetUnaryFunction_double_double() UnaryFunction_double_double { - return SwigcptrUnaryFunction_double_double(p.Swigcptr()) -} - -func (p SwigcptrSin) SwigIsUnaryFunctionBase() { -} - -func (p SwigcptrSin) SwigGetUnaryFunctionBase() UnaryFunctionBase { - return SwigcptrUnaryFunctionBase(p.Swigcptr()) -} - -type Sin interface { - Swigcptr() uintptr - SwigIsSin() - Get_arith_value() (_swig_ret int) - Get_value() (_swig_ret int) - Get_base_value() (_swig_ret int) - SwigIsArithUnaryFunction_double_double() - SwigGetArithUnaryFunction_double_double() ArithUnaryFunction_double_double - SwigIsUnaryFunction_double_double() - SwigGetUnaryFunction_double_double() UnaryFunction_double_double - SwigIsUnaryFunctionBase() - SwigGetUnaryFunctionBase() UnaryFunctionBase -} - -type SwigcptrCSin uintptr - -func (p SwigcptrCSin) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrCSin) SwigIsCSin() { -} - -var _wrap_new_CSin unsafe.Pointer - -func _swig_wrap_new_CSin() (base SwigcptrCSin) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_CSin, _swig_p) - return -} - -func NewCSin() (_swig_ret CSin) { - return _swig_wrap_new_CSin() -} - -var _wrap_delete_CSin unsafe.Pointer - -func _swig_wrap_delete_CSin(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_CSin, _swig_p) - return -} - -func DeleteCSin(arg1 CSin) { - _swig_wrap_delete_CSin(arg1.Swigcptr()) -} - -var _wrap_CSin_get_arith_value unsafe.Pointer - -func _swig_wrap_CSin_get_arith_value(base SwigcptrCSin) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_CSin_get_arith_value, _swig_p) - return -} - -func (_swig_base SwigcptrCSin) Get_arith_value() (_swig_ret int) { - return _swig_wrap_CSin_get_arith_value(_swig_base) -} - -var _wrap_CSin_get_value unsafe.Pointer - -func _swig_wrap_CSin_get_value(base SwigcptrCSin) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_CSin_get_value, _swig_p) - return -} - -func (_swig_base SwigcptrCSin) Get_value() (_swig_ret int) { - return _swig_wrap_CSin_get_value(_swig_base) -} - -var _wrap_CSin_get_base_value unsafe.Pointer - -func _swig_wrap_CSin_get_base_value(base SwigcptrCSin) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_CSin_get_base_value, _swig_p) - return -} - -func (_swig_base SwigcptrCSin) Get_base_value() (_swig_ret int) { - return _swig_wrap_CSin_get_base_value(_swig_base) -} - -func (p SwigcptrCSin) SwigIsArithUnaryFunction_complex_complex() { -} - -func (p SwigcptrCSin) SwigGetArithUnaryFunction_complex_complex() ArithUnaryFunction_complex_complex { - return SwigcptrArithUnaryFunction_complex_complex(p.Swigcptr()) -} - -func (p SwigcptrCSin) SwigIsUnaryFunction_complex_complex() { -} - -func (p SwigcptrCSin) SwigGetUnaryFunction_complex_complex() UnaryFunction_complex_complex { - return SwigcptrUnaryFunction_complex_complex(p.Swigcptr()) -} - -func (p SwigcptrCSin) SwigIsUnaryFunctionBase() { -} - -func (p SwigcptrCSin) SwigGetUnaryFunctionBase() UnaryFunctionBase { - return SwigcptrUnaryFunctionBase(p.Swigcptr()) -} - -type CSin interface { - Swigcptr() uintptr - SwigIsCSin() - Get_arith_value() (_swig_ret int) - Get_value() (_swig_ret int) - Get_base_value() (_swig_ret int) - SwigIsArithUnaryFunction_complex_complex() - SwigGetArithUnaryFunction_complex_complex() ArithUnaryFunction_complex_complex - SwigIsUnaryFunction_complex_complex() - SwigGetUnaryFunction_complex_complex() UnaryFunction_complex_complex - SwigIsUnaryFunctionBase() - SwigGetUnaryFunctionBase() UnaryFunctionBase -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/template_typedef_cplx3_runme b/Examples/test-suite/go/template_typedef_cplx3_runme deleted file mode 100755 index 7d3192c65..000000000 Binary files a/Examples/test-suite/go/template_typedef_cplx3_runme and /dev/null differ diff --git a/Examples/test-suite/go/template_typedef_cplx4.go b/Examples/test-suite/go/template_typedef_cplx4.go deleted file mode 100644 index 9c49f6f41..000000000 --- a/Examples/test-suite/go/template_typedef_cplx4.go +++ /dev/null @@ -1,896 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../template_typedef_cplx4.i - -package template_typedef_cplx4 - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrUnaryFunctionBase uintptr - -func (p SwigcptrUnaryFunctionBase) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrUnaryFunctionBase) SwigIsUnaryFunctionBase() { -} - -var _wrap_UnaryFunctionBase_get_base_value unsafe.Pointer - -func _swig_wrap_UnaryFunctionBase_get_base_value(base SwigcptrUnaryFunctionBase) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_UnaryFunctionBase_get_base_value, _swig_p) - return -} - -func (arg1 SwigcptrUnaryFunctionBase) Get_base_value() (_swig_ret int) { - return _swig_wrap_UnaryFunctionBase_get_base_value(arg1) -} - -var _wrap_new_UnaryFunctionBase unsafe.Pointer - -func _swig_wrap_new_UnaryFunctionBase() (base SwigcptrUnaryFunctionBase) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_UnaryFunctionBase, _swig_p) - return -} - -func NewUnaryFunctionBase() (_swig_ret UnaryFunctionBase) { - return _swig_wrap_new_UnaryFunctionBase() -} - -var _wrap_delete_UnaryFunctionBase unsafe.Pointer - -func _swig_wrap_delete_UnaryFunctionBase(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_UnaryFunctionBase, _swig_p) - return -} - -func DeleteUnaryFunctionBase(arg1 UnaryFunctionBase) { - _swig_wrap_delete_UnaryFunctionBase(arg1.Swigcptr()) -} - -type UnaryFunctionBase interface { - Swigcptr() uintptr - SwigIsUnaryFunctionBase() - Get_base_value() (_swig_ret int) -} - -type SwigcptrUnaryFunction_double_double uintptr - -func (p SwigcptrUnaryFunction_double_double) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrUnaryFunction_double_double) SwigIsUnaryFunction_double_double() { -} - -var _wrap_UnaryFunction_double_double_get_value unsafe.Pointer - -func _swig_wrap_UnaryFunction_double_double_get_value(base SwigcptrUnaryFunction_double_double) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_UnaryFunction_double_double_get_value, _swig_p) - return -} - -func (arg1 SwigcptrUnaryFunction_double_double) Get_value() (_swig_ret int) { - return _swig_wrap_UnaryFunction_double_double_get_value(arg1) -} - -var _wrap_new_UnaryFunction_double_double unsafe.Pointer - -func _swig_wrap_new_UnaryFunction_double_double() (base SwigcptrUnaryFunction_double_double) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_UnaryFunction_double_double, _swig_p) - return -} - -func NewUnaryFunction_double_double() (_swig_ret UnaryFunction_double_double) { - return _swig_wrap_new_UnaryFunction_double_double() -} - -var _wrap_delete_UnaryFunction_double_double unsafe.Pointer - -func _swig_wrap_delete_UnaryFunction_double_double(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_UnaryFunction_double_double, _swig_p) - return -} - -func DeleteUnaryFunction_double_double(arg1 UnaryFunction_double_double) { - _swig_wrap_delete_UnaryFunction_double_double(arg1.Swigcptr()) -} - -var _wrap_UnaryFunction_double_double_get_base_value unsafe.Pointer - -func _swig_wrap_UnaryFunction_double_double_get_base_value(base SwigcptrUnaryFunction_double_double) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_UnaryFunction_double_double_get_base_value, _swig_p) - return -} - -func (_swig_base SwigcptrUnaryFunction_double_double) Get_base_value() (_swig_ret int) { - return _swig_wrap_UnaryFunction_double_double_get_base_value(_swig_base) -} - -func (p SwigcptrUnaryFunction_double_double) SwigIsUnaryFunctionBase() { -} - -func (p SwigcptrUnaryFunction_double_double) SwigGetUnaryFunctionBase() UnaryFunctionBase { - return SwigcptrUnaryFunctionBase(p.Swigcptr()) -} - -type UnaryFunction_double_double interface { - Swigcptr() uintptr - SwigIsUnaryFunction_double_double() - Get_value() (_swig_ret int) - Get_base_value() (_swig_ret int) - SwigIsUnaryFunctionBase() - SwigGetUnaryFunctionBase() UnaryFunctionBase -} - -type SwigcptrArithUnaryFunction_double_double uintptr - -func (p SwigcptrArithUnaryFunction_double_double) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrArithUnaryFunction_double_double) SwigIsArithUnaryFunction_double_double() { -} - -var _wrap_ArithUnaryFunction_double_double_get_arith_value unsafe.Pointer - -func _swig_wrap_ArithUnaryFunction_double_double_get_arith_value(base SwigcptrArithUnaryFunction_double_double) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_ArithUnaryFunction_double_double_get_arith_value, _swig_p) - return -} - -func (arg1 SwigcptrArithUnaryFunction_double_double) Get_arith_value() (_swig_ret int) { - return _swig_wrap_ArithUnaryFunction_double_double_get_arith_value(arg1) -} - -var _wrap_new_ArithUnaryFunction_double_double unsafe.Pointer - -func _swig_wrap_new_ArithUnaryFunction_double_double() (base SwigcptrArithUnaryFunction_double_double) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_ArithUnaryFunction_double_double, _swig_p) - return -} - -func NewArithUnaryFunction_double_double() (_swig_ret ArithUnaryFunction_double_double) { - return _swig_wrap_new_ArithUnaryFunction_double_double() -} - -var _wrap_delete_ArithUnaryFunction_double_double unsafe.Pointer - -func _swig_wrap_delete_ArithUnaryFunction_double_double(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_ArithUnaryFunction_double_double, _swig_p) - return -} - -func DeleteArithUnaryFunction_double_double(arg1 ArithUnaryFunction_double_double) { - _swig_wrap_delete_ArithUnaryFunction_double_double(arg1.Swigcptr()) -} - -var _wrap_ArithUnaryFunction_double_double_get_value unsafe.Pointer - -func _swig_wrap_ArithUnaryFunction_double_double_get_value(base SwigcptrArithUnaryFunction_double_double) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_ArithUnaryFunction_double_double_get_value, _swig_p) - return -} - -func (_swig_base SwigcptrArithUnaryFunction_double_double) Get_value() (_swig_ret int) { - return _swig_wrap_ArithUnaryFunction_double_double_get_value(_swig_base) -} - -var _wrap_ArithUnaryFunction_double_double_get_base_value unsafe.Pointer - -func _swig_wrap_ArithUnaryFunction_double_double_get_base_value(base SwigcptrArithUnaryFunction_double_double) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_ArithUnaryFunction_double_double_get_base_value, _swig_p) - return -} - -func (_swig_base SwigcptrArithUnaryFunction_double_double) Get_base_value() (_swig_ret int) { - return _swig_wrap_ArithUnaryFunction_double_double_get_base_value(_swig_base) -} - -func (p SwigcptrArithUnaryFunction_double_double) SwigIsUnaryFunction_double_double() { -} - -func (p SwigcptrArithUnaryFunction_double_double) SwigGetUnaryFunction_double_double() UnaryFunction_double_double { - return SwigcptrUnaryFunction_double_double(p.Swigcptr()) -} - -func (p SwigcptrArithUnaryFunction_double_double) SwigIsUnaryFunctionBase() { -} - -func (p SwigcptrArithUnaryFunction_double_double) SwigGetUnaryFunctionBase() UnaryFunctionBase { - return SwigcptrUnaryFunctionBase(p.Swigcptr()) -} - -type ArithUnaryFunction_double_double interface { - Swigcptr() uintptr - SwigIsArithUnaryFunction_double_double() - Get_arith_value() (_swig_ret int) - Get_value() (_swig_ret int) - Get_base_value() (_swig_ret int) - SwigIsUnaryFunction_double_double() - SwigGetUnaryFunction_double_double() UnaryFunction_double_double - SwigIsUnaryFunctionBase() - SwigGetUnaryFunctionBase() UnaryFunctionBase -} - -var _wrap_make_Identity_double unsafe.Pointer - -func _swig_wrap_make_Identity_double() (base SwigcptrArithUnaryFunction_double_double) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_make_Identity_double, _swig_p) - return -} - -func Make_Identity_double() (_swig_ret ArithUnaryFunction_double_double) { - return _swig_wrap_make_Identity_double() -} - -type SwigcptrUnaryFunction_complex_complex uintptr - -func (p SwigcptrUnaryFunction_complex_complex) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrUnaryFunction_complex_complex) SwigIsUnaryFunction_complex_complex() { -} - -var _wrap_UnaryFunction_complex_complex_get_value unsafe.Pointer - -func _swig_wrap_UnaryFunction_complex_complex_get_value(base SwigcptrUnaryFunction_complex_complex) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_UnaryFunction_complex_complex_get_value, _swig_p) - return -} - -func (arg1 SwigcptrUnaryFunction_complex_complex) Get_value() (_swig_ret int) { - return _swig_wrap_UnaryFunction_complex_complex_get_value(arg1) -} - -var _wrap_new_UnaryFunction_complex_complex unsafe.Pointer - -func _swig_wrap_new_UnaryFunction_complex_complex() (base SwigcptrUnaryFunction_complex_complex) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_UnaryFunction_complex_complex, _swig_p) - return -} - -func NewUnaryFunction_complex_complex() (_swig_ret UnaryFunction_complex_complex) { - return _swig_wrap_new_UnaryFunction_complex_complex() -} - -var _wrap_delete_UnaryFunction_complex_complex unsafe.Pointer - -func _swig_wrap_delete_UnaryFunction_complex_complex(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_UnaryFunction_complex_complex, _swig_p) - return -} - -func DeleteUnaryFunction_complex_complex(arg1 UnaryFunction_complex_complex) { - _swig_wrap_delete_UnaryFunction_complex_complex(arg1.Swigcptr()) -} - -var _wrap_UnaryFunction_complex_complex_get_base_value unsafe.Pointer - -func _swig_wrap_UnaryFunction_complex_complex_get_base_value(base SwigcptrUnaryFunction_complex_complex) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_UnaryFunction_complex_complex_get_base_value, _swig_p) - return -} - -func (_swig_base SwigcptrUnaryFunction_complex_complex) Get_base_value() (_swig_ret int) { - return _swig_wrap_UnaryFunction_complex_complex_get_base_value(_swig_base) -} - -func (p SwigcptrUnaryFunction_complex_complex) SwigIsUnaryFunctionBase() { -} - -func (p SwigcptrUnaryFunction_complex_complex) SwigGetUnaryFunctionBase() UnaryFunctionBase { - return SwigcptrUnaryFunctionBase(p.Swigcptr()) -} - -type UnaryFunction_complex_complex interface { - Swigcptr() uintptr - SwigIsUnaryFunction_complex_complex() - Get_value() (_swig_ret int) - Get_base_value() (_swig_ret int) - SwigIsUnaryFunctionBase() - SwigGetUnaryFunctionBase() UnaryFunctionBase -} - -type SwigcptrArithUnaryFunction_complex_complex uintptr - -func (p SwigcptrArithUnaryFunction_complex_complex) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrArithUnaryFunction_complex_complex) SwigIsArithUnaryFunction_complex_complex() { -} - -var _wrap_ArithUnaryFunction_complex_complex_get_arith_value unsafe.Pointer - -func _swig_wrap_ArithUnaryFunction_complex_complex_get_arith_value(base SwigcptrArithUnaryFunction_complex_complex) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_ArithUnaryFunction_complex_complex_get_arith_value, _swig_p) - return -} - -func (arg1 SwigcptrArithUnaryFunction_complex_complex) Get_arith_value() (_swig_ret int) { - return _swig_wrap_ArithUnaryFunction_complex_complex_get_arith_value(arg1) -} - -var _wrap_new_ArithUnaryFunction_complex_complex unsafe.Pointer - -func _swig_wrap_new_ArithUnaryFunction_complex_complex() (base SwigcptrArithUnaryFunction_complex_complex) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_ArithUnaryFunction_complex_complex, _swig_p) - return -} - -func NewArithUnaryFunction_complex_complex() (_swig_ret ArithUnaryFunction_complex_complex) { - return _swig_wrap_new_ArithUnaryFunction_complex_complex() -} - -var _wrap_delete_ArithUnaryFunction_complex_complex unsafe.Pointer - -func _swig_wrap_delete_ArithUnaryFunction_complex_complex(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_ArithUnaryFunction_complex_complex, _swig_p) - return -} - -func DeleteArithUnaryFunction_complex_complex(arg1 ArithUnaryFunction_complex_complex) { - _swig_wrap_delete_ArithUnaryFunction_complex_complex(arg1.Swigcptr()) -} - -var _wrap_ArithUnaryFunction_complex_complex_get_value unsafe.Pointer - -func _swig_wrap_ArithUnaryFunction_complex_complex_get_value(base SwigcptrArithUnaryFunction_complex_complex) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_ArithUnaryFunction_complex_complex_get_value, _swig_p) - return -} - -func (_swig_base SwigcptrArithUnaryFunction_complex_complex) Get_value() (_swig_ret int) { - return _swig_wrap_ArithUnaryFunction_complex_complex_get_value(_swig_base) -} - -var _wrap_ArithUnaryFunction_complex_complex_get_base_value unsafe.Pointer - -func _swig_wrap_ArithUnaryFunction_complex_complex_get_base_value(base SwigcptrArithUnaryFunction_complex_complex) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_ArithUnaryFunction_complex_complex_get_base_value, _swig_p) - return -} - -func (_swig_base SwigcptrArithUnaryFunction_complex_complex) Get_base_value() (_swig_ret int) { - return _swig_wrap_ArithUnaryFunction_complex_complex_get_base_value(_swig_base) -} - -func (p SwigcptrArithUnaryFunction_complex_complex) SwigIsUnaryFunction_complex_complex() { -} - -func (p SwigcptrArithUnaryFunction_complex_complex) SwigGetUnaryFunction_complex_complex() UnaryFunction_complex_complex { - return SwigcptrUnaryFunction_complex_complex(p.Swigcptr()) -} - -func (p SwigcptrArithUnaryFunction_complex_complex) SwigIsUnaryFunctionBase() { -} - -func (p SwigcptrArithUnaryFunction_complex_complex) SwigGetUnaryFunctionBase() UnaryFunctionBase { - return SwigcptrUnaryFunctionBase(p.Swigcptr()) -} - -type ArithUnaryFunction_complex_complex interface { - Swigcptr() uintptr - SwigIsArithUnaryFunction_complex_complex() - Get_arith_value() (_swig_ret int) - Get_value() (_swig_ret int) - Get_base_value() (_swig_ret int) - SwigIsUnaryFunction_complex_complex() - SwigGetUnaryFunction_complex_complex() UnaryFunction_complex_complex - SwigIsUnaryFunctionBase() - SwigGetUnaryFunctionBase() UnaryFunctionBase -} - -var _wrap_make_Identity_complex unsafe.Pointer - -func _swig_wrap_make_Identity_complex() (base SwigcptrArithUnaryFunction_complex_complex) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_make_Identity_complex, _swig_p) - return -} - -func Make_Identity_complex() (_swig_ret ArithUnaryFunction_complex_complex) { - return _swig_wrap_make_Identity_complex() -} - -type SwigcptrUnaryFunction_double_complex uintptr - -func (p SwigcptrUnaryFunction_double_complex) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrUnaryFunction_double_complex) SwigIsUnaryFunction_double_complex() { -} - -var _wrap_UnaryFunction_double_complex_get_value unsafe.Pointer - -func _swig_wrap_UnaryFunction_double_complex_get_value(base SwigcptrUnaryFunction_double_complex) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_UnaryFunction_double_complex_get_value, _swig_p) - return -} - -func (arg1 SwigcptrUnaryFunction_double_complex) Get_value() (_swig_ret int) { - return _swig_wrap_UnaryFunction_double_complex_get_value(arg1) -} - -var _wrap_new_UnaryFunction_double_complex unsafe.Pointer - -func _swig_wrap_new_UnaryFunction_double_complex() (base SwigcptrUnaryFunction_double_complex) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_UnaryFunction_double_complex, _swig_p) - return -} - -func NewUnaryFunction_double_complex() (_swig_ret UnaryFunction_double_complex) { - return _swig_wrap_new_UnaryFunction_double_complex() -} - -var _wrap_delete_UnaryFunction_double_complex unsafe.Pointer - -func _swig_wrap_delete_UnaryFunction_double_complex(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_UnaryFunction_double_complex, _swig_p) - return -} - -func DeleteUnaryFunction_double_complex(arg1 UnaryFunction_double_complex) { - _swig_wrap_delete_UnaryFunction_double_complex(arg1.Swigcptr()) -} - -var _wrap_UnaryFunction_double_complex_get_base_value unsafe.Pointer - -func _swig_wrap_UnaryFunction_double_complex_get_base_value(base SwigcptrUnaryFunction_double_complex) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_UnaryFunction_double_complex_get_base_value, _swig_p) - return -} - -func (_swig_base SwigcptrUnaryFunction_double_complex) Get_base_value() (_swig_ret int) { - return _swig_wrap_UnaryFunction_double_complex_get_base_value(_swig_base) -} - -func (p SwigcptrUnaryFunction_double_complex) SwigIsUnaryFunctionBase() { -} - -func (p SwigcptrUnaryFunction_double_complex) SwigGetUnaryFunctionBase() UnaryFunctionBase { - return SwigcptrUnaryFunctionBase(p.Swigcptr()) -} - -type UnaryFunction_double_complex interface { - Swigcptr() uintptr - SwigIsUnaryFunction_double_complex() - Get_value() (_swig_ret int) - Get_base_value() (_swig_ret int) - SwigIsUnaryFunctionBase() - SwigGetUnaryFunctionBase() UnaryFunctionBase -} - -type SwigcptrArithUnaryFunction_double_complex uintptr - -func (p SwigcptrArithUnaryFunction_double_complex) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrArithUnaryFunction_double_complex) SwigIsArithUnaryFunction_double_complex() { -} - -var _wrap_ArithUnaryFunction_double_complex_get_arith_value unsafe.Pointer - -func _swig_wrap_ArithUnaryFunction_double_complex_get_arith_value(base SwigcptrArithUnaryFunction_double_complex) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_ArithUnaryFunction_double_complex_get_arith_value, _swig_p) - return -} - -func (arg1 SwigcptrArithUnaryFunction_double_complex) Get_arith_value() (_swig_ret int) { - return _swig_wrap_ArithUnaryFunction_double_complex_get_arith_value(arg1) -} - -var _wrap_new_ArithUnaryFunction_double_complex unsafe.Pointer - -func _swig_wrap_new_ArithUnaryFunction_double_complex() (base SwigcptrArithUnaryFunction_double_complex) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_ArithUnaryFunction_double_complex, _swig_p) - return -} - -func NewArithUnaryFunction_double_complex() (_swig_ret ArithUnaryFunction_double_complex) { - return _swig_wrap_new_ArithUnaryFunction_double_complex() -} - -var _wrap_delete_ArithUnaryFunction_double_complex unsafe.Pointer - -func _swig_wrap_delete_ArithUnaryFunction_double_complex(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_ArithUnaryFunction_double_complex, _swig_p) - return -} - -func DeleteArithUnaryFunction_double_complex(arg1 ArithUnaryFunction_double_complex) { - _swig_wrap_delete_ArithUnaryFunction_double_complex(arg1.Swigcptr()) -} - -var _wrap_ArithUnaryFunction_double_complex_get_value unsafe.Pointer - -func _swig_wrap_ArithUnaryFunction_double_complex_get_value(base SwigcptrArithUnaryFunction_double_complex) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_ArithUnaryFunction_double_complex_get_value, _swig_p) - return -} - -func (_swig_base SwigcptrArithUnaryFunction_double_complex) Get_value() (_swig_ret int) { - return _swig_wrap_ArithUnaryFunction_double_complex_get_value(_swig_base) -} - -var _wrap_ArithUnaryFunction_double_complex_get_base_value unsafe.Pointer - -func _swig_wrap_ArithUnaryFunction_double_complex_get_base_value(base SwigcptrArithUnaryFunction_double_complex) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_ArithUnaryFunction_double_complex_get_base_value, _swig_p) - return -} - -func (_swig_base SwigcptrArithUnaryFunction_double_complex) Get_base_value() (_swig_ret int) { - return _swig_wrap_ArithUnaryFunction_double_complex_get_base_value(_swig_base) -} - -func (p SwigcptrArithUnaryFunction_double_complex) SwigIsUnaryFunction_double_complex() { -} - -func (p SwigcptrArithUnaryFunction_double_complex) SwigGetUnaryFunction_double_complex() UnaryFunction_double_complex { - return SwigcptrUnaryFunction_double_complex(p.Swigcptr()) -} - -func (p SwigcptrArithUnaryFunction_double_complex) SwigIsUnaryFunctionBase() { -} - -func (p SwigcptrArithUnaryFunction_double_complex) SwigGetUnaryFunctionBase() UnaryFunctionBase { - return SwigcptrUnaryFunctionBase(p.Swigcptr()) -} - -type ArithUnaryFunction_double_complex interface { - Swigcptr() uintptr - SwigIsArithUnaryFunction_double_complex() - Get_arith_value() (_swig_ret int) - Get_value() (_swig_ret int) - Get_base_value() (_swig_ret int) - SwigIsUnaryFunction_double_complex() - SwigGetUnaryFunction_double_complex() UnaryFunction_double_complex - SwigIsUnaryFunctionBase() - SwigGetUnaryFunctionBase() UnaryFunctionBase -} - -var _wrap_make_Multiplies_double_double_complex_complex unsafe.Pointer - -func _swig_wrap_make_Multiplies_double_double_complex_complex(base uintptr, _ uintptr) (_ SwigcptrArithUnaryFunction_double_complex) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_make_Multiplies_double_double_complex_complex, _swig_p) - return -} - -func Make_Multiplies_double_double_complex_complex(arg1 ArithUnaryFunction_double_double, arg2 ArithUnaryFunction_complex_complex) (_swig_ret ArithUnaryFunction_double_complex) { - return _swig_wrap_make_Multiplies_double_double_complex_complex(arg1.Swigcptr(), arg2.Swigcptr()) -} - -var _wrap_make_Multiplies_double_double_double_double unsafe.Pointer - -func _swig_wrap_make_Multiplies_double_double_double_double(base uintptr, _ uintptr) (_ SwigcptrArithUnaryFunction_double_double) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_make_Multiplies_double_double_double_double, _swig_p) - return -} - -func Make_Multiplies_double_double_double_double(arg1 ArithUnaryFunction_double_double, arg2 ArithUnaryFunction_double_double) (_swig_ret ArithUnaryFunction_double_double) { - return _swig_wrap_make_Multiplies_double_double_double_double(arg1.Swigcptr(), arg2.Swigcptr()) -} - -var _wrap_make_Multiplies_complex_complex_complex_complex unsafe.Pointer - -func _swig_wrap_make_Multiplies_complex_complex_complex_complex(base uintptr, _ uintptr) (_ SwigcptrArithUnaryFunction_complex_complex) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_make_Multiplies_complex_complex_complex_complex, _swig_p) - return -} - -func Make_Multiplies_complex_complex_complex_complex(arg1 ArithUnaryFunction_complex_complex, arg2 ArithUnaryFunction_complex_complex) (_swig_ret ArithUnaryFunction_complex_complex) { - return _swig_wrap_make_Multiplies_complex_complex_complex_complex(arg1.Swigcptr(), arg2.Swigcptr()) -} - -var _wrap_make_Multiplies_complex_complex_double_double unsafe.Pointer - -func _swig_wrap_make_Multiplies_complex_complex_double_double(base uintptr, _ uintptr) (_ SwigcptrArithUnaryFunction_double_complex) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_make_Multiplies_complex_complex_double_double, _swig_p) - return -} - -func Make_Multiplies_complex_complex_double_double(arg1 ArithUnaryFunction_complex_complex, arg2 ArithUnaryFunction_double_double) (_swig_ret ArithUnaryFunction_double_complex) { - return _swig_wrap_make_Multiplies_complex_complex_double_double(arg1.Swigcptr(), arg2.Swigcptr()) -} - -var _wrap_my_func_r unsafe.Pointer - -func _swig_wrap_my_func_r(base uintptr) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_my_func_r, _swig_p) - return -} - -func My_func_r(arg1 ArithUnaryFunction_double_double) (_swig_ret int) { - return _swig_wrap_my_func_r(arg1.Swigcptr()) -} - -var _wrap_my_func_c unsafe.Pointer - -func _swig_wrap_my_func_c(base uintptr) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_my_func_c, _swig_p) - return -} - -func My_func_c(arg1 ArithUnaryFunction_complex_complex) (_swig_ret int) { - return _swig_wrap_my_func_c(arg1.Swigcptr()) -} - -type SwigcptrSin uintptr - -func (p SwigcptrSin) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrSin) SwigIsSin() { -} - -var _wrap_new_Sin unsafe.Pointer - -func _swig_wrap_new_Sin() (base SwigcptrSin) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Sin, _swig_p) - return -} - -func NewSin() (_swig_ret Sin) { - return _swig_wrap_new_Sin() -} - -var _wrap_delete_Sin unsafe.Pointer - -func _swig_wrap_delete_Sin(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Sin, _swig_p) - return -} - -func DeleteSin(arg1 Sin) { - _swig_wrap_delete_Sin(arg1.Swigcptr()) -} - -var _wrap_Sin_get_arith_value unsafe.Pointer - -func _swig_wrap_Sin_get_arith_value(base SwigcptrSin) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Sin_get_arith_value, _swig_p) - return -} - -func (_swig_base SwigcptrSin) Get_arith_value() (_swig_ret int) { - return _swig_wrap_Sin_get_arith_value(_swig_base) -} - -var _wrap_Sin_get_value unsafe.Pointer - -func _swig_wrap_Sin_get_value(base SwigcptrSin) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Sin_get_value, _swig_p) - return -} - -func (_swig_base SwigcptrSin) Get_value() (_swig_ret int) { - return _swig_wrap_Sin_get_value(_swig_base) -} - -var _wrap_Sin_get_base_value unsafe.Pointer - -func _swig_wrap_Sin_get_base_value(base SwigcptrSin) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Sin_get_base_value, _swig_p) - return -} - -func (_swig_base SwigcptrSin) Get_base_value() (_swig_ret int) { - return _swig_wrap_Sin_get_base_value(_swig_base) -} - -func (p SwigcptrSin) SwigIsArithUnaryFunction_double_double() { -} - -func (p SwigcptrSin) SwigGetArithUnaryFunction_double_double() ArithUnaryFunction_double_double { - return SwigcptrArithUnaryFunction_double_double(p.Swigcptr()) -} - -func (p SwigcptrSin) SwigIsUnaryFunction_double_double() { -} - -func (p SwigcptrSin) SwigGetUnaryFunction_double_double() UnaryFunction_double_double { - return SwigcptrUnaryFunction_double_double(p.Swigcptr()) -} - -func (p SwigcptrSin) SwigIsUnaryFunctionBase() { -} - -func (p SwigcptrSin) SwigGetUnaryFunctionBase() UnaryFunctionBase { - return SwigcptrUnaryFunctionBase(p.Swigcptr()) -} - -type Sin interface { - Swigcptr() uintptr - SwigIsSin() - Get_arith_value() (_swig_ret int) - Get_value() (_swig_ret int) - Get_base_value() (_swig_ret int) - SwigIsArithUnaryFunction_double_double() - SwigGetArithUnaryFunction_double_double() ArithUnaryFunction_double_double - SwigIsUnaryFunction_double_double() - SwigGetUnaryFunction_double_double() UnaryFunction_double_double - SwigIsUnaryFunctionBase() - SwigGetUnaryFunctionBase() UnaryFunctionBase -} - -type SwigcptrCSin uintptr - -func (p SwigcptrCSin) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrCSin) SwigIsCSin() { -} - -var _wrap_new_CSin unsafe.Pointer - -func _swig_wrap_new_CSin() (base SwigcptrCSin) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_CSin, _swig_p) - return -} - -func NewCSin() (_swig_ret CSin) { - return _swig_wrap_new_CSin() -} - -var _wrap_delete_CSin unsafe.Pointer - -func _swig_wrap_delete_CSin(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_CSin, _swig_p) - return -} - -func DeleteCSin(arg1 CSin) { - _swig_wrap_delete_CSin(arg1.Swigcptr()) -} - -var _wrap_CSin_get_arith_value unsafe.Pointer - -func _swig_wrap_CSin_get_arith_value(base SwigcptrCSin) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_CSin_get_arith_value, _swig_p) - return -} - -func (_swig_base SwigcptrCSin) Get_arith_value() (_swig_ret int) { - return _swig_wrap_CSin_get_arith_value(_swig_base) -} - -var _wrap_CSin_get_value unsafe.Pointer - -func _swig_wrap_CSin_get_value(base SwigcptrCSin) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_CSin_get_value, _swig_p) - return -} - -func (_swig_base SwigcptrCSin) Get_value() (_swig_ret int) { - return _swig_wrap_CSin_get_value(_swig_base) -} - -var _wrap_CSin_get_base_value unsafe.Pointer - -func _swig_wrap_CSin_get_base_value(base SwigcptrCSin) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_CSin_get_base_value, _swig_p) - return -} - -func (_swig_base SwigcptrCSin) Get_base_value() (_swig_ret int) { - return _swig_wrap_CSin_get_base_value(_swig_base) -} - -func (p SwigcptrCSin) SwigIsArithUnaryFunction_complex_complex() { -} - -func (p SwigcptrCSin) SwigGetArithUnaryFunction_complex_complex() ArithUnaryFunction_complex_complex { - return SwigcptrArithUnaryFunction_complex_complex(p.Swigcptr()) -} - -func (p SwigcptrCSin) SwigIsUnaryFunction_complex_complex() { -} - -func (p SwigcptrCSin) SwigGetUnaryFunction_complex_complex() UnaryFunction_complex_complex { - return SwigcptrUnaryFunction_complex_complex(p.Swigcptr()) -} - -func (p SwigcptrCSin) SwigIsUnaryFunctionBase() { -} - -func (p SwigcptrCSin) SwigGetUnaryFunctionBase() UnaryFunctionBase { - return SwigcptrUnaryFunctionBase(p.Swigcptr()) -} - -type CSin interface { - Swigcptr() uintptr - SwigIsCSin() - Get_arith_value() (_swig_ret int) - Get_value() (_swig_ret int) - Get_base_value() (_swig_ret int) - SwigIsArithUnaryFunction_complex_complex() - SwigGetArithUnaryFunction_complex_complex() ArithUnaryFunction_complex_complex - SwigIsUnaryFunction_complex_complex() - SwigGetUnaryFunction_complex_complex() UnaryFunction_complex_complex - SwigIsUnaryFunctionBase() - SwigGetUnaryFunctionBase() UnaryFunctionBase -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/template_typedef_cplx4_runme b/Examples/test-suite/go/template_typedef_cplx4_runme deleted file mode 100755 index 44d4073f4..000000000 Binary files a/Examples/test-suite/go/template_typedef_cplx4_runme and /dev/null differ diff --git a/Examples/test-suite/go/template_typedef_cplx5.go b/Examples/test-suite/go/template_typedef_cplx5.go deleted file mode 100644 index 2a3bb1f71..000000000 --- a/Examples/test-suite/go/template_typedef_cplx5.go +++ /dev/null @@ -1,109 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../template_typedef_cplx5.i - -package template_typedef_cplx5 - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrA uintptr - -func (p SwigcptrA) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrA) SwigIsA() { -} - -var _wrap_A_test1 unsafe.Pointer - -func _swig_wrap_A_test1(base SwigcptrA) (_ SwigcptrStd_complex_Sl_double_Sg_) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_A_test1, _swig_p) - return -} - -func (arg1 SwigcptrA) Test1() (_swig_ret Std_complex_Sl_double_Sg_) { - return _swig_wrap_A_test1(arg1) -} - -var _wrap_A_test2 unsafe.Pointer - -func _swig_wrap_A_test2(base SwigcptrA) (_ SwigcptrStd_complex_Sl_double_Sg_) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_A_test2, _swig_p) - return -} - -func (arg1 SwigcptrA) Test2() (_swig_ret Std_complex_Sl_double_Sg_) { - return _swig_wrap_A_test2(arg1) -} - -var _wrap_new_A unsafe.Pointer - -func _swig_wrap_new_A() (base SwigcptrA) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_A, _swig_p) - return -} - -func NewA() (_swig_ret A) { - return _swig_wrap_new_A() -} - -var _wrap_delete_A unsafe.Pointer - -func _swig_wrap_delete_A(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_A, _swig_p) - return -} - -func DeleteA(arg1 A) { - _swig_wrap_delete_A(arg1.Swigcptr()) -} - -type A interface { - Swigcptr() uintptr - SwigIsA() - Test1() (_swig_ret Std_complex_Sl_double_Sg_) - Test2() (_swig_ret Std_complex_Sl_double_Sg_) -} - - -type SwigcptrStd_complex_Sl_double_Sg_ uintptr -type Std_complex_Sl_double_Sg_ interface { - Swigcptr() uintptr; -} -func (p SwigcptrStd_complex_Sl_double_Sg_) Swigcptr() uintptr { - return uintptr(p) -} - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/template_typedef_fnc.go b/Examples/test-suite/go/template_typedef_fnc.go deleted file mode 100644 index ff34cd1f2..000000000 --- a/Examples/test-suite/go/template_typedef_fnc.go +++ /dev/null @@ -1,214 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../template_typedef_fnc.i - -package template_typedef_fnc - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrIntVector uintptr - -func (p SwigcptrIntVector) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrIntVector) SwigIsIntVector() { -} - -var _wrap_new_IntVector__SWIG_0 unsafe.Pointer - -func _swig_wrap_new_IntVector__SWIG_0() (base SwigcptrIntVector) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_IntVector__SWIG_0, _swig_p) - return -} - -func NewIntVector__SWIG_0() (_swig_ret IntVector) { - return _swig_wrap_new_IntVector__SWIG_0() -} - -var _wrap_new_IntVector__SWIG_1 unsafe.Pointer - -func _swig_wrap_new_IntVector__SWIG_1(base int64) (_ SwigcptrIntVector) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_IntVector__SWIG_1, _swig_p) - return -} - -func NewIntVector__SWIG_1(arg1 int64) (_swig_ret IntVector) { - return _swig_wrap_new_IntVector__SWIG_1(arg1) -} - -func NewIntVector(a ...interface{}) IntVector { - argc := len(a) - if argc == 0 { - return NewIntVector__SWIG_0() - } - if argc == 1 { - return NewIntVector__SWIG_1(a[0].(int64)) - } - panic("No match for overloaded function call") -} - -var _wrap_IntVector_size unsafe.Pointer - -func _swig_wrap_IntVector_size(base SwigcptrIntVector) (_ int64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_IntVector_size, _swig_p) - return -} - -func (arg1 SwigcptrIntVector) Size() (_swig_ret int64) { - return _swig_wrap_IntVector_size(arg1) -} - -var _wrap_IntVector_capacity unsafe.Pointer - -func _swig_wrap_IntVector_capacity(base SwigcptrIntVector) (_ int64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_IntVector_capacity, _swig_p) - return -} - -func (arg1 SwigcptrIntVector) Capacity() (_swig_ret int64) { - return _swig_wrap_IntVector_capacity(arg1) -} - -var _wrap_IntVector_reserve unsafe.Pointer - -func _swig_wrap_IntVector_reserve(base SwigcptrIntVector, _ int64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_IntVector_reserve, _swig_p) - return -} - -func (arg1 SwigcptrIntVector) Reserve(arg2 int64) { - _swig_wrap_IntVector_reserve(arg1, arg2) -} - -var _wrap_IntVector_isEmpty unsafe.Pointer - -func _swig_wrap_IntVector_isEmpty(base SwigcptrIntVector) (_ bool) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_IntVector_isEmpty, _swig_p) - return -} - -func (arg1 SwigcptrIntVector) IsEmpty() (_swig_ret bool) { - return _swig_wrap_IntVector_isEmpty(arg1) -} - -var _wrap_IntVector_clear unsafe.Pointer - -func _swig_wrap_IntVector_clear(base SwigcptrIntVector) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_IntVector_clear, _swig_p) - return -} - -func (arg1 SwigcptrIntVector) Clear() { - _swig_wrap_IntVector_clear(arg1) -} - -var _wrap_IntVector_add unsafe.Pointer - -func _swig_wrap_IntVector_add(base SwigcptrIntVector, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_IntVector_add, _swig_p) - return -} - -func (arg1 SwigcptrIntVector) Add(arg2 int) { - _swig_wrap_IntVector_add(arg1, arg2) -} - -var _wrap_IntVector_get unsafe.Pointer - -func _swig_wrap_IntVector_get(base SwigcptrIntVector, _ int) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_IntVector_get, _swig_p) - return -} - -func (arg1 SwigcptrIntVector) Get(arg2 int) (_swig_ret int) { - return _swig_wrap_IntVector_get(arg1, arg2) -} - -var _wrap_IntVector_set unsafe.Pointer - -func _swig_wrap_IntVector_set(base SwigcptrIntVector, _ int, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_IntVector_set, _swig_p) - return -} - -func (arg1 SwigcptrIntVector) Set(arg2 int, arg3 int) { - _swig_wrap_IntVector_set(arg1, arg2, arg3) -} - -var _wrap_delete_IntVector unsafe.Pointer - -func _swig_wrap_delete_IntVector(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_IntVector, _swig_p) - return -} - -func DeleteIntVector(arg1 IntVector) { - _swig_wrap_delete_IntVector(arg1.Swigcptr()) -} - -type IntVector interface { - Swigcptr() uintptr - SwigIsIntVector() - Size() (_swig_ret int64) - Capacity() (_swig_ret int64) - Reserve(arg2 int64) - IsEmpty() (_swig_ret bool) - Clear() - Add(arg2 int) - Get(arg2 int) (_swig_ret int) - Set(arg2 int, arg3 int) -} - -var _wrap_setCallback unsafe.Pointer - -func _swig_wrap_setCallback(base *_swig_fnptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_setCallback, _swig_p) - return -} - -func SetCallback(arg1 *_swig_fnptr) { - _swig_wrap_setCallback(arg1) -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/template_typedef_funcptr.go b/Examples/test-suite/go/template_typedef_funcptr.go deleted file mode 100644 index 30ad526c3..000000000 --- a/Examples/test-suite/go/template_typedef_funcptr.go +++ /dev/null @@ -1,175 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../template_typedef_funcptr.i - -package template_typedef_funcptr - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrMCContract uintptr - -func (p SwigcptrMCContract) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrMCContract) SwigIsMCContract() { -} - -var _wrap_new_MCContract unsafe.Pointer - -func _swig_wrap_new_MCContract() (base SwigcptrMCContract) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_MCContract, _swig_p) - return -} - -func NewMCContract() (_swig_ret MCContract) { - return _swig_wrap_new_MCContract() -} - -var _wrap_delete_MCContract unsafe.Pointer - -func _swig_wrap_delete_MCContract(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_MCContract, _swig_p) - return -} - -func DeleteMCContract(arg1 MCContract) { - _swig_wrap_delete_MCContract(arg1.Swigcptr()) -} - -type MCContract interface { - Swigcptr() uintptr - SwigIsMCContract() -} - -type SwigcptrMCContractFactory uintptr - -func (p SwigcptrMCContractFactory) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrMCContractFactory) SwigIsMCContractFactory() { -} - -var _wrap_MCContractFactory_getInstance unsafe.Pointer - -func _swig_wrap_MCContractFactory_getInstance() (base SwigcptrMCContractFactory) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_MCContractFactory_getInstance, _swig_p) - return -} - -func MCContractFactoryGetInstance() (_swig_ret MCContractFactory) { - return _swig_wrap_MCContractFactory_getInstance() -} - -var _wrap_new_MCContractFactory unsafe.Pointer - -func _swig_wrap_new_MCContractFactory() (base SwigcptrMCContractFactory) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_MCContractFactory, _swig_p) - return -} - -func NewMCContractFactory() (_swig_ret MCContractFactory) { - return _swig_wrap_new_MCContractFactory() -} - -var _wrap_delete_MCContractFactory unsafe.Pointer - -func _swig_wrap_delete_MCContractFactory(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_MCContractFactory, _swig_p) - return -} - -func DeleteMCContractFactory(arg1 MCContractFactory) { - _swig_wrap_delete_MCContractFactory(arg1.Swigcptr()) -} - -type MCContractFactory interface { - Swigcptr() uintptr - SwigIsMCContractFactory() -} - -type SwigcptrMCContractFactory2 uintptr - -func (p SwigcptrMCContractFactory2) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrMCContractFactory2) SwigIsMCContractFactory2() { -} - -var _wrap_MCContractFactory2_getInstance unsafe.Pointer - -func _swig_wrap_MCContractFactory2_getInstance() (base SwigcptrMCContractFactory2) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_MCContractFactory2_getInstance, _swig_p) - return -} - -func MCContractFactory2GetInstance() (_swig_ret MCContractFactory2) { - return _swig_wrap_MCContractFactory2_getInstance() -} - -var _wrap_new_MCContractFactory2 unsafe.Pointer - -func _swig_wrap_new_MCContractFactory2() (base SwigcptrMCContractFactory2) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_MCContractFactory2, _swig_p) - return -} - -func NewMCContractFactory2() (_swig_ret MCContractFactory2) { - return _swig_wrap_new_MCContractFactory2() -} - -var _wrap_delete_MCContractFactory2 unsafe.Pointer - -func _swig_wrap_delete_MCContractFactory2(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_MCContractFactory2, _swig_p) - return -} - -func DeleteMCContractFactory2(arg1 MCContractFactory2) { - _swig_wrap_delete_MCContractFactory2(arg1.Swigcptr()) -} - -type MCContractFactory2 interface { - Swigcptr() uintptr - SwigIsMCContractFactory2() -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/template_typedef_import.go b/Examples/test-suite/go/template_typedef_import.go deleted file mode 100644 index c0cbb2e8b..000000000 --- a/Examples/test-suite/go/template_typedef_import.go +++ /dev/null @@ -1,270 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../template_typedef_import.i - -package template_typedef_import - -import "unsafe" -import _ "runtime/cgo" -import "template_typedef_cplx2" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -var _wrap_my_func_r unsafe.Pointer - -func _swig_wrap_my_func_r(base uintptr) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_my_func_r, _swig_p) - return -} - -func My_func_r(arg1 template_typedef_cplx2.ArithUnaryFunction_double_double) (_swig_ret int) { - return _swig_wrap_my_func_r(arg1.Swigcptr()) -} - -var _wrap_my_func_c unsafe.Pointer - -func _swig_wrap_my_func_c(base uintptr) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_my_func_c, _swig_p) - return -} - -func My_func_c(arg1 template_typedef_cplx2.ArithUnaryFunction_complex_complex) (_swig_ret int) { - return _swig_wrap_my_func_c(arg1.Swigcptr()) -} - -type SwigcptrSin uintptr - -func (p SwigcptrSin) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrSin) SwigIsSin() { -} - -var _wrap_new_Sin unsafe.Pointer - -func _swig_wrap_new_Sin() (base SwigcptrSin) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Sin, _swig_p) - return -} - -func NewSin() (_swig_ret Sin) { - return _swig_wrap_new_Sin() -} - -var _wrap_delete_Sin unsafe.Pointer - -func _swig_wrap_delete_Sin(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Sin, _swig_p) - return -} - -func DeleteSin(arg1 Sin) { - _swig_wrap_delete_Sin(arg1.Swigcptr()) -} - -var _wrap_Sin_get_arith_value unsafe.Pointer - -func _swig_wrap_Sin_get_arith_value(base SwigcptrSin) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Sin_get_arith_value, _swig_p) - return -} - -func (_swig_base SwigcptrSin) Get_arith_value() (_swig_ret int) { - return _swig_wrap_Sin_get_arith_value(_swig_base) -} - -var _wrap_Sin_get_value unsafe.Pointer - -func _swig_wrap_Sin_get_value(base SwigcptrSin) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Sin_get_value, _swig_p) - return -} - -func (_swig_base SwigcptrSin) Get_value() (_swig_ret int) { - return _swig_wrap_Sin_get_value(_swig_base) -} - -var _wrap_Sin_get_base_value unsafe.Pointer - -func _swig_wrap_Sin_get_base_value(base SwigcptrSin) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Sin_get_base_value, _swig_p) - return -} - -func (_swig_base SwigcptrSin) Get_base_value() (_swig_ret int) { - return _swig_wrap_Sin_get_base_value(_swig_base) -} - -func (p SwigcptrSin) SwigIsArithUnaryFunction_double_double() { -} - -func (p SwigcptrSin) SwigGetArithUnaryFunction_double_double() template_typedef_cplx2.ArithUnaryFunction_double_double { - return template_typedef_cplx2.SwigcptrArithUnaryFunction_double_double(p.Swigcptr()) -} - -func (p SwigcptrSin) SwigIsUnaryFunction_double_double() { -} - -func (p SwigcptrSin) SwigGetUnaryFunction_double_double() template_typedef_cplx2.UnaryFunction_double_double { - return template_typedef_cplx2.SwigcptrUnaryFunction_double_double(p.Swigcptr()) -} - -func (p SwigcptrSin) SwigIsUnaryFunctionBase() { -} - -func (p SwigcptrSin) SwigGetUnaryFunctionBase() template_typedef_cplx2.UnaryFunctionBase { - return template_typedef_cplx2.SwigcptrUnaryFunctionBase(p.Swigcptr()) -} - -type Sin interface { - Swigcptr() uintptr - SwigIsSin() - Get_arith_value() (_swig_ret int) - Get_value() (_swig_ret int) - Get_base_value() (_swig_ret int) - SwigIsArithUnaryFunction_double_double() - SwigGetArithUnaryFunction_double_double() template_typedef_cplx2.ArithUnaryFunction_double_double - SwigIsUnaryFunction_double_double() - SwigGetUnaryFunction_double_double() template_typedef_cplx2.UnaryFunction_double_double - SwigIsUnaryFunctionBase() - SwigGetUnaryFunctionBase() template_typedef_cplx2.UnaryFunctionBase -} - -type SwigcptrCSin uintptr - -func (p SwigcptrCSin) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrCSin) SwigIsCSin() { -} - -var _wrap_new_CSin unsafe.Pointer - -func _swig_wrap_new_CSin() (base SwigcptrCSin) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_CSin, _swig_p) - return -} - -func NewCSin() (_swig_ret CSin) { - return _swig_wrap_new_CSin() -} - -var _wrap_delete_CSin unsafe.Pointer - -func _swig_wrap_delete_CSin(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_CSin, _swig_p) - return -} - -func DeleteCSin(arg1 CSin) { - _swig_wrap_delete_CSin(arg1.Swigcptr()) -} - -var _wrap_CSin_get_arith_value unsafe.Pointer - -func _swig_wrap_CSin_get_arith_value(base SwigcptrCSin) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_CSin_get_arith_value, _swig_p) - return -} - -func (_swig_base SwigcptrCSin) Get_arith_value() (_swig_ret int) { - return _swig_wrap_CSin_get_arith_value(_swig_base) -} - -var _wrap_CSin_get_value unsafe.Pointer - -func _swig_wrap_CSin_get_value(base SwigcptrCSin) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_CSin_get_value, _swig_p) - return -} - -func (_swig_base SwigcptrCSin) Get_value() (_swig_ret int) { - return _swig_wrap_CSin_get_value(_swig_base) -} - -var _wrap_CSin_get_base_value unsafe.Pointer - -func _swig_wrap_CSin_get_base_value(base SwigcptrCSin) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_CSin_get_base_value, _swig_p) - return -} - -func (_swig_base SwigcptrCSin) Get_base_value() (_swig_ret int) { - return _swig_wrap_CSin_get_base_value(_swig_base) -} - -func (p SwigcptrCSin) SwigIsArithUnaryFunction_complex_complex() { -} - -func (p SwigcptrCSin) SwigGetArithUnaryFunction_complex_complex() template_typedef_cplx2.ArithUnaryFunction_complex_complex { - return template_typedef_cplx2.SwigcptrArithUnaryFunction_complex_complex(p.Swigcptr()) -} - -func (p SwigcptrCSin) SwigIsUnaryFunction_complex_complex() { -} - -func (p SwigcptrCSin) SwigGetUnaryFunction_complex_complex() template_typedef_cplx2.UnaryFunction_complex_complex { - return template_typedef_cplx2.SwigcptrUnaryFunction_complex_complex(p.Swigcptr()) -} - -func (p SwigcptrCSin) SwigIsUnaryFunctionBase() { -} - -func (p SwigcptrCSin) SwigGetUnaryFunctionBase() template_typedef_cplx2.UnaryFunctionBase { - return template_typedef_cplx2.SwigcptrUnaryFunctionBase(p.Swigcptr()) -} - -type CSin interface { - Swigcptr() uintptr - SwigIsCSin() - Get_arith_value() (_swig_ret int) - Get_value() (_swig_ret int) - Get_base_value() (_swig_ret int) - SwigIsArithUnaryFunction_complex_complex() - SwigGetArithUnaryFunction_complex_complex() template_typedef_cplx2.ArithUnaryFunction_complex_complex - SwigIsUnaryFunction_complex_complex() - SwigGetUnaryFunction_complex_complex() template_typedef_cplx2.UnaryFunction_complex_complex - SwigIsUnaryFunctionBase() - SwigGetUnaryFunctionBase() template_typedef_cplx2.UnaryFunctionBase -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/template_typedef_inherit.go b/Examples/test-suite/go/template_typedef_inherit.go deleted file mode 100644 index 1df005644..000000000 --- a/Examples/test-suite/go/template_typedef_inherit.go +++ /dev/null @@ -1,246 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../template_typedef_inherit.i - -package template_typedef_inherit - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrStringPersistentCollection uintptr - -func (p SwigcptrStringPersistentCollection) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrStringPersistentCollection) SwigIsStringPersistentCollection() { -} - -var _wrap_StringPersistentCollection_add unsafe.Pointer - -func _swig_wrap_StringPersistentCollection_add(base SwigcptrStringPersistentCollection, _ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_StringPersistentCollection_add, _swig_p) - return -} - -func (arg1 SwigcptrStringPersistentCollection) Add(arg2 string) { - _swig_wrap_StringPersistentCollection_add(arg1, arg2) -} - -var _wrap_new_StringPersistentCollection unsafe.Pointer - -func _swig_wrap_new_StringPersistentCollection() (base SwigcptrStringPersistentCollection) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_StringPersistentCollection, _swig_p) - return -} - -func NewStringPersistentCollection() (_swig_ret StringPersistentCollection) { - return _swig_wrap_new_StringPersistentCollection() -} - -var _wrap_delete_StringPersistentCollection unsafe.Pointer - -func _swig_wrap_delete_StringPersistentCollection(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_StringPersistentCollection, _swig_p) - return -} - -func DeleteStringPersistentCollection(arg1 StringPersistentCollection) { - _swig_wrap_delete_StringPersistentCollection(arg1.Swigcptr()) -} - -type StringPersistentCollection interface { - Swigcptr() uintptr - SwigIsStringPersistentCollection() - Add(arg2 string) -} - -type SwigcptrDescriptionImplementation uintptr - -func (p SwigcptrDescriptionImplementation) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrDescriptionImplementation) SwigIsDescriptionImplementation() { -} - -var _wrap_new_DescriptionImplementation unsafe.Pointer - -func _swig_wrap_new_DescriptionImplementation() (base SwigcptrDescriptionImplementation) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_DescriptionImplementation, _swig_p) - return -} - -func NewDescriptionImplementation() (_swig_ret DescriptionImplementation) { - return _swig_wrap_new_DescriptionImplementation() -} - -var _wrap_delete_DescriptionImplementation unsafe.Pointer - -func _swig_wrap_delete_DescriptionImplementation(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_DescriptionImplementation, _swig_p) - return -} - -func DeleteDescriptionImplementation(arg1 DescriptionImplementation) { - _swig_wrap_delete_DescriptionImplementation(arg1.Swigcptr()) -} - -var _wrap_DescriptionImplementation_add unsafe.Pointer - -func _swig_wrap_DescriptionImplementation_add(base SwigcptrDescriptionImplementation, _ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_DescriptionImplementation_add, _swig_p) - return -} - -func (_swig_base SwigcptrDescriptionImplementation) Add(arg1 string) { - _swig_wrap_DescriptionImplementation_add(_swig_base, arg1) -} - -func (p SwigcptrDescriptionImplementation) SwigIsStringPersistentCollection() { -} - -func (p SwigcptrDescriptionImplementation) SwigGetStringPersistentCollection() StringPersistentCollection { - return SwigcptrStringPersistentCollection(p.Swigcptr()) -} - -type DescriptionImplementation interface { - Swigcptr() uintptr - SwigIsDescriptionImplementation() - Add(arg1 string) - SwigIsStringPersistentCollection() - SwigGetStringPersistentCollection() StringPersistentCollection -} - -type SwigcptrDescriptionImplementationTypedInterfaceObject uintptr - -func (p SwigcptrDescriptionImplementationTypedInterfaceObject) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrDescriptionImplementationTypedInterfaceObject) SwigIsDescriptionImplementationTypedInterfaceObject() { -} - -var _wrap_new_DescriptionImplementationTypedInterfaceObject unsafe.Pointer - -func _swig_wrap_new_DescriptionImplementationTypedInterfaceObject() (base SwigcptrDescriptionImplementationTypedInterfaceObject) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_DescriptionImplementationTypedInterfaceObject, _swig_p) - return -} - -func NewDescriptionImplementationTypedInterfaceObject() (_swig_ret DescriptionImplementationTypedInterfaceObject) { - return _swig_wrap_new_DescriptionImplementationTypedInterfaceObject() -} - -var _wrap_delete_DescriptionImplementationTypedInterfaceObject unsafe.Pointer - -func _swig_wrap_delete_DescriptionImplementationTypedInterfaceObject(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_DescriptionImplementationTypedInterfaceObject, _swig_p) - return -} - -func DeleteDescriptionImplementationTypedInterfaceObject(arg1 DescriptionImplementationTypedInterfaceObject) { - _swig_wrap_delete_DescriptionImplementationTypedInterfaceObject(arg1.Swigcptr()) -} - -type DescriptionImplementationTypedInterfaceObject interface { - Swigcptr() uintptr - SwigIsDescriptionImplementationTypedInterfaceObject() -} - -type SwigcptrDescriptionImplementationTypedCollectionInterfaceObject uintptr - -func (p SwigcptrDescriptionImplementationTypedCollectionInterfaceObject) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrDescriptionImplementationTypedCollectionInterfaceObject) SwigIsDescriptionImplementationTypedCollectionInterfaceObject() { -} - -var _wrap_DescriptionImplementationTypedCollectionInterfaceObject_add unsafe.Pointer - -func _swig_wrap_DescriptionImplementationTypedCollectionInterfaceObject_add(base SwigcptrDescriptionImplementationTypedCollectionInterfaceObject, _ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_DescriptionImplementationTypedCollectionInterfaceObject_add, _swig_p) - return -} - -func (arg1 SwigcptrDescriptionImplementationTypedCollectionInterfaceObject) Add(arg2 string) { - _swig_wrap_DescriptionImplementationTypedCollectionInterfaceObject_add(arg1, arg2) -} - -var _wrap_new_DescriptionImplementationTypedCollectionInterfaceObject unsafe.Pointer - -func _swig_wrap_new_DescriptionImplementationTypedCollectionInterfaceObject() (base SwigcptrDescriptionImplementationTypedCollectionInterfaceObject) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_DescriptionImplementationTypedCollectionInterfaceObject, _swig_p) - return -} - -func NewDescriptionImplementationTypedCollectionInterfaceObject() (_swig_ret DescriptionImplementationTypedCollectionInterfaceObject) { - return _swig_wrap_new_DescriptionImplementationTypedCollectionInterfaceObject() -} - -var _wrap_delete_DescriptionImplementationTypedCollectionInterfaceObject unsafe.Pointer - -func _swig_wrap_delete_DescriptionImplementationTypedCollectionInterfaceObject(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_DescriptionImplementationTypedCollectionInterfaceObject, _swig_p) - return -} - -func DeleteDescriptionImplementationTypedCollectionInterfaceObject(arg1 DescriptionImplementationTypedCollectionInterfaceObject) { - _swig_wrap_delete_DescriptionImplementationTypedCollectionInterfaceObject(arg1.Swigcptr()) -} - -func (p SwigcptrDescriptionImplementationTypedCollectionInterfaceObject) SwigIsDescriptionImplementationTypedInterfaceObject() { -} - -func (p SwigcptrDescriptionImplementationTypedCollectionInterfaceObject) SwigGetDescriptionImplementationTypedInterfaceObject() DescriptionImplementationTypedInterfaceObject { - return SwigcptrDescriptionImplementationTypedInterfaceObject(p.Swigcptr()) -} - -type DescriptionImplementationTypedCollectionInterfaceObject interface { - Swigcptr() uintptr - SwigIsDescriptionImplementationTypedCollectionInterfaceObject() - Add(arg2 string) - SwigIsDescriptionImplementationTypedInterfaceObject() - SwigGetDescriptionImplementationTypedInterfaceObject() DescriptionImplementationTypedInterfaceObject -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/template_typedef_ns.go b/Examples/test-suite/go/template_typedef_ns.go deleted file mode 100644 index bda2f9e60..000000000 --- a/Examples/test-suite/go/template_typedef_ns.go +++ /dev/null @@ -1,101 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../template_typedef_ns.i - -package template_typedef_ns - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrAlphaInt uintptr - -func (p SwigcptrAlphaInt) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrAlphaInt) SwigIsAlphaInt() { -} - -var _wrap_AlphaInt_x_set unsafe.Pointer - -func _swig_wrap_AlphaInt_x_set(base SwigcptrAlphaInt, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_AlphaInt_x_set, _swig_p) - return -} - -func (arg1 SwigcptrAlphaInt) SetX(arg2 int) { - _swig_wrap_AlphaInt_x_set(arg1, arg2) -} - -var _wrap_AlphaInt_x_get unsafe.Pointer - -func _swig_wrap_AlphaInt_x_get(base SwigcptrAlphaInt) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_AlphaInt_x_get, _swig_p) - return -} - -func (arg1 SwigcptrAlphaInt) GetX() (_swig_ret int) { - return _swig_wrap_AlphaInt_x_get(arg1) -} - -var _wrap_new_AlphaInt unsafe.Pointer - -func _swig_wrap_new_AlphaInt() (base SwigcptrAlphaInt) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_AlphaInt, _swig_p) - return -} - -func NewAlphaInt() (_swig_ret AlphaInt) { - return _swig_wrap_new_AlphaInt() -} - -var _wrap_delete_AlphaInt unsafe.Pointer - -func _swig_wrap_delete_AlphaInt(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_AlphaInt, _swig_p) - return -} - -func DeleteAlphaInt(arg1 AlphaInt) { - _swig_wrap_delete_AlphaInt(arg1.Swigcptr()) -} - -type AlphaInt interface { - Swigcptr() uintptr - SwigIsAlphaInt() - SetX(arg2 int) - GetX() (_swig_ret int) -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/template_typedef_ptr.go b/Examples/test-suite/go/template_typedef_ptr.go deleted file mode 100644 index 219d0fea6..000000000 --- a/Examples/test-suite/go/template_typedef_ptr.go +++ /dev/null @@ -1,113 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../template_typedef_ptr.i - -package template_typedef_ptr - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrC uintptr - -func (p SwigcptrC) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrC) SwigIsC() { -} - -var _wrap_new_C unsafe.Pointer - -func _swig_wrap_new_C() (base SwigcptrC) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_C, _swig_p) - return -} - -func NewC() (_swig_ret C) { - return _swig_wrap_new_C() -} - -var _wrap_delete_C unsafe.Pointer - -func _swig_wrap_delete_C(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_C, _swig_p) - return -} - -func DeleteC(arg1 C) { - _swig_wrap_delete_C(arg1.Swigcptr()) -} - -type C interface { - Swigcptr() uintptr - SwigIsC() -} - -type SwigcptrTest_pC uintptr - -func (p SwigcptrTest_pC) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrTest_pC) SwigIsTest_pC() { -} - -var _wrap_new_test_pC unsafe.Pointer - -func _swig_wrap_new_test_pC(base uintptr) (_ SwigcptrTest_pC) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_test_pC, _swig_p) - return -} - -func NewTest_pC(arg1 C) (_swig_ret Test_pC) { - return _swig_wrap_new_test_pC(arg1.Swigcptr()) -} - -var _wrap_delete_test_pC unsafe.Pointer - -func _swig_wrap_delete_test_pC(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_test_pC, _swig_p) - return -} - -func DeleteTest_pC(arg1 Test_pC) { - _swig_wrap_delete_test_pC(arg1.Swigcptr()) -} - -type Test_pC interface { - Swigcptr() uintptr - SwigIsTest_pC() -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/template_typedef_rec.go b/Examples/test-suite/go/template_typedef_rec.go deleted file mode 100644 index 66afd4dc2..000000000 --- a/Examples/test-suite/go/template_typedef_rec.go +++ /dev/null @@ -1,189 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../template_typedef_rec.i - -package template_typedef_rec - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrTest_Array uintptr - -func (p SwigcptrTest_Array) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrTest_Array) SwigIsTest_Array() { -} - -var _wrap_new_test_Array unsafe.Pointer - -func _swig_wrap_new_test_Array() (base SwigcptrTest_Array) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_test_Array, _swig_p) - return -} - -func NewTest_Array() (_swig_ret Test_Array) { - return _swig_wrap_new_test_Array() -} - -var _wrap_delete_test_Array unsafe.Pointer - -func _swig_wrap_delete_test_Array(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_test_Array, _swig_p) - return -} - -func DeleteTest_Array(arg1 Test_Array) { - _swig_wrap_delete_test_Array(arg1.Swigcptr()) -} - -type Test_Array interface { - Swigcptr() uintptr - SwigIsTest_Array() -} - -type SwigcptrModelNode uintptr - -func (p SwigcptrModelNode) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrModelNode) SwigIsModelNode() { -} - -var _wrap_new_ModelNode unsafe.Pointer - -func _swig_wrap_new_ModelNode() (base SwigcptrModelNode) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_ModelNode, _swig_p) - return -} - -func NewModelNode() (_swig_ret ModelNode) { - return _swig_wrap_new_ModelNode() -} - -var _wrap_delete_ModelNode unsafe.Pointer - -func _swig_wrap_delete_ModelNode(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_ModelNode, _swig_p) - return -} - -func DeleteModelNode(arg1 ModelNode) { - _swig_wrap_delete_ModelNode(arg1.Swigcptr()) -} - -type ModelNode interface { - Swigcptr() uintptr - SwigIsModelNode() -} - -type SwigcptrModel uintptr - -func (p SwigcptrModel) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrModel) SwigIsModel() { -} - -var _wrap_new_Model unsafe.Pointer - -func _swig_wrap_new_Model() (base SwigcptrModel) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Model, _swig_p) - return -} - -func NewModel() (_swig_ret Model) { - return _swig_wrap_new_Model() -} - -var _wrap_delete_Model unsafe.Pointer - -func _swig_wrap_delete_Model(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Model, _swig_p) - return -} - -func DeleteModel(arg1 Model) { - _swig_wrap_delete_Model(arg1.Swigcptr()) -} - -type Model interface { - Swigcptr() uintptr - SwigIsModel() -} - -type SwigcptrModelTree uintptr - -func (p SwigcptrModelTree) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrModelTree) SwigIsModelTree() { -} - -var _wrap_new_ModelTree unsafe.Pointer - -func _swig_wrap_new_ModelTree() (base SwigcptrModelTree) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_ModelTree, _swig_p) - return -} - -func NewModelTree() (_swig_ret ModelTree) { - return _swig_wrap_new_ModelTree() -} - -var _wrap_delete_ModelTree unsafe.Pointer - -func _swig_wrap_delete_ModelTree(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_ModelTree, _swig_p) - return -} - -func DeleteModelTree(arg1 ModelTree) { - _swig_wrap_delete_ModelTree(arg1.Swigcptr()) -} - -type ModelTree interface { - Swigcptr() uintptr - SwigIsModelTree() -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/template_typedef_typedef.go b/Examples/test-suite/go/template_typedef_typedef.go deleted file mode 100644 index 6fcba05a6..000000000 --- a/Examples/test-suite/go/template_typedef_typedef.go +++ /dev/null @@ -1,259 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../template_typedef_typedef.i - -package template_typedef_typedef - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrBase uintptr - -func (p SwigcptrBase) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrBase) SwigIsBase() { -} - -var _wrap_new_Base unsafe.Pointer - -func _swig_wrap_new_Base() (base SwigcptrBase) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Base, _swig_p) - return -} - -func NewBase() (_swig_ret Base) { - return _swig_wrap_new_Base() -} - -var _wrap_delete_Base unsafe.Pointer - -func _swig_wrap_delete_Base(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Base, _swig_p) - return -} - -func DeleteBase(arg1 Base) { - _swig_wrap_delete_Base(arg1.Swigcptr()) -} - -type Base interface { - Swigcptr() uintptr - SwigIsBase() -} - -type SwigcptrFactory uintptr - -func (p SwigcptrFactory) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrFactory) SwigIsFactory() { -} - -var _wrap_Factory_getBlabla4 unsafe.Pointer - -func _swig_wrap_Factory_getBlabla4(base SwigcptrFactory, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Factory_getBlabla4, _swig_p) - return -} - -func (arg1 SwigcptrFactory) GetBlabla4(arg2 Object2Base) { - _swig_wrap_Factory_getBlabla4(arg1, arg2.Swigcptr()) -} - -var _wrap_Factory_getBlabla3 unsafe.Pointer - -func _swig_wrap_Factory_getBlabla3(base SwigcptrFactory, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Factory_getBlabla3, _swig_p) - return -} - -func (arg1 SwigcptrFactory) GetBlabla3(arg2 ObjectBase) { - _swig_wrap_Factory_getBlabla3(arg1, arg2.Swigcptr()) -} - -var _wrap_new_Factory unsafe.Pointer - -func _swig_wrap_new_Factory() (base SwigcptrFactory) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Factory, _swig_p) - return -} - -func NewFactory() (_swig_ret Factory) { - return _swig_wrap_new_Factory() -} - -var _wrap_delete_Factory unsafe.Pointer - -func _swig_wrap_delete_Factory(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Factory, _swig_p) - return -} - -func DeleteFactory(arg1 Factory) { - _swig_wrap_delete_Factory(arg1.Swigcptr()) -} - -type Factory interface { - Swigcptr() uintptr - SwigIsFactory() - GetBlabla4(arg2 Object2Base) - GetBlabla3(arg2 ObjectBase) -} - -type SwigcptrObjectBase uintptr - -func (p SwigcptrObjectBase) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrObjectBase) SwigIsObjectBase() { -} - -var _wrap_ObjectBase_getBlabla1 unsafe.Pointer - -func _swig_wrap_ObjectBase_getBlabla1(base SwigcptrObjectBase, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_ObjectBase_getBlabla1, _swig_p) - return -} - -func (arg1 SwigcptrObjectBase) GetBlabla1(arg2 ObjectBase) { - _swig_wrap_ObjectBase_getBlabla1(arg1, arg2.Swigcptr()) -} - -var _wrap_new_ObjectBase unsafe.Pointer - -func _swig_wrap_new_ObjectBase() (base SwigcptrObjectBase) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_ObjectBase, _swig_p) - return -} - -func NewObjectBase() (_swig_ret ObjectBase) { - return _swig_wrap_new_ObjectBase() -} - -var _wrap_delete_ObjectBase unsafe.Pointer - -func _swig_wrap_delete_ObjectBase(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_ObjectBase, _swig_p) - return -} - -func DeleteObjectBase(arg1 ObjectBase) { - _swig_wrap_delete_ObjectBase(arg1.Swigcptr()) -} - -func (p SwigcptrObjectBase) SwigIsBase() { -} - -func (p SwigcptrObjectBase) SwigGetBase() Base { - return SwigcptrBase(p.Swigcptr()) -} - -type ObjectBase interface { - Swigcptr() uintptr - SwigIsObjectBase() - GetBlabla1(arg2 ObjectBase) - SwigIsBase() - SwigGetBase() Base -} - -type SwigcptrObject2Base uintptr - -func (p SwigcptrObject2Base) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrObject2Base) SwigIsObject2Base() { -} - -var _wrap_Object2Base_getBlabla2 unsafe.Pointer - -func _swig_wrap_Object2Base_getBlabla2(base SwigcptrObject2Base, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Object2Base_getBlabla2, _swig_p) - return -} - -func (arg1 SwigcptrObject2Base) GetBlabla2(arg2 Object2Base) { - _swig_wrap_Object2Base_getBlabla2(arg1, arg2.Swigcptr()) -} - -var _wrap_new_Object2Base unsafe.Pointer - -func _swig_wrap_new_Object2Base() (base SwigcptrObject2Base) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Object2Base, _swig_p) - return -} - -func NewObject2Base() (_swig_ret Object2Base) { - return _swig_wrap_new_Object2Base() -} - -var _wrap_delete_Object2Base unsafe.Pointer - -func _swig_wrap_delete_Object2Base(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Object2Base, _swig_p) - return -} - -func DeleteObject2Base(arg1 Object2Base) { - _swig_wrap_delete_Object2Base(arg1.Swigcptr()) -} - -func (p SwigcptrObject2Base) SwigIsBase() { -} - -func (p SwigcptrObject2Base) SwigGetBase() Base { - return SwigcptrBase(p.Swigcptr()) -} - -type Object2Base interface { - Swigcptr() uintptr - SwigIsObject2Base() - GetBlabla2(arg2 Object2Base) - SwigIsBase() - SwigGetBase() Base -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/template_typemaps.go b/Examples/test-suite/go/template_typemaps.go deleted file mode 100644 index 543b05e25..000000000 --- a/Examples/test-suite/go/template_typemaps.go +++ /dev/null @@ -1,237 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../template_typemaps.i - -package template_typemaps - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrFoo_I1 uintptr - -func (p SwigcptrFoo_I1) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrFoo_I1) SwigIsFoo_I1() { -} - -var _wrap_Foo_I1_val_set unsafe.Pointer - -func _swig_wrap_Foo_I1_val_set(base SwigcptrFoo_I1, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_I1_val_set, _swig_p) - return -} - -func (arg1 SwigcptrFoo_I1) SetVal(arg2 Integer1) { - _swig_wrap_Foo_I1_val_set(arg1, arg2.Swigcptr()) -} - -var _wrap_Foo_I1_val_get unsafe.Pointer - -func _swig_wrap_Foo_I1_val_get(base SwigcptrFoo_I1) (_ SwigcptrInteger1) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_I1_val_get, _swig_p) - return -} - -func (arg1 SwigcptrFoo_I1) GetVal() (_swig_ret Integer1) { - return _swig_wrap_Foo_I1_val_get(arg1) -} - -var _wrap_Foo_I1_get_value unsafe.Pointer - -func _swig_wrap_Foo_I1_get_value(base SwigcptrFoo_I1) (_ SwigcptrInteger1) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_I1_get_value, _swig_p) - return -} - -func (arg1 SwigcptrFoo_I1) Get_value() (_swig_ret Integer1) { - return _swig_wrap_Foo_I1_get_value(arg1) -} - -var _wrap_Foo_I1_set_value unsafe.Pointer - -func _swig_wrap_Foo_I1_set_value(base SwigcptrFoo_I1, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_I1_set_value, _swig_p) - return -} - -func (arg1 SwigcptrFoo_I1) Set_value(arg2 Integer1) { - _swig_wrap_Foo_I1_set_value(arg1, arg2.Swigcptr()) -} - -var _wrap_new_Foo_I1 unsafe.Pointer - -func _swig_wrap_new_Foo_I1() (base SwigcptrFoo_I1) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Foo_I1, _swig_p) - return -} - -func NewFoo_I1() (_swig_ret Foo_I1) { - return _swig_wrap_new_Foo_I1() -} - -var _wrap_delete_Foo_I1 unsafe.Pointer - -func _swig_wrap_delete_Foo_I1(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Foo_I1, _swig_p) - return -} - -func DeleteFoo_I1(arg1 Foo_I1) { - _swig_wrap_delete_Foo_I1(arg1.Swigcptr()) -} - -type Foo_I1 interface { - Swigcptr() uintptr - SwigIsFoo_I1() - SetVal(arg2 Integer1) - GetVal() (_swig_ret Integer1) - Get_value() (_swig_ret Integer1) - Set_value(arg2 Integer1) -} - -type SwigcptrFoo_I2 uintptr - -func (p SwigcptrFoo_I2) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrFoo_I2) SwigIsFoo_I2() { -} - -var _wrap_Foo_I2_val_set unsafe.Pointer - -func _swig_wrap_Foo_I2_val_set(base SwigcptrFoo_I2, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_I2_val_set, _swig_p) - return -} - -func (arg1 SwigcptrFoo_I2) SetVal(arg2 int) { - _swig_wrap_Foo_I2_val_set(arg1, arg2) -} - -var _wrap_Foo_I2_val_get unsafe.Pointer - -func _swig_wrap_Foo_I2_val_get(base SwigcptrFoo_I2) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_I2_val_get, _swig_p) - return -} - -func (arg1 SwigcptrFoo_I2) GetVal() (_swig_ret int) { - return _swig_wrap_Foo_I2_val_get(arg1) -} - -var _wrap_Foo_I2_get_value unsafe.Pointer - -func _swig_wrap_Foo_I2_get_value(base SwigcptrFoo_I2) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_I2_get_value, _swig_p) - return -} - -func (arg1 SwigcptrFoo_I2) Get_value() (_swig_ret int) { - return _swig_wrap_Foo_I2_get_value(arg1) -} - -var _wrap_Foo_I2_set_value unsafe.Pointer - -func _swig_wrap_Foo_I2_set_value(base SwigcptrFoo_I2, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_I2_set_value, _swig_p) - return -} - -func (arg1 SwigcptrFoo_I2) Set_value(arg2 int) { - _swig_wrap_Foo_I2_set_value(arg1, arg2) -} - -var _wrap_new_Foo_I2 unsafe.Pointer - -func _swig_wrap_new_Foo_I2() (base SwigcptrFoo_I2) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Foo_I2, _swig_p) - return -} - -func NewFoo_I2() (_swig_ret Foo_I2) { - return _swig_wrap_new_Foo_I2() -} - -var _wrap_delete_Foo_I2 unsafe.Pointer - -func _swig_wrap_delete_Foo_I2(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Foo_I2, _swig_p) - return -} - -func DeleteFoo_I2(arg1 Foo_I2) { - _swig_wrap_delete_Foo_I2(arg1.Swigcptr()) -} - -type Foo_I2 interface { - Swigcptr() uintptr - SwigIsFoo_I2() - SetVal(arg2 int) - GetVal() (_swig_ret int) - Get_value() (_swig_ret int) - Set_value(arg2 int) -} - -var _wrap_bar unsafe.Pointer - -func _swig_wrap_bar(base uintptr) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_bar, _swig_p) - return -} - -func Bar(arg1 Foo_I1) (_swig_ret int) { - return _swig_wrap_bar(arg1.Swigcptr()) -} - - -type SwigcptrInteger1 uintptr -type Integer1 interface { - Swigcptr() uintptr; -} -func (p SwigcptrInteger1) Swigcptr() uintptr { - return uintptr(p) -} - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/template_typemaps_typedef.go b/Examples/test-suite/go/template_typemaps_typedef.go deleted file mode 100644 index ae232e744..000000000 --- a/Examples/test-suite/go/template_typemaps_typedef.go +++ /dev/null @@ -1,520 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../template_typemaps_typedef.i - -package template_typemaps_typedef - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrA uintptr - -func (p SwigcptrA) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrA) SwigIsA() { -} - -var _wrap_A_val_set unsafe.Pointer - -func _swig_wrap_A_val_set(base SwigcptrA, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_A_val_set, _swig_p) - return -} - -func (arg1 SwigcptrA) SetVal(arg2 int) { - _swig_wrap_A_val_set(arg1, arg2) -} - -var _wrap_A_val_get unsafe.Pointer - -func _swig_wrap_A_val_get(base SwigcptrA) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_A_val_get, _swig_p) - return -} - -func (arg1 SwigcptrA) GetVal() (_swig_ret int) { - return _swig_wrap_A_val_get(arg1) -} - -var _wrap_new_A__SWIG_0 unsafe.Pointer - -func _swig_wrap_new_A__SWIG_0(base int) (_ SwigcptrA) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_A__SWIG_0, _swig_p) - return -} - -func NewA__SWIG_0(arg1 int) (_swig_ret A) { - return _swig_wrap_new_A__SWIG_0(arg1) -} - -var _wrap_new_A__SWIG_1 unsafe.Pointer - -func _swig_wrap_new_A__SWIG_1() (base SwigcptrA) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_A__SWIG_1, _swig_p) - return -} - -func NewA__SWIG_1() (_swig_ret A) { - return _swig_wrap_new_A__SWIG_1() -} - -func NewA(a ...interface{}) A { - argc := len(a) - if argc == 0 { - return NewA__SWIG_1() - } - if argc == 1 { - return NewA__SWIG_0(a[0].(int)) - } - panic("No match for overloaded function call") -} - -var _wrap_delete_A unsafe.Pointer - -func _swig_wrap_delete_A(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_A, _swig_p) - return -} - -func DeleteA(arg1 A) { - _swig_wrap_delete_A(arg1.Swigcptr()) -} - -type A interface { - Swigcptr() uintptr - SwigIsA() - SetVal(arg2 int) - GetVal() (_swig_ret int) -} - -type SwigcptrPairIntA uintptr - -func (p SwigcptrPairIntA) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrPairIntA) SwigIsPairIntA() { -} - -var _wrap_PairIntA_first_set unsafe.Pointer - -func _swig_wrap_PairIntA_first_set(base SwigcptrPairIntA, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_PairIntA_first_set, _swig_p) - return -} - -func (arg1 SwigcptrPairIntA) SetFirst(arg2 int) { - _swig_wrap_PairIntA_first_set(arg1, arg2) -} - -var _wrap_PairIntA_first_get unsafe.Pointer - -func _swig_wrap_PairIntA_first_get(base SwigcptrPairIntA) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_PairIntA_first_get, _swig_p) - return -} - -func (arg1 SwigcptrPairIntA) GetFirst() (_swig_ret int) { - return _swig_wrap_PairIntA_first_get(arg1) -} - -var _wrap_PairIntA_second_set unsafe.Pointer - -func _swig_wrap_PairIntA_second_set(base SwigcptrPairIntA, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_PairIntA_second_set, _swig_p) - return -} - -func (arg1 SwigcptrPairIntA) SetSecond(arg2 A) { - _swig_wrap_PairIntA_second_set(arg1, arg2.Swigcptr()) -} - -var _wrap_PairIntA_second_get unsafe.Pointer - -func _swig_wrap_PairIntA_second_get(base SwigcptrPairIntA) (_ SwigcptrA) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_PairIntA_second_get, _swig_p) - return -} - -func (arg1 SwigcptrPairIntA) GetSecond() (_swig_ret A) { - return _swig_wrap_PairIntA_second_get(arg1) -} - -var _wrap_new_PairIntA unsafe.Pointer - -func _swig_wrap_new_PairIntA() (base SwigcptrPairIntA) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_PairIntA, _swig_p) - return -} - -func NewPairIntA() (_swig_ret PairIntA) { - return _swig_wrap_new_PairIntA() -} - -var _wrap_delete_PairIntA unsafe.Pointer - -func _swig_wrap_delete_PairIntA(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_PairIntA, _swig_p) - return -} - -func DeletePairIntA(arg1 PairIntA) { - _swig_wrap_delete_PairIntA(arg1.Swigcptr()) -} - -type PairIntA interface { - Swigcptr() uintptr - SwigIsPairIntA() - SetFirst(arg2 int) - GetFirst() (_swig_ret int) - SetSecond(arg2 A) - GetSecond() (_swig_ret A) -} - -type SwigcptrMultimapIntA uintptr - -func (p SwigcptrMultimapIntA) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrMultimapIntA) SwigIsMultimapIntA() { -} - -var _wrap_MultimapIntA_typemap_test unsafe.Pointer - -func _swig_wrap_MultimapIntA_typemap_test(base SwigcptrMultimapIntA, _ uintptr) (_ SwigcptrA) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_MultimapIntA_typemap_test, _swig_p) - return -} - -func (arg1 SwigcptrMultimapIntA) Typemap_test(arg2 Standard_Pair_Sl_Standard_Multimap_Sl_int_Sc_A_Sg__iterator_Sc_Standard_Multimap_Sl_int_Sc_A_Sg__iterator_Sg_) (_swig_ret A) { - return _swig_wrap_MultimapIntA_typemap_test(arg1, arg2.Swigcptr()) -} - -var _wrap_MultimapIntA_make_dummy_pair unsafe.Pointer - -func _swig_wrap_MultimapIntA_make_dummy_pair(base SwigcptrMultimapIntA) (_ SwigcptrStandard_Pair_Sl_Standard_Multimap_Sl_int_Sc_A_Sg__iterator_Sc_Standard_Multimap_Sl_int_Sc_A_Sg__iterator_Sg_) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_MultimapIntA_make_dummy_pair, _swig_p) - return -} - -func (arg1 SwigcptrMultimapIntA) Make_dummy_pair() (_swig_ret Standard_Pair_Sl_Standard_Multimap_Sl_int_Sc_A_Sg__iterator_Sc_Standard_Multimap_Sl_int_Sc_A_Sg__iterator_Sg_) { - return _swig_wrap_MultimapIntA_make_dummy_pair(arg1) -} - -var _wrap_new_MultimapIntA unsafe.Pointer - -func _swig_wrap_new_MultimapIntA() (base SwigcptrMultimapIntA) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_MultimapIntA, _swig_p) - return -} - -func NewMultimapIntA() (_swig_ret MultimapIntA) { - return _swig_wrap_new_MultimapIntA() -} - -var _wrap_delete_MultimapIntA unsafe.Pointer - -func _swig_wrap_delete_MultimapIntA(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_MultimapIntA, _swig_p) - return -} - -func DeleteMultimapIntA(arg1 MultimapIntA) { - _swig_wrap_delete_MultimapIntA(arg1.Swigcptr()) -} - -type MultimapIntA interface { - Swigcptr() uintptr - SwigIsMultimapIntA() - Typemap_test(arg2 Standard_Pair_Sl_Standard_Multimap_Sl_int_Sc_A_Sg__iterator_Sc_Standard_Multimap_Sl_int_Sc_A_Sg__iterator_Sg_) (_swig_ret A) - Make_dummy_pair() (_swig_ret Standard_Pair_Sl_Standard_Multimap_Sl_int_Sc_A_Sg__iterator_Sc_Standard_Multimap_Sl_int_Sc_A_Sg__iterator_Sg_) -} - -type SwigcptrPairAInt uintptr - -func (p SwigcptrPairAInt) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrPairAInt) SwigIsPairAInt() { -} - -var _wrap_PairAInt_first_set unsafe.Pointer - -func _swig_wrap_PairAInt_first_set(base SwigcptrPairAInt, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_PairAInt_first_set, _swig_p) - return -} - -func (arg1 SwigcptrPairAInt) SetFirst(arg2 A) { - _swig_wrap_PairAInt_first_set(arg1, arg2.Swigcptr()) -} - -var _wrap_PairAInt_first_get unsafe.Pointer - -func _swig_wrap_PairAInt_first_get(base SwigcptrPairAInt) (_ SwigcptrA) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_PairAInt_first_get, _swig_p) - return -} - -func (arg1 SwigcptrPairAInt) GetFirst() (_swig_ret A) { - return _swig_wrap_PairAInt_first_get(arg1) -} - -var _wrap_PairAInt_second_set unsafe.Pointer - -func _swig_wrap_PairAInt_second_set(base SwigcptrPairAInt, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_PairAInt_second_set, _swig_p) - return -} - -func (arg1 SwigcptrPairAInt) SetSecond(arg2 int) { - _swig_wrap_PairAInt_second_set(arg1, arg2) -} - -var _wrap_PairAInt_second_get unsafe.Pointer - -func _swig_wrap_PairAInt_second_get(base SwigcptrPairAInt) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_PairAInt_second_get, _swig_p) - return -} - -func (arg1 SwigcptrPairAInt) GetSecond() (_swig_ret int) { - return _swig_wrap_PairAInt_second_get(arg1) -} - -var _wrap_new_PairAInt unsafe.Pointer - -func _swig_wrap_new_PairAInt() (base SwigcptrPairAInt) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_PairAInt, _swig_p) - return -} - -func NewPairAInt() (_swig_ret PairAInt) { - return _swig_wrap_new_PairAInt() -} - -var _wrap_delete_PairAInt unsafe.Pointer - -func _swig_wrap_delete_PairAInt(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_PairAInt, _swig_p) - return -} - -func DeletePairAInt(arg1 PairAInt) { - _swig_wrap_delete_PairAInt(arg1.Swigcptr()) -} - -type PairAInt interface { - Swigcptr() uintptr - SwigIsPairAInt() - SetFirst(arg2 A) - GetFirst() (_swig_ret A) - SetSecond(arg2 int) - GetSecond() (_swig_ret int) -} - -type SwigcptrMultimapAInt uintptr - -func (p SwigcptrMultimapAInt) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrMultimapAInt) SwigIsMultimapAInt() { -} - -var _wrap_MultimapAInt_typemap_test unsafe.Pointer - -func _swig_wrap_MultimapAInt_typemap_test(base SwigcptrMultimapAInt, _ uintptr) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_MultimapAInt_typemap_test, _swig_p) - return -} - -func (arg1 SwigcptrMultimapAInt) Typemap_test(arg2 Standard_Pair_Sl_Standard_Multimap_Sl_A_Sc_int_Sg__iterator_Sc_Standard_Multimap_Sl_A_Sc_int_Sg__iterator_Sg_) (_swig_ret int) { - return _swig_wrap_MultimapAInt_typemap_test(arg1, arg2.Swigcptr()) -} - -var _wrap_MultimapAInt_make_dummy_pair unsafe.Pointer - -func _swig_wrap_MultimapAInt_make_dummy_pair(base SwigcptrMultimapAInt) (_ SwigcptrStandard_Pair_Sl_Standard_Multimap_Sl_A_Sc_int_Sg__iterator_Sc_Standard_Multimap_Sl_A_Sc_int_Sg__iterator_Sg_) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_MultimapAInt_make_dummy_pair, _swig_p) - return -} - -func (arg1 SwigcptrMultimapAInt) Make_dummy_pair() (_swig_ret Standard_Pair_Sl_Standard_Multimap_Sl_A_Sc_int_Sg__iterator_Sc_Standard_Multimap_Sl_A_Sc_int_Sg__iterator_Sg_) { - return _swig_wrap_MultimapAInt_make_dummy_pair(arg1) -} - -var _wrap_new_MultimapAInt unsafe.Pointer - -func _swig_wrap_new_MultimapAInt() (base SwigcptrMultimapAInt) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_MultimapAInt, _swig_p) - return -} - -func NewMultimapAInt() (_swig_ret MultimapAInt) { - return _swig_wrap_new_MultimapAInt() -} - -var _wrap_delete_MultimapAInt unsafe.Pointer - -func _swig_wrap_delete_MultimapAInt(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_MultimapAInt, _swig_p) - return -} - -func DeleteMultimapAInt(arg1 MultimapAInt) { - _swig_wrap_delete_MultimapAInt(arg1.Swigcptr()) -} - -type MultimapAInt interface { - Swigcptr() uintptr - SwigIsMultimapAInt() - Typemap_test(arg2 Standard_Pair_Sl_Standard_Multimap_Sl_A_Sc_int_Sg__iterator_Sc_Standard_Multimap_Sl_A_Sc_int_Sg__iterator_Sg_) (_swig_ret int) - Make_dummy_pair() (_swig_ret Standard_Pair_Sl_Standard_Multimap_Sl_A_Sc_int_Sg__iterator_Sc_Standard_Multimap_Sl_A_Sc_int_Sg__iterator_Sg_) -} - -var _wrap_typedef_test1 unsafe.Pointer - -func _swig_wrap_typedef_test1(base uintptr) (_ SwigcptrA) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_typedef_test1, _swig_p) - return -} - -func Typedef_test1(arg1 Standard_Pair_Sl_Standard_Multimap_Sl_int_Sc_A_Sg__iterator_Sc_Standard_Multimap_Sl_int_Sc_A_Sg__iterator_Sg_) (_swig_ret A) { - return _swig_wrap_typedef_test1(arg1.Swigcptr()) -} - -var _wrap_typedef_test2 unsafe.Pointer - -func _swig_wrap_typedef_test2(base uintptr) (_ SwigcptrA) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_typedef_test2, _swig_p) - return -} - -func Typedef_test2(arg1 Standard_Pair_Sl_Standard_Multimap_Sl_int_Sc_A_Sg__iterator_Sc_Standard_Multimap_Sl_int_Sc_A_Sg__iterator_Sg_) (_swig_ret A) { - return _swig_wrap_typedef_test2(arg1.Swigcptr()) -} - -var _wrap_typedef_test3 unsafe.Pointer - -func _swig_wrap_typedef_test3(base uintptr) (_ SwigcptrA) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_typedef_test3, _swig_p) - return -} - -func Typedef_test3(arg1 Standard_Pair_Sl_Standard_Multimap_Sl_int_Sc_A_Sg__iterator_Sc_Standard_Multimap_Sl_int_Sc_A_Sg__iterator_Sg_) (_swig_ret A) { - return _swig_wrap_typedef_test3(arg1.Swigcptr()) -} - -var _wrap_typedef_test4 unsafe.Pointer - -func _swig_wrap_typedef_test4(base uintptr) (_ SwigcptrA) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_typedef_test4, _swig_p) - return -} - -func Typedef_test4(arg1 Standard_Pair_Sl_Standard_Multimap_Sl_int_Sc_A_Sg__iterator_Sc_Standard_Multimap_Sl_int_Sc_A_Sg__iterator_Sg_) (_swig_ret A) { - return _swig_wrap_typedef_test4(arg1.Swigcptr()) -} - -var _wrap_typedef_test5 unsafe.Pointer - -func _swig_wrap_typedef_test5(base uintptr) (_ SwigcptrA) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_typedef_test5, _swig_p) - return -} - -func Typedef_test5(arg1 Standard_Pair_Sl_Standard_Multimap_Sl_int_Sc_A_Sg__iterator_Sc_Standard_Multimap_Sl_int_Sc_A_Sg__iterator_Sg_) (_swig_ret A) { - return _swig_wrap_typedef_test5(arg1.Swigcptr()) -} - -var _wrap_typedef_test6 unsafe.Pointer - -func _swig_wrap_typedef_test6(base uintptr) (_ SwigcptrA) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_typedef_test6, _swig_p) - return -} - -func Typedef_test6(arg1 Standard_Pair_Sl_Standard_Multimap_Sl_int_Sc_A_Sg__iterator_Sc_Standard_Multimap_Sl_int_Sc_A_Sg__iterator_Sg_) (_swig_ret A) { - return _swig_wrap_typedef_test6(arg1.Swigcptr()) -} - - -type SwigcptrStandard_Pair_Sl_Standard_Multimap_Sl_int_Sc_A_Sg__iterator_Sc_Standard_Multimap_Sl_int_Sc_A_Sg__iterator_Sg_ uintptr -type Standard_Pair_Sl_Standard_Multimap_Sl_int_Sc_A_Sg__iterator_Sc_Standard_Multimap_Sl_int_Sc_A_Sg__iterator_Sg_ interface { - Swigcptr() uintptr; -} -func (p SwigcptrStandard_Pair_Sl_Standard_Multimap_Sl_int_Sc_A_Sg__iterator_Sc_Standard_Multimap_Sl_int_Sc_A_Sg__iterator_Sg_) Swigcptr() uintptr { - return uintptr(p) -} - -type SwigcptrStandard_Pair_Sl_Standard_Multimap_Sl_A_Sc_int_Sg__iterator_Sc_Standard_Multimap_Sl_A_Sc_int_Sg__iterator_Sg_ uintptr -type Standard_Pair_Sl_Standard_Multimap_Sl_A_Sc_int_Sg__iterator_Sc_Standard_Multimap_Sl_A_Sc_int_Sg__iterator_Sg_ interface { - Swigcptr() uintptr; -} -func (p SwigcptrStandard_Pair_Sl_Standard_Multimap_Sl_A_Sc_int_Sg__iterator_Sc_Standard_Multimap_Sl_A_Sc_int_Sg__iterator_Sg_) Swigcptr() uintptr { - return uintptr(p) -} - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/template_typemaps_typedef2.go b/Examples/test-suite/go/template_typemaps_typedef2.go deleted file mode 100644 index 20f60198c..000000000 --- a/Examples/test-suite/go/template_typemaps_typedef2.go +++ /dev/null @@ -1,520 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../template_typemaps_typedef2.i - -package template_typemaps_typedef2 - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrA uintptr - -func (p SwigcptrA) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrA) SwigIsA() { -} - -var _wrap_A_val_set unsafe.Pointer - -func _swig_wrap_A_val_set(base SwigcptrA, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_A_val_set, _swig_p) - return -} - -func (arg1 SwigcptrA) SetVal(arg2 int) { - _swig_wrap_A_val_set(arg1, arg2) -} - -var _wrap_A_val_get unsafe.Pointer - -func _swig_wrap_A_val_get(base SwigcptrA) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_A_val_get, _swig_p) - return -} - -func (arg1 SwigcptrA) GetVal() (_swig_ret int) { - return _swig_wrap_A_val_get(arg1) -} - -var _wrap_new_A__SWIG_0 unsafe.Pointer - -func _swig_wrap_new_A__SWIG_0(base int) (_ SwigcptrA) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_A__SWIG_0, _swig_p) - return -} - -func NewA__SWIG_0(arg1 int) (_swig_ret A) { - return _swig_wrap_new_A__SWIG_0(arg1) -} - -var _wrap_new_A__SWIG_1 unsafe.Pointer - -func _swig_wrap_new_A__SWIG_1() (base SwigcptrA) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_A__SWIG_1, _swig_p) - return -} - -func NewA__SWIG_1() (_swig_ret A) { - return _swig_wrap_new_A__SWIG_1() -} - -func NewA(a ...interface{}) A { - argc := len(a) - if argc == 0 { - return NewA__SWIG_1() - } - if argc == 1 { - return NewA__SWIG_0(a[0].(int)) - } - panic("No match for overloaded function call") -} - -var _wrap_delete_A unsafe.Pointer - -func _swig_wrap_delete_A(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_A, _swig_p) - return -} - -func DeleteA(arg1 A) { - _swig_wrap_delete_A(arg1.Swigcptr()) -} - -type A interface { - Swigcptr() uintptr - SwigIsA() - SetVal(arg2 int) - GetVal() (_swig_ret int) -} - -type SwigcptrPairIntA uintptr - -func (p SwigcptrPairIntA) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrPairIntA) SwigIsPairIntA() { -} - -var _wrap_PairIntA_first_set unsafe.Pointer - -func _swig_wrap_PairIntA_first_set(base SwigcptrPairIntA, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_PairIntA_first_set, _swig_p) - return -} - -func (arg1 SwigcptrPairIntA) SetFirst(arg2 int) { - _swig_wrap_PairIntA_first_set(arg1, arg2) -} - -var _wrap_PairIntA_first_get unsafe.Pointer - -func _swig_wrap_PairIntA_first_get(base SwigcptrPairIntA) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_PairIntA_first_get, _swig_p) - return -} - -func (arg1 SwigcptrPairIntA) GetFirst() (_swig_ret int) { - return _swig_wrap_PairIntA_first_get(arg1) -} - -var _wrap_PairIntA_second_set unsafe.Pointer - -func _swig_wrap_PairIntA_second_set(base SwigcptrPairIntA, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_PairIntA_second_set, _swig_p) - return -} - -func (arg1 SwigcptrPairIntA) SetSecond(arg2 A) { - _swig_wrap_PairIntA_second_set(arg1, arg2.Swigcptr()) -} - -var _wrap_PairIntA_second_get unsafe.Pointer - -func _swig_wrap_PairIntA_second_get(base SwigcptrPairIntA) (_ SwigcptrA) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_PairIntA_second_get, _swig_p) - return -} - -func (arg1 SwigcptrPairIntA) GetSecond() (_swig_ret A) { - return _swig_wrap_PairIntA_second_get(arg1) -} - -var _wrap_new_PairIntA unsafe.Pointer - -func _swig_wrap_new_PairIntA() (base SwigcptrPairIntA) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_PairIntA, _swig_p) - return -} - -func NewPairIntA() (_swig_ret PairIntA) { - return _swig_wrap_new_PairIntA() -} - -var _wrap_delete_PairIntA unsafe.Pointer - -func _swig_wrap_delete_PairIntA(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_PairIntA, _swig_p) - return -} - -func DeletePairIntA(arg1 PairIntA) { - _swig_wrap_delete_PairIntA(arg1.Swigcptr()) -} - -type PairIntA interface { - Swigcptr() uintptr - SwigIsPairIntA() - SetFirst(arg2 int) - GetFirst() (_swig_ret int) - SetSecond(arg2 A) - GetSecond() (_swig_ret A) -} - -type SwigcptrMultimapIntA uintptr - -func (p SwigcptrMultimapIntA) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrMultimapIntA) SwigIsMultimapIntA() { -} - -var _wrap_MultimapIntA_typemap_test unsafe.Pointer - -func _swig_wrap_MultimapIntA_typemap_test(base SwigcptrMultimapIntA, _ uintptr) (_ SwigcptrA) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_MultimapIntA_typemap_test, _swig_p) - return -} - -func (arg1 SwigcptrMultimapIntA) Typemap_test(arg2 Standard_Pair_Sl_Standard_Multimap_Sl_int_Sc_Space_AB_Sg__iterator_Sc_Standard_Multimap_Sl_int_Sc_Space_AB_Sg__iterator_Sg_) (_swig_ret A) { - return _swig_wrap_MultimapIntA_typemap_test(arg1, arg2.Swigcptr()) -} - -var _wrap_MultimapIntA_make_dummy_pair unsafe.Pointer - -func _swig_wrap_MultimapIntA_make_dummy_pair(base SwigcptrMultimapIntA) (_ SwigcptrStandard_Pair_Sl_Standard_Multimap_Sl_int_Sc_Space_AB_Sg__iterator_Sc_Standard_Multimap_Sl_int_Sc_Space_AB_Sg__iterator_Sg_) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_MultimapIntA_make_dummy_pair, _swig_p) - return -} - -func (arg1 SwigcptrMultimapIntA) Make_dummy_pair() (_swig_ret Standard_Pair_Sl_Standard_Multimap_Sl_int_Sc_Space_AB_Sg__iterator_Sc_Standard_Multimap_Sl_int_Sc_Space_AB_Sg__iterator_Sg_) { - return _swig_wrap_MultimapIntA_make_dummy_pair(arg1) -} - -var _wrap_new_MultimapIntA unsafe.Pointer - -func _swig_wrap_new_MultimapIntA() (base SwigcptrMultimapIntA) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_MultimapIntA, _swig_p) - return -} - -func NewMultimapIntA() (_swig_ret MultimapIntA) { - return _swig_wrap_new_MultimapIntA() -} - -var _wrap_delete_MultimapIntA unsafe.Pointer - -func _swig_wrap_delete_MultimapIntA(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_MultimapIntA, _swig_p) - return -} - -func DeleteMultimapIntA(arg1 MultimapIntA) { - _swig_wrap_delete_MultimapIntA(arg1.Swigcptr()) -} - -type MultimapIntA interface { - Swigcptr() uintptr - SwigIsMultimapIntA() - Typemap_test(arg2 Standard_Pair_Sl_Standard_Multimap_Sl_int_Sc_Space_AB_Sg__iterator_Sc_Standard_Multimap_Sl_int_Sc_Space_AB_Sg__iterator_Sg_) (_swig_ret A) - Make_dummy_pair() (_swig_ret Standard_Pair_Sl_Standard_Multimap_Sl_int_Sc_Space_AB_Sg__iterator_Sc_Standard_Multimap_Sl_int_Sc_Space_AB_Sg__iterator_Sg_) -} - -type SwigcptrPairAInt uintptr - -func (p SwigcptrPairAInt) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrPairAInt) SwigIsPairAInt() { -} - -var _wrap_PairAInt_first_set unsafe.Pointer - -func _swig_wrap_PairAInt_first_set(base SwigcptrPairAInt, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_PairAInt_first_set, _swig_p) - return -} - -func (arg1 SwigcptrPairAInt) SetFirst(arg2 A) { - _swig_wrap_PairAInt_first_set(arg1, arg2.Swigcptr()) -} - -var _wrap_PairAInt_first_get unsafe.Pointer - -func _swig_wrap_PairAInt_first_get(base SwigcptrPairAInt) (_ SwigcptrA) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_PairAInt_first_get, _swig_p) - return -} - -func (arg1 SwigcptrPairAInt) GetFirst() (_swig_ret A) { - return _swig_wrap_PairAInt_first_get(arg1) -} - -var _wrap_PairAInt_second_set unsafe.Pointer - -func _swig_wrap_PairAInt_second_set(base SwigcptrPairAInt, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_PairAInt_second_set, _swig_p) - return -} - -func (arg1 SwigcptrPairAInt) SetSecond(arg2 int) { - _swig_wrap_PairAInt_second_set(arg1, arg2) -} - -var _wrap_PairAInt_second_get unsafe.Pointer - -func _swig_wrap_PairAInt_second_get(base SwigcptrPairAInt) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_PairAInt_second_get, _swig_p) - return -} - -func (arg1 SwigcptrPairAInt) GetSecond() (_swig_ret int) { - return _swig_wrap_PairAInt_second_get(arg1) -} - -var _wrap_new_PairAInt unsafe.Pointer - -func _swig_wrap_new_PairAInt() (base SwigcptrPairAInt) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_PairAInt, _swig_p) - return -} - -func NewPairAInt() (_swig_ret PairAInt) { - return _swig_wrap_new_PairAInt() -} - -var _wrap_delete_PairAInt unsafe.Pointer - -func _swig_wrap_delete_PairAInt(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_PairAInt, _swig_p) - return -} - -func DeletePairAInt(arg1 PairAInt) { - _swig_wrap_delete_PairAInt(arg1.Swigcptr()) -} - -type PairAInt interface { - Swigcptr() uintptr - SwigIsPairAInt() - SetFirst(arg2 A) - GetFirst() (_swig_ret A) - SetSecond(arg2 int) - GetSecond() (_swig_ret int) -} - -type SwigcptrMultimapAInt uintptr - -func (p SwigcptrMultimapAInt) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrMultimapAInt) SwigIsMultimapAInt() { -} - -var _wrap_MultimapAInt_typemap_test unsafe.Pointer - -func _swig_wrap_MultimapAInt_typemap_test(base SwigcptrMultimapAInt, _ uintptr) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_MultimapAInt_typemap_test, _swig_p) - return -} - -func (arg1 SwigcptrMultimapAInt) Typemap_test(arg2 Standard_Pair_Sl_Standard_Multimap_Sl_Space_AB_Sc_int_Sg__iterator_Sc_Standard_Multimap_Sl_Space_AB_Sc_int_Sg__iterator_Sg_) (_swig_ret int) { - return _swig_wrap_MultimapAInt_typemap_test(arg1, arg2.Swigcptr()) -} - -var _wrap_MultimapAInt_make_dummy_pair unsafe.Pointer - -func _swig_wrap_MultimapAInt_make_dummy_pair(base SwigcptrMultimapAInt) (_ SwigcptrStandard_Pair_Sl_Standard_Multimap_Sl_Space_AB_Sc_int_Sg__iterator_Sc_Standard_Multimap_Sl_Space_AB_Sc_int_Sg__iterator_Sg_) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_MultimapAInt_make_dummy_pair, _swig_p) - return -} - -func (arg1 SwigcptrMultimapAInt) Make_dummy_pair() (_swig_ret Standard_Pair_Sl_Standard_Multimap_Sl_Space_AB_Sc_int_Sg__iterator_Sc_Standard_Multimap_Sl_Space_AB_Sc_int_Sg__iterator_Sg_) { - return _swig_wrap_MultimapAInt_make_dummy_pair(arg1) -} - -var _wrap_new_MultimapAInt unsafe.Pointer - -func _swig_wrap_new_MultimapAInt() (base SwigcptrMultimapAInt) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_MultimapAInt, _swig_p) - return -} - -func NewMultimapAInt() (_swig_ret MultimapAInt) { - return _swig_wrap_new_MultimapAInt() -} - -var _wrap_delete_MultimapAInt unsafe.Pointer - -func _swig_wrap_delete_MultimapAInt(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_MultimapAInt, _swig_p) - return -} - -func DeleteMultimapAInt(arg1 MultimapAInt) { - _swig_wrap_delete_MultimapAInt(arg1.Swigcptr()) -} - -type MultimapAInt interface { - Swigcptr() uintptr - SwigIsMultimapAInt() - Typemap_test(arg2 Standard_Pair_Sl_Standard_Multimap_Sl_Space_AB_Sc_int_Sg__iterator_Sc_Standard_Multimap_Sl_Space_AB_Sc_int_Sg__iterator_Sg_) (_swig_ret int) - Make_dummy_pair() (_swig_ret Standard_Pair_Sl_Standard_Multimap_Sl_Space_AB_Sc_int_Sg__iterator_Sc_Standard_Multimap_Sl_Space_AB_Sc_int_Sg__iterator_Sg_) -} - -var _wrap_typedef_test1 unsafe.Pointer - -func _swig_wrap_typedef_test1(base uintptr) (_ SwigcptrA) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_typedef_test1, _swig_p) - return -} - -func Typedef_test1(arg1 Standard_Pair_Sl_Standard_Multimap_Sl_int_Sc_Space_AB_Sg__iterator_Sc_Standard_Multimap_Sl_int_Sc_Space_AB_Sg__iterator_Sg_) (_swig_ret A) { - return _swig_wrap_typedef_test1(arg1.Swigcptr()) -} - -var _wrap_typedef_test2 unsafe.Pointer - -func _swig_wrap_typedef_test2(base uintptr) (_ SwigcptrA) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_typedef_test2, _swig_p) - return -} - -func Typedef_test2(arg1 Standard_Pair_Sl_Standard_Multimap_Sl_int_Sc_Space_AB_Sg__iterator_Sc_Standard_Multimap_Sl_int_Sc_Space_AB_Sg__iterator_Sg_) (_swig_ret A) { - return _swig_wrap_typedef_test2(arg1.Swigcptr()) -} - -var _wrap_typedef_test3 unsafe.Pointer - -func _swig_wrap_typedef_test3(base uintptr) (_ SwigcptrA) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_typedef_test3, _swig_p) - return -} - -func Typedef_test3(arg1 Standard_Pair_Sl_Standard_Multimap_Sl_int_Sc_Space_AB_Sg__iterator_Sc_Standard_Multimap_Sl_int_Sc_Space_AB_Sg__iterator_Sg_) (_swig_ret A) { - return _swig_wrap_typedef_test3(arg1.Swigcptr()) -} - -var _wrap_typedef_test4 unsafe.Pointer - -func _swig_wrap_typedef_test4(base uintptr) (_ SwigcptrA) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_typedef_test4, _swig_p) - return -} - -func Typedef_test4(arg1 Standard_Pair_Sl_Standard_Multimap_Sl_int_Sc_Space_AB_Sg__iterator_Sc_Standard_Multimap_Sl_int_Sc_Space_AB_Sg__iterator_Sg_) (_swig_ret A) { - return _swig_wrap_typedef_test4(arg1.Swigcptr()) -} - -var _wrap_typedef_test5 unsafe.Pointer - -func _swig_wrap_typedef_test5(base uintptr) (_ SwigcptrA) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_typedef_test5, _swig_p) - return -} - -func Typedef_test5(arg1 Standard_Pair_Sl_Standard_Multimap_Sl_int_Sc_Space_AB_Sg__iterator_Sc_Standard_Multimap_Sl_int_Sc_Space_AB_Sg__iterator_Sg_) (_swig_ret A) { - return _swig_wrap_typedef_test5(arg1.Swigcptr()) -} - -var _wrap_typedef_test6 unsafe.Pointer - -func _swig_wrap_typedef_test6(base uintptr) (_ SwigcptrA) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_typedef_test6, _swig_p) - return -} - -func Typedef_test6(arg1 Standard_Pair_Sl_Standard_Multimap_Sl_int_Sc_Space_AB_Sg__iterator_Sc_Standard_Multimap_Sl_int_Sc_Space_AB_Sg__iterator_Sg_) (_swig_ret A) { - return _swig_wrap_typedef_test6(arg1.Swigcptr()) -} - - -type SwigcptrStandard_Pair_Sl_Standard_Multimap_Sl_int_Sc_Space_AB_Sg__iterator_Sc_Standard_Multimap_Sl_int_Sc_Space_AB_Sg__iterator_Sg_ uintptr -type Standard_Pair_Sl_Standard_Multimap_Sl_int_Sc_Space_AB_Sg__iterator_Sc_Standard_Multimap_Sl_int_Sc_Space_AB_Sg__iterator_Sg_ interface { - Swigcptr() uintptr; -} -func (p SwigcptrStandard_Pair_Sl_Standard_Multimap_Sl_int_Sc_Space_AB_Sg__iterator_Sc_Standard_Multimap_Sl_int_Sc_Space_AB_Sg__iterator_Sg_) Swigcptr() uintptr { - return uintptr(p) -} - -type SwigcptrStandard_Pair_Sl_Standard_Multimap_Sl_Space_AB_Sc_int_Sg__iterator_Sc_Standard_Multimap_Sl_Space_AB_Sc_int_Sg__iterator_Sg_ uintptr -type Standard_Pair_Sl_Standard_Multimap_Sl_Space_AB_Sc_int_Sg__iterator_Sc_Standard_Multimap_Sl_Space_AB_Sc_int_Sg__iterator_Sg_ interface { - Swigcptr() uintptr; -} -func (p SwigcptrStandard_Pair_Sl_Standard_Multimap_Sl_Space_AB_Sc_int_Sg__iterator_Sc_Standard_Multimap_Sl_Space_AB_Sc_int_Sg__iterator_Sg_) Swigcptr() uintptr { - return uintptr(p) -} - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/template_using.go b/Examples/test-suite/go/template_using.go deleted file mode 100644 index 053ab6900..000000000 --- a/Examples/test-suite/go/template_using.go +++ /dev/null @@ -1,89 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../template_using.i - -package template_using - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -var _wrap_maxint unsafe.Pointer - -func Maxint(arg1 int, arg2 int) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_maxint, _swig_p) - return -} -type SwigcptrFoofloat uintptr - -func (p SwigcptrFoofloat) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrFoofloat) SwigIsFoofloat() { -} - -var _wrap_new_Foofloat unsafe.Pointer - -func _swig_wrap_new_Foofloat() (base SwigcptrFoofloat) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Foofloat, _swig_p) - return -} - -func NewFoofloat() (_swig_ret Foofloat) { - return _swig_wrap_new_Foofloat() -} - -var _wrap_delete_Foofloat unsafe.Pointer - -func _swig_wrap_delete_Foofloat(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Foofloat, _swig_p) - return -} - -func DeleteFoofloat(arg1 Foofloat) { - _swig_wrap_delete_Foofloat(arg1.Swigcptr()) -} - -type Foofloat interface { - Swigcptr() uintptr - SwigIsFoofloat() -} - -var _wrap_maxfloat unsafe.Pointer - -func Maxfloat(arg1 float32, arg2 float32) (_swig_ret float32) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_maxfloat, _swig_p) - return -} - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/template_using_directive_and_declaration_forward.go b/Examples/test-suite/go/template_using_directive_and_declaration_forward.go deleted file mode 100644 index aab450d14..000000000 --- a/Examples/test-suite/go/template_using_directive_and_declaration_forward.go +++ /dev/null @@ -1,653 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../template_using_directive_and_declaration_forward.i - -package template_using_directive_and_declaration_forward - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -var _wrap_useit1 unsafe.Pointer - -func _swig_wrap_useit1(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_useit1, _swig_p) - return -} - -func Useit1(arg1 Thing1Int) { - _swig_wrap_useit1(arg1.Swigcptr()) -} - -var _wrap_useit1a unsafe.Pointer - -func _swig_wrap_useit1a(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_useit1a, _swig_p) - return -} - -func Useit1a(arg1 Thing1Int) { - _swig_wrap_useit1a(arg1.Swigcptr()) -} - -var _wrap_useit1b unsafe.Pointer - -func _swig_wrap_useit1b(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_useit1b, _swig_p) - return -} - -func Useit1b(arg1 Thing1Int) { - _swig_wrap_useit1b(arg1.Swigcptr()) -} - -var _wrap_useit1c unsafe.Pointer - -func _swig_wrap_useit1c(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_useit1c, _swig_p) - return -} - -func Useit1c(arg1 Thing1Int) { - _swig_wrap_useit1c(arg1.Swigcptr()) -} - -var _wrap_useit2 unsafe.Pointer - -func _swig_wrap_useit2(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_useit2, _swig_p) - return -} - -func Useit2(arg1 Outer2_Space2_Thing2_Sl_int_Sg_) { - _swig_wrap_useit2(arg1.Swigcptr()) -} - -var _wrap_useit2a unsafe.Pointer - -func _swig_wrap_useit2a(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_useit2a, _swig_p) - return -} - -func Useit2a(arg1 Thing2Int) { - _swig_wrap_useit2a(arg1.Swigcptr()) -} - -var _wrap_useit2b unsafe.Pointer - -func _swig_wrap_useit2b(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_useit2b, _swig_p) - return -} - -func Useit2b(arg1 Thing2Int) { - _swig_wrap_useit2b(arg1.Swigcptr()) -} - -var _wrap_useit2c unsafe.Pointer - -func _swig_wrap_useit2c(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_useit2c, _swig_p) - return -} - -func Useit2c(arg1 Thing2Int) { - _swig_wrap_useit2c(arg1.Swigcptr()) -} - -var _wrap_useit2d unsafe.Pointer - -func _swig_wrap_useit2d(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_useit2d, _swig_p) - return -} - -func Useit2d(arg1 Thing2Int) { - _swig_wrap_useit2d(arg1.Swigcptr()) -} - -var _wrap_useit3 unsafe.Pointer - -func _swig_wrap_useit3(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_useit3, _swig_p) - return -} - -func Useit3(arg1 Outer3_Space3_Middle3_Thing3_Sl_int_Sg_) { - _swig_wrap_useit3(arg1.Swigcptr()) -} - -var _wrap_useit3a unsafe.Pointer - -func _swig_wrap_useit3a(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_useit3a, _swig_p) - return -} - -func Useit3a(arg1 Thing3Int) { - _swig_wrap_useit3a(arg1.Swigcptr()) -} - -var _wrap_useit3b unsafe.Pointer - -func _swig_wrap_useit3b(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_useit3b, _swig_p) - return -} - -func Useit3b(arg1 Thing3Int) { - _swig_wrap_useit3b(arg1.Swigcptr()) -} - -var _wrap_useit3c unsafe.Pointer - -func _swig_wrap_useit3c(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_useit3c, _swig_p) - return -} - -func Useit3c(arg1 Thing3Int) { - _swig_wrap_useit3c(arg1.Swigcptr()) -} - -var _wrap_useit3d unsafe.Pointer - -func _swig_wrap_useit3d(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_useit3d, _swig_p) - return -} - -func Useit3d(arg1 Thing3Int) { - _swig_wrap_useit3d(arg1.Swigcptr()) -} - -var _wrap_useit4 unsafe.Pointer - -func _swig_wrap_useit4(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_useit4, _swig_p) - return -} - -func Useit4(arg1 Outer4_Space4_Middle4_Thing4_Sl_int_Sg_) { - _swig_wrap_useit4(arg1.Swigcptr()) -} - -var _wrap_useit4a unsafe.Pointer - -func _swig_wrap_useit4a(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_useit4a, _swig_p) - return -} - -func Useit4a(arg1 Thing4Int) { - _swig_wrap_useit4a(arg1.Swigcptr()) -} - -var _wrap_useit4b unsafe.Pointer - -func _swig_wrap_useit4b(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_useit4b, _swig_p) - return -} - -func Useit4b(arg1 Thing4Int) { - _swig_wrap_useit4b(arg1.Swigcptr()) -} - -var _wrap_useit4c unsafe.Pointer - -func _swig_wrap_useit4c(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_useit4c, _swig_p) - return -} - -func Useit4c(arg1 Thing4Int) { - _swig_wrap_useit4c(arg1.Swigcptr()) -} - -var _wrap_useit4d unsafe.Pointer - -func _swig_wrap_useit4d(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_useit4d, _swig_p) - return -} - -func Useit4d(arg1 Thing4Int) { - _swig_wrap_useit4d(arg1.Swigcptr()) -} - -var _wrap_useit5 unsafe.Pointer - -func _swig_wrap_useit5(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_useit5, _swig_p) - return -} - -func Useit5(arg1 Outer5_Space5_Middle5_More5_Thing5_Sl_int_Sg_) { - _swig_wrap_useit5(arg1.Swigcptr()) -} - -var _wrap_useit5a unsafe.Pointer - -func _swig_wrap_useit5a(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_useit5a, _swig_p) - return -} - -func Useit5a(arg1 Thing5Int) { - _swig_wrap_useit5a(arg1.Swigcptr()) -} - -var _wrap_useit5b unsafe.Pointer - -func _swig_wrap_useit5b(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_useit5b, _swig_p) - return -} - -func Useit5b(arg1 Thing5Int) { - _swig_wrap_useit5b(arg1.Swigcptr()) -} - -var _wrap_useit5c unsafe.Pointer - -func _swig_wrap_useit5c(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_useit5c, _swig_p) - return -} - -func Useit5c(arg1 Thing5Int) { - _swig_wrap_useit5c(arg1.Swigcptr()) -} - -var _wrap_useit5d unsafe.Pointer - -func _swig_wrap_useit5d(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_useit5d, _swig_p) - return -} - -func Useit5d(arg1 Thing5Int) { - _swig_wrap_useit5d(arg1.Swigcptr()) -} - -var _wrap_useit7 unsafe.Pointer - -func _swig_wrap_useit7(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_useit7, _swig_p) - return -} - -func Useit7(arg1 Outer7_Space7_Middle7_Thing7_Sl_int_Sg_) { - _swig_wrap_useit7(arg1.Swigcptr()) -} - -var _wrap_useit7a unsafe.Pointer - -func _swig_wrap_useit7a(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_useit7a, _swig_p) - return -} - -func Useit7a(arg1 Thing7Int) { - _swig_wrap_useit7a(arg1.Swigcptr()) -} - -var _wrap_useit7b unsafe.Pointer - -func _swig_wrap_useit7b(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_useit7b, _swig_p) - return -} - -func Useit7b(arg1 Thing7Int) { - _swig_wrap_useit7b(arg1.Swigcptr()) -} - -var _wrap_useit7c unsafe.Pointer - -func _swig_wrap_useit7c(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_useit7c, _swig_p) - return -} - -func Useit7c(arg1 Thing7Int) { - _swig_wrap_useit7c(arg1.Swigcptr()) -} - -var _wrap_useit7d unsafe.Pointer - -func _swig_wrap_useit7d(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_useit7d, _swig_p) - return -} - -func Useit7d(arg1 Thing7Int) { - _swig_wrap_useit7d(arg1.Swigcptr()) -} - -type SwigcptrThing1Int uintptr - -func (p SwigcptrThing1Int) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrThing1Int) SwigIsThing1Int() { -} - -var _wrap_new_Thing1Int unsafe.Pointer - -func _swig_wrap_new_Thing1Int() (base SwigcptrThing1Int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Thing1Int, _swig_p) - return -} - -func NewThing1Int() (_swig_ret Thing1Int) { - return _swig_wrap_new_Thing1Int() -} - -var _wrap_delete_Thing1Int unsafe.Pointer - -func _swig_wrap_delete_Thing1Int(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Thing1Int, _swig_p) - return -} - -func DeleteThing1Int(arg1 Thing1Int) { - _swig_wrap_delete_Thing1Int(arg1.Swigcptr()) -} - -type Thing1Int interface { - Swigcptr() uintptr - SwigIsThing1Int() -} - -type SwigcptrThing2Int uintptr - -func (p SwigcptrThing2Int) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrThing2Int) SwigIsThing2Int() { -} - -var _wrap_new_Thing2Int unsafe.Pointer - -func _swig_wrap_new_Thing2Int() (base SwigcptrThing2Int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Thing2Int, _swig_p) - return -} - -func NewThing2Int() (_swig_ret Thing2Int) { - return _swig_wrap_new_Thing2Int() -} - -var _wrap_delete_Thing2Int unsafe.Pointer - -func _swig_wrap_delete_Thing2Int(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Thing2Int, _swig_p) - return -} - -func DeleteThing2Int(arg1 Thing2Int) { - _swig_wrap_delete_Thing2Int(arg1.Swigcptr()) -} - -type Thing2Int interface { - Swigcptr() uintptr - SwigIsThing2Int() -} - -type SwigcptrThing3Int uintptr - -func (p SwigcptrThing3Int) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrThing3Int) SwigIsThing3Int() { -} - -var _wrap_new_Thing3Int unsafe.Pointer - -func _swig_wrap_new_Thing3Int() (base SwigcptrThing3Int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Thing3Int, _swig_p) - return -} - -func NewThing3Int() (_swig_ret Thing3Int) { - return _swig_wrap_new_Thing3Int() -} - -var _wrap_delete_Thing3Int unsafe.Pointer - -func _swig_wrap_delete_Thing3Int(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Thing3Int, _swig_p) - return -} - -func DeleteThing3Int(arg1 Thing3Int) { - _swig_wrap_delete_Thing3Int(arg1.Swigcptr()) -} - -type Thing3Int interface { - Swigcptr() uintptr - SwigIsThing3Int() -} - -type SwigcptrThing4Int uintptr - -func (p SwigcptrThing4Int) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrThing4Int) SwigIsThing4Int() { -} - -var _wrap_new_Thing4Int unsafe.Pointer - -func _swig_wrap_new_Thing4Int() (base SwigcptrThing4Int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Thing4Int, _swig_p) - return -} - -func NewThing4Int() (_swig_ret Thing4Int) { - return _swig_wrap_new_Thing4Int() -} - -var _wrap_delete_Thing4Int unsafe.Pointer - -func _swig_wrap_delete_Thing4Int(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Thing4Int, _swig_p) - return -} - -func DeleteThing4Int(arg1 Thing4Int) { - _swig_wrap_delete_Thing4Int(arg1.Swigcptr()) -} - -type Thing4Int interface { - Swigcptr() uintptr - SwigIsThing4Int() -} - -type SwigcptrThing5Int uintptr - -func (p SwigcptrThing5Int) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrThing5Int) SwigIsThing5Int() { -} - -var _wrap_new_Thing5Int unsafe.Pointer - -func _swig_wrap_new_Thing5Int() (base SwigcptrThing5Int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Thing5Int, _swig_p) - return -} - -func NewThing5Int() (_swig_ret Thing5Int) { - return _swig_wrap_new_Thing5Int() -} - -var _wrap_delete_Thing5Int unsafe.Pointer - -func _swig_wrap_delete_Thing5Int(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Thing5Int, _swig_p) - return -} - -func DeleteThing5Int(arg1 Thing5Int) { - _swig_wrap_delete_Thing5Int(arg1.Swigcptr()) -} - -type Thing5Int interface { - Swigcptr() uintptr - SwigIsThing5Int() -} - -type SwigcptrThing7Int uintptr - -func (p SwigcptrThing7Int) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrThing7Int) SwigIsThing7Int() { -} - -var _wrap_new_Thing7Int unsafe.Pointer - -func _swig_wrap_new_Thing7Int() (base SwigcptrThing7Int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Thing7Int, _swig_p) - return -} - -func NewThing7Int() (_swig_ret Thing7Int) { - return _swig_wrap_new_Thing7Int() -} - -var _wrap_delete_Thing7Int unsafe.Pointer - -func _swig_wrap_delete_Thing7Int(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Thing7Int, _swig_p) - return -} - -func DeleteThing7Int(arg1 Thing7Int) { - _swig_wrap_delete_Thing7Int(arg1.Swigcptr()) -} - -type Thing7Int interface { - Swigcptr() uintptr - SwigIsThing7Int() -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - -type SwigcptrOuter5_Space5_Middle5_More5_Thing5_Sl_int_Sg_ uintptr -type Outer5_Space5_Middle5_More5_Thing5_Sl_int_Sg_ interface { - Swigcptr() uintptr; -} -func (p SwigcptrOuter5_Space5_Middle5_More5_Thing5_Sl_int_Sg_) Swigcptr() uintptr { - return uintptr(p) -} - -type SwigcptrOuter4_Space4_Middle4_Thing4_Sl_int_Sg_ uintptr -type Outer4_Space4_Middle4_Thing4_Sl_int_Sg_ interface { - Swigcptr() uintptr; -} -func (p SwigcptrOuter4_Space4_Middle4_Thing4_Sl_int_Sg_) Swigcptr() uintptr { - return uintptr(p) -} - -type SwigcptrOuter3_Space3_Middle3_Thing3_Sl_int_Sg_ uintptr -type Outer3_Space3_Middle3_Thing3_Sl_int_Sg_ interface { - Swigcptr() uintptr; -} -func (p SwigcptrOuter3_Space3_Middle3_Thing3_Sl_int_Sg_) Swigcptr() uintptr { - return uintptr(p) -} - -type SwigcptrOuter2_Space2_Thing2_Sl_int_Sg_ uintptr -type Outer2_Space2_Thing2_Sl_int_Sg_ interface { - Swigcptr() uintptr; -} -func (p SwigcptrOuter2_Space2_Thing2_Sl_int_Sg_) Swigcptr() uintptr { - return uintptr(p) -} - -type SwigcptrOuter7_Space7_Middle7_Thing7_Sl_int_Sg_ uintptr -type Outer7_Space7_Middle7_Thing7_Sl_int_Sg_ interface { - Swigcptr() uintptr; -} -func (p SwigcptrOuter7_Space7_Middle7_Thing7_Sl_int_Sg_) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/template_virtual.go b/Examples/test-suite/go/template_virtual.go deleted file mode 100644 index 02dc94f77..000000000 --- a/Examples/test-suite/go/template_virtual.go +++ /dev/null @@ -1,150 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../template_virtual.i - -package template_virtual - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrA_int uintptr - -func (p SwigcptrA_int) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrA_int) SwigIsA_int() { -} - -var _wrap_delete_A_int unsafe.Pointer - -func _swig_wrap_delete_A_int(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_A_int, _swig_p) - return -} - -func DeleteA_int(arg1 A_int) { - _swig_wrap_delete_A_int(arg1.Swigcptr()) -} - -var _wrap_A_int_say_hi unsafe.Pointer - -func _swig_wrap_A_int_say_hi(base SwigcptrA_int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_A_int_say_hi, _swig_p) - return -} - -func (arg1 SwigcptrA_int) Say_hi() { - _swig_wrap_A_int_say_hi(arg1) -} - -var _wrap_A_int_say_hello unsafe.Pointer - -func _swig_wrap_A_int_say_hello(base SwigcptrA_int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_A_int_say_hello, _swig_p) - return -} - -func (arg1 SwigcptrA_int) Say_hello() { - _swig_wrap_A_int_say_hello(arg1) -} - -type A_int interface { - Swigcptr() uintptr - SwigIsA_int() - Say_hi() - Say_hello() -} - -type SwigcptrB_int uintptr - -func (p SwigcptrB_int) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrB_int) SwigIsB_int() { -} - -var _wrap_delete_B_int unsafe.Pointer - -func _swig_wrap_delete_B_int(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_B_int, _swig_p) - return -} - -func DeleteB_int(arg1 B_int) { - _swig_wrap_delete_B_int(arg1.Swigcptr()) -} - -var _wrap_B_int_say_hi unsafe.Pointer - -func _swig_wrap_B_int_say_hi(base SwigcptrB_int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_B_int_say_hi, _swig_p) - return -} - -func (_swig_base SwigcptrB_int) Say_hi() { - _swig_wrap_B_int_say_hi(_swig_base) -} - -var _wrap_B_int_say_hello unsafe.Pointer - -func _swig_wrap_B_int_say_hello(base SwigcptrB_int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_B_int_say_hello, _swig_p) - return -} - -func (_swig_base SwigcptrB_int) Say_hello() { - _swig_wrap_B_int_say_hello(_swig_base) -} - -func (p SwigcptrB_int) SwigIsA_int() { -} - -func (p SwigcptrB_int) SwigGetA_int() A_int { - return SwigcptrA_int(p.Swigcptr()) -} - -type B_int interface { - Swigcptr() uintptr - SwigIsB_int() - Say_hi() - Say_hello() - SwigIsA_int() - SwigGetA_int() A_int -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/template_whitespace.go b/Examples/test-suite/go/template_whitespace.go deleted file mode 100644 index b8d486e82..000000000 --- a/Examples/test-suite/go/template_whitespace.go +++ /dev/null @@ -1,97 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../template_whitespace.i - -package template_whitespace - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -var _wrap_foo unsafe.Pointer - -func _swig_wrap_foo(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_foo, _swig_p) - return -} - -func Foo(arg1 Vector_Sl_int_Sg_) { - _swig_wrap_foo(arg1.Swigcptr()) -} - -var _wrap_bar unsafe.Pointer - -func _swig_wrap_bar(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_bar, _swig_p) - return -} - -func Bar(arg1 Vector_Sl_unsigned_SS_int_Sg_) { - _swig_wrap_bar(arg1.Swigcptr()) -} - -var _wrap_baz unsafe.Pointer - -func _swig_wrap_baz(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_baz, _swig_p) - return -} - -func Baz(arg1 Map_Sl_int_Sc_int_Sg_) { - _swig_wrap_baz(arg1.Swigcptr()) -} - - -type SwigcptrVector_Sl_unsigned_SS_int_Sg_ uintptr -type Vector_Sl_unsigned_SS_int_Sg_ interface { - Swigcptr() uintptr; -} -func (p SwigcptrVector_Sl_unsigned_SS_int_Sg_) Swigcptr() uintptr { - return uintptr(p) -} - -type SwigcptrVector_Sl_int_Sg_ uintptr -type Vector_Sl_int_Sg_ interface { - Swigcptr() uintptr; -} -func (p SwigcptrVector_Sl_int_Sg_) Swigcptr() uintptr { - return uintptr(p) -} - -type SwigcptrMap_Sl_int_Sc_int_Sg_ uintptr -type Map_Sl_int_Sc_int_Sg_ interface { - Swigcptr() uintptr; -} -func (p SwigcptrMap_Sl_int_Sc_int_Sg_) Swigcptr() uintptr { - return uintptr(p) -} - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/threads.go b/Examples/test-suite/go/threads.go deleted file mode 100644 index 4770bd401..000000000 --- a/Examples/test-suite/go/threads.go +++ /dev/null @@ -1,101 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../threads.i - -package threads - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrKerfuffle uintptr - -func (p SwigcptrKerfuffle) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrKerfuffle) SwigIsKerfuffle() { -} - -var _wrap_Kerfuffle_StdString unsafe.Pointer - -func _swig_wrap_Kerfuffle_StdString(base SwigcptrKerfuffle, _ string) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Kerfuffle_StdString, _swig_p) - return -} - -func (arg1 SwigcptrKerfuffle) StdString(arg2 string) (_swig_ret string) { - return _swig_wrap_Kerfuffle_StdString(arg1, arg2) -} - -var _wrap_Kerfuffle_CharString unsafe.Pointer - -func _swig_wrap_Kerfuffle_CharString(base SwigcptrKerfuffle, _ string) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Kerfuffle_CharString, _swig_p) - return -} - -func (arg1 SwigcptrKerfuffle) CharString(arg2 string) (_swig_ret string) { - return _swig_wrap_Kerfuffle_CharString(arg1, arg2) -} - -var _wrap_new_Kerfuffle unsafe.Pointer - -func _swig_wrap_new_Kerfuffle() (base SwigcptrKerfuffle) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Kerfuffle, _swig_p) - return -} - -func NewKerfuffle() (_swig_ret Kerfuffle) { - return _swig_wrap_new_Kerfuffle() -} - -var _wrap_delete_Kerfuffle unsafe.Pointer - -func _swig_wrap_delete_Kerfuffle(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Kerfuffle, _swig_p) - return -} - -func DeleteKerfuffle(arg1 Kerfuffle) { - _swig_wrap_delete_Kerfuffle(arg1.Swigcptr()) -} - -type Kerfuffle interface { - Swigcptr() uintptr - SwigIsKerfuffle() - StdString(arg2 string) (_swig_ret string) - CharString(arg2 string) (_swig_ret string) -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/threads_exception.go b/Examples/test-suite/go/threads_exception.go deleted file mode 100644 index 6fb40deea..000000000 --- a/Examples/test-suite/go/threads_exception.go +++ /dev/null @@ -1,230 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../threads_exception.i - -package threads_exception - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrExc uintptr - -func (p SwigcptrExc) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrExc) SwigIsExc() { -} - -var _wrap_new_Exc unsafe.Pointer - -func _swig_wrap_new_Exc(base int, _ string) (_ SwigcptrExc) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Exc, _swig_p) - return -} - -func NewExc(arg1 int, arg2 string) (_swig_ret Exc) { - return _swig_wrap_new_Exc(arg1, arg2) -} - -var _wrap_Exc_code_set unsafe.Pointer - -func _swig_wrap_Exc_code_set(base SwigcptrExc, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Exc_code_set, _swig_p) - return -} - -func (arg1 SwigcptrExc) SetCode(arg2 int) { - _swig_wrap_Exc_code_set(arg1, arg2) -} - -var _wrap_Exc_code_get unsafe.Pointer - -func _swig_wrap_Exc_code_get(base SwigcptrExc) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Exc_code_get, _swig_p) - return -} - -func (arg1 SwigcptrExc) GetCode() (_swig_ret int) { - return _swig_wrap_Exc_code_get(arg1) -} - -var _wrap_Exc_msg_set unsafe.Pointer - -func _swig_wrap_Exc_msg_set(base SwigcptrExc, _ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Exc_msg_set, _swig_p) - return -} - -func (arg1 SwigcptrExc) SetMsg(arg2 string) { - _swig_wrap_Exc_msg_set(arg1, arg2) -} - -var _wrap_Exc_msg_get unsafe.Pointer - -func _swig_wrap_Exc_msg_get(base SwigcptrExc) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Exc_msg_get, _swig_p) - return -} - -func (arg1 SwigcptrExc) GetMsg() (_swig_ret string) { - return _swig_wrap_Exc_msg_get(arg1) -} - -var _wrap_delete_Exc unsafe.Pointer - -func _swig_wrap_delete_Exc(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Exc, _swig_p) - return -} - -func DeleteExc(arg1 Exc) { - _swig_wrap_delete_Exc(arg1.Swigcptr()) -} - -type Exc interface { - Swigcptr() uintptr - SwigIsExc() - SetCode(arg2 int) - GetCode() (_swig_ret int) - SetMsg(arg2 string) - GetMsg() (_swig_ret string) -} - -type SwigcptrTest uintptr - -func (p SwigcptrTest) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrTest) SwigIsTest() { -} - -var _wrap_Test_simple unsafe.Pointer - -func _swig_wrap_Test_simple(base SwigcptrTest) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Test_simple, _swig_p) - return -} - -func (arg1 SwigcptrTest) Simple() (_swig_ret int) { - return _swig_wrap_Test_simple(arg1) -} - -var _wrap_Test_message unsafe.Pointer - -func _swig_wrap_Test_message(base SwigcptrTest) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Test_message, _swig_p) - return -} - -func (arg1 SwigcptrTest) Message() (_swig_ret int) { - return _swig_wrap_Test_message(arg1) -} - -var _wrap_Test_hosed unsafe.Pointer - -func _swig_wrap_Test_hosed(base SwigcptrTest) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Test_hosed, _swig_p) - return -} - -func (arg1 SwigcptrTest) Hosed() (_swig_ret int) { - return _swig_wrap_Test_hosed(arg1) -} - -var _wrap_Test_unknown unsafe.Pointer - -func _swig_wrap_Test_unknown(base SwigcptrTest) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Test_unknown, _swig_p) - return -} - -func (arg1 SwigcptrTest) Unknown() (_swig_ret int) { - return _swig_wrap_Test_unknown(arg1) -} - -var _wrap_Test_multi unsafe.Pointer - -func _swig_wrap_Test_multi(base SwigcptrTest, _ int) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Test_multi, _swig_p) - return -} - -func (arg1 SwigcptrTest) Multi(arg2 int) (_swig_ret int) { - return _swig_wrap_Test_multi(arg1, arg2) -} - -var _wrap_new_Test unsafe.Pointer - -func _swig_wrap_new_Test() (base SwigcptrTest) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Test, _swig_p) - return -} - -func NewTest() (_swig_ret Test) { - return _swig_wrap_new_Test() -} - -var _wrap_delete_Test unsafe.Pointer - -func _swig_wrap_delete_Test(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Test, _swig_p) - return -} - -func DeleteTest(arg1 Test) { - _swig_wrap_delete_Test(arg1.Swigcptr()) -} - -type Test interface { - Swigcptr() uintptr - SwigIsTest() - Simple() (_swig_ret int) - Message() (_swig_ret int) - Hosed() (_swig_ret int) - Unknown() (_swig_ret int) - Multi(arg2 int) (_swig_ret int) -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/threads_exception_runme b/Examples/test-suite/go/threads_exception_runme deleted file mode 100755 index ce2bde645..000000000 Binary files a/Examples/test-suite/go/threads_exception_runme and /dev/null differ diff --git a/Examples/test-suite/go/throw_exception.go b/Examples/test-suite/go/throw_exception.go deleted file mode 100644 index c658255e4..000000000 --- a/Examples/test-suite/go/throw_exception.go +++ /dev/null @@ -1,285 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../throw_exception.i - -package throw_exception - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrError uintptr - -func (p SwigcptrError) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrError) SwigIsError() { -} - -var _wrap_new_Error unsafe.Pointer - -func _swig_wrap_new_Error() (base SwigcptrError) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Error, _swig_p) - return -} - -func NewError() (_swig_ret Error) { - return _swig_wrap_new_Error() -} - -var _wrap_delete_Error unsafe.Pointer - -func _swig_wrap_delete_Error(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Error, _swig_p) - return -} - -func DeleteError(arg1 Error) { - _swig_wrap_delete_Error(arg1.Swigcptr()) -} - -type Error interface { - Swigcptr() uintptr - SwigIsError() -} - -var _wrap_test_is_Error unsafe.Pointer - -func _swig_wrap_test_is_Error(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_test_is_Error, _swig_p) - return -} - -func Test_is_Error(arg1 Error) { - _swig_wrap_test_is_Error(arg1.Swigcptr()) -} - -type NamespaceEnumTest int -var _wrap_enum1 unsafe.Pointer - -func _swig_getenum1() (_swig_ret NamespaceEnumTest) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_enum1, _swig_p) - return -} -var Enum1 NamespaceEnumTest = _swig_getenum1() -var _wrap_enum2 unsafe.Pointer - -func _swig_getenum2() (_swig_ret NamespaceEnumTest) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_enum2, _swig_p) - return -} -var Enum2 NamespaceEnumTest = _swig_getenum2() -type SwigcptrFoo uintptr - -func (p SwigcptrFoo) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrFoo) SwigIsFoo() { -} - -var _wrap_Foo_test_int unsafe.Pointer - -func _swig_wrap_Foo_test_int(base SwigcptrFoo) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_test_int, _swig_p) - return -} - -func (arg1 SwigcptrFoo) Test_int() { - _swig_wrap_Foo_test_int(arg1) -} - -var _wrap_Foo_test_msg unsafe.Pointer - -func _swig_wrap_Foo_test_msg(base SwigcptrFoo) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_test_msg, _swig_p) - return -} - -func (arg1 SwigcptrFoo) Test_msg() { - _swig_wrap_Foo_test_msg(arg1) -} - -var _wrap_Foo_test_cls unsafe.Pointer - -func _swig_wrap_Foo_test_cls(base SwigcptrFoo) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_test_cls, _swig_p) - return -} - -func (arg1 SwigcptrFoo) Test_cls() { - _swig_wrap_Foo_test_cls(arg1) -} - -var _wrap_Foo_test_cls_ptr unsafe.Pointer - -func _swig_wrap_Foo_test_cls_ptr(base SwigcptrFoo) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_test_cls_ptr, _swig_p) - return -} - -func (arg1 SwigcptrFoo) Test_cls_ptr() { - _swig_wrap_Foo_test_cls_ptr(arg1) -} - -var _wrap_Foo_test_cls_ref unsafe.Pointer - -func _swig_wrap_Foo_test_cls_ref(base SwigcptrFoo) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_test_cls_ref, _swig_p) - return -} - -func (arg1 SwigcptrFoo) Test_cls_ref() { - _swig_wrap_Foo_test_cls_ref(arg1) -} - -var _wrap_Foo_test_cls_td unsafe.Pointer - -func _swig_wrap_Foo_test_cls_td(base SwigcptrFoo) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_test_cls_td, _swig_p) - return -} - -func (arg1 SwigcptrFoo) Test_cls_td() { - _swig_wrap_Foo_test_cls_td(arg1) -} - -var _wrap_Foo_test_cls_ptr_td unsafe.Pointer - -func _swig_wrap_Foo_test_cls_ptr_td(base SwigcptrFoo) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_test_cls_ptr_td, _swig_p) - return -} - -func (arg1 SwigcptrFoo) Test_cls_ptr_td() { - _swig_wrap_Foo_test_cls_ptr_td(arg1) -} - -var _wrap_Foo_test_cls_ref_td unsafe.Pointer - -func _swig_wrap_Foo_test_cls_ref_td(base SwigcptrFoo) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_test_cls_ref_td, _swig_p) - return -} - -func (arg1 SwigcptrFoo) Test_cls_ref_td() { - _swig_wrap_Foo_test_cls_ref_td(arg1) -} - -var _wrap_Foo_test_array unsafe.Pointer - -func _swig_wrap_Foo_test_array(base SwigcptrFoo) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_test_array, _swig_p) - return -} - -func (arg1 SwigcptrFoo) Test_array() { - _swig_wrap_Foo_test_array(arg1) -} - -var _wrap_Foo_test_enum unsafe.Pointer - -func _swig_wrap_Foo_test_enum(base SwigcptrFoo) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_test_enum, _swig_p) - return -} - -func (arg1 SwigcptrFoo) Test_enum() { - _swig_wrap_Foo_test_enum(arg1) -} - -var _wrap_Foo_test_multi unsafe.Pointer - -func _swig_wrap_Foo_test_multi(base SwigcptrFoo, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_test_multi, _swig_p) - return -} - -func (arg1 SwigcptrFoo) Test_multi(arg2 int) { - _swig_wrap_Foo_test_multi(arg1, arg2) -} - -var _wrap_new_Foo unsafe.Pointer - -func _swig_wrap_new_Foo() (base SwigcptrFoo) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Foo, _swig_p) - return -} - -func NewFoo() (_swig_ret Foo) { - return _swig_wrap_new_Foo() -} - -var _wrap_delete_Foo unsafe.Pointer - -func _swig_wrap_delete_Foo(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Foo, _swig_p) - return -} - -func DeleteFoo(arg1 Foo) { - _swig_wrap_delete_Foo(arg1.Swigcptr()) -} - -type Foo interface { - Swigcptr() uintptr - SwigIsFoo() - Test_int() - Test_msg() - Test_cls() - Test_cls_ptr() - Test_cls_ref() - Test_cls_td() - Test_cls_ptr_td() - Test_cls_ref_td() - Test_array() - Test_enum() - Test_multi(arg2 int) -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/typedef_array_member.go b/Examples/test-suite/go/typedef_array_member.go deleted file mode 100644 index 69e3a93e5..000000000 --- a/Examples/test-suite/go/typedef_array_member.go +++ /dev/null @@ -1,173 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../typedef_array_member.i - -package typedef_array_member - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrFoo uintptr - -func (p SwigcptrFoo) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrFoo) SwigIsFoo() { -} - -var _wrap_Foo_x_set unsafe.Pointer - -func _swig_wrap_Foo_x_set(base SwigcptrFoo, _ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_x_set, _swig_p) - return -} - -func (arg1 SwigcptrFoo) SetX(arg2 string) { - _swig_wrap_Foo_x_set(arg1, arg2) -} - -var _wrap_Foo_x_get unsafe.Pointer - -func _swig_wrap_Foo_x_get(base SwigcptrFoo) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_x_get, _swig_p) - return -} - -func (arg1 SwigcptrFoo) GetX() (_swig_ret string) { - return _swig_wrap_Foo_x_get(arg1) -} - -var _wrap_new_Foo unsafe.Pointer - -func _swig_wrap_new_Foo() (base SwigcptrFoo) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Foo, _swig_p) - return -} - -func NewFoo() (_swig_ret Foo) { - return _swig_wrap_new_Foo() -} - -var _wrap_delete_Foo unsafe.Pointer - -func _swig_wrap_delete_Foo(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Foo, _swig_p) - return -} - -func DeleteFoo(arg1 Foo) { - _swig_wrap_delete_Foo(arg1.Swigcptr()) -} - -type Foo interface { - Swigcptr() uintptr - SwigIsFoo() - SetX(arg2 string) - GetX() (_swig_ret string) -} - -type SwigcptrAst_channel uintptr - -func (p SwigcptrAst_channel) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrAst_channel) SwigIsAst_channel() { -} - -var _wrap_Ast_channel_jmp_set unsafe.Pointer - -func _swig_wrap_Ast_channel_jmp_set(base SwigcptrAst_channel, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Ast_channel_jmp_set, _swig_p) - return -} - -func (arg1 SwigcptrAst_channel) SetJmp(arg2 Jbuf_tag) { - _swig_wrap_Ast_channel_jmp_set(arg1, arg2.Swigcptr()) -} - -var _wrap_Ast_channel_jmp_get unsafe.Pointer - -func _swig_wrap_Ast_channel_jmp_get(base SwigcptrAst_channel) (_ SwigcptrJbuf_tag) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Ast_channel_jmp_get, _swig_p) - return -} - -func (arg1 SwigcptrAst_channel) GetJmp() (_swig_ret Jbuf_tag) { - return _swig_wrap_Ast_channel_jmp_get(arg1) -} - -var _wrap_new_Ast_channel unsafe.Pointer - -func _swig_wrap_new_Ast_channel() (base SwigcptrAst_channel) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Ast_channel, _swig_p) - return -} - -func NewAst_channel() (_swig_ret Ast_channel) { - return _swig_wrap_new_Ast_channel() -} - -var _wrap_delete_Ast_channel unsafe.Pointer - -func _swig_wrap_delete_Ast_channel(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Ast_channel, _swig_p) - return -} - -func DeleteAst_channel(arg1 Ast_channel) { - _swig_wrap_delete_Ast_channel(arg1.Swigcptr()) -} - -type Ast_channel interface { - Swigcptr() uintptr - SwigIsAst_channel() - SetJmp(arg2 Jbuf_tag) - GetJmp() (_swig_ret Jbuf_tag) -} - - -type SwigcptrJbuf_tag uintptr -type Jbuf_tag interface { - Swigcptr() uintptr; -} -func (p SwigcptrJbuf_tag) Swigcptr() uintptr { - return uintptr(p) -} - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/typedef_class.go b/Examples/test-suite/go/typedef_class.go deleted file mode 100644 index cb02079bf..000000000 --- a/Examples/test-suite/go/typedef_class.go +++ /dev/null @@ -1,297 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../typedef_class.i - -package typedef_class - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrRealA uintptr - -func (p SwigcptrRealA) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrRealA) SwigIsRealA() { -} - -var _wrap_RealA_a_set unsafe.Pointer - -func _swig_wrap_RealA_a_set(base SwigcptrRealA, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_RealA_a_set, _swig_p) - return -} - -func (arg1 SwigcptrRealA) SetA(arg2 int) { - _swig_wrap_RealA_a_set(arg1, arg2) -} - -var _wrap_RealA_a_get unsafe.Pointer - -func _swig_wrap_RealA_a_get(base SwigcptrRealA) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_RealA_a_get, _swig_p) - return -} - -func (arg1 SwigcptrRealA) GetA() (_swig_ret int) { - return _swig_wrap_RealA_a_get(arg1) -} - -var _wrap_new_RealA unsafe.Pointer - -func _swig_wrap_new_RealA() (base SwigcptrRealA) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_RealA, _swig_p) - return -} - -func NewRealA() (_swig_ret RealA) { - return _swig_wrap_new_RealA() -} - -var _wrap_delete_RealA unsafe.Pointer - -func _swig_wrap_delete_RealA(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_RealA, _swig_p) - return -} - -func DeleteRealA(arg1 RealA) { - _swig_wrap_delete_RealA(arg1.Swigcptr()) -} - -type RealA interface { - Swigcptr() uintptr - SwigIsRealA() - SetA(arg2 int) - GetA() (_swig_ret int) -} - -type SwigcptrB uintptr - -func (p SwigcptrB) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrB) SwigIsB() { -} - -var _wrap_B_testA unsafe.Pointer - -func _swig_wrap_B_testA(base SwigcptrB, _ uintptr) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_B_testA, _swig_p) - return -} - -func (arg1 SwigcptrB) TestA(arg2 RealA) (_swig_ret int) { - return _swig_wrap_B_testA(arg1, arg2.Swigcptr()) -} - -var _wrap_new_B unsafe.Pointer - -func _swig_wrap_new_B() (base SwigcptrB) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_B, _swig_p) - return -} - -func NewB() (_swig_ret B) { - return _swig_wrap_new_B() -} - -var _wrap_delete_B unsafe.Pointer - -func _swig_wrap_delete_B(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_B, _swig_p) - return -} - -func DeleteB(arg1 B) { - _swig_wrap_delete_B(arg1.Swigcptr()) -} - -type B interface { - Swigcptr() uintptr - SwigIsB() - TestA(arg2 RealA) (_swig_ret int) -} - -type SwigcptrBBB uintptr - -func (p SwigcptrBBB) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrBBB) SwigIsBBB() { -} - -var _wrap_new_BBB unsafe.Pointer - -func _swig_wrap_new_BBB() (base SwigcptrBBB) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_BBB, _swig_p) - return -} - -func NewBBB() (_swig_ret BBB) { - return _swig_wrap_new_BBB() -} - -var _wrap_delete_BBB unsafe.Pointer - -func _swig_wrap_delete_BBB(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_BBB, _swig_p) - return -} - -func DeleteBBB(arg1 BBB) { - _swig_wrap_delete_BBB(arg1.Swigcptr()) -} - -type BBB interface { - Swigcptr() uintptr - SwigIsBBB() -} - -type SwigcptrBB uintptr - -func (p SwigcptrBB) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrBB) SwigIsBB() { -} - -var _wrap_new_BB__SWIG_0 unsafe.Pointer - -func _swig_wrap_new_BB__SWIG_0() (base SwigcptrBB) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_BB__SWIG_0, _swig_p) - return -} - -func NewBB__SWIG_0() (_swig_ret BB) { - return _swig_wrap_new_BB__SWIG_0() -} - -var _wrap_new_BB__SWIG_1 unsafe.Pointer - -func _swig_wrap_new_BB__SWIG_1(base int) (_ SwigcptrBB) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_BB__SWIG_1, _swig_p) - return -} - -func NewBB__SWIG_1(arg1 int) (_swig_ret BB) { - return _swig_wrap_new_BB__SWIG_1(arg1) -} - -func NewBB(a ...interface{}) BB { - argc := len(a) - if argc == 0 { - return NewBB__SWIG_0() - } - if argc == 1 { - return NewBB__SWIG_1(a[0].(int)) - } - panic("No match for overloaded function call") -} - -var _wrap_BB_aa_var_set unsafe.Pointer - -func _swig_wrap_BB_aa_var_set(base SwigcptrBB, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_BB_aa_var_set, _swig_p) - return -} - -func (arg1 SwigcptrBB) SetAa_var(arg2 int) { - _swig_wrap_BB_aa_var_set(arg1, arg2) -} - -var _wrap_BB_aa_var_get unsafe.Pointer - -func _swig_wrap_BB_aa_var_get(base SwigcptrBB) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_BB_aa_var_get, _swig_p) - return -} - -func (arg1 SwigcptrBB) GetAa_var() (_swig_ret int) { - return _swig_wrap_BB_aa_var_get(arg1) -} - -var _wrap_BB_aa_method unsafe.Pointer - -func _swig_wrap_BB_aa_method(base SwigcptrBB, _ float64) (_ *int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_BB_aa_method, _swig_p) - return -} - -func (arg1 SwigcptrBB) Aa_method(arg2 float64) (_swig_ret *int) { - return _swig_wrap_BB_aa_method(arg1, arg2) -} - -var _wrap_BB_aa_static_method unsafe.Pointer - -func BBAa_static_method(arg1 bool) (_swig_ret *int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_BB_aa_static_method, _swig_p) - return -} -var _wrap_delete_BB unsafe.Pointer - -func _swig_wrap_delete_BB(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_BB, _swig_p) - return -} - -func DeleteBB(arg1 BB) { - _swig_wrap_delete_BB(arg1.Swigcptr()) -} - -type BB interface { - Swigcptr() uintptr - SwigIsBB() - SetAa_var(arg2 int) - GetAa_var() (_swig_ret int) - Aa_method(arg2 float64) (_swig_ret *int) -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/typedef_class_runme b/Examples/test-suite/go/typedef_class_runme deleted file mode 100755 index 1affbf7ce..000000000 Binary files a/Examples/test-suite/go/typedef_class_runme and /dev/null differ diff --git a/Examples/test-suite/go/typedef_funcptr.go b/Examples/test-suite/go/typedef_funcptr.go deleted file mode 100644 index b26a46782..000000000 --- a/Examples/test-suite/go/typedef_funcptr.go +++ /dev/null @@ -1,52 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../typedef_funcptr.i - -package typedef_funcptr - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -var _wrap_do_op unsafe.Pointer - -func Do_op(arg1 int, arg2 int, arg3 _swig_fnptr) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_do_op, _swig_p) - return -} -var _wrap_addf unsafe.Pointer - -func _swig_getaddf() (_swig_ret _swig_fnptr) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_addf, _swig_p) - return -} -var Addf _swig_fnptr = _swig_getaddf() -var _wrap_subf unsafe.Pointer - -func _swig_getsubf() (_swig_ret _swig_fnptr) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_subf, _swig_p) - return -} -var Subf _swig_fnptr = _swig_getsubf() - diff --git a/Examples/test-suite/go/typedef_inherit.go b/Examples/test-suite/go/typedef_inherit.go deleted file mode 100644 index 39cf9102f..000000000 --- a/Examples/test-suite/go/typedef_inherit.go +++ /dev/null @@ -1,283 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../typedef_inherit.i - -package typedef_inherit - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrFoo uintptr - -func (p SwigcptrFoo) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrFoo) SwigIsFoo() { -} - -var _wrap_delete_Foo unsafe.Pointer - -func _swig_wrap_delete_Foo(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Foo, _swig_p) - return -} - -func DeleteFoo(arg1 Foo) { - _swig_wrap_delete_Foo(arg1.Swigcptr()) -} - -var _wrap_Foo_blah unsafe.Pointer - -func _swig_wrap_Foo_blah(base SwigcptrFoo) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_blah, _swig_p) - return -} - -func (arg1 SwigcptrFoo) Blah() (_swig_ret string) { - return _swig_wrap_Foo_blah(arg1) -} - -var _wrap_new_Foo unsafe.Pointer - -func _swig_wrap_new_Foo() (base SwigcptrFoo) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Foo, _swig_p) - return -} - -func NewFoo() (_swig_ret Foo) { - return _swig_wrap_new_Foo() -} - -type Foo interface { - Swigcptr() uintptr - SwigIsFoo() - Blah() (_swig_ret string) -} - -type SwigcptrBar uintptr - -func (p SwigcptrBar) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrBar) SwigIsBar() { -} - -var _wrap_Bar_blah unsafe.Pointer - -func _swig_wrap_Bar_blah(base SwigcptrBar) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Bar_blah, _swig_p) - return -} - -func (arg1 SwigcptrBar) Blah() (_swig_ret string) { - return _swig_wrap_Bar_blah(arg1) -} - -var _wrap_new_Bar unsafe.Pointer - -func _swig_wrap_new_Bar() (base SwigcptrBar) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Bar, _swig_p) - return -} - -func NewBar() (_swig_ret Bar) { - return _swig_wrap_new_Bar() -} - -var _wrap_delete_Bar unsafe.Pointer - -func _swig_wrap_delete_Bar(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Bar, _swig_p) - return -} - -func DeleteBar(arg1 Bar) { - _swig_wrap_delete_Bar(arg1.Swigcptr()) -} - -func (p SwigcptrBar) SwigIsFoo() { -} - -func (p SwigcptrBar) SwigGetFoo() Foo { - return SwigcptrFoo(p.Swigcptr()) -} - -type Bar interface { - Swigcptr() uintptr - SwigIsBar() - Blah() (_swig_ret string) - SwigIsFoo() - SwigGetFoo() Foo -} - -var _wrap_do_blah unsafe.Pointer - -func _swig_wrap_do_blah(base uintptr) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_do_blah, _swig_p) - return -} - -func Do_blah(arg1 Foo) (_swig_ret string) { - return _swig_wrap_do_blah(arg1.Swigcptr()) -} - -type SwigcptrSpam uintptr - -func (p SwigcptrSpam) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrSpam) SwigIsSpam() { -} - -var _wrap_delete_Spam unsafe.Pointer - -func _swig_wrap_delete_Spam(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Spam, _swig_p) - return -} - -func DeleteSpam(arg1 Spam) { - _swig_wrap_delete_Spam(arg1.Swigcptr()) -} - -var _wrap_Spam_blah unsafe.Pointer - -func _swig_wrap_Spam_blah(base SwigcptrSpam) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Spam_blah, _swig_p) - return -} - -func (arg1 SwigcptrSpam) Blah() (_swig_ret string) { - return _swig_wrap_Spam_blah(arg1) -} - -var _wrap_new_Spam unsafe.Pointer - -func _swig_wrap_new_Spam() (base SwigcptrSpam) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Spam, _swig_p) - return -} - -func NewSpam() (_swig_ret Spam) { - return _swig_wrap_new_Spam() -} - -type Spam interface { - Swigcptr() uintptr - SwigIsSpam() - Blah() (_swig_ret string) -} - -type SwigcptrGrok uintptr - -func (p SwigcptrGrok) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrGrok) SwigIsGrok() { -} - -var _wrap_delete_Grok unsafe.Pointer - -func _swig_wrap_delete_Grok(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Grok, _swig_p) - return -} - -func DeleteGrok(arg1 Grok) { - _swig_wrap_delete_Grok(arg1.Swigcptr()) -} - -var _wrap_Grok_blah unsafe.Pointer - -func _swig_wrap_Grok_blah(base SwigcptrGrok) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Grok_blah, _swig_p) - return -} - -func (arg1 SwigcptrGrok) Blah() (_swig_ret string) { - return _swig_wrap_Grok_blah(arg1) -} - -var _wrap_new_Grok unsafe.Pointer - -func _swig_wrap_new_Grok() (base SwigcptrGrok) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Grok, _swig_p) - return -} - -func NewGrok() (_swig_ret Grok) { - return _swig_wrap_new_Grok() -} - -func (p SwigcptrGrok) SwigIsSpam() { -} - -func (p SwigcptrGrok) SwigGetSpam() Spam { - return SwigcptrSpam(p.Swigcptr()) -} - -type Grok interface { - Swigcptr() uintptr - SwigIsGrok() - Blah() (_swig_ret string) - SwigIsSpam() - SwigGetSpam() Spam -} - -var _wrap_do_blah2 unsafe.Pointer - -func _swig_wrap_do_blah2(base uintptr) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_do_blah2, _swig_p) - return -} - -func Do_blah2(arg1 Spam) (_swig_ret string) { - return _swig_wrap_do_blah2(arg1.Swigcptr()) -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/typedef_inherit_runme b/Examples/test-suite/go/typedef_inherit_runme deleted file mode 100755 index 3c24d9ebe..000000000 Binary files a/Examples/test-suite/go/typedef_inherit_runme and /dev/null differ diff --git a/Examples/test-suite/go/typedef_mptr.go b/Examples/test-suite/go/typedef_mptr.go deleted file mode 100644 index 67f731ec0..000000000 --- a/Examples/test-suite/go/typedef_mptr.go +++ /dev/null @@ -1,29 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../typedef_mptr.i - -package typedef_mptr - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - - diff --git a/Examples/test-suite/go/typedef_reference.go b/Examples/test-suite/go/typedef_reference.go deleted file mode 100644 index 64d09f58e..000000000 --- a/Examples/test-suite/go/typedef_reference.go +++ /dev/null @@ -1,96 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../typedef_reference.i - -package typedef_reference - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -var _wrap_new_intp unsafe.Pointer - -func New_intp() (_swig_ret *int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_new_intp, _swig_p) - return -} -var _wrap_copy_intp unsafe.Pointer - -func Copy_intp(arg1 int) (_swig_ret *int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_copy_intp, _swig_p) - return -} -var _wrap_delete_intp unsafe.Pointer - -func _swig_wrap_delete_intp(base *int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_intp, _swig_p) - return -} - -func Delete_intp(arg1 *int) { - _swig_wrap_delete_intp(arg1) -} - -var _wrap_intp_assign unsafe.Pointer - -func _swig_wrap_intp_assign(base *int, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_intp_assign, _swig_p) - return -} - -func Intp_assign(arg1 *int, arg2 int) { - _swig_wrap_intp_assign(arg1, arg2) -} - -var _wrap_intp_value unsafe.Pointer - -func Intp_value(arg1 *int) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_intp_value, _swig_p) - return -} -var _wrap_somefunc unsafe.Pointer - -func Somefunc(arg1 *int) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_somefunc, _swig_p) - return -} -var _wrap_otherfunc unsafe.Pointer - -func Otherfunc(arg1 *int) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_otherfunc, _swig_p) - return -} - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/typedef_scope.go b/Examples/test-suite/go/typedef_scope.go deleted file mode 100644 index 1f00a8813..000000000 --- a/Examples/test-suite/go/typedef_scope.go +++ /dev/null @@ -1,177 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../typedef_scope.i - -package typedef_scope - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrBar uintptr - -func (p SwigcptrBar) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrBar) SwigIsBar() { -} - -var _wrap_Bar_test1 unsafe.Pointer - -func _swig_wrap_Bar_test1(base SwigcptrBar, _ int, _ string) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Bar_test1, _swig_p) - return -} - -func (arg1 SwigcptrBar) Test1(arg2 int, arg3 string) (_swig_ret int) { - return _swig_wrap_Bar_test1(arg1, arg2, arg3) -} - -var _wrap_Bar_test2 unsafe.Pointer - -func _swig_wrap_Bar_test2(base SwigcptrBar, _ int, _ string) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Bar_test2, _swig_p) - return -} - -func (arg1 SwigcptrBar) Test2(arg2 int, arg3 string) (_swig_ret string) { - return _swig_wrap_Bar_test2(arg1, arg2, arg3) -} - -var _wrap_new_Bar unsafe.Pointer - -func _swig_wrap_new_Bar() (base SwigcptrBar) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Bar, _swig_p) - return -} - -func NewBar() (_swig_ret Bar) { - return _swig_wrap_new_Bar() -} - -var _wrap_delete_Bar unsafe.Pointer - -func _swig_wrap_delete_Bar(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Bar, _swig_p) - return -} - -func DeleteBar(arg1 Bar) { - _swig_wrap_delete_Bar(arg1.Swigcptr()) -} - -type Bar interface { - Swigcptr() uintptr - SwigIsBar() - Test1(arg2 int, arg3 string) (_swig_ret int) - Test2(arg2 int, arg3 string) (_swig_ret string) -} - -type SwigcptrFoo uintptr - -func (p SwigcptrFoo) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrFoo) SwigIsFoo() { -} - -var _wrap_new_Foo unsafe.Pointer - -func _swig_wrap_new_Foo() (base SwigcptrFoo) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Foo, _swig_p) - return -} - -func NewFoo() (_swig_ret Foo) { - return _swig_wrap_new_Foo() -} - -var _wrap_delete_Foo unsafe.Pointer - -func _swig_wrap_delete_Foo(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Foo, _swig_p) - return -} - -func DeleteFoo(arg1 Foo) { - _swig_wrap_delete_Foo(arg1.Swigcptr()) -} - -type Foo interface { - Swigcptr() uintptr - SwigIsFoo() -} - -type SwigcptrCBaz uintptr - -func (p SwigcptrCBaz) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrCBaz) SwigIsCBaz() { -} - -var _wrap_new_CBaz unsafe.Pointer - -func _swig_wrap_new_CBaz() (base SwigcptrCBaz) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_CBaz, _swig_p) - return -} - -func NewCBaz() (_swig_ret CBaz) { - return _swig_wrap_new_CBaz() -} - -var _wrap_delete_CBaz unsafe.Pointer - -func _swig_wrap_delete_CBaz(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_CBaz, _swig_p) - return -} - -func DeleteCBaz(arg1 CBaz) { - _swig_wrap_delete_CBaz(arg1.Swigcptr()) -} - -type CBaz interface { - Swigcptr() uintptr - SwigIsCBaz() -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/typedef_scope_runme b/Examples/test-suite/go/typedef_scope_runme deleted file mode 100755 index 444963d4c..000000000 Binary files a/Examples/test-suite/go/typedef_scope_runme and /dev/null differ diff --git a/Examples/test-suite/go/typedef_sizet.go b/Examples/test-suite/go/typedef_sizet.go deleted file mode 100644 index 1c3772709..000000000 --- a/Examples/test-suite/go/typedef_sizet.go +++ /dev/null @@ -1,36 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../typedef_sizet.i - -package typedef_sizet - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -var _wrap_size unsafe.Pointer - -func Size(arg1 int64) (_swig_ret int64) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_size, _swig_p) - return -} - diff --git a/Examples/test-suite/go/typedef_struct.go b/Examples/test-suite/go/typedef_struct.go deleted file mode 100644 index 837b51ad4..000000000 --- a/Examples/test-suite/go/typedef_struct.go +++ /dev/null @@ -1,438 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../typedef_struct.i - -package typedef_struct - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrLineObj uintptr - -func (p SwigcptrLineObj) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrLineObj) SwigIsLineObj() { -} - -var _wrap_LineObj_numpoints_set unsafe.Pointer - -func _swig_wrap_LineObj_numpoints_set(base SwigcptrLineObj, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_LineObj_numpoints_set, _swig_p) - return -} - -func (arg1 SwigcptrLineObj) SetNumpoints(arg2 int) { - _swig_wrap_LineObj_numpoints_set(arg1, arg2) -} - -var _wrap_LineObj_numpoints_get unsafe.Pointer - -func _swig_wrap_LineObj_numpoints_get(base SwigcptrLineObj) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_LineObj_numpoints_get, _swig_p) - return -} - -func (arg1 SwigcptrLineObj) GetNumpoints() (_swig_ret int) { - return _swig_wrap_LineObj_numpoints_get(arg1) -} - -var _wrap_new_LineObj unsafe.Pointer - -func _swig_wrap_new_LineObj() (base SwigcptrLineObj) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_LineObj, _swig_p) - return -} - -func NewLineObj() (_swig_ret LineObj) { - return _swig_wrap_new_LineObj() -} - -var _wrap_delete_LineObj unsafe.Pointer - -func _swig_wrap_delete_LineObj(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_LineObj, _swig_p) - return -} - -func DeleteLineObj(arg1 LineObj) { - _swig_wrap_delete_LineObj(arg1.Swigcptr()) -} - -type LineObj interface { - Swigcptr() uintptr - SwigIsLineObj() - SetNumpoints(arg2 int) - GetNumpoints() (_swig_ret int) -} - -type SwigcptrFontSetObj uintptr - -func (p SwigcptrFontSetObj) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrFontSetObj) SwigIsFontSetObj() { -} - -var _wrap_FontSetObj_filename_get unsafe.Pointer - -func _swig_wrap_FontSetObj_filename_get(base SwigcptrFontSetObj) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_FontSetObj_filename_get, _swig_p) - return -} - -func (arg1 SwigcptrFontSetObj) GetFilename() (_swig_ret string) { - return _swig_wrap_FontSetObj_filename_get(arg1) -} - -var _wrap_FontSetObj_numfonts_get unsafe.Pointer - -func _swig_wrap_FontSetObj_numfonts_get(base SwigcptrFontSetObj) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_FontSetObj_numfonts_get, _swig_p) - return -} - -func (arg1 SwigcptrFontSetObj) GetNumfonts() (_swig_ret int) { - return _swig_wrap_FontSetObj_numfonts_get(arg1) -} - -var _wrap_FontSetObj_fonts_set unsafe.Pointer - -func _swig_wrap_FontSetObj_fonts_set(base SwigcptrFontSetObj, _ *int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_FontSetObj_fonts_set, _swig_p) - return -} - -func (arg1 SwigcptrFontSetObj) SetFonts(arg2 *int) { - _swig_wrap_FontSetObj_fonts_set(arg1, arg2) -} - -var _wrap_FontSetObj_fonts_get unsafe.Pointer - -func _swig_wrap_FontSetObj_fonts_get(base SwigcptrFontSetObj) (_ *int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_FontSetObj_fonts_get, _swig_p) - return -} - -func (arg1 SwigcptrFontSetObj) GetFonts() (_swig_ret *int) { - return _swig_wrap_FontSetObj_fonts_get(arg1) -} - -var _wrap_new_FontSetObj unsafe.Pointer - -func _swig_wrap_new_FontSetObj() (base SwigcptrFontSetObj) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_FontSetObj, _swig_p) - return -} - -func NewFontSetObj() (_swig_ret FontSetObj) { - return _swig_wrap_new_FontSetObj() -} - -var _wrap_delete_FontSetObj unsafe.Pointer - -func _swig_wrap_delete_FontSetObj(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_FontSetObj, _swig_p) - return -} - -func DeleteFontSetObj(arg1 FontSetObj) { - _swig_wrap_delete_FontSetObj(arg1.Swigcptr()) -} - -type FontSetObj interface { - Swigcptr() uintptr - SwigIsFontSetObj() - GetFilename() (_swig_ret string) - GetNumfonts() (_swig_ret int) - SetFonts(arg2 *int) - GetFonts() (_swig_ret *int) -} - -const MS_NOOVERRIDE int = -1111 -type SwigcptrA_t uintptr - -func (p SwigcptrA_t) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrA_t) SwigIsA_t() { -} - -var _wrap_A_t_a_set unsafe.Pointer - -func _swig_wrap_A_t_a_set(base SwigcptrA_t, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_A_t_a_set, _swig_p) - return -} - -func (arg1 SwigcptrA_t) SetA(arg2 int) { - _swig_wrap_A_t_a_set(arg1, arg2) -} - -var _wrap_A_t_a_get unsafe.Pointer - -func _swig_wrap_A_t_a_get(base SwigcptrA_t) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_A_t_a_get, _swig_p) - return -} - -func (arg1 SwigcptrA_t) GetA() (_swig_ret int) { - return _swig_wrap_A_t_a_get(arg1) -} - -var _wrap_A_t_b_set unsafe.Pointer - -func _swig_wrap_A_t_b_set(base SwigcptrA_t, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_A_t_b_set, _swig_p) - return -} - -func (arg1 SwigcptrA_t) SetB(arg2 int) { - _swig_wrap_A_t_b_set(arg1, arg2) -} - -var _wrap_A_t_b_get unsafe.Pointer - -func _swig_wrap_A_t_b_get(base SwigcptrA_t) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_A_t_b_get, _swig_p) - return -} - -func (arg1 SwigcptrA_t) GetB() (_swig_ret int) { - return _swig_wrap_A_t_b_get(arg1) -} - -var _wrap_new_A_t unsafe.Pointer - -func _swig_wrap_new_A_t() (base SwigcptrA_t) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_A_t, _swig_p) - return -} - -func NewA_t() (_swig_ret A_t) { - return _swig_wrap_new_A_t() -} - -var _wrap_delete_A_t unsafe.Pointer - -func _swig_wrap_delete_A_t(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_A_t, _swig_p) - return -} - -func DeleteA_t(arg1 A_t) { - _swig_wrap_delete_A_t(arg1.Swigcptr()) -} - -type A_t interface { - Swigcptr() uintptr - SwigIsA_t() - SetA(arg2 int) - GetA() (_swig_ret int) - SetB(arg2 int) - GetB() (_swig_ret int) -} - -var _wrap_make_a unsafe.Pointer - -func _swig_wrap_make_a() (base SwigcptrA_t) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_make_a, _swig_p) - return -} - -func Make_a() (_swig_ret A_t) { - return _swig_wrap_make_a() -} - -var _wrap_make_b unsafe.Pointer - -func _swig_wrap_make_b() (base SwigcptrA_t) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_make_b, _swig_p) - return -} - -func Make_b() (_swig_ret A_t) { - return _swig_wrap_make_b() -} - -type SwigcptrFoo uintptr - -func (p SwigcptrFoo) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrFoo) SwigIsFoo() { -} - -var _wrap_NONAME1_Foo unsafe.Pointer - -func _swig_getFoo_NONAME1_Foo() (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_NONAME1_Foo, _swig_p) - return -} -var FooNONAME1 int = _swig_getFoo_NONAME1_Foo() -var _wrap_NONAME2_Foo unsafe.Pointer - -func _swig_getFoo_NONAME2_Foo() (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_NONAME2_Foo, _swig_p) - return -} -var FooNONAME2 int = _swig_getFoo_NONAME2_Foo() -var _wrap_Foo_enumvar_set unsafe.Pointer - -func _swig_wrap_Foo_enumvar_set(base SwigcptrFoo, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_enumvar_set, _swig_p) - return -} - -func (arg1 SwigcptrFoo) SetEnumvar(arg2 int) { - _swig_wrap_Foo_enumvar_set(arg1, arg2) -} - -var _wrap_Foo_enumvar_get unsafe.Pointer - -func _swig_wrap_Foo_enumvar_get(base SwigcptrFoo) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_enumvar_get, _swig_p) - return -} - -func (arg1 SwigcptrFoo) GetEnumvar() (_swig_ret int) { - return _swig_wrap_Foo_enumvar_get(arg1) -} - -var _wrap_Foo_foovar_set unsafe.Pointer - -func _swig_wrap_Foo_foovar_set(base SwigcptrFoo, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_foovar_set, _swig_p) - return -} - -func (arg1 SwigcptrFoo) SetFoovar(arg2 int) { - _swig_wrap_Foo_foovar_set(arg1, arg2) -} - -var _wrap_Foo_foovar_get unsafe.Pointer - -func _swig_wrap_Foo_foovar_get(base SwigcptrFoo) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_foovar_get, _swig_p) - return -} - -func (arg1 SwigcptrFoo) GetFoovar() (_swig_ret int) { - return _swig_wrap_Foo_foovar_get(arg1) -} - -var _wrap_Foo_fptr_set unsafe.Pointer - -func _swig_wrap_Foo_fptr_set(base SwigcptrFoo, _ _swig_fnptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_fptr_set, _swig_p) - return -} - -func (arg1 SwigcptrFoo) SetFptr(arg2 _swig_fnptr) { - _swig_wrap_Foo_fptr_set(arg1, arg2) -} - -var _wrap_Foo_fptr_get unsafe.Pointer - -func _swig_wrap_Foo_fptr_get(base SwigcptrFoo) (_ _swig_fnptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_fptr_get, _swig_p) - return -} - -func (arg1 SwigcptrFoo) GetFptr() (_swig_ret _swig_fnptr) { - return _swig_wrap_Foo_fptr_get(arg1) -} - -var _wrap_new_Foo unsafe.Pointer - -func _swig_wrap_new_Foo() (base SwigcptrFoo) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Foo, _swig_p) - return -} - -func NewFoo() (_swig_ret Foo) { - return _swig_wrap_new_Foo() -} - -var _wrap_delete_Foo unsafe.Pointer - -func _swig_wrap_delete_Foo(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Foo, _swig_p) - return -} - -func DeleteFoo(arg1 Foo) { - _swig_wrap_delete_Foo(arg1.Swigcptr()) -} - -type Foo interface { - Swigcptr() uintptr - SwigIsFoo() - SetEnumvar(arg2 int) - GetEnumvar() (_swig_ret int) - SetFoovar(arg2 int) - GetFoovar() (_swig_ret int) - SetFptr(arg2 _swig_fnptr) - GetFptr() (_swig_ret _swig_fnptr) -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/typedef_typedef.go b/Examples/test-suite/go/typedef_typedef.go deleted file mode 100644 index 785751e09..000000000 --- a/Examples/test-suite/go/typedef_typedef.go +++ /dev/null @@ -1,164 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../typedef_typedef.i - -package typedef_typedef - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrA uintptr - -func (p SwigcptrA) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrA) SwigIsA() { -} - -var _wrap_new_A unsafe.Pointer - -func _swig_wrap_new_A() (base SwigcptrA) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_A, _swig_p) - return -} - -func NewA() (_swig_ret A) { - return _swig_wrap_new_A() -} - -var _wrap_delete_A unsafe.Pointer - -func _swig_wrap_delete_A(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_A, _swig_p) - return -} - -func DeleteA(arg1 A) { - _swig_wrap_delete_A(arg1.Swigcptr()) -} - -type A interface { - Swigcptr() uintptr - SwigIsA() -} - -type SwigcptrC uintptr - -func (p SwigcptrC) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrC) SwigIsC() { -} - -var _wrap_new_C unsafe.Pointer - -func _swig_wrap_new_C() (base SwigcptrC) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_C, _swig_p) - return -} - -func NewC() (_swig_ret C) { - return _swig_wrap_new_C() -} - -var _wrap_delete_C unsafe.Pointer - -func _swig_wrap_delete_C(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_C, _swig_p) - return -} - -func DeleteC(arg1 C) { - _swig_wrap_delete_C(arg1.Swigcptr()) -} - -type C interface { - Swigcptr() uintptr - SwigIsC() -} - -type SwigcptrB uintptr - -func (p SwigcptrB) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrB) SwigIsB() { -} - -var _wrap_B_getValue unsafe.Pointer - -func _swig_wrap_B_getValue(base SwigcptrB, _ int) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_B_getValue, _swig_p) - return -} - -func (arg1 SwigcptrB) GetValue(arg2 int) (_swig_ret int) { - return _swig_wrap_B_getValue(arg1, arg2) -} - -var _wrap_new_B unsafe.Pointer - -func _swig_wrap_new_B() (base SwigcptrB) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_B, _swig_p) - return -} - -func NewB() (_swig_ret B) { - return _swig_wrap_new_B() -} - -var _wrap_delete_B unsafe.Pointer - -func _swig_wrap_delete_B(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_B, _swig_p) - return -} - -func DeleteB(arg1 B) { - _swig_wrap_delete_B(arg1.Swigcptr()) -} - -type B interface { - Swigcptr() uintptr - SwigIsB() - GetValue(arg2 int) (_swig_ret int) -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/typemap_array_qualifiers.go b/Examples/test-suite/go/typemap_array_qualifiers.go deleted file mode 100644 index f73b4fb00..000000000 --- a/Examples/test-suite/go/typemap_array_qualifiers.go +++ /dev/null @@ -1,185 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../typemap_array_qualifiers.i - -package typemap_array_qualifiers - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrSomeType uintptr - -func (p SwigcptrSomeType) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrSomeType) SwigIsSomeType() { -} - -var _wrap_SomeType_a_set unsafe.Pointer - -func _swig_wrap_SomeType_a_set(base SwigcptrSomeType, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_SomeType_a_set, _swig_p) - return -} - -func (arg1 SwigcptrSomeType) SetA(arg2 int) { - _swig_wrap_SomeType_a_set(arg1, arg2) -} - -var _wrap_SomeType_a_get unsafe.Pointer - -func _swig_wrap_SomeType_a_get(base SwigcptrSomeType) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_SomeType_a_get, _swig_p) - return -} - -func (arg1 SwigcptrSomeType) GetA() (_swig_ret int) { - return _swig_wrap_SomeType_a_get(arg1) -} - -var _wrap_new_SomeType unsafe.Pointer - -func _swig_wrap_new_SomeType() (base SwigcptrSomeType) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_SomeType, _swig_p) - return -} - -func NewSomeType() (_swig_ret SomeType) { - return _swig_wrap_new_SomeType() -} - -var _wrap_delete_SomeType unsafe.Pointer - -func _swig_wrap_delete_SomeType(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_SomeType, _swig_p) - return -} - -func DeleteSomeType(arg1 SomeType) { - _swig_wrap_delete_SomeType(arg1.Swigcptr()) -} - -type SomeType interface { - Swigcptr() uintptr - SwigIsSomeType() - SetA(arg2 int) - GetA() (_swig_ret int) -} - -var _wrap_func1a unsafe.Pointer - -func _swig_wrap_func1a(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_func1a, _swig_p) - return -} - -func Func1a(arg1 SomeType) { - _swig_wrap_func1a(arg1.Swigcptr()) -} - -var _wrap_func1b unsafe.Pointer - -func _swig_wrap_func1b(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_func1b, _swig_p) - return -} - -func Func1b(arg1 SomeType) { - _swig_wrap_func1b(arg1.Swigcptr()) -} - -var _wrap_func2a unsafe.Pointer - -func _swig_wrap_func2a(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_func2a, _swig_p) - return -} - -func Func2a(arg1 SomeType) { - _swig_wrap_func2a(arg1.Swigcptr()) -} - -var _wrap_func2b unsafe.Pointer - -func _swig_wrap_func2b(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_func2b, _swig_p) - return -} - -func Func2b(arg1 SomeType) { - _swig_wrap_func2b(arg1.Swigcptr()) -} - -var _wrap_func2c unsafe.Pointer - -func _swig_wrap_func2c(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_func2c, _swig_p) - return -} - -func Func2c(arg1 SomeType) { - _swig_wrap_func2c(arg1.Swigcptr()) -} - -var _wrap_func3a unsafe.Pointer - -func _swig_wrap_func3a(base uintptr, _ *uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_func3a, _swig_p) - return -} - -func Func3a(arg1 uintptr, arg2 *uintptr) { - _swig_wrap_func3a(arg1, arg2) -} - -var _wrap_func4a unsafe.Pointer - -func _swig_wrap_func4a(base *_swig_fnptr, _ *_swig_fnptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_func4a, _swig_p) - return -} - -func Func4a(arg1 *_swig_fnptr, arg2 *_swig_fnptr) { - _swig_wrap_func4a(arg1, arg2) -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/typemap_arrays.go b/Examples/test-suite/go/typemap_arrays.go deleted file mode 100644 index 65162cff7..000000000 --- a/Examples/test-suite/go/typemap_arrays.go +++ /dev/null @@ -1,36 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../typemap_arrays.i - -package typemap_arrays - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -var _wrap_sumA unsafe.Pointer - -func SumA(arg1 **int) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_sumA, _swig_p) - return -} - diff --git a/Examples/test-suite/go/typemap_delete.go b/Examples/test-suite/go/typemap_delete.go deleted file mode 100644 index a85164280..000000000 --- a/Examples/test-suite/go/typemap_delete.go +++ /dev/null @@ -1,101 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../typemap_delete.i - -package typemap_delete - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrRect uintptr - -func (p SwigcptrRect) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrRect) SwigIsRect() { -} - -var _wrap_Rect_val_set unsafe.Pointer - -func _swig_wrap_Rect_val_set(base SwigcptrRect, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Rect_val_set, _swig_p) - return -} - -func (arg1 SwigcptrRect) SetVal(arg2 int) { - _swig_wrap_Rect_val_set(arg1, arg2) -} - -var _wrap_Rect_val_get unsafe.Pointer - -func _swig_wrap_Rect_val_get(base SwigcptrRect) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Rect_val_get, _swig_p) - return -} - -func (arg1 SwigcptrRect) GetVal() (_swig_ret int) { - return _swig_wrap_Rect_val_get(arg1) -} - -var _wrap_new_Rect unsafe.Pointer - -func _swig_wrap_new_Rect(base int) (_ SwigcptrRect) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Rect, _swig_p) - return -} - -func NewRect(arg1 int) (_swig_ret Rect) { - return _swig_wrap_new_Rect(arg1) -} - -var _wrap_delete_Rect unsafe.Pointer - -func _swig_wrap_delete_Rect(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Rect, _swig_p) - return -} - -func DeleteRect(arg1 Rect) { - _swig_wrap_delete_Rect(arg1.Swigcptr()) -} - -type Rect interface { - Swigcptr() uintptr - SwigIsRect() - SetVal(arg2 int) - GetVal() (_swig_ret int) -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/typemap_directorout.go b/Examples/test-suite/go/typemap_directorout.go deleted file mode 100644 index fab73f127..000000000 --- a/Examples/test-suite/go/typemap_directorout.go +++ /dev/null @@ -1,304 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../typemap_directorout.i - -package typemap_directorout - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type _swig_DirectorClass1 struct { - SwigcptrClass1 - v interface{} -} - -func (p *_swig_DirectorClass1) Swigcptr() uintptr { - return p.SwigcptrClass1.Swigcptr() -} - -func (p *_swig_DirectorClass1) SwigIsClass1() { -} - -func (p *_swig_DirectorClass1) DirectorInterface() interface{} { - return p.v -} - -var _wrap__swig_NewDirectorClass1Class1 unsafe.Pointer - -func _swig_NewDirectorClass1Class1(_swig_director *_swig_DirectorClass1) (_swig_ret SwigcptrClass1) { - _swig_p := uintptr(unsafe.Pointer(&_swig_director)) - _cgo_runtime_cgocall(_wrap__swig_NewDirectorClass1Class1, _swig_p) - return -} - -func NewDirectorClass1(v interface{}) Class1 { - p := &_swig_DirectorClass1{0, v} - p.SwigcptrClass1 = _swig_NewDirectorClass1Class1(p) - return p -} - -type _swig_DirectorInterfaceClass1Foo1 interface { - Foo1() *int -} - -var _wrap__swig_DirectorClass1_upcall_Foo1 unsafe.Pointer - -func _swig_wrap__swig_DirectorClass1_upcall_Foo1(_swig_ptr SwigcptrClass1) (_swig_ret *int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) - _cgo_runtime_cgocall(_wrap__swig_DirectorClass1_upcall_Foo1, _swig_p) - return -} - -func (swig_p *_swig_DirectorClass1) Foo1() *int { - if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceClass1Foo1); swig_ok { - return swig_g.Foo1() - } - var swig_r *int - swig_r = _swig_wrap__swig_DirectorClass1_upcall_Foo1(swig_p.SwigcptrClass1) - return swig_r -} - -func DirectorClass1Foo1(p Class1) *int { - var swig_r *int - swig_r = _swig_wrap__swig_DirectorClass1_upcall_Foo1(p.(*_swig_DirectorClass1).SwigcptrClass1) - return swig_r -} - -func Swig_DirectorClass1_callback_foo1(p *_swig_DirectorClass1) (swig_result *int) { - var swig_r *int - swig_r = p.Foo1() - return swig_r -} - -type _swig_DirectorInterfaceClass1Foo2__SWIG_0 interface { - Foo2__SWIG_0(int) *int -} - -var _wrap__swig_DirectorClass1_upcall_Foo2__SWIG_0 unsafe.Pointer - -func _swig_wrap__swig_DirectorClass1_upcall_Foo2__SWIG_0(_swig_ptr SwigcptrClass1, _ int) (_swig_ret *int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) - _cgo_runtime_cgocall(_wrap__swig_DirectorClass1_upcall_Foo2__SWIG_0, _swig_p) - return -} - -func (swig_p *_swig_DirectorClass1) Foo2__SWIG_0(parm1 int) *int { - if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceClass1Foo2__SWIG_0); swig_ok { - return swig_g.Foo2__SWIG_0(parm1) - } - var swig_r *int - swig_r = _swig_wrap__swig_DirectorClass1_upcall_Foo2__SWIG_0(swig_p.SwigcptrClass1, parm1) - return swig_r -} - -func DirectorClass1Foo2__SWIG_0(p Class1, arg2 int) *int { - var swig_r *int - swig_r = _swig_wrap__swig_DirectorClass1_upcall_Foo2__SWIG_0(p.(*_swig_DirectorClass1).SwigcptrClass1, arg2) - return swig_r -} - -func Swig_DirectorClass1_callback_foo2__SWIG_0(p *_swig_DirectorClass1, arg2 int) (swig_result *int) { - var swig_r *int - swig_r = p.Foo2__SWIG_0(arg2) - return swig_r -} - -type _swig_DirectorInterfaceClass1Foo2__SWIG_1 interface { - Foo2__SWIG_1() *int -} - -var _wrap__swig_DirectorClass1_upcall_Foo2__SWIG_1 unsafe.Pointer - -func _swig_wrap__swig_DirectorClass1_upcall_Foo2__SWIG_1(_swig_ptr SwigcptrClass1) (_swig_ret *int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ptr)) - _cgo_runtime_cgocall(_wrap__swig_DirectorClass1_upcall_Foo2__SWIG_1, _swig_p) - return -} - -func (swig_p *_swig_DirectorClass1) Foo2__SWIG_1() *int { - if swig_g, swig_ok := swig_p.v.(_swig_DirectorInterfaceClass1Foo2__SWIG_1); swig_ok { - return swig_g.Foo2__SWIG_1() - } - var swig_r *int - swig_r = _swig_wrap__swig_DirectorClass1_upcall_Foo2__SWIG_1(swig_p.SwigcptrClass1) - return swig_r -} - -func DirectorClass1Foo2__SWIG_1(p Class1) *int { - var swig_r *int - swig_r = _swig_wrap__swig_DirectorClass1_upcall_Foo2__SWIG_1(p.(*_swig_DirectorClass1).SwigcptrClass1) - return swig_r -} - -func Swig_DirectorClass1_callback_foo2__SWIG_1(p *_swig_DirectorClass1) (swig_result *int) { - var swig_r *int - swig_r = p.Foo2__SWIG_1() - return swig_r -} - -func (p _swig_DirectorClass1) Foo2(a ...interface{}) *int { - argc := len(a) - if argc == 0 { - return p.Foo2__SWIG_1() - } - if argc == 1 { - return p.Foo2__SWIG_0(a[0].(int)) - } - panic("No match for overloaded function call") -} - -func DirectorClass1Foo2(p *_swig_DirectorClass1, a ...interface{}) *int { - argc := len(a) - if argc == 0 { - return DirectorClass1Foo2__SWIG_1(p) - } - if argc == 1 { - return DirectorClass1Foo2__SWIG_0(p, a[0].(int)) - } - panic("No match for overloaded function call") -} - -var _wrap_DeleteDirectorClass1 unsafe.Pointer - -func _swig_wrap_DeleteDirectorClass1(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_DeleteDirectorClass1, _swig_p) - return -} - -func DeleteDirectorClass1(arg1 Class1) { - _swig_wrap_DeleteDirectorClass1(arg1.Swigcptr()) -} - -func Swiggo_DeleteDirector_Class1(p *_swig_DirectorClass1) { - p.SwigcptrClass1 = 0 -} - -type SwigcptrClass1 uintptr - -func (p SwigcptrClass1) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrClass1) SwigIsClass1() { -} - -func (p SwigcptrClass1) DirectorInterface() interface{} { - return nil -} - -var _wrap_new_Class1 unsafe.Pointer - -func _swig_wrap_new_Class1() (base SwigcptrClass1) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Class1, _swig_p) - return -} - -func NewClass1() (_swig_ret Class1) { - return _swig_wrap_new_Class1() -} - -var _wrap_Class1_foo1 unsafe.Pointer - -func _swig_wrap_Class1_foo1(base SwigcptrClass1) (_ *int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Class1_foo1, _swig_p) - return -} - -func (arg1 SwigcptrClass1) Foo1() (_swig_ret *int) { - return _swig_wrap_Class1_foo1(arg1) -} - -var _wrap_Class1_foo2__SWIG_0 unsafe.Pointer - -func _swig_wrap_Class1_foo2__SWIG_0(base SwigcptrClass1, _ int) (_ *int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Class1_foo2__SWIG_0, _swig_p) - return -} - -func (arg1 SwigcptrClass1) Foo2__SWIG_0(arg2 int) (_swig_ret *int) { - return _swig_wrap_Class1_foo2__SWIG_0(arg1, arg2) -} - -var _wrap_Class1_foo2__SWIG_1 unsafe.Pointer - -func _swig_wrap_Class1_foo2__SWIG_1(base SwigcptrClass1) (_ *int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Class1_foo2__SWIG_1, _swig_p) - return -} - -func (arg1 SwigcptrClass1) Foo2__SWIG_1() (_swig_ret *int) { - return _swig_wrap_Class1_foo2__SWIG_1(arg1) -} - -func (p SwigcptrClass1) Foo2(a ...interface{}) *int { - argc := len(a) - if argc == 0 { - return p.Foo2__SWIG_1() - } - if argc == 1 { - return p.Foo2__SWIG_0(a[0].(int)) - } - panic("No match for overloaded function call") -} - -var _wrap_delete_Class1 unsafe.Pointer - -func _swig_wrap_delete_Class1(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Class1, _swig_p) - return -} - -func DeleteClass1(arg1 Class1) { - _swig_wrap_delete_Class1(arg1.Swigcptr()) -} - -type Class1 interface { - Swigcptr() uintptr - SwigIsClass1() - DirectorInterface() interface{} - Foo1() (_swig_ret *int) - Foo2(a ...interface{}) *int -} - - -type SwigcptrSwigDirector_Class1 uintptr -type SwigDirector_Class1 interface { - Swigcptr() uintptr; -} -func (p SwigcptrSwigDirector_Class1) Swigcptr() uintptr { - return uintptr(p) -} - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/typemap_directorout_wrap.h b/Examples/test-suite/go/typemap_directorout_wrap.h deleted file mode 100644 index 52a0d06c1..000000000 --- a/Examples/test-suite/go/typemap_directorout_wrap.h +++ /dev/null @@ -1,37 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../typemap_directorout.i - -#ifndef SWIG_typemap_directorout_WRAP_H_ -#define SWIG_typemap_directorout_WRAP_H_ - -class SwigDirector_Class1 : public Class1 -{ - public: - SwigDirector_Class1(void *swig_p); - MyType &_swig_upcall_foo1() { - return Class1::foo1(); - } - virtual MyType &foo1(); - MyType &_swig_upcall_foo2__SWIG_0(int parm1) { - return Class1::foo2(parm1); - } - virtual MyType &foo2(int parm1); - MyType &_swig_upcall_foo2__SWIG_1() { - return Class1::foo2(); - } - virtual MyType &foo2(); - virtual ~SwigDirector_Class1(); - private: - void *go_val; -}; - -#endif diff --git a/Examples/test-suite/go/typemap_global_scope.go b/Examples/test-suite/go/typemap_global_scope.go deleted file mode 100644 index 07d124697..000000000 --- a/Examples/test-suite/go/typemap_global_scope.go +++ /dev/null @@ -1,1023 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../typemap_global_scope.i - -package typemap_global_scope - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrTest1 uintptr - -func (p SwigcptrTest1) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrTest1) SwigIsTest1() { -} - -var _wrap_new_Test1 unsafe.Pointer - -func _swig_wrap_new_Test1() (base SwigcptrTest1) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Test1, _swig_p) - return -} - -func NewTest1() (_swig_ret Test1) { - return _swig_wrap_new_Test1() -} - -var _wrap_delete_Test1 unsafe.Pointer - -func _swig_wrap_delete_Test1(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Test1, _swig_p) - return -} - -func DeleteTest1(arg1 Test1) { - _swig_wrap_delete_Test1(arg1.Swigcptr()) -} - -type Test1 interface { - Swigcptr() uintptr - SwigIsTest1() -} - -type SwigcptrTest2 uintptr - -func (p SwigcptrTest2) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrTest2) SwigIsTest2() { -} - -var _wrap_new_Test2 unsafe.Pointer - -func _swig_wrap_new_Test2() (base SwigcptrTest2) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Test2, _swig_p) - return -} - -func NewTest2() (_swig_ret Test2) { - return _swig_wrap_new_Test2() -} - -var _wrap_delete_Test2 unsafe.Pointer - -func _swig_wrap_delete_Test2(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Test2, _swig_p) - return -} - -func DeleteTest2(arg1 Test2) { - _swig_wrap_delete_Test2(arg1.Swigcptr()) -} - -type Test2 interface { - Swigcptr() uintptr - SwigIsTest2() -} - -type SwigcptrTest3 uintptr - -func (p SwigcptrTest3) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrTest3) SwigIsTest3() { -} - -var _wrap_new_Test3 unsafe.Pointer - -func _swig_wrap_new_Test3() (base SwigcptrTest3) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Test3, _swig_p) - return -} - -func NewTest3() (_swig_ret Test3) { - return _swig_wrap_new_Test3() -} - -var _wrap_delete_Test3 unsafe.Pointer - -func _swig_wrap_delete_Test3(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Test3, _swig_p) - return -} - -func DeleteTest3(arg1 Test3) { - _swig_wrap_delete_Test3(arg1.Swigcptr()) -} - -type Test3 interface { - Swigcptr() uintptr - SwigIsTest3() -} - -type SwigcptrTest4 uintptr - -func (p SwigcptrTest4) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrTest4) SwigIsTest4() { -} - -var _wrap_new_Test4 unsafe.Pointer - -func _swig_wrap_new_Test4() (base SwigcptrTest4) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Test4, _swig_p) - return -} - -func NewTest4() (_swig_ret Test4) { - return _swig_wrap_new_Test4() -} - -var _wrap_delete_Test4 unsafe.Pointer - -func _swig_wrap_delete_Test4(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Test4, _swig_p) - return -} - -func DeleteTest4(arg1 Test4) { - _swig_wrap_delete_Test4(arg1.Swigcptr()) -} - -type Test4 interface { - Swigcptr() uintptr - SwigIsTest4() -} - -var _wrap_test1a unsafe.Pointer - -func _swig_wrap_test1a(base uintptr, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_test1a, _swig_p) - return -} - -func Test1a(arg1 Test1, arg2 Test1) { - _swig_wrap_test1a(arg1.Swigcptr(), arg2.Swigcptr()) -} - -var _wrap_test1b unsafe.Pointer - -func _swig_wrap_test1b(base uintptr, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_test1b, _swig_p) - return -} - -func Test1b(arg1 Test1, arg2 Test1) { - _swig_wrap_test1b(arg1.Swigcptr(), arg2.Swigcptr()) -} - -var _wrap_test2a unsafe.Pointer - -func _swig_wrap_test2a(base uintptr, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_test2a, _swig_p) - return -} - -func Test2a(arg1 Test2, arg2 Test2) { - _swig_wrap_test2a(arg1.Swigcptr(), arg2.Swigcptr()) -} - -var _wrap_test2b unsafe.Pointer - -func _swig_wrap_test2b(base uintptr, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_test2b, _swig_p) - return -} - -func Test2b(arg1 Test2, arg2 Test2) { - _swig_wrap_test2b(arg1.Swigcptr(), arg2.Swigcptr()) -} - -var _wrap_test3a unsafe.Pointer - -func _swig_wrap_test3a(base uintptr, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_test3a, _swig_p) - return -} - -func Test3a(arg1 Test3, arg2 Test3) { - _swig_wrap_test3a(arg1.Swigcptr(), arg2.Swigcptr()) -} - -var _wrap_test3b unsafe.Pointer - -func _swig_wrap_test3b(base uintptr, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_test3b, _swig_p) - return -} - -func Test3b(arg1 Test3, arg2 Test3) { - _swig_wrap_test3b(arg1.Swigcptr(), arg2.Swigcptr()) -} - -var _wrap_test3c unsafe.Pointer - -func _swig_wrap_test3c(base uintptr, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_test3c, _swig_p) - return -} - -func Test3c(arg1 Test3, arg2 Test3) { - _swig_wrap_test3c(arg1.Swigcptr(), arg2.Swigcptr()) -} - -var _wrap_test3d unsafe.Pointer - -func _swig_wrap_test3d(base uintptr, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_test3d, _swig_p) - return -} - -func Test3d(arg1 Test3, arg2 Test3) { - _swig_wrap_test3d(arg1.Swigcptr(), arg2.Swigcptr()) -} - -var _wrap_test3e unsafe.Pointer - -func _swig_wrap_test3e(base uintptr, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_test3e, _swig_p) - return -} - -func Test3e(arg1 Test3, arg2 Test3) { - _swig_wrap_test3e(arg1.Swigcptr(), arg2.Swigcptr()) -} - -var _wrap_test4a unsafe.Pointer - -func _swig_wrap_test4a(base uintptr, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_test4a, _swig_p) - return -} - -func Test4a(arg1 Test4, arg2 Test4) { - _swig_wrap_test4a(arg1.Swigcptr(), arg2.Swigcptr()) -} - -var _wrap_test4b unsafe.Pointer - -func _swig_wrap_test4b(base uintptr, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_test4b, _swig_p) - return -} - -func Test4b(arg1 Test4, arg2 Test4) { - _swig_wrap_test4b(arg1.Swigcptr(), arg2.Swigcptr()) -} - -var _wrap_test4c unsafe.Pointer - -func _swig_wrap_test4c(base uintptr, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_test4c, _swig_p) - return -} - -func Test4c(arg1 Test4, arg2 Test4) { - _swig_wrap_test4c(arg1.Swigcptr(), arg2.Swigcptr()) -} - -var _wrap_test4d unsafe.Pointer - -func _swig_wrap_test4d(base uintptr, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_test4d, _swig_p) - return -} - -func Test4d(arg1 Test4, arg2 Test4) { - _swig_wrap_test4d(arg1.Swigcptr(), arg2.Swigcptr()) -} - -var _wrap_test4e unsafe.Pointer - -func _swig_wrap_test4e(base uintptr, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_test4e, _swig_p) - return -} - -func Test4e(arg1 Test4, arg2 Test4) { - _swig_wrap_test4e(arg1.Swigcptr(), arg2.Swigcptr()) -} - -type SwigcptrXX uintptr - -func (p SwigcptrXX) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrXX) SwigIsXX() { -} - -var _wrap_new_XX unsafe.Pointer - -func _swig_wrap_new_XX() (base SwigcptrXX) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_XX, _swig_p) - return -} - -func NewXX() (_swig_ret XX) { - return _swig_wrap_new_XX() -} - -var _wrap_delete_XX unsafe.Pointer - -func _swig_wrap_delete_XX(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_XX, _swig_p) - return -} - -func DeleteXX(arg1 XX) { - _swig_wrap_delete_XX(arg1.Swigcptr()) -} - -type XX interface { - Swigcptr() uintptr - SwigIsXX() -} - -type SwigcptrTemplateTest1XX uintptr - -func (p SwigcptrTemplateTest1XX) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrTemplateTest1XX) SwigIsTemplateTest1XX() { -} - -var _wrap_TemplateTest1XX_m_t_set unsafe.Pointer - -func _swig_wrap_TemplateTest1XX_m_t_set(base SwigcptrTemplateTest1XX, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_TemplateTest1XX_m_t_set, _swig_p) - return -} - -func (arg1 SwigcptrTemplateTest1XX) SetM_t(arg2 XX) { - _swig_wrap_TemplateTest1XX_m_t_set(arg1, arg2.Swigcptr()) -} - -var _wrap_TemplateTest1XX_m_t_get unsafe.Pointer - -func _swig_wrap_TemplateTest1XX_m_t_get(base SwigcptrTemplateTest1XX) (_ SwigcptrXX) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_TemplateTest1XX_m_t_get, _swig_p) - return -} - -func (arg1 SwigcptrTemplateTest1XX) GetM_t() (_swig_ret XX) { - return _swig_wrap_TemplateTest1XX_m_t_get(arg1) -} - -var _wrap_new_TemplateTest1XX unsafe.Pointer - -func _swig_wrap_new_TemplateTest1XX() (base SwigcptrTemplateTest1XX) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_TemplateTest1XX, _swig_p) - return -} - -func NewTemplateTest1XX() (_swig_ret TemplateTest1XX) { - return _swig_wrap_new_TemplateTest1XX() -} - -var _wrap_delete_TemplateTest1XX unsafe.Pointer - -func _swig_wrap_delete_TemplateTest1XX(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_TemplateTest1XX, _swig_p) - return -} - -func DeleteTemplateTest1XX(arg1 TemplateTest1XX) { - _swig_wrap_delete_TemplateTest1XX(arg1.Swigcptr()) -} - -type TemplateTest1XX interface { - Swigcptr() uintptr - SwigIsTemplateTest1XX() - SetM_t(arg2 XX) - GetM_t() (_swig_ret XX) -} - -type SwigcptrTemplateTest2XX uintptr - -func (p SwigcptrTemplateTest2XX) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrTemplateTest2XX) SwigIsTemplateTest2XX() { -} - -var _wrap_TemplateTest2XX_m_t_set unsafe.Pointer - -func _swig_wrap_TemplateTest2XX_m_t_set(base SwigcptrTemplateTest2XX, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_TemplateTest2XX_m_t_set, _swig_p) - return -} - -func (arg1 SwigcptrTemplateTest2XX) SetM_t(arg2 XX) { - _swig_wrap_TemplateTest2XX_m_t_set(arg1, arg2.Swigcptr()) -} - -var _wrap_TemplateTest2XX_m_t_get unsafe.Pointer - -func _swig_wrap_TemplateTest2XX_m_t_get(base SwigcptrTemplateTest2XX) (_ SwigcptrXX) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_TemplateTest2XX_m_t_get, _swig_p) - return -} - -func (arg1 SwigcptrTemplateTest2XX) GetM_t() (_swig_ret XX) { - return _swig_wrap_TemplateTest2XX_m_t_get(arg1) -} - -var _wrap_new_TemplateTest2XX unsafe.Pointer - -func _swig_wrap_new_TemplateTest2XX() (base SwigcptrTemplateTest2XX) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_TemplateTest2XX, _swig_p) - return -} - -func NewTemplateTest2XX() (_swig_ret TemplateTest2XX) { - return _swig_wrap_new_TemplateTest2XX() -} - -var _wrap_delete_TemplateTest2XX unsafe.Pointer - -func _swig_wrap_delete_TemplateTest2XX(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_TemplateTest2XX, _swig_p) - return -} - -func DeleteTemplateTest2XX(arg1 TemplateTest2XX) { - _swig_wrap_delete_TemplateTest2XX(arg1.Swigcptr()) -} - -type TemplateTest2XX interface { - Swigcptr() uintptr - SwigIsTemplateTest2XX() - SetM_t(arg2 XX) - GetM_t() (_swig_ret XX) -} - -type SwigcptrTemplateTest3XX uintptr - -func (p SwigcptrTemplateTest3XX) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrTemplateTest3XX) SwigIsTemplateTest3XX() { -} - -var _wrap_TemplateTest3XX_m_t_set unsafe.Pointer - -func _swig_wrap_TemplateTest3XX_m_t_set(base SwigcptrTemplateTest3XX, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_TemplateTest3XX_m_t_set, _swig_p) - return -} - -func (arg1 SwigcptrTemplateTest3XX) SetM_t(arg2 XX) { - _swig_wrap_TemplateTest3XX_m_t_set(arg1, arg2.Swigcptr()) -} - -var _wrap_TemplateTest3XX_m_t_get unsafe.Pointer - -func _swig_wrap_TemplateTest3XX_m_t_get(base SwigcptrTemplateTest3XX) (_ SwigcptrXX) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_TemplateTest3XX_m_t_get, _swig_p) - return -} - -func (arg1 SwigcptrTemplateTest3XX) GetM_t() (_swig_ret XX) { - return _swig_wrap_TemplateTest3XX_m_t_get(arg1) -} - -var _wrap_new_TemplateTest3XX unsafe.Pointer - -func _swig_wrap_new_TemplateTest3XX() (base SwigcptrTemplateTest3XX) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_TemplateTest3XX, _swig_p) - return -} - -func NewTemplateTest3XX() (_swig_ret TemplateTest3XX) { - return _swig_wrap_new_TemplateTest3XX() -} - -var _wrap_delete_TemplateTest3XX unsafe.Pointer - -func _swig_wrap_delete_TemplateTest3XX(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_TemplateTest3XX, _swig_p) - return -} - -func DeleteTemplateTest3XX(arg1 TemplateTest3XX) { - _swig_wrap_delete_TemplateTest3XX(arg1.Swigcptr()) -} - -type TemplateTest3XX interface { - Swigcptr() uintptr - SwigIsTemplateTest3XX() - SetM_t(arg2 XX) - GetM_t() (_swig_ret XX) -} - -type SwigcptrTemplateTest4XX uintptr - -func (p SwigcptrTemplateTest4XX) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrTemplateTest4XX) SwigIsTemplateTest4XX() { -} - -var _wrap_TemplateTest4XX_m_t_set unsafe.Pointer - -func _swig_wrap_TemplateTest4XX_m_t_set(base SwigcptrTemplateTest4XX, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_TemplateTest4XX_m_t_set, _swig_p) - return -} - -func (arg1 SwigcptrTemplateTest4XX) SetM_t(arg2 XX) { - _swig_wrap_TemplateTest4XX_m_t_set(arg1, arg2.Swigcptr()) -} - -var _wrap_TemplateTest4XX_m_t_get unsafe.Pointer - -func _swig_wrap_TemplateTest4XX_m_t_get(base SwigcptrTemplateTest4XX) (_ SwigcptrXX) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_TemplateTest4XX_m_t_get, _swig_p) - return -} - -func (arg1 SwigcptrTemplateTest4XX) GetM_t() (_swig_ret XX) { - return _swig_wrap_TemplateTest4XX_m_t_get(arg1) -} - -var _wrap_new_TemplateTest4XX unsafe.Pointer - -func _swig_wrap_new_TemplateTest4XX() (base SwigcptrTemplateTest4XX) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_TemplateTest4XX, _swig_p) - return -} - -func NewTemplateTest4XX() (_swig_ret TemplateTest4XX) { - return _swig_wrap_new_TemplateTest4XX() -} - -var _wrap_delete_TemplateTest4XX unsafe.Pointer - -func _swig_wrap_delete_TemplateTest4XX(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_TemplateTest4XX, _swig_p) - return -} - -func DeleteTemplateTest4XX(arg1 TemplateTest4XX) { - _swig_wrap_delete_TemplateTest4XX(arg1.Swigcptr()) -} - -type TemplateTest4XX interface { - Swigcptr() uintptr - SwigIsTemplateTest4XX() - SetM_t(arg2 XX) - GetM_t() (_swig_ret XX) -} - -var _wrap_test_template_1a unsafe.Pointer - -func _swig_wrap_test_template_1a(base uintptr, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_test_template_1a, _swig_p) - return -} - -func Test_template_1a(arg1 TemplateTest1XX, arg2 TemplateTest1XX) { - _swig_wrap_test_template_1a(arg1.Swigcptr(), arg2.Swigcptr()) -} - -var _wrap_test_template_1b unsafe.Pointer - -func _swig_wrap_test_template_1b(base uintptr, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_test_template_1b, _swig_p) - return -} - -func Test_template_1b(arg1 TemplateTest1XX, arg2 TemplateTest1XX) { - _swig_wrap_test_template_1b(arg1.Swigcptr(), arg2.Swigcptr()) -} - -var _wrap_test_template_2a unsafe.Pointer - -func _swig_wrap_test_template_2a(base uintptr, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_test_template_2a, _swig_p) - return -} - -func Test_template_2a(arg1 TemplateTest2XX, arg2 TemplateTest2XX) { - _swig_wrap_test_template_2a(arg1.Swigcptr(), arg2.Swigcptr()) -} - -var _wrap_test_template_2b unsafe.Pointer - -func _swig_wrap_test_template_2b(base uintptr, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_test_template_2b, _swig_p) - return -} - -func Test_template_2b(arg1 TemplateTest2XX, arg2 TemplateTest2XX) { - _swig_wrap_test_template_2b(arg1.Swigcptr(), arg2.Swigcptr()) -} - -var _wrap_test_template_3a unsafe.Pointer - -func _swig_wrap_test_template_3a(base uintptr, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_test_template_3a, _swig_p) - return -} - -func Test_template_3a(arg1 TemplateTest3XX, arg2 TemplateTest3XX) { - _swig_wrap_test_template_3a(arg1.Swigcptr(), arg2.Swigcptr()) -} - -var _wrap_test_template_3b unsafe.Pointer - -func _swig_wrap_test_template_3b(base uintptr, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_test_template_3b, _swig_p) - return -} - -func Test_template_3b(arg1 TemplateTest3XX, arg2 TemplateTest3XX) { - _swig_wrap_test_template_3b(arg1.Swigcptr(), arg2.Swigcptr()) -} - -var _wrap_test_template_3c unsafe.Pointer - -func _swig_wrap_test_template_3c(base uintptr, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_test_template_3c, _swig_p) - return -} - -func Test_template_3c(arg1 TemplateTest3XX, arg2 TemplateTest3XX) { - _swig_wrap_test_template_3c(arg1.Swigcptr(), arg2.Swigcptr()) -} - -var _wrap_test_template_3d unsafe.Pointer - -func _swig_wrap_test_template_3d(base uintptr, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_test_template_3d, _swig_p) - return -} - -func Test_template_3d(arg1 TemplateTest3XX, arg2 TemplateTest3XX) { - _swig_wrap_test_template_3d(arg1.Swigcptr(), arg2.Swigcptr()) -} - -var _wrap_test_template_3e unsafe.Pointer - -func _swig_wrap_test_template_3e(base uintptr, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_test_template_3e, _swig_p) - return -} - -func Test_template_3e(arg1 TemplateTest3XX, arg2 TemplateTest3XX) { - _swig_wrap_test_template_3e(arg1.Swigcptr(), arg2.Swigcptr()) -} - -var _wrap_test_template_4a unsafe.Pointer - -func _swig_wrap_test_template_4a(base uintptr, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_test_template_4a, _swig_p) - return -} - -func Test_template_4a(arg1 TemplateTest4XX, arg2 TemplateTest4XX) { - _swig_wrap_test_template_4a(arg1.Swigcptr(), arg2.Swigcptr()) -} - -var _wrap_test_template_4b unsafe.Pointer - -func _swig_wrap_test_template_4b(base uintptr, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_test_template_4b, _swig_p) - return -} - -func Test_template_4b(arg1 TemplateTest4XX, arg2 TemplateTest4XX) { - _swig_wrap_test_template_4b(arg1.Swigcptr(), arg2.Swigcptr()) -} - -var _wrap_test_template_4c unsafe.Pointer - -func _swig_wrap_test_template_4c(base uintptr, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_test_template_4c, _swig_p) - return -} - -func Test_template_4c(arg1 TemplateTest4XX, arg2 TemplateTest4XX) { - _swig_wrap_test_template_4c(arg1.Swigcptr(), arg2.Swigcptr()) -} - -var _wrap_test_template_4d unsafe.Pointer - -func _swig_wrap_test_template_4d(base uintptr, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_test_template_4d, _swig_p) - return -} - -func Test_template_4d(arg1 TemplateTest4XX, arg2 TemplateTest4XX) { - _swig_wrap_test_template_4d(arg1.Swigcptr(), arg2.Swigcptr()) -} - -var _wrap_test_template_4e unsafe.Pointer - -func _swig_wrap_test_template_4e(base uintptr, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_test_template_4e, _swig_p) - return -} - -func Test_template_4e(arg1 TemplateTest4XX, arg2 TemplateTest4XX) { - _swig_wrap_test_template_4e(arg1.Swigcptr(), arg2.Swigcptr()) -} - -type Enum1 int -var _wrap_enum_1 unsafe.Pointer - -func _swig_getenum_1() (_swig_ret Enum1) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_enum_1, _swig_p) - return -} -var Enum_1 Enum1 = _swig_getenum_1() -type Enum2 int -var _wrap_enum_2 unsafe.Pointer - -func _swig_getenum_2() (_swig_ret Enum2) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_enum_2, _swig_p) - return -} -var Enum_2 Enum2 = _swig_getenum_2() -type SpaceEnum3 int -var _wrap_enum_3 unsafe.Pointer - -func _swig_getenum_3() (_swig_ret SpaceEnum3) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_enum_3, _swig_p) - return -} -var Enum_3 SpaceEnum3 = _swig_getenum_3() -type SpaceEnum4 int -var _wrap_enum_4 unsafe.Pointer - -func _swig_getenum_4() (_swig_ret SpaceEnum4) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_enum_4, _swig_p) - return -} -var Enum_4 SpaceEnum4 = _swig_getenum_4() -var _wrap_test_enum_1a unsafe.Pointer - -func _swig_wrap_test_enum_1a(base Enum1, _ *Enum1) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_test_enum_1a, _swig_p) - return -} - -func Test_enum_1a(arg1 Enum1, arg2 *Enum1) { - _swig_wrap_test_enum_1a(arg1, arg2) -} - -var _wrap_test_enum_1b unsafe.Pointer - -func _swig_wrap_test_enum_1b(base Enum1, _ *Enum1) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_test_enum_1b, _swig_p) - return -} - -func Test_enum_1b(arg1 Enum1, arg2 *Enum1) { - _swig_wrap_test_enum_1b(arg1, arg2) -} - -var _wrap_test_enum_2a unsafe.Pointer - -func _swig_wrap_test_enum_2a(base Enum2, _ *Enum2) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_test_enum_2a, _swig_p) - return -} - -func Test_enum_2a(arg1 Enum2, arg2 *Enum2) { - _swig_wrap_test_enum_2a(arg1, arg2) -} - -var _wrap_test_enum_2b unsafe.Pointer - -func _swig_wrap_test_enum_2b(base Enum2, _ *Enum2) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_test_enum_2b, _swig_p) - return -} - -func Test_enum_2b(arg1 Enum2, arg2 *Enum2) { - _swig_wrap_test_enum_2b(arg1, arg2) -} - -var _wrap_test_enum_3a unsafe.Pointer - -func _swig_wrap_test_enum_3a(base SpaceEnum3, _ *SpaceEnum3) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_test_enum_3a, _swig_p) - return -} - -func Test_enum_3a(arg1 SpaceEnum3, arg2 *SpaceEnum3) { - _swig_wrap_test_enum_3a(arg1, arg2) -} - -var _wrap_test_enum_3b unsafe.Pointer - -func _swig_wrap_test_enum_3b(base SpaceEnum3, _ *SpaceEnum3) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_test_enum_3b, _swig_p) - return -} - -func Test_enum_3b(arg1 SpaceEnum3, arg2 *SpaceEnum3) { - _swig_wrap_test_enum_3b(arg1, arg2) -} - -var _wrap_test_enum_3c unsafe.Pointer - -func _swig_wrap_test_enum_3c(base SpaceEnum3, _ *SpaceEnum3) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_test_enum_3c, _swig_p) - return -} - -func Test_enum_3c(arg1 SpaceEnum3, arg2 *SpaceEnum3) { - _swig_wrap_test_enum_3c(arg1, arg2) -} - -var _wrap_test_enum_3d unsafe.Pointer - -func _swig_wrap_test_enum_3d(base SpaceEnum3, _ *SpaceEnum3) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_test_enum_3d, _swig_p) - return -} - -func Test_enum_3d(arg1 SpaceEnum3, arg2 *SpaceEnum3) { - _swig_wrap_test_enum_3d(arg1, arg2) -} - -var _wrap_test_enum_3e unsafe.Pointer - -func _swig_wrap_test_enum_3e(base SpaceEnum3, _ *SpaceEnum3) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_test_enum_3e, _swig_p) - return -} - -func Test_enum_3e(arg1 SpaceEnum3, arg2 *SpaceEnum3) { - _swig_wrap_test_enum_3e(arg1, arg2) -} - -var _wrap_test_enum_4a unsafe.Pointer - -func _swig_wrap_test_enum_4a(base SpaceEnum4, _ *SpaceEnum4) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_test_enum_4a, _swig_p) - return -} - -func Test_enum_4a(arg1 SpaceEnum4, arg2 *SpaceEnum4) { - _swig_wrap_test_enum_4a(arg1, arg2) -} - -var _wrap_test_enum_4b unsafe.Pointer - -func _swig_wrap_test_enum_4b(base SpaceEnum4, _ *SpaceEnum4) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_test_enum_4b, _swig_p) - return -} - -func Test_enum_4b(arg1 SpaceEnum4, arg2 *SpaceEnum4) { - _swig_wrap_test_enum_4b(arg1, arg2) -} - -var _wrap_test_enum_4c unsafe.Pointer - -func _swig_wrap_test_enum_4c(base SpaceEnum4, _ *SpaceEnum4) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_test_enum_4c, _swig_p) - return -} - -func Test_enum_4c(arg1 SpaceEnum4, arg2 *SpaceEnum4) { - _swig_wrap_test_enum_4c(arg1, arg2) -} - -var _wrap_test_enum_4d unsafe.Pointer - -func _swig_wrap_test_enum_4d(base SpaceEnum4, _ *SpaceEnum4) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_test_enum_4d, _swig_p) - return -} - -func Test_enum_4d(arg1 SpaceEnum4, arg2 *SpaceEnum4) { - _swig_wrap_test_enum_4d(arg1, arg2) -} - -var _wrap_test_enum_4e unsafe.Pointer - -func _swig_wrap_test_enum_4e(base SpaceEnum4, _ *SpaceEnum4) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_test_enum_4e, _swig_p) - return -} - -func Test_enum_4e(arg1 SpaceEnum4, arg2 *SpaceEnum4) { - _swig_wrap_test_enum_4e(arg1, arg2) -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/typemap_manyargs.go b/Examples/test-suite/go/typemap_manyargs.go deleted file mode 100644 index 8bae3e56e..000000000 --- a/Examples/test-suite/go/typemap_manyargs.go +++ /dev/null @@ -1,49 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../typemap_manyargs.i - -package typemap_manyargs - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -var _wrap_my_c_function unsafe.Pointer - -func _swig_wrap_my_c_function(base string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_my_c_function, _swig_p) - return -} - -func My_c_function(arg1 string) { - _swig_wrap_my_c_function(arg1) -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/typemap_namespace.go b/Examples/test-suite/go/typemap_namespace.go deleted file mode 100644 index caec22758..000000000 --- a/Examples/test-suite/go/typemap_namespace.go +++ /dev/null @@ -1,43 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../typemap_namespace.i - -package typemap_namespace - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -var _wrap_test1 unsafe.Pointer - -func Test1(arg1 string) (_swig_ret string) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_test1, _swig_p) - return -} -var _wrap_test2 unsafe.Pointer - -func Test2(arg1 string) (_swig_ret string) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_test2, _swig_p) - return -} - diff --git a/Examples/test-suite/go/typemap_namespace_runme b/Examples/test-suite/go/typemap_namespace_runme deleted file mode 100755 index b4bed3d2b..000000000 Binary files a/Examples/test-suite/go/typemap_namespace_runme and /dev/null differ diff --git a/Examples/test-suite/go/typemap_ns_using.go b/Examples/test-suite/go/typemap_ns_using.go deleted file mode 100644 index 851582b32..000000000 --- a/Examples/test-suite/go/typemap_ns_using.go +++ /dev/null @@ -1,82 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../typemap_ns_using.i - -package typemap_ns_using - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrX_FooImpl uintptr - -func (p SwigcptrX_FooImpl) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrX_FooImpl) SwigIsX_FooImpl() { -} - -var _wrap_new__FooImpl unsafe.Pointer - -func _swig_wrap_new__FooImpl() (base SwigcptrX_FooImpl) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new__FooImpl, _swig_p) - return -} - -func NewX_FooImpl() (_swig_ret X_FooImpl) { - return _swig_wrap_new__FooImpl() -} - -var _wrap_delete__FooImpl unsafe.Pointer - -func _swig_wrap_delete__FooImpl(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete__FooImpl, _swig_p) - return -} - -func DeleteX_FooImpl(arg1 X_FooImpl) { - _swig_wrap_delete__FooImpl(arg1.Swigcptr()) -} - -type X_FooImpl interface { - Swigcptr() uintptr - SwigIsX_FooImpl() -} - -var _wrap_spam unsafe.Pointer - -func Spam(arg1 int) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_spam, _swig_p) - return -} - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/typemap_ns_using_runme b/Examples/test-suite/go/typemap_ns_using_runme deleted file mode 100755 index 7bc202cbe..000000000 Binary files a/Examples/test-suite/go/typemap_ns_using_runme and /dev/null differ diff --git a/Examples/test-suite/go/typemap_numinputs.go b/Examples/test-suite/go/typemap_numinputs.go deleted file mode 100644 index a5314ccfa..000000000 --- a/Examples/test-suite/go/typemap_numinputs.go +++ /dev/null @@ -1,36 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../typemap_numinputs.i - -package typemap_numinputs - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -var _wrap_this_breaks unsafe.Pointer - -func This_breaks(arg1 int, arg2 string, arg3 *int) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_this_breaks, _swig_p) - return -} - diff --git a/Examples/test-suite/go/typemap_out_optimal.go b/Examples/test-suite/go/typemap_out_optimal.go deleted file mode 100644 index 361ee0462..000000000 --- a/Examples/test-suite/go/typemap_out_optimal.go +++ /dev/null @@ -1,148 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../typemap_out_optimal.i - -package typemap_out_optimal - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrXX uintptr - -func (p SwigcptrXX) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrXX) SwigIsXX() { -} - -var _wrap_new_XX__SWIG_0 unsafe.Pointer - -func _swig_wrap_new_XX__SWIG_0() (base SwigcptrXX) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_XX__SWIG_0, _swig_p) - return -} - -func NewXX__SWIG_0() (_swig_ret XX) { - return _swig_wrap_new_XX__SWIG_0() -} - -var _wrap_new_XX__SWIG_1 unsafe.Pointer - -func _swig_wrap_new_XX__SWIG_1(base int) (_ SwigcptrXX) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_XX__SWIG_1, _swig_p) - return -} - -func NewXX__SWIG_1(arg1 int) (_swig_ret XX) { - return _swig_wrap_new_XX__SWIG_1(arg1) -} - -var _wrap_new_XX__SWIG_2 unsafe.Pointer - -func _swig_wrap_new_XX__SWIG_2(base uintptr) (_ SwigcptrXX) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_XX__SWIG_2, _swig_p) - return -} - -func NewXX__SWIG_2(arg1 XX) (_swig_ret XX) { - return _swig_wrap_new_XX__SWIG_2(arg1.Swigcptr()) -} - -func NewXX(a ...interface{}) XX { - argc := len(a) - if argc == 0 { - return NewXX__SWIG_0() - } - if argc == 1 { - if _, ok := a[0].(XX); !ok { - goto check_2 - } - return NewXX__SWIG_2(a[0].(XX)) - } -check_2: - if argc == 1 { - return NewXX__SWIG_1(a[0].(int)) - } - panic("No match for overloaded function call") -} - -var _wrap_delete_XX unsafe.Pointer - -func _swig_wrap_delete_XX(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_XX, _swig_p) - return -} - -func DeleteXX(arg1 XX) { - _swig_wrap_delete_XX(arg1.Swigcptr()) -} - -var _wrap_XX_create unsafe.Pointer - -func _swig_wrap_XX_create() (base SwigcptrXX) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_XX_create, _swig_p) - return -} - -func XXCreate() (_swig_ret XX) { - return _swig_wrap_XX_create() -} - -var _wrap_XX_debug_set unsafe.Pointer - -func _swig_wrap_XX_debug_set(base bool) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_XX_debug_set, _swig_p) - return -} - -func SetXXDebug(arg1 bool) { - _swig_wrap_XX_debug_set(arg1) -} - -var _wrap_XX_debug_get unsafe.Pointer - -func GetXXDebug() (_swig_ret bool) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_XX_debug_get, _swig_p) - return -} -type XX interface { - Swigcptr() uintptr - SwigIsXX() -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/typemap_out_optimal_runme b/Examples/test-suite/go/typemap_out_optimal_runme deleted file mode 100755 index b452264c7..000000000 Binary files a/Examples/test-suite/go/typemap_out_optimal_runme and /dev/null differ diff --git a/Examples/test-suite/go/typemap_qualifier_strip.go b/Examples/test-suite/go/typemap_qualifier_strip.go deleted file mode 100644 index ef57b4d3b..000000000 --- a/Examples/test-suite/go/typemap_qualifier_strip.go +++ /dev/null @@ -1,148 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../typemap_qualifier_strip.i - -package typemap_qualifier_strip - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -var _wrap_create_int unsafe.Pointer - -func Create_int(arg1 int) (_swig_ret *int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_create_int, _swig_p) - return -} -var _wrap_testA1 unsafe.Pointer - -func TestA1(arg1 *int) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_testA1, _swig_p) - return -} -var _wrap_testA2 unsafe.Pointer - -func TestA2(arg1 *int) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_testA2, _swig_p) - return -} -var _wrap_testA3 unsafe.Pointer - -func TestA3(arg1 *int) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_testA3, _swig_p) - return -} -var _wrap_testA4 unsafe.Pointer - -func TestA4(arg1 *int) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_testA4, _swig_p) - return -} -var _wrap_testB1 unsafe.Pointer - -func TestB1(arg1 *int) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_testB1, _swig_p) - return -} -var _wrap_testB2 unsafe.Pointer - -func TestB2(arg1 *int) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_testB2, _swig_p) - return -} -var _wrap_testB3 unsafe.Pointer - -func TestB3(arg1 *int) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_testB3, _swig_p) - return -} -var _wrap_testB4 unsafe.Pointer - -func TestB4(arg1 *int) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_testB4, _swig_p) - return -} -var _wrap_testC1 unsafe.Pointer - -func TestC1(arg1 *int) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_testC1, _swig_p) - return -} -var _wrap_testC2 unsafe.Pointer - -func TestC2(arg1 *int) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_testC2, _swig_p) - return -} -var _wrap_testC3 unsafe.Pointer - -func TestC3(arg1 *int) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_testC3, _swig_p) - return -} -var _wrap_testC4 unsafe.Pointer - -func TestC4(arg1 *int) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_testC4, _swig_p) - return -} -var _wrap_testD1 unsafe.Pointer - -func TestD1(arg1 *int) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_testD1, _swig_p) - return -} -var _wrap_testD2 unsafe.Pointer - -func TestD2(arg1 *int) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_testD2, _swig_p) - return -} -var _wrap_testD3 unsafe.Pointer - -func TestD3(arg1 *int) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_testD3, _swig_p) - return -} -var _wrap_testD4 unsafe.Pointer - -func TestD4(arg1 *int) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_testD4, _swig_p) - return -} - diff --git a/Examples/test-suite/go/typemap_subst.go b/Examples/test-suite/go/typemap_subst.go deleted file mode 100644 index 3f6a6d65a..000000000 --- a/Examples/test-suite/go/typemap_subst.go +++ /dev/null @@ -1,101 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../typemap_subst.i - -package typemap_subst - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrXyzzy uintptr - -func (p SwigcptrXyzzy) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrXyzzy) SwigIsXyzzy() { -} - -var _wrap_xyzzy_member_set unsafe.Pointer - -func _swig_wrap_xyzzy_member_set(base SwigcptrXyzzy, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_xyzzy_member_set, _swig_p) - return -} - -func (arg1 SwigcptrXyzzy) SetMember(arg2 int) { - _swig_wrap_xyzzy_member_set(arg1, arg2) -} - -var _wrap_xyzzy_member_get unsafe.Pointer - -func _swig_wrap_xyzzy_member_get(base SwigcptrXyzzy) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_xyzzy_member_get, _swig_p) - return -} - -func (arg1 SwigcptrXyzzy) GetMember() (_swig_ret int) { - return _swig_wrap_xyzzy_member_get(arg1) -} - -var _wrap_new_xyzzy unsafe.Pointer - -func _swig_wrap_new_xyzzy() (base SwigcptrXyzzy) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_xyzzy, _swig_p) - return -} - -func NewXyzzy() (_swig_ret Xyzzy) { - return _swig_wrap_new_xyzzy() -} - -var _wrap_delete_xyzzy unsafe.Pointer - -func _swig_wrap_delete_xyzzy(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_xyzzy, _swig_p) - return -} - -func DeleteXyzzy(arg1 Xyzzy) { - _swig_wrap_delete_xyzzy(arg1.Swigcptr()) -} - -type Xyzzy interface { - Swigcptr() uintptr - SwigIsXyzzy() - SetMember(arg2 int) - GetMember() (_swig_ret int) -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/typemap_template.go b/Examples/test-suite/go/typemap_template.go deleted file mode 100644 index ac35894b3..000000000 --- a/Examples/test-suite/go/typemap_template.go +++ /dev/null @@ -1,290 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../typemap_template.i - -package typemap_template - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrYY uintptr - -func (p SwigcptrYY) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrYY) SwigIsYY() { -} - -var _wrap_new_YY unsafe.Pointer - -func _swig_wrap_new_YY() (base SwigcptrYY) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_YY, _swig_p) - return -} - -func NewYY() (_swig_ret YY) { - return _swig_wrap_new_YY() -} - -var _wrap_delete_YY unsafe.Pointer - -func _swig_wrap_delete_YY(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_YY, _swig_p) - return -} - -func DeleteYY(arg1 YY) { - _swig_wrap_delete_YY(arg1.Swigcptr()) -} - -type YY interface { - Swigcptr() uintptr - SwigIsYY() -} - -type SwigcptrZZ uintptr - -func (p SwigcptrZZ) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrZZ) SwigIsZZ() { -} - -var _wrap_new_ZZ unsafe.Pointer - -func _swig_wrap_new_ZZ() (base SwigcptrZZ) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_ZZ, _swig_p) - return -} - -func NewZZ() (_swig_ret ZZ) { - return _swig_wrap_new_ZZ() -} - -var _wrap_delete_ZZ unsafe.Pointer - -func _swig_wrap_delete_ZZ(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_ZZ, _swig_p) - return -} - -func DeleteZZ(arg1 ZZ) { - _swig_wrap_delete_ZZ(arg1.Swigcptr()) -} - -type ZZ interface { - Swigcptr() uintptr - SwigIsZZ() -} - -type SwigcptrTTYY uintptr - -func (p SwigcptrTTYY) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrTTYY) SwigIsTTYY() { -} - -var _wrap_TTYY_setT unsafe.Pointer - -func _swig_wrap_TTYY_setT(base SwigcptrTTYY, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_TTYY_setT, _swig_p) - return -} - -func (arg1 SwigcptrTTYY) SetT(arg2 TTYY) { - _swig_wrap_TTYY_setT(arg1, arg2.Swigcptr()) -} - -var _wrap_new_TTYY unsafe.Pointer - -func _swig_wrap_new_TTYY() (base SwigcptrTTYY) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_TTYY, _swig_p) - return -} - -func NewTTYY() (_swig_ret TTYY) { - return _swig_wrap_new_TTYY() -} - -var _wrap_delete_TTYY unsafe.Pointer - -func _swig_wrap_delete_TTYY(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_TTYY, _swig_p) - return -} - -func DeleteTTYY(arg1 TTYY) { - _swig_wrap_delete_TTYY(arg1.Swigcptr()) -} - -type TTYY interface { - Swigcptr() uintptr - SwigIsTTYY() - SetT(arg2 TTYY) -} - -type SwigcptrTTZZ uintptr - -func (p SwigcptrTTZZ) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrTTZZ) SwigIsTTZZ() { -} - -var _wrap_TTZZ_setT unsafe.Pointer - -func _swig_wrap_TTZZ_setT(base SwigcptrTTZZ, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_TTZZ_setT, _swig_p) - return -} - -func (arg1 SwigcptrTTZZ) SetT(arg2 TTZZ) { - _swig_wrap_TTZZ_setT(arg1, arg2.Swigcptr()) -} - -var _wrap_new_TTZZ unsafe.Pointer - -func _swig_wrap_new_TTZZ() (base SwigcptrTTZZ) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_TTZZ, _swig_p) - return -} - -func NewTTZZ() (_swig_ret TTZZ) { - return _swig_wrap_new_TTZZ() -} - -var _wrap_delete_TTZZ unsafe.Pointer - -func _swig_wrap_delete_TTZZ(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_TTZZ, _swig_p) - return -} - -func DeleteTTZZ(arg1 TTZZ) { - _swig_wrap_delete_TTZZ(arg1.Swigcptr()) -} - -type TTZZ interface { - Swigcptr() uintptr - SwigIsTTZZ() - SetT(arg2 TTZZ) -} - -type SwigcptrTTint uintptr - -func (p SwigcptrTTint) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrTTint) SwigIsTTint() { -} - -var _wrap_TTint_setT unsafe.Pointer - -func _swig_wrap_TTint_setT(base SwigcptrTTint, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_TTint_setT, _swig_p) - return -} - -func (arg1 SwigcptrTTint) SetT(arg2 TTint) { - _swig_wrap_TTint_setT(arg1, arg2.Swigcptr()) -} - -var _wrap_new_TTint unsafe.Pointer - -func _swig_wrap_new_TTint() (base SwigcptrTTint) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_TTint, _swig_p) - return -} - -func NewTTint() (_swig_ret TTint) { - return _swig_wrap_new_TTint() -} - -var _wrap_delete_TTint unsafe.Pointer - -func _swig_wrap_delete_TTint(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_TTint, _swig_p) - return -} - -func DeleteTTint(arg1 TTint) { - _swig_wrap_delete_TTint(arg1.Swigcptr()) -} - -type TTint interface { - Swigcptr() uintptr - SwigIsTTint() - SetT(arg2 TTint) -} - -var _wrap_extratest unsafe.Pointer - -func _swig_wrap_extratest(base uintptr, _ uintptr, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_extratest, _swig_p) - return -} - -func Extratest(arg1 TTYY, arg2 TTZZ, arg3 TTint) { - _swig_wrap_extratest(arg1.Swigcptr(), arg2.Swigcptr(), arg3.Swigcptr()) -} - -var _wrap_wasbug unsafe.Pointer - -func _swig_wrap_wasbug(base float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_wasbug, _swig_p) - return -} - -func Wasbug(arg1 float64) { - _swig_wrap_wasbug(arg1) -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/typemap_template_parm_typedef.go b/Examples/test-suite/go/typemap_template_parm_typedef.go deleted file mode 100644 index 4e374d2f1..000000000 --- a/Examples/test-suite/go/typemap_template_parm_typedef.go +++ /dev/null @@ -1,97 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../typemap_template_parm_typedef.i - -package typemap_template_parm_typedef - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -var _wrap_test_no_typedef unsafe.Pointer - -func _swig_wrap_test_no_typedef(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_test_no_typedef, _swig_p) - return -} - -func Test_no_typedef(arg1 Std_list_Sl_unsigned_SS_int_Sg_) { - _swig_wrap_test_no_typedef(arg1.Swigcptr()) -} - -var _wrap_test_typedef unsafe.Pointer - -func _swig_wrap_test_typedef(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_test_typedef, _swig_p) - return -} - -func Test_typedef(arg1 Std_vector_Sl_unsigned_SS_int_Sg_) { - _swig_wrap_test_typedef(arg1.Swigcptr()) -} - -var _wrap_no_typedef_out unsafe.Pointer - -func _swig_wrap_no_typedef_out() (base SwigcptrStd_deque_Sl_unsigned_SS_int_Sg_) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_no_typedef_out, _swig_p) - return -} - -func No_typedef_out() (_swig_ret Std_deque_Sl_unsigned_SS_int_Sg_) { - return _swig_wrap_no_typedef_out() -} - - -type SwigcptrStd_list_Sl_unsigned_SS_int_Sg_ uintptr -type Std_list_Sl_unsigned_SS_int_Sg_ interface { - Swigcptr() uintptr; -} -func (p SwigcptrStd_list_Sl_unsigned_SS_int_Sg_) Swigcptr() uintptr { - return uintptr(p) -} - -type SwigcptrStd_vector_Sl_unsigned_SS_int_Sg_ uintptr -type Std_vector_Sl_unsigned_SS_int_Sg_ interface { - Swigcptr() uintptr; -} -func (p SwigcptrStd_vector_Sl_unsigned_SS_int_Sg_) Swigcptr() uintptr { - return uintptr(p) -} - -type SwigcptrStd_deque_Sl_unsigned_SS_int_Sg_ uintptr -type Std_deque_Sl_unsigned_SS_int_Sg_ interface { - Swigcptr() uintptr; -} -func (p SwigcptrStd_deque_Sl_unsigned_SS_int_Sg_) Swigcptr() uintptr { - return uintptr(p) -} - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/typemap_variables.go b/Examples/test-suite/go/typemap_variables.go deleted file mode 100644 index 6fa825c75..000000000 --- a/Examples/test-suite/go/typemap_variables.go +++ /dev/null @@ -1,158 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../typemap_variables.i - -package typemap_variables - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -var _wrap_globul_set unsafe.Pointer - -func _swig_wrap_globul_set(base int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_globul_set, _swig_p) - return -} - -func SetGlobul(arg1 int) { - _swig_wrap_globul_set(arg1) -} - -var _wrap_globul_get unsafe.Pointer - -func GetGlobul() (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_globul_get, _swig_p) - return -} -var _wrap_nspace_set unsafe.Pointer - -func _swig_wrap_nspace_set(base int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_nspace_set, _swig_p) - return -} - -func SetNspace(arg1 int) { - _swig_wrap_nspace_set(arg1) -} - -var _wrap_nspace_get unsafe.Pointer - -func GetNspace() (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_nspace_get, _swig_p) - return -} -type SwigcptrStruct uintptr - -func (p SwigcptrStruct) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrStruct) SwigIsStruct() { -} - -var _wrap_Struct_member_set unsafe.Pointer - -func _swig_wrap_Struct_member_set(base SwigcptrStruct, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Struct_member_set, _swig_p) - return -} - -func (arg1 SwigcptrStruct) SetMember(arg2 int) { - _swig_wrap_Struct_member_set(arg1, arg2) -} - -var _wrap_Struct_member_get unsafe.Pointer - -func _swig_wrap_Struct_member_get(base SwigcptrStruct) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Struct_member_get, _swig_p) - return -} - -func (arg1 SwigcptrStruct) GetMember() (_swig_ret int) { - return _swig_wrap_Struct_member_get(arg1) -} - -var _wrap_Struct_smember_set unsafe.Pointer - -func _swig_wrap_Struct_smember_set(base int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Struct_smember_set, _swig_p) - return -} - -func SetStructSmember(arg1 int) { - _swig_wrap_Struct_smember_set(arg1) -} - -var _wrap_Struct_smember_get unsafe.Pointer - -func GetStructSmember() (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_Struct_smember_get, _swig_p) - return -} -var _wrap_new_Struct unsafe.Pointer - -func _swig_wrap_new_Struct() (base SwigcptrStruct) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Struct, _swig_p) - return -} - -func NewStruct() (_swig_ret Struct) { - return _swig_wrap_new_Struct() -} - -var _wrap_delete_Struct unsafe.Pointer - -func _swig_wrap_delete_Struct(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Struct, _swig_p) - return -} - -func DeleteStruct(arg1 Struct) { - _swig_wrap_delete_Struct(arg1.Swigcptr()) -} - -type Struct interface { - Swigcptr() uintptr - SwigIsStruct() - SetMember(arg2 int) - GetMember() (_swig_ret int) -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/typemap_various.go b/Examples/test-suite/go/typemap_various.go deleted file mode 100644 index 521380b80..000000000 --- a/Examples/test-suite/go/typemap_various.go +++ /dev/null @@ -1,363 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../typemap_various.i - -package typemap_various - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrFooInt uintptr - -func (p SwigcptrFooInt) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrFooInt) SwigIsFooInt() { -} - -var _wrap_new_FooInt unsafe.Pointer - -func _swig_wrap_new_FooInt() (base SwigcptrFooInt) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_FooInt, _swig_p) - return -} - -func NewFooInt() (_swig_ret FooInt) { - return _swig_wrap_new_FooInt() -} - -var _wrap_delete_FooInt unsafe.Pointer - -func _swig_wrap_delete_FooInt(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_FooInt, _swig_p) - return -} - -func DeleteFooInt(arg1 FooInt) { - _swig_wrap_delete_FooInt(arg1.Swigcptr()) -} - -type FooInt interface { - Swigcptr() uintptr - SwigIsFooInt() -} - -var _wrap_foo1 unsafe.Pointer - -func _swig_wrap_foo1(base uintptr, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_foo1, _swig_p) - return -} - -func Foo1(arg1 FooInt, arg2 FooInt) { - _swig_wrap_foo1(arg1.Swigcptr(), arg2.Swigcptr()) -} - -var _wrap_foo2 unsafe.Pointer - -func _swig_wrap_foo2(base uintptr, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_foo2, _swig_p) - return -} - -func Foo2(arg1 Foo_Sl_short_Sg_, arg2 Foo_Sl_short_Sg_) { - _swig_wrap_foo2(arg1.Swigcptr(), arg2.Swigcptr()) -} - -type SwigcptrBar1 uintptr - -func (p SwigcptrBar1) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrBar1) SwigIsBar1() { -} - -var _wrap_Bar1_foo unsafe.Pointer - -func _swig_wrap_Bar1_foo(base SwigcptrBar1) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Bar1_foo, _swig_p) - return -} - -func (arg1 SwigcptrBar1) Foo() (_swig_ret int) { - return _swig_wrap_Bar1_foo(arg1) -} - -var _wrap_new_Bar1 unsafe.Pointer - -func _swig_wrap_new_Bar1() (base SwigcptrBar1) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Bar1, _swig_p) - return -} - -func NewBar1() (_swig_ret Bar1) { - return _swig_wrap_new_Bar1() -} - -var _wrap_delete_Bar1 unsafe.Pointer - -func _swig_wrap_delete_Bar1(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Bar1, _swig_p) - return -} - -func DeleteBar1(arg1 Bar1) { - _swig_wrap_delete_Bar1(arg1.Swigcptr()) -} - -type Bar1 interface { - Swigcptr() uintptr - SwigIsBar1() - Foo() (_swig_ret int) -} - -type SwigcptrBar2 uintptr - -func (p SwigcptrBar2) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrBar2) SwigIsBar2() { -} - -var _wrap_Bar2_foo unsafe.Pointer - -func _swig_wrap_Bar2_foo(base SwigcptrBar2) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Bar2_foo, _swig_p) - return -} - -func (arg1 SwigcptrBar2) Foo() (_swig_ret int) { - return _swig_wrap_Bar2_foo(arg1) -} - -var _wrap_new_Bar2 unsafe.Pointer - -func _swig_wrap_new_Bar2() (base SwigcptrBar2) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Bar2, _swig_p) - return -} - -func NewBar2() (_swig_ret Bar2) { - return _swig_wrap_new_Bar2() -} - -var _wrap_delete_Bar2 unsafe.Pointer - -func _swig_wrap_delete_Bar2(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Bar2, _swig_p) - return -} - -func DeleteBar2(arg1 Bar2) { - _swig_wrap_delete_Bar2(arg1.Swigcptr()) -} - -type Bar2 interface { - Swigcptr() uintptr - SwigIsBar2() - Foo() (_swig_ret int) -} - -type SwigcptrFFoo uintptr - -func (p SwigcptrFFoo) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrFFoo) SwigIsFFoo() { -} - -var _wrap_FFoo_Bar unsafe.Pointer - -func _swig_wrap_FFoo_Bar(base SwigcptrFFoo, _ bool) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_FFoo_Bar, _swig_p) - return -} - -func (arg1 SwigcptrFFoo) Bar(arg2 bool) (_swig_ret string) { - return _swig_wrap_FFoo_Bar(arg1, arg2) -} - -var _wrap_new_FFoo unsafe.Pointer - -func _swig_wrap_new_FFoo() (base SwigcptrFFoo) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_FFoo, _swig_p) - return -} - -func NewFFoo() (_swig_ret FFoo) { - return _swig_wrap_new_FFoo() -} - -var _wrap_delete_FFoo unsafe.Pointer - -func _swig_wrap_delete_FFoo(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_FFoo, _swig_p) - return -} - -func DeleteFFoo(arg1 FFoo) { - _swig_wrap_delete_FFoo(arg1.Swigcptr()) -} - -type FFoo interface { - Swigcptr() uintptr - SwigIsFFoo() - Bar(arg2 bool) (_swig_ret string) -} - -type SwigcptrABCD uintptr - -func (p SwigcptrABCD) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrABCD) SwigIsABCD() { -} - -var _wrap_ABCD_meth unsafe.Pointer - -func _swig_wrap_ABCD_meth(base SwigcptrABCD) (_ float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_ABCD_meth, _swig_p) - return -} - -func (arg1 SwigcptrABCD) Meth() (_swig_ret float64) { - return _swig_wrap_ABCD_meth(arg1) -} - -var _wrap_ABCD_m1 unsafe.Pointer - -func _swig_wrap_ABCD_m1(base SwigcptrABCD) (_ float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_ABCD_m1, _swig_p) - return -} - -func (arg1 SwigcptrABCD) M1() (_swig_ret float64) { - return _swig_wrap_ABCD_m1(arg1) -} - -var _wrap_ABCD__x2 unsafe.Pointer - -func _swig_wrap_ABCD__x2(base SwigcptrABCD) (_ float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_ABCD__x2, _swig_p) - return -} - -func (arg1 SwigcptrABCD) X_x2() (_swig_ret float64) { - return _swig_wrap_ABCD__x2(arg1) -} - -var _wrap_ABCD_y_ unsafe.Pointer - -func _swig_wrap_ABCD_y_(base SwigcptrABCD) (_ float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_ABCD_y_, _swig_p) - return -} - -func (arg1 SwigcptrABCD) Y_() (_swig_ret float64) { - return _swig_wrap_ABCD_y_(arg1) -} - -var _wrap_ABCD__3 unsafe.Pointer - -func _swig_wrap_ABCD__3(base SwigcptrABCD) (_ float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_ABCD__3, _swig_p) - return -} - -func (arg1 SwigcptrABCD) X_3() (_swig_ret float64) { - return _swig_wrap_ABCD__3(arg1) -} - -var _wrap_new_ABCD unsafe.Pointer - -func _swig_wrap_new_ABCD() (base SwigcptrABCD) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_ABCD, _swig_p) - return -} - -func NewABCD() (_swig_ret ABCD) { - return _swig_wrap_new_ABCD() -} - -var _wrap_delete_ABCD unsafe.Pointer - -func _swig_wrap_delete_ABCD(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_ABCD, _swig_p) - return -} - -func DeleteABCD(arg1 ABCD) { - _swig_wrap_delete_ABCD(arg1.Swigcptr()) -} - -type ABCD interface { - Swigcptr() uintptr - SwigIsABCD() - Meth() (_swig_ret float64) - M1() (_swig_ret float64) - X_x2() (_swig_ret float64) - Y_() (_swig_ret float64) - X_3() (_swig_ret float64) -} - - -type SwigcptrFoo_Sl_short_Sg_ uintptr -type Foo_Sl_short_Sg_ interface { - Swigcptr() uintptr; -} -func (p SwigcptrFoo_Sl_short_Sg_) Swigcptr() uintptr { - return uintptr(p) -} - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/typename.go b/Examples/test-suite/go/typename.go deleted file mode 100644 index d87e19b11..000000000 --- a/Examples/test-suite/go/typename.go +++ /dev/null @@ -1,170 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../typename.i - -package typename - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrFoo uintptr - -func (p SwigcptrFoo) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrFoo) SwigIsFoo() { -} - -var _wrap_Foo_blah unsafe.Pointer - -func _swig_wrap_Foo_blah(base SwigcptrFoo) (_ float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_blah, _swig_p) - return -} - -func (arg1 SwigcptrFoo) Blah() (_swig_ret float64) { - return _swig_wrap_Foo_blah(arg1) -} - -var _wrap_new_Foo unsafe.Pointer - -func _swig_wrap_new_Foo() (base SwigcptrFoo) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Foo, _swig_p) - return -} - -func NewFoo() (_swig_ret Foo) { - return _swig_wrap_new_Foo() -} - -var _wrap_delete_Foo unsafe.Pointer - -func _swig_wrap_delete_Foo(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Foo, _swig_p) - return -} - -func DeleteFoo(arg1 Foo) { - _swig_wrap_delete_Foo(arg1.Swigcptr()) -} - -type Foo interface { - Swigcptr() uintptr - SwigIsFoo() - Blah() (_swig_ret float64) -} - -type SwigcptrBar uintptr - -func (p SwigcptrBar) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrBar) SwigIsBar() { -} - -var _wrap_Bar_blah unsafe.Pointer - -func _swig_wrap_Bar_blah(base SwigcptrBar) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Bar_blah, _swig_p) - return -} - -func (arg1 SwigcptrBar) Blah() (_swig_ret int) { - return _swig_wrap_Bar_blah(arg1) -} - -var _wrap_new_Bar unsafe.Pointer - -func _swig_wrap_new_Bar() (base SwigcptrBar) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Bar, _swig_p) - return -} - -func NewBar() (_swig_ret Bar) { - return _swig_wrap_new_Bar() -} - -var _wrap_delete_Bar unsafe.Pointer - -func _swig_wrap_delete_Bar(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Bar, _swig_p) - return -} - -func DeleteBar(arg1 Bar) { - _swig_wrap_delete_Bar(arg1.Swigcptr()) -} - -type Bar interface { - Swigcptr() uintptr - SwigIsBar() - Blah() (_swig_ret int) -} - -var _wrap_spam unsafe.Pointer - -func Spam() (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_spam, _swig_p) - return -} -var _wrap_twoFoo unsafe.Pointer - -func _swig_wrap_twoFoo(base uintptr) (_ float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_twoFoo, _swig_p) - return -} - -func TwoFoo(arg1 Foo) (_swig_ret float64) { - return _swig_wrap_twoFoo(arg1.Swigcptr()) -} - -var _wrap_twoBar unsafe.Pointer - -func _swig_wrap_twoBar(base uintptr) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_twoBar, _swig_p) - return -} - -func TwoBar(arg1 Bar) (_swig_ret int) { - return _swig_wrap_twoBar(arg1.Swigcptr()) -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/typename_runme b/Examples/test-suite/go/typename_runme deleted file mode 100755 index 43fc030ca..000000000 Binary files a/Examples/test-suite/go/typename_runme and /dev/null differ diff --git a/Examples/test-suite/go/types_directive.go b/Examples/test-suite/go/types_directive.go deleted file mode 100644 index 114698176..000000000 --- a/Examples/test-suite/go/types_directive.go +++ /dev/null @@ -1,358 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../types_directive.i - -package types_directive - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrDate uintptr - -func (p SwigcptrDate) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrDate) SwigIsDate() { -} - -var _wrap_new_Date unsafe.Pointer - -func _swig_wrap_new_Date(base uint, _ uint, _ uint) (_ SwigcptrDate) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Date, _swig_p) - return -} - -func NewDate(arg1 uint, arg2 uint, arg3 uint) (_swig_ret Date) { - return _swig_wrap_new_Date(arg1, arg2, arg3) -} - -var _wrap_Date_year_set unsafe.Pointer - -func _swig_wrap_Date_year_set(base SwigcptrDate, _ uint) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Date_year_set, _swig_p) - return -} - -func (arg1 SwigcptrDate) SetYear(arg2 uint) { - _swig_wrap_Date_year_set(arg1, arg2) -} - -var _wrap_Date_year_get unsafe.Pointer - -func _swig_wrap_Date_year_get(base SwigcptrDate) (_ uint) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Date_year_get, _swig_p) - return -} - -func (arg1 SwigcptrDate) GetYear() (_swig_ret uint) { - return _swig_wrap_Date_year_get(arg1) -} - -var _wrap_Date_month_set unsafe.Pointer - -func _swig_wrap_Date_month_set(base SwigcptrDate, _ uint) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Date_month_set, _swig_p) - return -} - -func (arg1 SwigcptrDate) SetMonth(arg2 uint) { - _swig_wrap_Date_month_set(arg1, arg2) -} - -var _wrap_Date_month_get unsafe.Pointer - -func _swig_wrap_Date_month_get(base SwigcptrDate) (_ uint) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Date_month_get, _swig_p) - return -} - -func (arg1 SwigcptrDate) GetMonth() (_swig_ret uint) { - return _swig_wrap_Date_month_get(arg1) -} - -var _wrap_Date_day_set unsafe.Pointer - -func _swig_wrap_Date_day_set(base SwigcptrDate, _ uint) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Date_day_set, _swig_p) - return -} - -func (arg1 SwigcptrDate) SetDay(arg2 uint) { - _swig_wrap_Date_day_set(arg1, arg2) -} - -var _wrap_Date_day_get unsafe.Pointer - -func _swig_wrap_Date_day_get(base SwigcptrDate) (_ uint) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Date_day_get, _swig_p) - return -} - -func (arg1 SwigcptrDate) GetDay() (_swig_ret uint) { - return _swig_wrap_Date_day_get(arg1) -} - -var _wrap_delete_Date unsafe.Pointer - -func _swig_wrap_delete_Date(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Date, _swig_p) - return -} - -func DeleteDate(arg1 Date) { - _swig_wrap_delete_Date(arg1.Swigcptr()) -} - -type Date interface { - Swigcptr() uintptr - SwigIsDate() - SetYear(arg2 uint) - GetYear() (_swig_ret uint) - SetMonth(arg2 uint) - GetMonth() (_swig_ret uint) - SetDay(arg2 uint) - GetDay() (_swig_ret uint) -} - -type SwigcptrTime1 uintptr - -func (p SwigcptrTime1) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrTime1) SwigIsTime1() { -} - -var _wrap_new_Time1 unsafe.Pointer - -func _swig_wrap_new_Time1(base uint, _ uint, _ uint, _ uint) (_ SwigcptrTime1) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Time1, _swig_p) - return -} - -func NewTime1(arg1 uint, arg2 uint, arg3 uint, arg4 uint) (_swig_ret Time1) { - return _swig_wrap_new_Time1(arg1, arg2, arg3, arg4) -} - -var _wrap_Time1_dateFromTime unsafe.Pointer - -func _swig_wrap_Time1_dateFromTime(base SwigcptrTime1) (_ SwigcptrDate) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Time1_dateFromTime, _swig_p) - return -} - -func (arg1 SwigcptrTime1) DateFromTime() (_swig_ret Date) { - return _swig_wrap_Time1_dateFromTime(arg1) -} - -var _wrap_Time1_date_set unsafe.Pointer - -func _swig_wrap_Time1_date_set(base SwigcptrTime1, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Time1_date_set, _swig_p) - return -} - -func (arg1 SwigcptrTime1) SetDate(arg2 Date) { - _swig_wrap_Time1_date_set(arg1, arg2.Swigcptr()) -} - -var _wrap_Time1_date_get unsafe.Pointer - -func _swig_wrap_Time1_date_get(base SwigcptrTime1) (_ SwigcptrDate) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Time1_date_get, _swig_p) - return -} - -func (arg1 SwigcptrTime1) GetDate() (_swig_ret Date) { - return _swig_wrap_Time1_date_get(arg1) -} - -var _wrap_Time1_seconds_set unsafe.Pointer - -func _swig_wrap_Time1_seconds_set(base SwigcptrTime1, _ uint) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Time1_seconds_set, _swig_p) - return -} - -func (arg1 SwigcptrTime1) SetSeconds(arg2 uint) { - _swig_wrap_Time1_seconds_set(arg1, arg2) -} - -var _wrap_Time1_seconds_get unsafe.Pointer - -func _swig_wrap_Time1_seconds_get(base SwigcptrTime1) (_ uint) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Time1_seconds_get, _swig_p) - return -} - -func (arg1 SwigcptrTime1) GetSeconds() (_swig_ret uint) { - return _swig_wrap_Time1_seconds_get(arg1) -} - -var _wrap_delete_Time1 unsafe.Pointer - -func _swig_wrap_delete_Time1(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Time1, _swig_p) - return -} - -func DeleteTime1(arg1 Time1) { - _swig_wrap_delete_Time1(arg1.Swigcptr()) -} - -type Time1 interface { - Swigcptr() uintptr - SwigIsTime1() - DateFromTime() (_swig_ret Date) - SetDate(arg2 Date) - GetDate() (_swig_ret Date) - SetSeconds(arg2 uint) - GetSeconds() (_swig_ret uint) -} - -type SwigcptrTime2 uintptr - -func (p SwigcptrTime2) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrTime2) SwigIsTime2() { -} - -var _wrap_new_Time2 unsafe.Pointer - -func _swig_wrap_new_Time2(base uint, _ uint, _ uint, _ uint) (_ SwigcptrTime2) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Time2, _swig_p) - return -} - -func NewTime2(arg1 uint, arg2 uint, arg3 uint, arg4 uint) (_swig_ret Time2) { - return _swig_wrap_new_Time2(arg1, arg2, arg3, arg4) -} - -var _wrap_Time2_date_set unsafe.Pointer - -func _swig_wrap_Time2_date_set(base SwigcptrTime2, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Time2_date_set, _swig_p) - return -} - -func (arg1 SwigcptrTime2) SetDate(arg2 Date) { - _swig_wrap_Time2_date_set(arg1, arg2.Swigcptr()) -} - -var _wrap_Time2_date_get unsafe.Pointer - -func _swig_wrap_Time2_date_get(base SwigcptrTime2) (_ SwigcptrDate) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Time2_date_get, _swig_p) - return -} - -func (arg1 SwigcptrTime2) GetDate() (_swig_ret Date) { - return _swig_wrap_Time2_date_get(arg1) -} - -var _wrap_Time2_seconds_set unsafe.Pointer - -func _swig_wrap_Time2_seconds_set(base SwigcptrTime2, _ uint) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Time2_seconds_set, _swig_p) - return -} - -func (arg1 SwigcptrTime2) SetSeconds(arg2 uint) { - _swig_wrap_Time2_seconds_set(arg1, arg2) -} - -var _wrap_Time2_seconds_get unsafe.Pointer - -func _swig_wrap_Time2_seconds_get(base SwigcptrTime2) (_ uint) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Time2_seconds_get, _swig_p) - return -} - -func (arg1 SwigcptrTime2) GetSeconds() (_swig_ret uint) { - return _swig_wrap_Time2_seconds_get(arg1) -} - -var _wrap_delete_Time2 unsafe.Pointer - -func _swig_wrap_delete_Time2(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Time2, _swig_p) - return -} - -func DeleteTime2(arg1 Time2) { - _swig_wrap_delete_Time2(arg1.Swigcptr()) -} - -type Time2 interface { - Swigcptr() uintptr - SwigIsTime2() - SetDate(arg2 Date) - GetDate() (_swig_ret Date) - SetSeconds(arg2 uint) - GetSeconds() (_swig_ret uint) -} - -var _wrap_add unsafe.Pointer - -func _swig_wrap_add(base uintptr, _ uint) (_ SwigcptrDate) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_add, _swig_p) - return -} - -func Add(arg1 Date, arg2 uint) (_swig_ret Date) { - return _swig_wrap_add(arg1.Swigcptr(), arg2) -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/unicode_strings.go b/Examples/test-suite/go/unicode_strings.go deleted file mode 100644 index 2735b4a3a..000000000 --- a/Examples/test-suite/go/unicode_strings.go +++ /dev/null @@ -1,43 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../unicode_strings.i - -package unicode_strings - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -var _wrap_non_utf8_c_str unsafe.Pointer - -func Non_utf8_c_str() (_swig_ret string) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_non_utf8_c_str, _swig_p) - return -} -var _wrap_non_utf8_std_string unsafe.Pointer - -func Non_utf8_std_string() (_swig_ret string) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_non_utf8_std_string, _swig_p) - return -} - diff --git a/Examples/test-suite/go/union_parameter.go b/Examples/test-suite/go/union_parameter.go deleted file mode 100644 index 3f0cc34ac..000000000 --- a/Examples/test-suite/go/union_parameter.go +++ /dev/null @@ -1,397 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../union_parameter.i - -package union_parameter - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrSDL_ActiveEvent uintptr - -func (p SwigcptrSDL_ActiveEvent) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrSDL_ActiveEvent) SwigIsSDL_ActiveEvent() { -} - -var _wrap_SDL_ActiveEvent_Xtype_set unsafe.Pointer - -func _swig_wrap_SDL_ActiveEvent_Xtype_set(base SwigcptrSDL_ActiveEvent, _ byte) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_SDL_ActiveEvent_Xtype_set, _swig_p) - return -} - -func (arg1 SwigcptrSDL_ActiveEvent) SetXtype(arg2 byte) { - _swig_wrap_SDL_ActiveEvent_Xtype_set(arg1, arg2) -} - -var _wrap_SDL_ActiveEvent_Xtype_get unsafe.Pointer - -func _swig_wrap_SDL_ActiveEvent_Xtype_get(base SwigcptrSDL_ActiveEvent) (_ byte) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_SDL_ActiveEvent_Xtype_get, _swig_p) - return -} - -func (arg1 SwigcptrSDL_ActiveEvent) GetXtype() (_swig_ret byte) { - return _swig_wrap_SDL_ActiveEvent_Xtype_get(arg1) -} - -var _wrap_SDL_ActiveEvent_gain_set unsafe.Pointer - -func _swig_wrap_SDL_ActiveEvent_gain_set(base SwigcptrSDL_ActiveEvent, _ byte) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_SDL_ActiveEvent_gain_set, _swig_p) - return -} - -func (arg1 SwigcptrSDL_ActiveEvent) SetGain(arg2 byte) { - _swig_wrap_SDL_ActiveEvent_gain_set(arg1, arg2) -} - -var _wrap_SDL_ActiveEvent_gain_get unsafe.Pointer - -func _swig_wrap_SDL_ActiveEvent_gain_get(base SwigcptrSDL_ActiveEvent) (_ byte) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_SDL_ActiveEvent_gain_get, _swig_p) - return -} - -func (arg1 SwigcptrSDL_ActiveEvent) GetGain() (_swig_ret byte) { - return _swig_wrap_SDL_ActiveEvent_gain_get(arg1) -} - -var _wrap_SDL_ActiveEvent_state_set unsafe.Pointer - -func _swig_wrap_SDL_ActiveEvent_state_set(base SwigcptrSDL_ActiveEvent, _ byte) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_SDL_ActiveEvent_state_set, _swig_p) - return -} - -func (arg1 SwigcptrSDL_ActiveEvent) SetState(arg2 byte) { - _swig_wrap_SDL_ActiveEvent_state_set(arg1, arg2) -} - -var _wrap_SDL_ActiveEvent_state_get unsafe.Pointer - -func _swig_wrap_SDL_ActiveEvent_state_get(base SwigcptrSDL_ActiveEvent) (_ byte) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_SDL_ActiveEvent_state_get, _swig_p) - return -} - -func (arg1 SwigcptrSDL_ActiveEvent) GetState() (_swig_ret byte) { - return _swig_wrap_SDL_ActiveEvent_state_get(arg1) -} - -var _wrap_new_SDL_ActiveEvent unsafe.Pointer - -func _swig_wrap_new_SDL_ActiveEvent() (base SwigcptrSDL_ActiveEvent) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_SDL_ActiveEvent, _swig_p) - return -} - -func NewSDL_ActiveEvent() (_swig_ret SDL_ActiveEvent) { - return _swig_wrap_new_SDL_ActiveEvent() -} - -var _wrap_delete_SDL_ActiveEvent unsafe.Pointer - -func _swig_wrap_delete_SDL_ActiveEvent(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_SDL_ActiveEvent, _swig_p) - return -} - -func DeleteSDL_ActiveEvent(arg1 SDL_ActiveEvent) { - _swig_wrap_delete_SDL_ActiveEvent(arg1.Swigcptr()) -} - -type SDL_ActiveEvent interface { - Swigcptr() uintptr - SwigIsSDL_ActiveEvent() - SetXtype(arg2 byte) - GetXtype() (_swig_ret byte) - SetGain(arg2 byte) - GetGain() (_swig_ret byte) - SetState(arg2 byte) - GetState() (_swig_ret byte) -} - -type SwigcptrSDL_KeyboardEvent uintptr - -func (p SwigcptrSDL_KeyboardEvent) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrSDL_KeyboardEvent) SwigIsSDL_KeyboardEvent() { -} - -var _wrap_SDL_KeyboardEvent_Xtype_set unsafe.Pointer - -func _swig_wrap_SDL_KeyboardEvent_Xtype_set(base SwigcptrSDL_KeyboardEvent, _ byte) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_SDL_KeyboardEvent_Xtype_set, _swig_p) - return -} - -func (arg1 SwigcptrSDL_KeyboardEvent) SetXtype(arg2 byte) { - _swig_wrap_SDL_KeyboardEvent_Xtype_set(arg1, arg2) -} - -var _wrap_SDL_KeyboardEvent_Xtype_get unsafe.Pointer - -func _swig_wrap_SDL_KeyboardEvent_Xtype_get(base SwigcptrSDL_KeyboardEvent) (_ byte) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_SDL_KeyboardEvent_Xtype_get, _swig_p) - return -} - -func (arg1 SwigcptrSDL_KeyboardEvent) GetXtype() (_swig_ret byte) { - return _swig_wrap_SDL_KeyboardEvent_Xtype_get(arg1) -} - -var _wrap_SDL_KeyboardEvent_which_set unsafe.Pointer - -func _swig_wrap_SDL_KeyboardEvent_which_set(base SwigcptrSDL_KeyboardEvent, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_SDL_KeyboardEvent_which_set, _swig_p) - return -} - -func (arg1 SwigcptrSDL_KeyboardEvent) SetWhich(arg2 int) { - _swig_wrap_SDL_KeyboardEvent_which_set(arg1, arg2) -} - -var _wrap_SDL_KeyboardEvent_which_get unsafe.Pointer - -func _swig_wrap_SDL_KeyboardEvent_which_get(base SwigcptrSDL_KeyboardEvent) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_SDL_KeyboardEvent_which_get, _swig_p) - return -} - -func (arg1 SwigcptrSDL_KeyboardEvent) GetWhich() (_swig_ret int) { - return _swig_wrap_SDL_KeyboardEvent_which_get(arg1) -} - -var _wrap_SDL_KeyboardEvent_state_set unsafe.Pointer - -func _swig_wrap_SDL_KeyboardEvent_state_set(base SwigcptrSDL_KeyboardEvent, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_SDL_KeyboardEvent_state_set, _swig_p) - return -} - -func (arg1 SwigcptrSDL_KeyboardEvent) SetState(arg2 int) { - _swig_wrap_SDL_KeyboardEvent_state_set(arg1, arg2) -} - -var _wrap_SDL_KeyboardEvent_state_get unsafe.Pointer - -func _swig_wrap_SDL_KeyboardEvent_state_get(base SwigcptrSDL_KeyboardEvent) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_SDL_KeyboardEvent_state_get, _swig_p) - return -} - -func (arg1 SwigcptrSDL_KeyboardEvent) GetState() (_swig_ret int) { - return _swig_wrap_SDL_KeyboardEvent_state_get(arg1) -} - -var _wrap_new_SDL_KeyboardEvent unsafe.Pointer - -func _swig_wrap_new_SDL_KeyboardEvent() (base SwigcptrSDL_KeyboardEvent) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_SDL_KeyboardEvent, _swig_p) - return -} - -func NewSDL_KeyboardEvent() (_swig_ret SDL_KeyboardEvent) { - return _swig_wrap_new_SDL_KeyboardEvent() -} - -var _wrap_delete_SDL_KeyboardEvent unsafe.Pointer - -func _swig_wrap_delete_SDL_KeyboardEvent(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_SDL_KeyboardEvent, _swig_p) - return -} - -func DeleteSDL_KeyboardEvent(arg1 SDL_KeyboardEvent) { - _swig_wrap_delete_SDL_KeyboardEvent(arg1.Swigcptr()) -} - -type SDL_KeyboardEvent interface { - Swigcptr() uintptr - SwigIsSDL_KeyboardEvent() - SetXtype(arg2 byte) - GetXtype() (_swig_ret byte) - SetWhich(arg2 int) - GetWhich() (_swig_ret int) - SetState(arg2 int) - GetState() (_swig_ret int) -} - -type SwigcptrSDL_Event uintptr - -func (p SwigcptrSDL_Event) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrSDL_Event) SwigIsSDL_Event() { -} - -var _wrap_SDL_Event_Xtype_set unsafe.Pointer - -func _swig_wrap_SDL_Event_Xtype_set(base SwigcptrSDL_Event, _ byte) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_SDL_Event_Xtype_set, _swig_p) - return -} - -func (arg1 SwigcptrSDL_Event) SetXtype(arg2 byte) { - _swig_wrap_SDL_Event_Xtype_set(arg1, arg2) -} - -var _wrap_SDL_Event_Xtype_get unsafe.Pointer - -func _swig_wrap_SDL_Event_Xtype_get(base SwigcptrSDL_Event) (_ byte) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_SDL_Event_Xtype_get, _swig_p) - return -} - -func (arg1 SwigcptrSDL_Event) GetXtype() (_swig_ret byte) { - return _swig_wrap_SDL_Event_Xtype_get(arg1) -} - -var _wrap_SDL_Event_active_set unsafe.Pointer - -func _swig_wrap_SDL_Event_active_set(base SwigcptrSDL_Event, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_SDL_Event_active_set, _swig_p) - return -} - -func (arg1 SwigcptrSDL_Event) SetActive(arg2 SDL_ActiveEvent) { - _swig_wrap_SDL_Event_active_set(arg1, arg2.Swigcptr()) -} - -var _wrap_SDL_Event_active_get unsafe.Pointer - -func _swig_wrap_SDL_Event_active_get(base SwigcptrSDL_Event) (_ SwigcptrSDL_ActiveEvent) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_SDL_Event_active_get, _swig_p) - return -} - -func (arg1 SwigcptrSDL_Event) GetActive() (_swig_ret SDL_ActiveEvent) { - return _swig_wrap_SDL_Event_active_get(arg1) -} - -var _wrap_SDL_Event_key_set unsafe.Pointer - -func _swig_wrap_SDL_Event_key_set(base SwigcptrSDL_Event, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_SDL_Event_key_set, _swig_p) - return -} - -func (arg1 SwigcptrSDL_Event) SetKey(arg2 SDL_KeyboardEvent) { - _swig_wrap_SDL_Event_key_set(arg1, arg2.Swigcptr()) -} - -var _wrap_SDL_Event_key_get unsafe.Pointer - -func _swig_wrap_SDL_Event_key_get(base SwigcptrSDL_Event) (_ SwigcptrSDL_KeyboardEvent) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_SDL_Event_key_get, _swig_p) - return -} - -func (arg1 SwigcptrSDL_Event) GetKey() (_swig_ret SDL_KeyboardEvent) { - return _swig_wrap_SDL_Event_key_get(arg1) -} - -var _wrap_new_SDL_Event unsafe.Pointer - -func _swig_wrap_new_SDL_Event() (base SwigcptrSDL_Event) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_SDL_Event, _swig_p) - return -} - -func NewSDL_Event() (_swig_ret SDL_Event) { - return _swig_wrap_new_SDL_Event() -} - -var _wrap_delete_SDL_Event unsafe.Pointer - -func _swig_wrap_delete_SDL_Event(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_SDL_Event, _swig_p) - return -} - -func DeleteSDL_Event(arg1 SDL_Event) { - _swig_wrap_delete_SDL_Event(arg1.Swigcptr()) -} - -type SDL_Event interface { - Swigcptr() uintptr - SwigIsSDL_Event() - SetXtype(arg2 byte) - GetXtype() (_swig_ret byte) - SetActive(arg2 SDL_ActiveEvent) - GetActive() (_swig_ret SDL_ActiveEvent) - SetKey(arg2 SDL_KeyboardEvent) - GetKey() (_swig_ret SDL_KeyboardEvent) -} - -var _wrap_SDL_PollEvent unsafe.Pointer - -func _swig_wrap_SDL_PollEvent(base uintptr) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_SDL_PollEvent, _swig_p) - return -} - -func SDL_PollEvent(arg1 SDL_Event) (_swig_ret int) { - return _swig_wrap_SDL_PollEvent(arg1.Swigcptr()) -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/union_scope.go b/Examples/test-suite/go/union_scope.go deleted file mode 100644 index 01f506064..000000000 --- a/Examples/test-suite/go/union_scope.go +++ /dev/null @@ -1,75 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../union_scope.i - -package union_scope - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrNRState uintptr - -func (p SwigcptrNRState) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrNRState) SwigIsNRState() { -} - -var _wrap_new_nRState unsafe.Pointer - -func _swig_wrap_new_nRState() (base SwigcptrNRState) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_nRState, _swig_p) - return -} - -func NewNRState() (_swig_ret NRState) { - return _swig_wrap_new_nRState() -} - -var _wrap_delete_nRState unsafe.Pointer - -func _swig_wrap_delete_nRState(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_nRState, _swig_p) - return -} - -func DeleteNRState(arg1 NRState) { - _swig_wrap_delete_nRState(arg1.Swigcptr()) -} - -type NRState interface { - Swigcptr() uintptr - SwigIsNRState() -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/unions.go b/Examples/test-suite/go/unions.go deleted file mode 100644 index 5b2b27d23..000000000 --- a/Examples/test-suite/go/unions.go +++ /dev/null @@ -1,448 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../unions.i - -package unions - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrSmallStruct uintptr - -func (p SwigcptrSmallStruct) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrSmallStruct) SwigIsSmallStruct() { -} - -var _wrap_SmallStruct_jill_set unsafe.Pointer - -func _swig_wrap_SmallStruct_jill_set(base SwigcptrSmallStruct, _ int16) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_SmallStruct_jill_set, _swig_p) - return -} - -func (arg1 SwigcptrSmallStruct) SetJill(arg2 int16) { - _swig_wrap_SmallStruct_jill_set(arg1, arg2) -} - -var _wrap_SmallStruct_jill_get unsafe.Pointer - -func _swig_wrap_SmallStruct_jill_get(base SwigcptrSmallStruct) (_ int16) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_SmallStruct_jill_get, _swig_p) - return -} - -func (arg1 SwigcptrSmallStruct) GetJill() (_swig_ret int16) { - return _swig_wrap_SmallStruct_jill_get(arg1) -} - -var _wrap_new_SmallStruct unsafe.Pointer - -func _swig_wrap_new_SmallStruct() (base SwigcptrSmallStruct) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_SmallStruct, _swig_p) - return -} - -func NewSmallStruct() (_swig_ret SmallStruct) { - return _swig_wrap_new_SmallStruct() -} - -var _wrap_delete_SmallStruct unsafe.Pointer - -func _swig_wrap_delete_SmallStruct(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_SmallStruct, _swig_p) - return -} - -func DeleteSmallStruct(arg1 SmallStruct) { - _swig_wrap_delete_SmallStruct(arg1.Swigcptr()) -} - -type SmallStruct interface { - Swigcptr() uintptr - SwigIsSmallStruct() - SetJill(arg2 int16) - GetJill() (_swig_ret int16) -} - -type SwigcptrBigStruct uintptr - -func (p SwigcptrBigStruct) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrBigStruct) SwigIsBigStruct() { -} - -var _wrap_BigStruct_jack_set unsafe.Pointer - -func _swig_wrap_BigStruct_jack_set(base SwigcptrBigStruct, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_BigStruct_jack_set, _swig_p) - return -} - -func (arg1 SwigcptrBigStruct) SetJack(arg2 int) { - _swig_wrap_BigStruct_jack_set(arg1, arg2) -} - -var _wrap_BigStruct_jack_get unsafe.Pointer - -func _swig_wrap_BigStruct_jack_get(base SwigcptrBigStruct) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_BigStruct_jack_get, _swig_p) - return -} - -func (arg1 SwigcptrBigStruct) GetJack() (_swig_ret int) { - return _swig_wrap_BigStruct_jack_get(arg1) -} - -var _wrap_BigStruct_smallstruct_set unsafe.Pointer - -func _swig_wrap_BigStruct_smallstruct_set(base SwigcptrBigStruct, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_BigStruct_smallstruct_set, _swig_p) - return -} - -func (arg1 SwigcptrBigStruct) SetSmallstruct(arg2 SmallStruct) { - _swig_wrap_BigStruct_smallstruct_set(arg1, arg2.Swigcptr()) -} - -var _wrap_BigStruct_smallstruct_get unsafe.Pointer - -func _swig_wrap_BigStruct_smallstruct_get(base SwigcptrBigStruct) (_ SwigcptrSmallStruct) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_BigStruct_smallstruct_get, _swig_p) - return -} - -func (arg1 SwigcptrBigStruct) GetSmallstruct() (_swig_ret SmallStruct) { - return _swig_wrap_BigStruct_smallstruct_get(arg1) -} - -var _wrap_new_BigStruct unsafe.Pointer - -func _swig_wrap_new_BigStruct() (base SwigcptrBigStruct) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_BigStruct, _swig_p) - return -} - -func NewBigStruct() (_swig_ret BigStruct) { - return _swig_wrap_new_BigStruct() -} - -var _wrap_delete_BigStruct unsafe.Pointer - -func _swig_wrap_delete_BigStruct(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_BigStruct, _swig_p) - return -} - -func DeleteBigStruct(arg1 BigStruct) { - _swig_wrap_delete_BigStruct(arg1.Swigcptr()) -} - -type BigStruct interface { - Swigcptr() uintptr - SwigIsBigStruct() - SetJack(arg2 int) - GetJack() (_swig_ret int) - SetSmallstruct(arg2 SmallStruct) - GetSmallstruct() (_swig_ret SmallStruct) -} - -type SwigcptrUnionTest uintptr - -func (p SwigcptrUnionTest) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrUnionTest) SwigIsUnionTest() { -} - -var _wrap_UnionTest_bs_set unsafe.Pointer - -func _swig_wrap_UnionTest_bs_set(base SwigcptrUnionTest, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_UnionTest_bs_set, _swig_p) - return -} - -func (arg1 SwigcptrUnionTest) SetBs(arg2 BigStruct) { - _swig_wrap_UnionTest_bs_set(arg1, arg2.Swigcptr()) -} - -var _wrap_UnionTest_bs_get unsafe.Pointer - -func _swig_wrap_UnionTest_bs_get(base SwigcptrUnionTest) (_ SwigcptrBigStruct) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_UnionTest_bs_get, _swig_p) - return -} - -func (arg1 SwigcptrUnionTest) GetBs() (_swig_ret BigStruct) { - return _swig_wrap_UnionTest_bs_get(arg1) -} - -var _wrap_UnionTest_ss_set unsafe.Pointer - -func _swig_wrap_UnionTest_ss_set(base SwigcptrUnionTest, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_UnionTest_ss_set, _swig_p) - return -} - -func (arg1 SwigcptrUnionTest) SetSs(arg2 SmallStruct) { - _swig_wrap_UnionTest_ss_set(arg1, arg2.Swigcptr()) -} - -var _wrap_UnionTest_ss_get unsafe.Pointer - -func _swig_wrap_UnionTest_ss_get(base SwigcptrUnionTest) (_ SwigcptrSmallStruct) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_UnionTest_ss_get, _swig_p) - return -} - -func (arg1 SwigcptrUnionTest) GetSs() (_swig_ret SmallStruct) { - return _swig_wrap_UnionTest_ss_get(arg1) -} - -var _wrap_new_UnionTest unsafe.Pointer - -func _swig_wrap_new_UnionTest() (base SwigcptrUnionTest) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_UnionTest, _swig_p) - return -} - -func NewUnionTest() (_swig_ret UnionTest) { - return _swig_wrap_new_UnionTest() -} - -var _wrap_delete_UnionTest unsafe.Pointer - -func _swig_wrap_delete_UnionTest(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_UnionTest, _swig_p) - return -} - -func DeleteUnionTest(arg1 UnionTest) { - _swig_wrap_delete_UnionTest(arg1.Swigcptr()) -} - -type UnionTest interface { - Swigcptr() uintptr - SwigIsUnionTest() - SetBs(arg2 BigStruct) - GetBs() (_swig_ret BigStruct) - SetSs(arg2 SmallStruct) - GetSs() (_swig_ret SmallStruct) -} - -type SwigcptrEmbeddedUnionTest uintptr - -func (p SwigcptrEmbeddedUnionTest) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrEmbeddedUnionTest) SwigIsEmbeddedUnionTest() { -} - -var _wrap_EmbeddedUnionTest_uni_get unsafe.Pointer - -func _swig_wrap_EmbeddedUnionTest_uni_get(base SwigcptrEmbeddedUnionTest) (_ SwigcptrEmbeddedUnionTest_uni) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_EmbeddedUnionTest_uni_get, _swig_p) - return -} - -func (arg1 SwigcptrEmbeddedUnionTest) GetUni() (_swig_ret EmbeddedUnionTest_uni) { - return _swig_wrap_EmbeddedUnionTest_uni_get(arg1) -} - -var _wrap_EmbeddedUnionTest_number_set unsafe.Pointer - -func _swig_wrap_EmbeddedUnionTest_number_set(base SwigcptrEmbeddedUnionTest, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_EmbeddedUnionTest_number_set, _swig_p) - return -} - -func (arg1 SwigcptrEmbeddedUnionTest) SetNumber(arg2 int) { - _swig_wrap_EmbeddedUnionTest_number_set(arg1, arg2) -} - -var _wrap_EmbeddedUnionTest_number_get unsafe.Pointer - -func _swig_wrap_EmbeddedUnionTest_number_get(base SwigcptrEmbeddedUnionTest) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_EmbeddedUnionTest_number_get, _swig_p) - return -} - -func (arg1 SwigcptrEmbeddedUnionTest) GetNumber() (_swig_ret int) { - return _swig_wrap_EmbeddedUnionTest_number_get(arg1) -} - -var _wrap_new_EmbeddedUnionTest unsafe.Pointer - -func _swig_wrap_new_EmbeddedUnionTest() (base SwigcptrEmbeddedUnionTest) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_EmbeddedUnionTest, _swig_p) - return -} - -func NewEmbeddedUnionTest() (_swig_ret EmbeddedUnionTest) { - return _swig_wrap_new_EmbeddedUnionTest() -} - -var _wrap_delete_EmbeddedUnionTest unsafe.Pointer - -func _swig_wrap_delete_EmbeddedUnionTest(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_EmbeddedUnionTest, _swig_p) - return -} - -func DeleteEmbeddedUnionTest(arg1 EmbeddedUnionTest) { - _swig_wrap_delete_EmbeddedUnionTest(arg1.Swigcptr()) -} - -type EmbeddedUnionTest interface { - Swigcptr() uintptr - SwigIsEmbeddedUnionTest() - GetUni() (_swig_ret EmbeddedUnionTest_uni) - SetNumber(arg2 int) - GetNumber() (_swig_ret int) -} - -type SwigcptrEmbeddedUnionTest_uni uintptr - -func (p SwigcptrEmbeddedUnionTest_uni) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrEmbeddedUnionTest_uni) SwigIsEmbeddedUnionTest_uni() { -} - -var _wrap_EmbeddedUnionTest_uni_big_set unsafe.Pointer - -func _swig_wrap_EmbeddedUnionTest_uni_big_set(base SwigcptrEmbeddedUnionTest_uni, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_EmbeddedUnionTest_uni_big_set, _swig_p) - return -} - -func (arg1 SwigcptrEmbeddedUnionTest_uni) SetBig(arg2 BigStruct) { - _swig_wrap_EmbeddedUnionTest_uni_big_set(arg1, arg2.Swigcptr()) -} - -var _wrap_EmbeddedUnionTest_uni_big_get unsafe.Pointer - -func _swig_wrap_EmbeddedUnionTest_uni_big_get(base SwigcptrEmbeddedUnionTest_uni) (_ SwigcptrBigStruct) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_EmbeddedUnionTest_uni_big_get, _swig_p) - return -} - -func (arg1 SwigcptrEmbeddedUnionTest_uni) GetBig() (_swig_ret BigStruct) { - return _swig_wrap_EmbeddedUnionTest_uni_big_get(arg1) -} - -var _wrap_EmbeddedUnionTest_uni_small_set unsafe.Pointer - -func _swig_wrap_EmbeddedUnionTest_uni_small_set(base SwigcptrEmbeddedUnionTest_uni, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_EmbeddedUnionTest_uni_small_set, _swig_p) - return -} - -func (arg1 SwigcptrEmbeddedUnionTest_uni) SetSmall(arg2 SmallStruct) { - _swig_wrap_EmbeddedUnionTest_uni_small_set(arg1, arg2.Swigcptr()) -} - -var _wrap_EmbeddedUnionTest_uni_small_get unsafe.Pointer - -func _swig_wrap_EmbeddedUnionTest_uni_small_get(base SwigcptrEmbeddedUnionTest_uni) (_ SwigcptrSmallStruct) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_EmbeddedUnionTest_uni_small_get, _swig_p) - return -} - -func (arg1 SwigcptrEmbeddedUnionTest_uni) GetSmall() (_swig_ret SmallStruct) { - return _swig_wrap_EmbeddedUnionTest_uni_small_get(arg1) -} - -var _wrap_new_EmbeddedUnionTest_uni unsafe.Pointer - -func _swig_wrap_new_EmbeddedUnionTest_uni() (base SwigcptrEmbeddedUnionTest_uni) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_EmbeddedUnionTest_uni, _swig_p) - return -} - -func NewEmbeddedUnionTest_uni() (_swig_ret EmbeddedUnionTest_uni) { - return _swig_wrap_new_EmbeddedUnionTest_uni() -} - -var _wrap_delete_EmbeddedUnionTest_uni unsafe.Pointer - -func _swig_wrap_delete_EmbeddedUnionTest_uni(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_EmbeddedUnionTest_uni, _swig_p) - return -} - -func DeleteEmbeddedUnionTest_uni(arg1 EmbeddedUnionTest_uni) { - _swig_wrap_delete_EmbeddedUnionTest_uni(arg1.Swigcptr()) -} - -type EmbeddedUnionTest_uni interface { - Swigcptr() uintptr - SwigIsEmbeddedUnionTest_uni() - SetBig(arg2 BigStruct) - GetBig() (_swig_ret BigStruct) - SetSmall(arg2 SmallStruct) - GetSmall() (_swig_ret SmallStruct) -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/unions_runme b/Examples/test-suite/go/unions_runme deleted file mode 100755 index 2008d69a2..000000000 Binary files a/Examples/test-suite/go/unions_runme and /dev/null differ diff --git a/Examples/test-suite/go/using1.go b/Examples/test-suite/go/using1.go deleted file mode 100644 index 11a8d57d5..000000000 --- a/Examples/test-suite/go/using1.go +++ /dev/null @@ -1,82 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../using1.i - -package using1 - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrX_FooImpl uintptr - -func (p SwigcptrX_FooImpl) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrX_FooImpl) SwigIsX_FooImpl() { -} - -var _wrap_new__FooImpl unsafe.Pointer - -func _swig_wrap_new__FooImpl() (base SwigcptrX_FooImpl) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new__FooImpl, _swig_p) - return -} - -func NewX_FooImpl() (_swig_ret X_FooImpl) { - return _swig_wrap_new__FooImpl() -} - -var _wrap_delete__FooImpl unsafe.Pointer - -func _swig_wrap_delete__FooImpl(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete__FooImpl, _swig_p) - return -} - -func DeleteX_FooImpl(arg1 X_FooImpl) { - _swig_wrap_delete__FooImpl(arg1.Swigcptr()) -} - -type X_FooImpl interface { - Swigcptr() uintptr - SwigIsX_FooImpl() -} - -var _wrap_spam unsafe.Pointer - -func Spam(arg1 int) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_spam, _swig_p) - return -} - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/using1_runme b/Examples/test-suite/go/using1_runme deleted file mode 100755 index 87d42fc7d..000000000 Binary files a/Examples/test-suite/go/using1_runme and /dev/null differ diff --git a/Examples/test-suite/go/using2.go b/Examples/test-suite/go/using2.go deleted file mode 100644 index 24a330282..000000000 --- a/Examples/test-suite/go/using2.go +++ /dev/null @@ -1,82 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../using2.i - -package using2 - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrX_FooImpl uintptr - -func (p SwigcptrX_FooImpl) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrX_FooImpl) SwigIsX_FooImpl() { -} - -var _wrap_new__FooImpl unsafe.Pointer - -func _swig_wrap_new__FooImpl() (base SwigcptrX_FooImpl) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new__FooImpl, _swig_p) - return -} - -func NewX_FooImpl() (_swig_ret X_FooImpl) { - return _swig_wrap_new__FooImpl() -} - -var _wrap_delete__FooImpl unsafe.Pointer - -func _swig_wrap_delete__FooImpl(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete__FooImpl, _swig_p) - return -} - -func DeleteX_FooImpl(arg1 X_FooImpl) { - _swig_wrap_delete__FooImpl(arg1.Swigcptr()) -} - -type X_FooImpl interface { - Swigcptr() uintptr - SwigIsX_FooImpl() -} - -var _wrap_spam unsafe.Pointer - -func Spam(arg1 int) (_swig_ret int) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_spam, _swig_p) - return -} - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/using2_runme b/Examples/test-suite/go/using2_runme deleted file mode 100755 index 316c43684..000000000 Binary files a/Examples/test-suite/go/using2_runme and /dev/null differ diff --git a/Examples/test-suite/go/using_composition.go b/Examples/test-suite/go/using_composition.go deleted file mode 100644 index d96ff1a50..000000000 --- a/Examples/test-suite/go/using_composition.go +++ /dev/null @@ -1,523 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../using_composition.i - -package using_composition - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrFoo uintptr - -func (p SwigcptrFoo) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrFoo) SwigIsFoo() { -} - -var _wrap_Foo_blah__SWIG_0 unsafe.Pointer - -func _swig_wrap_Foo_blah__SWIG_0(base SwigcptrFoo, _ int) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_blah__SWIG_0, _swig_p) - return -} - -func (arg1 SwigcptrFoo) Blah__SWIG_0(arg2 int) (_swig_ret int) { - return _swig_wrap_Foo_blah__SWIG_0(arg1, arg2) -} - -var _wrap_Foo_blah__SWIG_1 unsafe.Pointer - -func _swig_wrap_Foo_blah__SWIG_1(base SwigcptrFoo, _ string) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_blah__SWIG_1, _swig_p) - return -} - -func (arg1 SwigcptrFoo) Blah__SWIG_1(arg2 string) (_swig_ret string) { - return _swig_wrap_Foo_blah__SWIG_1(arg1, arg2) -} - -func (p SwigcptrFoo) Blah(a ...interface{}) interface{} { - argc := len(a) - if argc == 1 { - if _, ok := a[0].(int); !ok { - goto check_1 - } - return p.Blah__SWIG_0(a[0].(int)) - } -check_1: - if argc == 1 { - return p.Blah__SWIG_1(a[0].(string)) - } - panic("No match for overloaded function call") -} - -var _wrap_new_Foo unsafe.Pointer - -func _swig_wrap_new_Foo() (base SwigcptrFoo) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Foo, _swig_p) - return -} - -func NewFoo() (_swig_ret Foo) { - return _swig_wrap_new_Foo() -} - -var _wrap_delete_Foo unsafe.Pointer - -func _swig_wrap_delete_Foo(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Foo, _swig_p) - return -} - -func DeleteFoo(arg1 Foo) { - _swig_wrap_delete_Foo(arg1.Swigcptr()) -} - -type Foo interface { - Swigcptr() uintptr - SwigIsFoo() - Blah(a ...interface{}) interface{} -} - -type SwigcptrBar uintptr - -func (p SwigcptrBar) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrBar) SwigIsBar() { -} - -var _wrap_Bar_blah unsafe.Pointer - -func _swig_wrap_Bar_blah(base SwigcptrBar, _ float64) (_ float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Bar_blah, _swig_p) - return -} - -func (arg1 SwigcptrBar) Blah(arg2 float64) (_swig_ret float64) { - return _swig_wrap_Bar_blah(arg1, arg2) -} - -var _wrap_new_Bar unsafe.Pointer - -func _swig_wrap_new_Bar() (base SwigcptrBar) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Bar, _swig_p) - return -} - -func NewBar() (_swig_ret Bar) { - return _swig_wrap_new_Bar() -} - -var _wrap_delete_Bar unsafe.Pointer - -func _swig_wrap_delete_Bar(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Bar, _swig_p) - return -} - -func DeleteBar(arg1 Bar) { - _swig_wrap_delete_Bar(arg1.Swigcptr()) -} - -type Bar interface { - Swigcptr() uintptr - SwigIsBar() - Blah(arg2 float64) (_swig_ret float64) -} - -type SwigcptrFooBar uintptr - -func (p SwigcptrFooBar) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrFooBar) SwigIsFooBar() { -} - -var _wrap_FooBar_blah__SWIG_0_0 unsafe.Pointer - -func _swig_wrap_FooBar_blah__SWIG_0_0(base SwigcptrFooBar, _ int) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_FooBar_blah__SWIG_0_0, _swig_p) - return -} - -func (arg1 SwigcptrFooBar) Blah__SWIG_0_0(arg2 int) (_swig_ret int) { - return _swig_wrap_FooBar_blah__SWIG_0_0(arg1, arg2) -} - -var _wrap_FooBar_blah__SWIG_1_0 unsafe.Pointer - -func _swig_wrap_FooBar_blah__SWIG_1_0(base SwigcptrFooBar, _ float64) (_ float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_FooBar_blah__SWIG_1_0, _swig_p) - return -} - -func (arg1 SwigcptrFooBar) Blah__SWIG_1_0(arg2 float64) (_swig_ret float64) { - return _swig_wrap_FooBar_blah__SWIG_1_0(arg1, arg2) -} - -var _wrap_FooBar_blah__SWIG_2 unsafe.Pointer - -func _swig_wrap_FooBar_blah__SWIG_2(base SwigcptrFooBar, _ string) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_FooBar_blah__SWIG_2, _swig_p) - return -} - -func (arg1 SwigcptrFooBar) Blah__SWIG_2(arg2 string) (_swig_ret string) { - return _swig_wrap_FooBar_blah__SWIG_2(arg1, arg2) -} - -func (p SwigcptrFooBar) Blah(a ...interface{}) interface{} { - argc := len(a) - if argc == 1 { - if _, ok := a[0].(int); !ok { - goto check_1 - } - return p.Blah__SWIG_0_0(a[0].(int)) - } -check_1: - if argc == 1 { - if _, ok := a[0].(float64); !ok { - goto check_2 - } - return p.Blah__SWIG_1_0(a[0].(float64)) - } -check_2: - if argc == 1 { - return p.Blah__SWIG_2(a[0].(string)) - } - panic("No match for overloaded function call") -} - -var _wrap_new_FooBar unsafe.Pointer - -func _swig_wrap_new_FooBar() (base SwigcptrFooBar) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_FooBar, _swig_p) - return -} - -func NewFooBar() (_swig_ret FooBar) { - return _swig_wrap_new_FooBar() -} - -var _wrap_delete_FooBar unsafe.Pointer - -func _swig_wrap_delete_FooBar(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_FooBar, _swig_p) - return -} - -func DeleteFooBar(arg1 FooBar) { - _swig_wrap_delete_FooBar(arg1.Swigcptr()) -} - -func (p SwigcptrFooBar) SwigIsFoo() { -} - -func (p SwigcptrFooBar) SwigGetFoo() Foo { - return SwigcptrFoo(p.Swigcptr()) -} - -var _wrap_FooBar_SwigGetBar unsafe.Pointer - -func _swig_wrap_FooBar_SwigGetBar(base SwigcptrFooBar) (_ SwigcptrBar) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_FooBar_SwigGetBar, _swig_p) - return -} - -func (arg1 SwigcptrFooBar) SwigGetBar() (_swig_ret Bar) { - return _swig_wrap_FooBar_SwigGetBar(arg1) -} - -type FooBar interface { - Swigcptr() uintptr - SwigIsFooBar() - Blah(a ...interface{}) interface{} - SwigIsFoo() - SwigGetFoo() Foo - SwigGetBar() (_swig_ret Bar) -} - -type SwigcptrFooBar2 uintptr - -func (p SwigcptrFooBar2) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrFooBar2) SwigIsFooBar2() { -} - -var _wrap_FooBar2_blah__SWIG_0 unsafe.Pointer - -func _swig_wrap_FooBar2_blah__SWIG_0(base SwigcptrFooBar2, _ string) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_FooBar2_blah__SWIG_0, _swig_p) - return -} - -func (arg1 SwigcptrFooBar2) Blah__SWIG_0(arg2 string) (_swig_ret string) { - return _swig_wrap_FooBar2_blah__SWIG_0(arg1, arg2) -} - -var _wrap_FooBar2_blah__SWIG_1_0 unsafe.Pointer - -func _swig_wrap_FooBar2_blah__SWIG_1_0(base SwigcptrFooBar2, _ int) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_FooBar2_blah__SWIG_1_0, _swig_p) - return -} - -func (arg1 SwigcptrFooBar2) Blah__SWIG_1_0(arg2 int) (_swig_ret int) { - return _swig_wrap_FooBar2_blah__SWIG_1_0(arg1, arg2) -} - -var _wrap_FooBar2_blah__SWIG_2_0 unsafe.Pointer - -func _swig_wrap_FooBar2_blah__SWIG_2_0(base SwigcptrFooBar2, _ float64) (_ float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_FooBar2_blah__SWIG_2_0, _swig_p) - return -} - -func (arg1 SwigcptrFooBar2) Blah__SWIG_2_0(arg2 float64) (_swig_ret float64) { - return _swig_wrap_FooBar2_blah__SWIG_2_0(arg1, arg2) -} - -func (p SwigcptrFooBar2) Blah(a ...interface{}) interface{} { - argc := len(a) - if argc == 1 { - if _, ok := a[0].(int); !ok { - goto check_1 - } - return p.Blah__SWIG_1_0(a[0].(int)) - } -check_1: - if argc == 1 { - if _, ok := a[0].(float64); !ok { - goto check_2 - } - return p.Blah__SWIG_2_0(a[0].(float64)) - } -check_2: - if argc == 1 { - return p.Blah__SWIG_0(a[0].(string)) - } - panic("No match for overloaded function call") -} - -var _wrap_new_FooBar2 unsafe.Pointer - -func _swig_wrap_new_FooBar2() (base SwigcptrFooBar2) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_FooBar2, _swig_p) - return -} - -func NewFooBar2() (_swig_ret FooBar2) { - return _swig_wrap_new_FooBar2() -} - -var _wrap_delete_FooBar2 unsafe.Pointer - -func _swig_wrap_delete_FooBar2(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_FooBar2, _swig_p) - return -} - -func DeleteFooBar2(arg1 FooBar2) { - _swig_wrap_delete_FooBar2(arg1.Swigcptr()) -} - -func (p SwigcptrFooBar2) SwigIsFoo() { -} - -func (p SwigcptrFooBar2) SwigGetFoo() Foo { - return SwigcptrFoo(p.Swigcptr()) -} - -var _wrap_FooBar2_SwigGetBar unsafe.Pointer - -func _swig_wrap_FooBar2_SwigGetBar(base SwigcptrFooBar2) (_ SwigcptrBar) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_FooBar2_SwigGetBar, _swig_p) - return -} - -func (arg1 SwigcptrFooBar2) SwigGetBar() (_swig_ret Bar) { - return _swig_wrap_FooBar2_SwigGetBar(arg1) -} - -type FooBar2 interface { - Swigcptr() uintptr - SwigIsFooBar2() - Blah(a ...interface{}) interface{} - SwigIsFoo() - SwigGetFoo() Foo - SwigGetBar() (_swig_ret Bar) -} - -type SwigcptrFooBar3 uintptr - -func (p SwigcptrFooBar3) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrFooBar3) SwigIsFooBar3() { -} - -var _wrap_FooBar3_blah__SWIG_0_0 unsafe.Pointer - -func _swig_wrap_FooBar3_blah__SWIG_0_0(base SwigcptrFooBar3, _ int) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_FooBar3_blah__SWIG_0_0, _swig_p) - return -} - -func (arg1 SwigcptrFooBar3) Blah__SWIG_0_0(arg2 int) (_swig_ret int) { - return _swig_wrap_FooBar3_blah__SWIG_0_0(arg1, arg2) -} - -var _wrap_FooBar3_blah__SWIG_1 unsafe.Pointer - -func _swig_wrap_FooBar3_blah__SWIG_1(base SwigcptrFooBar3, _ string) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_FooBar3_blah__SWIG_1, _swig_p) - return -} - -func (arg1 SwigcptrFooBar3) Blah__SWIG_1(arg2 string) (_swig_ret string) { - return _swig_wrap_FooBar3_blah__SWIG_1(arg1, arg2) -} - -var _wrap_FooBar3_blah__SWIG_2_0 unsafe.Pointer - -func _swig_wrap_FooBar3_blah__SWIG_2_0(base SwigcptrFooBar3, _ float64) (_ float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_FooBar3_blah__SWIG_2_0, _swig_p) - return -} - -func (arg1 SwigcptrFooBar3) Blah__SWIG_2_0(arg2 float64) (_swig_ret float64) { - return _swig_wrap_FooBar3_blah__SWIG_2_0(arg1, arg2) -} - -func (p SwigcptrFooBar3) Blah(a ...interface{}) interface{} { - argc := len(a) - if argc == 1 { - if _, ok := a[0].(int); !ok { - goto check_1 - } - return p.Blah__SWIG_0_0(a[0].(int)) - } -check_1: - if argc == 1 { - if _, ok := a[0].(float64); !ok { - goto check_2 - } - return p.Blah__SWIG_2_0(a[0].(float64)) - } -check_2: - if argc == 1 { - return p.Blah__SWIG_1(a[0].(string)) - } - panic("No match for overloaded function call") -} - -var _wrap_new_FooBar3 unsafe.Pointer - -func _swig_wrap_new_FooBar3() (base SwigcptrFooBar3) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_FooBar3, _swig_p) - return -} - -func NewFooBar3() (_swig_ret FooBar3) { - return _swig_wrap_new_FooBar3() -} - -var _wrap_delete_FooBar3 unsafe.Pointer - -func _swig_wrap_delete_FooBar3(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_FooBar3, _swig_p) - return -} - -func DeleteFooBar3(arg1 FooBar3) { - _swig_wrap_delete_FooBar3(arg1.Swigcptr()) -} - -func (p SwigcptrFooBar3) SwigIsFoo() { -} - -func (p SwigcptrFooBar3) SwigGetFoo() Foo { - return SwigcptrFoo(p.Swigcptr()) -} - -var _wrap_FooBar3_SwigGetBar unsafe.Pointer - -func _swig_wrap_FooBar3_SwigGetBar(base SwigcptrFooBar3) (_ SwigcptrBar) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_FooBar3_SwigGetBar, _swig_p) - return -} - -func (arg1 SwigcptrFooBar3) SwigGetBar() (_swig_ret Bar) { - return _swig_wrap_FooBar3_SwigGetBar(arg1) -} - -type FooBar3 interface { - Swigcptr() uintptr - SwigIsFooBar3() - Blah(a ...interface{}) interface{} - SwigIsFoo() - SwigGetFoo() Foo - SwigGetBar() (_swig_ret Bar) -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/using_composition_runme b/Examples/test-suite/go/using_composition_runme deleted file mode 100755 index c8a0dc3cf..000000000 Binary files a/Examples/test-suite/go/using_composition_runme and /dev/null differ diff --git a/Examples/test-suite/go/using_directive_and_declaration.go b/Examples/test-suite/go/using_directive_and_declaration.go deleted file mode 100644 index 13e2a6825..000000000 --- a/Examples/test-suite/go/using_directive_and_declaration.go +++ /dev/null @@ -1,499 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../using_directive_and_declaration.i - -package using_directive_and_declaration - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrThing1 uintptr - -func (p SwigcptrThing1) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrThing1) SwigIsThing1() { -} - -var _wrap_new_Thing1 unsafe.Pointer - -func _swig_wrap_new_Thing1() (base SwigcptrThing1) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Thing1, _swig_p) - return -} - -func NewThing1() (_swig_ret Thing1) { - return _swig_wrap_new_Thing1() -} - -var _wrap_delete_Thing1 unsafe.Pointer - -func _swig_wrap_delete_Thing1(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Thing1, _swig_p) - return -} - -func DeleteThing1(arg1 Thing1) { - _swig_wrap_delete_Thing1(arg1.Swigcptr()) -} - -type Thing1 interface { - Swigcptr() uintptr - SwigIsThing1() -} - -var _wrap_useit1 unsafe.Pointer - -func _swig_wrap_useit1(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_useit1, _swig_p) - return -} - -func Useit1(arg1 Thing1) { - _swig_wrap_useit1(arg1.Swigcptr()) -} - -type SwigcptrThing2 uintptr - -func (p SwigcptrThing2) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrThing2) SwigIsThing2() { -} - -var _wrap_new_Thing2 unsafe.Pointer - -func _swig_wrap_new_Thing2() (base SwigcptrThing2) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Thing2, _swig_p) - return -} - -func NewThing2() (_swig_ret Thing2) { - return _swig_wrap_new_Thing2() -} - -var _wrap_delete_Thing2 unsafe.Pointer - -func _swig_wrap_delete_Thing2(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Thing2, _swig_p) - return -} - -func DeleteThing2(arg1 Thing2) { - _swig_wrap_delete_Thing2(arg1.Swigcptr()) -} - -type Thing2 interface { - Swigcptr() uintptr - SwigIsThing2() -} - -var _wrap_useit2 unsafe.Pointer - -func _swig_wrap_useit2(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_useit2, _swig_p) - return -} - -func Useit2(arg1 Thing2) { - _swig_wrap_useit2(arg1.Swigcptr()) -} - -type SwigcptrThing3 uintptr - -func (p SwigcptrThing3) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrThing3) SwigIsThing3() { -} - -var _wrap_new_Thing3 unsafe.Pointer - -func _swig_wrap_new_Thing3() (base SwigcptrThing3) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Thing3, _swig_p) - return -} - -func NewThing3() (_swig_ret Thing3) { - return _swig_wrap_new_Thing3() -} - -var _wrap_delete_Thing3 unsafe.Pointer - -func _swig_wrap_delete_Thing3(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Thing3, _swig_p) - return -} - -func DeleteThing3(arg1 Thing3) { - _swig_wrap_delete_Thing3(arg1.Swigcptr()) -} - -type Thing3 interface { - Swigcptr() uintptr - SwigIsThing3() -} - -var _wrap_useit3 unsafe.Pointer - -func _swig_wrap_useit3(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_useit3, _swig_p) - return -} - -func Useit3(arg1 Thing3) { - _swig_wrap_useit3(arg1.Swigcptr()) -} - -type SwigcptrThing4 uintptr - -func (p SwigcptrThing4) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrThing4) SwigIsThing4() { -} - -var _wrap_new_Thing4 unsafe.Pointer - -func _swig_wrap_new_Thing4() (base SwigcptrThing4) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Thing4, _swig_p) - return -} - -func NewThing4() (_swig_ret Thing4) { - return _swig_wrap_new_Thing4() -} - -var _wrap_delete_Thing4 unsafe.Pointer - -func _swig_wrap_delete_Thing4(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Thing4, _swig_p) - return -} - -func DeleteThing4(arg1 Thing4) { - _swig_wrap_delete_Thing4(arg1.Swigcptr()) -} - -type Thing4 interface { - Swigcptr() uintptr - SwigIsThing4() -} - -var _wrap_useit4 unsafe.Pointer - -func _swig_wrap_useit4(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_useit4, _swig_p) - return -} - -func Useit4(arg1 Thing4) { - _swig_wrap_useit4(arg1.Swigcptr()) -} - -type SwigcptrThing5 uintptr - -func (p SwigcptrThing5) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrThing5) SwigIsThing5() { -} - -var _wrap_new_Thing5 unsafe.Pointer - -func _swig_wrap_new_Thing5() (base SwigcptrThing5) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Thing5, _swig_p) - return -} - -func NewThing5() (_swig_ret Thing5) { - return _swig_wrap_new_Thing5() -} - -var _wrap_delete_Thing5 unsafe.Pointer - -func _swig_wrap_delete_Thing5(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Thing5, _swig_p) - return -} - -func DeleteThing5(arg1 Thing5) { - _swig_wrap_delete_Thing5(arg1.Swigcptr()) -} - -type Thing5 interface { - Swigcptr() uintptr - SwigIsThing5() -} - -var _wrap_useit5 unsafe.Pointer - -func _swig_wrap_useit5(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_useit5, _swig_p) - return -} - -func Useit5(arg1 Thing5) { - _swig_wrap_useit5(arg1.Swigcptr()) -} - -type SwigcptrThing6a uintptr - -func (p SwigcptrThing6a) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrThing6a) SwigIsThing6a() { -} - -var _wrap_Thing6a_a unsafe.Pointer - -func _swig_wrap_Thing6a_a(base SwigcptrThing6a) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Thing6a_a, _swig_p) - return -} - -func (arg1 SwigcptrThing6a) A() { - _swig_wrap_Thing6a_a(arg1) -} - -var _wrap_new_Thing6a unsafe.Pointer - -func _swig_wrap_new_Thing6a() (base SwigcptrThing6a) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Thing6a, _swig_p) - return -} - -func NewThing6a() (_swig_ret Thing6a) { - return _swig_wrap_new_Thing6a() -} - -var _wrap_delete_Thing6a unsafe.Pointer - -func _swig_wrap_delete_Thing6a(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Thing6a, _swig_p) - return -} - -func DeleteThing6a(arg1 Thing6a) { - _swig_wrap_delete_Thing6a(arg1.Swigcptr()) -} - -type Thing6a interface { - Swigcptr() uintptr - SwigIsThing6a() - A() -} - -type SwigcptrThing6 uintptr - -func (p SwigcptrThing6) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrThing6) SwigIsThing6() { -} - -var _wrap_Thing6_b unsafe.Pointer - -func _swig_wrap_Thing6_b(base SwigcptrThing6) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Thing6_b, _swig_p) - return -} - -func (arg1 SwigcptrThing6) B() { - _swig_wrap_Thing6_b(arg1) -} - -var _wrap_new_Thing6 unsafe.Pointer - -func _swig_wrap_new_Thing6() (base SwigcptrThing6) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Thing6, _swig_p) - return -} - -func NewThing6() (_swig_ret Thing6) { - return _swig_wrap_new_Thing6() -} - -var _wrap_delete_Thing6 unsafe.Pointer - -func _swig_wrap_delete_Thing6(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Thing6, _swig_p) - return -} - -func DeleteThing6(arg1 Thing6) { - _swig_wrap_delete_Thing6(arg1.Swigcptr()) -} - -type Thing6 interface { - Swigcptr() uintptr - SwigIsThing6() - B() -} - -var _wrap_useit6 unsafe.Pointer - -func _swig_wrap_useit6(base uintptr, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_useit6, _swig_p) - return -} - -func Useit6(arg1 Thing6a, arg2 Thing6) { - _swig_wrap_useit6(arg1.Swigcptr(), arg2.Swigcptr()) -} - -type SwigcptrThing7 uintptr - -func (p SwigcptrThing7) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrThing7) SwigIsThing7() { -} - -var _wrap_new_Thing7 unsafe.Pointer - -func _swig_wrap_new_Thing7() (base SwigcptrThing7) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Thing7, _swig_p) - return -} - -func NewThing7() (_swig_ret Thing7) { - return _swig_wrap_new_Thing7() -} - -var _wrap_delete_Thing7 unsafe.Pointer - -func _swig_wrap_delete_Thing7(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Thing7, _swig_p) - return -} - -func DeleteThing7(arg1 Thing7) { - _swig_wrap_delete_Thing7(arg1.Swigcptr()) -} - -type Thing7 interface { - Swigcptr() uintptr - SwigIsThing7() -} - -var _wrap_useit7 unsafe.Pointer - -func _swig_wrap_useit7(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_useit7, _swig_p) - return -} - -func Useit7(arg1 Thing7) { - _swig_wrap_useit7(arg1.Swigcptr()) -} - -var _wrap_useit7a unsafe.Pointer - -func _swig_wrap_useit7a(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_useit7a, _swig_p) - return -} - -func Useit7a(arg1 Thing7) { - _swig_wrap_useit7a(arg1.Swigcptr()) -} - -var _wrap_useit7b unsafe.Pointer - -func _swig_wrap_useit7b(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_useit7b, _swig_p) - return -} - -func Useit7b(arg1 Thing7) { - _swig_wrap_useit7b(arg1.Swigcptr()) -} - -var _wrap_useit7c unsafe.Pointer - -func _swig_wrap_useit7c(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_useit7c, _swig_p) - return -} - -func Useit7c(arg1 Thing7) { - _swig_wrap_useit7c(arg1.Swigcptr()) -} - -var _wrap_useit7d unsafe.Pointer - -func _swig_wrap_useit7d(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_useit7d, _swig_p) - return -} - -func Useit7d(arg1 Thing7) { - _swig_wrap_useit7d(arg1.Swigcptr()) -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/using_directive_and_declaration_forward.go b/Examples/test-suite/go/using_directive_and_declaration_forward.go deleted file mode 100644 index 8d8fe2893..000000000 --- a/Examples/test-suite/go/using_directive_and_declaration_forward.go +++ /dev/null @@ -1,613 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../using_directive_and_declaration_forward.i - -package using_directive_and_declaration_forward - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrThing1 uintptr - -func (p SwigcptrThing1) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrThing1) SwigIsThing1() { -} - -var _wrap_new_Thing1 unsafe.Pointer - -func _swig_wrap_new_Thing1() (base SwigcptrThing1) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Thing1, _swig_p) - return -} - -func NewThing1() (_swig_ret Thing1) { - return _swig_wrap_new_Thing1() -} - -var _wrap_delete_Thing1 unsafe.Pointer - -func _swig_wrap_delete_Thing1(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Thing1, _swig_p) - return -} - -func DeleteThing1(arg1 Thing1) { - _swig_wrap_delete_Thing1(arg1.Swigcptr()) -} - -type Thing1 interface { - Swigcptr() uintptr - SwigIsThing1() -} - -var _wrap_useit1 unsafe.Pointer - -func _swig_wrap_useit1(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_useit1, _swig_p) - return -} - -func Useit1(arg1 Thing1) { - _swig_wrap_useit1(arg1.Swigcptr()) -} - -var _wrap_useit1a unsafe.Pointer - -func _swig_wrap_useit1a(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_useit1a, _swig_p) - return -} - -func Useit1a(arg1 Thing1) { - _swig_wrap_useit1a(arg1.Swigcptr()) -} - -var _wrap_useit1b unsafe.Pointer - -func _swig_wrap_useit1b(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_useit1b, _swig_p) - return -} - -func Useit1b(arg1 Thing1) { - _swig_wrap_useit1b(arg1.Swigcptr()) -} - -var _wrap_useit1c unsafe.Pointer - -func _swig_wrap_useit1c(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_useit1c, _swig_p) - return -} - -func Useit1c(arg1 Thing1) { - _swig_wrap_useit1c(arg1.Swigcptr()) -} - -type SwigcptrThing2 uintptr - -func (p SwigcptrThing2) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrThing2) SwigIsThing2() { -} - -var _wrap_new_Thing2 unsafe.Pointer - -func _swig_wrap_new_Thing2() (base SwigcptrThing2) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Thing2, _swig_p) - return -} - -func NewThing2() (_swig_ret Thing2) { - return _swig_wrap_new_Thing2() -} - -var _wrap_delete_Thing2 unsafe.Pointer - -func _swig_wrap_delete_Thing2(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Thing2, _swig_p) - return -} - -func DeleteThing2(arg1 Thing2) { - _swig_wrap_delete_Thing2(arg1.Swigcptr()) -} - -type Thing2 interface { - Swigcptr() uintptr - SwigIsThing2() -} - -var _wrap_useit2 unsafe.Pointer - -func _swig_wrap_useit2(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_useit2, _swig_p) - return -} - -func Useit2(arg1 Thing2) { - _swig_wrap_useit2(arg1.Swigcptr()) -} - -var _wrap_useit2a unsafe.Pointer - -func _swig_wrap_useit2a(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_useit2a, _swig_p) - return -} - -func Useit2a(arg1 Thing2) { - _swig_wrap_useit2a(arg1.Swigcptr()) -} - -var _wrap_useit2b unsafe.Pointer - -func _swig_wrap_useit2b(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_useit2b, _swig_p) - return -} - -func Useit2b(arg1 Thing2) { - _swig_wrap_useit2b(arg1.Swigcptr()) -} - -var _wrap_useit2c unsafe.Pointer - -func _swig_wrap_useit2c(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_useit2c, _swig_p) - return -} - -func Useit2c(arg1 Thing2) { - _swig_wrap_useit2c(arg1.Swigcptr()) -} - -var _wrap_useit2d unsafe.Pointer - -func _swig_wrap_useit2d(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_useit2d, _swig_p) - return -} - -func Useit2d(arg1 Thing2) { - _swig_wrap_useit2d(arg1.Swigcptr()) -} - -type SwigcptrThing3 uintptr - -func (p SwigcptrThing3) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrThing3) SwigIsThing3() { -} - -var _wrap_new_Thing3 unsafe.Pointer - -func _swig_wrap_new_Thing3() (base SwigcptrThing3) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Thing3, _swig_p) - return -} - -func NewThing3() (_swig_ret Thing3) { - return _swig_wrap_new_Thing3() -} - -var _wrap_delete_Thing3 unsafe.Pointer - -func _swig_wrap_delete_Thing3(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Thing3, _swig_p) - return -} - -func DeleteThing3(arg1 Thing3) { - _swig_wrap_delete_Thing3(arg1.Swigcptr()) -} - -type Thing3 interface { - Swigcptr() uintptr - SwigIsThing3() -} - -var _wrap_useit3 unsafe.Pointer - -func _swig_wrap_useit3(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_useit3, _swig_p) - return -} - -func Useit3(arg1 Thing3) { - _swig_wrap_useit3(arg1.Swigcptr()) -} - -var _wrap_useit3a unsafe.Pointer - -func _swig_wrap_useit3a(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_useit3a, _swig_p) - return -} - -func Useit3a(arg1 Thing3) { - _swig_wrap_useit3a(arg1.Swigcptr()) -} - -var _wrap_useit3b unsafe.Pointer - -func _swig_wrap_useit3b(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_useit3b, _swig_p) - return -} - -func Useit3b(arg1 Thing3) { - _swig_wrap_useit3b(arg1.Swigcptr()) -} - -var _wrap_useit3c unsafe.Pointer - -func _swig_wrap_useit3c(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_useit3c, _swig_p) - return -} - -func Useit3c(arg1 Thing3) { - _swig_wrap_useit3c(arg1.Swigcptr()) -} - -var _wrap_useit3d unsafe.Pointer - -func _swig_wrap_useit3d(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_useit3d, _swig_p) - return -} - -func Useit3d(arg1 Thing3) { - _swig_wrap_useit3d(arg1.Swigcptr()) -} - -type SwigcptrThing4 uintptr - -func (p SwigcptrThing4) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrThing4) SwigIsThing4() { -} - -var _wrap_new_Thing4 unsafe.Pointer - -func _swig_wrap_new_Thing4() (base SwigcptrThing4) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Thing4, _swig_p) - return -} - -func NewThing4() (_swig_ret Thing4) { - return _swig_wrap_new_Thing4() -} - -var _wrap_delete_Thing4 unsafe.Pointer - -func _swig_wrap_delete_Thing4(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Thing4, _swig_p) - return -} - -func DeleteThing4(arg1 Thing4) { - _swig_wrap_delete_Thing4(arg1.Swigcptr()) -} - -type Thing4 interface { - Swigcptr() uintptr - SwigIsThing4() -} - -var _wrap_useit4 unsafe.Pointer - -func _swig_wrap_useit4(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_useit4, _swig_p) - return -} - -func Useit4(arg1 Thing4) { - _swig_wrap_useit4(arg1.Swigcptr()) -} - -var _wrap_useit4a unsafe.Pointer - -func _swig_wrap_useit4a(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_useit4a, _swig_p) - return -} - -func Useit4a(arg1 Thing4) { - _swig_wrap_useit4a(arg1.Swigcptr()) -} - -var _wrap_useit4b unsafe.Pointer - -func _swig_wrap_useit4b(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_useit4b, _swig_p) - return -} - -func Useit4b(arg1 Thing4) { - _swig_wrap_useit4b(arg1.Swigcptr()) -} - -var _wrap_useit4c unsafe.Pointer - -func _swig_wrap_useit4c(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_useit4c, _swig_p) - return -} - -func Useit4c(arg1 Thing4) { - _swig_wrap_useit4c(arg1.Swigcptr()) -} - -var _wrap_useit4d unsafe.Pointer - -func _swig_wrap_useit4d(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_useit4d, _swig_p) - return -} - -func Useit4d(arg1 Thing4) { - _swig_wrap_useit4d(arg1.Swigcptr()) -} - -type SwigcptrThing5 uintptr - -func (p SwigcptrThing5) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrThing5) SwigIsThing5() { -} - -var _wrap_new_Thing5 unsafe.Pointer - -func _swig_wrap_new_Thing5() (base SwigcptrThing5) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Thing5, _swig_p) - return -} - -func NewThing5() (_swig_ret Thing5) { - return _swig_wrap_new_Thing5() -} - -var _wrap_delete_Thing5 unsafe.Pointer - -func _swig_wrap_delete_Thing5(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Thing5, _swig_p) - return -} - -func DeleteThing5(arg1 Thing5) { - _swig_wrap_delete_Thing5(arg1.Swigcptr()) -} - -type Thing5 interface { - Swigcptr() uintptr - SwigIsThing5() -} - -var _wrap_useit5 unsafe.Pointer - -func _swig_wrap_useit5(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_useit5, _swig_p) - return -} - -func Useit5(arg1 Thing5) { - _swig_wrap_useit5(arg1.Swigcptr()) -} - -var _wrap_useit5a unsafe.Pointer - -func _swig_wrap_useit5a(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_useit5a, _swig_p) - return -} - -func Useit5a(arg1 Thing5) { - _swig_wrap_useit5a(arg1.Swigcptr()) -} - -var _wrap_useit5b unsafe.Pointer - -func _swig_wrap_useit5b(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_useit5b, _swig_p) - return -} - -func Useit5b(arg1 Thing5) { - _swig_wrap_useit5b(arg1.Swigcptr()) -} - -var _wrap_useit5c unsafe.Pointer - -func _swig_wrap_useit5c(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_useit5c, _swig_p) - return -} - -func Useit5c(arg1 Thing5) { - _swig_wrap_useit5c(arg1.Swigcptr()) -} - -var _wrap_useit5d unsafe.Pointer - -func _swig_wrap_useit5d(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_useit5d, _swig_p) - return -} - -func Useit5d(arg1 Thing5) { - _swig_wrap_useit5d(arg1.Swigcptr()) -} - -type SwigcptrThing7 uintptr - -func (p SwigcptrThing7) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrThing7) SwigIsThing7() { -} - -var _wrap_new_Thing7 unsafe.Pointer - -func _swig_wrap_new_Thing7() (base SwigcptrThing7) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Thing7, _swig_p) - return -} - -func NewThing7() (_swig_ret Thing7) { - return _swig_wrap_new_Thing7() -} - -var _wrap_delete_Thing7 unsafe.Pointer - -func _swig_wrap_delete_Thing7(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Thing7, _swig_p) - return -} - -func DeleteThing7(arg1 Thing7) { - _swig_wrap_delete_Thing7(arg1.Swigcptr()) -} - -type Thing7 interface { - Swigcptr() uintptr - SwigIsThing7() -} - -var _wrap_useit7 unsafe.Pointer - -func _swig_wrap_useit7(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_useit7, _swig_p) - return -} - -func Useit7(arg1 Thing7) { - _swig_wrap_useit7(arg1.Swigcptr()) -} - -var _wrap_useit7a unsafe.Pointer - -func _swig_wrap_useit7a(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_useit7a, _swig_p) - return -} - -func Useit7a(arg1 Thing7) { - _swig_wrap_useit7a(arg1.Swigcptr()) -} - -var _wrap_useit7b unsafe.Pointer - -func _swig_wrap_useit7b(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_useit7b, _swig_p) - return -} - -func Useit7b(arg1 Thing7) { - _swig_wrap_useit7b(arg1.Swigcptr()) -} - -var _wrap_useit7c unsafe.Pointer - -func _swig_wrap_useit7c(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_useit7c, _swig_p) - return -} - -func Useit7c(arg1 Thing7) { - _swig_wrap_useit7c(arg1.Swigcptr()) -} - -var _wrap_useit7d unsafe.Pointer - -func _swig_wrap_useit7d(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_useit7d, _swig_p) - return -} - -func Useit7d(arg1 Thing7) { - _swig_wrap_useit7d(arg1.Swigcptr()) -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/using_extend.go b/Examples/test-suite/go/using_extend.go deleted file mode 100644 index 4f9a30c1e..000000000 --- a/Examples/test-suite/go/using_extend.go +++ /dev/null @@ -1,412 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../using_extend.i - -package using_extend - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrFoo uintptr - -func (p SwigcptrFoo) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrFoo) SwigIsFoo() { -} - -var _wrap_Foo_blah__SWIG_0 unsafe.Pointer - -func _swig_wrap_Foo_blah__SWIG_0(base SwigcptrFoo, _ int) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_blah__SWIG_0, _swig_p) - return -} - -func (arg1 SwigcptrFoo) Blah__SWIG_0(arg2 int) (_swig_ret int) { - return _swig_wrap_Foo_blah__SWIG_0(arg1, arg2) -} - -var _wrap_Foo_blah__SWIG_1 unsafe.Pointer - -func _swig_wrap_Foo_blah__SWIG_1(base SwigcptrFoo, _ string) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_blah__SWIG_1, _swig_p) - return -} - -func (arg1 SwigcptrFoo) Blah__SWIG_1(arg2 string) (_swig_ret string) { - return _swig_wrap_Foo_blah__SWIG_1(arg1, arg2) -} - -var _wrap_Foo_blah__SWIG_2 unsafe.Pointer - -func _swig_wrap_Foo_blah__SWIG_2(base SwigcptrFoo, _ int, _ int) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_blah__SWIG_2, _swig_p) - return -} - -func (arg1 SwigcptrFoo) Blah__SWIG_2(arg2 int, arg3 int) (_swig_ret int) { - return _swig_wrap_Foo_blah__SWIG_2(arg1, arg2, arg3) -} - -func (p SwigcptrFoo) Blah(a ...interface{}) interface{} { - argc := len(a) - if argc == 1 { - if _, ok := a[0].(int); !ok { - goto check_1 - } - return p.Blah__SWIG_0(a[0].(int)) - } -check_1: - if argc == 1 { - return p.Blah__SWIG_1(a[0].(string)) - } - if argc == 2 { - return p.Blah__SWIG_2(a[0].(int), a[1].(int)) - } - panic("No match for overloaded function call") -} - -var _wrap_new_Foo unsafe.Pointer - -func _swig_wrap_new_Foo() (base SwigcptrFoo) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Foo, _swig_p) - return -} - -func NewFoo() (_swig_ret Foo) { - return _swig_wrap_new_Foo() -} - -var _wrap_delete_Foo unsafe.Pointer - -func _swig_wrap_delete_Foo(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Foo, _swig_p) - return -} - -func DeleteFoo(arg1 Foo) { - _swig_wrap_delete_Foo(arg1.Swigcptr()) -} - -type Foo interface { - Swigcptr() uintptr - SwigIsFoo() - Blah(a ...interface{}) interface{} -} - -type SwigcptrBar uintptr - -func (p SwigcptrBar) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrBar) SwigIsBar() { -} - -var _wrap_Bar_duh1 unsafe.Pointer - -func _swig_wrap_Bar_duh1(base SwigcptrBar) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Bar_duh1, _swig_p) - return -} - -func (arg1 SwigcptrBar) Duh1() (_swig_ret int) { - return _swig_wrap_Bar_duh1(arg1) -} - -var _wrap_Bar_duh unsafe.Pointer - -func _swig_wrap_Bar_duh(base SwigcptrBar, _ int) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Bar_duh, _swig_p) - return -} - -func (arg1 SwigcptrBar) Duh(arg2 int) (_swig_ret int) { - return _swig_wrap_Bar_duh(arg1, arg2) -} - -var _wrap_Bar_blah__SWIG_0 unsafe.Pointer - -func _swig_wrap_Bar_blah__SWIG_0(base SwigcptrBar, _ float64) (_ float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Bar_blah__SWIG_0, _swig_p) - return -} - -func (arg1 SwigcptrBar) Blah__SWIG_0(arg2 float64) (_swig_ret float64) { - return _swig_wrap_Bar_blah__SWIG_0(arg1, arg2) -} - -var _wrap_Bar_blah__SWIG_1 unsafe.Pointer - -func _swig_wrap_Bar_blah__SWIG_1(base SwigcptrBar, _ float64, _ float64) (_ float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Bar_blah__SWIG_1, _swig_p) - return -} - -func (arg1 SwigcptrBar) Blah__SWIG_1(arg2 float64, arg3 float64) (_swig_ret float64) { - return _swig_wrap_Bar_blah__SWIG_1(arg1, arg2, arg3) -} - -func (p SwigcptrBar) Blah(a ...interface{}) float64 { - argc := len(a) - if argc == 1 { - return p.Blah__SWIG_0(a[0].(float64)) - } - if argc == 2 { - return p.Blah__SWIG_1(a[0].(float64), a[1].(float64)) - } - panic("No match for overloaded function call") -} - -var _wrap_new_Bar unsafe.Pointer - -func _swig_wrap_new_Bar() (base SwigcptrBar) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Bar, _swig_p) - return -} - -func NewBar() (_swig_ret Bar) { - return _swig_wrap_new_Bar() -} - -var _wrap_delete_Bar unsafe.Pointer - -func _swig_wrap_delete_Bar(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Bar, _swig_p) - return -} - -func DeleteBar(arg1 Bar) { - _swig_wrap_delete_Bar(arg1.Swigcptr()) -} - -type Bar interface { - Swigcptr() uintptr - SwigIsBar() - Duh1() (_swig_ret int) - Duh(arg2 int) (_swig_ret int) - Blah(a ...interface{}) float64 -} - -type SwigcptrFooBar uintptr - -func (p SwigcptrFooBar) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrFooBar) SwigIsFooBar() { -} - -var _wrap_FooBar_blah__SWIG_0_0 unsafe.Pointer - -func _swig_wrap_FooBar_blah__SWIG_0_0(base SwigcptrFooBar, _ int) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_FooBar_blah__SWIG_0_0, _swig_p) - return -} - -func (arg1 SwigcptrFooBar) Blah__SWIG_0_0(arg2 int) (_swig_ret int) { - return _swig_wrap_FooBar_blah__SWIG_0_0(arg1, arg2) -} - -var _wrap_FooBar_blah__SWIG_0_1 unsafe.Pointer - -func _swig_wrap_FooBar_blah__SWIG_0_1(base SwigcptrFooBar, _ int, _ int) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_FooBar_blah__SWIG_0_1, _swig_p) - return -} - -func (arg1 SwigcptrFooBar) Blah__SWIG_0_1(arg2 int, arg3 int) (_swig_ret int) { - return _swig_wrap_FooBar_blah__SWIG_0_1(arg1, arg2, arg3) -} - -var _wrap_FooBar_blah__SWIG_1_0 unsafe.Pointer - -func _swig_wrap_FooBar_blah__SWIG_1_0(base SwigcptrFooBar, _ float64) (_ float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_FooBar_blah__SWIG_1_0, _swig_p) - return -} - -func (arg1 SwigcptrFooBar) Blah__SWIG_1_0(arg2 float64) (_swig_ret float64) { - return _swig_wrap_FooBar_blah__SWIG_1_0(arg1, arg2) -} - -var _wrap_FooBar_blah__SWIG_1_1 unsafe.Pointer - -func _swig_wrap_FooBar_blah__SWIG_1_1(base SwigcptrFooBar, _ float64, _ float64) (_ float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_FooBar_blah__SWIG_1_1, _swig_p) - return -} - -func (arg1 SwigcptrFooBar) Blah__SWIG_1_1(arg2 float64, arg3 float64) (_swig_ret float64) { - return _swig_wrap_FooBar_blah__SWIG_1_1(arg1, arg2, arg3) -} - -var _wrap_FooBar_blah__SWIG_2 unsafe.Pointer - -func _swig_wrap_FooBar_blah__SWIG_2(base SwigcptrFooBar, _ string) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_FooBar_blah__SWIG_2, _swig_p) - return -} - -func (arg1 SwigcptrFooBar) Blah__SWIG_2(arg2 string) (_swig_ret string) { - return _swig_wrap_FooBar_blah__SWIG_2(arg1, arg2) -} - -func (p SwigcptrFooBar) Blah(a ...interface{}) interface{} { - argc := len(a) - if argc == 1 { - if _, ok := a[0].(int); !ok { - goto check_1 - } - return p.Blah__SWIG_0_0(a[0].(int)) - } -check_1: - if argc == 1 { - if _, ok := a[0].(float64); !ok { - goto check_2 - } - return p.Blah__SWIG_1_0(a[0].(float64)) - } -check_2: - if argc == 1 { - return p.Blah__SWIG_2(a[0].(string)) - } - if argc == 2 { - if _, ok := a[0].(int); !ok { - goto check_4 - } - if _, ok := a[1].(int); !ok { - goto check_4 - } - return p.Blah__SWIG_0_1(a[0].(int), a[1].(int)) - } -check_4: - if argc == 2 { - return p.Blah__SWIG_1_1(a[0].(float64), a[1].(float64)) - } - panic("No match for overloaded function call") -} - -var _wrap_FooBar_duh1 unsafe.Pointer - -func _swig_wrap_FooBar_duh1(base SwigcptrFooBar) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_FooBar_duh1, _swig_p) - return -} - -func (arg1 SwigcptrFooBar) Duh1() (_swig_ret int) { - return _swig_wrap_FooBar_duh1(arg1) -} - -var _wrap_FooBar_duh unsafe.Pointer - -func _swig_wrap_FooBar_duh(base SwigcptrFooBar, _ int) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_FooBar_duh, _swig_p) - return -} - -func (arg1 SwigcptrFooBar) Duh(arg2 int) (_swig_ret int) { - return _swig_wrap_FooBar_duh(arg1, arg2) -} - -var _wrap_new_FooBar unsafe.Pointer - -func _swig_wrap_new_FooBar() (base SwigcptrFooBar) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_FooBar, _swig_p) - return -} - -func NewFooBar() (_swig_ret FooBar) { - return _swig_wrap_new_FooBar() -} - -var _wrap_delete_FooBar unsafe.Pointer - -func _swig_wrap_delete_FooBar(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_FooBar, _swig_p) - return -} - -func DeleteFooBar(arg1 FooBar) { - _swig_wrap_delete_FooBar(arg1.Swigcptr()) -} - -func (p SwigcptrFooBar) SwigIsFoo() { -} - -func (p SwigcptrFooBar) SwigGetFoo() Foo { - return SwigcptrFoo(p.Swigcptr()) -} - -var _wrap_FooBar_SwigGetBar unsafe.Pointer - -func _swig_wrap_FooBar_SwigGetBar(base SwigcptrFooBar) (_ SwigcptrBar) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_FooBar_SwigGetBar, _swig_p) - return -} - -func (arg1 SwigcptrFooBar) SwigGetBar() (_swig_ret Bar) { - return _swig_wrap_FooBar_SwigGetBar(arg1) -} - -type FooBar interface { - Swigcptr() uintptr - SwigIsFooBar() - Blah(a ...interface{}) interface{} - Duh1() (_swig_ret int) - Duh(arg2 int) (_swig_ret int) - SwigIsFoo() - SwigGetFoo() Foo - SwigGetBar() (_swig_ret Bar) -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/using_extend_runme b/Examples/test-suite/go/using_extend_runme deleted file mode 100755 index 79975e044..000000000 Binary files a/Examples/test-suite/go/using_extend_runme and /dev/null differ diff --git a/Examples/test-suite/go/using_inherit.go b/Examples/test-suite/go/using_inherit.go deleted file mode 100644 index 297cf1482..000000000 --- a/Examples/test-suite/go/using_inherit.go +++ /dev/null @@ -1,637 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../using_inherit.i - -package using_inherit - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrFoo uintptr - -func (p SwigcptrFoo) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrFoo) SwigIsFoo() { -} - -var _wrap_Foo_test__SWIG_0 unsafe.Pointer - -func _swig_wrap_Foo_test__SWIG_0(base SwigcptrFoo, _ int) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_test__SWIG_0, _swig_p) - return -} - -func (arg1 SwigcptrFoo) Test__SWIG_0(arg2 int) (_swig_ret int) { - return _swig_wrap_Foo_test__SWIG_0(arg1, arg2) -} - -var _wrap_Foo_test__SWIG_1 unsafe.Pointer - -func _swig_wrap_Foo_test__SWIG_1(base SwigcptrFoo, _ float64) (_ float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_test__SWIG_1, _swig_p) - return -} - -func (arg1 SwigcptrFoo) Test__SWIG_1(arg2 float64) (_swig_ret float64) { - return _swig_wrap_Foo_test__SWIG_1(arg1, arg2) -} - -func (p SwigcptrFoo) Test(a ...interface{}) interface{} { - argc := len(a) - if argc == 1 { - if _, ok := a[0].(int); !ok { - goto check_1 - } - return p.Test__SWIG_0(a[0].(int)) - } -check_1: - if argc == 1 { - return p.Test__SWIG_1(a[0].(float64)) - } - panic("No match for overloaded function call") -} - -var _wrap_new_Foo unsafe.Pointer - -func _swig_wrap_new_Foo() (base SwigcptrFoo) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Foo, _swig_p) - return -} - -func NewFoo() (_swig_ret Foo) { - return _swig_wrap_new_Foo() -} - -var _wrap_delete_Foo unsafe.Pointer - -func _swig_wrap_delete_Foo(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Foo, _swig_p) - return -} - -func DeleteFoo(arg1 Foo) { - _swig_wrap_delete_Foo(arg1.Swigcptr()) -} - -type Foo interface { - Swigcptr() uintptr - SwigIsFoo() - Test(a ...interface{}) interface{} -} - -type SwigcptrBar uintptr - -func (p SwigcptrBar) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrBar) SwigIsBar() { -} - -var _wrap_Bar_test_SWIG_0_0 unsafe.Pointer - -func _swig_wrap_Bar_test_SWIG_0_0(base SwigcptrBar, _ int) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Bar_test_SWIG_0_0, _swig_p) - return -} - -func (arg1 SwigcptrBar) Test_SWIG_0_0(arg2 int) (_swig_ret int) { - return _swig_wrap_Bar_test_SWIG_0_0(arg1, arg2) -} - -var _wrap_Bar_test_SWIG_0_1 unsafe.Pointer - -func _swig_wrap_Bar_test_SWIG_0_1(base SwigcptrBar, _ float64) (_ float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Bar_test_SWIG_0_1, _swig_p) - return -} - -func (arg1 SwigcptrBar) Test_SWIG_0_1(arg2 float64) (_swig_ret float64) { - return _swig_wrap_Bar_test_SWIG_0_1(arg1, arg2) -} - -func (p SwigcptrBar) Test(a ...interface{}) interface{} { - argc := len(a) - if argc == 1 { - if _, ok := a[0].(int); !ok { - goto check_1 - } - return p.Test_SWIG_0_0(a[0].(int)) - } -check_1: - if argc == 1 { - return p.Test_SWIG_0_1(a[0].(float64)) - } - panic("No match for overloaded function call") -} - -var _wrap_new_Bar unsafe.Pointer - -func _swig_wrap_new_Bar() (base SwigcptrBar) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Bar, _swig_p) - return -} - -func NewBar() (_swig_ret Bar) { - return _swig_wrap_new_Bar() -} - -var _wrap_delete_Bar unsafe.Pointer - -func _swig_wrap_delete_Bar(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Bar, _swig_p) - return -} - -func DeleteBar(arg1 Bar) { - _swig_wrap_delete_Bar(arg1.Swigcptr()) -} - -func (p SwigcptrBar) SwigIsFoo() { -} - -func (p SwigcptrBar) SwigGetFoo() Foo { - return SwigcptrFoo(p.Swigcptr()) -} - -type Bar interface { - Swigcptr() uintptr - SwigIsBar() - Test(a ...interface{}) interface{} - SwigIsFoo() - SwigGetFoo() Foo -} - -type SwigcptrBar2 uintptr - -func (p SwigcptrBar2) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrBar2) SwigIsBar2() { -} - -var _wrap_Bar2_test__SWIG_0 unsafe.Pointer - -func _swig_wrap_Bar2_test__SWIG_0(base SwigcptrBar2, _ int) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Bar2_test__SWIG_0, _swig_p) - return -} - -func (arg1 SwigcptrBar2) Test__SWIG_0(arg2 int) (_swig_ret int) { - return _swig_wrap_Bar2_test__SWIG_0(arg1, arg2) -} - -var _wrap_Bar2_test__SWIG_1 unsafe.Pointer - -func _swig_wrap_Bar2_test__SWIG_1(base SwigcptrBar2, _ float64) (_ float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Bar2_test__SWIG_1, _swig_p) - return -} - -func (arg1 SwigcptrBar2) Test__SWIG_1(arg2 float64) (_swig_ret float64) { - return _swig_wrap_Bar2_test__SWIG_1(arg1, arg2) -} - -func (p SwigcptrBar2) Test(a ...interface{}) interface{} { - argc := len(a) - if argc == 1 { - if _, ok := a[0].(int); !ok { - goto check_1 - } - return p.Test__SWIG_0(a[0].(int)) - } -check_1: - if argc == 1 { - return p.Test__SWIG_1(a[0].(float64)) - } - panic("No match for overloaded function call") -} - -var _wrap_new_Bar2 unsafe.Pointer - -func _swig_wrap_new_Bar2() (base SwigcptrBar2) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Bar2, _swig_p) - return -} - -func NewBar2() (_swig_ret Bar2) { - return _swig_wrap_new_Bar2() -} - -var _wrap_delete_Bar2 unsafe.Pointer - -func _swig_wrap_delete_Bar2(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Bar2, _swig_p) - return -} - -func DeleteBar2(arg1 Bar2) { - _swig_wrap_delete_Bar2(arg1.Swigcptr()) -} - -func (p SwigcptrBar2) SwigIsFoo() { -} - -func (p SwigcptrBar2) SwigGetFoo() Foo { - return SwigcptrFoo(p.Swigcptr()) -} - -type Bar2 interface { - Swigcptr() uintptr - SwigIsBar2() - Test(a ...interface{}) interface{} - SwigIsFoo() - SwigGetFoo() Foo -} - -type SwigcptrBar3 uintptr - -func (p SwigcptrBar3) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrBar3) SwigIsBar3() { -} - -var _wrap_Bar3_test__SWIG_0 unsafe.Pointer - -func _swig_wrap_Bar3_test__SWIG_0(base SwigcptrBar3, _ int) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Bar3_test__SWIG_0, _swig_p) - return -} - -func (arg1 SwigcptrBar3) Test__SWIG_0(arg2 int) (_swig_ret int) { - return _swig_wrap_Bar3_test__SWIG_0(arg1, arg2) -} - -var _wrap_Bar3_test__SWIG_1 unsafe.Pointer - -func _swig_wrap_Bar3_test__SWIG_1(base SwigcptrBar3, _ float64) (_ float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Bar3_test__SWIG_1, _swig_p) - return -} - -func (arg1 SwigcptrBar3) Test__SWIG_1(arg2 float64) (_swig_ret float64) { - return _swig_wrap_Bar3_test__SWIG_1(arg1, arg2) -} - -func (p SwigcptrBar3) Test(a ...interface{}) interface{} { - argc := len(a) - if argc == 1 { - if _, ok := a[0].(int); !ok { - goto check_1 - } - return p.Test__SWIG_0(a[0].(int)) - } -check_1: - if argc == 1 { - return p.Test__SWIG_1(a[0].(float64)) - } - panic("No match for overloaded function call") -} - -var _wrap_new_Bar3 unsafe.Pointer - -func _swig_wrap_new_Bar3() (base SwigcptrBar3) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Bar3, _swig_p) - return -} - -func NewBar3() (_swig_ret Bar3) { - return _swig_wrap_new_Bar3() -} - -var _wrap_delete_Bar3 unsafe.Pointer - -func _swig_wrap_delete_Bar3(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Bar3, _swig_p) - return -} - -func DeleteBar3(arg1 Bar3) { - _swig_wrap_delete_Bar3(arg1.Swigcptr()) -} - -func (p SwigcptrBar3) SwigIsFoo() { -} - -func (p SwigcptrBar3) SwigGetFoo() Foo { - return SwigcptrFoo(p.Swigcptr()) -} - -type Bar3 interface { - Swigcptr() uintptr - SwigIsBar3() - Test(a ...interface{}) interface{} - SwigIsFoo() - SwigGetFoo() Foo -} - -type SwigcptrBar4 uintptr - -func (p SwigcptrBar4) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrBar4) SwigIsBar4() { -} - -var _wrap_Bar4_test__SWIG_0 unsafe.Pointer - -func _swig_wrap_Bar4_test__SWIG_0(base SwigcptrBar4, _ int) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Bar4_test__SWIG_0, _swig_p) - return -} - -func (arg1 SwigcptrBar4) Test__SWIG_0(arg2 int) (_swig_ret int) { - return _swig_wrap_Bar4_test__SWIG_0(arg1, arg2) -} - -var _wrap_Bar4_test__SWIG_2 unsafe.Pointer - -func _swig_wrap_Bar4_test__SWIG_2(base SwigcptrBar4, _ float64) (_ float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Bar4_test__SWIG_2, _swig_p) - return -} - -func (arg1 SwigcptrBar4) Test__SWIG_2(arg2 float64) (_swig_ret float64) { - return _swig_wrap_Bar4_test__SWIG_2(arg1, arg2) -} - -func (p SwigcptrBar4) Test(a ...interface{}) interface{} { - argc := len(a) - if argc == 1 { - if _, ok := a[0].(int); !ok { - goto check_1 - } - return p.Test__SWIG_0(a[0].(int)) - } -check_1: - if argc == 1 { - return p.Test__SWIG_2(a[0].(float64)) - } - panic("No match for overloaded function call") -} - -var _wrap_new_Bar4 unsafe.Pointer - -func _swig_wrap_new_Bar4() (base SwigcptrBar4) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Bar4, _swig_p) - return -} - -func NewBar4() (_swig_ret Bar4) { - return _swig_wrap_new_Bar4() -} - -var _wrap_delete_Bar4 unsafe.Pointer - -func _swig_wrap_delete_Bar4(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Bar4, _swig_p) - return -} - -func DeleteBar4(arg1 Bar4) { - _swig_wrap_delete_Bar4(arg1.Swigcptr()) -} - -func (p SwigcptrBar4) SwigIsFoo() { -} - -func (p SwigcptrBar4) SwigGetFoo() Foo { - return SwigcptrFoo(p.Swigcptr()) -} - -type Bar4 interface { - Swigcptr() uintptr - SwigIsBar4() - Test(a ...interface{}) interface{} - SwigIsFoo() - SwigGetFoo() Foo -} - -type SwigcptrFred1 uintptr - -func (p SwigcptrFred1) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrFred1) SwigIsFred1() { -} - -var _wrap_Fred1_test__SWIG_0_0 unsafe.Pointer - -func _swig_wrap_Fred1_test__SWIG_0_0(base SwigcptrFred1, _ int) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Fred1_test__SWIG_0_0, _swig_p) - return -} - -func (arg1 SwigcptrFred1) Test__SWIG_0_0(arg2 int) (_swig_ret int) { - return _swig_wrap_Fred1_test__SWIG_0_0(arg1, arg2) -} - -var _wrap_Fred1_test__SWIG_1 unsafe.Pointer - -func _swig_wrap_Fred1_test__SWIG_1(base SwigcptrFred1, _ float64) (_ float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Fred1_test__SWIG_1, _swig_p) - return -} - -func (arg1 SwigcptrFred1) Test__SWIG_1(arg2 float64) (_swig_ret float64) { - return _swig_wrap_Fred1_test__SWIG_1(arg1, arg2) -} - -func (p SwigcptrFred1) Test(a ...interface{}) interface{} { - argc := len(a) - if argc == 1 { - if _, ok := a[0].(int); !ok { - goto check_1 - } - return p.Test__SWIG_0_0(a[0].(int)) - } -check_1: - if argc == 1 { - return p.Test__SWIG_1(a[0].(float64)) - } - panic("No match for overloaded function call") -} - -var _wrap_new_Fred1 unsafe.Pointer - -func _swig_wrap_new_Fred1() (base SwigcptrFred1) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Fred1, _swig_p) - return -} - -func NewFred1() (_swig_ret Fred1) { - return _swig_wrap_new_Fred1() -} - -var _wrap_delete_Fred1 unsafe.Pointer - -func _swig_wrap_delete_Fred1(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Fred1, _swig_p) - return -} - -func DeleteFred1(arg1 Fred1) { - _swig_wrap_delete_Fred1(arg1.Swigcptr()) -} - -func (p SwigcptrFred1) SwigIsFoo() { -} - -func (p SwigcptrFred1) SwigGetFoo() Foo { - return SwigcptrFoo(p.Swigcptr()) -} - -type Fred1 interface { - Swigcptr() uintptr - SwigIsFred1() - Test(a ...interface{}) interface{} - SwigIsFoo() - SwigGetFoo() Foo -} - -type SwigcptrFred2 uintptr - -func (p SwigcptrFred2) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrFred2) SwigIsFred2() { -} - -var _wrap_Fred2_test__SWIG_0 unsafe.Pointer - -func _swig_wrap_Fred2_test__SWIG_0(base SwigcptrFred2, _ float64) (_ float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Fred2_test__SWIG_0, _swig_p) - return -} - -func (arg1 SwigcptrFred2) Test__SWIG_0(arg2 float64) (_swig_ret float64) { - return _swig_wrap_Fred2_test__SWIG_0(arg1, arg2) -} - -var _wrap_Fred2_test__SWIG_1_0 unsafe.Pointer - -func _swig_wrap_Fred2_test__SWIG_1_0(base SwigcptrFred2, _ int) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Fred2_test__SWIG_1_0, _swig_p) - return -} - -func (arg1 SwigcptrFred2) Test__SWIG_1_0(arg2 int) (_swig_ret int) { - return _swig_wrap_Fred2_test__SWIG_1_0(arg1, arg2) -} - -func (p SwigcptrFred2) Test(a ...interface{}) interface{} { - argc := len(a) - if argc == 1 { - if _, ok := a[0].(int); !ok { - goto check_1 - } - return p.Test__SWIG_1_0(a[0].(int)) - } -check_1: - if argc == 1 { - return p.Test__SWIG_0(a[0].(float64)) - } - panic("No match for overloaded function call") -} - -var _wrap_new_Fred2 unsafe.Pointer - -func _swig_wrap_new_Fred2() (base SwigcptrFred2) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Fred2, _swig_p) - return -} - -func NewFred2() (_swig_ret Fred2) { - return _swig_wrap_new_Fred2() -} - -var _wrap_delete_Fred2 unsafe.Pointer - -func _swig_wrap_delete_Fred2(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Fred2, _swig_p) - return -} - -func DeleteFred2(arg1 Fred2) { - _swig_wrap_delete_Fred2(arg1.Swigcptr()) -} - -func (p SwigcptrFred2) SwigIsFoo() { -} - -func (p SwigcptrFred2) SwigGetFoo() Foo { - return SwigcptrFoo(p.Swigcptr()) -} - -type Fred2 interface { - Swigcptr() uintptr - SwigIsFred2() - Test(a ...interface{}) interface{} - SwigIsFoo() - SwigGetFoo() Foo -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/using_inherit_runme b/Examples/test-suite/go/using_inherit_runme deleted file mode 100755 index cdf7bf325..000000000 Binary files a/Examples/test-suite/go/using_inherit_runme and /dev/null differ diff --git a/Examples/test-suite/go/using_namespace.go b/Examples/test-suite/go/using_namespace.go deleted file mode 100644 index 96e735806..000000000 --- a/Examples/test-suite/go/using_namespace.go +++ /dev/null @@ -1,334 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../using_namespace.i - -package using_namespace - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrHello uintptr - -func (p SwigcptrHello) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrHello) SwigIsHello() { -} - -var _wrap_new_Hello unsafe.Pointer - -func _swig_wrap_new_Hello() (base SwigcptrHello) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Hello, _swig_p) - return -} - -func NewHello() (_swig_ret Hello) { - return _swig_wrap_new_Hello() -} - -var _wrap_delete_Hello unsafe.Pointer - -func _swig_wrap_delete_Hello(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Hello, _swig_p) - return -} - -func DeleteHello(arg1 Hello) { - _swig_wrap_delete_Hello(arg1.Swigcptr()) -} - -type Hello interface { - Swigcptr() uintptr - SwigIsHello() -} - -type SwigcptrHi0 uintptr - -func (p SwigcptrHi0) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrHi0) SwigIsHi0() { -} - -var _wrap_new_hi0 unsafe.Pointer - -func _swig_wrap_new_hi0() (base SwigcptrHi0) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_hi0, _swig_p) - return -} - -func NewHi0() (_swig_ret Hi0) { - return _swig_wrap_new_hi0() -} - -var _wrap_delete_hi0 unsafe.Pointer - -func _swig_wrap_delete_hi0(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_hi0, _swig_p) - return -} - -func DeleteHi0(arg1 Hi0) { - _swig_wrap_delete_hi0(arg1.Swigcptr()) -} - -type Hi0 interface { - Swigcptr() uintptr - SwigIsHi0() -} - -type SwigcptrHi_hi0 uintptr - -func (p SwigcptrHi_hi0) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrHi_hi0) SwigIsHi_hi0() { -} - -var _wrap_Hi_hi0_value1 unsafe.Pointer - -func _swig_wrap_Hi_hi0_value1(base SwigcptrHi_hi0) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Hi_hi0_value1, _swig_p) - return -} - -func (arg1 SwigcptrHi_hi0) Value1() (_swig_ret int) { - return _swig_wrap_Hi_hi0_value1(arg1) -} - -var _wrap_Hi_hi0_value2 unsafe.Pointer - -func _swig_wrap_Hi_hi0_value2(base SwigcptrHi_hi0) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Hi_hi0_value2, _swig_p) - return -} - -func (arg1 SwigcptrHi_hi0) Value2() (_swig_ret int) { - return _swig_wrap_Hi_hi0_value2(arg1) -} - -var _wrap_new_Hi_hi0 unsafe.Pointer - -func _swig_wrap_new_Hi_hi0() (base SwigcptrHi_hi0) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Hi_hi0, _swig_p) - return -} - -func NewHi_hi0() (_swig_ret Hi_hi0) { - return _swig_wrap_new_Hi_hi0() -} - -var _wrap_delete_Hi_hi0 unsafe.Pointer - -func _swig_wrap_delete_Hi_hi0(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Hi_hi0, _swig_p) - return -} - -func DeleteHi_hi0(arg1 Hi_hi0) { - _swig_wrap_delete_Hi_hi0(arg1.Swigcptr()) -} - -func (p SwigcptrHi_hi0) SwigIsHello() { -} - -func (p SwigcptrHi_hi0) SwigGetHello() Hello { - return SwigcptrHello(p.Swigcptr()) -} - -var _wrap_Hi_hi0_SwigGetHi0 unsafe.Pointer - -func _swig_wrap_Hi_hi0_SwigGetHi0(base SwigcptrHi_hi0) (_ SwigcptrHi0) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Hi_hi0_SwigGetHi0, _swig_p) - return -} - -func (arg1 SwigcptrHi_hi0) SwigGetHi0() (_swig_ret Hi0) { - return _swig_wrap_Hi_hi0_SwigGetHi0(arg1) -} - -type Hi_hi0 interface { - Swigcptr() uintptr - SwigIsHi_hi0() - Value1() (_swig_ret int) - Value2() (_swig_ret int) - SwigIsHello() - SwigGetHello() Hello - SwigGetHi0() (_swig_ret Hi0) -} - -type SwigcptrHi1 uintptr - -func (p SwigcptrHi1) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrHi1) SwigIsHi1() { -} - -var _wrap_hi1_value1 unsafe.Pointer - -func _swig_wrap_hi1_value1(base SwigcptrHi1) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_hi1_value1, _swig_p) - return -} - -func (arg1 SwigcptrHi1) Value1() (_swig_ret int) { - return _swig_wrap_hi1_value1(arg1) -} - -var _wrap_hi1_value2 unsafe.Pointer - -func _swig_wrap_hi1_value2(base SwigcptrHi1) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_hi1_value2, _swig_p) - return -} - -func (arg1 SwigcptrHi1) Value2() (_swig_ret int) { - return _swig_wrap_hi1_value2(arg1) -} - -var _wrap_new_hi1 unsafe.Pointer - -func _swig_wrap_new_hi1() (base SwigcptrHi1) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_hi1, _swig_p) - return -} - -func NewHi1() (_swig_ret Hi1) { - return _swig_wrap_new_hi1() -} - -var _wrap_delete_hi1 unsafe.Pointer - -func _swig_wrap_delete_hi1(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_hi1, _swig_p) - return -} - -func DeleteHi1(arg1 Hi1) { - _swig_wrap_delete_hi1(arg1.Swigcptr()) -} - -type Hi1 interface { - Swigcptr() uintptr - SwigIsHi1() - Value1() (_swig_ret int) - Value2() (_swig_ret int) -} - -type SwigcptrX uintptr - -func (p SwigcptrX) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrX) SwigIsX() { -} - -var _wrap_X_d_set unsafe.Pointer - -func _swig_wrap_X_d_set(base SwigcptrX, _ float32) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_X_d_set, _swig_p) - return -} - -func (arg1 SwigcptrX) SetD(arg2 float32) { - _swig_wrap_X_d_set(arg1, arg2) -} - -var _wrap_X_d_get unsafe.Pointer - -func _swig_wrap_X_d_get(base SwigcptrX) (_ float32) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_X_d_get, _swig_p) - return -} - -func (arg1 SwigcptrX) GetD() (_swig_ret float32) { - return _swig_wrap_X_d_get(arg1) -} - -var _wrap_new_X unsafe.Pointer - -func _swig_wrap_new_X() (base SwigcptrX) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_X, _swig_p) - return -} - -func NewX() (_swig_ret X) { - return _swig_wrap_new_X() -} - -var _wrap_delete_X unsafe.Pointer - -func _swig_wrap_delete_X(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_X, _swig_p) - return -} - -func DeleteX(arg1 X) { - _swig_wrap_delete_X(arg1.Swigcptr()) -} - -type X interface { - Swigcptr() uintptr - SwigIsX() - SetD(arg2 float32) - GetD() (_swig_ret float32) -} - -var _wrap_useSpaceMan unsafe.Pointer - -func UseSpaceMan(arg1 float64) (_swig_ret float64) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_useSpaceMan, _swig_p) - return -} - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/using_namespace_loop.go b/Examples/test-suite/go/using_namespace_loop.go deleted file mode 100644 index 1a9e5b894..000000000 --- a/Examples/test-suite/go/using_namespace_loop.go +++ /dev/null @@ -1,29 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../using_namespace_loop.i - -package using_namespace_loop - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - - diff --git a/Examples/test-suite/go/using_pointers.go b/Examples/test-suite/go/using_pointers.go deleted file mode 100644 index af3a15c43..000000000 --- a/Examples/test-suite/go/using_pointers.go +++ /dev/null @@ -1,226 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../using_pointers.i - -package using_pointers - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrFoo uintptr - -func (p SwigcptrFoo) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrFoo) SwigIsFoo() { -} - -var _wrap_Foo_x_set unsafe.Pointer - -func _swig_wrap_Foo_x_set(base SwigcptrFoo, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_x_set, _swig_p) - return -} - -func (arg1 SwigcptrFoo) SetX(arg2 int) { - _swig_wrap_Foo_x_set(arg1, arg2) -} - -var _wrap_Foo_x_get unsafe.Pointer - -func _swig_wrap_Foo_x_get(base SwigcptrFoo) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_x_get, _swig_p) - return -} - -func (arg1 SwigcptrFoo) GetX() (_swig_ret int) { - return _swig_wrap_Foo_x_get(arg1) -} - -var _wrap_delete_Foo unsafe.Pointer - -func _swig_wrap_delete_Foo(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Foo, _swig_p) - return -} - -func DeleteFoo(arg1 Foo) { - _swig_wrap_delete_Foo(arg1.Swigcptr()) -} - -var _wrap_Foo_blah unsafe.Pointer - -func _swig_wrap_Foo_blah(base SwigcptrFoo) (_ SwigcptrFoo) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_blah, _swig_p) - return -} - -func (arg1 SwigcptrFoo) Blah() (_swig_ret Foo) { - return _swig_wrap_Foo_blah(arg1) -} - -var _wrap_Foo_exception_spec unsafe.Pointer - -func _swig_wrap_Foo_exception_spec(base SwigcptrFoo, _ int) (_ SwigcptrFoo) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_exception_spec, _swig_p) - return -} - -func (arg1 SwigcptrFoo) Exception_spec(arg2 int) (_swig_ret Foo) { - return _swig_wrap_Foo_exception_spec(arg1, arg2) -} - -var _wrap_new_Foo unsafe.Pointer - -func _swig_wrap_new_Foo() (base SwigcptrFoo) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Foo, _swig_p) - return -} - -func NewFoo() (_swig_ret Foo) { - return _swig_wrap_new_Foo() -} - -type Foo interface { - Swigcptr() uintptr - SwigIsFoo() - SetX(arg2 int) - GetX() (_swig_ret int) - Blah() (_swig_ret Foo) - Exception_spec(arg2 int) (_swig_ret Foo) -} - -type SwigcptrFooBar uintptr - -func (p SwigcptrFooBar) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrFooBar) SwigIsFooBar() { -} - -var _wrap_FooBar_blah unsafe.Pointer - -func _swig_wrap_FooBar_blah(base SwigcptrFooBar) (_ SwigcptrFoo) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_FooBar_blah, _swig_p) - return -} - -func (arg1 SwigcptrFooBar) Blah() (_swig_ret Foo) { - return _swig_wrap_FooBar_blah(arg1) -} - -var _wrap_FooBar_x_set unsafe.Pointer - -func _swig_wrap_FooBar_x_set(base SwigcptrFooBar, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_FooBar_x_set, _swig_p) - return -} - -func (arg1 SwigcptrFooBar) SetX(arg2 int) { - _swig_wrap_FooBar_x_set(arg1, arg2) -} - -var _wrap_FooBar_x_get unsafe.Pointer - -func _swig_wrap_FooBar_x_get(base SwigcptrFooBar) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_FooBar_x_get, _swig_p) - return -} - -func (arg1 SwigcptrFooBar) GetX() (_swig_ret int) { - return _swig_wrap_FooBar_x_get(arg1) -} - -var _wrap_FooBar_exception_spec unsafe.Pointer - -func _swig_wrap_FooBar_exception_spec(base SwigcptrFooBar, _ int) (_ SwigcptrFoo) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_FooBar_exception_spec, _swig_p) - return -} - -func (arg1 SwigcptrFooBar) Exception_spec(arg2 int) (_swig_ret Foo) { - return _swig_wrap_FooBar_exception_spec(arg1, arg2) -} - -var _wrap_new_FooBar unsafe.Pointer - -func _swig_wrap_new_FooBar() (base SwigcptrFooBar) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_FooBar, _swig_p) - return -} - -func NewFooBar() (_swig_ret FooBar) { - return _swig_wrap_new_FooBar() -} - -var _wrap_delete_FooBar unsafe.Pointer - -func _swig_wrap_delete_FooBar(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_FooBar, _swig_p) - return -} - -func DeleteFooBar(arg1 FooBar) { - _swig_wrap_delete_FooBar(arg1.Swigcptr()) -} - -func (p SwigcptrFooBar) SwigIsFoo() { -} - -func (p SwigcptrFooBar) SwigGetFoo() Foo { - return SwigcptrFoo(p.Swigcptr()) -} - -type FooBar interface { - Swigcptr() uintptr - SwigIsFooBar() - Blah() (_swig_ret Foo) - SetX(arg2 int) - GetX() (_swig_ret int) - Exception_spec(arg2 int) (_swig_ret Foo) - SwigIsFoo() - SwigGetFoo() Foo -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/using_private.go b/Examples/test-suite/go/using_private.go deleted file mode 100644 index 3150b2e81..000000000 --- a/Examples/test-suite/go/using_private.go +++ /dev/null @@ -1,315 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../using_private.i - -package using_private - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrFoo uintptr - -func (p SwigcptrFoo) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrFoo) SwigIsFoo() { -} - -var _wrap_delete_Foo unsafe.Pointer - -func _swig_wrap_delete_Foo(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Foo, _swig_p) - return -} - -func DeleteFoo(arg1 Foo) { - _swig_wrap_delete_Foo(arg1.Swigcptr()) -} - -var _wrap_Foo_x_set unsafe.Pointer - -func _swig_wrap_Foo_x_set(base SwigcptrFoo, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_x_set, _swig_p) - return -} - -func (arg1 SwigcptrFoo) SetX(arg2 int) { - _swig_wrap_Foo_x_set(arg1, arg2) -} - -var _wrap_Foo_x_get unsafe.Pointer - -func _swig_wrap_Foo_x_get(base SwigcptrFoo) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_x_get, _swig_p) - return -} - -func (arg1 SwigcptrFoo) GetX() (_swig_ret int) { - return _swig_wrap_Foo_x_get(arg1) -} - -var _wrap_Foo_blah unsafe.Pointer - -func _swig_wrap_Foo_blah(base SwigcptrFoo, _ int) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_blah, _swig_p) - return -} - -func (arg1 SwigcptrFoo) Blah(arg2 int) (_swig_ret int) { - return _swig_wrap_Foo_blah(arg1, arg2) -} - -var _wrap_Foo_defaulted__SWIG_0 unsafe.Pointer - -func _swig_wrap_Foo_defaulted__SWIG_0(base SwigcptrFoo, _ int) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_defaulted__SWIG_0, _swig_p) - return -} - -func (arg1 SwigcptrFoo) Defaulted__SWIG_0(arg2 int) (_swig_ret int) { - return _swig_wrap_Foo_defaulted__SWIG_0(arg1, arg2) -} - -var _wrap_Foo_defaulted__SWIG_1 unsafe.Pointer - -func _swig_wrap_Foo_defaulted__SWIG_1(base SwigcptrFoo) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_defaulted__SWIG_1, _swig_p) - return -} - -func (arg1 SwigcptrFoo) Defaulted__SWIG_1() (_swig_ret int) { - return _swig_wrap_Foo_defaulted__SWIG_1(arg1) -} - -func (p SwigcptrFoo) Defaulted(a ...interface{}) int { - argc := len(a) - if argc == 0 { - return p.Defaulted__SWIG_1() - } - if argc == 1 { - return p.Defaulted__SWIG_0(a[0].(int)) - } - panic("No match for overloaded function call") -} - -var _wrap_Foo_virtualmethod unsafe.Pointer - -func _swig_wrap_Foo_virtualmethod(base SwigcptrFoo) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_virtualmethod, _swig_p) - return -} - -func (arg1 SwigcptrFoo) Virtualmethod() { - _swig_wrap_Foo_virtualmethod(arg1) -} - -var _wrap_Foo_anothervirtual unsafe.Pointer - -func _swig_wrap_Foo_anothervirtual(base SwigcptrFoo) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_anothervirtual, _swig_p) - return -} - -func (arg1 SwigcptrFoo) Anothervirtual() { - _swig_wrap_Foo_anothervirtual(arg1) -} - -var _wrap_new_Foo unsafe.Pointer - -func _swig_wrap_new_Foo() (base SwigcptrFoo) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Foo, _swig_p) - return -} - -func NewFoo() (_swig_ret Foo) { - return _swig_wrap_new_Foo() -} - -type Foo interface { - Swigcptr() uintptr - SwigIsFoo() - SetX(arg2 int) - GetX() (_swig_ret int) - Blah(arg2 int) (_swig_ret int) - Defaulted(a ...interface{}) int - Virtualmethod() - Anothervirtual() -} - -type SwigcptrFooBar uintptr - -func (p SwigcptrFooBar) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrFooBar) SwigIsFooBar() { -} - -var _wrap_FooBar_blah unsafe.Pointer - -func _swig_wrap_FooBar_blah(base SwigcptrFooBar, _ int) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_FooBar_blah, _swig_p) - return -} - -func (arg1 SwigcptrFooBar) Blah(arg2 int) (_swig_ret int) { - return _swig_wrap_FooBar_blah(arg1, arg2) -} - -var _wrap_FooBar_x_set unsafe.Pointer - -func _swig_wrap_FooBar_x_set(base SwigcptrFooBar, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_FooBar_x_set, _swig_p) - return -} - -func (arg1 SwigcptrFooBar) SetX(arg2 int) { - _swig_wrap_FooBar_x_set(arg1, arg2) -} - -var _wrap_FooBar_x_get unsafe.Pointer - -func _swig_wrap_FooBar_x_get(base SwigcptrFooBar) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_FooBar_x_get, _swig_p) - return -} - -func (arg1 SwigcptrFooBar) GetX() (_swig_ret int) { - return _swig_wrap_FooBar_x_get(arg1) -} - -var _wrap_FooBar_defaulted_SWIG_0_0 unsafe.Pointer - -func _swig_wrap_FooBar_defaulted_SWIG_0_0(base SwigcptrFooBar, _ int) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_FooBar_defaulted_SWIG_0_0, _swig_p) - return -} - -func (arg1 SwigcptrFooBar) Defaulted_SWIG_0_0(arg2 int) (_swig_ret int) { - return _swig_wrap_FooBar_defaulted_SWIG_0_0(arg1, arg2) -} - -var _wrap_FooBar_defaulted_SWIG_0_1 unsafe.Pointer - -func _swig_wrap_FooBar_defaulted_SWIG_0_1(base SwigcptrFooBar) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_FooBar_defaulted_SWIG_0_1, _swig_p) - return -} - -func (arg1 SwigcptrFooBar) Defaulted_SWIG_0_1() (_swig_ret int) { - return _swig_wrap_FooBar_defaulted_SWIG_0_1(arg1) -} - -func (p SwigcptrFooBar) Defaulted(a ...interface{}) int { - argc := len(a) - if argc == 0 { - return p.Defaulted_SWIG_0_1() - } - if argc == 1 { - return p.Defaulted_SWIG_0_0(a[0].(int)) - } - panic("No match for overloaded function call") -} - -var _wrap_FooBar_virtualmethod unsafe.Pointer - -func _swig_wrap_FooBar_virtualmethod(base SwigcptrFooBar) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_FooBar_virtualmethod, _swig_p) - return -} - -func (arg1 SwigcptrFooBar) Virtualmethod() { - _swig_wrap_FooBar_virtualmethod(arg1) -} - -var _wrap_FooBar_anothervirtual unsafe.Pointer - -func _swig_wrap_FooBar_anothervirtual(base SwigcptrFooBar) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_FooBar_anothervirtual, _swig_p) - return -} - -func (arg1 SwigcptrFooBar) Anothervirtual() { - _swig_wrap_FooBar_anothervirtual(arg1) -} - -var _wrap_delete_FooBar unsafe.Pointer - -func _swig_wrap_delete_FooBar(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_FooBar, _swig_p) - return -} - -func DeleteFooBar(arg1 FooBar) { - _swig_wrap_delete_FooBar(arg1.Swigcptr()) -} - -var _wrap_new_FooBar unsafe.Pointer - -func _swig_wrap_new_FooBar() (base SwigcptrFooBar) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_FooBar, _swig_p) - return -} - -func NewFooBar() (_swig_ret FooBar) { - return _swig_wrap_new_FooBar() -} - -type FooBar interface { - Swigcptr() uintptr - SwigIsFooBar() - Blah(arg2 int) (_swig_ret int) - SetX(arg2 int) - GetX() (_swig_ret int) - Defaulted(a ...interface{}) int - Virtualmethod() - Anothervirtual() -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/using_private_runme b/Examples/test-suite/go/using_private_runme deleted file mode 100755 index cc47122be..000000000 Binary files a/Examples/test-suite/go/using_private_runme and /dev/null differ diff --git a/Examples/test-suite/go/using_protected.go b/Examples/test-suite/go/using_protected.go deleted file mode 100644 index abe38d4ce..000000000 --- a/Examples/test-suite/go/using_protected.go +++ /dev/null @@ -1,221 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../using_protected.i - -package using_protected - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrFoo uintptr - -func (p SwigcptrFoo) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrFoo) SwigIsFoo() { -} - -var _wrap_new_Foo unsafe.Pointer - -func _swig_wrap_new_Foo() (base SwigcptrFoo) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Foo, _swig_p) - return -} - -func NewFoo() (_swig_ret Foo) { - return _swig_wrap_new_Foo() -} - -var _wrap_delete_Foo unsafe.Pointer - -func _swig_wrap_delete_Foo(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Foo, _swig_p) - return -} - -func DeleteFoo(arg1 Foo) { - _swig_wrap_delete_Foo(arg1.Swigcptr()) -} - -type Foo interface { - Swigcptr() uintptr - SwigIsFoo() -} - -type SwigcptrFooBar uintptr - -func (p SwigcptrFooBar) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrFooBar) SwigIsFooBar() { -} - -var _wrap_FooBar_blah unsafe.Pointer - -func _swig_wrap_FooBar_blah(base SwigcptrFooBar, _ int) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_FooBar_blah, _swig_p) - return -} - -func (arg1 SwigcptrFooBar) Blah(arg2 int) (_swig_ret int) { - return _swig_wrap_FooBar_blah(arg1, arg2) -} - -var _wrap_FooBar_x_set unsafe.Pointer - -func _swig_wrap_FooBar_x_set(base SwigcptrFooBar, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_FooBar_x_set, _swig_p) - return -} - -func (arg1 SwigcptrFooBar) SetX(arg2 int) { - _swig_wrap_FooBar_x_set(arg1, arg2) -} - -var _wrap_FooBar_x_get unsafe.Pointer - -func _swig_wrap_FooBar_x_get(base SwigcptrFooBar) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_FooBar_x_get, _swig_p) - return -} - -func (arg1 SwigcptrFooBar) GetX() (_swig_ret int) { - return _swig_wrap_FooBar_x_get(arg1) -} - -var _wrap_FooBar_vmethod unsafe.Pointer - -func _swig_wrap_FooBar_vmethod(base SwigcptrFooBar, _ int) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_FooBar_vmethod, _swig_p) - return -} - -func (arg1 SwigcptrFooBar) Vmethod(arg2 int) (_swig_ret int) { - return _swig_wrap_FooBar_vmethod(arg1, arg2) -} - -var _wrap_new_FooBar unsafe.Pointer - -func _swig_wrap_new_FooBar() (base SwigcptrFooBar) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_FooBar, _swig_p) - return -} - -func NewFooBar() (_swig_ret FooBar) { - return _swig_wrap_new_FooBar() -} - -var _wrap_delete_FooBar unsafe.Pointer - -func _swig_wrap_delete_FooBar(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_FooBar, _swig_p) - return -} - -func DeleteFooBar(arg1 FooBar) { - _swig_wrap_delete_FooBar(arg1.Swigcptr()) -} - -func (p SwigcptrFooBar) SwigIsFoo() { -} - -func (p SwigcptrFooBar) SwigGetFoo() Foo { - return SwigcptrFoo(p.Swigcptr()) -} - -type FooBar interface { - Swigcptr() uintptr - SwigIsFooBar() - Blah(arg2 int) (_swig_ret int) - SetX(arg2 int) - GetX() (_swig_ret int) - Vmethod(arg2 int) (_swig_ret int) - SwigIsFoo() - SwigGetFoo() Foo -} - -type SwigcptrFooBaz uintptr - -func (p SwigcptrFooBaz) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrFooBaz) SwigIsFooBaz() { -} - -var _wrap_new_FooBaz unsafe.Pointer - -func _swig_wrap_new_FooBaz() (base SwigcptrFooBaz) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_FooBaz, _swig_p) - return -} - -func NewFooBaz() (_swig_ret FooBaz) { - return _swig_wrap_new_FooBaz() -} - -var _wrap_delete_FooBaz unsafe.Pointer - -func _swig_wrap_delete_FooBaz(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_FooBaz, _swig_p) - return -} - -func DeleteFooBaz(arg1 FooBaz) { - _swig_wrap_delete_FooBaz(arg1.Swigcptr()) -} - -func (p SwigcptrFooBaz) SwigIsFoo() { -} - -func (p SwigcptrFooBaz) SwigGetFoo() Foo { - return SwigcptrFoo(p.Swigcptr()) -} - -type FooBaz interface { - Swigcptr() uintptr - SwigIsFooBaz() - SwigIsFoo() - SwigGetFoo() Foo -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/using_protected_runme b/Examples/test-suite/go/using_protected_runme deleted file mode 100755 index 40ad401bd..000000000 Binary files a/Examples/test-suite/go/using_protected_runme and /dev/null differ diff --git a/Examples/test-suite/go/valuewrapper.go b/Examples/test-suite/go/valuewrapper.go deleted file mode 100644 index 34a074431..000000000 --- a/Examples/test-suite/go/valuewrapper.go +++ /dev/null @@ -1,149 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../valuewrapper.i - -package valuewrapper - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrXi uintptr - -func (p SwigcptrXi) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrXi) SwigIsXi() { -} - -var _wrap_new_Xi unsafe.Pointer - -func _swig_wrap_new_Xi(base int) (_ SwigcptrXi) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Xi, _swig_p) - return -} - -func NewXi(arg1 int) (_swig_ret Xi) { - return _swig_wrap_new_Xi(arg1) -} - -var _wrap_delete_Xi unsafe.Pointer - -func _swig_wrap_delete_Xi(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Xi, _swig_p) - return -} - -func DeleteXi(arg1 Xi) { - _swig_wrap_delete_Xi(arg1.Swigcptr()) -} - -type Xi interface { - Swigcptr() uintptr - SwigIsXi() -} - -type SwigcptrYXi uintptr - -func (p SwigcptrYXi) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrYXi) SwigIsYXi() { -} - -var _wrap_new_YXi unsafe.Pointer - -func _swig_wrap_new_YXi() (base SwigcptrYXi) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_YXi, _swig_p) - return -} - -func NewYXi() (_swig_ret YXi) { - return _swig_wrap_new_YXi() -} - -var _wrap_YXi_spam__SWIG_0 unsafe.Pointer - -func _swig_wrap_YXi_spam__SWIG_0(base SwigcptrYXi, _ uintptr) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_YXi_spam__SWIG_0, _swig_p) - return -} - -func (arg1 SwigcptrYXi) Spam__SWIG_0(arg2 Xi) (_swig_ret int) { - return _swig_wrap_YXi_spam__SWIG_0(arg1, arg2.Swigcptr()) -} - -var _wrap_YXi_spam__SWIG_1 unsafe.Pointer - -func _swig_wrap_YXi_spam__SWIG_1(base SwigcptrYXi) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_YXi_spam__SWIG_1, _swig_p) - return -} - -func (arg1 SwigcptrYXi) Spam__SWIG_1() (_swig_ret int) { - return _swig_wrap_YXi_spam__SWIG_1(arg1) -} - -func (p SwigcptrYXi) Spam(a ...interface{}) int { - argc := len(a) - if argc == 0 { - return p.Spam__SWIG_1() - } - if argc == 1 { - return p.Spam__SWIG_0(a[0].(Xi)) - } - panic("No match for overloaded function call") -} - -var _wrap_delete_YXi unsafe.Pointer - -func _swig_wrap_delete_YXi(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_YXi, _swig_p) - return -} - -func DeleteYXi(arg1 YXi) { - _swig_wrap_delete_YXi(arg1.Swigcptr()) -} - -type YXi interface { - Swigcptr() uintptr - SwigIsYXi() - Spam(a ...interface{}) int -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/valuewrapper_base.go b/Examples/test-suite/go/valuewrapper_base.go deleted file mode 100644 index c6022a642..000000000 --- a/Examples/test-suite/go/valuewrapper_base.go +++ /dev/null @@ -1,151 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../valuewrapper_base.i - -package valuewrapper_base - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type OssPolarization int -var _wrap_UnaryPolarization unsafe.Pointer - -func _swig_getUnaryPolarization() (_swig_ret OssPolarization) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_UnaryPolarization, _swig_p) - return -} -var UnaryPolarization OssPolarization = _swig_getUnaryPolarization() -var _wrap_BinaryPolarization unsafe.Pointer - -func _swig_getBinaryPolarization() (_swig_ret OssPolarization) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_BinaryPolarization, _swig_p) - return -} -var BinaryPolarization OssPolarization = _swig_getBinaryPolarization() -type SwigcptrBase uintptr - -func (p SwigcptrBase) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrBase) SwigIsBase() { -} - -var _wrap_new_Base unsafe.Pointer - -func _swig_wrap_new_Base() (base SwigcptrBase) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Base, _swig_p) - return -} - -func NewBase() (_swig_ret Base) { - return _swig_wrap_new_Base() -} - -var _wrap_delete_Base unsafe.Pointer - -func _swig_wrap_delete_Base(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Base, _swig_p) - return -} - -func DeleteBase(arg1 Base) { - _swig_wrap_delete_Base(arg1.Swigcptr()) -} - -type Base interface { - Swigcptr() uintptr - SwigIsBase() -} - -type SwigcptrInterface_BP uintptr - -func (p SwigcptrInterface_BP) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrInterface_BP) SwigIsInterface_BP() { -} - -var _wrap_new_Interface_BP unsafe.Pointer - -func _swig_wrap_new_Interface_BP(base uintptr) (_ SwigcptrInterface_BP) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Interface_BP, _swig_p) - return -} - -func NewInterface_BP(arg1 Base) (_swig_ret Interface_BP) { - return _swig_wrap_new_Interface_BP(arg1.Swigcptr()) -} - -var _wrap_delete_Interface_BP unsafe.Pointer - -func _swig_wrap_delete_Interface_BP(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Interface_BP, _swig_p) - return -} - -func DeleteInterface_BP(arg1 Interface_BP) { - _swig_wrap_delete_Interface_BP(arg1.Swigcptr()) -} - -func (p SwigcptrInterface_BP) SwigIsBase() { -} - -func (p SwigcptrInterface_BP) SwigGetBase() Base { - return SwigcptrBase(p.Swigcptr()) -} - -type Interface_BP interface { - Swigcptr() uintptr - SwigIsInterface_BP() - SwigIsBase() - SwigGetBase() Base -} - -var _wrap_make_Interface_BP unsafe.Pointer - -func _swig_wrap_make_Interface_BP() (base SwigcptrInterface_BP) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_make_Interface_BP, _swig_p) - return -} - -func Make_Interface_BP() (_swig_ret Interface_BP) { - return _swig_wrap_make_Interface_BP() -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/valuewrapper_const.go b/Examples/test-suite/go/valuewrapper_const.go deleted file mode 100644 index 2b9962f12..000000000 --- a/Examples/test-suite/go/valuewrapper_const.go +++ /dev/null @@ -1,165 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../valuewrapper_const.i - -package valuewrapper_const - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrB uintptr - -func (p SwigcptrB) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrB) SwigIsB() { -} - -var _wrap_new_B unsafe.Pointer - -func _swig_wrap_new_B(base uintptr) (_ SwigcptrB) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_B, _swig_p) - return -} - -func NewB(arg1 B) (_swig_ret B) { - return _swig_wrap_new_B(arg1.Swigcptr()) -} - -var _wrap_delete_B unsafe.Pointer - -func _swig_wrap_delete_B(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_B, _swig_p) - return -} - -func DeleteB(arg1 B) { - _swig_wrap_delete_B(arg1.Swigcptr()) -} - -type B interface { - Swigcptr() uintptr - SwigIsB() -} - -type SwigcptrA uintptr - -func (p SwigcptrA) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrA) SwigIsA() { -} - -var _wrap_new_A unsafe.Pointer - -func _swig_wrap_new_A(base uintptr) (_ SwigcptrA) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_A, _swig_p) - return -} - -func NewA(arg1 B) (_swig_ret A) { - return _swig_wrap_new_A(arg1.Swigcptr()) -} - -var _wrap_A_GetB unsafe.Pointer - -func _swig_wrap_A_GetB(base SwigcptrA) (_ SwigcptrB) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_A_GetB, _swig_p) - return -} - -func (arg1 SwigcptrA) GetB() (_swig_ret B) { - return _swig_wrap_A_GetB(arg1) -} - -var _wrap_A_GetBconst unsafe.Pointer - -func _swig_wrap_A_GetBconst(base SwigcptrA) (_ SwigcptrB) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_A_GetBconst, _swig_p) - return -} - -func (arg1 SwigcptrA) GetBconst() (_swig_ret B) { - return _swig_wrap_A_GetBconst(arg1) -} - -var _wrap_A_GetBGlobalQualifier unsafe.Pointer - -func _swig_wrap_A_GetBGlobalQualifier(base SwigcptrA) (_ SwigcptrB) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_A_GetBGlobalQualifier, _swig_p) - return -} - -func (arg1 SwigcptrA) GetBGlobalQualifier() (_swig_ret B) { - return _swig_wrap_A_GetBGlobalQualifier(arg1) -} - -var _wrap_A_GetBconstGlobalGlobalQualifier unsafe.Pointer - -func _swig_wrap_A_GetBconstGlobalGlobalQualifier(base SwigcptrA) (_ SwigcptrB) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_A_GetBconstGlobalGlobalQualifier, _swig_p) - return -} - -func (arg1 SwigcptrA) GetBconstGlobalGlobalQualifier() (_swig_ret B) { - return _swig_wrap_A_GetBconstGlobalGlobalQualifier(arg1) -} - -var _wrap_delete_A unsafe.Pointer - -func _swig_wrap_delete_A(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_A, _swig_p) - return -} - -func DeleteA(arg1 A) { - _swig_wrap_delete_A(arg1.Swigcptr()) -} - -type A interface { - Swigcptr() uintptr - SwigIsA() - GetB() (_swig_ret B) - GetBconst() (_swig_ret B) - GetBGlobalQualifier() (_swig_ret B) - GetBconstGlobalGlobalQualifier() (_swig_ret B) -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/valuewrapper_opaque.go b/Examples/test-suite/go/valuewrapper_opaque.go deleted file mode 100644 index 43375ef7f..000000000 --- a/Examples/test-suite/go/valuewrapper_opaque.go +++ /dev/null @@ -1,481 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../valuewrapper_opaque.i - -package valuewrapper_opaque - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrA uintptr - -func (p SwigcptrA) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrA) SwigIsA() { -} - -var _wrap_new_A unsafe.Pointer - -func _swig_wrap_new_A(base int) (_ SwigcptrA) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_A, _swig_p) - return -} - -func NewA(arg1 int) (_swig_ret A) { - return _swig_wrap_new_A(arg1) -} - -var _wrap_delete_A unsafe.Pointer - -func _swig_wrap_delete_A(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_A, _swig_p) - return -} - -func DeleteA(arg1 A) { - _swig_wrap_delete_A(arg1.Swigcptr()) -} - -type A interface { - Swigcptr() uintptr - SwigIsA() -} - -type SwigcptrD uintptr - -func (p SwigcptrD) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrD) SwigIsD() { -} - -var _wrap_new_D unsafe.Pointer - -func _swig_wrap_new_D() (base SwigcptrD) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_D, _swig_p) - return -} - -func NewD() (_swig_ret D) { - return _swig_wrap_new_D() -} - -var _wrap_delete_D unsafe.Pointer - -func _swig_wrap_delete_D(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_D, _swig_p) - return -} - -func DeleteD(arg1 D) { - _swig_wrap_delete_D(arg1.Swigcptr()) -} - -type D interface { - Swigcptr() uintptr - SwigIsD() -} - -type SwigcptrKlass uintptr - -func (p SwigcptrKlass) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrKlass) SwigIsKlass() { -} - -var _wrap_new_Klass unsafe.Pointer - -func _swig_wrap_new_Klass() (base SwigcptrKlass) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Klass, _swig_p) - return -} - -func NewKlass() (_swig_ret Klass) { - return _swig_wrap_new_Klass() -} - -var _wrap_delete_Klass unsafe.Pointer - -func _swig_wrap_delete_Klass(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Klass, _swig_p) - return -} - -func DeleteKlass(arg1 Klass) { - _swig_wrap_delete_Klass(arg1.Swigcptr()) -} - -type Klass interface { - Swigcptr() uintptr - SwigIsKlass() -} - -var _wrap_getKlass unsafe.Pointer - -func _swig_wrap_getKlass(base uintptr) (_ SwigcptrTemplateClass_Sl_Klass_Sg_) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_getKlass, _swig_p) - return -} - -func GetKlass(arg1 Klass) (_swig_ret TemplateClass_Sl_Klass_Sg_) { - return _swig_wrap_getKlass(arg1.Swigcptr()) -} - -var _wrap_getA__SWIG_0 unsafe.Pointer - -func _swig_wrap_getA__SWIG_0(base uintptr) (_ SwigcptrTemplateClass_Sl_A_Sg_) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_getA__SWIG_0, _swig_p) - return -} - -func GetA__SWIG_0(arg1 A) (_swig_ret TemplateClass_Sl_A_Sg_) { - return _swig_wrap_getA__SWIG_0(arg1.Swigcptr()) -} - -var _wrap_getA__SWIG_1 unsafe.Pointer - -func _swig_wrap_getA__SWIG_1(base uintptr) (_ SwigcptrTemplateClass_Sl_B_Sg_) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_getA__SWIG_1, _swig_p) - return -} - -func GetA__SWIG_1(arg1 B) (_swig_ret TemplateClass_Sl_B_Sg_) { - return _swig_wrap_getA__SWIG_1(arg1.Swigcptr()) -} - -func GetA(a ...interface{}) interface{} { - argc := len(a) - if argc == 1 { - if _, ok := a[0].(A); !ok { - goto check_1 - } - return GetA__SWIG_0(a[0].(A)) - } -check_1: - if argc == 1 { - return GetA__SWIG_1(a[0].(B)) - } - panic("No match for overloaded function call") -} - -var _wrap_getC unsafe.Pointer - -func _swig_wrap_getC(base uintptr) (_ SwigcptrTemplateClass_Sl_C_Sg_) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_getC, _swig_p) - return -} - -func GetC(arg1 C) (_swig_ret TemplateClass_Sl_C_Sg_) { - return _swig_wrap_getC(arg1.Swigcptr()) -} - -var _wrap_getInt unsafe.Pointer - -func _swig_wrap_getInt(base int) (_ SwigcptrTemplateClass_Sl_int_Sg_) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_getInt, _swig_p) - return -} - -func GetInt(arg1 int) (_swig_ret TemplateClass_Sl_int_Sg_) { - return _swig_wrap_getInt(arg1) -} - -var _wrap_sgetA unsafe.Pointer - -func _swig_wrap_sgetA(base uintptr) (_ SwigcptrA) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_sgetA, _swig_p) - return -} - -func SgetA(arg1 A) (_swig_ret A) { - return _swig_wrap_sgetA(arg1.Swigcptr()) -} - -var _wrap_sgetKlass unsafe.Pointer - -func _swig_wrap_sgetKlass(base uintptr) (_ SwigcptrKlass) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_sgetKlass, _swig_p) - return -} - -func SgetKlass(arg1 Klass) (_swig_ret Klass) { - return _swig_wrap_sgetKlass(arg1.Swigcptr()) -} - -var _wrap_getPtrA unsafe.Pointer - -func _swig_wrap_getPtrA(base uintptr) (_ SwigcptrAuto_ptr_Sl_A_Sg_) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_getPtrA, _swig_p) - return -} - -func GetPtrA(arg1 Auto_ptr_Sl_A_Sg_) (_swig_ret Auto_ptr_Sl_A_Sg_) { - return _swig_wrap_getPtrA(arg1.Swigcptr()) -} - -var _wrap_getB unsafe.Pointer - -func _swig_wrap_getB(base uintptr) (_ SwigcptrB) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_getB, _swig_p) - return -} - -func GetB(arg1 B) (_swig_ret B) { - return _swig_wrap_getB(arg1.Swigcptr()) -} - -var _wrap_getD unsafe.Pointer - -func _swig_wrap_getD(base uintptr) (_ SwigcptrD) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_getD, _swig_p) - return -} - -func GetD(arg1 D) (_swig_ret D) { - return _swig_wrap_getD(arg1.Swigcptr()) -} - -type SwigcptrAA uintptr - -func (p SwigcptrAA) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrAA) SwigIsAA() { -} - -var _wrap_new_AA unsafe.Pointer - -func _swig_wrap_new_AA() (base SwigcptrAA) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_AA, _swig_p) - return -} - -func NewAA() (_swig_ret AA) { - return _swig_wrap_new_AA() -} - -var _wrap_AA_innerObj_set unsafe.Pointer - -func _swig_wrap_AA_innerObj_set(base SwigcptrAA, _ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_AA_innerObj_set, _swig_p) - return -} - -func (arg1 SwigcptrAA) SetInnerObj(arg2 BB) { - _swig_wrap_AA_innerObj_set(arg1, arg2.Swigcptr()) -} - -var _wrap_AA_innerObj_get unsafe.Pointer - -func _swig_wrap_AA_innerObj_get(base SwigcptrAA) (_ SwigcptrBB) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_AA_innerObj_get, _swig_p) - return -} - -func (arg1 SwigcptrAA) GetInnerObj() (_swig_ret BB) { - return _swig_wrap_AA_innerObj_get(arg1) -} - -var _wrap_delete_AA unsafe.Pointer - -func _swig_wrap_delete_AA(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_AA, _swig_p) - return -} - -func DeleteAA(arg1 AA) { - _swig_wrap_delete_AA(arg1.Swigcptr()) -} - -type AA interface { - Swigcptr() uintptr - SwigIsAA() - SetInnerObj(arg2 BB) - GetInnerObj() (_swig_ret BB) -} - -type SwigcptrQuux uintptr - -func (p SwigcptrQuux) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrQuux) SwigIsQuux() { -} - -var _wrap_new_Quux unsafe.Pointer - -func _swig_wrap_new_Quux() (base SwigcptrQuux) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Quux, _swig_p) - return -} - -func NewQuux() (_swig_ret Quux) { - return _swig_wrap_new_Quux() -} - -var _wrap_Quux_method unsafe.Pointer - -func _swig_wrap_Quux_method(base SwigcptrQuux) (_ SwigcptrFoobar) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Quux_method, _swig_p) - return -} - -func (arg1 SwigcptrQuux) Method() (_swig_ret Foobar) { - return _swig_wrap_Quux_method(arg1) -} - -var _wrap_delete_Quux unsafe.Pointer - -func _swig_wrap_delete_Quux(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Quux, _swig_p) - return -} - -func DeleteQuux(arg1 Quux) { - _swig_wrap_delete_Quux(arg1.Swigcptr()) -} - -type Quux interface { - Swigcptr() uintptr - SwigIsQuux() - Method() (_swig_ret Foobar) -} - - -type SwigcptrTemplateClass_Sl_A_Sg_ uintptr -type TemplateClass_Sl_A_Sg_ interface { - Swigcptr() uintptr; -} -func (p SwigcptrTemplateClass_Sl_A_Sg_) Swigcptr() uintptr { - return uintptr(p) -} - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - -type SwigcptrBB uintptr -type BB interface { - Swigcptr() uintptr; -} -func (p SwigcptrBB) Swigcptr() uintptr { - return uintptr(p) -} - -type SwigcptrTemplateClass_Sl_B_Sg_ uintptr -type TemplateClass_Sl_B_Sg_ interface { - Swigcptr() uintptr; -} -func (p SwigcptrTemplateClass_Sl_B_Sg_) Swigcptr() uintptr { - return uintptr(p) -} - -type SwigcptrFoobar uintptr -type Foobar interface { - Swigcptr() uintptr; -} -func (p SwigcptrFoobar) Swigcptr() uintptr { - return uintptr(p) -} - -type SwigcptrTemplateClass_Sl_C_Sg_ uintptr -type TemplateClass_Sl_C_Sg_ interface { - Swigcptr() uintptr; -} -func (p SwigcptrTemplateClass_Sl_C_Sg_) Swigcptr() uintptr { - return uintptr(p) -} - -type SwigcptrTemplateClass_Sl_Klass_Sg_ uintptr -type TemplateClass_Sl_Klass_Sg_ interface { - Swigcptr() uintptr; -} -func (p SwigcptrTemplateClass_Sl_Klass_Sg_) Swigcptr() uintptr { - return uintptr(p) -} - -type SwigcptrAuto_ptr_Sl_A_Sg_ uintptr -type Auto_ptr_Sl_A_Sg_ interface { - Swigcptr() uintptr; -} -func (p SwigcptrAuto_ptr_Sl_A_Sg_) Swigcptr() uintptr { - return uintptr(p) -} - -type SwigcptrTemplateClass_Sl_int_Sg_ uintptr -type TemplateClass_Sl_int_Sg_ interface { - Swigcptr() uintptr; -} -func (p SwigcptrTemplateClass_Sl_int_Sg_) Swigcptr() uintptr { - return uintptr(p) -} - -type SwigcptrB uintptr -type B interface { - Swigcptr() uintptr; -} -func (p SwigcptrB) Swigcptr() uintptr { - return uintptr(p) -} - -type SwigcptrC uintptr -type C interface { - Swigcptr() uintptr; -} -func (p SwigcptrC) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/varargs.go b/Examples/test-suite/go/varargs.go deleted file mode 100644 index 58335f802..000000000 --- a/Examples/test-suite/go/varargs.go +++ /dev/null @@ -1,244 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../varargs.i - -package varargs - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -var _wrap_test unsafe.Pointer - -func Test(arg1 string) (_swig_ret string) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_test, _swig_p) - return -} -var _wrap_test_def__SWIG_0 unsafe.Pointer - -func Test_def__SWIG_0(arg1 string, arg2 int) (_swig_ret string) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_test_def__SWIG_0, _swig_p) - return -} -var _wrap_test_def__SWIG_1 unsafe.Pointer - -func Test_def__SWIG_1(arg1 string) (_swig_ret string) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_test_def__SWIG_1, _swig_p) - return -} -func Test_def(a ...interface{}) string { - argc := len(a) - if argc == 1 { - return Test_def__SWIG_1(a[0].(string)) - } - if argc == 2 { - return Test_def__SWIG_0(a[0].(string), a[1].(int)) - } - panic("No match for overloaded function call") -} - -type SwigcptrFoo uintptr - -func (p SwigcptrFoo) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrFoo) SwigIsFoo() { -} - -var _wrap_Foo_str_set unsafe.Pointer - -func _swig_wrap_Foo_str_set(base SwigcptrFoo, _ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_str_set, _swig_p) - return -} - -func (arg1 SwigcptrFoo) SetStr(arg2 string) { - _swig_wrap_Foo_str_set(arg1, arg2) -} - -var _wrap_Foo_str_get unsafe.Pointer - -func _swig_wrap_Foo_str_get(base SwigcptrFoo) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_str_get, _swig_p) - return -} - -func (arg1 SwigcptrFoo) GetStr() (_swig_ret string) { - return _swig_wrap_Foo_str_get(arg1) -} - -var _wrap_new_Foo__SWIG_0 unsafe.Pointer - -func _swig_wrap_new_Foo__SWIG_0() (base SwigcptrFoo) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Foo__SWIG_0, _swig_p) - return -} - -func NewFoo__SWIG_0() (_swig_ret Foo) { - return _swig_wrap_new_Foo__SWIG_0() -} - -var _wrap_new_Foo__SWIG_1 unsafe.Pointer - -func _swig_wrap_new_Foo__SWIG_1(base string, _ int) (_ SwigcptrFoo) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Foo__SWIG_1, _swig_p) - return -} - -func NewFoo__SWIG_1(arg1 string, arg2 int) (_swig_ret Foo) { - return _swig_wrap_new_Foo__SWIG_1(arg1, arg2) -} - -var _wrap_new_Foo__SWIG_2 unsafe.Pointer - -func _swig_wrap_new_Foo__SWIG_2(base string) (_ SwigcptrFoo) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Foo__SWIG_2, _swig_p) - return -} - -func NewFoo__SWIG_2(arg1 string) (_swig_ret Foo) { - return _swig_wrap_new_Foo__SWIG_2(arg1) -} - -func NewFoo(a ...interface{}) Foo { - argc := len(a) - if argc == 0 { - return NewFoo__SWIG_0() - } - if argc == 1 { - return NewFoo__SWIG_2(a[0].(string)) - } - if argc == 2 { - return NewFoo__SWIG_1(a[0].(string), a[1].(int)) - } - panic("No match for overloaded function call") -} - -var _wrap_delete_Foo unsafe.Pointer - -func _swig_wrap_delete_Foo(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Foo, _swig_p) - return -} - -func DeleteFoo(arg1 Foo) { - _swig_wrap_delete_Foo(arg1.Swigcptr()) -} - -var _wrap_Foo_test unsafe.Pointer - -func _swig_wrap_Foo_test(base SwigcptrFoo, _ string) (_ string) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_test, _swig_p) - return -} - -func (arg1 SwigcptrFoo) Test(arg2 string) (_swig_ret string) { - return _swig_wrap_Foo_test(arg1, arg2) -} - -var _wrap_Foo_statictest__SWIG_0 unsafe.Pointer - -func FooStatictest__SWIG_0(arg1 string, arg2 int) (_swig_ret string) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_Foo_statictest__SWIG_0, _swig_p) - return -} -var _wrap_Foo_statictest__SWIG_1 unsafe.Pointer - -func FooStatictest__SWIG_1(arg1 string) (_swig_ret string) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_Foo_statictest__SWIG_1, _swig_p) - return -} -func FooStatictest(a ...interface{}) string { - argc := len(a) - if argc == 1 { - return FooStatictest__SWIG_1(a[0].(string)) - } - if argc == 2 { - return FooStatictest__SWIG_0(a[0].(string), a[1].(int)) - } - panic("No match for overloaded function call") -} - -type Foo interface { - Swigcptr() uintptr - SwigIsFoo() - SetStr(arg2 string) - GetStr() (_swig_ret string) - Test(arg2 string) (_swig_ret string) -} - -var _wrap_test_plenty__SWIG_0 unsafe.Pointer - -func Test_plenty__SWIG_0(arg1 string, arg2 int, arg3 int) (_swig_ret string) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_test_plenty__SWIG_0, _swig_p) - return -} -var _wrap_test_plenty__SWIG_1 unsafe.Pointer - -func Test_plenty__SWIG_1(arg1 string, arg2 int) (_swig_ret string) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_test_plenty__SWIG_1, _swig_p) - return -} -var _wrap_test_plenty__SWIG_2 unsafe.Pointer - -func Test_plenty__SWIG_2(arg1 string) (_swig_ret string) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_test_plenty__SWIG_2, _swig_p) - return -} -func Test_plenty(a ...interface{}) string { - argc := len(a) - if argc == 1 { - return Test_plenty__SWIG_2(a[0].(string)) - } - if argc == 2 { - return Test_plenty__SWIG_1(a[0].(string), a[1].(int)) - } - if argc == 3 { - return Test_plenty__SWIG_0(a[0].(string), a[1].(int), a[2].(int)) - } - panic("No match for overloaded function call") -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/varargs_overload.go b/Examples/test-suite/go/varargs_overload.go deleted file mode 100644 index 92f294fbe..000000000 --- a/Examples/test-suite/go/varargs_overload.go +++ /dev/null @@ -1,165 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../varargs_overload.i - -package varargs_overload - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -var _wrap_vararg_over1__SWIG_0 unsafe.Pointer - -func Vararg_over1__SWIG_0(arg1 string) (_swig_ret string) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_vararg_over1__SWIG_0, _swig_p) - return -} -var _wrap_vararg_over1__SWIG_1 unsafe.Pointer - -func Vararg_over1__SWIG_1(arg1 int) (_swig_ret string) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_vararg_over1__SWIG_1, _swig_p) - return -} -func Vararg_over1(a ...interface{}) string { - argc := len(a) - if argc == 1 { - if _, ok := a[0].(int); !ok { - goto check_1 - } - return Vararg_over1__SWIG_1(a[0].(int)) - } -check_1: - if argc >= 1 { - return Vararg_over1__SWIG_0(a[0].(string)) - } - panic("No match for overloaded function call") -} - -var _wrap_vararg_over2__SWIG_0 unsafe.Pointer - -func Vararg_over2__SWIG_0(arg1 string) (_swig_ret string) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_vararg_over2__SWIG_0, _swig_p) - return -} -var _wrap_vararg_over2__SWIG_1 unsafe.Pointer - -func Vararg_over2__SWIG_1(arg1 int, arg2 float64) (_swig_ret string) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_vararg_over2__SWIG_1, _swig_p) - return -} -func Vararg_over2(a ...interface{}) string { - argc := len(a) - if argc >= 1 { - if _, ok := a[0].(string); !ok { - goto check_1 - } - if argc > 1 { - if _, ok := a[1].([]interface{}); !ok { - goto check_1 - } - } - return Vararg_over2__SWIG_0(a[0].(string)) - } -check_1: - if argc == 2 { - return Vararg_over2__SWIG_1(a[0].(int), a[1].(float64)) - } - panic("No match for overloaded function call") -} - -var _wrap_vararg_over3__SWIG_0 unsafe.Pointer - -func Vararg_over3__SWIG_0(arg1 string) (_swig_ret string) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_vararg_over3__SWIG_0, _swig_p) - return -} -var _wrap_vararg_over3__SWIG_1 unsafe.Pointer - -func Vararg_over3__SWIG_1(arg1 int, arg2 float64, arg3 string) (_swig_ret string) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_vararg_over3__SWIG_1, _swig_p) - return -} -func Vararg_over3(a ...interface{}) string { - argc := len(a) - if argc >= 1 { - if _, ok := a[0].(string); !ok { - goto check_1 - } - if argc > 1 { - if _, ok := a[1].([]interface{}); !ok { - goto check_1 - } - } - return Vararg_over3__SWIG_0(a[0].(string)) - } -check_1: - if argc == 3 { - return Vararg_over3__SWIG_1(a[0].(int), a[1].(float64), a[2].(string)) - } - panic("No match for overloaded function call") -} - -var _wrap_vararg_over4__SWIG_0 unsafe.Pointer - -func Vararg_over4__SWIG_0(arg1 string, arg2 int) (_swig_ret string) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_vararg_over4__SWIG_0, _swig_p) - return -} -var _wrap_vararg_over4__SWIG_1 unsafe.Pointer - -func Vararg_over4__SWIG_1(arg1 string) (_swig_ret string) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_vararg_over4__SWIG_1, _swig_p) - return -} -var _wrap_vararg_over4__SWIG_2 unsafe.Pointer - -func Vararg_over4__SWIG_2(arg1 int) (_swig_ret string) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_vararg_over4__SWIG_2, _swig_p) - return -} -func Vararg_over4(a ...interface{}) string { - argc := len(a) - if argc == 1 { - if _, ok := a[0].(int); !ok { - goto check_1 - } - return Vararg_over4__SWIG_2(a[0].(int)) - } -check_1: - if argc == 1 { - return Vararg_over4__SWIG_1(a[0].(string)) - } - if argc == 2 { - return Vararg_over4__SWIG_0(a[0].(string), a[1].(int)) - } - panic("No match for overloaded function call") -} - - diff --git a/Examples/test-suite/go/varargs_overload_runme b/Examples/test-suite/go/varargs_overload_runme deleted file mode 100755 index 69a5570d6..000000000 Binary files a/Examples/test-suite/go/varargs_overload_runme and /dev/null differ diff --git a/Examples/test-suite/go/varargs_runme b/Examples/test-suite/go/varargs_runme deleted file mode 100755 index 971aa81ad..000000000 Binary files a/Examples/test-suite/go/varargs_runme and /dev/null differ diff --git a/Examples/test-suite/go/virtual_destructor.go b/Examples/test-suite/go/virtual_destructor.go deleted file mode 100644 index fac7c0c52..000000000 --- a/Examples/test-suite/go/virtual_destructor.go +++ /dev/null @@ -1,110 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../virtual_destructor.i - -package virtual_destructor - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrVirtualVoidDestructor uintptr - -func (p SwigcptrVirtualVoidDestructor) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrVirtualVoidDestructor) SwigIsVirtualVoidDestructor() { -} - -var _wrap_new_VirtualVoidDestructor unsafe.Pointer - -func _swig_wrap_new_VirtualVoidDestructor() (base SwigcptrVirtualVoidDestructor) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_VirtualVoidDestructor, _swig_p) - return -} - -func NewVirtualVoidDestructor() (_swig_ret VirtualVoidDestructor) { - return _swig_wrap_new_VirtualVoidDestructor() -} - -var _wrap_delete_VirtualVoidDestructor unsafe.Pointer - -func _swig_wrap_delete_VirtualVoidDestructor(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_VirtualVoidDestructor, _swig_p) - return -} - -func DeleteVirtualVoidDestructor(arg1 VirtualVoidDestructor) { - _swig_wrap_delete_VirtualVoidDestructor(arg1.Swigcptr()) -} - -type VirtualVoidDestructor interface { - Swigcptr() uintptr - SwigIsVirtualVoidDestructor() -} - -type SwigcptrDerived uintptr - -func (p SwigcptrDerived) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrDerived) SwigIsDerived() { -} - -var _wrap_new_Derived unsafe.Pointer - -func _swig_wrap_new_Derived() (base SwigcptrDerived) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Derived, _swig_p) - return -} - -func NewDerived() (_swig_ret Derived) { - return _swig_wrap_new_Derived() -} - -func (p SwigcptrDerived) SwigIsVirtualVoidDestructor() { -} - -func (p SwigcptrDerived) SwigGetVirtualVoidDestructor() VirtualVoidDestructor { - return SwigcptrVirtualVoidDestructor(p.Swigcptr()) -} - -type Derived interface { - Swigcptr() uintptr - SwigIsDerived() - SwigIsVirtualVoidDestructor() - SwigGetVirtualVoidDestructor() VirtualVoidDestructor -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/virtual_poly.go b/Examples/test-suite/go/virtual_poly.go deleted file mode 100644 index f90e59be4..000000000 --- a/Examples/test-suite/go/virtual_poly.go +++ /dev/null @@ -1,1317 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../virtual_poly.i - -package virtual_poly - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrNNumber uintptr - -func (p SwigcptrNNumber) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrNNumber) SwigIsNNumber() { -} - -var _wrap_delete_NNumber unsafe.Pointer - -func _swig_wrap_delete_NNumber(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_NNumber, _swig_p) - return -} - -func DeleteNNumber(arg1 NNumber) { - _swig_wrap_delete_NNumber(arg1.Swigcptr()) -} - -var _wrap_NNumber_copy unsafe.Pointer - -func _swig_wrap_NNumber_copy(base SwigcptrNNumber) (_ SwigcptrNNumber) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_NNumber_copy, _swig_p) - return -} - -func (arg1 SwigcptrNNumber) Copy() (_swig_ret NNumber) { - return _swig_wrap_NNumber_copy(arg1) -} - -var _wrap_NNumber_ref_this unsafe.Pointer - -func _swig_wrap_NNumber_ref_this(base SwigcptrNNumber) (_ SwigcptrNNumber) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_NNumber_ref_this, _swig_p) - return -} - -func (arg1 SwigcptrNNumber) Ref_this() (_swig_ret NNumber) { - return _swig_wrap_NNumber_ref_this(arg1) -} - -var _wrap_NNumber_nnumber unsafe.Pointer - -func _swig_wrap_NNumber_nnumber(base SwigcptrNNumber) (_ SwigcptrNNumber) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_NNumber_nnumber, _swig_p) - return -} - -func (arg1 SwigcptrNNumber) Nnumber() (_swig_ret NNumber) { - return _swig_wrap_NNumber_nnumber(arg1) -} - -type NNumber interface { - Swigcptr() uintptr - SwigIsNNumber() - Copy() (_swig_ret NNumber) - Ref_this() (_swig_ret NNumber) - Nnumber() (_swig_ret NNumber) -} - -type SwigcptrNInt uintptr - -func (p SwigcptrNInt) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrNInt) SwigIsNInt() { -} - -var _wrap_new_NInt unsafe.Pointer - -func _swig_wrap_new_NInt(base int) (_ SwigcptrNInt) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_NInt, _swig_p) - return -} - -func NewNInt(arg1 int) (_swig_ret NInt) { - return _swig_wrap_new_NInt(arg1) -} - -var _wrap_NInt_get unsafe.Pointer - -func _swig_wrap_NInt_get(base SwigcptrNInt) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_NInt_get, _swig_p) - return -} - -func (arg1 SwigcptrNInt) Get() (_swig_ret int) { - return _swig_wrap_NInt_get(arg1) -} - -var _wrap_NInt_copy unsafe.Pointer - -func _swig_wrap_NInt_copy(base SwigcptrNInt) (_ SwigcptrNInt) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_NInt_copy, _swig_p) - return -} - -func (arg1 SwigcptrNInt) Copy() (_swig_ret NInt) { - return _swig_wrap_NInt_copy(arg1) -} - -var _wrap_NInt_ref_this unsafe.Pointer - -func _swig_wrap_NInt_ref_this(base SwigcptrNInt) (_ SwigcptrNInt) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_NInt_ref_this, _swig_p) - return -} - -func (arg1 SwigcptrNInt) Ref_this() (_swig_ret NInt) { - return _swig_wrap_NInt_ref_this(arg1) -} - -var _wrap_NInt_narrow unsafe.Pointer - -func _swig_wrap_NInt_narrow(base uintptr) (_ SwigcptrNInt) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_NInt_narrow, _swig_p) - return -} - -func NIntNarrow(arg1 NNumber) (_swig_ret NInt) { - return _swig_wrap_NInt_narrow(arg1.Swigcptr()) -} - -var _wrap_delete_NInt unsafe.Pointer - -func _swig_wrap_delete_NInt(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_NInt, _swig_p) - return -} - -func DeleteNInt(arg1 NInt) { - _swig_wrap_delete_NInt(arg1.Swigcptr()) -} - -var _wrap_NInt_nnumber unsafe.Pointer - -func _swig_wrap_NInt_nnumber(base SwigcptrNInt) (_ SwigcptrNNumber) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_NInt_nnumber, _swig_p) - return -} - -func (_swig_base SwigcptrNInt) Nnumber() (_swig_ret NNumber) { - return _swig_wrap_NInt_nnumber(_swig_base) -} - -func (p SwigcptrNInt) SwigIsNNumber() { -} - -func (p SwigcptrNInt) SwigGetNNumber() NNumber { - return SwigcptrNNumber(p.Swigcptr()) -} - -type NInt interface { - Swigcptr() uintptr - SwigIsNInt() - Get() (_swig_ret int) - Copy() (_swig_ret NInt) - Ref_this() (_swig_ret NInt) - Nnumber() (_swig_ret NNumber) - SwigIsNNumber() - SwigGetNNumber() NNumber -} - -var _wrap_incr unsafe.Pointer - -func _swig_wrap_incr(base uintptr) (_ SwigcptrNInt) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_incr, _swig_p) - return -} - -func Incr(arg1 NInt) (_swig_ret NInt) { - return _swig_wrap_incr(arg1.Swigcptr()) -} - -type SwigcptrNDouble uintptr - -func (p SwigcptrNDouble) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrNDouble) SwigIsNDouble() { -} - -var _wrap_new_NDouble unsafe.Pointer - -func _swig_wrap_new_NDouble(base float64) (_ SwigcptrNDouble) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_NDouble, _swig_p) - return -} - -func NewNDouble(arg1 float64) (_swig_ret NDouble) { - return _swig_wrap_new_NDouble(arg1) -} - -var _wrap_NDouble_get unsafe.Pointer - -func _swig_wrap_NDouble_get(base SwigcptrNDouble) (_ float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_NDouble_get, _swig_p) - return -} - -func (arg1 SwigcptrNDouble) Get() (_swig_ret float64) { - return _swig_wrap_NDouble_get(arg1) -} - -var _wrap_NDouble_copy unsafe.Pointer - -func _swig_wrap_NDouble_copy(base SwigcptrNDouble) (_ SwigcptrNDouble) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_NDouble_copy, _swig_p) - return -} - -func (arg1 SwigcptrNDouble) Copy() (_swig_ret NDouble) { - return _swig_wrap_NDouble_copy(arg1) -} - -var _wrap_NDouble_ref_this unsafe.Pointer - -func _swig_wrap_NDouble_ref_this(base SwigcptrNDouble) (_ SwigcptrNDouble) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_NDouble_ref_this, _swig_p) - return -} - -func (arg1 SwigcptrNDouble) Ref_this() (_swig_ret NDouble) { - return _swig_wrap_NDouble_ref_this(arg1) -} - -var _wrap_NDouble_narrow unsafe.Pointer - -func _swig_wrap_NDouble_narrow(base uintptr) (_ SwigcptrNDouble) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_NDouble_narrow, _swig_p) - return -} - -func NDoubleNarrow(arg1 NNumber) (_swig_ret NDouble) { - return _swig_wrap_NDouble_narrow(arg1.Swigcptr()) -} - -var _wrap_delete_NDouble unsafe.Pointer - -func _swig_wrap_delete_NDouble(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_NDouble, _swig_p) - return -} - -func DeleteNDouble(arg1 NDouble) { - _swig_wrap_delete_NDouble(arg1.Swigcptr()) -} - -var _wrap_NDouble_nnumber unsafe.Pointer - -func _swig_wrap_NDouble_nnumber(base SwigcptrNDouble) (_ SwigcptrNNumber) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_NDouble_nnumber, _swig_p) - return -} - -func (_swig_base SwigcptrNDouble) Nnumber() (_swig_ret NNumber) { - return _swig_wrap_NDouble_nnumber(_swig_base) -} - -func (p SwigcptrNDouble) SwigIsNNumber() { -} - -func (p SwigcptrNDouble) SwigGetNNumber() NNumber { - return SwigcptrNNumber(p.Swigcptr()) -} - -type NDouble interface { - Swigcptr() uintptr - SwigIsNDouble() - Get() (_swig_ret float64) - Copy() (_swig_ret NDouble) - Ref_this() (_swig_ret NDouble) - Nnumber() (_swig_ret NNumber) - SwigIsNNumber() - SwigGetNNumber() NNumber -} - -type SwigcptrBaseInt uintptr - -func (p SwigcptrBaseInt) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrBaseInt) SwigIsBaseInt() { -} - -var _wrap_BaseInt_t_set unsafe.Pointer - -func _swig_wrap_BaseInt_t_set(base SwigcptrBaseInt, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_BaseInt_t_set, _swig_p) - return -} - -func (arg1 SwigcptrBaseInt) SetT(arg2 int) { - _swig_wrap_BaseInt_t_set(arg1, arg2) -} - -var _wrap_BaseInt_t_get unsafe.Pointer - -func _swig_wrap_BaseInt_t_get(base SwigcptrBaseInt) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_BaseInt_t_get, _swig_p) - return -} - -func (arg1 SwigcptrBaseInt) GetT() (_swig_ret int) { - return _swig_wrap_BaseInt_t_get(arg1) -} - -var _wrap_BaseInt_method unsafe.Pointer - -func _swig_wrap_BaseInt_method(base SwigcptrBaseInt) (_ *int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_BaseInt_method, _swig_p) - return -} - -func (arg1 SwigcptrBaseInt) Method() (_swig_ret *int) { - return _swig_wrap_BaseInt_method(arg1) -} - -var _wrap_BaseInt_foxy__SWIG_0 unsafe.Pointer - -func _swig_wrap_BaseInt_foxy__SWIG_0(base SwigcptrBaseInt) (_ *int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_BaseInt_foxy__SWIG_0, _swig_p) - return -} - -func (arg1 SwigcptrBaseInt) Foxy__SWIG_0() (_swig_ret *int) { - return _swig_wrap_BaseInt_foxy__SWIG_0(arg1) -} - -var _wrap_BaseInt_foxy__SWIG_1 unsafe.Pointer - -func _swig_wrap_BaseInt_foxy__SWIG_1(base SwigcptrBaseInt, _ int) (_ *int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_BaseInt_foxy__SWIG_1, _swig_p) - return -} - -func (arg1 SwigcptrBaseInt) Foxy__SWIG_1(arg2 int) (_swig_ret *int) { - return _swig_wrap_BaseInt_foxy__SWIG_1(arg1, arg2) -} - -var _wrap_BaseInt_foxy__SWIG_2 unsafe.Pointer - -func _swig_wrap_BaseInt_foxy__SWIG_2(base SwigcptrBaseInt, _ **int) (_ *int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_BaseInt_foxy__SWIG_2, _swig_p) - return -} - -func (arg1 SwigcptrBaseInt) Foxy__SWIG_2(arg2 **int) (_swig_ret *int) { - return _swig_wrap_BaseInt_foxy__SWIG_2(arg1, arg2) -} - -func (p SwigcptrBaseInt) Foxy(a ...interface{}) interface{} { - argc := len(a) - if argc == 0 { - return p.Foxy__SWIG_0() - } - if argc == 1 { - if _, ok := a[0].(**int); !ok { - goto check_2 - } - return p.Foxy__SWIG_2(a[0].(**int)) - } -check_2: - if argc == 1 { - return p.Foxy__SWIG_1(a[0].(int)) - } - panic("No match for overloaded function call") -} - -var _wrap_BaseInt_afunction unsafe.Pointer - -func _swig_wrap_BaseInt_afunction(base SwigcptrBaseInt) (_ float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_BaseInt_afunction, _swig_p) - return -} - -func (arg1 SwigcptrBaseInt) Afunction() (_swig_ret float64) { - return _swig_wrap_BaseInt_afunction(arg1) -} - -var _wrap_BaseInt_defaultargs__SWIG_0 unsafe.Pointer - -func _swig_wrap_BaseInt_defaultargs__SWIG_0(base SwigcptrBaseInt, _ float64, _ *int) (_ *int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_BaseInt_defaultargs__SWIG_0, _swig_p) - return -} - -func (arg1 SwigcptrBaseInt) Defaultargs__SWIG_0(arg2 float64, arg3 *int) (_swig_ret *int) { - return _swig_wrap_BaseInt_defaultargs__SWIG_0(arg1, arg2, arg3) -} - -var _wrap_BaseInt_defaultargs__SWIG_1 unsafe.Pointer - -func _swig_wrap_BaseInt_defaultargs__SWIG_1(base SwigcptrBaseInt, _ float64) (_ *int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_BaseInt_defaultargs__SWIG_1, _swig_p) - return -} - -func (arg1 SwigcptrBaseInt) Defaultargs__SWIG_1(arg2 float64) (_swig_ret *int) { - return _swig_wrap_BaseInt_defaultargs__SWIG_1(arg1, arg2) -} - -func (p SwigcptrBaseInt) Defaultargs(a ...interface{}) *int { - argc := len(a) - if argc == 1 { - return p.Defaultargs__SWIG_1(a[0].(float64)) - } - if argc == 2 { - return p.Defaultargs__SWIG_0(a[0].(float64), a[1].(*int)) - } - panic("No match for overloaded function call") -} - -var _wrap_BaseInt_StaticHidden unsafe.Pointer - -func _swig_wrap_BaseInt_StaticHidden() { - var _swig_p uintptr - _cgo_runtime_cgocall(_wrap_BaseInt_StaticHidden, _swig_p) - return -} - -func BaseIntStaticHidden() { - _swig_wrap_BaseInt_StaticHidden() -} - -var _wrap_BaseInt_AmIAmINotVirtual unsafe.Pointer - -func _swig_wrap_BaseInt_AmIAmINotVirtual(base SwigcptrBaseInt) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_BaseInt_AmIAmINotVirtual, _swig_p) - return -} - -func (arg1 SwigcptrBaseInt) AmIAmINotVirtual() { - _swig_wrap_BaseInt_AmIAmINotVirtual(arg1) -} - -var _wrap_BaseInt_NotVirtual unsafe.Pointer - -func _swig_wrap_BaseInt_NotVirtual(base SwigcptrBaseInt, _ *int) (_ *int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_BaseInt_NotVirtual, _swig_p) - return -} - -func (arg1 SwigcptrBaseInt) NotVirtual(arg2 *int) (_swig_ret *int) { - return _swig_wrap_BaseInt_NotVirtual(arg1, arg2) -} - -var _wrap_BaseInt_covariant__SWIG_0 unsafe.Pointer - -func _swig_wrap_BaseInt_covariant__SWIG_0(base SwigcptrBaseInt, _ int, _ *int) (_ SwigcptrBaseInt) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_BaseInt_covariant__SWIG_0, _swig_p) - return -} - -func (arg1 SwigcptrBaseInt) Covariant__SWIG_0(arg2 int, arg3 *int) (_swig_ret BaseInt) { - return _swig_wrap_BaseInt_covariant__SWIG_0(arg1, arg2, arg3) -} - -var _wrap_BaseInt_covariant__SWIG_1 unsafe.Pointer - -func _swig_wrap_BaseInt_covariant__SWIG_1(base SwigcptrBaseInt, _ int) (_ SwigcptrBaseInt) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_BaseInt_covariant__SWIG_1, _swig_p) - return -} - -func (arg1 SwigcptrBaseInt) Covariant__SWIG_1(arg2 int) (_swig_ret BaseInt) { - return _swig_wrap_BaseInt_covariant__SWIG_1(arg1, arg2) -} - -var _wrap_BaseInt_covariant__SWIG_2 unsafe.Pointer - -func _swig_wrap_BaseInt_covariant__SWIG_2(base SwigcptrBaseInt) (_ SwigcptrBaseInt) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_BaseInt_covariant__SWIG_2, _swig_p) - return -} - -func (arg1 SwigcptrBaseInt) Covariant__SWIG_2() (_swig_ret BaseInt) { - return _swig_wrap_BaseInt_covariant__SWIG_2(arg1) -} - -func (p SwigcptrBaseInt) Covariant(a ...interface{}) BaseInt { - argc := len(a) - if argc == 0 { - return p.Covariant__SWIG_2() - } - if argc == 1 { - return p.Covariant__SWIG_1(a[0].(int)) - } - if argc == 2 { - return p.Covariant__SWIG_0(a[0].(int), a[1].(*int)) - } - panic("No match for overloaded function call") -} - -var _wrap_BaseInt_covariant2 unsafe.Pointer - -func _swig_wrap_BaseInt_covariant2(base SwigcptrBaseInt) (_ SwigcptrBaseInt) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_BaseInt_covariant2, _swig_p) - return -} - -func (arg1 SwigcptrBaseInt) Covariant2() (_swig_ret BaseInt) { - return _swig_wrap_BaseInt_covariant2(arg1) -} - -var _wrap_BaseInt_covariant3 unsafe.Pointer - -func _swig_wrap_BaseInt_covariant3(base SwigcptrBaseInt) (_ SwigcptrBaseInt) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_BaseInt_covariant3, _swig_p) - return -} - -func (arg1 SwigcptrBaseInt) Covariant3() (_swig_ret BaseInt) { - return _swig_wrap_BaseInt_covariant3(arg1) -} - -var _wrap_delete_BaseInt unsafe.Pointer - -func _swig_wrap_delete_BaseInt(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_BaseInt, _swig_p) - return -} - -func DeleteBaseInt(arg1 BaseInt) { - _swig_wrap_delete_BaseInt(arg1.Swigcptr()) -} - -type BaseInt interface { - Swigcptr() uintptr - SwigIsBaseInt() - SetT(arg2 int) - GetT() (_swig_ret int) - Method() (_swig_ret *int) - Foxy(a ...interface{}) interface{} - Afunction() (_swig_ret float64) - Defaultargs(a ...interface{}) *int - AmIAmINotVirtual() - NotVirtual(arg2 *int) (_swig_ret *int) - Covariant(a ...interface{}) BaseInt - Covariant2() (_swig_ret BaseInt) - Covariant3() (_swig_ret BaseInt) -} - -type SwigcptrDerivedInt uintptr - -func (p SwigcptrDerivedInt) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrDerivedInt) SwigIsDerivedInt() { -} - -var _wrap_DerivedInt_method unsafe.Pointer - -func _swig_wrap_DerivedInt_method(base SwigcptrDerivedInt) (_ *int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_DerivedInt_method, _swig_p) - return -} - -func (arg1 SwigcptrDerivedInt) Method() (_swig_ret *int) { - return _swig_wrap_DerivedInt_method(arg1) -} - -var _wrap_DerivedInt_foxy__SWIG_0 unsafe.Pointer - -func _swig_wrap_DerivedInt_foxy__SWIG_0(base SwigcptrDerivedInt) (_ *int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_DerivedInt_foxy__SWIG_0, _swig_p) - return -} - -func (arg1 SwigcptrDerivedInt) Foxy__SWIG_0() (_swig_ret *int) { - return _swig_wrap_DerivedInt_foxy__SWIG_0(arg1) -} - -var _wrap_DerivedInt_foxy__SWIG_1 unsafe.Pointer - -func _swig_wrap_DerivedInt_foxy__SWIG_1(base SwigcptrDerivedInt, _ int) (_ *int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_DerivedInt_foxy__SWIG_1, _swig_p) - return -} - -func (arg1 SwigcptrDerivedInt) Foxy__SWIG_1(arg2 int) (_swig_ret *int) { - return _swig_wrap_DerivedInt_foxy__SWIG_1(arg1, arg2) -} - -var _wrap_DerivedInt_foxy__SWIG_2 unsafe.Pointer - -func _swig_wrap_DerivedInt_foxy__SWIG_2(base SwigcptrDerivedInt, _ **int) (_ *int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_DerivedInt_foxy__SWIG_2, _swig_p) - return -} - -func (arg1 SwigcptrDerivedInt) Foxy__SWIG_2(arg2 **int) (_swig_ret *int) { - return _swig_wrap_DerivedInt_foxy__SWIG_2(arg1, arg2) -} - -func (p SwigcptrDerivedInt) Foxy(a ...interface{}) interface{} { - argc := len(a) - if argc == 0 { - return p.Foxy__SWIG_0() - } - if argc == 1 { - if _, ok := a[0].(**int); !ok { - goto check_2 - } - return p.Foxy__SWIG_2(a[0].(**int)) - } -check_2: - if argc == 1 { - return p.Foxy__SWIG_1(a[0].(int)) - } - panic("No match for overloaded function call") -} - -var _wrap_DerivedInt_afunction unsafe.Pointer - -func _swig_wrap_DerivedInt_afunction(base SwigcptrDerivedInt) (_ float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_DerivedInt_afunction, _swig_p) - return -} - -func (arg1 SwigcptrDerivedInt) Afunction() (_swig_ret float64) { - return _swig_wrap_DerivedInt_afunction(arg1) -} - -var _wrap_DerivedInt_defaultargs__SWIG_0 unsafe.Pointer - -func _swig_wrap_DerivedInt_defaultargs__SWIG_0(base SwigcptrDerivedInt, _ float64, _ *int) (_ *int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_DerivedInt_defaultargs__SWIG_0, _swig_p) - return -} - -func (arg1 SwigcptrDerivedInt) Defaultargs__SWIG_0(arg2 float64, arg3 *int) (_swig_ret *int) { - return _swig_wrap_DerivedInt_defaultargs__SWIG_0(arg1, arg2, arg3) -} - -var _wrap_DerivedInt_defaultargs__SWIG_1 unsafe.Pointer - -func _swig_wrap_DerivedInt_defaultargs__SWIG_1(base SwigcptrDerivedInt, _ float64) (_ *int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_DerivedInt_defaultargs__SWIG_1, _swig_p) - return -} - -func (arg1 SwigcptrDerivedInt) Defaultargs__SWIG_1(arg2 float64) (_swig_ret *int) { - return _swig_wrap_DerivedInt_defaultargs__SWIG_1(arg1, arg2) -} - -func (p SwigcptrDerivedInt) Defaultargs(a ...interface{}) *int { - argc := len(a) - if argc == 1 { - return p.Defaultargs__SWIG_1(a[0].(float64)) - } - if argc == 2 { - return p.Defaultargs__SWIG_0(a[0].(float64), a[1].(*int)) - } - panic("No match for overloaded function call") -} - -var _wrap_DerivedInt_AmIAmINotVirtual unsafe.Pointer - -func _swig_wrap_DerivedInt_AmIAmINotVirtual(base SwigcptrDerivedInt) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_DerivedInt_AmIAmINotVirtual, _swig_p) - return -} - -func (arg1 SwigcptrDerivedInt) AmIAmINotVirtual() { - _swig_wrap_DerivedInt_AmIAmINotVirtual(arg1) -} - -var _wrap_DerivedInt_NotVirtual unsafe.Pointer - -func _swig_wrap_DerivedInt_NotVirtual(base SwigcptrDerivedInt, _ *int) (_ *int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_DerivedInt_NotVirtual, _swig_p) - return -} - -func (arg1 SwigcptrDerivedInt) NotVirtual(arg2 *int) (_swig_ret *int) { - return _swig_wrap_DerivedInt_NotVirtual(arg1, arg2) -} - -var _wrap_DerivedInt_covariant__SWIG_0 unsafe.Pointer - -func _swig_wrap_DerivedInt_covariant__SWIG_0(base SwigcptrDerivedInt, _ int, _ *int) (_ SwigcptrDerivedInt) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_DerivedInt_covariant__SWIG_0, _swig_p) - return -} - -func (arg1 SwigcptrDerivedInt) Covariant__SWIG_0(arg2 int, arg3 *int) (_swig_ret DerivedInt) { - return _swig_wrap_DerivedInt_covariant__SWIG_0(arg1, arg2, arg3) -} - -var _wrap_DerivedInt_covariant__SWIG_1 unsafe.Pointer - -func _swig_wrap_DerivedInt_covariant__SWIG_1(base SwigcptrDerivedInt, _ int) (_ SwigcptrDerivedInt) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_DerivedInt_covariant__SWIG_1, _swig_p) - return -} - -func (arg1 SwigcptrDerivedInt) Covariant__SWIG_1(arg2 int) (_swig_ret DerivedInt) { - return _swig_wrap_DerivedInt_covariant__SWIG_1(arg1, arg2) -} - -var _wrap_DerivedInt_covariant__SWIG_2 unsafe.Pointer - -func _swig_wrap_DerivedInt_covariant__SWIG_2(base SwigcptrDerivedInt) (_ SwigcptrDerivedInt) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_DerivedInt_covariant__SWIG_2, _swig_p) - return -} - -func (arg1 SwigcptrDerivedInt) Covariant__SWIG_2() (_swig_ret DerivedInt) { - return _swig_wrap_DerivedInt_covariant__SWIG_2(arg1) -} - -func (p SwigcptrDerivedInt) Covariant(a ...interface{}) DerivedInt { - argc := len(a) - if argc == 0 { - return p.Covariant__SWIG_2() - } - if argc == 1 { - return p.Covariant__SWIG_1(a[0].(int)) - } - if argc == 2 { - return p.Covariant__SWIG_0(a[0].(int), a[1].(*int)) - } - panic("No match for overloaded function call") -} - -var _wrap_DerivedInt_covariant2 unsafe.Pointer - -func _swig_wrap_DerivedInt_covariant2(base SwigcptrDerivedInt) (_ SwigcptrDerivedInt) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_DerivedInt_covariant2, _swig_p) - return -} - -func (arg1 SwigcptrDerivedInt) Covariant2() (_swig_ret DerivedInt) { - return _swig_wrap_DerivedInt_covariant2(arg1) -} - -var _wrap_DerivedInt_covariant3 unsafe.Pointer - -func _swig_wrap_DerivedInt_covariant3(base SwigcptrDerivedInt) (_ SwigcptrDerivedInt) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_DerivedInt_covariant3, _swig_p) - return -} - -func (arg1 SwigcptrDerivedInt) Covariant3() (_swig_ret DerivedInt) { - return _swig_wrap_DerivedInt_covariant3(arg1) -} - -var _wrap_DerivedInt_covariant4 unsafe.Pointer - -func _swig_wrap_DerivedInt_covariant4(base SwigcptrDerivedInt, _ float64) (_ SwigcptrDerivedInt) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_DerivedInt_covariant4, _swig_p) - return -} - -func (arg1 SwigcptrDerivedInt) Covariant4(arg2 float64) (_swig_ret DerivedInt) { - return _swig_wrap_DerivedInt_covariant4(arg1, arg2) -} - -var _wrap_DerivedInt_IsVirtual unsafe.Pointer - -func _swig_wrap_DerivedInt_IsVirtual(base SwigcptrDerivedInt) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_DerivedInt_IsVirtual, _swig_p) - return -} - -func (arg1 SwigcptrDerivedInt) IsVirtual() (_swig_ret int) { - return _swig_wrap_DerivedInt_IsVirtual(arg1) -} - -var _wrap_new_DerivedInt unsafe.Pointer - -func _swig_wrap_new_DerivedInt() (base SwigcptrDerivedInt) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_DerivedInt, _swig_p) - return -} - -func NewDerivedInt() (_swig_ret DerivedInt) { - return _swig_wrap_new_DerivedInt() -} - -var _wrap_delete_DerivedInt unsafe.Pointer - -func _swig_wrap_delete_DerivedInt(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_DerivedInt, _swig_p) - return -} - -func DeleteDerivedInt(arg1 DerivedInt) { - _swig_wrap_delete_DerivedInt(arg1.Swigcptr()) -} - -var _wrap_SetDerivedInt_T unsafe.Pointer - -func _swig_wrap_SetDerivedInt_T(base SwigcptrDerivedInt, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_SetDerivedInt_T, _swig_p) - return -} - -func (_swig_base SwigcptrDerivedInt) SetT(arg1 int) { - _swig_wrap_SetDerivedInt_T(_swig_base, arg1) -} - -var _wrap_GetDerivedInt_T unsafe.Pointer - -func _swig_wrap_GetDerivedInt_T(base SwigcptrDerivedInt) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_GetDerivedInt_T, _swig_p) - return -} - -func (_swig_base SwigcptrDerivedInt) GetT() (_swig_ret int) { - return _swig_wrap_GetDerivedInt_T(_swig_base) -} - -var _wrap_DerivedInt_StaticHidden unsafe.Pointer - -func _swig_wrap_DerivedInt_StaticHidden() { - var _swig_p uintptr - _cgo_runtime_cgocall(_wrap_DerivedInt_StaticHidden, _swig_p) - return -} - -func DerivedIntStaticHidden() { - _swig_wrap_DerivedInt_StaticHidden() -} - -func (p SwigcptrDerivedInt) SwigIsBaseInt() { -} - -func (p SwigcptrDerivedInt) SwigGetBaseInt() BaseInt { - return SwigcptrBaseInt(p.Swigcptr()) -} - -type DerivedInt interface { - Swigcptr() uintptr - SwigIsDerivedInt() - Method() (_swig_ret *int) - Foxy(a ...interface{}) interface{} - Afunction() (_swig_ret float64) - Defaultargs(a ...interface{}) *int - AmIAmINotVirtual() - NotVirtual(arg2 *int) (_swig_ret *int) - Covariant(a ...interface{}) DerivedInt - Covariant2() (_swig_ret DerivedInt) - Covariant3() (_swig_ret DerivedInt) - Covariant4(arg2 float64) (_swig_ret DerivedInt) - IsVirtual() (_swig_ret int) - SetT(arg1 int) - GetT() (_swig_ret int) - SwigIsBaseInt() - SwigGetBaseInt() BaseInt -} - -type SwigcptrBottomInt uintptr - -func (p SwigcptrBottomInt) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrBottomInt) SwigIsBottomInt() { -} - -var _wrap_BottomInt_method unsafe.Pointer - -func _swig_wrap_BottomInt_method(base SwigcptrBottomInt) (_ *int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_BottomInt_method, _swig_p) - return -} - -func (arg1 SwigcptrBottomInt) Method() (_swig_ret *int) { - return _swig_wrap_BottomInt_method(arg1) -} - -var _wrap_BottomInt_StaticHidden unsafe.Pointer - -func _swig_wrap_BottomInt_StaticHidden() { - var _swig_p uintptr - _cgo_runtime_cgocall(_wrap_BottomInt_StaticHidden, _swig_p) - return -} - -func BottomIntStaticHidden() { - _swig_wrap_BottomInt_StaticHidden() -} - -var _wrap_BottomInt_AmIAmINotVirtual unsafe.Pointer - -func _swig_wrap_BottomInt_AmIAmINotVirtual(base SwigcptrBottomInt) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_BottomInt_AmIAmINotVirtual, _swig_p) - return -} - -func (arg1 SwigcptrBottomInt) AmIAmINotVirtual() { - _swig_wrap_BottomInt_AmIAmINotVirtual(arg1) -} - -var _wrap_BottomInt_NotVirtual unsafe.Pointer - -func _swig_wrap_BottomInt_NotVirtual(base SwigcptrBottomInt, _ *int) (_ *int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_BottomInt_NotVirtual, _swig_p) - return -} - -func (arg1 SwigcptrBottomInt) NotVirtual(arg2 *int) (_swig_ret *int) { - return _swig_wrap_BottomInt_NotVirtual(arg1, arg2) -} - -var _wrap_BottomInt_funcptr_set unsafe.Pointer - -func _swig_wrap_BottomInt_funcptr_set(base SwigcptrBottomInt, _ _swig_fnptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_BottomInt_funcptr_set, _swig_p) - return -} - -func (arg1 SwigcptrBottomInt) SetFuncptr(arg2 _swig_fnptr) { - _swig_wrap_BottomInt_funcptr_set(arg1, arg2) -} - -var _wrap_BottomInt_funcptr_get unsafe.Pointer - -func _swig_wrap_BottomInt_funcptr_get(base SwigcptrBottomInt) (_ _swig_fnptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_BottomInt_funcptr_get, _swig_p) - return -} - -func (arg1 SwigcptrBottomInt) GetFuncptr() (_swig_ret _swig_fnptr) { - return _swig_wrap_BottomInt_funcptr_get(arg1) -} - -var _wrap_BottomInt_covariant__SWIG_0 unsafe.Pointer - -func _swig_wrap_BottomInt_covariant__SWIG_0(base SwigcptrBottomInt, _ int, _ *int) (_ SwigcptrBottomInt) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_BottomInt_covariant__SWIG_0, _swig_p) - return -} - -func (arg1 SwigcptrBottomInt) Covariant__SWIG_0(arg2 int, arg3 *int) (_swig_ret BottomInt) { - return _swig_wrap_BottomInt_covariant__SWIG_0(arg1, arg2, arg3) -} - -var _wrap_BottomInt_covariant__SWIG_1 unsafe.Pointer - -func _swig_wrap_BottomInt_covariant__SWIG_1(base SwigcptrBottomInt, _ int) (_ SwigcptrBottomInt) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_BottomInt_covariant__SWIG_1, _swig_p) - return -} - -func (arg1 SwigcptrBottomInt) Covariant__SWIG_1(arg2 int) (_swig_ret BottomInt) { - return _swig_wrap_BottomInt_covariant__SWIG_1(arg1, arg2) -} - -var _wrap_BottomInt_covariant__SWIG_2 unsafe.Pointer - -func _swig_wrap_BottomInt_covariant__SWIG_2(base SwigcptrBottomInt) (_ SwigcptrBottomInt) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_BottomInt_covariant__SWIG_2, _swig_p) - return -} - -func (arg1 SwigcptrBottomInt) Covariant__SWIG_2() (_swig_ret BottomInt) { - return _swig_wrap_BottomInt_covariant__SWIG_2(arg1) -} - -func (p SwigcptrBottomInt) Covariant(a ...interface{}) BottomInt { - argc := len(a) - if argc == 0 { - return p.Covariant__SWIG_2() - } - if argc == 1 { - return p.Covariant__SWIG_1(a[0].(int)) - } - if argc == 2 { - return p.Covariant__SWIG_0(a[0].(int), a[1].(*int)) - } - panic("No match for overloaded function call") -} - -var _wrap_BottomInt_covariant2 unsafe.Pointer - -func _swig_wrap_BottomInt_covariant2(base SwigcptrBottomInt) (_ SwigcptrDerivedInt) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_BottomInt_covariant2, _swig_p) - return -} - -func (arg1 SwigcptrBottomInt) Covariant2() (_swig_ret DerivedInt) { - return _swig_wrap_BottomInt_covariant2(arg1) -} - -var _wrap_BottomInt_covariant3 unsafe.Pointer - -func _swig_wrap_BottomInt_covariant3(base SwigcptrBottomInt) (_ SwigcptrBottomInt) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_BottomInt_covariant3, _swig_p) - return -} - -func (arg1 SwigcptrBottomInt) Covariant3() (_swig_ret BottomInt) { - return _swig_wrap_BottomInt_covariant3(arg1) -} - -var _wrap_BottomInt_covariant4 unsafe.Pointer - -func _swig_wrap_BottomInt_covariant4(base SwigcptrBottomInt, _ float64) (_ SwigcptrBottomInt) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_BottomInt_covariant4, _swig_p) - return -} - -func (arg1 SwigcptrBottomInt) Covariant4(arg2 float64) (_swig_ret BottomInt) { - return _swig_wrap_BottomInt_covariant4(arg1, arg2) -} - -var _wrap_BottomInt_IsVirtual unsafe.Pointer - -func _swig_wrap_BottomInt_IsVirtual(base SwigcptrBottomInt) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_BottomInt_IsVirtual, _swig_p) - return -} - -func (arg1 SwigcptrBottomInt) IsVirtual() (_swig_ret int) { - return _swig_wrap_BottomInt_IsVirtual(arg1) -} - -var _wrap_new_BottomInt unsafe.Pointer - -func _swig_wrap_new_BottomInt() (base SwigcptrBottomInt) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_BottomInt, _swig_p) - return -} - -func NewBottomInt() (_swig_ret BottomInt) { - return _swig_wrap_new_BottomInt() -} - -var _wrap_delete_BottomInt unsafe.Pointer - -func _swig_wrap_delete_BottomInt(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_BottomInt, _swig_p) - return -} - -func DeleteBottomInt(arg1 BottomInt) { - _swig_wrap_delete_BottomInt(arg1.Swigcptr()) -} - -var _wrap_BottomInt_foxy__SWIG_0 unsafe.Pointer - -func _swig_wrap_BottomInt_foxy__SWIG_0(base SwigcptrBottomInt) (_ *int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_BottomInt_foxy__SWIG_0, _swig_p) - return -} - -func (_swig_base SwigcptrBottomInt) Foxy__SWIG_0() (_swig_ret *int) { - return _swig_wrap_BottomInt_foxy__SWIG_0(_swig_base) -} - -var _wrap_BottomInt_foxy__SWIG_1 unsafe.Pointer - -func _swig_wrap_BottomInt_foxy__SWIG_1(base SwigcptrBottomInt, _ int) (_ *int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_BottomInt_foxy__SWIG_1, _swig_p) - return -} - -func (_swig_base SwigcptrBottomInt) Foxy__SWIG_1(arg1 int) (_swig_ret *int) { - return _swig_wrap_BottomInt_foxy__SWIG_1(_swig_base, arg1) -} - -var _wrap_BottomInt_foxy__SWIG_2 unsafe.Pointer - -func _swig_wrap_BottomInt_foxy__SWIG_2(base SwigcptrBottomInt, _ **int) (_ *int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_BottomInt_foxy__SWIG_2, _swig_p) - return -} - -func (_swig_base SwigcptrBottomInt) Foxy__SWIG_2(arg1 **int) (_swig_ret *int) { - return _swig_wrap_BottomInt_foxy__SWIG_2(_swig_base, arg1) -} - -func (p SwigcptrBottomInt) Foxy(a ...interface{}) interface{} { - argc := len(a) - if argc == 0 { - return p.Foxy__SWIG_0() - } - if argc == 1 { - if _, ok := a[0].(**int); !ok { - goto check_2 - } - return p.Foxy__SWIG_2(a[0].(**int)) - } -check_2: - if argc == 1 { - return p.Foxy__SWIG_1(a[0].(int)) - } - panic("No match for overloaded function call") -} - -var _wrap_BottomInt_afunction unsafe.Pointer - -func _swig_wrap_BottomInt_afunction(base SwigcptrBottomInt) (_ float64) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_BottomInt_afunction, _swig_p) - return -} - -func (_swig_base SwigcptrBottomInt) Afunction() (_swig_ret float64) { - return _swig_wrap_BottomInt_afunction(_swig_base) -} - -var _wrap_BottomInt_defaultargs__SWIG_0 unsafe.Pointer - -func _swig_wrap_BottomInt_defaultargs__SWIG_0(base SwigcptrBottomInt, _ float64, _ *int) (_ *int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_BottomInt_defaultargs__SWIG_0, _swig_p) - return -} - -func (_swig_base SwigcptrBottomInt) Defaultargs__SWIG_0(arg1 float64, arg2 *int) (_swig_ret *int) { - return _swig_wrap_BottomInt_defaultargs__SWIG_0(_swig_base, arg1, arg2) -} - -var _wrap_BottomInt_defaultargs__SWIG_1 unsafe.Pointer - -func _swig_wrap_BottomInt_defaultargs__SWIG_1(base SwigcptrBottomInt, _ float64) (_ *int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_BottomInt_defaultargs__SWIG_1, _swig_p) - return -} - -func (_swig_base SwigcptrBottomInt) Defaultargs__SWIG_1(arg1 float64) (_swig_ret *int) { - return _swig_wrap_BottomInt_defaultargs__SWIG_1(_swig_base, arg1) -} - -func (p SwigcptrBottomInt) Defaultargs(a ...interface{}) *int { - argc := len(a) - if argc == 1 { - return p.Defaultargs__SWIG_1(a[0].(float64)) - } - if argc == 2 { - return p.Defaultargs__SWIG_0(a[0].(float64), a[1].(*int)) - } - panic("No match for overloaded function call") -} - -var _wrap_SetBottomInt_T unsafe.Pointer - -func _swig_wrap_SetBottomInt_T(base SwigcptrBottomInt, _ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_SetBottomInt_T, _swig_p) - return -} - -func (_swig_base SwigcptrBottomInt) SetT(arg1 int) { - _swig_wrap_SetBottomInt_T(_swig_base, arg1) -} - -var _wrap_GetBottomInt_T unsafe.Pointer - -func _swig_wrap_GetBottomInt_T(base SwigcptrBottomInt) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_GetBottomInt_T, _swig_p) - return -} - -func (_swig_base SwigcptrBottomInt) GetT() (_swig_ret int) { - return _swig_wrap_GetBottomInt_T(_swig_base) -} - -func (p SwigcptrBottomInt) SwigIsDerivedInt() { -} - -func (p SwigcptrBottomInt) SwigGetDerivedInt() DerivedInt { - return SwigcptrDerivedInt(p.Swigcptr()) -} - -func (p SwigcptrBottomInt) SwigIsBaseInt() { -} - -func (p SwigcptrBottomInt) SwigGetBaseInt() BaseInt { - return SwigcptrBaseInt(p.Swigcptr()) -} - -type BottomInt interface { - Swigcptr() uintptr - SwigIsBottomInt() - Method() (_swig_ret *int) - AmIAmINotVirtual() - NotVirtual(arg2 *int) (_swig_ret *int) - SetFuncptr(arg2 _swig_fnptr) - GetFuncptr() (_swig_ret _swig_fnptr) - Covariant(a ...interface{}) BottomInt - Covariant2() (_swig_ret DerivedInt) - Covariant3() (_swig_ret BottomInt) - Covariant4(arg2 float64) (_swig_ret BottomInt) - IsVirtual() (_swig_ret int) - Foxy(a ...interface{}) interface{} - Afunction() (_swig_ret float64) - Defaultargs(a ...interface{}) *int - SetT(arg1 int) - GetT() (_swig_ret int) - SwigIsDerivedInt() - SwigGetDerivedInt() DerivedInt - SwigIsBaseInt() - SwigGetBaseInt() BaseInt -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/virtual_poly_runme b/Examples/test-suite/go/virtual_poly_runme deleted file mode 100755 index 670688de5..000000000 Binary files a/Examples/test-suite/go/virtual_poly_runme and /dev/null differ diff --git a/Examples/test-suite/go/virtual_poly_wrap.h b/Examples/test-suite/go/virtual_poly_wrap.h deleted file mode 100644 index 6c64bf2bb..000000000 --- a/Examples/test-suite/go/virtual_poly_wrap.h +++ /dev/null @@ -1,16 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../virtual_poly.i - -#ifndef SWIG_virtual_poly_WRAP_H_ -#define SWIG_virtual_poly_WRAP_H_ - -#endif diff --git a/Examples/test-suite/go/virtual_vs_nonvirtual_base.go b/Examples/test-suite/go/virtual_vs_nonvirtual_base.go deleted file mode 100644 index f2355fb7e..000000000 --- a/Examples/test-suite/go/virtual_vs_nonvirtual_base.go +++ /dev/null @@ -1,337 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../virtual_vs_nonvirtual_base.i - -package virtual_vs_nonvirtual_base - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -type SwigcptrSimpleVirtual uintptr - -func (p SwigcptrSimpleVirtual) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrSimpleVirtual) SwigIsSimpleVirtual() { -} - -var _wrap_SimpleVirtual_implementMe unsafe.Pointer - -func _swig_wrap_SimpleVirtual_implementMe(base SwigcptrSimpleVirtual) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_SimpleVirtual_implementMe, _swig_p) - return -} - -func (arg1 SwigcptrSimpleVirtual) ImplementMe() (_swig_ret int) { - return _swig_wrap_SimpleVirtual_implementMe(arg1) -} - -var _wrap_delete_SimpleVirtual unsafe.Pointer - -func _swig_wrap_delete_SimpleVirtual(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_SimpleVirtual, _swig_p) - return -} - -func DeleteSimpleVirtual(arg1 SimpleVirtual) { - _swig_wrap_delete_SimpleVirtual(arg1.Swigcptr()) -} - -type SimpleVirtual interface { - Swigcptr() uintptr - SwigIsSimpleVirtual() - ImplementMe() (_swig_ret int) -} - -type SwigcptrSimpleNonVirtual uintptr - -func (p SwigcptrSimpleNonVirtual) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrSimpleNonVirtual) SwigIsSimpleNonVirtual() { -} - -var _wrap_SimpleNonVirtual_dummy unsafe.Pointer - -func _swig_wrap_SimpleNonVirtual_dummy(base SwigcptrSimpleNonVirtual) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_SimpleNonVirtual_dummy, _swig_p) - return -} - -func (arg1 SwigcptrSimpleNonVirtual) Dummy() (_swig_ret int) { - return _swig_wrap_SimpleNonVirtual_dummy(arg1) -} - -var _wrap_new_SimpleNonVirtual unsafe.Pointer - -func _swig_wrap_new_SimpleNonVirtual() (base SwigcptrSimpleNonVirtual) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_SimpleNonVirtual, _swig_p) - return -} - -func NewSimpleNonVirtual() (_swig_ret SimpleNonVirtual) { - return _swig_wrap_new_SimpleNonVirtual() -} - -var _wrap_delete_SimpleNonVirtual unsafe.Pointer - -func _swig_wrap_delete_SimpleNonVirtual(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_SimpleNonVirtual, _swig_p) - return -} - -func DeleteSimpleNonVirtual(arg1 SimpleNonVirtual) { - _swig_wrap_delete_SimpleNonVirtual(arg1.Swigcptr()) -} - -type SimpleNonVirtual interface { - Swigcptr() uintptr - SwigIsSimpleNonVirtual() - Dummy() (_swig_ret int) -} - -type SwigcptrSimpleReturnClass uintptr - -func (p SwigcptrSimpleReturnClass) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrSimpleReturnClass) SwigIsSimpleReturnClass() { -} - -var _wrap_new_SimpleReturnClass unsafe.Pointer - -func _swig_wrap_new_SimpleReturnClass(base int) (_ SwigcptrSimpleReturnClass) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_SimpleReturnClass, _swig_p) - return -} - -func NewSimpleReturnClass(arg1 int) (_swig_ret SimpleReturnClass) { - return _swig_wrap_new_SimpleReturnClass(arg1) -} - -var _wrap_SimpleReturnClass_get unsafe.Pointer - -func _swig_wrap_SimpleReturnClass_get(base SwigcptrSimpleReturnClass) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_SimpleReturnClass_get, _swig_p) - return -} - -func (arg1 SwigcptrSimpleReturnClass) Get() (_swig_ret int) { - return _swig_wrap_SimpleReturnClass_get(arg1) -} - -var _wrap_delete_SimpleReturnClass unsafe.Pointer - -func _swig_wrap_delete_SimpleReturnClass(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_SimpleReturnClass, _swig_p) - return -} - -func DeleteSimpleReturnClass(arg1 SimpleReturnClass) { - _swig_wrap_delete_SimpleReturnClass(arg1.Swigcptr()) -} - -type SimpleReturnClass interface { - Swigcptr() uintptr - SwigIsSimpleReturnClass() - Get() (_swig_ret int) -} - -type SwigcptrSimpleClassFail uintptr - -func (p SwigcptrSimpleClassFail) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrSimpleClassFail) SwigIsSimpleClassFail() { -} - -var _wrap_new_SimpleClassFail unsafe.Pointer - -func _swig_wrap_new_SimpleClassFail() (base SwigcptrSimpleClassFail) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_SimpleClassFail, _swig_p) - return -} - -func NewSimpleClassFail() (_swig_ret SimpleClassFail) { - return _swig_wrap_new_SimpleClassFail() -} - -var _wrap_SimpleClassFail_getInner unsafe.Pointer - -func _swig_wrap_SimpleClassFail_getInner(base SwigcptrSimpleClassFail) (_ SwigcptrSimpleReturnClass) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_SimpleClassFail_getInner, _swig_p) - return -} - -func (arg1 SwigcptrSimpleClassFail) GetInner() (_swig_ret SimpleReturnClass) { - return _swig_wrap_SimpleClassFail_getInner(arg1) -} - -var _wrap_SimpleClassFail_implementMe unsafe.Pointer - -func _swig_wrap_SimpleClassFail_implementMe(base SwigcptrSimpleClassFail) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_SimpleClassFail_implementMe, _swig_p) - return -} - -func (arg1 SwigcptrSimpleClassFail) ImplementMe() (_swig_ret int) { - return _swig_wrap_SimpleClassFail_implementMe(arg1) -} - -var _wrap_delete_SimpleClassFail unsafe.Pointer - -func _swig_wrap_delete_SimpleClassFail(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_SimpleClassFail, _swig_p) - return -} - -func DeleteSimpleClassFail(arg1 SimpleClassFail) { - _swig_wrap_delete_SimpleClassFail(arg1.Swigcptr()) -} - -func (p SwigcptrSimpleClassFail) SwigIsSimpleVirtual() { -} - -func (p SwigcptrSimpleClassFail) SwigGetSimpleVirtual() SimpleVirtual { - return SwigcptrSimpleVirtual(p.Swigcptr()) -} - -type SimpleClassFail interface { - Swigcptr() uintptr - SwigIsSimpleClassFail() - GetInner() (_swig_ret SimpleReturnClass) - ImplementMe() (_swig_ret int) - SwigIsSimpleVirtual() - SwigGetSimpleVirtual() SimpleVirtual -} - -type SwigcptrSimpleClassWork uintptr - -func (p SwigcptrSimpleClassWork) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrSimpleClassWork) SwigIsSimpleClassWork() { -} - -var _wrap_new_SimpleClassWork unsafe.Pointer - -func _swig_wrap_new_SimpleClassWork() (base SwigcptrSimpleClassWork) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_SimpleClassWork, _swig_p) - return -} - -func NewSimpleClassWork() (_swig_ret SimpleClassWork) { - return _swig_wrap_new_SimpleClassWork() -} - -var _wrap_SimpleClassWork_getInner unsafe.Pointer - -func _swig_wrap_SimpleClassWork_getInner(base SwigcptrSimpleClassWork) (_ SwigcptrSimpleReturnClass) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_SimpleClassWork_getInner, _swig_p) - return -} - -func (arg1 SwigcptrSimpleClassWork) GetInner() (_swig_ret SimpleReturnClass) { - return _swig_wrap_SimpleClassWork_getInner(arg1) -} - -var _wrap_SimpleClassWork_implementMe unsafe.Pointer - -func _swig_wrap_SimpleClassWork_implementMe(base SwigcptrSimpleClassWork) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_SimpleClassWork_implementMe, _swig_p) - return -} - -func (arg1 SwigcptrSimpleClassWork) ImplementMe() (_swig_ret int) { - return _swig_wrap_SimpleClassWork_implementMe(arg1) -} - -var _wrap_delete_SimpleClassWork unsafe.Pointer - -func _swig_wrap_delete_SimpleClassWork(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_SimpleClassWork, _swig_p) - return -} - -func DeleteSimpleClassWork(arg1 SimpleClassWork) { - _swig_wrap_delete_SimpleClassWork(arg1.Swigcptr()) -} - -var _wrap_SimpleClassWork_dummy unsafe.Pointer - -func _swig_wrap_SimpleClassWork_dummy(base SwigcptrSimpleClassWork) (_ int) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_SimpleClassWork_dummy, _swig_p) - return -} - -func (_swig_base SwigcptrSimpleClassWork) Dummy() (_swig_ret int) { - return _swig_wrap_SimpleClassWork_dummy(_swig_base) -} - -func (p SwigcptrSimpleClassWork) SwigIsSimpleNonVirtual() { -} - -func (p SwigcptrSimpleClassWork) SwigGetSimpleNonVirtual() SimpleNonVirtual { - return SwigcptrSimpleNonVirtual(p.Swigcptr()) -} - -type SimpleClassWork interface { - Swigcptr() uintptr - SwigIsSimpleClassWork() - GetInner() (_swig_ret SimpleReturnClass) - ImplementMe() (_swig_ret int) - Dummy() (_swig_ret int) - SwigIsSimpleNonVirtual() - SwigGetSimpleNonVirtual() SimpleNonVirtual -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/voidtest.go b/Examples/test-suite/go/voidtest.go deleted file mode 100644 index abc392d45..000000000 --- a/Examples/test-suite/go/voidtest.go +++ /dev/null @@ -1,155 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../voidtest.i - -package voidtest - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -var _wrap_globalfunc unsafe.Pointer - -func _swig_wrap_globalfunc() { - var _swig_p uintptr - _cgo_runtime_cgocall(_wrap_globalfunc, _swig_p) - return -} - -func Globalfunc() { - _swig_wrap_globalfunc() -} - -type SwigcptrFoo uintptr - -func (p SwigcptrFoo) Swigcptr() uintptr { - return (uintptr)(p) -} - -func (p SwigcptrFoo) SwigIsFoo() { -} - -var _wrap_new_Foo unsafe.Pointer - -func _swig_wrap_new_Foo() (base SwigcptrFoo) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_new_Foo, _swig_p) - return -} - -func NewFoo() (_swig_ret Foo) { - return _swig_wrap_new_Foo() -} - -var _wrap_Foo_memberfunc unsafe.Pointer - -func _swig_wrap_Foo_memberfunc(base SwigcptrFoo) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_Foo_memberfunc, _swig_p) - return -} - -func (arg1 SwigcptrFoo) Memberfunc() { - _swig_wrap_Foo_memberfunc(arg1) -} - -var _wrap_Foo_staticmemberfunc unsafe.Pointer - -func _swig_wrap_Foo_staticmemberfunc() { - var _swig_p uintptr - _cgo_runtime_cgocall(_wrap_Foo_staticmemberfunc, _swig_p) - return -} - -func FooStaticmemberfunc() { - _swig_wrap_Foo_staticmemberfunc() -} - -var _wrap_delete_Foo unsafe.Pointer - -func _swig_wrap_delete_Foo(base uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_delete_Foo, _swig_p) - return -} - -func DeleteFoo(arg1 Foo) { - _swig_wrap_delete_Foo(arg1.Swigcptr()) -} - -type Foo interface { - Swigcptr() uintptr - SwigIsFoo() - Memberfunc() -} - -var _wrap_vfunc1 unsafe.Pointer - -func Vfunc1(arg1 uintptr) (_swig_ret uintptr) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_vfunc1, _swig_p) - return -} -var _wrap_vfunc2 unsafe.Pointer - -func _swig_wrap_vfunc2(base uintptr) (_ uintptr) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_vfunc2, _swig_p) - return -} - -func Vfunc2(arg1 Foo) (_swig_ret uintptr) { - return _swig_wrap_vfunc2(arg1.Swigcptr()) -} - -var _wrap_vfunc3 unsafe.Pointer - -func _swig_wrap_vfunc3(base uintptr) (_ SwigcptrFoo) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_vfunc3, _swig_p) - return -} - -func Vfunc3(arg1 uintptr) (_swig_ret Foo) { - return _swig_wrap_vfunc3(arg1) -} - -var _wrap_vfunc4 unsafe.Pointer - -func _swig_wrap_vfunc4(base uintptr) (_ SwigcptrFoo) { - _swig_p := uintptr(unsafe.Pointer(&base)) - _cgo_runtime_cgocall(_wrap_vfunc4, _swig_p) - return -} - -func Vfunc4(arg1 Foo) (_swig_ret Foo) { - return _swig_wrap_vfunc4(arg1.Swigcptr()) -} - - -type SwigcptrVoid uintptr -type Void interface { - Swigcptr() uintptr; -} -func (p SwigcptrVoid) Swigcptr() uintptr { - return uintptr(p) -} - diff --git a/Examples/test-suite/go/voidtest_runme b/Examples/test-suite/go/voidtest_runme deleted file mode 100755 index 6b00a71c3..000000000 Binary files a/Examples/test-suite/go/voidtest_runme and /dev/null differ diff --git a/Examples/test-suite/go/wallkw.go b/Examples/test-suite/go/wallkw.go deleted file mode 100644 index 37fcd8e98..000000000 --- a/Examples/test-suite/go/wallkw.go +++ /dev/null @@ -1,64 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../wallkw.i - -package wallkw - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -var _wrap_c_clone unsafe.Pointer - -func C_clone() (_swig_ret string) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_c_clone, _swig_p) - return -} -var _wrap__delegate unsafe.Pointer - -func X_delegate() (_swig_ret string) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap__delegate, _swig_p) - return -} -var _wrap__pass unsafe.Pointer - -func X_pass() (_swig_ret string) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap__pass, _swig_p) - return -} -var _wrap__alias unsafe.Pointer - -func X_alias() (_swig_ret string) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap__alias, _swig_p) - return -} -var _wrap_C_rescue unsafe.Pointer - -func C_rescue() (_swig_ret string) { - _swig_p := uintptr(unsafe.Pointer(&_swig_ret)) - _cgo_runtime_cgocall(_wrap_C_rescue, _swig_p) - return -} - diff --git a/Examples/test-suite/go/wrapmacro.go b/Examples/test-suite/go/wrapmacro.go deleted file mode 100644 index dd3b03f95..000000000 --- a/Examples/test-suite/go/wrapmacro.go +++ /dev/null @@ -1,68 +0,0 @@ -/* ---------------------------------------------------------------------------- - * This file was automatically generated by SWIG (http://www.swig.org). - * Version 3.0.3 - * - * This file is not intended to be easily readable and contains a number of - * coding conventions designed to improve portability and efficiency. Do not make - * changes to this file unless you know what you are doing--modify the SWIG - * interface file instead. - * ----------------------------------------------------------------------------- */ - -// source: ./../wrapmacro.i - -package wrapmacro - -import "unsafe" -import _ "runtime/cgo" - -var _cgo_runtime_cgocall func(unsafe.Pointer, uintptr) - - - -type _ unsafe.Pointer - - - -type _swig_fnptr *byte -type _swig_memberptr *byte - -var _wrap_GUINT16_SWAP_LE_BE_CONSTANT unsafe.Pointer - -func GUINT16_SWAP_LE_BE_CONSTANT(arg1 uint16) (_swig_ret uint16) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_GUINT16_SWAP_LE_BE_CONSTANT, _swig_p) - return -} -var _wrap_maximum__SWIG_0 unsafe.Pointer - -func Maximum__SWIG_0(arg1 int64, arg2 int64) (_swig_ret int64) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_maximum__SWIG_0, _swig_p) - return -} -var _wrap_maximum__SWIG_1 unsafe.Pointer - -func Maximum__SWIG_1(arg1 float64, arg2 float64) (_swig_ret float64) { - _swig_p := uintptr(unsafe.Pointer(&arg1)) - _cgo_runtime_cgocall(_wrap_maximum__SWIG_1, _swig_p) - return -} -func Maximum(a ...interface{}) interface{} { - argc := len(a) - if argc == 2 { - if _, ok := a[0].(int64); !ok { - goto check_1 - } - if _, ok := a[1].(int64); !ok { - goto check_1 - } - return Maximum__SWIG_0(a[0].(int64), a[1].(int64)) - } -check_1: - if argc == 2 { - return Maximum__SWIG_1(a[0].(float64), a[1].(float64)) - } - panic("No match for overloaded function call") -} - - diff --git a/Examples/test-suite/go/wrapmacro_runme b/Examples/test-suite/go/wrapmacro_runme deleted file mode 100755 index c6499ab30..000000000 Binary files a/Examples/test-suite/go/wrapmacro_runme and /dev/null differ diff --git a/Examples/test-suite/overload_polymorphic.i~ b/Examples/test-suite/overload_polymorphic.i~ deleted file mode 100644 index 5581e2e47..000000000 --- a/Examples/test-suite/overload_polymorphic.i~ +++ /dev/null @@ -1,25 +0,0 @@ -%module overload_polymorphic - -#ifndef SWIG_NO_OVERLOAD - -%inline %{ - -class Base { -public: - Base(){} - virtual ~Base(){} -}; - -class Derived : public Base { -public: - Derived(){} - virtual ~Derived(){} -}; - - - -void test(Base* base){} -void test(int hello){} - -%} -#endif diff --git a/Examples/test-suite/overload_rename.i~ b/Examples/test-suite/overload_rename.i~ deleted file mode 100644 index 6568c7681..000000000 --- a/Examples/test-suite/overload_rename.i~ +++ /dev/null @@ -1,30 +0,0 @@ -%module overload_rename - - -%inline %{ - -class Base { -public: - Base(){} - virtual void Print(){printf("I'm Base.\n");} - virtual ~Base(){} -}; - -class Derived : public Base { -public: - Derived(){} - void Print(){printf("I'm Derived.\n");} - virtual ~Derived(){} -}; - - - -void test(Base* base){ - base->Print(); -} -void test(int hello){ - printf("%d\n", hello); -} - -%} - diff --git a/Source/Modules/go.cxx~ b/Source/Modules/go.cxx~ deleted file mode 100644 index c9910ab05..000000000 --- a/Source/Modules/go.cxx~ +++ /dev/null @@ -1,5385 +0,0 @@ -/* ----------------------------------------------------------------------------- - * See the LICENSE file for information on copyright, usage and redistribution - * of SWIG, and the README file for authors - http://www.swig.org/release.html. - * - * go.cxx - * - * Go language module for SWIG. - * ----------------------------------------------------------------------------- */ - -#include "swigmod.h" -#include "cparse.h" -#include - -class GO:public Language { - static const char *const usage; - - // Go package name. - String *package; - // SWIG module name. - String *module; - // Flag for generating gccgo output. - bool gccgo_flag; - // Prefix to use with gccgo. - String *go_prefix; - // -fgo-prefix option. - String *prefix_option; - // -fgo-pkgpath option. - String *pkgpath_option; - // Whether to use a shared library. - bool use_shlib; - // Name of shared library to import. - String *soname; - // Size in bits of the Go type "int". 0 if not specified. - int intgo_type_size; - - /* Output files */ - File *f_c_begin; - File *f_go_begin; - File *f_gc_begin; - - /* Output fragments */ - File *f_c_runtime; - File *f_c_header; - File *f_c_wrappers; - File *f_c_init; - File *f_c_directors; - File *f_c_directors_h; - File *f_go_imports; - File *f_go_runtime; - File *f_go_header; - File *f_go_wrappers; - File *f_gc_runtime; - File *f_gc_header; - File *f_gc_wrappers; - - // True if we imported a module. - bool saw_import; - // If not NULL, name of import package being processed. - String *imported_package; - // Build interface methods while handling a class. This is only - // non-NULL when we are handling methods. - String *interfaces; - // The class node while handling a class. This is only non-NULL - // when we are handling methods. - Node *class_node; - // The class name while handling a class. This is only non-NULL - // when we are handling methods. This is the name of the class as - // SWIG sees it. - String *class_name; - // The receiver name while handling a class. This is only non-NULL - // when we are handling methods. This is the name of the class - // as run through goCPointerType. - String *class_receiver; - // A hash table of method names that we have seen when processing a - // class. This lets us detect base class methods that we don't want - // to use. - Hash *class_methods; - // True when we are generating the wrapper functions for a variable. - bool making_variable_wrappers; - // True when working with a static member function. - bool is_static_member_function; - // A hash table of enum types that we have seen but which may not have - // been defined. The index is a SwigType. - Hash *undefined_enum_types; - // A hash table of types that we have seen but which may not have - // been defined. The index is a SwigType. - Hash *undefined_types; - // A hash table of classes which were defined. The index is a Go - // type name. - Hash *defined_types; - // A hash table of all the go_imports already imported. The index is a full - // import name e.g. '"runtime"' or '_ "runtime/cgo"' or 'sc "syscall"'. - Hash *go_imports; - -public: - GO():package(NULL), - module(NULL), - gccgo_flag(false), - go_prefix(NULL), - prefix_option(NULL), - pkgpath_option(NULL), - use_shlib(false), - soname(NULL), - intgo_type_size(0), - f_c_begin(NULL), - f_go_begin(NULL), - f_gc_begin(NULL), - f_c_runtime(NULL), - f_c_header(NULL), - f_c_wrappers(NULL), - f_c_init(NULL), - f_c_directors(NULL), - f_c_directors_h(NULL), - f_go_imports(NULL), - f_go_runtime(NULL), - f_go_header(NULL), - f_go_wrappers(NULL), - f_gc_runtime(NULL), - f_gc_header(NULL), - f_gc_wrappers(NULL), - saw_import(false), - imported_package(NULL), - interfaces(NULL), - class_node(NULL), - class_name(NULL), - class_receiver(NULL), - class_methods(NULL), - making_variable_wrappers(false), - is_static_member_function(false), - undefined_enum_types(NULL), - undefined_types(NULL), - defined_types(NULL), - go_imports(NULL) { - director_multiple_inheritance = 1; - director_language = 1; - director_prot_ctor_code = NewString("_swig_gopanic(\"accessing abstract class or protected constructor\");"); - } - -private: - /* ------------------------------------------------------------ - * main() - * ------------------------------------------------------------ */ - virtual void main(int argc, char *argv[]) { - - SWIG_library_directory("go"); - bool display_help = false; - - // Process command line options. - for (int i = 1; i < argc; i++) { - if (argv[i]) { - if (strcmp(argv[i], "-package") == 0) { - if (argv[i + 1]) { - package = NewString(argv[i + 1]); - Swig_mark_arg(i); - Swig_mark_arg(i + 1); - i++; - } else { - Swig_arg_error(); - } - } else if (strcmp(argv[i], "-gccgo") == 0) { - Swig_mark_arg(i); - gccgo_flag = true; - } else if (strcmp(argv[i], "-go-prefix") == 0) { - if (argv[i + 1]) { - prefix_option = NewString(argv[i + 1]); - Swig_mark_arg(i); - Swig_mark_arg(i + 1); - i++; - } else { - Swig_arg_error(); - } - } else if (strcmp(argv[i], "-go-pkgpath") == 0) { - if (argv[i + 1]) { - pkgpath_option = NewString(argv[i + 1]); - Swig_mark_arg(i); - Swig_mark_arg(i + 1); - i++; - } else { - Swig_arg_error(); - } - } else if (strcmp(argv[i], "-use-shlib") == 0) { - Swig_mark_arg(i); - use_shlib = true; - } else if (strcmp(argv[i], "-soname") == 0) { - if (argv[i + 1]) { - soname = NewString(argv[i + 1]); - Swig_mark_arg(i); - Swig_mark_arg(i + 1); - i++; - } else { - Swig_arg_error(); - } - } else if (strcmp(argv[i], "-longsize") == 0) { - // Ignore for backward compatibility. - if (argv[i + 1]) { - Swig_mark_arg(i); - Swig_mark_arg(i + 1); - ++i; - } else { - Swig_arg_error(); - } - } else if (strcmp(argv[i], "-intgosize") == 0) { - if (argv[i + 1]) { - intgo_type_size = atoi(argv[i + 1]); - if (intgo_type_size != 32 && intgo_type_size != 64) { - Printf(stderr, "-intgosize not 32 or 64\n"); - Swig_arg_error(); - } - Swig_mark_arg(i); - Swig_mark_arg(i + 1); - ++i; - } else { - Swig_arg_error(); - } - } else if (strcmp(argv[i], "-help") == 0) { - display_help = true; - Printf(stdout, "%s\n", usage); - } - } - } - - if (gccgo_flag && !pkgpath_option && !prefix_option) { - prefix_option = NewString("go"); - } - - // Add preprocessor symbol to parser. - Preprocessor_define("SWIGGO 1", 0); - - if (gccgo_flag) { - Preprocessor_define("SWIGGO_GCCGO 1", 0); - } - - // This test may be removed in the future, when we can assume that - // everybody has upgraded to Go 1.1. The code below is prepared - // for this test to simply be taken out. - if (intgo_type_size == 0 && !display_help) { - Printf(stderr, "SWIG -go: -intgosize option required but not specified\n"); - SWIG_exit(EXIT_FAILURE); - } - - if (intgo_type_size == 32) { - Preprocessor_define("SWIGGO_INTGO_SIZE 32", 0); - } else if (intgo_type_size == 64) { - Preprocessor_define("SWIGGO_INTGO_SIZE 64", 0); - } else { - Preprocessor_define("SWIGGO_INTGO_SIZE 0", 0); - } - - // Add typemap definitions. - SWIG_typemap_lang("go"); - SWIG_config_file("go.swg"); - - allow_overloading(); - } - - /* --------------------------------------------------------------------- - * top() - * - * For 6g/8g, we are going to create the following files: - * - * 1) A .c or .cxx file compiled with gcc. This file will contain - * function wrappers. Each wrapper will take a pointer to a - * struct holding the arguments, unpack them, and call the real - * function. - * - * 2) A .go file which defines the Go form of all types, and which - * defines Go function wrappers. Each wrapper will call the C - * function wrapper in the second file. - * - * 3) A .c file compiled with 6c/8c. This file will define - * Go-callable C function wrappers. Each wrapper will use - * cgocall to call the function wrappers in the first file. - * - * When generating code for gccgo, we don't need the third file, and - * the function wrappers in the first file have a different form. - * - * --------------------------------------------------------------------- */ - - virtual int top(Node *n) { - Node *optionsnode = Getattr(Getattr(n, "module"), "options"); - if (optionsnode) { - if (Getattr(optionsnode, "directors")) { - allow_directors(); - } - if (Getattr(optionsnode, "dirprot")) { - allow_dirprot(); - } - allow_allprotected(GetFlag(optionsnode, "allprotected")); - } - - module = Getattr(n, "name"); - if (!package) { - package = Copy(module); - } - if (!soname && use_shlib) { - soname = Copy(package); - Append(soname, ".so"); - } - - if (gccgo_flag) { - String *pref; - if (pkgpath_option) { - pref = pkgpath_option; - } else { - pref = prefix_option; - } - go_prefix = NewString(""); - for (char *p = Char(pref); *p != '\0'; p++) { - if ((*p >= 'A' && *p <= 'Z') || (*p >= 'a' && *p <= 'z') || (*p >= '0' && *p <= '9') || *p == '.' || *p == '$') { - Putc(*p, go_prefix); - } else { - Putc('_', go_prefix); - } - } - if (!pkgpath_option) { - Append(go_prefix, "."); - Append(go_prefix, package); - } - } - - // Get filenames. - - String *swig_filename = Getattr(n, "infile"); - String *c_filename = Getattr(n, "outfile"); - String *c_filename_h = Getattr(n, "outfile_h"); - - String *go_filename = NewString(""); - Printf(go_filename, "%s%s.go", SWIG_output_directory(), module); - - String *gc_filename = NULL; - if (!gccgo_flag) { - gc_filename = NewString(""); - Printf(gc_filename, "%s%s_gc.c", SWIG_output_directory(), module); - } - - // Open files. - - f_c_begin = NewFile(c_filename, "w", SWIG_output_files()); - if (!f_c_begin) { - FileErrorDisplay(c_filename); - SWIG_exit(EXIT_FAILURE); - } - - if (directorsEnabled()) { - if (!c_filename_h) { - Printf(stderr, "Unable to determine outfile_h\n"); - SWIG_exit(EXIT_FAILURE); - } - f_c_directors_h = NewFile(c_filename_h, "w", SWIG_output_files()); - if (!f_c_directors_h) { - FileErrorDisplay(c_filename_h); - SWIG_exit(EXIT_FAILURE); - } - } - - f_go_begin = NewFile(go_filename, "w", SWIG_output_files()); - if (!f_go_begin) { - FileErrorDisplay(go_filename); - SWIG_exit(EXIT_FAILURE); - } - - if (!gccgo_flag) { - f_gc_begin = NewFile(gc_filename, "w", SWIG_output_files()); - if (!f_gc_begin) { - FileErrorDisplay(gc_filename); - SWIG_exit(EXIT_FAILURE); - } - } - - f_c_runtime = NewString(""); - f_c_header = NewString(""); - f_c_wrappers = NewString(""); - f_c_init = NewString(""); - f_c_directors = NewString(""); - f_go_imports = NewString(""); - f_go_runtime = NewString(""); - f_go_header = NewString(""); - f_go_wrappers = NewString(""); - if (!gccgo_flag) { - f_gc_runtime = NewString(""); - f_gc_header = NewString(""); - f_gc_wrappers = NewString(""); - } - - Swig_register_filebyname("begin", f_c_begin); - Swig_register_filebyname("runtime", f_c_runtime); - Swig_register_filebyname("header", f_c_header); - Swig_register_filebyname("wrapper", f_c_wrappers); - Swig_register_filebyname("init", f_c_init); - Swig_register_filebyname("director", f_c_directors); - Swig_register_filebyname("director_h", f_c_directors_h); - Swig_register_filebyname("go_begin", f_go_begin); - Swig_register_filebyname("go_imports", f_go_imports); - Swig_register_filebyname("go_runtime", f_go_runtime); - Swig_register_filebyname("go_header", f_go_header); - Swig_register_filebyname("go_wrapper", f_go_wrappers); - if (!gccgo_flag) { - Swig_register_filebyname("gc_begin", f_gc_begin); - Swig_register_filebyname("gc_runtime", f_gc_runtime); - Swig_register_filebyname("gc_header", f_gc_header); - Swig_register_filebyname("gc_wrapper", f_gc_wrappers); - } - - Swig_banner(f_c_begin); - if (CPlusPlus) { - Printf(f_c_begin, "\n// source: %s\n\n", swig_filename); - } else { - Printf(f_c_begin, "\n/* source: %s */\n\n", swig_filename); - } - - Printf(f_c_runtime, "#define SWIGMODULE %s\n", module); - if (gccgo_flag) { - Printf(f_c_runtime, "#define SWIGGO_PREFIX %s\n", go_prefix); - } - - if (directorsEnabled()) { - Printf(f_c_runtime, "#define SWIG_DIRECTORS\n"); - - Swig_banner(f_c_directors_h); - Printf(f_c_directors_h, "\n// source: %s\n\n", swig_filename); - - Printf(f_c_directors_h, "#ifndef SWIG_%s_WRAP_H_\n", module); - Printf(f_c_directors_h, "#define SWIG_%s_WRAP_H_\n\n", module); - - Printf(f_c_directors, "\n// C++ director class methods.\n"); - String *filename = Swig_file_filename(c_filename_h); - Printf(f_c_directors, "#include \"%s\"\n\n", filename); - Delete(filename); - } - - Swig_banner(f_go_begin); - Printf(f_go_begin, "\n// source: %s\n", swig_filename); - - if (!gccgo_flag && soname) { - Swig_banner(f_gc_begin); - Printf(f_gc_begin, "\n/* source: %s */\n\n", swig_filename); - Printf(f_gc_begin, "\n/* This file should be compiled with 6c/8c. */\n"); - Printf(f_gc_begin, "#pragma dynimport _ _ \"%s\"\n", soname); - } - - // Output module initialization code. - - Printf(f_go_begin, "\npackage %s\n\n", package); - - if (gccgo_flag) { - Printf(f_go_runtime, "func SwigCgocall()\n"); - Printf(f_go_runtime, "func SwigCgocallDone()\n"); - Printf(f_go_runtime, "func SwigCgocallBack()\n"); - Printf(f_go_runtime, "func SwigCgocallBackDone()\n\n"); - } - - // All the C++ wrappers should be extern "C". - - Printv(f_c_wrappers, "#ifdef __cplusplus\n", "extern \"C\" {\n", "#endif\n\n", NULL); - - // Set up the hash table for types not defined by SWIG. - - undefined_enum_types = NewHash(); - undefined_types = NewHash(); - defined_types = NewHash(); - go_imports = NewHash(); - - // Emit code. - - Language::top(n); - - Delete(go_imports); - - // Write out definitions for the types not defined by SWIG. - - if (Len(undefined_enum_types) > 0) - Printv(f_go_wrappers, "\n", NULL); - for (Iterator p = First(undefined_enum_types); p.key; p = Next(p)) { - String *name = p.item; - Printv(f_go_wrappers, "type ", name, " int\n", NULL); - } - - Printv(f_go_wrappers, "\n", NULL); - for (Iterator p = First(undefined_types); p.key; p = Next(p)) { - String *ty = goType(NULL, p.key); - if (!Getattr(defined_types, ty)) { - String *cp = goCPointerType(p.key, false); - if (!Getattr(defined_types, cp)) { - Printv(f_go_wrappers, "type ", cp, " uintptr\n", NULL); - Printv(f_go_wrappers, "type ", ty, " interface {\n", NULL); - Printv(f_go_wrappers, "\tSwigcptr() uintptr;\n", NULL); - Printv(f_go_wrappers, "}\n", NULL); - Printv(f_go_wrappers, "func (p ", cp, ") Swigcptr() uintptr {\n", NULL); - Printv(f_go_wrappers, "\treturn uintptr(p)\n", NULL); - Printv(f_go_wrappers, "}\n\n", NULL); - } - Delete(cp); - } - Delete(ty); - } - Delete(undefined_enum_types); - Delete(undefined_types); - Delete(defined_types); - - /* Write and cleanup */ - - Dump(f_c_header, f_c_runtime); - - if (directorsEnabled()) { - Printf(f_c_directors_h, "#endif\n"); - Delete(f_c_directors_h); - f_c_directors_h = NULL; - - Dump(f_c_directors, f_c_runtime); - Delete(f_c_directors); - f_c_directors = NULL; - } - - // End the extern "C". - Printv(f_c_wrappers, "#ifdef __cplusplus\n", "}\n", "#endif\n\n", NULL); - - Dump(f_c_runtime, f_c_begin); - Dump(f_c_wrappers, f_c_begin); - Dump(f_c_init, f_c_begin); - Dump(f_go_imports, f_go_begin); - Dump(f_go_header, f_go_begin); - Dump(f_go_runtime, f_go_begin); - Dump(f_go_wrappers, f_go_begin); - if (!gccgo_flag) { - Dump(f_gc_header, f_gc_begin); - Dump(f_gc_runtime, f_gc_begin); - Dump(f_gc_wrappers, f_gc_begin); - } - - Delete(f_c_runtime); - Delete(f_c_header); - Delete(f_c_wrappers); - Delete(f_c_init); - Delete(f_go_imports); - Delete(f_go_runtime); - Delete(f_go_header); - Delete(f_go_wrappers); - if (!gccgo_flag) { - Delete(f_gc_runtime); - Delete(f_gc_header); - Delete(f_gc_wrappers); - } - - Delete(f_c_begin); - Delete(f_go_begin); - if (!gccgo_flag) { - Delete(f_gc_begin); - } - - return SWIG_OK; - } - - /* ------------------------------------------------------------ - * importDirective() - * - * Handle a SWIG import statement by generating a Go import - * statement. - * ------------------------------------------------------------ */ - - virtual int importDirective(Node *n) { - String *hold_import = imported_package; - String *modname = Getattr(n, "module"); - if (modname) { - if (!Getattr(go_imports, modname)) { - Setattr(go_imports, modname, modname); - Printv(f_go_imports, "import \"", modname, "\"\n", NULL); - } - imported_package = modname; - saw_import = true; - } - int r = Language::importDirective(n); - imported_package = hold_import; - return r; - } - - /* ---------------------------------------------------------------------- - * Language::insertDirective() - * - * If the section is go_imports, store them for later. - * ---------------------------------------------------------------------- */ - virtual int insertDirective(Node *n) { - char *section = Char(Getattr(n, "section")); - if ((ImportMode && !Getattr(n, "generated")) || - !section || (strcmp(section, "go_imports") != 0)) { - return Language::insertDirective(n); - } - - char *code = Char(Getattr(n, "code")); - char *pch = strtok(code, ","); - while (pch != NULL) { - // Do not import same thing more than once. - if (!Getattr(go_imports, pch)) { - Setattr(go_imports, pch, pch); - Printv(f_go_imports, "import ", pch, "\n", NULL); - } - pch = strtok(NULL, ","); - } - return SWIG_OK; - } - - /* ---------------------------------------------------------------------- - * functionWrapper() - * - * Implement a function. - * ---------------------------------------------------------------------- */ - - virtual int functionWrapper(Node *n) { - if (GetFlag(n, "feature:ignore")) { - return SWIG_OK; - } - - // We don't need explicit calls. - if (GetFlag(n, "explicitcall")) { - return SWIG_OK; - } - - String *name = Getattr(n, "sym:name"); - String *nodetype = Getattr(n, "nodeType"); - bool is_static = is_static_member_function || isStatic(n); - bool is_friend = isFriend(n); - bool is_ctor_dtor = false; - - SwigType *result = Getattr(n, "type"); - - // For some reason SWIG changs the "type" value during the call to - // functionWrapper. We need to remember the type for possible - // overload processing. - Setattr(n, "go:type", Copy(result)); - - String *go_name; - - String *r1 = NULL; - if (making_variable_wrappers) { - // Change the name of the variable setter and getter functions - // to be more Go like. - - bool is_set = Strcmp(Char(name) + Len(name) - 4, "_set") == 0; - assert(is_set || Strcmp(Char(name) + Len(name) - 4, "_get") == 0); - - // Start with Set or Get. - go_name = NewString(is_set ? "Set" : "Get"); - - // If this is a static variable, put in the class name, - // capitalized. - if (is_static && class_name) { - String *ccn = exportedName(class_name); - Append(go_name, ccn); - Delete(ccn); - } - - // Add the rest of the name, capitalized, dropping the _set or - // _get. - String *c1 = removeClassname(name); - String *c2 = exportedName(c1); - char *p = Char(c2); - int len = Len(p); - for (int i = 0; i < len - 4; ++i) { - Putc(p[i], go_name); - } - Delete(c2); - Delete(c1); - - if (!checkIgnoredParameters(n, go_name)) { - Delete(go_name); - return SWIG_NOWRAP; - } - } else if (Cmp(nodetype, "constructor") == 0) { - is_ctor_dtor = true; - - // Change the name of a constructor to be more Go like. Change - // new_ to New, and capitalize the class name. - assert(Strncmp(name, "new_", 4) == 0); - String *c1 = NewString(Char(name) + 4); - String *c2 = exportedName(c1); - go_name = NewString("New"); - Append(go_name, c2); - Delete(c2); - Delete(c1); - - if (Swig_methodclass(n) && Swig_directorclass(n) - && Strcmp(Char(Getattr(n, "wrap:action")), director_prot_ctor_code) != 0) { - // The core SWIG code skips the first parameter when - // generating the $nondirector_new string. Recreate the - // action in this case. But don't it if we are using the - // special code for an abstract class. - String *call = Swig_cppconstructor_call(getClassType(), - Getattr(n, "parms")); - SwigType *type = Copy(getClassType()); - SwigType_add_pointer(type); - String *cres = Swig_cresult(type, Swig_cresult_name(), call); - Setattr(n, "wrap:action", cres); - } - } else if (Cmp(nodetype, "destructor") == 0) { - // No need to emit protected destructors. - if (!is_public(n)) { - return SWIG_OK; - } - - is_ctor_dtor = true; - - // Change the name of a destructor to be more Go like. Change - // delete_ to Delete and capitalize the class name. - assert(Strncmp(name, "delete_", 7) == 0); - String *c1 = NewString(Char(name) + 7); - String *c2 = exportedName(c1); - go_name = NewString("Delete"); - Append(go_name, c2); - Delete(c2); - Delete(c1); - - result = NewString("void"); - r1 = result; - } else { - if (!checkFunctionVisibility(n, NULL)) { - return SWIG_OK; - } - - go_name = buildGoName(name, is_static, is_friend); - - if (!checkIgnoredParameters(n, go_name)) { - Delete(go_name); - return SWIG_NOWRAP; - } - } - - String *overname = NULL; - if (Getattr(n, "sym:overloaded")) { - overname = Getattr(n, "sym:overname"); - } else { - String *scope; - if (!class_name || is_static || is_ctor_dtor) { - scope = NULL; - } else { - scope = NewString("swiggoscope."); - Append(scope, class_name); - } - if (!checkNameConflict(go_name, n, scope)) { - Delete(go_name); - return SWIG_NOWRAP; - } - } - - String *wname = Swig_name_wrapper(name); - if (overname) { - Append(wname, overname); - } - Setattr(n, "wrap:name", wname); - - ParmList *parms = Getattr(n, "parms"); - Setattr(n, "wrap:parms", parms); - - int r = makeWrappers(n, name, go_name, overname, wname, NULL, parms, result, is_static); - if (r != SWIG_OK) { - return r; - } - - if (Getattr(n, "sym:overloaded") && !Getattr(n, "sym:nextSibling")) { - String *scope ; - if (!class_name || is_static || is_ctor_dtor) { - scope = NULL; - } else { - scope = NewString("swiggoscope."); - Append(scope, class_name); - } - if (!checkNameConflict(go_name, n, scope)) { - Delete(go_name); - return SWIG_NOWRAP; - } - - String *receiver = class_receiver; - if (is_static || is_ctor_dtor) { - receiver = NULL; - } - r = makeDispatchFunction(n, go_name, receiver, is_static, NULL, false); - if (r != SWIG_OK) { - return r; - } - } - - Delete(wname); - Delete(go_name); - Delete(r1); - - return SWIG_OK; - } - - /* ---------------------------------------------------------------------- - * staticmemberfunctionHandler() - * - * For some reason the language code removes the "storage" attribute - * for a static function before calling functionWrapper, which means - * that we have no way of knowing whether a function is static or - * not. That makes no sense in the Go context. Here we note that a - * function is static. - * ---------------------------------------------------------------------- */ - - int staticmemberfunctionHandler(Node *n) { - assert(!is_static_member_function); - is_static_member_function = true; - int r = Language::staticmemberfunctionHandler(n); - is_static_member_function = false; - return r; - } - - /* ---------------------------------------------------------------------- - * makeWrappers() - * - * Write out the various function wrappers. - * n: The function we are emitting. - * name: The function name. - * go_name: The name of the function in Go. - * overname: The overload string for overloaded function. - * wname: The SWIG wrapped name--the name of the C function. - * base: A list of the names of base classes, in the case where this - * is is a vritual method not defined in the current class. - * parms: The parameters. - * result: The result type. - * is_static: Whether this is a static method or member. - * ---------------------------------------------------------------------- */ - - int makeWrappers(Node *n, String *name, String *go_name, String *overname, String *wname, List *base, ParmList *parms, SwigType *result, bool is_static) { - - assert(result); - - int r = goFunctionWrapper(n, name, go_name, overname, wname, base, parms, result, is_static); - if (r != SWIG_OK) { - return r; - } - - if (!gccgo_flag) { - r = gcFunctionWrapper(wname); - if (r != SWIG_OK) { - return r; - } - r = gccFunctionWrapper(n, base, wname, parms, result); - if (r != SWIG_OK) { - return r; - } - } else { - r = gccgoFunctionWrapper(n, base, wname, parms, result); - if (r != SWIG_OK) { - return r; - } - } - - if (class_methods) { - Setattr(class_methods, Getattr(n, "name"), NewString("")); - } - - return SWIG_OK; - } - - /* ---------------------------------------------------------------------- - * goFunctionWrapper() - * - * Write out a function wrapper in Go. When not implementing a - * method, the actual code is all in C; here we just declare the C - * function. When implementing a method, we have to call the C - * function, because it will have a different name. If base is not - * NULL, then we are being called to forward a virtual method to a - * base class. - * ---------------------------------------------------------------------- */ - - int goFunctionWrapper(Node *n, String *name, String *go_name, String *overname, String *wname, List *base, ParmList *parms, SwigType *result, bool is_static) { - Wrapper *dummy = NewWrapper(); - emit_attach_parmmaps(parms, dummy); - - Parm *p = parms; - int parm_count = emit_num_arguments(parms); - for (int i = 0; i < parm_count; ++i) { - p = getParm(p); - Swig_cparm_name(p, i); - p = nextParm(p); - } - - Swig_typemap_attach_parms("default", parms, dummy); - Swig_typemap_attach_parms("gotype", parms, dummy); - Swig_typemap_attach_parms("goin", parms, dummy); - Swig_typemap_attach_parms("goargout", parms, dummy); - Swig_typemap_attach_parms("imtype", parms, dummy); - - int required_count = emit_num_required(parms); - - String *receiver = class_receiver; - if (receiver && is_static) { - receiver = NULL; - } - - String *nodetype = Getattr(n, "nodeType"); - bool is_constructor = Cmp(nodetype, "constructor") == 0; - bool is_destructor = Cmp(nodetype, "destructor") == 0; - if (is_constructor || is_destructor) { - assert(class_receiver); - assert(!base); - receiver = NULL; - } - - String *goout = Swig_typemap_lookup("goout", n, "swig_r", NULL); - - bool add_to_interface = (interfaces && !is_constructor && !is_destructor && !is_static && !overname && checkFunctionVisibility(n, NULL)); - - bool needs_wrapper = (gccgo_flag || receiver || is_constructor || is_destructor || parm_count > required_count); - - bool has_goout = false; - if (goout) { - has_goout = true; - } - - // See whether any of the function parameters are represented by - // interface values. When calling the C++ code, we need to convert - // back to a uintptr. - p = parms; - for (int i = 0; i < parm_count; ++i) { - p = getParm(p); - String *ty = Getattr(p, "type"); - if (Getattr(p, "tmap:goargout")) { - has_goout = true; - needs_wrapper = true; - } else if (goTypeIsInterface(p, ty) || Getattr(p, "tmap:goin")) { - needs_wrapper = true; - } - p = nextParm(p); - } - if (goTypeIsInterface(n, result) || goout != NULL) { - needs_wrapper = true; - } - - if (!gccgo_flag) { - Printv(f_go_wrappers, "var ", wname, " unsafe.Pointer\n\n", NULL); - } - - // If this is a method, first declare the C function we will call. - // If we do not need a wrapper, then we will only be writing a - // declaration. - String *wrapper_name = NULL; - if (needs_wrapper) { - wrapper_name = buildGoWrapperName(name, overname); - - if (gccgo_flag) { - Printv(f_go_wrappers, "//extern ", go_prefix, "_", wname, "\n", NULL); - } - - bool arg = false; - Printv(f_go_wrappers, "func ", wrapper_name, "(", NULL); - if (parm_count > required_count) { - Printv(f_go_wrappers, argName(&arg), " int", NULL); - } - Parm *p = getParm(parms); - int i = 0; - if (is_destructor) { - if (parm_count > required_count) { - Printv(f_go_wrappers, ", ", NULL); - } - Printv(f_go_wrappers, argName(&arg), " uintptr", NULL); - ++i; - p = nextParm(p); - } else if (receiver && (base || !is_constructor)) { - if (parm_count > required_count) { - Printv(f_go_wrappers, ", ", NULL); - } - Printv(f_go_wrappers, argName(&arg), " ", receiver, NULL); - if (!base) { - ++i; - p = nextParm(p); - } - } - for (; i < parm_count; ++i) { - p = getParm(p); - if (i > 0 || (base && receiver) || parm_count > required_count) { - Printv(f_go_wrappers, ", ", NULL); - } - String *tm = goWrapperType(p, Getattr(p, "type"), false); - Printv(f_go_wrappers, argName(&arg), " ", tm, NULL); - Delete(tm); - p = nextParm(p); - } - Printv(f_go_wrappers, ")", NULL); - if (is_constructor) { - Printv(f_go_wrappers, " (", argName(&arg), " ", class_receiver, ")", NULL); - } else { - if (SwigType_type(result) != T_VOID) { - String *tm = goWrapperType(n, result, true); - Printv(f_go_wrappers, " (", argName(&arg), " ", tm, ")", NULL); - Delete(tm); - } - } - - if (!gccgo_flag) { - Printv(f_go_wrappers, " {\n", NULL); - if (arg) { - Printv(f_go_wrappers, "\t_swig_p := uintptr(unsafe.Pointer(&base))\n", NULL); - } else { - Printv(f_go_wrappers, "\tvar _swig_p uintptr\n", NULL); - } - Printv(f_go_wrappers, "\t_cgo_runtime_cgocall(", wname, ", _swig_p)\n", NULL); - Printv(f_go_wrappers, "\treturn\n", NULL); - Printv(f_go_wrappers, "}", NULL); - } - - Printv(f_go_wrappers, "\n\n", NULL); - } - - // Start defining the Go function. - - if (!needs_wrapper && gccgo_flag) { - Printv(f_go_wrappers, "//extern ", go_prefix, "_", wname, "\n", NULL); - } - - Printv(f_go_wrappers, "func ", NULL); - - p = parms; - int pi = 0; - - // Add the receiver if this is a method. - String *first = NULL; - if (receiver) { - Printv(f_go_wrappers, "(", NULL); - if (base && receiver) { - Printv(f_go_wrappers, "_swig_base", NULL); - if (first == NULL) { - first = NewString("_swig_base"); - } - } else { - Printv(f_go_wrappers, Getattr(p, "lname"), NULL); - if (first == NULL) { - first = Copy(Getattr(p, "lname")); - } - p = nextParm(p); - ++pi; - } - Printv(f_go_wrappers, " ", receiver, ") ", NULL); - } - - Printv(f_go_wrappers, go_name, NULL); - if (overname) { - Printv(f_go_wrappers, overname, NULL); - } - Printv(f_go_wrappers, "(", NULL); - - // If we are doing methods, add this function to the interface. - if (add_to_interface) { - Printv(interfaces, "\t", go_name, "(", NULL); - } - - // Write out the parameters to both the function definition and - // the interface. - - String *parm_print = NewString(""); - - for (; pi < parm_count; ++pi) { - p = getParm(p); - if (pi == 0 && is_destructor) { - String *cl = exportedName(class_name); - Printv(parm_print, Getattr(p, "lname"), " ", cl, NULL); - if (first == NULL) { - first = Copy(Getattr(p, "lname")); - } - Delete(cl); - } else { - if (pi > (receiver && !base ? 1 : 0)) { - Printv(parm_print, ", ", NULL); - } - if (pi >= required_count) { - Printv(parm_print, "_swig_args ...interface{}", NULL); - if (first == NULL) { - first = NewString("_swig_args"); - } - break; - } - Printv(parm_print, Getattr(p, "lname"), " ", NULL); - if (first == NULL) { - first = Copy(Getattr(p, "lname")); - } - String *tm = goType(p, Getattr(p, "type")); - Printv(parm_print, tm, NULL); - Delete(tm); - } - p = nextParm(p); - } - - Printv(parm_print, ")", NULL); - - // Write out the result type. - if (is_constructor) { - String *cl = exportedName(class_name); - Printv(parm_print, " (_swig_ret ", cl, ")", NULL); - if (first == NULL) { - first = NewString("_swig_ret"); - } - Delete(cl); - } else { - if (SwigType_type(result) != T_VOID) { - String *tm = goType(n, result); - Printv(parm_print, " (_swig_ret ", tm, ")", NULL); - if (first == NULL) { - first = NewString("_swig_ret"); - } - Delete(tm); - } - } - - Printv(f_go_wrappers, parm_print, NULL); - if (add_to_interface) { - Printv(interfaces, parm_print, "\n", NULL); - } - - // If this is a wrapper, we need to actually call the C function. - if (needs_wrapper) { - Printv(f_go_wrappers, " {\n", NULL); - - if (parm_count > required_count) { - Parm *p = parms; - int i; - for (i = 0; i < required_count; ++i) { - p = getParm(p); - p = nextParm(p); - } - for (; i < parm_count; ++i) { - p = getParm(p); - String *tm = goType(p, Getattr(p, "type")); - Printv(f_go_wrappers, "\tvar ", Getattr(p, "lname"), " ", tm, "\n", NULL); - Printf(f_go_wrappers, "\tif len(_swig_args) > %d {\n", i - required_count); - Printf(f_go_wrappers, "\t\t%s = _swig_args[%d].(%s)\n", Getattr(p, "lname"), i - required_count, tm); - Printv(f_go_wrappers, "\t}\n", NULL); - Delete(tm); - p = nextParm(p); - } - } - - String *call = NewString(""); - - bool need_return_var = SwigType_type(result) != T_VOID && ((gccgo_flag && is_constructor) || has_goout); - if (need_return_var) { - Printv(f_go_wrappers, "\tvar swig_r ", NULL); - if (is_constructor) { - String *cl = exportedName(class_name); - Printv(f_go_wrappers, cl, NULL); - Delete(cl); - } else { - Printv(f_go_wrappers, goImType(n, result), NULL); - } - Printv(f_go_wrappers, "\n", NULL); - } - - if (gccgo_flag) { - if (has_goout || is_constructor) { - Printv(call, "\tfunc() {\n", NULL); - } - Printv(call, "\tdefer SwigCgocallDone()\n", NULL); - Printv(call, "\tSwigCgocall()\n", NULL); - } - - Printv(call, "\t", NULL); - if (SwigType_type(result) != T_VOID) { - if (need_return_var) { - Printv(call, "swig_r = ", NULL); - } else { - Printv(call, "return ", NULL); - } - } - - Printv(call, wrapper_name, "(", NULL); - - if (parm_count > required_count) { - Printv(call, "len(_swig_args)", NULL); - } - - if (base && receiver) { - if (parm_count > required_count) { - Printv(call, ", ", NULL); - } - Printv(call, "_swig_base", NULL); - } - - Parm *p = parms; - for (int i = 0; i < parm_count; ++i) { - p = getParm(p); - if (i > 0 || (base && receiver) - || parm_count > required_count) { - Printv(call, ", ", NULL); - } - - SwigType *pt = Getattr(p, "type"); - String *ln = Getattr(p, "lname"); - - String *goin = Getattr(p, "tmap:goin"); - if (goin == NULL) { - Printv(call, ln, NULL); - if ((i == 0 && is_destructor) || ((i > 0 || !receiver || base || is_constructor) && goTypeIsInterface(p, pt))) { - Printv(call, ".Swigcptr()", NULL); - } - Setattr(p, "emit:goinput", ln); - } else { - String *ivar = NewString(""); - Printf(ivar, "_swig_i_%d", i); - String *itm = goImType(p, pt); - Printv(f_go_wrappers, "\tvar ", ivar, " ", itm, NULL); - goin = Copy(goin); - Replaceall(goin, "$input", ln); - Replaceall(goin, "$result", ivar); - Printv(f_go_wrappers, goin, NULL); - Delete(goin); - Printv(call, ivar, NULL); - Setattr(p, "emit:goinput", ivar); - } - - p = nextParm(p); - } - Printv(call, ")\n", NULL); - - if (gccgo_flag && (has_goout || is_constructor)) { - Printv(call, "\t}()\n", NULL); - } - - Printv(f_go_wrappers, call, NULL); - Delete(call); - - goargout(parms, parm_count); - - if (need_return_var) { - if (goout == NULL) { - Printv(f_go_wrappers, "\treturn swig_r\n", NULL); - } else { - String *tm = goType(n, result); - Printv(f_go_wrappers, "\tvar swig_r_1 ", tm, "\n", NULL); - Replaceall(goout, "$input", "swig_r"); - Replaceall(goout, "$result", "swig_r_1"); - Printv(f_go_wrappers, goout, NULL); - Printv(f_go_wrappers, "\treturn swig_r_1\n", NULL); - } - } - - Printv(f_go_wrappers, "}\n", NULL); - } else if (!gccgo_flag) { - // We don't need a wrapper. If we're using gccgo, the function - // declaration is all we need--it has a //extern comment to - // GCC-compiled wrapper. If we're not using gccgo, we need to - // call the GCC-compiled wrapper here. - Printv(f_go_wrappers, " {\n", NULL); - if (first == NULL) { - Printv(f_go_wrappers, "\tvar _swig_p uintptr\n", NULL); - } else { - Printv(f_go_wrappers, "\t_swig_p := uintptr(unsafe.Pointer(&", first, "))\n", NULL); - } - Printv(f_go_wrappers, "\t_cgo_runtime_cgocall(", wname, ", _swig_p)\n", NULL); - Printv(f_go_wrappers, "\treturn\n", NULL); - Printv(f_go_wrappers, "}", NULL); - } - - Printv(f_go_wrappers, "\n", NULL); - - Delete(wrapper_name); - DelWrapper(dummy); - - return SWIG_OK; - } - - /* ---------------------------------------------------------------------- - * argName() - * - * A helper for goFunctionWrapper to output the first argument name - * as "base" and all others as "_". - * ---------------------------------------------------------------------- */ - - const char *argName(bool *arg) { - if (*arg) { - return "_"; - } - *arg = true; - return "base"; - } - - /* ---------------------------------------------------------------------- - * gcFunctionWrapper() - * - * This is used for 6g/8g, not for gccgo. Write out the function - * redirector that will be compiled with 6c/8c. This used to write - * out a real function wrapper, but that has moved into Go code. - * ---------------------------------------------------------------------- */ - - int gcFunctionWrapper(String *wname) { - Wrapper *f = NewWrapper(); - - Printv(f->def, "#pragma dynimport ", wname, " ", wname, " \"\"\n", NULL); - Printv(f->def, "#pragma cgo_import_static ", wname, "\n", NULL); - Printv(f->def, "extern void ", wname, "(void*);\n", NULL); - // Declare this as a uintptr, since it is not a pointer into the - // Go heap. - // \xc2\xb7 is UTF-8 for U+00B7 which is Unicode 'Middle Dot' - Printv(f->def, "uintptr \xc2\xb7", wname, " = (uintptr)", wname, ";\n", NULL); - - Wrapper_print(f, f_gc_wrappers); - - DelWrapper(f); - - return SWIG_OK; - } - - /* ---------------------------------------------------------------------- - * gccFunctionWrapper() - * - * This is used for 6g/8g, not for gccgo. Write out the function - * wrapper which will be compiled with gcc. If the base parameter - * is not NULL, this is calls the base class method rather than - * executing the SWIG wrapper code. - * ---------------------------------------------------------------------- */ - - int gccFunctionWrapper(Node *n, List *base, String *wname, ParmList *parms, SwigType *result) { - Wrapper *f = NewWrapper(); - - Swig_save("gccFunctionWrapper", n, "parms", NULL); - - Parm *base_parm = NULL; - if (base && !isStatic(n)) { - SwigType *base_type = Copy(getClassType()); - SwigType_add_pointer(base_type); - base_parm = NewParm(base_type, NewString("arg1"), n); - set_nextSibling(base_parm, parms); - parms = base_parm; - } - - emit_parameter_variables(parms, f); - emit_attach_parmmaps(parms, f); - int parm_count = emit_num_arguments(parms); - int required_count = emit_num_required(parms); - - emit_return_variable(n, result, f); - - // Start the function definition. - - Printv(f->def, "void\n", wname, "(void *swig_v)\n", "{\n", NULL); - - // The single function parameter is a pointer to the real argument - // values. Define the structure that it points to. - - Printv(f->code, "\tstruct swigargs {\n", NULL); - - if (parm_count > required_count) { - Printv(f->code, "\t\tintgo _swig_optargc;\n", NULL); - } - - Parm *p = parms; - for (int i = 0; i < parm_count; ++i) { - p = getParm(p); - String *ln = Getattr(p, "lname"); - SwigType *pt = Getattr(p, "type"); - String *ct = gcCTypeForGoValue(p, pt, ln); - Printv(f->code, "\t\t\t", ct, ";\n", NULL); - Delete(ct); - p = nextParm(p); - } - if (SwigType_type(result) != T_VOID) { - Printv(f->code, "\t\tlong : 0;\n", NULL); - String *ln = NewString(Swig_cresult_name()); - String *ct = gcCTypeForGoValue(n, result, ln); - Delete(ln); - Printv(f->code, "\t\t", ct, ";\n", NULL); - Delete(ct); - - ln = NewString("_swig_go_result"); - ct = gcCTypeForGoValue(n, result, ln); - Wrapper_add_local(f, "_swig_go_result", ct); - Delete(ct); - Delete(ln); - } - Printv(f->code, "\t} *swig_a = (struct swigargs *) swig_v;\n", NULL); - - Printv(f->code, "\n", NULL); - - // Copy the input arguments out of the structure into the - // parameter variables. - - p = parms; - for (int i = 0; i < parm_count; ++i) { - p = getParm(p); - - String *tm = Getattr(p, "tmap:in"); - if (!tm) { - Swig_warning(WARN_TYPEMAP_IN_UNDEF, input_file, line_number, "Unable to use type %s as a function argument\n", SwigType_str(Getattr(p, "type"), 0)); - } else { - String *ln = Getattr(p, "lname"); - String *input = NewString(""); - Printv(input, "swig_a->", ln, NULL); - tm = Copy(tm); - Replaceall(tm, "$input", input); - Setattr(p, "emit:input", input); - if (i < required_count) { - Printv(f->code, "\t", tm, "\n", NULL); - } else { - Printf(f->code, "\tif (swig_a->_swig_optargc > %d) {\n", i - required_count); - Printv(f->code, "\t\t", tm, "\n", NULL); - Printv(f->code, "\t}\n", NULL); - } - Delete(tm); - } - p = nextParm(p); - } - - Printv(f->code, "\n", NULL); - - // Do the real work of the function. - - checkConstraints(parms, f); - - emitGoAction(n, base, parms, result, f); - - argout(parms, f); - - cleanupFunction(n, f, parms); - - Printv(f->code, "}\n", NULL); - - Wrapper_print(f, f_c_wrappers); - - Swig_restore(n); - - DelWrapper(f); - Delete(base_parm); - - return SWIG_OK; - } - - /* ---------------------------------------------------------------------- - * gccgoFunctionWrapper() - * - * This is used for gccgo, not 6g/8g. Write out the function - * wrapper which will be compiled with gcc. If the base parameter - * is not NULL, this is calls the base class method rather than - * executing the SWIG wrapper code. - * ---------------------------------------------------------------------- */ - - int gccgoFunctionWrapper(Node *n, List *base, String *wname, ParmList *parms, SwigType *result) { - Wrapper *f = NewWrapper(); - - Swig_save("gccgoFunctionWrapper", n, "parms", NULL); - - Parm *base_parm = NULL; - if (base && !isStatic(n)) { - SwigType *base_type = Copy(getClassType()); - SwigType_add_pointer(base_type); - base_parm = NewParm(base_type, NewString("arg1"), n); - set_nextSibling(base_parm, parms); - parms = base_parm; - } - - emit_parameter_variables(parms, f); - emit_attach_parmmaps(parms, f); - int parm_count = emit_num_arguments(parms); - int required_count = emit_num_required(parms); - - emit_return_variable(n, result, f); - - // Start the function definition. - - String *fnname = NewString(""); - Printv(fnname, "go_", wname, "(", NULL); - - if (parm_count > required_count) { - Printv(fnname, "intgo _swig_optargc", NULL); - } - - Parm *p = parms; - for (int i = 0; i < parm_count; ++i) { - p = getParm(p); - SwigType *pt = Copy(Getattr(p, "type")); - if (SwigType_isarray(pt)) { - SwigType_del_array(pt); - SwigType_add_pointer(pt); - } - String *pn = NewString("g"); - Append(pn, Getattr(p, "lname")); - String *ct = gccgoCTypeForGoValue(p, pt, pn); - if (i > 0 || parm_count > required_count) { - Printv(fnname, ", ", NULL); - } - Printv(fnname, ct, NULL); - Delete(ct); - Delete(pn); - Delete(pt); - p = nextParm(p); - } - - Printv(fnname, ")", NULL); - - String *fndef = NewString(""); - if (SwigType_type(result) == T_VOID) { - Printv(fndef, "void ", fnname, NULL); - } else { - String *ct = gccgoCTypeForGoValue(n, result, fnname); - Printv(fndef, ct, NULL); - Delete(ct); - } - - Printv(f->def, fndef, " __asm__(\"", go_prefix, "_", wname, "\");\n", NULL); - - Printv(f->def, fndef, " {\n", NULL); - - Delete(fnname); - Delete(fndef); - - if (SwigType_type(result) != T_VOID) { - String *ln = NewString("_swig_go_result"); - String *ct = gccgoCTypeForGoValue(n, result, ln); - Wrapper_add_local(f, "_swig_go_result", ct); - Delete(ct); - Delete(ln); - } - - // Copy the parameters into the variables which hold their values, - // applying appropriate transformations. - - p = parms; - for (int i = 0; i < parm_count; ++i) { - p = getParm(p); - - String *tm = Getattr(p, "tmap:in"); - if (!tm) { - Swig_warning(WARN_TYPEMAP_IN_UNDEF, input_file, line_number, - "Unable to use type %s as a function argument\n", SwigType_str(Getattr(p, "type"), 0)); - } else { - String *ln = Getattr(p, "lname"); - String *pn = NewString("g"); - Append(pn, ln); - tm = Copy(tm); - Replaceall(tm, "$input", pn); - Setattr(p, "emit:input", pn); - if (i < required_count) { - Printv(f->code, " ", tm, "\n", NULL); - } else { - Printf(f->code, " if (_swig_optargc > %d) {\n", i - required_count); - Printv(f->code, " ", tm, "\n", NULL); - Printv(f->code, " }\n", NULL); - } - Delete(tm); - } - - p = nextParm(p); - } - - Printv(f->code, "\n", NULL); - - // Do the real work of the function. - - checkConstraints(parms, f); - - emitGoAction(n, base, parms, result, f); - - argout(parms, f); - - cleanupFunction(n, f, parms); - - if (SwigType_type(result) != T_VOID) { - Printv(f->code, " return _swig_go_result;\n", NULL); - } - - Printv(f->code, "}\n", NULL); - - Wrapper_print(f, f_c_wrappers); - - Swig_restore(n); - - DelWrapper(f); - Delete(base_parm); - - return SWIG_OK; - } - - /* ----------------------------------------------------------------------- - * checkConstraints() - * - * Check parameter constraints if any. This is used for the C/C++ - * function. This assumes that each parameter has an "emit:input" - * property with the name to use to refer to that parameter. - * ----------------------------------------------------------------------- */ - - void checkConstraints(ParmList *parms, Wrapper *f) { - Parm *p = parms; - while (p) { - String *tm = Getattr(p, "tmap:check"); - if (!tm) { - p = nextSibling(p); - } else { - tm = Copy(tm); - Replaceall(tm, "$input", Getattr(p, "emit:input")); - Printv(f->code, tm, "\n\n", NULL); - Delete(tm); - p = Getattr(p, "tmap:check:next"); - } - } - } - - /* ----------------------------------------------------------------------- - * emitGoAction() - * - * Emit the action of the function. This is used for the C/C++ function. - * ----------------------------------------------------------------------- */ - - void emitGoAction(Node *n, List *base, ParmList *parms, SwigType *result, Wrapper *f) { - if (!gccgo_flag && SwigType_type(result) != T_VOID) { - Wrapper_add_local(f, "swig_stktop", "char *swig_stktop"); - Printv(f->code, "\tswig_stktop = _swig_topofstack();\n", NULL); - } - String *actioncode; - if (!base || isStatic(n)) { - Swig_director_emit_dynamic_cast(n, f); - actioncode = emit_action(n); - } else { - // Call the base class method. - actioncode = NewString(""); - - String *current = NewString(""); - if (!gccgo_flag) { - Printv(current, "swig_a->", NULL); - } - Printv(current, Getattr(parms, "lname"), NULL); - - int vc = 0; - for (Iterator bi = First(base); bi.item; bi = Next(bi)) { - Printf(actioncode, " %s *swig_b%d = (%s *)%s;\n", bi.item, vc, bi.item, current); - Delete(current); - current = NewString(""); - Printf(current, "swig_b%d", vc); - ++vc; - } - - String *code = Copy(Getattr(n, "wrap:action")); - Replaceall(code, Getattr(parms, "lname"), current); - Printv(actioncode, code, "\n", NULL); - } - - Swig_save("emitGoAction", n, "type", "tmap:out", NULL); - - Setattr(n, "type", result); - - String *tm = Swig_typemap_lookup_out("out", n, Swig_cresult_name(), f, actioncode); - if (!tm) { - Swig_warning(WARN_TYPEMAP_OUT_UNDEF, input_file, line_number, "Unable to use return type %s\n", SwigType_str(result, 0)); - } else { - Replaceall(tm, "$result", "_swig_go_result"); - if (GetFlag(n, "feature:new")) { - Replaceall(tm, "$owner", "1"); - } else { - Replaceall(tm, "$owner", "0"); - } - Printv(f->code, tm, "\n", NULL); - Delete(tm); - } - - if (!gccgo_flag && SwigType_type(result) != T_VOID) { - // If the function called back into the Go code, the stack might - // have been copied. We need to adjust swig_a accordingly here. - // This is what cgo does. - Printv(f->code, "\tswig_a = (struct swigargs*)((char*)swig_a + (_swig_topofstack() - swig_stktop));\n", NULL); - Printv(f->code, "\tswig_a->", Swig_cresult_name(), " = ", "_swig_go_result;\n", NULL); - } - - Swig_restore(n); - } - - /* ----------------------------------------------------------------------- - * argout() - * - * Handle argument output code if any. This is used for the C/C++ - * function. This assumes that each parameter has an "emit:input" - * property with the name to use to refer to that parameter. - * ----------------------------------------------------------------------- */ - - void argout(ParmList *parms, Wrapper *f) { - Parm *p = parms; - while (p) { - String *tm = Getattr(p, "tmap:argout"); - if (!tm) { - p = nextSibling(p); - } else { - tm = Copy(tm); - Replaceall(tm, "$result", Swig_cresult_name()); - Replaceall(tm, "$input", Getattr(p, "emit:input")); - Printv(f->code, tm, "\n", NULL); - Delete(tm); - p = Getattr(p, "tmap:argout:next"); - } - } - } - - /* ----------------------------------------------------------------------- - * goargout() - * - * Handle Go argument output code if any. This is used for the Go - * function. This assumes that each parameter has an "emit:goinput" - * property with the name to use to refer to that parameter. - * ----------------------------------------------------------------------- */ - - void goargout(ParmList *parms, int parm_count) { - Parm *p = parms; - for (int i = 0; i < parm_count; ++i) { - p = getParm(p); - String *tm = Getattr(p, "tmap:goargout"); - if (!tm) { - p = nextSibling(p); - } else { - tm = Copy(tm); - Replaceall(tm, "$result", "swig_r"); - Replaceall(tm, "$input", Getattr(p, "emit:goinput")); - Printv(f_go_wrappers, tm, NULL); - Delete(tm); - p = Getattr(p, "tmap:goargout:next"); - } - } - } - - /* ----------------------------------------------------------------------- - * freearg() - * - * Handle argument cleanup code if any. This is used for the C/C++ - * function. This assumes that each parameter has an "emit:input" - * property with the name to use to refer to that parameter. - * ----------------------------------------------------------------------- */ - - String *freearg(ParmList *parms) { - String *ret = NewString(""); - Parm *p = parms; - while (p) { - String *tm = Getattr(p, "tmap:freearg"); - if (!tm) { - p = nextSibling(p); - } else { - tm = Copy(tm); - Replaceall(tm, "$input", Getattr(p, "emit:input")); - Printv(ret, tm, "\n", NULL); - Delete(tm); - p = Getattr(p, "tmap:freearg:next"); - } - } - return ret; - } - - /* ----------------------------------------------------------------------- - * cleanupFunction() - * - * Final function cleanup code. - * ----------------------------------------------------------------------- */ - - void cleanupFunction(Node *n, Wrapper *f, ParmList *parms) { - String *cleanup = freearg(parms); - Printv(f->code, cleanup, NULL); - - if (GetFlag(n, "feature:new")) { - String *tm = Swig_typemap_lookup("newfree", n, Swig_cresult_name(), 0); - if (tm) { - Replaceall(tm, "$source", Swig_cresult_name()); - Printv(f->code, tm, "\n", NULL); - Delete(tm); - } - } - - Replaceall(f->code, "$cleanup", cleanup); - Delete(cleanup); - - Replaceall(f->code, "$symname", Getattr(n, "sym:name")); - } - - /* ----------------------------------------------------------------------- - * variableHandler() - * - * This exists just to set the making_variable_wrappers flag. - * ----------------------------------------------------------------------- */ - - virtual int variableHandler(Node *n) { - assert(!making_variable_wrappers); - making_variable_wrappers = true; - int r = Language::variableHandler(n); - making_variable_wrappers = false; - return r; - } - - /* ----------------------------------------------------------------------- - * constantWrapper() - * - * Product a const declaration. - * ------------------------------------------------------------------------ */ - - virtual int constantWrapper(Node *n) { - SwigType *type = Getattr(n, "type"); - - if (!SwigType_issimple(type) && SwigType_type(type) != T_STRING) { - return goComplexConstant(n, type); - } - - if (Swig_storage_isstatic(n)) { - return goComplexConstant(n, type); - } - - String *go_name = buildGoName(Getattr(n, "sym:name"), false, false); - - String *tm = goType(n, type); - String *value = Getattr(n, "value"); - - String *copy = NULL; - if (SwigType_type(type) == T_BOOL) { - if (Cmp(value, "true") != 0 && Cmp(value, "false") != 0) { - return goComplexConstant(n, type); - } - } else if (SwigType_type(type) == T_STRING || SwigType_type(type) == T_CHAR) { - // Backslash sequences are somewhat different in Go and C/C++. - if (Strchr(value, '\\') != 0) { - return goComplexConstant(n, type); - } - } else { - // Accept a 0x prefix, and strip combinations of u and l - // suffixes. Otherwise accept digits, decimal point, and - // exponentiation. Treat anything else as too complicated to - // handle as a Go constant. - char *p = Char(value); - int len = strlen(p); - bool need_copy = false; - while (len > 0) { - char c = p[len - 1]; - if (c != 'l' && c != 'L' && c != 'u' && c != 'U') { - break; - } - --len; - need_copy = true; - } - bool is_hex = false; - int i = 0; - if (p[0] == '0' && (p[1] == 'x' || p[1] == 'X')) { - i = 2; - is_hex = true; - } - for (; i < len; ++i) { - switch (p[i]) { - case '0': case '1': case '2': case '3': case '4': case '5': case '6': case '7': case '8': case '9': - break; - case 'a': case 'b': case 'c': case 'd': case 'f': case 'A': case 'B': case 'C': case 'D': case 'F': - if (!is_hex) { - return goComplexConstant(n, type); - } - break; - case '.': case 'e': case 'E': case '+': case '-': - break; - default: - return goComplexConstant(n, type); - } - } - if (need_copy) { - copy = Copy(value); - Replaceall(copy, p + len, ""); - value = copy; - } - } - - if (!checkNameConflict(go_name, n, NULL)) { - Delete(tm); - Delete(go_name); - Delete(copy); - return SWIG_NOWRAP; - } - - Printv(f_go_wrappers, "const ", go_name, " ", tm, " = ", NULL); - if (SwigType_type(type) == T_STRING) { - Printv(f_go_wrappers, "\"", value, "\"", NULL); - } else if (SwigType_type(type) == T_CHAR) { - Printv(f_go_wrappers, "'", value, "'", NULL); - } else { - Printv(f_go_wrappers, value, NULL); - } - - Printv(f_go_wrappers, "\n", NULL); - - Delete(tm); - Delete(go_name); - Delete(copy); - - return SWIG_OK; - } - - /* ---------------------------------------------------------------------- - * enumDeclaration() - * - * A C++ enum type turns into a Named go int type. - * ---------------------------------------------------------------------- */ - - virtual int enumDeclaration(Node *n) { - String *name = goEnumName(n); - if (Strcmp(name, "int") != 0) { - if (!ImportMode || !imported_package) { - if (!checkNameConflict(name, n, NULL)) { - Delete(name); - return SWIG_NOWRAP; - } - Printv(f_go_wrappers, "type ", name, " int\n", NULL); - } else { - String *nw = NewString(""); - Printv(nw, imported_package, ".", name, NULL); - Setattr(n, "go:enumname", nw); - } - } - Delete(name); - - return Language::enumDeclaration(n); - } - - /* ----------------------------------------------------------------------- - * enumvalueDeclaration() - * - * Declare a single value of an enum type. We fetch the value by - * calling a C/C++ function. - * ------------------------------------------------------------------------ */ - - virtual int enumvalueDeclaration(Node *n) { - if (!is_public(n)) { - return SWIG_OK; - } - if (Getattr(parentNode(n), "unnamed")) { - Setattr(n, "type", NewString("int")); - } else { - Setattr(n, "type", Getattr(parentNode(n), "enumtype")); - } - return goComplexConstant(n, Getattr(n, "type")); - } - - /* ----------------------------------------------------------------------- - * goComplexConstant() - * - * Handle a const declaration for something which is not a Go constant. - * ------------------------------------------------------------------------ */ - - int goComplexConstant(Node *n, SwigType *type) { - String *symname = Getattr(n, "sym:name"); - if (!symname) { - symname = Getattr(n, "name"); - } - - String *varname = buildGoName(symname, true, false); - - if (!checkNameConflict(varname, n, NULL)) { - Delete(varname); - return SWIG_NOWRAP; - } - - String *get = NewString(""); - Printv(get, Swig_cresult_name(), " = ", NULL); - - char quote; - if (Getattr(n, "wrappedasconstant")) { - quote = '\0'; - } else if (SwigType_type(type) == T_CHAR) { - quote = '\''; - } else if (SwigType_type(type) == T_STRING) { - quote = '"'; - } else { - quote = '\0'; - } - - if (quote != '\0') { - Printf(get, "%c", quote); - } - - Printv(get, Getattr(n, "value"), NULL); - - if (quote != '\0') { - Printf(get, "%c", quote); - } - - Printv(get, ";\n", NULL); - Setattr(n, "wrap:action", get); - - String *sname = Copy(symname); - if (class_name) { - Append(sname, "_"); - Append(sname, class_name); - } - - String *go_name = NewString("_swig_get"); - if (class_name) { - Append(go_name, class_name); - Append(go_name, "_"); - } - Append(go_name, sname); - - String *wname = Swig_name_wrapper(sname); - Setattr(n, "wrap:name", wname); - - int r = makeWrappers(n, sname, go_name, NULL, wname, NULL, NULL, type, true); - - if (r != SWIG_OK) { - return r; - } - - String *t = goType(n, type); - Printv(f_go_wrappers, "var ", varname, " ", t, " = ", go_name, "()\n", NULL); - - Delete(varname); - Delete(t); - Delete(go_name); - Delete(sname); - - return SWIG_OK; - } - - /* ------------------------------------------------------------ - * classHandler() - * - * For a C++ class, in Go we generate both a struct and an - * interface. The interface will declare all the class public - * methods. We will define all the methods on the struct, so that - * the struct meets the interface. We then expect users of the - * class to use the interface. - * ------------------------------------------------------------ */ - - virtual int classHandler(Node *n) { - class_node = n; - - List *baselist = Getattr(n, "bases"); - bool has_base_classes = baselist && Len(baselist) > 0; - - String *name = Getattr(n, "sym:name"); - - String *go_name = exportedName(name); - - if (!checkNameConflict(go_name, n, NULL)) { - Delete(go_name); - SetFlag(n, "go:conflict"); - return SWIG_NOWRAP; - } - - String *go_type_name = goCPointerType(Getattr(n, "classtypeobj"), true); - - class_name = name; - class_receiver = go_type_name; - class_methods = NewHash(); - - int isdir = GetFlag(n, "feature:director"); - int isnodir = GetFlag(n, "feature:nodirector"); - bool is_director = isdir && !isnodir; - - Printv(f_go_wrappers, "type ", go_type_name, " uintptr\n\n", NULL); - - // A method to return the pointer to the C++ class. This is used - // by generated code to convert between the interface and the C++ - // value. - Printv(f_go_wrappers, "func (p ", go_type_name, ") Swigcptr() uintptr {\n", NULL); - Printv(f_go_wrappers, "\treturn (uintptr)(p)\n", NULL); - Printv(f_go_wrappers, "}\n\n", NULL); - - // A method used as a marker for the class, to avoid invalid - // interface conversions when using multiple inheritance. - Printv(f_go_wrappers, "func (p ", go_type_name, ") SwigIs", go_name, "() {\n", NULL); - Printv(f_go_wrappers, "}\n\n", NULL); - - if (is_director) { - // Return the interface passed to the NewDirector function. - Printv(f_go_wrappers, "func (p ", go_type_name, ") DirectorInterface() interface{} {\n", NULL); - Printv(f_go_wrappers, "\treturn nil\n", NULL); - Printv(f_go_wrappers, "}\n\n", NULL); - } - - // We have seen a definition for this type. - Setattr(defined_types, go_name, go_name); - Setattr(defined_types, go_type_name, go_type_name); - - interfaces = NewString(""); - - int r = Language::classHandler(n); - if (r != SWIG_OK) { - return r; - } - - if (has_base_classes) { - // For each method defined in a base class but not defined in - // this class, we need to define the method in this class. We - // can't use anonymous field inheritance because it works - // differently in Go and in C++. - - Hash *local = NewHash(); - for (Node *ni = Getattr(n, "firstChild"); ni; ni = nextSibling(ni)) { - - if (!is_public(ni)) { - continue; - } - - String *type = Getattr(ni, "nodeType"); - if (Cmp(type, "constructor") == 0 || Cmp(type, "destructor") == 0) { - continue; - } - - String *cname = Getattr(ni, "sym:name"); - if (!cname) { - cname = Getattr(ni, "name"); - } - if (cname) { - Setattr(local, cname, NewString("")); - } - } - - for (Iterator b = First(baselist); b.item; b = Next(b)) { - List *bases = NewList(); - Append(bases, Getattr(b.item, "classtype")); - int r = addBase(n, b.item, bases, local); - if (r != SWIG_OK) { - return r; - } - Delete(bases); - } - - Delete(local); - - Hash *parents = NewHash(); - addFirstBaseInterface(n, parents, baselist); - int r = addExtraBaseInterfaces(n, parents, baselist); - Delete(parents); - if (r != SWIG_OK) { - return r; - } - } - - Printv(f_go_wrappers, "type ", go_name, " interface {\n", NULL); - Printv(f_go_wrappers, "\tSwigcptr() uintptr\n", NULL); - Printv(f_go_wrappers, "\tSwigIs", go_name, "()\n", NULL); - - if (is_director) { - Printv(f_go_wrappers, "\tDirectorInterface() interface{}\n", NULL); - } - - Append(f_go_wrappers, interfaces); - Printv(f_go_wrappers, "}\n\n", NULL); - Delete(interfaces); - - interfaces = NULL; - class_name = NULL; - class_receiver = NULL; - class_node = NULL; - Delete(class_methods); - class_methods = NULL; - - Delete(go_type_name); - - return SWIG_OK; - } - - /* ------------------------------------------------------------ - * addBase() - * - * Implement methods and members defined in a parent class for a - * child class. - * ------------------------------------------------------------ */ - - int addBase(Node *n, Node *base, List *bases, Hash *local) { - if (GetFlag(base, "feature:ignore")) { - return SWIG_OK; - } - - for (Node *ni = Getattr(base, "firstChild"); ni; ni = nextSibling(ni)) { - - if (GetFlag(ni, "feature:ignore")) { - continue; - } - - if (!is_public(ni)) { - continue; - } - - String *type = Getattr(ni, "nodeType"); - if (Strcmp(type, "constructor") == 0 || Strcmp(type, "destructor") == 0 || Strcmp(type, "enum") == 0 || Strcmp(type, "using") == 0 || Strcmp(type, "classforward") == 0 || Strcmp(type, "template") == 0) { - continue; - } - String *storage = Getattr(ni, "storage"); - if (storage && (Strcmp(storage, "typedef") == 0 || Strcmp(storage, "friend") == 0)) { - continue; - } - - String *mname = Getattr(ni, "sym:name"); - if (!mname) { - continue; - } - - String *lname = Getattr(ni, "name"); - if (Getattr(class_methods, lname)) { - continue; - } - if (Getattr(local, lname)) { - continue; - } - Setattr(local, lname, NewString("")); - - String *ty = NewString(Getattr(ni, "type")); - SwigType_push(ty, Getattr(ni, "decl")); - String *fullty = SwigType_typedef_resolve_all(ty); - bool is_function = SwigType_isfunction(fullty) ? true : false; - Delete(ty); - Delete(fullty); - - if (is_function) { - int r = goBaseMethod(n, bases, ni); - if (r != SWIG_OK) { - return r; - } - - if (Getattr(ni, "sym:overloaded")) { - for (Node *on = Getattr(ni, "sym:nextSibling"); on; on = Getattr(on, "sym:nextSibling")) { - r = goBaseMethod(n, bases, on); - if (r != SWIG_OK) { - return r; - } - } - - String *receiver = class_receiver; - bool is_static = isStatic(ni); - if (is_static) { - receiver = NULL; - } - String *go_name = buildGoName(Getattr(ni, "sym:name"), is_static, false); - r = makeDispatchFunction(ni, go_name, receiver, is_static, NULL, false); - Delete(go_name); - if (r != SWIG_OK) { - return r; - } - } - } else { - int r = goBaseVariable(n, bases, ni); - if (r != SWIG_OK) { - return r; - } - } - } - - List *baselist = Getattr(base, "bases"); - if (baselist && Len(baselist) > 0) { - for (Iterator b = First(baselist); b.item; b = Next(b)) { - List *nb = Copy(bases); - Append(nb, Getattr(b.item, "classtype")); - int r = addBase(n, b.item, nb, local); - Delete(nb); - if (r != SWIG_OK) { - return r; - } - } - } - - return SWIG_OK; - } - - /* ------------------------------------------------------------ - * goBaseMethod() - * - * Implement a method defined in a parent class for a child class. - * ------------------------------------------------------------ */ - - int goBaseMethod(Node *method_class, List *bases, Node *method) { - String *symname = Getattr(method, "sym:name"); - if (!validIdentifier(symname)) { - return SWIG_OK; - } - - String *name = NewString(""); - Printv(name, Getattr(method_class, "sym:name"), "_", symname, NULL); - - bool is_static = isStatic(method); - - String *go_name = buildGoName(name, is_static, false); - - String *overname = NULL; - if (Getattr(method, "sym:overloaded")) { - overname = Getattr(method, "sym:overname"); - } - String *wname = Swig_name_wrapper(name); - if (overname) { - Append(wname, overname); - } - - String *result = NewString(Getattr(method, "type")); - SwigType_push(result, Getattr(method, "decl")); - if (SwigType_isqualifier(result)) { - Delete(SwigType_pop(result)); - } - Delete(SwigType_pop_function(result)); - - // If the base method is imported, wrap:action may not be set. - Swig_save("goBaseMethod", method, "wrap:name", "wrap:action", "parms", NULL); - Setattr(method, "wrap:name", wname); - if (!Getattr(method, "wrap:action")) { - if (!is_static) { - Swig_MethodToFunction(method, getNSpace(), getClassType(), (Getattr(method, "template") ? SmartPointer : Extend | SmartPointer), NULL, false); - // Remove any self parameter that was just added. - ParmList *parms = Getattr(method, "parms"); - if (parms && Getattr(parms, "self")) { - parms = CopyParmList(nextSibling(parms)); - Setattr(method, "parms", parms); - } - } else { - String *call = Swig_cfunction_call(Getattr(method, "name"), Getattr(method, "parms")); - Setattr(method, "wrap:action", Swig_cresult(Getattr(method, "type"), Swig_cresult_name(), call)); - } - } - - int r = makeWrappers(method, name, go_name, overname, wname, bases, Getattr(method, "parms"), result, is_static); - - Swig_restore(method); - - Delete(result); - Delete(go_name); - Delete(name); - - return r; - } - - /* ------------------------------------------------------------ - * goBaseVariable() - * - * Add accessors for a member variable defined in a parent class for - * a child class. - * ------------------------------------------------------------ */ - - int goBaseVariable(Node *var_class, List *bases, Node *var) { - if (isStatic(var)) { - return SWIG_OK; - } - - String *var_name = buildGoName(Getattr(var, "sym:name"), false, false); - - Swig_save("goBaseVariable", var, "type", "wrap:action", NULL); - - // For a pointer type we apparently have to wrap in the decl. - SwigType *var_type = NewString(Getattr(var, "type")); - SwigType_push(var_type, Getattr(var, "decl")); - Setattr(var, "type", var_type); - - SwigType *vt = Copy(var_type); - if (SwigType_isclass(vt)) { - SwigType_add_pointer(vt); - } - - int flags = Extend | SmartPointer | use_naturalvar_mode(var); - if (isNonVirtualProtectedAccess(var)) { - flags |= CWRAP_ALL_PROTECTED_ACCESS; - } - - String *mname = Swig_name_member(getNSpace(), Getattr(var_class, "sym:name"), var_name); - - if (is_assignable(var)) { - for (Iterator ki = First(var); ki.key; ki = Next(ki)) { - if (Strncmp(ki.key, "tmap:", 5) == 0) { - Delattr(var, ki.key); - } - } - Swig_save("goBaseVariableSet", var, "name", "sym:name", "type", NULL); - - String *mname_set = NewString("Set"); - Append(mname_set, mname); - - String *go_name = NewString("Set"); - Append(go_name, var_name); - - Swig_MembersetToFunction(var, class_name, flags); - - String *wname = Swig_name_wrapper(mname_set); - ParmList *parms = NewParm(vt, var_name, var); - String *result = NewString("void"); - int r = makeWrappers(var, mname_set, go_name, NULL, wname, bases, parms, result, false); - if (r != SWIG_OK) { - return r; - } - Delete(wname); - Delete(parms); - Delete(result); - Delete(go_name); - Delete(mname_set); - - Swig_restore(var); - for (Iterator ki = First(var); ki.key; ki = Next(ki)) { - if (Strncmp(ki.key, "tmap:", 5) == 0) { - Delattr(var, ki.key); - } - } - } - - Swig_MembergetToFunction(var, class_name, flags); - - String *mname_get = NewString("Get"); - Append(mname_get, mname); - - String *go_name = NewString("Get"); - Append(go_name, var_name); - - String *wname = Swig_name_wrapper(mname_get); - - int r = makeWrappers(var, mname_get, go_name, NULL, wname, bases, NULL, vt, false); - if (r != SWIG_OK) { - return r; - } - - Delete(wname); - Delete(mname_get); - Delete(go_name); - Delete(mname); - Delete(var_name); - Delete(var_type); - Delete(vt); - - Swig_restore(var); - - return SWIG_OK; - } - - /* ------------------------------------------------------------ - * addFirstBaseInterface() - * - * When a C++ class uses multiple inheritance, we can use the C++ - * pointer for the first base class but not for any subsequent base - * classes. However, the Go interface will match the interface for - * all the base classes. To avoid accidentally treating a class as - * a pointer to a base class other than the first one, we use an - * isClassname method. This function adds those methods as - * required. - * - * For convenience when using multiple inheritance, we also add - * functions to retrieve the base class pointers. - * ------------------------------------------------------------ */ - - void addFirstBaseInterface(Node *n, Hash *parents, List *bases) { - if (!bases || Len(bases) == 0) { - return; - } - Iterator b = First(bases); - if (!GetFlag(b.item, "feature:ignore")) { - String *go_name = buildGoName(Getattr(n, "sym:name"), false, false); - String *go_type_name = goCPointerType(Getattr(n, "classtypeobj"), true); - String *go_base_name = exportedName(Getattr(b.item, "sym:name")); - String *go_base_type = goType(n, Getattr(b.item, "classtypeobj")); - String *go_base_type_name = goCPointerType(Getattr(b.item, "classtypeobj"), true); - - Printv(f_go_wrappers, "func (p ", go_type_name, ") SwigIs", go_base_name, "() {\n", NULL); - Printv(f_go_wrappers, "}\n\n", NULL); - - Printv(interfaces, "\tSwigIs", go_base_name, "()\n", NULL); - - Printv(f_go_wrappers, "func (p ", go_type_name, ") SwigGet", go_base_name, "() ", go_base_type, " {\n", NULL); - Printv(f_go_wrappers, "\treturn ", go_base_type_name, "(p.Swigcptr())\n", NULL); - Printv(f_go_wrappers, "}\n\n", NULL); - - Printv(interfaces, "\tSwigGet", go_base_name, "() ", go_base_type, "\n", NULL); - - Setattr(parents, go_base_name, NewString("")); - - Delete(go_name); - Delete(go_type_name); - Delete(go_base_type); - Delete(go_base_type_name); - } - - addFirstBaseInterface(n, parents, Getattr(b.item, "bases")); - } - - /* ------------------------------------------------------------ - * addExtraBaseInterfaces() - * - * Add functions to retrieve the base class pointers for all base - * classes other than the first. - * ------------------------------------------------------------ */ - - int addExtraBaseInterfaces(Node *n, Hash *parents, List *bases) { - Iterator b = First(bases); - - Node *fb = b.item; - - for (b = Next(b); b.item; b = Next(b)) { - if (GetFlag(b.item, "feature:ignore")) { - continue; - } - - String *go_base_name = exportedName(Getattr(b.item, "sym:name")); - - Swig_save("addExtraBaseInterface", n, "wrap:action", "wrap:name", "wrap:parms", NULL); - - SwigType *type = Copy(Getattr(n, "classtypeobj")); - SwigType_add_pointer(type); - Parm *parm = NewParm(type, "self", n); - Setattr(n, "wrap:parms", parm); - - String *pn = Swig_cparm_name(parm, 0); - String *action = NewString(""); - Printv(action, Swig_cresult_name(), " = (", Getattr(b.item, "classtype"), "*)", pn, ";", NULL); - Delete(pn); - - Setattr(n, "wrap:action", action); - - String *name = Copy(class_name); - Append(name, "_SwigGet"); - Append(name, go_base_name); - - String *go_name = NewString("SwigGet"); - String *c1 = exportedName(go_base_name); - Append(go_name, c1); - Delete(c1); - - String *wname = Swig_name_wrapper(name); - Setattr(n, "wrap:name", wname); - - SwigType *result = Copy(Getattr(b.item, "classtypeobj")); - SwigType_add_pointer(result); - - int r = makeWrappers(n, name, go_name, NULL, wname, NULL, parm, result, - false); - if (r != SWIG_OK) { - return r; - } - - Swig_restore(n); - - Setattr(parents, go_base_name, NewString("")); - - Delete(go_name); - Delete(type); - Delete(parm); - Delete(action); - Delete(result); - - String *ns = NewString(""); - addParentExtraBaseInterfaces(n, parents, b.item, false, ns); - Delete(ns); - } - - if (!GetFlag(fb, "feature:ignore")) { - String *ns = NewString(""); - addParentExtraBaseInterfaces(n, parents, fb, true, ns); - Delete(ns); - } - - return SWIG_OK; - } - - /* ------------------------------------------------------------ - * addParentExtraBaseInterfaces() - * - * Add functions to retrieve the base class pointers for all base - * classes of parents other than the first base class at each level. - * ------------------------------------------------------------ */ - - void addParentExtraBaseInterfaces(Node *n, Hash *parents, Node *base, bool is_base_first, String *sofar) { - List *baselist = Getattr(base, "bases"); - if (!baselist || Len(baselist) == 0) { - return; - } - - String *go_this_base_name = exportedName(Getattr(base, "sym:name")); - - String *sf = NewString(""); - Printv(sf, sofar, ".SwigGet", go_this_base_name, "()", NULL); - - Iterator b = First(baselist); - - if (is_base_first) { - if (!b.item) { - return; - } - if (!GetFlag(b.item, "feature:ignore")) { - addParentExtraBaseInterfaces(n, parents, b.item, true, sf); - } - - b = Next(b); - } - - String *go_name = buildGoName(Getattr(n, "sym:name"), false, false); - String *go_type_name = goCPointerType(Getattr(n, "classtypeobj"), true); - - for (; b.item; b = Next(b)) { - if (GetFlag(b.item, "feature:ignore")) { - continue; - } - - String *go_base_name = exportedName(Getattr(b.item, "sym:name")); - - if (!Getattr(parents, go_base_name)) { - Printv(f_go_wrappers, "func (p ", go_type_name, ") SwigGet", go_base_name, "() ", go_base_name, " {\n", NULL); - Printv(f_go_wrappers, "\treturn p", sf, ".SwigGet", go_base_name, "()\n", NULL); - Printv(f_go_wrappers, "}\n\n", NULL); - - Printv(interfaces, "\tSwigGet", go_base_name, "() ", go_base_name, "\n", NULL); - - addParentExtraBaseInterfaces(n, parents, b.item, false, sf); - - Setattr(parents, go_base_name, NewString("")); - } - } - - Delete(go_name); - Delete(go_type_name); - Delete(go_this_base_name); - Delete(sf); - } - - /* ------------------------------------------------------------ - * classDirectorInit - * - * Add support for a director class. - * - * Virtual inheritance is different in Go and C++. We implement - * director classes by defining a new function in Go, - * NewDirectorClassname, which takes a empty interface value and - * creates an instance of a new child class. The new child class - * refers all methods back to Go. The Go code checks whether the - * value passed to NewDirectorClassname implements that method; if - * it does, it calls it, otherwise it calls back into C++. - * ------------------------------------------------------------ */ - - int classDirectorInit(Node *n) { - // Because we use a different function to handle inheritance in - // Go, ordinary creations of the object should not create a - // director object. - Delete(director_ctor_code); - director_ctor_code = NewString("$nondirector_new"); - - class_node = n; - - String *name = Getattr(n, "sym:name"); - - assert(!class_name); - class_name = name; - - String *go_name = exportedName(name); - - String *go_type_name = goCPointerType(Getattr(n, "classtypeobj"), true); - - assert(!class_receiver); - class_receiver = go_type_name; - - String *director_struct_name = NewString("_swig_Director"); - Append(director_struct_name, go_name); - - String *cxx_director_name = NewString("SwigDirector_"); - Append(cxx_director_name, name); - - // The Go type of the director class. - Printv(f_go_wrappers, "type ", director_struct_name, " struct {\n", NULL); - Printv(f_go_wrappers, "\t", go_type_name, "\n", NULL); - Printv(f_go_wrappers, "\tv interface{}\n", NULL); - Printv(f_go_wrappers, "}\n\n", NULL); - - Printv(f_go_wrappers, "func (p *", director_struct_name, ") Swigcptr() uintptr {\n", NULL); - Printv(f_go_wrappers, "\treturn p.", go_type_name, ".Swigcptr()\n", NULL); - Printv(f_go_wrappers, "}\n\n", NULL); - - Printv(f_go_wrappers, "func (p *", director_struct_name, ") SwigIs", go_name, "() {\n", NULL); - Printv(f_go_wrappers, "}\n\n", NULL); - - Printv(f_go_wrappers, "func (p *", director_struct_name, ") DirectorInterface() interface{} {\n", NULL); - Printv(f_go_wrappers, "\treturn p.v\n", NULL); - Printv(f_go_wrappers, "}\n\n", NULL); - - // Start defining the director class. - Printv(f_c_directors_h, "class ", cxx_director_name, " : public ", Getattr(n, "classtype"), "\n", NULL); - Printv(f_c_directors_h, "{\n", NULL); - Printv(f_c_directors_h, " public:\n", NULL); - - Delete(director_struct_name); - Delete(cxx_director_name); - - class_methods = NewHash(); - - return SWIG_OK; - } - - /* ------------------------------------------------------------ - * classDirectorConstructor - * - * Emit a constructor for a director class. - * ------------------------------------------------------------ */ - - int classDirectorConstructor(Node *n) { - bool is_ignored = GetFlag(n, "feature:ignore") ? true : false; - - String *name = Getattr(n, "sym:name"); - if (!name) { - assert(is_ignored); - name = Getattr(n, "name"); - } - - String *overname = NULL; - if (Getattr(n, "sym:overloaded")) { - overname = Getattr(n, "sym:overname"); - } - - String *go_name = exportedName(name); - - ParmList *parms = Getattr(n, "parms"); - Setattr(n, "wrap:parms", parms); - - String *cn = exportedName(Getattr(parentNode(n), "sym:name")); - - String *go_type_name = goCPointerType(Getattr(parentNode(n), "classtypeobj"), true); - - String *director_struct_name = NewString("_swig_Director"); - Append(director_struct_name, cn); - - String *fn_name = NewString("_swig_NewDirector"); - Append(fn_name, cn); - Append(fn_name, go_name); - - if (!overname && !is_ignored) { - if (!checkNameConflict(fn_name, n, NULL)) { - return SWIG_NOWRAP; - } - } - - String *wname = Swig_name_wrapper(fn_name); - - if (overname) { - Append(wname, overname); - } - Setattr(n, "wrap:name", wname); - - bool is_static = isStatic(n); - - Wrapper *dummy = NewWrapper(); - emit_attach_parmmaps(parms, dummy); - DelWrapper(dummy); - - Swig_typemap_attach_parms("gotype", parms, NULL); - Swig_typemap_attach_parms("imtype", parms, NULL); - int parm_count = emit_num_arguments(parms); - - String *func_name = NewString("NewDirector"); - Append(func_name, go_name); - - String *func_with_over_name = Copy(func_name); - if (overname) { - Append(func_with_over_name, overname); - } - - SwigType *first_type = NewString("void"); - SwigType_add_pointer(first_type); - Parm *first_parm = NewParm(first_type, "swig_p", n); - set_nextSibling(first_parm, parms); - Setattr(first_parm, "lname", "p"); - - Parm *p = parms; - for (int i = 0; i < parm_count; ++i) { - p = getParm(p); - Swig_cparm_name(p, i); - p = nextParm(p); - } - - if (!is_ignored) { - // Declare the C++ wrapper. - - if (!gccgo_flag) { - Printv(f_go_wrappers, "var ", wname, " unsafe.Pointer\n\n", NULL); - } else { - Printv(f_go_wrappers, "//extern ", go_prefix, "_", wname, "\n", NULL); - } - - Printv(f_go_wrappers, "func ", fn_name, NULL); - if (overname) { - Printv(f_go_wrappers, overname, NULL); - } - Printv(f_go_wrappers, "(_swig_director *", director_struct_name, NULL); - - p = parms; - for (int i = 0; i < parm_count; ++i) { - p = getParm(p); - String *tm = goType(p, Getattr(p, "type")); - Printv(f_go_wrappers, ", _ ", tm, NULL); - Delete(tm); - p = nextParm(p); - } - - Printv(f_go_wrappers, ") (_swig_ret ", go_type_name, ")", NULL); - - if (!gccgo_flag) { - Printv(f_go_wrappers, " {\n", NULL); - Printv(f_go_wrappers, "\t_swig_p := uintptr(unsafe.Pointer(&_swig_director))\n", NULL); - Printv(f_go_wrappers, "\t_cgo_runtime_cgocall(", wname, ", _swig_p)\n", NULL); - Printv(f_go_wrappers, "\treturn\n", NULL); - Printv(f_go_wrappers, "}", NULL); - } - - Printv(f_go_wrappers, "\n\n", NULL); - - Printv(f_go_wrappers, "func ", func_with_over_name, "(v interface{}", NULL); - - p = parms; - for (int i = 0; i < parm_count; ++i) { - p = getParm(p); - // Set the lname parameter. - Printv(f_go_wrappers, ", ", Getattr(p, "lname"), " ", NULL); - String *tm = goType(p, Getattr(p, "type")); - Printv(f_go_wrappers, tm, NULL); - Delete(tm); - p = nextParm(p); - } - - Printv(f_go_wrappers, ") ", cn, " {\n", NULL); - - Printv(f_go_wrappers, "\tp := &", director_struct_name, "{0, v}\n", NULL); - - if (gccgo_flag) { - Printv(f_go_wrappers, "\tdefer SwigCgocallDone()\n", NULL); - Printv(f_go_wrappers, "\tSwigCgocall()\n", NULL); - } - - Printv(f_go_wrappers, "\tp.", class_receiver, " = ", fn_name, NULL); - if (overname) { - Printv(f_go_wrappers, overname, NULL); - } - Printv(f_go_wrappers, "(p", NULL); - - p = parms; - for (int i = 0; i < parm_count; ++i) { - p = getParm(p); - Printv(f_go_wrappers, ", ", Getattr(p, "lname"), NULL); - p = nextParm(p); - } - - Printv(f_go_wrappers, ")\n", NULL); - Printv(f_go_wrappers, "\treturn p\n", NULL); - Printv(f_go_wrappers, "}\n\n", NULL); - - SwigType *result = Copy(Getattr(parentNode(n), "classtypeobj")); - SwigType_add_pointer(result); - - Swig_save("classDirectorConstructor", n, "wrap:name", "wrap:action", NULL); - - Setattr(n, "wrap:name", Swig_name_wrapper(name)); - - String *action = NewString(""); - Printv(action, Swig_cresult_name(), " = new SwigDirector_", class_name, "(", NULL); - String *pname = Swig_cparm_name(NULL, 0); - Printv(action, pname, NULL); - Delete(pname); - p = parms; - for (int i = 0; i < parm_count; ++i) { - p = getParm(p); - String *pname = Swig_cparm_name(NULL, i + 1); - Printv(action, ", ", NULL); - if (SwigType_isreference(Getattr(p, "type"))) { - Printv(action, "*", NULL); - } - Printv(action, pname, NULL); - Delete(pname); - p = nextParm(p); - } - Printv(action, ");", NULL); - Setattr(n, "wrap:action", action); - - if (!gccgo_flag) { - int r = gcFunctionWrapper(wname); - if (r != SWIG_OK) { - return r; - } - r = gccFunctionWrapper(n, NULL, wname, first_parm, result); - if (r != SWIG_OK) { - return r; - } - } else { - int r = gccgoFunctionWrapper(n, NULL, wname, first_parm, result); - if (r != SWIG_OK) { - return r; - } - } - - Swig_restore(n); - - Delete(result); - } - - String *cxx_director_name = NewString("SwigDirector_"); - Append(cxx_director_name, class_name); - - String *decl = Swig_method_decl(NULL, Getattr(n, "decl"), - cxx_director_name, first_parm, 0, 0); - Printv(f_c_directors_h, " ", decl, ";\n", NULL); - Delete(decl); - - decl = Swig_method_decl(NULL, Getattr(n, "decl"), cxx_director_name, first_parm, 0, 0); - Printv(f_c_directors, cxx_director_name, "::", decl, "\n", NULL); - Delete(decl); - - Printv(f_c_directors, " : ", Getattr(parentNode(n), "classtype"), "(", NULL); - - p = parms; - for (int i = 0; i < parm_count; ++i) { - p = getParm(p); - if (i > 0) { - Printv(f_c_directors, ", ", NULL); - } - String *pn = Getattr(p, "name"); - assert(pn); - Printv(f_c_directors, pn, NULL); - p = nextParm(p); - } - Printv(f_c_directors, "),\n", NULL); - Printv(f_c_directors, " go_val(swig_p)\n", NULL); - Printv(f_c_directors, "{ }\n\n", NULL); - - if (Getattr(n, "sym:overloaded") && !Getattr(n, "sym:nextSibling")) { - int r = makeDispatchFunction(n, func_name, cn, is_static, Getattr(parentNode(n), "classtypeobj"), false); - if (r != SWIG_OK) { - return r; - } - } - - Delete(cxx_director_name); - Delete(go_name); - Delete(cn); - Delete(go_type_name); - Delete(director_struct_name); - Delete(fn_name); - Delete(func_name); - Delete(func_with_over_name); - Delete(wname); - Delete(first_type); - Delete(first_parm); - - return SWIG_OK; - } - - /* ------------------------------------------------------------ - * classDirectorDestructor - * - * Emit a destructor for a director class. - * ------------------------------------------------------------ */ - - int classDirectorDestructor(Node *n) { - if (!is_public(n)) { - return SWIG_OK; - } - - bool is_ignored = GetFlag(n, "feature:ignore") ? true : false; - - if (!is_ignored) { - String *fnname = NewString("DeleteDirector"); - String *c1 = exportedName(class_name); - Append(fnname, c1); - Delete(c1); - - String *wname = Swig_name_wrapper(fnname); - - Setattr(n, "wrap:name", fnname); - - Swig_DestructorToFunction(n, getNSpace(), getClassType(), CPlusPlus, Extend); - - ParmList *parms = Getattr(n, "parms"); - Setattr(n, "wrap:parms", parms); - - String *result = NewString("void"); - int r = makeWrappers(n, fnname, fnname, NULL, wname, NULL, parms, result, isStatic(n)); - if (r != SWIG_OK) { - return r; - } - - Delete(result); - Delete(fnname); - Delete(wname); - } - - // Generate the destructor for the C++ director class. Since the - // Go code is keeping a pointer to the C++ object, we need to call - // back to the Go code to let it know that the C++ object is gone. - - String *wname = NewString("_swiggo_wrap_DeleteDirector_"); - Append(wname, class_name); - - String *go_name = NewString("Swiggo_DeleteDirector_"); - Append(go_name, class_name); - - String *cn = exportedName(class_name); - - String *director_struct_name = NewString("_swig_Director"); - Append(director_struct_name, cn); - - Printv(f_c_directors_h, " virtual ~SwigDirector_", class_name, "()", NULL); - - String *throws = buildThrow(n); - if (throws) { - Printv(f_c_directors_h, " ", throws, NULL); - } - - Printv(f_c_directors_h, ";\n", NULL); - - if (!is_ignored) { - if (!gccgo_flag) { - Printv(f_c_directors, "extern \"C\" void ", wname, "(void*, int);\n", NULL); - } else { - Printv(f_c_directors, "extern \"C\" void ", wname, "(void*) __asm__(\"", go_prefix, ".", go_name, "\");\n", NULL); - } - } - - Printv(f_c_directors, "SwigDirector_", class_name, "::~SwigDirector_", class_name, "()", NULL); - - if (throws) { - Printv(f_c_directors, " ", throws, NULL); - Delete(throws); - } - - Printv(f_c_directors, "\n", NULL); - Printv(f_c_directors, "{\n", NULL); - - if (!is_ignored) { - if (!gccgo_flag) { - Printv(f_c_directors, " struct { void *p; } a;\n", NULL); - Printv(f_c_directors, " a.p = go_val;\n", NULL); - Printv(f_c_directors, " crosscall2(", wname, ", &a, (int) sizeof a);\n", NULL); - - Printv(f_gc_wrappers, "#pragma dynexport ", wname, " ", wname, "\n", NULL); - Printv(f_gc_wrappers, "#pragma cgo_export_static ", wname, " ", wname, "\n", NULL); - Printv(f_gc_wrappers, "#pragma textflag 7\n", NULL); - Printv(f_gc_wrappers, "extern void \xc2\xb7", go_name, "();\n", NULL); - Printv(f_gc_wrappers, "void\n", NULL); - Printv(f_gc_wrappers, wname, "(void *a, int32 n)\n", NULL); - Printv(f_gc_wrappers, "{\n", NULL); - Printv(f_gc_wrappers, "\truntime\xc2\xb7" "cgocallback(\xc2\xb7", go_name, ", a, n);\n", NULL); - Printv(f_gc_wrappers, "}\n\n", NULL); - } else { - Printv(f_c_directors, " ", wname, "(go_val);\n", NULL); - } - } - - Printv(f_c_directors, "}\n\n", NULL); - - if (!is_ignored) { - Printv(f_go_wrappers, "func ", go_name, "(p *", director_struct_name, ") {\n", NULL); - Printv(f_go_wrappers, "\tp.", class_receiver, " = 0\n", NULL); - Printv(f_go_wrappers, "}\n\n", NULL); - } - - Delete(wname); - Delete(go_name); - Delete(cn); - Delete(director_struct_name); - - return SWIG_OK; - } - - /* ------------------------------------------------------------ - * classDirectorMethod - * - * Emit a method for a director class, plus its overloads. - * ------------------------------------------------------------ */ - - int classDirectorMethod(Node *n, Node *parent, String *super) { - bool is_ignored = GetFlag(n, "feature:ignore") ? true : false; - - // We don't need explicit calls. - if (GetFlag(n, "explicitcall")) { - return SWIG_OK; - } - - String *name = Getattr(n, "sym:name"); - if (!name) { - assert(is_ignored); - name = Getattr(n, "name"); - } - - bool overloaded = Getattr(n, "sym:overloaded") && !Getattr(n, "explicitcallnode"); - if (!overloaded) { - int r = oneClassDirectorMethod(n, parent, super); - if (r != SWIG_OK) { - return r; - } - } else { - // Handle overloaded methods here, because otherwise we will - // reject them in the class_methods hash table. We need to use - // class_methods so that we correctly handle cases where a - // function in one class hides a function of the same name in a - // parent class. - if (!Getattr(class_methods, name)) { - for (Node *on = Getattr(n, "sym:overloaded"); on; on = Getattr(on, "sym:nextSibling")) { - // Swig_overload_rank expects wrap:name and wrap:parms to be - // set. - String *wn = Swig_name_wrapper(Getattr(on, "sym:name")); - Append(wn, Getattr(on, "sym:overname")); - Setattr(on, "wrap:name", wn); - Delete(wn); - Setattr(on, "wrap:parms", Getattr(on, "parms")); - } - } - - int r = oneClassDirectorMethod(n, parent, super); - if (r != SWIG_OK) { - return r; - } - - if (!Getattr(n, "sym:nextSibling")) - { - // Last overloaded function - Node *on = Getattr(n, "sym:overloaded"); - bool is_static = isStatic(on); - - String *cn = exportedName(Getattr(parent, "sym:name")); - String *go_name = buildGoName(name, is_static, false); - - String *director_struct_name = NewString("_swig_Director"); - Append(director_struct_name, cn); - - int r = makeDispatchFunction(on, go_name, director_struct_name, is_static, director_struct_name, false); - if (r != SWIG_OK) { - return r; - } - - if (!GetFlag(n, "abstract")) { - String *go_upcall = NewString("Director"); - Append(go_upcall, cn); - Append(go_upcall, go_name); - r = makeDispatchFunction(on, go_upcall, director_struct_name, is_static, director_struct_name, true); - if (r != SWIG_OK) { - return r; - } - Delete(go_upcall); - } - - Delete(director_struct_name); - Delete(go_name); - Delete(cn); - } - } - Setattr(class_methods, name, NewString("")); - - return SWIG_OK; - } - - /* ------------------------------------------------------------ - * oneClassDirectorMethod - * - * Emit a method for a director class. - * ------------------------------------------------------------ */ - - int oneClassDirectorMethod(Node *n, Node *parent, String *super) { - String *symname = Getattr(n, "sym:name"); - if (!checkFunctionVisibility(n, parent)) { - return SWIG_OK; - } - - bool is_ignored = GetFlag(n, "feature:ignore") ? true : false; - bool is_pure_virtual = (Cmp(Getattr(n, "storage"), "virtual") == 0 && Cmp(Getattr(n, "value"), "0") == 0); - - String *name = Getattr(n, "sym:name"); - if (!name) { - assert(is_ignored); - name = Getattr(n, "name"); - } - - String *overname = NULL; - if (Getattr(n, "sym:overloaded")) { - overname = Getattr(n, "sym:overname"); - } - - String *cn = exportedName(Getattr(parent, "sym:name")); - - String *go_type_name = goCPointerType(Getattr(parent, "classtypeobj"), true); - - String *director_struct_name = NewString("_swig_Director"); - Append(director_struct_name, cn); - - bool is_static = isStatic(n); - - String *go_name = buildGoName(name, is_static, false); - - ParmList *parms = Getattr(n, "parms"); - Setattr(n, "wrap:parms", parms); - - Wrapper *dummy = NewWrapper(); - emit_attach_parmmaps(parms, dummy); - DelWrapper(dummy); - - Swig_typemap_attach_parms("gotype", parms, NULL); - Swig_typemap_attach_parms("imtype", parms, NULL); - int parm_count = emit_num_arguments(parms); - - SwigType *result = Getattr(n, "type"); - - // Save the type for overload processing. - Setattr(n, "go:type", result); - - String *interface_name = NewString("_swig_DirectorInterface"); - Append(interface_name, cn); - Append(interface_name, go_name); - if (overname) { - Append(interface_name, overname); - } - - String *callback_name = Copy(director_struct_name); - Append(callback_name, "_callback_"); - Append(callback_name, name); - Replace(callback_name, "_swig", "Swig", DOH_REPLACE_FIRST); - if (overname) { - Append(callback_name, overname); - } - - String *callback_wname = Swig_name_wrapper(callback_name); - - String *upcall_name = Copy(director_struct_name); - Append(upcall_name, "_upcall_"); - Append(upcall_name, go_name); - - String *upcall_wname = Swig_name_wrapper(upcall_name); - if (overname) { - Append(upcall_wname, overname); - } - - String *upcall_gc_name = buildGoWrapperName(upcall_name, overname); - - String *go_with_over_name = Copy(go_name); - if (overname) { - Append(go_with_over_name, overname); - } - - Parm *p = 0; - Wrapper *w = NewWrapper(); - - Swig_director_parms_fixup(parms); - - Swig_typemap_attach_parms("directorin", parms, w); - Swig_typemap_attach_parms("directorargout", parms, w); - Swig_typemap_attach_parms("godirectorin", parms, w); - Swig_typemap_attach_parms("goin", parms, dummy); - Swig_typemap_attach_parms("goargout", parms, dummy); - - if (!is_ignored) { - // We use an interface to see if this method is defined in Go. - Printv(f_go_wrappers, "type ", interface_name, " interface {\n", NULL); - Printv(f_go_wrappers, "\t", go_with_over_name, "(", NULL); - - p = parms; - for (int i = 0; i < parm_count; ++i) { - p = getParm(p); - if (i > 0) { - Printv(f_go_wrappers, ", ", NULL); - } - String *tm = goType(p, Getattr(p, "type")); - Printv(f_go_wrappers, tm, NULL); - Delete(tm); - p = nextParm(p); - } - - Printv(f_go_wrappers, ")", NULL); - - if (SwigType_type(result) != T_VOID) { - String *tm = goType(n, result); - Printv(f_go_wrappers, " ", tm, NULL); - Delete(tm); - } - - Printv(f_go_wrappers, "\n", NULL); - Printv(f_go_wrappers, "}\n\n", NULL); - - if (!GetFlag(n, "abstract")) { - // Declare the upcall function, which calls the method on the - // parent class. - - if (!gccgo_flag) { - Printv(f_go_wrappers, "var ", upcall_wname, " unsafe.Pointer\n\n", NULL); - } else { - Printv(f_go_wrappers, "//extern ", go_prefix, "_", upcall_wname, "\n", NULL); - } - - Printv(f_go_wrappers, "func ", upcall_gc_name, "(_swig_ptr ", go_type_name, NULL); - - p = parms; - for (int i = 0; i < parm_count; ++i) { - p = getParm(p); - String *tm = goWrapperType(p, Getattr(p, "type"), false); - Printv(f_go_wrappers, ", _ ", tm, NULL); - Delete(tm); - p = nextParm(p); - } - - Printv(f_go_wrappers, ")", NULL); - - if (SwigType_type(result) != T_VOID) { - String *tm = goWrapperType(n, result, true); - Printv(f_go_wrappers, " (_swig_ret ", tm, ")", NULL); - Delete(tm); - } - - if (!gccgo_flag) { - Printv(f_go_wrappers, " {\n", NULL); - Printv(f_go_wrappers, "\t_swig_p := uintptr(unsafe.Pointer(&_swig_ptr))\n", NULL); - Printv(f_go_wrappers, "\t_cgo_runtime_cgocall(", upcall_wname, ", _swig_p)\n", NULL); - Printv(f_go_wrappers, "\treturn\n", NULL); - Printv(f_go_wrappers, "}", NULL); - } - - Printv(f_go_wrappers, "\n\n", NULL); - } - - // Define the method on the director class in Go. - - Printv(f_go_wrappers, "func (swig_p *", director_struct_name, ") ", go_with_over_name, "(", NULL); - - p = parms; - for (int i = 0; i < parm_count; ++i) { - p = getParm(p); - if (i > 0) { - Printv(f_go_wrappers, ", ", NULL); - } - Printv(f_go_wrappers, Getattr(p, "lname"), " ", NULL); - String *tm = goType(p, Getattr(p, "type")); - Printv(f_go_wrappers, tm, NULL); - Delete(tm); - p = nextParm(p); - } - - Printv(f_go_wrappers, ")", NULL); - - if (SwigType_type(result) != T_VOID) { - String *tm = goType(n, result); - Printv(f_go_wrappers, " ", tm, NULL); - Delete(tm); - } - - Printv(f_go_wrappers, " {\n", NULL); - - Printv(f_go_wrappers, "\tif swig_g, swig_ok := swig_p.v.(", interface_name, "); swig_ok {\n", NULL); - Printv(f_go_wrappers, "\t\t", NULL); - if (SwigType_type(result) != T_VOID) { - Printv(f_go_wrappers, "return ", NULL); - } - Printv(f_go_wrappers, "swig_g.", go_with_over_name, "(", NULL); - - p = parms; - for (int i = 0; i < parm_count; ++i) { - p = getParm(p); - if (i > 0) { - Printv(f_go_wrappers, ", ", NULL); - } - Printv(f_go_wrappers, Getattr(p, "lname"), NULL); - p = nextParm(p); - } - - Printv(f_go_wrappers, ")\n", NULL); - if (SwigType_type(result) == T_VOID) { - Printv(f_go_wrappers, "\t\treturn\n", NULL); - } - Printv(f_go_wrappers, "\t}\n", NULL); - - if (GetFlag(n, "abstract")) { - Printv(f_go_wrappers, "\tpanic(\"call to pure virtual method\")\n", NULL); - } else { - bool has_goout = false; - String *goout = NULL; - if (SwigType_type(result) != T_VOID) { - Printv(f_go_wrappers, "\tvar swig_r ", goImType(n, result), "\n", NULL); - goout = Swig_typemap_lookup("goout", n, "swig_r", NULL); - if (goout) { - has_goout = true; - } - } - - p = parms; - for (int i = 0; i < parm_count; ++i) { - p = getParm(p); - if (Getattr(p, "tmap:goargout")) { - has_goout = true; - } - p = nextParm(p); - } - - String *call = NewString(""); - - if (gccgo_flag) { - if (has_goout) { - Printv(call, "\tfunc() {\n", NULL); - } - Printv(call, "\tdefer SwigCgocallDone()\n", NULL); - Printv(call, "\tSwigCgocall()\n", NULL); - } - - Printv(call, "\t", NULL); - if (SwigType_type(result) != T_VOID) { - Printv(call, "swig_r = ", NULL); - } - Printv(call, upcall_gc_name, "(swig_p.", go_type_name, NULL); - - p = parms; - for (int i = 0; i < parm_count; ++i) { - Printv(call, ", ", NULL); - p = getParm(p); - SwigType *pt = Getattr(p, "type"); - - String *ln = Getattr(p, "lname"); - - // This is an ordinary call from Go to C++, so adjust using - // the goin typemap. - String *goin = Getattr(p, "tmap:goin"); - if (goin == NULL) { - Printv(call, ln, NULL); - if (goTypeIsInterface(p, pt)) { - Printv(call, ".Swigcptr()", NULL); - } - Setattr(p, "emit:goinput", ln); - } else { - String *ivar = NewString(""); - Printf(ivar, "_swig_i_%d", i); - String *itm = goImType(p, pt); - Printv(f_go_wrappers, "\tvar ", ivar, " ", itm, NULL); - goin = Copy(goin); - Replaceall(goin, "$input", ln); - Replaceall(goin, "$result", ivar); - Printv(f_go_wrappers, goin, NULL); - Delete(goin); - Printv(call, ivar, NULL); - Setattr(p, "emit:goinput", ivar); - } - - p = nextParm(p); - } - - Printv(call, ")\n", NULL); - - if (gccgo_flag && has_goout) { - Printv(call, "\t}()\n", NULL); - } - - Printv(f_go_wrappers, call, NULL); - Delete(call); - - goargout(parms, parm_count); - - if (SwigType_type(result) != T_VOID) { - if (goout == NULL) { - Printv(f_go_wrappers, "\treturn swig_r\n", NULL); - } else { - String *tm = goType(n, result); - Printv(f_go_wrappers, "\tvar swig_r_1 ", tm, "\n", NULL); - Replaceall(goout, "$input", "swig_r"); - Replaceall(goout, "$result", "swig_r_1"); - Printv(f_go_wrappers, goout, NULL); - Printv(f_go_wrappers, "\treturn swig_r_1\n", NULL); - } - } - } - - Printv(f_go_wrappers, "}\n\n", NULL); - - // Define a method in the C++ director class that the C++ upcall - // function can call. This permits an upcall to a protected - // method. - - if (!GetFlag(n, "abstract")) { - String *upcall_method_name = NewString("_swig_upcall_"); - Append(upcall_method_name, name); - if (overname) { - Append(upcall_method_name, overname); - } - SwigType *rtype = Getattr(n, "classDirectorMethods:type"); - String *upcall_decl = Swig_method_decl(rtype, Getattr(n, "decl"), upcall_method_name, parms, 0, 0); - Printv(f_c_directors_h, " ", upcall_decl, " {\n", NULL); - Delete(upcall_decl); - - Printv(f_c_directors_h, " ", NULL); - if (SwigType_type(result) != T_VOID) { - Printv(f_c_directors_h, "return ", NULL); - } - - String *super_call = Swig_method_call(super, parms); - Printv(f_c_directors_h, super_call, ";\n", NULL); - Delete(super_call); - - Printv(f_c_directors_h, " }\n", NULL); - - // Define the C++ function that the Go function calls. - - SwigType *first_type = NULL; - Parm *first_parm = parms; - if (!is_static) { - first_type = NewString("SwigDirector_"); - Append(first_type, class_name); - SwigType_add_pointer(first_type); - first_parm = NewParm(first_type, "p", n); - set_nextSibling(first_parm, parms); - } - - Swig_save("classDirectorMethod", n, "wrap:name", "wrap:action", NULL); - - Setattr(n, "wrap:name", upcall_wname); - - String *action = NewString(""); - if (SwigType_type(result) != T_VOID) { - Printv(action, Swig_cresult_name(), " = (", SwigType_lstr(result, 0), ")", NULL); - if (SwigType_isreference(result)) { - Printv(action, "&", NULL); - } - } - Printv(action, Swig_cparm_name(NULL, 0), "->", upcall_method_name, "(", NULL); - - p = parms; - int i = 0; - while (p != NULL) { - if (SwigType_type(Getattr(p, "type")) != T_VOID) { - String *pname = Swig_cparm_name(NULL, i + 1); - if (i > 0) { - Printv(action, ", ", NULL); - } - - // A parameter whose type is a reference is converted into a - // pointer type by gcCTypeForGoValue. We are calling a - // function which expects a reference so we need to convert - // back. - if (SwigType_isreference(Getattr(p, "type"))) { - Printv(action, "*", NULL); - } - - Printv(action, pname, NULL); - Delete(pname); - i++; - } - p = nextSibling(p); - } - Printv(action, ");", NULL); - Setattr(n, "wrap:action", action); - - if (!gccgo_flag) { - // Write the upcall wrapper function. This is compiled by gc - // and calls the C++ function. - int r = gcFunctionWrapper(upcall_wname); - if (r != SWIG_OK) { - return r; - } - r = gccFunctionWrapper(n, NULL, upcall_wname, first_parm, result); - if (r != SWIG_OK) { - return r; - } - } else { - int r = gccgoFunctionWrapper(n, NULL, upcall_wname, first_parm, result); - if (r != SWIG_OK) { - return r; - } - } - - Delete(first_type); - if (first_parm != parms) { - Delete(first_parm); - } - - Swig_restore(n); - Delete(upcall_method_name); - - // Define a function that uses the Go director type that other - // methods in the Go type can call to get parent methods. - - Printv(f_go_wrappers, "func Director", cn, go_with_over_name, "(p ", cn, NULL); - - p = parms; - for (int i = 0; i < parm_count; ++i) { - p = getParm(p); - Printv(f_go_wrappers, ", ", Getattr(p, "lname"), " ", NULL); - String *tm = goType(p, Getattr(p, "type")); - Printv(f_go_wrappers, tm, NULL); - Delete(tm); - p = nextParm(p); - } - - Printv(f_go_wrappers, ")", NULL); - - if (SwigType_type(result) != T_VOID) { - String *tm = goType(n, result); - Printv(f_go_wrappers, " ", tm, NULL); - Delete(tm); - } - - Printv(f_go_wrappers, " {\n", NULL); - - String *goout = NULL; - if (SwigType_type(result) != T_VOID) { - Printv(f_go_wrappers, "\tvar swig_r ", goImType(n, result), "\n", NULL); - goout = Swig_typemap_lookup("goout", n, "swig_r", NULL); - } - - String *call = NewString(""); - - if (gccgo_flag) { - if (goout != NULL) { - Printv(call, "\tfunc() {\n", NULL); - } - Printv(call, "\tdefer SwigCgocallDone()\n", NULL); - Printv(call, "\tSwigCgocall()\n", NULL); - } - - Printv(call, "\t", NULL); - if (SwigType_type(result) != T_VOID) { - Printv(call, "swig_r = ", NULL); - } - Printv(call, upcall_gc_name, "(p.(*", director_struct_name, ").", go_type_name, NULL); - - p = parms; - for (int i = 0; i < parm_count; ++i) { - Printv(call, ", ", NULL); - p = getParm(p); - SwigType *pt = Getattr(p, "type"); - - String *ln = Copy(Getattr(p, "lname")); - if (goTypeIsInterface(p, pt)) { - Printv(ln, ".Swigcptr()", NULL); - } - - String *goin = Getattr(p, "tmap:goin"); - if (goin == NULL) { - Printv(call, ln, NULL); - Setattr(p, "emit:goinput", ln); - } else { - String *ivar = NewString(""); - Printf(ivar, "_swig_i_%d", i); - String *itm = goImType(p, pt); - Printv(f_go_wrappers, "\tvar ", ivar, " ", itm, NULL); - goin = Copy(goin); - Replaceall(goin, "$input", ln); - Replaceall(goin, "$result", ivar); - Printv(f_go_wrappers, goin, NULL); - Delete(goin); - Printv(call, ivar, NULL); - Setattr(p, "emit:goinput", ivar); - } - - Delete(ln); - - p = nextParm(p); - } - - Printv(call, ")\n", NULL); - - if (gccgo_flag && goout != NULL) { - Printv(call, "\t}()\n", NULL); - } - - Printv(f_go_wrappers, call, NULL); - Delete(call); - - goargout(parms, parm_count); - - if (SwigType_type(result) != T_VOID) { - if (goout == NULL) { - Printv(f_go_wrappers, "\treturn swig_r\n", NULL); - } else { - String *tm = goType(n, result); - Printv(f_go_wrappers, "\tvar swig_r_1 ", tm, "\n", NULL); - Replaceall(goout, "$input", "swig_r"); - Replaceall(goout, "$result", "swig_r_1"); - Printv(f_go_wrappers, goout, NULL); - Printv(f_go_wrappers, "\treturn swig_r_1\n", NULL); - } - } - - Printv(f_go_wrappers, "}\n\n", NULL); - } - - // The Go function which invokes the method. This is called - // from by the C++ method on the director class. - - Printv(f_go_wrappers, "func ", callback_name, "(p *", director_struct_name, NULL); - - p = parms; - for (int i = 0; i < parm_count; ++i) { - p = getParm(p); - String *tm = goWrapperType(p, Getattr(p, "type"), false); - Printv(f_go_wrappers, ", ", Getattr(p, "lname"), " ", tm, NULL); - Delete(tm); - p = nextParm(p); - } - - Printv(f_go_wrappers, ") ", NULL); - String *result_wrapper = NULL; - if (SwigType_type(result) != T_VOID) { - result_wrapper = goWrapperType(n, result, true); - Printv(f_go_wrappers, "(swig_result ", result_wrapper, ") ", NULL); - } - Printv(f_go_wrappers, "{\n", NULL); - - if (is_ignored) { - Printv(f_go_wrappers, "\treturn\n", NULL); - } else { - bool result_is_interface = false; - String *goout = NULL; - if (SwigType_type(result) != T_VOID) { - result_is_interface = goTypeIsInterface(NULL, result); - Printv(f_go_wrappers, "\tvar swig_r ", NULL); - if (!result_is_interface) { - Printv(f_go_wrappers, goType(n, result), NULL); - } else { - Printv(f_go_wrappers, result_wrapper, NULL); - } - Printv(f_go_wrappers, "\n", NULL); - goout = Swig_typemap_lookup("godirectorout", n, "swig_r", NULL); - } - - String *call = NewString(""); - - if (gccgo_flag) { - if (goout != NULL) { - Printv(call, "\tfunc() {\n", NULL); - } - Printv(call, "\tSwigCgocallBack()\n", NULL); - Printv(call, "\tdefer SwigCgocallBackDone()\n", NULL); - } - - Printv(call, "\t", NULL); - - if (SwigType_type(result) != T_VOID) { - Printv(call, "swig_r = ", NULL); - if (result_is_interface) { - Printv(call, result_wrapper, "(", NULL); - } - } - Printv(call, "p.", go_with_over_name, "(", NULL); - - p = parms; - for (int i = 0; i < parm_count; ++i) { - p = getParm(p); - if (i > 0) { - Printv(call, ", ", NULL); - } - SwigType *pt = Getattr(p, "type"); - - String *ln = NewString(""); - - // If the Go representation is an interface type class, then - // we are receiving a uintptr, and must convert to the - // interface. - bool is_interface = goTypeIsInterface(p, pt); - if (is_interface) { - // Passing is_result as true to goWrapperType gives us the - // name of the Go type we need to convert to an interface. - String *wt = goWrapperType(p, pt, true); - Printv(ln, wt, "(", NULL); - Delete(wt); - } - - Printv(ln, Getattr(p, "lname"), NULL); - - if (is_interface) { - Printv(ln, ")", NULL); - } - - String *goin = Getattr(p, "tmap:godirectorin"); - if (goin == NULL) { - Printv(call, ln, NULL); - } else { - String *ivar = NewString(""); - Printf(ivar, "_swig_i_%d", i); - String *itm = goType(p, pt); - Printv(f_go_wrappers, "\tvar ", ivar, " ", itm, NULL); - goin = Copy(goin); - Replaceall(goin, "$input", ln); - Replaceall(goin, "$result", ivar); - Printv(f_go_wrappers, goin, NULL); - Delete(goin); - Printv(call, ivar, NULL); - Delete(ivar); - } - - Delete(ln); - - p = nextParm(p); - } - - Printv(call, ")", NULL); - - if (result_is_interface) { - Printv(call, ".Swigcptr())", NULL); - } - Printv(call, "\n", NULL); - - if (gccgo_flag && goout != NULL) { - Printv(call, "\t}()\n", NULL); - } - - Printv(f_go_wrappers, call, NULL); - Delete(call); - - if (SwigType_type(result) != T_VOID) { - if (goout == NULL) { - Printv(f_go_wrappers, "\treturn swig_r\n", NULL); - } else { - String *tm = goImType(n, result); - Printv(f_go_wrappers, "\tvar swig_r_1 ", tm, "\n", NULL); - Replaceall(goout, "$input", "swig_r"); - Replaceall(goout, "$result", "swig_r_1"); - Printv(f_go_wrappers, goout, NULL); - Printv(f_go_wrappers, "\treturn swig_r_1\n", NULL); - } - } - } - - Printv(f_go_wrappers, "}\n\n", NULL); - - Delete(result_wrapper); - - Delete(upcall_wname); - Delete(upcall_gc_name); - - // Build the C++ functions. - - if (!gccgo_flag) { - Printv(f_c_directors, "extern \"C\" void ", callback_wname, "(void*, int);\n", NULL); - } else { - Printv(f_c_directors, "extern \"C\" ", NULL); - - String *fnname = NewString(""); - Printv(fnname, callback_wname, "(void*", NULL); - - p = parms; - while (p) { - while (checkAttribute(p, "tmap:directorin:numinputs", "0")) { - p = Getattr(p, "tmap:directorin:next"); - } - String *cg = gccgoCTypeForGoValue(p, Getattr(p, "type"), - Getattr(p, "lname")); - Printv(fnname, ", ", cg, NULL); - Delete(cg); - p = Getattr(p, "tmap:directorin:next"); - } - - Printv(fnname, ")", NULL); - - if (SwigType_type(result) == T_VOID) { - Printv(f_c_directors, "void ", fnname, NULL); - } else { - String *tm = gccgoCTypeForGoValue(n, result, fnname); - Printv(f_c_directors, tm, NULL); - Delete(tm); - } - - Delete(fnname); - - Printv(f_c_directors, " __asm__(\"", go_prefix, ".", callback_name, "\");\n", NULL); - } - - Delete(go_with_over_name); - } - - if (!is_ignored || is_pure_virtual) { - // Declare the method for the director class. - - SwigType *rtype = Getattr(n, "conversion_operator") ? 0 : Getattr(n, "classDirectorMethods:type"); - String *decl = Swig_method_decl(rtype, Getattr(n, "decl"), Getattr(n, "name"), parms, 0, 0); - Printv(f_c_directors_h, " virtual ", decl, NULL); - Delete(decl); - - String *qname = NewString(""); - Printv(qname, "SwigDirector_", class_name, "::", Getattr(n, "name"), NULL); - decl = Swig_method_decl(rtype, Getattr(n, "decl"), qname, parms, 0, 0); - Printv(w->def, decl, NULL); - Delete(decl); - Delete(qname); - - String *throws = buildThrow(n); - if (throws) { - Printv(f_c_directors_h, " ", throws, NULL); - Printv(w->def, " ", throws, NULL); - Delete(throws); - } - - Printv(f_c_directors_h, ";\n", NULL); - - Printv(w->def, " {\n", NULL); - - if (SwigType_type(result) != T_VOID) { - Wrapper_add_local(w, "c_result", SwigType_lstr(result, "c_result")); - } - - if (!is_ignored) { - if (!gccgo_flag) { - Printv(w->code, " struct {\n", NULL); - Printv(w->code, " void *go_val;\n", NULL); - - p = parms; - while (p) { - while (checkAttribute(p, "tmap:directorin:numinputs", "0")) { - p = Getattr(p, "tmap:directorin:next"); - } - String *ln = Getattr(p, "lname"); - String *cg = gcCTypeForGoValue(p, Getattr(p, "type"), ln); - Printv(w->code, " ", cg, ";\n", NULL); - Delete(cg); - p = Getattr(p, "tmap:directorin:next"); - } - if (SwigType_type(result) != T_VOID) { - Printv(w->code, " long : 0;\n", NULL); - String *rname = NewString(Swig_cresult_name()); - String *cg = gcCTypeForGoValue(n, result, rname); - Printv(w->code, " ", cg, ";\n", NULL); - Delete(cg); - Delete(rname); - } - - Printv(w->code, " } swig_a;\n", NULL); - Printv(w->code, " swig_a.go_val = go_val;\n", NULL); - - p = parms; - while (p) { - while (checkAttribute(p, "tmap:directorin:numinputs", "0")) { - p = Getattr(p, "tmap:directorin:next"); - } - String *tm = Getattr(p, "tmap:directorin"); - if (!tm) { - Swig_warning(WARN_TYPEMAP_DIRECTORIN_UNDEF, input_file, - line_number, "Unable to use type %s as director method argument\n", SwigType_str(Getattr(p, "type"), 0)); - } else { - tm = Copy(tm); - String *ln = Getattr(p, "lname"); - String *input = NewString(""); - Printv(input, "swig_a.", ln, NULL); - Setattr(p, "emit:directorinput", input); - Replaceall(tm, "$input", input); - Replaceall(tm, "$owner", "0"); - Delete(input); - Printv(w->code, "\t", tm, "\n", NULL); - Delete(tm); - } - p = Getattr(p, "tmap:directorin:next"); - } - - Printv(w->code, " crosscall2(", callback_wname, ", &swig_a, (int) sizeof swig_a);\n", NULL); - - /* Marshal outputs */ - for (p = parms; p;) { - String *tm; - if ((tm = Getattr(p, "tmap:directorargout"))) { - tm = Copy(tm); - Replaceall(tm, "$result", "jresult"); - Replaceall(tm, "$input", Getattr(p, "emit:directorinput")); - Printv(w->code, tm, "\n", NIL); - Delete(tm); - p = Getattr(p, "tmap:directorargout:next"); - } else { - p = nextSibling(p); - } - } - - if (SwigType_type(result) != T_VOID) { - String *result_str = NewString("c_result"); - String *tm = Swig_typemap_lookup("directorout", n, result_str, NULL); - if (!tm) { - Swig_warning(WARN_TYPEMAP_DIRECTOROUT_UNDEF, input_file, line_number, - "Unable to use type %s as director method result\n", SwigType_str(result, 0)); - } else { - static const String *swig_a_result = NewStringf("swig_a.%s", Swig_cresult_name()); - Replaceall(tm, "$input", swig_a_result); - Replaceall(tm, "$result", "c_result"); - Printv(w->code, " ", tm, "\n", NULL); - String *retstr = SwigType_rcaststr(result, "c_result"); - Printv(w->code, " return ", retstr, ";\n", NULL); - Delete(retstr); - Delete(tm); - } - Delete(result_str); - } - - // The C wrapper code which calls the Go function. - Printv(f_gc_wrappers, "#pragma dynexport ", callback_wname, " ", callback_wname, "\n", NULL); - Printv(f_gc_wrappers, "#pragma cgo_export_static ", callback_wname, " ", callback_wname, "\n", NULL); - Printv(f_gc_wrappers, "#pragma textflag 7\n", NULL); - Printv(f_gc_wrappers, "extern void \xc2\xb7", callback_name, "();\n", NULL); - Printv(f_gc_wrappers, "void\n", NULL); - Printv(f_gc_wrappers, callback_wname, "(void *a, int32 n)\n", NULL); - Printv(f_gc_wrappers, "{\n", NULL); - Printv(f_gc_wrappers, "\truntime\xc2\xb7" "cgocallback(\xc2\xb7", callback_name, ", a, n);\n", NULL); - Printv(f_gc_wrappers, "}\n\n", NULL); - } else { - if (SwigType_type(result) != T_VOID) { - String *r = NewString(Swig_cresult_name()); - String *tm = gccgoCTypeForGoValue(n, result, r); - Wrapper_add_local(w, r, tm); - Delete(tm); - Delete(r); - } - - String *args = NewString(""); - - p = parms; - while (p) { - while (checkAttribute(p, "tmap:directorin:numinputs", "0")) { - p = Getattr(p, "tmap:directorin:next"); - } - - String *pn = NewString("g"); - Append(pn, Getattr(p, "lname")); - Setattr(p, "emit:directorinput", pn); - - String *tm = gccgoCTypeForGoValue(n, Getattr(p, "type"), pn); - Wrapper_add_local(w, pn, tm); - Delete(tm); - - tm = Getattr(p, "tmap:directorin"); - if (!tm) { - Swig_warning(WARN_TYPEMAP_DIRECTORIN_UNDEF, input_file, - line_number, "Unable to use type %s as director method argument\n", SwigType_str(Getattr(p, "type"), 0)); - } else { - tm = Copy(tm); - Replaceall(tm, "$input", pn); - Replaceall(tm, "$owner", 0); - Printv(w->code, " ", tm, "\n", NULL); - Delete(tm); - - Printv(args, ", ", pn, NULL); - } - - p = Getattr(p, "tmap:directorin:next"); - } - - Printv(w->code, " ", NULL); - if (SwigType_type(result) != T_VOID) { - Printv(w->code, Swig_cresult_name(), " = ", NULL); - } - Printv(w->code, callback_wname, "(go_val", args, ");\n", NULL); - - /* Marshal outputs */ - for (p = parms; p;) { - String *tm; - if ((tm = Getattr(p, "tmap:directorargout"))) { - tm = Copy(tm); - Replaceall(tm, "$result", "jresult"); - Replaceall(tm, "$input", Getattr(p, "emit:directorinput")); - Printv(w->code, tm, "\n", NIL); - Delete(tm); - p = Getattr(p, "tmap:directorargout:next"); - } else { - p = nextSibling(p); - } - } - - if (SwigType_type(result) != T_VOID) { - String *result_str = NewString("c_result"); - String *tm = Swig_typemap_lookup("directorout", n, result_str, NULL); - if (!tm) { - Swig_warning(WARN_TYPEMAP_DIRECTOROUT_UNDEF, input_file, line_number, - "Unable to use type %s as director method result\n", SwigType_str(result, 0)); - } else { - Replaceall(tm, "$input", Swig_cresult_name()); - Replaceall(tm, "$result", "c_result"); - Printv(w->code, " ", tm, "\n", NULL); - String *retstr = SwigType_rcaststr(result, "c_result"); - Printv(w->code, " return ", retstr, ";\n", NULL); - Delete(retstr); - Delete(tm); - } - Delete(result_str); - } - } - } else { - assert(is_pure_virtual); - Printv(w->code, " _swig_gopanic(\"call to pure virtual function ", Getattr(parent, "sym:name"), name, "\");\n", NULL); - if (SwigType_type(result) != T_VOID) { - String *retstr = SwigType_rcaststr(result, "c_result"); - Printv(w->code, " return ", retstr, ";\n", NULL); - Delete(retstr); - } - } - - Printv(w->code, "}", NULL); - - Replaceall(w->code, "$symname", symname); - Wrapper_print(w, f_c_directors); - } - - Delete(cn); - Delete(go_type_name); - Delete(director_struct_name); - Delete(interface_name); - Delete(upcall_name); - Delete(callback_wname); - Delete(go_name); - DelWrapper(w); - - return SWIG_OK; - } - - /* ------------------------------------------------------------ - * classDirectorEnd - * - * Complete support for a director class. - * ------------------------------------------------------------ */ - - int classDirectorEnd(Node *n) { - (void) n; - - Printv(f_c_directors_h, " private:\n", NULL); - Printv(f_c_directors_h, " void *go_val;\n", NULL); - Printv(f_c_directors_h, "};\n\n", NULL); - - class_name = NULL; - class_node = NULL; - - Delete(class_receiver); - class_receiver = NULL; - - Delete(class_methods); - class_methods = NULL; - - return SWIG_OK; - } - - /* ------------------------------------------------------------ - * classDirectorDisown - * - * I think Go does not require a disown method. - * ------------------------------------------------------------ */ - - int classDirectorDisown(Node *n) { - (void) n; - return SWIG_OK; - } - - /*---------------------------------------------------------------------- - * buildThrow() - * - * Build and return a throw clause if needed. - *--------------------------------------------------------------------*/ - - String *buildThrow(Node *n) { - ParmList *throw_parm_list = Getattr(n, "throws"); - if (!throw_parm_list && !Getattr(n, "throw")) - return NULL; - String *ret = NewString("throw("); - if (throw_parm_list) { - Swig_typemap_attach_parms("throws", throw_parm_list, NULL); - } - bool first = true; - for (Parm *p = throw_parm_list; p; p = nextSibling(p)) { - if (Getattr(p, "tmap:throws")) { - if (first) { - first = false; - } else { - Printv(ret, ", ", NULL); - } - String *s = SwigType_str(Getattr(p, "type"), 0); - Printv(ret, s, NULL); - Delete(s); - } - } - Printv(ret, ")", NULL); - return ret; - } - - /*---------------------------------------------------------------------- - * extraDirectorProtectedCPPMethodsRequired() - * - * We don't need to check upcall when calling methods. - *--------------------------------------------------------------------*/ - - bool extraDirectorProtectedCPPMethodsRequired() const { - return false; - } - - /*---------------------------------------------------------------------- - * makeDispatchFunction - * - * Make a dispatch function for an overloaded C++ function. The - * receiver parameter is the receiver for a method, unless is_upcall - * is true. If is_upcall is true, then the receiver parameter is - * the type of the first argument to the function. - *--------------------------------------------------------------------*/ - - int makeDispatchFunction(Node *n, String *go_name, String *receiver, bool is_static, SwigType *director_struct, bool is_upcall) { - bool is_director = director_struct ? true : false; - - String *nodetype = Getattr(n, "nodeType"); - bool is_constructor = Cmp(nodetype, "constructor") == 0; - bool is_destructor = Cmp(nodetype, "destructor") == 0; - - bool can_use_receiver = (!is_constructor && !is_destructor && !is_upcall); - - bool use_receiver = (!is_static && can_use_receiver); - - bool add_to_interface = (interfaces && !is_constructor && !is_destructor && !is_static && !is_upcall); - - List *dispatch = Swig_overload_rank(n, false); - int nfunc = Len(dispatch); - - SwigType *all_result; - bool mismatch; - if (is_constructor) { - assert(!is_upcall); - if (!is_director) { - all_result = Copy(Getattr(class_node, "classtypeobj")); - } else { - all_result = Copy(director_struct); - } - mismatch = false; - } else { - all_result = NULL; - mismatch = false; - bool any_void = false; - for (int i = 0; i < nfunc; ++i) { - Node *nn = Getitem(dispatch, i); - Node *ni = Getattr(nn, "directorNode") ? Getattr(nn, "directorNode") : nn; - SwigType *result = Getattr(ni, "go:type"); - assert(result); - - if (SwigType_type(result) == T_VOID) { - if (all_result) { - mismatch = true; - } - any_void = true; - } else { - if (any_void) { - mismatch = true; - } else if (!all_result) { - all_result = Copy(result); - } else if (Cmp(result, all_result) != 0) { - mismatch = true; - } - } - } - if (mismatch) { - Delete(all_result); - all_result = NULL; - } else if (all_result) { - ; - } else { - all_result = NewString("void"); - } - } - - Printv(f_go_wrappers, "func ", NULL); - - if (receiver && use_receiver) { - Printv(f_go_wrappers, "(p ", receiver, ") ", NULL); - } - - Printv(f_go_wrappers, go_name, "(", NULL); - if (is_director && is_constructor) { - Printv(f_go_wrappers, "abi interface{}, ", NULL); - assert(!add_to_interface); - } - if (is_upcall) { - Printv(f_go_wrappers, "p *", receiver, ", ", NULL); - assert(!add_to_interface); - } - Printv(f_go_wrappers, "a ...interface{})", NULL); - - if (add_to_interface) { - Printv(interfaces, "\t", go_name, "(a ...interface{})", NULL); - } - - if (mismatch) { - Printv(f_go_wrappers, " interface{}", NULL); - if (add_to_interface) { - Printv(interfaces, " interface{}", NULL); - } - } else if (all_result && SwigType_type(all_result) != T_VOID) { - if (is_director && is_constructor) { - Printv(f_go_wrappers, " ", receiver, NULL); - if (add_to_interface) { - Printv(interfaces, " ", receiver, NULL); - } - } else { - String *tm = goType(n, all_result); - Printv(f_go_wrappers, " ", tm, NULL); - if (add_to_interface) { - Printv(interfaces, " ", tm, NULL); - } - Delete(tm); - } - } - Printv(f_go_wrappers, " {\n", NULL); - if (add_to_interface) { - Printv(interfaces, "\n", NULL); - } - - Printv(f_go_wrappers, "\targc := len(a)\n", NULL); - - for (int i = 0; i < nfunc; ++i) { - int fn = 0; - Node *nn = Getitem(dispatch, i); - Node *ni = Getattr(nn, "directorNode") ? Getattr(nn, "directorNode") : nn; - Parm *pi = Getattr(ni, "wrap:parms"); - - // If we are using a receiver, we want to ignore a leading self - // parameter. Because of the way this is called, there may or - // may not be a self parameter at this point. - if (use_receiver && pi && Getattr(pi, "self")) { - pi = getParm(pi); - if (pi) { - pi = nextParm(pi); - } - } - - int num_required = emit_num_required(pi); - int num_arguments = emit_num_arguments(pi); - bool varargs = emit_isvarargs(pi) ? true : false; - - if (varargs) { - Printf(f_go_wrappers, "\tif argc >= %d {\n", num_required); - } else { - if (num_required == num_arguments) { - Printf(f_go_wrappers, "\tif argc == %d {\n", num_required); - } else { - Printf(f_go_wrappers, "\tif argc >= %d && argc <= %d {\n", num_required, num_arguments); - } - } - - // Build list of collisions with the same number of arguments. - List *coll = NewList(); - for (int k = i + 1; k < nfunc; ++k) { - Node *nnk = Getitem(dispatch, k); - Node *nk = Getattr(nnk, "directorNode") ? Getattr(nnk, "directorNode") : nnk; - Parm *pk = Getattr(nk, "wrap:parms"); - if (use_receiver && pk && Getattr(pk, "self")) { - pk = getParm(pk); - if (pk) { - pk = nextParm(pk); - } - } - int nrk = emit_num_required(pk); - int nak = emit_num_arguments(pk); - if ((nrk >= num_required && nrk <= num_arguments) - || (nak >= num_required && nak <= num_arguments) - || (nrk <= num_required && nak >= num_arguments) - || (varargs && nrk >= num_required)) { - Append(coll, nk); - } - } - - int num_braces = 0; - if (Len(coll) > 0 && num_arguments > 0) { - int j = 0; - Parm *pj = pi; - while (pj) { - pj = getParm(pj); - if (!pj) { - break; - } - - // If all the wrappers have the same type in this position, - // we can omit the check. - SwigType *tm = goWrapperType(pj, Getattr(pj, "type"), true); - bool emitcheck = false; - for (int k = 0; k < Len(coll) && !emitcheck; ++k) { - Node *nk = Getitem(coll, k); - Parm *pk = Getattr(nk, "wrap:parms"); - if (use_receiver && pk && Getattr(pk, "self")) { - pk = getParm(pk); - if (pk) { - pk = nextParm(pk); - } - } - int nak = emit_num_arguments(pk); - if (nak <= j) - continue; - int l = 0; - Parm *pl = pk; - while (pl && l <= j) { - pl = getParm(pl); - if (!pl) { - break; - } - if (l == j) { - SwigType *tml = goWrapperType(pl, Getattr(pl, "type"), true); - if (Cmp(tm, tml) != 0) { - emitcheck = true; - } - Delete(tml); - } - pl = nextParm(pl); - ++l; - } - } - - if (emitcheck) { - if (j >= num_required) { - Printf(f_go_wrappers, "\t\tif argc > %d {\n", j); - ++num_braces; - } - - fn = i + 1; - Printf(f_go_wrappers, "\t\tif _, ok := a[%d].(%s); !ok {\n", j, tm); - Printf(f_go_wrappers, "\t\t\tgoto check_%d\n", fn); - Printv(f_go_wrappers, "\t\t}\n", NULL); - } - - Delete(tm); - - pj = nextParm(pj); - - ++j; - } - } - - for (; num_braces > 0; --num_braces) { - Printv(f_go_wrappers, "\t\t}\n", NULL); - } - - // We may need to generate multiple calls if there are variable - // argument lists involved. Build the start of the call. - - String *start = NewString(""); - - SwigType *result = Getattr(ni, "go:type"); - - if (is_constructor) { - result = all_result; - } else if (is_destructor) { - result = NULL; - } - - if (result && SwigType_type(result) != T_VOID && (!all_result || SwigType_type(all_result) != T_VOID)) { - Printv(start, "return ", NULL); - } - - bool advance_parm = false; - - if (receiver && use_receiver) { - Printv(start, "p.", go_name, NULL); - } else if (can_use_receiver && !isStatic(ni) && pi && Getattr(pi, "self")) { - // This is an overload of a static function and a non-static - // function. - assert(num_required > 0); - SwigType *tm = goWrapperType(pi, Getattr(pi, "type"), true); - String *nm = buildGoName(Getattr(ni, "sym:name"), false, isFriend(ni)); - Printv(start, "a[0].(", tm, ").", nm, NULL); - Delete(nm); - Delete(tm); - advance_parm = true; - } else { - Printv(start, go_name, NULL); - } - - Printv(start, Getattr(ni, "sym:overname"), "(", NULL); - - bool need_comma = false; - - if (is_director && is_constructor) { - Printv(start, "abi", NULL); - need_comma = true; - } - if (is_upcall) { - Printv(start, "p", NULL); - need_comma = true; - } - Parm *p = pi; - int pn = 0; - if (advance_parm) { - p = getParm(p); - if (p) { - p = nextParm(p); - } - ++pn; - } - while (pn < num_required) { - p = getParm(p); - - if (need_comma) { - Printv(start, ", ", NULL); - } - - SwigType *tm = goType(p, Getattr(p, "type")); - Printf(start, "a[%d].(%s)", pn, tm); - Delete(tm); - - need_comma = true; - ++pn; - p = nextParm(p); - } - - String *end = NULL; - if (!result || SwigType_type(result) == T_VOID || (all_result && SwigType_type(all_result) == T_VOID)) { - end = NewString(""); - Printv(end, "return", NULL); - if (!all_result || SwigType_type(all_result) != T_VOID) { - Printv(end, " 0", NULL); - } - } - - if (num_required == num_arguments) { - Printv(f_go_wrappers, "\t\t", start, ")\n", NULL); - if (end) { - Printv(f_go_wrappers, "\t\t", end, "\n", NULL); - } - } else { - Printv(f_go_wrappers, "\t\tswitch argc {\n", NULL); - for (int j = num_required; j <= num_arguments; ++j) { - Printf(f_go_wrappers, "\t\tcase %d:\n", j); - Printv(f_go_wrappers, "\t\t\t", start, NULL); - bool nc = need_comma; - for (int k = num_required; k < j; ++k) { - if (nc) { - Printv(f_go_wrappers, ", ", NULL); - } - Printf(f_go_wrappers, "a[%d]", k); - nc = true; - } - Printv(f_go_wrappers, ")\n", NULL); - if (end) { - Printv(f_go_wrappers, "\t\t\t", end, "\n", NULL); - } - } - Printv(f_go_wrappers, "\t\t}\n", NULL); - } - - Printv(f_go_wrappers, "\t}\n", NULL); - - if (fn != 0) { - Printf(f_go_wrappers, "check_%d:\n", fn); - } - - Delete(coll); - } - - Printv(f_go_wrappers, "\tpanic(\"No match for overloaded function call\")\n", NULL); - Printv(f_go_wrappers, "}\n\n", NULL); - - Delete(all_result); - Delete(dispatch); - - return SWIG_OK; - } - - /* ---------------------------------------------------------------------- - * checkFunctionVisibility() - * - * Return true if we should write out a function based on its - * visibility, false otherwise. - * ---------------------------------------------------------------------- */ - - bool checkFunctionVisibility(Node *n, Node *parent) { - // Write out a public function. - if (is_public(n)) - return true; - // Don't write out a private function. - if (is_private(n)) - return false; - // Write a protected function for a director class in - // dirprot_mode. - if (parent == NULL) { - return false; - } - if (dirprot_mode() && Swig_directorclass(parent)) - return true; - // Otherwise don't write out a protected function. - return false; - } - - - /* ---------------------------------------------------------------------- - * exportedName() - * - * Given a C/C++ name, return a name in Go which will be exported. - * If the first character is an upper case letter, this returns a - * copy of its argment. If the first character is a lower case - * letter, this forces it to upper case. Otherwise, this prepends - * 'X'. - * ---------------------------------------------------------------------- */ - - String *exportedName(String *name) { - String *copy = Copy(name); - char c = *Char(copy); - if (islower(c)) { - char l[2]; - char u[2]; - l[0] = c; - l[1] = '\0'; - u[0] = toupper(c); - u[1] = '\0'; - Replace(copy, l, u, DOH_REPLACE_FIRST); - } else if (!isalpha(c)) { - char l[2]; - char u[3]; - l[0] = c; - l[1] = '\0'; - u[0] = 'X'; - u[1] = c; - u[2] = '\0'; - Replace(copy, l, u, DOH_REPLACE_FIRST); - } - String *ret = Swig_name_mangle(copy); - Delete(copy); - return ret; - } - - /* ---------------------------------------------------------------------- - * removeClassname() - * - * If the name starts with the current class name, followed by an - * underscore, remove it. If there is no current class name, this - * simply returns a copy of the name. This undoes Swig's way of - * recording the class name in a member name. - * ---------------------------------------------------------------------- */ - - String *removeClassname(String *name) { - String *copy = Copy(name); - if (class_name) { - char *p = Char(name); - if (Strncmp(name, class_name, Len(class_name)) == 0 && p[Len(class_name)] == '_') { - Replace(copy, class_name, "", DOH_REPLACE_FIRST); - Replace(copy, "_", "", DOH_REPLACE_FIRST); - } - } - return copy; - } - - /* ---------------------------------------------------------------------- - * buildGoName() - * - * Build the name to use for an ordinary function, variable, or - * whatever in Go. The name argument is something like the sym:name - * attribute of the node. If is_static is false, this could be a - * method, and the returned name will be the name of the - * method--i.e., it will not include the class name. - * ---------------------------------------------------------------------- */ - - String *buildGoName(String *name, bool is_static, bool is_friend) { - String *nw = NewString(""); - if (is_static && !is_friend && class_name) { - String *c1 = exportedName(class_name); - Append(nw, c1); - Delete(c1); - } - String *c2 = removeClassname(name); - String *c3 = exportedName(c2); - Append(nw, c3); - Delete(c2); - Delete(c3); - String *ret = Swig_name_mangle(nw); - Delete(nw); - return ret; - } - - /* ---------------------------------------------------------------------- - * buildGoWrapperName() - * - * Build the name to use for a Go wrapper function. This is a - * function called by the real Go function in order to convert C++ - * classes from interfaces to pointers, and other such conversions - * between the Go type and the C++ type. - * ---------------------------------------------------------------------- */ - - String *buildGoWrapperName(String *name, String *overname) { - String *s1 = NewString("_swig_wrap_"); - Append(s1, name); - String *s2 = Swig_name_mangle(s1); - Delete(s1); - if (overname) { - Append(s2, overname); - } - return s2; - } - - /* ---------------------------------------------------------------------- - * checkNameConflict() - * - * Check for a name conflict on the name we are going to use in Go. - * These conflicts are likely because of the enforced - * capitalization. When we find one, issue a warning and return - * false. If the name is OK, return true. - * ---------------------------------------------------------------------- */ - - bool checkNameConflict(String* name, Node* n, const_String_or_char_ptr scope) { - Node *lk = symbolLookup(name, scope); - if (lk) { - String *n1 = Getattr(n, "sym:name"); - if (!n1) { - n1 = Getattr(n, "name"); - } - String *n2 = Getattr(lk, "sym:name"); - if (!n2) { - n2 = Getattr(lk, "name"); - } - Swig_warning(WARN_GO_NAME_CONFLICT, input_file, line_number, - "Ignoring '%s' due to Go name ('%s') conflict with '%s'\n", - n1, name, n2); - return false; - } - bool r = addSymbol(name, n, scope) ? true : false; - assert(r); - return true; - } - - /* ---------------------------------------------------------------------- - * checkIgnoredParameters() - * - * If any of the parameters of this function, or the return type, - * are ignored due to a name conflict, give a warning and return - * false. - * ---------------------------------------------------------------------- */ - - bool checkIgnoredParameters(Node *n, String *go_name) { - ParmList *parms = Getattr(n, "parms"); - if (parms) { - Wrapper *dummy = NewWrapper(); - emit_attach_parmmaps(parms, dummy); - int parm_count = emit_num_arguments(parms); - Parm *p = parms; - - for (int i = 0; i < parm_count; ++i) { - p = getParm(p); - if (!checkIgnoredType(n, go_name, Getattr(p, "type"))) { - DelWrapper(dummy); - return false; - } - p = nextParm(p); - } - - DelWrapper(dummy); - } - - if (!checkIgnoredType(n, go_name, Getattr(n, "type"))) { - return false; - } - - return true; - } - - /* ---------------------------------------------------------------------- - * checkIgnoredType() - * - * If this type is being ignored due to a name conflict, give a - * warning and return false. - * ---------------------------------------------------------------------- */ - - bool checkIgnoredType(Node *n, String *go_name, SwigType *type) { - if (hasGoTypemap(n, type)) { - return true; - } - - SwigType *t = SwigType_typedef_resolve_all(type); - - bool ret = true; - bool is_conflict = false; - Node *e = Language::enumLookup(t); - if (e) { - if (GetFlag(e, "go:conflict")) { - is_conflict = true; - } - } else if (SwigType_issimple(t)) { - Node *cn = classLookup(t); - if (cn) { - if (GetFlag(cn, "go:conflict")) { - is_conflict = true; - } - } - } else if (SwigType_ispointer(t) || SwigType_isarray(t) || SwigType_isqualifier(t) || SwigType_isreference(t)) { - SwigType *r = Copy(t); - if (SwigType_ispointer(r)) { - SwigType_del_pointer(r); - } else if (SwigType_isarray(r)) { - SwigType_del_array(r); - } else if (SwigType_isqualifier(r)) { - SwigType_del_qualifier(r); - } else { - SwigType_del_reference(r); - } - - if (!checkIgnoredType(n, go_name, r)) { - ret = false; - } - - Delete(r); - } - - if (is_conflict) { - String *s = SwigType_str(t, NULL); - Swig_warning(WARN_GO_NAME_CONFLICT, input_file, line_number, - "Ignoring '%s' (Go name '%s') due to Go name conflict for parameter or result type '%s'\n", - Getattr(n, "name"), go_name, s); - Delete(s); - ret = false; - } - - Delete(t); - - return ret; - } - - /* ---------------------------------------------------------------------- - * goType() - * - * Given a SWIG type, return a string for the type in Go. - * ---------------------------------------------------------------------- */ - - String *goType(Node *n, SwigType *type) { - return goTypeWithInfo(n, type, false, NULL); - } - - /* ---------------------------------------------------------------------- - * goImType() - * - * Given a SWIG type, return a string for the intermediate Go type - * to pass to C/C++. This is like goType except that it looks for - * an imtype typemap entry first. - * ---------------------------------------------------------------------- */ - - String *goImType(Node *n, SwigType *type) { - return goTypeWithInfo(n, type, true, NULL); - } - - /* ---------------------------------------------------------------------- - * goTypeWithInfo() - * - * Like goType, but return some more information. - * - * If use_imtype is true, this look for a imtype typemap entry. - * - * If the p_is_interface parameter is not NULL, this sets - * *p_is_interface to indicate whether this type is going to be - * represented by a Go interface type. These are cases where the Go - * code needs to make some adjustments when passing values back and - * forth with C/C++. - * ---------------------------------------------------------------------- */ - - String *goTypeWithInfo(Node *n, SwigType *type, bool use_imtype, bool *p_is_interface) { - if (p_is_interface) { - *p_is_interface = false; - } - - String *ret = NULL; - if (use_imtype) { - if (n && Cmp(type, Getattr(n, "type")) == 0) { - if (Strcmp(Getattr(n, "nodeType"), "parm") == 0) { - ret = Getattr(n, "tmap:imtype"); - } - if (!ret) { - ret = Swig_typemap_lookup("imtype", n, "", NULL); - } - } else { - Parm *p = NewParm(type, "goImType", n); - ret = Swig_typemap_lookup("imtype", p, "", NULL); - Delete(p); - } - } - if (!ret) { - if (n && Cmp(type, Getattr(n, "type")) == 0) { - if (Strcmp(Getattr(n, "nodeType"), "parm") == 0) { - ret = Getattr(n, "tmap:gotype"); - } - if (!ret) { - ret = Swig_typemap_lookup("gotype", n, "", NULL); - } - } else { - Parm *p = NewParm(type, "goType", n); - ret = Swig_typemap_lookup("gotype", p, "", NULL); - Delete(p); - } - } - - if (ret && Strstr(ret, "$gotypename") != 0) { - ret = NULL; - } - - if (ret) { - return Copy(ret); - } - - SwigType *t = SwigType_typedef_resolve_all(type); - - if (SwigType_isenum(t)) { - Node *e = Language::enumLookup(t); - if (e) { - ret = goEnumName(e); - } else if (Strcmp(t, "enum ") == 0) { - ret = NewString("int"); - } else { - // An unknown enum - one that has not been parsed (neither a C enum forward reference nor a definition) or an ignored enum - String *tt = Copy(t); - Replace(tt, "enum ", "", DOH_REPLACE_ANY); - ret = exportedName(tt); - Setattr(undefined_enum_types, t, ret); - Delete(tt); - } - } else if (SwigType_isfunctionpointer(type) || SwigType_isfunction(type)) { - ret = NewString("_swig_fnptr"); - } else if (SwigType_ismemberpointer(type)) { - ret = NewString("_swig_memberptr"); - } else if (SwigType_issimple(t)) { - Node *cn = classLookup(t); - if (cn) { - ret = Getattr(cn, "sym:name"); - if (!ret) { - ret = Getattr(cn, "name"); - } - ret = exportedName(ret); - - Node *cnmod = Getattr(cn, "module"); - if (!cnmod || Strcmp(Getattr(cnmod, "name"), module) == 0) { - Setattr(undefined_types, t, t); - } else { - String *nw = NewString(""); - Printv(nw, Getattr(cnmod, "name"), ".", ret, NULL); - Delete(ret); - ret = nw; - } - } else { - // SWIG does not know about this type. - ret = exportedName(t); - Setattr(undefined_types, t, t); - } - if (p_is_interface) { - *p_is_interface = true; - } - } else if (SwigType_ispointer(t) || SwigType_isarray(t)) { - SwigType *r = Copy(t); - if (SwigType_ispointer(r)) { - SwigType_del_pointer(r); - } else { - SwigType_del_array(r); - } - - if (SwigType_type(r) == T_VOID) { - ret = NewString("uintptr"); - } else { - bool is_interface; - String *base = goTypeWithInfo(n, r, false, &is_interface); - - // At the Go level, an unknown or class type is handled as an - // interface wrapping a pointer. This means that if a - // function returns the C type X, we will be wrapping the C - // type X*. In Go we will call that type X. That means that - // if a C function expects X*, we can pass the Go type X. And - // that means that when we see the C type X*, we should use - // the Go type X. - - // The is_interface variable tells us this. However, it will - // be true both for the case of X and for the case of X*. If - // r is a pointer here, then we are looking at X**. There is - // really no good way for us to handle that. - bool is_pointer_to_pointer = false; - if (is_interface) { - SwigType *c = Copy(r); - if (SwigType_isqualifier(c)) { - SwigType_del_qualifier(c); - if (SwigType_ispointer(c) || SwigType_isarray(c)) { - is_pointer_to_pointer = true; - } - } - Delete(c); - } - - if (is_interface) { - if (!is_pointer_to_pointer) { - ret = base; - if (p_is_interface) { - *p_is_interface = true; - } - } else { - ret = NewString("uintptr"); - } - } else { - ret = NewString("*"); - Append(ret, base); - Delete(base); - } - } - - Delete(r); - } else if (SwigType_isreference(t)) { - SwigType *r = Copy(t); - SwigType_del_reference(r); - - // If this is a const reference, and we are looking at a pointer - // to it, then we just use the pointer we already have. - bool add_pointer = true; - if (SwigType_isqualifier(r)) { - String *q = SwigType_parm(r); - if (Strcmp(q, "const") == 0) { - SwigType *c = Copy(r); - SwigType_del_qualifier(c); - if (SwigType_ispointer(c)) { - add_pointer = false; - } - Delete(c); - } - } - if (add_pointer) { - SwigType_add_pointer(r); - } - ret = goTypeWithInfo(n, r, false, p_is_interface); - Delete(r); - } else if (SwigType_isqualifier(t)) { - SwigType *r = Copy(t); - SwigType_del_qualifier(r); - ret = goTypeWithInfo(n, r, false, p_is_interface); - Delete(r); - } else if (SwigType_isvarargs(t)) { - ret = NewString("[]interface{}"); - } - - Delete(t); - - if (!ret) { - Swig_warning(WARN_LANG_NATIVE_UNIMPL, input_file, line_number, "No Go typemap defined for %s\n", SwigType_str(type, 0)); - ret = NewString("uintptr"); - } - - return ret; - } - - /* ---------------------------------------------------------------------- - * goWrapperType() - * - * Given a type, return a string for the type to use for the wrapped - * Go function. This function exists because for a C++ class we - * need to convert interface and reference types. - * ---------------------------------------------------------------------- */ - - String *goWrapperType(Node *n, SwigType *type, bool is_result) { - bool is_interface; - String *ret = goTypeWithInfo(n, type, true, &is_interface); - - // If this is an interface, we want to pass the real type. - if (is_interface) { - Delete(ret); - if (!is_result) { - ret = NewString("uintptr"); - } else { - SwigType *ty = SwigType_typedef_resolve_all(type); - while (true) { - if (SwigType_ispointer(ty)) { - SwigType_del_pointer(ty); - } else if (SwigType_isarray(ty)) { - SwigType_del_array(ty); - } else if (SwigType_isreference(ty)) { - SwigType_del_reference(ty); - } else if (SwigType_isqualifier(ty)) { - SwigType_del_qualifier(ty); - } else { - break; - } - } - assert(SwigType_issimple(ty)); - String *p = goCPointerType(ty, true); - Delete(ty); - ret = p; - } - } - - return ret; - } - - /* ---------------------------------------------------------------------- - * goCPointerType() - * - * Return the name of the Go type to use for the C pointer value. - * The regular C type is the name of an interface type which wraps a - * pointer whose name is returned by this function. - * ---------------------------------------------------------------------- */ - - String *goCPointerType(SwigType *type, bool add_to_hash) { - SwigType *ty = SwigType_typedef_resolve_all(type); - Node *cn = classLookup(ty); - String *ex; - String *ret; - if (!cn) { - if (add_to_hash) { - Setattr(undefined_types, ty, ty); - } - ret = NewString("Swigcptr"); - ex = exportedName(ty); - Append(ret, ex); - } else { - String *cname = Getattr(cn, "sym:name"); - if (!cname) { - cname = Getattr(cn, "name"); - } - ex = exportedName(cname); - Node *cnmod = Getattr(cn, "module"); - if (!cnmod || Strcmp(Getattr(cnmod, "name"), module) == 0) { - if (add_to_hash) { - Setattr(undefined_types, ty, ty); - } - ret = NewString("Swigcptr"); - Append(ret, ex); - } else { - ret = NewString(""); - Printv(ret, Getattr(cnmod, "name"), ".Swigcptr", ex, NULL); - } - } - Delete(ty); - Delete(ex); - return ret; - } - - /* ---------------------------------------------------------------------- - * gcCTypeForGoValue() - * - * Given a type, return the C/C++ type which will be used to catch - * the value in Go. This is the 6g/8g version. - * ---------------------------------------------------------------------- */ - - String *gcCTypeForGoValue(Node *n, SwigType *type, String *name) { - bool is_interface; - String *gt = goTypeWithInfo(n, type, true, &is_interface); - - String *tail = NewString(""); - SwigType *t = SwigType_typedef_resolve_all(type); - if (!SwigType_isreference(t)) { - while (Strncmp(gt, "*", 1) == 0) { - Replace(gt, "*", "", DOH_REPLACE_FIRST); - Printv(tail, "*", NULL); - } - } - Delete(t); - - bool is_string = Strcmp(gt, "string") == 0; - bool is_slice = Strncmp(gt, "[]", 2) == 0; - bool is_function = Strcmp(gt, "_swig_fnptr") == 0; - bool is_member = Strcmp(gt, "_swig_memberptr") == 0; - bool is_complex64 = Strcmp(gt, "complex64") == 0; - bool is_complex128 = Strcmp(gt, "complex128") == 0; - bool is_int8 = false; - bool is_int16 = false; - bool is_int = Strcmp(gt, "int") == 0 || Strcmp(gt, "uint") == 0; - bool is_int32 = false; - bool is_int64 = false; - bool is_float32 = false; - bool is_float64 = false; - if ((n != NULL && Getattr(n, "tmap:gotype") != NULL) || hasGoTypemap(n, type)) { - is_int8 = Strcmp(gt, "int8") == 0 || Strcmp(gt, "uint8") == 0 || Strcmp(gt, "byte") == 0; - is_int16 = Strcmp(gt, "int16") == 0 || Strcmp(gt, "uint16") == 0; - is_int32 = Strcmp(gt, "int32") == 0 || Strcmp(gt, "uint32") == 0; - is_int64 = Strcmp(gt, "int64") == 0 || Strcmp(gt, "uint64") == 0; - is_float32 = Strcmp(gt, "float32") == 0; - is_float64 = Strcmp(gt, "float64") == 0; - } - Delete(gt); - - String *ret; - if (is_string) { - // Note that we don't turn a reference to a string into a - // pointer to a string. Strings are immutable anyhow. - ret = NewString(""); - Printv(ret, "_gostring_", tail, " ", name, NULL); - Delete(tail); - return ret; - } else if (is_slice) { - // Slices are always passed as a _goslice_, whether or not references - // are involved. - ret = NewString(""); - Printv(ret, "_goslice_", tail, " ", name, NULL); - Delete(tail); - return ret; - } else if (is_function || is_member) { - ret = NewString(""); - Printv(ret, "void*", tail, " ", name, NULL); - Delete(tail); - return ret; - } else if (is_complex64) { - ret = NewString("_Complex float "); - } else if (is_complex128) { - ret = NewString("_Complex double "); - } else if (is_interface) { - SwigType *t = SwigType_typedef_resolve_all(type); - if (SwigType_ispointer(t)) { - SwigType_del_pointer(t); - } - if (SwigType_isreference(t)) { - SwigType_del_reference(t); - } - SwigType_add_pointer(t); - ret = SwigType_lstr(t, name); - Delete(t); - Delete(tail); - return ret; - } else { - SwigType *t = SwigType_typedef_resolve_all(type); - if (SwigType_isreference(t)) { - // A const reference to a known type, or to a pointer, is not - // mapped to a pointer. - SwigType_del_reference(t); - if (SwigType_isqualifier(t)) { - String *q = SwigType_parm(t); - if (Strcmp(q, "const") == 0) { - SwigType_del_qualifier(t); - if (hasGoTypemap(n, t) || SwigType_ispointer(t)) { - if (is_int) { - ret = NewString("intgo "); - Append(ret, name); - } else if (is_int64) { - ret = NewString("long long "); - Append(ret, name); - } else { - ret = SwigType_lstr(t, name); - } - Delete(q); - Delete(t); - Delete(tail); - return ret; - } - } - Delete(q); - } - } - - if (Language::enumLookup(t) != NULL) { - is_int = true; - } else { - SwigType *tstripped = SwigType_strip_qualifiers(t); - if (SwigType_isenum(tstripped)) - is_int = true; - Delete(tstripped); - } - - Delete(t); - if (is_int8) { - ret = NewString("char "); - } else if (is_int16) { - ret = NewString("short "); - } else if (is_int) { - ret = NewString("intgo "); - } else if (is_int32) { - ret = NewString("int "); - } else if (is_int64) { - ret = NewString("long long "); - } else if (is_float32) { - ret = NewString("float "); - } else if (is_float64) { - ret = NewString("double "); - } else { - Delete(tail); - return SwigType_lstr(type, name); - } - } - - Append(ret, tail); - if (SwigType_isreference(type)) { - Append(ret, "* "); - } - Append(ret, name); - Delete(tail); - return ret; - } - - /* ---------------------------------------------------------------------- - * gccgoCTypeForGoValue() - * - * Given a type, return the C/C++ type which will be used to catch - * the value in Go. This is the gccgo version. - * ---------------------------------------------------------------------- */ - - String *gccgoCTypeForGoValue(Node *n, SwigType *type, String *name) { - return gcCTypeForGoValue(n, type, name); - } - - /* ---------------------------------------------------------------------- - * goTypeIsInterface - * - * Return whether this C++ type is represented as an interface type - * in Go. These types require adjustments in the Go code when - * passing them back and forth between Go and C++. - * ---------------------------------------------------------------------- */ - - bool goTypeIsInterface(Node *n, SwigType *type) { - bool is_interface; - Delete(goTypeWithInfo(n, type, false, &is_interface)); - return is_interface; - } - - /* ---------------------------------------------------------------------- - * hasGoTypemap - * - * Return whether a type has a "gotype" typemap entry. - * ---------------------------------------------------------------------- */ - - bool hasGoTypemap(Node *n, SwigType *type) { - Parm *p = NewParm(type, "test", n); - SwigType *tm = Swig_typemap_lookup("gotype", p, "", NULL); - Delete(p); - if (tm && Strstr(tm, "$gotypename") == 0) { - Delete(tm); - return true; - } - Delete(tm); - return false; - } - - /* ---------------------------------------------------------------------- - * goEnumName() - * - * Given an enum node, return a string to use for the enum type in Go. - * ---------------------------------------------------------------------- */ - - String *goEnumName(Node *n) { - String *ret = Getattr(n, "go:enumname"); - if (ret) { - return Copy(ret); - } - - if (Equal(Getattr(n, "type"), "enum ")) { - return NewString("int"); - } - - String *type = Getattr(n, "enumtype"); - assert(type); - char *p = Char(type); - int len = Len(type); - String *s = NewString(""); - bool capitalize = true; - for (int i = 0; i < len; ++i, ++p) { - if (*p == ':') { - ++i; - ++p; - assert(*p == ':'); - capitalize = true; - } else if (capitalize) { - Putc(toupper(*p), s); - capitalize = false; - } else { - Putc(*p, s); - } - } - - ret = Swig_name_mangle(s); - Delete(s); - return ret; - } - - - /* ---------------------------------------------------------------------- - * getParm() - * - * Get the real parameter to use. - * ---------------------------------------------------------------------- */ - - Parm *getParm(Parm *p) { - while (p && checkAttribute(p, "tmap:in:numinputs", "0")) { - p = Getattr(p, "tmap:in:next"); - } - return p; - } - - /* ---------------------------------------------------------------------- - * nextParm() - * - * Return the next parameter. - * ---------------------------------------------------------------------- */ - - Parm *nextParm(Parm *p) { - if (!p) { - return NULL; - } else if (Getattr(p, "tmap:in")) { - return Getattr(p, "tmap:in:next"); - } else { - return nextSibling(p); - } - } - - /* ---------------------------------------------------------------------- - * isStatic - * - * Return whether a node should be considered as static rather than - * as a member. - * ---------------------------------------------------------------------- */ - - bool isStatic(Node *n) { - String *storage = Getattr(n, "storage"); - return (storage && (Swig_storage_isstatic(n) || Strcmp(storage, "friend") == 0) && (!SmartPointer || !Getattr(n, "allocate:smartpointeraccess"))); - } - - /* ---------------------------------------------------------------------- - * isFriend - * - * Return whether a node is a friend. - * ---------------------------------------------------------------------- */ - - bool isFriend(Node *n) { - String *storage = Getattr(n, "storage"); - return storage && Strcmp(storage, "friend") == 0; - } - -}; /* class GO */ - -/* ----------------------------------------------------------------------------- - * swig_go() - Instantiate module - * ----------------------------------------------------------------------------- */ - -static Language *new_swig_go() { - return new GO(); -} -extern "C" Language *swig_go(void) { - return new_swig_go(); -} - -/* ----------------------------------------------------------------------------- - * Static member variables - * ----------------------------------------------------------------------------- */ - -// Usage message. -const char * const GO::usage = "\ -Go Options (available with -go)\n\ - -gccgo - Generate code for gccgo rather than 6g/8g\n\ - -go-pkgpath

    - Like gccgo -fgo-pkgpath option\n\ - -go-prefix

    - Like gccgo -fgo-prefix option\n\ - -intgosize - Set size of Go int type--32 or 64 bits\n\ - -package - Set name of the Go package to \n\ - -use-shlib - Force use of a shared library\n\ - -soname - Set shared library holding C/C++ code to \n\ -\n"; -- cgit v1.2.1 From 41e9ccae7c87ed01c7e286688f4b97f311cb9917 Mon Sep 17 00:00:00 2001 From: Anthony Li Date: Mon, 6 Oct 2014 20:01:38 +0800 Subject: Go: fix overload functions with polymorphic issue --- Examples/python/import_packages/relativeimport2/runme3.py | 9 +++++++++ 1 file changed, 9 insertions(+) create mode 100644 Examples/python/import_packages/relativeimport2/runme3.py diff --git a/Examples/python/import_packages/relativeimport2/runme3.py b/Examples/python/import_packages/relativeimport2/runme3.py new file mode 100644 index 000000000..4b0d112cf --- /dev/null +++ b/Examples/python/import_packages/relativeimport2/runme3.py @@ -0,0 +1,9 @@ +# Test import of modules content from within __init__.py +print("Testing %module(package=...) + python 'import' in __init__.py") +import sys +if sys.version_info < (3, 0): + import py2.pkg2.bar + print(" Finished importing py2.pkg2.bar") +else: + import py3.pkg2.bar + print(" Finished importing py3.pkg2.bar") -- cgit v1.2.1 From bbad7f96ab870046b62cfa834221a424f89bcf05 Mon Sep 17 00:00:00 2001 From: William S Fulton Date: Thu, 2 Oct 2014 20:03:40 +0100 Subject: Bypass Python tests throwing base classes as exceptions for -builtin Throwing builtin classes as exceptions is not supported --- Examples/test-suite/director_exception.i | 6 ++++++ Examples/test-suite/exception_order.i | 7 +++++++ Examples/test-suite/li_std_except_as_class.i | 8 ++++++++ Examples/test-suite/python/Makefile.in | 4 ---- .../test-suite/python/director_exception_runme.py | 19 ++++++++--------- .../test-suite/python/exception_order_runme.py | 2 ++ .../python/li_std_except_as_class_runme.py | 24 +++++++++++++++------- .../test-suite/python/threads_exception_runme.py | 19 +++++++++-------- Examples/test-suite/threads_exception.i | 6 ++++++ 9 files changed, 65 insertions(+), 30 deletions(-) diff --git a/Examples/test-suite/director_exception.i b/Examples/test-suite/director_exception.i index 43aeea22a..2559ae566 100644 --- a/Examples/test-suite/director_exception.i +++ b/Examples/test-suite/director_exception.i @@ -152,4 +152,10 @@ Foo *launder(Foo *f) { virtual Bar return_Bar() { return Bar(); } virtual ~ReturnAllTypes() {} }; + +#ifdef SWIGPYTHON_BUILTIN +bool is_python_builtin() { return true; } +#else +bool is_python_builtin() { return false; } +#endif %} diff --git a/Examples/test-suite/exception_order.i b/Examples/test-suite/exception_order.i index 4dd13858a..bca745c7e 100644 --- a/Examples/test-suite/exception_order.i +++ b/Examples/test-suite/exception_order.i @@ -125,6 +125,13 @@ } }; int A::sfoovar = 1; + +#ifdef SWIGPYTHON_BUILTIN +bool is_python_builtin() { return true; } +#else +bool is_python_builtin() { return false; } +#endif + %} %template(ET_i) ET; diff --git a/Examples/test-suite/li_std_except_as_class.i b/Examples/test-suite/li_std_except_as_class.i index 0400c9a82..01ed1f07c 100644 --- a/Examples/test-suite/li_std_except_as_class.i +++ b/Examples/test-suite/li_std_except_as_class.i @@ -23,3 +23,11 @@ void test_domain_error() throw(std::domain_error) %include void test_domain_error() throw(std::domain_error) { throw std::domain_error("std::domain_error"); } + +%inline %{ +#ifdef SWIGPYTHON_BUILTIN +bool is_python_builtin() { return true; } +#else +bool is_python_builtin() { return false; } +#endif +%} diff --git a/Examples/test-suite/python/Makefile.in b/Examples/test-suite/python/Makefile.in index 896014770..4ef876845 100644 --- a/Examples/test-suite/python/Makefile.in +++ b/Examples/test-suite/python/Makefile.in @@ -89,14 +89,10 @@ include $(srcdir)/../common.mk BUILTIN_BROKEN = \ autodoc.cpptest \ default_constructor.cpptest \ - director_exception.cpptest \ - exception_order.cpptest \ import_nomodule.cpptest \ - li_std_except_as_class.cpptest \ li_std_string_extra.cpptest \ li_std_wstring.cpptest \ python_abstractbase.cpptest \ - threads_exception.cpptest BUILTIN_NOT_BROKEN = $(filter-out $(BUILTIN_BROKEN),$(NOT_BROKEN_TEST_CASES)) diff --git a/Examples/test-suite/python/director_exception_runme.py b/Examples/test-suite/python/director_exception_runme.py index 510845a5a..de3ef22a5 100644 --- a/Examples/test-suite/python/director_exception_runme.py +++ b/Examples/test-suite/python/director_exception_runme.py @@ -68,14 +68,13 @@ if not ok: # This is expected to fail with -builtin option # Throwing builtin classes as exceptions not supported -try: - raise Exception2() -except Exception2: - pass +if not is_python_builtin(): + try: + raise Exception2() + except Exception2: + pass -# This is expected to fail with -builtin option -# Throwing builtin classes as exceptions not supported -try: - raise Exception1() -except Exception1: - pass + try: + raise Exception1() + except Exception1: + pass diff --git a/Examples/test-suite/python/exception_order_runme.py b/Examples/test-suite/python/exception_order_runme.py index 38b53eb0c..8f095eb98 100644 --- a/Examples/test-suite/python/exception_order_runme.py +++ b/Examples/test-suite/python/exception_order_runme.py @@ -2,6 +2,8 @@ from exception_order import * # This test is expected to fail with -builtin option. # Throwing builtin classes as exceptions not supported +if is_python_builtin(): + exit(0) a = A() diff --git a/Examples/test-suite/python/li_std_except_as_class_runme.py b/Examples/test-suite/python/li_std_except_as_class_runme.py index 386a878bf..a86e7a562 100644 --- a/Examples/test-suite/python/li_std_except_as_class_runme.py +++ b/Examples/test-suite/python/li_std_except_as_class_runme.py @@ -1,9 +1,19 @@ from li_std_except_as_class import * -# std::domain_error hierarchy -try: test_domain_error() -except domain_error: pass -try: test_domain_error() -except logic_error: pass -try: test_domain_error() -except exception: pass +# This test is expected to fail with -builtin option. +# Throwing builtin classes as exceptions not supported +if is_python_builtin(): + try: test_domain_error() + except RuntimeError: pass + try: test_domain_error() + except RuntimeError: pass + try: test_domain_error() + except RuntimeError: pass +else: + # std::domain_error hierarchy + try: test_domain_error() + except domain_error: pass + try: test_domain_error() + except logic_error: pass + try: test_domain_error() + except exception: pass diff --git a/Examples/test-suite/python/threads_exception_runme.py b/Examples/test-suite/python/threads_exception_runme.py index d4b8855fc..6fe6947ec 100644 --- a/Examples/test-suite/python/threads_exception_runme.py +++ b/Examples/test-suite/python/threads_exception_runme.py @@ -20,15 +20,16 @@ except RuntimeError,e: # This is expected fail with -builtin option # Throwing builtin classes as exceptions not supported -try: - t.hosed() -except threads_exception.Exc,e: - code = e.code - if code != 42: - raise RuntimeError, "bad... code: %d" % code - msg = e.msg - if msg != "Hosed": - raise RuntimeError, "bad... msg: '%s' len: %d" % (msg, len(msg)) +if not threads_exception.is_python_builtin(): + try: + t.hosed() + except threads_exception.Exc,e: + code = e.code + if code != 42: + raise RuntimeError, "bad... code: %d" % code + msg = e.msg + if msg != "Hosed": + raise RuntimeError, "bad... msg: '%s' len: %d" % (msg, len(msg)) for i in range(1,4): try: diff --git a/Examples/test-suite/threads_exception.i b/Examples/test-suite/threads_exception.i index b374f0ce6..caa79c78e 100644 --- a/Examples/test-suite/threads_exception.i +++ b/Examples/test-suite/threads_exception.i @@ -52,4 +52,10 @@ public: return 1; } }; + +#ifdef SWIGPYTHON_BUILTIN +bool is_python_builtin() { return true; } +#else +bool is_python_builtin() { return false; } +#endif %} -- cgit v1.2.1 From 9f1b051c16672120832ae4511667e8978efc1a80 Mon Sep 17 00:00:00 2001 From: William S Fulton Date: Thu, 2 Oct 2014 20:18:38 +0100 Subject: Bypass Python tests failing with -builtin Reverse operators not supported in builtin types --- Examples/test-suite/li_std_string_extra.i | 6 ++++++ Examples/test-suite/li_std_wstring.i | 6 ++++++ Examples/test-suite/python/Makefile.in | 2 -- Examples/test-suite/python/li_std_string_extra_runme.py | 13 ++++++------- Examples/test-suite/python/li_std_wstring_runme.py | 15 ++++++++------- 5 files changed, 26 insertions(+), 16 deletions(-) diff --git a/Examples/test-suite/li_std_string_extra.i b/Examples/test-suite/li_std_string_extra.i index aa758532a..6bef12ff4 100644 --- a/Examples/test-suite/li_std_string_extra.i +++ b/Examples/test-suite/li_std_string_extra.i @@ -49,6 +49,12 @@ std::basic_string,std::allocator > test_value_ return x; } +#ifdef SWIGPYTHON_BUILTIN +bool is_python_builtin() { return true; } +#else +bool is_python_builtin() { return false; } +#endif + %} %include "li_std_string.i" diff --git a/Examples/test-suite/li_std_wstring.i b/Examples/test-suite/li_std_wstring.i index e0ecde53b..80f860338 100644 --- a/Examples/test-suite/li_std_wstring.i +++ b/Examples/test-suite/li_std_wstring.i @@ -92,6 +92,12 @@ void test_throw() throw(std::wstring){ #pragma warning(default: 4290) // C++ exception specification ignored except to indicate a function is not __declspec(nothrow) #endif +#ifdef SWIGPYTHON_BUILTIN +bool is_python_builtin() { return true; } +#else +bool is_python_builtin() { return false; } +#endif + %} diff --git a/Examples/test-suite/python/Makefile.in b/Examples/test-suite/python/Makefile.in index 4ef876845..33fd34263 100644 --- a/Examples/test-suite/python/Makefile.in +++ b/Examples/test-suite/python/Makefile.in @@ -90,8 +90,6 @@ BUILTIN_BROKEN = \ autodoc.cpptest \ default_constructor.cpptest \ import_nomodule.cpptest \ - li_std_string_extra.cpptest \ - li_std_wstring.cpptest \ python_abstractbase.cpptest \ BUILTIN_NOT_BROKEN = $(filter-out $(BUILTIN_BROKEN),$(NOT_BROKEN_TEST_CASES)) diff --git a/Examples/test-suite/python/li_std_string_extra_runme.py b/Examples/test-suite/python/li_std_string_extra_runme.py index 9e9e3d2c3..503d09eb5 100644 --- a/Examples/test-suite/python/li_std_string_extra_runme.py +++ b/Examples/test-suite/python/li_std_string_extra_runme.py @@ -56,14 +56,13 @@ if a + " world" != "hello world": # This is expected to fail with -builtin option # Reverse operators not supported in builtin types -if "hello" + b != "hello world": - raise RuntimeError, "bad string mapping" +if not li_std_string_extra.is_python_builtin(): + if "hello" + b != "hello world": + raise RuntimeError, "bad string mapping" -# This is expected to fail with -builtin option -# Reverse operators not supported in builtin types -c = "hello" + b -if c.find_last_of("l") != 9: - raise RuntimeError, "bad string mapping" + c = "hello" + b + if c.find_last_of("l") != 9: + raise RuntimeError, "bad string mapping" s = "hello world" diff --git a/Examples/test-suite/python/li_std_wstring_runme.py b/Examples/test-suite/python/li_std_wstring_runme.py index fecc527e0..a467ae8bc 100644 --- a/Examples/test-suite/python/li_std_wstring_runme.py +++ b/Examples/test-suite/python/li_std_wstring_runme.py @@ -60,13 +60,14 @@ if a + " world" != "hello world": raise RuntimeError("bad string mapping") # This is expected to fail if -builtin is used -if "hello" + b != "hello world": - raise RuntimeError("bad string mapping") - -# This is expected to fail if -builtin is used -c = "hello" + b -if c.find_last_of("l") != 9: - raise RuntimeError("bad string mapping") +# Reverse operators not supported in builtin types +if not li_std_wstring.is_python_builtin(): + if "hello" + b != "hello world": + raise RuntimeError("bad string mapping") + + c = "hello" + b + if c.find_last_of("l") != 9: + raise RuntimeError("bad string mapping") s = "hello world" -- cgit v1.2.1 From afcd61388ae5d56b3e3821f39976e2b214d2f27f Mon Sep 17 00:00:00 2001 From: William S Fulton Date: Thu, 2 Oct 2014 20:23:08 +0100 Subject: Bypass Python tests not supported by -builtin The old static syntax (e.g., dc.new_A() rather than dc.A()) is not supported with -builtin --- Examples/test-suite/default_constructor.i | 8 +++++++- Examples/test-suite/python/Makefile.in | 1 - Examples/test-suite/python/default_constructor_runme.py | 6 ++++-- 3 files changed, 11 insertions(+), 4 deletions(-) diff --git a/Examples/test-suite/default_constructor.i b/Examples/test-suite/default_constructor.i index 091adff20..f7fc8cfa6 100644 --- a/Examples/test-suite/default_constructor.i +++ b/Examples/test-suite/default_constructor.i @@ -168,5 +168,11 @@ public: } }; - +%inline %{ +#ifdef SWIGPYTHON_BUILTIN +bool is_python_builtin() { return true; } +#else +bool is_python_builtin() { return false; } +#endif +%} diff --git a/Examples/test-suite/python/Makefile.in b/Examples/test-suite/python/Makefile.in index 33fd34263..87dac2565 100644 --- a/Examples/test-suite/python/Makefile.in +++ b/Examples/test-suite/python/Makefile.in @@ -88,7 +88,6 @@ include $(srcdir)/../common.mk BUILTIN_BROKEN = \ autodoc.cpptest \ - default_constructor.cpptest \ import_nomodule.cpptest \ python_abstractbase.cpptest \ diff --git a/Examples/test-suite/python/default_constructor_runme.py b/Examples/test-suite/python/default_constructor_runme.py index 59b130559..e6532031b 100644 --- a/Examples/test-suite/python/default_constructor_runme.py +++ b/Examples/test-suite/python/default_constructor_runme.py @@ -1,8 +1,10 @@ +import _default_constructor + # This test is expected to fail with -builtin option. # It uses the old static syntax (e.g., dc.new_A() rather than dc.A()), # which is not provided with the -builtin option. - -import _default_constructor +if _default_constructor.is_python_builtin(): + exit(0) dc = _default_constructor -- cgit v1.2.1 From 185d65895f4216b18b83a6b7e304358a22a65d96 Mon Sep 17 00:00:00 2001 From: William S Fulton Date: Fri, 3 Oct 2014 20:09:09 +0100 Subject: Bypass Python tests not supported by -builtin There are a number of autodoc comment differences when using -builtin. Some of which might need fixing, but for now we'll accept them as they are. --- Examples/test-suite/autodoc.i | 8 ++ Examples/test-suite/python/Makefile.in | 1 - Examples/test-suite/python/autodoc_runme.py | 209 ++++++++++++++++++++++++---- 3 files changed, 190 insertions(+), 28 deletions(-) diff --git a/Examples/test-suite/autodoc.i b/Examples/test-suite/autodoc.i index 599a3f12f..d85899756 100644 --- a/Examples/test-suite/autodoc.i +++ b/Examples/test-suite/autodoc.i @@ -133,3 +133,11 @@ typedef int Integer; void banana(S *a, const struct tagS *b, int c, Integer d) {} %} +%inline %{ +#ifdef SWIGPYTHON_BUILTIN +bool is_python_builtin() { return true; } +#else +bool is_python_builtin() { return false; } +#endif +%} + diff --git a/Examples/test-suite/python/Makefile.in b/Examples/test-suite/python/Makefile.in index 87dac2565..60253ac98 100644 --- a/Examples/test-suite/python/Makefile.in +++ b/Examples/test-suite/python/Makefile.in @@ -87,7 +87,6 @@ C_TEST_CASES += \ include $(srcdir)/../common.mk BUILTIN_BROKEN = \ - autodoc.cpptest \ import_nomodule.cpptest \ python_abstractbase.cpptest \ diff --git a/Examples/test-suite/python/autodoc_runme.py b/Examples/test-suite/python/autodoc_runme.py index 5776ad3ef..3cc9400f6 100644 --- a/Examples/test-suite/python/autodoc_runme.py +++ b/Examples/test-suite/python/autodoc_runme.py @@ -1,15 +1,24 @@ from autodoc import * import sys -def check(got, expected): - if expected != got: - raise RuntimeError("\n" + "Expected: [" + str(expected) + "]\n" + "Got : [" + str(got) + "]") +def check(got, expected, expected_builtin = None, skip = False): + if not skip: + expect = expected_builtin if is_python_builtin() and expected_builtin != None else expected + if expect != got: + raise RuntimeError("\n" + "Expected: [" + str(expect) + "]\n" + "Got : [" + str(got) + "]") -check(A.__doc__, "Proxy of C++ A class") +skip = True # skip builtin check - the autodoc is missing, but it probably should not be + +check(A.__doc__, "Proxy of C++ A class", "::A") check(A.funk.__doc__, "just a string") -check(A.func0.__doc__, "func0(self, arg2, hello) -> int") -check(A.func1.__doc__, "func1(A self, short arg2, Tuple hello) -> int") -check(A.func2.__doc__, "\n" +check(A.func0.__doc__, +"func0(self, arg2, hello) -> int", +"func0(arg2, hello) -> int") +check(A.func1.__doc__, +"func1(A self, short arg2, Tuple hello) -> int", +"func1(short arg2, Tuple hello) -> int") +check(A.func2.__doc__, +"\n" " func2(self, arg2, hello) -> int\n" "\n" " Parameters:\n" @@ -17,8 +26,18 @@ check(A.func2.__doc__, "\n" " hello: int tuple[2]\n" "\n" " " +, +"\n" +"func2(arg2, hello) -> int\n" +"\n" +"Parameters:\n" +" arg2: short\n" +" hello: int tuple[2]\n" +"\n" +"" ) -check(A.func3.__doc__, "\n" +check(A.func3.__doc__, +"\n" " func3(A self, short arg2, Tuple hello) -> int\n" "\n" " Parameters:\n" @@ -26,19 +45,41 @@ check(A.func3.__doc__, "\n" " hello: int tuple[2]\n" "\n" " " +, +"\n" +"func3(short arg2, Tuple hello) -> int\n" +"\n" +"Parameters:\n" +" arg2: short\n" +" hello: int tuple[2]\n" +"\n" +"" ) -check(A.func0default.__doc__, "\n" +check(A.func0default.__doc__, +"\n" " func0default(self, e, arg3, hello, f=2) -> int\n" " func0default(self, e, arg3, hello) -> int\n" " " +, +"\n" +"func0default(e, arg3, hello, f=2) -> int\n" +"func0default(e, arg3, hello) -> int\n" +"" ) -check(A.func1default.__doc__, "\n" +check(A.func1default.__doc__, +"\n" " func1default(A self, A e, short arg3, Tuple hello, double f=2) -> int\n" " func1default(A self, A e, short arg3, Tuple hello) -> int\n" " " +, +"\n" +"func1default(A e, short arg3, Tuple hello, double f=2) -> int\n" +"func1default(A e, short arg3, Tuple hello) -> int\n" +"" ) -check(A.func2default.__doc__, "\n" +check(A.func2default.__doc__, +"\n" " func2default(self, e, arg3, hello, f=2) -> int\n" "\n" " Parameters:\n" @@ -55,8 +96,27 @@ check(A.func2default.__doc__, "\n" " hello: int tuple[2]\n" "\n" " " +, +"\n" +"func2default(e, arg3, hello, f=2) -> int\n" +"\n" +"Parameters:\n" +" e: A *\n" +" arg3: short\n" +" hello: int tuple[2]\n" +" f: double\n" +"\n" +"func2default(e, arg3, hello) -> int\n" +"\n" +"Parameters:\n" +" e: A *\n" +" arg3: short\n" +" hello: int tuple[2]\n" +"\n" +"" ) -check(A.func3default.__doc__, "\n" +check(A.func3default.__doc__, +"\n" " func3default(A self, A e, short arg3, Tuple hello, double f=2) -> int\n" "\n" " Parameters:\n" @@ -73,19 +133,50 @@ check(A.func3default.__doc__, "\n" " hello: int tuple[2]\n" "\n" " " +, +"\n" +"func3default(A e, short arg3, Tuple hello, double f=2) -> int\n" +"\n" +"Parameters:\n" +" e: A *\n" +" arg3: short\n" +" hello: int tuple[2]\n" +" f: double\n" +"\n" +"func3default(A e, short arg3, Tuple hello) -> int\n" +"\n" +"Parameters:\n" +" e: A *\n" +" arg3: short\n" +" hello: int tuple[2]\n" +"\n" +"" ) -check(A.func0static.__doc__, "\n" +check(A.func0static.__doc__, +"\n" " func0static(e, arg2, hello, f=2) -> int\n" " func0static(e, arg2, hello) -> int\n" " " +, +"\n" +"func0static(e, arg2, hello, f=2) -> int\n" +"func0static(e, arg3, hello) -> int\n" +"" ) -check(A.func1static.__doc__, "\n" +check(A.func1static.__doc__, +"\n" " func1static(A e, short arg2, Tuple hello, double f=2) -> int\n" " func1static(A e, short arg2, Tuple hello) -> int\n" " " +, +"\n" +"func1static(A e, short arg2, Tuple hello, double f=2) -> int\n" +"func1static(A e, short arg3, Tuple hello) -> int\n" +"" ) -check(A.func2static.__doc__, "\n" +check(A.func2static.__doc__, +"\n" " func2static(e, arg2, hello, f=2) -> int\n" "\n" " Parameters:\n" @@ -102,8 +193,27 @@ check(A.func2static.__doc__, "\n" " hello: int tuple[2]\n" "\n" " " +, +"\n" +"func2static(e, arg2, hello, f=2) -> int\n" +"\n" +"Parameters:\n" +" e: A *\n" +" arg2: short\n" +" hello: int tuple[2]\n" +" f: double\n" +"\n" +"func2static(e, arg3, hello) -> int\n" +"\n" +"Parameters:\n" +" e: A *\n" +" arg3: short\n" +" hello: int tuple[2]\n" +"\n" +"" ) -check(A.func3static.__doc__, "\n" +check(A.func3static.__doc__, +"\n" " func3static(A e, short arg2, Tuple hello, double f=2) -> int\n" "\n" " Parameters:\n" @@ -120,31 +230,65 @@ check(A.func3static.__doc__, "\n" " hello: int tuple[2]\n" "\n" " " +, +"\n" +"func3static(A e, short arg2, Tuple hello, double f=2) -> int\n" +"\n" +"Parameters:\n" +" e: A *\n" +" arg2: short\n" +" hello: int tuple[2]\n" +" f: double\n" +"\n" +"func3static(A e, short arg3, Tuple hello) -> int\n" +"\n" +"Parameters:\n" +" e: A *\n" +" arg3: short\n" +" hello: int tuple[2]\n" +"\n" +"" ) if sys.version_info[0:2] > (2, 4): # Python 2.4 does not seem to work - check(A.variable_a.__doc__, "A_variable_a_get(self) -> int") - check(A.variable_b.__doc__, "A_variable_b_get(A self) -> int") - check(A.variable_c.__doc__, "\n" + check(A.variable_a.__doc__, + "A_variable_a_get(self) -> int", + "A.variable_a" + ) + check(A.variable_b.__doc__, + "A_variable_b_get(A self) -> int", + "A.variable_b" + ) + check(A.variable_c.__doc__, + "\n" "A_variable_c_get(self) -> int\n" "\n" "Parameters:\n" " self: A *\n" "\n" + , + "A.variable_c" ) - check(A.variable_d.__doc__, "\n" + check(A.variable_d.__doc__, + "\n" "A_variable_d_get(A self) -> int\n" "\n" "Parameters:\n" " self: A *\n" "\n" + , + "A.variable_d" ) -check(B.__doc__, "Proxy of C++ B class") -check(C.__init__.__doc__, "__init__(self, a, b, h) -> C") -check(D.__init__.__doc__, "__init__(D self, int a, int b, Hola h) -> D") -check(E.__init__.__doc__, "\n" +check(B.__doc__, +"Proxy of C++ B class", +"::B" +) +check(C.__init__.__doc__, "__init__(self, a, b, h) -> C", None, skip) +check(D.__init__.__doc__, "__init__(D self, int a, int b, Hola h) -> D", None, skip) +check(E.__init__.__doc__, +"\n" " __init__(self, a, b, h) -> E\n" "\n" " Parameters:\n" @@ -153,8 +297,10 @@ check(E.__init__.__doc__, "\n" " h: enum Hola\n" "\n" " " +, None, skip ) -check(F.__init__.__doc__, "\n" +check(F.__init__.__doc__, +"\n" " __init__(F self, int a, int b, Hola h) -> F\n" "\n" " Parameters:\n" @@ -163,14 +309,23 @@ check(F.__init__.__doc__, "\n" " h: enum Hola\n" "\n" " " +, None, skip ) -check(B.funk.__doc__, "funk(B self, int c, int d) -> int") +check(B.funk.__doc__, +"funk(B self, int c, int d) -> int", +"funk(int c, int d) -> int") check(funk.__doc__, "funk(A e, short arg2, int c, int d) -> int") -check(funkdefaults.__doc__, "\n" +check(funkdefaults.__doc__, +"\n" " funkdefaults(A e, short arg2, int c, int d, double f=2) -> int\n" " funkdefaults(A e, short arg2, int c, int d) -> int\n" " " +, +"\n" +"funkdefaults(A e, short arg2, int c, int d, double f=2) -> int\n" +"funkdefaults(A e, short arg2, int c, int d) -> int\n" +"" ) check(func_input.__doc__, "func_input(int * INPUT) -> int") -- cgit v1.2.1 From ab79441151a15578b2b173378d7da5bdf4e3eb96 Mon Sep 17 00:00:00 2001 From: William S Fulton Date: Sat, 4 Oct 2014 18:40:19 +0100 Subject: Bypass Python tests not supported by -builtin The base class is needed for the builtin class hierarchy, like many other languages --- Examples/test-suite/import_nomodule.i | 9 ++++++++- Examples/test-suite/python/Makefile.in | 1 - Examples/test-suite/python/import_nomodule_runme.py | 5 +++++ 3 files changed, 13 insertions(+), 2 deletions(-) diff --git a/Examples/test-suite/import_nomodule.i b/Examples/test-suite/import_nomodule.i index 4fd5cbf65..60ef7e0f6 100644 --- a/Examples/test-suite/import_nomodule.i +++ b/Examples/test-suite/import_nomodule.i @@ -8,7 +8,7 @@ %import "import_nomodule.h" -#if !defined(SWIGJAVA) && !defined(SWIGRUBY) && !defined(SWIGCSHARP) && !defined(SWIGD) +#if !defined(SWIGJAVA) && !defined(SWIGRUBY) && !defined(SWIGCSHARP) && !defined(SWIGD) && !defined(SWIGPYTHON_BUILTIN) /** * The proxy class does not have Bar derived from Foo, yet an instance of Bar @@ -40,3 +40,10 @@ class Bar : public Foo { }; #endif +%inline %{ +#ifdef SWIGPYTHON_BUILTIN +bool is_python_builtin() { return true; } +#else +bool is_python_builtin() { return false; } +#endif +%} diff --git a/Examples/test-suite/python/Makefile.in b/Examples/test-suite/python/Makefile.in index 60253ac98..9d2f8aa6d 100644 --- a/Examples/test-suite/python/Makefile.in +++ b/Examples/test-suite/python/Makefile.in @@ -87,7 +87,6 @@ C_TEST_CASES += \ include $(srcdir)/../common.mk BUILTIN_BROKEN = \ - import_nomodule.cpptest \ python_abstractbase.cpptest \ BUILTIN_NOT_BROKEN = $(filter-out $(BUILTIN_BROKEN),$(NOT_BROKEN_TEST_CASES)) diff --git a/Examples/test-suite/python/import_nomodule_runme.py b/Examples/test-suite/python/import_nomodule_runme.py index ba0abfd9a..efcff9c48 100644 --- a/Examples/test-suite/python/import_nomodule_runme.py +++ b/Examples/test-suite/python/import_nomodule_runme.py @@ -1,5 +1,10 @@ from import_nomodule import * +# This test is expected to fail with -builtin option. +# The base class is needed for the builtin class hierarchy +if is_python_builtin(): + exit(0) + f = create_Foo() test1(f,42) delete_Foo(f) -- cgit v1.2.1 From 49038b30b771d7e7c079e0f3759313cf3d043217 Mon Sep 17 00:00:00 2001 From: William S Fulton Date: Mon, 6 Oct 2014 20:06:08 +0100 Subject: Bypass Python tests not supported by -builtin Builtin types can't inherit from pure-python abstract bases --- Examples/test-suite/python/Makefile.in | 7 ------- Examples/test-suite/python/python_abstractbase_runme3.py | 2 ++ Examples/test-suite/python_abstractbase.i | 8 ++++++++ 3 files changed, 10 insertions(+), 7 deletions(-) diff --git a/Examples/test-suite/python/Makefile.in b/Examples/test-suite/python/Makefile.in index 9d2f8aa6d..c39a9c806 100644 --- a/Examples/test-suite/python/Makefile.in +++ b/Examples/test-suite/python/Makefile.in @@ -86,13 +86,6 @@ C_TEST_CASES += \ include $(srcdir)/../common.mk -BUILTIN_BROKEN = \ - python_abstractbase.cpptest \ - -BUILTIN_NOT_BROKEN = $(filter-out $(BUILTIN_BROKEN),$(NOT_BROKEN_TEST_CASES)) - -builtin-check : $(BUILTIN_NOT_BROKEN) - # Overridden variables here SCRIPTDIR = . LIBS = -L. diff --git a/Examples/test-suite/python/python_abstractbase_runme3.py b/Examples/test-suite/python/python_abstractbase_runme3.py index 94dee3ff7..9b189964d 100644 --- a/Examples/test-suite/python/python_abstractbase_runme3.py +++ b/Examples/test-suite/python/python_abstractbase_runme3.py @@ -3,6 +3,8 @@ from collections import * # This is expected to fail with -builtin option # Builtin types can't inherit from pure-python abstract bases +if is_python_builtin(): + exit(0) assert issubclass(Mapii, MutableMapping) assert issubclass(Multimapii, MutableMapping) diff --git a/Examples/test-suite/python_abstractbase.i b/Examples/test-suite/python_abstractbase.i index f72688237..65f3d9931 100644 --- a/Examples/test-suite/python_abstractbase.i +++ b/Examples/test-suite/python_abstractbase.i @@ -16,3 +16,11 @@ namespace std %template(IntVector) vector; %template(IntList) list; } + +%inline %{ +#ifdef SWIGPYTHON_BUILTIN +bool is_python_builtin() { return true; } +#else +bool is_python_builtin() { return false; } +#endif +%} -- cgit v1.2.1 From a89a8928431034c389afbb9ef7bd3f8c5691d968 Mon Sep 17 00:00:00 2001 From: William S Fulton Date: Mon, 6 Oct 2014 20:22:51 +0100 Subject: Fixes when using python -builtin and STL container wrappers. Deletion of single elements previously failed. Test case li_std_containers_int now works. --- CHANGES.current | 4 ++++ Lib/python/pycontainer.swg | 14 ++++++++++++++ 2 files changed, 18 insertions(+) diff --git a/CHANGES.current b/CHANGES.current index 2638d9930..713f78d99 100644 --- a/CHANGES.current +++ b/CHANGES.current @@ -5,6 +5,10 @@ See the RELEASENOTES file for a summary of changes in each release. Version 3.0.3 (in progress) =========================== +2014-10-06: wsfulton + [Python] Fixes when using -builtin and std::vector/std::list wrappers to allow deletion + of single elements, such as 'del vec[0]'. + 2014-09-30: wsfulton [Python] Patch #207 - Fix No module error with -relativeimport when using single header file import. diff --git a/Lib/python/pycontainer.swg b/Lib/python/pycontainer.swg index 425cc45fc..e5543cd6b 100644 --- a/Lib/python/pycontainer.swg +++ b/Lib/python/pycontainer.swg @@ -874,6 +874,13 @@ namespace swig *(swig::getpos(self,i)) = x; } +#if defined(SWIGPYTHON_BUILTIN) + // This will be called through the mp_ass_subscript slot to delete an entry. + void __setitem__(difference_type i) throw (std::out_of_range) { + self->erase(swig::getpos(self,i)); + } +#endif + void append(const value_type& x) { self->push_back(x); } @@ -892,6 +899,13 @@ namespace swig *(swig::getpos(self,i)) = x; } +#if defined(SWIGPYTHON_BUILTIN) + // This will be called through the mp_ass_subscript slot to delete an entry. + void __setitem__(difference_type i) throw (std::out_of_range) { + self->erase(swig::getpos(self,i)); + } +#endif + void append(value_type x) { self->push_back(x); } -- cgit v1.2.1 From 9834a69c18478fdc3b78ba52faabf7c551aef531 Mon Sep 17 00:00:00 2001 From: William S Fulton Date: Mon, 6 Oct 2014 21:04:04 +0100 Subject: Fix Python 3 import_packages/relativeimport2 example clean runme3.py files are generated and should not be checked in --- Examples/python/import_packages/relativeimport2/runme3.py | 9 --------- 1 file changed, 9 deletions(-) delete mode 100644 Examples/python/import_packages/relativeimport2/runme3.py diff --git a/Examples/python/import_packages/relativeimport2/runme3.py b/Examples/python/import_packages/relativeimport2/runme3.py deleted file mode 100644 index 4b0d112cf..000000000 --- a/Examples/python/import_packages/relativeimport2/runme3.py +++ /dev/null @@ -1,9 +0,0 @@ -# Test import of modules content from within __init__.py -print("Testing %module(package=...) + python 'import' in __init__.py") -import sys -if sys.version_info < (3, 0): - import py2.pkg2.bar - print(" Finished importing py2.pkg2.bar") -else: - import py3.pkg2.bar - print(" Finished importing py3.pkg2.bar") -- cgit v1.2.1 From a9c6196f7120a12a6d3a46adef6814a2dc7a878d Mon Sep 17 00:00:00 2001 From: William S Fulton Date: Mon, 6 Oct 2014 21:32:05 +0100 Subject: Display testname when running the import_packages Python examples For easier identification of what is running in these examples. --- Examples/python/import_packages/from_init1/runme.py | 8 ++++++-- Examples/python/import_packages/from_init2/runme.py | 8 ++++++-- Examples/python/import_packages/from_init3/runme.py | 8 ++++++-- Examples/python/import_packages/relativeimport1/runme.py | 8 ++++++-- Examples/python/import_packages/relativeimport2/runme.py | 8 ++++++-- Examples/python/import_packages/relativeimport3/runme.py | 8 ++++++-- Examples/python/import_packages/same_modnames1/runme.py | 6 +++++- Examples/python/import_packages/same_modnames2/runme.py | 5 +++++ 8 files changed, 46 insertions(+), 13 deletions(-) diff --git a/Examples/python/import_packages/from_init1/runme.py b/Examples/python/import_packages/from_init1/runme.py index c23a085fa..bbe092bab 100644 --- a/Examples/python/import_packages/from_init1/runme.py +++ b/Examples/python/import_packages/from_init1/runme.py @@ -1,6 +1,10 @@ -# Test import of modules content from within __init__.py -print "Testing %module(package=...) + python 'import' in __init__.py" import sys +import os.path + +# Test import of modules content from within __init__.py +testname = os.path.basename(os.path.dirname(os.path.abspath(__file__))) +print "Testing " + testname + " - %module(package=...) + python 'import' in __init__.py" + if sys.version_info < (3,0): import py2.pkg2 print " Finished importing py2.pkg2" diff --git a/Examples/python/import_packages/from_init2/runme.py b/Examples/python/import_packages/from_init2/runme.py index c23a085fa..bbe092bab 100644 --- a/Examples/python/import_packages/from_init2/runme.py +++ b/Examples/python/import_packages/from_init2/runme.py @@ -1,6 +1,10 @@ -# Test import of modules content from within __init__.py -print "Testing %module(package=...) + python 'import' in __init__.py" import sys +import os.path + +# Test import of modules content from within __init__.py +testname = os.path.basename(os.path.dirname(os.path.abspath(__file__))) +print "Testing " + testname + " - %module(package=...) + python 'import' in __init__.py" + if sys.version_info < (3,0): import py2.pkg2 print " Finished importing py2.pkg2" diff --git a/Examples/python/import_packages/from_init3/runme.py b/Examples/python/import_packages/from_init3/runme.py index c23a085fa..bbe092bab 100644 --- a/Examples/python/import_packages/from_init3/runme.py +++ b/Examples/python/import_packages/from_init3/runme.py @@ -1,6 +1,10 @@ -# Test import of modules content from within __init__.py -print "Testing %module(package=...) + python 'import' in __init__.py" import sys +import os.path + +# Test import of modules content from within __init__.py +testname = os.path.basename(os.path.dirname(os.path.abspath(__file__))) +print "Testing " + testname + " - %module(package=...) + python 'import' in __init__.py" + if sys.version_info < (3,0): import py2.pkg2 print " Finished importing py2.pkg2" diff --git a/Examples/python/import_packages/relativeimport1/runme.py b/Examples/python/import_packages/relativeimport1/runme.py index 44ce8d1c4..99b6e513e 100644 --- a/Examples/python/import_packages/relativeimport1/runme.py +++ b/Examples/python/import_packages/relativeimport1/runme.py @@ -1,6 +1,10 @@ -# Test import of modules content from within __init__.py -print "Testing %module(package=...) with -relativeimport" import sys +import os.path + +# Test import of modules content from within __init__.py +testname = os.path.basename(os.path.dirname(os.path.abspath(__file__))) +print "Testing " + testname + " - %module(package=...) with -relativeimport" + if sys.version_info < (3,0): import py2.pkg2.bar print " Finished importing py2.pkg2.bar" diff --git a/Examples/python/import_packages/relativeimport2/runme.py b/Examples/python/import_packages/relativeimport2/runme.py index ac60eb630..f0ab6c446 100644 --- a/Examples/python/import_packages/relativeimport2/runme.py +++ b/Examples/python/import_packages/relativeimport2/runme.py @@ -1,6 +1,10 @@ -# Test import of modules content from within __init__.py -print "Testing %module(package=...) + python 'import' in __init__.py" import sys +import os.path + +# Test import of modules content from within __init__.py +testname = os.path.basename(os.path.dirname(os.path.abspath(__file__))) +print "Testing " + testname + " - %module(package=...) + python 'import' in __init__.py" + if sys.version_info < (3,0): import py2.pkg2.bar print " Finished importing py2.pkg2.bar" diff --git a/Examples/python/import_packages/relativeimport3/runme.py b/Examples/python/import_packages/relativeimport3/runme.py index 44ce8d1c4..99b6e513e 100644 --- a/Examples/python/import_packages/relativeimport3/runme.py +++ b/Examples/python/import_packages/relativeimport3/runme.py @@ -1,6 +1,10 @@ -# Test import of modules content from within __init__.py -print "Testing %module(package=...) with -relativeimport" import sys +import os.path + +# Test import of modules content from within __init__.py +testname = os.path.basename(os.path.dirname(os.path.abspath(__file__))) +print "Testing " + testname + " - %module(package=...) with -relativeimport" + if sys.version_info < (3,0): import py2.pkg2.bar print " Finished importing py2.pkg2.bar" diff --git a/Examples/python/import_packages/same_modnames1/runme.py b/Examples/python/import_packages/same_modnames1/runme.py index 923f0e0bb..7bec1ec1e 100644 --- a/Examples/python/import_packages/same_modnames1/runme.py +++ b/Examples/python/import_packages/same_modnames1/runme.py @@ -1,5 +1,9 @@ +import os.path + # Test import of same modules from different packages -print "Testing %module(package=...) + %import + same modules in different packages" +testname = os.path.basename(os.path.dirname(os.path.abspath(__file__))) +print "Testing " + testname + " - %module(package=...) + python 'import' in __init__.py" + import pkg2.foo print " Finished importing pkg2.foo" diff --git a/Examples/python/import_packages/same_modnames2/runme.py b/Examples/python/import_packages/same_modnames2/runme.py index af8f78194..eec6121eb 100644 --- a/Examples/python/import_packages/same_modnames2/runme.py +++ b/Examples/python/import_packages/same_modnames2/runme.py @@ -1,3 +1,8 @@ +import os.path + +testname = os.path.basename(os.path.dirname(os.path.abspath(__file__))) +print "Testing " + testname + " - %module(package=...) + python 'import' in __init__.py" + import pkg1.pkg2.foo print " Finished importing pkg1.pkg2.foo" -- cgit v1.2.1 From da394fae800ce121fb51d9c0ef2880fdce2f1b63 Mon Sep 17 00:00:00 2001 From: William S Fulton Date: Tue, 7 Oct 2014 20:07:32 +0100 Subject: Remove Python swigrun example By default it doesn't work as it does not call the CEO's __del__ method as indicated in the comments. __del__ is called with -builtin but then the base class's __del__ is not available and so it errors out. Python 3 and -builtin goes into an endless loop. So removing as hopelessly broken. --- Examples/python/check.list | 1 - Examples/python/swigrun/Makefile | 23 --------------- Examples/python/swigrun/example.cxx | 20 ------------- Examples/python/swigrun/example.h | 58 ------------------------------------- Examples/python/swigrun/example.i | 15 ---------- Examples/python/swigrun/runme.py | 28 ------------------ 6 files changed, 145 deletions(-) delete mode 100644 Examples/python/swigrun/Makefile delete mode 100644 Examples/python/swigrun/example.cxx delete mode 100644 Examples/python/swigrun/example.h delete mode 100644 Examples/python/swigrun/example.i delete mode 100644 Examples/python/swigrun/runme.py diff --git a/Examples/python/check.list b/Examples/python/check.list index e9e7c8357..a43a5fca0 100644 --- a/Examples/python/check.list +++ b/Examples/python/check.list @@ -24,7 +24,6 @@ simple smartptr std_vector std_map -swigrun template varargs variables diff --git a/Examples/python/swigrun/Makefile b/Examples/python/swigrun/Makefile deleted file mode 100644 index 94f7d04e0..000000000 --- a/Examples/python/swigrun/Makefile +++ /dev/null @@ -1,23 +0,0 @@ -TOP = ../.. -SWIG = $(TOP)/../preinst-swig -CXXSRCS = example.cxx -TARGET = example -INTERFACE = example.i -LIBS = -lm -SWIGOPT = - -check: build - $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' python_run - -build: - $(SWIG) -python -external-runtime - $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' $(SWIGLIB) CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ - SWIGOPT='$(SWIGOPT)' TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' python_cpp - -static: - $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' $(SWIGLIB) CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ - SWIGOPT='$(SWIGOPT)' TARGET='mypython' INTERFACE='$(INTERFACE)' python_cpp_static - -clean: - $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' TARGET='$(TARGET)' python_clean - rm -f swigpyrun.h diff --git a/Examples/python/swigrun/example.cxx b/Examples/python/swigrun/example.cxx deleted file mode 100644 index 2d2471301..000000000 --- a/Examples/python/swigrun/example.cxx +++ /dev/null @@ -1,20 +0,0 @@ -/* File : example.cxx */ - -#include -#include "swigpyrun.h" -#include "example.h" - - -Manager* convert_to_Manager(PyObject *py_obj) -{ - Manager* c_ptr; - swig_type_info *ty = SWIG_TypeQuery("Manager *"); - printf("manager ty %p \n", (void *)ty); - if (SWIG_ConvertPtr(py_obj, (void **) &c_ptr, ty, 0) == -1) { - c_ptr = 0; - } else { - Py_XINCREF(py_obj); - } - return c_ptr; -} - diff --git a/Examples/python/swigrun/example.h b/Examples/python/swigrun/example.h deleted file mode 100644 index e89f7baaa..000000000 --- a/Examples/python/swigrun/example.h +++ /dev/null @@ -1,58 +0,0 @@ -/* File : example.h */ - -#include -#include -#include -#include -#include - -class Employee { -private: - std::string name; -public: - Employee(const char* n): name(n) {} - virtual std::string getTitle() { return getPosition() + " " + getName(); } - virtual std::string getName() { return name; } - virtual std::string getPosition() const { return "Employee"; } - virtual ~Employee() { printf("~Employee() @ %p\n", (void *)this); } -}; - - -class Manager: public Employee { -public: - Manager(const char* n): Employee(n) {} - virtual std::string getPosition() const { return "Manager"; } -}; - - -class EmployeeList { - std::vector list; -public: - EmployeeList() { - list.push_back(new Employee("Bob")); - list.push_back(new Employee("Jane")); - list.push_back(new Manager("Ted")); - } - void addEmployee(Employee *p) { - list.push_back(p); - std::cout << "New employee added. Current employees are:" << std::endl; - std::vector::iterator i; - for (i=list.begin(); i!=list.end(); i++) { - std::cout << " " << (*i)->getTitle() << std::endl; - } - } - const Employee *get_item(int i) { - return list[i]; - } - ~EmployeeList() { - std::vector::iterator i; - std::cout << "~EmployeeList, deleting " << list.size() << " employees." << std::endl; - for (i=list.begin(); i!=list.end(); i++) { - delete *i; - } - std::cout << "~EmployeeList empty." << std::endl; - } -}; - -Manager* convert_to_Manager(PyObject *obj); - diff --git a/Examples/python/swigrun/example.i b/Examples/python/swigrun/example.i deleted file mode 100644 index c8ec32e09..000000000 --- a/Examples/python/swigrun/example.i +++ /dev/null @@ -1,15 +0,0 @@ -/* File : example.i */ -%module(directors="1") example -%{ -#include "example.h" -%} - -%include "std_vector.i" -%include "std_string.i" - -/* turn on director wrapping for Manager */ -%feature("director") Employee; -%feature("director") Manager; - -%include "example.h" - diff --git a/Examples/python/swigrun/runme.py b/Examples/python/swigrun/runme.py deleted file mode 100644 index abcd96463..000000000 --- a/Examples/python/swigrun/runme.py +++ /dev/null @@ -1,28 +0,0 @@ -# file: runme.py - -# This file illustrates the cross language polymorphism using directors. - -import example - - -# CEO class, which overrides Employee::getPosition(). - -class CEO(example.Manager): - def __init__(self, name): - example.Manager.__init__(self, name) - def getPosition(self): - return "CEO" - def __del__(self): - print "CEO.__del__(),", self.getName() - # for proxy class extensions that are not "disowned" and - # define a __del__ method, it is very important to call the - # base class __del__. otherwise the c++ objects will never - # be deleted. - example.Manager.__del__(self) - - - - -e = CEO("Alice") -m = example.convert_to_Manager(e) -print m -- cgit v1.2.1 From 808d4b4798685dbbc8515277faa573c7ce40fbc2 Mon Sep 17 00:00:00 2001 From: William S Fulton Date: Tue, 7 Oct 2014 20:13:32 +0100 Subject: Bypass Python exmples not supported by -builtin Builtin classes as exceptions not supported, so don't run these aspects of the examples when using -builtin. --- Examples/python/exception/example.i | 9 +++++++++ Examples/python/exception/runme.py | 15 +++++++++++---- Examples/python/exceptproxy/example.i | 10 ++++++++-- Examples/python/exceptproxy/runme.py | 6 ++++++ 4 files changed, 34 insertions(+), 6 deletions(-) diff --git a/Examples/python/exception/example.i b/Examples/python/exception/example.i index 08672c3a8..817c5221c 100644 --- a/Examples/python/exception/example.i +++ b/Examples/python/exception/example.i @@ -10,3 +10,12 @@ /* Let's just grab the original header file here */ %include "example.h" +%inline %{ +// The -builtin SWIG option results in SWIGPYTHON_BUILTIN being defined +#ifdef SWIGPYTHON_BUILTIN +bool is_python_builtin() { return true; } +#else +bool is_python_builtin() { return false; } +#endif +%} + diff --git a/Examples/python/exception/runme.py b/Examples/python/exception/runme.py index 718707861..9e9241194 100644 --- a/Examples/python/exception/runme.py +++ b/Examples/python/exception/runme.py @@ -20,10 +20,17 @@ try: except RuntimeError,e: print e.args[0] -try: - t.hosed() -except example.Exc,e: - print e.code, e.msg +if not example.is_python_builtin(): + try: + t.hosed() + except example.Exc,e: + print e.code, e.msg +else: + try: + t.hosed() + except BaseException,e: + # Throwing builtin classes as exceptions not supported (-builtin option) + print e for i in range(1,4): try: diff --git a/Examples/python/exceptproxy/example.i b/Examples/python/exceptproxy/example.i index 4a1e0bae9..0a46afbb6 100644 --- a/Examples/python/exceptproxy/example.i +++ b/Examples/python/exceptproxy/example.i @@ -109,6 +109,12 @@ %template(doubleQueue) Queue; - - +%inline %{ +// The -builtin SWIG option results in SWIGPYTHON_BUILTIN being defined +#ifdef SWIGPYTHON_BUILTIN +bool is_python_builtin() { return true; } +#else +bool is_python_builtin() { return false; } +#endif +%} diff --git a/Examples/python/exceptproxy/runme.py b/Examples/python/exceptproxy/runme.py index a2ae55584..07e4b0a7f 100644 --- a/Examples/python/exceptproxy/runme.py +++ b/Examples/python/exceptproxy/runme.py @@ -1,10 +1,16 @@ # file: runme.py import example +if example.is_python_builtin(): + print "Skipping example: -builtin option does not support %exceptionclass" + exit(0) + q = example.intQueue(10) print "Inserting items into intQueue" +print type(example.FullError) + try: for i in range(0,100): q.enqueue(i) -- cgit v1.2.1 From a9c9c9c848c06cb542e52a0fe4885653de411e9e Mon Sep 17 00:00:00 2001 From: William S Fulton Date: Thu, 9 Oct 2014 19:33:40 +0100 Subject: Revert "Octave: remove unused field SwigOctClass::constructor_doc" This reverts commit afa9affcd97ea05d4bac538407b47a06df6f09a1. Reverting a series of Octave commits for re-applying again without incorrect whitespace changes. --- Lib/octave/octrundecl.swg | 1 + Source/Modules/octave.cxx | 6 ++++-- 2 files changed, 5 insertions(+), 2 deletions(-) diff --git a/Lib/octave/octrundecl.swg b/Lib/octave/octrundecl.swg index a1b2de778..c451f6951 100644 --- a/Lib/octave/octrundecl.swg +++ b/Lib/octave/octrundecl.swg @@ -229,6 +229,7 @@ struct SwigOctClass { swig_type_info** type; int director; SwigOctFuncPtr constructor; + const char* constructor_doc; SwigOctFuncPtr destructor; const SwigOctMember* members; const char** base_names; diff --git a/Source/Modules/octave.cxx b/Source/Modules/octave.cxx index b9c7a2a12..ec54e8b99 100644 --- a/Source/Modules/octave.cxx +++ b/Source/Modules/octave.cxx @@ -1039,11 +1039,13 @@ public: String* nspace = Getattr(n, "sym:nspace"); String* cname = Swig_name_construct(nspace, constructor_name); String* wcname = Swig_name_wrapper(cname); - Printf(f_wrappers, "%s,", wcname); + String* tname = texinfo_name(n); + Printf(f_wrappers, "%s,%s,", wcname, tname); + Delete(tname); Delete(wcname); Delete(cname); } else { - Printv(f_wrappers, "0,", NIL); + Printv(f_wrappers, "0,0,", NIL); } if (have_destructor) { String* nspace = Getattr(n, "sym:nspace"); -- cgit v1.2.1 From 851f122bfe8ab3482564e860a9d209108c4d7d3b Mon Sep 17 00:00:00 2001 From: William S Fulton Date: Thu, 9 Oct 2014 19:33:48 +0100 Subject: Revert "Octave: remove unused function SwigOctType::help_text()" This reverts commit 8c7e578279b17d6133992383e9da04abb2690b90. Reverting a series of Octave commits for re-applying again without incorrect whitespace changes. --- Lib/octave/octrunclass.swg | 12 ++++++++++++ Lib/octave/octrundecl.swg | 1 + 2 files changed, 13 insertions(+) diff --git a/Lib/octave/octrunclass.swg b/Lib/octave/octrunclass.swg index 3070e79d1..2310a45b8 100644 --- a/Lib/octave/octrunclass.swg +++ b/Lib/octave/octrunclass.swg @@ -329,6 +329,18 @@ long SwigOctType::swig_this() const return (long) types[0].second.ptr; } +const char* SwigOctType::help_text() const +{ + if (!types.size()) { + return 0; + } + if (!types[0].first->clientdata) { + return 0; + } + SwigOctClass* c = (SwigOctClass*) types[0].first->clientdata; + return c->constructor_doc; +} + std::string SwigOctType::swig_type_name() const { // * need some way to manually name subclasses. diff --git a/Lib/octave/octrundecl.swg b/Lib/octave/octrundecl.swg index c451f6951..6452aec97 100644 --- a/Lib/octave/octrundecl.swg +++ b/Lib/octave/octrundecl.swg @@ -317,6 +317,7 @@ public: static bool dispatch_global_op(const std::string& symbol, const octave_value_list& args, octave_value& ret); static octave_value dispatch_unary_op(const octave_base_value& x, const char* op_name); octave_base_value* empty_clone() const; + const char* help_text() const; void incref(); bool is_defined() const; virtual bool is_map() const; -- cgit v1.2.1 From 15961d581e5a914402ad17a87eec6f5d4407d3f5 Mon Sep 17 00:00:00 2001 From: William S Fulton Date: Thu, 9 Oct 2014 19:33:51 +0100 Subject: Revert "Revert "Suppress Octave failing the build"" This reverts commit 492b1b0339441ecc7e0eed0166d2e9981c9d3c2a. Reverting a series of Octave commits for re-applying again without incorrect whitespace changes. --- .travis.yml | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/.travis.yml b/.travis.yml index 4266e7183..fca1941a9 100644 --- a/.travis.yml +++ b/.travis.yml @@ -47,7 +47,9 @@ matrix: - compiler: gcc env: SWIGLANG=tcl allow_failures: - # None + # g++-4.6.3 internal compiler error for li_std_vector testcase + - compiler: gcc + env: SWIGLANG=octave SWIGJOBS=-j4 before_install: - date -u - uname -a -- cgit v1.2.1 From f5d714378a9fc974e607c9a660c80cba7812ddd9 Mon Sep 17 00:00:00 2001 From: William S Fulton Date: Thu, 9 Oct 2014 19:33:53 +0100 Subject: Revert ".travis.yml: reduce Octave make jobs to 3" This reverts commit 90c32a11c24b9a47820f7ab88448cc0261219cf9. Reverting a series of Octave commits for re-applying again without incorrect whitespace changes. --- .travis.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.travis.yml b/.travis.yml index fca1941a9..8521e0cc6 100644 --- a/.travis.yml +++ b/.travis.yml @@ -23,7 +23,7 @@ matrix: - compiler: gcc env: SWIGLANG=lua - compiler: gcc - env: SWIGLANG=octave SWIGJOBS=-j3 + env: SWIGLANG=octave SWIGJOBS=-j4 - compiler: gcc env: SWIGLANG=perl5 - compiler: gcc -- cgit v1.2.1 From b1595014e772c7ecc56b114bf994f35d75c58ba6 Mon Sep 17 00:00:00 2001 From: William S Fulton Date: Thu, 9 Oct 2014 19:33:55 +0100 Subject: Revert "Octave: disable optimization of tests for faster compiles/less memory usage" This reverts commit 8e37bcf1a88ba4df783b39c77e6132a51a4536a5. Reverting a series of Octave commits for re-applying again without incorrect whitespace changes. --- Tools/config/ax_check_compile_flag.m4 | 74 ----------------------------------- configure.ac | 27 ++++--------- 2 files changed, 7 insertions(+), 94 deletions(-) delete mode 100644 Tools/config/ax_check_compile_flag.m4 diff --git a/Tools/config/ax_check_compile_flag.m4 b/Tools/config/ax_check_compile_flag.m4 deleted file mode 100644 index 51df0c09a..000000000 --- a/Tools/config/ax_check_compile_flag.m4 +++ /dev/null @@ -1,74 +0,0 @@ -# =========================================================================== -# http://www.gnu.org/software/autoconf-archive/ax_check_compile_flag.html -# =========================================================================== -# -# SYNOPSIS -# -# AX_CHECK_COMPILE_FLAG(FLAG, [ACTION-SUCCESS], [ACTION-FAILURE], [EXTRA-FLAGS], [INPUT]) -# -# DESCRIPTION -# -# Check whether the given FLAG works with the current language's compiler -# or gives an error. (Warnings, however, are ignored) -# -# ACTION-SUCCESS/ACTION-FAILURE are shell commands to execute on -# success/failure. -# -# If EXTRA-FLAGS is defined, it is added to the current language's default -# flags (e.g. CFLAGS) when the check is done. The check is thus made with -# the flags: "CFLAGS EXTRA-FLAGS FLAG". This can for example be used to -# force the compiler to issue an error when a bad flag is given. -# -# INPUT gives an alternative input source to AC_COMPILE_IFELSE. -# -# NOTE: Implementation based on AX_CFLAGS_GCC_OPTION. Please keep this -# macro in sync with AX_CHECK_{PREPROC,LINK}_FLAG. -# -# LICENSE -# -# Copyright (c) 2008 Guido U. Draheim -# Copyright (c) 2011 Maarten Bosmans -# -# This program is free software: you can redistribute it and/or modify it -# under the terms of the GNU General Public License as published by the -# Free Software Foundation, either version 3 of the License, or (at your -# option) any later version. -# -# This program is distributed in the hope that it will be useful, but -# WITHOUT ANY WARRANTY; without even the implied warranty of -# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General -# Public License for more details. -# -# You should have received a copy of the GNU General Public License along -# with this program. If not, see . -# -# As a special exception, the respective Autoconf Macro's copyright owner -# gives unlimited permission to copy, distribute and modify the configure -# scripts that are the output of Autoconf when processing the Macro. You -# need not follow the terms of the GNU General Public License when using -# or distributing such scripts, even though portions of the text of the -# Macro appear in them. The GNU General Public License (GPL) does govern -# all other use of the material that constitutes the Autoconf Macro. -# -# This special exception to the GPL applies to versions of the Autoconf -# Macro released by the Autoconf Archive. When you make and distribute a -# modified version of the Autoconf Macro, you may extend this special -# exception to the GPL to apply to your modified version as well. - -#serial 3 - -AC_DEFUN([AX_CHECK_COMPILE_FLAG], -[AC_PREREQ(2.59)dnl for _AC_LANG_PREFIX -AS_VAR_PUSHDEF([CACHEVAR],[ax_cv_check_[]_AC_LANG_ABBREV[]flags_$4_$1])dnl -AC_CACHE_CHECK([whether _AC_LANG compiler accepts $1], CACHEVAR, [ - ax_check_save_flags=$[]_AC_LANG_PREFIX[]FLAGS - _AC_LANG_PREFIX[]FLAGS="$[]_AC_LANG_PREFIX[]FLAGS $4 $1" - AC_COMPILE_IFELSE([m4_default([$5],[AC_LANG_PROGRAM()])], - [AS_VAR_SET(CACHEVAR,[yes])], - [AS_VAR_SET(CACHEVAR,[no])]) - _AC_LANG_PREFIX[]FLAGS=$ax_check_save_flags]) -AS_IF([test x"AS_VAR_GET(CACHEVAR)" = xyes], - [m4_default([$2], :)], - [m4_default([$3], :)]) -AS_VAR_POPDEF([CACHEVAR])dnl -])dnl AX_CHECK_COMPILE_FLAGS diff --git a/configure.ac b/configure.ac index 017fc5a0c..78c276029 100644 --- a/configure.ac +++ b/configure.ac @@ -937,38 +937,25 @@ fi if test -n "$OCTAVE"; then AC_MSG_CHECKING([for Octave preprocessor flags]) OCTAVE_CPPFLAGS= - for var in CPPFLAGS INCFLAGS ALL_CXXFLAGS; do - for flag in `env - ${mkoctfile} -p ${var}`; do - case ${flag} in - -D*|-I*) OCTAVE_CPPFLAGS="${OCTAVE_CPPFLAGS} ${flag}";; - *) ;; - esac - done + for n in CPPFLAGS INCFLAGS; do + OCTAVE_CPPFLAGS="${OCTAVE_CPPFLAGS} "`unset CPPFLAGS; ${mkoctfile} -p $n` done AC_MSG_RESULT([$OCTAVE_CPPFLAGS]) AC_MSG_CHECKING([for Octave compiler flags]) OCTAVE_CXXFLAGS= - for var in ALL_CXXFLAGS; do - for flag in `env - ${mkoctfile} -p ${var}`; do - case ${flag} in - -g*|-W*) OCTAVE_CXXFLAGS="${OCTAVE_CXXFLAGS} ${flag}";; - *) ;; - esac - done + for n in ALL_CXXFLAGS; do + OCTAVE_CXXFLAGS="${OCTAVE_CXXFLAGS} "`unset CXXFLAGS; ${mkoctfile} -p $n` done AC_MSG_RESULT([$OCTAVE_CXXFLAGS]) - AC_LANG_PUSH([C++]) - AX_CHECK_COMPILE_FLAG([-O0],[OCTAVE_CXXFLAGS="${OCTAVE_CXXFLAGS} -O0"],[],[-Werror]) - AC_LANG_POP([C++]) AC_MSG_CHECKING([for Octave linker flags]) OCTAVE_LDFLAGS= - for var in RDYNAMIC_FLAG LFLAGS RLD_FLAG OCTAVE_LIBS LIBS; do - OCTAVE_LDFLAGS="${OCTAVE_LDFLAGS} "`env - ${mkoctfile} -p ${var}` + for n in RDYNAMIC_FLAG LFLAGS RLD_FLAG OCTAVE_LIBS LIBS; do + OCTAVE_LDFLAGS="${OCTAVE_LDFLAGS} "`${mkoctfile} -p $n` done AC_MSG_RESULT([$OCTAVE_LDFLAGS]) for octave_opt in --silent --norc --no-history --no-window-system; do AC_MSG_CHECKING([if Octave option '${octave_opt}' is supported]) - octave_out=`${OCTAVE} ${octave_opt} /dev/null 2>&1 | sed -n '1p' | sed -n '/unrecognized/p'` + octave_out=`${OCTAVE} ${octave_opt} /dev/null 2>&1 | sed -n '1{/unrecognized/p}'` AS_IF([test "x${octave_out}" = x],[ AC_MSG_RESULT([yes]) OCTAVE="${OCTAVE} ${octave_opt}" -- cgit v1.2.1 From bfa3d378eccd3817d39db44055f05600008340f4 Mon Sep 17 00:00:00 2001 From: William S Fulton Date: Thu, 9 Oct 2014 19:33:58 +0100 Subject: Revert "Octave: drop support for Octave versions older than 3.2.0" This reverts commit 952eee8f5904f85411d28dd375cc7df67f74b95a. Reverting a series of Octave commits for re-applying again without incorrect whitespace changes. --- CHANGES.current | 7 ------- Doc/Manual/Octave.html | 5 +++-- Examples/octave/module_load/runme.m | 6 ++++++ Lib/octave/octrundecl.swg | 11 +++++------ Lib/octave/octrunfunc.swg | 4 ++++ Lib/octave/octruninit.swg | 8 +++++++- 6 files changed, 25 insertions(+), 16 deletions(-) diff --git a/CHANGES.current b/CHANGES.current index 3b81a63bd..b305c7627 100644 --- a/CHANGES.current +++ b/CHANGES.current @@ -5,13 +5,6 @@ See the RELEASENOTES file for a summary of changes in each release. Version 3.0.3 (in progress) =========================== -2014-10-04: kwwette - [Octave] Drop support for Octave versions older than 3.2.0 - - Latest non-supported version is 3.0.5, released 2009-04-09 - - Earliest supported version is 3.2.0, released 2009-06-05 - - *** POTENTIAL INCOMPATIBILITY *** - 2014-09-30: oliverb [Javascript] Merge patch #216 by Richie765 - Added support for many versions of v8 javascript. diff --git a/Doc/Manual/Octave.html b/Doc/Manual/Octave.html index 3ba477b37..e48083afd 100644 --- a/Doc/Manual/Octave.html +++ b/Doc/Manual/Octave.html @@ -58,8 +58,9 @@ in the test suite (Examples/test-suite and Examples/test-suite/octave).

    32.1 Preliminaries

    -SWIG version 3.0.3 supports only Octave version 3.2.0 or later. It has -been tested with Octave versions 3.2.4, 3.4.3, 3.6.4, and 3.8.1. +As of SWIG 3.0.0, the Octave module has been tested with Octave versions 3.0.5, +3.2.4, 3.4.3, 3.6.4, and 3.8.0. Use of Octave versions older than 3.x.x is not +recommended, as these versions are no longer tested with SWIG.

    32.2 Running SWIG

    diff --git a/Examples/octave/module_load/runme.m b/Examples/octave/module_load/runme.m index 758df9c93..bc311b5e6 100644 --- a/Examples/octave/module_load/runme.m +++ b/Examples/octave/module_load/runme.m @@ -61,6 +61,12 @@ testme testme clear all +# octave 3.0.5 randomly crashes on the remaining tests, so skip them +api_version = sscanf(octave_config_info("api_version"), "api-v%i"); +if api_version < 37 + exit +endif + # load module with no cvar clear all; swigexample2; diff --git a/Lib/octave/octrundecl.swg b/Lib/octave/octrundecl.swg index 6452aec97..f71895abb 100644 --- a/Lib/octave/octrundecl.swg +++ b/Lib/octave/octrundecl.swg @@ -101,11 +101,6 @@ #endif // !defined(OCTAVE_MAJOR_VERSION) -// Set minimum supported Octave version -#if !SWIG_OCTAVE_PREREQ(3,2,0) -#error This version of SWIG supports only Octave version 3.2.0 or later -#endif - // Octave_map was renamed to octave_map in v3.3.52 #if !SWIG_OCTAVE_PREREQ(3,3,52) #define octave_map Octave_map @@ -113,7 +108,11 @@ ////////// Declare/define SWIG interface function loadable by Octave ////////// -#define SWIG_DEFUN(cname, wname, doc) DEFUNX_DLD(#cname, wname, G ## cname, args, nargout, doc) +#if !SWIG_OCTAVE_PREREQ(3,2,0) +#define SWIG_DEFUN(cname, wname, doc) DEFUNX_DLD(#cname, wname, FS ## cname, args, nargout, doc) +#else +#define SWIG_DEFUN(cname, wname, doc) DEFUNX_DLD(#cname, wname, G ## cname, args, nargout, doc) +#endif ////////// Define visibility of Octave runtime functions ////////// diff --git a/Lib/octave/octrunfunc.swg b/Lib/octave/octrunfunc.swg index 34dae2ee2..6773373b8 100644 --- a/Lib/octave/octrunfunc.swg +++ b/Lib/octave/octrunfunc.swg @@ -130,10 +130,14 @@ SWIGOCTRT void SWIG_Octave_SetGlobalValue(std::string name, const octave_value& SWIGOCTRT void SWIG_Octave_LinkGlobalValue(std::string name) { +#if !SWIG_OCTAVE_PREREQ(3,2,0) + link_to_global_variable(curr_sym_tab->lookup(name, true)); +#else #if !SWIG_OCTAVE_PREREQ(3,8,0) symbol_table::varref(name); #endif symbol_table::mark_global(name); +#endif } SWIGOCTRT swig_module_info* SWIG_Octave_GetModule(void* clientdata) diff --git a/Lib/octave/octruninit.swg b/Lib/octave/octruninit.swg index 7d83a5633..86d033af2 100644 --- a/Lib/octave/octruninit.swg +++ b/Lib/octave/octruninit.swg @@ -295,7 +295,7 @@ DEFUN_DLD(SWIG_name, args, nargout, SWIG_name_usage) // definitely affects version 3.2.*, not sure about 3.3.*, seems to be fixed in // version 3.4.* and above. can be turned off with macro definition. #ifndef SWIG_OCTAVE_NO_SEGFAULT_HACK -#if !SWIG_OCTAVE_PREREQ(3,4,1) +#if SWIG_OCTAVE_PREREQ(3,2,0) && !SWIG_OCTAVE_PREREQ(3,4,1) octave_exit = ::_Exit; #endif #endif @@ -311,6 +311,7 @@ DEFUN_DLD(SWIG_name, args, nargout, SWIG_name_usage) // workaround bug in octave where installing global variable of custom type and then // exiting without explicitly clearing the variable causes octave to segfault. +#if SWIG_OCTAVE_PREREQ(3,2,0) octave_value_list eval_args; eval_args.append("base"); eval_args.append("function __swig_atexit__; " @@ -324,6 +325,7 @@ DEFUN_DLD(SWIG_name, args, nargout, SWIG_name_usage) "atexit(\"__swig_atexit__\", false); " "atexit(\"__swig_atexit__\")"); feval("evalin", eval_args, 0); +#endif SwigOctRef::register_type(); SwigOctPacked::register_type(); @@ -396,7 +398,11 @@ DEFUN_DLD(SWIG_name, args, nargout, SWIG_name_usage) } } +#if !SWIG_OCTAVE_PREREQ(3,2,0) + mlock(me->name()); +#else mlock(); +#endif } -- cgit v1.2.1 From 457ba43989951d3bdd6abb8b91f19da094658c17 Mon Sep 17 00:00:00 2001 From: William S Fulton Date: Thu, 9 Oct 2014 19:34:00 +0100 Subject: Revert "Octave: whitespace/style cleanup of Doc/Manual/Octave.html" This reverts commit 56fefcc7e0adb2a4a25a30280047c1d7c097454f. Reverting a series of Octave commits for re-applying again without incorrect whitespace changes. --- Doc/Manual/Octave.html | 453 +++++++++++++++++-------------------------------- 1 file changed, 153 insertions(+), 300 deletions(-) diff --git a/Doc/Manual/Octave.html b/Doc/Manual/Octave.html index e48083afd..9c3489fb8 100644 --- a/Doc/Manual/Octave.html +++ b/Doc/Manual/Octave.html @@ -5,6 +5,7 @@ +

    32 SWIG and Octave

    @@ -42,29 +43,29 @@
    + +

    -Octave is a high-level language intended for numerical programming that is -mostly compatible with MATLAB. More information can be found -at Octave web site. + Octave is a high-level language intended for numerical programming that is mostly compatible with MATLAB. +More information can be found at Octave web site.

    -This chapter is intended to give an introduction to using the module. You -should also read the SWIG documentation that is not specific to Octave. Also, -there are a dozen or so examples in the Examples/octave directory, and hundreds -in the test suite (Examples/test-suite and Examples/test-suite/octave). + This chapter is intended to give an introduction to using the module. You should also read the SWIG documentation that is not specific to Octave. +Also, there are a dozen or so examples in the Examples/octave directory, and hundreds in the test suite (Examples/test-suite and Examples/test-suite/octave).

    32.1 Preliminaries

    +

    -As of SWIG 3.0.0, the Octave module has been tested with Octave versions 3.0.5, -3.2.4, 3.4.3, 3.6.4, and 3.8.0. Use of Octave versions older than 3.x.x is not -recommended, as these versions are no longer tested with SWIG. +As of SWIG 3.0.0, the Octave module has been tested with Octave versions 3.0.5, 3.2.4, 3.4.3, 3.6.4, and 3.8.0. +Use of Octave versions older than 3.x.x is not recommended, as these versions are no longer tested with SWIG.

    32.2 Running SWIG

    +

    Let's start with a very simple SWIG interface file, example.i:

    @@ -75,67 +76,54 @@ Let's start with a very simple SWIG interface file, example.i: #include "example.h" %} int gcd(int x, int y); -extern double Foo; -
    +extern double Foo;

    -To build an Octave module when wrapping C code, run swig using -the -octave option: +To build an Octave module when wrapping C code, run SWIG using the -octave option:

    -
    -$ swig -octave -o example_wrap.cpp example.i
    -
    +
    $ swig -octave -o example_wrap.cpp example.i 

    The -c++ option is also required when wrapping C++ code:

    -
    -$ swig -octave -c++ -o example_wrap.cpp example.i
    -
    + +
    $ swig -octave -c++ -o example_wrap.cpp example.i 

    -This creates a C++ source file example_wrap.cpp. A C++ file is -generated even when wrapping C code as Octave is itself written in C++ and -requires wrapper code to be in the same language. The generated C++ source file -contains the low-level wrappers that need to be compiled and linked with the -rest of your C/C++ application (in this case, the gcd implementation) to create -an extension module. +This creates a C++ source file "example_wrap.cpp". A C++ file is generated even when wrapping C code as Octave is itself written in C++ and requires wrapper code to be in the same language. The generated C++ source file contains the low-level wrappers that need to be compiled and linked with the rest of your C/C++ application (in this case, the gcd implementation) to create an extension module.

    32.2.1 Command-line options

    +

    -The swig command line has a number of options you can use, like to -redirect its output. Use swig -help to learn about these. Options -specific to the Octave module are: +The swig command line has a number of options you can use, like to redirect its output. Use swig -help to learn about these. +Options specific to the Octave module are:

    $ swig -octave -help
     ...
     Octave Options (available with -octave)
    -     -globals <name> - Set <name> used to access C global variables [default: 'cvar']
    -		       Use '.' to load C global variables into module namespace
    -     -opprefix <str> - Prefix <str> for global operator functions [default: 'op_']
    +     -globals name - Set name used to access C global variables [default: 'cvar']
    +                     Use '.' to load C global variables into module namespace
    +     -opprefix str - Prefix str for global operator functions [default: 'op_']
     

    -The -globals option sets the name of the variable which is the -namespace for C global variables exported by the module. The special -name . loads C global variables into the module namespace, -i.e. alongside C functions and structs exported by the module. -The -opprefix options sets the prefix of the names of -global/friend operator functions. +The -globals option sets the name of the variable which is the namespace for C global variables exported by the module. +The special name "." loads C global variables into the module namespace, i.e. alongside C functions and structs exported by the module. +The -opprefix options sets the prefix of the names of global/friend operator functions.

    32.2.2 Compiling a dynamic module

    +

    -Octave modules are DLLs/shared objects having the .oct suffix. -Building an .oct file is usually done with the mkoctfile -command (either within Octave itself, or from the shell). For example, +Octave modules are DLLs/shared objects having the ".oct" suffix. +Building an oct file is usually done with the mkoctfile command (either within Octave itself, or from the shell). For example,

    @@ -144,30 +132,28 @@ $ mkoctfile example_wrap.cpp example.c
     

    -where example.c is the file containing the gcd() implementation. + where "example.c" is the file containing the gcd() implementation.

    -mkoctfile can also be used to extract the build parameters required to -invoke the compiler and linker yourself. See the Octave manual -and mkoctfile man page. + mkoctfile can also be used to extract the build parameters required to invoke the compiler and linker yourself. See the Octave manual and mkoctfile man page.

    -mkoctfile will produce swigexample.oct, which contains the -compiled extension module. Loading it into Octave is then a matter of invoking + mkoctfile will produce "swigexample.oct", which contains the compiled extension module. Loading it into Octave is then a matter of invoking

    -
    octave:1> swigexample
    -
    +
    octave:1> swigexample

    32.2.3 Using your module

    +

    -Assuming all goes well, you will be able to do this: +Assuming all goes well, you will be able to do this: +

    -
    $ octave -q
    +          
    $ octave -q
     octave:1> swigexample
     octave:2> swigexample.gcd(4,6)
     ans =  2
    @@ -175,27 +161,20 @@ octave:3> swigexample.cvar.Foo
     ans =  3
     octave:4> swigexample.cvar.Foo=4;
     octave:5> swigexample.cvar.Foo
    -ans =  4
    -
    +ans = 4

    32.3 A tour of basic C/C++ wrapping

    +

    32.3.1 Modules

    +

    -The SWIG module directive specifies the name of the Octave module. If -you specify module swigexample, then in Octave everything in the module -will be accessible under swigexample, as in the above example. When -choosing a module name, make sure you don't use the same name as a built-in -Octave command or standard module name. +The SWIG module directive specifies the name of the Octave module. If you specify "module swigexample", then in Octave everything in the module will be accessible under "swigexample", as in the above example. When choosing a module name, make sure you don't use the same name as a built-in Octave command or standard module name.

    -When Octave is asked to invoke swigexample, it will try to find -the .m or .oct file that defines the -function swigexample. You therefore need to make sure -that swigexample.oct is in Octave's search path, which can be specified -with the environment variable OCTAVE_PATH. +When Octave is asked to invoke swigexample, it will try to find the ".m" or ".oct" file that defines the function "swigexample". You therefore need to make sure that "swigexample.oct" is in Octave's search path, which can be specified with the environment variable "OCTAVE_PATH".

    @@ -214,9 +193,8 @@ ans = 4

    -Modules can also be loaded from within functions, even before being loaded in -the base context. If the module is also used in the base context, however, it -must first be loaded again: +Modules can also be loaded from within functions, even before being loaded in the base context. +If the module is also used in the base context, however, it must first be loaded again:

    @@ -235,135 +213,112 @@ ans =  2
     
     

    32.3.2 Functions

    +

    -Global functions are wrapped as new Octave built-in functions. For example, +Global functions are wrapped as new Octave built-in functions. For example,

    -
    -%module swigexample
    -int fact(int n);
    -
    +
    %module swigexample
    +int fact(int n); 

    -creates a built-in function swigexample.fact(n) that works exactly like -you think it does: + creates a built-in function swigexample.fact(n) that works exactly like you think it does:

    -
    octave:1> swigexample.fact(4)
    -24
    -
    +
    octave:1> swigexample.fact(4)
    +24 

    32.3.3 Global variables

    +

    -Global variables are a little special in Octave. Given a global variable: + Global variables are a little special in Octave. Given a global variable:

    -
    -%module swigexample
    +
    %module swigexample
     extern double Foo;
     

    -To expose variables, SWIG actually generates two functions, to get and set the -value. In this case, Foo_set and Foo_set would be -generated. SWIG then automatically calls these functions when you get and set -the variable -- in the former case creating a local copy in the interpreter of -the C variables, and in the latter case copying an interpreter variables onto -the C variable. + To expose variables, SWIG actually generates two functions, to get and set the value. In this case, Foo_set and Foo_set would be generated. SWIG then automatically calls these functions when you get and set the variable-- in the former case creating a local copy in the interpreter of the C variables, and in the latter case copying an interpreter variables onto the C variable.

    -
    octave:1> swigexample;
    +    
    octave:1> swigexample;
     octave:2> c=swigexample.cvar.Foo
     c =  3
     octave:3> swigexample.cvar.Foo=4;
     octave:4> c
     c =  3
     octave:5> swigexample.cvar.Foo
    -ans =  4
    -
    +ans = 4

    -If a variable is marked with the %immutable directive then any attempts -to set this variable will cause an Octave error. Given a global variable: +If a variable is marked with the %immutable directive then any attempts to set this variable will cause an Octave error. Given a global variable:

    -
    -%module swigexample
    +    
    %module swigexample
     %immutable;
     extern double Foo;
     %mutable;
     

    -SWIG will allow the reading of Foo but when a set attempt is made, an -error function will be called. + SWIG will allow the reading of Foo but when a set attempt is made, an error function will be called.

    -
    octave:1> swigexample
    +    
    octave:1> swigexample
     octave:2> swigexample.Foo=4
     error: attempt to set immutable member variable
     error: assignment failed, or no method for `swig_type = scalar'
    -error: evaluating assignment expression near line 2, column 12
    -
    +error: evaluating assignment expression near line 2, column 12

    -It is possible to add new functions or variables to the module. This also allows -the user to rename/remove existing functions and constants (but not linked -variables, mutable or immutable). Therefore users are recommended to be careful -when doing so. + It is possible to add new functions or variables to the module. This also allows the user to rename/remove existing functions and constants (but not linked variables, mutable or immutable). Therefore users are recommended to be careful when doing so.

    -
    octave:1> swigexample;
    +    
    octave:1> swigexample;
     octave:2> swigexample.PI=3.142;
     octave:3> swigexample.PI
    -ans =  3.1420
    -
    +ans = 3.1420

    32.3.4 Constants and enums

    +

    -Because Octave doesn't really have the concept of constants, C/C++ constants are -not really constant in Octave. They are actually just a copy of the value into -the Octave interpreter. Therefore they can be changed just as any other -value. For example given some constants: + Because Octave doesn't really have the concept of constants, C/C++ constants are not really constant in Octave. They are actually just a copy of the value into the Octave interpreter. Therefore they can be changed just as any other value. For example given some constants:

    -
    -%module swigexample
    +    
    %module swigexample
     %constant int ICONST=42;
     #define    SCONST      "Hello World"
     enum Days{SUNDAY,MONDAY,TUESDAY,WEDNESDAY,THURSDAY,FRIDAY,SATURDAY};
     

    -This is effectively converted into the following Octave code: + This is 'effectively' converted into the following Octave code:

    -
    swigexample.ICONST=42
    +    
    swigexample.ICONST=42
     swigexample.SCONST="Hello World"
     swigexample.SUNDAY=0
    -....
    -
    +....

    32.3.5 Pointers

    +

    -C/C++ pointers are fully supported by SWIG. Furthermore, SWIG has no problem -working with incomplete type information. Given a wrapping of -the file.h interface: + C/C++ pointers are fully supported by SWIG. Furthermore, SWIG has no problem working with incomplete type information. Given a wrapping of the <file.h> interface: + C/C++ pointers are fully supported by SWIG. Furthermore, SWIG has no problem working with incomplete type information. Given a wrapping of the <file.h> interface:

    -
    -%module swigexample
    +
    %module swigexample
     FILE *fopen(const char *filename, const char *mode);
     int fputs(const char *, FILE *);
     int fclose(FILE *);
     

    -When wrapped, you will be able to use the functions in a natural way from -Octave. For example: +When wrapped, you will be able to use the functions in a natural way from Octave. For example:

    @@ -374,7 +329,7 @@ octave:4> swigexample.fclose(f);
     

    -Simply printing the value of a wrapped C++ type will print its typename, e.g.: + Simply printing the value of a wrapped C++ type will print its typename. E.g.,

    octave:1> swigexample;
    @@ -384,67 +339,55 @@ f =
     
     {
       _p_FILE, ptr = 0x9b0cd00
    -}
    -
    +}

    -As the user of the pointer, you are responsible for freeing it, or closing any -resources associated with it (just as you would in a C program). This does not -apply so strictly to classes and structs (see below). + As the user of the pointer, you are responsible for freeing it, or closing any resources associated with it (just as you would in a C program). This does not apply so strictly to classes and structs (see below).

    -
    octave:1> swigexample;
    +    
    octave:1> swigexample;
     octave:2> f=swigexample.fopen("not there","r");
     error: value on right hand side of assignment is undefined
    -error: evaluating assignment expression near line 2, column 2
    -
    +error: evaluating assignment expression near line 2, column 2

    32.3.6 Structures and C++ classes

    +

    -SWIG wraps C structures and C++ classes by using a special Octave type called -a swig_ref. A swig_ref contains a reference to one or more -instances of C/C++ objects, or just the type information for an object. For -each wrapped structure and class, a swig_ref will be exposed that has -the name of the type. When invoked as a function, it creates a new object of its -type and returns a swig_ref that points to that instance. This provides -a very natural interface. For example, + SWIG wraps C structures and C++ classes by using a special Octave type called a swig_ref. A swig_ref contains a reference to one or more instances of C/C++ objects, or just the type information for an object. +For each wrapped structure and class, a swig_ref will be exposed that has the name of the type. When invoked as a function, it creates a new object of its type and returns a swig_ref that points to that instance. This provides a very natural interface. For example,

    -
    -struct Point{
    +    
    struct Point{
       int x,y;
     };
     

    -is used as follows: + is used as follows:

    -
    octave:1> swigexample;
    +    
    +
    octave:1> swigexample;
     octave:2> p=swigexample.Point();
     octave:3> p.x=3;
     octave:4> p.y=5;
     octave:5> p.x, p.y
     ans =  3
    -ans =  5
    +ans =  5 
     
    -

    In C++, invoking the type object in this way calls the object's constructor. -swig_ref objects can also be acquired by having a wrapped function -return a pointer, reference, or value of a non-primitive type. +swig_ref objects can also be acquired by having a wrapped function return a pointer, reference, or value of a non-primitive type.

    -

    -The swig_ref type handles indexing operations such that usage maps -closely to what you would have in C/C++. Structure members are accessed as in -the above example, by calling set and get methods for C++ variables. Methods -also work as expected. For example, code wrapped in the following way +The swig_ref type handles indexing operations such that usage maps closely to what you would have in C/C++. +Structure members are accessed as in the above example, by calling set and get methods for C++ variables. + +Methods also work as expected. For example, code wrapped in the following way

    -
    -class Point{
    +    
    class Point{
     public:
       int x,y;
       Point(int _x,int _y) : x(_x),y(_y) {}
    @@ -456,41 +399,34 @@ public:
       }
     };
     
    -

    can be used from Octave like this

    - -
    octave:1> swigexample;
    +    
    +
    octave:1> swigexample;
     octave:2> p1=swigexample.Point(3,5);
     octave:3> p2=swigexample.Point(1,2);
     octave:4> p1.distance(p2)
     ans =  3.6056
     
    -

    -By using the swig_this() and swig_type() functions, one can -discover the pointers to and types of the underlying C/C++ object. +By using the swig_this() and swig_type() functions, one can discover the pointers to and types of the underlying C/C++ object.

    -
    +    
    +
     octave:5> swig_this(p1)
     ans = 162504808
     octave:6> swig_type(p1)
     ans = Point
     
    -

    -Note that swig_ref is a reference-counted pointer to a C/C++ -object/type, and as such has pass-by-reference semantics. For example if one has -a allocated a single object but has two swig_ref's pointing to it, -modifying the object through either of them will change the single allocated -object. This differs from the usual pass-by-value (copy-on-write) semantics -that Octave maintains for built-in types. For example, in the following snippet, -modifying b does not modify a, +Note that swig_ref is a reference-counted pointer to a C/C++ object/type, and as such has pass-by-reference semantics. For example if one has a allocated a single object but has two swig_ref's pointing to it, modifying the object through either of them will change the single allocated object. +This differs from the usual pass-by-value (copy-on-write) semantics that Octave maintains for built-in types. For example, in the following snippet, modifying b does not modify a,

    -
    +    
    +
     octave:7> a=struct('x',4)
     a =
     {
    @@ -516,12 +452,12 @@ a =
       x =  4
     }
     
    -

    However, when dealing with wrapped objects, one gets the behavior

    -
    +    
    +
     octave:2> a=Point(3,5)
     a =
     
    @@ -546,58 +482,41 @@ ans =  1
     

    -Depending on the ownership setting of a swig_ref, it may call C++ -destructors when its reference count goes to zero. See the section on memory -management below for details. +Depending on the ownership setting of a swig_ref, it may call C++ destructors when its reference count goes to zero. See the section on memory management below for details.

    32.3.7 C++ inheritance

    +

    -Single and multiple inheritance are fully supported. The swig_ref type -carries type information along with any C++ object pointer it holds. This -information contains the full class hierarchy. When an indexing operation (such -as a method invocation) occurs, the tree is walked to find a match in the -current class as well as any of its bases. The lookup is then cached in -the swig_ref. +Single and multiple inheritance are fully supported. The swig_ref type carries type information along with any C++ object pointer it holds. +This information contains the full class hierarchy. When an indexing operation (such as a method invocation) occurs, +the tree is walked to find a match in the current class as well as any of its bases. The lookup is then cached in the swig_ref.

    32.3.8 C++ overloaded functions

    +

    -Overloaded functions are supported, and handled as in other modules. That is, -each overload is wrapped separately (under internal names), and a dispatch -function is also emitted under the external/visible name. The dispatch function -selects which overload to call (if any) based on the passed arguments. -typecheck typemaps are used to analyze each argument, as well as assign -precedence. See the chapter on typemaps for details. +Overloaded functions are supported, and handled as in other modules. That is, +each overload is wrapped separately (under internal names), and a dispatch function is also emitted under the external/visible name. +The dispatch function selects which overload to call (if any) based on the passed arguments. +typecheck typemaps are used to analyze each argument, as well as assign precedence. See the chapter on typemaps for details.

    32.3.9 C++ operators

    +

    C++ operator overloading is supported, in a way similar to other modules. -The swig_ref type supports all unary and binary operators between -itself and all other types that exist in the system at module load time. When an -operator is used (where one of the operands is a swig_ref), the runtime -routes the call to either a member function of the given object, or to a global -function whose named is derived from the types of the operands (either both or -just the lhs or rhs). +The swig_ref type supports all unary and binary operators between itself and all other types that exist in the system at module load time. When an operator is used (where one of the operands is a swig_ref), the runtime routes the call to either a member function of the given object, or to a global function whose named is derived from the types of the operands (either both or just the lhs or rhs).

    -

    -For example, if a and b are SWIG variables in -Octave, a+b becomes a.__add(b). The wrapper is then free to -implement __add to do whatever it wants. A wrapper may define the __add -function manually, %rename some other function to it, -or %rename a C++ operator to it. +For example, if a and b are SWIG variables in Octave, a+b becomes a.__add(b). The wrapper is then free to implement __add to do whatever it wants. A wrapper may define the __add function manually, %rename some other function to it, or %rename a C++ operator to it.

    -

    -By default the C++ operators are renamed to their corresponding Octave -operators. So without doing any work, the following interface +By default the C++ operators are renamed to their corresponding Octave operators. So without doing any work, the following interface

    -
     %inline {
     struct A {
    @@ -609,20 +528,16 @@ struct A {
     };
     }
     
    -

    is usable from Octave like this:

    -
     a=A(2), b=A(3), c=a+b
     assert(c.value==5);
     
    -

    Octave operators are mapped in the following way:

    -
     __brace      a{args}
     __brace_asgn a{args} = rhs
    @@ -657,11 +572,9 @@ __el_ldiv    a .\ b
     __el_and     a & b
     __el_or      a | b
     
    -

    On the C++ side, the default mappings are as follows:

    -
     %rename(__add)       *::operator+;
     %rename(__add)       *::operator+();
    @@ -692,21 +605,18 @@ On the C++ side, the default mappings are as follows:
     

    -Octave can also utilise friend (i.e. non-member) operators with a simple -%rename: see the example in the Examples/octave/operator directory. +Octave can also utilise friend (i.e. non-member) operators with a simple %rename: see the example in the Examples/octave/operator directory.

    32.3.10 Class extension with %extend

    +

    -The %extend directive works the same as in other modules. You can use -it to define special behavior, like for example defining Octave operators not -mapped to C++ operators, or defining certain Octave mechanisms such as how an -object prints. For example, -the octave_value::{is_string,string_value,print} functions are routed -to a special method __str that can be defined inside an extend>. +The %extend directive works the same as in other modules. +

    +

    +You can use it to define special behavior, like for example defining Octave operators not mapped to C++ operators, or defining certain Octave mechanisms such as how an object prints. For example, the octave_value::{is_string,string_value,print} functions are routed to a special method __str that can be defined inside an %extend.

    -
     %extend A {
     string __str() {
    @@ -716,11 +626,9 @@ string __str() {
     }
     }
     
    -

    Then in Octave one gets,

    -
     octave:1> a=A(4);
     octave:2> a
    @@ -730,18 +638,15 @@ octave:3> printf("%s\n",a);
     octave:4> a.__str()
     4
     
    -

    32.3.11 C++ templates

    +

    -C++ class and function templates are fully supported as in other modules, in -that the template> directive may used to create explicit instantiations of -templated types. For example, function templates can be instantiated as -follows: +C++ class and function templates are fully supported as in other modules, in that the %template directive may used to create explicit instantiations of templated types. +For example, function templates can be instantiated as follows:

    -
    -%module swigexample
    +
    %module swigexample
     %inline {
      template<class __scalar>
        __scalar mul(__scalar a,__scalar b) {
    @@ -752,7 +657,6 @@ follows:
     %template(mul) mul<std::complex<double> >
     %template(mul) mul<double>
     
    -

    and then used from Octave

    @@ -770,8 +674,7 @@ ans = 22 + 46i Similarly, class templates can be instantiated as in the following example,

    -
    -%module swigexample
    +
    %module swigexample
     %include <std_complex.i>
     %include <std_string.i>
     %inline {
    @@ -811,30 +714,26 @@ ans =
     (7,4)
     
    +

    32.3.12 C++ Smart Pointers

    +

    C++ smart pointers are fully supported as in other modules.

    32.3.13 Directors (calling Octave from C++ code)

    +

    -There is full support for SWIG directors, which permits Octave code to subclass -C++ classes, and implement their virtual methods. +There is full support for SWIG Directors, which permits Octave code to subclass C++ classes, and implement their virtual methods.

    -

    -Octave has no direct support for object oriented programming, however -the swig_ref type provides some of this support. You can manufacture -a swig_ref using the subclass function (provided by the -SWIG/Octave runtime). +Octave has no direct support for object oriented programming, however the swig_ref type provides some of this support. You can manufacture a swig_ref using the subclass function (provided by the SWIG/Octave runtime).

    -

    For example,

    -
     octave:1> a=subclass();
     octave:2> a.my_var = 4;
    @@ -842,12 +741,9 @@ octave:3> a.my_method = @(self) printf("my_var = ",self.my_var);
     octave:4> a.my_method();
     my_var = 4
     
    -

    -subclass() can also be used to subclass one or more C++ types. Suppose -you have an interface defined by +subclass() can also be used to subclass one or more C++ types. Suppose you have an interface defined by

    -
     %inline {
     class A {
    @@ -861,11 +757,9 @@ void call_your_method(A& a) {
     }
     }
     
    -

    Then from Octave you can say:

    -
     octave:1> B=@() subclass(A(),@my_method);
     octave:2> function my_method(self)
    @@ -874,46 +768,30 @@ octave:4> end
     octave:5> call_your_method(B());
     octave-side routine called
     
    -

    or more concisely,

    -
     octave:1> B=@() subclass(A(),'my_method',@(self) printf("octave-side routine called\n"));
     octave:2> call_your_method(B());
     octave-side routine called
     
    -

    -Note that you have to enable directors via the %feature directive (see -other modules for this). +Note that you have to enable directors via the %feature directive (see other modules for this).

    -

    -subclass() will accept any number of C++ bases or -other subclass()'ed objects, (string,octave_value) pairs, -and function_handles. In the first case, these are taken as base -classes; in the second case, as named members (either variables or functions, -depending on whether the given value is a function handle); in the third case, -as member functions whose name is taken from the given function handle, e.g.: +subclass() will accept any number of C++ bases or other subclass()'ed objects, (string,octave_value) pairs, and function_handles. In the first case, these are taken as base classes; in the second case, as named members (either variables or functions, depending on whether the given value is a function handle); in the third case, as member functions whose name is taken from the given function handle. E.g.,

    -
     octave:1> B=@(some_var=2) subclass(A(),'some_var',some_var,@some_func,'another_func',
     @(self) do_stuff())
     
    -

    -You can also assign non-C++ member variables and functions after construction -time. There is no support for non-C++ static members. +You can also assign non-C++ member variables and functions after construct time. There is no support for non-C++ static members.

    -

    -There is limited support for explicitly referencing C++ bases. So, in the -example above, we could have +There is limited support for explicitly referencing C++ bases. So, in the example above, we could have

    -
     octave:1> B=@() subclass(A(),@my_method);
     octave:2> function my_method(self)
    @@ -927,29 +805,19 @@ octave-side routine called
     
     

    32.3.14 Threads

    +

    -The use of threads in wrapped director code is not supported; i.e., an -Octave-side implementation of a C++ class must be called from the Octave -interpreter's thread. Anything fancier (apartment/queue model, whatever) is left -to the user. Without anything fancier, this amounts to the limitation that -Octave must drive the module... like, for example, an optimization package that -calls Octave to evaluate an objective function. +The use of threads in wrapped Director code is not supported; i.e., an Octave-side implementation of a C++ class must be called from the Octave interpreter's thread. Anything fancier (apartment/queue model, whatever) is left to the user. Without anything fancier, this amounts to the limitation that Octave must drive the module... like, for example, an optimization package that calls Octave to evaluate an objective function.

    32.3.15 Memory management

    +

    -As noted above, swig_ref represents a reference counted pointer to a -C/C++-side object. It also contains a flag indicating whether Octave or the -C/C++ code owns the object. If Octave owns it, any destructors will be called -when the reference count reaches zero. If the C/C++ side owns the object, then -destructors will not be called when the reference count goes to zero. +As noted above, swig_ref represents a reference counted pointer to a C/C++-side object. It also contains a flag indicating whether Octave or the C/C++ code owns the object. If Octave owns it, any destructors will be called when the reference count reaches zero. If the C/C++ side owns the object, then destructors will not be called when the reference count goes to zero.

    -

    For example, -

    -
     %inline {
     class A {
    @@ -959,11 +827,9 @@ public:
     };
     }
     
    -

    -would produce this behavior in Octave: +Would produce this behavior in Octave:

    -
     octave:1> a=A();
     A constructing
    @@ -972,49 +838,36 @@ octave:3> clear a;
     octave:4> b=4;
     A destructing
     
    -

    -The %newobject directive may be used to control this behavior for -pointers returned from functions. -

    - +The %newobject directive may be used to control this behavior for pointers returned from functions.

    -In the case where one wishes for the C++ side to own an object that was created -in Octave (especially a Director object), one can use the __disown() method to -invert this logic. Then letting the Octave reference count go to zero will not -destroy the object, but destroying the object will invalidate the Octave-side -object if it still exists (and call destructors of other C++ bases in the case -of multiple inheritance/subclass()'ing). +In the case where one wishes for the C++ side to own an object that was created in Octave (especially a Director object), one can use the __disown() method to invert this logic. Then letting the Octave reference count go to zero will not destroy the object, but destroying the object will invalidate the Octave-side object if it still exists (and call destructors of other C++ bases in the case of multiple inheritance/subclass()'ing).

    32.3.16 STL support

    +

    Various STL library files are provided for wrapping STL containers.

    32.3.17 Matrix typemaps

    +

    -Octave provides a rich set of classes for dealing with matrices. Currently there -are no built-in typemaps to deal with those. However, these are relatively -straight forward for users to add themselves (see the docs on typemaps). Without -much work (a single typemap decl -- say, 5 lines of code in the interface file), -it would be possible to have a function +Octave provides a rich set of classes for dealing with matrices. Currently there are no built-in typemaps to deal with those. However, these are relatively straight forward for users to add themselves (see the docs on typemaps). Without much work (a single typemap decl-- say, 5 lines of code in the interface file), it would be possible to have a function

    -
     double my_det(const double* mat,int m,int n);
     
    -

    that is accessed from Octave as,

    -
     octave:1> my_det(rand(4));
     ans = -0.18388
     
    - +
    + -- cgit v1.2.1 From 23373e9ffd849115a8be04254eb330b156883810 Mon Sep 17 00:00:00 2001 From: William S Fulton Date: Thu, 9 Oct 2014 19:34:02 +0100 Subject: Revert "Octave: cleanup/restructure library files" This reverts commit bf12d76d037dddb68c294cd77c3ad1f6b6d2e985. Reverting a series of Octave commits for re-applying again without incorrect whitespace changes. --- Lib/octave/attribute.i | 4 - Lib/octave/boost_shared_ptr.i | 183 +++--- Lib/octave/carrays.i | 6 +- Lib/octave/cdata.i | 4 - Lib/octave/cmalloc.i | 4 - Lib/octave/director.swg | 132 ++++ Lib/octave/exception.i | 7 +- Lib/octave/factory.i | 4 - Lib/octave/implicit.i | 5 +- Lib/octave/octave.swg | 15 +- Lib/octave/octcomplex.swg | 129 ++-- Lib/octave/octcontainer.swg | 985 +++++++++++++++-------------- Lib/octave/octfragments.swg | 19 - Lib/octave/octiterators.swg | 582 ++++++++--------- Lib/octave/octopers.swg | 17 +- Lib/octave/octprimtypes.swg | 365 +++++------ Lib/octave/octrun.swg | 1389 +++++++++++++++++++++++++++++++++++++++++ Lib/octave/octrunclass.swg | 1203 ----------------------------------- Lib/octave/octrundecl.swg | 479 -------------- Lib/octave/octrunfunc.swg | 187 ------ Lib/octave/octruninit.swg | 422 ------------- Lib/octave/octruntime.swg | 333 +++++++++- Lib/octave/octstdcommon.swg | 408 ++++++------ Lib/octave/octtypemaps.swg | 55 +- Lib/octave/octuserdir.swg | 119 ++-- Lib/octave/std_alloc.i | 4 - Lib/octave/std_basic_string.i | 96 ++- Lib/octave/std_carray.i | 3 - Lib/octave/std_char_traits.i | 4 - Lib/octave/std_common.i | 120 ++-- Lib/octave/std_complex.i | 19 +- Lib/octave/std_container.i | 4 - Lib/octave/std_deque.i | 19 +- Lib/octave/std_except.i | 4 - Lib/octave/std_list.i | 20 +- Lib/octave/std_map.i | 149 +++-- Lib/octave/std_pair.i | 214 +++---- Lib/octave/std_string.i | 4 - Lib/octave/std_vector.i | 13 +- Lib/octave/stl.i | 5 +- Lib/octave/typemaps.i | 4 - Source/Modules/octave.cxx | 50 +- 42 files changed, 3601 insertions(+), 4187 deletions(-) create mode 100644 Lib/octave/director.swg create mode 100644 Lib/octave/octrun.swg delete mode 100644 Lib/octave/octrunclass.swg delete mode 100644 Lib/octave/octrundecl.swg delete mode 100644 Lib/octave/octrunfunc.swg delete mode 100644 Lib/octave/octruninit.swg diff --git a/Lib/octave/attribute.i b/Lib/octave/attribute.i index 104e4f436..779716cd2 100644 --- a/Lib/octave/attribute.i +++ b/Lib/octave/attribute.i @@ -1,5 +1 @@ -// -// attribute.i - Attribute support -// - %include diff --git a/Lib/octave/boost_shared_ptr.i b/Lib/octave/boost_shared_ptr.i index 44868ccac..93b1a896f 100644 --- a/Lib/octave/boost_shared_ptr.i +++ b/Lib/octave/boost_shared_ptr.i @@ -1,7 +1,3 @@ -// -// boost_shared_ptr.i - Boost shared pointer support -// - %include // Language specific macro implementing all the customisations for handling the smart pointer @@ -14,32 +10,30 @@ // destructor wrapper customisation %feature("unref") TYPE //"if (debug_shared) { cout << \"deleting use_count: \" << (*smartarg1).use_count() << \" [\" << (boost::get_deleter(*smartarg1) ? std::string(\"CANNOT BE DETERMINED SAFELY\") : ( (*smartarg1).get() ? (*smartarg1)->getValue() : std::string(\"NULL PTR\") )) << \"]\" << endl << flush; }\n" - "(void)arg1; delete smartarg1;" + "(void)arg1; delete smartarg1;" -///// Typemap customisations ///// +// Typemap customisations... -// Plain value -%typemap(in) CONST TYPE(void* argp, int res = 0) { +// plain value +%typemap(in) CONST TYPE (void *argp, int res = 0) { int newmem = 0; res = SWIG_ConvertPtrAndOwn($input, &argp, $descriptor(SWIG_SHARED_PTR_QNAMESPACE::shared_ptr< TYPE > *), %convertptr_flags, &newmem); if (!SWIG_IsOK(res)) { - %argument_fail(res, "$type", $symname, $argnum); + %argument_fail(res, "$type", $symname, $argnum); } if (!argp) { %argument_nullref("$type", $symname, $argnum); } else { $1 = *(%reinterpret_cast(argp, SWIG_SHARED_PTR_QNAMESPACE::shared_ptr< CONST TYPE > *)->get()); - if (newmem & SWIG_CAST_NEW_MEMORY) { - delete %reinterpret_cast(argp, SWIG_SHARED_PTR_QNAMESPACE::shared_ptr< CONST TYPE > *); - } + if (newmem & SWIG_CAST_NEW_MEMORY) delete %reinterpret_cast(argp, SWIG_SHARED_PTR_QNAMESPACE::shared_ptr< CONST TYPE > *); } } %typemap(out) CONST TYPE { - %set_output(SWIG_NewPointerObj(new SWIG_SHARED_PTR_QNAMESPACE::shared_ptr< CONST TYPE > (new $1_ltype(($1_ltype &) $1)), $descriptor(SWIG_SHARED_PTR_QNAMESPACE::shared_ptr< TYPE > *), SWIG_POINTER_OWN)); + %set_output(SWIG_NewPointerObj(new SWIG_SHARED_PTR_QNAMESPACE::shared_ptr< CONST TYPE >(new $1_ltype(($1_ltype &)$1)), $descriptor(SWIG_SHARED_PTR_QNAMESPACE::shared_ptr< TYPE > *), SWIG_POINTER_OWN)); } %typemap(varin) CONST TYPE { - void* argp = 0; + void *argp = 0; int newmem = 0; int res = SWIG_ConvertPtrAndOwn($input, &argp, $descriptor(SWIG_SHARED_PTR_QNAMESPACE::shared_ptr< TYPE > *), %convertptr_flags, &newmem); if (!SWIG_IsOK(res)) { @@ -49,22 +43,20 @@ %argument_nullref("$type", $symname, $argnum); } else { $1 = *(%reinterpret_cast(argp, SWIG_SHARED_PTR_QNAMESPACE::shared_ptr< CONST TYPE > *)->get()); - if (newmem & SWIG_CAST_NEW_MEMORY) { - delete %reinterpret_cast(argp, SWIG_SHARED_PTR_QNAMESPACE::shared_ptr< CONST TYPE > *); - } + if (newmem & SWIG_CAST_NEW_MEMORY) delete %reinterpret_cast(argp, SWIG_SHARED_PTR_QNAMESPACE::shared_ptr< CONST TYPE > *); } } %typemap(varout) CONST TYPE { - %set_varoutput(SWIG_NewPointerObj(new SWIG_SHARED_PTR_QNAMESPACE::shared_ptr< CONST TYPE > (new $1_ltype(($1_ltype &) $1)), $descriptor(SWIG_SHARED_PTR_QNAMESPACE::shared_ptr< TYPE > *), SWIG_POINTER_OWN)); + %set_varoutput(SWIG_NewPointerObj(new SWIG_SHARED_PTR_QNAMESPACE::shared_ptr< CONST TYPE >(new $1_ltype(($1_ltype &)$1)), $descriptor(SWIG_SHARED_PTR_QNAMESPACE::shared_ptr< TYPE > *), SWIG_POINTER_OWN)); } -// Plain pointer +// plain pointer // Note: $disown not implemented as it will lead to a memory leak of the shared_ptr instance -%typemap(in) CONST TYPE* (void* argp = 0, int res = 0, SWIG_SHARED_PTR_QNAMESPACE::shared_ptr< CONST TYPE > tempshared, SWIG_SHARED_PTR_QNAMESPACE::shared_ptr< CONST TYPE > *smartarg = 0) { +%typemap(in) CONST TYPE * (void *argp = 0, int res = 0, SWIG_SHARED_PTR_QNAMESPACE::shared_ptr< CONST TYPE > tempshared, SWIG_SHARED_PTR_QNAMESPACE::shared_ptr< CONST TYPE > *smartarg = 0) { int newmem = 0; res = SWIG_ConvertPtrAndOwn($input, &argp, $descriptor(SWIG_SHARED_PTR_QNAMESPACE::shared_ptr< TYPE > *), %convertptr_flags, &newmem); if (!SWIG_IsOK(res)) { - %argument_fail(res, "$type", $symname, $argnum); + %argument_fail(res, "$type", $symname, $argnum); } if (newmem & SWIG_CAST_NEW_MEMORY) { tempshared = *%reinterpret_cast(argp, SWIG_SHARED_PTR_QNAMESPACE::shared_ptr< CONST TYPE > *); @@ -75,13 +67,13 @@ $1 = %const_cast((smartarg ? smartarg->get() : 0), $1_ltype); } } -%typemap(out, fragment = "SWIG_null_deleter") CONST TYPE* { - SWIG_SHARED_PTR_QNAMESPACE::shared_ptr< CONST TYPE > *smartresult = $1 ? new SWIG_SHARED_PTR_QNAMESPACE::shared_ptr< CONST TYPE > ($1 SWIG_NO_NULL_DELETER_$owner) : 0; +%typemap(out, fragment="SWIG_null_deleter") CONST TYPE * { + SWIG_SHARED_PTR_QNAMESPACE::shared_ptr< CONST TYPE > *smartresult = $1 ? new SWIG_SHARED_PTR_QNAMESPACE::shared_ptr< CONST TYPE >($1 SWIG_NO_NULL_DELETER_$owner) : 0; %set_output(SWIG_NewPointerObj(%as_voidptr(smartresult), $descriptor(SWIG_SHARED_PTR_QNAMESPACE::shared_ptr< TYPE > *), $owner | SWIG_POINTER_OWN)); } -%typemap(varin) CONST TYPE* { - void* argp = 0; +%typemap(varin) CONST TYPE * { + void *argp = 0; int newmem = 0; int res = SWIG_ConvertPtrAndOwn($input, &argp, $descriptor(SWIG_SHARED_PTR_QNAMESPACE::shared_ptr< TYPE > *), %convertptr_flags, &newmem); if (!SWIG_IsOK(res)) { @@ -98,21 +90,19 @@ $1 = %const_cast((smartarg ? smartarg->get() : 0), $1_ltype); } } -%typemap(varout, fragment = "SWIG_null_deleter") CONST TYPE* { - SWIG_SHARED_PTR_QNAMESPACE::shared_ptr< CONST TYPE > *smartresult = $1 ? new SWIG_SHARED_PTR_QNAMESPACE::shared_ptr< CONST TYPE > ($1 SWIG_NO_NULL_DELETER_0) : 0; +%typemap(varout, fragment="SWIG_null_deleter") CONST TYPE * { + SWIG_SHARED_PTR_QNAMESPACE::shared_ptr< CONST TYPE > *smartresult = $1 ? new SWIG_SHARED_PTR_QNAMESPACE::shared_ptr< CONST TYPE >($1 SWIG_NO_NULL_DELETER_0) : 0; %set_varoutput(SWIG_NewPointerObj(%as_voidptr(smartresult), $descriptor(SWIG_SHARED_PTR_QNAMESPACE::shared_ptr< TYPE > *), SWIG_POINTER_OWN)); } -// Plain reference -%typemap(in) CONST TYPE& (void* argp = 0, int res = 0, SWIG_SHARED_PTR_QNAMESPACE::shared_ptr< CONST TYPE > tempshared) { +// plain reference +%typemap(in) CONST TYPE & (void *argp = 0, int res = 0, SWIG_SHARED_PTR_QNAMESPACE::shared_ptr< CONST TYPE > tempshared) { int newmem = 0; res = SWIG_ConvertPtrAndOwn($input, &argp, $descriptor(SWIG_SHARED_PTR_QNAMESPACE::shared_ptr< TYPE > *), %convertptr_flags, &newmem); if (!SWIG_IsOK(res)) { - %argument_fail(res, "$type", $symname, $argnum); - } - if (!argp) { - %argument_nullref("$type", $symname, $argnum); + %argument_fail(res, "$type", $symname, $argnum); } + if (!argp) { %argument_nullref("$type", $symname, $argnum); } if (newmem & SWIG_CAST_NEW_MEMORY) { tempshared = *%reinterpret_cast(argp, SWIG_SHARED_PTR_QNAMESPACE::shared_ptr< CONST TYPE > *); delete %reinterpret_cast(argp, SWIG_SHARED_PTR_QNAMESPACE::shared_ptr< CONST TYPE > *); @@ -121,22 +111,20 @@ $1 = %const_cast(%reinterpret_cast(argp, SWIG_SHARED_PTR_QNAMESPACE::shared_ptr< CONST TYPE > *)->get(), $1_ltype); } } -%typemap(out, fragment = "SWIG_null_deleter") CONST TYPE& { - SWIG_SHARED_PTR_QNAMESPACE::shared_ptr< CONST TYPE > *smartresult = new SWIG_SHARED_PTR_QNAMESPACE::shared_ptr< CONST TYPE > ($1 SWIG_NO_NULL_DELETER_$owner); +%typemap(out, fragment="SWIG_null_deleter") CONST TYPE & { + SWIG_SHARED_PTR_QNAMESPACE::shared_ptr< CONST TYPE > *smartresult = new SWIG_SHARED_PTR_QNAMESPACE::shared_ptr< CONST TYPE >($1 SWIG_NO_NULL_DELETER_$owner); %set_output(SWIG_NewPointerObj(%as_voidptr(smartresult), $descriptor(SWIG_SHARED_PTR_QNAMESPACE::shared_ptr< TYPE > *), SWIG_POINTER_OWN)); } -%typemap(varin) CONST TYPE& { - void* argp = 0; +%typemap(varin) CONST TYPE & { + void *argp = 0; int newmem = 0; int res = SWIG_ConvertPtrAndOwn($input, &argp, $descriptor(SWIG_SHARED_PTR_QNAMESPACE::shared_ptr< TYPE > *), %convertptr_flags, &newmem); if (!SWIG_IsOK(res)) { %variable_fail(res, "$type", "$name"); } SWIG_SHARED_PTR_QNAMESPACE::shared_ptr< CONST TYPE > tempshared; - if (!argp) { - %argument_nullref("$type", $symname, $argnum); - } + if (!argp) { %argument_nullref("$type", $symname, $argnum); } if (newmem & SWIG_CAST_NEW_MEMORY) { tempshared = *%reinterpret_cast(argp, SWIG_SHARED_PTR_QNAMESPACE::shared_ptr< CONST TYPE > *); delete %reinterpret_cast(argp, SWIG_SHARED_PTR_QNAMESPACE::shared_ptr< CONST TYPE > *); @@ -145,18 +133,18 @@ $1 = *%const_cast(%reinterpret_cast(argp, SWIG_SHARED_PTR_QNAMESPACE::shared_ptr< CONST TYPE > *)->get(), $1_ltype); } } -%typemap(varout, fragment = "SWIG_null_deleter") CONST TYPE& { - SWIG_SHARED_PTR_QNAMESPACE::shared_ptr< CONST TYPE > *smartresult = new SWIG_SHARED_PTR_QNAMESPACE::shared_ptr< CONST TYPE > (&$1 SWIG_NO_NULL_DELETER_0); +%typemap(varout, fragment="SWIG_null_deleter") CONST TYPE & { + SWIG_SHARED_PTR_QNAMESPACE::shared_ptr< CONST TYPE > *smartresult = new SWIG_SHARED_PTR_QNAMESPACE::shared_ptr< CONST TYPE >(&$1 SWIG_NO_NULL_DELETER_0); %set_varoutput(SWIG_NewPointerObj(%as_voidptr(smartresult), $descriptor(SWIG_SHARED_PTR_QNAMESPACE::shared_ptr< TYPE > *), SWIG_POINTER_OWN)); } -// Plain pointer by reference +// plain pointer by reference // Note: $disown not implemented as it will lead to a memory leak of the shared_ptr instance -%typemap(in) TYPE* CONST& (void* argp = 0, int res = 0, $*1_ltype temp = 0, SWIG_SHARED_PTR_QNAMESPACE::shared_ptr< CONST TYPE > tempshared) { +%typemap(in) TYPE *CONST& (void *argp = 0, int res = 0, $*1_ltype temp = 0, SWIG_SHARED_PTR_QNAMESPACE::shared_ptr< CONST TYPE > tempshared) { int newmem = 0; res = SWIG_ConvertPtrAndOwn($input, &argp, $descriptor(SWIG_SHARED_PTR_QNAMESPACE::shared_ptr< TYPE > *), %convertptr_flags, &newmem); if (!SWIG_IsOK(res)) { - %argument_fail(res, "$type", $symname, $argnum); + %argument_fail(res, "$type", $symname, $argnum); } if (newmem & SWIG_CAST_NEW_MEMORY) { tempshared = *%reinterpret_cast(argp, SWIG_SHARED_PTR_QNAMESPACE::shared_ptr< CONST TYPE > *); @@ -167,65 +155,57 @@ } $1 = &temp; } -%typemap(out, fragment = "SWIG_null_deleter") TYPE * CONST& { - SWIG_SHARED_PTR_QNAMESPACE::shared_ptr< CONST TYPE > *smartresult = new SWIG_SHARED_PTR_QNAMESPACE::shared_ptr< CONST TYPE > (*$1 SWIG_NO_NULL_DELETER_$owner); +%typemap(out, fragment="SWIG_null_deleter") TYPE *CONST& { + SWIG_SHARED_PTR_QNAMESPACE::shared_ptr< CONST TYPE > *smartresult = new SWIG_SHARED_PTR_QNAMESPACE::shared_ptr< CONST TYPE >(*$1 SWIG_NO_NULL_DELETER_$owner); %set_output(SWIG_NewPointerObj(%as_voidptr(smartresult), $descriptor(SWIG_SHARED_PTR_QNAMESPACE::shared_ptr< TYPE > *), SWIG_POINTER_OWN)); } -%typemap(varin) TYPE* CONST& %{ +%typemap(varin) TYPE *CONST& %{ #error "varin typemap not implemented" %} -%typemap(varout) TYPE* CONST& %{ +%typemap(varout) TYPE *CONST& %{ #error "varout typemap not implemented" %} -// Shared_ptr by value -%typemap(in) SWIG_SHARED_PTR_QNAMESPACE::shared_ptr< CONST TYPE > (void* argp, int res = 0) { +// shared_ptr by value +%typemap(in) SWIG_SHARED_PTR_QNAMESPACE::shared_ptr< CONST TYPE > (void *argp, int res = 0) { int newmem = 0; res = SWIG_ConvertPtrAndOwn($input, &argp, $descriptor(SWIG_SHARED_PTR_QNAMESPACE::shared_ptr< TYPE > *), %convertptr_flags, &newmem); if (!SWIG_IsOK(res)) { - %argument_fail(res, "$type", $symname, $argnum); - } - if (argp) { - $1 = *(%reinterpret_cast(argp, $<ype)); - } - if (newmem & SWIG_CAST_NEW_MEMORY) { - delete %reinterpret_cast(argp, $<ype); + %argument_fail(res, "$type", $symname, $argnum); } + if (argp) $1 = *(%reinterpret_cast(argp, $<ype)); + if (newmem & SWIG_CAST_NEW_MEMORY) delete %reinterpret_cast(argp, $<ype); } %typemap(out) SWIG_SHARED_PTR_QNAMESPACE::shared_ptr< CONST TYPE > { - SWIG_SHARED_PTR_QNAMESPACE::shared_ptr< CONST TYPE > *smartresult = $1 ? new SWIG_SHARED_PTR_QNAMESPACE::shared_ptr< CONST TYPE > ($1) : 0; + SWIG_SHARED_PTR_QNAMESPACE::shared_ptr< CONST TYPE > *smartresult = $1 ? new SWIG_SHARED_PTR_QNAMESPACE::shared_ptr< CONST TYPE >($1) : 0; %set_output(SWIG_NewPointerObj(%as_voidptr(smartresult), $descriptor(SWIG_SHARED_PTR_QNAMESPACE::shared_ptr< TYPE > *), SWIG_POINTER_OWN)); } %typemap(varin) SWIG_SHARED_PTR_QNAMESPACE::shared_ptr< CONST TYPE > { int newmem = 0; - void* argp = 0; + void *argp = 0; int res = SWIG_ConvertPtrAndOwn($input, &argp, $descriptor(SWIG_SHARED_PTR_QNAMESPACE::shared_ptr< TYPE > *), %convertptr_flags, &newmem); if (!SWIG_IsOK(res)) { %variable_fail(res, "$type", "$name"); } $1 = argp ? *(%reinterpret_cast(argp, $<ype)) : SWIG_SHARED_PTR_QNAMESPACE::shared_ptr< TYPE >(); - if (newmem & SWIG_CAST_NEW_MEMORY) { - delete %reinterpret_cast(argp, $<ype); - } + if (newmem & SWIG_CAST_NEW_MEMORY) delete %reinterpret_cast(argp, $<ype); } %typemap(varout) SWIG_SHARED_PTR_QNAMESPACE::shared_ptr< CONST TYPE > { - SWIG_SHARED_PTR_QNAMESPACE::shared_ptr< CONST TYPE > *smartresult = $1 ? new SWIG_SHARED_PTR_QNAMESPACE::shared_ptr< CONST TYPE > ($1) : 0; + SWIG_SHARED_PTR_QNAMESPACE::shared_ptr< CONST TYPE > *smartresult = $1 ? new SWIG_SHARED_PTR_QNAMESPACE::shared_ptr< CONST TYPE >($1) : 0; %set_varoutput(SWIG_NewPointerObj(%as_voidptr(smartresult), $descriptor(SWIG_SHARED_PTR_QNAMESPACE::shared_ptr< TYPE > *), SWIG_POINTER_OWN)); } -// Shared_ptr by reference -%typemap(in) SWIG_SHARED_PTR_QNAMESPACE::shared_ptr< CONST TYPE > & (void* argp, int res = 0, $*1_ltype tempshared) { +// shared_ptr by reference +%typemap(in) SWIG_SHARED_PTR_QNAMESPACE::shared_ptr< CONST TYPE > & (void *argp, int res = 0, $*1_ltype tempshared) { int newmem = 0; res = SWIG_ConvertPtrAndOwn($input, &argp, $descriptor(SWIG_SHARED_PTR_QNAMESPACE::shared_ptr< TYPE > *), %convertptr_flags, &newmem); if (!SWIG_IsOK(res)) { - %argument_fail(res, "$type", $symname, $argnum); + %argument_fail(res, "$type", $symname, $argnum); } if (newmem & SWIG_CAST_NEW_MEMORY) { - if (argp) { - tempshared = *%reinterpret_cast(argp, $ltype); - } + if (argp) tempshared = *%reinterpret_cast(argp, $ltype); delete %reinterpret_cast(argp, $ltype); $1 = &tempshared; } else { @@ -233,7 +213,7 @@ } } %typemap(out) SWIG_SHARED_PTR_QNAMESPACE::shared_ptr< CONST TYPE > & { - SWIG_SHARED_PTR_QNAMESPACE::shared_ptr< CONST TYPE > *smartresult = *$1 ? new SWIG_SHARED_PTR_QNAMESPACE::shared_ptr< CONST TYPE > (*$1) : 0; + SWIG_SHARED_PTR_QNAMESPACE::shared_ptr< CONST TYPE > *smartresult = *$1 ? new SWIG_SHARED_PTR_QNAMESPACE::shared_ptr< CONST TYPE >(*$1) : 0; %set_output(SWIG_NewPointerObj(%as_voidptr(smartresult), $descriptor(SWIG_SHARED_PTR_QNAMESPACE::shared_ptr< TYPE > *), SWIG_POINTER_OWN)); } @@ -244,17 +224,15 @@ #error "varout typemap not implemented" %} -// Shared_ptr by pointer -%typemap(in) SWIG_SHARED_PTR_QNAMESPACE::shared_ptr< CONST TYPE > * (void* argp, int res = 0, $*1_ltype tempshared) { +// shared_ptr by pointer +%typemap(in) SWIG_SHARED_PTR_QNAMESPACE::shared_ptr< CONST TYPE > * (void *argp, int res = 0, $*1_ltype tempshared) { int newmem = 0; res = SWIG_ConvertPtrAndOwn($input, &argp, $descriptor(SWIG_SHARED_PTR_QNAMESPACE::shared_ptr< TYPE > *), %convertptr_flags, &newmem); if (!SWIG_IsOK(res)) { - %argument_fail(res, "$type", $symname, $argnum); + %argument_fail(res, "$type", $symname, $argnum); } if (newmem & SWIG_CAST_NEW_MEMORY) { - if (argp) { - tempshared = *%reinterpret_cast(argp, $ltype); - } + if (argp) tempshared = *%reinterpret_cast(argp, $ltype); delete %reinterpret_cast(argp, $ltype); $1 = &tempshared; } else { @@ -262,11 +240,9 @@ } } %typemap(out) SWIG_SHARED_PTR_QNAMESPACE::shared_ptr< CONST TYPE > * { - SWIG_SHARED_PTR_QNAMESPACE::shared_ptr< CONST TYPE > *smartresult = $1 && *$1 ? new SWIG_SHARED_PTR_QNAMESPACE::shared_ptr< CONST TYPE > (*$1) : 0; + SWIG_SHARED_PTR_QNAMESPACE::shared_ptr< CONST TYPE > *smartresult = $1 && *$1 ? new SWIG_SHARED_PTR_QNAMESPACE::shared_ptr< CONST TYPE >(*$1) : 0; %set_output(SWIG_NewPointerObj(%as_voidptr(smartresult), $descriptor(SWIG_SHARED_PTR_QNAMESPACE::shared_ptr< TYPE > *), SWIG_POINTER_OWN)); - if ($owner) { - delete $1; - } + if ($owner) delete $1; } %typemap(varin) SWIG_SHARED_PTR_QNAMESPACE::shared_ptr< CONST TYPE > * %{ @@ -276,24 +252,20 @@ #error "varout typemap not implemented" %} -// Shared_ptr by pointer reference -%typemap(in) SWIG_SHARED_PTR_QNAMESPACE::shared_ptr< CONST TYPE > *& (void* argp, int res = 0, SWIG_SHARED_PTR_QNAMESPACE::shared_ptr< CONST TYPE > tempshared, $*1_ltype temp = 0) { +// shared_ptr by pointer reference +%typemap(in) SWIG_SHARED_PTR_QNAMESPACE::shared_ptr< CONST TYPE > *& (void *argp, int res = 0, SWIG_SHARED_PTR_QNAMESPACE::shared_ptr< CONST TYPE > tempshared, $*1_ltype temp = 0) { int newmem = 0; res = SWIG_ConvertPtrAndOwn($input, &argp, $descriptor(SWIG_SHARED_PTR_QNAMESPACE::shared_ptr< TYPE > *), %convertptr_flags, &newmem); if (!SWIG_IsOK(res)) { - %argument_fail(res, "$type", $symname, $argnum); - } - if (argp) { - tempshared = *%reinterpret_cast(argp, $*ltype); - } - if (newmem & SWIG_CAST_NEW_MEMORY) { - delete %reinterpret_cast(argp, $*ltype); + %argument_fail(res, "$type", $symname, $argnum); } + if (argp) tempshared = *%reinterpret_cast(argp, $*ltype); + if (newmem & SWIG_CAST_NEW_MEMORY) delete %reinterpret_cast(argp, $*ltype); temp = &tempshared; $1 = &temp; } %typemap(out) SWIG_SHARED_PTR_QNAMESPACE::shared_ptr< CONST TYPE > *& { - SWIG_SHARED_PTR_QNAMESPACE::shared_ptr< CONST TYPE > *smartresult = *$1 && **$1 ? new SWIG_SHARED_PTR_QNAMESPACE::shared_ptr< CONST TYPE > (**$1) : 0; + SWIG_SHARED_PTR_QNAMESPACE::shared_ptr< CONST TYPE > *smartresult = *$1 && **$1 ? new SWIG_SHARED_PTR_QNAMESPACE::shared_ptr< CONST TYPE >(**$1) : 0; %set_output(SWIG_NewPointerObj(%as_voidptr(smartresult), $descriptor(SWIG_SHARED_PTR_QNAMESPACE::shared_ptr< TYPE > *), SWIG_POINTER_OWN)); } @@ -305,30 +277,31 @@ %} // Typecheck typemaps -// Note: SWIG_ConvertPtr with void ** parameter set to 0 instead of using SWIG_ConvertPtrAndOwn, so that the casting +// Note: SWIG_ConvertPtr with void ** parameter set to 0 instead of using SWIG_ConvertPtrAndOwn, so that the casting // function is not called thereby avoiding a possible smart pointer copy constructor call when casting up the inheritance chain. -%typemap(typecheck, precedence = SWIG_TYPECHECK_POINTER, noblock = 1) - TYPE CONST, - TYPE CONST&, - TYPE CONST*, - TYPE * CONST&, - SWIG_SHARED_PTR_QNAMESPACE::shared_ptr< CONST TYPE >, - SWIG_SHARED_PTR_QNAMESPACE::shared_ptr< CONST TYPE > &, - SWIG_SHARED_PTR_QNAMESPACE::shared_ptr< CONST TYPE > *, - SWIG_SHARED_PTR_QNAMESPACE::shared_ptr< CONST TYPE > *& -{ +%typemap(typecheck,precedence=SWIG_TYPECHECK_POINTER,noblock=1) + TYPE CONST, + TYPE CONST &, + TYPE CONST *, + TYPE *CONST&, + SWIG_SHARED_PTR_QNAMESPACE::shared_ptr< CONST TYPE >, + SWIG_SHARED_PTR_QNAMESPACE::shared_ptr< CONST TYPE > &, + SWIG_SHARED_PTR_QNAMESPACE::shared_ptr< CONST TYPE > *, + SWIG_SHARED_PTR_QNAMESPACE::shared_ptr< CONST TYPE > *& { int res = SWIG_ConvertPtr($input, 0, $descriptor(SWIG_SHARED_PTR_QNAMESPACE::shared_ptr< TYPE > *), 0); $1 = SWIG_CheckState(res); } -// Various missing typemaps - If ever used (unlikely) ensure compilation error rather than runtime bug -%typemap(in) CONST TYPE[], CONST TYPE[ANY], CONST TYPE(CLASS::*) %{ + +// various missing typemaps - If ever used (unlikely) ensure compilation error rather than runtime bug +%typemap(in) CONST TYPE[], CONST TYPE[ANY], CONST TYPE (CLASS::*) %{ #error "typemaps for $1_type not available" %} -%typemap(out) CONST TYPE[], CONST TYPE[ANY], CONST TYPE(CLASS::*) %{ +%typemap(out) CONST TYPE[], CONST TYPE[ANY], CONST TYPE (CLASS::*) %{ #error "typemaps for $1_type not available" %} %template() SWIG_SHARED_PTR_QNAMESPACE::shared_ptr< CONST TYPE >; %enddef + diff --git a/Lib/octave/carrays.i b/Lib/octave/carrays.i index 6607b7664..014de37ff 100644 --- a/Lib/octave/carrays.i +++ b/Lib/octave/carrays.i @@ -1,9 +1,5 @@ -// -// carrays.i - Manipulate simple pointers as arrays -// - %define %array_class(TYPE,NAME) -%array_class_wrap(TYPE,NAME,__paren__,__paren_asgn__) + %array_class_wrap(TYPE,NAME,__paren__,__paren_asgn__) %enddef %include diff --git a/Lib/octave/cdata.i b/Lib/octave/cdata.i index d626b5db0..367965990 100644 --- a/Lib/octave/cdata.i +++ b/Lib/octave/cdata.i @@ -1,5 +1 @@ -// -// cdata.i - Manipulate raw C data as strings -// - %include diff --git a/Lib/octave/cmalloc.i b/Lib/octave/cmalloc.i index e8b5929b7..248f06b96 100644 --- a/Lib/octave/cmalloc.i +++ b/Lib/octave/cmalloc.i @@ -1,5 +1 @@ -// -// cmalloc.i - Object creation using C malloc() -// - %include diff --git a/Lib/octave/director.swg b/Lib/octave/director.swg new file mode 100644 index 000000000..c399a6a89 --- /dev/null +++ b/Lib/octave/director.swg @@ -0,0 +1,132 @@ +/* ----------------------------------------------------------------------------- + * director.swg + * + * This file contains support for director classes so that D proxy + * methods can be called from C++. + * ----------------------------------------------------------------------------- */ + +# define SWIG_DIRECTOR_CAST(ARG) dynamic_cast(ARG) + +#include + +namespace Swig { + + class Director { + octave_swig_type *self; + bool swig_disowned; + + Director(const Director &x); + Director &operator=(const Director &rhs); + public: + + Director(void *vptr):self(0), swig_disowned(false) { + set_rtdir(vptr, this); + } + + ~Director() { + swig_director_destroyed(self, this); + if (swig_disowned) + self->decref(); + } + + void swig_set_self(octave_swig_type *new_self) { + assert(!swig_disowned); + self = new_self; + } + + octave_swig_type *swig_get_self() const { + return self; + } + + void swig_disown() { + if (swig_disowned) + return; + swig_disowned = true; + self->incref(); + } + }; + + struct DirectorTypeMismatchException { + static void raise(const char *msg) { + // ... todo + throw(DirectorTypeMismatchException()); + } + + static void raise(const octave_value &ov, const char *msg) { + // ... todo + raise(msg); + } + }; + + struct DirectorPureVirtualException { + static void raise(const char *msg) { + // ... todo + throw(DirectorPureVirtualException()); + } + + static void raise(const octave_value &ov, const char *msg) { + // ... todo + raise(msg); + } + }; + + SWIGINTERN rtdir_map *get_rtdir_map() { + static swig_module_info *module = 0; + if (!module) + module = SWIG_GetModule(0); + if (!module) + return 0; + if (!module->clientdata) + module->clientdata = new rtdir_map; + return (rtdir_map *) module->clientdata; + } + + SWIGINTERNINLINE void set_rtdir(void *vptr, Director *d) { + rtdir_map *rm = get_rtdir_map(); + if (rm) + (*rm)[vptr] = d; + } + + SWIGINTERNINLINE void erase_rtdir(void *vptr) { + rtdir_map *rm = get_rtdir_map(); + if (rm) + (*rm).erase(vptr); + } + + SWIGINTERNINLINE Director *get_rtdir(void *vptr) { + rtdir_map *rm = get_rtdir_map(); + if (!rm) + return 0; + rtdir_map::const_iterator pos = rm->find(vptr); + Director *rtdir = (pos != rm->end())? pos->second : 0; + return rtdir; + } + + SWIGRUNTIME void swig_director_destroyed(octave_swig_type *self, Director *d) { + self->director_destroyed(d); + } + + SWIGRUNTIME octave_swig_type *swig_director_get_self(Director *d) { + return d->swig_get_self(); + } + + SWIGRUNTIME void swig_director_set_self(Director *d, octave_swig_type *self) { + d->swig_set_self(self); + } + +} + +SWIGRUNTIME void swig_acquire_ownership(void *vptr) { + // assert(0); + // ... todo +} + +SWIGRUNTIME void swig_acquire_ownership_array(void *vptr) { + // assert(0); + // ... todo +} + +SWIGRUNTIME void swig_acquire_ownership_obj(void *vptr, int own) { + // assert(0); + // ... todo +} diff --git a/Lib/octave/exception.i b/Lib/octave/exception.i index 959bba7dd..bb0b15c9d 100644 --- a/Lib/octave/exception.i +++ b/Lib/octave/exception.i @@ -1,9 +1,6 @@ -// -// exception.i - C++ exception support -// - %include + %insert("runtime") { -%define_as(SWIG_exception(code, msg), %block(%error(code, msg); SWIG_fail; )) + %define_as(SWIG_exception(code, msg), %block(%error(code, msg); SWIG_fail; )) } diff --git a/Lib/octave/factory.i b/Lib/octave/factory.i index 029c81004..46a0a8733 100644 --- a/Lib/octave/factory.i +++ b/Lib/octave/factory.i @@ -1,5 +1 @@ -// -// factory.i - Factory method wrapping -// - %include diff --git a/Lib/octave/implicit.i b/Lib/octave/implicit.i index ceb05b7f7..152c2b056 100644 --- a/Lib/octave/implicit.i +++ b/Lib/octave/implicit.i @@ -1,10 +1,7 @@ -// -// implicit.i - %implicit directive -// - %include %include #warning "This file provides the %implicit directive, which is an old and fragile" #warning "way to implement the C++ implicit conversion mechanism." #warning "Try using the more robust '%implicitconv Type;' directive instead." + diff --git a/Lib/octave/octave.swg b/Lib/octave/octave.swg index b25931cfd..872054d88 100644 --- a/Lib/octave/octave.swg +++ b/Lib/octave/octave.swg @@ -1,19 +1,8 @@ -// -// octave.swg - Octave configuration module -// - -// Include standard SWIG macros and fragments %include %include - -// Include Octave runtime code %include - -// Include Octave typemaps +%include %include - -// Include Octave overloaded operator support %include -// Include Octave special user directives -%include +%define %docstring %feature("docstring") %enddef diff --git a/Lib/octave/octcomplex.swg b/Lib/octave/octcomplex.swg index 320dba127..a3e9ebf77 100644 --- a/Lib/octave/octcomplex.swg +++ b/Lib/octave/octcomplex.swg @@ -1,83 +1,92 @@ -// -// octcomplex.swg - Octave complex number support -// +/* + Defines the As/From conversors for double/float complex, you need to + provide complex Type, the Name you want to use in the conversors, + the complex Constructor method, and the Real and Imag complex + accesor methods. -// Defines the As/From conversors for double/float complex, you need to -// provide complex Type, the Name you want to use in the conversors, -// the complex Constructor method, and the Real and Imag complex accessor -// methods. See the std_complex.i and ccomplex.i for concrete examples. + See the std_complex.i and ccomplex.i for concrete examples. +*/ -// Common 'from' conversor +/* the common from conversor */ %define %swig_fromcplx_conv(Type, OctConstructor, Real, Imag) -%fragment(SWIG_From_frag(Type), "header") + %fragment(SWIG_From_frag(Type),"header") { - SWIGINTERNINLINE octave_value SWIG_From(Type)(const Type & c) { - return octave_value(OctConstructor(Real(c), Imag(c))); - } + SWIGINTERNINLINE octave_value + SWIG_From(Type)(const Type& c) + { + return octave_value(OctConstructor(Real(c), Imag(c))); + } } %enddef -// Double-precision 'as' conversor +// the double case %define %swig_cplxdbl_conv(Type, Constructor, Real, Imag) -%fragment(SWIG_AsVal_frag(Type), "header", fragment = SWIG_AsVal_frag(double)) + %fragment(SWIG_AsVal_frag(Type),"header", + fragment=SWIG_AsVal_frag(double)) { - SWIGINTERN int SWIG_AsVal(Type)(const octave_value & ov, Type * val) { - if (ov.is_complex_scalar()) { - if (val) { - Complex c(ov.complex_value()); - *val = Constructor(c.real(), c.imag()); - } - return SWIG_OK; - } else { - double d; - int res = SWIG_AddCast(SWIG_AsVal(double)(ov, &d)); - if (SWIG_IsOK(res)) { - if (val) { - *val = Constructor(d, 0.0); - } - return res; + SWIGINTERN int + SWIG_AsVal(Type) (const octave_value& ov, Type* val) + { + if (ov.is_complex_scalar()) { + if (val) { + Complex c(ov.complex_value()); + *val=Constructor(c.real(),c.imag()); + } + return SWIG_OK; + } else { + double d; + int res = SWIG_AddCast(SWIG_AsVal(double)(ov, &d)); + if (SWIG_IsOK(res)) { + if (val) + *val = Constructor(d, 0.0); + return res; + } } + return SWIG_TypeError; } - return SWIG_TypeError; - } } %swig_fromcplx_conv(Type, Complex, Real, Imag); %enddef -// Single-precision 'as' conversor +// the float case %define %swig_cplxflt_conv(Type, Constructor, Real, Imag) -%fragment(SWIG_AsVal_frag(Type), "header", fragment = SWIG_AsVal_frag(float)) -{ - SWIGINTERN int SWIG_AsVal(Type)(const octave_value & ov, Type * val) { - if (ov.is_complex_scalar()) { - if (val) { - Complex c(ov.complex_value()); - double re = c.real(); - double im = c.imag(); - if ((-FLT_MAX <= re && re <= FLT_MAX) && (-FLT_MAX <= im && im <= FLT_MAX)) { - if (val) - *val = Constructor(%numeric_cast(re, float), %numeric_cast(im, float)); - return SWIG_OK; - } else { - return SWIG_OverflowError; - } - } - } else { - float d; - int res = SWIG_AddCast(SWIG_AsVal(float)(ov, &d)); - if (SWIG_IsOK(res)) { - if (val) { - *val = Constructor(d, 0.0); - } - return res; + %fragment(SWIG_AsVal_frag(Type),"header", + fragment=SWIG_AsVal_frag(float)) { + SWIGINTERN int + SWIG_AsVal(Type) (const octave_value& ov, Type* val) + { + if (ov.is_complex_scalar()) { + if (val) { + Complex c(ov.complex_value()); + double re = c.real(); + double im = c.imag(); + if ((-FLT_MAX <= re && re <= FLT_MAX) && (-FLT_MAX <= im && im <= FLT_MAX)) { + if (val) + *val = Constructor(%numeric_cast(re, float), + %numeric_cast(im, float)); + return SWIG_OK; + } else + return SWIG_OverflowError; + } + } else { + float d; + int res = SWIG_AddCast(SWIG_AsVal(float)(ov, &d)); + if (SWIG_IsOK(res)) { + if (val) + *val = Constructor(d, 0.0); + return res; + } } + return SWIG_TypeError; } - return SWIG_TypeError; - } } %swig_fromcplx_conv(Type, FloatComplex, Real, Imag); %enddef -#define %swig_cplxflt_convn(Type, Constructor, Real, Imag) %swig_cplxflt_conv(Type, Constructor, Real, Imag) -#define %swig_cplxdbl_convn(Type, Constructor, Real, Imag) %swig_cplxdbl_conv(Type, Constructor, Real, Imag) +#define %swig_cplxflt_convn(Type, Constructor, Real, Imag) \ +%swig_cplxflt_conv(Type, Constructor, Real, Imag) + + +#define %swig_cplxdbl_convn(Type, Constructor, Real, Imag) \ +%swig_cplxdbl_conv(Type, Constructor, Real, Imag) diff --git a/Lib/octave/octcontainer.swg b/Lib/octave/octcontainer.swg index c6e88f7c8..723256ca0 100644 --- a/Lib/octave/octcontainer.swg +++ b/Lib/octave/octcontainer.swg @@ -1,20 +1,21 @@ -// -// octcontainer.swg - Octave STL container support -// - -// Octave cell <-> C++ container wrapper -// -// This wrapper, and its iterator, allows a general use (and reuse) of -// the mapping between C++ and Octave, thanks to the C++ templates. -// -// Of course, it needs the C++ compiler to support templates, but -// since we will use this wrapper with the STL containers, that should -// be the case. - -%header %{ +/* ----------------------------------------------------------------------------- + * octcontainer.swg + * + * Octave cell <-> C++ container wrapper + * + * This wrapper, and its iterator, allows a general use (and reuse) of + * the mapping between C++ and Octave, thanks to the C++ templates. + * + * Of course, it needs the C++ compiler to support templates, but + * since we will use this wrapper with the STL containers, that should + * be the case. + * ----------------------------------------------------------------------------- */ + +%{ #include %} + #if !defined(SWIG_NO_EXPORT_ITERATOR_METHODS) # if !defined(SWIG_EXPORT_ITERATOR_METHODS) # define SWIG_EXPORT_ITERATOR_METHODS SWIG_EXPORT_ITERATOR_METHODS @@ -23,585 +24,599 @@ %include +// The Octave C++ Wrap + %fragment(""); %include -%fragment(SWIG_Traits_frag(octave_value), "header", fragment = "StdTraits") +%fragment(SWIG_Traits_frag(octave_value),"header",fragment="StdTraits") { +namespace swig { + template <> struct traits { + typedef value_category category; + static const char* type_name() { return "octave_value"; } + }; + + template <> struct traits_from { + typedef octave_value value_type; + static octave_value from(const value_type& val) { + return val; + } + }; + + template <> + struct traits_check { + static bool check(const octave_value&) { + return true; + } + }; + + template <> struct traits_asval { + typedef octave_value value_type; + static int asval(const octave_value& obj, value_type *val) { + if (val) *val = obj; + return SWIG_OK; + } + }; +} +} + +%fragment("OctSequence_Base","header",fragment="") { +%#include - namespace swig +namespace std { + template <> + struct less : public binary_function { + bool + operator()(const octave_value& v, const octave_value& w) const + { + octave_value res = do_binary_op(octave_value::op_le,v,w); + return res.is_true(); + } + }; +} - template <> - struct traits { - typedef value_category category; - static const char* type_name() { - return "octave_value"; - } - }; +namespace swig { + inline size_t + check_index(ptrdiff_t i, size_t size, bool insert = false) { + if ( i < 0 ) { + if ((size_t) (-i) <= size) + return (size_t) (i + size); + } else if ( (size_t) i < size ) { + return (size_t) i; + } else if (insert && ((size_t) i == size)) { + return size; + } + + throw std::out_of_range("index out of range"); + } - template <> - struct traits_from { - typedef octave_value value_type; - static octave_value from(const value_type& val) { - return val; + inline size_t + slice_index(ptrdiff_t i, size_t size) { + if ( i < 0 ) { + if ((size_t) (-i) <= size) { + return (size_t) (i + size); + } else { + throw std::out_of_range("index out of range"); } - }; + } else { + return ( (size_t) i < size ) ? ((size_t) i) : size; + } + } - template <> - struct traits_check { - static bool check(const octave_value&) { - return true; - } - }; - - template <> - struct traits_asval { - typedef octave_value value_type; - static int asval(const octave_value& obj, value_type* val) { - if (val) { - *val = obj; - } - return SWIG_OK; - } - }; + template + inline typename Sequence::iterator + getpos(Sequence* self, Difference i) { + typename Sequence::iterator pos = self->begin(); + std::advance(pos, check_index(i,self->size())); + return pos; + } + template + inline typename Sequence::const_iterator + cgetpos(const Sequence* self, Difference i) { + typename Sequence::const_iterator pos = self->begin(); + std::advance(pos, check_index(i,self->size())); + return pos; } + template + inline Sequence* + getslice(const Sequence* self, Difference i, Difference j) { + typename Sequence::size_type size = self->size(); + typename Sequence::size_type ii = swig::check_index(i, size); + typename Sequence::size_type jj = swig::slice_index(j, size); + + if (jj > ii) { + typename Sequence::const_iterator vb = self->begin(); + typename Sequence::const_iterator ve = self->begin(); + std::advance(vb,ii); + std::advance(ve,jj); + return new Sequence(vb, ve); + } else { + return new Sequence(); + } + } + + template + inline void + setslice(Sequence* self, Difference i, Difference j, const InputSeq& v) { + typename Sequence::size_type size = self->size(); + typename Sequence::size_type ii = swig::check_index(i, size, true); + typename Sequence::size_type jj = swig::slice_index(j, size); + if (jj < ii) jj = ii; + size_t ssize = jj - ii; + if (ssize <= v.size()) { + typename Sequence::iterator sb = self->begin(); + typename InputSeq::const_iterator vmid = v.begin(); + std::advance(sb,ii); + std::advance(vmid, jj - ii); + self->insert(std::copy(v.begin(), vmid, sb), vmid, v.end()); + } else { + typename Sequence::iterator sb = self->begin(); + typename Sequence::iterator se = self->begin(); + std::advance(sb,ii); + std::advance(se,jj); + self->erase(sb,se); + self->insert(sb, v.begin(), v.end()); + } + } + + template + inline void + delslice(Sequence* self, Difference i, Difference j) { + typename Sequence::size_type size = self->size(); + typename Sequence::size_type ii = swig::check_index(i, size, true); + typename Sequence::size_type jj = swig::slice_index(j, size); + if (jj > ii) { + typename Sequence::iterator sb = self->begin(); + typename Sequence::iterator se = self->begin(); + std::advance(sb,ii); + std::advance(se,jj); + self->erase(sb,se); + } + } +} } -%fragment("OctSequence_Base", "header", fragment = "") +%fragment("OctSequence_Cont","header", + fragment="StdTraits", + fragment="OctSequence_Base", + fragment="OctSwigIterator_T") { -%#include - - namespace std +namespace swig +{ + template + struct OctSequence_Ref // * octave can't support these, because of how assignment works { - - template <> - struct less : public binary_function { - bool - operator()(const octave_value& v, const octave_value& w) const { - octave_value res = do_binary_op(octave_value::op_le, v, w); - return res.is_true(); + OctSequence_Ref(const octave_value& seq, int index) + : _seq(seq), _index(index) + { + } + + operator T () const + { + // swig::SwigVar_PyObject item = OctSequence_GetItem(_seq, _index); + octave_value item; // * todo + try { + return swig::as(item, true); + } catch (std::exception& e) { + char msg[1024]; + sprintf(msg, "in sequence element %d ", _index); + if (!Octave_Error_Occurred()) { + %type_error(swig::type_name()); + } + SWIG_Octave_AddErrorMsg(msg); + SWIG_Octave_AddErrorMsg(e.what()); + throw; } - }; + } - } + OctSequence_Ref& operator=(const T& v) + { + // OctSequence_SetItem(_seq, _index, swig::from(v)); + // * todo + return *this; + } + + private: + octave_value _seq; + int _index; + }; - namespace swig + template + struct OctSequence_ArrowProxy { + OctSequence_ArrowProxy(const T& x): m_value(x) {} + const T* operator->() const { return &m_value; } + operator const T*() const { return &m_value; } + T m_value; + }; + + template + struct OctSequence_InputIterator + { + typedef OctSequence_InputIterator self; - inline size_t check_index(ptrdiff_t i, size_t size, bool insert = false) - { - if (i < 0) { - if ((size_t)(-i) <= size) { - return (size_t)(i + size); - } - } else if ((size_t) i < size) { - return (size_t) i; - } else if (insert && ((size_t) i == size)) { - return size; - } + typedef std::random_access_iterator_tag iterator_category; + typedef Reference reference; + typedef T value_type; + typedef T* pointer; + typedef int difference_type; - throw std::out_of_range("index out of range"); + OctSequence_InputIterator() + { } - inline size_t slice_index(ptrdiff_t i, size_t size) + OctSequence_InputIterator(const octave_value& seq, int index) + : _seq(seq), _index(index) { - if (i < 0) { - if ((size_t)(-i) <= size) { - return (size_t)(i + size); - } else { - throw std::out_of_range("index out of range"); - } - } else { - return ((size_t) i < size) ? ((size_t) i) : size; - } } - template - inline typename Sequence::iterator getpos(Sequence* self, Difference i) + reference operator*() const { - typename Sequence::iterator pos = self->begin(); - std::advance(pos, check_index(i, self->size())); - return pos; + return reference(_seq, _index); } - template - inline typename Sequence::const_iterator cgetpos(const Sequence* self, Difference i) - { - typename Sequence::const_iterator pos = self->begin(); - std::advance(pos, check_index(i, self->size())); - return pos; + OctSequence_ArrowProxy + operator->() const { + return OctSequence_ArrowProxy(operator*()); } - template - inline Sequence* getslice(const Sequence* self, Difference i, Difference j) + bool operator==(const self& ri) const { - typename Sequence::size_type size = self->size(); - typename Sequence::size_type ii = swig::check_index(i, size); - typename Sequence::size_type jj = swig::slice_index(j, size); - if (jj > ii) { - typename Sequence::const_iterator vb = self->begin(); - typename Sequence::const_iterator ve = self->begin(); - std::advance(vb, ii); - std::advance(ve, jj); - return new Sequence(vb, ve); - } else { - return new Sequence(); - } + return (_index == ri._index); } - template - inline void setslice(Sequence* self, Difference i, Difference j, const InputSeq& v) + bool operator!=(const self& ri) const { - typename Sequence::size_type size = self->size(); - typename Sequence::size_type ii = swig::check_index(i, size, true); - typename Sequence::size_type jj = swig::slice_index(j, size); - if (jj < ii) { - jj = ii; - } - size_t ssize = jj - ii; - if (ssize <= v.size()) { - typename Sequence::iterator sb = self->begin(); - typename InputSeq::const_iterator vmid = v.begin(); - std::advance(sb, ii); - std::advance(vmid, jj - ii); - self->insert(std::copy(v.begin(), vmid, sb), vmid, v.end()); - } else { - typename Sequence::iterator sb = self->begin(); - typename Sequence::iterator se = self->begin(); - std::advance(sb, ii); - std::advance(se, jj); - self->erase(sb, se); - self->insert(sb, v.begin(), v.end()); - } + return !(operator==(ri)); } - template - inline void delslice(Sequence* self, Difference i, Difference j) + self& operator ++ () { - typename Sequence::size_type size = self->size(); - typename Sequence::size_type ii = swig::check_index(i, size, true); - typename Sequence::size_type jj = swig::slice_index(j, size); - if (jj > ii) { - typename Sequence::iterator sb = self->begin(); - typename Sequence::iterator se = self->begin(); - std::advance(sb, ii); - std::advance(se, jj); - self->erase(sb, se); - } + ++_index; + return *this; } - } - -} - -%fragment("OctSequence_Cont", "header", fragment = "StdTraits", fragment = "OctSequence_Base", fragment = "OctIterator_T") -{ - - namespace swig - { - - template - struct OctSequence_Ref { // * octave can't support these, because of how assignment works - - OctSequence_Ref(const octave_value& seq, int index) - : _seq(seq), _index(index) { - } - - operator T() const { - octave_value item; // * todo - try { - return swig::as (item, true); - } catch (std::exception& e) { - char msg[1024]; - sprintf(msg, "in sequence element %d ", _index); - if (!SWIG_Octave_ErrorOccurred()) { - %type_error(swig::type_name()); - } - SWIG_Octave_AddErrorMsg(msg); - SWIG_Octave_AddErrorMsg(e.what()); - throw; - } - } - - OctSequence_Ref& operator= (const T& v) { - // * todo - return *this; - } - - private: - - octave_value _seq; - int _index; - - }; - - template - struct OctSequence_ArrowProxy { - OctSequence_ArrowProxy(const T& x) : m_value(x) {} - const T* operator->() const { - return &m_value; - } - operator const T* () const { - return &m_value; - } - T m_value; - }; - - template - struct OctSequence_InputIterator { - - typedef OctSequence_InputIterator self; - typedef std::random_access_iterator_tag iterator_category; - typedef Reference reference; - typedef T value_type; - typedef T* pointer; - typedef int difference_type; - - OctSequence_InputIterator() { - } - - OctSequence_InputIterator(const octave_value& seq, int index) - : _seq(seq), _index(index) { - } - - reference operator*() const { - return reference(_seq, _index); - } - - OctSequence_ArrowProxy - operator->() const { - return OctSequence_ArrowProxy (operator*()); - } - - bool operator== (const self& ri) const { - return (_index == ri._index); - } - - bool operator!= (const self& ri) const { - return !(operator== (ri)); - } - - self& operator ++ () { - ++_index; - return *this; - } - - self& operator -- () { - --_index; - return *this; - } + self& operator -- () + { + --_index; + return *this; + } - self& operator += (difference_type n) { - _index += n; - return *this; - } + self& operator += (difference_type n) + { + _index += n; + return *this; + } - self operator + (difference_type n) const { - return self(_seq, _index + n); - } + self operator +(difference_type n) const + { + return self(_seq, _index + n); + } - self& operator -= (difference_type n) { - _index -= n; - return *this; - } + self& operator -= (difference_type n) + { + _index -= n; + return *this; + } - self operator - (difference_type n) const { - return self(_seq, _index - n); - } + self operator -(difference_type n) const + { + return self(_seq, _index - n); + } - difference_type operator - (const self& ri) const { - return _index - ri._index; - } + difference_type operator - (const self& ri) const + { + return _index - ri._index; + } - bool operator < (const self& ri) const { - return _index < ri._index; - } + bool operator < (const self& ri) const + { + return _index < ri._index; + } - reference - operator[](difference_type n) const { - return reference(_seq, _index + n); - } + reference + operator[](difference_type n) const + { + return reference(_seq, _index + n); + } - private: - octave_value _seq; - difference_type _index; - }; - - template - struct OctSequence_Cont { - typedef OctSequence_Ref reference; - typedef const OctSequence_Ref const_reference; - typedef T value_type; - typedef T* pointer; - typedef int difference_type; - typedef int size_type; - typedef const pointer const_pointer; - typedef OctSequence_InputIterator iterator; - typedef OctSequence_InputIterator const_iterator; - - OctSequence_Cont(const octave_value& seq) : _seq(seq) { - } + private: + octave_value _seq; + difference_type _index; + }; - ~OctSequence_Cont() { - } + template + struct OctSequence_Cont + { + typedef OctSequence_Ref reference; + typedef const OctSequence_Ref const_reference; + typedef T value_type; + typedef T* pointer; + typedef int difference_type; + typedef int size_type; + typedef const pointer const_pointer; + typedef OctSequence_InputIterator iterator; + typedef OctSequence_InputIterator const_iterator; + + OctSequence_Cont(const octave_value& seq) : _seq(seq) + { + // * assert that we have map type etc. + /* + if (!OctSequence_Check(seq)) { + throw std::invalid_argument("a sequence is expected"); + } + _seq = seq; + Py_INCREF(_seq); + */ + } - size_type size() const { - return 0; // * todo - } + ~OctSequence_Cont() + { + } - bool empty() const { - return size() == 0; - } + size_type size() const + { + // return static_cast(OctSequence_Size(_seq)); + return 0; // * todo + } - iterator begin() { - return iterator(_seq, 0); - } + bool empty() const + { + return size() == 0; + } - const_iterator begin() const { - return const_iterator(_seq, 0); - } + iterator begin() + { + return iterator(_seq, 0); + } - iterator end() { - return iterator(_seq, size()); - } + const_iterator begin() const + { + return const_iterator(_seq, 0); + } - const_iterator end() const { - return const_iterator(_seq, size()); - } + iterator end() + { + return iterator(_seq, size()); + } - reference operator[](difference_type n) { - return reference(_seq, n); - } + const_iterator end() const + { + return const_iterator(_seq, size()); + } - const_reference operator[](difference_type n) const { - return const_reference(_seq, n); - } + reference operator[](difference_type n) + { + return reference(_seq, n); + } - bool check(bool set_err = true) const { - int s = size(); - for (int i = 0; i < s; ++i) { - octave_value item; // * todo - if (!swig::check (item)) { - if (set_err) { - char msg[1024]; - sprintf(msg, "in sequence element %d", i); - SWIG_Error(SWIG_RuntimeError, msg); - } - return false; - } - } - return true; - } + const_reference operator[](difference_type n) const + { + return const_reference(_seq, n); + } - private: - octave_value _seq; - }; + bool check(bool set_err = true) const + { + int s = size(); + for (int i = 0; i < s; ++i) { + // swig::SwigVar_PyObject item = OctSequence_GetItem(_seq, i); + octave_value item; // * todo + if (!swig::check(item)) { + if (set_err) { + char msg[1024]; + sprintf(msg, "in sequence element %d", i); + SWIG_Error(SWIG_RuntimeError, msg); + } + return false; + } + } + return true; + } - } + private: + octave_value _seq; + }; } +} %define %swig_sequence_iterator(Sequence...) #if defined(SWIG_EXPORT_ITERATOR_METHODS) + class iterator; + class reverse_iterator; + class const_iterator; + class const_reverse_iterator; + + %typemap(out,noblock=1,fragment="OctSequence_Cont") + iterator, reverse_iterator, const_iterator, const_reverse_iterator { + $result = SWIG_NewPointerObj(swig::make_output_iterator(%static_cast($1,const $type &)), + swig::OctSwigIterator::descriptor(),SWIG_POINTER_OWN); + } + %typemap(out,fragment="OctSequence_Cont") + std::pair, std::pair { + octave_value_list tmpc; + tmpc.append(SWIG_NewPointerObj(swig::make_output_iterator(%static_cast($1,const $type &).first), + swig::OctSwigIterator::descriptor(),SWIG_POINTER_OWN)); + tmpc.append(SWIG_NewPointerObj(swig::make_output_iterator(%static_cast($1,const $type &).second), + swig::OctSwigIterator::descriptor(),SWIG_POINTER_OWN)); + $result = Cell(tmpc); + } -class iterator; -class reverse_iterator; -class const_iterator; -class const_reverse_iterator; - -%typemap(out, noblock = 1, fragment = "OctSequence_Cont") iterator, reverse_iterator, const_iterator, const_reverse_iterator { - $result = SWIG_NewPointerObj(swig::make_output_iterator(%static_cast($1, const $type&)), - swig::OctIterator::descriptor(), SWIG_POINTER_OWN); -} -%typemap(out, fragment = "OctSequence_Cont") std::pair, std::pair { - octave_value_list tmpc; - tmpc.append(SWIG_NewPointerObj(swig::make_output_iterator(%static_cast($1, const $type&).first), swig::OctIterator::descriptor(), SWIG_POINTER_OWN)); - tmpc.append(SWIG_NewPointerObj(swig::make_output_iterator(%static_cast($1, const $type&).second), swig::OctIterator::descriptor(), SWIG_POINTER_OWN)); - $result = Cell(tmpc); -} - -%fragment("OctPairBoolOutputIterator", "header", fragment = SWIG_From_frag(bool), fragment = "OctSequence_Cont") {} + %fragment("SwigPyPairBoolOutputIterator","header",fragment=SWIG_From_frag(bool),fragment="OctSequence_Cont") {} -%typemap(out, fragment = "OctPairBoolOutputIterator") std::pair, std::pair { - octave_value_list tmpc; - tmpc.append(SWIG_NewPointerObj(swig::make_output_iterator(%static_cast($1, const $type&).first), - swig::OctIterator::descriptor(), SWIG_POINTER_OWN)); - tmpc.append(SWIG_From(bool)(%static_cast($1, const $type&).second)); - $result = Cell(tmpc); -} + %typemap(out,fragment="OctPairBoolOutputIterator") + std::pair, std::pair { + octave_value_list tmpc; + tmpc.append(SWIG_NewPointerObj(swig::make_output_iterator(%static_cast($1,const $type &).first), + swig::OctSwigIterator::descriptor(),SWIG_POINTER_OWN)); + tmpc.append(SWIG_From(bool)(%static_cast($1,const $type &).second)); + $result = Cell(tmpc); + } -%typemap(in, noblock = 1, fragment = "OctSequence_Cont") - iterator(swig::OctIterator* iter = 0, int res), - reverse_iterator(swig::OctIterator* iter = 0, int res), - const_iterator(swig::OctIterator* iter = 0, int res), - const_reverse_iterator(swig::OctIterator* iter = 0, int res) -{ - res = SWIG_ConvertPtr($input, %as_voidptrptr(&iter), swig::OctIterator::descriptor(), 0); - if (!SWIG_IsOK(res) || !iter) { - %argument_fail(SWIG_TypeError, "$type", $symname, $argnum); - } else { - swig::OctIterator_T < $type > *iter_t = dynamic_cast < swig::OctIterator_T < $type > * >(iter); - if (iter_t) { - $1 = iter_t->get_current(); - } else { + %typemap(in,noblock=1,fragment="OctSequence_Cont") + iterator(swig::OctSwigIterator *iter = 0, int res), + reverse_iterator(swig::OctSwigIterator *iter = 0, int res), + const_iterator(swig::OctSwigIterator *iter = 0, int res), + const_reverse_iterator(swig::OctSwigIterator *iter = 0, int res) { + res = SWIG_ConvertPtr($input, %as_voidptrptr(&iter), swig::OctSwigIterator::descriptor(), 0); + if (!SWIG_IsOK(res) || !iter) { %argument_fail(SWIG_TypeError, "$type", $symname, $argnum); + } else { + swig::OctSwigIterator_T<$type > *iter_t = dynamic_cast *>(iter); + if (iter_t) { + $1 = iter_t->get_current(); + } else { + %argument_fail(SWIG_TypeError, "$type", $symname, $argnum); + } } } -} -%typecheck(%checkcode(ITERATOR), noblock = 1, fragment = "OctSequence_Cont") iterator, reverse_iterator, const_iterator, const_reverse_iterator { - swig::OctIterator* iter = 0; - int res = SWIG_ConvertPtr($input, %as_voidptrptr(&iter), swig::OctIterator::descriptor(), 0); - $1 = (SWIG_IsOK(res) && iter && (dynamic_cast < swig::OctIterator_T < $type > * >(iter) != 0)); -} - -%fragment("OctSequence_Cont"); + %typecheck(%checkcode(ITERATOR),noblock=1,fragment="OctSequence_Cont") + iterator, reverse_iterator, const_iterator, const_reverse_iterator { + swig::OctSwigIterator *iter = 0; + int res = SWIG_ConvertPtr($input, %as_voidptrptr(&iter), swig::OctSwigIterator::descriptor(), 0); + $1 = (SWIG_IsOK(res) && iter && (dynamic_cast *>(iter) != 0)); + } + %fragment("OctSequence_Cont"); #endif //SWIG_EXPORT_ITERATOR_METHODS %enddef -// Octave container methods +// The octave container methods %define %swig_container_methods(Container...) %enddef %define %swig_sequence_methods_common(Sequence...) -%swig_sequence_iterator(%arg(Sequence)) -%swig_container_methods(%arg(Sequence)) - -%fragment("OctSequence_Base"); - -%extend { - - value_type pop() throw(std::out_of_range) { - if (self->size() == 0) { - throw std::out_of_range("pop from empty container"); + %swig_sequence_iterator(%arg(Sequence)) + %swig_container_methods(%arg(Sequence)) + + %fragment("OctSequence_Base"); + + %extend { + value_type pop() throw (std::out_of_range) { + if (self->size() == 0) + throw std::out_of_range("pop from empty container"); + Sequence::value_type x = self->back(); + self->pop_back(); + return x; } - Sequence::value_type x = self->back(); - self->pop_back(); - return x; - } - value_type __paren__(difference_type i) throw(std::out_of_range) { - return * (swig::cgetpos(self, i)); - } + value_type __paren__(difference_type i) throw (std::out_of_range) { + return *(swig::cgetpos(self, i)); + } - void __paren_asgn__(difference_type i, value_type x) throw(std::out_of_range) { - * (swig::getpos(self, i)) = x; - } + void __paren_asgn__(difference_type i, value_type x) throw (std::out_of_range) { + *(swig::getpos(self,i)) = x; + } - void append(value_type x) { - self->push_back(x); + void append(value_type x) { + self->push_back(x); + } } -} %enddef %define %swig_sequence_methods(Sequence...) -%swig_sequence_methods_common(%arg(Sequence)) + %swig_sequence_methods_common(%arg(Sequence)) %enddef %define %swig_sequence_methods_val(Sequence...) -%swig_sequence_methods_common(%arg(Sequence)) + %swig_sequence_methods_common(%arg(Sequence)) %enddef +// // Common fragments +// -%fragment("StdSequenceTraits", "header", fragment = "StdTraits", fragment = "OctSequence_Cont") +%fragment("StdSequenceTraits","header", + fragment="StdTraits", + fragment="OctSequence_Cont") { - - namespace swig - { - - template - inline void - assign(const OctSeq& octseq, Seq* seq) - { +namespace swig { + template + inline void + assign(const OctSeq& octseq, Seq* seq) { %#ifdef SWIG_STD_NOASSIGN_STL - typedef typename OctSeq::value_type value_type; - typename OctSeq::const_iterator it = octseq.begin(); - for (; it != octseq.end(); ++it) { - seq->insert(seq->end(), (value_type)(*it)); - } + typedef typename OctSeq::value_type value_type; + typename OctSeq::const_iterator it = octseq.begin(); + for (;it != octseq.end(); ++it) { + seq->insert(seq->end(),(value_type)(*it)); + } %#else - seq->assign(octseq.begin(), octseq.end()); + seq->assign(octseq.begin(), octseq.end()); %#endif - } - - template - struct traits_asptr_stdseq { - - typedef Seq sequence; - typedef T value_type; - - static int asptr(const octave_value& obj, sequence** seq) { - if (!obj.is_defined() || SWIG_Octave_ValueDeref(obj)) { - sequence* p; - if (SWIG_ConvertPtr(obj, (void**) &p, swig::type_info(), 0) == SWIG_OK) { - if (seq) { - *seq = p; - } - return SWIG_OLDOBJ; - } - } else if (obj.is_cell()) { - try { - OctSequence_Cont octseq(obj); - if (seq) { - sequence* pseq = new sequence(); - assign(octseq, pseq); - *seq = pseq; - return SWIG_NEWOBJ; - } else { - return octseq.check() ? SWIG_OK : SWIG_ERROR; - } - } catch (std::exception& e) { - if (seq && !error_state) { - error("swig type error: %s", e.what()); - } - return SWIG_ERROR; - } - } - return SWIG_ERROR; - } - }; + } - template - struct traits_from_stdseq { + template + struct traits_asptr_stdseq { + typedef Seq sequence; + typedef T value_type; + + static int asptr(const octave_value& obj, sequence **seq) { + if (!obj.is_defined() || Swig::swig_value_deref(obj)) { + sequence *p; + if (SWIG_ConvertPtr(obj,(void**)&p, + swig::type_info(),0) == SWIG_OK) { + if (seq) *seq = p; + return SWIG_OLDOBJ; + } + } else if (obj.is_cell()) { + try { + OctSequence_Cont octseq(obj); + if (seq) { + sequence *pseq = new sequence(); + assign(octseq, pseq); + *seq = pseq; + return SWIG_NEWOBJ; + } else { + return octseq.check() ? SWIG_OK : SWIG_ERROR; + } + } catch (std::exception& e) { + if (seq&&!error_state) + error("swig type error: %s",e.what()); + return SWIG_ERROR; + } + } + return SWIG_ERROR; + } + }; - typedef Seq sequence; - typedef T value_type; - typedef typename Seq::size_type size_type; - typedef typename sequence::const_iterator const_iterator; + template + struct traits_from_stdseq { + typedef Seq sequence; + typedef T value_type; + typedef typename Seq::size_type size_type; + typedef typename sequence::const_iterator const_iterator; - static octave_value from(const sequence& seq) { + static octave_value from(const sequence& seq) { #ifdef SWIG_OCTAVE_EXTRA_NATIVE_CONTAINERS - swig_type_info* desc = swig::type_info(); - if (desc && desc->clientdata) { - return SWIG_NewPointerObj(new sequence(seq), desc, SWIG_POINTER_OWN); - } + swig_type_info *desc = swig::type_info(); + if (desc && desc->clientdata) { + return SWIG_NewPointerObj(new sequence(seq), desc, SWIG_POINTER_OWN); + } #endif - size_type size = seq.size(); - if (size <= (size_type) INT_MAX) { - Cell c(size, 1); - int i = 0; - for (const_iterator it = seq.begin(); - it != seq.end(); ++it, ++i) { - c(i) = swig::from (*it); - } - return c; - } else { - error("swig overflow error: sequence size not valid in octave"); - return octave_value(); - } - return octave_value(); + size_type size = seq.size(); + if (size <= (size_type)INT_MAX) { + Cell c(size,1); + int i = 0; + for (const_iterator it = seq.begin(); + it != seq.end(); ++it, ++i) { + c(i) = swig::from(*it); + } + return c; + } else { + error("swig overflow error: sequence size not valid in octave"); + return octave_value(); } - - }; - - } - + return octave_value(); + } + }; +} } + diff --git a/Lib/octave/octfragments.swg b/Lib/octave/octfragments.swg index 2c81e546c..8b1378917 100644 --- a/Lib/octave/octfragments.swg +++ b/Lib/octave/octfragments.swg @@ -1,20 +1 @@ -// -// octfragments.swg - Octave user fragments -// -// Create a file with this name, 'octfragments.swg', in your working -// directory and add all the %fragments you want to take precedence -// over the default ones defined by SWIG. -// -// For example, if you add: -// -// %fragment(SWIG_AsVal_frag(int),"header") { -// SWIGINTERNINLINE int SWIG_AsVal(int)(octave_value& obj, int *val) { -// ; -// } -// } -// -// this will replace the code used to retrieve an integer value for all -// the typemaps that need it, including: -// -// int, std::vector, std::list >, etc. diff --git a/Lib/octave/octiterators.swg b/Lib/octave/octiterators.swg index e4b7f4488..79a20f833 100644 --- a/Lib/octave/octiterators.swg +++ b/Lib/octave/octiterators.swg @@ -1,345 +1,357 @@ -// -// octiterators.swg - Octave STL iterator support -// - -// Users can derive form the OctIterator to implement their -// own iterators. As an example (real one since we use it for STL/STD -// containers), the template OctIterator_T does the -// implementation for generic C++ iterators. +/* ----------------------------------------------------------------------------- + * octiterators.swg + * + * Users can derive form the OctSwigIterator to implemet their + * own iterators. As an example (real one since we use it for STL/STD + * containers), the template OctSwigIterator_T does the + * implementation for generic C++ iterators. + * ----------------------------------------------------------------------------- */ %include -%fragment("OctIterator", "header", fragment = "") -{ - - namespace swig - { - - struct OctStopIteration { - }; - - struct OctIterator { - - private: - - octave_value _seq; - - protected: - - OctIterator(octave_value seq) : _seq(seq) { - } - - public: - - virtual ~OctIterator() {} - - virtual octave_value value() const = 0; - - virtual OctIterator* incr(size_t n = 1) = 0; - - virtual OctIterator* decr(size_t n = 1) { - throw OctStopIteration(); - } - - virtual ptrdiff_t distance(const OctIterator& x) const { - throw std::invalid_argument("operation not supported"); - } - - virtual bool equal(const OctIterator& x) const { - throw std::invalid_argument("operation not supported"); - } - - virtual OctIterator* copy() const = 0; - - octave_value next() { - octave_value obj = value(); - incr(); - return obj; - } +%fragment("OctSwigIterator","header",fragment="") { +namespace swig { + struct stop_iteration { + }; - octave_value previous() { - decr(); - return value(); - } + struct OctSwigIterator { + private: + octave_value _seq; - OctIterator* advance(ptrdiff_t n) { - return (n > 0) ? incr(n) : decr(-n); - } + protected: + OctSwigIterator(octave_value seq) : _seq(seq) + { + } + + public: + virtual ~OctSwigIterator() {} - bool operator== (const OctIterator& x) const { - return equal(x); - } + virtual octave_value value() const = 0; - bool operator!= (const OctIterator& x) const { - return ! operator== (x); - } + virtual OctSwigIterator *incr(size_t n = 1) = 0; - OctIterator* operator++ () { - incr(); - return this; - } + virtual OctSwigIterator *decr(size_t n = 1) + { + throw stop_iteration(); + } - OctIterator* operator-- () { - decr(); - return this; - } + virtual ptrdiff_t distance(const OctSwigIterator &x) const + { + throw std::invalid_argument("operation not supported"); + } - OctIterator* operator+ (ptrdiff_t n) const { - return copy()->advance(n); - } + virtual bool equal (const OctSwigIterator &x) const + { + throw std::invalid_argument("operation not supported"); + } + + virtual OctSwigIterator *copy() const = 0; - OctIterator* operator- (ptrdiff_t n) const { - return copy()->advance(-n); - } + octave_value next() + { + octave_value obj = value(); + incr(); + return obj; + } - ptrdiff_t operator- (const OctIterator& x) const { - return x.distance(*this); - } + octave_value previous() + { + decr(); + return value(); + } - static swig_type_info* descriptor() { - static int init = 0; - static swig_type_info* desc = 0; - if (!init) { - desc = SWIG_TypeQuery("swig::OctIterator *"); - init = 1; - } - return desc; - } + OctSwigIterator *advance(ptrdiff_t n) + { + return (n > 0) ? incr(n) : decr(-n); + } + + bool operator == (const OctSwigIterator& x) const + { + return equal(x); + } + + bool operator != (const OctSwigIterator& x) const + { + return ! operator==(x); + } - }; + OctSwigIterator* operator ++ () { + incr(); + return this; + } - } + OctSwigIterator* operator -- () { + decr(); + return this; + } + + OctSwigIterator* operator + (ptrdiff_t n) const + { + return copy()->advance(n); + } + OctSwigIterator* operator - (ptrdiff_t n) const + { + return copy()->advance(-n); + } + + ptrdiff_t operator - (const OctSwigIterator& x) const + { + return x.distance(*this); + } + + static swig_type_info* descriptor() { + static int init = 0; + static swig_type_info* desc = 0; + if (!init) { + desc = SWIG_TypeQuery("swig::OctSwigIterator *"); + init = 1; + } + return desc; + } + }; +} } -%fragment("OctIterator_T", "header", fragment = "", fragment = "OctIterator", fragment = "StdTraits", fragment = "StdIteratorTraits") -{ - - namespace swig +%fragment("OctSwigIterator_T","header",fragment="",fragment="OctSwigIterator",fragment="StdTraits",fragment="StdIteratorTraits") { +namespace swig { + template + class OctSwigIterator_T : public OctSwigIterator { + public: + typedef OutIterator out_iterator; + typedef typename std::iterator_traits::value_type value_type; + typedef OctSwigIterator_T self_type; - template - class OctIterator_T : public OctIterator + OctSwigIterator_T(out_iterator curr, octave_value seq) + : OctSwigIterator(seq), current(curr) { + } - public: - - typedef OutIterator out_iterator; - typedef typename std::iterator_traits::value_type value_type; - typedef OctIterator_T self_type; - - OctIterator_T(out_iterator curr, octave_value seq) - : OctIterator(seq), current(curr) { - } - - const out_iterator& get_current() const { - return current; - } - - bool equal(const OctIterator& iter) const { - const self_type* iters = dynamic_cast(&iter); - if (iters) { - return (current == iters->get_current()); - } else { - throw std::invalid_argument("bad iterator type"); - } - } - - ptrdiff_t distance(const OctIterator& iter) const { - const self_type* iters = dynamic_cast(&iter); - if (iters) { - return std::distance(current, iters->get_current()); - } else { - throw std::invalid_argument("bad iterator type"); - } - } - - protected: - - out_iterator current; - - }; - - template - struct OctFromOper { - typedef const ValueType& argument_type; - typedef octave_value result_type; - result_type operator()(argument_type v) const { - return swig::from(v); - } - }; - - template < typename OutIterator, typename ValueType = typename std::iterator_traits::value_type, typename FromOper = OctFromOper > - class OctIteratorOpen_T : public OctIterator_T + const out_iterator& get_current() const { + return current; + } - public: - - FromOper from; - typedef OutIterator out_iterator; - typedef ValueType value_type; - typedef OctIterator_T base; - typedef OctIteratorOpen_T self_type; - - OctIteratorOpen_T(out_iterator curr, octave_value seq) - : OctIterator_T (curr, seq) { - } - - octave_value value() const { - return from(static_cast(* (base::current))); - } - - OctIterator* copy() const { - return new self_type(*this); - } - - OctIterator* incr(size_t n = 1) { - while (n--) { - ++base::current; - } - return this; - } - - OctIterator* decr(size_t n = 1) { - while (n--) { - --base::current; - } - return this; + + bool equal (const OctSwigIterator &iter) const + { + const self_type *iters = dynamic_cast(&iter); + if (iters) { + return (current == iters->get_current()); + } else { + throw std::invalid_argument("bad iterator type"); } - - }; - - template < typename OutIterator, typename ValueType = typename std::iterator_traits::value_type, typename FromOper = OctFromOper > - class OctIteratorClosed_T : public OctIterator_T + } + + ptrdiff_t distance(const OctSwigIterator &iter) const { - - public: - - FromOper from; - typedef OutIterator out_iterator; - typedef ValueType value_type; - typedef OctIterator_T base; - typedef OctIteratorClosed_T self_type; - - OctIteratorClosed_T(out_iterator curr, out_iterator first, out_iterator last, octave_value seq) - : OctIterator_T (curr, seq), begin(first), end(last) { + const self_type *iters = dynamic_cast(&iter); + if (iters) { + return std::distance(current, iters->get_current()); + } else { + throw std::invalid_argument("bad iterator type"); } + } + + protected: + out_iterator current; + }; + + template + struct from_oper + { + typedef const ValueType& argument_type; + typedef octave_value result_type; + result_type operator()(argument_type v) const + { + return swig::from(v); + } + }; - octave_value value() const { - if (base::current == end) { - throw OctStopIteration(); - } else { - return from(static_cast(* (base::current))); - } - } + template::value_type, + typename FromOper = from_oper > + class OctSwigIteratorOpen_T : public OctSwigIterator_T + { + public: + FromOper from; + typedef OutIterator out_iterator; + typedef ValueType value_type; + typedef OctSwigIterator_T base; + typedef OctSwigIteratorOpen_T self_type; + + OctSwigIteratorOpen_T(out_iterator curr, octave_value seq) + : OctSwigIterator_T(curr, seq) + { + } + + octave_value value() const { + return from(static_cast(*(base::current))); + } + + OctSwigIterator *copy() const + { + return new self_type(*this); + } - OctIterator* copy() const { - return new self_type(*this); + OctSwigIterator *incr(size_t n = 1) + { + while (n--) { + ++base::current; } + return this; + } - OctIterator* incr(size_t n = 1) { - while (n--) { - if (base::current == end) { - throw OctStopIteration(); - } else { - ++base::current; - } - } - return this; + OctSwigIterator *decr(size_t n = 1) + { + while (n--) { + --base::current; } + return this; + } + }; - OctIterator* decr(size_t n = 1) { - while (n--) { - if (base::current == begin) { - throw OctStopIteration(); - } else { - --base::current; - } - } - return this; + template::value_type, + typename FromOper = from_oper > + class OctSwigIteratorClosed_T : public OctSwigIterator_T + { + public: + FromOper from; + typedef OutIterator out_iterator; + typedef ValueType value_type; + typedef OctSwigIterator_T base; + typedef OctSwigIteratorClosed_T self_type; + + OctSwigIteratorClosed_T(out_iterator curr, out_iterator first, out_iterator last, octave_value seq) + : OctSwigIterator_T(curr, seq), begin(first), end(last) + { + } + + octave_value value() const { + if (base::current == end) { + throw stop_iteration(); + } else { + return from(static_cast(*(base::current))); } + } + + OctSwigIterator *copy() const + { + return new self_type(*this); + } - private: - - out_iterator begin; - out_iterator end; - - }; - - template - inline OctIterator* make_output_iterator(const OutIter& current, const OutIter& begin, const OutIter& end, octave_value seq = octave_value()) + OctSwigIterator *incr(size_t n = 1) { - return new OctIteratorClosed_T (current, begin, end, seq); + while (n--) { + if (base::current == end) { + throw stop_iteration(); + } else { + ++base::current; + } + } + return this; } - template - inline OctIterator* make_output_iterator(const OutIter& current, octave_value seq = octave_value()) + OctSwigIterator *decr(size_t n = 1) { - return new OctIteratorOpen_T (current, seq); + while (n--) { + if (base::current == begin) { + throw stop_iteration(); + } else { + --base::current; + } + } + return this; } + private: + out_iterator begin; + out_iterator end; + }; + + template + inline OctSwigIterator* + make_output_iterator(const OutIter& current, const OutIter& begin,const OutIter& end, octave_value seq = octave_value()) + { + return new OctSwigIteratorClosed_T(current, begin, end, seq); } + template + inline OctSwigIterator* + make_output_iterator(const OutIter& current, octave_value seq = octave_value()) + { + return new OctSwigIteratorOpen_T(current, seq); + } +} } -%fragment("OctIterator"); -namespace swig +%fragment("OctSwigIterator"); +namespace swig { - - // Throw a StopIteration exception - %ignore OctStopIteration; - struct OctStopIteration {}; - %typemap(throws) OctStopIteration { - error("OctStopIteration exception"); +// Throw a StopIteration exception + %ignore stop_iteration; + struct stop_iteration {}; + + %typemap(throws) stop_iteration { + error("stop_iteration exception"); SWIG_fail; } - // Mark methods that return new objects - %newobject OctIterator::copy; - %newobject OctIterator::operator+ (ptrdiff_t n) const; - %newobject OctIterator::operator- (ptrdiff_t n) const; - - %catches(swig::OctStopIteration) OctIterator::value() const; - %catches(swig::OctStopIteration) OctIterator::incr(size_t n = 1); - %catches(swig::OctStopIteration) OctIterator::decr(size_t n = 1); - %catches(std::invalid_argument) OctIterator::distance(const OctIterator& x) const; - %catches(std::invalid_argument) OctIterator::equal(const OctIterator& x) const; - %catches(swig::OctStopIteration) OctIterator::next(); - %catches(swig::OctStopIteration) OctIterator::previous(); - %catches(swig::OctStopIteration) OctIterator::advance(ptrdiff_t n); - %catches(swig::OctStopIteration) OctIterator::operator+= (ptrdiff_t n); - %catches(swig::OctStopIteration) OctIterator::operator-= (ptrdiff_t n); - %catches(swig::OctStopIteration) OctIterator::operator+ (ptrdiff_t n) const; - %catches(swig::OctStopIteration) OctIterator::operator- (ptrdiff_t n) const; - - %nodirector OctIterator; - struct OctIterator { +// Mark methods that return new objects + %newobject OctSwigIterator::copy; + %newobject OctSwigIterator::operator + (ptrdiff_t n) const; + %newobject OctSwigIterator::operator - (ptrdiff_t n) const; - protected: + %nodirector OctSwigIterator; - OctIterator(octave_value seq); + %catches(swig::stop_iteration) OctSwigIterator::value() const; + %catches(swig::stop_iteration) OctSwigIterator::incr(size_t n = 1); + %catches(swig::stop_iteration) OctSwigIterator::decr(size_t n = 1); + %catches(std::invalid_argument) OctSwigIterator::distance(const OctSwigIterator &x) const; + %catches(std::invalid_argument) OctSwigIterator::equal (const OctSwigIterator &x) const; + %catches(swig::stop_iteration) OctSwigIterator::next(); + %catches(swig::stop_iteration) OctSwigIterator::previous(); + %catches(swig::stop_iteration) OctSwigIterator::advance(ptrdiff_t n); + %catches(swig::stop_iteration) OctSwigIterator::operator += (ptrdiff_t n); + %catches(swig::stop_iteration) OctSwigIterator::operator -= (ptrdiff_t n); + %catches(swig::stop_iteration) OctSwigIterator::operator + (ptrdiff_t n) const; + %catches(swig::stop_iteration) OctSwigIterator::operator - (ptrdiff_t n) const; + + + struct OctSwigIterator + { + protected: + OctSwigIterator(octave_value seq); public: + virtual ~OctSwigIterator(); - virtual ~OctIterator(); virtual octave_value value() const = 0; - virtual OctIterator* incr(size_t n = 1) = 0; - virtual OctIterator* decr(size_t n = 1); - virtual ptrdiff_t distance(const OctIterator& x) const; - virtual bool equal(const OctIterator& x) const; - virtual OctIterator* copy() const = 0; + + virtual OctSwigIterator *incr(size_t n = 1) = 0; + + virtual OctSwigIterator *decr(size_t n = 1); + + virtual ptrdiff_t distance(const OctSwigIterator &x) const; + + virtual bool equal (const OctSwigIterator &x) const; + + virtual OctSwigIterator *copy() const = 0; + octave_value next(); octave_value previous(); - OctIterator* advance(ptrdiff_t n); - bool operator== (const OctIterator& x) const; - bool operator!= (const OctIterator& x) const; - OctIterator* operator++ (); - OctIterator* operator-- (); - OctIterator* operator+ (ptrdiff_t n) const; - OctIterator* operator- (ptrdiff_t n) const; - ptrdiff_t operator- (const OctIterator& x) const; - + OctSwigIterator *advance(ptrdiff_t n); + + bool operator == (const OctSwigIterator& x) const; + bool operator != (const OctSwigIterator& x) const; + OctSwigIterator* operator ++ (); + OctSwigIterator* operator -- (); + OctSwigIterator* operator + (ptrdiff_t n) const; + OctSwigIterator* operator - (ptrdiff_t n) const; + ptrdiff_t operator - (const OctSwigIterator& x) const; }; - } + diff --git a/Lib/octave/octopers.swg b/Lib/octave/octopers.swg index 86e7df88a..c38e64d8c 100644 --- a/Lib/octave/octopers.swg +++ b/Lib/octave/octopers.swg @@ -1,17 +1,17 @@ -// -// octopers.swg - Octave overloaded operator support -// +/* ------------------------------------------------------------ + * Overloaded operator support + * ------------------------------------------------------------ */ #ifdef __cplusplus -// Operators supported in Octave, and the methods they are routed to: -// +// operators supported in Octave, and the methods they are routed to + // __brace__ a{args} // __brace_asgn__ a{args} = rhs // __paren__ a(args) // __paren_asgn__ a(args) = rhs // __str__ generates string rep -// + // __not__ !a // __uplus__ +a // __uminus__ -a @@ -40,7 +40,8 @@ // __el_and__ a & b // __el_or__ a | b -// Operators supported in C++, and the methods that route to them: +// operators supported in C++, and the methods that route to them + %rename(__add__) *::operator+; %rename(__add__) *::operator+(); %rename(__add__) *::operator+() const; @@ -84,4 +85,4 @@ %ignoreoperator(EQ) operator=; %ignoreoperator(ARROWSTAR) operator->*; -#endif // __cplusplus +#endif /* __cplusplus */ diff --git a/Lib/octave/octprimtypes.swg b/Lib/octave/octprimtypes.swg index 7105bda48..6f43f21b0 100644 --- a/Lib/octave/octprimtypes.swg +++ b/Lib/octave/octprimtypes.swg @@ -1,259 +1,232 @@ -// -// octprimtypes.swg - Octave primitive types -// +/* ------------------------------------------------------------ + * Primitive Types + * ------------------------------------------------------------ */ + // boolean -%fragment(SWIG_From_frag(bool), "header") +%fragment(SWIG_From_frag(bool),"header") { +SWIGINTERNINLINE octave_value + SWIG_From_dec(bool)(bool value) { - SWIGINTERNINLINE octave_value - SWIG_From_dec(bool)(bool value) { - return octave_value(value); - } + return octave_value(value); +} } -%fragment(SWIG_AsVal_frag(bool), "header", - fragment = SWIG_AsVal_frag(long)) +%fragment(SWIG_AsVal_frag(bool),"header", + fragment=SWIG_AsVal_frag(long)) { +SWIGINTERN int +SWIG_AsVal_dec(bool)(const octave_value& ov, bool *val) { - SWIGINTERN int - SWIG_AsVal_dec(bool)(const octave_value & ov, bool * val) { - if (!ov.is_bool_type()) { - return SWIG_ERROR; - } - if (val) { - *val = ov.bool_value(); - } - return SWIG_OK; - } + if (!ov.is_bool_type()) + return SWIG_ERROR; + if (val) + *val = ov.bool_value(); + return SWIG_OK; +} } // long -%fragment(SWIG_From_frag(long), "header") -{ - SWIGINTERNINLINE octave_value SWIG_From_dec(long)(long value) { - return octave_value(value); - } +%fragment(SWIG_From_frag(long),"header") { + SWIGINTERNINLINE octave_value SWIG_From_dec(long) (long value) + { + return octave_value(value); + } } -%fragment(SWIG_AsVal_frag(long), "header") -{ - SWIGINTERN int SWIG_AsVal_dec(long)(const octave_value & ov, long * val) { - if (!ov.is_scalar_type()) { - return SWIG_TypeError; - } - if (ov.is_complex_scalar()) { - return SWIG_TypeError; - } - if (ov.is_double_type() || ov.is_single_type()) { - double v = ov.double_value(); - if (v != floor(v)) { - return SWIG_TypeError; +%fragment(SWIG_AsVal_frag(long),"header") { + SWIGINTERN int SWIG_AsVal_dec(long)(const octave_value& ov, long* val) + { + if (!ov.is_scalar_type()) + return SWIG_TypeError; + if (ov.is_complex_scalar()) + return SWIG_TypeError; + if (ov.is_double_type()||ov.is_single_type()) { + double v=ov.double_value(); + if (v!=floor(v)) + return SWIG_TypeError; } + if (val) + *val = ov.long_value(); + return SWIG_OK; } - if (val) { - *val = ov.long_value(); - } - return SWIG_OK; - } } // unsigned long -%fragment(SWIG_From_frag(unsigned long), "header") -{ - SWIGINTERNINLINE octave_value SWIG_From_dec(unsigned long)(unsigned long value) { - return octave_value(value); - } +%fragment(SWIG_From_frag(unsigned long),"header") { + SWIGINTERNINLINE octave_value SWIG_From_dec(unsigned long) (unsigned long value) + { + return octave_value(value); + } } -%fragment(SWIG_AsVal_frag(unsigned long), "header") -{ - SWIGINTERN int SWIG_AsVal_dec(unsigned long)(const octave_value & ov, unsigned long * val) { - if (!ov.is_scalar_type()) { - return SWIG_TypeError; - } - if (ov.is_complex_scalar()) { - return SWIG_TypeError; - } - if (ov.is_double_type() || ov.is_single_type()) { - double v = ov.double_value(); - if (v < 0) { - return SWIG_OverflowError; +%fragment(SWIG_AsVal_frag(unsigned long),"header") { + SWIGINTERN int SWIG_AsVal_dec(unsigned long)(const octave_value& ov, unsigned long* val) + { + if (!ov.is_scalar_type()) + return SWIG_TypeError; + if (ov.is_complex_scalar()) + return SWIG_TypeError; + if (ov.is_double_type()||ov.is_single_type()) { + double v=ov.double_value(); + if (v<0) + return SWIG_OverflowError; + if (v!=floor(v)) + return SWIG_TypeError; } - if (v != floor(v)) { - return SWIG_TypeError; - } - } - if (ov.is_int8_type() || ov.is_int16_type() || ov.is_int32_type()) { - long v = ov.long_value(); - if (v < 0) { - return SWIG_OverflowError; + if (ov.is_int8_type()||ov.is_int16_type()|| + ov.is_int32_type()) { + long v=ov.long_value(); + if (v<0) + return SWIG_OverflowError; } - } - if (ov.is_int64_type()) { - long long v = ov.int64_scalar_value().value(); - if (v < 0) { - return SWIG_OverflowError; + if (ov.is_int64_type()) { + long long v=ov.int64_scalar_value().value(); + if (v<0) + return SWIG_OverflowError; } + if (val) + *val = ov.ulong_value(); + return SWIG_OK; } - if (val) { - *val = ov.ulong_value(); - } - return SWIG_OK; - } } // long long -%fragment(SWIG_From_frag(long long), "header") -{ - SWIGINTERNINLINE octave_value SWIG_From_dec(long long)(long long value) { - return octave_int64(value); - } +%fragment(SWIG_From_frag(long long),"header") { + SWIGINTERNINLINE octave_value SWIG_From_dec(long long) (long long value) + { + return octave_int64(value); + } } -%fragment(SWIG_AsVal_frag(long long), "header") -{ - SWIGINTERN int SWIG_AsVal_dec(long long)(const octave_value & ov, long long * val) { - if (!ov.is_scalar_type()) { - return SWIG_TypeError; - } - if (ov.is_complex_scalar()) { - return SWIG_TypeError; - } - if (ov.is_double_type() || ov.is_single_type()) { - double v = ov.double_value(); - if (v != floor(v)) { - return SWIG_TypeError; +%fragment(SWIG_AsVal_frag(long long),"header") { + SWIGINTERN int SWIG_AsVal_dec(long long)(const octave_value& ov, long long* val) + { + if (!ov.is_scalar_type()) + return SWIG_TypeError; + if (ov.is_complex_scalar()) + return SWIG_TypeError; + if (ov.is_double_type()||ov.is_single_type()) { + double v=ov.double_value(); + if (v!=floor(v)) + return SWIG_TypeError; } - } - if (val) { - if (ov.is_int64_type()) { - *val = ov.int64_scalar_value().value(); - } else if (ov.is_uint64_type()) { - *val = ov.uint64_scalar_value().value(); - } else { - *val = ov.long_value(); + if (val) { + if (ov.is_int64_type()) + *val = ov.int64_scalar_value().value(); + else if (ov.is_uint64_type()) + *val = ov.uint64_scalar_value().value(); + else + *val = ov.long_value(); } + return SWIG_OK; } - return SWIG_OK; - } } -%fragment(SWIG_From_frag(unsigned long long), "header") -{ - SWIGINTERNINLINE octave_value SWIG_From_dec(unsigned long long)(unsigned long long value) { - return octave_uint64(value); - } +%fragment(SWIG_From_frag(unsigned long long),"header") { + SWIGINTERNINLINE octave_value SWIG_From_dec(unsigned long long) (unsigned long long value) + { + return octave_uint64(value); + } } -%fragment(SWIG_AsVal_frag(unsigned long long), "header") -{ - SWIGINTERN int SWIG_AsVal_dec(unsigned long long)(const octave_value & ov, unsigned long long * val) { - if (!ov.is_scalar_type()) { - return SWIG_TypeError; - } - if (ov.is_complex_scalar()) { - return SWIG_TypeError; - } - if (ov.is_double_type() || ov.is_single_type()) { - double v = ov.double_value(); - if (v < 0) { - return SWIG_OverflowError; +%fragment(SWIG_AsVal_frag(unsigned long long),"header") { + SWIGINTERN int SWIG_AsVal_dec(unsigned long long)(const octave_value& ov, unsigned long long* val) + { + if (!ov.is_scalar_type()) + return SWIG_TypeError; + if (ov.is_complex_scalar()) + return SWIG_TypeError; + if (ov.is_double_type()||ov.is_single_type()) { + double v=ov.double_value(); + if (v<0) + return SWIG_OverflowError; + if (v!=floor(v)) + return SWIG_TypeError; } - if (v != floor(v)) { - return SWIG_TypeError; + if (ov.is_int8_type()||ov.is_int16_type()|| + ov.is_int32_type()) { + long v=ov.long_value(); + if (v<0) + return SWIG_OverflowError; } - } - if (ov.is_int8_type() || ov.is_int16_type() || - ov.is_int32_type()) { - long v = ov.long_value(); - if (v < 0) { - return SWIG_OverflowError; - } - } - if (ov.is_int64_type()) { - long long v = ov.int64_scalar_value().value(); - if (v < 0) { - return SWIG_OverflowError; - } - } - if (val) { if (ov.is_int64_type()) { - *val = ov.int64_scalar_value().value(); - } else if (ov.is_uint64_type()) { - *val = ov.uint64_scalar_value().value(); - } else { - *val = ov.long_value(); + long long v=ov.int64_scalar_value().value(); + if (v<0) + return SWIG_OverflowError; + } + if (val) { + if (ov.is_int64_type()) + *val = ov.int64_scalar_value().value(); + else if (ov.is_uint64_type()) + *val = ov.uint64_scalar_value().value(); + else + *val = ov.long_value(); } + return SWIG_OK; } - return SWIG_OK; - } } // double -%fragment(SWIG_From_frag(double), "header") -{ - SWIGINTERNINLINE octave_value SWIG_From_dec(double)(double value) { - return octave_value(value); - } +%fragment(SWIG_From_frag(double),"header") { + SWIGINTERNINLINE octave_value SWIG_From_dec(double) (double value) + { + return octave_value(value); + } } -%fragment(SWIG_AsVal_frag(double), "header") -{ - SWIGINTERN int SWIG_AsVal_dec(double)(const octave_value & ov, double * val) { - if (!ov.is_scalar_type()) { - return SWIG_TypeError; - } - if (ov.is_complex_scalar()) { - return SWIG_TypeError; - } - if (val) { - *val = ov.double_value(); +%fragment(SWIG_AsVal_frag(double),"header") { + SWIGINTERN int SWIG_AsVal_dec(double)(const octave_value& ov, double* val) + { + if (!ov.is_scalar_type()) + return SWIG_TypeError; + if (ov.is_complex_scalar()) + return SWIG_TypeError; + if (val) + *val = ov.double_value(); + return SWIG_OK; } - return SWIG_OK; - } } // const char* (strings) -%fragment("SWIG_AsCharPtrAndSize", "header") +%fragment("SWIG_AsCharPtrAndSize","header") { +SWIGINTERN int +SWIG_AsCharPtrAndSize(octave_value ov, char** cptr, size_t* psize, int *alloc) { - SWIGINTERN int - SWIG_AsCharPtrAndSize(octave_value ov, char** cptr, size_t * psize, int * alloc) { - if (ov.is_cell() && ov.rows() == 1 && ov.columns() == 1) { - ov = ov.cell_value()(0); - } - if (!ov.is_string()) { - return SWIG_TypeError; - } - - std::string str = ov.string_value(); - size_t len = str.size(); - char* cstr = (char*) str.c_str(); - if (alloc) { - *cptr = %new_copy_array(cstr, len + 1, char); - *alloc = SWIG_NEWOBJ; - } else if (cptr) { - *cptr = cstr; - } - if (psize) { - *psize = len + 1; - } - return SWIG_OK; - } + if (ov.is_cell() && ov.rows() == 1 && ov.columns() == 1) + ov = ov.cell_value()(0); + if (!ov.is_string()) + return SWIG_TypeError; + + std::string str=ov.string_value(); + size_t len=str.size(); + char* cstr=(char*)str.c_str(); + if (alloc) { + *cptr = %new_copy_array(cstr, len + 1, char); + *alloc = SWIG_NEWOBJ; + } else if (cptr) + *cptr = cstr; + if (psize) + *psize = len + 1; + return SWIG_OK; +} } -%fragment("SWIG_FromCharPtrAndSize", "header", fragment = "SWIG_pchar_descriptor") +%fragment("SWIG_FromCharPtrAndSize","header",fragment="SWIG_pchar_descriptor") { +SWIGINTERNINLINE octave_value +SWIG_FromCharPtrAndSize(const char* carray, size_t size) { - SWIGINTERNINLINE octave_value - SWIG_FromCharPtrAndSize(const char * carray, size_t size) { - return std::string(carray, carray + size); - } + return std::string(carray,carray+size); } +} + + diff --git a/Lib/octave/octrun.swg b/Lib/octave/octrun.swg new file mode 100644 index 000000000..dc9b6b6e6 --- /dev/null +++ b/Lib/octave/octrun.swg @@ -0,0 +1,1389 @@ + +#include + +// Macro for enabling features which require Octave version >= major.minor.patch +#define SWIG_OCTAVE_PREREQ(major, minor, patch) \ + ( (OCTAVE_MAJOR_VERSION<<16) + (OCTAVE_MINOR_VERSION<<8) + OCTAVE_PATCH_VERSION >= ((major)<<16) + ((minor)<<8) + (patch) ) + +// Reconstruct Octave major, minor, and patch versions for releases prior to 3.8.1 +#if !defined(OCTAVE_MAJOR_VERSION) + +# if !defined(OCTAVE_API_VERSION_NUMBER) + +// Hack to distinguish between Octave 3.8.0, which removed OCTAVE_API_VERSION_NUMBER but did not yet +// introduce OCTAVE_MAJOR_VERSION, and Octave <= 3.2, which did not define OCTAVE_API_VERSION_NUMBER +# include +# if defined(octave_ov_h) +# define OCTAVE_MAJOR_VERSION 3 +# define OCTAVE_MINOR_VERSION 8 +# define OCTAVE_PATCH_VERSION 0 +# else + +// Hack to distinguish between Octave 3.2 and earlier versions, before OCTAVE_API_VERSION_NUMBER existed +# define ComplexLU __ignore +# include +# undef ComplexLU +# if defined(octave_Complex_LU_h) + +// We know only that this version is prior to Octave 3.2, i.e. OCTAVE_API_VERSION_NUMBER < 37 +# define OCTAVE_MAJOR_VERSION 3 +# define OCTAVE_MINOR_VERSION 1 +# define OCTAVE_PATCH_VERSION 99 + +# else + +// OCTAVE_API_VERSION_NUMBER == 37 +# define OCTAVE_MAJOR_VERSION 3 +# define OCTAVE_MINOR_VERSION 2 +# define OCTAVE_PATCH_VERSION 0 + +# endif // defined(octave_Complex_LU_h) + +# endif // defined(octave_ov_h) + +// Correlation between Octave API and version numbers extracted from Octave's +// ChangeLogs; version is the *earliest* released Octave with that API number +# elif OCTAVE_API_VERSION_NUMBER >= 48 +# define OCTAVE_MAJOR_VERSION 3 +# define OCTAVE_MINOR_VERSION 6 +# define OCTAVE_PATCH_VERSION 0 + +# elif OCTAVE_API_VERSION_NUMBER >= 45 +# define OCTAVE_MAJOR_VERSION 3 +# define OCTAVE_MINOR_VERSION 4 +# define OCTAVE_PATCH_VERSION 1 + +# elif OCTAVE_API_VERSION_NUMBER >= 42 +# define OCTAVE_MAJOR_VERSION 3 +# define OCTAVE_MINOR_VERSION 3 +# define OCTAVE_PATCH_VERSION 54 + +# elif OCTAVE_API_VERSION_NUMBER >= 41 +# define OCTAVE_MAJOR_VERSION 3 +# define OCTAVE_MINOR_VERSION 3 +# define OCTAVE_PATCH_VERSION 53 + +# elif OCTAVE_API_VERSION_NUMBER >= 40 +# define OCTAVE_MAJOR_VERSION 3 +# define OCTAVE_MINOR_VERSION 3 +# define OCTAVE_PATCH_VERSION 52 + +# elif OCTAVE_API_VERSION_NUMBER >= 39 +# define OCTAVE_MAJOR_VERSION 3 +# define OCTAVE_MINOR_VERSION 3 +# define OCTAVE_PATCH_VERSION 51 + +# else // OCTAVE_API_VERSION_NUMBER == 38 +# define OCTAVE_MAJOR_VERSION 3 +# define OCTAVE_MINOR_VERSION 3 +# define OCTAVE_PATCH_VERSION 50 + +# endif // !defined(OCTAVE_API_VERSION_NUMBER) + +#endif // !defined(OCTAVE_MAJOR_VERSION) + +#if !SWIG_OCTAVE_PREREQ(3,2,0) +#define SWIG_DEFUN(cname, wname, doc) DEFUNX_DLD(#cname, wname, FS ## cname, args, nargout, doc) +#else +#define SWIG_DEFUN(cname, wname, doc) DEFUNX_DLD(#cname, wname, G ## cname, args, nargout, doc) +#endif + +SWIGRUNTIME bool SWIG_check_num_args(const char *func_name, int num_args, int max_args, int min_args, int varargs) { + if (num_args > max_args && !varargs) + error("function %s takes at most %i arguments", func_name, max_args); + else if (num_args < min_args) + error("function %s requires at least %i arguments", func_name, min_args); + else + return true; + return false; +} + +SWIGRUNTIME octave_value_list *SWIG_Octave_AppendOutput(octave_value_list *ovl, const octave_value &ov) { + ovl->append(ov); + return ovl; +} + +SWIGRUNTIME octave_value SWIG_ErrorType(int code) { + switch (code) { + case SWIG_MemoryError: + return "SWIG_MemoryError"; + case SWIG_IOError: + return "SWIG_IOError"; + case SWIG_RuntimeError: + return "SWIG_RuntimeError"; + case SWIG_IndexError: + return "SWIG_IndexError"; + case SWIG_TypeError: + return "SWIG_TypeError"; + case SWIG_DivisionByZero: + return "SWIG_DivisionByZero"; + case SWIG_OverflowError: + return "SWIG_OverflowError"; + case SWIG_SyntaxError: + return "SWIG_SyntaxError"; + case SWIG_ValueError: + return "SWIG_ValueError"; + case SWIG_SystemError: + return "SWIG_SystemError"; + case SWIG_AttributeError: + return "SWIG_AttributeError"; + } + return "SWIG unknown error"; +} + +SWIGRUNTIME octave_value SWIG_Error(int code, const char *msg) { + octave_value type(SWIG_ErrorType(code)); + std::string r = msg; + r += " (" + type.string_value() + ")"; + error(r.c_str()); + return octave_value(r); +} + +#define SWIG_fail goto fail + +#define SWIG_Octave_ConvertPtr(obj, pptr, type, flags) SWIG_Octave_ConvertPtrAndOwn(obj, pptr, type, flags, 0) +#define SWIG_ConvertPtr(obj, pptr, type, flags) SWIG_Octave_ConvertPtr(obj, pptr, type, flags) +#define SWIG_ConvertPtrAndOwn(obj,pptr,type,flags,own) SWIG_Octave_ConvertPtrAndOwn(obj, pptr, type, flags, own) +#define SWIG_ConvertPtr(obj, pptr, type, flags) SWIG_Octave_ConvertPtr(obj, pptr, type, flags) +#define SWIG_NewPointerObj(ptr, type, flags) SWIG_Octave_NewPointerObj(ptr, type, flags) +#define swig_owntype int + +#define SWIG_ConvertPacked(obj, ptr, sz, ty) SWIG_Octave_ConvertPacked(obj, ptr, sz, ty) +#define SWIG_NewPackedObj(ptr, sz, type) SWIG_Octave_NewPackedObj(ptr, sz, type) + +#define SWIG_ConvertFunctionPtr(obj, pptr, type) SWIG_ConvertPtr(obj, pptr, type, 0) +#define SWIG_NewFunctionPtrObj(ptr, type) SWIG_NewPointerObj(ptr, type, 0) + +#define SWIG_ConvertMember(obj, ptr, sz, ty) SWIG_Octave_ConvertPacked(obj, ptr, sz, ty) +#define SWIG_NewMemberObj(ptr, sz, type) SWIG_Octave_NewPackedObj(ptr, sz, type) + +#define SWIG_GetModule(clientdata) SWIG_Octave_GetModule(clientdata) +#define SWIG_SetModule(clientdata, pointer) SWIG_Octave_SetModule(clientdata,pointer); +#define SWIG_MODULE_CLIENTDATA_TYPE void* + +#define Octave_Error_Occurred() 0 +#define SWIG_Octave_AddErrorMsg(msg) {;} + +SWIGRUNTIME swig_module_info *SWIG_Octave_GetModule(void *clientdata); +SWIGRUNTIME void SWIG_Octave_SetModule(void *clientdata, swig_module_info *pointer); + +// For backward compatibility only +#define SWIG_POINTER_EXCEPTION 0 +#define SWIG_arg_fail(arg) 0 + +// Runtime API implementation + +#include +#include +#include + +typedef octave_value_list(*octave_func) (const octave_value_list &, int); +class octave_swig_type; + +namespace Swig { + +#ifdef SWIG_DIRECTORS + + class Director; + + typedef std::map < void *, Director * > rtdir_map; + SWIGINTERN rtdir_map* get_rtdir_map(); + SWIGINTERNINLINE void set_rtdir(void *vptr, Director *d); + SWIGINTERNINLINE void erase_rtdir(void *vptr); + SWIGINTERNINLINE Director *get_rtdir(void *vptr); + + SWIGRUNTIME void swig_director_destroyed(octave_swig_type *self, Director *d); + SWIGRUNTIME octave_swig_type *swig_director_get_self(Director *d); + SWIGRUNTIME void swig_director_set_self(Director *d, octave_swig_type *self); + +#endif + + SWIGRUNTIME octave_base_value *swig_value_ref(octave_swig_type *ost); + SWIGRUNTIME octave_swig_type *swig_value_deref(octave_value ov); + SWIGRUNTIME octave_swig_type *swig_value_deref(const octave_base_value &ov); +} + +#ifdef SWIG_DIRECTORS +SWIGRUNTIME void swig_acquire_ownership(void *vptr); +SWIGRUNTIME void swig_acquire_ownership_array(void *vptr); +SWIGRUNTIME void swig_acquire_ownership_obj(void *vptr, int own); +#endif + + struct swig_octave_member { + const char *name; + octave_func method; + octave_func get_method; + octave_func set_method; + int flags; // 1 static, 2 global + const char *doc; + bool is_static() const { + return flags &1; + } bool is_global() const { + return flags &2; + } + }; + + struct swig_octave_class { + const char *name; + swig_type_info **type; + int director; + octave_func constructor; + const char *constructor_doc; + octave_func destructor; + const swig_octave_member *members; + const char **base_names; + const swig_type_info **base; + }; + + // octave_swig_type plays the role of both the shadow class and the class + // representation within Octave, since there is no support for classes. + // + // These should really be decoupled, with the class support added to Octave + // and the shadow class given by an m-file script. That would dramatically + // reduce the runtime complexity, and be more in line w/ other modules. + + class octave_swig_type:public octave_base_value { + struct cpp_ptr { + void *ptr; + bool destroyed; + cpp_ptr(void *_ptr):ptr(_ptr), destroyed(false) { + }}; + typedef std::pair < const swig_type_info *, cpp_ptr > type_ptr_pair; + + mutable swig_module_info *module; + + const swig_type_info *construct_type; // type of special type object + std::vector < type_ptr_pair > types; // our c++ base classes + int own; // whether we call c++ destructors when we die + + typedef std::pair < const swig_octave_member *, octave_value > member_value_pair; + typedef std::map < std::string, member_value_pair > member_map; + member_map members; + bool always_static; + + const swig_octave_member *find_member(const swig_type_info *type, const std::string &name) { + if (!type->clientdata) + return 0; + swig_octave_class *c = (swig_octave_class *) type->clientdata; + const swig_octave_member *m; + for (m = c->members; m->name; ++m) + if (m->name == name) + return m; + for (int j = 0; c->base_names[j]; ++j) { + if (!c->base[j]) { + if (!module) + module = SWIG_GetModule(0); + assert(module); + c->base[j] = SWIG_MangledTypeQueryModule(module, module, c->base_names[j]); + } + if (!c->base[j]) + return 0; + if ((m = find_member(c->base[j], name))) + return m; + } + return 0; + } + + member_value_pair *find_member(const std::string &name, bool insert_if_not_found) { + member_map::iterator it = members.find(name); + if (it != members.end()) + return &it->second; + const swig_octave_member *m; + for (unsigned int j = 0; j < types.size(); ++j) + if ((m = find_member(types[j].first, name))) + return &members.insert(std::make_pair(name, std::make_pair(m, octave_value()))).first->second; + if (!insert_if_not_found) + return 0; + return &members[name]; + } + + const swig_type_info *find_base(const std::string &name, const swig_type_info *base) { + if (!base) { + for (unsigned int j = 0; j < types.size(); ++j) { + assert(types[j].first->clientdata); + swig_octave_class *cj = (swig_octave_class *) types[j].first->clientdata; + if (cj->name == name) + return types[j].first; + } + return 0; + } + assert(base->clientdata); + swig_octave_class *c = (swig_octave_class *) base->clientdata; + for (int j = 0; c->base_names[j]; ++j) { + if (!c->base[j]) { + if (!module) + module = SWIG_GetModule(0); + assert(module); + c->base[j] = SWIG_MangledTypeQueryModule(module, module, c->base_names[j]); + } + if (!c->base[j]) + return 0; + assert(c->base[j]->clientdata); + swig_octave_class *cj = (swig_octave_class *) c->base[j]->clientdata; + if (cj->name == name) + return c->base[j]; + } + return 0; + } + + void load_members(const swig_octave_class* c,member_map& out) const { + for (const swig_octave_member *m = c->members; m->name; ++m) { + if (out.find(m->name) == out.end()) + out.insert(std::make_pair(m->name, std::make_pair(m, octave_value()))); + } + for (int j = 0; c->base_names[j]; ++j) { + if (!c->base[j]) { + if (!module) + module = SWIG_GetModule(0); + assert(module); + c->base[j] = SWIG_MangledTypeQueryModule(module, module, c->base_names[j]); + } + if (!c->base[j]) + continue; + assert(c->base[j]->clientdata); + const swig_octave_class *cj = + (const swig_octave_class *) c->base[j]->clientdata; + load_members(cj,out); + } + } + + void load_members(member_map& out) const { + out=members; + for (unsigned int j = 0; j < types.size(); ++j) + if (types[j].first->clientdata) + load_members((const swig_octave_class *) types[j].first->clientdata, out); + } + + octave_value_list member_invoke(member_value_pair *m, const octave_value_list &args, int nargout) { + if (m->second.is_defined()) + return m->second.subsref("(", std::list < octave_value_list > (1, args), nargout); + else if (m->first && m->first->method) + return m->first->method(args, nargout); + error("member not defined or not invocable"); + return octave_value_list(); + } + + bool dispatch_unary_op(const std::string &symbol, octave_value &ret) { + member_value_pair *m = find_member(symbol, false); + if (!m || m->first->is_static() || m->first->is_global()) + return false; + octave_value_list args; + args.append(as_value()); + octave_value_list argout(member_invoke(m, args, 1)); + if (argout.length() < 1) + return false; + ret = argout(0); + return true; + } + + bool dispatch_binary_op(const std::string &symbol, const octave_base_value &rhs, octave_value &ret) { + member_value_pair *m = find_member(symbol, false); + if (!m || m->first->is_static() || m->first->is_global()) + return false; + octave_value_list args; + args.append(as_value()); + args.append(make_value_hack(rhs)); + octave_value_list argout(member_invoke(m, args, 1)); + if (argout.length() < 1) + return false; + ret = argout(0); + return true; + } + + bool dispatch_index_op(const std::string &symbol, const octave_value_list &rhs, octave_value_list &ret) { + member_value_pair *m = find_member(symbol, false); + if (!m || m->first->is_static() || m->first->is_global()) + return false; + octave_value_list args; + args.append(as_value()); + args.append(rhs); + octave_value_list argout(member_invoke(m, args, 1)); + if (argout.length() >= 1) + ret = argout(0); + return true; + } + + octave_value_list member_deref(member_value_pair *m, const octave_value_list &args) { + if (m->second.is_defined()) + return m->second; + else if (m->first) { + if (m->first->get_method) + return m->first->get_method(args, 1); + else if (m->first->method) + return octave_value(new octave_builtin(m->first->method)); + } + error("undefined member"); + return octave_value_list(); + } + + static octave_value make_value_hack(const octave_base_value &x) { + ((octave_swig_type &) x).count++; + return octave_value((octave_base_value *) &x); + } + + octave_swig_type(const octave_swig_type &x); + octave_swig_type &operator=(const octave_swig_type &rhs); + public: + + octave_swig_type(void *_ptr = 0, const swig_type_info *_type = 0, int _own = 0, + bool _always_static = false) + : module(0), construct_type(_ptr ? 0 : _type), own(_own), + always_static(_always_static) { + if (_type || _ptr) + types.push_back(std::make_pair(_type, _ptr)); +#ifdef SWIG_DIRECTORS + if (_ptr) { + Swig::Director *d = Swig::get_rtdir(_ptr); + if (d) + Swig::swig_director_set_self(d, this); + } +#endif + } + + ~octave_swig_type() { + if (own) { + ++count; + for (unsigned int j = 0; j < types.size(); ++j) { + if (!types[j].first || !types[j].first->clientdata) + continue; + swig_octave_class *c = (swig_octave_class *) types[j].first->clientdata; + if (c->destructor && !types[j].second.destroyed && types[j].second.ptr) { + c->destructor(as_value(), 0); + } + } + } +#ifdef SWIG_DIRECTORS + for (unsigned int j = 0; j < types.size(); ++j) + Swig::erase_rtdir(types[j].second.ptr); +#endif + } + + dim_vector dims(void) const { + octave_swig_type *nc_this = const_cast < octave_swig_type *>(this); + + // Find the __dims__ method of this object + member_value_pair *m = nc_this->find_member("__dims__", false); + + if (!m) return dim_vector(1,1); + + // Call the __dims__ method of this object + octave_value_list inarg; + inarg.append(nc_this->as_value()); + octave_value_list outarg = nc_this->member_invoke(m, inarg, 1); + + // __dims__ should return (at least) one output argument + if (outarg.length() < 1) return dim_vector(1,1); + + octave_value & out = outarg(0); + + // Return value should be cell or matrix of integers + if (out.is_cell()) { + const Cell & c=out.cell_value(); + int ndim = c.rows(); + if (ndim==1 && c.columns()!=1) ndim = c.columns(); + + dim_vector d; + d.resize(ndim < 2 ? 2 : ndim); + d(0) = d(1) = 1; + + // Fill in dim_vector + for (int k=0;k a = out.int_vector_value(); + if (error_state) return dim_vector(1,1); + dim_vector d; + d.resize(a.numel() < 2 ? 2 : a.numel()); + d(0) = d(1) = 1; + for (int k=0;kclientdata) + return 0; + swig_octave_class *c = (swig_octave_class *) types[0].first->clientdata; + return c->constructor_doc; + } + + std::string swig_type_name() const { + // * need some way to manually name subclasses. + // * eg optional first arg to subclass(), or named_subclass() + std::string ret; + for (unsigned int j = 0; j < types.size(); ++j) { + if (j) + ret += "_"; + if (types[j].first->clientdata) { + swig_octave_class *c = (swig_octave_class *) types[j].first->clientdata; + ret += c->name; + } else + ret += types[j].first->name; + } + return ret; + } + + void merge(octave_swig_type &rhs) { + rhs.own = 0; + for (unsigned int j = 0; j < rhs.types.size(); ++j) { + assert(!rhs.types[j].second.destroyed); +#ifdef SWIG_DIRECTORS + Swig::Director *d = Swig::get_rtdir(rhs.types[j].second.ptr); + if (d) + Swig::swig_director_set_self(d, this); +#endif + } + types.insert(types.end(), rhs.types.begin(), rhs.types.end()); + members.insert(rhs.members.begin(), rhs.members.end()); + rhs.types.clear(); + rhs.members.clear(); + } + + typedef member_map::const_iterator swig_member_const_iterator; + swig_member_const_iterator swig_members_begin() { return members.begin(); } + swig_member_const_iterator swig_members_end() { return members.end(); } + + void *cast(swig_type_info *type, int *_own, int flags) { + if (_own) + *_own = own; + if (flags &SWIG_POINTER_DISOWN) + own = 0; + if (!type && types.size()) + return types[0].second.ptr; + for (unsigned int j = 0; j < types.size(); ++j) + if (type == types[j].first) + return types[j].second.ptr; + for (unsigned int j = 0; j < types.size(); ++j) { + swig_cast_info *tc = SWIG_TypeCheck(types[j].first->name, type); + if (!tc) + continue; + int newmemory = 0; + void *vptr = SWIG_TypeCast(tc, types[j].second.ptr, &newmemory); + assert(!newmemory); // newmemory handling not yet implemented + return vptr; + } + return 0; + } + + bool is_owned() const { + return own; + } + +#ifdef SWIG_DIRECTORS + void director_destroyed(Swig::Director *d) { + bool found = false; + for (unsigned int j = 0; j < types.size(); ++j) { + Swig::Director *dj = Swig::get_rtdir(types[j].second.ptr); + if (dj == d) { + types[j].second.destroyed = true; + found = true; + } + } + assert(found); + } +#endif + + void assign(const std::string &name, const octave_value &ov) { + members[name] = std::make_pair((const swig_octave_member *) 0, ov); + } + + void assign(const std::string &name, const swig_octave_member *m) { + members[name] = std::make_pair(m, octave_value()); + } + + octave_base_value *clone() const { + // pass-by-value is probably not desired, and is harder; + // requires calling copy constructors of contained types etc. + assert(0); + *(int *) 0 = 0; + return 0; + } + + octave_base_value *empty_clone() const { + return new octave_swig_type(); + } + + bool is_defined() const { + return true; + } + + virtual bool is_map() const { + return true; + } + + virtual octave_value subsref(const std::string &ops, const std::list < octave_value_list > &idx) { + octave_value_list ovl = subsref(ops, idx, 1); + return ovl.length()? ovl(0) : octave_value(); + } + + virtual octave_value_list subsref(const std::string &ops, const std::list < octave_value_list > &idx, int nargout) { + assert(ops.size() > 0); + assert(ops.size() == idx.size()); + + std::list < octave_value_list >::const_iterator idx_it = idx.begin(); + int skip = 0; + octave_value_list sub_ovl; + + // constructor invocation + if (ops[skip] == '(' && construct_type) { + assert(construct_type->clientdata); + swig_octave_class *c = (swig_octave_class *) construct_type->clientdata; + if (!c->constructor) { + error("cannot create instance"); + return octave_value_list(); + } + octave_value_list args; + if (c->director) + args.append(Swig::swig_value_ref(new octave_swig_type(this, 0, 0))); + args.append(*idx_it++); + ++skip; + sub_ovl = c->constructor(args, nargout); + } + // member dereference or invocation + else if (ops[skip] == '.') { + std::string subname; + const swig_type_info *base = 0; // eg, a.base.base_cpp_mem + for (;;) { + octave_value_list subname_ovl(*idx_it++); + ++skip; + assert(subname_ovl.length() == 1 && subname_ovl(0).is_string()); + subname = subname_ovl(0).string_value(); + + const swig_type_info *next_base = find_base(subname, base); + if (!next_base || skip >= (int) ops.size() || ops[skip] != '.') + break; + base = next_base; + } + + member_value_pair tmp, *m = &tmp; + if (!base || !(m->first = find_member(base, subname))) + m = find_member(subname, false); + if (!m) { + error("member not found"); + return octave_value_list(); + } + + octave_value_list args; + if (!always_static && + (!m->first || (!m->first->is_static() && !m->first->is_global()))) + args.append(as_value()); + if (skip < (int) ops.size() && ops[skip] == '(' && + ((m->first && m->first->method) || m->second.is_function() || + m->second.is_function_handle())) { + args.append(*idx_it++); + ++skip; + sub_ovl = member_invoke(m, args, nargout); + } else { + sub_ovl = member_deref(m, args); + } + } + // index operator + else { + if (ops[skip] == '(' || ops[skip] == '{') { + const char *op_name = ops[skip] == '(' ? "__paren__" : "__brace__"; + octave_value_list args; + args.append(*idx_it++); + ++skip; + if (!dispatch_index_op(op_name, args, sub_ovl)) { + error("error evaluating index operator"); + return octave_value_list(); + } + } else { + error("unsupported subsref"); + return octave_value_list(); + } + } + + if (skip >= (int) ops.size()) + return sub_ovl; + if (sub_ovl.length() < 1) { + error("bad subs ref"); + return octave_value_list(); + } + return sub_ovl(0).next_subsref(nargout, ops, idx, skip); + } + + octave_value subsasgn(const std::string &ops, const std::list < octave_value_list > &idx, const octave_value &rhs) { + assert(ops.size() > 0); + assert(ops.size() == idx.size()); + + std::list < octave_value_list >::const_iterator idx_it = idx.begin(); + int skip = 0; + + if (ops.size() > 1) { + std::list < octave_value_list >::const_iterator last = idx.end(); + --last; + std::list < octave_value_list > next_idx(idx.begin(), last); + octave_value next_ov = subsref(ops.substr(0, ops.size() - 1), next_idx); + next_ov.subsasgn(ops.substr(ops.size() - 1), std::list < octave_value_list > (1, *last), rhs); + } + + else if (ops[skip] == '(' || ops[skip] == '{') { + const char *op_name = ops[skip] == '(' ? "__paren_asgn__" : "__brace_asgn__"; + member_value_pair *m = find_member(op_name, false); + if (m) { + octave_value_list args; + args.append(as_value()); + args.append(*idx_it); + args.append(rhs); + member_invoke(m, args, 1); + } else + error("%s member not found", op_name); + } + + else if (ops[skip] == '.') { + octave_value_list subname_ovl(*idx_it++); + ++skip; + assert(subname_ovl.length() == 1 &&subname_ovl(0).is_string()); + std::string subname = subname_ovl(0).string_value(); + + member_value_pair *m = find_member(subname, true); + if (!m->first || !m->first->set_method) { + m->first = 0; + m->second = rhs; + } else if (m->first->set_method) { + octave_value_list args; + if (!m->first->is_static() && !m->first->is_global()) + args.append(as_value()); + args.append(rhs); + m->first->set_method(args, 1); + } else + error("member not assignable"); + } else + error("unsupported subsasgn"); + + return as_value(); + } + + virtual bool is_object() const { + return true; + } + + virtual bool is_string() const { + octave_swig_type *nc_this = const_cast < octave_swig_type *>(this); + return !!nc_this->find_member("__str__", false); + } + + virtual std::string string_value(bool force = false) const { + octave_swig_type *nc_this = const_cast < octave_swig_type *>(this); + member_value_pair *m = nc_this->find_member("__str__", false); + if (!m) { + error("__str__ method not defined"); + return std::string(); + } + octave_value_list outarg = nc_this->member_invoke(m, octave_value_list(nc_this->as_value()), 1); + if (outarg.length() < 1 || !outarg(0).is_string()) { + error("__str__ method did not return a string"); + return std::string(); + } + return outarg(0).string_value(); + } + +#if SWIG_OCTAVE_PREREQ(3,3,52) + virtual octave_map map_value() const { + return octave_map(); + } +#else + virtual Octave_map map_value() const { + return Octave_map(); + } +#endif + + virtual string_vector map_keys() const { + member_map tmp; + load_members(tmp); + + string_vector keys(tmp.size()); + int k = 0; + for (member_map::iterator it = tmp.begin(); it != tmp.end(); ++it) + keys(k++) = it->first; + + return keys; + } + + virtual bool save_ascii (std::ostream& os) { + return true; + } + + virtual bool load_ascii (std::istream& is) { + return true; + } + + virtual bool save_binary (std::ostream& os, bool& save_as_floats) { + return true; + } + + virtual bool load_binary (std::istream& is, bool swap, + oct_mach_info::float_format fmt) { + return true; + } + +#if defined (HAVE_HDF5) + virtual bool + save_hdf5 (hid_t loc_id, const char *name, bool save_as_floats) { + return true; + } + + virtual bool + load_hdf5 (hid_t loc_id, const char *name, bool have_h5giterate_bug) { + return true; + } +#endif + + virtual octave_value convert_to_str(bool pad = false, bool force = false, char type = '"') const { + return string_value(); + } + + virtual octave_value convert_to_str_internal(bool pad, bool force, char type) const { + return string_value(); + } + + static bool dispatch_global_op(const std::string &symbol, const octave_value_list &args, octave_value &ret) { + // we assume that SWIG_op_prefix-prefixed functions are installed in global namespace + // (rather than any module namespace). + + octave_function *fcn = is_valid_function(symbol, std::string(), false); + if (!fcn) + return false; + ret = fcn->do_multi_index_op(1, args)(0); + return true; + } + + static octave_value dispatch_unary_op(const octave_base_value &x, const char *op_name) { + octave_swig_type *ost = Swig::swig_value_deref(x); + assert(ost); + + octave_value ret; + if (ost->dispatch_unary_op(std::string("__") + op_name + std::string("__"), ret)) + return ret; + std::string symbol = SWIG_op_prefix + ost->swig_type_name() + "_" + op_name; + octave_value_list args; + args.append(make_value_hack(x)); + if (dispatch_global_op(symbol, args, ret)) + return ret; + + error("could not dispatch unary operator"); + return octave_value(); + } + + static octave_value dispatch_binary_op(const octave_base_value &lhs, const octave_base_value &rhs, const char *op_name) { + octave_swig_type *lhs_ost = Swig::swig_value_deref(lhs); + octave_swig_type *rhs_ost = Swig::swig_value_deref(rhs); + + octave_value ret; + if (lhs_ost && lhs_ost->dispatch_binary_op(std::string("__") + op_name + std::string("__"), rhs, ret)) + return ret; + if (rhs_ost) { + if (strlen(op_name) == 2 && (op_name[1] == 't' || op_name[1] == 'e')) { + if (op_name[0] == 'l' && rhs_ost->dispatch_binary_op(std::string("__g") + op_name[1] + std::string("__"), lhs, ret)) + return ret; + if (op_name[0] == 'g' && rhs_ost->dispatch_binary_op(std::string("__l") + op_name[1] + std::string("__"), lhs, ret)) + return ret; + } + if (rhs_ost->dispatch_binary_op(std::string("__r") + op_name + std::string("__"), lhs, ret)) + return ret; + } + + std::string symbol; + octave_value_list args; + args.append(make_value_hack(lhs)); + args.append(make_value_hack(rhs)); + + symbol = SWIG_op_prefix; + symbol += lhs_ost ? lhs_ost->swig_type_name() : lhs.type_name(); + symbol += "_"; + symbol += op_name; + symbol += "_"; + symbol += rhs_ost ? rhs_ost->swig_type_name() : rhs.type_name(); + if (dispatch_global_op(symbol, args, ret)) + return ret; + + symbol = SWIG_op_prefix; + symbol += lhs_ost ? lhs_ost->swig_type_name() : lhs.type_name(); + symbol += "_"; + symbol += op_name; + symbol += "_"; + symbol += "any"; + if (dispatch_global_op(symbol, args, ret)) + return ret; + + symbol = SWIG_op_prefix; + symbol += "any"; + symbol += "_"; + symbol += op_name; + symbol += "_"; + symbol += rhs_ost ? rhs_ost->swig_type_name() : rhs.type_name(); + if (dispatch_global_op(symbol, args, ret)) + return ret; + + error("could not dispatch binary operator"); + return octave_value(); + } + + void print(std::ostream &os, bool pr_as_read_syntax = false) const { + if (is_string()) { + os << string_value(); + return; + } + + member_map tmp; + load_members(tmp); + + indent(os); + os << "{"; newline(os); + increment_indent_level(); + for (unsigned int j = 0; j < types.size(); ++j) { + indent(os); + if (types[j].first->clientdata) { + const swig_octave_class *c = (const swig_octave_class *) types[j].first->clientdata; + os << c->name << ", ptr = " << types[j].second.ptr; newline(os); + } else { + os << types[j].first->name << ", ptr = " << types[j].second.ptr; newline(os); + } + } + for (member_map::const_iterator it = tmp.begin(); it != tmp.end(); ++it) { + indent(os); + if (it->second.first) { + const char *objtype = it->second.first->method ? "method" : "variable"; + const char *modifier = (it->second.first->flags &1) ? "static " : (it->second.first->flags &2) ? "global " : ""; + os << it->second.first->name << " (" << modifier << objtype << ")"; newline(os); + assert(it->second.first->name == it->first); + } else { + os << it->first; newline(os); + } + } + decrement_indent_level(); + indent(os); + os << "}"; newline(os); + } + }; + + // Octave tries hard to preserve pass-by-value semantics. Eg, assignments + // will call clone() via make_unique() if there is more than one outstanding + // reference to the lhs, and forces the clone's reference count to 1 + // (so you can't just increment your own count and return this). + // + // One way to fix this (without modifying Octave) is to add a level of + // indirection such that clone copies ref-counted pointer and we keep + // pass-by-ref semantics (which are more natural/expected for C++ bindings). + // + // Supporting both pass-by-{ref,value} and toggling via %feature/option + // might be nice. + + class octave_swig_ref:public octave_base_value { + octave_swig_type *ptr; + public: + octave_swig_ref(octave_swig_type *_ptr = 0) + :ptr(_ptr) { } + + ~octave_swig_ref() + { if (ptr) ptr->decref(); } + + octave_swig_type *get_ptr() const + { return ptr; } + + octave_base_value *clone() const + { if (ptr) ptr->incref(); return new octave_swig_ref(ptr); } + + octave_base_value *empty_clone() const + { return new octave_swig_ref(0); } + + dim_vector dims(void) const + { return ptr->dims(); } + + bool is_defined() const + { return ptr->is_defined(); } + + virtual bool is_map() const + { return ptr->is_map(); } + + virtual octave_value subsref(const std::string &ops, const std::list < octave_value_list > &idx) + { return ptr->subsref(ops, idx); } + + virtual octave_value_list subsref(const std::string &ops, const std::list < octave_value_list > &idx, int nargout) + { return ptr->subsref(ops, idx, nargout); } + + octave_value subsasgn(const std::string &ops, const std::list < octave_value_list > &idx, const octave_value &rhs) + { return ptr->subsasgn(ops, idx, rhs); } + + virtual bool is_object() const + { return ptr->is_object(); } + + virtual bool is_string() const + { return ptr->is_string(); } + + virtual std::string string_value(bool force = false) const + { return ptr->string_value(force); } + +#if SWIG_OCTAVE_PREREQ(3,3,52) + virtual octave_map map_value() const + { return ptr->map_value(); } +#else + virtual Octave_map map_value() const + { return ptr->map_value(); } +#endif + + virtual string_vector map_keys() const + { return ptr->map_keys(); } + + virtual bool save_ascii (std::ostream& os) + { return ptr->save_ascii(os); } + + virtual bool load_ascii (std::istream& is) + { return ptr->load_ascii(is); } + + virtual bool save_binary (std::ostream& os, bool& save_as_floats) + { return ptr->save_binary(os, save_as_floats); } + + virtual bool load_binary (std::istream& is, bool swap, + oct_mach_info::float_format fmt) + { return ptr->load_binary(is, swap, fmt); } + +#if defined (HAVE_HDF5) + virtual bool + save_hdf5 (hid_t loc_id, const char *name, bool save_as_floats) + { return ptr->save_hdf5(loc_id, name, save_as_floats); } + + virtual bool + load_hdf5 (hid_t loc_id, const char *name, bool have_h5giterate_bug) + { return ptr->load_hdf5(loc_id, name, have_h5giterate_bug); } +#endif + + virtual octave_value convert_to_str(bool pad = false, bool force = false, char type = '"') const + { return ptr->convert_to_str(pad, force, type); } + + virtual octave_value convert_to_str_internal(bool pad, bool force, char type) const + { return ptr->convert_to_str_internal(pad, force, type); } + + void print(std::ostream &os, bool pr_as_read_syntax = false) const + { return ptr->print(os, pr_as_read_syntax); } + + private: + DECLARE_OCTAVE_ALLOCATOR; + DECLARE_OV_TYPEID_FUNCTIONS_AND_DATA; + }; + DEFINE_OCTAVE_ALLOCATOR(octave_swig_ref); + DEFINE_OV_TYPEID_FUNCTIONS_AND_DATA(octave_swig_ref, "swig_ref", "swig_ref"); + + class octave_swig_packed:public octave_base_value { + swig_type_info *type; + std::vector < char > buf; + public: + + octave_swig_packed(swig_type_info *_type = 0, const void *_buf = 0, size_t _buf_len = 0) + : type(_type), buf((const char*)_buf, (const char*)_buf + _buf_len) { + } + + bool copy(swig_type_info *outtype, void *ptr, size_t sz) const { + if (outtype && outtype != type) + return false; + assert(sz <= buf.size()); + std::copy(buf.begin(), buf.begin()+sz, (char*)ptr); + return true; + } + + octave_base_value *clone() const { + return new octave_swig_packed(*this); + } + + octave_base_value *empty_clone() const { + return new octave_swig_packed(); + } + + bool is_defined() const { + return true; + } + + void print(std::ostream &os, bool pr_as_read_syntax = false) const { + indent(os); + os << "swig packed type: name = " << (type ? type->name : std::string()) << ", len = " << buf.size(); newline(os); + } + + + virtual bool save_ascii (std::ostream& os) { + return true; + } + + virtual bool load_ascii (std::istream& is) { + return true; + } + + virtual bool save_binary (std::ostream& os, bool& save_as_floats) { + return true; + } + + virtual bool load_binary (std::istream& is, bool swap, + oct_mach_info::float_format fmt) { + return true; + } + +#if defined (HAVE_HDF5) + virtual bool + save_hdf5 (hid_t loc_id, const char *name, bool save_as_floats) { + return true; + } + + virtual bool + load_hdf5 (hid_t loc_id, const char *name, bool have_h5giterate_bug) { + return true; + } +#endif + + private: + DECLARE_OCTAVE_ALLOCATOR; + DECLARE_OV_TYPEID_FUNCTIONS_AND_DATA; + }; + DEFINE_OCTAVE_ALLOCATOR(octave_swig_packed); + DEFINE_OV_TYPEID_FUNCTIONS_AND_DATA(octave_swig_packed, "swig_packed", "swig_packed"); + + SWIGRUNTIME octave_value_list octave_set_immutable(const octave_value_list &args, int nargout) { + error("attempt to set immutable member variable"); + return octave_value_list(); + } + + struct octave_value_ref { + const octave_value_list &ovl; + int j; + + octave_value_ref(const octave_value_list &_ovl, int _j) + :ovl(_ovl), j(_j) { } + + operator octave_value() const { + return ovl(j); + } + + octave_value operator*() const { + return ovl(j); + } + }; + + +namespace Swig { + + SWIGRUNTIME octave_base_value *swig_value_ref(octave_swig_type *ost) { + return new octave_swig_ref(ost); + } + + SWIGRUNTIME octave_swig_type *swig_value_deref(octave_value ov) { + if (ov.is_cell() && ov.rows() == 1 && ov.columns() == 1) + ov = ov.cell_value()(0); + return swig_value_deref(*ov.internal_rep()); + } + + SWIGRUNTIME octave_swig_type *swig_value_deref(const octave_base_value &ov) { + if (ov.type_id() != octave_swig_ref::static_type_id()) + return 0; + const octave_swig_ref *osr = static_cast < const octave_swig_ref *>(&ov); + return osr->get_ptr(); + } + +} + + +#define swig_unary_op(name) \ +SWIGRUNTIME octave_value swig_unary_op_##name(const octave_base_value &x) { \ + return octave_swig_type::dispatch_unary_op(x,#name); \ +} +#define swig_binary_op(name) \ +SWIGRUNTIME octave_value swig_binary_op_##name(const octave_base_value&lhs,const octave_base_value &rhs) { \ + return octave_swig_type::dispatch_binary_op(lhs,rhs,#name); \ +} +#define swigreg_unary_op(name) \ +if (!octave_value_typeinfo::lookup_unary_op(octave_value::op_##name,tid)) \ +octave_value_typeinfo::register_unary_op(octave_value::op_##name,tid,swig_unary_op_##name); +#define swigreg_binary_op(name) \ +if (!octave_value_typeinfo::lookup_binary_op(octave_value::op_##name,tid1,tid2)) \ +octave_value_typeinfo::register_binary_op(octave_value::op_##name,tid1,tid2,swig_binary_op_##name); + + swig_unary_op(not); + swig_unary_op(uplus); + swig_unary_op(uminus); + swig_unary_op(transpose); + swig_unary_op(hermitian); + swig_unary_op(incr); + swig_unary_op(decr); + + swig_binary_op(add); + swig_binary_op(sub); + swig_binary_op(mul); + swig_binary_op(div); + swig_binary_op(pow); + swig_binary_op(ldiv); + swig_binary_op(lshift); + swig_binary_op(rshift); + swig_binary_op(lt); + swig_binary_op(le); + swig_binary_op(eq); + swig_binary_op(ge); + swig_binary_op(gt); + swig_binary_op(ne); + swig_binary_op(el_mul); + swig_binary_op(el_div); + swig_binary_op(el_pow); + swig_binary_op(el_ldiv); + swig_binary_op(el_and); + swig_binary_op(el_or); + + SWIGRUNTIME void SWIG_InstallUnaryOps(int tid) { + swigreg_unary_op(not); + swigreg_unary_op(uplus); + swigreg_unary_op(uminus); + swigreg_unary_op(transpose); + swigreg_unary_op(hermitian); + swigreg_unary_op(incr); + swigreg_unary_op(decr); + } + SWIGRUNTIME void SWIG_InstallBinaryOps(int tid1, int tid2) { + swigreg_binary_op(add); + swigreg_binary_op(sub); + swigreg_binary_op(mul); + swigreg_binary_op(div); + swigreg_binary_op(pow); + swigreg_binary_op(ldiv); + swigreg_binary_op(lshift); + swigreg_binary_op(rshift); + swigreg_binary_op(lt); + swigreg_binary_op(le); + swigreg_binary_op(eq); + swigreg_binary_op(ge); + swigreg_binary_op(gt); + swigreg_binary_op(ne); + swigreg_binary_op(el_mul); + swigreg_binary_op(el_div); + swigreg_binary_op(el_pow); + swigreg_binary_op(el_ldiv); + swigreg_binary_op(el_and); + swigreg_binary_op(el_or); + } + SWIGRUNTIME void SWIG_InstallOps(int tid) { + // here we assume that tid are conseq integers increasing from zero, and + // that our tid is the last one. might be better to have explicit string + // list of types we should bind to, and use lookup_type to resolve their tid. + + SWIG_InstallUnaryOps(tid); + SWIG_InstallBinaryOps(tid, tid); + for (int j = 0; j < tid; ++j) { + SWIG_InstallBinaryOps(j, tid); + SWIG_InstallBinaryOps(tid, j); + } + } + +SWIGRUNTIME octave_value SWIG_Octave_NewPointerObj(void *ptr, swig_type_info *type, int flags) { + int own = (flags &SWIG_POINTER_OWN) ? SWIG_POINTER_OWN : 0; + +#ifdef SWIG_DIRECTORS + Swig::Director *d = Swig::get_rtdir(ptr); + if (d && Swig::swig_director_get_self(d)) + return Swig::swig_director_get_self(d)->as_value(); +#endif + return Swig::swig_value_ref(new octave_swig_type(ptr, type, own)); +} + +SWIGRUNTIME int SWIG_Octave_ConvertPtrAndOwn(octave_value ov, void **ptr, swig_type_info *type, int flags, int *own) { + if (ov.is_cell() && ov.rows() == 1 && ov.columns() == 1) + ov = ov.cell_value()(0); + if (!ov.is_defined() || + (ov.is_matrix_type() && ov.rows() == 0 && ov.columns() == 0) ) { + if (ptr) + *ptr = 0; + return SWIG_OK; + } + if (ov.type_id() != octave_swig_ref::static_type_id()) + return SWIG_ERROR; + octave_swig_ref *osr = static_cast < octave_swig_ref *>(ov.internal_rep()); + octave_swig_type *ost = osr->get_ptr(); + void *vptr = ost->cast(type, own, flags); + if (!vptr) + return SWIG_ERROR; + if (ptr) + *ptr = vptr; + return SWIG_OK; +} + +SWIGRUNTIME octave_value SWIG_Octave_NewPackedObj(void *ptr, size_t sz, swig_type_info *type) { + return new octave_swig_packed(type, (char *) ptr, sz); +} + +SWIGRUNTIME int SWIG_Octave_ConvertPacked(const octave_value &ov, void *ptr, size_t sz, swig_type_info *type) { + if (!ov.is_defined()) + return SWIG_ERROR; + if (ov.type_id() != octave_swig_packed::static_type_id()) + return SWIG_ERROR; + octave_swig_packed *ost = static_cast < octave_swig_packed *>(ov.internal_rep()); + return ost->copy(type, (char *) ptr, sz) ? SWIG_OK : SWIG_ERROR; +} + +SWIGRUNTIMEINLINE void SWIG_Octave_SetConstant(octave_swig_type *module_ns, const std::string &name, const octave_value &ov) { + module_ns->assign(name, ov); +} + +SWIGRUNTIMEINLINE octave_value SWIG_Octave_GetGlobalValue(std::string name) { + return get_global_value(name, true); +} + +SWIGRUNTIME void SWIG_Octave_SetGlobalValue(std::string name, const octave_value& value) { + set_global_value(name, value); +} + +SWIGRUNTIME void SWIG_Octave_LinkGlobalValue(std::string name) { +#if !SWIG_OCTAVE_PREREQ(3,2,0) + link_to_global_variable(curr_sym_tab->lookup(name, true)); +#else +#if !SWIG_OCTAVE_PREREQ(3,8,0) + symbol_table::varref(name); +#endif + symbol_table::mark_global(name); +#endif +} + +SWIGRUNTIME swig_module_info *SWIG_Octave_GetModule(void *clientdata) { + octave_value ov = SWIG_Octave_GetGlobalValue("__SWIG_MODULE__" SWIG_TYPE_TABLE_NAME SWIG_RUNTIME_VERSION); + if (!ov.is_defined() || + ov.type_id() != octave_swig_packed::static_type_id()) + return 0; + const octave_swig_packed* osp = + static_cast < const octave_swig_packed *> (ov.internal_rep()); + swig_module_info *pointer = 0; + osp->copy(0, &pointer, sizeof(swig_module_info *)); + return pointer; +} + +SWIGRUNTIME void SWIG_Octave_SetModule(void *clientdata, swig_module_info *pointer) { + octave_value ov = new octave_swig_packed(0, &pointer, sizeof(swig_module_info *)); + SWIG_Octave_SetGlobalValue("__SWIG_MODULE__" SWIG_TYPE_TABLE_NAME SWIG_RUNTIME_VERSION, ov); +} diff --git a/Lib/octave/octrunclass.swg b/Lib/octave/octrunclass.swg deleted file mode 100644 index 2310a45b8..000000000 --- a/Lib/octave/octrunclass.swg +++ /dev/null @@ -1,1203 +0,0 @@ -// -// octrunclass.swg - Octave runtime classes -// - -////////// Octave class: SwigOctType ////////// - -const SwigOctMember* SwigOctType::find_member(const swig_type_info* type, const std::string& name) -{ - if (!type->clientdata) { - return 0; - } - SwigOctClass* c = (SwigOctClass*) type->clientdata; - const SwigOctMember* m; - for (m = c->members; m->name; ++m) - if (m->name == name) { - return m; - } - for (int j = 0; c->base_names[j]; ++j) { - if (!c->base[j]) { - if (!module) { - module = SWIG_GetModule(0); - } - assert(module); - c->base[j] = SWIG_MangledTypeQueryModule(module, module, c->base_names[j]); - } - if (!c->base[j]) { - return 0; - } - if ((m = find_member(c->base[j], name))) { - return m; - } - } - return 0; -} - -SwigOctType::member_value_pair* SwigOctType::find_member(const std::string& name, bool insert_if_not_found) -{ - member_map::iterator it = members.find(name); - if (it != members.end()) { - return &it->second; - } - const SwigOctMember* m; - for (unsigned int j = 0; j < types.size(); ++j) - if ((m = find_member(types[j].first, name))) { - return &members.insert(std::make_pair(name, std::make_pair(m, octave_value()))).first->second; - } - if (!insert_if_not_found) { - return 0; - } - return &members[name]; -} - -const swig_type_info* SwigOctType::find_base(const std::string& name, const swig_type_info* base) -{ - if (!base) { - for (unsigned int j = 0; j < types.size(); ++j) { - assert(types[j].first->clientdata); - SwigOctClass* cj = (SwigOctClass*) types[j].first->clientdata; - if (cj->name == name) { - return types[j].first; - } - } - return 0; - } - assert(base->clientdata); - SwigOctClass* c = (SwigOctClass*) base->clientdata; - for (int j = 0; c->base_names[j]; ++j) { - if (!c->base[j]) { - if (!module) { - module = SWIG_GetModule(0); - } - assert(module); - c->base[j] = SWIG_MangledTypeQueryModule(module, module, c->base_names[j]); - } - if (!c->base[j]) { - return 0; - } - assert(c->base[j]->clientdata); - SwigOctClass* cj = (SwigOctClass*) c->base[j]->clientdata; - if (cj->name == name) { - return c->base[j]; - } - } - return 0; -} - -void SwigOctType::load_members(const SwigOctClass* c, member_map& out) const -{ - for (const SwigOctMember* m = c->members; m->name; ++m) { - if (out.find(m->name) == out.end()) { - out.insert(std::make_pair(m->name, std::make_pair(m, octave_value()))); - } - } - for (int j = 0; c->base_names[j]; ++j) { - if (!c->base[j]) { - if (!module) { - module = SWIG_GetModule(0); - } - assert(module); - c->base[j] = SWIG_MangledTypeQueryModule(module, module, c->base_names[j]); - } - if (!c->base[j]) { - continue; - } - assert(c->base[j]->clientdata); - const SwigOctClass* cj = - (const SwigOctClass*) c->base[j]->clientdata; - load_members(cj, out); - } -} - -void SwigOctType::load_members(member_map& out) const -{ - out = members; - for (unsigned int j = 0; j < types.size(); ++j) - if (types[j].first->clientdata) { - load_members((const SwigOctClass*) types[j].first->clientdata, out); - } -} - -octave_value_list SwigOctType::member_invoke(member_value_pair* m, const octave_value_list& args, int nargout) -{ - if (m->second.is_defined()) { - return m->second.subsref("(", std::list < octave_value_list > (1, args), nargout); - } else if (m->first && m->first->method) { - return m->first->method(args, nargout); - } - error("member not defined or not invocable"); - return octave_value_list(); -} - -bool SwigOctType::dispatch_unary_op(const std::string& symbol, octave_value& ret) -{ - member_value_pair* m = find_member(symbol, false); - if (!m || m->first->is_static() || m->first->is_global()) { - return false; - } - octave_value_list args; - args.append(as_value()); - octave_value_list argout(member_invoke(m, args, 1)); - if (argout.length() < 1) { - return false; - } - ret = argout(0); - return true; -} - -bool SwigOctType::dispatch_binary_op(const std::string& symbol, const octave_base_value& rhs, octave_value& ret) -{ - member_value_pair* m = find_member(symbol, false); - if (!m || m->first->is_static() || m->first->is_global()) { - return false; - } - octave_value_list args; - args.append(as_value()); - args.append(make_value_hack(rhs)); - octave_value_list argout(member_invoke(m, args, 1)); - if (argout.length() < 1) { - return false; - } - ret = argout(0); - return true; -} - -bool SwigOctType::dispatch_index_op(const std::string& symbol, const octave_value_list& rhs, octave_value_list& ret) -{ - member_value_pair* m = find_member(symbol, false); - if (!m || m->first->is_static() || m->first->is_global()) { - return false; - } - octave_value_list args; - args.append(as_value()); - args.append(rhs); - octave_value_list argout(member_invoke(m, args, 1)); - if (argout.length() >= 1) { - ret = argout(0); - } - return true; -} - -octave_value_list SwigOctType::member_deref(member_value_pair* m, const octave_value_list& args) -{ - if (m->second.is_defined()) { - return m->second; - } else if (m->first) { - if (m->first->get_method) { - return m->first->get_method(args, 1); - } else if (m->first->method) { - return octave_value(new octave_builtin(m->first->method)); - } - } - error("undefined member"); - return octave_value_list(); -} - -octave_value SwigOctType::make_value_hack(const octave_base_value& x) -{ - ((SwigOctType&) x).count++; - return octave_value((octave_base_value*) &x); -} - -SwigOctType::SwigOctType(void* _ptr, const swig_type_info* _type, int _own, bool _always_static) - : module(0), construct_type(_ptr ? 0 : _type), own(_own), always_static(_always_static) -{ - if (_type || _ptr) { - types.push_back(std::make_pair(_type, _ptr)); - } -#ifdef SWIG_DIRECTORS - if (_ptr) { - Swig::Director* d = Swig::get_rtdir(_ptr); - if (d) { - Swig::swig_director_set_self(d, this); - } - } -#endif -} - -SwigOctType::~SwigOctType() -{ - if (own) { - ++count; - for (unsigned int j = 0; j < types.size(); ++j) { - if (!types[j].first || !types[j].first->clientdata) { - continue; - } - SwigOctClass* c = (SwigOctClass*) types[j].first->clientdata; - if (c->destructor && !types[j].second.destroyed && types[j].second.ptr) { - c->destructor(as_value(), 0); - } - } - } -#ifdef SWIG_DIRECTORS - for (unsigned int j = 0; j < types.size(); ++j) { - Swig::erase_rtdir(types[j].second.ptr); - } -#endif -} - -dim_vector SwigOctType::dims(void) const -{ - SwigOctType* nc_this = const_cast < SwigOctType*>(this); - - // Find the __dims__ method of this object - member_value_pair* m = nc_this->find_member("__dims__", false); - - if (!m) { - return dim_vector(1, 1); - } - - // Call the __dims__ method of this object - octave_value_list inarg; - inarg.append(nc_this->as_value()); - octave_value_list outarg = nc_this->member_invoke(m, inarg, 1); - - // __dims__ should return (at least) one output argument - if (outarg.length() < 1) { - return dim_vector(1, 1); - } - - octave_value& out = outarg(0); - - // Return value should be cell or matrix of integers - if (out.is_cell()) { - const Cell& c = out.cell_value(); - int ndim = c.rows(); - if (ndim == 1 && c.columns() != 1) { - ndim = c.columns(); - } - - dim_vector d; - d.resize(ndim < 2 ? 2 : ndim); - d(0) = d(1) = 1; - - // Fill in dim_vector - for (int k = 0; k < ndim; k++) { - const octave_value& obj = c(k); - d.elem(k) = obj.int_value(); - - // __dims__ should return a cell filled with integers - if (error_state) { - return dim_vector(1, 1); - } - } - return d; - } else if (out.is_matrix_type() || out.is_numeric_type()) { - if (out.rows() == 1 || out.columns() == 1) { - Array a = out.int_vector_value(); - if (error_state) { - return dim_vector(1, 1); - } - dim_vector d; - d.resize(a.numel() < 2 ? 2 : a.numel()); - d(0) = d(1) = 1; - for (int k = 0; k < a.numel(); k++) { - d.elem(k) = a(k); - } - return d; - } else { - return dim_vector(1, 1); - } - } else { - return dim_vector(1, 1); - } -} - -octave_value SwigOctType::as_value() -{ - ++count; - return SWIG_Octave_ValueRef(this); -} - -void SwigOctType::incref() -{ - ++count; -} - -void SwigOctType::decref() -{ - if (!--count) { - delete this; - } -} - -long SwigOctType::swig_this() const -{ - if (!types.size()) { - return (long) this; - } - return (long) types[0].second.ptr; -} - -const char* SwigOctType::help_text() const -{ - if (!types.size()) { - return 0; - } - if (!types[0].first->clientdata) { - return 0; - } - SwigOctClass* c = (SwigOctClass*) types[0].first->clientdata; - return c->constructor_doc; -} - -std::string SwigOctType::swig_type_name() const -{ - // * need some way to manually name subclasses. - // * eg optional first arg to subclass(), or named_subclass() - std::string ret; - for (unsigned int j = 0; j < types.size(); ++j) { - if (j) { - ret += "_"; - } - if (types[j].first->clientdata) { - SwigOctClass* c = (SwigOctClass*) types[j].first->clientdata; - ret += c->name; - } else { - ret += types[j].first->name; - } - } - return ret; -} - -void SwigOctType::merge(SwigOctType& rhs) -{ - rhs.own = 0; - for (unsigned int j = 0; j < rhs.types.size(); ++j) { - assert(!rhs.types[j].second.destroyed); -#ifdef SWIG_DIRECTORS - Swig::Director* d = Swig::get_rtdir(rhs.types[j].second.ptr); - if (d) { - Swig::swig_director_set_self(d, this); - } -#endif - } - types.insert(types.end(), rhs.types.begin(), rhs.types.end()); - members.insert(rhs.members.begin(), rhs.members.end()); - rhs.types.clear(); - rhs.members.clear(); -} - -SwigOctType::swig_member_const_iterator SwigOctType::swig_members_begin() -{ - return members.begin(); -} - -SwigOctType::swig_member_const_iterator SwigOctType::swig_members_end() -{ - return members.end(); -} - -void* SwigOctType::cast(swig_type_info* type, int* _own, int flags) -{ - if (_own) { - *_own = own; - } - if (flags & SWIG_POINTER_DISOWN) { - own = 0; - } - if (!type && types.size()) { - return types[0].second.ptr; - } - for (unsigned int j = 0; j < types.size(); ++j) - if (type == types[j].first) { - return types[j].second.ptr; - } - for (unsigned int j = 0; j < types.size(); ++j) { - swig_cast_info* tc = SWIG_TypeCheck(types[j].first->name, type); - if (!tc) { - continue; - } - int newmemory = 0; - void* vptr = SWIG_TypeCast(tc, types[j].second.ptr, &newmemory); - assert(!newmemory); // newmemory handling not yet implemented - return vptr; - } - return 0; -} - -bool SwigOctType::is_owned() const -{ - return own; -} - -#ifdef SWIG_DIRECTORS -void SwigOctType::director_destroyed(Swig::Director* d) -{ - bool found = false; - for (unsigned int j = 0; j < types.size(); ++j) { - Swig::Director* dj = Swig::get_rtdir(types[j].second.ptr); - if (dj == d) { - types[j].second.destroyed = true; - found = true; - } - } - assert(found); -} -#endif - -void SwigOctType::assign(const std::string& name, const octave_value& ov) -{ - members[name] = std::make_pair((const SwigOctMember*) 0, ov); -} - -void SwigOctType::assign(const std::string& name, const SwigOctMember* m) -{ - members[name] = std::make_pair(m, octave_value()); -} - -octave_base_value* SwigOctType::clone() const -{ - // pass-by-value is probably not desired, and is harder; - // requires calling copy constructors of contained types etc. - assert(0); - * (int*) 0 = 0; - return 0; -} - -octave_base_value* SwigOctType::empty_clone() const -{ - return new SwigOctType(); -} - -bool SwigOctType::is_defined() const -{ - return true; -} - -bool SwigOctType::is_map() const -{ - return true; -} - -octave_value SwigOctType::subsref(const std::string& ops, const std::list < octave_value_list > &idx) -{ - octave_value_list ovl = subsref(ops, idx, 1); - return ovl.length() ? ovl(0) : octave_value(); -} - -octave_value_list SwigOctType::subsref(const std::string& ops, const std::list < octave_value_list > &idx, int nargout) -{ - assert(ops.size() > 0); - assert(ops.size() == idx.size()); - - std::list < octave_value_list >::const_iterator idx_it = idx.begin(); - int skip = 0; - octave_value_list sub_ovl; - - // constructor invocation - if (ops[skip] == '(' && construct_type) { - assert(construct_type->clientdata); - SwigOctClass* c = (SwigOctClass*) construct_type->clientdata; - if (!c->constructor) { - error("cannot create instance"); - return octave_value_list(); - } - octave_value_list args; - if (c->director) { - args.append(SWIG_Octave_ValueRef(new SwigOctType(this, 0, 0))); - } - args.append(*idx_it++); - ++skip; - sub_ovl = c->constructor(args, nargout); - } - // member dereference or invocation - else if (ops[skip] == '.') { - std::string subname; - const swig_type_info* base = 0; // eg, a.base.base_cpp_mem - for (;;) { - octave_value_list subname_ovl(*idx_it++); - ++skip; - assert(subname_ovl.length() == 1 && subname_ovl(0).is_string()); - subname = subname_ovl(0).string_value(); - - const swig_type_info* next_base = find_base(subname, base); - if (!next_base || skip >= (int) ops.size() || ops[skip] != '.') { - break; - } - base = next_base; - } - - member_value_pair tmp, *m = &tmp; - if (!base || !(m->first = find_member(base, subname))) { - m = find_member(subname, false); - } - if (!m) { - error("member not found"); - return octave_value_list(); - } - - octave_value_list args; - if (!always_static && - (!m->first || (!m->first->is_static() && !m->first->is_global()))) { - args.append(as_value()); - } - if (skip < (int) ops.size() && ops[skip] == '(' && - ((m->first && m->first->method) || m->second.is_function() || - m->second.is_function_handle())) { - args.append(*idx_it++); - ++skip; - sub_ovl = member_invoke(m, args, nargout); - } else { - sub_ovl = member_deref(m, args); - } - } - // index operator - else { - if (ops[skip] == '(' || ops[skip] == '{') { - const char* op_name = ops[skip] == '(' ? "__paren__" : "__brace__"; - octave_value_list args; - args.append(*idx_it++); - ++skip; - if (!dispatch_index_op(op_name, args, sub_ovl)) { - error("error evaluating index operator"); - return octave_value_list(); - } - } else { - error("unsupported subsref"); - return octave_value_list(); - } - } - - if (skip >= (int) ops.size()) { - return sub_ovl; - } - if (sub_ovl.length() < 1) { - error("bad subs ref"); - return octave_value_list(); - } - return sub_ovl(0).next_subsref(nargout, ops, idx, skip); -} - -octave_value SwigOctType::subsasgn(const std::string& ops, const std::list < octave_value_list > &idx, const octave_value& rhs) -{ - assert(ops.size() > 0); - assert(ops.size() == idx.size()); - - std::list < octave_value_list >::const_iterator idx_it = idx.begin(); - int skip = 0; - - if (ops.size() > 1) { - std::list < octave_value_list >::const_iterator last = idx.end(); - --last; - std::list < octave_value_list > next_idx(idx.begin(), last); - octave_value next_ov = subsref(ops.substr(0, ops.size() - 1), next_idx); - next_ov.subsasgn(ops.substr(ops.size() - 1), std::list < octave_value_list > (1, *last), rhs); - } - - else if (ops[skip] == '(' || ops[skip] == '{') { - const char* op_name = ops[skip] == '(' ? "__paren_asgn__" : "__brace_asgn__"; - member_value_pair* m = find_member(op_name, false); - if (m) { - octave_value_list args; - args.append(as_value()); - args.append(*idx_it); - args.append(rhs); - member_invoke(m, args, 1); - } else { - error("%s member not found", op_name); - } - } - - else if (ops[skip] == '.') { - octave_value_list subname_ovl(*idx_it++); - ++skip; - assert(subname_ovl.length() == 1 && subname_ovl(0).is_string()); - std::string subname = subname_ovl(0).string_value(); - - member_value_pair* m = find_member(subname, true); - if (!m->first || !m->first->set_method) { - m->first = 0; - m->second = rhs; - } else if (m->first->set_method) { - octave_value_list args; - if (!m->first->is_static() && !m->first->is_global()) { - args.append(as_value()); - } - args.append(rhs); - m->first->set_method(args, 1); - } else { - error("member not assignable"); - } - } else { - error("unsupported subsasgn"); - } - - return as_value(); -} - -bool SwigOctType::is_object() const -{ - return true; -} - -bool SwigOctType::is_string() const -{ - SwigOctType* nc_this = const_cast < SwigOctType*>(this); - return !!nc_this->find_member("__str__", false); -} - -std::string SwigOctType::string_value(bool force) const -{ - SwigOctType* nc_this = const_cast < SwigOctType*>(this); - member_value_pair* m = nc_this->find_member("__str__", false); - if (!m) { - error("__str__ method not defined"); - return std::string(); - } - octave_value_list outarg = nc_this->member_invoke(m, octave_value_list(nc_this->as_value()), 1); - if (outarg.length() < 1 || !outarg(0).is_string()) { - error("__str__ method did not return a string"); - return std::string(); - } - return outarg(0).string_value(); -} - -octave_map SwigOctType::map_value() const -{ - return octave_map(); -} - -string_vector SwigOctType::map_keys() const -{ - member_map tmp; - load_members(tmp); - - string_vector keys(tmp.size()); - int k = 0; - for (member_map::iterator it = tmp.begin(); it != tmp.end(); ++it) { - keys(k++) = it->first; - } - - return keys; -} - -bool SwigOctType::save_ascii(std::ostream& os) -{ - return true; -} - -bool SwigOctType::load_ascii(std::istream& is) -{ - return true; -} - -bool SwigOctType::save_binary(std::ostream& os, bool& save_as_floats) -{ - return true; -} - -bool SwigOctType::load_binary(std::istream& is, bool swap, oct_mach_info::float_format fmt) -{ - return true; -} - -#ifdef HAVE_HDF5 -bool SwigOctType::save_hdf5(hid_t loc_id, const char* name, bool save_as_floats) -{ - return true; -} - -bool SwigOctType::load_hdf5(hid_t loc_id, const char* name, bool have_h5giterate_bug) -{ - return true; -} -#endif - -octave_value SwigOctType::convert_to_str(bool pad, bool force, char type) const -{ - return string_value(); -} - -octave_value SwigOctType::convert_to_str_internal(bool pad, bool force, char type) const -{ - return string_value(); -} - -bool SwigOctType::dispatch_global_op(const std::string& symbol, const octave_value_list& args, octave_value& ret) -{ - // we assume that SWIG_op_prefix-prefixed functions are installed in global namespace - // (rather than any module namespace). - - octave_function* fcn = is_valid_function(symbol, std::string(), false); - if (!fcn) { - return false; - } - ret = fcn->do_multi_index_op(1, args)(0); - return true; -} - -octave_value SwigOctType::dispatch_unary_op(const octave_base_value& x, const char* op_name) -{ - SwigOctType* ost = SWIG_Octave_ValueDeref(x); - assert(ost); - - octave_value ret; - if (ost->dispatch_unary_op(std::string("__") + op_name + std::string("__"), ret)) { - return ret; - } - std::string symbol = SWIG_op_prefix + ost->swig_type_name() + "_" + op_name; - octave_value_list args; - args.append(make_value_hack(x)); - if (dispatch_global_op(symbol, args, ret)) { - return ret; - } - - error("could not dispatch unary operator"); - return octave_value(); -} - -octave_value SwigOctType::dispatch_binary_op(const octave_base_value& lhs, const octave_base_value& rhs, const char* op_name) -{ - SwigOctType* lhs_ost = SWIG_Octave_ValueDeref(lhs); - SwigOctType* rhs_ost = SWIG_Octave_ValueDeref(rhs); - - octave_value ret; - if (lhs_ost && lhs_ost->dispatch_binary_op(std::string("__") + op_name + std::string("__"), rhs, ret)) { - return ret; - } - if (rhs_ost) { - if (strlen(op_name) == 2 && (op_name[1] == 't' || op_name[1] == 'e')) { - if (op_name[0] == 'l' && rhs_ost->dispatch_binary_op(std::string("__g") + op_name[1] + std::string("__"), lhs, ret)) { - return ret; - } - if (op_name[0] == 'g' && rhs_ost->dispatch_binary_op(std::string("__l") + op_name[1] + std::string("__"), lhs, ret)) { - return ret; - } - } - if (rhs_ost->dispatch_binary_op(std::string("__r") + op_name + std::string("__"), lhs, ret)) { - return ret; - } - } - - std::string symbol; - octave_value_list args; - args.append(make_value_hack(lhs)); - args.append(make_value_hack(rhs)); - - symbol = SWIG_op_prefix; - symbol += lhs_ost ? lhs_ost->swig_type_name() : lhs.type_name(); - symbol += "_"; - symbol += op_name; - symbol += "_"; - symbol += rhs_ost ? rhs_ost->swig_type_name() : rhs.type_name(); - if (dispatch_global_op(symbol, args, ret)) { - return ret; - } - - symbol = SWIG_op_prefix; - symbol += lhs_ost ? lhs_ost->swig_type_name() : lhs.type_name(); - symbol += "_"; - symbol += op_name; - symbol += "_"; - symbol += "any"; - if (dispatch_global_op(symbol, args, ret)) { - return ret; - } - - symbol = SWIG_op_prefix; - symbol += "any"; - symbol += "_"; - symbol += op_name; - symbol += "_"; - symbol += rhs_ost ? rhs_ost->swig_type_name() : rhs.type_name(); - if (dispatch_global_op(symbol, args, ret)) { - return ret; - } - - error("could not dispatch binary operator"); - return octave_value(); -} - -void SwigOctType::print(std::ostream& os, bool pr_as_read_syntax) const -{ - if (is_string()) { - os << string_value(); - return; - } - - member_map tmp; - load_members(tmp); - - indent(os); - os << "{"; - newline(os); - increment_indent_level(); - for (unsigned int j = 0; j < types.size(); ++j) { - indent(os); - if (types[j].first->clientdata) { - const SwigOctClass* c = (const SwigOctClass*) types[j].first->clientdata; - os << c->name << ", ptr = " << types[j].second.ptr; - newline(os); - } else { - os << types[j].first->name << ", ptr = " << types[j].second.ptr; - newline(os); - } - } - for (member_map::const_iterator it = tmp.begin(); it != tmp.end(); ++it) { - indent(os); - if (it->second.first) { - const char* objtype = it->second.first->method ? "method" : "variable"; - const char* modifier = (it->second.first->flags & 1) ? "static " : (it->second.first->flags & 2) ? "global " : ""; - os << it->second.first->name << " (" << modifier << objtype << ")"; - newline(os); - assert(it->second.first->name == it->first); - } else { - os << it->first; - newline(os); - } - } - decrement_indent_level(); - indent(os); - os << "}"; - newline(os); -} - -////////// Octave class: SwigOctRef ////////// - -DEFINE_OCTAVE_ALLOCATOR(SwigOctRef); -DEFINE_OV_TYPEID_FUNCTIONS_AND_DATA(SwigOctRef, "swig_ref", "swig_ref"); - -SwigOctRef::SwigOctRef(SwigOctType* _ptr) - : ptr(_ptr) -{ } - -SwigOctRef::~SwigOctRef() -{ - if (ptr) { - ptr->decref(); - } -} - -SwigOctType* SwigOctRef::get_ptr() const -{ - return ptr; -} - -octave_base_value* SwigOctRef::clone() const -{ - if (ptr) { - ptr->incref(); - } - return new SwigOctRef(ptr); -} - -octave_base_value* SwigOctRef::empty_clone() const -{ - return new SwigOctRef(0); -} - -dim_vector SwigOctRef::dims(void) const -{ - return ptr->dims(); -} - -bool SwigOctRef::is_defined() const -{ - return ptr->is_defined(); -} - -bool SwigOctRef::is_map() const -{ - return ptr->is_map(); -} - -octave_value SwigOctRef::subsref(const std::string& ops, const std::list < octave_value_list > &idx) -{ - return ptr->subsref(ops, idx); -} - -octave_value_list SwigOctRef::subsref(const std::string& ops, const std::list < octave_value_list > &idx, int nargout) -{ - return ptr->subsref(ops, idx, nargout); -} - -octave_value SwigOctRef::subsasgn(const std::string& ops, const std::list < octave_value_list > &idx, const octave_value& rhs) -{ - return ptr->subsasgn(ops, idx, rhs); -} - -bool SwigOctRef::is_object() const -{ - return ptr->is_object(); -} - -bool SwigOctRef::is_string() const -{ - return ptr->is_string(); -} - -std::string SwigOctRef::string_value(bool force) const -{ - return ptr->string_value(force); -} - -octave_map SwigOctRef::map_value() const -{ - return ptr->map_value(); -} - -string_vector SwigOctRef::map_keys() const -{ - return ptr->map_keys(); -} - -bool SwigOctRef::save_ascii(std::ostream& os) -{ - return ptr->save_ascii(os); -} - -bool SwigOctRef::load_ascii(std::istream& is) -{ - return ptr->load_ascii(is); -} - -bool SwigOctRef::save_binary(std::ostream& os, bool& save_as_floats) -{ - return ptr->save_binary(os, save_as_floats); -} - -bool SwigOctRef::load_binary(std::istream& is, bool swap, oct_mach_info::float_format fmt) -{ - return ptr->load_binary(is, swap, fmt); -} - -#ifdef HAVE_HDF5 -bool SwigOctRef::save_hdf5(hid_t loc_id, const char* name, bool save_as_floats) -{ - return ptr->save_hdf5(loc_id, name, save_as_floats); -} - -bool SwigOctRef::load_hdf5(hid_t loc_id, const char* name, bool have_h5giterate_bug) -{ - return ptr->load_hdf5(loc_id, name, have_h5giterate_bug); -} -#endif - -octave_value SwigOctRef::convert_to_str(bool pad, bool force, char type) const -{ - return ptr->convert_to_str(pad, force, type); -} - -octave_value SwigOctRef::convert_to_str_internal(bool pad, bool force, char type) const -{ - return ptr->convert_to_str_internal(pad, force, type); -} - -void SwigOctRef::print(std::ostream& os, bool pr_as_read_syntax) const -{ - return ptr->print(os, pr_as_read_syntax); -} - -////////// Octave class: SwigOctPacked ////////// - -DEFINE_OCTAVE_ALLOCATOR(SwigOctPacked); -DEFINE_OV_TYPEID_FUNCTIONS_AND_DATA(SwigOctPacked, "swig_packed", "swig_packed"); - -SwigOctPacked::SwigOctPacked(swig_type_info* _type, const void* _buf, size_t _buf_len) - : type(_type), buf((const char*) _buf, (const char*) _buf + _buf_len) -{ } - -bool SwigOctPacked::copy(swig_type_info* outtype, void* ptr, size_t sz) const -{ - if (outtype && outtype != type) { - return false; - } - assert(sz <= buf.size()); - std::copy(buf.begin(), buf.begin() + sz, (char*) ptr); - return true; -} - -octave_base_value* SwigOctPacked::clone() const -{ - return new SwigOctPacked(*this); -} - -octave_base_value* SwigOctPacked::empty_clone() const -{ - return new SwigOctPacked(); -} - -bool SwigOctPacked::is_defined() const -{ - return true; -} - -void SwigOctPacked::print(std::ostream& os, bool pr_as_read_syntax) const -{ - indent(os); - os << "swig packed type: name = " << (type ? type->name : std::string()) << ", len = " << buf.size(); - newline(os); -} - -bool SwigOctPacked::save_ascii(std::ostream& os) -{ - return true; -} - -bool SwigOctPacked::load_ascii(std::istream& is) -{ - return true; -} - -bool SwigOctPacked::save_binary(std::ostream& os, bool& save_as_floats) -{ - return true; -} - -bool SwigOctPacked::load_binary(std::istream& is, bool swap, oct_mach_info::float_format fmt) -{ - return true; -} - -#ifdef HAVE_HDF5 -bool SwigOctPacked::save_hdf5(hid_t loc_id, const char* name, bool save_as_floats) -{ - return true; -} - -bool SwigOctPacked::load_hdf5(hid_t loc_id, const char* name, bool have_h5giterate_bug) -{ - return true; -} -#endif - -////////// Octave class: Swig::Director and related classes ////////// - -#ifdef SWIG_DIRECTORS - -#include - -Swig::Director::Director(void* vptr) : self(0), swig_disowned(false) -{ - set_rtdir(vptr, this); -} - -Swig::Director::~Director() -{ - swig_director_destroyed(self, this); - if (swig_disowned) { - self->decref(); - } -} - -void Swig::Director::swig_set_self(SwigOctType* new_self) -{ - assert(!swig_disowned); - self = new_self; -} - -SwigOctType* Swig::Director::swig_get_self() const -{ - return self; -} - -void Swig::Director::swig_disown() -{ - if (swig_disowned) { - return; - } - swig_disowned = true; - self->incref(); -} - -void Swig::DirectorTypeMismatchException::raise(const char* msg) -{ - // ... todo - throw(DirectorTypeMismatchException()); -} - -void Swig::DirectorTypeMismatchException::raise(const octave_value& ov, const char* msg) -{ - // ... todo - raise(msg); -} - -void Swig::DirectorPureVirtualException::raise(const char* msg) -{ - // ... todo - throw(DirectorPureVirtualException()); -} - -void Swig::DirectorPureVirtualException::raise(const octave_value& ov, const char* msg) -{ - // ... todo - raise(msg); -} - -SWIGOCTRT Swig::rtdir_map* Swig::get_rtdir_map() -{ - static swig_module_info* module = 0; - if (!module) { - module = SWIG_GetModule(0); - } - if (!module) { - return 0; - } - if (!module->clientdata) { - module->clientdata = new rtdir_map; - } - return (rtdir_map*) module->clientdata; -} - -SWIGOCTRTINLINE void Swig::set_rtdir(void* vptr, Director* d) -{ - rtdir_map* rm = get_rtdir_map(); - if (rm) { - (*rm) [vptr] = d; - } -} - -SWIGOCTRTINLINE void Swig::erase_rtdir(void* vptr) -{ - rtdir_map* rm = get_rtdir_map(); - if (rm) { - (*rm).erase(vptr); - } -} - -SWIGOCTRTINLINE Swig::Director* Swig::get_rtdir(void* vptr) -{ - rtdir_map* rm = get_rtdir_map(); - if (!rm) { - return 0; - } - rtdir_map::const_iterator pos = rm->find(vptr); - Director* rtdir = (pos != rm->end()) ? pos->second : 0; - return rtdir; -} - -SWIGOCTRT void Swig::swig_director_destroyed(SwigOctType* self, Director* d) -{ - self->director_destroyed(d); -} - -SWIGOCTRT SwigOctType* Swig::swig_director_get_self(Director* d) -{ - return d->swig_get_self(); -} - -SWIGOCTRT void Swig::swig_director_set_self(Director* d, SwigOctType* self) -{ - d->swig_set_self(self); -} - -SWIGOCTRT void swig_acquire_ownership(void* vptr) -{ - // assert(0); - // ... todo -} - -SWIGOCTRT void swig_acquire_ownership_array(void* vptr) -{ - // assert(0); - // ... todo -} - -SWIGOCTRT void swig_acquire_ownership_obj(void* vptr, int own) -{ - // assert(0); - // ... todo -} - -#endif // SWIG_DIRECTORS diff --git a/Lib/octave/octrundecl.swg b/Lib/octave/octrundecl.swg deleted file mode 100644 index f71895abb..000000000 --- a/Lib/octave/octrundecl.swg +++ /dev/null @@ -1,479 +0,0 @@ -// -// octrundecl.swg - Declarations of Octave runtime code -// - -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include - -////////// Determine Octave version ////////// - -// Macro for enabling features which require Octave version >= major.minor.patch -#define SWIG_OCTAVE_PREREQ(major, minor, patch) \ - ( (OCTAVE_MAJOR_VERSION<<16) + (OCTAVE_MINOR_VERSION<<8) + OCTAVE_PATCH_VERSION >= ((major)<<16) + ((minor)<<8) + (patch) ) - -// Reconstruct Octave major, minor, and patch versions for releases prior to 3.8.1 -#if !defined(OCTAVE_MAJOR_VERSION) - -# if !defined(OCTAVE_API_VERSION_NUMBER) - -// Hack to distinguish between Octave 3.8.0, which removed OCTAVE_API_VERSION_NUMBER but did not yet -// introduce OCTAVE_MAJOR_VERSION, and Octave <= 3.2, which did not define OCTAVE_API_VERSION_NUMBER -# include -# if defined(octave_ov_h) -# define OCTAVE_MAJOR_VERSION 3 -# define OCTAVE_MINOR_VERSION 8 -# define OCTAVE_PATCH_VERSION 0 -# else - -// Hack to distinguish between Octave 3.2 and earlier versions, before OCTAVE_API_VERSION_NUMBER existed -# define ComplexLU __ignore -# include -# undef ComplexLU -# if defined(octave_Complex_LU_h) - -// We know only that this version is prior to Octave 3.2, i.e. OCTAVE_API_VERSION_NUMBER < 37 -# define OCTAVE_MAJOR_VERSION 3 -# define OCTAVE_MINOR_VERSION 1 -# define OCTAVE_PATCH_VERSION 99 - -# else - -// OCTAVE_API_VERSION_NUMBER == 37 -# define OCTAVE_MAJOR_VERSION 3 -# define OCTAVE_MINOR_VERSION 2 -# define OCTAVE_PATCH_VERSION 0 - -# endif // defined(octave_Complex_LU_h) - -# endif // defined(octave_ov_h) - -// Correlation between Octave API and version numbers extracted from Octave's -// ChangeLogs; version is the *earliest* released Octave with that API number -# elif OCTAVE_API_VERSION_NUMBER >= 48 -# define OCTAVE_MAJOR_VERSION 3 -# define OCTAVE_MINOR_VERSION 6 -# define OCTAVE_PATCH_VERSION 0 - -# elif OCTAVE_API_VERSION_NUMBER >= 45 -# define OCTAVE_MAJOR_VERSION 3 -# define OCTAVE_MINOR_VERSION 4 -# define OCTAVE_PATCH_VERSION 1 - -# elif OCTAVE_API_VERSION_NUMBER >= 42 -# define OCTAVE_MAJOR_VERSION 3 -# define OCTAVE_MINOR_VERSION 3 -# define OCTAVE_PATCH_VERSION 54 - -# elif OCTAVE_API_VERSION_NUMBER >= 41 -# define OCTAVE_MAJOR_VERSION 3 -# define OCTAVE_MINOR_VERSION 3 -# define OCTAVE_PATCH_VERSION 53 - -# elif OCTAVE_API_VERSION_NUMBER >= 40 -# define OCTAVE_MAJOR_VERSION 3 -# define OCTAVE_MINOR_VERSION 3 -# define OCTAVE_PATCH_VERSION 52 - -# elif OCTAVE_API_VERSION_NUMBER >= 39 -# define OCTAVE_MAJOR_VERSION 3 -# define OCTAVE_MINOR_VERSION 3 -# define OCTAVE_PATCH_VERSION 51 - -# else // OCTAVE_API_VERSION_NUMBER == 38 -# define OCTAVE_MAJOR_VERSION 3 -# define OCTAVE_MINOR_VERSION 3 -# define OCTAVE_PATCH_VERSION 50 - -# endif // !defined(OCTAVE_API_VERSION_NUMBER) - -#endif // !defined(OCTAVE_MAJOR_VERSION) - -// Octave_map was renamed to octave_map in v3.3.52 -#if !SWIG_OCTAVE_PREREQ(3,3,52) -#define octave_map Octave_map -#endif - -////////// Declare/define SWIG interface function loadable by Octave ////////// - -#if !SWIG_OCTAVE_PREREQ(3,2,0) -#define SWIG_DEFUN(cname, wname, doc) DEFUNX_DLD(#cname, wname, FS ## cname, args, nargout, doc) -#else -#define SWIG_DEFUN(cname, wname, doc) DEFUNX_DLD(#cname, wname, G ## cname, args, nargout, doc) -#endif - -////////// Define visibility of Octave runtime functions ////////// - -#define SWIGOCTRT SWIGRUNTIME -#define SWIGOCTRTINLINE SWIGOCTRT SWIGINLINE - -////////// Octave implementations of SWIG runtime functions ////////// - -#define SWIG_fail goto fail -#define swig_owntype int -#define SWIG_MODULE_CLIENTDATA_TYPE void* - -#define SWIG_ConvertFunctionPtr(obj, pptr, type) SWIG_ConvertPtr(obj, pptr, type, 0) -#define SWIG_ConvertMember(obj, ptr, sz, ty) SWIG_Octave_ConvertPacked(obj, ptr, sz, ty) -#define SWIG_ConvertPacked(obj, ptr, sz, ty) SWIG_Octave_ConvertPacked(obj, ptr, sz, ty) -#define SWIG_ConvertPtr(obj, pptr, type, flags) SWIG_Octave_ConvertPtr(obj, pptr, type, flags) -#define SWIG_ConvertPtr(obj, pptr, type, flags) SWIG_Octave_ConvertPtr(obj, pptr, type, flags) -#define SWIG_ConvertPtrAndOwn(obj,pptr,type,flags,own) SWIG_Octave_ConvertPtrAndOwn(obj, pptr, type, flags, own) -#define SWIG_GetModule(clientdata) SWIG_Octave_GetModule(clientdata) -#define SWIG_NewFunctionPtrObj(ptr, type) SWIG_NewPointerObj(ptr, type, 0) -#define SWIG_NewMemberObj(ptr, sz, type) SWIG_Octave_NewPackedObj(ptr, sz, type) -#define SWIG_NewPackedObj(ptr, sz, type) SWIG_Octave_NewPackedObj(ptr, sz, type) -#define SWIG_NewPointerObj(ptr, type, flags) SWIG_Octave_NewPointerObj(ptr, type, flags) -#define SWIG_Octave_AddErrorMsg(msg) {;} -#define SWIG_Octave_ConvertPtr(obj, pptr, type, flags) SWIG_Octave_ConvertPtrAndOwn(obj, pptr, type, flags, 0) -#define SWIG_Octave_ErrorOccurred() 0 -#define SWIG_SetModule(clientdata, pointer) SWIG_Octave_SetModule(clientdata,pointer); - -#define SWIG_DIRECTOR_CAST(ARG) dynamic_cast(ARG) - -// For backward compatibility only -#define SWIG_POINTER_EXCEPTION 0 -#define SWIG_arg_fail(arg) 0 - -////////// Forward declarations of Octave runtime classes and types ////////// - -class SwigOctPacked; -class SwigOctRef; -class SwigOctType; -struct SwigOctClass; -struct SwigOctMember; -struct SwigOctValueRef; -typedef octave_value_list(*SwigOctFuncPtr)(const octave_value_list&, int); - -#ifdef SWIG_DIRECTORS -namespace Swig -{ - class Director; - typedef std::map < void* , Director* > rtdir_map; -} -#endif - -////////// Declarations of Octave runtime functions ////////// - -SWIGOCTRT octave_value SWIG_Error(int code, const char* msg); -SWIGOCTRT octave_value SWIG_ErrorType(int code); -SWIGOCTRT octave_value_list* SWIG_Octave_AppendOutput(octave_value_list* ovl, const octave_value& ov); -SWIGOCTRT bool SWIG_Octave_CheckNumArgs(const char* func_name, int num_args, int max_args, int min_args, int varargs); -SWIGOCTRT int SWIG_Octave_ConvertPacked(const octave_value& ov, void* ptr, size_t sz, swig_type_info* type); -SWIGOCTRT int SWIG_Octave_ConvertPtrAndOwn(octave_value ov, void** ptr, swig_type_info* type, int flags, int* own); -SWIGOCTRTINLINE octave_value SWIG_Octave_GetGlobalValue(std::string name); -SWIGOCTRT swig_module_info* SWIG_Octave_GetModule(void* clientdata); -SWIGOCTRT swig_module_info* SWIG_Octave_GetModule(void* clientdata); -SWIGOCTRT void SWIG_Octave_LinkGlobalValue(std::string name); -SWIGOCTRT octave_value SWIG_Octave_NewPackedObj(void* ptr, size_t sz, swig_type_info* type); -SWIGOCTRT octave_value SWIG_Octave_NewPointerObj(void* ptr, swig_type_info* type, int flags); -SWIGOCTRTINLINE void SWIG_Octave_SetConstant(SwigOctType* module_ns, const std::string& name, const octave_value& ov); -SWIGOCTRT void SWIG_Octave_SetGlobalValue(std::string name, const octave_value& value); -SWIGOCTRT octave_value_list SWIG_Octave_SetImmutable(const octave_value_list& args, int nargout); -SWIGOCTRT void SWIG_Octave_SetModule(void* clientdata, swig_module_info* pointer); -SWIGOCTRT void SWIG_Octave_SetModule(void* clientdata, swig_module_info* pointer); -SWIGOCTRT SwigOctType* SWIG_Octave_ValueDeref(const octave_base_value& ov); -SWIGOCTRT SwigOctType* SWIG_Octave_ValueDeref(octave_value ov); -SWIGOCTRT octave_base_value* SWIG_Octave_ValueRef(SwigOctType* ost); - -#ifdef SWIG_DIRECTORS -namespace Swig -{ - SWIGOCTRTINLINE void erase_rtdir(void* vptr); - SWIGOCTRTINLINE Director* get_rtdir(void* vptr); - SWIGOCTRT rtdir_map* get_rtdir_map(); - SWIGOCTRTINLINE void set_rtdir(void* vptr, Director* d); - SWIGOCTRT void swig_director_destroyed(SwigOctType* self, Director* d); - SWIGOCTRT SwigOctType* swig_director_get_self(Director* d); - SWIGOCTRT void swig_director_set_self(Director* d, SwigOctType* self); -} -SWIGOCTRT void swig_acquire_ownership(void* vptr); -SWIGOCTRT void swig_acquire_ownership_array(void* vptr); -SWIGOCTRT void swig_acquire_ownership_obj(void* vptr, int own); -#endif - -////////// Declare Octave class: SwigOctMember ////////// - -struct SwigOctMember { - const char* name; - SwigOctFuncPtr method; - SwigOctFuncPtr get_method; - SwigOctFuncPtr set_method; - int flags; // 1=static, 2=global - const char* doc; - bool is_static() const { - return flags & 1; - } - bool is_global() const { - return flags & 2; - } -}; - -////////// Declare Octave class: SwigOctClass ////////// - -struct SwigOctClass { - const char* name; - swig_type_info** type; - int director; - SwigOctFuncPtr constructor; - const char* constructor_doc; - SwigOctFuncPtr destructor; - const SwigOctMember* members; - const char** base_names; - const swig_type_info** base; -}; - -////////// Declare Octave class: SwigOctValueRef ////////// - -struct SwigOctValueRef { - const octave_value_list& ovl; - int j; - SwigOctValueRef(const octave_value_list& _ovl, int _j) - : ovl(_ovl), j(_j) { - } - operator octave_value() const { - return ovl(j); - } - octave_value operator*() const { - return ovl(j); - } -}; - -////////// Declare Octave class: SwigOctType ////////// - -// SwigOctType plays the role of both the shadow class and the class -// representation within Octave, since there is no support for classes. -// -// These should really be decoupled, with the class support added to Octave -// and the shadow class given by an m-file script. That would dramatically -// reduce the runtime complexity, and be more in line w/ other modules. - -class SwigOctType: public octave_base_value -{ - - struct cpp_ptr { - void* ptr; - bool destroyed; - cpp_ptr(void* _ptr) : ptr(_ptr), destroyed(false) { - } - }; - - typedef std::pair < const swig_type_info* , cpp_ptr > type_ptr_pair; - typedef std::pair < const SwigOctMember* , octave_value > member_value_pair; - typedef std::map < std::string, member_value_pair > member_map; - - mutable swig_module_info* module; - const swig_type_info* construct_type; // type of special type object - std::vector < type_ptr_pair > types; // our c++ base classes - int own; // whether we call c++ destructors when we die - member_map members; - bool always_static; - - SwigOctType(const SwigOctType& x); - SwigOctType& operator= (const SwigOctType& rhs); - - bool dispatch_binary_op(const std::string& symbol, const octave_base_value& rhs, octave_value& ret); - bool dispatch_index_op(const std::string& symbol, const octave_value_list& rhs, octave_value_list& ret); - bool dispatch_unary_op(const std::string& symbol, octave_value& ret); - const swig_type_info* find_base(const std::string& name, const swig_type_info* base); - member_value_pair* find_member(const std::string& name, bool insert_if_not_found); - const SwigOctMember* find_member(const swig_type_info* type, const std::string& name); - void load_members(const SwigOctClass* c, member_map& out) const; - void load_members(member_map& out) const; - static octave_value make_value_hack(const octave_base_value& x); - octave_value_list member_deref(member_value_pair* m, const octave_value_list& args); - octave_value_list member_invoke(member_value_pair* m, const octave_value_list& args, int nargout); - -public: - - typedef member_map::const_iterator swig_member_const_iterator; - - SwigOctType(void* _ptr = 0, const swig_type_info* _type = 0, int _own = 0, bool _always_static = false); - ~SwigOctType(); - - octave_value as_value(); - void assign(const std::string& name, const octave_value& ov); - void assign(const std::string& name, const SwigOctMember* m); - void* cast(swig_type_info* type, int* _own, int flags); - octave_base_value* clone() const; - virtual octave_value convert_to_str(bool pad = false, bool force = false, char type = '"') const; - virtual octave_value convert_to_str_internal(bool pad, bool force, char type) const; - void decref(); - dim_vector dims(void) const; - static octave_value dispatch_binary_op(const octave_base_value& lhs, const octave_base_value& rhs, const char* op_name); - static bool dispatch_global_op(const std::string& symbol, const octave_value_list& args, octave_value& ret); - static octave_value dispatch_unary_op(const octave_base_value& x, const char* op_name); - octave_base_value* empty_clone() const; - const char* help_text() const; - void incref(); - bool is_defined() const; - virtual bool is_map() const; - virtual bool is_object() const; - bool is_owned() const; - virtual bool is_string() const; - virtual bool load_ascii(std::istream& is); - virtual bool load_binary(std::istream& is, bool swap, oct_mach_info::float_format fmt); - virtual string_vector map_keys() const; - virtual octave_map map_value() const; - void merge(SwigOctType& rhs); - void print(std::ostream& os, bool pr_as_read_syntax = false) const; - virtual bool save_ascii(std::ostream& os); - virtual bool save_binary(std::ostream& os, bool& save_as_floats); - virtual std::string string_value(bool force = false) const; - octave_value subsasgn(const std::string& ops, const std::list < octave_value_list > &idx, const octave_value& rhs); - virtual octave_value subsref(const std::string& ops, const std::list < octave_value_list > &idx); - virtual octave_value_list subsref(const std::string& ops, const std::list < octave_value_list > &idx, int nargout); - swig_member_const_iterator swig_members_begin(); - swig_member_const_iterator swig_members_end(); - long swig_this() const; - std::string swig_type_name() const; - -#ifdef HAVE_HDF5 - virtual bool load_hdf5(hid_t loc_id, const char* name, bool have_h5giterate_bug); - virtual bool save_hdf5(hid_t loc_id, const char* name, bool save_as_floats); -#endif - -#ifdef SWIG_DIRECTORS - void director_destroyed(Swig::Director* d); -#endif - -}; - -////////// Declare Octave class: SwigOctType ////////// - -// Octave tries hard to preserve pass-by-value semantics. Eg, assignments -// will call clone() via make_unique() if there is more than one outstanding -// reference to the lhs, and forces the clone's reference count to 1 -// (so you can't just increment your own count and return this). -// -// One way to fix this (without modifying Octave) is to add a level of -// indirection such that clone copies ref-counted pointer and we keep -// pass-by-ref semantics (which are more natural/expected for C++ bindings). -// -// Supporting both pass-by-{ref,value} and toggling via %feature/option -// might be nice. - -class SwigOctRef: public octave_base_value -{ - - DECLARE_OCTAVE_ALLOCATOR; - DECLARE_OV_TYPEID_FUNCTIONS_AND_DATA; - - SwigOctType* ptr; - -public: - - SwigOctRef(SwigOctType* _ptr = 0); - ~SwigOctRef(); - - octave_base_value* clone() const; - virtual octave_value convert_to_str(bool pad = false, bool force = false, char type = '"') const; - virtual octave_value convert_to_str_internal(bool pad, bool force, char type) const; - dim_vector dims(void) const; - octave_base_value* empty_clone() const; - SwigOctType* get_ptr() const; - bool is_defined() const; - virtual bool is_map() const; - virtual bool is_object() const; - virtual bool is_string() const; - virtual bool load_ascii(std::istream& is); - virtual bool load_binary(std::istream& is, bool swap, oct_mach_info::float_format fmt); - virtual string_vector map_keys() const; - virtual octave_map map_value() const; - void print(std::ostream& os, bool pr_as_read_syntax = false) const; - virtual bool save_ascii(std::ostream& os); - virtual bool save_binary(std::ostream& os, bool& save_as_floats); - virtual std::string string_value(bool force = false) const; - octave_value subsasgn(const std::string& ops, const std::list < octave_value_list > &idx, const octave_value& rhs); - virtual octave_value subsref(const std::string& ops, const std::list < octave_value_list > &idx); - virtual octave_value_list subsref(const std::string& ops, const std::list < octave_value_list > &idx, int nargout); - -#ifdef HAVE_HDF5 - virtual bool load_hdf5(hid_t loc_id, const char* name, bool have_h5giterate_bug); - virtual bool save_hdf5(hid_t loc_id, const char* name, bool save_as_floats); -#endif - -}; - -////////// Declare Octave class: SwigOctPacked ////////// - -class SwigOctPacked: public octave_base_value -{ - - DECLARE_OCTAVE_ALLOCATOR; - DECLARE_OV_TYPEID_FUNCTIONS_AND_DATA; - - swig_type_info* type; - std::vector < char > buf; - -public: - - SwigOctPacked(swig_type_info* _type = 0, const void* _buf = 0, size_t _buf_len = 0); - - octave_base_value* clone() const; - bool copy(swig_type_info* outtype, void* ptr, size_t sz) const; - octave_base_value* empty_clone() const; - bool is_defined() const; - virtual bool load_ascii(std::istream& is); - virtual bool load_binary(std::istream& is, bool swap, oct_mach_info::float_format fmt); - void print(std::ostream& os, bool pr_as_read_syntax = false) const; - virtual bool save_ascii(std::ostream& os); - virtual bool save_binary(std::ostream& os, bool& save_as_floats); - -#ifdef HAVE_HDF5 - virtual bool load_hdf5(hid_t loc_id, const char* name, bool have_h5giterate_bug); - virtual bool save_hdf5(hid_t loc_id, const char* name, bool save_as_floats); -#endif - -}; - -////////// Declare Octave class: Swig::Director and related classes ////////// - -#ifdef SWIG_DIRECTORS -namespace Swig -{ - - class Director - { - - SwigOctType* self; - bool swig_disowned; - - Director(const Director& x); - Director& operator= (const Director& rhs); - - public: - - Director(void* vptr); - ~Director(); - - void swig_disown(); - SwigOctType* swig_get_self() const; - void swig_set_self(SwigOctType* new_self); - - }; - - struct DirectorTypeMismatchException { - static void raise(const char* msg); - static void raise(const octave_value& ov, const char* msg); - }; - - struct DirectorPureVirtualException { - static void raise(const char* msg); - static void raise(const octave_value& ov, const char* msg); - }; - -} -#endif diff --git a/Lib/octave/octrunfunc.swg b/Lib/octave/octrunfunc.swg deleted file mode 100644 index 6773373b8..000000000 --- a/Lib/octave/octrunfunc.swg +++ /dev/null @@ -1,187 +0,0 @@ -// -// octrunfunc.swg - Octave runtime functions -// - -SWIGOCTRT bool SWIG_Octave_CheckNumArgs(const char* func_name, int num_args, int max_args, int min_args, int varargs) -{ - if (num_args > max_args && !varargs) { - error("function %s takes at most %i arguments", func_name, max_args); - } else if (num_args < min_args) { - error("function %s requires at least %i arguments", func_name, min_args); - } else { - return true; - } - return false; -} - -SWIGOCTRT octave_value_list* SWIG_Octave_AppendOutput(octave_value_list* ovl, const octave_value& ov) -{ - ovl->append(ov); - return ovl; -} - -SWIGOCTRT octave_value SWIG_ErrorType(int code) -{ - switch (code) { - case SWIG_MemoryError: - return "SWIG_MemoryError"; - case SWIG_IOError: - return "SWIG_IOError"; - case SWIG_RuntimeError: - return "SWIG_RuntimeError"; - case SWIG_IndexError: - return "SWIG_IndexError"; - case SWIG_TypeError: - return "SWIG_TypeError"; - case SWIG_DivisionByZero: - return "SWIG_DivisionByZero"; - case SWIG_OverflowError: - return "SWIG_OverflowError"; - case SWIG_SyntaxError: - return "SWIG_SyntaxError"; - case SWIG_ValueError: - return "SWIG_ValueError"; - case SWIG_SystemError: - return "SWIG_SystemError"; - case SWIG_AttributeError: - return "SWIG_AttributeError"; - } - return "SWIG unknown error"; -} - -SWIGOCTRT octave_value SWIG_Error(int code, const char* msg) -{ - octave_value type(SWIG_ErrorType(code)); - std::string r = msg; - r += " (" + type.string_value() + ")"; - error(r.c_str()); - return octave_value(r); -} - -SWIGOCTRT octave_value SWIG_Octave_NewPointerObj(void* ptr, swig_type_info* type, int flags) -{ - int own = (flags & SWIG_POINTER_OWN) ? SWIG_POINTER_OWN : 0; -#ifdef SWIG_DIRECTORS - Swig::Director* d = Swig::get_rtdir(ptr); - if (d && Swig::swig_director_get_self(d)) { - return Swig::swig_director_get_self(d)->as_value(); - } -#endif - return SWIG_Octave_ValueRef(new SwigOctType(ptr, type, own)); -} - -SWIGOCTRT int SWIG_Octave_ConvertPtrAndOwn(octave_value ov, void** ptr, swig_type_info* type, int flags, int* own) -{ - if (ov.is_cell() && ov.rows() == 1 && ov.columns() == 1) { - ov = ov.cell_value()(0); - } - if (!ov.is_defined() || (ov.is_matrix_type() && ov.rows() == 0 && ov.columns() == 0)) { - if (ptr) { - *ptr = 0; - } - return SWIG_OK; - } - if (ov.type_id() != SwigOctRef::static_type_id()) { - return SWIG_ERROR; - } - SwigOctRef* osr = static_cast < SwigOctRef*>(ov.internal_rep()); - SwigOctType* ost = osr->get_ptr(); - void* vptr = ost->cast(type, own, flags); - if (!vptr) { - return SWIG_ERROR; - } - if (ptr) { - *ptr = vptr; - } - return SWIG_OK; -} - -SWIGOCTRT octave_value SWIG_Octave_NewPackedObj(void* ptr, size_t sz, swig_type_info* type) -{ - return new SwigOctPacked(type, (char*) ptr, sz); -} - -SWIGOCTRT int SWIG_Octave_ConvertPacked(const octave_value& ov, void* ptr, size_t sz, swig_type_info* type) -{ - if (!ov.is_defined()) { - return SWIG_ERROR; - } - if (ov.type_id() != SwigOctPacked::static_type_id()) { - return SWIG_ERROR; - } - SwigOctPacked* ost = static_cast < SwigOctPacked*>(ov.internal_rep()); - return ost->copy(type, (char*) ptr, sz) ? SWIG_OK : SWIG_ERROR; -} - -SWIGOCTRTINLINE void SWIG_Octave_SetConstant(SwigOctType* module_ns, const std::string& name, const octave_value& ov) -{ - module_ns->assign(name, ov); -} - -SWIGOCTRTINLINE octave_value SWIG_Octave_GetGlobalValue(std::string name) -{ - return get_global_value(name, true); -} - -SWIGOCTRT void SWIG_Octave_SetGlobalValue(std::string name, const octave_value& value) -{ - set_global_value(name, value); -} - -SWIGOCTRT void SWIG_Octave_LinkGlobalValue(std::string name) -{ -#if !SWIG_OCTAVE_PREREQ(3,2,0) - link_to_global_variable(curr_sym_tab->lookup(name, true)); -#else -#if !SWIG_OCTAVE_PREREQ(3,8,0) - symbol_table::varref(name); -#endif - symbol_table::mark_global(name); -#endif -} - -SWIGOCTRT swig_module_info* SWIG_Octave_GetModule(void* clientdata) -{ - octave_value ov = SWIG_Octave_GetGlobalValue("__SWIG_MODULE__" SWIG_TYPE_TABLE_NAME SWIG_RUNTIME_VERSION); - if (!ov.is_defined() || ov.type_id() != SwigOctPacked::static_type_id()) { - return 0; - } - const SwigOctPacked* osp = static_cast < const SwigOctPacked*>(ov.internal_rep()); - swig_module_info* pointer = 0; - osp->copy(0, &pointer, sizeof(swig_module_info*)); - return pointer; -} - -SWIGOCTRT void SWIG_Octave_SetModule(void* clientdata, swig_module_info* pointer) -{ - octave_value ov = new SwigOctPacked(0, &pointer, sizeof(swig_module_info*)); - SWIG_Octave_SetGlobalValue("__SWIG_MODULE__" SWIG_TYPE_TABLE_NAME SWIG_RUNTIME_VERSION, ov); -} - -SWIGOCTRT octave_base_value* SWIG_Octave_ValueRef(SwigOctType* ost) -{ - return new SwigOctRef(ost); -} - -SWIGOCTRT SwigOctType* SWIG_Octave_ValueDeref(octave_value ov) -{ - if (ov.is_cell() && ov.rows() == 1 && ov.columns() == 1) { - ov = ov.cell_value()(0); - } - return SWIG_Octave_ValueDeref(*ov.internal_rep()); -} - -SWIGOCTRT SwigOctType* SWIG_Octave_ValueDeref(const octave_base_value& ov) -{ - if (ov.type_id() != SwigOctRef::static_type_id()) { - return 0; - } - const SwigOctRef* osr = static_cast < const SwigOctRef*>(&ov); - return osr->get_ptr(); -} - -SWIGOCTRT octave_value_list SWIG_Octave_SetImmutable(const octave_value_list& args, int nargout) -{ - error("attempt to set immutable member variable"); - return octave_value_list(); -} diff --git a/Lib/octave/octruninit.swg b/Lib/octave/octruninit.swg deleted file mode 100644 index 86d033af2..000000000 --- a/Lib/octave/octruninit.swg +++ /dev/null @@ -1,422 +0,0 @@ -// -// octruninit.swg - Octave runtime initialisation code -// - -// Forward declaration of module initialisation function -SWIGINTERN bool SWIG_Octave_InitUser(SwigOctType* module_ns); - -////////// Define, register, and install unary and binary operator dispatch functions ////////// - -#define SWIG_Octave_UnaryOp(name) \ - SWIGINTERN octave_value SWIG_Octave_UnaryOp_##name(const octave_base_value &x) { \ - return SwigOctType::dispatch_unary_op(x,#name); \ - } -#define SWIG_Octave_BinaryOp(name) \ - SWIGINTERN octave_value SWIG_Octave_BinaryOp_##name(const octave_base_value&lhs,const octave_base_value &rhs) { \ - return SwigOctType::dispatch_binary_op(lhs,rhs,#name); \ - } - -SWIG_Octave_UnaryOp(not); -SWIG_Octave_UnaryOp(uplus); -SWIG_Octave_UnaryOp(uminus); -SWIG_Octave_UnaryOp(transpose); -SWIG_Octave_UnaryOp(hermitian); -SWIG_Octave_UnaryOp(incr); -SWIG_Octave_UnaryOp(decr); - -SWIG_Octave_BinaryOp(add); -SWIG_Octave_BinaryOp(sub); -SWIG_Octave_BinaryOp(mul); -SWIG_Octave_BinaryOp(div); -SWIG_Octave_BinaryOp(pow); -SWIG_Octave_BinaryOp(ldiv); -SWIG_Octave_BinaryOp(lshift); -SWIG_Octave_BinaryOp(rshift); -SWIG_Octave_BinaryOp(lt); -SWIG_Octave_BinaryOp(le); -SWIG_Octave_BinaryOp(eq); -SWIG_Octave_BinaryOp(ge); -SWIG_Octave_BinaryOp(gt); -SWIG_Octave_BinaryOp(ne); -SWIG_Octave_BinaryOp(el_mul); -SWIG_Octave_BinaryOp(el_div); -SWIG_Octave_BinaryOp(el_pow); -SWIG_Octave_BinaryOp(el_ldiv); -SWIG_Octave_BinaryOp(el_and); -SWIG_Octave_BinaryOp(el_or); - -#define SWIG_Octave_RegisterUnaryOp(name) \ - if (!octave_value_typeinfo::lookup_unary_op(octave_value::op_##name,tid)) \ - octave_value_typeinfo::register_unary_op(octave_value::op_##name,tid,SWIG_Octave_UnaryOp_##name); -#define SWIG_Octave_RegisterBinaryOp(name) \ - if (!octave_value_typeinfo::lookup_binary_op(octave_value::op_##name,tid1,tid2)) \ - octave_value_typeinfo::register_binary_op(octave_value::op_##name,tid1,tid2,SWIG_Octave_BinaryOp_##name); - -SWIGINTERN void SWIG_Octave_InstallUnaryOps(int tid) -{ - SWIG_Octave_RegisterUnaryOp(not); - SWIG_Octave_RegisterUnaryOp(uplus); - SWIG_Octave_RegisterUnaryOp(uminus); - SWIG_Octave_RegisterUnaryOp(transpose); - SWIG_Octave_RegisterUnaryOp(hermitian); - SWIG_Octave_RegisterUnaryOp(incr); - SWIG_Octave_RegisterUnaryOp(decr); -} - -SWIGINTERN void SWIG_Octave_InstallBinaryOps(int tid1, int tid2) -{ - SWIG_Octave_RegisterBinaryOp(add); - SWIG_Octave_RegisterBinaryOp(sub); - SWIG_Octave_RegisterBinaryOp(mul); - SWIG_Octave_RegisterBinaryOp(div); - SWIG_Octave_RegisterBinaryOp(pow); - SWIG_Octave_RegisterBinaryOp(ldiv); - SWIG_Octave_RegisterBinaryOp(lshift); - SWIG_Octave_RegisterBinaryOp(rshift); - SWIG_Octave_RegisterBinaryOp(lt); - SWIG_Octave_RegisterBinaryOp(le); - SWIG_Octave_RegisterBinaryOp(eq); - SWIG_Octave_RegisterBinaryOp(ge); - SWIG_Octave_RegisterBinaryOp(gt); - SWIG_Octave_RegisterBinaryOp(ne); - SWIG_Octave_RegisterBinaryOp(el_mul); - SWIG_Octave_RegisterBinaryOp(el_div); - SWIG_Octave_RegisterBinaryOp(el_pow); - SWIG_Octave_RegisterBinaryOp(el_ldiv); - SWIG_Octave_RegisterBinaryOp(el_and); - SWIG_Octave_RegisterBinaryOp(el_or); -} - -SWIGINTERN void SWIG_Octave_InstallOps(int tid) -{ - // here we assume that tid are conseq integers increasing from zero, and - // that our tid is the last one. might be better to have explicit string - // list of types we should bind to, and use lookup_type to resolve their tid. - SWIG_Octave_InstallUnaryOps(tid); - SWIG_Octave_InstallBinaryOps(tid, tid); - for (int j = 0; j < tid; ++j) { - SWIG_Octave_InstallBinaryOps(j, tid); - SWIG_Octave_InstallBinaryOps(tid, j); - } -} - -////////// Internal functions for loading/installing modules ////////// - -SWIGINTERN bool SWIG_Octave_LoadModule(std::string name) -{ - bool retn; - { -#if !SWIG_OCTAVE_PREREQ(3,3,50) - unwind_protect::begin_frame("SWIG_Octave_LoadModule"); - unwind_protect_int(error_state); - unwind_protect_int(warning_state); - unwind_protect_bool(discard_error_messages); - unwind_protect_bool(discard_warning_messages); -#else - unwind_protect frame; - frame.protect_var(error_state); - frame.protect_var(warning_state); - frame.protect_var(discard_error_messages); - frame.protect_var(discard_warning_messages); -#endif - error_state = 0; - warning_state = 0; - discard_error_messages = true; - discard_warning_messages = true; - feval(name, octave_value_list(), 0); - retn = (error_state == 0); -#if !SWIG_OCTAVE_PREREQ(3,3,50) - unwind_protect::run_frame("SWIG_Octave_LoadModule"); -#endif - } - if (!retn) { - error(SWIG_name_d ": could not load module `%s'", name.c_str()); - } - return retn; -} - -SWIGINTERN bool SWIG_Octave_InstallFunction(octave_function* octloadfcn, std::string name) -{ - bool retn; - { -#if !SWIG_OCTAVE_PREREQ(3,3,50) - unwind_protect::begin_frame("SWIG_Octave_InstallFunction"); - unwind_protect_int(error_state); - unwind_protect_int(warning_state); - unwind_protect_bool(discard_error_messages); - unwind_protect_bool(discard_warning_messages); -#else - unwind_protect frame; - frame.protect_var(error_state); - frame.protect_var(warning_state); - frame.protect_var(discard_error_messages); - frame.protect_var(discard_warning_messages); -#endif - error_state = 0; - warning_state = 0; - discard_error_messages = true; - discard_warning_messages = true; - octave_value_list args; - args.append(name); - args.append(octloadfcn->fcn_file_name()); - error_state = 0; - feval("autoload", args, 0); - retn = (error_state == 0); -#if !SWIG_OCTAVE_PREREQ(3,3,50) - unwind_protect::run_frame("SWIG_Octave_InstallFunction"); -#endif - } - if (!retn) { - error(SWIG_name_d ": could not load function `%s'", name.c_str()); - } - return retn; -} - -////////// Public module function: swig_type() ////////// - -static const char* const swig_type_usage = "-*- texinfo -*- \n\ -@deftypefn {Loadable Function} {} swig_type(@var{swigref})\n\ -Return the underlying C/C++ type name of a SWIG-wrapped object.\n\ -@end deftypefn"; - -DEFUN_DLD(swig_type, args, nargout, swig_type_usage) -{ - if (args.length() != 1) { - error("swig_type: must be called with only a single object"); - return octave_value_list(); - } - SwigOctType* ost = SWIG_Octave_ValueDeref(args(0)); - if (!ost) { - error("swig_type: object is not a swig_ref"); - return octave_value_list(); - } - return octave_value(ost->swig_type_name()); -} - -////////// Public module function: swig_typequery() ////////// - -static const char* const swig_typequery_usage = "-*- texinfo -*- \n\ -@deftypefn {Loadable Function} {} swig_typequery(@var{string})\n\ -Return @var{string} if it is a recognised SWIG-wrapped C/C++ type name;\n\ -otherwise return `'.\n\ -@end deftypefn"; - -DEFUN_DLD(swig_typequery, args, nargout, swig_typequery_usage) -{ - if (args.length() != 1 || !args(0).is_string()) { - error("swig_typequery: must be called with single string argument"); - return octave_value_list(); - } - swig_module_info* module = SWIG_GetModule(0); - swig_type_info* type = SWIG_TypeQueryModule(module, module, args(0).string_value().c_str()); - if (!type) { - return octave_value(""); - } - return octave_value(type->name); -} - -////////// Public module function: swig_this() ////////// - -static const char* const swig_this_usage = "-*- texinfo -*- \n\ -@deftypefn {Loadable Function} {} swig_this(@var{swigref})\n\ -Return the underlying C/C++ pointer of a SWIG-wrapped object.\n\ -@end deftypefn"; - -DEFUN_DLD(swig_this, args, nargout, swig_this_usage) -{ - if (args.length() != 1) { - error("swig_this: must be called with only a single object"); - return octave_value_list(); - } - if (args(0).is_matrix_type() && args(0).rows() == 0 && args(0).columns() == 0) { - return octave_value(octave_uint64(0)); - } - SwigOctType* ost = SWIG_Octave_ValueDeref(args(0)); - if (!ost) { - error("swig_this: object is not a swig_ref"); - return octave_value_list(); - } - return octave_value(octave_uint64((unsigned long long) ost->swig_this())); -} - -////////// Public module function: subclass() ////////// - -static const char* const subclass_usage = "-*- texinfo -*- \n\ -@deftypefn {Loadable Function} {} subclass()\n\ -@deftypefnx{Loadable Function} {} subclass(@var{swigclass}, @var{name}, @var{fcn}, @dots{})\n\ -Subclass a C++ class from within Octave, and provide implementations of its virtual methods.\n\ -\n\ -See the SWIG manual for usage examples.\n\ -@end deftypefn"; - -DEFUN_DLD(subclass, args, nargout, subclass_usage) -{ - SwigOctType* top = new SwigOctType; - for (int j = 0; j < args.length(); ++j) { - if (args(j).type_id() == SwigOctRef::static_type_id()) { - SwigOctRef* osr = static_cast < SwigOctRef*>(args(j).internal_rep()); - SwigOctType* ost = osr->get_ptr(); - if (!ost->is_owned()) { - error("subclass: cannot subclass object not constructed on octave side"); - return octave_value_list(); - } - top->merge(*ost); - } else if (args(j).is_function_handle()) { - top->assign(args(j).fcn_handle_value()->fcn_name(), args(j)); - } else if (args(j).is_string()) { - if (j + 1 >= args.length()) { - error("subclass: member assignments must be of string,value form"); - return octave_value_list(); - } - top->assign(args(j).string_value(), args(j + 1)); - ++j; - } else { - error("subclass: invalid arguments to subclass()"); - return octave_value_list(); - } - } - return octave_value(SWIG_Octave_ValueRef(top)); -} - -////////// Public function which loads the Octave module ////////// - -static const char* const SWIG_name_usage = "-*- texinfo -*- \n\ -@deftypefn {Loadable Module} {} " SWIG_name_d "\n\ -Loads the SWIG-generated module `" SWIG_name_d "'.\n\ -@end deftypefn"; - -DEFUN_DLD(SWIG_name, args, nargout, SWIG_name_usage) -{ - - static SwigOctType* module_ns = 0; - - // workaround to prevent octave seg-faulting on exit: set Octave exit function - // octave_exit to _Exit, which exits immediately without trying to cleanup memory. - // definitely affects version 3.2.*, not sure about 3.3.*, seems to be fixed in - // version 3.4.* and above. can be turned off with macro definition. -#ifndef SWIG_OCTAVE_NO_SEGFAULT_HACK -#if SWIG_OCTAVE_PREREQ(3,2,0) && !SWIG_OCTAVE_PREREQ(3,4,1) - octave_exit = ::_Exit; -#endif -#endif - - // check for no input and output args - if (args.length() != 0 || nargout != 0) { - print_usage(); - return octave_value_list(); - } - - // create module on first function call - if (!module_ns) { - - // workaround bug in octave where installing global variable of custom type and then - // exiting without explicitly clearing the variable causes octave to segfault. -#if SWIG_OCTAVE_PREREQ(3,2,0) - octave_value_list eval_args; - eval_args.append("base"); - eval_args.append("function __swig_atexit__; " - " if mislocked() " - " clear -all; " - " else " - " mlock(); " - " endif; " - "endfunction; " - "__swig_atexit__; " - "atexit(\"__swig_atexit__\", false); " - "atexit(\"__swig_atexit__\")"); - feval("evalin", eval_args, 0); -#endif - - SwigOctRef::register_type(); - SwigOctPacked::register_type(); - SWIG_InitializeModule(0); - SWIG_PropagateClientData(); - - octave_function* me = octave_call_stack::current(); - - if (!SWIG_Octave_InstallFunction(me, "swig_type")) { - return octave_value_list(); - } - if (!SWIG_Octave_InstallFunction(me, "swig_typequery")) { - return octave_value_list(); - } - if (!SWIG_Octave_InstallFunction(me, "swig_this")) { - return octave_value_list(); - } - if (!SWIG_Octave_InstallFunction(me, "subclass")) { - return octave_value_list(); - } - - SwigOctType* cvar_ns = 0; - if (std::string(SWIG_global_name) != ".") { - cvar_ns = new SwigOctType; - for (int j = 0; swig_globals[j].name; ++j) - if (swig_globals[j].get_method) { - cvar_ns->assign(swig_globals[j].name, &swig_globals[j]); - } - } - - module_ns = new SwigOctType(0, 0, 0, true); - if (std::string(SWIG_global_name) != ".") { - module_ns->assign(SWIG_global_name, SWIG_Octave_ValueRef(cvar_ns)); - } else { - for (int j = 0; swig_globals[j].name; ++j) - if (swig_globals[j].get_method) { - module_ns->assign(swig_globals[j].name, &swig_globals[j]); - } - } - for (int j = 0; swig_globals[j].name; ++j) - if (swig_globals[j].method) { - module_ns->assign(swig_globals[j].name, &swig_globals[j]); - } - - // * need better solution here; swig_type -> octave_class mapping is - // * really n-to-1, in some cases such as template partial spec, etc. - // * see failing tests. - for (int j = 0; swig_types[j]; ++j) - if (swig_types[j]->clientdata) { - SwigOctClass* c = (SwigOctClass*) swig_types[j]->clientdata; - module_ns->assign(c->name, - SWIG_Octave_ValueRef - (new SwigOctType(0, swig_types[j]))); - } - - if (!SWIG_Octave_InitUser(module_ns)) { - delete module_ns; - module_ns = 0; - return octave_value_list(); - } - - SWIG_Octave_InstallOps(SwigOctRef::static_type_id()); - - SwigOctType::swig_member_const_iterator mb; - for (mb = module_ns->swig_members_begin(); mb != module_ns->swig_members_end(); ++mb) { - if (mb->second.first && mb->second.first->method) { - if (!SWIG_Octave_InstallFunction(me, mb->first)) { - return octave_value_list(); - } - } - } - -#if !SWIG_OCTAVE_PREREQ(3,2,0) - mlock(me->name()); -#else - mlock(); -#endif - - } - - SwigOctType::swig_member_const_iterator mb; - for (mb = module_ns->swig_members_begin(); mb != module_ns->swig_members_end(); ++mb) { - if (mb->second.second.is_defined()) { - SWIG_Octave_SetGlobalValue(mb->first, mb->second.second); - SWIG_Octave_LinkGlobalValue(mb->first); - } - } - - SWIG_Octave_SetGlobalValue(SWIG_name_d, module_ns->as_value()); - SWIG_Octave_LinkGlobalValue(SWIG_name_d); - - return octave_value_list(); - -} diff --git a/Lib/octave/octruntime.swg b/Lib/octave/octruntime.swg index cdcb66c30..fbf2007f6 100644 --- a/Lib/octave/octruntime.swg +++ b/Lib/octave/octruntime.swg @@ -1,20 +1,323 @@ -// -// octruntime.swg - Octave runtime code -// +%insert(runtime) %{ +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +%} -// Insert standard SWIG runtime code -%insert("runtime") "swigrun.swg"; -%insert("runtime") "swigerrors.swg"; -%insert("initbeforefunc") "swiginit.swg" +%insert(runtime) "swigrun.swg"; +%insert(runtime) "swigerrors.swg"; +%insert(runtime) "octrun.swg"; -// Declarations of Octave runtime code -%insert("runtime") "octrundecl.swg"; +%insert(initbeforefunc) "swiginit.swg" -// Octave runtime functions -%insert("runtime") "octrunfunc.swg" +%insert(initbeforefunc) %{ -// Octave runtime classes -%insert("runtime") "octrunclass.swg" +static bool SWIG_init_user(octave_swig_type* module_ns); -// Octave runtime initialisation code -%insert("initbeforefunc") "octruninit.swg" +SWIGINTERN bool SWIG_Octave_LoadModule(std::string name) { + bool retn; + { +#if !SWIG_OCTAVE_PREREQ(3,3,50) + unwind_protect::begin_frame("SWIG_Octave_LoadModule"); + unwind_protect_int(error_state); + unwind_protect_int(warning_state); + unwind_protect_bool(discard_error_messages); + unwind_protect_bool(discard_warning_messages); +#else + unwind_protect frame; + frame.protect_var(error_state); + frame.protect_var(warning_state); + frame.protect_var(discard_error_messages); + frame.protect_var(discard_warning_messages); +#endif + error_state = 0; + warning_state = 0; + discard_error_messages = true; + discard_warning_messages = true; + feval(name, octave_value_list(), 0); + retn = (error_state == 0); +#if !SWIG_OCTAVE_PREREQ(3,3,50) + unwind_protect::run_frame("SWIG_Octave_LoadModule"); +#endif + } + if (!retn) { + error(SWIG_name_d ": could not load module `%s'", name.c_str()); + } + return retn; +} + +SWIGINTERN bool SWIG_Octave_InstallFunction(octave_function *octloadfcn, std::string name) { + bool retn; + { +#if !SWIG_OCTAVE_PREREQ(3,3,50) + unwind_protect::begin_frame("SWIG_Octave_InstallFunction"); + unwind_protect_int(error_state); + unwind_protect_int(warning_state); + unwind_protect_bool(discard_error_messages); + unwind_protect_bool(discard_warning_messages); +#else + unwind_protect frame; + frame.protect_var(error_state); + frame.protect_var(warning_state); + frame.protect_var(discard_error_messages); + frame.protect_var(discard_warning_messages); +#endif + error_state = 0; + warning_state = 0; + discard_error_messages = true; + discard_warning_messages = true; + octave_value_list args; + args.append(name); + args.append(octloadfcn->fcn_file_name()); + error_state = 0; + feval("autoload", args, 0); + retn = (error_state == 0); +#if !SWIG_OCTAVE_PREREQ(3,3,50) + unwind_protect::run_frame("SWIG_Octave_InstallFunction"); +#endif + } + if (!retn) { + error(SWIG_name_d ": could not load function `%s'", name.c_str()); + } + return retn; +} + +static const char *const subclass_usage = "-*- texinfo -*- \n\ +@deftypefn {Loadable Function} {} subclass()\n\ +@deftypefnx{Loadable Function} {} subclass(@var{swigclass}, @var{name}, @var{fcn}, @dots{})\n\ +Subclass a C++ class from within Octave, and provide implementations of its virtual methods.\n\ +\n\ +See the SWIG manual for usage examples.\n\ +@end deftypefn"; + +DEFUN_DLD( subclass, args, nargout, subclass_usage ) { + octave_swig_type *top = new octave_swig_type; + for (int j = 0; j < args.length(); ++j) { + if (args(j).type_id() == octave_swig_ref::static_type_id()) { + octave_swig_ref *osr = static_cast < octave_swig_ref *>(args(j).internal_rep()); + octave_swig_type *ost = osr->get_ptr(); + if (!ost->is_owned()) { + error("subclass: cannot subclass object not constructed on octave side"); + return octave_value_list(); + } + top->merge(*ost); + } else if (args(j).is_function_handle()) { + top->assign(args(j).fcn_handle_value()->fcn_name(), args(j)); + } else if (args(j).is_string()) { + if (j + 1 >= args.length()) { + error("subclass: member assignments must be of string,value form"); + return octave_value_list(); + } + top->assign(args(j).string_value(), args(j + 1)); + ++j; + } else { + error("subclass: invalid arguments to subclass()"); + return octave_value_list(); + } + } + return octave_value(Swig::swig_value_ref(top)); +} + +static const char *const swig_type_usage = "-*- texinfo -*- \n\ +@deftypefn {Loadable Function} {} swig_type(@var{swigref})\n\ +Return the underlying C/C++ type name of a SWIG-wrapped object.\n\ +@end deftypefn"; + +DEFUN_DLD( swig_type, args, nargout, swig_type_usage ) { + if (args.length() != 1) { + error("swig_type: must be called with only a single object"); + return octave_value_list(); + } + octave_swig_type *ost = Swig::swig_value_deref(args(0)); + if (!ost) { + error("swig_type: object is not a swig_ref"); + return octave_value_list(); + } + return octave_value(ost->swig_type_name()); +} + +static const char *const swig_typequery_usage = "-*- texinfo -*- \n\ +@deftypefn {Loadable Function} {} swig_typequery(@var{string})\n\ +Return @var{string} if it is a recognised SWIG-wrapped C/C++ type name;\n\ +otherwise return `'.\n\ +@end deftypefn"; + +DEFUN_DLD( swig_typequery, args, nargout, swig_typequery_usage ) { + if (args.length() != 1 || !args(0).is_string()) { + error("swig_typequery: must be called with single string argument"); + return octave_value_list(); + } + swig_module_info *module = SWIG_GetModule(0); + swig_type_info *type = SWIG_TypeQueryModule(module, module, args(0).string_value().c_str()); + if (!type) + return octave_value(""); + return octave_value(type->name); +} + +static const char *const swig_this_usage = "-*- texinfo -*- \n\ +@deftypefn {Loadable Function} {} swig_this(@var{swigref})\n\ +Return the underlying C/C++ pointer of a SWIG-wrapped object.\n\ +@end deftypefn"; + +DEFUN_DLD( swig_this, args, nargout, swig_this_usage ) { + if (args.length() != 1) { + error("swig_this: must be called with only a single object"); + return octave_value_list(); + } + if (args(0).is_matrix_type() && args(0).rows() == 0 && args(0).columns() == 0) + return octave_value(octave_uint64(0)); + octave_swig_type *ost = Swig::swig_value_deref(args(0)); + if (!ost) { + error("swig_this: object is not a swig_ref"); + return octave_value_list(); + } + return octave_value(octave_uint64((unsigned long long) ost->swig_this())); +} + +static const char *const SWIG_name_usage = "-*- texinfo -*- \n\ +@deftypefn {Loadable Module} {} " SWIG_name_d "\n\ +Loads the SWIG-generated module `" SWIG_name_d "'.\n\ +@end deftypefn"; + +DEFUN_DLD( SWIG_name, args, nargout, SWIG_name_usage ) { + + static octave_swig_type* module_ns = 0; + + // workaround to prevent octave seg-faulting on exit: set Octave exit function + // octave_exit to _Exit, which exits immediately without trying to cleanup memory. + // definitely affects version 3.2.*, not sure about 3.3.*, seems to be fixed in + // version 3.4.* and above. can be turned off with macro definition. +#ifndef SWIG_OCTAVE_NO_SEGFAULT_HACK +#if SWIG_OCTAVE_PREREQ(3,2,0) && !SWIG_OCTAVE_PREREQ(3,4,1) + octave_exit = ::_Exit; +#endif +#endif + + // check for no input and output args + if (args.length() != 0 || nargout != 0) { + print_usage(); + return octave_value_list(); + } + + // create module on first function call + if (!module_ns) { + + // workaround bug in octave where installing global variable of custom type and then + // exiting without explicitly clearing the variable causes octave to segfault. +#if SWIG_OCTAVE_PREREQ(3,2,0) + octave_value_list eval_args; + eval_args.append("base"); + eval_args.append("function __swig_atexit__; " + " if mislocked() " + " clear -all; " + " else " + " mlock(); " + " endif; " + "endfunction; " + "__swig_atexit__; " + "atexit(\"__swig_atexit__\", false); " + "atexit(\"__swig_atexit__\")"); + feval("evalin", eval_args, 0); +#endif + + octave_swig_ref::register_type(); + octave_swig_packed::register_type(); + SWIG_InitializeModule(0); + SWIG_PropagateClientData(); + + octave_function *me = octave_call_stack::current(); + + if (!SWIG_Octave_InstallFunction(me, "swig_type")) { + return octave_value_list(); + } + if (!SWIG_Octave_InstallFunction(me, "swig_typequery")) { + return octave_value_list(); + } + if (!SWIG_Octave_InstallFunction(me, "swig_this")) { + return octave_value_list(); + } + if (!SWIG_Octave_InstallFunction(me, "subclass")) { + return octave_value_list(); + } + + octave_swig_type* cvar_ns=0; + if (std::string(SWIG_global_name) != ".") { + cvar_ns=new octave_swig_type; + for (int j=0;swig_globals[j].name;++j) + if (swig_globals[j].get_method) + cvar_ns->assign(swig_globals[j].name,&swig_globals[j]); + } + + module_ns=new octave_swig_type(0, 0, 0, true); + if (std::string(SWIG_global_name) != ".") { + module_ns->assign(SWIG_global_name,Swig::swig_value_ref(cvar_ns)); + } + else { + for (int j=0;swig_globals[j].name;++j) + if (swig_globals[j].get_method) + module_ns->assign(swig_globals[j].name,&swig_globals[j]); + } + for (int j=0;swig_globals[j].name;++j) + if (swig_globals[j].method) + module_ns->assign(swig_globals[j].name,&swig_globals[j]); + + // * need better solution here; swig_type -> octave_class mapping is + // * really n-to-1, in some cases such as template partial spec, etc. + // * see failing tests. + for (int j=0;swig_types[j];++j) + if (swig_types[j]->clientdata) { + swig_octave_class* c=(swig_octave_class*)swig_types[j]->clientdata; + module_ns->assign(c->name, + Swig::swig_value_ref + (new octave_swig_type(0,swig_types[j]))); + } + + if (!SWIG_init_user(module_ns)) { + delete module_ns; + module_ns=0; + return octave_value_list(); + } + + SWIG_InstallOps(octave_swig_ref::static_type_id()); + + octave_swig_type::swig_member_const_iterator mb; + for (mb = module_ns->swig_members_begin(); mb != module_ns->swig_members_end(); ++mb) { + if (mb->second.first && mb->second.first->method) { + if (!SWIG_Octave_InstallFunction(me, mb->first)) { + return octave_value_list(); + } + } + } + +#if !SWIG_OCTAVE_PREREQ(3,2,0) + mlock(me->name()); +#else + mlock(); +#endif + + } + + octave_swig_type::swig_member_const_iterator mb; + for (mb = module_ns->swig_members_begin(); mb != module_ns->swig_members_end(); ++mb) { + if (mb->second.second.is_defined()) { + SWIG_Octave_SetGlobalValue(mb->first, mb->second.second); + SWIG_Octave_LinkGlobalValue(mb->first); + } + } + + SWIG_Octave_SetGlobalValue(SWIG_name_d, module_ns->as_value()); + SWIG_Octave_LinkGlobalValue(SWIG_name_d); + + return octave_value_list(); + +} + +%} diff --git a/Lib/octave/octstdcommon.swg b/Lib/octave/octstdcommon.swg index 56379ed73..96923f40a 100644 --- a/Lib/octave/octstdcommon.swg +++ b/Lib/octave/octstdcommon.swg @@ -1,258 +1,226 @@ -// -// octstdcommon.swg - Octave common STL code -// - -%fragment("StdTraits", "header", fragment = "StdTraitsCommon") +%fragment("StdTraits","header",fragment="StdTraitsCommon") { +namespace swig { +// Traits that provides the from method + template struct traits_from_ptr { + static octave_value from(Type *val, int owner = 0) { + return SWIG_NewPointerObj(val, type_info(), owner); + } + }; - namespace swig - { - - // Traits that provides the from method - template struct traits_from_ptr { - static octave_value from(Type* val, int owner = 0) { - return SWIG_NewPointerObj(val, type_info(), owner); - } - }; - - template struct traits_from { - static octave_value from(const Type& val) { - return traits_from_ptr::from(new Type(val), 1); - } - }; + template struct traits_from { + static octave_value from(const Type& val) { + return traits_from_ptr::from(new Type(val), 1); + } + }; - template struct traits_from { - static octave_value from(Type* val) { - return traits_from_ptr::from(val, 0); - } - }; + template struct traits_from { + static octave_value from(Type* val) { + return traits_from_ptr::from(val, 0); + } + }; - template struct traits_from { - static octave_value from(const Type* val) { - return traits_from_ptr::from(const_cast(val), 0); - } - }; + template struct traits_from { + static octave_value from(const Type* val) { + return traits_from_ptr::from(const_cast(val), 0); + } + }; - template - inline octave_value from(const Type& val) - { - return traits_from::from(val); - } + template + inline octave_value from(const Type& val) { + return traits_from::from(val); + } - template - inline octave_value from_ptr(Type* val, int owner) - { - return traits_from_ptr::from(val, owner); - } + template + inline octave_value from_ptr(Type* val, int owner) { + return traits_from_ptr::from(val, owner); + } // Traits that provides the asval/as/check method - template - struct traits_asptr { - static int asptr(const octave_value& obj, Type** val) { - Type* p; - int res = SWIG_ConvertPtr(obj, (void**) &p, type_info(), 0); - if (SWIG_IsOK(res)) { - if (val) { - *val = p; - } - } - return res; + template + struct traits_asptr { + static int asptr(const octave_value& obj, Type **val) { + Type *p; + int res = SWIG_ConvertPtr(obj, (void**)&p, type_info(), 0); + if (SWIG_IsOK(res)) { + if (val) *val = p; } - }; - - template - inline int asptr(const octave_value& obj, Type** vptr) - { - return traits_asptr::asptr(obj, vptr); + return res; } + }; - template - struct traits_asval { - static int asval(const octave_value& obj, Type* val) { - if (val) { - Type* p = 0; - int res = traits_asptr::asptr(obj, &p); - if (!SWIG_IsOK(res)) { - return res; - } - if (p) { - typedef typename noconst_traits::noconst_type noconst_type; - * (const_cast(val)) = *p; - if (SWIG_IsNewObj(res)) { - %delete(p); - res = SWIG_DelNewMask(res); - } - return res; - } else { - return SWIG_ERROR; - } - } else { - return traits_asptr::asptr(obj, (Type**)(0)); - } - } - }; + template + inline int asptr(const octave_value& obj, Type **vptr) { + return traits_asptr::asptr(obj, vptr); + } - template struct traits_asval { - static int asval(const octave_value& obj, Type** val) { - if (val) { - typedef typename noconst_traits::noconst_type noconst_type; - noconst_type* p = 0; - int res = traits_asptr::asptr(obj, &p); - if (SWIG_IsOK(res)) { - * (const_cast(val)) = p; - } - return res; - } else { - return traits_asptr::asptr(obj, (Type**)(0)); - } + template + struct traits_asval { + static int asval(const octave_value& obj, Type *val) { + if (val) { + Type *p = 0; + int res = traits_asptr::asptr(obj, &p); + if (!SWIG_IsOK(res)) return res; + if (p) { + typedef typename noconst_traits::noconst_type noconst_type; + *(const_cast(val)) = *p; + if (SWIG_IsNewObj(res)){ + %delete(p); + res = SWIG_DelNewMask(res); + } + return res; + } else { + return SWIG_ERROR; + } + } else { + return traits_asptr::asptr(obj, (Type **)(0)); } - }; - - template - inline int asval(const octave_value& obj, Type* val) - { - return traits_asval::asval(obj, val); } - - template - struct traits_as { - static Type as(const octave_value& obj, bool throw_error) { - Type v; - int res = asval(obj, &v); - if (!obj.is_defined() || !SWIG_IsOK(res)) { - if (!SWIG_Octave_ErrorOccurred()) { - %type_error(swig::type_name()); - } - if (throw_error) { - throw std::invalid_argument("bad type"); - } - } - return v; + }; + + template struct traits_asval { + static int asval(const octave_value& obj, Type **val) { + if (val) { + typedef typename noconst_traits::noconst_type noconst_type; + noconst_type *p = 0; + int res = traits_asptr::asptr(obj, &p); + if (SWIG_IsOK(res)) { + *(const_cast(val)) = p; + } + return res; + } else { + return traits_asptr::asptr(obj, (Type **)(0)); } - }; + } + }; + + template + inline int asval(const octave_value& obj, Type *val) { + return traits_asval::asval(obj, val); + } - template - struct traits_as { - static Type as(const octave_value& obj, bool throw_error) { - Type* v = 0; - int res = traits_asptr::asptr(obj, &v); - if (SWIG_IsOK(res) && v) { - if (SWIG_IsNewObj(res)) { - Type r(*v); - %delete(v); - return r; - } else { - return *v; - } - } else { - // Uninitialized return value, no Type() constructor required. - static Type* v_def = (Type*) malloc(sizeof(Type)); - if (!SWIG_Octave_ErrorOccurred()) { - %type_error(swig::type_name()); - } - if (throw_error) { - throw std::invalid_argument("bad type"); - } - memset(v_def, 0, sizeof(Type)); - return *v_def; - } + template + struct traits_as { + static Type as(const octave_value& obj, bool throw_error) { + Type v; + int res = asval(obj, &v); + if (!obj.is_defined() || !SWIG_IsOK(res)) { + if (!Octave_Error_Occurred()) { + %type_error(swig::type_name()); + } + if (throw_error) throw std::invalid_argument("bad type"); } - }; - - template - struct traits_as { - static Type* as(const octave_value& obj, bool throw_error) { - Type* v = 0; - int res = traits_asptr::asptr(obj, &v); - if (SWIG_IsOK(res)) { - return v; - } else { - if (!SWIG_Octave_ErrorOccurred()) { - %type_error(swig::type_name()); - } - if (throw_error) { - throw std::invalid_argument("bad type"); - } - return 0; - } + return v; + } + }; + + template + struct traits_as { + static Type as(const octave_value& obj, bool throw_error) { + Type *v = 0; + int res = traits_asptr::asptr(obj, &v); + if (SWIG_IsOK(res) && v) { + if (SWIG_IsNewObj(res)) { + Type r(*v); + %delete(v); + return r; + } else { + return *v; + } + } else { + // Uninitialized return value, no Type() constructor required. + static Type *v_def = (Type*) malloc(sizeof(Type)); + if (!Octave_Error_Occurred()) { + %type_error(swig::type_name()); + } + if (throw_error) throw std::invalid_argument("bad type"); + memset(v_def,0,sizeof(Type)); + return *v_def; } - }; - - template - inline Type as(const octave_value& obj, bool te = false) - { - return traits_as::category>::as(obj, te); } - - template - struct traits_check { - static bool check(const octave_value& obj) { - int res = asval(obj, (Type*)(0)); - return SWIG_IsOK(res) ? true : false; + }; + + template + struct traits_as { + static Type* as(const octave_value& obj, bool throw_error) { + Type *v = 0; + int res = traits_asptr::asptr(obj, &v); + if (SWIG_IsOK(res)) { + return v; + } else { + if (!Octave_Error_Occurred()) { + %type_error(swig::type_name()); + } + if (throw_error) throw std::invalid_argument("bad type"); + return 0; } - }; + } + }; + + template + inline Type as(const octave_value& obj, bool te = false) { + return traits_as::category>::as(obj, te); + } - template - struct traits_check { - static bool check(const octave_value& obj) { - int res = asptr(obj, (Type**)(0)); - return SWIG_IsOK(res) ? true : false; - } - }; + template + struct traits_check { + static bool check(const octave_value& obj) { + int res = asval(obj, (Type *)(0)); + return SWIG_IsOK(res) ? true : false; + } + }; - template - inline bool check(const octave_value& obj) - { - return traits_check::category>::check(obj); + template + struct traits_check { + static bool check(const octave_value& obj) { + int res = asptr(obj, (Type **)(0)); + return SWIG_IsOK(res) ? true : false; } + }; + template + inline bool check(const octave_value& obj) { + return traits_check::category>::check(obj); } - +} } -%define %specialize_std_container(Type, Check, As, From) -%header %{ - - namespace swig { - - template <> - struct traits_asval { - typedef Type value_type; - static int asval(const octave_value& obj, value_type* val) { - if (Check(obj)) { - if (val) { - *val = As(obj); - } - return SWIG_OK; - } - return SWIG_ERROR; - } - }; - - template <> - struct traits_from { - typedef Type value_type; - static octave_value from(const value_type& val) { - return From(val); - } - }; - - template <> - struct traits_check { - static int check(const octave_value& obj) { - int res = Check(obj); - return obj && res ? res : 0; +%define %specialize_std_container(Type,Check,As,From) +%{ +namespace swig { + template <> struct traits_asval { + typedef Type value_type; + static int asval(const octave_value& obj, value_type *val) { + if (Check(obj)) { + if (val) *val = As(obj); + return SWIG_OK; } - }; - - } + return SWIG_ERROR; + } + }; + template <> struct traits_from { + typedef Type value_type; + static octave_value from(const value_type& val) { + return From(val); + } + }; + template <> + struct traits_check { + static int check(const octave_value& obj) { + int res = Check(obj); + return obj && res ? res : 0; + } + }; +} %} %enddef + #define specialize_std_vector(Type,Check,As,From) %specialize_std_container(%arg(Type),Check,As,From) #define specialize_std_list(Type,Check,As,From) %specialize_std_container(%arg(Type),Check,As,From) #define specialize_std_deque(Type,Check,As,From) %specialize_std_container(%arg(Type),Check,As,From) #define specialize_std_set(Type,Check,As,From) %specialize_std_container(%arg(Type),Check,As,From) #define specialize_std_multiset(Type,Check,As,From) %specialize_std_container(%arg(Type),Check,As,From) + diff --git a/Lib/octave/octtypemaps.swg b/Lib/octave/octtypemaps.swg index b241ad400..4acf8e076 100644 --- a/Lib/octave/octtypemaps.swg +++ b/Lib/octave/octtypemaps.swg @@ -1,45 +1,46 @@ -// -// octtypemaps.swg - Octave typemaps -// // Include fundamental fragment definitions %include -// Look for user fragments file +// Look for user fragments file. %include // Octave fragments for primitive types %include +// Octave fragments for char* strings +//%include + + #ifndef SWIG_DIRECTOR_TYPEMAPS #define SWIG_DIRECTOR_TYPEMAPS #endif // Octave types -#define SWIG_Object octave_value -#define VOID_Object octave_value() +#define SWIG_Object octave_value +#define VOID_Object octave_value() +/* // Octave allows implicit conversion -//#define %implicitconv_flag $implicitconv +#define %implicitconv_flag $implicitconv +*/ -// Append output -#define SWIG_AppendOutput(result, obj) SWIG_Octave_AppendOutput(result, obj) +// append output +#define SWIG_AppendOutput(result, obj) SWIG_Octave_AppendOutput(result, obj) -// Set constant -#define SWIG_SetConstant(name, obj) SWIG_Octave_SetConstant(module_ns,name,obj) +// set constant +#define SWIG_SetConstant(name, obj) SWIG_Octave_SetConstant(module_ns,name,obj) -// Raise errors -#define SWIG_Octave_Raise(OBJ, TYPE, DESC) error("C++ side threw an exception of type " TYPE) -#define SWIG_Raise(obj, type, desc) SWIG_Octave_Raise(obj, type, desc) +// raise +#define SWIG_Octave_Raise(OBJ, TYPE, DESC) error("C++ side threw an exception of type " TYPE) +#define SWIG_Raise(obj, type, desc) SWIG_Octave_Raise(obj, type, desc) // Include the unified typemap library %include -// Typechecks for Octave types %typecheck(SWIG_TYPECHECK_SWIGOBJECT) SWIG_Object "$1 = (*$input).is_defined();"; %typecheck(SWIG_TYPECHECK_SWIGOBJECT) octave_value_list "$1 = true;"; -// Typemaps for Octave types %typemap(in) (octave_value_list varargs,...) { for (int j=$argnum-1;jappend($1); } @@ -67,3 +70,23 @@ %typemap(out,noblock=1) Cell { $result=$1; } + +/* +// Smart Pointers +%typemap(out,noblock=1) const SWIGTYPE & SMARTPOINTER { + $result = SWIG_NewPointerObj(%new_copy(*$1, $*ltype), $descriptor, SWIG_POINTER_OWN | %newpointer_flags); +} + +%typemap(ret) const SWIGTYPE & SMARTPOINTER, SWIGTYPE SMARTPOINTER { + octave_swig_type* lobj=Swig::swig_value_deref($result); + if (lobj) { + std::list idx; + idx.push_back(octave_value("__deref__")); + idx.push_back(octave_value_list()); + octave_value_list ovl(lobj->subsref(".(",idx)); + octave_swig_type* robj=ovl.length()>=1?Swig::swig_value_deref(ovl(0)):0; + if (robj && !error_state) + lobj->append(robj); + } +} +*/ diff --git a/Lib/octave/octuserdir.swg b/Lib/octave/octuserdir.swg index 164e08a36..ebb11b3a5 100644 --- a/Lib/octave/octuserdir.swg +++ b/Lib/octave/octuserdir.swg @@ -1,65 +1,70 @@ -// -// octuserdir.swg - Octave special user directives -// +/* ------------------------------------------------------------------------- + * Special user directives + * ------------------------------------------------------------------------- */ -// Document string directive -#define %docstring %feature("docstring") +/* ------------------------------------------------------------------------- */ +/* + Implicit Conversion using the C++ constructor mechanism +*/ -// Implicit conversion using the C++ constructor mechanism -#define %implicitconv %feature("implicitconv") +#define %implicitconv %feature("implicitconv") #define %noimplicitconv %feature("implicitconv", "0") #define %clearimplicitconv %feature("implicitconv", "") -// %extend_smart_pointer: extend the smart pointer support. -// -// For example, if you have a smart pointer as: -// -// template class RCPtr { -// public: -// ... -// RCPtr(Type *p); -// Type * operator->() const; -// ... -// }; -// -// you use the %extend_smart_pointer directive as: -// -// %extend_smart_pointer(RCPtr); -// %template(RCPtr_A) RCPtr; -// -// then, if you have something like: -// -// RCPtr make_ptr(); -// int foo(A *); -// -// you can do the following: -// -// a = make_ptr(); -// b = foo(a); -// -// ie, swig will accept a RCPtr object where a 'A *' is -// expected. -// -// Also, when using vectors -// -// %extend_smart_pointer(RCPtr); -// %template(RCPtr_A) RCPtr; -// %template(vector_A) std::vector >; -// -// you can type -// -// a = A(); -// v = vector_A(2) -// v[0] = a -// -// ie, an 'A *' object is accepted, via implicit conversion, -// where a RCPtr object is expected. Additionally -// -// x = v[0] -// -// returns (and sets 'x' as) a copy of v[0], making reference -// counting possible and consistent. -// + +/* ------------------------------------------------------------------------- */ +/* + %extend_smart_pointer extend the smart pointer support. + + For example, if you have a smart pointer as: + + template class RCPtr { + public: + ... + RCPtr(Type *p); + Type * operator->() const; + ... + }; + + you use the %extend_smart_pointer directive as: + + %extend_smart_pointer(RCPtr); + %template(RCPtr_A) RCPtr; + + then, if you have something like: + + RCPtr make_ptr(); + int foo(A *); + + you can do the following: + + a = make_ptr(); + b = foo(a); + + ie, swig will accept a RCPtr object where a 'A *' is + expected. + + Also, when using vectors + + %extend_smart_pointer(RCPtr); + %template(RCPtr_A) RCPtr; + %template(vector_A) std::vector >; + + you can type + + a = A(); + v = vector_A(2) + v[0] = a + + ie, an 'A *' object is accepted, via implicit conversion, + where a RCPtr object is expected. Additionally + + x = v[0] + + returns (and sets 'x' as) a copy of v[0], making reference + counting possible and consistent. +*/ + %define %extend_smart_pointer(Type...) %implicitconv Type; %apply const SWIGTYPE& SMARTPOINTER { const Type& }; diff --git a/Lib/octave/std_alloc.i b/Lib/octave/std_alloc.i index 1013e6829..35dc051be 100644 --- a/Lib/octave/std_alloc.i +++ b/Lib/octave/std_alloc.i @@ -1,5 +1 @@ -// -// std_alloc.i - STL allocator support -// - %include diff --git a/Lib/octave/std_basic_string.i b/Lib/octave/std_basic_string.i index 113e10826..19712e8d0 100644 --- a/Lib/octave/std_basic_string.i +++ b/Lib/octave/std_basic_string.i @@ -1,8 +1,4 @@ -// -// std_basic_string.i - STL string support -// - -#if !defined(SWIG_STD_STRING) +#if !defined(SWIG_STD_STRING) #define SWIG_STD_BASIC_STRING #define SWIG_STD_MODERN_STL @@ -10,25 +6,28 @@ #define %swig_basic_string(Type...) %swig_sequence_methods_val(Type) -%fragment(SWIG_AsPtr_frag(std::basic_string), "header", fragment = "SWIG_AsCharPtrAndSize") + +%fragment(SWIG_AsPtr_frag(std::basic_string),"header", + fragment="SWIG_AsCharPtrAndSize") { +SWIGINTERN int +SWIG_AsPtr(std::basic_string)(octave_value obj, std::string **val) { - SWIGINTERN int SWIG_AsPtr(std::basic_string)(octave_value obj, std::string** val) { - if (obj.is_string()) { - if (val) { - *val = new std::string(obj.string_value()); - } - return SWIG_NEWOBJ; - } - if (val) { - error("a string is expected"); - } - return 0; + if (obj.is_string()) { + if (val) + *val = new std::string(obj.string_value()); + return SWIG_NEWOBJ; } + if (val) + error("a string is expected"); + return 0; +} } -%fragment(SWIG_From_frag(std::basic_string), "header", fragment = "SWIG_FromCharPtrAndSize") -{ - SWIGINTERNINLINE octave_value SWIG_From(std::basic_string)(const std::string & s) { +%fragment(SWIG_From_frag(std::basic_string),"header", + fragment="SWIG_FromCharPtrAndSize") { +SWIGINTERNINLINE octave_value + SWIG_From(std::basic_string)(const std::string& s) + { return SWIG_FromCharPtrAndSize(s.data(), s.size()); } } @@ -36,54 +35,51 @@ %ignore std::basic_string::operator +=; %include - %typemaps_asptrfromn(%checkcode(STRING), std::basic_string); #endif + #if !defined(SWIG_STD_WSTRING) -%fragment(SWIG_AsPtr_frag(std::basic_string), "header", fragment = "SWIG_AsWCharPtrAndSize") -{ - SWIGINTERN int SWIG_AsPtr(std::basic_string)(PyObject * obj, std::wstring** val) { - static swig_type_info* string_info = SWIG_TypeQuery("std::basic_string *"); - std::wstring* vptr; - if (SWIG_ConvertPtr(obj, (void**) &vptr, string_info, 0) == SWIG_OK) { - if (val) { - *val = vptr; - } +%fragment(SWIG_AsPtr_frag(std::basic_string),"header", + fragment="SWIG_AsWCharPtrAndSize") { +SWIGINTERN int + SWIG_AsPtr(std::basic_string)(PyObject* obj, std::wstring **val) + { + static swig_type_info* string_info = + SWIG_TypeQuery("std::basic_string *"); + std::wstring *vptr; + if (SWIG_ConvertPtr(obj, (void**)&vptr, string_info, 0) == SWIG_OK) { + if (val) *val = vptr; return SWIG_OLDOBJ; } else { PyErr_Clear(); - wchar_t* buf = 0 ; - size_t size = 0; - int alloc = 0; + wchar_t *buf = 0 ; size_t size = 0; int alloc = 0; if (SWIG_AsWCharPtrAndSize(obj, &buf, &size, &alloc) == SWIG_OK) { - if (buf) { - if (val) { - *val = new std::wstring(buf, size - 1); - } - if (alloc == SWIG_NEWOBJ) { - %delete_array(buf); - } - return SWIG_NEWOBJ; - } + if (buf) { + if (val) *val = new std::wstring(buf, size - 1); + if (alloc == SWIG_NEWOBJ) %delete_array(buf); + return SWIG_NEWOBJ; + } } else { - PyErr_Clear(); - } + PyErr_Clear(); + } if (val) { - SWIG_PYTHON_THREAD_BEGIN_BLOCK; - PyErr_SetString(PyExc_TypeError, "a wstring is expected"); - SWIG_PYTHON_THREAD_END_BLOCK; + SWIG_PYTHON_THREAD_BEGIN_BLOCK; + PyErr_SetString(PyExc_TypeError,"a wstring is expected"); + SWIG_PYTHON_THREAD_END_BLOCK; } return 0; } } } -%fragment(SWIG_From_frag(std::basic_string), "header", fragment = "SWIG_FromWCharPtrAndSize") -{ - SWIGINTERNINLINE PyObject* SWIG_From(std::basic_string)(const std::wstring & s) { +%fragment(SWIG_From_frag(std::basic_string),"header", + fragment="SWIG_FromWCharPtrAndSize") { +SWIGINTERNINLINE PyObject* + SWIG_From(std::basic_string)(const std::wstring& s) + { return SWIG_FromWCharPtrAndSize(s.data(), s.size()); } } diff --git a/Lib/octave/std_carray.i b/Lib/octave/std_carray.i index dcf317e80..e69de29bb 100644 --- a/Lib/octave/std_carray.i +++ b/Lib/octave/std_carray.i @@ -1,3 +0,0 @@ -// -// std_carray.i -// diff --git a/Lib/octave/std_char_traits.i b/Lib/octave/std_char_traits.i index d05f7b42c..bf4e6c47d 100644 --- a/Lib/octave/std_char_traits.i +++ b/Lib/octave/std_char_traits.i @@ -1,5 +1 @@ -// -// std_char_traits.i - STL character traits -// - %include diff --git a/Lib/octave/std_common.i b/Lib/octave/std_common.i index ebefc5942..9aebf7f45 100644 --- a/Lib/octave/std_common.i +++ b/Lib/octave/std_common.i @@ -1,82 +1,72 @@ -// -// std_common.i - Common STL support code -// - %include %include + // Generate the traits for a 'primitive' type, such as 'double', // for which the SWIG_AsVal and SWIG_From methods are already defined. -%define %traits_ptypen(Type...) -%fragment(SWIG_Traits_frag(Type), "header", fragment = SWIG_AsVal_frag(Type), fragment = SWIG_From_frag(Type), fragment = "StdTraits") -{ - - namespace swig - { - - template <> struct traits { - typedef value_category category; - static const char* type_name() { - return #Type; } - }; - - template <> struct traits_asval { - typedef Type value_type; - static int asval(octave_value obj, value_type* val) { - return SWIG_AsVal(Type)(obj, val); - } - }; - - template <> struct traits_from { - typedef Type value_type; - static octave_value from(const value_type& val) { - return SWIG_From(Type)(val); - } - }; - - } +%define %traits_ptypen(Type...) + %fragment(SWIG_Traits_frag(Type),"header", + fragment=SWIG_AsVal_frag(Type), + fragment=SWIG_From_frag(Type), + fragment="StdTraits") { +namespace swig { + template <> struct traits { + typedef value_category category; + static const char* type_name() { return #Type; } + }; + template <> struct traits_asval { + typedef Type value_type; + static int asval(octave_value obj, value_type *val) { + return SWIG_AsVal(Type)(obj, val); + } + }; + template <> struct traits_from { + typedef Type value_type; + static octave_value from(const value_type& val) { + return SWIG_From(Type)(val); + } + }; +} } %enddef -// Traits for enums. This is bit of a sneaky trick needed because a generic template specialization of enums -// is not possible (unless using template meta-programming which SWIG doesn't support because of the explicit -// instantiations required using %template). The STL containers define the 'front' method and the typemap -// below is used whenever the front method is wrapped returning an enum. This typemap simply picks up the -// standard enum typemap, but additionally drags in a fragment containing the traits_asval and traits_from -// required in the generated code for enums. +/* Traits for enums. This is bit of a sneaky trick needed because a generic template specialization of enums + is not possible (unless using template meta-programming which SWIG doesn't support because of the explicit + instantiations required using %template). The STL containers define the 'front' method and the typemap + below is used whenever the front method is wrapped returning an enum. This typemap simply picks up the + standard enum typemap, but additionally drags in a fragment containing the traits_asval and traits_from + required in the generated code for enums. */ %define %traits_enum(Type...) -%fragment("SWIG_Traits_enum_" {Type}, "header", fragment = SWIG_AsVal_frag(int), fragment = SWIG_From_frag(int), fragment = "StdTraits") { - - namespace swig - { - - template <> struct traits_asval { - typedef Type value_type; - static int asval(octave_value obj, value_type* val) { - return SWIG_AsVal(int)(obj, (int*) val); - } - }; - - template <> struct traits_from { - typedef Type value_type; - static octave_value from(const value_type& val) { - return SWIG_From(int)((int) val); - } - }; - - } - + %fragment("SWIG_Traits_enum_"{Type},"header", + fragment=SWIG_AsVal_frag(int), + fragment=SWIG_From_frag(int), + fragment="StdTraits") { +namespace swig { + template <> struct traits_asval { + typedef Type value_type; + static int asval(octave_value obj, value_type *val) { + return SWIG_AsVal(int)(obj, (int *)val); + } + }; + template <> struct traits_from { + typedef Type value_type; + static octave_value from(const value_type& val) { + return SWIG_From(int)((int)val); + } + }; } - -%typemap(out, fragment = "SWIG_Traits_enum_" {Type}) const enum SWIGTYPE& front %{ - $typemap(out, const enum SWIGTYPE&) -%} - +} +%typemap(out, fragment="SWIG_Traits_enum_"{Type}) const enum SWIGTYPE& front %{$typemap(out, const enum SWIGTYPE&)%} %enddef + %include -// Generates the traits for all the known primitive C++ types (int, double, ...) +// +// Generates the traits for all the known primitive +// C++ types (int, double, ...) +// %apply_cpptypes(%traits_ptypen); + diff --git a/Lib/octave/std_complex.i b/Lib/octave/std_complex.i index 0b4627078..771728b9d 100644 --- a/Lib/octave/std_complex.i +++ b/Lib/octave/std_complex.i @@ -1,17 +1,22 @@ -// -// std_complex.i - STL complex typemaps -// +/* + * STD C++ complex typemaps + */ %include -%header %{ -#include +%{ +#include %} -// Define the complex as/from converters +/* defining the complex as/from converters */ + %swig_cplxdbl_convn(std::complex, std::complex, std::real, std::imag) %swig_cplxflt_convn(std::complex, std::complex, std::real, std::imag) -// Define the typemaps +/* defining the typemaps */ + %typemaps_primitive(%checkcode(CPLXDBL), std::complex); %typemaps_primitive(%checkcode(CPLXFLT), std::complex); + + + diff --git a/Lib/octave/std_container.i b/Lib/octave/std_container.i index 80abeb768..cab76452b 100644 --- a/Lib/octave/std_container.i +++ b/Lib/octave/std_container.i @@ -1,6 +1,2 @@ -// -// std_container.i - STL container support -// - %include %include diff --git a/Lib/octave/std_deque.i b/Lib/octave/std_deque.i index d5eb67db8..6866a610f 100644 --- a/Lib/octave/std_deque.i +++ b/Lib/octave/std_deque.i @@ -1,29 +1,22 @@ -// -// std_deque.i - STL deque support -// +// Deques -%fragment("StdDequeTraits", "header", fragment = "StdSequenceTraits") +%fragment("StdDequeTraits","header",fragment="StdSequenceTraits") %{ - - namespace swig - { - + namespace swig { template struct traits_asptr > { - static int asptr(octave_value obj, std::deque **vec) { - return traits_asptr_stdseq >::asptr(obj, vec); + static int asptr(octave_value obj, std::deque **vec) { + return traits_asptr_stdseq >::asptr(obj, vec); } }; template struct traits_from > { static octave_value from(const std::deque & vec) { - return traits_from_stdseq >::from(vec); + return traits_from_stdseq >::from(vec); } }; - } - %} #define %swig_deque_methods(Type...) %swig_sequence_methods(Type) diff --git a/Lib/octave/std_except.i b/Lib/octave/std_except.i index 1f2987004..af98428f6 100644 --- a/Lib/octave/std_except.i +++ b/Lib/octave/std_except.i @@ -1,5 +1 @@ -// -// std_except.i - STL exception support -// - %include diff --git a/Lib/octave/std_list.i b/Lib/octave/std_list.i index 580d7d312..1421efaee 100644 --- a/Lib/octave/std_list.i +++ b/Lib/octave/std_list.i @@ -1,32 +1,26 @@ -// -// std_list.i - STL list support -// +// Lists -%fragment("StdListTraits", "header", fragment = "StdSequenceTraits") +%fragment("StdListTraits","header",fragment="StdSequenceTraits") %{ - - namespace swig - { - + namespace swig { template struct traits_asptr > { static int asptr(const octave_value& obj, std::list **lis) { - return traits_asptr_stdseq >::asptr(obj, lis); + return traits_asptr_stdseq >::asptr(obj, lis); } }; template struct traits_from > { - static octave_value* from(const std::list & vec) { - return traits_from_stdseq >::from(vec); + static octave_value *from(const std::list & vec) { + return traits_from_stdseq >::from(vec); } }; - } - %} #define %swig_list_methods(Type...) %swig_sequence_methods(Type) #define %swig_list_methods_val(Type...) %swig_sequence_methods_val(Type); %include + diff --git a/Lib/octave/std_map.i b/Lib/octave/std_map.i index 259bdaec3..7b85a548e 100644 --- a/Lib/octave/std_map.i +++ b/Lib/octave/std_map.i @@ -1,125 +1,156 @@ -// -// std_map.i - STL map support -// +// Maps %include -%fragment("StdMapCommonTraits", "header", fragment = "StdSequenceTraits") +%fragment("StdMapCommonTraits","header",fragment="StdSequenceTraits") { - - namespace swig - { - + namespace swig { template - struct from_key_oper { + struct from_key_oper + { typedef const ValueType& argument_type; typedef octave_value result_type; - result_type operator()(argument_type v) const { - return swig::from(v.first); + result_type operator()(argument_type v) const + { + return swig::from(v.first); } }; template - struct from_value_oper { + struct from_value_oper + { typedef const ValueType& argument_type; typedef octave_value result_type; - result_type operator()(argument_type v) const { - return swig::from(v.second); + result_type operator()(argument_type v) const + { + return swig::from(v.second); } }; template - struct OctMapIterator_T : OctIteratorClosed_T { + struct OctMapIterator_T : OctSwigIteratorClosed_T + { OctMapIterator_T(OutIterator curr, OutIterator first, OutIterator last, octave_value seq) - : OctIteratorClosed_T (curr, first, last, seq) { + : OctSwigIteratorClosed_T(curr, first, last, seq) + { } }; - template < class OutIterator, class FromOper = from_key_oper > - struct OctMapKeyIterator_T : OctMapIterator_T { + template > + struct OctMapKeyIterator_T : OctMapIterator_T + { OctMapKeyIterator_T(OutIterator curr, OutIterator first, OutIterator last, octave_value seq) - : OctMapIterator_T (curr, first, last, seq) { + : OctMapIterator_T(curr, first, last, seq) + { } }; template - inline OctIterator* make_output_key_iterator(const OutIter& current, const OutIter& begin, const OutIter& end, octave_value seq = octave_value()) + inline OctSwigIterator* + make_output_key_iterator(const OutIter& current, const OutIter& begin, const OutIter& end, octave_value seq = octave_value()) { - return new OctMapKeyIterator_T (current, begin, end, seq); + return new OctMapKeyIterator_T(current, begin, end, seq); } - template < class OutIterator, class FromOper = from_value_oper > - struct OctMapValueIterator_T : OctMapIterator_T { + template > + struct OctMapValueIterator_T : OctMapIterator_T + { OctMapValueIterator_T(OutIterator curr, OutIterator first, OutIterator last, octave_value seq) - : OctMapIterator_T (curr, first, last, seq) { + : OctMapIterator_T(curr, first, last, seq) + { } }; - + template - inline OctIterator* + inline OctSwigIterator* make_output_value_iterator(const OutIter& current, const OutIter& begin, const OutIter& end, octave_value seq = 0) { - return new OctMapValueIterator_T (current, begin, end, seq); + return new OctMapValueIterator_T(current, begin, end, seq); } - } - } -%fragment("StdMapTraits", "header", fragment = "StdMapCommonTraits") +%fragment("StdMapTraits","header",fragment="StdMapCommonTraits") { - - namespace swig - { - + namespace swig { template inline void - assign(const OctSeq& octseq, std::map *map) - { - typedef typename std::map::value_type value_type; + assign(const OctSeq& octseq, std::map *map) { + typedef typename std::map::value_type value_type; typename OctSeq::const_iterator it = octseq.begin(); - for (; it != octseq.end(); ++it) { - map->insert(value_type(it->first, it->second)); + for (;it != octseq.end(); ++it) { + map->insert(value_type(it->first, it->second)); } } template - struct traits_asptr > { - - typedef std::map map_type; - static int asptr(octave_value obj, map_type** val) { - // * todo - return SWIG_ERROR; - } - + struct traits_asptr > { + typedef std::map map_type; + static int asptr(octave_value obj, map_type **val) { + /* + int res = SWIG_ERROR; + if (PyDict_Check(obj)) { + SwigVar_PyObject items = PyObject_CallMethod(obj,(char *)"items",NULL); + res = traits_asptr_stdseq, std::pair >::asptr(items, val); + } else { + map_type *p; + res = SWIG_ConvertPtr(obj,(void**)&p,swig::type_info(),0); + if (SWIG_IsOK(res) && val) *val = p; + } + return res; + */ + return SWIG_ERROR; + } }; - + template - struct traits_from > { - typedef std::map map_type; + struct traits_from > { + typedef std::map map_type; typedef typename map_type::const_iterator const_iterator; typedef typename map_type::size_type size_type; - + static octave_value from(const map_type& map) { - // * todo - return octave_value(); + /* + swig_type_info *desc = swig::type_info(); + if (desc && desc->clientdata) { + return SWIG_NewPointerObj(new map_type(map), desc, SWIG_POINTER_OWN); + } else { + size_type size = map.size(); + int pysize = (size <= (size_type) INT_MAX) ? (int) size : -1; + if (pysize < 0) { + SWIG_PYTHON_THREAD_BEGIN_BLOCK; + PyErr_SetString(PyExc_OverflowError, + "map size not valid in python"); + SWIG_PYTHON_THREAD_END_BLOCK; + return NULL; + } + PyObject *obj = PyDict_New(); + for (const_iterator i= map.begin(); i!= map.end(); ++i) { + swig::SwigVar_PyObject key = swig::from(i->first); + swig::SwigVar_PyObject val = swig::from(i->second); + PyDict_SetItem(obj, key, val); + } + return obj; + } + */ + return octave_value(); } - }; - } - } %define %swig_map_common(Map...) -%swig_sequence_iterator(Map); -%swig_container_methods(Map); + %swig_sequence_iterator(Map); + %swig_container_methods(Map); %enddef %define %swig_map_methods(Map...) -%swig_map_common(Map) + %swig_map_common(Map) %enddef + %include diff --git a/Lib/octave/std_pair.i b/Lib/octave/std_pair.i index ac2384714..ab028d144 100644 --- a/Lib/octave/std_pair.i +++ b/Lib/octave/std_pair.i @@ -1,145 +1,129 @@ -// -// std_pair.i - STL pair support -// +// Pairs %include //#define SWIG_STD_PAIR_ASVAL -%fragment("StdPairTraits", "header", fragment = "StdTraits") -{ - namespace swig - { - +%fragment("StdPairTraits","header",fragment="StdTraits") { + namespace swig { #ifdef SWIG_STD_PAIR_ASVAL - template - struct traits_asval > { - - typedef std::pair value_type; - - static int get_pair(const octave_value& first, octave_value second, std::pair *val) { - if (val) { - T* pfirst = & (val->first); - int res1 = swig::asval(first, pfirst); - if (!SWIG_IsOK(res1)) { - return res1; - } - U* psecond = & (val->second); - int res2 = swig::asval(second, psecond); - if (!SWIG_IsOK(res2)) { - return res2; - } - return res1 > res2 ? res1 : res2; - } else { - T* pfirst = 0; - int res1 = swig::asval(first, pfirst); - if (!SWIG_IsOK(res1)) { - return res1; - } - U* psecond = 0; - int res2 = swig::asval((PyObject*) second, psecond); - if (!SWIG_IsOK(res2)) { - return res2; - } - return res1 > res2 ? res1 : res2; - } + struct traits_asval > { + typedef std::pair value_type; + + static int get_pair(const octave_value& first, octave_value second, + std::pair *val) + { + if (val) { + T *pfirst = &(val->first); + int res1 = swig::asval(first, pfirst); + if (!SWIG_IsOK(res1)) + return res1; + U *psecond = &(val->second); + int res2 = swig::asval(second, psecond); + if (!SWIG_IsOK(res2)) + return res2; + return res1 > res2 ? res1 : res2; + } else { + T *pfirst = 0; + int res1 = swig::asval(first, pfirst); + if (!SWIG_IsOK(res1)) + return res1; + U *psecond = 0; + int res2 = swig::asval((PyObject*)second, psecond); + if (!SWIG_IsOK(res2)) + return res2; + return res1 > res2 ? res1 : res2; + } } - static int asval(const octave_value& obj, std::pair *val) { - if (obj.is_cell()) { - Cell c = obj.cell_value(); - if (c.numel() < 2) { - error("pair from Cell array requires at least two elements"); - return SWIG_ERROR; - } - return get_pair(c(0), c(1), val); - } else { - value_type* p; - int res = SWIG_ConvertPtr(obj, (void**) &p, swig::type_info(), 0); - if (SWIG_IsOK(res) && val) { - *val = *p; - } - return res; - } - return SWIG_ERROR; + static int asval(const octave_value& obj, std::pair *val) { + if (obj.is_cell()) { + Cell c=obj.cell_value(); + if (c.numel()<2) { + error("pair from Cell array requires at least two elements"); + return SWIG_ERROR; + } + return get_pair(c(0),c(1),val); + } else { + value_type *p; + int res = SWIG_ConvertPtr(obj,(void**)&p,swig::type_info(),0); + if (SWIG_IsOK(res) && val) + *val = *p; + return res; + } + return SWIG_ERROR; } }; #else - template - struct traits_asptr > { - typedef std::pair value_type; - - static int get_pair(const octave_value& first, octave_value second, std::pair **val) { - if (val) { - value_type* vp = %new_instance(std::pair); - T* pfirst = & (vp->first); - int res1 = swig::asval(first, pfirst); - if (!SWIG_IsOK(res1)) { - return res1; - } - U* psecond = & (vp->second); - int res2 = swig::asval(second, psecond); - if (!SWIG_IsOK(res2)) { - return res2; - } - *val = vp; - return SWIG_AddNewMask(res1 > res2 ? res1 : res2); - } else { - T* pfirst = 0; - int res1 = swig::asval(first, pfirst); - if (!SWIG_IsOK(res1)) { - return res1; - } - U* psecond = 0; - int res2 = swig::asval(second, psecond); - if (!SWIG_IsOK(res2)) { - return res2; - } - return res1 > res2 ? res1 : res2; - } - return SWIG_ERROR; + struct traits_asptr > { + typedef std::pair value_type; + + static int get_pair(const octave_value& first, octave_value second, + std::pair **val) + { + if (val) { + value_type *vp = %new_instance(std::pair); + T *pfirst = &(vp->first); + int res1 = swig::asval(first, pfirst); + if (!SWIG_IsOK(res1)) + return res1; + U *psecond = &(vp->second); + int res2 = swig::asval(second, psecond); + if (!SWIG_IsOK(res2)) + return res2; + *val = vp; + return SWIG_AddNewMask(res1 > res2 ? res1 : res2); + } else { + T *pfirst = 0; + int res1 = swig::asval(first, pfirst); + if (!SWIG_IsOK(res1)) + return res1; + U *psecond = 0; + int res2 = swig::asval(second, psecond); + if (!SWIG_IsOK(res2)) + return res2; + return res1 > res2 ? res1 : res2; + } + return SWIG_ERROR; } - static int asptr(const octave_value& obj, std::pair **val) { - if (obj.is_cell()) { - Cell c = obj.cell_value(); - if (c.numel() < 2) { - error("pair from Cell array requires at least two elements"); - return SWIG_ERROR; - } - return get_pair(c(0), c(1), val); - } else { - value_type* p; - int res = SWIG_ConvertPtr(obj, (void**) &p, swig::type_info(), 0); - if (SWIG_IsOK(res) && val) { - *val = p; - } - return res; - } - return SWIG_ERROR; + static int asptr(const octave_value& obj, std::pair **val) { + if (obj.is_cell()) { + Cell c=obj.cell_value(); + if (c.numel()<2) { + error("pair from Cell array requires at least two elements"); + return SWIG_ERROR; + } + return get_pair(c(0),c(1),val); + } else { + value_type *p; + int res = SWIG_ConvertPtr(obj,(void**)&p,swig::type_info(),0); + if (SWIG_IsOK(res) && val) + *val = p; + return res; + } + return SWIG_ERROR; } }; #endif - template - struct traits_from > { - static octave_value from(const std::pair& val) { - Cell c(1, 2); - c(0) = swig::from(val.first); - c(1) = swig::from(val.second); - return c; + struct traits_from > { + static octave_value from(const std::pair& val) { + Cell c(1,2); + c(0)=swig::from(val.first); + c(1)=swig::from(val.second); + return c; } }; - } - } %define %swig_pair_methods(pair...) %enddef %include + diff --git a/Lib/octave/std_string.i b/Lib/octave/std_string.i index e9ad572e0..dc1378ae6 100644 --- a/Lib/octave/std_string.i +++ b/Lib/octave/std_string.i @@ -1,5 +1 @@ -// -// std_string.i - STL string support -// - %include diff --git a/Lib/octave/std_vector.i b/Lib/octave/std_vector.i index 386aea2a4..2862b5e77 100644 --- a/Lib/octave/std_vector.i +++ b/Lib/octave/std_vector.i @@ -1,21 +1,19 @@ -// -// std_vector.i - STL vector support -// +// Vectors -%fragment("StdVectorTraits", "header", fragment = "StdSequenceTraits") +%fragment("StdVectorTraits","header",fragment="StdSequenceTraits") %{ namespace swig { template struct traits_asptr > { static int asptr(const octave_value& obj, std::vector **vec) { - return traits_asptr_stdseq >::asptr(obj, vec); + return traits_asptr_stdseq >::asptr(obj, vec); } }; - + template struct traits_from > { static octave_value from(const std::vector& vec) { - return traits_from_stdseq >::from(vec); + return traits_from_stdseq >::from(vec); } }; } @@ -25,3 +23,4 @@ #define %swig_vector_methods_val(Type...) %swig_sequence_methods_val(Type); %include + diff --git a/Lib/octave/stl.i b/Lib/octave/stl.i index 83714cb8f..b29f7d84d 100644 --- a/Lib/octave/stl.i +++ b/Lib/octave/stl.i @@ -1,7 +1,4 @@ -// -// stl.i - STL support -// - +/* initial STL definition. extended as needed in each language */ %include %include %include diff --git a/Lib/octave/typemaps.i b/Lib/octave/typemaps.i index c093399ed..1f9b9c432 100644 --- a/Lib/octave/typemaps.i +++ b/Lib/octave/typemaps.i @@ -1,5 +1 @@ -// -// typemaps.i - Standard typemaps -// - %include diff --git a/Source/Modules/octave.cxx b/Source/Modules/octave.cxx index ec54e8b99..3ec60c31d 100644 --- a/Source/Modules/octave.cxx +++ b/Source/Modules/octave.cxx @@ -205,8 +205,8 @@ public: Printf(f_runtime, "\n"); - Printf(s_global_tab, "\nstatic const struct SwigOctMember swig_globals[] = {\n"); - Printf(f_init, "SWIGINTERN bool SWIG_Octave_InitUser(SwigOctType* module_ns)\n{\n"); + Printf(s_global_tab, "\nstatic const struct swig_octave_member swig_globals[] = {\n"); + Printf(f_init, "static bool SWIG_init_user(octave_swig_type* module_ns)\n{\n"); if (!CPlusPlus) { Printf(f_header, "extern \"C\" {\n"); @@ -222,6 +222,10 @@ public: emit_doc_texinfo(); } + if (directorsEnabled()) { + Swig_insert_file("director.swg", f_runtime); + } + Printf(f_init, "return true;\n}\n"); Printf(s_global_tab, "{0,0,0,0,0}\n};\n"); @@ -586,7 +590,7 @@ public: int varargs = emit_isvarargs(l); char source[64]; - Printf(w->code, "if (!SWIG_Octave_CheckNumArgs(\"%s\",args.length(),%i,%i,%i)) " + Printf(w->code, "if (!SWIG_check_num_args(\"%s\",args.length(),%i,%i,%i)) " "{\n SWIG_fail;\n }\n", iname, num_arguments, num_required, varargs); if (constructor && num_arguments == 1 && num_required == 1) { @@ -807,9 +811,9 @@ public: Octave_begin_function(n, w->def, iname, wname, true); Wrapper_add_local(w, "argc", "int argc = args.length()"); - Printf(tmp, "SwigOctValueRef argv[%d] = {", maxargs); + Printf(tmp, "octave_value_ref argv[%d]={", maxargs); for (int j = 0; j < maxargs; ++j) { - Printf(tmp, "%sSwigOctValueRef(args,%d)", j ? "," : " ", j); + Printf(tmp, "%soctave_value_ref(args,%d)", j ? "," : " ", j); } Printf(tmp, "}"); Wrapper_add_local(w, "argv", tmp); @@ -845,7 +849,7 @@ public: String* setwname = Swig_name_wrapper(setname); Octave_begin_function(n, setw->def, setname, setwname, true); - Printf(setw->def, "if (!SWIG_Octave_CheckNumArgs(\"%s_set\",args.length(),1,1,0)) return octave_value_list();", iname); + Printf(setw->def, "if (!SWIG_check_num_args(\"%s_set\",args.length(),1,1,0)) return octave_value_list();", iname); if (is_assignable(n)) { Setattr(n, "wrap:name", setname); if ((tm = Swig_typemap_lookup("varin", n, name, 0))) { @@ -863,7 +867,7 @@ public: Append(setw->code, "fail:\n"); Printf(setw->code, "return octave_value_list();\n"); } else { - Printf(setw->code, "return SWIG_Octave_SetImmutable(args,nargout);"); + Printf(setw->code, "return octave_set_immutable(args,nargout);"); } Append(setw->code, "}\n"); Wrapper_print(setw, f_wrappers); @@ -973,7 +977,7 @@ public: assert(!s_members_tab); s_members_tab = NewStringEmpty(); - Printv(s_members_tab, "static SwigOctMember swig_", class_name, "_members[] = {\n", NIL); + Printv(s_members_tab, "static swig_octave_member swig_", class_name, "_members[] = {\n", NIL); Language::classHandler(n); @@ -1033,7 +1037,7 @@ public: Printv(f_wrappers, "static const char *swig_", class_name, "_base_names[] = {", base_class_names, "0};\n", NIL); Printv(f_wrappers, "static const swig_type_info *swig_", class_name, "_base[] = {", base_class, "0};\n", NIL); - Printv(f_wrappers, "static SwigOctClass _wrap_class_", class_name, " = {\"", class_name, "\", &SWIGTYPE", SwigType_manglestr(t), ",", NIL); + Printv(f_wrappers, "static swig_octave_class _wrap_class_", class_name, " = {\"", class_name, "\", &SWIGTYPE", SwigType_manglestr(t), ",", NIL); Printv(f_wrappers, Swig_directorclass(n) ? "1," : "0,", NIL); if (have_constructor) { String* nspace = Getattr(n, "sym:nspace"); @@ -1107,7 +1111,7 @@ public: String* getname = Swig_name_get(NSPACE_TODO, Swig_name_member(NSPACE_TODO, class_name, symname)); String* setname = Swig_name_set(NSPACE_TODO, Swig_name_member(NSPACE_TODO, class_name, symname)); String* getwname = Swig_name_wrapper(getname); - String* setwname = GetFlag(n, "feature:immutable") ? NewString("SWIG_Octave_SetImmutable") : Swig_name_wrapper(setname); + String* setwname = GetFlag(n, "feature:immutable") ? NewString("octave_set_immutable") : Swig_name_wrapper(setname); assert(s_members_tab); Printf(s_members_tab, "{\"%s\",0,%s,%s,0,0},\n", symname, getwname, setwname); @@ -1196,7 +1200,7 @@ public: String* getname = Swig_name_get(NSPACE_TODO, Swig_name_member(NSPACE_TODO, class_name, symname)); String* setname = Swig_name_set(NSPACE_TODO, Swig_name_member(NSPACE_TODO, class_name, symname)); String* getwname = Swig_name_wrapper(getname); - String* setwname = GetFlag(n, "feature:immutable") ? NewString("SWIG_Octave_SetImmutable") : Swig_name_wrapper(setname); + String* setwname = GetFlag(n, "feature:immutable") ? NewString("octave_set_immutable") : Swig_name_wrapper(setname); assert(s_members_tab); Printf(s_members_tab, "{\"%s\",0,%s,%s,1,0},\n", symname, getwname, setwname); @@ -1277,12 +1281,12 @@ public: { Wrapper* w = NewWrapper(); Printf(w->def, "SwigDirector_%s::SwigDirector_%s(void* self) :" - "\nSwig::Director((SwigOctType*)self,static_cast<%s*>(this)) { \n", classname, classname, classname); + "\nSwig::Director((octave_swig_type*)self,static_cast<%s*>(this)) { \n", classname, classname, classname); Append(w->def, "}\n"); Wrapper_print(w, f_directors); DelWrapper(w); } - Printf(f_directors_h, " SwigDirector_%s(SwigOctType* self);\n", classname); + Printf(f_directors_h, " SwigDirector_%s(octave_swig_type* self);\n", classname); Delete(classname); return Language::classDirectorDefaultConstructor(n); } @@ -1563,20 +1567,12 @@ public: String* runtimeCode() { String* s = NewStringEmpty(); - const char* runtimeFiles[] = { - "octrundecl.swg", - "octrunfunc.swg", - "octrunclass.swg", - "octruninit.swg" - }; - for (size_t i = 0; i < sizeof(runtimeFiles)/sizeof(runtimeFiles[0]); ++i) { - String* srun = Swig_include_sys(runtimeFiles[i]); - if (!srun) { - Printf(stderr, "*** Unable to open '%s'\n", runtimeFiles[i]); - } else { - Append(s, srun); - Delete(srun); - } + String* srun = Swig_include_sys("octrun.swg"); + if (!srun) { + Printf(stderr, "*** Unable to open 'octrun.swg'\n"); + } else { + Append(s, srun); + Delete(srun); } return s; } -- cgit v1.2.1 From 97f6731e3c7f4ef17089ca05297b66e25e52ea4e Mon Sep 17 00:00:00 2001 From: William S Fulton Date: Thu, 9 Oct 2014 19:34:04 +0100 Subject: Revert "Octave: simplify Examples/octave/example.mk" This reverts commit 6c04378e20ee20cbadca7c3d887941e270990faf. Reverting a series of Octave commits for re-applying again without incorrect whitespace changes. --- Examples/octave/example.mk | 37 +++++++++++++++---------------------- 1 file changed, 15 insertions(+), 22 deletions(-) diff --git a/Examples/octave/example.mk b/Examples/octave/example.mk index ac36cca91..e0b1e4efb 100644 --- a/Examples/octave/example.mk +++ b/Examples/octave/example.mk @@ -6,34 +6,27 @@ SWIG = $(TOP)/../preinst-swig TARGET = swigexample INTERFACE = example.i -BUILDCMD = \ - $(MAKE) -f $(TOP)/Makefile \ - SRCDIR='$(SRCDIR)' \ - SWIG='$(SWIG)' \ - INTERFACE='$(INTERFACE)' - -ifneq (,$(SRCS)) - BUILDCMD += SRCS='$(SRCS)' - BUILDTARGET = octave -else - BUILDCMD += CXXSRCS='$(CXXSRCS)' - BUILDTARGET = octave_cpp -endif - check: build $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' octave_run build: - $(BUILDCMD) SWIGOPT='$(SWIGOPT)' TARGET='$(TARGET)' $(BUILDTARGET) - +ifneq (,$(SRCS)) + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SRCS='$(SRCS)' SWIG='$(SWIG)' \ + SWIGOPT='$(SWIGOPT)' TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' octave +else + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ + SWIGOPT='$(SWIGOPT)' TARGET='$(TARGET)' INTERFACE='$(INTERFACE)' octave_cpp +endif ifneq (,$(TARGET2)$(SWIGOPT2)) - -check: build2 - -build2: - $(BUILDCMD) SWIGOPT='$(SWIGOPT2)' TARGET='$(TARGET2)' $(BUILDTARGET) - +ifneq (,$(SRCS)) + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' SRCS='$(SRCS)' SWIG='$(SWIG)' \ + SWIGOPT='$(SWIGOPT2)' TARGET='$(TARGET2)' INTERFACE='$(INTERFACE)' octave +else + $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' CXXSRCS='$(CXXSRCS)' SWIG='$(SWIG)' \ + SWIGOPT='$(SWIGOPT2)' TARGET='$(TARGET2)' INTERFACE='$(INTERFACE)' octave_cpp endif +endif + clean: $(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' octave_clean -- cgit v1.2.1 From 376ebc2d85c5e3f2520ed34a6e459e7cce18b189 Mon Sep 17 00:00:00 2001 From: William S Fulton Date: Thu, 9 Oct 2014 19:34:06 +0100 Subject: Revert "Octave: whitespace/indentation/style cleanup of octave.cxx" This reverts commit 5ac475cbcd873307abe802063789f47aa5435dd1. Reverting a series of Octave commits for re-applying again without incorrect whitespace changes. --- Source/Modules/octave.cxx | 831 ++++++++++++++++++++++------------------------ 1 file changed, 393 insertions(+), 438 deletions(-) diff --git a/Source/Modules/octave.cxx b/Source/Modules/octave.cxx index 3ec60c31d..12903166c 100644 --- a/Source/Modules/octave.cxx +++ b/Source/Modules/octave.cxx @@ -14,10 +14,10 @@ #include "swigmod.h" #include "cparse.h" -static String* global_name = 0; -static String* op_prefix = 0; +static String *global_name = 0; +static String *op_prefix = 0; -static const char* usage = "\ +static const char *usage = "\ Octave Options (available with -octave)\n\ -globals - Set used to access C global variables [default: 'cvar']\n\ Use '.' to load C global variables into module namespace\n\ @@ -25,39 +25,39 @@ Octave Options (available with -octave)\n\ \n"; -class OCTAVE: public Language -{ +class OCTAVE:public Language { private: - File* f_begin; - File* f_runtime; - File* f_header; - File* f_doc; - File* f_wrappers; - File* f_init; - File* f_initbeforefunc; - File* f_directors; - File* f_directors_h; - String* s_global_tab; - String* s_members_tab; - String* class_name; + File *f_begin; + File *f_runtime; + File *f_header; + File *f_doc; + File *f_wrappers; + File *f_init; + File *f_initbeforefunc; + File *f_directors; + File *f_directors_h; + String *s_global_tab; + String *s_members_tab; + String *class_name; int have_constructor; int have_destructor; - String* constructor_name; + String *constructor_name; - Hash* docs; + Hash *docs; - void Octave_begin_function(Node* n, File* f, const_String_or_char_ptr cname, const_String_or_char_ptr wname, bool dld) { + void Octave_begin_function(Node *n, File *f, const_String_or_char_ptr cname, const_String_or_char_ptr wname, bool dld) { if (dld) { - String* tname = texinfo_name(n, "std::string()"); + String *tname = texinfo_name(n, "std::string()"); Printf(f, "SWIG_DEFUN( %s, %s, %s ) {", cname, wname, tname); - } else { + } + else { Printf(f, "static octave_value_list %s (const octave_value_list& args, int nargout) {", wname); } } public: - OCTAVE() : + OCTAVE(): f_begin(0), f_runtime(0), f_header(0), @@ -73,9 +73,10 @@ public: have_constructor(0), have_destructor(0), constructor_name(0), - docs(0) { + docs(0) + { /* Add code to manage protected constructors and directors */ - director_prot_ctor_code = NewStringEmpty(); + director_prot_ctor_code = NewString(""); Printv(director_prot_ctor_code, "if ( $comparison ) { /* subclassed */\n", " $director_new \n", @@ -88,7 +89,7 @@ public: docs = NewHash(); } - virtual void main(int argc, char* argv[]) { + virtual void main(int argc, char *argv[]) { for (int i = 1; i < argc; i++) { if (argv[i]) { if (strcmp(argv[i], "-help") == 0) { @@ -115,12 +116,10 @@ public: } } - if (!global_name) { + if (!global_name) global_name = NewString("cvar"); - } - if (!op_prefix) { + if (!op_prefix) op_prefix = NewString("op_"); - } SWIG_library_directory("octave"); Preprocessor_define("SWIGOCTAVE 1", 0); @@ -129,16 +128,15 @@ public: allow_overloading(); // Octave API is C++, so output must be C++ compatibile even when wrapping C code - if (!cparse_cplusplus) { + if (!cparse_cplusplus) Swig_cparse_cplusplusout(1); - } } - virtual int top(Node* n) { + virtual int top(Node *n) { { - Node* mod = Getattr(n, "module"); + Node *mod = Getattr(n, "module"); if (mod) { - Node* options = Getattr(mod, "options"); + Node *options = Getattr(mod, "options"); if (options) { int dirprot = 0; if (Getattr(options, "dirprot")) { @@ -149,30 +147,29 @@ public: } if (Getattr(options, "directors")) { allow_directors(); - if (dirprot) { + if (dirprot) allow_dirprot(); - } } } } } - String* module = Getattr(n, "name"); - String* outfile = Getattr(n, "outfile"); + String *module = Getattr(n, "name"); + String *outfile = Getattr(n, "outfile"); f_begin = NewFile(outfile, "w", SWIG_output_files()); if (!f_begin) { FileErrorDisplay(outfile); SWIG_exit(EXIT_FAILURE); } - f_runtime = NewStringEmpty(); - f_header = NewStringEmpty(); - f_doc = NewStringEmpty(); - f_wrappers = NewStringEmpty(); - f_init = NewStringEmpty(); - f_initbeforefunc = NewStringEmpty(); - f_directors_h = NewStringEmpty(); - f_directors = NewStringEmpty(); - s_global_tab = NewStringEmpty(); + f_runtime = NewString(""); + f_header = NewString(""); + f_doc = NewString(""); + f_wrappers = NewString(""); + f_init = NewString(""); + f_initbeforefunc = NewString(""); + f_directors_h = NewString(""); + f_directors = NewString(""); + s_global_tab = NewString(""); Swig_register_filebyname("begin", f_begin); Swig_register_filebyname("runtime", f_runtime); Swig_register_filebyname("header", f_header); @@ -208,23 +205,19 @@ public: Printf(s_global_tab, "\nstatic const struct swig_octave_member swig_globals[] = {\n"); Printf(f_init, "static bool SWIG_init_user(octave_swig_type* module_ns)\n{\n"); - if (!CPlusPlus) { - Printf(f_header, "extern \"C\" {\n"); - } + if (!CPlusPlus) + Printf(f_header,"extern \"C\" {\n"); Language::top(n); - if (!CPlusPlus) { - Printf(f_header, "}\n"); - } + if (!CPlusPlus) + Printf(f_header,"}\n"); - if (Len(docs)) { + if (Len(docs)) emit_doc_texinfo(); - } - if (directorsEnabled()) { + if (directorsEnabled()) Swig_insert_file("director.swg", f_runtime); - } Printf(f_init, "return true;\n}\n"); Printf(s_global_tab, "{0,0,0,0,0}\n};\n"); @@ -256,13 +249,12 @@ public: return SWIG_OK; } - String* texinfo_escape(String* _s) { - const char* s = (const char*) Data(_s); - while (*s && (*s == '\t' || *s == '\r' || *s == '\n' || *s == ' ')) { + String *texinfo_escape(String *_s) { + const char* s=(const char*)Data(_s); + while (*s&&(*s=='\t'||*s=='\r'||*s=='\n'||*s==' ')) ++s; - } - String* r = NewStringEmpty(); - for (int j = 0; s[j]; ++j) { + String *r = NewString(""); + for (int j=0;s[j];++j) { if (s[j] == '\n') { Append(r, "\\n\\\n"); } else if (s[j] == '\r') { @@ -275,98 +267,94 @@ public: Append(r, "\\\'"); } else if (s[j] == '\"') { Append(r, "\\\""); - } else { + } else Putc(s[j], r); - } } return r; } void emit_doc_texinfo() { for (Iterator it = First(docs); it.key; it = Next(it)) { - String* wrap_name = it.key; + String *wrap_name = it.key; - String* synopsis = Getattr(it.item, "synopsis"); - String* decl_info = Getattr(it.item, "decl_info"); - String* cdecl_info = Getattr(it.item, "cdecl_info"); - String* args_info = Getattr(it.item, "args_info"); + String *synopsis = Getattr(it.item, "synopsis"); + String *decl_info = Getattr(it.item, "decl_info"); + String *cdecl_info = Getattr(it.item, "cdecl_info"); + String *args_info = Getattr(it.item, "args_info"); - String* doc_str = NewStringEmpty(); + String *doc_str = NewString(""); Printv(doc_str, synopsis, decl_info, cdecl_info, args_info, NIL); - String* escaped_doc_str = texinfo_escape(doc_str); - - if (Len(doc_str) > 0) { - Printf(f_doc, "static const char* %s_texinfo = ", wrap_name); - Printf(f_doc, "\"-*- texinfo -*-\\n\\\n%s", escaped_doc_str); - if (Len(decl_info)) { - Printf(f_doc, "\\n\\\n@end deftypefn"); - } - Printf(f_doc, "\";\n"); + String *escaped_doc_str = texinfo_escape(doc_str); + + if (Len(doc_str)>0) { + Printf(f_doc,"static const char* %s_texinfo = ",wrap_name); + Printf(f_doc,"\"-*- texinfo -*-\\n\\\n%s", escaped_doc_str); + if (Len(decl_info)) + Printf(f_doc,"\\n\\\n@end deftypefn"); + Printf(f_doc,"\";\n"); } Delete(escaped_doc_str); Delete(doc_str); Delete(wrap_name); } - Printf(f_doc, "\n"); + Printf(f_doc,"\n"); } bool is_empty_doc_node(Node* n) { - if (!n) { + if (!n) return true; - } - String* synopsis = Getattr(n, "synopsis"); - String* decl_info = Getattr(n, "decl_info"); - String* cdecl_info = Getattr(n, "cdecl_info"); - String* args_info = Getattr(n, "args_info"); + String *synopsis = Getattr(n, "synopsis"); + String *decl_info = Getattr(n, "decl_info"); + String *cdecl_info = Getattr(n, "cdecl_info"); + String *args_info = Getattr(n, "args_info"); return !Len(synopsis) && !Len(decl_info) && - !Len(cdecl_info) && !Len(args_info); + !Len(cdecl_info) && !Len(args_info); } - String* texinfo_name(Node* n, const char* defval = "0") { - String* tname = NewStringEmpty(); - String* iname = Getattr(n, "sym:name"); - String* wname = Swig_name_wrapper(iname); + String *texinfo_name(Node* n, const char* defval = "0") { + String *tname = NewString(""); + String *iname = Getattr(n, "sym:name"); + String *wname = Swig_name_wrapper(iname); Node* d = Getattr(docs, wname); - if (is_empty_doc_node(d)) { + if (is_empty_doc_node(d)) Printf(tname, defval); - } else { + else Printf(tname, "%s_texinfo", wname); - } return tname; } - void process_autodoc(Node* n) { - String* iname = Getattr(n, "sym:name"); - String* name = Getattr(n, "name"); - String* wname = Swig_name_wrapper(iname); - String* str = Getattr(n, "feature:docstring"); + void process_autodoc(Node *n) { + String *iname = Getattr(n, "sym:name"); + String *name = Getattr(n, "name"); + String *wname = Swig_name_wrapper(iname); + String *str = Getattr(n, "feature:docstring"); bool autodoc_enabled = !Cmp(Getattr(n, "feature:autodoc"), "1"); Node* d = Getattr(docs, wname); if (!d) { d = NewHash(); - Setattr(d, "synopsis", NewStringEmpty()); - Setattr(d, "decl_info", NewStringEmpty()); - Setattr(d, "cdecl_info", NewStringEmpty()); - Setattr(d, "args_info", NewStringEmpty()); + Setattr(d, "synopsis", NewString("")); + Setattr(d, "decl_info", NewString("")); + Setattr(d, "cdecl_info", NewString("")); + Setattr(d, "args_info", NewString("")); Setattr(docs, wname, d); } - String* synopsis = Getattr(d, "synopsis"); - String* decl_info = Getattr(d, "decl_info"); + String *synopsis = Getattr(d, "synopsis"); + String *decl_info = Getattr(d, "decl_info"); // String *cdecl_info = Getattr(d, "cdecl_info"); - String* args_info = Getattr(d, "args_info"); + String *args_info = Getattr(d, "args_info"); // * couldn't we just emit the docs here? if (autodoc_enabled) { - String* decl_str = NewStringEmpty(); - String* args_str = NewStringEmpty(); + String *decl_str = NewString(""); + String *args_str = NewString(""); make_autodocParmList(n, decl_str, args_str); Append(decl_info, "@deftypefn {Loadable Function} "); - SwigType* type = Getattr(n, "type"); + SwigType *type = Getattr(n, "type"); if (type && Strcmp(type, "void")) { - Node* nn = classLookup(Getattr(n, "type")); - String* type_str = nn ? Copy(Getattr(nn, "sym:name")) : SwigType_str(type, 0); + Node *nn = classLookup(Getattr(n, "type")); + String *type_str = nn ? Copy(Getattr(nn, "sym:name")) : SwigType_str(type, 0); Append(decl_info, "@var{retval} = "); Printf(args_str, "%s@var{retval} is of type %s. ", args_str, type_str); Delete(type_str); @@ -383,7 +371,7 @@ public: if (str && Len(str) > 0) { // strip off {} if necessary - char* t = Char(str); + char *t = Char(str); if (*t == '{') { Delitem(str, 0); Delitem(str, DOH_END); @@ -394,15 +382,14 @@ public: } } - virtual int importDirective(Node* n) { - String* modname = Getattr(n, "module"); - if (modname) { + virtual int importDirective(Node *n) { + String *modname = Getattr(n, "module"); + if (modname) Printf(f_init, "if (!SWIG_Octave_LoadModule(\"%s\")) return false;\n", modname); - } return Language::importDirective(n); } - const char* get_implicitconv_flag(Node* n) { + const char *get_implicitconv_flag(Node *n) { int conv = 0; if (n && GetFlag(n, "feature:implicitconv")) { conv = 1; @@ -421,12 +408,12 @@ public: * The "lname" attribute in each parameter in plist will be contain a parameter name * ----------------------------------------------------------------------------- */ - void addMissingParameterNames(ParmList* plist, int arg_offset) { - Parm* p = plist; + void addMissingParameterNames(ParmList *plist, int arg_offset) { + Parm *p = plist; int i = arg_offset; while (p) { if (!Getattr(p, "lname")) { - String* pname = Swig_cparm_name(p, i); + String *pname = Swig_cparm_name(p, i); Delete(pname); } i++; @@ -434,21 +421,21 @@ public: } } - void make_autodocParmList(Node* n, String* decl_str, String* args_str) { - String* pdocs = 0; - ParmList* plist = CopyParmList(Getattr(n, "parms")); - Parm* p; - Parm* pnext; + void make_autodocParmList(Node *n, String *decl_str, String *args_str) { + String *pdocs = 0; + ParmList *plist = CopyParmList(Getattr(n, "parms")); + Parm *p; + Parm *pnext; int start_arg_num = is_wrapping_class() ? 1 : 0; - addMissingParameterNames(plist, start_arg_num); // for $1_name substitutions done in Swig_typemap_attach_parms + addMissingParameterNames(plist, start_arg_num); // for $1_name substitutions done in Swig_typemap_attach_parms Swig_typemap_attach_parms("in", plist, 0); Swig_typemap_attach_parms("doc", plist, 0); for (p = plist; p; p = pnext) { - String* tm = Getattr(p, "tmap:in"); + String *tm = Getattr(p, "tmap:in"); if (tm) { pnext = Getattr(p, "tmap:in:next"); if (checkAttribute(p, "tmap:in:numinputs", "0")) { @@ -458,10 +445,10 @@ public: pnext = nextSibling(p); } - String* name = 0; - String* type = 0; - String* value = 0; - String* pdoc = Getattr(p, "tmap:doc"); + String *name = 0; + String *type = 0; + String *value = 0; + String *pdoc = Getattr(p, "tmap:doc"); if (pdoc) { name = Getattr(p, "tmap:doc:name"); type = Getattr(p, "tmap:doc:type"); @@ -471,51 +458,46 @@ public: // Note: the generated name should be consistent with that in kwnames[] name = name ? name : Getattr(p, "name"); name = name ? name : Getattr(p, "lname"); - name = Swig_name_make(p, 0, name, 0, 0); // rename parameter if a keyword + name = Swig_name_make(p, 0, name, 0, 0); // rename parameter if a keyword type = type ? type : Getattr(p, "type"); value = value ? value : Getattr(p, "value"); - if (SwigType_isvarargs(type)) { + if (SwigType_isvarargs(type)) break; - } - String* tex_name = NewStringEmpty(); - if (name) { + String *tex_name = NewString(""); + if (name) Printf(tex_name, "@var{%s}", name); - } else { + else Printf(tex_name, "@var{?}"); - } - if (Len(decl_str)) { + if (Len(decl_str)) Append(decl_str, ", "); - } Append(decl_str, tex_name); if (value) { - String* new_value = convertValue(value, Getattr(p, "type")); + String *new_value = convertValue(value, Getattr(p, "type")); if (new_value) { value = new_value; } else { - Node* lookup = Swig_symbol_clookup(value, 0); - if (lookup) { + Node *lookup = Swig_symbol_clookup(value, 0); + if (lookup) value = Getattr(lookup, "sym:name"); - } } Printf(decl_str, " = %s", value); } - Node* nn = classLookup(Getattr(p, "type")); - String* type_str = nn ? Copy(Getattr(nn, "sym:name")) : SwigType_str(type, 0); + Node *nn = classLookup(Getattr(p, "type")); + String *type_str = nn ? Copy(Getattr(nn, "sym:name")) : SwigType_str(type, 0); Printf(args_str, "%s is of type %s. ", tex_name, type_str); Delete(type_str); Delete(tex_name); Delete(name); } - if (pdocs) { + if (pdocs) Setattr(n, "feature:pdocs", pdocs); - } Delete(plist); } @@ -524,65 +506,58 @@ public: * Check if string v can be an Octave value literal, * (eg. number or string), or translate it to an Octave literal. * ------------------------------------------------------------ */ - String* convertValue(String* v, SwigType* t) { + String *convertValue(String *v, SwigType *t) { if (v && Len(v) > 0) { - char fc = (Char(v)) [0]; + char fc = (Char(v))[0]; if (('0' <= fc && fc <= '9') || '\'' == fc || '"' == fc) { /* number or string (or maybe NULL pointer) */ - if (SwigType_ispointer(t) && Strcmp(v, "0") == 0) { + if (SwigType_ispointer(t) && Strcmp(v, "0") == 0) return NewString("None"); - } else { + else return v; - } } - if (Strcmp(v, "NULL") == 0 || Strcmp(v, "nullptr") == 0) { + if (Strcmp(v, "NULL") == 0 || Strcmp(v, "nullptr") == 0) return SwigType_ispointer(t) ? NewString("nil") : NewString("0"); - } - if (Strcmp(v, "true") == 0 || Strcmp(v, "TRUE") == 0) { + if (Strcmp(v, "true") == 0 || Strcmp(v, "TRUE") == 0) return NewString("true"); - } - if (Strcmp(v, "false") == 0 || Strcmp(v, "FALSE") == 0) { + if (Strcmp(v, "false") == 0 || Strcmp(v, "FALSE") == 0) return NewString("false"); - } } return 0; } - virtual int functionWrapper(Node* n) { - Parm* p; - String* tm; + virtual int functionWrapper(Node *n) { + Parm *p; + String *tm; int j; - String* nodeType = Getattr(n, "nodeType"); + String *nodeType = Getattr(n, "nodeType"); int constructor = (!Cmp(nodeType, "constructor")); int destructor = (!Cmp(nodeType, "destructor")); - String* storage = Getattr(n, "storage"); + String *storage = Getattr(n, "storage"); bool overloaded = !!Getattr(n, "sym:overloaded"); bool last_overload = overloaded && !Getattr(n, "sym:nextSibling"); - String* iname = Getattr(n, "sym:name"); - String* wname = Swig_name_wrapper(iname); - String* overname = Copy(wname); - SwigType* d = Getattr(n, "type"); - ParmList* l = Getattr(n, "parms"); + String *iname = Getattr(n, "sym:name"); + String *wname = Swig_name_wrapper(iname); + String *overname = Copy(wname); + SwigType *d = Getattr(n, "type"); + ParmList *l = Getattr(n, "parms"); - if (!overloaded && !addSymbol(iname, n)) { + if (!overloaded && !addSymbol(iname, n)) return SWIG_ERROR; - } - if (overloaded) { + if (overloaded) Append(overname, Getattr(n, "sym:overname")); - } - if (!overloaded || last_overload) { + if (!overloaded || last_overload) process_autodoc(n); - } - Wrapper* w = NewWrapper(); - Octave_begin_function(n, w->def, iname, overname, !overloaded); + Wrapper *f = NewWrapper(); + Octave_begin_function(n, f->def, iname, overname, !overloaded); - emit_parameter_variables(l, w); - emit_attach_parmmaps(l, w); + emit_parameter_variables(l, f); + emit_attach_parmmaps(l, f); Setattr(n, "wrap:parms", l); int num_arguments = emit_num_arguments(l); @@ -590,15 +565,15 @@ public: int varargs = emit_isvarargs(l); char source[64]; - Printf(w->code, "if (!SWIG_check_num_args(\"%s\",args.length(),%i,%i,%i)) " + Printf(f->code, "if (!SWIG_check_num_args(\"%s\",args.length(),%i,%i,%i)) " "{\n SWIG_fail;\n }\n", iname, num_arguments, num_required, varargs); if (constructor && num_arguments == 1 && num_required == 1) { if (Cmp(storage, "explicit") == 0) { - Node* parent = Swig_methodclass(n); + Node *parent = Swig_methodclass(n); if (GetFlag(parent, "feature:implicitconv")) { - String* desc = NewStringf("SWIGTYPE%s", SwigType_manglestr(Getattr(n, "type"))); - Printf(w->code, "if (SWIG_CheckImplicit(%s)) SWIG_fail;\n", desc); + String *desc = NewStringf("SWIGTYPE%s", SwigType_manglestr(Getattr(n, "type"))); + Printf(f->code, "if (SWIG_CheckImplicit(%s)) SWIG_fail;\n", desc); Delete(desc); } } @@ -609,9 +584,9 @@ public: p = Getattr(p, "tmap:in:next"); } - SwigType* pt = Getattr(p, "type"); + SwigType *pt = Getattr(p, "type"); - String* tm = Getattr(p, "tmap:in"); + String *tm = Getattr(p, "tmap:in"); if (tm) { if (!tm || checkAttribute(p, "tmap:in:numinputs", "0")) { p = nextSibling(p); @@ -632,22 +607,21 @@ public: } if (Getattr(p, "tmap:in:implicitconv")) { - const char* convflag = "0"; + const char *convflag = "0"; if (!Getattr(p, "hidden")) { - SwigType* ptype = Getattr(p, "type"); + SwigType *ptype = Getattr(p, "type"); convflag = get_implicitconv_flag(classLookup(ptype)); } Replaceall(tm, "$implicitconv", convflag); Setattr(p, "implicitconv", convflag); } - String* getargs = NewStringEmpty(); - if (j >= num_required) { + String *getargs = NewString(""); + if (j >= num_required) Printf(getargs, "if (%dcode, getargs, "\n", NIL); + Printv(f->code, getargs, "\n", NIL); Delete(getargs); p = Getattr(p, "tmap:in:next"); @@ -662,7 +636,7 @@ public: if (varargs) { if (p && (tm = Getattr(p, "tmap:in"))) { Replaceall(tm, "$input", "varargs"); - Printv(w->code, tm, "\n", NIL); + Printv(f->code, tm, "\n", NIL); } } @@ -670,7 +644,7 @@ public: for (p = l; p;) { if ((tm = Getattr(p, "tmap:check"))) { Replaceall(tm, "$target", Getattr(p, "lname")); - Printv(w->code, tm, "\n", NIL); + Printv(f->code, tm, "\n", NIL); p = Getattr(p, "tmap:check:next"); } else { p = nextSibling(p); @@ -678,13 +652,13 @@ public: } // Insert cleanup code - String* cleanup = NewStringEmpty(); + String *cleanup = NewString(""); for (p = l; p;) { if ((tm = Getattr(p, "tmap:freearg"))) { if (Getattr(p, "tmap:freearg:implicitconv")) { - const char* convflag = "0"; + const char *convflag = "0"; if (!Getattr(p, "hidden")) { - SwigType* ptype = Getattr(p, "type"); + SwigType *ptype = Getattr(p, "type"); convflag = get_implicitconv_flag(classLookup(ptype)); } if (strcmp(convflag, "0") == 0) { @@ -702,7 +676,7 @@ public: } // Insert argument output code - String* outarg = NewStringEmpty(); + String *outarg = NewString(""); for (p = l; p;) { if ((tm = Getattr(p, "tmap:argout"))) { Replaceall(tm, "$source", Getattr(p, "lname")); @@ -719,75 +693,73 @@ public: int director_method = is_member_director(n) && !is_smart_pointer() && !destructor; if (director_method) { - Wrapper_add_local(w, "upcall", "bool upcall = false"); - Append(w->code, "upcall = !!dynamic_cast(arg1);\n"); + Wrapper_add_local(f, "upcall", "bool upcall = false"); + Append(f->code, "upcall = !!dynamic_cast(arg1);\n"); } Setattr(n, "wrap:name", overname); - Swig_director_emit_dynamic_cast(n, w); - String* actioncode = emit_action(n); + Swig_director_emit_dynamic_cast(n, f); + String *actioncode = emit_action(n); - Wrapper_add_local(w, "_out", "octave_value_list _out"); - Wrapper_add_local(w, "_outp", "octave_value_list *_outp=&_out"); - Wrapper_add_local(w, "_outv", "octave_value _outv"); + Wrapper_add_local(f, "_out", "octave_value_list _out"); + Wrapper_add_local(f, "_outp", "octave_value_list *_outp=&_out"); + Wrapper_add_local(f, "_outv", "octave_value _outv"); // Return the function value - if ((tm = Swig_typemap_lookup_out("out", n, Swig_cresult_name(), w, actioncode))) { + if ((tm = Swig_typemap_lookup_out("out", n, Swig_cresult_name(), f, actioncode))) { Replaceall(tm, "$source", Swig_cresult_name()); Replaceall(tm, "$target", "_outv"); Replaceall(tm, "$result", "_outv"); - if (GetFlag(n, "feature:new")) { + if (GetFlag(n, "feature:new")) Replaceall(tm, "$owner", "1"); - } else { + else Replaceall(tm, "$owner", "0"); - } - Printf(w->code, "%s\n", tm); - Printf(w->code, "if (_outv.is_defined()) _outp = " "SWIG_Octave_AppendOutput(_outp, _outv);\n"); + Printf(f->code, "%s\n", tm); + Printf(f->code, "if (_outv.is_defined()) _outp = " "SWIG_Octave_AppendOutput(_outp, _outv);\n"); Delete(tm); } else { Swig_warning(WARN_TYPEMAP_OUT_UNDEF, input_file, line_number, "Unable to use return type %s in function %s.\n", SwigType_str(d, 0), iname); } - emit_return_variable(n, d, w); + emit_return_variable(n, d, f); - Printv(w->code, outarg, NIL); - Printv(w->code, cleanup, NIL); + Printv(f->code, outarg, NIL); + Printv(f->code, cleanup, NIL); if (GetFlag(n, "feature:new")) { if ((tm = Swig_typemap_lookup("newfree", n, Swig_cresult_name(), 0))) { Replaceall(tm, "$source", Swig_cresult_name()); - Printf(w->code, "%s\n", tm); + Printf(f->code, "%s\n", tm); } } if ((tm = Swig_typemap_lookup("ret", n, Swig_cresult_name(), 0))) { Replaceall(tm, "$source", Swig_cresult_name()); Replaceall(tm, "$result", "_outv"); - Printf(w->code, "%s\n", tm); + Printf(f->code, "%s\n", tm); Delete(tm); } - Printf(w->code, "return _out;\n"); - Printf(w->code, "fail:\n"); // we should free locals etc if this happens - Printv(w->code, cleanup, NIL); - Printf(w->code, "return octave_value_list();\n"); - Printf(w->code, "}\n"); + Printf(f->code, "return _out;\n"); + Printf(f->code, "fail:\n"); // we should free locals etc if this happens + Printv(f->code, cleanup, NIL); + Printf(f->code, "return octave_value_list();\n"); + Printf(f->code, "}\n"); /* Substitute the cleanup code */ - Replaceall(w->code, "$cleanup", cleanup); + Replaceall(f->code, "$cleanup", cleanup); - Replaceall(w->code, "$symname", iname); - Wrapper_print(w, f_wrappers); - DelWrapper(w); + Replaceall(f->code, "$symname", iname); + Wrapper_print(f, f_wrappers); + DelWrapper(f); - if (last_overload) { + if (last_overload) dispatchFunction(n); - } if (!overloaded || last_overload) { - String* tname = texinfo_name(n); + String *tname = texinfo_name(n); Printf(s_global_tab, "{\"%s\",%s,0,0,2,%s},\n", iname, wname, tname); Delete(tname); } @@ -800,56 +772,54 @@ public: return SWIG_OK; } - void dispatchFunction(Node* n) { - Wrapper* w = NewWrapper(); + void dispatchFunction(Node *n) { + Wrapper *f = NewWrapper(); - String* iname = Getattr(n, "sym:name"); - String* wname = Swig_name_wrapper(iname); + String *iname = Getattr(n, "sym:name"); + String *wname = Swig_name_wrapper(iname); int maxargs; - String* dispatch = Swig_overload_dispatch(n, "return %s(args, nargout);", &maxargs); - String* tmp = NewStringEmpty(); + String *dispatch = Swig_overload_dispatch(n, "return %s(args, nargout);", &maxargs); + String *tmp = NewString(""); - Octave_begin_function(n, w->def, iname, wname, true); - Wrapper_add_local(w, "argc", "int argc = args.length()"); + Octave_begin_function(n, f->def, iname, wname, true); + Wrapper_add_local(f, "argc", "int argc = args.length()"); Printf(tmp, "octave_value_ref argv[%d]={", maxargs); - for (int j = 0; j < maxargs; ++j) { + for (int j = 0; j < maxargs; ++j) Printf(tmp, "%soctave_value_ref(args,%d)", j ? "," : " ", j); - } Printf(tmp, "}"); - Wrapper_add_local(w, "argv", tmp); - Printv(w->code, dispatch, "\n", NIL); - Printf(w->code, "error(\"No matching function for overload\");\n", iname); - Printf(w->code, "return octave_value_list();\n"); - Printv(w->code, "}\n", NIL); + Wrapper_add_local(f, "argv", tmp); + Printv(f->code, dispatch, "\n", NIL); + Printf(f->code, "error(\"No matching function for overload\");\n", iname); + Printf(f->code, "return octave_value_list();\n"); + Printv(f->code, "}\n", NIL); - Wrapper_print(w, f_wrappers); + Wrapper_print(f, f_wrappers); Delete(tmp); - DelWrapper(w); + DelWrapper(f); Delete(dispatch); Delete(wname); } - virtual int variableWrapper(Node* n) { - String* name = Getattr(n, "name"); - String* iname = Getattr(n, "sym:name"); - SwigType* t = Getattr(n, "type"); + virtual int variableWrapper(Node *n) { + String *name = Getattr(n, "name"); + String *iname = Getattr(n, "sym:name"); + SwigType *t = Getattr(n, "type"); - if (!addSymbol(iname, n)) { + if (!addSymbol(iname, n)) return SWIG_ERROR; - } - String* tm; - Wrapper* getw = NewWrapper(); - Wrapper* setw = NewWrapper(); + String *tm; + Wrapper *getf = NewWrapper(); + Wrapper *setf = NewWrapper(); - String* getname = Swig_name_get(NSPACE_TODO, iname); - String* setname = Swig_name_set(NSPACE_TODO, iname); + String *getname = Swig_name_get(NSPACE_TODO, iname); + String *setname = Swig_name_set(NSPACE_TODO, iname); - String* getwname = Swig_name_wrapper(getname); - String* setwname = Swig_name_wrapper(setname); + String *getwname = Swig_name_wrapper(getname); + String *setwname = Swig_name_wrapper(setname); - Octave_begin_function(n, setw->def, setname, setwname, true); - Printf(setw->def, "if (!SWIG_check_num_args(\"%s_set\",args.length(),1,1,0)) return octave_value_list();", iname); + Octave_begin_function(n, setf->def, setname, setwname, true); + Printf(setf->def, "if (!SWIG_check_num_args(\"%s_set\",args.length(),1,1,0)) return octave_value_list();", iname); if (is_assignable(n)) { Setattr(n, "wrap:name", setname); if ((tm = Swig_typemap_lookup("varin", n, name, 0))) { @@ -859,66 +829,65 @@ public: if (Getattr(n, "tmap:varin:implicitconv")) { Replaceall(tm, "$implicitconv", get_implicitconv_flag(n)); } - emit_action_code(n, setw->code, tm); + emit_action_code(n, setf->code, tm); Delete(tm); } else { Swig_warning(WARN_TYPEMAP_VARIN_UNDEF, input_file, line_number, "Unable to set variable of type %s.\n", SwigType_str(t, 0)); } - Append(setw->code, "fail:\n"); - Printf(setw->code, "return octave_value_list();\n"); + Append(setf->code, "fail:\n"); + Printf(setf->code, "return octave_value_list();\n"); } else { - Printf(setw->code, "return octave_set_immutable(args,nargout);"); + Printf(setf->code, "return octave_set_immutable(args,nargout);"); } - Append(setw->code, "}\n"); - Wrapper_print(setw, f_wrappers); + Append(setf->code, "}\n"); + Wrapper_print(setf, f_wrappers); Setattr(n, "wrap:name", getname); int addfail = 0; - Octave_begin_function(n, getw->def, getname, getwname, true); - Wrapper_add_local(getw, "obj", "octave_value obj"); + Octave_begin_function(n, getf->def, getname, getwname, true); + Wrapper_add_local(getf, "obj", "octave_value obj"); if ((tm = Swig_typemap_lookup("varout", n, name, 0))) { Replaceall(tm, "$source", name); Replaceall(tm, "$target", "obj"); Replaceall(tm, "$result", "obj"); - addfail = emit_action_code(n, getw->code, tm); + addfail = emit_action_code(n, getf->code, tm); Delete(tm); } else { Swig_warning(WARN_TYPEMAP_VAROUT_UNDEF, input_file, line_number, "Unable to read variable of type %s\n", SwigType_str(t, 0)); } - Append(getw->code, " return obj;\n"); + Append(getf->code, " return obj;\n"); if (addfail) { - Append(getw->code, "fail:\n"); - Append(getw->code, " return octave_value_list();\n"); + Append(getf->code, "fail:\n"); + Append(getf->code, " return octave_value_list();\n"); } - Append(getw->code, "}\n"); - Wrapper_print(getw, f_wrappers); + Append(getf->code, "}\n"); + Wrapper_print(getf, f_wrappers); Printf(s_global_tab, "{\"%s\",0,%s,%s,2,0},\n", iname, getwname, setwname); Delete(getwname); Delete(setwname); - DelWrapper(setw); - DelWrapper(getw); + DelWrapper(setf); + DelWrapper(getf); return SWIG_OK; } - virtual int constantWrapper(Node* n) { - String* name = Getattr(n, "name"); - String* iname = Getattr(n, "sym:name"); - SwigType* type = Getattr(n, "type"); - String* rawval = Getattr(n, "rawval"); - String* value = rawval ? rawval : Getattr(n, "value"); - String* cppvalue = Getattr(n, "cppvalue"); - String* tm; + virtual int constantWrapper(Node *n) { + String *name = Getattr(n, "name"); + String *iname = Getattr(n, "sym:name"); + SwigType *type = Getattr(n, "type"); + String *rawval = Getattr(n, "rawval"); + String *value = rawval ? rawval : Getattr(n, "value"); + String *cppvalue = Getattr(n, "cppvalue"); + String *tm; - if (!addSymbol(iname, n)) { + if (!addSymbol(iname, n)) return SWIG_ERROR; - } if (SwigType_type(type) == T_MPOINTER) { - String* wname = Swig_name_wrapper(iname); - String* str = SwigType_str(type, wname); + String *wname = Swig_name_wrapper(iname); + String *str = SwigType_str(type, wname); Printf(f_header, "static %s = %s;\n", str, value); Delete(str); value = wname; @@ -937,37 +906,36 @@ public: return SWIG_OK; } - virtual int nativeWrapper(Node* n) { + virtual int nativeWrapper(Node *n) { return Language::nativeWrapper(n); } - virtual int enumDeclaration(Node* n) { + virtual int enumDeclaration(Node *n) { return Language::enumDeclaration(n); } - virtual int enumvalueDeclaration(Node* n) { + virtual int enumvalueDeclaration(Node *n) { return Language::enumvalueDeclaration(n); } - virtual int classDeclaration(Node* n) { + virtual int classDeclaration(Node *n) { return Language::classDeclaration(n); } - virtual int classHandler(Node* n) { + virtual int classHandler(Node *n) { have_constructor = 0; have_destructor = 0; constructor_name = 0; class_name = Getattr(n, "sym:name"); - if (!addSymbol(class_name, n)) { + if (!addSymbol(class_name, n)) return SWIG_ERROR; - } // This is a bug, due to the fact that swig_type -> octave_class mapping // is 1-to-n. - static Hash* emitted = NewHash(); - String* mangled_classname = Swig_name_mangle(Getattr(n, "name")); + static Hash *emitted = NewHash(); + String *mangled_classname = Swig_name_mangle(Getattr(n, "name")); if (Getattr(emitted, mangled_classname)) { Delete(mangled_classname); return SWIG_NOWRAP; @@ -976,24 +944,24 @@ public: Delete(mangled_classname); assert(!s_members_tab); - s_members_tab = NewStringEmpty(); + s_members_tab = NewString(""); Printv(s_members_tab, "static swig_octave_member swig_", class_name, "_members[] = {\n", NIL); Language::classHandler(n); - SwigType* t = Copy(Getattr(n, "name")); + SwigType *t = Copy(Getattr(n, "name")); SwigType_add_pointer(t); - String* wrap_class = NewStringf("&_wrap_class_%s", class_name); + String *wrap_class = NewStringf("&_wrap_class_%s", class_name); SwigType_remember_clientdata(t, wrap_class); int use_director = Swig_directorclass(n); if (use_director) { - String* nspace = Getattr(n, "sym:nspace"); - String* cname = Swig_name_disown(nspace, class_name); - String* wcname = Swig_name_wrapper(cname); - String* cnameshdw = NewStringf("%s_shadow", cname); - String* wcnameshdw = Swig_name_wrapper(cnameshdw); + String *nspace = Getattr(n, "sym:nspace"); + String *cname = Swig_name_disown(nspace, class_name); + String *wcname = Swig_name_wrapper(cname); + String *cnameshdw = NewStringf("%s_shadow", cname); + String *wcnameshdw = Swig_name_wrapper(cnameshdw); Octave_begin_function(n, f_wrappers, cnameshdw, wcnameshdw, true); Printf(f_wrappers, " if (args.length()!=1) {\n"); Printf(f_wrappers, " error(\"disown takes no arguments\");\n"); @@ -1012,21 +980,21 @@ public: Printf(s_members_tab, "{0,0,0,0}\n};\n"); Printv(f_wrappers, s_members_tab, NIL); - String* base_class_names = NewStringEmpty(); - String* base_class = NewStringEmpty(); - List* baselist = Getattr(n, "bases"); + String *base_class_names = NewString(""); + String *base_class = NewString(""); + List *baselist = Getattr(n, "bases"); if (baselist && Len(baselist)) { Iterator b; int index = 0; b = First(baselist); while (b.item) { - String* bname = Getattr(b.item, "name"); + String *bname = Getattr(b.item, "name"); if ((!bname) || GetFlag(b.item, "feature:ignore") || (!Getattr(b.item, "module"))) { b = Next(b); continue; } - String* bname_mangled = SwigType_manglestr(SwigType_add_pointer(Copy(bname))); + String *bname_mangled = SwigType_manglestr(SwigType_add_pointer(Copy(bname))); Printf(base_class_names, "\"%s\",", bname_mangled); Printf(base_class, "0,"); b = Next(b); @@ -1040,27 +1008,25 @@ public: Printv(f_wrappers, "static swig_octave_class _wrap_class_", class_name, " = {\"", class_name, "\", &SWIGTYPE", SwigType_manglestr(t), ",", NIL); Printv(f_wrappers, Swig_directorclass(n) ? "1," : "0,", NIL); if (have_constructor) { - String* nspace = Getattr(n, "sym:nspace"); - String* cname = Swig_name_construct(nspace, constructor_name); - String* wcname = Swig_name_wrapper(cname); - String* tname = texinfo_name(n); + String *nspace = Getattr(n, "sym:nspace"); + String *cname = Swig_name_construct(nspace, constructor_name); + String *wcname = Swig_name_wrapper(cname); + String *tname = texinfo_name(n); Printf(f_wrappers, "%s,%s,", wcname, tname); Delete(tname); Delete(wcname); Delete(cname); - } else { + } else Printv(f_wrappers, "0,0,", NIL); - } if (have_destructor) { - String* nspace = Getattr(n, "sym:nspace"); - String* cname = Swig_name_destroy(nspace, class_name); - String* wcname = Swig_name_wrapper(cname); + String *nspace = Getattr(n, "sym:nspace"); + String *cname = Swig_name_destroy(nspace, class_name); + String *wcname = Swig_name_wrapper(cname); Printf(f_wrappers, "%s,", wcname); Delete(wcname); Delete(cname); - } else { + } else Printv(f_wrappers, "0", ",", NIL); - } Printf(f_wrappers, "swig_%s_members,swig_%s_base_names,swig_%s_base };\n\n", class_name, class_name, class_name); Delete(base_class); @@ -1073,24 +1039,23 @@ public: return SWIG_OK; } - virtual int memberfunctionHandler(Node* n) { + virtual int memberfunctionHandler(Node *n) { Language::memberfunctionHandler(n); assert(s_members_tab); assert(class_name); - String* name = Getattr(n, "name"); - String* iname = GetChar(n, "sym:name"); - String* realname = iname ? iname : name; - String* wname = Getattr(n, "wrap:name"); + String *name = Getattr(n, "name"); + String *iname = GetChar(n, "sym:name"); + String *realname = iname ? iname : name; + String *wname = Getattr(n, "wrap:name"); assert(wname); if (!Getattr(n, "sym:nextSibling")) { - String* tname = texinfo_name(n); - String* rname = Copy(wname); + String *tname = texinfo_name(n); + String *rname = Copy(wname); bool overloaded = !!Getattr(n, "sym:overloaded"); - if (overloaded) { + if (overloaded) Delslice(rname, Len(rname) - Len(Getattr(n, "sym:overname")), DOH_END); - } Printf(s_members_tab, "{\"%s\",%s,0,0,0,%s},\n", realname, rname, tname); Delete(rname); @@ -1100,18 +1065,18 @@ public: return SWIG_OK; } - virtual int membervariableHandler(Node* n) { + virtual int membervariableHandler(Node *n) { Setattr(n, "feature:autodoc", "0"); Language::membervariableHandler(n); assert(s_members_tab); assert(class_name); - String* symname = Getattr(n, "sym:name"); - String* getname = Swig_name_get(NSPACE_TODO, Swig_name_member(NSPACE_TODO, class_name, symname)); - String* setname = Swig_name_set(NSPACE_TODO, Swig_name_member(NSPACE_TODO, class_name, symname)); - String* getwname = Swig_name_wrapper(getname); - String* setwname = GetFlag(n, "feature:immutable") ? NewString("octave_set_immutable") : Swig_name_wrapper(setname); + String *symname = Getattr(n, "sym:name"); + String *getname = Swig_name_get(NSPACE_TODO, Swig_name_member(NSPACE_TODO, class_name, symname)); + String *setname = Swig_name_set(NSPACE_TODO, Swig_name_member(NSPACE_TODO, class_name, symname)); + String *getwname = Swig_name_wrapper(getname); + String *setwname = GetFlag(n, "feature:immutable") ? NewString("octave_set_immutable") : Swig_name_wrapper(setname); assert(s_members_tab); Printf(s_members_tab, "{\"%s\",0,%s,%s,0,0},\n", symname, getwname, setwname); @@ -1123,26 +1088,24 @@ public: return SWIG_OK; } - virtual int constructorHandler(Node* n) { + virtual int constructorHandler(Node *n) { have_constructor = 1; - if (!constructor_name) { + if (!constructor_name) constructor_name = NewString(Getattr(n, "sym:name")); - } int use_director = Swig_directorclass(n); if (use_director) { - Parm* parms = Getattr(n, "parms"); - Parm* self; - String* name = NewString("self"); - String* type = NewString("void"); + Parm *parms = Getattr(n, "parms"); + Parm *self; + String *name = NewString("self"); + String *type = NewString("void"); SwigType_add_pointer(type); self = NewParm(type, name, n); Delete(type); Delete(name); Setattr(self, "lname", "self_obj"); - if (parms) { + if (parms) set_nextSibling(self, parms); - } Setattr(n, "parms", self); Setattr(n, "wrap:self", "1"); Setattr(n, "hidden", "1"); @@ -1152,29 +1115,28 @@ public: return Language::constructorHandler(n); } - virtual int destructorHandler(Node* n) { + virtual int destructorHandler(Node *n) { have_destructor = 1; return Language::destructorHandler(n); } - virtual int staticmemberfunctionHandler(Node* n) { + virtual int staticmemberfunctionHandler(Node *n) { Language::staticmemberfunctionHandler(n); assert(s_members_tab); assert(class_name); - String* name = Getattr(n, "name"); - String* iname = GetChar(n, "sym:name"); - String* realname = iname ? iname : name; - String* wname = Getattr(n, "wrap:name"); + String *name = Getattr(n, "name"); + String *iname = GetChar(n, "sym:name"); + String *realname = iname ? iname : name; + String *wname = Getattr(n, "wrap:name"); assert(wname); if (!Getattr(n, "sym:nextSibling")) { - String* tname = texinfo_name(n); - String* rname = Copy(wname); + String *tname = texinfo_name(n); + String *rname = Copy(wname); bool overloaded = !!Getattr(n, "sym:overloaded"); - if (overloaded) { + if (overloaded) Delslice(rname, Len(rname) - Len(Getattr(n, "sym:overname")), DOH_END); - } Printf(s_members_tab, "{\"%s\",%s,0,0,1,%s},\n", realname, rname, tname); Delete(rname); @@ -1184,11 +1146,11 @@ public: return SWIG_OK; } - virtual int memberconstantHandler(Node* n) { + virtual int memberconstantHandler(Node *n) { return Language::memberconstantHandler(n); } - virtual int staticmembervariableHandler(Node* n) { + virtual int staticmembervariableHandler(Node *n) { Setattr(n, "feature:autodoc", "0"); Language::staticmembervariableHandler(n); @@ -1196,11 +1158,11 @@ public: if (!GetFlag(n, "wrappedasconstant")) { assert(s_members_tab); assert(class_name); - String* symname = Getattr(n, "sym:name"); - String* getname = Swig_name_get(NSPACE_TODO, Swig_name_member(NSPACE_TODO, class_name, symname)); - String* setname = Swig_name_set(NSPACE_TODO, Swig_name_member(NSPACE_TODO, class_name, symname)); - String* getwname = Swig_name_wrapper(getname); - String* setwname = GetFlag(n, "feature:immutable") ? NewString("octave_set_immutable") : Swig_name_wrapper(setname); + String *symname = Getattr(n, "sym:name"); + String *getname = Swig_name_get(NSPACE_TODO, Swig_name_member(NSPACE_TODO, class_name, symname)); + String *setname = Swig_name_set(NSPACE_TODO, Swig_name_member(NSPACE_TODO, class_name, symname)); + String *getwname = Swig_name_wrapper(getname); + String *setwname = GetFlag(n, "feature:immutable") ? NewString("octave_set_immutable") : Swig_name_wrapper(setname); assert(s_members_tab); Printf(s_members_tab, "{\"%s\",0,%s,%s,1,0},\n", symname, getwname, setwname); @@ -1213,8 +1175,8 @@ public: return SWIG_OK; } - int classDirectorInit(Node* n) { - String* declaration = Swig_director_declaration(n); + int classDirectorInit(Node *n) { + String *declaration = Swig_director_declaration(n); Printf(f_directors_h, "\n"); Printf(f_directors_h, "%s\n", declaration); Printf(f_directors_h, "public:\n"); @@ -1222,24 +1184,24 @@ public: return Language::classDirectorInit(n); } - int classDirectorEnd(Node* n) { + int classDirectorEnd(Node *n) { Printf(f_directors_h, "};\n\n"); return Language::classDirectorEnd(n); } - int classDirectorConstructor(Node* n) { - Node* parent = Getattr(n, "parentNode"); - String* sub = NewStringEmpty(); - String* decl = Getattr(n, "decl"); - String* supername = Swig_class_name(parent); - String* classname = NewStringEmpty(); + int classDirectorConstructor(Node *n) { + Node *parent = Getattr(n, "parentNode"); + String *sub = NewString(""); + String *decl = Getattr(n, "decl"); + String *supername = Swig_class_name(parent); + String *classname = NewString(""); Printf(classname, "SwigDirector_%s", supername); // insert self parameter - Parm* p; - ParmList* superparms = Getattr(n, "parms"); - ParmList* parms = CopyParmList(superparms); - String* type = NewString("void"); + Parm *p; + ParmList *superparms = Getattr(n, "parms"); + ParmList *parms = CopyParmList(superparms); + String *type = NewString("void"); SwigType_add_pointer(type); p = NewParm(type, NewString("self"), n); set_nextSibling(p, parms); @@ -1248,10 +1210,10 @@ public: if (!Getattr(n, "defaultargs")) { // constructor { - Wrapper* w = NewWrapper(); - String* call; - String* basetype = Getattr(parent, "classtype"); - String* target = Swig_method_decl(0, decl, classname, parms, 0, 0); + Wrapper *w = NewWrapper(); + String *call; + String *basetype = Getattr(parent, "classtype"); + String *target = Swig_method_decl(0, decl, classname, parms, 0, 0); call = Swig_csuperclass_call(0, basetype, superparms); Printf(w->def, "%s::%s: %s," "\nSwig::Director(static_cast<%s*>(this)) { \n", classname, target, call, basetype); Append(w->def, "}\n"); @@ -1263,7 +1225,7 @@ public: // constructor header { - String* target = Swig_method_decl(0, decl, classname, parms, 0, 1); + String *target = Swig_method_decl(0, decl, classname, parms, 0, 1); Printf(f_directors_h, " %s;\n", target); Delete(target); } @@ -1276,10 +1238,10 @@ public: return Language::classDirectorConstructor(n); } - int classDirectorDefaultConstructor(Node* n) { - String* classname = Swig_class_name(n); + int classDirectorDefaultConstructor(Node *n) { + String *classname = Swig_class_name(n); { - Wrapper* w = NewWrapper(); + Wrapper *w = NewWrapper(); Printf(w->def, "SwigDirector_%s::SwigDirector_%s(void* self) :" "\nSwig::Director((octave_swig_type*)self,static_cast<%s*>(this)) { \n", classname, classname, classname); Append(w->def, "}\n"); @@ -1291,22 +1253,22 @@ public: return Language::classDirectorDefaultConstructor(n); } - int classDirectorMethod(Node* n, Node* parent, String* super) { + int classDirectorMethod(Node *n, Node *parent, String *super) { int is_void = 0; int is_pointer = 0; - String* decl = Getattr(n, "decl"); - String* returntype = Getattr(n, "type"); - String* name = Getattr(n, "name"); - String* classname = Getattr(parent, "sym:name"); - String* c_classname = Getattr(parent, "name"); - String* symname = Getattr(n, "sym:name"); - String* declaration = NewStringEmpty(); - ParmList* l = Getattr(n, "parms"); - Wrapper* w = NewWrapper(); - String* tm; - String* wrap_args = NewStringEmpty(); - String* value = Getattr(n, "value"); - String* storage = Getattr(n, "storage"); + String *decl = Getattr(n, "decl"); + String *returntype = Getattr(n, "type"); + String *name = Getattr(n, "name"); + String *classname = Getattr(parent, "sym:name"); + String *c_classname = Getattr(parent, "name"); + String *symname = Getattr(n, "sym:name"); + String *declaration = NewString(""); + ParmList *l = Getattr(n, "parms"); + Wrapper *w = NewWrapper(); + String *tm; + String *wrap_args = NewString(""); + String *value = Getattr(n, "value"); + String *storage = Getattr(n, "storage"); bool pure_virtual = false; int status = SWIG_OK; int idx; @@ -1323,10 +1285,10 @@ public: is_void = (!Cmp(returntype, "void") && !is_pointer); // virtual method definition - String* target; - String* pclassname = NewStringf("SwigDirector_%s", classname); - String* qualified_name = NewStringf("%s::%s", pclassname, name); - SwigType* rtype = Getattr(n, "conversion_operator") ? 0 : Getattr(n, "classDirectorMethods:type"); + String *target; + String *pclassname = NewStringf("SwigDirector_%s", classname); + String *qualified_name = NewStringf("%s::%s", pclassname, name); + SwigType *rtype = Getattr(n, "conversion_operator") ? 0 : Getattr(n, "classDirectorMethods:type"); target = Swig_method_decl(rtype, decl, qualified_name, l, 0, 0); Printf(w->def, "%s", target); Delete(qualified_name); @@ -1338,25 +1300,24 @@ public: Delete(target); // Get any exception classes in the throws typemap - ParmList* throw_parm_list = 0; + ParmList *throw_parm_list = 0; if ((throw_parm_list = Getattr(n, "throws")) || Getattr(n, "throw")) { - Parm* p; + Parm *p; int gencomma = 0; Append(w->def, " throw("); Append(declaration, " throw("); - if (throw_parm_list) { + if (throw_parm_list) Swig_typemap_attach_parms("throws", throw_parm_list, 0); - } for (p = throw_parm_list; p; p = nextSibling(p)) { if (Getattr(p, "tmap:throws")) { if (gencomma++) { Append(w->def, ", "); Append(declaration, ", "); } - String* str = SwigType_str(Getattr(p, "type"), 0); + String *str = SwigType_str(Getattr(p, "type"), 0); Append(w->def, str); Append(declaration, str); Delete(str); @@ -1375,7 +1336,7 @@ public: // handle it, including declaration of c_result ($result). if (!is_void) { if (!(ignored_method && !pure_virtual)) { - String* cres = SwigType_lstr(returntype, "c_result"); + String *cres = SwigType_lstr(returntype, "c_result"); Printf(w->code, "%s;\n", cres); Delete(cres); } @@ -1383,10 +1344,9 @@ public: if (ignored_method) { if (!pure_virtual) { - if (!is_void) { + if (!is_void) Printf(w->code, "return "); - } - String* super_call = Swig_method_call(super, l); + String *super_call = Swig_method_call(super, l); Printf(w->code, "%s;\n", super_call); Delete(super_call); } else { @@ -1395,7 +1355,7 @@ public: } } else { // attach typemaps to arguments (C/C++ -> Python) - String* parse_args = NewStringEmpty(); + String *parse_args = NewString(""); Swig_director_parms_fixup(l); @@ -1403,12 +1363,11 @@ public: Swig_typemap_attach_parms("directorin", l, 0); Swig_typemap_attach_parms("directorargout", l, w); - Parm* p; + Parm *p; int outputs = 0; - if (!is_void) { + if (!is_void) outputs++; - } // build argument list and type conversion string p = l; @@ -1418,16 +1377,15 @@ public: continue; } - if (Getattr(p, "tmap:directorargout") != 0) { + if (Getattr(p, "tmap:directorargout") != 0) outputs++; - } - String* pname = Getattr(p, "name"); - String* ptype = Getattr(p, "type"); + String *pname = Getattr(p, "name"); + String *ptype = Getattr(p, "type"); Wrapper_add_local(w, "tmpv", "octave_value tmpv"); if ((tm = Getattr(p, "tmap:directorin")) != 0) { - String* parse = Getattr(p, "tmap:directorin:parse"); + String *parse = Getattr(p, "tmap:directorin:parse"); if (!parse) { Setattr(p, "emit:directorinput", "tmpv"); Replaceall(tm, "$input", "tmpv"); @@ -1440,9 +1398,8 @@ public: Setattr(p, "emit:directorinput", pname); Replaceall(tm, "$input", pname); Replaceall(tm, "$owner", "0"); - if (Len(tm) == 0) { + if (Len(tm) == 0) Append(tm, pname); - } } p = Getattr(p, "tmap:directorin:next"); continue; @@ -1456,7 +1413,7 @@ public: p = nextSibling(p); } - String* method_name = Getattr(n, "sym:name"); + String *method_name = Getattr(n, "sym:name"); Printv(w->code, wrap_args, NIL); @@ -1468,8 +1425,8 @@ public: Printf(w->code, "idx.push_back(args);\n"); Printf(w->code, "out=swig_get_self()->subsref(\".(\",idx,%d);\n", outputs); - String* cleanup = NewStringEmpty(); - String* outarg = NewStringEmpty(); + String *cleanup = NewString(""); + String *outarg = NewString(""); idx = 0; // marshal return value @@ -1522,7 +1479,7 @@ public: if (!is_void) { if (!(ignored_method && !pure_virtual)) { - String* rettype = SwigType_str(returntype, 0); + String *rettype = SwigType_str(returntype, 0); if (!SwigType_isreference(returntype)) { Printf(w->code, "return (%s) c_result;\n", rettype); } else { @@ -1535,16 +1492,15 @@ public: Append(w->code, "}\n"); // We expose protected methods via an extra public inline method which makes a straight call to the wrapped class' method - String* inline_extra_method = NewStringEmpty(); + String *inline_extra_method = NewString(""); if (dirprot_mode() && !is_public(n) && !pure_virtual) { Printv(inline_extra_method, declaration, NIL); - String* extra_method_name = NewStringf("%sSwigPublic", name); + String *extra_method_name = NewStringf("%sSwigPublic", name); Replaceall(inline_extra_method, name, extra_method_name); Replaceall(inline_extra_method, ";\n", " {\n "); - if (!is_void) { + if (!is_void) Printf(inline_extra_method, "return "); - } - String* methodcall = Swig_method_call(super, l); + String *methodcall = Swig_method_call(super, l); Printv(inline_extra_method, methodcall, ";\n }\n", NIL); Delete(methodcall); Delete(extra_method_name); @@ -1565,9 +1521,9 @@ public: return status; } - String* runtimeCode() { - String* s = NewStringEmpty(); - String* srun = Swig_include_sys("octrun.swg"); + String *runtimeCode() { + String *s = NewString(""); + String *srun = Swig_include_sys("octrun.swg"); if (!srun) { Printf(stderr, "*** Unable to open 'octrun.swg'\n"); } else { @@ -1577,12 +1533,11 @@ public: return s; } - String* defaultExternalRuntimeFilename() { + String *defaultExternalRuntimeFilename() { return NewString("swigoctaverun.h"); } }; -extern "C" Language* swig_octave(void) -{ +extern "C" Language *swig_octave(void) { return new OCTAVE(); } -- cgit v1.2.1 From 023037b122fc50e9bcce8bd9840bfe3fe73a699d Mon Sep 17 00:00:00 2001 From: William S Fulton Date: Fri, 10 Oct 2014 20:30:17 +0100 Subject: Tcl documentation fixes Mostly suggestions from Ben Golding on swig-devel mailing list [skip ci] --- Doc/Manual/Tcl.html | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/Doc/Manual/Tcl.html b/Doc/Manual/Tcl.html index d4bf91970..8fc917070 100644 --- a/Doc/Manual/Tcl.html +++ b/Doc/Manual/Tcl.html @@ -2365,7 +2365,7 @@ Tcl extension by specifying the following in an interface file : $action // Gets substituted by actual function call } catch (RangeError) { - Tcl_SetStringObj(tcl_result,"Array index out-of-bounds"); + Tcl_SetResult(interp, (char *)"Array index out-of-bounds", TCL_STATIC); return TCL_ERROR; } } @@ -2384,7 +2384,7 @@ exception handler to only apply to specific methods like this: $action } catch (RangeError) { - Tcl_SetStringObj(tcl_result,"Array index out-of-bounds"); + Tcl_SetResult(interp, (char *)"Array index out-of-bounds", TCL_STATIC); return TCL_ERROR; } } @@ -2394,7 +2394,7 @@ exception handler to only apply to specific methods like this: $action } catch (RangeError) { - Tcl_SetStringObj(tcl_result,"Array index out-of-bounds"); + Tcl_SetResult(interp, (char *)"Array index out-of-bounds", TCL_STATIC); return TCL_ERROR; } } @@ -2419,7 +2419,7 @@ For example: $action } catch (RangeError) { - Tcl_SetStringObj(tcl_result,"Array index out-of-bounds"); + Tcl_SetResult(interp, (char *)"Array index out-of-bounds", TCL_STATIC); return TCL_ERROR; } } @@ -2921,7 +2921,6 @@ int Tcl_GetDoubleFromObj(Tcl_Interp *, Tcl_Obj *o, double *dp);
     Tcl_Obj  *Tcl_NewStringObj(char *str, int len);
    -void      Tcl_SetStringObj(Tcl_Obj *obj, char *str, int len);
     char     *Tcl_GetStringFromObj(Tcl_Obj *obj, int *len);
     void      Tcl_AppendToObj(Tcl_Obj *obj, char *str, int len);
     
    @@ -3037,9 +3036,10 @@ work)
    -%typemap(out) char * {
    -   Tcl_SetStringObj($result,$1);
    +%typemap(out,noblock=1,fragment="SWIG_FromCharPtr") char *, const char * {
    +  Tcl_SetObjResult(interp,SWIG_FromCharPtr((const char *)$1));
     }
    +
     
    -- cgit v1.2.1 From e7b35c796e99468fdb4146783ecdeefc992c7d34 Mon Sep 17 00:00:00 2001 From: William S Fulton Date: Fri, 10 Oct 2014 21:31:46 +0100 Subject: Add Python -builtin Travis testing --- .travis.yml | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/.travis.yml b/.travis.yml index 8521e0cc6..fe01df47e 100644 --- a/.travis.yml +++ b/.travis.yml @@ -42,6 +42,10 @@ matrix: env: SWIGLANG=python PY3=3 VER=3.3 - compiler: gcc env: SWIGLANG=python PY3=3 VER=3.4 + - compiler: gcc + env: SWIGLANG=python SWIG_FEATURES=-builtin + - compiler: gcc + env: SWIGLANG=python SWIG_FEATURES=-builtin PY3=1 - compiler: gcc env: SWIGLANG=ruby - compiler: gcc -- cgit v1.2.1 From 361e0ede60927619856e214e63656ab3b5270c56 Mon Sep 17 00:00:00 2001 From: William S Fulton Date: Fri, 10 Oct 2014 23:00:27 +0100 Subject: Changes file entry for Python director property fix --- CHANGES.current | 3 +++ 1 file changed, 3 insertions(+) diff --git a/CHANGES.current b/CHANGES.current index 781b21c1c..09d446509 100644 --- a/CHANGES.current +++ b/CHANGES.current @@ -5,6 +5,9 @@ See the RELEASENOTES file for a summary of changes in each release. Version 3.0.3 (in progress) =========================== +2014-10-10: diorcety + [Python] Patch #232 Fix property access using directors + 2014-09-23: wsfulton [Python] Add patch from Thomas Maslach to fix crash in wrappers when using -threads in the STL iterators (SwigPyIterator destructor). -- cgit v1.2.1 From 31ae3fe79d9ee24af4d828ba3facef5b2dd7b511 Mon Sep 17 00:00:00 2001 From: William S Fulton Date: Fri, 10 Oct 2014 23:06:39 +0100 Subject: Fix Travis PY3 testing for -builtin --- .travis.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.travis.yml b/.travis.yml index fe01df47e..ce15e294b 100644 --- a/.travis.yml +++ b/.travis.yml @@ -45,7 +45,7 @@ matrix: - compiler: gcc env: SWIGLANG=python SWIG_FEATURES=-builtin - compiler: gcc - env: SWIGLANG=python SWIG_FEATURES=-builtin PY3=1 + env: SWIGLANG=python SWIG_FEATURES=-builtin PY3=3 - compiler: gcc env: SWIGLANG=ruby - compiler: gcc -- cgit v1.2.1 From ef4d44e92d58e9045a7ea7c18dad6ee34614bc8b Mon Sep 17 00:00:00 2001 From: William S Fulton Date: Fri, 10 Oct 2014 23:56:14 +0100 Subject: Fix syntax error in autodoc testcase when using Python 2.4 and earlier --- Examples/test-suite/python/autodoc_runme.py | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/Examples/test-suite/python/autodoc_runme.py b/Examples/test-suite/python/autodoc_runme.py index 3cc9400f6..24a1c2834 100644 --- a/Examples/test-suite/python/autodoc_runme.py +++ b/Examples/test-suite/python/autodoc_runme.py @@ -3,7 +3,9 @@ import sys def check(got, expected, expected_builtin = None, skip = False): if not skip: - expect = expected_builtin if is_python_builtin() and expected_builtin != None else expected + expect = expected + if is_python_builtin() and expected_builtin != None: + expect = expected_builtin if expect != got: raise RuntimeError("\n" + "Expected: [" + str(expect) + "]\n" + "Got : [" + str(got) + "]") -- cgit v1.2.1 From aeacff3b145c6b09c40273fdd0b98278643a8339 Mon Sep 17 00:00:00 2001 From: Yann Diorcet Date: Sat, 11 Oct 2014 20:20:10 +0200 Subject: Improve cpp11_function_objects test for python --- Examples/test-suite/cpp11_function_objects.i | 18 ++++++++++++------ .../test-suite/python/cpp11_function_objects_runme.py | 11 +++++++++++ 2 files changed, 23 insertions(+), 6 deletions(-) diff --git a/Examples/test-suite/cpp11_function_objects.i b/Examples/test-suite/cpp11_function_objects.i index fb75edea6..95816d194 100644 --- a/Examples/test-suite/cpp11_function_objects.i +++ b/Examples/test-suite/cpp11_function_objects.i @@ -3,25 +3,31 @@ Function objects are objects which overload the operator() function. The std::function does not provide any seamless support in the target languages yet. */ -%module cpp11_function_objects +%module(directors="1") cpp11_function_objects %rename(__call__) Test::operator(); +%feature("director") Test; + %inline %{ -struct Test { +class Test { +public: int value; - void operator()(int x, int y) { + virtual void operator()(int x, int y) { value=x+y; } Test() : value(0) {} -} test; + ~Test() {} +}; + +Test test; #include std::function pF = test; -int testit1(Test new_test, int a, int b) { - pF = new_test; +int testit1(Test &new_test, int a, int b) { + pF = std::ref(new_test); pF(a, b); return new_test.value; } diff --git a/Examples/test-suite/python/cpp11_function_objects_runme.py b/Examples/test-suite/python/cpp11_function_objects_runme.py index aac7f9c5f..5a63b632b 100644 --- a/Examples/test-suite/python/cpp11_function_objects_runme.py +++ b/Examples/test-suite/python/cpp11_function_objects_runme.py @@ -1,6 +1,13 @@ import cpp11_function_objects import sys +class Test1(cpp11_function_objects.Test): + def __init__(self): + cpp11_function_objects.Test.__init__(self) + + def __call__(self, a, b): + self.value = a * b + t = cpp11_function_objects.Test() if t.value != 0: raise RuntimeError("Runtime cpp11_function_objects failed. t.value should be 0, but is " + str(t.value)) @@ -10,3 +17,7 @@ t(1,2) # adds numbers and sets value if t.value != 3: raise RuntimeError("Runtime cpp11_function_objects failed. t.value not changed - should be 3, but is " + str(t.value)) +t2 = Test1() +a = cpp11_function_objects.testit1(t2, 4,3) +if a != 12: + raise RuntimeError("Runtime cpp11_function_objects failed. t.value not changed - should be 12, but is " + str(a)) -- cgit v1.2.1 From 1226970b9f23c2e8f32191f872d30d14ec8eb4fb Mon Sep 17 00:00:00 2001 From: Ian Lance Taylor Date: Sat, 11 Oct 2014 19:07:14 -0700 Subject: [Go] More fixes for Go 1.4. Ensure that values with argout or freearg typemapes escape, and refer to them using local variables loaded at the start of the function, in case the argout or freearg template causes a stack copy. --- Source/Modules/go.cxx | 50 ++++++++++++++++++++++++++++++++++++++++++-------- 1 file changed, 42 insertions(+), 8 deletions(-) diff --git a/Source/Modules/go.cxx b/Source/Modules/go.cxx index c9910ab05..a5766dfd8 100644 --- a/Source/Modules/go.cxx +++ b/Source/Modules/go.cxx @@ -919,6 +919,18 @@ private: } else if (goTypeIsInterface(p, ty) || Getattr(p, "tmap:goin")) { needs_wrapper = true; } + + // If the parameter has an argout or freearg typemap, we need to + // make sure that it escapes, in case it contains any pointers. + if (Getattr(p, "tmap:argout") || Getattr(p, "tmap:freearg")) { + if (!goTypeIsInterface(p, Getattr(p, "type"))) { + String *tm = goWrapperType(p, Getattr(p, "type"), false); + Printf(f_go_wrappers, "var %s_escape_%d %s\n", wname, i, tm); + Delete(tm); + needs_wrapper = true; + } + } + p = nextParm(p); } if (goTypeIsInterface(n, result) || goout != NULL) { @@ -1204,6 +1216,15 @@ private: Setattr(p, "emit:goinput", ivar); } + // If the parameter has an argout or freearg typemap, make + // sure that it escapes. + if (Getattr(p, "tmap:argout") || Getattr(p, "tmap:freearg")) { + // No need to do anything for C++ class type. + if (!goTypeIsInterface(p, pt)) { + Printf(f_go_wrappers, "\t%s_escape_%d = %s\n", wname, i, Getattr(p, "emit:goinput")); + } + } + p = nextParm(p); } Printv(call, ")\n", NULL); @@ -1342,11 +1363,19 @@ private: Parm *p = parms; for (int i = 0; i < parm_count; ++i) { p = getParm(p); + String *ln = Getattr(p, "lname"); SwigType *pt = Getattr(p, "type"); String *ct = gcCTypeForGoValue(p, pt, ln); Printv(f->code, "\t\t\t", ct, ";\n", NULL); Delete(ct); + + String *gn = NewStringf("_swig_go_%d", i); + ct = gcCTypeForGoValue(p, pt, gn); + Setattr(p, "emit:input", gn); + Wrapper_add_local(f, gn, ct); + Delete(ct); + p = nextParm(p); } if (SwigType_type(result) != T_VOID) { @@ -1367,23 +1396,28 @@ private: Printv(f->code, "\n", NULL); - // Copy the input arguments out of the structure into the - // parameter variables. - + // Copy the input arguments out of the structure into the Go local + // variables. p = parms; for (int i = 0; i < parm_count; ++i) { p = getParm(p); + String *ln = Getattr(p, "lname"); + String *gn = Getattr(p, "emit:input"); + Printv(f->code, "\t", gn, " = swig_a->", ln, ";\n", NULL); + p = nextParm(p); + } + // Apply the in typemaps. + p = parms; + for (int i = 0; i < parm_count; ++i) { + p = getParm(p); String *tm = Getattr(p, "tmap:in"); if (!tm) { Swig_warning(WARN_TYPEMAP_IN_UNDEF, input_file, line_number, "Unable to use type %s as a function argument\n", SwigType_str(Getattr(p, "type"), 0)); } else { - String *ln = Getattr(p, "lname"); - String *input = NewString(""); - Printv(input, "swig_a->", ln, NULL); tm = Copy(tm); - Replaceall(tm, "$input", input); - Setattr(p, "emit:input", input); + String *gn = Getattr(p, "emit:input"); + Replaceall(tm, "$input", gn); if (i < required_count) { Printv(f->code, "\t", tm, "\n", NULL); } else { -- cgit v1.2.1 From 17721f46823e32a6ad7e41ee926a4777c0e74205 Mon Sep 17 00:00:00 2001 From: William S Fulton Date: Mon, 13 Oct 2014 19:38:47 +0100 Subject: Correct cpp11_function_objects testcase Fixes SWIG warning --- Examples/test-suite/cpp11_function_objects.i | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Examples/test-suite/cpp11_function_objects.i b/Examples/test-suite/cpp11_function_objects.i index 95816d194..e80f60a2f 100644 --- a/Examples/test-suite/cpp11_function_objects.i +++ b/Examples/test-suite/cpp11_function_objects.i @@ -18,7 +18,7 @@ public: value=x+y; } Test() : value(0) {} - ~Test() {} + virtual ~Test() {} }; Test test; -- cgit v1.2.1 From 0577ff22204326e3f7e09ab5c9f33028dde07b25 Mon Sep 17 00:00:00 2001 From: Ian Lance Taylor Date: Tue, 14 Oct 2014 10:05:43 -0700 Subject: [Go] Adjust last patch to avoid write-after-write data race on global variable. Only set the variable if another global variable is true, but that variable is always false. The effect is that the variable is never written, but as far as the compiler is concerned it might escape. --- Lib/go/goruntime.swg | 10 ++++++++++ Source/Modules/go.cxx | 45 +++++++++++++++++++++++++++++++-------------- 2 files changed, 41 insertions(+), 14 deletions(-) diff --git a/Lib/go/goruntime.swg b/Lib/go/goruntime.swg index a61837074..ef64186b7 100644 --- a/Lib/go/goruntime.swg +++ b/Lib/go/goruntime.swg @@ -225,6 +225,16 @@ type _ unsafe.Pointer %} +/* Swig_always_false is used to conditionally assign parameters to + Swig_escape_val so that the compiler thinks that they escape. We + only assign them if Swig_always_false is true, which it never is. + We export the variable so that the compiler doesn't realize that it + is never set. */ +%insert(go_header) %{ +var Swig_escape_always_false bool +var Swig_escape_val interface{} +%} + /* Function pointers are translated by the code in go.cxx into _swig_fnptr. Member pointers are translated to _swig_memberptr. */ diff --git a/Source/Modules/go.cxx b/Source/Modules/go.cxx index a5766dfd8..4f706e0d6 100644 --- a/Source/Modules/go.cxx +++ b/Source/Modules/go.cxx @@ -920,15 +920,8 @@ private: needs_wrapper = true; } - // If the parameter has an argout or freearg typemap, we need to - // make sure that it escapes, in case it contains any pointers. - if (Getattr(p, "tmap:argout") || Getattr(p, "tmap:freearg")) { - if (!goTypeIsInterface(p, Getattr(p, "type"))) { - String *tm = goWrapperType(p, Getattr(p, "type"), false); - Printf(f_go_wrappers, "var %s_escape_%d %s\n", wname, i, tm); - Delete(tm); - needs_wrapper = true; - } + if (paramNeedsEscape(p)) { + needs_wrapper = true; } p = nextParm(p); @@ -1218,11 +1211,10 @@ private: // If the parameter has an argout or freearg typemap, make // sure that it escapes. - if (Getattr(p, "tmap:argout") || Getattr(p, "tmap:freearg")) { - // No need to do anything for C++ class type. - if (!goTypeIsInterface(p, pt)) { - Printf(f_go_wrappers, "\t%s_escape_%d = %s\n", wname, i, Getattr(p, "emit:goinput")); - } + if (paramNeedsEscape(p)) { + Printv(f_go_wrappers, "\tif Swig_escape_always_false {\n", NULL); + Printv(f_go_wrappers, "\t\tSwig_escape_val = ", Getattr(p, "emit:goinput"), "\n", NULL); + Printv(f_go_wrappers, "\t}\n", NULL); } p = nextParm(p); @@ -1291,6 +1283,31 @@ private: return "base"; } + /* ---------------------------------------------------------------------- + * paramNeedsEscape() + * + * A helper for goFunctionWrapper that returns whether a parameter + * needs to explicitly escape. This is true if the parameter has a + * non-empty argout or freearg typemap, because in those cases the + * Go argument might be or contain a pointer. We need to ensure + * that that pointer does not oint into the stack, which means that + * it needs to escape. + * ---------------------------------------------------------------------- */ + bool paramNeedsEscape(Parm *p) { + String *argout = Getattr(p, "tmap:argout"); + String *freearg = Getattr(p, "tmap:freearg"); + if ((!argout || Len(argout) == 0) && (!freearg || Len(freearg) == 0)) { + return false; + } + // If a C++ type is represented as an interface type in Go, then + // we don't care whether it escapes, because we know that the + // pointer is a C++ pointer. + if (goTypeIsInterface(p, Getattr(p, "type"))) { + return false; + } + return true; + } + /* ---------------------------------------------------------------------- * gcFunctionWrapper() * -- cgit v1.2.1 From 8441e3eab47e6e52e3999399361d708fe4d0c413 Mon Sep 17 00:00:00 2001 From: William S Fulton Date: Mon, 13 Oct 2014 20:20:33 +0100 Subject: Java gc tests failure fix Sometimes the GC just won't run the finalizers, so we output a warning instead of throwing an error, so now the test-suite will pass but with a warning if the number of objects is not as expected. Was notably failing on RHEL6 using OpenSUSE build testing with openjdk-1.6 --- Examples/test-suite/java/java_director_runme.java | 2 +- Examples/test-suite/java/li_boost_shared_ptr_runme.java | 2 +- Examples/test-suite/java/li_std_auto_ptr_runme.java | 4 ++-- 3 files changed, 4 insertions(+), 4 deletions(-) diff --git a/Examples/test-suite/java/java_director_runme.java b/Examples/test-suite/java/java_director_runme.java index 812e791f4..2167d2621 100644 --- a/Examples/test-suite/java/java_director_runme.java +++ b/Examples/test-suite/java/java_director_runme.java @@ -53,7 +53,7 @@ public class java_director_runme { }; int actualCount = Quux.instances(); if (actualCount != expectedCount) - throw new RuntimeException("Expected count: " + expectedCount + " Actual count: " + actualCount); + System.err.println("GC failed to run (java_director). Expected count: " + expectedCount + " Actual count: " + actualCount); // Finalizers are not guaranteed to be run and sometimes they just don't } /* Test Quux1's director disconnect method rename */ diff --git a/Examples/test-suite/java/li_boost_shared_ptr_runme.java b/Examples/test-suite/java/li_boost_shared_ptr_runme.java index aa355c86a..64c356f8e 100644 --- a/Examples/test-suite/java/li_boost_shared_ptr_runme.java +++ b/Examples/test-suite/java/li_boost_shared_ptr_runme.java @@ -59,7 +59,7 @@ public class li_boost_shared_ptr_runme { } int actualCount = Klass.getTotal_count(); if (actualCount != expectedCount) - throw new RuntimeException("Expected count: " + expectedCount + " Actual count: " + actualCount); + System.err.println("GC failed to run (li_boost_shared_ptr). Expected count: " + expectedCount + " Actual count: " + actualCount); // Finalizers are not guaranteed to be run and sometimes they just don't } int wrapper_count = li_boost_shared_ptr.shared_ptr_wrapper_count(); diff --git a/Examples/test-suite/java/li_std_auto_ptr_runme.java b/Examples/test-suite/java/li_std_auto_ptr_runme.java index db34fb529..50ed113a4 100644 --- a/Examples/test-suite/java/li_std_auto_ptr_runme.java +++ b/Examples/test-suite/java/li_std_auto_ptr_runme.java @@ -43,7 +43,7 @@ public class li_std_auto_ptr_runme { } int actualCount = Klass.getTotal_count(); if (actualCount != expectedCount) - throw new RuntimeException("Expected count: " + expectedCount + " Actual count: " + actualCount); + System.err.println("GC failed to run (li_std_auto_ptr 1). Expected count: " + expectedCount + " Actual count: " + actualCount); // Finalizers are not guaranteed to be run and sometimes they just don't } if (!k2.getLabel().equals("second")) @@ -62,7 +62,7 @@ public class li_std_auto_ptr_runme { }; int actualCount = Klass.getTotal_count(); if (actualCount != expectedCount) - throw new RuntimeException("Expected count: " + expectedCount + " Actual count: " + actualCount); + System.err.println("GC failed to run (li_std_auto_ptr 2). Expected count: " + expectedCount + " Actual count: " + actualCount); // Finalizers are not guaranteed to be run and sometimes they just don't } } } -- cgit v1.2.1 From 42da040a07916f914419215c34c702140d36f198 Mon Sep 17 00:00:00 2001 From: William S Fulton Date: Tue, 14 Oct 2014 07:27:08 +0100 Subject: Show mono info in 'make check-csharp-version' For diagnosing configuration of mono runtime --- Examples/Makefile.in | 1 + 1 file changed, 1 insertion(+) diff --git a/Examples/Makefile.in b/Examples/Makefile.in index b7dc7d101..5162ba37f 100644 --- a/Examples/Makefile.in +++ b/Examples/Makefile.in @@ -1396,6 +1396,7 @@ csharp_run: # Version check below also works with MS csc.exe which does not understand --version csharp_version: $(CSHARPCOMPILER) --version | head -n 1 + if test -n "$(CSHARPCILINTERPRETER)" ; then "$(CSHARPCILINTERPRETER)" --version ; fi # ----------------------------------------------------------------- # Cleaning the CSharp examples -- cgit v1.2.1 From 78de526b1d2bded55fd20652d743550b97d62175 Mon Sep 17 00:00:00 2001 From: Bruce Mitchener Date: Wed, 15 Oct 2014 18:38:39 +0700 Subject: [js] v8-shell.cxx had some Windows line endings. --- Tools/javascript/v8_shell.cxx | 444 +++++++++++++++++++++--------------------- 1 file changed, 222 insertions(+), 222 deletions(-) diff --git a/Tools/javascript/v8_shell.cxx b/Tools/javascript/v8_shell.cxx index bc90c1f10..7016e9c31 100644 --- a/Tools/javascript/v8_shell.cxx +++ b/Tools/javascript/v8_shell.cxx @@ -1,16 +1,16 @@ -#include -#include -#include -#include -#include - -#include -#include - -#include "js_shell.h" - -typedef int (*V8ExtensionInitializer) (v8::Handle module); - +#include +#include +#include +#include +#include + +#include +#include + +#include "js_shell.h" + +typedef int (*V8ExtensionInitializer) (v8::Handle module); + // Note: these typedefs and defines are used to deal with v8 API changes since version 3.19.00 #if (SWIG_V8_VERSION < 0x031903) @@ -65,90 +65,90 @@ typedef v8::Persistent SwigV8Context; typedef v8::Local SwigV8Context; #endif -class V8Shell: public JSShell { - -public: - V8Shell(); - - virtual ~V8Shell(); - +class V8Shell: public JSShell { + +public: + V8Shell(); + + virtual ~V8Shell(); + virtual bool RunScript(const std::string &scriptPath); - - virtual bool RunShell(); - - -protected: - - virtual bool InitializeEngine(); - + + virtual bool RunShell(); + + +protected: + + virtual bool InitializeEngine(); + virtual bool ExecuteScript(const std::string &source, const std::string &scriptPath); - - virtual bool DisposeEngine(); - -private: - + + virtual bool DisposeEngine(); + +private: + v8::Handle Import(const std::string &moduleName); - + SwigV8Context CreateShellContext(); - + void ReportException(v8::TryCatch *handler); - + static SwigV8ReturnValue Print(const SwigV8Arguments &args); - + static SwigV8ReturnValue Require(const SwigV8Arguments &args); - + static SwigV8ReturnValue Quit(const SwigV8Arguments &args); - + static SwigV8ReturnValue Version(const SwigV8Arguments &args); - + static const char* ToCString(const v8::String::Utf8Value &value); - -}; - -#ifdef __GNUC__ -#include -#define LOAD_SYMBOL(handle, name) dlsym(handle, name) -#else -#error "implement dll loading" -#endif - + +}; + +#ifdef __GNUC__ +#include +#define LOAD_SYMBOL(handle, name) dlsym(handle, name) +#else +#error "implement dll loading" +#endif + V8Shell::V8Shell() {} - -V8Shell::~V8Shell() {} - + +V8Shell::~V8Shell() {} + bool V8Shell::RunScript(const std::string &scriptPath) { std::string source = ReadFile(scriptPath); - + v8::Isolate *isolate = v8::Isolate::New(); v8::Isolate::Scope isolate_scope(isolate); SWIGV8_HANDLESCOPE(); SwigV8Context context = CreateShellContext(); - - if (context.IsEmpty()) { - printf("Could not create context.\n"); - return false; - } - + + if (context.IsEmpty()) { + printf("Could not create context.\n"); + return false; + } + context->Enter(); - - // Store a pointer to this shell for later use - v8::Handle global = context->Global(); + // Store a pointer to this shell for later use + + v8::Handle global = context->Global(); v8::Local __shell__ = SWIGV8_EXTERNAL_NEW((void*) (long) this); global->SetHiddenValue(SWIGV8_STRING_NEW("__shell__"), __shell__); - - // Node.js compatibility: make `print` available as `console.log()` - ExecuteScript("var console = {}; console.log = print;", ""); - + + // Node.js compatibility: make `print` available as `console.log()` + ExecuteScript("var console = {}; console.log = print;", ""); + bool success = ExecuteScript(source, scriptPath); - + // Cleanup - + context->Exit(); - + #if (SWIG_V8_VERSION < 0x031710) context.Dispose(); #elif (SWIG_V8_VERSION < 0x031900) @@ -166,32 +166,32 @@ bool V8Shell::RunShell() { SWIGV8_HANDLESCOPE(); SwigV8Context context = CreateShellContext(); - - if (context.IsEmpty()) { - printf("Could not create context.\n"); - return false; - } - - context->Enter(); - - v8::Context::Scope context_scope(context); - - ExecuteScript("var console = {}; console.log = print;", ""); - - static const int kBufferSize = 1024; - while (true) { - char buffer[kBufferSize]; - printf("> "); + + if (context.IsEmpty()) { + printf("Could not create context.\n"); + return false; + } + + context->Enter(); + + v8::Context::Scope context_scope(context); + + ExecuteScript("var console = {}; console.log = print;", ""); + + static const int kBufferSize = 1024; + while (true) { + char buffer[kBufferSize]; + printf("> "); char *str = fgets(buffer, kBufferSize, stdin); - if (str == NULL) break; - std::string source(str); - ExecuteScript(source, "(shell)"); - } - printf("\n"); - + if (str == NULL) break; + std::string source(str); + ExecuteScript(source, "(shell)"); + } + printf("\n"); + // Cleanup - context->Exit(); + context->Exit(); #if (SWIG_V8_VERSION < 0x031710) context.Dispose(); @@ -202,53 +202,53 @@ bool V8Shell::RunShell() { #endif // v8::V8::Dispose(); - - return true; -} - - -bool V8Shell::InitializeEngine() { - return true; -} - + + return true; +} + + +bool V8Shell::InitializeEngine() { + return true; +} + bool V8Shell::ExecuteScript(const std::string &source, const std::string &name) { SWIGV8_HANDLESCOPE(); - v8::TryCatch try_catch; + v8::TryCatch try_catch; v8::Handle script = v8::Script::Compile(SWIGV8_STRING_NEW(source.c_str()), SWIGV8_STRING_NEW(name.c_str())); - - // Stop if script is empty - if (script.IsEmpty()) { - // Print errors that happened during compilation. - ReportException(&try_catch); - return false; - } - - v8::Handle result = script->Run(); - - // Print errors that happened during execution. - if (try_catch.HasCaught()) { - ReportException(&try_catch); - return false; - } else { - return true; - } -} - -bool V8Shell::DisposeEngine() { - return true; -} - + + // Stop if script is empty + if (script.IsEmpty()) { + // Print errors that happened during compilation. + ReportException(&try_catch); + return false; + } + + v8::Handle result = script->Run(); + + // Print errors that happened during execution. + if (try_catch.HasCaught()) { + ReportException(&try_catch); + return false; + } else { + return true; + } +} + +bool V8Shell::DisposeEngine() { + return true; +} + SwigV8Context V8Shell::CreateShellContext() { - // Create a template for the global object. - v8::Handle global = v8::ObjectTemplate::New(); - - // Bind global functions + // Create a template for the global object. + v8::Handle global = v8::ObjectTemplate::New(); + + // Bind global functions global->Set(SWIGV8_STRING_NEW("print"), SWIGV8_FUNCTEMPLATE_NEW(V8Shell::Print)); global->Set(SWIGV8_STRING_NEW("quit"), SWIGV8_FUNCTEMPLATE_NEW(V8Shell::Quit)); global->Set(SWIGV8_STRING_NEW("require"), SWIGV8_FUNCTEMPLATE_NEW(V8Shell::Require)); global->Set(SWIGV8_STRING_NEW("version"), SWIGV8_FUNCTEMPLATE_NEW(V8Shell::Version)); - + #if (SWIG_V8_VERSION < 0x031900) SwigV8Context context = v8::Context::New(NULL, global); return context; @@ -256,133 +256,133 @@ SwigV8Context V8Shell::CreateShellContext() { SwigV8Context context = v8::Context::New(v8::Isolate::GetCurrent(), NULL, global); return context; #endif -} - +} + v8::Handle V8Shell::Import(const std::string &module_path) -{ +{ SWIGV8_HANDLESCOPE_ESC(); - - HANDLE library; - std::string module_name = LoadModule(module_path, &library); - - std::string symname = std::string(module_name).append("_initialize"); - - V8ExtensionInitializer init_function = reinterpret_cast((long) LOAD_SYMBOL(library, symname.c_str())); - - if(init_function == 0) { - printf("Could not find initializer function."); + + HANDLE library; + std::string module_name = LoadModule(module_path, &library); + + std::string symname = std::string(module_name).append("_initialize"); + + V8ExtensionInitializer init_function = reinterpret_cast((long) LOAD_SYMBOL(library, symname.c_str())); + + if(init_function == 0) { + printf("Could not find initializer function."); return SWIGV8_UNDEFINED(); - } - + } + v8::Local module = SWIGV8_OBJECT_NEW(); - init_function(module); + init_function(module); SWIGV8_ESCAPE(module); -} - +} + SwigV8ReturnValue V8Shell::Print(const SwigV8Arguments &args) { SWIGV8_HANDLESCOPE(); - bool first = true; - for (int i = 0; i < args.Length(); i++) { + bool first = true; + for (int i = 0; i < args.Length(); i++) { - if (first) { - first = false; - } else { - printf(" "); - } - v8::String::Utf8Value str(args[i]); + if (first) { + first = false; + } else { + printf(" "); + } + v8::String::Utf8Value str(args[i]); const char *cstr = V8Shell::ToCString(str); - printf("%s", cstr); - } - printf("\n"); - fflush(stdout); + printf("%s", cstr); + } + printf("\n"); + fflush(stdout); SWIGV8_RETURN(SWIGV8_UNDEFINED()); -} - +} + SwigV8ReturnValue V8Shell::Require(const SwigV8Arguments &args) { SWIGV8_HANDLESCOPE(); - - if (args.Length() != 1) { - printf("Illegal arguments for `require`"); - }; - - v8::String::Utf8Value str(args[0]); + + if (args.Length() != 1) { + printf("Illegal arguments for `require`"); + }; + + v8::String::Utf8Value str(args[0]); const char *cstr = V8Shell::ToCString(str); - std::string moduleName(cstr); - + std::string moduleName(cstr); + v8::Local global = SWIGV8_CURRENT_CONTEXT()->Global(); v8::Local hidden = global->GetHiddenValue(SWIGV8_STRING_NEW("__shell__")); - v8::Local __shell__ = v8::Local::Cast(hidden); + v8::Local __shell__ = v8::Local::Cast(hidden); V8Shell *_this = (V8Shell *) (long) __shell__->Value(); - - v8::Handle module = _this->Import(moduleName); - + + v8::Handle module = _this->Import(moduleName); + SWIGV8_RETURN(module); -} - +} + SwigV8ReturnValue V8Shell::Quit(const SwigV8Arguments &args) { SWIGV8_HANDLESCOPE(); - int exit_code = args[0]->Int32Value(); - fflush(stdout); - fflush(stderr); - exit(exit_code); + int exit_code = args[0]->Int32Value(); + fflush(stdout); + fflush(stderr); + exit(exit_code); SWIGV8_RETURN(SWIGV8_UNDEFINED()); -} - +} + SwigV8ReturnValue V8Shell::Version(const SwigV8Arguments &args) { SWIGV8_HANDLESCOPE(); SWIGV8_RETURN(SWIGV8_STRING_NEW(v8::V8::GetVersion())); -} - +} + void V8Shell::ReportException(v8::TryCatch *try_catch) { SWIGV8_HANDLESCOPE(); - v8::String::Utf8Value exception(try_catch->Exception()); + v8::String::Utf8Value exception(try_catch->Exception()); const char *exception_string = V8Shell::ToCString(exception); - v8::Handle message = try_catch->Message(); - if (message.IsEmpty()) { - // V8 didn't provide any extra information about this error; just - // print the exception. - printf("%s\n", exception_string); - } else { - // Print (filename):(line number): (message). - v8::String::Utf8Value filename(message->GetScriptResourceName()); + v8::Handle message = try_catch->Message(); + if (message.IsEmpty()) { + // V8 didn't provide any extra information about this error; just + // print the exception. + printf("%s\n", exception_string); + } else { + // Print (filename):(line number): (message). + v8::String::Utf8Value filename(message->GetScriptResourceName()); const char *filename_string = V8Shell::ToCString(filename); - int linenum = message->GetLineNumber(); - printf("%s:%i: %s\n", filename_string, linenum, exception_string); - // Print line of source code. - v8::String::Utf8Value sourceline(message->GetSourceLine()); + int linenum = message->GetLineNumber(); + printf("%s:%i: %s\n", filename_string, linenum, exception_string); + // Print line of source code. + v8::String::Utf8Value sourceline(message->GetSourceLine()); const char *sourceline_string = V8Shell::ToCString(sourceline); - printf("%s\n", sourceline_string); - // Print wavy underline (GetUnderline is deprecated). - int start = message->GetStartColumn(); - for (int i = 0; i < start; i++) { - printf(" "); - } - int end = message->GetEndColumn(); - for (int i = start; i < end; i++) { - printf("^"); - } - printf("\n"); - v8::String::Utf8Value stack_trace(try_catch->StackTrace()); - if (stack_trace.length() > 0) { + printf("%s\n", sourceline_string); + // Print wavy underline (GetUnderline is deprecated). + int start = message->GetStartColumn(); + for (int i = 0; i < start; i++) { + printf(" "); + } + int end = message->GetEndColumn(); + for (int i = start; i < end; i++) { + printf("^"); + } + printf("\n"); + v8::String::Utf8Value stack_trace(try_catch->StackTrace()); + if (stack_trace.length() > 0) { const char *stack_trace_string = V8Shell::ToCString(stack_trace); - printf("%s\n", stack_trace_string); - } - } -} - -// Extracts a C string from a V8 Utf8Value. + printf("%s\n", stack_trace_string); + } + } +} + +// Extracts a C string from a V8 Utf8Value. const char *V8Shell::ToCString(const v8::String::Utf8Value &value) { - return *value ? *value : ""; -} - + return *value ? *value : ""; +} + JSShell *V8Shell_Create() { - return new V8Shell(); -} + return new V8Shell(); +} -- cgit v1.2.1 From bf201f22b07c2ea6ad47a3c9d636a6e81fd39a2b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Pawe=C5=82=20Tomulik?= Date: Thu, 16 Oct 2014 16:16:33 +0200 Subject: correct example in enum class docs --- Doc/Manual/CPlusPlus11.html | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/Doc/Manual/CPlusPlus11.html b/Doc/Manual/CPlusPlus11.html index ce9174254..5bb6f2529 100644 --- a/Doc/Manual/CPlusPlus11.html +++ b/Doc/Manual/CPlusPlus11.html @@ -525,19 +525,19 @@ class Color {

    A workaround is to write these as a series of separate classes containing anonymous enums:

    -class PrintingColors {
    +struct PrintingColors {
       enum : unsigned int {
         Cyan, Magenta, Yellow, Black
       };
     };
     
    -class BasicColors {
    +struct BasicColors {
       enum : unsigned int {
         Red, Green, Blue
       };
     };
     
    -class AllColors {
    +struct AllColors {
       enum : unsigned int {
         Yellow, Orange, Red, Magenta, Blue, Cyan, Green, Pink, Black, White
       };
    -- 
    cgit v1.2.1
    
    
    From 2862a0a6bc2b025f970ec695c4f2295cca2d534a Mon Sep 17 00:00:00 2001
    From: William S Fulton 
    Date: Thu, 16 Oct 2014 07:48:05 +0100
    Subject: Syntax fix using %feature in documentation
    
    ---
     CHANGES                       | 4 ++--
     Doc/Manual/Customization.html | 4 ++--
     2 files changed, 4 insertions(+), 4 deletions(-)
    
    diff --git a/CHANGES b/CHANGES
    index 9fef3ae06..d205fcba4 100644
    --- a/CHANGES
    +++ b/CHANGES
    @@ -9456,7 +9456,7 @@ Version 1.3.23 (November 11, 2004)
                 wrapper method only and not the extra overloaded methods that SWIG generates.
                 For example:
     
    -              %feature("except") void hello(int i=0, double d=0.0);
    +              %feature("except") hello(int i=0, double d=0.0);
                   void hello(int i=0, double d=0.0);
     
                will apply the feature to all three wrapper methods, that is:
    @@ -9467,7 +9467,7 @@ Version 1.3.23 (November 11, 2004)
     
                If the default arguments are not specified in the feature:
     
    -              %feature("except") void hello(int i, double d);
    +              %feature("except") hello(int i, double d);
                   void hello(int i=0, double d=0.0);
     
                then the feature will only apply to this wrapper method:
    diff --git a/Doc/Manual/Customization.html b/Doc/Manual/Customization.html
    index 880b64c90..ca0cec130 100644
    --- a/Doc/Manual/Customization.html
    +++ b/Doc/Manual/Customization.html
    @@ -1082,7 +1082,7 @@ For example:
     
     
    -%feature("except") void hello(int i=0, double d=0.0) { ... }
    +%feature("except") hello(int i=0, double d=0.0) { ... }
     void hello(int i=0, double d=0.0);
     
    @@ -1105,7 +1105,7 @@ If the default arguments are not specified in the feature:
    -%feature("except") void hello(int i, double d) { ... }
    +%feature("except") hello(int i, double d) { ... }
     void hello(int i=0, double d=0.0);
     
    -- cgit v1.2.1 From b57a675d00a7e42bd145e62fd2e035400cc76873 Mon Sep 17 00:00:00 2001 From: William S Fulton Date: Mon, 20 Oct 2014 19:51:27 +0100 Subject: Cosmetic comment changes Note: copyrights are in the COPYRIGHT file --- Source/Modules/csharp.cxx | 4 ++++ Source/Modules/java.cxx | 5 +++++ Source/Modules/lang.cxx | 5 +++++ Source/Modules/ocaml.cxx | 3 --- Source/Modules/python.cxx | 3 +-- 5 files changed, 15 insertions(+), 5 deletions(-) diff --git a/Source/Modules/csharp.cxx b/Source/Modules/csharp.cxx index df4486d1d..57bcfe705 100644 --- a/Source/Modules/csharp.cxx +++ b/Source/Modules/csharp.cxx @@ -4285,6 +4285,10 @@ public: Delete(dirclassname); } + /*---------------------------------------------------------------------- + * nestedClassesSupport() + *--------------------------------------------------------------------*/ + NestedClassSupport nestedClassesSupport() const { return NCS_Full; } diff --git a/Source/Modules/java.cxx b/Source/Modules/java.cxx index 9e16bb422..8aa8666b7 100644 --- a/Source/Modules/java.cxx +++ b/Source/Modules/java.cxx @@ -4598,6 +4598,7 @@ public: /*---------------------------------------------------------------------- * extraDirectorProtectedCPPMethodsRequired() *--------------------------------------------------------------------*/ + bool extraDirectorProtectedCPPMethodsRequired() const { return false; } @@ -4623,6 +4624,10 @@ public: Setattr(n, "director:ctor", class_ctor); } + /*---------------------------------------------------------------------- + * nestedClassesSupport() + *--------------------------------------------------------------------*/ + NestedClassSupport nestedClassesSupport() const { return NCS_Full; } diff --git a/Source/Modules/lang.cxx b/Source/Modules/lang.cxx index 5ea79f0ab..9fa52cd2c 100644 --- a/Source/Modules/lang.cxx +++ b/Source/Modules/lang.cxx @@ -3517,9 +3517,14 @@ bool Language::extraDirectorProtectedCPPMethodsRequired() const { return true; } +/* ----------------------------------------------------------------------------- + * Language::nestedClassesSupport() + * ----------------------------------------------------------------------------- */ + Language::NestedClassSupport Language::nestedClassesSupport() const { return NCS_Unknown; } + /* ----------------------------------------------------------------------------- * Language::is_wrapping_class() * ----------------------------------------------------------------------------- */ diff --git a/Source/Modules/ocaml.cxx b/Source/Modules/ocaml.cxx index f1ec8a8cf..f3d63a6dc 100644 --- a/Source/Modules/ocaml.cxx +++ b/Source/Modules/ocaml.cxx @@ -1350,9 +1350,6 @@ public: /* * Modified polymorphism code for Ocaml language module. - * Original: - * C++/Python polymorphism demo code, copyright (C) 2002 Mark Rose - * * * TODO * diff --git a/Source/Modules/python.cxx b/Source/Modules/python.cxx index 2310b3472..c5e4b63f6 100644 --- a/Source/Modules/python.cxx +++ b/Source/Modules/python.cxx @@ -2600,7 +2600,6 @@ public: /* Insert cleanup code */ for (p = l; p;) { - // if (!checkAttribute(p,"tmap:in:numinputs","0") && !Getattr(p,"tmap:in:parse")) { if (!Getattr(p, "tmap:in:parse") && (tm = Getattr(p, "tmap:freearg"))) { if (Getattr(p, "tmap:freearg:implicitconv")) { const char *convflag = "0"; @@ -3208,7 +3207,7 @@ public: * BEGIN C++ Director Class modifications * ------------------------------------------------------------------------- */ - /* C++/Python polymorphism demo code, copyright (C) 2002 Mark Rose + /* C++/Python polymorphism demo code * * TODO * -- cgit v1.2.1 From bfde14888745fb3f8d83bd7e8d8f1b8df1826db8 Mon Sep 17 00:00:00 2001 From: William S Fulton Date: Tue, 21 Oct 2014 07:32:45 +0100 Subject: The kwargs feature no longer turns on compactdefaultargs for languages that don't support kwargs. Affects all languages except Python and Ruby. Closes #242 --- CHANGES.current | 7 +++++++ Doc/Manual/SWIGPlus.html | 6 ++++-- Examples/test-suite/common.mk | 1 + Examples/test-suite/java/kwargs_feature_runme.java | 23 ++++++++++++++++++++++ Examples/test-suite/kwargs_feature.i | 18 ++++------------- Examples/test-suite/python/Makefile.in | 1 - Examples/test-suite/python/kwargs_feature_runme.py | 4 ++-- Examples/test-suite/ruby/Makefile.in | 1 - Source/CParse/parser.y | 3 ++- Source/Modules/lang.cxx | 8 ++++++++ Source/Modules/main.cxx | 3 +++ Source/Modules/python.cxx | 7 +++++++ Source/Modules/ruby.cxx | 8 ++++++++ Source/Modules/swigmod.h | 3 +++ 14 files changed, 72 insertions(+), 21 deletions(-) create mode 100644 Examples/test-suite/java/kwargs_feature_runme.java diff --git a/CHANGES.current b/CHANGES.current index cc8406221..85f9a0110 100644 --- a/CHANGES.current +++ b/CHANGES.current @@ -5,6 +5,13 @@ See the RELEASENOTES file for a summary of changes in each release. Version 3.0.3 (in progress) =========================== +2014-10-21: wsfulton + Fix issue #242 - Use of the "kwargs" feature no longer automatically turns on the + "compactdefaultargs" feature if the target language does not support kwargs. + Only Java and Python support kwargs, so this affects all the other languages. + + *** POTENTIAL INCOMPATIBILITY *** + 2014-10-10: diorcety [Python] Patch #232 Fix property access using directors diff --git a/Doc/Manual/SWIGPlus.html b/Doc/Manual/SWIGPlus.html index 9589bf16c..6aaef07b4 100644 --- a/Doc/Manual/SWIGPlus.html +++ b/Doc/Manual/SWIGPlus.html @@ -1191,8 +1191,10 @@ values have to be public).

    -This feature is automatically turned on when wrapping C code with default arguments -and whenever keyword arguments (kwargs) are specified for either C or C++ code. +The compactdefaultargs feature is automatically turned on when wrapping C code with default arguments. +Some target languages will also automatically turn on this feature +if the keyword arguments feature (kwargs) is specified for either C or C++ functions, and the target language supports kwargs, +the compactdefaultargs feature is also automatically turned on. Keyword arguments are a language feature of some scripting languages, for example Ruby and Python. SWIG is unable to support kwargs when wrapping overloaded methods, so the default approach cannot be used.

    diff --git a/Examples/test-suite/common.mk b/Examples/test-suite/common.mk index c8a67283c..f985b55d1 100644 --- a/Examples/test-suite/common.mk +++ b/Examples/test-suite/common.mk @@ -249,6 +249,7 @@ CPP_TEST_CASES += \ insert_directive \ keyword_rename \ kind \ + kwargs_feature \ langobj \ li_attribute \ li_attribute_template \ diff --git a/Examples/test-suite/java/kwargs_feature_runme.java b/Examples/test-suite/java/kwargs_feature_runme.java new file mode 100644 index 000000000..ba742d9ec --- /dev/null +++ b/Examples/test-suite/java/kwargs_feature_runme.java @@ -0,0 +1,23 @@ +import kwargs_feature.*; + +public class kwargs_feature_runme { + + static { + try { + System.loadLibrary("kwargs_feature"); + } 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[]) { + // Check normal overloading still works (no compactdefaultargs) if the kwargs feature is used, + // as the kwargs feature is not supported + Foo f = new Foo(99); + if (f.foo() != 1) + throw new RuntimeException("It went wrong"); + if (Foo.statfoo(2) != 2) + throw new RuntimeException("It went wrong"); + } +} diff --git a/Examples/test-suite/kwargs_feature.i b/Examples/test-suite/kwargs_feature.i index 87153109a..a935b25f3 100644 --- a/Examples/test-suite/kwargs_feature.i +++ b/Examples/test-suite/kwargs_feature.i @@ -1,7 +1,7 @@ %module kwargs_feature %nocopyctor; -%kwargs; +%feature("kwargs"); %rename(myDel) del; %inline @@ -35,9 +35,7 @@ virtual ~Foo() { } - }; - %} @@ -64,8 +62,7 @@ // Functions %inline %{ - int foo(int a = 1, int b = 0) {return a + b; } - + int foo_fn(int a = 1, int b = 0) {return a + b; } template T templatedfunction(T a = 1, T b = 0) { return a + b; } %} @@ -73,10 +70,8 @@ %template(templatedfunction) templatedfunction; -// Deafult args with references -%inline -%{ - +// Default args with references +%inline %{ typedef int size_type; struct Hello @@ -84,13 +79,10 @@ static const size_type hello = 3; }; - - int rfoo( const size_type& x = Hello::hello, const Hello& y = Hello() ) { return x; } - %} %{ const int Hello::hello; @@ -104,9 +96,7 @@ int foo_kw(int from = 1, int except = 2) {return from + except; } - int foo_nu(int from = 1, int = 0) {return from; } int foo_mm(int min = 1, int max = 2) {return min + max; } - %} diff --git a/Examples/test-suite/python/Makefile.in b/Examples/test-suite/python/Makefile.in index c39a9c806..c79a786da 100644 --- a/Examples/test-suite/python/Makefile.in +++ b/Examples/test-suite/python/Makefile.in @@ -39,7 +39,6 @@ CPP_TEST_CASES += \ inout \ inplaceadd \ input \ - kwargs_feature \ li_cstring \ li_cwstring \ li_factory \ diff --git a/Examples/test-suite/python/kwargs_feature_runme.py b/Examples/test-suite/python/kwargs_feature_runme.py index 5539e211d..7792e2e06 100644 --- a/Examples/test-suite/python/kwargs_feature_runme.py +++ b/Examples/test-suite/python/kwargs_feature_runme.py @@ -44,10 +44,10 @@ if BarInt_sbar(b=2) != 3: if templatedfunction(b=2) != 3: raise RuntimeError -if foo(a=1,b=2) != 3: +if foo_fn(a=1,b=2) != 3: raise RuntimeError -if foo(b=2) != 3: +if foo_fn(b=2) != 3: raise RuntimeError diff --git a/Examples/test-suite/ruby/Makefile.in b/Examples/test-suite/ruby/Makefile.in index 1a6875360..ae4995882 100644 --- a/Examples/test-suite/ruby/Makefile.in +++ b/Examples/test-suite/ruby/Makefile.in @@ -11,7 +11,6 @@ top_srcdir = @top_srcdir@ top_builddir = @top_builddir@ CPP_TEST_CASES = \ - kwargs_feature \ li_cdata \ li_cstring \ li_factory \ diff --git a/Source/CParse/parser.y b/Source/CParse/parser.y index b334ace76..61b0462b5 100644 --- a/Source/CParse/parser.y +++ b/Source/CParse/parser.y @@ -59,6 +59,7 @@ static int compact_default_args = 0; static int template_reduce = 0; static int cparse_externc = 0; int ignore_nested_classes = 0; +int kwargs_supported = 0; /* ----------------------------------------------------------------------------- * Assist Functions * ----------------------------------------------------------------------------- */ @@ -1177,7 +1178,7 @@ static void default_arguments(Node *n) { if (compact_default_args || is_cfunction(function) || GetFlag(function,"feature:compactdefaultargs") - || GetFlag(function,"feature:kwargs")) { + || (GetFlag(function,"feature:kwargs") && kwargs_supported)) { ParmList *p = Getattr(function,"parms"); if (p) Setattr(p,"compactdefargs", "1"); /* mark parameters for special handling */ diff --git a/Source/Modules/lang.cxx b/Source/Modules/lang.cxx index 9fa52cd2c..5b1547487 100644 --- a/Source/Modules/lang.cxx +++ b/Source/Modules/lang.cxx @@ -3525,6 +3525,14 @@ Language::NestedClassSupport Language::nestedClassesSupport() const { return NCS_Unknown; } +/* ----------------------------------------------------------------------------- + * Language::kwargsSupport() + * ----------------------------------------------------------------------------- */ + +bool Language::kwargsSupport() const { + return false; +} + /* ----------------------------------------------------------------------------- * Language::is_wrapping_class() * ----------------------------------------------------------------------------- */ diff --git a/Source/Modules/main.cxx b/Source/Modules/main.cxx index 47d0d374b..f41844d34 100644 --- a/Source/Modules/main.cxx +++ b/Source/Modules/main.cxx @@ -50,6 +50,7 @@ int SwigRuntime = 0; // 0 = no option, 1 = -runtime, 2 = -noruntime extern "C" { extern String *ModuleName; extern int ignore_nested_classes; + extern int kwargs_supported; } /* usage string split into multiple parts otherwise string is too big for some compilers */ @@ -904,6 +905,8 @@ int SWIG_main(int argc, char *argv[], Language *l) { // Inform the parser if the nested classes should be ignored unless explicitly told otherwise via feature:flatnested ignore_nested_classes = l->nestedClassesSupport() == Language::NCS_Unknown ? 1 : 0; + kwargs_supported = l->kwargsSupport() ? 1 : 0; + // Create Library search directories // Check for SWIG_LIB environment variable diff --git a/Source/Modules/python.cxx b/Source/Modules/python.cxx index c5e4b63f6..b14f0903d 100644 --- a/Source/Modules/python.cxx +++ b/Source/Modules/python.cxx @@ -4785,6 +4785,13 @@ public: return NewString("swigpyrun.h"); } + /*---------------------------------------------------------------------- + * kwargsSupport() + *--------------------------------------------------------------------*/ + + bool kwargsSupport() const { + return true; + } }; /* --------------------------------------------------------------- diff --git a/Source/Modules/ruby.cxx b/Source/Modules/ruby.cxx index 6aeaae5a1..310e89b82 100644 --- a/Source/Modules/ruby.cxx +++ b/Source/Modules/ruby.cxx @@ -3426,6 +3426,14 @@ public: String *defaultExternalRuntimeFilename() { return NewString("swigrubyrun.h"); } + + /*---------------------------------------------------------------------- + * kwargsSupport() + *--------------------------------------------------------------------*/ + + bool kwargsSupport() const { + return true; + } }; /* class RUBY */ /* ----------------------------------------------------------------------------- diff --git a/Source/Modules/swigmod.h b/Source/Modules/swigmod.h index 63b91bae5..33fecbcc7 100644 --- a/Source/Modules/swigmod.h +++ b/Source/Modules/swigmod.h @@ -315,6 +315,9 @@ public: */ virtual NestedClassSupport nestedClassesSupport() const; + /* Returns true if the target language supports key word arguments (kwargs) */ + virtual bool kwargsSupport() const; + protected: /* Identifies if a protected members that are generated when the allprotected option is used. This does not include protected virtual methods as they are turned on with the dirprot option. */ -- cgit v1.2.1 From 3dcc501ac0eb65c0d2e2340e63abc2e346fa0759 Mon Sep 17 00:00:00 2001 From: William S Fulton Date: Tue, 21 Oct 2014 07:55:07 +0100 Subject: Spelling fix --- CHANGES | 24 ++++++++++++------------ Doc/Manual/SWIG.html | 2 +- Doc/Manual/SWIGPlus.html | 2 +- Examples/test-suite/allowexcept.i | 2 +- Examples/test-suite/enum_rename.i | 2 +- Examples/test-suite/exception_partial_info.i | 2 +- Examples/test-suite/extend_default.i | 2 +- Lib/typemaps/attribute.swg | 2 +- Source/Modules/lang.cxx | 2 +- 9 files changed, 20 insertions(+), 20 deletions(-) diff --git a/CHANGES b/CHANGES index d205fcba4..b7b9856e2 100644 --- a/CHANGES +++ b/CHANGES @@ -1622,7 +1622,7 @@ Version 2.0.5 (19 April 2012) -tmsearch and -tmused. 2011-08-26: wsfulton - [C#, D] Fix %callback which was generating uncompileable code. + [C#, D] Fix %callback which was generating uncompilable code. 2011-08-25: wsfulton Fix constructors in named typedef class declarations as reported by Gregory Bronner: @@ -1861,7 +1861,7 @@ Version 2.0.4 (21 May 2011) PySlice_GetIndices, which changed signatures in python3.2. 2011-04-07: wsfulton - Fix wrapping of const array typedefs which were generating uncompileable code as + Fix wrapping of const array typedefs which were generating uncompilable code as reported by Karl Wette. 2011-04-03: szager @@ -2299,7 +2299,7 @@ Version 2.0.1 (4 October 2010) in this case). 2010-06-03: wsfulton - Fix uncompileable code when %rename results in two enum items + Fix uncompilable code when %rename results in two enum items with the same name. Reported by Vadim Zeitlin. Version 2.0.0 (2 June 2010) @@ -2812,7 +2812,7 @@ Version 2.0.0 (2 June 2010) Fix #2310483 - function pointer typedef within extern "C" block. 2009-11-13: wsfulton - Fix usage of nested template classes within templated classes so that compileable code + Fix usage of nested template classes within templated classes so that compilable code is generated. 2009-11-13: olly @@ -2820,7 +2820,7 @@ Version 2.0.0 (2 June 2010) wasn't being used. Patch from gverbruggen in SF#2892647. 2009-11-12: wsfulton - Fix usage of nested template classes so that compileable code is generated - the nested + Fix usage of nested template classes so that compilable code is generated - the nested template class is now treated like a normal nested classes, that is, as an opaque type unless the nestedworkaround feature is used. @@ -2846,7 +2846,7 @@ Version 2.0.0 (2 June 2010) 2009-11-11: wsfulton There were a number of C++ cases where nested classes/structs/unions were being handled - as if C code was being parsed which would oftentimes lead to uncompileable code as an + as if C code was being parsed which would oftentimes lead to uncompilable code as an attempt was made to wrap the nested structs like it is documented for C code. Now all nested structs/classes/unions are ignored in C++ mode, as was always documented. However, there is an improvement as usage of nested structs/classes/unions is now always treated @@ -2858,7 +2858,7 @@ Version 2.0.0 (2 June 2010) Fix R for -fcompact and add std_map.i 2009-11-08: wsfulton - Fix inconsistency for nested structs/unions/classes. Uncompileable code was being + Fix inconsistency for nested structs/unions/classes. Uncompilable code was being generated when inner struct and union declarations were used as types within the inner struct. The inner struct/union is now treated as a forward declaration making the behaviour the same as an inner class. (C++ code), eg: @@ -2872,7 +2872,7 @@ Version 2.0.0 (2 June 2010) Ignored nested class/struct warnings now display the name of the ignored class/struct. 2009-11-07: wsfulton - Bug #1514681 - Fix nested template classes within a namespace generated uncompileable + Bug #1514681 - Fix nested template classes within a namespace generated uncompilable code and introduced strange side effects to other wrapper code especially code after the nested template class. Note that nested template classes are still ignored. @@ -3727,7 +3727,7 @@ Version 1.3.36 (24 June 2008) 06/19/2008: wsfulton [Java, C#] C# and Java keywords will be renamed instead of just issuing a warning - and then generating uncompileable code. Warning 314 gives the new name when a + and then generating uncompilable code. Warning 314 gives the new name when a keyword is found. 06/19/2008: wsfulton @@ -4170,7 +4170,7 @@ Version 1.3.34 (27 February 2008) 11/30/2007: wsfulton Fix using statements using a base class method where the methods were overloaded. Depending on the order of the using statements and method declarations, these - were previously generating uncompileable wrappers, eg: + were previously generating uncompilable wrappers, eg: struct Derived : Base { virtual void funk(); @@ -5258,7 +5258,7 @@ Version 1.3.30 (November 13, 2006) 10/03/2006: wsfulton [Ruby] Fix #1527885 - Overloaded director virtual methods sometimes produced - uncompileable code when used with the director:except feature. + uncompilable code when used with the director:except feature. 10/03/2006: wsfulton Directors: Directors are output in the order in which they are declared in @@ -10842,7 +10842,7 @@ Version 1.3.22 (September 4, 2004) ... } - Previously, none of BIG, LARGE or BAR would have produced compileable code + Previously, none of BIG, LARGE or BAR would have produced compilable code when using %javaconst(1). 06/27/2004: wsfulton diff --git a/Doc/Manual/SWIG.html b/Doc/Manual/SWIG.html index bd929f7d4..e7178a621 100644 --- a/Doc/Manual/SWIG.html +++ b/Doc/Manual/SWIG.html @@ -3316,7 +3316,7 @@ Most importantly, define a type before it is used! A C compiler will tell you if the full type information is not available if it is needed, whereas SWIG will usually not warn or error out as it is designed to work without full type information. However, if type information is not specified -correctly, the wrappers can be sub-optimal and even result in uncompileable C/C++ code. +correctly, the wrappers can be sub-optimal and even result in uncompilable C/C++ code.
  • If your program has a main() function, you may need to rename it (read on). diff --git a/Doc/Manual/SWIGPlus.html b/Doc/Manual/SWIGPlus.html index 6aaef07b4..72917f1e0 100644 --- a/Doc/Manual/SWIGPlus.html +++ b/Doc/Manual/SWIGPlus.html @@ -1184,7 +1184,7 @@ public:
  • -This produces uncompileable wrapper code because default values in C++ are +This produces uncompilable wrapper code because default values in C++ are evaluated in the same scope as the member function whereas SWIG evaluates them in the scope of a wrapper function (meaning that the values have to be public). diff --git a/Examples/test-suite/allowexcept.i b/Examples/test-suite/allowexcept.i index 37b01cd75..c901295df 100644 --- a/Examples/test-suite/allowexcept.i +++ b/Examples/test-suite/allowexcept.i @@ -21,7 +21,7 @@ UVW Bar::static_member_variable; %} -// Now test the allowexcept feature by making the usual $action uncompileable and ensuring the %exception is picked up +// Now test the allowexcept feature by making the usual $action uncompilable and ensuring the %exception is picked up struct XYZ { }; diff --git a/Examples/test-suite/enum_rename.i b/Examples/test-suite/enum_rename.i index 0cab4d0d8..23e100db9 100644 --- a/Examples/test-suite/enum_rename.i +++ b/Examples/test-suite/enum_rename.i @@ -2,7 +2,7 @@ %warnfilter(SWIGWARN_PARSE_REDEFINED) S_May; -// %rename using regex can do the equivalent of these two renames, which was resulting in uncompileable code +// %rename using regex can do the equivalent of these two renames, which was resulting in uncompilable code %rename(May) M_May; %rename(May) S_May; diff --git a/Examples/test-suite/exception_partial_info.i b/Examples/test-suite/exception_partial_info.i index 37b87ef50..47b046735 100644 --- a/Examples/test-suite/exception_partial_info.i +++ b/Examples/test-suite/exception_partial_info.i @@ -1,6 +1,6 @@ %module exception_partial_info -// This produced compileable code for Tcl, Python in 1.3.27, fails in 1.3.29 +// This produced compilable code for Tcl, Python in 1.3.27, fails in 1.3.29 %{ #if defined(_MSC_VER) diff --git a/Examples/test-suite/extend_default.i b/Examples/test-suite/extend_default.i index 097b5332e..d4a015f55 100644 --- a/Examples/test-suite/extend_default.i +++ b/Examples/test-suite/extend_default.i @@ -93,7 +93,7 @@ struct OverAfter { // %extend overrides the class definition %extend Override { int over(int a) { return a*a; } // SWIG should give a warning then choose this one over the real one - int overload(int a) { return a*a; } // Similarly, but this one generated uncompileable code in SWIG-1.3.22 + int overload(int a) { return a*a; } // Similarly, but this one generated uncompilable code in SWIG-1.3.22 } %inline %{ struct Override { diff --git a/Lib/typemaps/attribute.swg b/Lib/typemaps/attribute.swg index f06c8c0f3..988113991 100644 --- a/Lib/typemaps/attribute.swg +++ b/Lib/typemaps/attribute.swg @@ -137,7 +137,7 @@ // // Define SWIG_ATTRIBUTE_TEMPLATE if you want to use templates instead of macros for the C++ get and set wrapper methods -// Does not always generate compileable code, use at your peril! +// Does not always generate compilable code, use at your peril! // //#define SWIG_ATTRIBUTE_TEMPLATE diff --git a/Source/Modules/lang.cxx b/Source/Modules/lang.cxx index 5b1547487..4d9a94547 100644 --- a/Source/Modules/lang.cxx +++ b/Source/Modules/lang.cxx @@ -2043,7 +2043,7 @@ int Language::classDirectorConstructors(Node *n) { needed, since there is a public constructor already defined. (scottm) This code is needed here to make the director_abstract + - test generate compileable code (Example2 in director_abastract.i). + test generate compilable code (Example2 in director_abastract.i). (mmatus) This is very strange, since swig compiled with gcc3.2.3 doesn't need it here.... -- cgit v1.2.1 From f84e1f823b029d2507d6a9a57c729bb824aa952e Mon Sep 17 00:00:00 2001 From: William S Fulton Date: Tue, 21 Oct 2014 08:02:25 +0100 Subject: Minor C++11 doc change --- Doc/Manual/CPlusPlus11.html | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/Doc/Manual/CPlusPlus11.html b/Doc/Manual/CPlusPlus11.html index 5bb6f2529..04c40a6d6 100644 --- a/Doc/Manual/CPlusPlus11.html +++ b/Doc/Manual/CPlusPlus11.html @@ -506,7 +506,7 @@ This is usually not a problem, however, there may be some name clashes. For example, the following code:

    -class Color {
    +struct Color {
       enum class PrintingColors : unsigned int {
         Cyan, Magenta, Yellow, Black
       };
    @@ -611,6 +611,7 @@ The following is an example of an alias template:
     
     template< typename T1, typename T2, int >
     class SomeType {
    +public:
       T1 a;
       T2 b;
       int c;
    -- 
    cgit v1.2.1
    
    
    From 18a9c095f82a6046ab2b4a4e1ce4af13150ca1d6 Mon Sep 17 00:00:00 2001
    From: Karl Wette 
    Date: Sun, 5 Oct 2014 14:31:24 +0200
    Subject: Octave: disable optimization of tests for faster compiles/less memory
     usage
    
    - Filter out all but -g... and -W... flags from OCTAVE_CXXFLAGS
    - Use AX_CHECK_COMPILE_FLAG() to check if -O0 is supported, if so
      add to end of OCTAVE_CXXFLAGS to ensure optimization is disabled
    - Also run mkoctfile under "env -" to protect it from environment
    - Also use more standard-compliant sed expressions
    ---
     configure.ac | 32 +++++++++++++++++++++++++-------
     1 file changed, 25 insertions(+), 7 deletions(-)
    
    diff --git a/configure.ac b/configure.ac
    index 78c276029..22d66d1ef 100644
    --- a/configure.ac
    +++ b/configure.ac
    @@ -937,25 +937,43 @@ fi
     if test -n "$OCTAVE"; then
        AC_MSG_CHECKING([for Octave preprocessor flags])
        OCTAVE_CPPFLAGS=
    -   for n in CPPFLAGS INCFLAGS; do
    -     OCTAVE_CPPFLAGS="${OCTAVE_CPPFLAGS} "`unset CPPFLAGS; ${mkoctfile} -p $n`
    +   for var in CPPFLAGS INCFLAGS ALL_CXXFLAGS; do
    +      for flag in `env - ${mkoctfile} -p ${var}`; do
    +         case ${flag} in
    +            -D*|-I*) OCTAVE_CPPFLAGS="${OCTAVE_CPPFLAGS} ${flag}";;
    +            *) ;;
    +         esac
    +      done
        done
        AC_MSG_RESULT([$OCTAVE_CPPFLAGS])
        AC_MSG_CHECKING([for Octave compiler flags])
        OCTAVE_CXXFLAGS=
    -   for n in ALL_CXXFLAGS; do
    -     OCTAVE_CXXFLAGS="${OCTAVE_CXXFLAGS} "`unset CXXFLAGS; ${mkoctfile} -p $n`
    +   for var in ALL_CXXFLAGS; do
    +      for flag in `env - ${mkoctfile} -p ${var}`; do
    +         case ${flag} in
    +            -g*|-W*) OCTAVE_CXXFLAGS="${OCTAVE_CXXFLAGS} ${flag}";;
    +            *) ;;
    +         esac
    +      done
        done
    +   save_CXXFLAGS="${CXXFLAGS}"
    +   CXXFLAGS="-Werror -O0"
    +   AC_COMPILE_IFELSE([
    +      AC_LANG_PROGRAM([AC_INCLUDES_DEFAULT],[])
    +   ],[
    +      OCTAVE_CXXFLAGS="${OCTAVE_CXXFLAGS} -O0"
    +   ])
    +   CXXFLAGS="${save_CXXFLAGS}"
        AC_MSG_RESULT([$OCTAVE_CXXFLAGS])
        AC_MSG_CHECKING([for Octave linker flags])
        OCTAVE_LDFLAGS=
    -   for n in RDYNAMIC_FLAG LFLAGS RLD_FLAG OCTAVE_LIBS LIBS; do
    -     OCTAVE_LDFLAGS="${OCTAVE_LDFLAGS} "`${mkoctfile} -p $n`
    +   for var in RDYNAMIC_FLAG LFLAGS RLD_FLAG OCTAVE_LIBS LIBS; do
    +     OCTAVE_LDFLAGS="${OCTAVE_LDFLAGS} "`env - ${mkoctfile} -p ${var}`
        done
        AC_MSG_RESULT([$OCTAVE_LDFLAGS])
        for octave_opt in --silent --norc --no-history --no-window-system; do
           AC_MSG_CHECKING([if Octave option '${octave_opt}' is supported])
    -      octave_out=`${OCTAVE} ${octave_opt} /dev/null 2>&1 | sed -n '1{/unrecognized/p}'`
    +      octave_out=`${OCTAVE} ${octave_opt} /dev/null 2>&1 | sed -n '1p' | sed -n '/unrecognized/p'`
           AS_IF([test "x${octave_out}" = x],[
              AC_MSG_RESULT([yes])
              OCTAVE="${OCTAVE} ${octave_opt}"
    -- 
    cgit v1.2.1
    
    
    From e8762313cd84a93fe42974b7f4c86dabd9ff0fdf Mon Sep 17 00:00:00 2001
    From: Karl Wette 
    Date: Sun, 5 Oct 2014 14:34:46 +0200
    Subject: .travis.yml: reduce Octave make jobs to 3
    
    - Allow for more memory per job to prevent gcc failures
    - Disabling optimization should give enough speedup to compensate
    ---
     .travis.yml | 2 +-
     1 file changed, 1 insertion(+), 1 deletion(-)
    
    diff --git a/.travis.yml b/.travis.yml
    index ce15e294b..0ab710248 100644
    --- a/.travis.yml
    +++ b/.travis.yml
    @@ -23,7 +23,7 @@ matrix:
         - compiler: gcc
           env: SWIGLANG=lua
         - compiler: gcc
    -      env: SWIGLANG=octave SWIGJOBS=-j4
    +      env: SWIGLANG=octave SWIGJOBS=-j3
         - compiler: gcc
           env: SWIGLANG=perl5
         - compiler: gcc
    -- 
    cgit v1.2.1
    
    
    From 12e9589ec0f2ac27f93ac907aeb5e726102108d4 Mon Sep 17 00:00:00 2001
    From: Karl Wette 
    Date: Sun, 5 Oct 2014 14:35:12 +0200
    Subject: Revert "Suppress Octave failing the build"
    
    - This reverts commit fea2fc137e2a1db8601e6af922838a71cc47596e.
    - Failures were probably due to gcc running out of memory
    - Disabling optimization of Octave tests should both increase
      compile times and reduce memory usage, and reducing number
      of make jobs to 3 should also allow for more memory per job
    ---
     .travis.yml | 4 +---
     1 file changed, 1 insertion(+), 3 deletions(-)
    
    diff --git a/.travis.yml b/.travis.yml
    index 0ab710248..5a9391e42 100644
    --- a/.travis.yml
    +++ b/.travis.yml
    @@ -51,9 +51,7 @@ matrix:
         - compiler: gcc
           env: SWIGLANG=tcl
       allow_failures:
    -    # g++-4.6.3 internal compiler error for li_std_vector testcase
    -    - compiler: gcc
    -      env: SWIGLANG=octave SWIGJOBS=-j4
    +    # None
     before_install:
       - date -u
       - uname -a
    -- 
    cgit v1.2.1
    
    
    From d8e2815e258e6760ad9c69090758e6caa8672c3d Mon Sep 17 00:00:00 2001
    From: Karl Wette 
    Date: Fri, 17 Oct 2014 01:15:01 +0200
    Subject: .travis.yml: also test against Octave version 3.8
    
    ---
     .travis.yml | 7 +++++--
     1 file changed, 5 insertions(+), 2 deletions(-)
    
    diff --git a/.travis.yml b/.travis.yml
    index 5a9391e42..1c1614979 100644
    --- a/.travis.yml
    +++ b/.travis.yml
    @@ -23,7 +23,9 @@ matrix:
         - compiler: gcc
           env: SWIGLANG=lua
         - compiler: gcc
    -      env: SWIGLANG=octave SWIGJOBS=-j3
    +      env: SWIGLANG=octave SWIGJOBS=-j3 # 3.2
    +    - compiler: gcc
    +      env: SWIGLANG=octave SWIGJOBS=-j3 VER=3.8
         - compiler: gcc
           env: SWIGLANG=perl5
         - compiler: gcc
    @@ -66,7 +68,8 @@ before_install:
       - if test "$SWIGLANG" = "javascript" -a "$ENGINE" = "v8"; then sudo apt-get install -qq libv8-dev; fi
       - if test "$SWIGLANG" = "guile"; then sudo apt-get -qq install guile-2.0-dev; fi
       - if test "$SWIGLANG" = "lua"; then sudo apt-get -qq install lua5.1 liblua5.1-dev; fi
    -  - if test "$SWIGLANG" = "octave"; then sudo apt-get -qq install octave3.2 octave3.2-headers; fi
    +  - if test "$SWIGLANG" = "octave" -a -z "$VER"; then sudo apt-get -qq install octave3.2 octave3.2-headers; fi
    +  - if test "$SWIGLANG" = "octave" -a "$VER"; then sudo add-apt-repository -y ppa:kwwette/octaves && sudo apt-get -qq update && sudo apt-get -qq install liboctave${VER}-dev; fi
       - if test "$SWIGLANG" = "php"; then sudo apt-get install php5-cli php5-dev; fi
       - if test "$SWIGLANG" = "python"; then git clone https://github.com/jcrocholl/pep8.git && pushd pep8 && git checkout tags/1.5.7 && python ./setup.py build && sudo python ./setup.py install && popd; fi
       - if test "$SWIGLANG" = "python" -a "$PY3" -a -z "$VER"; then sudo apt-get install -qq python3-dev; fi
    -- 
    cgit v1.2.1
    
    
    From 7d1f3a6ea1ead398bd10dc50456e91c1fb62a20c Mon Sep 17 00:00:00 2001
    From: Karl Wette 
    Date: Wed, 22 Oct 2014 12:18:16 +0200
    Subject: Doc/Manual/Octave.html: update which Octave versions have been tested
     against
    
    ---
     Doc/Manual/Octave.html | 4 ++--
     1 file changed, 2 insertions(+), 2 deletions(-)
    
    diff --git a/Doc/Manual/Octave.html b/Doc/Manual/Octave.html
    index 9c3489fb8..46a8941c2 100644
    --- a/Doc/Manual/Octave.html
    +++ b/Doc/Manual/Octave.html
    @@ -59,8 +59,8 @@ Also, there are a dozen or so examples in the Examples/octave directory, and hun
     
     
     

    -As of SWIG 3.0.0, the Octave module has been tested with Octave versions 3.0.5, 3.2.4, 3.4.3, 3.6.4, and 3.8.0. -Use of Octave versions older than 3.x.x is not recommended, as these versions are no longer tested with SWIG. +As of SWIG 3.0.3, the Octave module has been tested with Octave versions 3.2.4, 3.4.3, 3.6.4, and 3.8.1. +Use of older Octave versions is not recommended, as these versions are no longer tested with SWIG.

    32.2 Running SWIG

    -- cgit v1.2.1 From d03c260738bdd27b515f363ac2ec6b89d0b2f20c Mon Sep 17 00:00:00 2001 From: William S Fulton Date: Sat, 25 Oct 2014 15:46:43 +0100 Subject: D test-suite fixes Fixes 'make partialcheck-d-test-suite' and probably normal D test-suite usage (unable to test) --- Examples/test-suite/d/Makefile.in | 9 ++++----- 1 file changed, 4 insertions(+), 5 deletions(-) diff --git a/Examples/test-suite/d/Makefile.in b/Examples/test-suite/d/Makefile.in index 37a944b09..418381e7f 100644 --- a/Examples/test-suite/d/Makefile.in +++ b/Examples/test-suite/d/Makefile.in @@ -5,8 +5,8 @@ LANGUAGE = d srcdir = @srcdir@ -top_srcdir = @top_srcdir@ -top_builddir = @top_builddir@ +top_srcdir = ../@top_srcdir@ +top_builddir = ../@top_builddir@ ifeq (2,$(D_VERSION)) VERSIONSUFFIX = .2 @@ -22,10 +22,9 @@ CPP_TEST_CASES = \ include $(srcdir)/../common.mk -# Override some variables from common.mk: - +# Overridden variables here +SRCDIR = ../$(srcdir)/ TARGETSUFFIX = _wrap - SWIGOPT+=-splitproxy -package $* # Rules for the different types of tests -- cgit v1.2.1 From 5d71f91b291fc1f476f8ea29120cb8413d30c87e Mon Sep 17 00:00:00 2001 From: William S Fulton Date: Mon, 27 Oct 2014 20:03:31 +0000 Subject: Fix autodoc testcase for new named python arguments when using python -builtin For the changes in #201. --- Examples/test-suite/python/autodoc_runme.py | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/Examples/test-suite/python/autodoc_runme.py b/Examples/test-suite/python/autodoc_runme.py index 24a1c2834..f32b94adc 100644 --- a/Examples/test-suite/python/autodoc_runme.py +++ b/Examples/test-suite/python/autodoc_runme.py @@ -163,7 +163,7 @@ check(A.func0static.__doc__, , "\n" "func0static(e, arg2, hello, f=2) -> int\n" -"func0static(e, arg3, hello) -> int\n" +"func0static(e, arg2, hello) -> int\n" "" ) check(A.func1static.__doc__, @@ -174,7 +174,7 @@ check(A.func1static.__doc__, , "\n" "func1static(A e, short arg2, Tuple hello, double f=2) -> int\n" -"func1static(A e, short arg3, Tuple hello) -> int\n" +"func1static(A e, short arg2, Tuple hello) -> int\n" "" ) check(A.func2static.__doc__, @@ -205,11 +205,11 @@ check(A.func2static.__doc__, " hello: int tuple[2]\n" " f: double\n" "\n" -"func2static(e, arg3, hello) -> int\n" +"func2static(e, arg2, hello) -> int\n" "\n" "Parameters:\n" " e: A *\n" -" arg3: short\n" +" arg2: short\n" " hello: int tuple[2]\n" "\n" "" @@ -242,11 +242,11 @@ check(A.func3static.__doc__, " hello: int tuple[2]\n" " f: double\n" "\n" -"func3static(A e, short arg3, Tuple hello) -> int\n" +"func3static(A e, short arg2, Tuple hello) -> int\n" "\n" "Parameters:\n" " e: A *\n" -" arg3: short\n" +" arg2: short\n" " hello: int tuple[2]\n" "\n" "" @@ -287,7 +287,7 @@ check(B.__doc__, "Proxy of C++ B class", "::B" ) -check(C.__init__.__doc__, "__init__(self, a, b, h) -> C", None, skip) +check(C.__init__.__doc__, "__init__(self, a, b, h) -> C") check(D.__init__.__doc__, "__init__(D self, int a, int b, Hola h) -> D", None, skip) check(E.__init__.__doc__, "\n" -- cgit v1.2.1 From cd725fbe948f39cebb0ce979997cc6bf5ffd2331 Mon Sep 17 00:00:00 2001 From: William S Fulton Date: Tue, 28 Oct 2014 06:33:12 +0000 Subject: Minor cosmetic source code changes --- Source/Modules/lang.cxx | 1 + Source/Modules/python.cxx | 4 ++-- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/Source/Modules/lang.cxx b/Source/Modules/lang.cxx index 908aa0b52..4fc1471b0 100644 --- a/Source/Modules/lang.cxx +++ b/Source/Modules/lang.cxx @@ -3530,6 +3530,7 @@ String *Language::makeParameterName(Node *n, Parm *p, int arg_num, bool setter) // Some languages (C#) insist on calling the input variable "value" while // others (D, Java) could, in principle, use something different but this // would require more work, and so we just use "value" for them too. + // For setters the parameter name sometimes includes C++ scope resolution which needs removing. Delete(arg); arg = NewString("value"); } diff --git a/Source/Modules/python.cxx b/Source/Modules/python.cxx index c4b36ed06..e2c3180ff 100644 --- a/Source/Modules/python.cxx +++ b/Source/Modules/python.cxx @@ -1533,7 +1533,7 @@ public: // so we only minimally rename them in Swig_name_make(), e.g. replacing "keyword" // with "_keyword" if they have any name at all. if (check_kwargs(n)) { - String* name = Getattr(p, "name"); + String *name = Getattr(p, "name"); if (name) return Swig_name_make(p, 0, name, 0, 0); } @@ -1554,7 +1554,7 @@ public: * The "lname" attribute in each parameter in plist will be contain a parameter name * ----------------------------------------------------------------------------- */ - void addMissingParameterNames(Node* n, ParmList *plist, int arg_offset) { + void addMissingParameterNames(Node *n, ParmList *plist, int arg_offset) { Parm *p = plist; int i = arg_offset; while (p) { -- cgit v1.2.1 From a6efdb7999298de6be8c5b4f1fca4ff60ac1fb20 Mon Sep 17 00:00:00 2001 From: William S Fulton Date: Tue, 28 Oct 2014 06:59:30 +0000 Subject: Fix when is 'self' used as a parameter name in Python Fix corner case for variable names called 'self' after merging in patch #201 --- Examples/test-suite/keyword_rename.i | 4 ++++ Examples/test-suite/python/keyword_rename_runme.py | 4 +++- Lib/python/pythonkw.swg | 2 +- 3 files changed, 8 insertions(+), 2 deletions(-) diff --git a/Examples/test-suite/keyword_rename.i b/Examples/test-suite/keyword_rename.i index 46c3338b3..3a878ae80 100644 --- a/Examples/test-suite/keyword_rename.i +++ b/Examples/test-suite/keyword_rename.i @@ -35,6 +35,10 @@ KW(chan, fallthrough) KW(end, function) KW(nil,local) +struct Keywords { + void selfkw(int self) {} +}; + %} diff --git a/Examples/test-suite/python/keyword_rename_runme.py b/Examples/test-suite/python/keyword_rename_runme.py index 5646ce7d6..f6796db52 100644 --- a/Examples/test-suite/python/keyword_rename_runme.py +++ b/Examples/test-suite/python/keyword_rename_runme.py @@ -1,4 +1,6 @@ -#!/usr/bin/env python import keyword_rename keyword_rename._in(1) keyword_rename._except(1) + +k = keyword_rename.Keywords() +k.selfkw(123) diff --git a/Lib/python/pythonkw.swg b/Lib/python/pythonkw.swg index 8ad0ef11b..2f76a664a 100644 --- a/Lib/python/pythonkw.swg +++ b/Lib/python/pythonkw.swg @@ -130,7 +130,7 @@ PYTHONKW(None); /* 'self' is also a bad Name */ -PYTHONBN(self); +PYTHONKW(self); #undef PYTHONBN #undef PYTHONKW -- cgit v1.2.1 From 6d93d57ab03f4c13dca65921cadc6f1e6d244cff Mon Sep 17 00:00:00 2001 From: Vadim Zeitlin Date: Wed, 29 Oct 2014 00:55:49 +0100 Subject: Don't use C++ features when building test code as C. This fixes the build after a6efdb7 which added a method to a test used in both C++ and C test cases. --- Examples/test-suite/keyword_rename.i | 2 ++ 1 file changed, 2 insertions(+) diff --git a/Examples/test-suite/keyword_rename.i b/Examples/test-suite/keyword_rename.i index 3a878ae80..1703285f0 100644 --- a/Examples/test-suite/keyword_rename.i +++ b/Examples/test-suite/keyword_rename.i @@ -35,9 +35,11 @@ KW(chan, fallthrough) KW(end, function) KW(nil,local) +#ifdef __cplusplus struct Keywords { void selfkw(int self) {} }; +#endif /* __cplusplus */ %} -- cgit v1.2.1 From 3eb626fda6ab999109c641aed95de5e12cec17ba Mon Sep 17 00:00:00 2001 From: William S Fulton Date: Wed, 29 Oct 2014 09:42:04 +0000 Subject: Revert "Don't use C++ features when building test code as C." This reverts commit 6d93d57ab03f4c13dca65921cadc6f1e6d244cff. --- Examples/test-suite/keyword_rename.i | 2 -- 1 file changed, 2 deletions(-) diff --git a/Examples/test-suite/keyword_rename.i b/Examples/test-suite/keyword_rename.i index 1703285f0..3a878ae80 100644 --- a/Examples/test-suite/keyword_rename.i +++ b/Examples/test-suite/keyword_rename.i @@ -35,11 +35,9 @@ KW(chan, fallthrough) KW(end, function) KW(nil,local) -#ifdef __cplusplus struct Keywords { void selfkw(int self) {} }; -#endif /* __cplusplus */ %} -- cgit v1.2.1 From 7d4af72dde1d9e8413173628c11534f5ac815ef8 Mon Sep 17 00:00:00 2001 From: William S Fulton Date: Wed, 29 Oct 2014 09:42:11 +0000 Subject: Revert "Fix when is 'self' used as a parameter name in Python" This reverts commit a6efdb7999298de6be8c5b4f1fca4ff60ac1fb20. --- Examples/test-suite/keyword_rename.i | 4 ---- Examples/test-suite/python/keyword_rename_runme.py | 4 +--- Lib/python/pythonkw.swg | 2 +- 3 files changed, 2 insertions(+), 8 deletions(-) diff --git a/Examples/test-suite/keyword_rename.i b/Examples/test-suite/keyword_rename.i index 3a878ae80..46c3338b3 100644 --- a/Examples/test-suite/keyword_rename.i +++ b/Examples/test-suite/keyword_rename.i @@ -35,10 +35,6 @@ KW(chan, fallthrough) KW(end, function) KW(nil,local) -struct Keywords { - void selfkw(int self) {} -}; - %} diff --git a/Examples/test-suite/python/keyword_rename_runme.py b/Examples/test-suite/python/keyword_rename_runme.py index f6796db52..5646ce7d6 100644 --- a/Examples/test-suite/python/keyword_rename_runme.py +++ b/Examples/test-suite/python/keyword_rename_runme.py @@ -1,6 +1,4 @@ +#!/usr/bin/env python import keyword_rename keyword_rename._in(1) keyword_rename._except(1) - -k = keyword_rename.Keywords() -k.selfkw(123) diff --git a/Lib/python/pythonkw.swg b/Lib/python/pythonkw.swg index 2f76a664a..8ad0ef11b 100644 --- a/Lib/python/pythonkw.swg +++ b/Lib/python/pythonkw.swg @@ -130,7 +130,7 @@ PYTHONKW(None); /* 'self' is also a bad Name */ -PYTHONKW(self); +PYTHONBN(self); #undef PYTHONBN #undef PYTHONKW -- cgit v1.2.1 From fc1eaa521368cc410a5410103234cf6b00cfd77e Mon Sep 17 00:00:00 2001 From: William S Fulton Date: Wed, 29 Oct 2014 12:23:51 +0000 Subject: Fix autodoc testcase for python -builtin --- Examples/test-suite/python/autodoc_runme.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Examples/test-suite/python/autodoc_runme.py b/Examples/test-suite/python/autodoc_runme.py index f32b94adc..756b85904 100644 --- a/Examples/test-suite/python/autodoc_runme.py +++ b/Examples/test-suite/python/autodoc_runme.py @@ -287,7 +287,7 @@ check(B.__doc__, "Proxy of C++ B class", "::B" ) -check(C.__init__.__doc__, "__init__(self, a, b, h) -> C") +check(C.__init__.__doc__, "__init__(self, a, b, h) -> C", None, skip) check(D.__init__.__doc__, "__init__(D self, int a, int b, Hola h) -> D", None, skip) check(E.__init__.__doc__, "\n" -- cgit v1.2.1 From ede1e9544c1d999fb4504b076bee53356e3e53c8 Mon Sep 17 00:00:00 2001 From: William S Fulton Date: Wed, 29 Oct 2014 22:57:55 +0000 Subject: Fix R Lib files and testcase failing due to new preprocessor checks Fixes unknown preprocessor directive error introduced in #217 commit 255c929c5636f54c16261bd92b8eea2005d61b11 These were probably intended as script comments using # when C/C++ comments using // or /* */ should have been used. --- Examples/test-suite/r_overload_array.i | 7 ++++--- Lib/r/rfragments.swg | 2 +- Lib/r/rtype.swg | 34 +++++++++++----------------------- 3 files changed, 16 insertions(+), 27 deletions(-) diff --git a/Examples/test-suite/r_overload_array.i b/Examples/test-suite/r_overload_array.i index 1474661c4..aa714dfdb 100644 --- a/Examples/test-suite/r_overload_array.i +++ b/Examples/test-suite/r_overload_array.i @@ -1,7 +1,8 @@ %module r_overload_array -%include "stl.i" -# this tests the situation in which there is a scalar function -# corresponding with a vector one + +%include +// this tests the situation in which there is a scalar function +// corresponding with a vector one %inline %{ class Foo { diff --git a/Lib/r/rfragments.swg b/Lib/r/rfragments.swg index afb75c3c1..2ec8f867f 100644 --- a/Lib/r/rfragments.swg +++ b/Lib/r/rfragments.swg @@ -153,7 +153,7 @@ SWIG_strdup(const char *str) } } -# This is modified from the R header files +//# This is modified from the R header files %fragment("SWIG_FromCharPtrAndSize","header") { diff --git a/Lib/r/rtype.swg b/Lib/r/rtype.swg index 9e5aa7b6d..22639f2d0 100644 --- a/Lib/r/rtype.swg +++ b/Lib/r/rtype.swg @@ -149,34 +149,22 @@ string &, std::string & %typemap(scoerceout) enum SWIGTYPE *const %{ $result = enumToInteger($result, "$R_class"); %} -#%typemap(scoerceout) SWIGTYPE -# %{ class($result) <- "$&R_class"; %} +%typemap(scoerceout) SEXP %{ %} -#%typemap(scoerceout) SWIGTYPE & -# %{ class($result) <- "$R_class"; %} - -#%typemap(scoerceout) SWIGTYPE * -# %{ class($result) <- "$R_class"; %} - -#%typemap(scoerceout) SWIGTYPE *const -# %{ class($result) <- "$R_class"; %} - - %typemap(scoerceout) SEXP %{ %} - - %typemap(scoerceout) SWIGTYPE - %{ $result <- new("$&R_class", ref=$result); %} +%typemap(scoerceout) SWIGTYPE + %{ $result <- new("$&R_class", ref=$result); %} - %typemap(scoerceout) SWIGTYPE & - %{ $result <- new("$R_class", ref=$result) ; %} +%typemap(scoerceout) SWIGTYPE & + %{ $result <- new("$R_class", ref=$result) ; %} - %typemap(scoerceout) SWIGTYPE && - %{ $result <- new("$R_class", ref=$result) ; %} +%typemap(scoerceout) SWIGTYPE && + %{ $result <- new("$R_class", ref=$result) ; %} - %typemap(scoerceout) SWIGTYPE * - %{ $result <- new("$R_class", ref=$result) ; %} +%typemap(scoerceout) SWIGTYPE * + %{ $result <- new("$R_class", ref=$result) ; %} - %typemap(scoerceout) SWIGTYPE *const - %{ $result <- new("$R_class", ref=$result) ; %} +%typemap(scoerceout) SWIGTYPE *const + %{ $result <- new("$R_class", ref=$result) ; %} /* Override the SWIGTYPE * above. */ -- cgit v1.2.1 From 3855b96459d1e2397b6455dbabb4db0ffb8fb33e Mon Sep 17 00:00:00 2001 From: William S Fulton Date: Wed, 29 Oct 2014 23:10:40 +0000 Subject: Update changes file --- CHANGES.current | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/CHANGES.current b/CHANGES.current index 85f9a0110..a5f089dbf 100644 --- a/CHANGES.current +++ b/CHANGES.current @@ -5,6 +5,13 @@ See the RELEASENOTES file for a summary of changes in each release. Version 3.0.3 (in progress) =========================== +2014-10-28: vadz + [Python] Patch #201 The generated .py file no longer uses *args for all Python parameters. + Instead, the parameters are named using the C++ parameter names. + +2014-10-24: timotheecour + [D] Patch #204 Use core.atomic.atomicOp to mutate shared variables + 2014-10-21: wsfulton Fix issue #242 - Use of the "kwargs" feature no longer automatically turns on the "compactdefaultargs" feature if the target language does not support kwargs. -- cgit v1.2.1 From 6029b2f7d83251dbc6349de2c1c606859c727044 Mon Sep 17 00:00:00 2001 From: William S Fulton Date: Thu, 30 Oct 2014 07:22:59 +0000 Subject: Fix for 'self' being used as a parameter name --- Examples/test-suite/director_keywords.i | 8 +++++--- Examples/test-suite/python/director_keywords_runme.py | 5 +++++ Lib/python/pythonkw.swg | 2 +- Source/Modules/java.cxx | 8 ++++---- Source/Modules/perl5.cxx | 8 ++++---- 5 files changed, 19 insertions(+), 12 deletions(-) create mode 100644 Examples/test-suite/python/director_keywords_runme.py diff --git a/Examples/test-suite/director_keywords.i b/Examples/test-suite/director_keywords.i index 473786c00..53f124772 100644 --- a/Examples/test-suite/director_keywords.i +++ b/Examples/test-suite/director_keywords.i @@ -1,13 +1,15 @@ // Checks if collisions of argument names with target language keywords are -// resolved properly when directors are used (currently only »abstract« for -// C#, D and Java is checked). +// resolved properly when directors are used %module(directors="1") director_keywords +%warnfilter(SWIGWARN_PARSE_KEYWORD); + %feature("director") Foo; %inline %{ struct Foo { virtual ~Foo() {} - virtual void bar(int abstract) {} + virtual void check_abstract(int abstract) {} // for Java, C#, D... + virtual void check_self(int self) {} // self for Python }; %} diff --git a/Examples/test-suite/python/director_keywords_runme.py b/Examples/test-suite/python/director_keywords_runme.py new file mode 100644 index 000000000..03a50206a --- /dev/null +++ b/Examples/test-suite/python/director_keywords_runme.py @@ -0,0 +1,5 @@ +from director_keywords import * + +f = Foo() +f.check_self(20) + diff --git a/Lib/python/pythonkw.swg b/Lib/python/pythonkw.swg index 8ad0ef11b..2f76a664a 100644 --- a/Lib/python/pythonkw.swg +++ b/Lib/python/pythonkw.swg @@ -130,7 +130,7 @@ PYTHONKW(None); /* 'self' is also a bad Name */ -PYTHONBN(self); +PYTHONKW(self); #undef PYTHONBN #undef PYTHONKW diff --git a/Source/Modules/java.cxx b/Source/Modules/java.cxx index 72924fac2..2d07c55c4 100644 --- a/Source/Modules/java.cxx +++ b/Source/Modules/java.cxx @@ -2268,7 +2268,7 @@ public: Printf(imcall, "swigCPtr"); String *this_type = Copy(getClassType()); - String *name = NewString("self"); + String *name = NewString("jself"); String *qualifier = Getattr(n, "qualifier"); if (qualifier) SwigType_push(this_type, qualifier); @@ -3734,7 +3734,7 @@ public: /* Create the intermediate class wrapper */ tm = Swig_typemap_lookup("jtype", n, "", 0); if (tm) { - Printf(callback_def, " public static %s %s(%s self", tm, imclass_dmethod, qualified_classname); + Printf(callback_def, " public static %s %s(%s jself", tm, imclass_dmethod, qualified_classname); } else { Swig_warning(WARN_JAVA_TYPEMAP_JTYPE_UNDEF, input_file, line_number, "No jtype typemap defined for %s\n", SwigType_str(returntype, 0)); } @@ -3851,7 +3851,7 @@ public: Printf(w->code, "if (swigjobj && jenv->IsSameObject(swigjobj, NULL) == JNI_FALSE) {\n"); } - /* Start the Java field descriptor for the intermediate class's upcall (insert self object) */ + /* Start the Java field descriptor for the intermediate class's upcall (insert jself object) */ Parm *tp = NewParmNode(c_classname, n); String *jdesc; @@ -4062,7 +4062,7 @@ public: /* Emit the intermediate class's upcall to the actual class */ - String *upcall = NewStringf("self.%s(%s)", symname, imcall_args); + String *upcall = NewStringf("jself.%s(%s)", symname, imcall_args); // Handle exception classes specified in the "except" feature's "throws" attribute addThrows(n, "feature:except", n); diff --git a/Source/Modules/perl5.cxx b/Source/Modules/perl5.cxx index c67ba554a..224c4852e 100644 --- a/Source/Modules/perl5.cxx +++ b/Source/Modules/perl5.cxx @@ -2178,12 +2178,12 @@ public: SwigType_add_pointer(ptype); String *mangle = SwigType_manglestr(ptype); - Wrapper_add_local(w, "self", "SV *self"); - Printf(w->code, "self = SWIG_NewPointerObj(SWIG_as_voidptr(this), SWIGTYPE%s, SWIG_SHADOW);\n", mangle); - Printf(w->code, "sv_bless(self, gv_stashpv(swig_get_class(), 0));\n"); + Wrapper_add_local(w, "swigself", "SV *swigself"); + Printf(w->code, "swigself = SWIG_NewPointerObj(SWIG_as_voidptr(this), SWIGTYPE%s, SWIG_SHADOW);\n", mangle); + Printf(w->code, "sv_bless(swigself, gv_stashpv(swig_get_class(), 0));\n"); Delete(mangle); Delete(ptype); - Append(pstack, "XPUSHs(self);\n"); + Append(pstack, "XPUSHs(swigself);\n"); } Parm *p; -- cgit v1.2.1 From 6d6cefa7916dc8019178cf0f63cfef455b859863 Mon Sep 17 00:00:00 2001 From: William S Fulton Date: Fri, 31 Oct 2014 07:23:08 +0000 Subject: Fix 'self' parameter name clash when generating for Python builtin --- Examples/test-suite/director_keywords.i | 1 + Source/Modules/python.cxx | 10 ++++++++++ 2 files changed, 11 insertions(+) diff --git a/Examples/test-suite/director_keywords.i b/Examples/test-suite/director_keywords.i index 53f124772..53f36a8f6 100644 --- a/Examples/test-suite/director_keywords.i +++ b/Examples/test-suite/director_keywords.i @@ -11,5 +11,6 @@ struct Foo { virtual ~Foo() {} virtual void check_abstract(int abstract) {} // for Java, C#, D... virtual void check_self(int self) {} // self for Python + virtual void check_from(int from) {} // for Python }; %} diff --git a/Source/Modules/python.cxx b/Source/Modules/python.cxx index e2c3180ff..6a0b286ca 100644 --- a/Source/Modules/python.cxx +++ b/Source/Modules/python.cxx @@ -4841,6 +4841,16 @@ int PYTHON::classDirectorMethod(Node *n, Node *parent, String *super) { int idx; bool ignored_method = GetFlag(n, "feature:ignore") ? true : false; + if (builtin) { + // Rename any wrapped parameters called 'self' as the generated code contains a variable with same name + Parm *p; + for (p = l; p; p = nextSibling(p)) { + String *arg = Getattr(p, "name"); + if (arg && Cmp(arg, "self") == 0) + Delattr(p, "name"); + } + } + if (Cmp(storage, "virtual") == 0) { if (Cmp(value, "0") == 0) { pure_virtual = true; -- cgit v1.2.1 From 837d2bfd04929845c9f6d351bc141f5b8e01c903 Mon Sep 17 00:00:00 2001 From: Alexey Pelykh Date: Mon, 3 Nov 2014 12:10:10 +0200 Subject: Removed useless code (it does not affect output, at least on our testcases) --- Source/Modules/java.cxx | 23 ----------------------- 1 file changed, 23 deletions(-) diff --git a/Source/Modules/java.cxx b/Source/Modules/java.cxx index e67b03290..e8c76854f 100644 --- a/Source/Modules/java.cxx +++ b/Source/Modules/java.cxx @@ -1556,22 +1556,6 @@ public: } else if (!const_feature_flag) { // Default enum and constant handling will work with any type of C constant and initialises the Java variable from C through a JNI call. - String* pureSymname = NULL; - if (Equal(Getattr(n, "nodeType"), "enumitem")) { - // If enum is strongly-typed, generate fully-qualified symname - Node* parent = parentNode(n); - String* pureSymname = NULL; - if (GetFlag(parent, "scopedenum") && !GetFlag(n, "symname_has_enumscope")) { - pureSymname = symname; - - String* enumClassName = Swig_scopename_last(Getattr(parent, "name")); - symname = Swig_name_member(0, enumClassName, pureSymname); - Delete(enumClassName); - - /* Printf(stdout, "Renamed strong enum value symname (java:1) '%s' -> '%s'\n", pureSymname, symname); */ - } - } - if (classname_substituted_flag) { if (SwigType_isenum(t)) { // This handles wrapping of inline initialised const enum static member variables (not when wrapping enum items - ignored later on) @@ -1584,13 +1568,6 @@ public: Printf(constants_code, "%s.%s();\n", full_imclass_name ? full_imclass_name : imclass_name, Swig_name_get(getNSpace(), symname)); } - // Delete temporary symname if it was created - if (pureSymname) { - Delete(symname); - symname = pureSymname; - pureSymname = NULL; - } - // Each constant and enum value is wrapped with a separate JNI function call SetFlag(n, "feature:immutable"); enum_constant_flag = true; -- cgit v1.2.1 From 8bc38dc0070740d1a4b1ec522f80c7e292a74850 Mon Sep 17 00:00:00 2001 From: Vladimir Kalinin Date: Tue, 4 Nov 2014 19:30:53 +0300 Subject: fixes "flatnested" feature for out-of-scope defined nested classes --- Examples/test-suite/nested_scope.i | 11 +++++++++++ Source/CParse/parser.y | 14 +++++++++++--- 2 files changed, 22 insertions(+), 3 deletions(-) diff --git a/Examples/test-suite/nested_scope.i b/Examples/test-suite/nested_scope.i index 789478361..059b73535 100644 --- a/Examples/test-suite/nested_scope.i +++ b/Examples/test-suite/nested_scope.i @@ -26,4 +26,15 @@ namespace ns { #endif }; } +#ifndef __clang__ + class Outer1 { + struct Nested1; + public: + struct Nested2; + }; + struct Outer1::Nested2 { + int data; + }; +#endif + %} diff --git a/Source/CParse/parser.y b/Source/CParse/parser.y index 61b0462b5..c4061b110 100644 --- a/Source/CParse/parser.y +++ b/Source/CParse/parser.y @@ -1018,7 +1018,7 @@ static Node *nested_forward_declaration(const char *storage, const char *kind, S } } - if (!GetFlag(currentOuterClass, "nested")) { + if (!currentOuterClass || !GetFlag(currentOuterClass, "nested")) { if (nn && Equal(nodeType(nn), "classforward")) { Node *n = nn; SWIG_WARN_NODE_BEGIN(n); @@ -3451,8 +3451,14 @@ cpp_class_decl : storage_class cpptype idcolon inherit LBRACE { nscope = Getattr($$, "nested:nscope"); Delattr($$, "nested:innerscope"); Delattr($$, "nested:nscope"); - if (nscope_inner && Strcmp(nodeType(nscope_inner), "class") == 0) /* actual parent class for this class */ - Setattr($$, "nested:outer", nscope_inner); + if (nscope_inner && Strcmp(nodeType(nscope_inner), "class") == 0) { /* actual parent class for this class */ + Node* forward_declaration = Swig_symbol_clookup_no_inherit(Getattr($$,"name"), Getattr(nscope_inner, "symtab")); + if (forward_declaration) { + Setattr($$, "access", Getattr(forward_declaration, "access")); + } + Setattr($$, "nested:outer", nscope_inner); + SetFlag($$, "nested"); + } if (!currentOuterClass) inclass = 0; cscope = Getattr($$, "prev_symtab"); @@ -3531,6 +3537,8 @@ cpp_class_decl : storage_class cpptype idcolon inherit LBRACE { } else if (nscope_inner) { /* this is tricky */ /* we add the declaration in the original namespace */ + if (Strcmp(nodeType(nscope_inner), "class") == 0 && cparse_cplusplus && ignore_nested_classes && !GetFlag($$, "feature:flatnested")) + $$ = nested_forward_declaration($1, $2, $3, Copy($3), $9); appendChild(nscope_inner, $$); Swig_symbol_setscope(Getattr(nscope_inner, "symtab")); Delete(Namespaceprefix); -- cgit v1.2.1 From 45b9070a1ddf1a2b04d159998e5bded97133d9be Mon Sep 17 00:00:00 2001 From: Olly Betts Date: Wed, 5 Nov 2014 09:56:55 +1300 Subject: Fix doc typos reported by tounsi67 in issue#260 --- Doc/Manual/Javascript.html | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/Doc/Manual/Javascript.html b/Doc/Manual/Javascript.html index 6aabdc754..4a0cd46a8 100644 --- a/Doc/Manual/Javascript.html +++ b/Doc/Manual/Javascript.html @@ -195,7 +195,7 @@ $ sudo npm install -g node-gyp

    First create the wrapper using SWIG:

    -$ swig -javascript -node -c++ example.cxx
    +$ swig -javascript -node -c++ example.i

    Then run node-gyp

    @@ -353,8 +353,8 @@ It has some extras to configure node-webkit. See the
     {
    -  "name": "example"
    -  "main": "app.html"
    +  "name": "example",
    +  "main": "app.html",
       "window": {
         "show": true,
         "width": 800,
    -- 
    cgit v1.2.1
    
    
    From 7717dc1aafd24e050483f1c1ad005ebda853f18a Mon Sep 17 00:00:00 2001
    From: Anthony Li 
    Date: Wed, 5 Nov 2014 09:42:38 +0800
    Subject: delete unmeaningful macro
    
    ---
     Examples/python/import_packages/relativeimport2/runme3.py | 9 ---------
     Examples/test-suite/overload_polymorphic.i                | 3 ---
     2 files changed, 12 deletions(-)
     delete mode 100644 Examples/python/import_packages/relativeimport2/runme3.py
    
    diff --git a/Examples/python/import_packages/relativeimport2/runme3.py b/Examples/python/import_packages/relativeimport2/runme3.py
    deleted file mode 100644
    index 4b0d112cf..000000000
    --- a/Examples/python/import_packages/relativeimport2/runme3.py
    +++ /dev/null
    @@ -1,9 +0,0 @@
    -# Test import of modules content from within __init__.py
    -print("Testing %module(package=...) + python 'import' in __init__.py")
    -import sys
    -if sys.version_info < (3, 0):
    -  import py2.pkg2.bar
    -  print("  Finished importing py2.pkg2.bar")
    -else:
    -  import py3.pkg2.bar
    -  print("  Finished importing py3.pkg2.bar")
    diff --git a/Examples/test-suite/overload_polymorphic.i b/Examples/test-suite/overload_polymorphic.i
    index 83e3cc257..a1f123b9d 100644
    --- a/Examples/test-suite/overload_polymorphic.i
    +++ b/Examples/test-suite/overload_polymorphic.i
    @@ -1,7 +1,5 @@
     %module overload_polymorphic
     
    -#ifndef SWIG_NO_OVERLOAD
    -
     %inline %{
     
     class Base {
    @@ -22,4 +20,3 @@ int test(Base* base){ return 0;}
     int test(int hello){ return 1; }
     
     %}
    -#endif
    -- 
    cgit v1.2.1
    
    
    From bb768f5aa57e360f600194448ecc9a2823e73a33 Mon Sep 17 00:00:00 2001
    From: David Nadlinger 
    Date: Sat, 25 Oct 2014 20:46:48 +0200
    Subject: D: Fix li_boost_shared_ptr_runme.2.d compilation.
    
    The overload of Thread.sleep taking a bare integer has been
    deprecated/removed.
    ---
     Examples/test-suite/d/li_boost_shared_ptr_runme.2.d | 3 ++-
     1 file changed, 2 insertions(+), 1 deletion(-)
    
    diff --git a/Examples/test-suite/d/li_boost_shared_ptr_runme.2.d b/Examples/test-suite/d/li_boost_shared_ptr_runme.2.d
    index 0027aad05..b74751392 100644
    --- a/Examples/test-suite/d/li_boost_shared_ptr_runme.2.d
    +++ b/Examples/test-suite/d/li_boost_shared_ptr_runme.2.d
    @@ -2,6 +2,7 @@ module li_boost_shared_ptr_runme;
     
     import core.memory;
     import core.thread;
    +import core.time;
     import std.conv;
     import std.exception;
     import std.stdio;
    @@ -37,7 +38,7 @@ void main() {
         GC.collect();
         if (Klass.getTotal_count() == 1)
           break;
    -    Thread.sleep(100);
    +    Thread.sleep(100.usecs);
       }
     
       // A single remaining instance expected: the global variable (GlobalValue).
    -- 
    cgit v1.2.1
    
    
    From 0b42c6f653254e9d4456c445a30381d4ded2a523 Mon Sep 17 00:00:00 2001
    From: David Nadlinger 
    Date: Sat, 25 Oct 2014 21:25:48 +0200
    Subject: D: Fix allprotected_not.i compilation.
    
    The director cycle breaking code was emitted when protectors
    were not actually enabled on the parent class, leading to
    swigIsMethodOverridden being called but not declared.
    ---
     Source/Modules/d.cxx | 2 +-
     1 file changed, 1 insertion(+), 1 deletion(-)
    
    diff --git a/Source/Modules/d.cxx b/Source/Modules/d.cxx
    index 364a2bbee..328e03fff 100644
    --- a/Source/Modules/d.cxx
    +++ b/Source/Modules/d.cxx
    @@ -2850,7 +2850,7 @@ private:
           // polymorphic call or an explicit method call. Needed to prevent infinite
           // recursion when calling director methods.
           Node *explicit_n = Getattr(n, "explicitcallnode");
    -      if (explicit_n) {
    +      if (explicit_n && Swig_directorclass(getCurrentClass())) {
     	String *ex_overloaded_name = getOverloadedName(explicit_n);
     	String *ex_intermediary_function_name = Swig_name_member(getNSpace(), proxy_class_name, ex_overloaded_name);
     
    -- 
    cgit v1.2.1
    
    
    From 2faef96e0a19dfb9206e1acdf14567293932808c Mon Sep 17 00:00:00 2001
    From: David Nadlinger 
    Date: Sat, 25 Oct 2014 22:05:22 +0200
    Subject: D: Fix preproc_constants/preproc_constants_c test cases.
    
    ---
     Examples/test-suite/preproc_constants.i | 2 ++
     1 file changed, 2 insertions(+)
    
    diff --git a/Examples/test-suite/preproc_constants.i b/Examples/test-suite/preproc_constants.i
    index 7507d632c..ef5c35e12 100644
    --- a/Examples/test-suite/preproc_constants.i
    +++ b/Examples/test-suite/preproc_constants.i
    @@ -85,6 +85,8 @@
     /// constant assignment in enum
     #if defined(SWIGCSHARP)
     %csconstvalue("1<<2") kValue;
    +#elif defined(SWIGD)
    +%dconstvalue("1<<2") kValue;
     #endif
     
     %{
    -- 
    cgit v1.2.1
    
    
    From 95e8db7c6232d0ffab55d291e2b23d9b9abb70ac Mon Sep 17 00:00:00 2001
    From: David Nadlinger 
    Date: Sat, 25 Oct 2014 22:34:42 +0200
    Subject: D: Fix class/method name ambiguity in test-suite/c_delete.i.
    
    There might be other cases where this happens when $dclassname
    is used for code emitted into the proxy class itself, but so
    far, there are none in the test suite or any bug reports.
    ---
     Lib/d/boost_shared_ptr.i | 4 ++--
     Lib/d/dclassgen.swg      | 8 ++++----
     2 files changed, 6 insertions(+), 6 deletions(-)
    
    diff --git a/Lib/d/boost_shared_ptr.i b/Lib/d/boost_shared_ptr.i
    index bfa2aa646..5c171555e 100644
    --- a/Lib/d/boost_shared_ptr.i
    +++ b/Lib/d/boost_shared_ptr.i
    @@ -152,7 +152,7 @@ public this(void* cObject, bool ownCObject) {
       swigCMemOwn = ownCObject;
     }
     
    -public static void* swigGetCPtr($dclassname obj) {
    +public static void* swigGetCPtr(typeof(this) obj) {
       return (obj is null) ? null : obj.swigCPtr;
     }
     %}
    @@ -167,7 +167,7 @@ public this(void* cObject, bool ownCObject) {
       swigCMemOwn = ownCObject;
     }
     
    -public static void* swigGetCPtr($dclassname obj) {
    +public static void* swigGetCPtr(typeof(this) obj) {
       return (obj is null) ? null : obj.swigCPtr;
     }
     %}
    diff --git a/Lib/d/dclassgen.swg b/Lib/d/dclassgen.swg
    index ceaf50727..68910b412 100644
    --- a/Lib/d/dclassgen.swg
    +++ b/Lib/d/dclassgen.swg
    @@ -72,7 +72,7 @@ public this(void* cObject, bool ownCObject) {
       swigCMemOwn = ownCObject;
     }
     
    -public static void* swigGetCPtr($dclassname obj) {
    +public static void* swigGetCPtr(typeof(this) obj) {
       return (obj is null) ? null : obj.swigCPtr;
     }
     
    @@ -88,7 +88,7 @@ public this(void* cObject, bool ownCObject) {
       swigCPtr = cObject;
     }
     
    -public static void* swigGetCPtr($dclassname obj) {
    +public static void* swigGetCPtr(typeof(this) obj) {
       return (obj is null) ? null : obj.swigCPtr;
     }
     
    @@ -111,7 +111,7 @@ protected this() {
       swigCPtr = null;
     }
     
    -public static void* swigGetCPtr($dclassname obj) {
    +public static void* swigGetCPtr(typeof(this) obj) {
       return (obj is null) ? null : obj.swigCPtr;
     }
     
    @@ -134,7 +134,7 @@ protected this() {
       swigCPtr = null;
     }
     
    -package static char* swigGetCMemberPtr($dclassname obj) {
    +package static char* swigGetCMemberPtr(typeof(this) obj) {
       return (obj is null) ? null : obj.swigCPtr;
     }
     
    -- 
    cgit v1.2.1
    
    
    From 0d6472525c808d9cbf3e7cfcddd9a6850c68470d Mon Sep 17 00:00:00 2001
    From: David Nadlinger 
    Date: Sat, 25 Oct 2014 23:10:09 +0200
    Subject: D: Fix name collision between im D module function pointer and actual
     C function.
    
    Previously, the function pointers were not only declared with
    extern(C) calling convention, but actually had C linkage
    themselves. Thus, they were exported under their bare names,
    potentially colliding with the actual function definitions
    in the wrapped library if the dynamic linker decided to
    resolve them the wrong way.
    
    This fixes the sneaky1 test case, although I have no idea why
    the add() reference in D_add() (via the PLT) is rebound to the
    function pointer there and not in all other test cases and
    real-world libraries. As far as I can see, there don't seem to
    be any special symbol visibility/binding settings involved in
    our build system.
    ---
     Source/Modules/d.cxx | 2 +-
     1 file changed, 1 insertion(+), 1 deletion(-)
    
    diff --git a/Source/Modules/d.cxx b/Source/Modules/d.cxx
    index 328e03fff..7af1b9942 100644
    --- a/Source/Modules/d.cxx
    +++ b/Source/Modules/d.cxx
    @@ -2594,7 +2594,7 @@ private:
         const_String_or_char_ptr wrapper_function_name) {
     
         // TODO: Add support for static linking here.
    -    Printf(im_dmodule_code, "extern(C) %s function%s %s;\n", return_type,
    +    Printf(im_dmodule_code, "SwigExternC!(%s function%s) %s;\n", return_type,
           parameters, d_name);
         Printv(wrapper_loader_bind_code, wrapper_loader_bind_command, NIL);
         Replaceall(wrapper_loader_bind_code, "$function", d_name);
    -- 
    cgit v1.2.1
    
    
    From a9d7b7f40c02b75be0ff1c679a5c9d740de32b94 Mon Sep 17 00:00:00 2001
    From: David Nadlinger 
    Date: Mon, 27 Oct 2014 22:23:01 +0100
    Subject: Work around D test suite failure due to issue #254.
    
    Object is currently a D keyword for the purposes of SWIG
    (that's in fact a little too strict, but Object is the root
    of the class hierarchy and some parts of the code break).
    'template_typedef_typedef' is supposed to test.
    ---
     Examples/test-suite/java/template_typedef_typedef_runme.java | 6 +++---
     Examples/test-suite/template_typedef_typedef.i               | 8 ++++----
     2 files changed, 7 insertions(+), 7 deletions(-)
    
    diff --git a/Examples/test-suite/java/template_typedef_typedef_runme.java b/Examples/test-suite/java/template_typedef_typedef_runme.java
    index f5f368561..5a3af0099 100644
    --- a/Examples/test-suite/java/template_typedef_typedef_runme.java
    +++ b/Examples/test-suite/java/template_typedef_typedef_runme.java
    @@ -12,13 +12,13 @@ public class template_typedef_typedef_runme {
       }
     
       public static void main(String argv[]) {
    -    ObjectBase ob1 = new ObjectBase();
    -    ob1.getBlabla1(new ObjectBase());
    +    Object1Base ob1 = new Object1Base();
    +    ob1.getBlabla1(new Object1Base());
         Object2Base ob2 = new Object2Base();
         ob2.getBlabla2(new Object2Base());
     
         Factory factory = new Factory();
    -    factory.getBlabla3(new ObjectBase());
    +    factory.getBlabla3(new Object1Base());
         factory.getBlabla4(new Object2Base());
       }
     }
    diff --git a/Examples/test-suite/template_typedef_typedef.i b/Examples/test-suite/template_typedef_typedef.i
    index 30077c484..ac96b2db8 100644
    --- a/Examples/test-suite/template_typedef_typedef.i
    +++ b/Examples/test-suite/template_typedef_typedef.i
    @@ -1,7 +1,7 @@
     %module template_typedef_typedef
     
     // Github issue #50
    -// The Object2::getBlabla2 and Object::getBlabla1 functions were not resolving to the correct template types
    +// The Object2::getBlabla2 and Object1::getBlabla1 functions were not resolving to the correct template types
     
     %inline%{
     
    @@ -20,7 +20,7 @@ namespace TT{
                     };
             };
             template 
    -        class Object:public T {
    +        class Object1:public T {
             public:
                     void getBlabla1(typename T::ABCD::CC1 c) {
                     };
    @@ -29,7 +29,7 @@ namespace TT{
     
     class Factory {
             public:
    -        typedef TT::Object CC1;
    +        typedef TT::Object1 CC1;
             typedef TT::Object2 CC2;
             void getBlabla4(CC2 c) {
             };
    @@ -38,6 +38,6 @@ class Factory {
     };
     %}
     
    -%template(ObjectBase) TT::Object;
    +%template(Object1Base) TT::Object1;
     %template(Object2Base) TT::Object2;
     
    -- 
    cgit v1.2.1
    
    
    From a8cdd1798edc3221bee33f6b34b8d5ea117f50ce Mon Sep 17 00:00:00 2001
    From: David Nadlinger 
    Date: Thu, 30 Oct 2014 08:30:29 +0100
    Subject: D: Emit empty enums as int aliases instead of omitting them.
    
    This fixes test-suite/enum_forward.i.
    ---
     Source/Modules/d.cxx | 30 +++++++++++++++---------------
     1 file changed, 15 insertions(+), 15 deletions(-)
    
    diff --git a/Source/Modules/d.cxx b/Source/Modules/d.cxx
    index 7af1b9942..da31504e6 100644
    --- a/Source/Modules/d.cxx
    +++ b/Source/Modules/d.cxx
    @@ -803,24 +803,24 @@ public:
         // Emit each enum item.
         Language::enumDeclaration(n);
     
    -    if (!GetFlag(n, "nonempty")) {
    -      // Do not wrap empty enums; the resulting D code would be illegal.
    -      Delete(proxy_enum_code);
    -      return SWIG_NOWRAP;
    -    }
    -
    -    // Finish the enum.
    -    if (typemap_lookup_type) {
    -      Printv(proxy_enum_code,
    -	lookupCodeTypemap(n, "dcode", typemap_lookup_type, WARN_NONE), // Extra D code
    -	"\n}\n", NIL);
    +    if (GetFlag(n, "nonempty")) {
    +      // Finish the enum.
    +      if (typemap_lookup_type) {
    +	Printv(proxy_enum_code,
    +	  lookupCodeTypemap(n, "dcode", typemap_lookup_type, WARN_NONE), // Extra D code
    +	  "\n}\n", NIL);
    +      } else {
    +	// Handle anonymous enums.
    +	Printv(proxy_enum_code, "\n}\n", NIL);
    +      }
    +      Replaceall(proxy_enum_code, "$dclassname", symname);
         } else {
    -      // Handle anonymous enums.
    -      Printv(proxy_enum_code, "\n}\n", NIL);
    +      // D enum declarations must have at least one member to be legal, so emit
    +      // an alias to int instead (their ctype/imtype is always int).
    +      Delete(proxy_enum_code);
    +      proxy_enum_code = NewStringf("\nalias int %s;\n", symname);
         }
     
    -    Replaceall(proxy_enum_code, "$dclassname", symname);
    -
         const String* imports =
           lookupCodeTypemap(n, "dimports", typemap_lookup_type, WARN_NONE);
         String* imports_trimmed;
    -- 
    cgit v1.2.1
    
    
    From 5d133ada9182a5a9e52de52e355239cae0071136 Mon Sep 17 00:00:00 2001
    From: David Nadlinger 
    Date: Fri, 31 Oct 2014 20:14:35 +0100
    Subject: D: Use deterministic allocation on the D side in
     li_boost_shared_ptr_runme.i.
    
    ---
     .../test-suite/d/li_boost_shared_ptr_runme.2.d     | 273 +++++++++++----------
     1 file changed, 141 insertions(+), 132 deletions(-)
    
    diff --git a/Examples/test-suite/d/li_boost_shared_ptr_runme.2.d b/Examples/test-suite/d/li_boost_shared_ptr_runme.2.d
    index b74751392..028929543 100644
    --- a/Examples/test-suite/d/li_boost_shared_ptr_runme.2.d
    +++ b/Examples/test-suite/d/li_boost_shared_ptr_runme.2.d
    @@ -32,15 +32,6 @@ void main() {
       if (TRACE)
         writeln("---> NEARLY FINISHED <---");
     
    -  // Try to get the GC to collect everything not referenced anymore.
    -  int countdown = 100;
    -  while (--countdown) {
    -    GC.collect();
    -    if (Klass.getTotal_count() == 1)
    -      break;
    -    Thread.sleep(100.usecs);
    -  }
    -
       // A single remaining instance expected: the global variable (GlobalValue).
       if (Klass.getTotal_count() != 1)
         throw new Exception("Klass.total_count=" ~ to!string(Klass.getTotal_count()));
    @@ -56,9 +47,15 @@ void main() {
     }
     
     void runTest() {
    +  // We want to check whether all the C++ Klass instances have been properly
    +  // destructed after the tests have run. However, as it is legal for the GC
    +  // to leave an object around even if it is unreachable, use deterministic
    +  // memory management here.
    +  import std.typecons : scoped;
    +
       // simple shared_ptr usage - created in C++
       {
    -    auto k = new Klass("me oh my");
    +    auto k = scoped!Klass("me oh my");
         string val = k.getValue();
         verifyValue("me oh my", val);
         verifyCount(1, k);
    @@ -74,7 +71,7 @@ void runTest() {
     
       // pass by shared_ptr
       {
    -    auto k = new Klass("me oh my");
    +    auto k = scoped!Klass("me oh my");
         auto kret = smartpointertest(k);
         string val = kret.getValue();
         verifyValue("me oh my smartpointertest", val);
    @@ -84,7 +81,7 @@ void runTest() {
     
       // pass by shared_ptr pointer
       {
    -    auto k = new Klass("me oh my");
    +    auto k = scoped!Klass("me oh my");
         auto kret = smartpointerpointertest(k);
         string val = kret.getValue();
         verifyValue("me oh my smartpointerpointertest", val);
    @@ -94,7 +91,7 @@ void runTest() {
     
       // pass by shared_ptr reference
       {
    -    auto k = new Klass("me oh my");
    +    auto k = scoped!Klass("me oh my");
         auto kret = smartpointerreftest(k);
         string val = kret.getValue();
         verifyValue("me oh my smartpointerreftest", val);
    @@ -104,7 +101,7 @@ void runTest() {
     
       // pass by shared_ptr pointer reference
       {
    -    auto k = new Klass("me oh my");
    +    auto k = scoped!Klass("me oh my");
         auto kret = smartpointerpointerreftest(k);
         string val = kret.getValue();
         verifyValue("me oh my smartpointerpointerreftest", val);
    @@ -114,7 +111,7 @@ void runTest() {
     
       // const pass by shared_ptr
       {
    -    auto k = new Klass("me oh my");
    +    auto k = scoped!Klass("me oh my");
         auto kret = constsmartpointertest(k);
         string val = kret.getValue();
         verifyValue("me oh my", val);
    @@ -124,7 +121,7 @@ void runTest() {
     
       // const pass by shared_ptr pointer
       {
    -    auto k = new Klass("me oh my");
    +    auto k = scoped!Klass("me oh my");
         auto kret = constsmartpointerpointertest(k);
         string val = kret.getValue();
         verifyValue("me oh my", val);
    @@ -134,7 +131,7 @@ void runTest() {
     
       // const pass by shared_ptr reference
       {
    -    auto k = new Klass("me oh my");
    +    auto k = scoped!Klass("me oh my");
         auto kret = constsmartpointerreftest(k);
         string val = kret.getValue();
         verifyValue("me oh my", val);
    @@ -144,7 +141,7 @@ void runTest() {
     
       // pass by value
       {
    -    auto k = new Klass("me oh my");
    +    auto k = scoped!Klass("me oh my");
         auto kret = valuetest(k);
         string val = kret.getValue();
         verifyValue("me oh my valuetest", val);
    @@ -154,7 +151,7 @@ void runTest() {
     
       // pass by pointer
       {
    -    auto k = new Klass("me oh my");
    +    auto k = scoped!Klass("me oh my");
         auto kret = pointertest(k);
         string val = kret.getValue();
         verifyValue("me oh my pointertest", val);
    @@ -164,7 +161,7 @@ void runTest() {
     
       // pass by reference
       {
    -    auto k = new Klass("me oh my");
    +    auto k = scoped!Klass("me oh my");
         auto kret = reftest(k);
         string val = kret.getValue();
         verifyValue("me oh my reftest", val);
    @@ -174,7 +171,7 @@ void runTest() {
     
       // pass by pointer reference
       {
    -    auto k = new Klass("me oh my");
    +    auto k = scoped!Klass("me oh my");
         auto kret = pointerreftest(k);
         string val = kret.getValue();
         verifyValue("me oh my pointerreftest", val);
    @@ -216,7 +213,7 @@ void runTest() {
       ////////////////////////////////// Derived classes ////////////////////////////////////////
       // derived pass by shared_ptr
       {
    -    auto k = new KlassDerived("me oh my");
    +    auto k = scoped!KlassDerived("me oh my");
         auto kret = derivedsmartptrtest(k);
         string val = kret.getValue();
         verifyValue("me oh my derivedsmartptrtest-Derived", val);
    @@ -225,7 +222,7 @@ void runTest() {
       }
       // derived pass by shared_ptr pointer
       {
    -    auto k = new KlassDerived("me oh my");
    +    auto k = scoped!KlassDerived("me oh my");
         auto kret = derivedsmartptrpointertest(k);
         string val = kret.getValue();
         verifyValue("me oh my derivedsmartptrpointertest-Derived", val);
    @@ -234,7 +231,7 @@ void runTest() {
       }
       // derived pass by shared_ptr ref
       {
    -    auto k = new KlassDerived("me oh my");
    +    auto k = scoped!KlassDerived("me oh my");
         auto kret = derivedsmartptrreftest(k);
         string val = kret.getValue();
         verifyValue("me oh my derivedsmartptrreftest-Derived", val);
    @@ -243,7 +240,7 @@ void runTest() {
       }
       // derived pass by shared_ptr pointer ref
       {
    -    auto k = new KlassDerived("me oh my");
    +    auto k = scoped!KlassDerived("me oh my");
         auto kret = derivedsmartptrpointerreftest(k);
         string val = kret.getValue();
         verifyValue("me oh my derivedsmartptrpointerreftest-Derived", val);
    @@ -252,7 +249,7 @@ void runTest() {
       }
       // derived pass by pointer
       {
    -    auto k = new KlassDerived("me oh my");
    +    auto k = scoped!KlassDerived("me oh my");
         auto kret = derivedpointertest(k);
         string val = kret.getValue();
         verifyValue("me oh my derivedpointertest-Derived", val);
    @@ -261,7 +258,7 @@ void runTest() {
       }
       // derived pass by ref
       {
    -    auto k = new KlassDerived("me oh my");
    +    auto k = scoped!KlassDerived("me oh my");
         auto kret = derivedreftest(k);
         string val = kret.getValue();
         verifyValue("me oh my derivedreftest-Derived", val);
    @@ -272,7 +269,7 @@ void runTest() {
       ////////////////////////////////// Derived and base class mixed ////////////////////////////////////////
       // pass by shared_ptr (mixed)
       {
    -    auto k = new KlassDerived("me oh my");
    +    auto k = scoped!KlassDerived("me oh my");
         auto kret = smartpointertest(k);
         string val = kret.getValue();
         verifyValue("me oh my smartpointertest-Derived", val);
    @@ -282,7 +279,7 @@ void runTest() {
     
       // pass by shared_ptr pointer (mixed)
       {
    -    auto k = new KlassDerived("me oh my");
    +    auto k = scoped!KlassDerived("me oh my");
         auto kret = smartpointerpointertest(k);
         string val = kret.getValue();
         verifyValue("me oh my smartpointerpointertest-Derived", val);
    @@ -292,7 +289,7 @@ void runTest() {
     
       // pass by shared_ptr reference (mixed)
       {
    -    auto k = new KlassDerived("me oh my");
    +    auto k = scoped!KlassDerived("me oh my");
         auto kret = smartpointerreftest(k);
         string val = kret.getValue();
         verifyValue("me oh my smartpointerreftest-Derived", val);
    @@ -302,7 +299,7 @@ void runTest() {
     
       // pass by shared_ptr pointer reference (mixed)
       {
    -    auto k = new KlassDerived("me oh my");
    +    auto k = scoped!KlassDerived("me oh my");
         auto kret = smartpointerpointerreftest(k);
         string val = kret.getValue();
         verifyValue("me oh my smartpointerpointerreftest-Derived", val);
    @@ -312,7 +309,7 @@ void runTest() {
     
       // pass by value (mixed)
       {
    -    auto k = new KlassDerived("me oh my");
    +    auto k = scoped!KlassDerived("me oh my");
         auto kret = valuetest(k);
         string val = kret.getValue();
         verifyValue("me oh my valuetest", val); // note slicing
    @@ -322,7 +319,7 @@ void runTest() {
     
       // pass by pointer (mixed)
       {
    -    auto k = new KlassDerived("me oh my");
    +    auto k = scoped!KlassDerived("me oh my");
         auto kret = pointertest(k);
         string val = kret.getValue();
         verifyValue("me oh my pointertest-Derived", val);
    @@ -332,7 +329,7 @@ void runTest() {
     
       // pass by ref (mixed)
       {
    -    auto k = new KlassDerived("me oh my");
    +    auto k = scoped!KlassDerived("me oh my");
         auto kret = reftest(k);
         string val = kret.getValue();
         verifyValue("me oh my reftest-Derived", val);
    @@ -342,7 +339,7 @@ void runTest() {
     
       // 3rd derived class
       {
    -    auto k = new Klass3rdDerived("me oh my");
    +    auto k = scoped!Klass3rdDerived("me oh my");
         string val = k.getValue();
         verifyValue("me oh my-3rdDerived", val);
         verifyCount(3, k); // 3 classes in inheritance chain == 3 swigCPtr values
    @@ -354,128 +351,140 @@ void runTest() {
       ////////////////////////////////// Member variables ////////////////////////////////////////
       // smart pointer by value
       {
    -    auto m = new MemberVariables();
    -    auto k = new Klass("smart member value");
    -    m.SmartMemberValue = k;
    -    string val = k.getValue();
    -    verifyValue("smart member value", val);
    -    verifyCount(2, k);
    -
    -    auto kmember = m.SmartMemberValue;
    -    val = kmember.getValue();
    -    verifyValue("smart member value", val);
    -    verifyCount(3, kmember);
    -    verifyCount(3, k);
    -
    -    delete m;
    +    auto k = scoped!Klass("smart member value");
    +    Klass kmember;
    +
    +    {
    +      auto m = scoped!MemberVariables();
    +      m.SmartMemberValue = k;
    +      string val = k.getValue();
    +      verifyValue("smart member value", val);
    +      verifyCount(2, k);
    +
    +      kmember = m.SmartMemberValue;
    +      val = kmember.getValue();
    +      verifyValue("smart member value", val);
    +      verifyCount(3, kmember);
    +      verifyCount(3, k);
    +    }
     
         verifyCount(2, kmember);
         verifyCount(2, k);
       }
       // smart pointer by pointer
       {
    -    auto m = new MemberVariables();
    -    auto k = new Klass("smart member pointer");
    -    m.SmartMemberPointer = k;
    -    string val = k.getValue();
    -    verifyValue("smart member pointer", val);
    -    verifyCount(1, k);
    -
    -    auto kmember = m.SmartMemberPointer;
    -    val = kmember.getValue();
    -    verifyValue("smart member pointer", val);
    -    verifyCount(2, kmember);
    -    verifyCount(2, k);
    -
    -    delete m;
    +    auto k = scoped!Klass("smart member pointer");
    +    Klass kmember;
    +
    +    {
    +      auto m = scoped!MemberVariables();
    +      m.SmartMemberPointer = k;
    +      string val = k.getValue();
    +      verifyValue("smart member pointer", val);
    +      verifyCount(1, k);
    +
    +      kmember = m.SmartMemberPointer;
    +      val = kmember.getValue();
    +      verifyValue("smart member pointer", val);
    +      verifyCount(2, kmember);
    +      verifyCount(2, k);
    +    }
     
         verifyCount(2, kmember);
         verifyCount(2, k);
       }
       // smart pointer by reference
       {
    -    auto m = new MemberVariables();
    -    auto k = new Klass("smart member reference");
    -    m.SmartMemberReference = k;
    -    string val = k.getValue();
    -    verifyValue("smart member reference", val);
    -    verifyCount(2, k);
    -
    -    auto kmember = m.SmartMemberReference;
    -    val = kmember.getValue();
    -    verifyValue("smart member reference", val);
    -    verifyCount(3, kmember);
    -    verifyCount(3, k);
    -
    -    // The C++ reference refers to SmartMemberValue...
    -    auto kmemberVal = m.SmartMemberValue;
    -    val = kmember.getValue();
    -    verifyValue("smart member reference", val);
    -    verifyCount(4, kmemberVal);
    -    verifyCount(4, kmember);
    -    verifyCount(4, k);
    -
    -    delete m;
    +    auto k = scoped!Klass("smart member reference");
    +    Klass kmember;
    +
    +    {
    +      auto m = scoped!MemberVariables();
    +      m.SmartMemberReference = k;
    +      string val = k.getValue();
    +      verifyValue("smart member reference", val);
    +      verifyCount(2, k);
    +
    +      kmember = m.SmartMemberReference;
    +      val = kmember.getValue();
    +      verifyValue("smart member reference", val);
    +      verifyCount(3, kmember);
    +      verifyCount(3, k);
    +
    +      // The C++ reference refers to SmartMemberValue...
    +      auto kmemberVal = m.SmartMemberValue;
    +      val = kmember.getValue();
    +      verifyValue("smart member reference", val);
    +      verifyCount(4, kmemberVal);
    +      verifyCount(4, kmember);
    +      verifyCount(4, k);
    +    }
     
         verifyCount(3, kmember);
         verifyCount(3, k);
       }
       // plain by value
       {
    -    auto m = new MemberVariables();
    -    auto k = new Klass("plain member value");
    -    m.MemberValue = k;
    -    string val = k.getValue();
    -    verifyValue("plain member value", val);
    -    verifyCount(1, k);
    -
    -    auto kmember = m.MemberValue;
    -    val = kmember.getValue();
    -    verifyValue("plain member value", val);
    -    verifyCount(1, kmember);
    -    verifyCount(1, k);
    -
    -    delete m;
    +    auto k = scoped!Klass("plain member value");
    +    Klass kmember;
    +
    +    {
    +      auto m = scoped!MemberVariables();
    +      m.MemberValue = k;
    +      string val = k.getValue();
    +      verifyValue("plain member value", val);
    +      verifyCount(1, k);
    +
    +      kmember = m.MemberValue;
    +      val = kmember.getValue();
    +      verifyValue("plain member value", val);
    +      verifyCount(1, kmember);
    +      verifyCount(1, k);
    +    }
     
         verifyCount(1, kmember);
         verifyCount(1, k);
       }
       // plain by pointer
       {
    -    auto m = new MemberVariables();
    -    auto k = new Klass("plain member pointer");
    -    m.MemberPointer = k;
    -    string val = k.getValue();
    -    verifyValue("plain member pointer", val);
    -    verifyCount(1, k);
    -
    -    auto kmember = m.MemberPointer;
    -    val = kmember.getValue();
    -    verifyValue("plain member pointer", val);
    -    verifyCount(1, kmember);
    -    verifyCount(1, k);
    -
    -    delete m;
    +    auto k = scoped!Klass("plain member pointer");
    +    Klass kmember;
    +
    +    {
    +      auto m = scoped!MemberVariables();
    +      m.MemberPointer = k;
    +      string val = k.getValue();
    +      verifyValue("plain member pointer", val);
    +      verifyCount(1, k);
    +
    +      kmember = m.MemberPointer;
    +      val = kmember.getValue();
    +      verifyValue("plain member pointer", val);
    +      verifyCount(1, kmember);
    +      verifyCount(1, k);
    +    }
     
         verifyCount(1, kmember);
         verifyCount(1, k);
       }
       // plain by reference
       {
    -    auto m = new MemberVariables();
    -    auto k = new Klass("plain member reference");
    -    m.MemberReference = k;
    -    string val = k.getValue();
    -    verifyValue("plain member reference", val);
    -    verifyCount(1, k);
    -
    -    auto kmember = m.MemberReference;
    -    val = kmember.getValue();
    -    verifyValue("plain member reference", val);
    -    verifyCount(1, kmember);
    -    verifyCount(1, k);
    -
    -    delete m;
    +    auto k = scoped!Klass("plain member reference");
    +    Klass kmember;
    +
    +    {
    +      auto m = scoped!MemberVariables();
    +      m.MemberReference = k;
    +      string val = k.getValue();
    +      verifyValue("plain member reference", val);
    +      verifyCount(1, k);
    +
    +      kmember = m.MemberReference;
    +      val = kmember.getValue();
    +      verifyValue("plain member reference", val);
    +      verifyCount(1, kmember);
    +      verifyCount(1, k);
    +    }
     
         verifyCount(1, kmember);
         verifyCount(1, k);
    @@ -483,7 +492,7 @@ void runTest() {
     
       // null member variables
       {
    -    auto m = new MemberVariables();
    +    auto m = scoped!MemberVariables();
     
         // shared_ptr by value
         auto k = m.SmartMemberValue;
    @@ -505,7 +514,7 @@ void runTest() {
         auto kglobal = GlobalSmartValue;
         enforce(kglobal is null, "expected null");
     
    -    auto k = new Klass("smart global value");
    +    auto k = scoped!Klass("smart global value");
         GlobalSmartValue = k;
         verifyCount(2, k);
     
    @@ -521,7 +530,7 @@ void runTest() {
       {
         Klass kglobal;
     
    -    auto k = new Klass("global value");
    +    auto k = scoped!Klass("global value");
         GlobalValue = k;
         verifyCount(1, k);
     
    @@ -539,7 +548,7 @@ void runTest() {
         auto kglobal = GlobalPointer;
         enforce(kglobal is null, "expected null");
     
    -    auto k = new Klass("global pointer");
    +    auto k = scoped!Klass("global pointer");
         GlobalPointer = k;
         verifyCount(1, k);
     
    @@ -554,7 +563,7 @@ void runTest() {
       {
         Klass kglobal;
     
    -    auto k = new Klass("global reference");
    +    auto k = scoped!Klass("global reference");
         GlobalReference = k;
         verifyCount(1, k);
     
    -- 
    cgit v1.2.1
    
    
    From 24ceed86b49665cfa4bb7051ff103038d236e64b Mon Sep 17 00:00:00 2001
    From: David Nadlinger 
    Date: Fri, 31 Oct 2014 20:24:16 +0100
    Subject: D: Work around nativepointer problem in
     test-suite/typemap_directorout.i.
    MIME-Version: 1.0
    Content-Type: text/plain; charset=UTF-8
    Content-Transfer-Encoding: 8bit
    
    Just "%typemap(ddirectorout) MyType &USEME = SWIGTYPE &;" does not
    inherit the antivepointer attribute from the SWIGTYPE & case, but
    the other typemaps that are not overridden (dout/…). Thus, some
    of the emitted code used native pointers, and some SWIGTYPE_p_int.
    ---
     Examples/test-suite/typemap_directorout.i | 2 +-
     1 file changed, 1 insertion(+), 1 deletion(-)
    
    diff --git a/Examples/test-suite/typemap_directorout.i b/Examples/test-suite/typemap_directorout.i
    index 4a85bd47c..79d0f8d94 100644
    --- a/Examples/test-suite/typemap_directorout.i
    +++ b/Examples/test-suite/typemap_directorout.i
    @@ -23,7 +23,7 @@
     #ifdef SWIGD
     %typemap(ddirectorout) MyType & %{ WILL_NOT_COMPILE %}
     %typemap(ddirectorout) MyType &USEME = SWIGTYPE &;
    -%typemap(ddirectorout) MyType &Class1::foo2, MyType &foo1 %{ /* special start */ $typemap(ddirectorout, MyType &USEME) /* special end */ %}
    +%typemap(ddirectorout, nativepointer="cast(void*)$dcall") MyType &Class1::foo2, MyType &foo1 %{ /* special start */ $typemap(ddirectorout, MyType &USEME) /* special end */ %}
     #endif
     
     #ifdef SWIGJAVA
    -- 
    cgit v1.2.1
    
    
    From 7c57ebf8888fd41319cffcb781c2763f3d4c40b6 Mon Sep 17 00:00:00 2001
    From: David Nadlinger 
    Date: Fri, 31 Oct 2014 21:45:57 +0100
    Subject: D: Use configure-detected default language version for test-suite.
    
    ---
     Examples/test-suite/d/Makefile.in | 4 ++++
     1 file changed, 4 insertions(+)
    
    diff --git a/Examples/test-suite/d/Makefile.in b/Examples/test-suite/d/Makefile.in
    index 418381e7f..3333df110 100644
    --- a/Examples/test-suite/d/Makefile.in
    +++ b/Examples/test-suite/d/Makefile.in
    @@ -8,6 +8,10 @@ srcdir       = @srcdir@
     top_srcdir   = ../@top_srcdir@
     top_builddir = ../@top_builddir@
     
    +ifeq (,$(D_VERSION))
    +  D_VERSION = @DDEFAULTVERSION@
    +endif
    +
     ifeq (2,$(D_VERSION))
       VERSIONSUFFIX = .2
     else
    -- 
    cgit v1.2.1
    
    
    From 86276568df8c036f1788c205b45d1b2e880aeaa7 Mon Sep 17 00:00:00 2001
    From: David Nadlinger 
    Date: Sat, 1 Nov 2014 01:39:42 +0100
    Subject: D: Fix out-of-source build for examples.
    
    ---
     Examples/Makefile.in           |  3 ++-
     Examples/d/callback/Makefile   | 28 +----------------------
     Examples/d/class/Makefile      | 28 +----------------------
     Examples/d/constants/Makefile  | 28 +----------------------
     Examples/d/constants/example.d | 23 -------------------
     Examples/d/enum/Makefile       | 28 +----------------------
     Examples/d/example.mk.in       | 50 ++++++++++++++++++++++++++++++++++++++++++
     Examples/d/extend/Makefile     | 28 +----------------------
     Examples/d/funcptr/Makefile    | 28 +----------------------
     Examples/d/simple/Makefile     | 28 +----------------------
     Examples/d/variables/Makefile  | 28 +----------------------
     configure.ac                   |  1 +
     12 files changed, 61 insertions(+), 240 deletions(-)
     delete mode 100644 Examples/d/constants/example.d
     create mode 100644 Examples/d/example.mk.in
    
    diff --git a/Examples/Makefile.in b/Examples/Makefile.in
    index 5162ba37f..ea4c65654 100644
    --- a/Examples/Makefile.in
    +++ b/Examples/Makefile.in
    @@ -130,6 +130,7 @@ OBJS      = $(SRCS:.c=.@OBJEXT@) $(CXXSRCS:.cxx=.@OBJEXT@)
     
     distclean:
     	rm -f Makefile
    +	rm -f d/example.mk
     	rm -f xml/Makefile
     
     ##################################################################
    @@ -1875,7 +1876,7 @@ d_compile: $(SRCDIR_SRCS)
     # -----------------------------------------------------------------
     
     d_run:
    -	$(RUNTOOL) $(D_RUNME) $(RUNPIPE)
    +	env LD_LIBRARY_PATH=$$PWD $(RUNTOOL) $(D_RUNME) $(RUNPIPE)
     
     # -----------------------------------------------------------------
     # Version display
    diff --git a/Examples/d/callback/Makefile b/Examples/d/callback/Makefile
    index 72edc17a5..ad84231e1 100644
    --- a/Examples/d/callback/Makefile
    +++ b/Examples/d/callback/Makefile
    @@ -1,27 +1 @@
    -ifeq (2,$(D_VERSION))
    -  WORKING_DIR = d2/
    -else
    -  WORKING_DIR = d1/
    -endif
    -
    -TOP           = ../../..
    -SWIG          = $(TOP)/../preinst-swig
    -EXTRA_CFLAGS  = -I../ ../example.cxx example_wrap.cxx
    -EXTRA_LDFLAGS = example.o example_wrap.o
    -TARGET        = example_wrap
    -SWIGOPT       =
    -DSRCS         = *.d
    -DFLAGS        = -ofrunme
    -
    -check: build
    -	cd $(WORKING_DIR); \
    -	$(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' d_run
    -
    -build:
    -	cd $(WORKING_DIR); \
    -	$(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' EXTRA_CFLAGS='$(EXTRA_CFLAGS)' EXTRA_LDFLAGS='$(EXTRA_LDFLAGS)' SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT) -outcurrentdir ../example.i' TARGET='$(TARGET)' d_cpp; \
    -	$(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' DSRCS='$(DSRCS)' DFLAGS='$(DFLAGS)' d_compile
    -
    -clean:
    -	cd $(WORKING_DIR); \
    -	$(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' d_clean
    +include ../example.mk
    diff --git a/Examples/d/class/Makefile b/Examples/d/class/Makefile
    index 72edc17a5..ad84231e1 100644
    --- a/Examples/d/class/Makefile
    +++ b/Examples/d/class/Makefile
    @@ -1,27 +1 @@
    -ifeq (2,$(D_VERSION))
    -  WORKING_DIR = d2/
    -else
    -  WORKING_DIR = d1/
    -endif
    -
    -TOP           = ../../..
    -SWIG          = $(TOP)/../preinst-swig
    -EXTRA_CFLAGS  = -I../ ../example.cxx example_wrap.cxx
    -EXTRA_LDFLAGS = example.o example_wrap.o
    -TARGET        = example_wrap
    -SWIGOPT       =
    -DSRCS         = *.d
    -DFLAGS        = -ofrunme
    -
    -check: build
    -	cd $(WORKING_DIR); \
    -	$(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' d_run
    -
    -build:
    -	cd $(WORKING_DIR); \
    -	$(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' EXTRA_CFLAGS='$(EXTRA_CFLAGS)' EXTRA_LDFLAGS='$(EXTRA_LDFLAGS)' SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT) -outcurrentdir ../example.i' TARGET='$(TARGET)' d_cpp; \
    -	$(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' DSRCS='$(DSRCS)' DFLAGS='$(DFLAGS)' d_compile
    -
    -clean:
    -	cd $(WORKING_DIR); \
    -	$(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' d_clean
    +include ../example.mk
    diff --git a/Examples/d/constants/Makefile b/Examples/d/constants/Makefile
    index 609c7f660..ad84231e1 100644
    --- a/Examples/d/constants/Makefile
    +++ b/Examples/d/constants/Makefile
    @@ -1,27 +1 @@
    -ifeq (2,$(D_VERSION))
    -  WORKING_DIR = d2/
    -else
    -  WORKING_DIR = d1/
    -endif
    -
    -TOP           = ../../..
    -SWIG          = $(TOP)/../preinst-swig
    -EXTRA_CFLAGS  = -I../ example_wrap.c
    -EXTRA_LDFLAGS = example_wrap.o
    -TARGET        = example_wrap
    -SWIGOPT       =
    -DSRCS         = *.d
    -DFLAGS        = -ofrunme
    -
    -check: build
    -	cd $(WORKING_DIR); \
    -	$(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' d_run
    -
    -build:
    -	cd $(WORKING_DIR); \
    -	$(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' EXTRA_CFLAGS='$(EXTRA_CFLAGS)' EXTRA_LDFLAGS='$(EXTRA_LDFLAGS)' SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT) -outcurrentdir ../example.i' TARGET='$(TARGET)' d; \
    -	$(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' DSRCS='$(DSRCS)' DFLAGS='$(DFLAGS)' d_compile
    -
    -clean:
    -	cd $(WORKING_DIR); \
    -	$(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' d_clean
    +include ../example.mk
    diff --git a/Examples/d/constants/example.d b/Examples/d/constants/example.d
    deleted file mode 100644
    index 7448d0ad9..000000000
    --- a/Examples/d/constants/example.d
    +++ /dev/null
    @@ -1,23 +0,0 @@
    -/* ----------------------------------------------------------------------------
    - * This file was automatically generated by SWIG (http://www.swig.org).
    - * Version 1.3.41
    - *
    - * Do not make changes to this file unless you know what you are doing--modify
    - * the SWIG interface file instead.
    - * ----------------------------------------------------------------------------- */
    -
    -module example;
    -
    -static import example_wrap;
    -
    -static import tango.stdc.stringz;
    -
    -public const int ICONST = 42;
    -public const double FCONST = 2.1828;
    -public const char CCONST = 'x';
    -public const char CCONST2 = '\n';
    -public const char[] SCONST = "Hello World";
    -public const char[] SCONST2 = "\"Hello World\"";
    -public const double EXPR = 42+3*(2.1828);
    -public const int iconst = 37;
    -public const double fconst = 3.14;
    diff --git a/Examples/d/enum/Makefile b/Examples/d/enum/Makefile
    index 72edc17a5..ad84231e1 100644
    --- a/Examples/d/enum/Makefile
    +++ b/Examples/d/enum/Makefile
    @@ -1,27 +1 @@
    -ifeq (2,$(D_VERSION))
    -  WORKING_DIR = d2/
    -else
    -  WORKING_DIR = d1/
    -endif
    -
    -TOP           = ../../..
    -SWIG          = $(TOP)/../preinst-swig
    -EXTRA_CFLAGS  = -I../ ../example.cxx example_wrap.cxx
    -EXTRA_LDFLAGS = example.o example_wrap.o
    -TARGET        = example_wrap
    -SWIGOPT       =
    -DSRCS         = *.d
    -DFLAGS        = -ofrunme
    -
    -check: build
    -	cd $(WORKING_DIR); \
    -	$(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' d_run
    -
    -build:
    -	cd $(WORKING_DIR); \
    -	$(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' EXTRA_CFLAGS='$(EXTRA_CFLAGS)' EXTRA_LDFLAGS='$(EXTRA_LDFLAGS)' SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT) -outcurrentdir ../example.i' TARGET='$(TARGET)' d_cpp; \
    -	$(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' DSRCS='$(DSRCS)' DFLAGS='$(DFLAGS)' d_compile
    -
    -clean:
    -	cd $(WORKING_DIR); \
    -	$(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' d_clean
    +include ../example.mk
    diff --git a/Examples/d/example.mk.in b/Examples/d/example.mk.in
    new file mode 100644
    index 000000000..7d0eb9c9d
    --- /dev/null
    +++ b/Examples/d/example.mk.in
    @@ -0,0 +1,50 @@
    +#
    +# Common Makefile code for building D examples.
    +#
    +# We actually need to configure this to gain access to the default D version to
    +# use when D_VERSION is not set. Using Examples/Makefile.in is not enough, as
    +# the location of the source files (d1/ or d2/) depends on it. The alternative
    +# would be to add the functionality specific to Examples/d (as opposed to the
    +# test suite) directly to Examples/Makefile.in.
    +#
    +# This file is supposed to be included from a Makefile in the subdirectory
    +# corresponding to a specific example.
    +#
    +
    +ifeq (,$(D_VERSION))
    +	D_VERSION = @DDEFAULTVERSION@
    +endif
    +
    +ifeq (1,$(D_VERSION))
    +	VERSION_DIR = d1/
    +else
    +	VERSION_DIR = d2/
    +endif
    +
    +EXAMPLES_TOP   = ../../..
    +SWIG_TOP       = ../../../..
    +SWIG           = $(SWIG_TOP)/preinst-swig
    +EXTRA_CFLAGS   =
    +EXTRA_CXXFLAGS =
    +EXTRA_LDFLAGS  =
    +TARGET         = example_wrap
    +SWIGOPT        = -outcurrentdir
    +DSRCS          = *.d
    +DFLAGS         = -ofrunme
    +
    +check: build
    +	$(MAKE) -C $(VERSION_DIR) -f $(EXAMPLES_TOP)/Makefile SRCDIR='../$(SRCDIR)' d_run
    +
    +build:
    +	mkdir -p $(VERSION_DIR)
    +	if [ -f ../$(SRCDIR)example.cxx ]; then
    +		$(MAKE) -C $(VERSION_DIR) -f $(EXAMPLES_TOP)/Makefile SRCDIR='../$(SRCDIR)' EXTRA_CXXFLAGS='$(EXTRA_CXXFLAGS)' EXTRA_LDFLAGS='$(EXTRA_LDFLAGS)' SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT)' TARGET='$(TARGET)' INTERFACE='example.i' CXXSRCS='example.cxx' d_cpp
    +	elif [ -f ../$(SRCDIR)example.c ]; then
    +		$(MAKE) -C $(VERSION_DIR) -f $(EXAMPLES_TOP)/Makefile SRCDIR='../$(SRCDIR)' EXTRA_CFLAGS='$(EXTRA_CFLAGS)' EXTRA_LDFLAGS='$(EXTRA_LDFLAGS)' SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT)' TARGET='$(TARGET)' INTERFACE='example.i' SRCS='example.c' d
    +	else
    +		$(MAKE) -C $(VERSION_DIR) -f $(EXAMPLES_TOP)/Makefile SRCDIR='../$(SRCDIR)' EXTRA_CFLAGS='$(EXTRA_CFLAGS)' EXTRA_LDFLAGS='$(EXTRA_LDFLAGS)' SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT)' TARGET='$(TARGET)' INTERFACE='example.i' SRCS='' d
    +	fi
    +	$(MAKE) -f $(EXAMPLES_TOP)/Makefile SRCDIR='../$(SRCDIR)' DSRCS='../$(SRCDIR)$(VERSION_DIR)runme.d $(DSRCS)' DFLAGS='$(DFLAGS)' d_compile
    +
    +clean:
    +	$(MAKE) -C $(VERSION_DIR) -f $(EXAMPLES_TOP)/Makefile SRCDIR='../$(SRCDIR)' d_clean
    diff --git a/Examples/d/extend/Makefile b/Examples/d/extend/Makefile
    index 72edc17a5..ad84231e1 100644
    --- a/Examples/d/extend/Makefile
    +++ b/Examples/d/extend/Makefile
    @@ -1,27 +1 @@
    -ifeq (2,$(D_VERSION))
    -  WORKING_DIR = d2/
    -else
    -  WORKING_DIR = d1/
    -endif
    -
    -TOP           = ../../..
    -SWIG          = $(TOP)/../preinst-swig
    -EXTRA_CFLAGS  = -I../ ../example.cxx example_wrap.cxx
    -EXTRA_LDFLAGS = example.o example_wrap.o
    -TARGET        = example_wrap
    -SWIGOPT       =
    -DSRCS         = *.d
    -DFLAGS        = -ofrunme
    -
    -check: build
    -	cd $(WORKING_DIR); \
    -	$(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' d_run
    -
    -build:
    -	cd $(WORKING_DIR); \
    -	$(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' EXTRA_CFLAGS='$(EXTRA_CFLAGS)' EXTRA_LDFLAGS='$(EXTRA_LDFLAGS)' SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT) -outcurrentdir ../example.i' TARGET='$(TARGET)' d_cpp; \
    -	$(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' DSRCS='$(DSRCS)' DFLAGS='$(DFLAGS)' d_compile
    -
    -clean:
    -	cd $(WORKING_DIR); \
    -	$(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' d_clean
    +include ../example.mk
    diff --git a/Examples/d/funcptr/Makefile b/Examples/d/funcptr/Makefile
    index 6554c3c73..ad84231e1 100644
    --- a/Examples/d/funcptr/Makefile
    +++ b/Examples/d/funcptr/Makefile
    @@ -1,27 +1 @@
    -ifeq (2,$(D_VERSION))
    -  WORKING_DIR = d2/
    -else
    -  WORKING_DIR = d1/
    -endif
    -
    -TOP           = ../../..
    -SWIG          = $(TOP)/../preinst-swig
    -EXTRA_CFLAGS  = -I../ ../example.c example_wrap.c
    -EXTRA_LDFLAGS = example.o example_wrap.o
    -TARGET        = example_wrap
    -SWIGOPT       =
    -DSRCS         = *.d
    -DFLAGS        = -ofrunme
    -
    -check: build
    -	cd $(WORKING_DIR); \
    -	$(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' d_run
    -
    -build:
    -	cd $(WORKING_DIR); \
    -	$(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' EXTRA_CFLAGS='$(EXTRA_CFLAGS)' EXTRA_LDFLAGS='$(EXTRA_LDFLAGS)' EXTRA_LDFLAGS='$(EXTRA_LDFLAGS)' SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT) -outcurrentdir ../example.i' TARGET='$(TARGET)' d; \
    -	$(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' DSRCS='$(DSRCS)' DFLAGS='$(DFLAGS)' d_compile
    -
    -clean:
    -	cd $(WORKING_DIR); \
    -	$(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' d_clean
    +include ../example.mk
    diff --git a/Examples/d/simple/Makefile b/Examples/d/simple/Makefile
    index f5eed3210..ad84231e1 100644
    --- a/Examples/d/simple/Makefile
    +++ b/Examples/d/simple/Makefile
    @@ -1,27 +1 @@
    -ifeq (2,$(D_VERSION))
    -  WORKING_DIR = d2/
    -else
    -  WORKING_DIR = d1/
    -endif
    -
    -TOP           = ../../..
    -SWIG          = $(TOP)/../preinst-swig
    -EXTRA_CFLAGS  = -I../ ../example.c example_wrap.c
    -EXTRA_LDFLAGS = example.o example_wrap.o
    -TARGET        = example_wrap
    -SWIGOPT       =
    -DSRCS         = *.d
    -DFLAGS        = -ofrunme
    -
    -check: build
    -	cd $(WORKING_DIR); \
    -	$(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' d_run
    -
    -build:
    -	cd $(WORKING_DIR); \
    -	$(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' EXTRA_CFLAGS='$(EXTRA_CFLAGS)' EXTRA_LDFLAGS='$(EXTRA_LDFLAGS)' SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT) -outcurrentdir ../example.i' TARGET='$(TARGET)' d; \
    -	$(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' DSRCS='$(DSRCS)' DFLAGS='$(DFLAGS)' d_compile
    -
    -clean:
    -	cd $(WORKING_DIR); \
    -	$(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' d_clean
    +include ../example.mk
    diff --git a/Examples/d/variables/Makefile b/Examples/d/variables/Makefile
    index f5eed3210..ad84231e1 100644
    --- a/Examples/d/variables/Makefile
    +++ b/Examples/d/variables/Makefile
    @@ -1,27 +1 @@
    -ifeq (2,$(D_VERSION))
    -  WORKING_DIR = d2/
    -else
    -  WORKING_DIR = d1/
    -endif
    -
    -TOP           = ../../..
    -SWIG          = $(TOP)/../preinst-swig
    -EXTRA_CFLAGS  = -I../ ../example.c example_wrap.c
    -EXTRA_LDFLAGS = example.o example_wrap.o
    -TARGET        = example_wrap
    -SWIGOPT       =
    -DSRCS         = *.d
    -DFLAGS        = -ofrunme
    -
    -check: build
    -	cd $(WORKING_DIR); \
    -	$(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' d_run
    -
    -build:
    -	cd $(WORKING_DIR); \
    -	$(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' EXTRA_CFLAGS='$(EXTRA_CFLAGS)' EXTRA_LDFLAGS='$(EXTRA_LDFLAGS)' SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT) -outcurrentdir ../example.i' TARGET='$(TARGET)' d; \
    -	$(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' DSRCS='$(DSRCS)' DFLAGS='$(DFLAGS)' d_compile
    -
    -clean:
    -	cd $(WORKING_DIR); \
    -	$(MAKE) -f $(TOP)/Makefile SRCDIR='$(SRCDIR)' d_clean
    +include ../example.mk
    diff --git a/configure.ac b/configure.ac
    index 22d66d1ef..b05933527 100644
    --- a/configure.ac
    +++ b/configure.ac
    @@ -2675,6 +2675,7 @@ AC_CONFIG_FILES([
         Makefile
         swig.spec
         Examples/Makefile
    +    Examples/d/example.mk
         Examples/xml/Makefile
         Examples/test-suite/errors/Makefile
         Examples/test-suite/chicken/Makefile
    -- 
    cgit v1.2.1
    
    
    From a034d151b7cda9f7a5c3252499e3a9c8332ff30c Mon Sep 17 00:00:00 2001
    From: David Nadlinger 
    Date: Sat, 1 Nov 2014 03:45:01 +0100
    Subject: Add D to Travis CI.
    
    ---
     .travis.yml | 5 +++++
     1 file changed, 5 insertions(+)
    
    diff --git a/.travis.yml b/.travis.yml
    index 1c1614979..65008f623 100644
    --- a/.travis.yml
    +++ b/.travis.yml
    @@ -8,6 +8,8 @@ matrix:
       include:
         - compiler: gcc
           env: SWIGLANG=csharp
    +    - compiler: gcc
    +      env: SWIGLANG=d
         - compiler: gcc
           env: SWIGLANG=go
         - compiler: gcc
    @@ -62,6 +64,7 @@ before_install:
       - time sudo apt-get -qq install libboost-dev
       - if test -z "$SWIGLANG"; then sudo apt-get -qq install yodl; fi
       - if test "$SWIGLANG" = "csharp"; then sudo apt-get -qq install mono-devel; fi
    +  - if test "$SWIGLANG" = "d"; then wget http://downloads.dlang.org/releases/2014/dmd_2.066.0-0_amd64.deb; sudo dpkg -i dmd_2.066.0-0_amd64.deb; fi
       - if test "$SWIGLANG" = "go"; then go env | sed -e 's/^/export /' > goenvsetup && source goenvsetup && rm -f goenvsetup; fi # Until configure.ac is fixed
       - if test "$SWIGLANG" = "javascript" -a "$ENGINE" = "node"; then sudo apt-get install -qq rlwrap python-software-properties && echo 'yes' | sudo add-apt-repository ppa:chris-lea/node.js && sudo apt-get -qq update && sudo apt-get install -qq nodejs && sudo npm install -g node-gyp; fi
       - if test "$SWIGLANG" = "javascript" -a "$ENGINE" = "jsc"; then sudo apt-get install -qq libwebkitgtk-dev; fi
    @@ -78,6 +81,7 @@ before_install:
       # Stricter compile flags for examples. Various headers and SWIG generated code prevents full use of -pedantic.
       - declare -A CFLAGS_EXAMPLES && CFLAGS_EXAMPLES=(
             ["csharp"]="-Werror -std=gnu89 -fdiagnostics-show-option -Wno-long-long -Wreturn-type"
    +             ["d"]="-Werror -std=gnu89 -fdiagnostics-show-option -Wno-long-long -Wreturn-type"
                 ["go"]="-Werror -std=gnu89 -fdiagnostics-show-option -Wno-long-long -Wreturn-type"
              ["guile"]="-Werror -std=gnu89 -fdiagnostics-show-option -Wno-long-long -Wreturn-type"
               ["java"]="-Werror -std=gnu89 -fdiagnostics-show-option -pedantic -Wno-long-long -Wreturn-type"
    @@ -92,6 +96,7 @@ before_install:
         )
       - declare -A CXXFLAGS_EXAMPLES && CXXFLAGS_EXAMPLES=(
             ["csharp"]="-Werror -std=c++98 -fdiagnostics-show-option -pedantic -Wno-long-long -Wreturn-type"
    +             ["d"]="-Werror -std=c++98 -fdiagnostics-show-option -pedantic -Wno-long-long -Wreturn-type"
                 ["go"]="-Werror -std=c++98 -fdiagnostics-show-option -pedantic -Wno-long-long -Wreturn-type"
              ["guile"]="-Werror -std=c++98 -fdiagnostics-show-option -Wno-long-long -Wreturn-type"
               ["java"]="-Werror -std=c++98 -fdiagnostics-show-option -pedantic -Wno-long-long -Wreturn-type"
    -- 
    cgit v1.2.1
    
    
    From 278308cfd32601eea3f68134449a168dac4a87f3 Mon Sep 17 00:00:00 2001
    From: David Nadlinger 
    Date: Sat, 1 Nov 2014 17:39:42 +0100
    Subject: D: Fix exception handling support.
    
    The original code was ported from the C# module. It looks like it
    tried to avoid reading TLS data by using a shared counter. However,
    without also synchronizing on the counter check (or using atomics)
    the code is racy. While the races might be benign (the thread that
    sets the exception also increments the counter, so when there is
    actually an exception, the visible value will always be non-zero
    even if it is outdated), they are still undefined behavior,
    strictly speaking. Additionally, just using TLS isn't expensive
    either.
    ---
     Lib/d/dhead.swg | 76 +++++++++++----------------------------------------------
     1 file changed, 14 insertions(+), 62 deletions(-)
    
    diff --git a/Lib/d/dhead.swg b/Lib/d/dhead.swg
    index 9f950c60f..786ca6e66 100644
    --- a/Lib/d/dhead.swg
    +++ b/Lib/d/dhead.swg
    @@ -93,31 +93,26 @@ private class SwigExceptionHelper {
     
       static void setException(char* message) {
         auto exception = new object.Exception(tango.stdc.stringz.fromStringz(message).dup);
    -    exception.next = SwigPendingException.retrieve();
         SwigPendingException.set(exception);
       }
     
       static void setIllegalArgumentException(char* message) {
         auto exception = new tango.core.Exception.IllegalArgumentException(tango.stdc.stringz.fromStringz(message).dup);
    -    exception.next = SwigPendingException.retrieve();
         SwigPendingException.set(exception);
       }
     
       static void setIllegalElementException(char* message) {
         auto exception = new tango.core.Exception.IllegalElementException(tango.stdc.stringz.fromStringz(message).dup);
    -    exception.next = SwigPendingException.retrieve();
         SwigPendingException.set(exception);
       }
     
       static void setIOException(char* message) {
         auto exception = new tango.core.Exception.IOException(tango.stdc.stringz.fromStringz(message).dup);
    -    exception.next = SwigPendingException.retrieve();
         SwigPendingException.set(exception);
       }
     
       static void setNoSuchElementException(char* message) {
         auto exception = new tango.core.Exception.NoSuchElementException(tango.stdc.stringz.fromStringz(message).dup);
    -    exception.next = SwigPendingException.retrieve();
         SwigPendingException.set(exception);
       }
     }
    @@ -125,51 +120,31 @@ private class SwigExceptionHelper {
     package class SwigPendingException {
     public:
       static this() {
    -    m_sPendingCount = 0;
         m_sPendingException = new ThreadLocalData(null);
       }
     
       static bool isPending() {
    -    bool pending = false;
    -    if (m_sPendingCount > 0) {
    -      if (m_sPendingException.val !is null) {
    -        pending = true;
    -      }
    -    }
    -    return pending;
    +    return m_sPendingException.val !is null;
       }
     
       static void set(object.Exception e) {
    -    if (m_sPendingException.val !is null) {
    -      throw new object.Exception("FATAL: An earlier pending exception from C/C++ code " ~
    -        "was missed and thus not thrown (" ~ m_sPendingException.val.classinfo.name ~
    -        ": " ~ m_sPendingException.val.msg ~ ")!", e);
    +    auto pending = m_sPendingException.val;
    +    if (pending !is null) {
    +      e.next = pending;
    +      throw new object.Exception("FATAL: An earlier pending exception from C/C++ " ~
    +        "code was missed and thus not thrown (" ~ pending.classinfo.name ~ ": " ~
    +        pending.msg ~ ")!", e);
         }
    -
         m_sPendingException.val = e;
    -    synchronized {
    -      ++m_sPendingCount;
    -    }
       }
     
       static object.Exception retrieve() {
    -    object.Exception e = null;
    -    if (m_sPendingCount > 0) {
    -      if (m_sPendingException.val !is null) {
    -        e = m_sPendingException.val;
    -        m_sPendingException.val = null;
    -        synchronized {
    -          --m_sPendingCount;
    -        }
    -      }
    -    }
    +    auto e = m_sPendingException.val;
    +    m_sPendingException.val = null;
         return e;
       }
     
     private:
    -  // The pending exception counter is stored thread-global.
    -  static int m_sPendingCount;
    -
       // The reference to the pending exception (if any) is stored thread-local.
       alias tango.core.Thread.ThreadLocal!(object.Exception) ThreadLocalData;
       static ThreadLocalData m_sPendingException;
    @@ -195,8 +170,7 @@ private class SwigExceptionHelper {
       }
     
       static void setException(const char* message) {
    -    auto exception = new object.Exception(std.conv.to!string(message).idup);
    -    exception.next = SwigPendingException.retrieve();
    +    auto exception = new object.Exception(std.conv.to!string(message));
         SwigPendingException.set(exception);
       }
     }
    @@ -204,53 +178,31 @@ private class SwigExceptionHelper {
     package struct SwigPendingException {
     public:
       static this() {
    -    m_sPendingCount = 0;
         m_sPendingException = null;
       }
     
       static bool isPending() {
    -    bool pending = false;
    -    if (m_sPendingCount > 0) {
    -      if (m_sPendingException !is null) {
    -        pending = true;
    -      }
    -    }
    -    return pending;
    +    return m_sPendingException !is null;
       }
     
       static void set(object.Exception e) {
         if (m_sPendingException !is null) {
    +      e.next = m_sPendingException;
           throw new object.Exception("FATAL: An earlier pending exception from C/C++ code " ~
             "was missed and thus not thrown (" ~ m_sPendingException.classinfo.name ~
             ": " ~ m_sPendingException.msg ~ ")!", e);
         }
     
         m_sPendingException = e;
    -    synchronized {
    -      import core.atomic;
    -      core.atomic.atomicOp!"+="(m_sPendingCount, 1);
    -    }
       }
     
       static object.Exception retrieve() {
    -    object.Exception e = null;
    -    if (m_sPendingCount > 0) {
    -      if (m_sPendingException !is null) {
    -        e = m_sPendingException;
    -        m_sPendingException = null;
    -        synchronized {
    -          import core.atomic;
    -          core.atomic.atomicOp!"-="(m_sPendingCount, 1);
    -        }
    -      }
    -    }
    +    auto e = m_sPendingException;
    +    m_sPendingException = null;
         return e;
       }
     
     private:
    -  // The pending exception counter is stored thread-global.
    -  static shared int m_sPendingCount;
    -
       // The reference to the pending exception (if any) is stored thread-local.
       static object.Exception m_sPendingException;
     }
    -- 
    cgit v1.2.1
    
    
    From fe3d137ce9ad30e546fa481333b37a2daa6e7532 Mon Sep 17 00:00:00 2001
    From: David Nadlinger 
    Date: Thu, 6 Nov 2014 23:12:00 +0100
    Subject: D: Fixup example makefile.
    
    This fixes 8627656. I accidentally merged an old version to master,
    sorry for the intermittent breakage.
    ---
     Examples/d/example.mk.in | 12 ++++++------
     1 file changed, 6 insertions(+), 6 deletions(-)
    
    diff --git a/Examples/d/example.mk.in b/Examples/d/example.mk.in
    index 7d0eb9c9d..ff335240d 100644
    --- a/Examples/d/example.mk.in
    +++ b/Examples/d/example.mk.in
    @@ -37,12 +37,12 @@ check: build
     
     build:
     	mkdir -p $(VERSION_DIR)
    -	if [ -f ../$(SRCDIR)example.cxx ]; then
    -		$(MAKE) -C $(VERSION_DIR) -f $(EXAMPLES_TOP)/Makefile SRCDIR='../$(SRCDIR)' EXTRA_CXXFLAGS='$(EXTRA_CXXFLAGS)' EXTRA_LDFLAGS='$(EXTRA_LDFLAGS)' SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT)' TARGET='$(TARGET)' INTERFACE='example.i' CXXSRCS='example.cxx' d_cpp
    -	elif [ -f ../$(SRCDIR)example.c ]; then
    -		$(MAKE) -C $(VERSION_DIR) -f $(EXAMPLES_TOP)/Makefile SRCDIR='../$(SRCDIR)' EXTRA_CFLAGS='$(EXTRA_CFLAGS)' EXTRA_LDFLAGS='$(EXTRA_LDFLAGS)' SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT)' TARGET='$(TARGET)' INTERFACE='example.i' SRCS='example.c' d
    -	else
    -		$(MAKE) -C $(VERSION_DIR) -f $(EXAMPLES_TOP)/Makefile SRCDIR='../$(SRCDIR)' EXTRA_CFLAGS='$(EXTRA_CFLAGS)' EXTRA_LDFLAGS='$(EXTRA_LDFLAGS)' SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT)' TARGET='$(TARGET)' INTERFACE='example.i' SRCS='' d
    +	if [ -f ../$(SRCDIR)example.cxx ]; then \
    +		$(MAKE) -C $(VERSION_DIR) -f $(EXAMPLES_TOP)/Makefile SRCDIR='../$(SRCDIR)' EXTRA_CXXFLAGS='$(EXTRA_CXXFLAGS)' EXTRA_LDFLAGS='$(EXTRA_LDFLAGS)' SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT)' TARGET='$(TARGET)' INTERFACE='example.i' CXXSRCS='example.cxx' d_cpp \
    +	elif [ -f ../$(SRCDIR)example.c ]; then \
    +		$(MAKE) -C $(VERSION_DIR) -f $(EXAMPLES_TOP)/Makefile SRCDIR='../$(SRCDIR)' EXTRA_CFLAGS='$(EXTRA_CFLAGS)' EXTRA_LDFLAGS='$(EXTRA_LDFLAGS)' SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT)' TARGET='$(TARGET)' INTERFACE='example.i' SRCS='example.c' d \
    +	else \
    +		$(MAKE) -C $(VERSION_DIR) -f $(EXAMPLES_TOP)/Makefile SRCDIR='../$(SRCDIR)' EXTRA_CFLAGS='$(EXTRA_CFLAGS)' EXTRA_LDFLAGS='$(EXTRA_LDFLAGS)' SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT)' TARGET='$(TARGET)' INTERFACE='example.i' SRCS='' d \
     	fi
     	$(MAKE) -f $(EXAMPLES_TOP)/Makefile SRCDIR='../$(SRCDIR)' DSRCS='../$(SRCDIR)$(VERSION_DIR)runme.d $(DSRCS)' DFLAGS='$(DFLAGS)' d_compile
     
    -- 
    cgit v1.2.1
    
    
    From 0e5e043870681d6234414abfe3dc236cbd343055 Mon Sep 17 00:00:00 2001
    From: David Nadlinger 
    Date: Fri, 7 Nov 2014 00:23:02 +0100
    Subject: D: Fix up the emergency CI build fix (fe3d137ce).
    
    Turns out the issue that led me to push a broken commit in
    the first place also caused the build to succeed when I
    tested the fix in a rush. I should've just used the GitHub
    merge button. Sorry for the noise, hopefully won't happen again.
    ---
     Examples/d/example.mk.in | 12 ++++++------
     1 file changed, 6 insertions(+), 6 deletions(-)
    
    diff --git a/Examples/d/example.mk.in b/Examples/d/example.mk.in
    index ff335240d..33e1a801e 100644
    --- a/Examples/d/example.mk.in
    +++ b/Examples/d/example.mk.in
    @@ -37,14 +37,14 @@ check: build
     
     build:
     	mkdir -p $(VERSION_DIR)
    -	if [ -f ../$(SRCDIR)example.cxx ]; then \
    -		$(MAKE) -C $(VERSION_DIR) -f $(EXAMPLES_TOP)/Makefile SRCDIR='../$(SRCDIR)' EXTRA_CXXFLAGS='$(EXTRA_CXXFLAGS)' EXTRA_LDFLAGS='$(EXTRA_LDFLAGS)' SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT)' TARGET='$(TARGET)' INTERFACE='example.i' CXXSRCS='example.cxx' d_cpp \
    -	elif [ -f ../$(SRCDIR)example.c ]; then \
    -		$(MAKE) -C $(VERSION_DIR) -f $(EXAMPLES_TOP)/Makefile SRCDIR='../$(SRCDIR)' EXTRA_CFLAGS='$(EXTRA_CFLAGS)' EXTRA_LDFLAGS='$(EXTRA_LDFLAGS)' SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT)' TARGET='$(TARGET)' INTERFACE='example.i' SRCS='example.c' d \
    +	if [ -f $(SRCDIR)example.cxx ]; then \
    +		$(MAKE) -C $(VERSION_DIR) -f $(EXAMPLES_TOP)/Makefile SRCDIR='../$(SRCDIR)' EXTRA_CXXFLAGS='$(EXTRA_CXXFLAGS)' EXTRA_LDFLAGS='$(EXTRA_LDFLAGS)' SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT)' TARGET='$(TARGET)' INTERFACE='example.i' CXXSRCS='example.cxx' d_cpp; \
    +	elif [ -f $(SRCDIR)example.c ]; then \
    +		$(MAKE) -C $(VERSION_DIR) -f $(EXAMPLES_TOP)/Makefile SRCDIR='../$(SRCDIR)' EXTRA_CFLAGS='$(EXTRA_CFLAGS)' EXTRA_LDFLAGS='$(EXTRA_LDFLAGS)' SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT)' TARGET='$(TARGET)' INTERFACE='example.i' SRCS='example.c' d; \
     	else \
    -		$(MAKE) -C $(VERSION_DIR) -f $(EXAMPLES_TOP)/Makefile SRCDIR='../$(SRCDIR)' EXTRA_CFLAGS='$(EXTRA_CFLAGS)' EXTRA_LDFLAGS='$(EXTRA_LDFLAGS)' SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT)' TARGET='$(TARGET)' INTERFACE='example.i' SRCS='' d \
    +		$(MAKE) -C $(VERSION_DIR) -f $(EXAMPLES_TOP)/Makefile SRCDIR='../$(SRCDIR)' EXTRA_CFLAGS='$(EXTRA_CFLAGS)' EXTRA_LDFLAGS='$(EXTRA_LDFLAGS)' SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT)' TARGET='$(TARGET)' INTERFACE='example.i' SRCS='' d; \
     	fi
    -	$(MAKE) -f $(EXAMPLES_TOP)/Makefile SRCDIR='../$(SRCDIR)' DSRCS='../$(SRCDIR)$(VERSION_DIR)runme.d $(DSRCS)' DFLAGS='$(DFLAGS)' d_compile
    +	$(MAKE) -C $(VERSION_DIR) -f $(EXAMPLES_TOP)/Makefile SRCDIR='../$(SRCDIR)' DSRCS='../$(SRCDIR)$(VERSION_DIR)runme.d $(DSRCS)' DFLAGS='$(DFLAGS)' d_compile
     
     clean:
     	$(MAKE) -C $(VERSION_DIR) -f $(EXAMPLES_TOP)/Makefile SRCDIR='../$(SRCDIR)' d_clean
    -- 
    cgit v1.2.1
    
    
    From e047d2e2bded6712a4583e4fe067f7574be56fac Mon Sep 17 00:00:00 2001
    From: Olly Betts 
    Date: Wed, 5 Nov 2014 10:17:22 +1300
    Subject: Remove bogus ; after } in documentation
    
    ---
     CHANGES                    | 18 +++++++++---------
     Doc/Manual/Javascript.html | 12 ++++++------
     Doc/Manual/SWIGPlus.html   |  2 +-
     Source/CParse/cscanner.c   |  2 +-
     4 files changed, 17 insertions(+), 17 deletions(-)
    
    diff --git a/CHANGES b/CHANGES
    index b7b9856e2..33b2b5942 100644
    --- a/CHANGES
    +++ b/CHANGES
    @@ -2898,8 +2898,8 @@ Version 2.0.0 (2 June 2010)
                 and in template parameter specializations:
     
                   struct S {};
    -              template  struct X { void a() {}; };
    -              template <> struct X { void b() {}; };
    +              template  struct X { void a() {} };
    +              template <> struct X { void b() {} };
                   %template(MyTConcrete) X< ::S >;
     
                 plus probably some other corner case usage of ::.
    @@ -20234,13 +20234,13 @@ Version 1.3.6  (July 9, 2001)
     	   class TestClass
     	   {
     	   public:
    -	     TestClass() {};
    -	     TestClass(int a) {};
    -	     ~TestClass() {};
    -	     unsigned long xyz(short k) {};
    -	     unsigned long xyz(int n) {};
    -	     static void static_func() {};
    -	     static void static_func(int a) {};
    +	     TestClass() {}
    +	     TestClass(int a) {}
    +	     ~TestClass() {}
    +	     unsigned long xyz(short k) {}
    +	     unsigned long xyz(int n) {}
    +	     static void static_func() {}
    +	     static void static_func(int a) {}
     	   };
     	   void delete_TestClass(int a);
     
    diff --git a/Doc/Manual/Javascript.html b/Doc/Manual/Javascript.html
    index 4a0cd46a8..cae199048 100644
    --- a/Doc/Manual/Javascript.html
    +++ b/Doc/Manual/Javascript.html
    @@ -478,7 +478,7 @@ public:
       }
       virtual ~Shape() {
         nshapes--;
    -  };
    +  }
       double  x, y;
       void    move(double dx, double dy);
       virtual double area(void) = 0;
    @@ -490,7 +490,7 @@ class Circle : public Shape {
     private:
       double radius;
     public:
    -  Circle(double r) : radius(r) { };
    +  Circle(double r) : radius(r) { }
       virtual double area(void);
       virtual double perimeter(void);
     };
    @@ -499,7 +499,7 @@ class Square : public Shape {
     private:
       double width;
     public:
    -  Square(double w) : width(w) { };
    +  Square(double w) : width(w) { }
       virtual double area(void);
       virtual double perimeter(void);
     };
    @@ -776,7 +776,7 @@ class JSEmitter { */ virtual int exitClass(Node *) { return SWIG_OK; - }; + } /** * Invoked at the beginning of the variableHandler. @@ -788,7 +788,7 @@ class JSEmitter { */ virtual int exitVariable(Node *) { return SWIG_OK; - }; + } /** * Invoked at the beginning of the functionHandler. @@ -800,7 +800,7 @@ class JSEmitter { */ virtual int exitFunction(Node *) { return SWIG_OK; - }; + } /** * Invoked by functionWrapper callback after call to Language::functionWrapper. diff --git a/Doc/Manual/SWIGPlus.html b/Doc/Manual/SWIGPlus.html index 72917f1e0..d0deff03f 100644 --- a/Doc/Manual/SWIGPlus.html +++ b/Doc/Manual/SWIGPlus.html @@ -3567,7 +3567,7 @@ It is also possible to separate these declarations from the template class. For template<class T> class List { ... public: - List() { }; + List() { } T get(int index); ... }; diff --git a/Source/CParse/cscanner.c b/Source/CParse/cscanner.c index de00e2b1f..d9a17b874 100644 --- a/Source/CParse/cscanner.c +++ b/Source/CParse/cscanner.c @@ -147,7 +147,7 @@ String *get_raw_text_balanced(int startchar, int endchar) { * friend ostream& operator<<(ostream&, const char *s); * * or - * friend ostream& operator<<(ostream&, const char *s) { }; + * friend ostream& operator<<(ostream&, const char *s) { } * * ------------------------------------------------------------------------- */ -- cgit v1.2.1 From 37cd1474b563d413c3ae7df254d9d22b9c6086b8 Mon Sep 17 00:00:00 2001 From: Olly Betts Date: Wed, 5 Nov 2014 10:42:12 +1300 Subject: Remove bogus ; after } in examples --- Examples/contract/simple_cxx/example.h | 6 +++--- Examples/csharp/reference/example.h | 4 ++-- Examples/go/reference/example.h | 4 ++-- Examples/java/reference/example.h | 4 ++-- Examples/javascript/reference/example.h | 4 ++-- Examples/lua/import/base.h | 4 ++-- Examples/lua/owner/example.h | 6 +++--- Examples/modula3/reference/example.h | 4 ++-- Examples/octave/reference/example.h | 4 ++-- Examples/perl5/import/base.h | 4 ++-- Examples/perl5/reference/example.h | 4 ++-- Examples/php/disown/example.h | 10 +++++----- Examples/php/proxy/example.h | 8 ++++---- Examples/php/reference/example.h | 4 ++-- Examples/python/import/base.h | 4 ++-- Examples/python/import_template/base.h | 4 ++-- Examples/python/reference/example.h | 4 ++-- Examples/python/smartptr/example.h | 4 ++-- 18 files changed, 43 insertions(+), 43 deletions(-) diff --git a/Examples/contract/simple_cxx/example.h b/Examples/contract/simple_cxx/example.h index 64b7684fa..de708bb7b 100644 --- a/Examples/contract/simple_cxx/example.h +++ b/Examples/contract/simple_cxx/example.h @@ -7,7 +7,7 @@ public: } virtual ~Shape() { nshapes--; - }; + } double x, y; void move(double dx, double dy); virtual double area(void) = 0; @@ -19,7 +19,7 @@ class Circle : public Shape { private: double radius; public: - Circle(double r) : radius(r) { }; + Circle(double r) : radius(r) { } virtual double area(void); virtual double perimeter(void); }; @@ -28,7 +28,7 @@ class Square : public Shape { private: double width; public: - Square(double w) : width(w) { }; + Square(double w) : width(w) { } virtual double area(void); virtual double perimeter(void); }; diff --git a/Examples/csharp/reference/example.h b/Examples/csharp/reference/example.h index 4915adb1b..c4820f19a 100644 --- a/Examples/csharp/reference/example.h +++ b/Examples/csharp/reference/example.h @@ -4,8 +4,8 @@ class Vector { private: double x,y,z; public: - Vector() : x(0), y(0), z(0) { }; - Vector(double x, double y, double z) : x(x), y(y), z(z) { }; + Vector() : x(0), y(0), z(0) { } + Vector(double x, double y, double z) : x(x), y(y), z(z) { } friend Vector operator+(const Vector &a, const Vector &b); char *print(); }; diff --git a/Examples/go/reference/example.h b/Examples/go/reference/example.h index 4915adb1b..c4820f19a 100644 --- a/Examples/go/reference/example.h +++ b/Examples/go/reference/example.h @@ -4,8 +4,8 @@ class Vector { private: double x,y,z; public: - Vector() : x(0), y(0), z(0) { }; - Vector(double x, double y, double z) : x(x), y(y), z(z) { }; + Vector() : x(0), y(0), z(0) { } + Vector(double x, double y, double z) : x(x), y(y), z(z) { } friend Vector operator+(const Vector &a, const Vector &b); char *print(); }; diff --git a/Examples/java/reference/example.h b/Examples/java/reference/example.h index 4915adb1b..c4820f19a 100644 --- a/Examples/java/reference/example.h +++ b/Examples/java/reference/example.h @@ -4,8 +4,8 @@ class Vector { private: double x,y,z; public: - Vector() : x(0), y(0), z(0) { }; - Vector(double x, double y, double z) : x(x), y(y), z(z) { }; + Vector() : x(0), y(0), z(0) { } + Vector(double x, double y, double z) : x(x), y(y), z(z) { } friend Vector operator+(const Vector &a, const Vector &b); char *print(); }; diff --git a/Examples/javascript/reference/example.h b/Examples/javascript/reference/example.h index 4915adb1b..c4820f19a 100644 --- a/Examples/javascript/reference/example.h +++ b/Examples/javascript/reference/example.h @@ -4,8 +4,8 @@ class Vector { private: double x,y,z; public: - Vector() : x(0), y(0), z(0) { }; - Vector(double x, double y, double z) : x(x), y(y), z(z) { }; + Vector() : x(0), y(0), z(0) { } + Vector(double x, double y, double z) : x(x), y(y), z(z) { } friend Vector operator+(const Vector &a, const Vector &b); char *print(); }; diff --git a/Examples/lua/import/base.h b/Examples/lua/import/base.h index fec0f329c..ff6fecdd3 100644 --- a/Examples/lua/import/base.h +++ b/Examples/lua/import/base.h @@ -1,7 +1,7 @@ class Base { public: - Base() { }; - virtual ~Base() { }; + Base() { } + virtual ~Base() { } virtual const char * A() const { return "Base::A"; } diff --git a/Examples/lua/owner/example.h b/Examples/lua/owner/example.h index 320bb2569..9101c6330 100644 --- a/Examples/lua/owner/example.h +++ b/Examples/lua/owner/example.h @@ -8,7 +8,7 @@ public: } virtual ~Shape() { nshapes--; - }; + } double x, y; void move(double dx, double dy); virtual double area(void) = 0; @@ -20,7 +20,7 @@ class Circle : public Shape { private: double radius; public: - Circle(double r) : radius(r) { }; + Circle(double r) : radius(r) { } virtual double area(void); virtual double perimeter(void); }; @@ -29,7 +29,7 @@ class Square : public Shape { private: double width; public: - Square(double w) : width(w) { }; + Square(double w) : width(w) { } virtual double area(void); virtual double perimeter(void); }; diff --git a/Examples/modula3/reference/example.h b/Examples/modula3/reference/example.h index 0a9cd447f..7b4ba8fb8 100644 --- a/Examples/modula3/reference/example.h +++ b/Examples/modula3/reference/example.h @@ -4,8 +4,8 @@ struct Vector { private: double x,y,z; public: - Vector() : x(0), y(0), z(0) { }; - Vector(double x, double y, double z) : x(x), y(y), z(z) { }; + Vector() : x(0), y(0), z(0) { } + Vector(double x, double y, double z) : x(x), y(y), z(z) { } Vector operator+(const Vector &b) const; char *print(); }; diff --git a/Examples/octave/reference/example.h b/Examples/octave/reference/example.h index 697afafe0..bcfcfb72f 100644 --- a/Examples/octave/reference/example.h +++ b/Examples/octave/reference/example.h @@ -4,8 +4,8 @@ class Vector { private: double x,y,z; public: - Vector() : x(0), y(0), z(0) { }; - Vector(double x, double y, double z) : x(x), y(y), z(z) { }; + Vector() : x(0), y(0), z(0) { } + Vector(double x, double y, double z) : x(x), y(y), z(z) { } friend Vector operator+(const Vector &a, const Vector &b); char *print(); }; diff --git a/Examples/perl5/import/base.h b/Examples/perl5/import/base.h index 5a266f68c..c0b47956b 100644 --- a/Examples/perl5/import/base.h +++ b/Examples/perl5/import/base.h @@ -2,8 +2,8 @@ class Base { public: - Base() { }; - virtual ~Base() { }; + Base() { } + virtual ~Base() { } virtual void A() { printf("I'm Base::A\n"); } diff --git a/Examples/perl5/reference/example.h b/Examples/perl5/reference/example.h index 4915adb1b..c4820f19a 100644 --- a/Examples/perl5/reference/example.h +++ b/Examples/perl5/reference/example.h @@ -4,8 +4,8 @@ class Vector { private: double x,y,z; public: - Vector() : x(0), y(0), z(0) { }; - Vector(double x, double y, double z) : x(x), y(y), z(z) { }; + Vector() : x(0), y(0), z(0) { } + Vector(double x, double y, double z) : x(x), y(y), z(z) { } friend Vector operator+(const Vector &a, const Vector &b); char *print(); }; diff --git a/Examples/php/disown/example.h b/Examples/php/disown/example.h index 985bc333d..e9f96743f 100644 --- a/Examples/php/disown/example.h +++ b/Examples/php/disown/example.h @@ -9,7 +9,7 @@ public: } virtual ~Shape() { nshapes--; - }; + } double x, y; void move(double dx, double dy); virtual double area(void) = 0; @@ -22,8 +22,8 @@ class Circle : public Shape { private: double radius; public: - Circle(double r) : radius(r) { }; - ~Circle() { }; + Circle(double r) : radius(r) { } + ~Circle() { } void set_radius( double r ); virtual double area(void); virtual double perimeter(void); @@ -33,7 +33,7 @@ class Square : public Shape { private: double width; public: - Square(double w) : width(w) { }; + Square(double w) : width(w) { } ~Square() { } virtual double area(void); virtual double perimeter(void); @@ -44,7 +44,7 @@ private: typedef std::vector::iterator iterator; std::vector shapes; public: - ShapeContainer() : shapes() {}; + ShapeContainer() : shapes() {} ~ShapeContainer(); void addShape( Shape *s ); }; diff --git a/Examples/php/proxy/example.h b/Examples/php/proxy/example.h index 361dff898..0683f07f3 100644 --- a/Examples/php/proxy/example.h +++ b/Examples/php/proxy/example.h @@ -9,7 +9,7 @@ public: } virtual ~Shape() { nshapes--; - }; + } double x, y; void move(double dx, double dy); virtual double area(void) = 0; @@ -22,8 +22,8 @@ class Circle : public Shape { private: double radius; public: - Circle(double r) : radius(r) { }; - ~Circle() { }; + Circle(double r) : radius(r) { } + ~Circle() { } void set_radius( double r ); virtual double area(void); virtual double perimeter(void); @@ -33,7 +33,7 @@ class Square : public Shape { private: double width; public: - Square(double w) : width(w) { }; + Square(double w) : width(w) { } ~Square() { } virtual double area(void); virtual double perimeter(void); diff --git a/Examples/php/reference/example.h b/Examples/php/reference/example.h index 1b88cbf5c..d9daee89c 100644 --- a/Examples/php/reference/example.h +++ b/Examples/php/reference/example.h @@ -4,8 +4,8 @@ class Vector { private: double x,y,z; public: - Vector() : x(0), y(0), z(0) { }; - Vector(double x, double y, double z) : x(x), y(y), z(z) { }; + Vector() : x(0), y(0), z(0) { } + Vector(double x, double y, double z) : x(x), y(y), z(z) { } friend Vector operator+(const Vector &a, const Vector &b); char *as_string(); }; diff --git a/Examples/python/import/base.h b/Examples/python/import/base.h index 5a266f68c..c0b47956b 100644 --- a/Examples/python/import/base.h +++ b/Examples/python/import/base.h @@ -2,8 +2,8 @@ class Base { public: - Base() { }; - virtual ~Base() { }; + Base() { } + virtual ~Base() { } virtual void A() { printf("I'm Base::A\n"); } diff --git a/Examples/python/import_template/base.h b/Examples/python/import_template/base.h index c755a6f9d..8faafb3d7 100644 --- a/Examples/python/import_template/base.h +++ b/Examples/python/import_template/base.h @@ -2,8 +2,8 @@ template class Base { public: - Base() { }; - virtual ~Base() { }; + Base() { } + virtual ~Base() { } virtual void A() { printf("I'm Base::A\n"); } diff --git a/Examples/python/reference/example.h b/Examples/python/reference/example.h index 4915adb1b..c4820f19a 100644 --- a/Examples/python/reference/example.h +++ b/Examples/python/reference/example.h @@ -4,8 +4,8 @@ class Vector { private: double x,y,z; public: - Vector() : x(0), y(0), z(0) { }; - Vector(double x, double y, double z) : x(x), y(y), z(z) { }; + Vector() : x(0), y(0), z(0) { } + Vector(double x, double y, double z) : x(x), y(y), z(z) { } friend Vector operator+(const Vector &a, const Vector &b); char *print(); }; diff --git a/Examples/python/smartptr/example.h b/Examples/python/smartptr/example.h index c0f9b1d57..c18e7eaf4 100644 --- a/Examples/python/smartptr/example.h +++ b/Examples/python/smartptr/example.h @@ -7,7 +7,7 @@ public: } virtual ~Shape() { nshapes--; - }; + } double x, y; void move(double dx, double dy); virtual double area() = 0; @@ -19,7 +19,7 @@ class Circle : public Shape { private: double radius; public: - Circle(double r) : radius(r) { }; + Circle(double r) : radius(r) { } virtual double area(); virtual double perimeter(); }; -- cgit v1.2.1 From ac1f067ce983e40591461f768df8914b01b5505d Mon Sep 17 00:00:00 2001 From: Olly Betts Date: Wed, 5 Nov 2014 10:43:42 +1300 Subject: Eliminate trivial differences between the reference examples --- Examples/csharp/reference/example.h | 4 ---- Examples/csharp/reference/example.i | 6 +----- Examples/go/reference/example.h | 4 ---- Examples/go/reference/example.i | 2 +- Examples/java/reference/example.h | 4 ---- Examples/java/reference/example.i | 6 +----- Examples/javascript/reference/example.h | 4 ---- Examples/javascript/reference/example.i | 2 +- Examples/perl5/reference/example.h | 4 ---- Examples/perl5/reference/example.i | 6 +----- Examples/php/reference/example.h | 4 ---- Examples/php/reference/example.i | 10 +++------- Examples/python/reference/example.h | 4 ---- Examples/python/reference/example.i | 6 +----- Examples/ruby/reference/example.h | 8 ++------ Examples/ruby/reference/example.i | 6 +----- Examples/tcl/reference/example.h | 8 ++------ Examples/tcl/reference/example.i | 6 +----- 18 files changed, 15 insertions(+), 79 deletions(-) diff --git a/Examples/csharp/reference/example.h b/Examples/csharp/reference/example.h index c4820f19a..bcfcfb72f 100644 --- a/Examples/csharp/reference/example.h +++ b/Examples/csharp/reference/example.h @@ -20,7 +20,3 @@ public: Vector &operator[](int); int size(); }; - - - - diff --git a/Examples/csharp/reference/example.i b/Examples/csharp/reference/example.i index 6daa3b1f4..173143d79 100644 --- a/Examples/csharp/reference/example.i +++ b/Examples/csharp/reference/example.i @@ -29,7 +29,7 @@ public: VectorArray(int maxsize); ~VectorArray(); int size(); - + /* This wrapper provides an alternative to the [] operator */ %extend { Vector &get(int index) { @@ -40,7 +40,3 @@ public: } } }; - - - - diff --git a/Examples/go/reference/example.h b/Examples/go/reference/example.h index c4820f19a..bcfcfb72f 100644 --- a/Examples/go/reference/example.h +++ b/Examples/go/reference/example.h @@ -20,7 +20,3 @@ public: Vector &operator[](int); int size(); }; - - - - diff --git a/Examples/go/reference/example.i b/Examples/go/reference/example.i index 1cf19c82c..173143d79 100644 --- a/Examples/go/reference/example.i +++ b/Examples/go/reference/example.i @@ -29,7 +29,7 @@ public: VectorArray(int maxsize); ~VectorArray(); int size(); - + /* This wrapper provides an alternative to the [] operator */ %extend { Vector &get(int index) { diff --git a/Examples/java/reference/example.h b/Examples/java/reference/example.h index c4820f19a..bcfcfb72f 100644 --- a/Examples/java/reference/example.h +++ b/Examples/java/reference/example.h @@ -20,7 +20,3 @@ public: Vector &operator[](int); int size(); }; - - - - diff --git a/Examples/java/reference/example.i b/Examples/java/reference/example.i index 6daa3b1f4..173143d79 100644 --- a/Examples/java/reference/example.i +++ b/Examples/java/reference/example.i @@ -29,7 +29,7 @@ public: VectorArray(int maxsize); ~VectorArray(); int size(); - + /* This wrapper provides an alternative to the [] operator */ %extend { Vector &get(int index) { @@ -40,7 +40,3 @@ public: } } }; - - - - diff --git a/Examples/javascript/reference/example.h b/Examples/javascript/reference/example.h index c4820f19a..bcfcfb72f 100644 --- a/Examples/javascript/reference/example.h +++ b/Examples/javascript/reference/example.h @@ -20,7 +20,3 @@ public: Vector &operator[](int); int size(); }; - - - - diff --git a/Examples/javascript/reference/example.i b/Examples/javascript/reference/example.i index 1cf19c82c..173143d79 100644 --- a/Examples/javascript/reference/example.i +++ b/Examples/javascript/reference/example.i @@ -29,7 +29,7 @@ public: VectorArray(int maxsize); ~VectorArray(); int size(); - + /* This wrapper provides an alternative to the [] operator */ %extend { Vector &get(int index) { diff --git a/Examples/perl5/reference/example.h b/Examples/perl5/reference/example.h index c4820f19a..bcfcfb72f 100644 --- a/Examples/perl5/reference/example.h +++ b/Examples/perl5/reference/example.h @@ -20,7 +20,3 @@ public: Vector &operator[](int); int size(); }; - - - - diff --git a/Examples/perl5/reference/example.i b/Examples/perl5/reference/example.i index 6daa3b1f4..173143d79 100644 --- a/Examples/perl5/reference/example.i +++ b/Examples/perl5/reference/example.i @@ -29,7 +29,7 @@ public: VectorArray(int maxsize); ~VectorArray(); int size(); - + /* This wrapper provides an alternative to the [] operator */ %extend { Vector &get(int index) { @@ -40,7 +40,3 @@ public: } } }; - - - - diff --git a/Examples/php/reference/example.h b/Examples/php/reference/example.h index d9daee89c..353b88835 100644 --- a/Examples/php/reference/example.h +++ b/Examples/php/reference/example.h @@ -20,7 +20,3 @@ public: Vector &operator[](int); int size(); }; - - - - diff --git a/Examples/php/reference/example.i b/Examples/php/reference/example.i index a372439b1..df1459921 100644 --- a/Examples/php/reference/example.i +++ b/Examples/php/reference/example.i @@ -1,10 +1,6 @@ /* File : example.i */ -/* This example has nothing to do with references but the name is used by all - * the other languages so it's hard to rename to something more meaningful. - * - * Mostly it shows how to use %extend. - */ +/* This file has a few "typical" uses of C++ references. */ %module example @@ -33,8 +29,8 @@ public: VectorArray(int maxsize); ~VectorArray(); int size(); - - /* This wrapper provides an alternative to the [] operator */ + + /* This wrapper provides an alternative to the [] operator */ %extend { Vector &get(int index) { printf("VectorArray extended get: %p %d\n", (void *)$self, index); diff --git a/Examples/python/reference/example.h b/Examples/python/reference/example.h index c4820f19a..bcfcfb72f 100644 --- a/Examples/python/reference/example.h +++ b/Examples/python/reference/example.h @@ -20,7 +20,3 @@ public: Vector &operator[](int); int size(); }; - - - - diff --git a/Examples/python/reference/example.i b/Examples/python/reference/example.i index 8c95b3213..8af8397ec 100644 --- a/Examples/python/reference/example.i +++ b/Examples/python/reference/example.i @@ -31,7 +31,7 @@ public: VectorArray(int maxsize); ~VectorArray(); int size(); - + /* This wrapper provides an alternative to the [] operator */ %extend { Vector &get(int index) { @@ -42,7 +42,3 @@ public: } } }; - - - - diff --git a/Examples/ruby/reference/example.h b/Examples/ruby/reference/example.h index 4915adb1b..bcfcfb72f 100644 --- a/Examples/ruby/reference/example.h +++ b/Examples/ruby/reference/example.h @@ -4,8 +4,8 @@ class Vector { private: double x,y,z; public: - Vector() : x(0), y(0), z(0) { }; - Vector(double x, double y, double z) : x(x), y(y), z(z) { }; + Vector() : x(0), y(0), z(0) { } + Vector(double x, double y, double z) : x(x), y(y), z(z) { } friend Vector operator+(const Vector &a, const Vector &b); char *print(); }; @@ -20,7 +20,3 @@ public: Vector &operator[](int); int size(); }; - - - - diff --git a/Examples/ruby/reference/example.i b/Examples/ruby/reference/example.i index 6daa3b1f4..173143d79 100644 --- a/Examples/ruby/reference/example.i +++ b/Examples/ruby/reference/example.i @@ -29,7 +29,7 @@ public: VectorArray(int maxsize); ~VectorArray(); int size(); - + /* This wrapper provides an alternative to the [] operator */ %extend { Vector &get(int index) { @@ -40,7 +40,3 @@ public: } } }; - - - - diff --git a/Examples/tcl/reference/example.h b/Examples/tcl/reference/example.h index 4915adb1b..bcfcfb72f 100644 --- a/Examples/tcl/reference/example.h +++ b/Examples/tcl/reference/example.h @@ -4,8 +4,8 @@ class Vector { private: double x,y,z; public: - Vector() : x(0), y(0), z(0) { }; - Vector(double x, double y, double z) : x(x), y(y), z(z) { }; + Vector() : x(0), y(0), z(0) { } + Vector(double x, double y, double z) : x(x), y(y), z(z) { } friend Vector operator+(const Vector &a, const Vector &b); char *print(); }; @@ -20,7 +20,3 @@ public: Vector &operator[](int); int size(); }; - - - - diff --git a/Examples/tcl/reference/example.i b/Examples/tcl/reference/example.i index 6daa3b1f4..173143d79 100644 --- a/Examples/tcl/reference/example.i +++ b/Examples/tcl/reference/example.i @@ -29,7 +29,7 @@ public: VectorArray(int maxsize); ~VectorArray(); int size(); - + /* This wrapper provides an alternative to the [] operator */ %extend { Vector &get(int index) { @@ -40,7 +40,3 @@ public: } } }; - - - - -- cgit v1.2.1 From bca042a7dd3e0c3727f4dc201d2964aa3b160763 Mon Sep 17 00:00:00 2001 From: William S Fulton Date: Fri, 7 Nov 2014 19:45:20 +0000 Subject: Add director_nested_class testcase Java nested director class test for fix in e7db081d5e175024f1d5baa9ac028474958a2542 --- Examples/test-suite/director_nested_class.i | 16 ++++++++++++ .../java/director_nested_class_runme.java | 30 ++++++++++++++++++++++ 2 files changed, 46 insertions(+) create mode 100644 Examples/test-suite/director_nested_class.i create mode 100644 Examples/test-suite/java/director_nested_class_runme.java diff --git a/Examples/test-suite/director_nested_class.i b/Examples/test-suite/director_nested_class.i new file mode 100644 index 000000000..99eecfcc8 --- /dev/null +++ b/Examples/test-suite/director_nested_class.i @@ -0,0 +1,16 @@ +%module(directors="1") director_nested_class + + +%feature("director") DirectorOuter::DirectorInner; + +%inline %{ +struct DirectorOuter { + struct DirectorInner { + virtual ~DirectorInner() {} + virtual int vmethod(int input) const = 0; + }; + static int callMethod(const DirectorInner &di, int value) { + return di.vmethod(value); + } +}; +%} diff --git a/Examples/test-suite/java/director_nested_class_runme.java b/Examples/test-suite/java/director_nested_class_runme.java new file mode 100644 index 000000000..5d330fb46 --- /dev/null +++ b/Examples/test-suite/java/director_nested_class_runme.java @@ -0,0 +1,30 @@ + +import director_nested_class.*; + +public class director_nested_class_runme { + + static { + try { + System.loadLibrary("director_nested_class"); + } 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[]) { + + director_nested_class_Derived d = new director_nested_class_Derived(); + + if (DirectorOuter.callMethod(d, 999) != 9990) { + throw new RuntimeException("callMethod(999) failed"); + } + } +} + +class director_nested_class_Derived extends DirectorOuter.DirectorInner { + public int vmethod(int input) { + return input * 10; + } +} + -- cgit v1.2.1 From 220acc3fc8bd703fbec64f3964637202194def76 Mon Sep 17 00:00:00 2001 From: William S Fulton Date: Sat, 8 Nov 2014 10:53:49 +0000 Subject: Fixes for clang -fsanitize=undefined-trap -fsanitize-undefined-trap-on-error Fixes 'Illegal instruction' when SWIG executes and compiled with above compiler options Fixes #263 --- Source/DOH/string.c | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/Source/DOH/string.c b/Source/DOH/string.c index 3e02e05d1..cfc6c70f6 100644 --- a/Source/DOH/string.c +++ b/Source/DOH/string.c @@ -181,10 +181,10 @@ static int String_hash(DOH *so) { return s->hashkey; } else { register char *c = s->str; - register int len = s->len > 50 ? 50 : s->len; - register int h = 0; - register int mlen = len >> 2; - register int i = mlen; + register unsigned int len = s->len > 50 ? 50 : s->len; + register unsigned int h = 0; + register unsigned int mlen = len >> 2; + register unsigned int i = mlen; for (; i; --i) { h = (h << 5) + *(c++); h = (h << 5) + *(c++); @@ -195,7 +195,7 @@ static int String_hash(DOH *so) { h = (h << 5) + *(c++); } h &= 0x7fffffff; - s->hashkey = h; + s->hashkey = (int)h; return h; } } -- cgit v1.2.1 From 396f286a029d365563b1bad75a09f0c22fd30ccb Mon Sep 17 00:00:00 2001 From: Natanael Arndt Date: Sun, 9 Nov 2014 23:16:38 +0100 Subject: Fix #224 Fix the PHP section of the documentation to include both source files resp. object files in the example command lines --- Doc/Manual/Php.html | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/Doc/Manual/Php.html b/Doc/Manual/Php.html index 684774d51..48ce17420 100644 --- a/Doc/Manual/Php.html +++ b/Doc/Manual/Php.html @@ -136,8 +136,8 @@ least work for Linux though):

    -	gcc `php-config --includes` -fpic -c example_wrap.c
    -	gcc -shared example_wrap.o -o example.so
    +	gcc `php-config --includes` -fpic -c example_wrap.c example.c
    +	gcc -shared example_wrap.o example.o -o example.so
     
    -- cgit v1.2.1 From 92d3146a0621d8da071eb8e07ac0e283f3f265b0 Mon Sep 17 00:00:00 2001 From: William S Fulton Date: Fri, 7 Nov 2014 20:38:09 +0000 Subject: Expand director_nested_class test to test more than one level of nesting --- Examples/test-suite/director_nested_class.i | 9 +++++++++ Examples/test-suite/java/director_nested_class_runme.java | 11 +++++++++++ 2 files changed, 20 insertions(+) diff --git a/Examples/test-suite/director_nested_class.i b/Examples/test-suite/director_nested_class.i index 99eecfcc8..f3d627f3c 100644 --- a/Examples/test-suite/director_nested_class.i +++ b/Examples/test-suite/director_nested_class.i @@ -2,15 +2,24 @@ %feature("director") DirectorOuter::DirectorInner; +%feature("director") DirectorOuter::DirectorInner::DirectorInnerInner; %inline %{ struct DirectorOuter { struct DirectorInner { virtual ~DirectorInner() {} virtual int vmethod(int input) const = 0; + struct DirectorInnerInner { + DirectorInnerInner(DirectorInner *din = 0) {} + virtual ~DirectorInnerInner() {} + virtual int innervmethod(int input) const = 0; + }; }; static int callMethod(const DirectorInner &di, int value) { return di.vmethod(value); } + static int callInnerInnerMethod(const DirectorInner::DirectorInnerInner &di, int value) { + return di.innervmethod(value); + } }; %} diff --git a/Examples/test-suite/java/director_nested_class_runme.java b/Examples/test-suite/java/director_nested_class_runme.java index 5d330fb46..5144413b7 100644 --- a/Examples/test-suite/java/director_nested_class_runme.java +++ b/Examples/test-suite/java/director_nested_class_runme.java @@ -19,6 +19,12 @@ public class director_nested_class_runme { if (DirectorOuter.callMethod(d, 999) != 9990) { throw new RuntimeException("callMethod(999) failed"); } + + director_nested_class_DerivedInnerInner dinner = new director_nested_class_DerivedInnerInner(); + + if (DirectorOuter.callInnerInnerMethod(dinner, 999) != 999000) { + throw new RuntimeException("callMethod(999) failed"); + } } } @@ -28,3 +34,8 @@ class director_nested_class_Derived extends DirectorOuter.DirectorInner { } } +class director_nested_class_DerivedInnerInner extends DirectorOuter.DirectorInner.DirectorInnerInner { + public int innervmethod(int input) { + return input * 1000; + } +} -- cgit v1.2.1 From 3b3de5d477ea1bb28304d2cf08edf8ce0baabe17 Mon Sep 17 00:00:00 2001 From: Anthony Li Date: Tue, 11 Nov 2014 12:18:13 +0800 Subject: revert unrelated file --- Examples/python/import_packages/relativeimport2/runme3.py | 9 +++++++++ 1 file changed, 9 insertions(+) create mode 100644 Examples/python/import_packages/relativeimport2/runme3.py diff --git a/Examples/python/import_packages/relativeimport2/runme3.py b/Examples/python/import_packages/relativeimport2/runme3.py new file mode 100644 index 000000000..4b0d112cf --- /dev/null +++ b/Examples/python/import_packages/relativeimport2/runme3.py @@ -0,0 +1,9 @@ +# Test import of modules content from within __init__.py +print("Testing %module(package=...) + python 'import' in __init__.py") +import sys +if sys.version_info < (3, 0): + import py2.pkg2.bar + print(" Finished importing py2.pkg2.bar") +else: + import py3.pkg2.bar + print(" Finished importing py3.pkg2.bar") -- cgit v1.2.1 From 3fc574e7d6b172eadc6acc11e25c4a7f21b542c1 Mon Sep 17 00:00:00 2001 From: Ian Lance Taylor Date: Mon, 17 Nov 2014 08:59:04 -0800 Subject: Go: Document memory management of C++ classes allocated in Go. Fixes #266. --- Doc/Manual/Contents.html | 1 + Doc/Manual/Go.html | 36 +++++++++++++++++++++++++++++++++++- 2 files changed, 36 insertions(+), 1 deletion(-) diff --git a/Doc/Manual/Contents.html b/Doc/Manual/Contents.html index 0d97e2803..74cf27394 100644 --- a/Doc/Manual/Contents.html +++ b/Doc/Manual/Contents.html @@ -854,6 +854,7 @@
  • Go Enumerations
  • Go Classes
  • Go Templates diff --git a/Doc/Manual/Go.html b/Doc/Manual/Go.html index 5ce76e8cd..03b48d40c 100644 --- a/Doc/Manual/Go.html +++ b/Doc/Manual/Go.html @@ -23,6 +23,7 @@
  • Go Enumerations
  • Go Classes
  • Go Templates @@ -375,7 +376,40 @@ returns a go interface. If the returned pointer can be null, you can check for this by calling the Swigcptr() method.

    -

    23.3.5.1 Go Class Inheritance

    +

    23.3.5.1 Go Class Memory Management

    + + +

    +Calling NewClassName for some C++ class ClassName +will allocate memory using the C++ memory allocator. This memory will +not be automatically freed by Go's garbage collector. When you are +done with the C++ object you must free it using DeleteClassName. +

    + +

    +A common technique is to store the C++ object into a Go object, and +use the Go function runtime.SetFinalizer to free the C++ +object when the Go object is freed. For example, if the SWIG package +is imported as "wrap": +

    +
    +
    +type GoClassName struct {
    +	w wrap.ClassName
    +}
    +
    +func NewGoClassName() *GoClassName {
    +	r := &GoClassName{wrap.NewClassName()}
    +	runtime.SetFinalizer(r,
    +		func(r *GoClassName) {
    +			wrap.DeleteClassName(r.w)
    +		})
    +	return r
    +}
    +
    +
    + +

    23.3.5.2 Go Class Inheritance

    -- cgit v1.2.1 From 859d65b300405c8f6d3c048d74f2ba57c57c449a Mon Sep 17 00:00:00 2001 From: Olly Betts Date: Tue, 18 Nov 2014 12:38:03 +1300 Subject: wording tweak --- Doc/Manual/Customization.html | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Doc/Manual/Customization.html b/Doc/Manual/Customization.html index ca0cec130..33b6c58f3 100644 --- a/Doc/Manual/Customization.html +++ b/Doc/Manual/Customization.html @@ -547,7 +547,7 @@ Below shows the expansions for the 1st of the overloaded something wrap The exception.i library file provides support for creating language independent exceptions in your interfaces. To use it, simply put an "%include exception.i" in your interface file. This -creates a function SWIG_exception() that can be used to raise +provides a function SWIG_exception() that can be used to raise common scripting language exceptions in a portable manner. For example :

    -- 
    cgit v1.2.1
    
    
    From f541e604e8722550826d6dcac2d97adf49309061 Mon Sep 17 00:00:00 2001
    From: Olly Betts 
    Date: Tue, 18 Nov 2014 12:44:37 +1300
    Subject: Consistently put whitespace outside of ... and not inside
    
    ---
     Doc/Manual/Customization.html |  2 +-
     Doc/Manual/Java.html          | 10 +++++-----
     Doc/Manual/Python.html        |  8 ++++----
     Doc/Manual/Ruby.html          | 14 +++++++-------
     Doc/Manual/SWIG.html          |  4 ++--
     Doc/Manual/SWIGPlus.html      |  6 +++---
     Doc/Manual/Tcl.html           |  4 ++--
     Doc/Manual/Typemaps.html      |  2 +-
     8 files changed, 25 insertions(+), 25 deletions(-)
    
    diff --git a/Doc/Manual/Customization.html b/Doc/Manual/Customization.html
    index 33b6c58f3..8e26a7e8a 100644
    --- a/Doc/Manual/Customization.html
    +++ b/Doc/Manual/Customization.html
    @@ -547,7 +547,7 @@ Below shows the expansions for the 1st of the overloaded something wrap
     The exception.i library file provides support for creating
     language independent exceptions in your interfaces.  To use it, simply
     put an "%include exception.i" in your interface file.  This
    -provides a function SWIG_exception() that can be used to raise
    +provides a function SWIG_exception() that can be used to raise
     common scripting language exceptions in a portable manner.  For example :

    diff --git a/Doc/Manual/Java.html b/Doc/Manual/Java.html
    index 5e87e835e..3a4f7ee5d 100644
    --- a/Doc/Manual/Java.html
    +++ b/Doc/Manual/Java.html
    @@ -358,7 +358,7 @@ more aggressive from gcc-4.0 onwards and will result in code that fails with str
     

    The name of the shared library output file is important. If the name of your SWIG module is "example", the name of the corresponding shared library file should be "libexample.so" (or equivalent depending on your machine, see Dynamic linking problems for more information). -The name of the module is specified using the %module directive or -module command line option.

    +The name of the module is specified using the %module directive or -module command line option.

    25.2.5 Using your module

    @@ -2441,7 +2441,7 @@ It also contains all the methods in the C++ class it is proxying plus getters an member variables. These functions call the native methods in the intermediary JNI class. The advantage of having this extra layer is the type safety that the proxy class functions offer. It adds static type checking which leads to fewer surprises at runtime. -For example, you can see that if you attempt to use the spam() +For example, you can see that if you attempt to use the spam() function it will only compile when the parameters passed are an int and a Foo. From a user's point of view, it makes the class work as if it were a Java class:

    @@ -4173,8 +4173,8 @@ void *malloc(size_t nbytes);

    If no declaration name is given to %exception, it is applied to all wrapper functions. -The $action is a SWIG special variable and is replaced by the C/C++ function call being wrapped. -The return $null; handles all native method return types, namely those that have a void return and those that do not. +The $action is a SWIG special variable and is replaced by the C/C++ function call being wrapped. +The return $null; handles all native method return types, namely those that have a void return and those that do not. This is useful for typemaps that will be used in native method returning all return types. See the section on Java special variables for further explanation. @@ -5579,7 +5579,7 @@ This special variable is usually used for making calls to a function in the inte

    -$null
    +$null
    Used in input typemaps to return early from JNI functions that have either void or a non-void return type. Example:

    diff --git a/Doc/Manual/Python.html b/Doc/Manual/Python.html index 8b4f42a43..234117464 100644 --- a/Doc/Manual/Python.html +++ b/Doc/Manual/Python.html @@ -194,7 +194,7 @@ int fact(int n);

    -The #define SWIG_FILE_WITH_INIT line inserts a macro that specifies that the +The #define SWIG_FILE_WITH_INIT line inserts a macro that specifies that the resulting C file should be built as a python extension, inserting the module init code. This .i file wraps the following simple C file:

    @@ -395,7 +395,7 @@ of the module prefixed by an underscore. If the name of your module is "_example.so" or "_examplemodule.so". The name of the module is specified using the %module directive or the - -module command line option. +-module command line option.

    @@ -783,8 +783,8 @@ Building a SWIG extension to Python under Windows is roughly similar to the process used with Unix. Using the distutils, it is essentially identical. If you have the same version of the MS compiler that Python was built with (the python2.4 and python2.5 distributed by python.org -are built with Visual Studio 2003), the standard python setup.py -build should just work. +are built with Visual Studio 2003), the standard python setup.py +build should just work.

    diff --git a/Doc/Manual/Ruby.html b/Doc/Manual/Ruby.html index cdebfe07b..c4e0074f3 100644 --- a/Doc/Manual/Ruby.html +++ b/Doc/Manual/Ruby.html @@ -685,7 +685,7 @@ For example, this struct declaration:

    gets wrapped as a Vector class, with -Ruby instance methods x, x=, +Ruby instance methods x, x=, y and y=. These methods can be used to access structure data from Ruby as follows:

    @@ -1313,7 +1313,7 @@ chapter.

    Some containers in the STL allow you to modify their default behavior by using so called functors or function objects. -Functors are often just a very simple struct with operator() +Functors are often just a very simple struct with operator() redefined or an actual C/C++ function. This allows you, for example, to always keep the sort order of a STL container to your liking.

    @@ -1327,7 +1327,7 @@ this includes std::set, std::multiset and std::multimap.

    -

    The functors in swig are called swig::UnaryFunction +

    The functors in swig are called swig::UnaryFunction and swig::BinaryFunction. For C++ predicates (ie. functors that must return bool as a result) swig::UnaryPredicate @@ -1380,8 +1380,8 @@ values they point at, while the non-const iterators can both read and modify the values.

    The Ruby STL wrappings support both type of iterators by using -a proxy class in-between. This proxy class is swig::Iterator or -swig::ConstIterator. Derived from them are template +a proxy class in-between. This proxy class is swig::Iterator or +swig::ConstIterator. Derived from them are template classes that need to be initialized with the actual iterator for the container you are wrapping and often times with the beginning and ending points of the iteration range.

    @@ -1450,7 +1450,7 @@ i
  • 34.1.2 Using PHP Extensions

    -

    If you'd rather have STL classes without any iterators, you should define -DSWIG_NO_EXPORT_ITERATOR_METHODS when running swig.

    +

    If you'd rather have STL classes without any iterators, you should define -DSWIG_NO_EXPORT_ITERATOR_METHODS when running swig.

    38.3.16 C++ Smart Pointers

    @@ -4997,7 +4997,7 @@ object from its underlying C++ object.

    In general, you will only need to use the SWIG_RubyInstanceFor, which is required for implementing mark functions as shown below. However, if you implement your own free functions (see below) you may -also have to call the SWIG_RubyRemoveTracking and RubyUnlinkObjects +also have to call the SWIG_RubyRemoveTracking and RubyUnlinkObjects methods.

    38.10.4 Mark Functions

    diff --git a/Doc/Manual/SWIG.html b/Doc/Manual/SWIG.html index e7178a621..e70280a08 100644 --- a/Doc/Manual/SWIG.html +++ b/Doc/Manual/SWIG.html @@ -1046,7 +1046,7 @@ def filecopy(source,target):

    -In this case f1, f2, and buffer are all +In this case f1, f2, and buffer are all opaque objects containing C pointers. It doesn't matter what value they contain--our program works just fine without this knowledge.

    @@ -1711,7 +1711,7 @@ wrapping a header file like this:

    -%rename applies a renaming operation to all future +%rename applies a renaming operation to all future occurrences of a name. The renaming applies to functions, variables, class and structure names, member functions, and member data. For example, if you had two-dozen C++ classes, all with a member function diff --git a/Doc/Manual/SWIGPlus.html b/Doc/Manual/SWIGPlus.html index d0deff03f..62c0e8d1e 100644 --- a/Doc/Manual/SWIGPlus.html +++ b/Doc/Manual/SWIGPlus.html @@ -1205,7 +1205,7 @@ SWIG is unable to support kwargs when wrapping overloaded methods, so the defaul

    SWIG wraps class members that are public following the C++ conventions, i.e., by explicit public declaration or by the use of - the using directive. In general, anything specified in a + the using directive. In general, anything specified in a private or protected section will be ignored, although the internal code generator sometimes looks at the contents of the private and protected sections so that it can properly generate code for default @@ -2800,7 +2800,7 @@ public:

    -This code adds a __str__ method to our class for producing a +This code adds a __str__ method to our class for producing a string representation of the object. In Python, such a method would allow us to print the value of an object using the print command. @@ -2854,7 +2854,7 @@ The Speci

    -The %extend directive follows all of the same conventions +The %extend directive follows all of the same conventions as its use with C structures. Please refer to the Adding member functions to C structures section for further details.

    diff --git a/Doc/Manual/Tcl.html b/Doc/Manual/Tcl.html index 8fc917070..45218f303 100644 --- a/Doc/Manual/Tcl.html +++ b/Doc/Manual/Tcl.html @@ -160,7 +160,7 @@ of the module. If the name of your SWIG module is "example", the name of the corresponding object file should be "example.so". The name of the module is specified using the %module directive or the - -module command line option. + -module command line option.

    39.1.3 Static linking

    @@ -504,7 +504,7 @@ name, but you can override it using the -prefix option.

    -When the -namespace option is used, objects in the module +When the -namespace option is used, objects in the module are always accessed with the namespace name such as Foo::bar.

    diff --git a/Doc/Manual/Typemaps.html b/Doc/Manual/Typemaps.html index cba524149..5cb6b0bbf 100644 --- a/Doc/Manual/Typemaps.html +++ b/Doc/Manual/Typemaps.html @@ -3360,7 +3360,7 @@ list of strings like this:

    -To do this, you not only need to map a list of strings to char *argv[], but the +To do this, you not only need to map a list of strings to char *argv[], but the value of int argc is implicitly determined by the length of the list. Using only simple typemaps, this type of conversion is possible, but extremely painful. Multi-argument typemaps help in this situation. -- cgit v1.2.1 From 1cfc099d9184ab1f8c6d5af956ee440bfc38579d Mon Sep 17 00:00:00 2001 From: Olly Betts Date: Tue, 18 Nov 2014 12:51:08 +1300 Subject: Fix typo --- Doc/Manual/Php.html | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Doc/Manual/Php.html b/Doc/Manual/Php.html index 48ce17420..e07fc77b3 100644 --- a/Doc/Manual/Php.html +++ b/Doc/Manual/Php.html @@ -143,7 +143,7 @@ least work for Linux though):

    34.1.2 Using PHP Extensions

    -To test the extension from a PHP script, you first need to load tell PHP to +To test the extension from a PHP script, you first need to tell PHP to load it. To do this, add a line like this to the [PHP] section of php.ini:

    -- cgit v1.2.1 From 01faf1baf92f3dc9c6c26b61c3e6db4f9d4e7784 Mon Sep 17 00:00:00 2001 From: Olly Betts Date: Tue, 18 Nov 2014 12:51:30 +1300 Subject: using an unknown constant emits a notice, not a warning --- Doc/Manual/Php.html | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/Doc/Manual/Php.html b/Doc/Manual/Php.html index e07fc77b3..6f11b4aa1 100644 --- a/Doc/Manual/Php.html +++ b/Doc/Manual/Php.html @@ -235,9 +235,9 @@ echo "E = " . E . "\n";

    There's one peculiarity of how constants work in PHP which it is useful to note (this is not specific to SWIG though) - if you try to use an undeclared -constant, PHP will issue a warning and then expand the constant to a string -version of the constant's name. The warning will often be missed though as -if you're using PHP in a webserver, it will probably end up in error.log or +constant, PHP will emit a notice and then expand the constant to a string +version of the constant's name. Unfortunately it is easy to miss the notice +if you're using PHP in a webserver, as it will probably end up in error.log or similar.

    -- cgit v1.2.1 From 089865ba57e7303d702231792f9226bc80cb0c39 Mon Sep 17 00:00:00 2001 From: William S Fulton Date: Mon, 10 Nov 2014 19:57:07 +0000 Subject: Rewrite some Java director nested class support code for strongly typed enums --- Source/Modules/java.cxx | 39 ++++----------------------------------- 1 file changed, 4 insertions(+), 35 deletions(-) diff --git a/Source/Modules/java.cxx b/Source/Modules/java.cxx index e8c76854f..bbf63c6dd 100644 --- a/Source/Modules/java.cxx +++ b/Source/Modules/java.cxx @@ -3704,7 +3704,6 @@ public: * --------------------------------------------------------------- */ int classDirectorMethod(Node *n, Node *parent, String *super) { - String *classname = Getattr(parent, "sym:name"); String *c_classname = Getattr(parent, "name"); String *name = Getattr(n, "name"); String *symname = Getattr(n, "sym:name"); @@ -3738,24 +3737,7 @@ public: String *imcall_args = NewString(""); int classmeth_off = curr_class_dmethod - first_class_dmethod; bool ignored_method = GetFlag(n, "feature:ignore") ? true : false; - String *nspace = getNSpace(); - - String *outerClassesPrefix = 0; - if (Node *outer = Getattr(parent, "nested:outer")) { - outerClassesPrefix = Copy(Getattr(outer, "sym:name")); - for (outer = Getattr(outer, "nested:outer"); outer != 0; outer = Getattr(outer, "nested:outer")) { - Push(outerClassesPrefix, "."); - Push(outerClassesPrefix, Getattr(outer, "sym:name")); - } - } - String* qualified_classname = outerClassesPrefix ? NewStringf("%s.%s", outerClassesPrefix, classname) : NewStringf("%s", classname); - /* Printf(stdout, "Director qualified_classname '%s' instead of '%s'\n", qualified_classname, classname); */ - - if (nspace && package) - Insert(qualified_classname, 0, NewStringf("%s.%s.", package, nspace)); - else if(nspace) - Insert(qualified_classname, 0, NewStringf("%s.", nspace)); - + String *qualified_classname = getProxyName(getClassName()); // Kludge Alert: functionWrapper sets sym:overload properly, but it // isn't at this point, so we have to manufacture it ourselves. At least @@ -3878,7 +3860,6 @@ public: } Delete(adjustedreturntypeparm); - Delete(qualified_classname); Swig_director_parms_fixup(l); @@ -4519,29 +4500,17 @@ public: * ------------------------------------------------------------ */ int classDirectorEnd(Node *n) { - String *classname = Copy(Getattr(n, "sym:name")); + String *full_classname = Getattr(n, "name"); + String *classname = getProxyName(full_classname, true); String *director_classname = directorClassName(n); String *internal_classname; Wrapper *w = NewWrapper(); - // Form full classname including outer classes - if (classname && !GetFlag(n, "feature:flatnested")) { - for (Node *outer_class = Getattr(n, "nested:outer"); outer_class; outer_class = Getattr(outer_class, "nested:outer")) { - Push(classname, "$"); - Push(classname, Getattr(outer_class, "sym:name")); - } - } - - if (Len(package_path) > 0 && Len(getNSpace()) > 0) - internal_classname = NewStringf("%s/%s/%s", package_path, getNSpace(), classname); - else if (Len(package_path) > 0) + if (Len(package_path) > 0) internal_classname = NewStringf("%s/%s", package_path, classname); - else if (Len(getNSpace()) > 0) - internal_classname = NewStringf("%s/%s", getNSpace(), classname); else internal_classname = NewStringf("%s", classname); - Delete(classname); // If the namespace is multiple levels, the result of getNSpace() will have inserted // .'s to delimit namespaces, so we need to replace those with /'s -- cgit v1.2.1 From 77b338151ef25b9ce1ffd88bbab931379ddea3b3 Mon Sep 17 00:00:00 2001 From: William S Fulton Date: Tue, 18 Nov 2014 20:04:01 +0000 Subject: Simplify/improve strongly typed enum implementation for Java --- Source/Modules/java.cxx | 43 +++++----------------- Source/Modules/lang.cxx | 95 ++++++++++++++++++------------------------------ Source/Modules/swigmod.h | 3 ++ 3 files changed, 49 insertions(+), 92 deletions(-) diff --git a/Source/Modules/java.cxx b/Source/Modules/java.cxx index bbf63c6dd..682f5b61b 100644 --- a/Source/Modules/java.cxx +++ b/Source/Modules/java.cxx @@ -2959,17 +2959,14 @@ public: // Use the C syntax to make a true Java constant and hope that it compiles as Java code value = Getattr(n, "enumvalue") ? Copy(Getattr(n, "enumvalue")) : Copy(Getattr(n, "enumvalueex")); } else { - // If enum is strongly-typed, generate fully-qualified symname - Node* parent = parentNode(n); - String* pureSymname = NULL; - if (GetFlag(parent, "scopedenum") && !GetFlag(n, "symname_has_enumscope")) { - pureSymname = symname; - - String* enumClassName = Swig_scopename_last(Getattr(parent, "name")); - symname = Swig_name_member(0, enumClassName, pureSymname); - Delete(enumClassName); - - /* Printf(stdout, "Renamed strong enum value symname (java:2) '%s' -> '%s'\n", pureSymname, symname); */ + String *newsymname = 0; + if (!getCurrentClass() || !proxy_flag) { + String *enumClassPrefix = getEnumClassPrefix(); + if (enumClassPrefix) { + // A global scoped enum + newsymname = Swig_name_member(0, enumClassPrefix, symname); + symname = newsymname; + } } // Get the enumvalue from a JNI call @@ -2980,29 +2977,9 @@ public: value = NewStringf("%s.%s()", full_imclass_name ? full_imclass_name : imclass_name, Swig_name_get(getNSpace(), symname)); } else { memberconstantHandler(n); - String* outerClassesPrefix = NULL; - if (Node *outer = Getattr(getCurrentClass(), "nested:outer")) { - outerClassesPrefix = Copy(Getattr(outer, "sym:name")); - for (outer = Getattr(outer, "nested:outer"); outer != 0; outer = Getattr(outer, "nested:outer")) { - Push(outerClassesPrefix, "."); - Push(outerClassesPrefix, Getattr(outer, "sym:name")); - } - } - String* full_proxy_class_sym_name = outerClassesPrefix ? NewStringf("%s.%s", outerClassesPrefix, proxy_class_name) : NewStringf("%s", proxy_class_name); - Replaceall(full_proxy_class_sym_name, ".", "_"); - /* Printf(stdout, "Change proxy class symname '%s' -> '%s'\n", proxy_class_name, full_proxy_class_sym_name); */ - value = NewStringf("%s.%s()", full_imclass_name ? full_imclass_name : imclass_name, Swig_name_get(getNSpace(), Swig_name_member(0, full_proxy_class_sym_name, symname))); - Delete(full_proxy_class_sym_name); - if (outerClassesPrefix) - Delete(outerClassesPrefix); - } - - // Delete temporary symname if it was created - if (pureSymname) { - Delete(symname); - symname = pureSymname; - pureSymname = NULL; + value = NewStringf("%s.%s()", full_imclass_name ? full_imclass_name : imclass_name, Swig_name_get(getNSpace(), Swig_name_member(0, getEnumClassPrefix(), symname))); } + Delete(newsymname); } } return value; diff --git a/Source/Modules/lang.cxx b/Source/Modules/lang.cxx index 04eec8af3..454d74eb5 100644 --- a/Source/Modules/lang.cxx +++ b/Source/Modules/lang.cxx @@ -57,7 +57,9 @@ extern "C" { /* Some status variables used during parsing */ static int InClass = 0; /* Parsing C++ or not */ static String *ClassName = 0; /* This is the real name of the current class */ +static String *EnumClassName = 0; /* Enum class name */ static String *ClassPrefix = 0; /* Class prefix */ +static String *EnumClassPrefix = 0; /* Prefix for strongly typed enums (including ClassPrefix) */ static String *NSpace = 0; /* Namespace for the nspace feature */ static String *ClassType = 0; /* Fully qualified type name to use */ static String *DirectorClassName = 0; /* Director name of the current class */ @@ -1650,10 +1652,24 @@ int Language::enumDeclaration(Node *n) { String *oldNSpace = NSpace; NSpace = Getattr(n, "sym:nspace"); + String *oldEnumClassPrefix = EnumClassPrefix; + if (GetFlag(n, "scopedenum")) { + assert(Getattr(n, "sym:name")); + assert(Getattr(n, "name")); + EnumClassPrefix = ClassPrefix ? NewStringf("%s_", ClassPrefix) : NewString(""); + Printv(EnumClassPrefix, Getattr(n, "sym:name"), NIL); + EnumClassName = Copy(Getattr(n, "name")); + } if (!ImportMode) { emit_children(n); } + if (GetFlag(n, "scopedenum")) { + Delete(EnumClassName); + EnumClassName = 0; + Delete(EnumClassPrefix); + EnumClassPrefix = oldEnumClassPrefix; + } NSpace = oldNSpace; return SWIG_OK; @@ -1720,50 +1736,16 @@ int Language::memberconstantHandler(Node *n) { String *symname = Getattr(n, "sym:name"); String *value = Getattr(n, "value"); - String *mrename = Swig_name_member(0, ClassPrefix, symname); - if (Equal(Getattr(n, "nodeType"), "enumitem")) { - // If enum is strongly-typed, generate fully-qualified symname - Node* parent = parentNode(n); - if (GetFlag(parent, "scopedenum") && !GetFlag(n, "symname_has_enumscope")) - { - SetFlag(n, "symname_has_enumscope"); - Delete(mrename); - - String* enumClassName = Swig_scopename_last(Getattr(parent, "name")); - String* scopedItemName = Swig_name_member(0, enumClassName, symname); - mrename = Swig_name_member(0, ClassPrefix, scopedItemName); - - /* Printf(stdout, "Renamed strong enum value symname (lang:1) '%s' -> '%s'\n", symname, mrename); */ - - Delete(enumClassName); - Delete(scopedItemName); - } - } + String *mrename = Swig_name_member(0, EnumClassPrefix, symname); Setattr(n, "sym:name", mrename); String *new_name = 0; if (Extend) new_name = Copy(value); + else if (EnumClassName) + new_name = NewStringf("%s::%s", isNonVirtualProtectedAccess(n) ? DirectorClassName : EnumClassName, name); else new_name = NewStringf("%s::%s", isNonVirtualProtectedAccess(n) ? DirectorClassName : ClassName, name); - if (Equal(Getattr(n, "nodeType"), "enumitem")) { - // If enum is strongly-typed, generate fully-qualified symname - Node* parent = parentNode(n); - if (GetFlag(parent, "scopedenum") && !GetFlag(n, "name_has_enumscope")) - { - SetFlag(n, "name_has_enumscope"); - Delete(new_name); - - String* enumClassName = Swig_scopename_last(Getattr(parent, "name")); - String* scopedItemName = NewStringf("%s::%s", enumClassName, name); - new_name = NewStringf("%s::%s", isNonVirtualProtectedAccess(n) ? DirectorClassName : ClassName, scopedItemName); - - /* Printf(stdout, "Renamed strong enum value name (lang:1) '%s' -> '%s'\n", name, new_name); */ - - Delete(enumClassName); - Delete(scopedItemName); - } - } Setattr(n, "name", new_name); constantWrapper(n); @@ -2405,6 +2387,7 @@ int Language::classDeclaration(Node *n) { int oldInClass = InClass; String *oldClassType = ClassType; String *oldClassPrefix = ClassPrefix; + String *oldEnumClassPrefix = EnumClassPrefix; String *oldClassName = ClassName; String *oldDirectorClassName = DirectorClassName; String *oldNSpace = NSpace; @@ -2446,6 +2429,7 @@ int Language::classDeclaration(Node *n) { Push(ClassPrefix, "_"); Push(ClassPrefix, Getattr(outerClass, "sym:name")); } + EnumClassPrefix = Copy(ClassPrefix); if (strip) { ClassType = Copy(name); } else { @@ -2513,6 +2497,8 @@ int Language::classDeclaration(Node *n) { CurrentClass = oldCurrentClass; Delete(ClassType); ClassType = oldClassType; + Delete(EnumClassPrefix); + EnumClassPrefix = oldEnumClassPrefix; Delete(ClassPrefix); ClassPrefix = oldClassPrefix; Delete(ClassName); @@ -2998,20 +2984,10 @@ int Language::variableWrapper(Node *n) { Delattr(n,"varset"); Delattr(n,"varget"); - String* pureSymname = NULL; - if (Equal(Getattr(n, "nodeType"), "enumitem")) { - // If enum is strongly-typed, generate fully-qualified symname - Node* parent = parentNode(n); - if (GetFlag(parent, "scopedenum") && !GetFlag(n, "symname_has_enumscope")) - { - pureSymname = symname; - - String* enumClassName = Swig_scopename_last(Getattr(parent, "name")); - symname = Swig_name_member(0, enumClassName, pureSymname); - Delete(enumClassName); - - /* Printf(stdout, "Renamed strong enum value symname (lang:2) '%s' -> '%s'\n", pureSymname, symname); */ - } + String *newsymname = 0; + if (!CurrentClass && EnumClassPrefix) { + newsymname = Swig_name_member(0, EnumClassPrefix, symname); + symname = newsymname; } /* If no way to set variables. We simply create functions */ @@ -3071,14 +3047,7 @@ int Language::variableWrapper(Node *n) { functionWrapper(n); Delattr(n, "varget"); Swig_restore(n); - - // Delete temporary symname if it was created - if (pureSymname) { - Delete(symname); - symname = pureSymname; - pureSymname = NULL; - } - + Delete(newsymname); return SWIG_OK; } @@ -3620,6 +3589,14 @@ String *Language::getClassPrefix() const { return ClassPrefix; } +/* ----------------------------------------------------------------------------- + * Language::getEnumClassPrefix() + * ----------------------------------------------------------------------------- */ + +String *Language::getEnumClassPrefix() const { + return EnumClassPrefix; +} + /* ----------------------------------------------------------------------------- * Language::getClassType() * ----------------------------------------------------------------------------- */ diff --git a/Source/Modules/swigmod.h b/Source/Modules/swigmod.h index 63b91bae5..c2ba384e3 100644 --- a/Source/Modules/swigmod.h +++ b/Source/Modules/swigmod.h @@ -291,6 +291,9 @@ protected: /* Return the current class prefix */ String *getClassPrefix() const; + /* Return the current enum class prefix */ + String *getEnumClassPrefix() const; + /* Fully qualified type name to use */ String *getClassType() const; -- cgit v1.2.1 From f72b9f99a4d46a7b39d11cfd97f4184911d5e18e Mon Sep 17 00:00:00 2001 From: William S Fulton Date: Thu, 20 Nov 2014 20:11:41 +0000 Subject: Enhance cpp11_strongly_typed_enumerations testcase and turn it on --- Examples/test-suite/common.mk | 2 +- .../test-suite/cpp11_strongly_typed_enumerations.i | 94 ++++++++++++++-------- 2 files changed, 62 insertions(+), 34 deletions(-) diff --git a/Examples/test-suite/common.mk b/Examples/test-suite/common.mk index 485453b5a..09eb2b742 100644 --- a/Examples/test-suite/common.mk +++ b/Examples/test-suite/common.mk @@ -525,6 +525,7 @@ CPP11_TEST_CASES = \ cpp11_rvalue_reference3 \ cpp11_sizeof_object \ cpp11_static_assert \ + cpp11_strongly_typed_enumerations \ cpp11_thread_local \ cpp11_template_double_brackets \ cpp11_template_explicit \ @@ -537,7 +538,6 @@ CPP11_TEST_CASES = \ # Broken C++11 test cases. CPP11_TEST_BROKEN = \ # cpp11_hash_tables \ # not fully implemented yet -# cpp11_strongly_typed_enumerations \ # SWIG not quite getting this right yet in all langs # cpp11_variadic_templates \ # Broken for some languages (such as Java) # cpp11_reference_wrapper \ # No typemaps diff --git a/Examples/test-suite/cpp11_strongly_typed_enumerations.i b/Examples/test-suite/cpp11_strongly_typed_enumerations.i index feb7399a1..0c5f12e1f 100644 --- a/Examples/test-suite/cpp11_strongly_typed_enumerations.i +++ b/Examples/test-suite/cpp11_strongly_typed_enumerations.i @@ -2,10 +2,6 @@ strongly typed enums. Enums with the same type are comparable. Enum classes require support for nested classes. */ %module cpp11_strongly_typed_enumerations -%warnfilter(302) Val1; -%warnfilter(302) Val2; -%warnfilter(302) Val3; -%warnfilter(302) Val4; /* Forward declarations (illegally accepted by SWIG - oh well!) */ enum Enum1 : short; @@ -17,14 +13,14 @@ enum : unsigned short; enum class Enum1 { Val1, Val2, - Val3 = 100, - Val4 /* = 101 */ + Val3 = 13, + Val4 }; enum class Enum2 : short { Val1, Val2, - Val3 = 100, + Val3 = 23, Val4 }; %} @@ -39,24 +35,24 @@ enum class Enum5; // Legal in C++11, because enum class declarati enum class Enum6 : unsigned int; // Legal C++11. enum Enum4 : unsigned int { - Val1, Val2, Val3 = 100, Val4 + Val1, Val2, Val3 = 43, Val4 }; enum class Enum5 { - Val1, Val2, Val3 = 100, Val4 + Val1, Val2, Val3 = 53, Val4 }; enum class Enum6 : unsigned int { - Val1, Val2, Val3 = 300, Val4 + Val1, Val2, Val3 = 63, Val4 }; typedef enum class Enum7 : unsigned int { - Val1, Val2, Val3 = 300, Val4 + Val1, Val2, Val3 = 73, Val4 } Enum7td; // enum inherits from non-primitive type enum class Enum8 : size_t { - Val1, Val2, Val3 = 300, Val4 + Val1, Val2, Val3 = 83, Val4 }; template struct TType { @@ -64,7 +60,7 @@ template struct TType { }; enum class Enum10 : TType::type_name { - Val1, Val2, Val3 = 300, Val4 + Val1, Val2, Val3 = 103, Val4 }; // forward declaration, no definition of enum @@ -78,34 +74,50 @@ class Class1 public: enum class Enum12 { - Val1 = 300, - Val2 = 400, + Val1 = 1121, + Val2 = 1122, Val3, Val4 }; enum Enum13 { - Val1 = 300, - Val2 = 400, + Val1 = 1131, + Val2 = 1132, + Val3, + Val4 + }; + + enum class Enum14 + { + Val1 = 1141, + Val2 = 1142, Val3, Val4 }; struct Struct1 { - enum class Enum14 + enum class Enum12 { - Val1 = 300, - Val2 = 400, + Val1 = 3121, + Val2 = 3122, Val3, Val4 }; - enum Enum15 + enum Enum13 + { + Val1 = 3131, + Val2 = 3132, + Val3, + Val4 + }; + + enum class Enum14 { - Val1 = 300, - Val2 = 400, + Val1 = 3141, + Val2 = 3142, Val3, Val4 }; @@ -117,34 +129,50 @@ class Class2 public: enum class Enum12 { - Val1 = 300, - Val2 = 400, + Val1 = 2121, + Val2 = 2122, Val3, Val4 }; enum Enum13 { - Val1 = 300, - Val2 = 400, + Val1 = 2131, + Val2 = 2132, + Val3, + Val4 + }; + + enum class Enum14 + { + Val1 = 2141, + Val2 = 2142, Val3, Val4 }; struct Struct1 { - enum class Enum14 + enum class Enum12 { - Val1 = 300, - Val2 = 400, + Val1 = 4121, + Val2 = 4122, Val3, Val4 }; - enum Enum15 + enum Enum13 + { + Val1 = 4131, + Val2 = 4132, + Val3, + Val4 + }; + + enum class Enum14 { - Val1 = 300, - Val2 = 400, + Val1 = 4141, + Val2 = 4142, Val3, Val4 }; -- cgit v1.2.1 From ede58b87444dba7e0ec79ab2c32279bdbd889209 Mon Sep 17 00:00:00 2001 From: William S Fulton Date: Fri, 21 Nov 2014 18:58:08 +0000 Subject: Cosmetic formatting --- Source/Modules/csharp.cxx | 6 ++---- Source/Modules/java.cxx | 6 ++---- 2 files changed, 4 insertions(+), 8 deletions(-) diff --git a/Source/Modules/csharp.cxx b/Source/Modules/csharp.cxx index d2c37e110..81563c6d6 100644 --- a/Source/Modules/csharp.cxx +++ b/Source/Modules/csharp.cxx @@ -1090,15 +1090,13 @@ public: return ret; } - String *getCurrentScopeName(String *nspace) - { + String *getCurrentScopeName(String *nspace) { String *scope = 0; if (nspace || getCurrentClass()) { scope = NewString(""); if (nspace) Printf(scope, "%s", nspace); - if (Node* cls = getCurrentClass()) - { + if (Node* cls = getCurrentClass()) { if (Node *outer = Getattr(cls, "nested:outer")) { String *outerClassesPrefix = Copy(Getattr(outer, "sym:name")); for (outer = Getattr(outer, "nested:outer"); outer != 0; outer = Getattr(outer, "nested:outer")) { diff --git a/Source/Modules/java.cxx b/Source/Modules/java.cxx index d84100e07..3649995d5 100644 --- a/Source/Modules/java.cxx +++ b/Source/Modules/java.cxx @@ -1194,15 +1194,13 @@ public: return ret; } - String *getCurrentScopeName(String *nspace) - { + String *getCurrentScopeName(String *nspace) { String *scope = 0; if (nspace || getCurrentClass()) { scope = NewString(""); if (nspace) Printf(scope, "%s", nspace); - if (Node* cls = getCurrentClass()) - { + if (Node* cls = getCurrentClass()) { if (Node *outer = Getattr(cls, "nested:outer")) { String *outerClassesPrefix = Copy(Getattr(outer, "sym:name")); for (outer = Getattr(outer, "nested:outer"); outer != 0; outer = Getattr(outer, "nested:outer")) { -- cgit v1.2.1 From fcef37d682e7125288d7c732ffc8f94900314a0c Mon Sep 17 00:00:00 2001 From: William S Fulton Date: Fri, 21 Nov 2014 19:50:23 +0000 Subject: Fix incorrect symbol clash error in C# and Java when using %rename for enums When using using 'simple enum' wrappers --- CHANGES.current | 3 +++ Examples/test-suite/enum_thorough.i | 12 ++++++++++++ Source/Modules/csharp.cxx | 2 +- Source/Modules/java.cxx | 2 +- 4 files changed, 17 insertions(+), 2 deletions(-) diff --git a/CHANGES.current b/CHANGES.current index a5f089dbf..aff98df24 100644 --- a/CHANGES.current +++ b/CHANGES.current @@ -5,6 +5,9 @@ See the RELEASENOTES file for a summary of changes in each release. Version 3.0.3 (in progress) =========================== +2014-11-21: wsfulton + [Java C#] Fix multiply defined error when using %rename of enum items when using the "simple enum" wrappers. + 2014-10-28: vadz [Python] Patch #201 The generated .py file no longer uses *args for all Python parameters. Instead, the parameters are named using the C++ parameter names. diff --git a/Examples/test-suite/enum_thorough.i b/Examples/test-suite/enum_thorough.i index ec31c2787..3ece5471b 100644 --- a/Examples/test-suite/enum_thorough.i +++ b/Examples/test-suite/enum_thorough.i @@ -277,6 +277,18 @@ OldNameStruct::doublenametag renameTest6(OldNameStruct::doublenametag e) OldNameStruct::singlename renameTest7(OldNameStruct::singlename e) { return e; } %} +%rename(Clash1_di1) Clash1::di1; +%rename(Clash1_di2) Clash1::di2; +%rename(Clash1_di3) Clash1::di3; +%inline %{ +namespace Clash1 { + enum DuplicateItems1 { di1, di2 = 10, di3 }; +} +namespace Clash2 { + enum DuplicateItems2 { di1, di2 = 10, di3 }; +} +%} + %inline %{ struct TreesClass { enum trees {oak, fir, pine }; diff --git a/Source/Modules/csharp.cxx b/Source/Modules/csharp.cxx index 81563c6d6..0a698ca2c 100644 --- a/Source/Modules/csharp.cxx +++ b/Source/Modules/csharp.cxx @@ -1308,7 +1308,7 @@ public: else Printf(scope, ".%s", Getattr(parent, "sym:name")); } - if (!addSymbol(name, n, scope)) + if (!addSymbol(symname, n, scope)) return SWIG_ERROR; const String *csattributes = Getattr(n, "feature:cs:attributes"); diff --git a/Source/Modules/java.cxx b/Source/Modules/java.cxx index 3649995d5..2b17721d9 100644 --- a/Source/Modules/java.cxx +++ b/Source/Modules/java.cxx @@ -1410,7 +1410,7 @@ public: else Printf(scope, ".%s", Getattr(parent, "sym:name")); } - if (!addSymbol(name, n, scope)) + if (!addSymbol(symname, n, scope)) return SWIG_ERROR; if ((enum_feature == ProperEnum) && parent_name && !unnamedinstance) { -- cgit v1.2.1 From 0664ecdeb7db57aebe62ca7a04591fa9a372524e Mon Sep 17 00:00:00 2001 From: William S Fulton Date: Sat, 22 Nov 2014 15:59:44 +0000 Subject: Fix strongly typed enums for Java when using simple enum wrappers --- .../test-suite/cpp11_strongly_typed_enumerations_simple.i | 5 +++++ Examples/test-suite/java/Makefile.in | 3 +++ Source/Modules/java.cxx | 12 ++++++++++-- 3 files changed, 18 insertions(+), 2 deletions(-) create mode 100644 Examples/test-suite/cpp11_strongly_typed_enumerations_simple.i diff --git a/Examples/test-suite/cpp11_strongly_typed_enumerations_simple.i b/Examples/test-suite/cpp11_strongly_typed_enumerations_simple.i new file mode 100644 index 000000000..3848d2940 --- /dev/null +++ b/Examples/test-suite/cpp11_strongly_typed_enumerations_simple.i @@ -0,0 +1,5 @@ +%module cpp11_strongly_typed_enumerations_simple + +%include + +%include "cpp11_strongly_typed_enumerations.i" diff --git a/Examples/test-suite/java/Makefile.in b/Examples/test-suite/java/Makefile.in index dd6c74a51..310f1a773 100644 --- a/Examples/test-suite/java/Makefile.in +++ b/Examples/test-suite/java/Makefile.in @@ -40,6 +40,9 @@ CPP_TEST_CASES = \ java_typemaps_typewrapper # li_boost_intrusive_ptr +CPP11_TEST_CASES = \ + cpp11_strongly_typed_enumerations_simple \ + include $(srcdir)/../common.mk # Overridden variables here diff --git a/Source/Modules/java.cxx b/Source/Modules/java.cxx index 2b17721d9..440fbf95a 100644 --- a/Source/Modules/java.cxx +++ b/Source/Modules/java.cxx @@ -1368,6 +1368,7 @@ public: int unnamedinstance = GetFlag(parent, "unnamedinstance"); String *parent_name = Getattr(parent, "name"); String *nspace = getNSpace(); + String *newsymname = 0; String *tmpValue; // Strange hack from parent method @@ -1392,14 +1393,20 @@ public: { EnumFeature enum_feature = decodeEnumFeature(parent); + if ((enum_feature == SimpleEnum) && GetFlag(parent, "scopedenum")) { + newsymname = Swig_name_member(0, Getattr(parent, "sym:name"), symname); + symname = newsymname; + } + // Add to language symbol table String *scope = 0; if (unnamedinstance || !parent_name || enum_feature == SimpleEnum) { - if (proxy_class_name) { + String *enumClassPrefix = getEnumClassPrefix(); + if (enumClassPrefix) { scope = NewString(""); if (nspace) Printf(scope, "%s.", nspace); - Printf(scope, "%s", proxy_class_name); + Printf(scope, "%s", enumClassPrefix); } else { scope = Copy(constants_interface_name); } @@ -1464,6 +1471,7 @@ public: Delete(scope); } + Delete(newsymname); Delete(tmpValue); Swig_restore(n); return SWIG_OK; -- cgit v1.2.1 From 73fc7c2a9035d6b498dcc85d9953d33c395d555d Mon Sep 17 00:00:00 2001 From: William S Fulton Date: Sat, 22 Nov 2014 16:40:49 +0000 Subject: Enhance strongly typed enums testcase --- .../test-suite/cpp11_strongly_typed_enumerations.i | 54 ++++++++++++++++------ 1 file changed, 40 insertions(+), 14 deletions(-) diff --git a/Examples/test-suite/cpp11_strongly_typed_enumerations.i b/Examples/test-suite/cpp11_strongly_typed_enumerations.i index 0c5f12e1f..4bba2d82f 100644 --- a/Examples/test-suite/cpp11_strongly_typed_enumerations.i +++ b/Examples/test-suite/cpp11_strongly_typed_enumerations.i @@ -14,14 +14,18 @@ enum class Enum1 { Val1, Val2, Val3 = 13, - Val4 + Val4, + Val5a = 13, + Val6a }; enum class Enum2 : short { Val1, Val2, Val3 = 23, - Val4 + Val4, + Val5b = 23, + Val6b }; %} @@ -77,7 +81,9 @@ public: Val1 = 1121, Val2 = 1122, Val3, - Val4 + Val4, + Val5c = 1121, + Val6c }; enum Enum13 @@ -85,7 +91,9 @@ public: Val1 = 1131, Val2 = 1132, Val3, - Val4 + Val4, + Val5d = 1131, + Val6d }; enum class Enum14 @@ -93,7 +101,9 @@ public: Val1 = 1141, Val2 = 1142, Val3, - Val4 + Val4, + Val5e = 1141, + Val6e }; struct Struct1 @@ -103,7 +113,9 @@ public: Val1 = 3121, Val2 = 3122, Val3, - Val4 + Val4, + Val5f = 3121, + Val6f }; enum Enum13 @@ -111,7 +123,7 @@ public: Val1 = 3131, Val2 = 3132, Val3, - Val4 + Val4, }; enum class Enum14 @@ -119,7 +131,9 @@ public: Val1 = 3141, Val2 = 3142, Val3, - Val4 + Val4, + Val5g = 3141, + Val6g }; }; }; @@ -132,7 +146,9 @@ public: Val1 = 2121, Val2 = 2122, Val3, - Val4 + Val4, + Val5h = 2121, + Val6h }; enum Enum13 @@ -140,7 +156,9 @@ public: Val1 = 2131, Val2 = 2132, Val3, - Val4 + Val4, + Val5i = 2131, + Val6i }; enum class Enum14 @@ -148,7 +166,9 @@ public: Val1 = 2141, Val2 = 2142, Val3, - Val4 + Val4, + Val5j = 2141, + Val6j }; struct Struct1 @@ -158,7 +178,9 @@ public: Val1 = 4121, Val2 = 4122, Val3, - Val4 + Val4, + Val5k = 4121, + Val6k }; enum Enum13 @@ -166,7 +188,9 @@ public: Val1 = 4131, Val2 = 4132, Val3, - Val4 + Val4, + Val5l = 4131, + Val6l }; enum class Enum14 @@ -174,7 +198,9 @@ public: Val1 = 4141, Val2 = 4142, Val3, - Val4 + Val4, + Val5m = 4141, + Val6m }; }; }; -- cgit v1.2.1 From 366948079f4ff833ce353b853ccbd1be82b23bc7 Mon Sep 17 00:00:00 2001 From: William S Fulton Date: Sat, 22 Nov 2014 16:45:44 +0000 Subject: Add C# support for wrapping C++11 strongly typed enums --- Examples/test-suite/csharp/Makefile.in | 3 + .../cpp11_strongly_typed_enumerations_runme.cs | 163 +++++++++++++++++++++ Source/Modules/csharp.cxx | 26 +++- 3 files changed, 188 insertions(+), 4 deletions(-) create mode 100644 Examples/test-suite/csharp/cpp11_strongly_typed_enumerations_runme.cs diff --git a/Examples/test-suite/csharp/Makefile.in b/Examples/test-suite/csharp/Makefile.in index 7bec108eb..292c751e4 100644 --- a/Examples/test-suite/csharp/Makefile.in +++ b/Examples/test-suite/csharp/Makefile.in @@ -28,6 +28,9 @@ CPP_TEST_CASES = \ intermediary_classname \ li_boost_intrusive_ptr +CPP11_TEST_CASES = \ + cpp11_strongly_typed_enumerations_simple \ + include $(srcdir)/../common.mk # Overridden variables here diff --git a/Examples/test-suite/csharp/cpp11_strongly_typed_enumerations_runme.cs b/Examples/test-suite/csharp/cpp11_strongly_typed_enumerations_runme.cs new file mode 100644 index 000000000..a6180609a --- /dev/null +++ b/Examples/test-suite/csharp/cpp11_strongly_typed_enumerations_runme.cs @@ -0,0 +1,163 @@ + +// This is the bool runtime testcase. It checks that the C++ bool type works. + +using System; +using cpp11_strongly_typed_enumerationsNamespace; + +public class cpp11_strongly_typed_enumerations_runme { + + public static int enumCheck(int actual, int expected) { + if (actual != expected) + throw new ApplicationException("Enum value mismatch. Expected " + expected + " Actual: " + actual); + return expected + 1; + } + + public static void Main() { + int val = 0; + val = enumCheck((int)Enum1.Val1, val); + val = enumCheck((int)Enum1.Val2, val); + val = enumCheck((int)Enum1.Val3, 13); + val = enumCheck((int)Enum1.Val4, val); + val = enumCheck((int)Enum1.Val5a, 13); + val = enumCheck((int)Enum1.Val6a, val); + + val = 0; + val = enumCheck((int)Enum2.Val1, val); + val = enumCheck((int)Enum2.Val2, val); + val = enumCheck((int)Enum2.Val3, 23); + val = enumCheck((int)Enum2.Val4, val); + val = enumCheck((int)Enum2.Val5b, 23); + val = enumCheck((int)Enum2.Val6b, val); + + val = 0; + val = enumCheck((int)Enum4.Val1, val); + val = enumCheck((int)Enum4.Val2, val); + val = enumCheck((int)Enum4.Val3, 43); + val = enumCheck((int)Enum4.Val4, val); + + val = 0; + val = enumCheck((int)Enum5.Val1, val); + val = enumCheck((int)Enum5.Val2, val); + val = enumCheck((int)Enum5.Val3, 53); + val = enumCheck((int)Enum5.Val4, val); + + val = 0; + val = enumCheck((int)Enum6.Val1, val); + val = enumCheck((int)Enum6.Val2, val); + val = enumCheck((int)Enum6.Val3, 63); + val = enumCheck((int)Enum6.Val4, val); + + val = 0; + val = enumCheck((int)Enum7td.Val1, val); + val = enumCheck((int)Enum7td.Val2, val); + val = enumCheck((int)Enum7td.Val3, 73); + val = enumCheck((int)Enum7td.Val4, val); + + val = 0; + val = enumCheck((int)Enum8.Val1, val); + val = enumCheck((int)Enum8.Val2, val); + val = enumCheck((int)Enum8.Val3, 83); + val = enumCheck((int)Enum8.Val4, val); + + val = 0; + val = enumCheck((int)Enum10.Val1, val); + val = enumCheck((int)Enum10.Val2, val); + val = enumCheck((int)Enum10.Val3, 103); + val = enumCheck((int)Enum10.Val4, val); + + val = 0; + val = enumCheck((int)Class1.Enum12.Val1, 1121); + val = enumCheck((int)Class1.Enum12.Val2, 1122); + val = enumCheck((int)Class1.Enum12.Val3, val); + val = enumCheck((int)Class1.Enum12.Val4, val); + val = enumCheck((int)Class1.Enum12.Val5c, 1121); + val = enumCheck((int)Class1.Enum12.Val6c, val); + + val = 0; + val = enumCheck((int)Class1.Enum13.Val1, 1131); + val = enumCheck((int)Class1.Enum13.Val2, 1132); + val = enumCheck((int)Class1.Enum13.Val3, val); + val = enumCheck((int)Class1.Enum13.Val4, val); + val = enumCheck((int)Class1.Enum13.Val5d, 1131); + val = enumCheck((int)Class1.Enum13.Val6d, val); + + val = 0; + val = enumCheck((int)Class1.Enum14.Val1, 1141); + val = enumCheck((int)Class1.Enum14.Val2, 1142); + val = enumCheck((int)Class1.Enum14.Val3, val); + val = enumCheck((int)Class1.Enum14.Val4, val); + val = enumCheck((int)Class1.Enum14.Val5e, 1141); + val = enumCheck((int)Class1.Enum14.Val6e, val); + + val = 0; + val = enumCheck((int)Class1.Struct1.Enum12.Val1, 3121); + val = enumCheck((int)Class1.Struct1.Enum12.Val2, 3122); + val = enumCheck((int)Class1.Struct1.Enum12.Val3, val); + val = enumCheck((int)Class1.Struct1.Enum12.Val4, val); + val = enumCheck((int)Class1.Struct1.Enum12.Val5f, 3121); + val = enumCheck((int)Class1.Struct1.Enum12.Val6f, val); + + val = 0; + val = enumCheck((int)Class1.Struct1.Enum13.Val1, 3131); + val = enumCheck((int)Class1.Struct1.Enum13.Val2, 3132); + val = enumCheck((int)Class1.Struct1.Enum13.Val3, val); + val = enumCheck((int)Class1.Struct1.Enum13.Val4, val); + + val = 0; + val = enumCheck((int)Class1.Struct1.Enum14.Val1, 3141); + val = enumCheck((int)Class1.Struct1.Enum14.Val2, 3142); + val = enumCheck((int)Class1.Struct1.Enum14.Val3, val); + val = enumCheck((int)Class1.Struct1.Enum14.Val4, val); + val = enumCheck((int)Class1.Struct1.Enum14.Val5g, 3141); + val = enumCheck((int)Class1.Struct1.Enum14.Val6g, val); + + val = 0; + val = enumCheck((int)Class2.Enum12.Val1, 2121); + val = enumCheck((int)Class2.Enum12.Val2, 2122); + val = enumCheck((int)Class2.Enum12.Val3, val); + val = enumCheck((int)Class2.Enum12.Val4, val); + val = enumCheck((int)Class2.Enum12.Val5h, 2121); + val = enumCheck((int)Class2.Enum12.Val6h, val); + + val = 0; + val = enumCheck((int)Class2.Enum13.Val1, 2131); + val = enumCheck((int)Class2.Enum13.Val2, 2132); + val = enumCheck((int)Class2.Enum13.Val3, val); + val = enumCheck((int)Class2.Enum13.Val4, val); + val = enumCheck((int)Class2.Enum13.Val5i, 2131); + val = enumCheck((int)Class2.Enum13.Val6i, val); + + val = 0; + val = enumCheck((int)Class2.Enum14.Val1, 2141); + val = enumCheck((int)Class2.Enum14.Val2, 2142); + val = enumCheck((int)Class2.Enum14.Val3, val); + val = enumCheck((int)Class2.Enum14.Val4, val); + val = enumCheck((int)Class2.Enum14.Val5j, 2141); + val = enumCheck((int)Class2.Enum14.Val6j, val); + + val = 0; + val = enumCheck((int)Class2.Struct1.Enum12.Val1, 4121); + val = enumCheck((int)Class2.Struct1.Enum12.Val2, 4122); + val = enumCheck((int)Class2.Struct1.Enum12.Val3, val); + val = enumCheck((int)Class2.Struct1.Enum12.Val4, val); + val = enumCheck((int)Class2.Struct1.Enum12.Val5k, 4121); + val = enumCheck((int)Class2.Struct1.Enum12.Val6k, val); + + val = 0; + val = enumCheck((int)Class2.Struct1.Enum13.Val1, 4131); + val = enumCheck((int)Class2.Struct1.Enum13.Val2, 4132); + val = enumCheck((int)Class2.Struct1.Enum13.Val3, val); + val = enumCheck((int)Class2.Struct1.Enum13.Val4, val); + val = enumCheck((int)Class2.Struct1.Enum13.Val5l, 4131); + val = enumCheck((int)Class2.Struct1.Enum13.Val6l, val); + + val = 0; + val = enumCheck((int)Class2.Struct1.Enum14.Val1, 4141); + val = enumCheck((int)Class2.Struct1.Enum14.Val2, 4142); + val = enumCheck((int)Class2.Struct1.Enum14.Val3, val); + val = enumCheck((int)Class2.Struct1.Enum14.Val4, val); + val = enumCheck((int)Class2.Struct1.Enum14.Val5m, 4141); + val = enumCheck((int)Class2.Struct1.Enum14.Val6m, val); + } +} + diff --git a/Source/Modules/csharp.cxx b/Source/Modules/csharp.cxx index 0a698ca2c..39cab8f0a 100644 --- a/Source/Modules/csharp.cxx +++ b/Source/Modules/csharp.cxx @@ -719,7 +719,7 @@ public: String *overloaded_name = getOverloadedName(n); if (!Getattr(n, "sym:overloaded")) { - if (!addSymbol(Getattr(n, "sym:name"), n, imclass_name)) + if (!addSymbol(symname, n, imclass_name)) return SWIG_ERROR; } @@ -1266,6 +1266,7 @@ public: int unnamedinstance = GetFlag(parent, "unnamedinstance"); String *parent_name = Getattr(parent, "name"); String *nspace = getNSpace(); + String *newsymname = 0; String *tmpValue; // Strange hack from parent method @@ -1290,14 +1291,20 @@ public: { EnumFeature enum_feature = decodeEnumFeature(parent); + if ((enum_feature == SimpleEnum) && GetFlag(parent, "scopedenum")) { + newsymname = Swig_name_member(0, Getattr(parent, "sym:name"), symname); + symname = newsymname; + } + // Add to language symbol table String *scope = 0; if (unnamedinstance || !parent_name || enum_feature == SimpleEnum) { - if (proxy_class_name) { + String *enumClassPrefix = getEnumClassPrefix(); + if (enumClassPrefix) { scope = NewString(""); if (nspace) Printf(scope, "%s.", nspace); - Printf(scope, "%s", proxy_class_name); + Printf(scope, "%s", enumClassPrefix); } else { scope = Copy(module_class_name); } @@ -1380,6 +1387,7 @@ public: Delete(scope); } + Delete(newsymname); Delete(tmpValue); Swig_restore(n); return SWIG_OK; @@ -3053,6 +3061,16 @@ public: // Use the C syntax to make a true C# constant and hope that it compiles as C# code value = Getattr(n, "enumvalue") ? Copy(Getattr(n, "enumvalue")) : Copy(Getattr(n, "enumvalueex")); } else { + String *newsymname = 0; + if (!getCurrentClass() || !proxy_flag) { + String *enumClassPrefix = getEnumClassPrefix(); + if (enumClassPrefix) { + // A global scoped enum + newsymname = Swig_name_member(0, enumClassPrefix, symname); + symname = newsymname; + } + } + // Get the enumvalue from a PINVOKE call if (!getCurrentClass() || !cparse_cplusplus || !proxy_flag) { // Strange hack to change the name @@ -3061,7 +3079,7 @@ public: value = NewStringf("%s.%s()", full_imclass_name ? full_imclass_name : imclass_name, Swig_name_get(getNSpace(), symname)); } else { memberconstantHandler(n); - value = NewStringf("%s.%s()", full_imclass_name ? full_imclass_name : imclass_name, Swig_name_get(getNSpace(), Swig_name_member(0, proxy_class_name, symname))); + value = NewStringf("%s.%s()", full_imclass_name ? full_imclass_name : imclass_name, Swig_name_get(getNSpace(), Swig_name_member(0, getEnumClassPrefix(), symname))); } } } -- cgit v1.2.1 From b5cb93f43e47c45d0e32b6f7df93dbda42096a83 Mon Sep 17 00:00:00 2001 From: William S Fulton Date: Mon, 24 Nov 2014 07:22:13 +0000 Subject: add director_nested_class to list of broken tests --- Examples/test-suite/common.mk | 1 + 1 file changed, 1 insertion(+) diff --git a/Examples/test-suite/common.mk b/Examples/test-suite/common.mk index 36eded830..9a151f3fd 100644 --- a/Examples/test-suite/common.mk +++ b/Examples/test-suite/common.mk @@ -86,6 +86,7 @@ Makefile: $(srcdir)/Makefile.in ../../../config.status CPP_TEST_BROKEN += \ constants \ cpp_broken \ + director_nested_class \ exception_partial_info \ extend_variable \ li_std_vector_ptr \ -- cgit v1.2.1 From 49761fe34784a12ab6a54568fd05122c1aba6dfc Mon Sep 17 00:00:00 2001 From: William S Fulton Date: Tue, 25 Nov 2014 06:23:14 +0000 Subject: Add Java runtime testcases for C++11 strongly typed enums --- .../cpp11_strongly_typed_enumerations_runme.java | 167 +++++++++++++++++++++ ...1_strongly_typed_enumerations_simple_runme.java | 167 +++++++++++++++++++++ 2 files changed, 334 insertions(+) create mode 100644 Examples/test-suite/java/cpp11_strongly_typed_enumerations_runme.java create mode 100644 Examples/test-suite/java/cpp11_strongly_typed_enumerations_simple_runme.java diff --git a/Examples/test-suite/java/cpp11_strongly_typed_enumerations_runme.java b/Examples/test-suite/java/cpp11_strongly_typed_enumerations_runme.java new file mode 100644 index 000000000..f317cf9d2 --- /dev/null +++ b/Examples/test-suite/java/cpp11_strongly_typed_enumerations_runme.java @@ -0,0 +1,167 @@ +import cpp11_strongly_typed_enumerations.*; + +public class cpp11_strongly_typed_enumerations_runme { + + static { + try { + System.loadLibrary("cpp11_strongly_typed_enumerations"); + } 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 int enumCheck(int actual, int expected) { + if (actual != expected) + throw new RuntimeException("Enum value mismatch. Expected " + expected + " Actual: " + actual); + return expected + 1; + } + + public static void main(String argv[]) { + int val = 0; + val = enumCheck(Enum1.Val1.swigValue(), val); + val = enumCheck(Enum1.Val2.swigValue(), val); + val = enumCheck(Enum1.Val3.swigValue(), 13); + val = enumCheck(Enum1.Val4.swigValue(), val); + val = enumCheck(Enum1.Val5a.swigValue(), 13); + val = enumCheck(Enum1.Val6a.swigValue(), val); + + val = 0; + val = enumCheck(Enum2.Val1.swigValue(), val); + val = enumCheck(Enum2.Val2.swigValue(), val); + val = enumCheck(Enum2.Val3.swigValue(), 23); + val = enumCheck(Enum2.Val4.swigValue(), val); + val = enumCheck(Enum2.Val5b.swigValue(), 23); + val = enumCheck(Enum2.Val6b.swigValue(), val); + + val = 0; + val = enumCheck(Enum4.Val1.swigValue(), val); + val = enumCheck(Enum4.Val2.swigValue(), val); + val = enumCheck(Enum4.Val3.swigValue(), 43); + val = enumCheck(Enum4.Val4.swigValue(), val); + + val = 0; + val = enumCheck(Enum5.Val1.swigValue(), val); + val = enumCheck(Enum5.Val2.swigValue(), val); + val = enumCheck(Enum5.Val3.swigValue(), 53); + val = enumCheck(Enum5.Val4.swigValue(), val); + + val = 0; + val = enumCheck(Enum6.Val1.swigValue(), val); + val = enumCheck(Enum6.Val2.swigValue(), val); + val = enumCheck(Enum6.Val3.swigValue(), 63); + val = enumCheck(Enum6.Val4.swigValue(), val); + + val = 0; + val = enumCheck(Enum7td.Val1.swigValue(), val); + val = enumCheck(Enum7td.Val2.swigValue(), val); + val = enumCheck(Enum7td.Val3.swigValue(), 73); + val = enumCheck(Enum7td.Val4.swigValue(), val); + + val = 0; + val = enumCheck(Enum8.Val1.swigValue(), val); + val = enumCheck(Enum8.Val2.swigValue(), val); + val = enumCheck(Enum8.Val3.swigValue(), 83); + val = enumCheck(Enum8.Val4.swigValue(), val); + + val = 0; + val = enumCheck(Enum10.Val1.swigValue(), val); + val = enumCheck(Enum10.Val2.swigValue(), val); + val = enumCheck(Enum10.Val3.swigValue(), 103); + val = enumCheck(Enum10.Val4.swigValue(), val); + + val = 0; + val = enumCheck(Class1.Enum12.Val1.swigValue(), 1121); + val = enumCheck(Class1.Enum12.Val2.swigValue(), 1122); + val = enumCheck(Class1.Enum12.Val3.swigValue(), val); + val = enumCheck(Class1.Enum12.Val4.swigValue(), val); + val = enumCheck(Class1.Enum12.Val5c.swigValue(), 1121); + val = enumCheck(Class1.Enum12.Val6c.swigValue(), val); + + val = 0; + val = enumCheck(Class1.Enum13.Val1.swigValue(), 1131); + val = enumCheck(Class1.Enum13.Val2.swigValue(), 1132); + val = enumCheck(Class1.Enum13.Val3.swigValue(), val); + val = enumCheck(Class1.Enum13.Val4.swigValue(), val); + val = enumCheck(Class1.Enum13.Val5d.swigValue(), 1131); + val = enumCheck(Class1.Enum13.Val6d.swigValue(), val); + + val = 0; + val = enumCheck(Class1.Enum14.Val1.swigValue(), 1141); + val = enumCheck(Class1.Enum14.Val2.swigValue(), 1142); + val = enumCheck(Class1.Enum14.Val3.swigValue(), val); + val = enumCheck(Class1.Enum14.Val4.swigValue(), val); + val = enumCheck(Class1.Enum14.Val5e.swigValue(), 1141); + val = enumCheck(Class1.Enum14.Val6e.swigValue(), val); + + val = 0; + val = enumCheck(Class1.Struct1.Enum12.Val1.swigValue(), 3121); + val = enumCheck(Class1.Struct1.Enum12.Val2.swigValue(), 3122); + val = enumCheck(Class1.Struct1.Enum12.Val3.swigValue(), val); + val = enumCheck(Class1.Struct1.Enum12.Val4.swigValue(), val); + val = enumCheck(Class1.Struct1.Enum12.Val5f.swigValue(), 3121); + val = enumCheck(Class1.Struct1.Enum12.Val6f.swigValue(), val); + + val = 0; + val = enumCheck(Class1.Struct1.Enum13.Val1.swigValue(), 3131); + val = enumCheck(Class1.Struct1.Enum13.Val2.swigValue(), 3132); + val = enumCheck(Class1.Struct1.Enum13.Val3.swigValue(), val); + val = enumCheck(Class1.Struct1.Enum13.Val4.swigValue(), val); + + val = 0; + val = enumCheck(Class1.Struct1.Enum14.Val1.swigValue(), 3141); + val = enumCheck(Class1.Struct1.Enum14.Val2.swigValue(), 3142); + val = enumCheck(Class1.Struct1.Enum14.Val3.swigValue(), val); + val = enumCheck(Class1.Struct1.Enum14.Val4.swigValue(), val); + val = enumCheck(Class1.Struct1.Enum14.Val5g.swigValue(), 3141); + val = enumCheck(Class1.Struct1.Enum14.Val6g.swigValue(), val); + + val = 0; + val = enumCheck(Class2.Enum12.Val1.swigValue(), 2121); + val = enumCheck(Class2.Enum12.Val2.swigValue(), 2122); + val = enumCheck(Class2.Enum12.Val3.swigValue(), val); + val = enumCheck(Class2.Enum12.Val4.swigValue(), val); + val = enumCheck(Class2.Enum12.Val5h.swigValue(), 2121); + val = enumCheck(Class2.Enum12.Val6h.swigValue(), val); + + val = 0; + val = enumCheck(Class2.Enum13.Val1.swigValue(), 2131); + val = enumCheck(Class2.Enum13.Val2.swigValue(), 2132); + val = enumCheck(Class2.Enum13.Val3.swigValue(), val); + val = enumCheck(Class2.Enum13.Val4.swigValue(), val); + val = enumCheck(Class2.Enum13.Val5i.swigValue(), 2131); + val = enumCheck(Class2.Enum13.Val6i.swigValue(), val); + + val = 0; + val = enumCheck(Class2.Enum14.Val1.swigValue(), 2141); + val = enumCheck(Class2.Enum14.Val2.swigValue(), 2142); + val = enumCheck(Class2.Enum14.Val3.swigValue(), val); + val = enumCheck(Class2.Enum14.Val4.swigValue(), val); + val = enumCheck(Class2.Enum14.Val5j.swigValue(), 2141); + val = enumCheck(Class2.Enum14.Val6j.swigValue(), val); + + val = 0; + val = enumCheck(Class2.Struct1.Enum12.Val1.swigValue(), 4121); + val = enumCheck(Class2.Struct1.Enum12.Val2.swigValue(), 4122); + val = enumCheck(Class2.Struct1.Enum12.Val3.swigValue(), val); + val = enumCheck(Class2.Struct1.Enum12.Val4.swigValue(), val); + val = enumCheck(Class2.Struct1.Enum12.Val5k.swigValue(), 4121); + val = enumCheck(Class2.Struct1.Enum12.Val6k.swigValue(), val); + + val = 0; + val = enumCheck(Class2.Struct1.Enum13.Val1.swigValue(), 4131); + val = enumCheck(Class2.Struct1.Enum13.Val2.swigValue(), 4132); + val = enumCheck(Class2.Struct1.Enum13.Val3.swigValue(), val); + val = enumCheck(Class2.Struct1.Enum13.Val4.swigValue(), val); + val = enumCheck(Class2.Struct1.Enum13.Val5l.swigValue(), 4131); + val = enumCheck(Class2.Struct1.Enum13.Val6l.swigValue(), val); + + val = 0; + val = enumCheck(Class2.Struct1.Enum14.Val1.swigValue(), 4141); + val = enumCheck(Class2.Struct1.Enum14.Val2.swigValue(), 4142); + val = enumCheck(Class2.Struct1.Enum14.Val3.swigValue(), val); + val = enumCheck(Class2.Struct1.Enum14.Val4.swigValue(), val); + val = enumCheck(Class2.Struct1.Enum14.Val5m.swigValue(), 4141); + val = enumCheck(Class2.Struct1.Enum14.Val6m.swigValue(), val); + } +} diff --git a/Examples/test-suite/java/cpp11_strongly_typed_enumerations_simple_runme.java b/Examples/test-suite/java/cpp11_strongly_typed_enumerations_simple_runme.java new file mode 100644 index 000000000..6a8b85ba9 --- /dev/null +++ b/Examples/test-suite/java/cpp11_strongly_typed_enumerations_simple_runme.java @@ -0,0 +1,167 @@ +import cpp11_strongly_typed_enumerations_simple.*; + +public class cpp11_strongly_typed_enumerations_simple_runme { + + static { + try { + System.loadLibrary("cpp11_strongly_typed_enumerations_simple"); + } 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 int enumCheck(int actual, int expected) { + if (actual != expected) + throw new RuntimeException("Enum value mismatch. Expected " + expected + " Actual: " + actual); + return expected + 1; + } + + public static void main(String argv[]) { + int val = 0; + val = enumCheck(cpp11_strongly_typed_enumerations_simple.Enum1_Val1, val); + val = enumCheck(cpp11_strongly_typed_enumerations_simple.Enum1_Val2, val); + val = enumCheck(cpp11_strongly_typed_enumerations_simple.Enum1_Val3, 13); + val = enumCheck(cpp11_strongly_typed_enumerations_simple.Enum1_Val4, val); + val = enumCheck(cpp11_strongly_typed_enumerations_simple.Enum1_Val5a, 13); + val = enumCheck(cpp11_strongly_typed_enumerations_simple.Enum1_Val6a, val); + + val = 0; + val = enumCheck(cpp11_strongly_typed_enumerations_simple.Enum2_Val1, val); + val = enumCheck(cpp11_strongly_typed_enumerations_simple.Enum2_Val2, val); + val = enumCheck(cpp11_strongly_typed_enumerations_simple.Enum2_Val3, 23); + val = enumCheck(cpp11_strongly_typed_enumerations_simple.Enum2_Val4, val); + val = enumCheck(cpp11_strongly_typed_enumerations_simple.Enum2_Val5b, 23); + val = enumCheck(cpp11_strongly_typed_enumerations_simple.Enum2_Val6b, val); + + val = 0; + val = enumCheck(cpp11_strongly_typed_enumerations_simple.Val1, val); + val = enumCheck(cpp11_strongly_typed_enumerations_simple.Val2, val); + val = enumCheck(cpp11_strongly_typed_enumerations_simple.Val3, 43); + val = enumCheck(cpp11_strongly_typed_enumerations_simple.Val4, val); + + val = 0; + val = enumCheck(cpp11_strongly_typed_enumerations_simple.Enum5_Val1, val); + val = enumCheck(cpp11_strongly_typed_enumerations_simple.Enum5_Val2, val); + val = enumCheck(cpp11_strongly_typed_enumerations_simple.Enum5_Val3, 53); + val = enumCheck(cpp11_strongly_typed_enumerations_simple.Enum5_Val4, val); + + val = 0; + val = enumCheck(cpp11_strongly_typed_enumerations_simple.Enum6_Val1, val); + val = enumCheck(cpp11_strongly_typed_enumerations_simple.Enum6_Val2, val); + val = enumCheck(cpp11_strongly_typed_enumerations_simple.Enum6_Val3, 63); + val = enumCheck(cpp11_strongly_typed_enumerations_simple.Enum6_Val4, val); + + val = 0; + val = enumCheck(cpp11_strongly_typed_enumerations_simple.Enum7td_Val1, val); + val = enumCheck(cpp11_strongly_typed_enumerations_simple.Enum7td_Val2, val); + val = enumCheck(cpp11_strongly_typed_enumerations_simple.Enum7td_Val3, 73); + val = enumCheck(cpp11_strongly_typed_enumerations_simple.Enum7td_Val4, val); + + val = 0; + val = enumCheck(cpp11_strongly_typed_enumerations_simple.Enum8_Val1, val); + val = enumCheck(cpp11_strongly_typed_enumerations_simple.Enum8_Val2, val); + val = enumCheck(cpp11_strongly_typed_enumerations_simple.Enum8_Val3, 83); + val = enumCheck(cpp11_strongly_typed_enumerations_simple.Enum8_Val4, val); + + val = 0; + val = enumCheck(cpp11_strongly_typed_enumerations_simple.Enum10_Val1, val); + val = enumCheck(cpp11_strongly_typed_enumerations_simple.Enum10_Val2, val); + val = enumCheck(cpp11_strongly_typed_enumerations_simple.Enum10_Val3, 103); + val = enumCheck(cpp11_strongly_typed_enumerations_simple.Enum10_Val4, val); + + val = 0; + val = enumCheck(Class1.Enum12_Val1, 1121); + val = enumCheck(Class1.Enum12_Val2, 1122); + val = enumCheck(Class1.Enum12_Val3, val); + val = enumCheck(Class1.Enum12_Val4, val); + val = enumCheck(Class1.Enum12_Val5c, 1121); + val = enumCheck(Class1.Enum12_Val6c, val); + + val = 0; + val = enumCheck(Class1.Val1, 1131); + val = enumCheck(Class1.Val2, 1132); + val = enumCheck(Class1.Val3, val); + val = enumCheck(Class1.Val4, val); + val = enumCheck(Class1.Val5d, 1131); + val = enumCheck(Class1.Val6d, val); + + val = 0; + val = enumCheck(Class1.Enum14_Val1, 1141); + val = enumCheck(Class1.Enum14_Val2, 1142); + val = enumCheck(Class1.Enum14_Val3, val); + val = enumCheck(Class1.Enum14_Val4, val); + val = enumCheck(Class1.Enum14_Val5e, 1141); + val = enumCheck(Class1.Enum14_Val6e, val); + + val = 0; + val = enumCheck(Class1.Struct1.Enum12_Val1, 3121); + val = enumCheck(Class1.Struct1.Enum12_Val2, 3122); + val = enumCheck(Class1.Struct1.Enum12_Val3, val); + val = enumCheck(Class1.Struct1.Enum12_Val4, val); + val = enumCheck(Class1.Struct1.Enum12_Val5f, 3121); + val = enumCheck(Class1.Struct1.Enum12_Val6f, val); + + val = 0; + val = enumCheck(Class1.Struct1.Val1, 3131); + val = enumCheck(Class1.Struct1.Val2, 3132); + val = enumCheck(Class1.Struct1.Val3, val); + val = enumCheck(Class1.Struct1.Val4, val); + + val = 0; + val = enumCheck(Class1.Struct1.Enum14_Val1, 3141); + val = enumCheck(Class1.Struct1.Enum14_Val2, 3142); + val = enumCheck(Class1.Struct1.Enum14_Val3, val); + val = enumCheck(Class1.Struct1.Enum14_Val4, val); + val = enumCheck(Class1.Struct1.Enum14_Val5g, 3141); + val = enumCheck(Class1.Struct1.Enum14_Val6g, val); + + val = 0; + val = enumCheck(Class2.Enum12_Val1, 2121); + val = enumCheck(Class2.Enum12_Val2, 2122); + val = enumCheck(Class2.Enum12_Val3, val); + val = enumCheck(Class2.Enum12_Val4, val); + val = enumCheck(Class2.Enum12_Val5h, 2121); + val = enumCheck(Class2.Enum12_Val6h, val); + + val = 0; + val = enumCheck(Class2.Val1, 2131); + val = enumCheck(Class2.Val2, 2132); + val = enumCheck(Class2.Val3, val); + val = enumCheck(Class2.Val4, val); + val = enumCheck(Class2.Val5i, 2131); + val = enumCheck(Class2.Val6i, val); + + val = 0; + val = enumCheck(Class2.Enum14_Val1, 2141); + val = enumCheck(Class2.Enum14_Val2, 2142); + val = enumCheck(Class2.Enum14_Val3, val); + val = enumCheck(Class2.Enum14_Val4, val); + val = enumCheck(Class2.Enum14_Val5j, 2141); + val = enumCheck(Class2.Enum14_Val6j, val); + + val = 0; + val = enumCheck(Class2.Struct1.Enum12_Val1, 4121); + val = enumCheck(Class2.Struct1.Enum12_Val2, 4122); + val = enumCheck(Class2.Struct1.Enum12_Val3, val); + val = enumCheck(Class2.Struct1.Enum12_Val4, val); + val = enumCheck(Class2.Struct1.Enum12_Val5k, 4121); + val = enumCheck(Class2.Struct1.Enum12_Val6k, val); + + val = 0; + val = enumCheck(Class2.Struct1.Val1, 4131); + val = enumCheck(Class2.Struct1.Val2, 4132); + val = enumCheck(Class2.Struct1.Val3, val); + val = enumCheck(Class2.Struct1.Val4, val); + val = enumCheck(Class2.Struct1.Val5l, 4131); + val = enumCheck(Class2.Struct1.Val6l, val); + + val = 0; + val = enumCheck(Class2.Struct1.Enum14_Val1, 4141); + val = enumCheck(Class2.Struct1.Enum14_Val2, 4142); + val = enumCheck(Class2.Struct1.Enum14_Val3, val); + val = enumCheck(Class2.Struct1.Enum14_Val4, val); + val = enumCheck(Class2.Struct1.Enum14_Val5m, 4141); + val = enumCheck(Class2.Struct1.Enum14_Val6m, val); + } +} -- cgit v1.2.1 From b1eb699ff06bf95f5a276b255e512c0fc120e272 Mon Sep 17 00:00:00 2001 From: William S Fulton Date: Tue, 25 Nov 2014 07:04:12 +0000 Subject: C++11 strongly typed enum support This should provide support for most of the scripting languages --- Source/Modules/lang.cxx | 12 ++++++++++-- 1 file changed, 10 insertions(+), 2 deletions(-) diff --git a/Source/Modules/lang.cxx b/Source/Modules/lang.cxx index 7f106a257..c90e3dece 100644 --- a/Source/Modules/lang.cxx +++ b/Source/Modules/lang.cxx @@ -1683,7 +1683,7 @@ int Language::enumvalueDeclaration(Node *n) { if (CurrentClass && (cplus_mode != PUBLIC)) return SWIG_NOWRAP; - Swig_require("enumvalueDeclaration", n, "*name", "?value", NIL); + Swig_require("enumvalueDeclaration", n, "*name", "*sym:name", "?value", NIL); String *value = Getattr(n, "value"); String *name = Getattr(n, "name"); String *tmpValue; @@ -1694,6 +1694,13 @@ int Language::enumvalueDeclaration(Node *n) { tmpValue = NewString(name); Setattr(n, "value", tmpValue); + Node *parent = parentNode(n); + if (GetFlag(parent, "scopedenum")) { + String *symname = Swig_name_member(0, Getattr(parent, "sym:name"), Getattr(n, "sym:name")); + Setattr(n, "sym:name", symname); + Delete(symname); + } + if (!CurrentClass || !cparse_cplusplus) { Setattr(n, "name", tmpValue); /* for wrapping of enums in a namespace when emit_action is used */ constantWrapper(n); @@ -1732,11 +1739,12 @@ int Language::memberconstantHandler(Node *n) { Setattr(n, "feature:except", Getattr(n, "feature:exceptvar")); } + String *enumvalue_symname = Getattr(n, "enumvalueDeclaration:sym:name"); // Only set if a strongly typed enum String *name = Getattr(n, "name"); String *symname = Getattr(n, "sym:name"); String *value = Getattr(n, "value"); - String *mrename = Swig_name_member(0, EnumClassPrefix, symname); + String *mrename = Swig_name_member(0, EnumClassPrefix, enumvalue_symname ? enumvalue_symname : symname); Setattr(n, "sym:name", mrename); String *new_name = 0; -- cgit v1.2.1 From 274977154f412c7bb7a6949f3a5cc44dcd1ee604 Mon Sep 17 00:00:00 2001 From: Vladimir Kalinin Date: Tue, 25 Nov 2014 19:38:37 +0300 Subject: fix for nested template defined out of class (issue #265) --- Examples/test-suite/nested_scope.i | 24 ++++++++++++++++++++++++ Source/CParse/parser.y | 14 ++++++++++---- 2 files changed, 34 insertions(+), 4 deletions(-) diff --git a/Examples/test-suite/nested_scope.i b/Examples/test-suite/nested_scope.i index 059b73535..b1515f77f 100644 --- a/Examples/test-suite/nested_scope.i +++ b/Examples/test-suite/nested_scope.i @@ -31,10 +31,34 @@ namespace ns { struct Nested1; public: struct Nested2; + template class Abstract; + class Real; }; struct Outer1::Nested2 { int data; }; + + class Class { + public: + template class Abstract; + class Real; + }; + + template class Class::Abstract { + public: + virtual void Method() = 0; + }; +#endif +%} +#ifndef __clang__ + %template(abstract_int) Class::Abstract ; +#endif +%inline %{ +#ifndef __clang__ + class Class::Real : public Abstract { + public: + virtual void Method() {} + }; #endif %} diff --git a/Source/CParse/parser.y b/Source/CParse/parser.y index c4061b110..1566bafec 100644 --- a/Source/CParse/parser.y +++ b/Source/CParse/parser.y @@ -2504,6 +2504,7 @@ types_directive : TYPES LPAREN parms RPAREN stringbracesemi { template_directive: SWIGTEMPLATE LPAREN idstringopt RPAREN idcolonnt LESSTHAN valparms GREATERTHAN SEMI { Parm *p, *tp; Node *n; + Node *outer_class = currentOuterClass; Symtab *tscope = 0; int specialized = 0; int variadic = 0; @@ -2516,6 +2517,9 @@ template_directive: SWIGTEMPLATE LPAREN idstringopt RPAREN idcolonnt LESSTHAN va if (!inclass) { $5 = resolve_create_node_scope($5); } + if (nscope_inner && Strcmp(nodeType(nscope_inner), "class") == 0) { + outer_class = nscope_inner; + } /* We use the new namespace entry 'nscope' only to @@ -2648,7 +2652,7 @@ template_directive: SWIGTEMPLATE LPAREN idstringopt RPAREN idcolonnt LESSTHAN va Setattr(templnode,"sym:typename","1"); } /* for now, nested %template is allowed only in the same scope as the template declaration */ - if ($3 && !(nnisclass && ((currentOuterClass && (currentOuterClass != Getattr(nn, "nested:outer"))) + if ($3 && !(nnisclass && ((outer_class && (outer_class != Getattr(nn, "nested:outer"))) ||(extendmode && current_class && (current_class != Getattr(nn, "nested:outer")))))) { /* Comment this out for 1.3.28. We need to @@ -2677,9 +2681,9 @@ template_directive: SWIGTEMPLATE LPAREN idstringopt RPAREN idcolonnt LESSTHAN va Setfile(templnode,cparse_file); Setline(templnode,cparse_line); Delete(temparms); - if (currentOuterClass) { + if (outer_class && nnisclass) { SetFlag(templnode, "nested"); - Setattr(templnode, "nested:outer", currentOuterClass); + Setattr(templnode, "nested:outer", outer_class); } add_symbols_copy(templnode); @@ -4017,7 +4021,9 @@ cpp_template_decl : TEMPLATE LESSTHAN template_parms GREATERTHAN { Swig_symbol_setscope(cscope); Delete(Namespaceprefix); Namespaceprefix = Swig_symbol_qualifiedscopename(0); - if (error) $$ = 0; + if (error || (nscope_inner && Strcmp(nodeType(nscope_inner), "class") == 0)) { + $$ = 0; + } if (currentOuterClass) template_parameters = Getattr(currentOuterClass, "template_parameters"); else -- cgit v1.2.1 From 7ffea44d8090c9341ac15cc1c414469ac3c2a1bb Mon Sep 17 00:00:00 2001 From: William S Fulton Date: Tue, 25 Nov 2014 19:56:34 +0000 Subject: C++11 strongly typed enums runtime test for python --- .../test-suite/cpp11_strongly_typed_enumerations.i | 18 +-- .../cpp11_strongly_typed_enumerations_runme.py | 154 +++++++++++++++++++++ 2 files changed, 159 insertions(+), 13 deletions(-) create mode 100644 Examples/test-suite/python/cpp11_strongly_typed_enumerations_runme.py diff --git a/Examples/test-suite/cpp11_strongly_typed_enumerations.i b/Examples/test-suite/cpp11_strongly_typed_enumerations.i index 4bba2d82f..ccef36904 100644 --- a/Examples/test-suite/cpp11_strongly_typed_enumerations.i +++ b/Examples/test-suite/cpp11_strongly_typed_enumerations.i @@ -1,8 +1,10 @@ -/* This testcase checks whether SWIG produces the correct wrapper for the - strongly typed enums. Enums with the same type are comparable. Enum classes - require support for nested classes. */ +// This testcase checks whether SWIG produces the correct wrappers for strongly typed enums. + %module cpp11_strongly_typed_enumerations +%warnfilter(SWIGWARN_PARSE_NAMED_NESTED_CLASS) Class1::Struct1; +%warnfilter(SWIGWARN_PARSE_NAMED_NESTED_CLASS) Class2::Struct1; + /* Forward declarations (illegally accepted by SWIG - oh well!) */ enum Enum1 : short; enum Enum3; @@ -205,15 +207,5 @@ public: }; }; -/* -TODO -enum class MyClass {AAA, BBB, CCC}; -namespace Space { -enum MyEnum {XXX, YYY, ZZZ}; -} -struct SSS { - MyClass m; -}; -*/ %} diff --git a/Examples/test-suite/python/cpp11_strongly_typed_enumerations_runme.py b/Examples/test-suite/python/cpp11_strongly_typed_enumerations_runme.py new file mode 100644 index 000000000..61046897f --- /dev/null +++ b/Examples/test-suite/python/cpp11_strongly_typed_enumerations_runme.py @@ -0,0 +1,154 @@ +from cpp11_strongly_typed_enumerations import * + +def enumCheck(actual, expected): + if actual != expected: + raise RuntimeError("Enum value mismatch. Expected " + str(expected) + " Actual: " + str(actual)) + return expected + 1 + +val = 0 +val = enumCheck(Enum1_Val1, val) +val = enumCheck(Enum1_Val2, val) +val = enumCheck(Enum1_Val3, 13) +val = enumCheck(Enum1_Val4, val) +val = enumCheck(Enum1_Val5a, 13) +val = enumCheck(Enum1_Val6a, val) + +val = 0 +val = enumCheck(Enum2_Val1, val) +val = enumCheck(Enum2_Val2, val) +val = enumCheck(Enum2_Val3, 23) +val = enumCheck(Enum2_Val4, val) +val = enumCheck(Enum2_Val5b, 23) +val = enumCheck(Enum2_Val6b, val) + +val = 0 +val = enumCheck(Val1, val) +val = enumCheck(Val2, val) +val = enumCheck(Val3, 43) +val = enumCheck(Val4, val) + +val = 0 +val = enumCheck(Enum5_Val1, val) +val = enumCheck(Enum5_Val2, val) +val = enumCheck(Enum5_Val3, 53) +val = enumCheck(Enum5_Val4, val) + +val = 0 +val = enumCheck(Enum6_Val1, val) +val = enumCheck(Enum6_Val2, val) +val = enumCheck(Enum6_Val3, 63) +val = enumCheck(Enum6_Val4, val) + +val = 0 +val = enumCheck(Enum7td_Val1, val) +val = enumCheck(Enum7td_Val2, val) +val = enumCheck(Enum7td_Val3, 73) +val = enumCheck(Enum7td_Val4, val) + +val = 0 +val = enumCheck(Enum8_Val1, val) +val = enumCheck(Enum8_Val2, val) +val = enumCheck(Enum8_Val3, 83) +val = enumCheck(Enum8_Val4, val) + +val = 0 +val = enumCheck(Enum10_Val1, val) +val = enumCheck(Enum10_Val2, val) +val = enumCheck(Enum10_Val3, 103) +val = enumCheck(Enum10_Val4, val) + +val = 0 +val = enumCheck(Class1.Enum12_Val1, 1121) +val = enumCheck(Class1.Enum12_Val2, 1122) +val = enumCheck(Class1.Enum12_Val3, val) +val = enumCheck(Class1.Enum12_Val4, val) +val = enumCheck(Class1.Enum12_Val5c, 1121) +val = enumCheck(Class1.Enum12_Val6c, val) + +val = 0 +val = enumCheck(Class1.Val1, 1131) +val = enumCheck(Class1.Val2, 1132) +val = enumCheck(Class1.Val3, val) +val = enumCheck(Class1.Val4, val) +val = enumCheck(Class1.Val5d, 1131) +val = enumCheck(Class1.Val6d, val) + +val = 0 +val = enumCheck(Class1.Enum14_Val1, 1141) +val = enumCheck(Class1.Enum14_Val2, 1142) +val = enumCheck(Class1.Enum14_Val3, val) +val = enumCheck(Class1.Enum14_Val4, val) +val = enumCheck(Class1.Enum14_Val5e, 1141) +val = enumCheck(Class1.Enum14_Val6e, val) + +# Requires nested class support to work +#val = 0 +#val = enumCheck(Class1.Struct1.Enum12_Val1, 3121) +#val = enumCheck(Class1.Struct1.Enum12_Val2, 3122) +#val = enumCheck(Class1.Struct1.Enum12_Val3, val) +#val = enumCheck(Class1.Struct1.Enum12_Val4, val) +#val = enumCheck(Class1.Struct1.Enum12_Val5f, 3121) +#val = enumCheck(Class1.Struct1.Enum12_Val6f, val) +# +#val = 0 +#val = enumCheck(Class1.Struct1.Val1, 3131) +#val = enumCheck(Class1.Struct1.Val2, 3132) +#val = enumCheck(Class1.Struct1.Val3, val) +#val = enumCheck(Class1.Struct1.Val4, val) +# +#val = 0 +#val = enumCheck(Class1.Struct1.Enum14_Val1, 3141) +#val = enumCheck(Class1.Struct1.Enum14_Val2, 3142) +#val = enumCheck(Class1.Struct1.Enum14_Val3, val) +#val = enumCheck(Class1.Struct1.Enum14_Val4, val) +#val = enumCheck(Class1.Struct1.Enum14_Val5g, 3141) +#val = enumCheck(Class1.Struct1.Enum14_Val6g, val) + +val = 0 +val = enumCheck(Class2.Enum12_Val1, 2121) +val = enumCheck(Class2.Enum12_Val2, 2122) +val = enumCheck(Class2.Enum12_Val3, val) +val = enumCheck(Class2.Enum12_Val4, val) +val = enumCheck(Class2.Enum12_Val5h, 2121) +val = enumCheck(Class2.Enum12_Val6h, val) + +val = 0 +val = enumCheck(Class2.Val1, 2131) +val = enumCheck(Class2.Val2, 2132) +val = enumCheck(Class2.Val3, val) +val = enumCheck(Class2.Val4, val) +val = enumCheck(Class2.Val5i, 2131) +val = enumCheck(Class2.Val6i, val) + +val = 0 +val = enumCheck(Class2.Enum14_Val1, 2141) +val = enumCheck(Class2.Enum14_Val2, 2142) +val = enumCheck(Class2.Enum14_Val3, val) +val = enumCheck(Class2.Enum14_Val4, val) +val = enumCheck(Class2.Enum14_Val5j, 2141) +val = enumCheck(Class2.Enum14_Val6j, val) + +# Requires nested class support to work +#val = 0 +#val = enumCheck(Class2.Struct1.Enum12_Val1, 4121) +#val = enumCheck(Class2.Struct1.Enum12_Val2, 4122) +#val = enumCheck(Class2.Struct1.Enum12_Val3, val) +#val = enumCheck(Class2.Struct1.Enum12_Val4, val) +#val = enumCheck(Class2.Struct1.Enum12_Val5k, 4121) +#val = enumCheck(Class2.Struct1.Enum12_Val6k, val) +# +#val = 0 +#val = enumCheck(Class2.Struct1.Val1, 4131) +#val = enumCheck(Class2.Struct1.Val2, 4132) +#val = enumCheck(Class2.Struct1.Val3, val) +#val = enumCheck(Class2.Struct1.Val4, val) +#val = enumCheck(Class2.Struct1.Val5l, 4131) +#val = enumCheck(Class2.Struct1.Val6l, val) +# +#val = 0 +#val = enumCheck(Class2.Struct1.Enum14_Val1, 4141) +#val = enumCheck(Class2.Struct1.Enum14_Val2, 4142) +#val = enumCheck(Class2.Struct1.Enum14_Val3, val) +#val = enumCheck(Class2.Struct1.Enum14_Val4, val) +#val = enumCheck(Class2.Struct1.Enum14_Val5m, 4141) +#val = enumCheck(Class2.Struct1.Enum14_Val6m, val) -- cgit v1.2.1 From 80ae3353194458628ec5d54097892b6d5b7dddea Mon Sep 17 00:00:00 2001 From: William S Fulton Date: Tue, 25 Nov 2014 20:24:55 +0000 Subject: Enhance C++11 strongly typed enums testcase --- Examples/test-suite/cpp11_strongly_typed_enumerations.i | 7 +++++++ .../csharp/cpp11_strongly_typed_enumerations_runme.cs | 9 +++++++++ .../java/cpp11_strongly_typed_enumerations_runme.java | 9 +++++++++ .../java/cpp11_strongly_typed_enumerations_simple_runme.java | 9 +++++++++ .../python/cpp11_strongly_typed_enumerations_runme.py | 10 ++++++++++ 5 files changed, 44 insertions(+) diff --git a/Examples/test-suite/cpp11_strongly_typed_enumerations.i b/Examples/test-suite/cpp11_strongly_typed_enumerations.i index ccef36904..3a4ee107a 100644 --- a/Examples/test-suite/cpp11_strongly_typed_enumerations.i +++ b/Examples/test-suite/cpp11_strongly_typed_enumerations.i @@ -138,6 +138,9 @@ public: Val6g }; }; + Enum1 class1Test1(Enum1 e) { return e; } + Enum12 class1Test2(Enum12 e) { return e; } + Struct1::Enum12 class1Test3(Struct1::Enum12 e) { return e; } }; class Class2 @@ -207,5 +210,9 @@ public: }; }; +Enum1 globalTest1(Enum1 e) { return e; } +Class1::Enum12 globalTest2(Class1::Enum12 e) { return e; } +Class1::Struct1::Enum12 globalTest3(Class1::Struct1::Enum12 e) { return e; } + %} diff --git a/Examples/test-suite/csharp/cpp11_strongly_typed_enumerations_runme.cs b/Examples/test-suite/csharp/cpp11_strongly_typed_enumerations_runme.cs index a6180609a..f0f48f0bc 100644 --- a/Examples/test-suite/csharp/cpp11_strongly_typed_enumerations_runme.cs +++ b/Examples/test-suite/csharp/cpp11_strongly_typed_enumerations_runme.cs @@ -158,6 +158,15 @@ public class cpp11_strongly_typed_enumerations_runme { val = enumCheck((int)Class2.Struct1.Enum14.Val4, val); val = enumCheck((int)Class2.Struct1.Enum14.Val5m, 4141); val = enumCheck((int)Class2.Struct1.Enum14.Val6m, val); + + Class1 class1 = new Class1(); + enumCheck((int)class1.class1Test1(Enum1.Val5a), 13); + enumCheck((int)class1.class1Test2(Class1.Enum12.Val5c), 1121); + enumCheck((int)class1.class1Test3(Class1.Struct1.Enum12.Val5f), 3121); + + enumCheck((int)cpp11_strongly_typed_enumerations.globalTest1(Enum1.Val5a), 13); + enumCheck((int)cpp11_strongly_typed_enumerations.globalTest2(Class1.Enum12.Val5c), 1121); + enumCheck((int)cpp11_strongly_typed_enumerations.globalTest3(Class1.Struct1.Enum12.Val5f), 3121); } } diff --git a/Examples/test-suite/java/cpp11_strongly_typed_enumerations_runme.java b/Examples/test-suite/java/cpp11_strongly_typed_enumerations_runme.java index f317cf9d2..3e0b3f651 100644 --- a/Examples/test-suite/java/cpp11_strongly_typed_enumerations_runme.java +++ b/Examples/test-suite/java/cpp11_strongly_typed_enumerations_runme.java @@ -163,5 +163,14 @@ public class cpp11_strongly_typed_enumerations_runme { val = enumCheck(Class2.Struct1.Enum14.Val4.swigValue(), val); val = enumCheck(Class2.Struct1.Enum14.Val5m.swigValue(), 4141); val = enumCheck(Class2.Struct1.Enum14.Val6m.swigValue(), val); + + Class1 class1 = new Class1(); + enumCheck(class1.class1Test1(Enum1.Val5a).swigValue(), 13); + enumCheck(class1.class1Test2(Class1.Enum12.Val5c).swigValue(), 1121); + enumCheck(class1.class1Test3(Class1.Struct1.Enum12.Val5f).swigValue(), 3121); + + enumCheck(cpp11_strongly_typed_enumerations.globalTest1(Enum1.Val5a).swigValue(), 13); + enumCheck(cpp11_strongly_typed_enumerations.globalTest2(Class1.Enum12.Val5c).swigValue(), 1121); + enumCheck(cpp11_strongly_typed_enumerations.globalTest3(Class1.Struct1.Enum12.Val5f).swigValue(), 3121); } } diff --git a/Examples/test-suite/java/cpp11_strongly_typed_enumerations_simple_runme.java b/Examples/test-suite/java/cpp11_strongly_typed_enumerations_simple_runme.java index 6a8b85ba9..b50e94893 100644 --- a/Examples/test-suite/java/cpp11_strongly_typed_enumerations_simple_runme.java +++ b/Examples/test-suite/java/cpp11_strongly_typed_enumerations_simple_runme.java @@ -163,5 +163,14 @@ public class cpp11_strongly_typed_enumerations_simple_runme { val = enumCheck(Class2.Struct1.Enum14_Val4, val); val = enumCheck(Class2.Struct1.Enum14_Val5m, 4141); val = enumCheck(Class2.Struct1.Enum14_Val6m, val); + + Class1 class1 = new Class1(); + enumCheck(class1.class1Test1(cpp11_strongly_typed_enumerations_simple.Enum1_Val5a), 13); + enumCheck(class1.class1Test2(Class1.Enum12_Val5c), 1121); + enumCheck(class1.class1Test3(Class1.Struct1.Enum12_Val5f), 3121); + + enumCheck(cpp11_strongly_typed_enumerations_simple.globalTest1(cpp11_strongly_typed_enumerations_simple.Enum1_Val5a), 13); + enumCheck(cpp11_strongly_typed_enumerations_simple.globalTest2(Class1.Enum12_Val5c), 1121); + enumCheck(cpp11_strongly_typed_enumerations_simple.globalTest3(Class1.Struct1.Enum12_Val5f), 3121); } } diff --git a/Examples/test-suite/python/cpp11_strongly_typed_enumerations_runme.py b/Examples/test-suite/python/cpp11_strongly_typed_enumerations_runme.py index 61046897f..6509ba873 100644 --- a/Examples/test-suite/python/cpp11_strongly_typed_enumerations_runme.py +++ b/Examples/test-suite/python/cpp11_strongly_typed_enumerations_runme.py @@ -152,3 +152,13 @@ val = enumCheck(Class2.Enum14_Val6j, val) #val = enumCheck(Class2.Struct1.Enum14_Val4, val) #val = enumCheck(Class2.Struct1.Enum14_Val5m, 4141) #val = enumCheck(Class2.Struct1.Enum14_Val6m, val) + +class1 = Class1() +enumCheck(class1.class1Test1(Enum1_Val5a), 13) +enumCheck(class1.class1Test2(Class1.Enum12_Val5c), 1121) +#enumCheck(class1.class1Test3(Class1.Struct1.Enum12_Val5f), 3121) + +enumCheck(globalTest1(Enum1_Val5a), 13) +enumCheck(globalTest2(Class1.Enum12_Val5c), 1121) +#enumCheck(globalTest3(Class1.Struct1.Enum12_Val5f), 3121) + -- cgit v1.2.1 From b9d70866ca42260df5d90307088085f1a8711e0c Mon Sep 17 00:00:00 2001 From: William S Fulton Date: Tue, 25 Nov 2014 20:59:46 +0000 Subject: Add c++11 strongly typed enums runtime test for Perl --- .../cpp11_strongly_typed_enumerations_runme.pl | 168 +++++++++++++++++++++ 1 file changed, 168 insertions(+) create mode 100644 Examples/test-suite/perl5/cpp11_strongly_typed_enumerations_runme.pl diff --git a/Examples/test-suite/perl5/cpp11_strongly_typed_enumerations_runme.pl b/Examples/test-suite/perl5/cpp11_strongly_typed_enumerations_runme.pl new file mode 100644 index 000000000..db19bbfa6 --- /dev/null +++ b/Examples/test-suite/perl5/cpp11_strongly_typed_enumerations_runme.pl @@ -0,0 +1,168 @@ +use strict; +use warnings; +use Test::More tests => 78; +BEGIN { use_ok('cpp11_strongly_typed_enumerations') } +require_ok('cpp11_strongly_typed_enumerations'); + +sub enumCheck { my($actual, $expected) = @_; + is($actual, $expected); + return $expected + 1; +} + +my $val = 0; +$val = enumCheck($cpp11_strongly_typed_enumerations::Enum1_Val1, $val); +$val = enumCheck($cpp11_strongly_typed_enumerations::Enum1_Val2, $val); +$val = enumCheck($cpp11_strongly_typed_enumerations::Enum1_Val3, 13); +$val = enumCheck($cpp11_strongly_typed_enumerations::Enum1_Val4, $val); +$val = enumCheck($cpp11_strongly_typed_enumerations::Enum1_Val5a, 13); +$val = enumCheck($cpp11_strongly_typed_enumerations::Enum1_Val6a, $val); + +$val = 0; +$val = enumCheck($cpp11_strongly_typed_enumerations::Enum2_Val1, $val); +$val = enumCheck($cpp11_strongly_typed_enumerations::Enum2_Val2, $val); +$val = enumCheck($cpp11_strongly_typed_enumerations::Enum2_Val3, 23); +$val = enumCheck($cpp11_strongly_typed_enumerations::Enum2_Val4, $val); +$val = enumCheck($cpp11_strongly_typed_enumerations::Enum2_Val5b, 23); +$val = enumCheck($cpp11_strongly_typed_enumerations::Enum2_Val6b, $val); + +$val = 0; +$val = enumCheck($cpp11_strongly_typed_enumerations::Val1, $val); +$val = enumCheck($cpp11_strongly_typed_enumerations::Val2, $val); +$val = enumCheck($cpp11_strongly_typed_enumerations::Val3, 43); +$val = enumCheck($cpp11_strongly_typed_enumerations::Val4, $val); + +$val = 0; +$val = enumCheck($cpp11_strongly_typed_enumerations::Enum5_Val1, $val); +$val = enumCheck($cpp11_strongly_typed_enumerations::Enum5_Val2, $val); +$val = enumCheck($cpp11_strongly_typed_enumerations::Enum5_Val3, 53); +$val = enumCheck($cpp11_strongly_typed_enumerations::Enum5_Val4, $val); + +$val = 0; +$val = enumCheck($cpp11_strongly_typed_enumerations::Enum6_Val1, $val); +$val = enumCheck($cpp11_strongly_typed_enumerations::Enum6_Val2, $val); +$val = enumCheck($cpp11_strongly_typed_enumerations::Enum6_Val3, 63); +$val = enumCheck($cpp11_strongly_typed_enumerations::Enum6_Val4, $val); + +$val = 0; +$val = enumCheck($cpp11_strongly_typed_enumerations::Enum7td_Val1, $val); +$val = enumCheck($cpp11_strongly_typed_enumerations::Enum7td_Val2, $val); +$val = enumCheck($cpp11_strongly_typed_enumerations::Enum7td_Val3, 73); +$val = enumCheck($cpp11_strongly_typed_enumerations::Enum7td_Val4, $val); + +$val = 0; +$val = enumCheck($cpp11_strongly_typed_enumerations::Enum8_Val1, $val); +$val = enumCheck($cpp11_strongly_typed_enumerations::Enum8_Val2, $val); +$val = enumCheck($cpp11_strongly_typed_enumerations::Enum8_Val3, 83); +$val = enumCheck($cpp11_strongly_typed_enumerations::Enum8_Val4, $val); + +$val = 0; +$val = enumCheck($cpp11_strongly_typed_enumerations::Enum10_Val1, $val); +$val = enumCheck($cpp11_strongly_typed_enumerations::Enum10_Val2, $val); +$val = enumCheck($cpp11_strongly_typed_enumerations::Enum10_Val3, 103); +$val = enumCheck($cpp11_strongly_typed_enumerations::Enum10_Val4, $val); + +$val = 0; +$val = enumCheck($cpp11_strongly_typed_enumerations::Class1::Enum12_Val1, 1121); +$val = enumCheck($cpp11_strongly_typed_enumerations::Class1::Enum12_Val2, 1122); +$val = enumCheck($cpp11_strongly_typed_enumerations::Class1::Enum12_Val3, $val); +$val = enumCheck($cpp11_strongly_typed_enumerations::Class1::Enum12_Val4, $val); +$val = enumCheck($cpp11_strongly_typed_enumerations::Class1::Enum12_Val5c, 1121); +$val = enumCheck($cpp11_strongly_typed_enumerations::Class1::Enum12_Val6c, $val); + +$val = 0; +$val = enumCheck($cpp11_strongly_typed_enumerations::Class1::Val1, 1131); +$val = enumCheck($cpp11_strongly_typed_enumerations::Class1::Val2, 1132); +$val = enumCheck($cpp11_strongly_typed_enumerations::Class1::Val3, $val); +$val = enumCheck($cpp11_strongly_typed_enumerations::Class1::Val4, $val); +$val = enumCheck($cpp11_strongly_typed_enumerations::Class1::Val5d, 1131); +$val = enumCheck($cpp11_strongly_typed_enumerations::Class1::Val6d, $val); + +$val = 0; +$val = enumCheck($cpp11_strongly_typed_enumerations::Class1::Enum14_Val1, 1141); +$val = enumCheck($cpp11_strongly_typed_enumerations::Class1::Enum14_Val2, 1142); +$val = enumCheck($cpp11_strongly_typed_enumerations::Class1::Enum14_Val3, $val); +$val = enumCheck($cpp11_strongly_typed_enumerations::Class1::Enum14_Val4, $val); +$val = enumCheck($cpp11_strongly_typed_enumerations::Class1::Enum14_Val5e, 1141); +$val = enumCheck($cpp11_strongly_typed_enumerations::Class1::Enum14_Val6e, $val); + +# Requires nested class support to work +#$val = 0; +#$val = enumCheck($cpp11_strongly_typed_enumerations::Class1::Struct1::Enum12_Val1, 3121); +#$val = enumCheck($cpp11_strongly_typed_enumerations::Class1::Struct1::Enum12_Val2, 3122); +#$val = enumCheck($cpp11_strongly_typed_enumerations::Class1::Struct1::Enum12_Val3, $val); +#$val = enumCheck($cpp11_strongly_typed_enumerations::Class1::Struct1::Enum12_Val4, $val); +#$val = enumCheck($cpp11_strongly_typed_enumerations::Class1::Struct1::Enum12_Val5f, 3121); +#$val = enumCheck($cpp11_strongly_typed_enumerations::Class1::Struct1::Enum12_Val6f, $val); +# +#$val = 0; +#$val = enumCheck($cpp11_strongly_typed_enumerations::Class1::Struct1::Val1, 3131); +#$val = enumCheck($cpp11_strongly_typed_enumerations::Class1::Struct1::Val2, 3132); +#$val = enumCheck($cpp11_strongly_typed_enumerations::Class1::Struct1::Val3, $val); +#$val = enumCheck($cpp11_strongly_typed_enumerations::Class1::Struct1::Val4, $val); +# +#$val = 0; +#$val = enumCheck($cpp11_strongly_typed_enumerations::Class1::Struct1::Enum14_Val1, 3141); +#$val = enumCheck($cpp11_strongly_typed_enumerations::Class1::Struct1::Enum14_Val2, 3142); +#$val = enumCheck($cpp11_strongly_typed_enumerations::Class1::Struct1::Enum14_Val3, $val); +#$val = enumCheck($cpp11_strongly_typed_enumerations::Class1::Struct1::Enum14_Val4, $val); +#$val = enumCheck($cpp11_strongly_typed_enumerations::Class1::Struct1::Enum14_Val5g, 3141); +#$val = enumCheck($cpp11_strongly_typed_enumerations::Class1::Struct1::Enum14_Val6g, $val); + +$val = 0; +$val = enumCheck($cpp11_strongly_typed_enumerations::Class2::Enum12_Val1, 2121); +$val = enumCheck($cpp11_strongly_typed_enumerations::Class2::Enum12_Val2, 2122); +$val = enumCheck($cpp11_strongly_typed_enumerations::Class2::Enum12_Val3, $val); +$val = enumCheck($cpp11_strongly_typed_enumerations::Class2::Enum12_Val4, $val); +$val = enumCheck($cpp11_strongly_typed_enumerations::Class2::Enum12_Val5h, 2121); +$val = enumCheck($cpp11_strongly_typed_enumerations::Class2::Enum12_Val6h, $val); + +$val = 0; +$val = enumCheck($cpp11_strongly_typed_enumerations::Class2::Val1, 2131); +$val = enumCheck($cpp11_strongly_typed_enumerations::Class2::Val2, 2132); +$val = enumCheck($cpp11_strongly_typed_enumerations::Class2::Val3, $val); +$val = enumCheck($cpp11_strongly_typed_enumerations::Class2::Val4, $val); +$val = enumCheck($cpp11_strongly_typed_enumerations::Class2::Val5i, 2131); +$val = enumCheck($cpp11_strongly_typed_enumerations::Class2::Val6i, $val); + +$val = 0; +$val = enumCheck($cpp11_strongly_typed_enumerations::Class2::Enum14_Val1, 2141); +$val = enumCheck($cpp11_strongly_typed_enumerations::Class2::Enum14_Val2, 2142); +$val = enumCheck($cpp11_strongly_typed_enumerations::Class2::Enum14_Val3, $val); +$val = enumCheck($cpp11_strongly_typed_enumerations::Class2::Enum14_Val4, $val); +$val = enumCheck($cpp11_strongly_typed_enumerations::Class2::Enum14_Val5j, 2141); +$val = enumCheck($cpp11_strongly_typed_enumerations::Class2::Enum14_Val6j, $val); + +# Requires nested class support to work +#$val = 0; +#$val = enumCheck($cpp11_strongly_typed_enumerations::Class2::Struct1::Enum12_Val1, 4121); +#$val = enumCheck($cpp11_strongly_typed_enumerations::Class2::Struct1::Enum12_Val2, 4122); +#$val = enumCheck($cpp11_strongly_typed_enumerations::Class2::Struct1::Enum12_Val3, $val); +#$val = enumCheck($cpp11_strongly_typed_enumerations::Class2::Struct1::Enum12_Val4, $val); +#$val = enumCheck($cpp11_strongly_typed_enumerations::Class2::Struct1::Enum12_Val5k, 4121); +#$val = enumCheck($cpp11_strongly_typed_enumerations::Class2::Struct1::Enum12_Val6k, $val); +# +#$val = 0; +#$val = enumCheck($cpp11_strongly_typed_enumerations::Class2::Struct1::Val1, 4131); +#$val = enumCheck($cpp11_strongly_typed_enumerations::Class2::Struct1::Val2, 4132); +#$val = enumCheck($cpp11_strongly_typed_enumerations::Class2::Struct1::Val3, $val); +#$val = enumCheck($cpp11_strongly_typed_enumerations::Class2::Struct1::Val4, $val); +#$val = enumCheck($cpp11_strongly_typed_enumerations::Class2::Struct1::Val5l, 4131); +#$val = enumCheck($cpp11_strongly_typed_enumerations::Class2::Struct1::Val6l, $val); +# +#$val = 0; +#$val = enumCheck($cpp11_strongly_typed_enumerations::Class2::Struct1::Enum14_Val1, 4141); +#$val = enumCheck($cpp11_strongly_typed_enumerations::Class2::Struct1::Enum14_Val2, 4142); +#$val = enumCheck($cpp11_strongly_typed_enumerations::Class2::Struct1::Enum14_Val3, $val); +#$val = enumCheck($cpp11_strongly_typed_enumerations::Class2::Struct1::Enum14_Val4, $val); +#$val = enumCheck($cpp11_strongly_typed_enumerations::Class2::Struct1::Enum14_Val5m, 4141); +#$val = enumCheck($cpp11_strongly_typed_enumerations::Class2::Struct1::Enum14_Val6m, $val); + +my $class1 = cpp11_strongly_typed_enumerations::Class1->new(); +enumCheck($class1->class1Test1($cpp11_strongly_typed_enumerations::Enum1_Val5a), 13); +enumCheck($class1->class1Test2($cpp11_strongly_typed_enumerations::Class1::Enum12_Val5c), 1121); +#enumCheck($class1->class1Test3($cpp11_strongly_typed_enumerations::Class1::Struct1::Enum12_Val5f), 3121); + +enumCheck(cpp11_strongly_typed_enumerations::globalTest1($cpp11_strongly_typed_enumerations::Enum1_Val5a), 13); +enumCheck(cpp11_strongly_typed_enumerations::globalTest2($cpp11_strongly_typed_enumerations::Class1::Enum12_Val5c), 1121); +#enumCheck(cpp11_strongly_typed_enumerations::globalTest3($cpp11_strongly_typed_enumerations::Class1::Struct1::Enum12_Val5f), 3121); + -- cgit v1.2.1 From 91c5b0fd1355e1cdac91fb4eeae5c0b0e0dd73bf Mon Sep 17 00:00:00 2001 From: William S Fulton Date: Thu, 27 Nov 2014 06:38:42 +0000 Subject: Add c++11 strongly typed enums runtime test for Ruby --- .../cpp11_strongly_typed_enumerations_runme.rb | 177 +++++++++++++++++++++ 1 file changed, 177 insertions(+) create mode 100644 Examples/test-suite/ruby/cpp11_strongly_typed_enumerations_runme.rb diff --git a/Examples/test-suite/ruby/cpp11_strongly_typed_enumerations_runme.rb b/Examples/test-suite/ruby/cpp11_strongly_typed_enumerations_runme.rb new file mode 100644 index 000000000..897a44281 --- /dev/null +++ b/Examples/test-suite/ruby/cpp11_strongly_typed_enumerations_runme.rb @@ -0,0 +1,177 @@ +#!/usr/bin/env ruby +# +# Put description here +# +# +# +# +# + +require 'swig_assert' + +require 'cpp11_strongly_typed_enumerations' + +include Cpp11_strongly_typed_enumerations + +def enumCheck(actual, expected) + raise RuntimeError,"Enum value mismatch. Expected #{expected} Actual: #{actual}" if actual != expected + return expected + 1 +end + +val = 0 +val = enumCheck(Enum1_Val1, val) +val = enumCheck(Enum1_Val2, val) +val = enumCheck(Enum1_Val3, 13) +val = enumCheck(Enum1_Val4, val) +val = enumCheck(Enum1_Val5a, 13) +val = enumCheck(Enum1_Val6a, val) + +val = 0 +val = enumCheck(Enum2_Val1, val) +val = enumCheck(Enum2_Val2, val) +val = enumCheck(Enum2_Val3, 23) +val = enumCheck(Enum2_Val4, val) +val = enumCheck(Enum2_Val5b, 23) +val = enumCheck(Enum2_Val6b, val) + +val = 0 +val = enumCheck(Val1, val) +val = enumCheck(Val2, val) +val = enumCheck(Val3, 43) +val = enumCheck(Val4, val) + +val = 0 +val = enumCheck(Enum5_Val1, val) +val = enumCheck(Enum5_Val2, val) +val = enumCheck(Enum5_Val3, 53) +val = enumCheck(Enum5_Val4, val) + +val = 0 +val = enumCheck(Enum6_Val1, val) +val = enumCheck(Enum6_Val2, val) +val = enumCheck(Enum6_Val3, 63) +val = enumCheck(Enum6_Val4, val) + +val = 0 +val = enumCheck(Enum7td_Val1, val) +val = enumCheck(Enum7td_Val2, val) +val = enumCheck(Enum7td_Val3, 73) +val = enumCheck(Enum7td_Val4, val) + +val = 0 +val = enumCheck(Enum8_Val1, val) +val = enumCheck(Enum8_Val2, val) +val = enumCheck(Enum8_Val3, 83) +val = enumCheck(Enum8_Val4, val) + +val = 0 +val = enumCheck(Enum10_Val1, val) +val = enumCheck(Enum10_Val2, val) +val = enumCheck(Enum10_Val3, 103) +val = enumCheck(Enum10_Val4, val) + +val = 0 +val = enumCheck(Class1::Enum12_Val1, 1121) +val = enumCheck(Class1::Enum12_Val2, 1122) +val = enumCheck(Class1::Enum12_Val3, val) +val = enumCheck(Class1::Enum12_Val4, val) +val = enumCheck(Class1::Enum12_Val5c, 1121) +val = enumCheck(Class1::Enum12_Val6c, val) + +val = 0 +val = enumCheck(Class1::Val1, 1131) +val = enumCheck(Class1::Val2, 1132) +val = enumCheck(Class1::Val3, val) +val = enumCheck(Class1::Val4, val) +val = enumCheck(Class1::Val5d, 1131) +val = enumCheck(Class1::Val6d, val) + +val = 0 +val = enumCheck(Class1::Enum14_Val1, 1141) +val = enumCheck(Class1::Enum14_Val2, 1142) +val = enumCheck(Class1::Enum14_Val3, val) +val = enumCheck(Class1::Enum14_Val4, val) +val = enumCheck(Class1::Enum14_Val5e, 1141) +val = enumCheck(Class1::Enum14_Val6e, val) + +# Requires nested class support to work +#val = 0 +#val = enumCheck(Class1::Struct1.Enum12_Val1, 3121) +#val = enumCheck(Class1::Struct1.Enum12_Val2, 3122) +#val = enumCheck(Class1::Struct1.Enum12_Val3, val) +#val = enumCheck(Class1::Struct1.Enum12_Val4, val) +#val = enumCheck(Class1::Struct1.Enum12_Val5f, 3121) +#val = enumCheck(Class1::Struct1.Enum12_Val6f, val) +# +#val = 0 +#val = enumCheck(Class1::Struct1.Val1, 3131) +#val = enumCheck(Class1::Struct1.Val2, 3132) +#val = enumCheck(Class1::Struct1.Val3, val) +#val = enumCheck(Class1::Struct1.Val4, val) +# +#val = 0 +#val = enumCheck(Class1::Struct1.Enum14_Val1, 3141) +#val = enumCheck(Class1::Struct1.Enum14_Val2, 3142) +#val = enumCheck(Class1::Struct1.Enum14_Val3, val) +#val = enumCheck(Class1::Struct1.Enum14_Val4, val) +#val = enumCheck(Class1::Struct1.Enum14_Val5g, 3141) +#val = enumCheck(Class1::Struct1.Enum14_Val6g, val) + +val = 0 +val = enumCheck(Class2::Enum12_Val1, 2121) +val = enumCheck(Class2::Enum12_Val2, 2122) +val = enumCheck(Class2::Enum12_Val3, val) +val = enumCheck(Class2::Enum12_Val4, val) +val = enumCheck(Class2::Enum12_Val5h, 2121) +val = enumCheck(Class2::Enum12_Val6h, val) + +val = 0 +val = enumCheck(Class2::Val1, 2131) +val = enumCheck(Class2::Val2, 2132) +val = enumCheck(Class2::Val3, val) +val = enumCheck(Class2::Val4, val) +val = enumCheck(Class2::Val5i, 2131) +val = enumCheck(Class2::Val6i, val) + +val = 0 +val = enumCheck(Class2::Enum14_Val1, 2141) +val = enumCheck(Class2::Enum14_Val2, 2142) +val = enumCheck(Class2::Enum14_Val3, val) +val = enumCheck(Class2::Enum14_Val4, val) +val = enumCheck(Class2::Enum14_Val5j, 2141) +val = enumCheck(Class2::Enum14_Val6j, val) + +# Requires nested class support to work +#val = 0 +#val = enumCheck(Class2::Struct1.Enum12_Val1, 4121) +#val = enumCheck(Class2::Struct1.Enum12_Val2, 4122) +#val = enumCheck(Class2::Struct1.Enum12_Val3, val) +#val = enumCheck(Class2::Struct1.Enum12_Val4, val) +#val = enumCheck(Class2::Struct1.Enum12_Val5k, 4121) +#val = enumCheck(Class2::Struct1.Enum12_Val6k, val) +# +#val = 0 +#val = enumCheck(Class2::Struct1.Val1, 4131) +#val = enumCheck(Class2::Struct1.Val2, 4132) +#val = enumCheck(Class2::Struct1.Val3, val) +#val = enumCheck(Class2::Struct1.Val4, val) +#val = enumCheck(Class2::Struct1.Val5l, 4131) +#val = enumCheck(Class2::Struct1.Val6l, val) +# +#val = 0 +#val = enumCheck(Class2::Struct1.Enum14_Val1, 4141) +#val = enumCheck(Class2::Struct1.Enum14_Val2, 4142) +#val = enumCheck(Class2::Struct1.Enum14_Val3, val) +#val = enumCheck(Class2::Struct1.Enum14_Val4, val) +#val = enumCheck(Class2::Struct1.Enum14_Val5m, 4141) +#val = enumCheck(Class2::Struct1.Enum14_Val6m, val) + +class1 = Class1.new +enumCheck(class1.class1Test1(Enum1_Val5a), 13) +enumCheck(class1.class1Test2(Class1::Enum12_Val5c), 1121) +#enumCheck(class1.class1Test3(Class1::Struct1.Enum12_Val5f), 3121) + +enumCheck(globalTest1(Enum1_Val5a), 13) +enumCheck(globalTest2(Class1::Enum12_Val5c), 1121) +#enumCheck(globalTest3(Class1::Struct1.Enum12_Val5f), 3121) + -- cgit v1.2.1 From 3efd3affbd83754a37c225baa43bda26762e2da5 Mon Sep 17 00:00:00 2001 From: William S Fulton Date: Thu, 27 Nov 2014 08:14:43 +0000 Subject: Add c++11 strongly typed enum support for PHP --- .../cpp11_strongly_typed_enumerations_runme.php | 169 +++++++++++++++++++++ Lib/php/const.i | 2 +- Lib/php/globalvar.i | 2 +- 3 files changed, 171 insertions(+), 2 deletions(-) create mode 100644 Examples/test-suite/php/cpp11_strongly_typed_enumerations_runme.php diff --git a/Examples/test-suite/php/cpp11_strongly_typed_enumerations_runme.php b/Examples/test-suite/php/cpp11_strongly_typed_enumerations_runme.php new file mode 100644 index 000000000..bee59b209 --- /dev/null +++ b/Examples/test-suite/php/cpp11_strongly_typed_enumerations_runme.php @@ -0,0 +1,169 @@ +class1Test1(Enum1_Val5a), 13); +enumCheck($class1->class1Test2(Class1::Enum12_Val5c), 1121); +#enumCheck($class1.class1Test3(Class1::Struct1.Enum12_Val5f), 3121); + +enumCheck(globalTest1(Enum1_Val5a), 13); +enumCheck(globalTest2(Class1::Enum12_Val5c), 1121); +#enumCheck(globalTest3(Class1::Struct1.Enum12_Val5f), 3121); + +?> diff --git a/Lib/php/const.i b/Lib/php/const.i index 329b0cf07..061ba99a2 100644 --- a/Lib/php/const.i +++ b/Lib/php/const.i @@ -14,7 +14,7 @@ signed char, bool, enum SWIGTYPE - "SWIG_LONG_CONSTANT($symname, $value);"; + "SWIG_LONG_CONSTANT($symname, ($1_type)$value);"; %typemap(consttab) float, double diff --git a/Lib/php/globalvar.i b/Lib/php/globalvar.i index 56f921434..4f21c5cbf 100644 --- a/Lib/php/globalvar.i +++ b/Lib/php/globalvar.i @@ -34,7 +34,7 @@ zval *z_var; MAKE_STD_ZVAL(z_var); z_var->type = IS_LONG; - z_var->value.lval = $1; + z_var->value.lval = (long)$1; zend_hash_add(&EG(symbol_table), (char*)"$1", sizeof("$1"), (void *)&z_var, sizeof(zval *), NULL); } -- cgit v1.2.1 From 55a9dc71151d096b0fafc324d21ac41bc007dbde Mon Sep 17 00:00:00 2001 From: William S Fulton Date: Thu, 27 Nov 2014 19:55:04 +0000 Subject: Add c++11 strongly typed enums runtime test for Tcl --- .../cpp11_strongly_typed_enumerations_runme.tcl | 172 +++++++++++++++++++++ 1 file changed, 172 insertions(+) create mode 100644 Examples/test-suite/tcl/cpp11_strongly_typed_enumerations_runme.tcl diff --git a/Examples/test-suite/tcl/cpp11_strongly_typed_enumerations_runme.tcl b/Examples/test-suite/tcl/cpp11_strongly_typed_enumerations_runme.tcl new file mode 100644 index 000000000..5132101ad --- /dev/null +++ b/Examples/test-suite/tcl/cpp11_strongly_typed_enumerations_runme.tcl @@ -0,0 +1,172 @@ + +if [ catch { load ./cpp11_strongly_typed_enumerations[info sharedlibextension] cpp11_strongly_typed_enumerations} err_msg ] { + puts stderr "Could not load shared object:\n$err_msg" +} + +proc enumCheck {actual expected} { + if {$actual != $expected} { + error "Enum value mismatch. Expected $expected. Actual: $actual" + } + return [expr $expected + 1] +} + +#set val 0 +#set val [enumCheck $Enum1_Val1 $val] +#set val [enumCheck $Enum1_Val2 $val] + +set val 0 +set val [enumCheck $Enum1_Val1 $val] +set val [enumCheck $Enum1_Val2 $val] +set val [enumCheck $Enum1_Val3 13] +set val [enumCheck $Enum1_Val4 $val] +set val [enumCheck $Enum1_Val5a 13] +set val [enumCheck $Enum1_Val6a $val] + +set val 0 +set val [enumCheck $Enum2_Val1 $val] +set val [enumCheck $Enum2_Val2 $val] +set val [enumCheck $Enum2_Val3 23] +set val [enumCheck $Enum2_Val4 $val] +set val [enumCheck $Enum2_Val5b 23] +set val [enumCheck $Enum2_Val6b $val] + +set val 0 +set val [enumCheck $Val1 $val] +set val [enumCheck $Val2 $val] +set val [enumCheck $Val3 43] +set val [enumCheck $Val4 $val] + +set val 0 +set val [enumCheck $Enum5_Val1 $val] +set val [enumCheck $Enum5_Val2 $val] +set val [enumCheck $Enum5_Val3 53] +set val [enumCheck $Enum5_Val4 $val] + +set val 0 +set val [enumCheck $Enum6_Val1 $val] +set val [enumCheck $Enum6_Val2 $val] +set val [enumCheck $Enum6_Val3 63] +set val [enumCheck $Enum6_Val4 $val] + +set val 0 +set val [enumCheck $Enum7td_Val1 $val] +set val [enumCheck $Enum7td_Val2 $val] +set val [enumCheck $Enum7td_Val3 73] +set val [enumCheck $Enum7td_Val4 $val] + +set val 0 +set val [enumCheck $Enum8_Val1 $val] +set val [enumCheck $Enum8_Val2 $val] +set val [enumCheck $Enum8_Val3 83] +set val [enumCheck $Enum8_Val4 $val] + +set val 0 +set val [enumCheck $Enum10_Val1 $val] +set val [enumCheck $Enum10_Val2 $val] +set val [enumCheck $Enum10_Val3 103] +set val [enumCheck $Enum10_Val4 $val] + +set val 0 +set val [enumCheck $Class1_Enum12_Val1 1121] +set val [enumCheck $Class1_Enum12_Val2 1122] +set val [enumCheck $Class1_Enum12_Val3 $val] +set val [enumCheck $Class1_Enum12_Val4 $val] +set val [enumCheck $Class1_Enum12_Val5c 1121] +set val [enumCheck $Class1_Enum12_Val6c $val] + +set val 0 +set val [enumCheck $Class1_Val1 1131] +set val [enumCheck $Class1_Val2 1132] +set val [enumCheck $Class1_Val3 $val] +set val [enumCheck $Class1_Val4 $val] +set val [enumCheck $Class1_Val5d 1131] +set val [enumCheck $Class1_Val6d $val] + +set val 0 +set val [enumCheck $Class1_Enum14_Val1 1141] +set val [enumCheck $Class1_Enum14_Val2 1142] +set val [enumCheck $Class1_Enum14_Val3 $val] +set val [enumCheck $Class1_Enum14_Val4 $val] +set val [enumCheck $Class1_Enum14_Val5e 1141] +set val [enumCheck $Class1_Enum14_Val6e $val] + +# Requires nested class support to work +#set val 0 +#set val [enumCheck $Class1_Struct1_Enum12_Val1 3121] +#set val [enumCheck $Class1_Struct1_Enum12_Val2 3122] +#set val [enumCheck $Class1_Struct1_Enum12_Val3 $val] +#set val [enumCheck $Class1_Struct1_Enum12_Val4 $val] +#set val [enumCheck $Class1_Struct1_Enum12_Val5f 3121] +#set val [enumCheck $Class1_Struct1_Enum12_Val6f $val] +# +#set val 0 +#set val [enumCheck $Class1_Struct1_Val1 3131] +#set val [enumCheck $Class1_Struct1_Val2 3132] +#set val [enumCheck $Class1_Struct1_Val3 $val] +#set val [enumCheck $Class1_Struct1_Val4 $val] +# +#set val 0 +#set val [enumCheck $Class1_Struct1_Enum14_Val1 3141] +#set val [enumCheck $Class1_Struct1_Enum14_Val2 3142] +#set val [enumCheck $Class1_Struct1_Enum14_Val3 $val] +#set val [enumCheck $Class1_Struct1_Enum14_Val4 $val] +#set val [enumCheck $Class1_Struct1_Enum14_Val5g 3141] +#set val [enumCheck $Class1_Struct1_Enum14_Val6g $val] + +set val 0 +set val [enumCheck $Class2_Enum12_Val1 2121] +set val [enumCheck $Class2_Enum12_Val2 2122] +set val [enumCheck $Class2_Enum12_Val3 $val] +set val [enumCheck $Class2_Enum12_Val4 $val] +set val [enumCheck $Class2_Enum12_Val5h 2121] +set val [enumCheck $Class2_Enum12_Val6h $val] + +set val 0 +set val [enumCheck $Class2_Val1 2131] +set val [enumCheck $Class2_Val2 2132] +set val [enumCheck $Class2_Val3 $val] +set val [enumCheck $Class2_Val4 $val] +set val [enumCheck $Class2_Val5i 2131] +set val [enumCheck $Class2_Val6i $val] + +set val 0 +set val [enumCheck $Class2_Enum14_Val1 2141] +set val [enumCheck $Class2_Enum14_Val2 2142] +set val [enumCheck $Class2_Enum14_Val3 $val] +set val [enumCheck $Class2_Enum14_Val4 $val] +set val [enumCheck $Class2_Enum14_Val5j 2141] +set val [enumCheck $Class2_Enum14_Val6j $val] + +# Requires nested class support to work +#set val 0 +#set val [enumCheck $Class2_Struct1_Enum12_Val1 4121] +#set val [enumCheck $Class2_Struct1_Enum12_Val2 4122] +#set val [enumCheck $Class2_Struct1_Enum12_Val3 $val] +#set val [enumCheck $Class2_Struct1_Enum12_Val4 $val] +#set val [enumCheck $Class2_Struct1_Enum12_Val5k 4121] +#set val [enumCheck $Class2_Struct1_Enum12_Val6k $val] +# +#set val 0 +#set val [enumCheck $Class2_Struct1_Val1 4131] +#set val [enumCheck $Class2_Struct1_Val2 4132] +#set val [enumCheck $Class2_Struct1_Val3 $val] +#set val [enumCheck $Class2_Struct1_Val4 $val] +#set val [enumCheck $Class2_Struct1_Val5l 4131] +#set val [enumCheck $Class2_Struct1_Val6l $val] +# +#set val 0 +#set val [enumCheck $Class2_Struct1_Enum14_Val1 4141] +#set val [enumCheck $Class2_Struct1_Enum14_Val2 4142] +#set val [enumCheck $Class2_Struct1_Enum14_Val3 $val] +#set val [enumCheck $Class2_Struct1_Enum14_Val4 $val] +#set val [enumCheck $Class2_Struct1_Enum14_Val5m 4141] +#set val [enumCheck $Class2_Struct1_Enum14_Val6m $val] + +set class1 [Class1] +enumCheck [$class1 class1Test1 $Enum1_Val5a] 13 +enumCheck [$class1 class1Test2 $Class1_Enum12_Val5c] 1121 +#enumCheck [$class1 class1Test3 $Class1_Struct1_Enum12_Val5f] 3121 + +enumCheck [globalTest1 $Enum1_Val5a] 13 +enumCheck [globalTest2 $Class1_Enum12_Val5c] 1121 +#enumCheck [globalTest3 $Class1_Struct1_Enum12_Val5f] 3121 -- cgit v1.2.1 From 97b0868754227d716611e3600ce23b00a73a1017 Mon Sep 17 00:00:00 2001 From: William S Fulton Date: Thu, 27 Nov 2014 20:23:28 +0000 Subject: Fix line endings in lua example --- Examples/lua/embed2/runme.lua | 30 +++++++++++++++--------------- 1 file changed, 15 insertions(+), 15 deletions(-) diff --git a/Examples/lua/embed2/runme.lua b/Examples/lua/embed2/runme.lua index 9e7ab616c..6e93164c0 100644 --- a/Examples/lua/embed2/runme.lua +++ b/Examples/lua/embed2/runme.lua @@ -3,25 +3,25 @@ print "[lua] This is runme.lua" -- we do not need to load the library, as it was already in the interpreter -- but let's check anyway assert(type(example)=='table',"Don't appear to have loaded the example module") - --- note: we will copy the functions from example table into global --- this will help us later -for k,v in pairs(example) do _G[k]=v end --- our add function +-- note: we will copy the functions from example table into global +-- this will help us later +for k,v in pairs(example) do _G[k]=v end + +-- our add function -- we will be calling this from C -function add(a,b) - print("[lua] this is function add(",a,b,")") - c=a+b - print("[lua] returning",c) - return c +function add(a,b) + print("[lua] this is function add(",a,b,")") + c=a+b + print("[lua] returning",c) + return c end -function append(a,b) - print("[lua] this is function append(",a,b,")") - c=a..b - print("[lua] returning",c) - return c +function append(a,b) + print("[lua] this is function append(",a,b,")") + c=a..b + print("[lua] returning",c) + return c end -- cgit v1.2.1 From be272ff8cd5f4f7b9e64c237f1456bddc3ef313d Mon Sep 17 00:00:00 2001 From: William S Fulton Date: Fri, 28 Nov 2014 07:47:45 +0000 Subject: Add c++11 strongly typed enum support for Lua --- .../cpp11_strongly_typed_enumerations_runme.lua | 174 +++++++++++++++++++++ Source/Modules/lua.cxx | 11 +- 2 files changed, 184 insertions(+), 1 deletion(-) create mode 100644 Examples/test-suite/lua/cpp11_strongly_typed_enumerations_runme.lua diff --git a/Examples/test-suite/lua/cpp11_strongly_typed_enumerations_runme.lua b/Examples/test-suite/lua/cpp11_strongly_typed_enumerations_runme.lua new file mode 100644 index 000000000..983e25aa2 --- /dev/null +++ b/Examples/test-suite/lua/cpp11_strongly_typed_enumerations_runme.lua @@ -0,0 +1,174 @@ +require("import") -- the import fn +import("cpp11_strongly_typed_enumerations") -- import lib + +-- catch "undefined" global variables +local env = _ENV -- Lua 5.2 +if not env then env = getfenv () end -- Lua 5.1 +setmetatable(env, {__index=function (t,i) error("undefined global variable `"..i.."'",2) end}) + +function enumCheck(actual, expected) + if not (actual == expected) then + error("Enum value mismatch. Expected: "..expected.." Actual: "..actual) + end + return expected + 1 +end + +--val = 0 +--val = enumCheck(cpp11_strongly_typed_enumerations.cpp11_strongly_typed_enumerations.Enum1_Val1, val) +local val = 0 +val = enumCheck(cpp11_strongly_typed_enumerations.Enum1_Val1, val) +val = enumCheck(cpp11_strongly_typed_enumerations.Enum1_Val2, val) +val = enumCheck(cpp11_strongly_typed_enumerations.Enum1_Val3, 13) +val = enumCheck(cpp11_strongly_typed_enumerations.Enum1_Val4, val) +val = enumCheck(cpp11_strongly_typed_enumerations.Enum1_Val5a, 13) +val = enumCheck(cpp11_strongly_typed_enumerations.Enum1_Val6a, val) + +val = 0 +val = enumCheck(cpp11_strongly_typed_enumerations.Enum2_Val1, val) +val = enumCheck(cpp11_strongly_typed_enumerations.Enum2_Val2, val) +val = enumCheck(cpp11_strongly_typed_enumerations.Enum2_Val3, 23) +val = enumCheck(cpp11_strongly_typed_enumerations.Enum2_Val4, val) +val = enumCheck(cpp11_strongly_typed_enumerations.Enum2_Val5b, 23) +val = enumCheck(cpp11_strongly_typed_enumerations.Enum2_Val6b, val) + +val = 0 +val = enumCheck(cpp11_strongly_typed_enumerations.Val1, val) +val = enumCheck(cpp11_strongly_typed_enumerations.Val2, val) +val = enumCheck(cpp11_strongly_typed_enumerations.Val3, 43) +val = enumCheck(cpp11_strongly_typed_enumerations.Val4, val) + +val = 0 +val = enumCheck(cpp11_strongly_typed_enumerations.Enum5_Val1, val) +val = enumCheck(cpp11_strongly_typed_enumerations.Enum5_Val2, val) +val = enumCheck(cpp11_strongly_typed_enumerations.Enum5_Val3, 53) +val = enumCheck(cpp11_strongly_typed_enumerations.Enum5_Val4, val) + +val = 0 +val = enumCheck(cpp11_strongly_typed_enumerations.Enum6_Val1, val) +val = enumCheck(cpp11_strongly_typed_enumerations.Enum6_Val2, val) +val = enumCheck(cpp11_strongly_typed_enumerations.Enum6_Val3, 63) +val = enumCheck(cpp11_strongly_typed_enumerations.Enum6_Val4, val) + +val = 0 +val = enumCheck(cpp11_strongly_typed_enumerations.Enum7td_Val1, val) +val = enumCheck(cpp11_strongly_typed_enumerations.Enum7td_Val2, val) +val = enumCheck(cpp11_strongly_typed_enumerations.Enum7td_Val3, 73) +val = enumCheck(cpp11_strongly_typed_enumerations.Enum7td_Val4, val) + +val = 0 +val = enumCheck(cpp11_strongly_typed_enumerations.Enum8_Val1, val) +val = enumCheck(cpp11_strongly_typed_enumerations.Enum8_Val2, val) +val = enumCheck(cpp11_strongly_typed_enumerations.Enum8_Val3, 83) +val = enumCheck(cpp11_strongly_typed_enumerations.Enum8_Val4, val) + +val = 0 +val = enumCheck(cpp11_strongly_typed_enumerations.Enum10_Val1, val) +val = enumCheck(cpp11_strongly_typed_enumerations.Enum10_Val2, val) +val = enumCheck(cpp11_strongly_typed_enumerations.Enum10_Val3, 103) +val = enumCheck(cpp11_strongly_typed_enumerations.Enum10_Val4, val) + +val = 0 +val = enumCheck(cpp11_strongly_typed_enumerations.Class1.Enum12_Val1, 1121) +val = enumCheck(cpp11_strongly_typed_enumerations.Class1.Enum12_Val2, 1122) +val = enumCheck(cpp11_strongly_typed_enumerations.Class1.Enum12_Val3, val) +val = enumCheck(cpp11_strongly_typed_enumerations.Class1.Enum12_Val4, val) +val = enumCheck(cpp11_strongly_typed_enumerations.Class1.Enum12_Val5c, 1121) +val = enumCheck(cpp11_strongly_typed_enumerations.Class1.Enum12_Val6c, val) + +val = 0 +val = enumCheck(cpp11_strongly_typed_enumerations.Class1.Val1, 1131) +val = enumCheck(cpp11_strongly_typed_enumerations.Class1.Val2, 1132) +val = enumCheck(cpp11_strongly_typed_enumerations.Class1.Val3, val) +val = enumCheck(cpp11_strongly_typed_enumerations.Class1.Val4, val) +val = enumCheck(cpp11_strongly_typed_enumerations.Class1.Val5d, 1131) +val = enumCheck(cpp11_strongly_typed_enumerations.Class1.Val6d, val) + +val = 0 +val = enumCheck(cpp11_strongly_typed_enumerations.Class1.Enum14_Val1, 1141) +val = enumCheck(cpp11_strongly_typed_enumerations.Class1.Enum14_Val2, 1142) +val = enumCheck(cpp11_strongly_typed_enumerations.Class1.Enum14_Val3, val) +val = enumCheck(cpp11_strongly_typed_enumerations.Class1.Enum14_Val4, val) +val = enumCheck(cpp11_strongly_typed_enumerations.Class1.Enum14_Val5e, 1141) +val = enumCheck(cpp11_strongly_typed_enumerations.Class1.Enum14_Val6e, val) + +-- Requires nested class support to work +--val = 0 +--val = enumCheck(cpp11_strongly_typed_enumerations.Class1.Struct1.Enum12_Val1, 3121) +--val = enumCheck(cpp11_strongly_typed_enumerations.Class1.Struct1.Enum12_Val2, 3122) +--val = enumCheck(cpp11_strongly_typed_enumerations.Class1.Struct1.Enum12_Val3, val) +--val = enumCheck(cpp11_strongly_typed_enumerations.Class1.Struct1.Enum12_Val4, val) +--val = enumCheck(cpp11_strongly_typed_enumerations.Class1.Struct1.Enum12_Val5f, 3121) +--val = enumCheck(cpp11_strongly_typed_enumerations.Class1.Struct1.Enum12_Val6f, val) +-- +--val = 0 +--val = enumCheck(cpp11_strongly_typed_enumerations.Class1.Struct1.Val1, 3131) +--val = enumCheck(cpp11_strongly_typed_enumerations.Class1.Struct1.Val2, 3132) +--val = enumCheck(cpp11_strongly_typed_enumerations.Class1.Struct1.Val3, val) +--val = enumCheck(cpp11_strongly_typed_enumerations.Class1.Struct1.Val4, val) +-- +--val = 0 +--val = enumCheck(cpp11_strongly_typed_enumerations.Class1.Struct1.Enum14_Val1, 3141) +--val = enumCheck(cpp11_strongly_typed_enumerations.Class1.Struct1.Enum14_Val2, 3142) +--val = enumCheck(cpp11_strongly_typed_enumerations.Class1.Struct1.Enum14_Val3, val) +--val = enumCheck(cpp11_strongly_typed_enumerations.Class1.Struct1.Enum14_Val4, val) +--val = enumCheck(cpp11_strongly_typed_enumerations.Class1.Struct1.Enum14_Val5g, 3141) +--val = enumCheck(cpp11_strongly_typed_enumerations.Class1.Struct1.Enum14_Val6g, val) + +val = 0 +val = enumCheck(cpp11_strongly_typed_enumerations.Class2.Enum12_Val1, 2121) +val = enumCheck(cpp11_strongly_typed_enumerations.Class2.Enum12_Val2, 2122) +val = enumCheck(cpp11_strongly_typed_enumerations.Class2.Enum12_Val3, val) +val = enumCheck(cpp11_strongly_typed_enumerations.Class2.Enum12_Val4, val) +val = enumCheck(cpp11_strongly_typed_enumerations.Class2.Enum12_Val5h, 2121) +val = enumCheck(cpp11_strongly_typed_enumerations.Class2.Enum12_Val6h, val) + +val = 0 +val = enumCheck(cpp11_strongly_typed_enumerations.Class2.Val1, 2131) +val = enumCheck(cpp11_strongly_typed_enumerations.Class2.Val2, 2132) +val = enumCheck(cpp11_strongly_typed_enumerations.Class2.Val3, val) +val = enumCheck(cpp11_strongly_typed_enumerations.Class2.Val4, val) +val = enumCheck(cpp11_strongly_typed_enumerations.Class2.Val5i, 2131) +val = enumCheck(cpp11_strongly_typed_enumerations.Class2.Val6i, val) + +val = 0 +val = enumCheck(cpp11_strongly_typed_enumerations.Class2.Enum14_Val1, 2141) +val = enumCheck(cpp11_strongly_typed_enumerations.Class2.Enum14_Val2, 2142) +val = enumCheck(cpp11_strongly_typed_enumerations.Class2.Enum14_Val3, val) +val = enumCheck(cpp11_strongly_typed_enumerations.Class2.Enum14_Val4, val) +val = enumCheck(cpp11_strongly_typed_enumerations.Class2.Enum14_Val5j, 2141) +val = enumCheck(cpp11_strongly_typed_enumerations.Class2.Enum14_Val6j, val) + +-- Requires nested class support to work +--val = 0 +--val = enumCheck(cpp11_strongly_typed_enumerations.Class2.Struct1.Enum12_Val1, 4121) +--val = enumCheck(cpp11_strongly_typed_enumerations.Class2.Struct1.Enum12_Val2, 4122) +--val = enumCheck(cpp11_strongly_typed_enumerations.Class2.Struct1.Enum12_Val3, val) +--val = enumCheck(cpp11_strongly_typed_enumerations.Class2.Struct1.Enum12_Val4, val) +--val = enumCheck(cpp11_strongly_typed_enumerations.Class2.Struct1.Enum12_Val5k, 4121) +--val = enumCheck(cpp11_strongly_typed_enumerations.Class2.Struct1.Enum12_Val6k, val) +-- +--val = 0 +--val = enumCheck(cpp11_strongly_typed_enumerations.Class2.Struct1.Val1, 4131) +--val = enumCheck(cpp11_strongly_typed_enumerations.Class2.Struct1.Val2, 4132) +--val = enumCheck(cpp11_strongly_typed_enumerations.Class2.Struct1.Val3, val) +--val = enumCheck(cpp11_strongly_typed_enumerations.Class2.Struct1.Val4, val) +--val = enumCheck(cpp11_strongly_typed_enumerations.Class2.Struct1.Val5l, 4131) +--val = enumCheck(cpp11_strongly_typed_enumerations.Class2.Struct1.Val6l, val) +-- +--val = 0 +--val = enumCheck(cpp11_strongly_typed_enumerations.Class2.Struct1.Enum14_Val1, 4141) +--val = enumCheck(cpp11_strongly_typed_enumerations.Class2.Struct1.Enum14_Val2, 4142) +--val = enumCheck(cpp11_strongly_typed_enumerations.Class2.Struct1.Enum14_Val3, val) +--val = enumCheck(cpp11_strongly_typed_enumerations.Class2.Struct1.Enum14_Val4, val) +--val = enumCheck(cpp11_strongly_typed_enumerations.Class2.Struct1.Enum14_Val5m, 4141) +--val = enumCheck(cpp11_strongly_typed_enumerations.Class2.Struct1.Enum14_Val6m, val) + +class1 = cpp11_strongly_typed_enumerations.Class1() +enumCheck(class1:class1Test1(cpp11_strongly_typed_enumerations.Enum1_Val5a), 13) +enumCheck(class1:class1Test2(cpp11_strongly_typed_enumerations.Class1.Enum12_Val5c), 1121) +--enumCheck(class1:class1Test3(cpp11_strongly_typed_enumerations.Class1.Struct1.Enum12_Val5f), 3121) + +enumCheck(cpp11_strongly_typed_enumerations.globalTest1(cpp11_strongly_typed_enumerations.Enum1_Val5a), 13) +enumCheck(cpp11_strongly_typed_enumerations.globalTest2(cpp11_strongly_typed_enumerations.Class1.Enum12_Val5c), 1121) +--enumCheck(globalTest3(cpp11_strongly_typed_enumerations.Class1.Struct1.Enum12_Val5f), 3121) + diff --git a/Source/Modules/lua.cxx b/Source/Modules/lua.cxx index 46e21fb91..8211fb317 100644 --- a/Source/Modules/lua.cxx +++ b/Source/Modules/lua.cxx @@ -1184,10 +1184,12 @@ public: if (getCurrentClass() && (cplus_mode != PUBLIC)) return SWIG_NOWRAP; - Swig_require("enumvalueDeclaration", n, "*name", "?value", NIL); + Swig_require("enumvalueDeclaration", n, "*name", "?value", "*sym:name", NIL); + String *symname = Getattr(n, "sym:name"); String *value = Getattr(n, "value"); String *name = Getattr(n, "name"); String *tmpValue; + Node *parent = parentNode(n); if (value) tmpValue = NewString(value); @@ -1196,6 +1198,13 @@ public: Setattr(n, "value", tmpValue); Setattr(n, "name", tmpValue); /* for wrapping of enums in a namespace when emit_action is used */ + + if (GetFlag(parent, "scopedenum")) { + symname = Swig_name_member(0, Getattr(parent, "sym:name"), symname); + Setattr(n, "sym:name", symname); + Delete(symname); + } + int result = constantWrapper(n); Delete(tmpValue); -- cgit v1.2.1 From b45c3737c8904c644abc7258bb652564c063994d Mon Sep 17 00:00:00 2001 From: William S Fulton Date: Fri, 28 Nov 2014 08:13:27 +0000 Subject: Add c++11 strongly typed enum support for D --- Lib/d/denums.swg | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/Lib/d/denums.swg b/Lib/d/denums.swg index 5917da90d..3f8124662 100644 --- a/Lib/d/denums.swg +++ b/Lib/d/denums.swg @@ -16,10 +16,10 @@ %typecheck(SWIG_TYPECHECK_POINTER) enum SWIGTYPE "" %typemap(in) enum SWIGTYPE %{ $1 = ($1_ltype)$input; %} -%typemap(out) enum SWIGTYPE %{ $result = $1; %} +%typemap(out) enum SWIGTYPE %{ $result = (int)$1; %} %typemap(directorout) enum SWIGTYPE %{ $result = ($1_ltype)$input; %} -%typemap(directorin) enum SWIGTYPE "$input = $1;" +%typemap(directorin) enum SWIGTYPE "$input = (int)$1;" %typemap(ddirectorin) enum SWIGTYPE "cast($dclassname)$winput" %typemap(ddirectorout) enum SWIGTYPE "cast(int)$dcall" @@ -43,9 +43,9 @@ %typemap(in) const enum SWIGTYPE & ($*1_ltype temp) %{ temp = ($*1_ltype)$input; $1 = &temp; %} -%typemap(out) const enum SWIGTYPE & %{ $result = *$1; %} +%typemap(out) const enum SWIGTYPE & %{ $result = (int)*$1; %} -%typemap(directorin) const enum SWIGTYPE & "$input = $1;" +%typemap(directorin) const enum SWIGTYPE & "$input = (int)$1;" %typemap(directorout,warning=SWIGWARN_TYPEMAP_THREAD_UNSAFE_MSG) const enum SWIGTYPE & %{ static $*1_ltype temp = ($*1_ltype)$input; $result = &temp; %} -- cgit v1.2.1 From 713d3d597325e39a1bad6e57d52b5d0b375f3099 Mon Sep 17 00:00:00 2001 From: William S Fulton Date: Fri, 28 Nov 2014 20:40:37 +0000 Subject: Add c++11 strongly typed enum support for Go --- .../go/cpp11_strongly_typed_enumerations_runme.go | 171 +++++++++++++++++++++ Source/Modules/go.cxx | 19 ++- 2 files changed, 187 insertions(+), 3 deletions(-) create mode 100644 Examples/test-suite/go/cpp11_strongly_typed_enumerations_runme.go diff --git a/Examples/test-suite/go/cpp11_strongly_typed_enumerations_runme.go b/Examples/test-suite/go/cpp11_strongly_typed_enumerations_runme.go new file mode 100644 index 000000000..f4b84b1ee --- /dev/null +++ b/Examples/test-suite/go/cpp11_strongly_typed_enumerations_runme.go @@ -0,0 +1,171 @@ +package main + +import "fmt" +import . "./cpp11_strongly_typed_enumerations" + +func enumCheck(actual int, expected int) int { + if actual != expected { + panic(fmt.Sprintf("Enum value mismatch. Expected: %d Actual: %d", expected, actual)) + } + return expected + 1 +} + +func main() { + var val = 0 + val = enumCheck(int(Enum1_Val1), val) + val = enumCheck(int(Enum1_Val2), val) + val = enumCheck(int(Enum1_Val3), 13) + val = enumCheck(int(Enum1_Val4), val) + val = enumCheck(int(Enum1_Val5a), 13) + val = enumCheck(int(Enum1_Val6a), val) + + val = 0 + val = enumCheck(int(Enum2_Val1), val) + val = enumCheck(int(Enum2_Val2), val) + val = enumCheck(int(Enum2_Val3), 23) + val = enumCheck(int(Enum2_Val4), val) + val = enumCheck(int(Enum2_Val5b), 23) + val = enumCheck(int(Enum2_Val6b), val) + + val = 0 + val = enumCheck(int(Val1), val) + val = enumCheck(int(Val2), val) + val = enumCheck(int(Val3), 43) + val = enumCheck(int(Val4), val) + + val = 0 + val = enumCheck(int(Enum5_Val1), val) + val = enumCheck(int(Enum5_Val2), val) + val = enumCheck(int(Enum5_Val3), 53) + val = enumCheck(int(Enum5_Val4), val) + + val = 0 + val = enumCheck(int(Enum6_Val1), val) + val = enumCheck(int(Enum6_Val2), val) + val = enumCheck(int(Enum6_Val3), 63) + val = enumCheck(int(Enum6_Val4), val) + + val = 0 + val = enumCheck(int(Enum7td_Val1), val) + val = enumCheck(int(Enum7td_Val2), val) + val = enumCheck(int(Enum7td_Val3), 73) + val = enumCheck(int(Enum7td_Val4), val) + + val = 0 + val = enumCheck(int(Enum8_Val1), val) + val = enumCheck(int(Enum8_Val2), val) + val = enumCheck(int(Enum8_Val3), 83) + val = enumCheck(int(Enum8_Val4), val) + + val = 0 + val = enumCheck(int(Enum10_Val1), val) + val = enumCheck(int(Enum10_Val2), val) + val = enumCheck(int(Enum10_Val3), 103) + val = enumCheck(int(Enum10_Val4), val) + + val = 0 + val = enumCheck(int(Class1Enum12_Val1), 1121) + val = enumCheck(int(Class1Enum12_Val2), 1122) + val = enumCheck(int(Class1Enum12_Val3), val) + val = enumCheck(int(Class1Enum12_Val4), val) + val = enumCheck(int(Class1Enum12_Val5c), 1121) + val = enumCheck(int(Class1Enum12_Val6c), val) + + val = 0 + val = enumCheck(int(Class1Val1), 1131) + val = enumCheck(int(Class1Val2), 1132) + val = enumCheck(int(Class1Val3), val) + val = enumCheck(int(Class1Val4), val) + val = enumCheck(int(Class1Val5d), 1131) + val = enumCheck(int(Class1Val6d), val) + + val = 0 + val = enumCheck(int(Class1Enum14_Val1), 1141) + val = enumCheck(int(Class1Enum14_Val2), 1142) + val = enumCheck(int(Class1Enum14_Val3), val) + val = enumCheck(int(Class1Enum14_Val4), val) + val = enumCheck(int(Class1Enum14_Val5e), 1141) + val = enumCheck(int(Class1Enum14_Val6e), val) + + // Requires nested class support to work + //val = 0 + //val = enumCheck(int(Class1Struct1Enum12_Val1), 3121) + //val = enumCheck(int(Class1Struct1Enum12_Val2), 3122) + //val = enumCheck(int(Class1Struct1Enum12_Val3), val) + //val = enumCheck(int(Class1Struct1Enum12_Val4), val) + //val = enumCheck(int(Class1Struct1Enum12_Val5f), 3121) + //val = enumCheck(int(Class1Struct1Enum12_Val6f), val) + // + //val = 0 + //val = enumCheck(int(Class1Struct1Val1), 3131) + //val = enumCheck(int(Class1Struct1Val2), 3132) + //val = enumCheck(int(Class1Struct1Val3), val) + //val = enumCheck(int(Class1Struct1Val4), val) + // + //val = 0 + //val = enumCheck(int(Class1Struct1Enum14_Val1), 3141) + //val = enumCheck(int(Class1Struct1Enum14_Val2), 3142) + //val = enumCheck(int(Class1Struct1Enum14_Val3), val) + //val = enumCheck(int(Class1Struct1Enum14_Val4), val) + //val = enumCheck(int(Class1Struct1Enum14_Val5g), 3141) + //val = enumCheck(int(Class1Struct1Enum14_Val6g), val) + + val = 0 + val = enumCheck(int(Class2Enum12_Val1), 2121) + val = enumCheck(int(Class2Enum12_Val2), 2122) + val = enumCheck(int(Class2Enum12_Val3), val) + val = enumCheck(int(Class2Enum12_Val4), val) + val = enumCheck(int(Class2Enum12_Val5h), 2121) + val = enumCheck(int(Class2Enum12_Val6h), val) + + val = 0 + val = enumCheck(int(Class2Val1), 2131) + val = enumCheck(int(Class2Val2), 2132) + val = enumCheck(int(Class2Val3), val) + val = enumCheck(int(Class2Val4), val) + val = enumCheck(int(Class2Val5i), 2131) + val = enumCheck(int(Class2Val6i), val) + + val = 0 + val = enumCheck(int(Class2Enum14_Val1), 2141) + val = enumCheck(int(Class2Enum14_Val2), 2142) + val = enumCheck(int(Class2Enum14_Val3), val) + val = enumCheck(int(Class2Enum14_Val4), val) + val = enumCheck(int(Class2Enum14_Val5j), 2141) + val = enumCheck(int(Class2Enum14_Val6j), val) + + // Requires nested class support to work + //val = 0 + //val = enumCheck(int(Class2Struct1Enum12_Val1), 4121) + //val = enumCheck(int(Class2Struct1Enum12_Val2), 4122) + //val = enumCheck(int(Class2Struct1Enum12_Val3), val) + //val = enumCheck(int(Class2Struct1Enum12_Val4), val) + //val = enumCheck(int(Class2Struct1Enum12_Val5k), 4121) + //val = enumCheck(int(Class2Struct1Enum12_Val6k), val) + // + //val = 0 + //val = enumCheck(int(Class2Struct1Val1), 4131) + //val = enumCheck(int(Class2Struct1Val2), 4132) + //val = enumCheck(int(Class2Struct1Val3), val) + //val = enumCheck(int(Class2Struct1Val4), val) + //val = enumCheck(int(Class2Struct1Val5l), 4131) + //val = enumCheck(int(Class2Struct1Val6l), val) + // + //val = 0 + //val = enumCheck(int(Class2Struct1Enum14_Val1), 4141) + //val = enumCheck(int(Class2Struct1Enum14_Val2), 4142) + //val = enumCheck(int(Class2Struct1Enum14_Val3), val) + //val = enumCheck(int(Class2Struct1Enum14_Val4), val) + //val = enumCheck(int(Class2Struct1Enum14_Val5m), 4141) + //val = enumCheck(int(Class2Struct1Enum14_Val6m), val) + + class1 := NewClass1() + enumCheck(int(class1.Class1Test1(Enum1_Val5a)), 13) + enumCheck(int(class1.Class1Test2(Class1Enum12_Val5c)), 1121) + //enumCheck(int(class1.Class1Test3(Class1Struct1Enum12_Val5f)), 3121) + + enumCheck(int(GlobalTest1(Enum1_Val5a)), 13) + enumCheck(int(GlobalTest2(Class1Enum12_Val5c)), 1121) + //enumCheck(int(GlobalTest3(Class1Struct1Enum12_Val5f)), 3121) + +} diff --git a/Source/Modules/go.cxx b/Source/Modules/go.cxx index 4f706e0d6..639e6f91d 100644 --- a/Source/Modules/go.cxx +++ b/Source/Modules/go.cxx @@ -1959,15 +1959,28 @@ private: * ------------------------------------------------------------------------ */ virtual int enumvalueDeclaration(Node *n) { + Swig_require("enumvalueDeclaration", n, "*sym:name", NIL); + Node *parent = parentNode(n); + if (!is_public(n)) { return SWIG_OK; } - if (Getattr(parentNode(n), "unnamed")) { + if (Getattr(parent, "unnamed")) { Setattr(n, "type", NewString("int")); } else { - Setattr(n, "type", Getattr(parentNode(n), "enumtype")); + Setattr(n, "type", Getattr(parent, "enumtype")); + } + + if (GetFlag(parent, "scopedenum")) { + String *symname = Getattr(n, "sym:name"); + symname = Swig_name_member(0, Getattr(parent, "sym:name"), symname); + Setattr(n, "sym:name", symname); + Delete(symname); } - return goComplexConstant(n, Getattr(n, "type")); + + int ret = goComplexConstant(n, Getattr(n, "type")); + Swig_restore(n); + return ret; } /* ----------------------------------------------------------------------- -- cgit v1.2.1 From cf3be359cf095b7cad2a1a31f5905bb2e38da1b0 Mon Sep 17 00:00:00 2001 From: William S Fulton Date: Fri, 28 Nov 2014 23:27:22 +0000 Subject: Add c++11 strongly typed enum support for Guile --- Lib/guile/typemaps.i | 6 +++--- Source/Modules/guile.cxx | 2 +- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/Lib/guile/typemaps.i b/Lib/guile/typemaps.i index d818613e7..a01e73f64 100644 --- a/Lib/guile/typemaps.i +++ b/Lib/guile/typemaps.i @@ -172,11 +172,11 @@ } * (int *) &($1) = scm_to_int($input); } -%typemap(out) enum SWIGTYPE { $result = scm_from_long($1); } -%typemap(varout) enum SWIGTYPE { $result = scm_from_long($1); } +%typemap(out) enum SWIGTYPE { $result = scm_from_long((int)$1); } +%typemap(varout) enum SWIGTYPE { $result = scm_from_long((int)$1); } %typemap(throws) enum SWIGTYPE { scm_throw(scm_from_locale_symbol((char *) "swig-exception"), - scm_listify(scm_from_long($1), SCM_UNDEFINED)); + scm_listify(scm_from_long((int)$1), SCM_UNDEFINED)); } /* The SIMPLE_MAP_WITH_EXPR macro below defines the whole set of diff --git a/Source/Modules/guile.cxx b/Source/Modules/guile.cxx index a9e51fd1b..ce8d19c06 100644 --- a/Source/Modules/guile.cxx +++ b/Source/Modules/guile.cxx @@ -1350,7 +1350,7 @@ public: Printv(f_header, tm, "\n", NIL); } else { // Create variable and assign it a value - Printf(f_header, "static %s = %s;\n", SwigType_str(type, var_name), rvalue); + Printf(f_header, "static %s = (%s)%s;\n", SwigType_str(type, var_name), type, rvalue); } { /* Hack alert: will cleanup later -- Dave */ -- cgit v1.2.1 From a798699e09718be25a322b6bd32080a3b3986a33 Mon Sep 17 00:00:00 2001 From: William S Fulton Date: Sat, 29 Nov 2014 00:00:32 +0000 Subject: Add c++11 strongly typed enums runtime test for Octave --- .../cpp11_strongly_typed_enumerations_runme.m | 166 +++++++++++++++++++++ 1 file changed, 166 insertions(+) create mode 100644 Examples/test-suite/octave/cpp11_strongly_typed_enumerations_runme.m diff --git a/Examples/test-suite/octave/cpp11_strongly_typed_enumerations_runme.m b/Examples/test-suite/octave/cpp11_strongly_typed_enumerations_runme.m new file mode 100644 index 000000000..f66d3d569 --- /dev/null +++ b/Examples/test-suite/octave/cpp11_strongly_typed_enumerations_runme.m @@ -0,0 +1,166 @@ +cpp11_strongly_typed_enumerations + +function newvalue = enumCheck(actual, expected) + if (actual != expected); + error("Enum value mismatch. Expected: %d Actual: %d", expected, actual); + endif + newvalue = expected + 1; +end + +val = 0; +val = enumCheck(cpp11_strongly_typed_enumerations.Enum1_Val1, val); +val = enumCheck(cpp11_strongly_typed_enumerations.Enum1_Val2, val); +val = enumCheck(cpp11_strongly_typed_enumerations.Enum1_Val3, 13); +val = enumCheck(cpp11_strongly_typed_enumerations.Enum1_Val4, val); +val = enumCheck(cpp11_strongly_typed_enumerations.Enum1_Val5a, 13); +val = enumCheck(cpp11_strongly_typed_enumerations.Enum1_Val6a, val); + +val = 0; +val = enumCheck(cpp11_strongly_typed_enumerations.Enum2_Val1, val); +val = enumCheck(cpp11_strongly_typed_enumerations.Enum2_Val2, val); +val = enumCheck(cpp11_strongly_typed_enumerations.Enum2_Val3, 23); +val = enumCheck(cpp11_strongly_typed_enumerations.Enum2_Val4, val); +val = enumCheck(cpp11_strongly_typed_enumerations.Enum2_Val5b, 23); +val = enumCheck(cpp11_strongly_typed_enumerations.Enum2_Val6b, val); + +val = 0; +val = enumCheck(cpp11_strongly_typed_enumerations.Val1, val); +val = enumCheck(cpp11_strongly_typed_enumerations.Val2, val); +val = enumCheck(cpp11_strongly_typed_enumerations.Val3, 43); +val = enumCheck(cpp11_strongly_typed_enumerations.Val4, val); + +val = 0; +val = enumCheck(cpp11_strongly_typed_enumerations.Enum5_Val1, val); +val = enumCheck(cpp11_strongly_typed_enumerations.Enum5_Val2, val); +val = enumCheck(cpp11_strongly_typed_enumerations.Enum5_Val3, 53); +val = enumCheck(cpp11_strongly_typed_enumerations.Enum5_Val4, val); + +val = 0; +val = enumCheck(cpp11_strongly_typed_enumerations.Enum6_Val1, val); +val = enumCheck(cpp11_strongly_typed_enumerations.Enum6_Val2, val); +val = enumCheck(cpp11_strongly_typed_enumerations.Enum6_Val3, 63); +val = enumCheck(cpp11_strongly_typed_enumerations.Enum6_Val4, val); + +val = 0; +val = enumCheck(cpp11_strongly_typed_enumerations.Enum7td_Val1, val); +val = enumCheck(cpp11_strongly_typed_enumerations.Enum7td_Val2, val); +val = enumCheck(cpp11_strongly_typed_enumerations.Enum7td_Val3, 73); +val = enumCheck(cpp11_strongly_typed_enumerations.Enum7td_Val4, val); + +val = 0; +val = enumCheck(cpp11_strongly_typed_enumerations.Enum8_Val1, val); +val = enumCheck(cpp11_strongly_typed_enumerations.Enum8_Val2, val); +val = enumCheck(cpp11_strongly_typed_enumerations.Enum8_Val3, 83); +val = enumCheck(cpp11_strongly_typed_enumerations.Enum8_Val4, val); + +val = 0; +val = enumCheck(cpp11_strongly_typed_enumerations.Enum10_Val1, val); +val = enumCheck(cpp11_strongly_typed_enumerations.Enum10_Val2, val); +val = enumCheck(cpp11_strongly_typed_enumerations.Enum10_Val3, 103); +val = enumCheck(cpp11_strongly_typed_enumerations.Enum10_Val4, val); + +val = 0; +val = enumCheck(cpp11_strongly_typed_enumerations.Class1_Enum12_Val1, 1121); +val = enumCheck(cpp11_strongly_typed_enumerations.Class1_Enum12_Val2, 1122); +val = enumCheck(cpp11_strongly_typed_enumerations.Class1_Enum12_Val3, val); +val = enumCheck(cpp11_strongly_typed_enumerations.Class1_Enum12_Val4, val); +val = enumCheck(cpp11_strongly_typed_enumerations.Class1_Enum12_Val5c, 1121); +val = enumCheck(cpp11_strongly_typed_enumerations.Class1_Enum12_Val6c, val); + +val = 0; +val = enumCheck(cpp11_strongly_typed_enumerations.Class1_Val1, 1131); +val = enumCheck(cpp11_strongly_typed_enumerations.Class1_Val2, 1132); +val = enumCheck(cpp11_strongly_typed_enumerations.Class1_Val3, val); +val = enumCheck(cpp11_strongly_typed_enumerations.Class1_Val4, val); +val = enumCheck(cpp11_strongly_typed_enumerations.Class1_Val5d, 1131); +val = enumCheck(cpp11_strongly_typed_enumerations.Class1_Val6d, val); + +val = 0; +val = enumCheck(cpp11_strongly_typed_enumerations.Class1_Enum14_Val1, 1141); +val = enumCheck(cpp11_strongly_typed_enumerations.Class1_Enum14_Val2, 1142); +val = enumCheck(cpp11_strongly_typed_enumerations.Class1_Enum14_Val3, val); +val = enumCheck(cpp11_strongly_typed_enumerations.Class1_Enum14_Val4, val); +val = enumCheck(cpp11_strongly_typed_enumerations.Class1_Enum14_Val5e, 1141); +val = enumCheck(cpp11_strongly_typed_enumerations.Class1_Enum14_Val6e, val); + +# Requires nested class support to work +#val = 0; +#val = enumCheck(cpp11_strongly_typed_enumerations.Class1_Struct1.Enum12_Val1, 3121); +#val = enumCheck(cpp11_strongly_typed_enumerations.Class1_Struct1.Enum12_Val2, 3122); +#val = enumCheck(cpp11_strongly_typed_enumerations.Class1_Struct1.Enum12_Val3, val); +#val = enumCheck(cpp11_strongly_typed_enumerations.Class1_Struct1.Enum12_Val4, val); +#val = enumCheck(cpp11_strongly_typed_enumerations.Class1_Struct1.Enum12_Val5f, 3121); +#val = enumCheck(cpp11_strongly_typed_enumerations.Class1_Struct1.Enum12_Val6f, val); +# +#val = 0; +#val = enumCheck(cpp11_strongly_typed_enumerations.Class1_Struct1.Val1, 3131); +#val = enumCheck(cpp11_strongly_typed_enumerations.Class1_Struct1.Val2, 3132); +#val = enumCheck(cpp11_strongly_typed_enumerations.Class1_Struct1.Val3, val); +#val = enumCheck(cpp11_strongly_typed_enumerations.Class1_Struct1.Val4, val); +# +#val = 0; +#val = enumCheck(cpp11_strongly_typed_enumerations.Class1_Struct1.Enum14_Val1, 3141); +#val = enumCheck(cpp11_strongly_typed_enumerations.Class1_Struct1.Enum14_Val2, 3142); +#val = enumCheck(cpp11_strongly_typed_enumerations.Class1_Struct1.Enum14_Val3, val); +#val = enumCheck(cpp11_strongly_typed_enumerations.Class1_Struct1.Enum14_Val4, val); +#val = enumCheck(cpp11_strongly_typed_enumerations.Class1_Struct1.Enum14_Val5g, 3141); +#val = enumCheck(cpp11_strongly_typed_enumerations.Class1_Struct1.Enum14_Val6g, val); + +val = 0; +val = enumCheck(cpp11_strongly_typed_enumerations.Class2_Enum12_Val1, 2121); +val = enumCheck(cpp11_strongly_typed_enumerations.Class2_Enum12_Val2, 2122); +val = enumCheck(cpp11_strongly_typed_enumerations.Class2_Enum12_Val3, val); +val = enumCheck(cpp11_strongly_typed_enumerations.Class2_Enum12_Val4, val); +val = enumCheck(cpp11_strongly_typed_enumerations.Class2_Enum12_Val5h, 2121); +val = enumCheck(cpp11_strongly_typed_enumerations.Class2_Enum12_Val6h, val); + +val = 0; +val = enumCheck(cpp11_strongly_typed_enumerations.Class2_Val1, 2131); +val = enumCheck(cpp11_strongly_typed_enumerations.Class2_Val2, 2132); +val = enumCheck(cpp11_strongly_typed_enumerations.Class2_Val3, val); +val = enumCheck(cpp11_strongly_typed_enumerations.Class2_Val4, val); +val = enumCheck(cpp11_strongly_typed_enumerations.Class2_Val5i, 2131); +val = enumCheck(cpp11_strongly_typed_enumerations.Class2_Val6i, val); + +val = 0; +val = enumCheck(cpp11_strongly_typed_enumerations.Class2_Enum14_Val1, 2141); +val = enumCheck(cpp11_strongly_typed_enumerations.Class2_Enum14_Val2, 2142); +val = enumCheck(cpp11_strongly_typed_enumerations.Class2_Enum14_Val3, val); +val = enumCheck(cpp11_strongly_typed_enumerations.Class2_Enum14_Val4, val); +val = enumCheck(cpp11_strongly_typed_enumerations.Class2_Enum14_Val5j, 2141); +val = enumCheck(cpp11_strongly_typed_enumerations.Class2_Enum14_Val6j, val); + +# Requires nested class support to work +#val = 0; +#val = enumCheck(cpp11_strongly_typed_enumerations.Class2_Struct1_Enum12_Val1, 4121); +#val = enumCheck(cpp11_strongly_typed_enumerations.Class2_Struct1_Enum12_Val2, 4122); +#val = enumCheck(cpp11_strongly_typed_enumerations.Class2_Struct1_Enum12_Val3, val); +#val = enumCheck(cpp11_strongly_typed_enumerations.Class2_Struct1_Enum12_Val4, val); +#val = enumCheck(cpp11_strongly_typed_enumerations.Class2_Struct1_Enum12_Val5k, 4121); +#val = enumCheck(cpp11_strongly_typed_enumerations.Class2_Struct1_Enum12_Val6k, val); +# +#val = 0; +#val = enumCheck(cpp11_strongly_typed_enumerations.Class2_Struct1_Val1, 4131); +#val = enumCheck(cpp11_strongly_typed_enumerations.Class2_Struct1_Val2, 4132); +#val = enumCheck(cpp11_strongly_typed_enumerations.Class2_Struct1_Val3, val); +#val = enumCheck(cpp11_strongly_typed_enumerations.Class2_Struct1_Val4, val); +#val = enumCheck(cpp11_strongly_typed_enumerations.Class2_Struct1_Val5l, 4131); +#val = enumCheck(cpp11_strongly_typed_enumerations.Class2_Struct1_Val6l, val); +# +#val = 0; +#val = enumCheck(cpp11_strongly_typed_enumerations.Class2_Struct1_Enum14_Val1, 4141); +#val = enumCheck(cpp11_strongly_typed_enumerations.Class2_Struct1_Enum14_Val2, 4142); +#val = enumCheck(cpp11_strongly_typed_enumerations.Class2_Struct1_Enum14_Val3, val); +#val = enumCheck(cpp11_strongly_typed_enumerations.Class2_Struct1_Enum14_Val4, val); +#val = enumCheck(cpp11_strongly_typed_enumerations.Class2_Struct1_Enum14_Val5m, 4141); +#val = enumCheck(cpp11_strongly_typed_enumerations.Class2_Struct1_Enum14_Val6m, val); + +class1 = Class1(); +enumCheck(class1.class1Test1(cpp11_strongly_typed_enumerations.Enum1_Val5a), 13); +enumCheck(class1.class1Test2(cpp11_strongly_typed_enumerations.Class1_Enum12_Val5c), 1121); +#enumCheck(class1.class1Test3(cpp11_strongly_typed_enumerations.Class1_Struct1_Enum12_Val5f), 3121); + +enumCheck(cpp11_strongly_typed_enumerations.globalTest1(cpp11_strongly_typed_enumerations.Enum1_Val5a), 13); +enumCheck(cpp11_strongly_typed_enumerations.globalTest2(cpp11_strongly_typed_enumerations.Class1_Enum12_Val5c), 1121); +#enumCheck(globalTest3(cpp11_strongly_typed_enumerations.Class1_Struct1_Enum12_Val5f), 3121); + -- cgit v1.2.1 From 3d85dfba9a3af5926974436322740f6228b6e6eb Mon Sep 17 00:00:00 2001 From: William S Fulton Date: Tue, 2 Dec 2014 19:59:59 +0000 Subject: Add c++11 strongly typed enums runtime test for Javascript --- .../cpp11_strongly_typed_enumerations_runme.js | 165 +++++++++++++++++++++ 1 file changed, 165 insertions(+) create mode 100644 Examples/test-suite/javascript/cpp11_strongly_typed_enumerations_runme.js diff --git a/Examples/test-suite/javascript/cpp11_strongly_typed_enumerations_runme.js b/Examples/test-suite/javascript/cpp11_strongly_typed_enumerations_runme.js new file mode 100644 index 000000000..ad9d4e883 --- /dev/null +++ b/Examples/test-suite/javascript/cpp11_strongly_typed_enumerations_runme.js @@ -0,0 +1,165 @@ +var cpp11_strongly_typed_enumerations = require("cpp11_strongly_typed_enumerations"); + +function enumCheck(actual, expected) { + if (actual != expected) { + throw new Error("Enum value mismatch. Expected: " + expected + " Actual: " + actual); + } + return expected + 1; +} + +val = 0; +val = enumCheck(cpp11_strongly_typed_enumerations.Enum1_Val1, val); +val = enumCheck(cpp11_strongly_typed_enumerations.Enum1_Val2, val); +val = enumCheck(cpp11_strongly_typed_enumerations.Enum1_Val3, 13); +val = enumCheck(cpp11_strongly_typed_enumerations.Enum1_Val4, val); +val = enumCheck(cpp11_strongly_typed_enumerations.Enum1_Val5a, 13); +val = enumCheck(cpp11_strongly_typed_enumerations.Enum1_Val6a, val); + +val = 0; +val = enumCheck(cpp11_strongly_typed_enumerations.Enum2_Val1, val); +val = enumCheck(cpp11_strongly_typed_enumerations.Enum2_Val2, val); +val = enumCheck(cpp11_strongly_typed_enumerations.Enum2_Val3, 23); +val = enumCheck(cpp11_strongly_typed_enumerations.Enum2_Val4, val); +val = enumCheck(cpp11_strongly_typed_enumerations.Enum2_Val5b, 23); +val = enumCheck(cpp11_strongly_typed_enumerations.Enum2_Val6b, val); + +val = 0; +val = enumCheck(cpp11_strongly_typed_enumerations.Val1, val); +val = enumCheck(cpp11_strongly_typed_enumerations.Val2, val); +val = enumCheck(cpp11_strongly_typed_enumerations.Val3, 43); +val = enumCheck(cpp11_strongly_typed_enumerations.Val4, val); + +val = 0; +val = enumCheck(cpp11_strongly_typed_enumerations.Enum5_Val1, val); +val = enumCheck(cpp11_strongly_typed_enumerations.Enum5_Val2, val); +val = enumCheck(cpp11_strongly_typed_enumerations.Enum5_Val3, 53); +val = enumCheck(cpp11_strongly_typed_enumerations.Enum5_Val4, val); + +val = 0; +val = enumCheck(cpp11_strongly_typed_enumerations.Enum6_Val1, val); +val = enumCheck(cpp11_strongly_typed_enumerations.Enum6_Val2, val); +val = enumCheck(cpp11_strongly_typed_enumerations.Enum6_Val3, 63); +val = enumCheck(cpp11_strongly_typed_enumerations.Enum6_Val4, val); + +val = 0; +val = enumCheck(cpp11_strongly_typed_enumerations.Enum7td_Val1, val); +val = enumCheck(cpp11_strongly_typed_enumerations.Enum7td_Val2, val); +val = enumCheck(cpp11_strongly_typed_enumerations.Enum7td_Val3, 73); +val = enumCheck(cpp11_strongly_typed_enumerations.Enum7td_Val4, val); + +val = 0; +val = enumCheck(cpp11_strongly_typed_enumerations.Enum8_Val1, val); +val = enumCheck(cpp11_strongly_typed_enumerations.Enum8_Val2, val); +val = enumCheck(cpp11_strongly_typed_enumerations.Enum8_Val3, 83); +val = enumCheck(cpp11_strongly_typed_enumerations.Enum8_Val4, val); + +val = 0; +val = enumCheck(cpp11_strongly_typed_enumerations.Enum10_Val1, val); +val = enumCheck(cpp11_strongly_typed_enumerations.Enum10_Val2, val); +val = enumCheck(cpp11_strongly_typed_enumerations.Enum10_Val3, 103); +val = enumCheck(cpp11_strongly_typed_enumerations.Enum10_Val4, val); + +val = 0; +val = enumCheck(cpp11_strongly_typed_enumerations.Class1.Enum12_Val1, 1121); +val = enumCheck(cpp11_strongly_typed_enumerations.Class1.Enum12_Val2, 1122); +val = enumCheck(cpp11_strongly_typed_enumerations.Class1.Enum12_Val3, val); +val = enumCheck(cpp11_strongly_typed_enumerations.Class1.Enum12_Val4, val); +val = enumCheck(cpp11_strongly_typed_enumerations.Class1.Enum12_Val5c, 1121); +val = enumCheck(cpp11_strongly_typed_enumerations.Class1.Enum12_Val6c, val); + +val = 0; +val = enumCheck(cpp11_strongly_typed_enumerations.Class1.Val1, 1131); +val = enumCheck(cpp11_strongly_typed_enumerations.Class1.Val2, 1132); +val = enumCheck(cpp11_strongly_typed_enumerations.Class1.Val3, val); +val = enumCheck(cpp11_strongly_typed_enumerations.Class1.Val4, val); +val = enumCheck(cpp11_strongly_typed_enumerations.Class1.Val5d, 1131); +val = enumCheck(cpp11_strongly_typed_enumerations.Class1.Val6d, val); + +val = 0; +val = enumCheck(cpp11_strongly_typed_enumerations.Class1.Enum14_Val1, 1141); +val = enumCheck(cpp11_strongly_typed_enumerations.Class1.Enum14_Val2, 1142); +val = enumCheck(cpp11_strongly_typed_enumerations.Class1.Enum14_Val3, val); +val = enumCheck(cpp11_strongly_typed_enumerations.Class1.Enum14_Val4, val); +val = enumCheck(cpp11_strongly_typed_enumerations.Class1.Enum14_Val5e, 1141); +val = enumCheck(cpp11_strongly_typed_enumerations.Class1.Enum14_Val6e, val); + +// Requires nested class support to work +//val = 0; +//val = enumCheck(cpp11_strongly_typed_enumerations.Class1.Struct1.Enum12_Val1, 3121); +//val = enumCheck(cpp11_strongly_typed_enumerations.Class1.Struct1.Enum12_Val2, 3122); +//val = enumCheck(cpp11_strongly_typed_enumerations.Class1.Struct1.Enum12_Val3, val); +//val = enumCheck(cpp11_strongly_typed_enumerations.Class1.Struct1.Enum12_Val4, val); +//val = enumCheck(cpp11_strongly_typed_enumerations.Class1.Struct1.Enum12_Val5f, 3121); +//val = enumCheck(cpp11_strongly_typed_enumerations.Class1.Struct1.Enum12_Val6f, val); +// +//val = 0; +//val = enumCheck(cpp11_strongly_typed_enumerations.Class1.Struct1.Val1, 3131); +//val = enumCheck(cpp11_strongly_typed_enumerations.Class1.Struct1.Val2, 3132); +//val = enumCheck(cpp11_strongly_typed_enumerations.Class1.Struct1.Val3, val); +//val = enumCheck(cpp11_strongly_typed_enumerations.Class1.Struct1.Val4, val); +// +//val = 0; +//val = enumCheck(cpp11_strongly_typed_enumerations.Class1.Struct1.Enum14_Val1, 3141); +//val = enumCheck(cpp11_strongly_typed_enumerations.Class1.Struct1.Enum14_Val2, 3142); +//val = enumCheck(cpp11_strongly_typed_enumerations.Class1.Struct1.Enum14_Val3, val); +//val = enumCheck(cpp11_strongly_typed_enumerations.Class1.Struct1.Enum14_Val4, val); +//val = enumCheck(cpp11_strongly_typed_enumerations.Class1.Struct1.Enum14_Val5g, 3141); +//val = enumCheck(cpp11_strongly_typed_enumerations.Class1.Struct1.Enum14_Val6g, val); + +val = 0; +val = enumCheck(cpp11_strongly_typed_enumerations.Class2.Enum12_Val1, 2121); +val = enumCheck(cpp11_strongly_typed_enumerations.Class2.Enum12_Val2, 2122); +val = enumCheck(cpp11_strongly_typed_enumerations.Class2.Enum12_Val3, val); +val = enumCheck(cpp11_strongly_typed_enumerations.Class2.Enum12_Val4, val); +val = enumCheck(cpp11_strongly_typed_enumerations.Class2.Enum12_Val5h, 2121); +val = enumCheck(cpp11_strongly_typed_enumerations.Class2.Enum12_Val6h, val); + +val = 0; +val = enumCheck(cpp11_strongly_typed_enumerations.Class2.Val1, 2131); +val = enumCheck(cpp11_strongly_typed_enumerations.Class2.Val2, 2132); +val = enumCheck(cpp11_strongly_typed_enumerations.Class2.Val3, val); +val = enumCheck(cpp11_strongly_typed_enumerations.Class2.Val4, val); +val = enumCheck(cpp11_strongly_typed_enumerations.Class2.Val5i, 2131); +val = enumCheck(cpp11_strongly_typed_enumerations.Class2.Val6i, val); + +val = 0; +val = enumCheck(cpp11_strongly_typed_enumerations.Class2.Enum14_Val1, 2141); +val = enumCheck(cpp11_strongly_typed_enumerations.Class2.Enum14_Val2, 2142); +val = enumCheck(cpp11_strongly_typed_enumerations.Class2.Enum14_Val3, val); +val = enumCheck(cpp11_strongly_typed_enumerations.Class2.Enum14_Val4, val); +val = enumCheck(cpp11_strongly_typed_enumerations.Class2.Enum14_Val5j, 2141); +val = enumCheck(cpp11_strongly_typed_enumerations.Class2.Enum14_Val6j, val); + +// Requires nested class support to work +//val = 0; +//val = enumCheck(cpp11_strongly_typed_enumerations.Class2.Struct1_Enum12_Val1, 4121); +//val = enumCheck(cpp11_strongly_typed_enumerations.Class2.Struct1_Enum12_Val2, 4122); +//val = enumCheck(cpp11_strongly_typed_enumerations.Class2.Struct1_Enum12_Val3, val); +//val = enumCheck(cpp11_strongly_typed_enumerations.Class2.Struct1_Enum12_Val4, val); +//val = enumCheck(cpp11_strongly_typed_enumerations.Class2.Struct1_Enum12_Val5k, 4121); +//val = enumCheck(cpp11_strongly_typed_enumerations.Class2.Struct1_Enum12_Val6k, val); +// +//val = 0; +//val = enumCheck(cpp11_strongly_typed_enumerations.Class2.Struct1_Val1, 4131); +//val = enumCheck(cpp11_strongly_typed_enumerations.Class2.Struct1_Val2, 4132); +//val = enumCheck(cpp11_strongly_typed_enumerations.Class2.Struct1_Val3, val); +//val = enumCheck(cpp11_strongly_typed_enumerations.Class2.Struct1_Val4, val); +//val = enumCheck(cpp11_strongly_typed_enumerations.Class2.Struct1_Val5l, 4131); +//val = enumCheck(cpp11_strongly_typed_enumerations.Class2.Struct1_Val6l, val); +// +//val = 0; +//val = enumCheck(cpp11_strongly_typed_enumerations.Class2.Struct1_Enum14_Val1, 4141); +//val = enumCheck(cpp11_strongly_typed_enumerations.Class2.Struct1_Enum14_Val2, 4142); +//val = enumCheck(cpp11_strongly_typed_enumerations.Class2.Struct1_Enum14_Val3, val); +//val = enumCheck(cpp11_strongly_typed_enumerations.Class2.Struct1_Enum14_Val4, val); +//val = enumCheck(cpp11_strongly_typed_enumerations.Class2.Struct1_Enum14_Val5m, 4141); +//val = enumCheck(cpp11_strongly_typed_enumerations.Class2.Struct1_Enum14_Val6m, val); + +class1 = new cpp11_strongly_typed_enumerations.Class1(); +enumCheck(class1.class1Test1(cpp11_strongly_typed_enumerations.Enum1_Val5a), 13); +enumCheck(class1.class1Test2(cpp11_strongly_typed_enumerations.Class1.Enum12_Val5c), 1121); +//enumCheck(class1.class1Test3(cpp11_strongly_typed_enumerations.Class1.Struct1_Enum12_Val5f), 3121); + +enumCheck(cpp11_strongly_typed_enumerations.globalTest1(cpp11_strongly_typed_enumerations.Enum1_Val5a), 13); +enumCheck(cpp11_strongly_typed_enumerations.globalTest2(cpp11_strongly_typed_enumerations.Class1.Enum12_Val5c), 1121); +//enumCheck(globalTest3(cpp11_strongly_typed_enumerations.Class1.Struct1_Enum12_Val5f), 3121); -- cgit v1.2.1 From 5b480847dd5fbc6b98a41154c70ac1806cfd25d9 Mon Sep 17 00:00:00 2001 From: William S Fulton Date: Thu, 4 Dec 2014 06:23:43 +0000 Subject: Improve Javascript Webkit detection pkg-config detection was missing. Use pkg-config for the link flags. --- configure.ac | 44 +++++++++++++++----------------------------- 1 file changed, 15 insertions(+), 29 deletions(-) diff --git a/configure.ac b/configure.ac index b05933527..4633f8ed0 100644 --- a/configure.ac +++ b/configure.ac @@ -461,6 +461,8 @@ fi]) AC_ARG_WITH(alllang, AS_HELP_STRING([--without-alllang], [Disable all languages]), with_alllang="$withval") +AC_CHECK_PROGS(PKGCONFIG, [pkg-config]) + #-------------------------------------------------------------------- # Look for Tcl #-------------------------------------------------------------------- @@ -1203,37 +1205,21 @@ else # check for JavaScriptCore/Webkit libraries AC_ARG_WITH(jscorelib,[ --with-jsclib =path Set location of the JavaScriptCore/Webkit library directory],[JSCORELIB="-L$withval"], [JSCORELIB=]) - AC_MSG_CHECKING(for JavaScriptCore/Webkit library) - - # look for the library when not provided - if test -z "$JSCORELIB"; then - case $host in - *-*-linux*) - dirs="/usr/lib64/ /usr/local/lib64/ /usr/lib/ /usr/local/lib/" - for i in $dirs ; do - if test -r $i/libjavascriptcoregtk-1.0.so; then - AC_MSG_RESULT($i) - JSCORELIB="-L$i -ljavascriptcoregtk-1.0" - JSCOREVERSION=`pkg-config --modversion javascriptcoregtk-1.0` - break - fi - done - if test -z "$JSCORELIB"; then - AC_MSG_RESULT(not found) - JSCENABLED= - else - JSCOREDYNAMICLINKING="$JSCORELIB" - JSCENABLED=1 - fi - ;; - *-*-darwin*) - JSCOREDYNAMICLINKING="-framework JavaScriptCore" + if test -z "$JSCORELIB" -a -n "$PKGCONFIG"; then + AC_MSG_CHECKING(for JavaScriptCore/Webkit library) + if pkg-config javascriptcoregtk-1.0; then + JSCORELIB=`$PKGCONFIG --libs javascriptcoregtk-1.0` + JSCOREVERSION=`$PKGCONFIG --modversion javascriptcoregtk-1.0` + fi + if test -z "$JSCORELIB"; then + AC_MSG_RESULT(not found) + JSCENABLED= + else + AC_MSG_RESULT([$JSCORELIB]) + JSCOREDYNAMICLINKING="$JSCORELIB" JSCENABLED=1 - ;; - *) - ;; - esac + fi fi #---------------------------------------------------------------- -- cgit v1.2.1 From 1509d6c9e0c35d8fffd20ff8f93bd9cdabf095b4 Mon Sep 17 00:00:00 2001 From: Alexey Neyman Date: Sat, 6 Dec 2014 21:38:58 +0000 Subject: Add clarification on _global_ prefix. --- Doc/Manual/Typemaps.html | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/Doc/Manual/Typemaps.html b/Doc/Manual/Typemaps.html index 5cb6b0bbf..e4da514bb 100644 --- a/Doc/Manual/Typemaps.html +++ b/Doc/Manual/Typemaps.html @@ -2050,6 +2050,10 @@ wrap_foo() {
    +

    There is an exception: if the variable name starts with the _global_ prefix, +the argument number is not appended. Such variables can be used throughout the generated +wrapper function.

    +

    Some typemaps do not recognize local variables (or they may simply not apply). At this time, only typemaps that apply to argument conversion support this (input typemaps such as the "in" typemap). -- cgit v1.2.1 From 427c5112e725a9d9be1e337d75e39d56dc392c0e Mon Sep 17 00:00:00 2001 From: William S Fulton Date: Sat, 6 Dec 2014 21:49:42 +0000 Subject: Add more docs about _global_ prefix in typemap temporary variables --- Doc/Manual/Typemaps.html | 14 +++++++++++++- 1 file changed, 13 insertions(+), 1 deletion(-) diff --git a/Doc/Manual/Typemaps.html b/Doc/Manual/Typemaps.html index e4da514bb..040244d45 100644 --- a/Doc/Manual/Typemaps.html +++ b/Doc/Manual/Typemaps.html @@ -2052,7 +2052,19 @@ wrap_foo() {

    There is an exception: if the variable name starts with the _global_ prefix, the argument number is not appended. Such variables can be used throughout the generated -wrapper function.

    +wrapper function. For example, the above typemap could be rewritten to use _global_temp +instead of temp and the generated code would then contain a single _global_temp variable +instead of temp1, temp2 and temp3: +

    + +
    +
    +%typemap(in) std::string * (std::string _global_temp) {
    + ... as above ...
    +}
    +
    +
    +

    Some typemaps do not recognize local variables (or they may simply not -- cgit v1.2.1 From 8c77d4be899d29464076211dc2a4081080239e45 Mon Sep 17 00:00:00 2001 From: William S Fulton Date: Sun, 7 Dec 2014 17:10:07 +0000 Subject: Document new C++11 strongly typed enumerations support. --- CHANGES.current | 3 +++ Doc/Manual/CPlusPlus11.html | 62 ++++++++++++++++++++++----------------------- 2 files changed, 34 insertions(+), 31 deletions(-) diff --git a/CHANGES.current b/CHANGES.current index aff98df24..9304d636a 100644 --- a/CHANGES.current +++ b/CHANGES.current @@ -5,6 +5,9 @@ See the RELEASENOTES file for a summary of changes in each release. Version 3.0.3 (in progress) =========================== +2014-12-07: wsfulton + Add support for C++11 strongly typed enumerations. + 2014-11-21: wsfulton [Java C#] Fix multiply defined error when using %rename of enum items when using the "simple enum" wrappers. diff --git a/Doc/Manual/CPlusPlus11.html b/Doc/Manual/CPlusPlus11.html index 04c40a6d6..b7e1d638c 100644 --- a/Doc/Manual/CPlusPlus11.html +++ b/Doc/Manual/CPlusPlus11.html @@ -495,59 +495,59 @@ struct DerivedStruct : BaseStruct {

    7.2.13 Strongly typed enumerations

    -

    SWIG parses the new enum class syntax and forward declarator for the enums:

    +

    SWIG supports strongly typed enumerations and parses the new enum class syntax and forward declarator for the enums, such as:

     enum class MyEnum : unsigned int;
     
    -

    The strongly typed enumerations are treated the same as the ordinary and anonymous enums. -This is because the required nested class support in SWIG is new and has not yet been incorporated into the wrapping of these strongly typed enum classes. -This is usually not a problem, however, -there may be some name clashes. For example, the following code:

    +

    +Strongly typed enums are often used to avoid name clashes such as the following: +

     struct Color {
    -  enum class PrintingColors : unsigned int {
    -    Cyan, Magenta, Yellow, Black
    +  enum class RainbowColors : unsigned int {
    +    Red, Orange, Yellow, Green, Blue, Indigo, Violet
       };
       
    -  enum class BasicColors {
    -    Red, Green, Blue
    +  enum class WarmColors {
    +    Yellow, Orange, Red
       };
    -  
    -  enum class AllColors {
    -    // produces warnings because of duplicate names
    -    Yellow, Orange, Red, Magenta, Blue, Cyan, Green, Pink, Black, White
    +
    +  // Note normal enum
    +  enum PrimeColors {
    +    Red=100, Green, Blue
       };
     };
     
    -

    A workaround is to write these as a series of separate classes containing anonymous enums:

    +

    +There are various ways that the target languages handle enums, so it is not possible to precisely state how they are handled in this section. +However, generally, most scripting languages mangle in the strongly typed enumeration's class name, +but do not use any additional mangling for normal enumerations. For example, in Python, the following code +

    -
    -struct PrintingColors {
    -  enum : unsigned int {
    -    Cyan, Magenta, Yellow, Black
    -  };
    -};
    +
    +print Color.RainbowColors_Red, Color.WarmColors_Red, Color.Red
    +
    -struct BasicColors { - enum : unsigned int { - Red, Green, Blue - }; -}; +

    +results in +

    -struct AllColors { - enum : unsigned int { - Yellow, Orange, Red, Magenta, Blue, Cyan, Green, Pink, Black, White - }; -}; +
    +0 2 100
     

    -Expect to see this improved in a future version of SWIG. +The strongly typed languages often wrap normal enums into an enum class and so treat normal enums and strongly typed enums the same. +The equivalent in Java is:

    +
    +System.out.println(Color.RainbowColors.Red.swigValue() + " " + Color.WarmColors.Red.swigValue() + " " + Color.PrimeColors.Red.swigValue());
    +
    +

    7.2.14 Double angle brackets

    -- cgit v1.2.1 From 7f8bb02d78fe8ab3bff62f9cfd7a2c5b9825516c Mon Sep 17 00:00:00 2001 From: William S Fulton Date: Sun, 7 Dec 2014 20:27:29 +0000 Subject: Fix regression in introduced in merge of C++11 strongly typed enums support - Guile constants bad casts generated - Go non-public enum value wrappers assert failure Also cosmetic test comment correction --- .../test-suite/csharp/cpp11_strongly_typed_enumerations_runme.cs | 3 --- Source/Modules/go.cxx | 7 ++++--- Source/Modules/guile.cxx | 2 +- 3 files changed, 5 insertions(+), 7 deletions(-) diff --git a/Examples/test-suite/csharp/cpp11_strongly_typed_enumerations_runme.cs b/Examples/test-suite/csharp/cpp11_strongly_typed_enumerations_runme.cs index f0f48f0bc..f2c25e7a2 100644 --- a/Examples/test-suite/csharp/cpp11_strongly_typed_enumerations_runme.cs +++ b/Examples/test-suite/csharp/cpp11_strongly_typed_enumerations_runme.cs @@ -1,6 +1,3 @@ - -// This is the bool runtime testcase. It checks that the C++ bool type works. - using System; using cpp11_strongly_typed_enumerationsNamespace; diff --git a/Source/Modules/go.cxx b/Source/Modules/go.cxx index 20a8650ef..eac83a5a5 100644 --- a/Source/Modules/go.cxx +++ b/Source/Modules/go.cxx @@ -1959,12 +1959,13 @@ private: * ------------------------------------------------------------------------ */ virtual int enumvalueDeclaration(Node *n) { - Swig_require("enumvalueDeclaration", n, "*sym:name", NIL); - Node *parent = parentNode(n); - if (!is_public(n)) { return SWIG_OK; } + + Swig_require("enumvalueDeclaration", n, "*sym:name", NIL); + Node *parent = parentNode(n); + if (Getattr(parent, "unnamed")) { Setattr(n, "type", NewString("int")); } else { diff --git a/Source/Modules/guile.cxx b/Source/Modules/guile.cxx index ce8d19c06..1c135b53d 100644 --- a/Source/Modules/guile.cxx +++ b/Source/Modules/guile.cxx @@ -1350,7 +1350,7 @@ public: Printv(f_header, tm, "\n", NIL); } else { // Create variable and assign it a value - Printf(f_header, "static %s = (%s)%s;\n", SwigType_str(type, var_name), type, rvalue); + Printf(f_header, "static %s = (%s)(%s);\n", SwigType_str(type, var_name), SwigType_str(type, 0), rvalue); } { /* Hack alert: will cleanup later -- Dave */ -- cgit v1.2.1 From 9cbdf69fdc3554a5d3c1bc8c3a0fbe7e3c182254 Mon Sep 17 00:00:00 2001 From: William S Fulton Date: Sun, 7 Dec 2014 21:53:17 +0000 Subject: Correctly detect Go1 during configure --- configure.ac | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/configure.ac b/configure.ac index 4633f8ed0..40eeb5a18 100644 --- a/configure.ac +++ b/configure.ac @@ -2297,7 +2297,7 @@ else go_version=$($GO $GOVERSIONOPTION | sed -e 's/go version //') AC_MSG_CHECKING([whether go version is too old]) case $go_version in - go1.0*) + go1.0* | go1 ) AC_MSG_RESULT([yes - minimum version is 1.1]) GO= GOOPT="-intgosize 32" @@ -2312,7 +2312,7 @@ else ;; esac case $go_version in - go1.0* | go1.1*) + go1.0* | go1 | go1.1*) GOOPT="$GOOPT -use-shlib" ;; go1.2*) -- cgit v1.2.1 From ae555c2339aba9d677bc3da813848c93142cb500 Mon Sep 17 00:00:00 2001 From: William S Fulton Date: Tue, 9 Dec 2014 23:31:07 +0000 Subject: Fix templated constructors regression Templated constructors were incorrectly ignored because SWIG thought they were methods without a return type. Regression introduced in swig-3.0.0 Closes #245. --- CHANGES.current | 5 +++ Examples/test-suite/common.mk | 1 + .../template_templated_constructors_runme.java | 26 ++++++++++++ .../test-suite/template_templated_constructors.i | 47 ++++++++++++++++++++++ Source/Modules/lang.cxx | 3 +- 5 files changed, 81 insertions(+), 1 deletion(-) create mode 100644 Examples/test-suite/java/template_templated_constructors_runme.java create mode 100644 Examples/test-suite/template_templated_constructors.i diff --git a/CHANGES.current b/CHANGES.current index 9304d636a..941e575a7 100644 --- a/CHANGES.current +++ b/CHANGES.current @@ -5,6 +5,11 @@ See the RELEASENOTES file for a summary of changes in each release. Version 3.0.3 (in progress) =========================== +2014-12-09: wsfulton + Fix #245 - regression (since swig-3.0.0) in templated constructors. + Templated constructors could not be instantiated - they were incorrectly ignored with a warning 504: + "Function: xyz must have a return type. Ignored." + 2014-12-07: wsfulton Add support for C++11 strongly typed enumerations. diff --git a/Examples/test-suite/common.mk b/Examples/test-suite/common.mk index c1cef0bcc..d4f34a707 100644 --- a/Examples/test-suite/common.mk +++ b/Examples/test-suite/common.mk @@ -382,6 +382,7 @@ CPP_TEST_CASES += \ template_classes \ template_const_ref \ template_construct \ + template_templated_constructors \ template_default \ template_default2 \ template_default_arg \ diff --git a/Examples/test-suite/java/template_templated_constructors_runme.java b/Examples/test-suite/java/template_templated_constructors_runme.java new file mode 100644 index 000000000..cd3f31d21 --- /dev/null +++ b/Examples/test-suite/java/template_templated_constructors_runme.java @@ -0,0 +1,26 @@ + +import template_templated_constructors.*; + +public class template_templated_constructors_runme { + + static { + try { + System.loadLibrary("template_templated_constructors"); + } 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[]) { + TConstructor1 t1 = new TConstructor1(123); + TConstructor2 t2a = new TConstructor2(); + TConstructor2 t2b = new TConstructor2(123); + + TClass1Int tc1 = new TClass1Int(123.4); + TClass2Int tc2a = new TClass2Int(); + TClass2Int tc2b = new TClass2Int(123.4); + + } +} + diff --git a/Examples/test-suite/template_templated_constructors.i b/Examples/test-suite/template_templated_constructors.i new file mode 100644 index 000000000..ee9df94bb --- /dev/null +++ b/Examples/test-suite/template_templated_constructors.i @@ -0,0 +1,47 @@ +%module template_templated_constructors + +%inline %{ +namespace ConstructSpace { + +class TConstructor1 { +public: + template TConstructor1(T val) {} + ~TConstructor1() {} +}; + +class TConstructor2 { +public: + TConstructor2() {} + template TConstructor2(T val) {} + ~TConstructor2() {} +}; + +template class TClass1 { +public: + template TClass1(Y t) {} +}; + +template class TClass2 { +public: + TClass2() {} + template TClass2(Y t) {} +}; + +} +%} + +%extend ConstructSpace::TConstructor1 { + %template(TConstructor1) TConstructor1; +} + +%template(TConstructor2) ConstructSpace::TConstructor2::TConstructor2; + +%template(TClass1Int) ConstructSpace::TClass1; +%extend ConstructSpace::TClass1 { + %template(TClass1Int) TClass1; +} + +%template(TClass2Int) ConstructSpace::TClass2; +%extend ConstructSpace::TClass2 { + %template(TClass2Int) TClass2; +} diff --git a/Source/Modules/lang.cxx b/Source/Modules/lang.cxx index c90e3dece..3efd4e425 100644 --- a/Source/Modules/lang.cxx +++ b/Source/Modules/lang.cxx @@ -2694,7 +2694,8 @@ int Language::constructorDeclaration(Node *n) { String *scope = Swig_scopename_check(ClassName) ? Swig_scopename_prefix(ClassName) : 0; String *actual_name = scope ? NewStringf("%s::%s", scope, name) : NewString(name); Delete(scope); - if (!Equal(actual_name, expected_name) && !SwigType_istemplate(expected_name)) { + if (!Equal(actual_name, expected_name) && !SwigType_istemplate(expected_name) && !SwigType_istemplate(actual_name)) { + // Checking templates is skipped but they ought to be checked... they are just somewhat more tricky to check correctly bool illegal_name = true; if (Extend) { // Check for typedef names used as a constructor name in %extend. This is deprecated except for anonymous -- cgit v1.2.1 From cb53e3063bdd6476f91b2a1accfcba947341fc92 Mon Sep 17 00:00:00 2001 From: Vadim Zeitlin Date: Tue, 16 Dec 2014 17:05:10 +0100 Subject: Add PEP8_FLAGS variable to the test suite Python makefile. Put pep8 options into this variable to avoid repeating them twice. No real changes. --- Examples/test-suite/python/Makefile.in | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/Examples/test-suite/python/Makefile.in b/Examples/test-suite/python/Makefile.in index c79a786da..3b237475c 100644 --- a/Examples/test-suite/python/Makefile.in +++ b/Examples/test-suite/python/Makefile.in @@ -11,6 +11,7 @@ endif LANGUAGE = python PYTHON = $(PYBIN) PEP8 = @PEP8@ +PEP8_FLAGS = --ignore=E501,E30,W291,W391 #*_runme.py for Python 2.x, *_runme3.py for Python 3.x PY2SCRIPTSUFFIX = _runme.py @@ -126,13 +127,13 @@ py3_runme = $(SCRIPTPREFIX)$*$(PY3SCRIPTSUFFIX) check_pep8 = \ if [ -n "$(PEP8)" ]; then \ - $(PEP8) --ignore=E501,E30,W291,W391 $(SCRIPTPREFIX)$*.py;\ + $(PEP8) $(PEP8_FLAGS) $(SCRIPTPREFIX)$*.py;\ fi check_pep8_multi_cpp = \ if [ -n "$(PEP8)" ]; then \ for f in `cat $(top_srcdir)/$(EXAMPLES)/$(TEST_SUITE)/$*.list` ; do \ - $(PEP8) --ignore=E501,E30,W291,W391 $$f.py; \ + $(PEP8) $(PEP8_FLAGS) $$f.py; \ done \ fi -- cgit v1.2.1 From e12a1d7671e1a3876c2990ed7c0b36d37cf992d2 Mon Sep 17 00:00:00 2001 From: Vadim Zeitlin Date: Tue, 16 Dec 2014 17:05:53 +0100 Subject: Ignore E402 (import not on top of file) PEP8 error. Travis uses the latest pep8 sources from Git and since https://github.com/jcrocholl/pep8/commit/f3a12babd4278f8f7a529a9d1d63d56faf071cf8 this error is given for all Python files generated by SWIG with -builtin option. --- Examples/test-suite/python/Makefile.in | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Examples/test-suite/python/Makefile.in b/Examples/test-suite/python/Makefile.in index 3b237475c..82a0e9db1 100644 --- a/Examples/test-suite/python/Makefile.in +++ b/Examples/test-suite/python/Makefile.in @@ -11,7 +11,7 @@ endif LANGUAGE = python PYTHON = $(PYBIN) PEP8 = @PEP8@ -PEP8_FLAGS = --ignore=E501,E30,W291,W391 +PEP8_FLAGS = --ignore=E402,E501,E30,W291,W391 #*_runme.py for Python 2.x, *_runme3.py for Python 3.x PY2SCRIPTSUFFIX = _runme.py -- cgit v1.2.1 From 2e01533b23cfff7f90bf45c6608ee5112e57242a Mon Sep 17 00:00:00 2001 From: William S Fulton Date: Thu, 18 Dec 2014 06:37:49 +0000 Subject: Partial support for %constant and structs Test case is slightly modified from the test case in issue #250 Use of constant objects does not seem to work in Python - the type is SwigPyObject instead of constant_directive.Type1. --- Examples/test-suite/common.mk | 1 + .../test-suite/java/constant_directive_runme.java | 22 ++++++++++++++++++++++ Source/Modules/csharp.cxx | 11 ----------- Source/Modules/d.cxx | 11 ----------- Source/Modules/java.cxx | 13 +------------ Source/Modules/modula3.cxx | 13 ------------- Source/Swig/cwrap.c | 9 ++++++++- 7 files changed, 32 insertions(+), 48 deletions(-) create mode 100644 Examples/test-suite/java/constant_directive_runme.java diff --git a/Examples/test-suite/common.mk b/Examples/test-suite/common.mk index d4f34a707..314894598 100644 --- a/Examples/test-suite/common.mk +++ b/Examples/test-suite/common.mk @@ -143,6 +143,7 @@ CPP_TEST_CASES += \ class_scope_weird \ compactdefaultargs \ const_const_2 \ + constant_directive \ constant_pointers \ constover \ constructor_copy \ diff --git a/Examples/test-suite/java/constant_directive_runme.java b/Examples/test-suite/java/constant_directive_runme.java new file mode 100644 index 000000000..b5135a499 --- /dev/null +++ b/Examples/test-suite/java/constant_directive_runme.java @@ -0,0 +1,22 @@ +import constant_directive.*; + +public class constant_directive_runme { + + static { + try { + System.loadLibrary("constant_directive"); + } 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[]) { + if (constant_directive.TYPE1_CONSTANT1.getVal() != 1) + throw new RuntimeException("fail"); + if (constant_directive.TYPE1_CONSTANT2.getVal() != 2) + throw new RuntimeException("fail"); + if (constant_directive.TYPE1_CONSTANT3.getVal() != 3) + throw new RuntimeException("fail"); + } +} diff --git a/Source/Modules/csharp.cxx b/Source/Modules/csharp.cxx index 39cab8f0a..3b1e03560 100644 --- a/Source/Modules/csharp.cxx +++ b/Source/Modules/csharp.cxx @@ -914,21 +914,10 @@ public: String *null_attribute = 0; // Now write code to make the function call if (!native_function_flag) { - if (Cmp(nodeType(n), "constant") == 0) { - // Wrapping a constant hack - Swig_save("functionWrapper", n, "wrap:action", NIL); - - // below based on Swig_VargetToFunction() - SwigType *ty = Swig_wrapped_var_type(Getattr(n, "type"), use_naturalvar_mode(n)); - Setattr(n, "wrap:action", NewStringf("%s = (%s)(%s);", Swig_cresult_name(), SwigType_lstr(ty, 0), Getattr(n, "value"))); - } Swig_director_emit_dynamic_cast(n, f); String *actioncode = emit_action(n); - if (Cmp(nodeType(n), "constant") == 0) - Swig_restore(n); - /* Return value if necessary */ if ((tm = Swig_typemap_lookup_out("out", n, Swig_cresult_name(), f, actioncode))) { canThrow(n, "out", n); diff --git a/Source/Modules/d.cxx b/Source/Modules/d.cxx index da31504e6..8546372ea 100644 --- a/Source/Modules/d.cxx +++ b/Source/Modules/d.cxx @@ -1701,21 +1701,10 @@ public: String *null_attribute = 0; // Now write code to make the function call if (!native_function_flag) { - if (Cmp(nodeType(n), "constant") == 0) { - // Wrapping a constant hack - Swig_save("functionWrapper", n, "wrap:action", NIL); - - // below based on Swig_VargetToFunction() - SwigType *ty = Swig_wrapped_var_type(Getattr(n, "type"), use_naturalvar_mode(n)); - Setattr(n, "wrap:action", NewStringf("%s = (%s) %s;", Swig_cresult_name(), SwigType_lstr(ty, 0), Getattr(n, "value"))); - } Swig_director_emit_dynamic_cast(n, f); String *actioncode = emit_action(n); - if (Cmp(nodeType(n), "constant") == 0) - Swig_restore(n); - /* Return value if necessary */ if ((tm = Swig_typemap_lookup_out("out", n, Swig_cresult_name(), f, actioncode))) { canThrow(n, "out", n); diff --git a/Source/Modules/java.cxx b/Source/Modules/java.cxx index 440fbf95a..82ecb41a4 100644 --- a/Source/Modules/java.cxx +++ b/Source/Modules/java.cxx @@ -1039,26 +1039,15 @@ public: } } + // Now write code to make the function call if (!native_function_flag) { - if (Cmp(nodeType(n), "constant") == 0) { - // Wrapping a constant hack - Swig_save("functionWrapper", n, "wrap:action", NIL); - // below based on Swig_VargetToFunction() - SwigType *ty = Swig_wrapped_var_type(Getattr(n, "type"), use_naturalvar_mode(n)); - Setattr(n, "wrap:action", NewStringf("%s = (%s)(%s);", Swig_cresult_name(), SwigType_lstr(ty, 0), Getattr(n, "value"))); - } - - // Now write code to make the function call Swig_director_emit_dynamic_cast(n, f); String *actioncode = emit_action(n); // Handle exception classes specified in the "except" feature's "throws" attribute addThrows(n, "feature:except", n); - if (Cmp(nodeType(n), "constant") == 0) - Swig_restore(n); - /* Return value if necessary */ if ((tm = Swig_typemap_lookup_out("out", n, Swig_cresult_name(), f, actioncode))) { addThrows(n, "tmap:out", n); diff --git a/Source/Modules/modula3.cxx b/Source/Modules/modula3.cxx index 2d6f26108..d9a0c922b 100644 --- a/Source/Modules/modula3.cxx +++ b/Source/Modules/modula3.cxx @@ -1407,25 +1407,12 @@ MODULA3(): } } - if (Cmp(nodeType(n), "constant") == 0) { - // Wrapping a constant hack - Swig_save("functionWrapper", n, "wrap:action", NIL); - - // below based on Swig_VargetToFunction() - SwigType *ty = Swig_wrapped_var_type(Getattr(n, "type"), use_naturalvar_mode(n)); - Setattr(n, "wrap:action", NewStringf("%s = (%s)(%s);", Swig_cresult_name(), SwigType_lstr(ty, 0), Getattr(n, "value"))); - } - Setattr(n, "wrap:name", wname); // Now write code to make the function call if (!native_function_flag) { String *actioncode = emit_action(n); - if (Cmp(nodeType(n), "constant") == 0) { - Swig_restore(n); - } - /* Return value if necessary */ String *tm; if ((tm = Swig_typemap_lookup_out("out", n, Swig_cresult_name(), f, actioncode))) { diff --git a/Source/Swig/cwrap.c b/Source/Swig/cwrap.c index c97640b08..9da4e0829 100644 --- a/Source/Swig/cwrap.c +++ b/Source/Swig/cwrap.c @@ -1614,7 +1614,14 @@ int Swig_VargetToFunction(Node *n, int flags) { Delete(mangled); Delete(sname); } else { - String *nname = SwigType_namestr(name); + String *nname = 0; + if (Equal(nodeType(n), "constant")) { + String *rawval = Getattr(n, "rawval"); + String *value = rawval ? rawval : Getattr(n, "value"); + nname = NewStringf("(%s)", value); + } else { + nname = SwigType_namestr(name); + } call = Swig_wrapped_var_assign(type, nname, varcref); cres = Swig_cresult(ty, Swig_cresult_name(), call); Setattr(n, "wrap:action", cres); -- cgit v1.2.1 From 0ad384bb288bcd25347d26c71c4ca5b3c4e0aee5 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Pawe=C5=82=20Tomulik?= Date: Sat, 25 Oct 2014 23:11:37 +0200 Subject: fixed python global object constants Fix for Python and -builtin Fix from Github issue #250 --- Lib/python/pyinit.swg | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/Lib/python/pyinit.swg b/Lib/python/pyinit.swg index b44c2c893..38822e414 100644 --- a/Lib/python/pyinit.swg +++ b/Lib/python/pyinit.swg @@ -401,6 +401,12 @@ SWIG_init(void) { #else m = Py_InitModule((char *) SWIG_name, SwigMethods); #endif + +#ifdef SWIGPYTHON_BUILTIN + PyObject *self = m; + (void)self; +#endif + md = d = PyModule_GetDict(m); (void)md; -- cgit v1.2.1 From 1db561cf0862f39c24960eec31015be3e96730be Mon Sep 17 00:00:00 2001 From: William S Fulton Date: Thu, 18 Dec 2014 06:54:09 +0000 Subject: Improve Python builtin and %constant structs Tweak to previous commit from issue #250 for C compatibility. Set self to zero too. --- Lib/python/pyinit.swg | 7 ++----- 1 file changed, 2 insertions(+), 5 deletions(-) diff --git a/Lib/python/pyinit.swg b/Lib/python/pyinit.swg index 38822e414..47d3d9700 100644 --- a/Lib/python/pyinit.swg +++ b/Lib/python/pyinit.swg @@ -375,6 +375,7 @@ SWIG_init(void) { PyObject *public_interface, *public_symbol; PyObject *this_descr; PyObject *thisown_descr; + PyObject *self = 0; int i; (void)builtin_pytype; @@ -382,6 +383,7 @@ SWIG_init(void) { (void)builtin_basetype; (void)tuple; (void)static_getset; + (void)self; /* metatype is used to implement static member variables. */ metatype_args = Py_BuildValue("(s(O){})", "SwigPyObjectType", &PyType_Type); @@ -402,11 +404,6 @@ SWIG_init(void) { m = Py_InitModule((char *) SWIG_name, SwigMethods); #endif -#ifdef SWIGPYTHON_BUILTIN - PyObject *self = m; - (void)self; -#endif - md = d = PyModule_GetDict(m); (void)md; -- cgit v1.2.1 From 70a04c9ffe172c5449f1c5b9421c2b4bd6cf29df Mon Sep 17 00:00:00 2001 From: William S Fulton Date: Thu, 18 Dec 2014 07:06:52 +0000 Subject: Add in missing constant_directive.i test --- Examples/test-suite/constant_directive.i | 28 ++++++++++++++++++++++++++++ 1 file changed, 28 insertions(+) create mode 100644 Examples/test-suite/constant_directive.i diff --git a/Examples/test-suite/constant_directive.i b/Examples/test-suite/constant_directive.i new file mode 100644 index 000000000..8204720d6 --- /dev/null +++ b/Examples/test-suite/constant_directive.i @@ -0,0 +1,28 @@ +%module constant_directive + +// %constant and struct +%{ + struct Type1 { + Type1(int val = 0) : val(val) {} + int val; + }; + static Type1 TYPE1_CONSTANT1(1); + static Type1 TYPE1_CONST2(2); + static Type1 TYPE1_CONST3(3); +%} + +struct Type1 { + Type1(int val = 0) : val(val) {} + int val; +}; + +%inline %{ +Type1 getType1Instance() { return Type1(111); } +%} + +%constant Type1 TYPE1_CONSTANT1; +%constant Type1 TYPE1_CONSTANT2 = TYPE1_CONST2; +%constant Type1 *TYPE1_CONSTANT3 = &TYPE1_CONST3; + +%constant int TYPE_INT = 0; + -- cgit v1.2.1 From 68a936a63865eced4f9029c28d4fa7a13b538e0e Mon Sep 17 00:00:00 2001 From: William S Fulton Date: Fri, 19 Dec 2014 19:35:38 +0000 Subject: Add testcase for nested inner class deriving from a templated base class and defined outside of the outer class. For languages that don't support nested class support, use flatnested. See issue #270 --- Examples/test-suite/common.mk | 1 + .../java/nested_template_base_runme.java | 27 +++++++++++++++ Examples/test-suite/nested_template_base.i | 38 ++++++++++++++++++++++ .../python/nested_template_base_runme.py | 13 ++++++++ 4 files changed, 79 insertions(+) create mode 100644 Examples/test-suite/java/nested_template_base_runme.java create mode 100644 Examples/test-suite/nested_template_base.i create mode 100644 Examples/test-suite/python/nested_template_base_runme.py diff --git a/Examples/test-suite/common.mk b/Examples/test-suite/common.mk index 314894598..ac2dfd4dd 100644 --- a/Examples/test-suite/common.mk +++ b/Examples/test-suite/common.mk @@ -299,6 +299,7 @@ CPP_TEST_CASES += \ nested_directors \ nested_comment \ nested_scope \ + nested_template_base \ nested_workaround \ newobject1 \ null_pointer \ diff --git a/Examples/test-suite/java/nested_template_base_runme.java b/Examples/test-suite/java/nested_template_base_runme.java new file mode 100644 index 000000000..8404afe04 --- /dev/null +++ b/Examples/test-suite/java/nested_template_base_runme.java @@ -0,0 +1,27 @@ +import nested_template_base.*; + +public class nested_template_base_runme { + + static { + try { + System.loadLibrary("nested_template_base"); + } 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[]) { + OuterC.InnerS ois = new OuterC.InnerS(123); + OuterC.InnerC oic = new OuterC.InnerC(); + + // Check base method is available + if (oic.outer(ois).getVal() != 123) + throw new RuntimeException("Wrong value calling outer"); + + // Check non-derived class using base class + if (oic.innerc().outer(ois).getVal() != 123) + throw new RuntimeException("Wrong value calling innerc"); + + } +} diff --git a/Examples/test-suite/nested_template_base.i b/Examples/test-suite/nested_template_base.i new file mode 100644 index 000000000..65cc715fa --- /dev/null +++ b/Examples/test-suite/nested_template_base.i @@ -0,0 +1,38 @@ +%module nested_template_base + +%inline %{ + template class OuterT { + public: + T outer(T t) { return t; } + }; +%} + +// The %template goes after OuterT and before OuterC as OuterC::InnerC's base is handled inside OuterC +%template(OuterTInnerS) OuterT; + +#if !defined(SWIGCSHARP) && !defined(SWIGJAVA) +%feature("flatnested") OuterC::InnerS; +%feature("flatnested") OuterC::InnerC; +#endif + + +%inline %{ + class OuterC { + public: + class InnerS; + class InnerC; + }; + + struct OuterC::InnerS { + int val; + InnerS(int val = 0) : val(val) {} + }; + + + class OuterC::InnerC : public OuterT { + public: + OuterT& innerc() { + return *this; + } + }; +%} diff --git a/Examples/test-suite/python/nested_template_base_runme.py b/Examples/test-suite/python/nested_template_base_runme.py new file mode 100644 index 000000000..3d54b8391 --- /dev/null +++ b/Examples/test-suite/python/nested_template_base_runme.py @@ -0,0 +1,13 @@ +from nested_template_base import * + + +ois = InnerS(123); +oic = InnerC(); + +# Check base method is available +if (oic.outer(ois).val != 123): + raise RuntimeError("Wrong value calling outer"); + +# Check non-derived class using base class +if (oic.innerc().outer(ois).val != 123): + raise RuntimeError("Wrong value calling innerc"); -- cgit v1.2.1 From 93d58cd3ed1cc2cf0490e95d43eed4e8de62763d Mon Sep 17 00:00:00 2001 From: William S Fulton Date: Sat, 20 Dec 2014 16:56:31 +0000 Subject: Fix use of preprocessor null directive This was broken recently in commit 255c929c5636f54c16261bd92b8eea2005d61b11 for issue #217 --- Examples/test-suite/preproc.i | 17 +++++++++++++++++ Examples/test-suite/python/preproc_runme.py | 2 ++ Source/Preprocessor/cpp.c | 2 ++ 3 files changed, 21 insertions(+) diff --git a/Examples/test-suite/preproc.i b/Examples/test-suite/preproc.i index e052bff28..779c41e97 100644 --- a/Examples/test-suite/preproc.i +++ b/Examples/test-suite/preproc.i @@ -346,3 +346,20 @@ int method(struct TypeNameTraits tnt) { return tnt.val; } %} + +/* Null directive */ +# /* comment 1 */ +# // comment 2 +# /** comment 3 */ +# /* comment 4 */ /*comment 5*/ +# /** comment 6 +# +# more comment 6 */ +# +# +# +int methodX(int x); +%{ +int methodX(int x) { return x+100; } +%} + diff --git a/Examples/test-suite/python/preproc_runme.py b/Examples/test-suite/python/preproc_runme.py index c989294b6..3049f00ab 100644 --- a/Examples/test-suite/python/preproc_runme.py +++ b/Examples/test-suite/python/preproc_runme.py @@ -12,3 +12,5 @@ if preproc.defined != 1: if 2*preproc.one != preproc.two: raise RuntimeError +if preproc.methodX(99) != 199: + raise RuntimeError diff --git a/Source/Preprocessor/cpp.c b/Source/Preprocessor/cpp.c index 1ca549703..b556bce27 100644 --- a/Source/Preprocessor/cpp.c +++ b/Source/Preprocessor/cpp.c @@ -1768,6 +1768,8 @@ String *Preprocessor_parse(String *s) { } } else if (Equal(id, kpp_level)) { Swig_error(Getfile(s), Getline(id), "cpp debug: level = %d, startlevel = %d\n", level, start_level); + } else if (Equal(id, "")) { + /* Null directive */ } else { Swig_error(Getfile(s), Getline(id), "Unknown SWIG preprocessor directive: %s\n", id); } -- cgit v1.2.1 From 31df3077b3a2fcfd50e84289d0ec67bf1ba7cebe Mon Sep 17 00:00:00 2001 From: William S Fulton Date: Sun, 21 Dec 2014 20:41:31 +0000 Subject: nested_scope test fixes for clang --- Examples/test-suite/nested_scope.i | 19 +++++++++++-------- 1 file changed, 11 insertions(+), 8 deletions(-) diff --git a/Examples/test-suite/nested_scope.i b/Examples/test-suite/nested_scope.i index b1515f77f..d89ba6ab7 100644 --- a/Examples/test-suite/nested_scope.i +++ b/Examples/test-suite/nested_scope.i @@ -26,17 +26,23 @@ namespace ns { #endif }; } -#ifndef __clang__ class Outer1 { struct Nested1; public: struct Nested2; +#ifdef __clang__ + struct Nested2 { + int data; + }; +#endif template class Abstract; class Real; }; +#ifndef __clang__ struct Outer1::Nested2 { int data; }; +#endif class Class { public: @@ -47,18 +53,15 @@ namespace ns { template class Class::Abstract { public: virtual void Method() = 0; + virtual ~Abstract() {} }; -#endif %} -#ifndef __clang__ - %template(abstract_int) Class::Abstract ; -#endif + +%template(abstract_int) Class::Abstract ; + %inline %{ -#ifndef __clang__ class Class::Real : public Abstract { public: virtual void Method() {} }; -#endif - %} -- cgit v1.2.1 From 5c57a8c877f88c9388b68067d665c63546244ba0 Mon Sep 17 00:00:00 2001 From: William S Fulton Date: Mon, 22 Dec 2014 20:35:13 +0000 Subject: Warning suppressions in tests --- Examples/test-suite/extend_special_variables.i | 5 ++++- Examples/test-suite/java/smart_pointer_const_overload_runme.java | 2 +- Examples/test-suite/nested_template_base.i | 2 +- Examples/test-suite/python/smart_pointer_const_overload_runme.py | 2 +- Examples/test-suite/smart_pointer_const_overload.i | 2 +- 5 files changed, 8 insertions(+), 5 deletions(-) diff --git a/Examples/test-suite/extend_special_variables.i b/Examples/test-suite/extend_special_variables.i index 9a453597a..1f218a8b9 100644 --- a/Examples/test-suite/extend_special_variables.i +++ b/Examples/test-suite/extend_special_variables.i @@ -28,7 +28,10 @@ namespace Space { %extend Space::ExtendTemplate { - void extending() { $parentclassname tmp; } + void extending() { + $parentclassname tmp; + (void)tmp; + } } %template(ExtendTemplateInt) Space::ExtendTemplate; diff --git a/Examples/test-suite/java/smart_pointer_const_overload_runme.java b/Examples/test-suite/java/smart_pointer_const_overload_runme.java index bb4ae2c8f..9c10dedb2 100644 --- a/Examples/test-suite/java/smart_pointer_const_overload_runme.java +++ b/Examples/test-suite/java/smart_pointer_const_overload_runme.java @@ -41,7 +41,7 @@ public class smart_pointer_const_overload_runme { Assert(f.getAccess() == MUTABLE_ACCESS); // Test static method - b.stat(); + b.statMethod(); Assert(f.getAccess() == CONST_ACCESS); diff --git a/Examples/test-suite/nested_template_base.i b/Examples/test-suite/nested_template_base.i index 65cc715fa..0b0272224 100644 --- a/Examples/test-suite/nested_template_base.i +++ b/Examples/test-suite/nested_template_base.i @@ -19,7 +19,7 @@ %inline %{ class OuterC { public: - class InnerS; + struct InnerS; class InnerC; }; diff --git a/Examples/test-suite/python/smart_pointer_const_overload_runme.py b/Examples/test-suite/python/smart_pointer_const_overload_runme.py index f1be315a5..098e5b4c3 100644 --- a/Examples/test-suite/python/smart_pointer_const_overload_runme.py +++ b/Examples/test-suite/python/smart_pointer_const_overload_runme.py @@ -56,7 +56,7 @@ def test(b, f): raise RuntimeError # Test static method - b.stat() + b.statMethod() if f.access != CONST_ACCESS: raise RuntimeError diff --git a/Examples/test-suite/smart_pointer_const_overload.i b/Examples/test-suite/smart_pointer_const_overload.i index e3b000b52..75a137b73 100644 --- a/Examples/test-suite/smart_pointer_const_overload.i +++ b/Examples/test-suite/smart_pointer_const_overload.i @@ -34,7 +34,7 @@ struct Foo { Foo() : x(0), xp(&x), y(0), yp(&y), access(0) { } int getx() const { return x; } void setx(int x_) { x = x_; } - static void stat() {} + static void statMethod() {} }; %} -- cgit v1.2.1 From 631c3b18d718cfc618c50b074201dfc8f48baf14 Mon Sep 17 00:00:00 2001 From: Michael Schaller Date: Tue, 23 Dec 2014 14:57:02 +0100 Subject: Added auto-generated 'Examples/d/example.mk' to '.gitignore'. --- .gitignore | 1 + 1 file changed, 1 insertion(+) diff --git a/.gitignore b/.gitignore index a1b9d5e94..3bf08798a 100644 --- a/.gitignore +++ b/.gitignore @@ -67,6 +67,7 @@ CCache/config.h CCache/config.log CCache/config.status Examples/Makefile +Examples/d/example.mk Examples/guile/Makefile Examples/test-suite/*/Makefile Examples/xml/Makefile -- cgit v1.2.1 From 0a3fb69a270dd2873ab8e2ed5116a2a18060dcb6 Mon Sep 17 00:00:00 2001 From: Michael Schaller Date: Tue, 23 Dec 2014 16:32:26 +0100 Subject: [Go] Updated Go documentation (examples, runtime.SetFinalizer, object ownership). * Fixes swig/swig#266. * Added links to working examples. * Added link to runtime.SetFinalizer documentation. * Added recommendation to read the runtime.SetFinalizer documentation before using it. * Clarified that C++ objects ownership is not tracked and thus objects need to be freed manually. --- Doc/Manual/Go.html | 59 ++++++++++++++++++++++++++++++++++-------------------- 1 file changed, 37 insertions(+), 22 deletions(-) diff --git a/Doc/Manual/Go.html b/Doc/Manual/Go.html index 03b48d40c..d0d7f4c51 100644 --- a/Doc/Manual/Go.html +++ b/Doc/Manual/Go.html @@ -10,6 +10,7 @@
    • Overview +
    • Examples
    • Running SWIG with Go
      • Additional Commandline Options @@ -69,7 +70,18 @@ checking and runtime library are not used with Go. This should be borne in mind when reading the rest of the SWIG documentation.

        -

        23.2 Running SWIG with Go

        +

        23.2 Examples

        + + +

        +Working examples can be found here: +

        + + +

        23.3 Running SWIG with Go

        @@ -78,7 +90,7 @@ default SWIG will generate code for the gc compilers. To generate code for gccgo, you should also use the -gccgo option.

        -

        23.2.1 Additional Commandline Options

        +

        23.3.1 Additional Commandline Options

        @@ -152,7 +164,7 @@ swig -go -help -

        23.2.2 Go Output Files

        +

        23.3.2 Go Output Files

        When generating Go code, SWIG will generate the following @@ -228,7 +240,7 @@ this: % go tool 6l main.6

    -

    23.3 A tour of basic C/C++ wrapping

    +

    23.4 A tour of basic C/C++ wrapping

    @@ -238,7 +250,7 @@ modifications have to occur. This section briefly covers the essential aspects of this wrapping.

    -

    23.3.1 Go Package Name

    +

    23.4.1 Go Package Name

    @@ -248,7 +260,7 @@ directive. You may override this by using SWIG's -package command line option.

    -

    23.3.2 Go Names

    +

    23.4.2 Go Names

    @@ -280,7 +292,7 @@ followed by that name, and the destructor will be named Delete followed by that name.

    -

    23.3.3 Go Constants

    +

    23.4.3 Go Constants

    @@ -288,7 +300,7 @@ C/C++ constants created via #define or the %constant directive become Go constants, declared with a const declaration. -

    23.3.4 Go Enumerations

    +

    23.4.4 Go Enumerations

    @@ -298,7 +310,7 @@ usual). The values of the enumeration will become variables in Go; code should avoid modifying those variables.

    -

    23.3.5 Go Classes

    +

    23.4.5 Go Classes

    @@ -376,21 +388,24 @@ returns a go interface. If the returned pointer can be null, you can check for this by calling the Swigcptr() method.

    -

    23.3.5.1 Go Class Memory Management

    +

    23.4.5.1 Go Class Memory Management

    Calling NewClassName for some C++ class ClassName will allocate memory using the C++ memory allocator. This memory will -not be automatically freed by Go's garbage collector. When you are -done with the C++ object you must free it using DeleteClassName. +not be automatically freed by Go's garbage collector as the object ownership is +not tracked. When you are done with the C++ object you must free it manually +using DeleteClassName.

    A common technique is to store the C++ object into a Go object, and -use the Go function runtime.SetFinalizer to free the C++ -object when the Go object is freed. For example, if the SWIG package -is imported as "wrap": +use the Go function runtime.SetFinalizer to free the C++ object when +the Go object is freed. It is strongly recommended to read the +runtime.SetFinalizer +documentation before using this technique to understand its limitations. +For example, if the SWIG package is imported as "wrap":

    @@ -409,7 +424,7 @@ func NewGoClassName() *GoClassName {
     
    -

    23.3.5.2 Go Class Inheritance

    +

    23.4.5.2 Go Class Inheritance

    @@ -421,7 +436,7 @@ Doing the reverse will require an explicit type assertion, which will be checked dynamically.

    -

    23.3.6 Go Templates

    +

    23.4.6 Go Templates

    @@ -429,7 +444,7 @@ In order to use C++ templates in Go, you must tell SWIG to create wrappers for a particular template instantation. To do this, use the %template directive. -

    23.3.7 Go Director Classes

    +

    23.4.7 Go Director Classes

    @@ -472,7 +487,7 @@ method defined in Go. The Go code may of course call other methods on itself, and those methods may be defined either in Go or in C++.

    -

    23.3.8 Default Go primitive type mappings

    +

    23.4.8 Default Go primitive type mappings

    @@ -579,7 +594,7 @@ that typemap, or add new values, to control how C/C++ types are mapped into Go types.

    -

    23.3.9 Output arguments

    +

    23.4.9 Output arguments

    Because of limitations in the way output arguments are processed in swig, @@ -632,7 +647,7 @@ void f(char *output);

    -

    23.3.10 Adding additional go code

    +

    23.4.10 Adding additional go code

    Often the APIs generated by swig are not very natural in go, especially if @@ -727,7 +742,7 @@ func bar() {

    -

    23.3.11 Go typemaps

    +

    23.4.11 Go typemaps

    -- cgit v1.2.1 From 9a0fbef431a91c58ca16a529739c1174671d77c3 Mon Sep 17 00:00:00 2001 From: Michael Schaller Date: Thu, 25 Dec 2014 09:48:59 +0100 Subject: [Go] Changed link 'https://github.com/golang/go/tree/master/misc/swig' to 'https://golang.org/misc/swig' in the Go documentation. --- Doc/Manual/Go.html | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Doc/Manual/Go.html b/Doc/Manual/Go.html index d0d7f4c51..5c38aabdf 100644 --- a/Doc/Manual/Go.html +++ b/Doc/Manual/Go.html @@ -77,7 +77,7 @@ borne in mind when reading the rest of the SWIG documentation. Working examples can be found here:

    -- cgit v1.2.1 From c432073626efc1fbd399444535c35809526c3264 Mon Sep 17 00:00:00 2001 From: Robert Stone Date: Sat, 27 Dec 2014 12:48:58 -0800 Subject: Issue #282 perl5 archlib vs archlibexp --- CHANGES.current | 3 +++ configure.ac | 2 +- 2 files changed, 4 insertions(+), 1 deletion(-) diff --git a/CHANGES.current b/CHANGES.current index 941e575a7..5600d9ac5 100644 --- a/CHANGES.current +++ b/CHANGES.current @@ -5,6 +5,9 @@ See the RELEASENOTES file for a summary of changes in each release. Version 3.0.3 (in progress) =========================== +2014-12-27: talby + [Perl] Issue #282 perl5 archlib vs archlibexp + 2014-12-09: wsfulton Fix #245 - regression (since swig-3.0.0) in templated constructors. Templated constructors could not be instantiated - they were incorrectly ignored with a warning 504: diff --git a/configure.ac b/configure.ac index 40eeb5a18..ff4ce0310 100644 --- a/configure.ac +++ b/configure.ac @@ -821,7 +821,7 @@ fi # perl -MExtUtils::Embed -e ccopts AC_MSG_CHECKING(for Perl5 header files) if test -n "$PERL"; then - PERL5DIR=`($PERL -e 'use Config; print $Config{archlib}, "\n";') 2>/dev/null` + PERL5DIR=`($PERL -MConfig -le 'print $Config{archlibexp}') 2>/dev/null` if test -n "$PERL5DIR" ; then dirs="$PERL5DIR $PERL5DIR/CORE" PERL5EXT=none -- cgit v1.2.1 From 03570f85f25f4387dbcb82daacd972c4032c9e78 Mon Sep 17 00:00:00 2001 From: Robert Stone Date: Sat, 27 Dec 2014 20:45:11 -0800 Subject: [Perl] tidy "warning: duplicate 'extern' declaration specifier" when building generated code under clang --- CHANGES.current | 1 + Lib/perl5/perlinit.swg | 2 +- 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/CHANGES.current b/CHANGES.current index 5600d9ac5..7e6dcdadc 100644 --- a/CHANGES.current +++ b/CHANGES.current @@ -7,6 +7,7 @@ Version 3.0.3 (in progress) 2014-12-27: talby [Perl] Issue #282 perl5 archlib vs archlibexp + [Perl] tidy "warning: duplicate 'extern' declaration specifier" when building generated code under clang 2014-12-09: wsfulton Fix #245 - regression (since swig-3.0.0) in templated constructors. diff --git a/Lib/perl5/perlinit.swg b/Lib/perl5/perlinit.swg index d9ffa9bf8..cdb73d53a 100644 --- a/Lib/perl5/perlinit.swg +++ b/Lib/perl5/perlinit.swg @@ -21,7 +21,7 @@ SWIGEXPORT void SWIG_init (CV *cv, CPerlObj *); %init %{ -#ifdef __cplusplus +#if defined(__cplusplus) && ! defined(XSPROTO) extern "C" #endif -- cgit v1.2.1 From eec306c228107478165b99954f353ab0587a451b Mon Sep 17 00:00:00 2001 From: William S Fulton Date: Wed, 24 Dec 2014 08:48:54 +0000 Subject: Test suite warning fixes --- Examples/test-suite/li_swigtype_inout.i | 12 ++++---- Examples/test-suite/nested_class.i | 6 ++++ Examples/test-suite/nested_scope.i | 14 +++++----- .../test-suite/php/director_exception_runme.php | 2 +- Examples/test-suite/php/exception_order_runme.php | 2 +- Examples/test-suite/php/import_nomodule_runme.php | 2 +- .../test-suite/php/threads_exception_runme.php | 4 +-- Examples/test-suite/throw_exception.i | 32 +++++++++++----------- 8 files changed, 40 insertions(+), 34 deletions(-) diff --git a/Examples/test-suite/li_swigtype_inout.i b/Examples/test-suite/li_swigtype_inout.i index 9d7e9a4c6..136c9fa9e 100644 --- a/Examples/test-suite/li_swigtype_inout.i +++ b/Examples/test-suite/li_swigtype_inout.i @@ -13,28 +13,28 @@ #include struct XXX { XXX(int v) : value(v) { - if (debug) std::cout << "Default Constructor " << value << " " << this << std::endl; + if (debugging) std::cout << "Default Constructor " << value << " " << this << std::endl; count++; } XXX(const XXX &other) { value = other.value; - if (debug) std::cout << "Copy Constructor " << value << " " << this << std::endl; + if (debugging) std::cout << "Copy Constructor " << value << " " << this << std::endl; count++; } XXX& operator=(const XXX &other) { value = other.value; - if (debug) std::cout << "Assignment operator " << value << " " << this << std::endl; + if (debugging) std::cout << "Assignment operator " << value << " " << this << std::endl; return *this; } ~XXX() { - if (debug) std::cout << "Destructor " << value << " " << this << std::endl; + if (debugging) std::cout << "Destructor " << value << " " << this << std::endl; count--; } void showInfo() { - if (debug) std::cout << "Info " << value << " " << this << std::endl; + if (debugging) std::cout << "Info " << value << " " << this << std::endl; } int value; - static const bool debug = false; + static const bool debugging = false; static int count; }; int XXX::count = 0; diff --git a/Examples/test-suite/nested_class.i b/Examples/test-suite/nested_class.i index ccb7ecac1..fe405479c 100644 --- a/Examples/test-suite/nested_class.i +++ b/Examples/test-suite/nested_class.i @@ -49,6 +49,9 @@ struct Outer { struct { Integer b; }; +#else + Integer a; + Integer b; #endif union { @@ -164,6 +167,9 @@ struct Outer { public: Integer yy; }; +#else + Integer xx; + Integer yy; #endif /////////////////////////////////////////// diff --git a/Examples/test-suite/nested_scope.i b/Examples/test-suite/nested_scope.i index d89ba6ab7..bd66eec73 100644 --- a/Examples/test-suite/nested_scope.i +++ b/Examples/test-suite/nested_scope.i @@ -35,7 +35,7 @@ namespace ns { int data; }; #endif - template class Abstract; + template class AbstractClass; class Real; }; #ifndef __clang__ @@ -44,23 +44,23 @@ namespace ns { }; #endif - class Class { + class Klass { public: - template class Abstract; + template class AbstractClass; class Real; }; - template class Class::Abstract { + template class Klass::AbstractClass { public: virtual void Method() = 0; - virtual ~Abstract() {} + virtual ~AbstractClass() {} }; %} -%template(abstract_int) Class::Abstract ; +%template(abstract_int) Klass::AbstractClass ; %inline %{ - class Class::Real : public Abstract { + class Klass::Real : public AbstractClass { public: virtual void Method() {} }; diff --git a/Examples/test-suite/php/director_exception_runme.php b/Examples/test-suite/php/director_exception_runme.php index cb823214b..8b852c2ce 100644 --- a/Examples/test-suite/php/director_exception_runme.php +++ b/Examples/test-suite/php/director_exception_runme.php @@ -4,7 +4,7 @@ require "tests.php"; require "director_exception.php"; // No new functions -check::functions(array(foo_ping,foo_pong,launder,bar_ping,bar_pong,bar_pang,returnalltypes_return_int,returnalltypes_return_double,returnalltypes_return_const_char_star,returnalltypes_return_std_string,returnalltypes_return_bar)); +check::functions(array(foo_ping,foo_pong,launder,bar_ping,bar_pong,bar_pang,returnalltypes_return_int,returnalltypes_return_double,returnalltypes_return_const_char_star,returnalltypes_return_std_string,returnalltypes_return_bar,returnalltypes_call_int,returnalltypes_call_double,returnalltypes_call_const_char_star,returnalltypes_call_std_string,returnalltypes_call_bar,is_python_builtin)); // No new classes check::classes(array(director_exception,Foo,Exception1,Exception2,Base,Bar,ReturnAllTypes)); // now new vars diff --git a/Examples/test-suite/php/exception_order_runme.php b/Examples/test-suite/php/exception_order_runme.php index a83598170..acb83561a 100644 --- a/Examples/test-suite/php/exception_order_runme.php +++ b/Examples/test-suite/php/exception_order_runme.php @@ -2,7 +2,7 @@ require "tests.php"; require "exception_order.php"; -check::functions(array(a_foo,a_bar,a_foobar,a_barfoo)); +check::functions(array(a_foo,a_bar,a_foobar,a_barfoo,is_python_builtin)); check::classes(array(A,E1,E2,E3,exception_order,ET_i,ET_d)); check::globals(array(efoovar,foovar,cfoovar,a_sfoovar,a_foovar,a_efoovar)); diff --git a/Examples/test-suite/php/import_nomodule_runme.php b/Examples/test-suite/php/import_nomodule_runme.php index 84191fba9..41836ba0f 100644 --- a/Examples/test-suite/php/import_nomodule_runme.php +++ b/Examples/test-suite/php/import_nomodule_runme.php @@ -3,7 +3,7 @@ require "tests.php"; require "import_nomodule.php"; // No new functions -check::functions(array(create_foo,delete_foo,test1)); +check::functions(array(create_foo,delete_foo,test1,is_python_builtin)); // No new classes check::classes(array(import_nomodule,Bar)); // now new vars diff --git a/Examples/test-suite/php/threads_exception_runme.php b/Examples/test-suite/php/threads_exception_runme.php index 31148a1e1..9e4d04e10 100644 --- a/Examples/test-suite/php/threads_exception_runme.php +++ b/Examples/test-suite/php/threads_exception_runme.php @@ -4,9 +4,9 @@ require "tests.php"; require "threads_exception.php"; // Check functions -check::functions(array(test_simple,test_message,test_hosed,test_unknown,test_multi)); +check::functions(array(test_simple,test_message,test_hosed,test_unknown,test_multi,is_python_builtin)); // Check classes. -check::classes(array(Exc,Test)); +check::classes(array(Exc,Test,threads_exception)); // Chek globals. check::globals(array(exc_code,exc_msg)); diff --git a/Examples/test-suite/throw_exception.i b/Examples/test-suite/throw_exception.i index c1ad945fb..396c633a6 100644 --- a/Examples/test-suite/throw_exception.i +++ b/Examples/test-suite/throw_exception.i @@ -16,15 +16,15 @@ %inline %{ -class Error { +class CError { }; -void test_is_Error(Error *r) {} +void test_is_Error(CError *r) {} namespace Namespace { - typedef Error ErrorTypedef; - typedef const Error& ErrorRef; - typedef const Error* ErrorPtr; + typedef CError ErrorTypedef; + typedef const CError& ErrorRef; + typedef const CError* ErrorPtr; typedef int IntArray[10]; enum EnumTest { enum1, enum2 }; } @@ -36,26 +36,26 @@ public: void test_msg() throw(const char *) { throw "Dead"; } - void test_cls() throw(Error) { - throw Error(); + void test_cls() throw(CError) { + throw CError(); } - void test_cls_ptr() throw(Error *) { - static Error StaticError; + void test_cls_ptr() throw(CError *) { + static CError StaticError; throw &StaticError; } - void test_cls_ref() throw(Error &) { - static Error StaticError; + void test_cls_ref() throw(CError &) { + static CError StaticError; throw StaticError; } void test_cls_td() throw(Namespace::ErrorTypedef) { - throw Error(); + throw CError(); } void test_cls_ptr_td() throw(Namespace::ErrorPtr) { - static Error StaticError; + static CError StaticError; throw &StaticError; } void test_cls_ref_td() throw(Namespace::ErrorRef) { - static Error StaticError; + static CError StaticError; throw StaticError; } void test_array() throw(Namespace::IntArray) { @@ -68,10 +68,10 @@ public: void test_enum() throw(Namespace::EnumTest) { throw Namespace::enum2; } - void test_multi(int x) throw(int, const char *, Error) { + void test_multi(int x) throw(int, const char *, CError) { if (x == 1) throw 37; if (x == 2) throw "Dead"; - if (x == 3) throw Error(); + if (x == 3) throw CError(); } }; -- cgit v1.2.1 From ee35389d2299e33c74141b59a4ef346da8b6930e Mon Sep 17 00:00:00 2001 From: William S Fulton Date: Sun, 28 Dec 2014 10:29:56 +0000 Subject: Fix abort using template default parameters Closes #280 --- CHANGES.current | 4 ++ .../java/template_default_class_parms_runme.java | 5 +++ Examples/test-suite/template_default_class_parms.i | 43 ++++++++++++++++++++++ Source/Swig/symbol.c | 12 +++--- 4 files changed, 58 insertions(+), 6 deletions(-) diff --git a/CHANGES.current b/CHANGES.current index 7e6dcdadc..e89fe79f0 100644 --- a/CHANGES.current +++ b/CHANGES.current @@ -5,6 +5,10 @@ See the RELEASENOTES file for a summary of changes in each release. Version 3.0.3 (in progress) =========================== +2014-12-27: wsfulton + Fix #280 - abort using all default template parameters within other template + parameters. + 2014-12-27: talby [Perl] Issue #282 perl5 archlib vs archlibexp [Perl] tidy "warning: duplicate 'extern' declaration specifier" when building generated code under clang diff --git a/Examples/test-suite/java/template_default_class_parms_runme.java b/Examples/test-suite/java/template_default_class_parms_runme.java index 406915b82..0a6571fa8 100644 --- a/Examples/test-suite/java/template_default_class_parms_runme.java +++ b/Examples/test-suite/java/template_default_class_parms_runme.java @@ -45,6 +45,11 @@ public class template_default_class_parms_runme { foo.setTType(a); a = foo.method(a); } + + { + MapDefaults md = new MapDefaults(); + md.test_func(10, 20, new DefaultNodeType()); + } } } diff --git a/Examples/test-suite/template_default_class_parms.i b/Examples/test-suite/template_default_class_parms.i index cd37269d3..8784bb1b4 100644 --- a/Examples/test-suite/template_default_class_parms.i +++ b/Examples/test-suite/template_default_class_parms.i @@ -31,3 +31,46 @@ namespace Space { %template(FooAnotherType) Space::Foo; %template() Space::ATemplate<>; + + +// Github issue #280 segfault +%inline %{ +namespace Teuchos { + class Describable {}; +} +namespace KokkosClassic { + namespace DefaultNode { + struct DefaultNodeType {}; + }; +} + +namespace Tpetra { + template + class Map : public Teuchos::Describable { + public: + typedef LocalOrdinal local_ordinal_type; + typedef GlobalOrdinal global_ordinal_type; + typedef Node node_type; + void test_func(LocalOrdinal, GlobalOrdinal, Node) {} + }; +} +%} + +%template(MapDefaults) Tpetra::Map<>; + +%inline %{ +namespace Details { + template < class LO = ::Tpetra::Map<>::local_ordinal_type, + class GO = typename ::Tpetra::Map::global_ordinal_type, + class NT = typename ::Tpetra::Map::node_type > + class Transfer : public Teuchos::Describable { + public: + void transfer_func(LO, GO, NT) {} + }; +} +%} + +// Below is not resolving correctly yet +%template(TransferDefaults) Details::Transfer<>; diff --git a/Source/Swig/symbol.c b/Source/Swig/symbol.c index e77f818de..2202f61c6 100644 --- a/Source/Swig/symbol.c +++ b/Source/Swig/symbol.c @@ -1875,15 +1875,15 @@ ParmList *Swig_symbol_template_defargs(Parm *parms, Parm *targs, Symtab *tscope, Delete(ntq); ntq = ty; } - /* Printf(stderr,"value %s %s %s\n",value,ntr,ntq); */ cp = NewParmWithoutFileLineInfo(ntq, 0); - if (lp) - set_nextSibling(lp, cp); - else - expandedparms = CopyParm(cp); + if (lp) { + set_nextSibling(lp, cp); + Delete(cp); + } else { + expandedparms = cp; + } lp = cp; tp = nextSibling(tp); - Delete(cp); Delete(nt); Delete(ntq); } else { -- cgit v1.2.1 From ad5890bb46d682a13a2d05b84dd833c0a61c4a11 Mon Sep 17 00:00:00 2001 From: William S Fulton Date: Sun, 28 Dec 2014 13:05:30 +0000 Subject: Reduce scope of template_default_class_parms testcase %template is not working for all languages yet - remove it until fixed --- Examples/test-suite/template_default_class_parms.i | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/Examples/test-suite/template_default_class_parms.i b/Examples/test-suite/template_default_class_parms.i index 8784bb1b4..e5a8c9d49 100644 --- a/Examples/test-suite/template_default_class_parms.i +++ b/Examples/test-suite/template_default_class_parms.i @@ -58,7 +58,10 @@ namespace Tpetra { } %} +#ifdef SWIGJAVA +// Fixes still required for other languages %template(MapDefaults) Tpetra::Map<>; +#endif %inline %{ namespace Details { @@ -73,4 +76,4 @@ namespace Details { %} // Below is not resolving correctly yet -%template(TransferDefaults) Details::Transfer<>; +//%template(TransferDefaults) Details::Transfer<>; -- cgit v1.2.1 From d79f11501d0bdd78a038df79521ce21bf7cd9825 Mon Sep 17 00:00:00 2001 From: William S Fulton Date: Sun, 28 Dec 2014 15:26:27 +0000 Subject: Don't delete checked in files with 'make distclean' Occurs when ruby is not detected. Fixes #290. --- Examples/Makefile.in | 2 +- configure.ac | 1 + 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/Examples/Makefile.in b/Examples/Makefile.in index ea4c65654..bd3ed6c90 100644 --- a/Examples/Makefile.in +++ b/Examples/Makefile.in @@ -1096,7 +1096,7 @@ ruby_version: # ----------------------------------------------------------------- ruby_clean: - rm -f *_wrap* *~ .~* myruby@EXEEXT@ *.pm + rm -f *_wrap* *~ .~* myruby@EXEEXT@ rm -f core @EXTRA_CLEAN@ rm -f *.@OBJEXT@ *$(RUBY_SO) diff --git a/configure.ac b/configure.ac index ff4ce0310..24d66dc13 100644 --- a/configure.ac +++ b/configure.ac @@ -1507,6 +1507,7 @@ AC_ARG_WITH(ruby, AS_HELP_STRING([--without-ruby], [Disable Ruby]) AS_HELP_STRING([--with-ruby=path], [Set location of Ruby executable]),[ RUBYBIN="$withval"], [RUBYBIN=yes]) # First, check for "--without-ruby" or "--with-ruby=no". +RUBYSO=$SO if test x"${RUBYBIN}" = xno -o x"${with_alllang}" = xno ; then AC_MSG_NOTICE([Disabling Ruby]) RUBY= -- cgit v1.2.1 From 2b04d37b9425d2724b41ebbc1e1ca96a3ac6e74e Mon Sep 17 00:00:00 2001 From: William S Fulton Date: Sun, 28 Dec 2014 16:13:22 +0000 Subject: Tidy up Javascript build system --- Examples/Makefile.in | 5 +---- Examples/test-suite/javascript/Makefile.in | 6 ++++-- Tools/javascript/Makefile.in | 4 ---- configure.ac | 18 ------------------ 4 files changed, 5 insertions(+), 28 deletions(-) diff --git a/Examples/Makefile.in b/Examples/Makefile.in index bd3ed6c90..cdc33d030 100644 --- a/Examples/Makefile.in +++ b/Examples/Makefile.in @@ -633,9 +633,6 @@ java_clean: ROOT_DIR = @ROOT_DIR@ JSINCLUDES = @JSCOREINC@ @JSV8INC@ JSDYNAMICLINKING = @JSCOREDYNAMICLINKING@ @JSV8DYNAMICLINKING@ -JSSO =@JSSO@ -JSLDSHARED = @JSLDSHARED@ -JSCXXSHARED = @JSCXXSHARED@ NODEJS = @NODEJS@ NODEGYP = @NODEGYP@ @@ -731,7 +728,7 @@ javascript_clean: rm -rf build rm -f *_wrap* $(RUNME) rm -f core @EXTRA_CLEAN@ - rm -f *.@OBJEXT@ *@JSSO@ *.$(SO) + rm -f *.@OBJEXT@ *@SO@ rm -f binding.gyp example-gypcopy.cxx cd $(ROOT_DIR)/Tools/javascript && $(MAKE) -s clean diff --git a/Examples/test-suite/javascript/Makefile.in b/Examples/test-suite/javascript/Makefile.in index b0fd82c25..3a15e5af1 100644 --- a/Examples/test-suite/javascript/Makefile.in +++ b/Examples/test-suite/javascript/Makefile.in @@ -6,6 +6,8 @@ LANGUAGE = javascript NODEGYP = @NODEGYP@ NODEJS = @NODEJS@ SCRIPTSUFFIX = _runme.js +OBJ = @OBJ@ +SO = @SO@ srcdir = @srcdir@ top_srcdir = @top_srcdir@ @@ -116,10 +118,10 @@ endif %.clean: @rm -rf $* - @rm -f $*_wrap.* $*.so $*.o + @rm -f $*_wrap.* $*$(SO) $*$(OBJ) clean: - for ext in _wrap.cxx _wrap.o .so; do \ + for ext in _wrap.cxx _wrap$(OBJ) $(SO); do \ rm -f clientdata_prop_a$${ext} clientdata_prop_b$${ext}; \ rm -f imports_a$${ext} imports_b$${ext}; \ rm -f import_stl_a$${ext} import_stl_b$${ext}; \ diff --git a/Tools/javascript/Makefile.in b/Tools/javascript/Makefile.in index 37ff8830e..1eec5bc1e 100644 --- a/Tools/javascript/Makefile.in +++ b/Tools/javascript/Makefile.in @@ -26,10 +26,6 @@ LINKFLAGS = @JSINTERPRETERLINKFLAGS@ ROOT_DIR = @ROOT_DIR@ JSINCLUDES = @JSCOREINC@ @JSV8INC@ JSDYNAMICLINKING = @JSCOREDYNAMICLINKING@ @JSV8DYNAMICLINKING@ -JSLIBRARYPREFIX = @JSLIBRARYPREFIX@ -JSSO =@JSSO@ -JSLDSHARED = @JSLDSHARED@ -JSCXXSHARED = @JSCXXSHARED@ JSV8ENABLED = @JSV8ENABLED@ JSCENABLED = @JSCENABLED@ diff --git a/configure.ac b/configure.ac index 24d66dc13..7eec63c83 100644 --- a/configure.ac +++ b/configure.ac @@ -1123,28 +1123,15 @@ else # General Javascript settings shared by JSC and V8 #---------------------------------------------------------------- - case $host in - *-*-cygwin* | *-*-mingw*) - JSLIBRARYPREFIX="" - ;; - *) - JSLIBRARYPREFIX="lib" - ;; - esac - case $host in *-*-darwin*) JSSO=".dylib" - JSLDSHARED='$(CC) -dynamiclib' - JSCXXSHARED='$(CXX) -dynamiclib' # HACK: didn't manage to get dynamic module loading working with a g++ compiled interpreter JSINTERPRETERCXX='c++' JSINTERPRETERLINKFLAGS='-g -Wl,-search_paths_first -Wl,-headerpad_max_install_names' ;; *) JSSO=$SO - JSLDSHARED='$(LDSHARED)' - JSCXXSHARED='$(CXXSHARED)' JSINTERPRETERCXX='$(CXX)' JSINTERPRETERLINKFLAGS='-ldl' ;; @@ -1296,11 +1283,6 @@ else fi -AC_SUBST(JSLIBRARYPREFIX) -AC_SUBST(JSSO) -AC_SUBST(JSLDSHARED) -AC_SUBST(JSCXXSHARED) - AC_SUBST(JSINTERPRETERCXX) AC_SUBST(JSINTERPRETERLINKFLAGS) -- cgit v1.2.1 From 8b9d68582dd5f983d564a33a4f24e04433e92ff8 Mon Sep 17 00:00:00 2001 From: William S Fulton Date: Sun, 28 Dec 2014 17:30:10 +0000 Subject: Fix javascript clean Regression introduced a couple of commits ago --- Examples/test-suite/javascript/Makefile.in | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/Examples/test-suite/javascript/Makefile.in b/Examples/test-suite/javascript/Makefile.in index 3a15e5af1..007b970a6 100644 --- a/Examples/test-suite/javascript/Makefile.in +++ b/Examples/test-suite/javascript/Makefile.in @@ -6,7 +6,7 @@ LANGUAGE = javascript NODEGYP = @NODEGYP@ NODEJS = @NODEJS@ SCRIPTSUFFIX = _runme.js -OBJ = @OBJ@ +OBJEXT = @OBJEXT@ SO = @SO@ srcdir = @srcdir@ @@ -118,10 +118,10 @@ endif %.clean: @rm -rf $* - @rm -f $*_wrap.* $*$(SO) $*$(OBJ) + @rm -f $*_wrap.* $*$(SO) $*$(OBJEXT) clean: - for ext in _wrap.cxx _wrap$(OBJ) $(SO); do \ + for ext in _wrap.cxx _wrap$(OBJEXT) $(SO); do \ rm -f clientdata_prop_a$${ext} clientdata_prop_b$${ext}; \ rm -f imports_a$${ext} imports_b$${ext}; \ rm -f import_stl_a$${ext} import_stl_b$${ext}; \ -- cgit v1.2.1 From c26010eb010b0b3a9dd738edc51688dec9cca078 Mon Sep 17 00:00:00 2001 From: William S Fulton Date: Sun, 28 Dec 2014 17:22:13 +0000 Subject: Fix D examples clean --- Examples/Makefile.in | 5 ++--- Examples/d/example.mk.in | 3 ++- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/Examples/Makefile.in b/Examples/Makefile.in index cdc33d030..b8b4e9426 100644 --- a/Examples/Makefile.in +++ b/Examples/Makefile.in @@ -1888,6 +1888,5 @@ d_version: # ----------------------------------------------------------------- d_clean: - rm -f *_wrap* *~ .~* $(RUNME) $(RUNME).exe `find . -name \*.d | grep -v $(RUNME).d` - rm -f core @EXTRA_CLEAN@ - rm -f *.@OBJEXT@ *@SO@ + @exit 0 + diff --git a/Examples/d/example.mk.in b/Examples/d/example.mk.in index 33e1a801e..c19cebce2 100644 --- a/Examples/d/example.mk.in +++ b/Examples/d/example.mk.in @@ -47,4 +47,5 @@ build: $(MAKE) -C $(VERSION_DIR) -f $(EXAMPLES_TOP)/Makefile SRCDIR='../$(SRCDIR)' DSRCS='../$(SRCDIR)$(VERSION_DIR)runme.d $(DSRCS)' DFLAGS='$(DFLAGS)' d_compile clean: - $(MAKE) -C $(VERSION_DIR) -f $(EXAMPLES_TOP)/Makefile SRCDIR='../$(SRCDIR)' d_clean + rm -rf $(VERSION_DIR) + -- cgit v1.2.1 From df4a2195645bf02a88c999a19740b402c666c0dc Mon Sep 17 00:00:00 2001 From: William S Fulton Date: Sun, 28 Dec 2014 17:40:12 +0000 Subject: Let Octave 3.8 fail in Travis Too many internal compiler errors in gcc are failing the builds --- .travis.yml | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/.travis.yml b/.travis.yml index 65008f623..3a726db3e 100644 --- a/.travis.yml +++ b/.travis.yml @@ -55,7 +55,9 @@ matrix: - compiler: gcc env: SWIGLANG=tcl allow_failures: - # None + # Occasional gcc internal compiler error + - compiler: gcc + env: SWIGLANG=octave SWIGJOBS=-j3 VER=3.8 before_install: - date -u - uname -a -- cgit v1.2.1 From 1610ca86dd5ddc880f3d621998cd57021456b9cd Mon Sep 17 00:00:00 2001 From: William S Fulton Date: Sun, 28 Dec 2014 19:07:32 +0000 Subject: Fix javascript clean --- Examples/test-suite/javascript/Makefile.in | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/Examples/test-suite/javascript/Makefile.in b/Examples/test-suite/javascript/Makefile.in index 007b970a6..83b15f822 100644 --- a/Examples/test-suite/javascript/Makefile.in +++ b/Examples/test-suite/javascript/Makefile.in @@ -118,10 +118,10 @@ endif %.clean: @rm -rf $* - @rm -f $*_wrap.* $*$(SO) $*$(OBJEXT) + @rm -f $*_wrap.* $*$(SO) $*.$(OBJEXT) clean: - for ext in _wrap.cxx _wrap$(OBJEXT) $(SO); do \ + for ext in _wrap.cxx _wrap.$(OBJEXT) $(SO); do \ rm -f clientdata_prop_a$${ext} clientdata_prop_b$${ext}; \ rm -f imports_a$${ext} imports_b$${ext}; \ rm -f import_stl_a$${ext} import_stl_b$${ext}; \ -- cgit v1.2.1 From 063aa9e3c5614927a099f3142ddc523a939e064e Mon Sep 17 00:00:00 2001 From: William S Fulton Date: Sun, 28 Dec 2014 19:14:25 +0000 Subject: Revert "Fix D examples clean" This reverts commit c26010eb010b0b3a9dd738edc51688dec9cca078. --- Examples/Makefile.in | 5 +++-- Examples/d/example.mk.in | 3 +-- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/Examples/Makefile.in b/Examples/Makefile.in index b8b4e9426..cdc33d030 100644 --- a/Examples/Makefile.in +++ b/Examples/Makefile.in @@ -1888,5 +1888,6 @@ d_version: # ----------------------------------------------------------------- d_clean: - @exit 0 - + rm -f *_wrap* *~ .~* $(RUNME) $(RUNME).exe `find . -name \*.d | grep -v $(RUNME).d` + rm -f core @EXTRA_CLEAN@ + rm -f *.@OBJEXT@ *@SO@ diff --git a/Examples/d/example.mk.in b/Examples/d/example.mk.in index c19cebce2..33e1a801e 100644 --- a/Examples/d/example.mk.in +++ b/Examples/d/example.mk.in @@ -47,5 +47,4 @@ build: $(MAKE) -C $(VERSION_DIR) -f $(EXAMPLES_TOP)/Makefile SRCDIR='../$(SRCDIR)' DSRCS='../$(SRCDIR)$(VERSION_DIR)runme.d $(DSRCS)' DFLAGS='$(DFLAGS)' d_compile clean: - rm -rf $(VERSION_DIR) - + $(MAKE) -C $(VERSION_DIR) -f $(EXAMPLES_TOP)/Makefile SRCDIR='../$(SRCDIR)' d_clean -- cgit v1.2.1 From 2d340efe0d622f52127d8507762ed00bee7bc9b3 Mon Sep 17 00:00:00 2001 From: William S Fulton Date: Sun, 28 Dec 2014 19:54:46 +0000 Subject: Fix D examples clean Was not working if run out of source without previously running D examples --- Examples/d/example.mk.in | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/Examples/d/example.mk.in b/Examples/d/example.mk.in index 33e1a801e..ae680f2fd 100644 --- a/Examples/d/example.mk.in +++ b/Examples/d/example.mk.in @@ -47,4 +47,7 @@ build: $(MAKE) -C $(VERSION_DIR) -f $(EXAMPLES_TOP)/Makefile SRCDIR='../$(SRCDIR)' DSRCS='../$(SRCDIR)$(VERSION_DIR)runme.d $(DSRCS)' DFLAGS='$(DFLAGS)' d_compile clean: - $(MAKE) -C $(VERSION_DIR) -f $(EXAMPLES_TOP)/Makefile SRCDIR='../$(SRCDIR)' d_clean + if [ -d $(VERSION_DIR) ]; then \ + $(MAKE) -C $(VERSION_DIR) -f $(EXAMPLES_TOP)/Makefile SRCDIR='../$(SRCDIR)' d_clean; \ + fi + test -f $(VERSION_DIR)/runme.d || rm -rf $(VERSION_DIR) # Only delete dir if out of source -- cgit v1.2.1 From 3aab2df371716f6c0f35c1e953e15751d4bfd931 Mon Sep 17 00:00:00 2001 From: William S Fulton Date: Mon, 29 Dec 2014 17:17:25 +0000 Subject: Fix D examples when run 'in-source' --- Examples/d/example.mk.in | 12 +++++++++--- 1 file changed, 9 insertions(+), 3 deletions(-) diff --git a/Examples/d/example.mk.in b/Examples/d/example.mk.in index ae680f2fd..a1d9a85fc 100644 --- a/Examples/d/example.mk.in +++ b/Examples/d/example.mk.in @@ -29,9 +29,15 @@ EXTRA_CXXFLAGS = EXTRA_LDFLAGS = TARGET = example_wrap SWIGOPT = -outcurrentdir -DSRCS = *.d DFLAGS = -ofrunme +ifeq (,$(SRCDIR)) +DSRCS = *.d +else +DSRCS = *.d $(addprefix ../$(SRCDIR)$(VERSION_DIR),runme.d) +endif + + check: build $(MAKE) -C $(VERSION_DIR) -f $(EXAMPLES_TOP)/Makefile SRCDIR='../$(SRCDIR)' d_run @@ -44,10 +50,10 @@ build: else \ $(MAKE) -C $(VERSION_DIR) -f $(EXAMPLES_TOP)/Makefile SRCDIR='../$(SRCDIR)' EXTRA_CFLAGS='$(EXTRA_CFLAGS)' EXTRA_LDFLAGS='$(EXTRA_LDFLAGS)' SWIG='$(SWIG)' SWIGOPT='$(SWIGOPT)' TARGET='$(TARGET)' INTERFACE='example.i' SRCS='' d; \ fi - $(MAKE) -C $(VERSION_DIR) -f $(EXAMPLES_TOP)/Makefile SRCDIR='../$(SRCDIR)' DSRCS='../$(SRCDIR)$(VERSION_DIR)runme.d $(DSRCS)' DFLAGS='$(DFLAGS)' d_compile + $(MAKE) -C $(VERSION_DIR) -f $(EXAMPLES_TOP)/Makefile SRCDIR='../$(SRCDIR)' DSRCS='$(DSRCS)' DFLAGS='$(DFLAGS)' d_compile clean: if [ -d $(VERSION_DIR) ]; then \ $(MAKE) -C $(VERSION_DIR) -f $(EXAMPLES_TOP)/Makefile SRCDIR='../$(SRCDIR)' d_clean; \ fi - test -f $(VERSION_DIR)/runme.d || rm -rf $(VERSION_DIR) # Only delete dir if out of source + test -f $(VERSION_DIR)runme.d || rm -rf $(VERSION_DIR) # Only delete dir if out of source -- cgit v1.2.1 From cb4d0dbba50d6cbea8d40a9a607ef03bd181cb07 Mon Sep 17 00:00:00 2001 From: William S Fulton Date: Mon, 29 Dec 2014 17:36:56 +0000 Subject: %constant and structs support for Lua --- Lib/lua/lua.swg | 3 +++ 1 file changed, 3 insertions(+) diff --git a/Lib/lua/lua.swg b/Lib/lua/lua.swg index 60e418596..892d15798 100644 --- a/Lib/lua/lua.swg +++ b/Lib/lua/lua.swg @@ -44,6 +44,9 @@ %typemap(consttab) SWIGTYPE *, SWIGTYPE *const, SWIGTYPE &, SWIGTYPE &&, SWIGTYPE [] { SWIG_LUA_CONSTTAB_POINTER("$symname",$value, $1_descriptor) } +%typemap(consttab) SWIGTYPE + { SWIG_LUA_CONSTTAB_POINTER("$symname",&$value, $&1_descriptor) } + // member function pointers %typemap(consttab) SWIGTYPE (CLASS::*) { SWIG_LUA_CONSTTAB_BINARY("$symname", sizeof($type),&$value, $1_descriptor) } -- cgit v1.2.1 From 926c9d32005cc12d702cfd3a75d9782d9978a800 Mon Sep 17 00:00:00 2001 From: William S Fulton Date: Mon, 29 Dec 2014 21:21:34 +0000 Subject: Minor tweaks to the changes file --- CHANGES.current | 11 +++++++++-- 1 file changed, 9 insertions(+), 2 deletions(-) diff --git a/CHANGES.current b/CHANGES.current index e89fe79f0..cbaa756d2 100644 --- a/CHANGES.current +++ b/CHANGES.current @@ -11,7 +11,11 @@ Version 3.0.3 (in progress) 2014-12-27: talby [Perl] Issue #282 perl5 archlib vs archlibexp - [Perl] tidy "warning: duplicate 'extern' declaration specifier" when building generated code under clang + [Perl] tidy "warning: duplicate 'extern' declaration specifier" when building generated code + under clang + +2014-12-18: wsfulton + Add support for %constant and structs/classes - issue #272 2014-12-09: wsfulton Fix #245 - regression (since swig-3.0.0) in templated constructors. @@ -22,7 +26,8 @@ Version 3.0.3 (in progress) Add support for C++11 strongly typed enumerations. 2014-11-21: wsfulton - [Java C#] Fix multiply defined error when using %rename of enum items when using the "simple enum" wrappers. + [Java C#] Fix multiply defined error when using %rename of enum items when using the "simple enum" + wrappers. 2014-10-28: vadz [Python] Patch #201 The generated .py file no longer uses *args for all Python parameters. @@ -113,6 +118,8 @@ Version 3.0.3 (in progress) Issue an error for unknown SWIG preprocessor directives, rather than quietly ignoring them. Reported by jrhelsey in issue#217. + *** POTENTIAL INCOMPATIBILITY *** + 2014-08-15: talby [Perl] Include guard fix for nested modules from Anthony Heading (SF Patch #350). -- cgit v1.2.1 From 5ec7fe578b3ac9daf3cff52df9a444fc39e1ebae Mon Sep 17 00:00:00 2001 From: William S Fulton Date: Mon, 29 Dec 2014 21:34:41 +0000 Subject: Add 3.0.3 release information --- ANNOUNCE | 2 +- CHANGES.current | 2 +- Doc/Manual/Sections.html | 2 +- README | 2 +- RELEASENOTES | 5 +++++ 5 files changed, 9 insertions(+), 4 deletions(-) diff --git a/ANNOUNCE b/ANNOUNCE index 95261b2bd..4524f9acf 100644 --- a/ANNOUNCE +++ b/ANNOUNCE @@ -1,4 +1,4 @@ -*** ANNOUNCE: SWIG 3.0.3 (in progress) *** +*** ANNOUNCE: SWIG 3.0.3 (30 Dec 2014) *** http://www.swig.org diff --git a/CHANGES.current b/CHANGES.current index cbaa756d2..7d9af1967 100644 --- a/CHANGES.current +++ b/CHANGES.current @@ -2,7 +2,7 @@ Below are the changes for the current release. See the CHANGES file for changes in older releases. See the RELEASENOTES file for a summary of changes in each release. -Version 3.0.3 (in progress) +Version 3.0.3 (30 Dec 2014) =========================== 2014-12-27: wsfulton diff --git a/Doc/Manual/Sections.html b/Doc/Manual/Sections.html index 0bda3e106..1a16b6cc5 100644 --- a/Doc/Manual/Sections.html +++ b/Doc/Manual/Sections.html @@ -6,7 +6,7 @@

    SWIG-3.0 Documentation

    -Last update : SWIG-3.0.3 (in progress) +Last update : SWIG-3.0.3 (30 Dec 2014)

    Sections

    diff --git a/README b/README index 7d0130b83..be1a1dd06 100644 --- a/README +++ b/README @@ -1,6 +1,6 @@ SWIG (Simplified Wrapper and Interface Generator) -Version: 3.0.3 (in progress) +Version: 3.0.3 (30 Dec 2014) Tagline: SWIG is a compiler that integrates C and C++ with languages including Perl, Python, Tcl, Ruby, PHP, Java, C#, D, Go, Lua, diff --git a/RELEASENOTES b/RELEASENOTES index 38fbe60e7..1db08977b 100644 --- a/RELEASENOTES +++ b/RELEASENOTES @@ -4,6 +4,11 @@ and CHANGES files. Release Notes ============= +SWIG-3.0.3 summary: +- Add support for C++11 strongly typed enumerations. +- Numerous bug fixes and minor enhancements for C#, D, Go, Java, + Javascript, PHP, Perl and Python wrappers. + SWIG-3.0.2 summary: - Bug fix during install and a couple of other minor changes. -- cgit v1.2.1 From 30537089cae6623864922df281b623e483feef8e Mon Sep 17 00:00:00 2001 From: William S Fulton Date: Mon, 29 Dec 2014 21:52:42 +0000 Subject: HTML tweaks --- Doc/Manual/Php.html | 2 ++ 1 file changed, 2 insertions(+) diff --git a/Doc/Manual/Php.html b/Doc/Manual/Php.html index 6f11b4aa1..623adb68a 100644 --- a/Doc/Manual/Php.html +++ b/Doc/Manual/Php.html @@ -142,6 +142,7 @@ least work for Linux though):

    34.1.2 Using PHP Extensions

    +

    To test the extension from a PHP script, you first need to tell PHP to load it. To do this, add a line like this to the [PHP] section of @@ -773,6 +774,7 @@ Ko::threats();

    34.2.6.5 Specifying Implemented Interfaces

    +

    PHP supports the concept of abstract interfaces which a class can implement. Since SWIG 3.0.3, you can tell SWIG that a wrapped class (for example -- cgit v1.2.1 From 73222a1cd1b2e1cb7bc96b6346b34532cb6f4014 Mon Sep 17 00:00:00 2001 From: William S Fulton Date: Wed, 31 Dec 2014 01:22:16 +0000 Subject: Bump version to 3.0.4 --- ANNOUNCE | 8 +-- CHANGES | 139 +++++++++++++++++++++++++++++++++++++++++++++++ CHANGES.current | 137 +--------------------------------------------- Doc/Manual/Sections.html | 2 +- README | 2 +- configure.ac | 2 +- 6 files changed, 147 insertions(+), 143 deletions(-) diff --git a/ANNOUNCE b/ANNOUNCE index 4524f9acf..f419bf2c4 100644 --- a/ANNOUNCE +++ b/ANNOUNCE @@ -1,8 +1,8 @@ -*** ANNOUNCE: SWIG 3.0.3 (30 Dec 2014) *** +*** ANNOUNCE: SWIG 3.0.4 (in progress) *** http://www.swig.org -We're pleased to announce SWIG-3.0.3, the latest SWIG release. +We're pleased to announce SWIG-3.0.4, the latest SWIG release. What is SWIG? ============= @@ -21,11 +21,11 @@ Availability ============ The release is available for download on Sourceforge at - http://prdownloads.sourceforge.net/swig/swig-3.0.3.tar.gz + http://prdownloads.sourceforge.net/swig/swig-3.0.4.tar.gz A Windows version is also available at - http://prdownloads.sourceforge.net/swig/swigwin-3.0.3.zip + http://prdownloads.sourceforge.net/swig/swigwin-3.0.4.zip Please report problems with this release to the swig-devel mailing list, details at http://www.swig.org/mail.html. diff --git a/CHANGES b/CHANGES index 33b2b5942..a2fff2263 100644 --- a/CHANGES +++ b/CHANGES @@ -3,6 +3,145 @@ SWIG (Simplified Wrapper and Interface Generator) See the CHANGES.current file for changes in the current version. See the RELEASENOTES file for a summary of changes in each release. +Version 3.0.3 (30 Dec 2014) +=========================== + +2014-12-27: wsfulton + Fix #280 - abort using all default template parameters within other template + parameters. + +2014-12-27: talby + [Perl] Issue #282 perl5 archlib vs archlibexp + [Perl] tidy "warning: duplicate 'extern' declaration specifier" when building generated code + under clang + +2014-12-18: wsfulton + Add support for %constant and structs/classes - issue #272 + +2014-12-09: wsfulton + Fix #245 - regression (since swig-3.0.0) in templated constructors. + Templated constructors could not be instantiated - they were incorrectly ignored with a warning 504: + "Function: xyz must have a return type. Ignored." + +2014-12-07: wsfulton + Add support for C++11 strongly typed enumerations. + +2014-11-21: wsfulton + [Java C#] Fix multiply defined error when using %rename of enum items when using the "simple enum" + wrappers. + +2014-10-28: vadz + [Python] Patch #201 The generated .py file no longer uses *args for all Python parameters. + Instead, the parameters are named using the C++ parameter names. + +2014-10-24: timotheecour + [D] Patch #204 Use core.atomic.atomicOp to mutate shared variables + +2014-10-21: wsfulton + Fix issue #242 - Use of the "kwargs" feature no longer automatically turns on the + "compactdefaultargs" feature if the target language does not support kwargs. + Only Java and Python support kwargs, so this affects all the other languages. + + *** POTENTIAL INCOMPATIBILITY *** + +2014-10-10: diorcety + [Python] Patch #232 Fix property access using directors + +2014-10-06: wsfulton + [Python] Fixes when using -builtin and std::vector/std::list wrappers to allow deletion + of single elements, such as 'del vec[0]'. + +2014-09-30: oliverb + [Javascript] Merge patch #216 by Richie765 - Added support for many versions of v8 javascript. + +2014-09-30: oliverb + [Javascript] Merge patch #195 by zittix - Fixed JSClassRef declaration not using the static one. + +2014-09-30: ianlancetaylor + [Go] In configure script, require Go 1.1 or later. + +2014-09-30: wsfulton + [Python] Patch #207 - Fix No module error with -relativeimport when using single + header file import. + +2014-09-27: wsfulton + Patch #208 - Initialise newly created array when using array_functions in the + carrays.i library (C++ usage). + +2014-09-27: wsfulton + [Ruby] Patch #187 - Fix crash on shutdown of the Ruby interpreter if more than one + module was loaded at a time when data is being shared between modules. + +2014-09-27: wsfulton + [Java] Patch #168 - Fix leak in Java director string handling after the Java + upcall when called from a native thread. + +2014-09-25: ianlancetaylor + [Go] Adjust generated code to work with upcoming Go 1.4 + release. + +2014-09-23: wsfulton + [Python] Add patch from Thomas Maslach to fix crash in wrappers when using -threads in + the STL iterators (SwigPyIterator destructor). + +2014-09-17: wsfulton + [C#] Merge patch #229 from contre - Add bool array types to arrays_csharp.i + +2014-09-12: olly + [PHP] Add support for specifying any PHP interfaces a wrapped class + implements, e.g.: %typemap("phpinterfaces") MyIterator "Iterator"; + +2014-09-11: olly + [PHP] Fix throwing a PHP exception through C++ from a subclassed + director method - PHP NULL gets returned by the subclassed method + in this case, so the directorout typemap needs to allow that (at + least if an exception is active). + +2014-09-09: ianlancetaylor + [Go] Add goargout typemap. + +2014-09-09: olly + [PHP] Fix segmentation faults with directors in PHP >= 5.4, and + reenable runme tests for director_basic testcase. Fix from + pavel-charvat in issue#164. + +2014-09-05: ianlancetaylor + [Go] Add imtype, goin, goout, godirectorin, and + godirectorout typemaps, to support writing Go code to + convert between types. + +2014-09-02: olly + [Python] Fix regression in indentation of python code produced with + -modern, introduced by changes in #188. Reported by fabiencastan + in #218. + +2014-09-01: olly + Issue an error for unknown SWIG preprocessor directives, rather + than quietly ignoring them. Reported by jrhelsey in issue#217. + + *** POTENTIAL INCOMPATIBILITY *** + +2014-08-15: talby + [Perl] Include guard fix for nested modules from Anthony Heading (SF Patch #350). + +2014-08-04: wsfulton + [C#] Merge patch #200 from gpetrou - Changed CSharp license header to include auto-generated + tag so that StyleCop ignores the files. + +2014-08-04: wsfulton + [Java] Merge patch #198 from Yuval Kashtan - Support for java.nio.ByteBuffer mapping to + unsigned char * in various.i in NIOBUFFER typemaps. + +2014-07-14: ianlancetaylor + [Go] Change struct definition to use void *, not uint8, so + that the type is recorded as possibly containing + pointers. This ensures that the 1.3 garbage collector + does not collect pointers passed to C++ code. + +2014-07-01: wsfulton + Fix SF Bug #1375 - Expansion of the $parentclassname special variable incorrectly contains + brackets in the expanded name. + Version 3.0.2 (4 Jun 2014) ========================== diff --git a/CHANGES.current b/CHANGES.current index 7d9af1967..dd10b0f2b 100644 --- a/CHANGES.current +++ b/CHANGES.current @@ -2,141 +2,6 @@ Below are the changes for the current release. See the CHANGES file for changes in older releases. See the RELEASENOTES file for a summary of changes in each release. -Version 3.0.3 (30 Dec 2014) +Version 3.0.4 (in progress) =========================== -2014-12-27: wsfulton - Fix #280 - abort using all default template parameters within other template - parameters. - -2014-12-27: talby - [Perl] Issue #282 perl5 archlib vs archlibexp - [Perl] tidy "warning: duplicate 'extern' declaration specifier" when building generated code - under clang - -2014-12-18: wsfulton - Add support for %constant and structs/classes - issue #272 - -2014-12-09: wsfulton - Fix #245 - regression (since swig-3.0.0) in templated constructors. - Templated constructors could not be instantiated - they were incorrectly ignored with a warning 504: - "Function: xyz must have a return type. Ignored." - -2014-12-07: wsfulton - Add support for C++11 strongly typed enumerations. - -2014-11-21: wsfulton - [Java C#] Fix multiply defined error when using %rename of enum items when using the "simple enum" - wrappers. - -2014-10-28: vadz - [Python] Patch #201 The generated .py file no longer uses *args for all Python parameters. - Instead, the parameters are named using the C++ parameter names. - -2014-10-24: timotheecour - [D] Patch #204 Use core.atomic.atomicOp to mutate shared variables - -2014-10-21: wsfulton - Fix issue #242 - Use of the "kwargs" feature no longer automatically turns on the - "compactdefaultargs" feature if the target language does not support kwargs. - Only Java and Python support kwargs, so this affects all the other languages. - - *** POTENTIAL INCOMPATIBILITY *** - -2014-10-10: diorcety - [Python] Patch #232 Fix property access using directors - -2014-10-06: wsfulton - [Python] Fixes when using -builtin and std::vector/std::list wrappers to allow deletion - of single elements, such as 'del vec[0]'. - -2014-09-30: oliverb - [Javascript] Merge patch #216 by Richie765 - Added support for many versions of v8 javascript. - -2014-09-30: oliverb - [Javascript] Merge patch #195 by zittix - Fixed JSClassRef declaration not using the static one. - -2014-09-30: ianlancetaylor - [Go] In configure script, require Go 1.1 or later. - -2014-09-30: wsfulton - [Python] Patch #207 - Fix No module error with -relativeimport when using single - header file import. - -2014-09-27: wsfulton - Patch #208 - Initialise newly created array when using array_functions in the - carrays.i library (C++ usage). - -2014-09-27: wsfulton - [Ruby] Patch #187 - Fix crash on shutdown of the Ruby interpreter if more than one - module was loaded at a time when data is being shared between modules. - -2014-09-27: wsfulton - [Java] Patch #168 - Fix leak in Java director string handling after the Java - upcall when called from a native thread. - -2014-09-25: ianlancetaylor - [Go] Adjust generated code to work with upcoming Go 1.4 - release. - -2014-09-23: wsfulton - [Python] Add patch from Thomas Maslach to fix crash in wrappers when using -threads in - the STL iterators (SwigPyIterator destructor). - -2014-09-17: wsfulton - [C#] Merge patch #229 from contre - Add bool array types to arrays_csharp.i - -2014-09-12: olly - [PHP] Add support for specifying any PHP interfaces a wrapped class - implements, e.g.: %typemap("phpinterfaces") MyIterator "Iterator"; - -2014-09-11: olly - [PHP] Fix throwing a PHP exception through C++ from a subclassed - director method - PHP NULL gets returned by the subclassed method - in this case, so the directorout typemap needs to allow that (at - least if an exception is active). - -2014-09-09: ianlancetaylor - [Go] Add goargout typemap. - -2014-09-09: olly - [PHP] Fix segmentation faults with directors in PHP >= 5.4, and - reenable runme tests for director_basic testcase. Fix from - pavel-charvat in issue#164. - -2014-09-05: ianlancetaylor - [Go] Add imtype, goin, goout, godirectorin, and - godirectorout typemaps, to support writing Go code to - convert between types. - -2014-09-02: olly - [Python] Fix regression in indentation of python code produced with - -modern, introduced by changes in #188. Reported by fabiencastan - in #218. - -2014-09-01: olly - Issue an error for unknown SWIG preprocessor directives, rather - than quietly ignoring them. Reported by jrhelsey in issue#217. - - *** POTENTIAL INCOMPATIBILITY *** - -2014-08-15: talby - [Perl] Include guard fix for nested modules from Anthony Heading (SF Patch #350). - -2014-08-04: wsfulton - [C#] Merge patch #200 from gpetrou - Changed CSharp license header to include auto-generated - tag so that StyleCop ignores the files. - -2014-08-04: wsfulton - [Java] Merge patch #198 from Yuval Kashtan - Support for java.nio.ByteBuffer mapping to - unsigned char * in various.i in NIOBUFFER typemaps. - -2014-07-14: ianlancetaylor - [Go] Change struct definition to use void *, not uint8, so - that the type is recorded as possibly containing - pointers. This ensures that the 1.3 garbage collector - does not collect pointers passed to C++ code. - -2014-07-01: wsfulton - Fix SF Bug #1375 - Expansion of the $parentclassname special variable incorrectly contains - brackets in the expanded name. diff --git a/Doc/Manual/Sections.html b/Doc/Manual/Sections.html index 1a16b6cc5..2b2917203 100644 --- a/Doc/Manual/Sections.html +++ b/Doc/Manual/Sections.html @@ -6,7 +6,7 @@

    SWIG-3.0 Documentation

    -Last update : SWIG-3.0.3 (30 Dec 2014) +Last update : SWIG-3.0.4 (in progress)

    Sections

    diff --git a/README b/README index be1a1dd06..4d3b30012 100644 --- a/README +++ b/README @@ -1,6 +1,6 @@ SWIG (Simplified Wrapper and Interface Generator) -Version: 3.0.3 (30 Dec 2014) +Version: 3.0.4 (in progress) Tagline: SWIG is a compiler that integrates C and C++ with languages including Perl, Python, Tcl, Ruby, PHP, Java, C#, D, Go, Lua, diff --git a/configure.ac b/configure.ac index 7eec63c83..ff2b057d9 100644 --- a/configure.ac +++ b/configure.ac @@ -2,7 +2,7 @@ dnl Process this file with autoconf to produce a configure script. dnl The macros which aren't shipped with the autotools are stored in the dnl Tools/config directory in .m4 files. -AC_INIT([swig],[3.0.3],[http://www.swig.org]) +AC_INIT([swig],[3.0.4],[http://www.swig.org]) dnl NB: When this requirement is increased to 2.60 or later, AC_PROG_SED dnl definition below can be removed -- cgit v1.2.1 From e4326229b65e6d8ff1b7c55a04bdb2f950aed8e1 Mon Sep 17 00:00:00 2001 From: Olly Betts Date: Wed, 7 Jan 2015 12:40:31 +1300 Subject: Fix typo --- CHANGES | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/CHANGES b/CHANGES index a2fff2263..1741c7ea7 100644 --- a/CHANGES +++ b/CHANGES @@ -179,7 +179,7 @@ Version 3.0.1 (27 May 2014) symbol comprising the outer structure name and unnamed variable instance name. 2014-05-15: kwwette - Add #166 - 'make check' now works out of source. This required te examples to build + Add #166 - 'make check' now works out of source. This required the examples to build out of source. The main languages have been tested - C#, Go, Guile, Java, Javascript, Lua, Octave, Perl, PHP, Python, Ruby and Tcl. -- cgit v1.2.1 From 430fe58a24339edace14d60de315f357bd813405 Mon Sep 17 00:00:00 2001 From: Olly Betts Date: Wed, 7 Jan 2015 18:14:44 +1300 Subject: Properly quote parameters in preinst-swig wrapper. $* is subject to word-splitting and pathname expansion, whereas "$@" expands to each parameter as a separate quoted word. Some ancient shells expand "$@" to "" if there are no parameters, but that isn't really a concern here as running swig without arguments isn't useful. --- preinst-swig.in | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/preinst-swig.in b/preinst-swig.in index 0f49e2e5e..384593ce1 100755 --- a/preinst-swig.in +++ b/preinst-swig.in @@ -4,4 +4,4 @@ srcdir=`cd "$builddir" && cd '@srcdir@' && pwd` SWIG_LIB=$srcdir/Lib #SWIG_LIB=`cygpath -w $srcdir/Lib` # For native Windows version of SWIG export SWIG_LIB -exec "$builddir/swig" $* +exec "$builddir/swig" "$@" -- cgit v1.2.1 From bfccd9c441c9ee8df81171dad011a6e56bdbf5af Mon Sep 17 00:00:00 2001 From: William S Fulton Date: Wed, 7 Jan 2015 20:46:25 +0000 Subject: More on Go examples [skip ci] --- Doc/Manual/Go.html | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/Doc/Manual/Go.html b/Doc/Manual/Go.html index 5c38aabdf..9a6de9598 100644 --- a/Doc/Manual/Go.html +++ b/Doc/Manual/Go.html @@ -80,6 +80,10 @@ Working examples can be found here:
  • Examples from the Go source tree
  • Examples from the SWIG source tree +

    +The examples in the 2nd link are shipped with the SWIG distribution under the Examples/go directory. +

    +

    23.3 Running SWIG with Go

    -- cgit v1.2.1 From 0acebe2289a33c2e039912a7985f54ae3f5436f1 Mon Sep 17 00:00:00 2001 From: Olly Betts Date: Thu, 8 Jan 2015 10:14:18 +1300 Subject: Split -help output into 4 chunks instead of 3 I believe the aim is to keep these below 2KB to avoid string literal length limits on some compiler, but they slowly creep up in size, so split into more chunks and rebalance the contents. --- Source/Modules/main.cxx | 14 +++++++++----- 1 file changed, 9 insertions(+), 5 deletions(-) diff --git a/Source/Modules/main.cxx b/Source/Modules/main.cxx index f41844d34..d1465947f 100644 --- a/Source/Modules/main.cxx +++ b/Source/Modules/main.cxx @@ -80,6 +80,9 @@ static const char *usage1 = (const char *) "\ -directors - Turn on director mode for all the classes, mainly for testing\n\ -dirprot - Turn on wrapping of protected members for director classes (default)\n\ -D - Define a symbol (for conditional compilation)\n\ +"; + +static const char *usage2 = (const char *) "\ -E - Preprocess only, does not generate wrapper code\n\ -external-runtime [file] - Export the SWIG runtime stack\n\ -fakeversion - Make SWIG fake the program version number to \n\ @@ -87,9 +90,6 @@ static const char *usage1 = (const char *) "\ -features - Set global features, where is a comma separated list of\n\ features, eg -features directors,autodoc=1\n\ If no explicit value is given to the feature, a default of 1 is used\n\ -"; - -static const char *usage2 = (const char *) "\ -fastdispatch - Enable fast dispatch mode to produce faster overload dispatcher code\n\ -Fmicrosoft - Display error/warning messages in Microsoft format\n\ -Fstandard - Display error/warning messages in commonly used format\n\ @@ -101,6 +101,9 @@ static const char *usage2 = (const char *) "\ -importall - Follow all #include statements as imports\n\ -includeall - Follow all #include statements\n\ -l - Include SWIG library file \n\ +"; + +static const char *usage3 = (const char *) "\ -macroerrors - Report errors inside macros\n\ -makedefault - Create default constructors/destructors (the default)\n\ -M - List all dependencies\n\ @@ -120,10 +123,10 @@ static const char *usage2 = (const char *) "\ -noexcept - Do not wrap exception specifiers\n\ -nofastdispatch - Disable fast dispatch mode (default)\n\ -nopreprocess - Skip the preprocessor step\n\ + -notemplatereduce - Disable reduction of the typedefs in templates\n\ "; -static const char *usage3 = (const char *) "\ - -notemplatereduce - Disable reduction of the typedefs in templates\n\ +static const char *usage4 = (const char *) "\ -O - Enable the optimization options: \n\ -fastdispatch -fvirtual \n\ -o - Set name of the output file to \n\ @@ -851,6 +854,7 @@ void SWIG_getoptions(int argc, char *argv[]) { fputs(usage1, stdout); fputs(usage2, stdout); fputs(usage3, stdout); + fputs(usage4, stdout); Swig_mark_arg(i); help = 1; } -- cgit v1.2.1 From cd16059c667aa952d79a5b70a0a6ac9a7d5fdc0d Mon Sep 17 00:00:00 2001 From: Olly Betts Date: Thu, 8 Jan 2015 10:54:37 +1300 Subject: Provide -cppext as a general command line option Provide -cppext as a general command line option for setting the extension used for generated C++ files (previously it was specific to the PHP backend). Deprecate the equivalent -suffix option provided by the Ocaml backend, but continue to support that for now. --- CHANGES.current | 6 ++++++ Doc/Manual/SWIG.html | 1 + Source/Modules/main.cxx | 11 +++++++++++ Source/Modules/ocaml.cxx | 3 ++- Source/Modules/php.cxx | 10 ---------- 5 files changed, 20 insertions(+), 11 deletions(-) diff --git a/CHANGES.current b/CHANGES.current index dd10b0f2b..a5b700cf4 100644 --- a/CHANGES.current +++ b/CHANGES.current @@ -5,3 +5,9 @@ See the RELEASENOTES file for a summary of changes in each release. Version 3.0.4 (in progress) =========================== +2015-01-08: olly + Provide -cppext as a general command line option for setting the + extension used for generated C++ files (previously it was specific + to the PHP backend). Deprecate the equivalent -suffix option + provided by the Ocaml backend, but continue to support that for + now. diff --git a/Doc/Manual/SWIG.html b/Doc/Manual/SWIG.html index e70280a08..1652df3c0 100644 --- a/Doc/Manual/SWIG.html +++ b/Doc/Manual/SWIG.html @@ -138,6 +138,7 @@ can be obtained by typing swig -help or swig -xml Generate XML wrappers -c++ Enable C++ parsing +-cppext ext Change file extension of C++ generated files to ext (default is cxx, except for PHP which uses cpp) -Dsymbol Define a preprocessor symbol -Fstandard Display error/warning messages in commonly used format -Fmicrosoft Display error/warning messages in Microsoft format diff --git a/Source/Modules/main.cxx b/Source/Modules/main.cxx index d1465947f..aa0d7d589 100644 --- a/Source/Modules/main.cxx +++ b/Source/Modules/main.cxx @@ -63,6 +63,8 @@ static const char *usage1 = (const char *) "\ -co - Check out of the SWIG library\n\ -copyctor - Automatically generate copy constructors wherever possible\n\ -cpperraswarn - Treat the preprocessor #error statement as #warning (default)\n\ + -cppext - Change file extension of generated C++ files to \n\ + (default is cxx, except for PHP which uses cpp)\n\ -copyright - Display copyright notices\n\ -debug-classes - Display information about the classes found in the interface\n\ -debug-module - Display module parse tree at stages 1-4, is a csv list of stages\n\ @@ -681,6 +683,15 @@ void SWIG_getoptions(int argc, char *argv[]) { } else if (strcmp(argv[i], "-nocpperraswarn") == 0) { Preprocessor_error_as_warning(0); Swig_mark_arg(i); + } else if (strcmp(argv[i], "-cppext") == 0) { + Swig_mark_arg(i); + if (argv[i + 1]) { + SWIG_config_cppext(argv[i + 1]); + Swig_mark_arg(i + 1); + i++; + } else { + Swig_arg_error(); + } } else if ((strcmp(argv[i], "-debug-typemap") == 0) || (strcmp(argv[i], "-debug_typemap") == 0) || (strcmp(argv[i], "-tm_debug") == 0)) { tm_debug = 1; Swig_mark_arg(i); diff --git a/Source/Modules/ocaml.cxx b/Source/Modules/ocaml.cxx index f3d63a6dc..ac73c1f0c 100644 --- a/Source/Modules/ocaml.cxx +++ b/Source/Modules/ocaml.cxx @@ -19,7 +19,7 @@ static const char *usage = "\ Ocaml Options (available with -ocaml)\n\ -oldvarnames - Old intermediary method names for variable wrappers\n\ -prefix - Set a prefix to be prepended to all names\n\ - -suffix - Change .cxx to something else\n\ + -suffix - Deprecated alias for general option -cppext\n\ -where - Emit library location\n\ \n"; @@ -114,6 +114,7 @@ public: } } else if (strcmp(argv[i], "-suffix") == 0) { if (argv[i + 1]) { + Printf(stderr, "swig: warning: -suffix option deprecated. SWIG 3.0.4 and later provide a -cppext option which should be used instead.\n"); SWIG_config_cppext(argv[i + 1]); Swig_mark_arg(i); Swig_mark_arg(i + 1); diff --git a/Source/Modules/php.cxx b/Source/Modules/php.cxx index b09dd09aa..efeb4dcc4 100644 --- a/Source/Modules/php.cxx +++ b/Source/Modules/php.cxx @@ -44,7 +44,6 @@ static const char *usage = "\ PHP Options (available with -php)\n\ - -cppext - Change C++ file extension to (default is cpp)\n\ -noproxy - Don't generate proxy classes.\n\ -prefix - Prepend to all class names in PHP wrappers\n\ \n"; @@ -221,15 +220,6 @@ public: } else { Swig_arg_error(); } - } else if (strcmp(argv[i], "-cppext") == 0) { - if (argv[i + 1]) { - SWIG_config_cppext(argv[i + 1]); - Swig_mark_arg(i); - Swig_mark_arg(i + 1); - i++; - } else { - Swig_arg_error(); - } } else if ((strcmp(argv[i], "-noshadow") == 0) || (strcmp(argv[i], "-noproxy") == 0)) { shadow = 0; Swig_mark_arg(i); -- cgit v1.2.1 From 4912920416f059cd191ce8ba507e06e2fd8d7747 Mon Sep 17 00:00:00 2001 From: Olly Betts Date: Thu, 8 Jan 2015 10:55:35 +1300 Subject: Fix tab to space in HTML preformatted block --- Doc/Manual/SWIG.html | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Doc/Manual/SWIG.html b/Doc/Manual/SWIG.html index 1652df3c0..4c33aeab8 100644 --- a/Doc/Manual/SWIG.html +++ b/Doc/Manual/SWIG.html @@ -147,7 +147,7 @@ can be obtained by typing swig -help or swig -lfile Include a SWIG library file. -module name Set the name of the SWIG module -o outfile Name of output file --outcurrentdir Set default output dir to current dir instead of input file's path +-outcurrentdir Set default output dir to current dir instead of input file's path -outdir dir Set language specific files output directory -pcreversion Display PCRE version information -swiglib Show location of SWIG library -- cgit v1.2.1 From fc60a97ebee3be9a0e4b62664100163f6924664c Mon Sep 17 00:00:00 2001 From: Olly Betts Date: Thu, 8 Jan 2015 10:55:58 +1300 Subject: Drop deprecated warnings for ancient options Support for -stat was removed in SWIG 1.3 Alpha 1 nearly 15 years ago, and the documentation options were removed prior to that, so issuing a warning that they are deprecated and ignoring them serves no useful purpose now. --- Source/Modules/swigmain.cxx | 5 ----- 1 file changed, 5 deletions(-) diff --git a/Source/Modules/swigmain.cxx b/Source/Modules/swigmain.cxx index 8a0861d17..6bbf40d95 100644 --- a/Source/Modules/swigmain.cxx +++ b/Source/Modules/swigmain.cxx @@ -180,11 +180,6 @@ int main(int margc, char **margv) { } else if (strcmp(argv[i], "-nolang") == 0) { dl = new Language; Swig_mark_arg(i); - } else if ((strcmp(argv[i], "-dnone") == 0) || - (strcmp(argv[i], "-dhtml") == 0) || - (strcmp(argv[i], "-dlatex") == 0) || (strcmp(argv[i], "-dascii") == 0) || (strcmp(argv[i], "-stat") == 0)) { - Printf(stderr, "swig: Warning. %s option deprecated.\n", argv[i]); - Swig_mark_arg(i); } else if ((strcmp(argv[i], "-help") == 0) || (strcmp(argv[i], "--help") == 0)) { if (strcmp(argv[i], "--help") == 0) strcpy(argv[i], "-help"); -- cgit v1.2.1 From 70280970d6715095f2f90fcc39be85c46d4508e7 Mon Sep 17 00:00:00 2001 From: Olly Betts Date: Thu, 8 Jan 2015 11:16:19 +1300 Subject: Fix links to the online 1.3 docs to instead be relative --- Doc/Manual/Ruby.html | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/Doc/Manual/Ruby.html b/Doc/Manual/Ruby.html index c4e0074f3..181c46ba9 100644 --- a/Doc/Manual/Ruby.html +++ b/Doc/Manual/Ruby.html @@ -2823,7 +2823,7 @@ not support optional arguments, such as Java and C#, effectively ignore the value specified by this typemap as all arguments must be given.

    Once a default typemap has been applied to an argument, all -arguments that follow must have default values. See the +arguments that follow must have default values. See the Default/optional arguments section for further information on default argument wrapping.

    @@ -3017,7 +3017,7 @@ catch(char const *_e) {

    Note that if your methods do not have an exception specification yet they do throw exceptions, SWIG cannot know how to -deal with them. For a neat way to handle these, see the Exception +deal with them. For a neat way to handle these, see the Exception handling with %exception section.

    38.7.6.14 directorin typemap

    -- cgit v1.2.1 From 9ca6f78b078887ee9357ad63e68ed79e214a40f3 Mon Sep 17 00:00:00 2001 From: Olly Betts Date: Thu, 8 Jan 2015 11:16:48 +1300 Subject: Update link to point to 3.0 docs --- Lib/pointer.i | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Lib/pointer.i b/Lib/pointer.i index 8015317d7..ea8e535ab 100644 --- a/Lib/pointer.i +++ b/Lib/pointer.i @@ -4,7 +4,7 @@ %echo "pointer.i is deprecated. Use cpointer.i instead." -%echo "See http://www.swig.org/Doc1.3/Library.html" +%echo "See http://www.swig.org/Doc3.0/Library.html" -- cgit v1.2.1 From 04715f74e2d27f0a956ae83232444e9fbc273ba4 Mon Sep 17 00:00:00 2001 From: Olly Betts Date: Thu, 8 Jan 2015 12:07:54 +1300 Subject: Improve error message when an unknown SWIG directive is used This previously gave the cryptic "Error: Syntax error in input(1).", but now gives "Error: Unknown directive '%foo'." --- CHANGES.current | 5 +++++ Examples/test-suite/errors/pp_unknowndirective.i | 7 +++++++ Examples/test-suite/errors/pp_unknowndirective.stderr | 1 + Source/CParse/cparse.h | 1 + Source/CParse/cscanner.c | 11 ++++++++++- Source/CParse/parser.y | 6 +++++- 6 files changed, 29 insertions(+), 2 deletions(-) create mode 100644 Examples/test-suite/errors/pp_unknowndirective.i create mode 100644 Examples/test-suite/errors/pp_unknowndirective.stderr diff --git a/CHANGES.current b/CHANGES.current index a5b700cf4..115a1b511 100644 --- a/CHANGES.current +++ b/CHANGES.current @@ -5,6 +5,11 @@ See the RELEASENOTES file for a summary of changes in each release. Version 3.0.4 (in progress) =========================== +2015-01-08: olly + Improve error message when an unknown SWIG directive is used - this + previously gave the cryptic "Error: Syntax error in input(1).", but + now gives "Error: Unknown directive '%foo'." + 2015-01-08: olly Provide -cppext as a general command line option for setting the extension used for generated C++ files (previously it was specific diff --git a/Examples/test-suite/errors/pp_unknowndirective.i b/Examples/test-suite/errors/pp_unknowndirective.i new file mode 100644 index 000000000..659a997d3 --- /dev/null +++ b/Examples/test-suite/errors/pp_unknowndirective.i @@ -0,0 +1,7 @@ +%module xxx + +/* This used to give the rather cryptic "Syntax error in input(1)." prior to + * SWIG 3.0.4. This testcase checks that the improved message is actually + * issued. + */ +%remane("typo") tyop; diff --git a/Examples/test-suite/errors/pp_unknowndirective.stderr b/Examples/test-suite/errors/pp_unknowndirective.stderr new file mode 100644 index 000000000..4506c5cf4 --- /dev/null +++ b/Examples/test-suite/errors/pp_unknowndirective.stderr @@ -0,0 +1 @@ +c_unknowndirective.i:7: Error: Unknown directive '%remane'. diff --git a/Source/CParse/cparse.h b/Source/CParse/cparse.h index 5a0d52d23..84a486fb7 100644 --- a/Source/CParse/cparse.h +++ b/Source/CParse/cparse.h @@ -27,6 +27,7 @@ extern "C" { extern int cparse_cplusplus; extern int cparse_cplusplusout; extern int cparse_start_line; + extern String *cparse_unknown_directive; extern void Swig_cparse_cplusplus(int); extern void Swig_cparse_cplusplusout(int); diff --git a/Source/CParse/cscanner.c b/Source/CParse/cscanner.c index d9a17b874..d86c4590a 100644 --- a/Source/CParse/cscanner.c +++ b/Source/CParse/cscanner.c @@ -40,6 +40,9 @@ int cparse_cplusplus = 0; /* Generate C++ compatible code when wrapping C code */ int cparse_cplusplusout = 0; +/* To allow better error reporting */ +String *cparse_unknown_directive = 0; + /* Private vars */ static int scan_init = 0; static int num_brace = 0; @@ -801,8 +804,11 @@ int yylex(void) { if (strcmp(yytext, "inline") == 0) return (yylex()); - /* SWIG directives */ } else { + Delete(cparse_unknown_directive); + cparse_unknown_directive = NULL; + + /* SWIG directives */ if (strcmp(yytext, "%module") == 0) return (MODULE); if (strcmp(yytext, "%insert") == 0) @@ -878,6 +884,9 @@ int yylex(void) { } if (strcmp(yytext, "%warn") == 0) return (WARN); + + /* Note down the apparently unknown directive for error reporting. */ + cparse_unknown_directive = Swig_copy_string(yytext); } /* Have an unknown identifier, as a last step, we'll do a typedef lookup on it. */ diff --git a/Source/CParse/parser.y b/Source/CParse/parser.y index 1566bafec..4bee5f127 100644 --- a/Source/CParse/parser.y +++ b/Source/CParse/parser.y @@ -1510,7 +1510,11 @@ declaration : swig_directive { $$ = $1; } | SEMI { $$ = 0; } | error { $$ = 0; - Swig_error(cparse_file, cparse_line,"Syntax error in input(1).\n"); + if (cparse_unknown_directive) { + Swig_error(cparse_file, cparse_line, "Unknown directive '%s'.\n", cparse_unknown_directive); + } else { + Swig_error(cparse_file, cparse_line, "Syntax error in input(1).\n"); + } exit(1); } /* Out of class constructor/destructor declarations */ -- cgit v1.2.1 From 809ebef1f8a50068052586dc9689f7283e7cc869 Mon Sep 17 00:00:00 2001 From: Olly Betts Date: Thu, 8 Jan 2015 12:21:23 +1300 Subject: Fix testcase name in expected output --- Examples/test-suite/errors/pp_unknowndirective.stderr | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Examples/test-suite/errors/pp_unknowndirective.stderr b/Examples/test-suite/errors/pp_unknowndirective.stderr index 4506c5cf4..d0d5e249f 100644 --- a/Examples/test-suite/errors/pp_unknowndirective.stderr +++ b/Examples/test-suite/errors/pp_unknowndirective.stderr @@ -1 +1 @@ -c_unknowndirective.i:7: Error: Unknown directive '%remane'. +pp_unknowndirective.i:7: Error: Unknown directive '%remane'. -- cgit v1.2.1 From 19961d7135181926e764cfdbacf5e0ba0388e02a Mon Sep 17 00:00:00 2001 From: Olly Betts Date: Thu, 8 Jan 2015 12:25:47 +1300 Subject: Add .gitignore for Examples/test-suite/errors/ --- Examples/test-suite/errors/.gitignore | 4 ++++ 1 file changed, 4 insertions(+) create mode 100644 Examples/test-suite/errors/.gitignore diff --git a/Examples/test-suite/errors/.gitignore b/Examples/test-suite/errors/.gitignore new file mode 100644 index 000000000..22ca11947 --- /dev/null +++ b/Examples/test-suite/errors/.gitignore @@ -0,0 +1,4 @@ +*.newerr +cpp_recursive_typedef.py +cpp_shared_ptr.py +xxx.py -- cgit v1.2.1 From 51487c1acc7d269019d115d8eb5ad686f83de321 Mon Sep 17 00:00:00 2001 From: Olly Betts Date: Thu, 8 Jan 2015 12:47:12 +1300 Subject: Improve error message for extraneous '%}'. --- CHANGES.current | 3 +++ Examples/test-suite/errors/c_extra_rblock.stderr | 2 +- Source/Swig/scanner.c | 3 +++ 3 files changed, 7 insertions(+), 1 deletion(-) diff --git a/CHANGES.current b/CHANGES.current index 115a1b511..d875740a5 100644 --- a/CHANGES.current +++ b/CHANGES.current @@ -5,6 +5,9 @@ See the RELEASENOTES file for a summary of changes in each release. Version 3.0.4 (in progress) =========================== +2015-01-08: olly + Improve error message for extraneous '%}'. + 2015-01-08: olly Improve error message when an unknown SWIG directive is used - this previously gave the cryptic "Error: Syntax error in input(1).", but diff --git a/Examples/test-suite/errors/c_extra_rblock.stderr b/Examples/test-suite/errors/c_extra_rblock.stderr index 82877023a..be14eee4c 100644 --- a/Examples/test-suite/errors/c_extra_rblock.stderr +++ b/Examples/test-suite/errors/c_extra_rblock.stderr @@ -1 +1 @@ -c_extra_rblock.i:5: Error: Syntax error in input(1). +c_extra_rblock.i:5: Error: Syntax error. Extraneous '%}' diff --git a/Source/Swig/scanner.c b/Source/Swig/scanner.c index d8c3f7f3f..b0d608c9e 100644 --- a/Source/Swig/scanner.c +++ b/Source/Swig/scanner.c @@ -824,6 +824,9 @@ static int look(Scanner *s) { state = 7; } else if (c == '=') { return SWIG_TOKEN_MODEQUAL; + } else if (c == '}') { + Swig_error(cparse_file, cparse_line, "Syntax error. Extraneous '%%}'\n"); + exit(1); } else { retract(s, 1); return SWIG_TOKEN_PERCENT; -- cgit v1.2.1 From ce90ff6a77e32d97670eb6bc97b114b84af9dc4c Mon Sep 17 00:00:00 2001 From: Olly Betts Date: Thu, 8 Jan 2015 13:19:17 +1300 Subject: When reporting an error for a construct which hasn't been terminated when the end of the file is reached, report it at the start line rather than "EOF" as then tools like editors and IDEs will take you to a generally more useful place for fixing the problem. --- CHANGES.current | 7 +++++++ Examples/test-suite/errors/pp_missing_enddef.stderr | 2 +- Examples/test-suite/errors/pp_missing_endif.stderr | 2 +- Examples/test-suite/errors/pp_missing_endoffile.i | 7 +++++++ Examples/test-suite/errors/pp_missing_endoffile.stderr | 1 + Examples/test-suite/errors/pp_missing_rblock.stderr | 2 +- Examples/test-suite/errors/pp_unterm_char.stderr | 2 +- Examples/test-suite/errors/pp_unterm_comment.stderr | 2 +- Examples/test-suite/errors/pp_unterm_string.stderr | 2 +- Source/Preprocessor/cpp.c | 14 +++++++------- 10 files changed, 28 insertions(+), 13 deletions(-) create mode 100644 Examples/test-suite/errors/pp_missing_endoffile.i create mode 100644 Examples/test-suite/errors/pp_missing_endoffile.stderr diff --git a/CHANGES.current b/CHANGES.current index d875740a5..515ad8f61 100644 --- a/CHANGES.current +++ b/CHANGES.current @@ -5,6 +5,13 @@ See the RELEASENOTES file for a summary of changes in each release. Version 3.0.4 (in progress) =========================== +2015-01-08: olly + When reporting an error for a construct which hasn't been + terminated when the end of the file is reached, report it at the + start line rather than "EOF" as then tools like editors and IDEs + will take you to a generally more useful place for fixing the + problem. + 2015-01-08: olly Improve error message for extraneous '%}'. diff --git a/Examples/test-suite/errors/pp_missing_enddef.stderr b/Examples/test-suite/errors/pp_missing_enddef.stderr index bb4ea3c75..c461699e6 100644 --- a/Examples/test-suite/errors/pp_missing_enddef.stderr +++ b/Examples/test-suite/errors/pp_missing_enddef.stderr @@ -1 +1 @@ -pp_missing_enddef.i:EOF: Error: Missing %enddef for macro starting on line 3 +pp_missing_enddef.i:3: Error: Missing %enddef for macro starting here diff --git a/Examples/test-suite/errors/pp_missing_endif.stderr b/Examples/test-suite/errors/pp_missing_endif.stderr index 0bbfad7f2..4db4021aa 100644 --- a/Examples/test-suite/errors/pp_missing_endif.stderr +++ b/Examples/test-suite/errors/pp_missing_endif.stderr @@ -1 +1 @@ -pp_missing_endif.i:EOF: Error: Missing #endif for conditional starting on line 3 +pp_missing_endif.i:3: Error: Missing #endif for conditional starting here diff --git a/Examples/test-suite/errors/pp_missing_endoffile.i b/Examples/test-suite/errors/pp_missing_endoffile.i new file mode 100644 index 000000000..2074495a8 --- /dev/null +++ b/Examples/test-suite/errors/pp_missing_endoffile.i @@ -0,0 +1,7 @@ +%module xxx +/* %beginfile and %endoffile are internal directives inserted when %include is + * used. Users should never use them directly, but test coverage for this + * error message still seems useful to have. + */ +%includefile "dummy.i" %beginfile + diff --git a/Examples/test-suite/errors/pp_missing_endoffile.stderr b/Examples/test-suite/errors/pp_missing_endoffile.stderr new file mode 100644 index 000000000..7269f2e92 --- /dev/null +++ b/Examples/test-suite/errors/pp_missing_endoffile.stderr @@ -0,0 +1 @@ +pp_missing_endoffile.i:6: Error: Missing %endoffile for file inclusion block starting here diff --git a/Examples/test-suite/errors/pp_missing_rblock.stderr b/Examples/test-suite/errors/pp_missing_rblock.stderr index 8f4a54c0a..f00457d73 100644 --- a/Examples/test-suite/errors/pp_missing_rblock.stderr +++ b/Examples/test-suite/errors/pp_missing_rblock.stderr @@ -1 +1 @@ -pp_missing_rblock.i:EOF: Error: Unterminated %{ ... %} block starting on line 3 +pp_missing_rblock.i:3: Error: Unterminated %{ ... %} block diff --git a/Examples/test-suite/errors/pp_unterm_char.stderr b/Examples/test-suite/errors/pp_unterm_char.stderr index 4386e933d..147e3859d 100644 --- a/Examples/test-suite/errors/pp_unterm_char.stderr +++ b/Examples/test-suite/errors/pp_unterm_char.stderr @@ -1 +1 @@ -pp_unterm_char.i:EOF: Error: Unterminated character constant starting at line 4 +pp_unterm_char.i:4: Error: Unterminated character constant diff --git a/Examples/test-suite/errors/pp_unterm_comment.stderr b/Examples/test-suite/errors/pp_unterm_comment.stderr index 4ff34230c..ab1edac14 100644 --- a/Examples/test-suite/errors/pp_unterm_comment.stderr +++ b/Examples/test-suite/errors/pp_unterm_comment.stderr @@ -1 +1 @@ -pp_unterm_comment.i:EOF: Error: Unterminated comment starting on line 3 +pp_unterm_comment.i:3: Error: Unterminated comment diff --git a/Examples/test-suite/errors/pp_unterm_string.stderr b/Examples/test-suite/errors/pp_unterm_string.stderr index 16b4034f3..14e110ebb 100644 --- a/Examples/test-suite/errors/pp_unterm_string.stderr +++ b/Examples/test-suite/errors/pp_unterm_string.stderr @@ -1 +1 @@ -pp_unterm_string.i:EOF: Error: Unterminated string constant starting at line 4 +pp_unterm_string.i:4: Error: Unterminated string constant diff --git a/Source/Preprocessor/cpp.c b/Source/Preprocessor/cpp.c index b556bce27..8fd30f703 100644 --- a/Source/Preprocessor/cpp.c +++ b/Source/Preprocessor/cpp.c @@ -1376,12 +1376,12 @@ String *Preprocessor_parse(String *s) { else if (c == '\"') { start_line = Getline(s); if (skip_tochar(s, '\"', chunk) < 0) { - Swig_error(Getfile(s), -1, "Unterminated string constant starting at line %d\n", start_line); + Swig_error(Getfile(s), start_line, "Unterminated string constant\n"); } } else if (c == '\'') { start_line = Getline(s); if (skip_tochar(s, '\'', chunk) < 0) { - Swig_error(Getfile(s), -1, "Unterminated character constant starting at line %d\n", start_line); + Swig_error(Getfile(s), start_line, "Unterminated character constant\n"); } } else if (c == '/') state = 30; /* Comment */ @@ -2008,21 +2008,21 @@ String *Preprocessor_parse(String *s) { } } while (level > 0) { - Swig_error(Getfile(s), -1, "Missing #endif for conditional starting on line %d\n", cond_lines[level - 1]); + Swig_error(Getfile(s), cond_lines[level - 1], "Missing #endif for conditional starting here\n"); level--; } if (state == 120) { - Swig_error(Getfile(s), -1, "Missing %%endoffile for file inclusion block starting on line %d\n", start_line); + Swig_error(Getfile(s), start_line, "Missing %%endoffile for file inclusion block starting here\n"); } if (state == 150) { Seek(value, 0, SEEK_SET); - Swig_error(Getfile(s), -1, "Missing %%enddef for macro starting on line %d\n", Getline(value)); + Swig_error(Getfile(s), Getline(value), "Missing %%enddef for macro starting here\n", Getline(value)); } if ((state >= 105) && (state < 107)) { - Swig_error(Getfile(s), -1, "Unterminated %%{ ... %%} block starting on line %d\n", start_line); + Swig_error(Getfile(s), start_line, "Unterminated %%{ ... %%} block\n"); } if ((state >= 30) && (state < 40)) { - Swig_error(Getfile(s), -1, "Unterminated comment starting on line %d\n", start_line); + Swig_error(Getfile(s), start_line, "Unterminated comment\n"); } copy_location(s, chunk); -- cgit v1.2.1 From 8fbdd75a0b1a4f4728c430d4888bdca7b25427f8 Mon Sep 17 00:00:00 2001 From: Olly Betts Date: Thu, 8 Jan 2015 13:20:37 +1300 Subject: Add test coverage for unterminated %{ ... %} block --- Examples/test-suite/errors/pp_unterminated_block.i | 5 +++++ Examples/test-suite/errors/pp_unterminated_block.stderr | 1 + 2 files changed, 6 insertions(+) create mode 100644 Examples/test-suite/errors/pp_unterminated_block.i create mode 100644 Examples/test-suite/errors/pp_unterminated_block.stderr diff --git a/Examples/test-suite/errors/pp_unterminated_block.i b/Examples/test-suite/errors/pp_unterminated_block.i new file mode 100644 index 000000000..99f5f0bc2 --- /dev/null +++ b/Examples/test-suite/errors/pp_unterminated_block.i @@ -0,0 +1,5 @@ +%module xxx + +%{ +int foo(int x); + diff --git a/Examples/test-suite/errors/pp_unterminated_block.stderr b/Examples/test-suite/errors/pp_unterminated_block.stderr new file mode 100644 index 000000000..03c16a45f --- /dev/null +++ b/Examples/test-suite/errors/pp_unterminated_block.stderr @@ -0,0 +1 @@ +pp_unterminated_block.i:3: Error: Unterminated %{ ... %} block -- cgit v1.2.1 From d315187a1cd41fb62a18770d9e59469b49f509d2 Mon Sep 17 00:00:00 2001 From: Olly Betts Date: Thu, 8 Jan 2015 14:15:46 +1300 Subject: Fix typo in old entry --- CHANGES | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/CHANGES b/CHANGES index 1741c7ea7..5b8355f76 100644 --- a/CHANGES +++ b/CHANGES @@ -4447,7 +4447,7 @@ Version 1.3.32 (November 15, 2007) %attributeref(Class, AttributeType, AttributeName, AccessorMethod) 10/16/2007: olly - [Tcl] Fix several ocurrences of "warning: deprecated conversion + [Tcl] Fix several occurrences of "warning: deprecated conversion from string constant to 'char*'" from GCC 4.2 in generated C/C++ code. -- cgit v1.2.1 From 62670e756e188e03bb78cc5f371dfa88989783cc Mon Sep 17 00:00:00 2001 From: Olly Betts Date: Thu, 8 Jan 2015 15:27:57 +1300 Subject: Improve errors for missing ; and unexpected ) --- CHANGES.current | 8 ++------ Examples/test-suite/errors/c_missing_semi.stderr | 2 +- Examples/test-suite/errors/cpp_extra_brackets.stderr | 2 +- Source/CParse/parser.y | 9 +++++++++ 4 files changed, 13 insertions(+), 8 deletions(-) diff --git a/CHANGES.current b/CHANGES.current index 515ad8f61..564135d08 100644 --- a/CHANGES.current +++ b/CHANGES.current @@ -13,12 +13,8 @@ Version 3.0.4 (in progress) problem. 2015-01-08: olly - Improve error message for extraneous '%}'. - -2015-01-08: olly - Improve error message when an unknown SWIG directive is used - this - previously gave the cryptic "Error: Syntax error in input(1).", but - now gives "Error: Unknown directive '%foo'." + Improve error messages for a few cases which previously gave the + one of the cryptic catch-all errors "Syntax error in input". 2015-01-08: olly Provide -cppext as a general command line option for setting the diff --git a/Examples/test-suite/errors/c_missing_semi.stderr b/Examples/test-suite/errors/c_missing_semi.stderr index 791b959ca..9f539e4ab 100644 --- a/Examples/test-suite/errors/c_missing_semi.stderr +++ b/Examples/test-suite/errors/c_missing_semi.stderr @@ -1 +1 @@ -c_missing_semi.i:3: Error: Syntax error in input(1). +c_missing_semi.i:3: Error: Syntax error - missing ';'? diff --git a/Examples/test-suite/errors/cpp_extra_brackets.stderr b/Examples/test-suite/errors/cpp_extra_brackets.stderr index 12bb1f327..f1fabc78d 100644 --- a/Examples/test-suite/errors/cpp_extra_brackets.stderr +++ b/Examples/test-suite/errors/cpp_extra_brackets.stderr @@ -1 +1 @@ -cpp_extra_brackets.i:5: Error: Syntax error in input(3). +cpp_extra_brackets.i:5: Error: Unexpected ')'. diff --git a/Source/CParse/parser.y b/Source/CParse/parser.y index 4bee5f127..9de6a1b07 100644 --- a/Source/CParse/parser.y +++ b/Source/CParse/parser.y @@ -3024,6 +3024,15 @@ c_decl_tail : SEMI { skip_balanced('{','}'); $$ = 0; } + | error { + $$ = 0; + if (yychar == RPAREN) { + Swig_error(cparse_file, cparse_line, "Unexpected ')'.\n"); + } else { + Swig_error(cparse_file, cparse_line, "Syntax error - missing ';'?\n"); + } + exit(1); + } ; initializer : def_args { -- cgit v1.2.1 From 87bdaa3910ebf9ba74704f9753970a83906e7507 Mon Sep 17 00:00:00 2001 From: Olly Betts Date: Thu, 8 Jan 2015 15:56:50 +1300 Subject: Allow C++11 "explicit constexpr" --- CHANGES.current | 4 ++++ Examples/test-suite/cpp11_constexpr.i | 2 ++ Source/CParse/parser.y | 1 + 3 files changed, 7 insertions(+) diff --git a/CHANGES.current b/CHANGES.current index 564135d08..880453b53 100644 --- a/CHANGES.current +++ b/CHANGES.current @@ -5,6 +5,10 @@ See the RELEASENOTES file for a summary of changes in each release. Version 3.0.4 (in progress) =========================== +2015-01-08: olly + Allow C++11 "explicit constexpr". Fixes github issue#284 reported + by Paweł Tomulik. + 2015-01-08: olly When reporting an error for a construct which hasn't been terminated when the end of the file is reached, report it at the diff --git a/Examples/test-suite/cpp11_constexpr.i b/Examples/test-suite/cpp11_constexpr.i index 412b8132a..d8de0ae1d 100644 --- a/Examples/test-suite/cpp11_constexpr.i +++ b/Examples/test-suite/cpp11_constexpr.i @@ -18,6 +18,8 @@ struct ConstExpressions { static const int LLL = 300; constexpr int MMM() { return 400; } constexpr const int NNN() { return 500; } + // Regression test for https://github.com/swig/swig/issues/284 : + explicit constexpr ConstExpressions(int) { } }; %} diff --git a/Source/CParse/parser.y b/Source/CParse/parser.y index 9de6a1b07..5e4dc24d7 100644 --- a/Source/CParse/parser.y +++ b/Source/CParse/parser.y @@ -4680,6 +4680,7 @@ storage_class : EXTERN { $$ = "extern"; } | FRIEND { $$ = "friend"; } | EXPLICIT { $$ = "explicit"; } | CONSTEXPR { $$ = "constexpr"; } + | EXPLICIT CONSTEXPR { $$ = "explicit constexpr"; } | STATIC CONSTEXPR { $$ = "static constexpr"; } | THREAD_LOCAL { $$ = "thread_local"; } | THREAD_LOCAL STATIC { $$ = "static thread_local"; } -- cgit v1.2.1 From bfa570e404d1808d8b2f4c6b39fc5829d9aafeaa Mon Sep 17 00:00:00 2001 From: Olly Betts Date: Fri, 9 Jan 2015 11:47:40 +1300 Subject: Handle "constexpr explicit" and "constexpr static" --- CHANGES.current | 3 ++- Examples/test-suite/cpp11_constexpr.i | 6 +++++- Source/CParse/parser.y | 2 ++ 3 files changed, 9 insertions(+), 2 deletions(-) diff --git a/CHANGES.current b/CHANGES.current index 880453b53..50de69c90 100644 --- a/CHANGES.current +++ b/CHANGES.current @@ -7,7 +7,8 @@ Version 3.0.4 (in progress) 2015-01-08: olly Allow C++11 "explicit constexpr". Fixes github issue#284 reported - by Paweł Tomulik. + by Paweł Tomulik. Also handle "constexpr explicit" and "constexpr + static". 2015-01-08: olly When reporting an error for a construct which hasn't been diff --git a/Examples/test-suite/cpp11_constexpr.i b/Examples/test-suite/cpp11_constexpr.i index d8de0ae1d..d91107cc6 100644 --- a/Examples/test-suite/cpp11_constexpr.i +++ b/Examples/test-suite/cpp11_constexpr.i @@ -18,8 +18,12 @@ struct ConstExpressions { static const int LLL = 300; constexpr int MMM() { return 400; } constexpr const int NNN() { return 500; } - // Regression test for https://github.com/swig/swig/issues/284 : + // Regression tests for support added in SWIG 3.0.4: + static constexpr const int JJJ1 = 101; + constexpr static int KKK1 = 201; + // Regression tests for https://github.com/swig/swig/issues/284 : explicit constexpr ConstExpressions(int) { } + constexpr explicit ConstExpressions(double) { } }; %} diff --git a/Source/CParse/parser.y b/Source/CParse/parser.y index 5e4dc24d7..4f48b62ff 100644 --- a/Source/CParse/parser.y +++ b/Source/CParse/parser.y @@ -4681,7 +4681,9 @@ storage_class : EXTERN { $$ = "extern"; } | EXPLICIT { $$ = "explicit"; } | CONSTEXPR { $$ = "constexpr"; } | EXPLICIT CONSTEXPR { $$ = "explicit constexpr"; } + | CONSTEXPR EXPLICIT { $$ = "explicit constexpr"; } | STATIC CONSTEXPR { $$ = "static constexpr"; } + | CONSTEXPR STATIC { $$ = "static constexpr"; } | THREAD_LOCAL { $$ = "thread_local"; } | THREAD_LOCAL STATIC { $$ = "static thread_local"; } | STATIC THREAD_LOCAL { $$ = "static thread_local"; } -- cgit v1.2.1 From af43f904843f02a2d221922e61f30405badec6f1 Mon Sep 17 00:00:00 2001 From: William S Fulton Date: Thu, 8 Jan 2015 19:35:16 +0000 Subject: Wording change for missing semicolon error --- Examples/test-suite/errors/c_missing_semi.stderr | 2 +- Source/CParse/parser.y | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/Examples/test-suite/errors/c_missing_semi.stderr b/Examples/test-suite/errors/c_missing_semi.stderr index 9f539e4ab..18befaa1b 100644 --- a/Examples/test-suite/errors/c_missing_semi.stderr +++ b/Examples/test-suite/errors/c_missing_semi.stderr @@ -1 +1 @@ -c_missing_semi.i:3: Error: Syntax error - missing ';'? +c_missing_semi.i:3: Error: Syntax error - possibly a missing semicolon. diff --git a/Source/CParse/parser.y b/Source/CParse/parser.y index 4f48b62ff..1fb759081 100644 --- a/Source/CParse/parser.y +++ b/Source/CParse/parser.y @@ -3029,7 +3029,7 @@ c_decl_tail : SEMI { if (yychar == RPAREN) { Swig_error(cparse_file, cparse_line, "Unexpected ')'.\n"); } else { - Swig_error(cparse_file, cparse_line, "Syntax error - missing ';'?\n"); + Swig_error(cparse_file, cparse_line, "Syntax error - possibly a missing semicolon.\n"); } exit(1); } -- cgit v1.2.1 From 34787ab98e86b1c82a4d41cecf58ff01d816a4ae Mon Sep 17 00:00:00 2001 From: Vadim Zeitlin Date: Mon, 5 Jan 2015 02:50:24 +0100 Subject: Python default argument test cases from issue #294 --- Examples/test-suite/default_args.i | 13 +++++++++++++ 1 file changed, 13 insertions(+) diff --git a/Examples/test-suite/default_args.i b/Examples/test-suite/default_args.i index 839d28e3e..50667d9b9 100644 --- a/Examples/test-suite/default_args.i +++ b/Examples/test-suite/default_args.i @@ -13,6 +13,12 @@ %inline %{ #include + // All kinds of numbers: hex, octal (which pose special problems to Python), negative... + void lots_of_args(int pos = -1, unsigned rgb = 0xabcdef, int mode = 0644) { } + + // Long long arguments are not handled at Python level currently but still work. + void seek(long long offset = 0LL) {} + // Anonymous arguments int anonymous(int = 7771); int anonymous(int x) { return x; } @@ -29,6 +35,12 @@ bool blah(speed s = FAST, flavor f = SWEET) { return (s == FAST && f == SWEET); }; }; + // using base class enum in a derived class + class DerivedEnumClass : public EnumClass { + public: + void accelerate(speed s = SLOW) { } + }; + // casts const char * casts1(const char *m = (const char *) NULL) { char *ret = NULL; @@ -199,6 +211,7 @@ namespace Space { struct Klass { int val; Klass(int val = -1) : val(val) {} + static Klass inc(int n = 1, const Klass& k = Klass()) { return Klass(k.val + n); } }; Klass constructorcall(const Klass& k = Klass()) { return k; } -- cgit v1.2.1 From 38ba81811e4fd7743570cf3ca6b9a57a720444a1 Mon Sep 17 00:00:00 2001 From: William S Fulton Date: Thu, 8 Jan 2015 23:33:47 +0000 Subject: Fix Python default argument handing broken since swig-3.0.3 Default values are no longer generated as Python code by default. They must be explicitly turned on using the "python:defaultargs" feature. Closes #294 Closes #296 The problems in these two issues when "python:defaultargs" is turned on still need to be fixed and should be addressed in separate patches. The important thing is the default code generation is now fixed. --- CHANGES.current | 10 ++ Examples/test-suite/default_args.i | 4 +- Examples/test-suite/python/Makefile.in | 1 + Examples/test-suite/python/default_args_runme.py | 156 ++++++++++++--------- .../test-suite/python/python_default_args_runme.py | 3 + Examples/test-suite/python_default_args.i | 10 ++ Lib/python/pyuserdir.swg | 10 ++ Source/Modules/python.cxx | 42 +++--- 8 files changed, 153 insertions(+), 83 deletions(-) create mode 100644 Examples/test-suite/python/python_default_args_runme.py create mode 100644 Examples/test-suite/python_default_args.i diff --git a/CHANGES.current b/CHANGES.current index 50de69c90..7c9712f0e 100644 --- a/CHANGES.current +++ b/CHANGES.current @@ -5,6 +5,16 @@ See the RELEASENOTES file for a summary of changes in each release. Version 3.0.4 (in progress) =========================== +2015-01-08: wsfulton + [Python] Fix #294 #296 - Regression introduced in SWIG-3.0.3 when + wrapping functions with default arguments. Now any method with default + arguments obtains the default arguments from C++ instead of generating + Python code with the default arguments. + + The "python:defaultargs" feature has been introduced for users to + optionally generate Python methods with the default arguments instead + the default *args. + 2015-01-08: olly Allow C++11 "explicit constexpr". Fixes github issue#284 reported by Paweł Tomulik. Also handle "constexpr explicit" and "constexpr diff --git a/Examples/test-suite/default_args.i b/Examples/test-suite/default_args.i index 50667d9b9..cd66676ac 100644 --- a/Examples/test-suite/default_args.i +++ b/Examples/test-suite/default_args.i @@ -14,7 +14,9 @@ #include // All kinds of numbers: hex, octal (which pose special problems to Python), negative... - void lots_of_args(int pos = -1, unsigned rgb = 0xabcdef, int mode = 0644) { } + void trickyvalue1(int first, int pos = -1) {} + void trickyvalue2(int first, unsigned rgb = 0xabcdef) {} + void trickyvalue3(int first, int mode = 0644) {} // Long long arguments are not handled at Python level currently but still work. void seek(long long offset = 0LL) {} diff --git a/Examples/test-suite/python/Makefile.in b/Examples/test-suite/python/Makefile.in index 82a0e9db1..3c87577a2 100644 --- a/Examples/test-suite/python/Makefile.in +++ b/Examples/test-suite/python/Makefile.in @@ -58,6 +58,7 @@ CPP_TEST_CASES += \ primitive_types \ python_abstractbase \ python_append \ + python_default_args \ python_director \ python_nondynamic \ python_overload_simple_cast \ diff --git a/Examples/test-suite/python/default_args_runme.py b/Examples/test-suite/python/default_args_runme.py index ad5e03d11..45465bac9 100644 --- a/Examples/test-suite/python/default_args_runme.py +++ b/Examples/test-suite/python/default_args_runme.py @@ -1,67 +1,91 @@ -import default_args - -ec = default_args.EnumClass() -if not ec.blah(): - raise RuntimeError,"EnumClass::blah() default arguments don't work" - -if default_args.Statics_staticMethod() != 60: - raise RuntimeError - -if default_args.cfunc1(1) != 2: - raise RuntimeError - -if default_args.cfunc2(1) != 3: - raise RuntimeError - -if default_args.cfunc3(1) != 4: - raise RuntimeError - - -f = default_args.Foo() - -f.newname() -f.newname(1) - - -try: - f = default_args.Foo(1) - error = 1 -except: - error = 0 -if error: raise RuntimeError,"Foo::Foo ignore is not working" - -try: - f = default_args.Foo(1,2) - error = 1 -except: - error = 0 -if error: raise RuntimeError,"Foo::Foo ignore is not working" - -try: - f = default_args.Foo(1,2,3) - error = 1 -except: - error = 0 -if error: raise RuntimeError,"Foo::Foo ignore is not working" - -try: - m = f.meth(1) - error = 1 -except: - error = 0 -if error: raise RuntimeError,"Foo::meth ignore is not working" - -try: - m = f.meth(1,2) - error = 1 -except: - error = 0 -if error: raise RuntimeError,"Foo::meth ignore is not working" - -try: - m = f.meth(1,2,3) - error = 1 -except: - error = 0 -if error: raise RuntimeError,"Foo::meth ignore is not working" +# Note that this test is also used by python_default_args_runme.py hence the use of __main__ and the run function + +def run(module_name): + default_args = __import__(module_name) + print "running...." + ec = default_args.EnumClass() + if not ec.blah(): + raise RuntimeError,"EnumClass::blah() default arguments don't work" + + de = default_args.DerivedEnumClass() + de.accelerate() + de.accelerate(default_args.EnumClass.SLOW) + + if default_args.Statics_staticMethod() != 60: + raise RuntimeError + + if default_args.cfunc1(1) != 2: + raise RuntimeError + + if default_args.cfunc2(1) != 3: + raise RuntimeError + + if default_args.cfunc3(1) != 4: + raise RuntimeError + + + f = default_args.Foo() + + f.newname() + f.newname(1) + + + try: + f = default_args.Foo(1) + error = 1 + except: + error = 0 + if error: raise RuntimeError,"Foo::Foo ignore is not working" + + try: + f = default_args.Foo(1,2) + error = 1 + except: + error = 0 + if error: raise RuntimeError,"Foo::Foo ignore is not working" + + try: + f = default_args.Foo(1,2,3) + error = 1 + except: + error = 0 + if error: raise RuntimeError,"Foo::Foo ignore is not working" + + try: + m = f.meth(1) + error = 1 + except: + error = 0 + if error: raise RuntimeError,"Foo::meth ignore is not working" + + try: + m = f.meth(1,2) + error = 1 + except: + error = 0 + if error: raise RuntimeError,"Foo::meth ignore is not working" + + try: + m = f.meth(1,2,3) + error = 1 + except: + error = 0 + if error: raise RuntimeError,"Foo::meth ignore is not working" + + if default_args.Klass.inc(100, default_args.Klass(22)).val != 122: + raise RuntimeError, "Klass::inc failed" + + if default_args.Klass.inc(100).val != 99: + raise RuntimeError, "Klass::inc failed" + + if default_args.Klass.inc().val != 0: + raise RuntimeError, "Klass::inc failed" + + default_args.trickyvalue1(10); default_args.trickyvalue1(10, 10) + default_args.trickyvalue2(10); default_args.trickyvalue2(10, 10) + default_args.trickyvalue3(10); default_args.trickyvalue3(10, 10) + default_args.seek(); default_args.seek(10) + +if __name__=="__main__": + run('default_args') diff --git a/Examples/test-suite/python/python_default_args_runme.py b/Examples/test-suite/python/python_default_args_runme.py new file mode 100644 index 000000000..7f35fbed6 --- /dev/null +++ b/Examples/test-suite/python/python_default_args_runme.py @@ -0,0 +1,3 @@ +# Test %feature("python:defaultargs") using the test code in default_args_runme.py (which does not use the feature) +import default_args_runme +default_args_runme.run('python_default_args') diff --git a/Examples/test-suite/python_default_args.i b/Examples/test-suite/python_default_args.i new file mode 100644 index 000000000..66e66a671 --- /dev/null +++ b/Examples/test-suite/python_default_args.i @@ -0,0 +1,10 @@ +%module python_default_args + +%pythondefaultargs; + +// Turn off the feature for the tricky cases that can't be handled +%nopythondefaultargs seek; +%nopythondefaultargs Space::Klass::inc; +%nopythondefaultargs DerivedEnumClass::accelerate; + +%include "default_args.i" diff --git a/Lib/python/pyuserdir.swg b/Lib/python/pyuserdir.swg index d3c3eb188..2a1d80790 100644 --- a/Lib/python/pyuserdir.swg +++ b/Lib/python/pyuserdir.swg @@ -185,6 +185,16 @@ These methods "may be called" if needed. #define %clearpythonappend %feature("pythonappend","") +/* ------------------------------------------------------------------------- */ +/* + Python default argument handling (for non-builtin) +*/ + +#define %pythondefaultargs %feature("python:defaultargs") +#define %nopythondefaultargs %feature("python:defaultargs", "0") +#define %clearpythondefaultargs %feature("python:defaultargs", "") + + /* ------------------------------------------------------------------------- */ /* diff --git a/Source/Modules/python.cxx b/Source/Modules/python.cxx index 6a0b286ca..217d7ce7d 100644 --- a/Source/Modules/python.cxx +++ b/Source/Modules/python.cxx @@ -1856,27 +1856,37 @@ public: * at C++ code level where they can always be handled. * ------------------------------------------------------------ */ bool is_representable_as_pyargs(Node *n) { - ParmList *plist = CopyParmList(Getattr(n, "parms")); - Parm *p; - Parm *pnext; + bool is_representable = true; - for (p = plist; p; p = pnext) { - String *tm = Getattr(p, "tmap:in"); - if (tm) { - pnext = Getattr(p, "tmap:in:next"); - if (checkAttribute(p, "tmap:in:numinputs", "0")) { - continue; + if (Getattr(n, "sym:overloaded")) { + if (GetFlag(n, "feature:python:defaultargs")) { + ParmList *plist = CopyParmList(Getattr(n, "parms")); + Parm *p; + Parm *pnext; + + for (p = plist; p; p = pnext) { + String *tm = Getattr(p, "tmap:in"); + if (tm) { + pnext = Getattr(p, "tmap:in:next"); + if (checkAttribute(p, "tmap:in:numinputs", "0")) { + continue; + } + } else { + pnext = nextSibling(p); + } + if (String *value = Getattr(p, "value")) { + String *type = Getattr(p, "type"); + if (!convertValue(value, type)) { + is_representable = false; + break; + } + } } } else { - pnext = nextSibling(p); - } - if (String *value = Getattr(p, "value")) { - String *type = Getattr(p, "type"); - if (!convertValue(value, type)) - return false; + is_representable = false; } } - return true; + return is_representable; } -- cgit v1.2.1 From efb8784c8b9240bac0868f2de3ac70289aea9b0d Mon Sep 17 00:00:00 2001 From: William S Fulton Date: Thu, 8 Jan 2015 23:54:50 +0000 Subject: Fix python default_args testcase for Python 3 Changes for the default_args testcase to run under Python 3 when called from python_default_args testcase --- Examples/test-suite/python/default_args_runme.py | 21 ++++++++++----------- Examples/test-suite/python_default_args.i | 1 + 2 files changed, 11 insertions(+), 11 deletions(-) diff --git a/Examples/test-suite/python/default_args_runme.py b/Examples/test-suite/python/default_args_runme.py index 45465bac9..f24e825ad 100644 --- a/Examples/test-suite/python/default_args_runme.py +++ b/Examples/test-suite/python/default_args_runme.py @@ -2,10 +2,9 @@ def run(module_name): default_args = __import__(module_name) - print "running...." ec = default_args.EnumClass() if not ec.blah(): - raise RuntimeError,"EnumClass::blah() default arguments don't work" + raise RuntimeError("EnumClass::blah() default arguments don't work") de = default_args.DerivedEnumClass() de.accelerate() @@ -35,51 +34,51 @@ def run(module_name): error = 1 except: error = 0 - if error: raise RuntimeError,"Foo::Foo ignore is not working" + if error: raise RuntimeError("Foo::Foo ignore is not working") try: f = default_args.Foo(1,2) error = 1 except: error = 0 - if error: raise RuntimeError,"Foo::Foo ignore is not working" + if error: raise RuntimeError("Foo::Foo ignore is not working") try: f = default_args.Foo(1,2,3) error = 1 except: error = 0 - if error: raise RuntimeError,"Foo::Foo ignore is not working" + if error: raise RuntimeError("Foo::Foo ignore is not working") try: m = f.meth(1) error = 1 except: error = 0 - if error: raise RuntimeError,"Foo::meth ignore is not working" + if error: raise RuntimeError("Foo::meth ignore is not working") try: m = f.meth(1,2) error = 1 except: error = 0 - if error: raise RuntimeError,"Foo::meth ignore is not working" + if error: raise RuntimeError("Foo::meth ignore is not working") try: m = f.meth(1,2,3) error = 1 except: error = 0 - if error: raise RuntimeError,"Foo::meth ignore is not working" + if error: raise RuntimeError("Foo::meth ignore is not working") if default_args.Klass.inc(100, default_args.Klass(22)).val != 122: - raise RuntimeError, "Klass::inc failed" + raise RuntimeError("Klass::inc failed") if default_args.Klass.inc(100).val != 99: - raise RuntimeError, "Klass::inc failed" + raise RuntimeError("Klass::inc failed") if default_args.Klass.inc().val != 0: - raise RuntimeError, "Klass::inc failed" + raise RuntimeError("Klass::inc failed") default_args.trickyvalue1(10); default_args.trickyvalue1(10, 10) default_args.trickyvalue2(10); default_args.trickyvalue2(10, 10) diff --git a/Examples/test-suite/python_default_args.i b/Examples/test-suite/python_default_args.i index 66e66a671..01c090342 100644 --- a/Examples/test-suite/python_default_args.i +++ b/Examples/test-suite/python_default_args.i @@ -3,6 +3,7 @@ %pythondefaultargs; // Turn off the feature for the tricky cases that can't be handled +%nopythondefaultargs trickyvalue3; // 'mode=0644' is okay in Python 2, but no Python 3 %nopythondefaultargs seek; %nopythondefaultargs Space::Klass::inc; %nopythondefaultargs DerivedEnumClass::accelerate; -- cgit v1.2.1 From 4b5ed45d50349e762ecae221ea5a516da15ba6ac Mon Sep 17 00:00:00 2001 From: Olly Betts Date: Fri, 9 Jan 2015 14:50:15 +1300 Subject: Add note about delimiting blocks of Python code Using { and } to delimit means Python comments will cause errors with SWIG 3.0.3 and later. With older SWIG it usually just meant such comments failed to appear in the generated output. See issue #221. --- Doc/Manual/Python.html | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/Doc/Manual/Python.html b/Doc/Manual/Python.html index 234117464..eb102aa3e 100644 --- a/Doc/Manual/Python.html +++ b/Doc/Manual/Python.html @@ -3368,6 +3368,18 @@ print("Loading", "Whizz", "Bang", sep=' ... ')
  • +

    When using %pythoncode and %pythonbegin you generally +want to make sure that the block is delimited by %{ and %}. +If you delimit it with { and } then any lines with a +leading # will be handled by SWIG as preprocessor directives, when +you probably meant them as Python comments. Prior to SWIG 3.0.3, invalid +preprocessor directives were silently ignored, so generally using the wrong +delimiters resulted in such comments not appearing in the generated output +(though a comment starting with a valid preprocessor directive could cause +problems, for example: # error handling). SWIG 3.0.3 and later report +an error for invalid preprocessor directives, so you may have to update +existing interface files to delimit blocks of Python code correctly.

    +

    Sometimes you may want to replace or modify the wrapper function that SWIG creates in the proxy .py file. The Python module in SWIG provides some features that enable you to do this. First, to -- cgit v1.2.1 From 4e7af7db808c07ee4fad34e27fa93d639f2fdf26 Mon Sep 17 00:00:00 2001 From: Thomas Trocha Date: Sun, 11 Jan 2015 15:34:07 +0100 Subject: [lua/luarun] change return type from int to void on functions not returning anything Using emscripten compiler to crosscompile to javascript lead to "traps" on this functions which results in a crash --- Lib/lua/luarun.swg | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/Lib/lua/luarun.swg b/Lib/lua/luarun.swg index 8803c66f6..d9124887d 100644 --- a/Lib/lua/luarun.swg +++ b/Lib/lua/luarun.swg @@ -1161,7 +1161,7 @@ SWIGINTERN void SWIG_Lua_init_base_class(lua_State *L,swig_lua_class *clss) #if defined(SWIG_LUA_SQUASH_BASES) && (SWIG_LUA_TARGET == SWIG_LUA_FLAVOR_LUA) /* Merges two tables */ -SWIGINTERN int SWIG_Lua_merge_tables_by_index(lua_State *L, int target, int source) +SWIGINTERN void SWIG_Lua_merge_tables_by_index(lua_State *L, int target, int source) { /* iterating */ lua_pushnil(L); @@ -1177,7 +1177,7 @@ SWIGINTERN int SWIG_Lua_merge_tables_by_index(lua_State *L, int target, int sour } /* Merges two tables with given name. original - index of target metatable, base - index of source metatable */ -SWIGINTERN int SWIG_Lua_merge_tables(lua_State *L, const char* name, int original, int base) +SWIGINTERN void SWIG_Lua_merge_tables(lua_State *L, const char* name, int original, int base) { /* push original[name], then base[name] */ lua_pushstring(L,name); @@ -1192,7 +1192,7 @@ SWIGINTERN int SWIG_Lua_merge_tables(lua_State *L, const char* name, int origina } /* Function takes all symbols from base and adds it to derived class. It's just a helper. */ -SWIGINTERN int SWIG_Lua_class_squash_base(lua_State *L, swig_lua_class *base_cls) +SWIGINTERN void SWIG_Lua_class_squash_base(lua_State *L, swig_lua_class *base_cls) { /* There is one parameter - original, i.e. 'derived' class metatable */ assert(lua_istable(L,-1)); @@ -1206,7 +1206,7 @@ SWIGINTERN int SWIG_Lua_class_squash_base(lua_State *L, swig_lua_class *base_cls } /* Function squashes all symbols from 'clss' bases into itself */ -SWIGINTERN int SWIG_Lua_class_squash_bases(lua_State *L, swig_lua_class *clss) +SWIGINTERN void SWIG_Lua_class_squash_bases(lua_State *L, swig_lua_class *clss) { int i; SWIG_Lua_get_class_metatable(L,clss->fqname); -- cgit v1.2.1 From adbe3f2e779a000d2688e758d3530752b24000bf Mon Sep 17 00:00:00 2001 From: Vadim Zeitlin Date: Sun, 11 Jan 2015 16:42:21 +0000 Subject: Python default arg improvements Merge the code fixes from patch #294 to more reliably generate default argument values into the python layer. --- Source/Modules/python.cxx | 144 +++++++++++++++++++++++++++++++++++++++++----- 1 file changed, 130 insertions(+), 14 deletions(-) diff --git a/Source/Modules/python.cxx b/Source/Modules/python.cxx index 217d7ce7d..ed19e0b46 100644 --- a/Source/Modules/python.cxx +++ b/Source/Modules/python.cxx @@ -17,6 +17,8 @@ static int treduce = SWIG_cparse_template_reduce(0); #include +#include +#include #define PYSHADOW_MEMBER 0x2 #define WARN_PYTHON_MULTIPLE_INH 405 @@ -1814,20 +1816,129 @@ public: return doc; } + /* ------------------------------------------------------------ + * convertDoubleValue() + * Check if the given string looks like a decimal floating point constant + * and return it if it does, otherwise return NIL. + * ------------------------------------------------------------ */ + String *convertDoubleValue(String *v) { + const char *const s = Char(v); + char *end; + + (void)strtod(s, &end); + if (errno != ERANGE && end != s) { + // An added complication: at least some versions of strtod() recognize + // hexadecimal floating point numbers which don't exist in Python, so + // detect them ourselves and refuse to convert them (this can't be done + // without loss of precision in general). + // + // Also don't accept neither "NAN" nor "INFINITY" (both of which + // conveniently contain "n"). + if (strpbrk(s, "xXnN")) + return NIL; + + // Disregard optional "f" suffix, it can be just dropped in Python as it + // uses doubles for everything anyhow. + for (char* p = end; *p != '\0'; ++p) { + switch (*p) { + case 'f': + case 'F': + break; + + default: + return NIL; + } + } + + // Avoid unnecessary string allocation in the common case when we don't + // need to remove any suffix. + return *end == '\0' ? v : NewStringWithSize(s, end - s); + } + + return NIL; + } + /* ------------------------------------------------------------ * convertValue() * Check if string v can be a Python value literal or a * constant. Return NIL if it isn't. * ------------------------------------------------------------ */ String *convertValue(String *v, SwigType *t) { - char fc = (Char(v))[0]; - if (('0' <= fc && fc <= '9') || '\'' == fc || '"' == fc) { - /* number or string (or maybe NULL pointer) */ - if (SwigType_ispointer(t) && Strcmp(v, "0") == 0) - return NewString("None"); - else - return v; + const char *const s = Char(v); + char *end; + + // Check if this is a number in any base. + (void)strtol(s, &end, 0); + if (end != s) { + if (errno == ERANGE) { + // There was an overflow, we could try representing the value as Python + // long integer literal, but for now don't bother with it. + return NIL; + } + + if (*end != '\0') { + // If there is a suffix after the number, we can safely ignore any + // combination of "l" and "u", but not anything else (again, stuff like + // "LL" could be handled, but we don't bother to do it currently). + bool seen_long = false; + for (char* p = end; *p != '\0'; ++p) { + switch (*p) { + case 'l': + case 'L': + // Bail out on "LL". + if (seen_long) + return NIL; + seen_long = true; + break; + + case 'u': + case 'U': + break; + + default: + // Except that our suffix could actually be the fractional part of + // a floating point number, so we still have to check for this. + return convertDoubleValue(v); + } + } + } + + // Deal with the values starting with 0 first as they can be octal or + // hexadecimal numbers or even pointers. + if (s[0] == '0') { + if (Len(v) == 1) { + // This is just a lone 0, but it needs to be represented differently + // in Python depending on whether it's a zero or a null pointer. + if (SwigType_ispointer(t)) + return NewString("None"); + else + return v; + } else if (s[1] == 'x' || s[1] == 'X') { + // This must have been a hex number, we can use it directly in Python, + // so nothing to do here. + } else { + // This must have been an octal number, we have to change its prefix + // to be "0o" in Python 3 only (and as long as we still support Python + // 2.5, this can't be done unconditionally). + if (py3) { + String *res = NewString("0o"); + Append(res, NewStringWithSize(s + 1, end - s - 1)); + return res; + } + } + } + + // Avoid unnecessary string allocation in the common case when we don't + // need to remove any suffix. + return *end == '\0' ? v : NewStringWithSize(s, end - s); + } + + // Check if this is a floating point number (notice that it wasn't + // necessarily parsed as a long above, consider e.g. ".123"). + if (String *res = convertDoubleValue(v)) { + return res; } + if (Strcmp(v, "true") == 0 || Strcmp(v, "TRUE") == 0) return NewString("True"); if (Strcmp(v, "false") == 0 || Strcmp(v, "FALSE") == 0) @@ -1835,12 +1946,15 @@ public: if (Strcmp(v, "NULL") == 0 || Strcmp(v, "nullptr") == 0) return SwigType_ispointer(t) ? NewString("None") : NewString("0"); - // This could also be an enum type, default value of which is perfectly - // representable in Python. - Node *lookup = Swig_symbol_clookup(v, 0); - if (lookup) { - if (Cmp(Getattr(lookup, "nodeType"), "enumitem") == 0) - return Getattr(lookup, "sym:name"); + // This could also be an enum type, default value of which could be + // representable in Python if it doesn't include any scope (which could, + // but currently is not, translated). + if (!Strchr(s, ':')) { + Node *lookup = Swig_symbol_clookup(v, 0); + if (lookup) { + if (Cmp(Getattr(lookup, "nodeType"), "enumitem") == 0) + return Getattr(lookup, "sym:name"); + } } return NIL; @@ -1865,13 +1979,15 @@ public: Parm *pnext; for (p = plist; p; p = pnext) { + pnext = NIL; String *tm = Getattr(p, "tmap:in"); if (tm) { pnext = Getattr(p, "tmap:in:next"); if (checkAttribute(p, "tmap:in:numinputs", "0")) { continue; } - } else { + } + if (!pnext) { pnext = nextSibling(p); } if (String *value = Getattr(p, "value")) { -- cgit v1.2.1 From 679f9395bc6706c5b438dbb227fbccaaaa599324 Mon Sep 17 00:00:00 2001 From: William S Fulton Date: Sun, 11 Jan 2015 16:45:53 +0000 Subject: Tests for Python default arguments and %pythondefaultargs. Tests changes in previous commit (see patch #294) --- Examples/test-suite/default_args.i | 5 ++++- Examples/test-suite/python_default_args.i | 7 +------ 2 files changed, 5 insertions(+), 7 deletions(-) diff --git a/Examples/test-suite/default_args.i b/Examples/test-suite/default_args.i index cd66676ac..2bbd6738d 100644 --- a/Examples/test-suite/default_args.i +++ b/Examples/test-suite/default_args.i @@ -13,11 +13,14 @@ %inline %{ #include - // All kinds of numbers: hex, octal (which pose special problems to Python), negative... + // All kinds of numbers: hex, octal (which pose special problems to Python (using %pythondefaultargs), negative... void trickyvalue1(int first, int pos = -1) {} void trickyvalue2(int first, unsigned rgb = 0xabcdef) {} void trickyvalue3(int first, int mode = 0644) {} + void doublevalue1(int first, double num = 0.0e-1) {} + void doublevalue2(int first, double num = -0.0E2) {} + // Long long arguments are not handled at Python level currently but still work. void seek(long long offset = 0LL) {} diff --git a/Examples/test-suite/python_default_args.i b/Examples/test-suite/python_default_args.i index 01c090342..f8f2072c4 100644 --- a/Examples/test-suite/python_default_args.i +++ b/Examples/test-suite/python_default_args.i @@ -1,11 +1,6 @@ %module python_default_args +// Testing use of %pythondefaultargs %pythondefaultargs; -// Turn off the feature for the tricky cases that can't be handled -%nopythondefaultargs trickyvalue3; // 'mode=0644' is okay in Python 2, but no Python 3 -%nopythondefaultargs seek; -%nopythondefaultargs Space::Klass::inc; -%nopythondefaultargs DerivedEnumClass::accelerate; - %include "default_args.i" -- cgit v1.2.1 From 06e361dbf279e93a137b77e0c1b0d19afc0060ba Mon Sep 17 00:00:00 2001 From: William S Fulton Date: Sun, 11 Jan 2015 17:30:25 +0000 Subject: Fix linux gcc warnings and strtol corrections --- Source/Modules/php.cxx | 4 ++-- Source/Modules/python.cxx | 6 ++++-- 2 files changed, 6 insertions(+), 4 deletions(-) diff --git a/Source/Modules/php.cxx b/Source/Modules/php.cxx index efeb4dcc4..620966a58 100644 --- a/Source/Modules/php.cxx +++ b/Source/Modules/php.cxx @@ -1268,7 +1268,7 @@ public: break; char *p; errno = 0; - int n = strtol(Char(value), &p, 0); + long n = strtol(Char(value), &p, 0); Clear(value); if (errno || *p) { Append(value, "?"); @@ -1286,7 +1286,7 @@ public: case T_LONG: { char *p; errno = 0; - unsigned int n = strtol(Char(value), &p, 0); + long n = strtol(Char(value), &p, 0); (void) n; if (errno || *p) { Clear(value); diff --git a/Source/Modules/python.cxx b/Source/Modules/python.cxx index ed19e0b46..00eec707a 100644 --- a/Source/Modules/python.cxx +++ b/Source/Modules/python.cxx @@ -1825,7 +1825,8 @@ public: const char *const s = Char(v); char *end; - (void)strtod(s, &end); + double value = strtod(s, &end); + (void) value; if (errno != ERANGE && end != s) { // An added complication: at least some versions of strtod() recognize // hexadecimal floating point numbers which don't exist in Python, so @@ -1868,7 +1869,8 @@ public: char *end; // Check if this is a number in any base. - (void)strtol(s, &end, 0); + long value = strtol(s, &end, 0); + (void) value; if (end != s) { if (errno == ERANGE) { // There was an overflow, we could try representing the value as Python -- cgit v1.2.1 From 682b4dd8434401ba57f26f3e3da6fe2571d372ca Mon Sep 17 00:00:00 2001 From: Olly Betts Date: Mon, 12 Jan 2015 13:53:01 +1300 Subject: [PHP] Fix segfault in director upcall check Manifest only when using PHP built with ZTS enabled. --- CHANGES.current | 4 ++++ Source/Modules/php.cxx | 15 ++++++++------- 2 files changed, 12 insertions(+), 7 deletions(-) diff --git a/CHANGES.current b/CHANGES.current index 7c9712f0e..f04bbd9b0 100644 --- a/CHANGES.current +++ b/CHANGES.current @@ -5,6 +5,10 @@ See the RELEASENOTES file for a summary of changes in each release. Version 3.0.4 (in progress) =========================== +2015-01-12: olly + [PHP] Fix segfault in director upcall check when using PHP built with + ZTS enabled. Fixes #155, reported by Pierre Labastie. + 2015-01-08: wsfulton [Python] Fix #294 #296 - Regression introduced in SWIG-3.0.3 when wrapping functions with default arguments. Now any method with default diff --git a/Source/Modules/php.cxx b/Source/Modules/php.cxx index 620966a58..218d6250c 100644 --- a/Source/Modules/php.cxx +++ b/Source/Modules/php.cxx @@ -826,13 +826,6 @@ public: Delete(args); args = NULL; } - if (is_member_director(n)) { - Wrapper_add_local(f, "director", "Swig::Director *director = 0"); - Printf(f->code, "director = dynamic_cast(arg1);\n"); - Wrapper_add_local(f, "upcall", "bool upcall = false"); - Printf(f->code, "upcall = !director->swig_is_overridden_method((char *)\"%s%s\", (char *)\"%s\");\n", - prefix, Swig_class_name(Swig_methodclass(n)), name); - } // This generated code may be called: // 1) as an object method, or @@ -921,6 +914,14 @@ public: Delete(source); } + if (is_member_director(n)) { + Wrapper_add_local(f, "director", "Swig::Director *director = 0"); + Printf(f->code, "director = dynamic_cast(arg1);\n"); + Wrapper_add_local(f, "upcall", "bool upcall = false"); + Printf(f->code, "upcall = !director->swig_is_overridden_method((char *)\"%s%s\", (char *)\"%s\");\n", + prefix, Swig_class_name(Swig_methodclass(n)), name); + } + Swig_director_emit_dynamic_cast(n, f); /* Insert constraint checking code */ -- cgit v1.2.1 From 02b10195fcc9b66076fc77beaa6752a7ed0fe134 Mon Sep 17 00:00:00 2001 From: Olly Betts Date: Mon, 12 Jan 2015 22:33:15 +1300 Subject: Add regression test for #217 --- Examples/test-suite/errors/pp_unknowndirective2.i | 9 +++++++++ Examples/test-suite/errors/pp_unknowndirective2.stderr | 1 + 2 files changed, 10 insertions(+) create mode 100644 Examples/test-suite/errors/pp_unknowndirective2.i create mode 100644 Examples/test-suite/errors/pp_unknowndirective2.stderr diff --git a/Examples/test-suite/errors/pp_unknowndirective2.i b/Examples/test-suite/errors/pp_unknowndirective2.i new file mode 100644 index 000000000..c66443d93 --- /dev/null +++ b/Examples/test-suite/errors/pp_unknowndirective2.i @@ -0,0 +1,9 @@ +%module xxx + +#ifdef FOO +long long i; +#elsif defined(BAR) +long i; +#else +int i; +#endif diff --git a/Examples/test-suite/errors/pp_unknowndirective2.stderr b/Examples/test-suite/errors/pp_unknowndirective2.stderr new file mode 100644 index 000000000..8426dd17f --- /dev/null +++ b/Examples/test-suite/errors/pp_unknowndirective2.stderr @@ -0,0 +1 @@ +pp_unknowndirective2.i:5: Error: Unknown SWIG preprocessor directive: elsif -- cgit v1.2.1 From 112499eb398f729e66c3bb7661f6d4d3263ccca2 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Klaus=20K=C3=A4mpf?= Date: Mon, 12 Jan 2015 15:17:10 +0100 Subject: Ruby: Replace Config::CONFIG with RbConfig::CONFIG in configure.ac The Config namespace was deprecated for a long time and Ruby 2.2 finally removed it. Adapt configure.ac accordingly. This fixes issue #304 --- configure.ac | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) diff --git a/configure.ac b/configure.ac index ff2b057d9..911d364f5 100644 --- a/configure.ac +++ b/configure.ac @@ -1508,7 +1508,7 @@ if test -n "$RUBY"; then # Try Ruby1.9+ first RUBYDIR=`($RUBY -rrbconfig -e 'print RbConfig::CONFIG[["rubyhdrdir"]] || $rubyhdrdir') 2>/dev/null` if test x"$RUBYDIR" = x"" || test x"$RUBYDIR" = x"nil"; then - RUBYDIR=`($RUBY -rmkmf -e 'print Config::CONFIG[["archdir"]] || $archdir') 2>/dev/null` + RUBYDIR=`($RUBY -rmkmf -e 'print RbConfig::CONFIG[["archdir"]] || $archdir') 2>/dev/null` else RUBYARCH=`($RUBY -rrbconfig -e 'print RbConfig::CONFIG[["arch"]] || $arch') 2>/dev/null` fi @@ -1533,13 +1533,13 @@ if test -n "$RUBY"; then # Find library and path for linking. AC_MSG_CHECKING(for Ruby library) RUBYLIB="" - rb_libdir=`($RUBY -rrbconfig -e 'print Config::CONFIG[["libdir"]]') 2>/dev/null` - rb_bindir=`($RUBY -rrbconfig -e 'print Config::CONFIG[["bindir"]]') 2>/dev/null` + rb_libdir=`($RUBY -rrbconfig -e 'print RbConfig::CONFIG[["libdir"]]') 2>/dev/null` + rb_bindir=`($RUBY -rrbconfig -e 'print RbConfig::CONFIG[["bindir"]]') 2>/dev/null` dirs="$dirs $rb_libdir $rb_bindir" - rb_libruby=`($RUBY -rrbconfig -e 'print Config::CONFIG[["LIBRUBY_A"]]') 2>/dev/null` + rb_libruby=`($RUBY -rrbconfig -e 'print RbConfig::CONFIG[["LIBRUBY_A"]]') 2>/dev/null` RUBYLINK=`($RUBY -rrbconfig -e ' - c = Config::CONFIG + c = RbConfig::CONFIG if c.has_key? "LIBRUBYARG_STATIC" # 1.8.x if c[["LIBRUBY"]] == c[["LIBRUBY_A"]] link = c[["LIBRUBYARG_STATIC"]] @@ -1585,11 +1585,11 @@ if test -n "$RUBY"; then case $host in *-*-mingw*) ;; # do nothing, the default windows libraries are already included - *) RUBYLINK="$RUBYLINK `($RUBY -rrbconfig -e 'print Config::CONFIG[["LIBS"]]') 2>/dev/null`";; + *) RUBYLINK="$RUBYLINK `($RUBY -rrbconfig -e 'print RbConfig::CONFIG[["LIBS"]]') 2>/dev/null`";; esac - RUBYCCDLFLAGS=`($RUBY -rrbconfig -e 'print Config::CONFIG[["CCDLFLAGS"]]') 2>/dev/null` - RUBYSO=.`($RUBY -rrbconfig -e 'print Config::CONFIG[["DLEXT"]]') 2>/dev/null` + RUBYCCDLFLAGS=`($RUBY -rrbconfig -e 'print RbConfig::CONFIG[["CCDLFLAGS"]]') 2>/dev/null` + RUBYSO=.`($RUBY -rrbconfig -e 'print RbConfig::CONFIG[["DLEXT"]]') 2>/dev/null` else AC_MSG_RESULT(could not figure out how to run ruby) fi -- cgit v1.2.1 From 9d87b9f099cf1dd3978375d3a4a109221570e7f9 Mon Sep 17 00:00:00 2001 From: William S Fulton Date: Mon, 12 Jan 2015 21:35:47 +0000 Subject: Revert introduction of python:defaultargs feature See issue #294 --- CHANGES.current | 13 ++----- Examples/test-suite/default_args.i | 6 ++- Examples/test-suite/python/Makefile.in | 1 - .../test-suite/python/python_default_args_runme.py | 3 -- Examples/test-suite/python_default_args.i | 6 --- Lib/python/pyuserdir.swg | 11 ------ Source/Modules/python.cxx | 44 ++++++++++------------ 7 files changed, 29 insertions(+), 55 deletions(-) delete mode 100644 Examples/test-suite/python/python_default_args_runme.py delete mode 100644 Examples/test-suite/python_default_args.i diff --git a/CHANGES.current b/CHANGES.current index f04bbd9b0..cc36f9397 100644 --- a/CHANGES.current +++ b/CHANGES.current @@ -9,18 +9,13 @@ Version 3.0.4 (in progress) [PHP] Fix segfault in director upcall check when using PHP built with ZTS enabled. Fixes #155, reported by Pierre Labastie. -2015-01-08: wsfulton +2015-01-12: vadz [Python] Fix #294 #296 - Regression introduced in SWIG-3.0.3 when - wrapping functions with default arguments. Now any method with default - arguments obtains the default arguments from C++ instead of generating - Python code with the default arguments. - - The "python:defaultargs" feature has been introduced for users to - optionally generate Python methods with the default arguments instead - the default *args. + wrapping functions with default arguments. Invalid or missing default + arguments were sometimes being generated into the python layer. 2015-01-08: olly - Allow C++11 "explicit constexpr". Fixes github issue#284 reported + Allow C++11 "explicit constexpr". Fixes github issue #284 reported by Paweł Tomulik. Also handle "constexpr explicit" and "constexpr static". diff --git a/Examples/test-suite/default_args.i b/Examples/test-suite/default_args.i index 2bbd6738d..53f88fe37 100644 --- a/Examples/test-suite/default_args.i +++ b/Examples/test-suite/default_args.i @@ -13,7 +13,7 @@ %inline %{ #include - // All kinds of numbers: hex, octal (which pose special problems to Python (using %pythondefaultargs), negative... + // All kinds of numbers: hex, octal (which pose special problems to Python), negative... void trickyvalue1(int first, int pos = -1) {} void trickyvalue2(int first, unsigned rgb = 0xabcdef) {} void trickyvalue3(int first, int mode = 0644) {} @@ -23,6 +23,10 @@ // Long long arguments are not handled at Python level currently but still work. void seek(long long offset = 0LL) {} + void seek2(unsigned long long offset = 0ULL) {} + void seek3(long offset = 0L) {} + void seek4(unsigned long offset = 0UL) {} + void seek5(unsigned long offset = 0U) {} // Anonymous arguments int anonymous(int = 7771); diff --git a/Examples/test-suite/python/Makefile.in b/Examples/test-suite/python/Makefile.in index 3c87577a2..82a0e9db1 100644 --- a/Examples/test-suite/python/Makefile.in +++ b/Examples/test-suite/python/Makefile.in @@ -58,7 +58,6 @@ CPP_TEST_CASES += \ primitive_types \ python_abstractbase \ python_append \ - python_default_args \ python_director \ python_nondynamic \ python_overload_simple_cast \ diff --git a/Examples/test-suite/python/python_default_args_runme.py b/Examples/test-suite/python/python_default_args_runme.py deleted file mode 100644 index 7f35fbed6..000000000 --- a/Examples/test-suite/python/python_default_args_runme.py +++ /dev/null @@ -1,3 +0,0 @@ -# Test %feature("python:defaultargs") using the test code in default_args_runme.py (which does not use the feature) -import default_args_runme -default_args_runme.run('python_default_args') diff --git a/Examples/test-suite/python_default_args.i b/Examples/test-suite/python_default_args.i deleted file mode 100644 index f8f2072c4..000000000 --- a/Examples/test-suite/python_default_args.i +++ /dev/null @@ -1,6 +0,0 @@ -%module python_default_args - -// Testing use of %pythondefaultargs -%pythondefaultargs; - -%include "default_args.i" diff --git a/Lib/python/pyuserdir.swg b/Lib/python/pyuserdir.swg index 2a1d80790..00aec07d5 100644 --- a/Lib/python/pyuserdir.swg +++ b/Lib/python/pyuserdir.swg @@ -185,17 +185,6 @@ These methods "may be called" if needed. #define %clearpythonappend %feature("pythonappend","") -/* ------------------------------------------------------------------------- */ -/* - Python default argument handling (for non-builtin) -*/ - -#define %pythondefaultargs %feature("python:defaultargs") -#define %nopythondefaultargs %feature("python:defaultargs", "0") -#define %clearpythondefaultargs %feature("python:defaultargs", "") - - - /* ------------------------------------------------------------------------- */ /* %extend_smart_pointer extend the smart pointer support. diff --git a/Source/Modules/python.cxx b/Source/Modules/python.cxx index 00eec707a..abfe29823 100644 --- a/Source/Modules/python.cxx +++ b/Source/Modules/python.cxx @@ -1975,33 +1975,29 @@ public: bool is_representable = true; if (Getattr(n, "sym:overloaded")) { - if (GetFlag(n, "feature:python:defaultargs")) { - ParmList *plist = CopyParmList(Getattr(n, "parms")); - Parm *p; - Parm *pnext; - - for (p = plist; p; p = pnext) { - pnext = NIL; - String *tm = Getattr(p, "tmap:in"); - if (tm) { - pnext = Getattr(p, "tmap:in:next"); - if (checkAttribute(p, "tmap:in:numinputs", "0")) { - continue; - } - } - if (!pnext) { - pnext = nextSibling(p); + ParmList *plist = CopyParmList(Getattr(n, "parms")); + Parm *p; + Parm *pnext; + + for (p = plist; p; p = pnext) { + pnext = NIL; + String *tm = Getattr(p, "tmap:in"); + if (tm) { + pnext = Getattr(p, "tmap:in:next"); + if (checkAttribute(p, "tmap:in:numinputs", "0")) { + continue; } - if (String *value = Getattr(p, "value")) { - String *type = Getattr(p, "type"); - if (!convertValue(value, type)) { - is_representable = false; - break; - } + } + if (!pnext) { + pnext = nextSibling(p); + } + if (String *value = Getattr(p, "value")) { + String *type = Getattr(p, "type"); + if (!convertValue(value, type)) { + is_representable = false; + break; } } - } else { - is_representable = false; } } return is_representable; -- cgit v1.2.1 From 944fbfb426276358c92410c5f40db28262674fcc Mon Sep 17 00:00:00 2001 From: William S Fulton Date: Tue, 13 Jan 2015 07:52:48 +0000 Subject: Python 3 default args fix Fix 0U and 0L as default args for Python 3 (tests committed in previously commit of default_args.i). Relates to issue #294. --- Examples/test-suite/default_args.i | 6 ++++++ Source/Modules/python.cxx | 8 +++++--- 2 files changed, 11 insertions(+), 3 deletions(-) diff --git a/Examples/test-suite/default_args.i b/Examples/test-suite/default_args.i index 53f88fe37..bcb8766a8 100644 --- a/Examples/test-suite/default_args.i +++ b/Examples/test-suite/default_args.i @@ -27,6 +27,12 @@ void seek3(long offset = 0L) {} void seek4(unsigned long offset = 0UL) {} void seek5(unsigned long offset = 0U) {} + void seek6(unsigned long offset = 02U) {} + void seek7(unsigned long offset = 00U) {} + void seek8(unsigned long offset = 1U) {} + void seek9(long offset = 1L) {} + void seekA(long long offset = 1LL) {} + void seekB(unsigned long long offset = 1ULL) {} // Anonymous arguments int anonymous(int = 7771); diff --git a/Source/Modules/python.cxx b/Source/Modules/python.cxx index abfe29823..dde1b6023 100644 --- a/Source/Modules/python.cxx +++ b/Source/Modules/python.cxx @@ -1923,9 +1923,11 @@ public: // to be "0o" in Python 3 only (and as long as we still support Python // 2.5, this can't be done unconditionally). if (py3) { - String *res = NewString("0o"); - Append(res, NewStringWithSize(s + 1, end - s - 1)); - return res; + if (end - s > 1) { + String *res = NewString("0o"); + Append(res, NewStringWithSize(s + 1, end - s - 1)); + return res; + } } } } -- cgit v1.2.1 From 055e96da09aa92aec09658dea5a4aabd9a240404 Mon Sep 17 00:00:00 2001 From: William S Fulton Date: Mon, 12 Jan 2015 21:49:38 +0000 Subject: Update html --- Doc/Manual/Contents.html | 1 + 1 file changed, 1 insertion(+) diff --git a/Doc/Manual/Contents.html b/Doc/Manual/Contents.html index 74cf27394..51d4edaa4 100644 --- a/Doc/Manual/Contents.html +++ b/Doc/Manual/Contents.html @@ -841,6 +841,7 @@

    • Overview +
    • Examples
    • Running SWIG with Go
      • Additional Commandline Options -- cgit v1.2.1 From ea5be4e5083750f0aeb168a748e14ec6d809b3c0 Mon Sep 17 00:00:00 2001 From: Olly Betts Date: Wed, 14 Jan 2015 10:44:54 +1300 Subject: Fix PHP backend for default_args testcase --- Source/Modules/php.cxx | 21 +++++++++++---------- 1 file changed, 11 insertions(+), 10 deletions(-) diff --git a/Source/Modules/php.cxx b/Source/Modules/php.cxx index 218d6250c..00dfb064e 100644 --- a/Source/Modules/php.cxx +++ b/Source/Modules/php.cxx @@ -1284,7 +1284,8 @@ public: case T_SCHAR: case T_SHORT: case T_INT: - case T_LONG: { + case T_LONG: + case T_LONGLONG: { char *p; errno = 0; long n = strtol(Char(value), &p, 0); @@ -1298,7 +1299,8 @@ public: case T_UCHAR: case T_USHORT: case T_UINT: - case T_ULONG: { + case T_ULONG: + case T_ULONGLONG: { char *p; errno = 0; unsigned int n = strtoul(Char(value), &p, 0); @@ -1310,7 +1312,8 @@ public: break; } case T_FLOAT: - case T_DOUBLE:{ + case T_DOUBLE: + case T_LONGDOUBLE: { char *p; errno = 0; /* FIXME: strtod is locale dependent... */ @@ -1329,13 +1332,6 @@ public: } break; } - case T_REFERENCE: - case T_RVALUE_REFERENCE: - case T_USER: - case T_ARRAY: - Clear(value); - Append(value, "?"); - break; case T_STRING: if (Len(value) < 2) { // How can a string (including "" be less than 2 characters?) @@ -1384,6 +1380,11 @@ public: } break; } + default: + /* Safe default */ + Clear(value); + Append(value, "?"); + break; } if (!arg_values[argno]) { -- cgit v1.2.1 From a98bda01cbce175a45d94047aef2ac2ca82c3033 Mon Sep 17 00:00:00 2001 From: Olly Betts Date: Wed, 14 Jan 2015 11:04:02 +1300 Subject: Note 1.8 as the oldest supported version --- Doc/Manual/Ruby.html | 20 +++++++++++++------- 1 file changed, 13 insertions(+), 7 deletions(-) diff --git a/Doc/Manual/Ruby.html b/Doc/Manual/Ruby.html index 181c46ba9..1b1cfe6a5 100644 --- a/Doc/Manual/Ruby.html +++ b/Doc/Manual/Ruby.html @@ -147,7 +147,7 @@

        38.1 Preliminaries

        -

        SWIG 1.3 is known to work with Ruby versions 1.6 and later. +

        SWIG 3.0 is known to work with Ruby versions 1.8 and later. Given the choice, you should use the latest stable version of Ruby. You should also determine if your system supports shared libraries and dynamic loading. SWIG will work with or without dynamic loading, but @@ -191,7 +191,7 @@ header file. This file is usually contained in a directory such as

        /usr/lib/ruby/1.8/x86_64-linux-gnu/ruby.h
        -/usr/local/lib/ruby/1.6/i686-linux/ruby.h
        +/usr/include/ruby-2.1.0/ruby.h
         
        @@ -201,8 +201,14 @@ installed, you can run Ruby to find out. For example:

        $ ruby -e 'puts $:.join("\n")'
        -/usr/local/lib/ruby/site_ruby/1.6 /usr/local/lib/ruby/site_ruby/1.6/i686-linux
        -/usr/local/lib/ruby/site_ruby /usr/local/lib/ruby/1.6 /usr/local/lib/ruby/1.6/i686-linux .
        +/usr/local/lib/site_ruby/2.1.0
        +/usr/local/lib/x86_64-linux-gnu/site_ruby
        +/usr/local/lib/site_ruby
        +/usr/lib/ruby/vendor_ruby/2.1.0
        +/usr/lib/x86_64-linux-gnu/ruby/vendor_ruby/2.1.0
        +/usr/lib/ruby/vendor_ruby
        +/usr/lib/ruby/2.1.0
        +/usr/lib/x86_64-linux-gnu/ruby/2.1.0
         
        @@ -260,7 +266,7 @@ operating system would look something like this:

        $ swig -ruby example.i
         $ gcc -O2 -fPIC -c example.c
        -$ gcc -O2 -fPIC -c example_wrap.c -I/usr/local/lib/ruby/1.6/i686-linux
        +$ gcc -O2 -fPIC -c example_wrap.c -I/usr/include/ruby-2.1.0
         $ gcc -shared example.o example_wrap.o -o example.so
         
        @@ -334,7 +340,7 @@ using the C++ compiler. For example:

         $ swig -c++ -ruby example.i
         $ g++ -fPIC -c example.cxx
        -$ g++ -fPIC -c example_wrap.cxx -I/usr/local/lib/ruby/1.6/i686-linux
        +$ g++ -fPIC -c example_wrap.cxx -I/usr/include/ruby-2.1.0
         $ g++ -shared example.o example_wrap.o -o example.so
         
    @@ -4466,7 +4472,7 @@ and then type make to build the shared library:

    $ ruby extconf.rb
     creating Makefile
     $ make
    -g++ -fPIC -g -O2 -I. -I/usr/local/lib/ruby/1.7/i686-linux \
    +g++ -fPIC -g -O2 -I. -I/usr/include/ruby-2.1.0 \
     -I. -c shape_wrap.cxx
     gcc -shared -L/usr/local/lib -o shape.so shape_wrap.o -L. \
     -lruby -lruby -lc
    -- cgit v1.2.1 From aa5d916e4d2ea5344c2a9a2126daa0a5710213c7 Mon Sep 17 00:00:00 2001 From: Olly Betts Date: Wed, 14 Jan 2015 11:04:09 +1300 Subject: Fix typo --- Doc/Manual/Ruby.html | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Doc/Manual/Ruby.html b/Doc/Manual/Ruby.html index 1b1cfe6a5..e78447b92 100644 --- a/Doc/Manual/Ruby.html +++ b/Doc/Manual/Ruby.html @@ -5357,7 +5357,7 @@ used for callbacks, for example.

    To solve the problem, SWIG can now generate code with director functions containing the optional macros SWIG_INIT_STACK and SWIG_RELEASE_STACK. These macros will try to force Ruby to -reinitiliaze the beginning of the stack the first time a +reinitialize the beginning of the stack the first time a director function is called. This will lead Ruby to measure and not collect any VALUE objects defined from that point on.

    -- cgit v1.2.1 From 558ded2cebaaaba55c2e6adb10ca932fb1c2d260 Mon Sep 17 00:00:00 2001 From: William S Fulton Date: Tue, 13 Jan 2015 23:06:03 +0000 Subject: Add 3.0.4 release information --- ANNOUNCE | 2 +- CHANGES.current | 2 +- Doc/Manual/Sections.html | 2 +- README | 2 +- RELEASENOTES | 4 ++++ 5 files changed, 8 insertions(+), 4 deletions(-) diff --git a/ANNOUNCE b/ANNOUNCE index f419bf2c4..894010dc4 100644 --- a/ANNOUNCE +++ b/ANNOUNCE @@ -1,4 +1,4 @@ -*** ANNOUNCE: SWIG 3.0.4 (in progress) *** +*** ANNOUNCE: SWIG 3.0.4 (14 Jan 2015) *** http://www.swig.org diff --git a/CHANGES.current b/CHANGES.current index cc36f9397..1787477e6 100644 --- a/CHANGES.current +++ b/CHANGES.current @@ -2,7 +2,7 @@ Below are the changes for the current release. See the CHANGES file for changes in older releases. See the RELEASENOTES file for a summary of changes in each release. -Version 3.0.4 (in progress) +Version 3.0.4 (14 Jan 2015) =========================== 2015-01-12: olly diff --git a/Doc/Manual/Sections.html b/Doc/Manual/Sections.html index 2b2917203..897d274ed 100644 --- a/Doc/Manual/Sections.html +++ b/Doc/Manual/Sections.html @@ -6,7 +6,7 @@

    SWIG-3.0 Documentation

    -Last update : SWIG-3.0.4 (in progress) +Last update : SWIG-3.0.4 (14 Jan 2015)

    Sections

    diff --git a/README b/README index 4d3b30012..969ee4e89 100644 --- a/README +++ b/README @@ -1,6 +1,6 @@ SWIG (Simplified Wrapper and Interface Generator) -Version: 3.0.4 (in progress) +Version: 3.0.4 (14 Jan 2015) Tagline: SWIG is a compiler that integrates C and C++ with languages including Perl, Python, Tcl, Ruby, PHP, Java, C#, D, Go, Lua, diff --git a/RELEASENOTES b/RELEASENOTES index 1db08977b..2aff1d265 100644 --- a/RELEASENOTES +++ b/RELEASENOTES @@ -4,6 +4,10 @@ and CHANGES files. Release Notes ============= +SWIG-3.0.4 summary: +- Python regression fix when wrapping C++ default arguments. +- Improved error messages. + SWIG-3.0.3 summary: - Add support for C++11 strongly typed enumerations. - Numerous bug fixes and minor enhancements for C#, D, Go, Java, -- cgit v1.2.1 From 0dd685bad224ea2a586340b46ea5fa25e8d9422c Mon Sep 17 00:00:00 2001 From: Olly Betts Date: Wed, 14 Jan 2015 15:38:55 +1300 Subject: Fix PHP crash in director_finalizer --- Lib/php/director.swg | 3 +-- Source/Modules/php.cxx | 4 +--- 2 files changed, 2 insertions(+), 5 deletions(-) diff --git a/Lib/php/director.swg b/Lib/php/director.swg index 06eeb73b0..92c149999 100644 --- a/Lib/php/director.swg +++ b/Lib/php/director.swg @@ -98,8 +98,7 @@ namespace Swig { TSRMLS_SET_CTX(swig_zts_ctx); } - bool swig_is_overridden_method(char *cname, char *lc_fname) { - TSRMLS_FETCH_FROM_CTX(swig_zts_ctx); + static bool swig_is_overridden_method(char *cname, char *lc_fname TSRMLS_DC) { zend_class_entry **ce; zend_function *mptr; diff --git a/Source/Modules/php.cxx b/Source/Modules/php.cxx index 00dfb064e..a2f0e3687 100644 --- a/Source/Modules/php.cxx +++ b/Source/Modules/php.cxx @@ -915,10 +915,8 @@ public: } if (is_member_director(n)) { - Wrapper_add_local(f, "director", "Swig::Director *director = 0"); - Printf(f->code, "director = dynamic_cast(arg1);\n"); Wrapper_add_local(f, "upcall", "bool upcall = false"); - Printf(f->code, "upcall = !director->swig_is_overridden_method((char *)\"%s%s\", (char *)\"%s\");\n", + Printf(f->code, "upcall = !Swig::Director::swig_is_overridden_method((char *)\"%s%s\", (char *)\"%s\" TSRMLS_CC);\n", prefix, Swig_class_name(Swig_methodclass(n)), name); } -- cgit v1.2.1 From a2f803bb5a1805ac5c22a38dff17bf3d8bafe0bf Mon Sep 17 00:00:00 2001 From: Olly Betts Date: Wed, 14 Jan 2015 16:00:40 +1300 Subject: Add explanatory comment to pp_unknowndirective2.i --- Examples/test-suite/errors/pp_unknowndirective2.i | 2 ++ Examples/test-suite/errors/pp_unknowndirective2.stderr | 2 +- 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/Examples/test-suite/errors/pp_unknowndirective2.i b/Examples/test-suite/errors/pp_unknowndirective2.i index c66443d93..889e6c5b2 100644 --- a/Examples/test-suite/errors/pp_unknowndirective2.i +++ b/Examples/test-suite/errors/pp_unknowndirective2.i @@ -2,6 +2,8 @@ #ifdef FOO long long i; +/* Check we get an error for an unknown directive (this should be #elif). + * Unknown directives were silently ignored by SWIG < 3.0.3. */ #elsif defined(BAR) long i; #else diff --git a/Examples/test-suite/errors/pp_unknowndirective2.stderr b/Examples/test-suite/errors/pp_unknowndirective2.stderr index 8426dd17f..8244c7d0d 100644 --- a/Examples/test-suite/errors/pp_unknowndirective2.stderr +++ b/Examples/test-suite/errors/pp_unknowndirective2.stderr @@ -1 +1 @@ -pp_unknowndirective2.i:5: Error: Unknown SWIG preprocessor directive: elsif +pp_unknowndirective2.i:7: Error: Unknown SWIG preprocessor directive: elsif -- cgit v1.2.1 From be4065531eb712e9536332471bec353a7b7f89b9 Mon Sep 17 00:00:00 2001 From: Olly Betts Date: Wed, 14 Jan 2015 16:08:08 +1300 Subject: Add suggestion to check block delimiter The fix for #217 means that blocks of target code delimited by { } with '#' comments in now give errors (previously these lines were quietly discarded). The fix is generally to use %{ %} delimiters instead, so suggest this might be the issue in the error message to help users hitting this issue with wrappers which were apparently working before. --- Examples/test-suite/errors/pp_unknowndirective2.stderr | 2 +- Source/Preprocessor/cpp.c | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/Examples/test-suite/errors/pp_unknowndirective2.stderr b/Examples/test-suite/errors/pp_unknowndirective2.stderr index 8244c7d0d..70afa670c 100644 --- a/Examples/test-suite/errors/pp_unknowndirective2.stderr +++ b/Examples/test-suite/errors/pp_unknowndirective2.stderr @@ -1 +1 @@ -pp_unknowndirective2.i:7: Error: Unknown SWIG preprocessor directive: elsif +pp_unknowndirective2.i:7: Error: Unknown SWIG preprocessor directive: elsif (if this is a block of target language code, delimit it with %{ and %}) diff --git a/Source/Preprocessor/cpp.c b/Source/Preprocessor/cpp.c index 8fd30f703..ac912f49e 100644 --- a/Source/Preprocessor/cpp.c +++ b/Source/Preprocessor/cpp.c @@ -1771,7 +1771,7 @@ String *Preprocessor_parse(String *s) { } else if (Equal(id, "")) { /* Null directive */ } else { - Swig_error(Getfile(s), Getline(id), "Unknown SWIG preprocessor directive: %s\n", id); + Swig_error(Getfile(s), Getline(id), "Unknown SWIG preprocessor directive: %s (if this is a block of target language code, delimit it with %%{ and %%})\n", id); } for (i = 0; i < cpp_lines; i++) Putc('\n', ns); -- cgit v1.2.1 From 4fed2e6690b1486952b0543b6bde28573eb0d132 Mon Sep 17 00:00:00 2001 From: Olly Betts Date: Wed, 14 Jan 2015 09:31:41 +0000 Subject: Use -rrbconfig rather than -rmkmf to load rbconfig Both seem to work, but it's better to ask for the module we actually want rather than rely on it being pulled in indirectly. See #305. --- configure.ac | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/configure.ac b/configure.ac index 911d364f5..b0c7e869d 100644 --- a/configure.ac +++ b/configure.ac @@ -1508,7 +1508,7 @@ if test -n "$RUBY"; then # Try Ruby1.9+ first RUBYDIR=`($RUBY -rrbconfig -e 'print RbConfig::CONFIG[["rubyhdrdir"]] || $rubyhdrdir') 2>/dev/null` if test x"$RUBYDIR" = x"" || test x"$RUBYDIR" = x"nil"; then - RUBYDIR=`($RUBY -rmkmf -e 'print RbConfig::CONFIG[["archdir"]] || $archdir') 2>/dev/null` + RUBYDIR=`($RUBY -rrbconfig -e 'print RbConfig::CONFIG[["archdir"]] || $archdir') 2>/dev/null` else RUBYARCH=`($RUBY -rrbconfig -e 'print RbConfig::CONFIG[["arch"]] || $arch') 2>/dev/null` fi -- cgit v1.2.1